VE Lua Documentation

Press F to search!

update

Definition


-- @/lua/common/luaCore.lua:41

function nop()
end

Callers

@/inspector/Views/Layers3DContentView.js
    {
        this._controls.update();
        this._restrictPan();
@/lua/vehicle/powertrain/hydraulicPump.lua
  for _, consumer in ipairs(device.connectedConsumers) do
    local consumerFlow, tankFlow = consumer:update(device.accumulatorPressure, dt)
    device.accumulatorOutFlow = device.accumulatorOutFlow + consumerFlow + tankFlow
@/ui/ui-vue/src/modules/vehicleConfig/parts/licensePlate.js
    this.settingsChanged()
    this.update()
  }

  update() {
    bngApi.engineLua("core_vehicles.getVehicleLicenseText(getPlayerVehicle(0))", str => this.text = str)
    bngApi.engineLua(`core_vehicles.setPlateText(core_vehicles.regenerateVehicleLicenseText(getPlayerVehicle(0)),nil,nil,nil)`)
    this.update()
  }
@/lua/ge/extensions/core/cameraModes/trackir.lua

function C:update(data)
  if data.openxrSessionRunning then return end -- disable potentially conflicting head-tracking systems (like some VR injectors, etc) working on top of the normal VR tracking
@/lua/vehicle/powertrain/hydraulicAccumulator.lua
  for _, consumer in ipairs(device.connectedConsumers) do
    local consumerFlow, tankFlow = consumer:update(device.accumulatorPressure, dt)
    device.accumulatorOutFlow = device.accumulatorOutFlow + consumerFlow + tankFlow
@/lua/ge/extensions/campaign/exploration.lua
  end
  destinationMarker:update(dt)
  --
@/lua/common/utils/simpleHttpServer.lua

local function update()
  if not tcp_socket then return end
@/lua/ge/extensions/gameplay/markers/bigmapMarker.lua
-- called every frame to update the visuals.
function C:update(data)
  --if not self.visible then return end
@/ui/ui-vue/src/services/settings.js
    this._lua = lua
    this.update()
  }

  async update() {
    if (!this._lua) return
@/lua/ge/extensions/editor/gen/world.lua
			end
			M.update(dmesh[cmesh])
		end
				cedit.cval['Drag'].terrain = cterrain * dirhit
				M.update(dmesh[cmesh])
				U.boxMark(dmesh[cmesh].obj, out)

				M.update(dmesh[cmesh])
--                dmesh[cmesh].obj:createMesh({})
	--                    lo('?? moved:'..cmesh..':'..n..':'..tostring(dirobj)..':'..dir..':'..tostring(amesh[1].verts[1]))
				M.update(dmesh[cmesh])
				U.boxMark(dmesh[cmesh].obj, out)
				M.move(nil, dmesh[cmesh].trans, dmesh[cmesh].data, 'NONE')
				M.update(dmesh[cmesh])
				out.avedit = {}
				M.move(nil, dmesh[cmesh].sel, dmesh[cmesh].data, 'NONE')
				M.update(dmesh[cmesh])
				out.avedit = {}
			dmesh[cmesh].buf = {}
			M.update(dmesh[cmesh])
			out.avedit = {}
				M.move(nil, dmesh[cmesh].buf, dmesh[cmesh].sel, 'NONE')
				M.update(dmesh[cmesh])
				out.avedit = {}
	--                    lo('?? mmoved:'..#dmesh[cmesh].data)
				M.update(dmesh[cmesh])
				out.avedit = {}
@/lua/ge/extensions/editor/trafficSignalsEditor.lua
    trafficSignals.debugLevel = 2
    map.reset() -- this forces the mapmgr signals to update ("temporary" solution)
    running = true
@/lua/vehicle/controller/tech/tyreBarrier.lua
-- Update called. This is called on every physics step update, once the controller has been loaded.
local function update(dt)
@/lua/common/utils/httpJsonServer.lua

local function update()
    if not tcp_socket then return end
@/inspector/Views/CompletionSuggestionsView.js

    update(completions, selectedIndex)
    {
@/ui/entrypoints/main/main.js
              } else {
                BlurGame.update(id, blur)
              }
@/lua/ge/extensions/gameplay/markers/gasStationMarker.lua

function C:update(data)
  if not self.visible or not data.veh then return end
@/lua/ge/extensions/core/cameraModes/smooth.lua

function C:update(data)
  data.res.pos.x = self.posX:get(data.res.pos.x, data.dt)
@/lua/ge/extensions/core/camera.lua
    -- one of the global cameras
    if globalCam:update(camData) then
      extensions.hook("onCameraPreRender", camData)
    if cam and vdata.focusedCamName then
      cam:update(camData)
      if not validateData(camData) and cam.init then cam:init() end -- if present, clean up NaN/infs in camera state, by re-initting it
  for _,v in ipairs(getRunningCamsOrder()) do
    v.cam:update(camData)
  end
@/ui/ui-vue/src/common/directives/BngOcclusionWatcher.js
    if (!parent || !(parent instanceof HTMLElement) || parent.contains(elm)) {
      update(elm, data)
    }
    if (elms.has(entry.target)) {
      update(entry.target)
    } else {

function update(elm, data = undefined) {
  if (!data) data = elms.get(elm)
      id: uniqueId("occlusion"),
      observe: () => !data.delayed && update(el),
      set: debounce(setOcclusion, DELAY),
        delete data.delayed
        if (elms.has(el)) update(el, data)
      }, value)
    } else {
      update(el, data)
    }
    const data = elms.get(el)
    if (data && !data.delayed) update(el, data)
  },
@/lua/vehicle/beamstate.lua
M.update = nop
local function update(dtSim)
  local finished_precomp = true
@/lua/vehicle/guistreams.lua

local function update()
  for k, _ in pairs(streamControl) do
@/ui/ui-vue/src/modules/vehicleConfig/parts/searchHistory.js

  update() {
    if (this.search.query.length === 0) return
@/lua/ge/extensions/editor/terrainMaterialsEditor.lua
local function onEditorActivated()
  -- we need to update (load) the material library so we can show the list of materials
  if editor.isWindowVisible(terrainMaterialEditorWindowName) then
@/lua/vehicle/controller/drivingDynamics/sensors/vehicleData.lua

local function update(dt)
  local wheelAccess = M.wheelAccess
local function updateDebug(dt)
  update(dt)
end
@/lua/ge/extensions/core/cameraModes/handheld.lua

function C:update(data)
  if self.mustReset then
@/lua/ge/extensions/core/cameraModes/shake.lua

function C:update(data)
  self.time = self.time + data.dt
@/ui/lib/ext/spine-canvas.js
    IkConstraint.prototype.apply = function () {
      this.update();
    };
    PathConstraint.prototype.apply = function () {
      this.update();
    };
      for (var i = 0, n = updateCache.length; i < n; i++)
        updateCache[i].update();
    };
    TransformConstraint.prototype.apply = function () {
      this.update();
    };
@/lua/vehicle/controller.lua
      if controller.update ~= nil then
        print("  sortedControllers[" .. i .. "].update(dt) -- " .. controller.typeName)
      end
@/lua/ge/extensions/core/cameraModes/predictor.lua

function C:update(data)
  data.res.targetPos:setAdd(self.dtFuture * data.vel)
@/lua/ge/extensions/gameplay/markers/parkingMarker.lua
local tmpNormal = vec3()
function C:update(data)
  if not self.visible then return end
@/lua/ge/map.lua

function singleEventTimer:update(dt)
  local waitDt = max(0, self.waitDt - dt)
  end
  delayedLoad:update(dtReal)
  drawTrajectory(trajectoryToDraw)
@/lua/common/utils/perf.lua

local function update()
  local dt = globalTimer:stopAndReset() / 1000
@/lua/ge/extensions/core/cameraModes/crash.lua

function C:update(data)
  local veh1 = scenetree.findObjectById(self.veh1Id)
@/lua/ge/extensions/editor/dragRaceEditor/waypoints.lua

  if transformsState.waypoint:update(mouseInfo) then
    waypoint.transform.position = {x = transformsState.waypoint.pos.x, y = transformsState.waypoint.pos.y, z = transformsState.waypoint.pos.z}
@/lua/ge/extensions/scenario/raceMarkers/sideHologramMarker.lua
-- called every frame to update the visuals.
function C:update(dt, dtSim)
  self.colorTimer = self.colorTimer + dt

  self:update(0,0)
end
@/lua/ge/server/server.lua
  profilerPopEvent("init")
  loadingProgress:update(-1, 'init done')
  be:physicsInitWorld()
  loadingProgress:update(-1, '')
  loadJsonMaterialsFile("art/shapes/particles/managedParticleData.json")
  loadingProgress:update(-1, '')
  loadJsonMaterialsFile("art/shapes/particles/managedParticleEmitterData.json")
  loadJsonMaterialsFile("art/shapes/particles/managedParticleEmitterData.json")
  loadingProgress:update(-1, '')
  if FS:fileExists("art/decals/managedDecalData.cs") then
    TorqueScriptLua.exec("art/decals/managedDecalData.cs")
    loadingProgress:update(-1, '')
  end
  loadJsonMaterialsFile("art/datablocks/audioProfiles.datablocks.json")
  loadingProgress:update(-1, '')
  loadJsonMaterialsFile("art/datablocks/sounds.datablocks.json")
  loadJsonMaterialsFile("art/datablocks/sounds.datablocks.json")
  loadingProgress:update(-1, '')
  if FS:fileExists("art/datablocks/player.datablocks.json") then
    loadJsonMaterialsFile("art/datablocks/player.datablocks.json")
    loadingProgress:update(-1, '')
  end
  loadJsonMaterialsFile("art/datablocks/datablockExec.datablocks.json")
  loadingProgress:update(-1, '')
  loadJsonMaterialsFile("art/datablocks/lights.datablocks.json")
  loadingProgress:update(-1, '')
  loadJsonMaterialsFile("art/datablocks/managedDatablocks.datablocks.json")
  profilerPopEvent("datablocks")
  loadingProgress:update(-1, 'datablocks done')
  profilerPushEvent('materials')
    elseif string.find(filename, 'materials.cs') then
      loadingProgress:update(-1, '')
      TorqueScriptLua.exec(filename)
    elseif string.find(filename, 'materials.json') then
      loadingProgress:update(-1, '')
      loadJsonMaterialsFile(filename)
  for  _, filename in pairs(jsonFilesToLoad) do
    loadingProgress:update(-1, '')
    loadJsonMaterialsFile(filename)
  for  _, filename in pairs(tsFilesToExecute) do
    loadingProgress:update(-1, '')
    TorqueScriptLua.exec(filename)
  profilerPopEvent("materials")
  loadingProgress:update(-1, 'materials done')
  profilerPushEvent('objects')
  profilerPopEvent("objects")
  loadingProgress:update(-1, 'objects done')
  profilerPushEvent('start physics')
  profilerPopEvent("start physics")
  loadingProgress:update(-1, 'physics done')
  profilerPushEvent('spawn player')
  end
  loadingProgress:update(-1, 'player done')
@/inspector/Models/DOMNodeStyles.js
            if (this._computedStyle)
                this._computedStyle.update(null, properties);
            else
            if (property && property.name === name && (property.index === index || (isNaN(property.index) && isNaN(index)))) {
                property.update(text, name, value, priority, enabled, overridden, implicit, anonymous, valid, styleSheetTextRange);
                return property;
                    pendingProperty.index = index;
                    pendingProperty.update(text, name, value, priority, enabled, overridden, implicit, anonymous, valid, styleSheetTextRange);
                    return pendingProperty;
        if (style) {
            style.update(text, properties, styleSheetTextRange);
            return style;
        if (rule) {
            rule.update(sourceCodeLocation, selectorText, selectors, matchedSelectorIndices, style, mediaList);
            return rule;
@/inspector/Views/SpreadsheetTextField.js

        this._suggestionsView.update(completions);
@/lua/vehicle/controller/tech/recorders.lua

local function update(dt)
  if sampleStep == 0 then
@/lua/ge/extensions/gameplay/markers/zoneMarker.lua

function C:update(data)
end
@/ui/modules/photomode/photomode.js
  vm.environment = Environment
  Environment.update()
@/inspector/Controllers/CodeMirrorCompletionController.js
            // Update and show the suggestion list.
            this._suggestionsView.update(completions, index);
            this._suggestionsView.show(bounds);

        function update()
        {
    {
        function update()
        {

        function update()
        {
@/lua/ge/extensions/scenario/raceMarkers/ringMarker.lua
-- called every frame to update the visuals.
function C:update(dt, dtSim)
  end
  self:update(0,0)
end
@/ui/lib/ext/chartist.min.js

!function(a,b){"function"==typeof define&&define.amd?define("Chartist",[],function(){return a.Chartist=b()}):"object"==typeof module&&module.exports?module.exports=b():a.Chartist=b()}(this,function(){var a={version:"0.11.0"};return function(a,b,c){"use strict";c.namespaces={svg:"http://www.w3.org/2000/svg",xmlns:"http://www.w3.org/2000/xmlns/",xhtml:"http://www.w3.org/1999/xhtml",xlink:"http://www.w3.org/1999/xlink",ct:"http://gionkunz.github.com/chartist-js/ct"},c.noop=function(a){return a},c.alphaNumerate=function(a){return String.fromCharCode(97+a%26)},c.extend=function(a){var b,d,e;for(a=a||{},b=1;b":">",'"':""","'":"'"},c.serialize=function(a){return null===a||void 0===a?a:("number"==typeof a?a=""+a:"object"==typeof a&&(a=JSON.stringify({data:a})),Object.keys(c.escapingMap).reduce(function(a,b){return c.replaceAll(a,b,c.escapingMap[b])},a))},c.deserialize=function(a){if("string"!=typeof a)return a;a=Object.keys(c.escapingMap).reduce(function(a,b){return c.replaceAll(a,c.escapingMap[b],b)},a);try{a=JSON.parse(a),a=void 0!==a.data?a.data:a}catch(b){}return a},c.createSvg=function(a,b,d,e){var f;return b=b||"100%",d=d||"100%",Array.prototype.slice.call(a.querySelectorAll("svg")).filter(function(a){return a.getAttributeNS(c.namespaces.xmlns,"ct")}).forEach(function(b){a.removeChild(b)}),f=new c.Svg("svg").attr({width:b,height:d}).addClass(e),f._node.style.width=b,f._node.style.height=d,a.appendChild(f._node),f},c.normalizeData=function(a,b,d){var e,f={raw:a,normalized:{}};return f.normalized.series=c.getDataArray({series:a.series||[]},b,d),e=f.normalized.series.every(function(a){return a instanceof Array})?Math.max.apply(null,f.normalized.series.map(function(a){return a.length})):f.normalized.series.length,f.normalized.labels=(a.labels||[]).slice(),Array.prototype.push.apply(f.normalized.labels,c.times(Math.max(0,e-f.normalized.labels.length)).map(function(){return""})),b&&c.reverseData(f.normalized),f},c.safeHasProperty=function(a,b){return null!==a&&"object"==typeof a&&a.hasOwnProperty(b)},c.isDataHoleValue=function(a){return null===a||void 0===a||"number"==typeof a&&isNaN(a)},c.reverseData=function(a){a.labels.reverse(),a.series.reverse();for(var b=0;bf.high&&(f.high=c),h&&c0?f.low=0:(f.high=1,f.low=0)),f},c.isNumeric=function(a){return null!==a&&isFinite(a)},c.isFalseyButZero=function(a){return!a&&0!==a},c.getNumberOrUndefined=function(a){return c.isNumeric(a)?+a:void 0},c.isMultiValue=function(a){return"object"==typeof a&&("x"in a||"y"in a)},c.getMultiValue=function(a,b){return c.isMultiValue(a)?c.getNumberOrUndefined(a[b||"y"]):c.getNumberOrUndefined(a)},c.rho=function(a){function b(a,c){return a%c===0?c:b(c,a%c)}function c(a){return a*a+1}if(1===a)return a;var d,e=2,f=2;if(a%2===0)return 2;do e=c(e)%a,f=c(c(f))%a,d=b(Math.abs(e-f),a);while(1===d);return d},c.getBounds=function(a,b,d,e){function f(a,b){return a===(a+=b)&&(a*=1+(b>0?o:-o)),a}var g,h,i,j=0,k={high:b.high,low:b.low};k.valueRange=k.high-k.low,k.oom=c.orderOfMagnitude(k.valueRange),k.step=Math.pow(10,k.oom),k.min=Math.floor(k.low/k.step)*k.step,k.max=Math.ceil(k.high/k.step)*k.step,k.range=k.max-k.min,k.numberOfSteps=Math.round(k.range/k.step);var l=c.projectLength(a,k.step,k),m=l=d)k.step=1;else if(e&&n=d)k.step=n;else for(;;){if(m&&c.projectLength(a,k.step,k)<=d)k.step*=2;else{if(m||!(c.projectLength(a,k.step/2,k)>=d))break;if(k.step/=2,e&&k.step%1!==0){k.step*=2;break}}if(j++>1e3)throw new Error("Exceeded maximum number of iterations while optimizing scale step!")}var o=2.221e-16;for(k.step=Math.max(k.step,o),h=k.min,i=k.max;h+k.step<=k.low;)h=f(h,k.step);for(;i-k.step>=k.high;)i=f(i,-k.step);k.min=h,k.max=i,k.range=k.max-k.min;var p=[];for(g=k.min;g<=k.max;g=f(g,k.step)){var q=c.roundWithPrecision(g);q!==p[p.length-1]&&p.push(q)}return k.values=p,k},c.polarToCartesian=function(a,b,c,d){var e=(d-90)*Math.PI/180;return{x:a+c*Math.cos(e),y:b+c*Math.sin(e)}},c.createChartRect=function(a,b,d){var e=!(!b.axisX&&!b.axisY),f=e?b.axisY.offset:0,g=e?b.axisX.offset:0,h=a.width()||c.quantity(b.width).value||0,i=a.height()||c.quantity(b.height).value||0,j=c.normalizePadding(b.chartPadding,d);h=Math.max(h,f+j.left+j.right),i=Math.max(i,g+j.top+j.bottom);var k={padding:j,width:function(){return this.x2-this.x1},height:function(){return this.y1-this.y2}};return e?("start"===b.axisX.position?(k.y2=j.top+g,k.y1=Math.max(i-j.bottom,k.y2+1)):(k.y2=j.top,k.y1=Math.max(i-j.bottom-g,k.y2+1)),"start"===b.axisY.position?(k.x1=j.left+f,k.x2=Math.max(h-j.right,k.x1+1)):(k.x1=j.left,k.x2=Math.max(h-j.right-f,k.x1+1))):(k.x1=j.left,k.x2=Math.max(h-j.right,k.x1+1),k.y2=j.top,k.y1=Math.max(i-j.bottom,k.y2+1)),k},c.createGrid=function(a,b,d,e,f,g,h,i){var j={};j[d.units.pos+"1"]=a,j[d.units.pos+"2"]=a,j[d.counterUnits.pos+"1"]=e,j[d.counterUnits.pos+"2"]=e+f;var k=g.elem("line",j,h.join(" "));i.emit("draw",c.extend({type:"grid",axis:d,index:b,group:g,element:k},j))},c.createGridBackground=function(a,b,c,d){var e=a.elem("rect",{x:b.x1,y:b.y2,width:b.width(),height:b.height()},c,!0);d.emit("draw",{type:"gridBackground",group:a,element:e})},c.createLabel=function(a,d,e,f,g,h,i,j,k,l,m){var n,o={};if(o[g.units.pos]=a+i[g.units.pos],o[g.counterUnits.pos]=i[g.counterUnits.pos],o[g.units.len]=d,o[g.counterUnits.len]=Math.max(0,h-10),l){var p=b.createElement("span");p.className=k.join(" "),p.setAttribute("xmlns",c.namespaces.xhtml),p.innerText=f[e],p.style[g.units.len]=Math.round(o[g.units.len])+"px",p.style[g.counterUnits.len]=Math.round(o[g.counterUnits.len])+"px",n=j.foreignObject(p,c.extend({style:"overflow: visible;"},o))}else n=j.elem("text",o,k.join(" ")).text(f[e]);m.emit("draw",c.extend({type:"label",axis:g,index:e,group:j,element:n,text:f[e]},o))},c.getSeriesOption=function(a,b,c){if(a.name&&b.series&&b.series[a.name]){var d=b.series[a.name];return d.hasOwnProperty(c)?d[c]:b[c]}return b[c]},c.optionsProvider=function(b,d,e){function f(b){var f=h;if(h=c.extend({},j),d)for(i=0;i=2&&a[h]<=a[h-2]&&(g=!0),g&&(f.push({pathCoordinates:[],valueData:[]}),g=!1),f[f.length-1].pathCoordinates.push(a[h],a[h+1]),f[f.length-1].valueData.push(b[h/2]));return f}}(window,document,a),function(a,b,c){"use strict";c.Interpolation={},c.Interpolation.none=function(a){var b={fillHoles:!1};return a=c.extend({},b,a),function(b,d){for(var e=new c.Svg.Path,f=!0,g=0;g1){var i=[];return h.forEach(function(a){i.push(f(a.pathCoordinates,a.valueData))}),c.Svg.Path.join(i)}if(b=h[0].pathCoordinates,g=h[0].valueData,b.length<=4)return c.Interpolation.none()(b,g);for(var j,k=(new c.Svg.Path).move(b[0],b[1],!1,g[0]),l=0,m=b.length;m-2*!j>l;l+=2){var n=[{x:+b[l-2],y:+b[l-1]},{x:+b[l],y:+b[l+1]},{x:+b[l+2],y:+b[l+3]},{x:+b[l+4],y:+b[l+5]}];j?l?m-4===l?n[3]={x:+b[0],y:+b[1]}:m-2===l&&(n[2]={x:+b[0],y:+b[1]},n[3]={x:+b[2],y:+b[3]}):n[0]={x:+b[m-2],y:+b[m-1]}:m-4===l?n[3]=n[2]:l||(n[0]={x:+b[l],y:+b[l+1]}),k.curve(d*(-n[0].x+6*n[1].x+n[2].x)/6+e*n[2].x,d*(-n[0].y+6*n[1].y+n[2].y)/6+e*n[2].y,d*(n[1].x+6*n[2].x-n[3].x)/6+e*n[2].x,d*(n[1].y+6*n[2].y-n[3].y)/6+e*n[2].y,n[2].x,n[2].y,!1,g[(l+2)/2])}return k}return c.Interpolation.none()([])}},c.Interpolation.monotoneCubic=function(a){var b={fillHoles:!1};return a=c.extend({},b,a),function d(b,e){var f=c.splitIntoSegments(b,e,{fillHoles:a.fillHoles,increasingX:!0});if(f.length){if(f.length>1){var g=[];return f.forEach(function(a){g.push(d(a.pathCoordinates,a.valueData))}),c.Svg.Path.join(g)}if(b=f[0].pathCoordinates,e=f[0].valueData,b.length<=4)return c.Interpolation.none()(b,e);var h,i,j=[],k=[],l=b.length/2,m=[],n=[],o=[],p=[];for(h=0;h0!=n[h]>0?m[h]=0:(m[h]=3*(p[h-1]+p[h])/((2*p[h]+p[h-1])/n[h-1]+(p[h]+2*p[h-1])/n[h]),isFinite(m[h])||(m[h]=0));for(i=(new c.Svg.Path).move(j[0],k[0],!1,e[0]),h=0;h1}).map(function(a){var b=a.pathElements[0],c=a.pathElements[a.pathElements.length-1];return a.clone(!0).position(0).remove(1).move(b.x,r).line(b.x,b.y).position(a.pathElements.length+1).line(c.x,r)}).forEach(function(c){var h=i.elem("path",{d:c.stringify()},a.classNames.area,!0);this.eventEmitter.emit("draw",{type:"area",values:b.normalized.series[g],path:c.clone(),series:f,seriesIndex:g,axisX:d,axisY:e,chartRect:j,index:g,group:i,element:h})}.bind(this))}}.bind(this)),this.eventEmitter.emit("created",{bounds:e.bounds,chartRect:j,axisX:d,axisY:e,svg:this.svg,options:a})}function e(a,b,d,e){c.Line["super"].constructor.call(this,a,b,f,c.extend({},f,d),e)}var f={axisX:{offset:30,position:"end",labelOffset:{x:0,y:0},showLabel:!0,showGrid:!0,labelInterpolationFnc:c.noop,type:void 0},axisY:{offset:40,position:"start",labelOffset:{x:0,y:0},showLabel:!0,showGrid:!0,labelInterpolationFnc:c.noop,type:void 0,scaleMinSpace:20,onlyInteger:!1},width:void 0,height:void 0,showLine:!0,showPoint:!0,showArea:!1,areaBase:0,lineSmooth:!0,showGridBackground:!1,low:void 0,high:void 0,chartPadding:{top:15,right:15,bottom:5,left:10},fullWidth:!1,reverseData:!1,classNames:{chart:"ct-chart-line",label:"ct-label",labelGroup:"ct-labels",series:"ct-series",line:"ct-line",point:"ct-point",area:"ct-area",grid:"ct-grid",gridGroup:"ct-grids",gridBackground:"ct-grid-background",vertical:"ct-vertical",horizontal:"ct-horizontal",start:"ct-start",end:"ct-end"}};c.Line=c.Base.extend({constructor:e,createChart:d})}(window,document,a),function(a,b,c){"use strict";function d(a){var b,d;a.distributeSeries?(b=c.normalizeData(this.data,a.reverseData,a.horizontalBars?"x":"y"),b.normalized.series=b.normalized.series.map(function(a){return[a]})):b=c.normalizeData(this.data,a.reverseData,a.horizontalBars?"x":"y"),this.svg=c.createSvg(this.container,a.width,a.height,a.classNames.chart+(a.horizontalBars?" "+a.classNames.horizontalBars:""));var e=this.svg.elem("g").addClass(a.classNames.gridGroup),g=this.svg.elem("g"),h=this.svg.elem("g").addClass(a.classNames.labelGroup);if(a.stackBars&&0!==b.normalized.series.length){var i=c.serialMap(b.normalized.series,function(){
return Array.prototype.slice.call(arguments).map(function(a){return a}).reduce(function(a,b){return{x:a.x+(b&&b.x)||0,y:a.y+(b&&b.y)||0}},{x:0,y:0})});d=c.getHighLow([i],a,a.horizontalBars?"x":"y")}else d=c.getHighLow(b.normalized.series,a,a.horizontalBars?"x":"y");d.high=+a.high||(0===a.high?0:d.high),d.low=+a.low||(0===a.low?0:d.low);var j,k,l,m,n,o=c.createChartRect(this.svg,a,f.padding);k=a.distributeSeries&&a.stackBars?b.normalized.labels.slice(0,1):b.normalized.labels,a.horizontalBars?(j=m=void 0===a.axisX.type?new c.AutoScaleAxis(c.Axis.units.x,b.normalized.series,o,c.extend({},a.axisX,{highLow:d,referenceValue:0})):a.axisX.type.call(c,c.Axis.units.x,b.normalized.series,o,c.extend({},a.axisX,{highLow:d,referenceValue:0})),l=n=void 0===a.axisY.type?new c.StepAxis(c.Axis.units.y,b.normalized.series,o,{ticks:k}):a.axisY.type.call(c,c.Axis.units.y,b.normalized.series,o,a.axisY)):(l=m=void 0===a.axisX.type?new c.StepAxis(c.Axis.units.x,b.normalized.series,o,{ticks:k}):a.axisX.type.call(c,c.Axis.units.x,b.normalized.series,o,a.axisX),j=n=void 0===a.axisY.type?new c.AutoScaleAxis(c.Axis.units.y,b.normalized.series,o,c.extend({},a.axisY,{highLow:d,referenceValue:0})):a.axisY.type.call(c,c.Axis.units.y,b.normalized.series,o,c.extend({},a.axisY,{highLow:d,referenceValue:0})));var p=a.horizontalBars?o.x1+j.projectValue(0):o.y1-j.projectValue(0),q=[];l.createGridAndLabels(e,h,this.supportsForeignObject,a,this.eventEmitter),j.createGridAndLabels(e,h,this.supportsForeignObject,a,this.eventEmitter),a.showGridBackground&&c.createGridBackground(e,o,a.classNames.gridBackground,this.eventEmitter),b.raw.series.forEach(function(d,e){var f,h,i=e-(b.raw.series.length-1)/2;f=a.distributeSeries&&!a.stackBars?l.axisLength/b.normalized.series.length/2:a.distributeSeries&&a.stackBars?l.axisLength/2:l.axisLength/b.normalized.series[e].length/2,h=g.elem("g"),h.attr({"ct:series-name":d.name,"ct:meta":c.serialize(d.meta)}),h.addClass([a.classNames.series,d.className||a.classNames.series+"-"+c.alphaNumerate(e)].join(" ")),b.normalized.series[e].forEach(function(g,k){var r,s,t,u;if(u=a.distributeSeries&&!a.stackBars?e:a.distributeSeries&&a.stackBars?0:k,r=a.horizontalBars?{x:o.x1+j.projectValue(g&&g.x?g.x:0,k,b.normalized.series[e]),y:o.y1-l.projectValue(g&&g.y?g.y:0,u,b.normalized.series[e])}:{x:o.x1+l.projectValue(g&&g.x?g.x:0,u,b.normalized.series[e]),y:o.y1-j.projectValue(g&&g.y?g.y:0,k,b.normalized.series[e])},l instanceof c.StepAxis&&(l.options.stretch||(r[l.units.pos]+=f*(a.horizontalBars?-1:1)),r[l.units.pos]+=a.stackBars||a.distributeSeries?0:i*a.seriesBarDistance*(a.horizontalBars?-1:1)),t=q[k]||p,q[k]=t-(p-r[l.counterUnits.pos]),void 0!==g){var v={};v[l.units.pos+"1"]=r[l.units.pos],v[l.units.pos+"2"]=r[l.units.pos],!a.stackBars||"accumulate"!==a.stackMode&&a.stackMode?(v[l.counterUnits.pos+"1"]=p,v[l.counterUnits.pos+"2"]=r[l.counterUnits.pos]):(v[l.counterUnits.pos+"1"]=t,v[l.counterUnits.pos+"2"]=q[k]),v.x1=Math.min(Math.max(v.x1,o.x1),o.x2),v.x2=Math.min(Math.max(v.x2,o.x1),o.x2),v.y1=Math.min(Math.max(v.y1,o.y2),o.y1),v.y2=Math.min(Math.max(v.y2,o.y2),o.y1);var w=c.getMetaData(d,k);s=h.elem("line",v,a.classNames.bar).attr({"ct:value":[g.x,g.y].filter(c.isNumeric).join(","),"ct:meta":c.serialize(w)}),this.eventEmitter.emit("draw",c.extend({type:"bar",value:g,index:k,meta:w,series:d,seriesIndex:e,axisX:m,axisY:n,chartRect:o,group:h,element:s},v))}}.bind(this))}.bind(this)),this.eventEmitter.emit("created",{bounds:j.bounds,chartRect:o,axisX:m,axisY:n,svg:this.svg,options:a})}function e(a,b,d,e){c.Bar["super"].constructor.call(this,a,b,f,c.extend({},f,d),e)}var f={axisX:{offset:30,position:"end",labelOffset:{x:0,y:0},showLabel:!0,showGrid:!0,labelInterpolationFnc:c.noop,scaleMinSpace:30,onlyInteger:!1},axisY:{offset:40,position:"start",labelOffset:{x:0,y:0},showLabel:!0,showGrid:!0,labelInterpolationFnc:c.noop,scaleMinSpace:20,onlyInteger:!1},width:void 0,height:void 0,high:void 0,low:void 0,referenceValue:0,chartPadding:{top:15,right:15,bottom:5,left:10},seriesBarDistance:15,stackBars:!1,stackMode:"accumulate",horizontalBars:!1,distributeSeries:!1,reverseData:!1,showGridBackground:!1,classNames:{chart:"ct-chart-bar",horizontalBars:"ct-horizontal-bars",label:"ct-label",labelGroup:"ct-labels",series:"ct-series",bar:"ct-bar",grid:"ct-grid",gridGroup:"ct-grids",gridBackground:"ct-grid-background",vertical:"ct-vertical",horizontal:"ct-horizontal",start:"ct-start",end:"ct-end"}};c.Bar=c.Base.extend({constructor:e,createChart:d})}(window,document,a),function(a,b,c){"use strict";function d(a,b,c){var d=b.x>a.x;return d&&"explode"===c||!d&&"implode"===c?"start":d&&"implode"===c||!d&&"explode"===c?"end":"middle"}function e(a){var b,e,f,h,i,j=c.normalizeData(this.data),k=[],l=a.startAngle;this.svg=c.createSvg(this.container,a.width,a.height,a.donut?a.classNames.chartDonut:a.classNames.chartPie),e=c.createChartRect(this.svg,a,g.padding),f=Math.min(e.width()/2,e.height()/2),i=a.total||j.normalized.series.reduce(function(a,b){return a+b},0);var m=c.quantity(a.donutWidth);"%"===m.unit&&(m.value*=f/100),f-=a.donut&&!a.donutSolid?m.value/2:0,h="outside"===a.labelPosition||a.donut&&!a.donutSolid?f:"center"===a.labelPosition?0:a.donutSolid?f-m.value/2:f/2,h+=a.labelOffset;var n={x:e.x1+e.width()/2,y:e.y2+e.height()/2},o=1===j.raw.series.filter(function(a){return a.hasOwnProperty("value")?0!==a.value:0!==a}).length;j.raw.series.forEach(function(a,b){k[b]=this.svg.elem("g",null,null)}.bind(this)),a.showLabel&&(b=this.svg.elem("g",null,null)),j.raw.series.forEach(function(e,g){if(0!==j.normalized.series[g]||!a.ignoreEmptyValues){k[g].attr({"ct:series-name":e.name}),k[g].addClass([a.classNames.series,e.className||a.classNames.series+"-"+c.alphaNumerate(g)].join(" "));var p=i>0?l+j.normalized.series[g]/i*360:0,q=Math.max(0,l-(0===g||o?0:.2));p-q>=359.99&&(p=q+359.99);var r,s,t,u=c.polarToCartesian(n.x,n.y,f,q),v=c.polarToCartesian(n.x,n.y,f,p),w=new c.Svg.Path(!a.donut||a.donutSolid).move(v.x,v.y).arc(f,f,0,p-l>180,0,u.x,u.y);a.donut?a.donutSolid&&(t=f-m.value,r=c.polarToCartesian(n.x,n.y,t,l-(0===g||o?0:.2)),s=c.polarToCartesian(n.x,n.y,t,p),w.line(r.x,r.y),w.arc(t,t,0,p-l>180,1,s.x,s.y)):w.line(n.x,n.y);var x=a.classNames.slicePie;a.donut&&(x=a.classNames.sliceDonut,a.donutSolid&&(x=a.classNames.sliceDonutSolid));var y=k[g].elem("path",{d:w.stringify()},x);if(y.attr({"ct:value":j.normalized.series[g],"ct:meta":c.serialize(e.meta)}),a.donut&&!a.donutSolid&&(y._node.style.strokeWidth=m.value+"px"),this.eventEmitter.emit("draw",{type:"slice",value:j.normalized.series[g],totalDataSum:i,index:g,meta:e.meta,series:e,group:k[g],element:y,path:w.clone(),center:n,radius:f,startAngle:l,endAngle:p}),a.showLabel){var z;z=1===j.raw.series.length?{x:n.x,y:n.y}:c.polarToCartesian(n.x,n.y,h,l+(p-l)/2);var A;A=j.normalized.labels&&!c.isFalseyButZero(j.normalized.labels[g])?j.normalized.labels[g]:j.normalized.series[g];var B=a.labelInterpolationFnc(A,g);if(B||0===B){var C=b.elem("text",{dx:z.x,dy:z.y,"text-anchor":d(n,z,a.labelDirection)},a.classNames.label).text(""+B);this.eventEmitter.emit("draw",{type:"label",index:g,group:b,element:C,text:""+B,x:z.x,y:z.y})}}l=p}}.bind(this)),this.eventEmitter.emit("created",{chartRect:e,svg:this.svg,options:a})}function f(a,b,d,e){c.Pie["super"].constructor.call(this,a,b,g,c.extend({},g,d),e)}var g={width:void 0,height:void 0,chartPadding:5,classNames:{chartPie:"ct-chart-pie",chartDonut:"ct-chart-donut",series:"ct-series",slicePie:"ct-slice-pie",sliceDonut:"ct-slice-donut",sliceDonutSolid:"ct-slice-donut-solid",label:"ct-label"},startAngle:0,total:void 0,donut:!1,donutSolid:!1,donutWidth:60,showLabel:!0,labelOffset:0,labelPosition:"inside",labelInterpolationFnc:c.noop,labelDirection:"neutral",reverseData:!1,ignoreEmptyValues:!1};c.Pie=c.Base.extend({constructor:f,createChart:e,determineAnchorPosition:d})}(window,document,a),a});

!function(a,b){"function"==typeof define&&define.amd?define("Chartist",[],function(){return a.Chartist=b()}):"object"==typeof module&&module.exports?module.exports=b():a.Chartist=b()}(this,function(){var a={version:"0.11.0"};return function(a,b,c){"use strict";c.namespaces={svg:"http://www.w3.org/2000/svg",xmlns:"http://www.w3.org/2000/xmlns/",xhtml:"http://www.w3.org/1999/xhtml",xlink:"http://www.w3.org/1999/xlink",ct:"http://gionkunz.github.com/chartist-js/ct"},c.noop=function(a){return a},c.alphaNumerate=function(a){return String.fromCharCode(97+a%26)},c.extend=function(a){var b,d,e;for(a=a||{},b=1;b":">",'"':""","'":"'"},c.serialize=function(a){return null===a||void 0===a?a:("number"==typeof a?a=""+a:"object"==typeof a&&(a=JSON.stringify({data:a})),Object.keys(c.escapingMap).reduce(function(a,b){return c.replaceAll(a,b,c.escapingMap[b])},a))},c.deserialize=function(a){if("string"!=typeof a)return a;a=Object.keys(c.escapingMap).reduce(function(a,b){return c.replaceAll(a,c.escapingMap[b],b)},a);try{a=JSON.parse(a),a=void 0!==a.data?a.data:a}catch(b){}return a},c.createSvg=function(a,b,d,e){var f;return b=b||"100%",d=d||"100%",Array.prototype.slice.call(a.querySelectorAll("svg")).filter(function(a){return a.getAttributeNS(c.namespaces.xmlns,"ct")}).forEach(function(b){a.removeChild(b)}),f=new c.Svg("svg").attr({width:b,height:d}).addClass(e),f._node.style.width=b,f._node.style.height=d,a.appendChild(f._node),f},c.normalizeData=function(a,b,d){var e,f={raw:a,normalized:{}};return f.normalized.series=c.getDataArray({series:a.series||[]},b,d),e=f.normalized.series.every(function(a){return a instanceof Array})?Math.max.apply(null,f.normalized.series.map(function(a){return a.length})):f.normalized.series.length,f.normalized.labels=(a.labels||[]).slice(),Array.prototype.push.apply(f.normalized.labels,c.times(Math.max(0,e-f.normalized.labels.length)).map(function(){return""})),b&&c.reverseData(f.normalized),f},c.safeHasProperty=function(a,b){return null!==a&&"object"==typeof a&&a.hasOwnProperty(b)},c.isDataHoleValue=function(a){return null===a||void 0===a||"number"==typeof a&&isNaN(a)},c.reverseData=function(a){a.labels.reverse(),a.series.reverse();for(var b=0;bf.high&&(f.high=c),h&&c0?f.low=0:(f.high=1,f.low=0)),f},c.isNumeric=function(a){return null!==a&&isFinite(a)},c.isFalseyButZero=function(a){return!a&&0!==a},c.getNumberOrUndefined=function(a){return c.isNumeric(a)?+a:void 0},c.isMultiValue=function(a){return"object"==typeof a&&("x"in a||"y"in a)},c.getMultiValue=function(a,b){return c.isMultiValue(a)?c.getNumberOrUndefined(a[b||"y"]):c.getNumberOrUndefined(a)},c.rho=function(a){function b(a,c){return a%c===0?c:b(c,a%c)}function c(a){return a*a+1}if(1===a)return a;var d,e=2,f=2;if(a%2===0)return 2;do e=c(e)%a,f=c(c(f))%a,d=b(Math.abs(e-f),a);while(1===d);return d},c.getBounds=function(a,b,d,e){function f(a,b){return a===(a+=b)&&(a*=1+(b>0?o:-o)),a}var g,h,i,j=0,k={high:b.high,low:b.low};k.valueRange=k.high-k.low,k.oom=c.orderOfMagnitude(k.valueRange),k.step=Math.pow(10,k.oom),k.min=Math.floor(k.low/k.step)*k.step,k.max=Math.ceil(k.high/k.step)*k.step,k.range=k.max-k.min,k.numberOfSteps=Math.round(k.range/k.step);var l=c.projectLength(a,k.step,k),m=l=d)k.step=1;else if(e&&n=d)k.step=n;else for(;;){if(m&&c.projectLength(a,k.step,k)<=d)k.step*=2;else{if(m||!(c.projectLength(a,k.step/2,k)>=d))break;if(k.step/=2,e&&k.step%1!==0){k.step*=2;break}}if(j++>1e3)throw new Error("Exceeded maximum number of iterations while optimizing scale step!")}var o=2.221e-16;for(k.step=Math.max(k.step,o),h=k.min,i=k.max;h+k.step<=k.low;)h=f(h,k.step);for(;i-k.step>=k.high;)i=f(i,-k.step);k.min=h,k.max=i,k.range=k.max-k.min;var p=[];for(g=k.min;g<=k.max;g=f(g,k.step)){var q=c.roundWithPrecision(g);q!==p[p.length-1]&&p.push(q)}return k.values=p,k},c.polarToCartesian=function(a,b,c,d){var e=(d-90)*Math.PI/180;return{x:a+c*Math.cos(e),y:b+c*Math.sin(e)}},c.createChartRect=function(a,b,d){var e=!(!b.axisX&&!b.axisY),f=e?b.axisY.offset:0,g=e?b.axisX.offset:0,h=a.width()||c.quantity(b.width).value||0,i=a.height()||c.quantity(b.height).value||0,j=c.normalizePadding(b.chartPadding,d);h=Math.max(h,f+j.left+j.right),i=Math.max(i,g+j.top+j.bottom);var k={padding:j,width:function(){return this.x2-this.x1},height:function(){return this.y1-this.y2}};return e?("start"===b.axisX.position?(k.y2=j.top+g,k.y1=Math.max(i-j.bottom,k.y2+1)):(k.y2=j.top,k.y1=Math.max(i-j.bottom-g,k.y2+1)),"start"===b.axisY.position?(k.x1=j.left+f,k.x2=Math.max(h-j.right,k.x1+1)):(k.x1=j.left,k.x2=Math.max(h-j.right-f,k.x1+1))):(k.x1=j.left,k.x2=Math.max(h-j.right,k.x1+1),k.y2=j.top,k.y1=Math.max(i-j.bottom,k.y2+1)),k},c.createGrid=function(a,b,d,e,f,g,h,i){var j={};j[d.units.pos+"1"]=a,j[d.units.pos+"2"]=a,j[d.counterUnits.pos+"1"]=e,j[d.counterUnits.pos+"2"]=e+f;var k=g.elem("line",j,h.join(" "));i.emit("draw",c.extend({type:"grid",axis:d,index:b,group:g,element:k},j))},c.createGridBackground=function(a,b,c,d){var e=a.elem("rect",{x:b.x1,y:b.y2,width:b.width(),height:b.height()},c,!0);d.emit("draw",{type:"gridBackground",group:a,element:e})},c.createLabel=function(a,d,e,f,g,h,i,j,k,l,m){var n,o={};if(o[g.units.pos]=a+i[g.units.pos],o[g.counterUnits.pos]=i[g.counterUnits.pos],o[g.units.len]=d,o[g.counterUnits.len]=Math.max(0,h-10),l){var p=b.createElement("span");p.className=k.join(" "),p.setAttribute("xmlns",c.namespaces.xhtml),p.innerText=f[e],p.style[g.units.len]=Math.round(o[g.units.len])+"px",p.style[g.counterUnits.len]=Math.round(o[g.counterUnits.len])+"px",n=j.foreignObject(p,c.extend({style:"overflow: visible;"},o))}else n=j.elem("text",o,k.join(" ")).text(f[e]);m.emit("draw",c.extend({type:"label",axis:g,index:e,group:j,element:n,text:f[e]},o))},c.getSeriesOption=function(a,b,c){if(a.name&&b.series&&b.series[a.name]){var d=b.series[a.name];return d.hasOwnProperty(c)?d[c]:b[c]}return b[c]},c.optionsProvider=function(b,d,e){function f(b){var f=h;if(h=c.extend({},j),d)for(i=0;i=2&&a[h]<=a[h-2]&&(g=!0),g&&(f.push({pathCoordinates:[],valueData:[]}),g=!1),f[f.length-1].pathCoordinates.push(a[h],a[h+1]),f[f.length-1].valueData.push(b[h/2]));return f}}(window,document,a),function(a,b,c){"use strict";c.Interpolation={},c.Interpolation.none=function(a){var b={fillHoles:!1};return a=c.extend({},b,a),function(b,d){for(var e=new c.Svg.Path,f=!0,g=0;g1){var i=[];return h.forEach(function(a){i.push(f(a.pathCoordinates,a.valueData))}),c.Svg.Path.join(i)}if(b=h[0].pathCoordinates,g=h[0].valueData,b.length<=4)return c.Interpolation.none()(b,g);for(var j,k=(new c.Svg.Path).move(b[0],b[1],!1,g[0]),l=0,m=b.length;m-2*!j>l;l+=2){var n=[{x:+b[l-2],y:+b[l-1]},{x:+b[l],y:+b[l+1]},{x:+b[l+2],y:+b[l+3]},{x:+b[l+4],y:+b[l+5]}];j?l?m-4===l?n[3]={x:+b[0],y:+b[1]}:m-2===l&&(n[2]={x:+b[0],y:+b[1]},n[3]={x:+b[2],y:+b[3]}):n[0]={x:+b[m-2],y:+b[m-1]}:m-4===l?n[3]=n[2]:l||(n[0]={x:+b[l],y:+b[l+1]}),k.curve(d*(-n[0].x+6*n[1].x+n[2].x)/6+e*n[2].x,d*(-n[0].y+6*n[1].y+n[2].y)/6+e*n[2].y,d*(n[1].x+6*n[2].x-n[3].x)/6+e*n[2].x,d*(n[1].y+6*n[2].y-n[3].y)/6+e*n[2].y,n[2].x,n[2].y,!1,g[(l+2)/2])}return k}return c.Interpolation.none()([])}},c.Interpolation.monotoneCubic=function(a){var b={fillHoles:!1};return a=c.extend({},b,a),function d(b,e){var f=c.splitIntoSegments(b,e,{fillHoles:a.fillHoles,increasingX:!0});if(f.length){if(f.length>1){var g=[];return f.forEach(function(a){g.push(d(a.pathCoordinates,a.valueData))}),c.Svg.Path.join(g)}if(b=f[0].pathCoordinates,e=f[0].valueData,b.length<=4)return c.Interpolation.none()(b,e);var h,i,j=[],k=[],l=b.length/2,m=[],n=[],o=[],p=[];for(h=0;h0!=n[h]>0?m[h]=0:(m[h]=3*(p[h-1]+p[h])/((2*p[h]+p[h-1])/n[h-1]+(p[h]+2*p[h-1])/n[h]),isFinite(m[h])||(m[h]=0));for(i=(new c.Svg.Path).move(j[0],k[0],!1,e[0]),h=0;h1}).map(function(a){var b=a.pathElements[0],c=a.pathElements[a.pathElements.length-1];return a.clone(!0).position(0).remove(1).move(b.x,r).line(b.x,b.y).position(a.pathElements.length+1).line(c.x,r)}).forEach(function(c){var h=i.elem("path",{d:c.stringify()},a.classNames.area,!0);this.eventEmitter.emit("draw",{type:"area",values:b.normalized.series[g],path:c.clone(),series:f,seriesIndex:g,axisX:d,axisY:e,chartRect:j,index:g,group:i,element:h})}.bind(this))}}.bind(this)),this.eventEmitter.emit("created",{bounds:e.bounds,chartRect:j,axisX:d,axisY:e,svg:this.svg,options:a})}function e(a,b,d,e){c.Line["super"].constructor.call(this,a,b,f,c.extend({},f,d),e)}var f={axisX:{offset:30,position:"end",labelOffset:{x:0,y:0},showLabel:!0,showGrid:!0,labelInterpolationFnc:c.noop,type:void 0},axisY:{offset:40,position:"start",labelOffset:{x:0,y:0},showLabel:!0,showGrid:!0,labelInterpolationFnc:c.noop,type:void 0,scaleMinSpace:20,onlyInteger:!1},width:void 0,height:void 0,showLine:!0,showPoint:!0,showArea:!1,areaBase:0,lineSmooth:!0,showGridBackground:!1,low:void 0,high:void 0,chartPadding:{top:15,right:15,bottom:5,left:10},fullWidth:!1,reverseData:!1,classNames:{chart:"ct-chart-line",label:"ct-label",labelGroup:"ct-labels",series:"ct-series",line:"ct-line",point:"ct-point",area:"ct-area",grid:"ct-grid",gridGroup:"ct-grids",gridBackground:"ct-grid-background",vertical:"ct-vertical",horizontal:"ct-horizontal",start:"ct-start",end:"ct-end"}};c.Line=c.Base.extend({constructor:e,createChart:d})}(window,document,a),function(a,b,c){"use strict";function d(a){var b,d;a.distributeSeries?(b=c.normalizeData(this.data,a.reverseData,a.horizontalBars?"x":"y"),b.normalized.series=b.normalized.series.map(function(a){return[a]})):b=c.normalizeData(this.data,a.reverseData,a.horizontalBars?"x":"y"),this.svg=c.createSvg(this.container,a.width,a.height,a.classNames.chart+(a.horizontalBars?" "+a.classNames.horizontalBars:""));var e=this.svg.elem("g").addClass(a.classNames.gridGroup),g=this.svg.elem("g"),h=this.svg.elem("g").addClass(a.classNames.labelGroup);if(a.stackBars&&0!==b.normalized.series.length){var i=c.serialMap(b.normalized.series,function(){
return Array.prototype.slice.call(arguments).map(function(a){return a}).reduce(function(a,b){return{x:a.x+(b&&b.x)||0,y:a.y+(b&&b.y)||0}},{x:0,y:0})});d=c.getHighLow([i],a,a.horizontalBars?"x":"y")}else d=c.getHighLow(b.normalized.series,a,a.horizontalBars?"x":"y");d.high=+a.high||(0===a.high?0:d.high),d.low=+a.low||(0===a.low?0:d.low);var j,k,l,m,n,o=c.createChartRect(this.svg,a,f.padding);k=a.distributeSeries&&a.stackBars?b.normalized.labels.slice(0,1):b.normalized.labels,a.horizontalBars?(j=m=void 0===a.axisX.type?new c.AutoScaleAxis(c.Axis.units.x,b.normalized.series,o,c.extend({},a.axisX,{highLow:d,referenceValue:0})):a.axisX.type.call(c,c.Axis.units.x,b.normalized.series,o,c.extend({},a.axisX,{highLow:d,referenceValue:0})),l=n=void 0===a.axisY.type?new c.StepAxis(c.Axis.units.y,b.normalized.series,o,{ticks:k}):a.axisY.type.call(c,c.Axis.units.y,b.normalized.series,o,a.axisY)):(l=m=void 0===a.axisX.type?new c.StepAxis(c.Axis.units.x,b.normalized.series,o,{ticks:k}):a.axisX.type.call(c,c.Axis.units.x,b.normalized.series,o,a.axisX),j=n=void 0===a.axisY.type?new c.AutoScaleAxis(c.Axis.units.y,b.normalized.series,o,c.extend({},a.axisY,{highLow:d,referenceValue:0})):a.axisY.type.call(c,c.Axis.units.y,b.normalized.series,o,c.extend({},a.axisY,{highLow:d,referenceValue:0})));var p=a.horizontalBars?o.x1+j.projectValue(0):o.y1-j.projectValue(0),q=[];l.createGridAndLabels(e,h,this.supportsForeignObject,a,this.eventEmitter),j.createGridAndLabels(e,h,this.supportsForeignObject,a,this.eventEmitter),a.showGridBackground&&c.createGridBackground(e,o,a.classNames.gridBackground,this.eventEmitter),b.raw.series.forEach(function(d,e){var f,h,i=e-(b.raw.series.length-1)/2;f=a.distributeSeries&&!a.stackBars?l.axisLength/b.normalized.series.length/2:a.distributeSeries&&a.stackBars?l.axisLength/2:l.axisLength/b.normalized.series[e].length/2,h=g.elem("g"),h.attr({"ct:series-name":d.name,"ct:meta":c.serialize(d.meta)}),h.addClass([a.classNames.series,d.className||a.classNames.series+"-"+c.alphaNumerate(e)].join(" ")),b.normalized.series[e].forEach(function(g,k){var r,s,t,u;if(u=a.distributeSeries&&!a.stackBars?e:a.distributeSeries&&a.stackBars?0:k,r=a.horizontalBars?{x:o.x1+j.projectValue(g&&g.x?g.x:0,k,b.normalized.series[e]),y:o.y1-l.projectValue(g&&g.y?g.y:0,u,b.normalized.series[e])}:{x:o.x1+l.projectValue(g&&g.x?g.x:0,u,b.normalized.series[e]),y:o.y1-j.projectValue(g&&g.y?g.y:0,k,b.normalized.series[e])},l instanceof c.StepAxis&&(l.options.stretch||(r[l.units.pos]+=f*(a.horizontalBars?-1:1)),r[l.units.pos]+=a.stackBars||a.distributeSeries?0:i*a.seriesBarDistance*(a.horizontalBars?-1:1)),t=q[k]||p,q[k]=t-(p-r[l.counterUnits.pos]),void 0!==g){var v={};v[l.units.pos+"1"]=r[l.units.pos],v[l.units.pos+"2"]=r[l.units.pos],!a.stackBars||"accumulate"!==a.stackMode&&a.stackMode?(v[l.counterUnits.pos+"1"]=p,v[l.counterUnits.pos+"2"]=r[l.counterUnits.pos]):(v[l.counterUnits.pos+"1"]=t,v[l.counterUnits.pos+"2"]=q[k]),v.x1=Math.min(Math.max(v.x1,o.x1),o.x2),v.x2=Math.min(Math.max(v.x2,o.x1),o.x2),v.y1=Math.min(Math.max(v.y1,o.y2),o.y1),v.y2=Math.min(Math.max(v.y2,o.y2),o.y1);var w=c.getMetaData(d,k);s=h.elem("line",v,a.classNames.bar).attr({"ct:value":[g.x,g.y].filter(c.isNumeric).join(","),"ct:meta":c.serialize(w)}),this.eventEmitter.emit("draw",c.extend({type:"bar",value:g,index:k,meta:w,series:d,seriesIndex:e,axisX:m,axisY:n,chartRect:o,group:h,element:s},v))}}.bind(this))}.bind(this)),this.eventEmitter.emit("created",{bounds:j.bounds,chartRect:o,axisX:m,axisY:n,svg:this.svg,options:a})}function e(a,b,d,e){c.Bar["super"].constructor.call(this,a,b,f,c.extend({},f,d),e)}var f={axisX:{offset:30,position:"end",labelOffset:{x:0,y:0},showLabel:!0,showGrid:!0,labelInterpolationFnc:c.noop,scaleMinSpace:30,onlyInteger:!1},axisY:{offset:40,position:"start",labelOffset:{x:0,y:0},showLabel:!0,showGrid:!0,labelInterpolationFnc:c.noop,scaleMinSpace:20,onlyInteger:!1},width:void 0,height:void 0,high:void 0,low:void 0,referenceValue:0,chartPadding:{top:15,right:15,bottom:5,left:10},seriesBarDistance:15,stackBars:!1,stackMode:"accumulate",horizontalBars:!1,distributeSeries:!1,reverseData:!1,showGridBackground:!1,classNames:{chart:"ct-chart-bar",horizontalBars:"ct-horizontal-bars",label:"ct-label",labelGroup:"ct-labels",series:"ct-series",bar:"ct-bar",grid:"ct-grid",gridGroup:"ct-grids",gridBackground:"ct-grid-background",vertical:"ct-vertical",horizontal:"ct-horizontal",start:"ct-start",end:"ct-end"}};c.Bar=c.Base.extend({constructor:e,createChart:d})}(window,document,a),function(a,b,c){"use strict";function d(a,b,c){var d=b.x>a.x;return d&&"explode"===c||!d&&"implode"===c?"start":d&&"implode"===c||!d&&"explode"===c?"end":"middle"}function e(a){var b,e,f,h,i,j=c.normalizeData(this.data),k=[],l=a.startAngle;this.svg=c.createSvg(this.container,a.width,a.height,a.donut?a.classNames.chartDonut:a.classNames.chartPie),e=c.createChartRect(this.svg,a,g.padding),f=Math.min(e.width()/2,e.height()/2),i=a.total||j.normalized.series.reduce(function(a,b){return a+b},0);var m=c.quantity(a.donutWidth);"%"===m.unit&&(m.value*=f/100),f-=a.donut&&!a.donutSolid?m.value/2:0,h="outside"===a.labelPosition||a.donut&&!a.donutSolid?f:"center"===a.labelPosition?0:a.donutSolid?f-m.value/2:f/2,h+=a.labelOffset;var n={x:e.x1+e.width()/2,y:e.y2+e.height()/2},o=1===j.raw.series.filter(function(a){return a.hasOwnProperty("value")?0!==a.value:0!==a}).length;j.raw.series.forEach(function(a,b){k[b]=this.svg.elem("g",null,null)}.bind(this)),a.showLabel&&(b=this.svg.elem("g",null,null)),j.raw.series.forEach(function(e,g){if(0!==j.normalized.series[g]||!a.ignoreEmptyValues){k[g].attr({"ct:series-name":e.name}),k[g].addClass([a.classNames.series,e.className||a.classNames.series+"-"+c.alphaNumerate(g)].join(" "));var p=i>0?l+j.normalized.series[g]/i*360:0,q=Math.max(0,l-(0===g||o?0:.2));p-q>=359.99&&(p=q+359.99);var r,s,t,u=c.polarToCartesian(n.x,n.y,f,q),v=c.polarToCartesian(n.x,n.y,f,p),w=new c.Svg.Path(!a.donut||a.donutSolid).move(v.x,v.y).arc(f,f,0,p-l>180,0,u.x,u.y);a.donut?a.donutSolid&&(t=f-m.value,r=c.polarToCartesian(n.x,n.y,t,l-(0===g||o?0:.2)),s=c.polarToCartesian(n.x,n.y,t,p),w.line(r.x,r.y),w.arc(t,t,0,p-l>180,1,s.x,s.y)):w.line(n.x,n.y);var x=a.classNames.slicePie;a.donut&&(x=a.classNames.sliceDonut,a.donutSolid&&(x=a.classNames.sliceDonutSolid));var y=k[g].elem("path",{d:w.stringify()},x);if(y.attr({"ct:value":j.normalized.series[g],"ct:meta":c.serialize(e.meta)}),a.donut&&!a.donutSolid&&(y._node.style.strokeWidth=m.value+"px"),this.eventEmitter.emit("draw",{type:"slice",value:j.normalized.series[g],totalDataSum:i,index:g,meta:e.meta,series:e,group:k[g],element:y,path:w.clone(),center:n,radius:f,startAngle:l,endAngle:p}),a.showLabel){var z;z=1===j.raw.series.length?{x:n.x,y:n.y}:c.polarToCartesian(n.x,n.y,h,l+(p-l)/2);var A;A=j.normalized.labels&&!c.isFalseyButZero(j.normalized.labels[g])?j.normalized.labels[g]:j.normalized.series[g];var B=a.labelInterpolationFnc(A,g);if(B||0===B){var C=b.elem("text",{dx:z.x,dy:z.y,"text-anchor":d(n,z,a.labelDirection)},a.classNames.label).text(""+B);this.eventEmitter.emit("draw",{type:"label",index:g,group:b,element:C,text:""+B,x:z.x,y:z.y})}}l=p}}.bind(this)),this.eventEmitter.emit("created",{chartRect:e,svg:this.svg,options:a})}function f(a,b,d,e){c.Pie["super"].constructor.call(this,a,b,g,c.extend({},g,d),e)}var g={width:void 0,height:void 0,chartPadding:5,classNames:{chartPie:"ct-chart-pie",chartDonut:"ct-chart-donut",series:"ct-series",slicePie:"ct-slice-pie",sliceDonut:"ct-slice-donut",sliceDonutSolid:"ct-slice-donut-solid",label:"ct-label"},startAngle:0,total:void 0,donut:!1,donutSolid:!1,donutWidth:60,showLabel:!0,labelOffset:0,labelPosition:"inside",labelInterpolationFnc:c.noop,labelDirection:"neutral",reverseData:!1,ignoreEmptyValues:!1};c.Pie=c.Base.extend({constructor:f,createChart:e,determineAnchorPosition:d})}(window,document,a),a});
@/lua/ge/extensions/gameplay/rally/loop/speedingDetector.lua

function C:update(dtSim, limitKph, strictMode)
  self.currentLimitKph = limitKph
@/lua/ge/extensions/editor/dragRaceEditor/strips.lua

        if transformsState.waypoint:update(mouseInfo) then
          selectedWaypoint.transform.position = {x = transformsState.waypoint.pos.x, y = transformsState.waypoint.pos.y, z = transformsState.waypoint.pos.z}

      if transformsState.boundary:update(mouseInfo) then
        lane.boundary.transform.position = {x = transformsState.boundary.pos.x, y = transformsState.boundary.pos.y, z = transformsState.boundary.pos.z}
@/lua/ge/extensions/editor/util/editorElementHelper.lua
  e.transform.switchRotationForMouse = true
  if e.transform:update(mouseInfo) then
    ctd[e.fieldNamePos] = e.hasPos and (e.transform.pos:toTable())

  if e.lapConfig:update(mouseInfo) then
    ret = true
@/ui/ui-vue/src/modules/vehicleConfig/parts/search.js
      // update history if there are some results
      this.history.update()
    } else {
@/lua/vehicle/extensions/api.lua
local function updateGFX()
    httpJsonServer.update()
end
@/lua/ge/extensions/core/cameraModes/unicycle.lua

function C:update(data)
  local dt = data.dtSim

  --self.manualzoom:update(data) -- disable for now, freeing up buttons on gamepad
@/lua/common/jbeam/loader.lua
  profilerPushEvent('jbeam/loader')
  if loadingProgress then loadingProgress:update(0.1, 'Reading files...') end
  local ioCtx = jbeamIO.startLoading(vehicleDirectories)

  if loadingProgress then loadingProgress:update(0.2, 'Finding parts...') end
  local vehicle, unifyJournal, unifyJournalC, chosenPartsTree, slotPartMap, activePartsData, activeParts = jbeamSlotSystem.findParts(ioCtx, vehicleConfig)

  if loadingProgress then loadingProgress:update(0.21, 'Applying variables...') end
  local allVariables = jbeamVariables.processParts(vehicle, unifyJournal, vehicleConfig, vars)

  if loadingProgress then loadingProgress:update(0.22, 'Unifying parts...') end
  if not jbeamSlotSystem.unifyPartJournal(ioCtx, unifyJournal) then return end

  if loadingProgress then loadingProgress:update(0.3, 'Assembling tables ...') end
  if not jbeamTableSchema.process(vehicle) then

  if loadingProgress then loadingProgress:update(0.4, 'Linking things together ...') end
  -- a) this creates a list of things to be linked AND deletes unlinkable things

  if loadingProgress then loadingProgress:update(0.5, 'Inspecting variables ...') end
  jbeamNodeBeam.process(vehicle)

  if loadingProgress then loadingProgress:update(0.6, 'Adding wheels ...') end
  jbeamWheels.processWheels(vehicle)

  if loadingProgress then loadingProgress:update(0.7, 'Doing some things.') end
  jbeamAssorted.process(vehicle) -- after resolveGroupLinks

  if loadingProgress then loadingProgress:update(0.9, 'Optimizing result') end
  if not jbeamOptimization.process(vehicle, debugEnabled) then

    if loadingProgress then loadingProgress:update(0.8, 'Loading input events...') end
    jbeamEvents.process(objID, vehicleObj, vehicleBundle.vdata)

    if loadingProgress then loadingProgress:update(0.8, 'Adding the 3D meshes ...') end
    jbeamLicensePlatesSkins.process(objID, vehicleObj, vehicleBundle.config, vehicleBundle.vdata.activePartsData)
  if loadingProgress then
    loadingProgress:update(1, 'Vehicle loading done')
    LoadingManager:pop(loadingProgress)
@/lua/vehicle/controller/tech/GPS.lua
-- Physics step update for this GPS sensor instance.
local function update(dtSim)
  -- Cycle the physics update timer. If we are not ready for a physics step update, leave immediately.
@/lua/ge/extensions/core/cameraModes/orbit.lua

function C:update(data)
  data.res.collisionCompatible = true
  data.res.targetPos:set(targetPos)
  self.collision:update(data)
  return true
@/lua/ge/extensions/util/nodeStream.lua

  server:update()
end
@/inspector/Views/StyleOriginView.js

    update(style)
    {
@/lua/ge/main.lua
function requestGeluaProfile()
  geluaProfiler = LuaProfiler("update() and luaPreRender() gelua function calls")
  extensions.setProfiler(geluaProfiler)
-- this function is called after input and before physics
function update(dtReal, dtSim, dtRaw)
  if geluaProfiler then geluaProfiler:start() end
  extensions.core_input_bindings.updateGFX(dtRaw)
  simTimeAuthority.update(dtReal)
  if geluaProfiler then geluaProfiler:add("update beginning") end
  end
  perf.update()
@/lua/ge/extensions/editor/gen/mesh.lua

local function update(tmesh)
	local amesh = {}
@/ui/modules/scenariocontrol/scenariocontrol.js
          for (var i = 0; i < data.length; i += 1) {
            data[i].state.update(delta)
            data[i].state.apply(data[i].skeleton)
@/inspector/Views/EventBreakpointPopover.js

                this._suggestionsView.update(this._currentCompletions);
                this._showSuggestionsView();

        this.update();
@/inspector/Views/DOMTreeOutline.js

        this.update();
    }

        this.update();
    }

    update()
    {
@/lua/console/simtest.lua
        hp = HighPerfTimer()
        BeamEngine:update(1/2000, 1/2000)
        print(" - "..hp:stop().." ms")
@/lua/ge/extensions/ui/ambientSound.lua
]]
local function update(dt)
  for i=1,#soundStreams do
@/inspector/Views/SpreadsheetCSSStyleDeclarationEditor.js
                propertyView.property.commentOut(disabled);
                propertyView.update();
            }
@/lua/ge/extensions/core/cameraModes/chase.lua
local rot = vec3()
function C:update(data)
  data.res.collisionCompatible = true

  self.collision:update(data)
  return true
@/inspector/External/three.js/three.js

        function update( attribute, bufferType ) {

                    objects.update( boxMesh );

                    objects.update( planeMesh );

            info.update( count, mode );

            info.update( count, mode, geometry.maxInstancedCount );

        function update( geometry ) {

                attributes.update( index, gl.ELEMENT_ARRAY_BUFFER );

                attributes.update( geometryAttributes[ name ], gl.ARRAY_BUFFER );

                    attributes.update( array[ i ], gl.ARRAY_BUFFER );

            attributes.update( attribute, gl.ELEMENT_ARRAY_BUFFER );

            info.update( count, mode );

            info.update( count, mode, geometry.maxInstancedCount );

        function update( count, mode, instanceCount ) {

        function update( object, geometry, material, program ) {

        function update( object ) {

                geometries.update( buffergeometry );

        function update( object, key, value ) {

                    shadow.update( light );

                    var geometry = _objects.update( object );
                    var material = object.material;
                _videoTextures[ id ] = frame;
                texture.update();

                morphtargets.update( object, geometry, material, program );

                        object.skeleton.update();

                        var geometry = objects.update( object );
                        var material = object.material;

                properties.update( material, 'lightsHash', lights.state.hash );
                programChange = false;

            return function update( camera ) {

            return function update() {

            return function update( camera ) {

        this.update();

        return function update() {

        this.update();

        return function update() {

        this.update();

        this.update();

        this.update();

        return function update() {
        this.matrixAutoUpdate = false;
        this.update();

        return function update() {

        this.update();

        return function update() {

        this.update();

        return function update() {

        this.update();

        return function update( object ) {

                console.warn( 'THREE.BoxHelper: .update() has no longer arguments.' );
        this.object = object;
        this.update();

        console.error( 'THREE.SkeletonHelper: update() no longer needs to be called.' );

        console.warn( 'THREE.CubeCamera: .updateCubeMap() is now .update().' );
        return this.update( renderer, scene );
        console.warn( 'THREE.CubeCamera: .updateCubeMap() is now .update().' );
        return this.update( renderer, scene );
@/lua/ge/extensions/gameplay/markers/invisibleTrigger.lua
-- called every frame to update the visuals.
function C:update(data)
--[[
@/lua/console/resave-pcs.lua
          be:queueLuaCommand("partmgmt.saveLocal('" .. config .. "')")
          BeamEngine:update(2, 2)
          configCount = configCount + 1
@/lua/ge/extensions/core/cameraModes/path.lua

function C:update(data)
  if self.customData and self.customData.useJsonVersion then
@/lua/ge/extensions/core/cameraModes/driver.lua

function C:update(data)
  local carPos = data.pos

  local notifiedFov = self.manualzoom:update(data)
  if notifiedFov then
@/inspector/Views/ObjectTreeView.js

        this.update();
    }

    update()
    {
@/lua/ge/extensions/scenario/raceMarkers/noneMarker.lua
-- called every frame to update the visuals.
function C:update()
    --local color = ColorF(0.91,0.05,0.48,0.5)
@/lua/ge/extensions/scenario/raceMarkers/overhead.lua
-- called every frame to update the visuals.
function C:update(dt, dtSim)
  self.colorTimer = self.colorTimer + dt

  self:update(0,0)
@/lua/vehicle/controller/tech/advancedIMU.lua
-- Physics step update for this sensor instance.
local function update(dtSim)
  -- Manage the update timer. [We cycle the timer to ensure update regularity.]
@/lua/ge/extensions/core/cameraModes/pacenoteOrbit.lua

function C:update(data)
  data.res.collisionCompatible = true
@/inspector/Views/DatabaseTableContentView.js

        this.update();
    }

    update()
    {
    {
        this.update();
    }
@/inspector/Views/TypeTokenView.js

    update(typeDescription)
    {
@/ui/ui-vue/src/services/uiNavTracker.js
  let raf
  function update(eventName) {
    // const idx = trackedEvents.value.findIndex(e => e.name === eventName)
      instance.active = parseActive(options?.active, eventName)
      update(eventName)
      return
    }
    update(eventName)
  }

    update(eventName)
  }
    DEBUG && Logger.log("removed event", eventName, trackedInstances[eventName].length, element)
    update(eventName)
    addHelper(unblockedEvents, unblockedInstances, eventName, ownerId, () => {
      update(eventName)
      updateBlocklist()
    removeHelper(unblockedEvents, unblockedInstances, eventName, ownerId, () => {
      update(eventName)
      updateBlocklist()
@/ui/ui-vue/src/common/directives/BngLazyImage.js

function update(el, { arg, value }) {
  const data = {
@/ui/ui-vue/src/common/directives/BngVisibility.js

function update(el, value) {
  const data = observed.get(el)
    })
    update(el, value)
  },
  updated(el, { value }) {
    update(el, value)
  },
@/lua/ge/extensions/util/wsTest.lua
  end
  server:update()
end
@/lua/ge/extensions/scenario/raceMarkers/cylinderMarker.lua
-- called every frame to update the visuals.
function C:update()
  if not self.visible then return end
  self.currentColor = ColorF(self.color[1],self.color[2],self.color[3],1)
  self:update(0,0)
end
@/lua/vehicle/powertrain.lua

local function update(dt)
  M.torqueReactionCoefs, torqueReactionCoefs2 = torqueReactionCoefs2, M.torqueReactionCoefs
@/lua/ge/extensions/core/cameraModes/fallback.lua

function C:update(data)
  data.res.pos = data.res.pos or data.pos            -- camera position
@/lua/ge/extensions/gameplay/missions/progress.lua

  -- update (if application quits before finishing, we should replace saveFile with backupFile)
  jsonWriteFile(saveFile, mission.saveData, true)
@/lua/ge/extensions/editor/util/transformUtil.lua

  -- which elements should show when you call update()
  self.showWidgets = true

function C:update(mouseInfo)
  --local gizmo = self:gizmo()
@/inspector/Models/CSSProperty.js

        this.update(text, name, value, priority, enabled, overridden, implicit, anonymous, valid, styleSheetTextRange, true);
    }

    update(text, name, value, priority, enabled, overridden, implicit, anonymous, valid, styleSheetTextRange, dontFireEvents)
    {
@/lua/vehicle/thrusters.lua

local function update()
  -- node1 is source, node2 is destination
@/lua/ge/extensions/gameplay/markers/invisibleMarker.lua
-- called every frame to update the visuals.
function C:update(data)
@/lua/ge/extensions/scenario/raceMarkers/attention.lua
-- called every frame to update the visuals.
function C:update(dt, dtSim)
  self.colorTimer = self.colorTimer + dt

  self:update(0,0)
@/lua/ge/extensions/core/cameraModes/autozoom.lua
end
function C:update(data)
  local distance = data.res.targetPos:distance(data.res.pos)
@/lua/ge/extensions/core/cameraModes/bigMap.lua

function C:update(data)
  if self.initialCamData and self.firstUpdate then
  local zoomBefore = self.manualzoom.fov
  self.manualzoom:update(data)
  local zoomAfter = self.manualzoom.fov
@/lua/vehicle/controller/tech/powertrainSensor.lua
-- Physics step update for this powertrain sensor instance.
local function update(dtSim)
  -- Cycle the physics update timer. If we are not ready for a physics step update, leave immediately.
@/lua/ge/extensions/gameplay/markers/crawlMarker.lua

function C:update(data)
  if not self.visible or not data.veh then return end
@/lua/vehicle/extensions/vehicleStatsLogger.lua

local function update()
  updateDeviceStates()
    secUntilNextUpdate = settings.updatePeriod
    update()
  else
@/inspector/Views/ScopeChainDetailsSidebarPanel.js
                previousHeight = height;
                popover.update(false);
            }
            this._codeMirror.focus();
            popover.update();
        }, 0);
@/ui/lib/ext/vue3/vue.global.js
          isHmrUpdating = true;
          instance.update();
          isHmrUpdating = false;
                          state.isLeaving = false;
                          instance.update();
                      };
                  // instance.update is the reactive effect runner.
                  instance.update();
              }
@/ui/ui-vue/src/services/popup.js
    }
    popup.progress.update(~~(((seconds - remaining) * 100) / seconds), makeRemainingText(remaining))
  }
@/lua/common/guihooks.lua
local function checkStreamsAndVehicle()
  streams.update()
@/lua/vehicle/controller/tech/cosimulationCoupling.lua
-- Update callback.
local function update(dt)
    if csvSendData == nil then
        log('E', logTag, 'Failed to initialize csvSendData in update(). Skipping CSV logging.')
        return
    else
        log('I', logTag, 'csvSendData successfully created during update().')
    end
@/inspector/Proxies/HeapSnapshotProxy.js

        this.update(() => {
            this.dispatchEventToListeners(WI.HeapSnapshotProxy.Event.CollectedNodes, event.data);

    update(callback)
    {
@/lua/ge/extensions/gameplay/markers/missionMarker.lua
-- called every frame to update the visuals.
function C:update(data)
  if not self.visible then return end
@/lua/common/utils/heatmap.lua
-- executed every frame, also when not rendering 3d in the menu
local function update()
  if not heatSVG then return end
@/inspector/Views/SpreadsheetStyleProperty.js

        this.update();
        property.addEventListener(WI.CSSProperty.Event.OverriddenStatusChanged, this.updateStatus, this);

    update()
    {
        this._property.commentOut(this.property.enabled);
        this.update();
    }
@/lua/ge/extensions/editor/missionEditor/startTrigger.lua
  extensions.editor_missionEditor.getMissionTypeWindow():getCurrentEditorHelper():updateMouseInfo(self.mission)
  if transformHelper:update(extensions.editor_missionEditor.getMissionTypeWindow():getCurrentEditorHelper().mouseInfo) then
    self.mission.startTrigger.pos = transformHelper.pos:toTable()
@/lua/vehicle/controller/tech/idealRADARSensor.lua
-- The ideal RADAR sensor physics step update callback.
local function update(dtSim)
@/lua/ge/extensions/editor/buildingEditor.lua
		if d.obj and d.obj.isactive and d.obj.update then
			d.obj.update()
		end
@/lua/ge/extensions/editor/sitesEditor/parkingSpots.lua
  self.current = ps
  if transformUtil:update(mouseInfo) then -- if change was detected
    if transformUtil.isDragging then
@/ui/lib/ext/vue3/vue.global.prod.js
var Vue=function(e){"use strict";function t(e,t){const n=Object.create(null),o=e.split(",");for(let r=0;r!!n[e.toLowerCase()]:e=>!!n[e]}const n=t("Infinity,undefined,NaN,isFinite,isNaN,parseFloat,parseInt,decodeURI,decodeURIComponent,encodeURI,encodeURIComponent,Math,Number,Date,Array,Object,Boolean,String,RegExp,Map,Set,JSON,Intl,BigInt"),o=t("itemscope,allowfullscreen,formnovalidate,ismap,nomodule,novalidate,readonly");function r(e){if(T(e)){const t={};for(let n=0;n{if(e){const n=e.split(i);n.length>1&&(t[n[0].trim()]=n[1].trim())}})),t}function c(e){let t="";if(A(e))t=e;else if(T(e))for(let n=0;nf(e,t)))}const h=(e,t)=>N(t)?{[`Map(${t.size})`]:[...t.entries()].reduce(((e,[t,n])=>(e[`${t} =>`]=n,e)),{})}:E(t)?{[`Set(${t.size})`]:[...t.values()]}:!I(t)||T(t)||P(t)?t:String(t),m={},g=[],v=()=>{},y=()=>!1,b=/^on[^a-z]/,_=e=>b.test(e),x=e=>e.startsWith("onUpdate:"),S=Object.assign,C=(e,t)=>{const n=e.indexOf(t);n>-1&&e.splice(n,1)},k=Object.prototype.hasOwnProperty,w=(e,t)=>k.call(e,t),T=Array.isArray,N=e=>"[object Map]"===R(e),E=e=>"[object Set]"===R(e),$=e=>e instanceof Date,F=e=>"function"==typeof e,A=e=>"string"==typeof e,M=e=>"symbol"==typeof e,I=e=>null!==e&&"object"==typeof e,O=e=>I(e)&&F(e.then)&&F(e.catch),B=Object.prototype.toString,R=e=>B.call(e),P=e=>"[object Object]"===R(e),V=e=>A(e)&&"NaN"!==e&&"-"!==e[0]&&""+parseInt(e,10)===e,L=t(",key,ref,onVnodeBeforeMount,onVnodeMounted,onVnodeBeforeUpdate,onVnodeUpdated,onVnodeBeforeUnmount,onVnodeUnmounted"),j=e=>{const t=Object.create(null);return n=>t[n]||(t[n]=e(n))},U=/-(\w)/g,H=j((e=>e.replace(U,((e,t)=>t?t.toUpperCase():"")))),D=/\B([A-Z])/g,z=j((e=>e.replace(D,"-$1").toLowerCase())),W=j((e=>e.charAt(0).toUpperCase()+e.slice(1))),K=j((e=>e?`on${W(e)}`:"")),G=(e,t)=>e!==t&&(e==e||t==t),q=(e,t)=>{for(let n=0;n{Object.defineProperty(e,t,{configurable:!0,enumerable:!1,value:n})},Z=e=>{const t=parseFloat(e);return isNaN(t)?e:t},Q=new WeakMap,X=[];let Y;const ee=Symbol(""),te=Symbol("");function ne(e,t=m){(function(e){return e&&!0===e._isEffect})(e)&&(e=e.raw);const n=function(e,t){const n=function(){if(!n.active)return t.scheduler?void 0:e();if(!X.includes(n)){se(n);try{return le.push(ie),ie=!0,X.push(n),Y=n,e()}finally{X.pop(),ae(),Y=X[X.length-1]}}};return n.id=re++,n.allowRecurse=!!t.allowRecurse,n._isEffect=!0,n.active=!0,n.raw=e,n.deps=[],n.options=t,n}(e,t);return t.lazy||n(),n}function oe(e){e.active&&(se(e),e.options.onStop&&e.options.onStop(),e.active=!1)}let re=0;function se(e){const{deps:t}=e;if(t.length){for(let n=0;n{e&&e.forEach((e=>{(e!==Y||e.allowRecurse)&&l.add(e)}))};if("clear"===t)i.forEach(c);else if("length"===n&&T(e))i.forEach(((e,t)=>{("length"===t||t>=o)&&c(e)}));else switch(void 0!==n&&c(i.get(n)),t){case"add":T(e)?V(n)&&c(i.get("length")):(c(i.get(ee)),N(e)&&c(i.get(te)));break;case"delete":T(e)||(c(i.get(ee)),N(e)&&c(i.get(te)));break;case"set":N(e)&&c(i.get(ee))}l.forEach((e=>{e.options.scheduler?e.options.scheduler(e):e()}))}const fe=t("__proto__,__v_isRef,__isVue"),de=new Set(Object.getOwnPropertyNames(Symbol).map((e=>Symbol[e])).filter(M)),he=be(),me=be(!1,!0),ge=be(!0),ve=be(!0,!0),ye={};function be(e=!1,t=!1){return function(n,o,r){if("__v_isReactive"===o)return!e;if("__v_isReadonly"===o)return e;if("__v_raw"===o&&r===(e?t?Qe:Ze:t?Je:qe).get(n))return n;const s=T(n);if(!e&&s&&w(ye,o))return Reflect.get(ye,o,r);const i=Reflect.get(n,o,r);if(M(o)?de.has(o):fe(o))return i;if(e||ue(n,0,o),t)return i;if(ct(i)){return!s||!V(o)?i.value:i}return I(i)?e?tt(i):Ye(i):i}}["includes","indexOf","lastIndexOf"].forEach((e=>{const t=Array.prototype[e];ye[e]=function(...e){const n=it(this);for(let t=0,r=this.length;t{const t=Array.prototype[e];ye[e]=function(...e){ce();const n=t.apply(this,e);return ae(),n}}));function _e(e=!1){return function(t,n,o,r){let s=t[n];if(!e&&(o=it(o),s=it(s),!T(t)&&ct(s)&&!ct(o)))return s.value=o,!0;const i=T(t)&&V(n)?Number(n)!0,deleteProperty:(e,t)=>!0},Ce=S({},xe,{get:me,set:_e(!0)}),ke=S({},Se,{get:ve}),we=e=>I(e)?Ye(e):e,Te=e=>I(e)?tt(e):e,Ne=e=>e,Ee=e=>Reflect.getPrototypeOf(e);function $e(e,t,n=!1,o=!1){const r=it(e=e.__v_raw),s=it(t);t!==s&&!n&&ue(r,0,t),!n&&ue(r,0,s);const{has:i}=Ee(r),l=o?Ne:n?Te:we;return i.call(r,t)?l(e.get(t)):i.call(r,s)?l(e.get(s)):void 0}function Fe(e,t=!1){const n=this.__v_raw,o=it(n),r=it(e);return e!==r&&!t&&ue(o,0,e),!t&&ue(o,0,r),e===r?n.has(e):n.has(e)||n.has(r)}function Ae(e,t=!1){return e=e.__v_raw,!t&&ue(it(e),0,ee),Reflect.get(e,"size",e)}function Me(e){e=it(e);const t=it(this);return Ee(t).has.call(t,e)||(t.add(e),pe(t,"add",e,e)),this}function Ie(e,t){t=it(t);const n=it(this),{has:o,get:r}=Ee(n);let s=o.call(n,e);s||(e=it(e),s=o.call(n,e));const i=r.call(n,e);return n.set(e,t),s?G(t,i)&&pe(n,"set",e,t):pe(n,"add",e,t),this}function Oe(e){const t=it(this),{has:n,get:o}=Ee(t);let r=n.call(t,e);r||(e=it(e),r=n.call(t,e)),o&&o.call(t,e);const s=t.delete(e);return r&&pe(t,"delete",e,void 0),s}function Be(){const e=it(this),t=0!==e.size,n=e.clear();return t&&pe(e,"clear",void 0,void 0),n}function Re(e,t){return function(n,o){const r=this,s=r.__v_raw,i=it(s),l=t?Ne:e?Te:we;return!e&&ue(i,0,ee),s.forEach(((e,t)=>n.call(o,l(e),l(t),r)))}}function Pe(e,t,n){return function(...o){const r=this.__v_raw,s=it(r),i=N(s),l="entries"===e||e===Symbol.iterator&&i,c="keys"===e&&i,a=r[e](...o),u=n?Ne:t?Te:we;return!t&&ue(s,0,c?te:ee),{next(){const{value:e,done:t}=a.next();return t?{value:e,done:t}:{value:l?[u(e[0]),u(e[1])]:u(e),done:t}},[Symbol.iterator](){return this}}}}function Ve(e){return function(...t){return"delete"!==e&&this}}const Le={get(e){return $e(this,e)},get size(){return Ae(this)},has:Fe,add:Me,set:Ie,delete:Oe,clear:Be,forEach:Re(!1,!1)},je={get(e){return $e(this,e,!1,!0)},get size(){return Ae(this)},has:Fe,add:Me,set:Ie,delete:Oe,clear:Be,forEach:Re(!1,!0)},Ue={get(e){return $e(this,e,!0)},get size(){return Ae(this,!0)},has(e){return Fe.call(this,e,!0)},add:Ve("add"),set:Ve("set"),delete:Ve("delete"),clear:Ve("clear"),forEach:Re(!0,!1)},He={get(e){return $e(this,e,!0,!0)},get size(){return Ae(this,!0)},has(e){return Fe.call(this,e,!0)},add:Ve("add"),set:Ve("set"),delete:Ve("delete"),clear:Ve("clear"),forEach:Re(!0,!0)};function De(e,t){const n=t?e?He:je:e?Ue:Le;return(t,o,r)=>"__v_isReactive"===o?!e:"__v_isReadonly"===o?e:"__v_raw"===o?t:Reflect.get(w(n,o)&&o in t?n:t,o,r)}["keys","values","entries",Symbol.iterator].forEach((e=>{Le[e]=Pe(e,!1,!1),Ue[e]=Pe(e,!0,!1),je[e]=Pe(e,!1,!0),He[e]=Pe(e,!0,!0)}));const ze={get:De(!1,!1)},We={get:De(!1,!0)},Ke={get:De(!0,!1)},Ge={get:De(!0,!0)},qe=new WeakMap,Je=new WeakMap,Ze=new WeakMap,Qe=new WeakMap;function Xe(e){return e.__v_skip||!Object.isExtensible(e)?0:function(e){switch(e){case"Object":case"Array":return 1;case"Map":case"Set":case"WeakMap":case"WeakSet":return 2;default:return 0}}((e=>R(e).slice(8,-1))(e))}function Ye(e){return e&&e.__v_isReadonly?e:nt(e,!1,xe,ze,qe)}function et(e){return nt(e,!1,Ce,We,Je)}function tt(e){return nt(e,!0,Se,Ke,Ze)}function nt(e,t,n,o,r){if(!I(e))return e;if(e.__v_raw&&(!t||!e.__v_isReactive))return e;const s=r.get(e);if(s)return s;const i=Xe(e);if(0===i)return e;const l=new Proxy(e,2===i?o:n);return r.set(e,l),l}function ot(e){return rt(e)?ot(e.__v_raw):!(!e||!e.__v_isReactive)}function rt(e){return!(!e||!e.__v_isReadonly)}function st(e){return ot(e)||rt(e)}function it(e){return e&&it(e.__v_raw)||e}const lt=e=>I(e)?Ye(e):e;function ct(e){return Boolean(e&&!0===e.__v_isRef)}function at(e){return pt(e)}class ut{constructor(e,t=!1){this._rawValue=e,this._shallow=t,this.__v_isRef=!0,this._value=t?e:lt(e)}get value(){return ue(it(this),0,"value"),this._value}set value(e){G(it(e),this._rawValue)&&(this._rawValue=e,this._value=this._shallow?e:lt(e),pe(it(this),"set","value",e))}}function pt(e,t=!1){return ct(e)?e:new ut(e,t)}function ft(e){return ct(e)?e.value:e}const dt={get:(e,t,n)=>ft(Reflect.get(e,t,n)),set:(e,t,n,o)=>{const r=e[t];return ct(r)&&!ct(n)?(r.value=n,!0):Reflect.set(e,t,n,o)}};function ht(e){return ot(e)?e:new Proxy(e,dt)}class mt{constructor(e){this.__v_isRef=!0;const{get:t,set:n}=e((()=>ue(this,0,"value")),(()=>pe(this,"set","value")));this._get=t,this._set=n}get value(){return this._get()}set value(e){this._set(e)}}class gt{constructor(e,t){this._object=e,this._key=t,this.__v_isRef=!0}get value(){return this._object[this._key]}set value(e){this._object[this._key]=e}}function vt(e,t){return ct(e[t])?e[t]:new gt(e,t)}class yt{constructor(e,t,n){this._setter=t,this._dirty=!0,this.__v_isRef=!0,this.effect=ne(e,{lazy:!0,scheduler:()=>{this._dirty||(this._dirty=!0,pe(it(this),"set","value"))}}),this.__v_isReadonly=n}get value(){const e=it(this);return e._dirty&&(e._value=this.effect(),e._dirty=!1),ue(e,0,"value"),e._value}set value(e){this._setter(e)}}const bt=[];function _t(e){const t=[],n=Object.keys(e);return n.slice(0,3).forEach((n=>{t.push(...xt(n,e[n]))})),n.length>3&&t.push(" ..."),t}function xt(e,t,n){return A(t)?(t=JSON.stringify(t),n?t:[`${e}=${t}`]):"number"==typeof t||"boolean"==typeof t||null==t?n?t:[`${e}=${t}`]:ct(t)?(t=xt(e,it(t.value),!0),n?t:[`${e}=Ref<`,t,">"]):F(t)?[`${e}=fn${t.name?`<${t.name}>`:""}`]:(t=it(t),n?t:[`${e}=`,t])}function St(e,t,n,o){let r;try{r=o?e(...o):e()}catch(s){kt(s,t,n)}return r}function Ct(e,t,n,o){if(F(e)){const r=St(e,t,n,o);return r&&O(r)&&r.catch((e=>{kt(e,t,n)})),r}const r=[];for(let s=0;s>>1;Wt(Nt[e])-1?Nt.splice(t,0,e):Nt.push(e),jt()}}function jt(){wt||Tt||(Tt=!0,Rt=Bt.then(Kt))}function Ut(e,t,n,o){T(e)?n.push(...e):t&&t.includes(e,e.allowRecurse?o+1:o)||n.push(e),jt()}function Ht(e){Ut(e,It,Mt,Ot)}function Dt(e,t=null){if($t.length){for(Pt=t,Ft=[...new Set($t)],$t.length=0,At=0;AtWt(e)-Wt(t))),Ot=0;Otnull==e.id?1/0:e.id;function Kt(e){Tt=!1,wt=!0,Dt(e),Nt.sort(((e,t)=>Wt(e)-Wt(t)));try{for(Et=0;Ete.trim())):t&&(r=n.map(Z))}let l,c=o[l=K(t)]||o[l=K(H(t))];!c&&s&&(c=o[l=K(z(t))]),c&&Ct(c,e,6,r);const a=o[l+"Once"];if(a){if(e.emitted){if(e.emitted[l])return}else(e.emitted={})[l]=!0;Ct(a,e,6,r)}}function qt(e,t,n=!1){if(!t.deopt&&void 0!==e.__emits)return e.__emits;const o=e.emits;let r={},s=!1;if(!F(e)){const o=e=>{const n=qt(e,t,!0);n&&(s=!0,S(r,n))};!n&&t.mixins.length&&t.mixins.forEach(o),e.extends&&o(e.extends),e.mixins&&e.mixins.forEach(o)}return o||s?(T(o)?o.forEach((e=>r[e]=null)):S(r,o),e.__emits=r):e.__emits=null}function Jt(e,t){return!(!e||!_(t))&&(t=t.slice(2).replace(/Once$/,""),w(e,t[0].toLowerCase()+t.slice(1))||w(e,z(t))||w(e,t))}let Zt=0;const Qt=e=>Zt+=e;function Xt(e){return e.some((e=>!Ko(e)||e.type!==Vo&&!(e.type===Ro&&!Xt(e.children))))?e:null}let Yt=null,en=null;function tn(e){const t=Yt;return Yt=e,en=e&&e.type.__scopeId||null,t}function nn(e,t=Yt){if(!t)return e;const n=(...n)=>{Zt||Ho(!0);const o=tn(t),r=e(...n);return tn(o),Zt||Do(),r};return n._c=!0,n}function on(e){const{type:t,vnode:n,proxy:o,withProxy:r,props:s,propsOptions:[i],slots:l,attrs:c,emit:a,render:u,renderCache:p,data:f,setupState:d,ctx:h}=e;let m;const g=tn(e);try{let e;if(4&n.shapeFlag){const t=r||o;m=er(u.call(t,t,p,s,d,f,h)),e=c}else{const n=t;0,m=er(n(s,n.length>1?{attrs:c,slots:l,emit:a}:null)),e=t.props?c:sn(c)}let g=m;if(!1!==t.inheritAttrs&&e){const t=Object.keys(e),{shapeFlag:n}=g;t.length&&(1&n||6&n)&&(i&&t.some(x)&&(e=ln(e,i)),g=Xo(g,e))}n.dirs&&(g.dirs=g.dirs?g.dirs.concat(n.dirs):n.dirs),n.transition&&(g.transition=n.transition),m=g}catch(v){jo.length=0,kt(v,e,1),m=Qo(Vo)}return tn(g),m}function rn(e){let t;for(let n=0;n{let t;for(const n in e)("class"===n||"style"===n||_(n))&&((t||(t={}))[n]=e[n]);return t},ln=(e,t)=>{const n={};for(const o in e)x(o)&&o.slice(9)in t||(n[o]=e[o]);return n};function cn(e,t,n){const o=Object.keys(t);if(o.length!==Object.keys(e).length)return!0;for(let r=0;r0?(a(null,e.ssFallback,t,n,o,null,s,i),hn(f,e.ssFallback)):f.resolve()}(t,n,o,r,s,i,l,c,a):function(e,t,n,o,r,s,i,l,{p:c,um:a,o:{createElement:u}}){const p=t.suspense=e.suspense;p.vnode=t,t.el=e.el;const f=t.ssContent,d=t.ssFallback,{activeBranch:h,pendingBranch:m,isInFallback:g,isHydrating:v}=p;if(m)p.pendingBranch=f,Go(f,m)?(c(m,f,p.hiddenContainer,null,r,p,s,i,l),p.deps<=0?p.resolve():g&&(c(h,d,n,o,r,null,s,i,l),hn(p,d))):(p.pendingId++,v?(p.isHydrating=!1,p.activeBranch=m):a(m,r,p),p.deps=0,p.effects.length=0,p.hiddenContainer=u("div"),g?(c(null,f,p.hiddenContainer,null,r,p,s,i,l),p.deps<=0?p.resolve():(c(h,d,n,o,r,null,s,i,l),hn(p,d))):h&&Go(f,h)?(c(h,f,n,o,r,p,s,i,l),p.resolve(!0)):(c(null,f,p.hiddenContainer,null,r,p,s,i,l),p.deps<=0&&p.resolve()));else if(h&&Go(f,h))c(h,f,n,o,r,p,s,i,l),hn(p,f);else{const e=t.props&&t.props.onPending;if(F(e)&&e(),p.pendingBranch=f,p.pendingId++,c(null,f,p.hiddenContainer,null,r,p,s,i,l),p.deps<=0)p.resolve();else{const{timeout:e,pendingId:t}=p;e>0?setTimeout((()=>{p.pendingId===t&&p.fallback(d)}),e):0===e&&p.fallback(d)}}}(e,t,n,o,r,i,l,c,a)},hydrate:function(e,t,n,o,r,s,i,l,c){const a=t.suspense=pn(t,o,n,e.parentNode,document.createElement("div"),null,r,s,i,l,!0),u=c(e,a.pendingBranch=t.ssContent,n,a,s,i);0===a.deps&&a.resolve();return u},create:pn};function pn(e,t,n,o,r,s,i,l,c,a,u=!1){const{p:p,m:f,um:d,n:h,o:{parentNode:m,remove:g}}=a,v=Z(e.props&&e.props.timeout),y={vnode:e,parent:t,parentComponent:n,isSVG:i,container:o,hiddenContainer:r,anchor:s,deps:0,pendingId:0,timeout:"number"==typeof v?v:-1,activeBranch:null,pendingBranch:null,isInFallback:!0,isHydrating:u,isUnmounted:!1,effects:[],resolve(e=!1){const{vnode:t,activeBranch:n,pendingBranch:o,pendingId:r,effects:s,parentComponent:i,container:l}=y;if(y.isHydrating)y.isHydrating=!1;else if(!e){const e=n&&o.transition&&"out-in"===o.transition.mode;e&&(n.transition.afterLeave=()=>{r===y.pendingId&&f(o,l,t,0)});let{anchor:t}=y;n&&(t=h(n),d(n,i,y,!0)),e||f(o,l,t,0)}hn(y,o),y.pendingBranch=null,y.isInFallback=!1;let c=y.parent,a=!1;for(;c;){if(c.pendingBranch){c.effects.push(...s),a=!0;break}c=c.parent}a||Ht(s),y.effects=[];const u=t.props&&t.props.onResolve;F(u)&&u()},fallback(e){if(!y.pendingBranch)return;const{vnode:t,activeBranch:n,parentComponent:o,container:r,isSVG:s}=y,i=t.props&&t.props.onFallback;F(i)&&i();const a=h(n),u=()=>{y.isInFallback&&(p(null,e,r,a,o,null,s,l,c),hn(y,e))},f=e.transition&&"out-in"===e.transition.mode;f&&(n.transition.afterLeave=u),d(n,o,null,!0),y.isInFallback=!0,f||u()},move(e,t,n){y.activeBranch&&f(y.activeBranch,e,t,n),y.container=e},next:()=>y.activeBranch&&h(y.activeBranch),registerDep(e,t){const n=!!y.pendingBranch;n&&y.deps++;const o=e.vnode.el;e.asyncDep.catch((t=>{kt(t,e,0)})).then((r=>{if(e.isUnmounted||y.isUnmounted||y.pendingId!==e.suspenseId)return;e.asyncResolved=!0;const{vnode:s}=e;Tr(e,r),o&&(s.el=o);const l=!o&&e.subTree.el;t(e,s,m(o||e.subTree.el),o?null:h(e.subTree),y,i,c),l&&g(l),an(e,s.el),n&&0==--y.deps&&y.resolve()}))},unmount(e,t){y.isUnmounted=!0,y.activeBranch&&d(y.activeBranch,n,e,t),y.pendingBranch&&d(y.pendingBranch,n,e,t)}};return y}function fn(e){if(F(e)&&(e=e()),T(e)){e=rn(e)}return er(e)}function dn(e,t){t&&t.pendingBranch?T(e)?t.effects.push(...e):t.effects.push(e):Ht(e)}function hn(e,t){e.activeBranch=t;const{vnode:n,parentComponent:o}=e,r=n.el=t.el;o&&o.subTree===n&&(o.vnode.el=r,an(o,r))}function mn(e,t,n,o){const[r,s]=e.propsOptions;if(t)for(const i in t){const s=t[i];if(L(i))continue;let l;r&&w(r,l=H(i))?n[l]=s:Jt(e.emitsOptions,i)||(o[i]=s)}if(s){const t=it(n);for(let o=0;o{i=!0;const[n,o]=vn(e,t,!0);S(r,n),o&&s.push(...o)};!n&&t.mixins.length&&t.mixins.forEach(o),e.extends&&o(e.extends),e.mixins&&e.mixins.forEach(o)}if(!o&&!i)return e.__props=g;if(T(o))for(let l=0;l-1,n[1]=o<0||t-1||w(n,"default"))&&s.push(e)}}}return e.__props=[r,s]}function yn(e){return"$"!==e[0]}function bn(e){const t=e&&e.toString().match(/^\s*function (\w+)/);return t?t[1]:""}function _n(e,t){return bn(e)===bn(t)}function xn(e,t){return T(t)?t.findIndex((t=>_n(t,e))):F(t)&&_n(t,e)?0:-1}function Sn(e,t,n=_r,o=!1){if(n){const r=n[e]||(n[e]=[]),s=t.__weh||(t.__weh=(...o)=>{if(n.isUnmounted)return;ce(),Sr(n);const r=Ct(t,n,e,o);return Sr(null),ae(),r});return o?r.unshift(s):r.push(s),s}}const Cn=e=>(t,n=_r)=>!wr&&Sn(e,t,n),kn=Cn("bm"),wn=Cn("m"),Tn=Cn("bu"),Nn=Cn("u"),En=Cn("bum"),$n=Cn("um"),Fn=Cn("rtg"),An=Cn("rtc"),Mn=(e,t=_r)=>{Sn("ec",e,t)};function In(e,t){return Rn(e,null,t)}const On={};function Bn(e,t,n){return Rn(e,t,n)}function Rn(e,t,{immediate:n,deep:o,flush:r,onTrack:s,onTrigger:i}=m,l=_r){let c,a,u=!1;if(ct(e)?(c=()=>e.value,u=!!e._shallow):ot(e)?(c=()=>e,o=!0):c=T(e)?()=>e.map((e=>ct(e)?e.value:ot(e)?Vn(e):F(e)?St(e,l,2,[l&&l.proxy]):void 0)):F(e)?t?()=>St(e,l,2,[l&&l.proxy]):()=>{if(!l||!l.isUnmounted)return a&&a(),Ct(e,l,3,[p])}:v,t&&o){const e=c;c=()=>Vn(e())}let p=e=>{a=g.options.onStop=()=>{St(e,l,4)}},f=T(e)?[]:On;const d=()=>{if(g.active)if(t){const e=g();(o||u||G(e,f))&&(a&&a(),Ct(t,l,3,[e,f===On?void 0:f,p]),f=e)}else g()};let h;d.allowRecurse=!!t,h="sync"===r?d:"post"===r?()=>_o(d,l&&l.suspense):()=>{!l||l.isMounted?function(e){Ut(e,Ft,$t,At)}(d):d()};const g=ne(c,{lazy:!0,onTrack:s,onTrigger:i,scheduler:h});return Fr(g,l),t?n?d():f=g():"post"===r?_o(g,l&&l.suspense):g(),()=>{oe(g),l&&C(l.effects,g)}}function Pn(e,t,n){const o=this.proxy;return Rn(A(e)?()=>o[e]:e.bind(o),t.bind(o),n,this)}function Vn(e,t=new Set){if(!I(e)||t.has(e))return e;if(t.add(e),ct(e))Vn(e.value,t);else if(T(e))for(let n=0;n{Vn(e,t)}));else for(const n in e)Vn(e[n],t);return e}function Ln(){const e={isMounted:!1,isLeaving:!1,isUnmounting:!1,leavingVNodes:new Map};return wn((()=>{e.isMounted=!0})),En((()=>{e.isUnmounting=!0})),e}const jn=[Function,Array],Un={name:"BaseTransition",props:{mode:String,appear:Boolean,persisted:Boolean,onBeforeEnter:jn,onEnter:jn,onAfterEnter:jn,onEnterCancelled:jn,onBeforeLeave:jn,onLeave:jn,onAfterLeave:jn,onLeaveCancelled:jn,onBeforeAppear:jn,onAppear:jn,onAfterAppear:jn,onAppearCancelled:jn},setup(e,{slots:t}){const n=xr(),o=Ln();let r;return()=>{const s=t.default&&Gn(t.default(),!0);if(!s||!s.length)return;const i=it(e),{mode:l}=i,c=s[0];if(o.isLeaving)return zn(c);const a=Wn(c);if(!a)return zn(c);const u=Dn(a,i,o,n);Kn(a,u);const p=n.subTree,f=p&&Wn(p);let d=!1;const{getTransitionKey:h}=a.type;if(h){const e=h();void 0===r?r=e:e!==r&&(r=e,d=!0)}if(f&&f.type!==Vo&&(!Go(a,f)||d)){const e=Dn(f,i,o,n);if(Kn(f,e),"out-in"===l)return o.isLeaving=!0,e.afterLeave=()=>{o.isLeaving=!1,n.update()},zn(c);"in-out"===l&&a.type!==Vo&&(e.delayLeave=(e,t,n)=>{Hn(o,f)[String(f.key)]=f,e._leaveCb=()=>{t(),e._leaveCb=void 0,delete u.delayedLeave},u.delayedLeave=n})}return c}}};function Hn(e,t){const{leavingVNodes:n}=e;let o=n.get(t.type);return o||(o=Object.create(null),n.set(t.type,o)),o}function Dn(e,t,n,o){const{appear:r,mode:s,persisted:i=!1,onBeforeEnter:l,onEnter:c,onAfterEnter:a,onEnterCancelled:u,onBeforeLeave:p,onLeave:f,onAfterLeave:d,onLeaveCancelled:h,onBeforeAppear:m,onAppear:g,onAfterAppear:v,onAppearCancelled:y}=t,b=String(e.key),_=Hn(n,e),x=(e,t)=>{e&&Ct(e,o,9,t)},S={mode:s,persisted:i,beforeEnter(t){let o=l;if(!n.isMounted){if(!r)return;o=m||l}t._leaveCb&&t._leaveCb(!0);const s=_[b];s&&Go(e,s)&&s.el._leaveCb&&s.el._leaveCb(),x(o,[t])},enter(e){let t=c,o=a,s=u;if(!n.isMounted){if(!r)return;t=g||c,o=v||a,s=y||u}let i=!1;const l=e._enterCb=t=>{i||(i=!0,x(t?s:o,[e]),S.delayedLeave&&S.delayedLeave(),e._enterCb=void 0)};t?(t(e,l),t.length<=1&&l()):l()},leave(t,o){const r=String(e.key);if(t._enterCb&&t._enterCb(!0),n.isUnmounting)return o();x(p,[t]);let s=!1;const i=t._leaveCb=n=>{s||(s=!0,o(),x(n?h:d,[t]),t._leaveCb=void 0,_[r]===e&&delete _[r])};_[r]=e,f?(f(t,i),f.length<=1&&i()):i()},clone:e=>Dn(e,t,n,o)};return S}function zn(e){if(qn(e))return(e=Xo(e)).children=null,e}function Wn(e){return qn(e)?e.children?e.children[0]:void 0:e}function Kn(e,t){6&e.shapeFlag&&e.component?Kn(e.component.subTree,t):128&e.shapeFlag?(e.ssContent.transition=t.clone(e.ssContent),e.ssFallback.transition=t.clone(e.ssFallback)):e.transition=t}function Gn(e,t=!1){let n=[],o=0;for(let r=0;r1)for(let r=0;re.type.__isKeepAlive,Jn={name:"KeepAlive",__isKeepAlive:!0,props:{include:[String,RegExp,Array],exclude:[String,RegExp,Array],max:[String,Number]},setup(e,{slots:t}){const n=xr(),o=n.ctx;if(!o.renderer)return t.default;const r=new Map,s=new Set;let i=null;const l=n.suspense,{renderer:{p:c,m:a,um:u,o:{createElement:p}}}=o,f=p("div");function d(e){to(e),u(e,n,l)}function h(e){r.forEach(((t,n)=>{const o=Mr(t.type);!o||e&&e(o)||m(n)}))}function m(e){const t=r.get(e);i&&t.type===i.type?i&&to(i):d(t),r.delete(e),s.delete(e)}o.activate=(e,t,n,o,r)=>{const s=e.component;a(e,t,n,0,l),c(s.vnode,e,t,n,s,l,o,e.slotScopeIds,r),_o((()=>{s.isDeactivated=!1,s.a&&q(s.a);const t=e.props&&e.props.onVnodeMounted;t&&wo(t,s.parent,e)}),l)},o.deactivate=e=>{const t=e.component;a(e,f,null,1,l),_o((()=>{t.da&&q(t.da);const n=e.props&&e.props.onVnodeUnmounted;n&&wo(n,t.parent,e),t.isDeactivated=!0}),l)},Bn((()=>[e.include,e.exclude]),(([e,t])=>{e&&h((t=>Zn(e,t))),t&&h((e=>!Zn(t,e)))}),{flush:"post",deep:!0});let g=null;const v=()=>{null!=g&&r.set(g,no(n.subTree))};return wn(v),Nn(v),En((()=>{r.forEach((e=>{const{subTree:t,suspense:o}=n,r=no(t);if(e.type!==r.type)d(e);else{to(r);const e=r.component.da;e&&_o(e,o)}}))})),()=>{if(g=null,!t.default)return null;const n=t.default(),o=n[0];if(n.length>1)return i=null,n;if(!(Ko(o)&&(4&o.shapeFlag||128&o.shapeFlag)))return i=null,o;let l=no(o);const c=l.type,a=Mr(c),{include:u,exclude:p,max:f}=e;if(u&&(!a||!Zn(u,a))||p&&a&&Zn(p,a))return i=l,o;const d=null==l.key?c:l.key,h=r.get(d);return l.el&&(l=Xo(l),128&o.shapeFlag&&(o.ssContent=l)),g=d,h?(l.el=h.el,l.component=h.component,l.transition&&Kn(l,l.transition),l.shapeFlag|=512,s.delete(d),s.add(d)):(s.add(d),f&&s.size>parseInt(f,10)&&m(s.values().next().value)),l.shapeFlag|=256,i=l,o}}};function Zn(e,t){return T(e)?e.some((e=>Zn(e,t))):A(e)?e.split(",").indexOf(t)>-1:!!e.test&&e.test(t)}function Qn(e,t){Yn(e,"a",t)}function Xn(e,t){Yn(e,"da",t)}function Yn(e,t,n=_r){const o=e.__wdc||(e.__wdc=()=>{let t=n;for(;t;){if(t.isDeactivated)return;t=t.parent}e()});if(Sn(t,o,n),n){let e=n.parent;for(;e&&e.parent;)qn(e.parent.vnode)&&eo(o,t,n,e),e=e.parent}}function eo(e,t,n,o){const r=Sn(t,e,o,!0);$n((()=>{C(o[t],r)}),n)}function to(e){let t=e.shapeFlag;256&t&&(t-=256),512&t&&(t-=512),e.shapeFlag=t}function no(e){return 128&e.shapeFlag?e.ssContent:e}const oo=e=>"_"===e[0]||"$stable"===e,ro=e=>T(e)?e.map(er):[er(e)],so=(e,t,n)=>nn((e=>ro(t(e))),n),io=(e,t)=>{const n=e._ctx;for(const o in e){if(oo(o))continue;const r=e[o];if(F(r))t[o]=so(0,r,n);else if(null!=r){const e=ro(r);t[o]=()=>e}}},lo=(e,t)=>{const n=ro(t);e.slots.default=()=>n};function co(e,t,n,o){const r=e.dirs,s=t&&t.dirs;for(let i=0;i(s.has(e)||(e&&F(e.install)?(s.add(e),e.install(l,...t)):F(e)&&(s.add(e),e(l,...t))),l),mixin:e=>(r.mixins.includes(e)||(r.mixins.push(e),(e.props||e.emits)&&(r.deopt=!0)),l),component:(e,t)=>t?(r.components[e]=t,l):r.components[e],directive:(e,t)=>t?(r.directives[e]=t,l):r.directives[e],mount(s,c,a){if(!i){const u=Qo(n,o);return u.appContext=r,c&&t?t(u,s):e(u,s,a),i=!0,l._container=s,s.__vue_app__=l,u.component.proxy}},unmount(){i&&(e(null,l._container),delete l._container.__vue_app__)},provide:(e,t)=>(r.provides[e]=t,l)};return l}}let fo=!1;const ho=e=>/svg/.test(e.namespaceURI)&&"foreignObject"!==e.tagName,mo=e=>8===e.nodeType;function go(e){const{mt:t,p:n,o:{patchProp:o,nextSibling:r,parentNode:s,remove:i,insert:l,createComment:c}}=e,a=(n,o,i,l,c,m=!1)=>{const g=mo(n)&&"["===n.data,v=()=>d(n,o,i,l,c,g),{type:y,ref:b,shapeFlag:_}=o,x=n.nodeType;o.el=n;let S=null;switch(y){case Po:3!==x?S=v():(n.data!==o.children&&(fo=!0,n.data=o.children),S=r(n));break;case Vo:S=8!==x||g?v():r(n);break;case Lo:if(1===x){S=n;const e=!o.children.length;for(let t=0;t{t(o,e,null,i,l,ho(e),m)},u=o.type.__asyncLoader;u?u().then(a):a(),S=g?h(n):r(n)}else 64&_?S=8!==x?v():o.type.hydrate(n,o,i,l,c,m,e,p):128&_&&(S=o.type.hydrate(n,o,i,l,ho(s(n)),c,m,e,a))}return null!=b&&xo(b,null,l,o),S},u=(e,t,n,r,s,l)=>{l=l||!!t.dynamicChildren;const{props:c,patchFlag:a,shapeFlag:u,dirs:f}=t;if(-1!==a){if(f&&co(t,null,n,"created"),c)if(!l||16&a||32&a)for(const t in c)!L(t)&&_(t)&&o(e,t,null,c[t]);else c.onClick&&o(e,"onClick",null,c.onClick);let d;if((d=c&&c.onVnodeBeforeMount)&&wo(d,n,t),f&&co(t,null,n,"beforeMount"),((d=c&&c.onVnodeMounted)||f)&&dn((()=>{d&&wo(d,n,t),f&&co(t,null,n,"mounted")}),r),16&u&&(!c||!c.innerHTML&&!c.textContent)){let o=p(e.firstChild,t,e,n,r,s,l);for(;o;){fo=!0;const e=o;o=o.nextSibling,i(e)}}else 8&u&&e.textContent!==t.children&&(fo=!0,e.textContent=t.children)}return e.nextSibling},p=(e,t,o,r,s,i,l)=>{l=l||!!t.dynamicChildren;const c=t.children,u=c.length;for(let p=0;p{const{slotScopeIds:u}=t;u&&(i=i?i.concat(u):u);const f=s(e),d=p(r(e),t,f,n,o,i,a);return d&&mo(d)&&"]"===d.data?r(t.anchor=d):(fo=!0,l(t.anchor=c("]"),f,d),d)},d=(e,t,o,l,c,a)=>{if(fo=!0,t.el=null,a){const t=h(e);for(;;){const n=r(e);if(!n||n===t)break;i(n)}}const u=r(e),p=s(e);return i(e),n(null,t,p,u,o,l,ho(p),c),u},h=e=>{let t=0;for(;e;)if((e=r(e))&&mo(e)&&("["===e.data&&t++,"]"===e.data)){if(0===t)return r(e);t--}return e};return[(e,t)=>{fo=!1,a(t.firstChild,e,null,null,null),zt(),fo&&console.error("Hydration completed but contains mismatches.")},a]}function vo(e){return F(e)?{setup:e,name:e.name}:e}function yo(e,{vnode:{ref:t,props:n,children:o}}){const r=Qo(e,n,o);return r.ref=t,r}const bo={scheduler:Lt,allowRecurse:!0},_o=dn,xo=(e,t,n,o)=>{if(T(e))return void e.forEach(((e,r)=>xo(e,t&&(T(t)?t[r]:t),n,o)));let r;if(o){if(o.type.__asyncLoader)return;r=4&o.shapeFlag?o.component.exposed||o.component.proxy:o.el}else r=null;const{i:s,r:i}=e,l=t&&t.r,c=s.refs===m?s.refs={}:s.refs,a=s.setupState;if(null!=l&&l!==i&&(A(l)?(c[l]=null,w(a,l)&&(a[l]=null)):ct(l)&&(l.value=null)),A(i)){const e=()=>{c[i]=r,w(a,i)&&(a[i]=r)};r?(e.id=-1,_o(e,n)):e()}else if(ct(i)){const e=()=>{i.value=r};r?(e.id=-1,_o(e,n)):e()}else F(i)&&St(i,s,12,[r,c])};function So(e){return ko(e)}function Co(e){return ko(e,go)}function ko(e,t){const{insert:n,remove:o,patchProp:r,forcePatchProp:s,createElement:i,createText:l,createComment:c,setText:a,setElementText:u,parentNode:p,nextSibling:f,setScopeId:d=v,cloneNode:h,insertStaticContent:y}=e,b=(e,t,n,o=null,r=null,s=null,i=!1,l=null,c=!1)=>{e&&!Go(e,t)&&(o=Y(e),K(e,r,s,!0),e=null),-2===t.patchFlag&&(c=!1,t.dynamicChildren=null);const{type:a,ref:u,shapeFlag:p}=t;switch(a){case Po:_(e,t,n,o);break;case Vo:x(e,t,n,o);break;case Lo:null==e&&C(t,n,o,i);break;case Ro:M(e,t,n,o,r,s,i,l,c);break;default:1&p?k(e,t,n,o,r,s,i,l,c):6&p?I(e,t,n,o,r,s,i,l,c):(64&p||128&p)&&a.process(e,t,n,o,r,s,i,l,c,te)}null!=u&&r&&xo(u,e&&e.ref,s,t)},_=(e,t,o,r)=>{if(null==e)n(t.el=l(t.children),o,r);else{const n=t.el=e.el;t.children!==e.children&&a(n,t.children)}},x=(e,t,o,r)=>{null==e?n(t.el=c(t.children||""),o,r):t.el=e.el},C=(e,t,n,o)=>{[e.el,e.anchor]=y(e.children,t,n,o)},k=(e,t,n,o,r,s,i,l,c)=>{i=i||"svg"===t.type,null==e?T(t,n,o,r,s,i,l,c):$(e,t,r,s,i,l,c)},T=(e,t,o,s,l,c,a,p)=>{let f,d;const{type:m,props:g,shapeFlag:v,transition:y,patchFlag:b,dirs:_}=e;if(e.el&&void 0!==h&&-1===b)f=e.el=h(e.el);else{if(f=e.el=i(e.type,c,g&&g.is,g),8&v?u(f,e.children):16&v&&E(e.children,f,null,s,l,c&&"foreignObject"!==m,a,p||!!e.dynamicChildren),_&&co(e,null,s,"created"),g){for(const t in g)L(t)||r(f,t,null,g[t],c,e.children,s,l,X);(d=g.onVnodeBeforeMount)&&wo(d,s,e)}N(f,e,e.scopeId,a,s)}_&&co(e,null,s,"beforeMount");const x=(!l||l&&!l.pendingBranch)&&y&&!y.persisted;x&&y.beforeEnter(f),n(f,t,o),((d=g&&g.onVnodeMounted)||x||_)&&_o((()=>{d&&wo(d,s,e),x&&y.enter(f),_&&co(e,null,s,"mounted")}),l)},N=(e,t,n,o,r)=>{if(n&&d(e,n),o)for(let s=0;s{for(let a=c;a{const a=t.el=e.el;let{patchFlag:p,dynamicChildren:f,dirs:d}=t;p|=16&e.patchFlag;const h=e.props||m,g=t.props||m;let v;if((v=g.onVnodeBeforeUpdate)&&wo(v,n,t,e),d&&co(t,e,n,"beforeUpdate"),p>0){if(16&p)A(a,t,h,g,n,o,i);else if(2&p&&h.class!==g.class&&r(a,"class",null,g.class,i),4&p&&r(a,"style",h.style,g.style,i),8&p){const l=t.dynamicProps;for(let t=0;t{v&&wo(v,n,t,e),d&&co(t,e,n,"updated")}),o)},F=(e,t,n,o,r,s,i)=>{for(let l=0;l{if(n!==o){for(const a in o){if(L(a))continue;const u=o[a],p=n[a];(u!==p||s&&s(e,a))&&r(e,a,p,u,c,t.children,i,l,X)}if(n!==m)for(const s in n)L(s)||s in o||r(e,s,n[s],null,c,t.children,i,l,X)}},M=(e,t,o,r,s,i,c,a,u)=>{const p=t.el=e?e.el:l(""),f=t.anchor=e?e.anchor:l("");let{patchFlag:d,dynamicChildren:h,slotScopeIds:m}=t;d>0&&(u=!0),m&&(a=a?a.concat(m):m),null==e?(n(p,o,r),n(f,o,r),E(t.children,o,f,s,i,c,a,u)):d>0&&64&d&&h&&e.dynamicChildren?(F(e.dynamicChildren,h,o,s,i,c,a),(null!=t.key||s&&t===s.subTree)&&To(e,t,!0)):j(e,t,o,f,s,i,c,a,u)},I=(e,t,n,o,r,s,i,l,c)=>{t.slotScopeIds=l,null==e?512&t.shapeFlag?r.ctx.activate(t,n,o,i,c):B(t,n,o,r,s,i,c):R(e,t,c)},B=(e,t,n,o,r,s,i)=>{const l=e.component=function(e,t,n){const o=e.type,r=(t?t.appContext:e.appContext)||yr,s={uid:br++,vnode:e,type:o,parent:t,appContext:r,root:null,next:null,subTree:null,update:null,render:null,proxy:null,exposed:null,withProxy:null,effects:null,provides:t?t.provides:Object.create(r.provides),accessCache:null,renderCache:[],components:null,directives:null,propsOptions:vn(o,r),emitsOptions:qt(o,r),emit:null,emitted:null,propsDefaults:m,ctx:m,data:m,props:m,attrs:m,slots:m,refs:m,setupState:m,setupContext:null,suspense:n,suspenseId:n?n.pendingId:0,asyncDep:null,asyncResolved:!1,isMounted:!1,isUnmounted:!1,isDeactivated:!1,bc:null,c:null,bm:null,m:null,bu:null,u:null,um:null,bum:null,da:null,a:null,rtg:null,rtc:null,ec:null};return s.ctx={_:s},s.root=t?t.root:s,s.emit=Gt.bind(null,s),s}(e,o,r);if(qn(e)&&(l.ctx.renderer=te),function(e,t=!1){wr=t;const{props:n,children:o}=e.vnode,r=Cr(e);(function(e,t,n,o=!1){const r={},s={};J(s,qo,1),e.propsDefaults=Object.create(null),mn(e,t,r,s),e.props=n?o?r:et(r):e.type.props?r:s,e.attrs=s})(e,n,r,t),((e,t)=>{if(32&e.vnode.shapeFlag){const n=t._;n?(e.slots=t,J(t,"_",n)):io(t,e.slots={})}else e.slots={},t&&lo(e,t);J(e.slots,qo,1)})(e,o);const s=r?function(e,t){const n=e.type;e.accessCache=Object.create(null),e.proxy=new Proxy(e.ctx,gr);const{setup:o}=n;if(o){const n=e.setupContext=o.length>1?$r(e):null;_r=e,ce();const r=St(o,e,0,[e.props,n]);if(ae(),_r=null,O(r)){if(t)return r.then((t=>{Tr(e,t)})).catch((t=>{kt(t,e,0)}));e.asyncDep=r}else Tr(e,r)}else Er(e)}(e,t):void 0;wr=!1}(l),l.asyncDep){if(r&&r.registerDep(l,P),!e.el){const e=l.subTree=Qo(Vo);x(null,e,t,n)}}else P(l,e,t,n,r,s,i)},R=(e,t,n)=>{const o=t.component=e.component;if(function(e,t,n){const{props:o,children:r,component:s}=e,{props:i,children:l,patchFlag:c}=t,a=s.emitsOptions;if(t.dirs||t.transition)return!0;if(!(n&&c>=0))return!(!r&&!l||l&&l.$stable)||o!==i&&(o?!i||cn(o,i,a):!!i);if(1024&c)return!0;if(16&c)return o?cn(o,i,a):!!i;if(8&c){const e=t.dynamicProps;for(let t=0;tEt&&Nt.splice(t,1)}(o.update),o.update()}else t.component=e.component,t.el=e.el,o.vnode=t},P=(e,t,n,o,r,s,i)=>{e.update=ne((function(){if(e.isMounted){let t,{next:n,bu:o,u:l,parent:c,vnode:a}=e,u=n;n?(n.el=a.el,V(e,n,i)):n=a,o&&q(o),(t=n.props&&n.props.onVnodeBeforeUpdate)&&wo(t,c,n,a);const f=on(e),d=e.subTree;e.subTree=f,b(d,f,p(d.el),Y(d),e,r,s),n.el=f.el,null===u&&an(e,f.el),l&&_o(l,r),(t=n.props&&n.props.onVnodeUpdated)&&_o((()=>{wo(t,c,n,a)}),r)}else{let i;const{el:l,props:c}=t,{bm:a,m:u,parent:p}=e;a&&q(a),(i=c&&c.onVnodeBeforeMount)&&wo(i,p,t);const f=e.subTree=on(e);if(l&&se?se(t.el,f,e,r,null):(b(null,f,n,o,e,r,s),t.el=f.el),u&&_o(u,r),i=c&&c.onVnodeMounted){const e=t;_o((()=>{wo(i,p,e)}),r)}const{a:d}=e;d&&256&t.shapeFlag&&_o(d,r),e.isMounted=!0,t=n=o=null}}),bo)},V=(e,t,n)=>{t.component=e;const o=e.vnode.props;e.vnode=t,e.next=null,function(e,t,n,o){const{props:r,attrs:s,vnode:{patchFlag:i}}=e,l=it(r),[c]=e.propsOptions;if(!(o||i>0)||16&i){let o;mn(e,t,r,s);for(const s in l)t&&(w(t,s)||(o=z(s))!==s&&w(t,o))||(c?!n||void 0===n[s]&&void 0===n[o]||(r[s]=gn(c,t||m,s,void 0,e)):delete r[s]);if(s!==l)for(const e in s)t&&w(t,e)||delete s[e]}else if(8&i){const n=e.vnode.dynamicProps;for(let o=0;o{const{vnode:o,slots:r}=e;let s=!0,i=m;if(32&o.shapeFlag){const e=t._;e?n&&1===e?s=!1:(S(r,t),n||1!==e||delete r._):(s=!t.$stable,io(t,r)),i=t}else t&&(lo(e,t),i={default:1});if(s)for(const l in r)oo(l)||l in i||delete r[l]})(e,t.children,n),ce(),Dt(void 0,e.update),ae()},j=(e,t,n,o,r,s,i,l,c=!1)=>{const a=e&&e.children,p=e?e.shapeFlag:0,f=t.children,{patchFlag:d,shapeFlag:h}=t;if(d>0){if(128&d)return void D(a,f,n,o,r,s,i,l,c);if(256&d)return void U(a,f,n,o,r,s,i,l,c)}8&h?(16&p&&X(a,r,s),f!==a&&u(n,f)):16&p?16&h?D(a,f,n,o,r,s,i,l,c):X(a,r,s,!0):(8&p&&u(n,""),16&h&&E(f,n,o,r,s,i,l,c))},U=(e,t,n,o,r,s,i,l,c)=>{const a=(e=e||g).length,u=(t=t||g).length,p=Math.min(a,u);let f;for(f=0;fu?X(e,r,s,!0,!1,p):E(t,n,o,r,s,i,l,c,p)},D=(e,t,n,o,r,s,i,l,c)=>{let a=0;const u=t.length;let p=e.length-1,f=u-1;for(;a<=p&&a<=f;){const o=e[a],u=t[a]=c?tr(t[a]):er(t[a]);if(!Go(o,u))break;b(o,u,n,null,r,s,i,l,c),a++}for(;a<=p&&a<=f;){const o=e[p],a=t[f]=c?tr(t[f]):er(t[f]);if(!Go(o,a))break;b(o,a,n,null,r,s,i,l,c),p--,f--}if(a>p){if(a<=f){const e=f+1,p=ef)for(;a<=p;)K(e[a],r,s,!0),a++;else{const d=a,h=a,m=new Map;for(a=h;a<=f;a++){const e=t[a]=c?tr(t[a]):er(t[a]);null!=e.key&&m.set(e.key,a)}let v,y=0;const _=f-h+1;let x=!1,S=0;const C=new Array(_);for(a=0;a<_;a++)C[a]=0;for(a=d;a<=p;a++){const o=e[a];if(y>=_){K(o,r,s,!0);continue}let u;if(null!=o.key)u=m.get(o.key);else for(v=h;v<=f;v++)if(0===C[v-h]&&Go(o,t[v])){u=v;break}void 0===u?K(o,r,s,!0):(C[u-h]=a+1,u>=S?S=u:x=!0,b(o,t[u],n,null,r,s,i,l,c),y++)}const k=x?function(e){const t=e.slice(),n=[0];let o,r,s,i,l;const c=e.length;for(o=0;o0&&(t[o]=n[s-1]),n[s]=o)}}s=n.length,i=n[s-1];for(;s-- >0;)n[s]=i,i=t[i];return n}(C):g;for(v=k.length-1,a=_-1;a>=0;a--){const e=h+a,p=t[e],f=e+1{const{el:i,type:l,transition:c,children:a,shapeFlag:u}=e;if(6&u)return void W(e.component.subTree,t,o,r);if(128&u)return void e.suspense.move(t,o,r);if(64&u)return void l.move(e,t,o,te);if(l===Ro){n(i,t,o);for(let e=0;e{let s;for(;e&&e!==t;)s=f(e),n(e,o,r),e=s;n(t,o,r)})(e,t,o);if(2!==r&&1&u&&c)if(0===r)c.beforeEnter(i),n(i,t,o),_o((()=>c.enter(i)),s);else{const{leave:e,delayLeave:r,afterLeave:s}=c,l=()=>n(i,t,o),a=()=>{e(i,(()=>{l(),s&&s()}))};r?r(i,l,a):a()}else n(i,t,o)},K=(e,t,n,o=!1,r=!1)=>{const{type:s,props:i,ref:l,children:c,dynamicChildren:a,shapeFlag:u,patchFlag:p,dirs:f}=e;if(null!=l&&xo(l,null,n,null),256&u)return void t.ctx.deactivate(e);const d=1&u&&f;let h;if((h=i&&i.onVnodeBeforeUnmount)&&wo(h,t,e),6&u)Q(e.component,n,o);else{if(128&u)return void e.suspense.unmount(n,o);d&&co(e,null,t,"beforeUnmount"),64&u?e.type.remove(e,t,n,r,te,o):a&&(s!==Ro||p>0&&64&p)?X(a,t,n,!1,!0):(s===Ro&&(128&p||256&p)||!r&&16&u)&&X(c,t,n),o&&G(e)}((h=i&&i.onVnodeUnmounted)||d)&&_o((()=>{h&&wo(h,t,e),d&&co(e,null,t,"unmounted")}),n)},G=e=>{const{type:t,el:n,anchor:r,transition:s}=e;if(t===Ro)return void Z(n,r);if(t===Lo)return void(({el:e,anchor:t})=>{let n;for(;e&&e!==t;)n=f(e),o(e),e=n;o(t)})(e);const i=()=>{o(n),s&&!s.persisted&&s.afterLeave&&s.afterLeave()};if(1&e.shapeFlag&&s&&!s.persisted){const{leave:t,delayLeave:o}=s,r=()=>t(n,i);o?o(e.el,i,r):r()}else i()},Z=(e,t)=>{let n;for(;e!==t;)n=f(e),o(e),e=n;o(t)},Q=(e,t,n)=>{const{bum:o,effects:r,update:s,subTree:i,um:l}=e;if(o&&q(o),r)for(let c=0;c{e.isUnmounted=!0}),t),t&&t.pendingBranch&&!t.isUnmounted&&e.asyncDep&&!e.asyncResolved&&e.suspenseId===t.pendingId&&(t.deps--,0===t.deps&&t.resolve())},X=(e,t,n,o=!1,r=!1,s=0)=>{for(let i=s;i6&e.shapeFlag?Y(e.component.subTree):128&e.shapeFlag?e.suspense.next():f(e.anchor||e.el),ee=(e,t,n)=>{null==e?t._vnode&&K(t._vnode,null,null,!0):b(t._vnode||null,e,t,null,null,null,n),zt(),t._vnode=e},te={p:b,um:K,m:W,r:G,mt:B,mc:E,pc:j,pbc:F,n:Y,o:e};let re,se;return t&&([re,se]=t(te)),{render:ee,hydrate:re,createApp:po(ee,re)}}function wo(e,t,n,o=null){Ct(e,t,7,[n,o])}function To(e,t,n=!1){const o=e.children,r=t.children;if(T(o)&&T(r))for(let s=0;se&&(e.disabled||""===e.disabled),Eo=e=>"undefined"!=typeof SVGElement&&e instanceof SVGElement,$o=(e,t)=>{const n=e&&e.to;if(A(n)){if(t){return t(n)}return null}return n};function Fo(e,t,n,{o:{insert:o},m:r},s=2){0===s&&o(e.targetAnchor,t,n);const{el:i,anchor:l,shapeFlag:c,children:a,props:u}=e,p=2===s;if(p&&o(i,t,n),(!p||No(u))&&16&c)for(let f=0;f{16&v&&u(y,e,t,r,s,i,l,c)};g?b(n,a):p&&b(p,f)}else{t.el=e.el;const o=t.anchor=e.anchor,u=t.target=e.target,d=t.targetAnchor=e.targetAnchor,m=No(e.props),v=m?n:u,y=m?o:d;if(i=i||Eo(u),t.dynamicChildren?(f(e.dynamicChildren,t.dynamicChildren,v,r,s,i,l),To(e,t,!0)):c||p(e,t,v,y,r,s,i,l,!1),g)m||Fo(t,n,o,a,1);else if((t.props&&t.props.to)!==(e.props&&e.props.to)){const e=t.target=$o(t.props,h);e&&Fo(t,e,null,a,0)}else m&&Fo(t,u,d,a,1)}},remove(e,t,n,o,{um:r,o:{remove:s}},i){const{shapeFlag:l,children:c,anchor:a,targetAnchor:u,target:p,props:f}=e;if(p&&s(u),(i||!No(f))&&(s(a),16&l))for(let d=0;d0&&Uo&&Uo.push(s),s}function Ko(e){return!!e&&!0===e.__v_isVNode}function Go(e,t){return e.type===t.type&&e.key===t.key}const qo="__vInternal",Jo=({key:e})=>null!=e?e:null,Zo=({ref:e})=>null!=e?A(e)||ct(e)||F(e)?{i:Yt,r:e}:e:null,Qo=function(e,t=null,n=null,o=0,s=null,i=!1){e&&e!==Io||(e=Vo);if(Ko(e)){const o=Xo(e,t,!0);return n&&nr(o,n),o}l=e,F(l)&&"__vccOpts"in l&&(e=e.__vccOpts);var l;if(t){(st(t)||qo in t)&&(t=S({},t));let{class:e,style:n}=t;e&&!A(e)&&(t.class=c(e)),I(n)&&(st(n)&&!T(n)&&(n=S({},n)),t.style=r(n))}const a=A(e)?1:(e=>e.__isSuspense)(e)?128:(e=>e.__isTeleport)(e)?64:I(e)?4:F(e)?2:0,u={__v_isVNode:!0,__v_skip:!0,type:e,props:t,key:t&&Jo(t),ref:t&&Zo(t),scopeId:en,slotScopeIds:null,children:null,component:null,suspense:null,ssContent:null,ssFallback:null,dirs:null,transition:null,el:null,anchor:null,target:null,targetAnchor:null,staticCount:0,shapeFlag:a,patchFlag:o,dynamicProps:s,dynamicChildren:null,appContext:null};if(nr(u,n),128&a){const{content:e,fallback:t}=function(e){const{shapeFlag:t,children:n}=e;let o,r;return 32&t?(o=fn(n.default),r=fn(n.fallback)):(o=fn(n),r=er(null)),{content:o,fallback:r}}(u);u.ssContent=e,u.ssFallback=t}zo>0&&!i&&Uo&&(o>0||6&a)&&32!==o&&Uo.push(u);return u};function Xo(e,t,n=!1){const{props:o,ref:r,patchFlag:s,children:i}=e,l=t?or(o||{},t):o;return{__v_isVNode:!0,__v_skip:!0,type:e.type,props:l,key:l&&Jo(l),ref:t&&t.ref?n&&r?T(r)?r.concat(Zo(t)):[r,Zo(t)]:Zo(t):r,scopeId:e.scopeId,slotScopeIds:e.slotScopeIds,children:i,target:e.target,targetAnchor:e.targetAnchor,staticCount:e.staticCount,shapeFlag:e.shapeFlag,patchFlag:t&&e.type!==Ro?-1===s?16:16|s:s,dynamicProps:e.dynamicProps,dynamicChildren:e.dynamicChildren,appContext:e.appContext,dirs:e.dirs,transition:e.transition,component:e.component,suspense:e.suspense,ssContent:e.ssContent&&Xo(e.ssContent),ssFallback:e.ssFallback&&Xo(e.ssFallback),el:e.el,anchor:e.anchor}}function Yo(e=" ",t=0){return Qo(Po,null,e,t)}function er(e){return null==e||"boolean"==typeof e?Qo(Vo):T(e)?Qo(Ro,null,e):"object"==typeof e?null===e.el?e:Xo(e):Qo(Po,null,String(e))}function tr(e){return null===e.el?e:Xo(e)}function nr(e,t){let n=0;const{shapeFlag:o}=e;if(null==t)t=null;else if(T(t))n=16;else if("object"==typeof t){if(1&o||64&o){const n=t.default;return void(n&&(n._c&&Qt(1),nr(e,n()),n._c&&Qt(-1)))}{n=32;const o=t._;o||qo in t?3===o&&Yt&&(1024&Yt.vnode.patchFlag?(t._=2,e.patchFlag|=1024):t._=1):t._ctx=Yt}}else F(t)?(t={default:t,_ctx:Yt},n=32):(t=String(t),64&o?(n=16,t=[Yo(t)]):n=8);e.children=t,e.shapeFlag|=n}function or(...e){const t=S({},e[0]);for(let n=1;n1)return n&&F(t)?t():t}}let ir=!0;function lr(e,t,n=[],o=[],r=[],s=!1){const{mixins:i,extends:l,data:c,computed:a,methods:u,watch:p,provide:f,inject:d,components:h,directives:g,beforeMount:y,mounted:b,beforeUpdate:_,updated:x,activated:C,deactivated:k,beforeUnmount:w,unmounted:N,render:E,renderTracked:$,renderTriggered:A,errorCaptured:M,expose:O}=t,B=e.proxy,R=e.ctx,P=e.appContext.mixins;if(s&&E&&e.render===v&&(e.render=E),s||(ir=!1,cr("beforeCreate","bc",t,e,P),ir=!0,ur(e,P,n,o,r)),l&&lr(e,l,n,o,r,!0),i&&ur(e,i,n,o,r),d)if(T(d))for(let m=0;mpr(e,t,B))),c&&pr(e,c,B)),a)for(const m in a){const e=a[m],t=Or({get:F(e)?e.bind(B,B):F(e.get)?e.get.bind(B,B):v,set:!F(e)&&F(e.set)?e.set.bind(B):v});Object.defineProperty(R,m,{enumerable:!0,configurable:!0,get:()=>t.value,set:e=>t.value=e})}if(p&&o.push(p),!s&&o.length&&o.forEach((e=>{for(const t in e)fr(e[t],R,B,t)})),f&&r.push(f),!s&&r.length&&r.forEach((e=>{const t=F(e)?e.call(B):e;Reflect.ownKeys(t).forEach((e=>{rr(e,t[e])}))})),s&&(h&&S(e.components||(e.components=S({},e.type.components)),h),g&&S(e.directives||(e.directives=S({},e.type.directives)),g)),s||cr("created","c",t,e,P),y&&kn(y.bind(B)),b&&wn(b.bind(B)),_&&Tn(_.bind(B)),x&&Nn(x.bind(B)),C&&Qn(C.bind(B)),k&&Xn(k.bind(B)),M&&Mn(M.bind(B)),$&&An($.bind(B)),A&&Fn(A.bind(B)),w&&En(w.bind(B)),N&&$n(N.bind(B)),T(O)&&!s)if(O.length){const t=e.exposed||(e.exposed=ht({}));O.forEach((e=>{t[e]=vt(B,e)}))}else e.exposed||(e.exposed=m)}function cr(e,t,n,o,r){for(let s=0;s{let t=e;for(let e=0;en[o];if(A(e)){const n=t[e];F(n)&&Bn(r,n)}else if(F(e))Bn(r,e.bind(n));else if(I(e))if(T(e))e.forEach((e=>fr(e,t,n,o)));else{const o=F(e.handler)?e.handler.bind(n):t[e.handler];F(o)&&Bn(r,o,e)}}function dr(e,t,n){const o=n.appContext.config.optionMergeStrategies,{mixins:r,extends:s}=t;s&&dr(e,s,n),r&&r.forEach((t=>dr(e,t,n)));for(const i in t)e[i]=o&&w(o,i)?o[i](e[i],t[i],n.proxy,i):t[i]}const hr=e=>e?Cr(e)?e.exposed?e.exposed:e.proxy:hr(e.parent):null,mr=S(Object.create(null),{$:e=>e,$el:e=>e.vnode.el,$data:e=>e.data,$props:e=>e.props,$attrs:e=>e.attrs,$slots:e=>e.slots,$refs:e=>e.refs,$parent:e=>hr(e.parent),$root:e=>hr(e.root),$emit:e=>e.emit,$options:e=>function(e){const t=e.type,{__merged:n,mixins:o,extends:r}=t;if(n)return n;const s=e.appContext.mixins;if(!s.length&&!o&&!r)return t;const i={};return s.forEach((t=>dr(i,t,e))),dr(i,t,e),t.__merged=i}(e),$forceUpdate:e=>()=>Lt(e.update),$nextTick:e=>Vt.bind(e.proxy),$watch:e=>Pn.bind(e)}),gr={get({_:e},t){const{ctx:n,setupState:o,data:r,props:s,accessCache:i,type:l,appContext:c}=e;if("__v_skip"===t)return!0;let a;if("$"!==t[0]){const l=i[t];if(void 0!==l)switch(l){case 0:return o[t];case 1:return r[t];case 3:return n[t];case 2:return s[t]}else{if(o!==m&&w(o,t))return i[t]=0,o[t];if(r!==m&&w(r,t))return i[t]=1,r[t];if((a=e.propsOptions[0])&&w(a,t))return i[t]=2,s[t];if(n!==m&&w(n,t))return i[t]=3,n[t];ir&&(i[t]=4)}}const u=mr[t];let p,f;return u?("$attrs"===t&&ue(e,0,t),u(e)):(p=l.__cssModules)&&(p=p[t])?p:n!==m&&w(n,t)?(i[t]=3,n[t]):(f=c.config.globalProperties,w(f,t)?f[t]:void 0)},set({_:e},t,n){const{data:o,setupState:r,ctx:s}=e;if(r!==m&&w(r,t))r[t]=n;else if(o!==m&&w(o,t))o[t]=n;else if(w(e.props,t))return!1;return("$"!==t[0]||!(t.slice(1)in e))&&(s[t]=n,!0)},has({_:{data:e,setupState:t,accessCache:n,ctx:o,appContext:r,propsOptions:s}},i){let l;return void 0!==n[i]||e!==m&&w(e,i)||t!==m&&w(t,i)||(l=s[0])&&w(l,i)||w(o,i)||w(mr,i)||w(r.config.globalProperties,i)}},vr=S({},gr,{get(e,t){if(t!==Symbol.unscopables)return gr.get(e,t,e)},has:(e,t)=>"_"!==t[0]&&!n(t)}),yr=ao();let br=0;let _r=null;const xr=()=>_r||Yt,Sr=e=>{_r=e};function Cr(e){return 4&e.vnode.shapeFlag}let kr,wr=!1;function Tr(e,t,n){F(t)?e.render=t:I(t)&&(e.setupState=ht(t)),Er(e)}function Nr(e){kr=e}function Er(e,t){const n=e.type;e.render||(kr&&n.template&&!n.render&&(n.render=kr(n.template,{isCustomElement:e.appContext.config.isCustomElement,delimiters:n.delimiters})),e.render=n.render||v,e.render._rc&&(e.withProxy=new Proxy(e.ctx,vr))),_r=e,ce(),lr(e,n),ae(),_r=null}function $r(e){const t=t=>{e.exposed=ht(t)};return{attrs:e.attrs,slots:e.slots,emit:e.emit,expose:t}}function Fr(e,t=_r){t&&(t.effects||(t.effects=[])).push(e)}const Ar=/(?:^|[-_])(\w)/g;function Mr(e){return F(e)&&e.displayName||e.name}function Ir(e,t,n=!1){let o=Mr(t);if(!o&&t.__file){const e=t.__file.match(/([^/\\]+)\.\w+$/);e&&(o=e[1])}if(!o&&e&&e.parent){const n=e=>{for(const n in e)if(e[n]===t)return n};o=n(e.components||e.parent.type.components)||n(e.appContext.components)}return o?o.replace(Ar,(e=>e.toUpperCase())).replace(/[-_]/g,""):n?"App":"Anonymous"}function Or(e){const t=function(e){let t,n;return F(e)?(t=e,n=v):(t=e.get,n=e.set),new yt(t,n,F(e)||!e.set)}(e);return Fr(t.effect),t}function Br(e,t,n){const o=arguments.length;return 2===o?I(t)&&!T(t)?Ko(t)?Qo(e,null,[t]):Qo(e,t):Qo(e,null,t):(o>3?n=Array.prototype.slice.call(arguments,2):3===o&&Ko(n)&&(n=[n]),Qo(e,t,n))}const Rr=Symbol("");const Pr="3.0.11",Vr="http://www.w3.org/2000/svg",Lr="undefined"!=typeof document?document:null;let jr,Ur;const Hr={insert:(e,t,n)=>{t.insertBefore(e,n||null)},remove:e=>{const t=e.parentNode;t&&t.removeChild(e)},createElement:(e,t,n,o)=>{const r=t?Lr.createElementNS(Vr,e):Lr.createElement(e,n?{is:n}:void 0);return"select"===e&&o&&null!=o.multiple&&r.setAttribute("multiple",o.multiple),r},createText:e=>Lr.createTextNode(e),createComment:e=>Lr.createComment(e),setText:(e,t)=>{e.nodeValue=t},setElementText:(e,t)=>{e.textContent=t},parentNode:e=>e.parentNode,nextSibling:e=>e.nextSibling,querySelector:e=>Lr.querySelector(e),setScopeId(e,t){e.setAttribute(t,"")},cloneNode(e){const t=e.cloneNode(!0);return"_value"in e&&(t._value=e._value),t},insertStaticContent(e,t,n,o){const r=o?Ur||(Ur=Lr.createElementNS(Vr,"svg")):jr||(jr=Lr.createElement("div"));r.innerHTML=e;const s=r.firstChild;let i=s,l=i;for(;i;)l=i,Hr.insert(i,t,n),i=r.firstChild;return[s,l]}};const Dr=/\s*!important$/;function zr(e,t,n){if(T(n))n.forEach((n=>zr(e,t,n)));else if(t.startsWith("--"))e.setProperty(t,n);else{const o=function(e,t){const n=Kr[t];if(n)return n;let o=H(t);if("filter"!==o&&o in e)return Kr[t]=o;o=W(o);for(let r=0;rdocument.createEvent("Event").timeStamp&&(qr=()=>performance.now());const e=navigator.userAgent.match(/firefox\/(\d+)/i);Jr=!!(e&&Number(e[1])<=53)}let Zr=0;const Qr=Promise.resolve(),Xr=()=>{Zr=0};function Yr(e,t,n,o){e.addEventListener(t,n,o)}function es(e,t,n,o,r=null){const s=e._vei||(e._vei={}),i=s[t];if(o&&i)i.value=o;else{const[n,l]=function(e){let t;if(ts.test(e)){let n;for(t={};n=e.match(ts);)e=e.slice(0,e.length-n[0].length),t[n[0].toLowerCase()]=!0}return[z(e.slice(2)),t]}(t);if(o){Yr(e,n,s[t]=function(e,t){const n=e=>{const o=e.timeStamp||qr();(Jr||o>=n.attached-1)&&Ct(function(e,t){if(T(t)){const n=e.stopImmediatePropagation;return e.stopImmediatePropagation=()=>{n.call(e),e._stopped=!0},t.map((e=>t=>!t._stopped&&e(t)))}return t}(e,n.value),t,5,[e])};return n.value=e,n.attached=(()=>Zr||(Qr.then(Xr),Zr=qr()))(),n}(o,r),l)}else i&&(!function(e,t,n,o){e.removeEventListener(t,n,o)}(e,n,i,l),s[t]=void 0)}}const ts=/(?:Once|Passive|Capture)$/;const ns=/^on[a-z]/;function os(e,t){if(128&e.shapeFlag){const n=e.suspense;e=n.activeBranch,n.pendingBranch&&!n.isHydrating&&n.effects.push((()=>{os(n.activeBranch,t)}))}for(;e.component;)e=e.component.subTree;if(1&e.shapeFlag&&e.el){const n=e.el.style;for(const e in t)n.setProperty(`--${e}`,t[e])}else e.type===Ro&&e.children.forEach((e=>os(e,t)))}const rs="transition",ss="animation",is=(e,{slots:t})=>Br(Un,as(e),t);is.displayName="Transition";const ls={name:String,type:String,css:{type:Boolean,default:!0},duration:[String,Number,Object],enterFromClass:String,enterActiveClass:String,enterToClass:String,appearFromClass:String,appearActiveClass:String,appearToClass:String,leaveFromClass:String,leaveActiveClass:String,leaveToClass:String},cs=is.props=S({},Un.props,ls);function as(e){let{name:t="v",type:n,css:o=!0,duration:r,enterFromClass:s=`${t}-enter-from`,enterActiveClass:i=`${t}-enter-active`,enterToClass:l=`${t}-enter-to`,appearFromClass:c=s,appearActiveClass:a=i,appearToClass:u=l,leaveFromClass:p=`${t}-leave-from`,leaveActiveClass:f=`${t}-leave-active`,leaveToClass:d=`${t}-leave-to`}=e;const h={};for(const S in e)S in ls||(h[S]=e[S]);if(!o)return h;const m=function(e){if(null==e)return null;if(I(e))return[us(e.enter),us(e.leave)];{const t=us(e);return[t,t]}}(r),g=m&&m[0],v=m&&m[1],{onBeforeEnter:y,onEnter:b,onEnterCancelled:_,onLeave:x,onLeaveCancelled:C,onBeforeAppear:k=y,onAppear:w=b,onAppearCancelled:T=_}=h,N=(e,t,n)=>{fs(e,t?u:l),fs(e,t?a:i),n&&n()},E=(e,t)=>{fs(e,d),fs(e,f),t&&t()},$=e=>(t,o)=>{const r=e?w:b,i=()=>N(t,e,o);r&&r(t,i),ds((()=>{fs(t,e?c:s),ps(t,e?u:l),r&&r.length>1||ms(t,n,g,i)}))};return S(h,{onBeforeEnter(e){y&&y(e),ps(e,s),ps(e,i)},onBeforeAppear(e){k&&k(e),ps(e,c),ps(e,a)},onEnter:$(!1),onAppear:$(!0),onLeave(e,t){const o=()=>E(e,t);ps(e,p),bs(),ps(e,f),ds((()=>{fs(e,p),ps(e,d),x&&x.length>1||ms(e,n,v,o)})),x&&x(e,o)},onEnterCancelled(e){N(e,!1),_&&_(e)},onAppearCancelled(e){N(e,!0),T&&T(e)},onLeaveCancelled(e){E(e),C&&C(e)}})}function us(e){return Z(e)}function ps(e,t){t.split(/\s+/).forEach((t=>t&&e.classList.add(t))),(e._vtc||(e._vtc=new Set)).add(t)}function fs(e,t){t.split(/\s+/).forEach((t=>t&&e.classList.remove(t)));const{_vtc:n}=e;n&&(n.delete(t),n.size||(e._vtc=void 0))}function ds(e){requestAnimationFrame((()=>{requestAnimationFrame(e)}))}let hs=0;function ms(e,t,n,o){const r=e._endId=++hs,s=()=>{r===e._endId&&o()};if(n)return setTimeout(s,n);const{type:i,timeout:l,propCount:c}=gs(e,t);if(!i)return o();const a=i+"end";let u=0;const p=()=>{e.removeEventListener(a,f),s()},f=t=>{t.target===e&&++u>=c&&p()};setTimeout((()=>{u(n[e]||"").split(", "),r=o("transitionDelay"),s=o("transitionDuration"),i=vs(r,s),l=o("animationDelay"),c=o("animationDuration"),a=vs(l,c);let u=null,p=0,f=0;t===rs?i>0&&(u=rs,p=i,f=s.length):t===ss?a>0&&(u=ss,p=a,f=c.length):(p=Math.max(i,a),u=p>0?i>a?rs:ss:null,f=u?u===rs?s.length:c.length:0);return{type:u,timeout:p,propCount:f,hasTransform:u===rs&&/\b(transform|all)(,|$)/.test(n.transitionProperty)}}function vs(e,t){for(;e.lengthys(t)+ys(e[n]))))}function ys(e){return 1e3*Number(e.slice(0,-1).replace(",","."))}function bs(){return document.body.offsetHeight}const _s=new WeakMap,xs=new WeakMap,Ss={name:"TransitionGroup",props:S({},cs,{tag:String,moveClass:String}),setup(e,{slots:t}){const n=xr(),o=Ln();let r,s;return Nn((()=>{if(!r.length)return;const t=e.moveClass||`${e.name||"v"}-move`;if(!function(e,t,n){const o=e.cloneNode();e._vtc&&e._vtc.forEach((e=>{e.split(/\s+/).forEach((e=>e&&o.classList.remove(e)))}));n.split(/\s+/).forEach((e=>e&&o.classList.add(e))),o.style.display="none";const r=1===t.nodeType?t:t.parentNode;r.appendChild(o);const{hasTransform:s}=gs(o);return r.removeChild(o),s}(r[0].el,n.vnode.el,t))return;r.forEach(Cs),r.forEach(ks);const o=r.filter(ws);bs(),o.forEach((e=>{const n=e.el,o=n.style;ps(n,t),o.transform=o.webkitTransform=o.transitionDuration="";const r=n._moveCb=e=>{e&&e.target!==n||e&&!/transform$/.test(e.propertyName)||(n.removeEventListener("transitionend",r),n._moveCb=null,fs(n,t))};n.addEventListener("transitionend",r)}))})),()=>{const i=it(e),l=as(i),c=i.tag||Ro;r=s,s=t.default?Gn(t.default()):[];for(let e=0;e{const t=e.props["onUpdate:modelValue"];return T(t)?e=>q(t,e):t};function Ns(e){e.target.composing=!0}function Es(e){const t=e.target;t.composing&&(t.composing=!1,function(e,t){const n=document.createEvent("HTMLEvents");n.initEvent(t,!0,!0),e.dispatchEvent(n)}(t,"input"))}const $s={created(e,{modifiers:{lazy:t,trim:n,number:o}},r){e._assign=Ts(r);const s=o||"number"===e.type;Yr(e,t?"change":"input",(t=>{if(t.target.composing)return;let o=e.value;n?o=o.trim():s&&(o=Z(o)),e._assign(o)})),n&&Yr(e,"change",(()=>{e.value=e.value.trim()})),t||(Yr(e,"compositionstart",Ns),Yr(e,"compositionend",Es),Yr(e,"change",Es))},mounted(e,{value:t}){e.value=null==t?"":t},beforeUpdate(e,{value:t,modifiers:{trim:n,number:o}},r){if(e._assign=Ts(r),e.composing)return;if(document.activeElement===e){if(n&&e.value.trim()===t)return;if((o||"number"===e.type)&&Z(e.value)===t)return}const s=null==t?"":t;e.value!==s&&(e.value=s)}},Fs={created(e,t,n){e._assign=Ts(n),Yr(e,"change",(()=>{const t=e._modelValue,n=Bs(e),o=e.checked,r=e._assign;if(T(t)){const e=d(t,n),s=-1!==e;if(o&&!s)r(t.concat(n));else if(!o&&s){const n=[...t];n.splice(e,1),r(n)}}else if(E(t)){const e=new Set(t);o?e.add(n):e.delete(n),r(e)}else r(Rs(e,o))}))},mounted:As,beforeUpdate(e,t,n){e._assign=Ts(n),As(e,t,n)}};function As(e,{value:t,oldValue:n},o){e._modelValue=t,T(t)?e.checked=d(t,o.props.value)>-1:E(t)?e.checked=t.has(o.props.value):t!==n&&(e.checked=f(t,Rs(e,!0)))}const Ms={created(e,{value:t},n){e.checked=f(t,n.props.value),e._assign=Ts(n),Yr(e,"change",(()=>{e._assign(Bs(e))}))},beforeUpdate(e,{value:t,oldValue:n},o){e._assign=Ts(o),t!==n&&(e.checked=f(t,o.props.value))}},Is={created(e,{value:t,modifiers:{number:n}},o){const r=E(t);Yr(e,"change",(()=>{const t=Array.prototype.filter.call(e.options,(e=>e.selected)).map((e=>n?Z(Bs(e)):Bs(e)));e._assign(e.multiple?r?new Set(t):t:t[0])})),e._assign=Ts(o)},mounted(e,{value:t}){Os(e,t)},beforeUpdate(e,t,n){e._assign=Ts(n)},updated(e,{value:t}){Os(e,t)}};function Os(e,t){const n=e.multiple;if(!n||T(t)||E(t)){for(let o=0,r=e.options.length;o-1:t.has(s);else if(f(Bs(r),t))return void(e.selectedIndex=o)}n||(e.selectedIndex=-1)}}function Bs(e){return"_value"in e?e._value:e.value}function Rs(e,t){const n=t?"_trueValue":"_falseValue";return n in e?e[n]:t}const Ps={created(e,t,n){Vs(e,t,n,null,"created")},mounted(e,t,n){Vs(e,t,n,null,"mounted")},beforeUpdate(e,t,n,o){Vs(e,t,n,o,"beforeUpdate")},updated(e,t,n,o){Vs(e,t,n,o,"updated")}};function Vs(e,t,n,o,r){let s;switch(e.tagName){case"SELECT":s=Is;break;case"TEXTAREA":s=$s;break;default:switch(n.props&&n.props.type){case"checkbox":s=Fs;break;case"radio":s=Ms;break;default:s=$s}}const i=s[r];i&&i(e,t,n,o)}const Ls=["ctrl","shift","alt","meta"],js={stop:e=>e.stopPropagation(),prevent:e=>e.preventDefault(),self:e=>e.target!==e.currentTarget,ctrl:e=>!e.ctrlKey,shift:e=>!e.shiftKey,alt:e=>!e.altKey,meta:e=>!e.metaKey,left:e=>"button"in e&&0!==e.button,middle:e=>"button"in e&&1!==e.button,right:e=>"button"in e&&2!==e.button,exact:(e,t)=>Ls.some((n=>e[`${n}Key`]&&!t.includes(n)))},Us={esc:"escape",space:" ",up:"arrow-up",left:"arrow-left",right:"arrow-right",down:"arrow-down",delete:"backspace"},Hs={beforeMount(e,{value:t},{transition:n}){e._vod="none"===e.style.display?"":e.style.display,n&&t?n.beforeEnter(e):Ds(e,t)},mounted(e,{value:t},{transition:n}){n&&t&&n.enter(e)},updated(e,{value:t,oldValue:n},{transition:o}){!t!=!n&&(o?t?(o.beforeEnter(e),Ds(e,!0),o.enter(e)):o.leave(e,(()=>{Ds(e,!1)})):Ds(e,t))},beforeUnmount(e,{value:t}){Ds(e,t)}};function Ds(e,t){e.style.display=t?e._vod:"none"}const zs=S({patchProp:(e,t,n,r,s=!1,i,l,c,a)=>{switch(t){case"class":!function(e,t,n){if(null==t&&(t=""),n)e.setAttribute("class",t);else{const n=e._vtc;n&&(t=(t?[t,...n]:[...n]).join(" ")),e.className=t}}(e,r,s);break;case"style":!function(e,t,n){const o=e.style;if(n)if(A(n)){if(t!==n){const t=o.display;o.cssText=n,"_vod"in e&&(o.display=t)}}else{for(const e in n)zr(o,e,n[e]);if(t&&!A(t))for(const e in t)null==n[e]&&zr(o,e,"")}else e.removeAttribute("style")}(e,n,r);break;default:_(t)?x(t)||es(e,t,0,r,l):function(e,t,n,o){if(o)return"innerHTML"===t||!!(t in e&&ns.test(t)&&F(n));if("spellcheck"===t||"draggable"===t)return!1;if("form"===t)return!1;if("list"===t&&"INPUT"===e.tagName)return!1;if("type"===t&&"TEXTAREA"===e.tagName)return!1;if(ns.test(t)&&A(n))return!1;return t in e}(e,t,r,s)?function(e,t,n,o,r,s,i){if("innerHTML"===t||"textContent"===t)return o&&i(o,r,s),void(e[t]=null==n?"":n);if("value"!==t||"PROGRESS"===e.tagName){if(""===n||null==n){const o=typeof e[t];if(""===n&&"boolean"===o)return void(e[t]=!0);if(null==n&&"string"===o)return e[t]="",void e.removeAttribute(t);if("number"===o)return e[t]=0,void e.removeAttribute(t)}try{e[t]=n}catch(l){}}else{e._value=n;const t=null==n?"":n;e.value!==t&&(e.value=t)}}(e,t,r,i,l,c,a):("true-value"===t?e._trueValue=r:"false-value"===t&&(e._falseValue=r),function(e,t,n,r){if(r&&t.startsWith("xlink:"))null==n?e.removeAttributeNS(Gr,t.slice(6,t.length)):e.setAttributeNS(Gr,t,n);else{const r=o(t);null==n||r&&!1===n?e.removeAttribute(t):e.setAttribute(t,r?"":n)}}(e,t,r,s))}},forcePatchProp:(e,t)=>"value"===t},Hr);let Ws,Ks=!1;function Gs(){return Ws||(Ws=So(zs))}function qs(){return Ws=Ks?Ws:Co(zs),Ks=!0,Ws}function Js(e){if(A(e)){return document.querySelector(e)}return e}function Zs(e){throw e}function Qs(e,t,n,o){const r=new SyntaxError(String(e));return r.code=e,r.loc=t,r}const Xs=Symbol(""),Ys=Symbol(""),ei=Symbol(""),ti=Symbol(""),ni=Symbol(""),oi=Symbol(""),ri=Symbol(""),si=Symbol(""),ii=Symbol(""),li=Symbol(""),ci=Symbol(""),ai=Symbol(""),ui=Symbol(""),pi=Symbol(""),fi=Symbol(""),di=Symbol(""),hi=Symbol(""),mi=Symbol(""),gi=Symbol(""),vi=Symbol(""),yi=Symbol(""),bi=Symbol(""),_i=Symbol(""),xi=Symbol(""),Si=Symbol(""),Ci=Symbol(""),ki=Symbol(""),wi=Symbol(""),Ti=Symbol(""),Ni=Symbol(""),Ei=Symbol(""),$i={[Xs]:"Fragment",[Ys]:"Teleport",[ei]:"Suspense",[ti]:"KeepAlive",[ni]:"BaseTransition",[oi]:"openBlock",[ri]:"createBlock",[si]:"createVNode",[ii]:"createCommentVNode",[li]:"createTextVNode",[ci]:"createStaticVNode",[ai]:"resolveComponent",[ui]:"resolveDynamicComponent",[pi]:"resolveDirective",[fi]:"withDirectives",[di]:"renderList",[hi]:"renderSlot",[mi]:"createSlots",[gi]:"toDisplayString",[vi]:"mergeProps",[yi]:"toHandlers",[bi]:"camelize",[_i]:"capitalize",[xi]:"toHandlerKey",[Si]:"setBlockTracking",[Ci]:"pushScopeId",[ki]:"popScopeId",[wi]:"withScopeId",[Ti]:"withCtx",[Ni]:"unref",[Ei]:"isRef"};const Fi={source:"",start:{line:1,column:1,offset:0},end:{line:1,column:1,offset:0}};function Ai(e,t,n,o,r,s,i,l=!1,c=!1,a=Fi){return e&&(l?(e.helper(oi),e.helper(ri)):e.helper(si),i&&e.helper(fi)),{type:13,tag:t,props:n,children:o,patchFlag:r,dynamicProps:s,directives:i,isBlock:l,disableTracking:c,loc:a}}function Mi(e,t=Fi){return{type:17,loc:t,elements:e}}function Ii(e,t=Fi){return{type:15,loc:t,properties:e}}function Oi(e,t){return{type:16,loc:Fi,key:A(e)?Bi(e,!0):e,value:t}}function Bi(e,t,n=Fi,o=0){return{type:4,loc:n,content:e,isStatic:t,constType:t?3:o}}function Ri(e,t=Fi){return{type:8,loc:t,children:e}}function Pi(e,t=[],n=Fi){return{type:14,loc:n,callee:e,arguments:t}}function Vi(e,t,n=!1,o=!1,r=Fi){return{type:18,params:e,returns:t,newline:n,isSlot:o,loc:r}}function Li(e,t,n,o=!0){return{type:19,test:e,consequent:t,alternate:n,newline:o,loc:Fi}}const ji=e=>4===e.type&&e.isStatic,Ui=(e,t)=>e===t||e===z(t);function Hi(e){return Ui(e,"Teleport")?Ys:Ui(e,"Suspense")?ei:Ui(e,"KeepAlive")?ti:Ui(e,"BaseTransition")?ni:void 0}const Di=/^\d|[^\$\w]/,zi=e=>!Di.test(e),Wi=/^[A-Za-z_$\xA0-\uFFFF][\w$\xA0-\uFFFF]*(?:\s*\.\s*[A-Za-z_$\xA0-\uFFFF][\w$\xA0-\uFFFF]*|\[[^\]]+\])*$/,Ki=e=>!!e&&Wi.test(e.trim());function Gi(e,t,n){const o={source:e.source.substr(t,n),start:qi(e.start,e.source,t),end:e.end};return null!=n&&(o.end=qi(e.start,e.source,t+n)),o}function qi(e,t,n=t.length){return Ji(S({},e),t,n)}function Ji(e,t,n=t.length){let o=0,r=-1;for(let s=0;s4===e.key.type&&e.key.content===n))}e||r.properties.unshift(t),o=r}else o=Pi(n.helper(vi),[Ii([t]),r]);13===e.type?e.props=o:e.arguments[2]=o}function rl(e,t){return`_${t}_${e.replace(/[^\w]/g,"_")}`}const sl=/&(gt|lt|amp|apos|quot);/g,il={gt:">",lt:"<",amp:"&",apos:"'",quot:'"'},ll={delimiters:["{{","}}"],getNamespace:()=>0,getTextMode:()=>0,isVoidTag:y,isPreTag:y,isCustomElement:y,decodeEntities:e=>e.replace(sl,((e,t)=>il[t])),onError:Zs,comments:!1};function cl(e,t={}){const n=function(e,t){const n=S({},ll);for(const o in t)n[o]=t[o]||ll[o];return{options:n,column:1,line:1,offset:0,originalSource:e,source:e,inPre:!1,inVPre:!1}}(e,t),o=Sl(n);return function(e,t=Fi){return{type:0,children:e,helpers:[],components:[],directives:[],hoists:[],imports:[],cached:0,temps:0,codegenNode:void 0,loc:t}}(al(n,0,[]),Cl(n,o))}function al(e,t,n){const o=kl(n),r=o?o.ns:0,s=[];for(;!$l(e,t,n);){const i=e.source;let l;if(0===t||1===t)if(!e.inVPre&&wl(i,e.options.delimiters[0]))l=bl(e,t);else if(0===t&&"<"===i[0])if(1===i.length);else if("!"===i[1])l=wl(i,"\x3c!--")?fl(e):wl(i,""===i[2]){Tl(e,3);continue}if(/[a-z]/i.test(i[2])){gl(e,1,o);continue}l=dl(e)}else/[a-z]/i.test(i[1])?l=hl(e,n):"?"===i[1]&&(l=dl(e));if(l||(l=_l(e,t)),T(l))for(let e=0;e/.exec(e.source);if(o){n=e.source.slice(4,o.index);const t=e.source.slice(0,o.index);let r=1,s=0;for(;-1!==(s=t.indexOf("\x3c!--",r));)Tl(e,s-r+1),r=s+1;Tl(e,o.index+o[0].length-r+1)}else n=e.source.slice(4),Tl(e,e.source.length);return{type:3,content:n,loc:Cl(e,t)}}function dl(e){const t=Sl(e),n="?"===e.source[1]?1:2;let o;const r=e.source.indexOf(">");return-1===r?(o=e.source.slice(n),Tl(e,e.source.length)):(o=e.source.slice(n,r),Tl(e,r+1)),{type:3,content:o,loc:Cl(e,t)}}function hl(e,t){const n=e.inPre,o=e.inVPre,r=kl(t),s=gl(e,0,r),i=e.inPre&&!n,l=e.inVPre&&!o;if(s.isSelfClosing||e.options.isVoidTag(s.tag))return s;t.push(s);const c=e.options.getTextMode(s,r),a=al(e,c,t);if(t.pop(),s.children=a,Fl(e.source,s.tag))gl(e,1,r);else if(0===e.source.length&&"script"===s.tag.toLowerCase()){const e=a[0];e&&wl(e.loc.source,"\x3c!--")}return s.loc=Cl(e,s.loc.start),i&&(e.inPre=!1),l&&(e.inVPre=!1),s}const ml=t("if,else,else-if,for,slot");function gl(e,t,n){const o=Sl(e),r=/^<\/?([a-z][^\t\r\n\f />]*)/i.exec(e.source),s=r[1],i=e.options.getNamespace(s,n);Tl(e,r[0].length),Nl(e);const l=Sl(e),c=e.source;let a=vl(e,t);e.options.isPreTag(s)&&(e.inPre=!0),!e.inVPre&&a.some((e=>7===e.type&&"pre"===e.name))&&(e.inVPre=!0,S(e,l),e.source=c,a=vl(e,t).filter((e=>"v-pre"!==e.name)));let u=!1;0===e.source.length||(u=wl(e.source,"/>"),Tl(e,u?2:1));let p=0;const f=e.options;if(!e.inVPre&&!f.isCustomElement(s)){const e=a.some((e=>7===e.type&&"is"===e.name));f.isNativeTag&&!e?f.isNativeTag(s)||(p=1):(e||Hi(s)||f.isBuiltInComponent&&f.isBuiltInComponent(s)||/^[A-Z]/.test(s)||"component"===s)&&(p=1),"slot"===s?p=2:"template"===s&&a.some((e=>7===e.type&&ml(e.name)))&&(p=3)}return{type:1,ns:i,tag:s,tagType:p,props:a,isSelfClosing:u,children:[],loc:Cl(e,o),codegenNode:void 0}}function vl(e,t){const n=[],o=new Set;for(;e.source.length>0&&!wl(e.source,">")&&!wl(e.source,"/>");){if(wl(e.source,"/")){Tl(e,1),Nl(e);continue}const r=yl(e,o);0===t&&n.push(r),/^[^\t\r\n\f />]/.test(e.source),Nl(e)}return n}function yl(e,t){const n=Sl(e),o=/^[^\t\r\n\f />][^\t\r\n\f />=]*/.exec(e.source)[0];t.has(o),t.add(o);{const e=/["'<]/g;let t;for(;t=e.exec(o););}let r;Tl(e,o.length),/^[\t\r\n\f ]*=/.test(e.source)&&(Nl(e),Tl(e,1),Nl(e),r=function(e){const t=Sl(e);let n;const o=e.source[0],r='"'===o||"'"===o;if(r){Tl(e,1);const t=e.source.indexOf(o);-1===t?n=xl(e,e.source.length,4):(n=xl(e,t,4),Tl(e,1))}else{const t=/^[^\t\r\n\f >]+/.exec(e.source);if(!t)return;const o=/["'<=`]/g;let r;for(;r=o.exec(t[0]););n=xl(e,t[0].length,4)}return{content:n,isQuoted:r,loc:Cl(e,t)}}(e));const s=Cl(e,n);if(!e.inVPre&&/^(v-|:|@|#)/.test(o)){const t=/(?:^v-([a-z0-9-]+))?(?:(?::|^@|^#)(\[[^\]]+\]|[^\.]+))?(.+)?$/i.exec(o),i=t[1]||(wl(o,":")?"bind":wl(o,"@")?"on":"slot");let l;if(t[2]){const r="slot"===i,s=o.lastIndexOf(t[2]),c=Cl(e,El(e,n,s),El(e,n,s+t[2].length+(r&&t[3]||"").length));let a=t[2],u=!0;a.startsWith("[")?(u=!1,a.endsWith("]"),a=a.substr(1,a.length-2)):r&&(a+=t[3]||""),l={type:4,content:a,isStatic:u,constType:u?3:0,loc:c}}if(r&&r.isQuoted){const e=r.loc;e.start.offset++,e.start.column++,e.end=qi(e.start,r.content),e.source=e.source.slice(1,-1)}return{type:7,name:i,exp:r&&{type:4,content:r.content,isStatic:!1,constType:0,loc:r.loc},arg:l,modifiers:t[3]?t[3].substr(1).split("."):[],loc:s}}return{type:6,name:o,value:r&&{type:2,content:r.content,loc:r.loc},loc:s}}function bl(e,t){const[n,o]=e.options.delimiters,r=e.source.indexOf(o,n.length);if(-1===r)return;const s=Sl(e);Tl(e,n.length);const i=Sl(e),l=Sl(e),c=r-n.length,a=e.source.slice(0,c),u=xl(e,c,t),p=u.trim(),f=u.indexOf(p);f>0&&Ji(i,a,f);return Ji(l,a,c-(u.length-p.length-f)),Tl(e,o.length),{type:5,content:{type:4,isStatic:!1,constType:0,content:p,loc:Cl(e,i,l)},loc:Cl(e,s)}}function _l(e,t){const n=["<",e.options.delimiters[0]];3===t&&n.push("]]>");let o=e.source.length;for(let s=0;st&&(o=t)}const r=Sl(e);return{type:2,content:xl(e,o,t),loc:Cl(e,r)}}function xl(e,t,n){const o=e.source.slice(0,t);return Tl(e,t),2===n||3===n||-1===o.indexOf("&")?o:e.options.decodeEntities(o,4===n)}function Sl(e){const{column:t,line:n,offset:o}=e;return{column:t,line:n,offset:o}}function Cl(e,t,n){return{start:t,end:n=n||Sl(e),source:e.originalSource.slice(t.offset,n.offset)}}function kl(e){return e[e.length-1]}function wl(e,t){return e.startsWith(t)}function Tl(e,t){const{source:n}=e;Ji(e,n,t),e.source=n.slice(t)}function Nl(e){const t=/^[\t\r\n\f ]+/.exec(e.source);t&&Tl(e,t[0].length)}function El(e,t,n){return qi(t,e.originalSource.slice(t.offset,n),n)}function $l(e,t,n){const o=e.source;switch(t){case 0:if(wl(o,"=0;--e)if(Fl(o,n[e].tag))return!0;break;case 1:case 2:{const e=kl(n);if(e&&Fl(o,e.tag))return!0;break}case 3:if(wl(o,"]]>"))return!0}return!o}function Fl(e,t){return wl(e,"]/.test(e[2+t.length]||">")}function Al(e,t){Il(e,t,Ml(e,e.children[0]))}function Ml(e,t){const{children:n}=e;return 1===n.length&&1===t.type&&!nl(t)}function Il(e,t,n=!1){let o=!1,r=!0;const{children:s}=e;for(let i=0;i0){if(s<3&&(r=!1),s>=2){e.codegenNode.patchFlag="-1",e.codegenNode=t.hoist(e.codegenNode),o=!0;continue}}else{const n=e.codegenNode;if(13===n.type){const o=Pl(n);if((!o||512===o||1===o)&&Bl(e,t)>=2){const o=Rl(e);o&&(n.props=t.hoist(o))}}}}else if(12===e.type){const n=Ol(e.content,t);n>0&&(n<3&&(r=!1),n>=2&&(e.codegenNode=t.hoist(e.codegenNode),o=!0))}if(1===e.type){const n=1===e.tagType;n&&t.scopes.vSlot++,Il(e,t),n&&t.scopes.vSlot--}else if(11===e.type)Il(e,t,1===e.children.length);else if(9===e.type)for(let n=0;n1)for(let r=0;r`_${$i[S.helper(e)]}`,replaceNode(e){S.parent.children[S.childIndex]=S.currentNode=e},removeNode(e){const t=e?S.parent.children.indexOf(e):S.currentNode?S.childIndex:-1;e&&e!==S.currentNode?S.childIndex>t&&(S.childIndex--,S.onNodeRemoved()):(S.currentNode=null,S.onNodeRemoved()),S.parent.children.splice(t,1)},onNodeRemoved:()=>{},addIdentifiers(e){},removeIdentifiers(e){},hoist(e){S.hoists.push(e);const t=Bi(`_hoisted_${S.hoists.length}`,!1,e.loc,2);return t.hoisted=e,t},cache:(e,t=!1)=>function(e,t,n=!1){return{type:20,index:e,value:t,isVNode:n,loc:Fi}}(++S.cached,e,t)};return S}function Ll(e,t){const n=Vl(e,t);jl(e,n),t.hoistStatic&&Al(e,n),t.ssr||function(e,t){const{helper:n,removeHelper:o}=t,{children:r}=e;if(1===r.length){const t=r[0];if(Ml(e,t)&&t.codegenNode){const r=t.codegenNode;13===r.type&&(r.isBlock||(o(si),r.isBlock=!0,n(oi),n(ri))),e.codegenNode=r}else e.codegenNode=t}else if(r.length>1){let o=64;e.codegenNode=Ai(t,n(Xs),void 0,e.children,o+"",void 0,void 0,!0)}}(e,n),e.helpers=[...n.helpers.keys()],e.components=[...n.components],e.directives=[...n.directives],e.imports=n.imports,e.hoists=n.hoists,e.temps=n.temps,e.cached=n.cached}function jl(e,t){t.currentNode=e;const{nodeTransforms:n}=t,o=[];for(let s=0;s{n--};for(;nt===e:t=>e.test(t);return(e,o)=>{if(1===e.type){const{props:r}=e;if(3===e.tagType&&r.some(el))return;const s=[];for(let i=0;i`_${$i[e]}`,push(e,t){u.code+=e},indent(){p(++u.indentLevel)},deindent(e=!1){e?--u.indentLevel:p(--u.indentLevel)},newline(){p(u.indentLevel)}};function p(e){u.push("\n"+"  ".repeat(e))}return u}(e,t);t.onContextCreated&&t.onContextCreated(n);const{mode:o,push:r,prefixIdentifiers:s,indent:i,deindent:l,newline:c,ssr:a}=n,u=e.helpers.length>0,p=!s&&"module"!==o;!function(e,t){const{push:n,newline:o,runtimeGlobalName:r}=t,s=r,i=e=>`${$i[e]}: _${$i[e]}`;if(e.helpers.length>0&&(n(`const _Vue = ${s}\n`),e.hoists.length)){n(`const { ${[si,ii,li,ci].filter((t=>e.helpers.includes(t))).map(i).join(", ")} } = _Vue\n`)}(function(e,t){if(!e.length)return;t.pure=!0;const{push:n,newline:o}=t;o(),e.forEach(((e,r)=>{e&&(n(`const _hoisted_${r+1} = `),Gl(e,t),o())})),t.pure=!1})(e.hoists,t),o(),n("return ")}(e,n);if(r(`function ${a?"ssrRender":"render"}(${(a?["_ctx","_push","_parent","_attrs"]:["_ctx","_cache"]).join(", ")}) {`),i(),p&&(r("with (_ctx) {"),i(),u&&(r(`const { ${e.helpers.map((e=>`${$i[e]}: _${$i[e]}`)).join(", ")} } = _Vue`),r("\n"),c())),e.components.length&&(zl(e.components,"component",n),(e.directives.length||e.temps>0)&&c()),e.directives.length&&(zl(e.directives,"directive",n),e.temps>0&&c()),e.temps>0){r("let ");for(let t=0;t0?", ":""}_temp${t}`)}return(e.components.length||e.directives.length||e.temps)&&(r("\n"),c()),a||r("return "),e.codegenNode?Gl(e.codegenNode,n):r("null"),p&&(l(),r("}")),l(),r("}"),{ast:e,code:n.code,preamble:"",map:n.map?n.map.toJSON():void 0}}function zl(e,t,{helper:n,push:o,newline:r}){const s=n("component"===t?ai:pi);for(let i=0;i3||!1;t.push("["),n&&t.indent(),Kl(e,t,n),n&&t.deindent(),t.push("]")}function Kl(e,t,n=!1,o=!0){const{push:r,newline:s}=t;for(let i=0;ie||"null"))}([s,i,l,c,a]),t),n(")"),p&&n(")");u&&(n(", "),Gl(u,t),n(")"))}(e,t);break;case 14:!function(e,t){const{push:n,helper:o,pure:r}=t,s=A(e.callee)?e.callee:o(e.callee);r&&n(Hl);n(s+"(",e),Kl(e.arguments,t),n(")")}(e,t);break;case 15:!function(e,t){const{push:n,indent:o,deindent:r,newline:s}=t,{properties:i}=e;if(!i.length)return void n("{}",e);const l=i.length>1||!1;n(l?"{":"{ "),l&&o();for(let c=0;c "),(c||l)&&(n("{"),o());i?(c&&n("return "),T(i)?Wl(i,t):Gl(i,t)):l&&Gl(l,t);(c||l)&&(r(),n("}"));a&&n(")")}(e,t);break;case 19:!function(e,t){const{test:n,consequent:o,alternate:r,newline:s}=e,{push:i,indent:l,deindent:c,newline:a}=t;if(4===n.type){const e=!zi(n.content);e&&i("("),ql(n,t),e&&i(")")}else i("("),Gl(n,t),i(")");s&&l(),t.indentLevel++,s||i(" "),i("? "),Gl(o,t),t.indentLevel--,s&&a(),s||i(" "),i(": ");const u=19===r.type;u||t.indentLevel++;Gl(r,t),u||t.indentLevel--;s&&c(!0)}(e,t);break;case 20:!function(e,t){const{push:n,helper:o,indent:r,deindent:s,newline:i}=t;n(`_cache[${e.index}] || (`),e.isVNode&&(r(),n(`${o(Si)}(-1),`),i());n(`_cache[${e.index}] = `),Gl(e.value,t),e.isVNode&&(n(","),i(),n(`${o(Si)}(1),`),i(),n(`_cache[${e.index}]`),s());n(")")}(e,t)}}function ql(e,t){const{content:n,isStatic:o}=e;t.push(o?JSON.stringify(n):n,e)}function Jl(e,t){for(let n=0;nfunction(e,t,n,o){if(!("else"===t.name||t.exp&&t.exp.content.trim())){t.exp=Bi("true",!1,t.exp?t.exp.loc:e.loc)}if("if"===t.name){const r=Xl(e,t),s={type:9,loc:e.loc,branches:[r]};if(n.replaceNode(s),o)return o(s,r,!0)}else{const r=n.parent.children;let s=r.indexOf(e);for(;s-- >=-1;){const i=r[s];if(!i||2!==i.type||i.content.trim().length){if(i&&9===i.type){n.removeNode();const r=Xl(e,t);i.branches.push(r);const s=o&&o(i,r,!1);jl(r,n),s&&s(),n.currentNode=null}break}n.removeNode(i)}}}(e,t,n,((e,t,o)=>{const r=n.parent.children;let s=r.indexOf(e),i=0;for(;s-- >=0;){const e=r[s];e&&9===e.type&&(i+=e.branches.length)}return()=>{if(o)e.codegenNode=Yl(t,i,n);else{(function(e){for(;;)if(19===e.type){if(19!==e.alternate.type)return e;e=e.alternate}else 20===e.type&&(e=e.value)}(e.codegenNode)).alternate=Yl(t,i+e.branches.length-1,n)}}}))));function Xl(e,t){return{type:10,loc:e.loc,condition:"else"===t.name?void 0:t.exp,children:3!==e.tagType||Zi(e,"for")?[e]:e.children,userKey:Qi(e,"key")}}function Yl(e,t,n){return e.condition?Li(e.condition,ec(e,t,n),Pi(n.helper(ii),['""',"true"])):ec(e,t,n)}function ec(e,t,n){const{helper:o,removeHelper:r}=n,s=Oi("key",Bi(`${t}`,!1,Fi,2)),{children:i}=e,l=i[0];if(1!==i.length||1!==l.type){if(1===i.length&&11===l.type){const e=l.codegenNode;return ol(e,s,n),e}{let t=64;return Ai(n,o(Xs),Ii([s]),i,t+"",void 0,void 0,!0,!1,e.loc)}}{const e=l.codegenNode;return 13!==e.type||e.isBlock||(r(si),e.isBlock=!0,o(oi),o(ri)),ol(e,s,n),e}}const tc=Ul("for",((e,t,n)=>{const{helper:o,removeHelper:r}=n;return function(e,t,n,o){if(!t.exp)return;const r=sc(t.exp);if(!r)return;const{scopes:s}=n,{source:i,value:l,key:c,index:a}=r,u={type:11,loc:t.loc,source:i,valueAlias:l,keyAlias:c,objectIndexAlias:a,parseResult:r,children:tl(e)?e.children:[e]};n.replaceNode(u),s.vFor++;const p=o&&o(u);return()=>{s.vFor--,p&&p()}}(e,t,n,(t=>{const s=Pi(o(di),[t.source]),i=Qi(e,"key"),l=i?Oi("key",6===i.type?Bi(i.value.content,!0):i.exp):null,c=4===t.source.type&&t.source.constType>0,a=c?64:i?128:256;return t.codegenNode=Ai(n,o(Xs),void 0,s,a+"",void 0,void 0,!0,!c,e.loc),()=>{let i;const a=tl(e),{children:u}=t,p=1!==u.length||1!==u[0].type,f=nl(e)?e:a&&1===e.children.length&&nl(e.children[0])?e.children[0]:null;f?(i=f.codegenNode,a&&l&&ol(i,l,n)):p?i=Ai(n,o(Xs),l?Ii([l]):void 0,e.children,"64",void 0,void 0,!0):(i=u[0].codegenNode,a&&l&&ol(i,l,n),i.isBlock!==!c&&(i.isBlock?(r(oi),r(ri)):r(si)),i.isBlock=!c,i.isBlock?(o(oi),o(ri)):o(si)),s.arguments.push(Vi(lc(t.parseResult),i,!0))}}))}));const nc=/([\s\S]*?)\s+(?:in|of)\s+([\s\S]*)/,oc=/,([^,\}\]]*)(?:,([^,\}\]]*))?$/,rc=/^\(|\)$/g;function sc(e,t){const n=e.loc,o=e.content,r=o.match(nc);if(!r)return;const[,s,i]=r,l={source:ic(n,i.trim(),o.indexOf(i,s.length)),value:void 0,key:void 0,index:void 0};let c=s.trim().replace(rc,"").trim();const a=s.indexOf(c),u=c.match(oc);if(u){c=c.replace(oc,"").trim();const e=u[1].trim();let t;if(e&&(t=o.indexOf(e,a+c.length),l.key=ic(n,e,t)),u[2]){const r=u[2].trim();r&&(l.index=ic(n,r,o.indexOf(r,l.key?t+e.length:a+c.length)))}}return c&&(l.value=ic(n,c,a)),l}function ic(e,t,n){return Bi(t,!1,Gi(e,n,t.length))}function lc({value:e,key:t,index:n}){const o=[];return e&&o.push(e),t&&(e||o.push(Bi("_",!1)),o.push(t)),n&&(t||(e||o.push(Bi("_",!1)),o.push(Bi("__",!1))),o.push(n)),o}const cc=Bi("undefined",!1),ac=(e,t)=>{if(1===e.type&&(1===e.tagType||3===e.tagType)){const n=Zi(e,"slot");if(n)return t.scopes.vSlot++,()=>{t.scopes.vSlot--}}},uc=(e,t,n)=>Vi(e,t,!1,!0,t.length?t[0].loc:n);function pc(e,t,n=uc){t.helper(Ti);const{children:o,loc:r}=e,s=[],i=[],l=(e,t)=>Oi("default",n(e,t,r));let c=t.scopes.vSlot>0||t.scopes.vFor>0;const a=Zi(e,"slot",!0);if(a){const{arg:e,exp:t}=a;e&&!ji(e)&&(c=!0),s.push(Oi(e||Bi("default",!0),n(t,o,r)))}let u=!1,p=!1;const f=[],d=new Set;for(let g=0;gfunction(){if(1!==(e=t.currentNode).type||0!==e.tagType&&1!==e.tagType)return;const{tag:n,props:o}=e,r=1===e.tagType,s=r?function(e,t,n=!1){const{tag:o}=e,r=bc(o)?Qi(e,"is"):Zi(e,"is");if(r){const e=6===r.type?r.value&&Bi(r.value.content,!0):r.exp;if(e)return Pi(t.helper(ui),[e])}const s=Hi(o)||t.isBuiltInComponent(o);if(s)return n||t.helper(s),s;return t.helper(ai),t.components.add(o),rl(o,"component")}(e,t):`"${n}"`;let i,l,c,a,u,p,f=0,d=I(s)&&s.callee===ui||s===Ys||s===ei||!r&&("svg"===n||"foreignObject"===n||Qi(e,"key",!0));if(o.length>0){const n=gc(e,t);i=n.props,f=n.patchFlag,u=n.dynamicPropNames;const o=n.directives;p=o&&o.length?Mi(o.map((e=>function(e,t){const n=[],o=hc.get(e);o?n.push(t.helperString(o)):(t.helper(pi),t.directives.add(e.name),n.push(rl(e.name,"directive")));const{loc:r}=e;e.exp&&n.push(e.exp);e.arg&&(e.exp||n.push("void 0"),n.push(e.arg));if(Object.keys(e.modifiers).length){e.arg||(e.exp||n.push("void 0"),n.push("void 0"));const t=Bi("true",!1,r);n.push(Ii(e.modifiers.map((e=>Oi(e,t))),r))}return Mi(n,e.loc)}(e,t)))):void 0}if(e.children.length>0){s===ti&&(d=!0,f|=1024);if(r&&s!==Ys&&s!==ti){const{slots:n,hasDynamicSlots:o}=pc(e,t);l=n,o&&(f|=1024)}else if(1===e.children.length&&s!==Ys){const n=e.children[0],o=n.type,r=5===o||8===o;r&&0===Ol(n,t)&&(f|=1),l=r||2===o?n:e.children}else l=e.children}0!==f&&(c=String(f),u&&u.length&&(a=function(e){let t="[";for(let n=0,o=e.length;n{if(ji(e)){const o=e.content,r=_(o);if(i||!r||"onclick"===o.toLowerCase()||"onUpdate:modelValue"===o||L(o)||(h=!0),r&&L(o)&&(g=!0),20===n.type||(4===n.type||8===n.type)&&Ol(n,t)>0)return;"ref"===o?p=!0:"class"!==o||i?"style"!==o||i?"key"===o||v.includes(o)||v.push(o):d=!0:f=!0}else m=!0};for(let _=0;_1?Pi(t.helper(vi),c,s):c[0]):l.length&&(b=Ii(vc(l),s)),m?u|=16:(f&&(u|=2),d&&(u|=4),v.length&&(u|=8),h&&(u|=32)),0!==u&&32!==u||!(p||g||a.length>0)||(u|=512),{props:b,directives:a,patchFlag:u,dynamicPropNames:v}}function vc(e){const t=new Map,n=[];for(let o=0;o{if(nl(e)){const{children:n,loc:o}=e,{slotName:r,slotProps:s}=function(e,t){let n,o='"default"';const r=[];for(let s=0;s0){const{props:o,directives:s}=gc(e,t,r);n=o}return{slotName:o,slotProps:n}}(e,t),i=[t.prefixIdentifiers?"_ctx.$slots":"$slots",r];s&&i.push(s),n.length&&(s||i.push("{}"),i.push(Vi([],n,!1,!1,o))),t.scopeId&&!t.slotted&&(s||i.push("{}"),n.length||i.push("undefined"),i.push("true")),e.codegenNode=Pi(t.helper(hi),i,o)}};const xc=/^\s*([\w$_]+|\([^)]*?\))\s*=>|^\s*function(?:\s+[\w$]+)?\s*\(/,Sc=(e,t,n,o)=>{const{loc:r,modifiers:s,arg:i}=e;let l;if(4===i.type)if(i.isStatic){l=Bi(K(H(i.content)),!0,i.loc)}else l=Ri([`${n.helperString(xi)}(`,i,")"]);else l=i,l.children.unshift(`${n.helperString(xi)}(`),l.children.push(")");let c=e.exp;c&&!c.content.trim()&&(c=void 0);let a=n.cacheHandlers&&!c;if(c){const e=Ki(c.content),t=!(e||xc.test(c.content)),n=c.content.includes(";");(t||a&&e)&&(c=Ri([`${t?"$event":"(...args)"} => ${n?"{":"("}`,c,n?"}":")"]))}let u={props:[Oi(l,c||Bi("() => {}",!1,r))]};return o&&(u=o(u)),a&&(u.props[0].value=n.cache(u.props[0].value)),u},Cc=(e,t,n)=>{const{exp:o,modifiers:r,loc:s}=e,i=e.arg;return 4!==i.type?(i.children.unshift("("),i.children.push(') || ""')):i.isStatic||(i.content=`${i.content} || ""`),r.includes("camel")&&(4===i.type?i.content=i.isStatic?H(i.content):`${n.helperString(bi)}(${i.content})`:(i.children.unshift(`${n.helperString(bi)}(`),i.children.push(")"))),!o||4===o.type&&!o.content.trim()?{props:[Oi(i,Bi("",!0,s))]}:{props:[Oi(i,o)]}},kc=(e,t)=>{if(0===e.type||1===e.type||11===e.type||10===e.type)return()=>{const n=e.children;let o,r=!1;for(let e=0;e{if(1===e.type&&Zi(e,"once",!0)){if(wc.has(e))return;return wc.add(e),t.helper(Si),()=>{const e=t.currentNode;e.codegenNode&&(e.codegenNode=t.cache(e.codegenNode,!0))}}},Nc=(e,t,n)=>{const{exp:o,arg:r}=e;if(!o)return Ec();const s=o.loc.source;if(!Ki(4===o.type?o.content:s))return Ec();const i=r||Bi("modelValue",!0),l=r?ji(r)?`onUpdate:${r.content}`:Ri(['"onUpdate:" + ',r]):"onUpdate:modelValue";let c;c=Ri([`${n.isTS?"($event: any)":"$event"} => (`,o," = $event)"]);const a=[Oi(i,e.exp),Oi(l,c)];if(e.modifiers.length&&1===t.tagType){const t=e.modifiers.map((e=>(zi(e)?e:JSON.stringify(e))+": true")).join(", "),n=r?ji(r)?`${r.content}Modifiers`:Ri([r,' + "Modifiers"']):"modelModifiers";a.push(Oi(n,Bi(`{ ${t} }`,!1,e.loc,2)))}return Ec(a)};function Ec(e=[]){return{props:e}}function $c(e,t={}){const n=t.onError||Zs,o="module"===t.mode;!0===t.prefixIdentifiers?n(Qs(45)):o&&n(Qs(46));t.cacheHandlers&&n(Qs(47)),t.scopeId&&!o&&n(Qs(48));const r=A(e)?cl(e,t):e,[s,i]=[[Tc,Ql,tc,_c,mc,ac,kc],{on:Sc,bind:Cc,model:Nc}];return Ll(r,S({},t,{prefixIdentifiers:false,nodeTransforms:[...s,...t.nodeTransforms||[]],directiveTransforms:S({},i,t.directiveTransforms||{})})),Dl(r,S({},t,{prefixIdentifiers:false}))}const Fc=Symbol(""),Ac=Symbol(""),Mc=Symbol(""),Ic=Symbol(""),Oc=Symbol(""),Bc=Symbol(""),Rc=Symbol(""),Pc=Symbol(""),Vc=Symbol(""),Lc=Symbol("");var jc;let Uc;jc={[Fc]:"vModelRadio",[Ac]:"vModelCheckbox",[Mc]:"vModelText",[Ic]:"vModelSelect",[Oc]:"vModelDynamic",[Bc]:"withModifiers",[Rc]:"withKeys",[Pc]:"vShow",[Vc]:"Transition",[Lc]:"TransitionGroup"},Object.getOwnPropertySymbols(jc).forEach((e=>{$i[e]=jc[e]}));const Hc=t("style,iframe,script,noscript",!0),Dc={isVoidTag:p,isNativeTag:e=>a(e)||u(e),isPreTag:e=>"pre"===e,decodeEntities:function(e){return(Uc||(Uc=document.createElement("div"))).innerHTML=e,Uc.textContent},isBuiltInComponent:e=>Ui(e,"Transition")?Vc:Ui(e,"TransitionGroup")?Lc:void 0,getNamespace(e,t){let n=t?t.ns:0;if(t&&2===n)if("annotation-xml"===t.tag){if("svg"===e)return 1;t.props.some((e=>6===e.type&&"encoding"===e.name&&null!=e.value&&("text/html"===e.value.content||"application/xhtml+xml"===e.value.content)))&&(n=0)}else/^m(?:[ions]|text)$/.test(t.tag)&&"mglyph"!==e&&"malignmark"!==e&&(n=0);else t&&1===n&&("foreignObject"!==t.tag&&"desc"!==t.tag&&"title"!==t.tag||(n=0));if(0===n){if("svg"===e)return 1;if("math"===e)return 2}return n},getTextMode({tag:e,ns:t}){if(0===t){if("textarea"===e||"title"===e)return 1;if(Hc(e))return 2}return 0}},zc=(e,t)=>{const n=l(e);return Bi(JSON.stringify(n),!1,t,3)};const Wc=t("passive,once,capture"),Kc=t("stop,prevent,self,ctrl,shift,alt,meta,exact,middle"),Gc=t("left,right"),qc=t("onkeyup,onkeydown,onkeypress",!0),Jc=(e,t)=>ji(e)&&"onclick"===e.content.toLowerCase()?Bi(t,!0):4!==e.type?Ri(["(",e,`) === "onClick" ? "${t}" : (`,e,")"]):e,Zc=(e,t)=>{1!==e.type||0!==e.tagType||"script"!==e.tag&&"style"!==e.tag||t.removeNode()},Qc=[e=>{1===e.type&&e.props.forEach(((t,n)=>{6===t.type&&"style"===t.name&&t.value&&(e.props[n]={type:7,name:"bind",arg:Bi("style",!0,t.loc),exp:zc(t.value.content,t.loc),modifiers:[],loc:t.loc})}))}],Xc={cloak:()=>({props:[]}),html:(e,t,n)=>{const{exp:o,loc:r}=e;return t.children.length&&(t.children.length=0),{props:[Oi(Bi("innerHTML",!0,r),o||Bi("",!0))]}},text:(e,t,n)=>{const{exp:o,loc:r}=e;return t.children.length&&(t.children.length=0),{props:[Oi(Bi("textContent",!0),o?Pi(n.helperString(gi),[o],r):Bi("",!0))]}},model:(e,t,n)=>{const o=Nc(e,t,n);if(!o.props.length||1===t.tagType)return o;const{tag:r}=t,s=n.isCustomElement(r);if("input"===r||"textarea"===r||"select"===r||s){let e=Mc,i=!1;if("input"===r||s){const n=Qi(t,"type");if(n){if(7===n.type)e=Oc;else if(n.value)switch(n.value.content){case"radio":e=Fc;break;case"checkbox":e=Ac;break;case"file":i=!0}}else(function(e){return e.props.some((e=>!(7!==e.type||"bind"!==e.name||e.arg&&4===e.arg.type&&e.arg.isStatic)))})(t)&&(e=Oc)}else"select"===r&&(e=Ic);i||(o.needRuntime=n.helper(e))}return o.props=o.props.filter((e=>!(4===e.key.type&&"modelValue"===e.key.content))),o},on:(e,t,n)=>Sc(e,0,n,(t=>{const{modifiers:o}=e;if(!o.length)return t;let{key:r,value:s}=t.props[0];const{keyModifiers:i,nonKeyModifiers:l,eventOptionModifiers:c}=((e,t)=>{const n=[],o=[],r=[];for(let s=0;s({props:[],needRuntime:n.helper(Pc)})};const Yc=Object.create(null);function ea(e,t){if(!A(e)){if(!e.nodeType)return v;e=e.innerHTML}const n=e,o=Yc[n];if(o)return o;if("#"===e[0]){const t=document.querySelector(e);e=t?t.innerHTML:""}const{code:r}=function(e,t={}){return $c(e,S({},Dc,t,{nodeTransforms:[Zc,...Qc,...t.nodeTransforms||[]],directiveTransforms:S({},Xc,t.directiveTransforms||{}),transformHoist:null}))}(e,S({hoistStatic:!0,onError(e){throw e}},t)),s=new Function(r)();return s._rc=!0,Yc[n]=s}return Nr(ea),e.BaseTransition=Un,e.Comment=Vo,e.Fragment=Ro,e.KeepAlive=Jn,e.Static=Lo,e.Suspense=un,e.Teleport=Ao,e.Text=Po,e.Transition=is,e.TransitionGroup=Ss,e.callWithAsyncErrorHandling=Ct,e.callWithErrorHandling=St,e.camelize=H,e.capitalize=W,e.cloneVNode=Xo,e.compile=ea,e.computed=Or,e.createApp=(...e)=>{const t=Gs().createApp(...e),{mount:n}=t;return t.mount=e=>{const o=Js(e);if(!o)return;const r=t._component;F(r)||r.render||r.template||(r.template=o.innerHTML),o.innerHTML="";const s=n(o,!1,o instanceof SVGElement);return o instanceof Element&&(o.removeAttribute("v-cloak"),o.setAttribute("data-v-app","")),s},t},e.createBlock=Wo,e.createCommentVNode=function(e="",t=!1){return t?(Ho(),Wo(Vo,null,e)):Qo(Vo,null,e)},e.createHydrationRenderer=Co,e.createRenderer=So,e.createSSRApp=(...e)=>{const t=qs().createApp(...e),{mount:n}=t;return t.mount=e=>{const t=Js(e);if(t)return n(t,!0,t instanceof SVGElement)},t},e.createSlots=function(e,t){for(let n=0;n{let e;return a||(e=a=t().catch((e=>{if(e=e instanceof Error?e:new Error(String(e)),l)return new Promise(((t,n)=>{l(e,(()=>t((u++,a=null,p()))),(()=>n(e)),u+1)}));throw e})).then((t=>e!==a&&a?a:(t&&(t.__esModule||"Module"===t[Symbol.toStringTag])&&(t=t.default),c=t,t))))};return vo({__asyncLoader:p,name:"AsyncComponentWrapper",setup(){const e=_r;if(c)return()=>yo(c,e);const t=t=>{a=null,kt(t,e,13,!o)};if(i&&e.suspense)return p().then((t=>()=>yo(t,e))).catch((e=>(t(e),()=>o?Qo(o,{error:e}):null)));const l=at(!1),u=at(),f=at(!!r);return r&&setTimeout((()=>{f.value=!1}),r),null!=s&&setTimeout((()=>{if(!l.value&&!u.value){const e=new Error(`Async component timed out after ${s}ms.`);t(e),u.value=e}}),s),p().then((()=>{l.value=!0})).catch((e=>{t(e),u.value=e})),()=>l.value&&c?yo(c,e):u.value&&o?Qo(o,{error:u.value}):n&&!f.value?Qo(n):void 0}})},e.defineComponent=vo,e.defineEmit=function(){return null},e.defineProps=function(){return null},e.getCurrentInstance=xr,e.getTransitionRawChildren=Gn,e.h=Br,e.handleError=kt,e.hydrate=(...e)=>{qs().hydrate(...e)},e.initCustomFormatter=function(){},e.inject=sr,e.isProxy=st,e.isReactive=ot,e.isReadonly=rt,e.isRef=ct,e.isRuntimeOnly=()=>!kr,e.isVNode=Ko,e.markRaw=function(e){return J(e,"__v_skip",!0),e},e.mergeProps=or,e.nextTick=Vt,e.onActivated=Qn,e.onBeforeMount=kn,e.onBeforeUnmount=En,e.onBeforeUpdate=Tn,e.onDeactivated=Xn,e.onErrorCaptured=Mn,e.onMounted=wn,e.onRenderTracked=An,e.onRenderTriggered=Fn,e.onUnmounted=$n,e.onUpdated=Nn,e.openBlock=Ho,e.popScopeId=function(){en=null},e.provide=rr,e.proxyRefs=ht,e.pushScopeId=function(e){en=e},e.queuePostFlushCb=Ht,e.reactive=Ye,e.readonly=tt,e.ref=at,e.registerRuntimeCompiler=Nr,e.render=(...e)=>{Gs().render(...e)},e.renderList=function(e,t){let n;if(T(e)||A(e)){n=new Array(e.length);for(let o=0,r=e.length;onull==e?"":I(e)?JSON.stringify(e,h,2):String(e),e.toHandlerKey=K,e.toHandlers=function(e){const t={};for(const n in e)t[K(n)]=e[n];return t},e.toRaw=it,e.toRef=vt,e.toRefs=function(e){const t=T(e)?new Array(e.length):{};for(const n in e)t[n]=vt(e,n);return t},e.transformVNodeArgs=function(e){},e.triggerRef=function(e){pe(it(e),"set","value",void 0)},e.unref=ft,e.useContext=function(){const e=xr();return e.setupContext||(e.setupContext=$r(e))},e.useCssModule=function(e="$style"){return m},e.useCssVars=function(e){const t=xr();if(!t)return;const n=()=>os(t.subTree,e(t.proxy));wn((()=>In(n,{flush:"post"}))),Nn(n)},e.useSSRContext=()=>{},e.useTransitionState=Ln,e.vModelCheckbox=Fs,e.vModelDynamic=Ps,e.vModelRadio=Ms,e.vModelSelect=Is,e.vModelText=$s,e.vShow=Hs,e.version=Pr,e.warn=function(e,...t){ce();const n=bt.length?bt[bt.length-1].component:null,o=n&&n.appContext.config.warnHandler,r=function(){let e=bt[bt.length-1];if(!e)return[];const t=[];for(;e;){const n=t[0];n&&n.vnode===e?n.recurseCount++:t.push({vnode:e,recurseCount:0});const o=e.component&&e.component.parent;e=o&&o.vnode}return t}();if(o)St(o,n,11,[e+t.join(""),n&&n.proxy,r.map((({vnode:e})=>`at <${Ir(n,e.type)}>`)).join("\n"),r]);else{const n=[`[Vue warn]: ${e}`,...t];r.length&&n.push("\n",...function(e){const t=[];return e.forEach(((e,n)=>{t.push(...0===n?[]:["\n"],...function({vnode:e,recurseCount:t}){const n=t>0?`... (${t} recursive calls)`:"",o=` at <${Ir(e.component,e.type,!!e.component&&null==e.component.parent)}`,r=">"+n;return e.props?[o,..._t(e.props),r]:[o+r]}(e))})),t}(r)),console.warn(...n)}ae()},e.watch=Bn,e.watchEffect=In,e.withCtx=nn,e.withDirectives=function(e,t){if(null===Yt)return e;const n=Yt.proxy,o=e.dirs||(e.dirs=[]);for(let r=0;rn=>{if(!("key"in n))return;const o=z(n.key);return t.some((e=>e===o||Us[e]===o))?e(n):void 0},e.withModifiers=(e,t)=>(n,...o)=>{for(let e=0;enn,Object.defineProperty(e,"__esModule",{value:!0}),e}({});
var Vue=function(e){"use strict";function t(e,t){const n=Object.create(null),o=e.split(",");for(let r=0;r!!n[e.toLowerCase()]:e=>!!n[e]}const n=t("Infinity,undefined,NaN,isFinite,isNaN,parseFloat,parseInt,decodeURI,decodeURIComponent,encodeURI,encodeURIComponent,Math,Number,Date,Array,Object,Boolean,String,RegExp,Map,Set,JSON,Intl,BigInt"),o=t("itemscope,allowfullscreen,formnovalidate,ismap,nomodule,novalidate,readonly");function r(e){if(T(e)){const t={};for(let n=0;n{if(e){const n=e.split(i);n.length>1&&(t[n[0].trim()]=n[1].trim())}})),t}function c(e){let t="";if(A(e))t=e;else if(T(e))for(let n=0;nf(e,t)))}const h=(e,t)=>N(t)?{[`Map(${t.size})`]:[...t.entries()].reduce(((e,[t,n])=>(e[`${t} =>`]=n,e)),{})}:E(t)?{[`Set(${t.size})`]:[...t.values()]}:!I(t)||T(t)||P(t)?t:String(t),m={},g=[],v=()=>{},y=()=>!1,b=/^on[^a-z]/,_=e=>b.test(e),x=e=>e.startsWith("onUpdate:"),S=Object.assign,C=(e,t)=>{const n=e.indexOf(t);n>-1&&e.splice(n,1)},k=Object.prototype.hasOwnProperty,w=(e,t)=>k.call(e,t),T=Array.isArray,N=e=>"[object Map]"===R(e),E=e=>"[object Set]"===R(e),$=e=>e instanceof Date,F=e=>"function"==typeof e,A=e=>"string"==typeof e,M=e=>"symbol"==typeof e,I=e=>null!==e&&"object"==typeof e,O=e=>I(e)&&F(e.then)&&F(e.catch),B=Object.prototype.toString,R=e=>B.call(e),P=e=>"[object Object]"===R(e),V=e=>A(e)&&"NaN"!==e&&"-"!==e[0]&&""+parseInt(e,10)===e,L=t(",key,ref,onVnodeBeforeMount,onVnodeMounted,onVnodeBeforeUpdate,onVnodeUpdated,onVnodeBeforeUnmount,onVnodeUnmounted"),j=e=>{const t=Object.create(null);return n=>t[n]||(t[n]=e(n))},U=/-(\w)/g,H=j((e=>e.replace(U,((e,t)=>t?t.toUpperCase():"")))),D=/\B([A-Z])/g,z=j((e=>e.replace(D,"-$1").toLowerCase())),W=j((e=>e.charAt(0).toUpperCase()+e.slice(1))),K=j((e=>e?`on${W(e)}`:"")),G=(e,t)=>e!==t&&(e==e||t==t),q=(e,t)=>{for(let n=0;n{Object.defineProperty(e,t,{configurable:!0,enumerable:!1,value:n})},Z=e=>{const t=parseFloat(e);return isNaN(t)?e:t},Q=new WeakMap,X=[];let Y;const ee=Symbol(""),te=Symbol("");function ne(e,t=m){(function(e){return e&&!0===e._isEffect})(e)&&(e=e.raw);const n=function(e,t){const n=function(){if(!n.active)return t.scheduler?void 0:e();if(!X.includes(n)){se(n);try{return le.push(ie),ie=!0,X.push(n),Y=n,e()}finally{X.pop(),ae(),Y=X[X.length-1]}}};return n.id=re++,n.allowRecurse=!!t.allowRecurse,n._isEffect=!0,n.active=!0,n.raw=e,n.deps=[],n.options=t,n}(e,t);return t.lazy||n(),n}function oe(e){e.active&&(se(e),e.options.onStop&&e.options.onStop(),e.active=!1)}let re=0;function se(e){const{deps:t}=e;if(t.length){for(let n=0;n{e&&e.forEach((e=>{(e!==Y||e.allowRecurse)&&l.add(e)}))};if("clear"===t)i.forEach(c);else if("length"===n&&T(e))i.forEach(((e,t)=>{("length"===t||t>=o)&&c(e)}));else switch(void 0!==n&&c(i.get(n)),t){case"add":T(e)?V(n)&&c(i.get("length")):(c(i.get(ee)),N(e)&&c(i.get(te)));break;case"delete":T(e)||(c(i.get(ee)),N(e)&&c(i.get(te)));break;case"set":N(e)&&c(i.get(ee))}l.forEach((e=>{e.options.scheduler?e.options.scheduler(e):e()}))}const fe=t("__proto__,__v_isRef,__isVue"),de=new Set(Object.getOwnPropertyNames(Symbol).map((e=>Symbol[e])).filter(M)),he=be(),me=be(!1,!0),ge=be(!0),ve=be(!0,!0),ye={};function be(e=!1,t=!1){return function(n,o,r){if("__v_isReactive"===o)return!e;if("__v_isReadonly"===o)return e;if("__v_raw"===o&&r===(e?t?Qe:Ze:t?Je:qe).get(n))return n;const s=T(n);if(!e&&s&&w(ye,o))return Reflect.get(ye,o,r);const i=Reflect.get(n,o,r);if(M(o)?de.has(o):fe(o))return i;if(e||ue(n,0,o),t)return i;if(ct(i)){return!s||!V(o)?i.value:i}return I(i)?e?tt(i):Ye(i):i}}["includes","indexOf","lastIndexOf"].forEach((e=>{const t=Array.prototype[e];ye[e]=function(...e){const n=it(this);for(let t=0,r=this.length;t{const t=Array.prototype[e];ye[e]=function(...e){ce();const n=t.apply(this,e);return ae(),n}}));function _e(e=!1){return function(t,n,o,r){let s=t[n];if(!e&&(o=it(o),s=it(s),!T(t)&&ct(s)&&!ct(o)))return s.value=o,!0;const i=T(t)&&V(n)?Number(n)!0,deleteProperty:(e,t)=>!0},Ce=S({},xe,{get:me,set:_e(!0)}),ke=S({},Se,{get:ve}),we=e=>I(e)?Ye(e):e,Te=e=>I(e)?tt(e):e,Ne=e=>e,Ee=e=>Reflect.getPrototypeOf(e);function $e(e,t,n=!1,o=!1){const r=it(e=e.__v_raw),s=it(t);t!==s&&!n&&ue(r,0,t),!n&&ue(r,0,s);const{has:i}=Ee(r),l=o?Ne:n?Te:we;return i.call(r,t)?l(e.get(t)):i.call(r,s)?l(e.get(s)):void 0}function Fe(e,t=!1){const n=this.__v_raw,o=it(n),r=it(e);return e!==r&&!t&&ue(o,0,e),!t&&ue(o,0,r),e===r?n.has(e):n.has(e)||n.has(r)}function Ae(e,t=!1){return e=e.__v_raw,!t&&ue(it(e),0,ee),Reflect.get(e,"size",e)}function Me(e){e=it(e);const t=it(this);return Ee(t).has.call(t,e)||(t.add(e),pe(t,"add",e,e)),this}function Ie(e,t){t=it(t);const n=it(this),{has:o,get:r}=Ee(n);let s=o.call(n,e);s||(e=it(e),s=o.call(n,e));const i=r.call(n,e);return n.set(e,t),s?G(t,i)&&pe(n,"set",e,t):pe(n,"add",e,t),this}function Oe(e){const t=it(this),{has:n,get:o}=Ee(t);let r=n.call(t,e);r||(e=it(e),r=n.call(t,e)),o&&o.call(t,e);const s=t.delete(e);return r&&pe(t,"delete",e,void 0),s}function Be(){const e=it(this),t=0!==e.size,n=e.clear();return t&&pe(e,"clear",void 0,void 0),n}function Re(e,t){return function(n,o){const r=this,s=r.__v_raw,i=it(s),l=t?Ne:e?Te:we;return!e&&ue(i,0,ee),s.forEach(((e,t)=>n.call(o,l(e),l(t),r)))}}function Pe(e,t,n){return function(...o){const r=this.__v_raw,s=it(r),i=N(s),l="entries"===e||e===Symbol.iterator&&i,c="keys"===e&&i,a=r[e](...o),u=n?Ne:t?Te:we;return!t&&ue(s,0,c?te:ee),{next(){const{value:e,done:t}=a.next();return t?{value:e,done:t}:{value:l?[u(e[0]),u(e[1])]:u(e),done:t}},[Symbol.iterator](){return this}}}}function Ve(e){return function(...t){return"delete"!==e&&this}}const Le={get(e){return $e(this,e)},get size(){return Ae(this)},has:Fe,add:Me,set:Ie,delete:Oe,clear:Be,forEach:Re(!1,!1)},je={get(e){return $e(this,e,!1,!0)},get size(){return Ae(this)},has:Fe,add:Me,set:Ie,delete:Oe,clear:Be,forEach:Re(!1,!0)},Ue={get(e){return $e(this,e,!0)},get size(){return Ae(this,!0)},has(e){return Fe.call(this,e,!0)},add:Ve("add"),set:Ve("set"),delete:Ve("delete"),clear:Ve("clear"),forEach:Re(!0,!1)},He={get(e){return $e(this,e,!0,!0)},get size(){return Ae(this,!0)},has(e){return Fe.call(this,e,!0)},add:Ve("add"),set:Ve("set"),delete:Ve("delete"),clear:Ve("clear"),forEach:Re(!0,!0)};function De(e,t){const n=t?e?He:je:e?Ue:Le;return(t,o,r)=>"__v_isReactive"===o?!e:"__v_isReadonly"===o?e:"__v_raw"===o?t:Reflect.get(w(n,o)&&o in t?n:t,o,r)}["keys","values","entries",Symbol.iterator].forEach((e=>{Le[e]=Pe(e,!1,!1),Ue[e]=Pe(e,!0,!1),je[e]=Pe(e,!1,!0),He[e]=Pe(e,!0,!0)}));const ze={get:De(!1,!1)},We={get:De(!1,!0)},Ke={get:De(!0,!1)},Ge={get:De(!0,!0)},qe=new WeakMap,Je=new WeakMap,Ze=new WeakMap,Qe=new WeakMap;function Xe(e){return e.__v_skip||!Object.isExtensible(e)?0:function(e){switch(e){case"Object":case"Array":return 1;case"Map":case"Set":case"WeakMap":case"WeakSet":return 2;default:return 0}}((e=>R(e).slice(8,-1))(e))}function Ye(e){return e&&e.__v_isReadonly?e:nt(e,!1,xe,ze,qe)}function et(e){return nt(e,!1,Ce,We,Je)}function tt(e){return nt(e,!0,Se,Ke,Ze)}function nt(e,t,n,o,r){if(!I(e))return e;if(e.__v_raw&&(!t||!e.__v_isReactive))return e;const s=r.get(e);if(s)return s;const i=Xe(e);if(0===i)return e;const l=new Proxy(e,2===i?o:n);return r.set(e,l),l}function ot(e){return rt(e)?ot(e.__v_raw):!(!e||!e.__v_isReactive)}function rt(e){return!(!e||!e.__v_isReadonly)}function st(e){return ot(e)||rt(e)}function it(e){return e&&it(e.__v_raw)||e}const lt=e=>I(e)?Ye(e):e;function ct(e){return Boolean(e&&!0===e.__v_isRef)}function at(e){return pt(e)}class ut{constructor(e,t=!1){this._rawValue=e,this._shallow=t,this.__v_isRef=!0,this._value=t?e:lt(e)}get value(){return ue(it(this),0,"value"),this._value}set value(e){G(it(e),this._rawValue)&&(this._rawValue=e,this._value=this._shallow?e:lt(e),pe(it(this),"set","value",e))}}function pt(e,t=!1){return ct(e)?e:new ut(e,t)}function ft(e){return ct(e)?e.value:e}const dt={get:(e,t,n)=>ft(Reflect.get(e,t,n)),set:(e,t,n,o)=>{const r=e[t];return ct(r)&&!ct(n)?(r.value=n,!0):Reflect.set(e,t,n,o)}};function ht(e){return ot(e)?e:new Proxy(e,dt)}class mt{constructor(e){this.__v_isRef=!0;const{get:t,set:n}=e((()=>ue(this,0,"value")),(()=>pe(this,"set","value")));this._get=t,this._set=n}get value(){return this._get()}set value(e){this._set(e)}}class gt{constructor(e,t){this._object=e,this._key=t,this.__v_isRef=!0}get value(){return this._object[this._key]}set value(e){this._object[this._key]=e}}function vt(e,t){return ct(e[t])?e[t]:new gt(e,t)}class yt{constructor(e,t,n){this._setter=t,this._dirty=!0,this.__v_isRef=!0,this.effect=ne(e,{lazy:!0,scheduler:()=>{this._dirty||(this._dirty=!0,pe(it(this),"set","value"))}}),this.__v_isReadonly=n}get value(){const e=it(this);return e._dirty&&(e._value=this.effect(),e._dirty=!1),ue(e,0,"value"),e._value}set value(e){this._setter(e)}}const bt=[];function _t(e){const t=[],n=Object.keys(e);return n.slice(0,3).forEach((n=>{t.push(...xt(n,e[n]))})),n.length>3&&t.push(" ..."),t}function xt(e,t,n){return A(t)?(t=JSON.stringify(t),n?t:[`${e}=${t}`]):"number"==typeof t||"boolean"==typeof t||null==t?n?t:[`${e}=${t}`]:ct(t)?(t=xt(e,it(t.value),!0),n?t:[`${e}=Ref<`,t,">"]):F(t)?[`${e}=fn${t.name?`<${t.name}>`:""}`]:(t=it(t),n?t:[`${e}=`,t])}function St(e,t,n,o){let r;try{r=o?e(...o):e()}catch(s){kt(s,t,n)}return r}function Ct(e,t,n,o){if(F(e)){const r=St(e,t,n,o);return r&&O(r)&&r.catch((e=>{kt(e,t,n)})),r}const r=[];for(let s=0;s>>1;Wt(Nt[e])-1?Nt.splice(t,0,e):Nt.push(e),jt()}}function jt(){wt||Tt||(Tt=!0,Rt=Bt.then(Kt))}function Ut(e,t,n,o){T(e)?n.push(...e):t&&t.includes(e,e.allowRecurse?o+1:o)||n.push(e),jt()}function Ht(e){Ut(e,It,Mt,Ot)}function Dt(e,t=null){if($t.length){for(Pt=t,Ft=[...new Set($t)],$t.length=0,At=0;AtWt(e)-Wt(t))),Ot=0;Otnull==e.id?1/0:e.id;function Kt(e){Tt=!1,wt=!0,Dt(e),Nt.sort(((e,t)=>Wt(e)-Wt(t)));try{for(Et=0;Ete.trim())):t&&(r=n.map(Z))}let l,c=o[l=K(t)]||o[l=K(H(t))];!c&&s&&(c=o[l=K(z(t))]),c&&Ct(c,e,6,r);const a=o[l+"Once"];if(a){if(e.emitted){if(e.emitted[l])return}else(e.emitted={})[l]=!0;Ct(a,e,6,r)}}function qt(e,t,n=!1){if(!t.deopt&&void 0!==e.__emits)return e.__emits;const o=e.emits;let r={},s=!1;if(!F(e)){const o=e=>{const n=qt(e,t,!0);n&&(s=!0,S(r,n))};!n&&t.mixins.length&&t.mixins.forEach(o),e.extends&&o(e.extends),e.mixins&&e.mixins.forEach(o)}return o||s?(T(o)?o.forEach((e=>r[e]=null)):S(r,o),e.__emits=r):e.__emits=null}function Jt(e,t){return!(!e||!_(t))&&(t=t.slice(2).replace(/Once$/,""),w(e,t[0].toLowerCase()+t.slice(1))||w(e,z(t))||w(e,t))}let Zt=0;const Qt=e=>Zt+=e;function Xt(e){return e.some((e=>!Ko(e)||e.type!==Vo&&!(e.type===Ro&&!Xt(e.children))))?e:null}let Yt=null,en=null;function tn(e){const t=Yt;return Yt=e,en=e&&e.type.__scopeId||null,t}function nn(e,t=Yt){if(!t)return e;const n=(...n)=>{Zt||Ho(!0);const o=tn(t),r=e(...n);return tn(o),Zt||Do(),r};return n._c=!0,n}function on(e){const{type:t,vnode:n,proxy:o,withProxy:r,props:s,propsOptions:[i],slots:l,attrs:c,emit:a,render:u,renderCache:p,data:f,setupState:d,ctx:h}=e;let m;const g=tn(e);try{let e;if(4&n.shapeFlag){const t=r||o;m=er(u.call(t,t,p,s,d,f,h)),e=c}else{const n=t;0,m=er(n(s,n.length>1?{attrs:c,slots:l,emit:a}:null)),e=t.props?c:sn(c)}let g=m;if(!1!==t.inheritAttrs&&e){const t=Object.keys(e),{shapeFlag:n}=g;t.length&&(1&n||6&n)&&(i&&t.some(x)&&(e=ln(e,i)),g=Xo(g,e))}n.dirs&&(g.dirs=g.dirs?g.dirs.concat(n.dirs):n.dirs),n.transition&&(g.transition=n.transition),m=g}catch(v){jo.length=0,kt(v,e,1),m=Qo(Vo)}return tn(g),m}function rn(e){let t;for(let n=0;n{let t;for(const n in e)("class"===n||"style"===n||_(n))&&((t||(t={}))[n]=e[n]);return t},ln=(e,t)=>{const n={};for(const o in e)x(o)&&o.slice(9)in t||(n[o]=e[o]);return n};function cn(e,t,n){const o=Object.keys(t);if(o.length!==Object.keys(e).length)return!0;for(let r=0;r0?(a(null,e.ssFallback,t,n,o,null,s,i),hn(f,e.ssFallback)):f.resolve()}(t,n,o,r,s,i,l,c,a):function(e,t,n,o,r,s,i,l,{p:c,um:a,o:{createElement:u}}){const p=t.suspense=e.suspense;p.vnode=t,t.el=e.el;const f=t.ssContent,d=t.ssFallback,{activeBranch:h,pendingBranch:m,isInFallback:g,isHydrating:v}=p;if(m)p.pendingBranch=f,Go(f,m)?(c(m,f,p.hiddenContainer,null,r,p,s,i,l),p.deps<=0?p.resolve():g&&(c(h,d,n,o,r,null,s,i,l),hn(p,d))):(p.pendingId++,v?(p.isHydrating=!1,p.activeBranch=m):a(m,r,p),p.deps=0,p.effects.length=0,p.hiddenContainer=u("div"),g?(c(null,f,p.hiddenContainer,null,r,p,s,i,l),p.deps<=0?p.resolve():(c(h,d,n,o,r,null,s,i,l),hn(p,d))):h&&Go(f,h)?(c(h,f,n,o,r,p,s,i,l),p.resolve(!0)):(c(null,f,p.hiddenContainer,null,r,p,s,i,l),p.deps<=0&&p.resolve()));else if(h&&Go(f,h))c(h,f,n,o,r,p,s,i,l),hn(p,f);else{const e=t.props&&t.props.onPending;if(F(e)&&e(),p.pendingBranch=f,p.pendingId++,c(null,f,p.hiddenContainer,null,r,p,s,i,l),p.deps<=0)p.resolve();else{const{timeout:e,pendingId:t}=p;e>0?setTimeout((()=>{p.pendingId===t&&p.fallback(d)}),e):0===e&&p.fallback(d)}}}(e,t,n,o,r,i,l,c,a)},hydrate:function(e,t,n,o,r,s,i,l,c){const a=t.suspense=pn(t,o,n,e.parentNode,document.createElement("div"),null,r,s,i,l,!0),u=c(e,a.pendingBranch=t.ssContent,n,a,s,i);0===a.deps&&a.resolve();return u},create:pn};function pn(e,t,n,o,r,s,i,l,c,a,u=!1){const{p:p,m:f,um:d,n:h,o:{parentNode:m,remove:g}}=a,v=Z(e.props&&e.props.timeout),y={vnode:e,parent:t,parentComponent:n,isSVG:i,container:o,hiddenContainer:r,anchor:s,deps:0,pendingId:0,timeout:"number"==typeof v?v:-1,activeBranch:null,pendingBranch:null,isInFallback:!0,isHydrating:u,isUnmounted:!1,effects:[],resolve(e=!1){const{vnode:t,activeBranch:n,pendingBranch:o,pendingId:r,effects:s,parentComponent:i,container:l}=y;if(y.isHydrating)y.isHydrating=!1;else if(!e){const e=n&&o.transition&&"out-in"===o.transition.mode;e&&(n.transition.afterLeave=()=>{r===y.pendingId&&f(o,l,t,0)});let{anchor:t}=y;n&&(t=h(n),d(n,i,y,!0)),e||f(o,l,t,0)}hn(y,o),y.pendingBranch=null,y.isInFallback=!1;let c=y.parent,a=!1;for(;c;){if(c.pendingBranch){c.effects.push(...s),a=!0;break}c=c.parent}a||Ht(s),y.effects=[];const u=t.props&&t.props.onResolve;F(u)&&u()},fallback(e){if(!y.pendingBranch)return;const{vnode:t,activeBranch:n,parentComponent:o,container:r,isSVG:s}=y,i=t.props&&t.props.onFallback;F(i)&&i();const a=h(n),u=()=>{y.isInFallback&&(p(null,e,r,a,o,null,s,l,c),hn(y,e))},f=e.transition&&"out-in"===e.transition.mode;f&&(n.transition.afterLeave=u),d(n,o,null,!0),y.isInFallback=!0,f||u()},move(e,t,n){y.activeBranch&&f(y.activeBranch,e,t,n),y.container=e},next:()=>y.activeBranch&&h(y.activeBranch),registerDep(e,t){const n=!!y.pendingBranch;n&&y.deps++;const o=e.vnode.el;e.asyncDep.catch((t=>{kt(t,e,0)})).then((r=>{if(e.isUnmounted||y.isUnmounted||y.pendingId!==e.suspenseId)return;e.asyncResolved=!0;const{vnode:s}=e;Tr(e,r),o&&(s.el=o);const l=!o&&e.subTree.el;t(e,s,m(o||e.subTree.el),o?null:h(e.subTree),y,i,c),l&&g(l),an(e,s.el),n&&0==--y.deps&&y.resolve()}))},unmount(e,t){y.isUnmounted=!0,y.activeBranch&&d(y.activeBranch,n,e,t),y.pendingBranch&&d(y.pendingBranch,n,e,t)}};return y}function fn(e){if(F(e)&&(e=e()),T(e)){e=rn(e)}return er(e)}function dn(e,t){t&&t.pendingBranch?T(e)?t.effects.push(...e):t.effects.push(e):Ht(e)}function hn(e,t){e.activeBranch=t;const{vnode:n,parentComponent:o}=e,r=n.el=t.el;o&&o.subTree===n&&(o.vnode.el=r,an(o,r))}function mn(e,t,n,o){const[r,s]=e.propsOptions;if(t)for(const i in t){const s=t[i];if(L(i))continue;let l;r&&w(r,l=H(i))?n[l]=s:Jt(e.emitsOptions,i)||(o[i]=s)}if(s){const t=it(n);for(let o=0;o{i=!0;const[n,o]=vn(e,t,!0);S(r,n),o&&s.push(...o)};!n&&t.mixins.length&&t.mixins.forEach(o),e.extends&&o(e.extends),e.mixins&&e.mixins.forEach(o)}if(!o&&!i)return e.__props=g;if(T(o))for(let l=0;l-1,n[1]=o<0||t-1||w(n,"default"))&&s.push(e)}}}return e.__props=[r,s]}function yn(e){return"$"!==e[0]}function bn(e){const t=e&&e.toString().match(/^\s*function (\w+)/);return t?t[1]:""}function _n(e,t){return bn(e)===bn(t)}function xn(e,t){return T(t)?t.findIndex((t=>_n(t,e))):F(t)&&_n(t,e)?0:-1}function Sn(e,t,n=_r,o=!1){if(n){const r=n[e]||(n[e]=[]),s=t.__weh||(t.__weh=(...o)=>{if(n.isUnmounted)return;ce(),Sr(n);const r=Ct(t,n,e,o);return Sr(null),ae(),r});return o?r.unshift(s):r.push(s),s}}const Cn=e=>(t,n=_r)=>!wr&&Sn(e,t,n),kn=Cn("bm"),wn=Cn("m"),Tn=Cn("bu"),Nn=Cn("u"),En=Cn("bum"),$n=Cn("um"),Fn=Cn("rtg"),An=Cn("rtc"),Mn=(e,t=_r)=>{Sn("ec",e,t)};function In(e,t){return Rn(e,null,t)}const On={};function Bn(e,t,n){return Rn(e,t,n)}function Rn(e,t,{immediate:n,deep:o,flush:r,onTrack:s,onTrigger:i}=m,l=_r){let c,a,u=!1;if(ct(e)?(c=()=>e.value,u=!!e._shallow):ot(e)?(c=()=>e,o=!0):c=T(e)?()=>e.map((e=>ct(e)?e.value:ot(e)?Vn(e):F(e)?St(e,l,2,[l&&l.proxy]):void 0)):F(e)?t?()=>St(e,l,2,[l&&l.proxy]):()=>{if(!l||!l.isUnmounted)return a&&a(),Ct(e,l,3,[p])}:v,t&&o){const e=c;c=()=>Vn(e())}let p=e=>{a=g.options.onStop=()=>{St(e,l,4)}},f=T(e)?[]:On;const d=()=>{if(g.active)if(t){const e=g();(o||u||G(e,f))&&(a&&a(),Ct(t,l,3,[e,f===On?void 0:f,p]),f=e)}else g()};let h;d.allowRecurse=!!t,h="sync"===r?d:"post"===r?()=>_o(d,l&&l.suspense):()=>{!l||l.isMounted?function(e){Ut(e,Ft,$t,At)}(d):d()};const g=ne(c,{lazy:!0,onTrack:s,onTrigger:i,scheduler:h});return Fr(g,l),t?n?d():f=g():"post"===r?_o(g,l&&l.suspense):g(),()=>{oe(g),l&&C(l.effects,g)}}function Pn(e,t,n){const o=this.proxy;return Rn(A(e)?()=>o[e]:e.bind(o),t.bind(o),n,this)}function Vn(e,t=new Set){if(!I(e)||t.has(e))return e;if(t.add(e),ct(e))Vn(e.value,t);else if(T(e))for(let n=0;n{Vn(e,t)}));else for(const n in e)Vn(e[n],t);return e}function Ln(){const e={isMounted:!1,isLeaving:!1,isUnmounting:!1,leavingVNodes:new Map};return wn((()=>{e.isMounted=!0})),En((()=>{e.isUnmounting=!0})),e}const jn=[Function,Array],Un={name:"BaseTransition",props:{mode:String,appear:Boolean,persisted:Boolean,onBeforeEnter:jn,onEnter:jn,onAfterEnter:jn,onEnterCancelled:jn,onBeforeLeave:jn,onLeave:jn,onAfterLeave:jn,onLeaveCancelled:jn,onBeforeAppear:jn,onAppear:jn,onAfterAppear:jn,onAppearCancelled:jn},setup(e,{slots:t}){const n=xr(),o=Ln();let r;return()=>{const s=t.default&&Gn(t.default(),!0);if(!s||!s.length)return;const i=it(e),{mode:l}=i,c=s[0];if(o.isLeaving)return zn(c);const a=Wn(c);if(!a)return zn(c);const u=Dn(a,i,o,n);Kn(a,u);const p=n.subTree,f=p&&Wn(p);let d=!1;const{getTransitionKey:h}=a.type;if(h){const e=h();void 0===r?r=e:e!==r&&(r=e,d=!0)}if(f&&f.type!==Vo&&(!Go(a,f)||d)){const e=Dn(f,i,o,n);if(Kn(f,e),"out-in"===l)return o.isLeaving=!0,e.afterLeave=()=>{o.isLeaving=!1,n.update()},zn(c);"in-out"===l&&a.type!==Vo&&(e.delayLeave=(e,t,n)=>{Hn(o,f)[String(f.key)]=f,e._leaveCb=()=>{t(),e._leaveCb=void 0,delete u.delayedLeave},u.delayedLeave=n})}return c}}};function Hn(e,t){const{leavingVNodes:n}=e;let o=n.get(t.type);return o||(o=Object.create(null),n.set(t.type,o)),o}function Dn(e,t,n,o){const{appear:r,mode:s,persisted:i=!1,onBeforeEnter:l,onEnter:c,onAfterEnter:a,onEnterCancelled:u,onBeforeLeave:p,onLeave:f,onAfterLeave:d,onLeaveCancelled:h,onBeforeAppear:m,onAppear:g,onAfterAppear:v,onAppearCancelled:y}=t,b=String(e.key),_=Hn(n,e),x=(e,t)=>{e&&Ct(e,o,9,t)},S={mode:s,persisted:i,beforeEnter(t){let o=l;if(!n.isMounted){if(!r)return;o=m||l}t._leaveCb&&t._leaveCb(!0);const s=_[b];s&&Go(e,s)&&s.el._leaveCb&&s.el._leaveCb(),x(o,[t])},enter(e){let t=c,o=a,s=u;if(!n.isMounted){if(!r)return;t=g||c,o=v||a,s=y||u}let i=!1;const l=e._enterCb=t=>{i||(i=!0,x(t?s:o,[e]),S.delayedLeave&&S.delayedLeave(),e._enterCb=void 0)};t?(t(e,l),t.length<=1&&l()):l()},leave(t,o){const r=String(e.key);if(t._enterCb&&t._enterCb(!0),n.isUnmounting)return o();x(p,[t]);let s=!1;const i=t._leaveCb=n=>{s||(s=!0,o(),x(n?h:d,[t]),t._leaveCb=void 0,_[r]===e&&delete _[r])};_[r]=e,f?(f(t,i),f.length<=1&&i()):i()},clone:e=>Dn(e,t,n,o)};return S}function zn(e){if(qn(e))return(e=Xo(e)).children=null,e}function Wn(e){return qn(e)?e.children?e.children[0]:void 0:e}function Kn(e,t){6&e.shapeFlag&&e.component?Kn(e.component.subTree,t):128&e.shapeFlag?(e.ssContent.transition=t.clone(e.ssContent),e.ssFallback.transition=t.clone(e.ssFallback)):e.transition=t}function Gn(e,t=!1){let n=[],o=0;for(let r=0;r1)for(let r=0;re.type.__isKeepAlive,Jn={name:"KeepAlive",__isKeepAlive:!0,props:{include:[String,RegExp,Array],exclude:[String,RegExp,Array],max:[String,Number]},setup(e,{slots:t}){const n=xr(),o=n.ctx;if(!o.renderer)return t.default;const r=new Map,s=new Set;let i=null;const l=n.suspense,{renderer:{p:c,m:a,um:u,o:{createElement:p}}}=o,f=p("div");function d(e){to(e),u(e,n,l)}function h(e){r.forEach(((t,n)=>{const o=Mr(t.type);!o||e&&e(o)||m(n)}))}function m(e){const t=r.get(e);i&&t.type===i.type?i&&to(i):d(t),r.delete(e),s.delete(e)}o.activate=(e,t,n,o,r)=>{const s=e.component;a(e,t,n,0,l),c(s.vnode,e,t,n,s,l,o,e.slotScopeIds,r),_o((()=>{s.isDeactivated=!1,s.a&&q(s.a);const t=e.props&&e.props.onVnodeMounted;t&&wo(t,s.parent,e)}),l)},o.deactivate=e=>{const t=e.component;a(e,f,null,1,l),_o((()=>{t.da&&q(t.da);const n=e.props&&e.props.onVnodeUnmounted;n&&wo(n,t.parent,e),t.isDeactivated=!0}),l)},Bn((()=>[e.include,e.exclude]),(([e,t])=>{e&&h((t=>Zn(e,t))),t&&h((e=>!Zn(t,e)))}),{flush:"post",deep:!0});let g=null;const v=()=>{null!=g&&r.set(g,no(n.subTree))};return wn(v),Nn(v),En((()=>{r.forEach((e=>{const{subTree:t,suspense:o}=n,r=no(t);if(e.type!==r.type)d(e);else{to(r);const e=r.component.da;e&&_o(e,o)}}))})),()=>{if(g=null,!t.default)return null;const n=t.default(),o=n[0];if(n.length>1)return i=null,n;if(!(Ko(o)&&(4&o.shapeFlag||128&o.shapeFlag)))return i=null,o;let l=no(o);const c=l.type,a=Mr(c),{include:u,exclude:p,max:f}=e;if(u&&(!a||!Zn(u,a))||p&&a&&Zn(p,a))return i=l,o;const d=null==l.key?c:l.key,h=r.get(d);return l.el&&(l=Xo(l),128&o.shapeFlag&&(o.ssContent=l)),g=d,h?(l.el=h.el,l.component=h.component,l.transition&&Kn(l,l.transition),l.shapeFlag|=512,s.delete(d),s.add(d)):(s.add(d),f&&s.size>parseInt(f,10)&&m(s.values().next().value)),l.shapeFlag|=256,i=l,o}}};function Zn(e,t){return T(e)?e.some((e=>Zn(e,t))):A(e)?e.split(",").indexOf(t)>-1:!!e.test&&e.test(t)}function Qn(e,t){Yn(e,"a",t)}function Xn(e,t){Yn(e,"da",t)}function Yn(e,t,n=_r){const o=e.__wdc||(e.__wdc=()=>{let t=n;for(;t;){if(t.isDeactivated)return;t=t.parent}e()});if(Sn(t,o,n),n){let e=n.parent;for(;e&&e.parent;)qn(e.parent.vnode)&&eo(o,t,n,e),e=e.parent}}function eo(e,t,n,o){const r=Sn(t,e,o,!0);$n((()=>{C(o[t],r)}),n)}function to(e){let t=e.shapeFlag;256&t&&(t-=256),512&t&&(t-=512),e.shapeFlag=t}function no(e){return 128&e.shapeFlag?e.ssContent:e}const oo=e=>"_"===e[0]||"$stable"===e,ro=e=>T(e)?e.map(er):[er(e)],so=(e,t,n)=>nn((e=>ro(t(e))),n),io=(e,t)=>{const n=e._ctx;for(const o in e){if(oo(o))continue;const r=e[o];if(F(r))t[o]=so(0,r,n);else if(null!=r){const e=ro(r);t[o]=()=>e}}},lo=(e,t)=>{const n=ro(t);e.slots.default=()=>n};function co(e,t,n,o){const r=e.dirs,s=t&&t.dirs;for(let i=0;i(s.has(e)||(e&&F(e.install)?(s.add(e),e.install(l,...t)):F(e)&&(s.add(e),e(l,...t))),l),mixin:e=>(r.mixins.includes(e)||(r.mixins.push(e),(e.props||e.emits)&&(r.deopt=!0)),l),component:(e,t)=>t?(r.components[e]=t,l):r.components[e],directive:(e,t)=>t?(r.directives[e]=t,l):r.directives[e],mount(s,c,a){if(!i){const u=Qo(n,o);return u.appContext=r,c&&t?t(u,s):e(u,s,a),i=!0,l._container=s,s.__vue_app__=l,u.component.proxy}},unmount(){i&&(e(null,l._container),delete l._container.__vue_app__)},provide:(e,t)=>(r.provides[e]=t,l)};return l}}let fo=!1;const ho=e=>/svg/.test(e.namespaceURI)&&"foreignObject"!==e.tagName,mo=e=>8===e.nodeType;function go(e){const{mt:t,p:n,o:{patchProp:o,nextSibling:r,parentNode:s,remove:i,insert:l,createComment:c}}=e,a=(n,o,i,l,c,m=!1)=>{const g=mo(n)&&"["===n.data,v=()=>d(n,o,i,l,c,g),{type:y,ref:b,shapeFlag:_}=o,x=n.nodeType;o.el=n;let S=null;switch(y){case Po:3!==x?S=v():(n.data!==o.children&&(fo=!0,n.data=o.children),S=r(n));break;case Vo:S=8!==x||g?v():r(n);break;case Lo:if(1===x){S=n;const e=!o.children.length;for(let t=0;t{t(o,e,null,i,l,ho(e),m)},u=o.type.__asyncLoader;u?u().then(a):a(),S=g?h(n):r(n)}else 64&_?S=8!==x?v():o.type.hydrate(n,o,i,l,c,m,e,p):128&_&&(S=o.type.hydrate(n,o,i,l,ho(s(n)),c,m,e,a))}return null!=b&&xo(b,null,l,o),S},u=(e,t,n,r,s,l)=>{l=l||!!t.dynamicChildren;const{props:c,patchFlag:a,shapeFlag:u,dirs:f}=t;if(-1!==a){if(f&&co(t,null,n,"created"),c)if(!l||16&a||32&a)for(const t in c)!L(t)&&_(t)&&o(e,t,null,c[t]);else c.onClick&&o(e,"onClick",null,c.onClick);let d;if((d=c&&c.onVnodeBeforeMount)&&wo(d,n,t),f&&co(t,null,n,"beforeMount"),((d=c&&c.onVnodeMounted)||f)&&dn((()=>{d&&wo(d,n,t),f&&co(t,null,n,"mounted")}),r),16&u&&(!c||!c.innerHTML&&!c.textContent)){let o=p(e.firstChild,t,e,n,r,s,l);for(;o;){fo=!0;const e=o;o=o.nextSibling,i(e)}}else 8&u&&e.textContent!==t.children&&(fo=!0,e.textContent=t.children)}return e.nextSibling},p=(e,t,o,r,s,i,l)=>{l=l||!!t.dynamicChildren;const c=t.children,u=c.length;for(let p=0;p{const{slotScopeIds:u}=t;u&&(i=i?i.concat(u):u);const f=s(e),d=p(r(e),t,f,n,o,i,a);return d&&mo(d)&&"]"===d.data?r(t.anchor=d):(fo=!0,l(t.anchor=c("]"),f,d),d)},d=(e,t,o,l,c,a)=>{if(fo=!0,t.el=null,a){const t=h(e);for(;;){const n=r(e);if(!n||n===t)break;i(n)}}const u=r(e),p=s(e);return i(e),n(null,t,p,u,o,l,ho(p),c),u},h=e=>{let t=0;for(;e;)if((e=r(e))&&mo(e)&&("["===e.data&&t++,"]"===e.data)){if(0===t)return r(e);t--}return e};return[(e,t)=>{fo=!1,a(t.firstChild,e,null,null,null),zt(),fo&&console.error("Hydration completed but contains mismatches.")},a]}function vo(e){return F(e)?{setup:e,name:e.name}:e}function yo(e,{vnode:{ref:t,props:n,children:o}}){const r=Qo(e,n,o);return r.ref=t,r}const bo={scheduler:Lt,allowRecurse:!0},_o=dn,xo=(e,t,n,o)=>{if(T(e))return void e.forEach(((e,r)=>xo(e,t&&(T(t)?t[r]:t),n,o)));let r;if(o){if(o.type.__asyncLoader)return;r=4&o.shapeFlag?o.component.exposed||o.component.proxy:o.el}else r=null;const{i:s,r:i}=e,l=t&&t.r,c=s.refs===m?s.refs={}:s.refs,a=s.setupState;if(null!=l&&l!==i&&(A(l)?(c[l]=null,w(a,l)&&(a[l]=null)):ct(l)&&(l.value=null)),A(i)){const e=()=>{c[i]=r,w(a,i)&&(a[i]=r)};r?(e.id=-1,_o(e,n)):e()}else if(ct(i)){const e=()=>{i.value=r};r?(e.id=-1,_o(e,n)):e()}else F(i)&&St(i,s,12,[r,c])};function So(e){return ko(e)}function Co(e){return ko(e,go)}function ko(e,t){const{insert:n,remove:o,patchProp:r,forcePatchProp:s,createElement:i,createText:l,createComment:c,setText:a,setElementText:u,parentNode:p,nextSibling:f,setScopeId:d=v,cloneNode:h,insertStaticContent:y}=e,b=(e,t,n,o=null,r=null,s=null,i=!1,l=null,c=!1)=>{e&&!Go(e,t)&&(o=Y(e),K(e,r,s,!0),e=null),-2===t.patchFlag&&(c=!1,t.dynamicChildren=null);const{type:a,ref:u,shapeFlag:p}=t;switch(a){case Po:_(e,t,n,o);break;case Vo:x(e,t,n,o);break;case Lo:null==e&&C(t,n,o,i);break;case Ro:M(e,t,n,o,r,s,i,l,c);break;default:1&p?k(e,t,n,o,r,s,i,l,c):6&p?I(e,t,n,o,r,s,i,l,c):(64&p||128&p)&&a.process(e,t,n,o,r,s,i,l,c,te)}null!=u&&r&&xo(u,e&&e.ref,s,t)},_=(e,t,o,r)=>{if(null==e)n(t.el=l(t.children),o,r);else{const n=t.el=e.el;t.children!==e.children&&a(n,t.children)}},x=(e,t,o,r)=>{null==e?n(t.el=c(t.children||""),o,r):t.el=e.el},C=(e,t,n,o)=>{[e.el,e.anchor]=y(e.children,t,n,o)},k=(e,t,n,o,r,s,i,l,c)=>{i=i||"svg"===t.type,null==e?T(t,n,o,r,s,i,l,c):$(e,t,r,s,i,l,c)},T=(e,t,o,s,l,c,a,p)=>{let f,d;const{type:m,props:g,shapeFlag:v,transition:y,patchFlag:b,dirs:_}=e;if(e.el&&void 0!==h&&-1===b)f=e.el=h(e.el);else{if(f=e.el=i(e.type,c,g&&g.is,g),8&v?u(f,e.children):16&v&&E(e.children,f,null,s,l,c&&"foreignObject"!==m,a,p||!!e.dynamicChildren),_&&co(e,null,s,"created"),g){for(const t in g)L(t)||r(f,t,null,g[t],c,e.children,s,l,X);(d=g.onVnodeBeforeMount)&&wo(d,s,e)}N(f,e,e.scopeId,a,s)}_&&co(e,null,s,"beforeMount");const x=(!l||l&&!l.pendingBranch)&&y&&!y.persisted;x&&y.beforeEnter(f),n(f,t,o),((d=g&&g.onVnodeMounted)||x||_)&&_o((()=>{d&&wo(d,s,e),x&&y.enter(f),_&&co(e,null,s,"mounted")}),l)},N=(e,t,n,o,r)=>{if(n&&d(e,n),o)for(let s=0;s{for(let a=c;a{const a=t.el=e.el;let{patchFlag:p,dynamicChildren:f,dirs:d}=t;p|=16&e.patchFlag;const h=e.props||m,g=t.props||m;let v;if((v=g.onVnodeBeforeUpdate)&&wo(v,n,t,e),d&&co(t,e,n,"beforeUpdate"),p>0){if(16&p)A(a,t,h,g,n,o,i);else if(2&p&&h.class!==g.class&&r(a,"class",null,g.class,i),4&p&&r(a,"style",h.style,g.style,i),8&p){const l=t.dynamicProps;for(let t=0;t{v&&wo(v,n,t,e),d&&co(t,e,n,"updated")}),o)},F=(e,t,n,o,r,s,i)=>{for(let l=0;l{if(n!==o){for(const a in o){if(L(a))continue;const u=o[a],p=n[a];(u!==p||s&&s(e,a))&&r(e,a,p,u,c,t.children,i,l,X)}if(n!==m)for(const s in n)L(s)||s in o||r(e,s,n[s],null,c,t.children,i,l,X)}},M=(e,t,o,r,s,i,c,a,u)=>{const p=t.el=e?e.el:l(""),f=t.anchor=e?e.anchor:l("");let{patchFlag:d,dynamicChildren:h,slotScopeIds:m}=t;d>0&&(u=!0),m&&(a=a?a.concat(m):m),null==e?(n(p,o,r),n(f,o,r),E(t.children,o,f,s,i,c,a,u)):d>0&&64&d&&h&&e.dynamicChildren?(F(e.dynamicChildren,h,o,s,i,c,a),(null!=t.key||s&&t===s.subTree)&&To(e,t,!0)):j(e,t,o,f,s,i,c,a,u)},I=(e,t,n,o,r,s,i,l,c)=>{t.slotScopeIds=l,null==e?512&t.shapeFlag?r.ctx.activate(t,n,o,i,c):B(t,n,o,r,s,i,c):R(e,t,c)},B=(e,t,n,o,r,s,i)=>{const l=e.component=function(e,t,n){const o=e.type,r=(t?t.appContext:e.appContext)||yr,s={uid:br++,vnode:e,type:o,parent:t,appContext:r,root:null,next:null,subTree:null,update:null,render:null,proxy:null,exposed:null,withProxy:null,effects:null,provides:t?t.provides:Object.create(r.provides),accessCache:null,renderCache:[],components:null,directives:null,propsOptions:vn(o,r),emitsOptions:qt(o,r),emit:null,emitted:null,propsDefaults:m,ctx:m,data:m,props:m,attrs:m,slots:m,refs:m,setupState:m,setupContext:null,suspense:n,suspenseId:n?n.pendingId:0,asyncDep:null,asyncResolved:!1,isMounted:!1,isUnmounted:!1,isDeactivated:!1,bc:null,c:null,bm:null,m:null,bu:null,u:null,um:null,bum:null,da:null,a:null,rtg:null,rtc:null,ec:null};return s.ctx={_:s},s.root=t?t.root:s,s.emit=Gt.bind(null,s),s}(e,o,r);if(qn(e)&&(l.ctx.renderer=te),function(e,t=!1){wr=t;const{props:n,children:o}=e.vnode,r=Cr(e);(function(e,t,n,o=!1){const r={},s={};J(s,qo,1),e.propsDefaults=Object.create(null),mn(e,t,r,s),e.props=n?o?r:et(r):e.type.props?r:s,e.attrs=s})(e,n,r,t),((e,t)=>{if(32&e.vnode.shapeFlag){const n=t._;n?(e.slots=t,J(t,"_",n)):io(t,e.slots={})}else e.slots={},t&&lo(e,t);J(e.slots,qo,1)})(e,o);const s=r?function(e,t){const n=e.type;e.accessCache=Object.create(null),e.proxy=new Proxy(e.ctx,gr);const{setup:o}=n;if(o){const n=e.setupContext=o.length>1?$r(e):null;_r=e,ce();const r=St(o,e,0,[e.props,n]);if(ae(),_r=null,O(r)){if(t)return r.then((t=>{Tr(e,t)})).catch((t=>{kt(t,e,0)}));e.asyncDep=r}else Tr(e,r)}else Er(e)}(e,t):void 0;wr=!1}(l),l.asyncDep){if(r&&r.registerDep(l,P),!e.el){const e=l.subTree=Qo(Vo);x(null,e,t,n)}}else P(l,e,t,n,r,s,i)},R=(e,t,n)=>{const o=t.component=e.component;if(function(e,t,n){const{props:o,children:r,component:s}=e,{props:i,children:l,patchFlag:c}=t,a=s.emitsOptions;if(t.dirs||t.transition)return!0;if(!(n&&c>=0))return!(!r&&!l||l&&l.$stable)||o!==i&&(o?!i||cn(o,i,a):!!i);if(1024&c)return!0;if(16&c)return o?cn(o,i,a):!!i;if(8&c){const e=t.dynamicProps;for(let t=0;tEt&&Nt.splice(t,1)}(o.update),o.update()}else t.component=e.component,t.el=e.el,o.vnode=t},P=(e,t,n,o,r,s,i)=>{e.update=ne((function(){if(e.isMounted){let t,{next:n,bu:o,u:l,parent:c,vnode:a}=e,u=n;n?(n.el=a.el,V(e,n,i)):n=a,o&&q(o),(t=n.props&&n.props.onVnodeBeforeUpdate)&&wo(t,c,n,a);const f=on(e),d=e.subTree;e.subTree=f,b(d,f,p(d.el),Y(d),e,r,s),n.el=f.el,null===u&&an(e,f.el),l&&_o(l,r),(t=n.props&&n.props.onVnodeUpdated)&&_o((()=>{wo(t,c,n,a)}),r)}else{let i;const{el:l,props:c}=t,{bm:a,m:u,parent:p}=e;a&&q(a),(i=c&&c.onVnodeBeforeMount)&&wo(i,p,t);const f=e.subTree=on(e);if(l&&se?se(t.el,f,e,r,null):(b(null,f,n,o,e,r,s),t.el=f.el),u&&_o(u,r),i=c&&c.onVnodeMounted){const e=t;_o((()=>{wo(i,p,e)}),r)}const{a:d}=e;d&&256&t.shapeFlag&&_o(d,r),e.isMounted=!0,t=n=o=null}}),bo)},V=(e,t,n)=>{t.component=e;const o=e.vnode.props;e.vnode=t,e.next=null,function(e,t,n,o){const{props:r,attrs:s,vnode:{patchFlag:i}}=e,l=it(r),[c]=e.propsOptions;if(!(o||i>0)||16&i){let o;mn(e,t,r,s);for(const s in l)t&&(w(t,s)||(o=z(s))!==s&&w(t,o))||(c?!n||void 0===n[s]&&void 0===n[o]||(r[s]=gn(c,t||m,s,void 0,e)):delete r[s]);if(s!==l)for(const e in s)t&&w(t,e)||delete s[e]}else if(8&i){const n=e.vnode.dynamicProps;for(let o=0;o{const{vnode:o,slots:r}=e;let s=!0,i=m;if(32&o.shapeFlag){const e=t._;e?n&&1===e?s=!1:(S(r,t),n||1!==e||delete r._):(s=!t.$stable,io(t,r)),i=t}else t&&(lo(e,t),i={default:1});if(s)for(const l in r)oo(l)||l in i||delete r[l]})(e,t.children,n),ce(),Dt(void 0,e.update),ae()},j=(e,t,n,o,r,s,i,l,c=!1)=>{const a=e&&e.children,p=e?e.shapeFlag:0,f=t.children,{patchFlag:d,shapeFlag:h}=t;if(d>0){if(128&d)return void D(a,f,n,o,r,s,i,l,c);if(256&d)return void U(a,f,n,o,r,s,i,l,c)}8&h?(16&p&&X(a,r,s),f!==a&&u(n,f)):16&p?16&h?D(a,f,n,o,r,s,i,l,c):X(a,r,s,!0):(8&p&&u(n,""),16&h&&E(f,n,o,r,s,i,l,c))},U=(e,t,n,o,r,s,i,l,c)=>{const a=(e=e||g).length,u=(t=t||g).length,p=Math.min(a,u);let f;for(f=0;fu?X(e,r,s,!0,!1,p):E(t,n,o,r,s,i,l,c,p)},D=(e,t,n,o,r,s,i,l,c)=>{let a=0;const u=t.length;let p=e.length-1,f=u-1;for(;a<=p&&a<=f;){const o=e[a],u=t[a]=c?tr(t[a]):er(t[a]);if(!Go(o,u))break;b(o,u,n,null,r,s,i,l,c),a++}for(;a<=p&&a<=f;){const o=e[p],a=t[f]=c?tr(t[f]):er(t[f]);if(!Go(o,a))break;b(o,a,n,null,r,s,i,l,c),p--,f--}if(a>p){if(a<=f){const e=f+1,p=ef)for(;a<=p;)K(e[a],r,s,!0),a++;else{const d=a,h=a,m=new Map;for(a=h;a<=f;a++){const e=t[a]=c?tr(t[a]):er(t[a]);null!=e.key&&m.set(e.key,a)}let v,y=0;const _=f-h+1;let x=!1,S=0;const C=new Array(_);for(a=0;a<_;a++)C[a]=0;for(a=d;a<=p;a++){const o=e[a];if(y>=_){K(o,r,s,!0);continue}let u;if(null!=o.key)u=m.get(o.key);else for(v=h;v<=f;v++)if(0===C[v-h]&&Go(o,t[v])){u=v;break}void 0===u?K(o,r,s,!0):(C[u-h]=a+1,u>=S?S=u:x=!0,b(o,t[u],n,null,r,s,i,l,c),y++)}const k=x?function(e){const t=e.slice(),n=[0];let o,r,s,i,l;const c=e.length;for(o=0;o0&&(t[o]=n[s-1]),n[s]=o)}}s=n.length,i=n[s-1];for(;s-- >0;)n[s]=i,i=t[i];return n}(C):g;for(v=k.length-1,a=_-1;a>=0;a--){const e=h+a,p=t[e],f=e+1{const{el:i,type:l,transition:c,children:a,shapeFlag:u}=e;if(6&u)return void W(e.component.subTree,t,o,r);if(128&u)return void e.suspense.move(t,o,r);if(64&u)return void l.move(e,t,o,te);if(l===Ro){n(i,t,o);for(let e=0;e{let s;for(;e&&e!==t;)s=f(e),n(e,o,r),e=s;n(t,o,r)})(e,t,o);if(2!==r&&1&u&&c)if(0===r)c.beforeEnter(i),n(i,t,o),_o((()=>c.enter(i)),s);else{const{leave:e,delayLeave:r,afterLeave:s}=c,l=()=>n(i,t,o),a=()=>{e(i,(()=>{l(),s&&s()}))};r?r(i,l,a):a()}else n(i,t,o)},K=(e,t,n,o=!1,r=!1)=>{const{type:s,props:i,ref:l,children:c,dynamicChildren:a,shapeFlag:u,patchFlag:p,dirs:f}=e;if(null!=l&&xo(l,null,n,null),256&u)return void t.ctx.deactivate(e);const d=1&u&&f;let h;if((h=i&&i.onVnodeBeforeUnmount)&&wo(h,t,e),6&u)Q(e.component,n,o);else{if(128&u)return void e.suspense.unmount(n,o);d&&co(e,null,t,"beforeUnmount"),64&u?e.type.remove(e,t,n,r,te,o):a&&(s!==Ro||p>0&&64&p)?X(a,t,n,!1,!0):(s===Ro&&(128&p||256&p)||!r&&16&u)&&X(c,t,n),o&&G(e)}((h=i&&i.onVnodeUnmounted)||d)&&_o((()=>{h&&wo(h,t,e),d&&co(e,null,t,"unmounted")}),n)},G=e=>{const{type:t,el:n,anchor:r,transition:s}=e;if(t===Ro)return void Z(n,r);if(t===Lo)return void(({el:e,anchor:t})=>{let n;for(;e&&e!==t;)n=f(e),o(e),e=n;o(t)})(e);const i=()=>{o(n),s&&!s.persisted&&s.afterLeave&&s.afterLeave()};if(1&e.shapeFlag&&s&&!s.persisted){const{leave:t,delayLeave:o}=s,r=()=>t(n,i);o?o(e.el,i,r):r()}else i()},Z=(e,t)=>{let n;for(;e!==t;)n=f(e),o(e),e=n;o(t)},Q=(e,t,n)=>{const{bum:o,effects:r,update:s,subTree:i,um:l}=e;if(o&&q(o),r)for(let c=0;c{e.isUnmounted=!0}),t),t&&t.pendingBranch&&!t.isUnmounted&&e.asyncDep&&!e.asyncResolved&&e.suspenseId===t.pendingId&&(t.deps--,0===t.deps&&t.resolve())},X=(e,t,n,o=!1,r=!1,s=0)=>{for(let i=s;i6&e.shapeFlag?Y(e.component.subTree):128&e.shapeFlag?e.suspense.next():f(e.anchor||e.el),ee=(e,t,n)=>{null==e?t._vnode&&K(t._vnode,null,null,!0):b(t._vnode||null,e,t,null,null,null,n),zt(),t._vnode=e},te={p:b,um:K,m:W,r:G,mt:B,mc:E,pc:j,pbc:F,n:Y,o:e};let re,se;return t&&([re,se]=t(te)),{render:ee,hydrate:re,createApp:po(ee,re)}}function wo(e,t,n,o=null){Ct(e,t,7,[n,o])}function To(e,t,n=!1){const o=e.children,r=t.children;if(T(o)&&T(r))for(let s=0;se&&(e.disabled||""===e.disabled),Eo=e=>"undefined"!=typeof SVGElement&&e instanceof SVGElement,$o=(e,t)=>{const n=e&&e.to;if(A(n)){if(t){return t(n)}return null}return n};function Fo(e,t,n,{o:{insert:o},m:r},s=2){0===s&&o(e.targetAnchor,t,n);const{el:i,anchor:l,shapeFlag:c,children:a,props:u}=e,p=2===s;if(p&&o(i,t,n),(!p||No(u))&&16&c)for(let f=0;f{16&v&&u(y,e,t,r,s,i,l,c)};g?b(n,a):p&&b(p,f)}else{t.el=e.el;const o=t.anchor=e.anchor,u=t.target=e.target,d=t.targetAnchor=e.targetAnchor,m=No(e.props),v=m?n:u,y=m?o:d;if(i=i||Eo(u),t.dynamicChildren?(f(e.dynamicChildren,t.dynamicChildren,v,r,s,i,l),To(e,t,!0)):c||p(e,t,v,y,r,s,i,l,!1),g)m||Fo(t,n,o,a,1);else if((t.props&&t.props.to)!==(e.props&&e.props.to)){const e=t.target=$o(t.props,h);e&&Fo(t,e,null,a,0)}else m&&Fo(t,u,d,a,1)}},remove(e,t,n,o,{um:r,o:{remove:s}},i){const{shapeFlag:l,children:c,anchor:a,targetAnchor:u,target:p,props:f}=e;if(p&&s(u),(i||!No(f))&&(s(a),16&l))for(let d=0;d0&&Uo&&Uo.push(s),s}function Ko(e){return!!e&&!0===e.__v_isVNode}function Go(e,t){return e.type===t.type&&e.key===t.key}const qo="__vInternal",Jo=({key:e})=>null!=e?e:null,Zo=({ref:e})=>null!=e?A(e)||ct(e)||F(e)?{i:Yt,r:e}:e:null,Qo=function(e,t=null,n=null,o=0,s=null,i=!1){e&&e!==Io||(e=Vo);if(Ko(e)){const o=Xo(e,t,!0);return n&&nr(o,n),o}l=e,F(l)&&"__vccOpts"in l&&(e=e.__vccOpts);var l;if(t){(st(t)||qo in t)&&(t=S({},t));let{class:e,style:n}=t;e&&!A(e)&&(t.class=c(e)),I(n)&&(st(n)&&!T(n)&&(n=S({},n)),t.style=r(n))}const a=A(e)?1:(e=>e.__isSuspense)(e)?128:(e=>e.__isTeleport)(e)?64:I(e)?4:F(e)?2:0,u={__v_isVNode:!0,__v_skip:!0,type:e,props:t,key:t&&Jo(t),ref:t&&Zo(t),scopeId:en,slotScopeIds:null,children:null,component:null,suspense:null,ssContent:null,ssFallback:null,dirs:null,transition:null,el:null,anchor:null,target:null,targetAnchor:null,staticCount:0,shapeFlag:a,patchFlag:o,dynamicProps:s,dynamicChildren:null,appContext:null};if(nr(u,n),128&a){const{content:e,fallback:t}=function(e){const{shapeFlag:t,children:n}=e;let o,r;return 32&t?(o=fn(n.default),r=fn(n.fallback)):(o=fn(n),r=er(null)),{content:o,fallback:r}}(u);u.ssContent=e,u.ssFallback=t}zo>0&&!i&&Uo&&(o>0||6&a)&&32!==o&&Uo.push(u);return u};function Xo(e,t,n=!1){const{props:o,ref:r,patchFlag:s,children:i}=e,l=t?or(o||{},t):o;return{__v_isVNode:!0,__v_skip:!0,type:e.type,props:l,key:l&&Jo(l),ref:t&&t.ref?n&&r?T(r)?r.concat(Zo(t)):[r,Zo(t)]:Zo(t):r,scopeId:e.scopeId,slotScopeIds:e.slotScopeIds,children:i,target:e.target,targetAnchor:e.targetAnchor,staticCount:e.staticCount,shapeFlag:e.shapeFlag,patchFlag:t&&e.type!==Ro?-1===s?16:16|s:s,dynamicProps:e.dynamicProps,dynamicChildren:e.dynamicChildren,appContext:e.appContext,dirs:e.dirs,transition:e.transition,component:e.component,suspense:e.suspense,ssContent:e.ssContent&&Xo(e.ssContent),ssFallback:e.ssFallback&&Xo(e.ssFallback),el:e.el,anchor:e.anchor}}function Yo(e=" ",t=0){return Qo(Po,null,e,t)}function er(e){return null==e||"boolean"==typeof e?Qo(Vo):T(e)?Qo(Ro,null,e):"object"==typeof e?null===e.el?e:Xo(e):Qo(Po,null,String(e))}function tr(e){return null===e.el?e:Xo(e)}function nr(e,t){let n=0;const{shapeFlag:o}=e;if(null==t)t=null;else if(T(t))n=16;else if("object"==typeof t){if(1&o||64&o){const n=t.default;return void(n&&(n._c&&Qt(1),nr(e,n()),n._c&&Qt(-1)))}{n=32;const o=t._;o||qo in t?3===o&&Yt&&(1024&Yt.vnode.patchFlag?(t._=2,e.patchFlag|=1024):t._=1):t._ctx=Yt}}else F(t)?(t={default:t,_ctx:Yt},n=32):(t=String(t),64&o?(n=16,t=[Yo(t)]):n=8);e.children=t,e.shapeFlag|=n}function or(...e){const t=S({},e[0]);for(let n=1;n1)return n&&F(t)?t():t}}let ir=!0;function lr(e,t,n=[],o=[],r=[],s=!1){const{mixins:i,extends:l,data:c,computed:a,methods:u,watch:p,provide:f,inject:d,components:h,directives:g,beforeMount:y,mounted:b,beforeUpdate:_,updated:x,activated:C,deactivated:k,beforeUnmount:w,unmounted:N,render:E,renderTracked:$,renderTriggered:A,errorCaptured:M,expose:O}=t,B=e.proxy,R=e.ctx,P=e.appContext.mixins;if(s&&E&&e.render===v&&(e.render=E),s||(ir=!1,cr("beforeCreate","bc",t,e,P),ir=!0,ur(e,P,n,o,r)),l&&lr(e,l,n,o,r,!0),i&&ur(e,i,n,o,r),d)if(T(d))for(let m=0;mpr(e,t,B))),c&&pr(e,c,B)),a)for(const m in a){const e=a[m],t=Or({get:F(e)?e.bind(B,B):F(e.get)?e.get.bind(B,B):v,set:!F(e)&&F(e.set)?e.set.bind(B):v});Object.defineProperty(R,m,{enumerable:!0,configurable:!0,get:()=>t.value,set:e=>t.value=e})}if(p&&o.push(p),!s&&o.length&&o.forEach((e=>{for(const t in e)fr(e[t],R,B,t)})),f&&r.push(f),!s&&r.length&&r.forEach((e=>{const t=F(e)?e.call(B):e;Reflect.ownKeys(t).forEach((e=>{rr(e,t[e])}))})),s&&(h&&S(e.components||(e.components=S({},e.type.components)),h),g&&S(e.directives||(e.directives=S({},e.type.directives)),g)),s||cr("created","c",t,e,P),y&&kn(y.bind(B)),b&&wn(b.bind(B)),_&&Tn(_.bind(B)),x&&Nn(x.bind(B)),C&&Qn(C.bind(B)),k&&Xn(k.bind(B)),M&&Mn(M.bind(B)),$&&An($.bind(B)),A&&Fn(A.bind(B)),w&&En(w.bind(B)),N&&$n(N.bind(B)),T(O)&&!s)if(O.length){const t=e.exposed||(e.exposed=ht({}));O.forEach((e=>{t[e]=vt(B,e)}))}else e.exposed||(e.exposed=m)}function cr(e,t,n,o,r){for(let s=0;s{let t=e;for(let e=0;en[o];if(A(e)){const n=t[e];F(n)&&Bn(r,n)}else if(F(e))Bn(r,e.bind(n));else if(I(e))if(T(e))e.forEach((e=>fr(e,t,n,o)));else{const o=F(e.handler)?e.handler.bind(n):t[e.handler];F(o)&&Bn(r,o,e)}}function dr(e,t,n){const o=n.appContext.config.optionMergeStrategies,{mixins:r,extends:s}=t;s&&dr(e,s,n),r&&r.forEach((t=>dr(e,t,n)));for(const i in t)e[i]=o&&w(o,i)?o[i](e[i],t[i],n.proxy,i):t[i]}const hr=e=>e?Cr(e)?e.exposed?e.exposed:e.proxy:hr(e.parent):null,mr=S(Object.create(null),{$:e=>e,$el:e=>e.vnode.el,$data:e=>e.data,$props:e=>e.props,$attrs:e=>e.attrs,$slots:e=>e.slots,$refs:e=>e.refs,$parent:e=>hr(e.parent),$root:e=>hr(e.root),$emit:e=>e.emit,$options:e=>function(e){const t=e.type,{__merged:n,mixins:o,extends:r}=t;if(n)return n;const s=e.appContext.mixins;if(!s.length&&!o&&!r)return t;const i={};return s.forEach((t=>dr(i,t,e))),dr(i,t,e),t.__merged=i}(e),$forceUpdate:e=>()=>Lt(e.update),$nextTick:e=>Vt.bind(e.proxy),$watch:e=>Pn.bind(e)}),gr={get({_:e},t){const{ctx:n,setupState:o,data:r,props:s,accessCache:i,type:l,appContext:c}=e;if("__v_skip"===t)return!0;let a;if("$"!==t[0]){const l=i[t];if(void 0!==l)switch(l){case 0:return o[t];case 1:return r[t];case 3:return n[t];case 2:return s[t]}else{if(o!==m&&w(o,t))return i[t]=0,o[t];if(r!==m&&w(r,t))return i[t]=1,r[t];if((a=e.propsOptions[0])&&w(a,t))return i[t]=2,s[t];if(n!==m&&w(n,t))return i[t]=3,n[t];ir&&(i[t]=4)}}const u=mr[t];let p,f;return u?("$attrs"===t&&ue(e,0,t),u(e)):(p=l.__cssModules)&&(p=p[t])?p:n!==m&&w(n,t)?(i[t]=3,n[t]):(f=c.config.globalProperties,w(f,t)?f[t]:void 0)},set({_:e},t,n){const{data:o,setupState:r,ctx:s}=e;if(r!==m&&w(r,t))r[t]=n;else if(o!==m&&w(o,t))o[t]=n;else if(w(e.props,t))return!1;return("$"!==t[0]||!(t.slice(1)in e))&&(s[t]=n,!0)},has({_:{data:e,setupState:t,accessCache:n,ctx:o,appContext:r,propsOptions:s}},i){let l;return void 0!==n[i]||e!==m&&w(e,i)||t!==m&&w(t,i)||(l=s[0])&&w(l,i)||w(o,i)||w(mr,i)||w(r.config.globalProperties,i)}},vr=S({},gr,{get(e,t){if(t!==Symbol.unscopables)return gr.get(e,t,e)},has:(e,t)=>"_"!==t[0]&&!n(t)}),yr=ao();let br=0;let _r=null;const xr=()=>_r||Yt,Sr=e=>{_r=e};function Cr(e){return 4&e.vnode.shapeFlag}let kr,wr=!1;function Tr(e,t,n){F(t)?e.render=t:I(t)&&(e.setupState=ht(t)),Er(e)}function Nr(e){kr=e}function Er(e,t){const n=e.type;e.render||(kr&&n.template&&!n.render&&(n.render=kr(n.template,{isCustomElement:e.appContext.config.isCustomElement,delimiters:n.delimiters})),e.render=n.render||v,e.render._rc&&(e.withProxy=new Proxy(e.ctx,vr))),_r=e,ce(),lr(e,n),ae(),_r=null}function $r(e){const t=t=>{e.exposed=ht(t)};return{attrs:e.attrs,slots:e.slots,emit:e.emit,expose:t}}function Fr(e,t=_r){t&&(t.effects||(t.effects=[])).push(e)}const Ar=/(?:^|[-_])(\w)/g;function Mr(e){return F(e)&&e.displayName||e.name}function Ir(e,t,n=!1){let o=Mr(t);if(!o&&t.__file){const e=t.__file.match(/([^/\\]+)\.\w+$/);e&&(o=e[1])}if(!o&&e&&e.parent){const n=e=>{for(const n in e)if(e[n]===t)return n};o=n(e.components||e.parent.type.components)||n(e.appContext.components)}return o?o.replace(Ar,(e=>e.toUpperCase())).replace(/[-_]/g,""):n?"App":"Anonymous"}function Or(e){const t=function(e){let t,n;return F(e)?(t=e,n=v):(t=e.get,n=e.set),new yt(t,n,F(e)||!e.set)}(e);return Fr(t.effect),t}function Br(e,t,n){const o=arguments.length;return 2===o?I(t)&&!T(t)?Ko(t)?Qo(e,null,[t]):Qo(e,t):Qo(e,null,t):(o>3?n=Array.prototype.slice.call(arguments,2):3===o&&Ko(n)&&(n=[n]),Qo(e,t,n))}const Rr=Symbol("");const Pr="3.0.11",Vr="http://www.w3.org/2000/svg",Lr="undefined"!=typeof document?document:null;let jr,Ur;const Hr={insert:(e,t,n)=>{t.insertBefore(e,n||null)},remove:e=>{const t=e.parentNode;t&&t.removeChild(e)},createElement:(e,t,n,o)=>{const r=t?Lr.createElementNS(Vr,e):Lr.createElement(e,n?{is:n}:void 0);return"select"===e&&o&&null!=o.multiple&&r.setAttribute("multiple",o.multiple),r},createText:e=>Lr.createTextNode(e),createComment:e=>Lr.createComment(e),setText:(e,t)=>{e.nodeValue=t},setElementText:(e,t)=>{e.textContent=t},parentNode:e=>e.parentNode,nextSibling:e=>e.nextSibling,querySelector:e=>Lr.querySelector(e),setScopeId(e,t){e.setAttribute(t,"")},cloneNode(e){const t=e.cloneNode(!0);return"_value"in e&&(t._value=e._value),t},insertStaticContent(e,t,n,o){const r=o?Ur||(Ur=Lr.createElementNS(Vr,"svg")):jr||(jr=Lr.createElement("div"));r.innerHTML=e;const s=r.firstChild;let i=s,l=i;for(;i;)l=i,Hr.insert(i,t,n),i=r.firstChild;return[s,l]}};const Dr=/\s*!important$/;function zr(e,t,n){if(T(n))n.forEach((n=>zr(e,t,n)));else if(t.startsWith("--"))e.setProperty(t,n);else{const o=function(e,t){const n=Kr[t];if(n)return n;let o=H(t);if("filter"!==o&&o in e)return Kr[t]=o;o=W(o);for(let r=0;rdocument.createEvent("Event").timeStamp&&(qr=()=>performance.now());const e=navigator.userAgent.match(/firefox\/(\d+)/i);Jr=!!(e&&Number(e[1])<=53)}let Zr=0;const Qr=Promise.resolve(),Xr=()=>{Zr=0};function Yr(e,t,n,o){e.addEventListener(t,n,o)}function es(e,t,n,o,r=null){const s=e._vei||(e._vei={}),i=s[t];if(o&&i)i.value=o;else{const[n,l]=function(e){let t;if(ts.test(e)){let n;for(t={};n=e.match(ts);)e=e.slice(0,e.length-n[0].length),t[n[0].toLowerCase()]=!0}return[z(e.slice(2)),t]}(t);if(o){Yr(e,n,s[t]=function(e,t){const n=e=>{const o=e.timeStamp||qr();(Jr||o>=n.attached-1)&&Ct(function(e,t){if(T(t)){const n=e.stopImmediatePropagation;return e.stopImmediatePropagation=()=>{n.call(e),e._stopped=!0},t.map((e=>t=>!t._stopped&&e(t)))}return t}(e,n.value),t,5,[e])};return n.value=e,n.attached=(()=>Zr||(Qr.then(Xr),Zr=qr()))(),n}(o,r),l)}else i&&(!function(e,t,n,o){e.removeEventListener(t,n,o)}(e,n,i,l),s[t]=void 0)}}const ts=/(?:Once|Passive|Capture)$/;const ns=/^on[a-z]/;function os(e,t){if(128&e.shapeFlag){const n=e.suspense;e=n.activeBranch,n.pendingBranch&&!n.isHydrating&&n.effects.push((()=>{os(n.activeBranch,t)}))}for(;e.component;)e=e.component.subTree;if(1&e.shapeFlag&&e.el){const n=e.el.style;for(const e in t)n.setProperty(`--${e}`,t[e])}else e.type===Ro&&e.children.forEach((e=>os(e,t)))}const rs="transition",ss="animation",is=(e,{slots:t})=>Br(Un,as(e),t);is.displayName="Transition";const ls={name:String,type:String,css:{type:Boolean,default:!0},duration:[String,Number,Object],enterFromClass:String,enterActiveClass:String,enterToClass:String,appearFromClass:String,appearActiveClass:String,appearToClass:String,leaveFromClass:String,leaveActiveClass:String,leaveToClass:String},cs=is.props=S({},Un.props,ls);function as(e){let{name:t="v",type:n,css:o=!0,duration:r,enterFromClass:s=`${t}-enter-from`,enterActiveClass:i=`${t}-enter-active`,enterToClass:l=`${t}-enter-to`,appearFromClass:c=s,appearActiveClass:a=i,appearToClass:u=l,leaveFromClass:p=`${t}-leave-from`,leaveActiveClass:f=`${t}-leave-active`,leaveToClass:d=`${t}-leave-to`}=e;const h={};for(const S in e)S in ls||(h[S]=e[S]);if(!o)return h;const m=function(e){if(null==e)return null;if(I(e))return[us(e.enter),us(e.leave)];{const t=us(e);return[t,t]}}(r),g=m&&m[0],v=m&&m[1],{onBeforeEnter:y,onEnter:b,onEnterCancelled:_,onLeave:x,onLeaveCancelled:C,onBeforeAppear:k=y,onAppear:w=b,onAppearCancelled:T=_}=h,N=(e,t,n)=>{fs(e,t?u:l),fs(e,t?a:i),n&&n()},E=(e,t)=>{fs(e,d),fs(e,f),t&&t()},$=e=>(t,o)=>{const r=e?w:b,i=()=>N(t,e,o);r&&r(t,i),ds((()=>{fs(t,e?c:s),ps(t,e?u:l),r&&r.length>1||ms(t,n,g,i)}))};return S(h,{onBeforeEnter(e){y&&y(e),ps(e,s),ps(e,i)},onBeforeAppear(e){k&&k(e),ps(e,c),ps(e,a)},onEnter:$(!1),onAppear:$(!0),onLeave(e,t){const o=()=>E(e,t);ps(e,p),bs(),ps(e,f),ds((()=>{fs(e,p),ps(e,d),x&&x.length>1||ms(e,n,v,o)})),x&&x(e,o)},onEnterCancelled(e){N(e,!1),_&&_(e)},onAppearCancelled(e){N(e,!0),T&&T(e)},onLeaveCancelled(e){E(e),C&&C(e)}})}function us(e){return Z(e)}function ps(e,t){t.split(/\s+/).forEach((t=>t&&e.classList.add(t))),(e._vtc||(e._vtc=new Set)).add(t)}function fs(e,t){t.split(/\s+/).forEach((t=>t&&e.classList.remove(t)));const{_vtc:n}=e;n&&(n.delete(t),n.size||(e._vtc=void 0))}function ds(e){requestAnimationFrame((()=>{requestAnimationFrame(e)}))}let hs=0;function ms(e,t,n,o){const r=e._endId=++hs,s=()=>{r===e._endId&&o()};if(n)return setTimeout(s,n);const{type:i,timeout:l,propCount:c}=gs(e,t);if(!i)return o();const a=i+"end";let u=0;const p=()=>{e.removeEventListener(a,f),s()},f=t=>{t.target===e&&++u>=c&&p()};setTimeout((()=>{u(n[e]||"").split(", "),r=o("transitionDelay"),s=o("transitionDuration"),i=vs(r,s),l=o("animationDelay"),c=o("animationDuration"),a=vs(l,c);let u=null,p=0,f=0;t===rs?i>0&&(u=rs,p=i,f=s.length):t===ss?a>0&&(u=ss,p=a,f=c.length):(p=Math.max(i,a),u=p>0?i>a?rs:ss:null,f=u?u===rs?s.length:c.length:0);return{type:u,timeout:p,propCount:f,hasTransform:u===rs&&/\b(transform|all)(,|$)/.test(n.transitionProperty)}}function vs(e,t){for(;e.lengthys(t)+ys(e[n]))))}function ys(e){return 1e3*Number(e.slice(0,-1).replace(",","."))}function bs(){return document.body.offsetHeight}const _s=new WeakMap,xs=new WeakMap,Ss={name:"TransitionGroup",props:S({},cs,{tag:String,moveClass:String}),setup(e,{slots:t}){const n=xr(),o=Ln();let r,s;return Nn((()=>{if(!r.length)return;const t=e.moveClass||`${e.name||"v"}-move`;if(!function(e,t,n){const o=e.cloneNode();e._vtc&&e._vtc.forEach((e=>{e.split(/\s+/).forEach((e=>e&&o.classList.remove(e)))}));n.split(/\s+/).forEach((e=>e&&o.classList.add(e))),o.style.display="none";const r=1===t.nodeType?t:t.parentNode;r.appendChild(o);const{hasTransform:s}=gs(o);return r.removeChild(o),s}(r[0].el,n.vnode.el,t))return;r.forEach(Cs),r.forEach(ks);const o=r.filter(ws);bs(),o.forEach((e=>{const n=e.el,o=n.style;ps(n,t),o.transform=o.webkitTransform=o.transitionDuration="";const r=n._moveCb=e=>{e&&e.target!==n||e&&!/transform$/.test(e.propertyName)||(n.removeEventListener("transitionend",r),n._moveCb=null,fs(n,t))};n.addEventListener("transitionend",r)}))})),()=>{const i=it(e),l=as(i),c=i.tag||Ro;r=s,s=t.default?Gn(t.default()):[];for(let e=0;e{const t=e.props["onUpdate:modelValue"];return T(t)?e=>q(t,e):t};function Ns(e){e.target.composing=!0}function Es(e){const t=e.target;t.composing&&(t.composing=!1,function(e,t){const n=document.createEvent("HTMLEvents");n.initEvent(t,!0,!0),e.dispatchEvent(n)}(t,"input"))}const $s={created(e,{modifiers:{lazy:t,trim:n,number:o}},r){e._assign=Ts(r);const s=o||"number"===e.type;Yr(e,t?"change":"input",(t=>{if(t.target.composing)return;let o=e.value;n?o=o.trim():s&&(o=Z(o)),e._assign(o)})),n&&Yr(e,"change",(()=>{e.value=e.value.trim()})),t||(Yr(e,"compositionstart",Ns),Yr(e,"compositionend",Es),Yr(e,"change",Es))},mounted(e,{value:t}){e.value=null==t?"":t},beforeUpdate(e,{value:t,modifiers:{trim:n,number:o}},r){if(e._assign=Ts(r),e.composing)return;if(document.activeElement===e){if(n&&e.value.trim()===t)return;if((o||"number"===e.type)&&Z(e.value)===t)return}const s=null==t?"":t;e.value!==s&&(e.value=s)}},Fs={created(e,t,n){e._assign=Ts(n),Yr(e,"change",(()=>{const t=e._modelValue,n=Bs(e),o=e.checked,r=e._assign;if(T(t)){const e=d(t,n),s=-1!==e;if(o&&!s)r(t.concat(n));else if(!o&&s){const n=[...t];n.splice(e,1),r(n)}}else if(E(t)){const e=new Set(t);o?e.add(n):e.delete(n),r(e)}else r(Rs(e,o))}))},mounted:As,beforeUpdate(e,t,n){e._assign=Ts(n),As(e,t,n)}};function As(e,{value:t,oldValue:n},o){e._modelValue=t,T(t)?e.checked=d(t,o.props.value)>-1:E(t)?e.checked=t.has(o.props.value):t!==n&&(e.checked=f(t,Rs(e,!0)))}const Ms={created(e,{value:t},n){e.checked=f(t,n.props.value),e._assign=Ts(n),Yr(e,"change",(()=>{e._assign(Bs(e))}))},beforeUpdate(e,{value:t,oldValue:n},o){e._assign=Ts(o),t!==n&&(e.checked=f(t,o.props.value))}},Is={created(e,{value:t,modifiers:{number:n}},o){const r=E(t);Yr(e,"change",(()=>{const t=Array.prototype.filter.call(e.options,(e=>e.selected)).map((e=>n?Z(Bs(e)):Bs(e)));e._assign(e.multiple?r?new Set(t):t:t[0])})),e._assign=Ts(o)},mounted(e,{value:t}){Os(e,t)},beforeUpdate(e,t,n){e._assign=Ts(n)},updated(e,{value:t}){Os(e,t)}};function Os(e,t){const n=e.multiple;if(!n||T(t)||E(t)){for(let o=0,r=e.options.length;o-1:t.has(s);else if(f(Bs(r),t))return void(e.selectedIndex=o)}n||(e.selectedIndex=-1)}}function Bs(e){return"_value"in e?e._value:e.value}function Rs(e,t){const n=t?"_trueValue":"_falseValue";return n in e?e[n]:t}const Ps={created(e,t,n){Vs(e,t,n,null,"created")},mounted(e,t,n){Vs(e,t,n,null,"mounted")},beforeUpdate(e,t,n,o){Vs(e,t,n,o,"beforeUpdate")},updated(e,t,n,o){Vs(e,t,n,o,"updated")}};function Vs(e,t,n,o,r){let s;switch(e.tagName){case"SELECT":s=Is;break;case"TEXTAREA":s=$s;break;default:switch(n.props&&n.props.type){case"checkbox":s=Fs;break;case"radio":s=Ms;break;default:s=$s}}const i=s[r];i&&i(e,t,n,o)}const Ls=["ctrl","shift","alt","meta"],js={stop:e=>e.stopPropagation(),prevent:e=>e.preventDefault(),self:e=>e.target!==e.currentTarget,ctrl:e=>!e.ctrlKey,shift:e=>!e.shiftKey,alt:e=>!e.altKey,meta:e=>!e.metaKey,left:e=>"button"in e&&0!==e.button,middle:e=>"button"in e&&1!==e.button,right:e=>"button"in e&&2!==e.button,exact:(e,t)=>Ls.some((n=>e[`${n}Key`]&&!t.includes(n)))},Us={esc:"escape",space:" ",up:"arrow-up",left:"arrow-left",right:"arrow-right",down:"arrow-down",delete:"backspace"},Hs={beforeMount(e,{value:t},{transition:n}){e._vod="none"===e.style.display?"":e.style.display,n&&t?n.beforeEnter(e):Ds(e,t)},mounted(e,{value:t},{transition:n}){n&&t&&n.enter(e)},updated(e,{value:t,oldValue:n},{transition:o}){!t!=!n&&(o?t?(o.beforeEnter(e),Ds(e,!0),o.enter(e)):o.leave(e,(()=>{Ds(e,!1)})):Ds(e,t))},beforeUnmount(e,{value:t}){Ds(e,t)}};function Ds(e,t){e.style.display=t?e._vod:"none"}const zs=S({patchProp:(e,t,n,r,s=!1,i,l,c,a)=>{switch(t){case"class":!function(e,t,n){if(null==t&&(t=""),n)e.setAttribute("class",t);else{const n=e._vtc;n&&(t=(t?[t,...n]:[...n]).join(" ")),e.className=t}}(e,r,s);break;case"style":!function(e,t,n){const o=e.style;if(n)if(A(n)){if(t!==n){const t=o.display;o.cssText=n,"_vod"in e&&(o.display=t)}}else{for(const e in n)zr(o,e,n[e]);if(t&&!A(t))for(const e in t)null==n[e]&&zr(o,e,"")}else e.removeAttribute("style")}(e,n,r);break;default:_(t)?x(t)||es(e,t,0,r,l):function(e,t,n,o){if(o)return"innerHTML"===t||!!(t in e&&ns.test(t)&&F(n));if("spellcheck"===t||"draggable"===t)return!1;if("form"===t)return!1;if("list"===t&&"INPUT"===e.tagName)return!1;if("type"===t&&"TEXTAREA"===e.tagName)return!1;if(ns.test(t)&&A(n))return!1;return t in e}(e,t,r,s)?function(e,t,n,o,r,s,i){if("innerHTML"===t||"textContent"===t)return o&&i(o,r,s),void(e[t]=null==n?"":n);if("value"!==t||"PROGRESS"===e.tagName){if(""===n||null==n){const o=typeof e[t];if(""===n&&"boolean"===o)return void(e[t]=!0);if(null==n&&"string"===o)return e[t]="",void e.removeAttribute(t);if("number"===o)return e[t]=0,void e.removeAttribute(t)}try{e[t]=n}catch(l){}}else{e._value=n;const t=null==n?"":n;e.value!==t&&(e.value=t)}}(e,t,r,i,l,c,a):("true-value"===t?e._trueValue=r:"false-value"===t&&(e._falseValue=r),function(e,t,n,r){if(r&&t.startsWith("xlink:"))null==n?e.removeAttributeNS(Gr,t.slice(6,t.length)):e.setAttributeNS(Gr,t,n);else{const r=o(t);null==n||r&&!1===n?e.removeAttribute(t):e.setAttribute(t,r?"":n)}}(e,t,r,s))}},forcePatchProp:(e,t)=>"value"===t},Hr);let Ws,Ks=!1;function Gs(){return Ws||(Ws=So(zs))}function qs(){return Ws=Ks?Ws:Co(zs),Ks=!0,Ws}function Js(e){if(A(e)){return document.querySelector(e)}return e}function Zs(e){throw e}function Qs(e,t,n,o){const r=new SyntaxError(String(e));return r.code=e,r.loc=t,r}const Xs=Symbol(""),Ys=Symbol(""),ei=Symbol(""),ti=Symbol(""),ni=Symbol(""),oi=Symbol(""),ri=Symbol(""),si=Symbol(""),ii=Symbol(""),li=Symbol(""),ci=Symbol(""),ai=Symbol(""),ui=Symbol(""),pi=Symbol(""),fi=Symbol(""),di=Symbol(""),hi=Symbol(""),mi=Symbol(""),gi=Symbol(""),vi=Symbol(""),yi=Symbol(""),bi=Symbol(""),_i=Symbol(""),xi=Symbol(""),Si=Symbol(""),Ci=Symbol(""),ki=Symbol(""),wi=Symbol(""),Ti=Symbol(""),Ni=Symbol(""),Ei=Symbol(""),$i={[Xs]:"Fragment",[Ys]:"Teleport",[ei]:"Suspense",[ti]:"KeepAlive",[ni]:"BaseTransition",[oi]:"openBlock",[ri]:"createBlock",[si]:"createVNode",[ii]:"createCommentVNode",[li]:"createTextVNode",[ci]:"createStaticVNode",[ai]:"resolveComponent",[ui]:"resolveDynamicComponent",[pi]:"resolveDirective",[fi]:"withDirectives",[di]:"renderList",[hi]:"renderSlot",[mi]:"createSlots",[gi]:"toDisplayString",[vi]:"mergeProps",[yi]:"toHandlers",[bi]:"camelize",[_i]:"capitalize",[xi]:"toHandlerKey",[Si]:"setBlockTracking",[Ci]:"pushScopeId",[ki]:"popScopeId",[wi]:"withScopeId",[Ti]:"withCtx",[Ni]:"unref",[Ei]:"isRef"};const Fi={source:"",start:{line:1,column:1,offset:0},end:{line:1,column:1,offset:0}};function Ai(e,t,n,o,r,s,i,l=!1,c=!1,a=Fi){return e&&(l?(e.helper(oi),e.helper(ri)):e.helper(si),i&&e.helper(fi)),{type:13,tag:t,props:n,children:o,patchFlag:r,dynamicProps:s,directives:i,isBlock:l,disableTracking:c,loc:a}}function Mi(e,t=Fi){return{type:17,loc:t,elements:e}}function Ii(e,t=Fi){return{type:15,loc:t,properties:e}}function Oi(e,t){return{type:16,loc:Fi,key:A(e)?Bi(e,!0):e,value:t}}function Bi(e,t,n=Fi,o=0){return{type:4,loc:n,content:e,isStatic:t,constType:t?3:o}}function Ri(e,t=Fi){return{type:8,loc:t,children:e}}function Pi(e,t=[],n=Fi){return{type:14,loc:n,callee:e,arguments:t}}function Vi(e,t,n=!1,o=!1,r=Fi){return{type:18,params:e,returns:t,newline:n,isSlot:o,loc:r}}function Li(e,t,n,o=!0){return{type:19,test:e,consequent:t,alternate:n,newline:o,loc:Fi}}const ji=e=>4===e.type&&e.isStatic,Ui=(e,t)=>e===t||e===z(t);function Hi(e){return Ui(e,"Teleport")?Ys:Ui(e,"Suspense")?ei:Ui(e,"KeepAlive")?ti:Ui(e,"BaseTransition")?ni:void 0}const Di=/^\d|[^\$\w]/,zi=e=>!Di.test(e),Wi=/^[A-Za-z_$\xA0-\uFFFF][\w$\xA0-\uFFFF]*(?:\s*\.\s*[A-Za-z_$\xA0-\uFFFF][\w$\xA0-\uFFFF]*|\[[^\]]+\])*$/,Ki=e=>!!e&&Wi.test(e.trim());function Gi(e,t,n){const o={source:e.source.substr(t,n),start:qi(e.start,e.source,t),end:e.end};return null!=n&&(o.end=qi(e.start,e.source,t+n)),o}function qi(e,t,n=t.length){return Ji(S({},e),t,n)}function Ji(e,t,n=t.length){let o=0,r=-1;for(let s=0;s4===e.key.type&&e.key.content===n))}e||r.properties.unshift(t),o=r}else o=Pi(n.helper(vi),[Ii([t]),r]);13===e.type?e.props=o:e.arguments[2]=o}function rl(e,t){return`_${t}_${e.replace(/[^\w]/g,"_")}`}const sl=/&(gt|lt|amp|apos|quot);/g,il={gt:">",lt:"<",amp:"&",apos:"'",quot:'"'},ll={delimiters:["{{","}}"],getNamespace:()=>0,getTextMode:()=>0,isVoidTag:y,isPreTag:y,isCustomElement:y,decodeEntities:e=>e.replace(sl,((e,t)=>il[t])),onError:Zs,comments:!1};function cl(e,t={}){const n=function(e,t){const n=S({},ll);for(const o in t)n[o]=t[o]||ll[o];return{options:n,column:1,line:1,offset:0,originalSource:e,source:e,inPre:!1,inVPre:!1}}(e,t),o=Sl(n);return function(e,t=Fi){return{type:0,children:e,helpers:[],components:[],directives:[],hoists:[],imports:[],cached:0,temps:0,codegenNode:void 0,loc:t}}(al(n,0,[]),Cl(n,o))}function al(e,t,n){const o=kl(n),r=o?o.ns:0,s=[];for(;!$l(e,t,n);){const i=e.source;let l;if(0===t||1===t)if(!e.inVPre&&wl(i,e.options.delimiters[0]))l=bl(e,t);else if(0===t&&"<"===i[0])if(1===i.length);else if("!"===i[1])l=wl(i,"\x3c!--")?fl(e):wl(i,""===i[2]){Tl(e,3);continue}if(/[a-z]/i.test(i[2])){gl(e,1,o);continue}l=dl(e)}else/[a-z]/i.test(i[1])?l=hl(e,n):"?"===i[1]&&(l=dl(e));if(l||(l=_l(e,t)),T(l))for(let e=0;e/.exec(e.source);if(o){n=e.source.slice(4,o.index);const t=e.source.slice(0,o.index);let r=1,s=0;for(;-1!==(s=t.indexOf("\x3c!--",r));)Tl(e,s-r+1),r=s+1;Tl(e,o.index+o[0].length-r+1)}else n=e.source.slice(4),Tl(e,e.source.length);return{type:3,content:n,loc:Cl(e,t)}}function dl(e){const t=Sl(e),n="?"===e.source[1]?1:2;let o;const r=e.source.indexOf(">");return-1===r?(o=e.source.slice(n),Tl(e,e.source.length)):(o=e.source.slice(n,r),Tl(e,r+1)),{type:3,content:o,loc:Cl(e,t)}}function hl(e,t){const n=e.inPre,o=e.inVPre,r=kl(t),s=gl(e,0,r),i=e.inPre&&!n,l=e.inVPre&&!o;if(s.isSelfClosing||e.options.isVoidTag(s.tag))return s;t.push(s);const c=e.options.getTextMode(s,r),a=al(e,c,t);if(t.pop(),s.children=a,Fl(e.source,s.tag))gl(e,1,r);else if(0===e.source.length&&"script"===s.tag.toLowerCase()){const e=a[0];e&&wl(e.loc.source,"\x3c!--")}return s.loc=Cl(e,s.loc.start),i&&(e.inPre=!1),l&&(e.inVPre=!1),s}const ml=t("if,else,else-if,for,slot");function gl(e,t,n){const o=Sl(e),r=/^<\/?([a-z][^\t\r\n\f />]*)/i.exec(e.source),s=r[1],i=e.options.getNamespace(s,n);Tl(e,r[0].length),Nl(e);const l=Sl(e),c=e.source;let a=vl(e,t);e.options.isPreTag(s)&&(e.inPre=!0),!e.inVPre&&a.some((e=>7===e.type&&"pre"===e.name))&&(e.inVPre=!0,S(e,l),e.source=c,a=vl(e,t).filter((e=>"v-pre"!==e.name)));let u=!1;0===e.source.length||(u=wl(e.source,"/>"),Tl(e,u?2:1));let p=0;const f=e.options;if(!e.inVPre&&!f.isCustomElement(s)){const e=a.some((e=>7===e.type&&"is"===e.name));f.isNativeTag&&!e?f.isNativeTag(s)||(p=1):(e||Hi(s)||f.isBuiltInComponent&&f.isBuiltInComponent(s)||/^[A-Z]/.test(s)||"component"===s)&&(p=1),"slot"===s?p=2:"template"===s&&a.some((e=>7===e.type&&ml(e.name)))&&(p=3)}return{type:1,ns:i,tag:s,tagType:p,props:a,isSelfClosing:u,children:[],loc:Cl(e,o),codegenNode:void 0}}function vl(e,t){const n=[],o=new Set;for(;e.source.length>0&&!wl(e.source,">")&&!wl(e.source,"/>");){if(wl(e.source,"/")){Tl(e,1),Nl(e);continue}const r=yl(e,o);0===t&&n.push(r),/^[^\t\r\n\f />]/.test(e.source),Nl(e)}return n}function yl(e,t){const n=Sl(e),o=/^[^\t\r\n\f />][^\t\r\n\f />=]*/.exec(e.source)[0];t.has(o),t.add(o);{const e=/["'<]/g;let t;for(;t=e.exec(o););}let r;Tl(e,o.length),/^[\t\r\n\f ]*=/.test(e.source)&&(Nl(e),Tl(e,1),Nl(e),r=function(e){const t=Sl(e);let n;const o=e.source[0],r='"'===o||"'"===o;if(r){Tl(e,1);const t=e.source.indexOf(o);-1===t?n=xl(e,e.source.length,4):(n=xl(e,t,4),Tl(e,1))}else{const t=/^[^\t\r\n\f >]+/.exec(e.source);if(!t)return;const o=/["'<=`]/g;let r;for(;r=o.exec(t[0]););n=xl(e,t[0].length,4)}return{content:n,isQuoted:r,loc:Cl(e,t)}}(e));const s=Cl(e,n);if(!e.inVPre&&/^(v-|:|@|#)/.test(o)){const t=/(?:^v-([a-z0-9-]+))?(?:(?::|^@|^#)(\[[^\]]+\]|[^\.]+))?(.+)?$/i.exec(o),i=t[1]||(wl(o,":")?"bind":wl(o,"@")?"on":"slot");let l;if(t[2]){const r="slot"===i,s=o.lastIndexOf(t[2]),c=Cl(e,El(e,n,s),El(e,n,s+t[2].length+(r&&t[3]||"").length));let a=t[2],u=!0;a.startsWith("[")?(u=!1,a.endsWith("]"),a=a.substr(1,a.length-2)):r&&(a+=t[3]||""),l={type:4,content:a,isStatic:u,constType:u?3:0,loc:c}}if(r&&r.isQuoted){const e=r.loc;e.start.offset++,e.start.column++,e.end=qi(e.start,r.content),e.source=e.source.slice(1,-1)}return{type:7,name:i,exp:r&&{type:4,content:r.content,isStatic:!1,constType:0,loc:r.loc},arg:l,modifiers:t[3]?t[3].substr(1).split("."):[],loc:s}}return{type:6,name:o,value:r&&{type:2,content:r.content,loc:r.loc},loc:s}}function bl(e,t){const[n,o]=e.options.delimiters,r=e.source.indexOf(o,n.length);if(-1===r)return;const s=Sl(e);Tl(e,n.length);const i=Sl(e),l=Sl(e),c=r-n.length,a=e.source.slice(0,c),u=xl(e,c,t),p=u.trim(),f=u.indexOf(p);f>0&&Ji(i,a,f);return Ji(l,a,c-(u.length-p.length-f)),Tl(e,o.length),{type:5,content:{type:4,isStatic:!1,constType:0,content:p,loc:Cl(e,i,l)},loc:Cl(e,s)}}function _l(e,t){const n=["<",e.options.delimiters[0]];3===t&&n.push("]]>");let o=e.source.length;for(let s=0;st&&(o=t)}const r=Sl(e);return{type:2,content:xl(e,o,t),loc:Cl(e,r)}}function xl(e,t,n){const o=e.source.slice(0,t);return Tl(e,t),2===n||3===n||-1===o.indexOf("&")?o:e.options.decodeEntities(o,4===n)}function Sl(e){const{column:t,line:n,offset:o}=e;return{column:t,line:n,offset:o}}function Cl(e,t,n){return{start:t,end:n=n||Sl(e),source:e.originalSource.slice(t.offset,n.offset)}}function kl(e){return e[e.length-1]}function wl(e,t){return e.startsWith(t)}function Tl(e,t){const{source:n}=e;Ji(e,n,t),e.source=n.slice(t)}function Nl(e){const t=/^[\t\r\n\f ]+/.exec(e.source);t&&Tl(e,t[0].length)}function El(e,t,n){return qi(t,e.originalSource.slice(t.offset,n),n)}function $l(e,t,n){const o=e.source;switch(t){case 0:if(wl(o,"=0;--e)if(Fl(o,n[e].tag))return!0;break;case 1:case 2:{const e=kl(n);if(e&&Fl(o,e.tag))return!0;break}case 3:if(wl(o,"]]>"))return!0}return!o}function Fl(e,t){return wl(e,"]/.test(e[2+t.length]||">")}function Al(e,t){Il(e,t,Ml(e,e.children[0]))}function Ml(e,t){const{children:n}=e;return 1===n.length&&1===t.type&&!nl(t)}function Il(e,t,n=!1){let o=!1,r=!0;const{children:s}=e;for(let i=0;i0){if(s<3&&(r=!1),s>=2){e.codegenNode.patchFlag="-1",e.codegenNode=t.hoist(e.codegenNode),o=!0;continue}}else{const n=e.codegenNode;if(13===n.type){const o=Pl(n);if((!o||512===o||1===o)&&Bl(e,t)>=2){const o=Rl(e);o&&(n.props=t.hoist(o))}}}}else if(12===e.type){const n=Ol(e.content,t);n>0&&(n<3&&(r=!1),n>=2&&(e.codegenNode=t.hoist(e.codegenNode),o=!0))}if(1===e.type){const n=1===e.tagType;n&&t.scopes.vSlot++,Il(e,t),n&&t.scopes.vSlot--}else if(11===e.type)Il(e,t,1===e.children.length);else if(9===e.type)for(let n=0;n1)for(let r=0;r`_${$i[S.helper(e)]}`,replaceNode(e){S.parent.children[S.childIndex]=S.currentNode=e},removeNode(e){const t=e?S.parent.children.indexOf(e):S.currentNode?S.childIndex:-1;e&&e!==S.currentNode?S.childIndex>t&&(S.childIndex--,S.onNodeRemoved()):(S.currentNode=null,S.onNodeRemoved()),S.parent.children.splice(t,1)},onNodeRemoved:()=>{},addIdentifiers(e){},removeIdentifiers(e){},hoist(e){S.hoists.push(e);const t=Bi(`_hoisted_${S.hoists.length}`,!1,e.loc,2);return t.hoisted=e,t},cache:(e,t=!1)=>function(e,t,n=!1){return{type:20,index:e,value:t,isVNode:n,loc:Fi}}(++S.cached,e,t)};return S}function Ll(e,t){const n=Vl(e,t);jl(e,n),t.hoistStatic&&Al(e,n),t.ssr||function(e,t){const{helper:n,removeHelper:o}=t,{children:r}=e;if(1===r.length){const t=r[0];if(Ml(e,t)&&t.codegenNode){const r=t.codegenNode;13===r.type&&(r.isBlock||(o(si),r.isBlock=!0,n(oi),n(ri))),e.codegenNode=r}else e.codegenNode=t}else if(r.length>1){let o=64;e.codegenNode=Ai(t,n(Xs),void 0,e.children,o+"",void 0,void 0,!0)}}(e,n),e.helpers=[...n.helpers.keys()],e.components=[...n.components],e.directives=[...n.directives],e.imports=n.imports,e.hoists=n.hoists,e.temps=n.temps,e.cached=n.cached}function jl(e,t){t.currentNode=e;const{nodeTransforms:n}=t,o=[];for(let s=0;s{n--};for(;nt===e:t=>e.test(t);return(e,o)=>{if(1===e.type){const{props:r}=e;if(3===e.tagType&&r.some(el))return;const s=[];for(let i=0;i`_${$i[e]}`,push(e,t){u.code+=e},indent(){p(++u.indentLevel)},deindent(e=!1){e?--u.indentLevel:p(--u.indentLevel)},newline(){p(u.indentLevel)}};function p(e){u.push("\n"+"  ".repeat(e))}return u}(e,t);t.onContextCreated&&t.onContextCreated(n);const{mode:o,push:r,prefixIdentifiers:s,indent:i,deindent:l,newline:c,ssr:a}=n,u=e.helpers.length>0,p=!s&&"module"!==o;!function(e,t){const{push:n,newline:o,runtimeGlobalName:r}=t,s=r,i=e=>`${$i[e]}: _${$i[e]}`;if(e.helpers.length>0&&(n(`const _Vue = ${s}\n`),e.hoists.length)){n(`const { ${[si,ii,li,ci].filter((t=>e.helpers.includes(t))).map(i).join(", ")} } = _Vue\n`)}(function(e,t){if(!e.length)return;t.pure=!0;const{push:n,newline:o}=t;o(),e.forEach(((e,r)=>{e&&(n(`const _hoisted_${r+1} = `),Gl(e,t),o())})),t.pure=!1})(e.hoists,t),o(),n("return ")}(e,n);if(r(`function ${a?"ssrRender":"render"}(${(a?["_ctx","_push","_parent","_attrs"]:["_ctx","_cache"]).join(", ")}) {`),i(),p&&(r("with (_ctx) {"),i(),u&&(r(`const { ${e.helpers.map((e=>`${$i[e]}: _${$i[e]}`)).join(", ")} } = _Vue`),r("\n"),c())),e.components.length&&(zl(e.components,"component",n),(e.directives.length||e.temps>0)&&c()),e.directives.length&&(zl(e.directives,"directive",n),e.temps>0&&c()),e.temps>0){r("let ");for(let t=0;t0?", ":""}_temp${t}`)}return(e.components.length||e.directives.length||e.temps)&&(r("\n"),c()),a||r("return "),e.codegenNode?Gl(e.codegenNode,n):r("null"),p&&(l(),r("}")),l(),r("}"),{ast:e,code:n.code,preamble:"",map:n.map?n.map.toJSON():void 0}}function zl(e,t,{helper:n,push:o,newline:r}){const s=n("component"===t?ai:pi);for(let i=0;i3||!1;t.push("["),n&&t.indent(),Kl(e,t,n),n&&t.deindent(),t.push("]")}function Kl(e,t,n=!1,o=!0){const{push:r,newline:s}=t;for(let i=0;ie||"null"))}([s,i,l,c,a]),t),n(")"),p&&n(")");u&&(n(", "),Gl(u,t),n(")"))}(e,t);break;case 14:!function(e,t){const{push:n,helper:o,pure:r}=t,s=A(e.callee)?e.callee:o(e.callee);r&&n(Hl);n(s+"(",e),Kl(e.arguments,t),n(")")}(e,t);break;case 15:!function(e,t){const{push:n,indent:o,deindent:r,newline:s}=t,{properties:i}=e;if(!i.length)return void n("{}",e);const l=i.length>1||!1;n(l?"{":"{ "),l&&o();for(let c=0;c "),(c||l)&&(n("{"),o());i?(c&&n("return "),T(i)?Wl(i,t):Gl(i,t)):l&&Gl(l,t);(c||l)&&(r(),n("}"));a&&n(")")}(e,t);break;case 19:!function(e,t){const{test:n,consequent:o,alternate:r,newline:s}=e,{push:i,indent:l,deindent:c,newline:a}=t;if(4===n.type){const e=!zi(n.content);e&&i("("),ql(n,t),e&&i(")")}else i("("),Gl(n,t),i(")");s&&l(),t.indentLevel++,s||i(" "),i("? "),Gl(o,t),t.indentLevel--,s&&a(),s||i(" "),i(": ");const u=19===r.type;u||t.indentLevel++;Gl(r,t),u||t.indentLevel--;s&&c(!0)}(e,t);break;case 20:!function(e,t){const{push:n,helper:o,indent:r,deindent:s,newline:i}=t;n(`_cache[${e.index}] || (`),e.isVNode&&(r(),n(`${o(Si)}(-1),`),i());n(`_cache[${e.index}] = `),Gl(e.value,t),e.isVNode&&(n(","),i(),n(`${o(Si)}(1),`),i(),n(`_cache[${e.index}]`),s());n(")")}(e,t)}}function ql(e,t){const{content:n,isStatic:o}=e;t.push(o?JSON.stringify(n):n,e)}function Jl(e,t){for(let n=0;nfunction(e,t,n,o){if(!("else"===t.name||t.exp&&t.exp.content.trim())){t.exp=Bi("true",!1,t.exp?t.exp.loc:e.loc)}if("if"===t.name){const r=Xl(e,t),s={type:9,loc:e.loc,branches:[r]};if(n.replaceNode(s),o)return o(s,r,!0)}else{const r=n.parent.children;let s=r.indexOf(e);for(;s-- >=-1;){const i=r[s];if(!i||2!==i.type||i.content.trim().length){if(i&&9===i.type){n.removeNode();const r=Xl(e,t);i.branches.push(r);const s=o&&o(i,r,!1);jl(r,n),s&&s(),n.currentNode=null}break}n.removeNode(i)}}}(e,t,n,((e,t,o)=>{const r=n.parent.children;let s=r.indexOf(e),i=0;for(;s-- >=0;){const e=r[s];e&&9===e.type&&(i+=e.branches.length)}return()=>{if(o)e.codegenNode=Yl(t,i,n);else{(function(e){for(;;)if(19===e.type){if(19!==e.alternate.type)return e;e=e.alternate}else 20===e.type&&(e=e.value)}(e.codegenNode)).alternate=Yl(t,i+e.branches.length-1,n)}}}))));function Xl(e,t){return{type:10,loc:e.loc,condition:"else"===t.name?void 0:t.exp,children:3!==e.tagType||Zi(e,"for")?[e]:e.children,userKey:Qi(e,"key")}}function Yl(e,t,n){return e.condition?Li(e.condition,ec(e,t,n),Pi(n.helper(ii),['""',"true"])):ec(e,t,n)}function ec(e,t,n){const{helper:o,removeHelper:r}=n,s=Oi("key",Bi(`${t}`,!1,Fi,2)),{children:i}=e,l=i[0];if(1!==i.length||1!==l.type){if(1===i.length&&11===l.type){const e=l.codegenNode;return ol(e,s,n),e}{let t=64;return Ai(n,o(Xs),Ii([s]),i,t+"",void 0,void 0,!0,!1,e.loc)}}{const e=l.codegenNode;return 13!==e.type||e.isBlock||(r(si),e.isBlock=!0,o(oi),o(ri)),ol(e,s,n),e}}const tc=Ul("for",((e,t,n)=>{const{helper:o,removeHelper:r}=n;return function(e,t,n,o){if(!t.exp)return;const r=sc(t.exp);if(!r)return;const{scopes:s}=n,{source:i,value:l,key:c,index:a}=r,u={type:11,loc:t.loc,source:i,valueAlias:l,keyAlias:c,objectIndexAlias:a,parseResult:r,children:tl(e)?e.children:[e]};n.replaceNode(u),s.vFor++;const p=o&&o(u);return()=>{s.vFor--,p&&p()}}(e,t,n,(t=>{const s=Pi(o(di),[t.source]),i=Qi(e,"key"),l=i?Oi("key",6===i.type?Bi(i.value.content,!0):i.exp):null,c=4===t.source.type&&t.source.constType>0,a=c?64:i?128:256;return t.codegenNode=Ai(n,o(Xs),void 0,s,a+"",void 0,void 0,!0,!c,e.loc),()=>{let i;const a=tl(e),{children:u}=t,p=1!==u.length||1!==u[0].type,f=nl(e)?e:a&&1===e.children.length&&nl(e.children[0])?e.children[0]:null;f?(i=f.codegenNode,a&&l&&ol(i,l,n)):p?i=Ai(n,o(Xs),l?Ii([l]):void 0,e.children,"64",void 0,void 0,!0):(i=u[0].codegenNode,a&&l&&ol(i,l,n),i.isBlock!==!c&&(i.isBlock?(r(oi),r(ri)):r(si)),i.isBlock=!c,i.isBlock?(o(oi),o(ri)):o(si)),s.arguments.push(Vi(lc(t.parseResult),i,!0))}}))}));const nc=/([\s\S]*?)\s+(?:in|of)\s+([\s\S]*)/,oc=/,([^,\}\]]*)(?:,([^,\}\]]*))?$/,rc=/^\(|\)$/g;function sc(e,t){const n=e.loc,o=e.content,r=o.match(nc);if(!r)return;const[,s,i]=r,l={source:ic(n,i.trim(),o.indexOf(i,s.length)),value:void 0,key:void 0,index:void 0};let c=s.trim().replace(rc,"").trim();const a=s.indexOf(c),u=c.match(oc);if(u){c=c.replace(oc,"").trim();const e=u[1].trim();let t;if(e&&(t=o.indexOf(e,a+c.length),l.key=ic(n,e,t)),u[2]){const r=u[2].trim();r&&(l.index=ic(n,r,o.indexOf(r,l.key?t+e.length:a+c.length)))}}return c&&(l.value=ic(n,c,a)),l}function ic(e,t,n){return Bi(t,!1,Gi(e,n,t.length))}function lc({value:e,key:t,index:n}){const o=[];return e&&o.push(e),t&&(e||o.push(Bi("_",!1)),o.push(t)),n&&(t||(e||o.push(Bi("_",!1)),o.push(Bi("__",!1))),o.push(n)),o}const cc=Bi("undefined",!1),ac=(e,t)=>{if(1===e.type&&(1===e.tagType||3===e.tagType)){const n=Zi(e,"slot");if(n)return t.scopes.vSlot++,()=>{t.scopes.vSlot--}}},uc=(e,t,n)=>Vi(e,t,!1,!0,t.length?t[0].loc:n);function pc(e,t,n=uc){t.helper(Ti);const{children:o,loc:r}=e,s=[],i=[],l=(e,t)=>Oi("default",n(e,t,r));let c=t.scopes.vSlot>0||t.scopes.vFor>0;const a=Zi(e,"slot",!0);if(a){const{arg:e,exp:t}=a;e&&!ji(e)&&(c=!0),s.push(Oi(e||Bi("default",!0),n(t,o,r)))}let u=!1,p=!1;const f=[],d=new Set;for(let g=0;gfunction(){if(1!==(e=t.currentNode).type||0!==e.tagType&&1!==e.tagType)return;const{tag:n,props:o}=e,r=1===e.tagType,s=r?function(e,t,n=!1){const{tag:o}=e,r=bc(o)?Qi(e,"is"):Zi(e,"is");if(r){const e=6===r.type?r.value&&Bi(r.value.content,!0):r.exp;if(e)return Pi(t.helper(ui),[e])}const s=Hi(o)||t.isBuiltInComponent(o);if(s)return n||t.helper(s),s;return t.helper(ai),t.components.add(o),rl(o,"component")}(e,t):`"${n}"`;let i,l,c,a,u,p,f=0,d=I(s)&&s.callee===ui||s===Ys||s===ei||!r&&("svg"===n||"foreignObject"===n||Qi(e,"key",!0));if(o.length>0){const n=gc(e,t);i=n.props,f=n.patchFlag,u=n.dynamicPropNames;const o=n.directives;p=o&&o.length?Mi(o.map((e=>function(e,t){const n=[],o=hc.get(e);o?n.push(t.helperString(o)):(t.helper(pi),t.directives.add(e.name),n.push(rl(e.name,"directive")));const{loc:r}=e;e.exp&&n.push(e.exp);e.arg&&(e.exp||n.push("void 0"),n.push(e.arg));if(Object.keys(e.modifiers).length){e.arg||(e.exp||n.push("void 0"),n.push("void 0"));const t=Bi("true",!1,r);n.push(Ii(e.modifiers.map((e=>Oi(e,t))),r))}return Mi(n,e.loc)}(e,t)))):void 0}if(e.children.length>0){s===ti&&(d=!0,f|=1024);if(r&&s!==Ys&&s!==ti){const{slots:n,hasDynamicSlots:o}=pc(e,t);l=n,o&&(f|=1024)}else if(1===e.children.length&&s!==Ys){const n=e.children[0],o=n.type,r=5===o||8===o;r&&0===Ol(n,t)&&(f|=1),l=r||2===o?n:e.children}else l=e.children}0!==f&&(c=String(f),u&&u.length&&(a=function(e){let t="[";for(let n=0,o=e.length;n{if(ji(e)){const o=e.content,r=_(o);if(i||!r||"onclick"===o.toLowerCase()||"onUpdate:modelValue"===o||L(o)||(h=!0),r&&L(o)&&(g=!0),20===n.type||(4===n.type||8===n.type)&&Ol(n,t)>0)return;"ref"===o?p=!0:"class"!==o||i?"style"!==o||i?"key"===o||v.includes(o)||v.push(o):d=!0:f=!0}else m=!0};for(let _=0;_1?Pi(t.helper(vi),c,s):c[0]):l.length&&(b=Ii(vc(l),s)),m?u|=16:(f&&(u|=2),d&&(u|=4),v.length&&(u|=8),h&&(u|=32)),0!==u&&32!==u||!(p||g||a.length>0)||(u|=512),{props:b,directives:a,patchFlag:u,dynamicPropNames:v}}function vc(e){const t=new Map,n=[];for(let o=0;o{if(nl(e)){const{children:n,loc:o}=e,{slotName:r,slotProps:s}=function(e,t){let n,o='"default"';const r=[];for(let s=0;s0){const{props:o,directives:s}=gc(e,t,r);n=o}return{slotName:o,slotProps:n}}(e,t),i=[t.prefixIdentifiers?"_ctx.$slots":"$slots",r];s&&i.push(s),n.length&&(s||i.push("{}"),i.push(Vi([],n,!1,!1,o))),t.scopeId&&!t.slotted&&(s||i.push("{}"),n.length||i.push("undefined"),i.push("true")),e.codegenNode=Pi(t.helper(hi),i,o)}};const xc=/^\s*([\w$_]+|\([^)]*?\))\s*=>|^\s*function(?:\s+[\w$]+)?\s*\(/,Sc=(e,t,n,o)=>{const{loc:r,modifiers:s,arg:i}=e;let l;if(4===i.type)if(i.isStatic){l=Bi(K(H(i.content)),!0,i.loc)}else l=Ri([`${n.helperString(xi)}(`,i,")"]);else l=i,l.children.unshift(`${n.helperString(xi)}(`),l.children.push(")");let c=e.exp;c&&!c.content.trim()&&(c=void 0);let a=n.cacheHandlers&&!c;if(c){const e=Ki(c.content),t=!(e||xc.test(c.content)),n=c.content.includes(";");(t||a&&e)&&(c=Ri([`${t?"$event":"(...args)"} => ${n?"{":"("}`,c,n?"}":")"]))}let u={props:[Oi(l,c||Bi("() => {}",!1,r))]};return o&&(u=o(u)),a&&(u.props[0].value=n.cache(u.props[0].value)),u},Cc=(e,t,n)=>{const{exp:o,modifiers:r,loc:s}=e,i=e.arg;return 4!==i.type?(i.children.unshift("("),i.children.push(') || ""')):i.isStatic||(i.content=`${i.content} || ""`),r.includes("camel")&&(4===i.type?i.content=i.isStatic?H(i.content):`${n.helperString(bi)}(${i.content})`:(i.children.unshift(`${n.helperString(bi)}(`),i.children.push(")"))),!o||4===o.type&&!o.content.trim()?{props:[Oi(i,Bi("",!0,s))]}:{props:[Oi(i,o)]}},kc=(e,t)=>{if(0===e.type||1===e.type||11===e.type||10===e.type)return()=>{const n=e.children;let o,r=!1;for(let e=0;e{if(1===e.type&&Zi(e,"once",!0)){if(wc.has(e))return;return wc.add(e),t.helper(Si),()=>{const e=t.currentNode;e.codegenNode&&(e.codegenNode=t.cache(e.codegenNode,!0))}}},Nc=(e,t,n)=>{const{exp:o,arg:r}=e;if(!o)return Ec();const s=o.loc.source;if(!Ki(4===o.type?o.content:s))return Ec();const i=r||Bi("modelValue",!0),l=r?ji(r)?`onUpdate:${r.content}`:Ri(['"onUpdate:" + ',r]):"onUpdate:modelValue";let c;c=Ri([`${n.isTS?"($event: any)":"$event"} => (`,o," = $event)"]);const a=[Oi(i,e.exp),Oi(l,c)];if(e.modifiers.length&&1===t.tagType){const t=e.modifiers.map((e=>(zi(e)?e:JSON.stringify(e))+": true")).join(", "),n=r?ji(r)?`${r.content}Modifiers`:Ri([r,' + "Modifiers"']):"modelModifiers";a.push(Oi(n,Bi(`{ ${t} }`,!1,e.loc,2)))}return Ec(a)};function Ec(e=[]){return{props:e}}function $c(e,t={}){const n=t.onError||Zs,o="module"===t.mode;!0===t.prefixIdentifiers?n(Qs(45)):o&&n(Qs(46));t.cacheHandlers&&n(Qs(47)),t.scopeId&&!o&&n(Qs(48));const r=A(e)?cl(e,t):e,[s,i]=[[Tc,Ql,tc,_c,mc,ac,kc],{on:Sc,bind:Cc,model:Nc}];return Ll(r,S({},t,{prefixIdentifiers:false,nodeTransforms:[...s,...t.nodeTransforms||[]],directiveTransforms:S({},i,t.directiveTransforms||{})})),Dl(r,S({},t,{prefixIdentifiers:false}))}const Fc=Symbol(""),Ac=Symbol(""),Mc=Symbol(""),Ic=Symbol(""),Oc=Symbol(""),Bc=Symbol(""),Rc=Symbol(""),Pc=Symbol(""),Vc=Symbol(""),Lc=Symbol("");var jc;let Uc;jc={[Fc]:"vModelRadio",[Ac]:"vModelCheckbox",[Mc]:"vModelText",[Ic]:"vModelSelect",[Oc]:"vModelDynamic",[Bc]:"withModifiers",[Rc]:"withKeys",[Pc]:"vShow",[Vc]:"Transition",[Lc]:"TransitionGroup"},Object.getOwnPropertySymbols(jc).forEach((e=>{$i[e]=jc[e]}));const Hc=t("style,iframe,script,noscript",!0),Dc={isVoidTag:p,isNativeTag:e=>a(e)||u(e),isPreTag:e=>"pre"===e,decodeEntities:function(e){return(Uc||(Uc=document.createElement("div"))).innerHTML=e,Uc.textContent},isBuiltInComponent:e=>Ui(e,"Transition")?Vc:Ui(e,"TransitionGroup")?Lc:void 0,getNamespace(e,t){let n=t?t.ns:0;if(t&&2===n)if("annotation-xml"===t.tag){if("svg"===e)return 1;t.props.some((e=>6===e.type&&"encoding"===e.name&&null!=e.value&&("text/html"===e.value.content||"application/xhtml+xml"===e.value.content)))&&(n=0)}else/^m(?:[ions]|text)$/.test(t.tag)&&"mglyph"!==e&&"malignmark"!==e&&(n=0);else t&&1===n&&("foreignObject"!==t.tag&&"desc"!==t.tag&&"title"!==t.tag||(n=0));if(0===n){if("svg"===e)return 1;if("math"===e)return 2}return n},getTextMode({tag:e,ns:t}){if(0===t){if("textarea"===e||"title"===e)return 1;if(Hc(e))return 2}return 0}},zc=(e,t)=>{const n=l(e);return Bi(JSON.stringify(n),!1,t,3)};const Wc=t("passive,once,capture"),Kc=t("stop,prevent,self,ctrl,shift,alt,meta,exact,middle"),Gc=t("left,right"),qc=t("onkeyup,onkeydown,onkeypress",!0),Jc=(e,t)=>ji(e)&&"onclick"===e.content.toLowerCase()?Bi(t,!0):4!==e.type?Ri(["(",e,`) === "onClick" ? "${t}" : (`,e,")"]):e,Zc=(e,t)=>{1!==e.type||0!==e.tagType||"script"!==e.tag&&"style"!==e.tag||t.removeNode()},Qc=[e=>{1===e.type&&e.props.forEach(((t,n)=>{6===t.type&&"style"===t.name&&t.value&&(e.props[n]={type:7,name:"bind",arg:Bi("style",!0,t.loc),exp:zc(t.value.content,t.loc),modifiers:[],loc:t.loc})}))}],Xc={cloak:()=>({props:[]}),html:(e,t,n)=>{const{exp:o,loc:r}=e;return t.children.length&&(t.children.length=0),{props:[Oi(Bi("innerHTML",!0,r),o||Bi("",!0))]}},text:(e,t,n)=>{const{exp:o,loc:r}=e;return t.children.length&&(t.children.length=0),{props:[Oi(Bi("textContent",!0),o?Pi(n.helperString(gi),[o],r):Bi("",!0))]}},model:(e,t,n)=>{const o=Nc(e,t,n);if(!o.props.length||1===t.tagType)return o;const{tag:r}=t,s=n.isCustomElement(r);if("input"===r||"textarea"===r||"select"===r||s){let e=Mc,i=!1;if("input"===r||s){const n=Qi(t,"type");if(n){if(7===n.type)e=Oc;else if(n.value)switch(n.value.content){case"radio":e=Fc;break;case"checkbox":e=Ac;break;case"file":i=!0}}else(function(e){return e.props.some((e=>!(7!==e.type||"bind"!==e.name||e.arg&&4===e.arg.type&&e.arg.isStatic)))})(t)&&(e=Oc)}else"select"===r&&(e=Ic);i||(o.needRuntime=n.helper(e))}return o.props=o.props.filter((e=>!(4===e.key.type&&"modelValue"===e.key.content))),o},on:(e,t,n)=>Sc(e,0,n,(t=>{const{modifiers:o}=e;if(!o.length)return t;let{key:r,value:s}=t.props[0];const{keyModifiers:i,nonKeyModifiers:l,eventOptionModifiers:c}=((e,t)=>{const n=[],o=[],r=[];for(let s=0;s({props:[],needRuntime:n.helper(Pc)})};const Yc=Object.create(null);function ea(e,t){if(!A(e)){if(!e.nodeType)return v;e=e.innerHTML}const n=e,o=Yc[n];if(o)return o;if("#"===e[0]){const t=document.querySelector(e);e=t?t.innerHTML:""}const{code:r}=function(e,t={}){return $c(e,S({},Dc,t,{nodeTransforms:[Zc,...Qc,...t.nodeTransforms||[]],directiveTransforms:S({},Xc,t.directiveTransforms||{}),transformHoist:null}))}(e,S({hoistStatic:!0,onError(e){throw e}},t)),s=new Function(r)();return s._rc=!0,Yc[n]=s}return Nr(ea),e.BaseTransition=Un,e.Comment=Vo,e.Fragment=Ro,e.KeepAlive=Jn,e.Static=Lo,e.Suspense=un,e.Teleport=Ao,e.Text=Po,e.Transition=is,e.TransitionGroup=Ss,e.callWithAsyncErrorHandling=Ct,e.callWithErrorHandling=St,e.camelize=H,e.capitalize=W,e.cloneVNode=Xo,e.compile=ea,e.computed=Or,e.createApp=(...e)=>{const t=Gs().createApp(...e),{mount:n}=t;return t.mount=e=>{const o=Js(e);if(!o)return;const r=t._component;F(r)||r.render||r.template||(r.template=o.innerHTML),o.innerHTML="";const s=n(o,!1,o instanceof SVGElement);return o instanceof Element&&(o.removeAttribute("v-cloak"),o.setAttribute("data-v-app","")),s},t},e.createBlock=Wo,e.createCommentVNode=function(e="",t=!1){return t?(Ho(),Wo(Vo,null,e)):Qo(Vo,null,e)},e.createHydrationRenderer=Co,e.createRenderer=So,e.createSSRApp=(...e)=>{const t=qs().createApp(...e),{mount:n}=t;return t.mount=e=>{const t=Js(e);if(t)return n(t,!0,t instanceof SVGElement)},t},e.createSlots=function(e,t){for(let n=0;n{let e;return a||(e=a=t().catch((e=>{if(e=e instanceof Error?e:new Error(String(e)),l)return new Promise(((t,n)=>{l(e,(()=>t((u++,a=null,p()))),(()=>n(e)),u+1)}));throw e})).then((t=>e!==a&&a?a:(t&&(t.__esModule||"Module"===t[Symbol.toStringTag])&&(t=t.default),c=t,t))))};return vo({__asyncLoader:p,name:"AsyncComponentWrapper",setup(){const e=_r;if(c)return()=>yo(c,e);const t=t=>{a=null,kt(t,e,13,!o)};if(i&&e.suspense)return p().then((t=>()=>yo(t,e))).catch((e=>(t(e),()=>o?Qo(o,{error:e}):null)));const l=at(!1),u=at(),f=at(!!r);return r&&setTimeout((()=>{f.value=!1}),r),null!=s&&setTimeout((()=>{if(!l.value&&!u.value){const e=new Error(`Async component timed out after ${s}ms.`);t(e),u.value=e}}),s),p().then((()=>{l.value=!0})).catch((e=>{t(e),u.value=e})),()=>l.value&&c?yo(c,e):u.value&&o?Qo(o,{error:u.value}):n&&!f.value?Qo(n):void 0}})},e.defineComponent=vo,e.defineEmit=function(){return null},e.defineProps=function(){return null},e.getCurrentInstance=xr,e.getTransitionRawChildren=Gn,e.h=Br,e.handleError=kt,e.hydrate=(...e)=>{qs().hydrate(...e)},e.initCustomFormatter=function(){},e.inject=sr,e.isProxy=st,e.isReactive=ot,e.isReadonly=rt,e.isRef=ct,e.isRuntimeOnly=()=>!kr,e.isVNode=Ko,e.markRaw=function(e){return J(e,"__v_skip",!0),e},e.mergeProps=or,e.nextTick=Vt,e.onActivated=Qn,e.onBeforeMount=kn,e.onBeforeUnmount=En,e.onBeforeUpdate=Tn,e.onDeactivated=Xn,e.onErrorCaptured=Mn,e.onMounted=wn,e.onRenderTracked=An,e.onRenderTriggered=Fn,e.onUnmounted=$n,e.onUpdated=Nn,e.openBlock=Ho,e.popScopeId=function(){en=null},e.provide=rr,e.proxyRefs=ht,e.pushScopeId=function(e){en=e},e.queuePostFlushCb=Ht,e.reactive=Ye,e.readonly=tt,e.ref=at,e.registerRuntimeCompiler=Nr,e.render=(...e)=>{Gs().render(...e)},e.renderList=function(e,t){let n;if(T(e)||A(e)){n=new Array(e.length);for(let o=0,r=e.length;onull==e?"":I(e)?JSON.stringify(e,h,2):String(e),e.toHandlerKey=K,e.toHandlers=function(e){const t={};for(const n in e)t[K(n)]=e[n];return t},e.toRaw=it,e.toRef=vt,e.toRefs=function(e){const t=T(e)?new Array(e.length):{};for(const n in e)t[n]=vt(e,n);return t},e.transformVNodeArgs=function(e){},e.triggerRef=function(e){pe(it(e),"set","value",void 0)},e.unref=ft,e.useContext=function(){const e=xr();return e.setupContext||(e.setupContext=$r(e))},e.useCssModule=function(e="$style"){return m},e.useCssVars=function(e){const t=xr();if(!t)return;const n=()=>os(t.subTree,e(t.proxy));wn((()=>In(n,{flush:"post"}))),Nn(n)},e.useSSRContext=()=>{},e.useTransitionState=Ln,e.vModelCheckbox=Fs,e.vModelDynamic=Ps,e.vModelRadio=Ms,e.vModelSelect=Is,e.vModelText=$s,e.vShow=Hs,e.version=Pr,e.warn=function(e,...t){ce();const n=bt.length?bt[bt.length-1].component:null,o=n&&n.appContext.config.warnHandler,r=function(){let e=bt[bt.length-1];if(!e)return[];const t=[];for(;e;){const n=t[0];n&&n.vnode===e?n.recurseCount++:t.push({vnode:e,recurseCount:0});const o=e.component&&e.component.parent;e=o&&o.vnode}return t}();if(o)St(o,n,11,[e+t.join(""),n&&n.proxy,r.map((({vnode:e})=>`at <${Ir(n,e.type)}>`)).join("\n"),r]);else{const n=[`[Vue warn]: ${e}`,...t];r.length&&n.push("\n",...function(e){const t=[];return e.forEach(((e,n)=>{t.push(...0===n?[]:["\n"],...function({vnode:e,recurseCount:t}){const n=t>0?`... (${t} recursive calls)`:"",o=` at <${Ir(e.component,e.type,!!e.component&&null==e.component.parent)}`,r=">"+n;return e.props?[o,..._t(e.props),r]:[o+r]}(e))})),t}(r)),console.warn(...n)}ae()},e.watch=Bn,e.watchEffect=In,e.withCtx=nn,e.withDirectives=function(e,t){if(null===Yt)return e;const n=Yt.proxy,o=e.dirs||(e.dirs=[]);for(let r=0;rn=>{if(!("key"in n))return;const o=z(n.key);return t.some((e=>e===o||Us[e]===o))?e(n):void 0},e.withModifiers=(e,t)=>(n,...o)=>{for(let e=0;enn,Object.defineProperty(e,"__esModule",{value:!0}),e}({});
@/lua/ge/extensions/core/cameraModes/free.lua
local qdir, qdirLook = quat(), quat()
function C:update(data)
  -- Rotation

  self.manualzoom:update(data)
  return true
@/ui/modules/apps/PowerTrainDebug/app.js

            edge.torque = edge.torqueSmoother.update(devices[k].outputTorque[i])
            edge.av = edge.avSmoother.update(devices[k].outputAV[i])
            edge.torque = edge.torqueSmoother.update(devices[k].outputTorque[i])
            edge.av = edge.avSmoother.update(devices[k].outputAV[i])
          }
@/lua/ge/extensions/core/cameraModes/noise.lua

function C:update(data)
  self.timeSinceRandom = self.timeSinceRandom + data.dt
@/ui/modules/apps/ShiftPointDebug/app.js
            data.series[gears.length][0][1].y = rpm
            chart.update(data)
          }
@/ui/lib/ext/angular/angular-animate.js
        if (animation.from && animation.to) {
          update(animation.from.element);
          update(animation.to.element);
          update(animation.from.element);
          update(animation.to.element);
        } else {
        } else {
          update(animation.element);
        }

        function update(element) {
          var runner = getRunner(element);
@/lua/ge/extensions/core/ropeVisualTest.lua
      if im.IsItemHovered() then
        im.SetTooltip("Solver iterations per update (1-10)")
      end
@/ui/ui-vue/src/services/navigator-class.js

  update(data) {
    if (data)
      this.setup(data);
    this.layers.map.update();
    if (this.layers.elements)
    if (this.layers.elements)
      this.layers.elements.update(this.layers.map.state);
    this.layers.map.render();
    if (this.layers.vehicles)
      this.layers.vehicles.update(data);
    this.update(data);
      this.layers.vehicles.update(data);
    this.update(data);
    if (this.opts.hideBootscreen && this.layers.bootscreen)
      this.layers.bootscreen.toggle(data.ignitionLevel < 2);
    this.update();
  }
    // if (doupdate)
    //     this.update();
  }
    if (doupdate)
      this.update();
  }
    // if (doupdate)
    //     this.update();
  }
  //     // if (doupdate)
  //     //     this.update();
  // }
    // if (doupdate)
    //     this.update();
  }

  update() {
    const pos = {

  update(data) {
    if (this.dimver !== this.dimensions.ver) {

  update(data) {
    // receive live data from the GE map

  update(data) {
    if (!data || !data.key)

  update({ rotation }) {
    this.otherFrame = !this.otherFrame;
@/inspector/Controllers/BreakpointPopoverController.js
            let newText = change.text.join("").replace(/\n/g, "");
            change.update(change.from, change.to, [newText]);
        }
        this._popoverOptionsRowElement.classList.remove(WI.BreakpointPopoverController.HiddenStyleClassName);
        this._popover.update();
    }

        this._popover.update();
    }

        this._popover.update();
    }
    {
        this._popover.update();
    }
@/lua/ge/extensions/core/cameraModes/gameengine.lua
local gameNotified
function C:update(data)
  if not levelLoaded then
@/inspector/Controllers/TypeTokenAnnotator.js
            if (node.attachments.__typeToken)
                node.attachments.__typeToken.update(node.attachments.types);
        if (node.attachments.__typeToken)
            node.attachments.__typeToken.update(node.attachments.returnTypes);
    }
@/lua/console/test_dyncol.lua
        --hp = HighPerfTimer()
        BeamEngine:update(1/2000, 1/2000)
        --print(" - "..hp:stop().-" ms")
@/inspector/Controllers/CodeMirrorColorEditingController.js
        this._colorPicker.addEventListener(WI.ColorPicker.Event.ColorChanged, this._colorPickerColorChanged, this);
        this._colorPicker.addEventListener(WI.ColorPicker.Event.FormatChanged, (event) => popover.update());
        popover.content = this._colorPicker.element;
@/lua/ge/extensions/flowgraph/nodes/activity/activityFlow.lua
-- update -----------------------------------------
function C:update(dtReal, dtSim, dtRaw)
  self.mgr.dtReal = dtReal
  if not self.mgr.activity then
    self:update(...)
  end
function C:onUpdateActivity(...)
  self:update(...)
end
@/lua/ge/extensions/core/cameraModes/external.lua

function C:update(data)
  data.dt = data.dtSim -- switch to physics dt, to respect time scaling
  data.res.pos:set(self.camPos)
  self.predictor:update(data)
  self.autozoom:update(data)
  self.predictor:update(data)
  self.autozoom:update(data)
  self.autopoint:update(data)
  self.autozoom:update(data)
  self.autopoint:update(data)
  if self.isFanMode then
  if self.isFanMode then
    self.noise:update(data)
    self.smooth:update(data)
    self.noise:update(data)
    self.smooth:update(data)
  end
  end
  self.handheld:update(data)
  return true
@/inspector/Models/LineWidget.js

    update()
    {
        if (this._codeMirrorLineWidget.update)
            this._codeMirrorLineWidget.update();
    }
@/lua/ge/extensions/gameplay/drift/stuntZones/hitPole.lua
  if self.marker then
    self.marker:update(dtReal, dtSim)
  end
@/lua/ge/extensions/gameplay/markers/driftLineMarker.lua

function C:update()
end
local tmpVec = vec3()
function C:update(data)
  debugDrawer:drawSphere(self.pos, self.radius, self._inside and colorIn or colorOut)
@/lua/ge/extensions/gameplay/missions/missionTypes/editorHelper.lua
  e.transform.switchRotationForMouse = true
  if e.transform:update(mouseInfo) then
    mtd[e.fieldNamePos] = e.hasPos and (e.transform.pos:toTable())

  if e.lapConfig:update(mouseInfo) then
    ret = true
@/lua/vehicle/powertrain/hydraulicCylinder.lua
--unused, currently backup till fully refactored
local function update(cylinder, inputPressure, dt)
  local invBeamCount = cylinder.invBeamCount
@/lua/ge/extensions/gameplay/markerInteraction.lua
        marker:show()
        marker:update(updateData)
        -- post-marker decals, so they can be all drawn at once
@/ui/ui-vue/src/common/directives/BngFocusCapture.js

function update(data, value, firstTime = false) {
  if (typeof value === "function") {

    update(data, value, true)
  },
    if (!data) return
    update(data, value)
  },
@/lua/vehicle/hydros.lua

local function update(dtSim)
  -- state: the state of the hydro from -1 to 1
@/lua/common/libs/binaryheap/binaryheap.lua
function updateU(self, payload, newValue)
  return update(self, self.reverse[payload], newValue)
end
@/ui/ui-vue/src/common/directives/BngTooltip.js
    const data = el[DATA_PROP]
    if (data.update) requestAnimationFrame(() => data.update())
  },

  data.update && data.update()
}
@/ui/lib/ext/angular/angular.js
          
          
        
@/lua/ge/extensions/gameplay/markers/walkingMarker.lua

function C:update(data)
  if not self.visible then return end
@/ui/ui-vue/dist/index.js
var __create=Object.create,__defProp=Object.defineProperty,__getOwnPropDesc=Object.getOwnPropertyDescriptor,__getOwnPropNames=Object.getOwnPropertyNames,__getProtoOf=Object.getPrototypeOf,__hasOwnProp=Object.prototype.hasOwnProperty,__commonJSMin=(cb,mod)=>()=>(mod||cb((mod={exports:{}}).exports,mod),mod.exports),__export=all=>{let target={};for(var name in all)__defProp(target,name,{get:all[name],enumerable:!0});return target},__copyProps=(to,from,except,desc)=>{if(from&&typeof from==`object`||typeof from==`function`)for(var keys=__getOwnPropNames(from),i=0,n=keys.length,key;ifrom[k]).bind(null,key),enumerable:!(desc=__getOwnPropDesc(from,key))||desc.enumerable});return to},__toESM=(mod,isNodeMode,target)=>(target=mod==null?{}:__create(__getProtoOf(mod)),__copyProps(isNodeMode||!mod||!mod.__esModule?__defProp(target,`default`,{value:mod,enumerable:!0}):target,mod));(function(){let relList=document.createElement(`link`).relList;if(relList&&relList.supports&&relList.supports(`modulepreload`))return;for(let link of document.querySelectorAll(`link[rel="modulepreload"]`))processPreload(link);new MutationObserver(mutations=>{for(let mutation of mutations)if(mutation.type===`childList`)for(let node of mutation.addedNodes)node.tagName===`LINK`&&node.rel===`modulepreload`&&processPreload(node)}).observe(document,{childList:!0,subtree:!0});function getFetchOpts(link){let fetchOpts={};return link.integrity&&(fetchOpts.integrity=link.integrity),link.referrerPolicy&&(fetchOpts.referrerPolicy=link.referrerPolicy),link.crossOrigin===`use-credentials`?fetchOpts.credentials=`include`:link.crossOrigin===`anonymous`?fetchOpts.credentials=`omit`:fetchOpts.credentials=`same-origin`,fetchOpts}function processPreload(link){if(link.ep)return;link.ep=!0;let fetchOpts=getFetchOpts(link);fetch(link.href,fetchOpts)}})();function makeMap(str){let map=Object.create(null);for(let key of str.split(`,`))map[key]=1;return val=>val in map}var EMPTY_OBJ={},EMPTY_ARR=[],NOOP=()=>{},NO=()=>!1,isOn=key=>key.charCodeAt(0)===111&&key.charCodeAt(1)===110&&(key.charCodeAt(2)>122||key.charCodeAt(2)<97),isModelListener=key=>key.startsWith(`onUpdate:`),extend=Object.assign,remove$2=(arr,el)=>{let i=arr.indexOf(el);i>-1&&arr.splice(i,1)},hasOwnProperty$2=Object.prototype.hasOwnProperty,hasOwn$1=(val,key)=>hasOwnProperty$2.call(val,key),isArray$2=Array.isArray,isMap=val=>toTypeString$1(val)===`[object Map]`,isSet=val=>toTypeString$1(val)===`[object Set]`,isDate$1=val=>toTypeString$1(val)===`[object Date]`,isRegExp$1=val=>toTypeString$1(val)===`[object RegExp]`,isFunction$1=val=>typeof val==`function`,isString$1=val=>typeof val==`string`,isSymbol=val=>typeof val==`symbol`,isObject$1=val=>typeof val==`object`&&!!val,isPromise$1=val=>(isObject$1(val)||isFunction$1(val))&&isFunction$1(val.then)&&isFunction$1(val.catch),objectToString$1=Object.prototype.toString,toTypeString$1=value=>objectToString$1.call(value),toRawType=value=>toTypeString$1(value).slice(8,-1),isPlainObject$2=val=>toTypeString$1(val)===`[object Object]`,isIntegerKey=key=>isString$1(key)&&key!==`NaN`&&key[0]!==`-`&&``+parseInt(key,10)===key,isReservedProp=makeMap(`,key,ref,ref_for,ref_key,onVnodeBeforeMount,onVnodeMounted,onVnodeBeforeUpdate,onVnodeUpdated,onVnodeBeforeUnmount,onVnodeUnmounted`),isBuiltInDirective=makeMap(`bind,cloak,else-if,else,for,html,if,model,on,once,pre,show,slot,text,memo`),cacheStringFunction=fn=>{let cache$1=Object.create(null);return(str=>cache$1[str]||(cache$1[str]=fn(str)))},camelizeRE=/-\w/g,camelize=cacheStringFunction(str=>str.replace(camelizeRE,c=>c.slice(1).toUpperCase())),hyphenateRE=/\B([A-Z])/g,hyphenate=cacheStringFunction(str=>str.replace(hyphenateRE,`-$1`).toLowerCase()),capitalize$1=cacheStringFunction(str=>str.charAt(0).toUpperCase()+str.slice(1)),toHandlerKey=cacheStringFunction(str=>str?`on${capitalize$1(str)}`:``),hasChanged=(value,oldValue)=>!Object.is(value,oldValue),invokeArrayFns=(fns,...arg)=>{for(let i=0;i{Object.defineProperty(obj,key,{configurable:!0,enumerable:!1,writable,value})},looseToNumber=val=>{let n=parseFloat(val);return isNaN(n)?val:n},toNumber=val=>{let n=isString$1(val)?Number(val):NaN;return isNaN(n)?val:n},_globalThis$1,getGlobalThis$1=()=>_globalThis$1||=typeof globalThis<`u`?globalThis:typeof self<`u`?self:typeof window<`u`?window:typeof global<`u`?global:{};function genCacheKey(source,options){return source+JSON.stringify(options,(_,val)=>typeof val==`function`?val.toString():val)}var isGloballyAllowed=makeMap(`Infinity,undefined,NaN,isFinite,isNaN,parseFloat,parseInt,decodeURI,decodeURIComponent,encodeURI,encodeURIComponent,Math,Number,Date,Array,Object,Boolean,String,RegExp,Map,Set,JSON,Intl,BigInt,console,Error,Symbol`);function normalizeStyle(value){if(isArray$2(value)){let res={};for(let i=0;i{if(item){let tmp=item.split(propertyDelimiterRE);tmp.length>1&&(ret[tmp[0].trim()]=tmp[1].trim())}}),ret}function normalizeClass(value){let res=``;if(isString$1(value))res=value;else if(isArray$2(value))for(let i=0;ilooseEqual(item,val))}var isRef$2=val=>!!(val&&val.__v_isRef===!0),toDisplayString=val=>isString$1(val)?val:val==null?``:isArray$2(val)||isObject$1(val)&&(val.toString===objectToString$1||!isFunction$1(val.toString))?isRef$2(val)?toDisplayString(val.value):JSON.stringify(val,replacer,2):String(val),replacer=(_key,val)=>isRef$2(val)?replacer(_key,val.value):isMap(val)?{[`Map(${val.size})`]:[...val.entries()].reduce((entries,[key,val2],i)=>(entries[stringifySymbol(key,i)+` =>`]=val2,entries),{})}:isSet(val)?{[`Set(${val.size})`]:[...val.values()].map(v=>stringifySymbol(v))}:isSymbol(val)?stringifySymbol(val):isObject$1(val)&&!isArray$2(val)&&!isPlainObject$2(val)?String(val):val,stringifySymbol=(v,i=``)=>{var _a;return isSymbol(v)?`Symbol(${v.description??i})`:v};function normalizeCssVarValue(value){return value==null?`initial`:typeof value==`string`?value===``?` `:value:String(value)}var activeEffectScope,EffectScope=class{constructor(detached=!1){this.detached=detached,this._active=!0,this._on=0,this.effects=[],this.cleanups=[],this._isPaused=!1,this.parent=activeEffectScope,!detached&&activeEffectScope&&(this.index=(activeEffectScope.scopes||=[]).push(this)-1)}get active(){return this._active}pause(){if(this._active){this._isPaused=!0;let i,l;if(this.scopes)for(i=0,l=this.scopes.length;i0&&--this._on===0&&(activeEffectScope=this.prevScope,this.prevScope=void 0)}stop(fromParent){if(this._active){this._active=!1;let i,l;for(i=0,l=this.effects.length;i0)return;if(batchedComputed){let e=batchedComputed;for(batchedComputed=void 0;e;){let next=e.next;e.next=void 0,e.flags&=-9,e=next}}let error;for(;batchedSub;){let e=batchedSub;for(batchedSub=void 0;e;){let next=e.next;if(e.next=void 0,e.flags&=-9,e.flags&1)try{e.trigger()}catch(err){error||=err}e=next}}if(error)throw error}function prepareDeps(sub){for(let link=sub.deps;link;link=link.nextDep)link.version=-1,link.prevActiveLink=link.dep.activeLink,link.dep.activeLink=link}function cleanupDeps(sub){let head,tail=sub.depsTail,link=tail;for(;link;){let prev=link.prevDep;link.version===-1?(link===tail&&(tail=prev),removeSub(link),removeDep(link)):head=link,link.dep.activeLink=link.prevActiveLink,link.prevActiveLink=void 0,link=prev}sub.deps=head,sub.depsTail=tail}function isDirty(sub){for(let link=sub.deps;link;link=link.nextDep)if(link.dep.version!==link.version||link.dep.computed&&(refreshComputed(link.dep.computed)||link.dep.version!==link.version))return!0;return!!sub._dirty}function refreshComputed(computed$2){if(computed$2.flags&4&&!(computed$2.flags&16)||(computed$2.flags&=-17,computed$2.globalVersion===globalVersion)||(computed$2.globalVersion=globalVersion,!computed$2.isSSR&&computed$2.flags&128&&(!computed$2.deps&&!computed$2._dirty||!isDirty(computed$2))))return;computed$2.flags|=2;let dep=computed$2.dep,prevSub=activeSub,prevShouldTrack=shouldTrack;activeSub=computed$2,shouldTrack=!0;try{prepareDeps(computed$2);let value=computed$2.fn(computed$2._value);(dep.version===0||hasChanged(value,computed$2._value))&&(computed$2.flags|=128,computed$2._value=value,dep.version++)}catch(err){throw dep.version++,err}finally{activeSub=prevSub,shouldTrack=prevShouldTrack,cleanupDeps(computed$2),computed$2.flags&=-3}}function removeSub(link,soft=!1){let{dep,prevSub,nextSub}=link;if(prevSub&&(prevSub.nextSub=nextSub,link.prevSub=void 0),nextSub&&(nextSub.prevSub=prevSub,link.nextSub=void 0),dep.subs===link&&(dep.subs=prevSub,!prevSub&&dep.computed)){dep.computed.flags&=-5;for(let l=dep.computed.deps;l;l=l.nextDep)removeSub(l,!0)}!soft&&!--dep.sc&&dep.map&&dep.map.delete(dep.key)}function removeDep(link){let{prevDep,nextDep}=link;prevDep&&(prevDep.nextDep=nextDep,link.prevDep=void 0),nextDep&&(nextDep.prevDep=prevDep,link.nextDep=void 0)}function effect(fn,options){fn.effect instanceof ReactiveEffect&&(fn=fn.effect.fn);let e=new ReactiveEffect(fn);options&&extend(e,options);try{e.run()}catch(err){throw e.stop(),err}let runner=e.run.bind(e);return runner.effect=e,runner}function stop(runner){runner.effect.stop()}var shouldTrack=!0,trackStack=[];function pauseTracking(){trackStack.push(shouldTrack),shouldTrack=!1}function resetTracking(){let last=trackStack.pop();shouldTrack=last===void 0?!0:last}function cleanupEffect(e){let{cleanup}=e;if(e.cleanup=void 0,cleanup){let prevSub=activeSub;activeSub=void 0;try{cleanup()}finally{activeSub=prevSub}}}var globalVersion=0,Link=class{constructor(sub,dep){this.sub=sub,this.dep=dep,this.version=dep.version,this.nextDep=this.prevDep=this.nextSub=this.prevSub=this.prevActiveLink=void 0}},Dep=class{constructor(computed$2){this.computed=computed$2,this.version=0,this.activeLink=void 0,this.subs=void 0,this.map=void 0,this.key=void 0,this.sc=0,this.__v_skip=!0}track(debugInfo){if(!activeSub||!shouldTrack||activeSub===this.computed)return;let link=this.activeLink;if(link===void 0||link.sub!==activeSub)link=this.activeLink=new Link(activeSub,this),activeSub.deps?(link.prevDep=activeSub.depsTail,activeSub.depsTail.nextDep=link,activeSub.depsTail=link):activeSub.deps=activeSub.depsTail=link,addSub(link);else if(link.version===-1&&(link.version=this.version,link.nextDep)){let next=link.nextDep;next.prevDep=link.prevDep,link.prevDep&&(link.prevDep.nextDep=next),link.prevDep=activeSub.depsTail,link.nextDep=void 0,activeSub.depsTail.nextDep=link,activeSub.depsTail=link,activeSub.deps===link&&(activeSub.deps=next)}return link}trigger(debugInfo){this.version++,globalVersion++,this.notify(debugInfo)}notify(debugInfo){startBatch();try{for(let link=this.subs;link;link=link.prevSub)link.sub.notify()&&link.sub.dep.notify()}finally{endBatch()}}};function addSub(link){if(link.dep.sc++,link.sub.flags&4){let computed$2=link.dep.computed;if(computed$2&&!link.dep.subs){computed$2.flags|=20;for(let l=computed$2.deps;l;l=l.nextDep)addSub(l)}let currentTail=link.dep.subs;currentTail!==link&&(link.prevSub=currentTail,currentTail&&(currentTail.nextSub=link)),link.dep.subs=link}}var targetMap=new WeakMap,ITERATE_KEY=Symbol(``),MAP_KEY_ITERATE_KEY=Symbol(``),ARRAY_ITERATE_KEY=Symbol(``);function track(target,type,key){if(shouldTrack&&activeSub){let depsMap=targetMap.get(target);depsMap||targetMap.set(target,depsMap=new Map);let dep=depsMap.get(key);dep||(depsMap.set(key,dep=new Dep),dep.map=depsMap,dep.key=key),dep.track()}}function trigger$1(target,type,key,newValue,oldValue,oldTarget){let depsMap=targetMap.get(target);if(!depsMap){globalVersion++;return}let run$1=dep=>{dep&&dep.trigger()};if(startBatch(),type===`clear`)depsMap.forEach(run$1);else{let targetIsArray=isArray$2(target),isArrayIndex=targetIsArray&&isIntegerKey(key);if(targetIsArray&&key===`length`){let newLength=Number(newValue);depsMap.forEach((dep,key2)=>{(key2===`length`||key2===ARRAY_ITERATE_KEY||!isSymbol(key2)&&key2>=newLength)&&run$1(dep)})}else switch((key!==void 0||depsMap.has(void 0))&&run$1(depsMap.get(key)),isArrayIndex&&run$1(depsMap.get(ARRAY_ITERATE_KEY)),type){case`add`:targetIsArray?isArrayIndex&&run$1(depsMap.get(`length`)):(run$1(depsMap.get(ITERATE_KEY)),isMap(target)&&run$1(depsMap.get(MAP_KEY_ITERATE_KEY)));break;case`delete`:targetIsArray||(run$1(depsMap.get(ITERATE_KEY)),isMap(target)&&run$1(depsMap.get(MAP_KEY_ITERATE_KEY)));break;case`set`:isMap(target)&&run$1(depsMap.get(ITERATE_KEY));break}}endBatch()}function getDepFromReactive(object,key){let depMap=targetMap.get(object);return depMap&&depMap.get(key)}function reactiveReadArray(array){let raw=toRaw(array);return raw===array?raw:(track(raw,`iterate`,ARRAY_ITERATE_KEY),isShallow(array)?raw:raw.map(toReactive))}function shallowReadArray(arr){return track(arr=toRaw(arr),`iterate`,ARRAY_ITERATE_KEY),arr}var arrayInstrumentations={__proto__:null,[Symbol.iterator](){return iterator(this,Symbol.iterator,toReactive)},concat(...args){return reactiveReadArray(this).concat(...args.map(x=>isArray$2(x)?reactiveReadArray(x):x))},entries(){return iterator(this,`entries`,value=>(value[1]=toReactive(value[1]),value))},every(fn,thisArg){return apply(this,`every`,fn,thisArg,void 0,arguments)},filter(fn,thisArg){return apply(this,`filter`,fn,thisArg,v=>v.map(toReactive),arguments)},find(fn,thisArg){return apply(this,`find`,fn,thisArg,toReactive,arguments)},findIndex(fn,thisArg){return apply(this,`findIndex`,fn,thisArg,void 0,arguments)},findLast(fn,thisArg){return apply(this,`findLast`,fn,thisArg,toReactive,arguments)},findLastIndex(fn,thisArg){return apply(this,`findLastIndex`,fn,thisArg,void 0,arguments)},forEach(fn,thisArg){return apply(this,`forEach`,fn,thisArg,void 0,arguments)},includes(...args){return searchProxy(this,`includes`,args)},indexOf(...args){return searchProxy(this,`indexOf`,args)},join(separator){return reactiveReadArray(this).join(separator)},lastIndexOf(...args){return searchProxy(this,`lastIndexOf`,args)},map(fn,thisArg){return apply(this,`map`,fn,thisArg,void 0,arguments)},pop(){return noTracking(this,`pop`)},push(...args){return noTracking(this,`push`,args)},reduce(fn,...args){return reduce(this,`reduce`,fn,args)},reduceRight(fn,...args){return reduce(this,`reduceRight`,fn,args)},shift(){return noTracking(this,`shift`)},some(fn,thisArg){return apply(this,`some`,fn,thisArg,void 0,arguments)},splice(...args){return noTracking(this,`splice`,args)},toReversed(){return reactiveReadArray(this).toReversed()},toSorted(comparer){return reactiveReadArray(this).toSorted(comparer)},toSpliced(...args){return reactiveReadArray(this).toSpliced(...args)},unshift(...args){return noTracking(this,`unshift`,args)},values(){return iterator(this,`values`,toReactive)}};function iterator(self$1,method,wrapValue){let arr=shallowReadArray(self$1),iter=arr[method]();return arr!==self$1&&!isShallow(self$1)&&(iter._next=iter.next,iter.next=()=>{let result=iter._next();return result.done||(result.value=wrapValue(result.value)),result}),iter}var arrayProto=Array.prototype;function apply(self$1,method,fn,thisArg,wrappedRetFn,args){let arr=shallowReadArray(self$1),needsWrap=arr!==self$1&&!isShallow(self$1),methodFn=arr[method];if(methodFn!==arrayProto[method]){let result2=methodFn.apply(self$1,args);return needsWrap?toReactive(result2):result2}let wrappedFn=fn;arr!==self$1&&(needsWrap?wrappedFn=function(item,index){return fn.call(this,toReactive(item),index,self$1)}:fn.length>2&&(wrappedFn=function(item,index){return fn.call(this,item,index,self$1)}));let result=methodFn.call(arr,wrappedFn,thisArg);return needsWrap&&wrappedRetFn?wrappedRetFn(result):result}function reduce(self$1,method,fn,args){let arr=shallowReadArray(self$1),wrappedFn=fn;return arr!==self$1&&(isShallow(self$1)?fn.length>3&&(wrappedFn=function(acc,item,index){return fn.call(this,acc,item,index,self$1)}):wrappedFn=function(acc,item,index){return fn.call(this,acc,toReactive(item),index,self$1)}),arr[method](wrappedFn,...args)}function searchProxy(self$1,method,args){let arr=toRaw(self$1);track(arr,`iterate`,ARRAY_ITERATE_KEY);let res=arr[method](...args);return(res===-1||res===!1)&&isProxy(args[0])?(args[0]=toRaw(args[0]),arr[method](...args)):res}function noTracking(self$1,method,args=[]){pauseTracking(),startBatch();let res=toRaw(self$1)[method].apply(self$1,args);return endBatch(),resetTracking(),res}var isNonTrackableKeys=makeMap(`__proto__,__v_isRef,__isVue`),builtInSymbols=new Set(Object.getOwnPropertyNames(Symbol).filter(key=>key!==`arguments`&&key!==`caller`).map(key=>Symbol[key]).filter(isSymbol));function hasOwnProperty$1(key){isSymbol(key)||(key=String(key));let obj=toRaw(this);return track(obj,`has`,key),obj.hasOwnProperty(key)}var BaseReactiveHandler=class{constructor(_isReadonly=!1,_isShallow=!1){this._isReadonly=_isReadonly,this._isShallow=_isShallow}get(target,key,receiver){if(key===`__v_skip`)return target.__v_skip;let isReadonly2=this._isReadonly,isShallow2=this._isShallow;if(key===`__v_isReactive`)return!isReadonly2;if(key===`__v_isReadonly`)return isReadonly2;if(key===`__v_isShallow`)return isShallow2;if(key===`__v_raw`)return receiver===(isReadonly2?isShallow2?shallowReadonlyMap:readonlyMap:isShallow2?shallowReactiveMap:reactiveMap).get(target)||Object.getPrototypeOf(target)===Object.getPrototypeOf(receiver)?target:void 0;let targetIsArray=isArray$2(target);if(!isReadonly2){let fn;if(targetIsArray&&(fn=arrayInstrumentations[key]))return fn;if(key===`hasOwnProperty`)return hasOwnProperty$1}let res=Reflect.get(target,key,isRef(target)?target:receiver);if((isSymbol(key)?builtInSymbols.has(key):isNonTrackableKeys(key))||(isReadonly2||track(target,`get`,key),isShallow2))return res;if(isRef(res)){let value=targetIsArray&&isIntegerKey(key)?res:res.value;return isReadonly2&&isObject$1(value)?readonly(value):value}return isObject$1(res)?isReadonly2?readonly(res):reactive(res):res}},MutableReactiveHandler=class extends BaseReactiveHandler{constructor(isShallow2=!1){super(!1,isShallow2)}set(target,key,value,receiver){let oldValue=target[key];if(!this._isShallow){let isOldValueReadonly=isReadonly(oldValue);if(!isShallow(value)&&!isReadonly(value)&&(oldValue=toRaw(oldValue),value=toRaw(value)),!isArray$2(target)&&isRef(oldValue)&&!isRef(value))return isOldValueReadonly||(oldValue.value=value),!0}let hadKey=isArray$2(target)&&isIntegerKey(key)?Number(key)value,getProto=v=>Reflect.getPrototypeOf(v);function createIterableMethod(method,isReadonly2,isShallow2){return function(...args){let target=this.__v_raw,rawTarget=toRaw(target),targetIsMap=isMap(rawTarget),isPair=method===`entries`||method===Symbol.iterator&&targetIsMap,isKeyOnly=method===`keys`&&targetIsMap,innerIterator=target[method](...args),wrap=isShallow2?toShallow:isReadonly2?toReadonly:toReactive;return!isReadonly2&&track(rawTarget,`iterate`,isKeyOnly?MAP_KEY_ITERATE_KEY:ITERATE_KEY),{next(){let{value,done}=innerIterator.next();return done?{value,done}:{value:isPair?[wrap(value[0]),wrap(value[1])]:wrap(value),done}},[Symbol.iterator](){return this}}}}function createReadonlyMethod(type){return function(...args){return type===`delete`?!1:type===`clear`?void 0:this}}function createInstrumentations(readonly$1,shallow){let instrumentations={get(key){let target=this.__v_raw,rawTarget=toRaw(target),rawKey=toRaw(key);readonly$1||(hasChanged(key,rawKey)&&track(rawTarget,`get`,key),track(rawTarget,`get`,rawKey));let{has:has$1}=getProto(rawTarget),wrap=shallow?toShallow:readonly$1?toReadonly:toReactive;if(has$1.call(rawTarget,key))return wrap(target.get(key));if(has$1.call(rawTarget,rawKey))return wrap(target.get(rawKey));target!==rawTarget&&target.get(key)},get size(){let target=this.__v_raw;return!readonly$1&&track(toRaw(target),`iterate`,ITERATE_KEY),target.size},has(key){let target=this.__v_raw,rawTarget=toRaw(target),rawKey=toRaw(key);return readonly$1||(hasChanged(key,rawKey)&&track(rawTarget,`has`,key),track(rawTarget,`has`,rawKey)),key===rawKey?target.has(key):target.has(key)||target.has(rawKey)},forEach(callback,thisArg){let observed$2=this,target=observed$2.__v_raw,rawTarget=toRaw(target),wrap=shallow?toShallow:readonly$1?toReadonly:toReactive;return!readonly$1&&track(rawTarget,`iterate`,ITERATE_KEY),target.forEach((value,key)=>callback.call(thisArg,wrap(value),wrap(key),observed$2))}};return extend(instrumentations,readonly$1?{add:createReadonlyMethod(`add`),set:createReadonlyMethod(`set`),delete:createReadonlyMethod(`delete`),clear:createReadonlyMethod(`clear`)}:{add(value){!shallow&&!isShallow(value)&&!isReadonly(value)&&(value=toRaw(value));let target=toRaw(this);return getProto(target).has.call(target,value)||(target.add(value),trigger$1(target,`add`,value,value)),this},set(key,value){!shallow&&!isShallow(value)&&!isReadonly(value)&&(value=toRaw(value));let target=toRaw(this),{has:has$1,get}=getProto(target),hadKey=has$1.call(target,key);hadKey||=(key=toRaw(key),has$1.call(target,key));let oldValue=get.call(target,key);return target.set(key,value),hadKey?hasChanged(value,oldValue)&&trigger$1(target,`set`,key,value,oldValue):trigger$1(target,`add`,key,value),this},delete(key){let target=toRaw(this),{has:has$1,get}=getProto(target),hadKey=has$1.call(target,key);hadKey||=(key=toRaw(key),has$1.call(target,key));let oldValue=get?get.call(target,key):void 0,result=target.delete(key);return hadKey&&trigger$1(target,`delete`,key,void 0,oldValue),result},clear(){let target=toRaw(this),hadItems=target.size!==0,oldTarget,result=target.clear();return hadItems&&trigger$1(target,`clear`,void 0,void 0,void 0),result}}),[`keys`,`values`,`entries`,Symbol.iterator].forEach(method=>{instrumentations[method]=createIterableMethod(method,readonly$1,shallow)}),instrumentations}function createInstrumentationGetter(isReadonly2,shallow){let instrumentations=createInstrumentations(isReadonly2,shallow);return(target,key,receiver)=>key===`__v_isReactive`?!isReadonly2:key===`__v_isReadonly`?isReadonly2:key===`__v_raw`?target:Reflect.get(hasOwn$1(instrumentations,key)&&key in target?instrumentations:target,key,receiver)}var mutableCollectionHandlers={get:createInstrumentationGetter(!1,!1)},shallowCollectionHandlers={get:createInstrumentationGetter(!1,!0)},readonlyCollectionHandlers={get:createInstrumentationGetter(!0,!1)},shallowReadonlyCollectionHandlers={get:createInstrumentationGetter(!0,!0)},reactiveMap=new WeakMap,shallowReactiveMap=new WeakMap,readonlyMap=new WeakMap,shallowReadonlyMap=new WeakMap;function targetTypeMap(rawType){switch(rawType){case`Object`:case`Array`:return 1;case`Map`:case`Set`:case`WeakMap`:case`WeakSet`:return 2;default:return 0}}function getTargetType(value){return value.__v_skip||!Object.isExtensible(value)?0:targetTypeMap(toRawType(value))}function reactive(target){return isReadonly(target)?target:createReactiveObject(target,!1,mutableHandlers,mutableCollectionHandlers,reactiveMap)}function shallowReactive(target){return createReactiveObject(target,!1,shallowReactiveHandlers,shallowCollectionHandlers,shallowReactiveMap)}function readonly(target){return createReactiveObject(target,!0,readonlyHandlers,readonlyCollectionHandlers,readonlyMap)}function shallowReadonly(target){return createReactiveObject(target,!0,shallowReadonlyHandlers,shallowReadonlyCollectionHandlers,shallowReadonlyMap)}function createReactiveObject(target,isReadonly2,baseHandlers,collectionHandlers,proxyMap){if(!isObject$1(target)||target.__v_raw&&!(isReadonly2&&target.__v_isReactive))return target;let targetType=getTargetType(target);if(targetType===0)return target;let existingProxy=proxyMap.get(target);if(existingProxy)return existingProxy;let proxy=new Proxy(target,targetType===2?collectionHandlers:baseHandlers);return proxyMap.set(target,proxy),proxy}function isReactive(value){return isReadonly(value)?isReactive(value.__v_raw):!!(value&&value.__v_isReactive)}function isReadonly(value){return!!(value&&value.__v_isReadonly)}function isShallow(value){return!!(value&&value.__v_isShallow)}function isProxy(value){return value?!!value.__v_raw:!1}function toRaw(observed$2){let raw=observed$2&&observed$2.__v_raw;return raw?toRaw(raw):observed$2}function markRaw(value){return!hasOwn$1(value,`__v_skip`)&&Object.isExtensible(value)&&def(value,`__v_skip`,!0),value}var toReactive=value=>isObject$1(value)?reactive(value):value,toReadonly=value=>isObject$1(value)?readonly(value):value;function isRef(r){return r?r.__v_isRef===!0:!1}function ref(value){return createRef(value,!1)}function shallowRef(value){return createRef(value,!0)}function createRef(rawValue,shallow){return isRef(rawValue)?rawValue:new RefImpl(rawValue,shallow)}var RefImpl=class{constructor(value,isShallow2){this.dep=new Dep,this.__v_isRef=!0,this.__v_isShallow=!1,this._rawValue=isShallow2?value:toRaw(value),this._value=isShallow2?value:toReactive(value),this.__v_isShallow=isShallow2}get value(){return this.dep.track(),this._value}set value(newValue){let oldValue=this._rawValue,useDirectValue=this.__v_isShallow||isShallow(newValue)||isReadonly(newValue);newValue=useDirectValue?newValue:toRaw(newValue),hasChanged(newValue,oldValue)&&(this._rawValue=newValue,this._value=useDirectValue?newValue:toReactive(newValue),this.dep.trigger())}};function triggerRef(ref2){ref2.dep&&ref2.dep.trigger()}function unref(ref2){return isRef(ref2)?ref2.value:ref2}function toValue$1(source){return isFunction$1(source)?source():unref(source)}var shallowUnwrapHandlers={get:(target,key,receiver)=>key===`__v_raw`?target:unref(Reflect.get(target,key,receiver)),set:(target,key,value,receiver)=>{let oldValue=target[key];return isRef(oldValue)&&!isRef(value)?(oldValue.value=value,!0):Reflect.set(target,key,value,receiver)}};function proxyRefs(objectWithRefs){return isReactive(objectWithRefs)?objectWithRefs:new Proxy(objectWithRefs,shallowUnwrapHandlers)}var CustomRefImpl=class{constructor(factory){this.__v_isRef=!0,this._value=void 0;let dep=this.dep=new Dep,{get,set}=factory(dep.track.bind(dep),dep.trigger.bind(dep));this._get=get,this._set=set}get value(){return this._value=this._get()}set value(newVal){this._set(newVal)}};function customRef(factory){return new CustomRefImpl(factory)}function toRefs(object){let ret=isArray$2(object)?Array(object.length):{};for(let key in object)ret[key]=propertyToRef(object,key);return ret}var ObjectRefImpl=class{constructor(_object,_key,_defaultValue){this._object=_object,this._key=_key,this._defaultValue=_defaultValue,this.__v_isRef=!0,this._value=void 0}get value(){let val=this._object[this._key];return this._value=val===void 0?this._defaultValue:val}set value(newVal){this._object[this._key]=newVal}get dep(){return getDepFromReactive(toRaw(this._object),this._key)}},GetterRefImpl=class{constructor(_getter){this._getter=_getter,this.__v_isRef=!0,this.__v_isReadonly=!0,this._value=void 0}get value(){return this._value=this._getter()}};function toRef(source,key,defaultValue){return isRef(source)?source:isFunction$1(source)?new GetterRefImpl(source):isObject$1(source)&&arguments.length>1?propertyToRef(source,key,defaultValue):ref(source)}function propertyToRef(source,key,defaultValue){let val=source[key];return isRef(val)?val:new ObjectRefImpl(source,key,defaultValue)}var ComputedRefImpl=class{constructor(fn,setter,isSSR){this.fn=fn,this.setter=setter,this._value=void 0,this.dep=new Dep(this),this.__v_isRef=!0,this.deps=void 0,this.depsTail=void 0,this.flags=16,this.globalVersion=globalVersion-1,this.next=void 0,this.effect=this,this.__v_isReadonly=!setter,this.isSSR=isSSR}notify(){if(this.flags|=16,!(this.flags&8)&&activeSub!==this)return batch(this,!0),!0}get value(){let link=this.dep.track();return refreshComputed(this),link&&(link.version=this.dep.version),this._value}set value(newValue){this.setter&&this.setter(newValue)}};function computed$1(getterOrOptions,debugOptions,isSSR=!1){let getter,setter;return isFunction$1(getterOrOptions)?getter=getterOrOptions:(getter=getterOrOptions.get,setter=getterOrOptions.set),new ComputedRefImpl(getter,setter,isSSR)}var TrackOpTypes={GET:`get`,HAS:`has`,ITERATE:`iterate`},TriggerOpTypes={SET:`set`,ADD:`add`,DELETE:`delete`,CLEAR:`clear`},INITIAL_WATCHER_VALUE={},cleanupMap=new WeakMap,activeWatcher=void 0;function getCurrentWatcher(){return activeWatcher}function onWatcherCleanup(cleanupFn,failSilently=!1,owner=activeWatcher){if(owner){let cleanups=cleanupMap.get(owner);cleanups||cleanupMap.set(owner,cleanups=[]),cleanups.push(cleanupFn)}}function watch$1(source,cb,options=EMPTY_OBJ){let{immediate,deep,once,scheduler,augmentJob,call}=options,reactiveGetter=source2=>deep?source2:isShallow(source2)||deep===!1||deep===0?traverse(source2,1):traverse(source2),effect$1,getter,cleanup,boundCleanup,forceTrigger=!1,isMultiSource=!1;if(isRef(source)?(getter=()=>source.value,forceTrigger=isShallow(source)):isReactive(source)?(getter=()=>reactiveGetter(source),forceTrigger=!0):isArray$2(source)?(isMultiSource=!0,forceTrigger=source.some(s=>isReactive(s)||isShallow(s)),getter=()=>source.map(s=>{if(isRef(s))return s.value;if(isReactive(s))return reactiveGetter(s);if(isFunction$1(s))return call?call(s,2):s()})):getter=isFunction$1(source)?cb?call?()=>call(source,2):source:()=>{if(cleanup){pauseTracking();try{cleanup()}finally{resetTracking()}}let currentEffect=activeWatcher;activeWatcher=effect$1;try{return call?call(source,3,[boundCleanup]):source(boundCleanup)}finally{activeWatcher=currentEffect}}:NOOP,cb&&deep){let baseGetter=getter,depth=deep===!0?1/0:deep;getter=()=>traverse(baseGetter(),depth)}let scope$1=getCurrentScope(),watchHandle=()=>{effect$1.stop(),scope$1&&scope$1.active&&remove$2(scope$1.effects,effect$1)};if(once&&cb){let _cb=cb;cb=(...args)=>{_cb(...args),watchHandle()}}let oldValue=isMultiSource?Array(source.length).fill(INITIAL_WATCHER_VALUE):INITIAL_WATCHER_VALUE,job=immediateFirstRun=>{if(!(!(effect$1.flags&1)||!effect$1.dirty&&!immediateFirstRun))if(cb){let newValue=effect$1.run();if(deep||forceTrigger||(isMultiSource?newValue.some((v,i)=>hasChanged(v,oldValue[i])):hasChanged(newValue,oldValue))){cleanup&&cleanup();let currentWatcher=activeWatcher;activeWatcher=effect$1;try{let args=[newValue,oldValue===INITIAL_WATCHER_VALUE?void 0:isMultiSource&&oldValue[0]===INITIAL_WATCHER_VALUE?[]:oldValue,boundCleanup];oldValue=newValue,call?call(cb,3,args):cb(...args)}finally{activeWatcher=currentWatcher}}}else effect$1.run()};return augmentJob&&augmentJob(job),effect$1=new ReactiveEffect(getter),effect$1.scheduler=scheduler?()=>scheduler(job,!1):job,boundCleanup=fn=>onWatcherCleanup(fn,!1,effect$1),cleanup=effect$1.onStop=()=>{let cleanups=cleanupMap.get(effect$1);if(cleanups){if(call)call(cleanups,4);else for(let cleanup2 of cleanups)cleanup2();cleanupMap.delete(effect$1)}},cb?immediate?job(!0):oldValue=effect$1.run():scheduler?scheduler(job.bind(null,!0),!0):effect$1.run(),watchHandle.pause=effect$1.pause.bind(effect$1),watchHandle.resume=effect$1.resume.bind(effect$1),watchHandle.stop=watchHandle,watchHandle}function traverse(value,depth=1/0,seen$3){if(depth<=0||!isObject$1(value)||value.__v_skip||(seen$3||=new Map,(seen$3.get(value)||0)>=depth))return value;if(seen$3.set(value,depth),depth--,isRef(value))traverse(value.value,depth,seen$3);else if(isArray$2(value))for(let i=0;i{traverse(v,depth,seen$3)});else if(isPlainObject$2(value)){for(let key in value)traverse(value[key],depth,seen$3);for(let key of Object.getOwnPropertySymbols(value))Object.prototype.propertyIsEnumerable.call(value,key)&&traverse(value[key],depth,seen$3)}return value}var stack$1=[];function pushWarningContext(vnode){stack$1.push(vnode)}function popWarningContext(){stack$1.pop()}function assertNumber(val,type){}var ErrorCodes={SETUP_FUNCTION:0,0:`SETUP_FUNCTION`,RENDER_FUNCTION:1,1:`RENDER_FUNCTION`,NATIVE_EVENT_HANDLER:5,5:`NATIVE_EVENT_HANDLER`,COMPONENT_EVENT_HANDLER:6,6:`COMPONENT_EVENT_HANDLER`,VNODE_HOOK:7,7:`VNODE_HOOK`,DIRECTIVE_HOOK:8,8:`DIRECTIVE_HOOK`,TRANSITION_HOOK:9,9:`TRANSITION_HOOK`,APP_ERROR_HANDLER:10,10:`APP_ERROR_HANDLER`,APP_WARN_HANDLER:11,11:`APP_WARN_HANDLER`,FUNCTION_REF:12,12:`FUNCTION_REF`,ASYNC_COMPONENT_LOADER:13,13:`ASYNC_COMPONENT_LOADER`,SCHEDULER:14,14:`SCHEDULER`,COMPONENT_UPDATE:15,15:`COMPONENT_UPDATE`,APP_UNMOUNT_CLEANUP:16,16:`APP_UNMOUNT_CLEANUP`},ErrorTypeStrings$1={sp:`serverPrefetch hook`,bc:`beforeCreate hook`,c:`created hook`,bm:`beforeMount hook`,m:`mounted hook`,bu:`beforeUpdate hook`,u:`updated`,bum:`beforeUnmount hook`,um:`unmounted hook`,a:`activated hook`,da:`deactivated hook`,ec:`errorCaptured hook`,rtc:`renderTracked hook`,rtg:`renderTriggered hook`,0:`setup function`,1:`render function`,2:`watcher getter`,3:`watcher callback`,4:`watcher cleanup function`,5:`native event handler`,6:`component event handler`,7:`vnode hook`,8:`directive hook`,9:`transition hook`,10:`app errorHandler`,11:`app warnHandler`,12:`ref function`,13:`async component loader`,14:`scheduler flush`,15:`component update`,16:`app unmount cleanup function`};function callWithErrorHandling(fn,instance$1,type,args){try{return args?fn(...args):fn()}catch(err){handleError(err,instance$1,type)}}function callWithAsyncErrorHandling(fn,instance$1,type,args){if(isFunction$1(fn)){let res=callWithErrorHandling(fn,instance$1,type,args);return res&&isPromise$1(res)&&res.catch(err=>{handleError(err,instance$1,type)}),res}if(isArray$2(fn)){let values=[];for(let i=0;i>>1,middleJob=queue$1[middle],middleJobId=getId(middleJob);middleJobId=getId(lastJob)?queue$1.push(job):queue$1.splice(findInsertionIndex$1(jobId),0,job),job.flags|=1,queueFlush()}}function queueFlush(){currentFlushPromise||=resolvedPromise.then(flushJobs)}function queuePostFlushCb(cb){isArray$2(cb)?pendingPostFlushCbs.push(...cb):activePostFlushCbs&&cb.id===-1?activePostFlushCbs.splice(postFlushIndex+1,0,cb):cb.flags&1||(pendingPostFlushCbs.push(cb),cb.flags|=1),queueFlush()}function flushPreFlushCbs(instance$1,seen$3,i=flushIndex+1){for(;igetId(a$1)-getId(b));if(pendingPostFlushCbs.length=0,activePostFlushCbs){activePostFlushCbs.push(...deduped);return}for(activePostFlushCbs=deduped,postFlushIndex=0;postFlushIndexjob.id==null?job.flags&2?-1:1/0:job.id;function flushJobs(seen$3){try{for(flushIndex=0;flushIndexdevtools$1.emit(event,...args)),buffer=[]):typeof window<`u`&&window.HTMLElement&&!(window.navigator?.userAgent)?.includes(`jsdom`)?((target.__VUE_DEVTOOLS_HOOK_REPLAY__=target.__VUE_DEVTOOLS_HOOK_REPLAY__||[]).push(newHook=>{setDevtoolsHook$1(newHook,target)}),setTimeout(()=>{devtools$1||(target.__VUE_DEVTOOLS_HOOK_REPLAY__=null,buffer=[])},3e3)):buffer=[]}var currentRenderingInstance=null,currentScopeId=null;function setCurrentRenderingInstance(instance$1){let prev=currentRenderingInstance;return currentRenderingInstance=instance$1,currentScopeId=instance$1&&instance$1.type.__scopeId||null,prev}function pushScopeId(id){currentScopeId=id}function popScopeId(){currentScopeId=null}var withScopeId=_id=>withCtx;function withCtx(fn,ctx=currentRenderingInstance,isNonScopedSlot){if(!ctx||fn._n)return fn;let renderFnWithContext=(...args)=>{renderFnWithContext._d&&setBlockTracking(-1);let prevInstance=setCurrentRenderingInstance(ctx),res;try{res=fn(...args)}finally{setCurrentRenderingInstance(prevInstance),renderFnWithContext._d&&setBlockTracking(1)}return res};return renderFnWithContext._n=!0,renderFnWithContext._c=!0,renderFnWithContext._d=!0,renderFnWithContext}function withDirectives(vnode,directives){if(currentRenderingInstance===null)return vnode;let instance$1=getComponentPublicInstance(currentRenderingInstance),bindings=vnode.dirs||=[];for(let i=0;itype.__isTeleport,isTeleportDisabled=props=>props&&(props.disabled||props.disabled===``),isTeleportDeferred=props=>props&&(props.defer||props.defer===``),isTargetSVG=target=>typeof SVGElement<`u`&&target instanceof SVGElement,isTargetMathML=target=>typeof MathMLElement==`function`&&target instanceof MathMLElement,resolveTarget=(props,select)=>{let targetSelector=props&&props.to;return isString$1(targetSelector)?select?select(targetSelector):null:targetSelector},TeleportImpl={name:`Teleport`,__isTeleport:!0,process(n1,n2,container,anchor,parentComponent,parentSuspense,namespace,slotScopeIds,optimized,internals){let{mc:mountChildren,pc:patchChildren,pbc:patchBlockChildren,o:{insert,querySelector,createText,createComment}}=internals,disabled=isTeleportDisabled(n2.props),{shapeFlag,children,dynamicChildren}=n2;if(n1==null){let placeholder=n2.el=createText(``),mainAnchor=n2.anchor=createText(``);insert(placeholder,container,anchor),insert(mainAnchor,container,anchor);let mount=(container2,anchor2)=>{shapeFlag&16&&mountChildren(children,container2,anchor2,parentComponent,parentSuspense,namespace,slotScopeIds,optimized)},mountToTarget=()=>{let target=n2.target=resolveTarget(n2.props,querySelector),targetAnchor=prepareAnchor(target,n2,createText,insert);target&&(namespace!==`svg`&&isTargetSVG(target)?namespace=`svg`:namespace!==`mathml`&&isTargetMathML(target)&&(namespace=`mathml`),parentComponent&&parentComponent.isCE&&(parentComponent.ce._teleportTargets||(parentComponent.ce._teleportTargets=new Set)).add(target),disabled||(mount(target,targetAnchor),updateCssVars(n2,!1)))};disabled&&(mount(container,mainAnchor),updateCssVars(n2,!0)),isTeleportDeferred(n2.props)?(n2.el.__isMounted=!1,queuePostRenderEffect(()=>{mountToTarget(),delete n2.el.__isMounted},parentSuspense)):mountToTarget()}else{if(isTeleportDeferred(n2.props)&&n1.el.__isMounted===!1){queuePostRenderEffect(()=>{TeleportImpl.process(n1,n2,container,anchor,parentComponent,parentSuspense,namespace,slotScopeIds,optimized,internals)},parentSuspense);return}n2.el=n1.el,n2.targetStart=n1.targetStart;let mainAnchor=n2.anchor=n1.anchor,target=n2.target=n1.target,targetAnchor=n2.targetAnchor=n1.targetAnchor,wasDisabled=isTeleportDisabled(n1.props),currentContainer=wasDisabled?container:target,currentAnchor=wasDisabled?mainAnchor:targetAnchor;if(namespace===`svg`||isTargetSVG(target)?namespace=`svg`:(namespace===`mathml`||isTargetMathML(target))&&(namespace=`mathml`),dynamicChildren?(patchBlockChildren(n1.dynamicChildren,dynamicChildren,currentContainer,parentComponent,parentSuspense,namespace,slotScopeIds),traverseStaticChildren(n1,n2,!0)):optimized||patchChildren(n1,n2,currentContainer,currentAnchor,parentComponent,parentSuspense,namespace,slotScopeIds,!1),disabled)wasDisabled?n2.props&&n1.props&&n2.props.to!==n1.props.to&&(n2.props.to=n1.props.to):moveTeleport(n2,container,mainAnchor,internals,1);else if((n2.props&&n2.props.to)!==(n1.props&&n1.props.to)){let nextTarget=n2.target=resolveTarget(n2.props,querySelector);nextTarget&&moveTeleport(n2,nextTarget,null,internals,0)}else wasDisabled&&moveTeleport(n2,target,targetAnchor,internals,1);updateCssVars(n2,disabled)}},remove(vnode,parentComponent,parentSuspense,{um:unmount,o:{remove:hostRemove}},doRemove){let{shapeFlag,children,anchor,targetStart,targetAnchor,target,props}=vnode;if(target&&(hostRemove(targetStart),hostRemove(targetAnchor)),doRemove&&hostRemove(anchor),shapeFlag&16){let shouldRemove=doRemove||!isTeleportDisabled(props);for(let i=0;i{state.isMounted=!0}),onBeforeUnmount(()=>{state.isUnmounting=!0}),state}var TransitionHookValidator=[Function,Array],BaseTransitionPropsValidators={mode:String,appear:Boolean,persisted:Boolean,onBeforeEnter:TransitionHookValidator,onEnter:TransitionHookValidator,onAfterEnter:TransitionHookValidator,onEnterCancelled:TransitionHookValidator,onBeforeLeave:TransitionHookValidator,onLeave:TransitionHookValidator,onAfterLeave:TransitionHookValidator,onLeaveCancelled:TransitionHookValidator,onBeforeAppear:TransitionHookValidator,onAppear:TransitionHookValidator,onAfterAppear:TransitionHookValidator,onAppearCancelled:TransitionHookValidator},recursiveGetSubtree=instance$1=>{let subTree=instance$1.subTree;return subTree.component?recursiveGetSubtree(subTree.component):subTree},BaseTransitionImpl={name:`BaseTransition`,props:BaseTransitionPropsValidators,setup(props,{slots}){let instance$1=getCurrentInstance(),state=useTransitionState();return()=>{let children=slots.default&&getTransitionRawChildren(slots.default(),!0);if(!children||!children.length)return;let child=findNonCommentChild(children),rawProps=toRaw(props),{mode}=rawProps;if(state.isLeaving)return emptyPlaceholder(child);let innerChild=getInnerChild$1(child);if(!innerChild)return emptyPlaceholder(child);let enterHooks=resolveTransitionHooks(innerChild,rawProps,state,instance$1,hooks=>enterHooks=hooks);innerChild.type!==Comment&&setTransitionHooks(innerChild,enterHooks);let oldInnerChild=instance$1.subTree&&getInnerChild$1(instance$1.subTree);if(oldInnerChild&&oldInnerChild.type!==Comment&&!isSameVNodeType(oldInnerChild,innerChild)&&recursiveGetSubtree(instance$1).type!==Comment){let leavingHooks=resolveTransitionHooks(oldInnerChild,rawProps,state,instance$1);if(setTransitionHooks(oldInnerChild,leavingHooks),mode===`out-in`&&innerChild.type!==Comment)return state.isLeaving=!0,leavingHooks.afterLeave=()=>{state.isLeaving=!1,instance$1.job.flags&8||instance$1.update(),delete leavingHooks.afterLeave,oldInnerChild=void 0},emptyPlaceholder(child);mode===`in-out`&&innerChild.type!==Comment?leavingHooks.delayLeave=(el,earlyRemove,delayedLeave)=>{let leavingVNodesCache=getLeavingNodesForType(state,oldInnerChild);leavingVNodesCache[String(oldInnerChild.key)]=oldInnerChild,el[leaveCbKey]=()=>{earlyRemove(),el[leaveCbKey]=void 0,delete enterHooks.delayedLeave,oldInnerChild=void 0},enterHooks.delayedLeave=()=>{delayedLeave(),delete enterHooks.delayedLeave,oldInnerChild=void 0}}:oldInnerChild=void 0}else oldInnerChild&&=void 0;return child}}};function findNonCommentChild(children){let child=children[0];if(children.length>1){for(let c of children)if(c.type!==Comment){child=c;break}}return child}var BaseTransition=BaseTransitionImpl;function getLeavingNodesForType(state,vnode){let{leavingVNodes}=state,leavingVNodesCache=leavingVNodes.get(vnode.type);return leavingVNodesCache||(leavingVNodesCache=Object.create(null),leavingVNodes.set(vnode.type,leavingVNodesCache)),leavingVNodesCache}function resolveTransitionHooks(vnode,props,state,instance$1,postClone){let{appear,mode,persisted=!1,onBeforeEnter,onEnter,onAfterEnter,onEnterCancelled,onBeforeLeave,onLeave,onAfterLeave,onLeaveCancelled,onBeforeAppear,onAppear,onAfterAppear,onAppearCancelled}=props,key=String(vnode.key),leavingVNodesCache=getLeavingNodesForType(state,vnode),callHook$2=(hook,args)=>{hook&&callWithAsyncErrorHandling(hook,instance$1,9,args)},callAsyncHook=(hook,args)=>{let done=args[1];callHook$2(hook,args),isArray$2(hook)?hook.every(hook2=>hook2.length<=1)&&done():hook.length<=1&&done()},hooks={mode,persisted,beforeEnter(el){let hook=onBeforeEnter;if(!state.isMounted)if(appear)hook=onBeforeAppear||onBeforeEnter;else return;el[leaveCbKey]&&el[leaveCbKey](!0);let leavingVNode=leavingVNodesCache[key];leavingVNode&&isSameVNodeType(vnode,leavingVNode)&&leavingVNode.el[leaveCbKey]&&leavingVNode.el[leaveCbKey](),callHook$2(hook,[el])},enter(el){let hook=onEnter,afterHook=onAfterEnter,cancelHook=onEnterCancelled;if(!state.isMounted)if(appear)hook=onAppear||onEnter,afterHook=onAfterAppear||onAfterEnter,cancelHook=onAppearCancelled||onEnterCancelled;else return;let called=!1,done=el[enterCbKey$1]=cancelled=>{called||(called=!0,callHook$2(cancelled?cancelHook:afterHook,[el]),hooks.delayedLeave&&hooks.delayedLeave(),el[enterCbKey$1]=void 0)};hook?callAsyncHook(hook,[el,done]):done()},leave(el,remove$3){let key2=String(vnode.key);if(el[enterCbKey$1]&&el[enterCbKey$1](!0),state.isUnmounting)return remove$3();callHook$2(onBeforeLeave,[el]);let called=!1,done=el[leaveCbKey]=cancelled=>{called||(called=!0,remove$3(),callHook$2(cancelled?onLeaveCancelled:onAfterLeave,[el]),el[leaveCbKey]=void 0,leavingVNodesCache[key2]===vnode&&delete leavingVNodesCache[key2])};leavingVNodesCache[key2]=vnode,onLeave?callAsyncHook(onLeave,[el,done]):done()},clone(vnode2){let hooks2=resolveTransitionHooks(vnode2,props,state,instance$1,postClone);return postClone&&postClone(hooks2),hooks2}};return hooks}function emptyPlaceholder(vnode){if(isKeepAlive(vnode))return vnode=cloneVNode(vnode),vnode.children=null,vnode}function getInnerChild$1(vnode){if(!isKeepAlive(vnode))return isTeleport(vnode.type)&&vnode.children?findNonCommentChild(vnode.children):vnode;if(vnode.component)return vnode.component.subTree;let{shapeFlag,children}=vnode;if(children){if(shapeFlag&16)return children[0];if(shapeFlag&32&&isFunction$1(children.default))return children.default()}}function setTransitionHooks(vnode,hooks){vnode.shapeFlag&6&&vnode.component?(vnode.transition=hooks,setTransitionHooks(vnode.component.subTree,hooks)):vnode.shapeFlag&128?(vnode.ssContent.transition=hooks.clone(vnode.ssContent),vnode.ssFallback.transition=hooks.clone(vnode.ssFallback)):vnode.transition=hooks}function getTransitionRawChildren(children,keepComment=!1,parentKey){let ret=[],keyedFragmentCount=0;for(let i=0;i1)for(let i=0;iextend({name:options.name},extraOptions,{setup:options}))():options}function useId(){let i=getCurrentInstance();return i?(i.appContext.config.idPrefix||`v`)+`-`+i.ids[0]+ i.ids[1]++:``}function markAsyncBoundary(instance$1){instance$1.ids=[instance$1.ids[0]+ instance$1.ids[2]+++`-`,0,0]}function useTemplateRef(key){let i=getCurrentInstance(),r=shallowRef(null);if(i){let refs=i.refs===EMPTY_OBJ?i.refs={}:i.refs;Object.defineProperty(refs,key,{enumerable:!0,get:()=>r.value,set:val=>r.value=val})}return r}var pendingSetRefMap=new WeakMap;function setRef(rawRef,oldRawRef,parentSuspense,vnode,isUnmount=!1){if(isArray$2(rawRef)){rawRef.forEach((r,i)=>setRef(r,oldRawRef&&(isArray$2(oldRawRef)?oldRawRef[i]:oldRawRef),parentSuspense,vnode,isUnmount));return}if(isAsyncWrapper(vnode)&&!isUnmount){vnode.shapeFlag&512&&vnode.type.__asyncResolved&&vnode.component.subTree.component&&setRef(rawRef,oldRawRef,parentSuspense,vnode.component.subTree);return}let refValue=vnode.shapeFlag&4?getComponentPublicInstance(vnode.component):vnode.el,value=isUnmount?null:refValue,{i:owner,r:ref$1}=rawRef,oldRef=oldRawRef&&oldRawRef.r,refs=owner.refs===EMPTY_OBJ?owner.refs={}:owner.refs,setupState=owner.setupState,rawSetupState=toRaw(setupState),canSetSetupRef=setupState===EMPTY_OBJ?NO:key=>hasOwn$1(rawSetupState,key),canSetRef=ref2=>!0;if(oldRef!=null&&oldRef!==ref$1){if(invalidatePendingSetRef(oldRawRef),isString$1(oldRef))refs[oldRef]=null,canSetSetupRef(oldRef)&&(setupState[oldRef]=null);else if(isRef(oldRef)){canSetRef(oldRef)&&(oldRef.value=null);let oldRawRefAtom=oldRawRef;oldRawRefAtom.k&&(refs[oldRawRefAtom.k]=null)}}if(isFunction$1(ref$1))callWithErrorHandling(ref$1,owner,12,[value,refs]);else{let _isString=isString$1(ref$1),_isRef=isRef(ref$1);if(_isString||_isRef){let doSet=()=>{if(rawRef.f){let existing=_isString?canSetSetupRef(ref$1)?setupState[ref$1]:refs[ref$1]:canSetRef(ref$1)||!rawRef.k?ref$1.value:refs[rawRef.k];if(isUnmount)isArray$2(existing)&&remove$2(existing,refValue);else if(isArray$2(existing))existing.includes(refValue)||existing.push(refValue);else if(_isString)refs[ref$1]=[refValue],canSetSetupRef(ref$1)&&(setupState[ref$1]=refs[ref$1]);else{let newVal=[refValue];canSetRef(ref$1)&&(ref$1.value=newVal),rawRef.k&&(refs[rawRef.k]=newVal)}}else _isString?(refs[ref$1]=value,canSetSetupRef(ref$1)&&(setupState[ref$1]=value)):_isRef&&(canSetRef(ref$1)&&(ref$1.value=value),rawRef.k&&(refs[rawRef.k]=value))};if(value){let job=()=>{doSet(),pendingSetRefMap.delete(rawRef)};job.id=-1,pendingSetRefMap.set(rawRef,job),queuePostRenderEffect(job,parentSuspense)}else invalidatePendingSetRef(rawRef),doSet()}}}function invalidatePendingSetRef(rawRef){let pendingSetRef=pendingSetRefMap.get(rawRef);pendingSetRef&&(pendingSetRef.flags|=8,pendingSetRefMap.delete(rawRef))}var hasLoggedMismatchError=!1,logMismatchError=()=>{hasLoggedMismatchError||=(console.error(`Hydration completed but contains mismatches.`),!0)},isSVGContainer=container=>container.namespaceURI.includes(`svg`)&&container.tagName!==`foreignObject`,isMathMLContainer=container=>container.namespaceURI.includes(`MathML`),getContainerType=container=>{if(container.nodeType===1){if(isSVGContainer(container))return`svg`;if(isMathMLContainer(container))return`mathml`}},isComment=node=>node.nodeType===8;function createHydrationFunctions(rendererInternals){let{mt:mountComponent,p:patch,o:{patchProp:patchProp$1,createText,nextSibling,parentNode,remove:remove$3,insert,createComment}}=rendererInternals,hydrate$1=(vnode,container)=>{if(!container.hasChildNodes()){patch(null,vnode,container),flushPostFlushCbs(),container._vnode=vnode;return}hydrateNode(container.firstChild,vnode,null,null,null),flushPostFlushCbs(),container._vnode=vnode},hydrateNode=(node,vnode,parentComponent,parentSuspense,slotScopeIds,optimized=!1)=>{optimized||=!!vnode.dynamicChildren;let isFragmentStart=isComment(node)&&node.data===`[`,onMismatch=()=>handleMismatch(node,vnode,parentComponent,parentSuspense,slotScopeIds,isFragmentStart),{type,ref:ref$1,shapeFlag,patchFlag}=vnode,domType=node.nodeType;vnode.el=node,patchFlag===-2&&(optimized=!1,vnode.dynamicChildren=null);let nextNode=null;switch(type){case Text:domType===3?(node.data!==vnode.children&&(logMismatchError(),node.data=vnode.children),nextNode=nextSibling(node)):vnode.children===``?(insert(vnode.el=createText(``),parentNode(node),node),nextNode=node):nextNode=onMismatch();break;case Comment:isTemplateNode$1(node)?(nextNode=nextSibling(node),replaceNode(vnode.el=node.content.firstChild,node,parentComponent)):nextNode=domType!==8||isFragmentStart?onMismatch():nextSibling(node);break;case Static:if(isFragmentStart&&(node=nextSibling(node),domType=node.nodeType),domType===1||domType===3){nextNode=node;let needToAdoptContent=!vnode.children.length;for(let i=0;i{optimized||=!!vnode.dynamicChildren;let{type,props,patchFlag,shapeFlag,dirs,transition}=vnode,forcePatch=type===`input`||type===`option`;if(forcePatch||patchFlag!==-1){dirs&&invokeDirectiveHook(vnode,null,parentComponent,`created`);let needCallTransitionHooks=!1;if(isTemplateNode$1(el)){needCallTransitionHooks=needTransition(null,transition)&&parentComponent&&parentComponent.vnode.props&&parentComponent.vnode.props.appear;let content=el.content.firstChild;if(needCallTransitionHooks){let cls=content.getAttribute(`class`);cls&&(content.$cls=cls),transition.beforeEnter(content)}replaceNode(content,el,parentComponent),vnode.el=el=content}if(shapeFlag&16&&!(props&&(props.innerHTML||props.textContent))){let next=hydrateChildren(el.firstChild,vnode,el,parentComponent,parentSuspense,slotScopeIds,optimized);for(;next;){isMismatchAllowed(el,1)||logMismatchError();let cur=next;next=next.nextSibling,remove$3(cur)}}else if(shapeFlag&8){let clientText=vnode.children;clientText[0]===`
`&&(el.tagName===`PRE`||el.tagName===`TEXTAREA`)&&(clientText=clientText.slice(1)),el.textContent!==clientText&&(isMismatchAllowed(el,0)||logMismatchError(),el.textContent=vnode.children)}if(props){if(forcePatch||!optimized||patchFlag&48){let isCustomElement=el.tagName.includes(`-`);for(let key in props)(forcePatch&&(key.endsWith(`value`)||key===`indeterminate`)||isOn(key)&&!isReservedProp(key)||key[0]===`.`||isCustomElement)&&patchProp$1(el,key,null,props[key],void 0,parentComponent)}else if(props.onClick)patchProp$1(el,`onClick`,null,props.onClick,void 0,parentComponent);else if(patchFlag&4&&isReactive(props.style))for(let key in props.style)props.style[key]}let vnodeHooks;(vnodeHooks=props&&props.onVnodeBeforeMount)&&invokeVNodeHook(vnodeHooks,parentComponent,vnode),dirs&&invokeDirectiveHook(vnode,null,parentComponent,`beforeMount`),((vnodeHooks=props&&props.onVnodeMounted)||dirs||needCallTransitionHooks)&&queueEffectWithSuspense(()=>{vnodeHooks&&invokeVNodeHook(vnodeHooks,parentComponent,vnode),needCallTransitionHooks&&transition.enter(el),dirs&&invokeDirectiveHook(vnode,null,parentComponent,`mounted`)},parentSuspense)}return el.nextSibling},hydrateChildren=(node,parentVNode,container,parentComponent,parentSuspense,slotScopeIds,optimized)=>{optimized||=!!parentVNode.dynamicChildren;let children=parentVNode.children,l=children.length;for(let i=0;i{let{slotScopeIds:fragmentSlotScopeIds}=vnode;fragmentSlotScopeIds&&(slotScopeIds=slotScopeIds?slotScopeIds.concat(fragmentSlotScopeIds):fragmentSlotScopeIds);let container=parentNode(node),next=hydrateChildren(nextSibling(node),vnode,container,parentComponent,parentSuspense,slotScopeIds,optimized);return next&&isComment(next)&&next.data===`]`?nextSibling(vnode.anchor=next):(logMismatchError(),insert(vnode.anchor=createComment(`]`),container,next),next)},handleMismatch=(node,vnode,parentComponent,parentSuspense,slotScopeIds,isFragment)=>{if(isMismatchAllowed(node.parentElement,1)||logMismatchError(),vnode.el=null,isFragment){let end=locateClosingAnchor(node);for(;;){let next2=nextSibling(node);if(next2&&next2!==end)remove$3(next2);else break}}let next=nextSibling(node),container=parentNode(node);return remove$3(node),patch(null,vnode,container,next,parentComponent,parentSuspense,getContainerType(container),slotScopeIds),parentComponent&&(parentComponent.vnode.el=vnode.el,updateHOCHostEl(parentComponent,vnode.el)),next},locateClosingAnchor=(node,open$1=`[`,close=`]`)=>{let match=0;for(;node;)if(node=nextSibling(node),node&&isComment(node)&&(node.data===open$1&&match++,node.data===close)){if(match===0)return nextSibling(node);match--}return node},replaceNode=(newNode,oldNode,parentComponent)=>{let parentNode2=oldNode.parentNode;parentNode2&&parentNode2.replaceChild(newNode,oldNode);let parent=parentComponent;for(;parent;)parent.vnode.el===oldNode&&(parent.vnode.el=parent.subTree.el=newNode),parent=parent.parent},isTemplateNode$1=node=>node.nodeType===1&&node.tagName===`TEMPLATE`;return[hydrate$1,hydrateNode]}var allowMismatchAttr=`data-allow-mismatch`,MismatchTypeString={0:`text`,1:`children`,2:`class`,3:`style`,4:`attribute`};function isMismatchAllowed(el,allowedType){if(allowedType===0||allowedType===1)for(;el&&!el.hasAttribute(allowMismatchAttr);)el=el.parentElement;let allowedAttr=el&&el.getAttribute(allowMismatchAttr);if(allowedAttr==null)return!1;if(allowedAttr===``)return!0;{let list=allowedAttr.split(`,`);return allowedType===0&&list.includes(`children`)?!0:list.includes(MismatchTypeString[allowedType])}}var requestIdleCallback=getGlobalThis$1().requestIdleCallback||(cb=>setTimeout(cb,1)),cancelIdleCallback=getGlobalThis$1().cancelIdleCallback||(id=>clearTimeout(id)),hydrateOnIdle=(timeout=1e4)=>hydrate$1=>{let id=requestIdleCallback(hydrate$1,{timeout});return()=>cancelIdleCallback(id)};function elementIsVisibleInViewport(el){let{top,left,bottom,right}=el.getBoundingClientRect(),{innerHeight,innerWidth}=window;return(top>0&&top0&&bottom0&&left0&&right(hydrate$1,forEach)=>{let ob=new IntersectionObserver(entries=>{for(let e of entries)if(e.isIntersecting){ob.disconnect(),hydrate$1();break}},opts);return forEach(el=>{if(el instanceof Element){if(elementIsVisibleInViewport(el))return hydrate$1(),ob.disconnect(),!1;ob.observe(el)}}),()=>ob.disconnect()},hydrateOnMediaQuery=query=>hydrate$1=>{if(query){let mql=matchMedia(query);if(mql.matches)hydrate$1();else return mql.addEventListener(`change`,hydrate$1,{once:!0}),()=>mql.removeEventListener(`change`,hydrate$1)}},hydrateOnInteraction=(interactions=[])=>(hydrate$1,forEach)=>{isString$1(interactions)&&(interactions=[interactions]);let hasHydrated=!1,doHydrate=e=>{hasHydrated||(hasHydrated=!0,teardown(),hydrate$1(),e.target.dispatchEvent(new e.constructor(e.type,e)))},teardown=()=>{forEach(el=>{for(let i of interactions)el.removeEventListener(i,doHydrate)})};return forEach(el=>{for(let i of interactions)el.addEventListener(i,doHydrate,{once:!0})}),teardown};function forEachElement(node,cb){if(isComment(node)&&node.data===`[`){let depth=1,next=node.nextSibling;for(;next;){if(next.nodeType===1){if(cb(next)===!1)break}else if(isComment(next))if(next.data===`]`){if(--depth===0)break}else next.data===`[`&&depth++;next=next.nextSibling}}else cb(node)}var isAsyncWrapper=i=>!!i.type.__asyncLoader;function defineAsyncComponent(source){isFunction$1(source)&&(source={loader:source});let{loader,loadingComponent,errorComponent,delay=200,hydrate:hydrateStrategy,timeout,suspensible=!0,onError:userOnError}=source,pendingRequest=null,resolvedComp,retries=0,retry=()=>(retries++,pendingRequest=null,load()),load=()=>{let thisRequest;return pendingRequest||(thisRequest=pendingRequest=loader().catch(err=>{if(err=err instanceof Error?err:Error(String(err)),userOnError)return new Promise((resolve$1,reject)=>{userOnError(err,()=>resolve$1(retry()),()=>reject(err),retries+1)});throw err}).then(comp=>thisRequest!==pendingRequest&&pendingRequest?pendingRequest:(comp&&(comp.__esModule||comp[Symbol.toStringTag]===`Module`)&&(comp=comp.default),resolvedComp=comp,comp)))};return defineComponent({name:`AsyncComponentWrapper`,__asyncLoader:load,__asyncHydrate(el,instance$1,hydrate$1){let patched=!1;(instance$1.bu||=[]).push(()=>patched=!0);let performHydrate=()=>{patched||hydrate$1()},doHydrate=hydrateStrategy?()=>{let teardown=hydrateStrategy(performHydrate,cb=>forEachElement(el,cb));teardown&&(instance$1.bum||=[]).push(teardown)}:performHydrate;resolvedComp?doHydrate():load().then(()=>!instance$1.isUnmounted&&doHydrate())},get __asyncResolved(){return resolvedComp},setup(){let instance$1=currentInstance;if(markAsyncBoundary(instance$1),resolvedComp)return()=>createInnerComp(resolvedComp,instance$1);let onError=err=>{pendingRequest=null,handleError(err,instance$1,13,!errorComponent)};if(suspensible&&instance$1.suspense||isInSSRComponentSetup)return load().then(comp=>()=>createInnerComp(comp,instance$1)).catch(err=>(onError(err),()=>errorComponent?createVNode(errorComponent,{error:err}):null));let loaded=ref(!1),error=ref(),delayed=ref(!!delay);return delay&&setTimeout(()=>{delayed.value=!1},delay),timeout!=null&&setTimeout(()=>{if(!loaded.value&&!error.value){let err=Error(`Async component timed out after ${timeout}ms.`);onError(err),error.value=err}},timeout),load().then(()=>{loaded.value=!0,instance$1.parent&&isKeepAlive(instance$1.parent.vnode)&&instance$1.parent.update()}).catch(err=>{onError(err),error.value=err}),()=>{if(loaded.value&&resolvedComp)return createInnerComp(resolvedComp,instance$1);if(error.value&&errorComponent)return createVNode(errorComponent,{error:error.value});if(loadingComponent&&!delayed.value)return createVNode(loadingComponent)}}})}function createInnerComp(comp,parent){let{ref:ref2,props,children,ce}=parent.vnode,vnode=createVNode(comp,props,children);return vnode.ref=ref2,vnode.ce=ce,delete parent.vnode.ce,vnode}var isKeepAlive=vnode=>vnode.type.__isKeepAlive,KeepAlive={name:`KeepAlive`,__isKeepAlive:!0,props:{include:[String,RegExp,Array],exclude:[String,RegExp,Array],max:[String,Number]},setup(props,{slots}){let instance$1=getCurrentInstance(),sharedContext$1=instance$1.ctx;if(!sharedContext$1.renderer)return()=>{let children=slots.default&&slots.default();return children&&children.length===1?children[0]:children};let cache$1=new Map,keys=new Set,current=null,parentSuspense=instance$1.suspense,{renderer:{p:patch,m:move,um:_unmount,o:{createElement}}}=sharedContext$1,storageContainer=createElement(`div`);sharedContext$1.activate=(vnode,container,anchor,namespace,optimized)=>{let instance2=vnode.component;move(vnode,container,anchor,0,parentSuspense),patch(instance2.vnode,vnode,container,anchor,instance2,parentSuspense,namespace,vnode.slotScopeIds,optimized),queuePostRenderEffect(()=>{instance2.isDeactivated=!1,instance2.a&&invokeArrayFns(instance2.a);let vnodeHook=vnode.props&&vnode.props.onVnodeMounted;vnodeHook&&invokeVNodeHook(vnodeHook,instance2.parent,vnode)},parentSuspense)},sharedContext$1.deactivate=vnode=>{let instance2=vnode.component;invalidateMount(instance2.m),invalidateMount(instance2.a),move(vnode,storageContainer,null,1,parentSuspense),queuePostRenderEffect(()=>{instance2.da&&invokeArrayFns(instance2.da);let vnodeHook=vnode.props&&vnode.props.onVnodeUnmounted;vnodeHook&&invokeVNodeHook(vnodeHook,instance2.parent,vnode),instance2.isDeactivated=!0},parentSuspense)};function unmount(vnode){resetShapeFlag(vnode),_unmount(vnode,instance$1,parentSuspense,!0)}function pruneCache(filter){cache$1.forEach((vnode,key)=>{let name=getComponentName(vnode.type);name&&!filter(name)&&pruneCacheEntry(key)})}function pruneCacheEntry(key){let cached=cache$1.get(key);cached&&(!current||!isSameVNodeType(cached,current))?unmount(cached):current&&resetShapeFlag(current),cache$1.delete(key),keys.delete(key)}watch(()=>[props.include,props.exclude],([include,exclude])=>{include&&pruneCache(name=>matches(include,name)),exclude&&pruneCache(name=>!matches(exclude,name))},{flush:`post`,deep:!0});let pendingCacheKey=null,cacheSubtree=()=>{pendingCacheKey!=null&&(isSuspense(instance$1.subTree.type)?queuePostRenderEffect(()=>{cache$1.set(pendingCacheKey,getInnerChild(instance$1.subTree))},instance$1.subTree.suspense):cache$1.set(pendingCacheKey,getInnerChild(instance$1.subTree)))};return onMounted(cacheSubtree),onUpdated(cacheSubtree),onBeforeUnmount(()=>{cache$1.forEach(cached=>{let{subTree,suspense}=instance$1,vnode=getInnerChild(subTree);if(cached.type===vnode.type&&cached.key===vnode.key){resetShapeFlag(vnode);let da=vnode.component.da;da&&queuePostRenderEffect(da,suspense);return}unmount(cached)})}),()=>{if(pendingCacheKey=null,!slots.default)return current=null;let children=slots.default(),rawVNode=children[0];if(children.length>1)return current=null,children;if(!isVNode(rawVNode)||!(rawVNode.shapeFlag&4)&&!(rawVNode.shapeFlag&128))return current=null,rawVNode;let vnode=getInnerChild(rawVNode);if(vnode.type===Comment)return current=null,vnode;let comp=vnode.type,name=getComponentName(isAsyncWrapper(vnode)?vnode.type.__asyncResolved||{}:comp),{include,exclude,max:max$1}=props;if(include&&(!name||!matches(include,name))||exclude&&name&&matches(exclude,name))return vnode.shapeFlag&=-257,current=vnode,rawVNode;let key=vnode.key==null?comp:vnode.key,cachedVNode=cache$1.get(key);return vnode.el&&(vnode=cloneVNode(vnode),rawVNode.shapeFlag&128&&(rawVNode.ssContent=vnode)),pendingCacheKey=key,cachedVNode?(vnode.el=cachedVNode.el,vnode.component=cachedVNode.component,vnode.transition&&setTransitionHooks(vnode,vnode.transition),vnode.shapeFlag|=512,keys.delete(key),keys.add(key)):(keys.add(key),max$1&&keys.size>parseInt(max$1,10)&&pruneCacheEntry(keys.values().next().value)),vnode.shapeFlag|=256,current=vnode,isSuspense(rawVNode.type)?rawVNode:vnode}}};function matches(pattern,name){return isArray$2(pattern)?pattern.some(p$1=>matches(p$1,name)):isString$1(pattern)?pattern.split(`,`).includes(name):isRegExp$1(pattern)?(pattern.lastIndex=0,pattern.test(name)):!1}function onActivated(hook,target){registerKeepAliveHook(hook,`a`,target)}function onDeactivated(hook,target){registerKeepAliveHook(hook,`da`,target)}function registerKeepAliveHook(hook,type,target=currentInstance){let wrappedHook=hook.__wdc||=()=>{let current=target;for(;current;){if(current.isDeactivated)return;current=current.parent}return hook()};if(injectHook(type,wrappedHook,target),target){let current=target.parent;for(;current&¤t.parent;)isKeepAlive(current.parent.vnode)&&injectToKeepAliveRoot(wrappedHook,type,target,current),current=current.parent}}function injectToKeepAliveRoot(hook,type,target,keepAliveRoot){let injected=injectHook(type,hook,keepAliveRoot,!0);onUnmounted(()=>{remove$2(keepAliveRoot[type],injected)},target)}function resetShapeFlag(vnode){vnode.shapeFlag&=-257,vnode.shapeFlag&=-513}function getInnerChild(vnode){return vnode.shapeFlag&128?vnode.ssContent:vnode}function injectHook(type,hook,target=currentInstance,prepend=!1){if(target){let hooks=target[type]||(target[type]=[]),wrappedHook=hook.__weh||=(...args)=>{pauseTracking();let reset$1=setCurrentInstance(target),res=callWithAsyncErrorHandling(hook,target,type,args);return reset$1(),resetTracking(),res};return prepend?hooks.unshift(wrappedHook):hooks.push(wrappedHook),wrappedHook}}var createHook=lifecycle=>(hook,target=currentInstance)=>{(!isInSSRComponentSetup||lifecycle===`sp`)&&injectHook(lifecycle,(...args)=>hook(...args),target)},onBeforeMount=createHook(`bm`),onMounted=createHook(`m`),onBeforeUpdate=createHook(`bu`),onUpdated=createHook(`u`),onBeforeUnmount=createHook(`bum`),onUnmounted=createHook(`um`),onServerPrefetch=createHook(`sp`),onRenderTriggered=createHook(`rtg`),onRenderTracked=createHook(`rtc`);function onErrorCaptured(hook,target=currentInstance){injectHook(`ec`,hook,target)}var COMPONENTS=`components`,DIRECTIVES=`directives`;function resolveComponent(name,maybeSelfReference){return resolveAsset(COMPONENTS,name,!0,maybeSelfReference)||name}var NULL_DYNAMIC_COMPONENT=Symbol.for(`v-ndc`);function resolveDynamicComponent(component){return isString$1(component)?resolveAsset(COMPONENTS,component,!1)||component:component||NULL_DYNAMIC_COMPONENT}function resolveDirective(name){return resolveAsset(DIRECTIVES,name)}function resolveAsset(type,name,warnMissing=!0,maybeSelfReference=!1){let instance$1=currentRenderingInstance||currentInstance;if(instance$1){let Component=instance$1.type;if(type===COMPONENTS){let selfName=getComponentName(Component,!1);if(selfName&&(selfName===name||selfName===camelize(name)||selfName===capitalize$1(camelize(name))))return Component}let res=resolve(instance$1[type]||Component[type],name)||resolve(instance$1.appContext[type],name);return!res&&maybeSelfReference?Component:res}}function resolve(registry$1,name){return registry$1&&(registry$1[name]||registry$1[camelize(name)]||registry$1[capitalize$1(camelize(name))])}function renderList(source,renderItem,cache$1,index){let ret,cached=cache$1&&cache$1[index],sourceIsArray=isArray$2(source);if(sourceIsArray||isString$1(source)){let sourceIsReactiveArray=sourceIsArray&&isReactive(source),needsWrap=!1,isReadonlySource=!1;sourceIsReactiveArray&&(needsWrap=!isShallow(source),isReadonlySource=isReadonly(source),source=shallowReadArray(source)),ret=Array(source.length);for(let i=0,l=source.length;irenderItem(item,i,void 0,cached&&cached[i]));else{let keys=Object.keys(source);ret=Array(keys.length);for(let i=0,l=keys.length;i{let res=slot.fn(...args);return res&&(res.key=slot.key),res}:slot.fn)}return slots}function renderSlot(slots,name,props={},fallback,noSlotted){if(currentRenderingInstance.ce||currentRenderingInstance.parent&&isAsyncWrapper(currentRenderingInstance.parent)&¤tRenderingInstance.parent.ce){let hasProps=Object.keys(props).length>0;return name!==`default`&&(props.name=name),openBlock(),createBlock(Fragment,null,[createVNode(`slot`,props,fallback&&fallback())],hasProps?-2:64)}let slot=slots[name];slot&&slot._c&&(slot._d=!1),openBlock();let validSlotContent=slot&&ensureValidVNode(slot(props)),slotKey=props.key||validSlotContent&&validSlotContent.key,rendered=createBlock(Fragment,{key:(slotKey&&!isSymbol(slotKey)?slotKey:`_${name}`)+(!validSlotContent&&fallback?`_fb`:``)},validSlotContent||(fallback?fallback():[]),validSlotContent&&slots._===1?64:-2);return!noSlotted&&rendered.scopeId&&(rendered.slotScopeIds=[rendered.scopeId+`-s`]),slot&&slot._c&&(slot._d=!0),rendered}function ensureValidVNode(vnodes){return vnodes.some(child=>isVNode(child)?!(child.type===Comment||child.type===Fragment&&!ensureValidVNode(child.children)):!0)?vnodes:null}function toHandlers(obj,preserveCaseIfNecessary){let ret={};for(let key in obj)ret[preserveCaseIfNecessary&&/[A-Z]/.test(key)?`on:${key}`:toHandlerKey(key)]=obj[key];return ret}var getPublicInstance=i=>i?isStatefulComponent(i)?getComponentPublicInstance(i):getPublicInstance(i.parent):null,publicPropertiesMap=extend(Object.create(null),{$:i=>i,$el:i=>i.vnode.el,$data:i=>i.data,$props:i=>i.props,$attrs:i=>i.attrs,$slots:i=>i.slots,$refs:i=>i.refs,$parent:i=>getPublicInstance(i.parent),$root:i=>getPublicInstance(i.root),$host:i=>i.ce,$emit:i=>i.emit,$options:i=>resolveMergedOptions(i),$forceUpdate:i=>i.f||=()=>{queueJob(i.update)},$nextTick:i=>i.n||=nextTick.bind(i.proxy),$watch:i=>instanceWatch.bind(i)}),hasSetupBinding=(state,key)=>state!==EMPTY_OBJ&&!state.__isScriptSetup&&hasOwn$1(state,key),PublicInstanceProxyHandlers={get({_:instance$1},key){if(key===`__v_skip`)return!0;let{ctx,setupState,data,props,accessCache,type,appContext}=instance$1,normalizedProps;if(key[0]!==`$`){let n=accessCache[key];if(n!==void 0)switch(n){case 1:return setupState[key];case 2:return data[key];case 4:return ctx[key];case 3:return props[key]}else if(hasSetupBinding(setupState,key))return accessCache[key]=1,setupState[key];else if(data!==EMPTY_OBJ&&hasOwn$1(data,key))return accessCache[key]=2,data[key];else if((normalizedProps=instance$1.propsOptions[0])&&hasOwn$1(normalizedProps,key))return accessCache[key]=3,props[key];else if(ctx!==EMPTY_OBJ&&hasOwn$1(ctx,key))return accessCache[key]=4,ctx[key];else shouldCacheAccess&&(accessCache[key]=0)}let publicGetter=publicPropertiesMap[key],cssModule,globalProperties;if(publicGetter)return key===`$attrs`&&track(instance$1.attrs,`get`,``),publicGetter(instance$1);if((cssModule=type.__cssModules)&&(cssModule=cssModule[key]))return cssModule;if(ctx!==EMPTY_OBJ&&hasOwn$1(ctx,key))return accessCache[key]=4,ctx[key];if(globalProperties=appContext.config.globalProperties,hasOwn$1(globalProperties,key))return globalProperties[key]},set({_:instance$1},key,value){let{data,setupState,ctx}=instance$1;return hasSetupBinding(setupState,key)?(setupState[key]=value,!0):data!==EMPTY_OBJ&&hasOwn$1(data,key)?(data[key]=value,!0):hasOwn$1(instance$1.props,key)||key[0]===`$`&&key.slice(1)in instance$1?!1:(ctx[key]=value,!0)},has({_:{data,setupState,accessCache,ctx,appContext,propsOptions,type}},key){let normalizedProps,cssModules;return!!(accessCache[key]||data!==EMPTY_OBJ&&key[0]!==`$`&&hasOwn$1(data,key)||hasSetupBinding(setupState,key)||(normalizedProps=propsOptions[0])&&hasOwn$1(normalizedProps,key)||hasOwn$1(ctx,key)||hasOwn$1(publicPropertiesMap,key)||hasOwn$1(appContext.config.globalProperties,key)||(cssModules=type.__cssModules)&&cssModules[key])},defineProperty(target,key,descriptor){return descriptor.get==null?hasOwn$1(descriptor,`value`)&&this.set(target,key,descriptor.value,null):target._.accessCache[key]=0,Reflect.defineProperty(target,key,descriptor)}},RuntimeCompiledPublicInstanceProxyHandlers=extend({},PublicInstanceProxyHandlers,{get(target,key){if(key!==Symbol.unscopables)return PublicInstanceProxyHandlers.get(target,key,target)},has(_,key){return key[0]!==`_`&&!isGloballyAllowed(key)}});function defineProps(){return null}function defineEmits(){return null}function defineExpose(exposed){}function defineOptions(options){}function defineSlots(){return null}function defineModel(){}function withDefaults(props,defaults){return null}function useSlots(){return getContext(`useSlots`).slots}function useAttrs(){return getContext(`useAttrs`).attrs}function getContext(calledFunctionName){let i=getCurrentInstance();return i.setupContext||=createSetupContext(i)}function normalizePropsOrEmits(props){return isArray$2(props)?props.reduce((normalized,p$1)=>(normalized[p$1]=null,normalized),{}):props}function mergeDefaults(raw,defaults){let props=normalizePropsOrEmits(raw);for(let key in defaults){if(key.startsWith(`__skip`))continue;let opt=props[key];opt?isArray$2(opt)||isFunction$1(opt)?opt=props[key]={type:opt,default:defaults[key]}:opt.default=defaults[key]:opt===null&&(opt=props[key]={default:defaults[key]}),opt&&defaults[`__skip_${key}`]&&(opt.skipFactory=!0)}return props}function mergeModels(a$1,b){return!a$1||!b?a$1||b:isArray$2(a$1)&&isArray$2(b)?a$1.concat(b):extend({},normalizePropsOrEmits(a$1),normalizePropsOrEmits(b))}function createPropsRestProxy(props,excludedKeys){let ret={};for(let key in props)excludedKeys.includes(key)||Object.defineProperty(ret,key,{enumerable:!0,get:()=>props[key]});return ret}function withAsyncContext(getAwaitable){let ctx=getCurrentInstance(),awaitable=getAwaitable();return unsetCurrentInstance(),isPromise$1(awaitable)&&(awaitable=awaitable.catch(e=>{throw setCurrentInstance(ctx),e})),[awaitable,()=>setCurrentInstance(ctx)]}var shouldCacheAccess=!0;function applyOptions$1(instance$1){let options=resolveMergedOptions(instance$1),publicThis=instance$1.proxy,ctx=instance$1.ctx;shouldCacheAccess=!1,options.beforeCreate&&callHook$1(options.beforeCreate,instance$1,`bc`);let{data:dataOptions,computed:computedOptions,methods,watch:watchOptions,provide:provideOptions,inject:injectOptions,created,beforeMount:beforeMount$1,mounted:mounted$2,beforeUpdate,updated:updated$2,activated,deactivated,beforeDestroy,beforeUnmount:beforeUnmount$1,destroyed,unmounted:unmounted$1,render:render$1,renderTracked,renderTriggered,errorCaptured,serverPrefetch,expose,inheritAttrs,components,directives,filters}=options,checkDuplicateProperties=null;if(injectOptions&&resolveInjections(injectOptions,ctx,null),methods)for(let key in methods){let methodHandler=methods[key];isFunction$1(methodHandler)&&(ctx[key]=methodHandler.bind(publicThis))}if(dataOptions){let data=dataOptions.call(publicThis,publicThis);isObject$1(data)&&(instance$1.data=reactive(data))}if(shouldCacheAccess=!0,computedOptions)for(let key in computedOptions){let opt=computedOptions[key],c=computed({get:isFunction$1(opt)?opt.bind(publicThis,publicThis):isFunction$1(opt.get)?opt.get.bind(publicThis,publicThis):NOOP,set:!isFunction$1(opt)&&isFunction$1(opt.set)?opt.set.bind(publicThis):NOOP});Object.defineProperty(ctx,key,{enumerable:!0,configurable:!0,get:()=>c.value,set:v=>c.value=v})}if(watchOptions)for(let key in watchOptions)createWatcher(watchOptions[key],ctx,publicThis,key);if(provideOptions){let provides=isFunction$1(provideOptions)?provideOptions.call(publicThis):provideOptions;Reflect.ownKeys(provides).forEach(key=>{provide(key,provides[key])})}created&&callHook$1(created,instance$1,`c`);function registerLifecycleHook(register,hook){isArray$2(hook)?hook.forEach(_hook=>register(_hook.bind(publicThis))):hook&®ister(hook.bind(publicThis))}if(registerLifecycleHook(onBeforeMount,beforeMount$1),registerLifecycleHook(onMounted,mounted$2),registerLifecycleHook(onBeforeUpdate,beforeUpdate),registerLifecycleHook(onUpdated,updated$2),registerLifecycleHook(onActivated,activated),registerLifecycleHook(onDeactivated,deactivated),registerLifecycleHook(onErrorCaptured,errorCaptured),registerLifecycleHook(onRenderTracked,renderTracked),registerLifecycleHook(onRenderTriggered,renderTriggered),registerLifecycleHook(onBeforeUnmount,beforeUnmount$1),registerLifecycleHook(onUnmounted,unmounted$1),registerLifecycleHook(onServerPrefetch,serverPrefetch),isArray$2(expose))if(expose.length){let exposed=instance$1.exposed||={};expose.forEach(key=>{Object.defineProperty(exposed,key,{get:()=>publicThis[key],set:val=>publicThis[key]=val,enumerable:!0})})}else instance$1.exposed||={};render$1&&instance$1.render===NOOP&&(instance$1.render=render$1),inheritAttrs!=null&&(instance$1.inheritAttrs=inheritAttrs),components&&(instance$1.components=components),directives&&(instance$1.directives=directives),serverPrefetch&&markAsyncBoundary(instance$1)}function resolveInjections(injectOptions,ctx,checkDuplicateProperties=NOOP){for(let key in isArray$2(injectOptions)&&(injectOptions=normalizeInject(injectOptions)),injectOptions){let opt=injectOptions[key],injected;injected=isObject$1(opt)?`default`in opt?inject(opt.from||key,opt.default,!0):inject(opt.from||key):inject(opt),isRef(injected)?Object.defineProperty(ctx,key,{enumerable:!0,configurable:!0,get:()=>injected.value,set:v=>injected.value=v}):ctx[key]=injected}}function callHook$1(hook,instance$1,type){callWithAsyncErrorHandling(isArray$2(hook)?hook.map(h$1=>h$1.bind(instance$1.proxy)):hook.bind(instance$1.proxy),instance$1,type)}function createWatcher(raw,ctx,publicThis,key){let getter=key.includes(`.`)?createPathGetter(publicThis,key):()=>publicThis[key];if(isString$1(raw)){let handler$1=ctx[raw];isFunction$1(handler$1)&&watch(getter,handler$1)}else if(isFunction$1(raw))watch(getter,raw.bind(publicThis));else if(isObject$1(raw))if(isArray$2(raw))raw.forEach(r=>createWatcher(r,ctx,publicThis,key));else{let handler$1=isFunction$1(raw.handler)?raw.handler.bind(publicThis):ctx[raw.handler];isFunction$1(handler$1)&&watch(getter,handler$1,raw)}}function resolveMergedOptions(instance$1){let base=instance$1.type,{mixins,extends:extendsOptions}=base,{mixins:globalMixins,optionsCache:cache$1,config:{optionMergeStrategies}}=instance$1.appContext,cached=cache$1.get(base),resolved;return cached?resolved=cached:!globalMixins.length&&!mixins&&!extendsOptions?resolved=base:(resolved={},globalMixins.length&&globalMixins.forEach(m=>mergeOptions$1(resolved,m,optionMergeStrategies,!0)),mergeOptions$1(resolved,base,optionMergeStrategies)),isObject$1(base)&&cache$1.set(base,resolved),resolved}function mergeOptions$1(to,from,strats,asMixin=!1){let{mixins,extends:extendsOptions}=from;for(let key in extendsOptions&&mergeOptions$1(to,extendsOptions,strats,!0),mixins&&mixins.forEach(m=>mergeOptions$1(to,m,strats,!0)),from)if(!(asMixin&&key===`expose`)){let strat=internalOptionMergeStrats[key]||strats&&strats[key];to[key]=strat?strat(to[key],from[key]):from[key]}return to}var internalOptionMergeStrats={data:mergeDataFn,props:mergeEmitsOrPropsOptions,emits:mergeEmitsOrPropsOptions,methods:mergeObjectOptions,computed:mergeObjectOptions,beforeCreate:mergeAsArray$1,created:mergeAsArray$1,beforeMount:mergeAsArray$1,mounted:mergeAsArray$1,beforeUpdate:mergeAsArray$1,updated:mergeAsArray$1,beforeDestroy:mergeAsArray$1,beforeUnmount:mergeAsArray$1,destroyed:mergeAsArray$1,unmounted:mergeAsArray$1,activated:mergeAsArray$1,deactivated:mergeAsArray$1,errorCaptured:mergeAsArray$1,serverPrefetch:mergeAsArray$1,components:mergeObjectOptions,directives:mergeObjectOptions,watch:mergeWatchOptions,provide:mergeDataFn,inject:mergeInject};function mergeDataFn(to,from){return from?to?function(){return extend(isFunction$1(to)?to.call(this,this):to,isFunction$1(from)?from.call(this,this):from)}:from:to}function mergeInject(to,from){return mergeObjectOptions(normalizeInject(to),normalizeInject(from))}function normalizeInject(raw){if(isArray$2(raw)){let res={};for(let i=0;i1)return treatDefaultAsFactory&&isFunction$1(defaultValue)?defaultValue.call(instance$1&&instance$1.proxy):defaultValue}}function hasInjectionContext(){return!!(getCurrentInstance()||currentApp)}var internalObjectProto={},createInternalObject=()=>Object.create(internalObjectProto),isInternalObject=obj=>Object.getPrototypeOf(obj)===internalObjectProto;function initProps(instance$1,rawProps,isStateful,isSSR=!1){let props={},attrs=createInternalObject();for(let key in instance$1.propsDefaults=Object.create(null),setFullProps(instance$1,rawProps,props,attrs),instance$1.propsOptions[0])key in props||(props[key]=void 0);isStateful?instance$1.props=isSSR?props:shallowReactive(props):instance$1.type.props?instance$1.props=props:instance$1.props=attrs,instance$1.attrs=attrs}function updateProps(instance$1,rawProps,rawPrevProps,optimized){let{props,attrs,vnode:{patchFlag}}=instance$1,rawCurrentProps=toRaw(props),[options]=instance$1.propsOptions,hasAttrsChanged=!1;if((optimized||patchFlag>0)&&!(patchFlag&16)){if(patchFlag&8){let propsToUpdate=instance$1.vnode.dynamicProps;for(let i=0;i{hasExtends=!0;let[props,keys]=normalizePropsOptions(raw2,appContext,!0);extend(normalized,props),keys&&needCastKeys.push(...keys)};!asMixin&&appContext.mixins.length&&appContext.mixins.forEach(extendProps),comp.extends&&extendProps(comp.extends),comp.mixins&&comp.mixins.forEach(extendProps)}if(!raw&&!hasExtends)return isObject$1(comp)&&cache$1.set(comp,EMPTY_ARR),EMPTY_ARR;if(isArray$2(raw))for(let i=0;ikey===`_`||key===`_ctx`||key===`$stable`,normalizeSlotValue=value=>isArray$2(value)?value.map(normalizeVNode):[normalizeVNode(value)],normalizeSlot$1=(key,rawSlot,ctx)=>{if(rawSlot._n)return rawSlot;let normalized=withCtx((...args)=>normalizeSlotValue(rawSlot(...args)),ctx);return normalized._c=!1,normalized},normalizeObjectSlots=(rawSlots,slots,instance$1)=>{let ctx=rawSlots._ctx;for(let key in rawSlots){if(isInternalKey(key))continue;let value=rawSlots[key];if(isFunction$1(value))slots[key]=normalizeSlot$1(key,value,ctx);else if(value!=null){let normalized=normalizeSlotValue(value);slots[key]=()=>normalized}}},normalizeVNodeSlots=(instance$1,children)=>{let normalized=normalizeSlotValue(children);instance$1.slots.default=()=>normalized},assignSlots=(slots,children,optimized)=>{for(let key in children)(optimized||!isInternalKey(key))&&(slots[key]=children[key])},initSlots=(instance$1,children,optimized)=>{let slots=instance$1.slots=createInternalObject();if(instance$1.vnode.shapeFlag&32){let type=children._;type?(assignSlots(slots,children,optimized),optimized&&def(slots,`_`,type,!0)):normalizeObjectSlots(children,slots)}else children&&normalizeVNodeSlots(instance$1,children)},updateSlots=(instance$1,children,optimized)=>{let{vnode,slots}=instance$1,needDeletionCheck=!0,deletionComparisonTarget=EMPTY_OBJ;if(vnode.shapeFlag&32){let type=children._;type?optimized&&type===1?needDeletionCheck=!1:assignSlots(slots,children,optimized):(needDeletionCheck=!children.$stable,normalizeObjectSlots(children,slots)),deletionComparisonTarget=children}else children&&(normalizeVNodeSlots(instance$1,children),deletionComparisonTarget={default:1});if(needDeletionCheck)for(let key in slots)!isInternalKey(key)&&deletionComparisonTarget[key]==null&&delete slots[key]};function initFeatureFlags$2(){}var queuePostRenderEffect=queueEffectWithSuspense;function createRenderer(options){return baseCreateRenderer(options)}function createHydrationRenderer(options){return baseCreateRenderer(options,createHydrationFunctions)}function baseCreateRenderer(options,createHydrationFns){let target=getGlobalThis$1();target.__VUE__=!0;let{insert:hostInsert,remove:hostRemove,patchProp:hostPatchProp,createElement:hostCreateElement,createText:hostCreateText,createComment:hostCreateComment,setText:hostSetText,setElementText:hostSetElementText,parentNode:hostParentNode,nextSibling:hostNextSibling,setScopeId:hostSetScopeId=NOOP,insertStaticContent:hostInsertStaticContent}=options,patch=(n1,n2,container,anchor=null,parentComponent=null,parentSuspense=null,namespace=void 0,slotScopeIds=null,optimized=!!n2.dynamicChildren)=>{if(n1===n2)return;n1&&!isSameVNodeType(n1,n2)&&(anchor=getNextHostNode(n1),unmount(n1,parentComponent,parentSuspense,!0),n1=null),n2.patchFlag===-2&&(optimized=!1,n2.dynamicChildren=null);let{type,ref:ref$1,shapeFlag}=n2;switch(type){case Text:processText(n1,n2,container,anchor);break;case Comment:processCommentNode(n1,n2,container,anchor);break;case Static:n1??mountStaticNode(n2,container,anchor,namespace);break;case Fragment:processFragment(n1,n2,container,anchor,parentComponent,parentSuspense,namespace,slotScopeIds,optimized);break;default:shapeFlag&1?processElement(n1,n2,container,anchor,parentComponent,parentSuspense,namespace,slotScopeIds,optimized):shapeFlag&6?processComponent(n1,n2,container,anchor,parentComponent,parentSuspense,namespace,slotScopeIds,optimized):(shapeFlag&64||shapeFlag&128)&&type.process(n1,n2,container,anchor,parentComponent,parentSuspense,namespace,slotScopeIds,optimized,internals)}ref$1!=null&&parentComponent?setRef(ref$1,n1&&n1.ref,parentSuspense,n2||n1,!n2):ref$1==null&&n1&&n1.ref!=null&&setRef(n1.ref,null,parentSuspense,n1,!0)},processText=(n1,n2,container,anchor)=>{if(n1==null)hostInsert(n2.el=hostCreateText(n2.children),container,anchor);else{let el=n2.el=n1.el;n2.children!==n1.children&&hostSetText(el,n2.children)}},processCommentNode=(n1,n2,container,anchor)=>{n1==null?hostInsert(n2.el=hostCreateComment(n2.children||``),container,anchor):n2.el=n1.el},mountStaticNode=(n2,container,anchor,namespace)=>{[n2.el,n2.anchor]=hostInsertStaticContent(n2.children,container,anchor,namespace,n2.el,n2.anchor)},moveStaticNode=({el,anchor},container,nextSibling)=>{let next;for(;el&&el!==anchor;)next=hostNextSibling(el),hostInsert(el,container,nextSibling),el=next;hostInsert(anchor,container,nextSibling)},removeStaticNode=({el,anchor})=>{let next;for(;el&&el!==anchor;)next=hostNextSibling(el),hostRemove(el),el=next;hostRemove(anchor)},processElement=(n1,n2,container,anchor,parentComponent,parentSuspense,namespace,slotScopeIds,optimized)=>{n2.type===`svg`?namespace=`svg`:n2.type===`math`&&(namespace=`mathml`),n1==null?mountElement(n2,container,anchor,parentComponent,parentSuspense,namespace,slotScopeIds,optimized):patchElement(n1,n2,parentComponent,parentSuspense,namespace,slotScopeIds,optimized)},mountElement=(vnode,container,anchor,parentComponent,parentSuspense,namespace,slotScopeIds,optimized)=>{let el,vnodeHook,{props,shapeFlag,transition,dirs}=vnode;if(el=vnode.el=hostCreateElement(vnode.type,namespace,props&&props.is,props),shapeFlag&8?hostSetElementText(el,vnode.children):shapeFlag&16&&mountChildren(vnode.children,el,null,parentComponent,parentSuspense,resolveChildrenNamespace(vnode,namespace),slotScopeIds,optimized),dirs&&invokeDirectiveHook(vnode,null,parentComponent,`created`),setScopeId(el,vnode,vnode.scopeId,slotScopeIds,parentComponent),props){for(let key in props)key!==`value`&&!isReservedProp(key)&&hostPatchProp(el,key,null,props[key],namespace,parentComponent);`value`in props&&hostPatchProp(el,`value`,null,props.value,namespace),(vnodeHook=props.onVnodeBeforeMount)&&invokeVNodeHook(vnodeHook,parentComponent,vnode)}dirs&&invokeDirectiveHook(vnode,null,parentComponent,`beforeMount`);let needCallTransitionHooks=needTransition(parentSuspense,transition);needCallTransitionHooks&&transition.beforeEnter(el),hostInsert(el,container,anchor),((vnodeHook=props&&props.onVnodeMounted)||needCallTransitionHooks||dirs)&&queuePostRenderEffect(()=>{vnodeHook&&invokeVNodeHook(vnodeHook,parentComponent,vnode),needCallTransitionHooks&&transition.enter(el),dirs&&invokeDirectiveHook(vnode,null,parentComponent,`mounted`)},parentSuspense)},setScopeId=(el,vnode,scopeId,slotScopeIds,parentComponent)=>{if(scopeId&&hostSetScopeId(el,scopeId),slotScopeIds)for(let i=0;i{for(let i=start;i{let el=n2.el=n1.el,{patchFlag,dynamicChildren,dirs}=n2;patchFlag|=n1.patchFlag&16;let oldProps=n1.props||EMPTY_OBJ,newProps=n2.props||EMPTY_OBJ,vnodeHook;if(parentComponent&&toggleRecurse(parentComponent,!1),(vnodeHook=newProps.onVnodeBeforeUpdate)&&invokeVNodeHook(vnodeHook,parentComponent,n2,n1),dirs&&invokeDirectiveHook(n2,n1,parentComponent,`beforeUpdate`),parentComponent&&toggleRecurse(parentComponent,!0),(oldProps.innerHTML&&newProps.innerHTML==null||oldProps.textContent&&newProps.textContent==null)&&hostSetElementText(el,``),dynamicChildren?patchBlockChildren(n1.dynamicChildren,dynamicChildren,el,parentComponent,parentSuspense,resolveChildrenNamespace(n2,namespace),slotScopeIds):optimized||patchChildren(n1,n2,el,null,parentComponent,parentSuspense,resolveChildrenNamespace(n2,namespace),slotScopeIds,!1),patchFlag>0){if(patchFlag&16)patchProps(el,oldProps,newProps,parentComponent,namespace);else if(patchFlag&2&&oldProps.class!==newProps.class&&hostPatchProp(el,`class`,null,newProps.class,namespace),patchFlag&4&&hostPatchProp(el,`style`,oldProps.style,newProps.style,namespace),patchFlag&8){let propsToUpdate=n2.dynamicProps;for(let i=0;i{vnodeHook&&invokeVNodeHook(vnodeHook,parentComponent,n2,n1),dirs&&invokeDirectiveHook(n2,n1,parentComponent,`updated`)},parentSuspense)},patchBlockChildren=(oldChildren,newChildren,fallbackContainer,parentComponent,parentSuspense,namespace,slotScopeIds)=>{for(let i=0;i{if(oldProps!==newProps){if(oldProps!==EMPTY_OBJ)for(let key in oldProps)!isReservedProp(key)&&!(key in newProps)&&hostPatchProp(el,key,oldProps[key],null,namespace,parentComponent);for(let key in newProps){if(isReservedProp(key))continue;let next=newProps[key],prev=oldProps[key];next!==prev&&key!==`value`&&hostPatchProp(el,key,prev,next,namespace,parentComponent)}`value`in newProps&&hostPatchProp(el,`value`,oldProps.value,newProps.value,namespace)}},processFragment=(n1,n2,container,anchor,parentComponent,parentSuspense,namespace,slotScopeIds,optimized)=>{let fragmentStartAnchor=n2.el=n1?n1.el:hostCreateText(``),fragmentEndAnchor=n2.anchor=n1?n1.anchor:hostCreateText(``),{patchFlag,dynamicChildren,slotScopeIds:fragmentSlotScopeIds}=n2;fragmentSlotScopeIds&&(slotScopeIds=slotScopeIds?slotScopeIds.concat(fragmentSlotScopeIds):fragmentSlotScopeIds),n1==null?(hostInsert(fragmentStartAnchor,container,anchor),hostInsert(fragmentEndAnchor,container,anchor),mountChildren(n2.children||[],container,fragmentEndAnchor,parentComponent,parentSuspense,namespace,slotScopeIds,optimized)):patchFlag>0&&patchFlag&64&&dynamicChildren&&n1.dynamicChildren?(patchBlockChildren(n1.dynamicChildren,dynamicChildren,container,parentComponent,parentSuspense,namespace,slotScopeIds),(n2.key!=null||parentComponent&&n2===parentComponent.subTree)&&traverseStaticChildren(n1,n2,!0)):patchChildren(n1,n2,container,fragmentEndAnchor,parentComponent,parentSuspense,namespace,slotScopeIds,optimized)},processComponent=(n1,n2,container,anchor,parentComponent,parentSuspense,namespace,slotScopeIds,optimized)=>{n2.slotScopeIds=slotScopeIds,n1==null?n2.shapeFlag&512?parentComponent.ctx.activate(n2,container,anchor,namespace,optimized):mountComponent(n2,container,anchor,parentComponent,parentSuspense,namespace,optimized):updateComponent(n1,n2,optimized)},mountComponent=(initialVNode,container,anchor,parentComponent,parentSuspense,namespace,optimized)=>{let instance$1=initialVNode.component=createComponentInstance(initialVNode,parentComponent,parentSuspense);if(isKeepAlive(initialVNode)&&(instance$1.ctx.renderer=internals),setupComponent(instance$1,!1,optimized),instance$1.asyncDep){if(parentSuspense&&parentSuspense.registerDep(instance$1,setupRenderEffect,optimized),!initialVNode.el){let placeholder=instance$1.subTree=createVNode(Comment);processCommentNode(null,placeholder,container,anchor),initialVNode.placeholder=placeholder.el}}else setupRenderEffect(instance$1,initialVNode,container,anchor,parentSuspense,namespace,optimized)},updateComponent=(n1,n2,optimized)=>{let instance$1=n2.component=n1.component;if(shouldUpdateComponent(n1,n2,optimized))if(instance$1.asyncDep&&!instance$1.asyncResolved){updateComponentPreRender(instance$1,n2,optimized);return}else instance$1.next=n2,instance$1.update();else n2.el=n1.el,instance$1.vnode=n2},setupRenderEffect=(instance$1,initialVNode,container,anchor,parentSuspense,namespace,optimized)=>{let componentUpdateFn=()=>{if(instance$1.isMounted){let{next,bu,u,parent,vnode}=instance$1;{let nonHydratedAsyncRoot=locateNonHydratedAsyncRoot(instance$1);if(nonHydratedAsyncRoot){next&&(next.el=vnode.el,updateComponentPreRender(instance$1,next,optimized)),nonHydratedAsyncRoot.asyncDep.then(()=>{instance$1.isUnmounted||componentUpdateFn()});return}}let originNext=next,vnodeHook;toggleRecurse(instance$1,!1),next?(next.el=vnode.el,updateComponentPreRender(instance$1,next,optimized)):next=vnode,bu&&invokeArrayFns(bu),(vnodeHook=next.props&&next.props.onVnodeBeforeUpdate)&&invokeVNodeHook(vnodeHook,parent,next,vnode),toggleRecurse(instance$1,!0);let nextTree=renderComponentRoot(instance$1),prevTree=instance$1.subTree;instance$1.subTree=nextTree,patch(prevTree,nextTree,hostParentNode(prevTree.el),getNextHostNode(prevTree),instance$1,parentSuspense,namespace),next.el=nextTree.el,originNext===null&&updateHOCHostEl(instance$1,nextTree.el),u&&queuePostRenderEffect(u,parentSuspense),(vnodeHook=next.props&&next.props.onVnodeUpdated)&&queuePostRenderEffect(()=>invokeVNodeHook(vnodeHook,parent,next,vnode),parentSuspense)}else{let vnodeHook,{el,props}=initialVNode,{bm,m,parent,root,type}=instance$1,isAsyncWrapperVNode=isAsyncWrapper(initialVNode);if(toggleRecurse(instance$1,!1),bm&&invokeArrayFns(bm),!isAsyncWrapperVNode&&(vnodeHook=props&&props.onVnodeBeforeMount)&&invokeVNodeHook(vnodeHook,parent,initialVNode),toggleRecurse(instance$1,!0),el&&hydrateNode){let hydrateSubTree=()=>{instance$1.subTree=renderComponentRoot(instance$1),hydrateNode(el,instance$1.subTree,instance$1,parentSuspense,null)};isAsyncWrapperVNode&&type.__asyncHydrate?type.__asyncHydrate(el,instance$1,hydrateSubTree):hydrateSubTree()}else{root.ce&&root.ce._def.shadowRoot!==!1&&root.ce._injectChildStyle(type);let subTree=instance$1.subTree=renderComponentRoot(instance$1);patch(null,subTree,container,anchor,instance$1,parentSuspense,namespace),initialVNode.el=subTree.el}if(m&&queuePostRenderEffect(m,parentSuspense),!isAsyncWrapperVNode&&(vnodeHook=props&&props.onVnodeMounted)){let scopedInitialVNode=initialVNode;queuePostRenderEffect(()=>invokeVNodeHook(vnodeHook,parent,scopedInitialVNode),parentSuspense)}(initialVNode.shapeFlag&256||parent&&isAsyncWrapper(parent.vnode)&&parent.vnode.shapeFlag&256)&&instance$1.a&&queuePostRenderEffect(instance$1.a,parentSuspense),instance$1.isMounted=!0,initialVNode=container=anchor=null}};instance$1.scope.on();let effect$1=instance$1.effect=new ReactiveEffect(componentUpdateFn);instance$1.scope.off();let update$6=instance$1.update=effect$1.run.bind(effect$1),job=instance$1.job=effect$1.runIfDirty.bind(effect$1);job.i=instance$1,job.id=instance$1.uid,effect$1.scheduler=()=>queueJob(job),toggleRecurse(instance$1,!0),update$6()},updateComponentPreRender=(instance$1,nextVNode,optimized)=>{nextVNode.component=instance$1;let prevProps=instance$1.vnode.props;instance$1.vnode=nextVNode,instance$1.next=null,updateProps(instance$1,nextVNode.props,prevProps,optimized),updateSlots(instance$1,nextVNode.children,optimized),pauseTracking(),flushPreFlushCbs(instance$1),resetTracking()},patchChildren=(n1,n2,container,anchor,parentComponent,parentSuspense,namespace,slotScopeIds,optimized=!1)=>{let c1=n1&&n1.children,prevShapeFlag=n1?n1.shapeFlag:0,c2=n2.children,{patchFlag,shapeFlag}=n2;if(patchFlag>0){if(patchFlag&128){patchKeyedChildren(c1,c2,container,anchor,parentComponent,parentSuspense,namespace,slotScopeIds,optimized);return}else if(patchFlag&256){patchUnkeyedChildren(c1,c2,container,anchor,parentComponent,parentSuspense,namespace,slotScopeIds,optimized);return}}shapeFlag&8?(prevShapeFlag&16&&unmountChildren(c1,parentComponent,parentSuspense),c2!==c1&&hostSetElementText(container,c2)):prevShapeFlag&16?shapeFlag&16?patchKeyedChildren(c1,c2,container,anchor,parentComponent,parentSuspense,namespace,slotScopeIds,optimized):unmountChildren(c1,parentComponent,parentSuspense,!0):(prevShapeFlag&8&&hostSetElementText(container,``),shapeFlag&16&&mountChildren(c2,container,anchor,parentComponent,parentSuspense,namespace,slotScopeIds,optimized))},patchUnkeyedChildren=(c1,c2,container,anchor,parentComponent,parentSuspense,namespace,slotScopeIds,optimized)=>{c1||=EMPTY_ARR,c2||=EMPTY_ARR;let oldLength=c1.length,newLength=c2.length,commonLength=Math.min(oldLength,newLength),i;for(i=0;inewLength?unmountChildren(c1,parentComponent,parentSuspense,!0,!1,commonLength):mountChildren(c2,container,anchor,parentComponent,parentSuspense,namespace,slotScopeIds,optimized,commonLength)},patchKeyedChildren=(c1,c2,container,parentAnchor,parentComponent,parentSuspense,namespace,slotScopeIds,optimized)=>{let i=0,l2=c2.length,e1=c1.length-1,e2=l2-1;for(;i<=e1&&i<=e2;){let n1=c1[i],n2=c2[i]=optimized?cloneIfMounted(c2[i]):normalizeVNode(c2[i]);if(isSameVNodeType(n1,n2))patch(n1,n2,container,null,parentComponent,parentSuspense,namespace,slotScopeIds,optimized);else break;i++}for(;i<=e1&&i<=e2;){let n1=c1[e1],n2=c2[e2]=optimized?cloneIfMounted(c2[e2]):normalizeVNode(c2[e2]);if(isSameVNodeType(n1,n2))patch(n1,n2,container,null,parentComponent,parentSuspense,namespace,slotScopeIds,optimized);else break;e1--,e2--}if(i>e1){if(i<=e2){let nextPos=e2+1,anchor=nextPose2)for(;i<=e1;)unmount(c1[i],parentComponent,parentSuspense,!0),i++;else{let s1=i,s2=i,keyToNewIndexMap=new Map;for(i=s2;i<=e2;i++){let nextChild=c2[i]=optimized?cloneIfMounted(c2[i]):normalizeVNode(c2[i]);nextChild.key!=null&&keyToNewIndexMap.set(nextChild.key,i)}let j,patched=0,toBePatched=e2-s2+1,moved=!1,maxNewIndexSoFar=0,newIndexToOldIndexMap=Array(toBePatched);for(i=0;i=toBePatched){unmount(prevChild,parentComponent,parentSuspense,!0);continue}let newIndex;if(prevChild.key!=null)newIndex=keyToNewIndexMap.get(prevChild.key);else for(j=s2;j<=e2;j++)if(newIndexToOldIndexMap[j-s2]===0&&isSameVNodeType(prevChild,c2[j])){newIndex=j;break}newIndex===void 0?unmount(prevChild,parentComponent,parentSuspense,!0):(newIndexToOldIndexMap[newIndex-s2]=i+1,newIndex>=maxNewIndexSoFar?maxNewIndexSoFar=newIndex:moved=!0,patch(prevChild,c2[newIndex],container,null,parentComponent,parentSuspense,namespace,slotScopeIds,optimized),patched++)}let increasingNewIndexSequence=moved?getSequence(newIndexToOldIndexMap):EMPTY_ARR;for(j=increasingNewIndexSequence.length-1,i=toBePatched-1;i>=0;i--){let nextIndex=s2+i,nextChild=c2[nextIndex],anchorVNode=c2[nextIndex+1],anchor=nextIndex+1{let{el,type,transition,children,shapeFlag}=vnode;if(shapeFlag&6){move(vnode.component.subTree,container,anchor,moveType);return}if(shapeFlag&128){vnode.suspense.move(container,anchor,moveType);return}if(shapeFlag&64){type.move(vnode,container,anchor,internals);return}if(type===Fragment){hostInsert(el,container,anchor);for(let i=0;itransition.enter(el),parentSuspense);else{let{leave,delayLeave,afterLeave}=transition,remove2=()=>{vnode.ctx.isUnmounted?hostRemove(el):hostInsert(el,container,anchor)},performLeave=()=>{el._isLeaving&&el[leaveCbKey](!0),leave(el,()=>{remove2(),afterLeave&&afterLeave()})};delayLeave?delayLeave(el,remove2,performLeave):performLeave()}else hostInsert(el,container,anchor)},unmount=(vnode,parentComponent,parentSuspense,doRemove=!1,optimized=!1)=>{let{type,props,ref:ref$1,children,dynamicChildren,shapeFlag,patchFlag,dirs,cacheIndex}=vnode;if(patchFlag===-2&&(optimized=!1),ref$1!=null&&(pauseTracking(),setRef(ref$1,null,parentSuspense,vnode,!0),resetTracking()),cacheIndex!=null&&(parentComponent.renderCache[cacheIndex]=void 0),shapeFlag&256){parentComponent.ctx.deactivate(vnode);return}let shouldInvokeDirs=shapeFlag&1&&dirs,shouldInvokeVnodeHook=!isAsyncWrapper(vnode),vnodeHook;if(shouldInvokeVnodeHook&&(vnodeHook=props&&props.onVnodeBeforeUnmount)&&invokeVNodeHook(vnodeHook,parentComponent,vnode),shapeFlag&6)unmountComponent(vnode.component,parentSuspense,doRemove);else{if(shapeFlag&128){vnode.suspense.unmount(parentSuspense,doRemove);return}shouldInvokeDirs&&invokeDirectiveHook(vnode,null,parentComponent,`beforeUnmount`),shapeFlag&64?vnode.type.remove(vnode,parentComponent,parentSuspense,internals,doRemove):dynamicChildren&&!dynamicChildren.hasOnce&&(type!==Fragment||patchFlag>0&&patchFlag&64)?unmountChildren(dynamicChildren,parentComponent,parentSuspense,!1,!0):(type===Fragment&&patchFlag&384||!optimized&&shapeFlag&16)&&unmountChildren(children,parentComponent,parentSuspense),doRemove&&remove$3(vnode)}(shouldInvokeVnodeHook&&(vnodeHook=props&&props.onVnodeUnmounted)||shouldInvokeDirs)&&queuePostRenderEffect(()=>{vnodeHook&&invokeVNodeHook(vnodeHook,parentComponent,vnode),shouldInvokeDirs&&invokeDirectiveHook(vnode,null,parentComponent,`unmounted`)},parentSuspense)},remove$3=vnode=>{let{type,el,anchor,transition}=vnode;if(type===Fragment){removeFragment(el,anchor);return}if(type===Static){removeStaticNode(vnode);return}let performRemove=()=>{hostRemove(el),transition&&!transition.persisted&&transition.afterLeave&&transition.afterLeave()};if(vnode.shapeFlag&1&&transition&&!transition.persisted){let{leave,delayLeave}=transition,performLeave=()=>leave(el,performRemove);delayLeave?delayLeave(vnode.el,performRemove,performLeave):performLeave()}else performRemove()},removeFragment=(cur,end)=>{let next;for(;cur!==end;)next=hostNextSibling(cur),hostRemove(cur),cur=next;hostRemove(end)},unmountComponent=(instance$1,parentSuspense,doRemove)=>{let{bum,scope:scope$1,job,subTree,um,m,a:a$1}=instance$1;invalidateMount(m),invalidateMount(a$1),bum&&invokeArrayFns(bum),scope$1.stop(),job&&(job.flags|=8,unmount(subTree,instance$1,parentSuspense,doRemove)),um&&queuePostRenderEffect(um,parentSuspense),queuePostRenderEffect(()=>{instance$1.isUnmounted=!0},parentSuspense)},unmountChildren=(children,parentComponent,parentSuspense,doRemove=!1,optimized=!1,start=0)=>{for(let i=start;i{if(vnode.shapeFlag&6)return getNextHostNode(vnode.component.subTree);if(vnode.shapeFlag&128)return vnode.suspense.next();let el=hostNextSibling(vnode.anchor||vnode.el),teleportEnd=el&&el[TeleportEndKey];return teleportEnd?hostNextSibling(teleportEnd):el},isFlushing=!1,render$1=(vnode,container,namespace)=>{vnode==null?container._vnode&&unmount(container._vnode,null,null,!0):patch(container._vnode||null,vnode,container,null,null,null,namespace),container._vnode=vnode,isFlushing||=(isFlushing=!0,flushPreFlushCbs(),flushPostFlushCbs(),!1)},internals={p:patch,um:unmount,m:move,r:remove$3,mt:mountComponent,mc:mountChildren,pc:patchChildren,pbc:patchBlockChildren,n:getNextHostNode,o:options},hydrate$1,hydrateNode;return createHydrationFns&&([hydrate$1,hydrateNode]=createHydrationFns(internals)),{render:render$1,hydrate:hydrate$1,createApp:createAppAPI(render$1,hydrate$1)}}function resolveChildrenNamespace({type,props},currentNamespace){return currentNamespace===`svg`&&type===`foreignObject`||currentNamespace===`mathml`&&type===`annotation-xml`&&props&&props.encoding&&props.encoding.includes(`html`)?void 0:currentNamespace}function toggleRecurse({effect:effect$1,job},allowed){allowed?(effect$1.flags|=32,job.flags|=4):(effect$1.flags&=-33,job.flags&=-5)}function needTransition(parentSuspense,transition){return(!parentSuspense||parentSuspense&&!parentSuspense.pendingBranch)&&transition&&!transition.persisted}function traverseStaticChildren(n1,n2,shallow=!1){let ch1=n1.children,ch2=n2.children;if(isArray$2(ch1)&&isArray$2(ch2))for(let i=0;i>1,arr[result[c]]0&&(p$1[i]=result[u-1]),result[u]=i)}}for(u=result.length,v=result[u-1];u-- >0;)result[u]=v,v=p$1[v];return result}function locateNonHydratedAsyncRoot(instance$1){let subComponent=instance$1.subTree.component;if(subComponent)return subComponent.asyncDep&&!subComponent.asyncResolved?subComponent:locateNonHydratedAsyncRoot(subComponent)}function invalidateMount(hooks){if(hooks)for(let i=0;iinject(ssrContextKey);function watchEffect(effect$1,options){return doWatch(effect$1,null,options)}function watchPostEffect(effect$1,options){return doWatch(effect$1,null,{flush:`post`})}function watchSyncEffect(effect$1,options){return doWatch(effect$1,null,{flush:`sync`})}function watch(source,cb,options){return doWatch(source,cb,options)}function doWatch(source,cb,options=EMPTY_OBJ){let{immediate,deep,flush,once}=options,baseWatchOptions=extend({},options),runsImmediately=cb&&immediate||!cb&&flush!==`post`,ssrCleanup;if(isInSSRComponentSetup){if(flush===`sync`){let ctx=useSSRContext();ssrCleanup=ctx.__watcherHandles||=[]}else if(!runsImmediately){let watchStopHandle=()=>{};return watchStopHandle.stop=NOOP,watchStopHandle.resume=NOOP,watchStopHandle.pause=NOOP,watchStopHandle}}let instance$1=currentInstance;baseWatchOptions.call=(fn,type,args)=>callWithAsyncErrorHandling(fn,instance$1,type,args);let isPre=!1;flush===`post`?baseWatchOptions.scheduler=job=>{queuePostRenderEffect(job,instance$1&&instance$1.suspense)}:flush!==`sync`&&(isPre=!0,baseWatchOptions.scheduler=(job,isFirstRun)=>{isFirstRun?job():queueJob(job)}),baseWatchOptions.augmentJob=job=>{cb&&(job.flags|=4),isPre&&(job.flags|=2,instance$1&&(job.id=instance$1.uid,job.i=instance$1))};let watchHandle=watch$1(source,cb,baseWatchOptions);return isInSSRComponentSetup&&(ssrCleanup?ssrCleanup.push(watchHandle):runsImmediately&&watchHandle()),watchHandle}function instanceWatch(source,value,options){let publicThis=this.proxy,getter=isString$1(source)?source.includes(`.`)?createPathGetter(publicThis,source):()=>publicThis[source]:source.bind(publicThis,publicThis),cb;isFunction$1(value)?cb=value:(cb=value.handler,options=value);let reset$1=setCurrentInstance(this),res=doWatch(getter,cb.bind(publicThis),options);return reset$1(),res}function createPathGetter(ctx,path){let segments=path.split(`.`);return()=>{let cur=ctx;for(let i=0;i{let localValue,prevSetValue=EMPTY_OBJ,prevEmittedValue;return watchSyncEffect(()=>{let propValue=props[camelizedName];hasChanged(localValue,propValue)&&(localValue=propValue,trigger$2())}),{get(){return track$1(),options.get?options.get(localValue):localValue},set(value){let emittedValue=options.set?options.set(value):value;if(!hasChanged(emittedValue,localValue)&&!(prevSetValue!==EMPTY_OBJ&&hasChanged(value,prevSetValue)))return;let rawProps=i.vnode.props;rawProps&&(name in rawProps||camelizedName in rawProps||hyphenatedName in rawProps)&&(`onUpdate:${name}`in rawProps||`onUpdate:${camelizedName}`in rawProps||`onUpdate:${hyphenatedName}`in rawProps)||(localValue=value,trigger$2()),i.emit(`update:${name}`,emittedValue),hasChanged(value,emittedValue)&&hasChanged(value,prevSetValue)&&!hasChanged(emittedValue,prevEmittedValue)&&trigger$2(),prevSetValue=value,prevEmittedValue=emittedValue}}});return res[Symbol.iterator]=()=>{let i2=0;return{next(){return i2<2?{value:i2++?modifiers||EMPTY_OBJ:res,done:!1}:{done:!0}}}},res}var getModelModifiers=(props,modelName)=>modelName===`modelValue`||modelName===`model-value`?props.modelModifiers:props[`${modelName}Modifiers`]||props[`${camelize(modelName)}Modifiers`]||props[`${hyphenate(modelName)}Modifiers`];function emit(instance$1,event,...rawArgs){if(instance$1.isUnmounted)return;let props=instance$1.vnode.props||EMPTY_OBJ,args=rawArgs,isModelListener$1=event.startsWith(`update:`),modifiers=isModelListener$1&&getModelModifiers(props,event.slice(7));modifiers&&(modifiers.trim&&(args=rawArgs.map(a$1=>isString$1(a$1)?a$1.trim():a$1)),modifiers.number&&(args=rawArgs.map(looseToNumber)));let handlerName,handler$1=props[handlerName=toHandlerKey(event)]||props[handlerName=toHandlerKey(camelize(event))];!handler$1&&isModelListener$1&&(handler$1=props[handlerName=toHandlerKey(hyphenate(event))]),handler$1&&callWithAsyncErrorHandling(handler$1,instance$1,6,args);let onceHandler=props[handlerName+`Once`];if(onceHandler){if(!instance$1.emitted)instance$1.emitted={};else if(instance$1.emitted[handlerName])return;instance$1.emitted[handlerName]=!0,callWithAsyncErrorHandling(onceHandler,instance$1,6,args)}}var mixinEmitsCache=new WeakMap;function normalizeEmitsOptions(comp,appContext,asMixin=!1){let cache$1=asMixin?mixinEmitsCache:appContext.emitsCache,cached=cache$1.get(comp);if(cached!==void 0)return cached;let raw=comp.emits,normalized={},hasExtends=!1;if(!isFunction$1(comp)){let extendEmits=raw2=>{let normalizedFromExtend=normalizeEmitsOptions(raw2,appContext,!0);normalizedFromExtend&&(hasExtends=!0,extend(normalized,normalizedFromExtend))};!asMixin&&appContext.mixins.length&&appContext.mixins.forEach(extendEmits),comp.extends&&extendEmits(comp.extends),comp.mixins&&comp.mixins.forEach(extendEmits)}return!raw&&!hasExtends?(isObject$1(comp)&&cache$1.set(comp,null),null):(isArray$2(raw)?raw.forEach(key=>normalized[key]=null):extend(normalized,raw),isObject$1(comp)&&cache$1.set(comp,normalized),normalized)}function isEmitListener(options,key){return!options||!isOn(key)?!1:(key=key.slice(2).replace(/Once$/,``),hasOwn$1(options,key[0].toLowerCase()+key.slice(1))||hasOwn$1(options,hyphenate(key))||hasOwn$1(options,key))}function renderComponentRoot(instance$1){let{type:Component,vnode,proxy,withProxy,propsOptions:[propsOptions],slots,attrs,emit:emit$1,render:render$1,renderCache,props,data,setupState,ctx,inheritAttrs}=instance$1,prev=setCurrentRenderingInstance(instance$1),result,fallthroughAttrs;try{if(vnode.shapeFlag&4){let proxyToUse=withProxy||proxy,thisProxy=proxyToUse;result=normalizeVNode(render$1.call(thisProxy,proxyToUse,renderCache,props,setupState,data,ctx)),fallthroughAttrs=attrs}else{let render2=Component;result=normalizeVNode(render2.length>1?render2(props,{attrs,slots,emit:emit$1}):render2(props,null)),fallthroughAttrs=Component.props?attrs:getFunctionalFallthrough(attrs)}}catch(err){blockStack.length=0,handleError(err,instance$1,1),result=createVNode(Comment)}let root=result;if(fallthroughAttrs&&inheritAttrs!==!1){let keys=Object.keys(fallthroughAttrs),{shapeFlag}=root;keys.length&&shapeFlag&7&&(propsOptions&&keys.some(isModelListener)&&(fallthroughAttrs=filterModelListeners(fallthroughAttrs,propsOptions)),root=cloneVNode(root,fallthroughAttrs,!1,!0))}return vnode.dirs&&(root=cloneVNode(root,null,!1,!0),root.dirs=root.dirs?root.dirs.concat(vnode.dirs):vnode.dirs),vnode.transition&&setTransitionHooks(root,vnode.transition),result=root,setCurrentRenderingInstance(prev),result}function filterSingleRoot(children,recurse=!0){let singleRoot;for(let i=0;i{let res;for(let key in attrs)(key===`class`||key===`style`||isOn(key))&&((res||={})[key]=attrs[key]);return res},filterModelListeners=(attrs,props)=>{let res={};for(let key in attrs)(!isModelListener(key)||!(key.slice(9)in props))&&(res[key]=attrs[key]);return res};function shouldUpdateComponent(prevVNode,nextVNode,optimized){let{props:prevProps,children:prevChildren,component}=prevVNode,{props:nextProps,children:nextChildren,patchFlag}=nextVNode,emits=component.emitsOptions;if(nextVNode.dirs||nextVNode.transition)return!0;if(optimized&&patchFlag>=0){if(patchFlag&1024)return!0;if(patchFlag&16)return prevProps?hasPropsChanged(prevProps,nextProps,emits):!!nextProps;if(patchFlag&8){let dynamicProps=nextVNode.dynamicProps;for(let i=0;itype.__isSuspense,suspenseId=0,Suspense={name:`Suspense`,__isSuspense:!0,process(n1,n2,container,anchor,parentComponent,parentSuspense,namespace,slotScopeIds,optimized,rendererInternals){if(n1==null)mountSuspense(n2,container,anchor,parentComponent,parentSuspense,namespace,slotScopeIds,optimized,rendererInternals);else{if(parentSuspense&&parentSuspense.deps>0&&!n1.suspense.isInFallback){n2.suspense=n1.suspense,n2.suspense.vnode=n2,n2.el=n1.el;return}patchSuspense(n1,n2,container,anchor,parentComponent,namespace,slotScopeIds,optimized,rendererInternals)}},hydrate:hydrateSuspense,normalize:normalizeSuspenseChildren};function triggerEvent(vnode,name){let eventListener=vnode.props&&vnode.props[name];isFunction$1(eventListener)&&eventListener()}function mountSuspense(vnode,container,anchor,parentComponent,parentSuspense,namespace,slotScopeIds,optimized,rendererInternals){let{p:patch,o:{createElement}}=rendererInternals,hiddenContainer=createElement(`div`),suspense=vnode.suspense=createSuspenseBoundary(vnode,parentSuspense,parentComponent,container,hiddenContainer,anchor,namespace,slotScopeIds,optimized,rendererInternals);patch(null,suspense.pendingBranch=vnode.ssContent,hiddenContainer,null,parentComponent,suspense,namespace,slotScopeIds),suspense.deps>0?(triggerEvent(vnode,`onPending`),triggerEvent(vnode,`onFallback`),patch(null,vnode.ssFallback,container,anchor,parentComponent,null,namespace,slotScopeIds),setActiveBranch(suspense,vnode.ssFallback)):suspense.resolve(!1,!0)}function patchSuspense(n1,n2,container,anchor,parentComponent,namespace,slotScopeIds,optimized,{p:patch,um:unmount,o:{createElement}}){let suspense=n2.suspense=n1.suspense;suspense.vnode=n2,n2.el=n1.el;let newBranch=n2.ssContent,newFallback=n2.ssFallback,{activeBranch,pendingBranch,isInFallback,isHydrating}=suspense;if(pendingBranch)suspense.pendingBranch=newBranch,isSameVNodeType(pendingBranch,newBranch)?(patch(pendingBranch,newBranch,suspense.hiddenContainer,null,parentComponent,suspense,namespace,slotScopeIds,optimized),suspense.deps<=0?suspense.resolve():isInFallback&&(isHydrating||(patch(activeBranch,newFallback,container,anchor,parentComponent,null,namespace,slotScopeIds,optimized),setActiveBranch(suspense,newFallback)))):(suspense.pendingId=suspenseId++,isHydrating?(suspense.isHydrating=!1,suspense.activeBranch=pendingBranch):unmount(pendingBranch,parentComponent,suspense),suspense.deps=0,suspense.effects.length=0,suspense.hiddenContainer=createElement(`div`),isInFallback?(patch(null,newBranch,suspense.hiddenContainer,null,parentComponent,suspense,namespace,slotScopeIds,optimized),suspense.deps<=0?suspense.resolve():(patch(activeBranch,newFallback,container,anchor,parentComponent,null,namespace,slotScopeIds,optimized),setActiveBranch(suspense,newFallback))):activeBranch&&isSameVNodeType(activeBranch,newBranch)?(patch(activeBranch,newBranch,container,anchor,parentComponent,suspense,namespace,slotScopeIds,optimized),suspense.resolve(!0)):(patch(null,newBranch,suspense.hiddenContainer,null,parentComponent,suspense,namespace,slotScopeIds,optimized),suspense.deps<=0&&suspense.resolve()));else if(activeBranch&&isSameVNodeType(activeBranch,newBranch))patch(activeBranch,newBranch,container,anchor,parentComponent,suspense,namespace,slotScopeIds,optimized),setActiveBranch(suspense,newBranch);else if(triggerEvent(n2,`onPending`),suspense.pendingBranch=newBranch,newBranch.shapeFlag&512?suspense.pendingId=newBranch.component.suspenseId:suspense.pendingId=suspenseId++,patch(null,newBranch,suspense.hiddenContainer,null,parentComponent,suspense,namespace,slotScopeIds,optimized),suspense.deps<=0)suspense.resolve();else{let{timeout,pendingId}=suspense;timeout>0?setTimeout(()=>{suspense.pendingId===pendingId&&suspense.fallback(newFallback)},timeout):timeout===0&&suspense.fallback(newFallback)}}function createSuspenseBoundary(vnode,parentSuspense,parentComponent,container,hiddenContainer,anchor,namespace,slotScopeIds,optimized,rendererInternals,isHydrating=!1){let{p:patch,m:move,um:unmount,n:next,o:{parentNode,remove:remove$3}}=rendererInternals,parentSuspenseId,isSuspensible=isVNodeSuspensible(vnode);isSuspensible&&parentSuspense&&parentSuspense.pendingBranch&&(parentSuspenseId=parentSuspense.pendingId,parentSuspense.deps++);let timeout=vnode.props?toNumber(vnode.props.timeout):void 0,initialAnchor=anchor,suspense={vnode,parent:parentSuspense,parentComponent,namespace,container,hiddenContainer,deps:0,pendingId:suspenseId++,timeout:typeof timeout==`number`?timeout:-1,activeBranch:null,pendingBranch:null,isInFallback:!isHydrating,isHydrating,isUnmounted:!1,effects:[],resolve(resume=!1,sync=!1){let{vnode:vnode2,activeBranch,pendingBranch,pendingId,effects,parentComponent:parentComponent2,container:container2}=suspense,delayEnter=!1;suspense.isHydrating?suspense.isHydrating=!1:resume||(delayEnter=activeBranch&&pendingBranch.transition&&pendingBranch.transition.mode===`out-in`,delayEnter&&(activeBranch.transition.afterLeave=()=>{pendingId===suspense.pendingId&&(move(pendingBranch,container2,anchor===initialAnchor?next(activeBranch):anchor,0),queuePostFlushCb(effects))}),activeBranch&&(parentNode(activeBranch.el)===container2&&(anchor=next(activeBranch)),unmount(activeBranch,parentComponent2,suspense,!0)),delayEnter||move(pendingBranch,container2,anchor,0)),setActiveBranch(suspense,pendingBranch),suspense.pendingBranch=null,suspense.isInFallback=!1;let parent=suspense.parent,hasUnresolvedAncestor=!1;for(;parent;){if(parent.pendingBranch){parent.effects.push(...effects),hasUnresolvedAncestor=!0;break}parent=parent.parent}!hasUnresolvedAncestor&&!delayEnter&&queuePostFlushCb(effects),suspense.effects=[],isSuspensible&&parentSuspense&&parentSuspense.pendingBranch&&parentSuspenseId===parentSuspense.pendingId&&(parentSuspense.deps--,parentSuspense.deps===0&&!sync&&parentSuspense.resolve()),triggerEvent(vnode2,`onResolve`)},fallback(fallbackVNode){if(!suspense.pendingBranch)return;let{vnode:vnode2,activeBranch,parentComponent:parentComponent2,container:container2,namespace:namespace2}=suspense;triggerEvent(vnode2,`onFallback`);let anchor2=next(activeBranch),mountFallback=()=>{suspense.isInFallback&&(patch(null,fallbackVNode,container2,anchor2,parentComponent2,null,namespace2,slotScopeIds,optimized),setActiveBranch(suspense,fallbackVNode))},delayEnter=fallbackVNode.transition&&fallbackVNode.transition.mode===`out-in`;delayEnter&&(activeBranch.transition.afterLeave=mountFallback),suspense.isInFallback=!0,unmount(activeBranch,parentComponent2,null,!0),delayEnter||mountFallback()},move(container2,anchor2,type){suspense.activeBranch&&move(suspense.activeBranch,container2,anchor2,type),suspense.container=container2},next(){return suspense.activeBranch&&next(suspense.activeBranch)},registerDep(instance$1,setupRenderEffect,optimized2){let isInPendingSuspense=!!suspense.pendingBranch;isInPendingSuspense&&suspense.deps++;let hydratedEl=instance$1.vnode.el;instance$1.asyncDep.catch(err=>{handleError(err,instance$1,0)}).then(asyncSetupResult=>{if(instance$1.isUnmounted||suspense.isUnmounted||suspense.pendingId!==instance$1.suspenseId)return;instance$1.asyncResolved=!0;let{vnode:vnode2}=instance$1;handleSetupResult(instance$1,asyncSetupResult,!1),hydratedEl&&(vnode2.el=hydratedEl);let placeholder=!hydratedEl&&instance$1.subTree.el;setupRenderEffect(instance$1,vnode2,parentNode(hydratedEl||instance$1.subTree.el),hydratedEl?null:next(instance$1.subTree),suspense,namespace,optimized2),placeholder&&remove$3(placeholder),updateHOCHostEl(instance$1,vnode2.el),isInPendingSuspense&&--suspense.deps===0&&suspense.resolve()})},unmount(parentSuspense2,doRemove){suspense.isUnmounted=!0,suspense.activeBranch&&unmount(suspense.activeBranch,parentComponent,parentSuspense2,doRemove),suspense.pendingBranch&&unmount(suspense.pendingBranch,parentComponent,parentSuspense2,doRemove)}};return suspense}function hydrateSuspense(node,vnode,parentComponent,parentSuspense,namespace,slotScopeIds,optimized,rendererInternals,hydrateNode){let suspense=vnode.suspense=createSuspenseBoundary(vnode,parentSuspense,parentComponent,node.parentNode,document.createElement(`div`),null,namespace,slotScopeIds,optimized,rendererInternals,!0),result=hydrateNode(node,suspense.pendingBranch=vnode.ssContent,parentComponent,suspense,slotScopeIds,optimized);return suspense.deps===0&&suspense.resolve(!1,!0),result}function normalizeSuspenseChildren(vnode){let{shapeFlag,children}=vnode,isSlotChildren=shapeFlag&32;vnode.ssContent=normalizeSuspenseSlot(isSlotChildren?children.default:children),vnode.ssFallback=isSlotChildren?normalizeSuspenseSlot(children.fallback):createVNode(Comment)}function normalizeSuspenseSlot(s){let block;if(isFunction$1(s)){let trackBlock=isBlockTreeEnabled&&s._c;trackBlock&&(s._d=!1,openBlock()),s=s(),trackBlock&&(s._d=!0,block=currentBlock,closeBlock())}return isArray$2(s)&&(s=filterSingleRoot(s)),s=normalizeVNode(s),block&&!s.dynamicChildren&&(s.dynamicChildren=block.filter(c=>c!==s)),s}function queueEffectWithSuspense(fn,suspense){suspense&&suspense.pendingBranch?isArray$2(fn)?suspense.effects.push(...fn):suspense.effects.push(fn):queuePostFlushCb(fn)}function setActiveBranch(suspense,branch){suspense.activeBranch=branch;let{vnode,parentComponent}=suspense,el=branch.el;for(;!el&&branch.component;)branch=branch.component.subTree,el=branch.el;vnode.el=el,parentComponent&&parentComponent.subTree===vnode&&(parentComponent.vnode.el=el,updateHOCHostEl(parentComponent,el))}function isVNodeSuspensible(vnode){let suspensible=vnode.props&&vnode.props.suspensible;return suspensible!=null&&suspensible!==!1}var Fragment=Symbol.for(`v-fgt`),Text=Symbol.for(`v-txt`),Comment=Symbol.for(`v-cmt`),Static=Symbol.for(`v-stc`),blockStack=[],currentBlock=null;function openBlock(disableTracking=!1){blockStack.push(currentBlock=disableTracking?null:[])}function closeBlock(){blockStack.pop(),currentBlock=blockStack[blockStack.length-1]||null}var isBlockTreeEnabled=1;function setBlockTracking(value,inVOnce=!1){isBlockTreeEnabled+=value,value<0&¤tBlock&&inVOnce&&(currentBlock.hasOnce=!0)}function setupBlock(vnode){return vnode.dynamicChildren=isBlockTreeEnabled>0?currentBlock||EMPTY_ARR:null,closeBlock(),isBlockTreeEnabled>0&¤tBlock&¤tBlock.push(vnode),vnode}function createElementBlock(type,props,children,patchFlag,dynamicProps,shapeFlag){return setupBlock(createBaseVNode(type,props,children,patchFlag,dynamicProps,shapeFlag,!0))}function createBlock(type,props,children,patchFlag,dynamicProps){return setupBlock(createVNode(type,props,children,patchFlag,dynamicProps,!0))}function isVNode(value){return value?value.__v_isVNode===!0:!1}function isSameVNodeType(n1,n2){return n1.type===n2.type&&n1.key===n2.key}function transformVNodeArgs(transformer){}var normalizeKey=({key})=>key??null,normalizeRef=({ref:ref$1,ref_key,ref_for})=>(typeof ref$1==`number`&&(ref$1=``+ref$1),ref$1==null?null:isString$1(ref$1)||isRef(ref$1)||isFunction$1(ref$1)?{i:currentRenderingInstance,r:ref$1,k:ref_key,f:!!ref_for}:ref$1);function createBaseVNode(type,props=null,children=null,patchFlag=0,dynamicProps=null,shapeFlag=type===Fragment?0:1,isBlockNode=!1,needFullChildrenNormalization=!1){let vnode={__v_isVNode:!0,__v_skip:!0,type,props,key:props&&normalizeKey(props),ref:props&&normalizeRef(props),scopeId:currentScopeId,slotScopeIds:null,children,component:null,suspense:null,ssContent:null,ssFallback:null,dirs:null,transition:null,el:null,anchor:null,target:null,targetStart:null,targetAnchor:null,staticCount:0,shapeFlag,patchFlag,dynamicProps,dynamicChildren:null,appContext:null,ctx:currentRenderingInstance};return needFullChildrenNormalization?(normalizeChildren(vnode,children),shapeFlag&128&&type.normalize(vnode)):children&&(vnode.shapeFlag|=isString$1(children)?8:16),isBlockTreeEnabled>0&&!isBlockNode&¤tBlock&&(vnode.patchFlag>0||shapeFlag&6)&&vnode.patchFlag!==32&¤tBlock.push(vnode),vnode}var createVNode=_createVNode;function _createVNode(type,props=null,children=null,patchFlag=0,dynamicProps=null,isBlockNode=!1){if((!type||type===NULL_DYNAMIC_COMPONENT)&&(type=Comment),isVNode(type)){let cloned=cloneVNode(type,props,!0);return children&&normalizeChildren(cloned,children),isBlockTreeEnabled>0&&!isBlockNode&¤tBlock&&(cloned.shapeFlag&6?currentBlock[currentBlock.indexOf(type)]=cloned:currentBlock.push(cloned)),cloned.patchFlag=-2,cloned}if(isClassComponent(type)&&(type=type.__vccOpts),props){props=guardReactiveProps(props);let{class:klass,style}=props;klass&&!isString$1(klass)&&(props.class=normalizeClass(klass)),isObject$1(style)&&(isProxy(style)&&!isArray$2(style)&&(style=extend({},style)),props.style=normalizeStyle(style))}let shapeFlag=isString$1(type)?1:isSuspense(type)?128:isTeleport(type)?64:isObject$1(type)?4:isFunction$1(type)?2:0;return createBaseVNode(type,props,children,patchFlag,dynamicProps,shapeFlag,isBlockNode,!0)}function guardReactiveProps(props){return props?isProxy(props)||isInternalObject(props)?extend({},props):props:null}function cloneVNode(vnode,extraProps,mergeRef=!1,cloneTransition=!1){let{props,ref:ref$1,patchFlag,children,transition}=vnode,mergedProps=extraProps?mergeProps(props||{},extraProps):props,cloned={__v_isVNode:!0,__v_skip:!0,type:vnode.type,props:mergedProps,key:mergedProps&&normalizeKey(mergedProps),ref:extraProps&&extraProps.ref?mergeRef&&ref$1?isArray$2(ref$1)?ref$1.concat(normalizeRef(extraProps)):[ref$1,normalizeRef(extraProps)]:normalizeRef(extraProps):ref$1,scopeId:vnode.scopeId,slotScopeIds:vnode.slotScopeIds,children,target:vnode.target,targetStart:vnode.targetStart,targetAnchor:vnode.targetAnchor,staticCount:vnode.staticCount,shapeFlag:vnode.shapeFlag,patchFlag:extraProps&&vnode.type!==Fragment?patchFlag===-1?16:patchFlag|16:patchFlag,dynamicProps:vnode.dynamicProps,dynamicChildren:vnode.dynamicChildren,appContext:vnode.appContext,dirs:vnode.dirs,transition,component:vnode.component,suspense:vnode.suspense,ssContent:vnode.ssContent&&cloneVNode(vnode.ssContent),ssFallback:vnode.ssFallback&&cloneVNode(vnode.ssFallback),placeholder:vnode.placeholder,el:vnode.el,anchor:vnode.anchor,ctx:vnode.ctx,ce:vnode.ce};return transition&&cloneTransition&&setTransitionHooks(cloned,transition.clone(cloned)),cloned}function createTextVNode(text=` `,flag=0){return createVNode(Text,null,text,flag)}function createStaticVNode(content,numberOfNodes){let vnode=createVNode(Static,null,content);return vnode.staticCount=numberOfNodes,vnode}function createCommentVNode(text=``,asBlock=!1){return asBlock?(openBlock(),createBlock(Comment,null,text)):createVNode(Comment,null,text)}function normalizeVNode(child){return child==null||typeof child==`boolean`?createVNode(Comment):isArray$2(child)?createVNode(Fragment,null,child.slice()):isVNode(child)?cloneIfMounted(child):createVNode(Text,null,String(child))}function cloneIfMounted(child){return child.el===null&&child.patchFlag!==-1||child.memo?child:cloneVNode(child)}function normalizeChildren(vnode,children){let type=0,{shapeFlag}=vnode;if(children==null)children=null;else if(isArray$2(children))type=16;else if(typeof children==`object`)if(shapeFlag&65){let slot=children.default;slot&&(slot._c&&(slot._d=!1),normalizeChildren(vnode,slot()),slot._c&&(slot._d=!0));return}else{type=32;let slotFlag=children._;!slotFlag&&!isInternalObject(children)?children._ctx=currentRenderingInstance:slotFlag===3&¤tRenderingInstance&&(currentRenderingInstance.slots._===1?children._=1:(children._=2,vnode.patchFlag|=1024))}else isFunction$1(children)?(children={default:children,_ctx:currentRenderingInstance},type=32):(children=String(children),shapeFlag&64?(type=16,children=[createTextVNode(children)]):type=8);vnode.children=children,vnode.shapeFlag|=type}function mergeProps(...args){let ret={};for(let i=0;icurrentInstance||currentRenderingInstance,internalSetCurrentInstance,setInSSRSetupState;{let g=getGlobalThis$1(),registerGlobalSetter=(key,setter)=>{let setters;return(setters=g[key])||(setters=g[key]=[]),setters.push(setter),v=>{setters.length>1?setters.forEach(set=>set(v)):setters[0](v)}};internalSetCurrentInstance=registerGlobalSetter(`__VUE_INSTANCE_SETTERS__`,v=>currentInstance=v),setInSSRSetupState=registerGlobalSetter(`__VUE_SSR_SETTERS__`,v=>isInSSRComponentSetup=v)}var setCurrentInstance=instance$1=>{let prev=currentInstance;return internalSetCurrentInstance(instance$1),instance$1.scope.on(),()=>{instance$1.scope.off(),internalSetCurrentInstance(prev)}},unsetCurrentInstance=()=>{currentInstance&¤tInstance.scope.off(),internalSetCurrentInstance(null)};function isStatefulComponent(instance$1){return instance$1.vnode.shapeFlag&4}var isInSSRComponentSetup=!1;function setupComponent(instance$1,isSSR=!1,optimized=!1){isSSR&&setInSSRSetupState(isSSR);let{props,children}=instance$1.vnode,isStateful=isStatefulComponent(instance$1);initProps(instance$1,props,isStateful,isSSR),initSlots(instance$1,children,optimized||isSSR);let setupResult=isStateful?setupStatefulComponent(instance$1,isSSR):void 0;return isSSR&&setInSSRSetupState(!1),setupResult}function setupStatefulComponent(instance$1,isSSR){let Component=instance$1.type;instance$1.accessCache=Object.create(null),instance$1.proxy=new Proxy(instance$1.ctx,PublicInstanceProxyHandlers);let{setup:setup$3}=Component;if(setup$3){pauseTracking();let setupContext=instance$1.setupContext=setup$3.length>1?createSetupContext(instance$1):null,reset$1=setCurrentInstance(instance$1),setupResult=callWithErrorHandling(setup$3,instance$1,0,[instance$1.props,setupContext]),isAsyncSetup=isPromise$1(setupResult);if(resetTracking(),reset$1(),(isAsyncSetup||instance$1.sp)&&!isAsyncWrapper(instance$1)&&markAsyncBoundary(instance$1),isAsyncSetup){if(setupResult.then(unsetCurrentInstance,unsetCurrentInstance),isSSR)return setupResult.then(resolvedResult=>{handleSetupResult(instance$1,resolvedResult,isSSR)}).catch(e=>{handleError(e,instance$1,0)});instance$1.asyncDep=setupResult}else handleSetupResult(instance$1,setupResult,isSSR)}else finishComponentSetup(instance$1,isSSR)}function handleSetupResult(instance$1,setupResult,isSSR){isFunction$1(setupResult)?instance$1.type.__ssrInlineRender?instance$1.ssrRender=setupResult:instance$1.render=setupResult:isObject$1(setupResult)&&(instance$1.setupState=proxyRefs(setupResult)),finishComponentSetup(instance$1,isSSR)}var compile$2,installWithProxy;function registerRuntimeCompiler(_compile){compile$2=_compile,installWithProxy=i=>{i.render._rc&&(i.withProxy=new Proxy(i.ctx,RuntimeCompiledPublicInstanceProxyHandlers))}}var isRuntimeOnly=()=>!compile$2;function finishComponentSetup(instance$1,isSSR,skipOptions){let Component=instance$1.type;if(!instance$1.render){if(!isSSR&&compile$2&&!Component.render){let template=Component.template||resolveMergedOptions(instance$1).template;if(template){let{isCustomElement,compilerOptions}=instance$1.appContext.config,{delimiters,compilerOptions:componentCompilerOptions}=Component,finalCompilerOptions=extend(extend({isCustomElement,delimiters},compilerOptions),componentCompilerOptions);Component.render=compile$2(template,finalCompilerOptions)}}instance$1.render=Component.render||NOOP,installWithProxy&&installWithProxy(instance$1)}{let reset$1=setCurrentInstance(instance$1);pauseTracking();try{applyOptions$1(instance$1)}finally{resetTracking(),reset$1()}}}var attrsProxyHandlers={get(target,key){return track(target,`get`,``),target[key]}};function createSetupContext(instance$1){return{attrs:new Proxy(instance$1.attrs,attrsProxyHandlers),slots:instance$1.slots,emit:instance$1.emit,expose:exposed=>{instance$1.exposed=exposed||{}}}}function getComponentPublicInstance(instance$1){return instance$1.exposed?instance$1.exposeProxy||=new Proxy(proxyRefs(markRaw(instance$1.exposed)),{get(target,key){if(key in target)return target[key];if(key in publicPropertiesMap)return publicPropertiesMap[key](instance$1)},has(target,key){return key in target||key in publicPropertiesMap}}):instance$1.proxy}function getComponentName(Component,includeInferred=!0){return isFunction$1(Component)?Component.displayName||Component.name:Component.name||includeInferred&&Component.__name}function isClassComponent(value){return isFunction$1(value)&&`__vccOpts`in value}var computed=(getterOrOptions,debugOptions)=>computed$1(getterOrOptions,debugOptions,isInSSRComponentSetup);function h(type,propsOrChildren,children){try{setBlockTracking(-1);let l=arguments.length;return l===2?isObject$1(propsOrChildren)&&!isArray$2(propsOrChildren)?isVNode(propsOrChildren)?createVNode(type,null,[propsOrChildren]):createVNode(type,propsOrChildren):createVNode(type,null,propsOrChildren):(l>3?children=Array.prototype.slice.call(arguments,2):l===3&&isVNode(children)&&(children=[children]),createVNode(type,propsOrChildren,children))}finally{setBlockTracking(1)}}function initCustomFormatter(){return;function isKeyOfType(Comp,key,type){let opts=Comp[type];if(isArray$2(opts)&&opts.includes(key)||isObject$1(opts)&&key in opts||Comp.extends&&isKeyOfType(Comp.extends,key,type)||Comp.mixins&&Comp.mixins.some(m=>isKeyOfType(m,key,type)))return!0}}function withMemo(memo,render$1,cache$1,index){let cached=cache$1[index];if(cached&&isMemoSame(cached,memo))return cached;let ret=render$1();return ret.memo=memo.slice(),ret.cacheIndex=index,cache$1[index]=ret}function isMemoSame(cached,memo){let prev=cached.memo;if(prev.length!=memo.length)return!1;for(let i=0;i0&¤tBlock&¤tBlock.push(cached),!0}var version$1=`3.5.22`,warn$2=NOOP,ErrorTypeStrings=ErrorTypeStrings$1,devtools$2=devtools$1,setDevtoolsHook=setDevtoolsHook$1,ssrUtils={createComponentInstance,setupComponent,renderComponentRoot,setCurrentRenderingInstance,isVNode,normalizeVNode,getComponentPublicInstance,ensureValidVNode,pushWarningContext,popWarningContext},resolveFilter=null,compatUtils=null,DeprecationTypes=null,runtime_dom_esm_bundler_exports=__export({BaseTransition:()=>BaseTransition,BaseTransitionPropsValidators:()=>BaseTransitionPropsValidators,Comment:()=>Comment,DeprecationTypes:()=>null,EffectScope:()=>EffectScope,ErrorCodes:()=>ErrorCodes,ErrorTypeStrings:()=>ErrorTypeStrings,Fragment:()=>Fragment,KeepAlive:()=>KeepAlive,ReactiveEffect:()=>ReactiveEffect,Static:()=>Static,Suspense:()=>Suspense,Teleport:()=>Teleport,Text:()=>Text,TrackOpTypes:()=>TrackOpTypes,Transition:()=>Transition,TransitionGroup:()=>TransitionGroup,TriggerOpTypes:()=>TriggerOpTypes,VueElement:()=>VueElement,assertNumber:()=>assertNumber,callWithAsyncErrorHandling:()=>callWithAsyncErrorHandling,callWithErrorHandling:()=>callWithErrorHandling,camelize:()=>camelize,capitalize:()=>capitalize$1,cloneVNode:()=>cloneVNode,compatUtils:()=>null,computed:()=>computed,createApp:()=>createApp,createBlock:()=>createBlock,createCommentVNode:()=>createCommentVNode,createElementBlock:()=>createElementBlock,createElementVNode:()=>createBaseVNode,createHydrationRenderer:()=>createHydrationRenderer,createPropsRestProxy:()=>createPropsRestProxy,createRenderer:()=>createRenderer,createSSRApp:()=>createSSRApp,createSlots:()=>createSlots,createStaticVNode:()=>createStaticVNode,createTextVNode:()=>createTextVNode,createVNode:()=>createVNode,customRef:()=>customRef,defineAsyncComponent:()=>defineAsyncComponent,defineComponent:()=>defineComponent,defineCustomElement:()=>defineCustomElement,defineEmits:()=>defineEmits,defineExpose:()=>defineExpose,defineModel:()=>defineModel,defineOptions:()=>defineOptions,defineProps:()=>defineProps,defineSSRCustomElement:()=>defineSSRCustomElement,defineSlots:()=>defineSlots,devtools:()=>devtools$2,effect:()=>effect,effectScope:()=>effectScope,getCurrentInstance:()=>getCurrentInstance,getCurrentScope:()=>getCurrentScope,getCurrentWatcher:()=>getCurrentWatcher,getTransitionRawChildren:()=>getTransitionRawChildren,guardReactiveProps:()=>guardReactiveProps,h:()=>h,handleError:()=>handleError,hasInjectionContext:()=>hasInjectionContext,hydrate:()=>hydrate,hydrateOnIdle:()=>hydrateOnIdle,hydrateOnInteraction:()=>hydrateOnInteraction,hydrateOnMediaQuery:()=>hydrateOnMediaQuery,hydrateOnVisible:()=>hydrateOnVisible,initCustomFormatter:()=>initCustomFormatter,initDirectivesForSSR:()=>initDirectivesForSSR,inject:()=>inject,isMemoSame:()=>isMemoSame,isProxy:()=>isProxy,isReactive:()=>isReactive,isReadonly:()=>isReadonly,isRef:()=>isRef,isRuntimeOnly:()=>isRuntimeOnly,isShallow:()=>isShallow,isVNode:()=>isVNode,markRaw:()=>markRaw,mergeDefaults:()=>mergeDefaults,mergeModels:()=>mergeModels,mergeProps:()=>mergeProps,nextTick:()=>nextTick,normalizeClass:()=>normalizeClass,normalizeProps:()=>normalizeProps,normalizeStyle:()=>normalizeStyle,onActivated:()=>onActivated,onBeforeMount:()=>onBeforeMount,onBeforeUnmount:()=>onBeforeUnmount,onBeforeUpdate:()=>onBeforeUpdate,onDeactivated:()=>onDeactivated,onErrorCaptured:()=>onErrorCaptured,onMounted:()=>onMounted,onRenderTracked:()=>onRenderTracked,onRenderTriggered:()=>onRenderTriggered,onScopeDispose:()=>onScopeDispose,onServerPrefetch:()=>onServerPrefetch,onUnmounted:()=>onUnmounted,onUpdated:()=>onUpdated,onWatcherCleanup:()=>onWatcherCleanup,openBlock:()=>openBlock,popScopeId:()=>popScopeId,provide:()=>provide,proxyRefs:()=>proxyRefs,pushScopeId:()=>pushScopeId,queuePostFlushCb:()=>queuePostFlushCb,reactive:()=>reactive,readonly:()=>readonly,ref:()=>ref,registerRuntimeCompiler:()=>registerRuntimeCompiler,render:()=>render,renderList:()=>renderList,renderSlot:()=>renderSlot,resolveComponent:()=>resolveComponent,resolveDirective:()=>resolveDirective,resolveDynamicComponent:()=>resolveDynamicComponent,resolveFilter:()=>null,resolveTransitionHooks:()=>resolveTransitionHooks,setBlockTracking:()=>setBlockTracking,setDevtoolsHook:()=>setDevtoolsHook,setTransitionHooks:()=>setTransitionHooks,shallowReactive:()=>shallowReactive,shallowReadonly:()=>shallowReadonly,shallowRef:()=>shallowRef,ssrContextKey:()=>ssrContextKey,ssrUtils:()=>ssrUtils,stop:()=>stop,toDisplayString:()=>toDisplayString,toHandlerKey:()=>toHandlerKey,toHandlers:()=>toHandlers,toRaw:()=>toRaw,toRef:()=>toRef,toRefs:()=>toRefs,toValue:()=>toValue$1,transformVNodeArgs:()=>transformVNodeArgs,triggerRef:()=>triggerRef,unref:()=>unref,useAttrs:()=>useAttrs,useCssModule:()=>useCssModule,useCssVars:()=>useCssVars,useHost:()=>useHost,useId:()=>useId,useModel:()=>useModel,useSSRContext:()=>useSSRContext,useShadowRoot:()=>useShadowRoot,useSlots:()=>useSlots,useTemplateRef:()=>useTemplateRef,useTransitionState:()=>useTransitionState,vModelCheckbox:()=>vModelCheckbox,vModelDynamic:()=>vModelDynamic,vModelRadio:()=>vModelRadio,vModelSelect:()=>vModelSelect,vModelText:()=>vModelText,vShow:()=>vShow,version:()=>version$1,warn:()=>warn$2,watch:()=>watch,watchEffect:()=>watchEffect,watchPostEffect:()=>watchPostEffect,watchSyncEffect:()=>watchSyncEffect,withAsyncContext:()=>withAsyncContext,withCtx:()=>withCtx,withDefaults:()=>withDefaults,withDirectives:()=>withDirectives,withKeys:()=>withKeys,withMemo:()=>withMemo,withModifiers:()=>withModifiers,withScopeId:()=>withScopeId}),policy=void 0,tt=typeof window<`u`&&window.trustedTypes;if(tt)try{policy=tt.createPolicy(`vue`,{createHTML:val=>val})}catch{}var unsafeToTrustedHTML=policy?val=>policy.createHTML(val):val=>val,svgNS=`http://www.w3.org/2000/svg`,mathmlNS=`http://www.w3.org/1998/Math/MathML`,doc=typeof document<`u`?document:null,templateContainer=doc&&doc.createElement(`template`),nodeOps={insert:(child,parent,anchor)=>{parent.insertBefore(child,anchor||null)},remove:child=>{let parent=child.parentNode;parent&&parent.removeChild(child)},createElement:(tag,namespace,is,props)=>{let el=namespace===`svg`?doc.createElementNS(svgNS,tag):namespace===`mathml`?doc.createElementNS(mathmlNS,tag):is?doc.createElement(tag,{is}):doc.createElement(tag);return tag===`select`&&props&&props.multiple!=null&&el.setAttribute(`multiple`,props.multiple),el},createText:text=>doc.createTextNode(text),createComment:text=>doc.createComment(text),setText:(node,text)=>{node.nodeValue=text},setElementText:(el,text)=>{el.textContent=text},parentNode:node=>node.parentNode,nextSibling:node=>node.nextSibling,querySelector:selector=>doc.querySelector(selector),setScopeId(el,id){el.setAttribute(id,``)},insertStaticContent(content,parent,anchor,namespace,start,end){let before=anchor?anchor.previousSibling:parent.lastChild;if(start&&(start===end||start.nextSibling))for(;parent.insertBefore(start.cloneNode(!0),anchor),!(start===end||!(start=start.nextSibling)););else{templateContainer.innerHTML=unsafeToTrustedHTML(namespace===`svg`?`${content}`:namespace===`mathml`?`${content}`:content);let template=templateContainer.content;if(namespace===`svg`||namespace===`mathml`){let wrapper=template.firstChild;for(;wrapper.firstChild;)template.appendChild(wrapper.firstChild);template.removeChild(wrapper)}parent.insertBefore(template,anchor)}return[before?before.nextSibling:parent.firstChild,anchor?anchor.previousSibling:parent.lastChild]}},TRANSITION$1=`transition`,ANIMATION=`animation`,vtcKey=Symbol(`_vtc`),DOMTransitionPropsValidators={name:String,type:String,css:{type:Boolean,default:!0},duration:[String,Number,Object],enterFromClass:String,enterActiveClass:String,enterToClass:String,appearFromClass:String,appearActiveClass:String,appearToClass:String,leaveFromClass:String,leaveActiveClass:String,leaveToClass:String},TransitionPropsValidators=extend({},BaseTransitionPropsValidators,DOMTransitionPropsValidators),decorate$1=t=>(t.displayName=`Transition`,t.props=TransitionPropsValidators,t),Transition=decorate$1((props,{slots})=>h(BaseTransition,resolveTransitionProps(props),slots)),callHook=(hook,args=[])=>{isArray$2(hook)?hook.forEach(h2=>h2(...args)):hook&&hook(...args)},hasExplicitCallback=hook=>hook?isArray$2(hook)?hook.some(h2=>h2.length>1):hook.length>1:!1;function resolveTransitionProps(rawProps){let baseProps={};for(let key in rawProps)key in DOMTransitionPropsValidators||(baseProps[key]=rawProps[key]);if(rawProps.css===!1)return baseProps;let{name=`v`,type,duration,enterFromClass=`${name}-enter-from`,enterActiveClass=`${name}-enter-active`,enterToClass=`${name}-enter-to`,appearFromClass=enterFromClass,appearActiveClass=enterActiveClass,appearToClass=enterToClass,leaveFromClass=`${name}-leave-from`,leaveActiveClass=`${name}-leave-active`,leaveToClass=`${name}-leave-to`}=rawProps,durations=normalizeDuration(duration),enterDuration=durations&&durations[0],leaveDuration=durations&&durations[1],{onBeforeEnter,onEnter,onEnterCancelled,onLeave,onLeaveCancelled,onBeforeAppear=onBeforeEnter,onAppear=onEnter,onAppearCancelled=onEnterCancelled}=baseProps,finishEnter=(el,isAppear,done,isCancelled)=>{el._enterCancelled=isCancelled,removeTransitionClass(el,isAppear?appearToClass:enterToClass),removeTransitionClass(el,isAppear?appearActiveClass:enterActiveClass),done&&done()},finishLeave=(el,done)=>{el._isLeaving=!1,removeTransitionClass(el,leaveFromClass),removeTransitionClass(el,leaveToClass),removeTransitionClass(el,leaveActiveClass),done&&done()},makeEnterHook=isAppear=>(el,done)=>{let hook=isAppear?onAppear:onEnter,resolve$1=()=>finishEnter(el,isAppear,done);callHook(hook,[el,resolve$1]),nextFrame(()=>{removeTransitionClass(el,isAppear?appearFromClass:enterFromClass),addTransitionClass(el,isAppear?appearToClass:enterToClass),hasExplicitCallback(hook)||whenTransitionEnds(el,type,enterDuration,resolve$1)})};return extend(baseProps,{onBeforeEnter(el){callHook(onBeforeEnter,[el]),addTransitionClass(el,enterFromClass),addTransitionClass(el,enterActiveClass)},onBeforeAppear(el){callHook(onBeforeAppear,[el]),addTransitionClass(el,appearFromClass),addTransitionClass(el,appearActiveClass)},onEnter:makeEnterHook(!1),onAppear:makeEnterHook(!0),onLeave(el,done){el._isLeaving=!0;let resolve$1=()=>finishLeave(el,done);addTransitionClass(el,leaveFromClass),el._enterCancelled?(addTransitionClass(el,leaveActiveClass),forceReflow(el)):(forceReflow(el),addTransitionClass(el,leaveActiveClass)),nextFrame(()=>{el._isLeaving&&(removeTransitionClass(el,leaveFromClass),addTransitionClass(el,leaveToClass),hasExplicitCallback(onLeave)||whenTransitionEnds(el,type,leaveDuration,resolve$1))}),callHook(onLeave,[el,resolve$1])},onEnterCancelled(el){finishEnter(el,!1,void 0,!0),callHook(onEnterCancelled,[el])},onAppearCancelled(el){finishEnter(el,!0,void 0,!0),callHook(onAppearCancelled,[el])},onLeaveCancelled(el){finishLeave(el),callHook(onLeaveCancelled,[el])}})}function normalizeDuration(duration){if(duration==null)return null;if(isObject$1(duration))return[NumberOf(duration.enter),NumberOf(duration.leave)];{let n=NumberOf(duration);return[n,n]}}function NumberOf(val){return toNumber(val)}function addTransitionClass(el,cls){cls.split(/\s+/).forEach(c=>c&&el.classList.add(c)),(el[vtcKey]||(el[vtcKey]=new Set)).add(cls)}function removeTransitionClass(el,cls){cls.split(/\s+/).forEach(c=>c&&el.classList.remove(c));let _vtc=el[vtcKey];_vtc&&(_vtc.delete(cls),_vtc.size||(el[vtcKey]=void 0))}function nextFrame(cb){requestAnimationFrame(()=>{requestAnimationFrame(cb)})}var endId=0;function whenTransitionEnds(el,expectedType,explicitTimeout,resolve$1){let id=el._endId=++endId,resolveIfNotStale=()=>{id===el._endId&&resolve$1()};if(explicitTimeout!=null)return setTimeout(resolveIfNotStale,explicitTimeout);let{type,timeout,propCount}=getTransitionInfo(el,expectedType);if(!type)return resolve$1();let endEvent=type+`end`,ended=0,end=()=>{el.removeEventListener(endEvent,onEnd),resolveIfNotStale()},onEnd=e=>{e.target===el&&++ended>=propCount&&end()};setTimeout(()=>{ended(styles[key]||``).split(`, `),transitionDelays=getStyleProperties(`${TRANSITION$1}Delay`),transitionDurations=getStyleProperties(`${TRANSITION$1}Duration`),transitionTimeout=getTimeout(transitionDelays,transitionDurations),animationDelays=getStyleProperties(`${ANIMATION}Delay`),animationDurations=getStyleProperties(`${ANIMATION}Duration`),animationTimeout=getTimeout(animationDelays,animationDurations),type=null,timeout=0,propCount=0;expectedType===TRANSITION$1?transitionTimeout>0&&(type=TRANSITION$1,timeout=transitionTimeout,propCount=transitionDurations.length):expectedType===ANIMATION?animationTimeout>0&&(type=ANIMATION,timeout=animationTimeout,propCount=animationDurations.length):(timeout=Math.max(transitionTimeout,animationTimeout),type=timeout>0?transitionTimeout>animationTimeout?TRANSITION$1:ANIMATION:null,propCount=type?type===TRANSITION$1?transitionDurations.length:animationDurations.length:0);let hasTransform=type===TRANSITION$1&&/\b(?:transform|all)(?:,|$)/.test(getStyleProperties(`${TRANSITION$1}Property`).toString());return{type,timeout,propCount,hasTransform}}function getTimeout(delays,durations){for(;delays.lengthtoMs(d)+toMs(delays[i])))}function toMs(s){return s===`auto`?0:Number(s.slice(0,-1).replace(`,`,`.`))*1e3}function forceReflow(el){return(el?el.ownerDocument:document).body.offsetHeight}function patchClass(el,value,isSVG){let transitionClasses=el[vtcKey];transitionClasses&&(value=(value?[value,...transitionClasses]:[...transitionClasses]).join(` `)),value==null?el.removeAttribute(`class`):isSVG?el.setAttribute(`class`,value):el.className=value}var vShowOriginalDisplay=Symbol(`_vod`),vShowHidden=Symbol(`_vsh`),vShow={name:`show`,beforeMount(el,{value},{transition}){el[vShowOriginalDisplay]=el.style.display===`none`?``:el.style.display,transition&&value?transition.beforeEnter(el):setDisplay(el,value)},mounted(el,{value},{transition}){transition&&value&&transition.enter(el)},updated(el,{value,oldValue},{transition}){!value!=!oldValue&&(transition?value?(transition.beforeEnter(el),setDisplay(el,!0),transition.enter(el)):transition.leave(el,()=>{setDisplay(el,!1)}):setDisplay(el,value))},beforeUnmount(el,{value}){setDisplay(el,value)}};function setDisplay(el,value){el.style.display=value?el[vShowOriginalDisplay]:`none`,el[vShowHidden]=!value}function initVShowForSSR(){vShow.getSSRProps=({value})=>{if(!value)return{style:{display:`none`}}}}var CSS_VAR_TEXT=Symbol(``);function useCssVars(getter){let instance$1=getCurrentInstance();if(!instance$1)return;let updateTeleports=instance$1.ut=(vars=getter(instance$1.proxy))=>{Array.from(document.querySelectorAll(`[data-v-owner="${instance$1.uid}"]`)).forEach(node=>setVarsOnNode(node,vars))},setVars=()=>{let vars=getter(instance$1.proxy);instance$1.ce?setVarsOnNode(instance$1.ce,vars):setVarsOnVNode(instance$1.subTree,vars),updateTeleports(vars)};onBeforeUpdate(()=>{queuePostFlushCb(setVars)}),onMounted(()=>{watch(setVars,NOOP,{flush:`post`});let ob=new MutationObserver(setVars);ob.observe(instance$1.subTree.el.parentNode,{childList:!0}),onUnmounted(()=>ob.disconnect())})}function setVarsOnVNode(vnode,vars){if(vnode.shapeFlag&128){let suspense=vnode.suspense;vnode=suspense.activeBranch,suspense.pendingBranch&&!suspense.isHydrating&&suspense.effects.push(()=>{setVarsOnVNode(suspense.activeBranch,vars)})}for(;vnode.component;)vnode=vnode.component.subTree;if(vnode.shapeFlag&1&&vnode.el)setVarsOnNode(vnode.el,vars);else if(vnode.type===Fragment)vnode.children.forEach(c=>setVarsOnVNode(c,vars));else if(vnode.type===Static){let{el,anchor}=vnode;for(;el&&(setVarsOnNode(el,vars),el!==anchor);)el=el.nextSibling}}function setVarsOnNode(el,vars){if(el.nodeType===1){let style=el.style,cssText=``;for(let key in vars){let value=normalizeCssVarValue(vars[key]);style.setProperty(`--${key}`,value),cssText+=`--${key}: ${value};`}style[CSS_VAR_TEXT]=cssText}}var displayRE=/(?:^|;)\s*display\s*:/;function patchStyle(el,prev,next){let style=el.style,isCssString=isString$1(next),hasControlledDisplay=!1;if(next&&!isCssString){if(prev)if(isString$1(prev))for(let prevStyle of prev.split(`;`)){let key=prevStyle.slice(0,prevStyle.indexOf(`:`)).trim();next[key]??setStyle(style,key,``)}else for(let key in prev)next[key]??setStyle(style,key,``);for(let key in next)key===`display`&&(hasControlledDisplay=!0),setStyle(style,key,next[key])}else if(isCssString){if(prev!==next){let cssVarText=style[CSS_VAR_TEXT];cssVarText&&(next+=`;`+cssVarText),style.cssText=next,hasControlledDisplay=displayRE.test(next)}}else prev&&el.removeAttribute(`style`);vShowOriginalDisplay in el&&(el[vShowOriginalDisplay]=hasControlledDisplay?style.display:``,el[vShowHidden]&&(style.display=`none`))}var importantRE=/\s*!important$/;function setStyle(style,name,val){if(isArray$2(val))val.forEach(v=>setStyle(style,name,v));else if(val??=``,name.startsWith(`--`))style.setProperty(name,val);else{let prefixed=autoPrefix(style,name);importantRE.test(val)?style.setProperty(hyphenate(prefixed),val.replace(importantRE,``),`important`):style[prefixed]=val}}var prefixes=[`Webkit`,`Moz`,`ms`],prefixCache={};function autoPrefix(style,rawName){let cached=prefixCache[rawName];if(cached)return cached;let name=camelize(rawName);if(name!==`filter`&&name in style)return prefixCache[rawName]=name;name=capitalize$1(name);for(let i=0;icachedNow||=(p.then(()=>cachedNow=0),Date.now());function createInvoker(initialValue,instance$1){let invoker=e=>{if(!e._vts)e._vts=Date.now();else if(e._vts<=invoker.attached)return;callWithAsyncErrorHandling(patchStopImmediatePropagation(e,invoker.value),instance$1,5,[e])};return invoker.value=initialValue,invoker.attached=getNow(),invoker}function patchStopImmediatePropagation(e,value){if(isArray$2(value)){let originalStop=e.stopImmediatePropagation;return e.stopImmediatePropagation=()=>{originalStop.call(e),e._stopped=!0},value.map(fn=>e2=>!e2._stopped&&fn&&fn(e2))}else return value}var isNativeOn=key=>key.charCodeAt(0)===111&&key.charCodeAt(1)===110&&key.charCodeAt(2)>96&&key.charCodeAt(2)<123,patchProp=(el,key,prevValue,nextValue,namespace,parentComponent)=>{let isSVG=namespace===`svg`;key===`class`?patchClass(el,nextValue,isSVG):key===`style`?patchStyle(el,prevValue,nextValue):isOn(key)?isModelListener(key)||patchEvent(el,key,prevValue,nextValue,parentComponent):(key[0]===`.`?(key=key.slice(1),!0):key[0]===`^`?(key=key.slice(1),!1):shouldSetAsProp(el,key,nextValue,isSVG))?(patchDOMProp(el,key,nextValue),!el.tagName.includes(`-`)&&(key===`value`||key===`checked`||key===`selected`)&&patchAttr(el,key,nextValue,isSVG,parentComponent,key!==`value`)):el._isVueCE&&(/[A-Z]/.test(key)||!isString$1(nextValue))?patchDOMProp(el,camelize(key),nextValue,parentComponent,key):(key===`true-value`?el._trueValue=nextValue:key===`false-value`&&(el._falseValue=nextValue),patchAttr(el,key,nextValue,isSVG))};function shouldSetAsProp(el,key,value,isSVG){if(isSVG)return!!(key===`innerHTML`||key===`textContent`||key in el&&isNativeOn(key)&&isFunction$1(value));if(key===`spellcheck`||key===`draggable`||key===`translate`||key===`autocorrect`||key===`form`||key===`list`&&el.tagName===`INPUT`||key===`type`&&el.tagName===`TEXTAREA`)return!1;if(key===`width`||key===`height`){let tag=el.tagName;if(tag===`IMG`||tag===`VIDEO`||tag===`CANVAS`||tag===`SOURCE`)return!1}return isNativeOn(key)&&isString$1(value)?!1:key in el}var REMOVAL={};function defineCustomElement(options,extraOptions,_createApp){let Comp=defineComponent(options,extraOptions);isPlainObject$2(Comp)&&(Comp=extend({},Comp,extraOptions));class VueCustomElement extends VueElement{constructor(initialProps){super(Comp,initialProps,_createApp)}}return VueCustomElement.def=Comp,VueCustomElement}var defineSSRCustomElement=((options,extraOptions)=>defineCustomElement(options,extraOptions,createSSRApp)),BaseClass=typeof HTMLElement<`u`?HTMLElement:class{},VueElement=class VueElement extends BaseClass{constructor(_def,_props={},_createApp=createApp){super(),this._def=_def,this._props=_props,this._createApp=_createApp,this._isVueCE=!0,this._instance=null,this._app=null,this._nonce=this._def.nonce,this._connected=!1,this._resolved=!1,this._numberProps=null,this._styleChildren=new WeakSet,this._ob=null,this.shadowRoot&&_createApp!==createApp?this._root=this.shadowRoot:_def.shadowRoot===!1?this._root=this:(this.attachShadow(extend({},_def.shadowRootOptions,{mode:`open`})),this._root=this.shadowRoot)}connectedCallback(){if(!this.isConnected)return;!this.shadowRoot&&!this._resolved&&this._parseSlots(),this._connected=!0;let parent=this;for(;parent&&=parent.parentNode||parent.host;)if(parent instanceof VueElement){this._parent=parent;break}this._instance||(this._resolved?this._mount(this._def):parent&&parent._pendingResolve?this._pendingResolve=parent._pendingResolve.then(()=>{this._pendingResolve=void 0,this._resolveDef()}):this._resolveDef())}_setParent(parent=this._parent){parent&&(this._instance.parent=parent._instance,this._inheritParentContext(parent))}_inheritParentContext(parent=this._parent){parent&&this._app&&Object.setPrototypeOf(this._app._context.provides,parent._instance.provides)}disconnectedCallback(){this._connected=!1,nextTick(()=>{this._connected||(this._ob&&=(this._ob.disconnect(),null),this._app&&this._app.unmount(),this._instance&&(this._instance.ce=void 0),this._app=this._instance=null,this._teleportTargets&&=(this._teleportTargets.clear(),void 0))})}_processMutations(mutations){for(let m of mutations)this._setAttr(m.attributeName)}_resolveDef(){if(this._pendingResolve)return;for(let i=0;i{this._resolved=!0,this._pendingResolve=void 0;let{props,styles}=def$1,numberProps;if(props&&!isArray$2(props))for(let key in props){let opt=props[key];(opt===Number||opt&&opt.type===Number)&&(key in this._props&&(this._props[key]=toNumber(this._props[key])),(numberProps||=Object.create(null))[camelize(key)]=!0)}this._numberProps=numberProps,this._resolveProps(def$1),this.shadowRoot&&this._applyStyles(styles),this._mount(def$1)},asyncDef=this._def.__asyncLoader;asyncDef?this._pendingResolve=asyncDef().then(def$1=>{def$1.configureApp=this._def.configureApp,resolve$1(this._def=def$1,!0)}):resolve$1(this._def)}_mount(def$1){this._app=this._createApp(def$1),this._inheritParentContext(),def$1.configureApp&&def$1.configureApp(this._app),this._app._ceVNode=this._createVNode(),this._app.mount(this._root);let exposed=this._instance&&this._instance.exposed;if(exposed)for(let key in exposed)hasOwn$1(this,key)||Object.defineProperty(this,key,{get:()=>unref(exposed[key])})}_resolveProps(def$1){let{props}=def$1,declaredPropKeys=isArray$2(props)?props:Object.keys(props||{});for(let key of Object.keys(this))key[0]!==`_`&&declaredPropKeys.includes(key)&&this._setProp(key,this[key]);for(let key of declaredPropKeys.map(camelize))Object.defineProperty(this,key,{get(){return this._getProp(key)},set(val){this._setProp(key,val,!0,!0)}})}_setAttr(key){if(key.startsWith(`data-v-`))return;let has$1=this.hasAttribute(key),value=has$1?this.getAttribute(key):REMOVAL,camelKey=camelize(key);has$1&&this._numberProps&&this._numberProps[camelKey]&&(value=toNumber(value)),this._setProp(camelKey,value,!1,!0)}_getProp(key){return this._props[key]}_setProp(key,val,shouldReflect=!0,shouldUpdate=!1){if(val!==this._props[key]&&(val===REMOVAL?delete this._props[key]:(this._props[key]=val,key===`key`&&this._app&&(this._app._ceVNode.key=val)),shouldUpdate&&this._instance&&this._update(),shouldReflect)){let ob=this._ob;ob&&(this._processMutations(ob.takeRecords()),ob.disconnect()),val===!0?this.setAttribute(hyphenate(key),``):typeof val==`string`||typeof val==`number`?this.setAttribute(hyphenate(key),val+``):val||this.removeAttribute(hyphenate(key)),ob&&ob.observe(this,{attributes:!0})}}_update(){let vnode=this._createVNode();this._app&&(vnode.appContext=this._app._context),render(vnode,this._root)}_createVNode(){let baseProps={};this.shadowRoot||(baseProps.onVnodeMounted=baseProps.onVnodeUpdated=this._renderSlots.bind(this));let vnode=createVNode(this._def,extend(baseProps,this._props));return this._instance||(vnode.ce=instance$1=>{this._instance=instance$1,instance$1.ce=this,instance$1.isCE=!0;let dispatch=(event,args)=>{this.dispatchEvent(new CustomEvent(event,isPlainObject$2(args[0])?extend({detail:args},args[0]):{detail:args}))};instance$1.emit=(event,...args)=>{dispatch(event,args),hyphenate(event)!==event&&dispatch(hyphenate(event),args)},this._setParent()}),vnode}_applyStyles(styles,owner){if(!styles)return;if(owner){if(owner===this._def||this._styleChildren.has(owner))return;this._styleChildren.add(owner)}let nonce=this._nonce;for(let i=styles.length-1;i>=0;i--){let s=document.createElement(`style`);nonce&&s.setAttribute(`nonce`,nonce),s.textContent=styles[i],this.shadowRoot.prepend(s)}}_parseSlots(){let slots=this._slots={},n;for(;n=this.firstChild;){let slotName=n.nodeType===1&&n.getAttribute(`slot`)||`default`;(slots[slotName]||(slots[slotName]=[])).push(n),this.removeChild(n)}}_renderSlots(){let outlets=this._getSlots(),scopeId=this._instance.type.__scopeId;for(let i=0;i(res.push(...Array.from(i.querySelectorAll(`slot`))),res),[])}_injectChildStyle(comp){this._applyStyles(comp.styles,comp)}_removeChildStyle(comp){}};function useHost(caller){let instance$1=getCurrentInstance();return instance$1&&instance$1.ce||null}function useShadowRoot(){let el=useHost();return el&&el.shadowRoot}function useCssModule(name=`$style`){{let instance$1=getCurrentInstance();if(!instance$1)return EMPTY_OBJ;let modules=instance$1.type.__cssModules;return modules&&modules[name]||EMPTY_OBJ}}var positionMap=new WeakMap,newPositionMap=new WeakMap,moveCbKey=Symbol(`_moveCb`),enterCbKey=Symbol(`_enterCb`),decorate=t=>(delete t.props.mode,t),TransitionGroup=decorate({name:`TransitionGroup`,props:extend({},TransitionPropsValidators,{tag:String,moveClass:String}),setup(props,{slots}){let instance$1=getCurrentInstance(),state=useTransitionState(),prevChildren,children;return onUpdated(()=>{if(!prevChildren.length)return;let moveClass=props.moveClass||`${props.name||`v`}-move`;if(!hasCSSTransform(prevChildren[0].el,instance$1.vnode.el,moveClass)){prevChildren=[];return}prevChildren.forEach(callPendingCbs),prevChildren.forEach(recordPosition);let movedChildren=prevChildren.filter(applyTranslation);forceReflow(instance$1.vnode.el),movedChildren.forEach(c=>{let el=c.el,style=el.style;addTransitionClass(el,moveClass),style.transform=style.webkitTransform=style.transitionDuration=``;let cb=el[moveCbKey]=e=>{e&&e.target!==el||(!e||e.propertyName.endsWith(`transform`))&&(el.removeEventListener(`transitionend`,cb),el[moveCbKey]=null,removeTransitionClass(el,moveClass))};el.addEventListener(`transitionend`,cb)}),prevChildren=[]}),()=>{let rawProps=toRaw(props),cssTransitionProps=resolveTransitionProps(rawProps),tag=rawProps.tag||Fragment;if(prevChildren=[],children)for(let i=0;i{cls.split(/\s+/).forEach(c=>c&&clone.classList.remove(c))}),moveClass.split(/\s+/).forEach(c=>c&&clone.classList.add(c)),clone.style.display=`none`;let container=root.nodeType===1?root:root.parentNode;container.appendChild(clone);let{hasTransform}=getTransitionInfo(clone);return container.removeChild(clone),hasTransform}var getModelAssigner=vnode=>{let fn=vnode.props[`onUpdate:modelValue`]||!1;return isArray$2(fn)?value=>invokeArrayFns(fn,value):fn};function onCompositionStart(e){e.target.composing=!0}function onCompositionEnd(e){let target=e.target;target.composing&&(target.composing=!1,target.dispatchEvent(new Event(`input`)))}var assignKey=Symbol(`_assign`),vModelText={created(el,{modifiers:{lazy,trim,number}},vnode){el[assignKey]=getModelAssigner(vnode);let castToNumber=number||vnode.props&&vnode.props.type===`number`;addEventListener$1(el,lazy?`change`:`input`,e=>{if(e.target.composing)return;let domValue=el.value;trim&&(domValue=domValue.trim()),castToNumber&&(domValue=looseToNumber(domValue)),el[assignKey](domValue)}),trim&&addEventListener$1(el,`change`,()=>{el.value=el.value.trim()}),lazy||(addEventListener$1(el,`compositionstart`,onCompositionStart),addEventListener$1(el,`compositionend`,onCompositionEnd),addEventListener$1(el,`change`,onCompositionEnd))},mounted(el,{value}){el.value=value??``},beforeUpdate(el,{value,oldValue,modifiers:{lazy,trim,number}},vnode){if(el[assignKey]=getModelAssigner(vnode),el.composing)return;let elValue=(number||el.type===`number`)&&!/^0\d/.test(el.value)?looseToNumber(el.value):el.value,newValue=value??``;elValue!==newValue&&(document.activeElement===el&&el.type!==`range`&&(lazy&&value===oldValue||trim&&el.value.trim()===newValue)||(el.value=newValue))}},vModelCheckbox={deep:!0,created(el,_,vnode){el[assignKey]=getModelAssigner(vnode),addEventListener$1(el,`change`,()=>{let modelValue=el._modelValue,elementValue=getValue(el),checked=el.checked,assign$3=el[assignKey];if(isArray$2(modelValue)){let index=looseIndexOf(modelValue,elementValue),found=index!==-1;if(checked&&!found)assign$3(modelValue.concat(elementValue));else if(!checked&&found){let filtered=[...modelValue];filtered.splice(index,1),assign$3(filtered)}}else if(isSet(modelValue)){let cloned=new Set(modelValue);checked?cloned.add(elementValue):cloned.delete(elementValue),assign$3(cloned)}else assign$3(getCheckboxValue(el,checked))})},mounted:setChecked,beforeUpdate(el,binding,vnode){el[assignKey]=getModelAssigner(vnode),setChecked(el,binding,vnode)}};function setChecked(el,{value,oldValue},vnode){el._modelValue=value;let checked;if(isArray$2(value))checked=looseIndexOf(value,vnode.props.value)>-1;else if(isSet(value))checked=value.has(vnode.props.value);else{if(value===oldValue)return;checked=looseEqual(value,getCheckboxValue(el,!0))}el.checked!==checked&&(el.checked=checked)}var vModelRadio={created(el,{value},vnode){el.checked=looseEqual(value,vnode.props.value),el[assignKey]=getModelAssigner(vnode),addEventListener$1(el,`change`,()=>{el[assignKey](getValue(el))})},beforeUpdate(el,{value,oldValue},vnode){el[assignKey]=getModelAssigner(vnode),value!==oldValue&&(el.checked=looseEqual(value,vnode.props.value))}},vModelSelect={deep:!0,created(el,{value,modifiers:{number}},vnode){let isSetModel=isSet(value);addEventListener$1(el,`change`,()=>{let selectedVal=Array.prototype.filter.call(el.options,o=>o.selected).map(o=>number?looseToNumber(getValue(o)):getValue(o));el[assignKey](el.multiple?isSetModel?new Set(selectedVal):selectedVal:selectedVal[0]),el._assigning=!0,nextTick(()=>{el._assigning=!1})}),el[assignKey]=getModelAssigner(vnode)},mounted(el,{value}){setSelected(el,value)},beforeUpdate(el,_binding,vnode){el[assignKey]=getModelAssigner(vnode)},updated(el,{value}){el._assigning||setSelected(el,value)}};function setSelected(el,value){let isMultiple=el.multiple,isArrayValue=isArray$2(value);if(!(isMultiple&&!isArrayValue&&!isSet(value))){for(let i=0,l=el.options.length;iString(v)===String(optionValue)):option.selected=looseIndexOf(value,optionValue)>-1}else option.selected=value.has(optionValue);else if(looseEqual(getValue(option),value)){el.selectedIndex!==i&&(el.selectedIndex=i);return}}!isMultiple&&el.selectedIndex!==-1&&(el.selectedIndex=-1)}}function getValue(el){return`_value`in el?el._value:el.value}function getCheckboxValue(el,checked){let key=checked?`_trueValue`:`_falseValue`;return key in el?el[key]:checked}var vModelDynamic={created(el,binding,vnode){callModelHook(el,binding,vnode,null,`created`)},mounted(el,binding,vnode){callModelHook(el,binding,vnode,null,`mounted`)},beforeUpdate(el,binding,vnode,prevVNode){callModelHook(el,binding,vnode,prevVNode,`beforeUpdate`)},updated(el,binding,vnode,prevVNode){callModelHook(el,binding,vnode,prevVNode,`updated`)}};function resolveDynamicModel(tagName,type){switch(tagName){case`SELECT`:return vModelSelect;case`TEXTAREA`:return vModelText;default:switch(type){case`checkbox`:return vModelCheckbox;case`radio`:return vModelRadio;default:return vModelText}}}function callModelHook(el,binding,vnode,prevVNode,hook){let fn=resolveDynamicModel(el.tagName,vnode.props&&vnode.props.type)[hook];fn&&fn(el,binding,vnode,prevVNode)}function initVModelForSSR(){vModelText.getSSRProps=({value})=>({value}),vModelRadio.getSSRProps=({value},vnode)=>{if(vnode.props&&looseEqual(vnode.props.value,value))return{checked:!0}},vModelCheckbox.getSSRProps=({value},vnode)=>{if(isArray$2(value)){if(vnode.props&&looseIndexOf(value,vnode.props.value)>-1)return{checked:!0}}else if(isSet(value)){if(vnode.props&&value.has(vnode.props.value))return{checked:!0}}else if(value)return{checked:!0}},vModelDynamic.getSSRProps=(binding,vnode)=>{if(typeof vnode.type!=`string`)return;let modelToUse=resolveDynamicModel(vnode.type.toUpperCase(),vnode.props&&vnode.props.type);if(modelToUse.getSSRProps)return modelToUse.getSSRProps(binding,vnode)}}var systemModifiers=[`ctrl`,`shift`,`alt`,`meta`],modifierGuards={stop:e=>e.stopPropagation(),prevent:e=>e.preventDefault(),self:e=>e.target!==e.currentTarget,ctrl:e=>!e.ctrlKey,shift:e=>!e.shiftKey,alt:e=>!e.altKey,meta:e=>!e.metaKey,left:e=>`button`in e&&e.button!==0,middle:e=>`button`in e&&e.button!==1,right:e=>`button`in e&&e.button!==2,exact:(e,modifiers)=>systemModifiers.some(m=>e[`${m}Key`]&&!modifiers.includes(m))},withModifiers=(fn,modifiers)=>{let cache$1=fn._withMods||={},cacheKey=modifiers.join(`.`);return cache$1[cacheKey]||(cache$1[cacheKey]=((event,...args)=>{for(let i=0;i{let cache$1=fn._withKeys||={},cacheKey=modifiers.join(`.`);return cache$1[cacheKey]||(cache$1[cacheKey]=(event=>{if(!(`key`in event))return;let eventKey=hyphenate(event.key);if(modifiers.some(k=>k===eventKey||keyNames[k]===eventKey))return fn(event)}))},rendererOptions=extend({patchProp},nodeOps),renderer,enabledHydration=!1;function ensureRenderer(){return renderer||=createRenderer(rendererOptions)}function ensureHydrationRenderer(){return renderer=enabledHydration?renderer:createHydrationRenderer(rendererOptions),enabledHydration=!0,renderer}var render=((...args)=>{ensureRenderer().render(...args)}),hydrate=((...args)=>{ensureHydrationRenderer().hydrate(...args)}),createApp=((...args)=>{let app$1=ensureRenderer().createApp(...args),{mount}=app$1;return app$1.mount=containerOrSelector=>{let container=normalizeContainer(containerOrSelector);if(!container)return;let component=app$1._component;!isFunction$1(component)&&!component.render&&!component.template&&(component.template=container.innerHTML),container.nodeType===1&&(container.textContent=``);let proxy=mount(container,!1,resolveRootNamespace(container));return container instanceof Element&&(container.removeAttribute(`v-cloak`),container.setAttribute(`data-v-app`,``)),proxy},app$1}),createSSRApp=((...args)=>{let app$1=ensureHydrationRenderer().createApp(...args),{mount}=app$1;return app$1.mount=containerOrSelector=>{let container=normalizeContainer(containerOrSelector);if(container)return mount(container,!0,resolveRootNamespace(container))},app$1});function resolveRootNamespace(container){if(container instanceof SVGElement)return`svg`;if(typeof MathMLElement==`function`&&container instanceof MathMLElement)return`mathml`}function normalizeContainer(container){return isString$1(container)?document.querySelector(container):container}var ssrDirectiveInitialized=!1,initDirectivesForSSR=()=>{ssrDirectiveInitialized||(ssrDirectiveInitialized=!0,initVModelForSSR(),initVShowForSSR())},FRAGMENT=Symbol(``),TELEPORT=Symbol(``),SUSPENSE=Symbol(``),KEEP_ALIVE=Symbol(``),BASE_TRANSITION=Symbol(``),OPEN_BLOCK=Symbol(``),CREATE_BLOCK=Symbol(``),CREATE_ELEMENT_BLOCK=Symbol(``),CREATE_VNODE=Symbol(``),CREATE_ELEMENT_VNODE=Symbol(``),CREATE_COMMENT=Symbol(``),CREATE_TEXT=Symbol(``),CREATE_STATIC=Symbol(``),RESOLVE_COMPONENT=Symbol(``),RESOLVE_DYNAMIC_COMPONENT=Symbol(``),RESOLVE_DIRECTIVE=Symbol(``),RESOLVE_FILTER=Symbol(``),WITH_DIRECTIVES=Symbol(``),RENDER_LIST=Symbol(``),RENDER_SLOT=Symbol(``),CREATE_SLOTS=Symbol(``),TO_DISPLAY_STRING=Symbol(``),MERGE_PROPS=Symbol(``),NORMALIZE_CLASS=Symbol(``),NORMALIZE_STYLE=Symbol(``),NORMALIZE_PROPS=Symbol(``),GUARD_REACTIVE_PROPS=Symbol(``),TO_HANDLERS=Symbol(``),CAMELIZE=Symbol(``),CAPITALIZE=Symbol(``),TO_HANDLER_KEY=Symbol(``),SET_BLOCK_TRACKING=Symbol(``),PUSH_SCOPE_ID=Symbol(``),POP_SCOPE_ID=Symbol(``),WITH_CTX=Symbol(``),UNREF=Symbol(``),IS_REF=Symbol(``),WITH_MEMO=Symbol(``),IS_MEMO_SAME=Symbol(``),helperNameMap={[FRAGMENT]:`Fragment`,[TELEPORT]:`Teleport`,[SUSPENSE]:`Suspense`,[KEEP_ALIVE]:`KeepAlive`,[BASE_TRANSITION]:`BaseTransition`,[OPEN_BLOCK]:`openBlock`,[CREATE_BLOCK]:`createBlock`,[CREATE_ELEMENT_BLOCK]:`createElementBlock`,[CREATE_VNODE]:`createVNode`,[CREATE_ELEMENT_VNODE]:`createElementVNode`,[CREATE_COMMENT]:`createCommentVNode`,[CREATE_TEXT]:`createTextVNode`,[CREATE_STATIC]:`createStaticVNode`,[RESOLVE_COMPONENT]:`resolveComponent`,[RESOLVE_DYNAMIC_COMPONENT]:`resolveDynamicComponent`,[RESOLVE_DIRECTIVE]:`resolveDirective`,[RESOLVE_FILTER]:`resolveFilter`,[WITH_DIRECTIVES]:`withDirectives`,[RENDER_LIST]:`renderList`,[RENDER_SLOT]:`renderSlot`,[CREATE_SLOTS]:`createSlots`,[TO_DISPLAY_STRING]:`toDisplayString`,[MERGE_PROPS]:`mergeProps`,[NORMALIZE_CLASS]:`normalizeClass`,[NORMALIZE_STYLE]:`normalizeStyle`,[NORMALIZE_PROPS]:`normalizeProps`,[GUARD_REACTIVE_PROPS]:`guardReactiveProps`,[TO_HANDLERS]:`toHandlers`,[CAMELIZE]:`camelize`,[CAPITALIZE]:`capitalize`,[TO_HANDLER_KEY]:`toHandlerKey`,[SET_BLOCK_TRACKING]:`setBlockTracking`,[PUSH_SCOPE_ID]:`pushScopeId`,[POP_SCOPE_ID]:`popScopeId`,[WITH_CTX]:`withCtx`,[UNREF]:`unref`,[IS_REF]:`isRef`,[WITH_MEMO]:`withMemo`,[IS_MEMO_SAME]:`isMemoSame`};function registerRuntimeHelpers(helpers){Object.getOwnPropertySymbols(helpers).forEach(s=>{helperNameMap[s]=helpers[s]})}var locStub={start:{line:1,column:1,offset:0},end:{line:1,column:1,offset:0},source:``};function createRoot(children,source=``){return{type:0,source,children,helpers:new Set,components:[],directives:[],hoists:[],imports:[],cached:[],temps:0,codegenNode:void 0,loc:locStub}}function createVNodeCall(context,tag,props,children,patchFlag,dynamicProps,directives,isBlock=!1,disableTracking=!1,isComponent$1=!1,loc=locStub){return context&&(isBlock?(context.helper(OPEN_BLOCK),context.helper(getVNodeBlockHelper(context.inSSR,isComponent$1))):context.helper(getVNodeHelper(context.inSSR,isComponent$1)),directives&&context.helper(WITH_DIRECTIVES)),{type:13,tag,props,children,patchFlag,dynamicProps,directives,isBlock,disableTracking,isComponent:isComponent$1,loc}}function createArrayExpression(elements,loc=locStub){return{type:17,loc,elements}}function createObjectExpression(properties,loc=locStub){return{type:15,loc,properties}}function createObjectProperty(key,value){return{type:16,loc:locStub,key:isString$1(key)?createSimpleExpression(key,!0):key,value}}function createSimpleExpression(content,isStatic=!1,loc=locStub,constType=0){return{type:4,loc,content,isStatic,constType:isStatic?3:constType}}function createCompoundExpression(children,loc=locStub){return{type:8,loc,children}}function createCallExpression(callee,args=[],loc=locStub){return{type:14,loc,callee,arguments:args}}function createFunctionExpression(params,returns=void 0,newline=!1,isSlot=!1,loc=locStub){return{type:18,params,returns,newline,isSlot,loc}}function createConditionalExpression(test,consequent,alternate,newline=!0){return{type:19,test,consequent,alternate,newline,loc:locStub}}function createCacheExpression(index,value,needPauseTracking=!1,inVOnce=!1){return{type:20,index,value,needPauseTracking,inVOnce,needArraySpread:!1,loc:locStub}}function createBlockStatement(body){return{type:21,body,loc:locStub}}function getVNodeHelper(ssr,isComponent$1){return ssr||isComponent$1?CREATE_VNODE:CREATE_ELEMENT_VNODE}function getVNodeBlockHelper(ssr,isComponent$1){return ssr||isComponent$1?CREATE_BLOCK:CREATE_ELEMENT_BLOCK}function convertToBlock(node,{helper,removeHelper,inSSR}){node.isBlock||(node.isBlock=!0,removeHelper(getVNodeHelper(inSSR,node.isComponent)),helper(OPEN_BLOCK),helper(getVNodeBlockHelper(inSSR,node.isComponent)))}var defaultDelimitersOpen=new Uint8Array([123,123]),defaultDelimitersClose=new Uint8Array([125,125]);function isTagStartChar(c){return c>=97&&c<=122||c>=65&&c<=90}function isWhitespace(c){return c===32||c===10||c===9||c===12||c===13}function isEndOfTagSection(c){return c===47||c===62||isWhitespace(c)}function toCharCodes(str){let ret=new Uint8Array(str.length);for(let i=0;i=0;i--){let newlineIndex=this.newlines[i];if(index>newlineIndex){line=i+2,column=index-newlineIndex;break}}return{column,line,offset:index}}peek(){return this.buffer.charCodeAt(this.index+1)}stateText(c){c===60?(this.index>this.sectionStart&&this.cbs.ontext(this.sectionStart,this.index),this.state=5,this.sectionStart=this.index):!this.inVPre&&c===this.delimiterOpen[0]&&(this.state=2,this.delimiterIndex=0,this.stateInterpolationOpen(c))}stateInterpolationOpen(c){if(c===this.delimiterOpen[this.delimiterIndex])if(this.delimiterIndex===this.delimiterOpen.length-1){let start=this.index+1-this.delimiterOpen.length;start>this.sectionStart&&this.cbs.ontext(this.sectionStart,start),this.state=3,this.sectionStart=start}else this.delimiterIndex++;else this.inRCDATA?(this.state=32,this.stateInRCDATA(c)):(this.state=1,this.stateText(c))}stateInterpolation(c){c===this.delimiterClose[0]&&(this.state=4,this.delimiterIndex=0,this.stateInterpolationClose(c))}stateInterpolationClose(c){c===this.delimiterClose[this.delimiterIndex]?this.delimiterIndex===this.delimiterClose.length-1?(this.cbs.oninterpolation(this.sectionStart,this.index+1),this.inRCDATA?this.state=32:this.state=1,this.sectionStart=this.index+1):this.delimiterIndex++:(this.state=3,this.stateInterpolation(c))}stateSpecialStartSequence(c){let isEnd=this.sequenceIndex===this.currentSequence.length;if(!(isEnd?isEndOfTagSection(c):(c|32)===this.currentSequence[this.sequenceIndex]))this.inRCDATA=!1;else if(!isEnd){this.sequenceIndex++;return}this.sequenceIndex=0,this.state=6,this.stateInTagName(c)}stateInRCDATA(c){if(this.sequenceIndex===this.currentSequence.length){if(c===62||isWhitespace(c)){let endOfText=this.index-this.currentSequence.length;if(this.sectionStart=endIndex||(this.state===28?this.currentSequence===Sequences.CdataEnd?this.cbs.oncdata(this.sectionStart,endIndex):this.cbs.oncomment(this.sectionStart,endIndex):this.state===6||this.state===11||this.state===18||this.state===17||this.state===12||this.state===13||this.state===14||this.state===15||this.state===16||this.state===20||this.state===19||this.state===21||this.state===9||this.cbs.ontext(this.sectionStart,endIndex))}emitCodePoint(cp,consumed){}};function getCompatValue(key,{compatConfig}){let value=compatConfig&&compatConfig[key];return key===`MODE`?value||3:value}function isCompatEnabled(key,context){let mode=getCompatValue(`MODE`,context),value=getCompatValue(key,context);return mode===3?value===!0:value!==!1}function checkCompatEnabled(key,context,loc,...args){return isCompatEnabled(key,context)}function defaultOnError$1(error){throw error}function defaultOnWarn(msg){}function createCompilerError(code,loc,messages,additionalMessage){let msg=`https://vuejs.org/error-reference/#compiler-${code}`,error=SyntaxError(String(msg));return error.code=code,error.loc=loc,error}var isStaticExp=p$1=>p$1.type===4&&p$1.isStatic;function isCoreComponent(tag){switch(tag){case`Teleport`:case`teleport`:return TELEPORT;case`Suspense`:case`suspense`:return SUSPENSE;case`KeepAlive`:case`keep-alive`:return KEEP_ALIVE;case`BaseTransition`:case`base-transition`:return BASE_TRANSITION}}var nonIdentifierRE=/^$|^\d|[^\$\w\xA0-\uFFFF]/,isSimpleIdentifier=name=>!nonIdentifierRE.test(name),validFirstIdentCharRE=/[A-Za-z_$\xA0-\uFFFF]/,validIdentCharRE=/[\.\?\w$\xA0-\uFFFF]/,whitespaceRE=/\s+[.[]\s*|\s*[.[]\s+/g,getExpSource=exp=>exp.type===4?exp.content:exp.loc.source,isMemberExpressionBrowser=exp=>{let path=getExpSource(exp).trim().replace(whitespaceRE,s=>s.trim()),state=0,stateStack$1=[],currentOpenBracketCount=0,currentOpenParensCount=0,currentStringType=null;for(let i=0;i|^\s*(?:async\s+)?function(?:\s+[\w$]+)?\s*\(/,isFnExpressionBrowser=exp=>fnExpRE.test(getExpSource(exp)),isFnExpression=isFnExpressionBrowser;function findDir(node,name,allowEmpty=!1){for(let i=0;ip$1.type===7&&p$1.name===`bind`&&(!p$1.arg||p$1.arg.type!==4||!p$1.arg.isStatic))}function isText$1(node){return node.type===5||node.type===2}function isVPre(p$1){return p$1.type===7&&p$1.name===`pre`}function isVSlot(p$1){return p$1.type===7&&p$1.name===`slot`}function isTemplateNode(node){return node.type===1&&node.tagType===3}function isSlotOutlet(node){return node.type===1&&node.tagType===2}var propsHelperSet=new Set([NORMALIZE_PROPS,GUARD_REACTIVE_PROPS]);function getUnnormalizedProps(props,callPath=[]){if(props&&!isString$1(props)&&props.type===14){let callee=props.callee;if(!isString$1(callee)&&propsHelperSet.has(callee))return getUnnormalizedProps(props.arguments[0],callPath.concat(props))}return[props,callPath]}function injectProp(node,prop,context){let propsWithInjection,props=node.type===13?node.props:node.arguments[2],callPath=[],parentCall;if(props&&!isString$1(props)&&props.type===14){let ret=getUnnormalizedProps(props);props=ret[0],callPath=ret[1],parentCall=callPath[callPath.length-1]}if(props==null||isString$1(props))propsWithInjection=createObjectExpression([prop]);else if(props.type===14){let first=props.arguments[0];!isString$1(first)&&first.type===15?hasProp(prop,first)||first.properties.unshift(prop):props.callee===TO_HANDLERS?propsWithInjection=createCallExpression(context.helper(MERGE_PROPS),[createObjectExpression([prop]),props]):props.arguments.unshift(createObjectExpression([prop])),!propsWithInjection&&(propsWithInjection=props)}else props.type===15?(hasProp(prop,props)||props.properties.unshift(prop),propsWithInjection=props):(propsWithInjection=createCallExpression(context.helper(MERGE_PROPS),[createObjectExpression([prop]),props]),parentCall&&parentCall.callee===GUARD_REACTIVE_PROPS&&(parentCall=callPath[callPath.length-2]));node.type===13?parentCall?parentCall.arguments[0]=propsWithInjection:node.props=propsWithInjection:parentCall?parentCall.arguments[0]=propsWithInjection:node.arguments[2]=propsWithInjection}function hasProp(prop,props){let result=!1;if(prop.key.type===4){let propKeyName=prop.key.content;result=props.properties.some(p$1=>p$1.key.type===4&&p$1.key.content===propKeyName)}return result}function toValidAssetId(name,type){return`_${type}_${name.replace(/[^\w]/g,(searchValue,replaceValue)=>searchValue===`-`?`_`:name.charCodeAt(replaceValue).toString())}`}function getMemoedVNodeCall(node){return node.type===14&&node.callee===WITH_MEMO?node.arguments[1].returns:node}var forAliasRE=/([\s\S]*?)\s+(?:in|of)\s+(\S[\s\S]*)/,defaultParserOptions={parseMode:`base`,ns:0,delimiters:[`{{`,`}}`],getNamespace:()=>0,isVoidTag:NO,isPreTag:NO,isIgnoreNewlineTag:NO,isCustomElement:NO,onError:defaultOnError$1,onWarn:defaultOnWarn,comments:!1,prefixIdentifiers:!1},currentOptions=defaultParserOptions,currentRoot=null,currentInput=``,currentOpenTag=null,currentProp=null,currentAttrValue=``,currentAttrStartIndex=-1,currentAttrEndIndex=-1,inPre=0,inVPre=!1,currentVPreBoundary=null,stack=[],tokenizer=new Tokenizer(stack,{onerr:emitError,ontext(start,end){onText(getSlice(start,end),start,end)},ontextentity(char,start,end){onText(char,start,end)},oninterpolation(start,end){if(inVPre)return onText(getSlice(start,end),start,end);let innerStart=start+tokenizer.delimiterOpen.length,innerEnd=end-tokenizer.delimiterClose.length;for(;isWhitespace(currentInput.charCodeAt(innerStart));)innerStart++;for(;isWhitespace(currentInput.charCodeAt(innerEnd-1));)innerEnd--;let exp=getSlice(innerStart,innerEnd);exp.includes(`&`)&&(exp=currentOptions.decodeEntities(exp,!1)),addNode({type:5,content:createExp(exp,!1,getLoc(innerStart,innerEnd)),loc:getLoc(start,end)})},onopentagname(start,end){let name=getSlice(start,end);currentOpenTag={type:1,tag:name,ns:currentOptions.getNamespace(name,stack[0],currentOptions.ns),tagType:0,props:[],children:[],loc:getLoc(start-1,end),codegenNode:void 0}},onopentagend(end){endOpenTag(end)},onclosetag(start,end){let name=getSlice(start,end);if(!currentOptions.isVoidTag(name)){let found=!1;for(let i=0;i0&&emitError(24,stack[0].loc.start.offset);for(let j=0;j<=i;j++)onCloseTag(stack.shift(),end,j(p$1.type===7?p$1.rawName:p$1.name)===name)&&emitError(2,start)},onattribend(quote,end){if(currentOpenTag&¤tProp){if(setLocEnd(currentProp.loc,end),quote!==0)if(currentAttrValue.includes(`&`)&&(currentAttrValue=currentOptions.decodeEntities(currentAttrValue,!0)),currentProp.type===6)currentProp.name===`class`&&(currentAttrValue=condense(currentAttrValue).trim()),quote===1&&!currentAttrValue&&emitError(13,end),currentProp.value={type:2,content:currentAttrValue,loc:quote===1?getLoc(currentAttrStartIndex,currentAttrEndIndex):getLoc(currentAttrStartIndex-1,currentAttrEndIndex+1)},tokenizer.inSFCRoot&¤tOpenTag.tag===`template`&¤tProp.name===`lang`&¤tAttrValue&¤tAttrValue!==`html`&&tokenizer.enterRCDATA(toCharCodes(`mod.content===`sync`))>-1&&checkCompatEnabled(`COMPILER_V_BIND_SYNC`,currentOptions,currentProp.loc,currentProp.arg.loc.source)&&(currentProp.name=`model`,currentProp.modifiers.splice(syncIndex,1))}(currentProp.type!==7||currentProp.name!==`pre`)&¤tOpenTag.props.push(currentProp)}currentAttrValue=``,currentAttrStartIndex=currentAttrEndIndex=-1},oncomment(start,end){currentOptions.comments&&addNode({type:3,content:getSlice(start,end),loc:getLoc(start-4,end+3)})},onend(){let end=currentInput.length;for(let index=0;index{let start=loc.start.offset+offset$2;return createExp(content,!1,getLoc(start,start+content.length),0,asParam?1:0)},result={source:createAliasExpression(RHS.trim(),exp.indexOf(RHS,LHS.length)),value:void 0,key:void 0,index:void 0,finalized:!1},valueContent=LHS.trim().replace(stripParensRE,``).trim(),trimmedOffset=LHS.indexOf(valueContent),iteratorMatch=valueContent.match(forIteratorRE);if(iteratorMatch){valueContent=valueContent.replace(forIteratorRE,``).trim();let keyContent=iteratorMatch[1].trim(),keyOffset;if(keyContent&&(keyOffset=exp.indexOf(keyContent,trimmedOffset+valueContent.length),result.key=createAliasExpression(keyContent,keyOffset,!0)),iteratorMatch[2]){let indexContent=iteratorMatch[2].trim();indexContent&&(result.index=createAliasExpression(indexContent,exp.indexOf(indexContent,result.key?keyOffset+keyContent.length:trimmedOffset+valueContent.length),!0))}}return valueContent&&(result.value=createAliasExpression(valueContent,trimmedOffset,!0)),result}function getSlice(start,end){return currentInput.slice(start,end)}function endOpenTag(end){tokenizer.inSFCRoot&&(currentOpenTag.innerLoc=getLoc(end+1,end+1)),addNode(currentOpenTag);let{tag,ns}=currentOpenTag;ns===0&¤tOptions.isPreTag(tag)&&inPre++,currentOptions.isVoidTag(tag)?onCloseTag(currentOpenTag,end):(stack.unshift(currentOpenTag),(ns===1||ns===2)&&(tokenizer.inXML=!0)),currentOpenTag=null}function onText(content,start,end){{let tag=stack[0]&&stack[0].tag;tag!==`script`&&tag!==`style`&&content.includes(`&`)&&(content=currentOptions.decodeEntities(content,!1))}let parent=stack[0]||currentRoot,lastNode=parent.children[parent.children.length-1];lastNode&&lastNode.type===2?(lastNode.content+=content,setLocEnd(lastNode.loc,end)):parent.children.push({type:2,content,loc:getLoc(start,end)})}function onCloseTag(el,end,isImplied=!1){isImplied?setLocEnd(el.loc,backTrack(end,60)):setLocEnd(el.loc,lookAhead(end,62)+1),tokenizer.inSFCRoot&&(el.children.length?el.innerLoc.end=extend({},el.children[el.children.length-1].loc.end):el.innerLoc.end=extend({},el.innerLoc.start),el.innerLoc.source=getSlice(el.innerLoc.start.offset,el.innerLoc.end.offset));let{tag,ns,children}=el;if(inVPre||(tag===`slot`?el.tagType=2:isFragmentTemplate(el)?el.tagType=3:isComponent(el)&&(el.tagType=1)),tokenizer.inRCDATA||(el.children=condenseWhitespace(children)),ns===0&¤tOptions.isIgnoreNewlineTag(tag)){let first=children[0];first&&first.type===2&&(first.content=first.content.replace(/^\r?\n/,``))}ns===0&¤tOptions.isPreTag(tag)&&inPre--,currentVPreBoundary===el&&(inVPre=tokenizer.inVPre=!1,currentVPreBoundary=null),tokenizer.inXML&&(stack[0]?stack[0].ns:currentOptions.ns)===0&&(tokenizer.inXML=!1);{let props=el.props;if(!tokenizer.inSFCRoot&&isCompatEnabled(`COMPILER_NATIVE_TEMPLATE`,currentOptions)&&el.tag===`template`&&!isFragmentTemplate(el)){let parent=stack[0]||currentRoot,index=parent.children.indexOf(el);parent.children.splice(index,1,...el.children)}let inlineTemplateProp=props.find(p$1=>p$1.type===6&&p$1.name===`inline-template`);inlineTemplateProp&&checkCompatEnabled(`COMPILER_INLINE_TEMPLATE`,currentOptions,inlineTemplateProp.loc)&&el.children.length&&(inlineTemplateProp.value={type:2,content:getSlice(el.children[0].loc.start.offset,el.children[el.children.length-1].loc.end.offset),loc:inlineTemplateProp.loc})}}function lookAhead(index,c){let i=index;for(;currentInput.charCodeAt(i)!==c&&i=0;)i--;return i}var specialTemplateDir=new Set([`if`,`else`,`else-if`,`for`,`slot`]);function isFragmentTemplate({tag,props}){if(tag===`template`){for(let i=0;i64&&c<91}var windowsNewlineRE=/\r\n/g;function condenseWhitespace(nodes){let shouldCondense=currentOptions.whitespace!==`preserve`,removedWhitespace=!1;for(let i=0;i
var __create=Object.create,__defProp=Object.defineProperty,__getOwnPropDesc=Object.getOwnPropertyDescriptor,__getOwnPropNames=Object.getOwnPropertyNames,__getProtoOf=Object.getPrototypeOf,__hasOwnProp=Object.prototype.hasOwnProperty,__commonJSMin=(cb,mod)=>()=>(mod||cb((mod={exports:{}}).exports,mod),mod.exports),__export=all=>{let target={};for(var name in all)__defProp(target,name,{get:all[name],enumerable:!0});return target},__copyProps=(to,from,except,desc)=>{if(from&&typeof from==`object`||typeof from==`function`)for(var keys=__getOwnPropNames(from),i=0,n=keys.length,key;ifrom[k]).bind(null,key),enumerable:!(desc=__getOwnPropDesc(from,key))||desc.enumerable});return to},__toESM=(mod,isNodeMode,target)=>(target=mod==null?{}:__create(__getProtoOf(mod)),__copyProps(isNodeMode||!mod||!mod.__esModule?__defProp(target,`default`,{value:mod,enumerable:!0}):target,mod));(function(){let relList=document.createElement(`link`).relList;if(relList&&relList.supports&&relList.supports(`modulepreload`))return;for(let link of document.querySelectorAll(`link[rel="modulepreload"]`))processPreload(link);new MutationObserver(mutations=>{for(let mutation of mutations)if(mutation.type===`childList`)for(let node of mutation.addedNodes)node.tagName===`LINK`&&node.rel===`modulepreload`&&processPreload(node)}).observe(document,{childList:!0,subtree:!0});function getFetchOpts(link){let fetchOpts={};return link.integrity&&(fetchOpts.integrity=link.integrity),link.referrerPolicy&&(fetchOpts.referrerPolicy=link.referrerPolicy),link.crossOrigin===`use-credentials`?fetchOpts.credentials=`include`:link.crossOrigin===`anonymous`?fetchOpts.credentials=`omit`:fetchOpts.credentials=`same-origin`,fetchOpts}function processPreload(link){if(link.ep)return;link.ep=!0;let fetchOpts=getFetchOpts(link);fetch(link.href,fetchOpts)}})();function makeMap(str){let map=Object.create(null);for(let key of str.split(`,`))map[key]=1;return val=>val in map}var EMPTY_OBJ={},EMPTY_ARR=[],NOOP=()=>{},NO=()=>!1,isOn=key=>key.charCodeAt(0)===111&&key.charCodeAt(1)===110&&(key.charCodeAt(2)>122||key.charCodeAt(2)<97),isModelListener=key=>key.startsWith(`onUpdate:`),extend=Object.assign,remove$2=(arr,el)=>{let i=arr.indexOf(el);i>-1&&arr.splice(i,1)},hasOwnProperty$2=Object.prototype.hasOwnProperty,hasOwn$1=(val,key)=>hasOwnProperty$2.call(val,key),isArray$2=Array.isArray,isMap=val=>toTypeString$1(val)===`[object Map]`,isSet=val=>toTypeString$1(val)===`[object Set]`,isDate$1=val=>toTypeString$1(val)===`[object Date]`,isRegExp$1=val=>toTypeString$1(val)===`[object RegExp]`,isFunction$1=val=>typeof val==`function`,isString$1=val=>typeof val==`string`,isSymbol=val=>typeof val==`symbol`,isObject$1=val=>typeof val==`object`&&!!val,isPromise$1=val=>(isObject$1(val)||isFunction$1(val))&&isFunction$1(val.then)&&isFunction$1(val.catch),objectToString$1=Object.prototype.toString,toTypeString$1=value=>objectToString$1.call(value),toRawType=value=>toTypeString$1(value).slice(8,-1),isPlainObject$2=val=>toTypeString$1(val)===`[object Object]`,isIntegerKey=key=>isString$1(key)&&key!==`NaN`&&key[0]!==`-`&&``+parseInt(key,10)===key,isReservedProp=makeMap(`,key,ref,ref_for,ref_key,onVnodeBeforeMount,onVnodeMounted,onVnodeBeforeUpdate,onVnodeUpdated,onVnodeBeforeUnmount,onVnodeUnmounted`),isBuiltInDirective=makeMap(`bind,cloak,else-if,else,for,html,if,model,on,once,pre,show,slot,text,memo`),cacheStringFunction=fn=>{let cache$1=Object.create(null);return(str=>cache$1[str]||(cache$1[str]=fn(str)))},camelizeRE=/-\w/g,camelize=cacheStringFunction(str=>str.replace(camelizeRE,c=>c.slice(1).toUpperCase())),hyphenateRE=/\B([A-Z])/g,hyphenate=cacheStringFunction(str=>str.replace(hyphenateRE,`-$1`).toLowerCase()),capitalize$1=cacheStringFunction(str=>str.charAt(0).toUpperCase()+str.slice(1)),toHandlerKey=cacheStringFunction(str=>str?`on${capitalize$1(str)}`:``),hasChanged=(value,oldValue)=>!Object.is(value,oldValue),invokeArrayFns=(fns,...arg)=>{for(let i=0;i{Object.defineProperty(obj,key,{configurable:!0,enumerable:!1,writable,value})},looseToNumber=val=>{let n=parseFloat(val);return isNaN(n)?val:n},toNumber=val=>{let n=isString$1(val)?Number(val):NaN;return isNaN(n)?val:n},_globalThis$1,getGlobalThis$1=()=>_globalThis$1||=typeof globalThis<`u`?globalThis:typeof self<`u`?self:typeof window<`u`?window:typeof global<`u`?global:{};function genCacheKey(source,options){return source+JSON.stringify(options,(_,val)=>typeof val==`function`?val.toString():val)}var isGloballyAllowed=makeMap(`Infinity,undefined,NaN,isFinite,isNaN,parseFloat,parseInt,decodeURI,decodeURIComponent,encodeURI,encodeURIComponent,Math,Number,Date,Array,Object,Boolean,String,RegExp,Map,Set,JSON,Intl,BigInt,console,Error,Symbol`);function normalizeStyle(value){if(isArray$2(value)){let res={};for(let i=0;i{if(item){let tmp=item.split(propertyDelimiterRE);tmp.length>1&&(ret[tmp[0].trim()]=tmp[1].trim())}}),ret}function normalizeClass(value){let res=``;if(isString$1(value))res=value;else if(isArray$2(value))for(let i=0;ilooseEqual(item,val))}var isRef$2=val=>!!(val&&val.__v_isRef===!0),toDisplayString=val=>isString$1(val)?val:val==null?``:isArray$2(val)||isObject$1(val)&&(val.toString===objectToString$1||!isFunction$1(val.toString))?isRef$2(val)?toDisplayString(val.value):JSON.stringify(val,replacer,2):String(val),replacer=(_key,val)=>isRef$2(val)?replacer(_key,val.value):isMap(val)?{[`Map(${val.size})`]:[...val.entries()].reduce((entries,[key,val2],i)=>(entries[stringifySymbol(key,i)+` =>`]=val2,entries),{})}:isSet(val)?{[`Set(${val.size})`]:[...val.values()].map(v=>stringifySymbol(v))}:isSymbol(val)?stringifySymbol(val):isObject$1(val)&&!isArray$2(val)&&!isPlainObject$2(val)?String(val):val,stringifySymbol=(v,i=``)=>{var _a;return isSymbol(v)?`Symbol(${v.description??i})`:v};function normalizeCssVarValue(value){return value==null?`initial`:typeof value==`string`?value===``?` `:value:String(value)}var activeEffectScope,EffectScope=class{constructor(detached=!1){this.detached=detached,this._active=!0,this._on=0,this.effects=[],this.cleanups=[],this._isPaused=!1,this.parent=activeEffectScope,!detached&&activeEffectScope&&(this.index=(activeEffectScope.scopes||=[]).push(this)-1)}get active(){return this._active}pause(){if(this._active){this._isPaused=!0;let i,l;if(this.scopes)for(i=0,l=this.scopes.length;i0&&--this._on===0&&(activeEffectScope=this.prevScope,this.prevScope=void 0)}stop(fromParent){if(this._active){this._active=!1;let i,l;for(i=0,l=this.effects.length;i0)return;if(batchedComputed){let e=batchedComputed;for(batchedComputed=void 0;e;){let next=e.next;e.next=void 0,e.flags&=-9,e=next}}let error;for(;batchedSub;){let e=batchedSub;for(batchedSub=void 0;e;){let next=e.next;if(e.next=void 0,e.flags&=-9,e.flags&1)try{e.trigger()}catch(err){error||=err}e=next}}if(error)throw error}function prepareDeps(sub){for(let link=sub.deps;link;link=link.nextDep)link.version=-1,link.prevActiveLink=link.dep.activeLink,link.dep.activeLink=link}function cleanupDeps(sub){let head,tail=sub.depsTail,link=tail;for(;link;){let prev=link.prevDep;link.version===-1?(link===tail&&(tail=prev),removeSub(link),removeDep(link)):head=link,link.dep.activeLink=link.prevActiveLink,link.prevActiveLink=void 0,link=prev}sub.deps=head,sub.depsTail=tail}function isDirty(sub){for(let link=sub.deps;link;link=link.nextDep)if(link.dep.version!==link.version||link.dep.computed&&(refreshComputed(link.dep.computed)||link.dep.version!==link.version))return!0;return!!sub._dirty}function refreshComputed(computed$2){if(computed$2.flags&4&&!(computed$2.flags&16)||(computed$2.flags&=-17,computed$2.globalVersion===globalVersion)||(computed$2.globalVersion=globalVersion,!computed$2.isSSR&&computed$2.flags&128&&(!computed$2.deps&&!computed$2._dirty||!isDirty(computed$2))))return;computed$2.flags|=2;let dep=computed$2.dep,prevSub=activeSub,prevShouldTrack=shouldTrack;activeSub=computed$2,shouldTrack=!0;try{prepareDeps(computed$2);let value=computed$2.fn(computed$2._value);(dep.version===0||hasChanged(value,computed$2._value))&&(computed$2.flags|=128,computed$2._value=value,dep.version++)}catch(err){throw dep.version++,err}finally{activeSub=prevSub,shouldTrack=prevShouldTrack,cleanupDeps(computed$2),computed$2.flags&=-3}}function removeSub(link,soft=!1){let{dep,prevSub,nextSub}=link;if(prevSub&&(prevSub.nextSub=nextSub,link.prevSub=void 0),nextSub&&(nextSub.prevSub=prevSub,link.nextSub=void 0),dep.subs===link&&(dep.subs=prevSub,!prevSub&&dep.computed)){dep.computed.flags&=-5;for(let l=dep.computed.deps;l;l=l.nextDep)removeSub(l,!0)}!soft&&!--dep.sc&&dep.map&&dep.map.delete(dep.key)}function removeDep(link){let{prevDep,nextDep}=link;prevDep&&(prevDep.nextDep=nextDep,link.prevDep=void 0),nextDep&&(nextDep.prevDep=prevDep,link.nextDep=void 0)}function effect(fn,options){fn.effect instanceof ReactiveEffect&&(fn=fn.effect.fn);let e=new ReactiveEffect(fn);options&&extend(e,options);try{e.run()}catch(err){throw e.stop(),err}let runner=e.run.bind(e);return runner.effect=e,runner}function stop(runner){runner.effect.stop()}var shouldTrack=!0,trackStack=[];function pauseTracking(){trackStack.push(shouldTrack),shouldTrack=!1}function resetTracking(){let last=trackStack.pop();shouldTrack=last===void 0?!0:last}function cleanupEffect(e){let{cleanup}=e;if(e.cleanup=void 0,cleanup){let prevSub=activeSub;activeSub=void 0;try{cleanup()}finally{activeSub=prevSub}}}var globalVersion=0,Link=class{constructor(sub,dep){this.sub=sub,this.dep=dep,this.version=dep.version,this.nextDep=this.prevDep=this.nextSub=this.prevSub=this.prevActiveLink=void 0}},Dep=class{constructor(computed$2){this.computed=computed$2,this.version=0,this.activeLink=void 0,this.subs=void 0,this.map=void 0,this.key=void 0,this.sc=0,this.__v_skip=!0}track(debugInfo){if(!activeSub||!shouldTrack||activeSub===this.computed)return;let link=this.activeLink;if(link===void 0||link.sub!==activeSub)link=this.activeLink=new Link(activeSub,this),activeSub.deps?(link.prevDep=activeSub.depsTail,activeSub.depsTail.nextDep=link,activeSub.depsTail=link):activeSub.deps=activeSub.depsTail=link,addSub(link);else if(link.version===-1&&(link.version=this.version,link.nextDep)){let next=link.nextDep;next.prevDep=link.prevDep,link.prevDep&&(link.prevDep.nextDep=next),link.prevDep=activeSub.depsTail,link.nextDep=void 0,activeSub.depsTail.nextDep=link,activeSub.depsTail=link,activeSub.deps===link&&(activeSub.deps=next)}return link}trigger(debugInfo){this.version++,globalVersion++,this.notify(debugInfo)}notify(debugInfo){startBatch();try{for(let link=this.subs;link;link=link.prevSub)link.sub.notify()&&link.sub.dep.notify()}finally{endBatch()}}};function addSub(link){if(link.dep.sc++,link.sub.flags&4){let computed$2=link.dep.computed;if(computed$2&&!link.dep.subs){computed$2.flags|=20;for(let l=computed$2.deps;l;l=l.nextDep)addSub(l)}let currentTail=link.dep.subs;currentTail!==link&&(link.prevSub=currentTail,currentTail&&(currentTail.nextSub=link)),link.dep.subs=link}}var targetMap=new WeakMap,ITERATE_KEY=Symbol(``),MAP_KEY_ITERATE_KEY=Symbol(``),ARRAY_ITERATE_KEY=Symbol(``);function track(target,type,key){if(shouldTrack&&activeSub){let depsMap=targetMap.get(target);depsMap||targetMap.set(target,depsMap=new Map);let dep=depsMap.get(key);dep||(depsMap.set(key,dep=new Dep),dep.map=depsMap,dep.key=key),dep.track()}}function trigger$1(target,type,key,newValue,oldValue,oldTarget){let depsMap=targetMap.get(target);if(!depsMap){globalVersion++;return}let run$1=dep=>{dep&&dep.trigger()};if(startBatch(),type===`clear`)depsMap.forEach(run$1);else{let targetIsArray=isArray$2(target),isArrayIndex=targetIsArray&&isIntegerKey(key);if(targetIsArray&&key===`length`){let newLength=Number(newValue);depsMap.forEach((dep,key2)=>{(key2===`length`||key2===ARRAY_ITERATE_KEY||!isSymbol(key2)&&key2>=newLength)&&run$1(dep)})}else switch((key!==void 0||depsMap.has(void 0))&&run$1(depsMap.get(key)),isArrayIndex&&run$1(depsMap.get(ARRAY_ITERATE_KEY)),type){case`add`:targetIsArray?isArrayIndex&&run$1(depsMap.get(`length`)):(run$1(depsMap.get(ITERATE_KEY)),isMap(target)&&run$1(depsMap.get(MAP_KEY_ITERATE_KEY)));break;case`delete`:targetIsArray||(run$1(depsMap.get(ITERATE_KEY)),isMap(target)&&run$1(depsMap.get(MAP_KEY_ITERATE_KEY)));break;case`set`:isMap(target)&&run$1(depsMap.get(ITERATE_KEY));break}}endBatch()}function getDepFromReactive(object,key){let depMap=targetMap.get(object);return depMap&&depMap.get(key)}function reactiveReadArray(array){let raw=toRaw(array);return raw===array?raw:(track(raw,`iterate`,ARRAY_ITERATE_KEY),isShallow(array)?raw:raw.map(toReactive))}function shallowReadArray(arr){return track(arr=toRaw(arr),`iterate`,ARRAY_ITERATE_KEY),arr}var arrayInstrumentations={__proto__:null,[Symbol.iterator](){return iterator(this,Symbol.iterator,toReactive)},concat(...args){return reactiveReadArray(this).concat(...args.map(x=>isArray$2(x)?reactiveReadArray(x):x))},entries(){return iterator(this,`entries`,value=>(value[1]=toReactive(value[1]),value))},every(fn,thisArg){return apply(this,`every`,fn,thisArg,void 0,arguments)},filter(fn,thisArg){return apply(this,`filter`,fn,thisArg,v=>v.map(toReactive),arguments)},find(fn,thisArg){return apply(this,`find`,fn,thisArg,toReactive,arguments)},findIndex(fn,thisArg){return apply(this,`findIndex`,fn,thisArg,void 0,arguments)},findLast(fn,thisArg){return apply(this,`findLast`,fn,thisArg,toReactive,arguments)},findLastIndex(fn,thisArg){return apply(this,`findLastIndex`,fn,thisArg,void 0,arguments)},forEach(fn,thisArg){return apply(this,`forEach`,fn,thisArg,void 0,arguments)},includes(...args){return searchProxy(this,`includes`,args)},indexOf(...args){return searchProxy(this,`indexOf`,args)},join(separator){return reactiveReadArray(this).join(separator)},lastIndexOf(...args){return searchProxy(this,`lastIndexOf`,args)},map(fn,thisArg){return apply(this,`map`,fn,thisArg,void 0,arguments)},pop(){return noTracking(this,`pop`)},push(...args){return noTracking(this,`push`,args)},reduce(fn,...args){return reduce(this,`reduce`,fn,args)},reduceRight(fn,...args){return reduce(this,`reduceRight`,fn,args)},shift(){return noTracking(this,`shift`)},some(fn,thisArg){return apply(this,`some`,fn,thisArg,void 0,arguments)},splice(...args){return noTracking(this,`splice`,args)},toReversed(){return reactiveReadArray(this).toReversed()},toSorted(comparer){return reactiveReadArray(this).toSorted(comparer)},toSpliced(...args){return reactiveReadArray(this).toSpliced(...args)},unshift(...args){return noTracking(this,`unshift`,args)},values(){return iterator(this,`values`,toReactive)}};function iterator(self$1,method,wrapValue){let arr=shallowReadArray(self$1),iter=arr[method]();return arr!==self$1&&!isShallow(self$1)&&(iter._next=iter.next,iter.next=()=>{let result=iter._next();return result.done||(result.value=wrapValue(result.value)),result}),iter}var arrayProto=Array.prototype;function apply(self$1,method,fn,thisArg,wrappedRetFn,args){let arr=shallowReadArray(self$1),needsWrap=arr!==self$1&&!isShallow(self$1),methodFn=arr[method];if(methodFn!==arrayProto[method]){let result2=methodFn.apply(self$1,args);return needsWrap?toReactive(result2):result2}let wrappedFn=fn;arr!==self$1&&(needsWrap?wrappedFn=function(item,index){return fn.call(this,toReactive(item),index,self$1)}:fn.length>2&&(wrappedFn=function(item,index){return fn.call(this,item,index,self$1)}));let result=methodFn.call(arr,wrappedFn,thisArg);return needsWrap&&wrappedRetFn?wrappedRetFn(result):result}function reduce(self$1,method,fn,args){let arr=shallowReadArray(self$1),wrappedFn=fn;return arr!==self$1&&(isShallow(self$1)?fn.length>3&&(wrappedFn=function(acc,item,index){return fn.call(this,acc,item,index,self$1)}):wrappedFn=function(acc,item,index){return fn.call(this,acc,toReactive(item),index,self$1)}),arr[method](wrappedFn,...args)}function searchProxy(self$1,method,args){let arr=toRaw(self$1);track(arr,`iterate`,ARRAY_ITERATE_KEY);let res=arr[method](...args);return(res===-1||res===!1)&&isProxy(args[0])?(args[0]=toRaw(args[0]),arr[method](...args)):res}function noTracking(self$1,method,args=[]){pauseTracking(),startBatch();let res=toRaw(self$1)[method].apply(self$1,args);return endBatch(),resetTracking(),res}var isNonTrackableKeys=makeMap(`__proto__,__v_isRef,__isVue`),builtInSymbols=new Set(Object.getOwnPropertyNames(Symbol).filter(key=>key!==`arguments`&&key!==`caller`).map(key=>Symbol[key]).filter(isSymbol));function hasOwnProperty$1(key){isSymbol(key)||(key=String(key));let obj=toRaw(this);return track(obj,`has`,key),obj.hasOwnProperty(key)}var BaseReactiveHandler=class{constructor(_isReadonly=!1,_isShallow=!1){this._isReadonly=_isReadonly,this._isShallow=_isShallow}get(target,key,receiver){if(key===`__v_skip`)return target.__v_skip;let isReadonly2=this._isReadonly,isShallow2=this._isShallow;if(key===`__v_isReactive`)return!isReadonly2;if(key===`__v_isReadonly`)return isReadonly2;if(key===`__v_isShallow`)return isShallow2;if(key===`__v_raw`)return receiver===(isReadonly2?isShallow2?shallowReadonlyMap:readonlyMap:isShallow2?shallowReactiveMap:reactiveMap).get(target)||Object.getPrototypeOf(target)===Object.getPrototypeOf(receiver)?target:void 0;let targetIsArray=isArray$2(target);if(!isReadonly2){let fn;if(targetIsArray&&(fn=arrayInstrumentations[key]))return fn;if(key===`hasOwnProperty`)return hasOwnProperty$1}let res=Reflect.get(target,key,isRef(target)?target:receiver);if((isSymbol(key)?builtInSymbols.has(key):isNonTrackableKeys(key))||(isReadonly2||track(target,`get`,key),isShallow2))return res;if(isRef(res)){let value=targetIsArray&&isIntegerKey(key)?res:res.value;return isReadonly2&&isObject$1(value)?readonly(value):value}return isObject$1(res)?isReadonly2?readonly(res):reactive(res):res}},MutableReactiveHandler=class extends BaseReactiveHandler{constructor(isShallow2=!1){super(!1,isShallow2)}set(target,key,value,receiver){let oldValue=target[key];if(!this._isShallow){let isOldValueReadonly=isReadonly(oldValue);if(!isShallow(value)&&!isReadonly(value)&&(oldValue=toRaw(oldValue),value=toRaw(value)),!isArray$2(target)&&isRef(oldValue)&&!isRef(value))return isOldValueReadonly||(oldValue.value=value),!0}let hadKey=isArray$2(target)&&isIntegerKey(key)?Number(key)value,getProto=v=>Reflect.getPrototypeOf(v);function createIterableMethod(method,isReadonly2,isShallow2){return function(...args){let target=this.__v_raw,rawTarget=toRaw(target),targetIsMap=isMap(rawTarget),isPair=method===`entries`||method===Symbol.iterator&&targetIsMap,isKeyOnly=method===`keys`&&targetIsMap,innerIterator=target[method](...args),wrap=isShallow2?toShallow:isReadonly2?toReadonly:toReactive;return!isReadonly2&&track(rawTarget,`iterate`,isKeyOnly?MAP_KEY_ITERATE_KEY:ITERATE_KEY),{next(){let{value,done}=innerIterator.next();return done?{value,done}:{value:isPair?[wrap(value[0]),wrap(value[1])]:wrap(value),done}},[Symbol.iterator](){return this}}}}function createReadonlyMethod(type){return function(...args){return type===`delete`?!1:type===`clear`?void 0:this}}function createInstrumentations(readonly$1,shallow){let instrumentations={get(key){let target=this.__v_raw,rawTarget=toRaw(target),rawKey=toRaw(key);readonly$1||(hasChanged(key,rawKey)&&track(rawTarget,`get`,key),track(rawTarget,`get`,rawKey));let{has:has$1}=getProto(rawTarget),wrap=shallow?toShallow:readonly$1?toReadonly:toReactive;if(has$1.call(rawTarget,key))return wrap(target.get(key));if(has$1.call(rawTarget,rawKey))return wrap(target.get(rawKey));target!==rawTarget&&target.get(key)},get size(){let target=this.__v_raw;return!readonly$1&&track(toRaw(target),`iterate`,ITERATE_KEY),target.size},has(key){let target=this.__v_raw,rawTarget=toRaw(target),rawKey=toRaw(key);return readonly$1||(hasChanged(key,rawKey)&&track(rawTarget,`has`,key),track(rawTarget,`has`,rawKey)),key===rawKey?target.has(key):target.has(key)||target.has(rawKey)},forEach(callback,thisArg){let observed$2=this,target=observed$2.__v_raw,rawTarget=toRaw(target),wrap=shallow?toShallow:readonly$1?toReadonly:toReactive;return!readonly$1&&track(rawTarget,`iterate`,ITERATE_KEY),target.forEach((value,key)=>callback.call(thisArg,wrap(value),wrap(key),observed$2))}};return extend(instrumentations,readonly$1?{add:createReadonlyMethod(`add`),set:createReadonlyMethod(`set`),delete:createReadonlyMethod(`delete`),clear:createReadonlyMethod(`clear`)}:{add(value){!shallow&&!isShallow(value)&&!isReadonly(value)&&(value=toRaw(value));let target=toRaw(this);return getProto(target).has.call(target,value)||(target.add(value),trigger$1(target,`add`,value,value)),this},set(key,value){!shallow&&!isShallow(value)&&!isReadonly(value)&&(value=toRaw(value));let target=toRaw(this),{has:has$1,get}=getProto(target),hadKey=has$1.call(target,key);hadKey||=(key=toRaw(key),has$1.call(target,key));let oldValue=get.call(target,key);return target.set(key,value),hadKey?hasChanged(value,oldValue)&&trigger$1(target,`set`,key,value,oldValue):trigger$1(target,`add`,key,value),this},delete(key){let target=toRaw(this),{has:has$1,get}=getProto(target),hadKey=has$1.call(target,key);hadKey||=(key=toRaw(key),has$1.call(target,key));let oldValue=get?get.call(target,key):void 0,result=target.delete(key);return hadKey&&trigger$1(target,`delete`,key,void 0,oldValue),result},clear(){let target=toRaw(this),hadItems=target.size!==0,oldTarget,result=target.clear();return hadItems&&trigger$1(target,`clear`,void 0,void 0,void 0),result}}),[`keys`,`values`,`entries`,Symbol.iterator].forEach(method=>{instrumentations[method]=createIterableMethod(method,readonly$1,shallow)}),instrumentations}function createInstrumentationGetter(isReadonly2,shallow){let instrumentations=createInstrumentations(isReadonly2,shallow);return(target,key,receiver)=>key===`__v_isReactive`?!isReadonly2:key===`__v_isReadonly`?isReadonly2:key===`__v_raw`?target:Reflect.get(hasOwn$1(instrumentations,key)&&key in target?instrumentations:target,key,receiver)}var mutableCollectionHandlers={get:createInstrumentationGetter(!1,!1)},shallowCollectionHandlers={get:createInstrumentationGetter(!1,!0)},readonlyCollectionHandlers={get:createInstrumentationGetter(!0,!1)},shallowReadonlyCollectionHandlers={get:createInstrumentationGetter(!0,!0)},reactiveMap=new WeakMap,shallowReactiveMap=new WeakMap,readonlyMap=new WeakMap,shallowReadonlyMap=new WeakMap;function targetTypeMap(rawType){switch(rawType){case`Object`:case`Array`:return 1;case`Map`:case`Set`:case`WeakMap`:case`WeakSet`:return 2;default:return 0}}function getTargetType(value){return value.__v_skip||!Object.isExtensible(value)?0:targetTypeMap(toRawType(value))}function reactive(target){return isReadonly(target)?target:createReactiveObject(target,!1,mutableHandlers,mutableCollectionHandlers,reactiveMap)}function shallowReactive(target){return createReactiveObject(target,!1,shallowReactiveHandlers,shallowCollectionHandlers,shallowReactiveMap)}function readonly(target){return createReactiveObject(target,!0,readonlyHandlers,readonlyCollectionHandlers,readonlyMap)}function shallowReadonly(target){return createReactiveObject(target,!0,shallowReadonlyHandlers,shallowReadonlyCollectionHandlers,shallowReadonlyMap)}function createReactiveObject(target,isReadonly2,baseHandlers,collectionHandlers,proxyMap){if(!isObject$1(target)||target.__v_raw&&!(isReadonly2&&target.__v_isReactive))return target;let targetType=getTargetType(target);if(targetType===0)return target;let existingProxy=proxyMap.get(target);if(existingProxy)return existingProxy;let proxy=new Proxy(target,targetType===2?collectionHandlers:baseHandlers);return proxyMap.set(target,proxy),proxy}function isReactive(value){return isReadonly(value)?isReactive(value.__v_raw):!!(value&&value.__v_isReactive)}function isReadonly(value){return!!(value&&value.__v_isReadonly)}function isShallow(value){return!!(value&&value.__v_isShallow)}function isProxy(value){return value?!!value.__v_raw:!1}function toRaw(observed$2){let raw=observed$2&&observed$2.__v_raw;return raw?toRaw(raw):observed$2}function markRaw(value){return!hasOwn$1(value,`__v_skip`)&&Object.isExtensible(value)&&def(value,`__v_skip`,!0),value}var toReactive=value=>isObject$1(value)?reactive(value):value,toReadonly=value=>isObject$1(value)?readonly(value):value;function isRef(r){return r?r.__v_isRef===!0:!1}function ref(value){return createRef(value,!1)}function shallowRef(value){return createRef(value,!0)}function createRef(rawValue,shallow){return isRef(rawValue)?rawValue:new RefImpl(rawValue,shallow)}var RefImpl=class{constructor(value,isShallow2){this.dep=new Dep,this.__v_isRef=!0,this.__v_isShallow=!1,this._rawValue=isShallow2?value:toRaw(value),this._value=isShallow2?value:toReactive(value),this.__v_isShallow=isShallow2}get value(){return this.dep.track(),this._value}set value(newValue){let oldValue=this._rawValue,useDirectValue=this.__v_isShallow||isShallow(newValue)||isReadonly(newValue);newValue=useDirectValue?newValue:toRaw(newValue),hasChanged(newValue,oldValue)&&(this._rawValue=newValue,this._value=useDirectValue?newValue:toReactive(newValue),this.dep.trigger())}};function triggerRef(ref2){ref2.dep&&ref2.dep.trigger()}function unref(ref2){return isRef(ref2)?ref2.value:ref2}function toValue$1(source){return isFunction$1(source)?source():unref(source)}var shallowUnwrapHandlers={get:(target,key,receiver)=>key===`__v_raw`?target:unref(Reflect.get(target,key,receiver)),set:(target,key,value,receiver)=>{let oldValue=target[key];return isRef(oldValue)&&!isRef(value)?(oldValue.value=value,!0):Reflect.set(target,key,value,receiver)}};function proxyRefs(objectWithRefs){return isReactive(objectWithRefs)?objectWithRefs:new Proxy(objectWithRefs,shallowUnwrapHandlers)}var CustomRefImpl=class{constructor(factory){this.__v_isRef=!0,this._value=void 0;let dep=this.dep=new Dep,{get,set}=factory(dep.track.bind(dep),dep.trigger.bind(dep));this._get=get,this._set=set}get value(){return this._value=this._get()}set value(newVal){this._set(newVal)}};function customRef(factory){return new CustomRefImpl(factory)}function toRefs(object){let ret=isArray$2(object)?Array(object.length):{};for(let key in object)ret[key]=propertyToRef(object,key);return ret}var ObjectRefImpl=class{constructor(_object,_key,_defaultValue){this._object=_object,this._key=_key,this._defaultValue=_defaultValue,this.__v_isRef=!0,this._value=void 0}get value(){let val=this._object[this._key];return this._value=val===void 0?this._defaultValue:val}set value(newVal){this._object[this._key]=newVal}get dep(){return getDepFromReactive(toRaw(this._object),this._key)}},GetterRefImpl=class{constructor(_getter){this._getter=_getter,this.__v_isRef=!0,this.__v_isReadonly=!0,this._value=void 0}get value(){return this._value=this._getter()}};function toRef(source,key,defaultValue){return isRef(source)?source:isFunction$1(source)?new GetterRefImpl(source):isObject$1(source)&&arguments.length>1?propertyToRef(source,key,defaultValue):ref(source)}function propertyToRef(source,key,defaultValue){let val=source[key];return isRef(val)?val:new ObjectRefImpl(source,key,defaultValue)}var ComputedRefImpl=class{constructor(fn,setter,isSSR){this.fn=fn,this.setter=setter,this._value=void 0,this.dep=new Dep(this),this.__v_isRef=!0,this.deps=void 0,this.depsTail=void 0,this.flags=16,this.globalVersion=globalVersion-1,this.next=void 0,this.effect=this,this.__v_isReadonly=!setter,this.isSSR=isSSR}notify(){if(this.flags|=16,!(this.flags&8)&&activeSub!==this)return batch(this,!0),!0}get value(){let link=this.dep.track();return refreshComputed(this),link&&(link.version=this.dep.version),this._value}set value(newValue){this.setter&&this.setter(newValue)}};function computed$1(getterOrOptions,debugOptions,isSSR=!1){let getter,setter;return isFunction$1(getterOrOptions)?getter=getterOrOptions:(getter=getterOrOptions.get,setter=getterOrOptions.set),new ComputedRefImpl(getter,setter,isSSR)}var TrackOpTypes={GET:`get`,HAS:`has`,ITERATE:`iterate`},TriggerOpTypes={SET:`set`,ADD:`add`,DELETE:`delete`,CLEAR:`clear`},INITIAL_WATCHER_VALUE={},cleanupMap=new WeakMap,activeWatcher=void 0;function getCurrentWatcher(){return activeWatcher}function onWatcherCleanup(cleanupFn,failSilently=!1,owner=activeWatcher){if(owner){let cleanups=cleanupMap.get(owner);cleanups||cleanupMap.set(owner,cleanups=[]),cleanups.push(cleanupFn)}}function watch$1(source,cb,options=EMPTY_OBJ){let{immediate,deep,once,scheduler,augmentJob,call}=options,reactiveGetter=source2=>deep?source2:isShallow(source2)||deep===!1||deep===0?traverse(source2,1):traverse(source2),effect$1,getter,cleanup,boundCleanup,forceTrigger=!1,isMultiSource=!1;if(isRef(source)?(getter=()=>source.value,forceTrigger=isShallow(source)):isReactive(source)?(getter=()=>reactiveGetter(source),forceTrigger=!0):isArray$2(source)?(isMultiSource=!0,forceTrigger=source.some(s=>isReactive(s)||isShallow(s)),getter=()=>source.map(s=>{if(isRef(s))return s.value;if(isReactive(s))return reactiveGetter(s);if(isFunction$1(s))return call?call(s,2):s()})):getter=isFunction$1(source)?cb?call?()=>call(source,2):source:()=>{if(cleanup){pauseTracking();try{cleanup()}finally{resetTracking()}}let currentEffect=activeWatcher;activeWatcher=effect$1;try{return call?call(source,3,[boundCleanup]):source(boundCleanup)}finally{activeWatcher=currentEffect}}:NOOP,cb&&deep){let baseGetter=getter,depth=deep===!0?1/0:deep;getter=()=>traverse(baseGetter(),depth)}let scope$1=getCurrentScope(),watchHandle=()=>{effect$1.stop(),scope$1&&scope$1.active&&remove$2(scope$1.effects,effect$1)};if(once&&cb){let _cb=cb;cb=(...args)=>{_cb(...args),watchHandle()}}let oldValue=isMultiSource?Array(source.length).fill(INITIAL_WATCHER_VALUE):INITIAL_WATCHER_VALUE,job=immediateFirstRun=>{if(!(!(effect$1.flags&1)||!effect$1.dirty&&!immediateFirstRun))if(cb){let newValue=effect$1.run();if(deep||forceTrigger||(isMultiSource?newValue.some((v,i)=>hasChanged(v,oldValue[i])):hasChanged(newValue,oldValue))){cleanup&&cleanup();let currentWatcher=activeWatcher;activeWatcher=effect$1;try{let args=[newValue,oldValue===INITIAL_WATCHER_VALUE?void 0:isMultiSource&&oldValue[0]===INITIAL_WATCHER_VALUE?[]:oldValue,boundCleanup];oldValue=newValue,call?call(cb,3,args):cb(...args)}finally{activeWatcher=currentWatcher}}}else effect$1.run()};return augmentJob&&augmentJob(job),effect$1=new ReactiveEffect(getter),effect$1.scheduler=scheduler?()=>scheduler(job,!1):job,boundCleanup=fn=>onWatcherCleanup(fn,!1,effect$1),cleanup=effect$1.onStop=()=>{let cleanups=cleanupMap.get(effect$1);if(cleanups){if(call)call(cleanups,4);else for(let cleanup2 of cleanups)cleanup2();cleanupMap.delete(effect$1)}},cb?immediate?job(!0):oldValue=effect$1.run():scheduler?scheduler(job.bind(null,!0),!0):effect$1.run(),watchHandle.pause=effect$1.pause.bind(effect$1),watchHandle.resume=effect$1.resume.bind(effect$1),watchHandle.stop=watchHandle,watchHandle}function traverse(value,depth=1/0,seen$3){if(depth<=0||!isObject$1(value)||value.__v_skip||(seen$3||=new Map,(seen$3.get(value)||0)>=depth))return value;if(seen$3.set(value,depth),depth--,isRef(value))traverse(value.value,depth,seen$3);else if(isArray$2(value))for(let i=0;i{traverse(v,depth,seen$3)});else if(isPlainObject$2(value)){for(let key in value)traverse(value[key],depth,seen$3);for(let key of Object.getOwnPropertySymbols(value))Object.prototype.propertyIsEnumerable.call(value,key)&&traverse(value[key],depth,seen$3)}return value}var stack$1=[];function pushWarningContext(vnode){stack$1.push(vnode)}function popWarningContext(){stack$1.pop()}function assertNumber(val,type){}var ErrorCodes={SETUP_FUNCTION:0,0:`SETUP_FUNCTION`,RENDER_FUNCTION:1,1:`RENDER_FUNCTION`,NATIVE_EVENT_HANDLER:5,5:`NATIVE_EVENT_HANDLER`,COMPONENT_EVENT_HANDLER:6,6:`COMPONENT_EVENT_HANDLER`,VNODE_HOOK:7,7:`VNODE_HOOK`,DIRECTIVE_HOOK:8,8:`DIRECTIVE_HOOK`,TRANSITION_HOOK:9,9:`TRANSITION_HOOK`,APP_ERROR_HANDLER:10,10:`APP_ERROR_HANDLER`,APP_WARN_HANDLER:11,11:`APP_WARN_HANDLER`,FUNCTION_REF:12,12:`FUNCTION_REF`,ASYNC_COMPONENT_LOADER:13,13:`ASYNC_COMPONENT_LOADER`,SCHEDULER:14,14:`SCHEDULER`,COMPONENT_UPDATE:15,15:`COMPONENT_UPDATE`,APP_UNMOUNT_CLEANUP:16,16:`APP_UNMOUNT_CLEANUP`},ErrorTypeStrings$1={sp:`serverPrefetch hook`,bc:`beforeCreate hook`,c:`created hook`,bm:`beforeMount hook`,m:`mounted hook`,bu:`beforeUpdate hook`,u:`updated`,bum:`beforeUnmount hook`,um:`unmounted hook`,a:`activated hook`,da:`deactivated hook`,ec:`errorCaptured hook`,rtc:`renderTracked hook`,rtg:`renderTriggered hook`,0:`setup function`,1:`render function`,2:`watcher getter`,3:`watcher callback`,4:`watcher cleanup function`,5:`native event handler`,6:`component event handler`,7:`vnode hook`,8:`directive hook`,9:`transition hook`,10:`app errorHandler`,11:`app warnHandler`,12:`ref function`,13:`async component loader`,14:`scheduler flush`,15:`component update`,16:`app unmount cleanup function`};function callWithErrorHandling(fn,instance$1,type,args){try{return args?fn(...args):fn()}catch(err){handleError(err,instance$1,type)}}function callWithAsyncErrorHandling(fn,instance$1,type,args){if(isFunction$1(fn)){let res=callWithErrorHandling(fn,instance$1,type,args);return res&&isPromise$1(res)&&res.catch(err=>{handleError(err,instance$1,type)}),res}if(isArray$2(fn)){let values=[];for(let i=0;i>>1,middleJob=queue$1[middle],middleJobId=getId(middleJob);middleJobId=getId(lastJob)?queue$1.push(job):queue$1.splice(findInsertionIndex$1(jobId),0,job),job.flags|=1,queueFlush()}}function queueFlush(){currentFlushPromise||=resolvedPromise.then(flushJobs)}function queuePostFlushCb(cb){isArray$2(cb)?pendingPostFlushCbs.push(...cb):activePostFlushCbs&&cb.id===-1?activePostFlushCbs.splice(postFlushIndex+1,0,cb):cb.flags&1||(pendingPostFlushCbs.push(cb),cb.flags|=1),queueFlush()}function flushPreFlushCbs(instance$1,seen$3,i=flushIndex+1){for(;igetId(a$1)-getId(b));if(pendingPostFlushCbs.length=0,activePostFlushCbs){activePostFlushCbs.push(...deduped);return}for(activePostFlushCbs=deduped,postFlushIndex=0;postFlushIndexjob.id==null?job.flags&2?-1:1/0:job.id;function flushJobs(seen$3){try{for(flushIndex=0;flushIndexdevtools$1.emit(event,...args)),buffer=[]):typeof window<`u`&&window.HTMLElement&&!(window.navigator?.userAgent)?.includes(`jsdom`)?((target.__VUE_DEVTOOLS_HOOK_REPLAY__=target.__VUE_DEVTOOLS_HOOK_REPLAY__||[]).push(newHook=>{setDevtoolsHook$1(newHook,target)}),setTimeout(()=>{devtools$1||(target.__VUE_DEVTOOLS_HOOK_REPLAY__=null,buffer=[])},3e3)):buffer=[]}var currentRenderingInstance=null,currentScopeId=null;function setCurrentRenderingInstance(instance$1){let prev=currentRenderingInstance;return currentRenderingInstance=instance$1,currentScopeId=instance$1&&instance$1.type.__scopeId||null,prev}function pushScopeId(id){currentScopeId=id}function popScopeId(){currentScopeId=null}var withScopeId=_id=>withCtx;function withCtx(fn,ctx=currentRenderingInstance,isNonScopedSlot){if(!ctx||fn._n)return fn;let renderFnWithContext=(...args)=>{renderFnWithContext._d&&setBlockTracking(-1);let prevInstance=setCurrentRenderingInstance(ctx),res;try{res=fn(...args)}finally{setCurrentRenderingInstance(prevInstance),renderFnWithContext._d&&setBlockTracking(1)}return res};return renderFnWithContext._n=!0,renderFnWithContext._c=!0,renderFnWithContext._d=!0,renderFnWithContext}function withDirectives(vnode,directives){if(currentRenderingInstance===null)return vnode;let instance$1=getComponentPublicInstance(currentRenderingInstance),bindings=vnode.dirs||=[];for(let i=0;itype.__isTeleport,isTeleportDisabled=props=>props&&(props.disabled||props.disabled===``),isTeleportDeferred=props=>props&&(props.defer||props.defer===``),isTargetSVG=target=>typeof SVGElement<`u`&&target instanceof SVGElement,isTargetMathML=target=>typeof MathMLElement==`function`&&target instanceof MathMLElement,resolveTarget=(props,select)=>{let targetSelector=props&&props.to;return isString$1(targetSelector)?select?select(targetSelector):null:targetSelector},TeleportImpl={name:`Teleport`,__isTeleport:!0,process(n1,n2,container,anchor,parentComponent,parentSuspense,namespace,slotScopeIds,optimized,internals){let{mc:mountChildren,pc:patchChildren,pbc:patchBlockChildren,o:{insert,querySelector,createText,createComment}}=internals,disabled=isTeleportDisabled(n2.props),{shapeFlag,children,dynamicChildren}=n2;if(n1==null){let placeholder=n2.el=createText(``),mainAnchor=n2.anchor=createText(``);insert(placeholder,container,anchor),insert(mainAnchor,container,anchor);let mount=(container2,anchor2)=>{shapeFlag&16&&mountChildren(children,container2,anchor2,parentComponent,parentSuspense,namespace,slotScopeIds,optimized)},mountToTarget=()=>{let target=n2.target=resolveTarget(n2.props,querySelector),targetAnchor=prepareAnchor(target,n2,createText,insert);target&&(namespace!==`svg`&&isTargetSVG(target)?namespace=`svg`:namespace!==`mathml`&&isTargetMathML(target)&&(namespace=`mathml`),parentComponent&&parentComponent.isCE&&(parentComponent.ce._teleportTargets||(parentComponent.ce._teleportTargets=new Set)).add(target),disabled||(mount(target,targetAnchor),updateCssVars(n2,!1)))};disabled&&(mount(container,mainAnchor),updateCssVars(n2,!0)),isTeleportDeferred(n2.props)?(n2.el.__isMounted=!1,queuePostRenderEffect(()=>{mountToTarget(),delete n2.el.__isMounted},parentSuspense)):mountToTarget()}else{if(isTeleportDeferred(n2.props)&&n1.el.__isMounted===!1){queuePostRenderEffect(()=>{TeleportImpl.process(n1,n2,container,anchor,parentComponent,parentSuspense,namespace,slotScopeIds,optimized,internals)},parentSuspense);return}n2.el=n1.el,n2.targetStart=n1.targetStart;let mainAnchor=n2.anchor=n1.anchor,target=n2.target=n1.target,targetAnchor=n2.targetAnchor=n1.targetAnchor,wasDisabled=isTeleportDisabled(n1.props),currentContainer=wasDisabled?container:target,currentAnchor=wasDisabled?mainAnchor:targetAnchor;if(namespace===`svg`||isTargetSVG(target)?namespace=`svg`:(namespace===`mathml`||isTargetMathML(target))&&(namespace=`mathml`),dynamicChildren?(patchBlockChildren(n1.dynamicChildren,dynamicChildren,currentContainer,parentComponent,parentSuspense,namespace,slotScopeIds),traverseStaticChildren(n1,n2,!0)):optimized||patchChildren(n1,n2,currentContainer,currentAnchor,parentComponent,parentSuspense,namespace,slotScopeIds,!1),disabled)wasDisabled?n2.props&&n1.props&&n2.props.to!==n1.props.to&&(n2.props.to=n1.props.to):moveTeleport(n2,container,mainAnchor,internals,1);else if((n2.props&&n2.props.to)!==(n1.props&&n1.props.to)){let nextTarget=n2.target=resolveTarget(n2.props,querySelector);nextTarget&&moveTeleport(n2,nextTarget,null,internals,0)}else wasDisabled&&moveTeleport(n2,target,targetAnchor,internals,1);updateCssVars(n2,disabled)}},remove(vnode,parentComponent,parentSuspense,{um:unmount,o:{remove:hostRemove}},doRemove){let{shapeFlag,children,anchor,targetStart,targetAnchor,target,props}=vnode;if(target&&(hostRemove(targetStart),hostRemove(targetAnchor)),doRemove&&hostRemove(anchor),shapeFlag&16){let shouldRemove=doRemove||!isTeleportDisabled(props);for(let i=0;i{state.isMounted=!0}),onBeforeUnmount(()=>{state.isUnmounting=!0}),state}var TransitionHookValidator=[Function,Array],BaseTransitionPropsValidators={mode:String,appear:Boolean,persisted:Boolean,onBeforeEnter:TransitionHookValidator,onEnter:TransitionHookValidator,onAfterEnter:TransitionHookValidator,onEnterCancelled:TransitionHookValidator,onBeforeLeave:TransitionHookValidator,onLeave:TransitionHookValidator,onAfterLeave:TransitionHookValidator,onLeaveCancelled:TransitionHookValidator,onBeforeAppear:TransitionHookValidator,onAppear:TransitionHookValidator,onAfterAppear:TransitionHookValidator,onAppearCancelled:TransitionHookValidator},recursiveGetSubtree=instance$1=>{let subTree=instance$1.subTree;return subTree.component?recursiveGetSubtree(subTree.component):subTree},BaseTransitionImpl={name:`BaseTransition`,props:BaseTransitionPropsValidators,setup(props,{slots}){let instance$1=getCurrentInstance(),state=useTransitionState();return()=>{let children=slots.default&&getTransitionRawChildren(slots.default(),!0);if(!children||!children.length)return;let child=findNonCommentChild(children),rawProps=toRaw(props),{mode}=rawProps;if(state.isLeaving)return emptyPlaceholder(child);let innerChild=getInnerChild$1(child);if(!innerChild)return emptyPlaceholder(child);let enterHooks=resolveTransitionHooks(innerChild,rawProps,state,instance$1,hooks=>enterHooks=hooks);innerChild.type!==Comment&&setTransitionHooks(innerChild,enterHooks);let oldInnerChild=instance$1.subTree&&getInnerChild$1(instance$1.subTree);if(oldInnerChild&&oldInnerChild.type!==Comment&&!isSameVNodeType(oldInnerChild,innerChild)&&recursiveGetSubtree(instance$1).type!==Comment){let leavingHooks=resolveTransitionHooks(oldInnerChild,rawProps,state,instance$1);if(setTransitionHooks(oldInnerChild,leavingHooks),mode===`out-in`&&innerChild.type!==Comment)return state.isLeaving=!0,leavingHooks.afterLeave=()=>{state.isLeaving=!1,instance$1.job.flags&8||instance$1.update(),delete leavingHooks.afterLeave,oldInnerChild=void 0},emptyPlaceholder(child);mode===`in-out`&&innerChild.type!==Comment?leavingHooks.delayLeave=(el,earlyRemove,delayedLeave)=>{let leavingVNodesCache=getLeavingNodesForType(state,oldInnerChild);leavingVNodesCache[String(oldInnerChild.key)]=oldInnerChild,el[leaveCbKey]=()=>{earlyRemove(),el[leaveCbKey]=void 0,delete enterHooks.delayedLeave,oldInnerChild=void 0},enterHooks.delayedLeave=()=>{delayedLeave(),delete enterHooks.delayedLeave,oldInnerChild=void 0}}:oldInnerChild=void 0}else oldInnerChild&&=void 0;return child}}};function findNonCommentChild(children){let child=children[0];if(children.length>1){for(let c of children)if(c.type!==Comment){child=c;break}}return child}var BaseTransition=BaseTransitionImpl;function getLeavingNodesForType(state,vnode){let{leavingVNodes}=state,leavingVNodesCache=leavingVNodes.get(vnode.type);return leavingVNodesCache||(leavingVNodesCache=Object.create(null),leavingVNodes.set(vnode.type,leavingVNodesCache)),leavingVNodesCache}function resolveTransitionHooks(vnode,props,state,instance$1,postClone){let{appear,mode,persisted=!1,onBeforeEnter,onEnter,onAfterEnter,onEnterCancelled,onBeforeLeave,onLeave,onAfterLeave,onLeaveCancelled,onBeforeAppear,onAppear,onAfterAppear,onAppearCancelled}=props,key=String(vnode.key),leavingVNodesCache=getLeavingNodesForType(state,vnode),callHook$2=(hook,args)=>{hook&&callWithAsyncErrorHandling(hook,instance$1,9,args)},callAsyncHook=(hook,args)=>{let done=args[1];callHook$2(hook,args),isArray$2(hook)?hook.every(hook2=>hook2.length<=1)&&done():hook.length<=1&&done()},hooks={mode,persisted,beforeEnter(el){let hook=onBeforeEnter;if(!state.isMounted)if(appear)hook=onBeforeAppear||onBeforeEnter;else return;el[leaveCbKey]&&el[leaveCbKey](!0);let leavingVNode=leavingVNodesCache[key];leavingVNode&&isSameVNodeType(vnode,leavingVNode)&&leavingVNode.el[leaveCbKey]&&leavingVNode.el[leaveCbKey](),callHook$2(hook,[el])},enter(el){let hook=onEnter,afterHook=onAfterEnter,cancelHook=onEnterCancelled;if(!state.isMounted)if(appear)hook=onAppear||onEnter,afterHook=onAfterAppear||onAfterEnter,cancelHook=onAppearCancelled||onEnterCancelled;else return;let called=!1,done=el[enterCbKey$1]=cancelled=>{called||(called=!0,callHook$2(cancelled?cancelHook:afterHook,[el]),hooks.delayedLeave&&hooks.delayedLeave(),el[enterCbKey$1]=void 0)};hook?callAsyncHook(hook,[el,done]):done()},leave(el,remove$3){let key2=String(vnode.key);if(el[enterCbKey$1]&&el[enterCbKey$1](!0),state.isUnmounting)return remove$3();callHook$2(onBeforeLeave,[el]);let called=!1,done=el[leaveCbKey]=cancelled=>{called||(called=!0,remove$3(),callHook$2(cancelled?onLeaveCancelled:onAfterLeave,[el]),el[leaveCbKey]=void 0,leavingVNodesCache[key2]===vnode&&delete leavingVNodesCache[key2])};leavingVNodesCache[key2]=vnode,onLeave?callAsyncHook(onLeave,[el,done]):done()},clone(vnode2){let hooks2=resolveTransitionHooks(vnode2,props,state,instance$1,postClone);return postClone&&postClone(hooks2),hooks2}};return hooks}function emptyPlaceholder(vnode){if(isKeepAlive(vnode))return vnode=cloneVNode(vnode),vnode.children=null,vnode}function getInnerChild$1(vnode){if(!isKeepAlive(vnode))return isTeleport(vnode.type)&&vnode.children?findNonCommentChild(vnode.children):vnode;if(vnode.component)return vnode.component.subTree;let{shapeFlag,children}=vnode;if(children){if(shapeFlag&16)return children[0];if(shapeFlag&32&&isFunction$1(children.default))return children.default()}}function setTransitionHooks(vnode,hooks){vnode.shapeFlag&6&&vnode.component?(vnode.transition=hooks,setTransitionHooks(vnode.component.subTree,hooks)):vnode.shapeFlag&128?(vnode.ssContent.transition=hooks.clone(vnode.ssContent),vnode.ssFallback.transition=hooks.clone(vnode.ssFallback)):vnode.transition=hooks}function getTransitionRawChildren(children,keepComment=!1,parentKey){let ret=[],keyedFragmentCount=0;for(let i=0;i1)for(let i=0;iextend({name:options.name},extraOptions,{setup:options}))():options}function useId(){let i=getCurrentInstance();return i?(i.appContext.config.idPrefix||`v`)+`-`+i.ids[0]+ i.ids[1]++:``}function markAsyncBoundary(instance$1){instance$1.ids=[instance$1.ids[0]+ instance$1.ids[2]+++`-`,0,0]}function useTemplateRef(key){let i=getCurrentInstance(),r=shallowRef(null);if(i){let refs=i.refs===EMPTY_OBJ?i.refs={}:i.refs;Object.defineProperty(refs,key,{enumerable:!0,get:()=>r.value,set:val=>r.value=val})}return r}var pendingSetRefMap=new WeakMap;function setRef(rawRef,oldRawRef,parentSuspense,vnode,isUnmount=!1){if(isArray$2(rawRef)){rawRef.forEach((r,i)=>setRef(r,oldRawRef&&(isArray$2(oldRawRef)?oldRawRef[i]:oldRawRef),parentSuspense,vnode,isUnmount));return}if(isAsyncWrapper(vnode)&&!isUnmount){vnode.shapeFlag&512&&vnode.type.__asyncResolved&&vnode.component.subTree.component&&setRef(rawRef,oldRawRef,parentSuspense,vnode.component.subTree);return}let refValue=vnode.shapeFlag&4?getComponentPublicInstance(vnode.component):vnode.el,value=isUnmount?null:refValue,{i:owner,r:ref$1}=rawRef,oldRef=oldRawRef&&oldRawRef.r,refs=owner.refs===EMPTY_OBJ?owner.refs={}:owner.refs,setupState=owner.setupState,rawSetupState=toRaw(setupState),canSetSetupRef=setupState===EMPTY_OBJ?NO:key=>hasOwn$1(rawSetupState,key),canSetRef=ref2=>!0;if(oldRef!=null&&oldRef!==ref$1){if(invalidatePendingSetRef(oldRawRef),isString$1(oldRef))refs[oldRef]=null,canSetSetupRef(oldRef)&&(setupState[oldRef]=null);else if(isRef(oldRef)){canSetRef(oldRef)&&(oldRef.value=null);let oldRawRefAtom=oldRawRef;oldRawRefAtom.k&&(refs[oldRawRefAtom.k]=null)}}if(isFunction$1(ref$1))callWithErrorHandling(ref$1,owner,12,[value,refs]);else{let _isString=isString$1(ref$1),_isRef=isRef(ref$1);if(_isString||_isRef){let doSet=()=>{if(rawRef.f){let existing=_isString?canSetSetupRef(ref$1)?setupState[ref$1]:refs[ref$1]:canSetRef(ref$1)||!rawRef.k?ref$1.value:refs[rawRef.k];if(isUnmount)isArray$2(existing)&&remove$2(existing,refValue);else if(isArray$2(existing))existing.includes(refValue)||existing.push(refValue);else if(_isString)refs[ref$1]=[refValue],canSetSetupRef(ref$1)&&(setupState[ref$1]=refs[ref$1]);else{let newVal=[refValue];canSetRef(ref$1)&&(ref$1.value=newVal),rawRef.k&&(refs[rawRef.k]=newVal)}}else _isString?(refs[ref$1]=value,canSetSetupRef(ref$1)&&(setupState[ref$1]=value)):_isRef&&(canSetRef(ref$1)&&(ref$1.value=value),rawRef.k&&(refs[rawRef.k]=value))};if(value){let job=()=>{doSet(),pendingSetRefMap.delete(rawRef)};job.id=-1,pendingSetRefMap.set(rawRef,job),queuePostRenderEffect(job,parentSuspense)}else invalidatePendingSetRef(rawRef),doSet()}}}function invalidatePendingSetRef(rawRef){let pendingSetRef=pendingSetRefMap.get(rawRef);pendingSetRef&&(pendingSetRef.flags|=8,pendingSetRefMap.delete(rawRef))}var hasLoggedMismatchError=!1,logMismatchError=()=>{hasLoggedMismatchError||=(console.error(`Hydration completed but contains mismatches.`),!0)},isSVGContainer=container=>container.namespaceURI.includes(`svg`)&&container.tagName!==`foreignObject`,isMathMLContainer=container=>container.namespaceURI.includes(`MathML`),getContainerType=container=>{if(container.nodeType===1){if(isSVGContainer(container))return`svg`;if(isMathMLContainer(container))return`mathml`}},isComment=node=>node.nodeType===8;function createHydrationFunctions(rendererInternals){let{mt:mountComponent,p:patch,o:{patchProp:patchProp$1,createText,nextSibling,parentNode,remove:remove$3,insert,createComment}}=rendererInternals,hydrate$1=(vnode,container)=>{if(!container.hasChildNodes()){patch(null,vnode,container),flushPostFlushCbs(),container._vnode=vnode;return}hydrateNode(container.firstChild,vnode,null,null,null),flushPostFlushCbs(),container._vnode=vnode},hydrateNode=(node,vnode,parentComponent,parentSuspense,slotScopeIds,optimized=!1)=>{optimized||=!!vnode.dynamicChildren;let isFragmentStart=isComment(node)&&node.data===`[`,onMismatch=()=>handleMismatch(node,vnode,parentComponent,parentSuspense,slotScopeIds,isFragmentStart),{type,ref:ref$1,shapeFlag,patchFlag}=vnode,domType=node.nodeType;vnode.el=node,patchFlag===-2&&(optimized=!1,vnode.dynamicChildren=null);let nextNode=null;switch(type){case Text:domType===3?(node.data!==vnode.children&&(logMismatchError(),node.data=vnode.children),nextNode=nextSibling(node)):vnode.children===``?(insert(vnode.el=createText(``),parentNode(node),node),nextNode=node):nextNode=onMismatch();break;case Comment:isTemplateNode$1(node)?(nextNode=nextSibling(node),replaceNode(vnode.el=node.content.firstChild,node,parentComponent)):nextNode=domType!==8||isFragmentStart?onMismatch():nextSibling(node);break;case Static:if(isFragmentStart&&(node=nextSibling(node),domType=node.nodeType),domType===1||domType===3){nextNode=node;let needToAdoptContent=!vnode.children.length;for(let i=0;i{optimized||=!!vnode.dynamicChildren;let{type,props,patchFlag,shapeFlag,dirs,transition}=vnode,forcePatch=type===`input`||type===`option`;if(forcePatch||patchFlag!==-1){dirs&&invokeDirectiveHook(vnode,null,parentComponent,`created`);let needCallTransitionHooks=!1;if(isTemplateNode$1(el)){needCallTransitionHooks=needTransition(null,transition)&&parentComponent&&parentComponent.vnode.props&&parentComponent.vnode.props.appear;let content=el.content.firstChild;if(needCallTransitionHooks){let cls=content.getAttribute(`class`);cls&&(content.$cls=cls),transition.beforeEnter(content)}replaceNode(content,el,parentComponent),vnode.el=el=content}if(shapeFlag&16&&!(props&&(props.innerHTML||props.textContent))){let next=hydrateChildren(el.firstChild,vnode,el,parentComponent,parentSuspense,slotScopeIds,optimized);for(;next;){isMismatchAllowed(el,1)||logMismatchError();let cur=next;next=next.nextSibling,remove$3(cur)}}else if(shapeFlag&8){let clientText=vnode.children;clientText[0]===`
`&&(el.tagName===`PRE`||el.tagName===`TEXTAREA`)&&(clientText=clientText.slice(1)),el.textContent!==clientText&&(isMismatchAllowed(el,0)||logMismatchError(),el.textContent=vnode.children)}if(props){if(forcePatch||!optimized||patchFlag&48){let isCustomElement=el.tagName.includes(`-`);for(let key in props)(forcePatch&&(key.endsWith(`value`)||key===`indeterminate`)||isOn(key)&&!isReservedProp(key)||key[0]===`.`||isCustomElement)&&patchProp$1(el,key,null,props[key],void 0,parentComponent)}else if(props.onClick)patchProp$1(el,`onClick`,null,props.onClick,void 0,parentComponent);else if(patchFlag&4&&isReactive(props.style))for(let key in props.style)props.style[key]}let vnodeHooks;(vnodeHooks=props&&props.onVnodeBeforeMount)&&invokeVNodeHook(vnodeHooks,parentComponent,vnode),dirs&&invokeDirectiveHook(vnode,null,parentComponent,`beforeMount`),((vnodeHooks=props&&props.onVnodeMounted)||dirs||needCallTransitionHooks)&&queueEffectWithSuspense(()=>{vnodeHooks&&invokeVNodeHook(vnodeHooks,parentComponent,vnode),needCallTransitionHooks&&transition.enter(el),dirs&&invokeDirectiveHook(vnode,null,parentComponent,`mounted`)},parentSuspense)}return el.nextSibling},hydrateChildren=(node,parentVNode,container,parentComponent,parentSuspense,slotScopeIds,optimized)=>{optimized||=!!parentVNode.dynamicChildren;let children=parentVNode.children,l=children.length;for(let i=0;i{let{slotScopeIds:fragmentSlotScopeIds}=vnode;fragmentSlotScopeIds&&(slotScopeIds=slotScopeIds?slotScopeIds.concat(fragmentSlotScopeIds):fragmentSlotScopeIds);let container=parentNode(node),next=hydrateChildren(nextSibling(node),vnode,container,parentComponent,parentSuspense,slotScopeIds,optimized);return next&&isComment(next)&&next.data===`]`?nextSibling(vnode.anchor=next):(logMismatchError(),insert(vnode.anchor=createComment(`]`),container,next),next)},handleMismatch=(node,vnode,parentComponent,parentSuspense,slotScopeIds,isFragment)=>{if(isMismatchAllowed(node.parentElement,1)||logMismatchError(),vnode.el=null,isFragment){let end=locateClosingAnchor(node);for(;;){let next2=nextSibling(node);if(next2&&next2!==end)remove$3(next2);else break}}let next=nextSibling(node),container=parentNode(node);return remove$3(node),patch(null,vnode,container,next,parentComponent,parentSuspense,getContainerType(container),slotScopeIds),parentComponent&&(parentComponent.vnode.el=vnode.el,updateHOCHostEl(parentComponent,vnode.el)),next},locateClosingAnchor=(node,open$1=`[`,close=`]`)=>{let match=0;for(;node;)if(node=nextSibling(node),node&&isComment(node)&&(node.data===open$1&&match++,node.data===close)){if(match===0)return nextSibling(node);match--}return node},replaceNode=(newNode,oldNode,parentComponent)=>{let parentNode2=oldNode.parentNode;parentNode2&&parentNode2.replaceChild(newNode,oldNode);let parent=parentComponent;for(;parent;)parent.vnode.el===oldNode&&(parent.vnode.el=parent.subTree.el=newNode),parent=parent.parent},isTemplateNode$1=node=>node.nodeType===1&&node.tagName===`TEMPLATE`;return[hydrate$1,hydrateNode]}var allowMismatchAttr=`data-allow-mismatch`,MismatchTypeString={0:`text`,1:`children`,2:`class`,3:`style`,4:`attribute`};function isMismatchAllowed(el,allowedType){if(allowedType===0||allowedType===1)for(;el&&!el.hasAttribute(allowMismatchAttr);)el=el.parentElement;let allowedAttr=el&&el.getAttribute(allowMismatchAttr);if(allowedAttr==null)return!1;if(allowedAttr===``)return!0;{let list=allowedAttr.split(`,`);return allowedType===0&&list.includes(`children`)?!0:list.includes(MismatchTypeString[allowedType])}}var requestIdleCallback=getGlobalThis$1().requestIdleCallback||(cb=>setTimeout(cb,1)),cancelIdleCallback=getGlobalThis$1().cancelIdleCallback||(id=>clearTimeout(id)),hydrateOnIdle=(timeout=1e4)=>hydrate$1=>{let id=requestIdleCallback(hydrate$1,{timeout});return()=>cancelIdleCallback(id)};function elementIsVisibleInViewport(el){let{top,left,bottom,right}=el.getBoundingClientRect(),{innerHeight,innerWidth}=window;return(top>0&&top0&&bottom0&&left0&&right(hydrate$1,forEach)=>{let ob=new IntersectionObserver(entries=>{for(let e of entries)if(e.isIntersecting){ob.disconnect(),hydrate$1();break}},opts);return forEach(el=>{if(el instanceof Element){if(elementIsVisibleInViewport(el))return hydrate$1(),ob.disconnect(),!1;ob.observe(el)}}),()=>ob.disconnect()},hydrateOnMediaQuery=query=>hydrate$1=>{if(query){let mql=matchMedia(query);if(mql.matches)hydrate$1();else return mql.addEventListener(`change`,hydrate$1,{once:!0}),()=>mql.removeEventListener(`change`,hydrate$1)}},hydrateOnInteraction=(interactions=[])=>(hydrate$1,forEach)=>{isString$1(interactions)&&(interactions=[interactions]);let hasHydrated=!1,doHydrate=e=>{hasHydrated||(hasHydrated=!0,teardown(),hydrate$1(),e.target.dispatchEvent(new e.constructor(e.type,e)))},teardown=()=>{forEach(el=>{for(let i of interactions)el.removeEventListener(i,doHydrate)})};return forEach(el=>{for(let i of interactions)el.addEventListener(i,doHydrate,{once:!0})}),teardown};function forEachElement(node,cb){if(isComment(node)&&node.data===`[`){let depth=1,next=node.nextSibling;for(;next;){if(next.nodeType===1){if(cb(next)===!1)break}else if(isComment(next))if(next.data===`]`){if(--depth===0)break}else next.data===`[`&&depth++;next=next.nextSibling}}else cb(node)}var isAsyncWrapper=i=>!!i.type.__asyncLoader;function defineAsyncComponent(source){isFunction$1(source)&&(source={loader:source});let{loader,loadingComponent,errorComponent,delay=200,hydrate:hydrateStrategy,timeout,suspensible=!0,onError:userOnError}=source,pendingRequest=null,resolvedComp,retries=0,retry=()=>(retries++,pendingRequest=null,load()),load=()=>{let thisRequest;return pendingRequest||(thisRequest=pendingRequest=loader().catch(err=>{if(err=err instanceof Error?err:Error(String(err)),userOnError)return new Promise((resolve$1,reject)=>{userOnError(err,()=>resolve$1(retry()),()=>reject(err),retries+1)});throw err}).then(comp=>thisRequest!==pendingRequest&&pendingRequest?pendingRequest:(comp&&(comp.__esModule||comp[Symbol.toStringTag]===`Module`)&&(comp=comp.default),resolvedComp=comp,comp)))};return defineComponent({name:`AsyncComponentWrapper`,__asyncLoader:load,__asyncHydrate(el,instance$1,hydrate$1){let patched=!1;(instance$1.bu||=[]).push(()=>patched=!0);let performHydrate=()=>{patched||hydrate$1()},doHydrate=hydrateStrategy?()=>{let teardown=hydrateStrategy(performHydrate,cb=>forEachElement(el,cb));teardown&&(instance$1.bum||=[]).push(teardown)}:performHydrate;resolvedComp?doHydrate():load().then(()=>!instance$1.isUnmounted&&doHydrate())},get __asyncResolved(){return resolvedComp},setup(){let instance$1=currentInstance;if(markAsyncBoundary(instance$1),resolvedComp)return()=>createInnerComp(resolvedComp,instance$1);let onError=err=>{pendingRequest=null,handleError(err,instance$1,13,!errorComponent)};if(suspensible&&instance$1.suspense||isInSSRComponentSetup)return load().then(comp=>()=>createInnerComp(comp,instance$1)).catch(err=>(onError(err),()=>errorComponent?createVNode(errorComponent,{error:err}):null));let loaded=ref(!1),error=ref(),delayed=ref(!!delay);return delay&&setTimeout(()=>{delayed.value=!1},delay),timeout!=null&&setTimeout(()=>{if(!loaded.value&&!error.value){let err=Error(`Async component timed out after ${timeout}ms.`);onError(err),error.value=err}},timeout),load().then(()=>{loaded.value=!0,instance$1.parent&&isKeepAlive(instance$1.parent.vnode)&&instance$1.parent.update()}).catch(err=>{onError(err),error.value=err}),()=>{if(loaded.value&&resolvedComp)return createInnerComp(resolvedComp,instance$1);if(error.value&&errorComponent)return createVNode(errorComponent,{error:error.value});if(loadingComponent&&!delayed.value)return createVNode(loadingComponent)}}})}function createInnerComp(comp,parent){let{ref:ref2,props,children,ce}=parent.vnode,vnode=createVNode(comp,props,children);return vnode.ref=ref2,vnode.ce=ce,delete parent.vnode.ce,vnode}var isKeepAlive=vnode=>vnode.type.__isKeepAlive,KeepAlive={name:`KeepAlive`,__isKeepAlive:!0,props:{include:[String,RegExp,Array],exclude:[String,RegExp,Array],max:[String,Number]},setup(props,{slots}){let instance$1=getCurrentInstance(),sharedContext$1=instance$1.ctx;if(!sharedContext$1.renderer)return()=>{let children=slots.default&&slots.default();return children&&children.length===1?children[0]:children};let cache$1=new Map,keys=new Set,current=null,parentSuspense=instance$1.suspense,{renderer:{p:patch,m:move,um:_unmount,o:{createElement}}}=sharedContext$1,storageContainer=createElement(`div`);sharedContext$1.activate=(vnode,container,anchor,namespace,optimized)=>{let instance2=vnode.component;move(vnode,container,anchor,0,parentSuspense),patch(instance2.vnode,vnode,container,anchor,instance2,parentSuspense,namespace,vnode.slotScopeIds,optimized),queuePostRenderEffect(()=>{instance2.isDeactivated=!1,instance2.a&&invokeArrayFns(instance2.a);let vnodeHook=vnode.props&&vnode.props.onVnodeMounted;vnodeHook&&invokeVNodeHook(vnodeHook,instance2.parent,vnode)},parentSuspense)},sharedContext$1.deactivate=vnode=>{let instance2=vnode.component;invalidateMount(instance2.m),invalidateMount(instance2.a),move(vnode,storageContainer,null,1,parentSuspense),queuePostRenderEffect(()=>{instance2.da&&invokeArrayFns(instance2.da);let vnodeHook=vnode.props&&vnode.props.onVnodeUnmounted;vnodeHook&&invokeVNodeHook(vnodeHook,instance2.parent,vnode),instance2.isDeactivated=!0},parentSuspense)};function unmount(vnode){resetShapeFlag(vnode),_unmount(vnode,instance$1,parentSuspense,!0)}function pruneCache(filter){cache$1.forEach((vnode,key)=>{let name=getComponentName(vnode.type);name&&!filter(name)&&pruneCacheEntry(key)})}function pruneCacheEntry(key){let cached=cache$1.get(key);cached&&(!current||!isSameVNodeType(cached,current))?unmount(cached):current&&resetShapeFlag(current),cache$1.delete(key),keys.delete(key)}watch(()=>[props.include,props.exclude],([include,exclude])=>{include&&pruneCache(name=>matches(include,name)),exclude&&pruneCache(name=>!matches(exclude,name))},{flush:`post`,deep:!0});let pendingCacheKey=null,cacheSubtree=()=>{pendingCacheKey!=null&&(isSuspense(instance$1.subTree.type)?queuePostRenderEffect(()=>{cache$1.set(pendingCacheKey,getInnerChild(instance$1.subTree))},instance$1.subTree.suspense):cache$1.set(pendingCacheKey,getInnerChild(instance$1.subTree)))};return onMounted(cacheSubtree),onUpdated(cacheSubtree),onBeforeUnmount(()=>{cache$1.forEach(cached=>{let{subTree,suspense}=instance$1,vnode=getInnerChild(subTree);if(cached.type===vnode.type&&cached.key===vnode.key){resetShapeFlag(vnode);let da=vnode.component.da;da&&queuePostRenderEffect(da,suspense);return}unmount(cached)})}),()=>{if(pendingCacheKey=null,!slots.default)return current=null;let children=slots.default(),rawVNode=children[0];if(children.length>1)return current=null,children;if(!isVNode(rawVNode)||!(rawVNode.shapeFlag&4)&&!(rawVNode.shapeFlag&128))return current=null,rawVNode;let vnode=getInnerChild(rawVNode);if(vnode.type===Comment)return current=null,vnode;let comp=vnode.type,name=getComponentName(isAsyncWrapper(vnode)?vnode.type.__asyncResolved||{}:comp),{include,exclude,max:max$1}=props;if(include&&(!name||!matches(include,name))||exclude&&name&&matches(exclude,name))return vnode.shapeFlag&=-257,current=vnode,rawVNode;let key=vnode.key==null?comp:vnode.key,cachedVNode=cache$1.get(key);return vnode.el&&(vnode=cloneVNode(vnode),rawVNode.shapeFlag&128&&(rawVNode.ssContent=vnode)),pendingCacheKey=key,cachedVNode?(vnode.el=cachedVNode.el,vnode.component=cachedVNode.component,vnode.transition&&setTransitionHooks(vnode,vnode.transition),vnode.shapeFlag|=512,keys.delete(key),keys.add(key)):(keys.add(key),max$1&&keys.size>parseInt(max$1,10)&&pruneCacheEntry(keys.values().next().value)),vnode.shapeFlag|=256,current=vnode,isSuspense(rawVNode.type)?rawVNode:vnode}}};function matches(pattern,name){return isArray$2(pattern)?pattern.some(p$1=>matches(p$1,name)):isString$1(pattern)?pattern.split(`,`).includes(name):isRegExp$1(pattern)?(pattern.lastIndex=0,pattern.test(name)):!1}function onActivated(hook,target){registerKeepAliveHook(hook,`a`,target)}function onDeactivated(hook,target){registerKeepAliveHook(hook,`da`,target)}function registerKeepAliveHook(hook,type,target=currentInstance){let wrappedHook=hook.__wdc||=()=>{let current=target;for(;current;){if(current.isDeactivated)return;current=current.parent}return hook()};if(injectHook(type,wrappedHook,target),target){let current=target.parent;for(;current&¤t.parent;)isKeepAlive(current.parent.vnode)&&injectToKeepAliveRoot(wrappedHook,type,target,current),current=current.parent}}function injectToKeepAliveRoot(hook,type,target,keepAliveRoot){let injected=injectHook(type,hook,keepAliveRoot,!0);onUnmounted(()=>{remove$2(keepAliveRoot[type],injected)},target)}function resetShapeFlag(vnode){vnode.shapeFlag&=-257,vnode.shapeFlag&=-513}function getInnerChild(vnode){return vnode.shapeFlag&128?vnode.ssContent:vnode}function injectHook(type,hook,target=currentInstance,prepend=!1){if(target){let hooks=target[type]||(target[type]=[]),wrappedHook=hook.__weh||=(...args)=>{pauseTracking();let reset$1=setCurrentInstance(target),res=callWithAsyncErrorHandling(hook,target,type,args);return reset$1(),resetTracking(),res};return prepend?hooks.unshift(wrappedHook):hooks.push(wrappedHook),wrappedHook}}var createHook=lifecycle=>(hook,target=currentInstance)=>{(!isInSSRComponentSetup||lifecycle===`sp`)&&injectHook(lifecycle,(...args)=>hook(...args),target)},onBeforeMount=createHook(`bm`),onMounted=createHook(`m`),onBeforeUpdate=createHook(`bu`),onUpdated=createHook(`u`),onBeforeUnmount=createHook(`bum`),onUnmounted=createHook(`um`),onServerPrefetch=createHook(`sp`),onRenderTriggered=createHook(`rtg`),onRenderTracked=createHook(`rtc`);function onErrorCaptured(hook,target=currentInstance){injectHook(`ec`,hook,target)}var COMPONENTS=`components`,DIRECTIVES=`directives`;function resolveComponent(name,maybeSelfReference){return resolveAsset(COMPONENTS,name,!0,maybeSelfReference)||name}var NULL_DYNAMIC_COMPONENT=Symbol.for(`v-ndc`);function resolveDynamicComponent(component){return isString$1(component)?resolveAsset(COMPONENTS,component,!1)||component:component||NULL_DYNAMIC_COMPONENT}function resolveDirective(name){return resolveAsset(DIRECTIVES,name)}function resolveAsset(type,name,warnMissing=!0,maybeSelfReference=!1){let instance$1=currentRenderingInstance||currentInstance;if(instance$1){let Component=instance$1.type;if(type===COMPONENTS){let selfName=getComponentName(Component,!1);if(selfName&&(selfName===name||selfName===camelize(name)||selfName===capitalize$1(camelize(name))))return Component}let res=resolve(instance$1[type]||Component[type],name)||resolve(instance$1.appContext[type],name);return!res&&maybeSelfReference?Component:res}}function resolve(registry$1,name){return registry$1&&(registry$1[name]||registry$1[camelize(name)]||registry$1[capitalize$1(camelize(name))])}function renderList(source,renderItem,cache$1,index){let ret,cached=cache$1&&cache$1[index],sourceIsArray=isArray$2(source);if(sourceIsArray||isString$1(source)){let sourceIsReactiveArray=sourceIsArray&&isReactive(source),needsWrap=!1,isReadonlySource=!1;sourceIsReactiveArray&&(needsWrap=!isShallow(source),isReadonlySource=isReadonly(source),source=shallowReadArray(source)),ret=Array(source.length);for(let i=0,l=source.length;irenderItem(item,i,void 0,cached&&cached[i]));else{let keys=Object.keys(source);ret=Array(keys.length);for(let i=0,l=keys.length;i{let res=slot.fn(...args);return res&&(res.key=slot.key),res}:slot.fn)}return slots}function renderSlot(slots,name,props={},fallback,noSlotted){if(currentRenderingInstance.ce||currentRenderingInstance.parent&&isAsyncWrapper(currentRenderingInstance.parent)&¤tRenderingInstance.parent.ce){let hasProps=Object.keys(props).length>0;return name!==`default`&&(props.name=name),openBlock(),createBlock(Fragment,null,[createVNode(`slot`,props,fallback&&fallback())],hasProps?-2:64)}let slot=slots[name];slot&&slot._c&&(slot._d=!1),openBlock();let validSlotContent=slot&&ensureValidVNode(slot(props)),slotKey=props.key||validSlotContent&&validSlotContent.key,rendered=createBlock(Fragment,{key:(slotKey&&!isSymbol(slotKey)?slotKey:`_${name}`)+(!validSlotContent&&fallback?`_fb`:``)},validSlotContent||(fallback?fallback():[]),validSlotContent&&slots._===1?64:-2);return!noSlotted&&rendered.scopeId&&(rendered.slotScopeIds=[rendered.scopeId+`-s`]),slot&&slot._c&&(slot._d=!0),rendered}function ensureValidVNode(vnodes){return vnodes.some(child=>isVNode(child)?!(child.type===Comment||child.type===Fragment&&!ensureValidVNode(child.children)):!0)?vnodes:null}function toHandlers(obj,preserveCaseIfNecessary){let ret={};for(let key in obj)ret[preserveCaseIfNecessary&&/[A-Z]/.test(key)?`on:${key}`:toHandlerKey(key)]=obj[key];return ret}var getPublicInstance=i=>i?isStatefulComponent(i)?getComponentPublicInstance(i):getPublicInstance(i.parent):null,publicPropertiesMap=extend(Object.create(null),{$:i=>i,$el:i=>i.vnode.el,$data:i=>i.data,$props:i=>i.props,$attrs:i=>i.attrs,$slots:i=>i.slots,$refs:i=>i.refs,$parent:i=>getPublicInstance(i.parent),$root:i=>getPublicInstance(i.root),$host:i=>i.ce,$emit:i=>i.emit,$options:i=>resolveMergedOptions(i),$forceUpdate:i=>i.f||=()=>{queueJob(i.update)},$nextTick:i=>i.n||=nextTick.bind(i.proxy),$watch:i=>instanceWatch.bind(i)}),hasSetupBinding=(state,key)=>state!==EMPTY_OBJ&&!state.__isScriptSetup&&hasOwn$1(state,key),PublicInstanceProxyHandlers={get({_:instance$1},key){if(key===`__v_skip`)return!0;let{ctx,setupState,data,props,accessCache,type,appContext}=instance$1,normalizedProps;if(key[0]!==`$`){let n=accessCache[key];if(n!==void 0)switch(n){case 1:return setupState[key];case 2:return data[key];case 4:return ctx[key];case 3:return props[key]}else if(hasSetupBinding(setupState,key))return accessCache[key]=1,setupState[key];else if(data!==EMPTY_OBJ&&hasOwn$1(data,key))return accessCache[key]=2,data[key];else if((normalizedProps=instance$1.propsOptions[0])&&hasOwn$1(normalizedProps,key))return accessCache[key]=3,props[key];else if(ctx!==EMPTY_OBJ&&hasOwn$1(ctx,key))return accessCache[key]=4,ctx[key];else shouldCacheAccess&&(accessCache[key]=0)}let publicGetter=publicPropertiesMap[key],cssModule,globalProperties;if(publicGetter)return key===`$attrs`&&track(instance$1.attrs,`get`,``),publicGetter(instance$1);if((cssModule=type.__cssModules)&&(cssModule=cssModule[key]))return cssModule;if(ctx!==EMPTY_OBJ&&hasOwn$1(ctx,key))return accessCache[key]=4,ctx[key];if(globalProperties=appContext.config.globalProperties,hasOwn$1(globalProperties,key))return globalProperties[key]},set({_:instance$1},key,value){let{data,setupState,ctx}=instance$1;return hasSetupBinding(setupState,key)?(setupState[key]=value,!0):data!==EMPTY_OBJ&&hasOwn$1(data,key)?(data[key]=value,!0):hasOwn$1(instance$1.props,key)||key[0]===`$`&&key.slice(1)in instance$1?!1:(ctx[key]=value,!0)},has({_:{data,setupState,accessCache,ctx,appContext,propsOptions,type}},key){let normalizedProps,cssModules;return!!(accessCache[key]||data!==EMPTY_OBJ&&key[0]!==`$`&&hasOwn$1(data,key)||hasSetupBinding(setupState,key)||(normalizedProps=propsOptions[0])&&hasOwn$1(normalizedProps,key)||hasOwn$1(ctx,key)||hasOwn$1(publicPropertiesMap,key)||hasOwn$1(appContext.config.globalProperties,key)||(cssModules=type.__cssModules)&&cssModules[key])},defineProperty(target,key,descriptor){return descriptor.get==null?hasOwn$1(descriptor,`value`)&&this.set(target,key,descriptor.value,null):target._.accessCache[key]=0,Reflect.defineProperty(target,key,descriptor)}},RuntimeCompiledPublicInstanceProxyHandlers=extend({},PublicInstanceProxyHandlers,{get(target,key){if(key!==Symbol.unscopables)return PublicInstanceProxyHandlers.get(target,key,target)},has(_,key){return key[0]!==`_`&&!isGloballyAllowed(key)}});function defineProps(){return null}function defineEmits(){return null}function defineExpose(exposed){}function defineOptions(options){}function defineSlots(){return null}function defineModel(){}function withDefaults(props,defaults){return null}function useSlots(){return getContext(`useSlots`).slots}function useAttrs(){return getContext(`useAttrs`).attrs}function getContext(calledFunctionName){let i=getCurrentInstance();return i.setupContext||=createSetupContext(i)}function normalizePropsOrEmits(props){return isArray$2(props)?props.reduce((normalized,p$1)=>(normalized[p$1]=null,normalized),{}):props}function mergeDefaults(raw,defaults){let props=normalizePropsOrEmits(raw);for(let key in defaults){if(key.startsWith(`__skip`))continue;let opt=props[key];opt?isArray$2(opt)||isFunction$1(opt)?opt=props[key]={type:opt,default:defaults[key]}:opt.default=defaults[key]:opt===null&&(opt=props[key]={default:defaults[key]}),opt&&defaults[`__skip_${key}`]&&(opt.skipFactory=!0)}return props}function mergeModels(a$1,b){return!a$1||!b?a$1||b:isArray$2(a$1)&&isArray$2(b)?a$1.concat(b):extend({},normalizePropsOrEmits(a$1),normalizePropsOrEmits(b))}function createPropsRestProxy(props,excludedKeys){let ret={};for(let key in props)excludedKeys.includes(key)||Object.defineProperty(ret,key,{enumerable:!0,get:()=>props[key]});return ret}function withAsyncContext(getAwaitable){let ctx=getCurrentInstance(),awaitable=getAwaitable();return unsetCurrentInstance(),isPromise$1(awaitable)&&(awaitable=awaitable.catch(e=>{throw setCurrentInstance(ctx),e})),[awaitable,()=>setCurrentInstance(ctx)]}var shouldCacheAccess=!0;function applyOptions$1(instance$1){let options=resolveMergedOptions(instance$1),publicThis=instance$1.proxy,ctx=instance$1.ctx;shouldCacheAccess=!1,options.beforeCreate&&callHook$1(options.beforeCreate,instance$1,`bc`);let{data:dataOptions,computed:computedOptions,methods,watch:watchOptions,provide:provideOptions,inject:injectOptions,created,beforeMount:beforeMount$1,mounted:mounted$2,beforeUpdate,updated:updated$2,activated,deactivated,beforeDestroy,beforeUnmount:beforeUnmount$1,destroyed,unmounted:unmounted$1,render:render$1,renderTracked,renderTriggered,errorCaptured,serverPrefetch,expose,inheritAttrs,components,directives,filters}=options,checkDuplicateProperties=null;if(injectOptions&&resolveInjections(injectOptions,ctx,null),methods)for(let key in methods){let methodHandler=methods[key];isFunction$1(methodHandler)&&(ctx[key]=methodHandler.bind(publicThis))}if(dataOptions){let data=dataOptions.call(publicThis,publicThis);isObject$1(data)&&(instance$1.data=reactive(data))}if(shouldCacheAccess=!0,computedOptions)for(let key in computedOptions){let opt=computedOptions[key],c=computed({get:isFunction$1(opt)?opt.bind(publicThis,publicThis):isFunction$1(opt.get)?opt.get.bind(publicThis,publicThis):NOOP,set:!isFunction$1(opt)&&isFunction$1(opt.set)?opt.set.bind(publicThis):NOOP});Object.defineProperty(ctx,key,{enumerable:!0,configurable:!0,get:()=>c.value,set:v=>c.value=v})}if(watchOptions)for(let key in watchOptions)createWatcher(watchOptions[key],ctx,publicThis,key);if(provideOptions){let provides=isFunction$1(provideOptions)?provideOptions.call(publicThis):provideOptions;Reflect.ownKeys(provides).forEach(key=>{provide(key,provides[key])})}created&&callHook$1(created,instance$1,`c`);function registerLifecycleHook(register,hook){isArray$2(hook)?hook.forEach(_hook=>register(_hook.bind(publicThis))):hook&®ister(hook.bind(publicThis))}if(registerLifecycleHook(onBeforeMount,beforeMount$1),registerLifecycleHook(onMounted,mounted$2),registerLifecycleHook(onBeforeUpdate,beforeUpdate),registerLifecycleHook(onUpdated,updated$2),registerLifecycleHook(onActivated,activated),registerLifecycleHook(onDeactivated,deactivated),registerLifecycleHook(onErrorCaptured,errorCaptured),registerLifecycleHook(onRenderTracked,renderTracked),registerLifecycleHook(onRenderTriggered,renderTriggered),registerLifecycleHook(onBeforeUnmount,beforeUnmount$1),registerLifecycleHook(onUnmounted,unmounted$1),registerLifecycleHook(onServerPrefetch,serverPrefetch),isArray$2(expose))if(expose.length){let exposed=instance$1.exposed||={};expose.forEach(key=>{Object.defineProperty(exposed,key,{get:()=>publicThis[key],set:val=>publicThis[key]=val,enumerable:!0})})}else instance$1.exposed||={};render$1&&instance$1.render===NOOP&&(instance$1.render=render$1),inheritAttrs!=null&&(instance$1.inheritAttrs=inheritAttrs),components&&(instance$1.components=components),directives&&(instance$1.directives=directives),serverPrefetch&&markAsyncBoundary(instance$1)}function resolveInjections(injectOptions,ctx,checkDuplicateProperties=NOOP){for(let key in isArray$2(injectOptions)&&(injectOptions=normalizeInject(injectOptions)),injectOptions){let opt=injectOptions[key],injected;injected=isObject$1(opt)?`default`in opt?inject(opt.from||key,opt.default,!0):inject(opt.from||key):inject(opt),isRef(injected)?Object.defineProperty(ctx,key,{enumerable:!0,configurable:!0,get:()=>injected.value,set:v=>injected.value=v}):ctx[key]=injected}}function callHook$1(hook,instance$1,type){callWithAsyncErrorHandling(isArray$2(hook)?hook.map(h$1=>h$1.bind(instance$1.proxy)):hook.bind(instance$1.proxy),instance$1,type)}function createWatcher(raw,ctx,publicThis,key){let getter=key.includes(`.`)?createPathGetter(publicThis,key):()=>publicThis[key];if(isString$1(raw)){let handler$1=ctx[raw];isFunction$1(handler$1)&&watch(getter,handler$1)}else if(isFunction$1(raw))watch(getter,raw.bind(publicThis));else if(isObject$1(raw))if(isArray$2(raw))raw.forEach(r=>createWatcher(r,ctx,publicThis,key));else{let handler$1=isFunction$1(raw.handler)?raw.handler.bind(publicThis):ctx[raw.handler];isFunction$1(handler$1)&&watch(getter,handler$1,raw)}}function resolveMergedOptions(instance$1){let base=instance$1.type,{mixins,extends:extendsOptions}=base,{mixins:globalMixins,optionsCache:cache$1,config:{optionMergeStrategies}}=instance$1.appContext,cached=cache$1.get(base),resolved;return cached?resolved=cached:!globalMixins.length&&!mixins&&!extendsOptions?resolved=base:(resolved={},globalMixins.length&&globalMixins.forEach(m=>mergeOptions$1(resolved,m,optionMergeStrategies,!0)),mergeOptions$1(resolved,base,optionMergeStrategies)),isObject$1(base)&&cache$1.set(base,resolved),resolved}function mergeOptions$1(to,from,strats,asMixin=!1){let{mixins,extends:extendsOptions}=from;for(let key in extendsOptions&&mergeOptions$1(to,extendsOptions,strats,!0),mixins&&mixins.forEach(m=>mergeOptions$1(to,m,strats,!0)),from)if(!(asMixin&&key===`expose`)){let strat=internalOptionMergeStrats[key]||strats&&strats[key];to[key]=strat?strat(to[key],from[key]):from[key]}return to}var internalOptionMergeStrats={data:mergeDataFn,props:mergeEmitsOrPropsOptions,emits:mergeEmitsOrPropsOptions,methods:mergeObjectOptions,computed:mergeObjectOptions,beforeCreate:mergeAsArray$1,created:mergeAsArray$1,beforeMount:mergeAsArray$1,mounted:mergeAsArray$1,beforeUpdate:mergeAsArray$1,updated:mergeAsArray$1,beforeDestroy:mergeAsArray$1,beforeUnmount:mergeAsArray$1,destroyed:mergeAsArray$1,unmounted:mergeAsArray$1,activated:mergeAsArray$1,deactivated:mergeAsArray$1,errorCaptured:mergeAsArray$1,serverPrefetch:mergeAsArray$1,components:mergeObjectOptions,directives:mergeObjectOptions,watch:mergeWatchOptions,provide:mergeDataFn,inject:mergeInject};function mergeDataFn(to,from){return from?to?function(){return extend(isFunction$1(to)?to.call(this,this):to,isFunction$1(from)?from.call(this,this):from)}:from:to}function mergeInject(to,from){return mergeObjectOptions(normalizeInject(to),normalizeInject(from))}function normalizeInject(raw){if(isArray$2(raw)){let res={};for(let i=0;i1)return treatDefaultAsFactory&&isFunction$1(defaultValue)?defaultValue.call(instance$1&&instance$1.proxy):defaultValue}}function hasInjectionContext(){return!!(getCurrentInstance()||currentApp)}var internalObjectProto={},createInternalObject=()=>Object.create(internalObjectProto),isInternalObject=obj=>Object.getPrototypeOf(obj)===internalObjectProto;function initProps(instance$1,rawProps,isStateful,isSSR=!1){let props={},attrs=createInternalObject();for(let key in instance$1.propsDefaults=Object.create(null),setFullProps(instance$1,rawProps,props,attrs),instance$1.propsOptions[0])key in props||(props[key]=void 0);isStateful?instance$1.props=isSSR?props:shallowReactive(props):instance$1.type.props?instance$1.props=props:instance$1.props=attrs,instance$1.attrs=attrs}function updateProps(instance$1,rawProps,rawPrevProps,optimized){let{props,attrs,vnode:{patchFlag}}=instance$1,rawCurrentProps=toRaw(props),[options]=instance$1.propsOptions,hasAttrsChanged=!1;if((optimized||patchFlag>0)&&!(patchFlag&16)){if(patchFlag&8){let propsToUpdate=instance$1.vnode.dynamicProps;for(let i=0;i{hasExtends=!0;let[props,keys]=normalizePropsOptions(raw2,appContext,!0);extend(normalized,props),keys&&needCastKeys.push(...keys)};!asMixin&&appContext.mixins.length&&appContext.mixins.forEach(extendProps),comp.extends&&extendProps(comp.extends),comp.mixins&&comp.mixins.forEach(extendProps)}if(!raw&&!hasExtends)return isObject$1(comp)&&cache$1.set(comp,EMPTY_ARR),EMPTY_ARR;if(isArray$2(raw))for(let i=0;ikey===`_`||key===`_ctx`||key===`$stable`,normalizeSlotValue=value=>isArray$2(value)?value.map(normalizeVNode):[normalizeVNode(value)],normalizeSlot$1=(key,rawSlot,ctx)=>{if(rawSlot._n)return rawSlot;let normalized=withCtx((...args)=>normalizeSlotValue(rawSlot(...args)),ctx);return normalized._c=!1,normalized},normalizeObjectSlots=(rawSlots,slots,instance$1)=>{let ctx=rawSlots._ctx;for(let key in rawSlots){if(isInternalKey(key))continue;let value=rawSlots[key];if(isFunction$1(value))slots[key]=normalizeSlot$1(key,value,ctx);else if(value!=null){let normalized=normalizeSlotValue(value);slots[key]=()=>normalized}}},normalizeVNodeSlots=(instance$1,children)=>{let normalized=normalizeSlotValue(children);instance$1.slots.default=()=>normalized},assignSlots=(slots,children,optimized)=>{for(let key in children)(optimized||!isInternalKey(key))&&(slots[key]=children[key])},initSlots=(instance$1,children,optimized)=>{let slots=instance$1.slots=createInternalObject();if(instance$1.vnode.shapeFlag&32){let type=children._;type?(assignSlots(slots,children,optimized),optimized&&def(slots,`_`,type,!0)):normalizeObjectSlots(children,slots)}else children&&normalizeVNodeSlots(instance$1,children)},updateSlots=(instance$1,children,optimized)=>{let{vnode,slots}=instance$1,needDeletionCheck=!0,deletionComparisonTarget=EMPTY_OBJ;if(vnode.shapeFlag&32){let type=children._;type?optimized&&type===1?needDeletionCheck=!1:assignSlots(slots,children,optimized):(needDeletionCheck=!children.$stable,normalizeObjectSlots(children,slots)),deletionComparisonTarget=children}else children&&(normalizeVNodeSlots(instance$1,children),deletionComparisonTarget={default:1});if(needDeletionCheck)for(let key in slots)!isInternalKey(key)&&deletionComparisonTarget[key]==null&&delete slots[key]};function initFeatureFlags$2(){}var queuePostRenderEffect=queueEffectWithSuspense;function createRenderer(options){return baseCreateRenderer(options)}function createHydrationRenderer(options){return baseCreateRenderer(options,createHydrationFunctions)}function baseCreateRenderer(options,createHydrationFns){let target=getGlobalThis$1();target.__VUE__=!0;let{insert:hostInsert,remove:hostRemove,patchProp:hostPatchProp,createElement:hostCreateElement,createText:hostCreateText,createComment:hostCreateComment,setText:hostSetText,setElementText:hostSetElementText,parentNode:hostParentNode,nextSibling:hostNextSibling,setScopeId:hostSetScopeId=NOOP,insertStaticContent:hostInsertStaticContent}=options,patch=(n1,n2,container,anchor=null,parentComponent=null,parentSuspense=null,namespace=void 0,slotScopeIds=null,optimized=!!n2.dynamicChildren)=>{if(n1===n2)return;n1&&!isSameVNodeType(n1,n2)&&(anchor=getNextHostNode(n1),unmount(n1,parentComponent,parentSuspense,!0),n1=null),n2.patchFlag===-2&&(optimized=!1,n2.dynamicChildren=null);let{type,ref:ref$1,shapeFlag}=n2;switch(type){case Text:processText(n1,n2,container,anchor);break;case Comment:processCommentNode(n1,n2,container,anchor);break;case Static:n1??mountStaticNode(n2,container,anchor,namespace);break;case Fragment:processFragment(n1,n2,container,anchor,parentComponent,parentSuspense,namespace,slotScopeIds,optimized);break;default:shapeFlag&1?processElement(n1,n2,container,anchor,parentComponent,parentSuspense,namespace,slotScopeIds,optimized):shapeFlag&6?processComponent(n1,n2,container,anchor,parentComponent,parentSuspense,namespace,slotScopeIds,optimized):(shapeFlag&64||shapeFlag&128)&&type.process(n1,n2,container,anchor,parentComponent,parentSuspense,namespace,slotScopeIds,optimized,internals)}ref$1!=null&&parentComponent?setRef(ref$1,n1&&n1.ref,parentSuspense,n2||n1,!n2):ref$1==null&&n1&&n1.ref!=null&&setRef(n1.ref,null,parentSuspense,n1,!0)},processText=(n1,n2,container,anchor)=>{if(n1==null)hostInsert(n2.el=hostCreateText(n2.children),container,anchor);else{let el=n2.el=n1.el;n2.children!==n1.children&&hostSetText(el,n2.children)}},processCommentNode=(n1,n2,container,anchor)=>{n1==null?hostInsert(n2.el=hostCreateComment(n2.children||``),container,anchor):n2.el=n1.el},mountStaticNode=(n2,container,anchor,namespace)=>{[n2.el,n2.anchor]=hostInsertStaticContent(n2.children,container,anchor,namespace,n2.el,n2.anchor)},moveStaticNode=({el,anchor},container,nextSibling)=>{let next;for(;el&&el!==anchor;)next=hostNextSibling(el),hostInsert(el,container,nextSibling),el=next;hostInsert(anchor,container,nextSibling)},removeStaticNode=({el,anchor})=>{let next;for(;el&&el!==anchor;)next=hostNextSibling(el),hostRemove(el),el=next;hostRemove(anchor)},processElement=(n1,n2,container,anchor,parentComponent,parentSuspense,namespace,slotScopeIds,optimized)=>{n2.type===`svg`?namespace=`svg`:n2.type===`math`&&(namespace=`mathml`),n1==null?mountElement(n2,container,anchor,parentComponent,parentSuspense,namespace,slotScopeIds,optimized):patchElement(n1,n2,parentComponent,parentSuspense,namespace,slotScopeIds,optimized)},mountElement=(vnode,container,anchor,parentComponent,parentSuspense,namespace,slotScopeIds,optimized)=>{let el,vnodeHook,{props,shapeFlag,transition,dirs}=vnode;if(el=vnode.el=hostCreateElement(vnode.type,namespace,props&&props.is,props),shapeFlag&8?hostSetElementText(el,vnode.children):shapeFlag&16&&mountChildren(vnode.children,el,null,parentComponent,parentSuspense,resolveChildrenNamespace(vnode,namespace),slotScopeIds,optimized),dirs&&invokeDirectiveHook(vnode,null,parentComponent,`created`),setScopeId(el,vnode,vnode.scopeId,slotScopeIds,parentComponent),props){for(let key in props)key!==`value`&&!isReservedProp(key)&&hostPatchProp(el,key,null,props[key],namespace,parentComponent);`value`in props&&hostPatchProp(el,`value`,null,props.value,namespace),(vnodeHook=props.onVnodeBeforeMount)&&invokeVNodeHook(vnodeHook,parentComponent,vnode)}dirs&&invokeDirectiveHook(vnode,null,parentComponent,`beforeMount`);let needCallTransitionHooks=needTransition(parentSuspense,transition);needCallTransitionHooks&&transition.beforeEnter(el),hostInsert(el,container,anchor),((vnodeHook=props&&props.onVnodeMounted)||needCallTransitionHooks||dirs)&&queuePostRenderEffect(()=>{vnodeHook&&invokeVNodeHook(vnodeHook,parentComponent,vnode),needCallTransitionHooks&&transition.enter(el),dirs&&invokeDirectiveHook(vnode,null,parentComponent,`mounted`)},parentSuspense)},setScopeId=(el,vnode,scopeId,slotScopeIds,parentComponent)=>{if(scopeId&&hostSetScopeId(el,scopeId),slotScopeIds)for(let i=0;i{for(let i=start;i{let el=n2.el=n1.el,{patchFlag,dynamicChildren,dirs}=n2;patchFlag|=n1.patchFlag&16;let oldProps=n1.props||EMPTY_OBJ,newProps=n2.props||EMPTY_OBJ,vnodeHook;if(parentComponent&&toggleRecurse(parentComponent,!1),(vnodeHook=newProps.onVnodeBeforeUpdate)&&invokeVNodeHook(vnodeHook,parentComponent,n2,n1),dirs&&invokeDirectiveHook(n2,n1,parentComponent,`beforeUpdate`),parentComponent&&toggleRecurse(parentComponent,!0),(oldProps.innerHTML&&newProps.innerHTML==null||oldProps.textContent&&newProps.textContent==null)&&hostSetElementText(el,``),dynamicChildren?patchBlockChildren(n1.dynamicChildren,dynamicChildren,el,parentComponent,parentSuspense,resolveChildrenNamespace(n2,namespace),slotScopeIds):optimized||patchChildren(n1,n2,el,null,parentComponent,parentSuspense,resolveChildrenNamespace(n2,namespace),slotScopeIds,!1),patchFlag>0){if(patchFlag&16)patchProps(el,oldProps,newProps,parentComponent,namespace);else if(patchFlag&2&&oldProps.class!==newProps.class&&hostPatchProp(el,`class`,null,newProps.class,namespace),patchFlag&4&&hostPatchProp(el,`style`,oldProps.style,newProps.style,namespace),patchFlag&8){let propsToUpdate=n2.dynamicProps;for(let i=0;i{vnodeHook&&invokeVNodeHook(vnodeHook,parentComponent,n2,n1),dirs&&invokeDirectiveHook(n2,n1,parentComponent,`updated`)},parentSuspense)},patchBlockChildren=(oldChildren,newChildren,fallbackContainer,parentComponent,parentSuspense,namespace,slotScopeIds)=>{for(let i=0;i{if(oldProps!==newProps){if(oldProps!==EMPTY_OBJ)for(let key in oldProps)!isReservedProp(key)&&!(key in newProps)&&hostPatchProp(el,key,oldProps[key],null,namespace,parentComponent);for(let key in newProps){if(isReservedProp(key))continue;let next=newProps[key],prev=oldProps[key];next!==prev&&key!==`value`&&hostPatchProp(el,key,prev,next,namespace,parentComponent)}`value`in newProps&&hostPatchProp(el,`value`,oldProps.value,newProps.value,namespace)}},processFragment=(n1,n2,container,anchor,parentComponent,parentSuspense,namespace,slotScopeIds,optimized)=>{let fragmentStartAnchor=n2.el=n1?n1.el:hostCreateText(``),fragmentEndAnchor=n2.anchor=n1?n1.anchor:hostCreateText(``),{patchFlag,dynamicChildren,slotScopeIds:fragmentSlotScopeIds}=n2;fragmentSlotScopeIds&&(slotScopeIds=slotScopeIds?slotScopeIds.concat(fragmentSlotScopeIds):fragmentSlotScopeIds),n1==null?(hostInsert(fragmentStartAnchor,container,anchor),hostInsert(fragmentEndAnchor,container,anchor),mountChildren(n2.children||[],container,fragmentEndAnchor,parentComponent,parentSuspense,namespace,slotScopeIds,optimized)):patchFlag>0&&patchFlag&64&&dynamicChildren&&n1.dynamicChildren?(patchBlockChildren(n1.dynamicChildren,dynamicChildren,container,parentComponent,parentSuspense,namespace,slotScopeIds),(n2.key!=null||parentComponent&&n2===parentComponent.subTree)&&traverseStaticChildren(n1,n2,!0)):patchChildren(n1,n2,container,fragmentEndAnchor,parentComponent,parentSuspense,namespace,slotScopeIds,optimized)},processComponent=(n1,n2,container,anchor,parentComponent,parentSuspense,namespace,slotScopeIds,optimized)=>{n2.slotScopeIds=slotScopeIds,n1==null?n2.shapeFlag&512?parentComponent.ctx.activate(n2,container,anchor,namespace,optimized):mountComponent(n2,container,anchor,parentComponent,parentSuspense,namespace,optimized):updateComponent(n1,n2,optimized)},mountComponent=(initialVNode,container,anchor,parentComponent,parentSuspense,namespace,optimized)=>{let instance$1=initialVNode.component=createComponentInstance(initialVNode,parentComponent,parentSuspense);if(isKeepAlive(initialVNode)&&(instance$1.ctx.renderer=internals),setupComponent(instance$1,!1,optimized),instance$1.asyncDep){if(parentSuspense&&parentSuspense.registerDep(instance$1,setupRenderEffect,optimized),!initialVNode.el){let placeholder=instance$1.subTree=createVNode(Comment);processCommentNode(null,placeholder,container,anchor),initialVNode.placeholder=placeholder.el}}else setupRenderEffect(instance$1,initialVNode,container,anchor,parentSuspense,namespace,optimized)},updateComponent=(n1,n2,optimized)=>{let instance$1=n2.component=n1.component;if(shouldUpdateComponent(n1,n2,optimized))if(instance$1.asyncDep&&!instance$1.asyncResolved){updateComponentPreRender(instance$1,n2,optimized);return}else instance$1.next=n2,instance$1.update();else n2.el=n1.el,instance$1.vnode=n2},setupRenderEffect=(instance$1,initialVNode,container,anchor,parentSuspense,namespace,optimized)=>{let componentUpdateFn=()=>{if(instance$1.isMounted){let{next,bu,u,parent,vnode}=instance$1;{let nonHydratedAsyncRoot=locateNonHydratedAsyncRoot(instance$1);if(nonHydratedAsyncRoot){next&&(next.el=vnode.el,updateComponentPreRender(instance$1,next,optimized)),nonHydratedAsyncRoot.asyncDep.then(()=>{instance$1.isUnmounted||componentUpdateFn()});return}}let originNext=next,vnodeHook;toggleRecurse(instance$1,!1),next?(next.el=vnode.el,updateComponentPreRender(instance$1,next,optimized)):next=vnode,bu&&invokeArrayFns(bu),(vnodeHook=next.props&&next.props.onVnodeBeforeUpdate)&&invokeVNodeHook(vnodeHook,parent,next,vnode),toggleRecurse(instance$1,!0);let nextTree=renderComponentRoot(instance$1),prevTree=instance$1.subTree;instance$1.subTree=nextTree,patch(prevTree,nextTree,hostParentNode(prevTree.el),getNextHostNode(prevTree),instance$1,parentSuspense,namespace),next.el=nextTree.el,originNext===null&&updateHOCHostEl(instance$1,nextTree.el),u&&queuePostRenderEffect(u,parentSuspense),(vnodeHook=next.props&&next.props.onVnodeUpdated)&&queuePostRenderEffect(()=>invokeVNodeHook(vnodeHook,parent,next,vnode),parentSuspense)}else{let vnodeHook,{el,props}=initialVNode,{bm,m,parent,root,type}=instance$1,isAsyncWrapperVNode=isAsyncWrapper(initialVNode);if(toggleRecurse(instance$1,!1),bm&&invokeArrayFns(bm),!isAsyncWrapperVNode&&(vnodeHook=props&&props.onVnodeBeforeMount)&&invokeVNodeHook(vnodeHook,parent,initialVNode),toggleRecurse(instance$1,!0),el&&hydrateNode){let hydrateSubTree=()=>{instance$1.subTree=renderComponentRoot(instance$1),hydrateNode(el,instance$1.subTree,instance$1,parentSuspense,null)};isAsyncWrapperVNode&&type.__asyncHydrate?type.__asyncHydrate(el,instance$1,hydrateSubTree):hydrateSubTree()}else{root.ce&&root.ce._def.shadowRoot!==!1&&root.ce._injectChildStyle(type);let subTree=instance$1.subTree=renderComponentRoot(instance$1);patch(null,subTree,container,anchor,instance$1,parentSuspense,namespace),initialVNode.el=subTree.el}if(m&&queuePostRenderEffect(m,parentSuspense),!isAsyncWrapperVNode&&(vnodeHook=props&&props.onVnodeMounted)){let scopedInitialVNode=initialVNode;queuePostRenderEffect(()=>invokeVNodeHook(vnodeHook,parent,scopedInitialVNode),parentSuspense)}(initialVNode.shapeFlag&256||parent&&isAsyncWrapper(parent.vnode)&&parent.vnode.shapeFlag&256)&&instance$1.a&&queuePostRenderEffect(instance$1.a,parentSuspense),instance$1.isMounted=!0,initialVNode=container=anchor=null}};instance$1.scope.on();let effect$1=instance$1.effect=new ReactiveEffect(componentUpdateFn);instance$1.scope.off();let update$6=instance$1.update=effect$1.run.bind(effect$1),job=instance$1.job=effect$1.runIfDirty.bind(effect$1);job.i=instance$1,job.id=instance$1.uid,effect$1.scheduler=()=>queueJob(job),toggleRecurse(instance$1,!0),update$6()},updateComponentPreRender=(instance$1,nextVNode,optimized)=>{nextVNode.component=instance$1;let prevProps=instance$1.vnode.props;instance$1.vnode=nextVNode,instance$1.next=null,updateProps(instance$1,nextVNode.props,prevProps,optimized),updateSlots(instance$1,nextVNode.children,optimized),pauseTracking(),flushPreFlushCbs(instance$1),resetTracking()},patchChildren=(n1,n2,container,anchor,parentComponent,parentSuspense,namespace,slotScopeIds,optimized=!1)=>{let c1=n1&&n1.children,prevShapeFlag=n1?n1.shapeFlag:0,c2=n2.children,{patchFlag,shapeFlag}=n2;if(patchFlag>0){if(patchFlag&128){patchKeyedChildren(c1,c2,container,anchor,parentComponent,parentSuspense,namespace,slotScopeIds,optimized);return}else if(patchFlag&256){patchUnkeyedChildren(c1,c2,container,anchor,parentComponent,parentSuspense,namespace,slotScopeIds,optimized);return}}shapeFlag&8?(prevShapeFlag&16&&unmountChildren(c1,parentComponent,parentSuspense),c2!==c1&&hostSetElementText(container,c2)):prevShapeFlag&16?shapeFlag&16?patchKeyedChildren(c1,c2,container,anchor,parentComponent,parentSuspense,namespace,slotScopeIds,optimized):unmountChildren(c1,parentComponent,parentSuspense,!0):(prevShapeFlag&8&&hostSetElementText(container,``),shapeFlag&16&&mountChildren(c2,container,anchor,parentComponent,parentSuspense,namespace,slotScopeIds,optimized))},patchUnkeyedChildren=(c1,c2,container,anchor,parentComponent,parentSuspense,namespace,slotScopeIds,optimized)=>{c1||=EMPTY_ARR,c2||=EMPTY_ARR;let oldLength=c1.length,newLength=c2.length,commonLength=Math.min(oldLength,newLength),i;for(i=0;inewLength?unmountChildren(c1,parentComponent,parentSuspense,!0,!1,commonLength):mountChildren(c2,container,anchor,parentComponent,parentSuspense,namespace,slotScopeIds,optimized,commonLength)},patchKeyedChildren=(c1,c2,container,parentAnchor,parentComponent,parentSuspense,namespace,slotScopeIds,optimized)=>{let i=0,l2=c2.length,e1=c1.length-1,e2=l2-1;for(;i<=e1&&i<=e2;){let n1=c1[i],n2=c2[i]=optimized?cloneIfMounted(c2[i]):normalizeVNode(c2[i]);if(isSameVNodeType(n1,n2))patch(n1,n2,container,null,parentComponent,parentSuspense,namespace,slotScopeIds,optimized);else break;i++}for(;i<=e1&&i<=e2;){let n1=c1[e1],n2=c2[e2]=optimized?cloneIfMounted(c2[e2]):normalizeVNode(c2[e2]);if(isSameVNodeType(n1,n2))patch(n1,n2,container,null,parentComponent,parentSuspense,namespace,slotScopeIds,optimized);else break;e1--,e2--}if(i>e1){if(i<=e2){let nextPos=e2+1,anchor=nextPose2)for(;i<=e1;)unmount(c1[i],parentComponent,parentSuspense,!0),i++;else{let s1=i,s2=i,keyToNewIndexMap=new Map;for(i=s2;i<=e2;i++){let nextChild=c2[i]=optimized?cloneIfMounted(c2[i]):normalizeVNode(c2[i]);nextChild.key!=null&&keyToNewIndexMap.set(nextChild.key,i)}let j,patched=0,toBePatched=e2-s2+1,moved=!1,maxNewIndexSoFar=0,newIndexToOldIndexMap=Array(toBePatched);for(i=0;i=toBePatched){unmount(prevChild,parentComponent,parentSuspense,!0);continue}let newIndex;if(prevChild.key!=null)newIndex=keyToNewIndexMap.get(prevChild.key);else for(j=s2;j<=e2;j++)if(newIndexToOldIndexMap[j-s2]===0&&isSameVNodeType(prevChild,c2[j])){newIndex=j;break}newIndex===void 0?unmount(prevChild,parentComponent,parentSuspense,!0):(newIndexToOldIndexMap[newIndex-s2]=i+1,newIndex>=maxNewIndexSoFar?maxNewIndexSoFar=newIndex:moved=!0,patch(prevChild,c2[newIndex],container,null,parentComponent,parentSuspense,namespace,slotScopeIds,optimized),patched++)}let increasingNewIndexSequence=moved?getSequence(newIndexToOldIndexMap):EMPTY_ARR;for(j=increasingNewIndexSequence.length-1,i=toBePatched-1;i>=0;i--){let nextIndex=s2+i,nextChild=c2[nextIndex],anchorVNode=c2[nextIndex+1],anchor=nextIndex+1{let{el,type,transition,children,shapeFlag}=vnode;if(shapeFlag&6){move(vnode.component.subTree,container,anchor,moveType);return}if(shapeFlag&128){vnode.suspense.move(container,anchor,moveType);return}if(shapeFlag&64){type.move(vnode,container,anchor,internals);return}if(type===Fragment){hostInsert(el,container,anchor);for(let i=0;itransition.enter(el),parentSuspense);else{let{leave,delayLeave,afterLeave}=transition,remove2=()=>{vnode.ctx.isUnmounted?hostRemove(el):hostInsert(el,container,anchor)},performLeave=()=>{el._isLeaving&&el[leaveCbKey](!0),leave(el,()=>{remove2(),afterLeave&&afterLeave()})};delayLeave?delayLeave(el,remove2,performLeave):performLeave()}else hostInsert(el,container,anchor)},unmount=(vnode,parentComponent,parentSuspense,doRemove=!1,optimized=!1)=>{let{type,props,ref:ref$1,children,dynamicChildren,shapeFlag,patchFlag,dirs,cacheIndex}=vnode;if(patchFlag===-2&&(optimized=!1),ref$1!=null&&(pauseTracking(),setRef(ref$1,null,parentSuspense,vnode,!0),resetTracking()),cacheIndex!=null&&(parentComponent.renderCache[cacheIndex]=void 0),shapeFlag&256){parentComponent.ctx.deactivate(vnode);return}let shouldInvokeDirs=shapeFlag&1&&dirs,shouldInvokeVnodeHook=!isAsyncWrapper(vnode),vnodeHook;if(shouldInvokeVnodeHook&&(vnodeHook=props&&props.onVnodeBeforeUnmount)&&invokeVNodeHook(vnodeHook,parentComponent,vnode),shapeFlag&6)unmountComponent(vnode.component,parentSuspense,doRemove);else{if(shapeFlag&128){vnode.suspense.unmount(parentSuspense,doRemove);return}shouldInvokeDirs&&invokeDirectiveHook(vnode,null,parentComponent,`beforeUnmount`),shapeFlag&64?vnode.type.remove(vnode,parentComponent,parentSuspense,internals,doRemove):dynamicChildren&&!dynamicChildren.hasOnce&&(type!==Fragment||patchFlag>0&&patchFlag&64)?unmountChildren(dynamicChildren,parentComponent,parentSuspense,!1,!0):(type===Fragment&&patchFlag&384||!optimized&&shapeFlag&16)&&unmountChildren(children,parentComponent,parentSuspense),doRemove&&remove$3(vnode)}(shouldInvokeVnodeHook&&(vnodeHook=props&&props.onVnodeUnmounted)||shouldInvokeDirs)&&queuePostRenderEffect(()=>{vnodeHook&&invokeVNodeHook(vnodeHook,parentComponent,vnode),shouldInvokeDirs&&invokeDirectiveHook(vnode,null,parentComponent,`unmounted`)},parentSuspense)},remove$3=vnode=>{let{type,el,anchor,transition}=vnode;if(type===Fragment){removeFragment(el,anchor);return}if(type===Static){removeStaticNode(vnode);return}let performRemove=()=>{hostRemove(el),transition&&!transition.persisted&&transition.afterLeave&&transition.afterLeave()};if(vnode.shapeFlag&1&&transition&&!transition.persisted){let{leave,delayLeave}=transition,performLeave=()=>leave(el,performRemove);delayLeave?delayLeave(vnode.el,performRemove,performLeave):performLeave()}else performRemove()},removeFragment=(cur,end)=>{let next;for(;cur!==end;)next=hostNextSibling(cur),hostRemove(cur),cur=next;hostRemove(end)},unmountComponent=(instance$1,parentSuspense,doRemove)=>{let{bum,scope:scope$1,job,subTree,um,m,a:a$1}=instance$1;invalidateMount(m),invalidateMount(a$1),bum&&invokeArrayFns(bum),scope$1.stop(),job&&(job.flags|=8,unmount(subTree,instance$1,parentSuspense,doRemove)),um&&queuePostRenderEffect(um,parentSuspense),queuePostRenderEffect(()=>{instance$1.isUnmounted=!0},parentSuspense)},unmountChildren=(children,parentComponent,parentSuspense,doRemove=!1,optimized=!1,start=0)=>{for(let i=start;i{if(vnode.shapeFlag&6)return getNextHostNode(vnode.component.subTree);if(vnode.shapeFlag&128)return vnode.suspense.next();let el=hostNextSibling(vnode.anchor||vnode.el),teleportEnd=el&&el[TeleportEndKey];return teleportEnd?hostNextSibling(teleportEnd):el},isFlushing=!1,render$1=(vnode,container,namespace)=>{vnode==null?container._vnode&&unmount(container._vnode,null,null,!0):patch(container._vnode||null,vnode,container,null,null,null,namespace),container._vnode=vnode,isFlushing||=(isFlushing=!0,flushPreFlushCbs(),flushPostFlushCbs(),!1)},internals={p:patch,um:unmount,m:move,r:remove$3,mt:mountComponent,mc:mountChildren,pc:patchChildren,pbc:patchBlockChildren,n:getNextHostNode,o:options},hydrate$1,hydrateNode;return createHydrationFns&&([hydrate$1,hydrateNode]=createHydrationFns(internals)),{render:render$1,hydrate:hydrate$1,createApp:createAppAPI(render$1,hydrate$1)}}function resolveChildrenNamespace({type,props},currentNamespace){return currentNamespace===`svg`&&type===`foreignObject`||currentNamespace===`mathml`&&type===`annotation-xml`&&props&&props.encoding&&props.encoding.includes(`html`)?void 0:currentNamespace}function toggleRecurse({effect:effect$1,job},allowed){allowed?(effect$1.flags|=32,job.flags|=4):(effect$1.flags&=-33,job.flags&=-5)}function needTransition(parentSuspense,transition){return(!parentSuspense||parentSuspense&&!parentSuspense.pendingBranch)&&transition&&!transition.persisted}function traverseStaticChildren(n1,n2,shallow=!1){let ch1=n1.children,ch2=n2.children;if(isArray$2(ch1)&&isArray$2(ch2))for(let i=0;i>1,arr[result[c]]0&&(p$1[i]=result[u-1]),result[u]=i)}}for(u=result.length,v=result[u-1];u-- >0;)result[u]=v,v=p$1[v];return result}function locateNonHydratedAsyncRoot(instance$1){let subComponent=instance$1.subTree.component;if(subComponent)return subComponent.asyncDep&&!subComponent.asyncResolved?subComponent:locateNonHydratedAsyncRoot(subComponent)}function invalidateMount(hooks){if(hooks)for(let i=0;iinject(ssrContextKey);function watchEffect(effect$1,options){return doWatch(effect$1,null,options)}function watchPostEffect(effect$1,options){return doWatch(effect$1,null,{flush:`post`})}function watchSyncEffect(effect$1,options){return doWatch(effect$1,null,{flush:`sync`})}function watch(source,cb,options){return doWatch(source,cb,options)}function doWatch(source,cb,options=EMPTY_OBJ){let{immediate,deep,flush,once}=options,baseWatchOptions=extend({},options),runsImmediately=cb&&immediate||!cb&&flush!==`post`,ssrCleanup;if(isInSSRComponentSetup){if(flush===`sync`){let ctx=useSSRContext();ssrCleanup=ctx.__watcherHandles||=[]}else if(!runsImmediately){let watchStopHandle=()=>{};return watchStopHandle.stop=NOOP,watchStopHandle.resume=NOOP,watchStopHandle.pause=NOOP,watchStopHandle}}let instance$1=currentInstance;baseWatchOptions.call=(fn,type,args)=>callWithAsyncErrorHandling(fn,instance$1,type,args);let isPre=!1;flush===`post`?baseWatchOptions.scheduler=job=>{queuePostRenderEffect(job,instance$1&&instance$1.suspense)}:flush!==`sync`&&(isPre=!0,baseWatchOptions.scheduler=(job,isFirstRun)=>{isFirstRun?job():queueJob(job)}),baseWatchOptions.augmentJob=job=>{cb&&(job.flags|=4),isPre&&(job.flags|=2,instance$1&&(job.id=instance$1.uid,job.i=instance$1))};let watchHandle=watch$1(source,cb,baseWatchOptions);return isInSSRComponentSetup&&(ssrCleanup?ssrCleanup.push(watchHandle):runsImmediately&&watchHandle()),watchHandle}function instanceWatch(source,value,options){let publicThis=this.proxy,getter=isString$1(source)?source.includes(`.`)?createPathGetter(publicThis,source):()=>publicThis[source]:source.bind(publicThis,publicThis),cb;isFunction$1(value)?cb=value:(cb=value.handler,options=value);let reset$1=setCurrentInstance(this),res=doWatch(getter,cb.bind(publicThis),options);return reset$1(),res}function createPathGetter(ctx,path){let segments=path.split(`.`);return()=>{let cur=ctx;for(let i=0;i{let localValue,prevSetValue=EMPTY_OBJ,prevEmittedValue;return watchSyncEffect(()=>{let propValue=props[camelizedName];hasChanged(localValue,propValue)&&(localValue=propValue,trigger$2())}),{get(){return track$1(),options.get?options.get(localValue):localValue},set(value){let emittedValue=options.set?options.set(value):value;if(!hasChanged(emittedValue,localValue)&&!(prevSetValue!==EMPTY_OBJ&&hasChanged(value,prevSetValue)))return;let rawProps=i.vnode.props;rawProps&&(name in rawProps||camelizedName in rawProps||hyphenatedName in rawProps)&&(`onUpdate:${name}`in rawProps||`onUpdate:${camelizedName}`in rawProps||`onUpdate:${hyphenatedName}`in rawProps)||(localValue=value,trigger$2()),i.emit(`update:${name}`,emittedValue),hasChanged(value,emittedValue)&&hasChanged(value,prevSetValue)&&!hasChanged(emittedValue,prevEmittedValue)&&trigger$2(),prevSetValue=value,prevEmittedValue=emittedValue}}});return res[Symbol.iterator]=()=>{let i2=0;return{next(){return i2<2?{value:i2++?modifiers||EMPTY_OBJ:res,done:!1}:{done:!0}}}},res}var getModelModifiers=(props,modelName)=>modelName===`modelValue`||modelName===`model-value`?props.modelModifiers:props[`${modelName}Modifiers`]||props[`${camelize(modelName)}Modifiers`]||props[`${hyphenate(modelName)}Modifiers`];function emit(instance$1,event,...rawArgs){if(instance$1.isUnmounted)return;let props=instance$1.vnode.props||EMPTY_OBJ,args=rawArgs,isModelListener$1=event.startsWith(`update:`),modifiers=isModelListener$1&&getModelModifiers(props,event.slice(7));modifiers&&(modifiers.trim&&(args=rawArgs.map(a$1=>isString$1(a$1)?a$1.trim():a$1)),modifiers.number&&(args=rawArgs.map(looseToNumber)));let handlerName,handler$1=props[handlerName=toHandlerKey(event)]||props[handlerName=toHandlerKey(camelize(event))];!handler$1&&isModelListener$1&&(handler$1=props[handlerName=toHandlerKey(hyphenate(event))]),handler$1&&callWithAsyncErrorHandling(handler$1,instance$1,6,args);let onceHandler=props[handlerName+`Once`];if(onceHandler){if(!instance$1.emitted)instance$1.emitted={};else if(instance$1.emitted[handlerName])return;instance$1.emitted[handlerName]=!0,callWithAsyncErrorHandling(onceHandler,instance$1,6,args)}}var mixinEmitsCache=new WeakMap;function normalizeEmitsOptions(comp,appContext,asMixin=!1){let cache$1=asMixin?mixinEmitsCache:appContext.emitsCache,cached=cache$1.get(comp);if(cached!==void 0)return cached;let raw=comp.emits,normalized={},hasExtends=!1;if(!isFunction$1(comp)){let extendEmits=raw2=>{let normalizedFromExtend=normalizeEmitsOptions(raw2,appContext,!0);normalizedFromExtend&&(hasExtends=!0,extend(normalized,normalizedFromExtend))};!asMixin&&appContext.mixins.length&&appContext.mixins.forEach(extendEmits),comp.extends&&extendEmits(comp.extends),comp.mixins&&comp.mixins.forEach(extendEmits)}return!raw&&!hasExtends?(isObject$1(comp)&&cache$1.set(comp,null),null):(isArray$2(raw)?raw.forEach(key=>normalized[key]=null):extend(normalized,raw),isObject$1(comp)&&cache$1.set(comp,normalized),normalized)}function isEmitListener(options,key){return!options||!isOn(key)?!1:(key=key.slice(2).replace(/Once$/,``),hasOwn$1(options,key[0].toLowerCase()+key.slice(1))||hasOwn$1(options,hyphenate(key))||hasOwn$1(options,key))}function renderComponentRoot(instance$1){let{type:Component,vnode,proxy,withProxy,propsOptions:[propsOptions],slots,attrs,emit:emit$1,render:render$1,renderCache,props,data,setupState,ctx,inheritAttrs}=instance$1,prev=setCurrentRenderingInstance(instance$1),result,fallthroughAttrs;try{if(vnode.shapeFlag&4){let proxyToUse=withProxy||proxy,thisProxy=proxyToUse;result=normalizeVNode(render$1.call(thisProxy,proxyToUse,renderCache,props,setupState,data,ctx)),fallthroughAttrs=attrs}else{let render2=Component;result=normalizeVNode(render2.length>1?render2(props,{attrs,slots,emit:emit$1}):render2(props,null)),fallthroughAttrs=Component.props?attrs:getFunctionalFallthrough(attrs)}}catch(err){blockStack.length=0,handleError(err,instance$1,1),result=createVNode(Comment)}let root=result;if(fallthroughAttrs&&inheritAttrs!==!1){let keys=Object.keys(fallthroughAttrs),{shapeFlag}=root;keys.length&&shapeFlag&7&&(propsOptions&&keys.some(isModelListener)&&(fallthroughAttrs=filterModelListeners(fallthroughAttrs,propsOptions)),root=cloneVNode(root,fallthroughAttrs,!1,!0))}return vnode.dirs&&(root=cloneVNode(root,null,!1,!0),root.dirs=root.dirs?root.dirs.concat(vnode.dirs):vnode.dirs),vnode.transition&&setTransitionHooks(root,vnode.transition),result=root,setCurrentRenderingInstance(prev),result}function filterSingleRoot(children,recurse=!0){let singleRoot;for(let i=0;i{let res;for(let key in attrs)(key===`class`||key===`style`||isOn(key))&&((res||={})[key]=attrs[key]);return res},filterModelListeners=(attrs,props)=>{let res={};for(let key in attrs)(!isModelListener(key)||!(key.slice(9)in props))&&(res[key]=attrs[key]);return res};function shouldUpdateComponent(prevVNode,nextVNode,optimized){let{props:prevProps,children:prevChildren,component}=prevVNode,{props:nextProps,children:nextChildren,patchFlag}=nextVNode,emits=component.emitsOptions;if(nextVNode.dirs||nextVNode.transition)return!0;if(optimized&&patchFlag>=0){if(patchFlag&1024)return!0;if(patchFlag&16)return prevProps?hasPropsChanged(prevProps,nextProps,emits):!!nextProps;if(patchFlag&8){let dynamicProps=nextVNode.dynamicProps;for(let i=0;itype.__isSuspense,suspenseId=0,Suspense={name:`Suspense`,__isSuspense:!0,process(n1,n2,container,anchor,parentComponent,parentSuspense,namespace,slotScopeIds,optimized,rendererInternals){if(n1==null)mountSuspense(n2,container,anchor,parentComponent,parentSuspense,namespace,slotScopeIds,optimized,rendererInternals);else{if(parentSuspense&&parentSuspense.deps>0&&!n1.suspense.isInFallback){n2.suspense=n1.suspense,n2.suspense.vnode=n2,n2.el=n1.el;return}patchSuspense(n1,n2,container,anchor,parentComponent,namespace,slotScopeIds,optimized,rendererInternals)}},hydrate:hydrateSuspense,normalize:normalizeSuspenseChildren};function triggerEvent(vnode,name){let eventListener=vnode.props&&vnode.props[name];isFunction$1(eventListener)&&eventListener()}function mountSuspense(vnode,container,anchor,parentComponent,parentSuspense,namespace,slotScopeIds,optimized,rendererInternals){let{p:patch,o:{createElement}}=rendererInternals,hiddenContainer=createElement(`div`),suspense=vnode.suspense=createSuspenseBoundary(vnode,parentSuspense,parentComponent,container,hiddenContainer,anchor,namespace,slotScopeIds,optimized,rendererInternals);patch(null,suspense.pendingBranch=vnode.ssContent,hiddenContainer,null,parentComponent,suspense,namespace,slotScopeIds),suspense.deps>0?(triggerEvent(vnode,`onPending`),triggerEvent(vnode,`onFallback`),patch(null,vnode.ssFallback,container,anchor,parentComponent,null,namespace,slotScopeIds),setActiveBranch(suspense,vnode.ssFallback)):suspense.resolve(!1,!0)}function patchSuspense(n1,n2,container,anchor,parentComponent,namespace,slotScopeIds,optimized,{p:patch,um:unmount,o:{createElement}}){let suspense=n2.suspense=n1.suspense;suspense.vnode=n2,n2.el=n1.el;let newBranch=n2.ssContent,newFallback=n2.ssFallback,{activeBranch,pendingBranch,isInFallback,isHydrating}=suspense;if(pendingBranch)suspense.pendingBranch=newBranch,isSameVNodeType(pendingBranch,newBranch)?(patch(pendingBranch,newBranch,suspense.hiddenContainer,null,parentComponent,suspense,namespace,slotScopeIds,optimized),suspense.deps<=0?suspense.resolve():isInFallback&&(isHydrating||(patch(activeBranch,newFallback,container,anchor,parentComponent,null,namespace,slotScopeIds,optimized),setActiveBranch(suspense,newFallback)))):(suspense.pendingId=suspenseId++,isHydrating?(suspense.isHydrating=!1,suspense.activeBranch=pendingBranch):unmount(pendingBranch,parentComponent,suspense),suspense.deps=0,suspense.effects.length=0,suspense.hiddenContainer=createElement(`div`),isInFallback?(patch(null,newBranch,suspense.hiddenContainer,null,parentComponent,suspense,namespace,slotScopeIds,optimized),suspense.deps<=0?suspense.resolve():(patch(activeBranch,newFallback,container,anchor,parentComponent,null,namespace,slotScopeIds,optimized),setActiveBranch(suspense,newFallback))):activeBranch&&isSameVNodeType(activeBranch,newBranch)?(patch(activeBranch,newBranch,container,anchor,parentComponent,suspense,namespace,slotScopeIds,optimized),suspense.resolve(!0)):(patch(null,newBranch,suspense.hiddenContainer,null,parentComponent,suspense,namespace,slotScopeIds,optimized),suspense.deps<=0&&suspense.resolve()));else if(activeBranch&&isSameVNodeType(activeBranch,newBranch))patch(activeBranch,newBranch,container,anchor,parentComponent,suspense,namespace,slotScopeIds,optimized),setActiveBranch(suspense,newBranch);else if(triggerEvent(n2,`onPending`),suspense.pendingBranch=newBranch,newBranch.shapeFlag&512?suspense.pendingId=newBranch.component.suspenseId:suspense.pendingId=suspenseId++,patch(null,newBranch,suspense.hiddenContainer,null,parentComponent,suspense,namespace,slotScopeIds,optimized),suspense.deps<=0)suspense.resolve();else{let{timeout,pendingId}=suspense;timeout>0?setTimeout(()=>{suspense.pendingId===pendingId&&suspense.fallback(newFallback)},timeout):timeout===0&&suspense.fallback(newFallback)}}function createSuspenseBoundary(vnode,parentSuspense,parentComponent,container,hiddenContainer,anchor,namespace,slotScopeIds,optimized,rendererInternals,isHydrating=!1){let{p:patch,m:move,um:unmount,n:next,o:{parentNode,remove:remove$3}}=rendererInternals,parentSuspenseId,isSuspensible=isVNodeSuspensible(vnode);isSuspensible&&parentSuspense&&parentSuspense.pendingBranch&&(parentSuspenseId=parentSuspense.pendingId,parentSuspense.deps++);let timeout=vnode.props?toNumber(vnode.props.timeout):void 0,initialAnchor=anchor,suspense={vnode,parent:parentSuspense,parentComponent,namespace,container,hiddenContainer,deps:0,pendingId:suspenseId++,timeout:typeof timeout==`number`?timeout:-1,activeBranch:null,pendingBranch:null,isInFallback:!isHydrating,isHydrating,isUnmounted:!1,effects:[],resolve(resume=!1,sync=!1){let{vnode:vnode2,activeBranch,pendingBranch,pendingId,effects,parentComponent:parentComponent2,container:container2}=suspense,delayEnter=!1;suspense.isHydrating?suspense.isHydrating=!1:resume||(delayEnter=activeBranch&&pendingBranch.transition&&pendingBranch.transition.mode===`out-in`,delayEnter&&(activeBranch.transition.afterLeave=()=>{pendingId===suspense.pendingId&&(move(pendingBranch,container2,anchor===initialAnchor?next(activeBranch):anchor,0),queuePostFlushCb(effects))}),activeBranch&&(parentNode(activeBranch.el)===container2&&(anchor=next(activeBranch)),unmount(activeBranch,parentComponent2,suspense,!0)),delayEnter||move(pendingBranch,container2,anchor,0)),setActiveBranch(suspense,pendingBranch),suspense.pendingBranch=null,suspense.isInFallback=!1;let parent=suspense.parent,hasUnresolvedAncestor=!1;for(;parent;){if(parent.pendingBranch){parent.effects.push(...effects),hasUnresolvedAncestor=!0;break}parent=parent.parent}!hasUnresolvedAncestor&&!delayEnter&&queuePostFlushCb(effects),suspense.effects=[],isSuspensible&&parentSuspense&&parentSuspense.pendingBranch&&parentSuspenseId===parentSuspense.pendingId&&(parentSuspense.deps--,parentSuspense.deps===0&&!sync&&parentSuspense.resolve()),triggerEvent(vnode2,`onResolve`)},fallback(fallbackVNode){if(!suspense.pendingBranch)return;let{vnode:vnode2,activeBranch,parentComponent:parentComponent2,container:container2,namespace:namespace2}=suspense;triggerEvent(vnode2,`onFallback`);let anchor2=next(activeBranch),mountFallback=()=>{suspense.isInFallback&&(patch(null,fallbackVNode,container2,anchor2,parentComponent2,null,namespace2,slotScopeIds,optimized),setActiveBranch(suspense,fallbackVNode))},delayEnter=fallbackVNode.transition&&fallbackVNode.transition.mode===`out-in`;delayEnter&&(activeBranch.transition.afterLeave=mountFallback),suspense.isInFallback=!0,unmount(activeBranch,parentComponent2,null,!0),delayEnter||mountFallback()},move(container2,anchor2,type){suspense.activeBranch&&move(suspense.activeBranch,container2,anchor2,type),suspense.container=container2},next(){return suspense.activeBranch&&next(suspense.activeBranch)},registerDep(instance$1,setupRenderEffect,optimized2){let isInPendingSuspense=!!suspense.pendingBranch;isInPendingSuspense&&suspense.deps++;let hydratedEl=instance$1.vnode.el;instance$1.asyncDep.catch(err=>{handleError(err,instance$1,0)}).then(asyncSetupResult=>{if(instance$1.isUnmounted||suspense.isUnmounted||suspense.pendingId!==instance$1.suspenseId)return;instance$1.asyncResolved=!0;let{vnode:vnode2}=instance$1;handleSetupResult(instance$1,asyncSetupResult,!1),hydratedEl&&(vnode2.el=hydratedEl);let placeholder=!hydratedEl&&instance$1.subTree.el;setupRenderEffect(instance$1,vnode2,parentNode(hydratedEl||instance$1.subTree.el),hydratedEl?null:next(instance$1.subTree),suspense,namespace,optimized2),placeholder&&remove$3(placeholder),updateHOCHostEl(instance$1,vnode2.el),isInPendingSuspense&&--suspense.deps===0&&suspense.resolve()})},unmount(parentSuspense2,doRemove){suspense.isUnmounted=!0,suspense.activeBranch&&unmount(suspense.activeBranch,parentComponent,parentSuspense2,doRemove),suspense.pendingBranch&&unmount(suspense.pendingBranch,parentComponent,parentSuspense2,doRemove)}};return suspense}function hydrateSuspense(node,vnode,parentComponent,parentSuspense,namespace,slotScopeIds,optimized,rendererInternals,hydrateNode){let suspense=vnode.suspense=createSuspenseBoundary(vnode,parentSuspense,parentComponent,node.parentNode,document.createElement(`div`),null,namespace,slotScopeIds,optimized,rendererInternals,!0),result=hydrateNode(node,suspense.pendingBranch=vnode.ssContent,parentComponent,suspense,slotScopeIds,optimized);return suspense.deps===0&&suspense.resolve(!1,!0),result}function normalizeSuspenseChildren(vnode){let{shapeFlag,children}=vnode,isSlotChildren=shapeFlag&32;vnode.ssContent=normalizeSuspenseSlot(isSlotChildren?children.default:children),vnode.ssFallback=isSlotChildren?normalizeSuspenseSlot(children.fallback):createVNode(Comment)}function normalizeSuspenseSlot(s){let block;if(isFunction$1(s)){let trackBlock=isBlockTreeEnabled&&s._c;trackBlock&&(s._d=!1,openBlock()),s=s(),trackBlock&&(s._d=!0,block=currentBlock,closeBlock())}return isArray$2(s)&&(s=filterSingleRoot(s)),s=normalizeVNode(s),block&&!s.dynamicChildren&&(s.dynamicChildren=block.filter(c=>c!==s)),s}function queueEffectWithSuspense(fn,suspense){suspense&&suspense.pendingBranch?isArray$2(fn)?suspense.effects.push(...fn):suspense.effects.push(fn):queuePostFlushCb(fn)}function setActiveBranch(suspense,branch){suspense.activeBranch=branch;let{vnode,parentComponent}=suspense,el=branch.el;for(;!el&&branch.component;)branch=branch.component.subTree,el=branch.el;vnode.el=el,parentComponent&&parentComponent.subTree===vnode&&(parentComponent.vnode.el=el,updateHOCHostEl(parentComponent,el))}function isVNodeSuspensible(vnode){let suspensible=vnode.props&&vnode.props.suspensible;return suspensible!=null&&suspensible!==!1}var Fragment=Symbol.for(`v-fgt`),Text=Symbol.for(`v-txt`),Comment=Symbol.for(`v-cmt`),Static=Symbol.for(`v-stc`),blockStack=[],currentBlock=null;function openBlock(disableTracking=!1){blockStack.push(currentBlock=disableTracking?null:[])}function closeBlock(){blockStack.pop(),currentBlock=blockStack[blockStack.length-1]||null}var isBlockTreeEnabled=1;function setBlockTracking(value,inVOnce=!1){isBlockTreeEnabled+=value,value<0&¤tBlock&&inVOnce&&(currentBlock.hasOnce=!0)}function setupBlock(vnode){return vnode.dynamicChildren=isBlockTreeEnabled>0?currentBlock||EMPTY_ARR:null,closeBlock(),isBlockTreeEnabled>0&¤tBlock&¤tBlock.push(vnode),vnode}function createElementBlock(type,props,children,patchFlag,dynamicProps,shapeFlag){return setupBlock(createBaseVNode(type,props,children,patchFlag,dynamicProps,shapeFlag,!0))}function createBlock(type,props,children,patchFlag,dynamicProps){return setupBlock(createVNode(type,props,children,patchFlag,dynamicProps,!0))}function isVNode(value){return value?value.__v_isVNode===!0:!1}function isSameVNodeType(n1,n2){return n1.type===n2.type&&n1.key===n2.key}function transformVNodeArgs(transformer){}var normalizeKey=({key})=>key??null,normalizeRef=({ref:ref$1,ref_key,ref_for})=>(typeof ref$1==`number`&&(ref$1=``+ref$1),ref$1==null?null:isString$1(ref$1)||isRef(ref$1)||isFunction$1(ref$1)?{i:currentRenderingInstance,r:ref$1,k:ref_key,f:!!ref_for}:ref$1);function createBaseVNode(type,props=null,children=null,patchFlag=0,dynamicProps=null,shapeFlag=type===Fragment?0:1,isBlockNode=!1,needFullChildrenNormalization=!1){let vnode={__v_isVNode:!0,__v_skip:!0,type,props,key:props&&normalizeKey(props),ref:props&&normalizeRef(props),scopeId:currentScopeId,slotScopeIds:null,children,component:null,suspense:null,ssContent:null,ssFallback:null,dirs:null,transition:null,el:null,anchor:null,target:null,targetStart:null,targetAnchor:null,staticCount:0,shapeFlag,patchFlag,dynamicProps,dynamicChildren:null,appContext:null,ctx:currentRenderingInstance};return needFullChildrenNormalization?(normalizeChildren(vnode,children),shapeFlag&128&&type.normalize(vnode)):children&&(vnode.shapeFlag|=isString$1(children)?8:16),isBlockTreeEnabled>0&&!isBlockNode&¤tBlock&&(vnode.patchFlag>0||shapeFlag&6)&&vnode.patchFlag!==32&¤tBlock.push(vnode),vnode}var createVNode=_createVNode;function _createVNode(type,props=null,children=null,patchFlag=0,dynamicProps=null,isBlockNode=!1){if((!type||type===NULL_DYNAMIC_COMPONENT)&&(type=Comment),isVNode(type)){let cloned=cloneVNode(type,props,!0);return children&&normalizeChildren(cloned,children),isBlockTreeEnabled>0&&!isBlockNode&¤tBlock&&(cloned.shapeFlag&6?currentBlock[currentBlock.indexOf(type)]=cloned:currentBlock.push(cloned)),cloned.patchFlag=-2,cloned}if(isClassComponent(type)&&(type=type.__vccOpts),props){props=guardReactiveProps(props);let{class:klass,style}=props;klass&&!isString$1(klass)&&(props.class=normalizeClass(klass)),isObject$1(style)&&(isProxy(style)&&!isArray$2(style)&&(style=extend({},style)),props.style=normalizeStyle(style))}let shapeFlag=isString$1(type)?1:isSuspense(type)?128:isTeleport(type)?64:isObject$1(type)?4:isFunction$1(type)?2:0;return createBaseVNode(type,props,children,patchFlag,dynamicProps,shapeFlag,isBlockNode,!0)}function guardReactiveProps(props){return props?isProxy(props)||isInternalObject(props)?extend({},props):props:null}function cloneVNode(vnode,extraProps,mergeRef=!1,cloneTransition=!1){let{props,ref:ref$1,patchFlag,children,transition}=vnode,mergedProps=extraProps?mergeProps(props||{},extraProps):props,cloned={__v_isVNode:!0,__v_skip:!0,type:vnode.type,props:mergedProps,key:mergedProps&&normalizeKey(mergedProps),ref:extraProps&&extraProps.ref?mergeRef&&ref$1?isArray$2(ref$1)?ref$1.concat(normalizeRef(extraProps)):[ref$1,normalizeRef(extraProps)]:normalizeRef(extraProps):ref$1,scopeId:vnode.scopeId,slotScopeIds:vnode.slotScopeIds,children,target:vnode.target,targetStart:vnode.targetStart,targetAnchor:vnode.targetAnchor,staticCount:vnode.staticCount,shapeFlag:vnode.shapeFlag,patchFlag:extraProps&&vnode.type!==Fragment?patchFlag===-1?16:patchFlag|16:patchFlag,dynamicProps:vnode.dynamicProps,dynamicChildren:vnode.dynamicChildren,appContext:vnode.appContext,dirs:vnode.dirs,transition,component:vnode.component,suspense:vnode.suspense,ssContent:vnode.ssContent&&cloneVNode(vnode.ssContent),ssFallback:vnode.ssFallback&&cloneVNode(vnode.ssFallback),placeholder:vnode.placeholder,el:vnode.el,anchor:vnode.anchor,ctx:vnode.ctx,ce:vnode.ce};return transition&&cloneTransition&&setTransitionHooks(cloned,transition.clone(cloned)),cloned}function createTextVNode(text=` `,flag=0){return createVNode(Text,null,text,flag)}function createStaticVNode(content,numberOfNodes){let vnode=createVNode(Static,null,content);return vnode.staticCount=numberOfNodes,vnode}function createCommentVNode(text=``,asBlock=!1){return asBlock?(openBlock(),createBlock(Comment,null,text)):createVNode(Comment,null,text)}function normalizeVNode(child){return child==null||typeof child==`boolean`?createVNode(Comment):isArray$2(child)?createVNode(Fragment,null,child.slice()):isVNode(child)?cloneIfMounted(child):createVNode(Text,null,String(child))}function cloneIfMounted(child){return child.el===null&&child.patchFlag!==-1||child.memo?child:cloneVNode(child)}function normalizeChildren(vnode,children){let type=0,{shapeFlag}=vnode;if(children==null)children=null;else if(isArray$2(children))type=16;else if(typeof children==`object`)if(shapeFlag&65){let slot=children.default;slot&&(slot._c&&(slot._d=!1),normalizeChildren(vnode,slot()),slot._c&&(slot._d=!0));return}else{type=32;let slotFlag=children._;!slotFlag&&!isInternalObject(children)?children._ctx=currentRenderingInstance:slotFlag===3&¤tRenderingInstance&&(currentRenderingInstance.slots._===1?children._=1:(children._=2,vnode.patchFlag|=1024))}else isFunction$1(children)?(children={default:children,_ctx:currentRenderingInstance},type=32):(children=String(children),shapeFlag&64?(type=16,children=[createTextVNode(children)]):type=8);vnode.children=children,vnode.shapeFlag|=type}function mergeProps(...args){let ret={};for(let i=0;icurrentInstance||currentRenderingInstance,internalSetCurrentInstance,setInSSRSetupState;{let g=getGlobalThis$1(),registerGlobalSetter=(key,setter)=>{let setters;return(setters=g[key])||(setters=g[key]=[]),setters.push(setter),v=>{setters.length>1?setters.forEach(set=>set(v)):setters[0](v)}};internalSetCurrentInstance=registerGlobalSetter(`__VUE_INSTANCE_SETTERS__`,v=>currentInstance=v),setInSSRSetupState=registerGlobalSetter(`__VUE_SSR_SETTERS__`,v=>isInSSRComponentSetup=v)}var setCurrentInstance=instance$1=>{let prev=currentInstance;return internalSetCurrentInstance(instance$1),instance$1.scope.on(),()=>{instance$1.scope.off(),internalSetCurrentInstance(prev)}},unsetCurrentInstance=()=>{currentInstance&¤tInstance.scope.off(),internalSetCurrentInstance(null)};function isStatefulComponent(instance$1){return instance$1.vnode.shapeFlag&4}var isInSSRComponentSetup=!1;function setupComponent(instance$1,isSSR=!1,optimized=!1){isSSR&&setInSSRSetupState(isSSR);let{props,children}=instance$1.vnode,isStateful=isStatefulComponent(instance$1);initProps(instance$1,props,isStateful,isSSR),initSlots(instance$1,children,optimized||isSSR);let setupResult=isStateful?setupStatefulComponent(instance$1,isSSR):void 0;return isSSR&&setInSSRSetupState(!1),setupResult}function setupStatefulComponent(instance$1,isSSR){let Component=instance$1.type;instance$1.accessCache=Object.create(null),instance$1.proxy=new Proxy(instance$1.ctx,PublicInstanceProxyHandlers);let{setup:setup$3}=Component;if(setup$3){pauseTracking();let setupContext=instance$1.setupContext=setup$3.length>1?createSetupContext(instance$1):null,reset$1=setCurrentInstance(instance$1),setupResult=callWithErrorHandling(setup$3,instance$1,0,[instance$1.props,setupContext]),isAsyncSetup=isPromise$1(setupResult);if(resetTracking(),reset$1(),(isAsyncSetup||instance$1.sp)&&!isAsyncWrapper(instance$1)&&markAsyncBoundary(instance$1),isAsyncSetup){if(setupResult.then(unsetCurrentInstance,unsetCurrentInstance),isSSR)return setupResult.then(resolvedResult=>{handleSetupResult(instance$1,resolvedResult,isSSR)}).catch(e=>{handleError(e,instance$1,0)});instance$1.asyncDep=setupResult}else handleSetupResult(instance$1,setupResult,isSSR)}else finishComponentSetup(instance$1,isSSR)}function handleSetupResult(instance$1,setupResult,isSSR){isFunction$1(setupResult)?instance$1.type.__ssrInlineRender?instance$1.ssrRender=setupResult:instance$1.render=setupResult:isObject$1(setupResult)&&(instance$1.setupState=proxyRefs(setupResult)),finishComponentSetup(instance$1,isSSR)}var compile$2,installWithProxy;function registerRuntimeCompiler(_compile){compile$2=_compile,installWithProxy=i=>{i.render._rc&&(i.withProxy=new Proxy(i.ctx,RuntimeCompiledPublicInstanceProxyHandlers))}}var isRuntimeOnly=()=>!compile$2;function finishComponentSetup(instance$1,isSSR,skipOptions){let Component=instance$1.type;if(!instance$1.render){if(!isSSR&&compile$2&&!Component.render){let template=Component.template||resolveMergedOptions(instance$1).template;if(template){let{isCustomElement,compilerOptions}=instance$1.appContext.config,{delimiters,compilerOptions:componentCompilerOptions}=Component,finalCompilerOptions=extend(extend({isCustomElement,delimiters},compilerOptions),componentCompilerOptions);Component.render=compile$2(template,finalCompilerOptions)}}instance$1.render=Component.render||NOOP,installWithProxy&&installWithProxy(instance$1)}{let reset$1=setCurrentInstance(instance$1);pauseTracking();try{applyOptions$1(instance$1)}finally{resetTracking(),reset$1()}}}var attrsProxyHandlers={get(target,key){return track(target,`get`,``),target[key]}};function createSetupContext(instance$1){return{attrs:new Proxy(instance$1.attrs,attrsProxyHandlers),slots:instance$1.slots,emit:instance$1.emit,expose:exposed=>{instance$1.exposed=exposed||{}}}}function getComponentPublicInstance(instance$1){return instance$1.exposed?instance$1.exposeProxy||=new Proxy(proxyRefs(markRaw(instance$1.exposed)),{get(target,key){if(key in target)return target[key];if(key in publicPropertiesMap)return publicPropertiesMap[key](instance$1)},has(target,key){return key in target||key in publicPropertiesMap}}):instance$1.proxy}function getComponentName(Component,includeInferred=!0){return isFunction$1(Component)?Component.displayName||Component.name:Component.name||includeInferred&&Component.__name}function isClassComponent(value){return isFunction$1(value)&&`__vccOpts`in value}var computed=(getterOrOptions,debugOptions)=>computed$1(getterOrOptions,debugOptions,isInSSRComponentSetup);function h(type,propsOrChildren,children){try{setBlockTracking(-1);let l=arguments.length;return l===2?isObject$1(propsOrChildren)&&!isArray$2(propsOrChildren)?isVNode(propsOrChildren)?createVNode(type,null,[propsOrChildren]):createVNode(type,propsOrChildren):createVNode(type,null,propsOrChildren):(l>3?children=Array.prototype.slice.call(arguments,2):l===3&&isVNode(children)&&(children=[children]),createVNode(type,propsOrChildren,children))}finally{setBlockTracking(1)}}function initCustomFormatter(){return;function isKeyOfType(Comp,key,type){let opts=Comp[type];if(isArray$2(opts)&&opts.includes(key)||isObject$1(opts)&&key in opts||Comp.extends&&isKeyOfType(Comp.extends,key,type)||Comp.mixins&&Comp.mixins.some(m=>isKeyOfType(m,key,type)))return!0}}function withMemo(memo,render$1,cache$1,index){let cached=cache$1[index];if(cached&&isMemoSame(cached,memo))return cached;let ret=render$1();return ret.memo=memo.slice(),ret.cacheIndex=index,cache$1[index]=ret}function isMemoSame(cached,memo){let prev=cached.memo;if(prev.length!=memo.length)return!1;for(let i=0;i0&¤tBlock&¤tBlock.push(cached),!0}var version$1=`3.5.22`,warn$2=NOOP,ErrorTypeStrings=ErrorTypeStrings$1,devtools$2=devtools$1,setDevtoolsHook=setDevtoolsHook$1,ssrUtils={createComponentInstance,setupComponent,renderComponentRoot,setCurrentRenderingInstance,isVNode,normalizeVNode,getComponentPublicInstance,ensureValidVNode,pushWarningContext,popWarningContext},resolveFilter=null,compatUtils=null,DeprecationTypes=null,runtime_dom_esm_bundler_exports=__export({BaseTransition:()=>BaseTransition,BaseTransitionPropsValidators:()=>BaseTransitionPropsValidators,Comment:()=>Comment,DeprecationTypes:()=>null,EffectScope:()=>EffectScope,ErrorCodes:()=>ErrorCodes,ErrorTypeStrings:()=>ErrorTypeStrings,Fragment:()=>Fragment,KeepAlive:()=>KeepAlive,ReactiveEffect:()=>ReactiveEffect,Static:()=>Static,Suspense:()=>Suspense,Teleport:()=>Teleport,Text:()=>Text,TrackOpTypes:()=>TrackOpTypes,Transition:()=>Transition,TransitionGroup:()=>TransitionGroup,TriggerOpTypes:()=>TriggerOpTypes,VueElement:()=>VueElement,assertNumber:()=>assertNumber,callWithAsyncErrorHandling:()=>callWithAsyncErrorHandling,callWithErrorHandling:()=>callWithErrorHandling,camelize:()=>camelize,capitalize:()=>capitalize$1,cloneVNode:()=>cloneVNode,compatUtils:()=>null,computed:()=>computed,createApp:()=>createApp,createBlock:()=>createBlock,createCommentVNode:()=>createCommentVNode,createElementBlock:()=>createElementBlock,createElementVNode:()=>createBaseVNode,createHydrationRenderer:()=>createHydrationRenderer,createPropsRestProxy:()=>createPropsRestProxy,createRenderer:()=>createRenderer,createSSRApp:()=>createSSRApp,createSlots:()=>createSlots,createStaticVNode:()=>createStaticVNode,createTextVNode:()=>createTextVNode,createVNode:()=>createVNode,customRef:()=>customRef,defineAsyncComponent:()=>defineAsyncComponent,defineComponent:()=>defineComponent,defineCustomElement:()=>defineCustomElement,defineEmits:()=>defineEmits,defineExpose:()=>defineExpose,defineModel:()=>defineModel,defineOptions:()=>defineOptions,defineProps:()=>defineProps,defineSSRCustomElement:()=>defineSSRCustomElement,defineSlots:()=>defineSlots,devtools:()=>devtools$2,effect:()=>effect,effectScope:()=>effectScope,getCurrentInstance:()=>getCurrentInstance,getCurrentScope:()=>getCurrentScope,getCurrentWatcher:()=>getCurrentWatcher,getTransitionRawChildren:()=>getTransitionRawChildren,guardReactiveProps:()=>guardReactiveProps,h:()=>h,handleError:()=>handleError,hasInjectionContext:()=>hasInjectionContext,hydrate:()=>hydrate,hydrateOnIdle:()=>hydrateOnIdle,hydrateOnInteraction:()=>hydrateOnInteraction,hydrateOnMediaQuery:()=>hydrateOnMediaQuery,hydrateOnVisible:()=>hydrateOnVisible,initCustomFormatter:()=>initCustomFormatter,initDirectivesForSSR:()=>initDirectivesForSSR,inject:()=>inject,isMemoSame:()=>isMemoSame,isProxy:()=>isProxy,isReactive:()=>isReactive,isReadonly:()=>isReadonly,isRef:()=>isRef,isRuntimeOnly:()=>isRuntimeOnly,isShallow:()=>isShallow,isVNode:()=>isVNode,markRaw:()=>markRaw,mergeDefaults:()=>mergeDefaults,mergeModels:()=>mergeModels,mergeProps:()=>mergeProps,nextTick:()=>nextTick,normalizeClass:()=>normalizeClass,normalizeProps:()=>normalizeProps,normalizeStyle:()=>normalizeStyle,onActivated:()=>onActivated,onBeforeMount:()=>onBeforeMount,onBeforeUnmount:()=>onBeforeUnmount,onBeforeUpdate:()=>onBeforeUpdate,onDeactivated:()=>onDeactivated,onErrorCaptured:()=>onErrorCaptured,onMounted:()=>onMounted,onRenderTracked:()=>onRenderTracked,onRenderTriggered:()=>onRenderTriggered,onScopeDispose:()=>onScopeDispose,onServerPrefetch:()=>onServerPrefetch,onUnmounted:()=>onUnmounted,onUpdated:()=>onUpdated,onWatcherCleanup:()=>onWatcherCleanup,openBlock:()=>openBlock,popScopeId:()=>popScopeId,provide:()=>provide,proxyRefs:()=>proxyRefs,pushScopeId:()=>pushScopeId,queuePostFlushCb:()=>queuePostFlushCb,reactive:()=>reactive,readonly:()=>readonly,ref:()=>ref,registerRuntimeCompiler:()=>registerRuntimeCompiler,render:()=>render,renderList:()=>renderList,renderSlot:()=>renderSlot,resolveComponent:()=>resolveComponent,resolveDirective:()=>resolveDirective,resolveDynamicComponent:()=>resolveDynamicComponent,resolveFilter:()=>null,resolveTransitionHooks:()=>resolveTransitionHooks,setBlockTracking:()=>setBlockTracking,setDevtoolsHook:()=>setDevtoolsHook,setTransitionHooks:()=>setTransitionHooks,shallowReactive:()=>shallowReactive,shallowReadonly:()=>shallowReadonly,shallowRef:()=>shallowRef,ssrContextKey:()=>ssrContextKey,ssrUtils:()=>ssrUtils,stop:()=>stop,toDisplayString:()=>toDisplayString,toHandlerKey:()=>toHandlerKey,toHandlers:()=>toHandlers,toRaw:()=>toRaw,toRef:()=>toRef,toRefs:()=>toRefs,toValue:()=>toValue$1,transformVNodeArgs:()=>transformVNodeArgs,triggerRef:()=>triggerRef,unref:()=>unref,useAttrs:()=>useAttrs,useCssModule:()=>useCssModule,useCssVars:()=>useCssVars,useHost:()=>useHost,useId:()=>useId,useModel:()=>useModel,useSSRContext:()=>useSSRContext,useShadowRoot:()=>useShadowRoot,useSlots:()=>useSlots,useTemplateRef:()=>useTemplateRef,useTransitionState:()=>useTransitionState,vModelCheckbox:()=>vModelCheckbox,vModelDynamic:()=>vModelDynamic,vModelRadio:()=>vModelRadio,vModelSelect:()=>vModelSelect,vModelText:()=>vModelText,vShow:()=>vShow,version:()=>version$1,warn:()=>warn$2,watch:()=>watch,watchEffect:()=>watchEffect,watchPostEffect:()=>watchPostEffect,watchSyncEffect:()=>watchSyncEffect,withAsyncContext:()=>withAsyncContext,withCtx:()=>withCtx,withDefaults:()=>withDefaults,withDirectives:()=>withDirectives,withKeys:()=>withKeys,withMemo:()=>withMemo,withModifiers:()=>withModifiers,withScopeId:()=>withScopeId}),policy=void 0,tt=typeof window<`u`&&window.trustedTypes;if(tt)try{policy=tt.createPolicy(`vue`,{createHTML:val=>val})}catch{}var unsafeToTrustedHTML=policy?val=>policy.createHTML(val):val=>val,svgNS=`http://www.w3.org/2000/svg`,mathmlNS=`http://www.w3.org/1998/Math/MathML`,doc=typeof document<`u`?document:null,templateContainer=doc&&doc.createElement(`template`),nodeOps={insert:(child,parent,anchor)=>{parent.insertBefore(child,anchor||null)},remove:child=>{let parent=child.parentNode;parent&&parent.removeChild(child)},createElement:(tag,namespace,is,props)=>{let el=namespace===`svg`?doc.createElementNS(svgNS,tag):namespace===`mathml`?doc.createElementNS(mathmlNS,tag):is?doc.createElement(tag,{is}):doc.createElement(tag);return tag===`select`&&props&&props.multiple!=null&&el.setAttribute(`multiple`,props.multiple),el},createText:text=>doc.createTextNode(text),createComment:text=>doc.createComment(text),setText:(node,text)=>{node.nodeValue=text},setElementText:(el,text)=>{el.textContent=text},parentNode:node=>node.parentNode,nextSibling:node=>node.nextSibling,querySelector:selector=>doc.querySelector(selector),setScopeId(el,id){el.setAttribute(id,``)},insertStaticContent(content,parent,anchor,namespace,start,end){let before=anchor?anchor.previousSibling:parent.lastChild;if(start&&(start===end||start.nextSibling))for(;parent.insertBefore(start.cloneNode(!0),anchor),!(start===end||!(start=start.nextSibling)););else{templateContainer.innerHTML=unsafeToTrustedHTML(namespace===`svg`?`${content}`:namespace===`mathml`?`${content}`:content);let template=templateContainer.content;if(namespace===`svg`||namespace===`mathml`){let wrapper=template.firstChild;for(;wrapper.firstChild;)template.appendChild(wrapper.firstChild);template.removeChild(wrapper)}parent.insertBefore(template,anchor)}return[before?before.nextSibling:parent.firstChild,anchor?anchor.previousSibling:parent.lastChild]}},TRANSITION$1=`transition`,ANIMATION=`animation`,vtcKey=Symbol(`_vtc`),DOMTransitionPropsValidators={name:String,type:String,css:{type:Boolean,default:!0},duration:[String,Number,Object],enterFromClass:String,enterActiveClass:String,enterToClass:String,appearFromClass:String,appearActiveClass:String,appearToClass:String,leaveFromClass:String,leaveActiveClass:String,leaveToClass:String},TransitionPropsValidators=extend({},BaseTransitionPropsValidators,DOMTransitionPropsValidators),decorate$1=t=>(t.displayName=`Transition`,t.props=TransitionPropsValidators,t),Transition=decorate$1((props,{slots})=>h(BaseTransition,resolveTransitionProps(props),slots)),callHook=(hook,args=[])=>{isArray$2(hook)?hook.forEach(h2=>h2(...args)):hook&&hook(...args)},hasExplicitCallback=hook=>hook?isArray$2(hook)?hook.some(h2=>h2.length>1):hook.length>1:!1;function resolveTransitionProps(rawProps){let baseProps={};for(let key in rawProps)key in DOMTransitionPropsValidators||(baseProps[key]=rawProps[key]);if(rawProps.css===!1)return baseProps;let{name=`v`,type,duration,enterFromClass=`${name}-enter-from`,enterActiveClass=`${name}-enter-active`,enterToClass=`${name}-enter-to`,appearFromClass=enterFromClass,appearActiveClass=enterActiveClass,appearToClass=enterToClass,leaveFromClass=`${name}-leave-from`,leaveActiveClass=`${name}-leave-active`,leaveToClass=`${name}-leave-to`}=rawProps,durations=normalizeDuration(duration),enterDuration=durations&&durations[0],leaveDuration=durations&&durations[1],{onBeforeEnter,onEnter,onEnterCancelled,onLeave,onLeaveCancelled,onBeforeAppear=onBeforeEnter,onAppear=onEnter,onAppearCancelled=onEnterCancelled}=baseProps,finishEnter=(el,isAppear,done,isCancelled)=>{el._enterCancelled=isCancelled,removeTransitionClass(el,isAppear?appearToClass:enterToClass),removeTransitionClass(el,isAppear?appearActiveClass:enterActiveClass),done&&done()},finishLeave=(el,done)=>{el._isLeaving=!1,removeTransitionClass(el,leaveFromClass),removeTransitionClass(el,leaveToClass),removeTransitionClass(el,leaveActiveClass),done&&done()},makeEnterHook=isAppear=>(el,done)=>{let hook=isAppear?onAppear:onEnter,resolve$1=()=>finishEnter(el,isAppear,done);callHook(hook,[el,resolve$1]),nextFrame(()=>{removeTransitionClass(el,isAppear?appearFromClass:enterFromClass),addTransitionClass(el,isAppear?appearToClass:enterToClass),hasExplicitCallback(hook)||whenTransitionEnds(el,type,enterDuration,resolve$1)})};return extend(baseProps,{onBeforeEnter(el){callHook(onBeforeEnter,[el]),addTransitionClass(el,enterFromClass),addTransitionClass(el,enterActiveClass)},onBeforeAppear(el){callHook(onBeforeAppear,[el]),addTransitionClass(el,appearFromClass),addTransitionClass(el,appearActiveClass)},onEnter:makeEnterHook(!1),onAppear:makeEnterHook(!0),onLeave(el,done){el._isLeaving=!0;let resolve$1=()=>finishLeave(el,done);addTransitionClass(el,leaveFromClass),el._enterCancelled?(addTransitionClass(el,leaveActiveClass),forceReflow(el)):(forceReflow(el),addTransitionClass(el,leaveActiveClass)),nextFrame(()=>{el._isLeaving&&(removeTransitionClass(el,leaveFromClass),addTransitionClass(el,leaveToClass),hasExplicitCallback(onLeave)||whenTransitionEnds(el,type,leaveDuration,resolve$1))}),callHook(onLeave,[el,resolve$1])},onEnterCancelled(el){finishEnter(el,!1,void 0,!0),callHook(onEnterCancelled,[el])},onAppearCancelled(el){finishEnter(el,!0,void 0,!0),callHook(onAppearCancelled,[el])},onLeaveCancelled(el){finishLeave(el),callHook(onLeaveCancelled,[el])}})}function normalizeDuration(duration){if(duration==null)return null;if(isObject$1(duration))return[NumberOf(duration.enter),NumberOf(duration.leave)];{let n=NumberOf(duration);return[n,n]}}function NumberOf(val){return toNumber(val)}function addTransitionClass(el,cls){cls.split(/\s+/).forEach(c=>c&&el.classList.add(c)),(el[vtcKey]||(el[vtcKey]=new Set)).add(cls)}function removeTransitionClass(el,cls){cls.split(/\s+/).forEach(c=>c&&el.classList.remove(c));let _vtc=el[vtcKey];_vtc&&(_vtc.delete(cls),_vtc.size||(el[vtcKey]=void 0))}function nextFrame(cb){requestAnimationFrame(()=>{requestAnimationFrame(cb)})}var endId=0;function whenTransitionEnds(el,expectedType,explicitTimeout,resolve$1){let id=el._endId=++endId,resolveIfNotStale=()=>{id===el._endId&&resolve$1()};if(explicitTimeout!=null)return setTimeout(resolveIfNotStale,explicitTimeout);let{type,timeout,propCount}=getTransitionInfo(el,expectedType);if(!type)return resolve$1();let endEvent=type+`end`,ended=0,end=()=>{el.removeEventListener(endEvent,onEnd),resolveIfNotStale()},onEnd=e=>{e.target===el&&++ended>=propCount&&end()};setTimeout(()=>{ended(styles[key]||``).split(`, `),transitionDelays=getStyleProperties(`${TRANSITION$1}Delay`),transitionDurations=getStyleProperties(`${TRANSITION$1}Duration`),transitionTimeout=getTimeout(transitionDelays,transitionDurations),animationDelays=getStyleProperties(`${ANIMATION}Delay`),animationDurations=getStyleProperties(`${ANIMATION}Duration`),animationTimeout=getTimeout(animationDelays,animationDurations),type=null,timeout=0,propCount=0;expectedType===TRANSITION$1?transitionTimeout>0&&(type=TRANSITION$1,timeout=transitionTimeout,propCount=transitionDurations.length):expectedType===ANIMATION?animationTimeout>0&&(type=ANIMATION,timeout=animationTimeout,propCount=animationDurations.length):(timeout=Math.max(transitionTimeout,animationTimeout),type=timeout>0?transitionTimeout>animationTimeout?TRANSITION$1:ANIMATION:null,propCount=type?type===TRANSITION$1?transitionDurations.length:animationDurations.length:0);let hasTransform=type===TRANSITION$1&&/\b(?:transform|all)(?:,|$)/.test(getStyleProperties(`${TRANSITION$1}Property`).toString());return{type,timeout,propCount,hasTransform}}function getTimeout(delays,durations){for(;delays.lengthtoMs(d)+toMs(delays[i])))}function toMs(s){return s===`auto`?0:Number(s.slice(0,-1).replace(`,`,`.`))*1e3}function forceReflow(el){return(el?el.ownerDocument:document).body.offsetHeight}function patchClass(el,value,isSVG){let transitionClasses=el[vtcKey];transitionClasses&&(value=(value?[value,...transitionClasses]:[...transitionClasses]).join(` `)),value==null?el.removeAttribute(`class`):isSVG?el.setAttribute(`class`,value):el.className=value}var vShowOriginalDisplay=Symbol(`_vod`),vShowHidden=Symbol(`_vsh`),vShow={name:`show`,beforeMount(el,{value},{transition}){el[vShowOriginalDisplay]=el.style.display===`none`?``:el.style.display,transition&&value?transition.beforeEnter(el):setDisplay(el,value)},mounted(el,{value},{transition}){transition&&value&&transition.enter(el)},updated(el,{value,oldValue},{transition}){!value!=!oldValue&&(transition?value?(transition.beforeEnter(el),setDisplay(el,!0),transition.enter(el)):transition.leave(el,()=>{setDisplay(el,!1)}):setDisplay(el,value))},beforeUnmount(el,{value}){setDisplay(el,value)}};function setDisplay(el,value){el.style.display=value?el[vShowOriginalDisplay]:`none`,el[vShowHidden]=!value}function initVShowForSSR(){vShow.getSSRProps=({value})=>{if(!value)return{style:{display:`none`}}}}var CSS_VAR_TEXT=Symbol(``);function useCssVars(getter){let instance$1=getCurrentInstance();if(!instance$1)return;let updateTeleports=instance$1.ut=(vars=getter(instance$1.proxy))=>{Array.from(document.querySelectorAll(`[data-v-owner="${instance$1.uid}"]`)).forEach(node=>setVarsOnNode(node,vars))},setVars=()=>{let vars=getter(instance$1.proxy);instance$1.ce?setVarsOnNode(instance$1.ce,vars):setVarsOnVNode(instance$1.subTree,vars),updateTeleports(vars)};onBeforeUpdate(()=>{queuePostFlushCb(setVars)}),onMounted(()=>{watch(setVars,NOOP,{flush:`post`});let ob=new MutationObserver(setVars);ob.observe(instance$1.subTree.el.parentNode,{childList:!0}),onUnmounted(()=>ob.disconnect())})}function setVarsOnVNode(vnode,vars){if(vnode.shapeFlag&128){let suspense=vnode.suspense;vnode=suspense.activeBranch,suspense.pendingBranch&&!suspense.isHydrating&&suspense.effects.push(()=>{setVarsOnVNode(suspense.activeBranch,vars)})}for(;vnode.component;)vnode=vnode.component.subTree;if(vnode.shapeFlag&1&&vnode.el)setVarsOnNode(vnode.el,vars);else if(vnode.type===Fragment)vnode.children.forEach(c=>setVarsOnVNode(c,vars));else if(vnode.type===Static){let{el,anchor}=vnode;for(;el&&(setVarsOnNode(el,vars),el!==anchor);)el=el.nextSibling}}function setVarsOnNode(el,vars){if(el.nodeType===1){let style=el.style,cssText=``;for(let key in vars){let value=normalizeCssVarValue(vars[key]);style.setProperty(`--${key}`,value),cssText+=`--${key}: ${value};`}style[CSS_VAR_TEXT]=cssText}}var displayRE=/(?:^|;)\s*display\s*:/;function patchStyle(el,prev,next){let style=el.style,isCssString=isString$1(next),hasControlledDisplay=!1;if(next&&!isCssString){if(prev)if(isString$1(prev))for(let prevStyle of prev.split(`;`)){let key=prevStyle.slice(0,prevStyle.indexOf(`:`)).trim();next[key]??setStyle(style,key,``)}else for(let key in prev)next[key]??setStyle(style,key,``);for(let key in next)key===`display`&&(hasControlledDisplay=!0),setStyle(style,key,next[key])}else if(isCssString){if(prev!==next){let cssVarText=style[CSS_VAR_TEXT];cssVarText&&(next+=`;`+cssVarText),style.cssText=next,hasControlledDisplay=displayRE.test(next)}}else prev&&el.removeAttribute(`style`);vShowOriginalDisplay in el&&(el[vShowOriginalDisplay]=hasControlledDisplay?style.display:``,el[vShowHidden]&&(style.display=`none`))}var importantRE=/\s*!important$/;function setStyle(style,name,val){if(isArray$2(val))val.forEach(v=>setStyle(style,name,v));else if(val??=``,name.startsWith(`--`))style.setProperty(name,val);else{let prefixed=autoPrefix(style,name);importantRE.test(val)?style.setProperty(hyphenate(prefixed),val.replace(importantRE,``),`important`):style[prefixed]=val}}var prefixes=[`Webkit`,`Moz`,`ms`],prefixCache={};function autoPrefix(style,rawName){let cached=prefixCache[rawName];if(cached)return cached;let name=camelize(rawName);if(name!==`filter`&&name in style)return prefixCache[rawName]=name;name=capitalize$1(name);for(let i=0;icachedNow||=(p.then(()=>cachedNow=0),Date.now());function createInvoker(initialValue,instance$1){let invoker=e=>{if(!e._vts)e._vts=Date.now();else if(e._vts<=invoker.attached)return;callWithAsyncErrorHandling(patchStopImmediatePropagation(e,invoker.value),instance$1,5,[e])};return invoker.value=initialValue,invoker.attached=getNow(),invoker}function patchStopImmediatePropagation(e,value){if(isArray$2(value)){let originalStop=e.stopImmediatePropagation;return e.stopImmediatePropagation=()=>{originalStop.call(e),e._stopped=!0},value.map(fn=>e2=>!e2._stopped&&fn&&fn(e2))}else return value}var isNativeOn=key=>key.charCodeAt(0)===111&&key.charCodeAt(1)===110&&key.charCodeAt(2)>96&&key.charCodeAt(2)<123,patchProp=(el,key,prevValue,nextValue,namespace,parentComponent)=>{let isSVG=namespace===`svg`;key===`class`?patchClass(el,nextValue,isSVG):key===`style`?patchStyle(el,prevValue,nextValue):isOn(key)?isModelListener(key)||patchEvent(el,key,prevValue,nextValue,parentComponent):(key[0]===`.`?(key=key.slice(1),!0):key[0]===`^`?(key=key.slice(1),!1):shouldSetAsProp(el,key,nextValue,isSVG))?(patchDOMProp(el,key,nextValue),!el.tagName.includes(`-`)&&(key===`value`||key===`checked`||key===`selected`)&&patchAttr(el,key,nextValue,isSVG,parentComponent,key!==`value`)):el._isVueCE&&(/[A-Z]/.test(key)||!isString$1(nextValue))?patchDOMProp(el,camelize(key),nextValue,parentComponent,key):(key===`true-value`?el._trueValue=nextValue:key===`false-value`&&(el._falseValue=nextValue),patchAttr(el,key,nextValue,isSVG))};function shouldSetAsProp(el,key,value,isSVG){if(isSVG)return!!(key===`innerHTML`||key===`textContent`||key in el&&isNativeOn(key)&&isFunction$1(value));if(key===`spellcheck`||key===`draggable`||key===`translate`||key===`autocorrect`||key===`form`||key===`list`&&el.tagName===`INPUT`||key===`type`&&el.tagName===`TEXTAREA`)return!1;if(key===`width`||key===`height`){let tag=el.tagName;if(tag===`IMG`||tag===`VIDEO`||tag===`CANVAS`||tag===`SOURCE`)return!1}return isNativeOn(key)&&isString$1(value)?!1:key in el}var REMOVAL={};function defineCustomElement(options,extraOptions,_createApp){let Comp=defineComponent(options,extraOptions);isPlainObject$2(Comp)&&(Comp=extend({},Comp,extraOptions));class VueCustomElement extends VueElement{constructor(initialProps){super(Comp,initialProps,_createApp)}}return VueCustomElement.def=Comp,VueCustomElement}var defineSSRCustomElement=((options,extraOptions)=>defineCustomElement(options,extraOptions,createSSRApp)),BaseClass=typeof HTMLElement<`u`?HTMLElement:class{},VueElement=class VueElement extends BaseClass{constructor(_def,_props={},_createApp=createApp){super(),this._def=_def,this._props=_props,this._createApp=_createApp,this._isVueCE=!0,this._instance=null,this._app=null,this._nonce=this._def.nonce,this._connected=!1,this._resolved=!1,this._numberProps=null,this._styleChildren=new WeakSet,this._ob=null,this.shadowRoot&&_createApp!==createApp?this._root=this.shadowRoot:_def.shadowRoot===!1?this._root=this:(this.attachShadow(extend({},_def.shadowRootOptions,{mode:`open`})),this._root=this.shadowRoot)}connectedCallback(){if(!this.isConnected)return;!this.shadowRoot&&!this._resolved&&this._parseSlots(),this._connected=!0;let parent=this;for(;parent&&=parent.parentNode||parent.host;)if(parent instanceof VueElement){this._parent=parent;break}this._instance||(this._resolved?this._mount(this._def):parent&&parent._pendingResolve?this._pendingResolve=parent._pendingResolve.then(()=>{this._pendingResolve=void 0,this._resolveDef()}):this._resolveDef())}_setParent(parent=this._parent){parent&&(this._instance.parent=parent._instance,this._inheritParentContext(parent))}_inheritParentContext(parent=this._parent){parent&&this._app&&Object.setPrototypeOf(this._app._context.provides,parent._instance.provides)}disconnectedCallback(){this._connected=!1,nextTick(()=>{this._connected||(this._ob&&=(this._ob.disconnect(),null),this._app&&this._app.unmount(),this._instance&&(this._instance.ce=void 0),this._app=this._instance=null,this._teleportTargets&&=(this._teleportTargets.clear(),void 0))})}_processMutations(mutations){for(let m of mutations)this._setAttr(m.attributeName)}_resolveDef(){if(this._pendingResolve)return;for(let i=0;i{this._resolved=!0,this._pendingResolve=void 0;let{props,styles}=def$1,numberProps;if(props&&!isArray$2(props))for(let key in props){let opt=props[key];(opt===Number||opt&&opt.type===Number)&&(key in this._props&&(this._props[key]=toNumber(this._props[key])),(numberProps||=Object.create(null))[camelize(key)]=!0)}this._numberProps=numberProps,this._resolveProps(def$1),this.shadowRoot&&this._applyStyles(styles),this._mount(def$1)},asyncDef=this._def.__asyncLoader;asyncDef?this._pendingResolve=asyncDef().then(def$1=>{def$1.configureApp=this._def.configureApp,resolve$1(this._def=def$1,!0)}):resolve$1(this._def)}_mount(def$1){this._app=this._createApp(def$1),this._inheritParentContext(),def$1.configureApp&&def$1.configureApp(this._app),this._app._ceVNode=this._createVNode(),this._app.mount(this._root);let exposed=this._instance&&this._instance.exposed;if(exposed)for(let key in exposed)hasOwn$1(this,key)||Object.defineProperty(this,key,{get:()=>unref(exposed[key])})}_resolveProps(def$1){let{props}=def$1,declaredPropKeys=isArray$2(props)?props:Object.keys(props||{});for(let key of Object.keys(this))key[0]!==`_`&&declaredPropKeys.includes(key)&&this._setProp(key,this[key]);for(let key of declaredPropKeys.map(camelize))Object.defineProperty(this,key,{get(){return this._getProp(key)},set(val){this._setProp(key,val,!0,!0)}})}_setAttr(key){if(key.startsWith(`data-v-`))return;let has$1=this.hasAttribute(key),value=has$1?this.getAttribute(key):REMOVAL,camelKey=camelize(key);has$1&&this._numberProps&&this._numberProps[camelKey]&&(value=toNumber(value)),this._setProp(camelKey,value,!1,!0)}_getProp(key){return this._props[key]}_setProp(key,val,shouldReflect=!0,shouldUpdate=!1){if(val!==this._props[key]&&(val===REMOVAL?delete this._props[key]:(this._props[key]=val,key===`key`&&this._app&&(this._app._ceVNode.key=val)),shouldUpdate&&this._instance&&this._update(),shouldReflect)){let ob=this._ob;ob&&(this._processMutations(ob.takeRecords()),ob.disconnect()),val===!0?this.setAttribute(hyphenate(key),``):typeof val==`string`||typeof val==`number`?this.setAttribute(hyphenate(key),val+``):val||this.removeAttribute(hyphenate(key)),ob&&ob.observe(this,{attributes:!0})}}_update(){let vnode=this._createVNode();this._app&&(vnode.appContext=this._app._context),render(vnode,this._root)}_createVNode(){let baseProps={};this.shadowRoot||(baseProps.onVnodeMounted=baseProps.onVnodeUpdated=this._renderSlots.bind(this));let vnode=createVNode(this._def,extend(baseProps,this._props));return this._instance||(vnode.ce=instance$1=>{this._instance=instance$1,instance$1.ce=this,instance$1.isCE=!0;let dispatch=(event,args)=>{this.dispatchEvent(new CustomEvent(event,isPlainObject$2(args[0])?extend({detail:args},args[0]):{detail:args}))};instance$1.emit=(event,...args)=>{dispatch(event,args),hyphenate(event)!==event&&dispatch(hyphenate(event),args)},this._setParent()}),vnode}_applyStyles(styles,owner){if(!styles)return;if(owner){if(owner===this._def||this._styleChildren.has(owner))return;this._styleChildren.add(owner)}let nonce=this._nonce;for(let i=styles.length-1;i>=0;i--){let s=document.createElement(`style`);nonce&&s.setAttribute(`nonce`,nonce),s.textContent=styles[i],this.shadowRoot.prepend(s)}}_parseSlots(){let slots=this._slots={},n;for(;n=this.firstChild;){let slotName=n.nodeType===1&&n.getAttribute(`slot`)||`default`;(slots[slotName]||(slots[slotName]=[])).push(n),this.removeChild(n)}}_renderSlots(){let outlets=this._getSlots(),scopeId=this._instance.type.__scopeId;for(let i=0;i(res.push(...Array.from(i.querySelectorAll(`slot`))),res),[])}_injectChildStyle(comp){this._applyStyles(comp.styles,comp)}_removeChildStyle(comp){}};function useHost(caller){let instance$1=getCurrentInstance();return instance$1&&instance$1.ce||null}function useShadowRoot(){let el=useHost();return el&&el.shadowRoot}function useCssModule(name=`$style`){{let instance$1=getCurrentInstance();if(!instance$1)return EMPTY_OBJ;let modules=instance$1.type.__cssModules;return modules&&modules[name]||EMPTY_OBJ}}var positionMap=new WeakMap,newPositionMap=new WeakMap,moveCbKey=Symbol(`_moveCb`),enterCbKey=Symbol(`_enterCb`),decorate=t=>(delete t.props.mode,t),TransitionGroup=decorate({name:`TransitionGroup`,props:extend({},TransitionPropsValidators,{tag:String,moveClass:String}),setup(props,{slots}){let instance$1=getCurrentInstance(),state=useTransitionState(),prevChildren,children;return onUpdated(()=>{if(!prevChildren.length)return;let moveClass=props.moveClass||`${props.name||`v`}-move`;if(!hasCSSTransform(prevChildren[0].el,instance$1.vnode.el,moveClass)){prevChildren=[];return}prevChildren.forEach(callPendingCbs),prevChildren.forEach(recordPosition);let movedChildren=prevChildren.filter(applyTranslation);forceReflow(instance$1.vnode.el),movedChildren.forEach(c=>{let el=c.el,style=el.style;addTransitionClass(el,moveClass),style.transform=style.webkitTransform=style.transitionDuration=``;let cb=el[moveCbKey]=e=>{e&&e.target!==el||(!e||e.propertyName.endsWith(`transform`))&&(el.removeEventListener(`transitionend`,cb),el[moveCbKey]=null,removeTransitionClass(el,moveClass))};el.addEventListener(`transitionend`,cb)}),prevChildren=[]}),()=>{let rawProps=toRaw(props),cssTransitionProps=resolveTransitionProps(rawProps),tag=rawProps.tag||Fragment;if(prevChildren=[],children)for(let i=0;i{cls.split(/\s+/).forEach(c=>c&&clone.classList.remove(c))}),moveClass.split(/\s+/).forEach(c=>c&&clone.classList.add(c)),clone.style.display=`none`;let container=root.nodeType===1?root:root.parentNode;container.appendChild(clone);let{hasTransform}=getTransitionInfo(clone);return container.removeChild(clone),hasTransform}var getModelAssigner=vnode=>{let fn=vnode.props[`onUpdate:modelValue`]||!1;return isArray$2(fn)?value=>invokeArrayFns(fn,value):fn};function onCompositionStart(e){e.target.composing=!0}function onCompositionEnd(e){let target=e.target;target.composing&&(target.composing=!1,target.dispatchEvent(new Event(`input`)))}var assignKey=Symbol(`_assign`),vModelText={created(el,{modifiers:{lazy,trim,number}},vnode){el[assignKey]=getModelAssigner(vnode);let castToNumber=number||vnode.props&&vnode.props.type===`number`;addEventListener$1(el,lazy?`change`:`input`,e=>{if(e.target.composing)return;let domValue=el.value;trim&&(domValue=domValue.trim()),castToNumber&&(domValue=looseToNumber(domValue)),el[assignKey](domValue)}),trim&&addEventListener$1(el,`change`,()=>{el.value=el.value.trim()}),lazy||(addEventListener$1(el,`compositionstart`,onCompositionStart),addEventListener$1(el,`compositionend`,onCompositionEnd),addEventListener$1(el,`change`,onCompositionEnd))},mounted(el,{value}){el.value=value??``},beforeUpdate(el,{value,oldValue,modifiers:{lazy,trim,number}},vnode){if(el[assignKey]=getModelAssigner(vnode),el.composing)return;let elValue=(number||el.type===`number`)&&!/^0\d/.test(el.value)?looseToNumber(el.value):el.value,newValue=value??``;elValue!==newValue&&(document.activeElement===el&&el.type!==`range`&&(lazy&&value===oldValue||trim&&el.value.trim()===newValue)||(el.value=newValue))}},vModelCheckbox={deep:!0,created(el,_,vnode){el[assignKey]=getModelAssigner(vnode),addEventListener$1(el,`change`,()=>{let modelValue=el._modelValue,elementValue=getValue(el),checked=el.checked,assign$3=el[assignKey];if(isArray$2(modelValue)){let index=looseIndexOf(modelValue,elementValue),found=index!==-1;if(checked&&!found)assign$3(modelValue.concat(elementValue));else if(!checked&&found){let filtered=[...modelValue];filtered.splice(index,1),assign$3(filtered)}}else if(isSet(modelValue)){let cloned=new Set(modelValue);checked?cloned.add(elementValue):cloned.delete(elementValue),assign$3(cloned)}else assign$3(getCheckboxValue(el,checked))})},mounted:setChecked,beforeUpdate(el,binding,vnode){el[assignKey]=getModelAssigner(vnode),setChecked(el,binding,vnode)}};function setChecked(el,{value,oldValue},vnode){el._modelValue=value;let checked;if(isArray$2(value))checked=looseIndexOf(value,vnode.props.value)>-1;else if(isSet(value))checked=value.has(vnode.props.value);else{if(value===oldValue)return;checked=looseEqual(value,getCheckboxValue(el,!0))}el.checked!==checked&&(el.checked=checked)}var vModelRadio={created(el,{value},vnode){el.checked=looseEqual(value,vnode.props.value),el[assignKey]=getModelAssigner(vnode),addEventListener$1(el,`change`,()=>{el[assignKey](getValue(el))})},beforeUpdate(el,{value,oldValue},vnode){el[assignKey]=getModelAssigner(vnode),value!==oldValue&&(el.checked=looseEqual(value,vnode.props.value))}},vModelSelect={deep:!0,created(el,{value,modifiers:{number}},vnode){let isSetModel=isSet(value);addEventListener$1(el,`change`,()=>{let selectedVal=Array.prototype.filter.call(el.options,o=>o.selected).map(o=>number?looseToNumber(getValue(o)):getValue(o));el[assignKey](el.multiple?isSetModel?new Set(selectedVal):selectedVal:selectedVal[0]),el._assigning=!0,nextTick(()=>{el._assigning=!1})}),el[assignKey]=getModelAssigner(vnode)},mounted(el,{value}){setSelected(el,value)},beforeUpdate(el,_binding,vnode){el[assignKey]=getModelAssigner(vnode)},updated(el,{value}){el._assigning||setSelected(el,value)}};function setSelected(el,value){let isMultiple=el.multiple,isArrayValue=isArray$2(value);if(!(isMultiple&&!isArrayValue&&!isSet(value))){for(let i=0,l=el.options.length;iString(v)===String(optionValue)):option.selected=looseIndexOf(value,optionValue)>-1}else option.selected=value.has(optionValue);else if(looseEqual(getValue(option),value)){el.selectedIndex!==i&&(el.selectedIndex=i);return}}!isMultiple&&el.selectedIndex!==-1&&(el.selectedIndex=-1)}}function getValue(el){return`_value`in el?el._value:el.value}function getCheckboxValue(el,checked){let key=checked?`_trueValue`:`_falseValue`;return key in el?el[key]:checked}var vModelDynamic={created(el,binding,vnode){callModelHook(el,binding,vnode,null,`created`)},mounted(el,binding,vnode){callModelHook(el,binding,vnode,null,`mounted`)},beforeUpdate(el,binding,vnode,prevVNode){callModelHook(el,binding,vnode,prevVNode,`beforeUpdate`)},updated(el,binding,vnode,prevVNode){callModelHook(el,binding,vnode,prevVNode,`updated`)}};function resolveDynamicModel(tagName,type){switch(tagName){case`SELECT`:return vModelSelect;case`TEXTAREA`:return vModelText;default:switch(type){case`checkbox`:return vModelCheckbox;case`radio`:return vModelRadio;default:return vModelText}}}function callModelHook(el,binding,vnode,prevVNode,hook){let fn=resolveDynamicModel(el.tagName,vnode.props&&vnode.props.type)[hook];fn&&fn(el,binding,vnode,prevVNode)}function initVModelForSSR(){vModelText.getSSRProps=({value})=>({value}),vModelRadio.getSSRProps=({value},vnode)=>{if(vnode.props&&looseEqual(vnode.props.value,value))return{checked:!0}},vModelCheckbox.getSSRProps=({value},vnode)=>{if(isArray$2(value)){if(vnode.props&&looseIndexOf(value,vnode.props.value)>-1)return{checked:!0}}else if(isSet(value)){if(vnode.props&&value.has(vnode.props.value))return{checked:!0}}else if(value)return{checked:!0}},vModelDynamic.getSSRProps=(binding,vnode)=>{if(typeof vnode.type!=`string`)return;let modelToUse=resolveDynamicModel(vnode.type.toUpperCase(),vnode.props&&vnode.props.type);if(modelToUse.getSSRProps)return modelToUse.getSSRProps(binding,vnode)}}var systemModifiers=[`ctrl`,`shift`,`alt`,`meta`],modifierGuards={stop:e=>e.stopPropagation(),prevent:e=>e.preventDefault(),self:e=>e.target!==e.currentTarget,ctrl:e=>!e.ctrlKey,shift:e=>!e.shiftKey,alt:e=>!e.altKey,meta:e=>!e.metaKey,left:e=>`button`in e&&e.button!==0,middle:e=>`button`in e&&e.button!==1,right:e=>`button`in e&&e.button!==2,exact:(e,modifiers)=>systemModifiers.some(m=>e[`${m}Key`]&&!modifiers.includes(m))},withModifiers=(fn,modifiers)=>{let cache$1=fn._withMods||={},cacheKey=modifiers.join(`.`);return cache$1[cacheKey]||(cache$1[cacheKey]=((event,...args)=>{for(let i=0;i{let cache$1=fn._withKeys||={},cacheKey=modifiers.join(`.`);return cache$1[cacheKey]||(cache$1[cacheKey]=(event=>{if(!(`key`in event))return;let eventKey=hyphenate(event.key);if(modifiers.some(k=>k===eventKey||keyNames[k]===eventKey))return fn(event)}))},rendererOptions=extend({patchProp},nodeOps),renderer,enabledHydration=!1;function ensureRenderer(){return renderer||=createRenderer(rendererOptions)}function ensureHydrationRenderer(){return renderer=enabledHydration?renderer:createHydrationRenderer(rendererOptions),enabledHydration=!0,renderer}var render=((...args)=>{ensureRenderer().render(...args)}),hydrate=((...args)=>{ensureHydrationRenderer().hydrate(...args)}),createApp=((...args)=>{let app$1=ensureRenderer().createApp(...args),{mount}=app$1;return app$1.mount=containerOrSelector=>{let container=normalizeContainer(containerOrSelector);if(!container)return;let component=app$1._component;!isFunction$1(component)&&!component.render&&!component.template&&(component.template=container.innerHTML),container.nodeType===1&&(container.textContent=``);let proxy=mount(container,!1,resolveRootNamespace(container));return container instanceof Element&&(container.removeAttribute(`v-cloak`),container.setAttribute(`data-v-app`,``)),proxy},app$1}),createSSRApp=((...args)=>{let app$1=ensureHydrationRenderer().createApp(...args),{mount}=app$1;return app$1.mount=containerOrSelector=>{let container=normalizeContainer(containerOrSelector);if(container)return mount(container,!0,resolveRootNamespace(container))},app$1});function resolveRootNamespace(container){if(container instanceof SVGElement)return`svg`;if(typeof MathMLElement==`function`&&container instanceof MathMLElement)return`mathml`}function normalizeContainer(container){return isString$1(container)?document.querySelector(container):container}var ssrDirectiveInitialized=!1,initDirectivesForSSR=()=>{ssrDirectiveInitialized||(ssrDirectiveInitialized=!0,initVModelForSSR(),initVShowForSSR())},FRAGMENT=Symbol(``),TELEPORT=Symbol(``),SUSPENSE=Symbol(``),KEEP_ALIVE=Symbol(``),BASE_TRANSITION=Symbol(``),OPEN_BLOCK=Symbol(``),CREATE_BLOCK=Symbol(``),CREATE_ELEMENT_BLOCK=Symbol(``),CREATE_VNODE=Symbol(``),CREATE_ELEMENT_VNODE=Symbol(``),CREATE_COMMENT=Symbol(``),CREATE_TEXT=Symbol(``),CREATE_STATIC=Symbol(``),RESOLVE_COMPONENT=Symbol(``),RESOLVE_DYNAMIC_COMPONENT=Symbol(``),RESOLVE_DIRECTIVE=Symbol(``),RESOLVE_FILTER=Symbol(``),WITH_DIRECTIVES=Symbol(``),RENDER_LIST=Symbol(``),RENDER_SLOT=Symbol(``),CREATE_SLOTS=Symbol(``),TO_DISPLAY_STRING=Symbol(``),MERGE_PROPS=Symbol(``),NORMALIZE_CLASS=Symbol(``),NORMALIZE_STYLE=Symbol(``),NORMALIZE_PROPS=Symbol(``),GUARD_REACTIVE_PROPS=Symbol(``),TO_HANDLERS=Symbol(``),CAMELIZE=Symbol(``),CAPITALIZE=Symbol(``),TO_HANDLER_KEY=Symbol(``),SET_BLOCK_TRACKING=Symbol(``),PUSH_SCOPE_ID=Symbol(``),POP_SCOPE_ID=Symbol(``),WITH_CTX=Symbol(``),UNREF=Symbol(``),IS_REF=Symbol(``),WITH_MEMO=Symbol(``),IS_MEMO_SAME=Symbol(``),helperNameMap={[FRAGMENT]:`Fragment`,[TELEPORT]:`Teleport`,[SUSPENSE]:`Suspense`,[KEEP_ALIVE]:`KeepAlive`,[BASE_TRANSITION]:`BaseTransition`,[OPEN_BLOCK]:`openBlock`,[CREATE_BLOCK]:`createBlock`,[CREATE_ELEMENT_BLOCK]:`createElementBlock`,[CREATE_VNODE]:`createVNode`,[CREATE_ELEMENT_VNODE]:`createElementVNode`,[CREATE_COMMENT]:`createCommentVNode`,[CREATE_TEXT]:`createTextVNode`,[CREATE_STATIC]:`createStaticVNode`,[RESOLVE_COMPONENT]:`resolveComponent`,[RESOLVE_DYNAMIC_COMPONENT]:`resolveDynamicComponent`,[RESOLVE_DIRECTIVE]:`resolveDirective`,[RESOLVE_FILTER]:`resolveFilter`,[WITH_DIRECTIVES]:`withDirectives`,[RENDER_LIST]:`renderList`,[RENDER_SLOT]:`renderSlot`,[CREATE_SLOTS]:`createSlots`,[TO_DISPLAY_STRING]:`toDisplayString`,[MERGE_PROPS]:`mergeProps`,[NORMALIZE_CLASS]:`normalizeClass`,[NORMALIZE_STYLE]:`normalizeStyle`,[NORMALIZE_PROPS]:`normalizeProps`,[GUARD_REACTIVE_PROPS]:`guardReactiveProps`,[TO_HANDLERS]:`toHandlers`,[CAMELIZE]:`camelize`,[CAPITALIZE]:`capitalize`,[TO_HANDLER_KEY]:`toHandlerKey`,[SET_BLOCK_TRACKING]:`setBlockTracking`,[PUSH_SCOPE_ID]:`pushScopeId`,[POP_SCOPE_ID]:`popScopeId`,[WITH_CTX]:`withCtx`,[UNREF]:`unref`,[IS_REF]:`isRef`,[WITH_MEMO]:`withMemo`,[IS_MEMO_SAME]:`isMemoSame`};function registerRuntimeHelpers(helpers){Object.getOwnPropertySymbols(helpers).forEach(s=>{helperNameMap[s]=helpers[s]})}var locStub={start:{line:1,column:1,offset:0},end:{line:1,column:1,offset:0},source:``};function createRoot(children,source=``){return{type:0,source,children,helpers:new Set,components:[],directives:[],hoists:[],imports:[],cached:[],temps:0,codegenNode:void 0,loc:locStub}}function createVNodeCall(context,tag,props,children,patchFlag,dynamicProps,directives,isBlock=!1,disableTracking=!1,isComponent$1=!1,loc=locStub){return context&&(isBlock?(context.helper(OPEN_BLOCK),context.helper(getVNodeBlockHelper(context.inSSR,isComponent$1))):context.helper(getVNodeHelper(context.inSSR,isComponent$1)),directives&&context.helper(WITH_DIRECTIVES)),{type:13,tag,props,children,patchFlag,dynamicProps,directives,isBlock,disableTracking,isComponent:isComponent$1,loc}}function createArrayExpression(elements,loc=locStub){return{type:17,loc,elements}}function createObjectExpression(properties,loc=locStub){return{type:15,loc,properties}}function createObjectProperty(key,value){return{type:16,loc:locStub,key:isString$1(key)?createSimpleExpression(key,!0):key,value}}function createSimpleExpression(content,isStatic=!1,loc=locStub,constType=0){return{type:4,loc,content,isStatic,constType:isStatic?3:constType}}function createCompoundExpression(children,loc=locStub){return{type:8,loc,children}}function createCallExpression(callee,args=[],loc=locStub){return{type:14,loc,callee,arguments:args}}function createFunctionExpression(params,returns=void 0,newline=!1,isSlot=!1,loc=locStub){return{type:18,params,returns,newline,isSlot,loc}}function createConditionalExpression(test,consequent,alternate,newline=!0){return{type:19,test,consequent,alternate,newline,loc:locStub}}function createCacheExpression(index,value,needPauseTracking=!1,inVOnce=!1){return{type:20,index,value,needPauseTracking,inVOnce,needArraySpread:!1,loc:locStub}}function createBlockStatement(body){return{type:21,body,loc:locStub}}function getVNodeHelper(ssr,isComponent$1){return ssr||isComponent$1?CREATE_VNODE:CREATE_ELEMENT_VNODE}function getVNodeBlockHelper(ssr,isComponent$1){return ssr||isComponent$1?CREATE_BLOCK:CREATE_ELEMENT_BLOCK}function convertToBlock(node,{helper,removeHelper,inSSR}){node.isBlock||(node.isBlock=!0,removeHelper(getVNodeHelper(inSSR,node.isComponent)),helper(OPEN_BLOCK),helper(getVNodeBlockHelper(inSSR,node.isComponent)))}var defaultDelimitersOpen=new Uint8Array([123,123]),defaultDelimitersClose=new Uint8Array([125,125]);function isTagStartChar(c){return c>=97&&c<=122||c>=65&&c<=90}function isWhitespace(c){return c===32||c===10||c===9||c===12||c===13}function isEndOfTagSection(c){return c===47||c===62||isWhitespace(c)}function toCharCodes(str){let ret=new Uint8Array(str.length);for(let i=0;i=0;i--){let newlineIndex=this.newlines[i];if(index>newlineIndex){line=i+2,column=index-newlineIndex;break}}return{column,line,offset:index}}peek(){return this.buffer.charCodeAt(this.index+1)}stateText(c){c===60?(this.index>this.sectionStart&&this.cbs.ontext(this.sectionStart,this.index),this.state=5,this.sectionStart=this.index):!this.inVPre&&c===this.delimiterOpen[0]&&(this.state=2,this.delimiterIndex=0,this.stateInterpolationOpen(c))}stateInterpolationOpen(c){if(c===this.delimiterOpen[this.delimiterIndex])if(this.delimiterIndex===this.delimiterOpen.length-1){let start=this.index+1-this.delimiterOpen.length;start>this.sectionStart&&this.cbs.ontext(this.sectionStart,start),this.state=3,this.sectionStart=start}else this.delimiterIndex++;else this.inRCDATA?(this.state=32,this.stateInRCDATA(c)):(this.state=1,this.stateText(c))}stateInterpolation(c){c===this.delimiterClose[0]&&(this.state=4,this.delimiterIndex=0,this.stateInterpolationClose(c))}stateInterpolationClose(c){c===this.delimiterClose[this.delimiterIndex]?this.delimiterIndex===this.delimiterClose.length-1?(this.cbs.oninterpolation(this.sectionStart,this.index+1),this.inRCDATA?this.state=32:this.state=1,this.sectionStart=this.index+1):this.delimiterIndex++:(this.state=3,this.stateInterpolation(c))}stateSpecialStartSequence(c){let isEnd=this.sequenceIndex===this.currentSequence.length;if(!(isEnd?isEndOfTagSection(c):(c|32)===this.currentSequence[this.sequenceIndex]))this.inRCDATA=!1;else if(!isEnd){this.sequenceIndex++;return}this.sequenceIndex=0,this.state=6,this.stateInTagName(c)}stateInRCDATA(c){if(this.sequenceIndex===this.currentSequence.length){if(c===62||isWhitespace(c)){let endOfText=this.index-this.currentSequence.length;if(this.sectionStart=endIndex||(this.state===28?this.currentSequence===Sequences.CdataEnd?this.cbs.oncdata(this.sectionStart,endIndex):this.cbs.oncomment(this.sectionStart,endIndex):this.state===6||this.state===11||this.state===18||this.state===17||this.state===12||this.state===13||this.state===14||this.state===15||this.state===16||this.state===20||this.state===19||this.state===21||this.state===9||this.cbs.ontext(this.sectionStart,endIndex))}emitCodePoint(cp,consumed){}};function getCompatValue(key,{compatConfig}){let value=compatConfig&&compatConfig[key];return key===`MODE`?value||3:value}function isCompatEnabled(key,context){let mode=getCompatValue(`MODE`,context),value=getCompatValue(key,context);return mode===3?value===!0:value!==!1}function checkCompatEnabled(key,context,loc,...args){return isCompatEnabled(key,context)}function defaultOnError$1(error){throw error}function defaultOnWarn(msg){}function createCompilerError(code,loc,messages,additionalMessage){let msg=`https://vuejs.org/error-reference/#compiler-${code}`,error=SyntaxError(String(msg));return error.code=code,error.loc=loc,error}var isStaticExp=p$1=>p$1.type===4&&p$1.isStatic;function isCoreComponent(tag){switch(tag){case`Teleport`:case`teleport`:return TELEPORT;case`Suspense`:case`suspense`:return SUSPENSE;case`KeepAlive`:case`keep-alive`:return KEEP_ALIVE;case`BaseTransition`:case`base-transition`:return BASE_TRANSITION}}var nonIdentifierRE=/^$|^\d|[^\$\w\xA0-\uFFFF]/,isSimpleIdentifier=name=>!nonIdentifierRE.test(name),validFirstIdentCharRE=/[A-Za-z_$\xA0-\uFFFF]/,validIdentCharRE=/[\.\?\w$\xA0-\uFFFF]/,whitespaceRE=/\s+[.[]\s*|\s*[.[]\s+/g,getExpSource=exp=>exp.type===4?exp.content:exp.loc.source,isMemberExpressionBrowser=exp=>{let path=getExpSource(exp).trim().replace(whitespaceRE,s=>s.trim()),state=0,stateStack$1=[],currentOpenBracketCount=0,currentOpenParensCount=0,currentStringType=null;for(let i=0;i|^\s*(?:async\s+)?function(?:\s+[\w$]+)?\s*\(/,isFnExpressionBrowser=exp=>fnExpRE.test(getExpSource(exp)),isFnExpression=isFnExpressionBrowser;function findDir(node,name,allowEmpty=!1){for(let i=0;ip$1.type===7&&p$1.name===`bind`&&(!p$1.arg||p$1.arg.type!==4||!p$1.arg.isStatic))}function isText$1(node){return node.type===5||node.type===2}function isVPre(p$1){return p$1.type===7&&p$1.name===`pre`}function isVSlot(p$1){return p$1.type===7&&p$1.name===`slot`}function isTemplateNode(node){return node.type===1&&node.tagType===3}function isSlotOutlet(node){return node.type===1&&node.tagType===2}var propsHelperSet=new Set([NORMALIZE_PROPS,GUARD_REACTIVE_PROPS]);function getUnnormalizedProps(props,callPath=[]){if(props&&!isString$1(props)&&props.type===14){let callee=props.callee;if(!isString$1(callee)&&propsHelperSet.has(callee))return getUnnormalizedProps(props.arguments[0],callPath.concat(props))}return[props,callPath]}function injectProp(node,prop,context){let propsWithInjection,props=node.type===13?node.props:node.arguments[2],callPath=[],parentCall;if(props&&!isString$1(props)&&props.type===14){let ret=getUnnormalizedProps(props);props=ret[0],callPath=ret[1],parentCall=callPath[callPath.length-1]}if(props==null||isString$1(props))propsWithInjection=createObjectExpression([prop]);else if(props.type===14){let first=props.arguments[0];!isString$1(first)&&first.type===15?hasProp(prop,first)||first.properties.unshift(prop):props.callee===TO_HANDLERS?propsWithInjection=createCallExpression(context.helper(MERGE_PROPS),[createObjectExpression([prop]),props]):props.arguments.unshift(createObjectExpression([prop])),!propsWithInjection&&(propsWithInjection=props)}else props.type===15?(hasProp(prop,props)||props.properties.unshift(prop),propsWithInjection=props):(propsWithInjection=createCallExpression(context.helper(MERGE_PROPS),[createObjectExpression([prop]),props]),parentCall&&parentCall.callee===GUARD_REACTIVE_PROPS&&(parentCall=callPath[callPath.length-2]));node.type===13?parentCall?parentCall.arguments[0]=propsWithInjection:node.props=propsWithInjection:parentCall?parentCall.arguments[0]=propsWithInjection:node.arguments[2]=propsWithInjection}function hasProp(prop,props){let result=!1;if(prop.key.type===4){let propKeyName=prop.key.content;result=props.properties.some(p$1=>p$1.key.type===4&&p$1.key.content===propKeyName)}return result}function toValidAssetId(name,type){return`_${type}_${name.replace(/[^\w]/g,(searchValue,replaceValue)=>searchValue===`-`?`_`:name.charCodeAt(replaceValue).toString())}`}function getMemoedVNodeCall(node){return node.type===14&&node.callee===WITH_MEMO?node.arguments[1].returns:node}var forAliasRE=/([\s\S]*?)\s+(?:in|of)\s+(\S[\s\S]*)/,defaultParserOptions={parseMode:`base`,ns:0,delimiters:[`{{`,`}}`],getNamespace:()=>0,isVoidTag:NO,isPreTag:NO,isIgnoreNewlineTag:NO,isCustomElement:NO,onError:defaultOnError$1,onWarn:defaultOnWarn,comments:!1,prefixIdentifiers:!1},currentOptions=defaultParserOptions,currentRoot=null,currentInput=``,currentOpenTag=null,currentProp=null,currentAttrValue=``,currentAttrStartIndex=-1,currentAttrEndIndex=-1,inPre=0,inVPre=!1,currentVPreBoundary=null,stack=[],tokenizer=new Tokenizer(stack,{onerr:emitError,ontext(start,end){onText(getSlice(start,end),start,end)},ontextentity(char,start,end){onText(char,start,end)},oninterpolation(start,end){if(inVPre)return onText(getSlice(start,end),start,end);let innerStart=start+tokenizer.delimiterOpen.length,innerEnd=end-tokenizer.delimiterClose.length;for(;isWhitespace(currentInput.charCodeAt(innerStart));)innerStart++;for(;isWhitespace(currentInput.charCodeAt(innerEnd-1));)innerEnd--;let exp=getSlice(innerStart,innerEnd);exp.includes(`&`)&&(exp=currentOptions.decodeEntities(exp,!1)),addNode({type:5,content:createExp(exp,!1,getLoc(innerStart,innerEnd)),loc:getLoc(start,end)})},onopentagname(start,end){let name=getSlice(start,end);currentOpenTag={type:1,tag:name,ns:currentOptions.getNamespace(name,stack[0],currentOptions.ns),tagType:0,props:[],children:[],loc:getLoc(start-1,end),codegenNode:void 0}},onopentagend(end){endOpenTag(end)},onclosetag(start,end){let name=getSlice(start,end);if(!currentOptions.isVoidTag(name)){let found=!1;for(let i=0;i0&&emitError(24,stack[0].loc.start.offset);for(let j=0;j<=i;j++)onCloseTag(stack.shift(),end,j(p$1.type===7?p$1.rawName:p$1.name)===name)&&emitError(2,start)},onattribend(quote,end){if(currentOpenTag&¤tProp){if(setLocEnd(currentProp.loc,end),quote!==0)if(currentAttrValue.includes(`&`)&&(currentAttrValue=currentOptions.decodeEntities(currentAttrValue,!0)),currentProp.type===6)currentProp.name===`class`&&(currentAttrValue=condense(currentAttrValue).trim()),quote===1&&!currentAttrValue&&emitError(13,end),currentProp.value={type:2,content:currentAttrValue,loc:quote===1?getLoc(currentAttrStartIndex,currentAttrEndIndex):getLoc(currentAttrStartIndex-1,currentAttrEndIndex+1)},tokenizer.inSFCRoot&¤tOpenTag.tag===`template`&¤tProp.name===`lang`&¤tAttrValue&¤tAttrValue!==`html`&&tokenizer.enterRCDATA(toCharCodes(`mod.content===`sync`))>-1&&checkCompatEnabled(`COMPILER_V_BIND_SYNC`,currentOptions,currentProp.loc,currentProp.arg.loc.source)&&(currentProp.name=`model`,currentProp.modifiers.splice(syncIndex,1))}(currentProp.type!==7||currentProp.name!==`pre`)&¤tOpenTag.props.push(currentProp)}currentAttrValue=``,currentAttrStartIndex=currentAttrEndIndex=-1},oncomment(start,end){currentOptions.comments&&addNode({type:3,content:getSlice(start,end),loc:getLoc(start-4,end+3)})},onend(){let end=currentInput.length;for(let index=0;index{let start=loc.start.offset+offset$2;return createExp(content,!1,getLoc(start,start+content.length),0,asParam?1:0)},result={source:createAliasExpression(RHS.trim(),exp.indexOf(RHS,LHS.length)),value:void 0,key:void 0,index:void 0,finalized:!1},valueContent=LHS.trim().replace(stripParensRE,``).trim(),trimmedOffset=LHS.indexOf(valueContent),iteratorMatch=valueContent.match(forIteratorRE);if(iteratorMatch){valueContent=valueContent.replace(forIteratorRE,``).trim();let keyContent=iteratorMatch[1].trim(),keyOffset;if(keyContent&&(keyOffset=exp.indexOf(keyContent,trimmedOffset+valueContent.length),result.key=createAliasExpression(keyContent,keyOffset,!0)),iteratorMatch[2]){let indexContent=iteratorMatch[2].trim();indexContent&&(result.index=createAliasExpression(indexContent,exp.indexOf(indexContent,result.key?keyOffset+keyContent.length:trimmedOffset+valueContent.length),!0))}}return valueContent&&(result.value=createAliasExpression(valueContent,trimmedOffset,!0)),result}function getSlice(start,end){return currentInput.slice(start,end)}function endOpenTag(end){tokenizer.inSFCRoot&&(currentOpenTag.innerLoc=getLoc(end+1,end+1)),addNode(currentOpenTag);let{tag,ns}=currentOpenTag;ns===0&¤tOptions.isPreTag(tag)&&inPre++,currentOptions.isVoidTag(tag)?onCloseTag(currentOpenTag,end):(stack.unshift(currentOpenTag),(ns===1||ns===2)&&(tokenizer.inXML=!0)),currentOpenTag=null}function onText(content,start,end){{let tag=stack[0]&&stack[0].tag;tag!==`script`&&tag!==`style`&&content.includes(`&`)&&(content=currentOptions.decodeEntities(content,!1))}let parent=stack[0]||currentRoot,lastNode=parent.children[parent.children.length-1];lastNode&&lastNode.type===2?(lastNode.content+=content,setLocEnd(lastNode.loc,end)):parent.children.push({type:2,content,loc:getLoc(start,end)})}function onCloseTag(el,end,isImplied=!1){isImplied?setLocEnd(el.loc,backTrack(end,60)):setLocEnd(el.loc,lookAhead(end,62)+1),tokenizer.inSFCRoot&&(el.children.length?el.innerLoc.end=extend({},el.children[el.children.length-1].loc.end):el.innerLoc.end=extend({},el.innerLoc.start),el.innerLoc.source=getSlice(el.innerLoc.start.offset,el.innerLoc.end.offset));let{tag,ns,children}=el;if(inVPre||(tag===`slot`?el.tagType=2:isFragmentTemplate(el)?el.tagType=3:isComponent(el)&&(el.tagType=1)),tokenizer.inRCDATA||(el.children=condenseWhitespace(children)),ns===0&¤tOptions.isIgnoreNewlineTag(tag)){let first=children[0];first&&first.type===2&&(first.content=first.content.replace(/^\r?\n/,``))}ns===0&¤tOptions.isPreTag(tag)&&inPre--,currentVPreBoundary===el&&(inVPre=tokenizer.inVPre=!1,currentVPreBoundary=null),tokenizer.inXML&&(stack[0]?stack[0].ns:currentOptions.ns)===0&&(tokenizer.inXML=!1);{let props=el.props;if(!tokenizer.inSFCRoot&&isCompatEnabled(`COMPILER_NATIVE_TEMPLATE`,currentOptions)&&el.tag===`template`&&!isFragmentTemplate(el)){let parent=stack[0]||currentRoot,index=parent.children.indexOf(el);parent.children.splice(index,1,...el.children)}let inlineTemplateProp=props.find(p$1=>p$1.type===6&&p$1.name===`inline-template`);inlineTemplateProp&&checkCompatEnabled(`COMPILER_INLINE_TEMPLATE`,currentOptions,inlineTemplateProp.loc)&&el.children.length&&(inlineTemplateProp.value={type:2,content:getSlice(el.children[0].loc.start.offset,el.children[el.children.length-1].loc.end.offset),loc:inlineTemplateProp.loc})}}function lookAhead(index,c){let i=index;for(;currentInput.charCodeAt(i)!==c&&i=0;)i--;return i}var specialTemplateDir=new Set([`if`,`else`,`else-if`,`for`,`slot`]);function isFragmentTemplate({tag,props}){if(tag===`template`){for(let i=0;i64&&c<91}var windowsNewlineRE=/\r\n/g;function condenseWhitespace(nodes){let shouldCondense=currentOptions.whitespace!==`preserve`,removedWhitespace=!1;for(let i=0;ix.type!==3);return children.length===1&&children[0].type===1&&!isSlotOutlet(children[0])?children[0]:null}function walk(node,parent,context,doNotHoistNode=!1,inFor=!1){let{children}=node,toCache=[];for(let i=0;i0){if(constantType>=2){child.codegenNode.patchFlag=-1,toCache.push(child);continue}}else{let codegenNode=child.codegenNode;if(codegenNode.type===13){let flag=codegenNode.patchFlag;if((flag===void 0||flag===512||flag===1)&&getGeneratedPropsConstantType(child,context)>=2){let props=getNodeProps(child);props&&(codegenNode.props=context.hoist(props))}codegenNode.dynamicProps&&=context.hoist(codegenNode.dynamicProps)}}}else if(child.type===12&&(doNotHoistNode?0:getConstantType(child,context))>=2){child.codegenNode.type===14&&child.codegenNode.arguments.length>0&&child.codegenNode.arguments.push(`-1`),toCache.push(child);continue}if(child.type===1){let isComponent$1=child.tagType===1;isComponent$1&&context.scopes.vSlot++,walk(child,node,context,!1,inFor),isComponent$1&&context.scopes.vSlot--}else if(child.type===11)walk(child,node,context,child.children.length===1,!0);else if(child.type===9)for(let i2=0;i2p$1.key===name||p$1.key.content===name);return slot&&slot.value}}toCache.length&&context.transformHoist&&context.transformHoist(children,context,node)}function getConstantType(node,context){let{constantCache}=context;switch(node.type){case 1:if(node.tagType!==0)return 0;let cached=constantCache.get(node);if(cached!==void 0)return cached;let codegenNode=node.codegenNode;if(codegenNode.type!==13||codegenNode.isBlock&&node.tag!==`svg`&&node.tag!==`foreignObject`&&node.tag!==`math`)return 0;if(codegenNode.patchFlag===void 0){let returnType2=3,generatedPropsType=getGeneratedPropsConstantType(node,context);if(generatedPropsType===0)return constantCache.set(node,0),0;generatedPropsType1)for(let i=0;iremovalIndex&&(context.childIndex--,context.onNodeRemoved()),context.parent.children.splice(removalIndex,1)},onNodeRemoved:NOOP,addIdentifiers(exp){},removeIdentifiers(exp){},hoist(exp){isString$1(exp)&&(exp=createSimpleExpression(exp)),context.hoists.push(exp);let identifier=createSimpleExpression(`_hoisted_${context.hoists.length}`,!1,exp.loc,2);return identifier.hoisted=exp,identifier},cache(exp,isVNode$1=!1,inVOnce=!1){let cacheExp=createCacheExpression(context.cached.length,exp,isVNode$1,inVOnce);return context.cached.push(cacheExp),cacheExp}};return context.filters=new Set,context}function transform$1(root,options){let context=createTransformContext(root,options);traverseNode$1(root,context),options.hoistStatic&&cacheStatic(root,context),options.ssr||createRootCodegen(root,context),root.helpers=new Set([...context.helpers.keys()]),root.components=[...context.components],root.directives=[...context.directives],root.imports=context.imports,root.hoists=context.hoists,root.temps=context.temps,root.cached=context.cached,root.transformed=!0,root.filters=[...context.filters]}function createRootCodegen(root,context){let{helper}=context,{children}=root;if(children.length===1){let singleElementRootChild=getSingleElementRoot(root);if(singleElementRootChild&&singleElementRootChild.codegenNode){let codegenNode=singleElementRootChild.codegenNode;codegenNode.type===13&&convertToBlock(codegenNode,context),root.codegenNode=codegenNode}else root.codegenNode=children[0]}else children.length>1&&(root.codegenNode=createVNodeCall(context,helper(FRAGMENT),void 0,root.children,64,void 0,void 0,!0,void 0,!1))}function traverseChildren(parent,context){let i=0,nodeRemoved=()=>{i--};for(;in===name:n=>name.test(n);return(node,context)=>{if(node.type===1){let{props}=node;if(node.tagType===3&&props.some(isVSlot))return;let exitFns=[];for(let i=0;i`${helperNameMap[s]}: _${helperNameMap[s]}`;function createCodegenContext(ast,{mode=`function`,prefixIdentifiers=mode===`module`,sourceMap=!1,filename=`template.vue.html`,scopeId=null,optimizeImports=!1,runtimeGlobalName=`Vue`,runtimeModuleName=`vue`,ssrRuntimeModuleName=`vue/server-renderer`,ssr=!1,isTS=!1,inSSR=!1}){let context={mode,prefixIdentifiers,sourceMap,filename,scopeId,optimizeImports,runtimeGlobalName,runtimeModuleName,ssrRuntimeModuleName,ssr,isTS,inSSR,source:ast.source,code:``,column:1,line:1,offset:0,indentLevel:0,pure:!1,map:void 0,helper(key){return`_${helperNameMap[key]}`},push(code,newlineIndex=-2,node){context.code+=code},indent(){newline(++context.indentLevel)},deindent(withoutNewLine=!1){withoutNewLine?--context.indentLevel:newline(--context.indentLevel)},newline(){newline(context.indentLevel)}};function newline(n){context.push(`
var __create=Object.create,__defProp=Object.defineProperty,__getOwnPropDesc=Object.getOwnPropertyDescriptor,__getOwnPropNames=Object.getOwnPropertyNames,__getProtoOf=Object.getPrototypeOf,__hasOwnProp=Object.prototype.hasOwnProperty,__commonJSMin=(cb,mod)=>()=>(mod||cb((mod={exports:{}}).exports,mod),mod.exports),__export=all=>{let target={};for(var name in all)__defProp(target,name,{get:all[name],enumerable:!0});return target},__copyProps=(to,from,except,desc)=>{if(from&&typeof from==`object`||typeof from==`function`)for(var keys=__getOwnPropNames(from),i=0,n=keys.length,key;ifrom[k]).bind(null,key),enumerable:!(desc=__getOwnPropDesc(from,key))||desc.enumerable});return to},__toESM=(mod,isNodeMode,target)=>(target=mod==null?{}:__create(__getProtoOf(mod)),__copyProps(isNodeMode||!mod||!mod.__esModule?__defProp(target,`default`,{value:mod,enumerable:!0}):target,mod));(function(){let relList=document.createElement(`link`).relList;if(relList&&relList.supports&&relList.supports(`modulepreload`))return;for(let link of document.querySelectorAll(`link[rel="modulepreload"]`))processPreload(link);new MutationObserver(mutations=>{for(let mutation of mutations)if(mutation.type===`childList`)for(let node of mutation.addedNodes)node.tagName===`LINK`&&node.rel===`modulepreload`&&processPreload(node)}).observe(document,{childList:!0,subtree:!0});function getFetchOpts(link){let fetchOpts={};return link.integrity&&(fetchOpts.integrity=link.integrity),link.referrerPolicy&&(fetchOpts.referrerPolicy=link.referrerPolicy),link.crossOrigin===`use-credentials`?fetchOpts.credentials=`include`:link.crossOrigin===`anonymous`?fetchOpts.credentials=`omit`:fetchOpts.credentials=`same-origin`,fetchOpts}function processPreload(link){if(link.ep)return;link.ep=!0;let fetchOpts=getFetchOpts(link);fetch(link.href,fetchOpts)}})();function makeMap(str){let map=Object.create(null);for(let key of str.split(`,`))map[key]=1;return val=>val in map}var EMPTY_OBJ={},EMPTY_ARR=[],NOOP=()=>{},NO=()=>!1,isOn=key=>key.charCodeAt(0)===111&&key.charCodeAt(1)===110&&(key.charCodeAt(2)>122||key.charCodeAt(2)<97),isModelListener=key=>key.startsWith(`onUpdate:`),extend=Object.assign,remove$2=(arr,el)=>{let i=arr.indexOf(el);i>-1&&arr.splice(i,1)},hasOwnProperty$2=Object.prototype.hasOwnProperty,hasOwn$1=(val,key)=>hasOwnProperty$2.call(val,key),isArray$2=Array.isArray,isMap=val=>toTypeString$1(val)===`[object Map]`,isSet=val=>toTypeString$1(val)===`[object Set]`,isDate$1=val=>toTypeString$1(val)===`[object Date]`,isRegExp$1=val=>toTypeString$1(val)===`[object RegExp]`,isFunction$1=val=>typeof val==`function`,isString$1=val=>typeof val==`string`,isSymbol=val=>typeof val==`symbol`,isObject$1=val=>typeof val==`object`&&!!val,isPromise$1=val=>(isObject$1(val)||isFunction$1(val))&&isFunction$1(val.then)&&isFunction$1(val.catch),objectToString$1=Object.prototype.toString,toTypeString$1=value=>objectToString$1.call(value),toRawType=value=>toTypeString$1(value).slice(8,-1),isPlainObject$2=val=>toTypeString$1(val)===`[object Object]`,isIntegerKey=key=>isString$1(key)&&key!==`NaN`&&key[0]!==`-`&&``+parseInt(key,10)===key,isReservedProp=makeMap(`,key,ref,ref_for,ref_key,onVnodeBeforeMount,onVnodeMounted,onVnodeBeforeUpdate,onVnodeUpdated,onVnodeBeforeUnmount,onVnodeUnmounted`),isBuiltInDirective=makeMap(`bind,cloak,else-if,else,for,html,if,model,on,once,pre,show,slot,text,memo`),cacheStringFunction=fn=>{let cache$1=Object.create(null);return(str=>cache$1[str]||(cache$1[str]=fn(str)))},camelizeRE=/-\w/g,camelize=cacheStringFunction(str=>str.replace(camelizeRE,c=>c.slice(1).toUpperCase())),hyphenateRE=/\B([A-Z])/g,hyphenate=cacheStringFunction(str=>str.replace(hyphenateRE,`-$1`).toLowerCase()),capitalize$1=cacheStringFunction(str=>str.charAt(0).toUpperCase()+str.slice(1)),toHandlerKey=cacheStringFunction(str=>str?`on${capitalize$1(str)}`:``),hasChanged=(value,oldValue)=>!Object.is(value,oldValue),invokeArrayFns=(fns,...arg)=>{for(let i=0;i{Object.defineProperty(obj,key,{configurable:!0,enumerable:!1,writable,value})},looseToNumber=val=>{let n=parseFloat(val);return isNaN(n)?val:n},toNumber=val=>{let n=isString$1(val)?Number(val):NaN;return isNaN(n)?val:n},_globalThis$1,getGlobalThis$1=()=>_globalThis$1||=typeof globalThis<`u`?globalThis:typeof self<`u`?self:typeof window<`u`?window:typeof global<`u`?global:{};function genCacheKey(source,options){return source+JSON.stringify(options,(_,val)=>typeof val==`function`?val.toString():val)}var isGloballyAllowed=makeMap(`Infinity,undefined,NaN,isFinite,isNaN,parseFloat,parseInt,decodeURI,decodeURIComponent,encodeURI,encodeURIComponent,Math,Number,Date,Array,Object,Boolean,String,RegExp,Map,Set,JSON,Intl,BigInt,console,Error,Symbol`);function normalizeStyle(value){if(isArray$2(value)){let res={};for(let i=0;i{if(item){let tmp=item.split(propertyDelimiterRE);tmp.length>1&&(ret[tmp[0].trim()]=tmp[1].trim())}}),ret}function normalizeClass(value){let res=``;if(isString$1(value))res=value;else if(isArray$2(value))for(let i=0;ilooseEqual(item,val))}var isRef$2=val=>!!(val&&val.__v_isRef===!0),toDisplayString=val=>isString$1(val)?val:val==null?``:isArray$2(val)||isObject$1(val)&&(val.toString===objectToString$1||!isFunction$1(val.toString))?isRef$2(val)?toDisplayString(val.value):JSON.stringify(val,replacer,2):String(val),replacer=(_key,val)=>isRef$2(val)?replacer(_key,val.value):isMap(val)?{[`Map(${val.size})`]:[...val.entries()].reduce((entries,[key,val2],i)=>(entries[stringifySymbol(key,i)+` =>`]=val2,entries),{})}:isSet(val)?{[`Set(${val.size})`]:[...val.values()].map(v=>stringifySymbol(v))}:isSymbol(val)?stringifySymbol(val):isObject$1(val)&&!isArray$2(val)&&!isPlainObject$2(val)?String(val):val,stringifySymbol=(v,i=``)=>{var _a;return isSymbol(v)?`Symbol(${v.description??i})`:v};function normalizeCssVarValue(value){return value==null?`initial`:typeof value==`string`?value===``?` `:value:String(value)}var activeEffectScope,EffectScope=class{constructor(detached=!1){this.detached=detached,this._active=!0,this._on=0,this.effects=[],this.cleanups=[],this._isPaused=!1,this.parent=activeEffectScope,!detached&&activeEffectScope&&(this.index=(activeEffectScope.scopes||=[]).push(this)-1)}get active(){return this._active}pause(){if(this._active){this._isPaused=!0;let i,l;if(this.scopes)for(i=0,l=this.scopes.length;i0&&--this._on===0&&(activeEffectScope=this.prevScope,this.prevScope=void 0)}stop(fromParent){if(this._active){this._active=!1;let i,l;for(i=0,l=this.effects.length;i0)return;if(batchedComputed){let e=batchedComputed;for(batchedComputed=void 0;e;){let next=e.next;e.next=void 0,e.flags&=-9,e=next}}let error;for(;batchedSub;){let e=batchedSub;for(batchedSub=void 0;e;){let next=e.next;if(e.next=void 0,e.flags&=-9,e.flags&1)try{e.trigger()}catch(err){error||=err}e=next}}if(error)throw error}function prepareDeps(sub){for(let link=sub.deps;link;link=link.nextDep)link.version=-1,link.prevActiveLink=link.dep.activeLink,link.dep.activeLink=link}function cleanupDeps(sub){let head,tail=sub.depsTail,link=tail;for(;link;){let prev=link.prevDep;link.version===-1?(link===tail&&(tail=prev),removeSub(link),removeDep(link)):head=link,link.dep.activeLink=link.prevActiveLink,link.prevActiveLink=void 0,link=prev}sub.deps=head,sub.depsTail=tail}function isDirty(sub){for(let link=sub.deps;link;link=link.nextDep)if(link.dep.version!==link.version||link.dep.computed&&(refreshComputed(link.dep.computed)||link.dep.version!==link.version))return!0;return!!sub._dirty}function refreshComputed(computed$2){if(computed$2.flags&4&&!(computed$2.flags&16)||(computed$2.flags&=-17,computed$2.globalVersion===globalVersion)||(computed$2.globalVersion=globalVersion,!computed$2.isSSR&&computed$2.flags&128&&(!computed$2.deps&&!computed$2._dirty||!isDirty(computed$2))))return;computed$2.flags|=2;let dep=computed$2.dep,prevSub=activeSub,prevShouldTrack=shouldTrack;activeSub=computed$2,shouldTrack=!0;try{prepareDeps(computed$2);let value=computed$2.fn(computed$2._value);(dep.version===0||hasChanged(value,computed$2._value))&&(computed$2.flags|=128,computed$2._value=value,dep.version++)}catch(err){throw dep.version++,err}finally{activeSub=prevSub,shouldTrack=prevShouldTrack,cleanupDeps(computed$2),computed$2.flags&=-3}}function removeSub(link,soft=!1){let{dep,prevSub,nextSub}=link;if(prevSub&&(prevSub.nextSub=nextSub,link.prevSub=void 0),nextSub&&(nextSub.prevSub=prevSub,link.nextSub=void 0),dep.subs===link&&(dep.subs=prevSub,!prevSub&&dep.computed)){dep.computed.flags&=-5;for(let l=dep.computed.deps;l;l=l.nextDep)removeSub(l,!0)}!soft&&!--dep.sc&&dep.map&&dep.map.delete(dep.key)}function removeDep(link){let{prevDep,nextDep}=link;prevDep&&(prevDep.nextDep=nextDep,link.prevDep=void 0),nextDep&&(nextDep.prevDep=prevDep,link.nextDep=void 0)}function effect(fn,options){fn.effect instanceof ReactiveEffect&&(fn=fn.effect.fn);let e=new ReactiveEffect(fn);options&&extend(e,options);try{e.run()}catch(err){throw e.stop(),err}let runner=e.run.bind(e);return runner.effect=e,runner}function stop(runner){runner.effect.stop()}var shouldTrack=!0,trackStack=[];function pauseTracking(){trackStack.push(shouldTrack),shouldTrack=!1}function resetTracking(){let last=trackStack.pop();shouldTrack=last===void 0?!0:last}function cleanupEffect(e){let{cleanup}=e;if(e.cleanup=void 0,cleanup){let prevSub=activeSub;activeSub=void 0;try{cleanup()}finally{activeSub=prevSub}}}var globalVersion=0,Link=class{constructor(sub,dep){this.sub=sub,this.dep=dep,this.version=dep.version,this.nextDep=this.prevDep=this.nextSub=this.prevSub=this.prevActiveLink=void 0}},Dep=class{constructor(computed$2){this.computed=computed$2,this.version=0,this.activeLink=void 0,this.subs=void 0,this.map=void 0,this.key=void 0,this.sc=0,this.__v_skip=!0}track(debugInfo){if(!activeSub||!shouldTrack||activeSub===this.computed)return;let link=this.activeLink;if(link===void 0||link.sub!==activeSub)link=this.activeLink=new Link(activeSub,this),activeSub.deps?(link.prevDep=activeSub.depsTail,activeSub.depsTail.nextDep=link,activeSub.depsTail=link):activeSub.deps=activeSub.depsTail=link,addSub(link);else if(link.version===-1&&(link.version=this.version,link.nextDep)){let next=link.nextDep;next.prevDep=link.prevDep,link.prevDep&&(link.prevDep.nextDep=next),link.prevDep=activeSub.depsTail,link.nextDep=void 0,activeSub.depsTail.nextDep=link,activeSub.depsTail=link,activeSub.deps===link&&(activeSub.deps=next)}return link}trigger(debugInfo){this.version++,globalVersion++,this.notify(debugInfo)}notify(debugInfo){startBatch();try{for(let link=this.subs;link;link=link.prevSub)link.sub.notify()&&link.sub.dep.notify()}finally{endBatch()}}};function addSub(link){if(link.dep.sc++,link.sub.flags&4){let computed$2=link.dep.computed;if(computed$2&&!link.dep.subs){computed$2.flags|=20;for(let l=computed$2.deps;l;l=l.nextDep)addSub(l)}let currentTail=link.dep.subs;currentTail!==link&&(link.prevSub=currentTail,currentTail&&(currentTail.nextSub=link)),link.dep.subs=link}}var targetMap=new WeakMap,ITERATE_KEY=Symbol(``),MAP_KEY_ITERATE_KEY=Symbol(``),ARRAY_ITERATE_KEY=Symbol(``);function track(target,type,key){if(shouldTrack&&activeSub){let depsMap=targetMap.get(target);depsMap||targetMap.set(target,depsMap=new Map);let dep=depsMap.get(key);dep||(depsMap.set(key,dep=new Dep),dep.map=depsMap,dep.key=key),dep.track()}}function trigger$1(target,type,key,newValue,oldValue,oldTarget){let depsMap=targetMap.get(target);if(!depsMap){globalVersion++;return}let run$1=dep=>{dep&&dep.trigger()};if(startBatch(),type===`clear`)depsMap.forEach(run$1);else{let targetIsArray=isArray$2(target),isArrayIndex=targetIsArray&&isIntegerKey(key);if(targetIsArray&&key===`length`){let newLength=Number(newValue);depsMap.forEach((dep,key2)=>{(key2===`length`||key2===ARRAY_ITERATE_KEY||!isSymbol(key2)&&key2>=newLength)&&run$1(dep)})}else switch((key!==void 0||depsMap.has(void 0))&&run$1(depsMap.get(key)),isArrayIndex&&run$1(depsMap.get(ARRAY_ITERATE_KEY)),type){case`add`:targetIsArray?isArrayIndex&&run$1(depsMap.get(`length`)):(run$1(depsMap.get(ITERATE_KEY)),isMap(target)&&run$1(depsMap.get(MAP_KEY_ITERATE_KEY)));break;case`delete`:targetIsArray||(run$1(depsMap.get(ITERATE_KEY)),isMap(target)&&run$1(depsMap.get(MAP_KEY_ITERATE_KEY)));break;case`set`:isMap(target)&&run$1(depsMap.get(ITERATE_KEY));break}}endBatch()}function getDepFromReactive(object,key){let depMap=targetMap.get(object);return depMap&&depMap.get(key)}function reactiveReadArray(array){let raw=toRaw(array);return raw===array?raw:(track(raw,`iterate`,ARRAY_ITERATE_KEY),isShallow(array)?raw:raw.map(toReactive))}function shallowReadArray(arr){return track(arr=toRaw(arr),`iterate`,ARRAY_ITERATE_KEY),arr}var arrayInstrumentations={__proto__:null,[Symbol.iterator](){return iterator(this,Symbol.iterator,toReactive)},concat(...args){return reactiveReadArray(this).concat(...args.map(x=>isArray$2(x)?reactiveReadArray(x):x))},entries(){return iterator(this,`entries`,value=>(value[1]=toReactive(value[1]),value))},every(fn,thisArg){return apply(this,`every`,fn,thisArg,void 0,arguments)},filter(fn,thisArg){return apply(this,`filter`,fn,thisArg,v=>v.map(toReactive),arguments)},find(fn,thisArg){return apply(this,`find`,fn,thisArg,toReactive,arguments)},findIndex(fn,thisArg){return apply(this,`findIndex`,fn,thisArg,void 0,arguments)},findLast(fn,thisArg){return apply(this,`findLast`,fn,thisArg,toReactive,arguments)},findLastIndex(fn,thisArg){return apply(this,`findLastIndex`,fn,thisArg,void 0,arguments)},forEach(fn,thisArg){return apply(this,`forEach`,fn,thisArg,void 0,arguments)},includes(...args){return searchProxy(this,`includes`,args)},indexOf(...args){return searchProxy(this,`indexOf`,args)},join(separator){return reactiveReadArray(this).join(separator)},lastIndexOf(...args){return searchProxy(this,`lastIndexOf`,args)},map(fn,thisArg){return apply(this,`map`,fn,thisArg,void 0,arguments)},pop(){return noTracking(this,`pop`)},push(...args){return noTracking(this,`push`,args)},reduce(fn,...args){return reduce(this,`reduce`,fn,args)},reduceRight(fn,...args){return reduce(this,`reduceRight`,fn,args)},shift(){return noTracking(this,`shift`)},some(fn,thisArg){return apply(this,`some`,fn,thisArg,void 0,arguments)},splice(...args){return noTracking(this,`splice`,args)},toReversed(){return reactiveReadArray(this).toReversed()},toSorted(comparer){return reactiveReadArray(this).toSorted(comparer)},toSpliced(...args){return reactiveReadArray(this).toSpliced(...args)},unshift(...args){return noTracking(this,`unshift`,args)},values(){return iterator(this,`values`,toReactive)}};function iterator(self$1,method,wrapValue){let arr=shallowReadArray(self$1),iter=arr[method]();return arr!==self$1&&!isShallow(self$1)&&(iter._next=iter.next,iter.next=()=>{let result=iter._next();return result.done||(result.value=wrapValue(result.value)),result}),iter}var arrayProto=Array.prototype;function apply(self$1,method,fn,thisArg,wrappedRetFn,args){let arr=shallowReadArray(self$1),needsWrap=arr!==self$1&&!isShallow(self$1),methodFn=arr[method];if(methodFn!==arrayProto[method]){let result2=methodFn.apply(self$1,args);return needsWrap?toReactive(result2):result2}let wrappedFn=fn;arr!==self$1&&(needsWrap?wrappedFn=function(item,index){return fn.call(this,toReactive(item),index,self$1)}:fn.length>2&&(wrappedFn=function(item,index){return fn.call(this,item,index,self$1)}));let result=methodFn.call(arr,wrappedFn,thisArg);return needsWrap&&wrappedRetFn?wrappedRetFn(result):result}function reduce(self$1,method,fn,args){let arr=shallowReadArray(self$1),wrappedFn=fn;return arr!==self$1&&(isShallow(self$1)?fn.length>3&&(wrappedFn=function(acc,item,index){return fn.call(this,acc,item,index,self$1)}):wrappedFn=function(acc,item,index){return fn.call(this,acc,toReactive(item),index,self$1)}),arr[method](wrappedFn,...args)}function searchProxy(self$1,method,args){let arr=toRaw(self$1);track(arr,`iterate`,ARRAY_ITERATE_KEY);let res=arr[method](...args);return(res===-1||res===!1)&&isProxy(args[0])?(args[0]=toRaw(args[0]),arr[method](...args)):res}function noTracking(self$1,method,args=[]){pauseTracking(),startBatch();let res=toRaw(self$1)[method].apply(self$1,args);return endBatch(),resetTracking(),res}var isNonTrackableKeys=makeMap(`__proto__,__v_isRef,__isVue`),builtInSymbols=new Set(Object.getOwnPropertyNames(Symbol).filter(key=>key!==`arguments`&&key!==`caller`).map(key=>Symbol[key]).filter(isSymbol));function hasOwnProperty$1(key){isSymbol(key)||(key=String(key));let obj=toRaw(this);return track(obj,`has`,key),obj.hasOwnProperty(key)}var BaseReactiveHandler=class{constructor(_isReadonly=!1,_isShallow=!1){this._isReadonly=_isReadonly,this._isShallow=_isShallow}get(target,key,receiver){if(key===`__v_skip`)return target.__v_skip;let isReadonly2=this._isReadonly,isShallow2=this._isShallow;if(key===`__v_isReactive`)return!isReadonly2;if(key===`__v_isReadonly`)return isReadonly2;if(key===`__v_isShallow`)return isShallow2;if(key===`__v_raw`)return receiver===(isReadonly2?isShallow2?shallowReadonlyMap:readonlyMap:isShallow2?shallowReactiveMap:reactiveMap).get(target)||Object.getPrototypeOf(target)===Object.getPrototypeOf(receiver)?target:void 0;let targetIsArray=isArray$2(target);if(!isReadonly2){let fn;if(targetIsArray&&(fn=arrayInstrumentations[key]))return fn;if(key===`hasOwnProperty`)return hasOwnProperty$1}let res=Reflect.get(target,key,isRef(target)?target:receiver);if((isSymbol(key)?builtInSymbols.has(key):isNonTrackableKeys(key))||(isReadonly2||track(target,`get`,key),isShallow2))return res;if(isRef(res)){let value=targetIsArray&&isIntegerKey(key)?res:res.value;return isReadonly2&&isObject$1(value)?readonly(value):value}return isObject$1(res)?isReadonly2?readonly(res):reactive(res):res}},MutableReactiveHandler=class extends BaseReactiveHandler{constructor(isShallow2=!1){super(!1,isShallow2)}set(target,key,value,receiver){let oldValue=target[key];if(!this._isShallow){let isOldValueReadonly=isReadonly(oldValue);if(!isShallow(value)&&!isReadonly(value)&&(oldValue=toRaw(oldValue),value=toRaw(value)),!isArray$2(target)&&isRef(oldValue)&&!isRef(value))return isOldValueReadonly||(oldValue.value=value),!0}let hadKey=isArray$2(target)&&isIntegerKey(key)?Number(key)value,getProto=v=>Reflect.getPrototypeOf(v);function createIterableMethod(method,isReadonly2,isShallow2){return function(...args){let target=this.__v_raw,rawTarget=toRaw(target),targetIsMap=isMap(rawTarget),isPair=method===`entries`||method===Symbol.iterator&&targetIsMap,isKeyOnly=method===`keys`&&targetIsMap,innerIterator=target[method](...args),wrap=isShallow2?toShallow:isReadonly2?toReadonly:toReactive;return!isReadonly2&&track(rawTarget,`iterate`,isKeyOnly?MAP_KEY_ITERATE_KEY:ITERATE_KEY),{next(){let{value,done}=innerIterator.next();return done?{value,done}:{value:isPair?[wrap(value[0]),wrap(value[1])]:wrap(value),done}},[Symbol.iterator](){return this}}}}function createReadonlyMethod(type){return function(...args){return type===`delete`?!1:type===`clear`?void 0:this}}function createInstrumentations(readonly$1,shallow){let instrumentations={get(key){let target=this.__v_raw,rawTarget=toRaw(target),rawKey=toRaw(key);readonly$1||(hasChanged(key,rawKey)&&track(rawTarget,`get`,key),track(rawTarget,`get`,rawKey));let{has:has$1}=getProto(rawTarget),wrap=shallow?toShallow:readonly$1?toReadonly:toReactive;if(has$1.call(rawTarget,key))return wrap(target.get(key));if(has$1.call(rawTarget,rawKey))return wrap(target.get(rawKey));target!==rawTarget&&target.get(key)},get size(){let target=this.__v_raw;return!readonly$1&&track(toRaw(target),`iterate`,ITERATE_KEY),target.size},has(key){let target=this.__v_raw,rawTarget=toRaw(target),rawKey=toRaw(key);return readonly$1||(hasChanged(key,rawKey)&&track(rawTarget,`has`,key),track(rawTarget,`has`,rawKey)),key===rawKey?target.has(key):target.has(key)||target.has(rawKey)},forEach(callback,thisArg){let observed$2=this,target=observed$2.__v_raw,rawTarget=toRaw(target),wrap=shallow?toShallow:readonly$1?toReadonly:toReactive;return!readonly$1&&track(rawTarget,`iterate`,ITERATE_KEY),target.forEach((value,key)=>callback.call(thisArg,wrap(value),wrap(key),observed$2))}};return extend(instrumentations,readonly$1?{add:createReadonlyMethod(`add`),set:createReadonlyMethod(`set`),delete:createReadonlyMethod(`delete`),clear:createReadonlyMethod(`clear`)}:{add(value){!shallow&&!isShallow(value)&&!isReadonly(value)&&(value=toRaw(value));let target=toRaw(this);return getProto(target).has.call(target,value)||(target.add(value),trigger$1(target,`add`,value,value)),this},set(key,value){!shallow&&!isShallow(value)&&!isReadonly(value)&&(value=toRaw(value));let target=toRaw(this),{has:has$1,get}=getProto(target),hadKey=has$1.call(target,key);hadKey||=(key=toRaw(key),has$1.call(target,key));let oldValue=get.call(target,key);return target.set(key,value),hadKey?hasChanged(value,oldValue)&&trigger$1(target,`set`,key,value,oldValue):trigger$1(target,`add`,key,value),this},delete(key){let target=toRaw(this),{has:has$1,get}=getProto(target),hadKey=has$1.call(target,key);hadKey||=(key=toRaw(key),has$1.call(target,key));let oldValue=get?get.call(target,key):void 0,result=target.delete(key);return hadKey&&trigger$1(target,`delete`,key,void 0,oldValue),result},clear(){let target=toRaw(this),hadItems=target.size!==0,oldTarget,result=target.clear();return hadItems&&trigger$1(target,`clear`,void 0,void 0,void 0),result}}),[`keys`,`values`,`entries`,Symbol.iterator].forEach(method=>{instrumentations[method]=createIterableMethod(method,readonly$1,shallow)}),instrumentations}function createInstrumentationGetter(isReadonly2,shallow){let instrumentations=createInstrumentations(isReadonly2,shallow);return(target,key,receiver)=>key===`__v_isReactive`?!isReadonly2:key===`__v_isReadonly`?isReadonly2:key===`__v_raw`?target:Reflect.get(hasOwn$1(instrumentations,key)&&key in target?instrumentations:target,key,receiver)}var mutableCollectionHandlers={get:createInstrumentationGetter(!1,!1)},shallowCollectionHandlers={get:createInstrumentationGetter(!1,!0)},readonlyCollectionHandlers={get:createInstrumentationGetter(!0,!1)},shallowReadonlyCollectionHandlers={get:createInstrumentationGetter(!0,!0)},reactiveMap=new WeakMap,shallowReactiveMap=new WeakMap,readonlyMap=new WeakMap,shallowReadonlyMap=new WeakMap;function targetTypeMap(rawType){switch(rawType){case`Object`:case`Array`:return 1;case`Map`:case`Set`:case`WeakMap`:case`WeakSet`:return 2;default:return 0}}function getTargetType(value){return value.__v_skip||!Object.isExtensible(value)?0:targetTypeMap(toRawType(value))}function reactive(target){return isReadonly(target)?target:createReactiveObject(target,!1,mutableHandlers,mutableCollectionHandlers,reactiveMap)}function shallowReactive(target){return createReactiveObject(target,!1,shallowReactiveHandlers,shallowCollectionHandlers,shallowReactiveMap)}function readonly(target){return createReactiveObject(target,!0,readonlyHandlers,readonlyCollectionHandlers,readonlyMap)}function shallowReadonly(target){return createReactiveObject(target,!0,shallowReadonlyHandlers,shallowReadonlyCollectionHandlers,shallowReadonlyMap)}function createReactiveObject(target,isReadonly2,baseHandlers,collectionHandlers,proxyMap){if(!isObject$1(target)||target.__v_raw&&!(isReadonly2&&target.__v_isReactive))return target;let targetType=getTargetType(target);if(targetType===0)return target;let existingProxy=proxyMap.get(target);if(existingProxy)return existingProxy;let proxy=new Proxy(target,targetType===2?collectionHandlers:baseHandlers);return proxyMap.set(target,proxy),proxy}function isReactive(value){return isReadonly(value)?isReactive(value.__v_raw):!!(value&&value.__v_isReactive)}function isReadonly(value){return!!(value&&value.__v_isReadonly)}function isShallow(value){return!!(value&&value.__v_isShallow)}function isProxy(value){return value?!!value.__v_raw:!1}function toRaw(observed$2){let raw=observed$2&&observed$2.__v_raw;return raw?toRaw(raw):observed$2}function markRaw(value){return!hasOwn$1(value,`__v_skip`)&&Object.isExtensible(value)&&def(value,`__v_skip`,!0),value}var toReactive=value=>isObject$1(value)?reactive(value):value,toReadonly=value=>isObject$1(value)?readonly(value):value;function isRef(r){return r?r.__v_isRef===!0:!1}function ref(value){return createRef(value,!1)}function shallowRef(value){return createRef(value,!0)}function createRef(rawValue,shallow){return isRef(rawValue)?rawValue:new RefImpl(rawValue,shallow)}var RefImpl=class{constructor(value,isShallow2){this.dep=new Dep,this.__v_isRef=!0,this.__v_isShallow=!1,this._rawValue=isShallow2?value:toRaw(value),this._value=isShallow2?value:toReactive(value),this.__v_isShallow=isShallow2}get value(){return this.dep.track(),this._value}set value(newValue){let oldValue=this._rawValue,useDirectValue=this.__v_isShallow||isShallow(newValue)||isReadonly(newValue);newValue=useDirectValue?newValue:toRaw(newValue),hasChanged(newValue,oldValue)&&(this._rawValue=newValue,this._value=useDirectValue?newValue:toReactive(newValue),this.dep.trigger())}};function triggerRef(ref2){ref2.dep&&ref2.dep.trigger()}function unref(ref2){return isRef(ref2)?ref2.value:ref2}function toValue$1(source){return isFunction$1(source)?source():unref(source)}var shallowUnwrapHandlers={get:(target,key,receiver)=>key===`__v_raw`?target:unref(Reflect.get(target,key,receiver)),set:(target,key,value,receiver)=>{let oldValue=target[key];return isRef(oldValue)&&!isRef(value)?(oldValue.value=value,!0):Reflect.set(target,key,value,receiver)}};function proxyRefs(objectWithRefs){return isReactive(objectWithRefs)?objectWithRefs:new Proxy(objectWithRefs,shallowUnwrapHandlers)}var CustomRefImpl=class{constructor(factory){this.__v_isRef=!0,this._value=void 0;let dep=this.dep=new Dep,{get,set}=factory(dep.track.bind(dep),dep.trigger.bind(dep));this._get=get,this._set=set}get value(){return this._value=this._get()}set value(newVal){this._set(newVal)}};function customRef(factory){return new CustomRefImpl(factory)}function toRefs(object){let ret=isArray$2(object)?Array(object.length):{};for(let key in object)ret[key]=propertyToRef(object,key);return ret}var ObjectRefImpl=class{constructor(_object,_key,_defaultValue){this._object=_object,this._key=_key,this._defaultValue=_defaultValue,this.__v_isRef=!0,this._value=void 0}get value(){let val=this._object[this._key];return this._value=val===void 0?this._defaultValue:val}set value(newVal){this._object[this._key]=newVal}get dep(){return getDepFromReactive(toRaw(this._object),this._key)}},GetterRefImpl=class{constructor(_getter){this._getter=_getter,this.__v_isRef=!0,this.__v_isReadonly=!0,this._value=void 0}get value(){return this._value=this._getter()}};function toRef(source,key,defaultValue){return isRef(source)?source:isFunction$1(source)?new GetterRefImpl(source):isObject$1(source)&&arguments.length>1?propertyToRef(source,key,defaultValue):ref(source)}function propertyToRef(source,key,defaultValue){let val=source[key];return isRef(val)?val:new ObjectRefImpl(source,key,defaultValue)}var ComputedRefImpl=class{constructor(fn,setter,isSSR){this.fn=fn,this.setter=setter,this._value=void 0,this.dep=new Dep(this),this.__v_isRef=!0,this.deps=void 0,this.depsTail=void 0,this.flags=16,this.globalVersion=globalVersion-1,this.next=void 0,this.effect=this,this.__v_isReadonly=!setter,this.isSSR=isSSR}notify(){if(this.flags|=16,!(this.flags&8)&&activeSub!==this)return batch(this,!0),!0}get value(){let link=this.dep.track();return refreshComputed(this),link&&(link.version=this.dep.version),this._value}set value(newValue){this.setter&&this.setter(newValue)}};function computed$1(getterOrOptions,debugOptions,isSSR=!1){let getter,setter;return isFunction$1(getterOrOptions)?getter=getterOrOptions:(getter=getterOrOptions.get,setter=getterOrOptions.set),new ComputedRefImpl(getter,setter,isSSR)}var TrackOpTypes={GET:`get`,HAS:`has`,ITERATE:`iterate`},TriggerOpTypes={SET:`set`,ADD:`add`,DELETE:`delete`,CLEAR:`clear`},INITIAL_WATCHER_VALUE={},cleanupMap=new WeakMap,activeWatcher=void 0;function getCurrentWatcher(){return activeWatcher}function onWatcherCleanup(cleanupFn,failSilently=!1,owner=activeWatcher){if(owner){let cleanups=cleanupMap.get(owner);cleanups||cleanupMap.set(owner,cleanups=[]),cleanups.push(cleanupFn)}}function watch$1(source,cb,options=EMPTY_OBJ){let{immediate,deep,once,scheduler,augmentJob,call}=options,reactiveGetter=source2=>deep?source2:isShallow(source2)||deep===!1||deep===0?traverse(source2,1):traverse(source2),effect$1,getter,cleanup,boundCleanup,forceTrigger=!1,isMultiSource=!1;if(isRef(source)?(getter=()=>source.value,forceTrigger=isShallow(source)):isReactive(source)?(getter=()=>reactiveGetter(source),forceTrigger=!0):isArray$2(source)?(isMultiSource=!0,forceTrigger=source.some(s=>isReactive(s)||isShallow(s)),getter=()=>source.map(s=>{if(isRef(s))return s.value;if(isReactive(s))return reactiveGetter(s);if(isFunction$1(s))return call?call(s,2):s()})):getter=isFunction$1(source)?cb?call?()=>call(source,2):source:()=>{if(cleanup){pauseTracking();try{cleanup()}finally{resetTracking()}}let currentEffect=activeWatcher;activeWatcher=effect$1;try{return call?call(source,3,[boundCleanup]):source(boundCleanup)}finally{activeWatcher=currentEffect}}:NOOP,cb&&deep){let baseGetter=getter,depth=deep===!0?1/0:deep;getter=()=>traverse(baseGetter(),depth)}let scope$1=getCurrentScope(),watchHandle=()=>{effect$1.stop(),scope$1&&scope$1.active&&remove$2(scope$1.effects,effect$1)};if(once&&cb){let _cb=cb;cb=(...args)=>{_cb(...args),watchHandle()}}let oldValue=isMultiSource?Array(source.length).fill(INITIAL_WATCHER_VALUE):INITIAL_WATCHER_VALUE,job=immediateFirstRun=>{if(!(!(effect$1.flags&1)||!effect$1.dirty&&!immediateFirstRun))if(cb){let newValue=effect$1.run();if(deep||forceTrigger||(isMultiSource?newValue.some((v,i)=>hasChanged(v,oldValue[i])):hasChanged(newValue,oldValue))){cleanup&&cleanup();let currentWatcher=activeWatcher;activeWatcher=effect$1;try{let args=[newValue,oldValue===INITIAL_WATCHER_VALUE?void 0:isMultiSource&&oldValue[0]===INITIAL_WATCHER_VALUE?[]:oldValue,boundCleanup];oldValue=newValue,call?call(cb,3,args):cb(...args)}finally{activeWatcher=currentWatcher}}}else effect$1.run()};return augmentJob&&augmentJob(job),effect$1=new ReactiveEffect(getter),effect$1.scheduler=scheduler?()=>scheduler(job,!1):job,boundCleanup=fn=>onWatcherCleanup(fn,!1,effect$1),cleanup=effect$1.onStop=()=>{let cleanups=cleanupMap.get(effect$1);if(cleanups){if(call)call(cleanups,4);else for(let cleanup2 of cleanups)cleanup2();cleanupMap.delete(effect$1)}},cb?immediate?job(!0):oldValue=effect$1.run():scheduler?scheduler(job.bind(null,!0),!0):effect$1.run(),watchHandle.pause=effect$1.pause.bind(effect$1),watchHandle.resume=effect$1.resume.bind(effect$1),watchHandle.stop=watchHandle,watchHandle}function traverse(value,depth=1/0,seen$3){if(depth<=0||!isObject$1(value)||value.__v_skip||(seen$3||=new Map,(seen$3.get(value)||0)>=depth))return value;if(seen$3.set(value,depth),depth--,isRef(value))traverse(value.value,depth,seen$3);else if(isArray$2(value))for(let i=0;i{traverse(v,depth,seen$3)});else if(isPlainObject$2(value)){for(let key in value)traverse(value[key],depth,seen$3);for(let key of Object.getOwnPropertySymbols(value))Object.prototype.propertyIsEnumerable.call(value,key)&&traverse(value[key],depth,seen$3)}return value}var stack$1=[];function pushWarningContext(vnode){stack$1.push(vnode)}function popWarningContext(){stack$1.pop()}function assertNumber(val,type){}var ErrorCodes={SETUP_FUNCTION:0,0:`SETUP_FUNCTION`,RENDER_FUNCTION:1,1:`RENDER_FUNCTION`,NATIVE_EVENT_HANDLER:5,5:`NATIVE_EVENT_HANDLER`,COMPONENT_EVENT_HANDLER:6,6:`COMPONENT_EVENT_HANDLER`,VNODE_HOOK:7,7:`VNODE_HOOK`,DIRECTIVE_HOOK:8,8:`DIRECTIVE_HOOK`,TRANSITION_HOOK:9,9:`TRANSITION_HOOK`,APP_ERROR_HANDLER:10,10:`APP_ERROR_HANDLER`,APP_WARN_HANDLER:11,11:`APP_WARN_HANDLER`,FUNCTION_REF:12,12:`FUNCTION_REF`,ASYNC_COMPONENT_LOADER:13,13:`ASYNC_COMPONENT_LOADER`,SCHEDULER:14,14:`SCHEDULER`,COMPONENT_UPDATE:15,15:`COMPONENT_UPDATE`,APP_UNMOUNT_CLEANUP:16,16:`APP_UNMOUNT_CLEANUP`},ErrorTypeStrings$1={sp:`serverPrefetch hook`,bc:`beforeCreate hook`,c:`created hook`,bm:`beforeMount hook`,m:`mounted hook`,bu:`beforeUpdate hook`,u:`updated`,bum:`beforeUnmount hook`,um:`unmounted hook`,a:`activated hook`,da:`deactivated hook`,ec:`errorCaptured hook`,rtc:`renderTracked hook`,rtg:`renderTriggered hook`,0:`setup function`,1:`render function`,2:`watcher getter`,3:`watcher callback`,4:`watcher cleanup function`,5:`native event handler`,6:`component event handler`,7:`vnode hook`,8:`directive hook`,9:`transition hook`,10:`app errorHandler`,11:`app warnHandler`,12:`ref function`,13:`async component loader`,14:`scheduler flush`,15:`component update`,16:`app unmount cleanup function`};function callWithErrorHandling(fn,instance$1,type,args){try{return args?fn(...args):fn()}catch(err){handleError(err,instance$1,type)}}function callWithAsyncErrorHandling(fn,instance$1,type,args){if(isFunction$1(fn)){let res=callWithErrorHandling(fn,instance$1,type,args);return res&&isPromise$1(res)&&res.catch(err=>{handleError(err,instance$1,type)}),res}if(isArray$2(fn)){let values=[];for(let i=0;i>>1,middleJob=queue$1[middle],middleJobId=getId(middleJob);middleJobId=getId(lastJob)?queue$1.push(job):queue$1.splice(findInsertionIndex$1(jobId),0,job),job.flags|=1,queueFlush()}}function queueFlush(){currentFlushPromise||=resolvedPromise.then(flushJobs)}function queuePostFlushCb(cb){isArray$2(cb)?pendingPostFlushCbs.push(...cb):activePostFlushCbs&&cb.id===-1?activePostFlushCbs.splice(postFlushIndex+1,0,cb):cb.flags&1||(pendingPostFlushCbs.push(cb),cb.flags|=1),queueFlush()}function flushPreFlushCbs(instance$1,seen$3,i=flushIndex+1){for(;igetId(a$1)-getId(b));if(pendingPostFlushCbs.length=0,activePostFlushCbs){activePostFlushCbs.push(...deduped);return}for(activePostFlushCbs=deduped,postFlushIndex=0;postFlushIndexjob.id==null?job.flags&2?-1:1/0:job.id;function flushJobs(seen$3){try{for(flushIndex=0;flushIndexdevtools$1.emit(event,...args)),buffer=[]):typeof window<`u`&&window.HTMLElement&&!(window.navigator?.userAgent)?.includes(`jsdom`)?((target.__VUE_DEVTOOLS_HOOK_REPLAY__=target.__VUE_DEVTOOLS_HOOK_REPLAY__||[]).push(newHook=>{setDevtoolsHook$1(newHook,target)}),setTimeout(()=>{devtools$1||(target.__VUE_DEVTOOLS_HOOK_REPLAY__=null,buffer=[])},3e3)):buffer=[]}var currentRenderingInstance=null,currentScopeId=null;function setCurrentRenderingInstance(instance$1){let prev=currentRenderingInstance;return currentRenderingInstance=instance$1,currentScopeId=instance$1&&instance$1.type.__scopeId||null,prev}function pushScopeId(id){currentScopeId=id}function popScopeId(){currentScopeId=null}var withScopeId=_id=>withCtx;function withCtx(fn,ctx=currentRenderingInstance,isNonScopedSlot){if(!ctx||fn._n)return fn;let renderFnWithContext=(...args)=>{renderFnWithContext._d&&setBlockTracking(-1);let prevInstance=setCurrentRenderingInstance(ctx),res;try{res=fn(...args)}finally{setCurrentRenderingInstance(prevInstance),renderFnWithContext._d&&setBlockTracking(1)}return res};return renderFnWithContext._n=!0,renderFnWithContext._c=!0,renderFnWithContext._d=!0,renderFnWithContext}function withDirectives(vnode,directives){if(currentRenderingInstance===null)return vnode;let instance$1=getComponentPublicInstance(currentRenderingInstance),bindings=vnode.dirs||=[];for(let i=0;itype.__isTeleport,isTeleportDisabled=props=>props&&(props.disabled||props.disabled===``),isTeleportDeferred=props=>props&&(props.defer||props.defer===``),isTargetSVG=target=>typeof SVGElement<`u`&&target instanceof SVGElement,isTargetMathML=target=>typeof MathMLElement==`function`&&target instanceof MathMLElement,resolveTarget=(props,select)=>{let targetSelector=props&&props.to;return isString$1(targetSelector)?select?select(targetSelector):null:targetSelector},TeleportImpl={name:`Teleport`,__isTeleport:!0,process(n1,n2,container,anchor,parentComponent,parentSuspense,namespace,slotScopeIds,optimized,internals){let{mc:mountChildren,pc:patchChildren,pbc:patchBlockChildren,o:{insert,querySelector,createText,createComment}}=internals,disabled=isTeleportDisabled(n2.props),{shapeFlag,children,dynamicChildren}=n2;if(n1==null){let placeholder=n2.el=createText(``),mainAnchor=n2.anchor=createText(``);insert(placeholder,container,anchor),insert(mainAnchor,container,anchor);let mount=(container2,anchor2)=>{shapeFlag&16&&mountChildren(children,container2,anchor2,parentComponent,parentSuspense,namespace,slotScopeIds,optimized)},mountToTarget=()=>{let target=n2.target=resolveTarget(n2.props,querySelector),targetAnchor=prepareAnchor(target,n2,createText,insert);target&&(namespace!==`svg`&&isTargetSVG(target)?namespace=`svg`:namespace!==`mathml`&&isTargetMathML(target)&&(namespace=`mathml`),parentComponent&&parentComponent.isCE&&(parentComponent.ce._teleportTargets||(parentComponent.ce._teleportTargets=new Set)).add(target),disabled||(mount(target,targetAnchor),updateCssVars(n2,!1)))};disabled&&(mount(container,mainAnchor),updateCssVars(n2,!0)),isTeleportDeferred(n2.props)?(n2.el.__isMounted=!1,queuePostRenderEffect(()=>{mountToTarget(),delete n2.el.__isMounted},parentSuspense)):mountToTarget()}else{if(isTeleportDeferred(n2.props)&&n1.el.__isMounted===!1){queuePostRenderEffect(()=>{TeleportImpl.process(n1,n2,container,anchor,parentComponent,parentSuspense,namespace,slotScopeIds,optimized,internals)},parentSuspense);return}n2.el=n1.el,n2.targetStart=n1.targetStart;let mainAnchor=n2.anchor=n1.anchor,target=n2.target=n1.target,targetAnchor=n2.targetAnchor=n1.targetAnchor,wasDisabled=isTeleportDisabled(n1.props),currentContainer=wasDisabled?container:target,currentAnchor=wasDisabled?mainAnchor:targetAnchor;if(namespace===`svg`||isTargetSVG(target)?namespace=`svg`:(namespace===`mathml`||isTargetMathML(target))&&(namespace=`mathml`),dynamicChildren?(patchBlockChildren(n1.dynamicChildren,dynamicChildren,currentContainer,parentComponent,parentSuspense,namespace,slotScopeIds),traverseStaticChildren(n1,n2,!0)):optimized||patchChildren(n1,n2,currentContainer,currentAnchor,parentComponent,parentSuspense,namespace,slotScopeIds,!1),disabled)wasDisabled?n2.props&&n1.props&&n2.props.to!==n1.props.to&&(n2.props.to=n1.props.to):moveTeleport(n2,container,mainAnchor,internals,1);else if((n2.props&&n2.props.to)!==(n1.props&&n1.props.to)){let nextTarget=n2.target=resolveTarget(n2.props,querySelector);nextTarget&&moveTeleport(n2,nextTarget,null,internals,0)}else wasDisabled&&moveTeleport(n2,target,targetAnchor,internals,1);updateCssVars(n2,disabled)}},remove(vnode,parentComponent,parentSuspense,{um:unmount,o:{remove:hostRemove}},doRemove){let{shapeFlag,children,anchor,targetStart,targetAnchor,target,props}=vnode;if(target&&(hostRemove(targetStart),hostRemove(targetAnchor)),doRemove&&hostRemove(anchor),shapeFlag&16){let shouldRemove=doRemove||!isTeleportDisabled(props);for(let i=0;i{state.isMounted=!0}),onBeforeUnmount(()=>{state.isUnmounting=!0}),state}var TransitionHookValidator=[Function,Array],BaseTransitionPropsValidators={mode:String,appear:Boolean,persisted:Boolean,onBeforeEnter:TransitionHookValidator,onEnter:TransitionHookValidator,onAfterEnter:TransitionHookValidator,onEnterCancelled:TransitionHookValidator,onBeforeLeave:TransitionHookValidator,onLeave:TransitionHookValidator,onAfterLeave:TransitionHookValidator,onLeaveCancelled:TransitionHookValidator,onBeforeAppear:TransitionHookValidator,onAppear:TransitionHookValidator,onAfterAppear:TransitionHookValidator,onAppearCancelled:TransitionHookValidator},recursiveGetSubtree=instance$1=>{let subTree=instance$1.subTree;return subTree.component?recursiveGetSubtree(subTree.component):subTree},BaseTransitionImpl={name:`BaseTransition`,props:BaseTransitionPropsValidators,setup(props,{slots}){let instance$1=getCurrentInstance(),state=useTransitionState();return()=>{let children=slots.default&&getTransitionRawChildren(slots.default(),!0);if(!children||!children.length)return;let child=findNonCommentChild(children),rawProps=toRaw(props),{mode}=rawProps;if(state.isLeaving)return emptyPlaceholder(child);let innerChild=getInnerChild$1(child);if(!innerChild)return emptyPlaceholder(child);let enterHooks=resolveTransitionHooks(innerChild,rawProps,state,instance$1,hooks=>enterHooks=hooks);innerChild.type!==Comment&&setTransitionHooks(innerChild,enterHooks);let oldInnerChild=instance$1.subTree&&getInnerChild$1(instance$1.subTree);if(oldInnerChild&&oldInnerChild.type!==Comment&&!isSameVNodeType(oldInnerChild,innerChild)&&recursiveGetSubtree(instance$1).type!==Comment){let leavingHooks=resolveTransitionHooks(oldInnerChild,rawProps,state,instance$1);if(setTransitionHooks(oldInnerChild,leavingHooks),mode===`out-in`&&innerChild.type!==Comment)return state.isLeaving=!0,leavingHooks.afterLeave=()=>{state.isLeaving=!1,instance$1.job.flags&8||instance$1.update(),delete leavingHooks.afterLeave,oldInnerChild=void 0},emptyPlaceholder(child);mode===`in-out`&&innerChild.type!==Comment?leavingHooks.delayLeave=(el,earlyRemove,delayedLeave)=>{let leavingVNodesCache=getLeavingNodesForType(state,oldInnerChild);leavingVNodesCache[String(oldInnerChild.key)]=oldInnerChild,el[leaveCbKey]=()=>{earlyRemove(),el[leaveCbKey]=void 0,delete enterHooks.delayedLeave,oldInnerChild=void 0},enterHooks.delayedLeave=()=>{delayedLeave(),delete enterHooks.delayedLeave,oldInnerChild=void 0}}:oldInnerChild=void 0}else oldInnerChild&&=void 0;return child}}};function findNonCommentChild(children){let child=children[0];if(children.length>1){for(let c of children)if(c.type!==Comment){child=c;break}}return child}var BaseTransition=BaseTransitionImpl;function getLeavingNodesForType(state,vnode){let{leavingVNodes}=state,leavingVNodesCache=leavingVNodes.get(vnode.type);return leavingVNodesCache||(leavingVNodesCache=Object.create(null),leavingVNodes.set(vnode.type,leavingVNodesCache)),leavingVNodesCache}function resolveTransitionHooks(vnode,props,state,instance$1,postClone){let{appear,mode,persisted=!1,onBeforeEnter,onEnter,onAfterEnter,onEnterCancelled,onBeforeLeave,onLeave,onAfterLeave,onLeaveCancelled,onBeforeAppear,onAppear,onAfterAppear,onAppearCancelled}=props,key=String(vnode.key),leavingVNodesCache=getLeavingNodesForType(state,vnode),callHook$2=(hook,args)=>{hook&&callWithAsyncErrorHandling(hook,instance$1,9,args)},callAsyncHook=(hook,args)=>{let done=args[1];callHook$2(hook,args),isArray$2(hook)?hook.every(hook2=>hook2.length<=1)&&done():hook.length<=1&&done()},hooks={mode,persisted,beforeEnter(el){let hook=onBeforeEnter;if(!state.isMounted)if(appear)hook=onBeforeAppear||onBeforeEnter;else return;el[leaveCbKey]&&el[leaveCbKey](!0);let leavingVNode=leavingVNodesCache[key];leavingVNode&&isSameVNodeType(vnode,leavingVNode)&&leavingVNode.el[leaveCbKey]&&leavingVNode.el[leaveCbKey](),callHook$2(hook,[el])},enter(el){let hook=onEnter,afterHook=onAfterEnter,cancelHook=onEnterCancelled;if(!state.isMounted)if(appear)hook=onAppear||onEnter,afterHook=onAfterAppear||onAfterEnter,cancelHook=onAppearCancelled||onEnterCancelled;else return;let called=!1,done=el[enterCbKey$1]=cancelled=>{called||(called=!0,callHook$2(cancelled?cancelHook:afterHook,[el]),hooks.delayedLeave&&hooks.delayedLeave(),el[enterCbKey$1]=void 0)};hook?callAsyncHook(hook,[el,done]):done()},leave(el,remove$3){let key2=String(vnode.key);if(el[enterCbKey$1]&&el[enterCbKey$1](!0),state.isUnmounting)return remove$3();callHook$2(onBeforeLeave,[el]);let called=!1,done=el[leaveCbKey]=cancelled=>{called||(called=!0,remove$3(),callHook$2(cancelled?onLeaveCancelled:onAfterLeave,[el]),el[leaveCbKey]=void 0,leavingVNodesCache[key2]===vnode&&delete leavingVNodesCache[key2])};leavingVNodesCache[key2]=vnode,onLeave?callAsyncHook(onLeave,[el,done]):done()},clone(vnode2){let hooks2=resolveTransitionHooks(vnode2,props,state,instance$1,postClone);return postClone&&postClone(hooks2),hooks2}};return hooks}function emptyPlaceholder(vnode){if(isKeepAlive(vnode))return vnode=cloneVNode(vnode),vnode.children=null,vnode}function getInnerChild$1(vnode){if(!isKeepAlive(vnode))return isTeleport(vnode.type)&&vnode.children?findNonCommentChild(vnode.children):vnode;if(vnode.component)return vnode.component.subTree;let{shapeFlag,children}=vnode;if(children){if(shapeFlag&16)return children[0];if(shapeFlag&32&&isFunction$1(children.default))return children.default()}}function setTransitionHooks(vnode,hooks){vnode.shapeFlag&6&&vnode.component?(vnode.transition=hooks,setTransitionHooks(vnode.component.subTree,hooks)):vnode.shapeFlag&128?(vnode.ssContent.transition=hooks.clone(vnode.ssContent),vnode.ssFallback.transition=hooks.clone(vnode.ssFallback)):vnode.transition=hooks}function getTransitionRawChildren(children,keepComment=!1,parentKey){let ret=[],keyedFragmentCount=0;for(let i=0;i1)for(let i=0;iextend({name:options.name},extraOptions,{setup:options}))():options}function useId(){let i=getCurrentInstance();return i?(i.appContext.config.idPrefix||`v`)+`-`+i.ids[0]+ i.ids[1]++:``}function markAsyncBoundary(instance$1){instance$1.ids=[instance$1.ids[0]+ instance$1.ids[2]+++`-`,0,0]}function useTemplateRef(key){let i=getCurrentInstance(),r=shallowRef(null);if(i){let refs=i.refs===EMPTY_OBJ?i.refs={}:i.refs;Object.defineProperty(refs,key,{enumerable:!0,get:()=>r.value,set:val=>r.value=val})}return r}var pendingSetRefMap=new WeakMap;function setRef(rawRef,oldRawRef,parentSuspense,vnode,isUnmount=!1){if(isArray$2(rawRef)){rawRef.forEach((r,i)=>setRef(r,oldRawRef&&(isArray$2(oldRawRef)?oldRawRef[i]:oldRawRef),parentSuspense,vnode,isUnmount));return}if(isAsyncWrapper(vnode)&&!isUnmount){vnode.shapeFlag&512&&vnode.type.__asyncResolved&&vnode.component.subTree.component&&setRef(rawRef,oldRawRef,parentSuspense,vnode.component.subTree);return}let refValue=vnode.shapeFlag&4?getComponentPublicInstance(vnode.component):vnode.el,value=isUnmount?null:refValue,{i:owner,r:ref$1}=rawRef,oldRef=oldRawRef&&oldRawRef.r,refs=owner.refs===EMPTY_OBJ?owner.refs={}:owner.refs,setupState=owner.setupState,rawSetupState=toRaw(setupState),canSetSetupRef=setupState===EMPTY_OBJ?NO:key=>hasOwn$1(rawSetupState,key),canSetRef=ref2=>!0;if(oldRef!=null&&oldRef!==ref$1){if(invalidatePendingSetRef(oldRawRef),isString$1(oldRef))refs[oldRef]=null,canSetSetupRef(oldRef)&&(setupState[oldRef]=null);else if(isRef(oldRef)){canSetRef(oldRef)&&(oldRef.value=null);let oldRawRefAtom=oldRawRef;oldRawRefAtom.k&&(refs[oldRawRefAtom.k]=null)}}if(isFunction$1(ref$1))callWithErrorHandling(ref$1,owner,12,[value,refs]);else{let _isString=isString$1(ref$1),_isRef=isRef(ref$1);if(_isString||_isRef){let doSet=()=>{if(rawRef.f){let existing=_isString?canSetSetupRef(ref$1)?setupState[ref$1]:refs[ref$1]:canSetRef(ref$1)||!rawRef.k?ref$1.value:refs[rawRef.k];if(isUnmount)isArray$2(existing)&&remove$2(existing,refValue);else if(isArray$2(existing))existing.includes(refValue)||existing.push(refValue);else if(_isString)refs[ref$1]=[refValue],canSetSetupRef(ref$1)&&(setupState[ref$1]=refs[ref$1]);else{let newVal=[refValue];canSetRef(ref$1)&&(ref$1.value=newVal),rawRef.k&&(refs[rawRef.k]=newVal)}}else _isString?(refs[ref$1]=value,canSetSetupRef(ref$1)&&(setupState[ref$1]=value)):_isRef&&(canSetRef(ref$1)&&(ref$1.value=value),rawRef.k&&(refs[rawRef.k]=value))};if(value){let job=()=>{doSet(),pendingSetRefMap.delete(rawRef)};job.id=-1,pendingSetRefMap.set(rawRef,job),queuePostRenderEffect(job,parentSuspense)}else invalidatePendingSetRef(rawRef),doSet()}}}function invalidatePendingSetRef(rawRef){let pendingSetRef=pendingSetRefMap.get(rawRef);pendingSetRef&&(pendingSetRef.flags|=8,pendingSetRefMap.delete(rawRef))}var hasLoggedMismatchError=!1,logMismatchError=()=>{hasLoggedMismatchError||=(console.error(`Hydration completed but contains mismatches.`),!0)},isSVGContainer=container=>container.namespaceURI.includes(`svg`)&&container.tagName!==`foreignObject`,isMathMLContainer=container=>container.namespaceURI.includes(`MathML`),getContainerType=container=>{if(container.nodeType===1){if(isSVGContainer(container))return`svg`;if(isMathMLContainer(container))return`mathml`}},isComment=node=>node.nodeType===8;function createHydrationFunctions(rendererInternals){let{mt:mountComponent,p:patch,o:{patchProp:patchProp$1,createText,nextSibling,parentNode,remove:remove$3,insert,createComment}}=rendererInternals,hydrate$1=(vnode,container)=>{if(!container.hasChildNodes()){patch(null,vnode,container),flushPostFlushCbs(),container._vnode=vnode;return}hydrateNode(container.firstChild,vnode,null,null,null),flushPostFlushCbs(),container._vnode=vnode},hydrateNode=(node,vnode,parentComponent,parentSuspense,slotScopeIds,optimized=!1)=>{optimized||=!!vnode.dynamicChildren;let isFragmentStart=isComment(node)&&node.data===`[`,onMismatch=()=>handleMismatch(node,vnode,parentComponent,parentSuspense,slotScopeIds,isFragmentStart),{type,ref:ref$1,shapeFlag,patchFlag}=vnode,domType=node.nodeType;vnode.el=node,patchFlag===-2&&(optimized=!1,vnode.dynamicChildren=null);let nextNode=null;switch(type){case Text:domType===3?(node.data!==vnode.children&&(logMismatchError(),node.data=vnode.children),nextNode=nextSibling(node)):vnode.children===``?(insert(vnode.el=createText(``),parentNode(node),node),nextNode=node):nextNode=onMismatch();break;case Comment:isTemplateNode$1(node)?(nextNode=nextSibling(node),replaceNode(vnode.el=node.content.firstChild,node,parentComponent)):nextNode=domType!==8||isFragmentStart?onMismatch():nextSibling(node);break;case Static:if(isFragmentStart&&(node=nextSibling(node),domType=node.nodeType),domType===1||domType===3){nextNode=node;let needToAdoptContent=!vnode.children.length;for(let i=0;i{optimized||=!!vnode.dynamicChildren;let{type,props,patchFlag,shapeFlag,dirs,transition}=vnode,forcePatch=type===`input`||type===`option`;if(forcePatch||patchFlag!==-1){dirs&&invokeDirectiveHook(vnode,null,parentComponent,`created`);let needCallTransitionHooks=!1;if(isTemplateNode$1(el)){needCallTransitionHooks=needTransition(null,transition)&&parentComponent&&parentComponent.vnode.props&&parentComponent.vnode.props.appear;let content=el.content.firstChild;if(needCallTransitionHooks){let cls=content.getAttribute(`class`);cls&&(content.$cls=cls),transition.beforeEnter(content)}replaceNode(content,el,parentComponent),vnode.el=el=content}if(shapeFlag&16&&!(props&&(props.innerHTML||props.textContent))){let next=hydrateChildren(el.firstChild,vnode,el,parentComponent,parentSuspense,slotScopeIds,optimized);for(;next;){isMismatchAllowed(el,1)||logMismatchError();let cur=next;next=next.nextSibling,remove$3(cur)}}else if(shapeFlag&8){let clientText=vnode.children;clientText[0]===`
`&&(el.tagName===`PRE`||el.tagName===`TEXTAREA`)&&(clientText=clientText.slice(1)),el.textContent!==clientText&&(isMismatchAllowed(el,0)||logMismatchError(),el.textContent=vnode.children)}if(props){if(forcePatch||!optimized||patchFlag&48){let isCustomElement=el.tagName.includes(`-`);for(let key in props)(forcePatch&&(key.endsWith(`value`)||key===`indeterminate`)||isOn(key)&&!isReservedProp(key)||key[0]===`.`||isCustomElement)&&patchProp$1(el,key,null,props[key],void 0,parentComponent)}else if(props.onClick)patchProp$1(el,`onClick`,null,props.onClick,void 0,parentComponent);else if(patchFlag&4&&isReactive(props.style))for(let key in props.style)props.style[key]}let vnodeHooks;(vnodeHooks=props&&props.onVnodeBeforeMount)&&invokeVNodeHook(vnodeHooks,parentComponent,vnode),dirs&&invokeDirectiveHook(vnode,null,parentComponent,`beforeMount`),((vnodeHooks=props&&props.onVnodeMounted)||dirs||needCallTransitionHooks)&&queueEffectWithSuspense(()=>{vnodeHooks&&invokeVNodeHook(vnodeHooks,parentComponent,vnode),needCallTransitionHooks&&transition.enter(el),dirs&&invokeDirectiveHook(vnode,null,parentComponent,`mounted`)},parentSuspense)}return el.nextSibling},hydrateChildren=(node,parentVNode,container,parentComponent,parentSuspense,slotScopeIds,optimized)=>{optimized||=!!parentVNode.dynamicChildren;let children=parentVNode.children,l=children.length;for(let i=0;i{let{slotScopeIds:fragmentSlotScopeIds}=vnode;fragmentSlotScopeIds&&(slotScopeIds=slotScopeIds?slotScopeIds.concat(fragmentSlotScopeIds):fragmentSlotScopeIds);let container=parentNode(node),next=hydrateChildren(nextSibling(node),vnode,container,parentComponent,parentSuspense,slotScopeIds,optimized);return next&&isComment(next)&&next.data===`]`?nextSibling(vnode.anchor=next):(logMismatchError(),insert(vnode.anchor=createComment(`]`),container,next),next)},handleMismatch=(node,vnode,parentComponent,parentSuspense,slotScopeIds,isFragment)=>{if(isMismatchAllowed(node.parentElement,1)||logMismatchError(),vnode.el=null,isFragment){let end=locateClosingAnchor(node);for(;;){let next2=nextSibling(node);if(next2&&next2!==end)remove$3(next2);else break}}let next=nextSibling(node),container=parentNode(node);return remove$3(node),patch(null,vnode,container,next,parentComponent,parentSuspense,getContainerType(container),slotScopeIds),parentComponent&&(parentComponent.vnode.el=vnode.el,updateHOCHostEl(parentComponent,vnode.el)),next},locateClosingAnchor=(node,open$1=`[`,close=`]`)=>{let match=0;for(;node;)if(node=nextSibling(node),node&&isComment(node)&&(node.data===open$1&&match++,node.data===close)){if(match===0)return nextSibling(node);match--}return node},replaceNode=(newNode,oldNode,parentComponent)=>{let parentNode2=oldNode.parentNode;parentNode2&&parentNode2.replaceChild(newNode,oldNode);let parent=parentComponent;for(;parent;)parent.vnode.el===oldNode&&(parent.vnode.el=parent.subTree.el=newNode),parent=parent.parent},isTemplateNode$1=node=>node.nodeType===1&&node.tagName===`TEMPLATE`;return[hydrate$1,hydrateNode]}var allowMismatchAttr=`data-allow-mismatch`,MismatchTypeString={0:`text`,1:`children`,2:`class`,3:`style`,4:`attribute`};function isMismatchAllowed(el,allowedType){if(allowedType===0||allowedType===1)for(;el&&!el.hasAttribute(allowMismatchAttr);)el=el.parentElement;let allowedAttr=el&&el.getAttribute(allowMismatchAttr);if(allowedAttr==null)return!1;if(allowedAttr===``)return!0;{let list=allowedAttr.split(`,`);return allowedType===0&&list.includes(`children`)?!0:list.includes(MismatchTypeString[allowedType])}}var requestIdleCallback=getGlobalThis$1().requestIdleCallback||(cb=>setTimeout(cb,1)),cancelIdleCallback=getGlobalThis$1().cancelIdleCallback||(id=>clearTimeout(id)),hydrateOnIdle=(timeout=1e4)=>hydrate$1=>{let id=requestIdleCallback(hydrate$1,{timeout});return()=>cancelIdleCallback(id)};function elementIsVisibleInViewport(el){let{top,left,bottom,right}=el.getBoundingClientRect(),{innerHeight,innerWidth}=window;return(top>0&&top0&&bottom0&&left0&&right(hydrate$1,forEach)=>{let ob=new IntersectionObserver(entries=>{for(let e of entries)if(e.isIntersecting){ob.disconnect(),hydrate$1();break}},opts);return forEach(el=>{if(el instanceof Element){if(elementIsVisibleInViewport(el))return hydrate$1(),ob.disconnect(),!1;ob.observe(el)}}),()=>ob.disconnect()},hydrateOnMediaQuery=query=>hydrate$1=>{if(query){let mql=matchMedia(query);if(mql.matches)hydrate$1();else return mql.addEventListener(`change`,hydrate$1,{once:!0}),()=>mql.removeEventListener(`change`,hydrate$1)}},hydrateOnInteraction=(interactions=[])=>(hydrate$1,forEach)=>{isString$1(interactions)&&(interactions=[interactions]);let hasHydrated=!1,doHydrate=e=>{hasHydrated||(hasHydrated=!0,teardown(),hydrate$1(),e.target.dispatchEvent(new e.constructor(e.type,e)))},teardown=()=>{forEach(el=>{for(let i of interactions)el.removeEventListener(i,doHydrate)})};return forEach(el=>{for(let i of interactions)el.addEventListener(i,doHydrate,{once:!0})}),teardown};function forEachElement(node,cb){if(isComment(node)&&node.data===`[`){let depth=1,next=node.nextSibling;for(;next;){if(next.nodeType===1){if(cb(next)===!1)break}else if(isComment(next))if(next.data===`]`){if(--depth===0)break}else next.data===`[`&&depth++;next=next.nextSibling}}else cb(node)}var isAsyncWrapper=i=>!!i.type.__asyncLoader;function defineAsyncComponent(source){isFunction$1(source)&&(source={loader:source});let{loader,loadingComponent,errorComponent,delay=200,hydrate:hydrateStrategy,timeout,suspensible=!0,onError:userOnError}=source,pendingRequest=null,resolvedComp,retries=0,retry=()=>(retries++,pendingRequest=null,load()),load=()=>{let thisRequest;return pendingRequest||(thisRequest=pendingRequest=loader().catch(err=>{if(err=err instanceof Error?err:Error(String(err)),userOnError)return new Promise((resolve$1,reject)=>{userOnError(err,()=>resolve$1(retry()),()=>reject(err),retries+1)});throw err}).then(comp=>thisRequest!==pendingRequest&&pendingRequest?pendingRequest:(comp&&(comp.__esModule||comp[Symbol.toStringTag]===`Module`)&&(comp=comp.default),resolvedComp=comp,comp)))};return defineComponent({name:`AsyncComponentWrapper`,__asyncLoader:load,__asyncHydrate(el,instance$1,hydrate$1){let patched=!1;(instance$1.bu||=[]).push(()=>patched=!0);let performHydrate=()=>{patched||hydrate$1()},doHydrate=hydrateStrategy?()=>{let teardown=hydrateStrategy(performHydrate,cb=>forEachElement(el,cb));teardown&&(instance$1.bum||=[]).push(teardown)}:performHydrate;resolvedComp?doHydrate():load().then(()=>!instance$1.isUnmounted&&doHydrate())},get __asyncResolved(){return resolvedComp},setup(){let instance$1=currentInstance;if(markAsyncBoundary(instance$1),resolvedComp)return()=>createInnerComp(resolvedComp,instance$1);let onError=err=>{pendingRequest=null,handleError(err,instance$1,13,!errorComponent)};if(suspensible&&instance$1.suspense||isInSSRComponentSetup)return load().then(comp=>()=>createInnerComp(comp,instance$1)).catch(err=>(onError(err),()=>errorComponent?createVNode(errorComponent,{error:err}):null));let loaded=ref(!1),error=ref(),delayed=ref(!!delay);return delay&&setTimeout(()=>{delayed.value=!1},delay),timeout!=null&&setTimeout(()=>{if(!loaded.value&&!error.value){let err=Error(`Async component timed out after ${timeout}ms.`);onError(err),error.value=err}},timeout),load().then(()=>{loaded.value=!0,instance$1.parent&&isKeepAlive(instance$1.parent.vnode)&&instance$1.parent.update()}).catch(err=>{onError(err),error.value=err}),()=>{if(loaded.value&&resolvedComp)return createInnerComp(resolvedComp,instance$1);if(error.value&&errorComponent)return createVNode(errorComponent,{error:error.value});if(loadingComponent&&!delayed.value)return createVNode(loadingComponent)}}})}function createInnerComp(comp,parent){let{ref:ref2,props,children,ce}=parent.vnode,vnode=createVNode(comp,props,children);return vnode.ref=ref2,vnode.ce=ce,delete parent.vnode.ce,vnode}var isKeepAlive=vnode=>vnode.type.__isKeepAlive,KeepAlive={name:`KeepAlive`,__isKeepAlive:!0,props:{include:[String,RegExp,Array],exclude:[String,RegExp,Array],max:[String,Number]},setup(props,{slots}){let instance$1=getCurrentInstance(),sharedContext$1=instance$1.ctx;if(!sharedContext$1.renderer)return()=>{let children=slots.default&&slots.default();return children&&children.length===1?children[0]:children};let cache$1=new Map,keys=new Set,current=null,parentSuspense=instance$1.suspense,{renderer:{p:patch,m:move,um:_unmount,o:{createElement}}}=sharedContext$1,storageContainer=createElement(`div`);sharedContext$1.activate=(vnode,container,anchor,namespace,optimized)=>{let instance2=vnode.component;move(vnode,container,anchor,0,parentSuspense),patch(instance2.vnode,vnode,container,anchor,instance2,parentSuspense,namespace,vnode.slotScopeIds,optimized),queuePostRenderEffect(()=>{instance2.isDeactivated=!1,instance2.a&&invokeArrayFns(instance2.a);let vnodeHook=vnode.props&&vnode.props.onVnodeMounted;vnodeHook&&invokeVNodeHook(vnodeHook,instance2.parent,vnode)},parentSuspense)},sharedContext$1.deactivate=vnode=>{let instance2=vnode.component;invalidateMount(instance2.m),invalidateMount(instance2.a),move(vnode,storageContainer,null,1,parentSuspense),queuePostRenderEffect(()=>{instance2.da&&invokeArrayFns(instance2.da);let vnodeHook=vnode.props&&vnode.props.onVnodeUnmounted;vnodeHook&&invokeVNodeHook(vnodeHook,instance2.parent,vnode),instance2.isDeactivated=!0},parentSuspense)};function unmount(vnode){resetShapeFlag(vnode),_unmount(vnode,instance$1,parentSuspense,!0)}function pruneCache(filter){cache$1.forEach((vnode,key)=>{let name=getComponentName(vnode.type);name&&!filter(name)&&pruneCacheEntry(key)})}function pruneCacheEntry(key){let cached=cache$1.get(key);cached&&(!current||!isSameVNodeType(cached,current))?unmount(cached):current&&resetShapeFlag(current),cache$1.delete(key),keys.delete(key)}watch(()=>[props.include,props.exclude],([include,exclude])=>{include&&pruneCache(name=>matches(include,name)),exclude&&pruneCache(name=>!matches(exclude,name))},{flush:`post`,deep:!0});let pendingCacheKey=null,cacheSubtree=()=>{pendingCacheKey!=null&&(isSuspense(instance$1.subTree.type)?queuePostRenderEffect(()=>{cache$1.set(pendingCacheKey,getInnerChild(instance$1.subTree))},instance$1.subTree.suspense):cache$1.set(pendingCacheKey,getInnerChild(instance$1.subTree)))};return onMounted(cacheSubtree),onUpdated(cacheSubtree),onBeforeUnmount(()=>{cache$1.forEach(cached=>{let{subTree,suspense}=instance$1,vnode=getInnerChild(subTree);if(cached.type===vnode.type&&cached.key===vnode.key){resetShapeFlag(vnode);let da=vnode.component.da;da&&queuePostRenderEffect(da,suspense);return}unmount(cached)})}),()=>{if(pendingCacheKey=null,!slots.default)return current=null;let children=slots.default(),rawVNode=children[0];if(children.length>1)return current=null,children;if(!isVNode(rawVNode)||!(rawVNode.shapeFlag&4)&&!(rawVNode.shapeFlag&128))return current=null,rawVNode;let vnode=getInnerChild(rawVNode);if(vnode.type===Comment)return current=null,vnode;let comp=vnode.type,name=getComponentName(isAsyncWrapper(vnode)?vnode.type.__asyncResolved||{}:comp),{include,exclude,max:max$1}=props;if(include&&(!name||!matches(include,name))||exclude&&name&&matches(exclude,name))return vnode.shapeFlag&=-257,current=vnode,rawVNode;let key=vnode.key==null?comp:vnode.key,cachedVNode=cache$1.get(key);return vnode.el&&(vnode=cloneVNode(vnode),rawVNode.shapeFlag&128&&(rawVNode.ssContent=vnode)),pendingCacheKey=key,cachedVNode?(vnode.el=cachedVNode.el,vnode.component=cachedVNode.component,vnode.transition&&setTransitionHooks(vnode,vnode.transition),vnode.shapeFlag|=512,keys.delete(key),keys.add(key)):(keys.add(key),max$1&&keys.size>parseInt(max$1,10)&&pruneCacheEntry(keys.values().next().value)),vnode.shapeFlag|=256,current=vnode,isSuspense(rawVNode.type)?rawVNode:vnode}}};function matches(pattern,name){return isArray$2(pattern)?pattern.some(p$1=>matches(p$1,name)):isString$1(pattern)?pattern.split(`,`).includes(name):isRegExp$1(pattern)?(pattern.lastIndex=0,pattern.test(name)):!1}function onActivated(hook,target){registerKeepAliveHook(hook,`a`,target)}function onDeactivated(hook,target){registerKeepAliveHook(hook,`da`,target)}function registerKeepAliveHook(hook,type,target=currentInstance){let wrappedHook=hook.__wdc||=()=>{let current=target;for(;current;){if(current.isDeactivated)return;current=current.parent}return hook()};if(injectHook(type,wrappedHook,target),target){let current=target.parent;for(;current&¤t.parent;)isKeepAlive(current.parent.vnode)&&injectToKeepAliveRoot(wrappedHook,type,target,current),current=current.parent}}function injectToKeepAliveRoot(hook,type,target,keepAliveRoot){let injected=injectHook(type,hook,keepAliveRoot,!0);onUnmounted(()=>{remove$2(keepAliveRoot[type],injected)},target)}function resetShapeFlag(vnode){vnode.shapeFlag&=-257,vnode.shapeFlag&=-513}function getInnerChild(vnode){return vnode.shapeFlag&128?vnode.ssContent:vnode}function injectHook(type,hook,target=currentInstance,prepend=!1){if(target){let hooks=target[type]||(target[type]=[]),wrappedHook=hook.__weh||=(...args)=>{pauseTracking();let reset$1=setCurrentInstance(target),res=callWithAsyncErrorHandling(hook,target,type,args);return reset$1(),resetTracking(),res};return prepend?hooks.unshift(wrappedHook):hooks.push(wrappedHook),wrappedHook}}var createHook=lifecycle=>(hook,target=currentInstance)=>{(!isInSSRComponentSetup||lifecycle===`sp`)&&injectHook(lifecycle,(...args)=>hook(...args),target)},onBeforeMount=createHook(`bm`),onMounted=createHook(`m`),onBeforeUpdate=createHook(`bu`),onUpdated=createHook(`u`),onBeforeUnmount=createHook(`bum`),onUnmounted=createHook(`um`),onServerPrefetch=createHook(`sp`),onRenderTriggered=createHook(`rtg`),onRenderTracked=createHook(`rtc`);function onErrorCaptured(hook,target=currentInstance){injectHook(`ec`,hook,target)}var COMPONENTS=`components`,DIRECTIVES=`directives`;function resolveComponent(name,maybeSelfReference){return resolveAsset(COMPONENTS,name,!0,maybeSelfReference)||name}var NULL_DYNAMIC_COMPONENT=Symbol.for(`v-ndc`);function resolveDynamicComponent(component){return isString$1(component)?resolveAsset(COMPONENTS,component,!1)||component:component||NULL_DYNAMIC_COMPONENT}function resolveDirective(name){return resolveAsset(DIRECTIVES,name)}function resolveAsset(type,name,warnMissing=!0,maybeSelfReference=!1){let instance$1=currentRenderingInstance||currentInstance;if(instance$1){let Component=instance$1.type;if(type===COMPONENTS){let selfName=getComponentName(Component,!1);if(selfName&&(selfName===name||selfName===camelize(name)||selfName===capitalize$1(camelize(name))))return Component}let res=resolve(instance$1[type]||Component[type],name)||resolve(instance$1.appContext[type],name);return!res&&maybeSelfReference?Component:res}}function resolve(registry$1,name){return registry$1&&(registry$1[name]||registry$1[camelize(name)]||registry$1[capitalize$1(camelize(name))])}function renderList(source,renderItem,cache$1,index){let ret,cached=cache$1&&cache$1[index],sourceIsArray=isArray$2(source);if(sourceIsArray||isString$1(source)){let sourceIsReactiveArray=sourceIsArray&&isReactive(source),needsWrap=!1,isReadonlySource=!1;sourceIsReactiveArray&&(needsWrap=!isShallow(source),isReadonlySource=isReadonly(source),source=shallowReadArray(source)),ret=Array(source.length);for(let i=0,l=source.length;irenderItem(item,i,void 0,cached&&cached[i]));else{let keys=Object.keys(source);ret=Array(keys.length);for(let i=0,l=keys.length;i{let res=slot.fn(...args);return res&&(res.key=slot.key),res}:slot.fn)}return slots}function renderSlot(slots,name,props={},fallback,noSlotted){if(currentRenderingInstance.ce||currentRenderingInstance.parent&&isAsyncWrapper(currentRenderingInstance.parent)&¤tRenderingInstance.parent.ce){let hasProps=Object.keys(props).length>0;return name!==`default`&&(props.name=name),openBlock(),createBlock(Fragment,null,[createVNode(`slot`,props,fallback&&fallback())],hasProps?-2:64)}let slot=slots[name];slot&&slot._c&&(slot._d=!1),openBlock();let validSlotContent=slot&&ensureValidVNode(slot(props)),slotKey=props.key||validSlotContent&&validSlotContent.key,rendered=createBlock(Fragment,{key:(slotKey&&!isSymbol(slotKey)?slotKey:`_${name}`)+(!validSlotContent&&fallback?`_fb`:``)},validSlotContent||(fallback?fallback():[]),validSlotContent&&slots._===1?64:-2);return!noSlotted&&rendered.scopeId&&(rendered.slotScopeIds=[rendered.scopeId+`-s`]),slot&&slot._c&&(slot._d=!0),rendered}function ensureValidVNode(vnodes){return vnodes.some(child=>isVNode(child)?!(child.type===Comment||child.type===Fragment&&!ensureValidVNode(child.children)):!0)?vnodes:null}function toHandlers(obj,preserveCaseIfNecessary){let ret={};for(let key in obj)ret[preserveCaseIfNecessary&&/[A-Z]/.test(key)?`on:${key}`:toHandlerKey(key)]=obj[key];return ret}var getPublicInstance=i=>i?isStatefulComponent(i)?getComponentPublicInstance(i):getPublicInstance(i.parent):null,publicPropertiesMap=extend(Object.create(null),{$:i=>i,$el:i=>i.vnode.el,$data:i=>i.data,$props:i=>i.props,$attrs:i=>i.attrs,$slots:i=>i.slots,$refs:i=>i.refs,$parent:i=>getPublicInstance(i.parent),$root:i=>getPublicInstance(i.root),$host:i=>i.ce,$emit:i=>i.emit,$options:i=>resolveMergedOptions(i),$forceUpdate:i=>i.f||=()=>{queueJob(i.update)},$nextTick:i=>i.n||=nextTick.bind(i.proxy),$watch:i=>instanceWatch.bind(i)}),hasSetupBinding=(state,key)=>state!==EMPTY_OBJ&&!state.__isScriptSetup&&hasOwn$1(state,key),PublicInstanceProxyHandlers={get({_:instance$1},key){if(key===`__v_skip`)return!0;let{ctx,setupState,data,props,accessCache,type,appContext}=instance$1,normalizedProps;if(key[0]!==`$`){let n=accessCache[key];if(n!==void 0)switch(n){case 1:return setupState[key];case 2:return data[key];case 4:return ctx[key];case 3:return props[key]}else if(hasSetupBinding(setupState,key))return accessCache[key]=1,setupState[key];else if(data!==EMPTY_OBJ&&hasOwn$1(data,key))return accessCache[key]=2,data[key];else if((normalizedProps=instance$1.propsOptions[0])&&hasOwn$1(normalizedProps,key))return accessCache[key]=3,props[key];else if(ctx!==EMPTY_OBJ&&hasOwn$1(ctx,key))return accessCache[key]=4,ctx[key];else shouldCacheAccess&&(accessCache[key]=0)}let publicGetter=publicPropertiesMap[key],cssModule,globalProperties;if(publicGetter)return key===`$attrs`&&track(instance$1.attrs,`get`,``),publicGetter(instance$1);if((cssModule=type.__cssModules)&&(cssModule=cssModule[key]))return cssModule;if(ctx!==EMPTY_OBJ&&hasOwn$1(ctx,key))return accessCache[key]=4,ctx[key];if(globalProperties=appContext.config.globalProperties,hasOwn$1(globalProperties,key))return globalProperties[key]},set({_:instance$1},key,value){let{data,setupState,ctx}=instance$1;return hasSetupBinding(setupState,key)?(setupState[key]=value,!0):data!==EMPTY_OBJ&&hasOwn$1(data,key)?(data[key]=value,!0):hasOwn$1(instance$1.props,key)||key[0]===`$`&&key.slice(1)in instance$1?!1:(ctx[key]=value,!0)},has({_:{data,setupState,accessCache,ctx,appContext,propsOptions,type}},key){let normalizedProps,cssModules;return!!(accessCache[key]||data!==EMPTY_OBJ&&key[0]!==`$`&&hasOwn$1(data,key)||hasSetupBinding(setupState,key)||(normalizedProps=propsOptions[0])&&hasOwn$1(normalizedProps,key)||hasOwn$1(ctx,key)||hasOwn$1(publicPropertiesMap,key)||hasOwn$1(appContext.config.globalProperties,key)||(cssModules=type.__cssModules)&&cssModules[key])},defineProperty(target,key,descriptor){return descriptor.get==null?hasOwn$1(descriptor,`value`)&&this.set(target,key,descriptor.value,null):target._.accessCache[key]=0,Reflect.defineProperty(target,key,descriptor)}},RuntimeCompiledPublicInstanceProxyHandlers=extend({},PublicInstanceProxyHandlers,{get(target,key){if(key!==Symbol.unscopables)return PublicInstanceProxyHandlers.get(target,key,target)},has(_,key){return key[0]!==`_`&&!isGloballyAllowed(key)}});function defineProps(){return null}function defineEmits(){return null}function defineExpose(exposed){}function defineOptions(options){}function defineSlots(){return null}function defineModel(){}function withDefaults(props,defaults){return null}function useSlots(){return getContext(`useSlots`).slots}function useAttrs(){return getContext(`useAttrs`).attrs}function getContext(calledFunctionName){let i=getCurrentInstance();return i.setupContext||=createSetupContext(i)}function normalizePropsOrEmits(props){return isArray$2(props)?props.reduce((normalized,p$1)=>(normalized[p$1]=null,normalized),{}):props}function mergeDefaults(raw,defaults){let props=normalizePropsOrEmits(raw);for(let key in defaults){if(key.startsWith(`__skip`))continue;let opt=props[key];opt?isArray$2(opt)||isFunction$1(opt)?opt=props[key]={type:opt,default:defaults[key]}:opt.default=defaults[key]:opt===null&&(opt=props[key]={default:defaults[key]}),opt&&defaults[`__skip_${key}`]&&(opt.skipFactory=!0)}return props}function mergeModels(a$1,b){return!a$1||!b?a$1||b:isArray$2(a$1)&&isArray$2(b)?a$1.concat(b):extend({},normalizePropsOrEmits(a$1),normalizePropsOrEmits(b))}function createPropsRestProxy(props,excludedKeys){let ret={};for(let key in props)excludedKeys.includes(key)||Object.defineProperty(ret,key,{enumerable:!0,get:()=>props[key]});return ret}function withAsyncContext(getAwaitable){let ctx=getCurrentInstance(),awaitable=getAwaitable();return unsetCurrentInstance(),isPromise$1(awaitable)&&(awaitable=awaitable.catch(e=>{throw setCurrentInstance(ctx),e})),[awaitable,()=>setCurrentInstance(ctx)]}var shouldCacheAccess=!0;function applyOptions$1(instance$1){let options=resolveMergedOptions(instance$1),publicThis=instance$1.proxy,ctx=instance$1.ctx;shouldCacheAccess=!1,options.beforeCreate&&callHook$1(options.beforeCreate,instance$1,`bc`);let{data:dataOptions,computed:computedOptions,methods,watch:watchOptions,provide:provideOptions,inject:injectOptions,created,beforeMount:beforeMount$1,mounted:mounted$2,beforeUpdate,updated:updated$2,activated,deactivated,beforeDestroy,beforeUnmount:beforeUnmount$1,destroyed,unmounted:unmounted$1,render:render$1,renderTracked,renderTriggered,errorCaptured,serverPrefetch,expose,inheritAttrs,components,directives,filters}=options,checkDuplicateProperties=null;if(injectOptions&&resolveInjections(injectOptions,ctx,null),methods)for(let key in methods){let methodHandler=methods[key];isFunction$1(methodHandler)&&(ctx[key]=methodHandler.bind(publicThis))}if(dataOptions){let data=dataOptions.call(publicThis,publicThis);isObject$1(data)&&(instance$1.data=reactive(data))}if(shouldCacheAccess=!0,computedOptions)for(let key in computedOptions){let opt=computedOptions[key],c=computed({get:isFunction$1(opt)?opt.bind(publicThis,publicThis):isFunction$1(opt.get)?opt.get.bind(publicThis,publicThis):NOOP,set:!isFunction$1(opt)&&isFunction$1(opt.set)?opt.set.bind(publicThis):NOOP});Object.defineProperty(ctx,key,{enumerable:!0,configurable:!0,get:()=>c.value,set:v=>c.value=v})}if(watchOptions)for(let key in watchOptions)createWatcher(watchOptions[key],ctx,publicThis,key);if(provideOptions){let provides=isFunction$1(provideOptions)?provideOptions.call(publicThis):provideOptions;Reflect.ownKeys(provides).forEach(key=>{provide(key,provides[key])})}created&&callHook$1(created,instance$1,`c`);function registerLifecycleHook(register,hook){isArray$2(hook)?hook.forEach(_hook=>register(_hook.bind(publicThis))):hook&®ister(hook.bind(publicThis))}if(registerLifecycleHook(onBeforeMount,beforeMount$1),registerLifecycleHook(onMounted,mounted$2),registerLifecycleHook(onBeforeUpdate,beforeUpdate),registerLifecycleHook(onUpdated,updated$2),registerLifecycleHook(onActivated,activated),registerLifecycleHook(onDeactivated,deactivated),registerLifecycleHook(onErrorCaptured,errorCaptured),registerLifecycleHook(onRenderTracked,renderTracked),registerLifecycleHook(onRenderTriggered,renderTriggered),registerLifecycleHook(onBeforeUnmount,beforeUnmount$1),registerLifecycleHook(onUnmounted,unmounted$1),registerLifecycleHook(onServerPrefetch,serverPrefetch),isArray$2(expose))if(expose.length){let exposed=instance$1.exposed||={};expose.forEach(key=>{Object.defineProperty(exposed,key,{get:()=>publicThis[key],set:val=>publicThis[key]=val,enumerable:!0})})}else instance$1.exposed||={};render$1&&instance$1.render===NOOP&&(instance$1.render=render$1),inheritAttrs!=null&&(instance$1.inheritAttrs=inheritAttrs),components&&(instance$1.components=components),directives&&(instance$1.directives=directives),serverPrefetch&&markAsyncBoundary(instance$1)}function resolveInjections(injectOptions,ctx,checkDuplicateProperties=NOOP){for(let key in isArray$2(injectOptions)&&(injectOptions=normalizeInject(injectOptions)),injectOptions){let opt=injectOptions[key],injected;injected=isObject$1(opt)?`default`in opt?inject(opt.from||key,opt.default,!0):inject(opt.from||key):inject(opt),isRef(injected)?Object.defineProperty(ctx,key,{enumerable:!0,configurable:!0,get:()=>injected.value,set:v=>injected.value=v}):ctx[key]=injected}}function callHook$1(hook,instance$1,type){callWithAsyncErrorHandling(isArray$2(hook)?hook.map(h$1=>h$1.bind(instance$1.proxy)):hook.bind(instance$1.proxy),instance$1,type)}function createWatcher(raw,ctx,publicThis,key){let getter=key.includes(`.`)?createPathGetter(publicThis,key):()=>publicThis[key];if(isString$1(raw)){let handler$1=ctx[raw];isFunction$1(handler$1)&&watch(getter,handler$1)}else if(isFunction$1(raw))watch(getter,raw.bind(publicThis));else if(isObject$1(raw))if(isArray$2(raw))raw.forEach(r=>createWatcher(r,ctx,publicThis,key));else{let handler$1=isFunction$1(raw.handler)?raw.handler.bind(publicThis):ctx[raw.handler];isFunction$1(handler$1)&&watch(getter,handler$1,raw)}}function resolveMergedOptions(instance$1){let base=instance$1.type,{mixins,extends:extendsOptions}=base,{mixins:globalMixins,optionsCache:cache$1,config:{optionMergeStrategies}}=instance$1.appContext,cached=cache$1.get(base),resolved;return cached?resolved=cached:!globalMixins.length&&!mixins&&!extendsOptions?resolved=base:(resolved={},globalMixins.length&&globalMixins.forEach(m=>mergeOptions$1(resolved,m,optionMergeStrategies,!0)),mergeOptions$1(resolved,base,optionMergeStrategies)),isObject$1(base)&&cache$1.set(base,resolved),resolved}function mergeOptions$1(to,from,strats,asMixin=!1){let{mixins,extends:extendsOptions}=from;for(let key in extendsOptions&&mergeOptions$1(to,extendsOptions,strats,!0),mixins&&mixins.forEach(m=>mergeOptions$1(to,m,strats,!0)),from)if(!(asMixin&&key===`expose`)){let strat=internalOptionMergeStrats[key]||strats&&strats[key];to[key]=strat?strat(to[key],from[key]):from[key]}return to}var internalOptionMergeStrats={data:mergeDataFn,props:mergeEmitsOrPropsOptions,emits:mergeEmitsOrPropsOptions,methods:mergeObjectOptions,computed:mergeObjectOptions,beforeCreate:mergeAsArray$1,created:mergeAsArray$1,beforeMount:mergeAsArray$1,mounted:mergeAsArray$1,beforeUpdate:mergeAsArray$1,updated:mergeAsArray$1,beforeDestroy:mergeAsArray$1,beforeUnmount:mergeAsArray$1,destroyed:mergeAsArray$1,unmounted:mergeAsArray$1,activated:mergeAsArray$1,deactivated:mergeAsArray$1,errorCaptured:mergeAsArray$1,serverPrefetch:mergeAsArray$1,components:mergeObjectOptions,directives:mergeObjectOptions,watch:mergeWatchOptions,provide:mergeDataFn,inject:mergeInject};function mergeDataFn(to,from){return from?to?function(){return extend(isFunction$1(to)?to.call(this,this):to,isFunction$1(from)?from.call(this,this):from)}:from:to}function mergeInject(to,from){return mergeObjectOptions(normalizeInject(to),normalizeInject(from))}function normalizeInject(raw){if(isArray$2(raw)){let res={};for(let i=0;i1)return treatDefaultAsFactory&&isFunction$1(defaultValue)?defaultValue.call(instance$1&&instance$1.proxy):defaultValue}}function hasInjectionContext(){return!!(getCurrentInstance()||currentApp)}var internalObjectProto={},createInternalObject=()=>Object.create(internalObjectProto),isInternalObject=obj=>Object.getPrototypeOf(obj)===internalObjectProto;function initProps(instance$1,rawProps,isStateful,isSSR=!1){let props={},attrs=createInternalObject();for(let key in instance$1.propsDefaults=Object.create(null),setFullProps(instance$1,rawProps,props,attrs),instance$1.propsOptions[0])key in props||(props[key]=void 0);isStateful?instance$1.props=isSSR?props:shallowReactive(props):instance$1.type.props?instance$1.props=props:instance$1.props=attrs,instance$1.attrs=attrs}function updateProps(instance$1,rawProps,rawPrevProps,optimized){let{props,attrs,vnode:{patchFlag}}=instance$1,rawCurrentProps=toRaw(props),[options]=instance$1.propsOptions,hasAttrsChanged=!1;if((optimized||patchFlag>0)&&!(patchFlag&16)){if(patchFlag&8){let propsToUpdate=instance$1.vnode.dynamicProps;for(let i=0;i{hasExtends=!0;let[props,keys]=normalizePropsOptions(raw2,appContext,!0);extend(normalized,props),keys&&needCastKeys.push(...keys)};!asMixin&&appContext.mixins.length&&appContext.mixins.forEach(extendProps),comp.extends&&extendProps(comp.extends),comp.mixins&&comp.mixins.forEach(extendProps)}if(!raw&&!hasExtends)return isObject$1(comp)&&cache$1.set(comp,EMPTY_ARR),EMPTY_ARR;if(isArray$2(raw))for(let i=0;ikey===`_`||key===`_ctx`||key===`$stable`,normalizeSlotValue=value=>isArray$2(value)?value.map(normalizeVNode):[normalizeVNode(value)],normalizeSlot$1=(key,rawSlot,ctx)=>{if(rawSlot._n)return rawSlot;let normalized=withCtx((...args)=>normalizeSlotValue(rawSlot(...args)),ctx);return normalized._c=!1,normalized},normalizeObjectSlots=(rawSlots,slots,instance$1)=>{let ctx=rawSlots._ctx;for(let key in rawSlots){if(isInternalKey(key))continue;let value=rawSlots[key];if(isFunction$1(value))slots[key]=normalizeSlot$1(key,value,ctx);else if(value!=null){let normalized=normalizeSlotValue(value);slots[key]=()=>normalized}}},normalizeVNodeSlots=(instance$1,children)=>{let normalized=normalizeSlotValue(children);instance$1.slots.default=()=>normalized},assignSlots=(slots,children,optimized)=>{for(let key in children)(optimized||!isInternalKey(key))&&(slots[key]=children[key])},initSlots=(instance$1,children,optimized)=>{let slots=instance$1.slots=createInternalObject();if(instance$1.vnode.shapeFlag&32){let type=children._;type?(assignSlots(slots,children,optimized),optimized&&def(slots,`_`,type,!0)):normalizeObjectSlots(children,slots)}else children&&normalizeVNodeSlots(instance$1,children)},updateSlots=(instance$1,children,optimized)=>{let{vnode,slots}=instance$1,needDeletionCheck=!0,deletionComparisonTarget=EMPTY_OBJ;if(vnode.shapeFlag&32){let type=children._;type?optimized&&type===1?needDeletionCheck=!1:assignSlots(slots,children,optimized):(needDeletionCheck=!children.$stable,normalizeObjectSlots(children,slots)),deletionComparisonTarget=children}else children&&(normalizeVNodeSlots(instance$1,children),deletionComparisonTarget={default:1});if(needDeletionCheck)for(let key in slots)!isInternalKey(key)&&deletionComparisonTarget[key]==null&&delete slots[key]};function initFeatureFlags$2(){}var queuePostRenderEffect=queueEffectWithSuspense;function createRenderer(options){return baseCreateRenderer(options)}function createHydrationRenderer(options){return baseCreateRenderer(options,createHydrationFunctions)}function baseCreateRenderer(options,createHydrationFns){let target=getGlobalThis$1();target.__VUE__=!0;let{insert:hostInsert,remove:hostRemove,patchProp:hostPatchProp,createElement:hostCreateElement,createText:hostCreateText,createComment:hostCreateComment,setText:hostSetText,setElementText:hostSetElementText,parentNode:hostParentNode,nextSibling:hostNextSibling,setScopeId:hostSetScopeId=NOOP,insertStaticContent:hostInsertStaticContent}=options,patch=(n1,n2,container,anchor=null,parentComponent=null,parentSuspense=null,namespace=void 0,slotScopeIds=null,optimized=!!n2.dynamicChildren)=>{if(n1===n2)return;n1&&!isSameVNodeType(n1,n2)&&(anchor=getNextHostNode(n1),unmount(n1,parentComponent,parentSuspense,!0),n1=null),n2.patchFlag===-2&&(optimized=!1,n2.dynamicChildren=null);let{type,ref:ref$1,shapeFlag}=n2;switch(type){case Text:processText(n1,n2,container,anchor);break;case Comment:processCommentNode(n1,n2,container,anchor);break;case Static:n1??mountStaticNode(n2,container,anchor,namespace);break;case Fragment:processFragment(n1,n2,container,anchor,parentComponent,parentSuspense,namespace,slotScopeIds,optimized);break;default:shapeFlag&1?processElement(n1,n2,container,anchor,parentComponent,parentSuspense,namespace,slotScopeIds,optimized):shapeFlag&6?processComponent(n1,n2,container,anchor,parentComponent,parentSuspense,namespace,slotScopeIds,optimized):(shapeFlag&64||shapeFlag&128)&&type.process(n1,n2,container,anchor,parentComponent,parentSuspense,namespace,slotScopeIds,optimized,internals)}ref$1!=null&&parentComponent?setRef(ref$1,n1&&n1.ref,parentSuspense,n2||n1,!n2):ref$1==null&&n1&&n1.ref!=null&&setRef(n1.ref,null,parentSuspense,n1,!0)},processText=(n1,n2,container,anchor)=>{if(n1==null)hostInsert(n2.el=hostCreateText(n2.children),container,anchor);else{let el=n2.el=n1.el;n2.children!==n1.children&&hostSetText(el,n2.children)}},processCommentNode=(n1,n2,container,anchor)=>{n1==null?hostInsert(n2.el=hostCreateComment(n2.children||``),container,anchor):n2.el=n1.el},mountStaticNode=(n2,container,anchor,namespace)=>{[n2.el,n2.anchor]=hostInsertStaticContent(n2.children,container,anchor,namespace,n2.el,n2.anchor)},moveStaticNode=({el,anchor},container,nextSibling)=>{let next;for(;el&&el!==anchor;)next=hostNextSibling(el),hostInsert(el,container,nextSibling),el=next;hostInsert(anchor,container,nextSibling)},removeStaticNode=({el,anchor})=>{let next;for(;el&&el!==anchor;)next=hostNextSibling(el),hostRemove(el),el=next;hostRemove(anchor)},processElement=(n1,n2,container,anchor,parentComponent,parentSuspense,namespace,slotScopeIds,optimized)=>{n2.type===`svg`?namespace=`svg`:n2.type===`math`&&(namespace=`mathml`),n1==null?mountElement(n2,container,anchor,parentComponent,parentSuspense,namespace,slotScopeIds,optimized):patchElement(n1,n2,parentComponent,parentSuspense,namespace,slotScopeIds,optimized)},mountElement=(vnode,container,anchor,parentComponent,parentSuspense,namespace,slotScopeIds,optimized)=>{let el,vnodeHook,{props,shapeFlag,transition,dirs}=vnode;if(el=vnode.el=hostCreateElement(vnode.type,namespace,props&&props.is,props),shapeFlag&8?hostSetElementText(el,vnode.children):shapeFlag&16&&mountChildren(vnode.children,el,null,parentComponent,parentSuspense,resolveChildrenNamespace(vnode,namespace),slotScopeIds,optimized),dirs&&invokeDirectiveHook(vnode,null,parentComponent,`created`),setScopeId(el,vnode,vnode.scopeId,slotScopeIds,parentComponent),props){for(let key in props)key!==`value`&&!isReservedProp(key)&&hostPatchProp(el,key,null,props[key],namespace,parentComponent);`value`in props&&hostPatchProp(el,`value`,null,props.value,namespace),(vnodeHook=props.onVnodeBeforeMount)&&invokeVNodeHook(vnodeHook,parentComponent,vnode)}dirs&&invokeDirectiveHook(vnode,null,parentComponent,`beforeMount`);let needCallTransitionHooks=needTransition(parentSuspense,transition);needCallTransitionHooks&&transition.beforeEnter(el),hostInsert(el,container,anchor),((vnodeHook=props&&props.onVnodeMounted)||needCallTransitionHooks||dirs)&&queuePostRenderEffect(()=>{vnodeHook&&invokeVNodeHook(vnodeHook,parentComponent,vnode),needCallTransitionHooks&&transition.enter(el),dirs&&invokeDirectiveHook(vnode,null,parentComponent,`mounted`)},parentSuspense)},setScopeId=(el,vnode,scopeId,slotScopeIds,parentComponent)=>{if(scopeId&&hostSetScopeId(el,scopeId),slotScopeIds)for(let i=0;i{for(let i=start;i{let el=n2.el=n1.el,{patchFlag,dynamicChildren,dirs}=n2;patchFlag|=n1.patchFlag&16;let oldProps=n1.props||EMPTY_OBJ,newProps=n2.props||EMPTY_OBJ,vnodeHook;if(parentComponent&&toggleRecurse(parentComponent,!1),(vnodeHook=newProps.onVnodeBeforeUpdate)&&invokeVNodeHook(vnodeHook,parentComponent,n2,n1),dirs&&invokeDirectiveHook(n2,n1,parentComponent,`beforeUpdate`),parentComponent&&toggleRecurse(parentComponent,!0),(oldProps.innerHTML&&newProps.innerHTML==null||oldProps.textContent&&newProps.textContent==null)&&hostSetElementText(el,``),dynamicChildren?patchBlockChildren(n1.dynamicChildren,dynamicChildren,el,parentComponent,parentSuspense,resolveChildrenNamespace(n2,namespace),slotScopeIds):optimized||patchChildren(n1,n2,el,null,parentComponent,parentSuspense,resolveChildrenNamespace(n2,namespace),slotScopeIds,!1),patchFlag>0){if(patchFlag&16)patchProps(el,oldProps,newProps,parentComponent,namespace);else if(patchFlag&2&&oldProps.class!==newProps.class&&hostPatchProp(el,`class`,null,newProps.class,namespace),patchFlag&4&&hostPatchProp(el,`style`,oldProps.style,newProps.style,namespace),patchFlag&8){let propsToUpdate=n2.dynamicProps;for(let i=0;i{vnodeHook&&invokeVNodeHook(vnodeHook,parentComponent,n2,n1),dirs&&invokeDirectiveHook(n2,n1,parentComponent,`updated`)},parentSuspense)},patchBlockChildren=(oldChildren,newChildren,fallbackContainer,parentComponent,parentSuspense,namespace,slotScopeIds)=>{for(let i=0;i{if(oldProps!==newProps){if(oldProps!==EMPTY_OBJ)for(let key in oldProps)!isReservedProp(key)&&!(key in newProps)&&hostPatchProp(el,key,oldProps[key],null,namespace,parentComponent);for(let key in newProps){if(isReservedProp(key))continue;let next=newProps[key],prev=oldProps[key];next!==prev&&key!==`value`&&hostPatchProp(el,key,prev,next,namespace,parentComponent)}`value`in newProps&&hostPatchProp(el,`value`,oldProps.value,newProps.value,namespace)}},processFragment=(n1,n2,container,anchor,parentComponent,parentSuspense,namespace,slotScopeIds,optimized)=>{let fragmentStartAnchor=n2.el=n1?n1.el:hostCreateText(``),fragmentEndAnchor=n2.anchor=n1?n1.anchor:hostCreateText(``),{patchFlag,dynamicChildren,slotScopeIds:fragmentSlotScopeIds}=n2;fragmentSlotScopeIds&&(slotScopeIds=slotScopeIds?slotScopeIds.concat(fragmentSlotScopeIds):fragmentSlotScopeIds),n1==null?(hostInsert(fragmentStartAnchor,container,anchor),hostInsert(fragmentEndAnchor,container,anchor),mountChildren(n2.children||[],container,fragmentEndAnchor,parentComponent,parentSuspense,namespace,slotScopeIds,optimized)):patchFlag>0&&patchFlag&64&&dynamicChildren&&n1.dynamicChildren?(patchBlockChildren(n1.dynamicChildren,dynamicChildren,container,parentComponent,parentSuspense,namespace,slotScopeIds),(n2.key!=null||parentComponent&&n2===parentComponent.subTree)&&traverseStaticChildren(n1,n2,!0)):patchChildren(n1,n2,container,fragmentEndAnchor,parentComponent,parentSuspense,namespace,slotScopeIds,optimized)},processComponent=(n1,n2,container,anchor,parentComponent,parentSuspense,namespace,slotScopeIds,optimized)=>{n2.slotScopeIds=slotScopeIds,n1==null?n2.shapeFlag&512?parentComponent.ctx.activate(n2,container,anchor,namespace,optimized):mountComponent(n2,container,anchor,parentComponent,parentSuspense,namespace,optimized):updateComponent(n1,n2,optimized)},mountComponent=(initialVNode,container,anchor,parentComponent,parentSuspense,namespace,optimized)=>{let instance$1=initialVNode.component=createComponentInstance(initialVNode,parentComponent,parentSuspense);if(isKeepAlive(initialVNode)&&(instance$1.ctx.renderer=internals),setupComponent(instance$1,!1,optimized),instance$1.asyncDep){if(parentSuspense&&parentSuspense.registerDep(instance$1,setupRenderEffect,optimized),!initialVNode.el){let placeholder=instance$1.subTree=createVNode(Comment);processCommentNode(null,placeholder,container,anchor),initialVNode.placeholder=placeholder.el}}else setupRenderEffect(instance$1,initialVNode,container,anchor,parentSuspense,namespace,optimized)},updateComponent=(n1,n2,optimized)=>{let instance$1=n2.component=n1.component;if(shouldUpdateComponent(n1,n2,optimized))if(instance$1.asyncDep&&!instance$1.asyncResolved){updateComponentPreRender(instance$1,n2,optimized);return}else instance$1.next=n2,instance$1.update();else n2.el=n1.el,instance$1.vnode=n2},setupRenderEffect=(instance$1,initialVNode,container,anchor,parentSuspense,namespace,optimized)=>{let componentUpdateFn=()=>{if(instance$1.isMounted){let{next,bu,u,parent,vnode}=instance$1;{let nonHydratedAsyncRoot=locateNonHydratedAsyncRoot(instance$1);if(nonHydratedAsyncRoot){next&&(next.el=vnode.el,updateComponentPreRender(instance$1,next,optimized)),nonHydratedAsyncRoot.asyncDep.then(()=>{instance$1.isUnmounted||componentUpdateFn()});return}}let originNext=next,vnodeHook;toggleRecurse(instance$1,!1),next?(next.el=vnode.el,updateComponentPreRender(instance$1,next,optimized)):next=vnode,bu&&invokeArrayFns(bu),(vnodeHook=next.props&&next.props.onVnodeBeforeUpdate)&&invokeVNodeHook(vnodeHook,parent,next,vnode),toggleRecurse(instance$1,!0);let nextTree=renderComponentRoot(instance$1),prevTree=instance$1.subTree;instance$1.subTree=nextTree,patch(prevTree,nextTree,hostParentNode(prevTree.el),getNextHostNode(prevTree),instance$1,parentSuspense,namespace),next.el=nextTree.el,originNext===null&&updateHOCHostEl(instance$1,nextTree.el),u&&queuePostRenderEffect(u,parentSuspense),(vnodeHook=next.props&&next.props.onVnodeUpdated)&&queuePostRenderEffect(()=>invokeVNodeHook(vnodeHook,parent,next,vnode),parentSuspense)}else{let vnodeHook,{el,props}=initialVNode,{bm,m,parent,root,type}=instance$1,isAsyncWrapperVNode=isAsyncWrapper(initialVNode);if(toggleRecurse(instance$1,!1),bm&&invokeArrayFns(bm),!isAsyncWrapperVNode&&(vnodeHook=props&&props.onVnodeBeforeMount)&&invokeVNodeHook(vnodeHook,parent,initialVNode),toggleRecurse(instance$1,!0),el&&hydrateNode){let hydrateSubTree=()=>{instance$1.subTree=renderComponentRoot(instance$1),hydrateNode(el,instance$1.subTree,instance$1,parentSuspense,null)};isAsyncWrapperVNode&&type.__asyncHydrate?type.__asyncHydrate(el,instance$1,hydrateSubTree):hydrateSubTree()}else{root.ce&&root.ce._def.shadowRoot!==!1&&root.ce._injectChildStyle(type);let subTree=instance$1.subTree=renderComponentRoot(instance$1);patch(null,subTree,container,anchor,instance$1,parentSuspense,namespace),initialVNode.el=subTree.el}if(m&&queuePostRenderEffect(m,parentSuspense),!isAsyncWrapperVNode&&(vnodeHook=props&&props.onVnodeMounted)){let scopedInitialVNode=initialVNode;queuePostRenderEffect(()=>invokeVNodeHook(vnodeHook,parent,scopedInitialVNode),parentSuspense)}(initialVNode.shapeFlag&256||parent&&isAsyncWrapper(parent.vnode)&&parent.vnode.shapeFlag&256)&&instance$1.a&&queuePostRenderEffect(instance$1.a,parentSuspense),instance$1.isMounted=!0,initialVNode=container=anchor=null}};instance$1.scope.on();let effect$1=instance$1.effect=new ReactiveEffect(componentUpdateFn);instance$1.scope.off();let update$6=instance$1.update=effect$1.run.bind(effect$1),job=instance$1.job=effect$1.runIfDirty.bind(effect$1);job.i=instance$1,job.id=instance$1.uid,effect$1.scheduler=()=>queueJob(job),toggleRecurse(instance$1,!0),update$6()},updateComponentPreRender=(instance$1,nextVNode,optimized)=>{nextVNode.component=instance$1;let prevProps=instance$1.vnode.props;instance$1.vnode=nextVNode,instance$1.next=null,updateProps(instance$1,nextVNode.props,prevProps,optimized),updateSlots(instance$1,nextVNode.children,optimized),pauseTracking(),flushPreFlushCbs(instance$1),resetTracking()},patchChildren=(n1,n2,container,anchor,parentComponent,parentSuspense,namespace,slotScopeIds,optimized=!1)=>{let c1=n1&&n1.children,prevShapeFlag=n1?n1.shapeFlag:0,c2=n2.children,{patchFlag,shapeFlag}=n2;if(patchFlag>0){if(patchFlag&128){patchKeyedChildren(c1,c2,container,anchor,parentComponent,parentSuspense,namespace,slotScopeIds,optimized);return}else if(patchFlag&256){patchUnkeyedChildren(c1,c2,container,anchor,parentComponent,parentSuspense,namespace,slotScopeIds,optimized);return}}shapeFlag&8?(prevShapeFlag&16&&unmountChildren(c1,parentComponent,parentSuspense),c2!==c1&&hostSetElementText(container,c2)):prevShapeFlag&16?shapeFlag&16?patchKeyedChildren(c1,c2,container,anchor,parentComponent,parentSuspense,namespace,slotScopeIds,optimized):unmountChildren(c1,parentComponent,parentSuspense,!0):(prevShapeFlag&8&&hostSetElementText(container,``),shapeFlag&16&&mountChildren(c2,container,anchor,parentComponent,parentSuspense,namespace,slotScopeIds,optimized))},patchUnkeyedChildren=(c1,c2,container,anchor,parentComponent,parentSuspense,namespace,slotScopeIds,optimized)=>{c1||=EMPTY_ARR,c2||=EMPTY_ARR;let oldLength=c1.length,newLength=c2.length,commonLength=Math.min(oldLength,newLength),i;for(i=0;inewLength?unmountChildren(c1,parentComponent,parentSuspense,!0,!1,commonLength):mountChildren(c2,container,anchor,parentComponent,parentSuspense,namespace,slotScopeIds,optimized,commonLength)},patchKeyedChildren=(c1,c2,container,parentAnchor,parentComponent,parentSuspense,namespace,slotScopeIds,optimized)=>{let i=0,l2=c2.length,e1=c1.length-1,e2=l2-1;for(;i<=e1&&i<=e2;){let n1=c1[i],n2=c2[i]=optimized?cloneIfMounted(c2[i]):normalizeVNode(c2[i]);if(isSameVNodeType(n1,n2))patch(n1,n2,container,null,parentComponent,parentSuspense,namespace,slotScopeIds,optimized);else break;i++}for(;i<=e1&&i<=e2;){let n1=c1[e1],n2=c2[e2]=optimized?cloneIfMounted(c2[e2]):normalizeVNode(c2[e2]);if(isSameVNodeType(n1,n2))patch(n1,n2,container,null,parentComponent,parentSuspense,namespace,slotScopeIds,optimized);else break;e1--,e2--}if(i>e1){if(i<=e2){let nextPos=e2+1,anchor=nextPose2)for(;i<=e1;)unmount(c1[i],parentComponent,parentSuspense,!0),i++;else{let s1=i,s2=i,keyToNewIndexMap=new Map;for(i=s2;i<=e2;i++){let nextChild=c2[i]=optimized?cloneIfMounted(c2[i]):normalizeVNode(c2[i]);nextChild.key!=null&&keyToNewIndexMap.set(nextChild.key,i)}let j,patched=0,toBePatched=e2-s2+1,moved=!1,maxNewIndexSoFar=0,newIndexToOldIndexMap=Array(toBePatched);for(i=0;i=toBePatched){unmount(prevChild,parentComponent,parentSuspense,!0);continue}let newIndex;if(prevChild.key!=null)newIndex=keyToNewIndexMap.get(prevChild.key);else for(j=s2;j<=e2;j++)if(newIndexToOldIndexMap[j-s2]===0&&isSameVNodeType(prevChild,c2[j])){newIndex=j;break}newIndex===void 0?unmount(prevChild,parentComponent,parentSuspense,!0):(newIndexToOldIndexMap[newIndex-s2]=i+1,newIndex>=maxNewIndexSoFar?maxNewIndexSoFar=newIndex:moved=!0,patch(prevChild,c2[newIndex],container,null,parentComponent,parentSuspense,namespace,slotScopeIds,optimized),patched++)}let increasingNewIndexSequence=moved?getSequence(newIndexToOldIndexMap):EMPTY_ARR;for(j=increasingNewIndexSequence.length-1,i=toBePatched-1;i>=0;i--){let nextIndex=s2+i,nextChild=c2[nextIndex],anchorVNode=c2[nextIndex+1],anchor=nextIndex+1{let{el,type,transition,children,shapeFlag}=vnode;if(shapeFlag&6){move(vnode.component.subTree,container,anchor,moveType);return}if(shapeFlag&128){vnode.suspense.move(container,anchor,moveType);return}if(shapeFlag&64){type.move(vnode,container,anchor,internals);return}if(type===Fragment){hostInsert(el,container,anchor);for(let i=0;itransition.enter(el),parentSuspense);else{let{leave,delayLeave,afterLeave}=transition,remove2=()=>{vnode.ctx.isUnmounted?hostRemove(el):hostInsert(el,container,anchor)},performLeave=()=>{el._isLeaving&&el[leaveCbKey](!0),leave(el,()=>{remove2(),afterLeave&&afterLeave()})};delayLeave?delayLeave(el,remove2,performLeave):performLeave()}else hostInsert(el,container,anchor)},unmount=(vnode,parentComponent,parentSuspense,doRemove=!1,optimized=!1)=>{let{type,props,ref:ref$1,children,dynamicChildren,shapeFlag,patchFlag,dirs,cacheIndex}=vnode;if(patchFlag===-2&&(optimized=!1),ref$1!=null&&(pauseTracking(),setRef(ref$1,null,parentSuspense,vnode,!0),resetTracking()),cacheIndex!=null&&(parentComponent.renderCache[cacheIndex]=void 0),shapeFlag&256){parentComponent.ctx.deactivate(vnode);return}let shouldInvokeDirs=shapeFlag&1&&dirs,shouldInvokeVnodeHook=!isAsyncWrapper(vnode),vnodeHook;if(shouldInvokeVnodeHook&&(vnodeHook=props&&props.onVnodeBeforeUnmount)&&invokeVNodeHook(vnodeHook,parentComponent,vnode),shapeFlag&6)unmountComponent(vnode.component,parentSuspense,doRemove);else{if(shapeFlag&128){vnode.suspense.unmount(parentSuspense,doRemove);return}shouldInvokeDirs&&invokeDirectiveHook(vnode,null,parentComponent,`beforeUnmount`),shapeFlag&64?vnode.type.remove(vnode,parentComponent,parentSuspense,internals,doRemove):dynamicChildren&&!dynamicChildren.hasOnce&&(type!==Fragment||patchFlag>0&&patchFlag&64)?unmountChildren(dynamicChildren,parentComponent,parentSuspense,!1,!0):(type===Fragment&&patchFlag&384||!optimized&&shapeFlag&16)&&unmountChildren(children,parentComponent,parentSuspense),doRemove&&remove$3(vnode)}(shouldInvokeVnodeHook&&(vnodeHook=props&&props.onVnodeUnmounted)||shouldInvokeDirs)&&queuePostRenderEffect(()=>{vnodeHook&&invokeVNodeHook(vnodeHook,parentComponent,vnode),shouldInvokeDirs&&invokeDirectiveHook(vnode,null,parentComponent,`unmounted`)},parentSuspense)},remove$3=vnode=>{let{type,el,anchor,transition}=vnode;if(type===Fragment){removeFragment(el,anchor);return}if(type===Static){removeStaticNode(vnode);return}let performRemove=()=>{hostRemove(el),transition&&!transition.persisted&&transition.afterLeave&&transition.afterLeave()};if(vnode.shapeFlag&1&&transition&&!transition.persisted){let{leave,delayLeave}=transition,performLeave=()=>leave(el,performRemove);delayLeave?delayLeave(vnode.el,performRemove,performLeave):performLeave()}else performRemove()},removeFragment=(cur,end)=>{let next;for(;cur!==end;)next=hostNextSibling(cur),hostRemove(cur),cur=next;hostRemove(end)},unmountComponent=(instance$1,parentSuspense,doRemove)=>{let{bum,scope:scope$1,job,subTree,um,m,a:a$1}=instance$1;invalidateMount(m),invalidateMount(a$1),bum&&invokeArrayFns(bum),scope$1.stop(),job&&(job.flags|=8,unmount(subTree,instance$1,parentSuspense,doRemove)),um&&queuePostRenderEffect(um,parentSuspense),queuePostRenderEffect(()=>{instance$1.isUnmounted=!0},parentSuspense)},unmountChildren=(children,parentComponent,parentSuspense,doRemove=!1,optimized=!1,start=0)=>{for(let i=start;i{if(vnode.shapeFlag&6)return getNextHostNode(vnode.component.subTree);if(vnode.shapeFlag&128)return vnode.suspense.next();let el=hostNextSibling(vnode.anchor||vnode.el),teleportEnd=el&&el[TeleportEndKey];return teleportEnd?hostNextSibling(teleportEnd):el},isFlushing=!1,render$1=(vnode,container,namespace)=>{vnode==null?container._vnode&&unmount(container._vnode,null,null,!0):patch(container._vnode||null,vnode,container,null,null,null,namespace),container._vnode=vnode,isFlushing||=(isFlushing=!0,flushPreFlushCbs(),flushPostFlushCbs(),!1)},internals={p:patch,um:unmount,m:move,r:remove$3,mt:mountComponent,mc:mountChildren,pc:patchChildren,pbc:patchBlockChildren,n:getNextHostNode,o:options},hydrate$1,hydrateNode;return createHydrationFns&&([hydrate$1,hydrateNode]=createHydrationFns(internals)),{render:render$1,hydrate:hydrate$1,createApp:createAppAPI(render$1,hydrate$1)}}function resolveChildrenNamespace({type,props},currentNamespace){return currentNamespace===`svg`&&type===`foreignObject`||currentNamespace===`mathml`&&type===`annotation-xml`&&props&&props.encoding&&props.encoding.includes(`html`)?void 0:currentNamespace}function toggleRecurse({effect:effect$1,job},allowed){allowed?(effect$1.flags|=32,job.flags|=4):(effect$1.flags&=-33,job.flags&=-5)}function needTransition(parentSuspense,transition){return(!parentSuspense||parentSuspense&&!parentSuspense.pendingBranch)&&transition&&!transition.persisted}function traverseStaticChildren(n1,n2,shallow=!1){let ch1=n1.children,ch2=n2.children;if(isArray$2(ch1)&&isArray$2(ch2))for(let i=0;i>1,arr[result[c]]0&&(p$1[i]=result[u-1]),result[u]=i)}}for(u=result.length,v=result[u-1];u-- >0;)result[u]=v,v=p$1[v];return result}function locateNonHydratedAsyncRoot(instance$1){let subComponent=instance$1.subTree.component;if(subComponent)return subComponent.asyncDep&&!subComponent.asyncResolved?subComponent:locateNonHydratedAsyncRoot(subComponent)}function invalidateMount(hooks){if(hooks)for(let i=0;iinject(ssrContextKey);function watchEffect(effect$1,options){return doWatch(effect$1,null,options)}function watchPostEffect(effect$1,options){return doWatch(effect$1,null,{flush:`post`})}function watchSyncEffect(effect$1,options){return doWatch(effect$1,null,{flush:`sync`})}function watch(source,cb,options){return doWatch(source,cb,options)}function doWatch(source,cb,options=EMPTY_OBJ){let{immediate,deep,flush,once}=options,baseWatchOptions=extend({},options),runsImmediately=cb&&immediate||!cb&&flush!==`post`,ssrCleanup;if(isInSSRComponentSetup){if(flush===`sync`){let ctx=useSSRContext();ssrCleanup=ctx.__watcherHandles||=[]}else if(!runsImmediately){let watchStopHandle=()=>{};return watchStopHandle.stop=NOOP,watchStopHandle.resume=NOOP,watchStopHandle.pause=NOOP,watchStopHandle}}let instance$1=currentInstance;baseWatchOptions.call=(fn,type,args)=>callWithAsyncErrorHandling(fn,instance$1,type,args);let isPre=!1;flush===`post`?baseWatchOptions.scheduler=job=>{queuePostRenderEffect(job,instance$1&&instance$1.suspense)}:flush!==`sync`&&(isPre=!0,baseWatchOptions.scheduler=(job,isFirstRun)=>{isFirstRun?job():queueJob(job)}),baseWatchOptions.augmentJob=job=>{cb&&(job.flags|=4),isPre&&(job.flags|=2,instance$1&&(job.id=instance$1.uid,job.i=instance$1))};let watchHandle=watch$1(source,cb,baseWatchOptions);return isInSSRComponentSetup&&(ssrCleanup?ssrCleanup.push(watchHandle):runsImmediately&&watchHandle()),watchHandle}function instanceWatch(source,value,options){let publicThis=this.proxy,getter=isString$1(source)?source.includes(`.`)?createPathGetter(publicThis,source):()=>publicThis[source]:source.bind(publicThis,publicThis),cb;isFunction$1(value)?cb=value:(cb=value.handler,options=value);let reset$1=setCurrentInstance(this),res=doWatch(getter,cb.bind(publicThis),options);return reset$1(),res}function createPathGetter(ctx,path){let segments=path.split(`.`);return()=>{let cur=ctx;for(let i=0;i{let localValue,prevSetValue=EMPTY_OBJ,prevEmittedValue;return watchSyncEffect(()=>{let propValue=props[camelizedName];hasChanged(localValue,propValue)&&(localValue=propValue,trigger$2())}),{get(){return track$1(),options.get?options.get(localValue):localValue},set(value){let emittedValue=options.set?options.set(value):value;if(!hasChanged(emittedValue,localValue)&&!(prevSetValue!==EMPTY_OBJ&&hasChanged(value,prevSetValue)))return;let rawProps=i.vnode.props;rawProps&&(name in rawProps||camelizedName in rawProps||hyphenatedName in rawProps)&&(`onUpdate:${name}`in rawProps||`onUpdate:${camelizedName}`in rawProps||`onUpdate:${hyphenatedName}`in rawProps)||(localValue=value,trigger$2()),i.emit(`update:${name}`,emittedValue),hasChanged(value,emittedValue)&&hasChanged(value,prevSetValue)&&!hasChanged(emittedValue,prevEmittedValue)&&trigger$2(),prevSetValue=value,prevEmittedValue=emittedValue}}});return res[Symbol.iterator]=()=>{let i2=0;return{next(){return i2<2?{value:i2++?modifiers||EMPTY_OBJ:res,done:!1}:{done:!0}}}},res}var getModelModifiers=(props,modelName)=>modelName===`modelValue`||modelName===`model-value`?props.modelModifiers:props[`${modelName}Modifiers`]||props[`${camelize(modelName)}Modifiers`]||props[`${hyphenate(modelName)}Modifiers`];function emit(instance$1,event,...rawArgs){if(instance$1.isUnmounted)return;let props=instance$1.vnode.props||EMPTY_OBJ,args=rawArgs,isModelListener$1=event.startsWith(`update:`),modifiers=isModelListener$1&&getModelModifiers(props,event.slice(7));modifiers&&(modifiers.trim&&(args=rawArgs.map(a$1=>isString$1(a$1)?a$1.trim():a$1)),modifiers.number&&(args=rawArgs.map(looseToNumber)));let handlerName,handler$1=props[handlerName=toHandlerKey(event)]||props[handlerName=toHandlerKey(camelize(event))];!handler$1&&isModelListener$1&&(handler$1=props[handlerName=toHandlerKey(hyphenate(event))]),handler$1&&callWithAsyncErrorHandling(handler$1,instance$1,6,args);let onceHandler=props[handlerName+`Once`];if(onceHandler){if(!instance$1.emitted)instance$1.emitted={};else if(instance$1.emitted[handlerName])return;instance$1.emitted[handlerName]=!0,callWithAsyncErrorHandling(onceHandler,instance$1,6,args)}}var mixinEmitsCache=new WeakMap;function normalizeEmitsOptions(comp,appContext,asMixin=!1){let cache$1=asMixin?mixinEmitsCache:appContext.emitsCache,cached=cache$1.get(comp);if(cached!==void 0)return cached;let raw=comp.emits,normalized={},hasExtends=!1;if(!isFunction$1(comp)){let extendEmits=raw2=>{let normalizedFromExtend=normalizeEmitsOptions(raw2,appContext,!0);normalizedFromExtend&&(hasExtends=!0,extend(normalized,normalizedFromExtend))};!asMixin&&appContext.mixins.length&&appContext.mixins.forEach(extendEmits),comp.extends&&extendEmits(comp.extends),comp.mixins&&comp.mixins.forEach(extendEmits)}return!raw&&!hasExtends?(isObject$1(comp)&&cache$1.set(comp,null),null):(isArray$2(raw)?raw.forEach(key=>normalized[key]=null):extend(normalized,raw),isObject$1(comp)&&cache$1.set(comp,normalized),normalized)}function isEmitListener(options,key){return!options||!isOn(key)?!1:(key=key.slice(2).replace(/Once$/,``),hasOwn$1(options,key[0].toLowerCase()+key.slice(1))||hasOwn$1(options,hyphenate(key))||hasOwn$1(options,key))}function renderComponentRoot(instance$1){let{type:Component,vnode,proxy,withProxy,propsOptions:[propsOptions],slots,attrs,emit:emit$1,render:render$1,renderCache,props,data,setupState,ctx,inheritAttrs}=instance$1,prev=setCurrentRenderingInstance(instance$1),result,fallthroughAttrs;try{if(vnode.shapeFlag&4){let proxyToUse=withProxy||proxy,thisProxy=proxyToUse;result=normalizeVNode(render$1.call(thisProxy,proxyToUse,renderCache,props,setupState,data,ctx)),fallthroughAttrs=attrs}else{let render2=Component;result=normalizeVNode(render2.length>1?render2(props,{attrs,slots,emit:emit$1}):render2(props,null)),fallthroughAttrs=Component.props?attrs:getFunctionalFallthrough(attrs)}}catch(err){blockStack.length=0,handleError(err,instance$1,1),result=createVNode(Comment)}let root=result;if(fallthroughAttrs&&inheritAttrs!==!1){let keys=Object.keys(fallthroughAttrs),{shapeFlag}=root;keys.length&&shapeFlag&7&&(propsOptions&&keys.some(isModelListener)&&(fallthroughAttrs=filterModelListeners(fallthroughAttrs,propsOptions)),root=cloneVNode(root,fallthroughAttrs,!1,!0))}return vnode.dirs&&(root=cloneVNode(root,null,!1,!0),root.dirs=root.dirs?root.dirs.concat(vnode.dirs):vnode.dirs),vnode.transition&&setTransitionHooks(root,vnode.transition),result=root,setCurrentRenderingInstance(prev),result}function filterSingleRoot(children,recurse=!0){let singleRoot;for(let i=0;i{let res;for(let key in attrs)(key===`class`||key===`style`||isOn(key))&&((res||={})[key]=attrs[key]);return res},filterModelListeners=(attrs,props)=>{let res={};for(let key in attrs)(!isModelListener(key)||!(key.slice(9)in props))&&(res[key]=attrs[key]);return res};function shouldUpdateComponent(prevVNode,nextVNode,optimized){let{props:prevProps,children:prevChildren,component}=prevVNode,{props:nextProps,children:nextChildren,patchFlag}=nextVNode,emits=component.emitsOptions;if(nextVNode.dirs||nextVNode.transition)return!0;if(optimized&&patchFlag>=0){if(patchFlag&1024)return!0;if(patchFlag&16)return prevProps?hasPropsChanged(prevProps,nextProps,emits):!!nextProps;if(patchFlag&8){let dynamicProps=nextVNode.dynamicProps;for(let i=0;itype.__isSuspense,suspenseId=0,Suspense={name:`Suspense`,__isSuspense:!0,process(n1,n2,container,anchor,parentComponent,parentSuspense,namespace,slotScopeIds,optimized,rendererInternals){if(n1==null)mountSuspense(n2,container,anchor,parentComponent,parentSuspense,namespace,slotScopeIds,optimized,rendererInternals);else{if(parentSuspense&&parentSuspense.deps>0&&!n1.suspense.isInFallback){n2.suspense=n1.suspense,n2.suspense.vnode=n2,n2.el=n1.el;return}patchSuspense(n1,n2,container,anchor,parentComponent,namespace,slotScopeIds,optimized,rendererInternals)}},hydrate:hydrateSuspense,normalize:normalizeSuspenseChildren};function triggerEvent(vnode,name){let eventListener=vnode.props&&vnode.props[name];isFunction$1(eventListener)&&eventListener()}function mountSuspense(vnode,container,anchor,parentComponent,parentSuspense,namespace,slotScopeIds,optimized,rendererInternals){let{p:patch,o:{createElement}}=rendererInternals,hiddenContainer=createElement(`div`),suspense=vnode.suspense=createSuspenseBoundary(vnode,parentSuspense,parentComponent,container,hiddenContainer,anchor,namespace,slotScopeIds,optimized,rendererInternals);patch(null,suspense.pendingBranch=vnode.ssContent,hiddenContainer,null,parentComponent,suspense,namespace,slotScopeIds),suspense.deps>0?(triggerEvent(vnode,`onPending`),triggerEvent(vnode,`onFallback`),patch(null,vnode.ssFallback,container,anchor,parentComponent,null,namespace,slotScopeIds),setActiveBranch(suspense,vnode.ssFallback)):suspense.resolve(!1,!0)}function patchSuspense(n1,n2,container,anchor,parentComponent,namespace,slotScopeIds,optimized,{p:patch,um:unmount,o:{createElement}}){let suspense=n2.suspense=n1.suspense;suspense.vnode=n2,n2.el=n1.el;let newBranch=n2.ssContent,newFallback=n2.ssFallback,{activeBranch,pendingBranch,isInFallback,isHydrating}=suspense;if(pendingBranch)suspense.pendingBranch=newBranch,isSameVNodeType(pendingBranch,newBranch)?(patch(pendingBranch,newBranch,suspense.hiddenContainer,null,parentComponent,suspense,namespace,slotScopeIds,optimized),suspense.deps<=0?suspense.resolve():isInFallback&&(isHydrating||(patch(activeBranch,newFallback,container,anchor,parentComponent,null,namespace,slotScopeIds,optimized),setActiveBranch(suspense,newFallback)))):(suspense.pendingId=suspenseId++,isHydrating?(suspense.isHydrating=!1,suspense.activeBranch=pendingBranch):unmount(pendingBranch,parentComponent,suspense),suspense.deps=0,suspense.effects.length=0,suspense.hiddenContainer=createElement(`div`),isInFallback?(patch(null,newBranch,suspense.hiddenContainer,null,parentComponent,suspense,namespace,slotScopeIds,optimized),suspense.deps<=0?suspense.resolve():(patch(activeBranch,newFallback,container,anchor,parentComponent,null,namespace,slotScopeIds,optimized),setActiveBranch(suspense,newFallback))):activeBranch&&isSameVNodeType(activeBranch,newBranch)?(patch(activeBranch,newBranch,container,anchor,parentComponent,suspense,namespace,slotScopeIds,optimized),suspense.resolve(!0)):(patch(null,newBranch,suspense.hiddenContainer,null,parentComponent,suspense,namespace,slotScopeIds,optimized),suspense.deps<=0&&suspense.resolve()));else if(activeBranch&&isSameVNodeType(activeBranch,newBranch))patch(activeBranch,newBranch,container,anchor,parentComponent,suspense,namespace,slotScopeIds,optimized),setActiveBranch(suspense,newBranch);else if(triggerEvent(n2,`onPending`),suspense.pendingBranch=newBranch,newBranch.shapeFlag&512?suspense.pendingId=newBranch.component.suspenseId:suspense.pendingId=suspenseId++,patch(null,newBranch,suspense.hiddenContainer,null,parentComponent,suspense,namespace,slotScopeIds,optimized),suspense.deps<=0)suspense.resolve();else{let{timeout,pendingId}=suspense;timeout>0?setTimeout(()=>{suspense.pendingId===pendingId&&suspense.fallback(newFallback)},timeout):timeout===0&&suspense.fallback(newFallback)}}function createSuspenseBoundary(vnode,parentSuspense,parentComponent,container,hiddenContainer,anchor,namespace,slotScopeIds,optimized,rendererInternals,isHydrating=!1){let{p:patch,m:move,um:unmount,n:next,o:{parentNode,remove:remove$3}}=rendererInternals,parentSuspenseId,isSuspensible=isVNodeSuspensible(vnode);isSuspensible&&parentSuspense&&parentSuspense.pendingBranch&&(parentSuspenseId=parentSuspense.pendingId,parentSuspense.deps++);let timeout=vnode.props?toNumber(vnode.props.timeout):void 0,initialAnchor=anchor,suspense={vnode,parent:parentSuspense,parentComponent,namespace,container,hiddenContainer,deps:0,pendingId:suspenseId++,timeout:typeof timeout==`number`?timeout:-1,activeBranch:null,pendingBranch:null,isInFallback:!isHydrating,isHydrating,isUnmounted:!1,effects:[],resolve(resume=!1,sync=!1){let{vnode:vnode2,activeBranch,pendingBranch,pendingId,effects,parentComponent:parentComponent2,container:container2}=suspense,delayEnter=!1;suspense.isHydrating?suspense.isHydrating=!1:resume||(delayEnter=activeBranch&&pendingBranch.transition&&pendingBranch.transition.mode===`out-in`,delayEnter&&(activeBranch.transition.afterLeave=()=>{pendingId===suspense.pendingId&&(move(pendingBranch,container2,anchor===initialAnchor?next(activeBranch):anchor,0),queuePostFlushCb(effects))}),activeBranch&&(parentNode(activeBranch.el)===container2&&(anchor=next(activeBranch)),unmount(activeBranch,parentComponent2,suspense,!0)),delayEnter||move(pendingBranch,container2,anchor,0)),setActiveBranch(suspense,pendingBranch),suspense.pendingBranch=null,suspense.isInFallback=!1;let parent=suspense.parent,hasUnresolvedAncestor=!1;for(;parent;){if(parent.pendingBranch){parent.effects.push(...effects),hasUnresolvedAncestor=!0;break}parent=parent.parent}!hasUnresolvedAncestor&&!delayEnter&&queuePostFlushCb(effects),suspense.effects=[],isSuspensible&&parentSuspense&&parentSuspense.pendingBranch&&parentSuspenseId===parentSuspense.pendingId&&(parentSuspense.deps--,parentSuspense.deps===0&&!sync&&parentSuspense.resolve()),triggerEvent(vnode2,`onResolve`)},fallback(fallbackVNode){if(!suspense.pendingBranch)return;let{vnode:vnode2,activeBranch,parentComponent:parentComponent2,container:container2,namespace:namespace2}=suspense;triggerEvent(vnode2,`onFallback`);let anchor2=next(activeBranch),mountFallback=()=>{suspense.isInFallback&&(patch(null,fallbackVNode,container2,anchor2,parentComponent2,null,namespace2,slotScopeIds,optimized),setActiveBranch(suspense,fallbackVNode))},delayEnter=fallbackVNode.transition&&fallbackVNode.transition.mode===`out-in`;delayEnter&&(activeBranch.transition.afterLeave=mountFallback),suspense.isInFallback=!0,unmount(activeBranch,parentComponent2,null,!0),delayEnter||mountFallback()},move(container2,anchor2,type){suspense.activeBranch&&move(suspense.activeBranch,container2,anchor2,type),suspense.container=container2},next(){return suspense.activeBranch&&next(suspense.activeBranch)},registerDep(instance$1,setupRenderEffect,optimized2){let isInPendingSuspense=!!suspense.pendingBranch;isInPendingSuspense&&suspense.deps++;let hydratedEl=instance$1.vnode.el;instance$1.asyncDep.catch(err=>{handleError(err,instance$1,0)}).then(asyncSetupResult=>{if(instance$1.isUnmounted||suspense.isUnmounted||suspense.pendingId!==instance$1.suspenseId)return;instance$1.asyncResolved=!0;let{vnode:vnode2}=instance$1;handleSetupResult(instance$1,asyncSetupResult,!1),hydratedEl&&(vnode2.el=hydratedEl);let placeholder=!hydratedEl&&instance$1.subTree.el;setupRenderEffect(instance$1,vnode2,parentNode(hydratedEl||instance$1.subTree.el),hydratedEl?null:next(instance$1.subTree),suspense,namespace,optimized2),placeholder&&remove$3(placeholder),updateHOCHostEl(instance$1,vnode2.el),isInPendingSuspense&&--suspense.deps===0&&suspense.resolve()})},unmount(parentSuspense2,doRemove){suspense.isUnmounted=!0,suspense.activeBranch&&unmount(suspense.activeBranch,parentComponent,parentSuspense2,doRemove),suspense.pendingBranch&&unmount(suspense.pendingBranch,parentComponent,parentSuspense2,doRemove)}};return suspense}function hydrateSuspense(node,vnode,parentComponent,parentSuspense,namespace,slotScopeIds,optimized,rendererInternals,hydrateNode){let suspense=vnode.suspense=createSuspenseBoundary(vnode,parentSuspense,parentComponent,node.parentNode,document.createElement(`div`),null,namespace,slotScopeIds,optimized,rendererInternals,!0),result=hydrateNode(node,suspense.pendingBranch=vnode.ssContent,parentComponent,suspense,slotScopeIds,optimized);return suspense.deps===0&&suspense.resolve(!1,!0),result}function normalizeSuspenseChildren(vnode){let{shapeFlag,children}=vnode,isSlotChildren=shapeFlag&32;vnode.ssContent=normalizeSuspenseSlot(isSlotChildren?children.default:children),vnode.ssFallback=isSlotChildren?normalizeSuspenseSlot(children.fallback):createVNode(Comment)}function normalizeSuspenseSlot(s){let block;if(isFunction$1(s)){let trackBlock=isBlockTreeEnabled&&s._c;trackBlock&&(s._d=!1,openBlock()),s=s(),trackBlock&&(s._d=!0,block=currentBlock,closeBlock())}return isArray$2(s)&&(s=filterSingleRoot(s)),s=normalizeVNode(s),block&&!s.dynamicChildren&&(s.dynamicChildren=block.filter(c=>c!==s)),s}function queueEffectWithSuspense(fn,suspense){suspense&&suspense.pendingBranch?isArray$2(fn)?suspense.effects.push(...fn):suspense.effects.push(fn):queuePostFlushCb(fn)}function setActiveBranch(suspense,branch){suspense.activeBranch=branch;let{vnode,parentComponent}=suspense,el=branch.el;for(;!el&&branch.component;)branch=branch.component.subTree,el=branch.el;vnode.el=el,parentComponent&&parentComponent.subTree===vnode&&(parentComponent.vnode.el=el,updateHOCHostEl(parentComponent,el))}function isVNodeSuspensible(vnode){let suspensible=vnode.props&&vnode.props.suspensible;return suspensible!=null&&suspensible!==!1}var Fragment=Symbol.for(`v-fgt`),Text=Symbol.for(`v-txt`),Comment=Symbol.for(`v-cmt`),Static=Symbol.for(`v-stc`),blockStack=[],currentBlock=null;function openBlock(disableTracking=!1){blockStack.push(currentBlock=disableTracking?null:[])}function closeBlock(){blockStack.pop(),currentBlock=blockStack[blockStack.length-1]||null}var isBlockTreeEnabled=1;function setBlockTracking(value,inVOnce=!1){isBlockTreeEnabled+=value,value<0&¤tBlock&&inVOnce&&(currentBlock.hasOnce=!0)}function setupBlock(vnode){return vnode.dynamicChildren=isBlockTreeEnabled>0?currentBlock||EMPTY_ARR:null,closeBlock(),isBlockTreeEnabled>0&¤tBlock&¤tBlock.push(vnode),vnode}function createElementBlock(type,props,children,patchFlag,dynamicProps,shapeFlag){return setupBlock(createBaseVNode(type,props,children,patchFlag,dynamicProps,shapeFlag,!0))}function createBlock(type,props,children,patchFlag,dynamicProps){return setupBlock(createVNode(type,props,children,patchFlag,dynamicProps,!0))}function isVNode(value){return value?value.__v_isVNode===!0:!1}function isSameVNodeType(n1,n2){return n1.type===n2.type&&n1.key===n2.key}function transformVNodeArgs(transformer){}var normalizeKey=({key})=>key??null,normalizeRef=({ref:ref$1,ref_key,ref_for})=>(typeof ref$1==`number`&&(ref$1=``+ref$1),ref$1==null?null:isString$1(ref$1)||isRef(ref$1)||isFunction$1(ref$1)?{i:currentRenderingInstance,r:ref$1,k:ref_key,f:!!ref_for}:ref$1);function createBaseVNode(type,props=null,children=null,patchFlag=0,dynamicProps=null,shapeFlag=type===Fragment?0:1,isBlockNode=!1,needFullChildrenNormalization=!1){let vnode={__v_isVNode:!0,__v_skip:!0,type,props,key:props&&normalizeKey(props),ref:props&&normalizeRef(props),scopeId:currentScopeId,slotScopeIds:null,children,component:null,suspense:null,ssContent:null,ssFallback:null,dirs:null,transition:null,el:null,anchor:null,target:null,targetStart:null,targetAnchor:null,staticCount:0,shapeFlag,patchFlag,dynamicProps,dynamicChildren:null,appContext:null,ctx:currentRenderingInstance};return needFullChildrenNormalization?(normalizeChildren(vnode,children),shapeFlag&128&&type.normalize(vnode)):children&&(vnode.shapeFlag|=isString$1(children)?8:16),isBlockTreeEnabled>0&&!isBlockNode&¤tBlock&&(vnode.patchFlag>0||shapeFlag&6)&&vnode.patchFlag!==32&¤tBlock.push(vnode),vnode}var createVNode=_createVNode;function _createVNode(type,props=null,children=null,patchFlag=0,dynamicProps=null,isBlockNode=!1){if((!type||type===NULL_DYNAMIC_COMPONENT)&&(type=Comment),isVNode(type)){let cloned=cloneVNode(type,props,!0);return children&&normalizeChildren(cloned,children),isBlockTreeEnabled>0&&!isBlockNode&¤tBlock&&(cloned.shapeFlag&6?currentBlock[currentBlock.indexOf(type)]=cloned:currentBlock.push(cloned)),cloned.patchFlag=-2,cloned}if(isClassComponent(type)&&(type=type.__vccOpts),props){props=guardReactiveProps(props);let{class:klass,style}=props;klass&&!isString$1(klass)&&(props.class=normalizeClass(klass)),isObject$1(style)&&(isProxy(style)&&!isArray$2(style)&&(style=extend({},style)),props.style=normalizeStyle(style))}let shapeFlag=isString$1(type)?1:isSuspense(type)?128:isTeleport(type)?64:isObject$1(type)?4:isFunction$1(type)?2:0;return createBaseVNode(type,props,children,patchFlag,dynamicProps,shapeFlag,isBlockNode,!0)}function guardReactiveProps(props){return props?isProxy(props)||isInternalObject(props)?extend({},props):props:null}function cloneVNode(vnode,extraProps,mergeRef=!1,cloneTransition=!1){let{props,ref:ref$1,patchFlag,children,transition}=vnode,mergedProps=extraProps?mergeProps(props||{},extraProps):props,cloned={__v_isVNode:!0,__v_skip:!0,type:vnode.type,props:mergedProps,key:mergedProps&&normalizeKey(mergedProps),ref:extraProps&&extraProps.ref?mergeRef&&ref$1?isArray$2(ref$1)?ref$1.concat(normalizeRef(extraProps)):[ref$1,normalizeRef(extraProps)]:normalizeRef(extraProps):ref$1,scopeId:vnode.scopeId,slotScopeIds:vnode.slotScopeIds,children,target:vnode.target,targetStart:vnode.targetStart,targetAnchor:vnode.targetAnchor,staticCount:vnode.staticCount,shapeFlag:vnode.shapeFlag,patchFlag:extraProps&&vnode.type!==Fragment?patchFlag===-1?16:patchFlag|16:patchFlag,dynamicProps:vnode.dynamicProps,dynamicChildren:vnode.dynamicChildren,appContext:vnode.appContext,dirs:vnode.dirs,transition,component:vnode.component,suspense:vnode.suspense,ssContent:vnode.ssContent&&cloneVNode(vnode.ssContent),ssFallback:vnode.ssFallback&&cloneVNode(vnode.ssFallback),placeholder:vnode.placeholder,el:vnode.el,anchor:vnode.anchor,ctx:vnode.ctx,ce:vnode.ce};return transition&&cloneTransition&&setTransitionHooks(cloned,transition.clone(cloned)),cloned}function createTextVNode(text=` `,flag=0){return createVNode(Text,null,text,flag)}function createStaticVNode(content,numberOfNodes){let vnode=createVNode(Static,null,content);return vnode.staticCount=numberOfNodes,vnode}function createCommentVNode(text=``,asBlock=!1){return asBlock?(openBlock(),createBlock(Comment,null,text)):createVNode(Comment,null,text)}function normalizeVNode(child){return child==null||typeof child==`boolean`?createVNode(Comment):isArray$2(child)?createVNode(Fragment,null,child.slice()):isVNode(child)?cloneIfMounted(child):createVNode(Text,null,String(child))}function cloneIfMounted(child){return child.el===null&&child.patchFlag!==-1||child.memo?child:cloneVNode(child)}function normalizeChildren(vnode,children){let type=0,{shapeFlag}=vnode;if(children==null)children=null;else if(isArray$2(children))type=16;else if(typeof children==`object`)if(shapeFlag&65){let slot=children.default;slot&&(slot._c&&(slot._d=!1),normalizeChildren(vnode,slot()),slot._c&&(slot._d=!0));return}else{type=32;let slotFlag=children._;!slotFlag&&!isInternalObject(children)?children._ctx=currentRenderingInstance:slotFlag===3&¤tRenderingInstance&&(currentRenderingInstance.slots._===1?children._=1:(children._=2,vnode.patchFlag|=1024))}else isFunction$1(children)?(children={default:children,_ctx:currentRenderingInstance},type=32):(children=String(children),shapeFlag&64?(type=16,children=[createTextVNode(children)]):type=8);vnode.children=children,vnode.shapeFlag|=type}function mergeProps(...args){let ret={};for(let i=0;icurrentInstance||currentRenderingInstance,internalSetCurrentInstance,setInSSRSetupState;{let g=getGlobalThis$1(),registerGlobalSetter=(key,setter)=>{let setters;return(setters=g[key])||(setters=g[key]=[]),setters.push(setter),v=>{setters.length>1?setters.forEach(set=>set(v)):setters[0](v)}};internalSetCurrentInstance=registerGlobalSetter(`__VUE_INSTANCE_SETTERS__`,v=>currentInstance=v),setInSSRSetupState=registerGlobalSetter(`__VUE_SSR_SETTERS__`,v=>isInSSRComponentSetup=v)}var setCurrentInstance=instance$1=>{let prev=currentInstance;return internalSetCurrentInstance(instance$1),instance$1.scope.on(),()=>{instance$1.scope.off(),internalSetCurrentInstance(prev)}},unsetCurrentInstance=()=>{currentInstance&¤tInstance.scope.off(),internalSetCurrentInstance(null)};function isStatefulComponent(instance$1){return instance$1.vnode.shapeFlag&4}var isInSSRComponentSetup=!1;function setupComponent(instance$1,isSSR=!1,optimized=!1){isSSR&&setInSSRSetupState(isSSR);let{props,children}=instance$1.vnode,isStateful=isStatefulComponent(instance$1);initProps(instance$1,props,isStateful,isSSR),initSlots(instance$1,children,optimized||isSSR);let setupResult=isStateful?setupStatefulComponent(instance$1,isSSR):void 0;return isSSR&&setInSSRSetupState(!1),setupResult}function setupStatefulComponent(instance$1,isSSR){let Component=instance$1.type;instance$1.accessCache=Object.create(null),instance$1.proxy=new Proxy(instance$1.ctx,PublicInstanceProxyHandlers);let{setup:setup$3}=Component;if(setup$3){pauseTracking();let setupContext=instance$1.setupContext=setup$3.length>1?createSetupContext(instance$1):null,reset$1=setCurrentInstance(instance$1),setupResult=callWithErrorHandling(setup$3,instance$1,0,[instance$1.props,setupContext]),isAsyncSetup=isPromise$1(setupResult);if(resetTracking(),reset$1(),(isAsyncSetup||instance$1.sp)&&!isAsyncWrapper(instance$1)&&markAsyncBoundary(instance$1),isAsyncSetup){if(setupResult.then(unsetCurrentInstance,unsetCurrentInstance),isSSR)return setupResult.then(resolvedResult=>{handleSetupResult(instance$1,resolvedResult,isSSR)}).catch(e=>{handleError(e,instance$1,0)});instance$1.asyncDep=setupResult}else handleSetupResult(instance$1,setupResult,isSSR)}else finishComponentSetup(instance$1,isSSR)}function handleSetupResult(instance$1,setupResult,isSSR){isFunction$1(setupResult)?instance$1.type.__ssrInlineRender?instance$1.ssrRender=setupResult:instance$1.render=setupResult:isObject$1(setupResult)&&(instance$1.setupState=proxyRefs(setupResult)),finishComponentSetup(instance$1,isSSR)}var compile$2,installWithProxy;function registerRuntimeCompiler(_compile){compile$2=_compile,installWithProxy=i=>{i.render._rc&&(i.withProxy=new Proxy(i.ctx,RuntimeCompiledPublicInstanceProxyHandlers))}}var isRuntimeOnly=()=>!compile$2;function finishComponentSetup(instance$1,isSSR,skipOptions){let Component=instance$1.type;if(!instance$1.render){if(!isSSR&&compile$2&&!Component.render){let template=Component.template||resolveMergedOptions(instance$1).template;if(template){let{isCustomElement,compilerOptions}=instance$1.appContext.config,{delimiters,compilerOptions:componentCompilerOptions}=Component,finalCompilerOptions=extend(extend({isCustomElement,delimiters},compilerOptions),componentCompilerOptions);Component.render=compile$2(template,finalCompilerOptions)}}instance$1.render=Component.render||NOOP,installWithProxy&&installWithProxy(instance$1)}{let reset$1=setCurrentInstance(instance$1);pauseTracking();try{applyOptions$1(instance$1)}finally{resetTracking(),reset$1()}}}var attrsProxyHandlers={get(target,key){return track(target,`get`,``),target[key]}};function createSetupContext(instance$1){return{attrs:new Proxy(instance$1.attrs,attrsProxyHandlers),slots:instance$1.slots,emit:instance$1.emit,expose:exposed=>{instance$1.exposed=exposed||{}}}}function getComponentPublicInstance(instance$1){return instance$1.exposed?instance$1.exposeProxy||=new Proxy(proxyRefs(markRaw(instance$1.exposed)),{get(target,key){if(key in target)return target[key];if(key in publicPropertiesMap)return publicPropertiesMap[key](instance$1)},has(target,key){return key in target||key in publicPropertiesMap}}):instance$1.proxy}function getComponentName(Component,includeInferred=!0){return isFunction$1(Component)?Component.displayName||Component.name:Component.name||includeInferred&&Component.__name}function isClassComponent(value){return isFunction$1(value)&&`__vccOpts`in value}var computed=(getterOrOptions,debugOptions)=>computed$1(getterOrOptions,debugOptions,isInSSRComponentSetup);function h(type,propsOrChildren,children){try{setBlockTracking(-1);let l=arguments.length;return l===2?isObject$1(propsOrChildren)&&!isArray$2(propsOrChildren)?isVNode(propsOrChildren)?createVNode(type,null,[propsOrChildren]):createVNode(type,propsOrChildren):createVNode(type,null,propsOrChildren):(l>3?children=Array.prototype.slice.call(arguments,2):l===3&&isVNode(children)&&(children=[children]),createVNode(type,propsOrChildren,children))}finally{setBlockTracking(1)}}function initCustomFormatter(){return;function isKeyOfType(Comp,key,type){let opts=Comp[type];if(isArray$2(opts)&&opts.includes(key)||isObject$1(opts)&&key in opts||Comp.extends&&isKeyOfType(Comp.extends,key,type)||Comp.mixins&&Comp.mixins.some(m=>isKeyOfType(m,key,type)))return!0}}function withMemo(memo,render$1,cache$1,index){let cached=cache$1[index];if(cached&&isMemoSame(cached,memo))return cached;let ret=render$1();return ret.memo=memo.slice(),ret.cacheIndex=index,cache$1[index]=ret}function isMemoSame(cached,memo){let prev=cached.memo;if(prev.length!=memo.length)return!1;for(let i=0;i0&¤tBlock&¤tBlock.push(cached),!0}var version$1=`3.5.22`,warn$2=NOOP,ErrorTypeStrings=ErrorTypeStrings$1,devtools$2=devtools$1,setDevtoolsHook=setDevtoolsHook$1,ssrUtils={createComponentInstance,setupComponent,renderComponentRoot,setCurrentRenderingInstance,isVNode,normalizeVNode,getComponentPublicInstance,ensureValidVNode,pushWarningContext,popWarningContext},resolveFilter=null,compatUtils=null,DeprecationTypes=null,runtime_dom_esm_bundler_exports=__export({BaseTransition:()=>BaseTransition,BaseTransitionPropsValidators:()=>BaseTransitionPropsValidators,Comment:()=>Comment,DeprecationTypes:()=>null,EffectScope:()=>EffectScope,ErrorCodes:()=>ErrorCodes,ErrorTypeStrings:()=>ErrorTypeStrings,Fragment:()=>Fragment,KeepAlive:()=>KeepAlive,ReactiveEffect:()=>ReactiveEffect,Static:()=>Static,Suspense:()=>Suspense,Teleport:()=>Teleport,Text:()=>Text,TrackOpTypes:()=>TrackOpTypes,Transition:()=>Transition,TransitionGroup:()=>TransitionGroup,TriggerOpTypes:()=>TriggerOpTypes,VueElement:()=>VueElement,assertNumber:()=>assertNumber,callWithAsyncErrorHandling:()=>callWithAsyncErrorHandling,callWithErrorHandling:()=>callWithErrorHandling,camelize:()=>camelize,capitalize:()=>capitalize$1,cloneVNode:()=>cloneVNode,compatUtils:()=>null,computed:()=>computed,createApp:()=>createApp,createBlock:()=>createBlock,createCommentVNode:()=>createCommentVNode,createElementBlock:()=>createElementBlock,createElementVNode:()=>createBaseVNode,createHydrationRenderer:()=>createHydrationRenderer,createPropsRestProxy:()=>createPropsRestProxy,createRenderer:()=>createRenderer,createSSRApp:()=>createSSRApp,createSlots:()=>createSlots,createStaticVNode:()=>createStaticVNode,createTextVNode:()=>createTextVNode,createVNode:()=>createVNode,customRef:()=>customRef,defineAsyncComponent:()=>defineAsyncComponent,defineComponent:()=>defineComponent,defineCustomElement:()=>defineCustomElement,defineEmits:()=>defineEmits,defineExpose:()=>defineExpose,defineModel:()=>defineModel,defineOptions:()=>defineOptions,defineProps:()=>defineProps,defineSSRCustomElement:()=>defineSSRCustomElement,defineSlots:()=>defineSlots,devtools:()=>devtools$2,effect:()=>effect,effectScope:()=>effectScope,getCurrentInstance:()=>getCurrentInstance,getCurrentScope:()=>getCurrentScope,getCurrentWatcher:()=>getCurrentWatcher,getTransitionRawChildren:()=>getTransitionRawChildren,guardReactiveProps:()=>guardReactiveProps,h:()=>h,handleError:()=>handleError,hasInjectionContext:()=>hasInjectionContext,hydrate:()=>hydrate,hydrateOnIdle:()=>hydrateOnIdle,hydrateOnInteraction:()=>hydrateOnInteraction,hydrateOnMediaQuery:()=>hydrateOnMediaQuery,hydrateOnVisible:()=>hydrateOnVisible,initCustomFormatter:()=>initCustomFormatter,initDirectivesForSSR:()=>initDirectivesForSSR,inject:()=>inject,isMemoSame:()=>isMemoSame,isProxy:()=>isProxy,isReactive:()=>isReactive,isReadonly:()=>isReadonly,isRef:()=>isRef,isRuntimeOnly:()=>isRuntimeOnly,isShallow:()=>isShallow,isVNode:()=>isVNode,markRaw:()=>markRaw,mergeDefaults:()=>mergeDefaults,mergeModels:()=>mergeModels,mergeProps:()=>mergeProps,nextTick:()=>nextTick,normalizeClass:()=>normalizeClass,normalizeProps:()=>normalizeProps,normalizeStyle:()=>normalizeStyle,onActivated:()=>onActivated,onBeforeMount:()=>onBeforeMount,onBeforeUnmount:()=>onBeforeUnmount,onBeforeUpdate:()=>onBeforeUpdate,onDeactivated:()=>onDeactivated,onErrorCaptured:()=>onErrorCaptured,onMounted:()=>onMounted,onRenderTracked:()=>onRenderTracked,onRenderTriggered:()=>onRenderTriggered,onScopeDispose:()=>onScopeDispose,onServerPrefetch:()=>onServerPrefetch,onUnmounted:()=>onUnmounted,onUpdated:()=>onUpdated,onWatcherCleanup:()=>onWatcherCleanup,openBlock:()=>openBlock,popScopeId:()=>popScopeId,provide:()=>provide,proxyRefs:()=>proxyRefs,pushScopeId:()=>pushScopeId,queuePostFlushCb:()=>queuePostFlushCb,reactive:()=>reactive,readonly:()=>readonly,ref:()=>ref,registerRuntimeCompiler:()=>registerRuntimeCompiler,render:()=>render,renderList:()=>renderList,renderSlot:()=>renderSlot,resolveComponent:()=>resolveComponent,resolveDirective:()=>resolveDirective,resolveDynamicComponent:()=>resolveDynamicComponent,resolveFilter:()=>null,resolveTransitionHooks:()=>resolveTransitionHooks,setBlockTracking:()=>setBlockTracking,setDevtoolsHook:()=>setDevtoolsHook,setTransitionHooks:()=>setTransitionHooks,shallowReactive:()=>shallowReactive,shallowReadonly:()=>shallowReadonly,shallowRef:()=>shallowRef,ssrContextKey:()=>ssrContextKey,ssrUtils:()=>ssrUtils,stop:()=>stop,toDisplayString:()=>toDisplayString,toHandlerKey:()=>toHandlerKey,toHandlers:()=>toHandlers,toRaw:()=>toRaw,toRef:()=>toRef,toRefs:()=>toRefs,toValue:()=>toValue$1,transformVNodeArgs:()=>transformVNodeArgs,triggerRef:()=>triggerRef,unref:()=>unref,useAttrs:()=>useAttrs,useCssModule:()=>useCssModule,useCssVars:()=>useCssVars,useHost:()=>useHost,useId:()=>useId,useModel:()=>useModel,useSSRContext:()=>useSSRContext,useShadowRoot:()=>useShadowRoot,useSlots:()=>useSlots,useTemplateRef:()=>useTemplateRef,useTransitionState:()=>useTransitionState,vModelCheckbox:()=>vModelCheckbox,vModelDynamic:()=>vModelDynamic,vModelRadio:()=>vModelRadio,vModelSelect:()=>vModelSelect,vModelText:()=>vModelText,vShow:()=>vShow,version:()=>version$1,warn:()=>warn$2,watch:()=>watch,watchEffect:()=>watchEffect,watchPostEffect:()=>watchPostEffect,watchSyncEffect:()=>watchSyncEffect,withAsyncContext:()=>withAsyncContext,withCtx:()=>withCtx,withDefaults:()=>withDefaults,withDirectives:()=>withDirectives,withKeys:()=>withKeys,withMemo:()=>withMemo,withModifiers:()=>withModifiers,withScopeId:()=>withScopeId}),policy=void 0,tt=typeof window<`u`&&window.trustedTypes;if(tt)try{policy=tt.createPolicy(`vue`,{createHTML:val=>val})}catch{}var unsafeToTrustedHTML=policy?val=>policy.createHTML(val):val=>val,svgNS=`http://www.w3.org/2000/svg`,mathmlNS=`http://www.w3.org/1998/Math/MathML`,doc=typeof document<`u`?document:null,templateContainer=doc&&doc.createElement(`template`),nodeOps={insert:(child,parent,anchor)=>{parent.insertBefore(child,anchor||null)},remove:child=>{let parent=child.parentNode;parent&&parent.removeChild(child)},createElement:(tag,namespace,is,props)=>{let el=namespace===`svg`?doc.createElementNS(svgNS,tag):namespace===`mathml`?doc.createElementNS(mathmlNS,tag):is?doc.createElement(tag,{is}):doc.createElement(tag);return tag===`select`&&props&&props.multiple!=null&&el.setAttribute(`multiple`,props.multiple),el},createText:text=>doc.createTextNode(text),createComment:text=>doc.createComment(text),setText:(node,text)=>{node.nodeValue=text},setElementText:(el,text)=>{el.textContent=text},parentNode:node=>node.parentNode,nextSibling:node=>node.nextSibling,querySelector:selector=>doc.querySelector(selector),setScopeId(el,id){el.setAttribute(id,``)},insertStaticContent(content,parent,anchor,namespace,start,end){let before=anchor?anchor.previousSibling:parent.lastChild;if(start&&(start===end||start.nextSibling))for(;parent.insertBefore(start.cloneNode(!0),anchor),!(start===end||!(start=start.nextSibling)););else{templateContainer.innerHTML=unsafeToTrustedHTML(namespace===`svg`?`${content}`:namespace===`mathml`?`${content}`:content);let template=templateContainer.content;if(namespace===`svg`||namespace===`mathml`){let wrapper=template.firstChild;for(;wrapper.firstChild;)template.appendChild(wrapper.firstChild);template.removeChild(wrapper)}parent.insertBefore(template,anchor)}return[before?before.nextSibling:parent.firstChild,anchor?anchor.previousSibling:parent.lastChild]}},TRANSITION$1=`transition`,ANIMATION=`animation`,vtcKey=Symbol(`_vtc`),DOMTransitionPropsValidators={name:String,type:String,css:{type:Boolean,default:!0},duration:[String,Number,Object],enterFromClass:String,enterActiveClass:String,enterToClass:String,appearFromClass:String,appearActiveClass:String,appearToClass:String,leaveFromClass:String,leaveActiveClass:String,leaveToClass:String},TransitionPropsValidators=extend({},BaseTransitionPropsValidators,DOMTransitionPropsValidators),decorate$1=t=>(t.displayName=`Transition`,t.props=TransitionPropsValidators,t),Transition=decorate$1((props,{slots})=>h(BaseTransition,resolveTransitionProps(props),slots)),callHook=(hook,args=[])=>{isArray$2(hook)?hook.forEach(h2=>h2(...args)):hook&&hook(...args)},hasExplicitCallback=hook=>hook?isArray$2(hook)?hook.some(h2=>h2.length>1):hook.length>1:!1;function resolveTransitionProps(rawProps){let baseProps={};for(let key in rawProps)key in DOMTransitionPropsValidators||(baseProps[key]=rawProps[key]);if(rawProps.css===!1)return baseProps;let{name=`v`,type,duration,enterFromClass=`${name}-enter-from`,enterActiveClass=`${name}-enter-active`,enterToClass=`${name}-enter-to`,appearFromClass=enterFromClass,appearActiveClass=enterActiveClass,appearToClass=enterToClass,leaveFromClass=`${name}-leave-from`,leaveActiveClass=`${name}-leave-active`,leaveToClass=`${name}-leave-to`}=rawProps,durations=normalizeDuration(duration),enterDuration=durations&&durations[0],leaveDuration=durations&&durations[1],{onBeforeEnter,onEnter,onEnterCancelled,onLeave,onLeaveCancelled,onBeforeAppear=onBeforeEnter,onAppear=onEnter,onAppearCancelled=onEnterCancelled}=baseProps,finishEnter=(el,isAppear,done,isCancelled)=>{el._enterCancelled=isCancelled,removeTransitionClass(el,isAppear?appearToClass:enterToClass),removeTransitionClass(el,isAppear?appearActiveClass:enterActiveClass),done&&done()},finishLeave=(el,done)=>{el._isLeaving=!1,removeTransitionClass(el,leaveFromClass),removeTransitionClass(el,leaveToClass),removeTransitionClass(el,leaveActiveClass),done&&done()},makeEnterHook=isAppear=>(el,done)=>{let hook=isAppear?onAppear:onEnter,resolve$1=()=>finishEnter(el,isAppear,done);callHook(hook,[el,resolve$1]),nextFrame(()=>{removeTransitionClass(el,isAppear?appearFromClass:enterFromClass),addTransitionClass(el,isAppear?appearToClass:enterToClass),hasExplicitCallback(hook)||whenTransitionEnds(el,type,enterDuration,resolve$1)})};return extend(baseProps,{onBeforeEnter(el){callHook(onBeforeEnter,[el]),addTransitionClass(el,enterFromClass),addTransitionClass(el,enterActiveClass)},onBeforeAppear(el){callHook(onBeforeAppear,[el]),addTransitionClass(el,appearFromClass),addTransitionClass(el,appearActiveClass)},onEnter:makeEnterHook(!1),onAppear:makeEnterHook(!0),onLeave(el,done){el._isLeaving=!0;let resolve$1=()=>finishLeave(el,done);addTransitionClass(el,leaveFromClass),el._enterCancelled?(addTransitionClass(el,leaveActiveClass),forceReflow(el)):(forceReflow(el),addTransitionClass(el,leaveActiveClass)),nextFrame(()=>{el._isLeaving&&(removeTransitionClass(el,leaveFromClass),addTransitionClass(el,leaveToClass),hasExplicitCallback(onLeave)||whenTransitionEnds(el,type,leaveDuration,resolve$1))}),callHook(onLeave,[el,resolve$1])},onEnterCancelled(el){finishEnter(el,!1,void 0,!0),callHook(onEnterCancelled,[el])},onAppearCancelled(el){finishEnter(el,!0,void 0,!0),callHook(onAppearCancelled,[el])},onLeaveCancelled(el){finishLeave(el),callHook(onLeaveCancelled,[el])}})}function normalizeDuration(duration){if(duration==null)return null;if(isObject$1(duration))return[NumberOf(duration.enter),NumberOf(duration.leave)];{let n=NumberOf(duration);return[n,n]}}function NumberOf(val){return toNumber(val)}function addTransitionClass(el,cls){cls.split(/\s+/).forEach(c=>c&&el.classList.add(c)),(el[vtcKey]||(el[vtcKey]=new Set)).add(cls)}function removeTransitionClass(el,cls){cls.split(/\s+/).forEach(c=>c&&el.classList.remove(c));let _vtc=el[vtcKey];_vtc&&(_vtc.delete(cls),_vtc.size||(el[vtcKey]=void 0))}function nextFrame(cb){requestAnimationFrame(()=>{requestAnimationFrame(cb)})}var endId=0;function whenTransitionEnds(el,expectedType,explicitTimeout,resolve$1){let id=el._endId=++endId,resolveIfNotStale=()=>{id===el._endId&&resolve$1()};if(explicitTimeout!=null)return setTimeout(resolveIfNotStale,explicitTimeout);let{type,timeout,propCount}=getTransitionInfo(el,expectedType);if(!type)return resolve$1();let endEvent=type+`end`,ended=0,end=()=>{el.removeEventListener(endEvent,onEnd),resolveIfNotStale()},onEnd=e=>{e.target===el&&++ended>=propCount&&end()};setTimeout(()=>{ended(styles[key]||``).split(`, `),transitionDelays=getStyleProperties(`${TRANSITION$1}Delay`),transitionDurations=getStyleProperties(`${TRANSITION$1}Duration`),transitionTimeout=getTimeout(transitionDelays,transitionDurations),animationDelays=getStyleProperties(`${ANIMATION}Delay`),animationDurations=getStyleProperties(`${ANIMATION}Duration`),animationTimeout=getTimeout(animationDelays,animationDurations),type=null,timeout=0,propCount=0;expectedType===TRANSITION$1?transitionTimeout>0&&(type=TRANSITION$1,timeout=transitionTimeout,propCount=transitionDurations.length):expectedType===ANIMATION?animationTimeout>0&&(type=ANIMATION,timeout=animationTimeout,propCount=animationDurations.length):(timeout=Math.max(transitionTimeout,animationTimeout),type=timeout>0?transitionTimeout>animationTimeout?TRANSITION$1:ANIMATION:null,propCount=type?type===TRANSITION$1?transitionDurations.length:animationDurations.length:0);let hasTransform=type===TRANSITION$1&&/\b(?:transform|all)(?:,|$)/.test(getStyleProperties(`${TRANSITION$1}Property`).toString());return{type,timeout,propCount,hasTransform}}function getTimeout(delays,durations){for(;delays.lengthtoMs(d)+toMs(delays[i])))}function toMs(s){return s===`auto`?0:Number(s.slice(0,-1).replace(`,`,`.`))*1e3}function forceReflow(el){return(el?el.ownerDocument:document).body.offsetHeight}function patchClass(el,value,isSVG){let transitionClasses=el[vtcKey];transitionClasses&&(value=(value?[value,...transitionClasses]:[...transitionClasses]).join(` `)),value==null?el.removeAttribute(`class`):isSVG?el.setAttribute(`class`,value):el.className=value}var vShowOriginalDisplay=Symbol(`_vod`),vShowHidden=Symbol(`_vsh`),vShow={name:`show`,beforeMount(el,{value},{transition}){el[vShowOriginalDisplay]=el.style.display===`none`?``:el.style.display,transition&&value?transition.beforeEnter(el):setDisplay(el,value)},mounted(el,{value},{transition}){transition&&value&&transition.enter(el)},updated(el,{value,oldValue},{transition}){!value!=!oldValue&&(transition?value?(transition.beforeEnter(el),setDisplay(el,!0),transition.enter(el)):transition.leave(el,()=>{setDisplay(el,!1)}):setDisplay(el,value))},beforeUnmount(el,{value}){setDisplay(el,value)}};function setDisplay(el,value){el.style.display=value?el[vShowOriginalDisplay]:`none`,el[vShowHidden]=!value}function initVShowForSSR(){vShow.getSSRProps=({value})=>{if(!value)return{style:{display:`none`}}}}var CSS_VAR_TEXT=Symbol(``);function useCssVars(getter){let instance$1=getCurrentInstance();if(!instance$1)return;let updateTeleports=instance$1.ut=(vars=getter(instance$1.proxy))=>{Array.from(document.querySelectorAll(`[data-v-owner="${instance$1.uid}"]`)).forEach(node=>setVarsOnNode(node,vars))},setVars=()=>{let vars=getter(instance$1.proxy);instance$1.ce?setVarsOnNode(instance$1.ce,vars):setVarsOnVNode(instance$1.subTree,vars),updateTeleports(vars)};onBeforeUpdate(()=>{queuePostFlushCb(setVars)}),onMounted(()=>{watch(setVars,NOOP,{flush:`post`});let ob=new MutationObserver(setVars);ob.observe(instance$1.subTree.el.parentNode,{childList:!0}),onUnmounted(()=>ob.disconnect())})}function setVarsOnVNode(vnode,vars){if(vnode.shapeFlag&128){let suspense=vnode.suspense;vnode=suspense.activeBranch,suspense.pendingBranch&&!suspense.isHydrating&&suspense.effects.push(()=>{setVarsOnVNode(suspense.activeBranch,vars)})}for(;vnode.component;)vnode=vnode.component.subTree;if(vnode.shapeFlag&1&&vnode.el)setVarsOnNode(vnode.el,vars);else if(vnode.type===Fragment)vnode.children.forEach(c=>setVarsOnVNode(c,vars));else if(vnode.type===Static){let{el,anchor}=vnode;for(;el&&(setVarsOnNode(el,vars),el!==anchor);)el=el.nextSibling}}function setVarsOnNode(el,vars){if(el.nodeType===1){let style=el.style,cssText=``;for(let key in vars){let value=normalizeCssVarValue(vars[key]);style.setProperty(`--${key}`,value),cssText+=`--${key}: ${value};`}style[CSS_VAR_TEXT]=cssText}}var displayRE=/(?:^|;)\s*display\s*:/;function patchStyle(el,prev,next){let style=el.style,isCssString=isString$1(next),hasControlledDisplay=!1;if(next&&!isCssString){if(prev)if(isString$1(prev))for(let prevStyle of prev.split(`;`)){let key=prevStyle.slice(0,prevStyle.indexOf(`:`)).trim();next[key]??setStyle(style,key,``)}else for(let key in prev)next[key]??setStyle(style,key,``);for(let key in next)key===`display`&&(hasControlledDisplay=!0),setStyle(style,key,next[key])}else if(isCssString){if(prev!==next){let cssVarText=style[CSS_VAR_TEXT];cssVarText&&(next+=`;`+cssVarText),style.cssText=next,hasControlledDisplay=displayRE.test(next)}}else prev&&el.removeAttribute(`style`);vShowOriginalDisplay in el&&(el[vShowOriginalDisplay]=hasControlledDisplay?style.display:``,el[vShowHidden]&&(style.display=`none`))}var importantRE=/\s*!important$/;function setStyle(style,name,val){if(isArray$2(val))val.forEach(v=>setStyle(style,name,v));else if(val??=``,name.startsWith(`--`))style.setProperty(name,val);else{let prefixed=autoPrefix(style,name);importantRE.test(val)?style.setProperty(hyphenate(prefixed),val.replace(importantRE,``),`important`):style[prefixed]=val}}var prefixes=[`Webkit`,`Moz`,`ms`],prefixCache={};function autoPrefix(style,rawName){let cached=prefixCache[rawName];if(cached)return cached;let name=camelize(rawName);if(name!==`filter`&&name in style)return prefixCache[rawName]=name;name=capitalize$1(name);for(let i=0;icachedNow||=(p.then(()=>cachedNow=0),Date.now());function createInvoker(initialValue,instance$1){let invoker=e=>{if(!e._vts)e._vts=Date.now();else if(e._vts<=invoker.attached)return;callWithAsyncErrorHandling(patchStopImmediatePropagation(e,invoker.value),instance$1,5,[e])};return invoker.value=initialValue,invoker.attached=getNow(),invoker}function patchStopImmediatePropagation(e,value){if(isArray$2(value)){let originalStop=e.stopImmediatePropagation;return e.stopImmediatePropagation=()=>{originalStop.call(e),e._stopped=!0},value.map(fn=>e2=>!e2._stopped&&fn&&fn(e2))}else return value}var isNativeOn=key=>key.charCodeAt(0)===111&&key.charCodeAt(1)===110&&key.charCodeAt(2)>96&&key.charCodeAt(2)<123,patchProp=(el,key,prevValue,nextValue,namespace,parentComponent)=>{let isSVG=namespace===`svg`;key===`class`?patchClass(el,nextValue,isSVG):key===`style`?patchStyle(el,prevValue,nextValue):isOn(key)?isModelListener(key)||patchEvent(el,key,prevValue,nextValue,parentComponent):(key[0]===`.`?(key=key.slice(1),!0):key[0]===`^`?(key=key.slice(1),!1):shouldSetAsProp(el,key,nextValue,isSVG))?(patchDOMProp(el,key,nextValue),!el.tagName.includes(`-`)&&(key===`value`||key===`checked`||key===`selected`)&&patchAttr(el,key,nextValue,isSVG,parentComponent,key!==`value`)):el._isVueCE&&(/[A-Z]/.test(key)||!isString$1(nextValue))?patchDOMProp(el,camelize(key),nextValue,parentComponent,key):(key===`true-value`?el._trueValue=nextValue:key===`false-value`&&(el._falseValue=nextValue),patchAttr(el,key,nextValue,isSVG))};function shouldSetAsProp(el,key,value,isSVG){if(isSVG)return!!(key===`innerHTML`||key===`textContent`||key in el&&isNativeOn(key)&&isFunction$1(value));if(key===`spellcheck`||key===`draggable`||key===`translate`||key===`autocorrect`||key===`form`||key===`list`&&el.tagName===`INPUT`||key===`type`&&el.tagName===`TEXTAREA`)return!1;if(key===`width`||key===`height`){let tag=el.tagName;if(tag===`IMG`||tag===`VIDEO`||tag===`CANVAS`||tag===`SOURCE`)return!1}return isNativeOn(key)&&isString$1(value)?!1:key in el}var REMOVAL={};function defineCustomElement(options,extraOptions,_createApp){let Comp=defineComponent(options,extraOptions);isPlainObject$2(Comp)&&(Comp=extend({},Comp,extraOptions));class VueCustomElement extends VueElement{constructor(initialProps){super(Comp,initialProps,_createApp)}}return VueCustomElement.def=Comp,VueCustomElement}var defineSSRCustomElement=((options,extraOptions)=>defineCustomElement(options,extraOptions,createSSRApp)),BaseClass=typeof HTMLElement<`u`?HTMLElement:class{},VueElement=class VueElement extends BaseClass{constructor(_def,_props={},_createApp=createApp){super(),this._def=_def,this._props=_props,this._createApp=_createApp,this._isVueCE=!0,this._instance=null,this._app=null,this._nonce=this._def.nonce,this._connected=!1,this._resolved=!1,this._numberProps=null,this._styleChildren=new WeakSet,this._ob=null,this.shadowRoot&&_createApp!==createApp?this._root=this.shadowRoot:_def.shadowRoot===!1?this._root=this:(this.attachShadow(extend({},_def.shadowRootOptions,{mode:`open`})),this._root=this.shadowRoot)}connectedCallback(){if(!this.isConnected)return;!this.shadowRoot&&!this._resolved&&this._parseSlots(),this._connected=!0;let parent=this;for(;parent&&=parent.parentNode||parent.host;)if(parent instanceof VueElement){this._parent=parent;break}this._instance||(this._resolved?this._mount(this._def):parent&&parent._pendingResolve?this._pendingResolve=parent._pendingResolve.then(()=>{this._pendingResolve=void 0,this._resolveDef()}):this._resolveDef())}_setParent(parent=this._parent){parent&&(this._instance.parent=parent._instance,this._inheritParentContext(parent))}_inheritParentContext(parent=this._parent){parent&&this._app&&Object.setPrototypeOf(this._app._context.provides,parent._instance.provides)}disconnectedCallback(){this._connected=!1,nextTick(()=>{this._connected||(this._ob&&=(this._ob.disconnect(),null),this._app&&this._app.unmount(),this._instance&&(this._instance.ce=void 0),this._app=this._instance=null,this._teleportTargets&&=(this._teleportTargets.clear(),void 0))})}_processMutations(mutations){for(let m of mutations)this._setAttr(m.attributeName)}_resolveDef(){if(this._pendingResolve)return;for(let i=0;i{this._resolved=!0,this._pendingResolve=void 0;let{props,styles}=def$1,numberProps;if(props&&!isArray$2(props))for(let key in props){let opt=props[key];(opt===Number||opt&&opt.type===Number)&&(key in this._props&&(this._props[key]=toNumber(this._props[key])),(numberProps||=Object.create(null))[camelize(key)]=!0)}this._numberProps=numberProps,this._resolveProps(def$1),this.shadowRoot&&this._applyStyles(styles),this._mount(def$1)},asyncDef=this._def.__asyncLoader;asyncDef?this._pendingResolve=asyncDef().then(def$1=>{def$1.configureApp=this._def.configureApp,resolve$1(this._def=def$1,!0)}):resolve$1(this._def)}_mount(def$1){this._app=this._createApp(def$1),this._inheritParentContext(),def$1.configureApp&&def$1.configureApp(this._app),this._app._ceVNode=this._createVNode(),this._app.mount(this._root);let exposed=this._instance&&this._instance.exposed;if(exposed)for(let key in exposed)hasOwn$1(this,key)||Object.defineProperty(this,key,{get:()=>unref(exposed[key])})}_resolveProps(def$1){let{props}=def$1,declaredPropKeys=isArray$2(props)?props:Object.keys(props||{});for(let key of Object.keys(this))key[0]!==`_`&&declaredPropKeys.includes(key)&&this._setProp(key,this[key]);for(let key of declaredPropKeys.map(camelize))Object.defineProperty(this,key,{get(){return this._getProp(key)},set(val){this._setProp(key,val,!0,!0)}})}_setAttr(key){if(key.startsWith(`data-v-`))return;let has$1=this.hasAttribute(key),value=has$1?this.getAttribute(key):REMOVAL,camelKey=camelize(key);has$1&&this._numberProps&&this._numberProps[camelKey]&&(value=toNumber(value)),this._setProp(camelKey,value,!1,!0)}_getProp(key){return this._props[key]}_setProp(key,val,shouldReflect=!0,shouldUpdate=!1){if(val!==this._props[key]&&(val===REMOVAL?delete this._props[key]:(this._props[key]=val,key===`key`&&this._app&&(this._app._ceVNode.key=val)),shouldUpdate&&this._instance&&this._update(),shouldReflect)){let ob=this._ob;ob&&(this._processMutations(ob.takeRecords()),ob.disconnect()),val===!0?this.setAttribute(hyphenate(key),``):typeof val==`string`||typeof val==`number`?this.setAttribute(hyphenate(key),val+``):val||this.removeAttribute(hyphenate(key)),ob&&ob.observe(this,{attributes:!0})}}_update(){let vnode=this._createVNode();this._app&&(vnode.appContext=this._app._context),render(vnode,this._root)}_createVNode(){let baseProps={};this.shadowRoot||(baseProps.onVnodeMounted=baseProps.onVnodeUpdated=this._renderSlots.bind(this));let vnode=createVNode(this._def,extend(baseProps,this._props));return this._instance||(vnode.ce=instance$1=>{this._instance=instance$1,instance$1.ce=this,instance$1.isCE=!0;let dispatch=(event,args)=>{this.dispatchEvent(new CustomEvent(event,isPlainObject$2(args[0])?extend({detail:args},args[0]):{detail:args}))};instance$1.emit=(event,...args)=>{dispatch(event,args),hyphenate(event)!==event&&dispatch(hyphenate(event),args)},this._setParent()}),vnode}_applyStyles(styles,owner){if(!styles)return;if(owner){if(owner===this._def||this._styleChildren.has(owner))return;this._styleChildren.add(owner)}let nonce=this._nonce;for(let i=styles.length-1;i>=0;i--){let s=document.createElement(`style`);nonce&&s.setAttribute(`nonce`,nonce),s.textContent=styles[i],this.shadowRoot.prepend(s)}}_parseSlots(){let slots=this._slots={},n;for(;n=this.firstChild;){let slotName=n.nodeType===1&&n.getAttribute(`slot`)||`default`;(slots[slotName]||(slots[slotName]=[])).push(n),this.removeChild(n)}}_renderSlots(){let outlets=this._getSlots(),scopeId=this._instance.type.__scopeId;for(let i=0;i(res.push(...Array.from(i.querySelectorAll(`slot`))),res),[])}_injectChildStyle(comp){this._applyStyles(comp.styles,comp)}_removeChildStyle(comp){}};function useHost(caller){let instance$1=getCurrentInstance();return instance$1&&instance$1.ce||null}function useShadowRoot(){let el=useHost();return el&&el.shadowRoot}function useCssModule(name=`$style`){{let instance$1=getCurrentInstance();if(!instance$1)return EMPTY_OBJ;let modules=instance$1.type.__cssModules;return modules&&modules[name]||EMPTY_OBJ}}var positionMap=new WeakMap,newPositionMap=new WeakMap,moveCbKey=Symbol(`_moveCb`),enterCbKey=Symbol(`_enterCb`),decorate=t=>(delete t.props.mode,t),TransitionGroup=decorate({name:`TransitionGroup`,props:extend({},TransitionPropsValidators,{tag:String,moveClass:String}),setup(props,{slots}){let instance$1=getCurrentInstance(),state=useTransitionState(),prevChildren,children;return onUpdated(()=>{if(!prevChildren.length)return;let moveClass=props.moveClass||`${props.name||`v`}-move`;if(!hasCSSTransform(prevChildren[0].el,instance$1.vnode.el,moveClass)){prevChildren=[];return}prevChildren.forEach(callPendingCbs),prevChildren.forEach(recordPosition);let movedChildren=prevChildren.filter(applyTranslation);forceReflow(instance$1.vnode.el),movedChildren.forEach(c=>{let el=c.el,style=el.style;addTransitionClass(el,moveClass),style.transform=style.webkitTransform=style.transitionDuration=``;let cb=el[moveCbKey]=e=>{e&&e.target!==el||(!e||e.propertyName.endsWith(`transform`))&&(el.removeEventListener(`transitionend`,cb),el[moveCbKey]=null,removeTransitionClass(el,moveClass))};el.addEventListener(`transitionend`,cb)}),prevChildren=[]}),()=>{let rawProps=toRaw(props),cssTransitionProps=resolveTransitionProps(rawProps),tag=rawProps.tag||Fragment;if(prevChildren=[],children)for(let i=0;i{cls.split(/\s+/).forEach(c=>c&&clone.classList.remove(c))}),moveClass.split(/\s+/).forEach(c=>c&&clone.classList.add(c)),clone.style.display=`none`;let container=root.nodeType===1?root:root.parentNode;container.appendChild(clone);let{hasTransform}=getTransitionInfo(clone);return container.removeChild(clone),hasTransform}var getModelAssigner=vnode=>{let fn=vnode.props[`onUpdate:modelValue`]||!1;return isArray$2(fn)?value=>invokeArrayFns(fn,value):fn};function onCompositionStart(e){e.target.composing=!0}function onCompositionEnd(e){let target=e.target;target.composing&&(target.composing=!1,target.dispatchEvent(new Event(`input`)))}var assignKey=Symbol(`_assign`),vModelText={created(el,{modifiers:{lazy,trim,number}},vnode){el[assignKey]=getModelAssigner(vnode);let castToNumber=number||vnode.props&&vnode.props.type===`number`;addEventListener$1(el,lazy?`change`:`input`,e=>{if(e.target.composing)return;let domValue=el.value;trim&&(domValue=domValue.trim()),castToNumber&&(domValue=looseToNumber(domValue)),el[assignKey](domValue)}),trim&&addEventListener$1(el,`change`,()=>{el.value=el.value.trim()}),lazy||(addEventListener$1(el,`compositionstart`,onCompositionStart),addEventListener$1(el,`compositionend`,onCompositionEnd),addEventListener$1(el,`change`,onCompositionEnd))},mounted(el,{value}){el.value=value??``},beforeUpdate(el,{value,oldValue,modifiers:{lazy,trim,number}},vnode){if(el[assignKey]=getModelAssigner(vnode),el.composing)return;let elValue=(number||el.type===`number`)&&!/^0\d/.test(el.value)?looseToNumber(el.value):el.value,newValue=value??``;elValue!==newValue&&(document.activeElement===el&&el.type!==`range`&&(lazy&&value===oldValue||trim&&el.value.trim()===newValue)||(el.value=newValue))}},vModelCheckbox={deep:!0,created(el,_,vnode){el[assignKey]=getModelAssigner(vnode),addEventListener$1(el,`change`,()=>{let modelValue=el._modelValue,elementValue=getValue(el),checked=el.checked,assign$3=el[assignKey];if(isArray$2(modelValue)){let index=looseIndexOf(modelValue,elementValue),found=index!==-1;if(checked&&!found)assign$3(modelValue.concat(elementValue));else if(!checked&&found){let filtered=[...modelValue];filtered.splice(index,1),assign$3(filtered)}}else if(isSet(modelValue)){let cloned=new Set(modelValue);checked?cloned.add(elementValue):cloned.delete(elementValue),assign$3(cloned)}else assign$3(getCheckboxValue(el,checked))})},mounted:setChecked,beforeUpdate(el,binding,vnode){el[assignKey]=getModelAssigner(vnode),setChecked(el,binding,vnode)}};function setChecked(el,{value,oldValue},vnode){el._modelValue=value;let checked;if(isArray$2(value))checked=looseIndexOf(value,vnode.props.value)>-1;else if(isSet(value))checked=value.has(vnode.props.value);else{if(value===oldValue)return;checked=looseEqual(value,getCheckboxValue(el,!0))}el.checked!==checked&&(el.checked=checked)}var vModelRadio={created(el,{value},vnode){el.checked=looseEqual(value,vnode.props.value),el[assignKey]=getModelAssigner(vnode),addEventListener$1(el,`change`,()=>{el[assignKey](getValue(el))})},beforeUpdate(el,{value,oldValue},vnode){el[assignKey]=getModelAssigner(vnode),value!==oldValue&&(el.checked=looseEqual(value,vnode.props.value))}},vModelSelect={deep:!0,created(el,{value,modifiers:{number}},vnode){let isSetModel=isSet(value);addEventListener$1(el,`change`,()=>{let selectedVal=Array.prototype.filter.call(el.options,o=>o.selected).map(o=>number?looseToNumber(getValue(o)):getValue(o));el[assignKey](el.multiple?isSetModel?new Set(selectedVal):selectedVal:selectedVal[0]),el._assigning=!0,nextTick(()=>{el._assigning=!1})}),el[assignKey]=getModelAssigner(vnode)},mounted(el,{value}){setSelected(el,value)},beforeUpdate(el,_binding,vnode){el[assignKey]=getModelAssigner(vnode)},updated(el,{value}){el._assigning||setSelected(el,value)}};function setSelected(el,value){let isMultiple=el.multiple,isArrayValue=isArray$2(value);if(!(isMultiple&&!isArrayValue&&!isSet(value))){for(let i=0,l=el.options.length;iString(v)===String(optionValue)):option.selected=looseIndexOf(value,optionValue)>-1}else option.selected=value.has(optionValue);else if(looseEqual(getValue(option),value)){el.selectedIndex!==i&&(el.selectedIndex=i);return}}!isMultiple&&el.selectedIndex!==-1&&(el.selectedIndex=-1)}}function getValue(el){return`_value`in el?el._value:el.value}function getCheckboxValue(el,checked){let key=checked?`_trueValue`:`_falseValue`;return key in el?el[key]:checked}var vModelDynamic={created(el,binding,vnode){callModelHook(el,binding,vnode,null,`created`)},mounted(el,binding,vnode){callModelHook(el,binding,vnode,null,`mounted`)},beforeUpdate(el,binding,vnode,prevVNode){callModelHook(el,binding,vnode,prevVNode,`beforeUpdate`)},updated(el,binding,vnode,prevVNode){callModelHook(el,binding,vnode,prevVNode,`updated`)}};function resolveDynamicModel(tagName,type){switch(tagName){case`SELECT`:return vModelSelect;case`TEXTAREA`:return vModelText;default:switch(type){case`checkbox`:return vModelCheckbox;case`radio`:return vModelRadio;default:return vModelText}}}function callModelHook(el,binding,vnode,prevVNode,hook){let fn=resolveDynamicModel(el.tagName,vnode.props&&vnode.props.type)[hook];fn&&fn(el,binding,vnode,prevVNode)}function initVModelForSSR(){vModelText.getSSRProps=({value})=>({value}),vModelRadio.getSSRProps=({value},vnode)=>{if(vnode.props&&looseEqual(vnode.props.value,value))return{checked:!0}},vModelCheckbox.getSSRProps=({value},vnode)=>{if(isArray$2(value)){if(vnode.props&&looseIndexOf(value,vnode.props.value)>-1)return{checked:!0}}else if(isSet(value)){if(vnode.props&&value.has(vnode.props.value))return{checked:!0}}else if(value)return{checked:!0}},vModelDynamic.getSSRProps=(binding,vnode)=>{if(typeof vnode.type!=`string`)return;let modelToUse=resolveDynamicModel(vnode.type.toUpperCase(),vnode.props&&vnode.props.type);if(modelToUse.getSSRProps)return modelToUse.getSSRProps(binding,vnode)}}var systemModifiers=[`ctrl`,`shift`,`alt`,`meta`],modifierGuards={stop:e=>e.stopPropagation(),prevent:e=>e.preventDefault(),self:e=>e.target!==e.currentTarget,ctrl:e=>!e.ctrlKey,shift:e=>!e.shiftKey,alt:e=>!e.altKey,meta:e=>!e.metaKey,left:e=>`button`in e&&e.button!==0,middle:e=>`button`in e&&e.button!==1,right:e=>`button`in e&&e.button!==2,exact:(e,modifiers)=>systemModifiers.some(m=>e[`${m}Key`]&&!modifiers.includes(m))},withModifiers=(fn,modifiers)=>{let cache$1=fn._withMods||={},cacheKey=modifiers.join(`.`);return cache$1[cacheKey]||(cache$1[cacheKey]=((event,...args)=>{for(let i=0;i{let cache$1=fn._withKeys||={},cacheKey=modifiers.join(`.`);return cache$1[cacheKey]||(cache$1[cacheKey]=(event=>{if(!(`key`in event))return;let eventKey=hyphenate(event.key);if(modifiers.some(k=>k===eventKey||keyNames[k]===eventKey))return fn(event)}))},rendererOptions=extend({patchProp},nodeOps),renderer,enabledHydration=!1;function ensureRenderer(){return renderer||=createRenderer(rendererOptions)}function ensureHydrationRenderer(){return renderer=enabledHydration?renderer:createHydrationRenderer(rendererOptions),enabledHydration=!0,renderer}var render=((...args)=>{ensureRenderer().render(...args)}),hydrate=((...args)=>{ensureHydrationRenderer().hydrate(...args)}),createApp=((...args)=>{let app$1=ensureRenderer().createApp(...args),{mount}=app$1;return app$1.mount=containerOrSelector=>{let container=normalizeContainer(containerOrSelector);if(!container)return;let component=app$1._component;!isFunction$1(component)&&!component.render&&!component.template&&(component.template=container.innerHTML),container.nodeType===1&&(container.textContent=``);let proxy=mount(container,!1,resolveRootNamespace(container));return container instanceof Element&&(container.removeAttribute(`v-cloak`),container.setAttribute(`data-v-app`,``)),proxy},app$1}),createSSRApp=((...args)=>{let app$1=ensureHydrationRenderer().createApp(...args),{mount}=app$1;return app$1.mount=containerOrSelector=>{let container=normalizeContainer(containerOrSelector);if(container)return mount(container,!0,resolveRootNamespace(container))},app$1});function resolveRootNamespace(container){if(container instanceof SVGElement)return`svg`;if(typeof MathMLElement==`function`&&container instanceof MathMLElement)return`mathml`}function normalizeContainer(container){return isString$1(container)?document.querySelector(container):container}var ssrDirectiveInitialized=!1,initDirectivesForSSR=()=>{ssrDirectiveInitialized||(ssrDirectiveInitialized=!0,initVModelForSSR(),initVShowForSSR())},FRAGMENT=Symbol(``),TELEPORT=Symbol(``),SUSPENSE=Symbol(``),KEEP_ALIVE=Symbol(``),BASE_TRANSITION=Symbol(``),OPEN_BLOCK=Symbol(``),CREATE_BLOCK=Symbol(``),CREATE_ELEMENT_BLOCK=Symbol(``),CREATE_VNODE=Symbol(``),CREATE_ELEMENT_VNODE=Symbol(``),CREATE_COMMENT=Symbol(``),CREATE_TEXT=Symbol(``),CREATE_STATIC=Symbol(``),RESOLVE_COMPONENT=Symbol(``),RESOLVE_DYNAMIC_COMPONENT=Symbol(``),RESOLVE_DIRECTIVE=Symbol(``),RESOLVE_FILTER=Symbol(``),WITH_DIRECTIVES=Symbol(``),RENDER_LIST=Symbol(``),RENDER_SLOT=Symbol(``),CREATE_SLOTS=Symbol(``),TO_DISPLAY_STRING=Symbol(``),MERGE_PROPS=Symbol(``),NORMALIZE_CLASS=Symbol(``),NORMALIZE_STYLE=Symbol(``),NORMALIZE_PROPS=Symbol(``),GUARD_REACTIVE_PROPS=Symbol(``),TO_HANDLERS=Symbol(``),CAMELIZE=Symbol(``),CAPITALIZE=Symbol(``),TO_HANDLER_KEY=Symbol(``),SET_BLOCK_TRACKING=Symbol(``),PUSH_SCOPE_ID=Symbol(``),POP_SCOPE_ID=Symbol(``),WITH_CTX=Symbol(``),UNREF=Symbol(``),IS_REF=Symbol(``),WITH_MEMO=Symbol(``),IS_MEMO_SAME=Symbol(``),helperNameMap={[FRAGMENT]:`Fragment`,[TELEPORT]:`Teleport`,[SUSPENSE]:`Suspense`,[KEEP_ALIVE]:`KeepAlive`,[BASE_TRANSITION]:`BaseTransition`,[OPEN_BLOCK]:`openBlock`,[CREATE_BLOCK]:`createBlock`,[CREATE_ELEMENT_BLOCK]:`createElementBlock`,[CREATE_VNODE]:`createVNode`,[CREATE_ELEMENT_VNODE]:`createElementVNode`,[CREATE_COMMENT]:`createCommentVNode`,[CREATE_TEXT]:`createTextVNode`,[CREATE_STATIC]:`createStaticVNode`,[RESOLVE_COMPONENT]:`resolveComponent`,[RESOLVE_DYNAMIC_COMPONENT]:`resolveDynamicComponent`,[RESOLVE_DIRECTIVE]:`resolveDirective`,[RESOLVE_FILTER]:`resolveFilter`,[WITH_DIRECTIVES]:`withDirectives`,[RENDER_LIST]:`renderList`,[RENDER_SLOT]:`renderSlot`,[CREATE_SLOTS]:`createSlots`,[TO_DISPLAY_STRING]:`toDisplayString`,[MERGE_PROPS]:`mergeProps`,[NORMALIZE_CLASS]:`normalizeClass`,[NORMALIZE_STYLE]:`normalizeStyle`,[NORMALIZE_PROPS]:`normalizeProps`,[GUARD_REACTIVE_PROPS]:`guardReactiveProps`,[TO_HANDLERS]:`toHandlers`,[CAMELIZE]:`camelize`,[CAPITALIZE]:`capitalize`,[TO_HANDLER_KEY]:`toHandlerKey`,[SET_BLOCK_TRACKING]:`setBlockTracking`,[PUSH_SCOPE_ID]:`pushScopeId`,[POP_SCOPE_ID]:`popScopeId`,[WITH_CTX]:`withCtx`,[UNREF]:`unref`,[IS_REF]:`isRef`,[WITH_MEMO]:`withMemo`,[IS_MEMO_SAME]:`isMemoSame`};function registerRuntimeHelpers(helpers){Object.getOwnPropertySymbols(helpers).forEach(s=>{helperNameMap[s]=helpers[s]})}var locStub={start:{line:1,column:1,offset:0},end:{line:1,column:1,offset:0},source:``};function createRoot(children,source=``){return{type:0,source,children,helpers:new Set,components:[],directives:[],hoists:[],imports:[],cached:[],temps:0,codegenNode:void 0,loc:locStub}}function createVNodeCall(context,tag,props,children,patchFlag,dynamicProps,directives,isBlock=!1,disableTracking=!1,isComponent$1=!1,loc=locStub){return context&&(isBlock?(context.helper(OPEN_BLOCK),context.helper(getVNodeBlockHelper(context.inSSR,isComponent$1))):context.helper(getVNodeHelper(context.inSSR,isComponent$1)),directives&&context.helper(WITH_DIRECTIVES)),{type:13,tag,props,children,patchFlag,dynamicProps,directives,isBlock,disableTracking,isComponent:isComponent$1,loc}}function createArrayExpression(elements,loc=locStub){return{type:17,loc,elements}}function createObjectExpression(properties,loc=locStub){return{type:15,loc,properties}}function createObjectProperty(key,value){return{type:16,loc:locStub,key:isString$1(key)?createSimpleExpression(key,!0):key,value}}function createSimpleExpression(content,isStatic=!1,loc=locStub,constType=0){return{type:4,loc,content,isStatic,constType:isStatic?3:constType}}function createCompoundExpression(children,loc=locStub){return{type:8,loc,children}}function createCallExpression(callee,args=[],loc=locStub){return{type:14,loc,callee,arguments:args}}function createFunctionExpression(params,returns=void 0,newline=!1,isSlot=!1,loc=locStub){return{type:18,params,returns,newline,isSlot,loc}}function createConditionalExpression(test,consequent,alternate,newline=!0){return{type:19,test,consequent,alternate,newline,loc:locStub}}function createCacheExpression(index,value,needPauseTracking=!1,inVOnce=!1){return{type:20,index,value,needPauseTracking,inVOnce,needArraySpread:!1,loc:locStub}}function createBlockStatement(body){return{type:21,body,loc:locStub}}function getVNodeHelper(ssr,isComponent$1){return ssr||isComponent$1?CREATE_VNODE:CREATE_ELEMENT_VNODE}function getVNodeBlockHelper(ssr,isComponent$1){return ssr||isComponent$1?CREATE_BLOCK:CREATE_ELEMENT_BLOCK}function convertToBlock(node,{helper,removeHelper,inSSR}){node.isBlock||(node.isBlock=!0,removeHelper(getVNodeHelper(inSSR,node.isComponent)),helper(OPEN_BLOCK),helper(getVNodeBlockHelper(inSSR,node.isComponent)))}var defaultDelimitersOpen=new Uint8Array([123,123]),defaultDelimitersClose=new Uint8Array([125,125]);function isTagStartChar(c){return c>=97&&c<=122||c>=65&&c<=90}function isWhitespace(c){return c===32||c===10||c===9||c===12||c===13}function isEndOfTagSection(c){return c===47||c===62||isWhitespace(c)}function toCharCodes(str){let ret=new Uint8Array(str.length);for(let i=0;i=0;i--){let newlineIndex=this.newlines[i];if(index>newlineIndex){line=i+2,column=index-newlineIndex;break}}return{column,line,offset:index}}peek(){return this.buffer.charCodeAt(this.index+1)}stateText(c){c===60?(this.index>this.sectionStart&&this.cbs.ontext(this.sectionStart,this.index),this.state=5,this.sectionStart=this.index):!this.inVPre&&c===this.delimiterOpen[0]&&(this.state=2,this.delimiterIndex=0,this.stateInterpolationOpen(c))}stateInterpolationOpen(c){if(c===this.delimiterOpen[this.delimiterIndex])if(this.delimiterIndex===this.delimiterOpen.length-1){let start=this.index+1-this.delimiterOpen.length;start>this.sectionStart&&this.cbs.ontext(this.sectionStart,start),this.state=3,this.sectionStart=start}else this.delimiterIndex++;else this.inRCDATA?(this.state=32,this.stateInRCDATA(c)):(this.state=1,this.stateText(c))}stateInterpolation(c){c===this.delimiterClose[0]&&(this.state=4,this.delimiterIndex=0,this.stateInterpolationClose(c))}stateInterpolationClose(c){c===this.delimiterClose[this.delimiterIndex]?this.delimiterIndex===this.delimiterClose.length-1?(this.cbs.oninterpolation(this.sectionStart,this.index+1),this.inRCDATA?this.state=32:this.state=1,this.sectionStart=this.index+1):this.delimiterIndex++:(this.state=3,this.stateInterpolation(c))}stateSpecialStartSequence(c){let isEnd=this.sequenceIndex===this.currentSequence.length;if(!(isEnd?isEndOfTagSection(c):(c|32)===this.currentSequence[this.sequenceIndex]))this.inRCDATA=!1;else if(!isEnd){this.sequenceIndex++;return}this.sequenceIndex=0,this.state=6,this.stateInTagName(c)}stateInRCDATA(c){if(this.sequenceIndex===this.currentSequence.length){if(c===62||isWhitespace(c)){let endOfText=this.index-this.currentSequence.length;if(this.sectionStart=endIndex||(this.state===28?this.currentSequence===Sequences.CdataEnd?this.cbs.oncdata(this.sectionStart,endIndex):this.cbs.oncomment(this.sectionStart,endIndex):this.state===6||this.state===11||this.state===18||this.state===17||this.state===12||this.state===13||this.state===14||this.state===15||this.state===16||this.state===20||this.state===19||this.state===21||this.state===9||this.cbs.ontext(this.sectionStart,endIndex))}emitCodePoint(cp,consumed){}};function getCompatValue(key,{compatConfig}){let value=compatConfig&&compatConfig[key];return key===`MODE`?value||3:value}function isCompatEnabled(key,context){let mode=getCompatValue(`MODE`,context),value=getCompatValue(key,context);return mode===3?value===!0:value!==!1}function checkCompatEnabled(key,context,loc,...args){return isCompatEnabled(key,context)}function defaultOnError$1(error){throw error}function defaultOnWarn(msg){}function createCompilerError(code,loc,messages,additionalMessage){let msg=`https://vuejs.org/error-reference/#compiler-${code}`,error=SyntaxError(String(msg));return error.code=code,error.loc=loc,error}var isStaticExp=p$1=>p$1.type===4&&p$1.isStatic;function isCoreComponent(tag){switch(tag){case`Teleport`:case`teleport`:return TELEPORT;case`Suspense`:case`suspense`:return SUSPENSE;case`KeepAlive`:case`keep-alive`:return KEEP_ALIVE;case`BaseTransition`:case`base-transition`:return BASE_TRANSITION}}var nonIdentifierRE=/^$|^\d|[^\$\w\xA0-\uFFFF]/,isSimpleIdentifier=name=>!nonIdentifierRE.test(name),validFirstIdentCharRE=/[A-Za-z_$\xA0-\uFFFF]/,validIdentCharRE=/[\.\?\w$\xA0-\uFFFF]/,whitespaceRE=/\s+[.[]\s*|\s*[.[]\s+/g,getExpSource=exp=>exp.type===4?exp.content:exp.loc.source,isMemberExpressionBrowser=exp=>{let path=getExpSource(exp).trim().replace(whitespaceRE,s=>s.trim()),state=0,stateStack$1=[],currentOpenBracketCount=0,currentOpenParensCount=0,currentStringType=null;for(let i=0;i|^\s*(?:async\s+)?function(?:\s+[\w$]+)?\s*\(/,isFnExpressionBrowser=exp=>fnExpRE.test(getExpSource(exp)),isFnExpression=isFnExpressionBrowser;function findDir(node,name,allowEmpty=!1){for(let i=0;ip$1.type===7&&p$1.name===`bind`&&(!p$1.arg||p$1.arg.type!==4||!p$1.arg.isStatic))}function isText$1(node){return node.type===5||node.type===2}function isVPre(p$1){return p$1.type===7&&p$1.name===`pre`}function isVSlot(p$1){return p$1.type===7&&p$1.name===`slot`}function isTemplateNode(node){return node.type===1&&node.tagType===3}function isSlotOutlet(node){return node.type===1&&node.tagType===2}var propsHelperSet=new Set([NORMALIZE_PROPS,GUARD_REACTIVE_PROPS]);function getUnnormalizedProps(props,callPath=[]){if(props&&!isString$1(props)&&props.type===14){let callee=props.callee;if(!isString$1(callee)&&propsHelperSet.has(callee))return getUnnormalizedProps(props.arguments[0],callPath.concat(props))}return[props,callPath]}function injectProp(node,prop,context){let propsWithInjection,props=node.type===13?node.props:node.arguments[2],callPath=[],parentCall;if(props&&!isString$1(props)&&props.type===14){let ret=getUnnormalizedProps(props);props=ret[0],callPath=ret[1],parentCall=callPath[callPath.length-1]}if(props==null||isString$1(props))propsWithInjection=createObjectExpression([prop]);else if(props.type===14){let first=props.arguments[0];!isString$1(first)&&first.type===15?hasProp(prop,first)||first.properties.unshift(prop):props.callee===TO_HANDLERS?propsWithInjection=createCallExpression(context.helper(MERGE_PROPS),[createObjectExpression([prop]),props]):props.arguments.unshift(createObjectExpression([prop])),!propsWithInjection&&(propsWithInjection=props)}else props.type===15?(hasProp(prop,props)||props.properties.unshift(prop),propsWithInjection=props):(propsWithInjection=createCallExpression(context.helper(MERGE_PROPS),[createObjectExpression([prop]),props]),parentCall&&parentCall.callee===GUARD_REACTIVE_PROPS&&(parentCall=callPath[callPath.length-2]));node.type===13?parentCall?parentCall.arguments[0]=propsWithInjection:node.props=propsWithInjection:parentCall?parentCall.arguments[0]=propsWithInjection:node.arguments[2]=propsWithInjection}function hasProp(prop,props){let result=!1;if(prop.key.type===4){let propKeyName=prop.key.content;result=props.properties.some(p$1=>p$1.key.type===4&&p$1.key.content===propKeyName)}return result}function toValidAssetId(name,type){return`_${type}_${name.replace(/[^\w]/g,(searchValue,replaceValue)=>searchValue===`-`?`_`:name.charCodeAt(replaceValue).toString())}`}function getMemoedVNodeCall(node){return node.type===14&&node.callee===WITH_MEMO?node.arguments[1].returns:node}var forAliasRE=/([\s\S]*?)\s+(?:in|of)\s+(\S[\s\S]*)/,defaultParserOptions={parseMode:`base`,ns:0,delimiters:[`{{`,`}}`],getNamespace:()=>0,isVoidTag:NO,isPreTag:NO,isIgnoreNewlineTag:NO,isCustomElement:NO,onError:defaultOnError$1,onWarn:defaultOnWarn,comments:!1,prefixIdentifiers:!1},currentOptions=defaultParserOptions,currentRoot=null,currentInput=``,currentOpenTag=null,currentProp=null,currentAttrValue=``,currentAttrStartIndex=-1,currentAttrEndIndex=-1,inPre=0,inVPre=!1,currentVPreBoundary=null,stack=[],tokenizer=new Tokenizer(stack,{onerr:emitError,ontext(start,end){onText(getSlice(start,end),start,end)},ontextentity(char,start,end){onText(char,start,end)},oninterpolation(start,end){if(inVPre)return onText(getSlice(start,end),start,end);let innerStart=start+tokenizer.delimiterOpen.length,innerEnd=end-tokenizer.delimiterClose.length;for(;isWhitespace(currentInput.charCodeAt(innerStart));)innerStart++;for(;isWhitespace(currentInput.charCodeAt(innerEnd-1));)innerEnd--;let exp=getSlice(innerStart,innerEnd);exp.includes(`&`)&&(exp=currentOptions.decodeEntities(exp,!1)),addNode({type:5,content:createExp(exp,!1,getLoc(innerStart,innerEnd)),loc:getLoc(start,end)})},onopentagname(start,end){let name=getSlice(start,end);currentOpenTag={type:1,tag:name,ns:currentOptions.getNamespace(name,stack[0],currentOptions.ns),tagType:0,props:[],children:[],loc:getLoc(start-1,end),codegenNode:void 0}},onopentagend(end){endOpenTag(end)},onclosetag(start,end){let name=getSlice(start,end);if(!currentOptions.isVoidTag(name)){let found=!1;for(let i=0;i0&&emitError(24,stack[0].loc.start.offset);for(let j=0;j<=i;j++)onCloseTag(stack.shift(),end,j(p$1.type===7?p$1.rawName:p$1.name)===name)&&emitError(2,start)},onattribend(quote,end){if(currentOpenTag&¤tProp){if(setLocEnd(currentProp.loc,end),quote!==0)if(currentAttrValue.includes(`&`)&&(currentAttrValue=currentOptions.decodeEntities(currentAttrValue,!0)),currentProp.type===6)currentProp.name===`class`&&(currentAttrValue=condense(currentAttrValue).trim()),quote===1&&!currentAttrValue&&emitError(13,end),currentProp.value={type:2,content:currentAttrValue,loc:quote===1?getLoc(currentAttrStartIndex,currentAttrEndIndex):getLoc(currentAttrStartIndex-1,currentAttrEndIndex+1)},tokenizer.inSFCRoot&¤tOpenTag.tag===`template`&¤tProp.name===`lang`&¤tAttrValue&¤tAttrValue!==`html`&&tokenizer.enterRCDATA(toCharCodes(`mod.content===`sync`))>-1&&checkCompatEnabled(`COMPILER_V_BIND_SYNC`,currentOptions,currentProp.loc,currentProp.arg.loc.source)&&(currentProp.name=`model`,currentProp.modifiers.splice(syncIndex,1))}(currentProp.type!==7||currentProp.name!==`pre`)&¤tOpenTag.props.push(currentProp)}currentAttrValue=``,currentAttrStartIndex=currentAttrEndIndex=-1},oncomment(start,end){currentOptions.comments&&addNode({type:3,content:getSlice(start,end),loc:getLoc(start-4,end+3)})},onend(){let end=currentInput.length;for(let index=0;index{let start=loc.start.offset+offset$2;return createExp(content,!1,getLoc(start,start+content.length),0,asParam?1:0)},result={source:createAliasExpression(RHS.trim(),exp.indexOf(RHS,LHS.length)),value:void 0,key:void 0,index:void 0,finalized:!1},valueContent=LHS.trim().replace(stripParensRE,``).trim(),trimmedOffset=LHS.indexOf(valueContent),iteratorMatch=valueContent.match(forIteratorRE);if(iteratorMatch){valueContent=valueContent.replace(forIteratorRE,``).trim();let keyContent=iteratorMatch[1].trim(),keyOffset;if(keyContent&&(keyOffset=exp.indexOf(keyContent,trimmedOffset+valueContent.length),result.key=createAliasExpression(keyContent,keyOffset,!0)),iteratorMatch[2]){let indexContent=iteratorMatch[2].trim();indexContent&&(result.index=createAliasExpression(indexContent,exp.indexOf(indexContent,result.key?keyOffset+keyContent.length:trimmedOffset+valueContent.length),!0))}}return valueContent&&(result.value=createAliasExpression(valueContent,trimmedOffset,!0)),result}function getSlice(start,end){return currentInput.slice(start,end)}function endOpenTag(end){tokenizer.inSFCRoot&&(currentOpenTag.innerLoc=getLoc(end+1,end+1)),addNode(currentOpenTag);let{tag,ns}=currentOpenTag;ns===0&¤tOptions.isPreTag(tag)&&inPre++,currentOptions.isVoidTag(tag)?onCloseTag(currentOpenTag,end):(stack.unshift(currentOpenTag),(ns===1||ns===2)&&(tokenizer.inXML=!0)),currentOpenTag=null}function onText(content,start,end){{let tag=stack[0]&&stack[0].tag;tag!==`script`&&tag!==`style`&&content.includes(`&`)&&(content=currentOptions.decodeEntities(content,!1))}let parent=stack[0]||currentRoot,lastNode=parent.children[parent.children.length-1];lastNode&&lastNode.type===2?(lastNode.content+=content,setLocEnd(lastNode.loc,end)):parent.children.push({type:2,content,loc:getLoc(start,end)})}function onCloseTag(el,end,isImplied=!1){isImplied?setLocEnd(el.loc,backTrack(end,60)):setLocEnd(el.loc,lookAhead(end,62)+1),tokenizer.inSFCRoot&&(el.children.length?el.innerLoc.end=extend({},el.children[el.children.length-1].loc.end):el.innerLoc.end=extend({},el.innerLoc.start),el.innerLoc.source=getSlice(el.innerLoc.start.offset,el.innerLoc.end.offset));let{tag,ns,children}=el;if(inVPre||(tag===`slot`?el.tagType=2:isFragmentTemplate(el)?el.tagType=3:isComponent(el)&&(el.tagType=1)),tokenizer.inRCDATA||(el.children=condenseWhitespace(children)),ns===0&¤tOptions.isIgnoreNewlineTag(tag)){let first=children[0];first&&first.type===2&&(first.content=first.content.replace(/^\r?\n/,``))}ns===0&¤tOptions.isPreTag(tag)&&inPre--,currentVPreBoundary===el&&(inVPre=tokenizer.inVPre=!1,currentVPreBoundary=null),tokenizer.inXML&&(stack[0]?stack[0].ns:currentOptions.ns)===0&&(tokenizer.inXML=!1);{let props=el.props;if(!tokenizer.inSFCRoot&&isCompatEnabled(`COMPILER_NATIVE_TEMPLATE`,currentOptions)&&el.tag===`template`&&!isFragmentTemplate(el)){let parent=stack[0]||currentRoot,index=parent.children.indexOf(el);parent.children.splice(index,1,...el.children)}let inlineTemplateProp=props.find(p$1=>p$1.type===6&&p$1.name===`inline-template`);inlineTemplateProp&&checkCompatEnabled(`COMPILER_INLINE_TEMPLATE`,currentOptions,inlineTemplateProp.loc)&&el.children.length&&(inlineTemplateProp.value={type:2,content:getSlice(el.children[0].loc.start.offset,el.children[el.children.length-1].loc.end.offset),loc:inlineTemplateProp.loc})}}function lookAhead(index,c){let i=index;for(;currentInput.charCodeAt(i)!==c&&i=0;)i--;return i}var specialTemplateDir=new Set([`if`,`else`,`else-if`,`for`,`slot`]);function isFragmentTemplate({tag,props}){if(tag===`template`){for(let i=0;i64&&c<91}var windowsNewlineRE=/\r\n/g;function condenseWhitespace(nodes){let shouldCondense=currentOptions.whitespace!==`preserve`,removedWhitespace=!1;for(let i=0;ix.type!==3);return children.length===1&&children[0].type===1&&!isSlotOutlet(children[0])?children[0]:null}function walk(node,parent,context,doNotHoistNode=!1,inFor=!1){let{children}=node,toCache=[];for(let i=0;i0){if(constantType>=2){child.codegenNode.patchFlag=-1,toCache.push(child);continue}}else{let codegenNode=child.codegenNode;if(codegenNode.type===13){let flag=codegenNode.patchFlag;if((flag===void 0||flag===512||flag===1)&&getGeneratedPropsConstantType(child,context)>=2){let props=getNodeProps(child);props&&(codegenNode.props=context.hoist(props))}codegenNode.dynamicProps&&=context.hoist(codegenNode.dynamicProps)}}}else if(child.type===12&&(doNotHoistNode?0:getConstantType(child,context))>=2){child.codegenNode.type===14&&child.codegenNode.arguments.length>0&&child.codegenNode.arguments.push(`-1`),toCache.push(child);continue}if(child.type===1){let isComponent$1=child.tagType===1;isComponent$1&&context.scopes.vSlot++,walk(child,node,context,!1,inFor),isComponent$1&&context.scopes.vSlot--}else if(child.type===11)walk(child,node,context,child.children.length===1,!0);else if(child.type===9)for(let i2=0;i2p$1.key===name||p$1.key.content===name);return slot&&slot.value}}toCache.length&&context.transformHoist&&context.transformHoist(children,context,node)}function getConstantType(node,context){let{constantCache}=context;switch(node.type){case 1:if(node.tagType!==0)return 0;let cached=constantCache.get(node);if(cached!==void 0)return cached;let codegenNode=node.codegenNode;if(codegenNode.type!==13||codegenNode.isBlock&&node.tag!==`svg`&&node.tag!==`foreignObject`&&node.tag!==`math`)return 0;if(codegenNode.patchFlag===void 0){let returnType2=3,generatedPropsType=getGeneratedPropsConstantType(node,context);if(generatedPropsType===0)return constantCache.set(node,0),0;generatedPropsType1)for(let i=0;iremovalIndex&&(context.childIndex--,context.onNodeRemoved()),context.parent.children.splice(removalIndex,1)},onNodeRemoved:NOOP,addIdentifiers(exp){},removeIdentifiers(exp){},hoist(exp){isString$1(exp)&&(exp=createSimpleExpression(exp)),context.hoists.push(exp);let identifier=createSimpleExpression(`_hoisted_${context.hoists.length}`,!1,exp.loc,2);return identifier.hoisted=exp,identifier},cache(exp,isVNode$1=!1,inVOnce=!1){let cacheExp=createCacheExpression(context.cached.length,exp,isVNode$1,inVOnce);return context.cached.push(cacheExp),cacheExp}};return context.filters=new Set,context}function transform$1(root,options){let context=createTransformContext(root,options);traverseNode$1(root,context),options.hoistStatic&&cacheStatic(root,context),options.ssr||createRootCodegen(root,context),root.helpers=new Set([...context.helpers.keys()]),root.components=[...context.components],root.directives=[...context.directives],root.imports=context.imports,root.hoists=context.hoists,root.temps=context.temps,root.cached=context.cached,root.transformed=!0,root.filters=[...context.filters]}function createRootCodegen(root,context){let{helper}=context,{children}=root;if(children.length===1){let singleElementRootChild=getSingleElementRoot(root);if(singleElementRootChild&&singleElementRootChild.codegenNode){let codegenNode=singleElementRootChild.codegenNode;codegenNode.type===13&&convertToBlock(codegenNode,context),root.codegenNode=codegenNode}else root.codegenNode=children[0]}else children.length>1&&(root.codegenNode=createVNodeCall(context,helper(FRAGMENT),void 0,root.children,64,void 0,void 0,!0,void 0,!1))}function traverseChildren(parent,context){let i=0,nodeRemoved=()=>{i--};for(;in===name:n=>name.test(n);return(node,context)=>{if(node.type===1){let{props}=node;if(node.tagType===3&&props.some(isVSlot))return;let exitFns=[];for(let i=0;i`${helperNameMap[s]}: _${helperNameMap[s]}`;function createCodegenContext(ast,{mode=`function`,prefixIdentifiers=mode===`module`,sourceMap=!1,filename=`template.vue.html`,scopeId=null,optimizeImports=!1,runtimeGlobalName=`Vue`,runtimeModuleName=`vue`,ssrRuntimeModuleName=`vue/server-renderer`,ssr=!1,isTS=!1,inSSR=!1}){let context={mode,prefixIdentifiers,sourceMap,filename,scopeId,optimizeImports,runtimeGlobalName,runtimeModuleName,ssrRuntimeModuleName,ssr,isTS,inSSR,source:ast.source,code:``,column:1,line:1,offset:0,indentLevel:0,pure:!1,map:void 0,helper(key){return`_${helperNameMap[key]}`},push(code,newlineIndex=-2,node){context.code+=code},indent(){newline(++context.indentLevel)},deindent(withoutNewLine=!1){withoutNewLine?--context.indentLevel:newline(--context.indentLevel)},newline(){newline(context.indentLevel)}};function newline(n){context.push(`
      nop(${this.serializeToLua(text)}) -- (actually run the lua check)
    `)}serializeToLua(obj){let tmp;if(obj==null)return`nil`;switch(obj.constructor){case String:return obj.search(/\\|\"|\n|\t|\r/)==-1?`"${obj}"`:`"${obj.replace(/\\/g,`\\\\`).replace(/\"/g,`\\"`).replace(/\n|\r/g,`\\n`).replace(/\t/g,`\\t`)}"`;case Number:return isFinite(obj)?obj.toString():null;case Boolean:return obj?`true`:`false`;case Array:tmp=[];for(let i=0;iLua_default.extensions[LUA_BLUR_EXTENSION].replaceGroup(`uiBlur`,blurRegionList),getNextAvailableId=()=>(highestId<2**53-1?highestId++:highestId=0).toString(),LUA_BLUR_UNLOADED=0,LUA_BLUR_LOADING=1,LUA_BLUR_LOADED=2,blurLoadedState=LUA_BLUR_UNLOADED;function applyBlur(){if(!window.beamng||!window.beamng.ingame||blurLoadedState===LUA_BLUR_LOADING)return;let isEmpty=!Object.keys(blurRegionList).length;blurLoadedState===LUA_BLUR_UNLOADED?isEmpty||(blurLoadedState=LUA_BLUR_LOADING,Lua_default.extensions.load(LUA_BLUR_EXTENSION).then(()=>{blurLoadedState=LUA_BLUR_LOADED,sendBlurListToLua()})):isEmpty?(Lua_default.extensions.unload(LUA_BLUR_EXTENSION),blurLoadedState=LUA_BLUR_UNLOADED):sendBlurListToLua()}var GameBlurrer_default={register(coord){if(coord===void 0)throw Error(`Cannot register bng-blur with coordinates: `+coord);let id=getNextAvailableId();return blurRegionList[id]=coord,applyBlur(),id},unregister(id){id in blurRegionList&&(delete blurRegionList[id],applyBlur())},update(id,coord){if(!(id in blurRegionList))throw Error(`Trying to update bng-blur with an ID that is not registered: ${id} (of ${Object.keys(blurRegionList)})`);blurRegionList[id]=coord,applyBlur()}},handlers={},streamCoordinator;window.streamUpdate=data=>_runHandlers(`stream`,data),window.multihookUpdate=hooksData=>{for(let i in hooksData){let hook=hooksData[i];trigger(hook[0],hook[1])}},window.HookManager={trigger};var skippedStreamUpdate=null,streamUpdateHandler=function(data){if(streamCoordinator?.processing){console.log(`ERROR: streamUpdate cycle is already active, skipping this update of streams`),skippedStreamUpdate=data;return}skippedStreamUpdate=null;let oldFormat={};if(data.globalStreams)for(let sn in data.globalStreams)oldFormat[sn]=data.globalStreams[sn];if(data.vehicleStreams&&data.vehicleStreams.player_0)for(let sn in data.vehicleStreams.player_0)oldFormat[sn]=data.vehicleStreams.player_0[sn];streamCoordinator?.beforeBroadcast(),window.globalAngularRootScope?.$broadcast(`streamsUpdate`,oldFormat),window.vueEventBus?.emit(`onStreamsUpdate`,oldFormat),window.vueGlobalStore&&(window.vueGlobalStore.streams=oldFormat),streamCoordinator?.afterBroadcast(()=>{!streamCoordinator.processing&&skippedStreamUpdate&&streamUpdateHandler(skippedStreamUpdate)})};add$1(`streamMain`,streamUpdateHandler,`stream`);var mainHookHandler=function(hookName,args){args&&!Array.isArray(args)&&console.error(`HookManager.trigger unsupported arguments (needs to be a list): `+JSON.stringify(hookName)+` - `+JSON.stringify(args).substring(0,30)+` ... `),window.vueEventBus?.emit(hookName,...args),window.globalAngularRootScope?.$broadcast(hookName,...args)};add$1(`hooksMain`,mainHookHandler);function add$1(id,func,type=`hook`){handlers[type]||(handlers[type]={}),handlers[type][id]=func}function remove$1(id,type=`hook`){handlers[type]&&delete handlers[type][id]}function trigger(hookName,args){_runHandlers(`hook`,hookName,args)}function _runHandlers(type,...data){if(handlers[type]){let toRun=Object.values(handlers[type]);toRun.length&&toRun.forEach(f=>f(...data))}}var Hooks_default={add:add$1,remove:remove$1,trigger,setStreamCoordinator(manager){streamCoordinator=manager}},scriptRel=`modulepreload`,assetsURL=function(dep){return`/local/ui/ui-vue/`+dep},seen={};const __vitePreload=function(baseModule,deps$1,importerUrl){let promise=Promise.resolve();if(deps$1&&deps$1.length>0){let links=document.getElementsByTagName(`link`),cspNonceMeta=document.querySelector(`meta[property=csp-nonce]`),cspNonce=cspNonceMeta?.nonce||cspNonceMeta?.getAttribute(`nonce`);function allSettled(promises$2){return Promise.all(promises$2.map(p$1=>Promise.resolve(p$1).then(value$1=>({status:`fulfilled`,value:value$1}),reason=>({status:`rejected`,reason}))))}promise=allSettled(deps$1.map(dep=>{if(dep=assetsURL(dep,importerUrl),dep in seen)return;seen[dep]=!0;let isCss=dep.endsWith(`.css`),cssSelector=isCss?`[rel="stylesheet"]`:``;if(importerUrl)for(let i$1=links.length-1;i$1>=0;i$1--){let link$1=links[i$1];if(link$1.href===dep&&(!isCss||link$1.rel===`stylesheet`))return}else if(document.querySelector(`link[href="${dep}"]${cssSelector}`))return;let link=document.createElement(`link`);if(link.rel=isCss?`stylesheet`:scriptRel,isCss||(link.as=`script`),link.crossOrigin=``,link.href=dep,cspNonce&&link.setAttribute(`nonce`,cspNonce),document.head.appendChild(link),isCss)return new Promise((res,rej)=>{link.addEventListener(`load`,res),link.addEventListener(`error`,()=>rej(Error(`Unable to preload CSS for ${dep}`)))})}))}function handlePreloadError(err$2){let e$1=new Event(`vite:preloadError`,{cancelable:!0});if(e$1.payload=err$2,window.dispatchEvent(e$1),!e$1.defaultPrevented)throw err$2}return promise.then(res=>{for(let item of res||[])item.status===`rejected`&&handlePreloadError(item.reason);return baseModule().catch(handlePreloadError)})};var MOCK_DATA_PATH=`../mockdata`;function applyMockInterface(originalObject,mockInterface){let handler$1={mockInterface,get(target,propertyName){return this.mockInterface[propertyName]||target[propertyName]||defaultMockedMethod(propertyName)}};return new Proxy(originalObject,handler$1)}function defaultMockedMethod(name){return{[name]:function(...args){console.log(`Mocked method '${name}' called with:`),console.log(args)}}[name]}function getMockedData(fullPath){const[file$1,...path]=fullPath.split(`.`),filename=`${MOCK_DATA_PATH}/${file$1}.js`,toEval=[`d`,`default`,...path].join(`.`);return __vitePreload(()=>import(filename),[]).then(d=>eval(toEval))}const runInBrowser=fn=>{window.beamng||fn()},sendGUIHook=(name,...params)=>{window.bridge&&window.bridge.events&&window.bridge.events.emit(name,...params),window.globalAngularRootScope&&window.globalAngularRootScope.$broadcast(name,...params)};var withMocked=(sig,getData)=>(sig.mocked=getData,sig),LuaFunctionSignatures_default={dev:{getMockedData:key=>String},getVehicleColor:()=>{},getVehicleColorPalette:index=>Integer,resetGameplay:playerID=>Integer,quit:()=>{},checkFSErrors:()=>{},returnToMainMenu:()=>{},guihooks:{trigger:withMocked(hookName=>String,sendGUIHook)},simTimeAuthority:{togglePause:()=>{},getPause:()=>{},pause:state=>Boolean,pushPauseRequest:id=>String,popPauseRequest:id=>String},commands:{toggleCamera:()=>{}},ui_audio:{playEventSound:(soundClass,type)=>[String,String]},career_career:{closeAllMenus:()=>{},isActive:()=>{},sendAllCareerSaveSlotsData:()=>{},sendCurrentSaveSlotData:()=>{},createOrLoadCareerAndStart:(id,specificAutosave,tutorial)=>[String,Any$1,Boolean]},career_saveSystem:{saveCurrent:()=>{},removeSaveSlot:id=>String,renameSaveSlot:(name,newName)=>[String,String]},career_modules_uiUtils:{getCareerStatusData:withMocked(()=>{},()=>getMockedData(`career.status`)),getCareerSimpleStats:withMocked(()=>{},()=>getMockedData(`career.simpleStats`)),getCareerPauseContextButtons:()=>{},callCareerPauseContextButtons:id=>Number,getCareerCurrentLevelName:()=>{}},career_modules_fuel:{requestRefuelingTransactionData:()=>{},sendUpdateDataToUI:()=>{},uiButtonStartFueling:energyType=>String,uiButtonStopFueling:energyType=>String,onChangeFlowRate:flowRate=>Number,payPrice:()=>{},uiCancelTransaction:()=>{}},career_modules_logbook:{getLogbook:withMocked(()=>{},()=>getMockedData(`logbook.sample`)),setLogbookEntryRead:(id,state)=>[String,Boolean]},career_modules_milestones_milestones:{getMilestones:()=>{},claim:id=>Number,unclaimedMilestonesCount:()=>{}},career_modules_branches_landing:{openBigMapWithMissionSelected:id=>String,getBranchSkillCardData:id=>String,getBranchPageData:id=>String,getLandingPageData:domain=>String,getCargoProgressForUI:()=>{}},career_modules_partShopping:{cancelShopping:()=>{},applyShopping:()=>{},installPartByPartShopId:id=>Number,removePartBySlot:slot=>String,sendShoppingDataToUI:()=>{}},career_modules_vehicleShopping:{showVehicle:id=>Number,navigateToPos:pos=>Object,openShop:(seller,computerId)=>[Any$1,Any$1],cancelShopping:()=>{},quickTravelToVehicle:id=>Number,openPurchaseMenu:(purchaseType,shopId)=>[String,Number],updateInsuranceSelection:insuranceId=>Number,openInventoryMenuForTradeIn:()=>{},buyFromPurchaseMenu:(purchaseType,options)=>[String,Any$1],cancelPurchase:purchaseType=>String,getShoppingData:()=>{},sendPurchaseDataToUi:()=>{},removeTradeInVehicle:()=>{},onShoppingMenuClosed:()=>{}},career_modules_marketplace:{getListings:()=>{},menuOpened:open$1=>Boolean,acceptOffer:(inventoryId,offerIndex)=>[Number,Number],declineOffer:(inventoryId,offerIndex)=>[Number,Number],listVehicles:inventoryIds=>[Array],openMenu:()=>{},removeVehicleListing:inventoryId=>Number,startNegotiateBuyingOffer:(inventoryId,offerIndex)=>[Number,Number],startNegotiateSellingOffer:shopId=>[Number],getNegotiationState:()=>{},makeNegotiationOffer:price=>Number,takeTheirOffer:()=>{},cancelNegotiation:()=>{}},career_modules_testDrive:{stop:()=>{}},career_modules_inspectVehicle:{startTestDrive:()=>{},onInspectScreenChanged:enabled=>Boolean,onPurchaseMenuClosed:()=>{},repairVehicle:()=>{}},career_modules_loanerVehicles:{markForSpawning:loanInfo=>Object,spawnAndLoanVehicle:(vehicleInfo,loanInfo)=>[Object,Object],getLoanedVehiclesByOrg:orgId=>String,returnVehicle:inventoryId=>Number},career_modules_inventory:{sellVehicle:id=>Number,sellVehicleFromInventory:id=>Number,returnLoanedVehicleFromInventory:id=>Number,expediteRepairFromInventory:(inventoryId,price)=>[Number,Number],enterVehicle:id=>Number,openMenuFromComputer:computerId=>String,closeMenu:()=>{},chooseVehicleFromMenu:(vehId,buttonId,repairPrevVeh)=>[Number,Number,Boolean],setFavoriteVehicle:id=>Number,sendDataToUi:()=>{},removeVehicleObject:id=>Number,getVehicle:id=>Number,getVehicleUiData:id=>Number,isEmpty:()=>{},setLicensePlateText:(inventoryId,text)=>[Number,String],purchaseLicensePlateText:(inventoryId,text,money)=>[Number,String,Number],isLicensePlateValid:text=>String,isVehicleNameValid:text=>String,renameVehicle:(inventoryId,name)=>[Number,String],openInventoryMenuForChoosingListing:()=>{}},career_modules_vehiclePerformance:{startDragTest:id=>Number,cancelTest:()=>{}},career_modules_partInventory:{openMenu:computerId=>Any$1,closeMenu:()=>{},sendUIData:()=>{},sellParts:ids=>Array,partInventoryClosed:()=>{}},career_modules_insurance_insurance:{getProposablePoliciesForVehInv:invVehId=>Number,payInsuranceScoreReset:policyId=>Number,purchaseInsurance:id=>Number,calculateRenewalPriceDetails:(policyId,tempPerks)=>[Number,Any$1],changeInvVehInsuranceCoverageOptions:(policyId,changedPerks)=>[Number,Object],changeInvVehInsurance:(invVehId,newInsuranceId)=>[Number,Number],startRepairInGarage:(vehicleInfo,repairOptionData)=>[Object,Object],openRepairMenu:(vehicleInfo,originComputerId)=>[Object,Any$1],closeMenu:()=>{},sendUIData:()=>{},inventoryVehNeedsRepair:inventoryId=>Number,getInvVehHaveFuelDiscount:invVehId=>Object,openChooseInsuranceScreen:()=>{},calculateInsurancePremium:(insuranceId,potentialCoverageOptions,potentialVehiclesCoverageOptions)=>[Number,Object,Object],saveNewInsuranceCoverageOptions:(insuranceId,newCoverageOptions)=>[Number,Object],calculateVehiclePremium:(vehicleId,nonInvVehInfo,potentialCoverageOptions)=>[Number,Object,Object],saveNewVehicleCoverageOptions:(vehicleId,newCoverageOptions)=>[Number,Object],sendChooseInsuranceDataToTheUI:(purchaseType,shopId,defaultInsuranceId)=>[String,Number,Number],sendChangeInsuranceDataToTheUI:vehicleId=>[Number],resetDriverScore:()=>{}},career_modules_insurance_repairScreen:{getRepairData:()=>{},closeMenu:()=>{},startRepairInGarage:(invVehId,repairOptionData)=>[Number,Object],openRepairMenu:(vehicleInfo,originComputerId)=>[Object,Any$1]},career_modules_playerAbstract:{getPlayerAbstractData:()=>{},closePlayerAbstractMenu:()=>{}},career_modules_tuning:{apply:tuningValues=>Object,start:(vehId,origin)=>[Any$1,Any$1],getTuningData:()=>{},close:()=>{},applyShopping:()=>{},cancelShopping:()=>{},removeVarFromShoppingCart:varName=>String},career_modules_painting:{apply:()=>{},start:(vehId,origin)=>[Any$1,Any$1],getPaintData:()=>{},close:()=>{},setPaints:paint=>Object,getFactoryPaint:()=>{},onUIOpened:()=>{}},career_modules_questManager:{setQuestAsNotNew:id=>String,claimRewardsById:id=>String},career_modules_computer:{onMenuClosed:()=>{},getComputerUIData:()=>{},computerButtonCallback:(buttonId,inventoryId)=>[String,Any$1],openComputerMenuById:computerId=>String,closeAllMenus:()=>{}},career_modules_delivery_general:{setAutomaticRoute:enabled=>Boolean,setDetailedDropOff:enabled=>Boolean,setSetting:(key,value)=>[String,Any$1],getSettings:()=>{},setDeliveryTimePaused:paused=>Boolean},career_modules_delivery_cargoScreen:{requestCargoDataForUi:(facilityId,parkingSpotPath,updateMaxTimeStamp)=>[Any$1,Any$1,Any$1],moveCargoFromUi:(cargoId,targetLocation)=>[Number,Object],commitDeliveryConfiguration:()=>{},cancelDeliveryConfiguration:()=>{},exitDeliveryMode:()=>{},exitCargoOverviewScreen:()=>{},showCargoRoutePreview:cargoId=>Any$1,showVehicleOfferRoutePreview:offerId=>Any$1,setCargoRoute:(cargoId,origin)=>[Number,Boolean],showLocationRoutePreview:(location$1,asProvider)=>[Any$1,Boolean],showCargoContainerHelpPopup:()=>{},setBestRoute:()=>{},spawnOffer:(offerId,fadeToBlack)=>[Number,Any$1],abandonAcceptedOffer:vehId=>Number,setCargoScreenTab:tab=>String,unloadCargoPopupClosed:()=>{},moveMaterialFromUi:()=>{},requestDropOffData:()=>{},confirmDropOffData:(data,facId,psPath)=>[Any$1,Any$1,Any$1],dropOffPopupClosed:mode=>String,clearTransientMoveForCargo:cargoId=>Number,clearTransientMovesForStorage:materialType=>String,applyTransientMoves:()=>{},toggleOfferForSpawning:id=>Number,tryLoadAll:cargoIds=>Array,showRoutePreview:route=>Object,deliveryScreenExternalButtonPressed:id=>Any$1},career_modules_delivery_progress:{activateSound:(soundLabel,active)=>[String,Boolean]},career_modules_linearTutorial:{introPopup:(key,force)=>[String,Boolean],wasIntroPopupsSeen:pages=>Array,isLinearTutorialActive:()=>{}},gameplay_drag_dragBridge:{getHistory:id=>Object,screenshotTimeslip:()=>{}},gameplay_crashTest_scenarioManager:{nextStepFromUI:()=>{}},gameplay_discover:{getDiscoverPages:()=>{},startDiscover:discoverId=>String},freeroam_organizations:{getUIData:()=>{},getUIDataForOrg:orgId=>String},core_replay:{onInit:()=>{},loadFile:filename=>String,stop:()=>{},openReplayFolderInExplorer:()=>{},getRecordings:()=>{},removeRecording:filename=>String,togglePlay:()=>{},toggleRecording:()=>{},cancelRecording:()=>{},toggleSpeed:speed=>Number,pause:()=>{},seek:positionPercent=>Number,acceptRename:(oldFilename,newFilename)=>[String,String],saveMissionReplay:filename=>String,removeMissionSavedReplay:filename=>String,openMissionReplayFolder:filename=>String},core_gamestate:{requestGameState:()=>{},loadingScreenActive:()=>{}},core_gameContext:{getGameContext:withMocked(params=>{},params=>getMockedData(`gameContext.gameContextData`))},core_online:{requestState:()=>{}},core_hardwareinfo:{requestState:()=>{},getInfo:()=>{}},gameplay_statistic:{sendGUIState:()=>{}},core_quickAccess:{getUiData:()=>{},selectItem:(id,buttonDown,actionIndex)=>[Number,Boolean,Number],contextAction:(id,buttonDown,actionIndex)=>[Number,Boolean,Number],back:()=>{},setEnabled:(enabled,level$1,force)=>[Boolean,String,Boolean],openDynamicSlotConfigurator:index=>Number,getDynamicSlotConfigurationData:()=>{},setDynamicSlotConfiguration:(key,data)=>[String,Object],toggle:()=>[],tryAction:action=>String},ui_bindingsLegend:{sendDataToUI:forceResetFade=>Boolean,triggerInputAction:(action,value)=>[String,Number],toggleShowApp:()=>{},toggleShowVehicleSpecificActions:()=>{}},freeroam_bigMapMode:{enterBigMap:instant=>Object,exitBigMap:force=>Boolean,setBigmapScreenBounds:(windowBounds,mapBounds)=>[Object,Object],navigateToMission:poiId=>String,selectPoi:poiId=>String,poiHovered:(poiId,active)=>[String,Boolean],teleportToPoi:poiId=>String,setOnlyIdsVisible:poiIds=>Array,deselect:()=>{},openPopupCallback:()=>{},toggleBigMap:()=>{},setUiFocus:focus$1=>Boolean},freeroam_bigMapPoiProvider:{sendMissionLocationsToMinimap:()=>{},sendCurrentLevelMissionsToBigmap:()=>{},toggleGroupVisibility:groupKey=>String},freeroam_freeroamConfigurator:{getConfiguration:()=>{},getButtons:()=>{},triggerButton:buttonId=>Number,updateOption:(key,value)=>[String,Any$1],onSpawnPointTileClick:()=>{},onVehicleTileClick:()=>{},getCurrentSpawnPointTile:()=>{},getCurrentVehicleTile:()=>{},setSpawnPoint:(levelName,spawnPointName,key)=>[String,String,String],setVehicle:(model,config,additionalData,key)=>[String,String,Object,String],doubleClickOverride:item=>[Object]},gameplay_taxi:{startTaxiWithCurrentRoute:()=>{}},freeroam_vueBigMap:{enterBigMap:()=>{},exitBigMap:()=>{},getPoiData:()=>{},getFilters:()=>{},getGroups:()=>{},toggleFiltersByIds:filterIds=>Object,toggleFilterSectionById:sectionId=>Object,getGameStateInfo:()=>{},selectPoiFromList:poiId=>String,hoverPoiFromList:(poiId,active)=>[String,Boolean],executePoiAction:actionId=>Number},freeroam_freeroam:{startTrackBuilder:mapName=>String},extensions:{isExtensionLoaded:extensionName=>Boolean,load:extensionName=>String,unload:extensionName=>String,hook:hook=>String,ui_messagesDebugger:{show:()=>{},hide:()=>{},toggle:()=>{}},tech_license:{requestState:()=>{},isValid:()=>{}},core_input_actionFilter:{addAction:(filter,actionName,filtered)=>[Number,String,Boolean],setGroup:(name,actioNames)=>[String,Any$1]},core_input_bindings:{FFBSafetyDataRequest:()=>{},resetBindings:()=>{},resetBindingsForDevice:deviceName=>String,setMenuActionMapEnabled:state=>Boolean,getMenuActionMapEnabled:()=>{},setMenuActionEnabled:(enabled,actionName)=>[Boolean,String],notifyUI:reason=>String,saveBindingsToDisk:deviceContents=>Object,getRecentDevices:()=>{}},core_vehicle_partmgmt:{getConfigList:()=>{},highlightParts:(parts,vehID)=>[Object,Number],loadLocal:filename=>String,resetPartsToLoadedConfig:()=>{},resetVarsToLoadedConfig:()=>{},resetAllToLoadedConfig:()=>{},openConfigFolderInExplorer:()=>{},removeLocal:configName=>String,savedefault:()=>{},saveLocal:filename=>String,sendDataToUI:()=>{},selectPart:(part,subparts)=>[String,Boolean],selectParts:(parts,vehID)=>[Object,Number],selectReset:()=>{},setConfigVars:vars=>Object,setPartsConfig:config=>Object,setPartsTreeConfig:config=>Object,showHighlightedParts:vehID=>Number,setDynamicTextureMaterials:()=>{},partsSelectorChanged:parts=>Object,sendPartsSelectorStateToUI:()=>{}},core_vehicle_mirror:{getAnglesOffset:()=>{},focusOnMirror:mirror_name=>Any$1,setAngleOffset:(mirrorName,x,z,v,save)=>[String,Number,Number,Boolean,Boolean]},gameplay_drift_general:{onDriftAppMounted:()=>{},onDriftAppUnmounted:()=>{}},gameplay_missions_missionScreen:{getMissionScreenData:withMocked(()=>{},()=>getMockedData(`missionDetails.getMissionScreenData`)),startMissionById:(missionId,userSettings,startingOptions)=>[String,Object,Object],stopMissionById:id=>[String],changeUserSettings:(missionId,userSettings)=>[String,Object],startFromWithinMission:(id,userSettings)=>[String,Object],getActiveStarsForUserSettings:(id,userSettings)=>[String,Object],requestStartingOptionsForUserSettings:(id,userSettings)=>[String,Object],isAnyMissionActive:()=>{},isMissionStartOrEndScreenActive:()=>{},openAPMChallenges:(branch,skill)=>[String,String],navigateToMission:id=>[String],setPreselectedMissionId:id=>[String],showMissionRules:id=>[String],getMissionTiles:()=>{},activateSound:(soundLabel,active,frequency)=>[String,Boolean,Number],activateSoundBlur:active=>{Boolean},openVehicleSelectorForMissionBySetting:(mId,settingKey)=>[String,String]},gameplay_missions_missionManager:{getCurrentTaskdataTypeOrNil:()=>{}},gameplay_garageMode:{start:()=>{},isActive:()=>{},setCamera:view=>String,setLighting:lights=>Array,getLighting:()=>{},setGarageMenuState:state=>String,stop:()=>{},testVehicle:()=>{}},ui_dynamicDecals:{initialize:()=>{},exit:()=>{},requestUpdatedData:()=>{},setupEditor:()=>{},loadSaveFile:path=>String,createSaveFile:()=>{},saveChanges:filename=>String,cancelChanges:()=>{},exportSkin:skinName=>String,moveSelectedLayer:order=>Number,setDecalTexture:filePath=>String,setDecalColor:colorData=>Object,setDecalScale:decalData=>Object,setDecalRotation:decalRotation=>Number,setDecalSkew:decalSkew=>Object,setDecalApplyMultiple:applyMultiple=>Boolean,setDecalResetOnApply:resetOnApply=>Boolean,setDecalPositionX:positionX=>Number,setDecalPositionY:positionY=>Number,updateDecalPosition:(positionX,positionY)=>[Number,Number],toggleApplyingDecal:enable=>Boolean,toggleActionMap:enable=>Boolean,toggleDecalVisibility:enable=>Boolean,redo:()=>{},undo:()=>{},createLayer:layerData=>Object,createFillLayer:fillLayerData=>Object,createGroupLayer:layerData=>Object,updateLayer:layerData=>Object,deleteSelectedLayer:()=>{},selectLayer:layerUid=>String,toggleStampActionMap:enable=>Boolean,toggleLayerHighlight:uid$2=>String,toggleLayerVisibility:uid$2=>String},ui_liveryEditor:{save:filename=>String,setup:()=>{},deactivate:()=>{},setDecalTexture:texturePath=>String,useMousePosition:enable=>Boolean,useSurfaceNormal:enable=>Boolean,requestSettingsData:()=>{}},ui_liveryEditor_colorPresets:{getPresets:()=>{},addPreset:()=>{}},ui_liveryEditor_editor:{setup:()=>{},startEditor:()=>{},exitEditor:()=>{},startSession:()=>{},applyDecal:()=>{},applySkin:()=>{},createNew:()=>{},loadFile:path=>String,save:filename=>String,applyChanges:()=>{}},ui_liveryEditor_editMode:{reapply:()=>{},requestReapply:()=>{},cancelReapply:()=>{},setActiveLayer:layerUid=>String,setActiveLayerDirection:direction$1=>Number,removeAppliedLayer:layerUid=>String,resetCursorProperties:properties=>Array,toggleHighlightActive:()=>{},activate:()=>{},deactivate:()=>{},apply:()=>{},requestApply:()=>{},cancelRequestApply:()=>{},toggleRequestApply:()=>{},saveChanges:params=>Object,cancelChanges:()=>{},duplicateActiveLayer:()=>{}},ui_liveryEditor_camera:{setOrthographicView:view=>String,switchOrthographicViewByDirection:(x,y)=>[Number,Number]},ui_liveryEditor_controls:{toggleUseMousePos:()=>{}},ui_liveryEditor_history:{redo:()=>{},undo:()=>{}},ui_liveryEditor_layerAction:{performAction:action=>String,toggleEnabledByLayerUid:uid$2=>String},ui_liveryEditor_layerEdit:{setup:()=>{},setLayer:layerUid=>String,editNewDecal:params=>Object,translateLayer:(x,y)=>[Number,Number],holdTranslate:(axis,value)=>[String,Number],holdTranslateScalar:(axis,value)=>[String,Number],holdScale:(axis,value)=>[String,Number],holdSkew:(axis,value)=>[String,Number],holdPrecise:enable=>Boolean,scaleLayer:(x,y)=>[Number,Number],skewLayer:(x,y)=>[Number,Number],rotateLayer:(steps,counterClockwise)=>[Number,Boolean],setPosition:(x,y)=>[Number,Number],setScale:(x,y)=>[Number,Number],setRotation:degrees=>Number,setSkew:(x,y)=>[Number,Number],setMirrored:settings$1=>[Boolean,Boolean,Number],setLayerMaterials:properties=>Object,activateStampReapply:()=>{},cancelStampReapply:()=>{},requestLayerMaterials:()=>{},saveChanges:()=>{},cancelChanges:()=>{},requestStateData:()=>{},requestInitialLayerData:()=>{},requestTransform:()=>{},endTransform:()=>{},showCursorOrLayer:show=>Boolean,requestReposition:()=>{},cancelReposition:()=>{},applyReposition:()=>{},toggleUseMouseOrCursor:()=>{},setIsRotationPrecise:value=>Boolean,setAllowRotationAction:value=>Boolean},ui_liveryEditor_layers:{requestInitialData:()=>{}},ui_liveryEditor_layers_cursor:{requestData:()=>{}},ui_liveryEditor_layers_decals:{addLayer:params=>Object,setLayer:uid$2=>String},ui_liveryEditor_layers_decal:{addLayerCentered:params=>Object},ui_liveryEditor_layers_fill:{updateLayer:params=>Object,saveChanges:()=>{},restoreLayer:()=>{},restoreDefault:()=>{},requestLayerData:()=>{}},ui_liveryEditor_resources:{requestData:()=>{},getDecalTextures:()=>{},getTextureCategories:()=>{},getTexturesByCategory:category=>String},ui_liveryEditor_selection:{duplicateSelectedLayer:()=>{},getSelectedLayersData:()=>{},setSelected:layerUid=>String,setMultipleSelected:layerUids=>Array,clearSelection:()=>{},toggleSelection:layerIds=>Array,select:(layerIds,highlight)=>[Array,Boolean],toggleHighlightSelectedLayer:()=>{},requestInitialData:()=>{}},ui_liveryEditor_tools:{useTool:tool=>String,closeCurrentTool:()=>{}},ui_liveryEditor_tools_material:{setColor:rgbaArray=>Array,setMetallicIntensity:metallicIntensity=>Number,setNormalIntensity:normalIntensity=>Number,setRoughnessIntensity:roughnessIntensity=>Number,setDecal:decalTexture=>String},ui_liveryEditor_tools_misc:{duplicate:()=>{}},ui_liveryEditor_tools_group:{moveOrderUp:()=>{},moveOrderDown:()=>{},changeOrderToTop:()=>{},changeOrderToBottom:()=>{},moveOrderUpById:layerUid=>[String],moveOrderDownById:layerUid=>[String],setOrder:order=>Number,changeOrder:(oldOrder,oldParent,newOrder,newParent)=>[Number,String,Number,String],groupLayers:()=>{},ungroupLayer:()=>{}},ui_liveryEditor_tools_transform:{translate:(x,y)=>[Number,Number],setPosition:(x,y)=>[Number,Number],rotate:degrees=>Number,scale:(stepsX,stepsY)=>[Number,Number],setScale:(scaleX,scaleY)=>[Number,Number],setRotation:degrees=>Number,skew:(skewX,skewY)=>[Number,Number],setSkew:(skewX,skewY)=>[Number,Number],useStamp:()=>{},cancelStamp:()=>{}},ui_liveryEditor_tools_settings:{deleteLayer:()=>{},setMirrored:(mirrored,flip$2)=>[Boolean,Boolean],setVisibility:show=>Boolean,toggleVisibility:()=>{},toggleVisibilityById:layerUid=>String,toggleLock:()=>{},toggleLockById:layerUid=>String,setMirrorOffset:offset$2=>Number,setUseMousePos:value=>Boolean,setProjectSurfaceNormal:value=>Boolean,rename:name=>String},ui_liveryEditor_userData:{requestUpdatedData:()=>{},getSaveFiles:()=>{},createSaveFile:filename=>String,renameFile:(filename,newFilename)=>[String,String],deleteSaveFile:filename=>String},ui_gameBlur:{replaceGroup:(groupName,list)=>[String,Object]},ui_fadeScreen:{onScreenFadeStateDelayed:state=>Integer},ui_router:{addOrUpdateRoute:(route,config,options)=>[String,Object,Object],push:(routeName,params)=>[String,Object],back:()=>{},forward:()=>{},loadComplete:uiType=>String,routeChangeComplete:uiType=>String},ui_uiMods:{getVueMods:()=>{}}},ActionMap:{enableBindingCapturing:state=>Boolean},gameplay_markerInteraction:{startMissionById:(missionId,userSettings)=>[Any$1,Object],closeViewDetailPrompt:force=>Boolean,changeUserSettings:(missionId,userSettings)=>[String,Object]},ui_missionInfo:{performActivityAction:id=>Integer,setActivityIndexVisible:index=>Integer,closeDialogue:()=>{}},ui_apps_genericMissionData:{sendAllData:()=>{},setData:args=>Object,clearData:()=>{}},ui_apps_pointsBar:{requestAllData:()=>{}},ui_gameplayAppContainers:{getVisibleApps:containerId=>String,onGameplayAppContainerMounted:()=>{},onGameplayAppContainerUnmounted:()=>{},getAvailableApps:containerId=>String,setAppVisibility:(containerId,appId,visible)=>[String,String,Boolean],getAppVisibility:(containerId,appId)=>[String,String],showApp:(containerId,appId)=>[String,String],hideApp:(containerId,appId)=>[String,String],toggleApp:(containerId,appId)=>[String,String],hideAllApps:containerId=>String,getContainerContext:containerId=>String,setContainerContext:(containerId,context)=>[String,String],resetContainerContext:containerId=>String,getAvailableContexts:containerId=>String},ui_messagesTasksAppContainers:{getVisibleApps:containerId=>String,onMessagesTasksAppContainerMounted:()=>{},onMessagesTasksAppContainerUnmounted:()=>{},getAvailableApps:containerId=>String,setAppVisibility:(containerId,appId,visible)=>[String,String,Boolean],getAppVisibility:(containerId,appId)=>[String,String],showApp:(containerId,appId)=>[String,String],hideApp:(containerId,appId)=>[String,String],toggleApp:(containerId,appId)=>[String,String],hideAllApps:containerId=>String},scenetree:{"maincef:setMaxFPSLimit":fps=>Integer},settings:{notifyUI:()=>{},setState:state=>Object,getValue:value=>String,setValue:(settingName,value)=>[String,Any$1]},core_camera:{setFOV:(playerId,fovDeg)=>[Integer,Number]},core_modmanager:{requestState:()=>{}},core_vehicles:{cloneCurrent:()=>{},getModel:model=>String,getCurrentVehicleDetails:withMocked(()=>{},()=>getMockedData(`vehicle.details`)),getVehicleLicenseText:id=>Number,loadDefault:()=>{},removeAll:()=>{},removeAllExceptCurrent:()=>{},removeCurrent:()=>{},requestList:()=>{},requestListEnd:()=>{},setPlateText:plateText=>String,setMeshVisibility:state=>Number,spawnDefault:()=>{},spawnNewVehicle:(model,args)=>[String,Object],replaceVehicle:(model,args)=>[String,Object],isLicensePlateValid:text=>Any$1,getModelList:()=>{}},ui_gridSelector:{getTiles:(backendName,currentPath,pathChanged)=>[String,Object,Boolean],getFilters:backendName=>String,getActiveFilters:backendName=>String,toggleFilter:(backendName,propName,option)=>[String,String],updateRangeFilter:(backendName,propName,min$1,max$1)=>[String,String,Number,Number],resetRangeFilter:(backendName,propName)=>[String,String],resetSetFilter:(backendName,propName)=>[String,String],getSearchText:backendName=>String,setSearchText:(backendName,searchText$1)=>[String,String],getDisplayDataOptions:backendName=>String,setDisplayDataOption:(backendName,key,value)=>[String,String,Any$1],resetDisplayDataToDefaults:backendName=>String,getScreenHeaderTitleAndPath:(backendName,path)=>[String,Object],profilerFinish:(backendName,tag)=>[String,String],closedFromUI:backendName=>String,onOpenedSelectorWithItemDetails:(backendName,itemDetails)=>[String,Object],getDetails:(backendName,itemDetails)=>[String,Object],executeButton:(backendName,buttonId,additionalData)=>[String,Number,Object],getManagementDetails:backendName=>String,exitCallback:()=>{},executeDoubleClick:(backendName,itemDetails)=>[String,Object],exploreFolder:(backendName,path)=>[String,String],goToMod:(backendName,modId)=>[String,String],toggleFavourite:(backendName,itemDetails)=>[String,Object]},ui_gameplaySelector_general:{openGameplaySelector:()=>{},openChallengesSelector:()=>{},openCampaignsSelector:()=>{},openScenariosSelector:()=>{},openRallySelector:()=>{}},ui_gameplaySelector_tileGenerators_levelTiles:{getSpawningOptions:(levelName,backendName)=>[String,String],changeSpawningOption:(key,value)=>[String,Any$1],setAlwaysShowDialogue:(backendName,newValue)=>[String,Boolean]},ui_vehicleSelector_general:{openVehicleSelectorForFreeroamModal:()=>{}},ui_freeroamSelector_general:{setCustomDetailsButtons:buttons=>Array,getCustomDetailsButtons:()=>{},setManagementButtonsEnabled:enabled=>Boolean,getManagementButtonsEnabled:()=>{},openFreeroamSelectorWithCustomButtons:(buttons,callback)=>[Array,Function],setExitCallback:callback=>Function},ui_topBar:{hide:()=>{},requestData:()=>{},requestEntries:()=>{},setActiveItem:itemId=>String,selectItem:itemId=>String,show:()=>{}},core_vehicle_manager:{reloadAllVehicles:()=>{},toggleDebug:()=>{},getDebug:()=>{}},core_vehicle_colors:{setVehicleColor:(index,value)=>[Integer,Object]},core_recoveryPrompt:{getUIData:()=>{},buttonPressed:id=>[String],uiPopupButtonPressed:index=>[Integer],uiPopupCancelPressed:()=>{},onPopupClosed:()=>{}},core_remoteController:{devicesConnected:()=>Boolean,getQRCode:()=>{}},core_levels:{startLevel:()=>{}},util_screenshotCreator:{startWork:workOptions=>Any$1},util_groundModelDebug:{openWindow:()=>{}},scenario_scenariosLoader:{getList:()=>{},start:scenario=>Object},ui_apps_minimap_minimap:{setDrawTransform:(x,y,width$1,height$1)=>[Number,Number,Number,Number],hide:()=>{},toggleOptions:()=>{},getMode:()=>{},setOcclusionTransform:(id,x,y,width$1,height$1)=>[String,Number,Number,Number,Number],resetOcclusionTransform:id=>[String]},ui_apps_minimap_additionalInfo:{requestAdditionalInfo:()=>{}},WinInput:{setForwardRawEvents:state=>Boolean,setForwardFilteredEvents:state=>Boolean},Engine:{Audio:{playOnce:(channel,sound)=>[String,String]},Render:{getAdapterType:()=>{}},UI:{getUIEngine:()=>{}},Platform:{getFSInfo:()=>{}}},Steam:{showFloatingGamepadTextInput:(type,left,top,width$1,height$1)=>[Number,Number,Number,Number,Number]},setCEFTyping:state=>Boolean},api,loadAPI=()=>api||({api}=useBridge());const Any$1=i=>i,Integer=i=>i|0;var argTransformers={Any:Any$1,Boolean,String,Number,Integer,Object,Array:Any$1};signaturesToWrappers(LuaFunctionSignatures_default);var Lua_default=LuaFunctionSignatures_default;function signaturesToWrappers(sigsObject,prefixes$1=[]){let sigType,sig,funcPath,paramTypes,callName;for(let key in sigsObject)sig=sigsObject[key],sigType=typeof sig,funcPath=[...prefixes$1,key],sigType===`function`&&isArrowFunction(sig)?(paramTypes=normaliseTypes(sig(),sig.length),callName=funcPath.join(`.`),sigsObject[key]=buildWrapper(callName,paramTypes,sig.mocked)):sigType===`object`&&(sigsObject[key]=signaturesToWrappers(sig,funcPath));return sigsObject}function buildWrapper(callName,paramTypes,mockResponse=void 0){return(...args)=>run(callName,args,{argTypes:paramTypes,mockResponse})}function isArrowFunction(func){return(``+func).indexOf(`function(`)!=0}function normaliseTypes(types,paramCount){return types?Array.isArray(types)?types:[types]:Array(paramCount).fill(Any$1)}function run(funcName,args,{argTypes=Array(args.length).fill(Any$1),mockResponse}){if(loadAPI(),args.length(argTypes[i]&&argTransformers[argTypes[i].name]||Any$1)(arg)),runMocked(mockResponse,transformedArgs)):(transformedArgs=args.map((arg,i)=>serialize((argTypes[i]&&argTransformers[argTypes[i].name]||Any$1)(arg))),runRaw(`${funcName}(${transformedArgs})`))}function runRaw(luaCode,withPromise=!0){return loadAPI(),withPromise?new Promise(function(resolve$1){api.engineLua(luaCode,resolve$1)}):api.engineLua(luaCode)}function runMocked(response,args){let ret;return ret=typeof response==`function`?response(...args):response,ret&&ret.then?ret:new Promise(resolve$1=>resolve$1(ret))}function serialize(o){return loadAPI(),api.serializeToLua(o)}function serializeCheck(o){return loadAPI(),api.serializeToLua(o)}var StreamManager_default=class{streamsRefCnt={};gameAPI={};constructor(api$1){this.gameAPI=api$1}_updateSubscriptions(){let reqVehStreams=[];for(let k in this.streamsRefCnt)reqVehStreams.push(k);let subscriptions={vehicles:[{byPlayerId:0,streams:reqVehStreams}]};this.gameAPI.subscribeToEvents(JSON.stringify(subscriptions))}add(streams){for(let i=0;i!!(node.offsetWidth&&node.offsetHeight);function isVisible(node,_style=null){let tmp=node;for(_style||=document.defaultView.getComputedStyle(tmp,null);tmp.tagName!==`HTML`;){if(!tmp.isConnected||tmp.nodeType!==Node.ELEMENT_NODE||(_style=document.defaultView.getComputedStyle(tmp,null),_style.display===`none`||_style.visibility===`hidden`||_style.opacity===`0`))return!1;tmp=tmp.parentNode}return!0}function isOccluded$1(element,rect,dontIgnoreOffscreen){let x=(rect.left+rect.right)/2,y=(rect.top+rect.bottom)/2,topElement=document.elementFromPoint(x,y);if(!topElement)return!!dontIgnoreOffscreen;let tmp=topElement;for(;tmp.tagName!==`HTML`;){if(tmp==element||tmp.tagName===`MD-TOOLTIP`||tmp.noOcclude)return!1;tmp=tmp.parentNode}return!0}function dispatchKey(key,elem=window.document){if(typeof key!=`number`)throw Error(`Invalid key`);let target=elem||document,ev=document.createEvent(`KeyboardEvent`);return Object.defineProperty(ev,`keyCode`,{get:function(){return this.keyCodeVal}}),ev.initKeyboardEvent(`keydown`,!0,!0),ev.keyCodeVal=key,target.dispatchEvent(ev)}const eventDispatcherForElement=element=>(type,extras={})=>(isRef$1(element)?element.value:element).dispatchEvent(Object.assign(new Event(type),extras));function observePosition(element,callback){let trackDiv=document.createElement(`div`);setCss(trackDiv,{position:`fixed`,width:`2px`,height:`2px`,padding:`0`,margin:`0`,border:`0`,outline:`0`,"pointer-events":`none`},!0),element.classList.add(`bng-pos-observed`),trackDiv.className=`bng-pos-observer`,element.children.length?element.insertBefore(trackDiv,element.firstChild):element.appendChild(trackDiv),window.BNG_Logger&&window.BNG_Logger.assert(()=>!isAffectedByCss(trackDiv),`Position observer can break styles inside your element! Please adjust your styles using .bng-pos-observed and/or .bng-pos-observer selectors
`,element);let fixPosition=()=>{let rect=trackDiv.getBoundingClientRect();setCss(trackDiv,{"margin-left":`${parseFloat(trackDiv.style.marginLeft||`0`)-rect.left-1}px`,"margin-top":`${parseFloat(trackDiv.style.marginTop||`0`)-rect.top-1}px`},!0)};fixPosition();let intersectionObserver=new IntersectionObserver(entries=>{Math.round(entries[0].intersectionRatio*4)!==1&&(fixPosition(),callback())},{threshold:[.125,.375,.625,.875]});return intersectionObserver.observe(trackDiv),()=>{intersectionObserver.disconnect(),trackDiv.remove(),element.classList.remove(`bng-pos-observed`)}}window.observePosition=observePosition;function setCss(element,rules,important=void 0){if(window.BNG_Logger&&window.BNG_Logger.assert(()=>!Object.values(rules).some(val=>val.endsWith(` !important`)),`Rule values cannot have !important in them. Please set important flag instead.`,rules),important)for(let key in window.BNG_Logger&&window.BNG_Logger.assert(()=>!Object.keys(rules).some(name=>name!==name.toLowerCase()),`Rule names must be in kebab-case (as in CSS itself)`,rules),rules)element.style.setProperty(key,rules[key],`important`);else Object.assign(element.style,rules)}function isAffectedByCss(element,parent=void 0,fast=!1){if(!element||!element.isConnected||!parent&&!element.parentNode)return!1;parent||=element.parentNode;let clone=element.cloneNode(!fast);parent.insertBefore(clone,element);let orig=window.getComputedStyle(element),cloned=window.getComputedStyle(clone),affected=!1;for(let prop of orig)if(orig[prop]!==cloned[prop]){affected=!0;break}return parent.removeChild(clone),affected}var crossfire_exports=__export({MONITORED_UI_NAV_EVENTS:()=>MONITORED_UI_NAV_EVENTS,NAVIGABLE_ELEMENTS_SELECTOR:()=>NAVIGABLE_ELEMENTS_SELECTOR,NAV_PRIORITY_ATTR:()=>NAV_PRIORITY_ATTR,NAV_PRIORITY_CONTAINER_ATTR:()=>NAV_PRIORITY_CONTAINER_ATTR,NO_CHILD_NAV_ATTR:()=>NO_CHILD_NAV_ATTR,NO_NAV_ATTR:()=>NO_NAV_ATTR,SCROLL_ATTR:()=>SCROLL_ATTR,SCROLL_EVENT_H:()=>SCROLL_EVENT_H,SCROLL_EVENT_V:()=>SCROLL_EVENT_V,SCROLL_FORCE_ATTR:()=>SCROLL_FORCE_ATTR,collectRects:()=>collectRects,findNext:()=>findNext,focusOnElement:()=>focusOnElement,handleUINavEvent:()=>handleUINavEvent,isAvailable:()=>isAvailable,isNavigable:()=>isNavigable$1,isNavigatable:()=>isNavigable$1,isOccluded:()=>isOccluded,isVisibleFast:()=>isVisibleFast,navigate:()=>navigate,navigateScroll:()=>navigateScroll,scrollFix:()=>scrollFix,uncollectRects:()=>uncollectRects});const NAVIGABLE_ELEMENTS_SELECTOR=`[is-bng-panel], [bng-nav-item], [ng-click], [href], [bng-all-clicks], [bng-all-clicks-no-nav], [ui-sref], input, textarea, button, md-option, md-slider, md-select, md-checkbox`,NO_NAV_ATTR=`bng-no-nav`,NO_CHILD_NAV_ATTR=`bng-no-child-nav`,NAV_PRIORITY_CONTAINER_ATTR=`bng-nav-priority-container`,NAV_PRIORITY_ATTR=`bng-nav-priority-item`;var MENU_NAVIGATION_CLASS=`menu-navigation`,IGNORE_TAGS=[`HTML`,`BODY`];const SCROLL_ATTR=`bng-nav-scroll`,SCROLL_FORCE_ATTR=`bng-nav-scroll-force`;var DIR={LEFT:`left`,UP:`up`,RIGHT:`right`,DOWN:`down`},DIR_KEYS={[DIR.LEFT]:37,[DIR.UP]:38,[DIR.RIGHT]:39,[DIR.DOWN]:40},AXIS_H=`horizontal`,AXIS_V=`vertical`;const SCROLL_EVENT_H=`rotate_h_cam`,SCROLL_EVENT_V=`rotate_v_cam`;var UI_SCROLL_EVENT_ACTIONS={[SCROLL_EVENT_H]:AXIS_H,[SCROLL_EVENT_V]:AXIS_V},UI_SCROLL_ACTION_EVENTS={[AXIS_H]:SCROLL_EVENT_H,[AXIS_V]:SCROLL_EVENT_V},SCALAR_EVENT_H=`focus_lr`,SCALAR_EVENT_V=`focus_ud`,UI_SCALAR_EVENT_ACTIONS={[SCALAR_EVENT_H]:AXIS_H,[SCALAR_EVENT_V]:AXIS_V},UI_NAV_EVENT_ACTIONS={focus_u:`up`,focus_d:`down`,focus_l:`left`,focus_r:`right`,ok:`confirm`,tab_l:`tab_l`,tab_r:`tab_r`};const MONITORED_UI_NAV_EVENTS=[...Object.keys(UI_NAV_EVENT_ACTIONS),...Object.keys(UI_SCALAR_EVENT_ACTIONS)];var THUMBSTICK_DEADZONE=.5,lastScalarValue={horizontal:0,vertical:0},TRACKER_ID=`crossfire`;function focusOnElement(elem){let contentEditable=elem.contentEditable,tabIndex=elem.tabIndex;elem.contentEditable=!0,elem.tabIndex=0,elem.focus(),elem.tabIndex=tabIndex,elem.contentEditable=contentEditable}function getNavigableElements(root=null,forceAll=!1){let res=[...(root||document.body).querySelectorAll(NAVIGABLE_ELEMENTS_SELECTOR)];return forceAll||(res=res.filter(elem=>{if(elem.parentNode.closest(`[bng-no-child-nav="1"], [bng-no-child-nav="true"]`))return!1;let noNav=elem.attributes.getNamedItem(NO_NAV_ATTR);return!noNav||noNav.value!==`true`})),res}function isNavigable$1(elem,forceAll=!1){if(!elem||IGNORE_TAGS.includes(elem.nodeName||elem.tagName))return!1;if(elem.classList.contains(MENU_NAVIGATION_CLASS))return!0;let parent=elem.parentNode;if(!parent)return!1;let children=getNavigableElements(parent,forceAll);for(let child of children)if(child===elem)return!0;return!1}function uncollectRects(){let ns=getNavigableElements();for(let node of ns)node.classList.remove(MENU_NAVIGATION_CLASS)}var warnPrioNesting=window.beamng&&!window.beamng.shipping;function collectRects(direction$1,parent,forceAll=!1){let links={};direction$1?links[direction$1]=[]:(links.up=[],links.down=[],links.left=[],links.right=[]);let prioNodes=new WeakSet,ns=getNavigableElements(parent,forceAll);for(let node of ns){if(!isAvailable(node)){node.classList.remove(MENU_NAVIGATION_CLASS);continue}let rectNode=node,prioNode=node.closest(`[${NAV_PRIORITY_CONTAINER_ATTR}]`);if(prioNode&&prioNode!==node&&!prioNodes.has(prioNode)){if(prioNodes.add(prioNode),!warnPrioNesting){let parent$1=prioNode.parentNode.closest(`[${NAV_PRIORITY_CONTAINER_ATTR}]`);parent$1&&(console.warn(`Priority container nesting is not supported. Please remove the nested priority container.
`,CHAR_LS=`\u2028`,CHAR_PS=`\u2029`;function createScanner(str){let _buf=str,_index=0,_line=1,_column=1,_peekOffset=0,isCRLF=index$1=>_buf[index$1]===CHAR_CR&&_buf[index$1+1]===CHAR_LF,isLF=index$1=>_buf[index$1]===CHAR_LF,isPS=index$1=>_buf[index$1]===CHAR_PS,isLS=index$1=>_buf[index$1]===CHAR_LS,isLineEnd=index$1=>isCRLF(index$1)||isLF(index$1)||isPS(index$1)||isLS(index$1),index=()=>_index,line=()=>_line,column=()=>_column,peekOffset=()=>_peekOffset,charAt=offset$2=>isCRLF(offset$2)||isPS(offset$2)||isLS(offset$2)?CHAR_LF:_buf[offset$2],currentChar=()=>charAt(_index),currentPeek=()=>charAt(_index+_peekOffset);function next(){return _peekOffset=0,isLineEnd(_index)&&(_line++,_column=0),isCRLF(_index)&&_index++,_index++,_column++,_buf[_index]}function peek(){return isCRLF(_index+_peekOffset)&&_peekOffset++,_peekOffset++,_buf[_index+_peekOffset]}function reset$1(){_index=0,_line=1,_column=1,_peekOffset=0}function resetPeek(offset$2=0){_peekOffset=offset$2}function skipToPeek(){let target=_index+_peekOffset;for(;target!==_index;)next();_peekOffset=0}return{index,line,column,peekOffset,charAt,currentChar,currentPeek,next,peek,reset:reset$1,resetPeek,skipToPeek}}var EOF=void 0,DOT=`.`,LITERAL_DELIMITER=`'`,ERROR_DOMAIN$3=`tokenizer`;function createTokenizer(source,options={}){let location$1=options.location!==!1,_scnr=createScanner(source),currentOffset=()=>_scnr.index(),currentPosition=()=>createPosition(_scnr.line(),_scnr.column(),_scnr.index()),_initLoc=currentPosition(),_initOffset=currentOffset(),_context={currentType:13,offset:_initOffset,startLoc:_initLoc,endLoc:_initLoc,lastType:13,lastOffset:_initOffset,lastStartLoc:_initLoc,lastEndLoc:_initLoc,braceNest:0,inLinked:!1,text:``},context=()=>_context,{onError}=options;function emitError$1(code,pos,offset$2,...args){let ctx=context();pos.column+=offset$2,pos.offset+=offset$2,onError&&onError(createCompileError(code,location$1?createLocation(ctx.startLoc,pos):null,{domain:ERROR_DOMAIN$3,args}))}function getToken(context$1,type,value){context$1.endLoc=currentPosition(),context$1.currentType=type;let token={type};return location$1&&(token.loc=createLocation(context$1.startLoc,context$1.endLoc)),value!=null&&(token.value=value),token}let getEndToken=context$1=>getToken(context$1,13);function eat(scnr,ch){return scnr.currentChar()===ch?(scnr.next(),ch):(emitError$1(CompileErrorCodes.EXPECTED_TOKEN,currentPosition(),0,ch),``)}function peekSpaces(scnr){let buf=``;for(;scnr.currentPeek()===CHAR_SP||scnr.currentPeek()===CHAR_LF;)buf+=scnr.currentPeek(),scnr.peek();return buf}function skipSpaces(scnr){let buf=peekSpaces(scnr);return scnr.skipToPeek(),buf}function isIdentifierStart(ch){if(ch===EOF)return!1;let cc=ch.charCodeAt(0);return cc>=97&&cc<=122||cc>=65&&cc<=90||cc===95}function isNumberStart(ch){if(ch===EOF)return!1;let cc=ch.charCodeAt(0);return cc>=48&&cc<=57}function isNamedIdentifierStart(scnr,context$1){let{currentType}=context$1;if(currentType!==2)return!1;peekSpaces(scnr);let ret=isIdentifierStart(scnr.currentPeek());return scnr.resetPeek(),ret}function isListIdentifierStart(scnr,context$1){let{currentType}=context$1;if(currentType!==2)return!1;peekSpaces(scnr);let ret=isNumberStart(scnr.currentPeek()===`-`?scnr.peek():scnr.currentPeek());return scnr.resetPeek(),ret}function isLiteralStart(scnr,context$1){let{currentType}=context$1;if(currentType!==2)return!1;peekSpaces(scnr);let ret=scnr.currentPeek()===LITERAL_DELIMITER;return scnr.resetPeek(),ret}function isLinkedDotStart(scnr,context$1){let{currentType}=context$1;if(currentType!==7)return!1;peekSpaces(scnr);let ret=scnr.currentPeek()===`.`;return scnr.resetPeek(),ret}function isLinkedModifierStart(scnr,context$1){let{currentType}=context$1;if(currentType!==8)return!1;peekSpaces(scnr);let ret=isIdentifierStart(scnr.currentPeek());return scnr.resetPeek(),ret}function isLinkedDelimiterStart(scnr,context$1){let{currentType}=context$1;if(!(currentType===7||currentType===11))return!1;peekSpaces(scnr);let ret=scnr.currentPeek()===`:`;return scnr.resetPeek(),ret}function isLinkedReferStart(scnr,context$1){let{currentType}=context$1;if(currentType!==9)return!1;let fn=()=>{let ch=scnr.currentPeek();return ch===`{`?isIdentifierStart(scnr.peek()):ch===`@`||ch===`|`||ch===`:`||ch===`.`||ch===CHAR_SP||!ch?!1:ch===CHAR_LF?(scnr.peek(),fn()):isTextStart(scnr,!1)},ret=fn();return scnr.resetPeek(),ret}function isPluralStart(scnr){peekSpaces(scnr);let ret=scnr.currentPeek()===`|`;return scnr.resetPeek(),ret}function isTextStart(scnr,reset$1=!0){let fn=(hasSpace=!1,prev=``)=>{let ch=scnr.currentPeek();return ch===`{`||ch===`@`||!ch?hasSpace:ch===`|`?!(prev===CHAR_SP||prev===CHAR_LF):ch===CHAR_SP?(scnr.peek(),fn(!0,CHAR_SP)):ch===CHAR_LF?(scnr.peek(),fn(!0,CHAR_LF)):!0},ret=fn();return reset$1&&scnr.resetPeek(),ret}function takeChar(scnr,fn){let ch=scnr.currentChar();return ch===EOF?EOF:fn(ch)?(scnr.next(),ch):null}function isIdentifier(ch){let cc=ch.charCodeAt(0);return cc>=97&&cc<=122||cc>=65&&cc<=90||cc>=48&&cc<=57||cc===95||cc===36}function takeIdentifierChar(scnr){return takeChar(scnr,isIdentifier)}function isNamedIdentifier(ch){let cc=ch.charCodeAt(0);return cc>=97&&cc<=122||cc>=65&&cc<=90||cc>=48&&cc<=57||cc===95||cc===36||cc===45}function takeNamedIdentifierChar(scnr){return takeChar(scnr,isNamedIdentifier)}function isDigit(ch){let cc=ch.charCodeAt(0);return cc>=48&&cc<=57}function takeDigit(scnr){return takeChar(scnr,isDigit)}function isHexDigit(ch){let cc=ch.charCodeAt(0);return cc>=48&&cc<=57||cc>=65&&cc<=70||cc>=97&&cc<=102}function takeHexDigit(scnr){return takeChar(scnr,isHexDigit)}function getDigits(scnr){let ch=``,num=``;for(;ch=takeDigit(scnr);)num+=ch;return num}function readText(scnr){let buf=``;for(;;){let ch=scnr.currentChar();if(ch===`{`||ch===`}`||ch===`@`||ch===`|`||!ch)break;if(ch===CHAR_SP||ch===CHAR_LF)if(isTextStart(scnr))buf+=ch,scnr.next();else if(isPluralStart(scnr))break;else buf+=ch,scnr.next();else buf+=ch,scnr.next()}return buf}function readNamedIdentifier(scnr){skipSpaces(scnr);let ch=``,name=``;for(;ch=takeNamedIdentifierChar(scnr);)name+=ch;let currentChar=scnr.currentChar();if(currentChar&¤tChar!==`}`&¤tChar!==EOF&¤tChar!==CHAR_SP&¤tChar!==CHAR_LF&¤tChar!==` `){let invalidPart=readInvalidIdentifier(scnr);return emitError$1(CompileErrorCodes.INVALID_TOKEN_IN_PLACEHOLDER,currentPosition(),0,name+invalidPart),name+invalidPart}return scnr.currentChar()===EOF&&emitError$1(CompileErrorCodes.UNTERMINATED_CLOSING_BRACE,currentPosition(),0),name}function readListIdentifier(scnr){skipSpaces(scnr);let value=``;return scnr.currentChar()===`-`?(scnr.next(),value+=`-${getDigits(scnr)}`):value+=getDigits(scnr),scnr.currentChar()===EOF&&emitError$1(CompileErrorCodes.UNTERMINATED_CLOSING_BRACE,currentPosition(),0),value}function isLiteral(ch){return ch!==LITERAL_DELIMITER&&ch!==CHAR_LF}function readLiteral(scnr){skipSpaces(scnr),eat(scnr,`'`);let ch=``,literal=``;for(;ch=takeChar(scnr,isLiteral);)ch===`\\`?literal+=readEscapeSequence(scnr):literal+=ch;let current=scnr.currentChar();return current===CHAR_LF||current===EOF?(emitError$1(CompileErrorCodes.UNTERMINATED_SINGLE_QUOTE_IN_PLACEHOLDER,currentPosition(),0),current===CHAR_LF&&(scnr.next(),eat(scnr,`'`)),literal):(eat(scnr,`'`),literal)}function readEscapeSequence(scnr){let ch=scnr.currentChar();switch(ch){case`\\`:case`'`:return scnr.next(),`\\${ch}`;case`u`:return readUnicodeEscapeSequence(scnr,ch,4);case`U`:return readUnicodeEscapeSequence(scnr,ch,6);default:return emitError$1(CompileErrorCodes.UNKNOWN_ESCAPE_SEQUENCE,currentPosition(),0,ch),``}}function readUnicodeEscapeSequence(scnr,unicode,digits){eat(scnr,unicode);let sequence=``;for(let i=0;i{let ch=scnr.currentChar();return ch===`{`||ch===`@`||ch===`|`||ch===`(`||ch===`)`||!ch||ch===CHAR_SP?buf:(buf+=ch,scnr.next(),fn(buf))};return fn(``)}function readPlural(scnr){skipSpaces(scnr);let plural=eat(scnr,`|`);return skipSpaces(scnr),plural}function readTokenInPlaceholder(scnr,context$1){let token=null;switch(scnr.currentChar()){case`{`:return context$1.braceNest>=1&&emitError$1(CompileErrorCodes.NOT_ALLOW_NEST_PLACEHOLDER,currentPosition(),0),scnr.next(),token=getToken(context$1,2,`{`),skipSpaces(scnr),context$1.braceNest++,token;case`}`:return context$1.braceNest>0&&context$1.currentType===2&&emitError$1(CompileErrorCodes.EMPTY_PLACEHOLDER,currentPosition(),0),scnr.next(),token=getToken(context$1,3,`}`),context$1.braceNest--,context$1.braceNest>0&&skipSpaces(scnr),context$1.inLinked&&context$1.braceNest===0&&(context$1.inLinked=!1),token;case`@`:return context$1.braceNest>0&&emitError$1(CompileErrorCodes.UNTERMINATED_CLOSING_BRACE,currentPosition(),0),token=readTokenInLinked(scnr,context$1)||getEndToken(context$1),context$1.braceNest=0,token;default:{let validNamedIdentifier=!0,validListIdentifier=!0,validLiteral=!0;if(isPluralStart(scnr))return context$1.braceNest>0&&emitError$1(CompileErrorCodes.UNTERMINATED_CLOSING_BRACE,currentPosition(),0),token=getToken(context$1,1,readPlural(scnr)),context$1.braceNest=0,context$1.inLinked=!1,token;if(context$1.braceNest>0&&(context$1.currentType===4||context$1.currentType===5||context$1.currentType===6))return emitError$1(CompileErrorCodes.UNTERMINATED_CLOSING_BRACE,currentPosition(),0),context$1.braceNest=0,readToken(scnr,context$1);if(validNamedIdentifier=isNamedIdentifierStart(scnr,context$1))return token=getToken(context$1,4,readNamedIdentifier(scnr)),skipSpaces(scnr),token;if(validListIdentifier=isListIdentifierStart(scnr,context$1))return token=getToken(context$1,5,readListIdentifier(scnr)),skipSpaces(scnr),token;if(validLiteral=isLiteralStart(scnr,context$1))return token=getToken(context$1,6,readLiteral(scnr)),skipSpaces(scnr),token;if(!validNamedIdentifier&&!validListIdentifier&&!validLiteral)return token=getToken(context$1,12,readInvalidIdentifier(scnr)),emitError$1(CompileErrorCodes.INVALID_TOKEN_IN_PLACEHOLDER,currentPosition(),0,token.value),skipSpaces(scnr),token;break}}return token}function readTokenInLinked(scnr,context$1){let{currentType}=context$1,token=null,ch=scnr.currentChar();switch((currentType===7||currentType===8||currentType===11||currentType===9)&&(ch===CHAR_LF||ch===CHAR_SP)&&emitError$1(CompileErrorCodes.INVALID_LINKED_FORMAT,currentPosition(),0),ch){case`@`:return scnr.next(),token=getToken(context$1,7,`@`),context$1.inLinked=!0,token;case`.`:return skipSpaces(scnr),scnr.next(),getToken(context$1,8,`.`);case`:`:return skipSpaces(scnr),scnr.next(),getToken(context$1,9,`:`);default:return isPluralStart(scnr)?(token=getToken(context$1,1,readPlural(scnr)),context$1.braceNest=0,context$1.inLinked=!1,token):isLinkedDotStart(scnr,context$1)||isLinkedDelimiterStart(scnr,context$1)?(skipSpaces(scnr),readTokenInLinked(scnr,context$1)):isLinkedModifierStart(scnr,context$1)?(skipSpaces(scnr),getToken(context$1,11,readLinkedModifier(scnr))):isLinkedReferStart(scnr,context$1)?(skipSpaces(scnr),ch===`{`?readTokenInPlaceholder(scnr,context$1)||token:getToken(context$1,10,readLinkedRefer(scnr))):(currentType===7&&emitError$1(CompileErrorCodes.INVALID_LINKED_FORMAT,currentPosition(),0),context$1.braceNest=0,context$1.inLinked=!1,readToken(scnr,context$1))}}function readToken(scnr,context$1){let token={type:13};if(context$1.braceNest>0)return readTokenInPlaceholder(scnr,context$1)||getEndToken(context$1);if(context$1.inLinked)return readTokenInLinked(scnr,context$1)||getEndToken(context$1);switch(scnr.currentChar()){case`{`:return readTokenInPlaceholder(scnr,context$1)||getEndToken(context$1);case`}`:return emitError$1(CompileErrorCodes.UNBALANCED_CLOSING_BRACE,currentPosition(),0),scnr.next(),getToken(context$1,3,`}`);case`@`:return readTokenInLinked(scnr,context$1)||getEndToken(context$1);default:if(isPluralStart(scnr))return token=getToken(context$1,1,readPlural(scnr)),context$1.braceNest=0,context$1.inLinked=!1,token;if(isTextStart(scnr))return getToken(context$1,0,readText(scnr));break}return token}function nextToken(){let{currentType,offset:offset$2,startLoc,endLoc}=_context;return _context.lastType=currentType,_context.lastOffset=offset$2,_context.lastStartLoc=startLoc,_context.lastEndLoc=endLoc,_context.offset=currentOffset(),_context.startLoc=currentPosition(),_scnr.currentChar()===EOF?getToken(_context,13):readToken(_scnr,_context)}return{nextToken,currentOffset,currentPosition,context}}var ERROR_DOMAIN$2=`parser`,KNOWN_ESCAPES=/(?:\\\\|\\'|\\u([0-9a-fA-F]{4})|\\U([0-9a-fA-F]{6}))/g;function fromEscapeSequence(match,codePoint4,codePoint6){switch(match){case`\\\\`:return`\\`;case`\\'`:return`'`;default:{let codePoint=parseInt(codePoint4||codePoint6,16);return codePoint<=55295||codePoint>=57344?String.fromCodePoint(codePoint):`�`}}}function createParser(options={}){let location$1=options.location!==!1,{onError}=options;function emitError$1(tokenzer,code,start,offset$2,...args){let end=tokenzer.currentPosition();end.offset+=offset$2,end.column+=offset$2,onError&&onError(createCompileError(code,location$1?createLocation(start,end):null,{domain:ERROR_DOMAIN$2,args}))}function startNode(type,offset$2,loc){let node={type};return location$1&&(node.start=offset$2,node.end=offset$2,node.loc={start:loc,end:loc}),node}function endNode(node,offset$2,pos,type){location$1&&(node.end=offset$2,node.loc&&(node.loc.end=pos))}function parseText$1(tokenizer$1,value){let context=tokenizer$1.context(),node=startNode(3,context.offset,context.startLoc);return node.value=value,endNode(node,tokenizer$1.currentOffset(),tokenizer$1.currentPosition()),node}function parseList(tokenizer$1,index){let{lastOffset:offset$2,lastStartLoc:loc}=tokenizer$1.context(),node=startNode(5,offset$2,loc);return node.index=parseInt(index,10),tokenizer$1.nextToken(),endNode(node,tokenizer$1.currentOffset(),tokenizer$1.currentPosition()),node}function parseNamed(tokenizer$1,key){let{lastOffset:offset$2,lastStartLoc:loc}=tokenizer$1.context(),node=startNode(4,offset$2,loc);return node.key=key,tokenizer$1.nextToken(),endNode(node,tokenizer$1.currentOffset(),tokenizer$1.currentPosition()),node}function parseLiteral(tokenizer$1,value){let{lastOffset:offset$2,lastStartLoc:loc}=tokenizer$1.context(),node=startNode(9,offset$2,loc);return node.value=value.replace(KNOWN_ESCAPES,fromEscapeSequence),tokenizer$1.nextToken(),endNode(node,tokenizer$1.currentOffset(),tokenizer$1.currentPosition()),node}function parseLinkedModifier(tokenizer$1){let token=tokenizer$1.nextToken(),context=tokenizer$1.context(),{lastOffset:offset$2,lastStartLoc:loc}=context,node=startNode(8,offset$2,loc);return token.type===11?(token.value??emitError$1(tokenizer$1,CompileErrorCodes.UNEXPECTED_LEXICAL_ANALYSIS,context.lastStartLoc,0,getTokenCaption(token)),node.value=token.value||``,endNode(node,tokenizer$1.currentOffset(),tokenizer$1.currentPosition()),{node}):(emitError$1(tokenizer$1,CompileErrorCodes.UNEXPECTED_EMPTY_LINKED_MODIFIER,context.lastStartLoc,0),node.value=``,endNode(node,offset$2,loc),{nextConsumeToken:token,node})}function parseLinkedKey(tokenizer$1,value){let context=tokenizer$1.context(),node=startNode(7,context.offset,context.startLoc);return node.value=value,endNode(node,tokenizer$1.currentOffset(),tokenizer$1.currentPosition()),node}function parseLinked(tokenizer$1){let context=tokenizer$1.context(),linkedNode=startNode(6,context.offset,context.startLoc),token=tokenizer$1.nextToken();if(token.type===8){let parsed=parseLinkedModifier(tokenizer$1);linkedNode.modifier=parsed.node,token=parsed.nextConsumeToken||tokenizer$1.nextToken()}switch(token.type!==9&&emitError$1(tokenizer$1,CompileErrorCodes.UNEXPECTED_LEXICAL_ANALYSIS,context.lastStartLoc,0,getTokenCaption(token)),token=tokenizer$1.nextToken(),token.type===2&&(token=tokenizer$1.nextToken()),token.type){case 10:token.value??emitError$1(tokenizer$1,CompileErrorCodes.UNEXPECTED_LEXICAL_ANALYSIS,context.lastStartLoc,0,getTokenCaption(token)),linkedNode.key=parseLinkedKey(tokenizer$1,token.value||``);break;case 4:token.value??emitError$1(tokenizer$1,CompileErrorCodes.UNEXPECTED_LEXICAL_ANALYSIS,context.lastStartLoc,0,getTokenCaption(token)),linkedNode.key=parseNamed(tokenizer$1,token.value||``);break;case 5:token.value??emitError$1(tokenizer$1,CompileErrorCodes.UNEXPECTED_LEXICAL_ANALYSIS,context.lastStartLoc,0,getTokenCaption(token)),linkedNode.key=parseList(tokenizer$1,token.value||``);break;case 6:token.value??emitError$1(tokenizer$1,CompileErrorCodes.UNEXPECTED_LEXICAL_ANALYSIS,context.lastStartLoc,0,getTokenCaption(token)),linkedNode.key=parseLiteral(tokenizer$1,token.value||``);break;default:{emitError$1(tokenizer$1,CompileErrorCodes.UNEXPECTED_EMPTY_LINKED_KEY,context.lastStartLoc,0);let nextContext=tokenizer$1.context(),emptyLinkedKeyNode=startNode(7,nextContext.offset,nextContext.startLoc);return emptyLinkedKeyNode.value=``,endNode(emptyLinkedKeyNode,nextContext.offset,nextContext.startLoc),linkedNode.key=emptyLinkedKeyNode,endNode(linkedNode,nextContext.offset,nextContext.startLoc),{nextConsumeToken:token,node:linkedNode}}}return endNode(linkedNode,tokenizer$1.currentOffset(),tokenizer$1.currentPosition()),{node:linkedNode}}function parseMessage(tokenizer$1){let context=tokenizer$1.context(),node=startNode(2,context.currentType===1?tokenizer$1.currentOffset():context.offset,context.currentType===1?context.endLoc:context.startLoc);node.items=[];let nextToken=null;do{let token=nextToken||tokenizer$1.nextToken();switch(nextToken=null,token.type){case 0:token.value??emitError$1(tokenizer$1,CompileErrorCodes.UNEXPECTED_LEXICAL_ANALYSIS,context.lastStartLoc,0,getTokenCaption(token)),node.items.push(parseText$1(tokenizer$1,token.value||``));break;case 5:token.value??emitError$1(tokenizer$1,CompileErrorCodes.UNEXPECTED_LEXICAL_ANALYSIS,context.lastStartLoc,0,getTokenCaption(token)),node.items.push(parseList(tokenizer$1,token.value||``));break;case 4:token.value??emitError$1(tokenizer$1,CompileErrorCodes.UNEXPECTED_LEXICAL_ANALYSIS,context.lastStartLoc,0,getTokenCaption(token)),node.items.push(parseNamed(tokenizer$1,token.value||``));break;case 6:token.value??emitError$1(tokenizer$1,CompileErrorCodes.UNEXPECTED_LEXICAL_ANALYSIS,context.lastStartLoc,0,getTokenCaption(token)),node.items.push(parseLiteral(tokenizer$1,token.value||``));break;case 7:{let parsed=parseLinked(tokenizer$1);node.items.push(parsed.node),nextToken=parsed.nextConsumeToken||null;break}}}while(context.currentType!==13&&context.currentType!==1);return endNode(node,context.currentType===1?context.lastOffset:tokenizer$1.currentOffset(),context.currentType===1?context.lastEndLoc:tokenizer$1.currentPosition()),node}function parsePlural(tokenizer$1,offset$2,loc,msgNode){let context=tokenizer$1.context(),hasEmptyMessage=msgNode.items.length===0,node=startNode(1,offset$2,loc);node.cases=[],node.cases.push(msgNode);do{let msg=parseMessage(tokenizer$1);hasEmptyMessage||=msg.items.length===0,node.cases.push(msg)}while(context.currentType!==13);return hasEmptyMessage&&emitError$1(tokenizer$1,CompileErrorCodes.MUST_HAVE_MESSAGES_IN_PLURAL,loc,0),endNode(node,tokenizer$1.currentOffset(),tokenizer$1.currentPosition()),node}function parseResource(tokenizer$1){let context=tokenizer$1.context(),{offset:offset$2,startLoc}=context,msgNode=parseMessage(tokenizer$1);return context.currentType===13?msgNode:parsePlural(tokenizer$1,offset$2,startLoc,msgNode)}function parse$2(source){let tokenizer$1=createTokenizer(source,assign$1({},options)),context=tokenizer$1.context(),node=startNode(0,context.offset,context.startLoc);return location$1&&node.loc&&(node.loc.source=source),node.body=parseResource(tokenizer$1),options.onCacheKey&&(node.cacheKey=options.onCacheKey(source)),context.currentType!==13&&emitError$1(tokenizer$1,CompileErrorCodes.UNEXPECTED_LEXICAL_ANALYSIS,context.lastStartLoc,0,source[context.offset]||``),endNode(node,tokenizer$1.currentOffset(),tokenizer$1.currentPosition()),node}return{parse:parse$2}}function getTokenCaption(token){if(token.type===13)return`EOF`;let name=(token.value||``).replace(/\r?\n/gu,`\\n`);return name.length>10?name.slice(0,9)+`…`:name}function createTransformer(ast,options={}){let _context={ast,helpers:new Set};return{context:()=>_context,helper:name=>(_context.helpers.add(name),name)}}function traverseNodes(nodes,transformer){for(let i=0;ioptimizeMessageNode(c)),ast}function optimizeMessageNode(message){if(message.items.length===1){let item=message.items[0];(item.type===3||item.type===9)&&(message.static=item.value,delete item.value)}else{let values=[];for(let i=0;i_context;function push(code,node){_context.code+=code}function _newline(n,withBreakLine=!0){let _breakLineCode=withBreakLine?breakLineCode:``;push(_needIndent?_breakLineCode+`  `.repeat(n):_breakLineCode)}function indent(withNewLine=!0){let level$1=++_context.indentLevel;withNewLine&&_newline(level$1)}function deindent(withNewLine=!0){let level$1=--_context.indentLevel;withNewLine&&_newline(level$1)}function newline(){_newline(_context.indentLevel)}return{context,push,indent,deindent,newline,helper:key=>`_${key}`,needIndent:()=>_context.needIndent}}function generateLinkedNode(generator,node){let{helper}=generator;generator.push(`${helper(`linked`)}(`),generateNode(generator,node.key),node.modifier?(generator.push(`, `),generateNode(generator,node.modifier),generator.push(`, _type`)):generator.push(`, undefined, _type`),generator.push(`)`)}function generateMessageNode(generator,node){let{helper,needIndent}=generator;generator.push(`${helper(`normalize`)}([`),generator.indent(needIndent());let length=node.items.length;for(let i=0;i1){generator.push(`${helper(`plural`)}([`),generator.indent(needIndent());let length=node.cases.length;for(let i=0;i{let mode=isString(options.mode)?options.mode:`normal`,filename=isString(options.filename)?options.filename:`message.intl`,sourceMap=!!options.sourceMap,breakLineCode=options.breakLineCode==null?mode===`arrow`?`;`:`
`:options.breakLineCode,needIndent=options.needIndent?options.needIndent:mode!==`arrow`,helpers=ast.helpers||[],generator=createCodeGenerator(ast,{mode,filename,sourceMap,breakLineCode,needIndent});generator.push(mode===`normal`?`function __msg__ (ctx) {`:`(ctx) => {`),generator.indent(needIndent),helpers.length>0&&(generator.push(`const { ${join(helpers.map(s=>`${s}: _${s}`),`, `)} } = ctx`),generator.newline()),generator.push(`return `),generateNode(generator,ast),generator.deindent(needIndent),generator.push(`}`),delete ast.helpers;let{code,map}=generator.context();return{ast,code,map:map?map.toJSON():void 0}};function baseCompile(source,options={}){let assignedOptions=assign$1({},options),jit=!!assignedOptions.jit,enalbeMinify=!!assignedOptions.minify,enambeOptimize=assignedOptions.optimize==null?!0:assignedOptions.optimize,ast=createParser(assignedOptions).parse(source);return jit?(enambeOptimize&&optimize(ast),enalbeMinify&&minify(ast),{ast,code:``}):(transform(ast,assignedOptions),generate(ast,assignedOptions))}function initFeatureFlags$1(){typeof __INTLIFY_PROD_DEVTOOLS__!=`boolean`&&(getGlobalThis().__INTLIFY_PROD_DEVTOOLS__=!1),typeof __INTLIFY_DROP_MESSAGE_COMPILER__!=`boolean`&&(getGlobalThis().__INTLIFY_DROP_MESSAGE_COMPILER__=!1)}function isMessageAST(val){return isObject(val)&&resolveType(val)===0&&(hasOwn(val,`b`)||hasOwn(val,`body`))}var PROPS_BODY=[`b`,`body`];function resolveBody(node){return resolveProps(node,PROPS_BODY)}var PROPS_CASES=[`c`,`cases`];function resolveCases(node){return resolveProps(node,PROPS_CASES,[])}var PROPS_STATIC=[`s`,`static`];function resolveStatic(node){return resolveProps(node,PROPS_STATIC)}var PROPS_ITEMS=[`i`,`items`];function resolveItems(node){return resolveProps(node,PROPS_ITEMS,[])}var PROPS_TYPE=[`t`,`type`];function resolveType(node){return resolveProps(node,PROPS_TYPE)}var PROPS_VALUE=[`v`,`value`];function resolveValue$1(node,type){let resolved=resolveProps(node,PROPS_VALUE);if(resolved!=null)return resolved;throw createUnhandleNodeError(type)}var PROPS_MODIFIER=[`m`,`modifier`];function resolveLinkedModifier(node){return resolveProps(node,PROPS_MODIFIER)}var PROPS_KEY=[`k`,`key`];function resolveLinkedKey(node){let resolved=resolveProps(node,PROPS_KEY);if(resolved)return resolved;throw createUnhandleNodeError(6)}function resolveProps(node,props,defaultValue){for(let i=0;iformatParts(ctx,ast)}function formatParts(ctx,ast){let body=resolveBody(ast);if(body==null)throw createUnhandleNodeError(0);if(resolveType(body)===1){let cases=resolveCases(body);return ctx.plural(cases.reduce((messages,c)=>[...messages,formatMessageParts(ctx,c)],[]))}else return formatMessageParts(ctx,body)}function formatMessageParts(ctx,node){let static_=resolveStatic(node);if(static_!=null)return ctx.type===`text`?static_:ctx.normalize([static_]);{let messages=resolveItems(node).reduce((acm,c)=>[...acm,formatMessagePart(ctx,c)],[]);return ctx.normalize(messages)}}function formatMessagePart(ctx,node){let type=resolveType(node);switch(type){case 3:return resolveValue$1(node,type);case 9:return resolveValue$1(node,type);case 4:{let named=node;if(hasOwn(named,`k`)&&named.k)return ctx.interpolate(ctx.named(named.k));if(hasOwn(named,`key`)&&named.key)return ctx.interpolate(ctx.named(named.key));throw createUnhandleNodeError(type)}case 5:{let list=node;if(hasOwn(list,`i`)&&isNumber(list.i))return ctx.interpolate(ctx.list(list.i));if(hasOwn(list,`index`)&&isNumber(list.index))return ctx.interpolate(ctx.list(list.index));throw createUnhandleNodeError(type)}case 6:{let linked=node,modifier=resolveLinkedModifier(linked),key=resolveLinkedKey(linked);return ctx.linked(formatMessagePart(ctx,key),modifier?formatMessagePart(ctx,modifier):void 0,ctx.type)}case 7:return resolveValue$1(node,type);case 8:return resolveValue$1(node,type);default:throw Error(`unhandled node on format message part: ${type}`)}}var defaultOnCacheKey=message=>message,compileCache=create();function baseCompile$1(message,options={}){let detectError=!1,onError=options.onError||defaultOnError;return options.onError=err=>{detectError=!0,onError(err)},{...baseCompile(message,options),detectError}}function compile(message,context){if(!__INTLIFY_DROP_MESSAGE_COMPILER__&&isString(message)){isBoolean(context.warnHtmlMessage)&&context.warnHtmlMessage;let cacheKey=(context.onCacheKey||defaultOnCacheKey)(message),cached=compileCache[cacheKey];if(cached)return cached;let{ast,detectError}=baseCompile$1(message,{...context,location:!1,jit:!0}),msg=format$1(ast);return detectError?msg:compileCache[cacheKey]=msg}else{let cacheKey=message.cacheKey;return cacheKey?compileCache[cacheKey]||(compileCache[cacheKey]=format$1(message)):format$1(message)}}var devtools=null;function setDevToolsHook(hook){devtools=hook}function initI18nDevTools(i18n,version$2,meta){devtools&&devtools.emit(`i18n:init`,{timestamp:Date.now(),i18n,version:version$2,meta})}var translateDevTools=createDevToolsHook(`function:translate`);function createDevToolsHook(hook){return payloads=>devtools&&devtools.emit(hook,payloads)}var CoreErrorCodes={INVALID_ARGUMENT:17,INVALID_DATE_ARGUMENT:18,INVALID_ISO_DATE_ARGUMENT:19,NOT_SUPPORT_NON_STRING_MESSAGE:20,NOT_SUPPORT_LOCALE_PROMISE_VALUE:21,NOT_SUPPORT_LOCALE_ASYNC_FUNCTION:22,NOT_SUPPORT_LOCALE_TYPE:23},CORE_ERROR_CODES_EXTEND_POINT=24;function createCoreError(code){return createCompileError(code,null,void 0)}CoreErrorCodes.INVALID_ARGUMENT,CoreErrorCodes.INVALID_DATE_ARGUMENT,CoreErrorCodes.INVALID_ISO_DATE_ARGUMENT,CoreErrorCodes.NOT_SUPPORT_NON_STRING_MESSAGE,CoreErrorCodes.NOT_SUPPORT_LOCALE_PROMISE_VALUE,CoreErrorCodes.NOT_SUPPORT_LOCALE_ASYNC_FUNCTION,CoreErrorCodes.NOT_SUPPORT_LOCALE_TYPE;function getLocale(context,options){return options.locale==null?resolveLocale(context.locale):resolveLocale(options.locale)}var _resolveLocale;function resolveLocale(locale){if(isString(locale))return locale;if(isFunction(locale)){if(locale.resolvedOnce&&_resolveLocale!=null)return _resolveLocale;if(locale.constructor.name===`Function`){let resolve$1=locale();if(isPromise(resolve$1))throw createCoreError(CoreErrorCodes.NOT_SUPPORT_LOCALE_PROMISE_VALUE);return _resolveLocale=resolve$1}else throw createCoreError(CoreErrorCodes.NOT_SUPPORT_LOCALE_ASYNC_FUNCTION)}else throw createCoreError(CoreErrorCodes.NOT_SUPPORT_LOCALE_TYPE)}function fallbackWithSimple(ctx,fallback,start){return[...new Set([start,...isArray$1(fallback)?fallback:isObject(fallback)?Object.keys(fallback):isString(fallback)?[fallback]:[start]])]}var pathStateMachine=[];pathStateMachine[0]={w:[0],i:[3,0],"[":[4],o:[7]},pathStateMachine[1]={w:[1],".":[2],"[":[4],o:[7]},pathStateMachine[2]={w:[2],i:[3,0],0:[3,0]},pathStateMachine[3]={i:[3,0],0:[3,0],w:[1,1],".":[2,1],"[":[4,1],o:[7,1]},pathStateMachine[4]={"'":[5,0],'"':[6,0],"[":[4,2],"]":[1,3],o:8,l:[4,0]},pathStateMachine[5]={"'":[4,0],o:8,l:[5,0]},pathStateMachine[6]={'"':[4,0],o:8,l:[6,0]};function resolveWithKeyValue(obj,path){return isObject(obj)?obj[path]:null}var CoreWarnCodes={NOT_FOUND_KEY:1,FALLBACK_TO_TRANSLATE:2,CANNOT_FORMAT_NUMBER:3,FALLBACK_TO_NUMBER_FORMAT:4,CANNOT_FORMAT_DATE:5,FALLBACK_TO_DATE_FORMAT:6,EXPERIMENTAL_CUSTOM_MESSAGE_COMPILER:7},CORE_WARN_CODES_EXTEND_POINT=8,warnMessages={[CoreWarnCodes.NOT_FOUND_KEY]:`Not found '{key}' key in '{locale}' locale messages.`,[CoreWarnCodes.FALLBACK_TO_TRANSLATE]:`Fall back to translate '{key}' key with '{target}' locale.`,[CoreWarnCodes.CANNOT_FORMAT_NUMBER]:`Cannot format a number value due to not supported Intl.NumberFormat.`,[CoreWarnCodes.FALLBACK_TO_NUMBER_FORMAT]:`Fall back to number format '{key}' key with '{target}' locale.`,[CoreWarnCodes.CANNOT_FORMAT_DATE]:`Cannot format a date value due to not supported Intl.DateTimeFormat.`,[CoreWarnCodes.FALLBACK_TO_DATE_FORMAT]:`Fall back to datetime format '{key}' key with '{target}' locale.`,[CoreWarnCodes.EXPERIMENTAL_CUSTOM_MESSAGE_COMPILER]:`This project is using Custom Message Compiler, which is an experimental feature. It may receive breaking changes or be removed in the future.`},VERSION$1=`11.1.12`,NOT_REOSLVED=-1,DEFAULT_LOCALE=`en-US`,capitalize=str=>`${str.charAt(0).toLocaleUpperCase()}${str.substr(1)}`;function getDefaultLinkedModifiers(){return{upper:(val,type)=>type===`text`&&isString(val)?val.toUpperCase():type===`vnode`&&isObject(val)&&`__v_isVNode`in val?val.children.toUpperCase():val,lower:(val,type)=>type===`text`&&isString(val)?val.toLowerCase():type===`vnode`&&isObject(val)&&`__v_isVNode`in val?val.children.toLowerCase():val,capitalize:(val,type)=>type===`text`&&isString(val)?capitalize(val):type===`vnode`&&isObject(val)&&`__v_isVNode`in val?capitalize(val.children):val}}var _compiler;function registerMessageCompiler(compiler){_compiler=compiler}var _resolver,_fallbacker,_additionalMeta=null,setAdditionalMeta=meta=>{_additionalMeta=meta},getAdditionalMeta=()=>_additionalMeta,_fallbackContext=null,setFallbackContext=context=>{_fallbackContext=context},getFallbackContext=()=>_fallbackContext,_cid=0;function createCoreContext(options={}){let onWarn=isFunction(options.onWarn)?options.onWarn:warn,version$2=isString(options.version)?options.version:VERSION$1,locale=isString(options.locale)||isFunction(options.locale)?options.locale:DEFAULT_LOCALE,_locale=isFunction(locale)?DEFAULT_LOCALE:locale,fallbackLocale=isArray$1(options.fallbackLocale)||isPlainObject(options.fallbackLocale)||isString(options.fallbackLocale)||options.fallbackLocale===!1?options.fallbackLocale:_locale,messages=isPlainObject(options.messages)?options.messages:createResources(_locale),datetimeFormats=isPlainObject(options.datetimeFormats)?options.datetimeFormats:createResources(_locale),numberFormats=isPlainObject(options.numberFormats)?options.numberFormats:createResources(_locale),modifiers=assign$1(create(),options.modifiers,getDefaultLinkedModifiers()),pluralRules=options.pluralRules||create(),missing=isFunction(options.missing)?options.missing:null,missingWarn=isBoolean(options.missingWarn)||isRegExp(options.missingWarn)?options.missingWarn:!0,fallbackWarn=isBoolean(options.fallbackWarn)||isRegExp(options.fallbackWarn)?options.fallbackWarn:!0,fallbackFormat=!!options.fallbackFormat,unresolving=!!options.unresolving,postTranslation=isFunction(options.postTranslation)?options.postTranslation:null,processor=isPlainObject(options.processor)?options.processor:null,warnHtmlMessage=isBoolean(options.warnHtmlMessage)?options.warnHtmlMessage:!0,escapeParameter=!!options.escapeParameter,messageCompiler=isFunction(options.messageCompiler)?options.messageCompiler:_compiler,messageResolver=isFunction(options.messageResolver)?options.messageResolver:_resolver||resolveWithKeyValue,localeFallbacker=isFunction(options.localeFallbacker)?options.localeFallbacker:_fallbacker||fallbackWithSimple,fallbackContext=isObject(options.fallbackContext)?options.fallbackContext:void 0,internalOptions=options,__datetimeFormatters=isObject(internalOptions.__datetimeFormatters)?internalOptions.__datetimeFormatters:new Map,__numberFormatters=isObject(internalOptions.__numberFormatters)?internalOptions.__numberFormatters:new Map,__meta=isObject(internalOptions.__meta)?internalOptions.__meta:{};_cid++;let context={version:version$2,cid:_cid,locale,fallbackLocale,messages,modifiers,pluralRules,missing,missingWarn,fallbackWarn,fallbackFormat,unresolving,postTranslation,processor,warnHtmlMessage,escapeParameter,messageCompiler,messageResolver,localeFallbacker,fallbackContext,onWarn,__meta};return context.datetimeFormats=datetimeFormats,context.numberFormats=numberFormats,context.__datetimeFormatters=__datetimeFormatters,context.__numberFormatters=__numberFormatters,__INTLIFY_PROD_DEVTOOLS__&&initI18nDevTools(context,version$2,__meta),context}var createResources=locale=>({[locale]:create()});function handleMissing(context,key,locale,missingWarn,type){let{missing,onWarn}=context;if(missing!==null){let ret=missing(context,locale,key,type);return isString(ret)?ret:key}else return key}function updateFallbackLocale(ctx,locale,fallback){let context=ctx;context.__localeChainCache=new Map,ctx.localeFallbacker(ctx,fallback,locale)}function isAlmostSameLocale(locale,compareLocale){return locale===compareLocale?!1:locale.split(`-`)[0]===compareLocale.split(`-`)[0]}function isImplicitFallback(targetLocale,locales){let index=locales.indexOf(targetLocale);if(index===-1)return!1;for(let i=index+1;istr,DEFAULT_MESSAGE=ctx=>``,DEFAULT_MESSAGE_DATA_TYPE=`text`,DEFAULT_NORMALIZE=values=>values.length===0?``:join(values),DEFAULT_INTERPOLATE=toDisplayString$1;function pluralDefault(choice,choicesLength){return choice=Math.abs(choice),choicesLength===2?choice?choice>1?1:0:1:choice?Math.min(choice,2):0}function getPluralIndex(options){let index=isNumber(options.pluralIndex)?options.pluralIndex:-1;return options.named&&(isNumber(options.named.count)||isNumber(options.named.n))?isNumber(options.named.count)?options.named.count:isNumber(options.named.n)?options.named.n:index:index}function normalizeNamed(pluralIndex,props){props.count||=pluralIndex,props.n||=pluralIndex}function createMessageContext(options={}){let locale=options.locale,pluralIndex=getPluralIndex(options),pluralRule=isObject(options.pluralRules)&&isString(locale)&&isFunction(options.pluralRules[locale])?options.pluralRules[locale]:pluralDefault,orgPluralRule=isObject(options.pluralRules)&&isString(locale)&&isFunction(options.pluralRules[locale])?pluralDefault:void 0,plural=messages=>messages[pluralRule(pluralIndex,messages.length,orgPluralRule)],_list=options.list||[],list=index=>_list[index],_named=options.named||create();isNumber(options.pluralIndex)&&normalizeNamed(pluralIndex,_named);let named=key=>_named[key];function message(key,useLinked){return(isFunction(options.messages)?options.messages(key,!!useLinked):isObject(options.messages)?options.messages[key]:!1)||(options.parent?options.parent.message(key):DEFAULT_MESSAGE)}let _modifier=name=>options.modifiers?options.modifiers[name]:DEFAULT_MODIFIER,normalize=isPlainObject(options.processor)&&isFunction(options.processor.normalize)?options.processor.normalize:DEFAULT_NORMALIZE,interpolate=isPlainObject(options.processor)&&isFunction(options.processor.interpolate)?options.processor.interpolate:DEFAULT_INTERPOLATE,ctx={list,named,plural,linked:(key,...args)=>{let[arg1,arg2]=args,type$1=`text`,modifier=``;args.length===1?isObject(arg1)?(modifier=arg1.modifier||modifier,type$1=arg1.type||type$1):isString(arg1)&&(modifier=arg1||modifier):args.length===2&&(isString(arg1)&&(modifier=arg1||modifier),isString(arg2)&&(type$1=arg2||type$1));let ret=message(key,!0)(ctx),msg=type$1===`vnode`&&isArray$1(ret)&&modifier?ret[0]:ret;return modifier?_modifier(modifier)(msg,type$1):msg},message,type:isPlainObject(options.processor)&&isString(options.processor.type)?options.processor.type:DEFAULT_MESSAGE_DATA_TYPE,interpolate,normalize,values:assign$1(create(),_list,_named)};return ctx}var NOOP_MESSAGE_FUNCTION=()=>``,isMessageFunction=val=>isFunction(val);function translate$1(context,...args){let{fallbackFormat,postTranslation,unresolving,messageCompiler,fallbackLocale,messages}=context,[key,options]=parseTranslateArgs(...args),missingWarn=isBoolean(options.missingWarn)?options.missingWarn:context.missingWarn,fallbackWarn=isBoolean(options.fallbackWarn)?options.fallbackWarn:context.fallbackWarn,escapeParameter=isBoolean(options.escapeParameter)?options.escapeParameter:context.escapeParameter,resolvedMessage=!!options.resolvedMessage,defaultMsgOrKey=isString(options.default)||isBoolean(options.default)?isBoolean(options.default)?messageCompiler?key:()=>key:options.default:fallbackFormat?messageCompiler?key:()=>key:null,enableDefaultMsg=fallbackFormat||defaultMsgOrKey!=null&&(isString(defaultMsgOrKey)||isFunction(defaultMsgOrKey)),locale=getLocale(context,options);escapeParameter&&escapeParams(options);let[formatScope,targetLocale,message]=resolvedMessage?[key,locale,messages[locale]||create()]:resolveMessageFormat(context,key,locale,fallbackLocale,fallbackWarn,missingWarn),format$2=formatScope,cacheBaseKey=key;if(!resolvedMessage&&!(isString(format$2)||isMessageAST(format$2)||isMessageFunction(format$2))&&enableDefaultMsg&&(format$2=defaultMsgOrKey,cacheBaseKey=format$2),!resolvedMessage&&(!(isString(format$2)||isMessageAST(format$2)||isMessageFunction(format$2))||!isString(targetLocale)))return unresolving?-1:key;let occurred=!1,msg=isMessageFunction(format$2)?format$2:compileMessageFormat(context,key,targetLocale,format$2,cacheBaseKey,()=>{occurred=!0});if(occurred)return format$2;let messaged=evaluateMessage(context,msg,createMessageContext(getMessageContextOptions(context,targetLocale,message,options))),ret=postTranslation?postTranslation(messaged,key):messaged;if(escapeParameter&&isString(ret)&&(ret=sanitizeTranslatedHtml(ret)),__INTLIFY_PROD_DEVTOOLS__){let payloads={timestamp:Date.now(),key:isString(key)?key:isMessageFunction(format$2)?format$2.key:``,locale:targetLocale||(isMessageFunction(format$2)?format$2.locale:``),format:isString(format$2)?format$2:isMessageFunction(format$2)?format$2.source:``,message:ret};payloads.meta=assign$1({},context.__meta,getAdditionalMeta()||{}),translateDevTools(payloads)}return ret}function escapeParams(options){isArray$1(options.list)?options.list=options.list.map(item=>isString(item)?escapeHtml(item):item):isObject(options.named)&&Object.keys(options.named).forEach(key=>{isString(options.named[key])&&(options.named[key]=escapeHtml(options.named[key]))})}function resolveMessageFormat(context,key,locale,fallbackLocale,fallbackWarn,missingWarn){let{messages,onWarn,messageResolver:resolveValue,localeFallbacker}=context,locales=localeFallbacker(context,fallbackLocale,locale),message=create(),targetLocale,format$2=null,type=`translate`;for(let i=0;iformat$2);return msg$1.locale=targetLocale,msg$1.key=key,msg$1}let msg=messageCompiler(format$2,getCompileContext(context,targetLocale,cacheBaseKey,format$2,warnHtmlMessage,onError));return msg.locale=targetLocale,msg.key=key,msg.source=format$2,msg}function evaluateMessage(context,msg,msgCtx){return msg(msgCtx)}function parseTranslateArgs(...args){let[arg1,arg2,arg3]=args,options=create();if(!isString(arg1)&&!isNumber(arg1)&&!isMessageFunction(arg1)&&!isMessageAST(arg1))throw createCoreError(CoreErrorCodes.INVALID_ARGUMENT);let key=isNumber(arg1)?String(arg1):(isMessageFunction(arg1),arg1);return isNumber(arg2)?options.plural=arg2:isString(arg2)?options.default=arg2:isPlainObject(arg2)&&!isEmptyObject(arg2)?options.named=arg2:isArray$1(arg2)&&(options.list=arg2),isNumber(arg3)?options.plural=arg3:isString(arg3)?options.default=arg3:isPlainObject(arg3)&&assign$1(options,arg3),[key,options]}function getCompileContext(context,locale,key,source,warnHtmlMessage,onError){return{locale,key,warnHtmlMessage,onError:err=>{throw onError&&onError(err),err},onCacheKey:source$1=>generateFormatCacheKey(locale,key,source$1)}}function getMessageContextOptions(context,locale,message,options){let{modifiers,pluralRules,messageResolver:resolveValue,fallbackLocale,fallbackWarn,missingWarn,fallbackContext}=context,ctxOptions={locale,modifiers,pluralRules,messages:(key,useLinked)=>{let val=resolveValue(message,key);if(val==null&&(fallbackContext||useLinked)){let[,,message$1]=resolveMessageFormat(fallbackContext||context,key,locale,fallbackLocale,fallbackWarn,missingWarn);val=resolveValue(message$1,key)}if(isString(val)||isMessageAST(val)){let occurred=!1,msg=compileMessageFormat(context,key,locale,val,key,()=>{occurred=!0});return occurred?NOOP_MESSAGE_FUNCTION:msg}else if(isMessageFunction(val))return val;else return NOOP_MESSAGE_FUNCTION}};return context.processor&&(ctxOptions.processor=context.processor),options.list&&(ctxOptions.list=options.list),options.named&&(ctxOptions.named=options.named),isNumber(options.plural)&&(ctxOptions.pluralIndex=options.plural),ctxOptions}initFeatureFlags$1();var VERSION=`11.1.12`;function initFeatureFlags(){typeof __VUE_I18N_FULL_INSTALL__!=`boolean`&&(getGlobalThis().__VUE_I18N_FULL_INSTALL__=!0),typeof __VUE_I18N_LEGACY_API__!=`boolean`&&(getGlobalThis().__VUE_I18N_LEGACY_API__=!0),typeof __INTLIFY_DROP_MESSAGE_COMPILER__!=`boolean`&&(getGlobalThis().__INTLIFY_DROP_MESSAGE_COMPILER__=!1),typeof __INTLIFY_PROD_DEVTOOLS__!=`boolean`&&(getGlobalThis().__INTLIFY_PROD_DEVTOOLS__=!1)}var I18nErrorCodes={UNEXPECTED_RETURN_TYPE:24,INVALID_ARGUMENT:25,MUST_BE_CALL_SETUP_TOP:26,NOT_INSTALLED:27,REQUIRED_VALUE:28,INVALID_VALUE:29,CANNOT_SETUP_VUE_DEVTOOLS_PLUGIN:30,NOT_INSTALLED_WITH_PROVIDE:31,UNEXPECTED_ERROR:32,NOT_COMPATIBLE_LEGACY_VUE_I18N:33,NOT_AVAILABLE_COMPOSITION_IN_LEGACY:34};function createI18nError(code,...args){return createCompileError(code,null,void 0)}I18nErrorCodes.UNEXPECTED_RETURN_TYPE,I18nErrorCodes.INVALID_ARGUMENT,I18nErrorCodes.MUST_BE_CALL_SETUP_TOP,I18nErrorCodes.NOT_INSTALLED,I18nErrorCodes.UNEXPECTED_ERROR,I18nErrorCodes.REQUIRED_VALUE,I18nErrorCodes.INVALID_VALUE,I18nErrorCodes.CANNOT_SETUP_VUE_DEVTOOLS_PLUGIN,I18nErrorCodes.NOT_INSTALLED_WITH_PROVIDE,I18nErrorCodes.NOT_COMPATIBLE_LEGACY_VUE_I18N,I18nErrorCodes.NOT_AVAILABLE_COMPOSITION_IN_LEGACY;var SetPluralRulesSymbol=makeSymbol(`__setPluralRules`);makeSymbol(`__intlifyMeta`);var I18nWarnCodes={FALLBACK_TO_ROOT:8,NOT_FOUND_PARENT_SCOPE:9,IGNORE_OBJ_FLATTEN:10,DEPRECATE_LEGACY_MODE:11,DEPRECATE_TRANSLATE_CUSTOME_DIRECTIVE:12,DUPLICATE_USE_I18N_CALLING:13};I18nWarnCodes.FALLBACK_TO_ROOT,I18nWarnCodes.NOT_FOUND_PARENT_SCOPE,I18nWarnCodes.IGNORE_OBJ_FLATTEN,I18nWarnCodes.DEPRECATE_LEGACY_MODE,I18nWarnCodes.DEPRECATE_TRANSLATE_CUSTOME_DIRECTIVE,I18nWarnCodes.DUPLICATE_USE_I18N_CALLING;function handleFlatJson(obj){if(!isObject(obj)||isMessageAST(obj))return obj;for(let key in obj)if(hasOwn(obj,key))if(!key.includes(`.`))isObject(obj[key])&&handleFlatJson(obj[key]);else{let subKeys=key.split(`.`),lastIndex=subKeys.length-1,currentObj=obj,hasStringValue=!1;for(let i=0;i{if(`locale`in custom&&`resource`in custom){let{locale:locale$1,resource}=custom;locale$1?(ret[locale$1]=ret[locale$1]||create(),deepCopy(resource,ret[locale$1])):deepCopy(resource,ret)}else isString(custom)&&deepCopy(JSON.parse(custom),ret)}),messageResolver==null&&flatJson)for(let key in ret)hasOwn(ret,key)&&handleFlatJson(ret[key]);return ret}function getComponentOptions(instance$1){return instance$1.type}var DEVTOOLS_META=`__INTLIFY_META__`,composerID=0;function defineCoreMissingHandler(missing){return((ctx,locale,key,type)=>missing(locale,key,getCurrentInstance()||void 0,type))}var getMetaInfo=()=>{let instance$1=getCurrentInstance(),meta=null;return instance$1&&(meta=getComponentOptions(instance$1)[DEVTOOLS_META])?{[DEVTOOLS_META]:meta}:null};function createComposer(options={}){let{__root,__injectWithOption}=options,_isGlobal=__root===void 0,flatJson=options.flatJson,_ref=inBrowser?ref:shallowRef,_inheritLocale=isBoolean(options.inheritLocale)?options.inheritLocale:!0,_locale=_ref(__root&&_inheritLocale?__root.locale.value:isString(options.locale)?options.locale:DEFAULT_LOCALE),_fallbackLocale=_ref(__root&&_inheritLocale?__root.fallbackLocale.value:isString(options.fallbackLocale)||isArray$1(options.fallbackLocale)||isPlainObject(options.fallbackLocale)||options.fallbackLocale===!1?options.fallbackLocale:_locale.value),_messages=_ref(getLocaleMessages(_locale.value,options)),_missingWarn=__root?__root.missingWarn:isBoolean(options.missingWarn)||isRegExp(options.missingWarn)?options.missingWarn:!0,_fallbackWarn=__root?__root.fallbackWarn:isBoolean(options.fallbackWarn)||isRegExp(options.fallbackWarn)?options.fallbackWarn:!0,_fallbackRoot=__root?__root.fallbackRoot:isBoolean(options.fallbackRoot)?options.fallbackRoot:!0,_fallbackFormat=!!options.fallbackFormat,_missing=isFunction(options.missing)?options.missing:null,_runtimeMissing=isFunction(options.missing)?defineCoreMissingHandler(options.missing):null,_postTranslation=isFunction(options.postTranslation)?options.postTranslation:null,_warnHtmlMessage=__root?__root.warnHtmlMessage:isBoolean(options.warnHtmlMessage)?options.warnHtmlMessage:!0,_escapeParameter=!!options.escapeParameter,_modifiers=__root?__root.modifiers:isPlainObject(options.modifiers)?options.modifiers:{},_pluralRules=options.pluralRules||__root&&__root.pluralRules,_context;_context=(()=>{_isGlobal&&setFallbackContext(null);let ctx=createCoreContext({version:VERSION,locale:_locale.value,fallbackLocale:_fallbackLocale.value,messages:_messages.value,modifiers:_modifiers,pluralRules:_pluralRules,missing:_runtimeMissing===null?void 0:_runtimeMissing,missingWarn:_missingWarn,fallbackWarn:_fallbackWarn,fallbackFormat:_fallbackFormat,unresolving:!0,postTranslation:_postTranslation===null?void 0:_postTranslation,warnHtmlMessage:_warnHtmlMessage,escapeParameter:_escapeParameter,messageResolver:options.messageResolver,messageCompiler:options.messageCompiler,__meta:{framework:`vue`}});return _isGlobal&&setFallbackContext(ctx),ctx})(),updateFallbackLocale(_context,_locale.value,_fallbackLocale.value);function trackReactivityValues(){return[_locale.value,_fallbackLocale.value,_messages.value]}let locale=computed({get:()=>_locale.value,set:val=>{_context.locale=val,_locale.value=val}}),fallbackLocale=computed({get:()=>_fallbackLocale.value,set:val=>{_context.fallbackLocale=val,_fallbackLocale.value=val,updateFallbackLocale(_context,_locale.value,val)}}),messages=computed(()=>_messages.value);function getPostTranslationHandler(){return isFunction(_postTranslation)?_postTranslation:null}function setPostTranslationHandler(handler$1){_postTranslation=handler$1,_context.postTranslation=handler$1}function getMissingHandler(){return _missing}function setMissingHandler(handler$1){handler$1!==null&&(_runtimeMissing=defineCoreMissingHandler(handler$1)),_missing=handler$1,_context.missing=_runtimeMissing}let wrapWithDeps=(fn,argumentParser,warnType,fallbackSuccess,fallbackFail,successCondition)=>{trackReactivityValues();let ret;try{__INTLIFY_PROD_DEVTOOLS__,_isGlobal||(_context.fallbackContext=__root?getFallbackContext():void 0),ret=fn(_context)}finally{__INTLIFY_PROD_DEVTOOLS__,_isGlobal||(_context.fallbackContext=void 0)}if(isNumber(ret)&&ret===-1||warnType===`translate exists`){let[key,arg2]=argumentParser();return __root&&_fallbackRoot?fallbackSuccess(__root):fallbackFail(key)}else if(successCondition(ret))return ret;else throw createI18nError(I18nErrorCodes.UNEXPECTED_RETURN_TYPE)};function t(...args){return wrapWithDeps(context=>Reflect.apply(translate$1,null,[context,...args]),()=>parseTranslateArgs(...args),`translate`,root=>Reflect.apply(root.t,root,[...args]),key=>key,val=>isString(val))}function setPluralRules(rules){_pluralRules=rules,_context.pluralRules=_pluralRules}function getLocaleMessage(locale$1){return _messages.value[locale$1]||{}}function setLocaleMessage(locale$1,message){if(flatJson){let _message={[locale$1]:message};for(let key in _message)hasOwn(_message,key)&&handleFlatJson(_message[key]);message=_message[locale$1]}_messages.value[locale$1]=message,_context.messages=_messages.value}function mergeLocaleMessage(locale$1,message){_messages.value[locale$1]=_messages.value[locale$1]||{};let _message={[locale$1]:message};if(flatJson)for(let key in _message)hasOwn(_message,key)&&handleFlatJson(_message[key]);message=_message[locale$1],deepCopy(message,_messages.value[locale$1]),_context.messages=_messages.value}return composerID++,__root&&inBrowser&&(watch(__root.locale,val=>{_inheritLocale&&(_locale.value=val,_context.locale=val,updateFallbackLocale(_context,_locale.value,_fallbackLocale.value))}),watch(__root.fallbackLocale,val=>{_inheritLocale&&(_fallbackLocale.value=val,_context.fallbackLocale=val,updateFallbackLocale(_context,_locale.value,_fallbackLocale.value))})),{id:composerID,locale,fallbackLocale,get inheritLocale(){return _inheritLocale},set inheritLocale(val){_inheritLocale=val,val&&__root&&(_locale.value=__root.locale.value,_fallbackLocale.value=__root.fallbackLocale.value,updateFallbackLocale(_context,_locale.value,_fallbackLocale.value))},get availableLocales(){return Object.keys(_messages.value).sort()},messages,get modifiers(){return _modifiers},get pluralRules(){return _pluralRules||{}},get isGlobal(){return _isGlobal},get missingWarn(){return _missingWarn},set missingWarn(val){_missingWarn=val,_context.missingWarn=_missingWarn},get fallbackWarn(){return _fallbackWarn},set fallbackWarn(val){_fallbackWarn=val,_context.fallbackWarn=_fallbackWarn},get fallbackRoot(){return _fallbackRoot},set fallbackRoot(val){_fallbackRoot=val},get fallbackFormat(){return _fallbackFormat},set fallbackFormat(val){_fallbackFormat=val,_context.fallbackFormat=_fallbackFormat},get warnHtmlMessage(){return _warnHtmlMessage},set warnHtmlMessage(val){_warnHtmlMessage=val,_context.warnHtmlMessage=val},get escapeParameter(){return _escapeParameter},set escapeParameter(val){_escapeParameter=val,_context.escapeParameter=val},t,getLocaleMessage,setLocaleMessage,mergeLocaleMessage,getPostTranslationHandler,setPostTranslationHandler,getMissingHandler,setMissingHandler,[SetPluralRulesSymbol]:setPluralRules}}function createI18n(options={}){let __globalInjection=isBoolean(options.globalInjection)?options.globalInjection:!0,__instances=new Map,[globalScope,__global]=createGlobal(options),symbol=makeSymbol(``);function __getInstance(component){return __instances.get(component)||null}function __setInstance(component,instance$1){__instances.set(component,instance$1)}function __deleteInstance(component){__instances.delete(component)}let i18n={get mode(){return`composition`},async install(app$1,...options$1){if(app$1.__VUE_I18N_SYMBOL__=symbol,app$1.provide(app$1.__VUE_I18N_SYMBOL__,i18n),isPlainObject(options$1[0])){let opts=options$1[0];i18n.__composerExtend=opts.__composerExtend,i18n.__vueI18nExtend=opts.__vueI18nExtend}let globalReleaseHandler=null;__globalInjection&&(globalReleaseHandler=injectGlobalFields(app$1,i18n.global));let unmountApp=app$1.unmount;app$1.unmount=()=>{globalReleaseHandler&&globalReleaseHandler(),i18n.dispose(),unmountApp()}},get global(){return __global},dispose(){globalScope.stop()},__instances,__getInstance,__setInstance,__deleteInstance};return i18n}function createGlobal(options,legacyMode){let scope$1=effectScope(),obj=scope$1.run(()=>createComposer(options));if(obj==null)throw createI18nError(I18nErrorCodes.UNEXPECTED_ERROR);return[scope$1,obj]}var globalExportProps=[`locale`,`fallbackLocale`,`availableLocales`],globalExportMethods=[`t`];function injectGlobalFields(app$1,composer){let i18n=Object.create(null);return globalExportProps.forEach(prop=>{let desc=Object.getOwnPropertyDescriptor(composer,prop);if(!desc)throw createI18nError(I18nErrorCodes.UNEXPECTED_ERROR);let wrap=isRef(desc.value)?{get(){return desc.value.value},set(val){desc.value.value=val}}:{get(){return desc.get&&desc.get()}};Object.defineProperty(i18n,prop,wrap)}),app$1.config.globalProperties.$i18n=i18n,globalExportMethods.forEach(method=>{let desc=Object.getOwnPropertyDescriptor(composer,method);if(!desc||!desc.value)throw createI18nError(I18nErrorCodes.UNEXPECTED_ERROR);Object.defineProperty(app$1.config.globalProperties,`$${method}`,desc)}),()=>{delete app$1.config.globalProperties.$i18n,globalExportMethods.forEach(method=>{delete app$1.config.globalProperties[`$${method}`]})}}if(initFeatureFlags(),registerMessageCompiler(compile),__INTLIFY_PROD_DEVTOOLS__){let target=getGlobalThis();target.__INTLIFY__=!0,setDevToolsHook(target.__INTLIFY_DEVTOOLS_GLOBAL_HOOK__)}const emptyImage=`data:image/svg+xml,`;function getURL(path){return typeof path!=`string`||!path||path.includes(`://`)?path:(path.startsWith(`/`)&&(path=path.substring(1)),`/${path}`)}function getAssetURL(assetPath){let url=getURL(assetPath);return typeof url!=`string`||!url||url.startsWith(`/`)&&(url=`/ui/ui-vue/src/assets`+url),url}const getFile=(url,timeout=5)=>new Promise((resolve$1,reject)=>{try{let xhr=new XMLHttpRequest,tmr=timeout>0?setTimeout(()=>{xhr.abort(),reject(Error(`Timeout`))},timeout*1e3):null;xhr.open(`GET`,url,!0),xhr.onload=()=>{tmr&&clearTimeout(tmr),xhr.status===200?resolve$1(xhr.responseText):reject(Error(`Failed with code ${xhr.status}`))},xhr.send()}catch(err){reject(err)}}),ucaseFirst=str=>str[0].toUpperCase()+str.slice(1),defer=()=>{let noop$3=()=>{},resolve$1,reject,_notifyHandler=noop$3,promise=new Promise((res,rej)=>{[resolve$1,reject]=[res,rej]});return{promise:{then:(resolveHandler,rejectHandler=noop$3,notifyHandler=noop$3)=>(_notifyHandler=notifyHandler,promise.then(resolveHandler,rejectHandler))},resolve:resolve$1,reject,notify:val=>_notifyHandler(val)}},sleep=ms=>new Promise(resolve$1=>setTimeout(resolve$1,ms)),debounce=(func,wait,immediate)=>{let timeout;function call(...args){let context=this,later=()=>{timeout=null,immediate||func.apply(context,args)},callNow=immediate&&!timeout;timeout&&window.clearTimeout(timeout),timeout=window.setTimeout(later,wait),callNow&&func.apply(context,args)}return call.cancel=()=>timeout&&window.clearTimeout(timeout),call};var Settings=class{options=reactive({});values=reactive({});_previousValues={};_changedValues={};_watcher=null;_syncPending=!1;inited=!1;loaded=!1;_lua;constructor(eventBus$1=void 0,lua=void 0){eventBus$1&&lua&&this.init(eventBus$1,lua)}init(eventBus$1=void 0,lua=void 0){if(!(this.inited||this.loaded)){if(this.inited=!0,!eventBus$1||!lua){let bridge$4=useBridge();eventBus$1||=bridge$4.events,lua||=bridge$4.lua}eventBus$1.on(`SettingsChanged`,data=>{Object.assign(this.options,data.options),Object.assign(this.values,data.values),this._previousValues=this.clone(data.values),this._changedValues={},this._watcher||=watch(()=>this.values,()=>this._syncChanges(),{deep:!0,flush:`sync`}),this.loaded=!0}),this._syncChangesDebounced=debounce(this._syncChangesImmediate,100),this._lua=lua,this.update()}}async waitForData(){for(;!this.inited||!this.loaded;)await sleep(10)}async update(){if(this._lua)return await this._lua.settings.notifyUI()}clone(data){return JSON.parse(JSON.stringify(data))}getValue(field=null){if(this.loaded)return field&&!(field in this.values)?null:this.clone(field?this.values[field]:this.values)}get changesPending(){return this._syncChangesImmediate(),Object.keys(this._changedValues).length>0}get pendingChanges(){return this._syncChangesImmediate(),this.clone(this._changedValues)}_syncChanges(){this._syncPending=!0,this._syncChangesDebounced()}_syncChangesDebounced=()=>{};_syncChangesImmediate(){if(this._syncPending)for(let key in this._syncPending=!1,this.values)this._previousValues[key]===this.values[key]?key in this._changedValues&&delete this._changedValues[key]:this._changedValues[key]=this.values[key]}async apply(values=void 0){if(!this.loaded)return;let res;if(values)res=this.clone(values);else{if(!this.changesPending)return;res={...this._changedValues},this._changedValues={}}return Object.assign(this._previousValues,res),await this._lua.settings.setState(res)}},settings=new Settings;function useSettings(){return settings.init(),settings}async function useSettingsAsync(){return settings.init(),await settings.waitForData(),settings}var ANGULAR_TRANSLATE=[],_angularTranslateFunc,_i18n,i18nVariant=`petite`,defaultLocale=`en-US`,localeCheckId=`ui.common.okay`,checkLocale=()=>_i18n&&_i18n.global.t(localeCheckId)!==localeCheckId,translate=val=>val;const initTranslation=()=>{if(window.vueI18n?.__bng_i18n_variant!==i18nVariant){window.vueI18n&&console.warn(`Localisation library is already initialized, but its variant was not validated. Reloading...`);let creationArguments={locale:defaultLocale,fallbackLocale:defaultLocale,silentTranslationWarn:!0,fallbackWarn:!1,missingWarn:!1,warnHtmlMessage:!1};window.beamng&&!window.beamng.shipping&&(creationArguments.fallbackLocale=[defaultLocale,`not-shipping.internal`]),window.vueI18n=createI18n(creationArguments),window.vueI18n.__bng_i18n_variant=i18nVariant}return _i18n=window.vueI18n,{i18n:_i18n,plugin:translationPlugin}},loadLocale=async(locale,force=!1)=>{if(!(_i18n.global.availableLocales.includes(locale)&&!force))try{let url=getURL(`/locales/${locale}.json`),resp;try{resp=await getFile(url,5)}catch(err){if(err.message!==`Timeout`)throw err;console.warn(`Locale ${locale} load timed out, retrying with a bigger timeout...`),resp=await getFile(url,10)}_i18n.global.setLocaleMessage(locale,preprocessLocaleJSON(JSON.parse(resp)))}catch(err){console.error(`Failed to load ${locale} locale`,err)}};var setupUserLanguage=async()=>{let settings$1=await useSettingsAsync();watch(()=>settings$1.values.uiLanguage,async lang=>{lang&&lang!==defaultLocale&&await loadLocale(lang),_i18n.global.locale.value=_i18n.global.availableLocales.includes(lang)?lang:defaultLocale,lang!==defaultLocale&&!checkLocale()&&console.warn(`Locale ${lang} is not behaving properly`)},{immediate:!0})};const translationPlugin=()=>({install(app$1,options){return _i18n.global.locale.value=defaultLocale,loadLocale(defaultLocale,!0).then(async()=>{checkLocale()||(console.warn(`Failed to load default locale, retrying...`),await loadLocale(defaultLocale,!0),checkLocale()||console.error(`Failed to load default locale!`)),await setupUserLanguage()}),contextTranslatePlugin().install(app$1,options)}}),contextTranslatePlugin=()=>({install(app$1,options){translate=_wrapTranslate(app$1.config.globalProperties.$t||_i18n.global.t),app$1.config.globalProperties.$t=_i18n.global.t,app$1.config.globalProperties.$ctx_t=(val,translateContext=!0)=>contextTranslate(val,translateContext),app$1.config.globalProperties.$mctx_t=multiContextTranslate,app$1.config.globalProperties.$tt=translate}});var contextTranslate=(val,translateContext=!1)=>{let type=typeof val;if(type===`undefined`||val===null)return``;if(type===`object`)if(val.txt&&val.context){let context=val.context;if(translateContext)for(let key in context={...context},context)context[key]=contextTranslate(context[key],!0);return getTranslation(val.txt,context)}else val=val.txt||``;return getTranslation(``+val)},multiContextTranslate=val=>{if(val.txt)return contextTranslate(val);let description=``;for(let i of val)description+=contextTranslate(i);return description},getAngularTranslationFunc=()=>_angularTranslateFunc||(window.angular$translate&&(_angularTranslateFunc=window.angular$translate.instant.bind(window.angular$translate)),_angularTranslateFunc||translate),getTranslation=(...vals)=>(ANGULAR_TRANSLATE.includes(vals[0])?getAngularTranslationFunc():translate)(...vals);const $translate={instant:val=>val===void 0?``:translate(val),contextTranslate,multiContextTranslate};var rgxAngular=/{{.+}}/,rgxAngularTranslation=/([^ ]?){{ *(?::: *)?'([^ |}]+)' *\| *translate *}}([^\w]?)/gi;function translateAngularToVue(text){let vueText=text.replace(rgxAngularTranslation,(_,q1,s,q2)=>(q1?`${q1} `:``)+`@:${s}`+(q2?` ${q2}`:``));return vueText=vueText.replace(/{{ *([a-z\d_.]+) *}}/gi,`{$1}`),vueText===text||rgxAngular.test(vueText)?null:vueText}const preprocessLocaleJSON=obj=>{let messages={};for(let key in obj){if(ANGULAR_TRANSLATE.includes(key))continue;let text=obj[key];if(rgxAngular.test(text)){let vueText=translateAngularToVue(text);vueText?messages[key]=vueText:ANGULAR_TRANSLATE.includes(key)||ANGULAR_TRANSLATE.push(key)}else messages[key]=text}return messages};var rgxLinkedTranslation=/@:([a-zA-Z0-9_][a-zA-Z0-9_.-]+[a-zA-Z0-9_])/g,linkedNamespace=`__linked_custom`;function _linkedTranslation(msg){if(!msg.includes(`@:`)||!rgxLinkedTranslation.test(msg))return msg;let locale=_i18n.global.locale.value,messages=_i18n.global.messages.value[locale];msg=msg.replace(rgxLinkedTranslation,(_,id)=>`@:`+id);let uniqueId$1=``,match;for(rgxLinkedTranslation.lastIndex=0;(match=rgxLinkedTranslation.exec(msg))!==null;)uniqueId$1+=match[1].replace(/\./g,`_`)+`__`;let fullId,messageId,counter$1=0;for(;counter$1<100;){messageId=uniqueId$1+ ++counter$1,fullId=linkedNamespace+`.`+messageId;let existingMessage=messages[fullId];if(!existingMessage){_i18n.global.mergeLocaleMessage(locale,{[fullId]:msg});break}if(existingMessage===msg)break}return fullId}function _wrapTranslate(f){function translate$2(...args){let key=args[0];return key?typeof key!=`string`||(key=_linkedTranslation(key),key.includes(` `))?key:f.apply(this,[key,...args.slice(1)]):``}return Object.defineProperty(translate$2,`name`,{value:f.name}),translate$2}const UI_NAV_ACTION_GROUP=`UINavActions`,GAME_UI_NAVIGATION_EVENT=`UINavigation`,GAME_UI_NAV_MAP_ENABLED_EVENT=`MenuActionMapEnabled`,DOM_UI_NAVIGATION_EVENT=`ui_nav`,ACTIONS_BY_UI_EVENT={focus_u:`menu_item_up`,focus_r:`menu_item_right`,focus_d:`menu_item_down`,focus_l:`menu_item_left`,menu:`toggleMenues`,back:`menu_item_back`,details:`cui_details`,advanced:`cui_advanced`,camera:`cui_camera`,logs:`cui_logs`,tab_l:`menu_tab_left`,tab_r:`menu_tab_right`,modifier:`cui_modifier`,action_4:`cui_action_4`,focus_ud:`menu_item_focus_ud`,focus_lr:`menu_item_focus_lr`,rotate_h_cam:`menu_item_radial_right_x`,rotate_v_cam:`menu_item_radial_right_y`,ok:`menu_item_select`,cancel:`cui_cancel`,action_2:`cui_action_2`,action_3:`cui_action_3`,context:`cui_context`,gameplay_interact:`cui_gameplay_interact`},UI_EVENTS_BY_ACTION=Object.assign({},...Object.entries(ACTIONS_BY_UI_EVENT).map(([k,v])=>({[v]:k}))),UI_EVENTS={focus_u:`focus_u`,focus_r:`focus_r`,focus_d:`focus_d`,focus_l:`focus_l`,pause:`pause`,menu:`menu`,back:`back`,details:`details`,advanced:`advanced`,camera:`camera`,logs:`logs`,tab_l:`tab_l`,tab_r:`tab_r`,modifier:`modifier`,zoom_out:`zoom_out`,zoom_in:`zoom_in`,subtab_l:`subtab_l`,subtab_r:`subtab_r`,center_cam:`center_cam`,action_4:`action_4`,move_ud:`move_ud`,move_lr:`move_lr`,focus_ud:`focus_ud`,focus_lr:`focus_lr`,rotate_h_cam:`rotate_h_cam`,rotate_v_cam:`rotate_v_cam`,ok:`ok`,cancel:`cancel`,action_2:`action_2`,action_3:`action_3`,context:`context`,gameplay_interact:`gameplay_interact`},UI_EVENT_GROUPS={focusMove:[UI_EVENTS.focus_u,UI_EVENTS.focus_d,UI_EVENTS.focus_l,UI_EVENTS.focus_r],focusMoveScalar:[UI_EVENTS.focus_ud,UI_EVENTS.focus_lr],moveScalar:[UI_EVENTS.move_ud,UI_EVENTS.move_lr],navigation:[UI_EVENTS.focus_u,UI_EVENTS.focus_d,UI_EVENTS.focus_l,UI_EVENTS.focus_r,UI_EVENTS.focus_ud,UI_EVENTS.focus_lr,UI_EVENTS.move_ud,UI_EVENTS.move_lr],allEvents:Object.keys(ACTIONS_BY_UI_EVENT)},NAV_ACTIONS=[`focus_u`,`focus_d`,`focus_l`,`focus_r`],VALUE_BASED_EVENTS=[`zoom_out`,`zoom_in`,`subtab_l`,`subtab_r`,`move_ud`,`move_lr`,`focus_ud`,`focus_lr`,`rotate_h_cam`,`rotate_v_cam`],UI_SCOPE_ATTR$2=`bng-ui-scope`,UI_EVENT_ATTR=`ui-nav-event`;var UINavEventProcessor=class{constructor(){this.isModified=!1}processEvent(name,value=void 0,extras=[],context={}){return!this.isValidGameContext()||context.isEventBlocked&&context.isEventBlocked(name)?null:(this.handleModifierState(name,value),this.shouldHandleWithAngular(name,value)?(this.handleAngularIntegration(),null):this.createEventData(name,value,extras))}isValidGameContext(){return window.beamng?.ingame}handleModifierState(name,value){name===`modifier`&&(this.isModified=value===1)}shouldHandleWithAngular(name,value){return window.globalAngularRootScope&&window.bngIntroShown&&(name===`menu`||name===`back`)&&value===1}handleAngularIntegration(){window.globalAngularRootScope.$broadcast(`MenuToggle`)}createEventData(name,value,extras){let activeElement=document.activeElement,targetScope=null;if(activeElement&&activeElement!==document.body){let scopeElement=activeElement.closest(`[${UI_SCOPE_ATTR$2}]`);scopeElement&&(targetScope=scopeElement.getAttribute(UI_SCOPE_ATTR$2))}return{name,value,modified:name!==`modifier`&&this.isModified,extras,boundAction:ACTIONS_BY_UI_EVENT[name],sendToCrossfire:!0,targetScope}}getEventBroadcastElement(activeScope){let activeElement=document.activeElement;if(activeElement&&activeElement!==document.body)return activeElement;if(activeScope){let scopeElement=document.querySelector(`[${UI_SCOPE_ATTR$2}="${activeScope}"]`);if(scopeElement)return scopeElement}return document.body}},UINavActionHandlers=class{constructor(eventBus$1=null){this._useCrossfire=!0,this.eventBus=eventBus$1}setUseCrossfire(enabled){this._useCrossfire=enabled}get useCrossfire(){return this._useCrossfire}setEventBus(eventBus$1){this.eventBus=eventBus$1}handleGlobalEvent=event=>{let eventData=event.detail;eventData.value===1&&(this.handleMenuActions(eventData)||this.handleNavigationActions(eventData)||this.handleGameActions(eventData))||(this.useCrossfire&&eventData.sendToCrossfire&&handleUINavEvent(event),event.defaultPrevented||(this.handleTabNavigation(eventData),this.handleCameraRotation(eventData),this.handleContextActions(eventData)))};handleMenuActions=eventData=>{if(eventData.name===`menu`||eventData.name===`back`){let globalAngularRootScope=window.globalAngularRootScope;return globalAngularRootScope?(globalAngularRootScope.$broadcast(`MenuToggle`),!1):!0}return!1};handleNavigationActions(eventData){if(NAV_ACTIONS.includes(eventData.name)){Lua_default.extensions.hook(`onMenuItemNavigation`);return}return!1}handleGameActions(eventData){switch(eventData.name){case`pause`:return Lua_default.simTimeAuthority.togglePause(),!0;case`center_cam`:return runRaw(`if core_camera then core_camera.resetCamera(${eventData.extras.player}) end`,!1),!0;default:return!1}}handleTabNavigation(eventData){if(eventData.value===1)switch(eventData.name){case`tab_l`:this.eventBus.emit(`ui_topBar_selectPrevious`);break;case`tab_r`:this.eventBus.emit(`ui_topBar_selectNext`);break}}handleCameraRotation(eventData){if(eventData.name===`rotate_h_cam`||eventData.name===`rotate_v_cam`){let camDir=eventData.name===`rotate_v_cam`?`pitch`:`yaw`,[filterType]=eventData.extras||[0];runRaw(`if core_camera then core_camera.rotate_${camDir}(${eventData.value}, ${filterType}) end`,!1)}}handleContextActions(eventData){[`context`,`details`,`camera`].includes(eventData.name)&&eventData.value===1&&this.isBigMapContext()&&runRaw(`if freeroam_bigMapMode then freeroam_bigMapMode.toggleBigMap() end`,!1)}isBigMapContext(){return[`#/bigmap`,`#/menu.bigmap`,`#/play`,`#/menu/bigmap`].includes(window.location.hash)}},UINavService=class{constructor(eventBus$1){this._eventBus=eventBus$1,this._eventsActive=!1,this._globalEventsHooked=!1,this._activeScope=void 0,this._blockedEvents=[],this.eventProcessor=new UINavEventProcessor,this.actionHandlers=new UINavActionHandlers(eventBus$1),this.useCrossfire=!0}initialize(){this.attachEventListeners(),this.hookGlobalEvents()}handleGameEvent=(name,value,...extras)=>{let context={activeScope:this.activeScope,isEventBlocked:eventName=>this.isEventBlocked(eventName)},eventData=this.eventProcessor.processEvent(name,value,extras,context);eventData&&this.dispatchDOMEvent(eventData)};blockEvents(...events$3){let eventsToAdd=events$3.flat().filter(event=>!this._blockedEvents.includes(event));this._blockedEvents.push(...eventsToAdd)}unblockEvents(...events$3){let eventsToRemove=events$3.flat();this._blockedEvents=this._blockedEvents.filter(event=>!eventsToRemove.includes(event))}setBlockedEvents(events$3=[]){this._blockedEvents=[...events$3]}clearBlockedEvents(){this._blockedEvents=[]}isEventBlocked(eventName){return this._blockedEvents.includes(eventName)}getBlockedEvents(){return[...this._blockedEvents]}handleEnabledChange=state=>{this.eventsActive=state};dispatchDOMEvent=eventData=>{let event=new CustomEvent(DOM_UI_NAVIGATION_EVENT,{detail:eventData,cancelable:!0,bubbles:!0});this.eventProcessor.getEventBroadcastElement(this.activeScope).dispatchEvent(event)};fireEvent(uiEvent,value){this._eventBus&&(value instanceof PointerEvent?(this._eventBus.emit(GAME_UI_NAVIGATION_EVENT,uiEvent,1),this._eventBus.emit(GAME_UI_NAVIGATION_EVENT,uiEvent,0)):this._eventBus.emit(GAME_UI_NAVIGATION_EVENT,uiEvent,typeof value==`number`?value:value?1:0))}setActiveScope(scopeId){this._activeScope=scopeId}get activeScope(){return this._activeScope}activate(state=!0){this.attachEventListeners(state),this.eventsActive=state}hookGlobalEvents(state=!0){let listenerAction=document.body[state?`addEventListener`:`removeEventListener`];listenerAction(DOM_UI_NAVIGATION_EVENT,this.actionHandlers.handleGlobalEvent),this.globalEventsHooked=state}attachEventListeners(state=!0){this._eventBus&&(this._eventBus.off(GAME_UI_NAVIGATION_EVENT),this._eventBus.off(GAME_UI_NAV_MAP_ENABLED_EVENT),state&&(this._eventBus.on(GAME_UI_NAVIGATION_EVENT,this.handleGameEvent),this._eventBus.on(GAME_UI_NAV_MAP_ENABLED_EVENT,this.handleEnabledChange)))}setFilteredEvents(...events$3){this.clearFilteredEvents();let actionsToFilter=[...new Set(events$3.flat(1/0))].map(event=>ACTIONS_BY_UI_EVENT[event]);Lua_default.extensions.core_input_actionFilter.setGroup(UI_NAV_ACTION_GROUP,actionsToFilter),Lua_default.extensions.core_input_actionFilter.addAction(0,UI_NAV_ACTION_GROUP,!0)}setFilteredEventsAllExcept(...events$3){let eventsToNotFilter=[...new Set(events$3.flat(1/0))],eventsToFilter=Object.keys(ACTIONS_BY_UI_EVENT).filter(ev=>!eventsToNotFilter.includes(ev));this.setFilteredEvents(eventsToFilter)}clearFilteredEvents(){Lua_default.extensions.core_input_actionFilter.addAction(0,UI_NAV_ACTION_GROUP,!1),Lua_default.extensions.core_input_actionFilter.setGroup(UI_NAV_ACTION_GROUP,[])}set eventsActive(value){this._eventsActive=value}get eventsActive(){return this._eventsActive}set globalEventsHooked(value){this._globalEventsHooked=value}get globalEventsHooked(){return this._globalEventsHooked}get useCrossfire(){return this.actionHandlers.useCrossfire}set useCrossfire(value){this.actionHandlers.setUseCrossfire(value)}get eventBus(){return this._eventBus}},instance=null;const setUINavServiceInstance=serviceInstance=>{instance=serviceInstance},getUINavServiceInstance=()=>{if(!instance)throw Error(`UINavService not initialized.`);return instance},SCOPED_NAV_ATTR=`bng-scoped-nav`,SCOPED_NAV_PROPERTY_NAME=`_bngScopedNav`,UI_SCOPE_ATTR$1=`bng-ui-scope`,BNG_ON_UI_NAV_ATTR$1=`__BngOnUiNav`,ATTR_NAME$1=`bng-scoped-nav`,PASSTHROUGH_EXCLUDED_EVENTS=[UI_EVENTS.ok,UI_EVENTS.back,UI_EVENT_GROUPS.focusMove,UI_EVENT_GROUPS.focusMoveScalar],SCOPED_NAV_STATES={active:`full`,partial:`partial`,suspended:`suspended`,inactive:`inactive`},SCOPED_NAV_EVENTS={activate:`scopednav:activate`,deactivate:`scopednav:deactivate`,suspend:`scopednav:suspend`,resume:`scopednav:resume`},SCOPED_NAV_TYPES={normal:`normal`,container:`container`,nonav:`nonav`,popover:`popover`};var ScopeRegistry=class{constructor(){this.scopeRegistries=new WeakMap,this.depthCache=new WeakMap,this.cleanupTimers=new Map}clearDepthCache(scopeElement){this.depthCache.delete(scopeElement)}getCachedDepth(element,scopeElement){let scopeDepthCache=this.depthCache.get(scopeElement);if(scopeDepthCache||(scopeDepthCache=new Map,this.depthCache.set(scopeElement,scopeDepthCache)),!scopeDepthCache.has(element)){let depth=this._getElementDepth(element,scopeElement);scopeDepthCache.set(element,depth)}return scopeDepthCache.get(element)}register(scopeElement,handlerDescriptor){let scopeRegistry=this.scopeRegistries.get(scopeElement);scopeRegistry||(scopeRegistry={handlers:[],scopeHandler:null,initialized:!1},this.scopeRegistries.set(scopeElement,scopeRegistry));let existingIndex=scopeRegistry.handlers.findIndex(h$1=>h$1.element===handlerDescriptor.element&&this.descriptorsMatch(h$1.eventDescriptor,handlerDescriptor.eventDescriptor));return existingIndex===-1?scopeRegistry.handlers.push(handlerDescriptor):scopeRegistry.handlers[existingIndex]=handlerDescriptor,scopeRegistry.initialized||this.initializeScopeHandler(scopeElement,scopeRegistry),this.clearDepthCache(scopeElement),handlerDescriptor.handler}descriptorsMatch(desc1,desc2){return desc1.name===desc2.name&&desc1.modified===desc2.modified&&desc1.focusRequired===desc2.focusRequired}unregister(element,handlerController){let scopeElement=element.closest(`[${UI_SCOPE_ATTR$2}]`);if(!scopeElement)return;let scopeRegistry=this.scopeRegistries.get(scopeElement);if(!scopeRegistry)return;let handlerIndex=scopeRegistry.handlers.findIndex(h$1=>h$1.element===element&&h$1.handler===handlerController);handlerIndex!==-1&&(scopeRegistry.handlers.splice(handlerIndex,1),this.clearDepthCache(scopeElement)),this.scheduleCleanup(scopeElement,scopeRegistry)}scheduleCleanup(scopeElement,scopeRegistry){this.cleanupTimers.has(scopeElement)&&clearTimeout(this.cleanupTimers.get(scopeElement));let timerId=setTimeout(()=>{this.performCleanup(scopeElement,scopeRegistry),this.cleanupTimers.delete(scopeElement)},100);this.cleanupTimers.set(scopeElement,timerId)}performCleanup(scopeElement,scopeRegistry){scopeRegistry.handlers.length===0&&(scopeElement.removeEventListener(DOM_UI_NAVIGATION_EVENT,scopeRegistry.scopeHandler),this.scopeRegistries.delete(scopeElement),this.clearDepthCache(scopeElement))}destroy(){this.cleanupTimers.forEach(timer=>clearTimeout(timer)),this.cleanupTimers.clear(),this.depthCache=new WeakMap}initializeScopeHandler(scopeElement,scopeRegistry){let scopeHandler=event=>{let scopeId=scopeElement.getAttribute(UI_SCOPE_ATTR$2),uiNavService=getUINavServiceInstance(),targetScope=event.detail?.targetScope||uiNavService.activeScope;if(targetScope&&targetScope!==scopeId&&!this._isTargetScopeNested(targetScope,scopeElement)){console.warn(`UINav: Event target scope is not the intended scope. Ignoring event for this scope(${scopeId})`,{targetScope,scopeId});return}if(scopeElement._bngScopedNav&&scopeElement._bngScopedNav.canIgnoreEvent&&scopeElement._bngScopedNav.canIgnoreEvent(event)){event.stopPropagation();return}let isTargetActiveScope=targetScope===scopeId&&scopeId===uiNavService.activeScope,canPassthrough=isTargetActiveScope&&this._allowsPassthrough(scopeElement,event.detail),monitoredEvents=[...MONITORED_UI_NAV_EVENTS,UI_EVENTS.back];if(!(!isTargetActiveScope&&!canPassthrough&&!monitoredEvents.includes(event.detail.name))){if(!isTargetActiveScope&&!canPassthrough&&monitoredEvents.includes(event.detail.name)){this._executeScopedNavHandler(scopeElement,event,scopeRegistry.handlers)||event.stopPropagation();return}(!this._executeScopedBubbling(scopeElement,event,scopeRegistry.handlers)||!this._checkScopeBubbling(scopeElement,event))&&event.stopPropagation()}};scopeElement.addEventListener(DOM_UI_NAVIGATION_EVENT,scopeHandler),scopeRegistry.scopeHandler=scopeHandler,scopeRegistry.initialized=!0}_isTargetScopeNested(targetScopeId,currentScopeElement){let targetScopeElement=document.querySelector(`[${UI_SCOPE_ATTR$2}="${targetScopeId}"]`);return targetScopeElement?currentScopeElement.contains(targetScopeElement)&&targetScopeElement!==currentScopeElement:!1}_executeScopedNavHandler(scopeElement,event,handlers$1){let matchingHandlers=handlers$1.filter(h$1=>!h$1.disabled&&this._eventMatchesDescriptor(event.detail,h$1.eventDescriptor)&&h$1.element===scopeElement);if(matchingHandlers.length===0)return!0;let results=[];for(let handler$1 of matchingHandlers)try{let result=handler$1.handler(event);results.push(result)}catch(error){console.error(`Error in UINav scope handler:`,error,{element:handler$1.element,event:event.detail.name}),results.push(!1)}return results.some(result=>result===!0)}_executeScopedBubbling(scopeElement,event,handlers$1){let eventData=event.detail,matchingHandlers=handlers$1&&handlers$1.length>0?handlers$1.filter(h$1=>!h$1.disabled&&this._eventMatchesDescriptor(eventData,h$1.eventDescriptor)):[];if(matchingHandlers.length===0)return!0;let activeElement=document.activeElement,startElement=event.target;startElement=activeElement&&scopeElement.contains(activeElement)&&matchingHandlers.some(h$1=>h$1.element===activeElement)?activeElement:this._findDeepestHandlerElement(scopeElement,matchingHandlers);let bubblingPath=this._buildBubblingPath(startElement,scopeElement,matchingHandlers);return bubblingPath.length===0?(console.warn(`UINav: No bubbling path found.`,{scopeElement,event,handlers:handlers$1}),!0):this._executeHandlersAlongPath(bubblingPath,event)}_findDeepestHandlerElement(scopeElement,handlers$1){return[...new Set(handlers$1.map(h$1=>h$1.element))].filter(el=>this.getCachedDepth(el,scopeElement)<0?!1:!this._isElementInNestedScope(el,scopeElement)).sort((a$1,b)=>{let depthA=this.getCachedDepth(a$1,scopeElement);return this.getCachedDepth(b,scopeElement)-depthA})[0]||null}_isElementInNestedScope(element,currentScopeElement){let current=element;for(;current&¤t!==currentScopeElement;){if(current.hasAttribute(`bng-ui-scope`)&¤t!==currentScopeElement)return!0;current=current.parentElement}return!1}_buildBubblingPath(startElement,scopeElement,handlers$1){if(!scopeElement.contains(startElement))return console.warn(`UINav: Start element is outside scope boundary`,startElement,scopeElement),[];let path=[],current=startElement;for(;current&&scopeElement.contains(current);){let elementHandlers=handlers$1.filter(h$1=>h$1.element===current);if(elementHandlers.length>0&&path.push({element:current,handlers:elementHandlers}),current===scopeElement)break;current=current.parentElement}return path}_executeHandlersAlongPath(bubblingPath,event){for(let pathItem of bubblingPath){let results=[];for(let handlerDescriptor of pathItem.handlers)try{let result=handlerDescriptor.handler(event);results.push(result)}catch(error){console.error(`Error in UINav scope handler:`,error,{element:pathItem.element,event:event.detail.name}),results.push(!1)}if(!results.some(result=>result===!0))return!1}return!0}_checkScopeBubbling(scopeElement,event){let scopedNavProps=scopeElement._bngScopedNav;return scopedNavProps?scopedNavProps.shouldBubbleEvent&&typeof scopedNavProps.shouldBubbleEvent==`function`?scopedNavProps.shouldBubbleEvent(event):!1:!0}_getElementDepth(element,parent){let depth=0,current=element;for(;current&¤t!==parent;)depth++,current=current.parentElement;return current===parent?depth:-1}_allowsPassthrough(scopeElement,eventData){let domScopedNavProps=scopeElement.hasAttribute(`bng-scoped-nav`)?scopeElement[SCOPED_NAV_PROPERTY_NAME]:{};return domScopedNavProps.passthroughActive&&domScopedNavProps.passthroughEnabled&&domScopedNavProps.passthroughEvents.includes(eventData.name)}_eventMatchesDescriptor(eventData,descriptor){for(let[item,value]of Object.entries(descriptor))if(value!==void 0)if(item===`focusRequired`){if(value&&!value.contains(document.activeElement))return!1}else{if(!(item in eventData))return!1;if(typeof value==`function`){if(!value(eventData[item]))return!1}else if(eventData[item]!=value)return!1}return!0}};const isOnOffEvent=eventName=>!VALUE_BASED_EVENTS.includes(eventName),checkOn=value=>value,normalizeEventDescriptor=eventDescriptor=>({string:{name:eventDescriptor,value:isOnOffEvent(eventDescriptor)?checkOn:void 0,modified:!1,extras:void 0},object:{...eventDescriptor,value:`value`in eventDescriptor?eventDescriptor.value:isOnOffEvent(eventDescriptor.name)?checkOn:void 0}})[typeof eventDescriptor]||!1,eventMatchesDescriptor=(eventData,descriptor)=>{for(let[item,value]of Object.entries(descriptor))if(value!==void 0)if(item===`focusRequired`){if(value&&!value.contains(document.activeElement))return!1}else{if(!(item in eventData))return!1;if(typeof value==`function`){if(!value(eventData[item]))return!1}else if(eventData[item]!=value)return!1}return!0},getDescriptorEventNameText=descriptor=>descriptor.name?typeof descriptor.name==`function`?descriptor.name.name:descriptor.name:`ALL`;var HandlerFactory=class{static createHandler(eventDescriptor,userHandler){let descriptor=normalizeEventDescriptor(eventDescriptor);if(!descriptor)throw Error(`Invalid event descriptor when trying to create a UINav handler. Expecting a String or an Object.`);let handlerFuncName=userHandler?.name||`uiNav_${getDescriptorEventNameText(descriptor)}_handler`,disabled=!1;function wrapper(event){let eventData=event?.detail||{};return disabled||!eventMatchesDescriptor(eventData,descriptor)?!0:userHandler(event)}return Object.defineProperty(wrapper,`name`,{value:handlerFuncName}),Object.defineProperty(wrapper,`disabled`,{configurable:!1,get:()=>disabled,set:state=>{disabled=state}}),wrapper}static normalizeEventDescriptor(eventDescriptor){return{string:{name:eventDescriptor,value:isOnOffEvent(eventDescriptor)?checkOn:void 0,modified:!1,extras:void 0},object:{...eventDescriptor,value:`value`in eventDescriptor?eventDescriptor.value:isOnOffEvent(eventDescriptor.name)?checkOn:void 0}}[typeof eventDescriptor]||!1}},UINavHandlers=class{constructor(){this.scopeRegistry=new ScopeRegistry}add(domElement,uiNavHandlerOrDescriptor,handler$1=void 0){let scopeElement=domElement.closest(`[${UI_SCOPE_ATTR$2}]`);return scopeElement?this.addWithScope(domElement,uiNavHandlerOrDescriptor,handler$1,scopeElement):this.addIndividual(domElement,uiNavHandlerOrDescriptor,handler$1)}remove(domElement,uiNavHandler){domElement.closest(`[bng-ui-scope]`)?this.scopeRegistry.unregister(domElement,uiNavHandler):this.removeIndividual(domElement,uiNavHandler)}addWithScope(domElement,uiNavHandlerOrDescriptor,handler$1,scopeElement){let targetElement=domElement;if(!scopeElement.contains(targetElement))return console.error(`UINav: Attempting to register handler for element outside scope`,{targetElement,scopeElement,scopeId:scopeElement.getAttribute(UI_SCOPE_ATTR$2)}),this.addIndividual(domElement,uiNavHandlerOrDescriptor,handler$1);let wrapperHandler=handler$1?HandlerFactory.createHandler(uiNavHandlerOrDescriptor,handler$1):uiNavHandlerOrDescriptor,handlerDescriptor={element:domElement,eventDescriptor:HandlerFactory.normalizeEventDescriptor(uiNavHandlerOrDescriptor),handler:wrapperHandler,disabled:!1};return this.scopeRegistry.register(scopeElement,handlerDescriptor)}addIndividual(domElement,uiNavHandlerOrDescriptor,handler$1){let uiNavHandler=handler$1?HandlerFactory.createHandler(uiNavHandlerOrDescriptor,handler$1):uiNavHandlerOrDescriptor;return domElement.addEventListener(DOM_UI_NAVIGATION_EVENT,uiNavHandler),uiNavHandler}removeIndividual(domElement,uiNavHandler){domElement.removeEventListener(DOM_UI_NAVIGATION_EVENT,uiNavHandler)}},handlers_default=new UINavHandlers;function usePopupUINavScopeName(baseName,props){let attrs=useAttrs(),scopeName=baseName+`__`+attrs.__id;return useUINavScope(scopeName),watch(()=>props.popupActive,()=>props.popupActive&&useUINavScope(scopeName)),scopeName}function useUINavScope(scope$1=void 0,restoreScopeOnUnmount=!0){let currentScope=ref(scope$1),oldScope,scopeChanged=!1,setScope=newScope=>{scopeChanged=!0,currentScope.value=newScope,getUINavServiceInstance().setActiveScope(newScope)},restoreOldScope=()=>{getUINavServiceInstance().setActiveScope(oldScope)};return onMounted(()=>{oldScope=getUINavServiceInstance().activeScope,currentScope.value?setScope(currentScope.value):currentScope.value=oldScope}),onUnmounted(()=>{scopeChanged&&restoreScopeOnUnmount&&restoreOldScope()}),{current:computed(()=>currentScope.value),set:setScope,get oldScope(){return oldScope}}}function watchUINavEventChange(domElementRef,handler$1){return watch(()=>{if(!domElementRef.value)return{};let eventName=domElementRef.value.getAttribute(UI_EVENT_ATTR);return{eventName,action:ACTIONS_BY_UI_EVENT[eventName]}},handler$1)}const eventFirer=uiEvent=>value=>getUINavServiceInstance().fireEvent(uiEvent,value);var counter=0;const uniqueNum=()=>++counter%1e5+Math.random(),uniqueId=(name=``,separator=`.`)=>{let str=`${name?name+separator:``}${uniqueNum().toString(16)}`;return separator===`.`?str:str.replace(`.`,separator)},uniqueSafeId=()=>uniqueId(``,`_`);var DEFAULT_NAVIGATION=[...MONITORED_UI_NAV_EVENTS,`back`],ALWAYS_ACTIVE=[`ok`,`menu`,`back`],BLOCKER=Symbol(`uiNavBlocker`);const useUINavTracker=defineStore(`uiNavTracker`,()=>{let{lua,events:events$3}=useBridge(),showErrors=window.beamng&&!window.beamng.shipping,initialised=!1,trackedEvents=ref([]),trackedInstances={},ignoredEvents=ref([]),ignoredInstances={},blockedEvents$1=ref([]),blockedInstances={},unblockedEvents=ref([]),unblockedInstances={},activeEvents=ref([]),labelRegistry=useUiNavLabel();function updateBlocklist(){let uiNavService=getUINavServiceInstance(),eventsToBlock=blockedEvents$1.value.filter(name=>!unblockedEvents.value.includes(name));uiNavService.setBlockedEvents(eventsToBlock)}let raf;function update$6(eventName){cancelAnimationFrame(raf),raf=requestAnimationFrame(()=>{activeEvents.value=trackedEvents.value.filter(e=>!ignoredEvents.value.includes(e.name)&&(unblockedEvents.value.includes(e.name)||!blockedEvents$1.value.includes(e.name))).map(e=>({...e,nogroup:!!trackedInstances[e.name]?.at(-1)?.nogroup}))})}let ownerIdCheck=ownerId$1=>{if(typeof ownerId$1!=`string`||!ownerId$1)throw Error(`ownerId is required and must be a string`)},eventNameCheck=(eventName,quiet=!1)=>{let ok=!0;return typeof eventName!=`string`||!eventName?(showErrors&&logger_default.error(`eventName is required`),ok=!1):eventName in ACTIONS_BY_UI_EVENT||(showErrors&&!quiet&&logger_default.error(`eventName ${eventName} does not exist`),ok=!1),ok},getRecentInstance=eventName=>trackedInstances[eventName].findLast(inst=>inst.element!==BLOCKER),parseActive=(active,eventName)=>typeof active==`boolean`?active:ALWAYS_ACTIVE.includes(eventName);function addEvent(eventName,ownerId$1,element=null,options={}){if(initialised||rebind(),!eventNameCheck(eventName))return;ownerIdCheck(ownerId$1),trackedInstances[eventName]||(trackedInstances[eventName]=[]),element||=window.document.body;let instance$1=trackedInstances[eventName].find(instance$2=>instance$2.ownerId===ownerId$1);if(instance$1){instance$1.element=element,instance$1.nogroup=!!options?.nogroup,instance$1.active=parseActive(options?.active,eventName),update$6(eventName);return}if(trackedInstances[eventName].push({ownerId:ownerId$1,element,nogroup:!!options?.nogroup,active:parseActive(options?.active,eventName)}),trackedInstances[eventName].length===1){let event={name:eventName,label:computed(()=>{let instance$2=getRecentInstance(eventName);return labelRegistry.getLabel(eventName,instance$2?.element)||null}),action:computed(()=>getRecentInstance(eventName)?.active?eventFirer(eventName):null)};trackedEvents.value.push(event),actionSwitch(!0,eventName)}update$6(eventName)}function updateEvent(eventName,ownerId$1,element,options={}){if(ownerIdCheck(ownerId$1),!eventNameCheck(eventName))return;element||=window.document.body;let instance$1=trackedInstances[eventName]?.find(instance$2=>instance$2.ownerId===ownerId$1);if(!instance$1){addEvent(eventName,ownerId$1,element,!1,options);return}instance$1.element=element,instance$1.nogroup=!!options?.nogroup,instance$1.active=parseActive(options?.active,eventName),update$6(eventName)}function removeEvent(eventName,ownerId$1,element=null){if(ownerIdCheck(ownerId$1),!eventNameCheck(eventName)||!trackedInstances[eventName])return;element||=window.document.body;let idx=trackedInstances[eventName].findIndex(instance$1=>instance$1.ownerId===ownerId$1);if(idx!==-1&&(trackedInstances[eventName].splice(idx,1),update$6(eventName),trackedInstances[eventName].length===0)){delete trackedInstances[eventName];let idx$1=trackedEvents.value.findIndex(h$1=>h$1.name===eventName);idx$1>-1&&(trackedEvents.value.splice(idx$1,1),actionSwitch(!1,eventName))}}function addHelper(eventList,instanceList,eventName,ownerId$1,func,quiet=!1){ownerIdCheck(ownerId$1),eventNameCheck(eventName,quiet)&&(eventList.value.includes(eventName)||(eventList.value.push(eventName),func&&func(),instanceList[eventName]||(instanceList[eventName]=[])),instanceList[eventName].push(ownerId$1))}function removeHelper(eventList,instanceList,eventName,ownerId$1,func,quiet=!1){if(ownerIdCheck(ownerId$1),!eventNameCheck(eventName,quiet)||!(eventName in instanceList))return;let instIdx=instanceList[eventName].indexOf(ownerId$1);if(instIdx!==-1&&(instanceList[eventName].splice(instIdx,1),instanceList[eventName].length===0)){let idx=eventList.value.indexOf(eventName);idx>-1&&(eventList.value.splice(idx,1),func&&func())}}function addIgnore(eventName,ownerId$1){addHelper(ignoredEvents,ignoredInstances,eventName,ownerId$1,null,!0)}function removeIgnore(eventName,ownerId$1){removeHelper(ignoredEvents,ignoredInstances,eventName,ownerId$1,null,!0)}function addBlocker(eventName,ownerId$1){addHelper(blockedEvents$1,blockedInstances,eventName,ownerId$1,()=>{addEvent(eventName,ownerId$1,BLOCKER),updateBlocklist()})}function removeBlocker(eventName,ownerId$1){removeHelper(blockedEvents$1,blockedInstances,eventName,ownerId$1,()=>{removeEvent(eventName,ownerId$1,BLOCKER),updateBlocklist()})}function addForceUnblock(eventName,ownerId$1){addHelper(unblockedEvents,unblockedInstances,eventName,ownerId$1,()=>{update$6(eventName),updateBlocklist()})}function removeForceUnblock(eventName,ownerId$1){removeHelper(unblockedEvents,unblockedInstances,eventName,ownerId$1,()=>{update$6(eventName),updateBlocklist()})}let actionSwitch=async(enabled,eventName)=>{eventName!==`menu`&&(!enabled&&blockedEvents$1.value.includes(eventName)||await lua.extensions.core_input_bindings.setMenuActionEnabled(enabled,ACTIONS_BY_UI_EVENT[eventName]))};function rebind(){initialised||(initialised=!0,getUINavServiceInstance().clearBlockedEvents(),DEFAULT_NAVIGATION.forEach(name=>addEvent(name,`__uiNavTracker_default`))),Object.keys(ACTIONS_BY_UI_EVENT).filter(name=>!DEFAULT_NAVIGATION.includes(name)&&!trackedEvents.value.find(e=>e.name===name)).forEach(name=>actionSwitch(!1,name))}return lua.extensions.core_input_bindings.getMenuActionMapEnabled().then(enabled=>enabled&&rebind()),events$3.on(`MenuActionMapEnabled`,enabled=>enabled&&rebind()),{activeEvents,blockedEvents:blockedEvents$1,unblockedEvents,addEvent,updateEvent,removeEvent,addIgnore,removeIgnore,addBlocker,removeBlocker,addForceUnblock,removeForceUnblock}});function useUINavBlocker(){let id=uniqueId(`uiNavBlocker`),tracker=useUINavTracker(),allEventNames=Object.keys(ACTIONS_BY_UI_EVENT),defaultEvents=Object.freeze(Object.fromEntries(DEFAULT_NAVIGATION.map(name=>[name,name]))),allEvents=Object.freeze(UI_EVENTS),blockedEvents$1=[],unblockedEvents=[],filterEvents=events$3=>{if(!events$3)return[];if(typeof events$3==`string`)events$3=[events$3];else if(events$3.length===0)return[];return events$3.reduce((res,name)=>allEventNames.includes(name)&&!res.includes(name)?[...res,name]:res,[])};function allowOnly(events$3=[]){events$3=filterEvents(events$3),blockOnly(allEventNames.filter(name=>!events$3.includes(name)))}function allowNavigationOnly(enforce=!0){if(!enforce)return blockOnly();let events$3=[...DEFAULT_NAVIGATION,`menu`];blockOnly(allEventNames.filter(name=>!events$3.includes(name)))}function blockOnly(events$3=[]){events$3=filterEvents(events$3),blockedEvents$1.filter(name=>!events$3.includes(name)).forEach(name=>tracker.removeBlocker(name,id)),blockedEvents$1.splice(0),blockedEvents$1.push(...events$3),blockedEvents$1.forEach(name=>tracker.addBlocker(name,id))}function ensureNoBlock(events$3=[]){events$3=filterEvents(events$3),unblockedEvents.filter(name=>!events$3.includes(name)).forEach(name=>tracker.removeForceUnblock(name,id)),unblockedEvents.splice(0),unblockedEvents.push(...events$3),events$3.forEach(name=>tracker.addForceUnblock(name,id))}function isBlocked(eventName){return tracker.unblockedEvents.includes(eventName)?!1:tracker.blockedEvents.includes(eventName)}let clear=()=>blockOnly();return onUnmounted(clear),{allEvents,defaultEvents,allowOnly,allowNavigationOnly,blockOnly,clear,ensureNoBlock,isBlocked}}const useUiNavLabel=defineStore(`uiNavLabeler`,()=>{let elementLabels=reactive(new WeakMap),eventElements=reactive({});function registerLabel(element,eventNames,label){elementLabels.has(element)||elementLabels.set(element,{});let elementEvents=elementLabels.get(element);Array.isArray(eventNames)||(eventNames=[eventNames]);for(let eventName of eventNames)elementEvents[eventName]=label,eventElements[eventName]||(eventElements[eventName]=new Set),eventElements[eventName].add(element)}function clearLabels(element,eventNames=null){if(!elementLabels.has(element))return;let elementEvents=elementLabels.get(element);if(eventNames===null){for(let eventName of Object.keys(elementEvents))eventElements[eventName]&&eventElements[eventName].delete(element);elementLabels.delete(element)}else{for(let eventName of eventNames)delete elementEvents[eventName],eventElements[eventName]&&eventElements[eventName].delete(element);Object.keys(elementEvents).length===0&&elementLabels.delete(element)}}function getLabel(eventName,element=null){if(element&&elementLabels.has(element)&&elementLabels.get(element)[eventName])return elementLabels.get(element)[eventName];if(eventElements[eventName])for(let el of eventElements[eventName]){let label=elementLabels.get(el)?.[eventName];if(label)return label}return null}function getElementEvents(element){return elementLabels.has(element)?Object.keys(elementLabels.get(element)):[]}return{registerLabel,clearLabels,getLabel,getElementEvents}});var LUA_EXTENSION_NAME=`ui_topBar`;const useTopBar=defineStore(`topBar`,()=>{let{events:events$3}=useBridge(),setupComplete=!1,_items=ref({}),_activeItem=ref(null),visible=ref(!1),hiddenItems=ref([]),gameState$1=reactive({isInGame:void 0,gameState:void 0,uiState:void 0,isCareerActive:void 0,isGarageActive:void 0,isMissionActive:void 0,isScenarioActive:void 0}),sortItems=(a$1,b)=>(a$1.order??0)-(b.order??0),items$2=computed(()=>Object.values(_items.value).filter(item=>!hiddenItems.value||!hiddenItems.value.includes(item.id)).sort(sortItems)),activeItem=computed({get:()=>_activeItem.value,set:value=>{value!==_activeItem.value&&(_activeItem.value=value,Lua_default.ui_topBar.setActiveItem(value))}}),updateTopBarVisibility=()=>{if(!(!gameState$1.uiState||gameState$1.isInGame===void 0)){if(gameState$1.uiState.startsWith(`menu.mainmenu`)&&!gameState$1.isInGame&&(visible.value=!1),!visible.value||gameState$1.uiState===`unknown`){activeItem.value=null;return}if(gameState$1.uiState){let updatedActiveItem=Object.values(_items.value).find(item=>item.targetState===gameState$1.uiState);updatedActiveItem||=Object.values(_items.value).find(item=>item.substate&&gameState$1.uiState.startsWith(item.substate)),activeItem.value=updatedActiveItem?updatedActiveItem.id:null}updateHiddenItems()}};watch(()=>gameState$1.uiState,()=>nextTick(updateTopBarVisibility)),watch(()=>gameState$1.isInGame,()=>nextTick(updateTopBarVisibility));let selectPrevious=()=>{if(!visible.value)return;let len=items$2.value.length;if(len===0)return;let previousIndex=(items$2.value.findIndex(item=>item.id===activeItem.value)-1+len)%len;selectEntry(items$2.value[previousIndex].id)},selectNext=()=>{if(!visible.value)return;let len=items$2.value.length;if(len===0)return;let nextIndex=(items$2.value.findIndex(item=>item.id===activeItem.value)+1)%len;selectEntry(items$2.value[nextIndex].id)},selectEntry=itemId=>{visible.value&&(activeItem.value=itemId,Lua_default.ui_topBar.selectItem(itemId))},show=()=>{visible.value=!0},hide$2=()=>{visible.value=!1};function updateHiddenItems(){hiddenItems.value=Object.values(_items.value).filter(shouldHideItem).map(item=>item.id)}function shouldHideItem(item){if(!item.flags||item.flags.length===0)return!1;for(let flag of item.flags)if(flag===`inGameOnly`&&!gameState$1.isInGame||flag===`careerOnly`&&!gameState$1.isCareerActive||flag===`noCareer`&&gameState$1.isCareerActive||flag===`missionOnly`&&!gameState$1.isMissionActive||flag===`noMission`&&gameState$1.isMissionActive&&!gameState$1.isScenarioUnrestricted||flag===`garageOnly`&&!gameState$1.isGarageActive||flag===`noGarage`&&gameState$1.isGarageActive||flag===`scenarioOnly`&&!gameState$1.isScenarioActive||flag===`noScenario`&&gameState$1.isScenarioActive&&!gameState$1.isScenarioUnrestricted||flag===`careerGarageOnly`&&(!gameState$1.isCareerActive||!gameState$1.isGarageActive)||flag===`noCareerGarage`&&gameState$1.isCareerActive&&gameState$1.isGarageActive)return!0;return!1}function onCareerStateChanged(data){gameState$1.isCareerActive=data.isActive}function onGarageStateChanged(data){gameState$1.isGarageActive=data.isActive}function onMissionStateChanged(data){gameState$1.isMissionActive=data.isActive}function onScenarioStateChanged(data){gameState$1.isScenarioActive=data.isActive}function onDataRequested(data){let{isInGame,items:dataItems}=data;_items.value=dataItems,gameState$1.isInGame=isInGame,hiddenItems.value=[]}function onGameStateChanged(data){gameState$1.isInGame=data.isInGame,gameState$1.isCareerActive=data.isCareerActive,gameState$1.isGarageActive=data.isGarageActive,gameState$1.isMissionActive=data.isMissionActive,gameState$1.isScenarioActive=data.isScenarioActive,gameState$1.isScenarioUnrestricted=data.isScenarioUnrestricted,nextTick(()=>updateHiddenItems())}function onEntriesChanged(data){_items.value=data}function onVisibleItemsChanged(data){hiddenItems.value=data}function onShow(){visible.value=!0}function onHide(){visible.value=!1}let debouncedStateChange=debounce(data=>{gameState$1.uiState=(data.fullPath||data.name||`unknown`).replace(/^\//,``)},100);function onUIStateChanged(data){debouncedStateChange(data)}let eventHandlerMap={selectPrevious,selectNext,OnCareerActive:onCareerStateChanged,garageStateChanged:onGarageStateChanged,missionStateChanged:onMissionStateChanged,scenarioStateChanged:onScenarioStateChanged,dataRequested:onDataRequested,gameStateChanged:onGameStateChanged,entriesChanged:onEntriesChanged,visibleItemsChanged:onVisibleItemsChanged,show:onShow,hide:onHide};function addListeners(){for(let eventName of Object.keys(eventHandlerMap))events$3.on(`${LUA_EXTENSION_NAME}_${eventName}`,eventHandlerMap[eventName])}function removeListeners$1(){for(let eventName of Object.keys(eventHandlerMap))events$3.off(`${LUA_EXTENSION_NAME}_${eventName}`,eventHandlerMap[eventName])}return(async()=>{setupComplete||=(await Lua_default.extensions.isExtensionLoaded(LUA_EXTENSION_NAME)||await Lua_default.extensions.load(LUA_EXTENSION_NAME),addListeners(),await Lua_default.ui_topBar.requestData(),!0)})(),{activeItem,items:items$2,visible,gameState:gameState$1,show,hide:hide$2,selectEntry,selectPrevious,selectNext,onUIStateChanged,dispose:()=>{removeListeners$1(),Lua_default.extensions.unload(LUA_EXTENSION_NAME)}}});var events$2,beamNG,serviceProviders=ref(),online=ref(!1),videoAdapter=ref(``),modCounts=ref({total:0,active:0}),gameState=ref(),mainMenuBackgroundRequired=ref(),mainMenuFirstTime=ref(!0),serviceProvidersOnline=computed(()=>{let provs=serviceProviders.value,gotInfo=!!provs,ret={eos:gotInfo&&provs.eos&&provs.eos.loggedin,steam:gotInfo&&provs.steam&&provs.steam.loggedin&&provs.steam.working};return ret.any=Object.values(ret).some(v=>v),ret}),version,versionSimple,buildInfo,init$2=()=>{let api$1;({api:api$1,events:events$2,beamNG}=useBridge()),beamNG||=FAKE_BEAMNG_OBJ,api$1.serializeToLuaCheck(`English: hello`),api$1.serializeToLuaCheck(`Spanish: güeñes`),api$1.serializeToLuaCheck(`French: bâguéttè, garçon`),api$1.serializeToLuaCheck(`Czech: Kl�vesnice`),api$1.serializeToLuaCheck(`Korean: \r��\v��\v��`),api$1.serializeToLuaCheck(`Chinese Sim: 欢迎来到简体中文版的`),api$1.serializeToLuaCheck(`Chinese Tr: 歡迎來到`),api$1.serializeToLuaCheck(`Japanese: 』日本語版にようこそ`),api$1.serializeToLuaCheck(`Polish: źćłąóę`),api$1.serializeToLuaCheck(`Russian: абвгеёьъ`),events$2.on(`ServiceProviderInfo`,info=>serviceProviders.value=info),events$2.on(`OnlineStateChanged`,state=>online.value=state),events$2.on(`ModManagerModsChanged`,_processModData),events$2.on(`ShowEntertainingBackground`,state=>mainMenuBackgroundRequired.value=state),events$2.on(`GameStateUpdate`,state=>gameState.value=state.state),version=beamNG.version,versionSimple=_toSimpleVersion(beamNG.version),buildInfo=beamNG.buildinfo,refresh()},refresh=()=>{_requestServiceProviders(),_requestOnlineState(),_refreshVideoAdapter(),_refreshModData()},_refreshVideoAdapter=()=>Lua_default.Engine.Render.getAdapterType().then(adapter=>videoAdapter.value=adapter),_requestServiceProviders=()=>beamNG.requestServiceProviderInfo(),_requestOnlineState=()=>Lua_default.core_online.requestState(),_refreshModData=()=>Lua_default.core_modmanager.requestState(),sysInfo_default={init:init$2,refresh,serviceProviders,serviceProvidersOnline,online,videoAdapter,modCounts,gameState,mainMenuBackgroundRequired,mainMenuFirstTime,get version(){return version},get versionSimple(){return versionSimple},get buildInfo(){return buildInfo}},_toSimpleVersion=versionStr=>{let bits=versionStr.split(`.`);return bits.length==5&&bits.pop(),bits.join(`.`).replace(/(\.0)+$/,``)},_processModData=data=>{let mods=Object.values(data).filter(mod=>mod.modname!=`translations`);modCounts.value.total=mods.length,modCounts.value.active=mods.filter(({active})=>active).length},FAKE_BEAMNG_OBJ={version:`0.12.3.4.FAKE12345`,buildInfo:`Sample Fake BuildInfo - running outside of game`,requestServiceProviderInfo(){events$2.emit(`ServiceProviderInfo`,{steam:{loggedin:!0,accountID:`12345678901234567`,playerName:`fakeplayer`,branch:`qa_latest`,language:`english`,useSteam:!0,working:!0}})}};const useLibStore=defineStore(`lib`,{});var bridge$2,stateStack=[];function add(stateName){rem(stateName),stateStack.push(stateName)}function rem(stateName){let idx=stateStack.lastIndexOf(stateName);idx>-1&&stateStack.splice(idx,1)}var luaStringify=any=>JSON.stringify(any).replace(/^\[(.*)\]$/,`{$1}`),luaReport=(stateName,opened)=>bridge$2.api.engineLua(`extensions.hook("onUIStateTriggered", ${luaStringify(stateName)}, ${luaStringify(!!opened)}, ${luaStringify(stateStack)})`);function reportState(stateName,opened,prevName=null){bridge$2||=useBridge(),prevName&&(rem(prevName),luaReport(prevName,!1)),opened?add(stateName):rem(stateName),luaReport(stateName,opened)}function reportPopupState(popup,opened){reportState(`/popup/${popup.componentName}/${popup.wrapper.blur?`fullscreen`:`aside`}`,opened)}function scroll(el,binding){let direction$1=binding.arg;el.scrollHeight<=el.clientHeight||(direction$1===`top`?el.scrollTop>0&&(el.scrollTop=0):direction$1===`bottom`&&el.scrollTop{let id,blurAmount=1,blurUpdateWrapper=debounce(updateBlur,50),resizeObserver,removePositionObserver;function observe(){resizeObserver||(resizeObserver=new ResizeObserver(blurUpdateWrapper),resizeObserver.observe(el)),removePositionObserver||=observePosition(el,blurUpdateWrapper)}function unobserve(){resizeObserver&&resizeObserver.disconnect(),removePositionObserver&&removePositionObserver(),resizeObserver=null,removePositionObserver=null}elemBlurs.set(el,{blurUpdateWrapper,processBlurVal,observe,unobserve}),processBlurVal(binding.value),window.addEventListener(`resize`,blurUpdateWrapper);function processBlurVal(val){switch(typeof val){case`undefined`:val=1;break;case`boolean`:val=val?1:0;break;case`number`:(val<0||val>1)&&(logger_default.error(`Attempted to use v-bng-blur with a number out of range 0..1: ${val}\nSee stack:`,logger_default.STACK_TRACE),val=1);break;default:logger_default.error(`Attempted to use v-bng-blur with a non-number, non-boolean value: ${val}\nSee stack:`,logger_default.STACK_TRACE),val=0}blurAmount=val,blurUpdateWrapper()}function calcBlur(){let rect=el.getBoundingClientRect();return rect.width>0&&rect.height>0&&rect.bottom>0&&rect.top0&&rect.left{let elemBlur=elemBlurs.get(el);elemBlur&&binding.value!=binding.oldValue&&elemBlur.processBlurVal(binding.value)},unmounted:(el,binding)=>{let elemBlur=elemBlurs.get(el);elemBlur&&(elemBlur.unobserve(),elemBlur.processBlurVal(0),window.removeEventListener(`resize`,elemBlur.blurUpdateWrapper),elemBlurs.delete(el))}},DEFAULT_HOLD_DELAY=400,DEFAULT_REPEAT_INTERVAL=100,HOLD_CSS_TIME_VAR=`--hold-time`,HOLD_START_CSS_CLASS=`hold-start`,HOLD_ACTIVE_CSS_CLASS=`hold-active`,HOLD_COMPLETED_CSS_CLASS=`hold-completed`,EVENT_CLICK=`click`,EVENT_HOLD=`hold`,ELEMENT_ID=`__BNG_CLICK_ID`,curId=0,datas={};function update$5(element,binding){let id=element[ELEMENT_ID]||(element[ELEMENT_ID]=++curId),data=datas[id]||(datas[id]={id,element,events:{},binding:{}});if(typeof binding.value==`object`)data.binding=binding.value;else if(typeof binding.value==`function`){let cbName=binding.modifiers?.hold?`holdCallback`:`clickCallback`;data.binding[cbName]=binding.value}return data.controllerOnly=!!binding.modifiers?.controller,data.hasClick=typeof data.binding.clickCallback==`function`,data.hasHold=typeof data.binding.holdCallback==`function`,typeof data.binding.holdDelay!=`number`&&(data.binding.holdDelay=DEFAULT_HOLD_DELAY),typeof data.binding.repeatInterval!=`number`&&(data.binding.repeatInterval=DEFAULT_REPEAT_INTERVAL),data}function remove(element){let id=element[ELEMENT_ID];if(!id)return;let data=datas[id];data&&(`mouseleave`in data.events&&data.events.mouseleave(),updateEvents(id),delete datas[id],delete element[ELEMENT_ID])}function updateEvents(id,events$3={}){let data=datas[id];if(data){for(let event in data.events)data.element.removeEventListener(event,data.events[event]);for(let event in events$3)data.element.addEventListener(event,events$3[event]);data.events=events$3}}var BngClick_default={mounted:(el,binding)=>{let data=update$5(el,binding),approveEvent=evt=>data.controllerOnly?!!evt.fromController:evt.button===0||evt.fromController,tmrHoldActive;updateEvents(data.id,{mousedown:e=>{approveEvent(e)&&(el.style.setProperty(HOLD_CSS_TIME_VAR,`${data.binding.holdDelay}ms`),el.classList.toggle(HOLD_START_CSS_CLASS,!0),clearTimeout(tmrHoldActive),tmrHoldActive=setTimeout(()=>el.classList.toggle(HOLD_ACTIVE_CSS_CLASS,!0),0),el.classList.toggle(HOLD_COMPLETED_CSS_CLASS,!1),canInvokeEventType(EVENT_CLICK)&&(detectedEventType=EVENT_CLICK),canInvokeEventType(EVENT_HOLD)&&startHoldDelayTimer(e))},mouseup:e=>{if(approveEvent(e)){switch(el.style.removeProperty(HOLD_CSS_TIME_VAR),el.classList.toggle(HOLD_START_CSS_CLASS,!1),el.classList.toggle(HOLD_ACTIVE_CSS_CLASS,!1),clearTimeout(tmrHoldActive),stopHoldDelayTimer(),detectedEventType){case EVENT_CLICK:doAction(EVENT_CLICK,e);break;case EVENT_HOLD:stopHoldTimer();break}detectedEventType=null}},mouseleave:()=>{switch(el.style.removeProperty(HOLD_CSS_TIME_VAR),el.classList.toggle(HOLD_START_CSS_CLASS,!1),el.classList.toggle(HOLD_ACTIVE_CSS_CLASS,!1),clearTimeout(tmrHoldActive),stopHoldDelayTimer(),detectedEventType){case EVENT_HOLD:stopHoldTimer();break}detectedEventType=null},blur:()=>data.events.mouseleave()});let detectedEventType,holdDelayTimer,holdTimer;function startHoldDelayTimer(e){stopHoldTimer(),stopHoldDelayTimer(),holdDelayTimer=setTimeout(()=>{el.classList.toggle(HOLD_COMPLETED_CSS_CLASS,!0),detectedEventType=EVENT_HOLD,startHoldTimer(e)},data.binding.holdDelay)}function stopHoldDelayTimer(){holdDelayTimer&&=(clearTimeout(holdDelayTimer),null)}function startHoldTimer(e){doAction(EVENT_HOLD,e),data.binding.repeatInterval&&(stopHoldTimer(),holdTimer=setInterval(()=>{doAction(EVENT_HOLD,e)},data.binding.repeatInterval))}function stopHoldTimer(){holdTimer&&=(clearInterval(holdTimer),null)}function doAction(eventType,originalEvent){let callback=getCallback(eventType);callback&&(eventType==EVENT_HOLD?setTimeout(()=>callback(originalEvent),100):callback(originalEvent))}function getCallback(arg){switch(arg){case EVENT_CLICK:return data.binding.clickCallback;case EVENT_HOLD:return data.binding.holdCallback}return null}function canInvokeEventType(eventType){switch(eventType){case EVENT_CLICK:return data.hasClick;case EVENT_HOLD:return data.hasHold}return!1}},updated:update$5,beforeUnmount:remove},BngDisabled_default=(el,{value})=>{let has$1={disabled:el.hasAttribute(`disabled`),tabindex:el.hasAttribute(`tabindex`)};!has$1.disabled&&value?(el.setAttribute(`disabled`,`disabled`),has$1.tabindex&&(el._BNG_TABINDEX=el.getAttribute(`tabindex`),el.setAttribute(`tabindex`,`-1`))):has$1.disabled&&!value&&(el.removeAttribute(`disabled`),has$1.tabindex&&`_BNG_TABINDEX`in el&&el.getAttribute(`tabindex`)!==el._BNG_TABINDEX&&(el.setAttribute(`tabindex`,el._BNG_TABINDEX),delete el._BNG_TABINDEX))},DELAY=300,EVENTS_IN=[`uinav-focus`,`focus`,`focusin`],EVENTS_OUT=[`uinav-blur`,`blur`,`focusout`],elems$1=new Map,globInit=!1;function initGlobals(){globInit=!0;let running=!1,targets={in:[],out:[]};function preventer(){for(let[part,list]of Object.entries(targets))if(list.length!==0){for(let target of list)for(let[uid$2,data]of elems$1)if(!(!data.capture||!data.timer||!data.element)){if(part===`in`){if(data.element===target||data.element.contains(target))continue}else if(data.element!==target&&!data.element.contains(target))continue;clearTimeout(data.timer),data.timer=null;break}list.splice(0)}}function handler$1(evt,eventIn){if(elems$1.size===0)return;let target=evt.detail?.target||evt.target;if(!target)return;let part=eventIn?`in`:`out`;targets[part].includes(target)||targets[part].push(target),!running&&(running=!0,window.requestAnimationFrame(()=>{preventer(),running=!1}))}EVENTS_IN.forEach(evt=>document.addEventListener(evt,evt$1=>handler$1(evt$1,!0),!0)),EVENTS_OUT.forEach(evt=>document.addEventListener(evt,evt$1=>handler$1(evt$1,!1),!0))}function createHandler(data){return data.capture?evt=>{evt.detail?.doubleToSingle||(evt.preventDefault(),evt.stopImmediatePropagation(),data.timer?(clearTimeout(data.timer),data.timer=null,data.callback?.()):data.timer=setTimeout(()=>{data.timer=null;let click$1=new CustomEvent(`click`,{...evt,bubbles:!0,cancelable:!0,detail:{doubleToSingle:!0}});data.element.dispatchEvent(click$1)},DELAY))}:()=>{data.timer&&=(clearTimeout(data.timer),null);let now$1=Date.now();if(data.time&&now$1-data.time<=DELAY){data.time=0,data.callback?.();return}data.time=now$1}}function update$4(vnode,callback=void 0,mod={}){!globInit&&initGlobals();let el=vnode?.el;if(!el)return;let uid$2=vnode?.component?.uid||vnode?.key||el,capture=!!mod.capture,data=elems$1.get(uid$2)||{};data.handler&&data.element===el&&callback&&`callback`in data&&data.callback===callback&&data.capture===capture||(`element`in data||(data.element=el,data.callback=callback,data.capture=capture),data.handler&&(!callback||data.capture!==capture||data.element!==el)&&(delete data.callback,el.removeEventListener(`click`,data.handler,{capture:data.capture}),elems$1.delete(uid$2)),callback&&(data.handler?data.callback=callback:(data.capture=capture,data.handler=createHandler(data),el.addEventListener(`click`,data.handler,{capture}),elems$1.set(uid$2,data))))}var BngDoubleClick_default={mounted:(el,{value,modifiers,arg}={},vnode)=>update$4(vnode||{el},value,{capture:arg===`capture`,...modifiers}),updated:(el,{value,modifiers,arg}={},vnode)=>update$4(vnode||{el},value,{capture:arg===`capture`,...modifiers}),unmounted:(el,vnode)=>update$4(vnode||{el})},DRAG_START_EVENT_NAME=`bngDragStart`,DRAG_OVER_EVENT_NAME=`bngDragOver`,DRAG_END_EVENT_NAME=`bngDragEnd`;const DRAG_EVENTS=Object.freeze({dragStart:DRAG_START_EVENT_NAME,dragOver:DRAG_OVER_EVENT_NAME,dragEnd:DRAG_END_EVENT_NAME});var STORE_NAME=`controls`,store,DEVICE_ICONS={key:`keyboard`,mou:`mouseLMB`,vin:`smartphone2`,whe:`steeringWheelCommon`,gam:`gamepadOld`,xin:`gamepadOld`,default:`gamepad`};const CONTROL_LABELS={escape:`ESC`,enter:`⏎`,tab:`⭾`,capslock:`⇪`,backspace:`⌫`,delete:`Del`,insert:`Ins`,home:`Home`,end:`End`,pageup:`PG↑`,pagedown:`PG↓`,lshift:`L⇧`,rshift:`R⇧`,shift:`⇧`,lcontrol:`L Ctrl`,rcontrol:`R Ctrl`,lalt:`L Alt`,ralt:`R Alt`,left:`←`,right:`→`,up:`↑`,down:`↓`,space:`␣`,grave:`~`,backslash:`\\`,"/":`/`,comma:`,`,period:`.`,";":`;`,apostrophe:`'`,"[":`[`,"]":`]`,minus:`-`,"+":`NP+`,"*":`NP*`,numpaddivide:`NP/`,numpad0:`NP0`,numpad1:`NP1`,numpad2:`NP2`,numpad3:`NP3`,numpad4:`NP4`,numpad5:`NP5`,numpad6:`NP6`,numpad7:`NP7`,numpad8:`NP8`,numpad9:`NP9`,numpaddecimal:`NP.`,numpadenter:`NP⏎`,xaxis:`X Axis`,yaxis:`Y Axis`,zaxis:`Z Axis`,rzaxis:`R Z Axis`,thumblx:`L Thumb X`,thumbly:`L Thumb Y`,thumbrx:`R Thumb X`,thumbry:`R Thumb Y`};var controlLabel=control=>control.toLowerCase().split(/[ -]+/).map(ctl=>CONTROL_LABELS[ctl]||(ctl.startsWith(`button`)?`BTN`+ctl.substring(6):ctl)).join(` + `),CONTROL_ICONS={pc_mouse:{button0:`mouseLMB`,button1:`mouseRMB`,button2:`mouseMMB`,xaxis:`mouseXAxis`,yaxis:`mouseYAxis`,zaxis:`mouseWheel`},xbox:{btn_a:`xboxA`,btn_b:`xboxB`,btn_x:`xboxX`,btn_y:`xboxY`,btn_back:`xboxView`,btn_start:`xboxMenu`,btn_l:`xboxLB`,triggerl:`xboxLT`,btn_r:`xboxRB`,triggerr:`xboxRT`,dpov:`xboxDDown`,lpov:`xboxDLeft`,rpov:`xboxDRight`,upov:`xboxDUp`,thumblx:`xboxXAxis`,thumbly:`xboxYAxis`,thumbrx:`xboxXRot`,thumbry:`xboxYRot`,btn_lt:`xboxLSButton`,btn_rt:`xboxRSButton`},ps:{button1:`psCross`,button3:`psTriangle`,button0:`psSquare`,button2:`psCircle`,button8:`psCreate2`,button9:`psMenu2`,button4:`psL1`,button6:`psL2`,button5:`psR1`,button7:`psR2`,dpov:`psDDown`,lpov:`psDLeft`,rpov:`psDRight`,upov:`psDUp`,xaxis:`psLSX`,yaxis:`psLSY`,zaxis:`psRSX`,rzaxis:`psRSY`,rxaxis:`psL2`,ryaxis:`psR2`,button10:`psL3Button`,button11:`psR3Button`,button13:`psTrackpadPressCenter`}};const DEVICE_CONTROLS={pc_mouse:Object.keys(CONTROL_ICONS.pc_mouse),xbox:Object.keys(CONTROL_ICONS.xbox),ps:Object.keys(CONTROL_ICONS.ps)};var extendControlGroupNames=groups=>groups.reduce((res,group)=>(res.push(group),res.push({...group,controls:group.controls.map(ctl=>CONTROL_LABELS[ctl])}),res),[]),GROUPED_CONTROLS={pc_keyboard:extendControlGroupNames([{label:`↑↓←→`,controls:[`left`,`right`,`up`,`down`]},{label:`NP 8↑ 2↓ 4← 6→`,controls:[`numpad2`,`numpad4`,`numpad6`,`numpad8`]}]),xbox:extendControlGroupNames([{icon:`xboxDDefaultSolid`,controls:[`upov`,`dpov`,`lpov`,`rpov`]},{icon:`xboxThumbL`,controls:[`thumblx`,`thumbly`]},{icon:`xboxThumbR`,controls:[`thumbrx`,`thumbry`]}]),ps:extendControlGroupNames([{icon:`psDDefaultSolid`,controls:[`upov`,`dpov`,`lpov`,`rpov`]},{icon:`psLS`,controls:[`xaxis`,`yaxis`]},{icon:`psRS`,controls:[`zaxis`,`rzaxis`]}])},DEVICE_FAMILY={mouse:`pc_mouse`,keyboard:`pc_keyboard`,xinput:`xbox`,ps5:`ps`},CONTROL_ICON_KEYS=Object.keys(DEVICE_FAMILY),getViewerOverrides=(devName=void 0,imagePack=void 0)=>{let family;return imagePack&&(imagePack in DEVICE_FAMILY?family=DEVICE_FAMILY[imagePack]:imagePack in CONTROL_ICONS&&(family=imagePack)),!family&&devName&&(devName=CONTROL_ICON_KEYS.find(key=>devName.startsWith(key))||devName,devName in DEVICE_FAMILY?family=DEVICE_FAMILY[devName]:devName in CONTROL_ICONS&&(family=devName)),family?{family,icons:CONTROL_ICONS[family]||{},groups:GROUPED_CONTROLS[family]||[]}:null},DEVICE_ORDER=[`wheel`,`joystick`,`xinput`,`gamepad`,`mouse`,`keyboard`],makeStore=defineStore(STORE_NAME,()=>{let{events:events$3}=useBridge(),devNamesOrder=DEVICE_ORDER.map(devType=>devType+`0`),actions=ref([]),categories=ref({}),categoriesList=ref([]),bindings=ref([]),bindingsPerDevice=computed(()=>Object.fromEntries(bindings.value.map(b=>[b.devname,b]))),bindingTemplate=ref({}),controllers=ref({}),players=ref({}),lastDeviceOrder=ref([...devNamesOrder]),lastDevice=computed(()=>isKbm(lastDeviceOrder.value[0])?kbmDevNames:lastDeviceOrder.value[0]),lastControllers=computed(()=>lastDeviceOrder.value.filter(devName=>!isKbm(devName))),lastControllersSignature=computed(()=>lastControllers.value.sort().join(`::`)),isControllerUsed=computed(()=>!isKbm(lastDeviceOrder.value[0])),isControllerAvailable=computed(()=>lastDeviceOrder.value.some(devName=>!isKbm(devName))),lastDeviceSimple=computed(()=>isControllerUsed.value?lastDevice.value:null),getDevType=devName=>devName?devName.replace(/\d+$/,``):``,deviceSorter=(a$1,b)=>DEVICE_ORDER.indexOf(getDevType(a$1))-DEVICE_ORDER.indexOf(getDevType(b)),kbmDevNames=[`keyboard0`,`mouse0`].sort(deviceSorter),kbmShortNames=kbmDevNames.map(devName=>devName.slice(0,3)),isKbm=devName=>devName&&kbmShortNames.includes(devName.slice(0,3)),_receiveControlsData=data=>(controllers.value=data,_updateDeviceNotes()),_receivePlayersData=data=>players.value=data,_receiveBindingsData=_processBindingsData,_getBindingsData=()=>Lua_default.extensions.core_input_bindings.notifyUI(`Vue controls service needs the data`),connect=(state=!0)=>{let method=state?`on`:`off`;events$3[method](`ControllersChanged`,_receiveControlsData),events$3[method](`AssignedPlayersChanged`,_receivePlayersData),events$3[method](`InputBindingsChanged`,_receiveBindingsData),events$3[method](`RecentDevicesChanged`,_requestRecentDevices)},disconnect=()=>connect(!1),deviceIcon=deviceName=>DEVICE_ICONS[(deviceName||``).slice(0,3)]||DEVICE_ICONS.default;async function _requestRecentDevices(devNames=void 0){devNames||=await Lua_default.extensions.core_input_bindings.getRecentDevices(),!Array.isArray(devNames)||devNames.length===0?devNames=devNamesOrder:isKbm(devNames[0])&&(devNames=[...kbmDevNames,...devNames.filter(devName=>!isKbm(devName))]),lastDeviceOrder.value.splice(0,lastDeviceOrder.value.length,...devNames)}function*getBindingsIter(devFilter=[],useLastDeviceOrder=!1){if(!useLastDeviceOrder||devFilter.length>0)yield*bindings.value;else for(let devName of lastDeviceOrder.value){let binding=bindingsPerDevice.value[devName];binding&&(yield binding)}}let findBindingForAction=(action,devName=void 0,useLastDeviceOrder=!1)=>{let devFilter=devName?Array.isArray(devName)?devName:[devName]:[],bindingsIter=getBindingsIter(devFilter,useLastDeviceOrder);for(let binding of bindingsIter){if(devFilter.length>0&&!devFilter.includes(binding.devname))continue;let found=binding.contents.bindings.find(b=>b.action===action);if(found){let help=getBindingDetails(binding.devname,found.control,action);if(help)return help.devName=binding.devname,help.imagePack=binding.contents.imagePack,help}}},findAllBindingsForAction=(action,devName=void 0,allDevices=!1,useLastDeviceOrder=!1)=>{let res=[],devFilter=devName?Array.isArray(devName)?devName:[devName]:[],bindingsIter=getBindingsIter(devFilter,useLastDeviceOrder);for(let binding of bindingsIter){if(devFilter.length>0&&!devFilter.includes(binding.devname))continue;let matches$1=binding.contents.bindings.filter(b=>b.action===action);if(matches$1.length>0)for(let match of matches$1){let help=getBindingDetails(binding.devname,match.control,action);help&&(!allDevices&&devFilter.length===0&&devFilter.push(binding.devname),help.devName=binding.devname,help.imagePack=binding.contents.imagePack,res.push(help))}}return res},defaultBindingEntry=(action,control)=>({...bindingTemplate.value,action,control}),isAxis=(device,control)=>{let c=controllers.value[device].controls[control];return c&&c.control_type==`axis`},bindingConflicts=(device,control,action)=>bindings.value.find(b=>b.devname==device).contents.bindings.filter(b=>b.control==control).filter(b=>b.action!=action).map(b=>({...b,...getBindingDetails(device,control,b.action),resolved:!1})),captureBinding=(modifiersAllowed=!0)=>{let controlCaptured=!1,eventsRegister={},d=defer(),capturingBinding=!0;function _listener(data){if(!capturingBinding||controlCaptured)return;let devName=data.devName;eventsRegister[devName]||(eventsRegister[devName]={axis:{},key:[null,null]});let eventData=eventsRegister[devName];d.notify(eventsRegister);let valid=!1,key0,key1,key0Parts,key1Parts,genericModifierKeys=[`lalt`,`lcontrol`,`lshift`,`ralt`,`rcontrol`,`rshift`];switch(data.controlType){case`axis`:if(!eventData.axis[data.control])eventData.axis[data.control]={first:data.value,last:data.value,accumulated:0};else{let detectionThreshold=devName.startsWith(`mouse`)?1:.5;eventData.axis[data.control].accumulated+=Math.abs(eventData.axis[data.control].last-data.value)/detectionThreshold,eventData.axis[data.control].last=data.value}valid=eventData.axis[data.control].accumulated>=1;break;case`button`:case`pov`:case`key`:if(eventData.key=[eventData.key.at(-1),data.control],key0=eventData.key[0],key1=eventData.key[1],key0&&key1){let validSet=!1;key0Parts=key0.split(` `),key1Parts=key1.split(` `),key0Parts.length===1&&key1Parts.length===2&&key1Parts[1]===key0Parts[0]&&(eventData.key[1]=key0,key1=key0,data.control=key0,modifiersAllowed||(valid=!1,validSet=!0)),validSet||(valid=key0===key1,!modifiersAllowed&&(key0Parts.length===2||genericModifierKeys.includes(data.control))&&(valid=!1)),data.value===0&&(eventData.key=[null,null])}break;default:console.error(`Unrecognised raw input controlType: `+JSON.stringify(data))}valid&&data.devName.startsWith(`mouse`)&&data.control===`button1`&&(valid=!1),valid&&(controlCaptured=!0,capturingBinding=!1,data.direction=data.controlType===`axis`?Math.sign(eventData.axis[data.control].last-eventData.axis[data.control].first):0,d.resolve(data),_captureHelper.stopListening())}return Lua_default.ActionMap.enableBindingCapturing(!0),Lua_default.setCEFTyping(!0),_captureHelper.stopListening=()=>{Lua_default.ActionMap.enableBindingCapturing(!1),Lua_default.WinInput.setForwardRawEvents(!1),Lua_default.setCEFTyping(!1),events$3.off(`RawInputChanged`,_listener)},events$3.on(`RawInputChanged`,_listener),Lua_default.WinInput.setForwardRawEvents(!0),d.promise},removeBinding=(device,control,action,mockSave)=>{let deviceContents={...bindings.value.find(b=>b.devname==device).contents};deviceContents.bindings=[...deviceContents.bindings];let entryIndex=deviceContents.bindings.findIndex(b=>b.control==control&&b.action==action)||null;if(entryIndex)if(deviceContents.bindings.splice(entryIndex,1),mockSave){let deviceIndex=bindings.value.findIndex(b=>b.devname==device);bindings.value[deviceIndex].contents=deviceContents}else serializeCheck(deviceContents.name),Lua_default.extensions.core_input_bindings.saveBindingsToDisk(deviceContents)},addBinding=(device,bindingData,replace,mockSave)=>{let deviceContents={...bindings.value.find(b=>b.devname==device).contents};if(deviceContents.bindings=[...deviceContents.bindings],replace){let deprecatedIndex=deviceContents.bindings.findIndex(b=>b.control==bindingData.details.control&&b.action==bindingData.details.action);deviceContents[deprecatedIndex]=bindingData}else serializeCheck(deviceContents.name),Lua_default.extensions.core_input_bindings.saveBindingsToDisk(deviceContents)},isFFBBound=()=>{for(let i=0;i{let ffbCapable=()=>Object.values(controllers.value).some(controller=>controller.ffbAxes&&Object.keys(controller.ffbAxes).length>0);return asRef?computed(()=>ffbCapable()):ffbCapable},getIsControllerAvailable=(asRef=!1)=>asRef?isControllerAvailable:isControllerAvailable.value,isWheelFound=vendorId=>{for(let b of bindings.value)if(b.devname.slice(0,3)===`whe`&&b.contents.vidpid.slice(4,8)==vendorId)return!0;return!1};function isFFBEnabled(asRef=!1){let filter=()=>bindings.value.filter(b=>b.devname.slice(0,3)!==`xin`).some(b=>b.contents.bindings.some(binding=>binding.action===`steering`&&binding.isForceEnabled));return asRef?computed(()=>filter()):filter()}function isPidVidFound(desiredVid,desiredPid,asRef=!1){let filter=()=>bindings.value.some(b=>{let vid=desiredVid===void 0?desiredVid:b.contents.vidpid.slice(4,8),pid$1=desiredPid===void 0?desiredPid:b.contents.vidpid.slice(0,4);return vid==desiredVid&&pid$1==desiredPid});return asRef?computed(()=>filter()):filter()}function getBindingDetails(device,control,action){let actionDetails=getActionDetails(action);if(!actionDetails){console.warn(`Action details not found: `,action);return}let deviceBindings=bindings.value.find(b=>b.devname===device).contents.bindings,common={icon:deviceIcon(device),title:actionDetails.title,desc:actionDetails.desc},details=deviceBindings.find(b=>b.control===control&&b.action===action)||defaultBindingEntry(action,control),isBindingAxis=isAxis(device,control);return{...bindingTemplate.value,...details,...common,isAxis:isBindingAxis,action:actionDetails.action,actionName:actionDetails.actionName}}function getActionDetails(action){let actionDetails=actions.value[action];if(actionDetails)return{...actionDetails,action:actionDetails.actionName}}function addNewBinding(bindingData){let{devname,control,action}=bindingData,device=bindings.value.find(b=>b.devname==devname);if(!device){console.warn(`Device not found: `,devname);return}let deviceContents=device.contents;deviceContents.bindings.push({...bindingTemplate.value,...bindingData,control,action}),serializeCheck(deviceContents.name),Lua_default.extensions.core_input_bindings.saveBindingsToDisk(deviceContents)}function updateBinding(bindingData){let{devname,control,action}=bindingData,oldDevname=bindingData.oldDevname||devname,oldControl=bindingData.oldControl||control,device=bindings.value.find(b=>b.devname==oldDevname);if(!device){console.warn(`Device not found: `,oldDevname);return}let deviceContents=device.contents,deprecatedIndex=deviceContents.bindings.findIndex(b=>b.control==oldControl&&b.action==action);if(deprecatedIndex===-1){console.warn(`Binding not found: `,oldDevname,oldControl,action);return}if(devname===oldDevname)delete bindingData.oldDevname,delete bindingData.oldControl,deviceContents.bindings[deprecatedIndex]={...bindingData};else{deviceContents.bindings.splice(deprecatedIndex,1);let newDeviceContents=bindings.value.find(b=>b.devname===devname).contents;newDeviceContents.bindings.push({...bindingData,bindingTemplate:bindingTemplate.value}),serializeCheck(newDeviceContents.name),Lua_default.extensions.core_input_bindings.saveBindingsToDisk(newDeviceContents)}serializeCheck(deviceContents.name),Lua_default.extensions.core_input_bindings.saveBindingsToDisk(deviceContents)}function deleteBindings(bindingsData){let bindingsByDevname=bindingsData.reduce((acc,b)=>(acc[b.devname]=acc[b.devname]||[],acc[b.devname].push(b),acc),{});for(let devname in bindingsByDevname){let device=bindings.value.find(b=>b.devname==devname);if(!device){console.warn(`Device not found: `,devname);continue}let deviceContents=device.contents;bindingsByDevname[devname].forEach(b=>{let index=deviceContents.bindings.findIndex(binding=>binding.control==b.control&&binding.action==b.action);index!==-1&&deviceContents.bindings.splice(index,1)}),serializeCheck(deviceContents.name),Lua_default.extensions.core_input_bindings.saveBindingsToDisk(deviceContents)}}function deleteBinding({devname,control,action}){let device=bindings.value.find(b=>b.devname==devname);if(!device){console.warn(`Device not found: `,devname);return}let deviceContents=device.contents,index=deviceContents.bindings.findIndex(b=>b.control==control&&b.action==action);if(index===-1){console.warn(`Binding not found: Skipping...`,devname,control,action);return}deviceContents.bindings.splice(index,1),serializeCheck(deviceContents.name),Lua_default.extensions.core_input_bindings.saveBindingsToDisk(deviceContents)}function getAllBindingsForAction(action,devName,asRef=!1){let filteredBindings=()=>bindings.value.filter(b=>(!devName||b.devname==devName)&&b.contents.bindings.find(a$1=>a$1.action===action)).flatMap(b=>b.contents.bindings.filter(x=>x.action===action).map(x=>({...x,...getBindingDetails(b.devname,x.control,x.action),devname:b.devname,action,actionName:action})));return asRef?computed(()=>filteredBindings()):filteredBindings()}let _captureHelper={devName:null,stopListening:null};function _updateDeviceNotes(){Object.values(bindings.value).forEach(({contents:bindingContents})=>{for(let id in controllers.value){let controller=controllers.value[id];if(bindingContents.vidpid==controller.vidpid){controller.notes=bindingContents.notes;break}}})}let lastBindingsData=null;function _processBindingsData(data){let newBindingsData=JSON.stringify(data);if(lastBindingsData===newBindingsData)return;if(lastBindingsData=newBindingsData,Array.isArray(data.bindings)||(data.bindings=[]),data.bindings.forEach(device=>{Array.isArray(device.contents.bindings)||(device.contents.bindings=Object.values(device.contents.bindings))}),bindingTemplate.value=data.bindingTemplate,bindings.value=data.bindings,!data.actionCategories||!data.bindingTemplate||data.bindings.length===0){logger_default.debug(`Did not receive bindings data. Timing issue?`);return}bindings.value.sort((a$1,b)=>deviceSorter(a$1.devname,b.devname)),devNamesOrder.splice(0),kbmDevNames.splice(0);for(let binding of data.bindings){let devName=binding.devname;devNamesOrder.includes(devName)||devNamesOrder.push(devName),isKbm(devName)&&kbmDevNames.push(devName),binding.icon=deviceIcon(devName)}_requestRecentDevices();let acts={};for(let act in data.actions)acts[act]={actionName:act,...data.actions[act]};for(let cat in actions.value=acts,categories.value=data.actionCategories,categories.value)typeof categories.value[cat]==`object`&&(categories.value[cat].actions=[]);for(let act in actions.value){let obj={key:act,...actions.value[act]};actions.value[act].cat in categories.value||(categories.value[actions.value[act].cat]={order:99,icon:`symbol_exclamation`,title:`UNDEFINED CATEGORY: `+actions.value[act].cat,desc:``,actions:[]}),categories.value[actions.value[act].cat].actions.push(obj)}for(let x in categoriesList.value=[],Object.entries(categories.value).forEach(([catName,cat])=>categoriesList.value.push({key:catName,...cat})),categoriesList.value)for(let y in categoriesList.value[x].actions)for(let z in categoriesList.value[x].actions[y].titleTranslated=$translate.instant(categoriesList.value[x].actions[y].title),categoriesList.value[x].actions[y].descTranslated=$translate.instant(categoriesList.value[x].actions[y].desc),categoriesList.value[x].actions[y].tags)categoriesList.value[x].actions[y].tagsTranslated||(categoriesList.value[x].actions[y].tagsTranslated=[]),categoriesList.value[x].actions[y].tagsTranslated[z]=$translate.instant(categoriesList.value[x].actions[y].tags[z]);_updateDeviceNotes()}function makeViewerObj({deviceKey,device,action,uiEvent,imagePack,controller=!1,actionVariants=!1,useLastDevice=!1}){let viewerObj,multiDevice=!1;if(device&&Array.isArray(device)&&device.length===0&&(device=void 0),Array.isArray(device)&&(device.length===0?device=void 0:device.length===1?device=device[0]:multiDevice=!0),!device&&controller&&(device=lastControllers.value,device.length===0?device=void 0:device.length===1?device=device[0]:multiDevice=!0),uiEvent&&(action=ACTIONS_BY_UI_EVENT[uiEvent]),action?actionVariants?(viewerObj=_buildViewerObjVariants(findAllBindingsForAction(action,device,!1,useLastDevice)),actionVariants=!!viewerObj?.variants,actionVariants&&viewerObj.variants.sort((a$1,b)=>a$1.isInverted-b.isInverted)):viewerObj=findBindingForAction(action,device,useLastDevice):actionVariants=!1,deviceKey){let devName=viewerObj?.devName||(multiDevice?device[0]:device);viewerObj={icon:deviceIcon(devName),control:deviceKey,devName,imagePack:viewerObj?.imagePack||imagePack}}return viewerObj&&(_parseViewerObj(viewerObj,imagePack,actionVariants),viewerObj.variants&&viewerObj.variants.forEach(obj=>_parseViewerObj(obj,imagePack,actionVariants,device))),viewerObj}function _buildViewerObjVariants(viewerObjs){let len=viewerObjs?.length||0;if(len!==0)return len===1?viewerObjs[0]:{...viewerObjs[0],variants:viewerObjs}}let rgxCombo=/modifier(?\d+)[ -]+|[ -]*(?.+)/gi;function _parseViewerObj(viewerObj,imagePack=void 0,actionVariants=!1,devNames=void 0){let devName=viewerObj.devName;if(imagePack=viewerObj.imagePack||imagePack,!imagePack){let binding=bindings.value?.find(b=>b.devname===devName);binding?.contents?.imagePack&&(imagePack=binding.contents.imagePack),!imagePack&&devName&&(imagePack=CONTROL_ICON_KEYS.find(key=>devName.startsWith(key))),viewerObj.imagePack=imagePack}if(viewerObj.control.startsWith(`modifier`)){let matches$1=[...viewerObj.control.matchAll(rgxCombo)].map(m=>m.groups);if(matches$1.length>0){viewerObj.multiControls=[];for(let match of matches$1)if(match.mod){let modName=`customModifier`+match.mod,mod=actionVariants?_buildViewerObjVariants(findAllBindingsForAction(modName,devName,!1,!1)):findBindingForAction(modName,devName);mod||=actionVariants?_buildViewerObjVariants(findAllBindingsForAction(modName,devNames,!1,!1)):findBindingForAction(modName,devNames),mod&&viewerObj.multiControls.push(mod)}else viewerObj.multiControls.push({devName,control:match.key,icon:viewerObj.icon,imagePack})}}_addCustomInfo(viewerObj),viewerObj.multiControls&&viewerObj.multiControls.forEach(_addCustomInfo)}function _addCustomInfo(viewerObj){let devOverrides=getViewerOverrides(viewerObj.devName,viewerObj.imagePack);viewerObj.family=devOverrides?.family;let ownIcon=devOverrides?.icons[viewerObj.control];viewerObj.special=!!ownIcon,viewerObj.ownGroups=devOverrides?.groups,viewerObj.special?viewerObj.ownIcon=ownIcon:viewerObj.control=controlLabel(viewerObj.control)}return connect(),_getBindingsData(),{categories:computed(()=>categories.value),categoriesList:computed(()=>categoriesList.value),controllers:computed(()=>controllers.value),players:computed(()=>players.value),bindingTemplate:computed(()=>bindingTemplate.value),lastDevice:lastDeviceSimple,lastDevices:lastDeviceOrder,lastControllers,lastControllersSignature,isControllerAvailable,isControllerUsed,showIfController:isControllerUsed,focusIfController:isControllerAvailable,addNewBinding,connect,deleteBinding,deleteBindings,disconnect,deviceIcon,findBindingForAction,findAllBindingsForAction,getActionDetails,getBindingDetails,getAllBindingsForAction,defaultBindingEntry,isAxis,bindingConflicts,captureBinding,removeBinding,addBinding,isFFBBound,isFFBEnabled,isFFBCapable,isGamepadAvailable:getIsControllerAvailable,isWheelFound,isPidVidFound,makeViewerObj,updateBinding}}),useStore=()=>store||=makeStore(),controls_default=useStore,direction=`right`,focusClass=`focus-visible`,isController$1={value:!1},now=()=>new Date().getTime(),inited=!1,gamepadInited=!1,elms$3=[];function setFocus(elm,enable=!0){if(enable){if(elm.classList.add(focusClass),elm===document.activeElement)return}else if(elm.classList.remove(focusClass),elm!==document.activeElement)return;try{enable&&focusOnElement(elm)}catch{}}function setFocusExternal(elm,enable=!0,attemptScroll=!0){return elm?(!gamepadInited&&gamepadInit(),enable&&!isController$1.value?(attemptScroll&&isOccluded(elm,!0)&&scrollFix({dom:elm,rect:elm.getBoundingClientRect()},`down`),!1):(setFocus(elm,enable),!0)):!1}function ensureFocus(elm,onNextTick=!0){elm&&(!gamepadInited&&gamepadInit(),isController$1.value&&document.activeElement===elm&&!elm.classList.contains(focusClass)&&(onNextTick?nextTick(()=>elm&&setFocus(elm)):setFocus(elm)))}function gamepadInit(){gamepadInited||(gamepadInited=!0,isController$1=storeToRefs(controls_default()).focusIfController)}function init$1(){inited||(inited=!0,gamepadInit(),watch(isController$1,val=>{let active=document.activeElement;if(isNavigable$1(active)){let focused$1=active.classList.contains(focusClass);val&&!focused$1?setFocus(active,!0):!val&&focused$1&&setFocus(active,!1);return}if(val){if(priorityFocus())return;navigate(collectRects(direction),direction)&&window.requestAnimationFrame(()=>setFocus(document.activeElement,!0))}}))}function priorityFocus(){collectRects(direction);for(let{elm}of elms$3)if(isNavigable$1(elm))return setFocus(elm,!0),!0;return!1}function wantsFocus(elm,priority){inited||init$1();let dat=elms$3.find(itm=>itm.element===elm)||{elm,time:now()},isNew=!(`priority`in dat);if(typeof priority!=`number`||isNaN(priority)){if(!isNew){let idx=elms$3.findIndex(itm=>itm.elm===elm);idx>-1&&elms$3.splice(idx,1)}return}dat.priority=priority,isNew&&elms$3.push(dat),elms$3.sort((a$1,b)=>b.priority-a$1.priority||b.time-a$1.time),collectRects(direction,elm.parentNode),isNew&&isController$1.value&&!isNavigable$1(document.activeElement)&&priorityFocus()}function unwantsFocus(elm){let idx=elms$3.findIndex(itm=>itm.elm===elm);idx!==-1&&(elms$3.splice(idx,1),isController$1.value&&!isNavigable$1(document.activeElement)&&priorityFocus())}function initFocusVisible(){let raf=window.requestAnimationFrame,curFocused=null,holdFocus=!1;function notify(type,target,relatedTarget){let evt=new CustomEvent(`uinav-`+type,{bubbles:!0,cancelable:!0,detail:{target,relatedTarget}});document.dispatchEvent(evt)}function procFocus(target,relatedTarget){if(!(target&&target===curFocused)&&(relatedTarget===target&&(relatedTarget=void 0),relatedTarget&&doBlur(relatedTarget),curFocused&&=((!relatedTarget||relatedTarget!==curFocused)&&(relatedTarget=curFocused),doBlur(curFocused),null),target))try{if(target.disabled)return;if(`tabIndex`in target){if(typeof target.tabIndex==`string`&&target.tabIndex===`-1`||typeof target.tabIndex==`number`&&target.tabIndex===-1||target.tabIndex===``)return}else if(`contentEditable`in target){if(typeof target.contentEditable==`string`&&target.contentEditable!==`true`||typeof target.contentEditable==`boolean`&&!target.contentEditable)return}else return;let style=window.getComputedStyle(target);if(style.display===`none`||style.visibility===`hidden`||style.pointerEvents===`none`)return;if(isController$1.value&&target.classList.add(focusClass),curFocused=target,focusRegistry.includes(target)||focusRegistry.push(target),document.activeElement!==curFocused){holdFocus=!0;let holdFocusCounter=0;raf(function check(){!curFocused||holdFocusCounter>10||document.activeElement===curFocused?(holdFocus=!1,!curFocused||target!==curFocused?doBlur(target):notify(`focus`,curFocused,relatedTarget)):(holdFocusCounter++,curFocused.focus(),raf(check))})}else notify(`focus`,target,relatedTarget)}catch{}}function doBlur(target){if(target&&!(holdFocus&&target===curFocused))try{target.classList.remove(focusClass),target===curFocused&&(curFocused=null);let idx=focusRegistry.indexOf(target);idx!==-1&&(focusRegistry.splice(idx,1),notify(`blur`,target))}catch{}}document.addEventListener(`focusin`,evt=>procFocus(evt.target,evt.relatedTarget),!0),document.addEventListener(`focusout`,evt=>doBlur(evt.target),!0);let focusRegistry=[],originalFocus=HTMLElement.prototype.focus.__original__||HTMLElement.prototype.focus,originalBlur=HTMLElement.prototype.blur.__original__||HTMLElement.prototype.blur;HTMLElement.prototype.focus=function(...args){let target=this,prevFocused=document.activeElement;prevFocused.classList.contains(focusClass)||(focusRegistry.length>0?focusRegistry.forEach(elm=>elm!==target&&elm.blur()):document.querySelectorAll(`.`+focusClass).forEach(elm=>elm!==target&&doBlur(elm))),originalFocus.apply(target,args),procFocus(target,prevFocused)},HTMLElement.prototype.blur=function(...args){doBlur(this),originalBlur.apply(this,args)},HTMLElement.prototype.focus.__original__=originalFocus,HTMLElement.prototype.blur.__original__=originalBlur}var EVENT_CALLS=Object.entries({focus:[`uinav-focus`,`focus`,`focusin`,`click`],hide:[`mouseenter`],show:[`uinav-blur`,`blur`,`focusout`,`mouseleave`]}).reduce((res,[name,events$3])=>(events$3.forEach(event=>res[event]=name),res),{}),ID$1=`__bngFocusCapture`,elms$2={},isController;function setupController(){isController||(isController=storeToRefs(controls_default()).isControllerUsed,watch(isController,val=>{for(let data of Object.values(elms$2))val?data.show():data.hide()}))}function getClosestNavigable(elm){let target=collectRects(`down`,elm).down[0]?.dom;return target&&isNavigable$1(target)?target:null}function update$3(data,value,firstTime=!1){if(typeof value==`function`?(data.handler=()=>{let elm=value(data.parent);return elm?.$el||elm},delete data.disabled):typeof value==`boolean`&&!value?data.disabled=!0:delete data.disabled,data.disabled){if(data.hide(),!firstTime)for(let event in data.capture.remove(),EVENT_CALLS)data.parent.removeEventListener(event,data[EVENT_CALLS[event]])}else for(let event in data.parent.appendChild(data.capture),data.show(),EVENT_CALLS)data.parent.addEventListener(event,data[EVENT_CALLS[event]])}var BngFocusCapture_default={mounted(elm,{arg,value}){setupController();let id=uniqueId(ID$1),parent=elm,capture=document.createElement(`div`),data={id,shown:!0,parent,capture,handler:()=>getClosestNavigable(data.parent)};elms$2[id]=data,parent[ID$1]=id,capture.className=`bng-focus-capture`,capture.style.setProperty(`position`,`absolute`,`important`),capture.style.setProperty(`display`,`block`,`important`),capture.style.setProperty(`top`,`0%`,`important`),capture.style.setProperty(`left`,`0%`,`important`),capture.style.setProperty(`width`,`100%`,`important`),capture.style.setProperty(`height`,`100%`,`important`),capture.style.setProperty(`z-index`,arg&&/^\d+$/.test(arg)?arg:`1000`,`important`),capture.style.setProperty(`pointer-events`,`all`,`important`),capture.setAttribute(`bng-nav-item`,``),capture.setAttribute(`tabindex`,`0`),data.focus=()=>{if(data.hide(),!isController.value)return;let active=document.activeElement;if(!(active!==data.capture&&data.parent.contains(active))&&data.handler){let elm$1=data.handler(data.parent);elm$1&&nextTick(()=>setFocusExternal(elm$1))}},data.hide=()=>{data.shown&&(data.shown=!1,capture.style.setProperty(`pointer-events`,`none`,`important`))},data.show=evt=>{if(data.shown||(data.shown=!0,data.disabled||!isController.value))return;let active=document.activeElement;if(data.parent.contains(active))return;let target=evt?.relatedTarget||evt?.target||active;data.parent.contains(target)||capture.style.setProperty(`pointer-events`,`all`,`important`)},update$3(data,value,!0)},updated(elm,{arg,value}){let id=elm[ID$1];if(!id)return;let data=elms$2[id];data&&update$3(data,value)},unmounted(elm){let id=elm[ID$1];if(!id)return;delete elm[ID$1];let data=elms$2[id];if(data){for(let event in data.capture.remove(),EVENT_CALLS)data.parent.removeEventListener(event,data[EVENT_CALLS[event]]);delete elms$2[id]}}},BngFocusIf_default=(el,{value})=>value&&nextTick(()=>{let shouldFocus=typeof value==`object`?value.value:value,findNavItem=typeof value==`object`?value.findNavItem:!1;if(!el||!shouldFocus)return;let targetEl=el;if(findNavItem){let navItems=el.querySelectorAll(`[is-bng-panel], [bng-nav-item], [ng-click], [href], [bng-all-clicks], [bng-all-clicks-no-nav], [ui-sref], input, textarea, button, md-option, md-slider, md-select, md-checkbox`);navItems&&navItems.length>0&&(targetEl=navItems[0])}targetEl.focus();let blur$1=()=>{targetEl.classList.remove(`focus-visible`),targetEl.removeEventListener(`blur`,blur$1)};targetEl.addEventListener(`blur`,blur$1),targetEl.classList.add(`focus-visible`)}),elems=new WeakMap,curHorizontal=0,curVertical=0;function updateGE(horizontal=0,vertical=0){curHorizontal=horizontal,curVertical=vertical,bngApi.engineLua(`scenetree.OnlyGui:setFrustumCameraCenterOffset(Point2F(${horizontal}, ${vertical}))`)}var moveSpeed=1,smoothingUpdate;function updateGEsmooth(horizontal=0,vertical=0){if(smoothingUpdate){smoothingUpdate(horizontal,vertical);return}let dirH=1,dirV=1;function setDir(){dirH=horizontal>=curHorizontal?1:-1,dirV=vertical>=curVertical?1:-1}setDir(),smoothingUpdate=(h$1=0,v=0)=>{horizontal=h$1,vertical=v,setDir()},window.requestAnimationFrame(function(ms){let speed=moveSpeed/1e3,movH=curHorizontal,movV=curVertical,lastTime=ms,smoother=0;window.requestAnimationFrame(function step(ms$1){if(curHorizontal===horizontal&&curVertical===vertical){smoothingUpdate=null;return}smoother+=(ms$1-lastTime-smoother)*.02,lastTime=ms$1;let moveDelta=smoother*speed;movH+=moveDelta*dirH,movV+=moveDelta*dirV,(dirH>0&&movH>horizontal||dirH<0&&movH0&&movV>vertical||dirV<0&&movV{let updateDebounce=debounce(updateFrustum,50),updateWrapper=()=>updateDebounce(),resizeObserver=new ResizeObserver(updateWrapper);resizeObserver.observe(el),elems.set(el,{updateFrustum:updateDebounce,destroy:()=>{resizeObserver.disconnect(),window.removeEventListener(`resize`,updateWrapper),elems.delete(el),updateDebounce(0,0)}}),window.addEventListener(`resize`,updateWrapper);let curDirection=binding.arg||`left`,curSmooth=binding.modifiers.smooth,curState=binding.value===void 0?!0:!!binding.value;function updateFrustum(direction$1,enabled,smooth){direction$1||=curDirection,[`left`,`right`,`up`,`down`].includes(direction$1)?curDirection=direction$1:(console.error(`Frustum mover only supports left/right/up/down directions`),enabled=!1),typeof enabled!=`boolean`&&(enabled=curState),curState=enabled,typeof smooth!=`boolean`&&(smooth=curSmooth),curSmooth=smooth;let updater=smooth?updateGEsmooth:updateGE;if(!enabled){updater();return}let side=direction$1===`left`||direction$1===`right`?`width`:`height`,screenSize=window.screen[side],movePower=el.getBoundingClientRect()[side]/screenSize*power;movePower<.001?movePower=0:(direction$1===`left`||direction$1===`down`)&&(movePower=-movePower),updater(direction$1===`left`||direction$1===`right`?movePower:0,direction$1===`up`||direction$1===`down`?movePower:0)}},updated:(el,binding)=>{let itm=elems.get(el);itm&&itm.updateFrustum(binding.arg,!!binding.value,!!binding.modifiers.smooth)},unmounted:(el,binding)=>{let itm=elems.get(el);itm&&itm.destroy()}},highlighter=[``,``],rgxSanitize=str=>str.replace(/[\\[]\?:.\*\+\-]/g,`\\$1`),BngHighlighter_default=(el,binding,vnode,prevVnode)=>{if(vnode.children.length!==1||vnode.children[0].type.toString()!==`Symbol(v-txt)`){el.__highlightwarned||(el.__highlightwarned=!0,console.warn(`Only a single inner text v-node supported`,el));return}let res=vnode.children[0].children.replace(//g,`>`),highlight=binding.value;if(highlight){let rgx;if(highlight instanceof RegExp)highlight.test(res)&&(rgx=highlight);else{let searchCase=str=>binding.modifiers.case?str:str.toLowerCase(),searchSource=searchCase(res),checkString=str=>searchSource.indexOf(str)>-1,buildRegexp=str=>RegExp(`(${str})`,`gm`+(binding.modifiers.case?``:`i`));if(typeof highlight==`object`&&Array.isArray(highlight)){let found=[];for(let str of highlight)str&&(str=searchCase(String(str)),checkString(str)&&found.push(str));found.length>0&&(rgx=buildRegexp(found.map(str=>rgxSanitize(str)).join(`|`)))}else{let str=searchCase(String(highlight));checkString(str)&&(rgx=buildRegexp(rgxSanitize(str)))}}rgx&&(res=res.replace(rgx,`${highlighter[0]}$1${highlighter[1]}`))}el.innerHTML!==res&&(el.innerHTML=res)},ExecQueue=class{resolution={rejectThis:`rejectThis`,rejectOthers:`rejectOthers`,resolveThis:`resolveThis`,resolveOthers:`resolveOthers`,replaceWithReject:`replaceWithReject`,replaceWithResolve:`replaceWithResolve`,merge:`merge`};_queue=[];_processing=!1;_tick=0;_tickFunc=nextTick;_runningCount=0;_concurrency=1;constructor(tick=0,concurrency=1){this.tick=tick,this.concurrency=concurrency}get tick(){return this._tick}set tick(val){typeof val!=`number`&&(val=0),this._tick=val,this._tickFunc=val===0?func=>nextTick(func.bind(this)):func=>setTimeout(func.bind(this),this._tick)}get concurrency(){return this._concurrency}set concurrency(val){(typeof val!=`number`||val<1)&&(val=1),this._concurrency=val}shuffle(){this._shuffle=!0}async process(){if(!(this._processing||this._queue.length===0))for(this._processing=!0,this._shuffle&&=(this._queue=this._queue.sort(()=>Math.random()-.5),!1);this._runningCount0;){let item=this._queue.shift();if(!item)break;item.running=!0,this._runningCount++,this._processItem(item)}}async _processItem(item){try{let result=await item.func(...item.args);item.resolves?.forEach(resolve$1=>resolve$1?.(result))}catch(err){item.rejects.length>0?item.rejects?.forEach(reject=>reject?.(err)):console.error(err)}finally{this._runningCount--,this._tickFunc(()=>{this._processing=!1,this.process()})}}enqueue(name,func,args=[],conflicts={},resolve$1=null,reject=null){if(typeof conflicts==`object`&&Object.keys(conflicts).length>0)for(let i=this._queue.length-1;i>=0;i--){let item=this._queue[i];if(item.name in conflicts)switch(conflicts[item.name]){case this.resolution.merge:resolve$1&&item.resolves.push(resolve$1),reject&&item.rejects.push(reject);return;default:case this.resolution.rejectThis:reject?.(Error(`Function ${item.name} is rejected due to conflict`));return;case this.resolution.resolveThis:resolve$1?.();return;case this.resolution.rejectOthers:item.running||(item.rejects?.forEach(reject$1=>reject$1?.(Error(`Function ${item.name} is rejected due to conflict`))),this._queue.splice(i,1));break;case this.resolution.resolveOthers:case this.resolution.replaceWithResolve:item.running||(item.resolves?.forEach(resolve$2=>resolve$2?.()),this._queue.splice(i,1));break;case this.resolution.replaceWithReject:item.rejects?.forEach(reject$1=>reject$1?.(Error(`Function ${item.name} is replaced`))),this._queue.splice(i,1);break}}this._queue.push({name,func,args,resolves:[resolve$1],rejects:[reject]}),this._processing||(this._processing=!0,this._tickFunc(()=>{this._processing=!1,this.process()}))}promise(name,func,args=[],conflicts={}){return new Promise((resolve$1,reject)=>this.enqueue(name,func,args,conflicts,resolve$1,reject))}wrap(name,func,conflicts={}){return async(...args)=>await this.promise(name,func,args,conflicts)}},MAX_SIZE=500,OVERSIZE_LIMIT=100,CONCURRENCY_LIMIT=20,QUEUE_INTERVAL$1=0,OBS_ID=`__bngLazyImage`,cache=new Map,queue=new ExecQueue(QUEUE_INTERVAL$1,CONCURRENCY_LIMIT),observer$1=new IntersectionObserver(entries=>{for(let entry of entries)if(entry.isIntersecting){observer$1.unobserve(entry.target);let data=entry.target[OBS_ID];data.observed&&(data.observed=!1,queue.shuffle(),process(entry.target,data))}}),loadImage=url=>new Promise((resolve$1,reject)=>{let img=new Image;img.onload=async()=>{try{if(cache.sizeMAX_SIZE||img.height>MAX_SIZE)){let ratio=img.width/img.height,width$1,height$1;img.width>img.height?(width$1=MAX_SIZE,height$1=MAX_SIZE/ratio):(height$1=MAX_SIZE,width$1=MAX_SIZE*ratio);let cvs=new OffscreenCanvas(width$1,height$1);cvs.getContext(`2d`).drawImage(img,0,0,width$1,height$1);let bmp=await createImageBitmap(cvs);cache.set(img.src,{url,bmp})}}catch(err){reject(err)}resolve$1({url})},img.onerror=()=>reject(Error(`Failed to load image`)),img.src=url});function process(el,data){let{url,callback}=data,apply$1=imgData=>callback(el,imgData.url,imgData.bmp);if(cache.has(url)){apply$1(cache.get(url));return}apply$1(emptyImage),queue.enqueue(url,loadImage,[url],{url:queue.resolution.merge},data$1=>{apply$1(data$1)},err=>{logger_default.error(err),apply$1(url)})}function update$2(el,{arg,value}){let data={url:void 0,target:`src`,callback:void 0};if(typeof value==`string`)data.url=value;else if(typeof value==`object`&&!Array.isArray(value)&&value.url){if(data.url=value.url,data.target=value.target,data.callback=typeof value.callback==`function`?value.callback:void 0,!data.url||!data.target&&!data.callback)return}else return;if(el[OBS_ID]){let old=el[OBS_ID];if(old.observed&&observer$1.unobserve(el),old.url===data.url&&old.target===data.target&&old.callback===data.callback)return}el[OBS_ID]=data,arg===`observe`?(data.observed=!0,observer$1.observe(el)):process(el,data)}var BngLazyImage_default={mounted:update$2,updated:update$2,unmounted(el){el[OBS_ID]&&(el[OBS_ID].observed&&observer$1.unobserve(el),delete el[OBS_ID])}},elms$1=new Map,observer=new ResizeObserver(observed$1);function observed$1(entries){for(let entry of entries)elms$1.has(entry.target)?update$1(entry.target):observer.unobserve(entry.target)}function update$1(elm,data=void 0){if(data||=elms$1.get(elm),data)if(isVisibleFast(elm)){let screen$1={width:window.innerWidth,height:window.innerHeight,scrollX:window.scrollX,scrollY:window.scrollY},rect=elm.getBoundingClientRect(),metrics={x:rect.left+screen$1.scrollX,y:rect.top+screen$1.scrollY,width:rect.width,height:rect.height};data.set(data.id,metrics.x/screen$1.width,metrics.y/screen$1.height,metrics.width/screen$1.width,metrics.height/screen$1.height)}else data.reset(data.id)}var UINAV_PROP=`__BngOnUiNav`,_handlerToElement=handler$1=>{let element;switch(typeof handler$1){case`string`:element=document.querySelectorAll(handler$1)[0];break;case`object`:element=handler$1;break}return element instanceof HTMLElement&&element},_generateSignature=(vnode,eventNames,modifiers)=>`${UINAV_PROP}[${vnode.ctx.uid}]:`+(typeof eventNames==`string`?eventNames.split(`,`):eventNames).sort().join(`,`)+[``,...Object.keys(modifiers)].sort().join(`.`),_normalizedEvents=eventNames=>eventNames===`*`?[]:eventNames.split(`,`),_getDirData=(element,signature)=>element[UINAV_PROP]?.find(dir=>dir.signature===signature);function setup$2(data,element,vnode){if(data.modifiers.asMouse){if(data.eventNames.find(name=>!isOnOffEvent(name))){window.BNG_Logger&&window.BNG_Logger.error(`UINav directive asMouse modifier is only supported for on/off type events`,element);return}setupAsMouse(data,vnode)}typeof data.handler==`function`&&(applyUiNav(data,element),applyTracker(data,element))}function setupAsMouse(data,vnode){let handlerElement=_handlerToElement(data.handler);handlerElement&&(vnode={el:handlerElement});let eventFirer$1=vnode.ctx?.exposed?.fireEvent||eventDispatcherForElement(vnode.el),checkElementDisabled=vnode.ctx?.exposed?.getDisabledState||(()=>vnode.el.hasAttribute(`disabled`));delete data.modifiers.down,delete data.modifiers.up,data.mousedownActive=!1,data.handler=({detail})=>{if(checkElementDisabled())return;let fromControllerMarker={fromController:detail};return detail.value?(eventFirer$1(`mousedown`,fromControllerMarker),data.mousedownActive=!0):(eventFirer$1(`mouseup`,fromControllerMarker),data.mousedownActive&&(data.mousedownActive=!1,eventFirer$1(`click`,fromControllerMarker))),!!data.modifiers.bubble}}function applyTracker(data,element){let uiNavTracker=useUINavTracker();data.modifiers.focusRequired?(element.addEventListener(`focusin`,evt=>{let prevDirs=evt.relatedTarget?.[UINAV_PROP];if(prevDirs)for(let dir of prevDirs)dir.modifiers.focusRequired&&(dir.tracked.forEach(name=>uiNavTracker.removeEvent(name,dir.signature,evt.relatedTarget)),dir.tracked=[]);let cur=_getDirData(element,data.signature);cur&&(cur.tracked.lengthuiNavTracker.updateEvent(name,cur.signature,element,{active:cur.modifiers.active,nogroup:cur.modifiers.nogroup})),cur.tracked=[...cur.eventNames]))}),element.addEventListener(`focusout`,evt=>{let cur=_getDirData(element,data.signature);if(!cur||cur.tracked.length>0)return;let nextDirs=evt.relatedTarget?.[UINAV_PROP];(!nextDirs||!nextDirs.some(directive=>directive.modifiers.focusRequired))&&(cur.tracked.forEach(name=>uiNavTracker.removeEvent(name,cur.signature,element)),cur.tracked=[])})):(data.eventNames.forEach(name=>uiNavTracker.updateEvent(name,data.signature,element,{active:data.modifiers.active,nogroup:data.modifiers.nogroup})),data.tracked=[...data.eventNames])}function applyUiNav(data,element){let valueChecker;data.modifiers.down?valueChecker=checkOn:data.modifiers.up?valueChecker=0:!data.modifiers.asMouse&&!data.eventNames.find(name=>!isOnOffEvent(name))&&(valueChecker=checkOn),data.uiNavHandler=handlers_default.add(element,{name:name=>data.eventNames.includes(name),value:valueChecker,modified:data.modifiers.modified||!1,focusRequired:data.modifiers.focusRequired?element:void 0},data.handler),element.setAttribute(UI_EVENT_ATTR,``)}function mounted$1(element,{arg:eventNames,value:handler$1,modifiers},vnode){modifiers||={};let storage=element[UINAV_PROP]||(element[UINAV_PROP]=[]),signature=_generateSignature(vnode,eventNames,modifiers),data=storage.find(dir=>dir.signature===signature);data?window.BNG_Logger&&window.BNG_Logger.error(`Conflicting vBngOnUiNav directive on element`,element):(data={signature,eventNames:_normalizedEvents(eventNames),modifiers,handler:handler$1,uiNavHandler:null,mousedownActive:!1,tracked:[]},storage.push(data)),setup$2(data,element,vnode)}function updated$1(element,{arg:eventNames,value:handler$1,modifiers},vnode){modifiers||={};let data=_getDirData(element,_generateSignature(vnode,eventNames,modifiers));if(!data)return;typeof data.uiNavHandler==`function`&&handlers_default.remove(element,data.uiNavHandler);let normalizedEvents=_normalizedEvents(eventNames),oldEvents=data.tracked.filter(name=>!normalizedEvents.includes(name));if(oldEvents.length>0){let uiNavTracker=useUINavTracker();oldEvents.forEach(name=>uiNavTracker.removeEvent(name,data.signature,element)),data.tracked=data.tracked.filter(name=>normalizedEvents.includes(name))}data.eventNames=normalizedEvents,data.modifiers=modifiers,data.handler=handler$1,data.uiNavHandler=null,setup$2(data,element,vnode)}function dispose$1(element){let storage=element[UINAV_PROP];if(!storage)return;let uiNavTracker=useUINavTracker();storage.forEach(directive=>{directive.tracked.length>0&&directive.tracked.forEach(name=>uiNavTracker.removeEvent(name,directive.signature,element)),directive.uiNavHandler&&handlers_default.remove(element,directive.uiNavHandler)}),element.removeAttribute(UI_EVENT_ATTR),delete element[UINAV_PROP]}var BngOnUiNav_default={mounted:mounted$1,updated:updated$1,beforeUnmount:dispose$1},DIRECTIONS={horizontal:{[UI_EVENTS.focus_l]:-1,[UI_EVENTS.focus_r]:1},vertical:{[UI_EVENTS.focus_d]:-1,[UI_EVENTS.focus_u]:1}},HOLD_DELAY=400,REPEAT_INTERVAL=100,ELEMENT_FLAG=`__BNG_ONUINAVFOCUS`,BngOnUiNavFocus_default={mounted:(element,binding,vnode)=>{if(!binding.value)return;let opts={direction:binding.arg||`horizontal`,repeat:!!binding.modifiers.repeat,holdDelay:HOLD_DELAY,repeatInterval:REPEAT_INTERVAL,min:-1/0,max:1/0,step:1,value:null,callback:null,...typeof binding.value==`object`?binding.value:typeof binding.value==`function`?{callback:binding.value}:{}};!opts.events&&(opts.events=DIRECTIONS[opts.direction]);function process$1(evt){let detail=evt.fromController||evt.detail;if(!detail||!(detail.name in opts.events))return;let dir=opts.events[detail.name],val;if(typeof opts.value==`function`){let cur=opts.value(),res=cur+(typeof opts.step==`function`?opts.step():opts.step)*dir;dir<0&&res0&&res>opts.max&&(res=opts.max);let precision=10**(opts.step+`.`).split(/[.,]/)[1].length;res=precision>0?Math.round(res*precision)/precision:Math.round(res),cur===res?dir=0:val=res}dir&&opts.callback&&opts.callback(dir,val)}let dirUINav={arg:Object.keys(opts.events).join(`,`),modifiers:{focusRequired:!0,asMouse:!0}},dirClick={value:{clickCallback:process$1,holdCallback:opts.repeat?process$1:void 0,holdDelay:HOLD_DELAY,repeatInterval:REPEAT_INTERVAL}};BngOnUiNav_default.mounted(element,dirUINav,vnode),BngClick_default.mounted(element,dirClick,vnode),element[ELEMENT_FLAG]=!0},beforeUnmount:element=>{element[ELEMENT_FLAG]&&(BngClick_default.beforeUnmount(element),BngOnUiNav_default.beforeUnmount(element))}},DEFAULT_OPTS={intiallyOpen:!1,navEventToOpen:UI_EVENTS.ok,navEventToClose:UI_EVENTS.back},min=Math.min,max=Math.max,round$1=Math.round,floor=Math.floor,createCoords=v=>({x:v,y:v}),oppositeSideMap={left:`right`,right:`left`,bottom:`top`,top:`bottom`},oppositeAlignmentMap={start:`end`,end:`start`};function clamp$1(start,value,end){return max(start,min(value,end))}function evaluate(value,param){return typeof value==`function`?value(param):value}function getSide(placement){return placement.split(`-`)[0]}function getAlignment(placement){return placement.split(`-`)[1]}function getOppositeAxis(axis){return axis===`x`?`y`:`x`}function getAxisLength(axis){return axis===`y`?`height`:`width`}var yAxisSides=new Set([`top`,`bottom`]);function getSideAxis(placement){return yAxisSides.has(getSide(placement))?`y`:`x`}function getAlignmentAxis(placement){return getOppositeAxis(getSideAxis(placement))}function getAlignmentSides(placement,rects,rtl){rtl===void 0&&(rtl=!1);let alignment=getAlignment(placement),alignmentAxis=getAlignmentAxis(placement),length=getAxisLength(alignmentAxis),mainAlignmentSide=alignmentAxis===`x`?alignment===(rtl?`end`:`start`)?`right`:`left`:alignment===`start`?`bottom`:`top`;return rects.reference[length]>rects.floating[length]&&(mainAlignmentSide=getOppositePlacement(mainAlignmentSide)),[mainAlignmentSide,getOppositePlacement(mainAlignmentSide)]}function getExpandedPlacements(placement){let oppositePlacement=getOppositePlacement(placement);return[getOppositeAlignmentPlacement(placement),oppositePlacement,getOppositeAlignmentPlacement(oppositePlacement)]}function getOppositeAlignmentPlacement(placement){return placement.replace(/start|end/g,alignment=>oppositeAlignmentMap[alignment])}var lrPlacement=[`left`,`right`],rlPlacement=[`right`,`left`],tbPlacement=[`top`,`bottom`],btPlacement=[`bottom`,`top`];function getSideList(side,isStart,rtl){switch(side){case`top`:case`bottom`:return rtl?isStart?rlPlacement:lrPlacement:isStart?lrPlacement:rlPlacement;case`left`:case`right`:return isStart?tbPlacement:btPlacement;default:return[]}}function getOppositeAxisPlacements(placement,flipAlignment,direction$1,rtl){let alignment=getAlignment(placement),list=getSideList(getSide(placement),direction$1===`start`,rtl);return alignment&&(list=list.map(side=>side+`-`+alignment),flipAlignment&&(list=list.concat(list.map(getOppositeAlignmentPlacement)))),list}function getOppositePlacement(placement){return placement.replace(/left|right|bottom|top/g,side=>oppositeSideMap[side])}function expandPaddingObject(padding){return{top:0,right:0,bottom:0,left:0,...padding}}function getPaddingObject(padding){return typeof padding==`number`?{top:padding,right:padding,bottom:padding,left:padding}:expandPaddingObject(padding)}function rectToClientRect(rect){let{x,y,width:width$1,height:height$1}=rect;return{width:width$1,height:height$1,top:y,left:x,right:x+width$1,bottom:y+height$1,x,y}}function computeCoordsFromPlacement(_ref,placement,rtl){let{reference,floating}=_ref,sideAxis=getSideAxis(placement),alignmentAxis=getAlignmentAxis(placement),alignLength=getAxisLength(alignmentAxis),side=getSide(placement),isVertical=sideAxis===`y`,commonX=reference.x+reference.width/2-floating.width/2,commonY=reference.y+reference.height/2-floating.height/2,commonAlign=reference[alignLength]/2-floating[alignLength]/2,coords;switch(side){case`top`:coords={x:commonX,y:reference.y-floating.height};break;case`bottom`:coords={x:commonX,y:reference.y+reference.height};break;case`right`:coords={x:reference.x+reference.width,y:commonY};break;case`left`:coords={x:reference.x-floating.width,y:commonY};break;default:coords={x:reference.x,y:reference.y}}switch(getAlignment(placement)){case`start`:coords[alignmentAxis]-=commonAlign*(rtl&&isVertical?-1:1);break;case`end`:coords[alignmentAxis]+=commonAlign*(rtl&&isVertical?-1:1);break}return coords}var computePosition$1=async(reference,floating,config)=>{let{placement=`bottom`,strategy=`absolute`,middleware=[],platform:platform$1}=config,validMiddleware=middleware.filter(Boolean),rtl=await(platform$1.isRTL==null?void 0:platform$1.isRTL(floating)),rects=await platform$1.getElementRects({reference,floating,strategy}),{x,y}=computeCoordsFromPlacement(rects,placement,rtl),statefulPlacement=placement,middlewareData={},resetCount=0;for(let i=0;i({name:`arrow`,options,async fn(state){let{x,y,placement,rects,platform:platform$1,elements,middlewareData}=state,{element,padding=0}=evaluate(options,state)||{};if(element==null)return{};let paddingObject=getPaddingObject(padding),coords={x,y},axis=getAlignmentAxis(placement),length=getAxisLength(axis),arrowDimensions=await platform$1.getDimensions(element),isYAxis=axis===`y`,minProp=isYAxis?`top`:`left`,maxProp=isYAxis?`bottom`:`right`,clientProp=isYAxis?`clientHeight`:`clientWidth`,endDiff=rects.reference[length]+rects.reference[axis]-coords[axis]-rects.floating[length],startDiff=coords[axis]-rects.reference[axis],arrowOffsetParent=await(platform$1.getOffsetParent==null?void 0:platform$1.getOffsetParent(element)),clientSize=arrowOffsetParent?arrowOffsetParent[clientProp]:0;(!clientSize||!await(platform$1.isElement==null?void 0:platform$1.isElement(arrowOffsetParent)))&&(clientSize=elements.floating[clientProp]||rects.floating[length]);let centerToReference=endDiff/2-startDiff/2,largestPossiblePadding=clientSize/2-arrowDimensions[length]/2-1,minPadding=min(paddingObject[minProp],largestPossiblePadding),maxPadding=min(paddingObject[maxProp],largestPossiblePadding),min$1=minPadding,max$1=clientSize-arrowDimensions[length]-maxPadding,center=clientSize/2-arrowDimensions[length]/2+centerToReference,offset$2=clamp$1(min$1,center,max$1),shouldAddOffset=!middlewareData.arrow&&getAlignment(placement)!=null&¢er!==offset$2&&rects.reference[length]/2-(centerside$1<=0)){var _middlewareData$flip2,_overflowsData$filter;let nextIndex=(middlewareData.flip?.index||0)+1,nextPlacement=placements$1[nextIndex];if(nextPlacement&&(!(checkCrossAxis===`alignment`&&initialSideAxis!==getSideAxis(nextPlacement))||overflowsData.every(d=>getSideAxis(d.placement)===initialSideAxis?d.overflows[0]>0:!0)))return{data:{index:nextIndex,overflows:overflowsData},reset:{placement:nextPlacement}};let resetPlacement=overflowsData.filter(d=>d.overflows[0]<=0).sort((a$1,b)=>a$1.overflows[1]-b.overflows[1])[0]?.placement;if(!resetPlacement)switch(fallbackStrategy){case`bestFit`:{var _overflowsData$filter2;let placement$1=overflowsData.filter(d=>{if(hasFallbackAxisSideDirection){let currentSideAxis=getSideAxis(d.placement);return currentSideAxis===initialSideAxis||currentSideAxis===`y`}return!0}).map(d=>[d.placement,d.overflows.filter(overflow$1=>overflow$1>0).reduce((acc,overflow$1)=>acc+overflow$1,0)]).sort((a$1,b)=>a$1[1]-b[1])[0]?.[0];placement$1&&(resetPlacement=placement$1);break}case`initialPlacement`:resetPlacement=initialPlacement;break}if(placement!==resetPlacement)return{reset:{placement:resetPlacement}}}return{}}}},originSides=new Set([`left`,`top`]);async function convertValueToCoords(state,options){let{placement,platform:platform$1,elements}=state,rtl=await(platform$1.isRTL==null?void 0:platform$1.isRTL(elements.floating)),side=getSide(placement),alignment=getAlignment(placement),isVertical=getSideAxis(placement)===`y`,mainAxisMulti=originSides.has(side)?-1:1,crossAxisMulti=rtl&&isVertical?-1:1,rawValue=evaluate(options,state),{mainAxis,crossAxis,alignmentAxis}=typeof rawValue==`number`?{mainAxis:rawValue,crossAxis:0,alignmentAxis:null}:{mainAxis:rawValue.mainAxis||0,crossAxis:rawValue.crossAxis||0,alignmentAxis:rawValue.alignmentAxis};return alignment&&typeof alignmentAxis==`number`&&(crossAxis=alignment===`end`?alignmentAxis*-1:alignmentAxis),isVertical?{x:crossAxis*crossAxisMulti,y:mainAxis*mainAxisMulti}:{x:mainAxis*mainAxisMulti,y:crossAxis*crossAxisMulti}}var offset$1=function(options){return options===void 0&&(options=0),{name:`offset`,options,async fn(state){var _middlewareData$offse,_middlewareData$arrow;let{x,y,placement,middlewareData}=state,diffCoords=await convertValueToCoords(state,options);return placement===middlewareData.offset?.placement&&(_middlewareData$arrow=middlewareData.arrow)!=null&&_middlewareData$arrow.alignmentOffset?{}:{x:x+diffCoords.x,y:y+diffCoords.y,data:{...diffCoords,placement}}}}},shift$1=function(options){return options===void 0&&(options={}),{name:`shift`,options,async fn(state){let{x,y,placement}=state,{mainAxis:checkMainAxis=!0,crossAxis:checkCrossAxis=!1,limiter={fn:_ref=>{let{x:x$1,y:y$1}=_ref;return{x:x$1,y:y$1}}},...detectOverflowOptions}=evaluate(options,state),coords={x,y},overflow=await detectOverflow$1(state,detectOverflowOptions),crossAxis=getSideAxis(getSide(placement)),mainAxis=getOppositeAxis(crossAxis),mainAxisCoord=coords[mainAxis],crossAxisCoord=coords[crossAxis];if(checkMainAxis){let minSide=mainAxis===`y`?`top`:`left`,maxSide=mainAxis===`y`?`bottom`:`right`,min$1=mainAxisCoord+overflow[minSide],max$1=mainAxisCoord-overflow[maxSide];mainAxisCoord=clamp$1(min$1,mainAxisCoord,max$1)}if(checkCrossAxis){let minSide=crossAxis===`y`?`top`:`left`,maxSide=crossAxis===`y`?`bottom`:`right`,min$1=crossAxisCoord+overflow[minSide],max$1=crossAxisCoord-overflow[maxSide];crossAxisCoord=clamp$1(min$1,crossAxisCoord,max$1)}let limitedCoords=limiter.fn({...state,[mainAxis]:mainAxisCoord,[crossAxis]:crossAxisCoord});return{...limitedCoords,data:{x:limitedCoords.x-x,y:limitedCoords.y-y,enabled:{[mainAxis]:checkMainAxis,[crossAxis]:checkCrossAxis}}}}}};function hasWindow(){return typeof window<`u`}function getNodeName(node){return isNode(node)?(node.nodeName||``).toLowerCase():`#document`}function getWindow(node){var _node$ownerDocument;return(node==null||(_node$ownerDocument=node.ownerDocument)==null?void 0:_node$ownerDocument.defaultView)||window}function getDocumentElement(node){var _ref;return((isNode(node)?node.ownerDocument:node.document)||window.document)?.documentElement}function isNode(value){return hasWindow()?value instanceof Node||value instanceof getWindow(value).Node:!1}function isElement(value){return hasWindow()?value instanceof Element||value instanceof getWindow(value).Element:!1}function isHTMLElement(value){return hasWindow()?value instanceof HTMLElement||value instanceof getWindow(value).HTMLElement:!1}function isShadowRoot(value){return!hasWindow()||typeof ShadowRoot>`u`?!1:value instanceof ShadowRoot||value instanceof getWindow(value).ShadowRoot}var invalidOverflowDisplayValues=new Set([`inline`,`contents`]);function isOverflowElement(element){let{overflow,overflowX,overflowY,display}=getComputedStyle$1(element);return/auto|scroll|overlay|hidden|clip/.test(overflow+overflowY+overflowX)&&!invalidOverflowDisplayValues.has(display)}var tableElements=new Set([`table`,`td`,`th`]);function isTableElement(element){return tableElements.has(getNodeName(element))}var topLayerSelectors=[`:popover-open`,`:modal`];function isTopLayer(element){return topLayerSelectors.some(selector=>{try{return element.matches(selector)}catch{return!1}})}var transformProperties=[`transform`,`translate`,`scale`,`rotate`,`perspective`],willChangeValues=[`transform`,`translate`,`scale`,`rotate`,`perspective`,`filter`],containValues=[`paint`,`layout`,`strict`,`content`];function isContainingBlock(elementOrCss){let webkit=isWebKit(),css=isElement(elementOrCss)?getComputedStyle$1(elementOrCss):elementOrCss;return transformProperties.some(value=>css[value]?css[value]!==`none`:!1)||(css.containerType?css.containerType!==`normal`:!1)||!webkit&&(css.backdropFilter?css.backdropFilter!==`none`:!1)||!webkit&&(css.filter?css.filter!==`none`:!1)||willChangeValues.some(value=>(css.willChange||``).includes(value))||containValues.some(value=>(css.contain||``).includes(value))}function getContainingBlock(element){let currentNode=getParentNode(element);for(;isHTMLElement(currentNode)&&!isLastTraversableNode(currentNode);){if(isContainingBlock(currentNode))return currentNode;if(isTopLayer(currentNode))return null;currentNode=getParentNode(currentNode)}return null}function isWebKit(){return typeof CSS>`u`||!CSS.supports?!1:CSS.supports(`-webkit-backdrop-filter`,`none`)}var lastTraversableNodeNames=new Set([`html`,`body`,`#document`]);function isLastTraversableNode(node){return lastTraversableNodeNames.has(getNodeName(node))}function getComputedStyle$1(element){return getWindow(element).getComputedStyle(element)}function getNodeScroll(element){return isElement(element)?{scrollLeft:element.scrollLeft,scrollTop:element.scrollTop}:{scrollLeft:element.scrollX,scrollTop:element.scrollY}}function getParentNode(node){if(getNodeName(node)===`html`)return node;let result=node.assignedSlot||node.parentNode||isShadowRoot(node)&&node.host||getDocumentElement(node);return isShadowRoot(result)?result.host:result}function getNearestOverflowAncestor(node){let parentNode=getParentNode(node);return isLastTraversableNode(parentNode)?node.ownerDocument?node.ownerDocument.body:node.body:isHTMLElement(parentNode)&&isOverflowElement(parentNode)?parentNode:getNearestOverflowAncestor(parentNode)}function getOverflowAncestors(node,list,traverseIframes){var _node$ownerDocument2;list===void 0&&(list=[]),traverseIframes===void 0&&(traverseIframes=!0);let scrollableAncestor=getNearestOverflowAncestor(node),isBody=scrollableAncestor===node.ownerDocument?.body,win=getWindow(scrollableAncestor);if(isBody){let frameElement=getFrameElement(win);return list.concat(win,win.visualViewport||[],isOverflowElement(scrollableAncestor)?scrollableAncestor:[],frameElement&&traverseIframes?getOverflowAncestors(frameElement):[])}return list.concat(scrollableAncestor,getOverflowAncestors(scrollableAncestor,[],traverseIframes))}function getFrameElement(win){return win.parent&&Object.getPrototypeOf(win.parent)?win.frameElement:null}function getCssDimensions(element){let css=getComputedStyle$1(element),width$1=parseFloat(css.width)||0,height$1=parseFloat(css.height)||0,hasOffset=isHTMLElement(element),offsetWidth=hasOffset?element.offsetWidth:width$1,offsetHeight=hasOffset?element.offsetHeight:height$1,shouldFallback=round$1(width$1)!==offsetWidth||round$1(height$1)!==offsetHeight;return shouldFallback&&(width$1=offsetWidth,height$1=offsetHeight),{width:width$1,height:height$1,$:shouldFallback}}function unwrapElement$1(element){return isElement(element)?element:element.contextElement}function getScale(element){let domElement=unwrapElement$1(element);if(!isHTMLElement(domElement))return createCoords(1);let rect=domElement.getBoundingClientRect(),{width:width$1,height:height$1,$}=getCssDimensions(domElement),x=($?round$1(rect.width):rect.width)/width$1,y=($?round$1(rect.height):rect.height)/height$1;return(!x||!Number.isFinite(x))&&(x=1),(!y||!Number.isFinite(y))&&(y=1),{x,y}}var noOffsets=createCoords(0);function getVisualOffsets(element){let win=getWindow(element);return!isWebKit()||!win.visualViewport?noOffsets:{x:win.visualViewport.offsetLeft,y:win.visualViewport.offsetTop}}function shouldAddVisualOffsets(element,isFixed,floatingOffsetParent){return isFixed===void 0&&(isFixed=!1),!floatingOffsetParent||isFixed&&floatingOffsetParent!==getWindow(element)?!1:isFixed}function getBoundingClientRect(element,includeScale,isFixedStrategy,offsetParent){includeScale===void 0&&(includeScale=!1),isFixedStrategy===void 0&&(isFixedStrategy=!1);let clientRect=element.getBoundingClientRect(),domElement=unwrapElement$1(element),scale=createCoords(1);includeScale&&(offsetParent?isElement(offsetParent)&&(scale=getScale(offsetParent)):scale=getScale(element));let visualOffsets=shouldAddVisualOffsets(domElement,isFixedStrategy,offsetParent)?getVisualOffsets(domElement):createCoords(0),x=(clientRect.left+visualOffsets.x)/scale.x,y=(clientRect.top+visualOffsets.y)/scale.y,width$1=clientRect.width/scale.x,height$1=clientRect.height/scale.y;if(domElement){let win=getWindow(domElement),offsetWin=offsetParent&&isElement(offsetParent)?getWindow(offsetParent):offsetParent,currentWin=win,currentIFrame=getFrameElement(currentWin);for(;currentIFrame&&offsetParent&&offsetWin!==currentWin;){let iframeScale=getScale(currentIFrame),iframeRect=currentIFrame.getBoundingClientRect(),css=getComputedStyle$1(currentIFrame),left=iframeRect.left+(currentIFrame.clientLeft+parseFloat(css.paddingLeft))*iframeScale.x,top=iframeRect.top+(currentIFrame.clientTop+parseFloat(css.paddingTop))*iframeScale.y;x*=iframeScale.x,y*=iframeScale.y,width$1*=iframeScale.x,height$1*=iframeScale.y,x+=left,y+=top,currentWin=getWindow(currentIFrame),currentIFrame=getFrameElement(currentWin)}}return rectToClientRect({width:width$1,height:height$1,x,y})}function getWindowScrollBarX(element,rect){let leftScroll=getNodeScroll(element).scrollLeft;return rect?rect.left+leftScroll:getBoundingClientRect(getDocumentElement(element)).left+leftScroll}function getHTMLOffset(documentElement,scroll$1){let htmlRect=documentElement.getBoundingClientRect();return{x:htmlRect.left+scroll$1.scrollLeft-getWindowScrollBarX(documentElement,htmlRect),y:htmlRect.top+scroll$1.scrollTop}}function convertOffsetParentRelativeRectToViewportRelativeRect(_ref){let{elements,rect,offsetParent,strategy}=_ref,isFixed=strategy===`fixed`,documentElement=getDocumentElement(offsetParent),topLayer=elements?isTopLayer(elements.floating):!1;if(offsetParent===documentElement||topLayer&&isFixed)return rect;let scroll$1={scrollLeft:0,scrollTop:0},scale=createCoords(1),offsets=createCoords(0),isOffsetParentAnElement=isHTMLElement(offsetParent);if((isOffsetParentAnElement||!isOffsetParentAnElement&&!isFixed)&&((getNodeName(offsetParent)!==`body`||isOverflowElement(documentElement))&&(scroll$1=getNodeScroll(offsetParent)),isHTMLElement(offsetParent))){let offsetRect=getBoundingClientRect(offsetParent);scale=getScale(offsetParent),offsets.x=offsetRect.x+offsetParent.clientLeft,offsets.y=offsetRect.y+offsetParent.clientTop}let htmlOffset=documentElement&&!isOffsetParentAnElement&&!isFixed?getHTMLOffset(documentElement,scroll$1):createCoords(0);return{width:rect.width*scale.x,height:rect.height*scale.y,x:rect.x*scale.x-scroll$1.scrollLeft*scale.x+offsets.x+htmlOffset.x,y:rect.y*scale.y-scroll$1.scrollTop*scale.y+offsets.y+htmlOffset.y}}function getClientRects(element){return Array.from(element.getClientRects())}function getDocumentRect(element){let html=getDocumentElement(element),scroll$1=getNodeScroll(element),body=element.ownerDocument.body,width$1=max(html.scrollWidth,html.clientWidth,body.scrollWidth,body.clientWidth),height$1=max(html.scrollHeight,html.clientHeight,body.scrollHeight,body.clientHeight),x=-scroll$1.scrollLeft+getWindowScrollBarX(element),y=-scroll$1.scrollTop;return getComputedStyle$1(body).direction===`rtl`&&(x+=max(html.clientWidth,body.clientWidth)-width$1),{width:width$1,height:height$1,x,y}}var SCROLLBAR_MAX=25;function getViewportRect(element,strategy){let win=getWindow(element),html=getDocumentElement(element),visualViewport=win.visualViewport,width$1=html.clientWidth,height$1=html.clientHeight,x=0,y=0;if(visualViewport){width$1=visualViewport.width,height$1=visualViewport.height;let visualViewportBased=isWebKit();(!visualViewportBased||visualViewportBased&&strategy===`fixed`)&&(x=visualViewport.offsetLeft,y=visualViewport.offsetTop)}let windowScrollbarX=getWindowScrollBarX(html);if(windowScrollbarX<=0){let doc$1=html.ownerDocument,body=doc$1.body,bodyStyles=getComputedStyle(body),bodyMarginInline=doc$1.compatMode===`CSS1Compat`&&parseFloat(bodyStyles.marginLeft)+parseFloat(bodyStyles.marginRight)||0,clippingStableScrollbarWidth=Math.abs(html.clientWidth-body.clientWidth-bodyMarginInline);clippingStableScrollbarWidth<=SCROLLBAR_MAX&&(width$1-=clippingStableScrollbarWidth)}else windowScrollbarX<=SCROLLBAR_MAX&&(width$1+=windowScrollbarX);return{width:width$1,height:height$1,x,y}}var absoluteOrFixed=new Set([`absolute`,`fixed`]);function getInnerBoundingClientRect(element,strategy){let clientRect=getBoundingClientRect(element,!0,strategy===`fixed`),top=clientRect.top+element.clientTop,left=clientRect.left+element.clientLeft,scale=isHTMLElement(element)?getScale(element):createCoords(1);return{width:element.clientWidth*scale.x,height:element.clientHeight*scale.y,x:left*scale.x,y:top*scale.y}}function getClientRectFromClippingAncestor(element,clippingAncestor,strategy){let rect;if(clippingAncestor===`viewport`)rect=getViewportRect(element,strategy);else if(clippingAncestor===`document`)rect=getDocumentRect(getDocumentElement(element));else if(isElement(clippingAncestor))rect=getInnerBoundingClientRect(clippingAncestor,strategy);else{let visualOffsets=getVisualOffsets(element);rect={x:clippingAncestor.x-visualOffsets.x,y:clippingAncestor.y-visualOffsets.y,width:clippingAncestor.width,height:clippingAncestor.height}}return rectToClientRect(rect)}function hasFixedPositionAncestor(element,stopNode){let parentNode=getParentNode(element);return parentNode===stopNode||!isElement(parentNode)||isLastTraversableNode(parentNode)?!1:getComputedStyle$1(parentNode).position===`fixed`||hasFixedPositionAncestor(parentNode,stopNode)}function getClippingElementAncestors(element,cache$1){let cachedResult=cache$1.get(element);if(cachedResult)return cachedResult;let result=getOverflowAncestors(element,[],!1).filter(el=>isElement(el)&&getNodeName(el)!==`body`),currentContainingBlockComputedStyle=null,elementIsFixed=getComputedStyle$1(element).position===`fixed`,currentNode=elementIsFixed?getParentNode(element):element;for(;isElement(currentNode)&&!isLastTraversableNode(currentNode);){let computedStyle=getComputedStyle$1(currentNode),currentNodeIsContaining=isContainingBlock(currentNode);!currentNodeIsContaining&&computedStyle.position===`fixed`&&(currentContainingBlockComputedStyle=null),(elementIsFixed?!currentNodeIsContaining&&!currentContainingBlockComputedStyle:!currentNodeIsContaining&&computedStyle.position===`static`&¤tContainingBlockComputedStyle&&absoluteOrFixed.has(currentContainingBlockComputedStyle.position)||isOverflowElement(currentNode)&&!currentNodeIsContaining&&hasFixedPositionAncestor(element,currentNode))?result=result.filter(ancestor=>ancestor!==currentNode):currentContainingBlockComputedStyle=computedStyle,currentNode=getParentNode(currentNode)}return cache$1.set(element,result),result}function getClippingRect(_ref){let{element,boundary,rootBoundary,strategy}=_ref,clippingAncestors=[...boundary===`clippingAncestors`?isTopLayer(element)?[]:getClippingElementAncestors(element,this._c):[].concat(boundary),rootBoundary],firstClippingAncestor=clippingAncestors[0],clippingRect=clippingAncestors.reduce((accRect,clippingAncestor)=>{let rect=getClientRectFromClippingAncestor(element,clippingAncestor,strategy);return accRect.top=max(rect.top,accRect.top),accRect.right=min(rect.right,accRect.right),accRect.bottom=min(rect.bottom,accRect.bottom),accRect.left=max(rect.left,accRect.left),accRect},getClientRectFromClippingAncestor(element,firstClippingAncestor,strategy));return{width:clippingRect.right-clippingRect.left,height:clippingRect.bottom-clippingRect.top,x:clippingRect.left,y:clippingRect.top}}function getDimensions(element){let{width:width$1,height:height$1}=getCssDimensions(element);return{width:width$1,height:height$1}}function getRectRelativeToOffsetParent(element,offsetParent,strategy){let isOffsetParentAnElement=isHTMLElement(offsetParent),documentElement=getDocumentElement(offsetParent),isFixed=strategy===`fixed`,rect=getBoundingClientRect(element,!0,isFixed,offsetParent),scroll$1={scrollLeft:0,scrollTop:0},offsets=createCoords(0);function setLeftRTLScrollbarOffset(){offsets.x=getWindowScrollBarX(documentElement)}if(isOffsetParentAnElement||!isOffsetParentAnElement&&!isFixed)if((getNodeName(offsetParent)!==`body`||isOverflowElement(documentElement))&&(scroll$1=getNodeScroll(offsetParent)),isOffsetParentAnElement){let offsetRect=getBoundingClientRect(offsetParent,!0,isFixed,offsetParent);offsets.x=offsetRect.x+offsetParent.clientLeft,offsets.y=offsetRect.y+offsetParent.clientTop}else documentElement&&setLeftRTLScrollbarOffset();isFixed&&!isOffsetParentAnElement&&documentElement&&setLeftRTLScrollbarOffset();let htmlOffset=documentElement&&!isOffsetParentAnElement&&!isFixed?getHTMLOffset(documentElement,scroll$1):createCoords(0);return{x:rect.left+scroll$1.scrollLeft-offsets.x-htmlOffset.x,y:rect.top+scroll$1.scrollTop-offsets.y-htmlOffset.y,width:rect.width,height:rect.height}}function isStaticPositioned(element){return getComputedStyle$1(element).position===`static`}function getTrueOffsetParent(element,polyfill){if(!isHTMLElement(element)||getComputedStyle$1(element).position===`fixed`)return null;if(polyfill)return polyfill(element);let rawOffsetParent=element.offsetParent;return getDocumentElement(element)===rawOffsetParent&&(rawOffsetParent=rawOffsetParent.ownerDocument.body),rawOffsetParent}function getOffsetParent(element,polyfill){let win=getWindow(element);if(isTopLayer(element))return win;if(!isHTMLElement(element)){let svgOffsetParent=getParentNode(element);for(;svgOffsetParent&&!isLastTraversableNode(svgOffsetParent);){if(isElement(svgOffsetParent)&&!isStaticPositioned(svgOffsetParent))return svgOffsetParent;svgOffsetParent=getParentNode(svgOffsetParent)}return win}let offsetParent=getTrueOffsetParent(element,polyfill);for(;offsetParent&&isTableElement(offsetParent)&&isStaticPositioned(offsetParent);)offsetParent=getTrueOffsetParent(offsetParent,polyfill);return offsetParent&&isLastTraversableNode(offsetParent)&&isStaticPositioned(offsetParent)&&!isContainingBlock(offsetParent)?win:offsetParent||getContainingBlock(element)||win}var getElementRects=async function(data){let getOffsetParentFn=this.getOffsetParent||getOffsetParent,getDimensionsFn=this.getDimensions,floatingDimensions=await getDimensionsFn(data.floating);return{reference:getRectRelativeToOffsetParent(data.reference,await getOffsetParentFn(data.floating),data.strategy),floating:{x:0,y:0,width:floatingDimensions.width,height:floatingDimensions.height}}};function isRTL(element){return getComputedStyle$1(element).direction===`rtl`}var platform={convertOffsetParentRelativeRectToViewportRelativeRect,getDocumentElement,getClippingRect,getOffsetParent,getElementRects,getClientRects,getDimensions,getScale,isElement,isRTL};function rectsAreEqual(a$1,b){return a$1.x===b.x&&a$1.y===b.y&&a$1.width===b.width&&a$1.height===b.height}function observeMove(element,onMove){let io=null,timeoutId,root=getDocumentElement(element);function cleanup(){var _io;clearTimeout(timeoutId),(_io=io)==null||_io.disconnect(),io=null}function refresh$1(skip,threshold){skip===void 0&&(skip=!1),threshold===void 0&&(threshold=1),cleanup();let elementRectForRootMargin=element.getBoundingClientRect(),{left,top,width:width$1,height:height$1}=elementRectForRootMargin;if(skip||onMove(),!width$1||!height$1)return;let insetTop=floor(top),insetRight=floor(root.clientWidth-(left+width$1)),insetBottom=floor(root.clientHeight-(top+height$1)),insetLeft=floor(left),options={rootMargin:-insetTop+`px `+-insetRight+`px `+-insetBottom+`px `+-insetLeft+`px`,threshold:max(0,min(1,threshold))||1},isFirstUpdate=!0;function handleObserve(entries){let ratio=entries[0].intersectionRatio;if(ratio!==threshold){if(!isFirstUpdate)return refresh$1();ratio?refresh$1(!1,ratio):timeoutId=setTimeout(()=>{refresh$1(!1,1e-7)},1e3)}ratio===1&&!rectsAreEqual(elementRectForRootMargin,element.getBoundingClientRect())&&refresh$1(),isFirstUpdate=!1}try{io=new IntersectionObserver(handleObserve,{...options,root:root.ownerDocument})}catch{io=new IntersectionObserver(handleObserve,options)}io.observe(element)}return refresh$1(!0),cleanup}function autoUpdate(reference,floating,update$6,options){options===void 0&&(options={});let{ancestorScroll=!0,ancestorResize=!0,elementResize=typeof ResizeObserver==`function`,layoutShift=typeof IntersectionObserver==`function`,animationFrame=!1}=options,referenceEl=unwrapElement$1(reference),ancestors=ancestorScroll||ancestorResize?[...referenceEl?getOverflowAncestors(referenceEl):[],...getOverflowAncestors(floating)]:[];ancestors.forEach(ancestor=>{ancestorScroll&&ancestor.addEventListener(`scroll`,update$6,{passive:!0}),ancestorResize&&ancestor.addEventListener(`resize`,update$6)});let cleanupIo=referenceEl&&layoutShift?observeMove(referenceEl,update$6):null,reobserveFrame=-1,resizeObserver=null;elementResize&&(resizeObserver=new ResizeObserver(_ref=>{let[firstEntry]=_ref;firstEntry&&firstEntry.target===referenceEl&&resizeObserver&&(resizeObserver.unobserve(floating),cancelAnimationFrame(reobserveFrame),reobserveFrame=requestAnimationFrame(()=>{var _resizeObserver;(_resizeObserver=resizeObserver)==null||_resizeObserver.observe(floating)})),update$6()}),referenceEl&&!animationFrame&&resizeObserver.observe(referenceEl),resizeObserver.observe(floating));let frameId,prevRefRect=animationFrame?getBoundingClientRect(reference):null;animationFrame&&frameLoop();function frameLoop(){let nextRefRect=getBoundingClientRect(reference);prevRefRect&&!rectsAreEqual(prevRefRect,nextRefRect)&&update$6(),prevRefRect=nextRefRect,frameId=requestAnimationFrame(frameLoop)}return update$6(),()=>{var _resizeObserver2;ancestors.forEach(ancestor=>{ancestorScroll&&ancestor.removeEventListener(`scroll`,update$6),ancestorResize&&ancestor.removeEventListener(`resize`,update$6)}),cleanupIo?.(),(_resizeObserver2=resizeObserver)==null||_resizeObserver2.disconnect(),resizeObserver=null,animationFrame&&cancelAnimationFrame(frameId)}}var offset=offset$1,shift=shift$1,flip=flip$1,arrow$1=arrow$2,computePosition=(reference,floating,options)=>{let cache$1=new Map,mergedOptions={platform,...options},platformWithCache={...mergedOptions.platform,_c:cache$1};return computePosition$1(reference,floating,{...mergedOptions,platform:platformWithCache})};function isComponentPublicInstance(target){return typeof target==`object`&&!!target&&`$el`in target}function unwrapElement(target){if(isComponentPublicInstance(target)){let element=target.$el;return isNode(element)&&getNodeName(element)===`#comment`?null:element}return target}function toValue(source){return typeof source==`function`?source():unref(source)}function arrow(options){return{name:`arrow`,options,fn(args){let element=unwrapElement(toValue(options.element));return element==null?{}:arrow$1({element,padding:options.padding}).fn(args)}}}function getDPR(element){return typeof window>`u`?1:(element.ownerDocument.defaultView||window).devicePixelRatio||1}function roundByDPR(element,value){let dpr=getDPR(element);return Math.round(value*dpr)/dpr}function useFloating(reference,floating,options){options===void 0&&(options={});let whileElementsMountedOption=options.whileElementsMounted,openOption=computed(()=>{var _toValue;return toValue(options.open)??!0}),middlewareOption=computed(()=>toValue(options.middleware)),placementOption=computed(()=>{var _toValue2;return toValue(options.placement)??`bottom`}),strategyOption=computed(()=>{var _toValue3;return toValue(options.strategy)??`absolute`}),transformOption=computed(()=>{var _toValue4;return toValue(options.transform)??!0}),referenceElement=computed(()=>unwrapElement(reference.value)),floatingElement=computed(()=>unwrapElement(floating.value)),x=ref(0),y=ref(0),strategy=ref(strategyOption.value),placement=ref(placementOption.value),middlewareData=shallowRef({}),isPositioned=ref(!1),floatingStyles=computed(()=>{let initialStyles={position:strategy.value,left:`0`,top:`0`};if(!floatingElement.value)return initialStyles;let xVal=roundByDPR(floatingElement.value,x.value),yVal=roundByDPR(floatingElement.value,y.value);return transformOption.value?{...initialStyles,transform:`translate(`+xVal+`px, `+yVal+`px)`,...getDPR(floatingElement.value)>=1.5&&{willChange:`transform`}}:{position:strategy.value,left:xVal+`px`,top:yVal+`px`}}),whileElementsMountedCleanup;function update$6(){if(referenceElement.value==null||floatingElement.value==null)return;let open$1=openOption.value;computePosition(referenceElement.value,floatingElement.value,{middleware:middlewareOption.value,placement:placementOption.value,strategy:strategyOption.value}).then(position=>{x.value=position.x,y.value=position.y,strategy.value=position.strategy,placement.value=position.placement,middlewareData.value=position.middlewareData,isPositioned.value=open$1!==!1})}function cleanup(){typeof whileElementsMountedCleanup==`function`&&(whileElementsMountedCleanup(),whileElementsMountedCleanup=void 0)}function attach(){if(cleanup(),whileElementsMountedOption===void 0){update$6();return}if(referenceElement.value!=null&&floatingElement.value!=null){whileElementsMountedCleanup=whileElementsMountedOption(referenceElement.value,floatingElement.value,update$6);return}}function reset$1(){openOption.value||(isPositioned.value=!1)}return watch([middlewareOption,placementOption,strategyOption,openOption],update$6,{flush:`sync`}),watch([referenceElement,floatingElement],attach,{flush:`sync`}),watch(openOption,reset$1,{flush:`sync`}),getCurrentScope()&&onScopeDispose(cleanup),{x:shallowReadonly(x),y:shallowReadonly(y),strategy:shallowReadonly(strategy),placement:shallowReadonly(placement),middlewareData:shallowReadonly(middlewareData),isPositioned:shallowReadonly(isPositioned),floatingStyles,update:update$6}}var ARROW_POSITION={top:`bottom`,right:`left`,bottom:`top`,left:`right`};const usePopover=defineStore(`popover`,()=>{let _counter=ref(0),_currentPopover=ref(null),popovers=ref({}),currentPopover=computed(()=>_currentPopover.value),register=(name,popover,popoverPlacement=void 0,options={})=>{if(popovers.value[name])return;popovers.value[name]={element:popover,target:null,placement:popoverPlacement||`bottom`,show:!1};let popoverInstance=buildPopover(popover,toRef(popovers.value[name],`target`),toRef(popovers.value[name],`placement`),options),scope$1=effectScope(),show$1;scope$1.run(()=>{show$1=computed(()=>popovers.value[name].show)});let dispose$2=()=>{scope$1.stop(),popoverInstance.dispose()};return popovers.value[name].dispose=dispose$2,_counter.value++,{show:show$1,update:popoverInstance.update,placement:popoverInstance.placement}},bind=(popoverName,el,options)=>{let scope$1=effectScope(),hidden,isBound,popoverElement;scope$1.run(()=>{hidden=computed(()=>popovers.value[popoverName]?!popovers.value[popoverName].show:void 0),isBound=computed(()=>popovers.value[popoverName]?popovers.value[popoverName].target===el:void 0),popoverElement=computed(()=>popovers.value[popoverName]?popovers.value[popoverName].element:void 0)});let show$1=()=>{isBound.value||(popovers.value[popoverName].target=el,popovers.value[popoverName].placement=options.placement),popovers.value[popoverName].show=!0},hide$3=()=>{isBound.value&&(popovers.value[popoverName].show=!1)};return{popoverElement,hidden,isBound,show:show$1,hide:hide$3,toggle:(forceValue=void 0)=>{let doShow=forceValue;typeof doShow!=`boolean`&&(doShow=!isBound.value||!popovers.value[popoverName].show),doShow?show$1():hide$3()},isShown:()=>!!popovers.value[popoverName].show,unbind:()=>{scope$1.stop()}}},unregister=name=>{popovers.value[name]&&(popovers.value[name].dispose(),delete popovers.value[name])},isShown=name=>name in popovers.value?popovers.value[name].show:!1,show=(name,target)=>{name in popovers.value&&(popovers.value[name].show=!0,target&&(popovers.value[name].target=target),_currentPopover.value=popovers.value[name])},hide$2=name=>{name in popovers.value&&(popovers.value[name].show=!1,_currentPopover.value=null)};return{popovers,currentPopover,bind,register,unregister,isShown,show,hide:hide$2,toggle:(name,forceValue=void 0)=>{name in popovers.value&&(popovers.value[name].show=typeof forceValue==`boolean`?forceValue:!popovers.value[name].show,_currentPopover.value=popovers.value[name].show?popovers.value[name]:null)},hideAll:(startsWith=void 0)=>{let keys=Object.keys(popovers.value);startsWith&&(keys=keys.filter(name=>name.startsWith(startsWith))),keys.forEach(name=>popovers.value[name].show&&hide$2(name))},getPopover:name=>popovers.value[name],counter:computed(()=>_counter.value)}});function buildPopover(popover,reference,placementArg,options){let{floatingStyles,middlewareData,update:update$6,placement}=useFloating(reference,popover,{placement:placementArg,middleware:buildMiddleware(popover,options),whileElementsMounted:autoUpdate}),watchers$1=[];return watchers$1.push(watch(floatingStyles,async styles=>{popover.value&&await nextTick(()=>{Object.keys(styles).forEach(styleName=>popover.value.style[styleName]=styles[styleName])})})),options.arrow&&watchers$1.push(watch(middlewareData,async middlewareData$1=>{let left=middlewareData$1.arrow&&middlewareData$1.arrow.x!=null?`${middlewareData$1.arrow.x}px`:``,top=middlewareData$1.arrow&&middlewareData$1.arrow.y!=null?`${middlewareData$1.arrow.y}px`:``,arrowSide=ARROW_POSITION[middlewareData$1.offset.placement.split(`-`)[0]];await nextTick(()=>{applyStyles(options.arrow.value,{left,top,right:``,bottom:``,[arrowSide]:`-${options.arrow.value.offsetWidth/2}px`})})})),{placement,update:update$6,dispose:()=>{watchers$1.forEach(unwatch=>unwatch())}}}var arrowOffset=options=>({name:`arrowOffset`,options,fn({...state}){let arrOffset=Math.sqrt(2*options.element.value.offsetWidth**2)/2,side=state.placement.startsWith(`left`)||state.placement.startsWith(`top`)?-1:1;if(state.placement.startsWith(`left`)||state.placement.startsWith(`right`))return{x:state.x+side*arrOffset};if(state.placement.startsWith(`top`)||state.placement.startsWith(`bottom`))return{y:state.y+side*arrOffset}}});function buildMiddleware(popover,options){let middleware=[flip(),shift()],offsetValue=options.offset||0;return middleware.push(offset(offsetValue)),options.arrow&&(middleware.push(arrowOffset({element:options.arrow})),middleware.push(arrow({element:options.arrow}))),middleware}function applyStyles(el,styles){Object.keys(styles).forEach(styleName=>el.style[styleName]=styles[styleName])}var HOVER_SHOW_EVENTS=[`mouseover`,`focus`],HOVER_HIDE_EVENTS=[`mouseleave`,`blur`],TOGGLE_EVENTS=[`click`],BngPopover_default={mounted:setup$1,updated:setup$1,onBeforeUnmount:dispose};function setup$1(el,binding){dispose(el),binding.value&&(setPopoverProperties(el,binding),bindPopover(el),attachListeners(el,binding.modifiers))}function dispose(el){el.__popover&&(el.__popover.unregister&&el.__popover.unbind(),removeListeners(el))}function attachListeners(el,modifiers){el.__popover.showHandler=event=>{el.contains(event.target)&&el.__popover.show()},el.__popover.hideHandler=event=>{el.contains(event.relatedTarget)||el.__popover.hide()},el.__popover.toggleHandler=event=>{el.contains(event.target)&&el.__popover.toggle()},el.__popover.clickOutside=event=>{!el.contains(event.target)&&(!el.__popover.element.value||!el.__popover.element.value.contains(event.target))&&el.__popover.hide()},modifiers.click?(TOGGLE_EVENTS.forEach(eventName=>{el.addEventListener(eventName,el.__popover.toggleHandler)}),TOGGLE_EVENTS.forEach(eventName=>{window.addEventListener(eventName,el.__popover.clickOutside)})):(HOVER_SHOW_EVENTS.forEach(eventName=>el.addEventListener(eventName,el.__popover.showHandler)),HOVER_HIDE_EVENTS.forEach(eventName=>el.addEventListener(eventName,el.__popover.hideHandler)))}function removeListeners(el){el.__popover.toggleHandler&&(TOGGLE_EVENTS.forEach(eventName=>{el.removeEventListener(eventName,el.__popover.toggleHandler)}),TOGGLE_EVENTS.forEach(eventName=>{window.removeEventListener(eventName,el.__popover.clickOutside)})),el.__popover.showHandler&&HOVER_SHOW_EVENTS.forEach(eventName=>el.removeEventListener(eventName,el.__popover.showHandler)),el.__popover.hideHandler&&HOVER_SHOW_EVENTS.forEach(eventName=>el.removeEventListener(eventName,el.__popover.hideHandler))}function bindPopover(el){let popoverBind=usePopover().bind(el.__popover.name,el,getOptions$1(el));Object.assign(el.__popover,{toggle:popoverBind.toggle,show:popoverBind.show,isShown:popoverBind.isShown,hide:popoverBind.hide,toggle:popoverBind.toggle,hidden:popoverBind.hidden,element:popoverBind.popoverElement,unbind:popoverBind.unbind})}function setPopoverProperties(el,binding){el.__popover={name:getPopoverName(binding),placement:getPlacement(binding)}}var getOptions$1=el=>({placement:el.__popover.placement}),getPlacement=binding=>binding.arg?binding.arg:binding.placement?binding.placement:`left`,getPopoverName=binding=>typeof binding.value==`string`?binding.value:binding.value.name,TIMESPAN_TRANSLATE_ID_PREFIX=`ui.timespan.`,$t=i=>$translate.instant(TIMESPAN_TRANSLATE_ID_PREFIX+i),SECONDS_IN={year:3600*24*365,month:3600*24*30,week:3600*24*7,day:3600*24,hour:3600,minute:60,second:1},MINIMUM_SPAN=Object.entries(SECONDS_IN).slice(-1)[0][1],dateToEpoch=date=>date?typeof date==`string`?/^\d+$/.test(date)?+date:~~(new Date(date).getTime()/1e3):typeof date==`number`?date:0:0;const timeSpan=(date1,date2=null,length=2,useRelativeDescription=!1)=>{let res=`-`;if(date1=dateToEpoch(date1),!date1)return res;if(date2){if(date2=dateToEpoch(date2),!date2)return res}else date2=~~(new Date().getTime()/1e3);let diff,isFuture;return date1>=date2?(diff=date1-date2,isFuture=!0):(diff=date2-date1,isFuture=!1),res=formatTime(diff,length,useRelativeDescription,isFuture),res},formatTime=(seconds,length=2,useRelativeDescription=!1,future=!1)=>{let res=`-`;if(seconds20&&abs%10==1?abs+` `+$t(spanName+`.plural_1_pastfuture`):abs<=4||useRelativeDescription&&abs>20&&abs%10<=4?abs+` `+$t(spanName+`.plural_234`):abs+` `+$t(spanName+`.plural`),cur&&resArr.push(cur),length===1)break;length--,seconds%=spanSeconds}res=``;let resArrLen=resArr.length;return resArr.forEach((bit,i)=>{bit=bit.replace(` `,`\xA0`),i?(i===resArrLen-1?res+=` `+$t(`and`)+` `:res+=$t(`separator`)+` `,res+=bit):res+=ucaseFirst(bit)}),useRelativeDescription&&(res+=` `+$t(future?`future`:`past`)),res};var update=(element,{value})=>{let desc=timeSpan(value,null,1,!0);desc!==`-`&&(element.innerHTML=desc)},BngRelativeTime_default=update;const getScopeProperties=el=>{if(!(!el||!el.hasAttribute(`bng-ui-scope`)))return{scopeId:el.getAttribute(UI_SCOPE_ATTR$1),isScopedNav:el.hasAttribute(SCOPED_NAV_ATTR)}},findParentScope=(el,scopedNavOnly=!1)=>{let parent=el.parentElement;for(;parent;){let scopedNavId=parent.getAttribute(SCOPED_NAV_ATTR);if(scopedNavId)return{scopeId:scopedNavId,element:parent,isScopedNav:!0};if(!scopedNavOnly){let uiScopeId=parent.getAttribute(UI_SCOPE_ATTR$1);if(uiScopeId)return{scopeId:uiScopeId,element:parent,isScopedNav:!1}}parent=parent.parentElement}return null},isNavigable=el=>(!el.hasAttribute(`bng-no-nav`)||el.getAttribute(`bng-no-nav`)===`false`)&&(!el.hasAttribute(`disabled`)||el.getAttribute(`disabled`)===`false`),isDirectChild=(el,child)=>child.parentElement.closest(`[bng-scoped-nav]`)===el,getNavItems=(el,navigableOnly=!0)=>{let matches$1=el.querySelectorAll(NAVIGABLE_ELEMENTS_SELECTOR);return Array.from(matches$1).filter(child=>!isNavigable(child)&&navigableOnly?!1:isDirectChild(el,child))},getPassthroughEvents=el=>{let navItems=getNavItems(el,!1);if(navItems.length===0)return!1;let boundEvents=[];for(let elem of navItems){let uiNavEvents=elem.__BngOnUiNav?Object.values(elem.__BngOnUiNav).map(x=>x.eventNames).flat().filter(name=>!PASSTHROUGH_EXCLUDED_EVENTS.includes(name)):[],isDuplicate=uiNavEvents.some(event=>boundEvents.includes(event));if(uiNavEvents.length===0||isDuplicate){boundEvents=[];break}uiNavEvents.forEach(event=>{boundEvents.includes(event)||boundEvents.push(event)})}return boundEvents};var SCOPED_NAV_OBSERVER_EVENTS={onBeforeScopeActivated:`onBeforeScopeActivated`,onScopeActivated:`onScopeActivated`,onBeforeScopeDeactivated:`onBeforeScopeDeactivated`,onScopeDeactivated:`onScopeDeactivated`,onBeforeScopeSuspended:`onBeforeScopeSuspended`,onScopeSuspended:`onScopeSuspended`,onBeforeScopeResumed:`onBeforeScopeResumed`,onScopeResumed:`onScopeResumed`},scopedNavObservers={};function registerScopedNavObserver(id,observer$2){scopedNavObservers[id]=observer$2}function notifyScopedNavObservers(event,detail){Object.keys(scopedNavObservers).forEach(observerId=>{let callback=scopedNavObservers[observerId][event];if(callback&&typeof callback==`function`)try{callback(detail)}catch(error){logger_default.error(`Error in scoped nav observer ${observerId} for event ${event}`,error)}})}const useScopedNav=defineStore(`scopedNav2`,()=>{let scopeStack=ref([]),activateScope=(scopeId,element,options={activationType:SCOPED_NAV_STATES.active,suspendParentScopes:!1})=>{notifyScopedNavObservers(SCOPED_NAV_OBSERVER_EVENTS.onBeforeScopeActivated,{scopeId,element,options});let scopeIndex=scopeStack.value.findIndex(s=>s.scopeId===scopeId),existingScope=scopeIndex===-1?void 0:scopeStack.value[scopeIndex];if(existingScope&&existingScope.activationType===options.activationType){logger_default.warn(`Scope ${scopeId} already active. Ignoring...`),notifyScopedNavObservers(SCOPED_NAV_OBSERVER_EVENTS.onScopeActivated,{scopeId,element,options});return}existingScope?existingScope.activationType=options.activationType:(scopeStack.value.push({scopeId,element,...options}),scopeIndex=scopeStack.value.length-1),notifyScopedNavObservers(SCOPED_NAV_OBSERVER_EVENTS.onScopeActivated,{scopeId,element,options});let scopeData={scopeId,...options},{type}=element[SCOPED_NAV_PROPERTY_NAME];if(type===SCOPED_NAV_TYPES.popover||options.suspendParentScopes){let referenceElement=element;if(type===SCOPED_NAV_TYPES.popover){let popover=usePopover(),popoverName=element.getAttribute(`data-bng-popover-name`),pop=popover.getPopover(popoverName);pop&&pop.target&&(referenceElement=pop.target)}if(!referenceElement){logger_default.warn(`Unable to find popover's target element. Skipping suspending parent scopes...`);return}let parentScopes=scopeStack.value.slice(0,scopeIndex);for(let i=parentScopes.length-1;i>=0;i--){let scope$1=parentScopes[i];referenceElement&&scope$1.element.contains(referenceElement)?suspendScope(scope$1.scopeId,scopeData):referenceElement&&!scope$1.element.contains(referenceElement)&&deactivateScope(scope$1.scopeId)}}return getUINavServiceInstance().setActiveScope(scopeId),element.dispatchEvent(new CustomEvent(SCOPED_NAV_EVENTS.activate,{detail:scopeData})),scopeData},deactivateScope=(scopeId,settings$1={resumePrevious:!1})=>{let scopeIndex=scopeStack.value.findIndex(s=>s.scopeId===scopeId);if(scopeIndex===-1){logger_default.warn(`Scope ${scopeId} not found. Ignoring...`);return}notifyScopedNavObservers(SCOPED_NAV_OBSERVER_EVENTS.onBeforeScopeDeactivated,{scopeId,settings:settings$1});let scopeData=scopeStack.value[scopeIndex],element=scopeData.element,{type}=element[SCOPED_NAV_PROPERTY_NAME];if(scopeStack.value=scopeStack.value.slice(0,scopeIndex),element.dispatchEvent(new CustomEvent(SCOPED_NAV_EVENTS.deactivate,{detail:{scopeId,settings:settings$1,...scopeData}})),notifyScopedNavObservers(SCOPED_NAV_OBSERVER_EVENTS.onScopeDeactivated,{scopeId,settings:settings$1}),!settings$1.resumePrevious){getUINavServiceInstance().setActiveScope(null);return}let parentScope;if(type===SCOPED_NAV_TYPES.popover){let popover=usePopover(),popoverName=element.getAttribute(`data-bng-popover-name`),pop=popover.getPopover(popoverName);pop?parentScope=findParentScope(pop.target,!0):logger_default.warn(`Unable to find popover's target element. Skipping resume...`)}else parentScope=findParentScope(element,!0);parentScope?getScopeById(parentScope.scopeId)?resumeScope(parentScope.scopeId):activateScope(parentScope.scopeId,parentScope.element):getUINavServiceInstance().setActiveScope(null)},resumeScope=scopeId=>{let scopeIndex=scopeStack.value.findIndex(s=>s.scopeId===scopeId);if(scopeIndex===-1){logger_default.warn(`Scope ${scopeId} not found. Ignoring...`);return}notifyScopedNavObservers(SCOPED_NAV_OBSERVER_EVENTS.onBeforeScopeResumed,{scopeId});for(let i=scopeStack.value.length-1;i>scopeIndex;i--){let scope$1=scopeStack.value[i];deactivateScope(scope$1.scopeId)}let scopeData=scopeStack.value[scopeIndex];return scopeData.activationType=SCOPED_NAV_STATES.active,getUINavServiceInstance().setActiveScope(scopeData.scopeId),scopeData.element.dispatchEvent(new CustomEvent(SCOPED_NAV_EVENTS.resume,{detail:scopeData})),notifyScopedNavObservers(SCOPED_NAV_OBSERVER_EVENTS.onScopeResumed,{scopeId}),scopeData},suspendScope=(scopeId,newScope)=>{let scopeIndex=scopeStack.value.findIndex(s=>s.scopeId===scopeId);if(scopeIndex===-1){logger_default.warn(`Scope ${scopeId} not found. Ignoring...`);return}notifyScopedNavObservers(SCOPED_NAV_OBSERVER_EVENTS.onBeforeScopeSuspended,{scopeId,newScope});let scopeData=scopeStack.value[scopeIndex];if(scopeData.activationType===SCOPED_NAV_STATES.suspended){logger_default.warn(`Scope ${scopeId} already suspended. Ignoring...`);return}scopeData.activationType=SCOPED_NAV_STATES.suspended;let element=scopeData.element,payload={scopeId,newScope,...scopeData};return element.dispatchEvent(new CustomEvent(SCOPED_NAV_EVENTS.suspend,{detail:payload})),notifyScopedNavObservers(SCOPED_NAV_OBSERVER_EVENTS.onScopeSuspended,{scopeId,newScope}),scopeData},currentScope=()=>scopeStack.value[scopeStack.value.length-1],getScopeById=scopeId=>scopeStack.value.find(s=>s.scopeId===scopeId);return{activateScope,deactivateScope,resumeScope,suspendScope,getScopeById,currentScope,isCurrentScope:scopeId=>{let scope$1=currentScope();return scope$1&&scope$1.scopeId===scopeId},isActiveScope:scopeId=>{let current=currentScope();if(!current)return!1;if(current.scopeId===scopeId)return!0;if(current.activationType===SCOPED_NAV_STATES.partial&&scopeStack.value.length>2){let parentScope=scopeStack.value[scopeStack.value.length-2];if(parentScope.scopeId===scopeId&&parentScope.activationType===SCOPED_NAV_STATES.active)return!0}return!1},getScopes:()=>scopeStack.value}});var focusDebounceTimer=null,pendingFocusAction=null,focusListenersInitialized=!1,isActivatingScope=!1,isDeactivatingScope=!1,FOCUS_DEBOUNCE_TIME=200,focusManagerId=`focusManager`,clearFocusDebounce=()=>{focusDebounceTimer&&=(clearTimeout(focusDebounceTimer),null),pendingFocusAction=null},debouncedFocusAction=action=>{clearFocusDebounce(),pendingFocusAction=action,focusDebounceTimer=setTimeout(()=>{pendingFocusAction&&=(pendingFocusAction(),null),focusDebounceTimer=null},FOCUS_DEBOUNCE_TIME)};function useFocusManager(){let scopedNav=useScopedNav(),onUINavFocus=e=>{let{target,relatedTarget}=e.detail;if(isWithinDashmenu(target)||isWithinPopup(target))return;let targetScope=findParentScope(target,!0),scopeElement=targetScope&&targetScope.isScopedNav?targetScope.element:null,scopedNavProps=scopeElement&&scopeElement._bngScopedNav?scopeElement[SCOPED_NAV_PROPERTY_NAME]:null;if(scopedNavProps&&(scopeElement[SCOPED_NAV_PROPERTY_NAME].lastActiveElement=target),isActivatingScope||isDeactivatingScope||shouldSkipFocusHandling(scopedNavProps)){clearFocusDebounce();return}debouncedFocusAction(()=>handleFocusAction(target,targetScope,scopeElement,scopedNav))},onUINavBlur=e=>{let{target}=e.detail,scopeProperties=getScopeProperties(target);shouldHandleBlur(scopeProperties,scopedNav.currentScope())&&(target[SCOPED_NAV_PROPERTY_NAME].passthroughActive=!1,scopedNav.deactivateScope(scopeProperties.scopeId,{resumePrevious:!0}))};function addFocusListeners(){focusListenersInitialized||=(document.addEventListener(`uinav-focus`,onUINavFocus),document.addEventListener(`uinav-blur`,onUINavBlur),registerScopedNavObserver(focusManagerId,{onBeforeScopeActivated:()=>{clearFocusDebounce(),isActivatingScope=!0},onScopeActivated:()=>{clearFocusDebounce(),isActivatingScope=!1},onBeforeScopeDeactivated:()=>{clearFocusDebounce(),isDeactivatingScope=!0},onScopeDeactivated:()=>{clearFocusDebounce(),isDeactivatingScope=!1}}),!0)}function removeFocusListeners(){focusListenersInitialized&&=(document.removeEventListener(`uinav-focus`,onUINavFocus),document.removeEventListener(`uinav-blur`,onUINavBlur),!1)}function setup$3(){addFocusListeners()}function dispose$2(){removeFocusListeners()}return onMounted(()=>{setup$3()}),onBeforeUnmount(()=>{dispose$2()}),{setup:setup$3,dispose:dispose$2}}function isWithinDashmenu(target){return document.getElementById(`dashmenu`)?.contains(target)}function isWithinPopup(target){return!!target.closest(`dialog`)}function shouldSkipFocusHandling(scopedNavProps){return scopedNavProps?.type===SCOPED_NAV_TYPES.popover}function shouldHandleBlur(scopeProperties,currScope){return scopeProperties?.isScopedNav&&currScope?.scopeId===scopeProperties.scopeId&&currScope?.activationType===SCOPED_NAV_STATES.partial}function handleFocusAction(target,targetScope,scopeElement,scopedNavStore){if(!document.contains(target)&&!document.contains(scopeElement))return;let activeScope=scopedNavStore.currentScope();if(activeScope?.element===target)return;let existingScope,scopes=scopedNavStore.getScopes();for(let i=scopes.length-1;i>=0;i--){let scope$1=scopes[i];if(scope$1.element===scopeElement){existingScope=scope$1;break}}if(existingScope&&activeScope&&existingScope.scopeId!==activeScope.scopeId){scopedNavStore.resumeScope(existingScope.scopeId);return}scopes=scopedNavStore.getScopes();for(let i=scopes.length-1;i>=0;i--){let scope$1=scopes[i];if(scope$1.element===target||scope$1.element.contains(target)||scopeElement===scope$1.element||scope$1.element.contains(scopeElement))break;scopedNavStore.deactivateScope(scope$1.scopeId)}if(scopes=scopedNavStore.getScopes(),targetScope&&targetScope.isScopedNav){let lastScope=scopes.length>0?scopes[scopes.length-1]:null;lastScope&&activeScope&&activeScope.scopeId===lastScope.scopeId&&targetScope.scopeId!==lastScope.scopeId&&lastScope.activationType!==SCOPED_NAV_STATES.suspended&&scopedNavStore.suspendScope(lastScope.scopeId,{scopeId:targetScope.scopeId,scopeElement}),(!activeScope||activeScope.scopeId!==targetScope.scopeId)&&scopeElement._bngScopedNav.canActivate()&&scopedNavStore.activateScope(targetScope.scopeId,scopeElement)}if(target.hasAttribute(`bng-scoped-nav`)){let allowPartialActivation=target[SCOPED_NAV_PROPERTY_NAME].passthroughEnabled,canActivate=target[SCOPED_NAV_PROPERTY_NAME].canActivate();if(target[SCOPED_NAV_PROPERTY_NAME].passthroughActive=!0,allowPartialActivation&&canActivate){let partialScope=getScopeProperties(target);scopedNavStore.activateScope(partialScope.scopeId,target,{activationType:SCOPED_NAV_STATES.partial})}}}var PROPERTY_NAME=`_bngScopedNav`,ATTR_NAME=`bng-scoped-nav`,AUTOFOCUS_ATTR=`bng-scoped-nav-autofocus`,UI_SCOPE_ATTR=`bng-ui-scope`,NAV_ITEM_ATTR=`bng-nav-item`,BNG_ON_UI_NAV_ATTR=`__BngOnUiNav`,DEFAULT_AUTO_FOCUS_DELAY=100,EVENTS_UINAV_MAP={activate:[UI_EVENTS.ok],deactivate:[UI_EVENTS.back],navigation:[...UI_EVENT_GROUPS.focusMove,...UI_EVENT_GROUPS.focusMoveScalar]},NAV_EVENTS={activate:`activate`,deactivate:`deactivate`,suspend:`suspend`,resume:`resume`};const ACTIONS_ON_SUSPEND={allowNavigationLastNavItem:`allowNavigationLastNavItem`,allowNavigationByAttribute:`allowNavigationByAttribute`,disableNavigation:`disableNavigation`};var BngScopedNav_default={beforeMount,mounted,updated,beforeUnmount,unmounted},getDefaultOptions=()=>({type:SCOPED_NAV_TYPES.normal,activateOnMount:!1,actionsOnSuspend:[ACTIONS_ON_SUSPEND.disableNavigation],bubbleWhitelistEvents:[],bubbleBlacklistEvents:[],forcePassthroughEvents:[],canActivate:()=>!0,canDeactivate:()=>!0,autoFocusDelay:DEFAULT_AUTO_FOCUS_DELAY}),canBubbleEventInternal=(el,e)=>{let{bubbleWhitelistEvents,canBubbleEvent}=el[PROPERTY_NAME];return canBubbleEvent&&typeof canBubbleEvent==`function`?canBubbleEvent(e):bubbleWhitelistEvents&&Array.isArray(bubbleWhitelistEvents)&&bubbleWhitelistEvents.length>0?bubbleWhitelistEvents.includes(e.detail.name):!1},shouldBubbleToNextScope=(el,e)=>{let currentScope=useScopedNav().currentScope(),{scopeId,type}=el[PROPERTY_NAME],isActive=currentScope&¤tScope.scopeId===scopeId,isPartial=isActive&¤tScope.activationType===SCOPED_NAV_STATES.partial,isContainer=type===SCOPED_NAV_TYPES.container,isInactiveAndFocused=document.activeElement===el&&!isActive;return!currentScope||isInactiveAndFocused||canBubbleEventInternal(el,e)||isPartial||isContainer},getOptions=(el,binding,vnode)=>{let options={...getDefaultOptions(),...binding.value};if(!Object.values(SCOPED_NAV_TYPES).includes(options.type)){console.error(`Invalid scoped nav type: ${options.type}`);return}return options},applyOptions=(el,options)=>{let attributes={};switch(options.type){case SCOPED_NAV_TYPES.normal:attributes[NAV_ITEM_ATTR]=``,attributes[NO_CHILD_NAV_ATTR]=`true`;break;case SCOPED_NAV_TYPES.nonav:attributes[NO_NAV_ATTR]=`true`,attributes[NO_CHILD_NAV_ATTR]=`true`;break}Object.keys(attributes).forEach(attr=>el.setAttribute(attr,attributes[attr]))},findAutoFocusItem=navItems=>navItems.find(item=>item.hasAttribute(AUTOFOCUS_ATTR)&&item.getAttribute(AUTOFOCUS_ATTR)!==`false`),getAutoFocusItem=el=>findAutoFocusItem(getNavItems(el)),getFirstOrDefaultNavItem=el=>{let navItems,isAutoFocusItem=!1,getNavItems$1=()=>navItems||=getNavItems(el),getLastActive=()=>{let elm=el[PROPERTY_NAME].lastActiveElement;return elm&&!document.contains(elm)?null:elm},getAutoFocus=()=>{let elm=findAutoFocusItem(getNavItems$1());return elm&&!isNavigable(elm)?null:(isAutoFocusItem=!!elm,elm)},getFirst=()=>getNavItems$1()[0],sequence=[getLastActive,getAutoFocus];el[PROPERTY_NAME].preferAutoFocus&&sequence.reverse(),sequence.push(getFirst);for(let func of sequence){let elm=func();if(elm)return{focusItem:elm,isAutoFocusItem}}return{focusItem:null,isAutoFocusItem:!1}},setEnabledNavigation=(el,enabled,settings$1={applyToChildItems:!1,filterElements:void 0})=>{let{type}=el[PROPERTY_NAME];if(type===SCOPED_NAV_TYPES.nonav){logger_default.warn(`Cannot toggle navigation settings for nonav type`,el,enabled,type);return}settings$1.applyToChildItems?getNavItems(el,!1).forEach(item=>{if(!(settings$1.filterElements&&settings$1.filterElements.includes(item))){if(!item[PROPERTY_NAME]){let currentValue=item.hasAttribute(`bng-no-nav`)?item.getAttribute(NO_NAV_ATTR):void 0;item[PROPERTY_NAME]={originalNoNav:currentValue,hadOriginalNoNav:currentValue!==void 0}}enabled?(item[PROPERTY_NAME].hadOriginalNoNav?item.setAttribute(NO_NAV_ATTR,item[PROPERTY_NAME].originalNoNav):item.removeAttribute(NO_NAV_ATTR),item[PROPERTY_NAME].noNavSetByDirective=!1):(!item[PROPERTY_NAME].hadOriginalNoNav||item[PROPERTY_NAME].originalNoNav!==`true`)&&(item.setAttribute(NO_NAV_ATTR,`true`),item[PROPERTY_NAME].noNavSetByDirective=!0)}}):enabled?(el.removeAttribute(NO_CHILD_NAV_ATTR),type===SCOPED_NAV_TYPES.normal&&el.setAttribute(NO_NAV_ATTR,`true`)):(el.setAttribute(NO_CHILD_NAV_ATTR,`true`),type===SCOPED_NAV_TYPES.normal&&el.removeAttribute(NO_NAV_ATTR))},focusFirstOrDefaultNavItem=el=>{let{autoFocusDelay}=el[PROPERTY_NAME];nextTick(()=>{setTimeout(()=>{let{focusItem,isAutoFocusItem}=getFirstOrDefaultNavItem(el);focusItem&&setFocusExternal(focusItem,!0,isAutoFocusItem)},autoFocusDelay)})},ensureFocusOrFocusDefault=el=>{document.activeElement&&isDirectChild(el,document.activeElement)?ensureFocus(document.activeElement,!0):focusFirstOrDefaultNavItem(el)};function beforeMount(el,binding,vnode){let options=getOptions(el,binding,vnode);if(!options)return;let scopeId=options.scopeId||uniqueId(`scoped-nav`);el[PROPERTY_NAME]={scopeId,...options},el[PROPERTY_NAME].shouldBubbleEvent=e=>shouldBubbleToNextScope(el,e),el.setAttribute(ATTR_NAME,scopeId),el.setAttribute(UI_SCOPE_ATTR,scopeId),applyOptions(el,options)}function mounted(el,binding,vnode){addUINavEventListeners(el,binding,vnode),addScopedNavEventListeners(el);let scopedNav=useScopedNav(),options=getOptions(el,binding,vnode);options.type===SCOPED_NAV_TYPES.normal?configurePartialActivation(el):options.type===SCOPED_NAV_TYPES.container&&configureContainer(el,!1),options.activateOnMount&&nextTick(()=>scopedNav.activateScope(el[PROPERTY_NAME].scopeId,el))}var handleDefaultUpdate=(el,binding,vnode)=>{let activeScope=useScopedNav().currentScope(),{scopeId,type}=el[PROPERTY_NAME];!activeScope||activeScope.scopeId!==scopeId||activeScope.activationType!==SCOPED_NAV_STATES.active||ensureFocusOrFocusDefault(el)};function updated(el,binding,vnode){let options=getOptions(el,binding,vnode),{scopeId}=el[PROPERTY_NAME],scopedNav=useScopedNav();if(options.activated===!0&&!scopedNav.isActiveScope(scopeId))if(scopedNav.getScopeById(scopeId)){let popover=usePopover();if(Object.values(popover.popovers).filter(x=>x.show===!0).length>0)return;scopedNav.resumeScope(scopeId,el)}else scopedNav.activateScope(scopeId,el,{activationType:SCOPED_NAV_STATES.active,suspendParentScopes:!0});else options.activated===!1&&scopedNav.isActiveScope(scopeId)?scopedNav.deactivateScope(scopeId,{resumePrevious:!0}):!scopedNav.isActiveScope(scopeId)&&options.type===SCOPED_NAV_TYPES.container&&configureContainer(el,!1);nextTick(()=>{let activeScope=scopedNav.currentScope();activeScope&&activeScope.scopeId===scopeId&&handleDefaultUpdate(el,binding,vnode)})}function beforeUnmount(el,binding,vnode){removeScopedNavEventListeners(el);let scopedNav=useScopedNav();if(scopedNav.getScopeById(el[PROPERTY_NAME].scopeId)){let{type}=el[PROPERTY_NAME];scopedNav.deactivateScope(el[PROPERTY_NAME].scopeId,{resumePrevious:type===SCOPED_NAV_TYPES.popover}),el.dispatchEvent(new CustomEvent(NAV_EVENTS.deactivate,{detail:{force:!0,reason:`unmounted`}}))}}function unmounted(el,binding,vnode){}var handlePartialActivation=(el,event)=>{el[PROPERTY_NAME].forceBubble=!0},handleNormalActivation=(el,event)=>{el[PROPERTY_NAME].forceBubble=!1,nextTick(()=>{setEnabledNavigation(el,!0),(!document.activeElement||el===document.activeElement||!el.contains(document.activeElement))&&focusFirstOrDefaultNavItem(el)})},configurePartialActivation=el=>{let passthroughEvents=getPassthroughEvents(el);el[PROPERTY_NAME].passthroughEnabled=passthroughEvents.length>0,el[PROPERTY_NAME].passthroughEvents=passthroughEvents},configureContainer=(el,activated)=>{el[PROPERTY_NAME].containerSetup&&el[PROPERTY_NAME].containerSetup.cancel(),el[PROPERTY_NAME].containerSetup=debounce(()=>{let autoFocusItem=getAutoFocusItem(el);autoFocusItem&&setEnabledNavigation(el,activated,{applyToChildItems:!0,filterElements:[autoFocusItem]})},100),el[PROPERTY_NAME].containerSetup()},handleContainerActivation=(el,event)=>{configureContainer(el,!0)},handleNoNavActivation=(el,event)=>{},onActivate=(el,event)=>{let{type}=el[PROPERTY_NAME],{activationType}=event.detail;activationType===SCOPED_NAV_STATES.partial?handlePartialActivation(el,event):type===SCOPED_NAV_TYPES.normal?handleNormalActivation(el,event):type===SCOPED_NAV_TYPES.container?handleContainerActivation(el,event):SCOPED_NAV_TYPES.nonav,el.dispatchEvent(new CustomEvent(NAV_EVENTS.activate,{detail:event.detail}))},onDeactivate=(el,event)=>{let{type}=el[PROPERTY_NAME];type===SCOPED_NAV_TYPES.normal&&event.detail.activationType===SCOPED_NAV_STATES.active?setEnabledNavigation(el,!1):type===SCOPED_NAV_TYPES.container&&configureContainer(el,!1),el[PROPERTY_NAME].forceBubble=!1,el.dispatchEvent(new CustomEvent(NAV_EVENTS.deactivate,{detail:event.detail}))},onSuspend=(el,event)=>{let{actionsOnSuspend,type}=el[PROPERTY_NAME],filterElements=[];if(actionsOnSuspend.includes(ACTIONS_ON_SUSPEND.allowNavigationLastNavItem)){let lastActiveElement=el[PROPERTY_NAME].lastActiveElement;lastActiveElement&&document.contains(lastActiveElement)&&filterElements.push(lastActiveElement)}setEnabledNavigation(el,!1,{applyToChildItems:!0,filterElements})},onResume=(el,event)=>{let{actionsOnSuspend,type}=el[PROPERTY_NAME],filterElements=[];if(actionsOnSuspend.includes(ACTIONS_ON_SUSPEND.allowNavigationLastNavItem)){let lastActiveElement=el[PROPERTY_NAME].lastActiveElement;lastActiveElement&&document.contains(lastActiveElement)&&filterElements.push(lastActiveElement)}setEnabledNavigation(el,!0,{applyToChildItems:!0,filterElements}),ensureFocusOrFocusDefault(el)};function addScopedNavEventListeners(el){let eventHandlers={[SCOPED_NAV_EVENTS.activate]:event=>onActivate(el,event),[SCOPED_NAV_EVENTS.deactivate]:event=>onDeactivate(el,event),[SCOPED_NAV_EVENTS.suspend]:event=>onSuspend(el,event),[SCOPED_NAV_EVENTS.resume]:event=>onResume(el,event)};Object.keys(eventHandlers).forEach(eventName=>{el[PROPERTY_NAME].scopedNavListeners||(el[PROPERTY_NAME].scopedNavListeners={}),el.addEventListener(eventName,eventHandlers[eventName]),el[PROPERTY_NAME].scopedNavListeners[eventName]=eventHandlers[eventName]})}function removeScopedNavEventListeners(el){!el||!el[PROPERTY_NAME]||!el[PROPERTY_NAME].scopedNavListeners||Object.keys(el[PROPERTY_NAME].scopedNavListeners).forEach(eventName=>{el.removeEventListener(eventName,el[PROPERTY_NAME].scopedNavListeners[eventName]),delete el[PROPERTY_NAME].scopedNavListeners[eventName]})}var allowsNavigation=el=>{let{type}=el[PROPERTY_NAME];return[SCOPED_NAV_TYPES.normal,SCOPED_NAV_TYPES.container,SCOPED_NAV_TYPES.popover].includes(type)},processNavigationEvent=(el,e)=>{let currentScope=useScopedNav().currentScope(),{scopeId}=el[PROPERTY_NAME];if(!allowsNavigation(el))return!1;document.activeElement===el&¤tScope.scopeId===scopeId?focusFirstOrDefaultNavItem(el):handleUINavEvent(e,el)},isNavigationEvent=e=>UI_EVENT_GROUPS.navigation.includes(e.detail.name),getUINavEventsByEl=el=>{let uiNavEvents=el[BNG_ON_UI_NAV_ATTR]?Object.values(el[BNG_ON_UI_NAV_ATTR]).map(x=>x.eventNames).flat():[],boundEvents=[];return uiNavEvents.forEach(ev=>{boundEvents.includes(ev)||boundEvents.push(ev)}),boundEvents},hasBoundEvent=(el,eventName)=>{let boundEvents=getUINavEventsByEl(el);return boundEvents&&boundEvents.length>0&&boundEvents.includes(eventName)},isUINavEventBoundToChild=(el,e)=>{let{scopeId}=el[PROPERTY_NAME],currentScope=useScopedNav().currentScope();return currentScope&¤tScope.scopeId===scopeId&&e.target!==el&&el.contains(e.target)&&e.target===document.activeElement&&hasBoundEvent(e.target,e.detail.name)},generalHandler=(el,e)=>{let shouldBubble=!1;return isUINavEventBoundToChild(el,e)&&!e.target.hasAttribute(ATTR_NAME)||(shouldBubbleToNextScope(el,e)?shouldBubble=!0:isNavigationEvent(e)&&processNavigationEvent(el,e)),shouldBubble},processOkChildHandler=(el,e)=>{isUINavEventBoundToChild(el,e)||(handleUINavEvent(e,e.target),e.detail.sendToCrossfire=!1)},okHandler=(el,e)=>{if(e.detail.value!==1)return shouldBubbleToNextScope(el,e);let scopedNav=useScopedNav(),scopeId=el[PROPERTY_NAME].scopeId,currentScope=scopedNav.currentScope();return currentScope&¤tScope.scopeId===scopeId&¤tScope.activationType===SCOPED_NAV_STATES.active&&(document.activeElement&&isDirectChild(el,document.activeElement)||e.target&&isDirectChild(el,e.target))?processOkChildHandler(el,e):el[PROPERTY_NAME].canActivate()&&el[PROPERTY_NAME].type===SCOPED_NAV_TYPES.normal&&document.activeElement===el&&scopedNav.activateScope(scopeId,el),shouldBubbleToNextScope(el,e)},backHandler=(el,e)=>{if(e.detail.value!==1)return;let scopedNav=useScopedNav(),{scopeId,type,canDeactivate}=el[PROPERTY_NAME],currentScope=scopedNav.currentScope();if(currentScope&¤tScope.scopeId===scopeId&¤tScope.activationType===SCOPED_NAV_STATES.active)canDeactivate()&&(scopedNav.deactivateScope(scopeId,{resumePrevious:!0,executingScope:scopeId}),type===SCOPED_NAV_TYPES.normal&&nextTick(()=>setFocusExternal(el)));else if(e.target!==el&&isDirectChild(el,e.target))return!1;else return!0},uiNavEventsHandler=(el,e)=>{let uiNavEvent=e.detail.name;return EVENTS_UINAV_MAP.activate.includes(uiNavEvent)?okHandler(el,e):EVENTS_UINAV_MAP.deactivate.includes(uiNavEvent)?backHandler(el,e):generalHandler(el,e)};function addUINavEventListeners(el,binding,vnode){let{bubbleWhitelistEvents}=el[PROPERTY_NAME],generalUINavBinding={arg:[...EVENTS_UINAV_MAP.activate,...EVENTS_UINAV_MAP.deactivate,...EVENTS_UINAV_MAP.navigation].join(`,`),value:e=>uiNavEventsHandler(el,e)};BngOnUiNav_default.mounted(el,generalUINavBinding,vnode)}var ID=`__bngSound`,ID_STOP=`__bngSoundStop`,events$1={click:`click`,dblclick:`dblclick`,focus:`focus`,mouseenter:`mouseenter`};function handler(ev){let el=ev.currentTarget;if(el&&(el[ID]&&events$1[ev.type]&&Lua_default.ui_audio.playEventSound(el[ID],events$1[ev.type]),el[ID_STOP]))for(let event in delete el[ID_STOP],delete el[ID],events$1)el.removeEventListener(event,handler)}var BngSoundClass_default={mounted:(el,binding)=>{delete el[ID_STOP],el[ID]=binding.value,nextTick(()=>{for(let event in events$1)el.addEventListener(event,handler)})},updated:(el,binding)=>{el[ID]=binding.value},unmounted:el=>{el[ID_STOP]=!0}},marker=`__BNG_SD_INPUT`,inputTypes={singleLine:0,multiLine:1};function bindToInputs(elements){let inputs=Array.isArray(elements)?elements:[elements];for(let input of inputs){if(marker in input)continue;input[marker]=!0;let type,tag=input.tagName.toLowerCase();if(tag===`textarea`)type=inputTypes.multiLine;else if(tag===`input`&&[`text`,`number`,`password`,`search`].includes(input.type.toLowerCase()))type=inputTypes.singleLine;else continue;input.addEventListener(`focus`,()=>{let rect=input.getBoundingClientRect();console.log(`SteamDeck input focus:`,type,rect),Lua_default.Steam.showFloatingGamepadTextInput(type,rect.left,rect.top,rect.width,rect.height)})}}async function useSteamDeckInput(inputs){if(!inputs)throw Error(`inputs must be specified (ref, refs, element, elements)`);(await useSettingsAsync()).values.runningOnSteamDeck&&(isRef(inputs)?watch(inputs,bindToInputs,{immediate:!0}):bindToInputs(inputs))}var bridge$1,focused=!1,elms={},elmid=`__BNG_TEXT_INPUT`,focus=id=>async()=>{elms[id].active=!0,focused||=(await bridge$1.lua.setCEFTyping(!0),!0)},blur=id=>async()=>{elms[id].active=!1,focused&&(focused=Object.values(elms).some(e=>e.active),focused||await bridge$1.lua.setCEFTyping(!1))},BngTextInput_default={mounted(el){bridge$1||(bridge$1=useBridge(),bridge$1.events.on(`CEFTypingLostFocus`,()=>focused&&document.activeElement.blur()));let id=el[elmid]||(el[elmid]=uniqueId());elms[id]={el,active:!1,onFocus:focus(id),onBlur:blur(id)},el.addEventListener(`focus`,elms[id].onFocus),el.addEventListener(`blur`,elms[id].onBlur),useSteamDeckInput(el)},beforeUnmount(el){let id=el[elmid];elms[id]&&(el.removeEventListener(`focus`,elms[id].onFocus),el.removeEventListener(`blur`,elms[id].onBlur),elms[id].onBlur(),delete elms[id])}},DEFAULT_POSITION=`left`,TOOLTIP_ATTR_NAME=`data-bng-tooltip`,CONTENT_ATTR_NAME=`data-bng-tooltip-content`,ARROW_ATTR_NAME=`data-bng-tooltip-arrow`,SHOW_TOOLTIP_EVENTS=[`mouseover`,`focusin`],HIDE_TOOLTIP_EVENTS=[`mouseout`,`focusout`],DATA_PROP=`__bngTooltip`,POPOVER_CONTAINER=`.popover-container`,BngTooltip_default={beforeMount(el){initTooltipData(el)},mounted(el,binding,vnode){setupBindings(el,binding),setupTooltip(el),setListeners(el)},beforeUpdate(el,binding){setupBindings(el,binding),el[DATA_PROP].text===void 0?removeTooltip(el):updateTooltipElement(el)},updated(el){let data=el[DATA_PROP];data.update&&requestAnimationFrame(()=>data.update())},beforeUnmount(el){SHOW_TOOLTIP_EVENTS.forEach(eventName=>el.removeEventListener(eventName,el.__showTooltip)),HIDE_TOOLTIP_EVENTS.forEach(eventName=>el.removeEventListener(eventName,el.__hideTooltip));let data=el[DATA_PROP];data.dispose&&data.dispose(),removeTooltip(el)}};function setListeners(el){let data=el[DATA_PROP];data.showTooltip||(data.showTooltip=event=>{data.hideDelay&&=(clearTimeout(data.hideDelay),null),data.tooltipAnimationFrame&&=(cancelAnimationFrame(data.tooltipAnimationFrame),null),el.contains(event.target)&&!data.tooltipElRef.value&&queueTooltipUpdate(el,!0)},SHOW_TOOLTIP_EVENTS.forEach(eventName=>el.addEventListener(eventName,data.showTooltip,!0))),data.hideTooltip||(data.hideTooltip=event=>{data.tooltipAnimationFrame&&=(cancelAnimationFrame(data.tooltipAnimationFrame),null),!el.contains(event.relatedTarget)&&data.tooltipElRef.value&&queueTooltipUpdate(el,!1)},HIDE_TOOLTIP_EVENTS.forEach(eventName=>el.addEventListener(eventName,data.hideTooltip,!0)))}function setupBindings(el,binding){if(binding.value){let bindingValues=getBindings(binding);el[DATA_PROP].text=bindingValues.text,el[DATA_PROP].hideDelayTime=bindingValues.hideDelay,el[DATA_PROP].position=bindingValues.position,el[DATA_PROP].isBBCode=bindingValues.isBBCode,el[DATA_PROP].style=bindingValues.style}else resetTooltipData(el)}function queueTooltipUpdate(el,shouldShow){let data=el[DATA_PROP];data.tooltipAnimationFrame&&cancelAnimationFrame(data.tooltipAnimationFrame),data.pendingTooltipState=shouldShow,data.tooltipAnimationFrame=requestAnimationFrame(()=>{data.pendingTooltipState?showTooltip(el):hideTooltip(el),data.tooltipAnimationFrame=null,data.pendingTooltipState=null})}function showTooltip(el){let data=el[DATA_PROP];data.text&&(addTooltip(el),usePopover().show(data.popoverName,el))}function hideTooltip(el){let data=el[DATA_PROP],hideFn=()=>{removeTooltip(el)};data.hideDelayTime&&typeof data.hideDelayTime==`number`&&data.hideDelayTime>0?data.hideDelay=setTimeout(()=>{hideFn(),data.hideDelay=null},data.hideDelayTime):hideFn()}function setupTooltip(el){let data=el[DATA_PROP],popover=usePopover(),popoverInstance=popover.register(data.popoverName,data.tooltipElRef,data.position,{arrow:data.arrowElRef,offset:4});if(!popoverInstance){console.error(`Failed to register tooltip`);return}el[DATA_PROP].update=popoverInstance.update,el[DATA_PROP].dispose=()=>popover.unregister(data.popoverName),popover.bind(data.popoverName,el,{placement:data.position})}function updateTooltipElement(el){if(el[DATA_PROP].tooltipElRef.value&&el[DATA_PROP].tooltipElRef.value){let updatedContent=parseText(el[DATA_PROP].text,el[DATA_PROP].isBBCode),spanEl=el[DATA_PROP].tooltipElRef.value.querySelector(`span`);spanEl.innerHTML=updatedContent}}function addTooltip(el){let data=el[DATA_PROP];data.tooltipElRef.value=createTooltip(data);let popoverContainer=document.querySelector(POPOVER_CONTAINER);popoverContainer||=(console.warn(`Popover container not found, using parent element`),el.parentElement),el[DATA_PROP].arrowElRef.value=createArrow(),data.tooltipElRef.value.appendChild(el[DATA_PROP].arrowElRef.value),popoverContainer.appendChild(data.tooltipElRef.value)}function removeTooltip(el){let data=el[DATA_PROP];usePopover().hide(data.popoverName),data.tooltipElRef.value&&(data.tooltipElRef.value.remove(),data.tooltipElRef.value=null),data.update&&data.update()}function createTooltip(data){let container=document.createElement(`div`);return data.style&&Object.keys(data.style).forEach(key=>container.style.setProperty(key,data.style[key])),container.setAttribute(TOOLTIP_ATTR_NAME,``),container.appendChild(createContent(data.text,data.isBBCode)),container}function createContent(text,isBBCode){let content=document.createElement(`span`);return Object.assign(content.style,{}),content.innerHTML=parseText(text,isBBCode),content.setAttribute(CONTENT_ATTR_NAME,``),content}function createArrow(){let arrow$3=document.createElement(`span`);return Object.assign(arrow$3.style,{}),arrow$3.setAttribute(ARROW_ATTR_NAME,``),arrow$3}function parseText(text,isBBCode){return isBBCode?parse$1(text):text}var getBindings=binding=>{let position=binding.arg?binding.arg:DEFAULT_POSITION,hideDelay,text,isBBCode=!1,style={};return typeof binding.value==`object`?(hideDelay=binding.value?.hideDelay||0,text=binding.value?.text||void 0,isBBCode=binding.value?.isBBCode||!1,style=binding.value?.style||{}):text=binding.value,{text,position,hideDelay,isBBCode,style}};function initTooltipData(el){el[DATA_PROP]={popoverName:uniqueId(`bng-tooltip`),tooltipElRef:ref(null),arrowElRef:ref(null)},resetTooltipData(el)}function resetTooltipData(el){el[DATA_PROP].text=void 0,el[DATA_PROP].style={},el[DATA_PROP].isBBCode=!1,el[DATA_PROP].hideDelayTime=void 0,el[DATA_PROP].position=void 0,el[DATA_PROP].hideDelay=null,el[DATA_PROP].tooltipAnimationFrame=null}var reg=(elm,{value})=>nextTick(()=>elm&&wantsFocus(elm,value)),BngUiNavFocus_default={mounted:reg,updated:reg,beforeUnmount:unwantsFocus},registry,procEventNames=eventNames=>eventNames.split(`,`).map(name=>name.trim()).filter(Boolean),BngUiNavLabel_default={mounted(el,{arg:eventNames,value:label}){if(!eventNames){console.warn(`Usage: v-bng-ui-nav-label:back,menu="'Back'"`);return}registry||=useUiNavLabel(),label&&(eventNames=procEventNames(eventNames),registry.registerLabel(el,eventNames,label))},updated(el,{arg:eventNames,value:label}){eventNames&&(eventNames=procEventNames(eventNames),label?registry.registerLabel(el,eventNames,label):registry.clearLabels(el,eventNames))},beforeUnmount(el){let events$3=registry.getElementEvents(el);events$3.length>0&®istry.clearLabels(el,events$3)}},SCROLL_PROP=`__bngUiNavScroll`;function enableScroll(id,el){let tracker=useUINavTracker();tracker.addEvent(SCROLL_EVENT_H,id,el),tracker.addEvent(SCROLL_EVENT_V,id,el),tracker.addForceUnblock(SCROLL_EVENT_H,id),tracker.addForceUnblock(SCROLL_EVENT_V,id)}function disableScroll(id,el){let tracker=useUINavTracker();tracker.removeEvent(SCROLL_EVENT_H,id,el),tracker.removeEvent(SCROLL_EVENT_V,id,el),tracker.removeForceUnblock(SCROLL_EVENT_H,id),tracker.removeForceUnblock(SCROLL_EVENT_V,id)}var BngUiNavScroll_default={mounted(element,{arg,value,modifiers}){let prev=element[SCROLL_PROP]||{},dir={id:prev.id||uniqueId(SCROLL_PROP),forced:modifiers.force,enable:()=>enableScroll(dir.id,element),disable:()=>disableScroll(dir.id,element)};if(element[SCROLL_PROP]=dir,prev.forced&&(element.removeEventListener(`focusin`,prev.enable),element.removeEventListener(`focusout`,prev.disable)),typeof value==`boolean`&&!value){prev.id&&prev.disable(),dir.forced=!1;return}dir.forced?(element.setAttribute(SCROLL_FORCE_ATTR,``),dir.enable()):(element.setAttribute(SCROLL_ATTR,``),element.addEventListener(`focusin`,dir.enable),element.addEventListener(`focusout`,dir.disable))},beforeUnmount(element){let dir=element[SCROLL_PROP];dir&&(dir.forced||(element.removeEventListener(`focusin`,dir.enable),element.removeEventListener(`focusout`,dir.disable)),dir.disable(),delete element[SCROLL_PROP])}},observed=new WeakMap;function createObserver(root=null,rootMargin=`0px`){return new IntersectionObserver(entries=>{for(let entry of entries){let data=observed.get(entry.target);if(!data){entry.target.observer?.unobserve(entry.target);return}if(data.onChange)data.onChange(entry.isIntersecting);else{let displayValue=entry.isIntersecting?[`display`,``,``]:[`display`,`none`,`important`];entry.target.style.setProperty(...displayValue),entry.target.querySelectorAll(`*`).forEach(child=>{child.style.setProperty(...displayValue)})}}},{root,rootMargin,threshold:0})}var defaultObserver=createObserver(),_sfc_main$404={__name:`bngActionDrawer`,props:{actions:{type:Object,default:{allowOpenDrawer:!1}},skeletonItems:{type:Number,default:5},usePath:Boolean,alwaysShowBack:Boolean,itemWidth:Number,itemHeight:Number,itemMargin:Number,big:Boolean,position:String,blur:Boolean},emits:[`select`],setup(__props,{expose:__expose,emit:__emit}){let props=__props,emit$1=__emit;__expose({goBack:onBack});let expanded=ref(!1),current=ref(props.actions),lazyItem={label:`…`,icon:icons.stopwatchSectionOutlinedStart};function onSelect(item){(`items`in item||item.lazyLoadItems)&&(current.value&&addBack(current.value),current.value=item),emit$1(`select`,item)}let backState=computed(()=>{let disable=back.value.length===0||!(`items`in current.value);return{show:!disable||props.alwaysShowBack,disable}}),back=ref([]);function onBack(){current.value=null,onSelect(back.value.pop().data)}function addBack(prevItem){let backItem={index:back.value.length,label:prevItem.label,data:prevItem};props.usePath&&prevItem.items&&(backItem.items=prevItem.items.reduce((res,itm)=>[...res,{index:backItem.index+1,label:itm.label,data:itm}],[])),back.value.push(backItem)}let path=computed(()=>props.usePath?[...back.value,{current:!0,label:current.value.label,data:current.value}]:void 0);function onPath(item){item.current||(back.value.splice(item.index),current.value=null,onSelect(item.data))}return watch(()=>props.actions,val=>{back.value.splice(0),current.value=val}),(_ctx,_cache)=>(openBlock(),createBlock(unref(bngDrawer_default),{modelValue:expanded.value,"onUpdate:modelValue":_cache[0]||=$event=>expanded.value=$event,expandable:current.value.allowOpenDrawer,position:__props.position,blur:__props.blur},createSlots({"header-controls":withCtx(()=>[__props.usePath?(openBlock(),createBlock(unref(bngBreadcrumbs_default),{key:0,items:path.value,limit:`5`,onClick:onPath},null,8,[`items`])):backState.value.show?(openBlock(),createBlock(unref(bngButton_default),{key:1,accent:unref(ACCENTS).outlined,disabled:backState.value.disable,onClick:onBack},{default:withCtx(()=>[..._cache[1]||=[createTextVNode(`Back`,-1)]]),_:1},8,[`accent`,`disabled`])):createCommentVNode(``,!0),renderSlot(_ctx.$slots,`controls`)]),content:withCtx(()=>[withDirectives((openBlock(),createBlock(unref(bngList_default),{layout:expanded.value?unref(LIST_LAYOUTS).TILES:unref(LIST_LAYOUTS).RIBBON,big:__props.big,"target-width":__props.itemWidth,"target-height":__props.itemHeight,"target-margin":__props.itemMargin,"no-background":``},{default:withCtx(()=>[`items`in current.value?(openBlock(!0),createElementBlock(Fragment,{key:0},renderList(current.value.items,(item,index)=>renderSlot(_ctx.$slots,`action`,{item,select:onSelect,isLoading:!1,order:index})),256)):(openBlock(!0),createElementBlock(Fragment,{key:1},renderList(__props.skeletonItems,idx=>renderSlot(_ctx.$slots,`action`,{item:lazyItem,select:()=>{},isLoading:!0})),256))]),_:3},8,[`layout`,`big`,`target-width`,`target-height`,`target-margin`])),[[unref(BngDisabled_default),!(`items`in current.value)]])]),_:2},[__props.usePath?void 0:{name:`header`,fn:withCtx(()=>[createTextVNode(toDisplayString(current.value.label),1)]),key:`0`}]),1032,[`modelValue`,`expandable`,`position`,`blur`]))}},bngActionDrawer_default=_sfc_main$404,__plugin_vue_export_helper_default=(sfc,props)=>{let target=sfc.__vccOpts||sfc;for(let[key,val]of props)target[key]=val;return target},_hoisted_1$347={class:`bng-accordion-container`},_sfc_main$403={__name:`accordion`,props:{singular:Boolean,expanded:Boolean,disabled:Boolean,animated:Boolean,selectable:[Boolean,Object],selected:Boolean,provideParent:Boolean},emits:[`selected`],setup(__props,{emit:__emit}){let props=__props,counter$1=0,items$2=[],selopts=null,emit$1=__emit;watch(()=>props.singular,val=>val&&toggle(items$2.find(itm=>itm.expanded),!0)),watch(()=>props.expanded,val=>toggle(null,val)),watch(()=>props.animated,val=>{for(let itm of items$2)itm.animated=val},{immediate:!0}),watch(()=>props.disabled,val=>{for(let itm of items$2)itm.disabled=val},{immediate:!0}),watch(()=>props.selectable,val=>{val?(selopts={multi:!1},typeof val==`object`&&(selopts={selopts,...val})):selopts=null;for(let itm of items$2)itm.selectable=selopts},{immediate:!0}),watch(()=>props.selected,val=>select(null,val));function toggle(item=null,expanded=null){if(props.singular&&!item&&expanded){if(items$2.length===0)return;item=items$2[0]}for(let itm of items$2){let exp=!itm.expandedActual;item&&itm.id!==item.id?exp=props.singular?!1:itm.expandedActual:typeof expanded==`boolean`&&(exp=expanded),itm.expandedActual=exp}}provide(`accordion-item-toggle`,toggle);function select(item=null,selected=null){let state=[];for(let itm of items$2){let sel;sel=item&&itm.id!==item.id?selopts.multi?itm.selected:!1:typeof selected==`boolean`?selected:selopts.multi?!itm.selected:!0,itm.selected!==sel&&(itm.selected=sel,state.push(itm))}state.length>0&&emit$1(`selected`,state)}provide(`accordion-item-select`,select),props.provideParent&&inject(`accordion-item-childSelect`)(select);let waitForOptions=cb=>selopts?cb():setTimeout(()=>waitForOptions(cb),50);return provide(`accordion-item-register`,item=>{item.id=counter$1++,props.expanded&&(item.expanded=props.expanded),props.disabled&&(item.disabled=props.disabled),props.selectable&&(item.selectable=props.selectable),items$2.push(item),waitForOptions(()=>{props.singular&&item.expanded&&toggle(item,!0),item.selected&&select(item,!0)})}),provide(`accordion-item-unregister`,item=>{let idx=items$2.findIndex(itm=>itm.id===item.id);idx>-1&&items$2.splice(idx,1)}),(_ctx,_cache)=>withDirectives((openBlock(),createElementBlock(`div`,_hoisted_1$347,[renderSlot(_ctx.$slots,`default`,{},void 0,!0)])),[[unref(BngDisabled_default),__props.disabled]])}},accordion_default=__plugin_vue_export_helper_default(_sfc_main$403,[[`__scopeId`,`data-v-fcd1832d`]]),_hoisted_1$346={key:0,class:`bng-accitem-content`},_sfc_main$402={__name:`accordionItem`,props:{static:Boolean,expanded:Boolean,disabled:Boolean,animated:Boolean,selectable:{type:[Boolean,Object],default:!1},selected:Boolean,data:{},navigable:{type:[Boolean,Object],default:!1},arrowBig:Boolean,primaryAction:Function,secondaryAction:Function,primaryLabel:String,secondaryLabel:String,primaryHintInline:Boolean,secondaryHintInline:Boolean,expandHintInline:Boolean},emits:[`focus`,`unfocus`,`expanded`,`selected`],setup(__props,{expose:__expose,emit:__emit}){let{showIfController}=storeToRefs(controls_default()),navBlocker=useUINavBlocker(),props=__props,elCaption=ref(),elCaptionContent=ref(),elCaptionControls=ref(),hasFocus=ref(!1),icon=computed(()=>props.arrowBig?icons.arrowLargeRight:icons.arrowSmallRight),popTip=ref();watch([()=>hasFocus.value,()=>showIfController.value],()=>{hasFocus.value&&showIfController.value&&(props.primaryHintInline&&props.primaryAction||props.secondaryHintInline&&props.secondaryAction)?popTip.value.show(elCaption.value):popTip.value.isShown()&&popTip.value.hide()});let reg$1=inject(`accordion-item-register`),unreg=inject(`accordion-item-unregister`),toggle=inject(`accordion-item-toggle`),select=inject(`accordion-item-select`),opts=reactive({id:-1,captionClick:evt=>{props.primaryAction&&evt.fromController?props.primaryAction():opts.selectable?select(opts):opts.expandClick()},expandClick:()=>!props.static&&toggle(opts),static:props.static,expandedActual:props.expanded,disabled:props.disabled,animated:props.animated,selected:props.selected,selectable:props.selectable,navigable:{enabled:!1},data:props.data}),emit$1=__emit;__expose({captionClick:opts.captionClick,focus:()=>setFocusExternal(elCaption.value,!0,!1),captionElement:computed(()=>elCaption.value)}),watch(()=>props.static,val=>opts.static=val),watch(()=>props.expanded,val=>!opts.static&&toggle(opts,val)),watch(()=>props.disabled,val=>opts.disabled=val),watch(()=>opts.disabled,val=>!val&&props.disabled&&(opts.disabled=props.disabled)),watch(()=>props.animated,val=>opts.animated=val),watch(()=>props.selectable,val=>opts.selectable=val),watch(()=>props.selected,val=>opts.selected=val),watch(()=>opts.expandedActual,val=>{emit$1(`expanded`,!opts.static&&!opts.disabled&&val)}),watch(()=>props.data,val=>opts.data=val),watch(()=>props.navigable,val=>{if(typeof val!=`object`&&typeof val==`boolean`&&!val){opts.navigable={enabled:!1};return}opts.navigable={enabled:!0,scope:null,...typeof val==`object`?val:{}}},{immediate:!0}),opts.navigable.scope&&useUINavScope(opts.navigable.scope);let onFocus=evt=>{hasFocus.value=!0,navBlocker.blockOnly(opts.static?[`context`]:[]),emit$1(`focus`,evt)},onLoseFocus=evt=>{hasFocus.value=!1,navBlocker.clear(),emit$1(`unfocus`,evt)};return provide(`accordion-item-childSelect`,select$1=>(item,value)=>opts.selectable&&opts.selectable.multi&&select$1(item,value)),provide(`accordion-item-parent`,opts),onMounted(()=>reg$1(opts)),onBeforeUnmount(()=>{popTip.value.isShown()&&popTip.value.hide(),unreg(opts)}),(_ctx,_cache)=>withDirectives((openBlock(),createElementBlock(`div`,{class:normalizeClass({"bng-accitem":!0,"bng-accitem-normal":!opts.static&&!opts.selectable,"bng-accitem-static":opts.static,"bng-accitem-expandable":!opts.static,"bng-accitem-selectable":opts.selectable,"bng-accitem-expanded":!opts.static&&opts.expandedActual&&!opts.disabled,"bng-accitem-selected":opts.selected})},[withDirectives((openBlock(),createElementBlock(`div`,mergeProps({ref_key:`elCaption`,ref:elCaption,class:`bng-accitem-caption`,onClick:_cache[1]||=(...args)=>opts.captionClick&&opts.captionClick(...args),onFocus,onBlur:onLoseFocus},{"bng-nav-item":opts.navigable.enabled?!0:void 0,"bng-ui-scope":opts.navigable.scope||void 0}),[opts.static?createCommentVNode(``,!0):(openBlock(),createBlock(unref(bngIcon_default),{key:0,class:normalizeClass({"bng-accitem-caption-expander":!0,"bng-accitem-caption-expander-big":__props.arrowBig}),type:icon.value,onClick:withModifiers(opts.expandClick,[`stop`])},null,8,[`class`,`type`,`onClick`])),__props.expandHintInline&&!opts.static&&hasFocus.value&&unref(showIfController)?(openBlock(),createBlock(unref(bngBinding_default),{key:1,style:{"padding-right":`0.2em`},uiEvent:`context`,controller:``})):createCommentVNode(``,!0),createBaseVNode(`span`,{ref_key:`elCaptionContent`,ref:elCaptionContent,class:`bng-accitem-caption-content`},[renderSlot(_ctx.$slots,`caption`,{},()=>[_cache[2]||=createTextVNode(`Unnamed item`,-1)],!0)],512),_ctx.$slots.controls?(openBlock(),createElementBlock(`div`,{key:2,ref_key:`elCaptionControls`,ref:elCaptionControls,class:`bng-accitem-caption-controls`,onClick:_cache[0]||=withModifiers(()=>{},[`stop`])},[renderSlot(_ctx.$slots,`controls`,{},void 0,!0)],512)):createCommentVNode(``,!0),createVNode(unref(bngPopoverContent_default),{ref_key:`popTip`,ref:popTip,placement:`right`},{default:withCtx(()=>[__props.primaryHintInline&&__props.primaryAction?(openBlock(),createBlock(unref(bngBinding_default),{key:0,uiEvent:`ok`,controller:``})):createCommentVNode(``,!0),__props.secondaryHintInline&&__props.secondaryAction?(openBlock(),createBlock(unref(bngBinding_default),{key:1,uiEvent:`action_2`,controller:``})):createCommentVNode(``,!0)]),_:1},512)],16)),[[unref(BngOnUiNav_default),void 0,`ok`,{asMouse:!0,focusRequired:!0}],[unref(BngOnUiNav_default),__props.secondaryAction?__props.secondaryAction:void 0,`action_2`,{focusRequired:!0}],[unref(BngOnUiNav_default),!opts.static&&opts.navigable.enabled?opts.expandClick:void 0,`context`,{focusRequired:!0}],[unref(BngUiNavLabel_default),__props.primaryLabel||`ui.inputActions.menu.menu_item_select.title`,`ok`],[unref(BngUiNavLabel_default),__props.secondaryLabel,`action_2`],[unref(BngUiNavLabel_default),_ctx.$tt(`ui.common.expand`)+`/`+_ctx.$tt(`ui.common.collapse`),`context`]]),createVNode(Transition,{name:opts.animated?`bng-acc-trans`:null},{default:withCtx(()=>[!opts.static&&opts.expandedActual&&!opts.disabled?(openBlock(),createElementBlock(`div`,_hoisted_1$346,[renderSlot(_ctx.$slots,`default`,{},()=>[_cache[3]||=createTextVNode(`Empty`,-1)],!0)])):createCommentVNode(``,!0)]),_:3},8,[`name`])],2)),[[unref(BngDisabled_default),opts.disabled]])}},accordionItem_default=__plugin_vue_export_helper_default(_sfc_main$402,[[`__scopeId`,`data-v-dd6087ee`]]),_sfc_main$401={__name:`accordionTree`,props:{data:[Array,Object],dataField:{type:String,required:!0},propsField:String,contentField:String,selectable:{type:[Boolean,Object],default:!1},selectedField:String,isTreeElement:Boolean},emits:[`selected`],setup(__props,{emit:__emit}){let props=__props,dataView=computed(()=>props.data&&(props.data[props.dataField]||props.data)||[]),emit$1=__emit;props.isTreeElement||(watch(()=>dataView.value,refreshSelected),watch(()=>props.selectedField&&props.selectable&&props.selectable.multi,refreshSelected),refreshSelected());let prevState=[];function refreshSelected(){if(!props.selectedField||!props.selectable||!props.selectable.multi)return;let state=[];function deepScan(arr){for(let itm of arr){let data=itm.data||itm;data[props.selectedField]&&state.push({data,selected:!0}),data[props.dataField]&&deepScan(data[props.dataField])}}deepScan(dataView.value),selected(state)}function selected(state){if(!props.isTreeElement){if(!props.selectable.multi){prevState=prevState.filter(itm=>itm.selected);for(let itm of prevState)itm.selected&&(itm.item.selected=!1,props.selectedField&&(itm.item.data[props.selectedField]=!1),state.includes(itm.item)||state.push(itm.item));prevState=state.map(item=>({selected:!!item.selected,item}))}if(props.selectedField){function deepSet(arr,value=void 0){for(let itm of arr){let val=typeof value==`boolean`?value:itm.selected,data=itm.data||itm;data[props.selectedField]=val,data[props.dataField]&&deepSet(data[props.dataField])}}deepSet(state)}}emit$1(`selected`,state)}function branchSelected(state){props.isTreeElement?emit$1(`selected`,state):selected(state)}return(_ctx,_cache)=>dataView.value.length>0?(openBlock(),createBlock(unref(accordion_default),{key:0,class:`acctree`,selectable:__props.selectable,"provide-parent":__props.isTreeElement,onSelected:selected},{default:withCtx(()=>[(openBlock(!0),createElementBlock(Fragment,null,renderList(dataView.value,entry=>(openBlock(),createBlock(unref(accordionItem_default),mergeProps({ref_for:!0},__props.propsField?entry[__props.propsField]:void 0,{selected:__props.selectedField?entry[__props.selectedField]:void 0,static:(!entry[__props.dataField]||entry[__props.dataField].length===0)&&(!__props.contentField||!entry[__props.contentField]),data:entry}),{caption:withCtx(()=>[renderSlot(_ctx.$slots,`caption`,{entry},void 0,!0)]),controls:withCtx(()=>[renderSlot(_ctx.$slots,`controls`,{entry},void 0,!0)]),default:withCtx(()=>[__props.contentField&&entry[__props.contentField]?renderSlot(_ctx.$slots,`default`,{key:0,entry},void 0,!0):createCommentVNode(``,!0),entry[__props.dataField]&&entry[__props.dataField].length>0?(openBlock(),createBlock(unref(accordionTree_default),mergeProps({key:1,ref_for:!0},props,{data:entry,"is-tree-element":!0,onSelected:branchSelected}),{caption:withCtx(({entry:entry$1})=>[renderSlot(_ctx.$slots,`caption`,{entry:entry$1},void 0,!0)]),controls:withCtx(({entry:entry$1})=>[renderSlot(_ctx.$slots,`controls`,{entry:entry$1},void 0,!0)]),_:2},1040,[`data`])):createCommentVNode(``,!0)]),_:2},1040,[`selected`,`static`,`data`]))),256))]),_:3},8,[`selectable`,`provide-parent`])):createCommentVNode(``,!0)}},accordionTree_default=__plugin_vue_export_helper_default(_sfc_main$401,[[`__scopeId`,`data-v-2ad1085d`]]),_hoisted_1$345={class:`slotted`},_sfc_main$400={__name:`aspectRatio`,props:{ratio:{type:String,default:`16:9`},imageMode:{type:String,default:`cover`,validator:value=>[`cover`,`contain`].includes(value)},image:{type:String,default:null},externalImage:{type:String,default:null}},setup(__props){useCssVars(_ctx=>({v711986eb:__props.imageMode}));let placeholderImageURL=getAssetURL(`images/noimage.png`),slots=useSlots(),props=__props,padding=computed(()=>{if(!props.ratio)return`56.25%`;let[width$1,height$1]=props.ratio.split(`:`).map(Number);return`${height$1/width$1*100}%`}),backgroundStyle=computed(()=>!props.image&&!props.externalImage?{"--padding":padding.value,backgroundImage:`none`}:props.image||props.externalImage?{"--padding":padding.value,backgroundImage:`url("${props.externalImage?props.externalImage:getAssetURL(props.image)}")`}:slots.default?{"--padding":padding.value,backgroundImage:`url("${placeholderImageURL}")`}:{});return(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,{class:`aspect-ratio`,style:normalizeStyle(backgroundStyle.value)},[createBaseVNode(`div`,_hoisted_1$345,[renderSlot(_ctx.$slots,`default`,{},void 0,!0)])],4))}},aspectRatio_default=__plugin_vue_export_helper_default(_sfc_main$400,[[`__scopeId`,`data-v-83698898`]]),_hoisted_1$344=[`data-carousel-item`],_sfc_main$399={__name:`carouselItem`,props:{value:{type:[String,Number],required:!0}},setup(__props){return(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,{class:`bng-carousel-item`,"data-carousel-item":__props.value},[renderSlot(_ctx.$slots,`default`,{},void 0,!0)],8,_hoisted_1$344))}},carouselItem_default=__plugin_vue_export_helper_default(_sfc_main$399,[[`__scopeId`,`data-v-babc74fb`]]),_hoisted_1$343={key:0,class:`navigation`},_hoisted_2$271=[`onClick`],TRANSITION_TYPES=[`fade`],_sfc_main$398={__name:`carousel`,props:{items:{type:Array,required:!0},current:{type:[String,Number],default:0},vertical:Boolean,loop:{type:Boolean,default:!0},transition:Boolean,transitionType:{type:String,default:`fade`,validator:value=>TRANSITION_TYPES.includes(value)},transitionTime:{type:Number,default:3e3},showNav:{type:Boolean,default:!0},parent:Object},setup(__props,{expose:__expose}){let props=__props,transitionTimer,carouselRoot=ref(null),carousel=ref(null),currentIndex=ref(props.current);computed(()=>``);let navState=reactive({selected:null}),showSlide=value=>{let slideIndex=parseInt(value);currentIndex.value=slideIndex,navState.selected=slideIndex,setTransition()},navShown=computed(()=>props.showNav&&!props.parent),children=[],childIndex=child=>children.findIndex(itm=>itm.element===child.element),addChild=child=>{childIndex(child)===-1&&children.push(child)},remChild=child=>{let idx=childIndex(child);idx>-1&&children.splice(idx,1)},tryParent=(_retry=0)=>{if(props.parent.addChild)props.parent.addChild(exposed);else if(_retry<100){let unwatch=watch(()=>props.parent.addChild,()=>{unwatch(),tryParent(++_retry)})}};watch(()=>props.parent,tryParent),watch(()=>navState.selected,sel=>{for(let child of children)child.showSlide&&child.showSlide(sel)}),onMounted(()=>{setTransition(),props.parent&&tryParent()}),onBeforeUnmount(()=>{transitionTimer&&=(clearInterval(transitionTimer),null),props.parent&&props.parent.remChild&&props.parent.remChild(exposed)});function showPrevious(){if(props.parent)return;let prev;currentIndex.value===0&&props.loop?prev=props.items.length-1:currentIndex.value>0&&(prev=currentIndex.value-1),prev!==void 0&&(navState.selected=prev,currentIndex.value=prev,setTransition())}function showNext(){if(props.parent)return;let next=getNext();next>-1&&(navState.selected=next,currentIndex.value=next,setTransition())}function setTransition(){transitionTimer&&clearInterval(transitionTimer),transitionTimer=setInterval(()=>{let next=getNext();next>-1&&(currentIndex.value=next)},props.transitionTime)}function getNext(){return currentIndex.value===props.items.length-1&&props.loop?0:currentIndex.value(openBlock(),createElementBlock(`div`,{ref_key:`carouselRoot`,ref:carouselRoot,class:normalizeClass({"bng-carousel":!0,"carousel-vertical":__props.vertical,[`transition-${__props.transitionType}`]:!0})},[createBaseVNode(`div`,{ref_key:`carousel`,ref:carousel,class:`carousel-content`},[createVNode(Transition,{name:__props.transitionType},{default:withCtx(()=>[(openBlock(),createBlock(carouselItem_default,{key:currentIndex.value,class:`carousel-slide`,value:currentIndex.value},{default:withCtx(()=>[renderSlot(_ctx.$slots,`item`,{item:__props.items[currentIndex.value],index:currentIndex.value},()=>[createTextVNode(toDisplayString(__props.items[currentIndex.value]),1)],!0)]),_:3},8,[`value`]))]),_:3},8,[`name`])],512),renderSlot(_ctx.$slots,`navigation`,{},()=>[navShown.value&&__props.items&&__props.items.length>1?(openBlock(),createElementBlock(`div`,_hoisted_1$343,[(openBlock(!0),createElementBlock(Fragment,null,renderList(__props.items,(item,index)=>(openBlock(),createElementBlock(`div`,{class:normalizeClass([`navigation-item`,{active:index===currentIndex.value}]),key:item.value,onClick:$event=>showSlide(index)},null,10,_hoisted_2$271))),128))])):createCommentVNode(``,!0)],!0)],2))}},carousel_default=__plugin_vue_export_helper_default(_sfc_main$398,[[`__scopeId`,`data-v-f54192e0`]]),_hoisted_1$342={key:0,class:`drawer-header`},_hoisted_2$270={key:1,class:`drawer-content`},_hoisted_3$236={key:2,class:`drawer-header`};const DRAWER_POSITION={bottom:`bottom`,top:`top`,left:`left`,right:`right`};var _sfc_main$397={__name:`drawer`,props:mergeModels({blur:Boolean,position:{type:String,default:DRAWER_POSITION.bottom,validator:val=>Object.values(DRAWER_POSITION).includes(val)}},{modelValue:{type:Boolean},modelModifiers:{}}),emits:mergeModels([`change`],[`update:modelValue`]),setup(__props,{emit:__emit}){let emit$1=__emit,expanded=useModel(__props,`modelValue`);watch(()=>expanded.value,val=>emit$1(`change`,val));let slots=useSlots(),expandedContent=computed(()=>expanded.value&&`expanded-content`in slots),hasAnyContent=computed(()=>expandedContent.value||`content`in slots);return(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,{class:normalizeClass({"bng-drawer":!0,[`drawer-pos-${__props.position}`]:!0,"drawer-expanded":expanded.value})},[__props.position===`bottom`||__props.position===`right`?withDirectives((openBlock(),createElementBlock(`div`,_hoisted_1$342,[renderSlot(_ctx.$slots,`header`,{},void 0,!0)])),[[unref(BngBlur_default),__props.blur]]):createCommentVNode(``,!0),hasAnyContent.value?withDirectives((openBlock(),createElementBlock(`div`,_hoisted_2$270,[expandedContent.value?renderSlot(_ctx.$slots,`expanded-content`,{key:0},void 0,!0):renderSlot(_ctx.$slots,`content`,{key:1},void 0,!0)])),[[unref(BngBlur_default),__props.blur]]):createCommentVNode(``,!0),__props.position===`top`||__props.position===`left`?withDirectives((openBlock(),createElementBlock(`div`,_hoisted_3$236,[renderSlot(_ctx.$slots,`header`,{},void 0,!0)])),[[unref(BngBlur_default),__props.blur]]):createCommentVNode(``,!0)],2))}},drawer_default=__plugin_vue_export_helper_default(_sfc_main$397,[[`__scopeId`,`data-v-8023232b`]]),_sfc_main$396={__name:`dynamicComponent`,props:{template:String,translateId:String,translateContext:Boolean,bbcode:Boolean,useComponents:{type:Boolean,default:!0},extraComponents:{type:Object,default:()=>({})}},setup(__props){let ALL_COMPONENTS=Object.fromEntries(Object.entries({...base_exports,...utility_exports}).filter(([name])=>name!==`DEMOS`)),attrs=useAttrs(),props=__props,template=computed(()=>{let res=props.template;return props.translateId&&(res=props.translateContext?$translate.contextTranslate(props.translateId,!0):$translate.instant(props.translateId)),res&&props.bbcode&&(res=parse$1(res)),res||``}),makeComponent=computed(()=>defineComponent({template:template.value,components:{...props.useComponents&&ALL_COMPONENTS,...props.extraComponents},data(){return attrs}}));return(_ctx,_cache)=>template.value&&makeComponent.value?(openBlock(),createBlock(resolveDynamicComponent(makeComponent.value),{key:0})):createCommentVNode(``,!0)}},dynamicComponent_default=_sfc_main$396,_hoisted_1$341={class:`shelf-wrapper`},_hoisted_2$269=[`disabled`],_hoisted_3$235=[`disabled`],storageKey=`bngshelf`,_sfc_main$395={__name:`shelf`,props:mergeModels({saveName:{type:String,default:null},limit:{type:Number,default:5,validator:val=>val>2&&val%2==1},fade:{type:Boolean,default:!1},showExtra:{type:Boolean,default:!0},neighborsFlatten:{type:Boolean,default:!1},neighborsScale:{type:Number,default:1},keepNeighborsAspectRatio:{type:Boolean,default:!1},noLoop:{type:Boolean,default:!1},navShown:{type:Boolean,default:!1},inward:{type:Number,default:0,validator:val=>val>=0&&val<=1}},{modelValue:{type:Number,default:0},modelModifiers:{}}),emits:mergeModels([`change`,`click`],[`update:modelValue`]),setup(__props,{expose:__expose,emit:__emit}){let selectedIndex=useModel(__props,`modelValue`),props=__props,emit$1=__emit,ready=ref(!1),slots=useSlots(),containerRef=ref(null),shelfItems=ref([]),displayItems=ref([]),isAnimating=ref(!1),itemIdCounter=0,lastValidIndex=0,isReverting=!1,isPrevDisabled=computed(()=>isAnimating.value||props.noLoop&&selectedIndex.value===0),isNextDisabled=computed(()=>isAnimating.value||props.noLoop&&selectedIndex.value===shelfItems.value.length-1);watch(selectedIndex,index=>{if(!isReverting){if(index=parseInt(index,10),isNaN(index)||index<0||shelfItems.value.length>0&&index>=shelfItems.value.length){isReverting=!0,selectedIndex.value=lastValidIndex,isReverting=!1;return}lastValidIndex=index,ready.value&&buildDisplayItems()}},{immediate:!0});let timings={single:400,multiStart:200,multiMiddle:200,multiEnd:200};watch(()=>slots.default?.(),update$6,{immediate:!0});function update$6(vnodes){if(ready.value){if(vnodes===void 0&&(vnodes=slots.default?.()),Array.isArray(vnodes)||(vnodes=[]),shelfItems.value=vnodes.reduce((res,vnode)=>typeof vnode.type==`symbol`&&vnode.type.toString()===`Symbol(v-fgt)`?(res.push(...vnode.children),res):(res.push(vnode),res),[]),props.saveName){let val=localStorage.getItem(`${storageKey}-${props.saveName}`);if(val!==null){let idx=parseInt(val,10);!isNaN(idx)&&idx>=0&&idxhalfLimit)continue;let itemIndex=selectedIndex.value+offset$2;if(props.noLoop){if(itemIndex<0||itemIndex>=shelfItems.value.length)continue}else itemIndex<0?itemIndex=shelfItems.value.length+itemIndex:itemIndex>=shelfItems.value.length&&(itemIndex-=shelfItems.value.length);items$2.push({vnode:shelfItems.value[itemIndex],originalIndex:itemIndex,position:offset$2,id:++itemIdCounter,style:getItemStyle(offset$2,`normal`)})}displayItems.value=items$2}function getItemStyle(position,state=`normal`){let absPosition=Math.abs(position),halfLimit=~~(props.limit/2),isExtraItem=absPosition>halfLimit,factor=halfLimit>0?absPosition/halfLimit:1,leftPercentage;if(leftPercentage=isExtraItem?(position<0?0:props.limit-1)/(props.limit-1)*100:(position+halfLimit)/(props.limit-1)*100,position!==0&&props.inward>0){let pullToCenter=(50-leftPercentage)*props.inward*factor;leftPercentage+=pullToCenter}let rotateY=factor*-30*Math.sign(position),translateZ=0,scaleX=1,scaleY=1,brightness=1;if(position!==0){if(translateZ=-100*factor,props.keepNeighborsAspectRatio){let scale=Math.max(.6,1-factor*.4)*props.neighborsScale;scaleX=scale,scaleY=scale}else scaleX=Math.max(.4,1-factor*.6)*props.neighborsScale,scaleY=Math.max(.6,1-factor*.4)*props.neighborsScale;brightness=Math.max(.5,1-factor*.5),props.neighborsFlatten&&(rotateY=0)}let opacity=1;return state===`entering`||state===`exiting`?(opacity=.1,translateZ=-100*(absPosition/halfLimit),leftPercentage+=2*Math.sign(position)):isExtraItem?opacity=.2:props.fade&&position!==0&&(opacity=Math.max(.4,1-absPosition*.3)),{left:`${leftPercentage}%`,transform:`translateX(-50%) translateY(-50%) translateZ(${translateZ}px) rotateY(${rotateY}deg) scale(${scaleX}, ${scaleY})`,filter:`brightness(${brightness})`,transition:`all 400ms cubic-bezier(0.25, 0.8, 0.25, 1)`,opacity,zIndex:isExtraItem?10-absPosition:100-absPosition}}let abortAnimation=!1;async function toIndex(targetIndex){if(!ready.value||selectedIndex.value===targetIndex||typeof targetIndex!=`number`||targetIndex<0||targetIndex>=shelfItems.value.length)return;if(isAnimating.value)for(abortAnimation=!0;abortAnimation;)await sleep(20);let prevIndex=selectedIndex.value,steps=calculateSteps(selectedIndex.value,targetIndex);if(steps.length!==0){isAnimating.value=!0;try{let stepTimings=calculateStepTimings(steps.length);for(let i=0;i{selectedIndex.value===targetIndex&&setFocusExternal(containerRef.value.querySelector(`[data-shelf-index="${targetIndex}"]`))})}finally{abortAnimation=!1,isAnimating.value=!1}props.saveName&&localStorage.setItem(`${storageKey}-${props.saveName}`,targetIndex.toString()),emit$1(`change`,targetIndex,prevIndex)}}let onFocus=index=>selectedIndex.value!==index&&toIndex(index);function onClick(index,event){selectedIndex.value===index?emit$1(`click`,event,index):toIndex(index)}function calculateStepTimings(stepCount){return stepCount===1?[timings.single]:Array.from({length:stepCount},(_,i)=>i===0?timings.multiStart:i===stepCount-1?timings.multiEnd:timings.multiMiddle)}function calculateSteps(fromIndex,toIndex$1){let targetItemIndex=displayItems.value.findIndex(item=>item.originalIndex===toIndex$1),steps=[];if(targetItemIndex===-1){let current=fromIndex;for(;current!==toIndex$1;){let totalItems=shelfItems.value.length;props.noLoop?toIndex$1>current?current+=1:--current:current=(toIndex$1-current+totalItems)%totalItems<=(current-toIndex$1+totalItems)%totalItems?(current+1)%totalItems:(current-1+totalItems)%totalItems,steps.push(current)}}else{let targetPosition=displayItems.value[targetItemIndex].position;if(targetPosition!==0){let direction$1=targetPosition>0?1:-1,stepsNeeded=Math.abs(targetPosition),current=fromIndex;for(let i=0;i0?current+=1:--current:current=direction$1>0?(current+1)%shelfItems.value.length:(current-1+shelfItems.value.length)%shelfItems.value.length,steps.push(current)}}return steps}async function animateToStep(stepIndex,stepTiming){let halfLimit=Math.floor(props.limit/2),currentIndex=selectedIndex.value,actualDirection=0;if(props.noLoop)actualDirection=stepIndex>currentIndex?1:-1;else{let totalItems=shelfItems.value.length;actualDirection=(stepIndex-currentIndex+totalItems)%totalItems<=(currentIndex-stepIndex+totalItems)%totalItems?1:-1}let newItems=[];if(actualDirection>0){for(let i=0;i=shelfItems.value.length?rightmostIndex-shelfItems.value.length:rightmostIndex),wrappedIndex>=0&&wrappedIndex=0&&wrappedIndexhalfLimit;newItems.push({...currentItem,position:newPosition,style:getItemStyle(newPosition,isExiting?`exiting`:`normal`)})}}displayItems.value=newItems;let delay=stepTiming/2;await sleep(delay),displayItems.value=displayItems.value.map(item=>item.style.opacity===.1&&(item.position===halfLimit||item.position===-halfLimit)?{...item,style:getItemStyle(item.position,`normal`)}:item),await new Promise(resolve$1=>setTimeout(resolve$1,delay))}function navigateNext$1(){isAnimating.value||props.noLoop&&selectedIndex.value===shelfItems.value.length-1||toIndex((selectedIndex.value+1)%shelfItems.value.length)}function navigatePrev(){isAnimating.value||props.noLoop&&selectedIndex.value===0||toIndex(selectedIndex.value===0?shelfItems.value.length-1:selectedIndex.value-1)}__expose({toIndex,next:navigateNext$1,prev:navigatePrev,isSelected:evt=>{let elm=evt.target.closest(`[data-shelf-index]`);if(!elm)return!1;let idx=parseInt(elm.getAttribute(`data-shelf-index`),10);return!isNaN(idx)&&selectedIndex.value===idx}}),onMounted(()=>{ready.value=!0,nextTick(update$6)});function getActiveItem(){let active=document.activeElement;return String(active.dataset.shelfIndex)===String(selectedIndex.value)?null:containerRef.value.querySelector(`[data-shelf-index="${selectedIndex.value}"]`)}return(_ctx,_cache)=>withDirectives((openBlock(),createElementBlock(`div`,_hoisted_1$341,[withDirectives((openBlock(),createElementBlock(`div`,{ref_key:`containerRef`,ref:containerRef,class:`shelf-container`},[(openBlock(!0),createElementBlock(Fragment,null,renderList(displayItems.value,item=>(openBlock(),createElementBlock(`div`,{key:`item-${item.originalIndex}-${item.id}`,class:`shelf-item`,style:normalizeStyle(item.style)},[(openBlock(),createBlock(resolveDynamicComponent(item.vnode),{"data-shelf-index":item.originalIndex,onClick:$event=>onClick(item.originalIndex,$event),onFocus:$event=>onFocus(item.originalIndex),onUinavFocus:$event=>onFocus(item.originalIndex)},null,40,[`data-shelf-index`,`onClick`,`onFocus`,`onUinavFocus`]))],4))),128))])),[[unref(BngFocusCapture_default),getActiveItem,`101`]]),__props.navShown?(openBlock(),createElementBlock(`button`,{key:0,class:`shelf-nav shelf-nav-prev`,onClick:navigatePrev,disabled:isPrevDisabled.value},[createVNode(unref(bngIcon_default),{type:unref(icons).arrowLargeLeft},null,8,[`type`])],8,_hoisted_2$269)):createCommentVNode(``,!0),__props.navShown?(openBlock(),createElementBlock(`button`,{key:1,class:`shelf-nav shelf-nav-next`,onClick:navigateNext$1,disabled:isNextDisabled.value},[createVNode(unref(bngIcon_default),{type:unref(icons).arrowLargeRight},null,8,[`type`])],8,_hoisted_3$235)):createCommentVNode(``,!0)],512)),[[vShow,displayItems.value.length>0]])}},shelf_default=__plugin_vue_export_helper_default(_sfc_main$395,[[`__scopeId`,`data-v-0109573f`]]),_sfc_main$394={__name:`slotSwitcher`,props:{slotId:{type:String,default:`default`}},setup(__props){return(_ctx,_cache)=>renderSlot(_ctx.$slots,__props.slotId,normalizeProps(guardReactiveProps(_ctx.$attrs)))}},slotSwitcher_default=_sfc_main$394,_sfc_main$393={__name:`tab`,props:{heading:String,selected:Boolean},setup(__props){return(_ctx,_cache)=>renderSlot(_ctx.$slots,`default`,{tabHeading:__props.heading,tabSelected:__props.selected})}},tab_default=_sfc_main$393,_hoisted_1$340={class:`tab-list`},_sfc_main$392={__name:`tabList`,setup(__props){let tabs=inject(`tabs`),selectTab=inject(`selectTab`),tabHeaderClasses=tab=>({"tab-item":!0,"tab-active-tab":tab.active,"no-hover":tab.active});function handleTabSelect(index,event){let buttonElement=event.currentTarget,hasFocusVisible=document.activeElement&&document.activeElement.classList.contains(`focus-visible`);selectTab(index),hasFocusVisible&&nextTick(()=>{setFocusExternal(buttonElement)})}return(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$340,[(openBlock(!0),createElementBlock(Fragment,null,renderList(unref(tabs),(tab,i)=>(openBlock(),createBlock(unref(bngButton_default),{key:i,accent:(tab.active,`ghost`),class:normalizeClass(tabHeaderClasses(tab)),tabindex:`0`,"bng-nav-item":``,onClick:$event=>handleTabSelect(tab.index,$event)},{default:withCtx(()=>[createTextVNode(toDisplayString(tab.heading),1)]),_:2},1032,[`accent`,`class`,`onClick`]))),128))]))}},tabList_default=__plugin_vue_export_helper_default(_sfc_main$392,[[`__scopeId`,`data-v-5c322d77`]]),_hoisted_1$339={class:`tab-container`},_sfc_main$391={__name:`tabs`,props:{selectedIndex:{type:Number,default:-1}},emits:[`change`],setup(__props,{expose:__expose,emit:__emit}){let emit$1=__emit,props=__props,ready=ref(!1),slots=useSlots(),tabListStart=shallowRef(),tabListEnd=shallowRef(),tabsList=ref(),tabsContent=ref([]),selectedIndex=ref(-1),isTabList=vnode=>typeof vnode.type==`object`&&vnode.type.__name===tabList_default.__name;provide(`tabs`,tabsList),watch(()=>slots.default?.(),update$6,{immediate:!0}),watch(()=>props.selectedIndex,index=>selectTab(index));function update$6(vnodes){if(!ready.value)return;vnodes===void 0&&(vnodes=slots.default?.()),Array.isArray(vnodes)||(vnodes=[]);let tabListIndex=vnodes.findIndex(vn=>isTabList(vn));tabListStart.value=tabListIndex===0?vnodes[tabListIndex]:tabList_default,tabListEnd.value=tabListIndex===vnodes.length-1?vnodes[tabListIndex]:null,tabsContent.value=vnodes.filter(vn=>!isTabList(vn)).reduce((res,vnode)=>typeof vnode.type==`symbol`&&vnode.type.toString()===`Symbol(v-fgt)`?(res.push(...vnode.children),res):(res.push(vnode),res),[]),tabsList.value=tabsContent.value.map((tab,index)=>({index,heading:tab.props?.[`tab-heading`]||tab.props?.tabHeading||`Tab ${index+1}`,active:selectedIndex.value===-1?props.selectedIndex===index||!!tab.props?.[`tab-selected`]||!!tab.props?.tabSelected:selectedIndex.value===index}));let activeIndex=tabsList.value.findIndex(tab=>tab.active);selectTab(activeIndex>-1?activeIndex:0)}function selectTab(index){if(!ready.value||typeof index!=`number`||index<0||index>=tabsList.value.length||selectedIndex.value===index)return;let prevTab=tabsList.value[selectedIndex.value];tabsList.value.forEach(tab=>{tab.active=tab.index===index}),selectedIndex.value=index,emit$1(`change`,tabsList.value[index],prevTab)}return provide(`selectTab`,selectTab),__expose({goNext:()=>selectTab((selectedIndex.value+1)%tabsList.value.length),goPrev:()=>selectTab(Math.abs(selectedIndex.value-1)%tabsList.value.length),selectTab}),onMounted(()=>{ready.value=!0,nextTick(update$6)}),(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$339,[tabListStart.value?(openBlock(),createBlock(resolveDynamicComponent(tabListStart.value),{key:0})):createCommentVNode(``,!0),tabsContent.value[selectedIndex.value]?(openBlock(),createBlock(resolveDynamicComponent(tabsContent.value[selectedIndex.value]),{key:1,class:`tab-content`})):createCommentVNode(``,!0),tabListEnd.value?(openBlock(),createBlock(resolveDynamicComponent(tabListEnd.value),{key:2})):createCommentVNode(``,!0)]))}},tabs_default=__plugin_vue_export_helper_default(_sfc_main$391,[[`__scopeId`,`data-v-2ff63a4f`]]),_sfc_main$390={__name:`textScroller`,props:{scrollSpeed:{type:Number,default:3},initialPause:{type:Number,default:1},endingPause:{type:Number,default:1},fadeDuration:{type:Number,default:.2},watchContent:{type:Boolean,default:!1}},setup(__props){let props=__props,slots=useSlots(),events$3={start:[`uinav-focus`,`focus`,`mouseenter`],stop:[`uinav-blur`,`blur`,`mouseleave`]},elContainer=ref(null),elText=ref(null),scrollDistance=ref(0),translateX=ref(0),opacity=ref(1),isActive=ref(!1),isScrolling$1=ref(!1),styleOverrides={"button-icon":`.bng-button.l-icon, .bng-button.r-icon`},overrideClasses=ref([]),parentElement=null,fontSize=ref(16),scrollSpeed=computed(()=>props.scrollSpeed*fontSize.value),animTimer=null,animTimeout=(func,ms)=>(animTimer&&=(clearTimeout(animTimer),null),typeof func==`function`?(animTimer=setTimeout(()=>{animTimer=null,isScrolling$1.value&&func()},ms),animTimer):null),scrollStyles=computed(()=>({transform:`translateX(${translateX.value}px)`,opacity:opacity.value,transition:`opacity ${props.fadeDuration}s linear`+(isScrolling$1.value&&opacity.value>0?`, transform ${scrollDistance.value/scrollSpeed.value}s linear`:``)}));function animLoop(){isScrollable()&&(scrollDistance.value=getSize(),!(scrollDistance.value<=0)&&(opacity.value=1,animTimeout(()=>{translateX.value=-scrollDistance.value,animTimeout(()=>{opacity.value=0,animTimeout(()=>{translateX.value=0,nextTick(animLoop)},props.fadeDuration*1e3)},scrollDistance.value/scrollSpeed.value*1e3+props.endingPause*1e3)},Math.max(props.initialPause,props.fadeDuration)*1e3)))}function isScrollable(){if(!elContainer.value||!elText.value)return!1;let containerWidth=elContainer.value.clientWidth;return elText.value.scrollWidth>containerWidth}function getSize(){if(!elContainer.value||!elText.value)return 0;let containerWidth=elContainer.value.clientWidth,textWidth=elText.value.scrollWidth;return Math.max(0,textWidth-containerWidth)}function animStart(){isActive.value=!0,isScrollable()&&(isScrolling$1.value=!0,translateX.value=0,opacity.value=1,animLoop())}function animStop(restartAnim=!1){isActive.value=!1,isScrolling$1.value=!1,animTimeout(),nextTick(()=>{translateX.value=0,opacity.value=1,typeof restartAnim==`boolean`&&restartAnim&&nextTick(animStart)})}return props.watchContent&&watch(()=>slots.default?.(),()=>animStop(isActive.value),{deep:!0}),watch([()=>scrollSpeed.value,()=>props.initialPause,()=>props.endingPause,()=>props.fadeDuration],()=>animStop(isActive.value)),watch(()=>elContainer.value,()=>{if(!elContainer.value)return;for(parentElement=elContainer.value.parentElement;parentElement&&!parentElement.matches(`[is-bng-panel], [bng-nav-item], [ng-click], [href], [bng-all-clicks], [bng-all-clicks-no-nav], [ui-sref], input, textarea, button, md-option, md-slider, md-select, md-checkbox`);)if(parentElement=parentElement.parentElement,parentElement===document.body){parentElement=null;break}if(!parentElement)return;overrideClasses.value=[];for(let[key,selectors]of Object.entries(styleOverrides))parentElement.matches(selectors)&&overrideClasses.value.push(`bng-text-override--${key}`);let fSize=window.getComputedStyle(elContainer.value,null).fontSize;fontSize.value=+fSize.substring(0,fSize.length-2),events$3.start.forEach(event=>parentElement.addEventListener(event,animStart)),events$3.stop.forEach(event=>parentElement.addEventListener(event,animStop))},{immediate:!0}),onUnmounted(()=>{animTimeout(),parentElement&&(events$3.start.forEach(event=>parentElement.removeEventListener(event,animStart)),events$3.stop.forEach(event=>parentElement.removeEventListener(event,animStop)))}),(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,{ref_key:`elContainer`,ref:elContainer,class:normalizeClass([`bng-text-scroller`,[{"is-scrolling":isScrolling$1.value},...overrideClasses.value]])},[createBaseVNode(`div`,{ref_key:`elText`,ref:elText,class:`scroller-text`,style:normalizeStyle(scrollStyles.value)},[renderSlot(_ctx.$slots,`default`,{},void 0,!0)],4)],2))}},textScroller_default=__plugin_vue_export_helper_default(_sfc_main$390,[[`__scopeId`,`data-v-4f311fae`]]),_hoisted_1$338=[`data-tree-node-key`,`data-tree-node-expanded`,`data-tree-node-selected`,`data-tree-node-parent-path`,`data-tree-node-path`],_hoisted_2$268={key:1,class:`node`},_hoisted_3$234=[`disabled`],_hoisted_4$199={key:2,"data-tree-node-children":``},_sfc_main$389={__name:`treeNode`,props:{node:{type:Object,required:!0},keyName:{type:String,required:!0},parentNode:Object,selectMode:String,expandMode:String,expandedKeys:Array,selectedKeys:Array,parentPath:Array},setup(__props){let props=__props,$templates=inject(`$templates`),_expandFn=inject(`expandFn`),_selectFn=inject(`selectFn`),expanded=computed(()=>props.expandMode===`prop`?props.node.expanded:props.expandedKeys&&props.expandedKeys.includes(props.node[props.keyName])),expandable=computed(()=>!props.node.disabled&&props.node.children&&props.node.children.length>0),selected=computed(()=>props.selectMode?props.selectMode===`prop`?props.node.selected:props.selectedKeys&&props.selectedKeys.includes(props.node[props.keyName]):!1),selectable=computed(()=>!props.node.disabled&&props.selectMode&&props.node.selectable!==!1),path=computed(()=>props.parentPath?props.parentPath.concat(props.node[props.keyName]):[props.node[props.keyName]]),parentPathString=computed(()=>props.parentPath?props.parentPath.join(`/`):null),pathString=computed(()=>path.value.join(`/`)),nodeProps=computed(()=>({path:path.value,parentPath:props.parentPath}));return(_ctx,_cache)=>{let _component_TreeNode=resolveComponent(`TreeNode`,!0);return openBlock(),createElementBlock(`li`,{"data-tree-node-key":__props.node[__props.keyName],"data-tree-node-expanded":expanded.value,"data-tree-node-selected":selected.value,"data-tree-node-parent-path":parentPathString.value,"data-tree-node-path":pathString.value,"data-tree-node":``},[unref($templates).node?(openBlock(),createBlock(resolveDynamicComponent(unref($templates).node),{key:0,node:__props.node,parentNode:__props.parentNode,expanded:expanded.value,selected:selected.value,expand:()=>expandable.value?unref(_expandFn)(__props.node,nodeProps.value):{},select:()=>selectable.value?unref(_selectFn)(__props.node,nodeProps.value):{}},null,8,[`node`,`parentNode`,`expanded`,`selected`,`expand`,`select`])):(openBlock(),createElementBlock(`div`,_hoisted_2$268,[__props.node.children&&unref($templates).toggle?(openBlock(),createBlock(resolveDynamicComponent(unref($templates).toggle),{key:0,node:__props.node,parentNode:__props.parentNode,expanded:expanded.value,selected:selected.value,expand:()=>expandable.value?unref(_expandFn)(__props.node,nodeProps.value):{}},null,8,[`node`,`parentNode`,`expanded`,`selected`,`expand`])):(openBlock(),createElementBlock(`span`,{key:1,class:`node-toggle`,onClick:_cache[0]||=()=>expandable.value?unref(_expandFn)(__props.node,nodeProps.value):{},disabled:__props.node.disabled},[__props.node.children?(openBlock(),createBlock(unref(bngIcon_default),{key:0,"bng-nav-item":``,type:expanded.value?unref(icons).arrowSmallDown:unref(icons).arrowSmallRight},null,8,[`type`])):createCommentVNode(``,!0)],8,_hoisted_3$234)),unref($templates).content?(openBlock(),createBlock(resolveDynamicComponent(unref($templates).content),{key:2,node:__props.node,parentNode:__props.parentNode,expanded:expanded.value,selected:selected.value,expand:()=>expandable.value?unref(_expandFn)(__props.node,nodeProps.value):{},select:()=>selectable.value?unref(_selectFn)(__props.node,nodeProps.value):{}},null,8,[`node`,`parentNode`,`expanded`,`selected`,`expand`,`select`])):(openBlock(),createElementBlock(`span`,{key:3,"bng-nav-item":``,class:`node-content`,onClick:_cache[1]||=()=>selectable.value?unref(_selectFn)(__props.node,nodeProps.value):{}},toDisplayString(__props.node.label),1))])),expanded.value&&__props.node.children?(openBlock(),createElementBlock(`ul`,_hoisted_4$199,[(openBlock(!0),createElementBlock(Fragment,null,renderList(__props.node.children,childNode=>(openBlock(),createBlock(_component_TreeNode,{key:childNode[__props.keyName],node:childNode,parentNode:__props.node,keyName:__props.keyName,selectMode:__props.selectMode,expandMode:__props.expandMode,expandedKeys:__props.expandedKeys,selectedKeys:__props.selectedKeys,parentPath:path.value},null,8,[`node`,`parentNode`,`keyName`,`selectMode`,`expandMode`,`expandedKeys`,`selectedKeys`,`parentPath`]))),128))])):createCommentVNode(``,!0)],8,_hoisted_1$338)}}},treeNode_default=__plugin_vue_export_helper_default(_sfc_main$389,[[`__scopeId`,`data-v-aeb14cdb`]]),_hoisted_1$337={class:`tree`},SELECT_SINGLE=`single`,SELECT_MULTIPLE=`multi`,SELECT_PROP=`prop`,SELECT_MODES=[SELECT_SINGLE,SELECT_MULTIPLE,SELECT_PROP],EXPAND_MODEL=`model`,EXPAND_PROP=`prop`,EXPAND_MODES=[EXPAND_MODEL,EXPAND_PROP],_sfc_main$388={__name:`tree`,props:mergeModels({nodes:{type:Array,required:!0},keyName:{type:String,default:`key`},expandMode:{type:String,default:EXPAND_MODEL,validator(value){return EXPAND_MODES.includes(value)}},selectMode:{type:String,validator(value){return SELECT_MODES.includes(value)}}},{expandedKeys:{},expandedKeysModifiers:{},selectedKeys:{},selectedKeysModifiers:{}}),emits:mergeModels([`update:expandedKeys`,`node-expanded`,`node-collapsed`,`expanded-keys-changed`,`node-selected`,`node-unselected`,`selected-keys-changed`],[`update:expandedKeys`,`update:selectedKeys`]),setup(__props,{emit:__emit}){let props=__props,expandedKeys=useModel(__props,`expandedKeys`),selectedKeys=useModel(__props,`selectedKeys`),emit$1=__emit;onBeforeMount(()=>{provide(`$templates`,useSlots()),provide(`expandFn`,expand),provide(`selectFn`,select)});function expand(node,nodeProps){let nodeKey=node[props.keyName];if(props.expandMode===EXPAND_PROP)node.expanded?emit$1(`node-collapsed`,node,nodeProps):emit$1(`node-expanded`,node,nodeProps);else{if(!expandedKeys.value)throw Error(`v-model:expandedKeys must be set`);let expanded=expandedKeys.value.includes(nodeKey),updatedExpandedKeys;expanded?(updatedExpandedKeys=expandedKeys.value.filter(x=>x!==nodeKey),emit$1(`node-collapsed`,node,nodeProps)):(updatedExpandedKeys=[...expandedKeys.value,nodeKey],emit$1(`node-expanded`,node,nodeProps)),expandedKeys.value=updatedExpandedKeys,emit$1(`expanded-keys-changed`,updatedExpandedKeys)}}function select(node,nodeProps){console.log(`select`,node);let nodeKey=node[props.keyName];if(props.selectMode===SELECT_PROP)node.selected?emit$1(`node-selected`,node,nodeProps):emit$1(`node-unselected`,node,nodeProps);else{if(!selectedKeys.value)throw Error(`v-model:selectedKeys must be set`);let selected=selectedKeys.value.includes(nodeKey),updatedSelectedKeys;selected?(updatedSelectedKeys=selectedKeys.value.filter(x=>x!==nodeKey),emit$1(`node-unselected`,node,nodeProps)):props.selectMode===`single`?(updatedSelectedKeys=[nodeKey],emit$1(`node-selected`,node,nodeProps)):props.selectMode===`multi`&&(updatedSelectedKeys=[...selectedKeys.value,nodeKey],emit$1(`node-selected`,node,nodeProps)),selectedKeys.value=updatedSelectedKeys,emit$1(`selected-keys-changed`,updatedSelectedKeys)}}return(_ctx,_cache)=>(openBlock(),createElementBlock(`ul`,_hoisted_1$337,[(openBlock(!0),createElementBlock(Fragment,null,renderList(__props.nodes,node=>(openBlock(),createBlock(treeNode_default,{key:node[__props.keyName],node,keyName:__props.keyName,selectMode:__props.selectMode,expandMode:__props.expandMode,expandedKeys:expandedKeys.value,selectedKeys:selectedKeys.value},null,8,[`node`,`keyName`,`selectMode`,`expandMode`,`expandedKeys`,`selectedKeys`]))),128))]))}},tree_default=__plugin_vue_export_helper_default(_sfc_main$388,[[`__scopeId`,`data-v-7363528a`]]);const DEMOS$1={};var utility_exports=__export({Accordion:()=>accordion_default,AccordionItem:()=>accordionItem_default,AccordionTree:()=>accordionTree_default,AspectRatio:()=>aspectRatio_default,Carousel:()=>carousel_default,CarouselItem:()=>carouselItem_default,DEMOS:()=>DEMOS$1,DRAWER_POSITION:()=>DRAWER_POSITION,Drawer:()=>drawer_default,DynamicComponent:()=>dynamicComponent_default,Shelf:()=>shelf_default,SlotSwitcher:()=>slotSwitcher_default,Tab:()=>tab_default,TabList:()=>tabList_default,Tabs:()=>tabs_default,TextScroller:()=>textScroller_default,Tree:()=>tree_default,TreeNode:()=>treeNode_default}),_hoisted_1$336={class:`actions-drawer`},_sfc_main$387={__name:`bngActionsDrawer`,props:{header:{type:String,required:!0},headerActions:Array,showHeaderActions:{type:Boolean,default:!0},grouped:Boolean,actions:{type:[Array,Object],required:!0},selected:{type:[String,Number]},expanded:Boolean},emits:[`actionClick`,`headerActionClicked`,`categoryChanged`],setup(__props,{emit:__emit}){let emit$1=__emit,onActionClicked=action=>emit$1(`actionClick`,action);return(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$336,[createVNode(unref(bngDrawerOld_default),null,createSlots({header:withCtx(()=>[createTextVNode(toDisplayString(__props.header),1)]),content:withCtx(()=>[__props.grouped?(openBlock(),createBlock(unref(tabs_default),{key:0,class:`categories-tab bng-tabs`},{default:withCtx(()=>[(openBlock(!0),createElementBlock(Fragment,null,renderList(__props.actions,category=>(openBlock(),createBlock(unref(tab_default),{key:category.category,heading:category.category},{default:withCtx(()=>[(openBlock(),createBlock(unref(bngActionsList_default),{key:category.category,actions:category.items,selected:__props.selected,class:normalizeClass({expanded:__props.expanded}),onActionClick:_cache[0]||=value=>onActionClicked(value)},null,8,[`actions`,`selected`,`class`]))]),_:2},1032,[`heading`]))),128))]),_:1})):(openBlock(),createBlock(unref(bngActionsList_default),{key:1,actions:__props.actions,selected:__props.selected,class:normalizeClass({expanded:__props.expanded}),onActionClick:_cache[1]||=value=>onActionClicked(value)},null,8,[`actions`,`selected`,`class`]))]),_:2},[__props.showHeaderActions&&__props.headerActions?{name:`headerOptions`,fn:withCtx(()=>[(openBlock(!0),createElementBlock(Fragment,null,renderList(__props.headerActions,action=>(openBlock(),createBlock(unref(bngButton_default),{key:action.value,tabindex:`1`,accent:action.accent,onClick:$event=>_ctx.$emit(`headerActionClicked`,action.value)},{default:withCtx(()=>[createTextVNode(toDisplayString(action.label),1)]),_:2},1032,[`accent`,`onClick`]))),128))]),key:`0`}:void 0]),1024)]))}},bngActionsDrawer_default=__plugin_vue_export_helper_default(_sfc_main$387,[[`__scopeId`,`data-v-b433a352`]]),_hoisted_1$335={class:`header-wrapper`},_hoisted_2$267={class:`drawer-content`},_hoisted_3$233={key:0,class:`filters-wrapper`},_hoisted_4$198={class:`drawer-actions-wrapper`},_hoisted_5$168={key:0,class:`action-divider`},_hoisted_6$143={key:1,class:`progress-indicator`},_sfc_main$386={__name:`bngActionsDrawerOne`,props:{value:{type:Object,required:!0},flattenChildren:Boolean,allowOpenDrawer:Boolean,openDrawerLabel:String,closeDrawerLabel:String,loading:Boolean,header:String,blur:Boolean},emits:[`update:currentActionPath`,`update:loading`,`actionClicked`,`actionItemChanged`,`drawerOpened`],setup(__props,{emit:__emit}){let props=__props,emit$1=__emit,drawerState=reactive({isOpenCatalog:!1,currentPath:[],drawerFilters:[]}),currentActionPath=computed({get:()=>drawerState.currentPath,set:newValue=>{drawerState.currentPath=newValue}}),parentAction=computed(()=>{if(!currentActionPath.value||currentActionPath.value.length===0)return null;let currentAction$1=props.value;for(let key of currentActionPath.value.slice(0,-1))currentAction$1=currentAction$1.items.find(x=>x.value===key);return currentAction$1}),currentAction=computed(()=>{let currentAction$1=props.value;for(let key of currentActionPath.value)currentAction$1=currentAction$1.items.find(x=>x.value===key);return currentAction$1}),isDrawerOpen=computed({get:()=>drawerState.isOpenCatalog,set:newValue=>{drawerState.isOpenCatalog=newValue,emit$1(`drawerOpened`,newValue)}}),loading=computed({get:()=>props.loading,set:newValue=>emit$1(`update:loading`,newValue)}),canViewCatalogDisplayMode=computed(()=>(console.log(`canViewCatalogDisplayMode`),loading.value===!0||currentAction.value.allowOpenDrawer===!1?!1:(console.log(`currentAction`,currentAction.value),currentAction.value.items.every(x=>x.lazyLoadItems===!0||x.items)))),drawerFilterValue=computed({get:()=>drawerState.drawerFilters&&drawerState.drawerFilters.length>0?drawerState.drawerFilters[0]:null,set:newValue=>{drawerState.drawerFilters=newValue?[newValue]:[]}}),catalogFilters=computed(()=>{let activeAction=isDrawerOpen.value?parentAction.value:currentAction.value;return activeAction.items.every(x=>x.items&&x.items.length>0||x.lazyLoadItems)?activeAction.items.map(x=>({label:x.label,value:x.value})):[]}),showBackButton=computed(()=>currentActionPath.value.length>0);watch(drawerFilterValue,(newValue,oldValue)=>{console.log(`drawerFilterValue`,newValue,oldValue),newValue&&!oldValue?currentActionPath.value=[...currentActionPath.value,newValue]:newValue&&oldValue?currentActionPath.value=[...currentActionPath.value.slice(0,-1),newValue]:!newValue&&oldValue&&(currentActionPath.value=[...currentActionPath.value].slice(0,-1))}),watch(currentActionPath,()=>{emit$1(`actionItemChanged`,currentAction.value,currentActionPath.value)});let selectAction=actionItem=>{(actionItem.items&&actionItem.items.length>0||actionItem.lazyLoadItems===!0)&&(isDrawerOpen.value&&=!1,currentActionPath.value=[...currentActionPath.value,actionItem.value]),emit$1(`actionClicked`,actionItem)},toggleOpenCatalog=()=>{isDrawerOpen.value?closeDrawer():openDrawer()},goBack=()=>{isDrawerOpen.value?closeDrawer():currentActionPath.value=[...currentActionPath.value].slice(0,-1)};function openDrawer(){drawerFilterValue.value=catalogFilters.value[0].value,isDrawerOpen.value=!0}function closeDrawer(){drawerFilterValue.value=null,isDrawerOpen.value=!1}return(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,{class:normalizeClass([`bng-actions-drawer`,{expanded:isDrawerOpen.value}])},[createVNode(unref(bngDrawerOld_default),{blur:__props.blur,class:`bng-drawer`},{header:withCtx(()=>[renderSlot(_ctx.$slots,`header`,{actionItem:currentAction.value,canGoBack:showBackButton.value,goBack},()=>[createBaseVNode(`div`,_hoisted_1$335,[showBackButton.value?(openBlock(),createBlock(unref(bngButton_default),{key:0,icon:unref(icons).arrowLargeLeft,accent:unref(ACCENTS).secondary,class:`back-btn`,onClick:goBack},{default:withCtx(()=>[..._cache[1]||=[createTextVNode(`Back`,-1)]]),_:1},8,[`icon`,`accent`])):createCommentVNode(``,!0),createTextVNode(` `+toDisplayString(currentAction.value.label),1)])],!0)]),content:withCtx(()=>[createBaseVNode(`div`,_hoisted_2$267,[drawerState.isOpenCatalog&&catalogFilters.value.length>0?(openBlock(),createElementBlock(`div`,_hoisted_3$233,[createVNode(unref(bngPillFilters_default),{modelValue:drawerState.drawerFilters,"onUpdate:modelValue":_cache[0]||=$event=>drawerState.drawerFilters=$event,options:catalogFilters.value},null,8,[`modelValue`,`options`])])):createCommentVNode(``,!0),createBaseVNode(`div`,_hoisted_4$198,[createBaseVNode(`div`,{class:normalizeClass([`drawer-actions`,{expanded:drawerState.isOpenCatalog}])},[loading.value?(openBlock(),createElementBlock(`div`,_hoisted_6$143,[..._cache[2]||=[createBaseVNode(`div`,{class:`loader`},null,-1)]])):(openBlock(!0),createElementBlock(Fragment,{key:0},renderList(currentAction.value.items,action=>(openBlock(),createElementBlock(Fragment,{key:action.value},[action.type===`actionDivider`?(openBlock(),createElementBlock(`div`,_hoisted_5$168,toDisplayString(action.label),1)):renderSlot(_ctx.$slots,`item`,{key:1,actionItem:action,onClick:()=>selectAction(action)},()=>[createVNode(unref(bngImageTile_default),{label:action.label,icon:action.icon,onClick:$event=>selectAction(action)},null,8,[`label`,`icon`,`onClick`])],!0)],64))),128))],2)]),canViewCatalogDisplayMode.value?renderSlot(_ctx.$slots,`footer`,{key:1},()=>[createVNode(unref(bngButton_default),{class:`catalog-btn`,accent:unref(ACCENTS).outlined,onClick:toggleOpenCatalog},{default:withCtx(()=>[drawerState.isOpenCatalog?(openBlock(),createElementBlock(Fragment,{key:0},[createTextVNode(toDisplayString(__props.closeDrawerLabel?__props.closeDrawerLabel:`Collapse catalog`),1)],64)):(openBlock(),createElementBlock(Fragment,{key:1},[createTextVNode(toDisplayString(__props.openDrawerLabel?__props.openDrawerLabel:`Open full catalog`),1)],64))]),_:1},8,[`accent`])],!0):createCommentVNode(``,!0)])]),_:3},8,[`blur`])],2))}},bngActionsDrawerOne_default=__plugin_vue_export_helper_default(_sfc_main$386,[[`__scopeId`,`data-v-529c2a59`]]),_hoisted_1$334={class:`actions`},_sfc_main$385={__name:`bngActionsList`,props:{actions:{type:Array,required:!0},selected:{type:[String,Number],required:!1}},emits:[`actionClick`],setup(__props,{emit:__emit}){let emit$1=__emit;return(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$334,[(openBlock(!0),createElementBlock(Fragment,null,renderList(__props.actions,action=>(openBlock(),createBlock(unref(bngImageTile_default),mergeProps({class:`action-tile`,tabindex:`0`,key:action.value},{ref_for:!0},action,{"bng-nav-item":``,onClick:$event=>emit$1(`actionClick`,action.value)}),null,16,[`onClick`]))),128))]))}},bngActionsList_default=__plugin_vue_export_helper_default(_sfc_main$385,[[`__scopeId`,`data-v-8790d45d`]]),_hoisted_1$333=[`ui-event`],_hoisted_2$266={key:0},_hoisted_3$232={key:3,class:`combo-separator`},MULTI_ID=`[PLUS]`,MULTI_LABEL=`+`,_sfc_main$384={__name:`bngBinding`,props:{action:String,showUnassigned:Boolean,device:[String,Array],deviceKey:String,dark:Boolean,deviceMask:[String,Function],controller:Boolean,uiEvent:String,trackIgnore:Boolean,unassignedText:{default:`[N/A]`,type:String},viewerObj:Object,imagePack:String,actionVariants:Boolean,useLastDevice:{type:Boolean,default:!0},vertical:Boolean},setup(__props,{expose:__expose}){let $simplemenu=inject(`$simplemenu`),Controls=controls_default(),{showIfController,lastControllersSignature}=storeToRefs(Controls),props=__props,iconColors={dark:`var(--bng-off-black)`,light:`var(--bng-off-white)`},iconColor=computed(()=>iconColors[props.dark?`dark`:`light`]);computed(()=>iconColors[props.dark?`light`:`dark`]);let controllerOnly=computed(()=>props.controller||$simplemenu.value),LABELS_BIG=[`enter`,`tab`,`capslock`,`backspace`,`lshift`,`rshift`,`left`,`right`,`up`,`down`,`space`,`grave`,`comma`,`period`].map(c=>CONTROL_LABELS[c]||c),LABELS_OFFSET=[`space`].map(c=>CONTROL_LABELS[c]||c),rgxSanitize$1=s=>s.replace(/[-.+*$^?:|[\](){}]/g,`\\$&`),LABELS_RGX=RegExp(`(`+[MULTI_ID,...LABELS_BIG,...LABELS_OFFSET].map(rgxSanitize$1).join(`|`)+`)`,`g`),viewerObj=computed(()=>{if(props.viewerObj)return props.viewerObj;if(controllerOnly.value&&showIfController.value){let opts={...props};return opts.controller=!0,opts._controllerSignature=lastControllersSignature.value,Controls.makeViewerObj(opts)}return Controls.makeViewerObj(props)}),viewerVariants=computed(()=>{if(!viewerObj.value)return[];let variants=viewerObj.value.variants||[viewerObj.value];variants=variants.map(obj=>obj.multiControls||[obj]);for(let objs of variants)for(let obj of objs)if(obj&&(!obj.special||obj.ownLabel)&&!obj.controlSegments){let control=obj.ownLabel||obj.control;control=control.replace(/ \+ /g,MULTI_ID),obj.controlSegments=String(control).split(LABELS_RGX).filter(Boolean).map(segment=>({value:segment===MULTI_ID?MULTI_LABEL:segment,class:(LABELS_BIG.includes(segment)?`label-bigger `:``)+(LABELS_OFFSET.includes(segment)?`label-offset `:``)+(segment===MULTI_ID?`label-multi `:``)}))}return variants}),display=computed(()=>{let res=!!viewerObj.value;if(viewerObj.value)if(props.deviceMask){let dev=viewerObj.value.devName;res=typeof props.deviceMask==`function`?props.deviceMask(dev):dev.startsWith(props.deviceMask)}else controllerOnly.value&&(res=showIfController.value);return res||props.showUnassigned});__expose({displayed:display});let eventName=computed(()=>props.action?props.action:props.uiEvent?props.uiEvent:null),uiNavTracker=useUINavTracker(),ownerId$1=uniqueId(`bngBinding`),trackedEvent=``,track$1=(eventName$1=null)=>{if(trackedEvent&&=(uiNavTracker.removeIgnore(trackedEvent,ownerId$1),``),!(props.trackIgnore||!display.value)&&eventName$1){if(trackedEvent===eventName$1)return;trackedEvent=eventName$1,uiNavTracker.addIgnore(trackedEvent,ownerId$1)}};return watch(()=>props.trackIgnore,val=>track$1(val?null:eventName.value)),watch(display,()=>track$1(eventName.value)),watch(eventName,(val,prev)=>{prev&&track$1(),val&&track$1(val)}),onMounted(()=>track$1(eventName.value)),onUnmounted(()=>track$1()),(_ctx,_cache)=>display.value?(openBlock(),createElementBlock(`span`,{key:0,class:normalizeClass([`binding-wrapper`,{"binding-theme-dark":__props.dark,"binding-theme-light":!__props.dark,"with-variants":viewerVariants.value.length>1,vertical:__props.vertical}]),"ui-event":__props.uiEvent},[(openBlock(!0),createElementBlock(Fragment,null,renderList(viewerVariants.value,(viewerObjs,index)=>(openBlock(),createElementBlock(`span`,{key:index,class:normalizeClass([`binding-container`,{"combo-binding":viewerObjs.length>1}])},[(openBlock(!0),createElementBlock(Fragment,null,renderList(viewerObjs,(viewerObj$1,index$1)=>(openBlock(),createElementBlock(Fragment,{key:index$1},[viewerObj$1&&viewerObj$1.controlSegments?(openBlock(),createElementBlock(`kbd`,_hoisted_2$266,[(openBlock(!0),createElementBlock(Fragment,null,renderList(viewerObj$1.controlSegments,(seg,i)=>(openBlock(),createElementBlock(`span`,{key:i,class:normalizeClass(seg.class)},toDisplayString(seg.value),3))),128))])):viewerObj$1&&viewerObj$1.special?(openBlock(),createBlock(unref(bngIcon_default),{key:1,class:`bng-binding-icon`,type:unref(icons)[viewerObj$1.ownIcon],color:iconColor.value},null,8,[`type`,`color`])):!viewerObj$1&&__props.showUnassigned?(openBlock(),createBlock(unref(bngIcon_default),{key:2,class:`bng-binding-icon n-a`,type:unref(icons).NA,color:iconColor.value},null,8,[`type`,`color`])):createCommentVNode(``,!0),index$1Number(val)>0},simple:Boolean,blur:Boolean,disableLastItem:Boolean,showBackButton:Boolean,showBackBinding:{type:Boolean,default:!0},navigable:{type:Boolean,default:!0}},emits:[`click`,`back`],setup(__props,{emit:__emit}){let bid=uniqueId(`bng-path`),emit$1=__emit,props=__props,pathView=computed(()=>{if(!Array.isArray(props.items))return[];let mapItem=itm=>({label:itm.label,items:itm.items,data:itm,dividerType:itm.dividerType}),items$2=props.items.map(mapItem),res=props.limit?items$2.slice(-props.limit):items$2;if(!props.simple){let looseCmp=(a$1,b)=>a$1.label===b.label&&a$1.value===b.value,len=res.length;for(let i=1;ilooseCmp(itm,res[idx])),items:items$3.map(mapItem)})}}return props.limit&&items$2.length>props.limit&&res.unshift({label:`…`,data:items$2[items$2.length-props.limit-1]}),res.length>0&&(res[0].first=!0,res.at(-1).last=!0),res});function onClick(item,index){(!props.disableLastItem||index(openBlock(),createElementBlock(`div`,{class:`bng-path`,"bng-no-child-nav":!__props.navigable},[__props.showBackButton?(openBlock(),createBlock(unref(bngButton_default),{key:0,class:`back-button`,accent:unref(ACCENTS).custom,onClick:_cache[0]||=$event=>emit$1(`back`),tabindex:`1`},{default:withCtx(()=>[createVNode(unref(bngIcon_default),{type:unref(icons).arrowSmallLeft,class:`back-icon`},null,8,[`type`]),__props.showBackBinding?(openBlock(),createBlock(unref(bngBinding_default),{key:0,"ui-event":`back`,controller:``,"track-ignore":``})):createCommentVNode(``,!0),createTextVNode(` `+toDisplayString(_ctx.$tt(`ui.common.back`)),1)]),_:1},8,[`accent`])):createCommentVNode(``,!0),(openBlock(!0),createElementBlock(Fragment,null,renderList(pathView.value,(item,index)=>(openBlock(),createElementBlock(Fragment,{key:index},[item.dropdown?(openBlock(),createElementBlock(Fragment,{key:1},[withDirectives(createVNode(unref(bngButton_default),{class:`bng-path-item bng-path-has-dropdown`,accent:unref(ACCENTS).text,icon:unref(icons).arrowSmallRight},null,8,[`accent`,`icon`]),[[unref(BngBlur_default),__props.blur],[unref(BngPopover_default),item.dropdown,`bottom-start`,{click:!0}]]),createVNode(unref(bngPopoverMenu_default),{name:item.dropdown,focus:``},{default:withCtx(({hide:hide$2})=>[(openBlock(!0),createElementBlock(Fragment,null,renderList(item.items,(subitem,idx)=>withDirectives((openBlock(),createBlock(unref(bngButton_default),{key:idx,class:normalizeClass({selected:idx===item.selected}),accent:unref(ACCENTS).menu,onClick:$event=>onMenuClick(subitem,hide$2)},{default:withCtx(()=>[createTextVNode(toDisplayString(subitem.label),1)]),_:2},1032,[`class`,`accent`,`onClick`])),[[unref(BngOnUiNav_default),void 0,`ok`,{focusRequired:!0,asMouse:!0}]])),128))]),_:2},1032,[`name`])],64)):(openBlock(),createElementBlock(Fragment,{key:0},[withDirectives((openBlock(),createBlock(unref(bngButton_default),{class:normalizeClass([`bng-path-item`,{"bng-path-simple":__props.simple,"bng-path-disabled":__props.disableLastItem&&item.last,"bng-path-first":item.first,"bng-path-last":item.last}]),accent:unref(ACCENTS).text,onClick:$event=>onClick(item,index)},{default:withCtx(()=>[createTextVNode(toDisplayString(item.label),1)]),_:2},1032,[`class`,`accent`,`onClick`])),[[unref(BngBlur_default),__props.blur]]),__props.simple&&!item.last?(openBlock(),createElementBlock(`div`,_hoisted_2$265,[withDirectives(createVNode(unref(bngIcon_default),{type:item.dividerType||unref(icons).slashRight},null,8,[`type`]),[[unref(BngBlur_default),__props.blur]])])):createCommentVNode(``,!0)],64))],64))),128))],8,_hoisted_1$332))}},bngBreadcrumbs_default=__plugin_vue_export_helper_default(_sfc_main$383,[[`__scopeId`,`data-v-4a2e18d5`]]),_hoisted_1$331=[`accent`,`disabled`],_hoisted_2$264={key:0,class:`hold-arrow`,xmlns:`http://www.w3.org/2000/svg`,viewBox:`0 0 16 12`,preserveAspectRatio:`xMidYMid`},_hoisted_3$231={key:3,class:`label`},_hoisted_4$197={key:5,class:`label`},_hoisted_5$167={key:6};const ACCENTS={main:`main`,secondary:`secondary`,outlined:`outlined`,text:`text`,attention:`attention`,attentionghost:`attentionghost`,attentionoutlined:`attentionoutlined`,ghost:`ghost`,menu:`menu`,custom:`custom`};var _sfc_main$382={__name:`bngButton`,props:{accent:{type:String,default:`main`,validator:v=>Object.values(ACCENTS).includes(v)||v===``},iconLeft:[Object,String],iconRight:[Object,String],label:String,icon:[Object,String],externalIcon:String,showHold:Boolean,holdVertical:Boolean,disabled:Boolean,noSound:Boolean},setup(__props,{expose:__expose}){let slots=useSlots(),uiNavEvent=ref(),btnDOMElRef=ref(),attrs=useAttrs(),useOldIcons=computed(()=>`oldIcons`in attrs);watchUINavEventChange(btnDOMElRef,({eventName,action})=>{}),__expose({getElement(){return btnDOMElRef.value}});let isPlainTextSlot=ref(!1);function checkIfPlainText(){let slotContent=slots.default?slots.default():[];isPlainTextSlot.value=slotContent.length===1&&typeof slotContent[0].type==`symbol`&&String(slotContent[0].type).indexOf(`v-txt`)>-1&&slotContent[0].children.trim().length>0}watch(()=>slots.default,checkIfPlainText),checkIfPlainText();let props=__props,needsFallbackHoldOffset=ref(!0);return watchEffect(()=>{btnDOMElRef.value&&props.accent===`custom`&&window.getComputedStyle(btnDOMElRef.value).getPropertyValue(`--bng-button-custom-hold-offset`).trim()&&(needsFallbackHoldOffset.value=!1)}),(_ctx,_cache)=>withDirectives((openBlock(),createElementBlock(`button`,{ref_key:`btnDOMElRef`,ref:btnDOMElRef,accent:__props.accent,class:normalizeClass({"show-hold":__props.showHold,"hold-vertical":__props.holdVertical,"bng-button":!0,empty:!unref(slots).default&&!__props.label,"l-icon":__props.iconLeft||__props.icon,"r-icon":__props.iconRight,"external-icon":__props.externalIcon,"fallback-hold-offset":props.accent===`custom`&&needsFallbackHoldOffset.value}),disabled:__props.disabled},[__props.showHold?(openBlock(),createElementBlock(`svg`,_hoisted_2$264,[..._cache[0]||=[createBaseVNode(`path`,{d:`M1,1 L8,2 L16,1 L8,11 z`},null,-1)]])):createCommentVNode(``,!0),useOldIcons.value&&(__props.iconLeft||__props.icon)?(openBlock(),createBlock(unref(bngOldIcon_default),{key:1,type:__props.iconLeft||__props.icon},null,8,[`type`])):!useOldIcons.value&&(__props.iconLeft||__props.icon||__props.externalIcon)?(openBlock(),createBlock(unref(bngIcon_default),{key:2,class:`icon`,type:__props.iconLeft||__props.icon,externalImage:__props.externalIcon},null,8,[`type`,`externalImage`])):createCommentVNode(``,!0),isPlainTextSlot.value?(openBlock(),createElementBlock(`span`,_hoisted_3$231,[renderSlot(_ctx.$slots,`default`,{},void 0,!0)])):isPlainTextSlot.value?createCommentVNode(``,!0):renderSlot(_ctx.$slots,`default`,{key:4},void 0,!0),__props.label&&!isPlainTextSlot.value?(openBlock(),createElementBlock(`span`,_hoisted_4$197,toDisplayString(__props.label),1)):createCommentVNode(``,!0),uiNavEvent.value?(openBlock(),createElementBlock(`span`,_hoisted_5$167,toDisplayString(uiNavEvent.value),1)):createCommentVNode(``,!0),useOldIcons.value&&__props.iconRight?(openBlock(),createBlock(unref(bngOldIcon_default),{key:7,span:``,type:__props.iconRight},null,8,[`type`])):!useOldIcons.value&&__props.iconRight?(openBlock(),createBlock(unref(bngIcon_default),{key:8,class:`icon`,type:__props.iconRight},null,8,[`type`])):createCommentVNode(``,!0),_cache[1]||=createBaseVNode(`div`,{class:`background`},null,-1)],10,_hoisted_1$331)),[[unref(BngSoundClass_default),!__props.disabled&&!__props.noSound&&`bng_click_hover_generic`]])}},bngButton_default=__plugin_vue_export_helper_default(_sfc_main$382,[[`__scopeId`,`data-v-8b356414`]]),_hoisted_1$330={class:`card-cnt`},ANIMATION_TYPES=[`fade`,`slide`],_sfc_main$381={__name:`bngCard`,props:{backgroundImage:String,footerStyles:Object,hideFooter:Boolean,animateFooter:Boolean,animateFooterType:{type:String,default:`fade`,validator:value=>ANIMATION_TYPES.includes(value)}},setup(__props,{expose:__expose}){useCssVars(_ctx=>({v3c03b7b2:backgroundImageStyle.value}));let props=__props,slots=useSlots(),hasFooter=computed(()=>(slots.footer||slots.buttons)&&!props.hideFooter),buttonsContainer=ref(),backgroundImageStyle=computed(()=>props.backgroundImage?`url('${props.backgroundImage}')`:``);return __expose({buttonsContainer}),(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,{class:normalizeClass([`bng-card bng-card-wrapper`,{"with-background-image":backgroundImageStyle.value}])},[createBaseVNode(`div`,_hoisted_1$330,[renderSlot(_ctx.$slots,`default`,{},()=>[_cache[0]||=createTextVNode(`BNG Card`,-1)],!0)]),createVNode(Transition,{name:__props.animateFooter?__props.animateFooterType:``},{default:withCtx(()=>[hasFooter.value?(openBlock(),createElementBlock(`div`,{key:0,ref_key:`buttonsContainer`,ref:buttonsContainer,class:`footer-container`,style:normalizeStyle(__props.footerStyles)},[renderSlot(_ctx.$slots,`buttons`,{},void 0,!0),renderSlot(_ctx.$slots,`footer`,{},void 0,!0)],4)):createCommentVNode(``,!0)]),_:3},8,[`name`])],2))}},bngCard_default=__plugin_vue_export_helper_default(_sfc_main$381,[[`__scopeId`,`data-v-32edaae4`]]),_sfc_main$380={__name:`bngCardHeading`,props:{type:{type:String,default:`line`,validator:v=>[`line`,`ribbon`,`none`].includes(v)||v===``},outline:{type:Boolean,default:!1}},setup(__props){return(_ctx,_cache)=>(openBlock(),createElementBlock(`h2`,{class:normalizeClass({"card-heading":!0,[`heading-style-${__props.type}`]:!0,outline:__props.outline})},[renderSlot(_ctx.$slots,`default`,{},()=>[_cache[0]||=createTextVNode(`BNG Card Heading`,-1)],!0)],2))}},bngCardHeading_default=__plugin_vue_export_helper_default(_sfc_main$380,[[`__scopeId`,`data-v-fc76db37`]]),_hoisted_1$329={key:0,class:`colour-picker-switch`};const VIEWS={simple:{slider:!0,picker:!1,saturation:!1,luminosity:!1},compact_saturation:{slider:!0,picker:!0,saturation:!0,luminosity:!1,compact:!0},compact_luminosity:{slider:!0,picker:!0,saturation:!1,luminosity:!0,compact:!0},saturation:{slider:!1,picker:!0,saturation:!0,luminosity:!1},luminosity:{slider:!1,picker:!0,saturation:!1,luminosity:!0},full_saturation:{slider:!0,picker:!0,saturation:!0,luminosity:!1},full_luminosity:{slider:!0,picker:!0,saturation:!1,luminosity:!0}};var valuesDef={hue:.5,saturation:1,luminosity:.5},_sfc_main$379={__name:`bngColorPicker`,props:{modelValue:{type:Object,default:{...valuesDef}},view:{type:[String,Object],default:`full_luminosity`,validator:val=>typeof val==`string`||val in VIEWS},showText:{type:Boolean,default:!0},step:{type:Number,default:.001},disabled:Boolean},emits:[`update:modelValue`,`change`],setup(__props,{emit:__emit}){let $simplemenu=inject(`$simplemenu`),props=__props,sliderIndicator=`popout`,pickerMode=ref(`luminosity`),opts=ref({}),values=reactive({...valuesDef}),colorDot=ref({x:0,y:0});watch([()=>props.view,$simplemenu],()=>{if(typeof props.view==`string`)for(let key in VIEWS[props.view])opts.value[key]=VIEWS[props.view][key];else opts.value={...VIEWS[props.view]};$simplemenu.value?(opts.value.picker=!1,opts.value.compact&&(opts.value.slider=!0)):opts.value.compact&&loadCompactMode(),opts.value.picker&&setColorDot()},{immediate:!0});function updColour(){for(let key in values)values[key]=props.modelValue[key];opts.value.picker&&setColorDot()}watch(()=>props.modelValue,updColour),watch(()=>props.modelValue.hue,updColour),watch(()=>props.modelValue.saturation,updColour),watch(()=>props.modelValue.luminosity,updColour);let current=computed(()=>({hue:~~(values.hue*360),saturation:~~(values.saturation*100),luminosity:~~(values.luminosity*100)})),emitter=__emit;function notify(){for(let key in values)props.modelValue[key]=values[key];emitter(`change`,props.modelValue),emitter(`update:modelValue`,props.modelValue)}let hueLoop=[...Array(7)].map((_,i)=>i/6*360),gradients=reactive({hueStatic:hueLoop.map(hue=>`hsl(${hue}, 100%, 50%)`),hue:computed(()=>hueLoop.map(hue=>`hsl(${hue}, 100%, 50%)`)),overlaySaturation:[`hsla(0, 0%,  0%, 0)`,`hsla(0, 0%, 50%, 1)`],overlayLuminosity:[`hsla(0, 0%, 100%, 1)`,`hsla(0, 0%, 100%, 0) 50%`,`hsla(0, 0%,   0%, 0) 50%`,`hsla(0, 0%,   0%, 1)`],pickerOverlay:computed(()=>opts.value.saturation?gradients.overlaySaturation:gradients.overlayLuminosity),saturation:computed(()=>[`hsl(${current.value.hue},   0%, ${current.value.luminosity}%)`,`hsl(${current.value.hue}, 100%, ${current.value.luminosity}%)`]),luminosity:computed(()=>[`hsl(${current.value.hue}, ${current.value.saturation}%,   0%)`,`hsl(${current.value.hue}, ${current.value.saturation}%,  50%)`,`hsl(${current.value.hue}, ${current.value.saturation}%, 100%)`])}),isMousedown=!1;function onMousedown(){isMousedown=!0}function onMousemove(evt){updateColor(evt)}function onMouseupLeave(evt){updateColor(evt,!0)}function getPosition(evt){let rect=evt.target.getBoundingClientRect();return rect.width<20?colorDot.value:{x:(evt.x-rect.left)/rect.width*100,y:(evt.y-rect.top)/rect.height*100}}function updateColor(evt,mouseLeave=!1){if(!isMousedown)return;mouseLeave&&(isMousedown=!1);let pos=getPosition(evt);values.hue=Math.max(0,Math.min(pos.x,100))/100;let secondary=1-Math.max(0,Math.min(pos.y,100))/100;opts.value.saturation?values.saturation=secondary:values.luminosity=secondary,setColorDot(),nextTick(notify)}function setColorDot(){colorDot.value={x:values.hue*100,y:(1-(opts.value.saturation?values.saturation:values.luminosity))*100}}function toggleCompactMode(){opts.value.slider=!opts.value.slider,opts.value.picker=!opts.value.picker,saveCompactMode()}function togglePickerMode(){pickerMode.value=pickerMode.value===`luminosity`?`saturation`:`luminosity`,opts.value.luminosity=pickerMode.value===`luminosity`,opts.value.saturation=pickerMode.value===`saturation`,saveCompactMode()}function loadCompactMode(){let readOption=(name,val=null)=>JSON.parse(localStorage.getItem(name)||JSON.stringify(val));opts.value.picker=readOption(`bngColorPicker-picker`,!0),opts.value.slider=readOption(`bngColorPicker-slider`,!1),pickerMode.value=readOption(`bngColorPicker-picker-mode`,`luminosity`),opts.value.luminosity=pickerMode.value===`luminosity`,opts.value.saturation=pickerMode.value===`saturation`,!opts.value.luminosity&&!opts.value.saturation&&(opts.value.luminosity=!0)}function saveCompactMode(){let saveOption=(name,val)=>localStorage.setItem(name,JSON.stringify(val));saveOption(`bngColorPicker-picker`,opts.value.picker),saveOption(`bngColorPicker-slider`,opts.value.slider),saveOption(`bngColorPicker-picker-mode`,pickerMode.value)}return onMounted(()=>{updColour(),!$simplemenu.value&&opts.value.compact&&loadCompactMode()}),(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,{class:normalizeClass({"colour-picker-container":!0,"colour-picker-mode-picker":opts.value.picker,"colour-picker-mode-slider":opts.value.slider,"colour-picker-mode-compact":opts.value.compact})},[opts.value.compact?(openBlock(),createElementBlock(`div`,_hoisted_1$329,[_cache[3]||=createBaseVNode(`span`,null,`Custom color`,-1),!unref($simplemenu)&&opts.value.picker?withDirectives((openBlock(),createBlock(unref(bngButton_default),{key:0,accent:unref(ACCENTS).text,icon:unref(icons).materialTransparency01,onClick:togglePickerMode},null,8,[`accent`,`icon`])),[[unref(BngTooltip_default),`Toggle vertical axis mode to ${pickerMode.value===`luminosity`?`saturation`:`brightness`}`,`top`]]):createCommentVNode(``,!0),unref($simplemenu)?createCommentVNode(``,!0):withDirectives((openBlock(),createBlock(unref(bngButton_default),{key:1,accent:opts.value.picker?unref(ACCENTS).outlined:unref(ACCENTS).text,icon:opts.value.picker?unref(icons).materialGlossy:unref(icons).listSmall,onClick:toggleCompactMode},null,8,[`accent`,`icon`])),[[unref(BngTooltip_default),`Toggle picker/slider mode`,`top`]])])):createCommentVNode(``,!0),opts.value.picker?withDirectives((openBlock(),createElementBlock(`div`,{key:1,class:`colour-picker`,onMousemove,onMousedown,onMouseup:onMouseupLeave,onMouseleave:onMouseupLeave,style:normalizeStyle({"--colour-picker-x":`linear-gradient(90deg, ${gradients.hueStatic.join(`, `)})`,"--colour-picker-y":`linear-gradient(180deg, ${gradients.pickerOverlay.join(`, `)})`})},[createBaseVNode(`div`,{class:`colour-picker-dot`,style:normalizeStyle({left:`${colorDot.value.x}%`,top:`${colorDot.value.y}%`,"--colour-picker-dot-fill":`hsl(${current.value.hue}, ${opts.value.saturation?current.value.saturation:100}%, ${opts.value.luminosity?current.value.luminosity:50}%)`})},null,4)],36)),[[unref(BngDisabled_default),__props.disabled]]):createCommentVNode(``,!0),opts.value.slider||opts.value.hue?(openBlock(),createBlock(unref(bngColorSlider_default),{key:2,modelValue:values.hue,"onUpdate:modelValue":_cache[0]||=$event=>values.hue=$event,modelModifiers:{number:!0},onChange:notify,fill:gradients.hue,current:`hsl(${current.value.hue}, 100%, 50%)`,indicator:sliderIndicator,step:__props.step,disabled:__props.disabled},{default:withCtx(()=>[createTextVNode(toDisplayString(__props.showText?_ctx.$t(`ui.color.hue`):null),1)]),_:1},8,[`modelValue`,`fill`,`current`,`step`,`disabled`])):createCommentVNode(``,!0),opts.value.slider||opts.value.luminosity?(openBlock(),createBlock(unref(bngColorSlider_default),{key:3,"X:vertical":`opts.picker`,modelValue:values.saturation,"onUpdate:modelValue":_cache[1]||=$event=>values.saturation=$event,modelModifiers:{number:!0},onChange:notify,fill:gradients.saturation,current:`hsl(${current.value.hue}, ${current.value.saturation}%, ${current.value.luminosity}%)`,indicator:sliderIndicator,step:__props.step,disabled:__props.disabled},{default:withCtx(()=>[createTextVNode(toDisplayString(__props.showText?`${_ctx.$t(`ui.color.saturation`)} (${current.value.saturation}%)`:null),1)]),_:1},8,[`modelValue`,`fill`,`current`,`step`,`disabled`])):createCommentVNode(``,!0),opts.value.slider||opts.value.saturation?(openBlock(),createBlock(unref(bngColorSlider_default),{key:4,"X:vertical":`opts.picker`,modelValue:values.luminosity,"onUpdate:modelValue":_cache[2]||=$event=>values.luminosity=$event,modelModifiers:{number:!0},onChange:notify,fill:gradients.luminosity,current:`hsl(${current.value.hue}, ${current.value.saturation}%, ${current.value.luminosity}%)`,indicator:sliderIndicator,step:__props.step,disabled:__props.disabled},{default:withCtx(()=>[createTextVNode(toDisplayString(__props.showText?`${_ctx.$t(`ui.color.brightness`)} (${current.value.luminosity}%)`:null),1)]),_:1},8,[`modelValue`,`fill`,`current`,`step`,`disabled`])):createCommentVNode(``,!0)],2))}},bngColorPicker_default=__plugin_vue_export_helper_default(_sfc_main$379,[[`__scopeId`,`data-v-f4241405`]]),_hoisted_1$328={key:0},_hoisted_2$263=[`min`,`max`,`step`,`tabindex`,`orient`],_hoisted_3$230={key:0,class:`colour-slider-indicator-container`},_sfc_main$378={__name:`bngColorSlider`,props:{modelValue:{type:[Number,String],default:0},min:{type:Number,default:0},max:{type:Number,default:1},step:{type:Number,default:.001},fill:{type:Array,default:[`rgb(0,0,0)`,`rgb(255,255,255)`]},current:{type:String,default:null},vertical:Boolean,disabled:Boolean,indicator:{type:String,default:`inner`,validator:val=>[`inner`,`popout`].includes(val)},uiNavFocus:{type:[Boolean,Object],default:{},validator:val=>typeof val==`boolean`&&!val||typeof val==`object`}},emits:[`update:modelValue`,`change`],setup(__props,{emit:__emit}){let props=__props,elSlider=ref(),elIndicator=ref(),tabIndex=computed(()=>props.disabled?-1:0),value=ref(props.modelValue);watch(()=>props.modelValue,val=>value.value=Number(val));let indicatorPos=computed(()=>props.indicator===`popout`?(value.value-props.min)/(props.max-props.min):0),indicatorRot=computed(()=>{if(props.indicator!==`popout`||!elSlider.value||!elIndicator.value||!elSlider.value.getBoundingClientRect||!elIndicator.value.firstChild||!elIndicator.value.firstChild.getBoundingClientRect)return 0;let tilt=40,rot=0,srect=elSlider.value.getBoundingClientRect(),irect=elIndicator.value.firstChild.getBoundingClientRect(),abspos=indicatorPos.value*srect.width,iwidth=irect.width/2;return absposwithDirectives((openBlock(),createElementBlock(`div`,{ref_key:`elSlider`,ref:elSlider,class:`colour-slider`,style:normalizeStyle({"--colour-slider-track-fill":__props.fill&&__props.fill.length>0?`linear-gradient(90deg, ${__props.fill.join(`, `)})`:`transparent`,"--colour-slider-thumb-fill":__props.indicator===`inner`&&__props.current?__props.current:`#000`,"--colour-slider-thumb-size":__props.indicator===`inner`&&__props.current?`1em`:`0.25em`,"--colour-slider-indicator-x":`${indicatorPos.value*100}%`,"--colour-slider-indicator-r":`${indicatorRot.value}deg`})},[_ctx.$slots.default&&!__props.vertical?(openBlock(),createElementBlock(`span`,_hoisted_1$328,[renderSlot(_ctx.$slots,`default`,{},void 0,!0)])):createCommentVNode(``,!0),createBaseVNode(`div`,null,[withDirectives(createBaseVNode(`input`,{type:`range`,min:__props.min,max:__props.max,step:__props.step,"onUpdate:modelValue":_cache[0]||=$event=>value.value=$event,onInput:notify,onChange:notify,tabindex:tabIndex.value,class:normalizeClass({"colour-slider-vertical":__props.vertical}),orient:__props.vertical?`vertical`:`horizontal`},null,42,_hoisted_2$263),[[vModelText,value.value,void 0,{number:!0}],[unref(BngOnUiNavFocus_default),__props.uiNavFocus?{callback:(dir,val)=>{value.value=val,notify()},value:()=>value.value,min:__props.min,max:__props.max,step:()=>+__props.step,...__props.uiNavFocus}:!1,void 0,{repeat:!0}]]),__props.indicator===`popout`?(openBlock(),createElementBlock(`div`,_hoisted_3$230,[createBaseVNode(`div`,{ref_key:`elIndicator`,ref:elIndicator,class:`colour-slider-indicator`},[createVNode(unref(bngIconMarker_default),{marker:`circlePin`,color:[`#fff`,__props.current],class:`colour-slider-indicator-marker`},null,8,[`color`])],512)])):createCommentVNode(``,!0)])],4)),[[unref(BngDisabled_default),__props.disabled]])}},bngColorSlider_default=__plugin_vue_export_helper_default(_sfc_main$378,[[`__scopeId`,`data-v-346533a2`]]),_hoisted_1$327={class:`bng-color-tile`},_sfc_main$377={__name:`bngColorTile`,props:{red:{type:Number},blue:{type:Number},green:{type:Number},alpha:{type:Number,default:1}},setup(__props){useCssVars(_ctx=>({cef4bc4e:backgroundColor.value}));let props=__props,backgroundColor=computed(()=>`rgba(${props.red}, ${props.green}, ${props.blue}, ${props.alpha})`);return(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$327))}},bngColorTile_default=__plugin_vue_export_helper_default(_sfc_main$377,[[`__scopeId`,`data-v-32089404`]]),_sfc_main$376={__name:`bngCondition`,props:{integrity:{type:Number,default:1},integrityWarning:Boolean,color:{type:[String,Array],default:`#000`},showTooltip:Boolean},setup(__props){let props=__props,integrity=computed(()=>typeof props.integrity==`number`?Math.min(Math.max(props.integrity,0),1):1),tooltip=computed(()=>{if(!props.showTooltip)return;let tip=`${$translate.instant(`ui.condition.integrity`)}: ${~~(integrity.value*100)}%`;return props.integrityWarning&&(tip+=`\n${$translate.instant(`ui.condition.needsRepair`)}`),tip}),cssColour=computed(()=>{let clr=props.color;return Array.isArray(clr)?(clr=[...clr],clr.length>3&&(clr.splice(3),clr.some(c=>c>1)||(clr=clr.map(c=>c*255))),`rgb(${clr.join(`,`)})`):clr}),cssClipPoly=computed(()=>{let val=integrity.value,corners=[`100% 0%`,`100% 100%`,`0% 100%`,`0% 0%`],poly=`0% 0%`;if(val===1)poly=corners.join(`, `);else if(val>0){let deg=(1-val)*360,x=50+50*Math.sin(deg*Math.PI/180),y=50-50*Math.cos(deg*Math.PI/180);poly=`50% 0%, 50% 50%, ${~~x}% ${~~y}%, `+corners.slice(-Math.ceil((360-deg)/90)).join(`, `)}return poly});return(_ctx,_cache)=>withDirectives((openBlock(),createElementBlock(`div`,{class:normalizeClass({"bng-condition":!0,"cond-warn":__props.integrityWarning}),style:normalizeStyle({backgroundColor:cssColour.value,"--bng-condition-clip-path":`polygon(${cssClipPoly.value})`})},null,6)),[[unref(BngTooltip_default),tooltip.value]])}},bngCondition_default=__plugin_vue_export_helper_default(_sfc_main$376,[[`__scopeId`,`data-v-686a3067`]]),SCOPED_CHANGED_EVENT_NAME=`scopeChanged`,EVENT_CROSSFIRE_MAP={ok:`select`,back:`back`,tab_l:`tabLeft`,tab_r:`tabRight`};const CROSSFIRE_HINTS={select:{id:`select`,content:{type:`binding`,props:{uiEvent:`ok`},label:`Select`}},back:{id:`back`,content:{type:`binding`,props:{uiEvent:`back`},label:`Back`}},tabLeft:{id:`tabLeft`,content:{type:`binding`,props:{uiEvent:`tab_l`},label:`Tab left`}},tabRight:{id:`tabRight`,content:{type:`binding`,props:{uiEvent:`tab_r`},label:`Tab right`}}},CROSSFIRE_HINTS_ALL=Object.values(CROSSFIRE_HINTS),DEFAULT_LABELS={focus_u:`ui.inputActions.controllerui.focus_u.title`,focus_r:`ui.inputActions.controllerui.focus_r.title`,focus_d:`ui.inputActions.controllerui.focus_d.title`,focus_l:`ui.inputActions.controllerui.focus_l.title`,pause:`ui.inputActions.general.pause.title`,menu:`ui.inputActions.controllerui.menu.title`,back:`ui.inputActions.controllerui.back.title`,details:`ui.inputActions.controllerui.details.title`,advanced:`ui.inputActions.controllerui.advanced.title`,camera:`ui.inputActions.controllerui.camera.title`,logs:`ui.inputActions.controllerui.logs.title`,tab_l:`ui.inputActions.controllerui.tab_l.title`,tab_r:`ui.inputActions.controllerui.tab_r.title`,modifier:`ui.inputActions.controllerui.modifier.title`,zoom_out:`ui.inputActions.controllerui.zoom_out.title`,zoom_in:`ui.inputActions.controllerui.zoom_in.title`,subtab_l:`ui.inputActions.controllerui.subtab_l.title`,subtab_r:`ui.inputActions.controllerui.subtab_r.title`,center_cam:`ui.inputActions.controllerui.center_cam.title`,action_4:`ui.inputActions.controllerui.action_4.title`,move_ud:`ui.inputActions.controllerui.move_ud.title`,move_lr:`ui.inputActions.controllerui.move_lr.title`,focus_ud:`ui.inputActions.controllerui.focus_ud.title`,focus_lr:`ui.inputActions.controllerui.focus_lr.title`,rotate_h_cam:`ui.inputActions.controllerui.rotate_h_cam.title`,rotate_v_cam:`ui.inputActions.controllerui.rotate_v_cam.title`,ok:`ui.inputActions.controllerui.ok.title`,cancel:`ui.inputActions.controllerui.cancel.title`,action_2:`ui.inputActions.controllerui.action_2.title`,action_3:`ui.inputActions.controllerui.action_3.title`,context:`ui.inputActions.controllerui.context.title`};var HINT_GROUPS=()=>[{names:[`back`,`menu`],label:`ui.inputActions.controllerui.back.title`},{names:[`focus_u`,`focus_d`,`focus_r`,`focus_l`,`focus_lr`,`focus_ud`],label:`ui.mainmenu.navbar.navigate`,controllerOnly:!0},{names:[`focus_u`,`focus_d`,`focus_r`,`focus_l`],label:`ui.mainmenu.navbar.navigate`},{names:[`focus_lr`,`focus_ud`],label:`ui.mainmenu.navbar.navigate`,controllerOnly:!0},{names:[SCROLL_EVENT_H,SCROLL_EVENT_V],label:`ui.mainmenu.navbar.scroll_label`,controllerOnly:!0},{names:[`tab_r`,`tab_l`],label:`ui.mainmenu.navbar.navigate`,controllerOnly:!0}],AUTOID=`__auto`,AUTOIDS={binding:`${AUTOID}_binding`,group:`${AUTOID}_group`,labelGroup:`${AUTOID}_label_group`},DISPLAY_ACTION_VARIANTS=!1;const useInfoBar=defineStore(`infoBar`,()=>{let{events:events$3}=useBridge(),Controls=controls_default(),{isControllerUsed,lastDevice}=storeToRefs(Controls),hintGroups=HINT_GROUPS(),visible=ref(!1),showSysInfo=ref(!1),withAngular=ref(!1),hintsList=ref([]),hints=ref([]);watch([isControllerUsed,lastDevice],()=>_groupHints());let getControlGroup=(uiEvents,groupLabel)=>{try{let actions=uiEvents.map(event=>ACTIONS_BY_UI_EVENT[event]).filter(Boolean);if(actions.length!==uiEvents.length)return null;let viewerObjs=actions.map(action=>Controls.makeViewerObj({action,actionVariants:DISPLAY_ACTION_VARIANTS,useLastDevice:!0})).flatMap(vo=>vo?.variants?vo.variants:vo?[vo]:[]),matchingItems=[],devNames=viewerObjs.reduce((res,obj)=>obj&&!res.includes(obj.devName)?[...res,obj.devName]:res,[]);for(let devName of devNames){if(!devName)continue;let devViewerObjs=viewerObjs.filter(obj=>obj&&obj.devName===devName&&obj.ownGroups);if(devViewerObjs.length===0)continue;let groups=devViewerObjs[0].ownGroups,controls$1=devViewerObjs.map(obj=>obj.control);for(let group of groups){if(!group.controls.every(control=>controls$1.includes(control)))continue;controls$1=controls$1.filter(control=>!group.controls.includes(control));let item;item=group.label?{type:`binding`,props:{viewerObj:{icon:devViewerObjs[0].icon,ownLabel:group.label}},label:groupLabel}:{type:`icon`,props:{type:icons[group.icon]},label:groupLabel},matchingItems.push(item)}}return matchingItems.length===0?null:matchingItems.length===1?matchingItems[0]:matchingItems}catch(err){return logger_default.error(`Error in checkForControlGroup:`,err),null}},_groupHints=()=>{let res=[],groupCandidates={},labelGroups={},isCustomLabel=content=>content&&!content.autoLabel&&content?.props?.uiEvent&&content.label!==DEFAULT_LABELS[content?.props?.uiEvent];for(let hint of hintsList.value){let normalizedHint=hint.content?hint:{content:hint},{content}=normalizedHint;if(!content?.props?.uiEvent||!content.label){res.push(normalizedHint);continue}let labelKey=content.label;labelGroups[labelKey]?labelGroups[labelKey].hints.push(normalizedHint):labelGroups[labelKey]={hints:[normalizedHint],position:res.length}}let selectMatchingGroup=matchingGroups=>matchingGroups.length<1||isControllerUsed.value?matchingGroups[0]:matchingGroups.find(group=>!group.controllerOnly)||matchingGroups.at(-1);for(let[label,group]of Object.entries(labelGroups)){let action=group.hints[0].action;if(group.hints.length>1){let events$4=group.hints.map(h$1=>h$1.content.props.uiEvent),matchingGroup=selectMatchingGroup(hintGroups.filter(g=>g.content&&g.names.every(name=>events$4.includes(name))&&events$4.filter(e=>g.names.includes(e)).length===g.names.length));if(matchingGroup){if(matchingGroup.controllerOnly&&!isControllerUsed.value)continue;let groupContent=Array.isArray(matchingGroup.content)?matchingGroup.content[0]:matchingGroup.content,groupLabel=matchingGroup.label||groupContent?.label||group.hints[0]?.content?.label,groupEvents=group.hints.map(h$1=>h$1.content.props.uiEvent),labeledBindings=group.hints.map(h$1=>{let newContent={id:h$1.id,type:h$1.content.type,props:{...h$1.content.props}};return newContent.label=isCustomLabel(h$1.content)?h$1.content.label:groupLabel,newContent}),controlGroup=getControlGroup(groupEvents,groupLabel);if(controlGroup){let content=Array.isArray(controlGroup)?controlGroup.map(item=>({...item})):[{...controlGroup}],customLabelItem=group.hints.find(h$1=>isCustomLabel(h$1.content));customLabelItem&&content.forEach(item=>{item.label=customLabelItem.content.label}),res.splice(group.position,0,{id:`${AUTOIDS.labelGroup}_${label}`,content,action})}else res.splice(group.position,0,{id:`${AUTOIDS.labelGroup}_${label}`,content:labeledBindings,action})}else res.splice(group.position,0,{id:`${AUTOIDS.labelGroup}_${label}`,content:group.hints.map(h$1=>h$1.content),action})}else{let hint=group.hints[0],uiEvent=hint.content?.props?.uiEvent,isNoGroup=uiEvent$1=>uiNavTracker.activeEvents.find(e=>e.name===uiEvent$1)?.nogroup;if(isNoGroup(uiEvent)){res.push(hint);continue}let matchingGroup=selectMatchingGroup(hintGroups.filter(group$1=>group$1.names.includes(uiEvent)));if(!matchingGroup){res.push(hint);continue}let groupId=matchingGroup.names.join(`,`);groupId in groupCandidates||(groupCandidates[groupId]={hints:[],content:[],position:res.length});let groupCandidate=groupCandidates[groupId];if(groupCandidate.hints.push(hint),groupCandidate.content.push(hint.content),groupCandidate.hints.length===matchingGroup.names.length){if(matchingGroup.controllerOnly&&!isControllerUsed.value){delete groupCandidates[groupId];continue}if(groupCandidate.hints.some(h$1=>isNoGroup(h$1.content?.props?.uiEvent)))res.splice(groupCandidate.position,0,...groupCandidate.hints);else{let groupContent=Array.isArray(matchingGroup.content)?matchingGroup.content[0]:matchingGroup.content,groupLabel=matchingGroup.label||groupContent?.label||groupCandidate.hints[0]?.content?.label,labeledContent=groupCandidate.content.map(item=>{let newContent={id:item.id,type:item.type,props:{...item.props}};return isCustomLabel(item)?newContent.label=item.label:newContent.label=groupLabel,newContent}),controlGroup=getControlGroup(groupCandidate.hints.map(h$1=>h$1.content.props.uiEvent),groupLabel);if(controlGroup){let content=Array.isArray(controlGroup)?controlGroup.map(icon=>({...icon})):[{...controlGroup}],customLabelItem=groupCandidate.content.find(item=>isCustomLabel(item));customLabelItem&&content.forEach(icon=>icon.label=customLabelItem.label),res.splice(groupCandidate.position,0,{id:`${AUTOIDS.group}_${groupId}`,content,action})}else res.splice(groupCandidate.position,0,{id:`${AUTOIDS.group}_${groupId}`,content:labeledContent,action})}delete groupCandidates[groupId]}}}for(let group of Object.values(groupCandidates))res.splice(group.position,0,...group.hints);hints.value=res},uiNavTracker=useUINavTracker(),clearHints=()=>{hintsList.value=[],_addTrackedEvents()},addHints=(hintOrHints,idOrPos=void 0,before=!1)=>{if(hintOrHints===CROSSFIRE_HINTS_ALL){logger_default.warn(`Approach with CROSSFIRE_HINTS_ALL is deprecated and crossfire hints are added by default.`);return}let toAdd=[hintOrHints].flat().map(hint=>{if(typeof hint!=`object`)return hint;let content=hint.content||hint,uiEvent=content?.props?.uiEvent;return uiEvent&&(content.label||(content.autoLabel=!0,uiEvent in DEFAULT_LABELS?content.label=DEFAULT_LABELS[uiEvent]:content.label=uiEvent.replaceAll(`_`,` `).toUpperCase())),hint});if(idOrPos===void 0)hintsList.value=hintsList.value.concat(toAdd);else if(typeof idOrPos==`number`)hintsList.value.splice(idOrPos,0,...toAdd);else if(typeof idOrPos==`string`){let foundIndex=_findHintIndex(idOrPos);foundIndex>-1&&hintsList.value.splice(foundIndex+(before?0:1),0,...toAdd)}_groupHints()},updateHint=(idOrPos,updatedHint)=>{if(typeof idOrPos==`number`)hintsList.value[idOrPos]=updatedHint;else{let foundIndex=_findHintIndex(idOrPos);hintsList.value[foundIndex]=updatedHint}_groupHints()},removeHints=(...ids)=>{ids.forEach(id=>{let foundIndex=_findHintIndex(id);foundIndex>-1&&hintsList.value.splice(foundIndex,1)}),_groupHints()},flashHints=(...ids)=>{_setFlash(!1,ids),setTimeout(()=>_setFlash(!0,ids),0)},_setFlash=(state,ids)=>ids.forEach(id=>{let foundIndex=_findHintIndex(id);foundIndex>-1&&(hintsList.value[foundIndex].flash=state)}),highlightHints=(state,...ids)=>{},_findHintIndex=id=>hintsList.value.findIndex(h$1=>h$1.id===id);events$3.on(SCOPED_CHANGED_EVENT_NAME,data=>{logger_default.debug(`[infoBar] received data`,data),data&&(clearHints(),data.forEach(ev=>{let content;content=ev.label?{content:{type:`binding`,props:{uiEvent:ev.event},label:ev.label}}:CROSSFIRE_HINTS[EVENT_CROSSFIRE_MAP[ev.event]],addHints(content)}))});function _addTrackedEvents(){let activeEvents=uiNavTracker.activeEvents;hintsList.value=hintsList.value.filter(hint=>!hint.id?.startsWith(AUTOID)&&activeEvents.some(e=>e.name===hint.content.props.uiEvent));let currentBindings=hintsList.value.filter(hint=>hint.content?.type===`binding`).map(hint=>hint.content.props.uiEvent);addHints(activeEvents.filter(({name})=>!currentBindings.includes(name)).map(({name,label,nogroup,action})=>({id:`${AUTOIDS.binding}_${name}`,content:{type:`binding`,props:{uiEvent:name},label,autoLabel:!label||label===DEFAULT_LABELS[name]},nogroup,action})))}return watch(()=>uiNavTracker.activeEvents,_addTrackedEvents,{deep:!0}),{visible,hintsList,hints,showSysInfo,withAngular,clearHints,addHints,updateHint,removeHints,flashHints,highlightHints}});var _hoisted_1$326={key:0,xmlns:`http://www.w3.org/2000/svg`,viewBox:`20 140 460 220`},_hoisted_2$262={class:`bng-controller-hint-labels`},_hoisted_3$229={x:`120`,y:`165`,"text-anchor":`middle`},_hoisted_4$196={x:`120`,y:`335`,"text-anchor":`middle`},_hoisted_5$166={x:`45`,y:`255`,"text-anchor":`end`},_hoisted_6$142={x:`175`,y:`255`,"text-anchor":`start`},_hoisted_7$124={x:`219`,y:`315`,"text-anchor":`middle`},_hoisted_8$102={x:`249`,y:`315`,"text-anchor":`middle`},_hoisted_9$92={x:`340`,y:`175`,"text-anchor":`middle`},_hoisted_10$80={x:`380`,y:`335`,"text-anchor":`middle`},_sfc_main$375={__name:`bngControllerHint`,props:{device:String,actions:[Array,String],dark:Boolean},setup(__props,{expose:__expose}){let Controls=controls_default(),props=__props,available=[`xbox`],devName=computed(()=>{if(!props.device)return Controls.lastDevice;let devName$1=props.device;return/\d$/.test(devName$1)||(devName$1=Controls.lastDevices.find(dev=>dev.startsWith(devName$1)),devName$1||=props.device+`0`),devName$1}),devFamily=computed(()=>{let family=Controls.makeViewerObj({device:devName.value,uiEvent:`back`})?.family;return!family||!available.includes(family)?null:family});__expose({displayed:computed(()=>!!devFamily.value)});let actions=computed(()=>{let actions$1=props.actions;if(!actions$1||!devFamily.value)return{};if(typeof actions$1==`string`)actions$1=[actions$1];else if(!Array.isArray(actions$1)||actions$1.length===0)return{};let bindings={},allEvents=Object.keys(ACTIONS_BY_UI_EVENT),allActions=Object.values(ACTIONS_BY_UI_EVENT);for(let action of actions$1){if(!action)continue;let item=action;if(typeof item==`string`)item={action:item};else if(!item.action&&!item.event)continue;else item={...item};let actIdx=allEvents.indexOf(item.event||item.action);if(actIdx>-1&&(item.event=allEvents[actIdx],item.action=allActions[actIdx]),!allActions.includes(item.action))continue;let binding=Controls.findBindingForAction(item.action,devName.value);if(binding){if(!item.event||item.event===item.action){let idx=allActions.indexOf(item.action);idx>-1&&(item.event=allEvents[idx])}item.label||=DEFAULT_LABELS[item.event]||item.event||item.action,item.shown=!0,item.class={flash:item.flash},bindings[binding.control.toLowerCase()]=item}}logger_default.debug(`resolved actions:`,bindings);for(let keyName of DEVICE_CONTROLS[devFamily.value]){let key=keyName.toLowerCase();key in bindings||(bindings[key]={class:{inactive:!0}})}return bindings});return(_ctx,_cache)=>devFamily.value?(openBlock(),createElementBlock(`div`,{key:0,class:normalizeClass([`bng-controller-hint`,{"bng-controller-hint-dark":__props.dark}])},[devFamily.value===`xbox`?(openBlock(),createElementBlock(`svg`,_hoisted_1$326,[_cache[8]||=createBaseVNode(`rect`,{x:`60`,y:`180`,width:`380`,height:`140`,rx:`20`,fill:`#bcbcbc`,stroke:`#333`,"stroke-width":`8`},null,-1),_cache[9]||=createBaseVNode(`circle`,{cx:`120`,cy:`250`,r:`28`,fill:`#222`},null,-1),createBaseVNode(`rect`,{class:normalizeClass(actions.value.upov.class),x:`114`,y:`222`,width:`12`,height:`20`,rx:`3`,fill:`#444`},null,2),createBaseVNode(`rect`,{class:normalizeClass(actions.value.dpov.class),x:`114`,y:`258`,width:`12`,height:`20`,rx:`3`,fill:`#444`},null,2),createBaseVNode(`rect`,{class:normalizeClass(actions.value.lpov.class),x:`98`,y:`242`,width:`20`,height:`12`,rx:`3`,fill:`#444`},null,2),createBaseVNode(`rect`,{class:normalizeClass(actions.value.rpov.class),x:`122`,y:`242`,width:`20`,height:`12`,rx:`3`,fill:`#444`},null,2),createBaseVNode(`rect`,{class:normalizeClass(actions.value.btn_start.class),x:`210`,y:`240`,width:`18`,height:`10`,rx:`3`,fill:`#888`},null,2),createBaseVNode(`rect`,{class:normalizeClass(actions.value.btn_back.class),x:`240`,y:`240`,width:`18`,height:`10`,rx:`3`,fill:`#888`},null,2),createBaseVNode(`circle`,{class:normalizeClass(actions.value.btn_a.class),cx:`340`,cy:`230`,r:`18`,fill:`#22a`},null,2),createBaseVNode(`circle`,{class:normalizeClass(actions.value.btn_b.class),cx:`380`,cy:`270`,r:`18`,fill:`#22a`},null,2),createBaseVNode(`g`,_hoisted_2$262,[actions.value.upov?.shown?(openBlock(),createElementBlock(Fragment,{key:0},[_cache[0]||=createBaseVNode(`line`,{x1:`120`,y1:`202`,x2:`120`,y2:`170`,stroke:`#666`,"stroke-width":`2`},null,-1),createBaseVNode(`text`,_hoisted_3$229,toDisplayString(_ctx.$tt(actions.value.upov?.label)),1)],64)):createCommentVNode(``,!0),actions.value.dpov?.shown?(openBlock(),createElementBlock(Fragment,{key:1},[_cache[1]||=createBaseVNode(`line`,{x1:`120`,y1:`298`,x2:`120`,y2:`320`,stroke:`#666`,"stroke-width":`2`},null,-1),createBaseVNode(`text`,_hoisted_4$196,toDisplayString(_ctx.$tt(actions.value.dpov?.label)),1)],64)):createCommentVNode(``,!0),actions.value.lpov?.shown?(openBlock(),createElementBlock(Fragment,{key:2},[_cache[2]||=createBaseVNode(`line`,{x1:`78`,y1:`250`,x2:`50`,y2:`250`,stroke:`#666`,"stroke-width":`2`},null,-1),createBaseVNode(`text`,_hoisted_5$166,toDisplayString(_ctx.$tt(actions.value.lpov?.label)),1)],64)):createCommentVNode(``,!0),actions.value.rpov?.shown?(openBlock(),createElementBlock(Fragment,{key:3},[_cache[3]||=createBaseVNode(`line`,{x1:`142`,y1:`250`,x2:`170`,y2:`250`,stroke:`#666`,"stroke-width":`2`},null,-1),createBaseVNode(`text`,_hoisted_6$142,toDisplayString(_ctx.$tt(actions.value.rpov?.label)),1)],64)):createCommentVNode(``,!0),actions.value.btn_start?.shown?(openBlock(),createElementBlock(Fragment,{key:4},[_cache[4]||=createBaseVNode(`line`,{x1:`219`,y1:`270`,x2:`219`,y2:`300`,stroke:`#666`,"stroke-width":`2`},null,-1),createBaseVNode(`text`,_hoisted_7$124,toDisplayString(_ctx.$tt(actions.value.btn_start?.label)),1)],64)):createCommentVNode(``,!0),actions.value.btn_back?.shown?(openBlock(),createElementBlock(Fragment,{key:5},[_cache[5]||=createBaseVNode(`line`,{x1:`249`,y1:`270`,x2:`249`,y2:`300`,stroke:`#666`,"stroke-width":`2`},null,-1),createBaseVNode(`text`,_hoisted_8$102,toDisplayString(_ctx.$tt(actions.value.btn_back?.label)),1)],64)):createCommentVNode(``,!0),actions.value.btn_a?.shown?(openBlock(),createElementBlock(Fragment,{key:6},[_cache[6]||=createBaseVNode(`line`,{x1:`340`,y1:`212`,x2:`340`,y2:`180`,stroke:`#666`,"stroke-width":`2`},null,-1),createBaseVNode(`text`,_hoisted_9$92,toDisplayString(_ctx.$tt(actions.value.btn_a?.label)),1)],64)):createCommentVNode(``,!0),actions.value.btn_b?.shown?(openBlock(),createElementBlock(Fragment,{key:7},[_cache[7]||=createBaseVNode(`line`,{x1:`380`,y1:`288`,x2:`380`,y2:`320`,stroke:`#666`,"stroke-width":`2`},null,-1),createBaseVNode(`text`,_hoisted_10$80,toDisplayString(_ctx.$tt(actions.value.btn_b?.label)),1)],64)):createCommentVNode(``,!0)])])):createCommentVNode(``,!0)],2)):createCommentVNode(``,!0)}},bngControllerHint_default=__plugin_vue_export_helper_default(_sfc_main$375,[[`__scopeId`,`data-v-bb01f791`]]),_sfc_main$374={},_hoisted_1$325={class:`divider vertical-divider`};function _sfc_render$6(_ctx,_cache){return openBlock(),createElementBlock(`div`,_hoisted_1$325)}var bngDivider_default=__plugin_vue_export_helper_default(_sfc_main$374,[[`render`,_sfc_render$6],[`__scopeId`,`data-v-c3fbf7df`]]),_sfc_main$373={__name:`bngDrawer`,props:mergeModels({header:String,blur:Boolean,expandable:{type:Boolean,default:!0},position:String},{modelValue:{type:Boolean},modelModifiers:{}}),emits:mergeModels([`change`],[`update:modelValue`]),setup(__props,{emit:__emit}){let props=__props,emit$1=__emit,slots=useSlots(),arrows=computed(()=>{switch(props.position){default:case DRAWER_POSITION.bottom:case DRAWER_POSITION.right:return{expand:icons.arrowLargeUp,collapse:icons.arrowLargeDown};case DRAWER_POSITION.top:case DRAWER_POSITION.left:return{expand:icons.arrowLargeDown,collapse:icons.arrowLargeUp}}}),expanded=useModel(__props,`modelValue`);return watch(()=>expanded.value,val=>emit$1(`change`,val)),watch([()=>props.expandable,()=>expanded.value],()=>!props.expandable&&expanded.value&&(expanded.value=!1),{immediate:!0}),(_ctx,_cache)=>(openBlock(),createBlock(unref(drawer_default),{modelValue:expanded.value,"onUpdate:modelValue":_cache[1]||=$event=>expanded.value=$event,blur:__props.blur,position:__props.position},createSlots({header:withCtx(()=>[createVNode(unref(bngCardHeading_default),{class:`header`,type:`ribbon`,style:normalizeStyle({marginRight:!__props.header&&!unref(slots).header?`0`:void 0})},{default:withCtx(()=>[__props.header?(openBlock(),createElementBlock(Fragment,{key:0},[createTextVNode(toDisplayString(__props.header),1)],64)):renderSlot(_ctx.$slots,`header`,{key:1},()=>[_cache[2]||=createBaseVNode(`span`,null,null,-1)],!0)]),_:3},8,[`style`]),renderSlot(_ctx.$slots,`header-controls`,{},void 0,!0),__props.expandable?(openBlock(),createBlock(unref(bngButton_default),{key:0,accent:`text`,icon:expanded.value?arrows.value.collapse:arrows.value.expand,onClick:_cache[0]||=$event=>expanded.value=!expanded.value},null,8,[`icon`])):createCommentVNode(``,!0)]),_:2},[`content`in unref(slots)?{name:`content`,fn:withCtx(()=>[renderSlot(_ctx.$slots,`content`,{},void 0,!0)]),key:`0`}:void 0,`expanded-content`in unref(slots)?{name:`expanded-content`,fn:withCtx(()=>[renderSlot(_ctx.$slots,`expanded-content`,{},void 0,!0)]),key:`1`}:`default`in unref(slots)?{name:`expanded-content`,fn:withCtx(()=>[renderSlot(_ctx.$slots,`default`,{},void 0,!0)]),key:`2`}:void 0]),1032,[`modelValue`,`blur`,`position`]))}},bngDrawer_default=__plugin_vue_export_helper_default(_sfc_main$373,[[`__scopeId`,`data-v-30948d98`]]),_hoisted_1$324={class:`bng-drawer`},_hoisted_2$261={class:`header-wrapper`},_hoisted_3$228={class:`content`},_sfc_main$372={__name:`bngDrawerOld`,props:{header:{type:String},blur:{type:Boolean,default:!1}},setup(__props){return(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$324,[withDirectives((openBlock(),createElementBlock(`div`,_hoisted_2$261,[createVNode(unref(bngCardHeading_default),{class:`header`,type:`ribbon`},{default:withCtx(()=>[__props.header?(openBlock(),createElementBlock(Fragment,{key:0},[createTextVNode(toDisplayString(__props.header),1)],64)):renderSlot(_ctx.$slots,`header`,{key:1},void 0,!0)]),_:3}),renderSlot(_ctx.$slots,`headerOptions`,{},void 0,!0)])),[[unref(BngBlur_default),__props.blur]]),withDirectives((openBlock(),createBlock(unref(bngCard_default),null,{default:withCtx(()=>[createBaseVNode(`div`,_hoisted_3$228,[renderSlot(_ctx.$slots,`content`,{},void 0,!0)])]),_:3})),[[unref(BngBlur_default),__props.blur]])]))}},bngDrawerOld_default=__plugin_vue_export_helper_default(_sfc_main$372,[[`__scopeId`,`data-v-9e5c32b1`]]),_hoisted_1$323={class:`dropdown-display`},_hoisted_2$260={key:0,class:`dropdown-search`},_hoisted_3$227={key:1},_hoisted_4$195={key:0,class:`dropdown-group-header`},_hoisted_5$165=[`bng-nav-item`,`tabindex`,`bng-scoped-nav-autofocus`,`onClick`,`onKeyup`],_sfc_main$371={__name:`bngDropdown`,props:{modelValue:{type:[Number,String,Boolean,Object]},items:{type:Array,required:!0},showSearch:Boolean,highlight:{type:[String,Array,RegExp]},disabled:Boolean,longNames:{type:String,default:`oneline`,validator:val=>[`oneline`,`wrap`,`cut`].includes(val)},searchGroupName:Boolean,headless:Boolean,focusTarget:Object,popoverTarget:Object},emits:[`update:modelValue`,`valueChanged`,`open`,`close`],setup(__props,{expose:__expose,emit:__emit}){let attrs=useAttrs(),binds=computed(()=>props.headless?void 0:attrs),props=__props,emit$1=__emit,elContainer=ref(null),opened=ref(!1),searching=ref(!1),search$1=ref(``),searchTerm=computed(()=>search$1.value.toLowerCase());watch(opened,val=>!val&&(search$1.value=``)),__expose({opened,open:()=>opened.value=!0,close:()=>opened.value=!1,toggle:()=>opened.value=!opened.value,get popoverName(){return elContainer.value?.popoverName}});let groupedItems=computed(()=>{let hasGrouping=props.items.some(item=>item.group||item.grouped),searchActive=!!searchTerm.value;if(!hasGrouping)return[{header:null,items:searchActive?props.items.filter(item=>item.label.toLowerCase().includes(searchTerm.value)):props.items}];let groups=[],currentGroup=null;return props.items.forEach(item=>{item.group?(currentGroup={header:item,allItems:[],_headerMatches:item.label.toLowerCase().includes(searchTerm.value)},groups.push(currentGroup)):item.grouped?currentGroup?currentGroup.allItems.push(item):groups.push({header:null,allItems:[item]}):(groups.push({header:null,allItems:[item]}),currentGroup=null)}),groups.map(group=>{if(searchActive)if(group.header){if(props.searchGroupName&&group._headerMatches)return{header:group.header,items:group.allItems,headerMatches:!0};{let filteredItems=group.allItems.filter(item=>item.label.toLowerCase().includes(searchTerm.value));return{header:group.header,items:filteredItems,headerMatches:!1}}}else return{header:null,items:group.allItems.filter(item=>item.label.toLowerCase().includes(searchTerm.value))};else return{header:group.header||null,items:group.allItems}}).filter(group=>group.header&&props.searchGroupName&&group.headerMatches||group.items.length>0)}),highlighter$1=computed(()=>search$1.value||props.highlight),selectedValue=computed({get:()=>props.modelValue,set:newValue=>{emit$1(`update:modelValue`,newValue),emit$1(`valueChanged`,newValue)}}),selectedItem=computed(()=>props.items.find(x=>x.value===selectedValue.value)),headerText=computed(()=>selectedItem.value&&selectedItem.value.value!==null&&selectedItem.value.value!==void 0?selectedItem.value.label:`Select`),tabIndexValue=computed(()=>props.disabled?-1:0),select=item=>{item.disabled||(opened.value=!1,selectedValue.value!==item.value&&(selectedValue.value=item.value),elContainer.value?.focusContainer())};return(_ctx,_cache)=>(openBlock(),createBlock(unref(bngDropdownContainer_default),mergeProps({ref_key:`elContainer`,ref:elContainer},binds.value,{opened:opened.value,"onUpdate:opened":_cache[3]||=$event=>opened.value=$event,disabled:__props.disabled,headless:__props.headless,"focus-target":__props.focusTarget,"popover-target":__props.popoverTarget,class:{"with-search":__props.showSearch,[`dropdown-longnames-${__props.longNames}`]:!0},onShow:_cache[4]||=$event=>emit$1(`open`),onHide:_cache[5]||=$event=>emit$1(`close`)}),createSlots({default:withCtx(()=>[__props.showSearch?(openBlock(),createElementBlock(`div`,_hoisted_2$260,[createVNode(unref(bngInput_default),{modelValue:search$1.value,"onUpdate:modelValue":_cache[0]||=$event=>search$1.value=$event,modelModifiers:{trim:!0},"floating-label":`Search`,onFocus:_cache[1]||=$event=>searching.value=!0,onBlur:_cache[2]||=$event=>searching.value=!1},null,8,[`modelValue`])])):createCommentVNode(``,!0),search$1.value&&groupedItems.value.every(group=>group.items.length===0)?(openBlock(),createElementBlock(`div`,_hoisted_3$227,toDisplayString(_ctx.$t(`ui.common.search.noResults`)),1)):(openBlock(!0),createElementBlock(Fragment,{key:2},renderList(groupedItems.value,(group,groupIndex)=>(openBlock(),createElementBlock(Fragment,{key:groupIndex},[group.header?(openBlock(),createElementBlock(`div`,_hoisted_4$195,toDisplayString(group.header.label),1)):createCommentVNode(``,!0),(openBlock(!0),createElementBlock(Fragment,null,renderList(group.items,(item,idx)=>withDirectives((openBlock(),createElementBlock(`div`,{key:item.value,class:normalizeClass([`dropdown-option`,{selected:selectedItem.value&&selectedItem.value.value===item.value,"grouped-item":group.header,disabled:item.disabled}]),"bng-nav-item":!item.disabled||item.focusable,tabindex:item.disabled?-1:tabIndexValue.value,"bng-scoped-nav-autofocus":!item.disabled&&!searching.value&&(selectedItem.value&&selectedItem.value.value===item.value||!selectedItem.value&&groupIndex===0&&idx===0),onClick:$event=>select(item),onKeyup:withKeys($event=>select(item),[`enter`])},[createTextVNode(toDisplayString(item.label),1)],42,_hoisted_5$165)),[[unref(BngOnUiNav_default),void 0,`ok`,{asMouse:!0,focusRequired:!0}],[unref(BngUiNavLabel_default),`ui.inputActions.menu.menu_item_select.title`,`ok`],[unref(BngTooltip_default),item.tooltip??void 0],[unref(BngHighlighter_default),highlighter$1.value]])),128))],64))),128))]),_:2},[__props.headless?void 0:{name:`display`,fn:withCtx(()=>[renderSlot(_ctx.$slots,`display`,{},()=>[withDirectives((openBlock(),createElementBlock(`span`,_hoisted_1$323,[createTextVNode(toDisplayString(headerText.value),1)])),[[unref(BngHighlighter_default),highlighter$1.value]])],!0)]),key:`0`}]),1040,[`opened`,`disabled`,`headless`,`focus-target`,`popover-target`,`class`]))}},bngDropdown_default=__plugin_vue_export_helper_default(_sfc_main$371,[[`__scopeId`,`data-v-96e56708`]]),popoverBaseName=`bng-dropdown-content`,_sfc_main$370=Object.assign({inheritAttrs:!1},{__name:`bngDropdownContainer`,props:mergeModels({disabled:Boolean,class:[String,Array,Object],headless:Boolean,focusTarget:Object,popoverTarget:Object},{opened:{},openedModifiers:{}}),emits:mergeModels([`provideFocus`,`show`,`hide`],[`update:opened`]),setup(__props,{expose:__expose,emit:__emit}){let navBlocker=useUINavBlocker(),props=__props,attrs=useAttrs(),binds=computed(()=>({...attrs,tabindex:props.headless?-1:0,"bng-nav-item":props.headless?void 0:``})),opened=useModel(__props,`opened`);function open$1(val){opened.value=val,val?(navBlocker.allowOnly([`focus_u`,`focus_d`,`focus_ud`,`back`,`menu`,`ok`]),emit$1(`show`)):(navBlocker.clear(),emit$1(`hide`),focusTarget.value&&setFocusExternal(focusTarget.value,!0,!1))}let emit$1=__emit,popover=usePopover(),popoverName=uniqueId(popoverBaseName),container=ref(null),content=ref(null),focusTarget=computed(()=>props.focusTarget||container.value),popoverTarget=computed(()=>props.popoverTarget||container.value),placement=ref(`bottom-start`),openedTop=computed(()=>placement.value.startsWith(`top`));return watch(()=>opened.value,value=>{value?(Object.keys(popover.popovers).filter(name=>popover.popovers[name].show&&name!==popoverName&&!popover.popovers[name].element.contains(popover.popovers[popoverName].target)).forEach(name=>popover.hide(name)),!popover.popovers[popoverName].show&&popoverTarget.value&&popover.show(popoverName,popoverTarget.value)):popover.hide(popoverName)}),__expose({opened,open:()=>opened.value=!0,close:()=>opened.value=!1,toggle:()=>opened.value=!opened.value,focusContainer:()=>focusTarget.value&&setFocusExternal(focusTarget.value),popoverName}),(_ctx,_cache)=>(openBlock(),createElementBlock(Fragment,null,[__props.headless?createCommentVNode(``,!0):withDirectives((openBlock(),createElementBlock(`div`,mergeProps({key:0,ref_key:`container`,ref:container},binds.value,{class:[`bng-dropdown`,props.class]}),[createVNode(unref(bngIcon_default),{type:unref(icons).arrowSmallRight,class:normalizeClass({"dropdown-arrow":!0,"dropdown-arrow-top":openedTop.value,opened:opened.value})},null,8,[`type`,`class`]),renderSlot(_ctx.$slots,`display`,{},()=>[_cache[8]||=createTextVNode(`Select`,-1)],!0)],16)),[[unref(BngDisabled_default),__props.disabled],[unref(BngOnUiNav_default),void 0,`ok`,{asMouse:!0,focusRequired:!0}],[unref(BngPopover_default),unref(popoverName),`bottom-start`,{click:!0}]]),createVNode(unref(bngPopoverContent_default),{name:unref(popoverName),onShow:_cache[5]||=$event=>open$1(!0),onHide:_cache[6]||=$event=>open$1(!1),"hide-arrow":``,onPlacementChanged:_cache[7]||=value=>placement.value=value},{default:withCtx(()=>[withDirectives((openBlock(),createElementBlock(`div`,{ref_key:`content`,ref:content,class:normalizeClass([`bng-dropdown-content`,__props.class]),"bng-nav-scroll":``,onClick:_cache[0]||=withModifiers(()=>{},[`stop`]),onMouseover:_cache[1]||=withModifiers(()=>{},[`stop`]),onMouseenter:_cache[2]||=withModifiers(()=>{},[`stop`]),onMousedown:_cache[3]||=withModifiers(()=>{},[`stop`]),onMouseup:_cache[4]||=withModifiers(()=>{},[`stop`])},[opened.value?renderSlot(_ctx.$slots,`default`,{key:0},void 0,!0):createCommentVNode(``,!0)],34)),[[unref(BngAutoScroll_default),void 0,`top`],[unref(BngUiNavLabel_default),`ui.common.close`,`back,menu`],[unref(BngUiNavLabel_default),`ui.mainmenu.navbar.navigate`,`focus_u,focus_d`],[unref(BngUiNavScroll_default)],[unref(BngOnUiNav_default),()=>open$1(!1),`menu`]])]),_:3},8,[`name`])],64))}}),bngDropdownContainer_default=__plugin_vue_export_helper_default(_sfc_main$370,[[`__scopeId`,`data-v-840dc960`]]),icons$2=Object.freeze({"4WD":{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/4WD.svg`},"9dividedby10":{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/9dividedby10.svg`},abandon:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/abandon.svg`},ABSIndicator:{glyph:``,size:24,tags:[`vehicle`,`features`,`warning`,`internals`],fileSvg:`svg/ABSIndicator.svg`},addItemPolygon:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`,`road tools`],fileSvg:`svg/addItemPolygon.svg`},addListItem:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`,`road tools`],fileSvg:`svg/addListItem.svg`},addPolygonVertex:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`,`road tools`],fileSvg:`svg/addPolygonVertex.svg`},adjust:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/adjust.svg`},AIMicrochip:{glyph:``,size:24,tags:[`generic`,`ai`,`microchip`],fileSvg:`svg/AIMicrochip.svg`},AIRace:{glyph:``,size:24,tags:[`poi`],fileSvg:`svg/AIRace.svg`},aperture:{glyph:``,size:24,tags:[`generic`,`camera`,`optical`,`sensor`],fileSvg:`svg/aperture.svg`},arrowLargeDown:{glyph:``,size:24,tags:[`arrow`,`large`,`simple`,`outlined`],fileSvg:`svg/arrowLargeDown.svg`},arrowLargeLeft:{glyph:``,size:24,tags:[`arrow`,`large`,`simple`,`outlined`],fileSvg:`svg/arrowLargeLeft.svg`},arrowLargeRight:{glyph:``,size:24,tags:[`arrow`,`large`,`simple`,`outlined`],fileSvg:`svg/arrowLargeRight.svg`},arrowLargeUp:{glyph:``,size:24,tags:[`arrow`,`large`,`simple`,`outlined`],fileSvg:`svg/arrowLargeUp.svg`},arrowSmallDown:{glyph:``,size:24,tags:[`arrow`,`small`,`simple`,`outlined`],fileSvg:`svg/arrowSmallDown.svg`},arrowSmallLeft:{glyph:``,size:24,tags:[`arrow`,`small`,`simple`,`outlined`],fileSvg:`svg/arrowSmallLeft.svg`},arrowSmallRight:{glyph:``,size:24,tags:[`arrow`,`small`,`simple`,`outlined`],fileSvg:`svg/arrowSmallRight.svg`},arrowSmallUp:{glyph:``,size:24,tags:[`arrow`,`small`,`simple`,`outlined`],fileSvg:`svg/arrowSmallUp.svg`},arrowSolidLeft:{glyph:``,size:24,tags:[`arrow`,`large`,`solid`,`detailed`],fileSvg:`svg/arrowSolidLeft.svg`},arrowSolidRight:{glyph:``,size:24,tags:[`arrow`,`large`,`solid`,`detailed`],fileSvg:`svg/arrowSolidRight.svg`},autobahn:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/autobahn.svg`},AWD:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/AWD.svg`},axleLift:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/axleLift.svg`},axleCenter:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/axleCenter.svg`},axleFront:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/axleFront.svg`},axleRear:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/axleRear.svg`},bSpline:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`,`road tools`],fileSvg:`svg/bSpline.svg`},banknotes:{glyph:``,size:24,tags:[`career`,`currencies`],fileSvg:`svg/banknotes.svg`},barrelKnocker01:{glyph:``,size:24,tags:[`poi`],fileSvg:`svg/barrelKnocker01.svg`},barrelKnocker02:{glyph:``,size:24,tags:[`poi`],fileSvg:`svg/barrelKnocker02.svg`},beamCrashBarrier1:{glyph:``,size:24,tags:[`generic`,`world editor`,`we`,`road tools`],fileSvg:`svg/beamCrashBarrier1.svg`},beamCrashBarrier2:{glyph:``,size:24,tags:[`generic`,`world editor`,`we`,`road tools`],fileSvg:`svg/beamCrashBarrier2.svg`},beamCrashBarrier3:{glyph:``,size:24,tags:[`generic`,`world editor`,`we`,`road tools`],fileSvg:`svg/beamCrashBarrier3.svg`},beamCurrency:{glyph:``,size:24,tags:[`career`,`currencies`],fileSvg:`svg/beamCurrency.svg`},beamNG:{glyph:``,size:24,tags:[`brand`,`beamng`,`generic`],fileSvg:`svg/beamNG.svg`},beamXPFull:{glyph:``,size:24,tags:[`career`,`currencies`],fileSvg:`svg/beamXPFull.svg`},beamXPLo:{glyph:``,size:24,tags:[`career`,`currencies`],fileSvg:`svg/beamXPLo.svg`},bezierPath1:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`,`road tools`],fileSvg:`svg/bezierPath1.svg`},bezierPath2:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`,`road tools`],fileSvg:`svg/bezierPath2.svg`},bicycle1:{glyph:``,size:24,tags:[`generic`,`world editor`,`we`,`road tools`],fileSvg:`svg/bicycle1.svg`},bicycle2:{glyph:``,size:24,tags:[`generic`,`world editor`,`we`,`road tools`],fileSvg:`svg/bicycle2.svg`},BNGFolder:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/BNGFolder.svg`},BNGMicrochip:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/BNGMicrochip.svg`},bollard:{glyph:``,size:24,tags:[`generic`,`world editor`,`we`,`road tools`],fileSvg:`svg/bollard.svg`},bookmark:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/bookmark.svg`},booleanIntersect:{glyph:``,size:24,tags:[`decals`,`generic`],fileSvg:`svg/booleanIntersect.svg`},boxDropOff01:{glyph:``,size:24,tags:[`poi`,`delivery`],fileSvg:`svg/boxDropOff01.svg`},boxDropOff02:{glyph:``,size:24,tags:[`poi`,`delivery`],fileSvg:`svg/boxDropOff02.svg`},boxDropOff03:{glyph:``,size:24,tags:[`poi`,`delivery`],fileSvg:`svg/boxDropOff03.svg`},boxPickUp01:{glyph:``,size:24,tags:[`poi`,`delivery`],fileSvg:`svg/boxPickUp01.svg`},boxPickUp02:{glyph:``,size:24,tags:[`poi`,`delivery`],fileSvg:`svg/boxPickUp02.svg`},boxPickUp03:{glyph:``,size:24,tags:[`poi`,`delivery`],fileSvg:`svg/boxPickUp03.svg`},boxPickUpDropOff01:{glyph:``,size:24,tags:[`poi`,`delivery`],fileSvg:`svg/boxPickUpDropOff01.svg`},boxPickUpDropOff02:{glyph:``,size:24,tags:[`poi`,`delivery`],fileSvg:`svg/boxPickUpDropOff02.svg`},boxTruck:{glyph:``,size:24,tags:[`cargo`,`delivery`,`vehicle`],fileSvg:`svg/boxTruck.svg`},broom:{glyph:``,size:24,tags:[`generic`,`sound`],fileSvg:`svg/broom.svg`},bucketAdd:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/bucketAdd.svg`},bucketSubtract:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/bucketSubtract.svg`},bug:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/bug.svg`},bulldozer:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`,`road tools`],fileSvg:`svg/bulldozer.svg`},bus:{glyph:``,size:24,tags:[`poi`,`vehicle`],fileSvg:`svg/bus.svg`},camera3Fourth1:{glyph:``,size:24,tags:[`camera`],fileSvg:`svg/camera3Fourth1.svg`},cameraBack1:{glyph:``,size:24,tags:[`camera`],fileSvg:`svg/cameraBack1.svg`},cameraFocusOnPath:{glyph:``,size:24,tags:[`camera`],fileSvg:`svg/cameraFocusOnPath.svg`},cameraFocusOnVehicle1:{glyph:``,size:24,tags:[`camera`],fileSvg:`svg/cameraFocusOnVehicle1.svg`},cameraFocusOnVehicle2:{glyph:``,size:24,tags:[`camera`,`decals`],fileSvg:`svg/cameraFocusOnVehicle2.svg`},cameraFocusTopDown:{glyph:``,size:24,tags:[`camera`],fileSvg:`svg/cameraFocusTopDown.svg`},cameraFront1:{glyph:``,size:24,tags:[`camera`],fileSvg:`svg/cameraFront1.svg`},cameraSideLeft:{glyph:``,size:24,tags:[`camera`],fileSvg:`svg/cameraSideLeft.svg`},cameraSideLeft2:{glyph:``,size:24,tags:[`camera`],fileSvg:`svg/cameraSideLeft2.svg`},cameraSideRight:{glyph:``,size:24,tags:[`camera`],fileSvg:`svg/cameraSideRight.svg`},cameraSideRight2:{glyph:``,size:24,tags:[`camera`],fileSvg:`svg/cameraSideRight2.svg`},cameraTop1:{glyph:``,size:24,tags:[`camera`],fileSvg:`svg/cameraTop1.svg`},cannon:{glyph:``,size:24,tags:[`poi`],fileSvg:`svg/cannon.svg`},carChase01:{glyph:``,size:24,tags:[`generic`,`police`,`vehicle`],fileSvg:`svg/carChase01.svg`},carCoin:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/carCoin.svg`},carCoins:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/carCoins.svg`},carCrash:{glyph:``,size:24,tags:[`generic`,`vehicle`],fileSvg:`svg/carCrash.svg`},carDealer:{glyph:``,size:24,tags:[`career`,`garage`,`features`],fileSvg:`svg/carDealer.svg`},carOffroadOutlineRear:{glyph:``,size:24,tags:[`generic`,`vehicle`],fileSvg:`svg/carOffroadOutlineRear.svg`},carOffroadOutlineSide:{glyph:``,size:24,tags:[`generic`,`vehicle`],fileSvg:`svg/carOffroadOutlineSide.svg`},carOffroadRear:{glyph:``,size:24,tags:[`generic`,`vehicle`],fileSvg:`svg/carOffroadRear.svg`},carOffroadSide:{glyph:``,size:24,tags:[`generic`,`vehicle`],fileSvg:`svg/carOffroadSide.svg`},carSensors:{glyph:``,size:24,tags:[`generic`,`vehicle`,`sensors`],fileSvg:`svg/carSensors.svg`},carStarred:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/carStarred.svg`},carToWheels:{glyph:``,size:24,tags:[`generic`,`vehicle`],fileSvg:`svg/carToWheels.svg`},carUp:{glyph:``,size:24,tags:[`generic`,`vehicle`],fileSvg:`svg/carUp.svg`},carWithLidar:{glyph:``,size:24,tags:[`generic`,`vehicle`,`tech`,`sensors`],fileSvg:`svg/carWithLidar.svg`},car:{glyph:``,size:24,tags:[`generic`,`vehicle`],fileSvg:`svg/car.svg`},cardboardBox:{glyph:``,size:24,tags:[`generic`,`delivery`],fileSvg:`svg/cardboardBox.svg`},carsChase02:{glyph:``,size:24,tags:[`generic`,`police`,`vehicle`],fileSvg:`svg/carsChase02.svg`},cars:{glyph:``,size:24,tags:[`generic`,`vehicle`],fileSvg:`svg/cars.svg`},catalog01:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/catalog01.svg`},catalog02:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/catalog02.svg`},catalog03:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/catalog03.svg`},centrifugalClutchLocked03:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/centrifugalClutchLocked03.svg`},centrifugalClutchUnlocked03:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/centrifugalClutchUnlocked03.svg`},charge:{glyph:``,size:24,tags:[`fuel`,`electricity`,`ev`],fileSvg:`svg/charge.svg`},charging:{glyph:``,size:24,tags:[`fuel`,`electricity`,`ev`],fileSvg:`svg/charging.svg`},chartBars:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/chartBars.svg`},checkboxOff:{glyph:``,size:24,tags:[`checkbox`,`selection`,`box`],fileSvg:`svg/checkboxOff.svg`},checkboxOn:{glyph:``,size:24,tags:[`checkbox`,`selection`,`box`],fileSvg:`svg/checkboxOn.svg`},checkmarkBold:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/checkmarkBold.svg`},checkmark:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/checkmark.svg`},circuitMicrochip:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/circuitMicrochip.svg`},circuit:{glyph:``,size:24,tags:[`poi`],fileSvg:`svg/circuit.svg`},clapperboard:{glyph:``,size:24,tags:[`generic`,`movie`,`scenery`],fileSvg:`svg/clapperboard.svg`},code:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/code.svg`},cogDamaged:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/cogDamaged.svg`},cogsDamaged:{glyph:``,size:24,tags:[`vehicle`,`features`,`powertrain`,`drivetrain`],fileSvg:`svg/cogsDamaged.svg`},cogs:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/cogs.svg`},concreteRoadBlock:{glyph:``,size:24,tags:[`generic`,`world editor`,`we`,`road tools`],fileSvg:`svg/concreteRoadBlock.svg`},coolantTemp:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/coolantTemp.svg`},copy:{glyph:``,size:24,tags:[`decals`,`generic`],fileSvg:`svg/copy.svg`},crossroads1:{glyph:``,size:24,tags:[`generic`,`world editor`,`we`,`road tools`],fileSvg:`svg/crossroads1.svg`},crossroads2:{glyph:``,size:24,tags:[`generic`,`world editor`,`we`,`road tools`],fileSvg:`svg/crossroads2.svg`},cruiseDisable:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/cruiseDisable.svg`},cruiseEnable:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/cruiseEnable.svg`},cup:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/cup.svg`},dataExchange:{glyph:``,size:24,tags:[`generic`,`data`,`signal`],fileSvg:`svg/dataExchange.svg`},day:{glyph:``,size:24,tags:[`environment`],fileSvg:`svg/day.svg`},DCBattery:{glyph:``,size:24,tags:[`vehicle`,`features`,`warning`,`internals`],fileSvg:`svg/DCBattery.svg`},decalRoad:{glyph:``,size:24,tags:[`generic`,`world editor`,`we`,`road tools`],fileSvg:`svg/decalRoad.svg`},decal:{glyph:``,size:24,tags:[`decals`,`generic`],fileSvg:`svg/decal.svg`},deform:{glyph:``,size:24,tags:[`decals`,`generic`],fileSvg:`svg/deform.svg`},deliveryTruckArrows:{glyph:``,size:24,tags:[`poi`,`delivery`,`vehicle`],fileSvg:`svg/deliveryTruckArrows.svg`},deliveryTruck:{glyph:``,size:24,tags:[`poi`,`delivery`,`vehicle`],fileSvg:`svg/deliveryTruck.svg`},differentialFrontDefault:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/differentialFrontDefault.svg`},differentialFrontLocked:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/differentialFrontLocked.svg`},differentialMiddleDefault:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/differentialMiddleDefault.svg`},differentialMiddleLocked:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/differentialMiddleLocked.svg`},differentialRearDefault:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/differentialRearDefault.svg`},differentialRearLocked:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/differentialRearLocked.svg`},doorHandle:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/doorHandle.svg`},doorIn:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/doorIn.svg`},drag01:{glyph:``,size:24,tags:[`poi`],fileSvg:`svg/drag01.svg`},drag02:{glyph:``,size:24,tags:[`poi`],fileSvg:`svg/drag02.svg`},drift01:{glyph:``,size:24,tags:[`poi`,`vehicle`],fileSvg:`svg/drift01.svg`},drift02:{glyph:``,size:24,tags:[`poi`,`vehicle`],fileSvg:`svg/drift02.svg`},drivetrainGeneric:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/drivetrainGeneric.svg`},drivetrainSpecial:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/drivetrainSpecial.svg`},editCheckmark:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/editCheckmark.svg`},edit:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/edit.svg`},engine:{glyph:``,size:24,tags:[`vehicle`,`part`,`features`],fileSvg:`svg/engine.svg`},ESCOff:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/ESCOff.svg`},ESCOn:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/ESCOn.svg`},ESC:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/ESC.svg`},evade:{glyph:``,size:24,tags:[`poi`,`mission`,`police`],fileSvg:`svg/evade.svg`},exhaustValve:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/exhaustValve.svg`},exit:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/exit.svg`},export:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/export.svg`},eyeOutlineClosed:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/eyeOutlineClosed.svg`},eyeOutlineOpened:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/eyeOutlineOpened.svg`},eyeSolidClosed:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/eyeSolidClosed.svg`},eyeSolidOpened:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/eyeSolidOpened.svg`},eyeWaves:{glyph:``,size:24,tags:[`generic`,`data`,`signal`,`sensor`],fileSvg:`svg/eyeWaves.svg`},facility02:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/facility02.svg`},fastBackward:{glyph:``,size:24,tags:[`playback`],fileSvg:`svg/fastBackward.svg`},fastForward:{glyph:``,size:24,tags:[`playback`],fileSvg:`svg/fastForward.svg`},fastTravel:{glyph:``,size:24,tags:[`poi`],fileSvg:`svg/fastTravel.svg`},filter:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/filter.svg`},flagNew:{glyph:``,size:24,tags:[`poi`],fileSvg:`svg/flagNew.svg`},flag:{glyph:``,size:24,tags:[`poi`],fileSvg:`svg/flag.svg`},flatBulbBeam:{glyph:``,size:24,tags:[`generic`,`world editor`,`we`,`sensor`],fileSvg:`svg/flatBulbBeam.svg`},flatbedTruck:{glyph:``,size:24,tags:[`cargo`,`delivery`,`vehicle`,`truck`],fileSvg:`svg/flatbedTruck.svg`},floppyDisk:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/floppyDisk.svg`},fogLight:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/fogLight.svg`},folder:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/folder.svg`},forklift:{glyph:``,size:24,tags:[`delivery`,`stencil`,`cargo`,`vehicle`],fileSvg:`svg/forklift.svg`},FPS:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/FPS.svg`},fragile:{glyph:``,size:24,tags:[`delivery`,`stencil`,`cargo`],fileSvg:`svg/fragile.svg`},frontAxleMidpoint:{glyph:``,size:24,tags:[`generic`,`world editor`,`we`,`placement`,`sensor`],fileSvg:`svg/frontAxleMidpoint.svg`},frontBumperMidpoint:{glyph:``,size:24,tags:[`generic`,`world editor`,`we`,`placement`,`sensor`],fileSvg:`svg/frontBumperMidpoint.svg`},fuelPumpFilling:{glyph:``,size:24,tags:[`fuel`],fileSvg:`svg/fuelPumpFilling.svg`},fuelPump:{glyph:``,size:24,tags:[`fuel`],fileSvg:`svg/fuelPump.svg`},FWD:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/FWD.svg`},gamepadOld:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/gamepadOld.svg`},gamepad:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/gamepad.svg`},garage01:{glyph:``,size:24,tags:[`career`,`garage`,`features`],fileSvg:`svg/garage01.svg`},garage02:{glyph:``,size:24,tags:[`career`,`garage`,`features`],fileSvg:`svg/garage02.svg`},garage03:{glyph:``,size:24,tags:[`career`,`garage`,`features`],fileSvg:`svg/garage03.svg`},gaugeEmpty:{glyph:``,size:24,tags:[`poi`],fileSvg:`svg/gaugeEmpty.svg`},globe:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/globe.svg`},GPSMark:{glyph:``,size:24,tags:[`generic`,`gps`,`position`,`map`,`sensor`],fileSvg:`svg/GPSMark.svg`},GPSSolid:{glyph:``,size:24,tags:[`generic`,`gps`,`position`,`map`,`sensor`],fileSvg:`svg/GPSSolid.svg`},group:{glyph:``,size:24,tags:[`decals`,`generic`],fileSvg:`svg/group.svg`},gyroscopeMicrochip:{glyph:``,size:24,tags:[`generic`,`data`,`signal`,`sensor`],fileSvg:`svg/gyroscopeMicrochip.svg`},gyroscope:{glyph:``,size:24,tags:[`generic`,`data`,`signal`,`sensor`],fileSvg:`svg/gyroscope.svg`},hazardLights:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/hazardLights.svg`},helmets:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/helmets.svg`},help:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/help.svg`},highBeam:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/highBeam.svg`},HUD:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/HUD.svg`},hydroPump1:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/hydroPump1.svg`},hydroPump2:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/hydroPump2.svg`},hydroPump3:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/hydroPump3.svg`},hydroPump4:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/hydroPump4.svg`},hydroPump5:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/hydroPump5.svg`},hydroPump6:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/hydroPump6.svg`},hydroPump7:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/hydroPump7.svg`},hypermiling:{glyph:``,size:24,tags:[`poi`],fileSvg:`svg/hypermiling.svg`},import:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/import.svg`},infinity:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/infinity.svg`},info:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/info.svg`},jointLocked:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/jointLocked.svg`},jointUnlocked:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/jointUnlocked.svg`},jump:{glyph:``,size:24,tags:[`poi`],fileSvg:`svg/jump.svg`},keyboard:{glyph:``,size:24,tags:[`keyboard`,`input`],fileSvg:`svg/keyboard.svg`},keys1:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/keys1.svg`},keys2:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/keys2.svg`},lampPost1:{glyph:``,size:24,tags:[`generic`,`world editor`,`we`,`road tools`],fileSvg:`svg/lampPost1.svg`},lampPost2:{glyph:``,size:24,tags:[`generic`,`world editor`,`we`,`road tools`],fileSvg:`svg/lampPost2.svg`},lampPost3:{glyph:``,size:24,tags:[`generic`,`world editor`,`we`,`road tools`],fileSvg:`svg/lampPost3.svg`},laneProperties:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`,`road tools`],fileSvg:`svg/laneProperties.svg`},language:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/language.svg`},laptop:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/laptop.svg`},lidarPatternFullArcHighFreq:{glyph:``,size:24,tags:[`generic`,`world editor`,`we`,`sensor`],fileSvg:`svg/lidarPatternFullArcHighFreq.svg`},lidarPatternFullArcMidFreq:{glyph:``,size:24,tags:[`generic`,`world editor`,`we`,`sensor`],fileSvg:`svg/lidarPatternFullArcMidFreq.svg`},lidarPatternNarrowArc:{glyph:``,size:24,tags:[`generic`,`world editor`,`we`,`sensor`],fileSvg:`svg/lidarPatternNarrowArc.svg`},lidar:{glyph:``,size:24,tags:[`generic`,`data`,`signal`,`sensor`],fileSvg:`svg/lidar.svg`},lightGarageG11:{glyph:``,size:24,tags:[`career`,`garage`,`lights`],fileSvg:`svg/lightGarageG11.svg`},lightGarageG12:{glyph:``,size:24,tags:[`career`,`garage`,`lights`],fileSvg:`svg/lightGarageG12.svg`},lightGarageG13:{glyph:``,size:24,tags:[`career`,`garage`,`lights`],fileSvg:`svg/lightGarageG13.svg`},lightGarageG14:{glyph:``,size:24,tags:[`career`,`garage`,`lights`],fileSvg:`svg/lightGarageG14.svg`},lightGarageG21:{glyph:``,size:24,tags:[`career`,`garage`,`lights`],fileSvg:`svg/lightGarageG21.svg`},lightGarageG22:{glyph:``,size:24,tags:[`career`,`garage`,`lights`],fileSvg:`svg/lightGarageG22.svg`},lightGarageG23:{glyph:``,size:24,tags:[`career`,`garage`,`lights`],fileSvg:`svg/lightGarageG23.svg`},lightGarageG24:{glyph:``,size:24,tags:[`career`,`garage`,`lights`],fileSvg:`svg/lightGarageG24.svg`},lightGarageG31:{glyph:``,size:24,tags:[`career`,`garage`,`lights`],fileSvg:`svg/lightGarageG31.svg`},lightGarageG32:{glyph:``,size:24,tags:[`career`,`garage`,`lights`],fileSvg:`svg/lightGarageG32.svg`},lightGarageG33:{glyph:``,size:24,tags:[`career`,`garage`,`lights`],fileSvg:`svg/lightGarageG33.svg`},lightGarageG34:{glyph:``,size:24,tags:[`career`,`garage`,`lights`],fileSvg:`svg/lightGarageG34.svg`},lightrunner:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/lightrunner.svg`},limiterEnable:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/limiterEnable.svg`},lineToTerrain:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`,`road tools`],fileSvg:`svg/lineToTerrain.svg`},link2:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/link2.svg`},link:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/link.svg`},listBig:{glyph:``,size:24,tags:[`generic`,`catalog`,`selector`,`view`],fileSvg:`svg/listBig.svg`},listIndented:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/listIndented.svg`},listSmall:{glyph:``,size:24,tags:[`generic`,`catalog`,`selector`,`view`],fileSvg:`svg/listSmall.svg`},location1:{glyph:``,size:24,tags:[`generic`,`gps`,`position`,`map`,`sensor`],fileSvg:`svg/location1.svg`},location2:{glyph:``,size:24,tags:[`generic`,`gps`,`position`,`map`,`sensor`],fileSvg:`svg/location2.svg`},lockClosed:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/lockClosed.svg`},lockOpened:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/lockOpened.svg`},longRangeBeam1:{glyph:``,size:24,tags:[`generic`,`world editor`,`we`,`sensor`],fileSvg:`svg/longRangeBeam1.svg`},longRangeBeam2:{glyph:``,size:24,tags:[`generic`,`world editor`,`we`,`sensor`],fileSvg:`svg/longRangeBeam2.svg`},lowBeam:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/lowBeam.svg`},magnetOnSurface:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`,`road tools`],fileSvg:`svg/magnetOnSurface.svg`},mapWithEmitter:{glyph:``,size:24,tags:[`generic`,`tech`,`sensors`],fileSvg:`svg/mapWithEmitter.svg`},mapPoint:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/mapPoint.svg`},material:{glyph:``,size:24,tags:[`decals`,`generic`],fileSvg:`svg/material.svg`},mathDivide:{glyph:``,size:24,tags:[`generic`,`math`,`operands`,`small`],fileSvg:`svg/mathDivide.svg`},mathGreaterOrEqualThan:{glyph:``,size:24,tags:[`generic`,`math`,`operands`,`small`],fileSvg:`svg/mathGreaterOrEqualThan.svg`},mathGreaterThan:{glyph:``,size:24,tags:[`generic`,`math`,`operands`,`small`],fileSvg:`svg/mathGreaterThan.svg`},mathLessOrEqualThan:{glyph:``,size:24,tags:[`generic`,`math`,`operands`,`small`],fileSvg:`svg/mathLessOrEqualThan.svg`},mathLessThan:{glyph:``,size:24,tags:[`generic`,`math`,`operands`,`small`],fileSvg:`svg/mathLessThan.svg`},mathMinus:{glyph:``,size:24,tags:[`generic`,`math`,`operands`,`small`],fileSvg:`svg/mathMinus.svg`},mathMultiply:{glyph:``,size:24,tags:[`generic`,`math`,`operands`,`small`],fileSvg:`svg/mathMultiply.svg`},mathPlus:{glyph:``,size:24,tags:[`generic`,`math`,`operands`,`small`],fileSvg:`svg/mathPlus.svg`},medal:{glyph:``,size:24,tags:[`generic`,`reward`,`achievment`],fileSvg:`svg/medal.svg`},mesh4Cells:{glyph:``,size:24,tags:[`tech`,`mesh`,`beams`,`nodes`,`surface`],fileSvg:`svg/mesh4Cells.svg`},mesh9Cells:{glyph:``,size:24,tags:[`tech`,`mesh`,`beams`,`nodes`,`surface`],fileSvg:`svg/mesh9Cells.svg`},meshFence:{glyph:``,size:24,tags:[`generic`,`world editor`,`we`,`road tools`],fileSvg:`svg/meshFence.svg`},meshRoad:{glyph:``,size:24,tags:[`generic`,`world editor`,`we`,`road tools`],fileSvg:`svg/meshRoad.svg`},midRangeBeam1:{glyph:``,size:24,tags:[`generic`,`world editor`,`we`,`sensor`],fileSvg:`svg/midRangeBeam1.svg`},midRangeBeam2:{glyph:``,size:24,tags:[`generic`,`world editor`,`we`,`sensor`],fileSvg:`svg/midRangeBeam2.svg`},minusRes:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/minusRes.svg`},minus:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/minus.svg`},mirrorInteriorMiddle:{glyph:``,size:24,tags:[`vehicle`,`features`,`mirror`,`rearview`],fileSvg:`svg/mirrorInteriorMiddle.svg`},mirrorLeftBigBottomWideAngle:{glyph:``,size:24,tags:[`vehicle`,`features`,`mirror`,`rearview`],fileSvg:`svg/mirrorLeftBigBottomWideAngle.svg`},mirrorLeftBigTop:{glyph:``,size:24,tags:[`vehicle`,`features`,`mirror`,`rearview`],fileSvg:`svg/mirrorLeftBigTop.svg`},mirrorLeftBig:{glyph:``,size:24,tags:[`vehicle`,`features`,`mirror`,`rearview`],fileSvg:`svg/mirrorLeftBig.svg`},mirrorLeftBonnet:{glyph:``,size:24,tags:[`vehicle`,`features`,`mirror`,`rearview`],fileSvg:`svg/mirrorLeftBonnet.svg`},mirrorLeftDefault:{glyph:``,size:24,tags:[`vehicle`,`features`,`mirror`,`rearview`],fileSvg:`svg/mirrorLeftDefault.svg`},mirrorRightBigBottomWideAngle:{glyph:``,size:24,tags:[`vehicle`,`features`,`mirror`,`rearview`],fileSvg:`svg/mirrorRightBigBottomWideAngle.svg`},mirrorRightBigTop:{glyph:``,size:24,tags:[`vehicle`,`features`,`mirror`,`rearview`],fileSvg:`svg/mirrorRightBigTop.svg`},mirrorRightBig:{glyph:``,size:24,tags:[`vehicle`,`features`,`mirror`,`rearview`],fileSvg:`svg/mirrorRightBig.svg`},mirrorRightBonnet:{glyph:``,size:24,tags:[`vehicle`,`features`,`mirror`,`rearview`],fileSvg:`svg/mirrorRightBonnet.svg`},mirrorRightDefault:{glyph:``,size:24,tags:[`vehicle`,`features`,`mirror`,`rearview`],fileSvg:`svg/mirrorRightDefault.svg`},mirrorRoundWideAngle:{glyph:``,size:24,tags:[`vehicle`,`features`,`mirror`,`rearview`],fileSvg:`svg/mirrorRoundWideAngle.svg`},mirrorTopWideAngle:{glyph:``,size:24,tags:[`vehicle`,`features`,`mirror`,`rearview`],fileSvg:`svg/mirrorTopWideAngle.svg`},missionCheckboxCross:{glyph:``,size:24,tags:[`checkbox`,`selection`,`box`],fileSvg:`svg/missionCheckboxCross.svg`},mouseLMB:{glyph:``,size:24,tags:[`mouse`,`input`],fileSvg:`svg/mouseLMB.svg`},mouseMMB:{glyph:``,size:24,tags:[`mouse`,`input`],fileSvg:`svg/mouseMMB.svg`},mouseRMB:{glyph:``,size:24,tags:[`mouse`,`input`],fileSvg:`svg/mouseRMB.svg`},mouseWheel:{glyph:``,size:24,tags:[`mouse`,`input`],fileSvg:`svg/mouseWheel.svg`},mouseXAxis:{glyph:``,size:24,tags:[`mouse`,`input`],fileSvg:`svg/mouseXAxis.svg`},mouseXYAxis:{glyph:``,size:24,tags:[`mouse`,`input`],fileSvg:`svg/mouseXYAxis.svg`},mouseYAxis:{glyph:``,size:24,tags:[`mouse`,`input`],fileSvg:`svg/mouseYAxis.svg`},mouse:{glyph:``,size:24,tags:[`mouse`,`input`],fileSvg:`svg/mouse.svg`},move02:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/move02.svg`},move:{glyph:``,size:24,tags:[`decals`,`generic`],fileSvg:`svg/move.svg`},movieCamera:{glyph:``,size:24,tags:[`camera`],fileSvg:`svg/movieCamera.svg`},music:{glyph:``,size:24,tags:[`playback`],fileSvg:`svg/music.svg`},N2OButton:{glyph:``,size:24,tags:[`fuel`],fileSvg:`svg/N2OButton.svg`},N2OHoriz:{glyph:``,size:24,tags:[`fuel`],fileSvg:`svg/N2OHoriz.svg`},N2OVert:{glyph:``,size:24,tags:[`fuel`],fileSvg:`svg/N2OVert.svg`},nextTrack:{glyph:``,size:24,tags:[`playback`],fileSvg:`svg/nextTrack.svg`},night:{glyph:``,size:24,tags:[`environment`],fileSvg:`svg/night.svg`},noNameControllerButton:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/noNameControllerButton.svg`},nodeAddFirst01:{glyph:``,size:24,tags:[`generic`,`path`,`node`],fileSvg:`svg/nodeAddFirst01.svg`},nodeAddFirst02:{glyph:``,size:24,tags:[`generic`,`path`,`node`],fileSvg:`svg/nodeAddFirst02.svg`},nodeAddLast02:{glyph:``,size:24,tags:[`generic`,`path`,`node`],fileSvg:`svg/nodeAddLast02.svg`},nodeAddMiddle01:{glyph:``,size:24,tags:[`generic`,`path`,`node`],fileSvg:`svg/nodeAddMiddle01.svg`},nodeAddMiddle02:{glyph:``,size:24,tags:[`generic`,`path`,`node`],fileSvg:`svg/nodeAddMiddle02.svg`},nodeAdd:{glyph:``,size:24,tags:[`generic`,`path`,`node`],fileSvg:`svg/nodeAdd.svg`},nodeLast01:{glyph:``,size:24,tags:[`generic`,`path`,`node`],fileSvg:`svg/nodeLast01.svg`},nodeRemove:{glyph:``,size:24,tags:[`generic`,`path`,`node`],fileSvg:`svg/nodeRemove.svg`},odometerKM:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/odometerKM.svg`},odometerMI:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/odometerMI.svg`},odometer:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/odometer.svg`},oilPressureIndicator:{glyph:``,size:24,tags:[`vehicle`,`features`,`warning`,`internals`],fileSvg:`svg/oilPressureIndicator.svg`},order:{glyph:``,size:24,tags:[`decals`,`generic`],fileSvg:`svg/order.svg`},organization:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/organization.svg`},palmCrossed:{glyph:``,size:24,tags:[`touch`,`input`],fileSvg:`svg/palmCrossed.svg`},paperKnife:{glyph:``,size:24,tags:[`decals`,`generic`],fileSvg:`svg/paperKnife.svg`},parkingIndicator:{glyph:``,size:24,tags:[`vehicle`,`features`,`warning`,`internals`],fileSvg:`svg/parkingIndicator.svg`},parking:{glyph:``,size:24,tags:[`poi`],fileSvg:`svg/parking.svg`},pathArc:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`,`road tools`],fileSvg:`svg/pathArc.svg`},pathAroundObstacle:{glyph:``,size:24,tags:[`camera`],fileSvg:`svg/pathAroundObstacle.svg`},pathLine:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`,`road tools`],fileSvg:`svg/pathLine.svg`},pathSpiral:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`,`road tools`],fileSvg:`svg/pathSpiral.svg`},pauseRound:{glyph:``,size:24,tags:[`playback`],fileSvg:`svg/pauseRound.svg`},pause:{glyph:``,size:24,tags:[`playback`],fileSvg:`svg/pause.svg`},personSolid:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/personSolid.svg`},person:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/person.svg`},photo:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/photo.svg`},placeholder:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/placeholder.svg`},playRound:{glyph:``,size:24,tags:[`playback`],fileSvg:`svg/playRound.svg`},play:{glyph:``,size:24,tags:[`playback`],fileSvg:`svg/play.svg`},playlist:{glyph:``,size:24,tags:[`playback`],fileSvg:`svg/playlist.svg`},plusGarage1:{glyph:``,size:24,tags:[`career`,`garage`,`features`],fileSvg:`svg/plusGarage1.svg`},plusGarage2:{glyph:``,size:24,tags:[`career`,`garage`,`features`],fileSvg:`svg/plusGarage2.svg`},plusGarage3:{glyph:``,size:24,tags:[`career`,`garage`,`features`],fileSvg:`svg/plusGarage3.svg`},plusGarage4:{glyph:``,size:24,tags:[`career`,`garage`,`features`],fileSvg:`svg/plusGarage4.svg`},plusSet:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/plusSet.svg`},plus:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/plus.svg`},positionLights:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/positionLights.svg`},powerGauge01:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/powerGauge01.svg`},powerGauge02:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/powerGauge02.svg`},powerGauge03:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/powerGauge03.svg`},powerGauge04:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/powerGauge04.svg`},powerGauge05:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/powerGauge05.svg`},powerOnOff:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/powerOnOff.svg`},prevTrack:{glyph:``,size:24,tags:[`playback`],fileSvg:`svg/prevTrack.svg`},publisher:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/publisher.svg`},puzzleModule:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/puzzleModule.svg`},raceFlag:{glyph:``,size:24,tags:[`poi`],fileSvg:`svg/raceFlag.svg`},radarIdeal:{glyph:``,size:24,tags:[`generic`,`data`,`signal`,`sensor`],fileSvg:`svg/radarIdeal.svg`},radarRoundIdeal:{glyph:``,size:24,tags:[`generic`,`data`,`signal`,`sensor`],fileSvg:`svg/radarRoundIdeal.svg`},radarRound:{glyph:``,size:24,tags:[`generic`,`data`,`signal`,`sensor`],fileSvg:`svg/radarRound.svg`},radar:{glyph:``,size:24,tags:[`generic`,`data`,`signal`,`sensor`],fileSvg:`svg/radar.svg`},rangeboxHi2:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/rangeboxHi2.svg`},rangeboxHi4:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/rangeboxHi4.svg`},rangeboxHiA:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/rangeboxHiA.svg`},rangeboxLo2:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/rangeboxLo2.svg`},rangeboxLo4:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/rangeboxLo4.svg`},rangeboxLoA:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/rangeboxLoA.svg`},rearAxleMidpoint:{glyph:``,size:24,tags:[`generic`,`world editor`,`we`,`placement`,`sensor`],fileSvg:`svg/rearAxleMidpoint.svg`},rearBumperMidpoint:{glyph:``,size:24,tags:[`generic`,`world editor`,`we`,`placement`,`sensor`],fileSvg:`svg/rearBumperMidpoint.svg`},reconfigure:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/reconfigure.svg`},redo:{glyph:``,size:24,tags:[`decals`,`generic`],fileSvg:`svg/redo.svg`},reflectNot:{glyph:``,size:24,tags:[`decals`,`generic`],fileSvg:`svg/reflectNot.svg`},reflect:{glyph:``,size:24,tags:[`decals`,`generic`],fileSvg:`svg/reflect.svg`},rename:{glyph:``,size:24,tags:[`decals`,`generic`],fileSvg:`svg/rename.svg`},replay:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/replay.svg`},restart:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/restart.svg`},roadDividerLinesDecal:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`,`road tools`],fileSvg:`svg/roadDividerLinesDecal.svg`},roadEdgeLineDecal:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`,`road tools`],fileSvg:`svg/roadEdgeLineDecal.svg`},roadEndLineDecal:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`,`road tools`],fileSvg:`svg/roadEndLineDecal.svg`},roadFace:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`,`road tools`],fileSvg:`svg/roadFace.svg`},roadInfo:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/roadInfo.svg`},roadMarkingOutline:{glyph:``,size:24,tags:[`generic`,`world editor`,`we`,`outlined`],fileSvg:`svg/roadMarkingOutline.svg`},roadMarkingSolid:{glyph:``,size:24,tags:[`generic`,`world editor`,`we`,`road tools`],fileSvg:`svg/roadMarkingSolid.svg`},roadOutline:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`,`road tools`],fileSvg:`svg/roadOutline.svg`},roadRefPathDecal:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`,`road tools`],fileSvg:`svg/roadRefPathDecal.svg`},roadRefPath:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`,`road tools`],fileSvg:`svg/roadRefPath.svg`},roadStartLineDecal:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`,`road tools`],fileSvg:`svg/roadStartLineDecal.svg`},road:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/road.svg`},rockCrawling01:{glyph:``,size:24,tags:[`poi`,`vehicle`],fileSvg:`svg/rockCrawling01.svg`},rockCrawling02:{glyph:``,size:24,tags:[`poi`],fileSvg:`svg/rockCrawling02.svg`},routeAdd:{glyph:``,size:24,tags:[`route`,`traffic`],fileSvg:`svg/routeAdd.svg`},routeComplex:{glyph:``,size:24,tags:[`route`,`traffic`],fileSvg:`svg/routeComplex.svg`},routeSimple:{glyph:``,size:24,tags:[`route`,`traffic`],fileSvg:`svg/routeSimple.svg`},runScript:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/runScript.svg`},RWD:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/RWD.svg`},saveAs1:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/saveAs1.svg`},scan:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/scan.svg`},search:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/search.svg`},semiTrailer:{glyph:``,size:24,tags:[`cargo`,`delivery`,`trailer`,`vehicle`],fileSvg:`svg/semiTrailer.svg`},semiTruckCabover:{glyph:``,size:24,tags:[`cargo`,`delivery`,`vehicle`,`truck`],fileSvg:`svg/semiTruckCabover.svg`},semiTruckUS:{glyph:``,size:24,tags:[`cargo`,`delivery`,`vehicle`,`truck`],fileSvg:`svg/semiTruckUS.svg`},semiTruck:{glyph:``,size:24,tags:[`cargo`,`delivery`,`truck`,`trailer`,`vehicle`],fileSvg:`svg/semiTruck.svg`},shortRangeBeam1:{glyph:``,size:24,tags:[`generic`,`world editor`,`we`,`sensor`],fileSvg:`svg/shortRangeBeam1.svg`},shortRangeBeam2:{glyph:``,size:24,tags:[`generic`,`world editor`,`we`,`sensor`],fileSvg:`svg/shortRangeBeam2.svg`},signal01a:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/signal01a.svg`},signal02a:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/signal02a.svg`},signal03a:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/signal03a.svg`},signal04a:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/signal04a.svg`},signal05a:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/signal05a.svg`},slashLeft:{glyph:``,size:24,tags:[`generic`,`math`,`operands`,`small`],fileSvg:`svg/slashLeft.svg`},slashRight:{glyph:``,size:24,tags:[`generic`,`math`,`operands`,`small`],fileSvg:`svg/slashRight.svg`},smallTrailer:{glyph:``,size:24,tags:[`cargo`,`delivery`,`trailer`,`vehicle`],fileSvg:`svg/smallTrailer.svg`},smartphone1:{glyph:``,size:24,tags:[`touch`,`input`],fileSvg:`svg/smartphone1.svg`},smartphone2:{glyph:``,size:24,tags:[`touch`,`input`],fileSvg:`svg/smartphone2.svg`},snowflake:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/snowflake.svg`},soundFadeOut:{glyph:``,size:24,tags:[`generic`,`sound`],fileSvg:`svg/soundFadeOut.svg`},soundLimit:{glyph:``,size:24,tags:[`generic`,`sound`],fileSvg:`svg/soundLimit.svg`},soundLoud:{glyph:``,size:24,tags:[`generic`,`sound`],fileSvg:`svg/soundLoud.svg`},soundMonoL:{glyph:``,size:24,tags:[`generic`,`sound`],fileSvg:`svg/soundMonoL.svg`},soundMonoR:{glyph:``,size:24,tags:[`generic`,`sound`],fileSvg:`svg/soundMonoR.svg`},soundOff:{glyph:``,size:24,tags:[`generic`,`sound`],fileSvg:`svg/soundOff.svg`},soundQuiet:{glyph:``,size:24,tags:[`generic`,`sound`],fileSvg:`svg/soundQuiet.svg`},soundStereo:{glyph:``,size:24,tags:[`generic`,`sound`],fileSvg:`svg/soundStereo.svg`},soundWave01:{glyph:``,size:24,tags:[`generic`,`sound`],fileSvg:`svg/soundWave01.svg`},soundWave02:{glyph:``,size:24,tags:[`generic`,`sound`],fileSvg:`svg/soundWave02.svg`},sphereOnPathNumber:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`,`road tools`],fileSvg:`svg/sphereOnPathNumber.svg`},sphereOnPath:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`,`road tools`],fileSvg:`svg/sphereOnPath.svg`},sphericalBeam:{glyph:``,size:24,tags:[`generic`,`world editor`,`we`,`sensor`],fileSvg:`svg/sphericalBeam.svg`},spoilerLift:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/spoilerLift.svg`},sprayCan:{glyph:``,size:24,tags:[`decals`,`generic`],fileSvg:`svg/sprayCan.svg`},stack3:{glyph:``,size:24,tags:[`delivery`,`stencil`,`cargo`],fileSvg:`svg/stack3.svg`},star:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/star.svg`},starSecondary:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/starSecondary.svg`},steeringWheelCommon:{glyph:``,size:24,tags:[`steering`,`controller`,`input`],fileSvg:`svg/steeringWheelCommon.svg`},steeringWheelSporty:{glyph:``,size:24,tags:[`steering`,`controller`,`input`],fileSvg:`svg/steeringWheelSporty.svg`},stopwatchArrows01:{glyph:``,size:24,tags:[`generic`,`time`,`fast`],fileSvg:`svg/stopwatchArrows01.svg`},stopwatchArrows02:{glyph:``,size:24,tags:[`generic`,`time`,`fast`],fileSvg:`svg/stopwatchArrows02.svg`},stopwatchSectionOutlinedEnd:{glyph:``,size:24,tags:[`generic`,`time`,`fast`],fileSvg:`svg/stopwatchSectionOutlinedEnd.svg`},stopwatchSectionOutlinedStart:{glyph:``,size:24,tags:[`generic`,`time`,`fast`],fileSvg:`svg/stopwatchSectionOutlinedStart.svg`},stopwatchSectionSolidEnd:{glyph:``,size:24,tags:[`generic`,`time`,`fast`],fileSvg:`svg/stopwatchSectionSolidEnd.svg`},stopwatchSectionSolidStart:{glyph:``,size:24,tags:[`generic`,`time`,`fast`],fileSvg:`svg/stopwatchSectionSolidStart.svg`},strobeLights:{glyph:``,size:24,tags:[`vehicle`,`features`,`police`,`emergency`],fileSvg:`svg/strobeLights.svg`},sunRise:{glyph:``,size:24,tags:[`environment`],fileSvg:`svg/sunRise.svg`},survellianceCamera:{glyph:``,size:24,tags:[`generic`,`camera`,`optical`,`sensor`],fileSvg:`svg/survellianceCamera.svg`},suspension01:{glyph:``,size:24,tags:[`vehicle`,`features`,`part`],fileSvg:`svg/suspension01.svg`},suspension02:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/suspension02.svg`},switchBlock:{glyph:``,size:24,tags:[`generic`,`circuit`,`electronics`,`switch`],fileSvg:`svg/switchBlock.svg`},switchOutline:{glyph:``,size:24,tags:[`generic`,`circuit`,`electronics`,`switch`],fileSvg:`svg/switchOutline.svg`},sync:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/sync.svg`},synchro01:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/synchro01.svg`},synchro02:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/synchro02.svg`},tankerTrailer:{glyph:``,size:24,tags:[`cargo`,`delivery`,`tank`,`tanker`,`trailer`,`vehicle`],fileSvg:`svg/tankerTrailer.svg`},targetJump:{glyph:``,size:24,tags:[`poi`],fileSvg:`svg/targetJump.svg`},taxiCar1:{glyph:``,size:24,tags:[`taxi`,`generic`,`vehicle`],fileSvg:`svg/taxiCar1.svg`},taxiCar3:{glyph:``,size:24,tags:[`taxi`,`generic`,`vehicle`],fileSvg:`svg/taxiCar3.svg`},taxiCarT:{glyph:``,size:24,tags:[`taxi`,`generic`,`vehicle`],fileSvg:`svg/taxiCarT.svg`},taxiCheckerLamp:{glyph:``,size:24,tags:[`taxi`,`generic`,`vehicle`],fileSvg:`svg/taxiCheckerLamp.svg`},terrainToLine:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`,`road tools`],fileSvg:`svg/terrainToLine.svg`},terrain:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/terrain.svg`},thinBulbBeam:{glyph:``,size:24,tags:[`generic`,`world editor`,`we`,`sensor`],fileSvg:`svg/thinBulbBeam.svg`},thinnerBulbBeam:{glyph:``,size:24,tags:[`generic`,`world editor`,`we`,`sensor`],fileSvg:`svg/thinnerBulbBeam.svg`},thisSideUp:{glyph:``,size:24,tags:[`delivery`,`stencil`,`cargo`],fileSvg:`svg/thisSideUp.svg`},tiles:{glyph:``,size:24,tags:[`generic`,`catalog`,`selector`,`view`],fileSvg:`svg/tiles.svg`},timer:{glyph:``,size:24,tags:[`generic`,`time`,`fast`],fileSvg:`svg/timer.svg`},tireDirection3Fourth2:{glyph:``,size:24,tags:[`tire`],fileSvg:`svg/tireDirection3Fourth2.svg`},tireDirection3Fourth3:{glyph:``,size:24,tags:[`tire`],fileSvg:`svg/tireDirection3Fourth3.svg`},tireDirectionFront2:{glyph:``,size:24,tags:[`tire`],fileSvg:`svg/tireDirectionFront2.svg`},tireDirectionSide2:{glyph:``,size:24,tags:[`tire`],fileSvg:`svg/tireDirectionSide2.svg`},tireDirectionTop2:{glyph:``,size:24,tags:[`tire`],fileSvg:`svg/tireDirectionTop2.svg`},tirePressureDecrease01:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/tirePressureDecrease01.svg`},tirePressureDecrease02:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/tirePressureDecrease02.svg`},tirePressureGaugeAlt01:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/tirePressureGaugeAlt01.svg`},tirePressureGaugeAlt02:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/tirePressureGaugeAlt02.svg`},tirePressureGaugeAlt03:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/tirePressureGaugeAlt03.svg`},tirePressureGaugeOutlined01:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/tirePressureGaugeOutlined01.svg`},tirePressureGaugeOutlined02:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/tirePressureGaugeOutlined02.svg`},tirePressureGaugeOutlined03:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/tirePressureGaugeOutlined03.svg`},tirePressureGaugeSolid01:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/tirePressureGaugeSolid01.svg`},tirePressureGaugeSolid02:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/tirePressureGaugeSolid02.svg`},tirePressureGaugeSolid03:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/tirePressureGaugeSolid03.svg`},tirePressureIncrease01:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/tirePressureIncrease01.svg`},tirePressureIncrease02:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/tirePressureIncrease02.svg`},tirePressureStopLine:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/tirePressureStopLine.svg`},tirePressureStopOctoLine:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/tirePressureStopOctoLine.svg`},tirePressureStopOctoSolid:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/tirePressureStopOctoSolid.svg`},tirePressureStopSolid:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/tirePressureStopSolid.svg`},toCOMWithWheels:{glyph:``,size:24,tags:[`generic`,`world editor`,`we`,`placement`,`sensor`],fileSvg:`svg/toCOMWithWheels.svg`},toCOM:{glyph:``,size:24,tags:[`generic`,`world editor`,`we`,`placement`,`sensor`],fileSvg:`svg/toCOM.svg`},toGarage:{glyph:``,size:24,tags:[`poi`],fileSvg:`svg/toGarage.svg`},touch:{glyph:``,size:24,tags:[`touch`,`input`],fileSvg:`svg/touch.svg`},tow:{glyph:``,size:24,tags:[`generic`,`vehicle`],fileSvg:`svg/tow.svg`},tractionControl:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/tractionControl.svg`},trafficCone:{glyph:``,size:24,tags:[`route`,`traffic`],fileSvg:`svg/trafficCone.svg`},transform:{glyph:``,size:24,tags:[`decals`,`generic`],fileSvg:`svg/transform.svg`},transmissionA:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/transmissionA.svg`},transmissionM:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/transmissionM.svg`},transparencyMask:{glyph:``,size:24,tags:[`decals`,`generic`],fileSvg:`svg/transparencyMask.svg`},trashBin1:{glyph:``,size:24,tags:[`poi`],fileSvg:`svg/trashBin1.svg`},trashBin2:{glyph:``,size:24,tags:[`decals`,`generic`],fileSvg:`svg/trashBin2.svg`},triangleBeam:{glyph:``,size:24,tags:[`generic`,`world editor`,`we`,`sensor`],fileSvg:`svg/triangleBeam.svg`},trim:{glyph:``,size:24,tags:[`generic`,`sound`],fileSvg:`svg/trim.svg`},tulipBeam:{glyph:``,size:24,tags:[`generic`,`world editor`,`we`,`sensor`],fileSvg:`svg/tulipBeam.svg`},tunnel:{glyph:``,size:24,tags:[`generic`,`world editor`,`we`,`road tools`],fileSvg:`svg/tunnel.svg`},turbine:{glyph:``,size:24,tags:[`vehicle`,`part`,`features`],fileSvg:`svg/turbine.svg`},twoRoadsAdd:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`,`road tools`],fileSvg:`svg/twoRoadsAdd.svg`},twoRoadsCrossAdd:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`,`road tools`],fileSvg:`svg/twoRoadsCrossAdd.svg`},twoRoadsLink:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`,`road tools`],fileSvg:`svg/twoRoadsLink.svg`},twoUnicyclesOnly:{glyph:``,size:24,tags:[`delivery`,`stencil`,`cargo`],fileSvg:`svg/twoUnicyclesOnly.svg`},undo:{glyph:``,size:24,tags:[`decals`,`generic`],fileSvg:`svg/undo.svg`},ungroup:{glyph:``,size:24,tags:[`decals`,`generic`],fileSvg:`svg/ungroup.svg`},unlink:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/unlink.svg`},vehicleDoorsClose:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/vehicleDoorsClose.svg`},vehicleDoorsOpen:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/vehicleDoorsOpen.svg`},vehicleDoors:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/vehicleDoors.svg`},vehicleFeatures01:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/vehicleFeatures01.svg`},vehicleFeatures02:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/vehicleFeatures02.svg`},vehicleFeatures03:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/vehicleFeatures03.svg`},vehicleHood:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/vehicleHood.svg`},vehicleTrunk:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/vehicleTrunk.svg`},view:{glyph:``,size:24,tags:[`decals`,`generic`],fileSvg:`svg/view.svg`},voucherDiagonal1:{glyph:``,size:24,tags:[`generic`,`currency`,`reward`,`career`],fileSvg:`svg/voucherDiagonal1.svg`},voucherDiagonal2:{glyph:``,size:24,tags:[`generic`,`currency`,`reward`,`career`],fileSvg:`svg/voucherDiagonal2.svg`},voucherDiagonal3:{glyph:``,size:24,tags:[`generic`,`currency`,`reward`,`career`],fileSvg:`svg/voucherDiagonal3.svg`},voucherHorizontal1:{glyph:``,size:24,tags:[`generic`,`currency`,`reward`,`career`],fileSvg:`svg/voucherHorizontal1.svg`},voucherHorizontal2:{glyph:``,size:24,tags:[`generic`,`currency`,`reward`,`career`],fileSvg:`svg/voucherHorizontal2.svg`},voucherHorizontal3:{glyph:``,size:24,tags:[`generic`,`currency`,`reward`,`career`],fileSvg:`svg/voucherHorizontal3.svg`},wavesSignalReceived:{glyph:``,size:24,tags:[`generic`,`data`,`signal`,`sensor`],fileSvg:`svg/wavesSignalReceived.svg`},wavesSignalSentLeft:{glyph:``,size:24,tags:[`generic`,`data`,`signal`,`sensor`],fileSvg:`svg/wavesSignalSentLeft.svg`},wavesSignalSentRight:{glyph:``,size:24,tags:[`generic`,`data`,`signal`,`sensor`],fileSvg:`svg/wavesSignalSentRight.svg`},weather:{glyph:``,size:24,tags:[`environment`],fileSvg:`svg/weather.svg`},weight:{glyph:``,size:24,tags:[`decals`,`generic`],fileSvg:`svg/weight.svg`},wheelHubLocked01:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/wheelHubLocked01.svg`},wheelHubUnlocked01:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/wheelHubUnlocked01.svg`},wigwags:{glyph:``,size:24,tags:[`vehicle`,`features`,`police`,`emergency`],fileSvg:`svg/wigwags.svg`},wrench:{glyph:``,size:24,tags:[`generic`,`vehicle`,`features`],fileSvg:`svg/wrench.svg`},xboxA:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/xboxA.svg`},xboxB:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/xboxB.svg`},xboxDDefaultOutline:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/xboxDDefaultOutline.svg`},xboxDDefaultSolid:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/xboxDDefaultSolid.svg`},xboxDDown:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/xboxDDown.svg`},xboxDLeft:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/xboxDLeft.svg`},xboxDRight:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/xboxDRight.svg`},xboxDUp:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/xboxDUp.svg`},xboxLB:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/xboxLB.svg`},xboxLSButton:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/xboxLSButton.svg`},xboxLT:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/xboxLT.svg`},xboxMenu:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/xboxMenu.svg`},xboxRB:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/xboxRB.svg`},xboxRSButton:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/xboxRSButton.svg`},xboxRT:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/xboxRT.svg`},xboxThumbL:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/xboxThumbL.svg`},xboxThumbR:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/xboxThumbR.svg`},xboxView:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/xboxView.svg`},xboxXAxis:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/xboxXAxis.svg`},xboxXRot:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/xboxXRot.svg`},xboxX:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/xboxX.svg`},xboxYAxis:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/xboxYAxis.svg`},xboxYRot:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/xboxYRot.svg`},xboxY:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/xboxY.svg`},AIL:{glyph:``,size:48,tags:[`extra`],fileSvg:`svg/AIL.svg`},arrowLeftOutline:{glyph:``,size:48,tags:[`web`,`outlined`,`large`,`secondary`],fileSvg:`svg/arrowLeftOutline.svg`},arrowRightOutline:{glyph:``,size:48,tags:[`web`,`outlined`,`large`,`secondary`],fileSvg:`svg/arrowRightOutline.svg`},automaticTransmissionL:{glyph:``,size:48,tags:[`extra`],fileSvg:`svg/automaticTransmissionL.svg`},beamsNodesMessageOutline:{glyph:``,size:48,tags:[`web`,`outlined`,`large`,`secondary`],fileSvg:`svg/beamsNodesMessageOutline.svg`},beamsNodesOutline:{glyph:``,size:48,tags:[`web`,`outlined`,`large`,`secondary`],fileSvg:`svg/beamsNodesOutline.svg`},beamsNodesPlugOutline:{glyph:``,size:48,tags:[`web`,`outlined`,`large`,`secondary`],fileSvg:`svg/beamsNodesPlugOutline.svg`},BNGEcosystemOutline:{glyph:``,size:48,tags:[`web`,`outlined`,`large`,`secondary`],fileSvg:`svg/BNGEcosystemOutline.svg`},carFrontRouteOutline:{glyph:``,size:48,tags:[`web`,`outlined`,`large`,`secondary`],fileSvg:`svg/carFrontRouteOutline.svg`},carSensorsOutline:{glyph:``,size:48,tags:[`web`,`outlined`,`large`,`secondary`],fileSvg:`svg/carSensorsOutline.svg`},carSideRouteOutline:{glyph:``,size:48,tags:[`web`,`outlined`,`large`,`secondary`],fileSvg:`svg/carSideRouteOutline.svg`},chargeLL:{glyph:``,size:48,tags:[`extra`],fileSvg:`svg/chargeLL.svg`},cityOutline:{glyph:``,size:48,tags:[`web`,`outlined`,`large`,`secondary`],fileSvg:`svg/cityOutline.svg`},clutchL:{glyph:``,size:48,tags:[`extra`],fileSvg:`svg/clutchL.svg`},couplerL:{glyph:``,size:48,tags:[`extra`],fileSvg:`svg/couplerL.svg`},dialogOutline:{glyph:``,size:48,tags:[`web`,`outlined`,`large`,`secondary`],fileSvg:`svg/dialogOutline.svg`},documentSmileOutline:{glyph:``,size:48,tags:[`web`,`outlined`,`large`,`secondary`],fileSvg:`svg/documentSmileOutline.svg`},drivetrainOutline:{glyph:``,size:48,tags:[`web`,`outlined`,`large`,`secondary`],fileSvg:`svg/drivetrainOutline.svg`},electronicSchemeOutline:{glyph:``,size:48,tags:[`web`,`outlined`,`large`,`secondary`],fileSvg:`svg/electronicSchemeOutline.svg`},engineL:{glyph:``,size:48,tags:[`extra`],fileSvg:`svg/engineL.svg`},engineOutline:{glyph:``,size:48,tags:[`web`,`outlined`,`large`,`secondary`],fileSvg:`svg/engineOutline.svg`},gearTuningOutline:{glyph:``,size:48,tags:[`web`,`outlined`,`large`,`secondary`],fileSvg:`svg/gearTuningOutline.svg`},giftBoxOutline:{glyph:``,size:48,tags:[`web`,`outlined`,`large`,`secondary`],fileSvg:`svg/giftBoxOutline.svg`},lidarOutline:{glyph:``,size:48,tags:[`web`,`outlined`,`large`,`secondary`],fileSvg:`svg/lidarOutline.svg`},medalStarOutline:{glyph:``,size:48,tags:[`web`,`outlined`,`large`,`secondary`],fileSvg:`svg/medalStarOutline.svg`},megaphoneOutline:{glyph:``,size:48,tags:[`web`,`outlined`,`large`,`secondary`],fileSvg:`svg/megaphoneOutline.svg`},multiseatL:{glyph:``,size:48,tags:[`extra`],fileSvg:`svg/multiseatL.svg`},peopleOutline:{glyph:``,size:48,tags:[`web`,`outlined`,`large`,`secondary`],fileSvg:`svg/peopleOutline.svg`},personOutline:{glyph:``,size:48,tags:[`web`,`outlined`,`large`,`secondary`],fileSvg:`svg/personOutline.svg`},physicsOutline:{glyph:``,size:48,tags:[`web`,`outlined`,`large`,`secondary`],fileSvg:`svg/physicsOutline.svg`},playChainOutline:{glyph:``,size:48,tags:[`web`,`outlined`,`large`,`secondary`],fileSvg:`svg/playChainOutline.svg`},POITimeL:{glyph:``,size:48,tags:[`extra`],fileSvg:`svg/POITimeL.svg`},proximitySensorsOutline:{glyph:``,size:48,tags:[`web`,`outlined`,`large`,`secondary`],fileSvg:`svg/proximitySensorsOutline.svg`},qualityBadgeStarOutline:{glyph:``,size:48,tags:[`web`,`outlined`,`large`,`secondary`],fileSvg:`svg/qualityBadgeStarOutline.svg`},qualityBadgeVOutline:{glyph:``,size:48,tags:[`web`,`outlined`,`large`,`secondary`],fileSvg:`svg/qualityBadgeVOutline.svg`},replayL:{glyph:``,size:48,tags:[`extra`],fileSvg:`svg/replayL.svg`},roadblockL:{glyph:``,size:48,tags:[`extra`],fileSvg:`svg/roadblockL.svg`},rotationL:{glyph:``,size:48,tags:[`extra`],fileSvg:`svg/rotationL.svg`},sensorsL:{glyph:``,size:48,tags:[`extra`],fileSvg:`svg/sensorsL.svg`},simRigOutline:{glyph:``,size:48,tags:[`web`,`outlined`,`large`,`secondary`],fileSvg:`svg/simRigOutline.svg`},suspensionOutline:{glyph:``,size:48,tags:[`web`,`outlined`,`large`,`secondary`],fileSvg:`svg/suspensionOutline.svg`},teamOutline:{glyph:``,size:48,tags:[`web`,`outlined`,`large`,`secondary`],fileSvg:`svg/teamOutline.svg`},techLightBulbOutline01:{glyph:``,size:48,tags:[`web`,`outlined`,`large`,`secondary`],fileSvg:`svg/techLightBulbOutline01.svg`},techLightBulbOutline02:{glyph:``,size:48,tags:[`web`,`outlined`,`large`,`secondary`],fileSvg:`svg/techLightBulbOutline02.svg`},temperatureL:{glyph:``,size:48,tags:[`extra`],fileSvg:`svg/temperatureL.svg`},timeUnlockOutline:{glyph:``,size:48,tags:[`web`,`outlined`,`large`,`secondary`],fileSvg:`svg/timeUnlockOutline.svg`},timedLockOutline:{glyph:``,size:48,tags:[`web`,`outlined`,`large`,`secondary`],fileSvg:`svg/timedLockOutline.svg`},trafficOutline:{glyph:``,size:48,tags:[`web`,`outlined`,`large`,`secondary`],fileSvg:`svg/trafficOutline.svg`},tuningL:{glyph:``,size:48,tags:[`extra`],fileSvg:`svg/tuningL.svg`},turbineL:{glyph:``,size:48,tags:[`extra`],fileSvg:`svg/turbineL.svg`},voucherOutline:{glyph:``,size:48,tags:[`web`,`outlined`,`large`,`secondary`],fileSvg:`svg/voucherOutline.svg`},wheelBeamsNodesOutline:{glyph:``,size:48,tags:[`web`,`outlined`,`large`,`secondary`],fileSvg:`svg/wheelBeamsNodesOutline.svg`},wheelOutline:{glyph:``,size:48,tags:[`web`,`outlined`,`large`,`secondary`],fileSvg:`svg/wheelOutline.svg`},circlePinBack:{glyph:``,size:56,tags:[`poi`],fileSvg:`svg/circlePinBack.svg`},circlePinFront:{glyph:``,size:56,tags:[`poi`],fileSvg:`svg/circlePinFront.svg`},markerRectanglePinBack:{glyph:``,size:56,tags:[`poi`],fileSvg:`svg/markerRectanglePinBack.svg`},markerRectanglePinFront:{glyph:``,size:56,tags:[`poi`],fileSvg:`svg/markerRectanglePinFront.svg`},markerTriangleBack:{glyph:``,size:56,tags:[`poi`],fileSvg:`svg/markerTriangleBack.svg`},markerTriangleFront:{glyph:``,size:56,tags:[`poi`],fileSvg:`svg/markerTriangleFront.svg`},danger:{glyph:``,size:24,tags:[`generic`,`hazard`],fileSvg:`svg/danger.svg`},droplet:{glyph:``,size:24,tags:[`generic`,`drop`,`liquid`],fileSvg:`svg/droplet.svg`},envelope:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/envelope.svg`},fireDiamond:{glyph:``,size:24,tags:[`generic`,`hazard`,`nfpa704`],fileSvg:`svg/fireDiamond.svg`},rocks:{glyph:``,size:24,tags:[`dry cargo`,`dry`],fileSvg:`svg/rocks.svg`},xmark:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/xmark.svg`},scale:{glyph:``,size:24,tags:[`decals`,`editor`,`generic`],fileSvg:`svg/scale.svg`},arrowsUp:{glyph:``,size:16,tags:[`marker`,`ribbon`,`content-props`],fileSvg:`svg/arrowsUp.svg`},bigDot:{glyph:``,size:16,tags:[`marker`,`ribbon`,`content-props`],fileSvg:`svg/bigDot.svg`},connectorBold:{glyph:``,size:16,tags:[`marker`,`ribbon`,`content-props`],fileSvg:`svg/connectorBold.svg`},cornerTopRight:{glyph:``,size:16,tags:[`marker`,`ribbon`,`content-props`],fileSvg:`svg/cornerTopRight.svg`},plusBold:{glyph:``,size:16,tags:[`marker`,`ribbon`,`content-props`],fileSvg:`svg/plusBold.svg`},puzzlePieceBold:{glyph:``,size:16,tags:[`marker`,`ribbon`,`content-props`],fileSvg:`svg/puzzlePieceBold.svg`},locationDestination:{glyph:``,size:24,tags:[`generic`,`location`,`route`,`path`,`node`],fileSvg:`svg/locationDestination.svg`},locationSource:{glyph:``,size:24,tags:[`generic`,`location`,`route`,`path`,`node`],fileSvg:`svg/locationSource.svg`},accelerationKPH:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/accelerationKPH.svg`},accelerationMPH:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/accelerationMPH.svg`},boxTruckFast:{glyph:``,size:24,tags:[`cargo`,`delivery`,`vehicle`],fileSvg:`svg/boxTruckFast.svg`},colorBrightnessSun:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/colorBrightnessSun.svg`},colorCirclePalette:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/colorCirclePalette.svg`},colorPalette:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/colorPalette.svg`},colorSaturation:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/colorSaturation.svg`},sortAscDown02:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/sortAscDown02.svg`},sortAscDown:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/sortAscDown.svg`},sortAscUp02:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/sortAscUp02.svg`},sortAscUp:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/sortAscUp.svg`},sortDescDown02:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/sortDescDown02.svg`},sortDescDown:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/sortDescDown.svg`},sortDescUp02:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/sortDescUp02.svg`},sortDescUp:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/sortDescUp.svg`},cardboardBoxCoins:{glyph:``,size:24,tags:[`generic`,`delivery`],fileSvg:`svg/cardboardBoxCoins.svg`},lasso:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`],fileSvg:`svg/lasso.svg`},materialGlossy:{glyph:``,size:24,tags:[`decals`,`generic`],fileSvg:`svg/materialGlossy.svg`},materialMetal:{glyph:``,size:24,tags:[`decals`,`generic`],fileSvg:`svg/materialMetal.svg`},materialRoughness:{glyph:``,size:24,tags:[`decals`,`generic`],fileSvg:`svg/materialRoughness.svg`},materialTransparency01:{glyph:``,size:24,tags:[`decals`,`generic`],fileSvg:`svg/materialTransparency01.svg`},materialTransparency02:{glyph:``,size:24,tags:[`decals`,`generic`],fileSvg:`svg/materialTransparency02.svg`},metal01:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/metal01.svg`},removeItemPolygon:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`,`road tools`],fileSvg:`svg/removeItemPolygon.svg`},removeListItem:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`,`road tools`],fileSvg:`svg/removeListItem.svg`},sortAsc:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/sortAsc.svg`},sortDesc:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/sortDesc.svg`},surfaceRoughness02:{glyph:``,size:24,tags:[`decals`,`generic`],fileSvg:`svg/surfaceRoughness02.svg`},shieldCheckmark:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/shieldCheckmark.svg`},shieldHandCheckmark:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/shieldHandCheckmark.svg`},shieldHandPlus:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/shieldHandPlus.svg`},doorFrontCoins:{glyph:``,size:24,tags:[`vehicle`,`part`,`features`],fileSvg:`svg/doorFrontCoins.svg`},doorFront:{glyph:``,size:24,tags:[`vehicle`,`part`,`features`],fileSvg:`svg/doorFront.svg`},engineCoins:{glyph:``,size:24,tags:[`vehicle`,`part`,`features`],fileSvg:`svg/engineCoins.svg`},exhaustMufflerCoins:{glyph:``,size:24,tags:[`vehicle`,`part`,`features`],fileSvg:`svg/exhaustMufflerCoins.svg`},exhaustMuffler:{glyph:``,size:24,tags:[`vehicle`,`part`,`features`],fileSvg:`svg/exhaustMuffler.svg`},headlightCoins:{glyph:``,size:24,tags:[`vehicle`,`part`,`features`],fileSvg:`svg/headlightCoins.svg`},headlight:{glyph:``,size:24,tags:[`vehicle`,`part`,`features`],fileSvg:`svg/headlight.svg`},tire3FourthCoins:{glyph:``,size:24,tags:[`vehicle`,`part`,`features`,`tire`],fileSvg:`svg/tire3FourthCoins.svg`},tire3Fourth:{glyph:``,size:24,tags:[`vehicle`,`part`,`features`,`tire`],fileSvg:`svg/tire3Fourth.svg`},turbineCoins:{glyph:``,size:24,tags:[`vehicle`,`part`,`features`],fileSvg:`svg/turbineCoins.svg`},wheelDiscCoins:{glyph:``,size:24,tags:[`vehicle`,`part`,`features`],fileSvg:`svg/wheelDiscCoins.svg`},wheelDisc:{glyph:``,size:24,tags:[`vehicle`,`part`,`features`],fileSvg:`svg/wheelDisc.svg`},bridgeWithRiver:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`,`road tools`],fileSvg:`svg/bridgeWithRiver.svg`},gizmosOutline:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`,`road tools`],fileSvg:`svg/gizmosOutline.svg`},gizmosSolid:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`,`road tools`],fileSvg:`svg/gizmosSolid.svg`},highwayRoad3To2Merge01:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`,`road tools`],fileSvg:`svg/highwayRoad3To2Merge01.svg`},highwayRoad3To2Merge02:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`,`road tools`],fileSvg:`svg/highwayRoad3To2Merge02.svg`},highwayToUrbanRoadTransition01:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`,`road tools`],fileSvg:`svg/highwayToUrbanRoadTransition01.svg`},highwayToUrbanRoadTransition02:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`,`road tools`],fileSvg:`svg/highwayToUrbanRoadTransition02.svg`},pedestrianCrossing01:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`,`road tools`],fileSvg:`svg/pedestrianCrossing01.svg`},polygonalCube:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`,`road tools`],fileSvg:`svg/polygonalCube.svg`},roadEditOutline:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`,`road tools`],fileSvg:`svg/roadEditOutline.svg`},roadEditSolid:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`,`road tools`],fileSvg:`svg/roadEditSolid.svg`},roadFolderPlus:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`,`road tools`],fileSvg:`svg/roadFolderPlus.svg`},roadFolder:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`,`road tools`],fileSvg:`svg/roadFolder.svg`},roadGuideArrowOutline:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`,`road tools`],fileSvg:`svg/roadGuideArrowOutline.svg`},roadGuideArrowSolid:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`,`road tools`],fileSvg:`svg/roadGuideArrowSolid.svg`},roadOutlineMesh:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`,`road tools`],fileSvg:`svg/roadOutlineMesh.svg`},roadPedestrianCrossing02:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`,`road tools`],fileSvg:`svg/roadPedestrianCrossing02.svg`},roadProfileWithCheckmark:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`,`road tools`],fileSvg:`svg/roadProfileWithCheckmark.svg`},roadProfile:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`,`road tools`],fileSvg:`svg/roadProfile.svg`},roadRoundaboutJunction:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`,`road tools`],fileSvg:`svg/roadRoundaboutJunction.svg`},roadSidewalkTransition:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`,`road tools`],fileSvg:`svg/roadSidewalkTransition.svg`},roadStackPlus:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`,`road tools`],fileSvg:`svg/roadStackPlus.svg`},roadStack:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`,`road tools`],fileSvg:`svg/roadStack.svg`},roadTJunction:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`,`road tools`],fileSvg:`svg/roadTJunction.svg`},roadXJunction:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`,`road tools`],fileSvg:`svg/roadXJunction.svg`},roadYJunction:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`,`road tools`],fileSvg:`svg/roadYJunction.svg`},shoppingCart:{glyph:``,size:24,tags:[`generic`,`shop`,`purchase`],fileSvg:`svg/shoppingCart.svg`},singleLineToTerrain:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`,`road tools`],fileSvg:`svg/singleLineToTerrain.svg`},sphereOnMesh:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`,`road tools`],fileSvg:`svg/sphereOnMesh.svg`},twoLinesToTerrain:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`,`road tools`],fileSvg:`svg/twoLinesToTerrain.svg`},urbanRoad3To2Merge01:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`,`road tools`],fileSvg:`svg/urbanRoad3To2Merge01.svg`},urbanRoad3To2Merge02:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`,`road tools`],fileSvg:`svg/urbanRoad3To2Merge02.svg`},urbanRoadToHighwayTransition01:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`,`road tools`],fileSvg:`svg/urbanRoadToHighwayTransition01.svg`},urbanRoadToHighwayTransition02:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`,`road tools`],fileSvg:`svg/urbanRoadToHighwayTransition02.svg`},floppyDiskPlus:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/floppyDiskPlus.svg`},highwayMerge:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`,`road tools`],fileSvg:`svg/highwayMerge.svg`},highwaySeparate:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`,`road tools`],fileSvg:`svg/highwaySeparate.svg`},highwayShoulderMerge:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`,`road tools`],fileSvg:`svg/highwayShoulderMerge.svg`},terrainToSingleLine:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`,`road tools`],fileSvg:`svg/terrainToSingleLine.svg`},terrainToTwoLines:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`,`road tools`],fileSvg:`svg/terrainToTwoLines.svg`},urbanRoadMerge:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`,`road tools`],fileSvg:`svg/urbanRoadMerge.svg`},urbanRoadSeparate:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`,`road tools`],fileSvg:`svg/urbanRoadSeparate.svg`},urbanShoulderMerge:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`,`road tools`],fileSvg:`svg/urbanShoulderMerge.svg`},discharging:{glyph:``,size:24,tags:[`fuel`,`electricity`,`ev`],fileSvg:`svg/discharging.svg`},BNGChat:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/BNGChat.svg`},chatBubble:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/chatBubble.svg`},busTilted:{glyph:``,size:24,tags:[`poi`,`vehicle`,`bus`],fileSvg:`svg/busTilted.svg`},cameraFarClip:{glyph:``,size:24,tags:[`decals`,`generic`],fileSvg:`svg/cameraFarClip.svg`},cameraNearClip:{glyph:``,size:24,tags:[`decals`,`generic`],fileSvg:`svg/cameraNearClip.svg`},explosion:{glyph:``,size:24,tags:[`generic`,`destruction`],fileSvg:`svg/explosion.svg`},fireExtinguisher:{glyph:``,size:24,tags:[`generic`,`destruction`],fileSvg:`svg/fireExtinguisher.svg`},fire:{glyph:``,size:24,tags:[`generic`,`destruction`],fileSvg:`svg/fire.svg`},jointLockedMultiple:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/jointLockedMultiple.svg`},jointUnlockedMultiple:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/jointUnlockedMultiple.svg`},toggleOff:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/toggleOff.svg`},toggleOn:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/toggleOn.svg`},viewFarClip:{glyph:``,size:24,tags:[`decals`,`generic`],fileSvg:`svg/viewFarClip.svg`},viewNearClip:{glyph:``,size:24,tags:[`decals`,`generic`],fileSvg:`svg/viewNearClip.svg`},twoArrowsHorizontal:{glyph:``,size:24,tags:[`arrow`,`large`,`solid`,`turn signals`],fileSvg:`svg/twoArrowsHorizontal.svg`},twoArrowsVertical:{glyph:``,size:24,tags:[`arrow`,`large`,`solid`,`turn signals`],fileSvg:`svg/twoArrowsVertical.svg`},bridge:{glyph:``,size:48,tags:[`rally`,`pace notes`,`directions`,`surface`,`features`],fileSvg:`svg/bridge.svg`},bump:{glyph:``,size:48,tags:[`rally`,`pace notes`,`directions`,`surface`,`features`],fileSvg:`svg/bump.svg`},bumps:{glyph:``,size:48,tags:[`rally`,`pace notes`,`directions`,`surface`,`features`],fileSvg:`svg/bumps.svg`},caution:{glyph:``,size:48,tags:[`rally`,`pace notes`,`directions`,`surface`,`features`],fileSvg:`svg/caution.svg`},crest:{glyph:``,size:48,tags:[`rally`,`pace notes`,`directions`,`surface`,`features`],fileSvg:`svg/crest.svg`},doubleCaution:{glyph:``,size:48,tags:[`rally`,`pace notes`,`directions`,`surface`,`features`],fileSvg:`svg/doubleCaution.svg`},finish:{glyph:``,size:48,tags:[`rally`,`pace notes`,`directions`,`surface`,`features`],fileSvg:`svg/finish.svg`},jumpOverBump:{glyph:``,size:48,tags:[`rally`,`pace notes`,`directions`,`surface`,`features`],fileSvg:`svg/jumpOverBump.svg`},narrows:{glyph:``,size:48,tags:[`rally`,`pace notes`,`directions`,`surface`,`features`],fileSvg:`svg/narrows.svg`},pothole:{glyph:``,size:48,tags:[`rally`,`pace notes`,`directions`,`surface`,`features`],fileSvg:`svg/pothole.svg`},turn1:{glyph:``,size:48,tags:[`rally`,`pace notes`,`directions`,`surface`,`features`],fileSvg:`svg/turn1.svg`},turn2:{glyph:``,size:48,tags:[`rally`,`pace notes`,`directions`,`surface`,`features`],fileSvg:`svg/turn2.svg`},turn3:{glyph:``,size:48,tags:[`rally`,`pace notes`,`directions`,`surface`,`features`],fileSvg:`svg/turn3.svg`},turn4:{glyph:``,size:48,tags:[`rally`,`pace notes`,`directions`,`surface`,`features`],fileSvg:`svg/turn4.svg`},turn5:{glyph:``,size:48,tags:[`rally`,`pace notes`,`directions`,`surface`,`features`],fileSvg:`svg/turn5.svg`},turn6:{glyph:``,size:48,tags:[`rally`,`pace notes`,`directions`,`surface`,`features`],fileSvg:`svg/turn6.svg`},turnHp:{glyph:``,size:48,tags:[`rally`,`pace notes`,`directions`,`surface`,`features`],fileSvg:`svg/turnHp.svg`},turnSq:{glyph:``,size:48,tags:[`rally`,`pace notes`,`directions`,`surface`,`features`],fileSvg:`svg/turnSq.svg`},water:{glyph:``,size:48,tags:[`rally`,`pace notes`,`directions`,`surface`,`features`],fileSvg:`svg/water.svg`},circleSlashed:{glyph:``,size:24,tags:[`generic`,`do not cut`,`no entry`],fileSvg:`svg/circleSlashed.svg`},scissorsSlashed:{glyph:``,size:24,tags:[`generic`,`do not cut`],fileSvg:`svg/scissorsSlashed.svg`},scissors:{glyph:``,size:24,tags:[`generic`,`cut`],fileSvg:`svg/scissors.svg`},airPuffRight1:{glyph:``,size:24,tags:[`generic`,`vehicle`,`car`],fileSvg:`svg/airPuffRight1.svg`},airPuffUp1:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/airPuffUp1.svg`},arrowsReplace:{glyph:``,size:24,tags:[`generic`,`arrow`],fileSvg:`svg/arrowsReplace.svg`},arrowsShuffle:{glyph:``,size:24,tags:[`generic`,`arrow`],fileSvg:`svg/arrowsShuffle.svg`},arrowsSwitch:{glyph:``,size:24,tags:[`generic`,`arrow`],fileSvg:`svg/arrowsSwitch.svg`},carClock:{glyph:``,size:24,tags:[`generic`,`vehicle`],fileSvg:`svg/carClock.svg`},carFast:{glyph:``,size:24,tags:[`vehicle`],fileSvg:`svg/carFast.svg`},carNumber1:{glyph:``,size:24,tags:[`generic`,`vehicle`],fileSvg:`svg/carNumber1.svg`},carNumber2:{glyph:``,size:24,tags:[`generic`,`vehicle`],fileSvg:`svg/carNumber2.svg`},carNumber3:{glyph:``,size:24,tags:[`generic`,`vehicle`],fileSvg:`svg/carNumber3.svg`},carNumber4:{glyph:``,size:24,tags:[`generic`,`vehicle`],fileSvg:`svg/carNumber4.svg`},carNumber5:{glyph:``,size:24,tags:[`generic`,`vehicle`],fileSvg:`svg/carNumber5.svg`},carNumber6:{glyph:``,size:24,tags:[`generic`,`vehicle`],fileSvg:`svg/carNumber6.svg`},carNumber7:{glyph:``,size:24,tags:[`generic`,`vehicle`],fileSvg:`svg/carNumber7.svg`},carNumber8:{glyph:``,size:24,tags:[`generic`,`vehicle`],fileSvg:`svg/carNumber8.svg`},carNumber9:{glyph:``,size:24,tags:[`generic`,`vehicle`],fileSvg:`svg/carNumber9.svg`},carPlus:{glyph:``,size:24,tags:[`generic`,`vehicle`],fileSvg:`svg/carPlus.svg`},carsChange:{glyph:``,size:24,tags:[`vehicle`,`select`],fileSvg:`svg/carsChange.svg`},carsFollow:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/carsFollow.svg`},doorFrontDetached:{glyph:``,size:24,tags:[`vehicle`,`part`,`features`],fileSvg:`svg/doorFrontDetached.svg`},forceFieldPull1:{glyph:``,size:24,tags:[`physics`,`field`,`force`],fileSvg:`svg/forceFieldPull1.svg`},forceFieldPull2:{glyph:``,size:24,tags:[`physics`,`field`,`force`],fileSvg:`svg/forceFieldPull2.svg`},forceFieldPull3:{glyph:``,size:24,tags:[`physics`,`field`,`force`],fileSvg:`svg/forceFieldPull3.svg`},forceFieldPush1:{glyph:``,size:24,tags:[`physics`,`field`,`force`],fileSvg:`svg/forceFieldPush1.svg`},forceFieldPush2:{glyph:``,size:24,tags:[`physics`,`field`,`force`],fileSvg:`svg/forceFieldPush2.svg`},forceFieldPush3:{glyph:``,size:24,tags:[`physics`,`field`,`force`],fileSvg:`svg/forceFieldPush3.svg`},garageNumber1:{glyph:``,size:24,tags:[`career`,`garage number`,`features`],fileSvg:`svg/garageNumber1.svg`},garageNumber2:{glyph:``,size:24,tags:[`career`,`garage number`,`features`],fileSvg:`svg/garageNumber2.svg`},garageNumber3:{glyph:``,size:24,tags:[`career`,`garage number`,`features`],fileSvg:`svg/garageNumber3.svg`},garageNumber4:{glyph:``,size:24,tags:[`career`,`garage number`,`features`],fileSvg:`svg/garageNumber4.svg`},garageNumber5:{glyph:``,size:24,tags:[`career`,`garage number`,`features`],fileSvg:`svg/garageNumber5.svg`},garageNumber6:{glyph:``,size:24,tags:[`career`,`garage number`,`features`],fileSvg:`svg/garageNumber6.svg`},garageNumber7:{glyph:``,size:24,tags:[`career`,`garage number`,`features`],fileSvg:`svg/garageNumber7.svg`},garageNumber8:{glyph:``,size:24,tags:[`career`,`garage number`,`features`],fileSvg:`svg/garageNumber8.svg`},garageNumber9:{glyph:``,size:24,tags:[`career`,`garage number`,`features`],fileSvg:`svg/garageNumber9.svg`},hingeBroken:{glyph:``,size:24,tags:[`vehicle`,`part`,`features`],fileSvg:`svg/hingeBroken.svg`},loadMesh:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/loadMesh.svg`},octagonBrick:{glyph:``,size:24,tags:[`generic`,`vehicle`,`car`],fileSvg:`svg/octagonBrick.svg`},octagon:{glyph:``,size:24,tags:[`generic`,`vehicle`,`car`],fileSvg:`svg/octagon.svg`},pushUp:{glyph:``,size:24,tags:[`physics`,`force`],fileSvg:`svg/pushUp.svg`},saveMesh:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/saveMesh.svg`},square:{glyph:``,size:24,tags:[`playback`,`stop`],fileSvg:`svg/square.svg`},tireAirPuff:{glyph:``,size:24,tags:[`vehicle`,`car`],fileSvg:`svg/tireAirPuff.svg`},tireDeflated:{glyph:``,size:24,tags:[`vehicle`,`car`],fileSvg:`svg/tireDeflated.svg`},trafficLight:{glyph:``,size:24,tags:[`generic`,`traffic`,`roads`],fileSvg:`svg/trafficLight.svg`},enter:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/enter.svg`},pedestrianRunning:{glyph:``,size:24,tags:[`generic`,`sign`,`pedestrian`,`traffic`],fileSvg:`svg/pedestrianRunning.svg`},pedestrianStanding:{glyph:``,size:24,tags:[`generic`,`sign`,`pedestrian`,`traffic`],fileSvg:`svg/pedestrianStanding.svg`},seatArrowIn:{glyph:``,size:24,tags:[`generic`,`arrow`,`actions`],fileSvg:`svg/seatArrowIn.svg`},seatArrowOut:{glyph:``,size:24,tags:[`generic`,`arrow`,`actions`],fileSvg:`svg/seatArrowOut.svg`},seatVArrowIn:{glyph:``,size:24,tags:[`generic`,`arrow`,`actions`],fileSvg:`svg/seatVArrowIn.svg`},seatVArrowOut:{glyph:``,size:24,tags:[`generic`,`arrow`,`actions`],fileSvg:`svg/seatVArrowOut.svg`},vehicleArrowIn:{glyph:``,size:24,tags:[`generic`,`arrow`,`actions`],fileSvg:`svg/vehicleArrowIn.svg`},vehicleArrowOut:{glyph:``,size:24,tags:[`generic`,`arrow`,`actions`],fileSvg:`svg/vehicleArrowOut.svg`},leverFrontOperate:{glyph:``,size:24,tags:[`generic`,`actions`],fileSvg:`svg/leverFrontOperate.svg`},leverSideDown:{glyph:``,size:24,tags:[`generic`,`actions`],fileSvg:`svg/leverSideDown.svg`},leverSideOperate:{glyph:``,size:24,tags:[`generic`,`actions`],fileSvg:`svg/leverSideOperate.svg`},leverSideUp:{glyph:``,size:24,tags:[`generic`,`actions`],fileSvg:`svg/leverSideUp.svg`},medalEmpty:{glyph:``,size:24,tags:[`generic`,`reward`,`achievment`],fileSvg:`svg/medalEmpty.svg`},medalStar:{glyph:``,size:24,tags:[`generic`,`reward`,`achievment`],fileSvg:`svg/medalStar.svg`},seatArrowInLeft:{glyph:``,size:24,tags:[`generic`,`arrow`,`actions`],fileSvg:`svg/seatArrowInLeft.svg`},seatArrowOutLeft:{glyph:``,size:24,tags:[`generic`,`arrow`,`actions`],fileSvg:`svg/seatArrowOutLeft.svg`},seatVArrowInLeft:{glyph:``,size:24,tags:[`generic`,`arrow`,`actions`],fileSvg:`svg/seatVArrowInLeft.svg`},seatVArrowOutLeft:{glyph:``,size:24,tags:[`generic`,`arrow`,`actions`],fileSvg:`svg/seatVArrowOutLeft.svg`},badgeRoundEmpty:{glyph:``,size:24,tags:[`generic`,`reward`,`achievment`],fileSvg:`svg/badgeRoundEmpty.svg`},badgeRoundStar:{glyph:``,size:24,tags:[`generic`,`reward`,`achievment`],fileSvg:`svg/badgeRoundStar.svg`},badgeRound:{glyph:``,size:24,tags:[`generic`,`reward`,`achievment`],fileSvg:`svg/badgeRound.svg`},badge:{glyph:``,size:24,tags:[`generic`,`reward`,`achievment`],fileSvg:`svg/badge.svg`},beamCurrencyOutlineLarge:{glyph:``,size:48,tags:[`outline`,`generic`,`currency`],fileSvg:`svg/beamCurrencyOutlineLarge.svg`},carSideOutlineLarge:{glyph:``,size:48,tags:[`generic`,`vehicle`],fileSvg:`svg/carSideOutlineLarge.svg`},flagOutlineLarge:{glyph:``,size:48,tags:[`generic`,`mission`,`scenario`],fileSvg:`svg/flagOutlineLarge.svg`},terrainOutlineLarge:{glyph:``,size:48,tags:[`generic`],fileSvg:`svg/terrainOutlineLarge.svg`},houseWrenchRoof:{glyph:``,size:24,tags:[`career`,`garage`,`features`,`house`],fileSvg:`svg/houseWrenchRoof.svg`},houseWrench:{glyph:``,size:24,tags:[`career`,`garage`,`features`,`house`],fileSvg:`svg/houseWrench.svg`},eject:{glyph:``,size:24,tags:[`playback`],fileSvg:`svg/eject.svg`},rallyHelmet3To4:{glyph:``,size:24,tags:[`helmet`,`rally`,`generic`,`racing`,`game mode`],fileSvg:`svg/rallyHelmet3To4.svg`},rallyHelmet:{glyph:``,size:24,tags:[`helmet`,`rally`,`generic`,`racing`,`game mode`],fileSvg:`svg/rallyHelmet.svg`},test:{glyph:``,size:24,tags:[`generic`,`hazard`],fileSvg:`svg/test.svg`},tripleCaution:{glyph:``,size:48,tags:[`rally`,`pace notes`,`directions`,`surface`,`features`],fileSvg:`svg/tripleCaution.svg`},globeSimpleNotSign:{glyph:``,size:24,tags:[`generic`,`offline`],fileSvg:`svg/globeSimpleNotSign.svg`},globeSimplified:{glyph:``,size:24,tags:[`generic`,`online`],fileSvg:`svg/globeSimplified.svg`},radialMenu:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/radialMenu.svg`},branch:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/branch.svg`},NA:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/NA.svg`},psCircleOutline:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/psCircleOutline.svg`},psCircle:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/psCircle.svg`},psCreate2:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/psCreate2.svg`},psCreate:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/psCreate.svg`},psCrossOutline:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/psCrossOutline.svg`},psCross:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/psCross.svg`},psDDefaultOutline:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/psDDefaultOutline.svg`},psDDefaultSolid:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/psDDefaultSolid.svg`},psDDown:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/psDDown.svg`},psDLeft:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/psDLeft.svg`},psDRight:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/psDRight.svg`},psDUp:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/psDUp.svg`},psL1:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/psL1.svg`},psL2:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/psL2.svg`},psL3ButtonArrowDown:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/psL3ButtonArrowDown.svg`},psL3Button:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/psL3Button.svg`},psLSXLeft:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/psLSXLeft.svg`},psLSXRight:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/psLSXRight.svg`},psLSX:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/psLSX.svg`},psLSYDown:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/psLSYDown.svg`},psLSYUp:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/psLSYUp.svg`},psLSY:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/psLSY.svg`},psLS:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/psLS.svg`},psMenu2:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/psMenu2.svg`},psMenu:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/psMenu.svg`},psR1:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/psR1.svg`},psR2:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/psR2.svg`},psR3ButtonArrowDown:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/psR3ButtonArrowDown.svg`},psR3Button:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/psR3Button.svg`},psRSXLeft:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/psRSXLeft.svg`},psRSXRight:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/psRSXRight.svg`},psRSX:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/psRSX.svg`},psRSYDown:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/psRSYDown.svg`},psRSYUp:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/psRSYUp.svg`},psRSY:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/psRSY.svg`},psRS:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/psRS.svg`},psSquareOutline:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/psSquareOutline.svg`},psSquare:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/psSquare.svg`},psTrackpadNavigate:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/psTrackpadNavigate.svg`},psTrackpadPressCenter:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/psTrackpadPressCenter.svg`},psTrackpadPressLeft:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/psTrackpadPressLeft.svg`},psTrackpadPressRight:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/psTrackpadPressRight.svg`},psTrackpadSwipeDown:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/psTrackpadSwipeDown.svg`},psTrackpadSwipeLeft:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/psTrackpadSwipeLeft.svg`},psTrackpadSwipeRight:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/psTrackpadSwipeRight.svg`},psTrackpadSwipeUp:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/psTrackpadSwipeUp.svg`},psTriangleOutline:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/psTriangleOutline.svg`},psTriangle:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/psTriangle.svg`},xboxAOutline:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/xboxAOutline.svg`},xboxBOutline:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/xboxBOutline.svg`},xboxLSButtonArrowDown:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/xboxLSButtonArrowDown.svg`},xboxRSButtonArrowDown:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/xboxRSButtonArrowDown.svg`},xboxXAxisLeft:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/xboxXAxisLeft.svg`},xboxXAxisRight:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/xboxXAxisRight.svg`},xboxXOutline:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/xboxXOutline.svg`},xboxXRotLeft:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/xboxXRotLeft.svg`},xboxXRotRight:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/xboxXRotRight.svg`},xboxYAxisDown:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/xboxYAxisDown.svg`},xboxYAxisUp:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/xboxYAxisUp.svg`},xboxYOutline:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/xboxYOutline.svg`},xboxYRotDown:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/xboxYRotDown.svg`},xboxYRotUp:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/xboxYRotUp.svg`},cableSection:{glyph:``,size:24,tags:[`material`,`beam`,`strap`],fileSvg:`svg/cableSection.svg`},strapHook:{glyph:``,size:24,tags:[`material`,`strap`],fileSvg:`svg/strapHook.svg`},strapRatchet:{glyph:``,size:24,tags:[`material`,`strap`],fileSvg:`svg/strapRatchet.svg`},carFastReverse:{glyph:``,size:24,tags:[`vehicle`],fileSvg:`svg/carFastReverse.svg`},carsChase:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/carsChase.svg`},carsFlee:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/carsFlee.svg`},gaugeFull:{glyph:``,size:24,tags:[`poi`],fileSvg:`svg/gaugeFull.svg`},hammerParticles:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/hammerParticles.svg`},kbArrowsDown:{glyph:``,size:24,tags:[`keyboard`,`controls`],fileSvg:`svg/kbArrowsDown.svg`},kbArrowsLeftRight:{glyph:``,size:24,tags:[`keyboard`,`controls`],fileSvg:`svg/kbArrowsLeftRight.svg`},kbArrowsLeft:{glyph:``,size:24,tags:[`keyboard`,`controls`],fileSvg:`svg/kbArrowsLeft.svg`},kbArrowsOutline:{glyph:``,size:24,tags:[`keyboard`,`controls`],fileSvg:`svg/kbArrowsOutline.svg`},kbArrowsRight:{glyph:``,size:24,tags:[`keyboard`,`controls`],fileSvg:`svg/kbArrowsRight.svg`},kbArrowsSolid:{glyph:``,size:24,tags:[`keyboard`,`controls`],fileSvg:`svg/kbArrowsSolid.svg`},kbArrowsUpDown:{glyph:``,size:24,tags:[`keyboard`,`controls`],fileSvg:`svg/kbArrowsUpDown.svg`},kbArrowsUp:{glyph:``,size:24,tags:[`keyboard`,`controls`],fileSvg:`svg/kbArrowsUp.svg`},magicWand:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/magicWand.svg`},psDLeftRight:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/psDLeftRight.svg`},psDUpDown:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/psDUpDown.svg`},pushBackward:{glyph:``,size:24,tags:[`physics`,`force`],fileSvg:`svg/pushBackward.svg`},pushDown:{glyph:``,size:24,tags:[`physics`,`force`],fileSvg:`svg/pushDown.svg`},pushForward:{glyph:``,size:24,tags:[`physics`,`force`],fileSvg:`svg/pushForward.svg`},rangeboxHi:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/rangeboxHi.svg`},rangeboxLo:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/rangeboxLo.svg`},routeSimpleFlag:{glyph:``,size:24,tags:[`route`,`traffic`],fileSvg:`svg/routeSimpleFlag.svg`},xboxDLeftRight:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/xboxDLeftRight.svg`},xboxDUpDown:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/xboxDUpDown.svg`},carsWrench:{glyph:``,size:24,tags:[`vehicle`,`select`],fileSvg:`svg/carsWrench.svg`},jointCycleMultiple:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/jointCycleMultiple.svg`},jointCycle:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/jointCycle.svg`},dice24:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/dice24.svg`},diceD6:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/diceD6.svg`},pathDice:{glyph:``,size:24,tags:[`camera`],fileSvg:`svg/pathDice.svg`},sunDown:{glyph:``,size:24,tags:[`environment`],fileSvg:`svg/sunDown.svg`},xmarkBold:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/xmarkBold.svg`},intakeTrumpets:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/intakeTrumpets.svg`},transmissionCvt:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/transmissionCvt.svg`},house:{glyph:``,size:24,tags:[`career`,`generic`,`garage`,`features`,`house`],fileSvg:`svg/house.svg`},playPause:{glyph:``,size:24,tags:[`playback`],fileSvg:`svg/playPause.svg`},picture:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/picture.svg`},auxUpDown:{glyph:``,size:24,tags:[`vehicle`,`features`,`equipment`],fileSvg:`svg/auxUpDown.svg`},bucketArmUpDown:{glyph:``,size:24,tags:[`vehicle`,`features`,`equipment`],fileSvg:`svg/bucketArmUpDown.svg`},bucketTilt:{glyph:``,size:24,tags:[`vehicle`,`features`,`equipment`],fileSvg:`svg/bucketTilt.svg`},bucketArmDown:{glyph:``,size:24,tags:[`vehicle`,`features`,`equipment`],fileSvg:`svg/bucketArmDown.svg`},bucketArmLevel:{glyph:``,size:24,tags:[`vehicle`,`features`,`equipment`],fileSvg:`svg/bucketArmLevel.svg`},bucketArmUp:{glyph:``,size:24,tags:[`vehicle`,`features`,`equipment`],fileSvg:`svg/bucketArmUp.svg`},bucketTiltDown:{glyph:``,size:24,tags:[`vehicle`,`features`,`equipment`],fileSvg:`svg/bucketTiltDown.svg`},bucketTiltLevel:{glyph:``,size:24,tags:[`vehicle`,`features`,`equipment`],fileSvg:`svg/bucketTiltLevel.svg`},bucketTiltUp:{glyph:``,size:24,tags:[`vehicle`,`features`,`equipment`],fileSvg:`svg/bucketTiltUp.svg`},dumpBedDown:{glyph:``,size:24,tags:[`vehicle`,`features`,`equipment`],fileSvg:`svg/dumpBedDown.svg`},dumpBedUpDown:{glyph:``,size:24,tags:[`vehicle`,`features`,`equipment`],fileSvg:`svg/dumpBedUpDown.svg`},dumpBedUp:{glyph:``,size:24,tags:[`vehicle`,`features`,`equipment`],fileSvg:`svg/dumpBedUp.svg`},beamCurrencyThin:{glyph:``,size:24,tags:[`career`,`currencies`],fileSvg:`svg/beamCurrencyThin.svg`},shieldCheckmarkProgressbar:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/shieldCheckmarkProgressbar.svg`}}),iconsBySize=Object.freeze({16:{arrowsUp:icons$2.arrowsUp,bigDot:icons$2.bigDot,connectorBold:icons$2.connectorBold,cornerTopRight:icons$2.cornerTopRight,plusBold:icons$2.plusBold,puzzlePieceBold:icons$2.puzzlePieceBold},24:{"4WD":icons$2[`4WD`],"9dividedby10":icons$2[`9dividedby10`],abandon:icons$2.abandon,ABSIndicator:icons$2.ABSIndicator,addItemPolygon:icons$2.addItemPolygon,addListItem:icons$2.addListItem,addPolygonVertex:icons$2.addPolygonVertex,adjust:icons$2.adjust,AIMicrochip:icons$2.AIMicrochip,AIRace:icons$2.AIRace,aperture:icons$2.aperture,arrowLargeDown:icons$2.arrowLargeDown,arrowLargeLeft:icons$2.arrowLargeLeft,arrowLargeRight:icons$2.arrowLargeRight,arrowLargeUp:icons$2.arrowLargeUp,arrowSmallDown:icons$2.arrowSmallDown,arrowSmallLeft:icons$2.arrowSmallLeft,arrowSmallRight:icons$2.arrowSmallRight,arrowSmallUp:icons$2.arrowSmallUp,arrowSolidLeft:icons$2.arrowSolidLeft,arrowSolidRight:icons$2.arrowSolidRight,autobahn:icons$2.autobahn,AWD:icons$2.AWD,axleLift:icons$2.axleLift,axleCenter:icons$2.axleCenter,axleFront:icons$2.axleFront,axleRear:icons$2.axleRear,bSpline:icons$2.bSpline,banknotes:icons$2.banknotes,barrelKnocker01:icons$2.barrelKnocker01,barrelKnocker02:icons$2.barrelKnocker02,beamCrashBarrier1:icons$2.beamCrashBarrier1,beamCrashBarrier2:icons$2.beamCrashBarrier2,beamCrashBarrier3:icons$2.beamCrashBarrier3,beamCurrency:icons$2.beamCurrency,beamNG:icons$2.beamNG,beamXPFull:icons$2.beamXPFull,beamXPLo:icons$2.beamXPLo,bezierPath1:icons$2.bezierPath1,bezierPath2:icons$2.bezierPath2,bicycle1:icons$2.bicycle1,bicycle2:icons$2.bicycle2,BNGFolder:icons$2.BNGFolder,BNGMicrochip:icons$2.BNGMicrochip,bollard:icons$2.bollard,bookmark:icons$2.bookmark,booleanIntersect:icons$2.booleanIntersect,boxDropOff01:icons$2.boxDropOff01,boxDropOff02:icons$2.boxDropOff02,boxDropOff03:icons$2.boxDropOff03,boxPickUp01:icons$2.boxPickUp01,boxPickUp02:icons$2.boxPickUp02,boxPickUp03:icons$2.boxPickUp03,boxPickUpDropOff01:icons$2.boxPickUpDropOff01,boxPickUpDropOff02:icons$2.boxPickUpDropOff02,boxTruck:icons$2.boxTruck,broom:icons$2.broom,bucketAdd:icons$2.bucketAdd,bucketSubtract:icons$2.bucketSubtract,bug:icons$2.bug,bulldozer:icons$2.bulldozer,bus:icons$2.bus,camera3Fourth1:icons$2.camera3Fourth1,cameraBack1:icons$2.cameraBack1,cameraFocusOnPath:icons$2.cameraFocusOnPath,cameraFocusOnVehicle1:icons$2.cameraFocusOnVehicle1,cameraFocusOnVehicle2:icons$2.cameraFocusOnVehicle2,cameraFocusTopDown:icons$2.cameraFocusTopDown,cameraFront1:icons$2.cameraFront1,cameraSideLeft:icons$2.cameraSideLeft,cameraSideLeft2:icons$2.cameraSideLeft2,cameraSideRight:icons$2.cameraSideRight,cameraSideRight2:icons$2.cameraSideRight2,cameraTop1:icons$2.cameraTop1,cannon:icons$2.cannon,carChase01:icons$2.carChase01,carCoin:icons$2.carCoin,carCoins:icons$2.carCoins,carCrash:icons$2.carCrash,carDealer:icons$2.carDealer,carOffroadOutlineRear:icons$2.carOffroadOutlineRear,carOffroadOutlineSide:icons$2.carOffroadOutlineSide,carOffroadRear:icons$2.carOffroadRear,carOffroadSide:icons$2.carOffroadSide,carSensors:icons$2.carSensors,carStarred:icons$2.carStarred,carToWheels:icons$2.carToWheels,carUp:icons$2.carUp,carWithLidar:icons$2.carWithLidar,car:icons$2.car,cardboardBox:icons$2.cardboardBox,carsChase02:icons$2.carsChase02,cars:icons$2.cars,catalog01:icons$2.catalog01,catalog02:icons$2.catalog02,catalog03:icons$2.catalog03,centrifugalClutchLocked03:icons$2.centrifugalClutchLocked03,centrifugalClutchUnlocked03:icons$2.centrifugalClutchUnlocked03,charge:icons$2.charge,charging:icons$2.charging,chartBars:icons$2.chartBars,checkboxOff:icons$2.checkboxOff,checkboxOn:icons$2.checkboxOn,checkmarkBold:icons$2.checkmarkBold,checkmark:icons$2.checkmark,circuitMicrochip:icons$2.circuitMicrochip,circuit:icons$2.circuit,clapperboard:icons$2.clapperboard,code:icons$2.code,cogDamaged:icons$2.cogDamaged,cogsDamaged:icons$2.cogsDamaged,cogs:icons$2.cogs,concreteRoadBlock:icons$2.concreteRoadBlock,coolantTemp:icons$2.coolantTemp,copy:icons$2.copy,crossroads1:icons$2.crossroads1,crossroads2:icons$2.crossroads2,cruiseDisable:icons$2.cruiseDisable,cruiseEnable:icons$2.cruiseEnable,cup:icons$2.cup,dataExchange:icons$2.dataExchange,day:icons$2.day,DCBattery:icons$2.DCBattery,decalRoad:icons$2.decalRoad,decal:icons$2.decal,deform:icons$2.deform,deliveryTruckArrows:icons$2.deliveryTruckArrows,deliveryTruck:icons$2.deliveryTruck,differentialFrontDefault:icons$2.differentialFrontDefault,differentialFrontLocked:icons$2.differentialFrontLocked,differentialMiddleDefault:icons$2.differentialMiddleDefault,differentialMiddleLocked:icons$2.differentialMiddleLocked,differentialRearDefault:icons$2.differentialRearDefault,differentialRearLocked:icons$2.differentialRearLocked,doorHandle:icons$2.doorHandle,doorIn:icons$2.doorIn,drag01:icons$2.drag01,drag02:icons$2.drag02,drift01:icons$2.drift01,drift02:icons$2.drift02,drivetrainGeneric:icons$2.drivetrainGeneric,drivetrainSpecial:icons$2.drivetrainSpecial,editCheckmark:icons$2.editCheckmark,edit:icons$2.edit,engine:icons$2.engine,ESCOff:icons$2.ESCOff,ESCOn:icons$2.ESCOn,ESC:icons$2.ESC,evade:icons$2.evade,exhaustValve:icons$2.exhaustValve,exit:icons$2.exit,export:icons$2.export,eyeOutlineClosed:icons$2.eyeOutlineClosed,eyeOutlineOpened:icons$2.eyeOutlineOpened,eyeSolidClosed:icons$2.eyeSolidClosed,eyeSolidOpened:icons$2.eyeSolidOpened,eyeWaves:icons$2.eyeWaves,facility02:icons$2.facility02,fastBackward:icons$2.fastBackward,fastForward:icons$2.fastForward,fastTravel:icons$2.fastTravel,filter:icons$2.filter,flagNew:icons$2.flagNew,flag:icons$2.flag,flatBulbBeam:icons$2.flatBulbBeam,flatbedTruck:icons$2.flatbedTruck,floppyDisk:icons$2.floppyDisk,fogLight:icons$2.fogLight,folder:icons$2.folder,forklift:icons$2.forklift,FPS:icons$2.FPS,fragile:icons$2.fragile,frontAxleMidpoint:icons$2.frontAxleMidpoint,frontBumperMidpoint:icons$2.frontBumperMidpoint,fuelPumpFilling:icons$2.fuelPumpFilling,fuelPump:icons$2.fuelPump,FWD:icons$2.FWD,gamepadOld:icons$2.gamepadOld,gamepad:icons$2.gamepad,garage01:icons$2.garage01,garage02:icons$2.garage02,garage03:icons$2.garage03,gaugeEmpty:icons$2.gaugeEmpty,globe:icons$2.globe,GPSMark:icons$2.GPSMark,GPSSolid:icons$2.GPSSolid,group:icons$2.group,gyroscopeMicrochip:icons$2.gyroscopeMicrochip,gyroscope:icons$2.gyroscope,hazardLights:icons$2.hazardLights,helmets:icons$2.helmets,help:icons$2.help,highBeam:icons$2.highBeam,HUD:icons$2.HUD,hydroPump1:icons$2.hydroPump1,hydroPump2:icons$2.hydroPump2,hydroPump3:icons$2.hydroPump3,hydroPump4:icons$2.hydroPump4,hydroPump5:icons$2.hydroPump5,hydroPump6:icons$2.hydroPump6,hydroPump7:icons$2.hydroPump7,hypermiling:icons$2.hypermiling,import:icons$2.import,infinity:icons$2.infinity,info:icons$2.info,jointLocked:icons$2.jointLocked,jointUnlocked:icons$2.jointUnlocked,jump:icons$2.jump,keyboard:icons$2.keyboard,keys1:icons$2.keys1,keys2:icons$2.keys2,lampPost1:icons$2.lampPost1,lampPost2:icons$2.lampPost2,lampPost3:icons$2.lampPost3,laneProperties:icons$2.laneProperties,language:icons$2.language,laptop:icons$2.laptop,lidarPatternFullArcHighFreq:icons$2.lidarPatternFullArcHighFreq,lidarPatternFullArcMidFreq:icons$2.lidarPatternFullArcMidFreq,lidarPatternNarrowArc:icons$2.lidarPatternNarrowArc,lidar:icons$2.lidar,lightGarageG11:icons$2.lightGarageG11,lightGarageG12:icons$2.lightGarageG12,lightGarageG13:icons$2.lightGarageG13,lightGarageG14:icons$2.lightGarageG14,lightGarageG21:icons$2.lightGarageG21,lightGarageG22:icons$2.lightGarageG22,lightGarageG23:icons$2.lightGarageG23,lightGarageG24:icons$2.lightGarageG24,lightGarageG31:icons$2.lightGarageG31,lightGarageG32:icons$2.lightGarageG32,lightGarageG33:icons$2.lightGarageG33,lightGarageG34:icons$2.lightGarageG34,lightrunner:icons$2.lightrunner,limiterEnable:icons$2.limiterEnable,lineToTerrain:icons$2.lineToTerrain,link2:icons$2.link2,link:icons$2.link,listBig:icons$2.listBig,listIndented:icons$2.listIndented,listSmall:icons$2.listSmall,location1:icons$2.location1,location2:icons$2.location2,lockClosed:icons$2.lockClosed,lockOpened:icons$2.lockOpened,longRangeBeam1:icons$2.longRangeBeam1,longRangeBeam2:icons$2.longRangeBeam2,lowBeam:icons$2.lowBeam,magnetOnSurface:icons$2.magnetOnSurface,mapWithEmitter:icons$2.mapWithEmitter,mapPoint:icons$2.mapPoint,material:icons$2.material,mathDivide:icons$2.mathDivide,mathGreaterOrEqualThan:icons$2.mathGreaterOrEqualThan,mathGreaterThan:icons$2.mathGreaterThan,mathLessOrEqualThan:icons$2.mathLessOrEqualThan,mathLessThan:icons$2.mathLessThan,mathMinus:icons$2.mathMinus,mathMultiply:icons$2.mathMultiply,mathPlus:icons$2.mathPlus,medal:icons$2.medal,mesh4Cells:icons$2.mesh4Cells,mesh9Cells:icons$2.mesh9Cells,meshFence:icons$2.meshFence,meshRoad:icons$2.meshRoad,midRangeBeam1:icons$2.midRangeBeam1,midRangeBeam2:icons$2.midRangeBeam2,minusRes:icons$2.minusRes,minus:icons$2.minus,mirrorInteriorMiddle:icons$2.mirrorInteriorMiddle,mirrorLeftBigBottomWideAngle:icons$2.mirrorLeftBigBottomWideAngle,mirrorLeftBigTop:icons$2.mirrorLeftBigTop,mirrorLeftBig:icons$2.mirrorLeftBig,mirrorLeftBonnet:icons$2.mirrorLeftBonnet,mirrorLeftDefault:icons$2.mirrorLeftDefault,mirrorRightBigBottomWideAngle:icons$2.mirrorRightBigBottomWideAngle,mirrorRightBigTop:icons$2.mirrorRightBigTop,mirrorRightBig:icons$2.mirrorRightBig,mirrorRightBonnet:icons$2.mirrorRightBonnet,mirrorRightDefault:icons$2.mirrorRightDefault,mirrorRoundWideAngle:icons$2.mirrorRoundWideAngle,mirrorTopWideAngle:icons$2.mirrorTopWideAngle,missionCheckboxCross:icons$2.missionCheckboxCross,mouseLMB:icons$2.mouseLMB,mouseMMB:icons$2.mouseMMB,mouseRMB:icons$2.mouseRMB,mouseWheel:icons$2.mouseWheel,mouseXAxis:icons$2.mouseXAxis,mouseXYAxis:icons$2.mouseXYAxis,mouseYAxis:icons$2.mouseYAxis,mouse:icons$2.mouse,move02:icons$2.move02,move:icons$2.move,movieCamera:icons$2.movieCamera,music:icons$2.music,N2OButton:icons$2.N2OButton,N2OHoriz:icons$2.N2OHoriz,N2OVert:icons$2.N2OVert,nextTrack:icons$2.nextTrack,night:icons$2.night,noNameControllerButton:icons$2.noNameControllerButton,nodeAddFirst01:icons$2.nodeAddFirst01,nodeAddFirst02:icons$2.nodeAddFirst02,nodeAddLast02:icons$2.nodeAddLast02,nodeAddMiddle01:icons$2.nodeAddMiddle01,nodeAddMiddle02:icons$2.nodeAddMiddle02,nodeAdd:icons$2.nodeAdd,nodeLast01:icons$2.nodeLast01,nodeRemove:icons$2.nodeRemove,odometerKM:icons$2.odometerKM,odometerMI:icons$2.odometerMI,odometer:icons$2.odometer,oilPressureIndicator:icons$2.oilPressureIndicator,order:icons$2.order,organization:icons$2.organization,palmCrossed:icons$2.palmCrossed,paperKnife:icons$2.paperKnife,parkingIndicator:icons$2.parkingIndicator,parking:icons$2.parking,pathArc:icons$2.pathArc,pathAroundObstacle:icons$2.pathAroundObstacle,pathLine:icons$2.pathLine,pathSpiral:icons$2.pathSpiral,pauseRound:icons$2.pauseRound,pause:icons$2.pause,personSolid:icons$2.personSolid,person:icons$2.person,photo:icons$2.photo,placeholder:icons$2.placeholder,playRound:icons$2.playRound,play:icons$2.play,playlist:icons$2.playlist,plusGarage1:icons$2.plusGarage1,plusGarage2:icons$2.plusGarage2,plusGarage3:icons$2.plusGarage3,plusGarage4:icons$2.plusGarage4,plusSet:icons$2.plusSet,plus:icons$2.plus,positionLights:icons$2.positionLights,powerGauge01:icons$2.powerGauge01,powerGauge02:icons$2.powerGauge02,powerGauge03:icons$2.powerGauge03,powerGauge04:icons$2.powerGauge04,powerGauge05:icons$2.powerGauge05,powerOnOff:icons$2.powerOnOff,prevTrack:icons$2.prevTrack,publisher:icons$2.publisher,puzzleModule:icons$2.puzzleModule,raceFlag:icons$2.raceFlag,radarIdeal:icons$2.radarIdeal,radarRoundIdeal:icons$2.radarRoundIdeal,radarRound:icons$2.radarRound,radar:icons$2.radar,rangeboxHi2:icons$2.rangeboxHi2,rangeboxHi4:icons$2.rangeboxHi4,rangeboxHiA:icons$2.rangeboxHiA,rangeboxLo2:icons$2.rangeboxLo2,rangeboxLo4:icons$2.rangeboxLo4,rangeboxLoA:icons$2.rangeboxLoA,rearAxleMidpoint:icons$2.rearAxleMidpoint,rearBumperMidpoint:icons$2.rearBumperMidpoint,reconfigure:icons$2.reconfigure,redo:icons$2.redo,reflectNot:icons$2.reflectNot,reflect:icons$2.reflect,rename:icons$2.rename,replay:icons$2.replay,restart:icons$2.restart,roadDividerLinesDecal:icons$2.roadDividerLinesDecal,roadEdgeLineDecal:icons$2.roadEdgeLineDecal,roadEndLineDecal:icons$2.roadEndLineDecal,roadFace:icons$2.roadFace,roadInfo:icons$2.roadInfo,roadMarkingOutline:icons$2.roadMarkingOutline,roadMarkingSolid:icons$2.roadMarkingSolid,roadOutline:icons$2.roadOutline,roadRefPathDecal:icons$2.roadRefPathDecal,roadRefPath:icons$2.roadRefPath,roadStartLineDecal:icons$2.roadStartLineDecal,road:icons$2.road,rockCrawling01:icons$2.rockCrawling01,rockCrawling02:icons$2.rockCrawling02,routeAdd:icons$2.routeAdd,routeComplex:icons$2.routeComplex,routeSimple:icons$2.routeSimple,runScript:icons$2.runScript,RWD:icons$2.RWD,saveAs1:icons$2.saveAs1,scan:icons$2.scan,search:icons$2.search,semiTrailer:icons$2.semiTrailer,semiTruckCabover:icons$2.semiTruckCabover,semiTruckUS:icons$2.semiTruckUS,semiTruck:icons$2.semiTruck,shortRangeBeam1:icons$2.shortRangeBeam1,shortRangeBeam2:icons$2.shortRangeBeam2,signal01a:icons$2.signal01a,signal02a:icons$2.signal02a,signal03a:icons$2.signal03a,signal04a:icons$2.signal04a,signal05a:icons$2.signal05a,slashLeft:icons$2.slashLeft,slashRight:icons$2.slashRight,smallTrailer:icons$2.smallTrailer,smartphone1:icons$2.smartphone1,smartphone2:icons$2.smartphone2,snowflake:icons$2.snowflake,soundFadeOut:icons$2.soundFadeOut,soundLimit:icons$2.soundLimit,soundLoud:icons$2.soundLoud,soundMonoL:icons$2.soundMonoL,soundMonoR:icons$2.soundMonoR,soundOff:icons$2.soundOff,soundQuiet:icons$2.soundQuiet,soundStereo:icons$2.soundStereo,soundWave01:icons$2.soundWave01,soundWave02:icons$2.soundWave02,sphereOnPathNumber:icons$2.sphereOnPathNumber,sphereOnPath:icons$2.sphereOnPath,sphericalBeam:icons$2.sphericalBeam,spoilerLift:icons$2.spoilerLift,sprayCan:icons$2.sprayCan,stack3:icons$2.stack3,star:icons$2.star,starSecondary:icons$2.starSecondary,steeringWheelCommon:icons$2.steeringWheelCommon,steeringWheelSporty:icons$2.steeringWheelSporty,stopwatchArrows01:icons$2.stopwatchArrows01,stopwatchArrows02:icons$2.stopwatchArrows02,stopwatchSectionOutlinedEnd:icons$2.stopwatchSectionOutlinedEnd,stopwatchSectionOutlinedStart:icons$2.stopwatchSectionOutlinedStart,stopwatchSectionSolidEnd:icons$2.stopwatchSectionSolidEnd,stopwatchSectionSolidStart:icons$2.stopwatchSectionSolidStart,strobeLights:icons$2.strobeLights,sunRise:icons$2.sunRise,survellianceCamera:icons$2.survellianceCamera,suspension01:icons$2.suspension01,suspension02:icons$2.suspension02,switchBlock:icons$2.switchBlock,switchOutline:icons$2.switchOutline,sync:icons$2.sync,synchro01:icons$2.synchro01,synchro02:icons$2.synchro02,tankerTrailer:icons$2.tankerTrailer,targetJump:icons$2.targetJump,taxiCar1:icons$2.taxiCar1,taxiCar3:icons$2.taxiCar3,taxiCarT:icons$2.taxiCarT,taxiCheckerLamp:icons$2.taxiCheckerLamp,terrainToLine:icons$2.terrainToLine,terrain:icons$2.terrain,thinBulbBeam:icons$2.thinBulbBeam,thinnerBulbBeam:icons$2.thinnerBulbBeam,thisSideUp:icons$2.thisSideUp,tiles:icons$2.tiles,timer:icons$2.timer,tireDirection3Fourth2:icons$2.tireDirection3Fourth2,tireDirection3Fourth3:icons$2.tireDirection3Fourth3,tireDirectionFront2:icons$2.tireDirectionFront2,tireDirectionSide2:icons$2.tireDirectionSide2,tireDirectionTop2:icons$2.tireDirectionTop2,tirePressureDecrease01:icons$2.tirePressureDecrease01,tirePressureDecrease02:icons$2.tirePressureDecrease02,tirePressureGaugeAlt01:icons$2.tirePressureGaugeAlt01,tirePressureGaugeAlt02:icons$2.tirePressureGaugeAlt02,tirePressureGaugeAlt03:icons$2.tirePressureGaugeAlt03,tirePressureGaugeOutlined01:icons$2.tirePressureGaugeOutlined01,tirePressureGaugeOutlined02:icons$2.tirePressureGaugeOutlined02,tirePressureGaugeOutlined03:icons$2.tirePressureGaugeOutlined03,tirePressureGaugeSolid01:icons$2.tirePressureGaugeSolid01,tirePressureGaugeSolid02:icons$2.tirePressureGaugeSolid02,tirePressureGaugeSolid03:icons$2.tirePressureGaugeSolid03,tirePressureIncrease01:icons$2.tirePressureIncrease01,tirePressureIncrease02:icons$2.tirePressureIncrease02,tirePressureStopLine:icons$2.tirePressureStopLine,tirePressureStopOctoLine:icons$2.tirePressureStopOctoLine,tirePressureStopOctoSolid:icons$2.tirePressureStopOctoSolid,tirePressureStopSolid:icons$2.tirePressureStopSolid,toCOMWithWheels:icons$2.toCOMWithWheels,toCOM:icons$2.toCOM,toGarage:icons$2.toGarage,touch:icons$2.touch,tow:icons$2.tow,tractionControl:icons$2.tractionControl,trafficCone:icons$2.trafficCone,transform:icons$2.transform,transmissionA:icons$2.transmissionA,transmissionM:icons$2.transmissionM,transparencyMask:icons$2.transparencyMask,trashBin1:icons$2.trashBin1,trashBin2:icons$2.trashBin2,triangleBeam:icons$2.triangleBeam,trim:icons$2.trim,tulipBeam:icons$2.tulipBeam,tunnel:icons$2.tunnel,turbine:icons$2.turbine,twoRoadsAdd:icons$2.twoRoadsAdd,twoRoadsCrossAdd:icons$2.twoRoadsCrossAdd,twoRoadsLink:icons$2.twoRoadsLink,twoUnicyclesOnly:icons$2.twoUnicyclesOnly,undo:icons$2.undo,ungroup:icons$2.ungroup,unlink:icons$2.unlink,vehicleDoorsClose:icons$2.vehicleDoorsClose,vehicleDoorsOpen:icons$2.vehicleDoorsOpen,vehicleDoors:icons$2.vehicleDoors,vehicleFeatures01:icons$2.vehicleFeatures01,vehicleFeatures02:icons$2.vehicleFeatures02,vehicleFeatures03:icons$2.vehicleFeatures03,vehicleHood:icons$2.vehicleHood,vehicleTrunk:icons$2.vehicleTrunk,view:icons$2.view,voucherDiagonal1:icons$2.voucherDiagonal1,voucherDiagonal2:icons$2.voucherDiagonal2,voucherDiagonal3:icons$2.voucherDiagonal3,voucherHorizontal1:icons$2.voucherHorizontal1,voucherHorizontal2:icons$2.voucherHorizontal2,voucherHorizontal3:icons$2.voucherHorizontal3,wavesSignalReceived:icons$2.wavesSignalReceived,wavesSignalSentLeft:icons$2.wavesSignalSentLeft,wavesSignalSentRight:icons$2.wavesSignalSentRight,weather:icons$2.weather,weight:icons$2.weight,wheelHubLocked01:icons$2.wheelHubLocked01,wheelHubUnlocked01:icons$2.wheelHubUnlocked01,wigwags:icons$2.wigwags,wrench:icons$2.wrench,xboxA:icons$2.xboxA,xboxB:icons$2.xboxB,xboxDDefaultOutline:icons$2.xboxDDefaultOutline,xboxDDefaultSolid:icons$2.xboxDDefaultSolid,xboxDDown:icons$2.xboxDDown,xboxDLeft:icons$2.xboxDLeft,xboxDRight:icons$2.xboxDRight,xboxDUp:icons$2.xboxDUp,xboxLB:icons$2.xboxLB,xboxLSButton:icons$2.xboxLSButton,xboxLT:icons$2.xboxLT,xboxMenu:icons$2.xboxMenu,xboxRB:icons$2.xboxRB,xboxRSButton:icons$2.xboxRSButton,xboxRT:icons$2.xboxRT,xboxThumbL:icons$2.xboxThumbL,xboxThumbR:icons$2.xboxThumbR,xboxView:icons$2.xboxView,xboxXAxis:icons$2.xboxXAxis,xboxXRot:icons$2.xboxXRot,xboxX:icons$2.xboxX,xboxYAxis:icons$2.xboxYAxis,xboxYRot:icons$2.xboxYRot,xboxY:icons$2.xboxY,danger:icons$2.danger,droplet:icons$2.droplet,envelope:icons$2.envelope,fireDiamond:icons$2.fireDiamond,rocks:icons$2.rocks,xmark:icons$2.xmark,scale:icons$2.scale,locationDestination:icons$2.locationDestination,locationSource:icons$2.locationSource,accelerationKPH:icons$2.accelerationKPH,accelerationMPH:icons$2.accelerationMPH,boxTruckFast:icons$2.boxTruckFast,colorBrightnessSun:icons$2.colorBrightnessSun,colorCirclePalette:icons$2.colorCirclePalette,colorPalette:icons$2.colorPalette,colorSaturation:icons$2.colorSaturation,sortAscDown02:icons$2.sortAscDown02,sortAscDown:icons$2.sortAscDown,sortAscUp02:icons$2.sortAscUp02,sortAscUp:icons$2.sortAscUp,sortDescDown02:icons$2.sortDescDown02,sortDescDown:icons$2.sortDescDown,sortDescUp02:icons$2.sortDescUp02,sortDescUp:icons$2.sortDescUp,cardboardBoxCoins:icons$2.cardboardBoxCoins,lasso:icons$2.lasso,materialGlossy:icons$2.materialGlossy,materialMetal:icons$2.materialMetal,materialRoughness:icons$2.materialRoughness,materialTransparency01:icons$2.materialTransparency01,materialTransparency02:icons$2.materialTransparency02,metal01:icons$2.metal01,removeItemPolygon:icons$2.removeItemPolygon,removeListItem:icons$2.removeListItem,sortAsc:icons$2.sortAsc,sortDesc:icons$2.sortDesc,surfaceRoughness02:icons$2.surfaceRoughness02,shieldCheckmark:icons$2.shieldCheckmark,shieldHandCheckmark:icons$2.shieldHandCheckmark,shieldHandPlus:icons$2.shieldHandPlus,doorFrontCoins:icons$2.doorFrontCoins,doorFront:icons$2.doorFront,engineCoins:icons$2.engineCoins,exhaustMufflerCoins:icons$2.exhaustMufflerCoins,exhaustMuffler:icons$2.exhaustMuffler,headlightCoins:icons$2.headlightCoins,headlight:icons$2.headlight,tire3FourthCoins:icons$2.tire3FourthCoins,tire3Fourth:icons$2.tire3Fourth,turbineCoins:icons$2.turbineCoins,wheelDiscCoins:icons$2.wheelDiscCoins,wheelDisc:icons$2.wheelDisc,bridgeWithRiver:icons$2.bridgeWithRiver,gizmosOutline:icons$2.gizmosOutline,gizmosSolid:icons$2.gizmosSolid,highwayRoad3To2Merge01:icons$2.highwayRoad3To2Merge01,highwayRoad3To2Merge02:icons$2.highwayRoad3To2Merge02,highwayToUrbanRoadTransition01:icons$2.highwayToUrbanRoadTransition01,highwayToUrbanRoadTransition02:icons$2.highwayToUrbanRoadTransition02,pedestrianCrossing01:icons$2.pedestrianCrossing01,polygonalCube:icons$2.polygonalCube,roadEditOutline:icons$2.roadEditOutline,roadEditSolid:icons$2.roadEditSolid,roadFolderPlus:icons$2.roadFolderPlus,roadFolder:icons$2.roadFolder,roadGuideArrowOutline:icons$2.roadGuideArrowOutline,roadGuideArrowSolid:icons$2.roadGuideArrowSolid,roadOutlineMesh:icons$2.roadOutlineMesh,roadPedestrianCrossing02:icons$2.roadPedestrianCrossing02,roadProfileWithCheckmark:icons$2.roadProfileWithCheckmark,roadProfile:icons$2.roadProfile,roadRoundaboutJunction:icons$2.roadRoundaboutJunction,roadSidewalkTransition:icons$2.roadSidewalkTransition,roadStackPlus:icons$2.roadStackPlus,roadStack:icons$2.roadStack,roadTJunction:icons$2.roadTJunction,roadXJunction:icons$2.roadXJunction,roadYJunction:icons$2.roadYJunction,shoppingCart:icons$2.shoppingCart,singleLineToTerrain:icons$2.singleLineToTerrain,sphereOnMesh:icons$2.sphereOnMesh,twoLinesToTerrain:icons$2.twoLinesToTerrain,urbanRoad3To2Merge01:icons$2.urbanRoad3To2Merge01,urbanRoad3To2Merge02:icons$2.urbanRoad3To2Merge02,urbanRoadToHighwayTransition01:icons$2.urbanRoadToHighwayTransition01,urbanRoadToHighwayTransition02:icons$2.urbanRoadToHighwayTransition02,floppyDiskPlus:icons$2.floppyDiskPlus,highwayMerge:icons$2.highwayMerge,highwaySeparate:icons$2.highwaySeparate,highwayShoulderMerge:icons$2.highwayShoulderMerge,terrainToSingleLine:icons$2.terrainToSingleLine,terrainToTwoLines:icons$2.terrainToTwoLines,urbanRoadMerge:icons$2.urbanRoadMerge,urbanRoadSeparate:icons$2.urbanRoadSeparate,urbanShoulderMerge:icons$2.urbanShoulderMerge,discharging:icons$2.discharging,BNGChat:icons$2.BNGChat,chatBubble:icons$2.chatBubble,busTilted:icons$2.busTilted,cameraFarClip:icons$2.cameraFarClip,cameraNearClip:icons$2.cameraNearClip,explosion:icons$2.explosion,fireExtinguisher:icons$2.fireExtinguisher,fire:icons$2.fire,jointLockedMultiple:icons$2.jointLockedMultiple,jointUnlockedMultiple:icons$2.jointUnlockedMultiple,toggleOff:icons$2.toggleOff,toggleOn:icons$2.toggleOn,viewFarClip:icons$2.viewFarClip,viewNearClip:icons$2.viewNearClip,twoArrowsHorizontal:icons$2.twoArrowsHorizontal,twoArrowsVertical:icons$2.twoArrowsVertical,circleSlashed:icons$2.circleSlashed,scissorsSlashed:icons$2.scissorsSlashed,scissors:icons$2.scissors,airPuffRight1:icons$2.airPuffRight1,airPuffUp1:icons$2.airPuffUp1,arrowsReplace:icons$2.arrowsReplace,arrowsShuffle:icons$2.arrowsShuffle,arrowsSwitch:icons$2.arrowsSwitch,carClock:icons$2.carClock,carFast:icons$2.carFast,carNumber1:icons$2.carNumber1,carNumber2:icons$2.carNumber2,carNumber3:icons$2.carNumber3,carNumber4:icons$2.carNumber4,carNumber5:icons$2.carNumber5,carNumber6:icons$2.carNumber6,carNumber7:icons$2.carNumber7,carNumber8:icons$2.carNumber8,carNumber9:icons$2.carNumber9,carPlus:icons$2.carPlus,carsChange:icons$2.carsChange,carsFollow:icons$2.carsFollow,doorFrontDetached:icons$2.doorFrontDetached,forceFieldPull1:icons$2.forceFieldPull1,forceFieldPull2:icons$2.forceFieldPull2,forceFieldPull3:icons$2.forceFieldPull3,forceFieldPush1:icons$2.forceFieldPush1,forceFieldPush2:icons$2.forceFieldPush2,forceFieldPush3:icons$2.forceFieldPush3,garageNumber1:icons$2.garageNumber1,garageNumber2:icons$2.garageNumber2,garageNumber3:icons$2.garageNumber3,garageNumber4:icons$2.garageNumber4,garageNumber5:icons$2.garageNumber5,garageNumber6:icons$2.garageNumber6,garageNumber7:icons$2.garageNumber7,garageNumber8:icons$2.garageNumber8,garageNumber9:icons$2.garageNumber9,hingeBroken:icons$2.hingeBroken,loadMesh:icons$2.loadMesh,octagonBrick:icons$2.octagonBrick,octagon:icons$2.octagon,pushUp:icons$2.pushUp,saveMesh:icons$2.saveMesh,square:icons$2.square,tireAirPuff:icons$2.tireAirPuff,tireDeflated:icons$2.tireDeflated,trafficLight:icons$2.trafficLight,enter:icons$2.enter,pedestrianRunning:icons$2.pedestrianRunning,pedestrianStanding:icons$2.pedestrianStanding,seatArrowIn:icons$2.seatArrowIn,seatArrowOut:icons$2.seatArrowOut,seatVArrowIn:icons$2.seatVArrowIn,seatVArrowOut:icons$2.seatVArrowOut,vehicleArrowIn:icons$2.vehicleArrowIn,vehicleArrowOut:icons$2.vehicleArrowOut,leverFrontOperate:icons$2.leverFrontOperate,leverSideDown:icons$2.leverSideDown,leverSideOperate:icons$2.leverSideOperate,leverSideUp:icons$2.leverSideUp,medalEmpty:icons$2.medalEmpty,medalStar:icons$2.medalStar,seatArrowInLeft:icons$2.seatArrowInLeft,seatArrowOutLeft:icons$2.seatArrowOutLeft,seatVArrowInLeft:icons$2.seatVArrowInLeft,seatVArrowOutLeft:icons$2.seatVArrowOutLeft,badgeRoundEmpty:icons$2.badgeRoundEmpty,badgeRoundStar:icons$2.badgeRoundStar,badgeRound:icons$2.badgeRound,badge:icons$2.badge,houseWrenchRoof:icons$2.houseWrenchRoof,houseWrench:icons$2.houseWrench,eject:icons$2.eject,rallyHelmet3To4:icons$2.rallyHelmet3To4,rallyHelmet:icons$2.rallyHelmet,test:icons$2.test,globeSimpleNotSign:icons$2.globeSimpleNotSign,globeSimplified:icons$2.globeSimplified,radialMenu:icons$2.radialMenu,branch:icons$2.branch,NA:icons$2.NA,psCircleOutline:icons$2.psCircleOutline,psCircle:icons$2.psCircle,psCreate2:icons$2.psCreate2,psCreate:icons$2.psCreate,psCrossOutline:icons$2.psCrossOutline,psCross:icons$2.psCross,psDDefaultOutline:icons$2.psDDefaultOutline,psDDefaultSolid:icons$2.psDDefaultSolid,psDDown:icons$2.psDDown,psDLeft:icons$2.psDLeft,psDRight:icons$2.psDRight,psDUp:icons$2.psDUp,psL1:icons$2.psL1,psL2:icons$2.psL2,psL3ButtonArrowDown:icons$2.psL3ButtonArrowDown,psL3Button:icons$2.psL3Button,psLSXLeft:icons$2.psLSXLeft,psLSXRight:icons$2.psLSXRight,psLSX:icons$2.psLSX,psLSYDown:icons$2.psLSYDown,psLSYUp:icons$2.psLSYUp,psLSY:icons$2.psLSY,psLS:icons$2.psLS,psMenu2:icons$2.psMenu2,psMenu:icons$2.psMenu,psR1:icons$2.psR1,psR2:icons$2.psR2,psR3ButtonArrowDown:icons$2.psR3ButtonArrowDown,psR3Button:icons$2.psR3Button,psRSXLeft:icons$2.psRSXLeft,psRSXRight:icons$2.psRSXRight,psRSX:icons$2.psRSX,psRSYDown:icons$2.psRSYDown,psRSYUp:icons$2.psRSYUp,psRSY:icons$2.psRSY,psRS:icons$2.psRS,psSquareOutline:icons$2.psSquareOutline,psSquare:icons$2.psSquare,psTrackpadNavigate:icons$2.psTrackpadNavigate,psTrackpadPressCenter:icons$2.psTrackpadPressCenter,psTrackpadPressLeft:icons$2.psTrackpadPressLeft,psTrackpadPressRight:icons$2.psTrackpadPressRight,psTrackpadSwipeDown:icons$2.psTrackpadSwipeDown,psTrackpadSwipeLeft:icons$2.psTrackpadSwipeLeft,psTrackpadSwipeRight:icons$2.psTrackpadSwipeRight,psTrackpadSwipeUp:icons$2.psTrackpadSwipeUp,psTriangleOutline:icons$2.psTriangleOutline,psTriangle:icons$2.psTriangle,xboxAOutline:icons$2.xboxAOutline,xboxBOutline:icons$2.xboxBOutline,xboxLSButtonArrowDown:icons$2.xboxLSButtonArrowDown,xboxRSButtonArrowDown:icons$2.xboxRSButtonArrowDown,xboxXAxisLeft:icons$2.xboxXAxisLeft,xboxXAxisRight:icons$2.xboxXAxisRight,xboxXOutline:icons$2.xboxXOutline,xboxXRotLeft:icons$2.xboxXRotLeft,xboxXRotRight:icons$2.xboxXRotRight,xboxYAxisDown:icons$2.xboxYAxisDown,xboxYAxisUp:icons$2.xboxYAxisUp,xboxYOutline:icons$2.xboxYOutline,xboxYRotDown:icons$2.xboxYRotDown,xboxYRotUp:icons$2.xboxYRotUp,cableSection:icons$2.cableSection,strapHook:icons$2.strapHook,strapRatchet:icons$2.strapRatchet,carFastReverse:icons$2.carFastReverse,carsChase:icons$2.carsChase,carsFlee:icons$2.carsFlee,gaugeFull:icons$2.gaugeFull,hammerParticles:icons$2.hammerParticles,kbArrowsDown:icons$2.kbArrowsDown,kbArrowsLeftRight:icons$2.kbArrowsLeftRight,kbArrowsLeft:icons$2.kbArrowsLeft,kbArrowsOutline:icons$2.kbArrowsOutline,kbArrowsRight:icons$2.kbArrowsRight,kbArrowsSolid:icons$2.kbArrowsSolid,kbArrowsUpDown:icons$2.kbArrowsUpDown,kbArrowsUp:icons$2.kbArrowsUp,magicWand:icons$2.magicWand,psDLeftRight:icons$2.psDLeftRight,psDUpDown:icons$2.psDUpDown,pushBackward:icons$2.pushBackward,pushDown:icons$2.pushDown,pushForward:icons$2.pushForward,rangeboxHi:icons$2.rangeboxHi,rangeboxLo:icons$2.rangeboxLo,routeSimpleFlag:icons$2.routeSimpleFlag,xboxDLeftRight:icons$2.xboxDLeftRight,xboxDUpDown:icons$2.xboxDUpDown,carsWrench:icons$2.carsWrench,jointCycleMultiple:icons$2.jointCycleMultiple,jointCycle:icons$2.jointCycle,dice24:icons$2.dice24,diceD6:icons$2.diceD6,pathDice:icons$2.pathDice,sunDown:icons$2.sunDown,xmarkBold:icons$2.xmarkBold,intakeTrumpets:icons$2.intakeTrumpets,transmissionCvt:icons$2.transmissionCvt,house:icons$2.house,playPause:icons$2.playPause,picture:icons$2.picture,auxUpDown:icons$2.auxUpDown,bucketArmUpDown:icons$2.bucketArmUpDown,bucketTilt:icons$2.bucketTilt,bucketArmDown:icons$2.bucketArmDown,bucketArmLevel:icons$2.bucketArmLevel,bucketArmUp:icons$2.bucketArmUp,bucketTiltDown:icons$2.bucketTiltDown,bucketTiltLevel:icons$2.bucketTiltLevel,bucketTiltUp:icons$2.bucketTiltUp,dumpBedDown:icons$2.dumpBedDown,dumpBedUpDown:icons$2.dumpBedUpDown,dumpBedUp:icons$2.dumpBedUp,beamCurrencyThin:icons$2.beamCurrencyThin,shieldCheckmarkProgressbar:icons$2.shieldCheckmarkProgressbar},48:{AIL:icons$2.AIL,arrowLeftOutline:icons$2.arrowLeftOutline,arrowRightOutline:icons$2.arrowRightOutline,automaticTransmissionL:icons$2.automaticTransmissionL,beamsNodesMessageOutline:icons$2.beamsNodesMessageOutline,beamsNodesOutline:icons$2.beamsNodesOutline,beamsNodesPlugOutline:icons$2.beamsNodesPlugOutline,BNGEcosystemOutline:icons$2.BNGEcosystemOutline,carFrontRouteOutline:icons$2.carFrontRouteOutline,carSensorsOutline:icons$2.carSensorsOutline,carSideRouteOutline:icons$2.carSideRouteOutline,chargeLL:icons$2.chargeLL,cityOutline:icons$2.cityOutline,clutchL:icons$2.clutchL,couplerL:icons$2.couplerL,dialogOutline:icons$2.dialogOutline,documentSmileOutline:icons$2.documentSmileOutline,drivetrainOutline:icons$2.drivetrainOutline,electronicSchemeOutline:icons$2.electronicSchemeOutline,engineL:icons$2.engineL,engineOutline:icons$2.engineOutline,gearTuningOutline:icons$2.gearTuningOutline,giftBoxOutline:icons$2.giftBoxOutline,lidarOutline:icons$2.lidarOutline,medalStarOutline:icons$2.medalStarOutline,megaphoneOutline:icons$2.megaphoneOutline,multiseatL:icons$2.multiseatL,peopleOutline:icons$2.peopleOutline,personOutline:icons$2.personOutline,physicsOutline:icons$2.physicsOutline,playChainOutline:icons$2.playChainOutline,POITimeL:icons$2.POITimeL,proximitySensorsOutline:icons$2.proximitySensorsOutline,qualityBadgeStarOutline:icons$2.qualityBadgeStarOutline,qualityBadgeVOutline:icons$2.qualityBadgeVOutline,replayL:icons$2.replayL,roadblockL:icons$2.roadblockL,rotationL:icons$2.rotationL,sensorsL:icons$2.sensorsL,simRigOutline:icons$2.simRigOutline,suspensionOutline:icons$2.suspensionOutline,teamOutline:icons$2.teamOutline,techLightBulbOutline01:icons$2.techLightBulbOutline01,techLightBulbOutline02:icons$2.techLightBulbOutline02,temperatureL:icons$2.temperatureL,timeUnlockOutline:icons$2.timeUnlockOutline,timedLockOutline:icons$2.timedLockOutline,trafficOutline:icons$2.trafficOutline,tuningL:icons$2.tuningL,turbineL:icons$2.turbineL,voucherOutline:icons$2.voucherOutline,wheelBeamsNodesOutline:icons$2.wheelBeamsNodesOutline,wheelOutline:icons$2.wheelOutline,bridge:icons$2.bridge,bump:icons$2.bump,bumps:icons$2.bumps,caution:icons$2.caution,crest:icons$2.crest,doubleCaution:icons$2.doubleCaution,finish:icons$2.finish,jumpOverBump:icons$2.jumpOverBump,narrows:icons$2.narrows,pothole:icons$2.pothole,turn1:icons$2.turn1,turn2:icons$2.turn2,turn3:icons$2.turn3,turn4:icons$2.turn4,turn5:icons$2.turn5,turn6:icons$2.turn6,turnHp:icons$2.turnHp,turnSq:icons$2.turnSq,water:icons$2.water,beamCurrencyOutlineLarge:icons$2.beamCurrencyOutlineLarge,carSideOutlineLarge:icons$2.carSideOutlineLarge,flagOutlineLarge:icons$2.flagOutlineLarge,terrainOutlineLarge:icons$2.terrainOutlineLarge,tripleCaution:icons$2.tripleCaution},56:{circlePinBack:icons$2.circlePinBack,circlePinFront:icons$2.circlePinFront,markerRectanglePinBack:icons$2.markerRectanglePinBack,markerRectanglePinFront:icons$2.markerRectanglePinFront,markerTriangleBack:icons$2.markerTriangleBack,markerTriangleFront:icons$2.markerTriangleFront}}),iconsByTag=Object.freeze({vehicle:{"4WD":icons$2[`4WD`],ABSIndicator:icons$2.ABSIndicator,AWD:icons$2.AWD,axleLift:icons$2.axleLift,axleCenter:icons$2.axleCenter,axleFront:icons$2.axleFront,axleRear:icons$2.axleRear,boxTruck:icons$2.boxTruck,bus:icons$2.bus,carChase01:icons$2.carChase01,carCoin:icons$2.carCoin,carCoins:icons$2.carCoins,carCrash:icons$2.carCrash,carOffroadOutlineRear:icons$2.carOffroadOutlineRear,carOffroadOutlineSide:icons$2.carOffroadOutlineSide,carOffroadRear:icons$2.carOffroadRear,carOffroadSide:icons$2.carOffroadSide,carSensors:icons$2.carSensors,carStarred:icons$2.carStarred,carToWheels:icons$2.carToWheels,carUp:icons$2.carUp,carWithLidar:icons$2.carWithLidar,car:icons$2.car,carsChase02:icons$2.carsChase02,cars:icons$2.cars,centrifugalClutchLocked03:icons$2.centrifugalClutchLocked03,centrifugalClutchUnlocked03:icons$2.centrifugalClutchUnlocked03,cogDamaged:icons$2.cogDamaged,cogsDamaged:icons$2.cogsDamaged,cogs:icons$2.cogs,coolantTemp:icons$2.coolantTemp,cruiseDisable:icons$2.cruiseDisable,cruiseEnable:icons$2.cruiseEnable,DCBattery:icons$2.DCBattery,deliveryTruckArrows:icons$2.deliveryTruckArrows,deliveryTruck:icons$2.deliveryTruck,differentialFrontDefault:icons$2.differentialFrontDefault,differentialFrontLocked:icons$2.differentialFrontLocked,differentialMiddleDefault:icons$2.differentialMiddleDefault,differentialMiddleLocked:icons$2.differentialMiddleLocked,differentialRearDefault:icons$2.differentialRearDefault,differentialRearLocked:icons$2.differentialRearLocked,doorHandle:icons$2.doorHandle,drift01:icons$2.drift01,drift02:icons$2.drift02,drivetrainGeneric:icons$2.drivetrainGeneric,drivetrainSpecial:icons$2.drivetrainSpecial,engine:icons$2.engine,ESCOff:icons$2.ESCOff,ESCOn:icons$2.ESCOn,ESC:icons$2.ESC,exhaustValve:icons$2.exhaustValve,flatbedTruck:icons$2.flatbedTruck,fogLight:icons$2.fogLight,forklift:icons$2.forklift,FWD:icons$2.FWD,hazardLights:icons$2.hazardLights,highBeam:icons$2.highBeam,hydroPump1:icons$2.hydroPump1,hydroPump2:icons$2.hydroPump2,hydroPump3:icons$2.hydroPump3,hydroPump4:icons$2.hydroPump4,hydroPump5:icons$2.hydroPump5,hydroPump6:icons$2.hydroPump6,hydroPump7:icons$2.hydroPump7,jointLocked:icons$2.jointLocked,jointUnlocked:icons$2.jointUnlocked,keys1:icons$2.keys1,keys2:icons$2.keys2,limiterEnable:icons$2.limiterEnable,lowBeam:icons$2.lowBeam,minusRes:icons$2.minusRes,mirrorInteriorMiddle:icons$2.mirrorInteriorMiddle,mirrorLeftBigBottomWideAngle:icons$2.mirrorLeftBigBottomWideAngle,mirrorLeftBigTop:icons$2.mirrorLeftBigTop,mirrorLeftBig:icons$2.mirrorLeftBig,mirrorLeftBonnet:icons$2.mirrorLeftBonnet,mirrorLeftDefault:icons$2.mirrorLeftDefault,mirrorRightBigBottomWideAngle:icons$2.mirrorRightBigBottomWideAngle,mirrorRightBigTop:icons$2.mirrorRightBigTop,mirrorRightBig:icons$2.mirrorRightBig,mirrorRightBonnet:icons$2.mirrorRightBonnet,mirrorRightDefault:icons$2.mirrorRightDefault,mirrorRoundWideAngle:icons$2.mirrorRoundWideAngle,mirrorTopWideAngle:icons$2.mirrorTopWideAngle,odometerKM:icons$2.odometerKM,odometerMI:icons$2.odometerMI,odometer:icons$2.odometer,oilPressureIndicator:icons$2.oilPressureIndicator,parkingIndicator:icons$2.parkingIndicator,plusSet:icons$2.plusSet,positionLights:icons$2.positionLights,powerGauge01:icons$2.powerGauge01,powerGauge02:icons$2.powerGauge02,powerGauge03:icons$2.powerGauge03,powerGauge04:icons$2.powerGauge04,powerGauge05:icons$2.powerGauge05,rangeboxHi2:icons$2.rangeboxHi2,rangeboxHi4:icons$2.rangeboxHi4,rangeboxHiA:icons$2.rangeboxHiA,rangeboxLo2:icons$2.rangeboxLo2,rangeboxLo4:icons$2.rangeboxLo4,rangeboxLoA:icons$2.rangeboxLoA,rockCrawling01:icons$2.rockCrawling01,RWD:icons$2.RWD,semiTrailer:icons$2.semiTrailer,semiTruckCabover:icons$2.semiTruckCabover,semiTruckUS:icons$2.semiTruckUS,semiTruck:icons$2.semiTruck,smallTrailer:icons$2.smallTrailer,spoilerLift:icons$2.spoilerLift,strobeLights:icons$2.strobeLights,suspension01:icons$2.suspension01,suspension02:icons$2.suspension02,synchro01:icons$2.synchro01,synchro02:icons$2.synchro02,tankerTrailer:icons$2.tankerTrailer,taxiCar1:icons$2.taxiCar1,taxiCar3:icons$2.taxiCar3,taxiCarT:icons$2.taxiCarT,taxiCheckerLamp:icons$2.taxiCheckerLamp,tirePressureDecrease01:icons$2.tirePressureDecrease01,tirePressureDecrease02:icons$2.tirePressureDecrease02,tirePressureGaugeAlt01:icons$2.tirePressureGaugeAlt01,tirePressureGaugeAlt02:icons$2.tirePressureGaugeAlt02,tirePressureGaugeAlt03:icons$2.tirePressureGaugeAlt03,tirePressureGaugeOutlined01:icons$2.tirePressureGaugeOutlined01,tirePressureGaugeOutlined02:icons$2.tirePressureGaugeOutlined02,tirePressureGaugeOutlined03:icons$2.tirePressureGaugeOutlined03,tirePressureGaugeSolid01:icons$2.tirePressureGaugeSolid01,tirePressureGaugeSolid02:icons$2.tirePressureGaugeSolid02,tirePressureGaugeSolid03:icons$2.tirePressureGaugeSolid03,tirePressureIncrease01:icons$2.tirePressureIncrease01,tirePressureIncrease02:icons$2.tirePressureIncrease02,tirePressureStopLine:icons$2.tirePressureStopLine,tirePressureStopOctoLine:icons$2.tirePressureStopOctoLine,tirePressureStopOctoSolid:icons$2.tirePressureStopOctoSolid,tirePressureStopSolid:icons$2.tirePressureStopSolid,tow:icons$2.tow,tractionControl:icons$2.tractionControl,transmissionA:icons$2.transmissionA,transmissionM:icons$2.transmissionM,turbine:icons$2.turbine,vehicleDoorsClose:icons$2.vehicleDoorsClose,vehicleDoorsOpen:icons$2.vehicleDoorsOpen,vehicleDoors:icons$2.vehicleDoors,vehicleFeatures01:icons$2.vehicleFeatures01,vehicleFeatures02:icons$2.vehicleFeatures02,vehicleFeatures03:icons$2.vehicleFeatures03,vehicleHood:icons$2.vehicleHood,vehicleTrunk:icons$2.vehicleTrunk,wheelHubLocked01:icons$2.wheelHubLocked01,wheelHubUnlocked01:icons$2.wheelHubUnlocked01,wigwags:icons$2.wigwags,wrench:icons$2.wrench,accelerationKPH:icons$2.accelerationKPH,accelerationMPH:icons$2.accelerationMPH,boxTruckFast:icons$2.boxTruckFast,doorFrontCoins:icons$2.doorFrontCoins,doorFront:icons$2.doorFront,engineCoins:icons$2.engineCoins,exhaustMufflerCoins:icons$2.exhaustMufflerCoins,exhaustMuffler:icons$2.exhaustMuffler,headlightCoins:icons$2.headlightCoins,headlight:icons$2.headlight,tire3FourthCoins:icons$2.tire3FourthCoins,tire3Fourth:icons$2.tire3Fourth,turbineCoins:icons$2.turbineCoins,wheelDiscCoins:icons$2.wheelDiscCoins,wheelDisc:icons$2.wheelDisc,busTilted:icons$2.busTilted,jointLockedMultiple:icons$2.jointLockedMultiple,jointUnlockedMultiple:icons$2.jointUnlockedMultiple,airPuffRight1:icons$2.airPuffRight1,carClock:icons$2.carClock,carFast:icons$2.carFast,carNumber1:icons$2.carNumber1,carNumber2:icons$2.carNumber2,carNumber3:icons$2.carNumber3,carNumber4:icons$2.carNumber4,carNumber5:icons$2.carNumber5,carNumber6:icons$2.carNumber6,carNumber7:icons$2.carNumber7,carNumber8:icons$2.carNumber8,carNumber9:icons$2.carNumber9,carPlus:icons$2.carPlus,carsChange:icons$2.carsChange,carsFollow:icons$2.carsFollow,doorFrontDetached:icons$2.doorFrontDetached,hingeBroken:icons$2.hingeBroken,octagonBrick:icons$2.octagonBrick,octagon:icons$2.octagon,tireAirPuff:icons$2.tireAirPuff,tireDeflated:icons$2.tireDeflated,carSideOutlineLarge:icons$2.carSideOutlineLarge,carFastReverse:icons$2.carFastReverse,carsChase:icons$2.carsChase,carsFlee:icons$2.carsFlee,hammerParticles:icons$2.hammerParticles,rangeboxHi:icons$2.rangeboxHi,rangeboxLo:icons$2.rangeboxLo,carsWrench:icons$2.carsWrench,jointCycleMultiple:icons$2.jointCycleMultiple,jointCycle:icons$2.jointCycle,intakeTrumpets:icons$2.intakeTrumpets,transmissionCvt:icons$2.transmissionCvt,auxUpDown:icons$2.auxUpDown,bucketArmUpDown:icons$2.bucketArmUpDown,bucketTilt:icons$2.bucketTilt,bucketArmDown:icons$2.bucketArmDown,bucketArmLevel:icons$2.bucketArmLevel,bucketArmUp:icons$2.bucketArmUp,bucketTiltDown:icons$2.bucketTiltDown,bucketTiltLevel:icons$2.bucketTiltLevel,bucketTiltUp:icons$2.bucketTiltUp,dumpBedDown:icons$2.dumpBedDown,dumpBedUpDown:icons$2.dumpBedUpDown,dumpBedUp:icons$2.dumpBedUp},features:{"4WD":icons$2[`4WD`],ABSIndicator:icons$2.ABSIndicator,AWD:icons$2.AWD,axleLift:icons$2.axleLift,axleCenter:icons$2.axleCenter,axleFront:icons$2.axleFront,axleRear:icons$2.axleRear,carCoin:icons$2.carCoin,carCoins:icons$2.carCoins,carDealer:icons$2.carDealer,carStarred:icons$2.carStarred,centrifugalClutchLocked03:icons$2.centrifugalClutchLocked03,centrifugalClutchUnlocked03:icons$2.centrifugalClutchUnlocked03,cogDamaged:icons$2.cogDamaged,cogsDamaged:icons$2.cogsDamaged,cogs:icons$2.cogs,coolantTemp:icons$2.coolantTemp,cruiseDisable:icons$2.cruiseDisable,cruiseEnable:icons$2.cruiseEnable,DCBattery:icons$2.DCBattery,differentialFrontDefault:icons$2.differentialFrontDefault,differentialFrontLocked:icons$2.differentialFrontLocked,differentialMiddleDefault:icons$2.differentialMiddleDefault,differentialMiddleLocked:icons$2.differentialMiddleLocked,differentialRearDefault:icons$2.differentialRearDefault,differentialRearLocked:icons$2.differentialRearLocked,doorHandle:icons$2.doorHandle,drivetrainGeneric:icons$2.drivetrainGeneric,drivetrainSpecial:icons$2.drivetrainSpecial,engine:icons$2.engine,ESCOff:icons$2.ESCOff,ESCOn:icons$2.ESCOn,ESC:icons$2.ESC,exhaustValve:icons$2.exhaustValve,fogLight:icons$2.fogLight,FWD:icons$2.FWD,garage01:icons$2.garage01,garage02:icons$2.garage02,garage03:icons$2.garage03,hazardLights:icons$2.hazardLights,highBeam:icons$2.highBeam,hydroPump1:icons$2.hydroPump1,hydroPump2:icons$2.hydroPump2,hydroPump3:icons$2.hydroPump3,hydroPump4:icons$2.hydroPump4,hydroPump5:icons$2.hydroPump5,hydroPump6:icons$2.hydroPump6,hydroPump7:icons$2.hydroPump7,jointLocked:icons$2.jointLocked,jointUnlocked:icons$2.jointUnlocked,keys1:icons$2.keys1,keys2:icons$2.keys2,limiterEnable:icons$2.limiterEnable,lowBeam:icons$2.lowBeam,minusRes:icons$2.minusRes,mirrorInteriorMiddle:icons$2.mirrorInteriorMiddle,mirrorLeftBigBottomWideAngle:icons$2.mirrorLeftBigBottomWideAngle,mirrorLeftBigTop:icons$2.mirrorLeftBigTop,mirrorLeftBig:icons$2.mirrorLeftBig,mirrorLeftBonnet:icons$2.mirrorLeftBonnet,mirrorLeftDefault:icons$2.mirrorLeftDefault,mirrorRightBigBottomWideAngle:icons$2.mirrorRightBigBottomWideAngle,mirrorRightBigTop:icons$2.mirrorRightBigTop,mirrorRightBig:icons$2.mirrorRightBig,mirrorRightBonnet:icons$2.mirrorRightBonnet,mirrorRightDefault:icons$2.mirrorRightDefault,mirrorRoundWideAngle:icons$2.mirrorRoundWideAngle,mirrorTopWideAngle:icons$2.mirrorTopWideAngle,odometerKM:icons$2.odometerKM,odometerMI:icons$2.odometerMI,odometer:icons$2.odometer,oilPressureIndicator:icons$2.oilPressureIndicator,parkingIndicator:icons$2.parkingIndicator,plusGarage1:icons$2.plusGarage1,plusGarage2:icons$2.plusGarage2,plusGarage3:icons$2.plusGarage3,plusGarage4:icons$2.plusGarage4,plusSet:icons$2.plusSet,positionLights:icons$2.positionLights,powerGauge01:icons$2.powerGauge01,powerGauge02:icons$2.powerGauge02,powerGauge03:icons$2.powerGauge03,powerGauge04:icons$2.powerGauge04,powerGauge05:icons$2.powerGauge05,rangeboxHi2:icons$2.rangeboxHi2,rangeboxHi4:icons$2.rangeboxHi4,rangeboxHiA:icons$2.rangeboxHiA,rangeboxLo2:icons$2.rangeboxLo2,rangeboxLo4:icons$2.rangeboxLo4,rangeboxLoA:icons$2.rangeboxLoA,RWD:icons$2.RWD,spoilerLift:icons$2.spoilerLift,strobeLights:icons$2.strobeLights,suspension01:icons$2.suspension01,suspension02:icons$2.suspension02,synchro01:icons$2.synchro01,synchro02:icons$2.synchro02,tirePressureDecrease01:icons$2.tirePressureDecrease01,tirePressureDecrease02:icons$2.tirePressureDecrease02,tirePressureGaugeAlt01:icons$2.tirePressureGaugeAlt01,tirePressureGaugeAlt02:icons$2.tirePressureGaugeAlt02,tirePressureGaugeAlt03:icons$2.tirePressureGaugeAlt03,tirePressureGaugeOutlined01:icons$2.tirePressureGaugeOutlined01,tirePressureGaugeOutlined02:icons$2.tirePressureGaugeOutlined02,tirePressureGaugeOutlined03:icons$2.tirePressureGaugeOutlined03,tirePressureGaugeSolid01:icons$2.tirePressureGaugeSolid01,tirePressureGaugeSolid02:icons$2.tirePressureGaugeSolid02,tirePressureGaugeSolid03:icons$2.tirePressureGaugeSolid03,tirePressureIncrease01:icons$2.tirePressureIncrease01,tirePressureIncrease02:icons$2.tirePressureIncrease02,tirePressureStopLine:icons$2.tirePressureStopLine,tirePressureStopOctoLine:icons$2.tirePressureStopOctoLine,tirePressureStopOctoSolid:icons$2.tirePressureStopOctoSolid,tirePressureStopSolid:icons$2.tirePressureStopSolid,tractionControl:icons$2.tractionControl,transmissionA:icons$2.transmissionA,transmissionM:icons$2.transmissionM,turbine:icons$2.turbine,vehicleDoorsClose:icons$2.vehicleDoorsClose,vehicleDoorsOpen:icons$2.vehicleDoorsOpen,vehicleDoors:icons$2.vehicleDoors,vehicleFeatures01:icons$2.vehicleFeatures01,vehicleFeatures02:icons$2.vehicleFeatures02,vehicleFeatures03:icons$2.vehicleFeatures03,vehicleHood:icons$2.vehicleHood,vehicleTrunk:icons$2.vehicleTrunk,wheelHubLocked01:icons$2.wheelHubLocked01,wheelHubUnlocked01:icons$2.wheelHubUnlocked01,wigwags:icons$2.wigwags,wrench:icons$2.wrench,accelerationKPH:icons$2.accelerationKPH,accelerationMPH:icons$2.accelerationMPH,doorFrontCoins:icons$2.doorFrontCoins,doorFront:icons$2.doorFront,engineCoins:icons$2.engineCoins,exhaustMufflerCoins:icons$2.exhaustMufflerCoins,exhaustMuffler:icons$2.exhaustMuffler,headlightCoins:icons$2.headlightCoins,headlight:icons$2.headlight,tire3FourthCoins:icons$2.tire3FourthCoins,tire3Fourth:icons$2.tire3Fourth,turbineCoins:icons$2.turbineCoins,wheelDiscCoins:icons$2.wheelDiscCoins,wheelDisc:icons$2.wheelDisc,jointLockedMultiple:icons$2.jointLockedMultiple,jointUnlockedMultiple:icons$2.jointUnlockedMultiple,bridge:icons$2.bridge,bump:icons$2.bump,bumps:icons$2.bumps,caution:icons$2.caution,crest:icons$2.crest,doubleCaution:icons$2.doubleCaution,finish:icons$2.finish,jumpOverBump:icons$2.jumpOverBump,narrows:icons$2.narrows,pothole:icons$2.pothole,turn1:icons$2.turn1,turn2:icons$2.turn2,turn3:icons$2.turn3,turn4:icons$2.turn4,turn5:icons$2.turn5,turn6:icons$2.turn6,turnHp:icons$2.turnHp,turnSq:icons$2.turnSq,water:icons$2.water,carsFollow:icons$2.carsFollow,doorFrontDetached:icons$2.doorFrontDetached,garageNumber1:icons$2.garageNumber1,garageNumber2:icons$2.garageNumber2,garageNumber3:icons$2.garageNumber3,garageNumber4:icons$2.garageNumber4,garageNumber5:icons$2.garageNumber5,garageNumber6:icons$2.garageNumber6,garageNumber7:icons$2.garageNumber7,garageNumber8:icons$2.garageNumber8,garageNumber9:icons$2.garageNumber9,hingeBroken:icons$2.hingeBroken,houseWrenchRoof:icons$2.houseWrenchRoof,houseWrench:icons$2.houseWrench,tripleCaution:icons$2.tripleCaution,carsChase:icons$2.carsChase,carsFlee:icons$2.carsFlee,hammerParticles:icons$2.hammerParticles,rangeboxHi:icons$2.rangeboxHi,rangeboxLo:icons$2.rangeboxLo,jointCycleMultiple:icons$2.jointCycleMultiple,jointCycle:icons$2.jointCycle,intakeTrumpets:icons$2.intakeTrumpets,transmissionCvt:icons$2.transmissionCvt,house:icons$2.house,auxUpDown:icons$2.auxUpDown,bucketArmUpDown:icons$2.bucketArmUpDown,bucketTilt:icons$2.bucketTilt,bucketArmDown:icons$2.bucketArmDown,bucketArmLevel:icons$2.bucketArmLevel,bucketArmUp:icons$2.bucketArmUp,bucketTiltDown:icons$2.bucketTiltDown,bucketTiltLevel:icons$2.bucketTiltLevel,bucketTiltUp:icons$2.bucketTiltUp,dumpBedDown:icons$2.dumpBedDown,dumpBedUpDown:icons$2.dumpBedUpDown,dumpBedUp:icons$2.dumpBedUp},generic:{"9dividedby10":icons$2[`9dividedby10`],abandon:icons$2.abandon,addItemPolygon:icons$2.addItemPolygon,addListItem:icons$2.addListItem,addPolygonVertex:icons$2.addPolygonVertex,adjust:icons$2.adjust,AIMicrochip:icons$2.AIMicrochip,aperture:icons$2.aperture,autobahn:icons$2.autobahn,bSpline:icons$2.bSpline,beamCrashBarrier1:icons$2.beamCrashBarrier1,beamCrashBarrier2:icons$2.beamCrashBarrier2,beamCrashBarrier3:icons$2.beamCrashBarrier3,beamNG:icons$2.beamNG,bezierPath1:icons$2.bezierPath1,bezierPath2:icons$2.bezierPath2,bicycle1:icons$2.bicycle1,bicycle2:icons$2.bicycle2,BNGFolder:icons$2.BNGFolder,BNGMicrochip:icons$2.BNGMicrochip,bollard:icons$2.bollard,bookmark:icons$2.bookmark,booleanIntersect:icons$2.booleanIntersect,broom:icons$2.broom,bucketAdd:icons$2.bucketAdd,bucketSubtract:icons$2.bucketSubtract,bug:icons$2.bug,bulldozer:icons$2.bulldozer,carChase01:icons$2.carChase01,carCrash:icons$2.carCrash,carOffroadOutlineRear:icons$2.carOffroadOutlineRear,carOffroadOutlineSide:icons$2.carOffroadOutlineSide,carOffroadRear:icons$2.carOffroadRear,carOffroadSide:icons$2.carOffroadSide,carSensors:icons$2.carSensors,carToWheels:icons$2.carToWheels,carUp:icons$2.carUp,carWithLidar:icons$2.carWithLidar,car:icons$2.car,cardboardBox:icons$2.cardboardBox,carsChase02:icons$2.carsChase02,cars:icons$2.cars,catalog01:icons$2.catalog01,catalog02:icons$2.catalog02,catalog03:icons$2.catalog03,chartBars:icons$2.chartBars,checkmarkBold:icons$2.checkmarkBold,checkmark:icons$2.checkmark,circuitMicrochip:icons$2.circuitMicrochip,clapperboard:icons$2.clapperboard,code:icons$2.code,concreteRoadBlock:icons$2.concreteRoadBlock,copy:icons$2.copy,crossroads1:icons$2.crossroads1,crossroads2:icons$2.crossroads2,cup:icons$2.cup,dataExchange:icons$2.dataExchange,decalRoad:icons$2.decalRoad,decal:icons$2.decal,deform:icons$2.deform,doorIn:icons$2.doorIn,editCheckmark:icons$2.editCheckmark,edit:icons$2.edit,exit:icons$2.exit,export:icons$2.export,eyeOutlineClosed:icons$2.eyeOutlineClosed,eyeOutlineOpened:icons$2.eyeOutlineOpened,eyeSolidClosed:icons$2.eyeSolidClosed,eyeSolidOpened:icons$2.eyeSolidOpened,eyeWaves:icons$2.eyeWaves,facility02:icons$2.facility02,filter:icons$2.filter,flatBulbBeam:icons$2.flatBulbBeam,floppyDisk:icons$2.floppyDisk,folder:icons$2.folder,FPS:icons$2.FPS,frontAxleMidpoint:icons$2.frontAxleMidpoint,frontBumperMidpoint:icons$2.frontBumperMidpoint,globe:icons$2.globe,GPSMark:icons$2.GPSMark,GPSSolid:icons$2.GPSSolid,group:icons$2.group,gyroscopeMicrochip:icons$2.gyroscopeMicrochip,gyroscope:icons$2.gyroscope,helmets:icons$2.helmets,help:icons$2.help,HUD:icons$2.HUD,import:icons$2.import,infinity:icons$2.infinity,info:icons$2.info,lampPost1:icons$2.lampPost1,lampPost2:icons$2.lampPost2,lampPost3:icons$2.lampPost3,laneProperties:icons$2.laneProperties,language:icons$2.language,laptop:icons$2.laptop,lidarPatternFullArcHighFreq:icons$2.lidarPatternFullArcHighFreq,lidarPatternFullArcMidFreq:icons$2.lidarPatternFullArcMidFreq,lidarPatternNarrowArc:icons$2.lidarPatternNarrowArc,lidar:icons$2.lidar,lightrunner:icons$2.lightrunner,lineToTerrain:icons$2.lineToTerrain,link2:icons$2.link2,link:icons$2.link,listBig:icons$2.listBig,listIndented:icons$2.listIndented,listSmall:icons$2.listSmall,location1:icons$2.location1,location2:icons$2.location2,lockClosed:icons$2.lockClosed,lockOpened:icons$2.lockOpened,longRangeBeam1:icons$2.longRangeBeam1,longRangeBeam2:icons$2.longRangeBeam2,magnetOnSurface:icons$2.magnetOnSurface,mapWithEmitter:icons$2.mapWithEmitter,mapPoint:icons$2.mapPoint,material:icons$2.material,mathDivide:icons$2.mathDivide,mathGreaterOrEqualThan:icons$2.mathGreaterOrEqualThan,mathGreaterThan:icons$2.mathGreaterThan,mathLessOrEqualThan:icons$2.mathLessOrEqualThan,mathLessThan:icons$2.mathLessThan,mathMinus:icons$2.mathMinus,mathMultiply:icons$2.mathMultiply,mathPlus:icons$2.mathPlus,medal:icons$2.medal,meshFence:icons$2.meshFence,meshRoad:icons$2.meshRoad,midRangeBeam1:icons$2.midRangeBeam1,midRangeBeam2:icons$2.midRangeBeam2,minus:icons$2.minus,move02:icons$2.move02,move:icons$2.move,nodeAddFirst01:icons$2.nodeAddFirst01,nodeAddFirst02:icons$2.nodeAddFirst02,nodeAddLast02:icons$2.nodeAddLast02,nodeAddMiddle01:icons$2.nodeAddMiddle01,nodeAddMiddle02:icons$2.nodeAddMiddle02,nodeAdd:icons$2.nodeAdd,nodeLast01:icons$2.nodeLast01,nodeRemove:icons$2.nodeRemove,order:icons$2.order,organization:icons$2.organization,paperKnife:icons$2.paperKnife,pathArc:icons$2.pathArc,pathLine:icons$2.pathLine,pathSpiral:icons$2.pathSpiral,personSolid:icons$2.personSolid,person:icons$2.person,photo:icons$2.photo,placeholder:icons$2.placeholder,plus:icons$2.plus,powerOnOff:icons$2.powerOnOff,publisher:icons$2.publisher,puzzleModule:icons$2.puzzleModule,radarIdeal:icons$2.radarIdeal,radarRoundIdeal:icons$2.radarRoundIdeal,radarRound:icons$2.radarRound,radar:icons$2.radar,rearAxleMidpoint:icons$2.rearAxleMidpoint,rearBumperMidpoint:icons$2.rearBumperMidpoint,reconfigure:icons$2.reconfigure,redo:icons$2.redo,reflectNot:icons$2.reflectNot,reflect:icons$2.reflect,rename:icons$2.rename,replay:icons$2.replay,restart:icons$2.restart,roadDividerLinesDecal:icons$2.roadDividerLinesDecal,roadEdgeLineDecal:icons$2.roadEdgeLineDecal,roadEndLineDecal:icons$2.roadEndLineDecal,roadFace:icons$2.roadFace,roadInfo:icons$2.roadInfo,roadMarkingOutline:icons$2.roadMarkingOutline,roadMarkingSolid:icons$2.roadMarkingSolid,roadOutline:icons$2.roadOutline,roadRefPathDecal:icons$2.roadRefPathDecal,roadRefPath:icons$2.roadRefPath,roadStartLineDecal:icons$2.roadStartLineDecal,road:icons$2.road,runScript:icons$2.runScript,saveAs1:icons$2.saveAs1,scan:icons$2.scan,search:icons$2.search,shortRangeBeam1:icons$2.shortRangeBeam1,shortRangeBeam2:icons$2.shortRangeBeam2,signal01a:icons$2.signal01a,signal02a:icons$2.signal02a,signal03a:icons$2.signal03a,signal04a:icons$2.signal04a,signal05a:icons$2.signal05a,slashLeft:icons$2.slashLeft,slashRight:icons$2.slashRight,snowflake:icons$2.snowflake,soundFadeOut:icons$2.soundFadeOut,soundLimit:icons$2.soundLimit,soundLoud:icons$2.soundLoud,soundMonoL:icons$2.soundMonoL,soundMonoR:icons$2.soundMonoR,soundOff:icons$2.soundOff,soundQuiet:icons$2.soundQuiet,soundStereo:icons$2.soundStereo,soundWave01:icons$2.soundWave01,soundWave02:icons$2.soundWave02,sphereOnPathNumber:icons$2.sphereOnPathNumber,sphereOnPath:icons$2.sphereOnPath,sphericalBeam:icons$2.sphericalBeam,sprayCan:icons$2.sprayCan,star:icons$2.star,starSecondary:icons$2.starSecondary,stopwatchArrows01:icons$2.stopwatchArrows01,stopwatchArrows02:icons$2.stopwatchArrows02,stopwatchSectionOutlinedEnd:icons$2.stopwatchSectionOutlinedEnd,stopwatchSectionOutlinedStart:icons$2.stopwatchSectionOutlinedStart,stopwatchSectionSolidEnd:icons$2.stopwatchSectionSolidEnd,stopwatchSectionSolidStart:icons$2.stopwatchSectionSolidStart,survellianceCamera:icons$2.survellianceCamera,switchBlock:icons$2.switchBlock,switchOutline:icons$2.switchOutline,sync:icons$2.sync,taxiCar1:icons$2.taxiCar1,taxiCar3:icons$2.taxiCar3,taxiCarT:icons$2.taxiCarT,taxiCheckerLamp:icons$2.taxiCheckerLamp,terrainToLine:icons$2.terrainToLine,terrain:icons$2.terrain,thinBulbBeam:icons$2.thinBulbBeam,thinnerBulbBeam:icons$2.thinnerBulbBeam,tiles:icons$2.tiles,timer:icons$2.timer,toCOMWithWheels:icons$2.toCOMWithWheels,toCOM:icons$2.toCOM,tow:icons$2.tow,transform:icons$2.transform,transparencyMask:icons$2.transparencyMask,trashBin2:icons$2.trashBin2,triangleBeam:icons$2.triangleBeam,trim:icons$2.trim,tulipBeam:icons$2.tulipBeam,tunnel:icons$2.tunnel,twoRoadsAdd:icons$2.twoRoadsAdd,twoRoadsCrossAdd:icons$2.twoRoadsCrossAdd,twoRoadsLink:icons$2.twoRoadsLink,undo:icons$2.undo,ungroup:icons$2.ungroup,unlink:icons$2.unlink,view:icons$2.view,voucherDiagonal1:icons$2.voucherDiagonal1,voucherDiagonal2:icons$2.voucherDiagonal2,voucherDiagonal3:icons$2.voucherDiagonal3,voucherHorizontal1:icons$2.voucherHorizontal1,voucherHorizontal2:icons$2.voucherHorizontal2,voucherHorizontal3:icons$2.voucherHorizontal3,wavesSignalReceived:icons$2.wavesSignalReceived,wavesSignalSentLeft:icons$2.wavesSignalSentLeft,wavesSignalSentRight:icons$2.wavesSignalSentRight,weight:icons$2.weight,wrench:icons$2.wrench,danger:icons$2.danger,droplet:icons$2.droplet,envelope:icons$2.envelope,fireDiamond:icons$2.fireDiamond,xmark:icons$2.xmark,scale:icons$2.scale,locationDestination:icons$2.locationDestination,locationSource:icons$2.locationSource,colorBrightnessSun:icons$2.colorBrightnessSun,colorCirclePalette:icons$2.colorCirclePalette,colorPalette:icons$2.colorPalette,colorSaturation:icons$2.colorSaturation,sortAscDown02:icons$2.sortAscDown02,sortAscDown:icons$2.sortAscDown,sortAscUp02:icons$2.sortAscUp02,sortAscUp:icons$2.sortAscUp,sortDescDown02:icons$2.sortDescDown02,sortDescDown:icons$2.sortDescDown,sortDescUp02:icons$2.sortDescUp02,sortDescUp:icons$2.sortDescUp,cardboardBoxCoins:icons$2.cardboardBoxCoins,lasso:icons$2.lasso,materialGlossy:icons$2.materialGlossy,materialMetal:icons$2.materialMetal,materialRoughness:icons$2.materialRoughness,materialTransparency01:icons$2.materialTransparency01,materialTransparency02:icons$2.materialTransparency02,metal01:icons$2.metal01,removeItemPolygon:icons$2.removeItemPolygon,removeListItem:icons$2.removeListItem,sortAsc:icons$2.sortAsc,sortDesc:icons$2.sortDesc,surfaceRoughness02:icons$2.surfaceRoughness02,shieldCheckmark:icons$2.shieldCheckmark,shieldHandCheckmark:icons$2.shieldHandCheckmark,shieldHandPlus:icons$2.shieldHandPlus,bridgeWithRiver:icons$2.bridgeWithRiver,gizmosOutline:icons$2.gizmosOutline,gizmosSolid:icons$2.gizmosSolid,highwayRoad3To2Merge01:icons$2.highwayRoad3To2Merge01,highwayRoad3To2Merge02:icons$2.highwayRoad3To2Merge02,highwayToUrbanRoadTransition01:icons$2.highwayToUrbanRoadTransition01,highwayToUrbanRoadTransition02:icons$2.highwayToUrbanRoadTransition02,pedestrianCrossing01:icons$2.pedestrianCrossing01,polygonalCube:icons$2.polygonalCube,roadEditOutline:icons$2.roadEditOutline,roadEditSolid:icons$2.roadEditSolid,roadFolderPlus:icons$2.roadFolderPlus,roadFolder:icons$2.roadFolder,roadGuideArrowOutline:icons$2.roadGuideArrowOutline,roadGuideArrowSolid:icons$2.roadGuideArrowSolid,roadOutlineMesh:icons$2.roadOutlineMesh,roadPedestrianCrossing02:icons$2.roadPedestrianCrossing02,roadProfileWithCheckmark:icons$2.roadProfileWithCheckmark,roadProfile:icons$2.roadProfile,roadRoundaboutJunction:icons$2.roadRoundaboutJunction,roadSidewalkTransition:icons$2.roadSidewalkTransition,roadStackPlus:icons$2.roadStackPlus,roadStack:icons$2.roadStack,roadTJunction:icons$2.roadTJunction,roadXJunction:icons$2.roadXJunction,roadYJunction:icons$2.roadYJunction,shoppingCart:icons$2.shoppingCart,singleLineToTerrain:icons$2.singleLineToTerrain,sphereOnMesh:icons$2.sphereOnMesh,twoLinesToTerrain:icons$2.twoLinesToTerrain,urbanRoad3To2Merge01:icons$2.urbanRoad3To2Merge01,urbanRoad3To2Merge02:icons$2.urbanRoad3To2Merge02,urbanRoadToHighwayTransition01:icons$2.urbanRoadToHighwayTransition01,urbanRoadToHighwayTransition02:icons$2.urbanRoadToHighwayTransition02,floppyDiskPlus:icons$2.floppyDiskPlus,highwayMerge:icons$2.highwayMerge,highwaySeparate:icons$2.highwaySeparate,highwayShoulderMerge:icons$2.highwayShoulderMerge,terrainToSingleLine:icons$2.terrainToSingleLine,terrainToTwoLines:icons$2.terrainToTwoLines,urbanRoadMerge:icons$2.urbanRoadMerge,urbanRoadSeparate:icons$2.urbanRoadSeparate,urbanShoulderMerge:icons$2.urbanShoulderMerge,BNGChat:icons$2.BNGChat,chatBubble:icons$2.chatBubble,cameraFarClip:icons$2.cameraFarClip,cameraNearClip:icons$2.cameraNearClip,explosion:icons$2.explosion,fireExtinguisher:icons$2.fireExtinguisher,fire:icons$2.fire,toggleOff:icons$2.toggleOff,toggleOn:icons$2.toggleOn,viewFarClip:icons$2.viewFarClip,viewNearClip:icons$2.viewNearClip,circleSlashed:icons$2.circleSlashed,scissorsSlashed:icons$2.scissorsSlashed,scissors:icons$2.scissors,airPuffRight1:icons$2.airPuffRight1,airPuffUp1:icons$2.airPuffUp1,arrowsReplace:icons$2.arrowsReplace,arrowsShuffle:icons$2.arrowsShuffle,arrowsSwitch:icons$2.arrowsSwitch,carClock:icons$2.carClock,carNumber1:icons$2.carNumber1,carNumber2:icons$2.carNumber2,carNumber3:icons$2.carNumber3,carNumber4:icons$2.carNumber4,carNumber5:icons$2.carNumber5,carNumber6:icons$2.carNumber6,carNumber7:icons$2.carNumber7,carNumber8:icons$2.carNumber8,carNumber9:icons$2.carNumber9,carPlus:icons$2.carPlus,loadMesh:icons$2.loadMesh,octagonBrick:icons$2.octagonBrick,octagon:icons$2.octagon,saveMesh:icons$2.saveMesh,trafficLight:icons$2.trafficLight,enter:icons$2.enter,pedestrianRunning:icons$2.pedestrianRunning,pedestrianStanding:icons$2.pedestrianStanding,seatArrowIn:icons$2.seatArrowIn,seatArrowOut:icons$2.seatArrowOut,seatVArrowIn:icons$2.seatVArrowIn,seatVArrowOut:icons$2.seatVArrowOut,vehicleArrowIn:icons$2.vehicleArrowIn,vehicleArrowOut:icons$2.vehicleArrowOut,leverFrontOperate:icons$2.leverFrontOperate,leverSideDown:icons$2.leverSideDown,leverSideOperate:icons$2.leverSideOperate,leverSideUp:icons$2.leverSideUp,medalEmpty:icons$2.medalEmpty,medalStar:icons$2.medalStar,seatArrowInLeft:icons$2.seatArrowInLeft,seatArrowOutLeft:icons$2.seatArrowOutLeft,seatVArrowInLeft:icons$2.seatVArrowInLeft,seatVArrowOutLeft:icons$2.seatVArrowOutLeft,badgeRoundEmpty:icons$2.badgeRoundEmpty,badgeRoundStar:icons$2.badgeRoundStar,badgeRound:icons$2.badgeRound,badge:icons$2.badge,beamCurrencyOutlineLarge:icons$2.beamCurrencyOutlineLarge,carSideOutlineLarge:icons$2.carSideOutlineLarge,flagOutlineLarge:icons$2.flagOutlineLarge,terrainOutlineLarge:icons$2.terrainOutlineLarge,rallyHelmet3To4:icons$2.rallyHelmet3To4,rallyHelmet:icons$2.rallyHelmet,test:icons$2.test,globeSimpleNotSign:icons$2.globeSimpleNotSign,globeSimplified:icons$2.globeSimplified,radialMenu:icons$2.radialMenu,branch:icons$2.branch,NA:icons$2.NA,magicWand:icons$2.magicWand,dice24:icons$2.dice24,diceD6:icons$2.diceD6,xmarkBold:icons$2.xmarkBold,house:icons$2.house,picture:icons$2.picture,shieldCheckmarkProgressbar:icons$2.shieldCheckmarkProgressbar},warning:{ABSIndicator:icons$2.ABSIndicator,DCBattery:icons$2.DCBattery,oilPressureIndicator:icons$2.oilPressureIndicator,parkingIndicator:icons$2.parkingIndicator},internals:{ABSIndicator:icons$2.ABSIndicator,DCBattery:icons$2.DCBattery,oilPressureIndicator:icons$2.oilPressureIndicator,parkingIndicator:icons$2.parkingIndicator},we:{addItemPolygon:icons$2.addItemPolygon,addListItem:icons$2.addListItem,addPolygonVertex:icons$2.addPolygonVertex,bSpline:icons$2.bSpline,beamCrashBarrier1:icons$2.beamCrashBarrier1,beamCrashBarrier2:icons$2.beamCrashBarrier2,beamCrashBarrier3:icons$2.beamCrashBarrier3,bezierPath1:icons$2.bezierPath1,bezierPath2:icons$2.bezierPath2,bicycle1:icons$2.bicycle1,bicycle2:icons$2.bicycle2,bollard:icons$2.bollard,bulldozer:icons$2.bulldozer,concreteRoadBlock:icons$2.concreteRoadBlock,crossroads1:icons$2.crossroads1,crossroads2:icons$2.crossroads2,decalRoad:icons$2.decalRoad,flatBulbBeam:icons$2.flatBulbBeam,frontAxleMidpoint:icons$2.frontAxleMidpoint,frontBumperMidpoint:icons$2.frontBumperMidpoint,lampPost1:icons$2.lampPost1,lampPost2:icons$2.lampPost2,lampPost3:icons$2.lampPost3,laneProperties:icons$2.laneProperties,lidarPatternFullArcHighFreq:icons$2.lidarPatternFullArcHighFreq,lidarPatternFullArcMidFreq:icons$2.lidarPatternFullArcMidFreq,lidarPatternNarrowArc:icons$2.lidarPatternNarrowArc,lineToTerrain:icons$2.lineToTerrain,longRangeBeam1:icons$2.longRangeBeam1,longRangeBeam2:icons$2.longRangeBeam2,magnetOnSurface:icons$2.magnetOnSurface,meshFence:icons$2.meshFence,meshRoad:icons$2.meshRoad,midRangeBeam1:icons$2.midRangeBeam1,midRangeBeam2:icons$2.midRangeBeam2,pathArc:icons$2.pathArc,pathLine:icons$2.pathLine,pathSpiral:icons$2.pathSpiral,rearAxleMidpoint:icons$2.rearAxleMidpoint,rearBumperMidpoint:icons$2.rearBumperMidpoint,roadDividerLinesDecal:icons$2.roadDividerLinesDecal,roadEdgeLineDecal:icons$2.roadEdgeLineDecal,roadEndLineDecal:icons$2.roadEndLineDecal,roadFace:icons$2.roadFace,roadMarkingOutline:icons$2.roadMarkingOutline,roadMarkingSolid:icons$2.roadMarkingSolid,roadOutline:icons$2.roadOutline,roadRefPathDecal:icons$2.roadRefPathDecal,roadRefPath:icons$2.roadRefPath,roadStartLineDecal:icons$2.roadStartLineDecal,shortRangeBeam1:icons$2.shortRangeBeam1,shortRangeBeam2:icons$2.shortRangeBeam2,sphereOnPathNumber:icons$2.sphereOnPathNumber,sphereOnPath:icons$2.sphereOnPath,sphericalBeam:icons$2.sphericalBeam,terrainToLine:icons$2.terrainToLine,thinBulbBeam:icons$2.thinBulbBeam,thinnerBulbBeam:icons$2.thinnerBulbBeam,toCOMWithWheels:icons$2.toCOMWithWheels,toCOM:icons$2.toCOM,triangleBeam:icons$2.triangleBeam,tulipBeam:icons$2.tulipBeam,tunnel:icons$2.tunnel,twoRoadsAdd:icons$2.twoRoadsAdd,twoRoadsCrossAdd:icons$2.twoRoadsCrossAdd,twoRoadsLink:icons$2.twoRoadsLink,lasso:icons$2.lasso,removeItemPolygon:icons$2.removeItemPolygon,removeListItem:icons$2.removeListItem,bridgeWithRiver:icons$2.bridgeWithRiver,gizmosOutline:icons$2.gizmosOutline,gizmosSolid:icons$2.gizmosSolid,highwayRoad3To2Merge01:icons$2.highwayRoad3To2Merge01,highwayRoad3To2Merge02:icons$2.highwayRoad3To2Merge02,highwayToUrbanRoadTransition01:icons$2.highwayToUrbanRoadTransition01,highwayToUrbanRoadTransition02:icons$2.highwayToUrbanRoadTransition02,pedestrianCrossing01:icons$2.pedestrianCrossing01,polygonalCube:icons$2.polygonalCube,roadEditOutline:icons$2.roadEditOutline,roadEditSolid:icons$2.roadEditSolid,roadFolderPlus:icons$2.roadFolderPlus,roadFolder:icons$2.roadFolder,roadGuideArrowOutline:icons$2.roadGuideArrowOutline,roadGuideArrowSolid:icons$2.roadGuideArrowSolid,roadOutlineMesh:icons$2.roadOutlineMesh,roadPedestrianCrossing02:icons$2.roadPedestrianCrossing02,roadProfileWithCheckmark:icons$2.roadProfileWithCheckmark,roadProfile:icons$2.roadProfile,roadRoundaboutJunction:icons$2.roadRoundaboutJunction,roadSidewalkTransition:icons$2.roadSidewalkTransition,roadStackPlus:icons$2.roadStackPlus,roadStack:icons$2.roadStack,roadTJunction:icons$2.roadTJunction,roadXJunction:icons$2.roadXJunction,roadYJunction:icons$2.roadYJunction,singleLineToTerrain:icons$2.singleLineToTerrain,sphereOnMesh:icons$2.sphereOnMesh,twoLinesToTerrain:icons$2.twoLinesToTerrain,urbanRoad3To2Merge01:icons$2.urbanRoad3To2Merge01,urbanRoad3To2Merge02:icons$2.urbanRoad3To2Merge02,urbanRoadToHighwayTransition01:icons$2.urbanRoadToHighwayTransition01,urbanRoadToHighwayTransition02:icons$2.urbanRoadToHighwayTransition02,highwayMerge:icons$2.highwayMerge,highwaySeparate:icons$2.highwaySeparate,highwayShoulderMerge:icons$2.highwayShoulderMerge,terrainToSingleLine:icons$2.terrainToSingleLine,terrainToTwoLines:icons$2.terrainToTwoLines,urbanRoadMerge:icons$2.urbanRoadMerge,urbanRoadSeparate:icons$2.urbanRoadSeparate,urbanShoulderMerge:icons$2.urbanShoulderMerge},"world editor":{addItemPolygon:icons$2.addItemPolygon,addListItem:icons$2.addListItem,addPolygonVertex:icons$2.addPolygonVertex,bSpline:icons$2.bSpline,beamCrashBarrier1:icons$2.beamCrashBarrier1,beamCrashBarrier2:icons$2.beamCrashBarrier2,beamCrashBarrier3:icons$2.beamCrashBarrier3,bezierPath1:icons$2.bezierPath1,bezierPath2:icons$2.bezierPath2,bicycle1:icons$2.bicycle1,bicycle2:icons$2.bicycle2,bollard:icons$2.bollard,bulldozer:icons$2.bulldozer,concreteRoadBlock:icons$2.concreteRoadBlock,crossroads1:icons$2.crossroads1,crossroads2:icons$2.crossroads2,decalRoad:icons$2.decalRoad,flatBulbBeam:icons$2.flatBulbBeam,frontAxleMidpoint:icons$2.frontAxleMidpoint,frontBumperMidpoint:icons$2.frontBumperMidpoint,lampPost1:icons$2.lampPost1,lampPost2:icons$2.lampPost2,lampPost3:icons$2.lampPost3,laneProperties:icons$2.laneProperties,lidarPatternFullArcHighFreq:icons$2.lidarPatternFullArcHighFreq,lidarPatternFullArcMidFreq:icons$2.lidarPatternFullArcMidFreq,lidarPatternNarrowArc:icons$2.lidarPatternNarrowArc,lineToTerrain:icons$2.lineToTerrain,longRangeBeam1:icons$2.longRangeBeam1,longRangeBeam2:icons$2.longRangeBeam2,magnetOnSurface:icons$2.magnetOnSurface,meshFence:icons$2.meshFence,meshRoad:icons$2.meshRoad,midRangeBeam1:icons$2.midRangeBeam1,midRangeBeam2:icons$2.midRangeBeam2,pathArc:icons$2.pathArc,pathLine:icons$2.pathLine,pathSpiral:icons$2.pathSpiral,rearAxleMidpoint:icons$2.rearAxleMidpoint,rearBumperMidpoint:icons$2.rearBumperMidpoint,roadDividerLinesDecal:icons$2.roadDividerLinesDecal,roadEdgeLineDecal:icons$2.roadEdgeLineDecal,roadEndLineDecal:icons$2.roadEndLineDecal,roadFace:icons$2.roadFace,roadMarkingOutline:icons$2.roadMarkingOutline,roadMarkingSolid:icons$2.roadMarkingSolid,roadOutline:icons$2.roadOutline,roadRefPathDecal:icons$2.roadRefPathDecal,roadRefPath:icons$2.roadRefPath,roadStartLineDecal:icons$2.roadStartLineDecal,shortRangeBeam1:icons$2.shortRangeBeam1,shortRangeBeam2:icons$2.shortRangeBeam2,sphereOnPathNumber:icons$2.sphereOnPathNumber,sphereOnPath:icons$2.sphereOnPath,sphericalBeam:icons$2.sphericalBeam,terrainToLine:icons$2.terrainToLine,thinBulbBeam:icons$2.thinBulbBeam,thinnerBulbBeam:icons$2.thinnerBulbBeam,toCOMWithWheels:icons$2.toCOMWithWheels,toCOM:icons$2.toCOM,triangleBeam:icons$2.triangleBeam,tulipBeam:icons$2.tulipBeam,tunnel:icons$2.tunnel,twoRoadsAdd:icons$2.twoRoadsAdd,twoRoadsCrossAdd:icons$2.twoRoadsCrossAdd,twoRoadsLink:icons$2.twoRoadsLink,lasso:icons$2.lasso,removeItemPolygon:icons$2.removeItemPolygon,removeListItem:icons$2.removeListItem,bridgeWithRiver:icons$2.bridgeWithRiver,gizmosOutline:icons$2.gizmosOutline,gizmosSolid:icons$2.gizmosSolid,highwayRoad3To2Merge01:icons$2.highwayRoad3To2Merge01,highwayRoad3To2Merge02:icons$2.highwayRoad3To2Merge02,highwayToUrbanRoadTransition01:icons$2.highwayToUrbanRoadTransition01,highwayToUrbanRoadTransition02:icons$2.highwayToUrbanRoadTransition02,pedestrianCrossing01:icons$2.pedestrianCrossing01,polygonalCube:icons$2.polygonalCube,roadEditOutline:icons$2.roadEditOutline,roadEditSolid:icons$2.roadEditSolid,roadFolderPlus:icons$2.roadFolderPlus,roadFolder:icons$2.roadFolder,roadGuideArrowOutline:icons$2.roadGuideArrowOutline,roadGuideArrowSolid:icons$2.roadGuideArrowSolid,roadOutlineMesh:icons$2.roadOutlineMesh,roadPedestrianCrossing02:icons$2.roadPedestrianCrossing02,roadProfileWithCheckmark:icons$2.roadProfileWithCheckmark,roadProfile:icons$2.roadProfile,roadRoundaboutJunction:icons$2.roadRoundaboutJunction,roadSidewalkTransition:icons$2.roadSidewalkTransition,roadStackPlus:icons$2.roadStackPlus,roadStack:icons$2.roadStack,roadTJunction:icons$2.roadTJunction,roadXJunction:icons$2.roadXJunction,roadYJunction:icons$2.roadYJunction,singleLineToTerrain:icons$2.singleLineToTerrain,sphereOnMesh:icons$2.sphereOnMesh,twoLinesToTerrain:icons$2.twoLinesToTerrain,urbanRoad3To2Merge01:icons$2.urbanRoad3To2Merge01,urbanRoad3To2Merge02:icons$2.urbanRoad3To2Merge02,urbanRoadToHighwayTransition01:icons$2.urbanRoadToHighwayTransition01,urbanRoadToHighwayTransition02:icons$2.urbanRoadToHighwayTransition02,highwayMerge:icons$2.highwayMerge,highwaySeparate:icons$2.highwaySeparate,highwayShoulderMerge:icons$2.highwayShoulderMerge,terrainToSingleLine:icons$2.terrainToSingleLine,terrainToTwoLines:icons$2.terrainToTwoLines,urbanRoadMerge:icons$2.urbanRoadMerge,urbanRoadSeparate:icons$2.urbanRoadSeparate,urbanShoulderMerge:icons$2.urbanShoulderMerge},"road tools":{addItemPolygon:icons$2.addItemPolygon,addListItem:icons$2.addListItem,addPolygonVertex:icons$2.addPolygonVertex,bSpline:icons$2.bSpline,beamCrashBarrier1:icons$2.beamCrashBarrier1,beamCrashBarrier2:icons$2.beamCrashBarrier2,beamCrashBarrier3:icons$2.beamCrashBarrier3,bezierPath1:icons$2.bezierPath1,bezierPath2:icons$2.bezierPath2,bicycle1:icons$2.bicycle1,bicycle2:icons$2.bicycle2,bollard:icons$2.bollard,bulldozer:icons$2.bulldozer,concreteRoadBlock:icons$2.concreteRoadBlock,crossroads1:icons$2.crossroads1,crossroads2:icons$2.crossroads2,decalRoad:icons$2.decalRoad,lampPost1:icons$2.lampPost1,lampPost2:icons$2.lampPost2,lampPost3:icons$2.lampPost3,laneProperties:icons$2.laneProperties,lineToTerrain:icons$2.lineToTerrain,magnetOnSurface:icons$2.magnetOnSurface,meshFence:icons$2.meshFence,meshRoad:icons$2.meshRoad,pathArc:icons$2.pathArc,pathLine:icons$2.pathLine,pathSpiral:icons$2.pathSpiral,roadDividerLinesDecal:icons$2.roadDividerLinesDecal,roadEdgeLineDecal:icons$2.roadEdgeLineDecal,roadEndLineDecal:icons$2.roadEndLineDecal,roadFace:icons$2.roadFace,roadMarkingSolid:icons$2.roadMarkingSolid,roadOutline:icons$2.roadOutline,roadRefPathDecal:icons$2.roadRefPathDecal,roadRefPath:icons$2.roadRefPath,roadStartLineDecal:icons$2.roadStartLineDecal,sphereOnPathNumber:icons$2.sphereOnPathNumber,sphereOnPath:icons$2.sphereOnPath,terrainToLine:icons$2.terrainToLine,tunnel:icons$2.tunnel,twoRoadsAdd:icons$2.twoRoadsAdd,twoRoadsCrossAdd:icons$2.twoRoadsCrossAdd,twoRoadsLink:icons$2.twoRoadsLink,removeItemPolygon:icons$2.removeItemPolygon,removeListItem:icons$2.removeListItem,bridgeWithRiver:icons$2.bridgeWithRiver,gizmosOutline:icons$2.gizmosOutline,gizmosSolid:icons$2.gizmosSolid,highwayRoad3To2Merge01:icons$2.highwayRoad3To2Merge01,highwayRoad3To2Merge02:icons$2.highwayRoad3To2Merge02,highwayToUrbanRoadTransition01:icons$2.highwayToUrbanRoadTransition01,highwayToUrbanRoadTransition02:icons$2.highwayToUrbanRoadTransition02,pedestrianCrossing01:icons$2.pedestrianCrossing01,polygonalCube:icons$2.polygonalCube,roadEditOutline:icons$2.roadEditOutline,roadEditSolid:icons$2.roadEditSolid,roadFolderPlus:icons$2.roadFolderPlus,roadFolder:icons$2.roadFolder,roadGuideArrowOutline:icons$2.roadGuideArrowOutline,roadGuideArrowSolid:icons$2.roadGuideArrowSolid,roadOutlineMesh:icons$2.roadOutlineMesh,roadPedestrianCrossing02:icons$2.roadPedestrianCrossing02,roadProfileWithCheckmark:icons$2.roadProfileWithCheckmark,roadProfile:icons$2.roadProfile,roadRoundaboutJunction:icons$2.roadRoundaboutJunction,roadSidewalkTransition:icons$2.roadSidewalkTransition,roadStackPlus:icons$2.roadStackPlus,roadStack:icons$2.roadStack,roadTJunction:icons$2.roadTJunction,roadXJunction:icons$2.roadXJunction,roadYJunction:icons$2.roadYJunction,singleLineToTerrain:icons$2.singleLineToTerrain,sphereOnMesh:icons$2.sphereOnMesh,twoLinesToTerrain:icons$2.twoLinesToTerrain,urbanRoad3To2Merge01:icons$2.urbanRoad3To2Merge01,urbanRoad3To2Merge02:icons$2.urbanRoad3To2Merge02,urbanRoadToHighwayTransition01:icons$2.urbanRoadToHighwayTransition01,urbanRoadToHighwayTransition02:icons$2.urbanRoadToHighwayTransition02,highwayMerge:icons$2.highwayMerge,highwaySeparate:icons$2.highwaySeparate,highwayShoulderMerge:icons$2.highwayShoulderMerge,terrainToSingleLine:icons$2.terrainToSingleLine,terrainToTwoLines:icons$2.terrainToTwoLines,urbanRoadMerge:icons$2.urbanRoadMerge,urbanRoadSeparate:icons$2.urbanRoadSeparate,urbanShoulderMerge:icons$2.urbanShoulderMerge},ai:{AIMicrochip:icons$2.AIMicrochip},microchip:{AIMicrochip:icons$2.AIMicrochip},poi:{AIRace:icons$2.AIRace,barrelKnocker01:icons$2.barrelKnocker01,barrelKnocker02:icons$2.barrelKnocker02,boxDropOff01:icons$2.boxDropOff01,boxDropOff02:icons$2.boxDropOff02,boxDropOff03:icons$2.boxDropOff03,boxPickUp01:icons$2.boxPickUp01,boxPickUp02:icons$2.boxPickUp02,boxPickUp03:icons$2.boxPickUp03,boxPickUpDropOff01:icons$2.boxPickUpDropOff01,boxPickUpDropOff02:icons$2.boxPickUpDropOff02,bus:icons$2.bus,cannon:icons$2.cannon,circuit:icons$2.circuit,deliveryTruckArrows:icons$2.deliveryTruckArrows,deliveryTruck:icons$2.deliveryTruck,drag01:icons$2.drag01,drag02:icons$2.drag02,drift01:icons$2.drift01,drift02:icons$2.drift02,evade:icons$2.evade,fastTravel:icons$2.fastTravel,flagNew:icons$2.flagNew,flag:icons$2.flag,gaugeEmpty:icons$2.gaugeEmpty,hypermiling:icons$2.hypermiling,jump:icons$2.jump,parking:icons$2.parking,raceFlag:icons$2.raceFlag,rockCrawling01:icons$2.rockCrawling01,rockCrawling02:icons$2.rockCrawling02,targetJump:icons$2.targetJump,toGarage:icons$2.toGarage,trashBin1:icons$2.trashBin1,circlePinBack:icons$2.circlePinBack,circlePinFront:icons$2.circlePinFront,markerRectanglePinBack:icons$2.markerRectanglePinBack,markerRectanglePinFront:icons$2.markerRectanglePinFront,markerTriangleBack:icons$2.markerTriangleBack,markerTriangleFront:icons$2.markerTriangleFront,busTilted:icons$2.busTilted,gaugeFull:icons$2.gaugeFull},camera:{aperture:icons$2.aperture,camera3Fourth1:icons$2.camera3Fourth1,cameraBack1:icons$2.cameraBack1,cameraFocusOnPath:icons$2.cameraFocusOnPath,cameraFocusOnVehicle1:icons$2.cameraFocusOnVehicle1,cameraFocusOnVehicle2:icons$2.cameraFocusOnVehicle2,cameraFocusTopDown:icons$2.cameraFocusTopDown,cameraFront1:icons$2.cameraFront1,cameraSideLeft:icons$2.cameraSideLeft,cameraSideLeft2:icons$2.cameraSideLeft2,cameraSideRight:icons$2.cameraSideRight,cameraSideRight2:icons$2.cameraSideRight2,cameraTop1:icons$2.cameraTop1,movieCamera:icons$2.movieCamera,pathAroundObstacle:icons$2.pathAroundObstacle,survellianceCamera:icons$2.survellianceCamera,pathDice:icons$2.pathDice},optical:{aperture:icons$2.aperture,survellianceCamera:icons$2.survellianceCamera},sensor:{aperture:icons$2.aperture,eyeWaves:icons$2.eyeWaves,flatBulbBeam:icons$2.flatBulbBeam,frontAxleMidpoint:icons$2.frontAxleMidpoint,frontBumperMidpoint:icons$2.frontBumperMidpoint,GPSMark:icons$2.GPSMark,GPSSolid:icons$2.GPSSolid,gyroscopeMicrochip:icons$2.gyroscopeMicrochip,gyroscope:icons$2.gyroscope,lidarPatternFullArcHighFreq:icons$2.lidarPatternFullArcHighFreq,lidarPatternFullArcMidFreq:icons$2.lidarPatternFullArcMidFreq,lidarPatternNarrowArc:icons$2.lidarPatternNarrowArc,lidar:icons$2.lidar,location1:icons$2.location1,location2:icons$2.location2,longRangeBeam1:icons$2.longRangeBeam1,longRangeBeam2:icons$2.longRangeBeam2,midRangeBeam1:icons$2.midRangeBeam1,midRangeBeam2:icons$2.midRangeBeam2,radarIdeal:icons$2.radarIdeal,radarRoundIdeal:icons$2.radarRoundIdeal,radarRound:icons$2.radarRound,radar:icons$2.radar,rearAxleMidpoint:icons$2.rearAxleMidpoint,rearBumperMidpoint:icons$2.rearBumperMidpoint,shortRangeBeam1:icons$2.shortRangeBeam1,shortRangeBeam2:icons$2.shortRangeBeam2,sphericalBeam:icons$2.sphericalBeam,survellianceCamera:icons$2.survellianceCamera,thinBulbBeam:icons$2.thinBulbBeam,thinnerBulbBeam:icons$2.thinnerBulbBeam,toCOMWithWheels:icons$2.toCOMWithWheels,toCOM:icons$2.toCOM,triangleBeam:icons$2.triangleBeam,tulipBeam:icons$2.tulipBeam,wavesSignalReceived:icons$2.wavesSignalReceived,wavesSignalSentLeft:icons$2.wavesSignalSentLeft,wavesSignalSentRight:icons$2.wavesSignalSentRight},arrow:{arrowLargeDown:icons$2.arrowLargeDown,arrowLargeLeft:icons$2.arrowLargeLeft,arrowLargeRight:icons$2.arrowLargeRight,arrowLargeUp:icons$2.arrowLargeUp,arrowSmallDown:icons$2.arrowSmallDown,arrowSmallLeft:icons$2.arrowSmallLeft,arrowSmallRight:icons$2.arrowSmallRight,arrowSmallUp:icons$2.arrowSmallUp,arrowSolidLeft:icons$2.arrowSolidLeft,arrowSolidRight:icons$2.arrowSolidRight,twoArrowsHorizontal:icons$2.twoArrowsHorizontal,twoArrowsVertical:icons$2.twoArrowsVertical,arrowsReplace:icons$2.arrowsReplace,arrowsShuffle:icons$2.arrowsShuffle,arrowsSwitch:icons$2.arrowsSwitch,seatArrowIn:icons$2.seatArrowIn,seatArrowOut:icons$2.seatArrowOut,seatVArrowIn:icons$2.seatVArrowIn,seatVArrowOut:icons$2.seatVArrowOut,vehicleArrowIn:icons$2.vehicleArrowIn,vehicleArrowOut:icons$2.vehicleArrowOut,seatArrowInLeft:icons$2.seatArrowInLeft,seatArrowOutLeft:icons$2.seatArrowOutLeft,seatVArrowInLeft:icons$2.seatVArrowInLeft,seatVArrowOutLeft:icons$2.seatVArrowOutLeft},large:{arrowLargeDown:icons$2.arrowLargeDown,arrowLargeLeft:icons$2.arrowLargeLeft,arrowLargeRight:icons$2.arrowLargeRight,arrowLargeUp:icons$2.arrowLargeUp,arrowSolidLeft:icons$2.arrowSolidLeft,arrowSolidRight:icons$2.arrowSolidRight,arrowLeftOutline:icons$2.arrowLeftOutline,arrowRightOutline:icons$2.arrowRightOutline,beamsNodesMessageOutline:icons$2.beamsNodesMessageOutline,beamsNodesOutline:icons$2.beamsNodesOutline,beamsNodesPlugOutline:icons$2.beamsNodesPlugOutline,BNGEcosystemOutline:icons$2.BNGEcosystemOutline,carFrontRouteOutline:icons$2.carFrontRouteOutline,carSensorsOutline:icons$2.carSensorsOutline,carSideRouteOutline:icons$2.carSideRouteOutline,cityOutline:icons$2.cityOutline,dialogOutline:icons$2.dialogOutline,documentSmileOutline:icons$2.documentSmileOutline,drivetrainOutline:icons$2.drivetrainOutline,electronicSchemeOutline:icons$2.electronicSchemeOutline,engineOutline:icons$2.engineOutline,gearTuningOutline:icons$2.gearTuningOutline,giftBoxOutline:icons$2.giftBoxOutline,lidarOutline:icons$2.lidarOutline,medalStarOutline:icons$2.medalStarOutline,megaphoneOutline:icons$2.megaphoneOutline,peopleOutline:icons$2.peopleOutline,personOutline:icons$2.personOutline,physicsOutline:icons$2.physicsOutline,playChainOutline:icons$2.playChainOutline,proximitySensorsOutline:icons$2.proximitySensorsOutline,qualityBadgeStarOutline:icons$2.qualityBadgeStarOutline,qualityBadgeVOutline:icons$2.qualityBadgeVOutline,simRigOutline:icons$2.simRigOutline,suspensionOutline:icons$2.suspensionOutline,teamOutline:icons$2.teamOutline,techLightBulbOutline01:icons$2.techLightBulbOutline01,techLightBulbOutline02:icons$2.techLightBulbOutline02,timeUnlockOutline:icons$2.timeUnlockOutline,timedLockOutline:icons$2.timedLockOutline,trafficOutline:icons$2.trafficOutline,voucherOutline:icons$2.voucherOutline,wheelBeamsNodesOutline:icons$2.wheelBeamsNodesOutline,wheelOutline:icons$2.wheelOutline,twoArrowsHorizontal:icons$2.twoArrowsHorizontal,twoArrowsVertical:icons$2.twoArrowsVertical},simple:{arrowLargeDown:icons$2.arrowLargeDown,arrowLargeLeft:icons$2.arrowLargeLeft,arrowLargeRight:icons$2.arrowLargeRight,arrowLargeUp:icons$2.arrowLargeUp,arrowSmallDown:icons$2.arrowSmallDown,arrowSmallLeft:icons$2.arrowSmallLeft,arrowSmallRight:icons$2.arrowSmallRight,arrowSmallUp:icons$2.arrowSmallUp},outlined:{arrowLargeDown:icons$2.arrowLargeDown,arrowLargeLeft:icons$2.arrowLargeLeft,arrowLargeRight:icons$2.arrowLargeRight,arrowLargeUp:icons$2.arrowLargeUp,arrowSmallDown:icons$2.arrowSmallDown,arrowSmallLeft:icons$2.arrowSmallLeft,arrowSmallRight:icons$2.arrowSmallRight,arrowSmallUp:icons$2.arrowSmallUp,roadMarkingOutline:icons$2.roadMarkingOutline,arrowLeftOutline:icons$2.arrowLeftOutline,arrowRightOutline:icons$2.arrowRightOutline,beamsNodesMessageOutline:icons$2.beamsNodesMessageOutline,beamsNodesOutline:icons$2.beamsNodesOutline,beamsNodesPlugOutline:icons$2.beamsNodesPlugOutline,BNGEcosystemOutline:icons$2.BNGEcosystemOutline,carFrontRouteOutline:icons$2.carFrontRouteOutline,carSensorsOutline:icons$2.carSensorsOutline,carSideRouteOutline:icons$2.carSideRouteOutline,cityOutline:icons$2.cityOutline,dialogOutline:icons$2.dialogOutline,documentSmileOutline:icons$2.documentSmileOutline,drivetrainOutline:icons$2.drivetrainOutline,electronicSchemeOutline:icons$2.electronicSchemeOutline,engineOutline:icons$2.engineOutline,gearTuningOutline:icons$2.gearTuningOutline,giftBoxOutline:icons$2.giftBoxOutline,lidarOutline:icons$2.lidarOutline,medalStarOutline:icons$2.medalStarOutline,megaphoneOutline:icons$2.megaphoneOutline,peopleOutline:icons$2.peopleOutline,personOutline:icons$2.personOutline,physicsOutline:icons$2.physicsOutline,playChainOutline:icons$2.playChainOutline,proximitySensorsOutline:icons$2.proximitySensorsOutline,qualityBadgeStarOutline:icons$2.qualityBadgeStarOutline,qualityBadgeVOutline:icons$2.qualityBadgeVOutline,simRigOutline:icons$2.simRigOutline,suspensionOutline:icons$2.suspensionOutline,teamOutline:icons$2.teamOutline,techLightBulbOutline01:icons$2.techLightBulbOutline01,techLightBulbOutline02:icons$2.techLightBulbOutline02,timeUnlockOutline:icons$2.timeUnlockOutline,timedLockOutline:icons$2.timedLockOutline,trafficOutline:icons$2.trafficOutline,voucherOutline:icons$2.voucherOutline,wheelBeamsNodesOutline:icons$2.wheelBeamsNodesOutline,wheelOutline:icons$2.wheelOutline},small:{arrowSmallDown:icons$2.arrowSmallDown,arrowSmallLeft:icons$2.arrowSmallLeft,arrowSmallRight:icons$2.arrowSmallRight,arrowSmallUp:icons$2.arrowSmallUp,mathDivide:icons$2.mathDivide,mathGreaterOrEqualThan:icons$2.mathGreaterOrEqualThan,mathGreaterThan:icons$2.mathGreaterThan,mathLessOrEqualThan:icons$2.mathLessOrEqualThan,mathLessThan:icons$2.mathLessThan,mathMinus:icons$2.mathMinus,mathMultiply:icons$2.mathMultiply,mathPlus:icons$2.mathPlus,slashLeft:icons$2.slashLeft,slashRight:icons$2.slashRight},solid:{arrowSolidLeft:icons$2.arrowSolidLeft,arrowSolidRight:icons$2.arrowSolidRight,twoArrowsHorizontal:icons$2.twoArrowsHorizontal,twoArrowsVertical:icons$2.twoArrowsVertical},detailed:{arrowSolidLeft:icons$2.arrowSolidLeft,arrowSolidRight:icons$2.arrowSolidRight},career:{banknotes:icons$2.banknotes,beamCurrency:icons$2.beamCurrency,beamXPFull:icons$2.beamXPFull,beamXPLo:icons$2.beamXPLo,carDealer:icons$2.carDealer,garage01:icons$2.garage01,garage02:icons$2.garage02,garage03:icons$2.garage03,lightGarageG11:icons$2.lightGarageG11,lightGarageG12:icons$2.lightGarageG12,lightGarageG13:icons$2.lightGarageG13,lightGarageG14:icons$2.lightGarageG14,lightGarageG21:icons$2.lightGarageG21,lightGarageG22:icons$2.lightGarageG22,lightGarageG23:icons$2.lightGarageG23,lightGarageG24:icons$2.lightGarageG24,lightGarageG31:icons$2.lightGarageG31,lightGarageG32:icons$2.lightGarageG32,lightGarageG33:icons$2.lightGarageG33,lightGarageG34:icons$2.lightGarageG34,plusGarage1:icons$2.plusGarage1,plusGarage2:icons$2.plusGarage2,plusGarage3:icons$2.plusGarage3,plusGarage4:icons$2.plusGarage4,voucherDiagonal1:icons$2.voucherDiagonal1,voucherDiagonal2:icons$2.voucherDiagonal2,voucherDiagonal3:icons$2.voucherDiagonal3,voucherHorizontal1:icons$2.voucherHorizontal1,voucherHorizontal2:icons$2.voucherHorizontal2,voucherHorizontal3:icons$2.voucherHorizontal3,garageNumber1:icons$2.garageNumber1,garageNumber2:icons$2.garageNumber2,garageNumber3:icons$2.garageNumber3,garageNumber4:icons$2.garageNumber4,garageNumber5:icons$2.garageNumber5,garageNumber6:icons$2.garageNumber6,garageNumber7:icons$2.garageNumber7,garageNumber8:icons$2.garageNumber8,garageNumber9:icons$2.garageNumber9,houseWrenchRoof:icons$2.houseWrenchRoof,houseWrench:icons$2.houseWrench,house:icons$2.house,beamCurrencyThin:icons$2.beamCurrencyThin},currencies:{banknotes:icons$2.banknotes,beamCurrency:icons$2.beamCurrency,beamXPFull:icons$2.beamXPFull,beamXPLo:icons$2.beamXPLo,beamCurrencyThin:icons$2.beamCurrencyThin},brand:{beamNG:icons$2.beamNG},beamng:{beamNG:icons$2.beamNG},decals:{booleanIntersect:icons$2.booleanIntersect,cameraFocusOnVehicle2:icons$2.cameraFocusOnVehicle2,copy:icons$2.copy,decal:icons$2.decal,deform:icons$2.deform,group:icons$2.group,material:icons$2.material,move:icons$2.move,order:icons$2.order,paperKnife:icons$2.paperKnife,redo:icons$2.redo,reflectNot:icons$2.reflectNot,reflect:icons$2.reflect,rename:icons$2.rename,sprayCan:icons$2.sprayCan,transform:icons$2.transform,transparencyMask:icons$2.transparencyMask,trashBin2:icons$2.trashBin2,undo:icons$2.undo,ungroup:icons$2.ungroup,view:icons$2.view,weight:icons$2.weight,scale:icons$2.scale,materialGlossy:icons$2.materialGlossy,materialMetal:icons$2.materialMetal,materialRoughness:icons$2.materialRoughness,materialTransparency01:icons$2.materialTransparency01,materialTransparency02:icons$2.materialTransparency02,surfaceRoughness02:icons$2.surfaceRoughness02,cameraFarClip:icons$2.cameraFarClip,cameraNearClip:icons$2.cameraNearClip,viewFarClip:icons$2.viewFarClip,viewNearClip:icons$2.viewNearClip},delivery:{boxDropOff01:icons$2.boxDropOff01,boxDropOff02:icons$2.boxDropOff02,boxDropOff03:icons$2.boxDropOff03,boxPickUp01:icons$2.boxPickUp01,boxPickUp02:icons$2.boxPickUp02,boxPickUp03:icons$2.boxPickUp03,boxPickUpDropOff01:icons$2.boxPickUpDropOff01,boxPickUpDropOff02:icons$2.boxPickUpDropOff02,boxTruck:icons$2.boxTruck,cardboardBox:icons$2.cardboardBox,deliveryTruckArrows:icons$2.deliveryTruckArrows,deliveryTruck:icons$2.deliveryTruck,flatbedTruck:icons$2.flatbedTruck,forklift:icons$2.forklift,fragile:icons$2.fragile,semiTrailer:icons$2.semiTrailer,semiTruckCabover:icons$2.semiTruckCabover,semiTruckUS:icons$2.semiTruckUS,semiTruck:icons$2.semiTruck,smallTrailer:icons$2.smallTrailer,stack3:icons$2.stack3,tankerTrailer:icons$2.tankerTrailer,thisSideUp:icons$2.thisSideUp,twoUnicyclesOnly:icons$2.twoUnicyclesOnly,boxTruckFast:icons$2.boxTruckFast,cardboardBoxCoins:icons$2.cardboardBoxCoins},cargo:{boxTruck:icons$2.boxTruck,flatbedTruck:icons$2.flatbedTruck,forklift:icons$2.forklift,fragile:icons$2.fragile,semiTrailer:icons$2.semiTrailer,semiTruckCabover:icons$2.semiTruckCabover,semiTruckUS:icons$2.semiTruckUS,semiTruck:icons$2.semiTruck,smallTrailer:icons$2.smallTrailer,stack3:icons$2.stack3,tankerTrailer:icons$2.tankerTrailer,thisSideUp:icons$2.thisSideUp,twoUnicyclesOnly:icons$2.twoUnicyclesOnly,boxTruckFast:icons$2.boxTruckFast},sound:{broom:icons$2.broom,soundFadeOut:icons$2.soundFadeOut,soundLimit:icons$2.soundLimit,soundLoud:icons$2.soundLoud,soundMonoL:icons$2.soundMonoL,soundMonoR:icons$2.soundMonoR,soundOff:icons$2.soundOff,soundQuiet:icons$2.soundQuiet,soundStereo:icons$2.soundStereo,soundWave01:icons$2.soundWave01,soundWave02:icons$2.soundWave02,trim:icons$2.trim},police:{carChase01:icons$2.carChase01,carsChase02:icons$2.carsChase02,evade:icons$2.evade,strobeLights:icons$2.strobeLights,wigwags:icons$2.wigwags},garage:{carDealer:icons$2.carDealer,garage01:icons$2.garage01,garage02:icons$2.garage02,garage03:icons$2.garage03,lightGarageG11:icons$2.lightGarageG11,lightGarageG12:icons$2.lightGarageG12,lightGarageG13:icons$2.lightGarageG13,lightGarageG14:icons$2.lightGarageG14,lightGarageG21:icons$2.lightGarageG21,lightGarageG22:icons$2.lightGarageG22,lightGarageG23:icons$2.lightGarageG23,lightGarageG24:icons$2.lightGarageG24,lightGarageG31:icons$2.lightGarageG31,lightGarageG32:icons$2.lightGarageG32,lightGarageG33:icons$2.lightGarageG33,lightGarageG34:icons$2.lightGarageG34,plusGarage1:icons$2.plusGarage1,plusGarage2:icons$2.plusGarage2,plusGarage3:icons$2.plusGarage3,plusGarage4:icons$2.plusGarage4,houseWrenchRoof:icons$2.houseWrenchRoof,houseWrench:icons$2.houseWrench,house:icons$2.house},sensors:{carSensors:icons$2.carSensors,carWithLidar:icons$2.carWithLidar,mapWithEmitter:icons$2.mapWithEmitter},tech:{carWithLidar:icons$2.carWithLidar,mapWithEmitter:icons$2.mapWithEmitter,mesh4Cells:icons$2.mesh4Cells,mesh9Cells:icons$2.mesh9Cells},fuel:{charge:icons$2.charge,charging:icons$2.charging,fuelPumpFilling:icons$2.fuelPumpFilling,fuelPump:icons$2.fuelPump,N2OButton:icons$2.N2OButton,N2OHoriz:icons$2.N2OHoriz,N2OVert:icons$2.N2OVert,discharging:icons$2.discharging},electricity:{charge:icons$2.charge,charging:icons$2.charging,discharging:icons$2.discharging},ev:{charge:icons$2.charge,charging:icons$2.charging,discharging:icons$2.discharging},checkbox:{checkboxOff:icons$2.checkboxOff,checkboxOn:icons$2.checkboxOn,missionCheckboxCross:icons$2.missionCheckboxCross},selection:{checkboxOff:icons$2.checkboxOff,checkboxOn:icons$2.checkboxOn,missionCheckboxCross:icons$2.missionCheckboxCross},box:{checkboxOff:icons$2.checkboxOff,checkboxOn:icons$2.checkboxOn,missionCheckboxCross:icons$2.missionCheckboxCross},movie:{clapperboard:icons$2.clapperboard},scenery:{clapperboard:icons$2.clapperboard},powertrain:{cogsDamaged:icons$2.cogsDamaged},drivetrain:{cogsDamaged:icons$2.cogsDamaged},data:{dataExchange:icons$2.dataExchange,eyeWaves:icons$2.eyeWaves,gyroscopeMicrochip:icons$2.gyroscopeMicrochip,gyroscope:icons$2.gyroscope,lidar:icons$2.lidar,radarIdeal:icons$2.radarIdeal,radarRoundIdeal:icons$2.radarRoundIdeal,radarRound:icons$2.radarRound,radar:icons$2.radar,wavesSignalReceived:icons$2.wavesSignalReceived,wavesSignalSentLeft:icons$2.wavesSignalSentLeft,wavesSignalSentRight:icons$2.wavesSignalSentRight},signal:{dataExchange:icons$2.dataExchange,eyeWaves:icons$2.eyeWaves,gyroscopeMicrochip:icons$2.gyroscopeMicrochip,gyroscope:icons$2.gyroscope,lidar:icons$2.lidar,radarIdeal:icons$2.radarIdeal,radarRoundIdeal:icons$2.radarRoundIdeal,radarRound:icons$2.radarRound,radar:icons$2.radar,wavesSignalReceived:icons$2.wavesSignalReceived,wavesSignalSentLeft:icons$2.wavesSignalSentLeft,wavesSignalSentRight:icons$2.wavesSignalSentRight},environment:{day:icons$2.day,night:icons$2.night,sunRise:icons$2.sunRise,weather:icons$2.weather,sunDown:icons$2.sunDown},part:{engine:icons$2.engine,suspension01:icons$2.suspension01,turbine:icons$2.turbine,doorFrontCoins:icons$2.doorFrontCoins,doorFront:icons$2.doorFront,engineCoins:icons$2.engineCoins,exhaustMufflerCoins:icons$2.exhaustMufflerCoins,exhaustMuffler:icons$2.exhaustMuffler,headlightCoins:icons$2.headlightCoins,headlight:icons$2.headlight,tire3FourthCoins:icons$2.tire3FourthCoins,tire3Fourth:icons$2.tire3Fourth,turbineCoins:icons$2.turbineCoins,wheelDiscCoins:icons$2.wheelDiscCoins,wheelDisc:icons$2.wheelDisc,doorFrontDetached:icons$2.doorFrontDetached,hingeBroken:icons$2.hingeBroken},mission:{evade:icons$2.evade,flagOutlineLarge:icons$2.flagOutlineLarge},playback:{fastBackward:icons$2.fastBackward,fastForward:icons$2.fastForward,music:icons$2.music,nextTrack:icons$2.nextTrack,pauseRound:icons$2.pauseRound,pause:icons$2.pause,playRound:icons$2.playRound,play:icons$2.play,playlist:icons$2.playlist,prevTrack:icons$2.prevTrack,square:icons$2.square,eject:icons$2.eject,playPause:icons$2.playPause},truck:{flatbedTruck:icons$2.flatbedTruck,semiTruckCabover:icons$2.semiTruckCabover,semiTruckUS:icons$2.semiTruckUS,semiTruck:icons$2.semiTruck},stencil:{forklift:icons$2.forklift,fragile:icons$2.fragile,stack3:icons$2.stack3,thisSideUp:icons$2.thisSideUp,twoUnicyclesOnly:icons$2.twoUnicyclesOnly},placement:{frontAxleMidpoint:icons$2.frontAxleMidpoint,frontBumperMidpoint:icons$2.frontBumperMidpoint,rearAxleMidpoint:icons$2.rearAxleMidpoint,rearBumperMidpoint:icons$2.rearBumperMidpoint,toCOMWithWheels:icons$2.toCOMWithWheels,toCOM:icons$2.toCOM},gamepad:{gamepadOld:icons$2.gamepadOld,gamepad:icons$2.gamepad,noNameControllerButton:icons$2.noNameControllerButton,xboxA:icons$2.xboxA,xboxB:icons$2.xboxB,xboxDDefaultOutline:icons$2.xboxDDefaultOutline,xboxDDefaultSolid:icons$2.xboxDDefaultSolid,xboxDDown:icons$2.xboxDDown,xboxDLeft:icons$2.xboxDLeft,xboxDRight:icons$2.xboxDRight,xboxDUp:icons$2.xboxDUp,xboxLB:icons$2.xboxLB,xboxLSButton:icons$2.xboxLSButton,xboxLT:icons$2.xboxLT,xboxMenu:icons$2.xboxMenu,xboxRB:icons$2.xboxRB,xboxRSButton:icons$2.xboxRSButton,xboxRT:icons$2.xboxRT,xboxThumbL:icons$2.xboxThumbL,xboxThumbR:icons$2.xboxThumbR,xboxView:icons$2.xboxView,xboxXAxis:icons$2.xboxXAxis,xboxXRot:icons$2.xboxXRot,xboxX:icons$2.xboxX,xboxYAxis:icons$2.xboxYAxis,xboxYRot:icons$2.xboxYRot,xboxY:icons$2.xboxY,psCircleOutline:icons$2.psCircleOutline,psCircle:icons$2.psCircle,psCreate2:icons$2.psCreate2,psCreate:icons$2.psCreate,psCrossOutline:icons$2.psCrossOutline,psCross:icons$2.psCross,psDDefaultOutline:icons$2.psDDefaultOutline,psDDefaultSolid:icons$2.psDDefaultSolid,psDDown:icons$2.psDDown,psDLeft:icons$2.psDLeft,psDRight:icons$2.psDRight,psDUp:icons$2.psDUp,psL1:icons$2.psL1,psL2:icons$2.psL2,psL3ButtonArrowDown:icons$2.psL3ButtonArrowDown,psL3Button:icons$2.psL3Button,psLSXLeft:icons$2.psLSXLeft,psLSXRight:icons$2.psLSXRight,psLSX:icons$2.psLSX,psLSYDown:icons$2.psLSYDown,psLSYUp:icons$2.psLSYUp,psLSY:icons$2.psLSY,psLS:icons$2.psLS,psMenu2:icons$2.psMenu2,psMenu:icons$2.psMenu,psR1:icons$2.psR1,psR2:icons$2.psR2,psR3ButtonArrowDown:icons$2.psR3ButtonArrowDown,psR3Button:icons$2.psR3Button,psRSXLeft:icons$2.psRSXLeft,psRSXRight:icons$2.psRSXRight,psRSX:icons$2.psRSX,psRSYDown:icons$2.psRSYDown,psRSYUp:icons$2.psRSYUp,psRSY:icons$2.psRSY,psRS:icons$2.psRS,psSquareOutline:icons$2.psSquareOutline,psSquare:icons$2.psSquare,psTrackpadNavigate:icons$2.psTrackpadNavigate,psTrackpadPressCenter:icons$2.psTrackpadPressCenter,psTrackpadPressLeft:icons$2.psTrackpadPressLeft,psTrackpadPressRight:icons$2.psTrackpadPressRight,psTrackpadSwipeDown:icons$2.psTrackpadSwipeDown,psTrackpadSwipeLeft:icons$2.psTrackpadSwipeLeft,psTrackpadSwipeRight:icons$2.psTrackpadSwipeRight,psTrackpadSwipeUp:icons$2.psTrackpadSwipeUp,psTriangleOutline:icons$2.psTriangleOutline,psTriangle:icons$2.psTriangle,xboxAOutline:icons$2.xboxAOutline,xboxBOutline:icons$2.xboxBOutline,xboxLSButtonArrowDown:icons$2.xboxLSButtonArrowDown,xboxRSButtonArrowDown:icons$2.xboxRSButtonArrowDown,xboxXAxisLeft:icons$2.xboxXAxisLeft,xboxXAxisRight:icons$2.xboxXAxisRight,xboxXOutline:icons$2.xboxXOutline,xboxXRotLeft:icons$2.xboxXRotLeft,xboxXRotRight:icons$2.xboxXRotRight,xboxYAxisDown:icons$2.xboxYAxisDown,xboxYAxisUp:icons$2.xboxYAxisUp,xboxYOutline:icons$2.xboxYOutline,xboxYRotDown:icons$2.xboxYRotDown,xboxYRotUp:icons$2.xboxYRotUp,psDLeftRight:icons$2.psDLeftRight,psDUpDown:icons$2.psDUpDown,xboxDLeftRight:icons$2.xboxDLeftRight,xboxDUpDown:icons$2.xboxDUpDown},controller:{gamepadOld:icons$2.gamepadOld,gamepad:icons$2.gamepad,noNameControllerButton:icons$2.noNameControllerButton,steeringWheelCommon:icons$2.steeringWheelCommon,steeringWheelSporty:icons$2.steeringWheelSporty,xboxA:icons$2.xboxA,xboxB:icons$2.xboxB,xboxDDefaultOutline:icons$2.xboxDDefaultOutline,xboxDDefaultSolid:icons$2.xboxDDefaultSolid,xboxDDown:icons$2.xboxDDown,xboxDLeft:icons$2.xboxDLeft,xboxDRight:icons$2.xboxDRight,xboxDUp:icons$2.xboxDUp,xboxLB:icons$2.xboxLB,xboxLSButton:icons$2.xboxLSButton,xboxLT:icons$2.xboxLT,xboxMenu:icons$2.xboxMenu,xboxRB:icons$2.xboxRB,xboxRSButton:icons$2.xboxRSButton,xboxRT:icons$2.xboxRT,xboxThumbL:icons$2.xboxThumbL,xboxThumbR:icons$2.xboxThumbR,xboxView:icons$2.xboxView,xboxXAxis:icons$2.xboxXAxis,xboxXRot:icons$2.xboxXRot,xboxX:icons$2.xboxX,xboxYAxis:icons$2.xboxYAxis,xboxYRot:icons$2.xboxYRot,xboxY:icons$2.xboxY,psCircleOutline:icons$2.psCircleOutline,psCircle:icons$2.psCircle,psCreate2:icons$2.psCreate2,psCreate:icons$2.psCreate,psCrossOutline:icons$2.psCrossOutline,psCross:icons$2.psCross,psDDefaultOutline:icons$2.psDDefaultOutline,psDDefaultSolid:icons$2.psDDefaultSolid,psDDown:icons$2.psDDown,psDLeft:icons$2.psDLeft,psDRight:icons$2.psDRight,psDUp:icons$2.psDUp,psL1:icons$2.psL1,psL2:icons$2.psL2,psL3ButtonArrowDown:icons$2.psL3ButtonArrowDown,psL3Button:icons$2.psL3Button,psLSXLeft:icons$2.psLSXLeft,psLSXRight:icons$2.psLSXRight,psLSX:icons$2.psLSX,psLSYDown:icons$2.psLSYDown,psLSYUp:icons$2.psLSYUp,psLSY:icons$2.psLSY,psLS:icons$2.psLS,psMenu2:icons$2.psMenu2,psMenu:icons$2.psMenu,psR1:icons$2.psR1,psR2:icons$2.psR2,psR3ButtonArrowDown:icons$2.psR3ButtonArrowDown,psR3Button:icons$2.psR3Button,psRSXLeft:icons$2.psRSXLeft,psRSXRight:icons$2.psRSXRight,psRSX:icons$2.psRSX,psRSYDown:icons$2.psRSYDown,psRSYUp:icons$2.psRSYUp,psRSY:icons$2.psRSY,psRS:icons$2.psRS,psSquareOutline:icons$2.psSquareOutline,psSquare:icons$2.psSquare,psTrackpadNavigate:icons$2.psTrackpadNavigate,psTrackpadPressCenter:icons$2.psTrackpadPressCenter,psTrackpadPressLeft:icons$2.psTrackpadPressLeft,psTrackpadPressRight:icons$2.psTrackpadPressRight,psTrackpadSwipeDown:icons$2.psTrackpadSwipeDown,psTrackpadSwipeLeft:icons$2.psTrackpadSwipeLeft,psTrackpadSwipeRight:icons$2.psTrackpadSwipeRight,psTrackpadSwipeUp:icons$2.psTrackpadSwipeUp,psTriangleOutline:icons$2.psTriangleOutline,psTriangle:icons$2.psTriangle,xboxAOutline:icons$2.xboxAOutline,xboxBOutline:icons$2.xboxBOutline,xboxLSButtonArrowDown:icons$2.xboxLSButtonArrowDown,xboxRSButtonArrowDown:icons$2.xboxRSButtonArrowDown,xboxXAxisLeft:icons$2.xboxXAxisLeft,xboxXAxisRight:icons$2.xboxXAxisRight,xboxXOutline:icons$2.xboxXOutline,xboxXRotLeft:icons$2.xboxXRotLeft,xboxXRotRight:icons$2.xboxXRotRight,xboxYAxisDown:icons$2.xboxYAxisDown,xboxYAxisUp:icons$2.xboxYAxisUp,xboxYOutline:icons$2.xboxYOutline,xboxYRotDown:icons$2.xboxYRotDown,xboxYRotUp:icons$2.xboxYRotUp,psDLeftRight:icons$2.psDLeftRight,psDUpDown:icons$2.psDUpDown,xboxDLeftRight:icons$2.xboxDLeftRight,xboxDUpDown:icons$2.xboxDUpDown},input:{gamepadOld:icons$2.gamepadOld,gamepad:icons$2.gamepad,keyboard:icons$2.keyboard,mouseLMB:icons$2.mouseLMB,mouseMMB:icons$2.mouseMMB,mouseRMB:icons$2.mouseRMB,mouseWheel:icons$2.mouseWheel,mouseXAxis:icons$2.mouseXAxis,mouseXYAxis:icons$2.mouseXYAxis,mouseYAxis:icons$2.mouseYAxis,mouse:icons$2.mouse,noNameControllerButton:icons$2.noNameControllerButton,palmCrossed:icons$2.palmCrossed,smartphone1:icons$2.smartphone1,smartphone2:icons$2.smartphone2,steeringWheelCommon:icons$2.steeringWheelCommon,steeringWheelSporty:icons$2.steeringWheelSporty,touch:icons$2.touch,xboxA:icons$2.xboxA,xboxB:icons$2.xboxB,xboxDDefaultOutline:icons$2.xboxDDefaultOutline,xboxDDefaultSolid:icons$2.xboxDDefaultSolid,xboxDDown:icons$2.xboxDDown,xboxDLeft:icons$2.xboxDLeft,xboxDRight:icons$2.xboxDRight,xboxDUp:icons$2.xboxDUp,xboxLB:icons$2.xboxLB,xboxLSButton:icons$2.xboxLSButton,xboxLT:icons$2.xboxLT,xboxMenu:icons$2.xboxMenu,xboxRB:icons$2.xboxRB,xboxRSButton:icons$2.xboxRSButton,xboxRT:icons$2.xboxRT,xboxThumbL:icons$2.xboxThumbL,xboxThumbR:icons$2.xboxThumbR,xboxView:icons$2.xboxView,xboxXAxis:icons$2.xboxXAxis,xboxXRot:icons$2.xboxXRot,xboxX:icons$2.xboxX,xboxYAxis:icons$2.xboxYAxis,xboxYRot:icons$2.xboxYRot,xboxY:icons$2.xboxY,psCircleOutline:icons$2.psCircleOutline,psCircle:icons$2.psCircle,psCreate2:icons$2.psCreate2,psCreate:icons$2.psCreate,psCrossOutline:icons$2.psCrossOutline,psCross:icons$2.psCross,psDDefaultOutline:icons$2.psDDefaultOutline,psDDefaultSolid:icons$2.psDDefaultSolid,psDDown:icons$2.psDDown,psDLeft:icons$2.psDLeft,psDRight:icons$2.psDRight,psDUp:icons$2.psDUp,psL1:icons$2.psL1,psL2:icons$2.psL2,psL3ButtonArrowDown:icons$2.psL3ButtonArrowDown,psL3Button:icons$2.psL3Button,psLSXLeft:icons$2.psLSXLeft,psLSXRight:icons$2.psLSXRight,psLSX:icons$2.psLSX,psLSYDown:icons$2.psLSYDown,psLSYUp:icons$2.psLSYUp,psLSY:icons$2.psLSY,psLS:icons$2.psLS,psMenu2:icons$2.psMenu2,psMenu:icons$2.psMenu,psR1:icons$2.psR1,psR2:icons$2.psR2,psR3ButtonArrowDown:icons$2.psR3ButtonArrowDown,psR3Button:icons$2.psR3Button,psRSXLeft:icons$2.psRSXLeft,psRSXRight:icons$2.psRSXRight,psRSX:icons$2.psRSX,psRSYDown:icons$2.psRSYDown,psRSYUp:icons$2.psRSYUp,psRSY:icons$2.psRSY,psRS:icons$2.psRS,psSquareOutline:icons$2.psSquareOutline,psSquare:icons$2.psSquare,psTrackpadNavigate:icons$2.psTrackpadNavigate,psTrackpadPressCenter:icons$2.psTrackpadPressCenter,psTrackpadPressLeft:icons$2.psTrackpadPressLeft,psTrackpadPressRight:icons$2.psTrackpadPressRight,psTrackpadSwipeDown:icons$2.psTrackpadSwipeDown,psTrackpadSwipeLeft:icons$2.psTrackpadSwipeLeft,psTrackpadSwipeRight:icons$2.psTrackpadSwipeRight,psTrackpadSwipeUp:icons$2.psTrackpadSwipeUp,psTriangleOutline:icons$2.psTriangleOutline,psTriangle:icons$2.psTriangle,xboxAOutline:icons$2.xboxAOutline,xboxBOutline:icons$2.xboxBOutline,xboxLSButtonArrowDown:icons$2.xboxLSButtonArrowDown,xboxRSButtonArrowDown:icons$2.xboxRSButtonArrowDown,xboxXAxisLeft:icons$2.xboxXAxisLeft,xboxXAxisRight:icons$2.xboxXAxisRight,xboxXOutline:icons$2.xboxXOutline,xboxXRotLeft:icons$2.xboxXRotLeft,xboxXRotRight:icons$2.xboxXRotRight,xboxYAxisDown:icons$2.xboxYAxisDown,xboxYAxisUp:icons$2.xboxYAxisUp,xboxYOutline:icons$2.xboxYOutline,xboxYRotDown:icons$2.xboxYRotDown,xboxYRotUp:icons$2.xboxYRotUp,psDLeftRight:icons$2.psDLeftRight,psDUpDown:icons$2.psDUpDown,xboxDLeftRight:icons$2.xboxDLeftRight,xboxDUpDown:icons$2.xboxDUpDown},gps:{GPSMark:icons$2.GPSMark,GPSSolid:icons$2.GPSSolid,location1:icons$2.location1,location2:icons$2.location2},position:{GPSMark:icons$2.GPSMark,GPSSolid:icons$2.GPSSolid,location1:icons$2.location1,location2:icons$2.location2},map:{GPSMark:icons$2.GPSMark,GPSSolid:icons$2.GPSSolid,location1:icons$2.location1,location2:icons$2.location2},keyboard:{keyboard:icons$2.keyboard,kbArrowsDown:icons$2.kbArrowsDown,kbArrowsLeftRight:icons$2.kbArrowsLeftRight,kbArrowsLeft:icons$2.kbArrowsLeft,kbArrowsOutline:icons$2.kbArrowsOutline,kbArrowsRight:icons$2.kbArrowsRight,kbArrowsSolid:icons$2.kbArrowsSolid,kbArrowsUpDown:icons$2.kbArrowsUpDown,kbArrowsUp:icons$2.kbArrowsUp},lights:{lightGarageG11:icons$2.lightGarageG11,lightGarageG12:icons$2.lightGarageG12,lightGarageG13:icons$2.lightGarageG13,lightGarageG14:icons$2.lightGarageG14,lightGarageG21:icons$2.lightGarageG21,lightGarageG22:icons$2.lightGarageG22,lightGarageG23:icons$2.lightGarageG23,lightGarageG24:icons$2.lightGarageG24,lightGarageG31:icons$2.lightGarageG31,lightGarageG32:icons$2.lightGarageG32,lightGarageG33:icons$2.lightGarageG33,lightGarageG34:icons$2.lightGarageG34},catalog:{listBig:icons$2.listBig,listSmall:icons$2.listSmall,tiles:icons$2.tiles},selector:{listBig:icons$2.listBig,listSmall:icons$2.listSmall,tiles:icons$2.tiles},view:{listBig:icons$2.listBig,listSmall:icons$2.listSmall,tiles:icons$2.tiles},math:{mathDivide:icons$2.mathDivide,mathGreaterOrEqualThan:icons$2.mathGreaterOrEqualThan,mathGreaterThan:icons$2.mathGreaterThan,mathLessOrEqualThan:icons$2.mathLessOrEqualThan,mathLessThan:icons$2.mathLessThan,mathMinus:icons$2.mathMinus,mathMultiply:icons$2.mathMultiply,mathPlus:icons$2.mathPlus,slashLeft:icons$2.slashLeft,slashRight:icons$2.slashRight},operands:{mathDivide:icons$2.mathDivide,mathGreaterOrEqualThan:icons$2.mathGreaterOrEqualThan,mathGreaterThan:icons$2.mathGreaterThan,mathLessOrEqualThan:icons$2.mathLessOrEqualThan,mathLessThan:icons$2.mathLessThan,mathMinus:icons$2.mathMinus,mathMultiply:icons$2.mathMultiply,mathPlus:icons$2.mathPlus,slashLeft:icons$2.slashLeft,slashRight:icons$2.slashRight},reward:{medal:icons$2.medal,voucherDiagonal1:icons$2.voucherDiagonal1,voucherDiagonal2:icons$2.voucherDiagonal2,voucherDiagonal3:icons$2.voucherDiagonal3,voucherHorizontal1:icons$2.voucherHorizontal1,voucherHorizontal2:icons$2.voucherHorizontal2,voucherHorizontal3:icons$2.voucherHorizontal3,medalEmpty:icons$2.medalEmpty,medalStar:icons$2.medalStar,badgeRoundEmpty:icons$2.badgeRoundEmpty,badgeRoundStar:icons$2.badgeRoundStar,badgeRound:icons$2.badgeRound,badge:icons$2.badge},achievment:{medal:icons$2.medal,medalEmpty:icons$2.medalEmpty,medalStar:icons$2.medalStar,badgeRoundEmpty:icons$2.badgeRoundEmpty,badgeRoundStar:icons$2.badgeRoundStar,badgeRound:icons$2.badgeRound,badge:icons$2.badge},mesh:{mesh4Cells:icons$2.mesh4Cells,mesh9Cells:icons$2.mesh9Cells},beams:{mesh4Cells:icons$2.mesh4Cells,mesh9Cells:icons$2.mesh9Cells},nodes:{mesh4Cells:icons$2.mesh4Cells,mesh9Cells:icons$2.mesh9Cells},surface:{mesh4Cells:icons$2.mesh4Cells,mesh9Cells:icons$2.mesh9Cells,bridge:icons$2.bridge,bump:icons$2.bump,bumps:icons$2.bumps,caution:icons$2.caution,crest:icons$2.crest,doubleCaution:icons$2.doubleCaution,finish:icons$2.finish,jumpOverBump:icons$2.jumpOverBump,narrows:icons$2.narrows,pothole:icons$2.pothole,turn1:icons$2.turn1,turn2:icons$2.turn2,turn3:icons$2.turn3,turn4:icons$2.turn4,turn5:icons$2.turn5,turn6:icons$2.turn6,turnHp:icons$2.turnHp,turnSq:icons$2.turnSq,water:icons$2.water,tripleCaution:icons$2.tripleCaution},mirror:{mirrorInteriorMiddle:icons$2.mirrorInteriorMiddle,mirrorLeftBigBottomWideAngle:icons$2.mirrorLeftBigBottomWideAngle,mirrorLeftBigTop:icons$2.mirrorLeftBigTop,mirrorLeftBig:icons$2.mirrorLeftBig,mirrorLeftBonnet:icons$2.mirrorLeftBonnet,mirrorLeftDefault:icons$2.mirrorLeftDefault,mirrorRightBigBottomWideAngle:icons$2.mirrorRightBigBottomWideAngle,mirrorRightBigTop:icons$2.mirrorRightBigTop,mirrorRightBig:icons$2.mirrorRightBig,mirrorRightBonnet:icons$2.mirrorRightBonnet,mirrorRightDefault:icons$2.mirrorRightDefault,mirrorRoundWideAngle:icons$2.mirrorRoundWideAngle,mirrorTopWideAngle:icons$2.mirrorTopWideAngle},rearview:{mirrorInteriorMiddle:icons$2.mirrorInteriorMiddle,mirrorLeftBigBottomWideAngle:icons$2.mirrorLeftBigBottomWideAngle,mirrorLeftBigTop:icons$2.mirrorLeftBigTop,mirrorLeftBig:icons$2.mirrorLeftBig,mirrorLeftBonnet:icons$2.mirrorLeftBonnet,mirrorLeftDefault:icons$2.mirrorLeftDefault,mirrorRightBigBottomWideAngle:icons$2.mirrorRightBigBottomWideAngle,mirrorRightBigTop:icons$2.mirrorRightBigTop,mirrorRightBig:icons$2.mirrorRightBig,mirrorRightBonnet:icons$2.mirrorRightBonnet,mirrorRightDefault:icons$2.mirrorRightDefault,mirrorRoundWideAngle:icons$2.mirrorRoundWideAngle,mirrorTopWideAngle:icons$2.mirrorTopWideAngle},mouse:{mouseLMB:icons$2.mouseLMB,mouseMMB:icons$2.mouseMMB,mouseRMB:icons$2.mouseRMB,mouseWheel:icons$2.mouseWheel,mouseXAxis:icons$2.mouseXAxis,mouseXYAxis:icons$2.mouseXYAxis,mouseYAxis:icons$2.mouseYAxis,mouse:icons$2.mouse},path:{nodeAddFirst01:icons$2.nodeAddFirst01,nodeAddFirst02:icons$2.nodeAddFirst02,nodeAddLast02:icons$2.nodeAddLast02,nodeAddMiddle01:icons$2.nodeAddMiddle01,nodeAddMiddle02:icons$2.nodeAddMiddle02,nodeAdd:icons$2.nodeAdd,nodeLast01:icons$2.nodeLast01,nodeRemove:icons$2.nodeRemove,locationDestination:icons$2.locationDestination,locationSource:icons$2.locationSource},node:{nodeAddFirst01:icons$2.nodeAddFirst01,nodeAddFirst02:icons$2.nodeAddFirst02,nodeAddLast02:icons$2.nodeAddLast02,nodeAddMiddle01:icons$2.nodeAddMiddle01,nodeAddMiddle02:icons$2.nodeAddMiddle02,nodeAdd:icons$2.nodeAdd,nodeLast01:icons$2.nodeLast01,nodeRemove:icons$2.nodeRemove,locationDestination:icons$2.locationDestination,locationSource:icons$2.locationSource},touch:{palmCrossed:icons$2.palmCrossed,smartphone1:icons$2.smartphone1,smartphone2:icons$2.smartphone2,touch:icons$2.touch},route:{routeAdd:icons$2.routeAdd,routeComplex:icons$2.routeComplex,routeSimple:icons$2.routeSimple,trafficCone:icons$2.trafficCone,locationDestination:icons$2.locationDestination,locationSource:icons$2.locationSource,routeSimpleFlag:icons$2.routeSimpleFlag},traffic:{routeAdd:icons$2.routeAdd,routeComplex:icons$2.routeComplex,routeSimple:icons$2.routeSimple,trafficCone:icons$2.trafficCone,trafficLight:icons$2.trafficLight,pedestrianRunning:icons$2.pedestrianRunning,pedestrianStanding:icons$2.pedestrianStanding,routeSimpleFlag:icons$2.routeSimpleFlag},trailer:{semiTrailer:icons$2.semiTrailer,semiTruck:icons$2.semiTruck,smallTrailer:icons$2.smallTrailer,tankerTrailer:icons$2.tankerTrailer},steering:{steeringWheelCommon:icons$2.steeringWheelCommon,steeringWheelSporty:icons$2.steeringWheelSporty},time:{stopwatchArrows01:icons$2.stopwatchArrows01,stopwatchArrows02:icons$2.stopwatchArrows02,stopwatchSectionOutlinedEnd:icons$2.stopwatchSectionOutlinedEnd,stopwatchSectionOutlinedStart:icons$2.stopwatchSectionOutlinedStart,stopwatchSectionSolidEnd:icons$2.stopwatchSectionSolidEnd,stopwatchSectionSolidStart:icons$2.stopwatchSectionSolidStart,timer:icons$2.timer},fast:{stopwatchArrows01:icons$2.stopwatchArrows01,stopwatchArrows02:icons$2.stopwatchArrows02,stopwatchSectionOutlinedEnd:icons$2.stopwatchSectionOutlinedEnd,stopwatchSectionOutlinedStart:icons$2.stopwatchSectionOutlinedStart,stopwatchSectionSolidEnd:icons$2.stopwatchSectionSolidEnd,stopwatchSectionSolidStart:icons$2.stopwatchSectionSolidStart,timer:icons$2.timer},emergency:{strobeLights:icons$2.strobeLights,wigwags:icons$2.wigwags},circuit:{switchBlock:icons$2.switchBlock,switchOutline:icons$2.switchOutline},electronics:{switchBlock:icons$2.switchBlock,switchOutline:icons$2.switchOutline},switch:{switchBlock:icons$2.switchBlock,switchOutline:icons$2.switchOutline},tank:{tankerTrailer:icons$2.tankerTrailer},tanker:{tankerTrailer:icons$2.tankerTrailer},taxi:{taxiCar1:icons$2.taxiCar1,taxiCar3:icons$2.taxiCar3,taxiCarT:icons$2.taxiCarT,taxiCheckerLamp:icons$2.taxiCheckerLamp},tire:{tireDirection3Fourth2:icons$2.tireDirection3Fourth2,tireDirection3Fourth3:icons$2.tireDirection3Fourth3,tireDirectionFront2:icons$2.tireDirectionFront2,tireDirectionSide2:icons$2.tireDirectionSide2,tireDirectionTop2:icons$2.tireDirectionTop2,tire3FourthCoins:icons$2.tire3FourthCoins,tire3Fourth:icons$2.tire3Fourth},currency:{voucherDiagonal1:icons$2.voucherDiagonal1,voucherDiagonal2:icons$2.voucherDiagonal2,voucherDiagonal3:icons$2.voucherDiagonal3,voucherHorizontal1:icons$2.voucherHorizontal1,voucherHorizontal2:icons$2.voucherHorizontal2,voucherHorizontal3:icons$2.voucherHorizontal3,beamCurrencyOutlineLarge:icons$2.beamCurrencyOutlineLarge},extra:{AIL:icons$2.AIL,automaticTransmissionL:icons$2.automaticTransmissionL,chargeLL:icons$2.chargeLL,clutchL:icons$2.clutchL,couplerL:icons$2.couplerL,engineL:icons$2.engineL,multiseatL:icons$2.multiseatL,POITimeL:icons$2.POITimeL,replayL:icons$2.replayL,roadblockL:icons$2.roadblockL,rotationL:icons$2.rotationL,sensorsL:icons$2.sensorsL,temperatureL:icons$2.temperatureL,tuningL:icons$2.tuningL,turbineL:icons$2.turbineL},web:{arrowLeftOutline:icons$2.arrowLeftOutline,arrowRightOutline:icons$2.arrowRightOutline,beamsNodesMessageOutline:icons$2.beamsNodesMessageOutline,beamsNodesOutline:icons$2.beamsNodesOutline,beamsNodesPlugOutline:icons$2.beamsNodesPlugOutline,BNGEcosystemOutline:icons$2.BNGEcosystemOutline,carFrontRouteOutline:icons$2.carFrontRouteOutline,carSensorsOutline:icons$2.carSensorsOutline,carSideRouteOutline:icons$2.carSideRouteOutline,cityOutline:icons$2.cityOutline,dialogOutline:icons$2.dialogOutline,documentSmileOutline:icons$2.documentSmileOutline,drivetrainOutline:icons$2.drivetrainOutline,electronicSchemeOutline:icons$2.electronicSchemeOutline,engineOutline:icons$2.engineOutline,gearTuningOutline:icons$2.gearTuningOutline,giftBoxOutline:icons$2.giftBoxOutline,lidarOutline:icons$2.lidarOutline,medalStarOutline:icons$2.medalStarOutline,megaphoneOutline:icons$2.megaphoneOutline,peopleOutline:icons$2.peopleOutline,personOutline:icons$2.personOutline,physicsOutline:icons$2.physicsOutline,playChainOutline:icons$2.playChainOutline,proximitySensorsOutline:icons$2.proximitySensorsOutline,qualityBadgeStarOutline:icons$2.qualityBadgeStarOutline,qualityBadgeVOutline:icons$2.qualityBadgeVOutline,simRigOutline:icons$2.simRigOutline,suspensionOutline:icons$2.suspensionOutline,teamOutline:icons$2.teamOutline,techLightBulbOutline01:icons$2.techLightBulbOutline01,techLightBulbOutline02:icons$2.techLightBulbOutline02,timeUnlockOutline:icons$2.timeUnlockOutline,timedLockOutline:icons$2.timedLockOutline,trafficOutline:icons$2.trafficOutline,voucherOutline:icons$2.voucherOutline,wheelBeamsNodesOutline:icons$2.wheelBeamsNodesOutline,wheelOutline:icons$2.wheelOutline},secondary:{arrowLeftOutline:icons$2.arrowLeftOutline,arrowRightOutline:icons$2.arrowRightOutline,beamsNodesMessageOutline:icons$2.beamsNodesMessageOutline,beamsNodesOutline:icons$2.beamsNodesOutline,beamsNodesPlugOutline:icons$2.beamsNodesPlugOutline,BNGEcosystemOutline:icons$2.BNGEcosystemOutline,carFrontRouteOutline:icons$2.carFrontRouteOutline,carSensorsOutline:icons$2.carSensorsOutline,carSideRouteOutline:icons$2.carSideRouteOutline,cityOutline:icons$2.cityOutline,dialogOutline:icons$2.dialogOutline,documentSmileOutline:icons$2.documentSmileOutline,drivetrainOutline:icons$2.drivetrainOutline,electronicSchemeOutline:icons$2.electronicSchemeOutline,engineOutline:icons$2.engineOutline,gearTuningOutline:icons$2.gearTuningOutline,giftBoxOutline:icons$2.giftBoxOutline,lidarOutline:icons$2.lidarOutline,medalStarOutline:icons$2.medalStarOutline,megaphoneOutline:icons$2.megaphoneOutline,peopleOutline:icons$2.peopleOutline,personOutline:icons$2.personOutline,physicsOutline:icons$2.physicsOutline,playChainOutline:icons$2.playChainOutline,proximitySensorsOutline:icons$2.proximitySensorsOutline,qualityBadgeStarOutline:icons$2.qualityBadgeStarOutline,qualityBadgeVOutline:icons$2.qualityBadgeVOutline,simRigOutline:icons$2.simRigOutline,suspensionOutline:icons$2.suspensionOutline,teamOutline:icons$2.teamOutline,techLightBulbOutline01:icons$2.techLightBulbOutline01,techLightBulbOutline02:icons$2.techLightBulbOutline02,timeUnlockOutline:icons$2.timeUnlockOutline,timedLockOutline:icons$2.timedLockOutline,trafficOutline:icons$2.trafficOutline,voucherOutline:icons$2.voucherOutline,wheelBeamsNodesOutline:icons$2.wheelBeamsNodesOutline,wheelOutline:icons$2.wheelOutline},hazard:{danger:icons$2.danger,fireDiamond:icons$2.fireDiamond,test:icons$2.test},drop:{droplet:icons$2.droplet},liquid:{droplet:icons$2.droplet},nfpa704:{fireDiamond:icons$2.fireDiamond},"dry cargo":{rocks:icons$2.rocks},dry:{rocks:icons$2.rocks},editor:{scale:icons$2.scale},marker:{arrowsUp:icons$2.arrowsUp,bigDot:icons$2.bigDot,connectorBold:icons$2.connectorBold,cornerTopRight:icons$2.cornerTopRight,plusBold:icons$2.plusBold,puzzlePieceBold:icons$2.puzzlePieceBold},ribbon:{arrowsUp:icons$2.arrowsUp,bigDot:icons$2.bigDot,connectorBold:icons$2.connectorBold,cornerTopRight:icons$2.cornerTopRight,plusBold:icons$2.plusBold,puzzlePieceBold:icons$2.puzzlePieceBold},"content-props":{arrowsUp:icons$2.arrowsUp,bigDot:icons$2.bigDot,connectorBold:icons$2.connectorBold,cornerTopRight:icons$2.cornerTopRight,plusBold:icons$2.plusBold,puzzlePieceBold:icons$2.puzzlePieceBold},location:{locationDestination:icons$2.locationDestination,locationSource:icons$2.locationSource},shop:{shoppingCart:icons$2.shoppingCart},purchase:{shoppingCart:icons$2.shoppingCart},bus:{busTilted:icons$2.busTilted},destruction:{explosion:icons$2.explosion,fireExtinguisher:icons$2.fireExtinguisher,fire:icons$2.fire},"turn signals":{twoArrowsHorizontal:icons$2.twoArrowsHorizontal,twoArrowsVertical:icons$2.twoArrowsVertical},rally:{bridge:icons$2.bridge,bump:icons$2.bump,bumps:icons$2.bumps,caution:icons$2.caution,crest:icons$2.crest,doubleCaution:icons$2.doubleCaution,finish:icons$2.finish,jumpOverBump:icons$2.jumpOverBump,narrows:icons$2.narrows,pothole:icons$2.pothole,turn1:icons$2.turn1,turn2:icons$2.turn2,turn3:icons$2.turn3,turn4:icons$2.turn4,turn5:icons$2.turn5,turn6:icons$2.turn6,turnHp:icons$2.turnHp,turnSq:icons$2.turnSq,water:icons$2.water,rallyHelmet3To4:icons$2.rallyHelmet3To4,rallyHelmet:icons$2.rallyHelmet,tripleCaution:icons$2.tripleCaution},"pace notes":{bridge:icons$2.bridge,bump:icons$2.bump,bumps:icons$2.bumps,caution:icons$2.caution,crest:icons$2.crest,doubleCaution:icons$2.doubleCaution,finish:icons$2.finish,jumpOverBump:icons$2.jumpOverBump,narrows:icons$2.narrows,pothole:icons$2.pothole,turn1:icons$2.turn1,turn2:icons$2.turn2,turn3:icons$2.turn3,turn4:icons$2.turn4,turn5:icons$2.turn5,turn6:icons$2.turn6,turnHp:icons$2.turnHp,turnSq:icons$2.turnSq,water:icons$2.water,tripleCaution:icons$2.tripleCaution},directions:{bridge:icons$2.bridge,bump:icons$2.bump,bumps:icons$2.bumps,caution:icons$2.caution,crest:icons$2.crest,doubleCaution:icons$2.doubleCaution,finish:icons$2.finish,jumpOverBump:icons$2.jumpOverBump,narrows:icons$2.narrows,pothole:icons$2.pothole,turn1:icons$2.turn1,turn2:icons$2.turn2,turn3:icons$2.turn3,turn4:icons$2.turn4,turn5:icons$2.turn5,turn6:icons$2.turn6,turnHp:icons$2.turnHp,turnSq:icons$2.turnSq,water:icons$2.water,tripleCaution:icons$2.tripleCaution},"do not cut":{circleSlashed:icons$2.circleSlashed,scissorsSlashed:icons$2.scissorsSlashed},"no entry":{circleSlashed:icons$2.circleSlashed},cut:{scissors:icons$2.scissors},car:{airPuffRight1:icons$2.airPuffRight1,octagonBrick:icons$2.octagonBrick,octagon:icons$2.octagon,tireAirPuff:icons$2.tireAirPuff,tireDeflated:icons$2.tireDeflated},select:{carsChange:icons$2.carsChange,carsWrench:icons$2.carsWrench},physics:{forceFieldPull1:icons$2.forceFieldPull1,forceFieldPull2:icons$2.forceFieldPull2,forceFieldPull3:icons$2.forceFieldPull3,forceFieldPush1:icons$2.forceFieldPush1,forceFieldPush2:icons$2.forceFieldPush2,forceFieldPush3:icons$2.forceFieldPush3,pushUp:icons$2.pushUp,pushBackward:icons$2.pushBackward,pushDown:icons$2.pushDown,pushForward:icons$2.pushForward},field:{forceFieldPull1:icons$2.forceFieldPull1,forceFieldPull2:icons$2.forceFieldPull2,forceFieldPull3:icons$2.forceFieldPull3,forceFieldPush1:icons$2.forceFieldPush1,forceFieldPush2:icons$2.forceFieldPush2,forceFieldPush3:icons$2.forceFieldPush3},force:{forceFieldPull1:icons$2.forceFieldPull1,forceFieldPull2:icons$2.forceFieldPull2,forceFieldPull3:icons$2.forceFieldPull3,forceFieldPush1:icons$2.forceFieldPush1,forceFieldPush2:icons$2.forceFieldPush2,forceFieldPush3:icons$2.forceFieldPush3,pushUp:icons$2.pushUp,pushBackward:icons$2.pushBackward,pushDown:icons$2.pushDown,pushForward:icons$2.pushForward},"garage number":{garageNumber1:icons$2.garageNumber1,garageNumber2:icons$2.garageNumber2,garageNumber3:icons$2.garageNumber3,garageNumber4:icons$2.garageNumber4,garageNumber5:icons$2.garageNumber5,garageNumber6:icons$2.garageNumber6,garageNumber7:icons$2.garageNumber7,garageNumber8:icons$2.garageNumber8,garageNumber9:icons$2.garageNumber9},stop:{square:icons$2.square},roads:{trafficLight:icons$2.trafficLight},sign:{pedestrianRunning:icons$2.pedestrianRunning,pedestrianStanding:icons$2.pedestrianStanding},pedestrian:{pedestrianRunning:icons$2.pedestrianRunning,pedestrianStanding:icons$2.pedestrianStanding},actions:{seatArrowIn:icons$2.seatArrowIn,seatArrowOut:icons$2.seatArrowOut,seatVArrowIn:icons$2.seatVArrowIn,seatVArrowOut:icons$2.seatVArrowOut,vehicleArrowIn:icons$2.vehicleArrowIn,vehicleArrowOut:icons$2.vehicleArrowOut,leverFrontOperate:icons$2.leverFrontOperate,leverSideDown:icons$2.leverSideDown,leverSideOperate:icons$2.leverSideOperate,leverSideUp:icons$2.leverSideUp,seatArrowInLeft:icons$2.seatArrowInLeft,seatArrowOutLeft:icons$2.seatArrowOutLeft,seatVArrowInLeft:icons$2.seatVArrowInLeft,seatVArrowOutLeft:icons$2.seatVArrowOutLeft},outline:{beamCurrencyOutlineLarge:icons$2.beamCurrencyOutlineLarge},scenario:{flagOutlineLarge:icons$2.flagOutlineLarge},house:{houseWrenchRoof:icons$2.houseWrenchRoof,houseWrench:icons$2.houseWrench,house:icons$2.house},helmet:{rallyHelmet3To4:icons$2.rallyHelmet3To4,rallyHelmet:icons$2.rallyHelmet},racing:{rallyHelmet3To4:icons$2.rallyHelmet3To4,rallyHelmet:icons$2.rallyHelmet},"game mode":{rallyHelmet3To4:icons$2.rallyHelmet3To4,rallyHelmet:icons$2.rallyHelmet},offline:{globeSimpleNotSign:icons$2.globeSimpleNotSign},online:{globeSimplified:icons$2.globeSimplified},material:{cableSection:icons$2.cableSection,strapHook:icons$2.strapHook,strapRatchet:icons$2.strapRatchet},beam:{cableSection:icons$2.cableSection},strap:{cableSection:icons$2.cableSection,strapHook:icons$2.strapHook,strapRatchet:icons$2.strapRatchet},controls:{kbArrowsDown:icons$2.kbArrowsDown,kbArrowsLeftRight:icons$2.kbArrowsLeftRight,kbArrowsLeft:icons$2.kbArrowsLeft,kbArrowsOutline:icons$2.kbArrowsOutline,kbArrowsRight:icons$2.kbArrowsRight,kbArrowsSolid:icons$2.kbArrowsSolid,kbArrowsUpDown:icons$2.kbArrowsUpDown,kbArrowsUp:icons$2.kbArrowsUp},equipment:{auxUpDown:icons$2.auxUpDown,bucketArmUpDown:icons$2.bucketArmUpDown,bucketTilt:icons$2.bucketTilt,bucketArmDown:icons$2.bucketArmDown,bucketArmLevel:icons$2.bucketArmLevel,bucketArmUp:icons$2.bucketArmUp,bucketTiltDown:icons$2.bucketTiltDown,bucketTiltLevel:icons$2.bucketTiltLevel,bucketTiltUp:icons$2.bucketTiltUp,dumpBedDown:icons$2.dumpBedDown,dumpBedUpDown:icons$2.dumpBedUpDown,dumpBedUp:icons$2.dumpBedUp}}),getIconsWithTags=(...tagsToFind)=>Object.fromEntries(Object.entries(icons$2).filter(([name,{tags}])=>{for(let t of tagsToFind)if(!tags.includes(t))return!1;return!0})),icons=Object.freeze({...icons$2,_empty:{...icons$2.minus,invisible:!0}}),_sfc_main$369={__name:`bngIcon`,props:{type:{type:[String,Object],default:``},fallbackType:{type:String,default:`placeholder`},color:{type:String,default:`#fff`},asImage:{},image:String,externalImage:String},setup(__props){useCssVars(_ctx=>({v9bdaf084:__props.color}));let props=__props,hasImageSource=computed(()=>!!props.image||!!props.externalImage),imageSrcKey=computed(()=>props.image||props.externalImage||``),errorSrcKey=ref(``),isCurrentSrcErrored=computed(()=>!!imageSrcKey.value&&errorSrcKey.value===imageSrcKey.value),isGlyph=computed(()=>!!(!hasImageSource.value||isCurrentSrcErrored.value)),icon=computed(()=>{let res;switch(typeof props.type){case`object`:props.type.glyph&&(res=props.type);break;case`string`:props.type in icons&&(res=icons[props.type]);break}return res}),displayIcon=computed(()=>{let fallback=typeof props.fallbackType==`string`&&props.fallbackType in icons?icons[props.fallbackType]:icons.placeholder;return isCurrentSrcErrored.value||!icon.value&&!hasImageSource.value?fallback:icon.value}),iconGlyph=computed(()=>displayIcon.value?displayIcon.value.glyph:icons.placeholder.glyph),OFF_VALUES=[null,void 0,!1,`false`,0,`0`],asImage=computed(()=>OFF_VALUES.includes(props.asImage)?!1:props.asImage||!0),imageProps=computed(()=>{let res={bgColor:props.color,mask:[`mask`,`span`].includes(asImage.value)};return icon.value||(res.bgColor=`#f00`),asImage.value||(props.image?res.src=props.image:props.externalImage&&(res.externalSrc=props.externalImage)),res});function onImageError(){errorSrcKey.value=imageSrcKey.value}return(_ctx,_cache)=>isGlyph.value?(openBlock(),createElementBlock(`span`,{key:0,class:normalizeClass([`icon-base`,{"icon-not-found":displayIcon.value===unref(icons).placeholder,"icon-invisible":displayIcon.value&&displayIcon.value.invisible}])},toDisplayString(iconGlyph.value),3)):(openBlock(),createBlock(unref(bngImageAsset_default),mergeProps({key:1,class:`icon-img`},imageProps.value,{onError:onImageError}),null,16))}},bngIcon_default=__plugin_vue_export_helper_default(_sfc_main$369,[[`__scopeId`,`data-v-978d1732`]]),markerValidate=name=>name.endsWith(`Back`)&&Object.keys(iconsBySize[56]).includes(name.replace(/Back$/,`Front`))||name.endsWith(`Front`)&&Object.keys(iconsBySize[56]).includes(name.replace(/Front$/,`Back`)),markersList=Object.keys(iconsBySize[56]).filter(markerValidate).map(name=>name.replace(/Back$|Front$/,``)).sort((a$1,b)=>a$1.toLowerCase().localeCompare(b.toLowerCase())).reduce((res,name)=>res.includes(name)?res:[...res,name],[]);const markers=Object.fromEntries(markersList.map(i=>[i,i])),MARKER_POINTS={up:`up`,down:`down`,left:`left`,right:`right`};var _sfc_main$368={__name:`bngIconMarker`,props:{marker:{type:String,default:`circlePin`,validator:val=>!!markers[val]},type:[String,Object],color:[String,Array],point:{type:String,default:`down`,validator:val=>MARKER_POINTS[val]}},setup(__props){let props=__props,icon=computed(()=>({back:iconsBySize[56][props.marker+`Back`],front:iconsBySize[56][props.marker+`Front`]})),iconColour=computed(()=>({back:(Array.isArray(props.color)?props.color[0]:props.color)||`#fff`,front:(Array.isArray(props.color)?props.color[1]:null)||`#000`,icon:(Array.isArray(props.color)?props.color[2]||props.color[0]:props.color)||`#fff`}));return(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,{class:normalizeClass([`icon-marker`,`icon-point-${__props.point}`,`icon-type-${__props.marker}`])},[createVNode(unref(bngIcon_default),{class:`icon-back`,type:icon.value.back,color:iconColour.value.back},null,8,[`type`,`color`]),createVNode(unref(bngIcon_default),{class:`icon-front`,type:icon.value.front,color:iconColour.value.front},null,8,[`type`,`color`]),__props.type?(openBlock(),createBlock(unref(bngIcon_default),{key:0,class:`icon-inner`,type:__props.type,color:iconColour.value.icon},null,8,[`type`,`color`])):createCommentVNode(``,!0)],2))}},bngIconMarker_default=__plugin_vue_export_helper_default(_sfc_main$368,[[`__scopeId`,`data-v-1089accc`]]),_hoisted_1$322=[`src`],_sfc_main$367=Object.assign({inheritAttrs:!1},{__name:`bngImage`,props:{src:String,observe:Boolean},setup(__props){let props=__props,attrs=useAttrs(),observe=computed(()=>props.observe?`observe`:void 0),imgAttrs=computed(()=>showCanvas.value?{}:attrs),cvsAttrs=computed(()=>showCanvas.value?attrs:{}),elImg=ref(null),elCanvas=ref(null),showCanvas=ref(!1),imgSrc=ref(emptyImage),parentDataAttrs={};function setImage(elm,url,bmp){bmp?(showCanvas.value=!0,imgSrc.value=emptyImage,elCanvas.value.width=bmp.width,elCanvas.value.height=bmp.height,elCanvas.value.getContext(`2d`).drawImage(bmp,0,0),Object.entries(parentDataAttrs).forEach(([attr,value])=>{elCanvas.value.setAttribute(attr,value)})):(showCanvas.value=!1,imgSrc.value=url||`data:image/svg+xml,`)}return watch(()=>props.src,()=>{elImg.value&&(showCanvas.value=!1,imgSrc.value=emptyImage)}),watch(elImg,elm=>{if(elm){parentDataAttrs={};for(let attr of elm.parentElement.getAttributeNames())attr.startsWith(`data-v-`)&&(parentDataAttrs[attr]=elm.parentElement.getAttribute(attr));Object.entries(parentDataAttrs).forEach(([attr,value])=>{elm.setAttribute(attr,value),elCanvas.value&&elCanvas.value.setAttribute(attr,value)}),elm.__setImage=setImage}},{immediate:!0}),(_ctx,_cache)=>(openBlock(),createElementBlock(Fragment,null,[withDirectives(createBaseVNode(`img`,mergeProps({ref_key:`elImg`,ref:elImg},imgAttrs.value,{src:imgSrc.value,alt:``}),null,16,_hoisted_1$322),[[vShow,!showCanvas.value],[unref(BngLazyImage_default),{url:__props.src,callback:setImage},observe.value]]),withDirectives(createBaseVNode(`canvas`,mergeProps({ref_key:`elCanvas`,ref:elCanvas},cvsAttrs.value),null,16),[[vShow,showCanvas.value]])],64))}}),bngImage_default=_sfc_main$367,_hoisted_1$321=[`src`],_sfc_main$366={__name:`bngImageAsset`,props:{src:String,externalSrc:String,span:Boolean,mask:Boolean,bgColor:{type:String,default:`transparent`}},emits:[`error`,`load`],setup(__props,{emit:__emit}){useCssVars(_ctx=>({v0d0b2c1c:__props.bgColor}));let emit$1=__emit,props=__props,assetURL=computed(()=>props.src?getAssetURL(props.src):props.externalSrc);return(_ctx,_cache)=>__props.span||__props.mask?(openBlock(),createElementBlock(`span`,{key:0,class:`bng-image-asset`,style:normalizeStyle({[__props.mask?`maskImage`:`backgroundImage`]:`url(${assetURL.value})`})},[renderSlot(_ctx.$slots,`default`,{},void 0,!0)],4)):(openBlock(),createElementBlock(`img`,{key:1,class:`bng-image-asset`,src:assetURL.value,alt:``,onError:_cache[0]||=$event=>emit$1(`error`,$event),onLoad:_cache[1]||=$event=>emit$1(`load`,$event)},null,40,_hoisted_1$321))}},bngImageAsset_default=__plugin_vue_export_helper_default(_sfc_main$366,[[`__scopeId`,`data-v-27bf5bcc`]]),_hoisted_1$320={class:`bng-image-carousel`},_sfc_main$365={__name:`bngImageCarousel`,props:{images:{type:Array,required:!0},external:Boolean,current:[String,Number],transition:Boolean,transitionType:{type:String,default:`fade`},transitionTime:{type:Number,default:3e3},loop:{type:Boolean,default:!0},showNav:{type:Boolean,default:!0},parent:Object},setup(__props,{expose:__expose}){let props=__props,carousel=ref();__expose({carousel});let imageAssets=computed(()=>props.external?props.images.map(x=>`/`+x):props.images.map(getAssetURL)),carouselSettings=computed(()=>props.parent&&props.parent.carousel!==carousel?{parent:props.parent.carousel,transition:!1,transitionType:props.transitionType,loop:!1,transitionTime:props.transitionTime}:{current:props.current,transition:props.transition,transitionType:props.transitionType,transitionTime:props.transitionTime,loop:props.loop,showNav:props.showNav});return(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$320,[createVNode(unref(carousel_default),mergeProps({items:imageAssets.value,ref_key:`carousel`,ref:carousel},carouselSettings.value),{item:withCtx(({item})=>[createBaseVNode(`div`,{class:`image-slide`,style:normalizeStyle({"background-image":`url(${item})`})},null,4)]),_:1},16,[`items`])]))}},bngImageCarousel_default=__plugin_vue_export_helper_default(_sfc_main$365,[[`__scopeId`,`data-v-6b0c2d6b`]]),_hoisted_1$319=[`src`],_sfc_main$364={__name:`bngImageTile`,props:{oldIcon:String,src:String,externalSrc:String,label:String,image:String,externalImage:String,icon:[Object,String],ratio:{type:String,default:`4:3`}},setup(__props){let props=__props,slots=useSlots(),assetURL=computed(()=>props.externalSrc?props.externalSrc:getAssetURL(props.src));return(_ctx,_cache)=>(openBlock(),createBlock(unref(bngTile_default),{label:__props.label,backgroundImage:__props.image,backgroundExternalImage:__props.externalImage,ratio:__props.ratio},createSlots({default:withCtx(()=>[__props.oldIcon?(openBlock(),createBlock(unref(bngOldIcon_default),{key:0,class:`icon`,type:__props.oldIcon,span:``},null,8,[`type`])):createCommentVNode(``,!0),__props.icon?(openBlock(),createBlock(unref(bngIcon_default),{key:1,class:`glyph`,type:__props.icon},null,8,[`type`])):__props.src||__props.externalSrc?(openBlock(),createElementBlock(`img`,{key:2,class:`icon`,src:assetURL.value},null,8,_hoisted_1$319)):createCommentVNode(``,!0)]),_:2},[unref(slots).default?{name:`label`,fn:withCtx(()=>[renderSlot(_ctx.$slots,`default`,{},void 0,!0)]),key:`0`}:void 0]),1032,[`label`,`backgroundImage`,`backgroundExternalImage`,`ratio`]))}},bngImageTile_default=__plugin_vue_export_helper_default(_sfc_main$364,[[`__scopeId`,`data-v-d74a4ec4`]]),UNIQUE_CLEAN_VALUE=Symbol(`Unique 'clean' value from Dirty service code`);function useDirty(valueRef,emitter=void 0,setCallback=void 0){if(!valueRef)throw Error(`valueRef must be specified`);let hasInitValue=!1,initialValue=ref();function init$3(val){let type=typeof val;type===`undefined`||type===`number`&&isNaN(val)||(hasInitValue=!0,initialValue.value=val)}if(init$3(valueRef.value),!hasInitValue){let unwatch=watch(valueRef,newVal=>{init$3(newVal),hasInitValue&&unwatch()});onUnmounted(()=>!hasInitValue&&unwatch())}let dirty=computed(()=>{let isDirty$1=valueRef.value!==initialValue.value;return isDirty$1&&hasInitValue&&emitter&&emitter(`dirtied`,valueRef.value,initialValue.value),isDirty$1}),setDirty=state=>{let oldVal=initialValue.value,newVal=state?UNIQUE_CLEAN_VALUE:valueRef.value;initialValue.value=newVal,typeof setCallback==`function`&&setCallback(newVal,oldVal)};return{dirty,currentCleanValue:computed(()=>initialValue.value),setCleanValue:val=>initialValue.value=val,resetValue:()=>valueRef.value=initialValue.value,setDirty,markClean:()=>setDirty(!1)}}var _hoisted_1$318={class:`bng-input-wrapper`},_hoisted_2$259={class:`icons-input-wrapper`},_hoisted_3$226={class:`bng-input-container`},_hoisted_4$194={key:0,class:`prefix-suffix-container`},_hoisted_5$164={"data-testid":`prefix`},_hoisted_6$141={class:`bng-input-group`},_hoisted_7$123=[`value`,`type`,`min`,`max`,`step`,`maxlength`,`placeholder`,`disabled`,`readonly`],_hoisted_8$101={key:0,class:`number-actions`},_hoisted_9$91={key:1,class:`floating-label`,"data-testid":`floating-label`},_hoisted_10$79={key:2,class:`error-message`},_hoisted_11$71={key:1,class:`prefix-suffix-container`},_hoisted_12$59={"data-testid":`suffix`},_hoisted_13$51={key:2,class:`trailing-icon`},_sfc_main$363={__name:`bngInput`,props:{modelValue:[String,Number],type:{type:String,default:`text`,validator(value){return[`text`,`number`].includes(value)}},min:[Number,String],max:[Number,String],step:{type:[Number,String],default:1},decimals:Number,maxlength:[Number,String],readonly:Boolean,floatingLabel:String,externalLabel:String,placeholder:String,initialValue:String,leadingIcon:Object,prefix:String,suffix:String,trailingIcon:Object,trailingIconOutside:Boolean,disabled:Boolean,validate:Function,errorMessage:String},emits:[`update:modelValue`,`valueChanged`,`change`,`focus`,`blur`],setup(__props,{expose:__expose,emit:__emit}){let props=__props,emitter=__emit,input=ref(),value=ref(props.initialValue||props.modelValue),isInputFieldFocused=ref(!1),numMin=computed(()=>props.type===`number`?+props.min:null),numMax=computed(()=>props.type===`number`?+props.max:null),numStep=computed(()=>props.type===`number`?roundDec(+props.step,15):null),numDecimals=computed(()=>props.type===`number`?props.decimals:null),charMax=computed(()=>props.type===`text`?props.maxlength:null),hasValue=computed(()=>value.value!==``&&value.value!==void 0&&value.value!==null),hasError=computed(()=>typeof props.validate==`function`?!props.validate(value.value):!1);if(props.type===`number`){let type=typeof value.value;type===`string`&&/^\d+(?:\.?\d+)?$/.test(value.value)?value.value=+value.value:type!==`number`&&(value.value=0),numMin.value>numMax.value&&console.error(`BngInput: min cannot be greater than max`)}__expose(useDirty(value));let lastNotify;function notify(val){props.readonly||lastNotify===val||(lastNotify=val,emitter(`update:modelValue`,val),emitter(`valueChanged`,val),emitter(`change`,val))}watch(()=>props.modelValue,newVal=>{props.type===`number`&&(newVal=numClamp(newVal)),value.value=newVal,lastNotify=newVal},{immediate:!0});function numClamp(val){return isNaN(val)&&(val=0),typeof numDecimals.value==`number`&&!isNaN(numDecimals.value)?val=roundDec(val,numDecimals.value):typeof numStep.value==`number`&&!isNaN(numStep.value)&&(val=roundDecSample(val,numStep.value)),typeof numMin.value==`number`&&!isNaN(numMin.value)&&valnumMax.value&&(val=numMax.value),val}function increment(by){let val=numClamp(+value.value+by);value.value!==val&&(value.value=val,input.value=val,notify(val))}let onArrowUpClicked=()=>increment(numStep.value),onArrowDownClicked=()=>increment(-numStep.value);function onValueChanged($event){let val=$event.target.value;if(props.type===`number`){val=+val;let prev=val;val=numClamp(val),val!==prev&&(input.value=val)}value.value=val,notify(val)}function onInputFieldFocusIn(){isInputFieldFocused.value=!0,emitter(`focus`)}function onInputFieldFocusOut(){isInputFieldFocused.value=!1,emitter(`blur`),notify(value.value)}return(_ctx,_cache)=>withDirectives((openBlock(),createElementBlock(`div`,_hoisted_1$318,[__props.externalLabel?(openBlock(),createElementBlock(`span`,{key:0,class:`external-label`,style:normalizeStyle([__props.leadingIcon?{"margin-left":`3em`}:{}]),"data-testid":`external-label`},toDisplayString(__props.externalLabel),5)):createCommentVNode(``,!0),createBaseVNode(`div`,_hoisted_2$259,[__props.leadingIcon?(openBlock(),createBlock(unref(bngIcon_default),{key:0,class:`outside-icon`,type:__props.leadingIcon,"data-testid":`leading-icon`},null,8,[`type`])):createCommentVNode(``,!0),createBaseVNode(`div`,{tabindex:`disabled ? -1 : 0`,class:normalizeClass([`bng-highlight-container`,{"bng-input-focused":isInputFieldFocused.value,"has-error":hasError.value}]),onKeydown:withKeys(onInputFieldFocusOut,[`enter`])},[createBaseVNode(`div`,_hoisted_3$226,[__props.prefix?(openBlock(),createElementBlock(`span`,_hoisted_4$194,[createBaseVNode(`span`,_hoisted_5$164,toDisplayString(__props.prefix),1)])):createCommentVNode(``,!0),createBaseVNode(`div`,_hoisted_6$141,[withDirectives(createBaseVNode(`input`,{ref_key:`input`,ref:input,class:normalizeClass([`bng-input`,{"bng-input-empty":!hasValue.value,"bng-input-error":hasError.value}]),"data-testid":`input`,value:value.value,type:__props.type,min:numMin.value,max:numMax.value,step:numStep.value,maxlength:charMax.value,onInput:onValueChanged,onFocusin:onInputFieldFocusIn,onFocusout:onInputFieldFocusOut,placeholder:__props.placeholder,disabled:__props.disabled,readonly:__props.readonly},null,42,_hoisted_7$123),[[unref(BngTextInput_default)]]),__props.type===`number`?(openBlock(),createElementBlock(`div`,_hoisted_8$101,[withDirectives(createVNode(unref(bngIcon_default),{type:unref(iconsByTag).arrow.arrowLargeUp,class:normalizeClass([{"number-action-disabled":__props.readonly},`number-action up-action`])},null,8,[`type`,`class`]),[[unref(BngClick_default),{clickCallback:onArrowUpClicked,holdCallback:onArrowUpClicked}]]),withDirectives(createVNode(unref(bngIcon_default),{type:unref(iconsByTag).arrow.arrowLargeDown,class:normalizeClass([`number-action down-action`,{"number-action-disabled":__props.readonly}])},null,8,[`type`,`class`]),[[unref(BngClick_default),{clickCallback:onArrowDownClicked,holdCallback:onArrowDownClicked}]])])):createCommentVNode(``,!0),__props.floatingLabel?(openBlock(),createElementBlock(`span`,_hoisted_9$91,toDisplayString(__props.floatingLabel),1)):createCommentVNode(``,!0),hasError.value&&__props.errorMessage?(openBlock(),createElementBlock(`span`,_hoisted_10$79,toDisplayString(__props.errorMessage),1)):createCommentVNode(``,!0),_cache[0]||=createBaseVNode(`span`,{class:`input-border`},null,-1)]),__props.suffix?(openBlock(),createElementBlock(`span`,_hoisted_11$71,[createBaseVNode(`span`,_hoisted_12$59,toDisplayString(__props.suffix),1)])):createCommentVNode(``,!0),__props.trailingIcon&&!__props.trailingIconOutside?(openBlock(),createElementBlock(`span`,_hoisted_13$51,[createVNode(unref(bngIcon_default),{type:__props.trailingIcon,class:`input-icon`,"data-testid":`trailing-icon`},null,8,[`type`])])):createCommentVNode(``,!0)])],34),__props.trailingIcon&&__props.trailingIconOutside?(openBlock(),createBlock(unref(bngIcon_default),{key:1,type:__props.trailingIcon,class:`outside-icon`,"data-testid":`external-trailing-icon`},null,8,[`type`])):createCommentVNode(``,!0)])])),[[unref(BngDisabled_default),__props.disabled]])}},bngInput_default=__plugin_vue_export_helper_default(_sfc_main$363,[[`__scopeId`,`data-v-d6c70b5c`]]),_hoisted_1$317=[`readonly`,`disabled`,`placeholder`,`maxlength`],_hoisted_2$258={key:0,class:`floating-label`},_hoisted_3$225={key:7,class:`external-button`},_hoisted_4$193={key:8,class:`error-message`};const INPUT_TYPES={text:`text`,number:`number`},STEP_ICON_TYPES={arrowUpDown:`arrowUpDown`,arrowLeftRight:`arrowLeftRight`,plusMinus:`plusMinus`};var STEP_ICON_TYPES_MAP={[STEP_ICON_TYPES.arrowUpDown]:{up:`arrowSmallUp`,down:`arrowSmallDown`},[STEP_ICON_TYPES.arrowLeftRight]:{up:`arrowSmallRight`,down:`arrowSmallLeft`},[STEP_ICON_TYPES.plusMinus]:{up:`plus`,down:`minus`}},NUMBER_PATTERN=/^\d+(\.d+)?$/,NUMBER_INPUT_KEYS=/^[0-9\.\-]$/,ERROR_TYPES={invalidformat:`invalidformat`,outofrange:`outofrange`,required:`required`,custom:`custom`},ERROR_MESSAGES={[ERROR_TYPES.invalidformat]:`Invalid format`,[ERROR_TYPES.outofrange]:`Value must be between {min} and {max}`,[`${ERROR_TYPES.outofrange}-min`]:`Value must be greater than {min}`,[`${ERROR_TYPES.outofrange}-max`]:`Value must be less than {max}`,[ERROR_TYPES.required]:`Value is required`},ALLOW_DEFAULT_BEHAVIOR_KEYS=[`ArrowLeft`,`ArrowRight`,`ArrowUp`,`ArrowDown`,`Backspace`,`Delete`],NUMBER_INPUT_MODES={spinner:`spinner`,arrowKeys:`arrowKeys`,uinav:`uinav`},_sfc_main$362={__name:`bngInputNew`,props:{modelValue:{type:[Number,String],default:void 0},value:{type:[Number,String],default:void 0},type:{type:String,default:INPUT_TYPES.text,validator(value){return Object.keys(INPUT_TYPES).includes(value)}},showExternalButton:{type:Boolean,default:!0},floatingLabel:[Boolean,String],externalButtonFn:Function,externalLabel:String,label:String,prefix:String,suffix:String,leadingIcon:Object,trailingIcon:Object,maxLength:{type:[Number,String],default:null,validator(value){return value===null?!0:typeof parseInt(value)==`number`&&parseInt(value)>=0}},readonly:Boolean,disabled:Boolean,required:Boolean,placeholder:String,validate:Function,errorMessage:String,min:{type:Number,default:void 0},max:{type:Number,default:void 0},step:{type:Number,default:1},stepIconType:{type:String,default:STEP_ICON_TYPES.arrowUpDown,validator(value){return Object.keys(STEP_ICON_TYPES).includes(value)}},noStepBindings:Boolean},emits:[`update:modelValue`,`change`,`error`,`blur`,`focus`,`valueChanged`],setup(__props,{expose:__expose,emit:__emit}){let props=__props,emit$1=__emit,slots=useSlots(),{showIfController}=storeToRefs(controls_default()),input=ref(null),scopeActivated=ref(!1),rawValue=ref(null),validationState=ref(null),isProgrammaticChange=ref(!1),numberInputState=reactive({inputType:null,isUpActive:!1,isDownActive:!1}),value=computed({get:()=>props.modelValue,set:emitChange}),isEmptyRawValue=computed(()=>isEmpty(rawValue.value)),inputStyle=computed(()=>({"max-width":props.maxLength?`${props.maxLength}ch`:`initial`})),stepIcons=computed(()=>STEP_ICON_TYPES_MAP[props.stepIconType]),exposed=useDirty(value);exposed.scopeActivated=scopeActivated,__expose(exposed),watch(()=>rawValue.value,newValue=>{if(isProgrammaticChange.value){isProgrammaticChange.value=!1;return}let res=validate(newValue);validationState.value=res,rawValue.value!=props.modelValue&&(res.valid||res.error!==ERROR_TYPES.invalidformat)&&(value.value=res.value)}),watch(()=>props.modelValue,modelValue=>{modelValue!=rawValue.value&&(isProgrammaticChange.value=!0,rawValue.value=isEmpty(modelValue)?null:String(modelValue))},{immediate:!0}),watch(()=>props.value,()=>{props.modelValue===void 0&&props.value!=rawValue.value&&(isProgrammaticChange.value=!0,rawValue.value=props.value)},{immediate:!0}),onUnmounted(()=>{resetInputState.cancel()});let activateInput=()=>{props.disabled||props.readonly||nextTick(()=>input.value.focus())},canActivateScope=()=>!props.readonly&&!props.disabled,externalButtonFn=()=>{props.externalButtonFn?props.externalButtonFn():props.type===INPUT_TYPES.number?rawValue.value=props.min||0:rawValue.value=null,activateInput()};function onScopeActivated(event){scopeActivated.value=!0}function onScopeDeactivated(event){scopeActivated.value=!1,nextTick(()=>cleanValue())}let resetInputState=debounce(()=>{numberInputState.inputType=null,numberInputState.isUpActive=!1,numberInputState.isDownActive=!1},150);function onUINavChangeValue(dir){numberInputState.inputType&&numberInputState.inputType!==NUMBER_INPUT_MODES.uinav||(numberInputState.inputType=NUMBER_INPUT_MODES.uinav,updateNumValue(dir),resetInputState())}function onArrowKeysChangeValue(dir){numberInputState.inputType&&numberInputState.inputType!==NUMBER_INPUT_MODES.arrowKeys||(numberInputState.inputType=NUMBER_INPUT_MODES.arrowKeys,updateNumValue(dir),resetInputState())}function onSpinnerChangeValue(dir){numberInputState.inputType&&numberInputState.inputType!==NUMBER_INPUT_MODES.spinner||(numberInputState.inputType=NUMBER_INPUT_MODES.spinner,updateNumValue(dir),resetInputState())}function updateNumValue(dir){props.type!==INPUT_TYPES.number||props.disabled||props.readonly||(dir===1?(numberInputState.isUpActive=!0,changeNumValue(props.step)):(numberInputState.isDownActive=!0,changeNumValue(-props.step)))}function onEnterDown(event){event.preventDefault(),scopeActivated.value=!1}function onKeyDown(event){if(ALLOW_DEFAULT_BEHAVIOR_KEYS.includes(event.key))return;event.key===`Enter`&&event.preventDefault();let rawValueString=typeof rawValue.value!=`string`&&!isNullOrUndefined(rawValue.value)?rawValue.value.toString():rawValue.value;props.type===INPUT_TYPES.number&&(!NUMBER_INPUT_KEYS.test(event.key)||event.key===`.`&&(isNullOrUndefined(rawValueString)||rawValueString.includes(`.`))||event.key===`.`&&!NUMBER_PATTERN.test(rawValueString))&&event.preventDefault()}function changeNumValue(diff){if(props.type!==INPUT_TYPES.number)return;if(isEmpty(rawValue.value)){diff<0?rawValue.value=isNullOrUndefined(props.max)?0:props.max:rawValue.value=isNullOrUndefined(props.min)?0:props.min;return}let{valid,value:validatedValue,error}=validate(rawValue.value);if(!valid&&error!==ERROR_TYPES.outofrange){rawValue.value=0;return}let decimalTokens=props.step.toString().split(`.`),stepDecimalPlaces=decimalTokens.length>1?decimalTokens[1].length:0,newValue=Number((validatedValue+diff).toFixed(stepDecimalPlaces)),{valid:isValidRange}=validateRange(newValue);(isValidRange||diff<0&&newValue>=props.max||diff>0&&newValue<=props.min)&&(rawValue.value=newValue)}function cleanValue(){if(!isNullOrUndefined(rawValue.value)&&props.type===INPUT_TYPES.number){let rawValueString=typeof rawValue.value==`string`?rawValue.value:rawValue.value.toString();rawValueString.endsWith(`.`)&&(rawValue.value=rawValueString.slice(0,-1))}}function validate(value$1){let valid=!0,newValue=value$1,errorMessage=null;if(isEmpty(value$1)&&props.required)return{valid:!1,error:ERROR_TYPES.required};if(isEmpty(value$1)&&props.type===INPUT_TYPES.number)return{valid:!0,value:void 0};if(props.type===INPUT_TYPES.number&&typeof value$1==`string`&&(newValue=value$1.includes(`.`)?parseFloat(value$1):parseInt(value$1),isNaN(newValue)))return{valid:!1,error:ERROR_TYPES.invalidformat};if(props.type===INPUT_TYPES.number)return{...validateRange(newValue),value:newValue};if(props.validate){let res=props.validate(value$1);typeof res==`boolean`?(valid=res,errorMessage=props.errorMessage):typeof res==`object`&&(`valid`in res&&console.warn("`validate` function must return a boolean `valid` property. Ignoring validation result..."),valid=res.valid||!0,valid||(errorMessage=`errorMessage`in res?res.errorMessage:props.errorMessage))}return{valid,value:newValue,errorMessage}}function validateRange(value$1){let lessThanMin=props.min&&value$1props.max,valid=!0,errorMessage=null;return!isNullOrUndefined(props.min)&&!isNullOrUndefined(props.max)&&(lessThanMin||greaterThanMax)?(errorMessage=ERROR_MESSAGES[ERROR_TYPES.outofrange].replace(`{min}`,props.min).replace(`{max}`,props.max),valid=!1):lessThanMin?(errorMessage=ERROR_MESSAGES[`${ERROR_TYPES.outofrange}-min`].replace(`{min}`,props.min),valid=!1):greaterThanMax&&(errorMessage=ERROR_MESSAGES[`${ERROR_TYPES.outofrange}-max`].replace(`{max}`,props.max),valid=!1),{valid,error:valid?null:ERROR_TYPES.outofrange,errorMessage}}function isEmpty(val){return val==null||val===``}function isNullOrUndefined(val){return val==null}function emitChange(value$1){emit$1(`update:modelValue`,value$1),emit$1(`change`,value$1),emit$1(`valueChanged`,value$1)}return(_ctx,_cache)=>withDirectives((openBlock(),createElementBlock(`div`,{class:normalizeClass([{"has-value":!isEmptyRawValue.value,"bng-input-readonly":__props.readonly,"bng-input-invalid":validationState.value&&!validationState.value.valid},`bng-input`]),onActivate:onScopeActivated,onDeactivate:onScopeDeactivated},[(__props.label||__props.externalLabel||unref(slots).label)&&!__props.floatingLabel?(openBlock(),createElementBlock(`label`,{key:0,class:`external-label`,onClick:activateInput,onMousedown:_cache[0]||=withModifiers(()=>{},[`prevent`])},[renderSlot(_ctx.$slots,`label`,{},()=>[createTextVNode(toDisplayString(__props.label||__props.externalLabel),1)],!0)],32)):createCommentVNode(``,!0),__props.leadingIcon||unref(slots).leadingIcon?(openBlock(),createElementBlock(`span`,{key:1,class:`leading-icon`,onClick:activateInput,onMousedown:_cache[1]||=withModifiers(()=>{},[`prevent`])},[renderSlot(_ctx.$slots,`leading-icon`,{},()=>[createVNode(unref(bngIcon_default),{type:__props.leadingIcon},null,8,[`type`])],!0)],32)):createCommentVNode(``,!0),__props.type===INPUT_TYPES.number&&!__props.readonly&&!__props.disabled?(openBlock(),createElementBlock(`span`,{key:2,class:normalizeClass([{"spinner-active":numberInputState.isDownActive},`input-spinner input-spinner-down`]),onMousedown:_cache[2]||=withModifiers(()=>{},[`prevent`])},[renderSlot(_ctx.$slots,`spinner-down`,{changeValue:()=>onSpinnerChangeValue(-1)},()=>[withDirectives((openBlock(),createBlock(unref(bngButton_default),{"bng-no-nav":`true`,accent:`text`},{default:withCtx(()=>[__props.noStepBindings?createCommentVNode(``,!0):(openBlock(),createBlock(unref(bngBinding_default),{key:0,controller:``,uiEvent:`focus_d`})),!unref(showIfController)||__props.noStepBindings?(openBlock(),createBlock(unref(bngIcon_default),{key:1,type:stepIcons.value.down},null,8,[`type`])):createCommentVNode(``,!0)]),_:1})),[[unref(BngClick_default),{clickCallback:()=>onSpinnerChangeValue(-1),holdCallback:()=>onSpinnerChangeValue(-1)}]])],!0)],34)):createCommentVNode(``,!0),__props.prefix||unref(slots).prefix?(openBlock(),createElementBlock(`span`,{key:3,class:`prefix`,onClick:activateInput,onMousedown:_cache[3]||=withModifiers(()=>{},[`prevent`])},[renderSlot(_ctx.$slots,`prefix`,{},()=>[createTextVNode(toDisplayString(__props.prefix),1)],!0)],32)):createCommentVNode(``,!0),createBaseVNode(`div`,{class:`input-container`,style:normalizeStyle(inputStyle.value)},[withDirectives(createBaseVNode(`input`,{ref_key:`input`,ref:input,"onUpdate:modelValue":_cache[4]||=$event=>rawValue.value=$event,readonly:__props.readonly,disabled:__props.disabled,placeholder:__props.placeholder,maxlength:__props.maxLength,type:`text`,onFocusin:_cache[5]||=$event=>_ctx.$emit(`focus`),onFocusout:_cache[6]||=$event=>_ctx.$emit(`blur`),onKeydown:[_cache[7]||=withKeys($event=>onArrowKeysChangeValue(1),[`arrow-up`]),_cache[8]||=withKeys($event=>onArrowKeysChangeValue(-1),[`arrow-down`]),withKeys(onEnterDown,[`enter`]),onKeyDown]},null,40,_hoisted_1$317),[[unref(BngTextInput_default)],[unref(BngOnUiNavFocus_default),dir=>onUINavChangeValue(dir),`vertical`,{repeat:!0}],[vModelText,rawValue.value]]),__props.label&&__props.floatingLabel||typeof __props.floatingLabel==`string`||unref(slots).label?(openBlock(),createElementBlock(`label`,_hoisted_2$258,[renderSlot(_ctx.$slots,`label`,{},()=>[createTextVNode(toDisplayString(__props.label||__props.floatingLabel),1)],!0)])):createCommentVNode(``,!0)],4),__props.suffix||unref(slots).suffix?(openBlock(),createElementBlock(`span`,{key:4,class:`suffix`,onClick:activateInput,onMousedown:_cache[9]||=withModifiers(()=>{},[`prevent`])},[renderSlot(_ctx.$slots,`suffix`,{},()=>[createTextVNode(toDisplayString(__props.suffix),1)],!0)],32)):createCommentVNode(``,!0),__props.trailingIcon||unref(slots).trailingIcon?(openBlock(),createElementBlock(`span`,{key:5,class:`trailing-icon`,onClick:activateInput,onMousedown:_cache[10]||=withModifiers(()=>{},[`prevent`])},[renderSlot(_ctx.$slots,`trailing-icon`,{},()=>[createVNode(unref(bngIcon_default),{type:__props.trailingIcon},null,8,[`type`])],!0)],32)):createCommentVNode(``,!0),__props.type===INPUT_TYPES.number&&!__props.readonly&&!__props.disabled?(openBlock(),createElementBlock(`span`,{key:6,class:normalizeClass([{"spinner-active":numberInputState.isUpActive},`input-spinner input-spinner-up`]),onMousedown:_cache[11]||=withModifiers(()=>{},[`prevent`])},[renderSlot(_ctx.$slots,`spinner-up`,{changeValue:()=>onSpinnerChangeValue(1)},()=>[withDirectives((openBlock(),createBlock(unref(bngButton_default),{"bng-no-nav":`true`,accent:`text`},{default:withCtx(()=>[__props.noStepBindings?createCommentVNode(``,!0):(openBlock(),createBlock(unref(bngBinding_default),{key:0,controller:``,uiEvent:`focus_u`})),!unref(showIfController)||__props.noStepBindings?(openBlock(),createBlock(unref(bngIcon_default),{key:1,type:stepIcons.value.up},null,8,[`type`])):createCommentVNode(``,!0)]),_:1})),[[unref(BngClick_default),{clickCallback:()=>onSpinnerChangeValue(1),holdCallback:()=>onSpinnerChangeValue(1)}]])],!0)],34)):createCommentVNode(``,!0),__props.showExternalButton?(openBlock(),createElementBlock(`span`,_hoisted_3$225,[renderSlot(_ctx.$slots,`external-button`,{externalButtonFn},()=>[__props.readonly?createCommentVNode(``,!0):withDirectives((openBlock(),createBlock(unref(bngButton_default),{key:0,icon:unref(icons).mathMultiply,disabled:__props.disabled,accent:`attention`,onClick:externalButtonFn,onMousedown:_cache[12]||=withModifiers(()=>{},[`prevent`])},null,8,[`icon`,`disabled`])),[[unref(BngOnUiNav_default),void 0,`ok`,{asMouse:!0,focusRequired:!0}],[unref(BngDisabled_default),isEmptyRawValue.value]])],!0)])):createCommentVNode(``,!0),validationState.value&&!validationState.value.valid&&validationState.value.errorMessage||unref(slots).errorMessage?(openBlock(),createElementBlock(`span`,_hoisted_4$193,[renderSlot(_ctx.$slots,`error-message`,{},()=>[createTextVNode(toDisplayString(validationState.value.errorMessage),1)],!0)])):createCommentVNode(``,!0)],34)),[[unref(BngDisabled_default),__props.disabled],[unref(BngScopedNav_default),{activated:scopeActivated.value,canActivate:canActivateScope}]])}},bngInputNew_default=__plugin_vue_export_helper_default(_sfc_main$362,[[`__scopeId`,`data-v-bb1297d5`]]),_hoisted_1$316={class:`list-container`},_hoisted_2$257={key:0,class:`list-toolbar`},_hoisted_3$224={key:1},_hoisted_4$192={class:`list-layout-toggle`};const LIST_LAYOUTS={DEFAULT:`tiles`,TILES:`tiles`,LIST:`list`,RIBBON:`ribbon`};var _sfc_main$361={__name:`bngList`,props:{path:Array,pathLimit:{type:[Number,String],default:3},pathTarget:Object,layoutSelector:Boolean,layoutSelectorTarget:Object,layout:{type:String,default:LIST_LAYOUTS.DEFAULT,validator:val=>Object.values(LIST_LAYOUTS).includes(val)},big:Boolean,immediate:Boolean,keepAlive:[Boolean,Number],tileSizeCalc:Function,tileWidth:Number,tileHeight:Number,tileMargin:Number,targetWidth:Number,targetHeight:Number,targetMargin:Number,titleWidth:Number,titleHeight:Number,titleMargin:Number,targetTitleWidth:Number,targetTitleHeight:Number,targetTitleMargin:Number,noBackground:Boolean},emits:[`layoutChange`,`pathClick`],setup(__props,{expose:__expose,emit:__emit}){let emit$1=__emit,props=__props,elPath=ref();__expose({navBack(){elPath.value&&elPath.value.navBack()},navTo(item){elPath.value&&elPath.value.navTo(item)},async scrollToIndex(index=0){if(!bigmode.enabled){let hasPosObserver=(elCont.value.children||[])[0]?.classList.contains(`bng-pos-observer`),elm=(elCont.value.children||[])[index+(hasPosObserver?1:0)];return elm&&elm.scrollIntoView(),elm}let big=await getBigProps(void 0,index);if(!big)return null;let horizontal=layoutSelected.value===LIST_LAYOUTS.RIBBON,containerSize=horizontal?contWidth:contHeight,rowIndex=layoutCache.itemToRow.get(index),itemRowPos=layoutCache.rows[rowIndex]?.pos||big.position,itemRowSize=layoutCache.rows[rowIndex]?.size||(horizontal?tileWidth.value:tileHeight.value),centeredPos=itemRowPos-containerSize/2+itemRowSize/2;scrollPos.value=Math.max(0,centeredPos),horizontal?elCont.value.scrollLeft=scrollPos.value:elCont.value.scrollTop=scrollPos.value,await updSkeleton();let itm=items$2.value[index];return itm?itm.getElement?.()||itm.el||itm:null},refresh(){tileWidth.value=0,tileHeight.value=0,titleWidth.value=0,titleHeight.value=0,tileProps=getItemProps(items$2.value,!1),titleProps=getItemProps(items$2.value,!0),tileProps&&(tileMargin.value=validNum(tileProps.margin)?tileProps.margin:defTileMargin*fontSize,calcTiles()),titleProps&&(titleMargin.value=validNum(titleProps.margin)?titleProps.margin:defTitleMargin*fontSize,calcTitles()),invalidateLayoutCache(),nextTick(()=>{bigmode.enabled&&contWidth>0&&contHeight>0&&(buildLayoutCache(),calcBig(),updSkeleton())})}});let defFontSize=16,defTileWidth=10,defTileHeight=5,defTileMargin=.2,defTitleWidth=10,defTitleHeight=2.5,defTitleMargin=.2,layoutSelected=ref(props.layout);watch(()=>props.layout,()=>layoutSelected.value=props.layout||LIST_LAYOUTS.DEFAULT),watch(()=>layoutSelected.value,val=>{emit$1(`layoutChange`,val),invalidateLayoutCache(),updSize()});let toolbar=computed(()=>{let res={path:props.path&&props.path.length>0,layout:props.layoutSelector};return res.enabled=res.path||res.layout,res.show=res.enabled&&(res.path&&!props.pathTarget||res.layout&&!props.layoutSelectorTarget),res}),slots=useSlots(),elCont=ref(),elSize=ref(),elSkeleton=ref(),tileWidth=ref(0),tileHeight=ref(0),tileMargin=ref(0),titleWidth=ref(0),titleHeight=ref(0),titleMargin=ref(0),scrollPos=ref(0),skeletonItems=ref([]),processing=computed(()=>bigmode.enabled&&(bigmode.initial||layoutCache.building)),contWidth=0,contHeight=0,fontSize=16,skeletonShown=!1,warnShown=!1,listItemsStyle=computed(()=>bigmode.enabled?{transform:`translate${layoutSelected.value===LIST_LAYOUTS.RIBBON?`X`:`Y`}(${bigmode.position}px)`}:void 0),tileProps=null,titleProps=null,bigmode=reactive({enabled:!1,initial:!0,debounce:500,skeleton:!0,layouts:[],getPos:{[LIST_LAYOUTS.TILES]:()=>elCont.value?.scrollTop||0,[LIST_LAYOUTS.LIST]:()=>elCont.value?.scrollTop||0,[LIST_LAYOUTS.RIBBON]:()=>elCont.value?.scrollLeft||0},overflow:2,skeletonOverflow:2,first:0,last:0,perRow:1,items:[],position:0,full:0,size:0});bigmode.layouts=Object.keys(bigmode.getPos);let layoutCache=reactive({version:0,building:!1,valid:!1,itemCount:0,totalSize:0,rows:[],itemToRow:new Map,rowPositions:[]}),items$2=ref([]),itemsView=ref([]),itemsShown=ref(new Set);watch(()=>props.immediate,val=>{val?(bigmode._skeleton=bigmode.skeleton,bigmode._debounce=bigmode.debounce,bigmode.skeleton=!1,bigmode.debounce=0):(bigmode._skeleton&&(bigmode.skeleton=bigmode._skeleton),bigmode._debounce&&(bigmode.debounce=bigmode._debounce))},{immediate:!0}),watch([()=>slots.default?.(),()=>props.big,()=>layoutSelected.value],()=>{let res=slots.default?slots.default():[];bigmode.enabled=props.big&&bigmode.layouts.includes(layoutSelected.value),bigmode.enabled&&(bigmode.initial=!0,res=getItems(res)),res=res.map((item,key)=>({...item,key})),items$2.value=res,bigmode.enabled||(itemsView.value=res),itemsShown.value.clear(),nextTick(()=>{tileProps=getItemProps(res,!1),titleProps=getItemProps(res,!0),invalidateLayoutCache(),updSize(),updSkeleton()})},{immediate:!0});function getItems(vnodes,_level=0){let res=[];for(let vnode of vnodes)switch(typeof vnode.type){case`object`:{let isTitle=vnode.props&&`bng-list-title`in vnode.props,item={...vnode};isTitle&&(item.isBngListTitle=!0),res.push(item);break}case`symbol`:if(_level===20)return logger_default.debug(`BngList reached max level of nested Vue fragments`),[];res.push(...getItems(vnode.children,_level+1));break}return res}function findItem(vnode,_level=0){let res=null;switch(typeof vnode.type){case`object`:res={el:vnode.el,width:vnode.type.width,height:vnode.type.height,margin:vnode.type.margin};break;case`string`:vnode.el instanceof HTMLElement&&(res={el:vnode.el});break;case`symbol`:if(vnode.children.length>0){if(_level===20)return null;res=findItem(vnode.children[0],++_level)}break}return res}function getItemProps(vnodes,title=!1){if(vnodes.length===0)return null;let sampleItem=vnodes.find(vnode=>title&&vnode.isBngListTitle||!title&&!vnode.isBngListTitle);if(!sampleItem)return null;let res=findItem(sampleItem);if(!res)return null;let valid={width:validNum(res.width),height:validNum(res.height),margin:validNum(res.margin)},fontSize$1,targetWidth=0,targetHeight=0,targetMargin=0;if(!title&&props.tileSizeCalc)try{fontSize$1||=getFontSize();let size$3=props.tileSizeCalc({contWidth,contHeight,fontSize:fontSize$1,layout:layoutSelected.value});if(size$3&&typeof size$3==`object`){let isPx=size$3.unit===`px`;targetWidth=isPx?size$3.width/fontSize$1:size$3.width,targetHeight=isPx?size$3.height/fontSize$1:size$3.height,targetMargin=isPx?size$3.margin/fontSize$1:size$3.margin}}catch(err){logger_default.warn(`BngList: tileSizeCalc function error:`,err)}targetWidth||=title?props.titleWidth||props.targetTitleWidth:props.tileWidth||props.targetWidth,targetHeight||=title?props.titleHeight||props.targetTitleHeight:props.tileHeight||props.targetHeight,targetMargin||=title?props.titleMargin||props.targetTitleMargin:props.tileMargin||props.targetMargin,validNum(targetWidth)&&(res.width=targetWidth,valid.width=!0),validNum(targetHeight)&&(res.height=targetHeight,valid.height=!0),validNum(targetMargin)&&(res.margin=targetMargin,valid.margin=!0);let em2px=em=>(fontSize$1||=getFontSize(),em*fontSize$1);if(valid.width&&res.width&&(res.width=em2px(res.width)),valid.height&&res.height&&(res.height=em2px(res.height)),valid.margin&&res.margin&&(res.margin=em2px(res.margin)),!valid.width||bigmode.enabled&&!valid.height||!valid.margin){if(res.el instanceof HTMLElement){let style=window.getComputedStyle(res.el,null);valid.width||(res.width=+style.width.substring(0,style.width.length-2)),valid.height||(res.height=+style.height.substring(0,style.height.length-2)),valid.margin||(res.margin=[style.marginTop,style.marginRight,style.marginBottom,style.marginLeft].map(m=>+m.substring(0,m.length-2)).sort((a$1,b)=>b-a$1)[0])}else logger_default.warn(`BngList cannot access ${title?`title`:`tile`} element for size auto-detection!`);warnShown||(warnShown=!0,logger_default.debug(`BigList was not provided with ${title?`title`:`target`} sizes (from props or from ${title?`title`:`tile`} component export) and attempted to auto-detect them. This may lead to some size micro-adjustments visible to user or invalid sizes. Please specify ${title?`title`:`target`} sizes manually.`),(res.width<1||res.height<1)&&logger_default.debug(`BigList noticed a detected ${title?`title`:``} size being too low: width = ${res.width}, height = ${res.height}`))}return res}let validNum=num=>typeof num==`number`&&!isNaN(num),getFontSize=()=>{if(!elCont.value)return 16;let size$3=window.getComputedStyle(elCont.value,null).fontSize;return+size$3.substring(0,size$3.length-2)||16},resizeObserver=new ResizeObserver(updSize);onMounted(()=>nextTick(()=>{resizeObserver.observe(elSize.value)})),onBeforeUnmount(()=>{elSize.value&&resizeObserver.unobserve(elSize.value),resizeObserver.disconnect()});let scrolling=ref(!1),scrollTmr,scrollTick=!1,onScrollDebounce=async()=>{scrollPos.value=bigmode.getPos[layoutSelected.value](),await updSkeleton()};watch(scrollPos,async pos=>{if(bigmode.enabled)if(bigmode.debounce>0)clearTimeout(scrollTmr),scrolling.value=!0,scrollTmr=setTimeout(async()=>{scrolling.value=!1,await calcBig(pos),await updSkeleton()},bigmode.debounce);else{if(scrollTick)return;scrollTick=!0,requestAnimationFrame(async()=>{scrollTick=!1,await calcBig(pos),await updSkeleton()})}});function vScroll(evt){evt.deltaY!==0&&elCont.value.scrollBy({left:evt.deltaY,behavior:`instant`})}function updSize(entries=[]){let oldContWidth=contWidth,oldContHeight=contHeight;tileWidth.value=0,tileHeight.value=0,titleWidth.value=0,titleHeight.value=0,tileProps?(tileMargin.value=validNum(tileProps.margin)?tileProps.margin:defTileMargin*fontSize,calcTiles(entries)):tileMargin.value=0,titleProps?(titleMargin.value=validNum(titleProps.margin)?titleProps.margin:defTitleMargin*fontSize,calcTitles(entries)):titleMargin.value=0,(Math.abs(oldContWidth-contWidth)>1||Math.abs(oldContHeight-contHeight)>1)&&invalidateLayoutCache(),bigmode.enabled&&!layoutCache.valid&&contWidth>0&&contHeight>0&&(!titleProps||titleWidth.value>0&&titleHeight.value>0)&&buildLayoutCache(),bigmode.enabled&&bigmode.initial&&(tileProps||titleProps)&&nextTick(async()=>{await calcBig(),await updSkeleton(),setTimeout(async()=>{await calcBig(),await updSkeleton()},50)}),elCont.value.removeEventListener(`mousewheel`,vScroll),layoutSelected.value===LIST_LAYOUTS.RIBBON&&elCont.value.addEventListener(`mousewheel`,vScroll)}function calcSizes(entries=[]){if(contWidth=0,contHeight=0,!elSize.value||!bigmode.enabled&&layoutSelected.value!==LIST_LAYOUTS.TILES)return!1;let baseMargin=tileMargin.value,rect=entries[0]?.contentRect||elSize.value.getBoundingClientRect();if(fontSize=getFontSize(),contWidth=rect.width,layoutSelected.value===LIST_LAYOUTS.RIBBON){let tileHeight$1=(tileProps?.height||5*fontSize)+baseMargin,titleHeight$1=titleProps?(titleProps.height||defTitleHeight*fontSize)+(titleProps.margin||defTitleMargin*fontSize):0;contHeight=Math.max(tileHeight$1,titleHeight$1)}else contHeight=rect.height-baseMargin;return!0}function calcTiles(entries=[]){if(!calcSizes(entries))return;let wantsWidth=layoutSelected.value===LIST_LAYOUTS.TILES||bigmode.enabled&&layoutSelected.value===LIST_LAYOUTS.RIBBON,wantsHeight=bigmode.enabled;if(!wantsWidth&&!wantsHeight)return;let baseMargin=tileMargin.value;if(wantsWidth){let baseWidth=tileProps.width||10*fontSize;if(contWidth>0&&layoutSelected.value===LIST_LAYOUTS.TILES){let prepWidth=baseWidth+baseMargin,amount=contWidth/prepWidth;amount<2?tileWidth.value=contWidth-baseMargin:tileWidth.value=(contWidth-baseMargin)/~~amount-baseMargin}else tileWidth.value=baseWidth}wantsHeight&&(tileHeight.value=tileProps.height||5*fontSize),bigmode.enabled&&bigmode.initial&&((!wantsWidth||contWidth>0)&&(!wantsHeight||contHeight>0)?(bigmode.initial=!1,calcBig(),updSkeleton()):window.requestAnimationFrame(()=>calcTiles()))}function calcTitles(){if(bigmode.enabled&&(fontSize=getFontSize()),!titleProps)return;let baseMargin=titleMargin.value,baseHeight=titleProps.height||defTitleHeight*fontSize;layoutSelected.value===LIST_LAYOUTS.RIBBON?titleWidth.value=titleProps.width||10*fontSize:titleWidth.value=contWidth-baseMargin;let oldTitleHeight=titleHeight.value;titleHeight.value=baseHeight,bigmode.enabled&&oldTitleHeight===0&&titleHeight.value>0&&contWidth>0&&contHeight>0&&(invalidateLayoutCache(),buildLayoutCache())}function clearLayoutCache(){layoutCache.totalSize=0,layoutCache.rows=[],layoutCache.itemToRow.clear(),layoutCache.rowPositions=[],layoutCache.valid=!0,layoutCache.building=!1,bigmode.enabled&&(bigmode.initial=!1,bigmode.full=0,bigmode.position=0,itemsView.value=[])}async function buildLayoutCache(){if(layoutCache.building){for(;layoutCache.building;)await sleep(10);return}if(items$2.value.length===0){clearLayoutCache();return}if(!tileProps&&!titleProps||contWidth<=0||contHeight<=0)return;if(layoutCache.building=!0,layoutCache.version=Date.now(),layoutCache.itemCount=items$2.value.length,await sleep(0),layoutCache.rows=[],layoutCache.itemToRow.clear(),layoutCache.rowPositions=[],layoutCache.itemCount!==items$2.value.length&&(layoutCache.itemCount=0),layoutCache.itemCount===0){clearLayoutCache(),items$2.value.length>0&&buildLayoutCache();return}let baseTileMargin=tileProps?.margin||defTileMargin*fontSize,baseTitleMargin=titleProps?.margin||defTitleMargin*fontSize,horizontal=layoutSelected.value===LIST_LAYOUTS.RIBBON,tilesPerRow=layoutSelected.value===LIST_LAYOUTS.TILES?~~(contWidth/tileWidth.value):1,pos=0,first=0,curItems=0;function completeRow(i){let tileSize=horizontal?tileWidth.value:tileHeight.value,size$3=tileSize+baseTileMargin,row={pos,size:size$3,first,last:i-1};layoutCache.rows.push(row),layoutCache.rowPositions.push(pos);for(let j=first;j0&&(completeRow(i),curItems=0);let titleSize=horizontal?titleWidth.value:titleHeight.value,rowSize=titleSize+baseTitleMargin,row={pos,size:rowSize,first:i,last:i,isTitle:!0};layoutCache.rows.push(row),layoutCache.rowPositions.push(pos),layoutCache.itemToRow.set(i,layoutCache.rows.length-1);let nextMargin=items$2.value[i+1]?.isBngListTitle?baseTitleMargin:baseTileMargin;pos+=titleSize+nextMargin,first=i+1,curItems=0}else if(curItems++,curItems===1&&(first=i),curItems>=tilesPerRow){let tileSize=horizontal?tileWidth.value:tileHeight.value,size$3=tileSize+baseTileMargin,row={pos,size:size$3,first,last:i};layoutCache.rows.push(row),layoutCache.rowPositions.push(pos);for(let j=first;j<=i;j++)layoutCache.itemToRow.set(j,layoutCache.rows.length-1);let nextMargin=items$2.value[i+1]?.isBngListTitle?baseTitleMargin:baseTileMargin;pos+=tileSize+nextMargin,curItems=0,first=i+1}curItems>0&&completeRow(layoutCache.itemCount),pos+=items$2.value[layoutCache.itemCount-1]?.isBngListTitle?baseTitleMargin:baseTileMargin,layoutCache.totalSize=pos,layoutCache.valid=!0,layoutCache.building=!1}function invalidateLayoutCache(){layoutCache.valid=!1,layoutCache.version++}function layoutCacheSearch(arr,target){let left=0,right=arr.length-1;for(;left<=right;){let mid=~~((left+right)/2);arr[mid]<=target?left=mid+1:right=mid-1}return Math.max(0,right)}async function getBigProps(pos=void 0,index=void 0,overflow=void 0){let count$1=items$2.value.length;if(count$1===0)return;if((!layoutCache.valid||layoutCache.itemCount!==count$1)&&(await buildLayoutCache(),!layoutCache.valid))return null;(typeof index!=`number`||index<0)&&(index=void 0,typeof pos!=`number`&&(pos=bigmode.getPos[layoutSelected.value]()));let contSize=layoutSelected.value===LIST_LAYOUTS.RIBBON?contWidth:contHeight;typeof overflow!=`number`&&(overflow=bigmode.overflow);let overflowBefore=Math.ceil(overflow/2),overflowAfter=Math.floor(overflow/2),firstRow=0,currentPos=0;if(typeof index==`number`&&index>=0){let rowIndex=layoutCache.itemToRow.get(index);rowIndex!==void 0&&(firstRow=rowIndex,currentPos=layoutCache.rows[rowIndex].pos,pos=currentPos)}else firstRow=layoutCacheSearch(layoutCache.rowPositions,pos),currentPos=layoutCache.rows[firstRow]?.pos||0;let extendedFirstRow=firstRow,backwardCount=0;for(let i=firstRow-1;i>=0&&backwardCount=contSize));i++);let overflowCount=0;for(let i=lastRow+1;iprops.keepAlive){let center=big.first+(big.last-big.first)/2,farthest=Array.from(itemsShown.value).sort((a$1,b)=>Math.abs(b-center)-Math.abs(a$1-center)).slice(0,itemsShown.value.size-props.keepAlive);for(let idx of farthest)itemsShown.value.delete(idx)}big.items=Array.from(itemsShown.value).sort((a$1,b)=>a$1-b).map(idx=>{let item=items$2.value[idx];return idx>=big.first&&idx<=big.last?item:{...item,keepAliveStyle:`display: none !important;`}})}else itemsShown.value.size>0&&itemsShown.value.clear();bigmode.items=big.items,itemsView.value=big.items}}function showSkeleton(show=!0){skeletonShown!==show&&(show?elSkeleton.value.style.removeProperty(`display`):(skeletonItems.value=[],elSkeleton.value.style.setProperty(`display`,`none`,`important`)),skeletonShown=show)}async function updSkeleton(){if(!elSkeleton.value||!bigmode.enabled||!bigmode.skeleton||!scrolling.value||items$2.value.length===0||!layoutCache.valid){showSkeleton(!1);return}if(bigmode.first===0&&bigmode.last===items$2.value.length-1){showSkeleton(!1);return}let horizontal=layoutSelected.value===LIST_LAYOUTS.RIBBON,contSize=horizontal?contWidth:contHeight,pos=scrollPos.value,start,end;if(pos=bigmode.position||(end=i,visibleSize+=row.size,visibleSize>=contSize))break}let overflowCount=0;for(let i=end+1;i=bigmode.position);i++)end=i,overflowCount++;let neededSize=contSize+bigmode.skeletonOverflow*(horizontal?tileWidth.value:tileHeight.value),backwardSize=visibleSize;for(;start>0&&backwardSize=contSize));i++);let overflowCount=0;for(let i=end+1;i(openBlock(),createElementBlock(`div`,_hoisted_1$316,[toolbar.value.enabled?withDirectives((openBlock(),createElementBlock(`div`,_hoisted_2$257,[toolbar.value.path?(openBlock(),createBlock(Teleport,{key:0,disabled:!__props.pathTarget,to:__props.pathTarget},[createVNode(unref(bngBreadcrumbs_default),{ref_key:`elPath`,ref:elPath,items:__props.path,limit:__props.pathLimit,blur:!__props.noBackground,onClick:_cache[0]||=itm=>emit$1(`pathClick`,itm)},null,8,[`items`,`limit`,`blur`])],8,[`disabled`,`to`])):(openBlock(),createElementBlock(`div`,_hoisted_3$224)),toolbar.value.layout?(openBlock(),createBlock(Teleport,{key:2,disabled:!__props.layoutSelectorTarget,to:__props.layoutSelectorTarget},[createBaseVNode(`div`,_hoisted_4$192,[createVNode(unref(bngButton_default),{accent:layoutSelected.value===LIST_LAYOUTS.TILES?unref(ACCENTS).outlined:unref(ACCENTS).text,icon:unref(icons).tiles,onClick:_cache[1]||=$event=>layoutSelected.value=LIST_LAYOUTS.TILES},null,8,[`accent`,`icon`]),createVNode(unref(bngButton_default),{accent:layoutSelected.value===LIST_LAYOUTS.LIST?unref(ACCENTS).outlined:unref(ACCENTS).text,icon:unref(icons).listSmall,onClick:_cache[2]||=$event=>layoutSelected.value=LIST_LAYOUTS.LIST},null,8,[`accent`,`icon`])])],8,[`disabled`,`to`])):createCommentVNode(``,!0)],512)),[[vShow,toolbar.value.show]]):createCommentVNode(``,!0),withDirectives((openBlock(),createElementBlock(`div`,{ref_key:`elCont`,ref:elCont,class:normalizeClass({"list-content":!0,"list-with-background":!__props.noBackground,[`list-layout-${layoutSelected.value}`]:!0,"list-item-width":!!tileWidth.value,"list-item-height":!!tileHeight.value,"list-item-margin":!!tileMargin.value,"list-title-width":!!titleWidth.value,"list-title-height":!!titleHeight.value,"list-title-margin":!!titleMargin.value,"list-big":bigmode.enabled,"list-scrolling":scrolling.value||bigmode.debounce===0,"list-processing":processing.value}),style:normalizeStyle({"--list-item-width":`${tileWidth.value}px`,"--list-item-height":`${tileHeight.value}px`,"--list-item-margin":`${tileMargin.value}px`,"--list-title-width":`${titleWidth.value}px`,"--list-title-height":`${titleHeight.value}px`,"--list-title-margin":`${titleMargin.value}px`,"--list-big-full":`${bigmode.full}px`}),onScroll:onScrollDebounce},[createBaseVNode(`div`,{ref_key:`elSize`,ref:elSize,class:`list-content-size-observer`},null,512),bigmode.enabled&&bigmode.skeleton?(openBlock(),createElementBlock(`div`,{key:0,ref_key:`elSkeleton`,ref:elSkeleton,class:`list-skeleton`},[(openBlock(!0),createElementBlock(Fragment,null,renderList(skeletonItems.value,(isTitle,i)=>(openBlock(),createElementBlock(`div`,{key:`skeleton-${i}`,class:normalizeClass({"skeleton-item":!0,"skeleton-title":isTitle})},null,2))),128))],512)):createCommentVNode(``,!0),createBaseVNode(`div`,{class:`list-items`,style:normalizeStyle(listItemsStyle.value)},[(openBlock(!0),createElementBlock(Fragment,null,renderList(itemsView.value,vnode=>(openBlock(),createBlock(resolveDynamicComponent(vnode),{key:vnode.key,style:normalizeStyle(vnode.keepAliveStyle)},null,8,[`style`]))),128))],4)],38)),[[unref(BngBlur_default),!__props.noBackground]])]))}},bngList_default=__plugin_vue_export_helper_default(_sfc_main$361,[[`__scopeId`,`data-v-5af5eff2`]]),_hoisted_1$315={class:`bng-stars`},_hoisted_2$256={key:0,class:`stars`},_hoisted_3$223=[`innerHTML`],_hoisted_4$191=[`innerHTML`],_hoisted_5$163={key:1,class:`stars`},_hoisted_6$140={class:`stars-label`},_hoisted_7$122=[`innerHTML`],_sfc_main$360={__name:`bngMainStars`,props:{unlockedStars:{type:Number,default:0,validator:val=>val>=0},totalStars:{type:Number,default:1},scale:{type:Number,default:1},individualStars:{type:Object,default:null,validator:val=>val===null||Array.isArray(val)},numerical:{type:Boolean,default:!1}},setup(__props){useCssVars(_ctx=>({v3c930dd6:fontSize.value}));let props=__props,fontSize=computed(()=>`${props.scale}rem`),starsTotal=computed(()=>props.individualStars?props.individualStars.length:props.totalStars),starsFilled=computed(()=>props.individualStars?props.individualStars.filter(Boolean).length:props.unlockedStars),starsUnfilled=computed(()=>starsTotal.value-starsFilled.value),glyphsFilled=computed(()=>starsFilled.value>0?icons.star.glyph.repeat(starsFilled.value):``),glyphsUnfilled=computed(()=>starsUnfilled.value>0?icons.star.glyph.repeat(starsUnfilled.value):``);return(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$315,[!__props.numerical&&__props.individualStars&&__props.individualStars.length?(openBlock(),createElementBlock(`div`,_hoisted_2$256,[starsFilled.value?(openBlock(),createElementBlock(`span`,{key:0,class:`star star-filled`,innerHTML:glyphsFilled.value},null,8,_hoisted_3$223)):createCommentVNode(``,!0),starsUnfilled.value?(openBlock(),createElementBlock(`span`,{key:1,class:`star star-unfilled`,innerHTML:glyphsUnfilled.value},null,8,_hoisted_4$191)):createCommentVNode(``,!0)])):(openBlock(),createElementBlock(`div`,_hoisted_5$163,[createBaseVNode(`div`,_hoisted_6$140,toDisplayString(starsFilled.value)+` / `+toDisplayString(starsTotal.value),1),createBaseVNode(`span`,{class:`star star-filled`,innerHTML:unref(icons).star.glyph},null,8,_hoisted_7$122)]))]))}},bngMainStars_default=__plugin_vue_export_helper_default(_sfc_main$360,[[`__scopeId`,`data-v-4ba4c794`]]),_hoisted_1$314=[`rows`,`placeholder`,`disabled`],_hoisted_2$255={key:0,class:`floating-label`},_sfc_main$359={__name:`bngMultilineInput`,props:{floatingLabel:String,externalLabel:String,placeholder:String,initialValue:String,leadingIcon:Object,trailingIcon:Object,scalable:Boolean,hasError:Boolean,errorMessage:String,lines:{type:Number,default:1},disabled:{type:Boolean,default:!1}},setup(__props){useCssVars(_ctx=>({v26daab40:bngScalableInputMaxWidth.value}));let props=__props,inputContainer=ref(null),bngMultilineInput=ref(null),focusHighlight=ref(null),leadingIconContainer=ref(null),trailingIconContainer=ref(null),value=ref(``),isInputFieldFocused=ref(!1),hasValue=computed(()=>value.value!==``&&value.value!==void 0),bngScalableInputMaxWidth=computed(()=>`${(leadingIconContainer.value?leadingIconContainer.value.offsetWidth:0)+(trailingIconContainer.value?trailingIconContainer.value.offsetWidth:0)}px`),resizeObserver;onBeforeMount(()=>{value.value=props.initialValue,resizeObserver=new ResizeObserver(onInputResize)}),onMounted(()=>{resizeObserver.observe(bngMultilineInput.value)}),onDeactivated(()=>{resizeObserver.disconnect()});function onInputFieldFocusIn(){isInputFieldFocused.value=!0}function onInputFieldFocusOut(){isInputFieldFocused.value=!1}function onInputResize(){inputContainer.value&&window.requestAnimationFrame(()=>{let focusRight=inputContainer.value.offsetWidth-inputContainer.value.offsetWidth;focusHighlight.value.style.right=`${focusRight-2}px`})}return(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,{class:normalizeClass([`input-icon-wrapper`,{scalable:__props.scalable}])},[__props.leadingIcon?(openBlock(),createElementBlock(`span`,{key:0,ref_key:`leadingIconContainer`,ref:leadingIconContainer,class:`input-icon`},[createVNode(unref(bngIcon_default),{type:__props.leadingIcon},null,8,[`type`])],512)):createCommentVNode(``,!0),createBaseVNode(`div`,{ref_key:`inputContainer`,ref:inputContainer,class:normalizeClass([`bng-multiline-input`,{"input-focused":isInputFieldFocused.value,"has-error":__props.hasError}]),tabindex:`0`},[withDirectives(createBaseVNode(`textarea`,{"onUpdate:modelValue":_cache[0]||=$event=>value.value=$event,ref_key:`bngMultilineInput`,ref:bngMultilineInput,class:normalizeClass([`input-field`,{empty:!hasValue.value,"has-value":hasValue.value,"has-error":__props.hasError,disabled:__props.disabled}]),rows:__props.lines,placeholder:__props.floatingLabel,disabled:__props.disabled,onFocusin:onInputFieldFocusIn,onFocusout:onInputFieldFocusOut},null,42,_hoisted_1$314),[[vModelText,value.value],[unref(BngTextInput_default)]]),__props.floatingLabel?(openBlock(),createElementBlock(`span`,_hoisted_2$255,toDisplayString(__props.floatingLabel),1)):createCommentVNode(``,!0),createBaseVNode(`span`,{ref_key:`focusHighlight`,ref:focusHighlight,class:`focus-highlight`},null,512)],2),__props.trailingIcon?(openBlock(),createElementBlock(`span`,{key:1,ref_key:`trailingIconContainer`,ref:trailingIconContainer,class:`input-icon`},[createVNode(unref(bngIcon_default),{type:__props.trailingIcon},null,8,[`type`])],512)):createCommentVNode(``,!0)],2))}},bngMultilineInput_default=__plugin_vue_export_helper_default(_sfc_main$359,[[`__scopeId`,`data-v-6c6cfdb8`]]);const icons$1={undefined:`undefined`,arrow:{large:{up:`arrow/large_up`,down:`arrow/large_down`,left:`arrow/large_left`,right:`arrow/large_right`},small:{up:`arrow/arrowSmallUp`,down:`arrow/arrowSmallDown`,left:`arrow/arrowSmallLeft`,right:`arrow/arrowSmallRight`}},drive:{autobahn:`drive/autobahn`,busroutes:`drive/busroutes`,campaigns:`drive/campaigns`,career:`drive/career`,freeroam:`drive/freeroam`,garage:`drive/garage`,infinity:`drive/infinity`,lightrunner:`drive/lightrunner`,m_a:`drive/m_a`,m_b:`drive/m_b`,m_c:`drive/m_c`,play:`drive/play`,quit:`drive/quit`,scenarios:`drive/scenarios`,timetrials:`drive/timetrials`},general:{offbtn:`general/offbtn`,unknown:`general/unknown`,check:`general/check`,recharge:`general/recharge`,refuel:`general/refuel`,beambuck:`general/beambuck`,money:`general/beambuck`,beamXP:`general/beamXP`,arrow_small_left:`general/arrow_small-left`,arrow_small_right:`general/arrow_small-right`,fuel_nozzle:`general/fuel-nozzle`,recharge_connector:`general/recharge-connector`,star:`general/star`,star_outlined:`general/star-secondary`,vehicle:`general/vehicle`,awd:`general/awd`,"4wd":`general/4wd`,fwd:`general/fwd`,rwd:`general/rwd`,drivetrain_special:`general/drivetrain-special`,drivetrain_generic:`general/drivetrain-generic`,charge:`general/charge`,fuel:`general/fuel`,odometer:`general/odometer`,power_gauge_01:`general/power-gauge-01c`,power_gauge_02:`general/power-gauge-02c`,power_gauge_03:`general/power-gauge-03c`,power_gauge_04:`general/power-gauge-04c`,power_gauge_05:`general/power-gauge-05c`,weight:`general/weight`,transmission_a:`general/transmission-a`,transmission_m:`general/transmission-m`},device:{keyboard:`device/keyboard`,phone_android:`device/phone_android`,wheel:`device/wheel`,gamepad:`device/gamepad`,videogame_asset:`device/videogame_asset`,mouse:{button0:`device/mouse/button0`,button1:`device/mouse/button1`,button2:`device/mouse/button2`,xaxis:`device/mouse/xaxis`,yaxis:`device/mouse/yaxis`,zaxis:`device/mouse/zaxis`},xbox:{btn_a:`device/xbox/btn_a`,btn_b:`device/xbox/btn_b`,btn_back:`device/xbox/btn_back`,btn_lb:`device/xbox/btn_lb`,btn_lt:`device/xbox/btn_lt`,btn_rb:`device/xbox/btn_rb`,btn_rt:`device/xbox/btn_rt`,btn_start:`device/xbox/btn_start`,btn_x:`device/xbox/btn_x`,btn_y:`device/xbox/btn_y`,btn_dpad_default_filled:`device/xbox/btn_dpad_default_filled`,btn_dpad_default_outline:`device/xbox/btn_dpad_default_outline`,btn_dpad_down:`device/xbox/btn_dpad_down`,btn_dpad_left:`device/xbox/btn_dpad_left`,btn_dpad_right:`device/xbox/btn_dpad_right`,btn_dpad_up:`device/xbox/btn_dpad_up`,btn_thumb_left:`device/xbox/btn_thumb_left`,btn_thumb_left_x:`device/xbox/btn_thumb_left_x`,btn_thumb_left_y:`device/xbox/btn_thumb_left_y`,btn_thumb_right:`device/xbox/btn_thumb_right`,btn_thumb_right_x:`device/xbox/btn_thumb_right_x`,btn_thumb_right_y:`device/xbox/btn_thumb_right_y`}},decals:{camera:{back:`decals/camera/back`,freecam:`decals/camera/freecam`,front:`decals/camera/front`,left:`decals/camera/left`,right:`decals/camera/right`,top:`decals/camera/top`},general:{change_order:`decals/general/change_order`,deform:`decals/general/deform`,delete:`decals/general/delete`,duplicate:`decals/general/duplicate`,hide:`decals/general/hide`,lock:`decals/general/lock`,mirror:`decals/general/mirror`,options:`decals/general/options`,redo:`decals/general/redo`,rename:`decals/general/rename`,save:`decals/general/save`,transform:`decals/general/transform`,undo:`decals/general/undo`,unlock:`decals/general/unlock`,use_mask:`decals/general/mask`},group:{group:`decals/group/group`,ungroup:`decals/group/ungroup`},layer:{decal:`decals/layer/decal`,material:`decals/layer/material`},mirror:{copy_mirrored:`decals/mirror/copy_mirrored`,copy_straight:`decals/mirror/copy_straight`}}},iconTypesList=makeIconTypesList(icons$1);function makeIconTypesList(dict){let key,all=[];for(key in dict)all=all.concat(typeof dict[key]==`string`?dict[key]:makeIconTypesList(dict[key]));return all}var _hoisted_1$313=[`src`],_sfc_main$358={__name:`bngOldIcon`,props:{type:{type:String,validator:v=>iconTypesList.includes(v)},span:{type:Boolean,default:!0},mask:{type:Boolean,default:!0},color:String},setup(__props){let props=__props,iconImageURL=computed(()=>getAssetURL(`icons/${props.type}.svg`)),spanStyle=computed(()=>({[props.mask?`maskImage`:`backgroundImage`]:`url(${iconImageURL.value})`,backgroundColor:props.color||`#fff`}));return(_ctx,_cache)=>__props.span?(openBlock(),createElementBlock(`span`,{key:0,class:`bngicon`,style:normalizeStyle(spanStyle.value)},[renderSlot(_ctx.$slots,`default`,{},void 0,!0)],4)):(openBlock(),createElementBlock(`img`,{key:1,class:`bngicon`,src:iconImageURL.value,alt:``},null,8,_hoisted_1$313))}},bngOldIcon_default=__plugin_vue_export_helper_default(_sfc_main$358,[[`__scopeId`,`data-v-da0e0a74`]]),_hoisted_1$312=[`bng-no-child-nav`],scrollBuildupTime=3e3,scrollMaxSpeedModifier=4,CLICKID=`__bngOverflowContainer`,_sfc_main$357={__name:`bngOverflowContainer`,props:{scrollSpeed:{type:Number,default:5},initialIndex:{type:Number,default:-1},useBindings:[Boolean,Array],useBindingsOnly:[Boolean,Array],showBindings:{type:Boolean,default:!0},showArrows:{type:Boolean,default:!1},noWheel:{type:Boolean,default:!1}},setup(__props,{expose:__expose}){let slots=useSlots(),props=__props,useBindings=props.useBindings||props.useBindingsOnly,useBindingsOnly=props.useBindingsOnly;watch([()=>props.useBindings,()=>props.useBindingsOnly],()=>console.warn(`useBindings and useBindingsOnly can only be set at component mount time`));let uinavBound=!1,focusNav=useBindings&&Array.isArray(useBindings)?useBindings:[`tab_l`,`tab_r`],elBindPrev=ref(null),elBindNext=ref(null),elCont=ref(null),scrollContainer=ref(null),showLeftFade=ref(!1),showRightFade=ref(!1),resizeObserver=new ResizeObserver(updateFadeVisibility),scrollInterval=null,scrollTime=0,lastActive=null,fixingActive=!1;function setActive(elm){clearActive(),elm instanceof Element&&(elm.setAttribute(`active`,`true`),lastActive=elm)}function clearActive(evt){lastActive&&(evt&&(evt.detail?.target||evt.target)===lastActive||(lastActive.removeAttribute(`active`),lastActive=null))}function fixActive(evt){if(fixingActive||useBindings&&evt.type===`focusin`)return;let active=evt.detail?.target||evt.target||document.activeElement;if(active.matches(`[is-bng-panel], [bng-nav-item], [ng-click], [href], [bng-all-clicks], [bng-all-clicks-no-nav], [ui-sref], input, textarea, button, md-option, md-slider, md-select, md-checkbox`)||(active=active.closest(NAVIGABLE_ELEMENTS_SELECTOR)),scrollContainer.value.contains(active)&&!(lastActive&&(lastActive===active||lastActive.contains(active)))){if(useBindingsOnly){fixingActive=!0;let prev=evt.detail.relatedTarget||evt.relatedTarget;prev&&scrollContainer.value.contains(prev)&&(prev=null),prev?setFocusExternal(prev,!0):setFocusExternal(active,!1)}nextTick(()=>{setActive(active),fixingActive=!1})}}let firstTime=!0;function updateContents(){if(!scrollContainer.value)return;let elFirst;for(let elm of scrollContainer.value.children)firstTime&&!elFirst&&(elFirst=elm),!elm[CLICKID]&&(elm[CLICKID]=!0,elm.addEventListener(`click`,fixActive));firstTime&&elFirst&&props.initialIndex>-1&&(firstTime=!1,elFirst.matches(`[is-bng-panel], [bng-nav-item], [ng-click], [href], [bng-all-clicks], [bng-all-clicks-no-nav], [ui-sref], input, textarea, button, md-option, md-slider, md-select, md-checkbox`)||(elFirst=elFirst.querySelector(NAVIGABLE_ELEMENTS_SELECTOR)),elFirst&&activate(elFirst))}watch([()=>slots.default?.(),()=>scrollContainer.value],()=>nextTick(updateContents),{immediate:!0});function navContents(dir,fireClick=!1){let links=collectRects(dir,scrollContainer.value,useBindingsOnly),prev=lastActive;clearActive();let res;if(useBindingsOnly){let idx=links[dir].findIndex(link=>link.dom===prev);idx>-1?res=links[dir][dir===`right`?idx+1:idx-1]:idx===0&&dir===`left`?res=links[dir][links[dir].length-1]:idx===links[dir].length-1&&dir===`right`&&(res=links[dir][0]),res&&(setActive(res.dom),scrollFix(res,dir))}else prev&&(res=navigate(links,dir,prev),res&&setActive(res));res?fireClick&&(res.dom&&(res=res.dom),nextTick(()=>res?.dispatchEvent(new Event(`click`)))):(scrollContainer.value.scrollTo({left:dir===`right`?0:scrollContainer.value.clientWidth,behavior:`instant`}),nextTick(()=>{let elms$4=collectRects(`right`,scrollContainer.value,!0).right;dir===`left`&&elms$4.reverse(),res=elms$4[0],res&&(setActive(res.dom),useBindingsOnly?scrollFix(res,dir):setFocusExternal(res.dom),fireClick&&res.dom.dispatchEvent(new Event(`click`)))}))}let activatePrev=()=>navContents(`left`,!0),activateNext=()=>navContents(`right`,!0);function activate(indexOrElement){let elm;if(typeof indexOrElement==`number`){let elms$4=scrollContainer.value.querySelectorAll(NAVIGABLE_ELEMENTS_SELECTOR);indexOrElement<0&&(indexOrElement=elms$4.length+indexOrElement),elm=elms$4[indexOrElement]}else if(indexOrElement instanceof Element)elm=indexOrElement;else throw Error(`Invalid argument`);if(!elm)throw Error(`Element not found`);scrollFix({dom:elm,rect:elm.getBoundingClientRect()},`right`),setActive(elm),!useBindingsOnly&&setFocusExternal(elm)}if(__expose({scrollBy:amount=>scrollContainer.value?.scrollBy({left:amount,behavior:`smooth`}),activatePrev,activateNext,activate,deactivate:()=>{let active=document.activeElement,activeCorrect=active&&active===lastActive;clearActive(),activeCorrect&&(useBindingsOnly&&setFocusExternal(active,!1),active.blur?.())},refresh:(withActivation=!1)=>{withActivation&&(firstTime=!0),updateContents()}}),useBindings){let instance$1=getCurrentInstance(),contUnwatch=watch(()=>elCont.value,elm=>{elm&&(contUnwatch(),nextTick(()=>{uinavBound=!0;let vnode={ctx:instance$1,el:elm};BngOnUiNav_default.mounted(elm,{arg:focusNav[0],modifiers:{},value:activatePrev},vnode),BngOnUiNav_default.mounted(elm,{arg:focusNav[1],modifiers:{},value:activateNext},vnode),elm.addEventListener(`focusin`,fixActive)}))},{immediate:!0})}watch(scrollContainer,elm=>{elm&&(updateFadeVisibility(),resizeObserver.observe(elm))},{immediate:!0});function updateFadeVisibility(){if(!scrollContainer.value)return;let{scrollLeft,scrollWidth,clientWidth}=scrollContainer.value;showLeftFade.value=scrollLeft>0,showRightFade.value=scrollLeft{let speedModifier=Math.min(1+(scrollMaxSpeedModifier-1)*(scrollTime/scrollBuildupTime),scrollMaxSpeedModifier),scrollAmount=(direction$1===`left`?-props.scrollSpeed:props.scrollSpeed)*speedModifier;scrollContainer.value.scrollLeft+=scrollAmount,updateFadeVisibility(),scrollTime+=1e3/30},1e3/30)}function stopScrolling(){scrollInterval&&=(clearInterval(scrollInterval),null),scrollTime=0}function onWheel(evt){props.noWheel||(evt.preventDefault(),scrollContainer.value.scrollLeft+=evt.deltaY,updateFadeVisibility())}function onScroll(){updateFadeVisibility()}return onBeforeUnmount(()=>{resizeObserver.disconnect(),stopScrolling(),uinavBound&&(BngOnUiNav_default.beforeUnmount(elCont.value),elCont.value.removeEventListener(`focusin`,fixActive))}),(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,{ref_key:`elCont`,ref:elCont,class:normalizeClass([`bng-overflow-container`,{"with-bindings":unref(useBindings)&&(elBindPrev.value?.displayed||elBindNext.value?.displayed),"with-arrows":__props.showArrows&&!(elBindPrev.value?.displayed||elBindNext.value?.displayed),"hide-bindings":!__props.showBindings}]),onWheel},[withDirectives(createBaseVNode(`div`,{class:`fade-left`,onMouseenter:_cache[0]||=$event=>startScrolling(`left`),onMouseleave:stopScrolling},null,544),[[vShow,showLeftFade.value]]),withDirectives(createBaseVNode(`div`,{class:`fade-right`,onMouseenter:_cache[1]||=$event=>startScrolling(`right`),onMouseleave:stopScrolling},null,544),[[vShow,showRightFade.value]]),__props.showArrows&&!elBindPrev.value?.displayed?(openBlock(),createBlock(unref(bngIcon_default),{key:0,type:unref(icons).arrowLargeLeft,class:`hint-prev`},null,8,[`type`])):createCommentVNode(``,!0),__props.showArrows&&!elBindNext.value?.displayed?(openBlock(),createBlock(unref(bngIcon_default),{key:1,type:unref(icons).arrowLargeRight,class:`hint-next`},null,8,[`type`])):createCommentVNode(``,!0),unref(useBindings)?(openBlock(),createBlock(unref(bngBinding_default),{key:2,ref_key:`elBindPrev`,ref:elBindPrev,class:`hint-prev`,"ui-event":unref(focusNav)[0],controller:``},null,8,[`ui-event`])):createCommentVNode(``,!0),unref(useBindings)?(openBlock(),createBlock(unref(bngBinding_default),{key:3,ref_key:`elBindNext`,ref:elBindNext,class:`hint-next`,"ui-event":unref(focusNav)[1],controller:``},null,8,[`ui-event`])):createCommentVNode(``,!0),createBaseVNode(`div`,{ref_key:`scrollContainer`,ref:scrollContainer,class:`scroll-container`,"bng-no-child-nav":unref(useBindingsOnly),onScroll},[renderSlot(_ctx.$slots,`default`,{},void 0,!0)],40,_hoisted_1$312)],34))}},bngOverflowContainer_default=__plugin_vue_export_helper_default(_sfc_main$357,[[`__scopeId`,`data-v-24544cbf`]]);const rainbow=(numOfSteps,step)=>{let r,g,b,h$1=step/numOfSteps,i=~~(h$1*6),f=h$1*6-i,q=1-f;switch(i%6){case 0:[r,g,b]=[1,f,0];break;case 1:[r,g,b]=[q,1,0];break;case 2:[r,g,b]=[0,1,f];break;case 3:[r,g,b]=[0,q,1];break;case 4:[r,g,b]=[f,0,1];break;case 5:[r,g,b]=[1,0,q];break}return[r,g,b]},hueToRGB=(p$1,q,t)=>(t<0&&(t+=1),t>1&&--t,t<1/6?p$1+(q-p$1)*6*t:t<1/2?q:t<2/3?p$1+(q-p$1)*(2/3-t)*6:p$1),HSLToRGB=(h$1,s,l)=>{let r,g,b;if(s===0)r=g=b=l;else{let q=l<.5?l*(1+s):l+s-l*s,p$1=2*l-q;r=hueToRGB(p$1,q,h$1+1/3),g=hueToRGB(p$1,q,h$1),b=hueToRGB(p$1,q,h$1-1/3)}return[r,g,b]},RGBToHSL=(r,g,b)=>{let vmax=Math.max(r,g,b),vmin=Math.min(r,g,b),h$1,s,l=(vmax+vmin)/2;if(vmax===vmin)return[0,0,l];let d=vmax-vmin;return s=l>.5?d/(2-vmax-vmin):d/(vmax+vmin),vmax===r&&(h$1=(g-b)/d+(gnum;else if(val<=15){let prec=10**val;this._precision=num=>~~(num*prec)/prec}else throw TypeError(`Precision can't go higher than 15`)}_sync({hsl=!1,rgb=!1}={}){if(hsl&&rgb)throw Error(`Cannot set both HSL and RGB changes at once`);this._dirty.hsl&&!hsl?this._rgb=HSLToRGB(...this._hsl):this._dirty.rgb&&!rgb&&(this._hsl=RGBToHSL(...this._rgb)),this._dirty.hsl=hsl,this._dirty.rgb=rgb}_parse(val){let res;if(isProxy(val)&&(val=toRaw(val)),typeof val==`string`&&(val=val.split(` `)),typeof val==`object`&&Array.isArray(val)){if(val.length<3)throw Error(`Invalid colour array length`);val.length===3&&(val=[...val,1]),val=val.map(Number);for(let num of val)if(isNaN(num))throw Error(`Values must be numbers`);res=val}if(!res)throw Error(`Color must be either an array or a string`);return res}get hslString(){return this.hsl.join(` `)}get hslaString(){return this.hsla.join(` `)}get rgbString(){return this.rgb.join(` `)}get rgbaString(){return this.rgba.join(` `)}get saturationPercent(){return Math.round(this.saturation*100)}get luminosityPercent(){return Math.round(this.luminosity*100)}get alphaPercent(){return Math.round(this._alpha*50)}get metallicPercent(){return Math.round(this._metallic*100)}get roughnessPercent(){return Math.round(this._roughness*100)}get clearcoatPercent(){return Math.round(this._clearcoat*100)}get clearcoatRoughnessPercent(){return Math.round(this._clearcoatRoughness*100)}get paint(){return[...this._legacy?this.rgba:this.rgb,this.metallic,this.roughness,this.clearcoat,this.clearcoatRoughness].map(this._precision)}get paintString(){return this.paint.join(` `)}get paintObject(){return this._paintObjectNames.reduce((res,name)=>({...res,[name]:this[name]}),{})}set paint(val){let data;if(isProxy(val)&&(val=toRaw(val)),typeof val==`object`){if(!Array.isArray(val)){data={...val};let names=this._paintObjectNames;for(let name of names){if(name===`baseColor`){this.baseColor=name in data?data[name]:[1,1,1,1];continue}let num=0;name in data&&(num=Number(data[name]),isNaN(num)&&(num=0)),this[name]=num}return}data=val}else if(typeof val==`string`)data=val.split(` `);else throw TypeError(`Invalid data type`);if(data.length===8)this.rgba=data.slice(0,4);else if(data.length===7)this.rgb=data.slice(0,3);else throw TypeError(`Invalid data value`);[this._metallic,this._roughness,this._clearcoat,this._clearcoatRoughness]=data.slice(-4)}get metallic(){return this._precision(this._metallic)}set metallic(val){this._metallic=Number(val)}get roughness(){return this._precision(this._roughness)}set roughness(val){this._roughness=Number(val)}get clearcoat(){return this._precision(this._clearcoat)}set clearcoat(val){this._clearcoat=Number(val)}get clearcoatRoughness(){return this._precision(this._clearcoatRoughness)}set clearcoatRoughness(val){this._clearcoatRoughness=Number(val)}get alpha(){return this._precision(this._alpha)}set alpha(val){let type=typeof val;type!==`undefined`&&(type===`number`?this._alpha=val:this._alpha=Number(val))}get hsl(){return this._sync(),this._hsl.map(this._precision)}set hsl(val){let arr=this._parse(val);this._sync({hsl:!0}),this._hsl=arr.slice(0,3),this.alpha=arr[3]}get rgb(){return this._sync(),this._rgb.map(this._precision)}get rgb255(){return this.rgb.map(val=>Math.round(val*255))}set rgb(val){let arr=this._parse(val);this._sync({rgb:!0}),this._rgb=arr.slice(0,3),this.alpha=arr[3]}set rgb255(val){let arr=this._parse(val);this.rgb=[...arr.slice(0,3).map(val$1=>val$1/255),arr[3]]}get hsla(){return[...this.hsl,this.alpha]}set hsla(val){this.hsl=val}get rgba(){return[...this.rgb,this.alpha]}set rgba(val){this.rgb=val}get baseColor(){return this.rgba}set baseColor(val){this.rgba=val}get hue(){return this.hsl[0]}get hue360(){return this.hsl[0]*360}set hue(val){this._sync({hsl:!0}),this._hsl[0]=Number(val)}set hue360(val){this.hue=Number(val)/360}get saturation(){return this.hsl[1]}set saturation(val){this._sync({hsl:!0}),this._hsl[1]=Number(val)}get luminosity(){return this.hsl[2]}set luminosity(val){this._sync({hsl:!0}),this._hsl[2]=Number(val)}get red(){return this.rgb[0]}get red255(){return this.rgb[0]*255}set red(val){this._sync({rgb:!0}),this._rgb[0]=Number(val)}set red255(val){this.red=Number(val)/255}get green(){return this.rgb[1]}get green255(){return this.rgb[1]*255}set green(val){this._sync({rgb:!0}),this._rgb[1]=Number(val)}set green255(val){this.green=Number(val)/255}get blue(){return this.rgb[2]}get blue255(){return this.rgb[2]*255}set blue(val){this._sync({rgb:!0}),this._rgb[2]=Number(val)}set blue255(val){this.blue=Number(val)/255}static anyToArray(val,legacy=!1){if(Array.isArray(val)){let checks=[val$1=>val$1 instanceof Paint,val$1=>typeof val$1==`object`&&Array.isArray(val$1.baseColor),val$1=>typeof val$1==`string`&&val$1.split(` `).length>=7,val$1=>Array.isArray(val$1)&&val$1.length>=7];if(val.some(item=>checks.some(check=>check(item))))return val.map(item=>Paint.anyToArray(item,legacy))}let precision=val$1=>{let num=Number(val$1);return isNaN(num)?val$1:~~(num*1e4)/1e4};return Array.isArray(val)?val.map(precision):typeof val==`string`?val.split(` `).map(precision):val instanceof Paint?val.paint:typeof val==`object`&&val.baseColor?[...legacy?val.baseColor:val.baseColor.slice(0,3),val.metallic,val.roughness,val.clearcoat,val.clearcoatRoughness].map(precision):val}static hslCssStr(arr){return`${Math.round(arr[0]*360)}, ${Math.round(arr[1]*100)}%, ${Math.round(arr[2]*100)}%`}static rgbToHsl(rgb){return RGBToHSL(...rgb)}static hslToRgb(hsl){return HSLToRGB(...hsl)}},CACHE_LIMIT=200,TILE_SIZE=64,MULTI_ANGLE=23,MAX_CONCURRENT_RENDERS=20,QUEUE_INTERVAL=10,reflectionImageUrl=`/ui/ui-vue/src/assets/images/paint-reflection.jpg`,reflectionImage=null,reflectionImageDone=!1,renderCancelledError=Error(`Render cancelled`),cacheCleanedError=Error(`Cache cleared`);function hashPaintData(paintData){return paintData?(paintData=Paint.anyToArray(paintData,!1),Array.isArray(paintData)?Array.isArray(paintData[0])?paintData.map(paint=>Array.isArray(paint)?paint.join(`,`):``).join(`|`):paintData.join(`,`):JSON.stringify(paintData)):``}var checkMultipaint=paintData=>Array.isArray(paintData)&&paintData.length>0&&paintData.some(item=>Array.isArray(item)&&item.length>=7);const usePaintPreviews=defineStore(`paint-previews`,()=>{let previews=ref(new Map),pendingRenders=ref(new Map),renderQueue=ref([]),activeRenders=ref(0),cacheListeners=new Set,pendingBlobCleanup=new Set,queueProcessor=null,blobCleanupTimeout=null;{let img=new Image;img.onload=()=>{reflectionImage=img,reflectionImageDone=!0},img.onerror=()=>{console.warn(`Failed to load metallic reflection image`),reflectionImageDone=!0},img.src=reflectionImageUrl}function startQueue(eager=!1){if(queueProcessor||renderQueue.value.length===0)return;let run$1=()=>{renderQueue.value.length===0?stopQueue():activeRenders.value0||activeRenders.value>0)return!1;for(let entry of previews.value.values())if(entry.blobGenerating)return!1;return!0}function blobCleanup(){blobCleanupTimeout&&clearTimeout(blobCleanupTimeout),blobCleanupTimeout=setTimeout(()=>{if(blobCleanupTimeout=null,isSystemIdle()&&pendingBlobCleanup.size>0){for(let blobUrl of pendingBlobCleanup)URL.revokeObjectURL(blobUrl);pendingBlobCleanup.clear()}},1e3)}async function processQueue({key,paintData,opts,resolve:resolve$1,reject,aborter}){activeRenders.value++;try{let checkAborted=()=>{if(aborter.signal.aborted)throw renderCancelledError};checkAborted();let width$1=opts.width||TILE_SIZE,height$1=opts.height||TILE_SIZE,areas=calculatePaintAreas(paintData,width$1,height$1),cvs=await renderPaint(paintData,width$1,height$1,opts.radialLight||!1,areas,aborter);checkAborted();let bmp=await createImageBitmap(cvs);if(previews.value.size>=CACHE_LIMIT){let oldestKey=previews.value.keys().next().value;cleanupCacheEntry(previews.value.get(oldestKey)),previews.value.delete(oldestKey)}checkAborted(),previews.value.set(key,{bitmap:bmp,paintData,paintHash:hashPaintData(paintData),areas}),resolve$1(bmp)}catch(err){err!==renderCancelledError&&reject(err)}finally{pendingRenders.value.has(key)&&pendingRenders.value.get(key).aborter===aborter&&pendingRenders.value.delete(key),activeRenders.value--}}function getCacheKey({paintId,vehicleName,paintName,width:width$1=TILE_SIZE,height:height$1=TILE_SIZE,radialLight=!1}){if(paintId)return`paint#${paintId}@${width$1}x${height$1}${radialLight?`R`:`L`}`;if(vehicleName&&paintName)return`vehicle:${vehicleName}:${paintName}@${width$1}x${height$1}${radialLight?`R`:`L`}`;throw Error(`Either paintId or vehicleName+paintName must be provided`)}function isCached(opts,paintData){try{let key=getCacheKey(opts),data=previews.value.get(key);return data?!paintData||data.paintHash===hashPaintData(paintData):!1}catch{return!1}}function getCachedPreview(opts,paintData){try{let key=getCacheKey(opts),data=previews.value.get(key);return data?data.paintHash===hashPaintData(paintData)?data.bitmap:(cleanupCacheEntry(data),previews.value.delete(key),null):null}catch{return null}}async function generatePreview(paintData,opts){let key=getCacheKey(opts),paintHash=hashPaintData(paintData);if(pendingRenders.value.has(key)){let existing=pendingRenders.value.get(key);if(existing.paintHash===paintHash)return new Promise((resolve$1,reject)=>existing.others.push({resolve:resolve$1,reject}));{existing.aborter.abort(),renderQueue.value=renderQueue.value.filter(item=>!(item.key===key&&item.aborter===existing.aborter));let aborter$1=new AbortController,others$1=[...existing.others];return pendingRenders.value.set(key,{paintHash,others:others$1,aborter:aborter$1}),new Promise((resolve$1,reject)=>{others$1.push({resolve:resolve$1,reject}),renderQueue.value.unshift({key,paintData:Paint.anyToArray(paintData),opts,resolve:result=>others$1.forEach(p$1=>p$1.resolve(result)),reject:error=>others$1.forEach(p$1=>p$1.reject(error)),aborter:aborter$1}),startQueue(!0)})}}let aborter=new AbortController,others=[];return pendingRenders.value.set(key,{paintHash,others,aborter}),new Promise((resolve$1,reject)=>{others.push({resolve:resolve$1,reject}),renderQueue.value.push({key,paintData:Paint.anyToArray(paintData),opts,resolve:result=>{others.forEach(p$1=>p$1.resolve(result))},reject:error=>{others.forEach(p$1=>p$1.reject(error))},aborter}),startQueue()})}function cleanupCacheEntry(data){data&&(data.bitmap?.close?.(),data.blobUrl&&pendingBlobCleanup.add(data.blobUrl))}function onCacheClear(callback){return cacheListeners.add(callback),()=>cacheListeners.delete(callback)}function notifyCacheCleared(type=`all`,key=null){cacheListeners.forEach(callback=>{try{callback(type,key)}catch(error){console.warn(`Cache clear listener error:`,error)}})}function clearCache(opts=void 0){if(opts)try{let key=getCacheKey(opts);if(cleanupCacheEntry(previews.value.get(key)),previews.value.delete(key),pendingRenders.value.has(key)){let req=pendingRenders.value.get(key);req.aborter.abort(),req.others.forEach(p$1=>p$1.reject(cacheCleanedError)),pendingRenders.value.delete(key)}notifyCacheCleared(`single`,key)}catch{}else stopQueue(),pendingRenders.value.forEach(req=>{req.aborter.abort(),req.others.forEach(p$1=>p$1.reject(cacheCleanedError))}),pendingRenders.value.clear(),previews.value.forEach(cleanupCacheEntry),previews.value.clear(),renderQueue.value.splice(0),activeRenders.value=0,notifyCacheCleared(`all`),startQueue();blobCleanup()}async function getPreview(paintData,opts){return getCachedPreview(opts,paintData)||await generatePreview(paintData,opts)}async function getBlobPreview(paintData,opts){let paintHash=hashPaintData(paintData),key=getCacheKey(opts),bmp=await getPreview(paintData,opts),data=previews.value.get(key);if(!data)return null;if(data.blobUrl&&data.paintHash===paintHash)return data.blobUrl;for(;data.blobGenerating;)await sleep(10);if(data.blobUrl&&data.paintHash===paintHash)return data.blobUrl;data.blobGenerating=!0;let canvas=new OffscreenCanvas(opts.width||TILE_SIZE,opts.height||TILE_SIZE);canvas.getContext(`2d`).drawImage(bmp,0,0);let blobUrl=URL.createObjectURL(await canvas.convertToBlob()),oldBlobUrl=data.blobUrl;return data.blobUrl=blobUrl,delete data.blobGenerating,oldBlobUrl&&pendingBlobCleanup.add(oldBlobUrl),previews.value.has(key)?(blobCleanup(),blobUrl):(pendingBlobCleanup.add(blobUrl),blobCleanup(),null)}function getAreas(opts){let data=previews.value.get(getCacheKey(opts));return data?data.areas:[]}return{cache:previews.value,cacheSize:computed(()=>previews.value.size),isRenderingAny:computed(()=>activeRenders.value>0||renderQueue.value.length>0),queueLength:computed(()=>renderQueue.value.length),activeRenders,isCached,clearCache,onCacheClear,getCacheKey,getPreview,getBlobPreview,getAreas,checkMultipaint,toArray:Paint.anyToArray}});async function renderPaint(paintData,width$1=TILE_SIZE,height$1=TILE_SIZE,radialLight=!1,areas=null,aborter=null){if(paintData=Paint.anyToArray(paintData),!paintData)return renderEmpty(width$1,height$1,aborter);if(checkMultipaint(paintData)){let clipData=areas||calculatePaintAreas(paintData,width$1,height$1);return renderMultipaint(paintData,width$1,height$1,clipData,radialLight,aborter)}else return paintData=Array.isArray(paintData[0])?paintData[0]:paintData,renderSinglePaint(paintData,width$1,height$1,radialLight,aborter)}function createPaint(paintData){let paint={_isEmpty:!0};if(!paintData)return paint;try{paint=new Paint({paint:paintData})}catch{}return paint}function applyAntialiasing(ctx){ctx.imageSmoothingEnabled=!0,ctx.imageSmoothingQuality=`high`,ctx.antialias=!0}function calculatePaintAreas(paintData,width$1,height$1){if(!paintData||!checkMultipaint(paintData))return[[0,0,width$1,height$1]];let paintCount=paintData.length,angle=Math.tan(MULTI_ANGLE*Math.PI/180),stripeWidth=(width$1+height$1*angle)/paintCount,overlap=.5,areas=[];for(let i=0;i0?overlap:0),topRight=startX+stripeWidth+(icoords.map((coord,i)=>coord*(i%2==0?scaleX:scaleY)));for(let i=0;igrad.addColorStop(...args))}else grad=ctx.createLinearGradient(0,0,0,height$1*.65),gradStops.forEach(args=>grad.addColorStop(...args));ctx.fillStyle=grad,ctx.fillRect(0,0,width$1,height$1),ctx.restore()}async function renderPaintLayers(ctx,paint,width$1,height$1,radialLight=!1,aborter=null){if(applyAntialiasing(ctx),ctx.fillStyle=`rgb(${(paint.rgb255||[255,255,255]).join(`, `)})`,ctx.fillRect(0,0,width$1,height$1),aborter?.signal.aborted)return;let grad=ctx.createLinearGradient(0,0,0,height$1);if(grad.addColorStop(0,`rgba(0, 0, 0, 0)`),grad.addColorStop(.65,`rgba(0, 0, 0, 0)`),grad.addColorStop(.8,`rgba(0, 0, 0, 0.15)`),grad.addColorStop(1,`rgba(0, 0, 0, 0.55)`),ctx.fillStyle=grad,ctx.fillRect(0,0,width$1,height$1),aborter?.signal.aborted)return;let metallic=Math.max(0,paint.metallic-paint.roughness/.5);if(metallic>.01){for(;!reflectionImageDone;){if(aborter?.signal.aborted)return;await sleep(10)}if(aborter?.signal.aborted)return;if(ctx.globalCompositeOperation=`multiply`,ctx.globalAlpha=metallic,reflectionImage){let scale=1,imageAspect=reflectionImage.width/reflectionImage.height,canvasAspect=width$1/height$1,drawWidth,drawHeight,offsetX=0,offsetY=0;imageAspect>canvasAspect?(drawHeight=height$1*1,drawWidth=height$1*imageAspect*1):(drawHeight=width$1/imageAspect*1,drawWidth=width$1*1),ctx.drawImage(reflectionImage,0,0,drawWidth,drawHeight)}else{ctx.strokeStyle=`rgba(255, 255, 255, 0.5)`,ctx.lineWidth=1;for(let x=-height$1;x({v889f200a:tileWidth.value,bee2d4dc:tileHeight.value}));let popover=usePopover(),props=__props,emit$1=__emit,mapId=uniqueId(`paint-tile-map`),menuId=uniqueId(`paint-tile-menu`),popMenu=ref(null),elCont=ref(null),elCanvas=ref(null),isLoading=ref(!1),isEmpty=ref(!1),hasRenderedOnce=ref(!1),paintPreviews=usePaintPreviews(),width$1=computed(()=>props.size||props.width),height$1=computed(()=>props.size||props.height),tileWidth=computed(()=>`${width$1.value}px`),tileHeight=computed(()=>`${height$1.value}px`),paints=computed(()=>props.paint?paintPreviews.toArray(props.paint):[]),isMultipaint=computed(()=>paintPreviews.checkMultipaint(paints.value)),paintNames=computed(()=>{let len=props.paint?.length||0;if(len===0)return[];let res=Array.from({length:len}).map((_,idx)=>({tooltip:[`ui.color.paint.unnamed`,{index:idx+1}],menu:[`ui.color.paint.selectOne`,{index:idx+1}],menuAdd:null}));if(props.paintNames?.length>0)for(let i=0;ihoveredPaintIndex.value=idx,tooltip=computed(()=>{let res={name:props.tooltip||props.paintName};return hoveredPaintIndex.value>-1&&paintNames.value[hoveredPaintIndex.value]&&(res.subname=paintNames.value[hoveredPaintIndex.value].tooltip),res}),customMenu=computed(()=>!props.customMenu||props.customMenu.length===0?null:props.customMenu.reduce((res,item,idx)=>item?[...res,{label:item.label||item,click:evt=>{popMenu.value?.hide?.(),nextTick(()=>{item.action?item.action(props.paint,evt):emit$1(`menu-click`,item.value||idx,props.paint,evt)})}}]:res,[])),withMenu=computed(()=>props.withMenu&&(paintAreas.value.length>1||customMenu.value)),opts=computed(()=>({paintId:props.paintId,vehicleName:props.vehicleName,paintName:props.paintName,width:width$1.value,height:height$1.value,radialLight:props.radialLight})),cacheKey=computed(()=>{try{return paintPreviews.getCacheKey(opts.value)}catch{return null}}),paintAreas=computed(()=>{if(!props.paint||isEmpty.value)return[];try{return paintPreviews.getAreas(opts.value)}catch{return[]}}),onContClick=evt=>onClick(-1,evt),onContRMB=()=>withMenu.value&&openMenu();function onClick(idx,evt){popMenu.value?.hide?.(),!props.disabled&&emit$1(`click`,idx,props.paint,evt)}function openMenu(){!elCont.value||!popMenu.value||(popover.hideAll(`paint-tile-menu`),!props.disabled&&popMenu.value.show(elCont.value))}async function renderPreview(){if(!cacheKey.value||!props.paint){isEmpty.value=!0,hasRenderedOnce.value=!1;return}isLoading.value=!0,isEmpty.value=!1;try{let bmp=await paintPreviews.getPreview(paints.value,opts.value);if(elCanvas.value&&bmp){let ctx=elCanvas.value.getContext(`2d`);ctx.clearRect(0,0,width$1.value,height$1.value),ctx.drawImage(bmp,0,0,width$1.value,height$1.value),hasRenderedOnce.value=!0}}catch(error){console.error(`Failed to render preview`,error),isEmpty.value=!0,hasRenderedOnce.value=!1}finally{isLoading.value=!1}}function checkEmpty(){if(!props.paint)return isEmpty.value=!0,hasRenderedOnce.value=!1,!0;if(isMultipaint.value){let allEmpty=paints.value.every(paintArray=>!paintArray||paintArray.length===0);return isEmpty.value=allEmpty,allEmpty&&(hasRenderedOnce.value=!1),allEmpty}return Array.isArray(paints.value)&&paints.value.length===0?(isEmpty.value=!0,hasRenderedOnce.value=!1,!0):(isEmpty.value=!1,!1)}watch(()=>[paints.value,props.paintId,props.vehicleName,props.paintName,width$1.value,height$1.value,props.radialLight],()=>{checkEmpty()?isLoading.value=!1:renderPreview()},{immediate:!0,deep:!0}),watch(()=>props.withAreas,val=>{val||(hoveredPaintIndex.value=-1)});let unsubscribeFromCacheClear=null,outEvents=[`click`,`contextmenu`,`uinav-focus`],listeningOutEvents=!1;function outOfMenu(evt){if(!popMenu.value||!popMenu.value.isShown())return;let el=popMenu.value.getElement();el&&el.contains(evt.detail?.target||evt.target)||nextTick(()=>popMenu.value.hide?.())}return watch(()=>popover.popovers[menuId]?.show,val=>{val?listeningOutEvents||(listeningOutEvents=!0,outEvents.forEach(evt=>document.addEventListener(evt,outOfMenu))):listeningOutEvents&&(listeningOutEvents=!1,outEvents.forEach(evt=>document.removeEventListener(evt,outOfMenu)))}),onMounted(()=>{!checkEmpty()&&renderPreview(),unsubscribeFromCacheClear=paintPreviews.onCacheClear((type,key)=>{(type===`all`||type===`single`&&key===cacheKey.value)&&!checkEmpty()&&hasRenderedOnce.value&&renderPreview()})}),onUnmounted(()=>{unsubscribeFromCacheClear?.(),listeningOutEvents&&outEvents.forEach(evt=>document.removeEventListener(evt,outOfMenu))}),(_ctx,_cache)=>withDirectives((openBlock(),createElementBlock(`div`,{ref_key:`elCont`,ref:elCont,class:normalizeClass([`bng-paint-tile`,{loading:isLoading.value&&!hasRenderedOnce.value,empty:isEmpty.value}]),tabindex:`0`,"bng-nav-item":``,onClick:withModifiers(onContClick,[`stop`]),onContextmenu:withModifiers(onContRMB,[`stop`])},[createBaseVNode(`canvas`,{ref_key:`elCanvas`,ref:elCanvas,width:width$1.value,height:height$1.value},null,8,_hoisted_1$311),__props.withAreas&&paintAreas.value.length>1?(openBlock(),createElementBlock(Fragment,{key:0},[createBaseVNode(`img`,{usemap:`#${unref(mapId)}`,src:unref(emptyImage),alt:``},null,8,_hoisted_2$254),createBaseVNode(`map`,{name:unref(mapId)},[(openBlock(!0),createElementBlock(Fragment,null,renderList(paintAreas.value,(area,index)=>(openBlock(),createElementBlock(`area`,{key:index,shape:`poly`,coords:area.join(`,`),onMouseover:$event=>onMouseOver(index),onMouseleave:_cache[0]||=$event=>onMouseOver(-1),onClick:withModifiers($event=>onClick(index,$event),[`stop`])},null,40,_hoisted_4$190))),128))],8,_hoisted_3$222)],64)):createCommentVNode(``,!0),isEmpty.value||isLoading.value&&!hasRenderedOnce.value?(openBlock(),createElementBlock(`div`,_hoisted_5$162)):createCommentVNode(``,!0),withMenu.value?(openBlock(),createBlock(unref(bngPopoverMenu_default),{key:2,ref_key:`popMenu`,ref:popMenu,name:unref(menuId),focus:``},{default:withCtx(()=>[paintNames.value.length>1?(openBlock(),createElementBlock(Fragment,{key:0},[withDirectives((openBlock(),createBlock(unref(bngButton_default),{accent:unref(ACCENTS).menu,onClick:_cache[1]||=$event=>onClick(-1,$event)},{default:withCtx(()=>[createTextVNode(toDisplayString(_ctx.$tt(`ui.color.paint.selectAll`)),1)]),_:1},8,[`accent`])),[[unref(BngOnUiNav_default),void 0,`ok`,{focusRequired:!0,asMouse:!0}]]),(openBlock(!0),createElementBlock(Fragment,null,renderList(paintNames.value,(paint,index)=>withDirectives((openBlock(),createBlock(unref(bngButton_default),{key:index,accent:unref(ACCENTS).menu,onClick:$event=>onClick(index,$event)},{default:withCtx(()=>[createTextVNode(toDisplayString(_ctx.$tt(...paintNames.value[index].menu))+toDisplayString(paintNames.value[index].menuAdd?`: `+paintNames.value[index].menuAdd:``),1)]),_:2},1032,[`accent`,`onClick`])),[[unref(BngOnUiNav_default),void 0,`ok`,{focusRequired:!0,asMouse:!0}]])),128))],64)):withDirectives((openBlock(),createBlock(unref(bngButton_default),{key:1,accent:unref(ACCENTS).menu,onClick:_cache[2]||=$event=>onClick(0,$event)},{default:withCtx(()=>[createTextVNode(toDisplayString(_ctx.$tt(`ui.color.paint.select`)),1)]),_:1},8,[`accent`])),[[unref(BngOnUiNav_default),void 0,`ok`,{focusRequired:!0,asMouse:!0}]]),customMenu.value?.length>0?(openBlock(!0),createElementBlock(Fragment,{key:2},renderList(customMenu.value,(item,index)=>withDirectives((openBlock(),createBlock(unref(bngButton_default),{key:index,accent:unref(ACCENTS).menu,onClick:$event=>item.click($event)},{default:withCtx(()=>[createTextVNode(toDisplayString(_ctx.$tt(item.label)),1)]),_:2},1032,[`accent`,`onClick`])),[[unref(BngOnUiNav_default),void 0,`ok`,{focusRequired:!0,asMouse:!0}]])),128)):createCommentVNode(``,!0)]),_:1},8,[`name`])):createCommentVNode(``,!0)],34)),[[unref(BngTooltip_default),_ctx.$tt(tooltip.value.name)+(tooltip.value.subname?` - `+_ctx.$tt(...tooltip.value.subname):``),__props.tooltipPosition],[unref(BngOnUiNav_default),void 0,`ok`,{asMouse:!0,focusRequired:!0}]])}},bngPaintTile_default=__plugin_vue_export_helper_default(_sfc_main$356,[[`__scopeId`,`data-v-25bf2552`]]),_hoisted_1$310=[`tabindex`],_sfc_main$355={__name:`bngPill`,props:{marked:{type:Boolean,default:!1}},setup(__props){let props=__props,attrs=useAttrs(),hasClickEvent=computed(()=>attrs&&attrs.onClick),isMarked=ref(props.marked);return watch(()=>props.marked,newValue=>isMarked.value=newValue),(_ctx,_cache)=>(openBlock(),createElementBlock(`span`,{"bng-nav-item":``,class:normalizeClass([`bng-pill`,{"pill-marked":isMarked.value,"pill-clickable":hasClickEvent.value}]),tabindex:hasClickEvent.value?0:-1},[renderSlot(_ctx.$slots,`default`,{},void 0,!0)],10,_hoisted_1$310))}},bngPill_default=__plugin_vue_export_helper_default(_sfc_main$355,[[`__scopeId`,`data-v-2d28d1ed`]]),_sfc_main$354={__name:`bngPillCheckbox`,props:{modelValue:{type:Boolean,default:null},markedIcon:{type:[Boolean,Object],default:!0}},emits:[`update:modelValue`,`valueChanged`,`change`],setup(__props,{emit:__emit}){let props=__props,emit$1=__emit,defaultValue=ref(!1),isChecked=computed({get:()=>props.modelValue!==void 0&&props.modelValue!==null?props.modelValue:defaultValue.value,set:newValue=>{props.modelValue!==void 0&&props.modelValue!==null?notifyListeners(newValue):(defaultValue.value=newValue,emit$1(`valueChanged`,newValue),emit$1(`change`,newValue))}}),onChecked=()=>isChecked.value=!isChecked.value;function notifyListeners(value){emit$1(`update:modelValue`,value),emit$1(`change`,value),emit$1(`valueChanged`,value)}return(_ctx,_cache)=>(openBlock(),createElementBlock(`span`,{class:normalizeClass([`bng-pill-checkbox`,{"show-icon":isChecked.value&&props.markedIcon}])},[createVNode(unref(bngPill_default),{marked:isChecked.value,onClick:onChecked,onKeyup:withKeys(onChecked,[`space`])},{default:withCtx(()=>[createBaseVNode(`span`,{class:normalizeClass({"pill-content":!0,"uses-mark":__props.markedIcon})},[renderSlot(_ctx.$slots,`default`,{},void 0,!0)],2),createVNode(unref(bngIcon_default),{class:`pill-mark-icon`,type:props.markedIcon===!0?unref(icons).checkmark:props.markedIcon||unref(icons).checkmark},null,8,[`type`])]),_:3},8,[`marked`])],2))}},bngPillCheckbox_default=__plugin_vue_export_helper_default(_sfc_main$354,[[`__scopeId`,`data-v-04487830`]]),_hoisted_1$309={class:`bng-pill-filters`,tabindex:`0`},_sfc_main$353={__name:`bngPillFilters`,props:{modelValue:Array,options:{type:Array,required:!0},selectOnFocus:Boolean,selectMany:Boolean,showCheckIcon:{type:Boolean,default:!0},required:Boolean},emits:[`update:modelValue`,`valueChanged`],setup(__props,{expose:__expose,emit:__emit}){let props=__props,emit$1=__emit;__expose({focusPrevious,focusNext,toggleFocusedPill,focusIndex});let scrollable=ref(null),pills=ref([]),currentPillIndex=ref(-1),defaultSelected=ref([]),selectedValues=computed({get:()=>props.modelValue?props.modelValue:defaultSelected.value,set:newValue=>{props.modelValue?(emit$1(`update:modelValue`,newValue),emit$1(`valueChanged`,newValue)):(defaultSelected.value=newValue,emit$1(`valueChanged`,newValue))}}),pillConfigs=computed(()=>toRaw(props.options).map(x=>({...x,selected:selectedValues.value&&selectedValues.value.length>0&&selectedValues.value.includes(x.value)})));function focusPrevious(){currentPillIndex.value=currentPillIndex.value>0?currentPillIndex.value-1:0,pills.value[currentPillIndex.value].querySelector(`.bng-pill`).focus(),console.log(`currentPillIndex.value`,currentPillIndex.value)}function focusNext(){currentPillIndex.value{scrollable.value.addEventListener(`wheel`,evt=>{evt.preventDefault(),scrollable.value.scrollLeft+=evt.deltaY}),currentPillIndex.value=selectedValues.value.length>0?pillConfigs.value.findIndex(x=>x.value===selectedValues.value[0]):-1,currentPillIndex.value>-1&&focusPill(currentPillIndex.value)});let onPillValueChanged=(key,value)=>{props.selectOnFocus||(console.log(`onPillValueChanged`,key,value),setPillValue(key,value))},onPillFocusIn=(key,index)=>{focusPill(index),props.selectOnFocus&&setPillValue(key,!(selectedValues.value.length>0&&selectedValues.value.includes(key)))};function setPillValue(key,checked){if(currentPillIndex.value=pillConfigs.value.findIndex(x=>x.value===key),props.required&&!checked&&selectedValues.value.includes(key)&&selectedValues.value.length==1){selectedValues.value=[key];return}if(!props.selectMany){selectedValues.value=checked?[key]:[];return}let isExisting=selectedValues.value.includes(key);checked&&!isExisting?selectedValues.value=[...selectedValues.value,key]:!checked&&isExisting&&(selectedValues.value=selectedValues.value.filter(x=>x!==key))}function focusPill(index){let pillEl=pills.value[index],scrollableRect=scrollable.value.getBoundingClientRect(),pillRect=pillEl.getBoundingClientRect();pillRect.left>=scrollableRect.left&&pillRect.right<=scrollableRect.right||window.requestAnimationFrame(()=>{scrollable.value.scrollBy({left:pillEl.getBoundingClientRect().right})})}return(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$309,[createBaseVNode(`div`,{class:`pills-wrapper`,ref_key:`scrollable`,ref:scrollable},[(openBlock(!0),createElementBlock(Fragment,null,renderList(pillConfigs.value,(pill,index)=>(openBlock(),createElementBlock(`div`,{key:pill.value,ref_for:!0,ref_key:`pills`,ref:pills,class:`pill-wrapper`},[createVNode(unref(bngPillCheckbox_default),{markedIcon:__props.showCheckIcon,modelValue:pill.selected,"onUpdate:modelValue":$event=>pill.selected=$event,onValueChanged:value=>onPillValueChanged(pill.value,value),onFocusin:$event=>onPillFocusIn(pill.value,index)},{default:withCtx(()=>[createTextVNode(toDisplayString(pill.label),1)]),_:2},1032,[`markedIcon`,`modelValue`,`onUpdate:modelValue`,`onValueChanged`,`onFocusin`])]))),128))],512)]))}},bngPillFilters_default=__plugin_vue_export_helper_default(_sfc_main$353,[[`__scopeId`,`data-v-580a9eac`]]),_sfc_main$352={__name:`bngPillFiltersContainer`,props:{options:{type:Array,required:!0},selectOnNavigation:{type:Boolean,default:!0},required:Boolean,selectMany:Boolean,hasCheckedIcon:{default:!0,type:Boolean}},emits:[`update:modelValue`,`valueChanged`],setup(__props,{expose:__expose,emit:__emit}){let emit$1=__emit,props=__props,selectedItems=ref([]),bngFiltersContainer=ref(null),filtersContainer=ref(null),bngPillFiltersRef=ref(null);__expose({selectPrevious:()=>bngPillFiltersRef.value.selectPrevious(),selectNext:()=>bngPillFiltersRef.value.selectNext(),selectCurrent:()=>bngPillFiltersRef.value.selectCurrent(),focusAndScrollToSelected:focusSelected});let selectedItemId=``;onMounted(()=>{filtersContainer.value.addEventListener(`wheel`,evt=>{evt.preventDefault(),filtersContainer.value.scrollLeft+=evt.deltaY})});function focusSelected(){props.selectMany||!props.selectOnNavigation||scrollToElement(selectedItemId)}function onContainerFocusOut($event){!($event.relatedTarget&&bngFiltersContainer.value.contains($event.relatedTarget))&&!props.selectMany&&selectedItemId&&scrollToElement(selectedItemId)}function onValueChanged(items$2,id){selectedItems.value=items$2,selectedItemId=id,emit$1(`valueChanged`,items$2,id)}function onPillItemFocusIn(id){scrollToElement(id)}function scrollToElement(id){let scrollableContainer=filtersContainer.value,el=scrollableContainer.querySelector(`#${id}`);if(el){let scrollableContainerRect=scrollableContainer.getBoundingClientRect(),itemRect=el.getBoundingClientRect();if(itemRect.left>=scrollableContainerRect.left&&itemRect.right<=scrollableContainerRect.right)return;window.requestAnimationFrame(()=>{let scrollValue=itemRect.left(openBlock(),createElementBlock(`div`,{class:`bng-filters-container`,ref_key:`bngFiltersContainer`,ref:bngFiltersContainer,tabindex:`0`,onFocusout:onContainerFocusOut},[_cache[0]||=createBaseVNode(`div`,{class:`fade-effect left-fade-effect`},null,-1),_cache[1]||=createBaseVNode(`div`,{class:`fade-effect right-fade-effect`},null,-1),createBaseVNode(`div`,{class:`scroll-container`,ref_key:`filtersContainer`,ref:filtersContainer},[createVNode(unref(bngPillFilters_default),{ref_key:`bngPillFiltersRef`,ref:bngPillFiltersRef,options:__props.options,"select-on-navigation":__props.selectOnNavigation,required:__props.required,"select-many":__props.selectMany,"show-checked-icon":__props.hasCheckedIcon,onValueChanged,onPillItemFocusIn},null,8,[`options`,`select-on-navigation`,`required`,`select-many`,`show-checked-icon`])],512)],544))}},bngPillFiltersContainer_default=__plugin_vue_export_helper_default(_sfc_main$352,[[`__scopeId`,`data-v-498af92b`]]),_hoisted_1$308=[`data-bng-popover-name`],containerSelector=`.popover-container`,_sfc_main$351={__name:`bngPopoverContent`,props:{name:String,offset:{type:Number,default:4},hideArrow:Boolean,placement:String,disabled:Boolean},emits:[`show`,`hide`,`placementChanged`],setup(__props,{expose:__expose,emit:__emit}){let props=__props,emit$1=__emit,popover=usePopover(),popoverName,popoverContent=ref(null),arrow$3=ref(null),show=ref(!1),unwatchShow,unwatchPlacement,teleportTargetExists=ref(!1),observer$2=null,scopeActivated=ref(!1),isRender=computed(()=>!props.disabled&&teleportTargetExists.value&&show.value),hide$2=()=>!props.disabled&&popover.hide(popoverName),expose={hide:hide$2,show:(el=void 0)=>!props.disabled&&popover.show(popoverName,el),toggle:(forceVal=void 0)=>popover.toggle(popoverName,!props.disabled&&forceVal),isShown:()=>popover.isShown(popoverName)};__expose(expose),watch(()=>show.value,value=>emit$1(value?`show`:`hide`,{name:props.name,...expose})),watch(()=>props.name,(newName,oldName)=>{oldName&&disposePopover(oldName),props.disabled||setupPopover()},{immediate:!0}),watch(()=>props.disabled,value=>{value?(popover.hide(popoverName),disposePopover(popoverName)):setupPopover()}),watch(isRender,async value=>{value&&(await nextTick(),checkSlotContent())});let onMenu=()=>{scopeActivated.value=!1};onBeforeUnmount(()=>{disposePopover(popoverName),observer$2&&=(observer$2.disconnect(),null)}),onMounted(async()=>{teleportTargetExists.value=!!document.querySelector(containerSelector),teleportTargetExists.value||(observer$2=new MutationObserver(()=>{!teleportTargetExists.value&&document.querySelector(containerSelector)&&(teleportTargetExists.value=!0,observer$2.disconnect(),observer$2=null)}),observer$2.observe(document.body,{childList:!0,subtree:!0})),isRender.value&&(await nextTick(),checkSlotContent())});function onScopeChanged(activated,event){scopeActivated.value=activated,!activated&&!event.detail.force&&popover.hide(popoverName)}function checkSlotContent(){let navigableElements=popoverContent.value.querySelectorAll(NAVIGABLE_ELEMENTS_SELECTOR);navigableElements&&navigableElements.length>0&&!scopeActivated.value&&(scopeActivated.value=!0)}function setupPopover(){popoverName=props.name||uniqueId(`bng-popover-content`);let res=popover.register(popoverName,popoverContent,props.placement,{arrow:props.hideArrow?void 0:arrow$3,offset:props.offset});res&&(unwatchShow=watch(res.show,value=>show.value=value),unwatchPlacement=watch(res.placement,placement=>emit$1(`placementChanged`,placement)))}function disposePopover(name){unwatchShow&&=(unwatchShow(),null),unwatchPlacement&&=(unwatchPlacement(),null),popover.unregister(name),show.value=!1,popoverName=null}return(_ctx,_cache)=>isRender.value?(openBlock(),createBlock(Teleport,{key:0,to:`.popover-container`},[withDirectives((openBlock(),createElementBlock(`div`,{ref_key:`popoverContent`,ref:popoverContent,"data-bng-popover-name":unref(popoverName),class:`bng-popover`,onActivate:_cache[0]||=$event=>onScopeChanged(!0,$event),onDeactivate:_cache[1]||=$event=>onScopeChanged(!1,$event)},[renderSlot(_ctx.$slots,`default`,{hide:hide$2},void 0,!0),__props.hideArrow?createCommentVNode(``,!0):(openBlock(),createElementBlock(`span`,{key:0,ref_key:`arrow`,ref:arrow$3,class:`bng-popover-arrow`},null,512))],40,_hoisted_1$308)),[[unref(BngScopedNav_default),{activated:scopeActivated.value,type:unref(SCOPED_NAV_TYPES).popover}],[unref(BngOnUiNav_default),onMenu,`menu`]])])):createCommentVNode(``,!0)}},bngPopoverContent_default=__plugin_vue_export_helper_default(_sfc_main$351,[[`__scopeId`,`data-v-4938e558`]]),_sfc_main$350=Object.assign({inheritAttrs:!1},{__name:`bngPopoverMenu`,props:{name:String,offset:{type:Number,default:4},hideArrow:Boolean,disabled:Boolean,focus:Boolean},emits:[`show`,`hide`,`placementChanged`],setup(__props,{expose:__expose,emit:__emit}){let popover=usePopover(),props=__props,emit$1=__emit,relay={show:(...args)=>emit$1(`show`,...args),hide:(...args)=>emit$1(`hide`,...args),placementChanged:(...args)=>emit$1(`placementChanged`,...args)},popoverContent=ref(null),popoverMenu=ref(null),hide$2=(...args)=>popoverContent.value.hide(...args);return __expose({hide:hide$2,show:(...args)=>popoverContent.value.show(...args),toggle:(...args)=>popoverContent.value.toggle(...args),isShown:(...args)=>popoverContent.value.isShown(...args),getElement:()=>popoverMenu.value}),watchEffect(()=>{if(props.name in popover.popovers){let pop=popover.popovers[props.name];!pop.show&&nextTick(()=>{pop.target&&document.activeElement===document.body&&setFocusExternal(pop.target,!0,!1)})}}),(_ctx,_cache)=>(openBlock(),createBlock(unref(bngPopoverContent_default),{ref_key:`popoverContent`,ref:popoverContent,name:__props.name,offset:__props.offset,"hide-arrow":__props.hideArrow,disabled:__props.disabled,onPlacementChanged:relay.placementChanged,onHide:hide$2},{default:withCtx(()=>[createBaseVNode(`div`,{ref_key:`popoverMenu`,ref:popoverMenu,class:`bng-popover-menu`},[renderSlot(_ctx.$slots,`default`,{hide:hide$2},void 0,!0)],512)]),_:3},8,[`name`,`offset`,`hide-arrow`,`disabled`,`onPlacementChanged`]))}}),bngPopoverMenu_default=__plugin_vue_export_helper_default(_sfc_main$350,[[`__scopeId`,`data-v-fe39553c`]]),_hoisted_1$307={class:`bng-progress-bar`},_hoisted_2$253={key:0,class:`header`},_hoisted_3$221={class:`header-left`},_hoisted_4$189={class:`header-right`},_hoisted_5$161={class:`progress-bar`},_hoisted_6$139=[`innerHTML`],_hoisted_7$121={key:1,class:`progress-fill-indeterminate`},_sfc_main$349={__name:`bngProgressBar`,props:{value:{type:Number,default:0},oldValue:{type:Number,default:0},min:{type:Number,default:0},max:{type:Number,required:!0},headerLeft:String,headerRight:String,showValueLabel:{type:Boolean,default:!0},valueLabelFormat:{type:[String,Function],default:`#value#`},valueColor:{type:String,default:`#ff6600`},oldValueColor:{type:String,default:`#ffffff`},indeterminate:Boolean,animateDifference:Boolean,gradient:Boolean},setup(__props,{expose:__expose}){useCssVars(_ctx=>({v5113e7b0:__props.valueColor,v14406f01:progressFillUnits.value,v6b373656:oldProgressFillUnits.value}));let props=__props;__expose({decreaseValueBy,increaseValueBy,setValue:value=>updateCurrentValue(value)});let currentValue=ref(null),valueHTML=computed(()=>{let res;return res=typeof props.valueLabelFormat==`function`?props.valueLabelFormat(props.value,{min:props.min,max:props.max}):props.valueLabelFormat.replace(/ +/g,` `).replace(`#value#`,`${currentValue.value}${props.max}`),res}),progressFillUnits=computed(()=>1-(currentValue.value-props.min)/(props.max-props.min)),oldProgressFillUnits=computed(()=>1-(props.oldValue-props.min)/(props.max-props.min));watch(()=>props.value,updateCurrentValue),onMounted(()=>{updateCurrentValue(props.min>props.value?props.min:props.value)});function decreaseValueBy(value){let newValue=currentValue.value-value;newValueprops.max&&(newValue=props.max),updateCurrentValue(newValue)}function updateCurrentValue(newValue){currentValue.value=newValue}return(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$307,[__props.headerLeft||__props.headerRight?(openBlock(),createElementBlock(`div`,_hoisted_2$253,[createBaseVNode(`span`,_hoisted_3$221,toDisplayString(__props.headerLeft),1),createBaseVNode(`span`,_hoisted_4$189,toDisplayString(__props.headerRight),1)])):createCommentVNode(``,!0),createBaseVNode(`div`,_hoisted_5$161,[__props.showValueLabel?(openBlock(),createElementBlock(`div`,{key:0,class:`info`,innerHTML:valueHTML.value},null,8,_hoisted_6$139)):createCommentVNode(``,!0),__props.indeterminate?(openBlock(),createElementBlock(`span`,_hoisted_7$121)):(openBlock(),createElementBlock(`span`,{key:2,class:normalizeClass({"progress-fill":!0,"progress-fill-gradient":__props.gradient,"animate-progress":__props.animateDifference&&__props.value>__props.oldValue}),style:normalizeStyle({backgroundColor:__props.valueColor,zIndex:__props.value<__props.oldValue?2:1})},null,6)),__props.oldValue?(openBlock(),createElementBlock(`span`,{key:3,class:normalizeClass({"second-progress-fill":!0,"progress-fill-gradient":__props.gradient,"animate-progress":__props.animateDifference&&__props.value<__props.oldValue}),style:normalizeStyle({backgroundColor:__props.oldValueColor,zIndex:__props.value<__props.oldValue?1:2})},null,6)):createCommentVNode(``,!0)])]))}},bngProgressBar_default=__plugin_vue_export_helper_default(_sfc_main$349,[[`__scopeId`,`data-v-1ca6aacd`]]);function shrinkNum(num,decimals=0){let units=[``,`K`,`M`,`B`,`T`,`Q`];if(!num)return`0`;if(isNaN(parseFloat(num))||!isFinite(+num))return`n/a`;let power$1=Math.floor(Math.log(Math.abs(+num))/Math.log(1e3));return power$1>=units.length&&(power$1=units.length-1),(num/1e3**power$1).toFixed(decimals).replace(/\.0+$/,``)+units[power$1]}var _hoisted_1$306={key:1,class:`key-label`},_hoisted_2$252={class:`value-label`},_sfc_main$348={__name:`bngPropVal`,props:{iconType:[String,Object],keyLabel:String,valueLabel:{required:!0},shrinkNum:Boolean,iconColor:{type:String,default:`#fff`},noGap:{type:Boolean,default:!1},noIcon:{type:Boolean,default:!1}},setup(__props){let props=__props,itemClass=computed(()=>({"info-item":!0,"with-icon":props.iconType,"no-key":!props.keyLabel,"no-gap":props.noGap})),value=computed(()=>{let i=props.valueLabel;return props.shrinkNum?shrinkNum(i,0):i});return(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,{class:normalizeClass(itemClass.value)},[__props.iconType&&!__props.noIcon?(openBlock(),createBlock(unref(bngIcon_default),{key:0,class:`icon`,type:__props.iconType,color:__props.iconColor},null,8,[`type`,`color`])):createCommentVNode(``,!0),__props.keyLabel?(openBlock(),createElementBlock(`span`,_hoisted_1$306,toDisplayString(__props.keyLabel),1)):createCommentVNode(``,!0),createBaseVNode(`span`,_hoisted_2$252,toDisplayString(value.value),1)],2))}},bngPropVal_default=__plugin_vue_export_helper_default(_sfc_main$348,[[`__scopeId`,`data-v-fa2e2062`]]),_hoisted_1$305={class:`header`},_sfc_main$347={__name:`bngScreenHeading`,props:{blurDelay:Number,preheadings:Array,divider:Boolean,type:{type:String,default:`line`,validator:v=>[`line`,`ribbon`].includes(v)||v===``}},setup(__props){let blurVal=ref(!1);onMounted(()=>window.setTimeout(()=>blurVal.value=!0,~~+props.blurDelay));let props=__props,preheadings=computed(()=>Array.isArray(props.preheadings)&&props.preheadings.length>0?props.preheadings:null);return(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,{class:normalizeClass([`bng-screen-heading`,{[`heading-style-${__props.type}`]:!0,prehead:preheadings.value}])},[preheadings.value?withDirectives((openBlock(),createElementBlock(`span`,{key:0,class:normalizeClass([`pre-header`,{"with-divider":__props.divider}])},[(openBlock(!0),createElementBlock(Fragment,null,renderList(preheadings.value,preheading=>(openBlock(),createElementBlock(`span`,{class:`location`,key:preheading},toDisplayString(preheading),1))),128))],2)),[[unref(BngBlur_default),blurVal.value]]):createCommentVNode(``,!0),withDirectives((openBlock(),createElementBlock(`h1`,_hoisted_1$305,[renderSlot(_ctx.$slots,`default`,{},void 0,!0)])),[[unref(BngBlur_default),blurVal.value]])],2))}},bngScreenHeading_default=__plugin_vue_export_helper_default(_sfc_main$347,[[`__scopeId`,`data-v-f6d9f077`]]),_hoisted_1$304={class:`header`},_hoisted_2$251={key:0,class:`decorator-item`,width:`100%`,height:`100%`,viewBox:`0 0 32 40`,preserveAspectRatio:`none`,fill:`none`,xmlns:`http://www.w3.org/2000/svg`},_hoisted_3$220={key:1,class:`decorator-item`,width:`100%`,height:`100%`,viewBox:`0 0 36 40`,preserveAspectRatio:`xMaxYMid slice`,fill:`none`,xmlns:`http://www.w3.org/2000/svg`},_hoisted_4$188={key:2,class:`decorator-item`,width:`100%`,height:`100%`,viewBox:`0 0 36 40`,preserveAspectRatio:`xMaxYMid slice`,fill:`none`,xmlns:`http://www.w3.org/2000/svg`},_sfc_main$346={__name:`bngScreenHeadingV2`,props:{blurDelay:Number,preheadings:Array,divider:Boolean,type:{type:String,default:`1`,validator:v=>[`1`,`2`,`3`].includes(v)||v===``},hintVisible:Boolean,hintLabel:String,hintIcon:String,hintAccent:String,hintBindingEvent:String},emits:[`hint`],setup(__props,{emit:__emit}){let blurVal=ref(!1);onMounted(()=>window.setTimeout(()=>blurVal.value=!0,~~+props.blurDelay));let props=__props,preheadings=computed(()=>Array.isArray(props.preheadings)&&props.preheadings.length>0?props.preheadings:null);return computed(()=>props.hintVisible??!1),computed(()=>props.hintLabel??``),computed(()=>props.hintIcon??icons.arrowLargeLeft),computed(()=>props.hintAccent??ACCENTS.outlined),(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,{class:normalizeClass([`bng-screen-heading`,{[`heading-style-${__props.type}`]:!0,prehead:preheadings.value}])},[renderSlot(_ctx.$slots,`preheadings`,{},void 0,!0),withDirectives((openBlock(),createElementBlock(`span`,_hoisted_1$304,[createBaseVNode(`div`,{class:normalizeClass(`decorator type${__props.type}`)},[__props.type===`1`?(openBlock(),createElementBlock(`svg`,_hoisted_2$251,[..._cache[0]||=[createBaseVNode(`path`,{d:`M16.6328 40H1.62891L14.0039 6H14.002L11.8174 0H26.8174L29.001 6H29.0078L16.6328 40Z`,fill:`var(--bng-orange-400)`},null,-1)]])):createCommentVNode(``,!0),__props.type===`2`?(openBlock(),createElementBlock(`svg`,_hoisted_3$220,[..._cache[1]||=[createBaseVNode(`path`,{d:`M18.6366 0H34.0094L26.73 20H11.3572L18.6366 0Z`,fill:`#DA5706`},null,-1),createBaseVNode(`path`,{d:`M19.4504 40H4.07812L11.3572 20L4.07812 0H19.4504L26.7295 20L19.4504 40Z`,fill:`var(--bng-orange-400)`},null,-1)]])):createCommentVNode(``,!0),__props.type===`3`?(openBlock(),createElementBlock(`svg`,_hoisted_4$188,[..._cache[2]||=[createBaseVNode(`path`,{d:`M18.6366 0H34.0094L26.73 20H11.3572L18.6366 0Z`,fill:`#DA5706`},null,-1),createBaseVNode(`path`,{d:`M19.4504 40H4.07812L11.3572 20L4.07812 0H19.4504L26.7295 20L19.4504 40Z`,fill:`var(--bng-orange-400)`},null,-1)]])):createCommentVNode(``,!0)],2),createBaseVNode(`h1`,null,[renderSlot(_ctx.$slots,`default`,{},void 0,!0)])])),[[unref(BngBlur_default),blurVal.value]])],2))}},bngScreenHeadingV2_default=__plugin_vue_export_helper_default(_sfc_main$346,[[`__scopeId`,`data-v-4854a8bd`]]),_hoisted_1$303={class:`label select`},_hoisted_2$250={class:`bng-select-indicator`},_sfc_main$345={__name:`bngSelect`,props:mergeModels({value:void 0,options:{type:Array,required:!0},config:{type:Object,default:()=>({value:opt=>opt,label:opt=>opt})},loop:Boolean,labelClickable:Boolean,labelPopover:String,disabled:Boolean,navLeftEvent:{type:String,default:`focus_l`},navRightEvent:{type:String,default:`focus_r`}},{modelValue:{type:[Object,Boolean,Number,String],default:void 0},modelModifiers:{}}),emits:mergeModels([`change`,`valueChanged`,`label-click`],[`update:modelValue`]),setup(__props,{expose:__expose,emit:__emit}){let leftBinding=ref(),rightBinding=ref(),vModel=useModel(__props,`modelValue`),props=__props,elContainer=ref(),elContent=ref(),findOptionValue=(valueToFind,opts)=>Math.max(0,opts.findIndex(opt=>props.config.value(opt)===valueToFind)),index=ref(getInitialValue()),current=computed(()=>({option:props.options[index.value],value:props.config.value(props.options[index.value]),label:props.config.label(props.options[index.value])})),leftIconClass=computed(()=>({"with-binding":leftBinding.value?.displayed})),rightIconClass=computed(()=>({"with-binding":rightBinding.value?.displayed})),isLeftDisabled=props.loop?!1:computed(()=>index.value==0),isRightDisabled=props.loop?!1:computed(()=>index.value==props.options.length-1),emit$1=__emit,goPrev=()=>{!props.disabled&&!isLeftDisabled.value&&changeIndex(-1)},goNext=()=>{!props.disabled&&!isRightDisabled.value&&changeIndex(1)};__expose({goNext,goPrev,getElement:()=>elContainer.value,getContentElement:()=>elContent.value}),watch(()=>props.value,()=>index.value=props.value!==null&&props.value!==void 0?findOptionValue(props.value,props.options):0),watch(vModel,val=>index.value=val==null?0:findOptionValue(val,props.options)),watch(()=>index.value,updateValue);function updateValue(){emit$1(`valueChanged`,current.value.value,current.value.label,current.value.option),emit$1(`change`,current.value.value,current.value.label,current.value.option),vModel.value=current.value.value}function changeIndex(offset$2){props.loop?index.value=(props.options.length+index.value+offset$2)%props.options.length:index.value=clamp(index.value+offset$2,0,props.options.length-1)}function getInitialValue(){return vModel.value!==null&&vModel.value!==void 0?findOptionValue(vModel.value,props.options):`value`in props?findOptionValue(props.value,props.options):0}return(_ctx,_cache)=>withDirectives((openBlock(),createElementBlock(`div`,{ref_key:`elContainer`,ref:elContainer,class:`bng-select`,"bng-nav-item":``},[renderSlot(_ctx.$slots,`previousButton`,{click:goPrev,disabled:unref(isLeftDisabled)},()=>[createVNode(unref(bngButton_default),{"bng-no-nav":`true`,disabled:__props.disabled||unref(isLeftDisabled),accent:unref(ACCENTS).text,mute:_ctx.$attrs.mute,"data-testid":`previous-btn`,onClick:goPrev},{default:withCtx(()=>[createVNode(unref(bngIcon_default),{type:leftBinding.value?.displayed?unref(icons).arrowSmallLeft:unref(icons).arrowLargeLeft,class:normalizeClass(leftIconClass.value)},null,8,[`type`,`class`]),__props.navLeftEvent&&__props.navLeftEvent!==`focus_l`?(openBlock(),createBlock(unref(bngBinding_default),{key:0,ref_key:`leftBinding`,ref:leftBinding,uiEvent:__props.navLeftEvent,controller:``},null,8,[`uiEvent`])):createCommentVNode(``,!0)]),_:1},8,[`disabled`,`accent`,`mute`])],!0),withDirectives((openBlock(),createElementBlock(`div`,{ref_key:`elContent`,ref:elContent,class:normalizeClass([`bng-select-content`,{"label-clickable":__props.labelClickable}]),onClick:_cache[0]||=withModifiers($event=>__props.labelClickable&&emit$1(`label-click`),[`stop`])},[renderSlot(_ctx.$slots,`display`,{label:current.value.label,value:current.value.value},()=>[createBaseVNode(`span`,_hoisted_1$303,toDisplayString(current.value.label),1),_cache[1]||=createBaseVNode(`label`,{flavour:``},null,-1)],!0)],2)),[[unref(BngSoundClass_default),!__props.disabled&&__props.labelClickable&&`bng_click_hover_generic`],[unref(BngPopover_default),__props.labelPopover,`bottom`,{click:!0}]]),renderSlot(_ctx.$slots,`nextButton`,{click:goNext,disabled:unref(isRightDisabled)},()=>[createVNode(unref(bngButton_default),{"bng-no-nav":`true`,disabled:__props.disabled||unref(isRightDisabled),accent:unref(ACCENTS).text,mute:_ctx.$attrs.mute,"data-testid":`next-btn`,onClick:goNext},{default:withCtx(()=>[__props.navRightEvent&&__props.navRightEvent!==`focus_r`?(openBlock(),createBlock(unref(bngBinding_default),{key:0,ref_key:`rightBinding`,ref:rightBinding,uiEvent:__props.navRightEvent,controller:``},null,8,[`uiEvent`])):createCommentVNode(``,!0),createVNode(unref(bngIcon_default),{type:rightBinding.value?.displayed?unref(icons).arrowSmallRight:unref(icons).arrowLargeRight,class:normalizeClass(rightIconClass.value)},null,8,[`type`,`class`])]),_:1},8,[`disabled`,`accent`,`mute`])],!0),createBaseVNode(`div`,_hoisted_2$250,[(openBlock(!0),createElementBlock(Fragment,null,renderList(__props.options.length,idx=>(openBlock(),createElementBlock(`div`,{key:idx,class:normalizeClass({active:idx-1===index.value})},null,2))),128))])])),[[unref(BngOnUiNav_default),goPrev,__props.navLeftEvent,{focusRequired:!0}],[unref(BngOnUiNav_default),goNext,__props.navRightEvent,{focusRequired:!0}],[unref(BngDisabled_default),__props.disabled]])}},bngSelect_default=__plugin_vue_export_helper_default(_sfc_main$345,[[`__scopeId`,`data-v-d1cacb72`]]),_hoisted_1$302={class:`bng-simple-graph`},_hoisted_2$249={key:0,class:`y-axis`},_hoisted_3$219={class:`y-values`},_hoisted_4$187={class:`max-value`},_hoisted_5$160={class:`axis-label`},_hoisted_6$138={key:0,class:`unit`},_hoisted_7$120={class:`min-value`},_hoisted_8$100={viewBox:`0 0 100 100`,preserveAspectRatio:`none`,class:`graph-svg`},_hoisted_9$90=[`width`,`height`],_hoisted_10$78=[`d`,`stroke`],_hoisted_11$70=[`d`,`stroke`],_hoisted_12$58=[`width`,`height`],_hoisted_13$50=[`d`,`stroke`],_hoisted_14$45=[`d`,`stroke`],_hoisted_15$43={key:0,width:`100`,height:`100`,fill:`url(#subgrid)`},_hoisted_16$40={class:`grid`},_hoisted_17$33=[`y1`,`y2`,`stroke`],_hoisted_18$30={class:`background-ranges`},_hoisted_19$25=[`x`,`width`,`fill`,`stroke`,`opacity`],_hoisted_20$21={class:`vertical-guides`},_hoisted_21$19=[`x1`,`x2`,`stroke`,`opacity`],_hoisted_22$17=[`x1`,`x2`],_hoisted_23$16=[`d`,`fill`,`opacity`],_hoisted_24$15=[`d`,`stroke`],_hoisted_25$14={key:2,class:`x-axis`},_hoisted_26$12={class:`x-values`},_hoisted_27$12={class:`min-value`},_hoisted_28$11={class:`axis-label`},_hoisted_29$11={key:0,class:`unit`},_hoisted_30$10={class:`max-value`},_sfc_main$344={__name:`bngSimpleGraph`,props:{config:{type:Object,default:()=>({showLabels:!1,xAxis:{key:`x`,label:`X Axis`,unit:``},yAxis:{key:`y`,label:`Y Axis`,unit:``}})},points:{type:Array,default:()=>[]},gridColor:{type:String,default:`var(--bng-ter-blue-gray-500)`},backgroundColor:{type:String,default:`rgba(0, 0, 0, 0.1)`},currentX:{type:Number,default:null},verticalGuides:{type:Array,default:()=>[]},ranges:{type:Array,default:()=>[]},gridDivisions:{type:Array,default:()=>[50,20]},subgridDivider:{type:Number,default:2},showSubgrid:{type:Boolean,default:!0},singleLabel:{type:Object,default:null}},setup(__props){useCssVars(_ctx=>({v194c2663:__props.config.showLabels?`2rem`:`0`,fdb9891e:__props.backgroundColor}));let props=__props,gridSizes=computed(()=>({x:100/props.gridDivisions[0],y:100/props.gridDivisions[1]})),xScale=computed(()=>{if(props.config?.xAxis?.min!==void 0&&props.config?.xAxis?.max!==void 0){let range$1=props.config.xAxis.max-props.config.xAxis.min;return{min:props.config.xAxis.min,max:props.config.xAxis.max,range:range$1===0?1:range$1}}if(!props.points.length)return{min:0,max:1,range:1};let xValues=[...props.points.flatMap(dataset=>(dataset.points||[]).map(point=>point&&point[0])),...(props.verticalGuides||[]).map(guide=>guide?.x),...(props.ranges||[]).map(range$1=>range$1?.start),...(props.ranges||[]).map(range$1=>range$1?.end)].filter(val=>val!=null&&isFinite(val));if(xValues.length===0)return{min:0,max:1,range:1};let min$1=Math.min(...xValues),max$1=Math.max(...xValues);if(!isFinite(min$1)||!isFinite(max$1))return{min:0,max:1,range:1};let range=max$1-min$1;return{min:min$1,max:max$1,range:range===0?1:range}}),getXPosition=value=>{if(value==null||!isFinite(value))return 0;let result=(value-xScale.value.min)/xScale.value.range*100;return isFinite(result)?result:0},datasetPaths=computed(()=>!props.points.length||!xScale.value?[]:props.points.map(dataset=>{if(!dataset.points||!Array.isArray(dataset.points)||dataset.points.length===0)return{datasetId:dataset.label||`unknown`,linePath:``,areaPath:``};let linePoints=dataset.points.map((point,index)=>{if(!point||point.length<2)return``;let x=getXPosition(point[0]),y=getYPosition(point[1]);return`${index===0?`M`:`L`} ${x} ${y}`}).filter(p$1=>p$1).join(` `),areaPoints=dataset.points.map(point=>!point||point.length<2?``:`L ${getXPosition(point[0])} ${getYPosition(point[1])}`).filter(p$1=>p$1).join(` `),areaPath=``;if(dataset.fill&&dataset.points.length>0){let firstPoint=dataset.points[0],lastPoint=dataset.points[dataset.points.length-1];firstPoint&&lastPoint&&firstPoint.length>=2&&lastPoint.length>=2&&(areaPath=`M -5 105 L -5 ${getYPosition(firstPoint[1])} ${areaPoints} L 105 ${getYPosition(lastPoint[1])} L 105 105 Z`)}return{datasetId:dataset.label||`unknown`,linePath:linePoints,areaPath}})),getLinePathForDataset=dataset=>{let path=datasetPaths.value.find(p$1=>p$1.datasetId===dataset.label);return path?path.linePath:``},getAreaPathForDataset=dataset=>{let path=datasetPaths.value.find(p$1=>p$1.datasetId===dataset.label);return path?path.areaPath:``},getYPosition=value=>{if(value==null||!isFinite(value))return 50;let yMin=yBounds.value.min,yMax=yBounds.value.max;if(yMin==null||yMax==null||!isFinite(yMin)||!isFinite(yMax)||yMin===yMax)return 50;if(yMin>=0||yMax<=0){let yRange$1=yMax-yMin;if(yRange$1===0)return 50;let result$1=97.5-(value-yMin)/yRange$1*95;return isFinite(result$1)?result$1:50}let yRange=Math.max(Math.abs(yMin),Math.abs(yMax));if(yRange===0)return 50;let totalRange=Math.abs(yMin)+Math.abs(yMax);if(totalRange===0)return 50;let zeroLinePosition=Math.abs(yMin)/totalRange*95+2.5,result;return result=value>=0?zeroLinePosition-value/yRange*(zeroLinePosition-2.5):zeroLinePosition+Math.abs(value)/yRange*(97.5-zeroLinePosition),isFinite(result)?result:50},formatNumber=num=>num==null||!isFinite(num)?`0`:Math.floor(num).toString(),yBounds=computed(()=>{if(props.config?.yAxis?.min!==void 0&&props.config?.yAxis?.max!==void 0)return{min:props.config.yAxis.min,max:props.config.yAxis.max};if(!props.points.length)return{min:0,max:0};let allYValues=props.points.flatMap(dataset=>(dataset.points||[]).map(point=>point&&point[1])).filter(val=>val!=null&&isFinite(val));if(allYValues.length===0)return{min:0,max:1};let min$1=Math.min(...allYValues),max$1=Math.max(...allYValues);return!isFinite(min$1)||!isFinite(max$1)?{min:0,max:1}:{min:min$1,max:max$1}}),xMinFormatted=computed(()=>formatNumber(xScale.value?.min||0)),xMaxFormatted=computed(()=>formatNumber(xScale.value?.max||0)),yMinFormatted=computed(()=>formatNumber(yBounds.value.min)),yMaxFormatted=computed(()=>formatNumber(yBounds.value.max)),hasNegativeValues=computed(()=>yBounds.value.min<0),getLabelPosition=()=>{if(!props.singleLabel)return{x:0,y:0,anchor:`start`};let labelX=props.singleLabel.x===void 0?95:getXPosition(props.singleLabel.x),labelY=props.singleLabel.y===void 0?50:getYPosition(props.singleLabel.y),adjustedY=labelY>=25?labelY+4:labelY-2,anchor=labelX>=80?`end`:`start`;return{x:anchor===`end`?Math.min(labelX,98):Math.max(labelX,2),y:adjustedY,anchor}},getLabelStyle=()=>{if(!props.singleLabel)return{};let basePos=getLabelPosition(),estimatedWidth=props.singleLabel.text.length*6.5+6,estimatedHeight=18,containerWidth=300,containerHeight=80,pixelX=basePos.x/100*300,pixelY=basePos.y/100*80,finalX=basePos.x,finalY=basePos.y,anchor=basePos.anchor,verticalAlign=`middle`;anchor===`start`?pixelX+estimatedWidth>290&&(anchor=`end`):pixelX-estimatedWidth<10&&(anchor=`start`);let minGapFromPoint=4,topBuffer=8,bottomBuffer=8,wouldOverflowTop=pixelY-18/2<8;if(pixelY+18/2>72)verticalAlign=`bottom`,finalY=Math.max(basePos.y-4,15);else if(wouldOverflowTop)verticalAlign=`top`,finalY=Math.min(basePos.y+4,85);else{let pointY=basePos.y;pointY>75?(verticalAlign=`bottom`,finalY=pointY-4):pointY<25?(verticalAlign=`top`,finalY=pointY+4):(verticalAlign=`bottom`,finalY=pointY-4)}let transformX=`translateX(0)`,transformY=`translateY(-50%)`;return anchor===`end`&&(transformX=`translateX(-100%)`),verticalAlign===`bottom`?transformY=`translateY(-100%)`:verticalAlign===`top`&&(transformY=`translateY(0)`),{position:`absolute`,left:`${finalX}%`,top:`${finalY}%`,transform:`${transformX} ${transformY}`,color:props.singleLabel.color||`var(--bng-orange)`,fontSize:`11px`,fontFamily:`sans-serif`,pointerEvents:`none`,whiteSpace:`nowrap`}};return(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$302,[__props.config.showLabels?(openBlock(),createElementBlock(`div`,_hoisted_2$249,[createBaseVNode(`div`,_hoisted_3$219,[createBaseVNode(`div`,_hoisted_4$187,toDisplayString(yMaxFormatted.value),1),createBaseVNode(`div`,_hoisted_5$160,[createTextVNode(toDisplayString(__props.config.yAxis.label)+` `,1),__props.config.yAxis.unit?(openBlock(),createElementBlock(`span`,_hoisted_6$138,`(`+toDisplayString(__props.config.yAxis.unit)+`)`,1)):createCommentVNode(``,!0)]),createBaseVNode(`div`,_hoisted_7$120,toDisplayString(yMinFormatted.value),1)])])):createCommentVNode(``,!0),(openBlock(),createElementBlock(`svg`,_hoisted_8$100,[createBaseVNode(`defs`,null,[createBaseVNode(`pattern`,{id:`grid`,width:gridSizes.value.x,height:gridSizes.value.y,patternUnits:`userSpaceOnUse`},[createBaseVNode(`path`,{d:`M ${gridSizes.value.x} 0 L ${gridSizes.value.x} ${gridSizes.value.y}`,stroke:__props.gridColor,"stroke-width":`1`,"vector-effect":`non-scaling-stroke`,opacity:`0.3`},null,8,_hoisted_10$78),createBaseVNode(`path`,{d:`M 0 ${gridSizes.value.y} L 100 ${gridSizes.value.y}`,stroke:__props.gridColor,"stroke-width":`1`,"vector-effect":`non-scaling-stroke`,opacity:`0.3`},null,8,_hoisted_11$70)],8,_hoisted_9$90),createBaseVNode(`pattern`,{id:`subgrid`,width:gridSizes.value.x,height:gridSizes.value.y,patternUnits:`userSpaceOnUse`},[createBaseVNode(`path`,{d:`M ${gridSizes.value.x/__props.subgridDivider} 0 L ${gridSizes.value.x/__props.subgridDivider} ${gridSizes.value.y}`,stroke:__props.gridColor,"stroke-width":`0.5`,"vector-effect":`non-scaling-stroke`,opacity:`0.15`},null,8,_hoisted_13$50),createBaseVNode(`path`,{d:`M 0 ${gridSizes.value.y/__props.subgridDivider} L 100 ${gridSizes.value.y/__props.subgridDivider}`,stroke:__props.gridColor,"stroke-width":`0.5`,"vector-effect":`non-scaling-stroke`,opacity:`0.15`},null,8,_hoisted_14$45)],8,_hoisted_12$58)]),__props.showSubgrid?(openBlock(),createElementBlock(`rect`,_hoisted_15$43)):createCommentVNode(``,!0),_cache[0]||=createBaseVNode(`rect`,{width:`100`,height:`100`,fill:`url(#grid)`},null,-1),createBaseVNode(`g`,_hoisted_16$40,[hasNegativeValues.value?(openBlock(),createElementBlock(`line`,{key:0,x1:`0`,y1:getYPosition(0),x2:`100`,y2:getYPosition(0),stroke:__props.gridColor,"stroke-width":`2`,"vector-effect":`non-scaling-stroke`,opacity:`0.75`},null,8,_hoisted_17$33)):createCommentVNode(``,!0)]),createBaseVNode(`g`,_hoisted_18$30,[(openBlock(!0),createElementBlock(Fragment,null,renderList(__props.ranges,range=>(openBlock(),createElementBlock(`rect`,{key:`range-${range.start}`,x:getXPosition(range.start),y:`-5`,width:getXPosition(range.end)-getXPosition(range.start),height:`110`,fill:range.fill,stroke:range.outline,"stroke-width":`2`,"vector-effect":`non-scaling-stroke`,opacity:range.opacity},null,8,_hoisted_19$25))),128))]),createBaseVNode(`g`,_hoisted_20$21,[(openBlock(!0),createElementBlock(Fragment,null,renderList(__props.verticalGuides,guide=>(openBlock(),createElementBlock(`line`,{key:`guide-${guide.x}`,x1:getXPosition(guide.x),y1:`0`,x2:getXPosition(guide.x),y2:`100`,stroke:guide.color,"stroke-width":`1`,"vector-effect":`non-scaling-stroke`,opacity:guide.opacity},null,8,_hoisted_21$19))),128))]),__props.currentX?(openBlock(),createElementBlock(`line`,{key:1,x1:getXPosition(__props.currentX),y1:`0`,x2:getXPosition(__props.currentX),y2:`100`,stroke:`white`,"stroke-width":`1`,"vector-effect":`non-scaling-stroke`,opacity:`0.8`},null,8,_hoisted_22$17)):createCommentVNode(``,!0),(openBlock(!0),createElementBlock(Fragment,null,renderList(__props.points,dataset=>(openBlock(),createElementBlock(`g`,{key:dataset.label},[dataset.fill?(openBlock(),createElementBlock(`path`,{key:0,d:getAreaPathForDataset(dataset),fill:dataset.color||`white`,opacity:dataset.fillOpacity??.5},null,8,_hoisted_23$16)):createCommentVNode(``,!0),createBaseVNode(`path`,{d:getLinePathForDataset(dataset),stroke:dataset.color||`white`,fill:`none`,"stroke-width":`1`,"vector-effect":`non-scaling-stroke`},null,8,_hoisted_24$15)]))),128))])),__props.singleLabel?(openBlock(),createElementBlock(`div`,{key:1,class:`single-label`,style:normalizeStyle(getLabelStyle())},toDisplayString(__props.singleLabel.text),5)):createCommentVNode(``,!0),__props.config.showLabels?(openBlock(),createElementBlock(`div`,_hoisted_25$14,[createBaseVNode(`div`,_hoisted_26$12,[createBaseVNode(`div`,_hoisted_27$12,toDisplayString(xMinFormatted.value),1),createBaseVNode(`div`,_hoisted_28$11,[createTextVNode(toDisplayString(__props.config.xAxis.label)+` `,1),__props.config.xAxis.unit?(openBlock(),createElementBlock(`span`,_hoisted_29$11,`(`+toDisplayString(__props.config.xAxis.unit)+`)`,1)):createCommentVNode(``,!0)]),createBaseVNode(`div`,_hoisted_30$10,toDisplayString(xMaxFormatted.value),1)])])):createCommentVNode(``,!0)]))}},bngSimpleGraph_default=__plugin_vue_export_helper_default(_sfc_main$344,[[`__scopeId`,`data-v-66d95af3`]]),_hoisted_1$301={class:`bng-slider-container`},_hoisted_2$248=[`disabled`,`min`,`max`,`step`],_sfc_main$343={__name:`bngSlider`,props:{modelValue:Number,origValue:{type:[Number,String],default:NaN},min:{type:[Number,String],default:0},max:{type:[Number,String],required:!0},step:{type:[Number,String],default:0},withReset:{type:Boolean,default:!1},withInput:{type:Boolean,default:!1},inputMultiplier:{type:Number,default:1},unit:{type:String,default:``},disabled:Boolean,uiNavFocus:{type:[Boolean,Object],default:{},validator:val=>typeof val==`boolean`&&!val||typeof val==`object`}},emits:[`change`,`valueChanged`,`update:modelValue`],setup(__props,{expose:__expose,emit:__emit}){let props=__props,emit$1=__emit,slider=ref(null),value=ref(props.modelValue);ref(!1);let uiNavFocusFunction=computed(()=>props.uiNavFocus?{callback:(dir,val)=>{value.value=val,notify()},value:()=>value.value,min:+props.min,max:+props.max,step:()=>+props.step,...props.uiNavFocus}:!1);watch(()=>props.modelValue,val=>{value.value=Number(val),updateSliderBackground()});let dirty=useDirty(value,null,updateSliderBackground),dirtyReset=useDirty(value,null,updateSliderBackground);__expose(dirty);let resetDisabled=computed(()=>props.disabled?!0:isNaN(dirtyReset.currentCleanValue.value)?!dirty.dirty.value:!dirtyReset.dirty.value);onMounted(()=>{updateSliderBackground(),inputProps.value=value.value*props.inputMultiplier});function notify(){emit$1(`update:modelValue`,value.value),emit$1(`valueChanged`,value.value),emit$1(`change`,value.value),updateSliderBackground()}function updateSliderBackground(){if(!slider.value)return;let current=(value.value-props.min)/(props.max-props.min)*100,init$3=[-100,-100],dirtyVal=dirtyReset.currentCleanValue.value;if((typeof dirtyVal!=`number`||isNaN(dirtyVal))&&(dirtyVal=dirty.currentCleanValue.value),typeof dirtyVal==`number`&&!isNaN(dirtyVal)){let initpos=(dirtyVal-props.min)/(props.max-props.min)*100;init$3[currentvalue.value,val=>{inputProps.value=val*props.inputMultiplier}),watch(()=>props.origValue,val=>{val=+val,isNaN(val)||dirtyReset.setCleanValue(val)},{immediate:!0}),watch(()=>inputProps.value,val=>{value.value=val/props.inputMultiplier});function onInputChange(num){num=Number(num);let norm=roundDecSample(num,inputProps.step);num!==norm&&(inputProps.value=norm),num=norm/props.inputMultiplier,num=roundDecSample(num,props.step),numprops.max&&(num=props.max),value.value=num,notify()}function resetValue(){let val=+props.origValue;isNaN(val)?dirty.resetValue():value.value=val,notify()}return(_ctx,_cache)=>withDirectives((openBlock(),createElementBlock(`div`,_hoisted_1$301,[withDirectives(createBaseVNode(`input`,{ref_key:`slider`,ref:slider,class:`bng-slider`,type:`range`,disabled:__props.disabled,"onUpdate:modelValue":_cache[0]||=$event=>value.value=$event,min:+__props.min,max:+__props.max,step:+__props.step,onInput:notify},null,40,_hoisted_2$248),[[vModelText,value.value,void 0,{number:!0}],[unref(BngOnUiNavFocus_default),uiNavFocusFunction.value,void 0,{repeat:!0}]]),__props.withInput?(openBlock(),createBlock(unref(bngInput_default),{key:0,class:`bng-slider-input`,disabled:__props.disabled,modelValue:inputProps.value,"onUpdate:modelValue":_cache[1]||=$event=>inputProps.value=$event,type:`number`,min:inputProps.min,max:inputProps.max,step:inputProps.step,suffix:__props.unit,onValueChanged:onInputChange},null,8,[`disabled`,`modelValue`,`min`,`max`,`step`,`suffix`])):createCommentVNode(``,!0),__props.withReset?(openBlock(),createBlock(unref(bngButton_default),{key:1,class:`bng-slider-reset`,accent:unref(ACCENTS).text,icon:unref(icons).undo,disabled:resetDisabled.value,onClick:resetValue},null,8,[`accent`,`icon`,`disabled`])):createCommentVNode(``,!0)])),[[unref(BngScopedNav_default),{bubbleWhitelistEvents:[`menu`]}],[unref(BngDisabled_default),__props.disabled]])}},bngSlider_default=__plugin_vue_export_helper_default(_sfc_main$343,[[`__scopeId`,`data-v-7d0150a1`]]),_sfc_main$342={__name:`bngSmartSelect`,props:mergeModels({items:{type:Array,required:!0},threshold:{type:Number,default:6},type:{type:String,default:``,validator(val){return[``,`select`,`dropdown`].includes(val)}},highlight:[String,Array,RegExp],disabled:Boolean},{modelValue:{},modelModifiers:{}}),emits:mergeModels([`change`],[`update:modelValue`]),setup(__props,{emit:__emit}){let props=__props,value=useModel(__props,`modelValue`),emit$1=__emit,elDropdown=ref(),elSelect=ref(),types={none:bngSelect_default,select:bngSelect_default,dropdown:bngDropdown_default},items$2=computed(()=>Array.isArray(props.items)?props.items:[]),type=computed(()=>props.type&&props.type in types?props.type:items$2.value.length===0?`none`:items$2.value.length<=props.threshold?`select`:`dropdown`),binds=computed(()=>{let res={disabled:props.disabled};switch(type.value){default:res.options=[`n/a`],res.disabled=!0;break;case`select`:res.loop=!0,res.labelClickable=!0,res.config={label:itm=>itm?.label||`n/a`,value:itm=>itm?.value},res.options=items$2.value.filter(itm=>!itm.disabled&&!itm.group),res.items=items$2.value,res.highlight=props.highlight,res.disabled||=res.options.length===0,res.popoverTarget=elSelect.value?.getElement?.(),res.focusTarget=elSelect.value?.getContentElement?.()||res.popoverTarget;break;case`dropdown`:res.items=items$2.value,res.highlight=props.highlight,res.showSearch=!0;break}return res});function openDropdown(){}function onSelectChanged(newValue){value.value!==newValue&&emit$1(`change`,newValue)}function onDropdownChanged(newValue){value.value!==newValue&&emit$1(`change`,newValue)}return(_ctx,_cache)=>(openBlock(),createElementBlock(Fragment,null,[type.value===`dropdown`?createCommentVNode(``,!0):(openBlock(),createBlock(unref(bngSelect_default),{key:0,ref_key:`elSelect`,ref:elSelect,class:`bng-smart-select`,modelValue:value.value,"onUpdate:modelValue":_cache[0]||=$event=>value.value=$event,options:binds.value.options,config:binds.value.config,disabled:binds.value.disabled,loop:``,"label-clickable":``,"label-popover":elDropdown.value?.popoverName,onLabelClick:openDropdown,onChange:onSelectChanged},null,8,[`modelValue`,`options`,`config`,`disabled`,`label-popover`])),binds.value.items?(openBlock(),createBlock(unref(bngDropdown_default),{key:1,ref_key:`elDropdown`,ref:elDropdown,class:normalizeClass(`bng-smart-${type.value}`),modelValue:value.value,"onUpdate:modelValue":_cache[1]||=$event=>value.value=$event,items:binds.value.items,highlight:binds.value.highlight,disabled:binds.value.disabled,headless:type.value===`select`,"show-search":binds.value.showSearch,"focus-target":binds.value.focusTarget,"popover-target":binds.value.popoverTarget,onValueChanged:onDropdownChanged},null,8,[`class`,`modelValue`,`items`,`highlight`,`disabled`,`headless`,`show-search`,`focus-target`,`popover-target`])):createCommentVNode(``,!0)],64))}},bngSmartSelect_default=__plugin_vue_export_helper_default(_sfc_main$342,[[`__scopeId`,`data-v-a288ad68`]]),_hoisted_1$300=[`xlink:href`],_sfc_main$341={__name:`bngSpriteIcon`,props:{atlasPath:{type:String,default:`sprites/svg-symbols.svg`},src:{type:String,required:!0},color:{type:String,default:`#fff`},deg:{type:Number,default:0}},setup(__props){let props=__props,atlasURL=computed(()=>`${getAssetURL$1(props.atlasPath)}#${props.src.toLowerCase()}`),getAssetURL$1=assetPath=>bngApi.isMock?`http://localhost:9000/${assetPath}`:`/ui/ui-vue/src/assets/${assetPath}`;return(_ctx,_cache)=>(openBlock(),createElementBlock(`svg`,{class:`atlasIcon`,style:normalizeStyle({fill:__props.color,pointerEvents:`none`,transform:`rotate(${__props.deg}deg)`}),version:`1.1`,xmlns:`http://www.w3.org/2000/svg`},[createBaseVNode(`use`,{"xlink:href":atlasURL.value},null,8,_hoisted_1$300)],4))}},bngSpriteIcon_default=__plugin_vue_export_helper_default(_sfc_main$341,[[`__scopeId`,`data-v-0ace1ddc`]]),_hoisted_1$299=[`tabindex`],_hoisted_2$247={key:0};const LABEL_ALIGNMENTS={START:`start`,END:`end`,CENTER:`center`};var _sfc_main$340={__name:`bngSwitch`,props:{modelValue:[Boolean,Number,String],checked:{type:Boolean,default:!1},label:String,labelBefore:Boolean,labelAlignment:{type:String,default:LABEL_ALIGNMENTS.END,validator:value=>Object.values(LABEL_ALIGNMENTS).includes(value)},inline:{type:Boolean,default:!0},alwaysTransparent:Boolean,disabled:Boolean,valueOn:{type:[Boolean,Number,String],default:void 0},valueOff:{type:[Boolean,Number,String],default:void 0}},emits:[`update:modelValue`,`change`,`valueChanged`],setup(__props,{emit:__emit}){let props=__props,emit$1=__emit,slots=useSlots(),bngSwitch=ref(null),valOn=computed(()=>props.valueOn===void 0?!0:props.valueOn),valOff=computed(()=>props.valueOff===void 0?!1:props.valueOff),isSwitchOn=computed(()=>props.modelValue==null?props.checked:props.modelValue===valOn.value);function onClicked(){if(props.disabled)return;let newValue=isSwitchOn.value?valOff.value:valOn.value;props.modelValue!=null&&emit$1(`update:modelValue`,newValue),emit$1(`valueChanged`,newValue),emit$1(`change`,newValue)}return onUpdated(()=>ensureFocus(bngSwitch.value)),(_ctx,_cache)=>withDirectives((openBlock(),createElementBlock(`div`,{ref_key:`bngSwitch`,ref:bngSwitch,"bng-nav-item":``,class:normalizeClass([`bng-switch`,{"bng-switch-on":isSwitchOn.value,"with-background":!__props.alwaysTransparent,"with-label":__props.label||unref(slots).default,"label-position-before":__props.labelBefore,"inline-switch":!__props.label&&!unref(slots).default||__props.inline}]),tabindex:__props.disabled?-1:0,onClick:onClicked},[_cache[0]||=createBaseVNode(`div`,{class:`bng-switch-control`},null,-1),unref(slots).default||__props.label?(openBlock(),createElementBlock(`div`,{key:0,class:normalizeClass([`bng-switch-label`,[`label-alignment-`+__props.labelAlignment]])},[renderSlot(_ctx.$slots,`default`,{},()=>[__props.label?(openBlock(),createElementBlock(`span`,_hoisted_2$247,toDisplayString(__props.label),1)):createCommentVNode(``,!0)],!0)],2)):createCommentVNode(``,!0)],10,_hoisted_1$299)),[[unref(BngOnUiNav_default),void 0,`ok`,{asMouse:!0,focusRequired:!0}],[unref(BngDisabled_default),__props.disabled]])}},bngSwitch_default=__plugin_vue_export_helper_default(_sfc_main$340,[[`__scopeId`,`data-v-8e1c4b05`]]),_hoisted_1$298={class:`bng-switch-label`},_hoisted_2$246={key:0},_sfc_main$339={__name:`bngSwitchOld`,props:{modelValue:Boolean,label:String,checked:Boolean,uncheckedWithBackground:Boolean,disabled:Boolean},emits:[`valueChanged`,`update:modelValue`],setup(__props,{emit:__emit}){let toggleValue=ref(!1),props=__props,emit$1=__emit,slots=useSlots();onBeforeMount(init$3),watch(()=>props.modelValue,init$3),watch(()=>props.checked,init$3),watch(()=>props.disabled,init$3);function init$3(){toggleValue.value=props.checked||props.modelValue}function onValueChanged(){props.disabled||(toggleValue.value=!toggleValue.value,emit$1(`update:modelValue`,toggleValue.value),emit$1(`valueChanged`,toggleValue.value))}return(_ctx,_cache)=>unref(slots).default||__props.label?withDirectives((openBlock(),createElementBlock(`div`,mergeProps({key:0,class:[`bng-labeled-switch`,{"switch-on":toggleValue.value,"with-background":__props.uncheckedWithBackground}]},{...!__props.disabled&&{"bng-nav-item":1}},{tabindex:`{{disabled ? 0 : 1}}`,onClick:onValueChanged,onKeyup:withKeys(onValueChanged,[`space`])}),[_cache[0]||=createBaseVNode(`div`,{class:`bng-switch-wrapper`},[createBaseVNode(`div`,{class:`bng-switch`})],-1),createBaseVNode(`div`,_hoisted_1$298,[renderSlot(_ctx.$slots,`default`,{},()=>[__props.label?(openBlock(),createElementBlock(`label`,_hoisted_2$246,toDisplayString(__props.label),1)):createCommentVNode(``,!0)],!0)])],16)),[[unref(BngDisabled_default),__props.disabled]]):withDirectives((openBlock(),createElementBlock(`div`,mergeProps({key:1},{...!__props.disabled&&{"bng-nav-item":1}},{tabindex:`{{disabled ? 0 : 1}}`,class:[`bng-switch-wrapper`,{"switch-on":toggleValue.value}],onClick:onValueChanged,onKeyup:withKeys(onValueChanged,[`space`])}),[..._cache[1]||=[createBaseVNode(`div`,{class:`bng-switch`},null,-1)]],16)),[[unref(BngDisabled_default),__props.disabled]])}},bngSwitchOld_default=__plugin_vue_export_helper_default(_sfc_main$339,[[`__scopeId`,`data-v-da8dc7b1`]]),_hoisted_1$297={"bng-nav-item":``,class:`bng-tile tile`},_hoisted_2$245={class:`content`},_hoisted_3$218={class:`label`},_sfc_main$338={__name:`bngTile`,props:{label:String,ratio:{type:String,default:`4:3`},backgroundImage:String,backgroundExternalImage:String,disabled:Boolean},setup(__props){return(_ctx,_cache)=>withDirectives((openBlock(),createElementBlock(`div`,_hoisted_1$297,[createVNode(unref(aspectRatio_default),{class:`content-container image`,ratio:__props.ratio,image:__props.backgroundImage,externalImage:__props.backgroundExternalImage,imageMode:`contain`},{default:withCtx(()=>[createBaseVNode(`div`,_hoisted_2$245,[renderSlot(_ctx.$slots,`default`,{},void 0,!0)])]),_:3},8,[`ratio`,`image`,`externalImage`]),renderSlot(_ctx.$slots,`label`,{},()=>[createBaseVNode(`div`,_hoisted_3$218,toDisplayString(__props.label),1)],!0)])),[[unref(BngDisabled_default),__props.disabled]])}},bngTile_default=__plugin_vue_export_helper_default(_sfc_main$338,[[`__scopeId`,`data-v-af5747cc`]]),_sfc_main$337={__name:`bngTooltip`,props:{text:{type:String,required:!0},position:{type:String,default:`top`}},setup(__props){return(_ctx,_cache)=>withDirectives((openBlock(),createElementBlock(`div`,null,[renderSlot(_ctx.$slots,`default`,{},void 0,!0)])),[[unref(BngTooltip_default),__props.text,__props.position]])}},bngTooltip_default=__plugin_vue_export_helper_default(_sfc_main$337,[[`__scopeId`,`data-v-53073c36`]]),toInt=v=>~~+v,_sfc_main$336={__name:`bngUnit`,props:{options:Object,formatter:[Function,String]},setup(__props){let{units}=useBridge(),knownUnits={money:{formatter:v=>units.beamBucks(v)},beamXP:{formatter:toInt},stars:{formatter:toInt},vouchers:{formatter:toInt},insuranceScore:{formatter:toInt},multiplier:{formatter:toInt,noGap:!0}},defaultColors={stars:`var(--bng-ter-yellow-200)`,vouchers:`var(--bng-add-blue-400)`},attrs=useAttrs(),unit=computed(()=>{for(let key of Object.keys(attrs))if(key in knownUnits)return{type:key,value:attrs[key],...knownUnits[key],...props.options};return{type:`unknown`}}),formattedValue=computed(()=>{if(props.formatter){if(typeof props.formatter==`function`)return props.formatter(unit.value.value);if(typeof props.formatter==`string`&&props.formatter in knownUnits)return knownUnits[props.formatter].formatter(unit.value.value)}return typeof unit.value.formatter==`function`?unit.value.formatter(unit.value.value):unit.value.value}),props=__props;return(_ctx,_cache)=>(openBlock(),createBlock(unref(slotSwitcher_default),mergeProps(unref(attrs),{slotId:unit.value.type}),{money:withCtx(props$1=>[createVNode(unref(bngPropVal_default),mergeProps({...props$1,...unit.value},{iconType:props$1.iconType||unref(icons).beamCurrency,valueLabel:formattedValue.value}),null,16,[`iconType`,`valueLabel`])]),beamXP:withCtx(props$1=>[createVNode(unref(bngPropVal_default),mergeProps({...props$1,...unit.value},{iconType:props$1.iconType||unref(icons).beamXPLo,valueLabel:formattedValue.value}),null,16,[`iconType`,`valueLabel`])]),stars:withCtx(props$1=>[createVNode(unref(bngPropVal_default),mergeProps({...props$1,...unit.value},{iconType:props$1.iconType||unref(icons).star,valueLabel:formattedValue.value,"icon-color":defaultColors.stars}),null,16,[`iconType`,`valueLabel`,`icon-color`])]),vouchers:withCtx(props$1=>[createVNode(unref(bngPropVal_default),mergeProps({...props$1,...unit.value},{iconType:props$1.iconType||unref(icons).voucherHorizontal3,valueLabel:formattedValue.value,"icon-color":defaultColors.vouchers}),null,16,[`iconType`,`valueLabel`,`icon-color`])]),insuranceScore:withCtx(props$1=>[createVNode(unref(bngPropVal_default),mergeProps({...props$1,...unit.value},{iconType:props$1.iconType||unref(icons).shieldCheckmarkProgressbar,valueLabel:formattedValue.value}),null,16,[`iconType`,`valueLabel`])]),multiplier:withCtx(props$1=>[createVNode(unref(bngPropVal_default),mergeProps({...props$1,...unit.value},{iconType:props$1.iconType||unref(icons).mathMultiply,valueLabel:formattedValue.value,"icon-color":defaultColors.multiplier}),null,16,[`iconType`,`valueLabel`,`icon-color`])]),unknown:withCtx(props$1=>[createBaseVNode(`span`,normalizeProps(guardReactiveProps(props$1)),`BngUnit: Unknown unit type or no type specified`,16)]),_:1},16,[`slotId`]))}},bngUnit_default=_sfc_main$336;const DEMOS={};var base_exports=__export({ACCENTS:()=>ACCENTS,BngActionDrawer:()=>bngActionDrawer_default,BngActionsDrawer:()=>bngActionsDrawer_default,BngActionsDrawerOne:()=>bngActionsDrawerOne_default,BngActionsList:()=>bngActionsList_default,BngBinding:()=>bngBinding_default,BngBreadcrumbs:()=>bngBreadcrumbs_default,BngButton:()=>bngButton_default,BngCard:()=>bngCard_default,BngCardHeading:()=>bngCardHeading_default,BngColorPicker:()=>bngColorPicker_default,BngColorSlider:()=>bngColorSlider_default,BngColorTile:()=>bngColorTile_default,BngCondition:()=>bngCondition_default,BngControllerHint:()=>bngControllerHint_default,BngDivider:()=>bngDivider_default,BngDrawer:()=>bngDrawer_default,BngDrawerOld:()=>bngDrawerOld_default,BngDropdown:()=>bngDropdown_default,BngDropdownContainer:()=>bngDropdownContainer_default,BngIcon:()=>bngIcon_default,BngIconMarker:()=>bngIconMarker_default,BngImage:()=>bngImage_default,BngImageAsset:()=>bngImageAsset_default,BngImageCarousel:()=>bngImageCarousel_default,BngImageTile:()=>bngImageTile_default,BngInput:()=>bngInput_default,BngInputNew:()=>bngInputNew_default,BngList:()=>bngList_default,BngMainStars:()=>bngMainStars_default,BngMultilineInput:()=>bngMultilineInput_default,BngOldIcon:()=>bngOldIcon_default,BngOverflowContainer:()=>bngOverflowContainer_default,BngPaintTile:()=>bngPaintTile_default,BngPill:()=>bngPill_default,BngPillCheckbox:()=>bngPillCheckbox_default,BngPillFilters:()=>bngPillFilters_default,BngPillFiltersContainer:()=>bngPillFiltersContainer_default,BngPopoverContent:()=>bngPopoverContent_default,BngPopoverMenu:()=>bngPopoverMenu_default,BngProgressBar:()=>bngProgressBar_default,BngPropVal:()=>bngPropVal_default,BngScreenHeading:()=>bngScreenHeading_default,BngScreenHeadingV2:()=>bngScreenHeadingV2_default,BngSelect:()=>bngSelect_default,BngSimpleGraph:()=>bngSimpleGraph_default,BngSlider:()=>bngSlider_default,BngSmartSelect:()=>bngSmartSelect_default,BngSpriteIcon:()=>bngSpriteIcon_default,BngSwitch:()=>bngSwitch_default,BngSwitchOld:()=>bngSwitchOld_default,BngTile:()=>bngTile_default,BngTooltip:()=>bngTooltip_default,BngUnit:()=>bngUnit_default,DEMOS:()=>DEMOS,LABEL_ALIGNMENTS:()=>LABEL_ALIGNMENTS,LIST_LAYOUTS:()=>LIST_LAYOUTS,STEP_ICON_TYPES:()=>STEP_ICON_TYPES,getIconsWithTags:()=>getIconsWithTags,icons:()=>icons,iconsBySize:()=>iconsBySize,iconsByTag:()=>iconsByTag});function getPopupWrapperDefaults(){return{fade:!1,blur:!0,style:[popupContainer.default]}}function getActivityWrapperDefaults(){return{fade:!1,blur:!1,style:[popupContainer.clickthrough]}}const popupContainer=Object.freeze({default:`default`,transparent:`transparent`,clickthrough:`clickthrough`}),popupPosition=Object.freeze({default:`center`,top:`top`,left:`left`,right:`right`,bottom:`bottom`,center:`center`,fullscreen:`fullscreen`});var _hoisted_1$296=[`bng-ui-scope`],_hoisted_2$244={class:`popup-content`},_hoisted_3$217={key:0,class:`popup-title`},_hoisted_4$186={key:1,class:`popup-body`},_hoisted_5$159=[`innerHTML`],_hoisted_6$137={class:`popup-buttons`},__default__$10={wrapper:{blur:!0,style:null},position:popupPosition.center,animated:!0},_sfc_main$335=Object.assign(__default__$10,{__name:`Confirmation`,props:{appearance:String,popupActive:Boolean,message:{type:[String,Object],required:!0},title:String,buttons:Array},emits:[`return`],setup(__props,{emit:__emit}){useUINavBlocker().allowNavigationOnly();let props=__props,emit$1=__emit,scopeName=usePopupUINavScopeName(`_confirmPopup`,props),defaultButtonIndex=props.buttons.findIndex(button=>button.extras&&button.extras.default);defaultButtonIndex===-1&&(defaultButtonIndex=0);let cancelButton=props.buttons.find(button=>button.extras&&button.extras.cancel),exclude=[`default`,`cancel`],buttonProps=computed(()=>{let bp=[];for(let{extras}of props.buttons)extras?bp.push(Object.keys(extras).reduce((ex,key)=>exclude.includes(key)?ex:{...ex,[key]:extras[key]},{})):bp.push({});return bp}),messageIsComponent=computed(()=>props.message&&typeof props.message==`object`&&props.message.component),handleCancelWithBack=()=>emit$1(`return`,cancelButton?cancelButton.value:null);return(_ctx,_cache)=>withDirectives((openBlock(),createElementBlock(`div`,{class:normalizeClass([`popup`,`popup-style-`+__props.appearance]),"bng-ui-scope":unref(scopeName)},[createBaseVNode(`div`,_hoisted_2$244,[__props.title?(openBlock(),createElementBlock(`div`,_hoisted_3$217,toDisplayString(__props.title),1)):createCommentVNode(``,!0),messageIsComponent.value?(openBlock(),createElementBlock(`div`,_hoisted_4$186,[(openBlock(),createBlock(resolveDynamicComponent(__props.message.component),normalizeProps(guardReactiveProps(__props.message.props)),null,16))])):(openBlock(),createElementBlock(`div`,{key:2,class:`popup-body`,innerHTML:__props.message},null,8,_hoisted_5$159)),createBaseVNode(`div`,_hoisted_6$137,[(openBlock(!0),createElementBlock(Fragment,null,renderList(__props.buttons,(button,index)=>withDirectives((openBlock(),createBlock(unref(bngButton_default),mergeProps({key:index},{ref_for:!0},buttonProps.value[index],{onClick:$event=>_ctx.$emit(`return`,button.value)}),{default:withCtx(()=>[createTextVNode(toDisplayString(button.label),1)]),_:2},1040,[`onClick`])),[[unref(BngUiNavFocus_default),index===unref(defaultButtonIndex)?1e3:void 0]])),128))])])],10,_hoisted_1$296)),[[unref(BngOnUiNav_default),handleCancelWithBack,`back,menu`]])}}),Confirmation_default=__plugin_vue_export_helper_default(_sfc_main$335,[[`__scopeId`,`data-v-ce4a758b`]]),_hoisted_1$295=[`bng-ui-scope`],_hoisted_2$243={key:0,class:`form-dialog-toolbar`},_hoisted_3$216={class:`toolbar-title`},_hoisted_4$185={key:0,class:`content-description`},_hoisted_5$158={class:`content-wrapper`},_hoisted_6$136={class:`form-actions-bar`},_sfc_main$334={__name:`FormDialog`,props:mergeModels({title:{type:String},description:{type:String},view:{type:[Object,String],required:!0},formValidator:{type:Function,default:formModel=>!0},buttons:{type:Array,required:!0},maxWidth:{type:String,default:`40rem`}},{formModel:{},formModelModifiers:{}}),emits:mergeModels([`return`],[`update:formModel`]),setup(__props,{emit:__emit}){useUINavBlocker().allowOnly([`focus_u`,`focus_d`,`focus_l`,`focus_r`,`back`,`menu`,`ok`]);let props=__props,emit$1=__emit,formModel=useModel(__props,`formModel`),scopeName=usePopupUINavScopeName(`_formdialog`,props),handleCancelWithBack=()=>{let cancelButton=props.buttons.find(x=>x.extras&&x.extras.cancel);cancelButton?onClick(cancelButton):emit$1(`return`)},onClick=button=>{let data={value:button.value};button.emitData&&(data.formData=formModel.value),emit$1(`return`,data)},formValid=ref(!1),message=ref(null);return watch(formModel,()=>{let res=props.formValidator(formModel.value);message.value=res.error?res.message:props.description,formValid.value=!res.error},{immediate:!0,deep:!0}),(_ctx,_cache)=>withDirectives((openBlock(),createElementBlock(`div`,{class:`form-dialog`,style:normalizeStyle({maxWidth:props.maxWidth}),"bng-ui-scope":unref(scopeName)},[__props.title?(openBlock(),createElementBlock(`div`,_hoisted_2$243,[createBaseVNode(`div`,_hoisted_3$216,toDisplayString(__props.title),1)])):createCommentVNode(``,!0),createBaseVNode(`div`,{class:normalizeClass([{"no-title":!__props.title},`form-dialog-content`])},[message.value?(openBlock(),createElementBlock(`div`,_hoisted_4$185,toDisplayString(message.value),1)):createCommentVNode(``,!0),createBaseVNode(`div`,_hoisted_5$158,[(openBlock(),createBlock(resolveDynamicComponent(__props.view),{modelValue:formModel.value,"onUpdate:modelValue":_cache[0]||=$event=>formModel.value=$event},null,8,[`modelValue`]))])],2),createBaseVNode(`div`,_hoisted_6$136,[(openBlock(!0),createElementBlock(Fragment,null,renderList(__props.buttons,(button,index)=>withDirectives((openBlock(),createBlock(unref(bngButton_default),mergeProps({key:index},{ref_for:!0},button.extras,{disabled:button.disableIfInvalid&&!formValid.value,onClick:$event=>onClick(button)}),{default:withCtx(()=>[createTextVNode(toDisplayString(button.label),1)]),_:2},1040,[`disabled`,`onClick`])),[[unref(BngUiNavFocus_default),__props.buttons.length-index],[unref(BngFocusIf_default),index===0]])),128))])],12,_hoisted_1$295)),[[unref(BngOnUiNav_default),handleCancelWithBack,`back,menu`]])}},FormDialog_default=__plugin_vue_export_helper_default(_sfc_main$334,[[`__scopeId`,`data-v-e78a3aa6`]]),_hoisted_1$294=[`bng-ui-scope`],_hoisted_2$242={class:`popup-content`},_hoisted_3$215={key:0,class:`popup-title`},_hoisted_4$184={class:`popup-body`},_hoisted_5$157={key:0,class:`popup-message`},_hoisted_6$135={class:`popup-buttons`},_sfc_main$333={__name:`Progress`,props:{title:String,message:String,buttons:Array,indeterminate:Boolean,min:{type:Number,default:0},max:{type:Number,default:100},initialValue:{type:Number,default:0},valueLabelFormat:{type:[String,Function],default:()=>val=>`${val}%`},timeout:{type:Number,default:0},cancellable:Boolean,tunnel:Object},emits:[`return`],setup(__props,{emit:__emit}){useUINavBlocker().allowOnly([`focus_u`,`focus_d`,`focus_l`,`focus_r`,`back`,`menu`,`ok`]);let emit$1=__emit,DEFAULT_BUTTON_ID=uniqueId(`___DEFAULT`,`_`),props=__props,defaultButtonIndex=props.buttons.findIndex(button=>button.extras&&button.extras.default),cancelButton=props.buttons.find(button=>button.extras&&button.extras.cancel);~defaultButtonIndex&&onMounted(()=>{document.querySelector(`#${DEFAULT_BUTTON_ID}`).focus()});let scopeName=usePopupUINavScopeName(`_progressPopup`,props),progressValue=ref(props.initialValue),msg=ref(props.message),handleCancelWithBack=e=>{props.cancellable&&close()},close=()=>emit$1(`return`,cancelButton?cancelButton.value:null);return props.tunnel.update=(value,message=void 0)=>{progressValue.value=+value,message!==void 0&&(msg.value=message)},props.tunnel.done=close,props.tunnel.ready=!0,props.timeout&&setTimeout(close,props.timeout*1e3),(_ctx,_cache)=>withDirectives((openBlock(),createElementBlock(`div`,{class:normalizeClass([`popup`]),"bng-ui-scope":unref(scopeName)},[createBaseVNode(`div`,_hoisted_2$242,[__props.title?(openBlock(),createElementBlock(`div`,_hoisted_3$215,toDisplayString(__props.title),1)):createCommentVNode(``,!0),createBaseVNode(`div`,_hoisted_4$184,[msg.value?(openBlock(),createElementBlock(`div`,_hoisted_5$157,toDisplayString(msg.value),1)):createCommentVNode(``,!0),createVNode(unref(bngProgressBar_default),{value:progressValue.value,min:__props.min,max:__props.max,indeterminate:__props.indeterminate,"show-value-label":!__props.indeterminate&&!!__props.valueLabelFormat,"value-label-format":__props.valueLabelFormat},null,8,[`value`,`min`,`max`,`indeterminate`,`show-value-label`,`value-label-format`])]),createBaseVNode(`div`,_hoisted_6$135,[__props.buttons&&__props.buttons.length?(openBlock(!0),createElementBlock(Fragment,{key:0},renderList(__props.buttons,(button,index)=>(openBlock(),createBlock(unref(bngButton_default),mergeProps({key:index},{ref_for:!0},{...index==unref(defaultButtonIndex)&&{id:unref(DEFAULT_BUTTON_ID)},...button.extras},{onClick:$event=>_ctx.$emit(`return`,typeof button.value==`function`?button.value(_ctx.text):button.value)}),{default:withCtx(()=>[createTextVNode(toDisplayString(button.label),1)]),_:2},1040,[`onClick`]))),128)):createCommentVNode(``,!0)])])],8,_hoisted_1$294)),[[unref(BngOnUiNav_default),handleCancelWithBack,`back,menu`]])}},Progress_default=__plugin_vue_export_helper_default(_sfc_main$333,[[`__scopeId`,`data-v-a3c03360`]]),_hoisted_1$293=[`bng-ui-scope`],_hoisted_2$241={class:`popup-content`},_hoisted_3$214={key:0,class:`popup-title`},_hoisted_4$183={class:`popup-body`},_hoisted_5$156={key:0,class:`popup-message`},_hoisted_6$134={class:`popup-buttons`},_sfc_main$332={__name:`Prompt`,props:{buttons:Array,message:String,title:String,maxLength:Number,defaultValue:void 0,validate:Function,errorMessage:String,disableWhenInvalid:Boolean},emits:[`return`],setup(__props,{emit:__emit}){let emit$1=__emit,DEFAULT_BUTTON_ID=uniqueId(`___DEFAULT`,`_`),INPUT_ID=uniqueId(`___INPUT`,`_`),props=__props,scopeName=usePopupUINavScopeName(`_promptPopup`,props),text=ref(props.defaultValue||``),defaultButtonIndex=props.buttons.findIndex(button=>button.extras&&button.extras.default),cancelButton=props.buttons.find(button=>button.extras&&button.extras.cancel),handleEnterButton=text$1=>{props.disableWhenInvalid&&props.validate&&!props.validate(text$1)||emit$1(`return`,text$1)},handleCancelWithBack=e=>{emit$1(`return`,cancelButton?cancelButton.value:null)};return onMounted(()=>{document.querySelector(`#${INPUT_ID} input`).focus()}),(_ctx,_cache)=>withDirectives((openBlock(),createElementBlock(`div`,{class:normalizeClass([`popup`]),"bng-ui-scope":unref(scopeName)},[createBaseVNode(`div`,_hoisted_2$241,[__props.title?(openBlock(),createElementBlock(`div`,_hoisted_3$214,toDisplayString(__props.title),1)):createCommentVNode(``,!0),createBaseVNode(`div`,_hoisted_4$183,[__props.message?(openBlock(),createElementBlock(`div`,_hoisted_5$156,toDisplayString(__props.message),1)):createCommentVNode(``,!0),createVNode(unref(bngInput_default),{id:unref(INPUT_ID),modelValue:text.value,"onUpdate:modelValue":_cache[0]||=$event=>text.value=$event,maxlength:__props.maxLength,onKeyup:_cache[1]||=withKeys($event=>handleEnterButton(text.value),[`enter`]),validate:__props.validate,"error-message":__props.errorMessage},null,8,[`id`,`modelValue`,`maxlength`,`validate`,`error-message`])]),createBaseVNode(`div`,_hoisted_6$134,[(openBlock(!0),createElementBlock(Fragment,null,renderList(__props.buttons,(button,index)=>(openBlock(),createBlock(unref(bngButton_default),mergeProps({key:index},{ref_for:!0},{...index==unref(defaultButtonIndex)&&{id:unref(DEFAULT_BUTTON_ID)},...button.extras},{disabled:__props.disableWhenInvalid&&index>0&&__props.validate&&!__props.validate(text.value),onClick:$event=>_ctx.$emit(`return`,typeof button.value==`function`?button.value(text.value):button.value)}),{default:withCtx(()=>[createTextVNode(toDisplayString(button.label),1)]),_:2},1040,[`disabled`,`onClick`]))),128))])])],8,_hoisted_1$293)),[[unref(BngOnUiNav_default),handleCancelWithBack,`back,menu`]])}},Prompt_default=__plugin_vue_export_helper_default(_sfc_main$332,[[`__scopeId`,`data-v-cce4437b`]]),__default__$9={position:popupPosition.left},_sfc_main$331=Object.assign(__default__$9,{__name:`ScreenOverlay`,props:{view:Object},emits:[`return`],setup(__props){return(_ctx,_cache)=>(openBlock(),createBlock(resolveDynamicComponent(__props.view),{onClose:_cache[0]||=$event=>_ctx.$emit(`return`,!0)},null,32))}}),ScreenOverlay_default=_sfc_main$331,popup_components_exports=__export({Confirmation:()=>Confirmation_default,FormDialog:()=>FormDialog_default,Progress:()=>Progress_default,Prompt:()=>Prompt_default,ScreenOverlay:()=>ScreenOverlay_default}),popupLimit=5,activityLimit=3,count=-1;const PopupTypes=Object.freeze({activity:10,normal:100,priority:1e3});var PopupTypesBack=Object.freeze(Object.keys(PopupTypes).reduce((res,key)=>({...res,[String(PopupTypes[key])]:key}),{})),PopupTypesPairs=Object.freeze(Object.keys(PopupTypes).map(key=>[PopupTypes[key],key]).sort((a$1,b)=>a$1[0]-b[0]));function getPopupTypeName(type=PopupTypes.normal){let strType=String(type);if(strType in PopupTypesBack)return PopupTypesBack[strType];for(let[ptype,pname]of PopupTypesPairs)if(typepopupsAll.filter(itm=>itm.type>=PopupTypes.normal)),activitiesFiltered=computed(()=>popupsAll.filter(itm=>itm.typepopupsFiltered.value.length>0?popupsFiltered.value.slice(-popupLimit):null),popupsWrapper:computed(()=>accumulateWrapper(popupsFiltered.value,getPopupWrapperDefaults())),activities:computed(()=>activitiesFiltered.value.length>0?activitiesFiltered.value.slice(-activityLimit):null),activitiesWrapper:computed(()=>accumulateWrapper(activitiesFiltered.value,getActivityWrapperDefaults()))});function accumulateWrapper(popups,wrapper){for(let popup of popups)wrapper.fade!==popup.wrapper.fade&&(wrapper.fade=popup.wrapper.fade),wrapper.blur!==popup.wrapper.blur&&(wrapper.blur=popup.wrapper.blur),popup.wrapper.style&&wrapper.style.push(...popup.wrapper.style);return wrapper}function addPopup(componentOrName,props={},type=PopupTypes.normal){let component=typeof componentOrName==`string`?popup_components_exports[componentOrName]:componentOrName;if(!component)throw Error(`There is no popup base component named "${componentOrName}".Available components: "${Object.keys(popup_components_exports).join(`", "`)}"`);let popup={id:++count,active:!1,type,typeName:getPopupTypeName(type),component:markRaw({ref:component}),componentName:component.__name,props:{__id:count,...props},position:[popupPosition.default],animated:!0,wrapper:type>=PopupTypes.normal?getPopupWrapperDefaults():getActivityWrapperDefaults()};component.position&&(popup.position=Array.isArray(component.position)?component.position:[component.position]),typeof component.animated==`boolean`&&(popup.animated=component.animated),`wrapper`in component&&(typeof component.wrapper.fade==`boolean`&&(popup.wrapper.fade=component.wrapper.fade),typeof component.wrapper.blur==`boolean`&&(popup.wrapper.blur=component.wrapper.blur),component.wrapper.style&&(popup.wrapper.style=Array.isArray(component.wrapper.style)?component.wrapper.style:[component.wrapper.style])),popup.promise=new Promise((resolve$1,reject)=>{popup._resolve=resolve$1,popup._reject=reject}),popup.return=result=>{for(let i=0;i0&&(popupsAll[popupsAll.length-1].active=!0),reportPopupState(popup,!1);break}result===void 0?popup._reject():popup._resolve(result)},popup.promise.close=popup.return;for(let i=0;itype)return popupsAll.splice(i,0,popup),reportPopupState(popup,!0),popup;return popupsAll.length>0&&(popupsAll[popupsAll.length-1].active=!1),popup.active=!0,popupsAll.push(popup),reportPopupState(popup,!0),popup}function closeLastPopups(count$1=1){popupsAll.slice(-count$1).forEach(popup=>popup.return())}const openMessage=(title,message)=>addPopup(`Confirmation`,{title,message,buttons:[{label:$translate.instant(`ui.common.okay`),value:!0,extras:{default:!0}}]}).promise,openConfirmation=(title,message,buttons=[{label:$translate.instant(`ui.common.okay`),value:!0,extras:{default:!0}},{label:$translate.instant(`ui.common.cancel`),value:!1,extras:{cancel:!0,accent:ACCENTS.secondary}}],appearance=``)=>addPopup(`Confirmation`,{title,message,buttons,appearance}).promise,openPrompt=(message=``,title=``,{buttons=[{label:$translate.instant(`ui.common.okay`),value:text=>text},{label:$translate.instant(`ui.common.cancel`),value:!1,extras:{cancel:!0,accent:ACCENTS.secondary}}],defaultValue,maxLength,validate,errorMessage,disableWhenInvalid}={})=>addPopup(`Prompt`,{message,title,buttons,defaultValue,maxLength,validate,errorMessage,disableWhenInvalid}).promise,openExperimental=(title,message,buttons=[{label:$translate.instant(`ui.common.yes`),value:!0},{label:$translate.instant(`ui.common.no`),value:!1}])=>addPopup(`Confirmation`,{title,message,buttons,appearance:`experimental`}).promise,openScreenOverlay=component=>addPopup(`ScreenOverlay`,{view:markRaw(component)},PopupTypes.activity).promise,openFormDialog=(component,formModel,formValidator,title,description,buttons=[{label:$translate.instant(`ui.common.okay`),value:!0,emitData:!0},{label:$translate.instant(`ui.common.cancel`),value:!1,extras:{cancel:!0,accent:ACCENTS.secondary}}],maxWidth)=>addPopup(`FormDialog`,{view:markRaw(component),formModel,formValidator,title,description,buttons,maxWidth},PopupTypes.normal).promise,openProgress=(message=``,title=``,{buttons=[],indeterminate,min:min$1,max:max$1,initialValue,valueLabelFormat,timeout,cancellable}={})=>{let popup=addPopup(`Progress`,{message,title,buttons,indeterminate,min:min$1,max:max$1,initialValue,valueLabelFormat,timeout,cancellable,tunnel:{}});return popup.progress=popup.props.tunnel,popup.progress.done=popup.return,popup},fixedDelayPopup=(seconds,{makeRemainingText=s=>s?Math.round(s)+`s remaining...`:`Done!`,title=``}={})=>{let popup=openProgress(makeRemainingText(seconds),title,{timeout:seconds+1}),remaining=seconds,endTime=Date.now()+remaining*1e3,countdown=()=>{let timeLeft=(endTime-Date.now())/1e3;timeLeft>0?(remaining=timeLeft,requestAnimationFrame(countdown)):remaining=0,popup.progress.update(~~((seconds-remaining)*100/seconds),makeRemainingText(remaining))};return requestAnimationFrame(countdown),popup};var _hoisted_1$292={class:`activity-selector`},_hoisted_2$240={class:`activities-container`},_hoisted_3$213=[`onClick`],_hoisted_4$182={class:`selector-display`},selectConfig={label:x=>x.label,value:x=>x.value},_sfc_main$330={__name:`ActivitySelector`,props:{activities:{type:Array,required:!0},value:{type:[String,Number]},navLeftEvent:{type:String},navRightEvent:{type:String}},emits:[`valueChanged`],setup(__props,{expose:__expose,emit:__emit}){let props=__props,selectComponent=ref(),emit$1=__emit,activityOptions=computed(()=>props.activities.map((x,index)=>({label:index+1,value:x.value})));computed(()=>(activityOptions.value?activityOptions.value.find(x=>x.value===selectedValue.value):null)||{label:`?`,value:selectedValue.value});let selectedValue=ref(1);watch(()=>props.value,val=>selectedValue.value=val||props.activities[0].value,{immediate:!0});let onValueChanged=value=>{selectedValue.value=value,console.log(`onValueChanged`,value),emit$1(`valueChanged`,value)};return __expose({goNext:()=>selectComponent.value.goNext(),goPrev:()=>selectComponent.value.goPrev()}),computed(()=>`url("${getAssetURL(`icons/temp_debug/map_poi_target.svg`)}")`),(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$292,[createBaseVNode(`div`,_hoisted_2$240,[(openBlock(!0),createElementBlock(Fragment,null,renderList(__props.activities,activity=>(openBlock(),createElementBlock(`div`,{key:activity,class:normalizeClass([`activity-icon`,{highlighted:activity.value===selectedValue.value}]),onClick:$event=>onValueChanged(activity.value)},[createVNode(unref(bngSpriteIcon_default),{src:`map_`+activity.icon,style:{width:`100%`,height:`100%`}},null,8,[`src`])],10,_hoisted_3$213))),128))]),createVNode(unref(bngSelect_default),{ref_key:`selectComponent`,ref:selectComponent,value:selectedValue.value,options:activityOptions.value,config:selectConfig,mute:``,loop:``,onChange:onValueChanged,navLeftEvent:__props.navLeftEvent,navRightEvent:__props.navRightEvent},{display:withCtx(({label})=>[createBaseVNode(`div`,_hoisted_4$182,[createBaseVNode(`span`,null,toDisplayString(label),1),createVNode(unref(bngDivider_default)),createBaseVNode(`span`,null,toDisplayString(__props.activities.length),1)])]),_:1},8,[`value`,`options`,`navLeftEvent`,`navRightEvent`])]))}},ActivitySelector_default=__plugin_vue_export_helper_default(_sfc_main$330,[[`__scopeId`,`data-v-53fb9327`]]),_hoisted_1$291={key:0,class:`activity-start`,"bng-ui-scope":`activityStart`},_hoisted_2$239={class:`activity-props`},_hoisted_3$212={class:`binding-spacer`},BNG_MAIN_STARS_TYPE=`BngMainStars`,_sfc_main$329={__name:`ActivityStart`,setup(__props){useUINavScope(`activityStart`);let activitySelector=ref(null),goNext=()=>activitySelector.value&&activitySelector.value.goNext(),goPrev=()=>activitySelector.value&&activitySelector.value.goPrev(),gameContextStore=useGameContextStore(),{activities}=storeToRefs(gameContextStore),{closeActivitiesPrompt}=gameContextStore,selectedActivityIndex=ref(0),availableActivities=ref([]),activityOptions=computed(()=>{let result=availableActivities.value?availableActivities.value.map((x,index)=>({id:index,value:index,icon:x.icon})):[];return doFiltering&&filterEvents(result.length>1),result}),selectedActivity=computed(()=>{if(selectedActivityIndex.value<0||!availableActivities.value||availableActivities.value.length===0)return null;let activity=availableActivities.value[selectedActivityIndex.value],labels=activity.props&&activity.props.length>0?activity.props.filter(x=>!x.type):[];return{heading:activity.heading,icon:activity.icon,preheadings:activity.preheadings,labels:labels.map(x=>({keyLabel:$translate.instant(x.keyLabel),valueLabel:$translate.instant(x.valueLabel),icon:icons[x.icon]})),stars:activity.props&&activity.props.length>0?activity.props.find(x=>x.type===BNG_MAIN_STARS_TYPE):null,startable:!0,buttonLabel:activity.buttonLabel,action:activity.action,missionInfoPerformActionIndex:activity.missionInfoPerformActionIndex}}),preheadings=computed(()=>selectedActivity.value&&selectedActivity.value.preheadings?selectedActivity.value.preheadings.map(x=>$translate.contextTranslate(x)):[]),invokeActivityAction=()=>{Lua_default.ui_missionInfo.performActivityAction(selectedActivity.value.missionInfoPerformActionIndex)};watch(selectedActivity,()=>{Lua_default.ui_missionInfo.setActivityIndexVisible(selectedActivityIndex.value)});let onActivitySelected=value=>{selectedActivityIndex.value=value},onCancel=()=>{closeActivitiesPrompt()},openPauseMenu=()=>{onCancel(),window.globalAngularRootScope&&window.globalAngularRootScope.$broadcast(`MenuToggle`)};onBeforeMount(()=>{availableActivities.value=activities.value}),onMounted(()=>{getUINavServiceInstance().activate()}),onUnmounted(()=>{doFiltering=!1,getUINavServiceInstance().setFilteredEventsAllExcept(UI_EVENTS.menu,UI_EVENTS.pause,UI_EVENTS.center_cam),Lua_default.ui_missionInfo.setActivityIndexVisible(-1)});let doFiltering=!0,filterEvents=withTabs=>getUINavServiceInstance().setFilteredEventsAllExcept(UI_EVENTS.back,UI_EVENTS.menu,UI_EVENTS.pause,UI_EVENTS.center_cam,...withTabs?[UI_EVENTS.tab_l,UI_EVENTS.tab_r]:[]);return(_ctx,_cache)=>selectedActivity.value?withDirectives((openBlock(),createElementBlock(`div`,_hoisted_1$291,[activityOptions.value&&activityOptions.value.length>1?(openBlock(),createBlock(ActivitySelector_default,{key:0,ref_key:`activitySelector`,ref:activitySelector,activities:activityOptions.value,value:selectedActivityIndex.value,onValueChanged:onActivitySelected,navLeftEvent:`tab_l`,navRightEvent:`tab_r`},null,8,[`activities`,`value`])):createCommentVNode(``,!0),selectedActivity.value.heading?(openBlock(),createBlock(unref(bngScreenHeading_default),{key:1,mute:``,divider:``,preheadings:preheadings.value,"blur-delay":400},{default:withCtx(()=>[createTextVNode(toDisplayString(_ctx.$ctx_t(selectedActivity.value.heading)),1),selectedActivity.value.description?(openBlock(),createElementBlock(Fragment,{key:0},[createTextVNode(`: `+toDisplayString(_ctx.$ctx_t(selectedActivity.value.description)),1)],64)):createCommentVNode(``,!0)]),_:1},8,[`preheadings`])):createCommentVNode(``,!0),createBaseVNode(`div`,_hoisted_2$239,[selectedActivity.value.stars&&selectedActivity.value.stars.defaultStarCount?(openBlock(),createBlock(unref(bngMainStars_default),{key:0,"unlocked-stars":selectedActivity.value.stars.defaultUnlockedStarCount,"total-stars":selectedActivity.value.stars.defaultStarCount,class:`main-stars`},null,8,[`unlocked-stars`,`total-stars`])):createCommentVNode(``,!0),selectedActivity.value.stars&&selectedActivity.value.stars.bonusStarCount?(openBlock(),createBlock(unref(bngMainStars_default),{key:1,"unlocked-stars":selectedActivity.value.stars.bonusStarsUnlockedCount,"total-stars":selectedActivity.value.stars.bonusStarCount,class:`bonus-stars`},null,8,[`unlocked-stars`,`total-stars`])):createCommentVNode(``,!0),(openBlock(!0),createElementBlock(Fragment,null,renderList(selectedActivity.value.labels,(label,index)=>(openBlock(),createBlock(unref(bngPropVal_default),{key:index,iconType:label.icon,keyLabel:label.keyLabel,valueLabel:label.valueLabel},null,8,[`iconType`,`keyLabel`,`valueLabel`]))),128))]),createBaseVNode(`div`,null,[withDirectives((openBlock(),createBlock(unref(bngButton_default),{accent:unref(ACCENTS).main,onClick:invokeActivityAction},{default:withCtx(()=>[createBaseVNode(`span`,_hoisted_3$212,[createVNode(unref(bngBinding_default),{action:`gameplay_interact`})]),selectedActivity.value.startable?(openBlock(),createElementBlock(Fragment,{key:0},[createTextVNode(toDisplayString(_ctx.$ctx_t(selectedActivity.value.buttonLabel)),1)],64)):(openBlock(),createElementBlock(Fragment,{key:1},[createTextVNode(toDisplayString(_ctx.$tt(`ui.mission.action.locked`)),1)],64))]),_:1},8,[`accent`])),[[unref(BngOnUiNav_default),void 0,`gameplay_interact`,{asMouse:!0}]]),withDirectives((openBlock(),createBlock(unref(bngButton_default),{accent:unref(ACCENTS).secondary,onClick:onCancel},{default:withCtx(()=>[createVNode(unref(bngBinding_default),{"ui-event":`back`,controller:``}),createTextVNode(` `+toDisplayString(_ctx.$tt(`ui.common.close`)),1)]),_:1},8,[`accent`])),[[unref(BngOnUiNav_default),void 0,`back`,{asMouse:!0}]])])])),[[unref(BngOnUiNav_default),goPrev,`tab_l`,{up:!0}],[unref(BngOnUiNav_default),goNext,`tab_r`,{up:!0}],[unref(BngOnUiNav_default),openPauseMenu,`menu`]]):createCommentVNode(``,!0)}},ActivityStart_default=__plugin_vue_export_helper_default(_sfc_main$329,[[`__scopeId`,`data-v-1f131cb6`]]),_hoisted_1$290={class:`recovery-wrapper`,"bng-ui-scope":`recoveryPrompt`},_hoisted_2$238={class:`content`},_hoisted_3$211={class:`label`},_hoisted_4$181={key:0,class:`more-options`},_hoisted_5$155={key:0,class:`notification`},__default__$8={wrapper:{fade:!0,blur:!0,style:popupContainer.transparent},position:[popupPosition.center,popupPosition.center]},_sfc_main$328=Object.assign(__default__$8,{__name:`Recovery`,emits:[`return`],setup(__props,{emit:__emit}){let{events:events$3}=useBridge();useUINavScope(`recoveryPrompt`);let emit$1=__emit,{closeRecoveryPrompt}=useGameContextStore(),popupData=ref({}),clickHandler=(index,button,fromController)=>{button.confirmationText||executeButtonAction(index,button)},executeButtonAction=(index,button)=>{Lua_default.core_recoveryPrompt.uiPopupButtonPressed(index+1),button.keepMenuOpen||(closeRecoveryPrompt(),emit$1(`return`,!0))},cancelClickHandler=()=>{Lua_default.core_recoveryPrompt.uiPopupCancelPressed(),popupData.value.cancelButton.keepMenuOpen||(closeRecoveryPrompt(),emit$1(`return`,!0))},updateRecoveryPopupData=()=>{Lua_default.core_recoveryPrompt.getUIData().then(value=>popupData.value=value)};return events$3.on(`updateRecoveryPopupData`,updateRecoveryPopupData),onMounted(()=>{getUINavServiceInstance().activate(),getUINavServiceInstance().clearFilteredEvents(),updateRecoveryPopupData()}),onUnmounted(()=>{events$3.off(`updateRecoveryPopupData`,updateRecoveryPopupData),window.bngVue.getCurrentRoute().name==`unknown`&&getUINavServiceInstance().setFilteredEventsAllExcept(UI_EVENTS.menu,UI_EVENTS.pause,UI_EVENTS.center_cam)}),(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$290,[createVNode(unref(bngCard_default),null,{buttons:withCtx(()=>[unref(popupData).cancelButton?withDirectives((openBlock(),createBlock(unref(bngButton_default),{key:0,label:unref(popupData).cancelButton.label,accent:unref(ACCENTS).attention,onClick:cancelClickHandler},null,8,[`label`,`accent`])),[[unref(BngOnUiNav_default),void 0,`back,menu`,{asMouse:!0}]]):createCommentVNode(``,!0)]),default:withCtx(()=>[createVNode(unref(bngCardHeading_default),{type:`ribbon`},{default:withCtx(()=>[createTextVNode(toDisplayString(unref(popupData).title),1)]),_:1}),createBaseVNode(`div`,_hoisted_2$238,[(openBlock(!0),createElementBlock(Fragment,null,renderList(unref(popupData).buttons,(button,index)=>withDirectives((openBlock(),createBlock(unref(bngButton_default),{"show-hold":!!button.confirmationText,"hold-vertical":``,accent:unref(ACCENTS).outlined,class:`recovery-option-button`},{default:withCtx(()=>[createVNode(unref(bngImageTile_default),{class:`recovery-option-tile`,icon:unref(icons)[button.icon]},{default:withCtx(()=>[createBaseVNode(`span`,_hoisted_3$211,toDisplayString(_ctx.$ctx_t(button.label)),1),button.price?(openBlock(),createBlock(unref(bngDivider_default),{key:0})):createCommentVNode(``,!0),button.price?(openBlock(),createBlock(unref(bngUnit_default),{key:1,class:`units`,money:button.price.money.amount,options:{formatter:x=>~~x}},null,8,[`money`,`options`])):createCommentVNode(``,!0)]),_:2},1032,[`icon`]),button.keepMenuOpen?(openBlock(),createElementBlock(`span`,_hoisted_4$181,`⇢`)):createCommentVNode(``,!0)]),_:2},1032,[`show-hold`,`accent`])),[[unref(BngDisabled_default),!button.enabled],[unref(BngFocusIf_default),!index||button.enabled&&!unref(popupData).buttons[0].enabled],[unref(BngOnUiNav_default),void 0,`ok`,{asMouse:!0,focusRequired:!0}],[unref(BngClick_default),{clickCallback:e=>clickHandler(index,button,e.fromController),holdCallback:button.confirmationText?()=>executeButtonAction(index,button):null,holdDelay:500,repeatInterval:0}]])),256)),unref(popupData).warningMessage?(openBlock(),createElementBlock(`div`,_hoisted_5$155,toDisplayString(unref(popupData).warningMessage),1)):createCommentVNode(``,!0)])]),_:1})]))}}),Recovery_default=__plugin_vue_export_helper_default(_sfc_main$328,[[`__scopeId`,`data-v-8495e64c`]]),_hoisted_1$289={class:`item-container`,navigable:``,tabindex:`0`},_hoisted_2$237={class:`item-content`},_hoisted_3$210={class:`item-container indented`,navigable:``,tabindex:`0`},_hoisted_4$180={class:`item-content`},_sfc_main$327={__name:`FavoriteSelectionItem`,props:{data:Object,level:{type:Number,default:0}},emits:[`addedFunction`,`removedFunction`],setup(__props,{emit:__emit}){let emit$1=__emit,expandedStates=ref({}),focusedItem=ref(null),toggleExpanded=(idx,value)=>{expandedStates.value[idx]=value},select=item=>{focusedItem.value=item},deselect=item=>{focusedItem.value===item&&(focusedItem.value=null)},isFocused=item=>focusedItem.value===item,addActionToQuickAccess=item=>{console.log(`addActionToQuickAccess`,item),item&&item.uniqueID&&emit$1(`addedFunction`,item)},removeFunction=()=>{emit$1(`removedFunction`)};return(_ctx,_cache)=>{let _component_FavoriteSelectionItem=resolveComponent(`FavoriteSelectionItem`,!0);return openBlock(),createBlock(unref(accordion_default),{class:`favorite-selection-item`,expanded:__props.data.expanded},{default:withCtx(()=>[(openBlock(!0),createElementBlock(Fragment,null,renderList(__props.data.items,(item,idx)=>(openBlock(),createElementBlock(`div`,{key:idx,class:`item-wrapper`},[item.items?(openBlock(),createBlock(unref(accordionItem_default),{key:0,navigable:``,static:!item.items,expanded:expandedStates.value[idx],onExpanded:$event=>toggleExpanded(idx,$event),"arrow-big":``,onMouseover:withModifiers($event=>select(item),[`stop`]),onMouseleave:withModifiers($event=>deselect(item),[`stop`]),onFocusin:withModifiers($event=>select(item),[`stop`]),onFocusout:withModifiers($event=>deselect(item),[`stop`]),"primary-action":()=>addActionToQuickAccess(item),"primary-label":`ui.inputActions.menu.menu_item_select.title`,"expand-hint-inline":``},{caption:withCtx(()=>[createBaseVNode(`div`,_hoisted_1$289,[createBaseVNode(`div`,_hoisted_2$237,[createVNode(unref(bngIcon_default),{type:unref(icons)[item.icon]},null,8,[`type`]),createTextVNode(` `+toDisplayString(item.title?unref($translate).instant(item.title):item.niceName),1)]),item.uniqueID&&isFocused(item)?(openBlock(),createBlock(unref(bngButton_default),{key:0,accent:`outlined`,class:`select-button`,onClick:$event=>addActionToQuickAccess(item),"bng-no-nav":``},{default:withCtx(()=>[createVNode(unref(bngBinding_default),{class:`input-icon`,"ui-event":`ok`,controller:``}),_cache[0]||=createTextVNode(` Select `,-1)]),_:1},8,[`onClick`])):createCommentVNode(``,!0)])]),default:withCtx(()=>[createVNode(_component_FavoriteSelectionItem,{data:item,level:__props.level+1,onAddedFunction:addActionToQuickAccess,onRemovedFunction:removeFunction},null,8,[`data`,`level`])]),_:2},1032,[`static`,`expanded`,`onExpanded`,`onMouseover`,`onMouseleave`,`onFocusin`,`onFocusout`,`primary-action`])):(openBlock(),createBlock(unref(accordionItem_default),{key:1,static:!0,navigable:``,onMouseover:withModifiers($event=>select(item),[`stop`]),onMouseleave:withModifiers($event=>deselect(item),[`stop`]),onFocusin:withModifiers($event=>select(item),[`stop`]),onFocusout:withModifiers($event=>deselect(item),[`stop`]),"primary-action":()=>addActionToQuickAccess(item),"primary-label":`ui.inputActions.menu.menu_item_select.title`},{caption:withCtx(()=>[createBaseVNode(`div`,_hoisted_3$210,[createBaseVNode(`div`,_hoisted_4$180,[item.icon?(openBlock(),createBlock(unref(bngIcon_default),{key:0,type:unref(icons)[item.icon]},null,8,[`type`])):createCommentVNode(``,!0),createTextVNode(` `+toDisplayString(unref($translate).instant(item.title)),1)]),item.uniqueID&&isFocused(item)?(openBlock(),createBlock(unref(bngButton_default),{key:0,class:`select-button`,onClick:$event=>addActionToQuickAccess(item),accent:`outlined`,"bng-no-nav":``},{default:withCtx(()=>[createVNode(unref(bngBinding_default),{class:`input-icon`,"ui-event":`ok`,controller:``}),_cache[1]||=createTextVNode(` Select `,-1)]),_:1},8,[`onClick`])):createCommentVNode(``,!0)])]),_:2},1032,[`onMouseover`,`onMouseleave`,`onFocusin`,`onFocusout`,`primary-action`]))]))),128))]),_:1},8,[`expanded`])}}},FavoriteSelectionItem_default=__plugin_vue_export_helper_default(_sfc_main$327,[[`__scopeId`,`data-v-dd594aec`]]),_hoisted_1$288={class:`backgroundContainer`},_hoisted_2$236={key:0,class:`recovery-wrapper`,"bng-ui-scope":`favoriteSelection`},_hoisted_3$209={class:`current-action-container`},_hoisted_4$179={key:0},_hoisted_5$154={key:1},_hoisted_6$133={key:2},_hoisted_7$119={key:0,class:`content`},__default__$7={wrapper:{fade:!0,blur:!0,style:popupContainer.transparent},position:[popupPosition.center,popupPosition.center]},_sfc_main$326=Object.assign(__default__$7,{__name:`FavoriteSelection`,emits:[`return`],setup(__props,{emit:__emit}){let{events:events$3}=useBridge();useUINavScope(`favoriteSelection`);let emit$1=__emit,{closeRecoveryPrompt}=useGameContextStore(),data=ref({}),updateFavoritePopupData=()=>{Lua_default.core_quickAccess.getDynamicSlotConfigurationData().then(value=>data.value=value)};events$3.on(`radialFavoriteSelectionPopupData`,updateFavoritePopupData);let addedFunction=item=>{let config={uniqueID:item.uniqueID,level:item.level,type:item.type,mode:item.mode||`uniqueAction`};console.log(`addedFunction`,config),Lua_default.core_quickAccess.setDynamicSlotConfiguration(data.value.dynamicSlotKey,config),emit$1(`return`,!0)},removeFunction=()=>{Lua_default.core_quickAccess.removeActionFromQuickAccess(data.value.slotIndex),emit$1(`return`,!0)},close=()=>{emit$1(`return`,!0)};return onMounted(()=>{updateFavoritePopupData()}),onUnmounted(()=>{events$3.off(`radialFavoriteSelectionPopupData`,updateFavoritePopupData),window.bngVue.getCurrentRoute().name==`unknown`&&getUINavServiceInstance().setFilteredEventsAllExcept(UI_EVENTS.menu,UI_EVENTS.pause,UI_EVENTS.center_cam)}),(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$288,[unref(data).dynamicSlotKey?(openBlock(),createElementBlock(`div`,_hoisted_2$236,[createVNode(unref(bngCard_default),null,{default:withCtx(()=>[createVNode(unref(bngCardHeading_default),{type:`ribbon`},{default:withCtx(()=>[createTextVNode(` Assign Action to: `+toDisplayString(unref(data).dynamicSlotData.breadcrumbs[0]),1)]),_:1}),createBaseVNode(`div`,_hoisted_3$209,[_cache[3]||=createBaseVNode(`div`,{class:`current-action-label`},`Currently Assigned Action:`,-1),unref(data).dynamicSlotData.mode===`uniqueAction`&&unref(data).uniqueAction?(openBlock(),createElementBlock(`div`,_hoisted_4$179,[unref(data).uniqueAction.icon?(openBlock(),createBlock(unref(bngIcon_default),{key:0,type:unref(icons)[unref(data).uniqueAction.icon]},null,8,[`type`])):createCommentVNode(``,!0),createTextVNode(` `+toDisplayString(unref(data).uniqueAction.title?unref($translate).instant(unref(data).uniqueAction.title):unref(data).uniqueAction.niceName),1)])):createCommentVNode(``,!0),unref(data).dynamicSlotData.mode===`recentActions`?(openBlock(),createElementBlock(`div`,_hoisted_5$154,[createVNode(unref(bngIcon_default),{type:unref(icons).timer},null,8,[`type`]),_cache[1]||=createTextVNode(` Most Recent Action `,-1)])):createCommentVNode(``,!0),unref(data).dynamicSlotData.mode===`empty`?(openBlock(),createElementBlock(`div`,_hoisted_6$133,[createVNode(unref(bngIcon_default),{type:unref(icons).circleSlashed},null,8,[`type`]),_cache[2]||=createTextVNode(` Empty `,-1)])):createCommentVNode(``,!0)]),_cache[5]||=createBaseVNode(`div`,{class:`divider`},null,-1),unref(data).items?(openBlock(),createElementBlock(`div`,_hoisted_7$119,[createVNode(FavoriteSelectionItem_default,{data:unref(data).items,onAddedFunction:addedFunction,onRemovedFunction:removeFunction},null,8,[`data`])])):createCommentVNode(``,!0),withDirectives((openBlock(),createBlock(unref(bngButton_default),{class:`cancel-button`,onClick:_cache[0]||=$event=>close(),accent:`attention`},{default:withCtx(()=>[createVNode(unref(bngBinding_default),{class:`input-icon`,"ui-event":`back`,controller:``}),_cache[4]||=createTextVNode(` Cancel `,-1)]),_:1})),[[unref(BngOnUiNav_default),void 0,`back,menu`,{asMouse:!0}]])]),_:1})])):createCommentVNode(``,!0)]))}}),FavoriteSelection_default=__plugin_vue_export_helper_default(_sfc_main$326,[[`__scopeId`,`data-v-88390882`]]);const useGameContextStore=defineStore(`gameContext`,()=>{let{events:events$3}=useBridge(),activities=ref([]),activityScreen=null,recoveryPrompt=null,radialFavoriteSelectionPrompt=null,deliveryEndScreen=null,simpleDelayPopup=null,startMission=missionId=>{let mission=activities.value.find(x=>x.id===missionId);mission||console.error(`Mission not found ${missionId}. cannot start`);let settings$1=mission.settings,userSettings=mission&&settings$1?settings$1.reduce((a$1,b)=>a$1[b.key]=b.value,a):{};Lua_default.gameplay_markerInteraction.startMissionById(mission.id,userSettings)},closeActivitiesPrompt=()=>{Lua_default.gameplay_markerInteraction.closeViewDetailPrompt(!0)};function openRecoveryPrompt(){recoveryPrompt=addPopup(Recovery_default).promise}function openDynamicSlotConfigurator(){radialFavoriteSelectionPrompt=addPopup(FavoriteSelection_default).promise}function openSimpleDelayPopup(data){simpleDelayPopup=fixedDelayPopup(data.timer,{title:data.heading})}let performActivityAction=activityActionIndex=>Lua_default.ui_missionInfo.performActivityAction(activityActionIndex);events$3.on(`ActivityAcceptUpdate`,onActivityAcceptUpdate),events$3.on(`ActivityAcceptClose`,closeActivitiesPopup),events$3.on(`MenuOpenModule`,closeActivitiesPopup),events$3.on(`ChangeState`,closeActivitiesPopup),events$3.on(`OpenRecoveryPrompt`,openRecoveryPrompt),events$3.on(`OpenDynamicSlotConfigurator`,openDynamicSlotConfigurator),events$3.on(`OpenSimpleDelayPopup`,openSimpleDelayPopup);let deliveryRewardData=ref(!1);function showDeliveryEndScreen(data){deliveryRewardData.value=data,window.bngVue.gotoGameState(`cargoDeliveryReward`)}events$3.on(`OpenDeliveryEndScreen`,showDeliveryEndScreen);function onActivityAcceptUpdate(data){activityScreen&&(activities.value||!data)&&closeActivitiesPopup(),window.location.hash===`#/play`&&(activities.value=data,activities.value&&activities.value.length>0&&(activityScreen=openScreenOverlay(ActivityStart_default)))}function closeActivitiesPopup(){activityScreen&&=(activityScreen.close(!0),null)}function closeRecoveryPrompt(){recoveryPrompt&&=(recoveryPrompt.close(!0),null)}function closeRadialFavoriteSelectionPrompt(){radialFavoriteSelectionPrompt&&=(radialFavoriteSelectionPrompt.close(!0),null)}function closeSimpleDelayPopup(){simpleDelayPopup&&=(simpleDelayPopup.progress.done(),null)}function closeDeliveryEndScreen(){deliveryEndScreen&&=(deliveryEndScreen.close(!0),null)}function dispose$2(){events$3.off(`ActivityAcceptUpdate`,onActivityAcceptUpdate),events$3.off(`ActivityAcceptClose`,closeActivitiesPopup)}return{activities,closeActivitiesPrompt,closeDeliveryEndScreen,closeRecoveryPrompt,closeRadialFavoriteSelectionPrompt,closeSimpleDelayPopup,deliveryRewardData,dispose:dispose$2,performActivityAction,startMission}});var PARSE_NESTED$1=`PARSE_NESTED`,bbcode_main_default=[[/\[url=https?:\/\/([^\s\]]+)\](.*?(?=\[\/url\]))\[\/url\]/gi,`$2`],[/\[url='https?:\/\/([^\s\]]+)'\](.*?(?=\[\/url\]))\[\/url\]/gi,`$2`],[/\[forumurl=https?:\/\/([^\s\]]+)\](\S*?(?=\[\/forumurl\]))\[\/forumurl\]/gi,`$2`],[/\[url\]https?:\/\/(.*?(?=\[\/url\]))\[\/url\]/gi,`$1`],[/\[url=([^\s\]]+)\](.*?(?=\[\/url\]))\[\/url\]/gi,`$2`],[/\[h(\d)\](.*?(?=\[\/h\d\]))\[\/h\d\]/gi,`$2`],[/\[img\]\s*?(\S*?(?=\[\/img\]))\[\/img\]/gi,``],[/\shttp(s|):\/\/(\S*)/gi,`http$1://$2`],[/\[list=\d+\](.*?(?=\[\/list\]))\[\/list\]/gi,`
    $1
`],[/\[list\]/gi,`
    `],[/\[\/list\]/gi,`
`],[/\[olist\]/gi,`
    `],[/\[\/olist\]/gi,`
`],[/\[(\*|\+)\]\s*?((.|\s)*?(?=\[(\*|\+)\]|\<\/ul\>|\<\/ol\>|\n\n|$))/gim,`
  • $2
  • `],[PARSE_NESTED$1,/\[b\](.*?(?=\[\/b\]))\[\/b\]/gi,`$1`],[PARSE_NESTED$1,/\[u\](.*?(?=\[\/u\]))\[\/u\]/gi,`$1`],[PARSE_NESTED$1,/\[s\](.*?(?=\[\/s\]))\[\/s\]/gi,`$1`],[PARSE_NESTED$1,/\[i\](.*?(?=\[\/i\]))\[\/i\]/gi,`$1`],[/\[strike\](.*?(?=\[\/strike\]))\[\/strike\]/gi,`$1`],[/\[code\](.*?(?=\[\/code\]))\[\/code\]/gi,`$1`],[/\[br\]/gi,`
    `],[/\n\n/gi,`

    `],[/\n/gi,`
    `],[/\[attach=?f?u?l?l?\](.*?(?=\[\/attach\]))\[\/attach\]/gi,``],[/\[USER=([\d]+)\](.*?(?=\[\/USER\]))\[\/USER\]/gi,`$2`],[/\[MEDIA=youtube\](.*?(?=\[\/MEDIA\]))\[\/MEDIA\]/gi,`
    `],[/\[MEDIA=beamng\](.*?(?=\[\/MEDIA\]))\[\/MEDIA\]/gi,``],[PARSE_NESTED$1,/\[size=(\d+)\]([^[]*(?:\[(?!size=\d+\]|\/size\])[^[]*)*)\[\/size\]/gi,`$2`],[PARSE_NESTED$1,/\[COLOR=([a-z0-9\#\, \'\"\(\)]+)\]([^[]*(?:\[(?!COLOR=[a-z0-9#\(\)]+\]|\/COLOR\])[^[]*)*)\[\/COLOR\]/gi,`$2`],[PARSE_NESTED$1,/\[font=([^\]]+)\](.*?(?=\[\/font\]))\[\/font\]/gi,`$2`],[/\[hr\]\[\/hr\]/gi,`
    `],[/\[spoiler=([^\]]+)\](.*?(?=\[\/spoiler\]))\[\/spoiler\]/gi,`
    Spoiler: $1
    $2
    `],[/\[spoiler\](.*?(?=\[\/spoiler\]))\[\/spoiler\]/gi,`
    Spoiler
    $1
    `],[PARSE_NESTED$1,/\[left\](.*?(?=\[\/left\]))\[\/left\]/gi,`

    $1

    `],[PARSE_NESTED$1,/\[center\](.*?(?=\[\/center\]))\[\/center\]/gi,`

    $1

    `],[PARSE_NESTED$1,/\[right\](.*?(?=\[\/right\]))\[\/right\]/gi,`

    $1

    `],[PARSE_NESTED$1,/\*\*(.*?(?=\*\*))\*\*/gi,`$1`],[PARSE_NESTED$1,/\*(.*?(?=\*))\*/gi,`$1`],[PARSE_NESTED$1,/\[(.*?(?=\]\())\]\((https?:\/\/((.*?(?=\)))))\)/gi,`$1 ($2)`]],bbcode_vue_default=[[/\[ico=([^\s\]]+)\s*\](.*?(?=\[\/ico\]))\[\/ico\]/gi,`$2`],[/\[ico=([^\s\]]+)\s*\]/gi,``],[/\[action=(.*?)\]\[showunassigned=(.*?)\](.*?)/gi,``],[/\[action=(.*?)\](.*?)/gi,``],[/\[action=(.*?)\]/gi,``],[/\[(money|beamXP|stars|vouchers)=(.*?)\]/g,``]],bbcode_angular_default=[[/\[ico=([^\s\]]+)\s*\](.*?(?=\[\/ico\]))\[\/ico\]/gi,`$2`],[/\[ico=([^\s\]]+)\s*\]/gi,``],[/\[action=(.*?)\]\[showunassigned=(.*?)\](.*?)/gi,``],[/\[action=(.*?)\](.*?)/gi,``],[/\[action=(.*?)\]/gi,``]],bbcode_exports=__export({parse:()=>parse$1,useExtensions:()=>useExtensions}),PARSE_NESTED=`PARSE_NESTED`,_extensions=bbcode_vue_default;const useExtensions=exts=>_extensions=exts,parse$1=(txt,extensions$1=_extensions)=>{let text=``+txt;return[...bbcode_main_default,...extensions$1].forEach(replacement=>{let{nested,fromTo}=replacementDetails(replacement);text=nested?parseNested(text,...fromTo):text.replace(...fromTo)}),text};window.angularParseBBCode=txt=>parse$1(txt,bbcode_angular_default);var replacementDetails=replacement=>({nested:replacement.length==3&&replacement[0]===PARSE_NESTED,fromTo:replacement.slice(-2)}),parseNested=(text,regex,template)=>{for(;~text.search(regex);)text=text.replace(regex,template);return text},markdown_exports=__export({parse:()=>parse});function parse(src){let h$1=``;return src.replace(/^\s+|\r|\s+$/g,``).replace(/\t/g,` `).split(/\n\n+/).forEach(function(b,f,R){f=b[0],R={"*":[/\n\* /,`
    • `,`
    `],1:[/\n[1-9]\d*\.? /,`
    1. `,`
    `]," ":[/\n {4}/,`
    `,`
    `,` `],">":[/\n> /,`
    `,`
    `,`
    `,CHAR_LS=`\u2028`,CHAR_PS=`\u2029`;function createScanner(str){let _buf=str,_index=0,_line=1,_column=1,_peekOffset=0,isCRLF=index$1=>_buf[index$1]===CHAR_CR&&_buf[index$1+1]===CHAR_LF,isLF=index$1=>_buf[index$1]===CHAR_LF,isPS=index$1=>_buf[index$1]===CHAR_PS,isLS=index$1=>_buf[index$1]===CHAR_LS,isLineEnd=index$1=>isCRLF(index$1)||isLF(index$1)||isPS(index$1)||isLS(index$1),index=()=>_index,line=()=>_line,column=()=>_column,peekOffset=()=>_peekOffset,charAt=offset$2=>isCRLF(offset$2)||isPS(offset$2)||isLS(offset$2)?CHAR_LF:_buf[offset$2],currentChar=()=>charAt(_index),currentPeek=()=>charAt(_index+_peekOffset);function next(){return _peekOffset=0,isLineEnd(_index)&&(_line++,_column=0),isCRLF(_index)&&_index++,_index++,_column++,_buf[_index]}function peek(){return isCRLF(_index+_peekOffset)&&_peekOffset++,_peekOffset++,_buf[_index+_peekOffset]}function reset$1(){_index=0,_line=1,_column=1,_peekOffset=0}function resetPeek(offset$2=0){_peekOffset=offset$2}function skipToPeek(){let target=_index+_peekOffset;for(;target!==_index;)next();_peekOffset=0}return{index,line,column,peekOffset,charAt,currentChar,currentPeek,next,peek,reset:reset$1,resetPeek,skipToPeek}}var EOF=void 0,DOT=`.`,LITERAL_DELIMITER=`'`,ERROR_DOMAIN$3=`tokenizer`;function createTokenizer(source,options={}){let location$1=options.location!==!1,_scnr=createScanner(source),currentOffset=()=>_scnr.index(),currentPosition=()=>createPosition(_scnr.line(),_scnr.column(),_scnr.index()),_initLoc=currentPosition(),_initOffset=currentOffset(),_context={currentType:13,offset:_initOffset,startLoc:_initLoc,endLoc:_initLoc,lastType:13,lastOffset:_initOffset,lastStartLoc:_initLoc,lastEndLoc:_initLoc,braceNest:0,inLinked:!1,text:``},context=()=>_context,{onError}=options;function emitError$1(code,pos,offset$2,...args){let ctx=context();pos.column+=offset$2,pos.offset+=offset$2,onError&&onError(createCompileError(code,location$1?createLocation(ctx.startLoc,pos):null,{domain:ERROR_DOMAIN$3,args}))}function getToken(context$1,type,value){context$1.endLoc=currentPosition(),context$1.currentType=type;let token={type};return location$1&&(token.loc=createLocation(context$1.startLoc,context$1.endLoc)),value!=null&&(token.value=value),token}let getEndToken=context$1=>getToken(context$1,13);function eat(scnr,ch){return scnr.currentChar()===ch?(scnr.next(),ch):(emitError$1(CompileErrorCodes.EXPECTED_TOKEN,currentPosition(),0,ch),``)}function peekSpaces(scnr){let buf=``;for(;scnr.currentPeek()===CHAR_SP||scnr.currentPeek()===CHAR_LF;)buf+=scnr.currentPeek(),scnr.peek();return buf}function skipSpaces(scnr){let buf=peekSpaces(scnr);return scnr.skipToPeek(),buf}function isIdentifierStart(ch){if(ch===EOF)return!1;let cc=ch.charCodeAt(0);return cc>=97&&cc<=122||cc>=65&&cc<=90||cc===95}function isNumberStart(ch){if(ch===EOF)return!1;let cc=ch.charCodeAt(0);return cc>=48&&cc<=57}function isNamedIdentifierStart(scnr,context$1){let{currentType}=context$1;if(currentType!==2)return!1;peekSpaces(scnr);let ret=isIdentifierStart(scnr.currentPeek());return scnr.resetPeek(),ret}function isListIdentifierStart(scnr,context$1){let{currentType}=context$1;if(currentType!==2)return!1;peekSpaces(scnr);let ret=isNumberStart(scnr.currentPeek()===`-`?scnr.peek():scnr.currentPeek());return scnr.resetPeek(),ret}function isLiteralStart(scnr,context$1){let{currentType}=context$1;if(currentType!==2)return!1;peekSpaces(scnr);let ret=scnr.currentPeek()===LITERAL_DELIMITER;return scnr.resetPeek(),ret}function isLinkedDotStart(scnr,context$1){let{currentType}=context$1;if(currentType!==7)return!1;peekSpaces(scnr);let ret=scnr.currentPeek()===`.`;return scnr.resetPeek(),ret}function isLinkedModifierStart(scnr,context$1){let{currentType}=context$1;if(currentType!==8)return!1;peekSpaces(scnr);let ret=isIdentifierStart(scnr.currentPeek());return scnr.resetPeek(),ret}function isLinkedDelimiterStart(scnr,context$1){let{currentType}=context$1;if(!(currentType===7||currentType===11))return!1;peekSpaces(scnr);let ret=scnr.currentPeek()===`:`;return scnr.resetPeek(),ret}function isLinkedReferStart(scnr,context$1){let{currentType}=context$1;if(currentType!==9)return!1;let fn=()=>{let ch=scnr.currentPeek();return ch===`{`?isIdentifierStart(scnr.peek()):ch===`@`||ch===`|`||ch===`:`||ch===`.`||ch===CHAR_SP||!ch?!1:ch===CHAR_LF?(scnr.peek(),fn()):isTextStart(scnr,!1)},ret=fn();return scnr.resetPeek(),ret}function isPluralStart(scnr){peekSpaces(scnr);let ret=scnr.currentPeek()===`|`;return scnr.resetPeek(),ret}function isTextStart(scnr,reset$1=!0){let fn=(hasSpace=!1,prev=``)=>{let ch=scnr.currentPeek();return ch===`{`||ch===`@`||!ch?hasSpace:ch===`|`?!(prev===CHAR_SP||prev===CHAR_LF):ch===CHAR_SP?(scnr.peek(),fn(!0,CHAR_SP)):ch===CHAR_LF?(scnr.peek(),fn(!0,CHAR_LF)):!0},ret=fn();return reset$1&&scnr.resetPeek(),ret}function takeChar(scnr,fn){let ch=scnr.currentChar();return ch===EOF?EOF:fn(ch)?(scnr.next(),ch):null}function isIdentifier(ch){let cc=ch.charCodeAt(0);return cc>=97&&cc<=122||cc>=65&&cc<=90||cc>=48&&cc<=57||cc===95||cc===36}function takeIdentifierChar(scnr){return takeChar(scnr,isIdentifier)}function isNamedIdentifier(ch){let cc=ch.charCodeAt(0);return cc>=97&&cc<=122||cc>=65&&cc<=90||cc>=48&&cc<=57||cc===95||cc===36||cc===45}function takeNamedIdentifierChar(scnr){return takeChar(scnr,isNamedIdentifier)}function isDigit(ch){let cc=ch.charCodeAt(0);return cc>=48&&cc<=57}function takeDigit(scnr){return takeChar(scnr,isDigit)}function isHexDigit(ch){let cc=ch.charCodeAt(0);return cc>=48&&cc<=57||cc>=65&&cc<=70||cc>=97&&cc<=102}function takeHexDigit(scnr){return takeChar(scnr,isHexDigit)}function getDigits(scnr){let ch=``,num=``;for(;ch=takeDigit(scnr);)num+=ch;return num}function readText(scnr){let buf=``;for(;;){let ch=scnr.currentChar();if(ch===`{`||ch===`}`||ch===`@`||ch===`|`||!ch)break;if(ch===CHAR_SP||ch===CHAR_LF)if(isTextStart(scnr))buf+=ch,scnr.next();else if(isPluralStart(scnr))break;else buf+=ch,scnr.next();else buf+=ch,scnr.next()}return buf}function readNamedIdentifier(scnr){skipSpaces(scnr);let ch=``,name=``;for(;ch=takeNamedIdentifierChar(scnr);)name+=ch;let currentChar=scnr.currentChar();if(currentChar&¤tChar!==`}`&¤tChar!==EOF&¤tChar!==CHAR_SP&¤tChar!==CHAR_LF&¤tChar!==` `){let invalidPart=readInvalidIdentifier(scnr);return emitError$1(CompileErrorCodes.INVALID_TOKEN_IN_PLACEHOLDER,currentPosition(),0,name+invalidPart),name+invalidPart}return scnr.currentChar()===EOF&&emitError$1(CompileErrorCodes.UNTERMINATED_CLOSING_BRACE,currentPosition(),0),name}function readListIdentifier(scnr){skipSpaces(scnr);let value=``;return scnr.currentChar()===`-`?(scnr.next(),value+=`-${getDigits(scnr)}`):value+=getDigits(scnr),scnr.currentChar()===EOF&&emitError$1(CompileErrorCodes.UNTERMINATED_CLOSING_BRACE,currentPosition(),0),value}function isLiteral(ch){return ch!==LITERAL_DELIMITER&&ch!==CHAR_LF}function readLiteral(scnr){skipSpaces(scnr),eat(scnr,`'`);let ch=``,literal=``;for(;ch=takeChar(scnr,isLiteral);)ch===`\\`?literal+=readEscapeSequence(scnr):literal+=ch;let current=scnr.currentChar();return current===CHAR_LF||current===EOF?(emitError$1(CompileErrorCodes.UNTERMINATED_SINGLE_QUOTE_IN_PLACEHOLDER,currentPosition(),0),current===CHAR_LF&&(scnr.next(),eat(scnr,`'`)),literal):(eat(scnr,`'`),literal)}function readEscapeSequence(scnr){let ch=scnr.currentChar();switch(ch){case`\\`:case`'`:return scnr.next(),`\\${ch}`;case`u`:return readUnicodeEscapeSequence(scnr,ch,4);case`U`:return readUnicodeEscapeSequence(scnr,ch,6);default:return emitError$1(CompileErrorCodes.UNKNOWN_ESCAPE_SEQUENCE,currentPosition(),0,ch),``}}function readUnicodeEscapeSequence(scnr,unicode,digits){eat(scnr,unicode);let sequence=``;for(let i=0;i{let ch=scnr.currentChar();return ch===`{`||ch===`@`||ch===`|`||ch===`(`||ch===`)`||!ch||ch===CHAR_SP?buf:(buf+=ch,scnr.next(),fn(buf))};return fn(``)}function readPlural(scnr){skipSpaces(scnr);let plural=eat(scnr,`|`);return skipSpaces(scnr),plural}function readTokenInPlaceholder(scnr,context$1){let token=null;switch(scnr.currentChar()){case`{`:return context$1.braceNest>=1&&emitError$1(CompileErrorCodes.NOT_ALLOW_NEST_PLACEHOLDER,currentPosition(),0),scnr.next(),token=getToken(context$1,2,`{`),skipSpaces(scnr),context$1.braceNest++,token;case`}`:return context$1.braceNest>0&&context$1.currentType===2&&emitError$1(CompileErrorCodes.EMPTY_PLACEHOLDER,currentPosition(),0),scnr.next(),token=getToken(context$1,3,`}`),context$1.braceNest--,context$1.braceNest>0&&skipSpaces(scnr),context$1.inLinked&&context$1.braceNest===0&&(context$1.inLinked=!1),token;case`@`:return context$1.braceNest>0&&emitError$1(CompileErrorCodes.UNTERMINATED_CLOSING_BRACE,currentPosition(),0),token=readTokenInLinked(scnr,context$1)||getEndToken(context$1),context$1.braceNest=0,token;default:{let validNamedIdentifier=!0,validListIdentifier=!0,validLiteral=!0;if(isPluralStart(scnr))return context$1.braceNest>0&&emitError$1(CompileErrorCodes.UNTERMINATED_CLOSING_BRACE,currentPosition(),0),token=getToken(context$1,1,readPlural(scnr)),context$1.braceNest=0,context$1.inLinked=!1,token;if(context$1.braceNest>0&&(context$1.currentType===4||context$1.currentType===5||context$1.currentType===6))return emitError$1(CompileErrorCodes.UNTERMINATED_CLOSING_BRACE,currentPosition(),0),context$1.braceNest=0,readToken(scnr,context$1);if(validNamedIdentifier=isNamedIdentifierStart(scnr,context$1))return token=getToken(context$1,4,readNamedIdentifier(scnr)),skipSpaces(scnr),token;if(validListIdentifier=isListIdentifierStart(scnr,context$1))return token=getToken(context$1,5,readListIdentifier(scnr)),skipSpaces(scnr),token;if(validLiteral=isLiteralStart(scnr,context$1))return token=getToken(context$1,6,readLiteral(scnr)),skipSpaces(scnr),token;if(!validNamedIdentifier&&!validListIdentifier&&!validLiteral)return token=getToken(context$1,12,readInvalidIdentifier(scnr)),emitError$1(CompileErrorCodes.INVALID_TOKEN_IN_PLACEHOLDER,currentPosition(),0,token.value),skipSpaces(scnr),token;break}}return token}function readTokenInLinked(scnr,context$1){let{currentType}=context$1,token=null,ch=scnr.currentChar();switch((currentType===7||currentType===8||currentType===11||currentType===9)&&(ch===CHAR_LF||ch===CHAR_SP)&&emitError$1(CompileErrorCodes.INVALID_LINKED_FORMAT,currentPosition(),0),ch){case`@`:return scnr.next(),token=getToken(context$1,7,`@`),context$1.inLinked=!0,token;case`.`:return skipSpaces(scnr),scnr.next(),getToken(context$1,8,`.`);case`:`:return skipSpaces(scnr),scnr.next(),getToken(context$1,9,`:`);default:return isPluralStart(scnr)?(token=getToken(context$1,1,readPlural(scnr)),context$1.braceNest=0,context$1.inLinked=!1,token):isLinkedDotStart(scnr,context$1)||isLinkedDelimiterStart(scnr,context$1)?(skipSpaces(scnr),readTokenInLinked(scnr,context$1)):isLinkedModifierStart(scnr,context$1)?(skipSpaces(scnr),getToken(context$1,11,readLinkedModifier(scnr))):isLinkedReferStart(scnr,context$1)?(skipSpaces(scnr),ch===`{`?readTokenInPlaceholder(scnr,context$1)||token:getToken(context$1,10,readLinkedRefer(scnr))):(currentType===7&&emitError$1(CompileErrorCodes.INVALID_LINKED_FORMAT,currentPosition(),0),context$1.braceNest=0,context$1.inLinked=!1,readToken(scnr,context$1))}}function readToken(scnr,context$1){let token={type:13};if(context$1.braceNest>0)return readTokenInPlaceholder(scnr,context$1)||getEndToken(context$1);if(context$1.inLinked)return readTokenInLinked(scnr,context$1)||getEndToken(context$1);switch(scnr.currentChar()){case`{`:return readTokenInPlaceholder(scnr,context$1)||getEndToken(context$1);case`}`:return emitError$1(CompileErrorCodes.UNBALANCED_CLOSING_BRACE,currentPosition(),0),scnr.next(),getToken(context$1,3,`}`);case`@`:return readTokenInLinked(scnr,context$1)||getEndToken(context$1);default:if(isPluralStart(scnr))return token=getToken(context$1,1,readPlural(scnr)),context$1.braceNest=0,context$1.inLinked=!1,token;if(isTextStart(scnr))return getToken(context$1,0,readText(scnr));break}return token}function nextToken(){let{currentType,offset:offset$2,startLoc,endLoc}=_context;return _context.lastType=currentType,_context.lastOffset=offset$2,_context.lastStartLoc=startLoc,_context.lastEndLoc=endLoc,_context.offset=currentOffset(),_context.startLoc=currentPosition(),_scnr.currentChar()===EOF?getToken(_context,13):readToken(_scnr,_context)}return{nextToken,currentOffset,currentPosition,context}}var ERROR_DOMAIN$2=`parser`,KNOWN_ESCAPES=/(?:\\\\|\\'|\\u([0-9a-fA-F]{4})|\\U([0-9a-fA-F]{6}))/g;function fromEscapeSequence(match,codePoint4,codePoint6){switch(match){case`\\\\`:return`\\`;case`\\'`:return`'`;default:{let codePoint=parseInt(codePoint4||codePoint6,16);return codePoint<=55295||codePoint>=57344?String.fromCodePoint(codePoint):`�`}}}function createParser(options={}){let location$1=options.location!==!1,{onError}=options;function emitError$1(tokenzer,code,start,offset$2,...args){let end=tokenzer.currentPosition();end.offset+=offset$2,end.column+=offset$2,onError&&onError(createCompileError(code,location$1?createLocation(start,end):null,{domain:ERROR_DOMAIN$2,args}))}function startNode(type,offset$2,loc){let node={type};return location$1&&(node.start=offset$2,node.end=offset$2,node.loc={start:loc,end:loc}),node}function endNode(node,offset$2,pos,type){location$1&&(node.end=offset$2,node.loc&&(node.loc.end=pos))}function parseText$1(tokenizer$1,value){let context=tokenizer$1.context(),node=startNode(3,context.offset,context.startLoc);return node.value=value,endNode(node,tokenizer$1.currentOffset(),tokenizer$1.currentPosition()),node}function parseList(tokenizer$1,index){let{lastOffset:offset$2,lastStartLoc:loc}=tokenizer$1.context(),node=startNode(5,offset$2,loc);return node.index=parseInt(index,10),tokenizer$1.nextToken(),endNode(node,tokenizer$1.currentOffset(),tokenizer$1.currentPosition()),node}function parseNamed(tokenizer$1,key){let{lastOffset:offset$2,lastStartLoc:loc}=tokenizer$1.context(),node=startNode(4,offset$2,loc);return node.key=key,tokenizer$1.nextToken(),endNode(node,tokenizer$1.currentOffset(),tokenizer$1.currentPosition()),node}function parseLiteral(tokenizer$1,value){let{lastOffset:offset$2,lastStartLoc:loc}=tokenizer$1.context(),node=startNode(9,offset$2,loc);return node.value=value.replace(KNOWN_ESCAPES,fromEscapeSequence),tokenizer$1.nextToken(),endNode(node,tokenizer$1.currentOffset(),tokenizer$1.currentPosition()),node}function parseLinkedModifier(tokenizer$1){let token=tokenizer$1.nextToken(),context=tokenizer$1.context(),{lastOffset:offset$2,lastStartLoc:loc}=context,node=startNode(8,offset$2,loc);return token.type===11?(token.value??emitError$1(tokenizer$1,CompileErrorCodes.UNEXPECTED_LEXICAL_ANALYSIS,context.lastStartLoc,0,getTokenCaption(token)),node.value=token.value||``,endNode(node,tokenizer$1.currentOffset(),tokenizer$1.currentPosition()),{node}):(emitError$1(tokenizer$1,CompileErrorCodes.UNEXPECTED_EMPTY_LINKED_MODIFIER,context.lastStartLoc,0),node.value=``,endNode(node,offset$2,loc),{nextConsumeToken:token,node})}function parseLinkedKey(tokenizer$1,value){let context=tokenizer$1.context(),node=startNode(7,context.offset,context.startLoc);return node.value=value,endNode(node,tokenizer$1.currentOffset(),tokenizer$1.currentPosition()),node}function parseLinked(tokenizer$1){let context=tokenizer$1.context(),linkedNode=startNode(6,context.offset,context.startLoc),token=tokenizer$1.nextToken();if(token.type===8){let parsed=parseLinkedModifier(tokenizer$1);linkedNode.modifier=parsed.node,token=parsed.nextConsumeToken||tokenizer$1.nextToken()}switch(token.type!==9&&emitError$1(tokenizer$1,CompileErrorCodes.UNEXPECTED_LEXICAL_ANALYSIS,context.lastStartLoc,0,getTokenCaption(token)),token=tokenizer$1.nextToken(),token.type===2&&(token=tokenizer$1.nextToken()),token.type){case 10:token.value??emitError$1(tokenizer$1,CompileErrorCodes.UNEXPECTED_LEXICAL_ANALYSIS,context.lastStartLoc,0,getTokenCaption(token)),linkedNode.key=parseLinkedKey(tokenizer$1,token.value||``);break;case 4:token.value??emitError$1(tokenizer$1,CompileErrorCodes.UNEXPECTED_LEXICAL_ANALYSIS,context.lastStartLoc,0,getTokenCaption(token)),linkedNode.key=parseNamed(tokenizer$1,token.value||``);break;case 5:token.value??emitError$1(tokenizer$1,CompileErrorCodes.UNEXPECTED_LEXICAL_ANALYSIS,context.lastStartLoc,0,getTokenCaption(token)),linkedNode.key=parseList(tokenizer$1,token.value||``);break;case 6:token.value??emitError$1(tokenizer$1,CompileErrorCodes.UNEXPECTED_LEXICAL_ANALYSIS,context.lastStartLoc,0,getTokenCaption(token)),linkedNode.key=parseLiteral(tokenizer$1,token.value||``);break;default:{emitError$1(tokenizer$1,CompileErrorCodes.UNEXPECTED_EMPTY_LINKED_KEY,context.lastStartLoc,0);let nextContext=tokenizer$1.context(),emptyLinkedKeyNode=startNode(7,nextContext.offset,nextContext.startLoc);return emptyLinkedKeyNode.value=``,endNode(emptyLinkedKeyNode,nextContext.offset,nextContext.startLoc),linkedNode.key=emptyLinkedKeyNode,endNode(linkedNode,nextContext.offset,nextContext.startLoc),{nextConsumeToken:token,node:linkedNode}}}return endNode(linkedNode,tokenizer$1.currentOffset(),tokenizer$1.currentPosition()),{node:linkedNode}}function parseMessage(tokenizer$1){let context=tokenizer$1.context(),node=startNode(2,context.currentType===1?tokenizer$1.currentOffset():context.offset,context.currentType===1?context.endLoc:context.startLoc);node.items=[];let nextToken=null;do{let token=nextToken||tokenizer$1.nextToken();switch(nextToken=null,token.type){case 0:token.value??emitError$1(tokenizer$1,CompileErrorCodes.UNEXPECTED_LEXICAL_ANALYSIS,context.lastStartLoc,0,getTokenCaption(token)),node.items.push(parseText$1(tokenizer$1,token.value||``));break;case 5:token.value??emitError$1(tokenizer$1,CompileErrorCodes.UNEXPECTED_LEXICAL_ANALYSIS,context.lastStartLoc,0,getTokenCaption(token)),node.items.push(parseList(tokenizer$1,token.value||``));break;case 4:token.value??emitError$1(tokenizer$1,CompileErrorCodes.UNEXPECTED_LEXICAL_ANALYSIS,context.lastStartLoc,0,getTokenCaption(token)),node.items.push(parseNamed(tokenizer$1,token.value||``));break;case 6:token.value??emitError$1(tokenizer$1,CompileErrorCodes.UNEXPECTED_LEXICAL_ANALYSIS,context.lastStartLoc,0,getTokenCaption(token)),node.items.push(parseLiteral(tokenizer$1,token.value||``));break;case 7:{let parsed=parseLinked(tokenizer$1);node.items.push(parsed.node),nextToken=parsed.nextConsumeToken||null;break}}}while(context.currentType!==13&&context.currentType!==1);return endNode(node,context.currentType===1?context.lastOffset:tokenizer$1.currentOffset(),context.currentType===1?context.lastEndLoc:tokenizer$1.currentPosition()),node}function parsePlural(tokenizer$1,offset$2,loc,msgNode){let context=tokenizer$1.context(),hasEmptyMessage=msgNode.items.length===0,node=startNode(1,offset$2,loc);node.cases=[],node.cases.push(msgNode);do{let msg=parseMessage(tokenizer$1);hasEmptyMessage||=msg.items.length===0,node.cases.push(msg)}while(context.currentType!==13);return hasEmptyMessage&&emitError$1(tokenizer$1,CompileErrorCodes.MUST_HAVE_MESSAGES_IN_PLURAL,loc,0),endNode(node,tokenizer$1.currentOffset(),tokenizer$1.currentPosition()),node}function parseResource(tokenizer$1){let context=tokenizer$1.context(),{offset:offset$2,startLoc}=context,msgNode=parseMessage(tokenizer$1);return context.currentType===13?msgNode:parsePlural(tokenizer$1,offset$2,startLoc,msgNode)}function parse$2(source){let tokenizer$1=createTokenizer(source,assign$1({},options)),context=tokenizer$1.context(),node=startNode(0,context.offset,context.startLoc);return location$1&&node.loc&&(node.loc.source=source),node.body=parseResource(tokenizer$1),options.onCacheKey&&(node.cacheKey=options.onCacheKey(source)),context.currentType!==13&&emitError$1(tokenizer$1,CompileErrorCodes.UNEXPECTED_LEXICAL_ANALYSIS,context.lastStartLoc,0,source[context.offset]||``),endNode(node,tokenizer$1.currentOffset(),tokenizer$1.currentPosition()),node}return{parse:parse$2}}function getTokenCaption(token){if(token.type===13)return`EOF`;let name=(token.value||``).replace(/\r?\n/gu,`\\n`);return name.length>10?name.slice(0,9)+`…`:name}function createTransformer(ast,options={}){let _context={ast,helpers:new Set};return{context:()=>_context,helper:name=>(_context.helpers.add(name),name)}}function traverseNodes(nodes,transformer){for(let i=0;ioptimizeMessageNode(c)),ast}function optimizeMessageNode(message){if(message.items.length===1){let item=message.items[0];(item.type===3||item.type===9)&&(message.static=item.value,delete item.value)}else{let values=[];for(let i=0;i_context;function push(code,node){_context.code+=code}function _newline(n,withBreakLine=!0){let _breakLineCode=withBreakLine?breakLineCode:``;push(_needIndent?_breakLineCode+`  `.repeat(n):_breakLineCode)}function indent(withNewLine=!0){let level$1=++_context.indentLevel;withNewLine&&_newline(level$1)}function deindent(withNewLine=!0){let level$1=--_context.indentLevel;withNewLine&&_newline(level$1)}function newline(){_newline(_context.indentLevel)}return{context,push,indent,deindent,newline,helper:key=>`_${key}`,needIndent:()=>_context.needIndent}}function generateLinkedNode(generator,node){let{helper}=generator;generator.push(`${helper(`linked`)}(`),generateNode(generator,node.key),node.modifier?(generator.push(`, `),generateNode(generator,node.modifier),generator.push(`, _type`)):generator.push(`, undefined, _type`),generator.push(`)`)}function generateMessageNode(generator,node){let{helper,needIndent}=generator;generator.push(`${helper(`normalize`)}([`),generator.indent(needIndent());let length=node.items.length;for(let i=0;i1){generator.push(`${helper(`plural`)}([`),generator.indent(needIndent());let length=node.cases.length;for(let i=0;i{let mode=isString(options.mode)?options.mode:`normal`,filename=isString(options.filename)?options.filename:`message.intl`,sourceMap=!!options.sourceMap,breakLineCode=options.breakLineCode==null?mode===`arrow`?`;`:`
    `:options.breakLineCode,needIndent=options.needIndent?options.needIndent:mode!==`arrow`,helpers=ast.helpers||[],generator=createCodeGenerator(ast,{mode,filename,sourceMap,breakLineCode,needIndent});generator.push(mode===`normal`?`function __msg__ (ctx) {`:`(ctx) => {`),generator.indent(needIndent),helpers.length>0&&(generator.push(`const { ${join(helpers.map(s=>`${s}: _${s}`),`, `)} } = ctx`),generator.newline()),generator.push(`return `),generateNode(generator,ast),generator.deindent(needIndent),generator.push(`}`),delete ast.helpers;let{code,map}=generator.context();return{ast,code,map:map?map.toJSON():void 0}};function baseCompile(source,options={}){let assignedOptions=assign$1({},options),jit=!!assignedOptions.jit,enalbeMinify=!!assignedOptions.minify,enambeOptimize=assignedOptions.optimize==null?!0:assignedOptions.optimize,ast=createParser(assignedOptions).parse(source);return jit?(enambeOptimize&&optimize(ast),enalbeMinify&&minify(ast),{ast,code:``}):(transform(ast,assignedOptions),generate(ast,assignedOptions))}function initFeatureFlags$1(){typeof __INTLIFY_PROD_DEVTOOLS__!=`boolean`&&(getGlobalThis().__INTLIFY_PROD_DEVTOOLS__=!1),typeof __INTLIFY_DROP_MESSAGE_COMPILER__!=`boolean`&&(getGlobalThis().__INTLIFY_DROP_MESSAGE_COMPILER__=!1)}function isMessageAST(val){return isObject(val)&&resolveType(val)===0&&(hasOwn(val,`b`)||hasOwn(val,`body`))}var PROPS_BODY=[`b`,`body`];function resolveBody(node){return resolveProps(node,PROPS_BODY)}var PROPS_CASES=[`c`,`cases`];function resolveCases(node){return resolveProps(node,PROPS_CASES,[])}var PROPS_STATIC=[`s`,`static`];function resolveStatic(node){return resolveProps(node,PROPS_STATIC)}var PROPS_ITEMS=[`i`,`items`];function resolveItems(node){return resolveProps(node,PROPS_ITEMS,[])}var PROPS_TYPE=[`t`,`type`];function resolveType(node){return resolveProps(node,PROPS_TYPE)}var PROPS_VALUE=[`v`,`value`];function resolveValue$1(node,type){let resolved=resolveProps(node,PROPS_VALUE);if(resolved!=null)return resolved;throw createUnhandleNodeError(type)}var PROPS_MODIFIER=[`m`,`modifier`];function resolveLinkedModifier(node){return resolveProps(node,PROPS_MODIFIER)}var PROPS_KEY=[`k`,`key`];function resolveLinkedKey(node){let resolved=resolveProps(node,PROPS_KEY);if(resolved)return resolved;throw createUnhandleNodeError(6)}function resolveProps(node,props,defaultValue){for(let i=0;iformatParts(ctx,ast)}function formatParts(ctx,ast){let body=resolveBody(ast);if(body==null)throw createUnhandleNodeError(0);if(resolveType(body)===1){let cases=resolveCases(body);return ctx.plural(cases.reduce((messages,c)=>[...messages,formatMessageParts(ctx,c)],[]))}else return formatMessageParts(ctx,body)}function formatMessageParts(ctx,node){let static_=resolveStatic(node);if(static_!=null)return ctx.type===`text`?static_:ctx.normalize([static_]);{let messages=resolveItems(node).reduce((acm,c)=>[...acm,formatMessagePart(ctx,c)],[]);return ctx.normalize(messages)}}function formatMessagePart(ctx,node){let type=resolveType(node);switch(type){case 3:return resolveValue$1(node,type);case 9:return resolveValue$1(node,type);case 4:{let named=node;if(hasOwn(named,`k`)&&named.k)return ctx.interpolate(ctx.named(named.k));if(hasOwn(named,`key`)&&named.key)return ctx.interpolate(ctx.named(named.key));throw createUnhandleNodeError(type)}case 5:{let list=node;if(hasOwn(list,`i`)&&isNumber(list.i))return ctx.interpolate(ctx.list(list.i));if(hasOwn(list,`index`)&&isNumber(list.index))return ctx.interpolate(ctx.list(list.index));throw createUnhandleNodeError(type)}case 6:{let linked=node,modifier=resolveLinkedModifier(linked),key=resolveLinkedKey(linked);return ctx.linked(formatMessagePart(ctx,key),modifier?formatMessagePart(ctx,modifier):void 0,ctx.type)}case 7:return resolveValue$1(node,type);case 8:return resolveValue$1(node,type);default:throw Error(`unhandled node on format message part: ${type}`)}}var defaultOnCacheKey=message=>message,compileCache=create();function baseCompile$1(message,options={}){let detectError=!1,onError=options.onError||defaultOnError;return options.onError=err=>{detectError=!0,onError(err)},{...baseCompile(message,options),detectError}}function compile(message,context){if(!__INTLIFY_DROP_MESSAGE_COMPILER__&&isString(message)){isBoolean(context.warnHtmlMessage)&&context.warnHtmlMessage;let cacheKey=(context.onCacheKey||defaultOnCacheKey)(message),cached=compileCache[cacheKey];if(cached)return cached;let{ast,detectError}=baseCompile$1(message,{...context,location:!1,jit:!0}),msg=format$1(ast);return detectError?msg:compileCache[cacheKey]=msg}else{let cacheKey=message.cacheKey;return cacheKey?compileCache[cacheKey]||(compileCache[cacheKey]=format$1(message)):format$1(message)}}var devtools=null;function setDevToolsHook(hook){devtools=hook}function initI18nDevTools(i18n,version$2,meta){devtools&&devtools.emit(`i18n:init`,{timestamp:Date.now(),i18n,version:version$2,meta})}var translateDevTools=createDevToolsHook(`function:translate`);function createDevToolsHook(hook){return payloads=>devtools&&devtools.emit(hook,payloads)}var CoreErrorCodes={INVALID_ARGUMENT:17,INVALID_DATE_ARGUMENT:18,INVALID_ISO_DATE_ARGUMENT:19,NOT_SUPPORT_NON_STRING_MESSAGE:20,NOT_SUPPORT_LOCALE_PROMISE_VALUE:21,NOT_SUPPORT_LOCALE_ASYNC_FUNCTION:22,NOT_SUPPORT_LOCALE_TYPE:23},CORE_ERROR_CODES_EXTEND_POINT=24;function createCoreError(code){return createCompileError(code,null,void 0)}CoreErrorCodes.INVALID_ARGUMENT,CoreErrorCodes.INVALID_DATE_ARGUMENT,CoreErrorCodes.INVALID_ISO_DATE_ARGUMENT,CoreErrorCodes.NOT_SUPPORT_NON_STRING_MESSAGE,CoreErrorCodes.NOT_SUPPORT_LOCALE_PROMISE_VALUE,CoreErrorCodes.NOT_SUPPORT_LOCALE_ASYNC_FUNCTION,CoreErrorCodes.NOT_SUPPORT_LOCALE_TYPE;function getLocale(context,options){return options.locale==null?resolveLocale(context.locale):resolveLocale(options.locale)}var _resolveLocale;function resolveLocale(locale){if(isString(locale))return locale;if(isFunction(locale)){if(locale.resolvedOnce&&_resolveLocale!=null)return _resolveLocale;if(locale.constructor.name===`Function`){let resolve$1=locale();if(isPromise(resolve$1))throw createCoreError(CoreErrorCodes.NOT_SUPPORT_LOCALE_PROMISE_VALUE);return _resolveLocale=resolve$1}else throw createCoreError(CoreErrorCodes.NOT_SUPPORT_LOCALE_ASYNC_FUNCTION)}else throw createCoreError(CoreErrorCodes.NOT_SUPPORT_LOCALE_TYPE)}function fallbackWithSimple(ctx,fallback,start){return[...new Set([start,...isArray$1(fallback)?fallback:isObject(fallback)?Object.keys(fallback):isString(fallback)?[fallback]:[start]])]}var pathStateMachine=[];pathStateMachine[0]={w:[0],i:[3,0],"[":[4],o:[7]},pathStateMachine[1]={w:[1],".":[2],"[":[4],o:[7]},pathStateMachine[2]={w:[2],i:[3,0],0:[3,0]},pathStateMachine[3]={i:[3,0],0:[3,0],w:[1,1],".":[2,1],"[":[4,1],o:[7,1]},pathStateMachine[4]={"'":[5,0],'"':[6,0],"[":[4,2],"]":[1,3],o:8,l:[4,0]},pathStateMachine[5]={"'":[4,0],o:8,l:[5,0]},pathStateMachine[6]={'"':[4,0],o:8,l:[6,0]};function resolveWithKeyValue(obj,path){return isObject(obj)?obj[path]:null}var CoreWarnCodes={NOT_FOUND_KEY:1,FALLBACK_TO_TRANSLATE:2,CANNOT_FORMAT_NUMBER:3,FALLBACK_TO_NUMBER_FORMAT:4,CANNOT_FORMAT_DATE:5,FALLBACK_TO_DATE_FORMAT:6,EXPERIMENTAL_CUSTOM_MESSAGE_COMPILER:7},CORE_WARN_CODES_EXTEND_POINT=8,warnMessages={[CoreWarnCodes.NOT_FOUND_KEY]:`Not found '{key}' key in '{locale}' locale messages.`,[CoreWarnCodes.FALLBACK_TO_TRANSLATE]:`Fall back to translate '{key}' key with '{target}' locale.`,[CoreWarnCodes.CANNOT_FORMAT_NUMBER]:`Cannot format a number value due to not supported Intl.NumberFormat.`,[CoreWarnCodes.FALLBACK_TO_NUMBER_FORMAT]:`Fall back to number format '{key}' key with '{target}' locale.`,[CoreWarnCodes.CANNOT_FORMAT_DATE]:`Cannot format a date value due to not supported Intl.DateTimeFormat.`,[CoreWarnCodes.FALLBACK_TO_DATE_FORMAT]:`Fall back to datetime format '{key}' key with '{target}' locale.`,[CoreWarnCodes.EXPERIMENTAL_CUSTOM_MESSAGE_COMPILER]:`This project is using Custom Message Compiler, which is an experimental feature. It may receive breaking changes or be removed in the future.`},VERSION$1=`11.1.12`,NOT_REOSLVED=-1,DEFAULT_LOCALE=`en-US`,capitalize=str=>`${str.charAt(0).toLocaleUpperCase()}${str.substr(1)}`;function getDefaultLinkedModifiers(){return{upper:(val,type)=>type===`text`&&isString(val)?val.toUpperCase():type===`vnode`&&isObject(val)&&`__v_isVNode`in val?val.children.toUpperCase():val,lower:(val,type)=>type===`text`&&isString(val)?val.toLowerCase():type===`vnode`&&isObject(val)&&`__v_isVNode`in val?val.children.toLowerCase():val,capitalize:(val,type)=>type===`text`&&isString(val)?capitalize(val):type===`vnode`&&isObject(val)&&`__v_isVNode`in val?capitalize(val.children):val}}var _compiler;function registerMessageCompiler(compiler){_compiler=compiler}var _resolver,_fallbacker,_additionalMeta=null,setAdditionalMeta=meta=>{_additionalMeta=meta},getAdditionalMeta=()=>_additionalMeta,_fallbackContext=null,setFallbackContext=context=>{_fallbackContext=context},getFallbackContext=()=>_fallbackContext,_cid=0;function createCoreContext(options={}){let onWarn=isFunction(options.onWarn)?options.onWarn:warn,version$2=isString(options.version)?options.version:VERSION$1,locale=isString(options.locale)||isFunction(options.locale)?options.locale:DEFAULT_LOCALE,_locale=isFunction(locale)?DEFAULT_LOCALE:locale,fallbackLocale=isArray$1(options.fallbackLocale)||isPlainObject(options.fallbackLocale)||isString(options.fallbackLocale)||options.fallbackLocale===!1?options.fallbackLocale:_locale,messages=isPlainObject(options.messages)?options.messages:createResources(_locale),datetimeFormats=isPlainObject(options.datetimeFormats)?options.datetimeFormats:createResources(_locale),numberFormats=isPlainObject(options.numberFormats)?options.numberFormats:createResources(_locale),modifiers=assign$1(create(),options.modifiers,getDefaultLinkedModifiers()),pluralRules=options.pluralRules||create(),missing=isFunction(options.missing)?options.missing:null,missingWarn=isBoolean(options.missingWarn)||isRegExp(options.missingWarn)?options.missingWarn:!0,fallbackWarn=isBoolean(options.fallbackWarn)||isRegExp(options.fallbackWarn)?options.fallbackWarn:!0,fallbackFormat=!!options.fallbackFormat,unresolving=!!options.unresolving,postTranslation=isFunction(options.postTranslation)?options.postTranslation:null,processor=isPlainObject(options.processor)?options.processor:null,warnHtmlMessage=isBoolean(options.warnHtmlMessage)?options.warnHtmlMessage:!0,escapeParameter=!!options.escapeParameter,messageCompiler=isFunction(options.messageCompiler)?options.messageCompiler:_compiler,messageResolver=isFunction(options.messageResolver)?options.messageResolver:_resolver||resolveWithKeyValue,localeFallbacker=isFunction(options.localeFallbacker)?options.localeFallbacker:_fallbacker||fallbackWithSimple,fallbackContext=isObject(options.fallbackContext)?options.fallbackContext:void 0,internalOptions=options,__datetimeFormatters=isObject(internalOptions.__datetimeFormatters)?internalOptions.__datetimeFormatters:new Map,__numberFormatters=isObject(internalOptions.__numberFormatters)?internalOptions.__numberFormatters:new Map,__meta=isObject(internalOptions.__meta)?internalOptions.__meta:{};_cid++;let context={version:version$2,cid:_cid,locale,fallbackLocale,messages,modifiers,pluralRules,missing,missingWarn,fallbackWarn,fallbackFormat,unresolving,postTranslation,processor,warnHtmlMessage,escapeParameter,messageCompiler,messageResolver,localeFallbacker,fallbackContext,onWarn,__meta};return context.datetimeFormats=datetimeFormats,context.numberFormats=numberFormats,context.__datetimeFormatters=__datetimeFormatters,context.__numberFormatters=__numberFormatters,__INTLIFY_PROD_DEVTOOLS__&&initI18nDevTools(context,version$2,__meta),context}var createResources=locale=>({[locale]:create()});function handleMissing(context,key,locale,missingWarn,type){let{missing,onWarn}=context;if(missing!==null){let ret=missing(context,locale,key,type);return isString(ret)?ret:key}else return key}function updateFallbackLocale(ctx,locale,fallback){let context=ctx;context.__localeChainCache=new Map,ctx.localeFallbacker(ctx,fallback,locale)}function isAlmostSameLocale(locale,compareLocale){return locale===compareLocale?!1:locale.split(`-`)[0]===compareLocale.split(`-`)[0]}function isImplicitFallback(targetLocale,locales){let index=locales.indexOf(targetLocale);if(index===-1)return!1;for(let i=index+1;istr,DEFAULT_MESSAGE=ctx=>``,DEFAULT_MESSAGE_DATA_TYPE=`text`,DEFAULT_NORMALIZE=values=>values.length===0?``:join(values),DEFAULT_INTERPOLATE=toDisplayString$1;function pluralDefault(choice,choicesLength){return choice=Math.abs(choice),choicesLength===2?choice?choice>1?1:0:1:choice?Math.min(choice,2):0}function getPluralIndex(options){let index=isNumber(options.pluralIndex)?options.pluralIndex:-1;return options.named&&(isNumber(options.named.count)||isNumber(options.named.n))?isNumber(options.named.count)?options.named.count:isNumber(options.named.n)?options.named.n:index:index}function normalizeNamed(pluralIndex,props){props.count||=pluralIndex,props.n||=pluralIndex}function createMessageContext(options={}){let locale=options.locale,pluralIndex=getPluralIndex(options),pluralRule=isObject(options.pluralRules)&&isString(locale)&&isFunction(options.pluralRules[locale])?options.pluralRules[locale]:pluralDefault,orgPluralRule=isObject(options.pluralRules)&&isString(locale)&&isFunction(options.pluralRules[locale])?pluralDefault:void 0,plural=messages=>messages[pluralRule(pluralIndex,messages.length,orgPluralRule)],_list=options.list||[],list=index=>_list[index],_named=options.named||create();isNumber(options.pluralIndex)&&normalizeNamed(pluralIndex,_named);let named=key=>_named[key];function message(key,useLinked){return(isFunction(options.messages)?options.messages(key,!!useLinked):isObject(options.messages)?options.messages[key]:!1)||(options.parent?options.parent.message(key):DEFAULT_MESSAGE)}let _modifier=name=>options.modifiers?options.modifiers[name]:DEFAULT_MODIFIER,normalize=isPlainObject(options.processor)&&isFunction(options.processor.normalize)?options.processor.normalize:DEFAULT_NORMALIZE,interpolate=isPlainObject(options.processor)&&isFunction(options.processor.interpolate)?options.processor.interpolate:DEFAULT_INTERPOLATE,ctx={list,named,plural,linked:(key,...args)=>{let[arg1,arg2]=args,type$1=`text`,modifier=``;args.length===1?isObject(arg1)?(modifier=arg1.modifier||modifier,type$1=arg1.type||type$1):isString(arg1)&&(modifier=arg1||modifier):args.length===2&&(isString(arg1)&&(modifier=arg1||modifier),isString(arg2)&&(type$1=arg2||type$1));let ret=message(key,!0)(ctx),msg=type$1===`vnode`&&isArray$1(ret)&&modifier?ret[0]:ret;return modifier?_modifier(modifier)(msg,type$1):msg},message,type:isPlainObject(options.processor)&&isString(options.processor.type)?options.processor.type:DEFAULT_MESSAGE_DATA_TYPE,interpolate,normalize,values:assign$1(create(),_list,_named)};return ctx}var NOOP_MESSAGE_FUNCTION=()=>``,isMessageFunction=val=>isFunction(val);function translate$1(context,...args){let{fallbackFormat,postTranslation,unresolving,messageCompiler,fallbackLocale,messages}=context,[key,options]=parseTranslateArgs(...args),missingWarn=isBoolean(options.missingWarn)?options.missingWarn:context.missingWarn,fallbackWarn=isBoolean(options.fallbackWarn)?options.fallbackWarn:context.fallbackWarn,escapeParameter=isBoolean(options.escapeParameter)?options.escapeParameter:context.escapeParameter,resolvedMessage=!!options.resolvedMessage,defaultMsgOrKey=isString(options.default)||isBoolean(options.default)?isBoolean(options.default)?messageCompiler?key:()=>key:options.default:fallbackFormat?messageCompiler?key:()=>key:null,enableDefaultMsg=fallbackFormat||defaultMsgOrKey!=null&&(isString(defaultMsgOrKey)||isFunction(defaultMsgOrKey)),locale=getLocale(context,options);escapeParameter&&escapeParams(options);let[formatScope,targetLocale,message]=resolvedMessage?[key,locale,messages[locale]||create()]:resolveMessageFormat(context,key,locale,fallbackLocale,fallbackWarn,missingWarn),format$2=formatScope,cacheBaseKey=key;if(!resolvedMessage&&!(isString(format$2)||isMessageAST(format$2)||isMessageFunction(format$2))&&enableDefaultMsg&&(format$2=defaultMsgOrKey,cacheBaseKey=format$2),!resolvedMessage&&(!(isString(format$2)||isMessageAST(format$2)||isMessageFunction(format$2))||!isString(targetLocale)))return unresolving?-1:key;let occurred=!1,msg=isMessageFunction(format$2)?format$2:compileMessageFormat(context,key,targetLocale,format$2,cacheBaseKey,()=>{occurred=!0});if(occurred)return format$2;let messaged=evaluateMessage(context,msg,createMessageContext(getMessageContextOptions(context,targetLocale,message,options))),ret=postTranslation?postTranslation(messaged,key):messaged;if(escapeParameter&&isString(ret)&&(ret=sanitizeTranslatedHtml(ret)),__INTLIFY_PROD_DEVTOOLS__){let payloads={timestamp:Date.now(),key:isString(key)?key:isMessageFunction(format$2)?format$2.key:``,locale:targetLocale||(isMessageFunction(format$2)?format$2.locale:``),format:isString(format$2)?format$2:isMessageFunction(format$2)?format$2.source:``,message:ret};payloads.meta=assign$1({},context.__meta,getAdditionalMeta()||{}),translateDevTools(payloads)}return ret}function escapeParams(options){isArray$1(options.list)?options.list=options.list.map(item=>isString(item)?escapeHtml(item):item):isObject(options.named)&&Object.keys(options.named).forEach(key=>{isString(options.named[key])&&(options.named[key]=escapeHtml(options.named[key]))})}function resolveMessageFormat(context,key,locale,fallbackLocale,fallbackWarn,missingWarn){let{messages,onWarn,messageResolver:resolveValue,localeFallbacker}=context,locales=localeFallbacker(context,fallbackLocale,locale),message=create(),targetLocale,format$2=null,type=`translate`;for(let i=0;iformat$2);return msg$1.locale=targetLocale,msg$1.key=key,msg$1}let msg=messageCompiler(format$2,getCompileContext(context,targetLocale,cacheBaseKey,format$2,warnHtmlMessage,onError));return msg.locale=targetLocale,msg.key=key,msg.source=format$2,msg}function evaluateMessage(context,msg,msgCtx){return msg(msgCtx)}function parseTranslateArgs(...args){let[arg1,arg2,arg3]=args,options=create();if(!isString(arg1)&&!isNumber(arg1)&&!isMessageFunction(arg1)&&!isMessageAST(arg1))throw createCoreError(CoreErrorCodes.INVALID_ARGUMENT);let key=isNumber(arg1)?String(arg1):(isMessageFunction(arg1),arg1);return isNumber(arg2)?options.plural=arg2:isString(arg2)?options.default=arg2:isPlainObject(arg2)&&!isEmptyObject(arg2)?options.named=arg2:isArray$1(arg2)&&(options.list=arg2),isNumber(arg3)?options.plural=arg3:isString(arg3)?options.default=arg3:isPlainObject(arg3)&&assign$1(options,arg3),[key,options]}function getCompileContext(context,locale,key,source,warnHtmlMessage,onError){return{locale,key,warnHtmlMessage,onError:err=>{throw onError&&onError(err),err},onCacheKey:source$1=>generateFormatCacheKey(locale,key,source$1)}}function getMessageContextOptions(context,locale,message,options){let{modifiers,pluralRules,messageResolver:resolveValue,fallbackLocale,fallbackWarn,missingWarn,fallbackContext}=context,ctxOptions={locale,modifiers,pluralRules,messages:(key,useLinked)=>{let val=resolveValue(message,key);if(val==null&&(fallbackContext||useLinked)){let[,,message$1]=resolveMessageFormat(fallbackContext||context,key,locale,fallbackLocale,fallbackWarn,missingWarn);val=resolveValue(message$1,key)}if(isString(val)||isMessageAST(val)){let occurred=!1,msg=compileMessageFormat(context,key,locale,val,key,()=>{occurred=!0});return occurred?NOOP_MESSAGE_FUNCTION:msg}else if(isMessageFunction(val))return val;else return NOOP_MESSAGE_FUNCTION}};return context.processor&&(ctxOptions.processor=context.processor),options.list&&(ctxOptions.list=options.list),options.named&&(ctxOptions.named=options.named),isNumber(options.plural)&&(ctxOptions.pluralIndex=options.plural),ctxOptions}initFeatureFlags$1();var VERSION=`11.1.12`;function initFeatureFlags(){typeof __VUE_I18N_FULL_INSTALL__!=`boolean`&&(getGlobalThis().__VUE_I18N_FULL_INSTALL__=!0),typeof __VUE_I18N_LEGACY_API__!=`boolean`&&(getGlobalThis().__VUE_I18N_LEGACY_API__=!0),typeof __INTLIFY_DROP_MESSAGE_COMPILER__!=`boolean`&&(getGlobalThis().__INTLIFY_DROP_MESSAGE_COMPILER__=!1),typeof __INTLIFY_PROD_DEVTOOLS__!=`boolean`&&(getGlobalThis().__INTLIFY_PROD_DEVTOOLS__=!1)}var I18nErrorCodes={UNEXPECTED_RETURN_TYPE:24,INVALID_ARGUMENT:25,MUST_BE_CALL_SETUP_TOP:26,NOT_INSTALLED:27,REQUIRED_VALUE:28,INVALID_VALUE:29,CANNOT_SETUP_VUE_DEVTOOLS_PLUGIN:30,NOT_INSTALLED_WITH_PROVIDE:31,UNEXPECTED_ERROR:32,NOT_COMPATIBLE_LEGACY_VUE_I18N:33,NOT_AVAILABLE_COMPOSITION_IN_LEGACY:34};function createI18nError(code,...args){return createCompileError(code,null,void 0)}I18nErrorCodes.UNEXPECTED_RETURN_TYPE,I18nErrorCodes.INVALID_ARGUMENT,I18nErrorCodes.MUST_BE_CALL_SETUP_TOP,I18nErrorCodes.NOT_INSTALLED,I18nErrorCodes.UNEXPECTED_ERROR,I18nErrorCodes.REQUIRED_VALUE,I18nErrorCodes.INVALID_VALUE,I18nErrorCodes.CANNOT_SETUP_VUE_DEVTOOLS_PLUGIN,I18nErrorCodes.NOT_INSTALLED_WITH_PROVIDE,I18nErrorCodes.NOT_COMPATIBLE_LEGACY_VUE_I18N,I18nErrorCodes.NOT_AVAILABLE_COMPOSITION_IN_LEGACY;var SetPluralRulesSymbol=makeSymbol(`__setPluralRules`);makeSymbol(`__intlifyMeta`);var I18nWarnCodes={FALLBACK_TO_ROOT:8,NOT_FOUND_PARENT_SCOPE:9,IGNORE_OBJ_FLATTEN:10,DEPRECATE_LEGACY_MODE:11,DEPRECATE_TRANSLATE_CUSTOME_DIRECTIVE:12,DUPLICATE_USE_I18N_CALLING:13};I18nWarnCodes.FALLBACK_TO_ROOT,I18nWarnCodes.NOT_FOUND_PARENT_SCOPE,I18nWarnCodes.IGNORE_OBJ_FLATTEN,I18nWarnCodes.DEPRECATE_LEGACY_MODE,I18nWarnCodes.DEPRECATE_TRANSLATE_CUSTOME_DIRECTIVE,I18nWarnCodes.DUPLICATE_USE_I18N_CALLING;function handleFlatJson(obj){if(!isObject(obj)||isMessageAST(obj))return obj;for(let key in obj)if(hasOwn(obj,key))if(!key.includes(`.`))isObject(obj[key])&&handleFlatJson(obj[key]);else{let subKeys=key.split(`.`),lastIndex=subKeys.length-1,currentObj=obj,hasStringValue=!1;for(let i=0;i{if(`locale`in custom&&`resource`in custom){let{locale:locale$1,resource}=custom;locale$1?(ret[locale$1]=ret[locale$1]||create(),deepCopy(resource,ret[locale$1])):deepCopy(resource,ret)}else isString(custom)&&deepCopy(JSON.parse(custom),ret)}),messageResolver==null&&flatJson)for(let key in ret)hasOwn(ret,key)&&handleFlatJson(ret[key]);return ret}function getComponentOptions(instance$1){return instance$1.type}var DEVTOOLS_META=`__INTLIFY_META__`,composerID=0;function defineCoreMissingHandler(missing){return((ctx,locale,key,type)=>missing(locale,key,getCurrentInstance()||void 0,type))}var getMetaInfo=()=>{let instance$1=getCurrentInstance(),meta=null;return instance$1&&(meta=getComponentOptions(instance$1)[DEVTOOLS_META])?{[DEVTOOLS_META]:meta}:null};function createComposer(options={}){let{__root,__injectWithOption}=options,_isGlobal=__root===void 0,flatJson=options.flatJson,_ref=inBrowser?ref:shallowRef,_inheritLocale=isBoolean(options.inheritLocale)?options.inheritLocale:!0,_locale=_ref(__root&&_inheritLocale?__root.locale.value:isString(options.locale)?options.locale:DEFAULT_LOCALE),_fallbackLocale=_ref(__root&&_inheritLocale?__root.fallbackLocale.value:isString(options.fallbackLocale)||isArray$1(options.fallbackLocale)||isPlainObject(options.fallbackLocale)||options.fallbackLocale===!1?options.fallbackLocale:_locale.value),_messages=_ref(getLocaleMessages(_locale.value,options)),_missingWarn=__root?__root.missingWarn:isBoolean(options.missingWarn)||isRegExp(options.missingWarn)?options.missingWarn:!0,_fallbackWarn=__root?__root.fallbackWarn:isBoolean(options.fallbackWarn)||isRegExp(options.fallbackWarn)?options.fallbackWarn:!0,_fallbackRoot=__root?__root.fallbackRoot:isBoolean(options.fallbackRoot)?options.fallbackRoot:!0,_fallbackFormat=!!options.fallbackFormat,_missing=isFunction(options.missing)?options.missing:null,_runtimeMissing=isFunction(options.missing)?defineCoreMissingHandler(options.missing):null,_postTranslation=isFunction(options.postTranslation)?options.postTranslation:null,_warnHtmlMessage=__root?__root.warnHtmlMessage:isBoolean(options.warnHtmlMessage)?options.warnHtmlMessage:!0,_escapeParameter=!!options.escapeParameter,_modifiers=__root?__root.modifiers:isPlainObject(options.modifiers)?options.modifiers:{},_pluralRules=options.pluralRules||__root&&__root.pluralRules,_context;_context=(()=>{_isGlobal&&setFallbackContext(null);let ctx=createCoreContext({version:VERSION,locale:_locale.value,fallbackLocale:_fallbackLocale.value,messages:_messages.value,modifiers:_modifiers,pluralRules:_pluralRules,missing:_runtimeMissing===null?void 0:_runtimeMissing,missingWarn:_missingWarn,fallbackWarn:_fallbackWarn,fallbackFormat:_fallbackFormat,unresolving:!0,postTranslation:_postTranslation===null?void 0:_postTranslation,warnHtmlMessage:_warnHtmlMessage,escapeParameter:_escapeParameter,messageResolver:options.messageResolver,messageCompiler:options.messageCompiler,__meta:{framework:`vue`}});return _isGlobal&&setFallbackContext(ctx),ctx})(),updateFallbackLocale(_context,_locale.value,_fallbackLocale.value);function trackReactivityValues(){return[_locale.value,_fallbackLocale.value,_messages.value]}let locale=computed({get:()=>_locale.value,set:val=>{_context.locale=val,_locale.value=val}}),fallbackLocale=computed({get:()=>_fallbackLocale.value,set:val=>{_context.fallbackLocale=val,_fallbackLocale.value=val,updateFallbackLocale(_context,_locale.value,val)}}),messages=computed(()=>_messages.value);function getPostTranslationHandler(){return isFunction(_postTranslation)?_postTranslation:null}function setPostTranslationHandler(handler$1){_postTranslation=handler$1,_context.postTranslation=handler$1}function getMissingHandler(){return _missing}function setMissingHandler(handler$1){handler$1!==null&&(_runtimeMissing=defineCoreMissingHandler(handler$1)),_missing=handler$1,_context.missing=_runtimeMissing}let wrapWithDeps=(fn,argumentParser,warnType,fallbackSuccess,fallbackFail,successCondition)=>{trackReactivityValues();let ret;try{__INTLIFY_PROD_DEVTOOLS__,_isGlobal||(_context.fallbackContext=__root?getFallbackContext():void 0),ret=fn(_context)}finally{__INTLIFY_PROD_DEVTOOLS__,_isGlobal||(_context.fallbackContext=void 0)}if(isNumber(ret)&&ret===-1||warnType===`translate exists`){let[key,arg2]=argumentParser();return __root&&_fallbackRoot?fallbackSuccess(__root):fallbackFail(key)}else if(successCondition(ret))return ret;else throw createI18nError(I18nErrorCodes.UNEXPECTED_RETURN_TYPE)};function t(...args){return wrapWithDeps(context=>Reflect.apply(translate$1,null,[context,...args]),()=>parseTranslateArgs(...args),`translate`,root=>Reflect.apply(root.t,root,[...args]),key=>key,val=>isString(val))}function setPluralRules(rules){_pluralRules=rules,_context.pluralRules=_pluralRules}function getLocaleMessage(locale$1){return _messages.value[locale$1]||{}}function setLocaleMessage(locale$1,message){if(flatJson){let _message={[locale$1]:message};for(let key in _message)hasOwn(_message,key)&&handleFlatJson(_message[key]);message=_message[locale$1]}_messages.value[locale$1]=message,_context.messages=_messages.value}function mergeLocaleMessage(locale$1,message){_messages.value[locale$1]=_messages.value[locale$1]||{};let _message={[locale$1]:message};if(flatJson)for(let key in _message)hasOwn(_message,key)&&handleFlatJson(_message[key]);message=_message[locale$1],deepCopy(message,_messages.value[locale$1]),_context.messages=_messages.value}return composerID++,__root&&inBrowser&&(watch(__root.locale,val=>{_inheritLocale&&(_locale.value=val,_context.locale=val,updateFallbackLocale(_context,_locale.value,_fallbackLocale.value))}),watch(__root.fallbackLocale,val=>{_inheritLocale&&(_fallbackLocale.value=val,_context.fallbackLocale=val,updateFallbackLocale(_context,_locale.value,_fallbackLocale.value))})),{id:composerID,locale,fallbackLocale,get inheritLocale(){return _inheritLocale},set inheritLocale(val){_inheritLocale=val,val&&__root&&(_locale.value=__root.locale.value,_fallbackLocale.value=__root.fallbackLocale.value,updateFallbackLocale(_context,_locale.value,_fallbackLocale.value))},get availableLocales(){return Object.keys(_messages.value).sort()},messages,get modifiers(){return _modifiers},get pluralRules(){return _pluralRules||{}},get isGlobal(){return _isGlobal},get missingWarn(){return _missingWarn},set missingWarn(val){_missingWarn=val,_context.missingWarn=_missingWarn},get fallbackWarn(){return _fallbackWarn},set fallbackWarn(val){_fallbackWarn=val,_context.fallbackWarn=_fallbackWarn},get fallbackRoot(){return _fallbackRoot},set fallbackRoot(val){_fallbackRoot=val},get fallbackFormat(){return _fallbackFormat},set fallbackFormat(val){_fallbackFormat=val,_context.fallbackFormat=_fallbackFormat},get warnHtmlMessage(){return _warnHtmlMessage},set warnHtmlMessage(val){_warnHtmlMessage=val,_context.warnHtmlMessage=val},get escapeParameter(){return _escapeParameter},set escapeParameter(val){_escapeParameter=val,_context.escapeParameter=val},t,getLocaleMessage,setLocaleMessage,mergeLocaleMessage,getPostTranslationHandler,setPostTranslationHandler,getMissingHandler,setMissingHandler,[SetPluralRulesSymbol]:setPluralRules}}function createI18n(options={}){let __globalInjection=isBoolean(options.globalInjection)?options.globalInjection:!0,__instances=new Map,[globalScope,__global]=createGlobal(options),symbol=makeSymbol(``);function __getInstance(component){return __instances.get(component)||null}function __setInstance(component,instance$1){__instances.set(component,instance$1)}function __deleteInstance(component){__instances.delete(component)}let i18n={get mode(){return`composition`},async install(app$1,...options$1){if(app$1.__VUE_I18N_SYMBOL__=symbol,app$1.provide(app$1.__VUE_I18N_SYMBOL__,i18n),isPlainObject(options$1[0])){let opts=options$1[0];i18n.__composerExtend=opts.__composerExtend,i18n.__vueI18nExtend=opts.__vueI18nExtend}let globalReleaseHandler=null;__globalInjection&&(globalReleaseHandler=injectGlobalFields(app$1,i18n.global));let unmountApp=app$1.unmount;app$1.unmount=()=>{globalReleaseHandler&&globalReleaseHandler(),i18n.dispose(),unmountApp()}},get global(){return __global},dispose(){globalScope.stop()},__instances,__getInstance,__setInstance,__deleteInstance};return i18n}function createGlobal(options,legacyMode){let scope$1=effectScope(),obj=scope$1.run(()=>createComposer(options));if(obj==null)throw createI18nError(I18nErrorCodes.UNEXPECTED_ERROR);return[scope$1,obj]}var globalExportProps=[`locale`,`fallbackLocale`,`availableLocales`],globalExportMethods=[`t`];function injectGlobalFields(app$1,composer){let i18n=Object.create(null);return globalExportProps.forEach(prop=>{let desc=Object.getOwnPropertyDescriptor(composer,prop);if(!desc)throw createI18nError(I18nErrorCodes.UNEXPECTED_ERROR);let wrap=isRef(desc.value)?{get(){return desc.value.value},set(val){desc.value.value=val}}:{get(){return desc.get&&desc.get()}};Object.defineProperty(i18n,prop,wrap)}),app$1.config.globalProperties.$i18n=i18n,globalExportMethods.forEach(method=>{let desc=Object.getOwnPropertyDescriptor(composer,method);if(!desc||!desc.value)throw createI18nError(I18nErrorCodes.UNEXPECTED_ERROR);Object.defineProperty(app$1.config.globalProperties,`$${method}`,desc)}),()=>{delete app$1.config.globalProperties.$i18n,globalExportMethods.forEach(method=>{delete app$1.config.globalProperties[`$${method}`]})}}if(initFeatureFlags(),registerMessageCompiler(compile),__INTLIFY_PROD_DEVTOOLS__){let target=getGlobalThis();target.__INTLIFY__=!0,setDevToolsHook(target.__INTLIFY_DEVTOOLS_GLOBAL_HOOK__)}const emptyImage=`data:image/svg+xml,`;function getURL(path){return typeof path!=`string`||!path||path.includes(`://`)?path:(path.startsWith(`/`)&&(path=path.substring(1)),`/${path}`)}function getAssetURL(assetPath){let url=getURL(assetPath);return typeof url!=`string`||!url||url.startsWith(`/`)&&(url=`/ui/ui-vue/src/assets`+url),url}const getFile=(url,timeout=5)=>new Promise((resolve$1,reject)=>{try{let xhr=new XMLHttpRequest,tmr=timeout>0?setTimeout(()=>{xhr.abort(),reject(Error(`Timeout`))},timeout*1e3):null;xhr.open(`GET`,url,!0),xhr.onload=()=>{tmr&&clearTimeout(tmr),xhr.status===200?resolve$1(xhr.responseText):reject(Error(`Failed with code ${xhr.status}`))},xhr.send()}catch(err){reject(err)}}),ucaseFirst=str=>str[0].toUpperCase()+str.slice(1),defer=()=>{let noop$3=()=>{},resolve$1,reject,_notifyHandler=noop$3,promise=new Promise((res,rej)=>{[resolve$1,reject]=[res,rej]});return{promise:{then:(resolveHandler,rejectHandler=noop$3,notifyHandler=noop$3)=>(_notifyHandler=notifyHandler,promise.then(resolveHandler,rejectHandler))},resolve:resolve$1,reject,notify:val=>_notifyHandler(val)}},sleep=ms=>new Promise(resolve$1=>setTimeout(resolve$1,ms)),debounce=(func,wait,immediate)=>{let timeout;function call(...args){let context=this,later=()=>{timeout=null,immediate||func.apply(context,args)},callNow=immediate&&!timeout;timeout&&window.clearTimeout(timeout),timeout=window.setTimeout(later,wait),callNow&&func.apply(context,args)}return call.cancel=()=>timeout&&window.clearTimeout(timeout),call};var Settings=class{options=reactive({});values=reactive({});_previousValues={};_changedValues={};_watcher=null;_syncPending=!1;inited=!1;loaded=!1;_lua;constructor(eventBus$1=void 0,lua=void 0){eventBus$1&&lua&&this.init(eventBus$1,lua)}init(eventBus$1=void 0,lua=void 0){if(!(this.inited||this.loaded)){if(this.inited=!0,!eventBus$1||!lua){let bridge$4=useBridge();eventBus$1||=bridge$4.events,lua||=bridge$4.lua}eventBus$1.on(`SettingsChanged`,data=>{Object.assign(this.options,data.options),Object.assign(this.values,data.values),this._previousValues=this.clone(data.values),this._changedValues={},this._watcher||=watch(()=>this.values,()=>this._syncChanges(),{deep:!0,flush:`sync`}),this.loaded=!0}),this._syncChangesDebounced=debounce(this._syncChangesImmediate,100),this._lua=lua,this.update()}}async waitForData(){for(;!this.inited||!this.loaded;)await sleep(10)}async update(){if(this._lua)return await this._lua.settings.notifyUI()}clone(data){return JSON.parse(JSON.stringify(data))}getValue(field=null){if(this.loaded)return field&&!(field in this.values)?null:this.clone(field?this.values[field]:this.values)}get changesPending(){return this._syncChangesImmediate(),Object.keys(this._changedValues).length>0}get pendingChanges(){return this._syncChangesImmediate(),this.clone(this._changedValues)}_syncChanges(){this._syncPending=!0,this._syncChangesDebounced()}_syncChangesDebounced=()=>{};_syncChangesImmediate(){if(this._syncPending)for(let key in this._syncPending=!1,this.values)this._previousValues[key]===this.values[key]?key in this._changedValues&&delete this._changedValues[key]:this._changedValues[key]=this.values[key]}async apply(values=void 0){if(!this.loaded)return;let res;if(values)res=this.clone(values);else{if(!this.changesPending)return;res={...this._changedValues},this._changedValues={}}return Object.assign(this._previousValues,res),await this._lua.settings.setState(res)}},settings=new Settings;function useSettings(){return settings.init(),settings}async function useSettingsAsync(){return settings.init(),await settings.waitForData(),settings}var ANGULAR_TRANSLATE=[],_angularTranslateFunc,_i18n,i18nVariant=`petite`,defaultLocale=`en-US`,localeCheckId=`ui.common.okay`,checkLocale=()=>_i18n&&_i18n.global.t(localeCheckId)!==localeCheckId,translate=val=>val;const initTranslation=()=>{if(window.vueI18n?.__bng_i18n_variant!==i18nVariant){window.vueI18n&&console.warn(`Localisation library is already initialized, but its variant was not validated. Reloading...`);let creationArguments={locale:defaultLocale,fallbackLocale:defaultLocale,silentTranslationWarn:!0,fallbackWarn:!1,missingWarn:!1,warnHtmlMessage:!1};window.beamng&&!window.beamng.shipping&&(creationArguments.fallbackLocale=[defaultLocale,`not-shipping.internal`]),window.vueI18n=createI18n(creationArguments),window.vueI18n.__bng_i18n_variant=i18nVariant}return _i18n=window.vueI18n,{i18n:_i18n,plugin:translationPlugin}},loadLocale=async(locale,force=!1)=>{if(!(_i18n.global.availableLocales.includes(locale)&&!force))try{let url=getURL(`/locales/${locale}.json`),resp;try{resp=await getFile(url,5)}catch(err){if(err.message!==`Timeout`)throw err;console.warn(`Locale ${locale} load timed out, retrying with a bigger timeout...`),resp=await getFile(url,10)}_i18n.global.setLocaleMessage(locale,preprocessLocaleJSON(JSON.parse(resp)))}catch(err){console.error(`Failed to load ${locale} locale`,err)}};var setupUserLanguage=async()=>{let settings$1=await useSettingsAsync();watch(()=>settings$1.values.uiLanguage,async lang=>{lang&&lang!==defaultLocale&&await loadLocale(lang),_i18n.global.locale.value=_i18n.global.availableLocales.includes(lang)?lang:defaultLocale,lang!==defaultLocale&&!checkLocale()&&console.warn(`Locale ${lang} is not behaving properly`)},{immediate:!0})};const translationPlugin=()=>({install(app$1,options){return _i18n.global.locale.value=defaultLocale,loadLocale(defaultLocale,!0).then(async()=>{checkLocale()||(console.warn(`Failed to load default locale, retrying...`),await loadLocale(defaultLocale,!0),checkLocale()||console.error(`Failed to load default locale!`)),await setupUserLanguage()}),contextTranslatePlugin().install(app$1,options)}}),contextTranslatePlugin=()=>({install(app$1,options){translate=_wrapTranslate(app$1.config.globalProperties.$t||_i18n.global.t),app$1.config.globalProperties.$t=_i18n.global.t,app$1.config.globalProperties.$ctx_t=(val,translateContext=!0)=>contextTranslate(val,translateContext),app$1.config.globalProperties.$mctx_t=multiContextTranslate,app$1.config.globalProperties.$tt=translate}});var contextTranslate=(val,translateContext=!1)=>{let type=typeof val;if(type===`undefined`||val===null)return``;if(type===`object`)if(val.txt&&val.context){let context=val.context;if(translateContext)for(let key in context={...context},context)context[key]=contextTranslate(context[key],!0);return getTranslation(val.txt,context)}else val=val.txt||``;return getTranslation(``+val)},multiContextTranslate=val=>{if(val.txt)return contextTranslate(val);let description=``;for(let i of val)description+=contextTranslate(i);return description},getAngularTranslationFunc=()=>_angularTranslateFunc||(window.angular$translate&&(_angularTranslateFunc=window.angular$translate.instant.bind(window.angular$translate)),_angularTranslateFunc||translate),getTranslation=(...vals)=>(ANGULAR_TRANSLATE.includes(vals[0])?getAngularTranslationFunc():translate)(...vals);const $translate={instant:val=>val===void 0?``:translate(val),contextTranslate,multiContextTranslate};var rgxAngular=/{{.+}}/,rgxAngularTranslation=/([^ ]?){{ *(?::: *)?'([^ |}]+)' *\| *translate *}}([^\w]?)/gi;function translateAngularToVue(text){let vueText=text.replace(rgxAngularTranslation,(_,q1,s,q2)=>(q1?`${q1} `:``)+`@:${s}`+(q2?` ${q2}`:``));return vueText=vueText.replace(/{{ *([a-z\d_.]+) *}}/gi,`{$1}`),vueText===text||rgxAngular.test(vueText)?null:vueText}const preprocessLocaleJSON=obj=>{let messages={};for(let key in obj){if(ANGULAR_TRANSLATE.includes(key))continue;let text=obj[key];if(rgxAngular.test(text)){let vueText=translateAngularToVue(text);vueText?messages[key]=vueText:ANGULAR_TRANSLATE.includes(key)||ANGULAR_TRANSLATE.push(key)}else messages[key]=text}return messages};var rgxLinkedTranslation=/@:([a-zA-Z0-9_][a-zA-Z0-9_.-]+[a-zA-Z0-9_])/g,linkedNamespace=`__linked_custom`;function _linkedTranslation(msg){if(!msg.includes(`@:`)||!rgxLinkedTranslation.test(msg))return msg;let locale=_i18n.global.locale.value,messages=_i18n.global.messages.value[locale];msg=msg.replace(rgxLinkedTranslation,(_,id)=>`@:`+id);let uniqueId$1=``,match;for(rgxLinkedTranslation.lastIndex=0;(match=rgxLinkedTranslation.exec(msg))!==null;)uniqueId$1+=match[1].replace(/\./g,`_`)+`__`;let fullId,messageId,counter$1=0;for(;counter$1<100;){messageId=uniqueId$1+ ++counter$1,fullId=linkedNamespace+`.`+messageId;let existingMessage=messages[fullId];if(!existingMessage){_i18n.global.mergeLocaleMessage(locale,{[fullId]:msg});break}if(existingMessage===msg)break}return fullId}function _wrapTranslate(f){function translate$2(...args){let key=args[0];return key?typeof key!=`string`||(key=_linkedTranslation(key),key.includes(` `))?key:f.apply(this,[key,...args.slice(1)]):``}return Object.defineProperty(translate$2,`name`,{value:f.name}),translate$2}const UI_NAV_ACTION_GROUP=`UINavActions`,GAME_UI_NAVIGATION_EVENT=`UINavigation`,GAME_UI_NAV_MAP_ENABLED_EVENT=`MenuActionMapEnabled`,DOM_UI_NAVIGATION_EVENT=`ui_nav`,ACTIONS_BY_UI_EVENT={focus_u:`menu_item_up`,focus_r:`menu_item_right`,focus_d:`menu_item_down`,focus_l:`menu_item_left`,menu:`toggleMenues`,back:`menu_item_back`,details:`cui_details`,advanced:`cui_advanced`,camera:`cui_camera`,logs:`cui_logs`,tab_l:`menu_tab_left`,tab_r:`menu_tab_right`,modifier:`cui_modifier`,action_4:`cui_action_4`,focus_ud:`menu_item_focus_ud`,focus_lr:`menu_item_focus_lr`,rotate_h_cam:`menu_item_radial_right_x`,rotate_v_cam:`menu_item_radial_right_y`,ok:`menu_item_select`,cancel:`cui_cancel`,action_2:`cui_action_2`,action_3:`cui_action_3`,context:`cui_context`,gameplay_interact:`cui_gameplay_interact`},UI_EVENTS_BY_ACTION=Object.assign({},...Object.entries(ACTIONS_BY_UI_EVENT).map(([k,v])=>({[v]:k}))),UI_EVENTS={focus_u:`focus_u`,focus_r:`focus_r`,focus_d:`focus_d`,focus_l:`focus_l`,pause:`pause`,menu:`menu`,back:`back`,details:`details`,advanced:`advanced`,camera:`camera`,logs:`logs`,tab_l:`tab_l`,tab_r:`tab_r`,modifier:`modifier`,zoom_out:`zoom_out`,zoom_in:`zoom_in`,subtab_l:`subtab_l`,subtab_r:`subtab_r`,center_cam:`center_cam`,action_4:`action_4`,move_ud:`move_ud`,move_lr:`move_lr`,focus_ud:`focus_ud`,focus_lr:`focus_lr`,rotate_h_cam:`rotate_h_cam`,rotate_v_cam:`rotate_v_cam`,ok:`ok`,cancel:`cancel`,action_2:`action_2`,action_3:`action_3`,context:`context`,gameplay_interact:`gameplay_interact`},UI_EVENT_GROUPS={focusMove:[UI_EVENTS.focus_u,UI_EVENTS.focus_d,UI_EVENTS.focus_l,UI_EVENTS.focus_r],focusMoveScalar:[UI_EVENTS.focus_ud,UI_EVENTS.focus_lr],moveScalar:[UI_EVENTS.move_ud,UI_EVENTS.move_lr],navigation:[UI_EVENTS.focus_u,UI_EVENTS.focus_d,UI_EVENTS.focus_l,UI_EVENTS.focus_r,UI_EVENTS.focus_ud,UI_EVENTS.focus_lr,UI_EVENTS.move_ud,UI_EVENTS.move_lr],allEvents:Object.keys(ACTIONS_BY_UI_EVENT)},NAV_ACTIONS=[`focus_u`,`focus_d`,`focus_l`,`focus_r`],VALUE_BASED_EVENTS=[`zoom_out`,`zoom_in`,`subtab_l`,`subtab_r`,`move_ud`,`move_lr`,`focus_ud`,`focus_lr`,`rotate_h_cam`,`rotate_v_cam`],UI_SCOPE_ATTR$2=`bng-ui-scope`,UI_EVENT_ATTR=`ui-nav-event`;var UINavEventProcessor=class{constructor(){this.isModified=!1}processEvent(name,value=void 0,extras=[],context={}){return!this.isValidGameContext()||context.isEventBlocked&&context.isEventBlocked(name)?null:(this.handleModifierState(name,value),this.shouldHandleWithAngular(name,value)?(this.handleAngularIntegration(),null):this.createEventData(name,value,extras))}isValidGameContext(){return window.beamng?.ingame}handleModifierState(name,value){name===`modifier`&&(this.isModified=value===1)}shouldHandleWithAngular(name,value){return window.globalAngularRootScope&&window.bngIntroShown&&(name===`menu`||name===`back`)&&value===1}handleAngularIntegration(){window.globalAngularRootScope.$broadcast(`MenuToggle`)}createEventData(name,value,extras){let activeElement=document.activeElement,targetScope=null;if(activeElement&&activeElement!==document.body){let scopeElement=activeElement.closest(`[${UI_SCOPE_ATTR$2}]`);scopeElement&&(targetScope=scopeElement.getAttribute(UI_SCOPE_ATTR$2))}return{name,value,modified:name!==`modifier`&&this.isModified,extras,boundAction:ACTIONS_BY_UI_EVENT[name],sendToCrossfire:!0,targetScope}}getEventBroadcastElement(activeScope){let activeElement=document.activeElement;if(activeElement&&activeElement!==document.body)return activeElement;if(activeScope){let scopeElement=document.querySelector(`[${UI_SCOPE_ATTR$2}="${activeScope}"]`);if(scopeElement)return scopeElement}return document.body}},UINavActionHandlers=class{constructor(eventBus$1=null){this._useCrossfire=!0,this.eventBus=eventBus$1}setUseCrossfire(enabled){this._useCrossfire=enabled}get useCrossfire(){return this._useCrossfire}setEventBus(eventBus$1){this.eventBus=eventBus$1}handleGlobalEvent=event=>{let eventData=event.detail;eventData.value===1&&(this.handleMenuActions(eventData)||this.handleNavigationActions(eventData)||this.handleGameActions(eventData))||(this.useCrossfire&&eventData.sendToCrossfire&&handleUINavEvent(event),event.defaultPrevented||(this.handleTabNavigation(eventData),this.handleCameraRotation(eventData),this.handleContextActions(eventData)))};handleMenuActions=eventData=>{if(eventData.name===`menu`||eventData.name===`back`){let globalAngularRootScope=window.globalAngularRootScope;return globalAngularRootScope?(globalAngularRootScope.$broadcast(`MenuToggle`),!1):!0}return!1};handleNavigationActions(eventData){if(NAV_ACTIONS.includes(eventData.name)){Lua_default.extensions.hook(`onMenuItemNavigation`);return}return!1}handleGameActions(eventData){switch(eventData.name){case`pause`:return Lua_default.simTimeAuthority.togglePause(),!0;case`center_cam`:return runRaw(`if core_camera then core_camera.resetCamera(${eventData.extras.player}) end`,!1),!0;default:return!1}}handleTabNavigation(eventData){if(eventData.value===1)switch(eventData.name){case`tab_l`:this.eventBus.emit(`ui_topBar_selectPrevious`);break;case`tab_r`:this.eventBus.emit(`ui_topBar_selectNext`);break}}handleCameraRotation(eventData){if(eventData.name===`rotate_h_cam`||eventData.name===`rotate_v_cam`){let camDir=eventData.name===`rotate_v_cam`?`pitch`:`yaw`,[filterType]=eventData.extras||[0];runRaw(`if core_camera then core_camera.rotate_${camDir}(${eventData.value}, ${filterType}) end`,!1)}}handleContextActions(eventData){[`context`,`details`,`camera`].includes(eventData.name)&&eventData.value===1&&this.isBigMapContext()&&runRaw(`if freeroam_bigMapMode then freeroam_bigMapMode.toggleBigMap() end`,!1)}isBigMapContext(){return[`#/bigmap`,`#/menu.bigmap`,`#/play`,`#/menu/bigmap`].includes(window.location.hash)}},UINavService=class{constructor(eventBus$1){this._eventBus=eventBus$1,this._eventsActive=!1,this._globalEventsHooked=!1,this._activeScope=void 0,this._blockedEvents=[],this.eventProcessor=new UINavEventProcessor,this.actionHandlers=new UINavActionHandlers(eventBus$1),this.useCrossfire=!0}initialize(){this.attachEventListeners(),this.hookGlobalEvents()}handleGameEvent=(name,value,...extras)=>{let context={activeScope:this.activeScope,isEventBlocked:eventName=>this.isEventBlocked(eventName)},eventData=this.eventProcessor.processEvent(name,value,extras,context);eventData&&this.dispatchDOMEvent(eventData)};blockEvents(...events$3){let eventsToAdd=events$3.flat().filter(event=>!this._blockedEvents.includes(event));this._blockedEvents.push(...eventsToAdd)}unblockEvents(...events$3){let eventsToRemove=events$3.flat();this._blockedEvents=this._blockedEvents.filter(event=>!eventsToRemove.includes(event))}setBlockedEvents(events$3=[]){this._blockedEvents=[...events$3]}clearBlockedEvents(){this._blockedEvents=[]}isEventBlocked(eventName){return this._blockedEvents.includes(eventName)}getBlockedEvents(){return[...this._blockedEvents]}handleEnabledChange=state=>{this.eventsActive=state};dispatchDOMEvent=eventData=>{let event=new CustomEvent(DOM_UI_NAVIGATION_EVENT,{detail:eventData,cancelable:!0,bubbles:!0});this.eventProcessor.getEventBroadcastElement(this.activeScope).dispatchEvent(event)};fireEvent(uiEvent,value){this._eventBus&&(value instanceof PointerEvent?(this._eventBus.emit(GAME_UI_NAVIGATION_EVENT,uiEvent,1),this._eventBus.emit(GAME_UI_NAVIGATION_EVENT,uiEvent,0)):this._eventBus.emit(GAME_UI_NAVIGATION_EVENT,uiEvent,typeof value==`number`?value:value?1:0))}setActiveScope(scopeId){this._activeScope=scopeId}get activeScope(){return this._activeScope}activate(state=!0){this.attachEventListeners(state),this.eventsActive=state}hookGlobalEvents(state=!0){let listenerAction=document.body[state?`addEventListener`:`removeEventListener`];listenerAction(DOM_UI_NAVIGATION_EVENT,this.actionHandlers.handleGlobalEvent),this.globalEventsHooked=state}attachEventListeners(state=!0){this._eventBus&&(this._eventBus.off(GAME_UI_NAVIGATION_EVENT),this._eventBus.off(GAME_UI_NAV_MAP_ENABLED_EVENT),state&&(this._eventBus.on(GAME_UI_NAVIGATION_EVENT,this.handleGameEvent),this._eventBus.on(GAME_UI_NAV_MAP_ENABLED_EVENT,this.handleEnabledChange)))}setFilteredEvents(...events$3){this.clearFilteredEvents();let actionsToFilter=[...new Set(events$3.flat(1/0))].map(event=>ACTIONS_BY_UI_EVENT[event]);Lua_default.extensions.core_input_actionFilter.setGroup(UI_NAV_ACTION_GROUP,actionsToFilter),Lua_default.extensions.core_input_actionFilter.addAction(0,UI_NAV_ACTION_GROUP,!0)}setFilteredEventsAllExcept(...events$3){let eventsToNotFilter=[...new Set(events$3.flat(1/0))],eventsToFilter=Object.keys(ACTIONS_BY_UI_EVENT).filter(ev=>!eventsToNotFilter.includes(ev));this.setFilteredEvents(eventsToFilter)}clearFilteredEvents(){Lua_default.extensions.core_input_actionFilter.addAction(0,UI_NAV_ACTION_GROUP,!1),Lua_default.extensions.core_input_actionFilter.setGroup(UI_NAV_ACTION_GROUP,[])}set eventsActive(value){this._eventsActive=value}get eventsActive(){return this._eventsActive}set globalEventsHooked(value){this._globalEventsHooked=value}get globalEventsHooked(){return this._globalEventsHooked}get useCrossfire(){return this.actionHandlers.useCrossfire}set useCrossfire(value){this.actionHandlers.setUseCrossfire(value)}get eventBus(){return this._eventBus}},instance=null;const setUINavServiceInstance=serviceInstance=>{instance=serviceInstance},getUINavServiceInstance=()=>{if(!instance)throw Error(`UINavService not initialized.`);return instance},SCOPED_NAV_ATTR=`bng-scoped-nav`,SCOPED_NAV_PROPERTY_NAME=`_bngScopedNav`,UI_SCOPE_ATTR$1=`bng-ui-scope`,BNG_ON_UI_NAV_ATTR$1=`__BngOnUiNav`,ATTR_NAME$1=`bng-scoped-nav`,PASSTHROUGH_EXCLUDED_EVENTS=[UI_EVENTS.ok,UI_EVENTS.back,UI_EVENT_GROUPS.focusMove,UI_EVENT_GROUPS.focusMoveScalar],SCOPED_NAV_STATES={active:`full`,partial:`partial`,suspended:`suspended`,inactive:`inactive`},SCOPED_NAV_EVENTS={activate:`scopednav:activate`,deactivate:`scopednav:deactivate`,suspend:`scopednav:suspend`,resume:`scopednav:resume`},SCOPED_NAV_TYPES={normal:`normal`,container:`container`,nonav:`nonav`,popover:`popover`};var ScopeRegistry=class{constructor(){this.scopeRegistries=new WeakMap,this.depthCache=new WeakMap,this.cleanupTimers=new Map}clearDepthCache(scopeElement){this.depthCache.delete(scopeElement)}getCachedDepth(element,scopeElement){let scopeDepthCache=this.depthCache.get(scopeElement);if(scopeDepthCache||(scopeDepthCache=new Map,this.depthCache.set(scopeElement,scopeDepthCache)),!scopeDepthCache.has(element)){let depth=this._getElementDepth(element,scopeElement);scopeDepthCache.set(element,depth)}return scopeDepthCache.get(element)}register(scopeElement,handlerDescriptor){let scopeRegistry=this.scopeRegistries.get(scopeElement);scopeRegistry||(scopeRegistry={handlers:[],scopeHandler:null,initialized:!1},this.scopeRegistries.set(scopeElement,scopeRegistry));let existingIndex=scopeRegistry.handlers.findIndex(h$1=>h$1.element===handlerDescriptor.element&&this.descriptorsMatch(h$1.eventDescriptor,handlerDescriptor.eventDescriptor));return existingIndex===-1?scopeRegistry.handlers.push(handlerDescriptor):scopeRegistry.handlers[existingIndex]=handlerDescriptor,scopeRegistry.initialized||this.initializeScopeHandler(scopeElement,scopeRegistry),this.clearDepthCache(scopeElement),handlerDescriptor.handler}descriptorsMatch(desc1,desc2){return desc1.name===desc2.name&&desc1.modified===desc2.modified&&desc1.focusRequired===desc2.focusRequired}unregister(element,handlerController){let scopeElement=element.closest(`[${UI_SCOPE_ATTR$2}]`);if(!scopeElement)return;let scopeRegistry=this.scopeRegistries.get(scopeElement);if(!scopeRegistry)return;let handlerIndex=scopeRegistry.handlers.findIndex(h$1=>h$1.element===element&&h$1.handler===handlerController);handlerIndex!==-1&&(scopeRegistry.handlers.splice(handlerIndex,1),this.clearDepthCache(scopeElement)),this.scheduleCleanup(scopeElement,scopeRegistry)}scheduleCleanup(scopeElement,scopeRegistry){this.cleanupTimers.has(scopeElement)&&clearTimeout(this.cleanupTimers.get(scopeElement));let timerId=setTimeout(()=>{this.performCleanup(scopeElement,scopeRegistry),this.cleanupTimers.delete(scopeElement)},100);this.cleanupTimers.set(scopeElement,timerId)}performCleanup(scopeElement,scopeRegistry){scopeRegistry.handlers.length===0&&(scopeElement.removeEventListener(DOM_UI_NAVIGATION_EVENT,scopeRegistry.scopeHandler),this.scopeRegistries.delete(scopeElement),this.clearDepthCache(scopeElement))}destroy(){this.cleanupTimers.forEach(timer=>clearTimeout(timer)),this.cleanupTimers.clear(),this.depthCache=new WeakMap}initializeScopeHandler(scopeElement,scopeRegistry){let scopeHandler=event=>{let scopeId=scopeElement.getAttribute(UI_SCOPE_ATTR$2),uiNavService=getUINavServiceInstance(),targetScope=event.detail?.targetScope||uiNavService.activeScope;if(targetScope&&targetScope!==scopeId&&!this._isTargetScopeNested(targetScope,scopeElement)){console.warn(`UINav: Event target scope is not the intended scope. Ignoring event for this scope(${scopeId})`,{targetScope,scopeId});return}if(scopeElement._bngScopedNav&&scopeElement._bngScopedNav.canIgnoreEvent&&scopeElement._bngScopedNav.canIgnoreEvent(event)){event.stopPropagation();return}let isTargetActiveScope=targetScope===scopeId&&scopeId===uiNavService.activeScope,canPassthrough=isTargetActiveScope&&this._allowsPassthrough(scopeElement,event.detail),monitoredEvents=[...MONITORED_UI_NAV_EVENTS,UI_EVENTS.back];if(!(!isTargetActiveScope&&!canPassthrough&&!monitoredEvents.includes(event.detail.name))){if(!isTargetActiveScope&&!canPassthrough&&monitoredEvents.includes(event.detail.name)){this._executeScopedNavHandler(scopeElement,event,scopeRegistry.handlers)||event.stopPropagation();return}(!this._executeScopedBubbling(scopeElement,event,scopeRegistry.handlers)||!this._checkScopeBubbling(scopeElement,event))&&event.stopPropagation()}};scopeElement.addEventListener(DOM_UI_NAVIGATION_EVENT,scopeHandler),scopeRegistry.scopeHandler=scopeHandler,scopeRegistry.initialized=!0}_isTargetScopeNested(targetScopeId,currentScopeElement){let targetScopeElement=document.querySelector(`[${UI_SCOPE_ATTR$2}="${targetScopeId}"]`);return targetScopeElement?currentScopeElement.contains(targetScopeElement)&&targetScopeElement!==currentScopeElement:!1}_executeScopedNavHandler(scopeElement,event,handlers$1){let matchingHandlers=handlers$1.filter(h$1=>!h$1.disabled&&this._eventMatchesDescriptor(event.detail,h$1.eventDescriptor)&&h$1.element===scopeElement);if(matchingHandlers.length===0)return!0;let results=[];for(let handler$1 of matchingHandlers)try{let result=handler$1.handler(event);results.push(result)}catch(error){console.error(`Error in UINav scope handler:`,error,{element:handler$1.element,event:event.detail.name}),results.push(!1)}return results.some(result=>result===!0)}_executeScopedBubbling(scopeElement,event,handlers$1){let eventData=event.detail,matchingHandlers=handlers$1&&handlers$1.length>0?handlers$1.filter(h$1=>!h$1.disabled&&this._eventMatchesDescriptor(eventData,h$1.eventDescriptor)):[];if(matchingHandlers.length===0)return!0;let activeElement=document.activeElement,startElement=event.target;startElement=activeElement&&scopeElement.contains(activeElement)&&matchingHandlers.some(h$1=>h$1.element===activeElement)?activeElement:this._findDeepestHandlerElement(scopeElement,matchingHandlers);let bubblingPath=this._buildBubblingPath(startElement,scopeElement,matchingHandlers);return bubblingPath.length===0?(console.warn(`UINav: No bubbling path found.`,{scopeElement,event,handlers:handlers$1}),!0):this._executeHandlersAlongPath(bubblingPath,event)}_findDeepestHandlerElement(scopeElement,handlers$1){return[...new Set(handlers$1.map(h$1=>h$1.element))].filter(el=>this.getCachedDepth(el,scopeElement)<0?!1:!this._isElementInNestedScope(el,scopeElement)).sort((a$1,b)=>{let depthA=this.getCachedDepth(a$1,scopeElement);return this.getCachedDepth(b,scopeElement)-depthA})[0]||null}_isElementInNestedScope(element,currentScopeElement){let current=element;for(;current&¤t!==currentScopeElement;){if(current.hasAttribute(`bng-ui-scope`)&¤t!==currentScopeElement)return!0;current=current.parentElement}return!1}_buildBubblingPath(startElement,scopeElement,handlers$1){if(!scopeElement.contains(startElement))return console.warn(`UINav: Start element is outside scope boundary`,startElement,scopeElement),[];let path=[],current=startElement;for(;current&&scopeElement.contains(current);){let elementHandlers=handlers$1.filter(h$1=>h$1.element===current);if(elementHandlers.length>0&&path.push({element:current,handlers:elementHandlers}),current===scopeElement)break;current=current.parentElement}return path}_executeHandlersAlongPath(bubblingPath,event){for(let pathItem of bubblingPath){let results=[];for(let handlerDescriptor of pathItem.handlers)try{let result=handlerDescriptor.handler(event);results.push(result)}catch(error){console.error(`Error in UINav scope handler:`,error,{element:pathItem.element,event:event.detail.name}),results.push(!1)}if(!results.some(result=>result===!0))return!1}return!0}_checkScopeBubbling(scopeElement,event){let scopedNavProps=scopeElement._bngScopedNav;return scopedNavProps?scopedNavProps.shouldBubbleEvent&&typeof scopedNavProps.shouldBubbleEvent==`function`?scopedNavProps.shouldBubbleEvent(event):!1:!0}_getElementDepth(element,parent){let depth=0,current=element;for(;current&¤t!==parent;)depth++,current=current.parentElement;return current===parent?depth:-1}_allowsPassthrough(scopeElement,eventData){let domScopedNavProps=scopeElement.hasAttribute(`bng-scoped-nav`)?scopeElement[SCOPED_NAV_PROPERTY_NAME]:{};return domScopedNavProps.passthroughActive&&domScopedNavProps.passthroughEnabled&&domScopedNavProps.passthroughEvents.includes(eventData.name)}_eventMatchesDescriptor(eventData,descriptor){for(let[item,value]of Object.entries(descriptor))if(value!==void 0)if(item===`focusRequired`){if(value&&!value.contains(document.activeElement))return!1}else{if(!(item in eventData))return!1;if(typeof value==`function`){if(!value(eventData[item]))return!1}else if(eventData[item]!=value)return!1}return!0}};const isOnOffEvent=eventName=>!VALUE_BASED_EVENTS.includes(eventName),checkOn=value=>value,normalizeEventDescriptor=eventDescriptor=>({string:{name:eventDescriptor,value:isOnOffEvent(eventDescriptor)?checkOn:void 0,modified:!1,extras:void 0},object:{...eventDescriptor,value:`value`in eventDescriptor?eventDescriptor.value:isOnOffEvent(eventDescriptor.name)?checkOn:void 0}})[typeof eventDescriptor]||!1,eventMatchesDescriptor=(eventData,descriptor)=>{for(let[item,value]of Object.entries(descriptor))if(value!==void 0)if(item===`focusRequired`){if(value&&!value.contains(document.activeElement))return!1}else{if(!(item in eventData))return!1;if(typeof value==`function`){if(!value(eventData[item]))return!1}else if(eventData[item]!=value)return!1}return!0},getDescriptorEventNameText=descriptor=>descriptor.name?typeof descriptor.name==`function`?descriptor.name.name:descriptor.name:`ALL`;var HandlerFactory=class{static createHandler(eventDescriptor,userHandler){let descriptor=normalizeEventDescriptor(eventDescriptor);if(!descriptor)throw Error(`Invalid event descriptor when trying to create a UINav handler. Expecting a String or an Object.`);let handlerFuncName=userHandler?.name||`uiNav_${getDescriptorEventNameText(descriptor)}_handler`,disabled=!1;function wrapper(event){let eventData=event?.detail||{};return disabled||!eventMatchesDescriptor(eventData,descriptor)?!0:userHandler(event)}return Object.defineProperty(wrapper,`name`,{value:handlerFuncName}),Object.defineProperty(wrapper,`disabled`,{configurable:!1,get:()=>disabled,set:state=>{disabled=state}}),wrapper}static normalizeEventDescriptor(eventDescriptor){return{string:{name:eventDescriptor,value:isOnOffEvent(eventDescriptor)?checkOn:void 0,modified:!1,extras:void 0},object:{...eventDescriptor,value:`value`in eventDescriptor?eventDescriptor.value:isOnOffEvent(eventDescriptor.name)?checkOn:void 0}}[typeof eventDescriptor]||!1}},UINavHandlers=class{constructor(){this.scopeRegistry=new ScopeRegistry}add(domElement,uiNavHandlerOrDescriptor,handler$1=void 0){let scopeElement=domElement.closest(`[${UI_SCOPE_ATTR$2}]`);return scopeElement?this.addWithScope(domElement,uiNavHandlerOrDescriptor,handler$1,scopeElement):this.addIndividual(domElement,uiNavHandlerOrDescriptor,handler$1)}remove(domElement,uiNavHandler){domElement.closest(`[bng-ui-scope]`)?this.scopeRegistry.unregister(domElement,uiNavHandler):this.removeIndividual(domElement,uiNavHandler)}addWithScope(domElement,uiNavHandlerOrDescriptor,handler$1,scopeElement){let targetElement=domElement;if(!scopeElement.contains(targetElement))return console.error(`UINav: Attempting to register handler for element outside scope`,{targetElement,scopeElement,scopeId:scopeElement.getAttribute(UI_SCOPE_ATTR$2)}),this.addIndividual(domElement,uiNavHandlerOrDescriptor,handler$1);let wrapperHandler=handler$1?HandlerFactory.createHandler(uiNavHandlerOrDescriptor,handler$1):uiNavHandlerOrDescriptor,handlerDescriptor={element:domElement,eventDescriptor:HandlerFactory.normalizeEventDescriptor(uiNavHandlerOrDescriptor),handler:wrapperHandler,disabled:!1};return this.scopeRegistry.register(scopeElement,handlerDescriptor)}addIndividual(domElement,uiNavHandlerOrDescriptor,handler$1){let uiNavHandler=handler$1?HandlerFactory.createHandler(uiNavHandlerOrDescriptor,handler$1):uiNavHandlerOrDescriptor;return domElement.addEventListener(DOM_UI_NAVIGATION_EVENT,uiNavHandler),uiNavHandler}removeIndividual(domElement,uiNavHandler){domElement.removeEventListener(DOM_UI_NAVIGATION_EVENT,uiNavHandler)}},handlers_default=new UINavHandlers;function usePopupUINavScopeName(baseName,props){let attrs=useAttrs(),scopeName=baseName+`__`+attrs.__id;return useUINavScope(scopeName),watch(()=>props.popupActive,()=>props.popupActive&&useUINavScope(scopeName)),scopeName}function useUINavScope(scope$1=void 0,restoreScopeOnUnmount=!0){let currentScope=ref(scope$1),oldScope,scopeChanged=!1,setScope=newScope=>{scopeChanged=!0,currentScope.value=newScope,getUINavServiceInstance().setActiveScope(newScope)},restoreOldScope=()=>{getUINavServiceInstance().setActiveScope(oldScope)};return onMounted(()=>{oldScope=getUINavServiceInstance().activeScope,currentScope.value?setScope(currentScope.value):currentScope.value=oldScope}),onUnmounted(()=>{scopeChanged&&restoreScopeOnUnmount&&restoreOldScope()}),{current:computed(()=>currentScope.value),set:setScope,get oldScope(){return oldScope}}}function watchUINavEventChange(domElementRef,handler$1){return watch(()=>{if(!domElementRef.value)return{};let eventName=domElementRef.value.getAttribute(UI_EVENT_ATTR);return{eventName,action:ACTIONS_BY_UI_EVENT[eventName]}},handler$1)}const eventFirer=uiEvent=>value=>getUINavServiceInstance().fireEvent(uiEvent,value);var counter=0;const uniqueNum=()=>++counter%1e5+Math.random(),uniqueId=(name=``,separator=`.`)=>{let str=`${name?name+separator:``}${uniqueNum().toString(16)}`;return separator===`.`?str:str.replace(`.`,separator)},uniqueSafeId=()=>uniqueId(``,`_`);var DEFAULT_NAVIGATION=[...MONITORED_UI_NAV_EVENTS,`back`],ALWAYS_ACTIVE=[`ok`,`menu`,`back`],BLOCKER=Symbol(`uiNavBlocker`);const useUINavTracker=defineStore(`uiNavTracker`,()=>{let{lua,events:events$3}=useBridge(),showErrors=window.beamng&&!window.beamng.shipping,initialised=!1,trackedEvents=ref([]),trackedInstances={},ignoredEvents=ref([]),ignoredInstances={},blockedEvents$1=ref([]),blockedInstances={},unblockedEvents=ref([]),unblockedInstances={},activeEvents=ref([]),labelRegistry=useUiNavLabel();function updateBlocklist(){let uiNavService=getUINavServiceInstance(),eventsToBlock=blockedEvents$1.value.filter(name=>!unblockedEvents.value.includes(name));uiNavService.setBlockedEvents(eventsToBlock)}let raf;function update$6(eventName){cancelAnimationFrame(raf),raf=requestAnimationFrame(()=>{activeEvents.value=trackedEvents.value.filter(e=>!ignoredEvents.value.includes(e.name)&&(unblockedEvents.value.includes(e.name)||!blockedEvents$1.value.includes(e.name))).map(e=>({...e,nogroup:!!trackedInstances[e.name]?.at(-1)?.nogroup}))})}let ownerIdCheck=ownerId$1=>{if(typeof ownerId$1!=`string`||!ownerId$1)throw Error(`ownerId is required and must be a string`)},eventNameCheck=(eventName,quiet=!1)=>{let ok=!0;return typeof eventName!=`string`||!eventName?(showErrors&&logger_default.error(`eventName is required`),ok=!1):eventName in ACTIONS_BY_UI_EVENT||(showErrors&&!quiet&&logger_default.error(`eventName ${eventName} does not exist`),ok=!1),ok},getRecentInstance=eventName=>trackedInstances[eventName].findLast(inst=>inst.element!==BLOCKER),parseActive=(active,eventName)=>typeof active==`boolean`?active:ALWAYS_ACTIVE.includes(eventName);function addEvent(eventName,ownerId$1,element=null,options={}){if(initialised||rebind(),!eventNameCheck(eventName))return;ownerIdCheck(ownerId$1),trackedInstances[eventName]||(trackedInstances[eventName]=[]),element||=window.document.body;let instance$1=trackedInstances[eventName].find(instance$2=>instance$2.ownerId===ownerId$1);if(instance$1){instance$1.element=element,instance$1.nogroup=!!options?.nogroup,instance$1.active=parseActive(options?.active,eventName),update$6(eventName);return}if(trackedInstances[eventName].push({ownerId:ownerId$1,element,nogroup:!!options?.nogroup,active:parseActive(options?.active,eventName)}),trackedInstances[eventName].length===1){let event={name:eventName,label:computed(()=>{let instance$2=getRecentInstance(eventName);return labelRegistry.getLabel(eventName,instance$2?.element)||null}),action:computed(()=>getRecentInstance(eventName)?.active?eventFirer(eventName):null)};trackedEvents.value.push(event),actionSwitch(!0,eventName)}update$6(eventName)}function updateEvent(eventName,ownerId$1,element,options={}){if(ownerIdCheck(ownerId$1),!eventNameCheck(eventName))return;element||=window.document.body;let instance$1=trackedInstances[eventName]?.find(instance$2=>instance$2.ownerId===ownerId$1);if(!instance$1){addEvent(eventName,ownerId$1,element,!1,options);return}instance$1.element=element,instance$1.nogroup=!!options?.nogroup,instance$1.active=parseActive(options?.active,eventName),update$6(eventName)}function removeEvent(eventName,ownerId$1,element=null){if(ownerIdCheck(ownerId$1),!eventNameCheck(eventName)||!trackedInstances[eventName])return;element||=window.document.body;let idx=trackedInstances[eventName].findIndex(instance$1=>instance$1.ownerId===ownerId$1);if(idx!==-1&&(trackedInstances[eventName].splice(idx,1),update$6(eventName),trackedInstances[eventName].length===0)){delete trackedInstances[eventName];let idx$1=trackedEvents.value.findIndex(h$1=>h$1.name===eventName);idx$1>-1&&(trackedEvents.value.splice(idx$1,1),actionSwitch(!1,eventName))}}function addHelper(eventList,instanceList,eventName,ownerId$1,func,quiet=!1){ownerIdCheck(ownerId$1),eventNameCheck(eventName,quiet)&&(eventList.value.includes(eventName)||(eventList.value.push(eventName),func&&func(),instanceList[eventName]||(instanceList[eventName]=[])),instanceList[eventName].push(ownerId$1))}function removeHelper(eventList,instanceList,eventName,ownerId$1,func,quiet=!1){if(ownerIdCheck(ownerId$1),!eventNameCheck(eventName,quiet)||!(eventName in instanceList))return;let instIdx=instanceList[eventName].indexOf(ownerId$1);if(instIdx!==-1&&(instanceList[eventName].splice(instIdx,1),instanceList[eventName].length===0)){let idx=eventList.value.indexOf(eventName);idx>-1&&(eventList.value.splice(idx,1),func&&func())}}function addIgnore(eventName,ownerId$1){addHelper(ignoredEvents,ignoredInstances,eventName,ownerId$1,null,!0)}function removeIgnore(eventName,ownerId$1){removeHelper(ignoredEvents,ignoredInstances,eventName,ownerId$1,null,!0)}function addBlocker(eventName,ownerId$1){addHelper(blockedEvents$1,blockedInstances,eventName,ownerId$1,()=>{addEvent(eventName,ownerId$1,BLOCKER),updateBlocklist()})}function removeBlocker(eventName,ownerId$1){removeHelper(blockedEvents$1,blockedInstances,eventName,ownerId$1,()=>{removeEvent(eventName,ownerId$1,BLOCKER),updateBlocklist()})}function addForceUnblock(eventName,ownerId$1){addHelper(unblockedEvents,unblockedInstances,eventName,ownerId$1,()=>{update$6(eventName),updateBlocklist()})}function removeForceUnblock(eventName,ownerId$1){removeHelper(unblockedEvents,unblockedInstances,eventName,ownerId$1,()=>{update$6(eventName),updateBlocklist()})}let actionSwitch=async(enabled,eventName)=>{eventName!==`menu`&&(!enabled&&blockedEvents$1.value.includes(eventName)||await lua.extensions.core_input_bindings.setMenuActionEnabled(enabled,ACTIONS_BY_UI_EVENT[eventName]))};function rebind(){initialised||(initialised=!0,getUINavServiceInstance().clearBlockedEvents(),DEFAULT_NAVIGATION.forEach(name=>addEvent(name,`__uiNavTracker_default`))),Object.keys(ACTIONS_BY_UI_EVENT).filter(name=>!DEFAULT_NAVIGATION.includes(name)&&!trackedEvents.value.find(e=>e.name===name)).forEach(name=>actionSwitch(!1,name))}return lua.extensions.core_input_bindings.getMenuActionMapEnabled().then(enabled=>enabled&&rebind()),events$3.on(`MenuActionMapEnabled`,enabled=>enabled&&rebind()),{activeEvents,blockedEvents:blockedEvents$1,unblockedEvents,addEvent,updateEvent,removeEvent,addIgnore,removeIgnore,addBlocker,removeBlocker,addForceUnblock,removeForceUnblock}});function useUINavBlocker(){let id=uniqueId(`uiNavBlocker`),tracker=useUINavTracker(),allEventNames=Object.keys(ACTIONS_BY_UI_EVENT),defaultEvents=Object.freeze(Object.fromEntries(DEFAULT_NAVIGATION.map(name=>[name,name]))),allEvents=Object.freeze(UI_EVENTS),blockedEvents$1=[],unblockedEvents=[],filterEvents=events$3=>{if(!events$3)return[];if(typeof events$3==`string`)events$3=[events$3];else if(events$3.length===0)return[];return events$3.reduce((res,name)=>allEventNames.includes(name)&&!res.includes(name)?[...res,name]:res,[])};function allowOnly(events$3=[]){events$3=filterEvents(events$3),blockOnly(allEventNames.filter(name=>!events$3.includes(name)))}function allowNavigationOnly(enforce=!0){if(!enforce)return blockOnly();let events$3=[...DEFAULT_NAVIGATION,`menu`];blockOnly(allEventNames.filter(name=>!events$3.includes(name)))}function blockOnly(events$3=[]){events$3=filterEvents(events$3),blockedEvents$1.filter(name=>!events$3.includes(name)).forEach(name=>tracker.removeBlocker(name,id)),blockedEvents$1.splice(0),blockedEvents$1.push(...events$3),blockedEvents$1.forEach(name=>tracker.addBlocker(name,id))}function ensureNoBlock(events$3=[]){events$3=filterEvents(events$3),unblockedEvents.filter(name=>!events$3.includes(name)).forEach(name=>tracker.removeForceUnblock(name,id)),unblockedEvents.splice(0),unblockedEvents.push(...events$3),events$3.forEach(name=>tracker.addForceUnblock(name,id))}function isBlocked(eventName){return tracker.unblockedEvents.includes(eventName)?!1:tracker.blockedEvents.includes(eventName)}let clear=()=>blockOnly();return onUnmounted(clear),{allEvents,defaultEvents,allowOnly,allowNavigationOnly,blockOnly,clear,ensureNoBlock,isBlocked}}const useUiNavLabel=defineStore(`uiNavLabeler`,()=>{let elementLabels=reactive(new WeakMap),eventElements=reactive({});function registerLabel(element,eventNames,label){elementLabels.has(element)||elementLabels.set(element,{});let elementEvents=elementLabels.get(element);Array.isArray(eventNames)||(eventNames=[eventNames]);for(let eventName of eventNames)elementEvents[eventName]=label,eventElements[eventName]||(eventElements[eventName]=new Set),eventElements[eventName].add(element)}function clearLabels(element,eventNames=null){if(!elementLabels.has(element))return;let elementEvents=elementLabels.get(element);if(eventNames===null){for(let eventName of Object.keys(elementEvents))eventElements[eventName]&&eventElements[eventName].delete(element);elementLabels.delete(element)}else{for(let eventName of eventNames)delete elementEvents[eventName],eventElements[eventName]&&eventElements[eventName].delete(element);Object.keys(elementEvents).length===0&&elementLabels.delete(element)}}function getLabel(eventName,element=null){if(element&&elementLabels.has(element)&&elementLabels.get(element)[eventName])return elementLabels.get(element)[eventName];if(eventElements[eventName])for(let el of eventElements[eventName]){let label=elementLabels.get(el)?.[eventName];if(label)return label}return null}function getElementEvents(element){return elementLabels.has(element)?Object.keys(elementLabels.get(element)):[]}return{registerLabel,clearLabels,getLabel,getElementEvents}});var LUA_EXTENSION_NAME=`ui_topBar`;const useTopBar=defineStore(`topBar`,()=>{let{events:events$3}=useBridge(),setupComplete=!1,_items=ref({}),_activeItem=ref(null),visible=ref(!1),hiddenItems=ref([]),gameState$1=reactive({isInGame:void 0,gameState:void 0,uiState:void 0,isCareerActive:void 0,isGarageActive:void 0,isMissionActive:void 0,isScenarioActive:void 0}),sortItems=(a$1,b)=>(a$1.order??0)-(b.order??0),items$2=computed(()=>Object.values(_items.value).filter(item=>!hiddenItems.value||!hiddenItems.value.includes(item.id)).sort(sortItems)),activeItem=computed({get:()=>_activeItem.value,set:value=>{value!==_activeItem.value&&(_activeItem.value=value,Lua_default.ui_topBar.setActiveItem(value))}}),updateTopBarVisibility=()=>{if(!(!gameState$1.uiState||gameState$1.isInGame===void 0)){if(gameState$1.uiState.startsWith(`menu.mainmenu`)&&!gameState$1.isInGame&&(visible.value=!1),!visible.value||gameState$1.uiState===`unknown`){activeItem.value=null;return}if(gameState$1.uiState){let updatedActiveItem=Object.values(_items.value).find(item=>item.targetState===gameState$1.uiState);updatedActiveItem||=Object.values(_items.value).find(item=>item.substate&&gameState$1.uiState.startsWith(item.substate)),activeItem.value=updatedActiveItem?updatedActiveItem.id:null}updateHiddenItems()}};watch(()=>gameState$1.uiState,()=>nextTick(updateTopBarVisibility)),watch(()=>gameState$1.isInGame,()=>nextTick(updateTopBarVisibility));let selectPrevious=()=>{if(!visible.value)return;let len=items$2.value.length;if(len===0)return;let previousIndex=(items$2.value.findIndex(item=>item.id===activeItem.value)-1+len)%len;selectEntry(items$2.value[previousIndex].id)},selectNext=()=>{if(!visible.value)return;let len=items$2.value.length;if(len===0)return;let nextIndex=(items$2.value.findIndex(item=>item.id===activeItem.value)+1)%len;selectEntry(items$2.value[nextIndex].id)},selectEntry=itemId=>{visible.value&&(activeItem.value=itemId,Lua_default.ui_topBar.selectItem(itemId))},show=()=>{visible.value=!0},hide$2=()=>{visible.value=!1};function updateHiddenItems(){hiddenItems.value=Object.values(_items.value).filter(shouldHideItem).map(item=>item.id)}function shouldHideItem(item){if(!item.flags||item.flags.length===0)return!1;for(let flag of item.flags)if(flag===`inGameOnly`&&!gameState$1.isInGame||flag===`careerOnly`&&!gameState$1.isCareerActive||flag===`noCareer`&&gameState$1.isCareerActive||flag===`missionOnly`&&!gameState$1.isMissionActive||flag===`noMission`&&gameState$1.isMissionActive&&!gameState$1.isScenarioUnrestricted||flag===`garageOnly`&&!gameState$1.isGarageActive||flag===`noGarage`&&gameState$1.isGarageActive||flag===`scenarioOnly`&&!gameState$1.isScenarioActive||flag===`noScenario`&&gameState$1.isScenarioActive&&!gameState$1.isScenarioUnrestricted||flag===`careerGarageOnly`&&(!gameState$1.isCareerActive||!gameState$1.isGarageActive)||flag===`noCareerGarage`&&gameState$1.isCareerActive&&gameState$1.isGarageActive)return!0;return!1}function onCareerStateChanged(data){gameState$1.isCareerActive=data.isActive}function onGarageStateChanged(data){gameState$1.isGarageActive=data.isActive}function onMissionStateChanged(data){gameState$1.isMissionActive=data.isActive}function onScenarioStateChanged(data){gameState$1.isScenarioActive=data.isActive}function onDataRequested(data){let{isInGame,items:dataItems}=data;_items.value=dataItems,gameState$1.isInGame=isInGame,hiddenItems.value=[]}function onGameStateChanged(data){gameState$1.isInGame=data.isInGame,gameState$1.isCareerActive=data.isCareerActive,gameState$1.isGarageActive=data.isGarageActive,gameState$1.isMissionActive=data.isMissionActive,gameState$1.isScenarioActive=data.isScenarioActive,gameState$1.isScenarioUnrestricted=data.isScenarioUnrestricted,nextTick(()=>updateHiddenItems())}function onEntriesChanged(data){_items.value=data}function onVisibleItemsChanged(data){hiddenItems.value=data}function onShow(){visible.value=!0}function onHide(){visible.value=!1}let debouncedStateChange=debounce(data=>{gameState$1.uiState=(data.fullPath||data.name||`unknown`).replace(/^\//,``)},100);function onUIStateChanged(data){debouncedStateChange(data)}let eventHandlerMap={selectPrevious,selectNext,OnCareerActive:onCareerStateChanged,garageStateChanged:onGarageStateChanged,missionStateChanged:onMissionStateChanged,scenarioStateChanged:onScenarioStateChanged,dataRequested:onDataRequested,gameStateChanged:onGameStateChanged,entriesChanged:onEntriesChanged,visibleItemsChanged:onVisibleItemsChanged,show:onShow,hide:onHide};function addListeners(){for(let eventName of Object.keys(eventHandlerMap))events$3.on(`${LUA_EXTENSION_NAME}_${eventName}`,eventHandlerMap[eventName])}function removeListeners$1(){for(let eventName of Object.keys(eventHandlerMap))events$3.off(`${LUA_EXTENSION_NAME}_${eventName}`,eventHandlerMap[eventName])}return(async()=>{setupComplete||=(await Lua_default.extensions.isExtensionLoaded(LUA_EXTENSION_NAME)||await Lua_default.extensions.load(LUA_EXTENSION_NAME),addListeners(),await Lua_default.ui_topBar.requestData(),!0)})(),{activeItem,items:items$2,visible,gameState:gameState$1,show,hide:hide$2,selectEntry,selectPrevious,selectNext,onUIStateChanged,dispose:()=>{removeListeners$1(),Lua_default.extensions.unload(LUA_EXTENSION_NAME)}}});var events$2,beamNG,serviceProviders=ref(),online=ref(!1),videoAdapter=ref(``),modCounts=ref({total:0,active:0}),gameState=ref(),mainMenuBackgroundRequired=ref(),mainMenuFirstTime=ref(!0),serviceProvidersOnline=computed(()=>{let provs=serviceProviders.value,gotInfo=!!provs,ret={eos:gotInfo&&provs.eos&&provs.eos.loggedin,steam:gotInfo&&provs.steam&&provs.steam.loggedin&&provs.steam.working};return ret.any=Object.values(ret).some(v=>v),ret}),version,versionSimple,buildInfo,init$2=()=>{let api$1;({api:api$1,events:events$2,beamNG}=useBridge()),beamNG||=FAKE_BEAMNG_OBJ,api$1.serializeToLuaCheck(`English: hello`),api$1.serializeToLuaCheck(`Spanish: güeñes`),api$1.serializeToLuaCheck(`French: bâguéttè, garçon`),api$1.serializeToLuaCheck(`Czech: Kl�vesnice`),api$1.serializeToLuaCheck(`Korean: \r��\v��\v��`),api$1.serializeToLuaCheck(`Chinese Sim: 欢迎来到简体中文版的`),api$1.serializeToLuaCheck(`Chinese Tr: 歡迎來到`),api$1.serializeToLuaCheck(`Japanese: 』日本語版にようこそ`),api$1.serializeToLuaCheck(`Polish: źćłąóę`),api$1.serializeToLuaCheck(`Russian: абвгеёьъ`),events$2.on(`ServiceProviderInfo`,info=>serviceProviders.value=info),events$2.on(`OnlineStateChanged`,state=>online.value=state),events$2.on(`ModManagerModsChanged`,_processModData),events$2.on(`ShowEntertainingBackground`,state=>mainMenuBackgroundRequired.value=state),events$2.on(`GameStateUpdate`,state=>gameState.value=state.state),version=beamNG.version,versionSimple=_toSimpleVersion(beamNG.version),buildInfo=beamNG.buildinfo,refresh()},refresh=()=>{_requestServiceProviders(),_requestOnlineState(),_refreshVideoAdapter(),_refreshModData()},_refreshVideoAdapter=()=>Lua_default.Engine.Render.getAdapterType().then(adapter=>videoAdapter.value=adapter),_requestServiceProviders=()=>beamNG.requestServiceProviderInfo(),_requestOnlineState=()=>Lua_default.core_online.requestState(),_refreshModData=()=>Lua_default.core_modmanager.requestState(),sysInfo_default={init:init$2,refresh,serviceProviders,serviceProvidersOnline,online,videoAdapter,modCounts,gameState,mainMenuBackgroundRequired,mainMenuFirstTime,get version(){return version},get versionSimple(){return versionSimple},get buildInfo(){return buildInfo}},_toSimpleVersion=versionStr=>{let bits=versionStr.split(`.`);return bits.length==5&&bits.pop(),bits.join(`.`).replace(/(\.0)+$/,``)},_processModData=data=>{let mods=Object.values(data).filter(mod=>mod.modname!=`translations`);modCounts.value.total=mods.length,modCounts.value.active=mods.filter(({active})=>active).length},FAKE_BEAMNG_OBJ={version:`0.12.3.4.FAKE12345`,buildInfo:`Sample Fake BuildInfo - running outside of game`,requestServiceProviderInfo(){events$2.emit(`ServiceProviderInfo`,{steam:{loggedin:!0,accountID:`12345678901234567`,playerName:`fakeplayer`,branch:`qa_latest`,language:`english`,useSteam:!0,working:!0}})}};const useLibStore=defineStore(`lib`,{});var bridge$2,stateStack=[];function add(stateName){rem(stateName),stateStack.push(stateName)}function rem(stateName){let idx=stateStack.lastIndexOf(stateName);idx>-1&&stateStack.splice(idx,1)}var luaStringify=any=>JSON.stringify(any).replace(/^\[(.*)\]$/,`{$1}`),luaReport=(stateName,opened)=>bridge$2.api.engineLua(`extensions.hook("onUIStateTriggered", ${luaStringify(stateName)}, ${luaStringify(!!opened)}, ${luaStringify(stateStack)})`);function reportState(stateName,opened,prevName=null){bridge$2||=useBridge(),prevName&&(rem(prevName),luaReport(prevName,!1)),opened?add(stateName):rem(stateName),luaReport(stateName,opened)}function reportPopupState(popup,opened){reportState(`/popup/${popup.componentName}/${popup.wrapper.blur?`fullscreen`:`aside`}`,opened)}function scroll(el,binding){let direction$1=binding.arg;el.scrollHeight<=el.clientHeight||(direction$1===`top`?el.scrollTop>0&&(el.scrollTop=0):direction$1===`bottom`&&el.scrollTop{let id,blurAmount=1,blurUpdateWrapper=debounce(updateBlur,50),resizeObserver,removePositionObserver;function observe(){resizeObserver||(resizeObserver=new ResizeObserver(blurUpdateWrapper),resizeObserver.observe(el)),removePositionObserver||=observePosition(el,blurUpdateWrapper)}function unobserve(){resizeObserver&&resizeObserver.disconnect(),removePositionObserver&&removePositionObserver(),resizeObserver=null,removePositionObserver=null}elemBlurs.set(el,{blurUpdateWrapper,processBlurVal,observe,unobserve}),processBlurVal(binding.value),window.addEventListener(`resize`,blurUpdateWrapper);function processBlurVal(val){switch(typeof val){case`undefined`:val=1;break;case`boolean`:val=val?1:0;break;case`number`:(val<0||val>1)&&(logger_default.error(`Attempted to use v-bng-blur with a number out of range 0..1: ${val}\nSee stack:`,logger_default.STACK_TRACE),val=1);break;default:logger_default.error(`Attempted to use v-bng-blur with a non-number, non-boolean value: ${val}\nSee stack:`,logger_default.STACK_TRACE),val=0}blurAmount=val,blurUpdateWrapper()}function calcBlur(){let rect=el.getBoundingClientRect();return rect.width>0&&rect.height>0&&rect.bottom>0&&rect.top0&&rect.left{let elemBlur=elemBlurs.get(el);elemBlur&&binding.value!=binding.oldValue&&elemBlur.processBlurVal(binding.value)},unmounted:(el,binding)=>{let elemBlur=elemBlurs.get(el);elemBlur&&(elemBlur.unobserve(),elemBlur.processBlurVal(0),window.removeEventListener(`resize`,elemBlur.blurUpdateWrapper),elemBlurs.delete(el))}},DEFAULT_HOLD_DELAY=400,DEFAULT_REPEAT_INTERVAL=100,HOLD_CSS_TIME_VAR=`--hold-time`,HOLD_START_CSS_CLASS=`hold-start`,HOLD_ACTIVE_CSS_CLASS=`hold-active`,HOLD_COMPLETED_CSS_CLASS=`hold-completed`,EVENT_CLICK=`click`,EVENT_HOLD=`hold`,ELEMENT_ID=`__BNG_CLICK_ID`,curId=0,datas={};function update$5(element,binding){let id=element[ELEMENT_ID]||(element[ELEMENT_ID]=++curId),data=datas[id]||(datas[id]={id,element,events:{},binding:{}});if(typeof binding.value==`object`)data.binding=binding.value;else if(typeof binding.value==`function`){let cbName=binding.modifiers?.hold?`holdCallback`:`clickCallback`;data.binding[cbName]=binding.value}return data.controllerOnly=!!binding.modifiers?.controller,data.hasClick=typeof data.binding.clickCallback==`function`,data.hasHold=typeof data.binding.holdCallback==`function`,typeof data.binding.holdDelay!=`number`&&(data.binding.holdDelay=DEFAULT_HOLD_DELAY),typeof data.binding.repeatInterval!=`number`&&(data.binding.repeatInterval=DEFAULT_REPEAT_INTERVAL),data}function remove(element){let id=element[ELEMENT_ID];if(!id)return;let data=datas[id];data&&(`mouseleave`in data.events&&data.events.mouseleave(),updateEvents(id),delete datas[id],delete element[ELEMENT_ID])}function updateEvents(id,events$3={}){let data=datas[id];if(data){for(let event in data.events)data.element.removeEventListener(event,data.events[event]);for(let event in events$3)data.element.addEventListener(event,events$3[event]);data.events=events$3}}var BngClick_default={mounted:(el,binding)=>{let data=update$5(el,binding),approveEvent=evt=>data.controllerOnly?!!evt.fromController:evt.button===0||evt.fromController,tmrHoldActive;updateEvents(data.id,{mousedown:e=>{approveEvent(e)&&(el.style.setProperty(HOLD_CSS_TIME_VAR,`${data.binding.holdDelay}ms`),el.classList.toggle(HOLD_START_CSS_CLASS,!0),clearTimeout(tmrHoldActive),tmrHoldActive=setTimeout(()=>el.classList.toggle(HOLD_ACTIVE_CSS_CLASS,!0),0),el.classList.toggle(HOLD_COMPLETED_CSS_CLASS,!1),canInvokeEventType(EVENT_CLICK)&&(detectedEventType=EVENT_CLICK),canInvokeEventType(EVENT_HOLD)&&startHoldDelayTimer(e))},mouseup:e=>{if(approveEvent(e)){switch(el.style.removeProperty(HOLD_CSS_TIME_VAR),el.classList.toggle(HOLD_START_CSS_CLASS,!1),el.classList.toggle(HOLD_ACTIVE_CSS_CLASS,!1),clearTimeout(tmrHoldActive),stopHoldDelayTimer(),detectedEventType){case EVENT_CLICK:doAction(EVENT_CLICK,e);break;case EVENT_HOLD:stopHoldTimer();break}detectedEventType=null}},mouseleave:()=>{switch(el.style.removeProperty(HOLD_CSS_TIME_VAR),el.classList.toggle(HOLD_START_CSS_CLASS,!1),el.classList.toggle(HOLD_ACTIVE_CSS_CLASS,!1),clearTimeout(tmrHoldActive),stopHoldDelayTimer(),detectedEventType){case EVENT_HOLD:stopHoldTimer();break}detectedEventType=null},blur:()=>data.events.mouseleave()});let detectedEventType,holdDelayTimer,holdTimer;function startHoldDelayTimer(e){stopHoldTimer(),stopHoldDelayTimer(),holdDelayTimer=setTimeout(()=>{el.classList.toggle(HOLD_COMPLETED_CSS_CLASS,!0),detectedEventType=EVENT_HOLD,startHoldTimer(e)},data.binding.holdDelay)}function stopHoldDelayTimer(){holdDelayTimer&&=(clearTimeout(holdDelayTimer),null)}function startHoldTimer(e){doAction(EVENT_HOLD,e),data.binding.repeatInterval&&(stopHoldTimer(),holdTimer=setInterval(()=>{doAction(EVENT_HOLD,e)},data.binding.repeatInterval))}function stopHoldTimer(){holdTimer&&=(clearInterval(holdTimer),null)}function doAction(eventType,originalEvent){let callback=getCallback(eventType);callback&&(eventType==EVENT_HOLD?setTimeout(()=>callback(originalEvent),100):callback(originalEvent))}function getCallback(arg){switch(arg){case EVENT_CLICK:return data.binding.clickCallback;case EVENT_HOLD:return data.binding.holdCallback}return null}function canInvokeEventType(eventType){switch(eventType){case EVENT_CLICK:return data.hasClick;case EVENT_HOLD:return data.hasHold}return!1}},updated:update$5,beforeUnmount:remove},BngDisabled_default=(el,{value})=>{let has$1={disabled:el.hasAttribute(`disabled`),tabindex:el.hasAttribute(`tabindex`)};!has$1.disabled&&value?(el.setAttribute(`disabled`,`disabled`),has$1.tabindex&&(el._BNG_TABINDEX=el.getAttribute(`tabindex`),el.setAttribute(`tabindex`,`-1`))):has$1.disabled&&!value&&(el.removeAttribute(`disabled`),has$1.tabindex&&`_BNG_TABINDEX`in el&&el.getAttribute(`tabindex`)!==el._BNG_TABINDEX&&(el.setAttribute(`tabindex`,el._BNG_TABINDEX),delete el._BNG_TABINDEX))},DELAY=300,EVENTS_IN=[`uinav-focus`,`focus`,`focusin`],EVENTS_OUT=[`uinav-blur`,`blur`,`focusout`],elems$1=new Map,globInit=!1;function initGlobals(){globInit=!0;let running=!1,targets={in:[],out:[]};function preventer(){for(let[part,list]of Object.entries(targets))if(list.length!==0){for(let target of list)for(let[uid$2,data]of elems$1)if(!(!data.capture||!data.timer||!data.element)){if(part===`in`){if(data.element===target||data.element.contains(target))continue}else if(data.element!==target&&!data.element.contains(target))continue;clearTimeout(data.timer),data.timer=null;break}list.splice(0)}}function handler$1(evt,eventIn){if(elems$1.size===0)return;let target=evt.detail?.target||evt.target;if(!target)return;let part=eventIn?`in`:`out`;targets[part].includes(target)||targets[part].push(target),!running&&(running=!0,window.requestAnimationFrame(()=>{preventer(),running=!1}))}EVENTS_IN.forEach(evt=>document.addEventListener(evt,evt$1=>handler$1(evt$1,!0),!0)),EVENTS_OUT.forEach(evt=>document.addEventListener(evt,evt$1=>handler$1(evt$1,!1),!0))}function createHandler(data){return data.capture?evt=>{evt.detail?.doubleToSingle||(evt.preventDefault(),evt.stopImmediatePropagation(),data.timer?(clearTimeout(data.timer),data.timer=null,data.callback?.()):data.timer=setTimeout(()=>{data.timer=null;let click$1=new CustomEvent(`click`,{...evt,bubbles:!0,cancelable:!0,detail:{doubleToSingle:!0}});data.element.dispatchEvent(click$1)},DELAY))}:()=>{data.timer&&=(clearTimeout(data.timer),null);let now$1=Date.now();if(data.time&&now$1-data.time<=DELAY){data.time=0,data.callback?.();return}data.time=now$1}}function update$4(vnode,callback=void 0,mod={}){!globInit&&initGlobals();let el=vnode?.el;if(!el)return;let uid$2=vnode?.component?.uid||vnode?.key||el,capture=!!mod.capture,data=elems$1.get(uid$2)||{};data.handler&&data.element===el&&callback&&`callback`in data&&data.callback===callback&&data.capture===capture||(`element`in data||(data.element=el,data.callback=callback,data.capture=capture),data.handler&&(!callback||data.capture!==capture||data.element!==el)&&(delete data.callback,el.removeEventListener(`click`,data.handler,{capture:data.capture}),elems$1.delete(uid$2)),callback&&(data.handler?data.callback=callback:(data.capture=capture,data.handler=createHandler(data),el.addEventListener(`click`,data.handler,{capture}),elems$1.set(uid$2,data))))}var BngDoubleClick_default={mounted:(el,{value,modifiers,arg}={},vnode)=>update$4(vnode||{el},value,{capture:arg===`capture`,...modifiers}),updated:(el,{value,modifiers,arg}={},vnode)=>update$4(vnode||{el},value,{capture:arg===`capture`,...modifiers}),unmounted:(el,vnode)=>update$4(vnode||{el})},DRAG_START_EVENT_NAME=`bngDragStart`,DRAG_OVER_EVENT_NAME=`bngDragOver`,DRAG_END_EVENT_NAME=`bngDragEnd`;const DRAG_EVENTS=Object.freeze({dragStart:DRAG_START_EVENT_NAME,dragOver:DRAG_OVER_EVENT_NAME,dragEnd:DRAG_END_EVENT_NAME});var STORE_NAME=`controls`,store,DEVICE_ICONS={key:`keyboard`,mou:`mouseLMB`,vin:`smartphone2`,whe:`steeringWheelCommon`,gam:`gamepadOld`,xin:`gamepadOld`,default:`gamepad`};const CONTROL_LABELS={escape:`ESC`,enter:`⏎`,tab:`⭾`,capslock:`⇪`,backspace:`⌫`,delete:`Del`,insert:`Ins`,home:`Home`,end:`End`,pageup:`PG↑`,pagedown:`PG↓`,lshift:`L⇧`,rshift:`R⇧`,shift:`⇧`,lcontrol:`L Ctrl`,rcontrol:`R Ctrl`,lalt:`L Alt`,ralt:`R Alt`,left:`←`,right:`→`,up:`↑`,down:`↓`,space:`␣`,grave:`~`,backslash:`\\`,"/":`/`,comma:`,`,period:`.`,";":`;`,apostrophe:`'`,"[":`[`,"]":`]`,minus:`-`,"+":`NP+`,"*":`NP*`,numpaddivide:`NP/`,numpad0:`NP0`,numpad1:`NP1`,numpad2:`NP2`,numpad3:`NP3`,numpad4:`NP4`,numpad5:`NP5`,numpad6:`NP6`,numpad7:`NP7`,numpad8:`NP8`,numpad9:`NP9`,numpaddecimal:`NP.`,numpadenter:`NP⏎`,xaxis:`X Axis`,yaxis:`Y Axis`,zaxis:`Z Axis`,rzaxis:`R Z Axis`,thumblx:`L Thumb X`,thumbly:`L Thumb Y`,thumbrx:`R Thumb X`,thumbry:`R Thumb Y`};var controlLabel=control=>control.toLowerCase().split(/[ -]+/).map(ctl=>CONTROL_LABELS[ctl]||(ctl.startsWith(`button`)?`BTN`+ctl.substring(6):ctl)).join(` + `),CONTROL_ICONS={pc_mouse:{button0:`mouseLMB`,button1:`mouseRMB`,button2:`mouseMMB`,xaxis:`mouseXAxis`,yaxis:`mouseYAxis`,zaxis:`mouseWheel`},xbox:{btn_a:`xboxA`,btn_b:`xboxB`,btn_x:`xboxX`,btn_y:`xboxY`,btn_back:`xboxView`,btn_start:`xboxMenu`,btn_l:`xboxLB`,triggerl:`xboxLT`,btn_r:`xboxRB`,triggerr:`xboxRT`,dpov:`xboxDDown`,lpov:`xboxDLeft`,rpov:`xboxDRight`,upov:`xboxDUp`,thumblx:`xboxXAxis`,thumbly:`xboxYAxis`,thumbrx:`xboxXRot`,thumbry:`xboxYRot`,btn_lt:`xboxLSButton`,btn_rt:`xboxRSButton`},ps:{button1:`psCross`,button3:`psTriangle`,button0:`psSquare`,button2:`psCircle`,button8:`psCreate2`,button9:`psMenu2`,button4:`psL1`,button6:`psL2`,button5:`psR1`,button7:`psR2`,dpov:`psDDown`,lpov:`psDLeft`,rpov:`psDRight`,upov:`psDUp`,xaxis:`psLSX`,yaxis:`psLSY`,zaxis:`psRSX`,rzaxis:`psRSY`,rxaxis:`psL2`,ryaxis:`psR2`,button10:`psL3Button`,button11:`psR3Button`,button13:`psTrackpadPressCenter`}};const DEVICE_CONTROLS={pc_mouse:Object.keys(CONTROL_ICONS.pc_mouse),xbox:Object.keys(CONTROL_ICONS.xbox),ps:Object.keys(CONTROL_ICONS.ps)};var extendControlGroupNames=groups=>groups.reduce((res,group)=>(res.push(group),res.push({...group,controls:group.controls.map(ctl=>CONTROL_LABELS[ctl])}),res),[]),GROUPED_CONTROLS={pc_keyboard:extendControlGroupNames([{label:`↑↓←→`,controls:[`left`,`right`,`up`,`down`]},{label:`NP 8↑ 2↓ 4← 6→`,controls:[`numpad2`,`numpad4`,`numpad6`,`numpad8`]}]),xbox:extendControlGroupNames([{icon:`xboxDDefaultSolid`,controls:[`upov`,`dpov`,`lpov`,`rpov`]},{icon:`xboxThumbL`,controls:[`thumblx`,`thumbly`]},{icon:`xboxThumbR`,controls:[`thumbrx`,`thumbry`]}]),ps:extendControlGroupNames([{icon:`psDDefaultSolid`,controls:[`upov`,`dpov`,`lpov`,`rpov`]},{icon:`psLS`,controls:[`xaxis`,`yaxis`]},{icon:`psRS`,controls:[`zaxis`,`rzaxis`]}])},DEVICE_FAMILY={mouse:`pc_mouse`,keyboard:`pc_keyboard`,xinput:`xbox`,ps5:`ps`},CONTROL_ICON_KEYS=Object.keys(DEVICE_FAMILY),getViewerOverrides=(devName=void 0,imagePack=void 0)=>{let family;return imagePack&&(imagePack in DEVICE_FAMILY?family=DEVICE_FAMILY[imagePack]:imagePack in CONTROL_ICONS&&(family=imagePack)),!family&&devName&&(devName=CONTROL_ICON_KEYS.find(key=>devName.startsWith(key))||devName,devName in DEVICE_FAMILY?family=DEVICE_FAMILY[devName]:devName in CONTROL_ICONS&&(family=devName)),family?{family,icons:CONTROL_ICONS[family]||{},groups:GROUPED_CONTROLS[family]||[]}:null},DEVICE_ORDER=[`wheel`,`joystick`,`xinput`,`gamepad`,`mouse`,`keyboard`],makeStore=defineStore(STORE_NAME,()=>{let{events:events$3}=useBridge(),devNamesOrder=DEVICE_ORDER.map(devType=>devType+`0`),actions=ref([]),categories=ref({}),categoriesList=ref([]),bindings=ref([]),bindingsPerDevice=computed(()=>Object.fromEntries(bindings.value.map(b=>[b.devname,b]))),bindingTemplate=ref({}),controllers=ref({}),players=ref({}),lastDeviceOrder=ref([...devNamesOrder]),lastDevice=computed(()=>isKbm(lastDeviceOrder.value[0])?kbmDevNames:lastDeviceOrder.value[0]),lastControllers=computed(()=>lastDeviceOrder.value.filter(devName=>!isKbm(devName))),lastControllersSignature=computed(()=>lastControllers.value.sort().join(`::`)),isControllerUsed=computed(()=>!isKbm(lastDeviceOrder.value[0])),isControllerAvailable=computed(()=>lastDeviceOrder.value.some(devName=>!isKbm(devName))),lastDeviceSimple=computed(()=>isControllerUsed.value?lastDevice.value:null),getDevType=devName=>devName?devName.replace(/\d+$/,``):``,deviceSorter=(a$1,b)=>DEVICE_ORDER.indexOf(getDevType(a$1))-DEVICE_ORDER.indexOf(getDevType(b)),kbmDevNames=[`keyboard0`,`mouse0`].sort(deviceSorter),kbmShortNames=kbmDevNames.map(devName=>devName.slice(0,3)),isKbm=devName=>devName&&kbmShortNames.includes(devName.slice(0,3)),_receiveControlsData=data=>(controllers.value=data,_updateDeviceNotes()),_receivePlayersData=data=>players.value=data,_receiveBindingsData=_processBindingsData,_getBindingsData=()=>Lua_default.extensions.core_input_bindings.notifyUI(`Vue controls service needs the data`),connect=(state=!0)=>{let method=state?`on`:`off`;events$3[method](`ControllersChanged`,_receiveControlsData),events$3[method](`AssignedPlayersChanged`,_receivePlayersData),events$3[method](`InputBindingsChanged`,_receiveBindingsData),events$3[method](`RecentDevicesChanged`,_requestRecentDevices)},disconnect=()=>connect(!1),deviceIcon=deviceName=>DEVICE_ICONS[(deviceName||``).slice(0,3)]||DEVICE_ICONS.default;async function _requestRecentDevices(devNames=void 0){devNames||=await Lua_default.extensions.core_input_bindings.getRecentDevices(),!Array.isArray(devNames)||devNames.length===0?devNames=devNamesOrder:isKbm(devNames[0])&&(devNames=[...kbmDevNames,...devNames.filter(devName=>!isKbm(devName))]),lastDeviceOrder.value.splice(0,lastDeviceOrder.value.length,...devNames)}function*getBindingsIter(devFilter=[],useLastDeviceOrder=!1){if(!useLastDeviceOrder||devFilter.length>0)yield*bindings.value;else for(let devName of lastDeviceOrder.value){let binding=bindingsPerDevice.value[devName];binding&&(yield binding)}}let findBindingForAction=(action,devName=void 0,useLastDeviceOrder=!1)=>{let devFilter=devName?Array.isArray(devName)?devName:[devName]:[],bindingsIter=getBindingsIter(devFilter,useLastDeviceOrder);for(let binding of bindingsIter){if(devFilter.length>0&&!devFilter.includes(binding.devname))continue;let found=binding.contents.bindings.find(b=>b.action===action);if(found){let help=getBindingDetails(binding.devname,found.control,action);if(help)return help.devName=binding.devname,help.imagePack=binding.contents.imagePack,help}}},findAllBindingsForAction=(action,devName=void 0,allDevices=!1,useLastDeviceOrder=!1)=>{let res=[],devFilter=devName?Array.isArray(devName)?devName:[devName]:[],bindingsIter=getBindingsIter(devFilter,useLastDeviceOrder);for(let binding of bindingsIter){if(devFilter.length>0&&!devFilter.includes(binding.devname))continue;let matches$1=binding.contents.bindings.filter(b=>b.action===action);if(matches$1.length>0)for(let match of matches$1){let help=getBindingDetails(binding.devname,match.control,action);help&&(!allDevices&&devFilter.length===0&&devFilter.push(binding.devname),help.devName=binding.devname,help.imagePack=binding.contents.imagePack,res.push(help))}}return res},defaultBindingEntry=(action,control)=>({...bindingTemplate.value,action,control}),isAxis=(device,control)=>{let c=controllers.value[device].controls[control];return c&&c.control_type==`axis`},bindingConflicts=(device,control,action)=>bindings.value.find(b=>b.devname==device).contents.bindings.filter(b=>b.control==control).filter(b=>b.action!=action).map(b=>({...b,...getBindingDetails(device,control,b.action),resolved:!1})),captureBinding=(modifiersAllowed=!0)=>{let controlCaptured=!1,eventsRegister={},d=defer(),capturingBinding=!0;function _listener(data){if(!capturingBinding||controlCaptured)return;let devName=data.devName;eventsRegister[devName]||(eventsRegister[devName]={axis:{},key:[null,null]});let eventData=eventsRegister[devName];d.notify(eventsRegister);let valid=!1,key0,key1,key0Parts,key1Parts,genericModifierKeys=[`lalt`,`lcontrol`,`lshift`,`ralt`,`rcontrol`,`rshift`];switch(data.controlType){case`axis`:if(!eventData.axis[data.control])eventData.axis[data.control]={first:data.value,last:data.value,accumulated:0};else{let detectionThreshold=devName.startsWith(`mouse`)?1:.5;eventData.axis[data.control].accumulated+=Math.abs(eventData.axis[data.control].last-data.value)/detectionThreshold,eventData.axis[data.control].last=data.value}valid=eventData.axis[data.control].accumulated>=1;break;case`button`:case`pov`:case`key`:if(eventData.key=[eventData.key.at(-1),data.control],key0=eventData.key[0],key1=eventData.key[1],key0&&key1){let validSet=!1;key0Parts=key0.split(` `),key1Parts=key1.split(` `),key0Parts.length===1&&key1Parts.length===2&&key1Parts[1]===key0Parts[0]&&(eventData.key[1]=key0,key1=key0,data.control=key0,modifiersAllowed||(valid=!1,validSet=!0)),validSet||(valid=key0===key1,!modifiersAllowed&&(key0Parts.length===2||genericModifierKeys.includes(data.control))&&(valid=!1)),data.value===0&&(eventData.key=[null,null])}break;default:console.error(`Unrecognised raw input controlType: `+JSON.stringify(data))}valid&&data.devName.startsWith(`mouse`)&&data.control===`button1`&&(valid=!1),valid&&(controlCaptured=!0,capturingBinding=!1,data.direction=data.controlType===`axis`?Math.sign(eventData.axis[data.control].last-eventData.axis[data.control].first):0,d.resolve(data),_captureHelper.stopListening())}return Lua_default.ActionMap.enableBindingCapturing(!0),Lua_default.setCEFTyping(!0),_captureHelper.stopListening=()=>{Lua_default.ActionMap.enableBindingCapturing(!1),Lua_default.WinInput.setForwardRawEvents(!1),Lua_default.setCEFTyping(!1),events$3.off(`RawInputChanged`,_listener)},events$3.on(`RawInputChanged`,_listener),Lua_default.WinInput.setForwardRawEvents(!0),d.promise},removeBinding=(device,control,action,mockSave)=>{let deviceContents={...bindings.value.find(b=>b.devname==device).contents};deviceContents.bindings=[...deviceContents.bindings];let entryIndex=deviceContents.bindings.findIndex(b=>b.control==control&&b.action==action)||null;if(entryIndex)if(deviceContents.bindings.splice(entryIndex,1),mockSave){let deviceIndex=bindings.value.findIndex(b=>b.devname==device);bindings.value[deviceIndex].contents=deviceContents}else serializeCheck(deviceContents.name),Lua_default.extensions.core_input_bindings.saveBindingsToDisk(deviceContents)},addBinding=(device,bindingData,replace,mockSave)=>{let deviceContents={...bindings.value.find(b=>b.devname==device).contents};if(deviceContents.bindings=[...deviceContents.bindings],replace){let deprecatedIndex=deviceContents.bindings.findIndex(b=>b.control==bindingData.details.control&&b.action==bindingData.details.action);deviceContents[deprecatedIndex]=bindingData}else serializeCheck(deviceContents.name),Lua_default.extensions.core_input_bindings.saveBindingsToDisk(deviceContents)},isFFBBound=()=>{for(let i=0;i{let ffbCapable=()=>Object.values(controllers.value).some(controller=>controller.ffbAxes&&Object.keys(controller.ffbAxes).length>0);return asRef?computed(()=>ffbCapable()):ffbCapable},getIsControllerAvailable=(asRef=!1)=>asRef?isControllerAvailable:isControllerAvailable.value,isWheelFound=vendorId=>{for(let b of bindings.value)if(b.devname.slice(0,3)===`whe`&&b.contents.vidpid.slice(4,8)==vendorId)return!0;return!1};function isFFBEnabled(asRef=!1){let filter=()=>bindings.value.filter(b=>b.devname.slice(0,3)!==`xin`).some(b=>b.contents.bindings.some(binding=>binding.action===`steering`&&binding.isForceEnabled));return asRef?computed(()=>filter()):filter()}function isPidVidFound(desiredVid,desiredPid,asRef=!1){let filter=()=>bindings.value.some(b=>{let vid=desiredVid===void 0?desiredVid:b.contents.vidpid.slice(4,8),pid$1=desiredPid===void 0?desiredPid:b.contents.vidpid.slice(0,4);return vid==desiredVid&&pid$1==desiredPid});return asRef?computed(()=>filter()):filter()}function getBindingDetails(device,control,action){let actionDetails=getActionDetails(action);if(!actionDetails){console.warn(`Action details not found: `,action);return}let deviceBindings=bindings.value.find(b=>b.devname===device).contents.bindings,common={icon:deviceIcon(device),title:actionDetails.title,desc:actionDetails.desc},details=deviceBindings.find(b=>b.control===control&&b.action===action)||defaultBindingEntry(action,control),isBindingAxis=isAxis(device,control);return{...bindingTemplate.value,...details,...common,isAxis:isBindingAxis,action:actionDetails.action,actionName:actionDetails.actionName}}function getActionDetails(action){let actionDetails=actions.value[action];if(actionDetails)return{...actionDetails,action:actionDetails.actionName}}function addNewBinding(bindingData){let{devname,control,action}=bindingData,device=bindings.value.find(b=>b.devname==devname);if(!device){console.warn(`Device not found: `,devname);return}let deviceContents=device.contents;deviceContents.bindings.push({...bindingTemplate.value,...bindingData,control,action}),serializeCheck(deviceContents.name),Lua_default.extensions.core_input_bindings.saveBindingsToDisk(deviceContents)}function updateBinding(bindingData){let{devname,control,action}=bindingData,oldDevname=bindingData.oldDevname||devname,oldControl=bindingData.oldControl||control,device=bindings.value.find(b=>b.devname==oldDevname);if(!device){console.warn(`Device not found: `,oldDevname);return}let deviceContents=device.contents,deprecatedIndex=deviceContents.bindings.findIndex(b=>b.control==oldControl&&b.action==action);if(deprecatedIndex===-1){console.warn(`Binding not found: `,oldDevname,oldControl,action);return}if(devname===oldDevname)delete bindingData.oldDevname,delete bindingData.oldControl,deviceContents.bindings[deprecatedIndex]={...bindingData};else{deviceContents.bindings.splice(deprecatedIndex,1);let newDeviceContents=bindings.value.find(b=>b.devname===devname).contents;newDeviceContents.bindings.push({...bindingData,bindingTemplate:bindingTemplate.value}),serializeCheck(newDeviceContents.name),Lua_default.extensions.core_input_bindings.saveBindingsToDisk(newDeviceContents)}serializeCheck(deviceContents.name),Lua_default.extensions.core_input_bindings.saveBindingsToDisk(deviceContents)}function deleteBindings(bindingsData){let bindingsByDevname=bindingsData.reduce((acc,b)=>(acc[b.devname]=acc[b.devname]||[],acc[b.devname].push(b),acc),{});for(let devname in bindingsByDevname){let device=bindings.value.find(b=>b.devname==devname);if(!device){console.warn(`Device not found: `,devname);continue}let deviceContents=device.contents;bindingsByDevname[devname].forEach(b=>{let index=deviceContents.bindings.findIndex(binding=>binding.control==b.control&&binding.action==b.action);index!==-1&&deviceContents.bindings.splice(index,1)}),serializeCheck(deviceContents.name),Lua_default.extensions.core_input_bindings.saveBindingsToDisk(deviceContents)}}function deleteBinding({devname,control,action}){let device=bindings.value.find(b=>b.devname==devname);if(!device){console.warn(`Device not found: `,devname);return}let deviceContents=device.contents,index=deviceContents.bindings.findIndex(b=>b.control==control&&b.action==action);if(index===-1){console.warn(`Binding not found: Skipping...`,devname,control,action);return}deviceContents.bindings.splice(index,1),serializeCheck(deviceContents.name),Lua_default.extensions.core_input_bindings.saveBindingsToDisk(deviceContents)}function getAllBindingsForAction(action,devName,asRef=!1){let filteredBindings=()=>bindings.value.filter(b=>(!devName||b.devname==devName)&&b.contents.bindings.find(a$1=>a$1.action===action)).flatMap(b=>b.contents.bindings.filter(x=>x.action===action).map(x=>({...x,...getBindingDetails(b.devname,x.control,x.action),devname:b.devname,action,actionName:action})));return asRef?computed(()=>filteredBindings()):filteredBindings()}let _captureHelper={devName:null,stopListening:null};function _updateDeviceNotes(){Object.values(bindings.value).forEach(({contents:bindingContents})=>{for(let id in controllers.value){let controller=controllers.value[id];if(bindingContents.vidpid==controller.vidpid){controller.notes=bindingContents.notes;break}}})}let lastBindingsData=null;function _processBindingsData(data){let newBindingsData=JSON.stringify(data);if(lastBindingsData===newBindingsData)return;if(lastBindingsData=newBindingsData,Array.isArray(data.bindings)||(data.bindings=[]),data.bindings.forEach(device=>{Array.isArray(device.contents.bindings)||(device.contents.bindings=Object.values(device.contents.bindings))}),bindingTemplate.value=data.bindingTemplate,bindings.value=data.bindings,!data.actionCategories||!data.bindingTemplate||data.bindings.length===0){logger_default.debug(`Did not receive bindings data. Timing issue?`);return}bindings.value.sort((a$1,b)=>deviceSorter(a$1.devname,b.devname)),devNamesOrder.splice(0),kbmDevNames.splice(0);for(let binding of data.bindings){let devName=binding.devname;devNamesOrder.includes(devName)||devNamesOrder.push(devName),isKbm(devName)&&kbmDevNames.push(devName),binding.icon=deviceIcon(devName)}_requestRecentDevices();let acts={};for(let act in data.actions)acts[act]={actionName:act,...data.actions[act]};for(let cat in actions.value=acts,categories.value=data.actionCategories,categories.value)typeof categories.value[cat]==`object`&&(categories.value[cat].actions=[]);for(let act in actions.value){let obj={key:act,...actions.value[act]};actions.value[act].cat in categories.value||(categories.value[actions.value[act].cat]={order:99,icon:`symbol_exclamation`,title:`UNDEFINED CATEGORY: `+actions.value[act].cat,desc:``,actions:[]}),categories.value[actions.value[act].cat].actions.push(obj)}for(let x in categoriesList.value=[],Object.entries(categories.value).forEach(([catName,cat])=>categoriesList.value.push({key:catName,...cat})),categoriesList.value)for(let y in categoriesList.value[x].actions)for(let z in categoriesList.value[x].actions[y].titleTranslated=$translate.instant(categoriesList.value[x].actions[y].title),categoriesList.value[x].actions[y].descTranslated=$translate.instant(categoriesList.value[x].actions[y].desc),categoriesList.value[x].actions[y].tags)categoriesList.value[x].actions[y].tagsTranslated||(categoriesList.value[x].actions[y].tagsTranslated=[]),categoriesList.value[x].actions[y].tagsTranslated[z]=$translate.instant(categoriesList.value[x].actions[y].tags[z]);_updateDeviceNotes()}function makeViewerObj({deviceKey,device,action,uiEvent,imagePack,controller=!1,actionVariants=!1,useLastDevice=!1}){let viewerObj,multiDevice=!1;if(device&&Array.isArray(device)&&device.length===0&&(device=void 0),Array.isArray(device)&&(device.length===0?device=void 0:device.length===1?device=device[0]:multiDevice=!0),!device&&controller&&(device=lastControllers.value,device.length===0?device=void 0:device.length===1?device=device[0]:multiDevice=!0),uiEvent&&(action=ACTIONS_BY_UI_EVENT[uiEvent]),action?actionVariants?(viewerObj=_buildViewerObjVariants(findAllBindingsForAction(action,device,!1,useLastDevice)),actionVariants=!!viewerObj?.variants,actionVariants&&viewerObj.variants.sort((a$1,b)=>a$1.isInverted-b.isInverted)):viewerObj=findBindingForAction(action,device,useLastDevice):actionVariants=!1,deviceKey){let devName=viewerObj?.devName||(multiDevice?device[0]:device);viewerObj={icon:deviceIcon(devName),control:deviceKey,devName,imagePack:viewerObj?.imagePack||imagePack}}return viewerObj&&(_parseViewerObj(viewerObj,imagePack,actionVariants),viewerObj.variants&&viewerObj.variants.forEach(obj=>_parseViewerObj(obj,imagePack,actionVariants,device))),viewerObj}function _buildViewerObjVariants(viewerObjs){let len=viewerObjs?.length||0;if(len!==0)return len===1?viewerObjs[0]:{...viewerObjs[0],variants:viewerObjs}}let rgxCombo=/modifier(?\d+)[ -]+|[ -]*(?.+)/gi;function _parseViewerObj(viewerObj,imagePack=void 0,actionVariants=!1,devNames=void 0){let devName=viewerObj.devName;if(imagePack=viewerObj.imagePack||imagePack,!imagePack){let binding=bindings.value?.find(b=>b.devname===devName);binding?.contents?.imagePack&&(imagePack=binding.contents.imagePack),!imagePack&&devName&&(imagePack=CONTROL_ICON_KEYS.find(key=>devName.startsWith(key))),viewerObj.imagePack=imagePack}if(viewerObj.control.startsWith(`modifier`)){let matches$1=[...viewerObj.control.matchAll(rgxCombo)].map(m=>m.groups);if(matches$1.length>0){viewerObj.multiControls=[];for(let match of matches$1)if(match.mod){let modName=`customModifier`+match.mod,mod=actionVariants?_buildViewerObjVariants(findAllBindingsForAction(modName,devName,!1,!1)):findBindingForAction(modName,devName);mod||=actionVariants?_buildViewerObjVariants(findAllBindingsForAction(modName,devNames,!1,!1)):findBindingForAction(modName,devNames),mod&&viewerObj.multiControls.push(mod)}else viewerObj.multiControls.push({devName,control:match.key,icon:viewerObj.icon,imagePack})}}_addCustomInfo(viewerObj),viewerObj.multiControls&&viewerObj.multiControls.forEach(_addCustomInfo)}function _addCustomInfo(viewerObj){let devOverrides=getViewerOverrides(viewerObj.devName,viewerObj.imagePack);viewerObj.family=devOverrides?.family;let ownIcon=devOverrides?.icons[viewerObj.control];viewerObj.special=!!ownIcon,viewerObj.ownGroups=devOverrides?.groups,viewerObj.special?viewerObj.ownIcon=ownIcon:viewerObj.control=controlLabel(viewerObj.control)}return connect(),_getBindingsData(),{categories:computed(()=>categories.value),categoriesList:computed(()=>categoriesList.value),controllers:computed(()=>controllers.value),players:computed(()=>players.value),bindingTemplate:computed(()=>bindingTemplate.value),lastDevice:lastDeviceSimple,lastDevices:lastDeviceOrder,lastControllers,lastControllersSignature,isControllerAvailable,isControllerUsed,showIfController:isControllerUsed,focusIfController:isControllerAvailable,addNewBinding,connect,deleteBinding,deleteBindings,disconnect,deviceIcon,findBindingForAction,findAllBindingsForAction,getActionDetails,getBindingDetails,getAllBindingsForAction,defaultBindingEntry,isAxis,bindingConflicts,captureBinding,removeBinding,addBinding,isFFBBound,isFFBEnabled,isFFBCapable,isGamepadAvailable:getIsControllerAvailable,isWheelFound,isPidVidFound,makeViewerObj,updateBinding}}),useStore=()=>store||=makeStore(),controls_default=useStore,direction=`right`,focusClass=`focus-visible`,isController$1={value:!1},now=()=>new Date().getTime(),inited=!1,gamepadInited=!1,elms$3=[];function setFocus(elm,enable=!0){if(enable){if(elm.classList.add(focusClass),elm===document.activeElement)return}else if(elm.classList.remove(focusClass),elm!==document.activeElement)return;try{enable&&focusOnElement(elm)}catch{}}function setFocusExternal(elm,enable=!0,attemptScroll=!0){return elm?(!gamepadInited&&gamepadInit(),enable&&!isController$1.value?(attemptScroll&&isOccluded(elm,!0)&&scrollFix({dom:elm,rect:elm.getBoundingClientRect()},`down`),!1):(setFocus(elm,enable),!0)):!1}function ensureFocus(elm,onNextTick=!0){elm&&(!gamepadInited&&gamepadInit(),isController$1.value&&document.activeElement===elm&&!elm.classList.contains(focusClass)&&(onNextTick?nextTick(()=>elm&&setFocus(elm)):setFocus(elm)))}function gamepadInit(){gamepadInited||(gamepadInited=!0,isController$1=storeToRefs(controls_default()).focusIfController)}function init$1(){inited||(inited=!0,gamepadInit(),watch(isController$1,val=>{let active=document.activeElement;if(isNavigable$1(active)){let focused$1=active.classList.contains(focusClass);val&&!focused$1?setFocus(active,!0):!val&&focused$1&&setFocus(active,!1);return}if(val){if(priorityFocus())return;navigate(collectRects(direction),direction)&&window.requestAnimationFrame(()=>setFocus(document.activeElement,!0))}}))}function priorityFocus(){collectRects(direction);for(let{elm}of elms$3)if(isNavigable$1(elm))return setFocus(elm,!0),!0;return!1}function wantsFocus(elm,priority){inited||init$1();let dat=elms$3.find(itm=>itm.element===elm)||{elm,time:now()},isNew=!(`priority`in dat);if(typeof priority!=`number`||isNaN(priority)){if(!isNew){let idx=elms$3.findIndex(itm=>itm.elm===elm);idx>-1&&elms$3.splice(idx,1)}return}dat.priority=priority,isNew&&elms$3.push(dat),elms$3.sort((a$1,b)=>b.priority-a$1.priority||b.time-a$1.time),collectRects(direction,elm.parentNode),isNew&&isController$1.value&&!isNavigable$1(document.activeElement)&&priorityFocus()}function unwantsFocus(elm){let idx=elms$3.findIndex(itm=>itm.elm===elm);idx!==-1&&(elms$3.splice(idx,1),isController$1.value&&!isNavigable$1(document.activeElement)&&priorityFocus())}function initFocusVisible(){let raf=window.requestAnimationFrame,curFocused=null,holdFocus=!1;function notify(type,target,relatedTarget){let evt=new CustomEvent(`uinav-`+type,{bubbles:!0,cancelable:!0,detail:{target,relatedTarget}});document.dispatchEvent(evt)}function procFocus(target,relatedTarget){if(!(target&&target===curFocused)&&(relatedTarget===target&&(relatedTarget=void 0),relatedTarget&&doBlur(relatedTarget),curFocused&&=((!relatedTarget||relatedTarget!==curFocused)&&(relatedTarget=curFocused),doBlur(curFocused),null),target))try{if(target.disabled)return;if(`tabIndex`in target){if(typeof target.tabIndex==`string`&&target.tabIndex===`-1`||typeof target.tabIndex==`number`&&target.tabIndex===-1||target.tabIndex===``)return}else if(`contentEditable`in target){if(typeof target.contentEditable==`string`&&target.contentEditable!==`true`||typeof target.contentEditable==`boolean`&&!target.contentEditable)return}else return;let style=window.getComputedStyle(target);if(style.display===`none`||style.visibility===`hidden`||style.pointerEvents===`none`)return;if(isController$1.value&&target.classList.add(focusClass),curFocused=target,focusRegistry.includes(target)||focusRegistry.push(target),document.activeElement!==curFocused){holdFocus=!0;let holdFocusCounter=0;raf(function check(){!curFocused||holdFocusCounter>10||document.activeElement===curFocused?(holdFocus=!1,!curFocused||target!==curFocused?doBlur(target):notify(`focus`,curFocused,relatedTarget)):(holdFocusCounter++,curFocused.focus(),raf(check))})}else notify(`focus`,target,relatedTarget)}catch{}}function doBlur(target){if(target&&!(holdFocus&&target===curFocused))try{target.classList.remove(focusClass),target===curFocused&&(curFocused=null);let idx=focusRegistry.indexOf(target);idx!==-1&&(focusRegistry.splice(idx,1),notify(`blur`,target))}catch{}}document.addEventListener(`focusin`,evt=>procFocus(evt.target,evt.relatedTarget),!0),document.addEventListener(`focusout`,evt=>doBlur(evt.target),!0);let focusRegistry=[],originalFocus=HTMLElement.prototype.focus.__original__||HTMLElement.prototype.focus,originalBlur=HTMLElement.prototype.blur.__original__||HTMLElement.prototype.blur;HTMLElement.prototype.focus=function(...args){let target=this,prevFocused=document.activeElement;prevFocused.classList.contains(focusClass)||(focusRegistry.length>0?focusRegistry.forEach(elm=>elm!==target&&elm.blur()):document.querySelectorAll(`.`+focusClass).forEach(elm=>elm!==target&&doBlur(elm))),originalFocus.apply(target,args),procFocus(target,prevFocused)},HTMLElement.prototype.blur=function(...args){doBlur(this),originalBlur.apply(this,args)},HTMLElement.prototype.focus.__original__=originalFocus,HTMLElement.prototype.blur.__original__=originalBlur}var EVENT_CALLS=Object.entries({focus:[`uinav-focus`,`focus`,`focusin`,`click`],hide:[`mouseenter`],show:[`uinav-blur`,`blur`,`focusout`,`mouseleave`]}).reduce((res,[name,events$3])=>(events$3.forEach(event=>res[event]=name),res),{}),ID$1=`__bngFocusCapture`,elms$2={},isController;function setupController(){isController||(isController=storeToRefs(controls_default()).isControllerUsed,watch(isController,val=>{for(let data of Object.values(elms$2))val?data.show():data.hide()}))}function getClosestNavigable(elm){let target=collectRects(`down`,elm).down[0]?.dom;return target&&isNavigable$1(target)?target:null}function update$3(data,value,firstTime=!1){if(typeof value==`function`?(data.handler=()=>{let elm=value(data.parent);return elm?.$el||elm},delete data.disabled):typeof value==`boolean`&&!value?data.disabled=!0:delete data.disabled,data.disabled){if(data.hide(),!firstTime)for(let event in data.capture.remove(),EVENT_CALLS)data.parent.removeEventListener(event,data[EVENT_CALLS[event]])}else for(let event in data.parent.appendChild(data.capture),data.show(),EVENT_CALLS)data.parent.addEventListener(event,data[EVENT_CALLS[event]])}var BngFocusCapture_default={mounted(elm,{arg,value}){setupController();let id=uniqueId(ID$1),parent=elm,capture=document.createElement(`div`),data={id,shown:!0,parent,capture,handler:()=>getClosestNavigable(data.parent)};elms$2[id]=data,parent[ID$1]=id,capture.className=`bng-focus-capture`,capture.style.setProperty(`position`,`absolute`,`important`),capture.style.setProperty(`display`,`block`,`important`),capture.style.setProperty(`top`,`0%`,`important`),capture.style.setProperty(`left`,`0%`,`important`),capture.style.setProperty(`width`,`100%`,`important`),capture.style.setProperty(`height`,`100%`,`important`),capture.style.setProperty(`z-index`,arg&&/^\d+$/.test(arg)?arg:`1000`,`important`),capture.style.setProperty(`pointer-events`,`all`,`important`),capture.setAttribute(`bng-nav-item`,``),capture.setAttribute(`tabindex`,`0`),data.focus=()=>{if(data.hide(),!isController.value)return;let active=document.activeElement;if(!(active!==data.capture&&data.parent.contains(active))&&data.handler){let elm$1=data.handler(data.parent);elm$1&&nextTick(()=>setFocusExternal(elm$1))}},data.hide=()=>{data.shown&&(data.shown=!1,capture.style.setProperty(`pointer-events`,`none`,`important`))},data.show=evt=>{if(data.shown||(data.shown=!0,data.disabled||!isController.value))return;let active=document.activeElement;if(data.parent.contains(active))return;let target=evt?.relatedTarget||evt?.target||active;data.parent.contains(target)||capture.style.setProperty(`pointer-events`,`all`,`important`)},update$3(data,value,!0)},updated(elm,{arg,value}){let id=elm[ID$1];if(!id)return;let data=elms$2[id];data&&update$3(data,value)},unmounted(elm){let id=elm[ID$1];if(!id)return;delete elm[ID$1];let data=elms$2[id];if(data){for(let event in data.capture.remove(),EVENT_CALLS)data.parent.removeEventListener(event,data[EVENT_CALLS[event]]);delete elms$2[id]}}},BngFocusIf_default=(el,{value})=>value&&nextTick(()=>{let shouldFocus=typeof value==`object`?value.value:value,findNavItem=typeof value==`object`?value.findNavItem:!1;if(!el||!shouldFocus)return;let targetEl=el;if(findNavItem){let navItems=el.querySelectorAll(`[is-bng-panel], [bng-nav-item], [ng-click], [href], [bng-all-clicks], [bng-all-clicks-no-nav], [ui-sref], input, textarea, button, md-option, md-slider, md-select, md-checkbox`);navItems&&navItems.length>0&&(targetEl=navItems[0])}targetEl.focus();let blur$1=()=>{targetEl.classList.remove(`focus-visible`),targetEl.removeEventListener(`blur`,blur$1)};targetEl.addEventListener(`blur`,blur$1),targetEl.classList.add(`focus-visible`)}),elems=new WeakMap,curHorizontal=0,curVertical=0;function updateGE(horizontal=0,vertical=0){curHorizontal=horizontal,curVertical=vertical,bngApi.engineLua(`scenetree.OnlyGui:setFrustumCameraCenterOffset(Point2F(${horizontal}, ${vertical}))`)}var moveSpeed=1,smoothingUpdate;function updateGEsmooth(horizontal=0,vertical=0){if(smoothingUpdate){smoothingUpdate(horizontal,vertical);return}let dirH=1,dirV=1;function setDir(){dirH=horizontal>=curHorizontal?1:-1,dirV=vertical>=curVertical?1:-1}setDir(),smoothingUpdate=(h$1=0,v=0)=>{horizontal=h$1,vertical=v,setDir()},window.requestAnimationFrame(function(ms){let speed=moveSpeed/1e3,movH=curHorizontal,movV=curVertical,lastTime=ms,smoother=0;window.requestAnimationFrame(function step(ms$1){if(curHorizontal===horizontal&&curVertical===vertical){smoothingUpdate=null;return}smoother+=(ms$1-lastTime-smoother)*.02,lastTime=ms$1;let moveDelta=smoother*speed;movH+=moveDelta*dirH,movV+=moveDelta*dirV,(dirH>0&&movH>horizontal||dirH<0&&movH0&&movV>vertical||dirV<0&&movV{let updateDebounce=debounce(updateFrustum,50),updateWrapper=()=>updateDebounce(),resizeObserver=new ResizeObserver(updateWrapper);resizeObserver.observe(el),elems.set(el,{updateFrustum:updateDebounce,destroy:()=>{resizeObserver.disconnect(),window.removeEventListener(`resize`,updateWrapper),elems.delete(el),updateDebounce(0,0)}}),window.addEventListener(`resize`,updateWrapper);let curDirection=binding.arg||`left`,curSmooth=binding.modifiers.smooth,curState=binding.value===void 0?!0:!!binding.value;function updateFrustum(direction$1,enabled,smooth){direction$1||=curDirection,[`left`,`right`,`up`,`down`].includes(direction$1)?curDirection=direction$1:(console.error(`Frustum mover only supports left/right/up/down directions`),enabled=!1),typeof enabled!=`boolean`&&(enabled=curState),curState=enabled,typeof smooth!=`boolean`&&(smooth=curSmooth),curSmooth=smooth;let updater=smooth?updateGEsmooth:updateGE;if(!enabled){updater();return}let side=direction$1===`left`||direction$1===`right`?`width`:`height`,screenSize=window.screen[side],movePower=el.getBoundingClientRect()[side]/screenSize*power;movePower<.001?movePower=0:(direction$1===`left`||direction$1===`down`)&&(movePower=-movePower),updater(direction$1===`left`||direction$1===`right`?movePower:0,direction$1===`up`||direction$1===`down`?movePower:0)}},updated:(el,binding)=>{let itm=elems.get(el);itm&&itm.updateFrustum(binding.arg,!!binding.value,!!binding.modifiers.smooth)},unmounted:(el,binding)=>{let itm=elems.get(el);itm&&itm.destroy()}},highlighter=[``,``],rgxSanitize=str=>str.replace(/[\\[]\?:.\*\+\-]/g,`\\$1`),BngHighlighter_default=(el,binding,vnode,prevVnode)=>{if(vnode.children.length!==1||vnode.children[0].type.toString()!==`Symbol(v-txt)`){el.__highlightwarned||(el.__highlightwarned=!0,console.warn(`Only a single inner text v-node supported`,el));return}let res=vnode.children[0].children.replace(//g,`>`),highlight=binding.value;if(highlight){let rgx;if(highlight instanceof RegExp)highlight.test(res)&&(rgx=highlight);else{let searchCase=str=>binding.modifiers.case?str:str.toLowerCase(),searchSource=searchCase(res),checkString=str=>searchSource.indexOf(str)>-1,buildRegexp=str=>RegExp(`(${str})`,`gm`+(binding.modifiers.case?``:`i`));if(typeof highlight==`object`&&Array.isArray(highlight)){let found=[];for(let str of highlight)str&&(str=searchCase(String(str)),checkString(str)&&found.push(str));found.length>0&&(rgx=buildRegexp(found.map(str=>rgxSanitize(str)).join(`|`)))}else{let str=searchCase(String(highlight));checkString(str)&&(rgx=buildRegexp(rgxSanitize(str)))}}rgx&&(res=res.replace(rgx,`${highlighter[0]}$1${highlighter[1]}`))}el.innerHTML!==res&&(el.innerHTML=res)},ExecQueue=class{resolution={rejectThis:`rejectThis`,rejectOthers:`rejectOthers`,resolveThis:`resolveThis`,resolveOthers:`resolveOthers`,replaceWithReject:`replaceWithReject`,replaceWithResolve:`replaceWithResolve`,merge:`merge`};_queue=[];_processing=!1;_tick=0;_tickFunc=nextTick;_runningCount=0;_concurrency=1;constructor(tick=0,concurrency=1){this.tick=tick,this.concurrency=concurrency}get tick(){return this._tick}set tick(val){typeof val!=`number`&&(val=0),this._tick=val,this._tickFunc=val===0?func=>nextTick(func.bind(this)):func=>setTimeout(func.bind(this),this._tick)}get concurrency(){return this._concurrency}set concurrency(val){(typeof val!=`number`||val<1)&&(val=1),this._concurrency=val}shuffle(){this._shuffle=!0}async process(){if(!(this._processing||this._queue.length===0))for(this._processing=!0,this._shuffle&&=(this._queue=this._queue.sort(()=>Math.random()-.5),!1);this._runningCount0;){let item=this._queue.shift();if(!item)break;item.running=!0,this._runningCount++,this._processItem(item)}}async _processItem(item){try{let result=await item.func(...item.args);item.resolves?.forEach(resolve$1=>resolve$1?.(result))}catch(err){item.rejects.length>0?item.rejects?.forEach(reject=>reject?.(err)):console.error(err)}finally{this._runningCount--,this._tickFunc(()=>{this._processing=!1,this.process()})}}enqueue(name,func,args=[],conflicts={},resolve$1=null,reject=null){if(typeof conflicts==`object`&&Object.keys(conflicts).length>0)for(let i=this._queue.length-1;i>=0;i--){let item=this._queue[i];if(item.name in conflicts)switch(conflicts[item.name]){case this.resolution.merge:resolve$1&&item.resolves.push(resolve$1),reject&&item.rejects.push(reject);return;default:case this.resolution.rejectThis:reject?.(Error(`Function ${item.name} is rejected due to conflict`));return;case this.resolution.resolveThis:resolve$1?.();return;case this.resolution.rejectOthers:item.running||(item.rejects?.forEach(reject$1=>reject$1?.(Error(`Function ${item.name} is rejected due to conflict`))),this._queue.splice(i,1));break;case this.resolution.resolveOthers:case this.resolution.replaceWithResolve:item.running||(item.resolves?.forEach(resolve$2=>resolve$2?.()),this._queue.splice(i,1));break;case this.resolution.replaceWithReject:item.rejects?.forEach(reject$1=>reject$1?.(Error(`Function ${item.name} is replaced`))),this._queue.splice(i,1);break}}this._queue.push({name,func,args,resolves:[resolve$1],rejects:[reject]}),this._processing||(this._processing=!0,this._tickFunc(()=>{this._processing=!1,this.process()}))}promise(name,func,args=[],conflicts={}){return new Promise((resolve$1,reject)=>this.enqueue(name,func,args,conflicts,resolve$1,reject))}wrap(name,func,conflicts={}){return async(...args)=>await this.promise(name,func,args,conflicts)}},MAX_SIZE=500,OVERSIZE_LIMIT=100,CONCURRENCY_LIMIT=20,QUEUE_INTERVAL$1=0,OBS_ID=`__bngLazyImage`,cache=new Map,queue=new ExecQueue(QUEUE_INTERVAL$1,CONCURRENCY_LIMIT),observer$1=new IntersectionObserver(entries=>{for(let entry of entries)if(entry.isIntersecting){observer$1.unobserve(entry.target);let data=entry.target[OBS_ID];data.observed&&(data.observed=!1,queue.shuffle(),process(entry.target,data))}}),loadImage=url=>new Promise((resolve$1,reject)=>{let img=new Image;img.onload=async()=>{try{if(cache.sizeMAX_SIZE||img.height>MAX_SIZE)){let ratio=img.width/img.height,width$1,height$1;img.width>img.height?(width$1=MAX_SIZE,height$1=MAX_SIZE/ratio):(height$1=MAX_SIZE,width$1=MAX_SIZE*ratio);let cvs=new OffscreenCanvas(width$1,height$1);cvs.getContext(`2d`).drawImage(img,0,0,width$1,height$1);let bmp=await createImageBitmap(cvs);cache.set(img.src,{url,bmp})}}catch(err){reject(err)}resolve$1({url})},img.onerror=()=>reject(Error(`Failed to load image`)),img.src=url});function process(el,data){let{url,callback}=data,apply$1=imgData=>callback(el,imgData.url,imgData.bmp);if(cache.has(url)){apply$1(cache.get(url));return}apply$1(emptyImage),queue.enqueue(url,loadImage,[url],{url:queue.resolution.merge},data$1=>{apply$1(data$1)},err=>{logger_default.error(err),apply$1(url)})}function update$2(el,{arg,value}){let data={url:void 0,target:`src`,callback:void 0};if(typeof value==`string`)data.url=value;else if(typeof value==`object`&&!Array.isArray(value)&&value.url){if(data.url=value.url,data.target=value.target,data.callback=typeof value.callback==`function`?value.callback:void 0,!data.url||!data.target&&!data.callback)return}else return;if(el[OBS_ID]){let old=el[OBS_ID];if(old.observed&&observer$1.unobserve(el),old.url===data.url&&old.target===data.target&&old.callback===data.callback)return}el[OBS_ID]=data,arg===`observe`?(data.observed=!0,observer$1.observe(el)):process(el,data)}var BngLazyImage_default={mounted:update$2,updated:update$2,unmounted(el){el[OBS_ID]&&(el[OBS_ID].observed&&observer$1.unobserve(el),delete el[OBS_ID])}},elms$1=new Map,observer=new ResizeObserver(observed$1);function observed$1(entries){for(let entry of entries)elms$1.has(entry.target)?update$1(entry.target):observer.unobserve(entry.target)}function update$1(elm,data=void 0){if(data||=elms$1.get(elm),data)if(isVisibleFast(elm)){let screen$1={width:window.innerWidth,height:window.innerHeight,scrollX:window.scrollX,scrollY:window.scrollY},rect=elm.getBoundingClientRect(),metrics={x:rect.left+screen$1.scrollX,y:rect.top+screen$1.scrollY,width:rect.width,height:rect.height};data.set(data.id,metrics.x/screen$1.width,metrics.y/screen$1.height,metrics.width/screen$1.width,metrics.height/screen$1.height)}else data.reset(data.id)}var UINAV_PROP=`__BngOnUiNav`,_handlerToElement=handler$1=>{let element;switch(typeof handler$1){case`string`:element=document.querySelectorAll(handler$1)[0];break;case`object`:element=handler$1;break}return element instanceof HTMLElement&&element},_generateSignature=(vnode,eventNames,modifiers)=>`${UINAV_PROP}[${vnode.ctx.uid}]:`+(typeof eventNames==`string`?eventNames.split(`,`):eventNames).sort().join(`,`)+[``,...Object.keys(modifiers)].sort().join(`.`),_normalizedEvents=eventNames=>eventNames===`*`?[]:eventNames.split(`,`),_getDirData=(element,signature)=>element[UINAV_PROP]?.find(dir=>dir.signature===signature);function setup$2(data,element,vnode){if(data.modifiers.asMouse){if(data.eventNames.find(name=>!isOnOffEvent(name))){window.BNG_Logger&&window.BNG_Logger.error(`UINav directive asMouse modifier is only supported for on/off type events`,element);return}setupAsMouse(data,vnode)}typeof data.handler==`function`&&(applyUiNav(data,element),applyTracker(data,element))}function setupAsMouse(data,vnode){let handlerElement=_handlerToElement(data.handler);handlerElement&&(vnode={el:handlerElement});let eventFirer$1=vnode.ctx?.exposed?.fireEvent||eventDispatcherForElement(vnode.el),checkElementDisabled=vnode.ctx?.exposed?.getDisabledState||(()=>vnode.el.hasAttribute(`disabled`));delete data.modifiers.down,delete data.modifiers.up,data.mousedownActive=!1,data.handler=({detail})=>{if(checkElementDisabled())return;let fromControllerMarker={fromController:detail};return detail.value?(eventFirer$1(`mousedown`,fromControllerMarker),data.mousedownActive=!0):(eventFirer$1(`mouseup`,fromControllerMarker),data.mousedownActive&&(data.mousedownActive=!1,eventFirer$1(`click`,fromControllerMarker))),!!data.modifiers.bubble}}function applyTracker(data,element){let uiNavTracker=useUINavTracker();data.modifiers.focusRequired?(element.addEventListener(`focusin`,evt=>{let prevDirs=evt.relatedTarget?.[UINAV_PROP];if(prevDirs)for(let dir of prevDirs)dir.modifiers.focusRequired&&(dir.tracked.forEach(name=>uiNavTracker.removeEvent(name,dir.signature,evt.relatedTarget)),dir.tracked=[]);let cur=_getDirData(element,data.signature);cur&&(cur.tracked.lengthuiNavTracker.updateEvent(name,cur.signature,element,{active:cur.modifiers.active,nogroup:cur.modifiers.nogroup})),cur.tracked=[...cur.eventNames]))}),element.addEventListener(`focusout`,evt=>{let cur=_getDirData(element,data.signature);if(!cur||cur.tracked.length>0)return;let nextDirs=evt.relatedTarget?.[UINAV_PROP];(!nextDirs||!nextDirs.some(directive=>directive.modifiers.focusRequired))&&(cur.tracked.forEach(name=>uiNavTracker.removeEvent(name,cur.signature,element)),cur.tracked=[])})):(data.eventNames.forEach(name=>uiNavTracker.updateEvent(name,data.signature,element,{active:data.modifiers.active,nogroup:data.modifiers.nogroup})),data.tracked=[...data.eventNames])}function applyUiNav(data,element){let valueChecker;data.modifiers.down?valueChecker=checkOn:data.modifiers.up?valueChecker=0:!data.modifiers.asMouse&&!data.eventNames.find(name=>!isOnOffEvent(name))&&(valueChecker=checkOn),data.uiNavHandler=handlers_default.add(element,{name:name=>data.eventNames.includes(name),value:valueChecker,modified:data.modifiers.modified||!1,focusRequired:data.modifiers.focusRequired?element:void 0},data.handler),element.setAttribute(UI_EVENT_ATTR,``)}function mounted$1(element,{arg:eventNames,value:handler$1,modifiers},vnode){modifiers||={};let storage=element[UINAV_PROP]||(element[UINAV_PROP]=[]),signature=_generateSignature(vnode,eventNames,modifiers),data=storage.find(dir=>dir.signature===signature);data?window.BNG_Logger&&window.BNG_Logger.error(`Conflicting vBngOnUiNav directive on element`,element):(data={signature,eventNames:_normalizedEvents(eventNames),modifiers,handler:handler$1,uiNavHandler:null,mousedownActive:!1,tracked:[]},storage.push(data)),setup$2(data,element,vnode)}function updated$1(element,{arg:eventNames,value:handler$1,modifiers},vnode){modifiers||={};let data=_getDirData(element,_generateSignature(vnode,eventNames,modifiers));if(!data)return;typeof data.uiNavHandler==`function`&&handlers_default.remove(element,data.uiNavHandler);let normalizedEvents=_normalizedEvents(eventNames),oldEvents=data.tracked.filter(name=>!normalizedEvents.includes(name));if(oldEvents.length>0){let uiNavTracker=useUINavTracker();oldEvents.forEach(name=>uiNavTracker.removeEvent(name,data.signature,element)),data.tracked=data.tracked.filter(name=>normalizedEvents.includes(name))}data.eventNames=normalizedEvents,data.modifiers=modifiers,data.handler=handler$1,data.uiNavHandler=null,setup$2(data,element,vnode)}function dispose$1(element){let storage=element[UINAV_PROP];if(!storage)return;let uiNavTracker=useUINavTracker();storage.forEach(directive=>{directive.tracked.length>0&&directive.tracked.forEach(name=>uiNavTracker.removeEvent(name,directive.signature,element)),directive.uiNavHandler&&handlers_default.remove(element,directive.uiNavHandler)}),element.removeAttribute(UI_EVENT_ATTR),delete element[UINAV_PROP]}var BngOnUiNav_default={mounted:mounted$1,updated:updated$1,beforeUnmount:dispose$1},DIRECTIONS={horizontal:{[UI_EVENTS.focus_l]:-1,[UI_EVENTS.focus_r]:1},vertical:{[UI_EVENTS.focus_d]:-1,[UI_EVENTS.focus_u]:1}},HOLD_DELAY=400,REPEAT_INTERVAL=100,ELEMENT_FLAG=`__BNG_ONUINAVFOCUS`,BngOnUiNavFocus_default={mounted:(element,binding,vnode)=>{if(!binding.value)return;let opts={direction:binding.arg||`horizontal`,repeat:!!binding.modifiers.repeat,holdDelay:HOLD_DELAY,repeatInterval:REPEAT_INTERVAL,min:-1/0,max:1/0,step:1,value:null,callback:null,...typeof binding.value==`object`?binding.value:typeof binding.value==`function`?{callback:binding.value}:{}};!opts.events&&(opts.events=DIRECTIONS[opts.direction]);function process$1(evt){let detail=evt.fromController||evt.detail;if(!detail||!(detail.name in opts.events))return;let dir=opts.events[detail.name],val;if(typeof opts.value==`function`){let cur=opts.value(),res=cur+(typeof opts.step==`function`?opts.step():opts.step)*dir;dir<0&&res0&&res>opts.max&&(res=opts.max);let precision=10**(opts.step+`.`).split(/[.,]/)[1].length;res=precision>0?Math.round(res*precision)/precision:Math.round(res),cur===res?dir=0:val=res}dir&&opts.callback&&opts.callback(dir,val)}let dirUINav={arg:Object.keys(opts.events).join(`,`),modifiers:{focusRequired:!0,asMouse:!0}},dirClick={value:{clickCallback:process$1,holdCallback:opts.repeat?process$1:void 0,holdDelay:HOLD_DELAY,repeatInterval:REPEAT_INTERVAL}};BngOnUiNav_default.mounted(element,dirUINav,vnode),BngClick_default.mounted(element,dirClick,vnode),element[ELEMENT_FLAG]=!0},beforeUnmount:element=>{element[ELEMENT_FLAG]&&(BngClick_default.beforeUnmount(element),BngOnUiNav_default.beforeUnmount(element))}},DEFAULT_OPTS={intiallyOpen:!1,navEventToOpen:UI_EVENTS.ok,navEventToClose:UI_EVENTS.back},min=Math.min,max=Math.max,round$1=Math.round,floor=Math.floor,createCoords=v=>({x:v,y:v}),oppositeSideMap={left:`right`,right:`left`,bottom:`top`,top:`bottom`},oppositeAlignmentMap={start:`end`,end:`start`};function clamp$1(start,value,end){return max(start,min(value,end))}function evaluate(value,param){return typeof value==`function`?value(param):value}function getSide(placement){return placement.split(`-`)[0]}function getAlignment(placement){return placement.split(`-`)[1]}function getOppositeAxis(axis){return axis===`x`?`y`:`x`}function getAxisLength(axis){return axis===`y`?`height`:`width`}var yAxisSides=new Set([`top`,`bottom`]);function getSideAxis(placement){return yAxisSides.has(getSide(placement))?`y`:`x`}function getAlignmentAxis(placement){return getOppositeAxis(getSideAxis(placement))}function getAlignmentSides(placement,rects,rtl){rtl===void 0&&(rtl=!1);let alignment=getAlignment(placement),alignmentAxis=getAlignmentAxis(placement),length=getAxisLength(alignmentAxis),mainAlignmentSide=alignmentAxis===`x`?alignment===(rtl?`end`:`start`)?`right`:`left`:alignment===`start`?`bottom`:`top`;return rects.reference[length]>rects.floating[length]&&(mainAlignmentSide=getOppositePlacement(mainAlignmentSide)),[mainAlignmentSide,getOppositePlacement(mainAlignmentSide)]}function getExpandedPlacements(placement){let oppositePlacement=getOppositePlacement(placement);return[getOppositeAlignmentPlacement(placement),oppositePlacement,getOppositeAlignmentPlacement(oppositePlacement)]}function getOppositeAlignmentPlacement(placement){return placement.replace(/start|end/g,alignment=>oppositeAlignmentMap[alignment])}var lrPlacement=[`left`,`right`],rlPlacement=[`right`,`left`],tbPlacement=[`top`,`bottom`],btPlacement=[`bottom`,`top`];function getSideList(side,isStart,rtl){switch(side){case`top`:case`bottom`:return rtl?isStart?rlPlacement:lrPlacement:isStart?lrPlacement:rlPlacement;case`left`:case`right`:return isStart?tbPlacement:btPlacement;default:return[]}}function getOppositeAxisPlacements(placement,flipAlignment,direction$1,rtl){let alignment=getAlignment(placement),list=getSideList(getSide(placement),direction$1===`start`,rtl);return alignment&&(list=list.map(side=>side+`-`+alignment),flipAlignment&&(list=list.concat(list.map(getOppositeAlignmentPlacement)))),list}function getOppositePlacement(placement){return placement.replace(/left|right|bottom|top/g,side=>oppositeSideMap[side])}function expandPaddingObject(padding){return{top:0,right:0,bottom:0,left:0,...padding}}function getPaddingObject(padding){return typeof padding==`number`?{top:padding,right:padding,bottom:padding,left:padding}:expandPaddingObject(padding)}function rectToClientRect(rect){let{x,y,width:width$1,height:height$1}=rect;return{width:width$1,height:height$1,top:y,left:x,right:x+width$1,bottom:y+height$1,x,y}}function computeCoordsFromPlacement(_ref,placement,rtl){let{reference,floating}=_ref,sideAxis=getSideAxis(placement),alignmentAxis=getAlignmentAxis(placement),alignLength=getAxisLength(alignmentAxis),side=getSide(placement),isVertical=sideAxis===`y`,commonX=reference.x+reference.width/2-floating.width/2,commonY=reference.y+reference.height/2-floating.height/2,commonAlign=reference[alignLength]/2-floating[alignLength]/2,coords;switch(side){case`top`:coords={x:commonX,y:reference.y-floating.height};break;case`bottom`:coords={x:commonX,y:reference.y+reference.height};break;case`right`:coords={x:reference.x+reference.width,y:commonY};break;case`left`:coords={x:reference.x-floating.width,y:commonY};break;default:coords={x:reference.x,y:reference.y}}switch(getAlignment(placement)){case`start`:coords[alignmentAxis]-=commonAlign*(rtl&&isVertical?-1:1);break;case`end`:coords[alignmentAxis]+=commonAlign*(rtl&&isVertical?-1:1);break}return coords}var computePosition$1=async(reference,floating,config)=>{let{placement=`bottom`,strategy=`absolute`,middleware=[],platform:platform$1}=config,validMiddleware=middleware.filter(Boolean),rtl=await(platform$1.isRTL==null?void 0:platform$1.isRTL(floating)),rects=await platform$1.getElementRects({reference,floating,strategy}),{x,y}=computeCoordsFromPlacement(rects,placement,rtl),statefulPlacement=placement,middlewareData={},resetCount=0;for(let i=0;i({name:`arrow`,options,async fn(state){let{x,y,placement,rects,platform:platform$1,elements,middlewareData}=state,{element,padding=0}=evaluate(options,state)||{};if(element==null)return{};let paddingObject=getPaddingObject(padding),coords={x,y},axis=getAlignmentAxis(placement),length=getAxisLength(axis),arrowDimensions=await platform$1.getDimensions(element),isYAxis=axis===`y`,minProp=isYAxis?`top`:`left`,maxProp=isYAxis?`bottom`:`right`,clientProp=isYAxis?`clientHeight`:`clientWidth`,endDiff=rects.reference[length]+rects.reference[axis]-coords[axis]-rects.floating[length],startDiff=coords[axis]-rects.reference[axis],arrowOffsetParent=await(platform$1.getOffsetParent==null?void 0:platform$1.getOffsetParent(element)),clientSize=arrowOffsetParent?arrowOffsetParent[clientProp]:0;(!clientSize||!await(platform$1.isElement==null?void 0:platform$1.isElement(arrowOffsetParent)))&&(clientSize=elements.floating[clientProp]||rects.floating[length]);let centerToReference=endDiff/2-startDiff/2,largestPossiblePadding=clientSize/2-arrowDimensions[length]/2-1,minPadding=min(paddingObject[minProp],largestPossiblePadding),maxPadding=min(paddingObject[maxProp],largestPossiblePadding),min$1=minPadding,max$1=clientSize-arrowDimensions[length]-maxPadding,center=clientSize/2-arrowDimensions[length]/2+centerToReference,offset$2=clamp$1(min$1,center,max$1),shouldAddOffset=!middlewareData.arrow&&getAlignment(placement)!=null&¢er!==offset$2&&rects.reference[length]/2-(centerside$1<=0)){var _middlewareData$flip2,_overflowsData$filter;let nextIndex=(middlewareData.flip?.index||0)+1,nextPlacement=placements$1[nextIndex];if(nextPlacement&&(!(checkCrossAxis===`alignment`&&initialSideAxis!==getSideAxis(nextPlacement))||overflowsData.every(d=>getSideAxis(d.placement)===initialSideAxis?d.overflows[0]>0:!0)))return{data:{index:nextIndex,overflows:overflowsData},reset:{placement:nextPlacement}};let resetPlacement=overflowsData.filter(d=>d.overflows[0]<=0).sort((a$1,b)=>a$1.overflows[1]-b.overflows[1])[0]?.placement;if(!resetPlacement)switch(fallbackStrategy){case`bestFit`:{var _overflowsData$filter2;let placement$1=overflowsData.filter(d=>{if(hasFallbackAxisSideDirection){let currentSideAxis=getSideAxis(d.placement);return currentSideAxis===initialSideAxis||currentSideAxis===`y`}return!0}).map(d=>[d.placement,d.overflows.filter(overflow$1=>overflow$1>0).reduce((acc,overflow$1)=>acc+overflow$1,0)]).sort((a$1,b)=>a$1[1]-b[1])[0]?.[0];placement$1&&(resetPlacement=placement$1);break}case`initialPlacement`:resetPlacement=initialPlacement;break}if(placement!==resetPlacement)return{reset:{placement:resetPlacement}}}return{}}}},originSides=new Set([`left`,`top`]);async function convertValueToCoords(state,options){let{placement,platform:platform$1,elements}=state,rtl=await(platform$1.isRTL==null?void 0:platform$1.isRTL(elements.floating)),side=getSide(placement),alignment=getAlignment(placement),isVertical=getSideAxis(placement)===`y`,mainAxisMulti=originSides.has(side)?-1:1,crossAxisMulti=rtl&&isVertical?-1:1,rawValue=evaluate(options,state),{mainAxis,crossAxis,alignmentAxis}=typeof rawValue==`number`?{mainAxis:rawValue,crossAxis:0,alignmentAxis:null}:{mainAxis:rawValue.mainAxis||0,crossAxis:rawValue.crossAxis||0,alignmentAxis:rawValue.alignmentAxis};return alignment&&typeof alignmentAxis==`number`&&(crossAxis=alignment===`end`?alignmentAxis*-1:alignmentAxis),isVertical?{x:crossAxis*crossAxisMulti,y:mainAxis*mainAxisMulti}:{x:mainAxis*mainAxisMulti,y:crossAxis*crossAxisMulti}}var offset$1=function(options){return options===void 0&&(options=0),{name:`offset`,options,async fn(state){var _middlewareData$offse,_middlewareData$arrow;let{x,y,placement,middlewareData}=state,diffCoords=await convertValueToCoords(state,options);return placement===middlewareData.offset?.placement&&(_middlewareData$arrow=middlewareData.arrow)!=null&&_middlewareData$arrow.alignmentOffset?{}:{x:x+diffCoords.x,y:y+diffCoords.y,data:{...diffCoords,placement}}}}},shift$1=function(options){return options===void 0&&(options={}),{name:`shift`,options,async fn(state){let{x,y,placement}=state,{mainAxis:checkMainAxis=!0,crossAxis:checkCrossAxis=!1,limiter={fn:_ref=>{let{x:x$1,y:y$1}=_ref;return{x:x$1,y:y$1}}},...detectOverflowOptions}=evaluate(options,state),coords={x,y},overflow=await detectOverflow$1(state,detectOverflowOptions),crossAxis=getSideAxis(getSide(placement)),mainAxis=getOppositeAxis(crossAxis),mainAxisCoord=coords[mainAxis],crossAxisCoord=coords[crossAxis];if(checkMainAxis){let minSide=mainAxis===`y`?`top`:`left`,maxSide=mainAxis===`y`?`bottom`:`right`,min$1=mainAxisCoord+overflow[minSide],max$1=mainAxisCoord-overflow[maxSide];mainAxisCoord=clamp$1(min$1,mainAxisCoord,max$1)}if(checkCrossAxis){let minSide=crossAxis===`y`?`top`:`left`,maxSide=crossAxis===`y`?`bottom`:`right`,min$1=crossAxisCoord+overflow[minSide],max$1=crossAxisCoord-overflow[maxSide];crossAxisCoord=clamp$1(min$1,crossAxisCoord,max$1)}let limitedCoords=limiter.fn({...state,[mainAxis]:mainAxisCoord,[crossAxis]:crossAxisCoord});return{...limitedCoords,data:{x:limitedCoords.x-x,y:limitedCoords.y-y,enabled:{[mainAxis]:checkMainAxis,[crossAxis]:checkCrossAxis}}}}}};function hasWindow(){return typeof window<`u`}function getNodeName(node){return isNode(node)?(node.nodeName||``).toLowerCase():`#document`}function getWindow(node){var _node$ownerDocument;return(node==null||(_node$ownerDocument=node.ownerDocument)==null?void 0:_node$ownerDocument.defaultView)||window}function getDocumentElement(node){var _ref;return((isNode(node)?node.ownerDocument:node.document)||window.document)?.documentElement}function isNode(value){return hasWindow()?value instanceof Node||value instanceof getWindow(value).Node:!1}function isElement(value){return hasWindow()?value instanceof Element||value instanceof getWindow(value).Element:!1}function isHTMLElement(value){return hasWindow()?value instanceof HTMLElement||value instanceof getWindow(value).HTMLElement:!1}function isShadowRoot(value){return!hasWindow()||typeof ShadowRoot>`u`?!1:value instanceof ShadowRoot||value instanceof getWindow(value).ShadowRoot}var invalidOverflowDisplayValues=new Set([`inline`,`contents`]);function isOverflowElement(element){let{overflow,overflowX,overflowY,display}=getComputedStyle$1(element);return/auto|scroll|overlay|hidden|clip/.test(overflow+overflowY+overflowX)&&!invalidOverflowDisplayValues.has(display)}var tableElements=new Set([`table`,`td`,`th`]);function isTableElement(element){return tableElements.has(getNodeName(element))}var topLayerSelectors=[`:popover-open`,`:modal`];function isTopLayer(element){return topLayerSelectors.some(selector=>{try{return element.matches(selector)}catch{return!1}})}var transformProperties=[`transform`,`translate`,`scale`,`rotate`,`perspective`],willChangeValues=[`transform`,`translate`,`scale`,`rotate`,`perspective`,`filter`],containValues=[`paint`,`layout`,`strict`,`content`];function isContainingBlock(elementOrCss){let webkit=isWebKit(),css=isElement(elementOrCss)?getComputedStyle$1(elementOrCss):elementOrCss;return transformProperties.some(value=>css[value]?css[value]!==`none`:!1)||(css.containerType?css.containerType!==`normal`:!1)||!webkit&&(css.backdropFilter?css.backdropFilter!==`none`:!1)||!webkit&&(css.filter?css.filter!==`none`:!1)||willChangeValues.some(value=>(css.willChange||``).includes(value))||containValues.some(value=>(css.contain||``).includes(value))}function getContainingBlock(element){let currentNode=getParentNode(element);for(;isHTMLElement(currentNode)&&!isLastTraversableNode(currentNode);){if(isContainingBlock(currentNode))return currentNode;if(isTopLayer(currentNode))return null;currentNode=getParentNode(currentNode)}return null}function isWebKit(){return typeof CSS>`u`||!CSS.supports?!1:CSS.supports(`-webkit-backdrop-filter`,`none`)}var lastTraversableNodeNames=new Set([`html`,`body`,`#document`]);function isLastTraversableNode(node){return lastTraversableNodeNames.has(getNodeName(node))}function getComputedStyle$1(element){return getWindow(element).getComputedStyle(element)}function getNodeScroll(element){return isElement(element)?{scrollLeft:element.scrollLeft,scrollTop:element.scrollTop}:{scrollLeft:element.scrollX,scrollTop:element.scrollY}}function getParentNode(node){if(getNodeName(node)===`html`)return node;let result=node.assignedSlot||node.parentNode||isShadowRoot(node)&&node.host||getDocumentElement(node);return isShadowRoot(result)?result.host:result}function getNearestOverflowAncestor(node){let parentNode=getParentNode(node);return isLastTraversableNode(parentNode)?node.ownerDocument?node.ownerDocument.body:node.body:isHTMLElement(parentNode)&&isOverflowElement(parentNode)?parentNode:getNearestOverflowAncestor(parentNode)}function getOverflowAncestors(node,list,traverseIframes){var _node$ownerDocument2;list===void 0&&(list=[]),traverseIframes===void 0&&(traverseIframes=!0);let scrollableAncestor=getNearestOverflowAncestor(node),isBody=scrollableAncestor===node.ownerDocument?.body,win=getWindow(scrollableAncestor);if(isBody){let frameElement=getFrameElement(win);return list.concat(win,win.visualViewport||[],isOverflowElement(scrollableAncestor)?scrollableAncestor:[],frameElement&&traverseIframes?getOverflowAncestors(frameElement):[])}return list.concat(scrollableAncestor,getOverflowAncestors(scrollableAncestor,[],traverseIframes))}function getFrameElement(win){return win.parent&&Object.getPrototypeOf(win.parent)?win.frameElement:null}function getCssDimensions(element){let css=getComputedStyle$1(element),width$1=parseFloat(css.width)||0,height$1=parseFloat(css.height)||0,hasOffset=isHTMLElement(element),offsetWidth=hasOffset?element.offsetWidth:width$1,offsetHeight=hasOffset?element.offsetHeight:height$1,shouldFallback=round$1(width$1)!==offsetWidth||round$1(height$1)!==offsetHeight;return shouldFallback&&(width$1=offsetWidth,height$1=offsetHeight),{width:width$1,height:height$1,$:shouldFallback}}function unwrapElement$1(element){return isElement(element)?element:element.contextElement}function getScale(element){let domElement=unwrapElement$1(element);if(!isHTMLElement(domElement))return createCoords(1);let rect=domElement.getBoundingClientRect(),{width:width$1,height:height$1,$}=getCssDimensions(domElement),x=($?round$1(rect.width):rect.width)/width$1,y=($?round$1(rect.height):rect.height)/height$1;return(!x||!Number.isFinite(x))&&(x=1),(!y||!Number.isFinite(y))&&(y=1),{x,y}}var noOffsets=createCoords(0);function getVisualOffsets(element){let win=getWindow(element);return!isWebKit()||!win.visualViewport?noOffsets:{x:win.visualViewport.offsetLeft,y:win.visualViewport.offsetTop}}function shouldAddVisualOffsets(element,isFixed,floatingOffsetParent){return isFixed===void 0&&(isFixed=!1),!floatingOffsetParent||isFixed&&floatingOffsetParent!==getWindow(element)?!1:isFixed}function getBoundingClientRect(element,includeScale,isFixedStrategy,offsetParent){includeScale===void 0&&(includeScale=!1),isFixedStrategy===void 0&&(isFixedStrategy=!1);let clientRect=element.getBoundingClientRect(),domElement=unwrapElement$1(element),scale=createCoords(1);includeScale&&(offsetParent?isElement(offsetParent)&&(scale=getScale(offsetParent)):scale=getScale(element));let visualOffsets=shouldAddVisualOffsets(domElement,isFixedStrategy,offsetParent)?getVisualOffsets(domElement):createCoords(0),x=(clientRect.left+visualOffsets.x)/scale.x,y=(clientRect.top+visualOffsets.y)/scale.y,width$1=clientRect.width/scale.x,height$1=clientRect.height/scale.y;if(domElement){let win=getWindow(domElement),offsetWin=offsetParent&&isElement(offsetParent)?getWindow(offsetParent):offsetParent,currentWin=win,currentIFrame=getFrameElement(currentWin);for(;currentIFrame&&offsetParent&&offsetWin!==currentWin;){let iframeScale=getScale(currentIFrame),iframeRect=currentIFrame.getBoundingClientRect(),css=getComputedStyle$1(currentIFrame),left=iframeRect.left+(currentIFrame.clientLeft+parseFloat(css.paddingLeft))*iframeScale.x,top=iframeRect.top+(currentIFrame.clientTop+parseFloat(css.paddingTop))*iframeScale.y;x*=iframeScale.x,y*=iframeScale.y,width$1*=iframeScale.x,height$1*=iframeScale.y,x+=left,y+=top,currentWin=getWindow(currentIFrame),currentIFrame=getFrameElement(currentWin)}}return rectToClientRect({width:width$1,height:height$1,x,y})}function getWindowScrollBarX(element,rect){let leftScroll=getNodeScroll(element).scrollLeft;return rect?rect.left+leftScroll:getBoundingClientRect(getDocumentElement(element)).left+leftScroll}function getHTMLOffset(documentElement,scroll$1){let htmlRect=documentElement.getBoundingClientRect();return{x:htmlRect.left+scroll$1.scrollLeft-getWindowScrollBarX(documentElement,htmlRect),y:htmlRect.top+scroll$1.scrollTop}}function convertOffsetParentRelativeRectToViewportRelativeRect(_ref){let{elements,rect,offsetParent,strategy}=_ref,isFixed=strategy===`fixed`,documentElement=getDocumentElement(offsetParent),topLayer=elements?isTopLayer(elements.floating):!1;if(offsetParent===documentElement||topLayer&&isFixed)return rect;let scroll$1={scrollLeft:0,scrollTop:0},scale=createCoords(1),offsets=createCoords(0),isOffsetParentAnElement=isHTMLElement(offsetParent);if((isOffsetParentAnElement||!isOffsetParentAnElement&&!isFixed)&&((getNodeName(offsetParent)!==`body`||isOverflowElement(documentElement))&&(scroll$1=getNodeScroll(offsetParent)),isHTMLElement(offsetParent))){let offsetRect=getBoundingClientRect(offsetParent);scale=getScale(offsetParent),offsets.x=offsetRect.x+offsetParent.clientLeft,offsets.y=offsetRect.y+offsetParent.clientTop}let htmlOffset=documentElement&&!isOffsetParentAnElement&&!isFixed?getHTMLOffset(documentElement,scroll$1):createCoords(0);return{width:rect.width*scale.x,height:rect.height*scale.y,x:rect.x*scale.x-scroll$1.scrollLeft*scale.x+offsets.x+htmlOffset.x,y:rect.y*scale.y-scroll$1.scrollTop*scale.y+offsets.y+htmlOffset.y}}function getClientRects(element){return Array.from(element.getClientRects())}function getDocumentRect(element){let html=getDocumentElement(element),scroll$1=getNodeScroll(element),body=element.ownerDocument.body,width$1=max(html.scrollWidth,html.clientWidth,body.scrollWidth,body.clientWidth),height$1=max(html.scrollHeight,html.clientHeight,body.scrollHeight,body.clientHeight),x=-scroll$1.scrollLeft+getWindowScrollBarX(element),y=-scroll$1.scrollTop;return getComputedStyle$1(body).direction===`rtl`&&(x+=max(html.clientWidth,body.clientWidth)-width$1),{width:width$1,height:height$1,x,y}}var SCROLLBAR_MAX=25;function getViewportRect(element,strategy){let win=getWindow(element),html=getDocumentElement(element),visualViewport=win.visualViewport,width$1=html.clientWidth,height$1=html.clientHeight,x=0,y=0;if(visualViewport){width$1=visualViewport.width,height$1=visualViewport.height;let visualViewportBased=isWebKit();(!visualViewportBased||visualViewportBased&&strategy===`fixed`)&&(x=visualViewport.offsetLeft,y=visualViewport.offsetTop)}let windowScrollbarX=getWindowScrollBarX(html);if(windowScrollbarX<=0){let doc$1=html.ownerDocument,body=doc$1.body,bodyStyles=getComputedStyle(body),bodyMarginInline=doc$1.compatMode===`CSS1Compat`&&parseFloat(bodyStyles.marginLeft)+parseFloat(bodyStyles.marginRight)||0,clippingStableScrollbarWidth=Math.abs(html.clientWidth-body.clientWidth-bodyMarginInline);clippingStableScrollbarWidth<=SCROLLBAR_MAX&&(width$1-=clippingStableScrollbarWidth)}else windowScrollbarX<=SCROLLBAR_MAX&&(width$1+=windowScrollbarX);return{width:width$1,height:height$1,x,y}}var absoluteOrFixed=new Set([`absolute`,`fixed`]);function getInnerBoundingClientRect(element,strategy){let clientRect=getBoundingClientRect(element,!0,strategy===`fixed`),top=clientRect.top+element.clientTop,left=clientRect.left+element.clientLeft,scale=isHTMLElement(element)?getScale(element):createCoords(1);return{width:element.clientWidth*scale.x,height:element.clientHeight*scale.y,x:left*scale.x,y:top*scale.y}}function getClientRectFromClippingAncestor(element,clippingAncestor,strategy){let rect;if(clippingAncestor===`viewport`)rect=getViewportRect(element,strategy);else if(clippingAncestor===`document`)rect=getDocumentRect(getDocumentElement(element));else if(isElement(clippingAncestor))rect=getInnerBoundingClientRect(clippingAncestor,strategy);else{let visualOffsets=getVisualOffsets(element);rect={x:clippingAncestor.x-visualOffsets.x,y:clippingAncestor.y-visualOffsets.y,width:clippingAncestor.width,height:clippingAncestor.height}}return rectToClientRect(rect)}function hasFixedPositionAncestor(element,stopNode){let parentNode=getParentNode(element);return parentNode===stopNode||!isElement(parentNode)||isLastTraversableNode(parentNode)?!1:getComputedStyle$1(parentNode).position===`fixed`||hasFixedPositionAncestor(parentNode,stopNode)}function getClippingElementAncestors(element,cache$1){let cachedResult=cache$1.get(element);if(cachedResult)return cachedResult;let result=getOverflowAncestors(element,[],!1).filter(el=>isElement(el)&&getNodeName(el)!==`body`),currentContainingBlockComputedStyle=null,elementIsFixed=getComputedStyle$1(element).position===`fixed`,currentNode=elementIsFixed?getParentNode(element):element;for(;isElement(currentNode)&&!isLastTraversableNode(currentNode);){let computedStyle=getComputedStyle$1(currentNode),currentNodeIsContaining=isContainingBlock(currentNode);!currentNodeIsContaining&&computedStyle.position===`fixed`&&(currentContainingBlockComputedStyle=null),(elementIsFixed?!currentNodeIsContaining&&!currentContainingBlockComputedStyle:!currentNodeIsContaining&&computedStyle.position===`static`&¤tContainingBlockComputedStyle&&absoluteOrFixed.has(currentContainingBlockComputedStyle.position)||isOverflowElement(currentNode)&&!currentNodeIsContaining&&hasFixedPositionAncestor(element,currentNode))?result=result.filter(ancestor=>ancestor!==currentNode):currentContainingBlockComputedStyle=computedStyle,currentNode=getParentNode(currentNode)}return cache$1.set(element,result),result}function getClippingRect(_ref){let{element,boundary,rootBoundary,strategy}=_ref,clippingAncestors=[...boundary===`clippingAncestors`?isTopLayer(element)?[]:getClippingElementAncestors(element,this._c):[].concat(boundary),rootBoundary],firstClippingAncestor=clippingAncestors[0],clippingRect=clippingAncestors.reduce((accRect,clippingAncestor)=>{let rect=getClientRectFromClippingAncestor(element,clippingAncestor,strategy);return accRect.top=max(rect.top,accRect.top),accRect.right=min(rect.right,accRect.right),accRect.bottom=min(rect.bottom,accRect.bottom),accRect.left=max(rect.left,accRect.left),accRect},getClientRectFromClippingAncestor(element,firstClippingAncestor,strategy));return{width:clippingRect.right-clippingRect.left,height:clippingRect.bottom-clippingRect.top,x:clippingRect.left,y:clippingRect.top}}function getDimensions(element){let{width:width$1,height:height$1}=getCssDimensions(element);return{width:width$1,height:height$1}}function getRectRelativeToOffsetParent(element,offsetParent,strategy){let isOffsetParentAnElement=isHTMLElement(offsetParent),documentElement=getDocumentElement(offsetParent),isFixed=strategy===`fixed`,rect=getBoundingClientRect(element,!0,isFixed,offsetParent),scroll$1={scrollLeft:0,scrollTop:0},offsets=createCoords(0);function setLeftRTLScrollbarOffset(){offsets.x=getWindowScrollBarX(documentElement)}if(isOffsetParentAnElement||!isOffsetParentAnElement&&!isFixed)if((getNodeName(offsetParent)!==`body`||isOverflowElement(documentElement))&&(scroll$1=getNodeScroll(offsetParent)),isOffsetParentAnElement){let offsetRect=getBoundingClientRect(offsetParent,!0,isFixed,offsetParent);offsets.x=offsetRect.x+offsetParent.clientLeft,offsets.y=offsetRect.y+offsetParent.clientTop}else documentElement&&setLeftRTLScrollbarOffset();isFixed&&!isOffsetParentAnElement&&documentElement&&setLeftRTLScrollbarOffset();let htmlOffset=documentElement&&!isOffsetParentAnElement&&!isFixed?getHTMLOffset(documentElement,scroll$1):createCoords(0);return{x:rect.left+scroll$1.scrollLeft-offsets.x-htmlOffset.x,y:rect.top+scroll$1.scrollTop-offsets.y-htmlOffset.y,width:rect.width,height:rect.height}}function isStaticPositioned(element){return getComputedStyle$1(element).position===`static`}function getTrueOffsetParent(element,polyfill){if(!isHTMLElement(element)||getComputedStyle$1(element).position===`fixed`)return null;if(polyfill)return polyfill(element);let rawOffsetParent=element.offsetParent;return getDocumentElement(element)===rawOffsetParent&&(rawOffsetParent=rawOffsetParent.ownerDocument.body),rawOffsetParent}function getOffsetParent(element,polyfill){let win=getWindow(element);if(isTopLayer(element))return win;if(!isHTMLElement(element)){let svgOffsetParent=getParentNode(element);for(;svgOffsetParent&&!isLastTraversableNode(svgOffsetParent);){if(isElement(svgOffsetParent)&&!isStaticPositioned(svgOffsetParent))return svgOffsetParent;svgOffsetParent=getParentNode(svgOffsetParent)}return win}let offsetParent=getTrueOffsetParent(element,polyfill);for(;offsetParent&&isTableElement(offsetParent)&&isStaticPositioned(offsetParent);)offsetParent=getTrueOffsetParent(offsetParent,polyfill);return offsetParent&&isLastTraversableNode(offsetParent)&&isStaticPositioned(offsetParent)&&!isContainingBlock(offsetParent)?win:offsetParent||getContainingBlock(element)||win}var getElementRects=async function(data){let getOffsetParentFn=this.getOffsetParent||getOffsetParent,getDimensionsFn=this.getDimensions,floatingDimensions=await getDimensionsFn(data.floating);return{reference:getRectRelativeToOffsetParent(data.reference,await getOffsetParentFn(data.floating),data.strategy),floating:{x:0,y:0,width:floatingDimensions.width,height:floatingDimensions.height}}};function isRTL(element){return getComputedStyle$1(element).direction===`rtl`}var platform={convertOffsetParentRelativeRectToViewportRelativeRect,getDocumentElement,getClippingRect,getOffsetParent,getElementRects,getClientRects,getDimensions,getScale,isElement,isRTL};function rectsAreEqual(a$1,b){return a$1.x===b.x&&a$1.y===b.y&&a$1.width===b.width&&a$1.height===b.height}function observeMove(element,onMove){let io=null,timeoutId,root=getDocumentElement(element);function cleanup(){var _io;clearTimeout(timeoutId),(_io=io)==null||_io.disconnect(),io=null}function refresh$1(skip,threshold){skip===void 0&&(skip=!1),threshold===void 0&&(threshold=1),cleanup();let elementRectForRootMargin=element.getBoundingClientRect(),{left,top,width:width$1,height:height$1}=elementRectForRootMargin;if(skip||onMove(),!width$1||!height$1)return;let insetTop=floor(top),insetRight=floor(root.clientWidth-(left+width$1)),insetBottom=floor(root.clientHeight-(top+height$1)),insetLeft=floor(left),options={rootMargin:-insetTop+`px `+-insetRight+`px `+-insetBottom+`px `+-insetLeft+`px`,threshold:max(0,min(1,threshold))||1},isFirstUpdate=!0;function handleObserve(entries){let ratio=entries[0].intersectionRatio;if(ratio!==threshold){if(!isFirstUpdate)return refresh$1();ratio?refresh$1(!1,ratio):timeoutId=setTimeout(()=>{refresh$1(!1,1e-7)},1e3)}ratio===1&&!rectsAreEqual(elementRectForRootMargin,element.getBoundingClientRect())&&refresh$1(),isFirstUpdate=!1}try{io=new IntersectionObserver(handleObserve,{...options,root:root.ownerDocument})}catch{io=new IntersectionObserver(handleObserve,options)}io.observe(element)}return refresh$1(!0),cleanup}function autoUpdate(reference,floating,update$6,options){options===void 0&&(options={});let{ancestorScroll=!0,ancestorResize=!0,elementResize=typeof ResizeObserver==`function`,layoutShift=typeof IntersectionObserver==`function`,animationFrame=!1}=options,referenceEl=unwrapElement$1(reference),ancestors=ancestorScroll||ancestorResize?[...referenceEl?getOverflowAncestors(referenceEl):[],...getOverflowAncestors(floating)]:[];ancestors.forEach(ancestor=>{ancestorScroll&&ancestor.addEventListener(`scroll`,update$6,{passive:!0}),ancestorResize&&ancestor.addEventListener(`resize`,update$6)});let cleanupIo=referenceEl&&layoutShift?observeMove(referenceEl,update$6):null,reobserveFrame=-1,resizeObserver=null;elementResize&&(resizeObserver=new ResizeObserver(_ref=>{let[firstEntry]=_ref;firstEntry&&firstEntry.target===referenceEl&&resizeObserver&&(resizeObserver.unobserve(floating),cancelAnimationFrame(reobserveFrame),reobserveFrame=requestAnimationFrame(()=>{var _resizeObserver;(_resizeObserver=resizeObserver)==null||_resizeObserver.observe(floating)})),update$6()}),referenceEl&&!animationFrame&&resizeObserver.observe(referenceEl),resizeObserver.observe(floating));let frameId,prevRefRect=animationFrame?getBoundingClientRect(reference):null;animationFrame&&frameLoop();function frameLoop(){let nextRefRect=getBoundingClientRect(reference);prevRefRect&&!rectsAreEqual(prevRefRect,nextRefRect)&&update$6(),prevRefRect=nextRefRect,frameId=requestAnimationFrame(frameLoop)}return update$6(),()=>{var _resizeObserver2;ancestors.forEach(ancestor=>{ancestorScroll&&ancestor.removeEventListener(`scroll`,update$6),ancestorResize&&ancestor.removeEventListener(`resize`,update$6)}),cleanupIo?.(),(_resizeObserver2=resizeObserver)==null||_resizeObserver2.disconnect(),resizeObserver=null,animationFrame&&cancelAnimationFrame(frameId)}}var offset=offset$1,shift=shift$1,flip=flip$1,arrow$1=arrow$2,computePosition=(reference,floating,options)=>{let cache$1=new Map,mergedOptions={platform,...options},platformWithCache={...mergedOptions.platform,_c:cache$1};return computePosition$1(reference,floating,{...mergedOptions,platform:platformWithCache})};function isComponentPublicInstance(target){return typeof target==`object`&&!!target&&`$el`in target}function unwrapElement(target){if(isComponentPublicInstance(target)){let element=target.$el;return isNode(element)&&getNodeName(element)===`#comment`?null:element}return target}function toValue(source){return typeof source==`function`?source():unref(source)}function arrow(options){return{name:`arrow`,options,fn(args){let element=unwrapElement(toValue(options.element));return element==null?{}:arrow$1({element,padding:options.padding}).fn(args)}}}function getDPR(element){return typeof window>`u`?1:(element.ownerDocument.defaultView||window).devicePixelRatio||1}function roundByDPR(element,value){let dpr=getDPR(element);return Math.round(value*dpr)/dpr}function useFloating(reference,floating,options){options===void 0&&(options={});let whileElementsMountedOption=options.whileElementsMounted,openOption=computed(()=>{var _toValue;return toValue(options.open)??!0}),middlewareOption=computed(()=>toValue(options.middleware)),placementOption=computed(()=>{var _toValue2;return toValue(options.placement)??`bottom`}),strategyOption=computed(()=>{var _toValue3;return toValue(options.strategy)??`absolute`}),transformOption=computed(()=>{var _toValue4;return toValue(options.transform)??!0}),referenceElement=computed(()=>unwrapElement(reference.value)),floatingElement=computed(()=>unwrapElement(floating.value)),x=ref(0),y=ref(0),strategy=ref(strategyOption.value),placement=ref(placementOption.value),middlewareData=shallowRef({}),isPositioned=ref(!1),floatingStyles=computed(()=>{let initialStyles={position:strategy.value,left:`0`,top:`0`};if(!floatingElement.value)return initialStyles;let xVal=roundByDPR(floatingElement.value,x.value),yVal=roundByDPR(floatingElement.value,y.value);return transformOption.value?{...initialStyles,transform:`translate(`+xVal+`px, `+yVal+`px)`,...getDPR(floatingElement.value)>=1.5&&{willChange:`transform`}}:{position:strategy.value,left:xVal+`px`,top:yVal+`px`}}),whileElementsMountedCleanup;function update$6(){if(referenceElement.value==null||floatingElement.value==null)return;let open$1=openOption.value;computePosition(referenceElement.value,floatingElement.value,{middleware:middlewareOption.value,placement:placementOption.value,strategy:strategyOption.value}).then(position=>{x.value=position.x,y.value=position.y,strategy.value=position.strategy,placement.value=position.placement,middlewareData.value=position.middlewareData,isPositioned.value=open$1!==!1})}function cleanup(){typeof whileElementsMountedCleanup==`function`&&(whileElementsMountedCleanup(),whileElementsMountedCleanup=void 0)}function attach(){if(cleanup(),whileElementsMountedOption===void 0){update$6();return}if(referenceElement.value!=null&&floatingElement.value!=null){whileElementsMountedCleanup=whileElementsMountedOption(referenceElement.value,floatingElement.value,update$6);return}}function reset$1(){openOption.value||(isPositioned.value=!1)}return watch([middlewareOption,placementOption,strategyOption,openOption],update$6,{flush:`sync`}),watch([referenceElement,floatingElement],attach,{flush:`sync`}),watch(openOption,reset$1,{flush:`sync`}),getCurrentScope()&&onScopeDispose(cleanup),{x:shallowReadonly(x),y:shallowReadonly(y),strategy:shallowReadonly(strategy),placement:shallowReadonly(placement),middlewareData:shallowReadonly(middlewareData),isPositioned:shallowReadonly(isPositioned),floatingStyles,update:update$6}}var ARROW_POSITION={top:`bottom`,right:`left`,bottom:`top`,left:`right`};const usePopover=defineStore(`popover`,()=>{let _counter=ref(0),_currentPopover=ref(null),popovers=ref({}),currentPopover=computed(()=>_currentPopover.value),register=(name,popover,popoverPlacement=void 0,options={})=>{if(popovers.value[name])return;popovers.value[name]={element:popover,target:null,placement:popoverPlacement||`bottom`,show:!1};let popoverInstance=buildPopover(popover,toRef(popovers.value[name],`target`),toRef(popovers.value[name],`placement`),options),scope$1=effectScope(),show$1;scope$1.run(()=>{show$1=computed(()=>popovers.value[name].show)});let dispose$2=()=>{scope$1.stop(),popoverInstance.dispose()};return popovers.value[name].dispose=dispose$2,_counter.value++,{show:show$1,update:popoverInstance.update,placement:popoverInstance.placement}},bind=(popoverName,el,options)=>{let scope$1=effectScope(),hidden,isBound,popoverElement;scope$1.run(()=>{hidden=computed(()=>popovers.value[popoverName]?!popovers.value[popoverName].show:void 0),isBound=computed(()=>popovers.value[popoverName]?popovers.value[popoverName].target===el:void 0),popoverElement=computed(()=>popovers.value[popoverName]?popovers.value[popoverName].element:void 0)});let show$1=()=>{isBound.value||(popovers.value[popoverName].target=el,popovers.value[popoverName].placement=options.placement),popovers.value[popoverName].show=!0},hide$3=()=>{isBound.value&&(popovers.value[popoverName].show=!1)};return{popoverElement,hidden,isBound,show:show$1,hide:hide$3,toggle:(forceValue=void 0)=>{let doShow=forceValue;typeof doShow!=`boolean`&&(doShow=!isBound.value||!popovers.value[popoverName].show),doShow?show$1():hide$3()},isShown:()=>!!popovers.value[popoverName].show,unbind:()=>{scope$1.stop()}}},unregister=name=>{popovers.value[name]&&(popovers.value[name].dispose(),delete popovers.value[name])},isShown=name=>name in popovers.value?popovers.value[name].show:!1,show=(name,target)=>{name in popovers.value&&(popovers.value[name].show=!0,target&&(popovers.value[name].target=target),_currentPopover.value=popovers.value[name])},hide$2=name=>{name in popovers.value&&(popovers.value[name].show=!1,_currentPopover.value=null)};return{popovers,currentPopover,bind,register,unregister,isShown,show,hide:hide$2,toggle:(name,forceValue=void 0)=>{name in popovers.value&&(popovers.value[name].show=typeof forceValue==`boolean`?forceValue:!popovers.value[name].show,_currentPopover.value=popovers.value[name].show?popovers.value[name]:null)},hideAll:(startsWith=void 0)=>{let keys=Object.keys(popovers.value);startsWith&&(keys=keys.filter(name=>name.startsWith(startsWith))),keys.forEach(name=>popovers.value[name].show&&hide$2(name))},getPopover:name=>popovers.value[name],counter:computed(()=>_counter.value)}});function buildPopover(popover,reference,placementArg,options){let{floatingStyles,middlewareData,update:update$6,placement}=useFloating(reference,popover,{placement:placementArg,middleware:buildMiddleware(popover,options),whileElementsMounted:autoUpdate}),watchers$1=[];return watchers$1.push(watch(floatingStyles,async styles=>{popover.value&&await nextTick(()=>{Object.keys(styles).forEach(styleName=>popover.value.style[styleName]=styles[styleName])})})),options.arrow&&watchers$1.push(watch(middlewareData,async middlewareData$1=>{let left=middlewareData$1.arrow&&middlewareData$1.arrow.x!=null?`${middlewareData$1.arrow.x}px`:``,top=middlewareData$1.arrow&&middlewareData$1.arrow.y!=null?`${middlewareData$1.arrow.y}px`:``,arrowSide=ARROW_POSITION[middlewareData$1.offset.placement.split(`-`)[0]];await nextTick(()=>{applyStyles(options.arrow.value,{left,top,right:``,bottom:``,[arrowSide]:`-${options.arrow.value.offsetWidth/2}px`})})})),{placement,update:update$6,dispose:()=>{watchers$1.forEach(unwatch=>unwatch())}}}var arrowOffset=options=>({name:`arrowOffset`,options,fn({...state}){let arrOffset=Math.sqrt(2*options.element.value.offsetWidth**2)/2,side=state.placement.startsWith(`left`)||state.placement.startsWith(`top`)?-1:1;if(state.placement.startsWith(`left`)||state.placement.startsWith(`right`))return{x:state.x+side*arrOffset};if(state.placement.startsWith(`top`)||state.placement.startsWith(`bottom`))return{y:state.y+side*arrOffset}}});function buildMiddleware(popover,options){let middleware=[flip(),shift()],offsetValue=options.offset||0;return middleware.push(offset(offsetValue)),options.arrow&&(middleware.push(arrowOffset({element:options.arrow})),middleware.push(arrow({element:options.arrow}))),middleware}function applyStyles(el,styles){Object.keys(styles).forEach(styleName=>el.style[styleName]=styles[styleName])}var HOVER_SHOW_EVENTS=[`mouseover`,`focus`],HOVER_HIDE_EVENTS=[`mouseleave`,`blur`],TOGGLE_EVENTS=[`click`],BngPopover_default={mounted:setup$1,updated:setup$1,onBeforeUnmount:dispose};function setup$1(el,binding){dispose(el),binding.value&&(setPopoverProperties(el,binding),bindPopover(el),attachListeners(el,binding.modifiers))}function dispose(el){el.__popover&&(el.__popover.unregister&&el.__popover.unbind(),removeListeners(el))}function attachListeners(el,modifiers){el.__popover.showHandler=event=>{el.contains(event.target)&&el.__popover.show()},el.__popover.hideHandler=event=>{el.contains(event.relatedTarget)||el.__popover.hide()},el.__popover.toggleHandler=event=>{el.contains(event.target)&&el.__popover.toggle()},el.__popover.clickOutside=event=>{!el.contains(event.target)&&(!el.__popover.element.value||!el.__popover.element.value.contains(event.target))&&el.__popover.hide()},modifiers.click?(TOGGLE_EVENTS.forEach(eventName=>{el.addEventListener(eventName,el.__popover.toggleHandler)}),TOGGLE_EVENTS.forEach(eventName=>{window.addEventListener(eventName,el.__popover.clickOutside)})):(HOVER_SHOW_EVENTS.forEach(eventName=>el.addEventListener(eventName,el.__popover.showHandler)),HOVER_HIDE_EVENTS.forEach(eventName=>el.addEventListener(eventName,el.__popover.hideHandler)))}function removeListeners(el){el.__popover.toggleHandler&&(TOGGLE_EVENTS.forEach(eventName=>{el.removeEventListener(eventName,el.__popover.toggleHandler)}),TOGGLE_EVENTS.forEach(eventName=>{window.removeEventListener(eventName,el.__popover.clickOutside)})),el.__popover.showHandler&&HOVER_SHOW_EVENTS.forEach(eventName=>el.removeEventListener(eventName,el.__popover.showHandler)),el.__popover.hideHandler&&HOVER_SHOW_EVENTS.forEach(eventName=>el.removeEventListener(eventName,el.__popover.hideHandler))}function bindPopover(el){let popoverBind=usePopover().bind(el.__popover.name,el,getOptions$1(el));Object.assign(el.__popover,{toggle:popoverBind.toggle,show:popoverBind.show,isShown:popoverBind.isShown,hide:popoverBind.hide,toggle:popoverBind.toggle,hidden:popoverBind.hidden,element:popoverBind.popoverElement,unbind:popoverBind.unbind})}function setPopoverProperties(el,binding){el.__popover={name:getPopoverName(binding),placement:getPlacement(binding)}}var getOptions$1=el=>({placement:el.__popover.placement}),getPlacement=binding=>binding.arg?binding.arg:binding.placement?binding.placement:`left`,getPopoverName=binding=>typeof binding.value==`string`?binding.value:binding.value.name,TIMESPAN_TRANSLATE_ID_PREFIX=`ui.timespan.`,$t=i=>$translate.instant(TIMESPAN_TRANSLATE_ID_PREFIX+i),SECONDS_IN={year:3600*24*365,month:3600*24*30,week:3600*24*7,day:3600*24,hour:3600,minute:60,second:1},MINIMUM_SPAN=Object.entries(SECONDS_IN).slice(-1)[0][1],dateToEpoch=date=>date?typeof date==`string`?/^\d+$/.test(date)?+date:~~(new Date(date).getTime()/1e3):typeof date==`number`?date:0:0;const timeSpan=(date1,date2=null,length=2,useRelativeDescription=!1)=>{let res=`-`;if(date1=dateToEpoch(date1),!date1)return res;if(date2){if(date2=dateToEpoch(date2),!date2)return res}else date2=~~(new Date().getTime()/1e3);let diff,isFuture;return date1>=date2?(diff=date1-date2,isFuture=!0):(diff=date2-date1,isFuture=!1),res=formatTime(diff,length,useRelativeDescription,isFuture),res},formatTime=(seconds,length=2,useRelativeDescription=!1,future=!1)=>{let res=`-`;if(seconds20&&abs%10==1?abs+` `+$t(spanName+`.plural_1_pastfuture`):abs<=4||useRelativeDescription&&abs>20&&abs%10<=4?abs+` `+$t(spanName+`.plural_234`):abs+` `+$t(spanName+`.plural`),cur&&resArr.push(cur),length===1)break;length--,seconds%=spanSeconds}res=``;let resArrLen=resArr.length;return resArr.forEach((bit,i)=>{bit=bit.replace(` `,`\xA0`),i?(i===resArrLen-1?res+=` `+$t(`and`)+` `:res+=$t(`separator`)+` `,res+=bit):res+=ucaseFirst(bit)}),useRelativeDescription&&(res+=` `+$t(future?`future`:`past`)),res};var update=(element,{value})=>{let desc=timeSpan(value,null,1,!0);desc!==`-`&&(element.innerHTML=desc)},BngRelativeTime_default=update;const getScopeProperties=el=>{if(!(!el||!el.hasAttribute(`bng-ui-scope`)))return{scopeId:el.getAttribute(UI_SCOPE_ATTR$1),isScopedNav:el.hasAttribute(SCOPED_NAV_ATTR)}},findParentScope=(el,scopedNavOnly=!1)=>{let parent=el.parentElement;for(;parent;){let scopedNavId=parent.getAttribute(SCOPED_NAV_ATTR);if(scopedNavId)return{scopeId:scopedNavId,element:parent,isScopedNav:!0};if(!scopedNavOnly){let uiScopeId=parent.getAttribute(UI_SCOPE_ATTR$1);if(uiScopeId)return{scopeId:uiScopeId,element:parent,isScopedNav:!1}}parent=parent.parentElement}return null},isNavigable=el=>(!el.hasAttribute(`bng-no-nav`)||el.getAttribute(`bng-no-nav`)===`false`)&&(!el.hasAttribute(`disabled`)||el.getAttribute(`disabled`)===`false`),isDirectChild=(el,child)=>child.parentElement.closest(`[bng-scoped-nav]`)===el,getNavItems=(el,navigableOnly=!0)=>{let matches$1=el.querySelectorAll(NAVIGABLE_ELEMENTS_SELECTOR);return Array.from(matches$1).filter(child=>!isNavigable(child)&&navigableOnly?!1:isDirectChild(el,child))},getPassthroughEvents=el=>{let navItems=getNavItems(el,!1);if(navItems.length===0)return!1;let boundEvents=[];for(let elem of navItems){let uiNavEvents=elem.__BngOnUiNav?Object.values(elem.__BngOnUiNav).map(x=>x.eventNames).flat().filter(name=>!PASSTHROUGH_EXCLUDED_EVENTS.includes(name)):[],isDuplicate=uiNavEvents.some(event=>boundEvents.includes(event));if(uiNavEvents.length===0||isDuplicate){boundEvents=[];break}uiNavEvents.forEach(event=>{boundEvents.includes(event)||boundEvents.push(event)})}return boundEvents};var SCOPED_NAV_OBSERVER_EVENTS={onBeforeScopeActivated:`onBeforeScopeActivated`,onScopeActivated:`onScopeActivated`,onBeforeScopeDeactivated:`onBeforeScopeDeactivated`,onScopeDeactivated:`onScopeDeactivated`,onBeforeScopeSuspended:`onBeforeScopeSuspended`,onScopeSuspended:`onScopeSuspended`,onBeforeScopeResumed:`onBeforeScopeResumed`,onScopeResumed:`onScopeResumed`},scopedNavObservers={};function registerScopedNavObserver(id,observer$2){scopedNavObservers[id]=observer$2}function notifyScopedNavObservers(event,detail){Object.keys(scopedNavObservers).forEach(observerId=>{let callback=scopedNavObservers[observerId][event];if(callback&&typeof callback==`function`)try{callback(detail)}catch(error){logger_default.error(`Error in scoped nav observer ${observerId} for event ${event}`,error)}})}const useScopedNav=defineStore(`scopedNav2`,()=>{let scopeStack=ref([]),activateScope=(scopeId,element,options={activationType:SCOPED_NAV_STATES.active,suspendParentScopes:!1})=>{notifyScopedNavObservers(SCOPED_NAV_OBSERVER_EVENTS.onBeforeScopeActivated,{scopeId,element,options});let scopeIndex=scopeStack.value.findIndex(s=>s.scopeId===scopeId),existingScope=scopeIndex===-1?void 0:scopeStack.value[scopeIndex];if(existingScope&&existingScope.activationType===options.activationType){logger_default.warn(`Scope ${scopeId} already active. Ignoring...`),notifyScopedNavObservers(SCOPED_NAV_OBSERVER_EVENTS.onScopeActivated,{scopeId,element,options});return}existingScope?existingScope.activationType=options.activationType:(scopeStack.value.push({scopeId,element,...options}),scopeIndex=scopeStack.value.length-1),notifyScopedNavObservers(SCOPED_NAV_OBSERVER_EVENTS.onScopeActivated,{scopeId,element,options});let scopeData={scopeId,...options},{type}=element[SCOPED_NAV_PROPERTY_NAME];if(type===SCOPED_NAV_TYPES.popover||options.suspendParentScopes){let referenceElement=element;if(type===SCOPED_NAV_TYPES.popover){let popover=usePopover(),popoverName=element.getAttribute(`data-bng-popover-name`),pop=popover.getPopover(popoverName);pop&&pop.target&&(referenceElement=pop.target)}if(!referenceElement){logger_default.warn(`Unable to find popover's target element. Skipping suspending parent scopes...`);return}let parentScopes=scopeStack.value.slice(0,scopeIndex);for(let i=parentScopes.length-1;i>=0;i--){let scope$1=parentScopes[i];referenceElement&&scope$1.element.contains(referenceElement)?suspendScope(scope$1.scopeId,scopeData):referenceElement&&!scope$1.element.contains(referenceElement)&&deactivateScope(scope$1.scopeId)}}return getUINavServiceInstance().setActiveScope(scopeId),element.dispatchEvent(new CustomEvent(SCOPED_NAV_EVENTS.activate,{detail:scopeData})),scopeData},deactivateScope=(scopeId,settings$1={resumePrevious:!1})=>{let scopeIndex=scopeStack.value.findIndex(s=>s.scopeId===scopeId);if(scopeIndex===-1){logger_default.warn(`Scope ${scopeId} not found. Ignoring...`);return}notifyScopedNavObservers(SCOPED_NAV_OBSERVER_EVENTS.onBeforeScopeDeactivated,{scopeId,settings:settings$1});let scopeData=scopeStack.value[scopeIndex],element=scopeData.element,{type}=element[SCOPED_NAV_PROPERTY_NAME];if(scopeStack.value=scopeStack.value.slice(0,scopeIndex),element.dispatchEvent(new CustomEvent(SCOPED_NAV_EVENTS.deactivate,{detail:{scopeId,settings:settings$1,...scopeData}})),notifyScopedNavObservers(SCOPED_NAV_OBSERVER_EVENTS.onScopeDeactivated,{scopeId,settings:settings$1}),!settings$1.resumePrevious){getUINavServiceInstance().setActiveScope(null);return}let parentScope;if(type===SCOPED_NAV_TYPES.popover){let popover=usePopover(),popoverName=element.getAttribute(`data-bng-popover-name`),pop=popover.getPopover(popoverName);pop?parentScope=findParentScope(pop.target,!0):logger_default.warn(`Unable to find popover's target element. Skipping resume...`)}else parentScope=findParentScope(element,!0);parentScope?getScopeById(parentScope.scopeId)?resumeScope(parentScope.scopeId):activateScope(parentScope.scopeId,parentScope.element):getUINavServiceInstance().setActiveScope(null)},resumeScope=scopeId=>{let scopeIndex=scopeStack.value.findIndex(s=>s.scopeId===scopeId);if(scopeIndex===-1){logger_default.warn(`Scope ${scopeId} not found. Ignoring...`);return}notifyScopedNavObservers(SCOPED_NAV_OBSERVER_EVENTS.onBeforeScopeResumed,{scopeId});for(let i=scopeStack.value.length-1;i>scopeIndex;i--){let scope$1=scopeStack.value[i];deactivateScope(scope$1.scopeId)}let scopeData=scopeStack.value[scopeIndex];return scopeData.activationType=SCOPED_NAV_STATES.active,getUINavServiceInstance().setActiveScope(scopeData.scopeId),scopeData.element.dispatchEvent(new CustomEvent(SCOPED_NAV_EVENTS.resume,{detail:scopeData})),notifyScopedNavObservers(SCOPED_NAV_OBSERVER_EVENTS.onScopeResumed,{scopeId}),scopeData},suspendScope=(scopeId,newScope)=>{let scopeIndex=scopeStack.value.findIndex(s=>s.scopeId===scopeId);if(scopeIndex===-1){logger_default.warn(`Scope ${scopeId} not found. Ignoring...`);return}notifyScopedNavObservers(SCOPED_NAV_OBSERVER_EVENTS.onBeforeScopeSuspended,{scopeId,newScope});let scopeData=scopeStack.value[scopeIndex];if(scopeData.activationType===SCOPED_NAV_STATES.suspended){logger_default.warn(`Scope ${scopeId} already suspended. Ignoring...`);return}scopeData.activationType=SCOPED_NAV_STATES.suspended;let element=scopeData.element,payload={scopeId,newScope,...scopeData};return element.dispatchEvent(new CustomEvent(SCOPED_NAV_EVENTS.suspend,{detail:payload})),notifyScopedNavObservers(SCOPED_NAV_OBSERVER_EVENTS.onScopeSuspended,{scopeId,newScope}),scopeData},currentScope=()=>scopeStack.value[scopeStack.value.length-1],getScopeById=scopeId=>scopeStack.value.find(s=>s.scopeId===scopeId);return{activateScope,deactivateScope,resumeScope,suspendScope,getScopeById,currentScope,isCurrentScope:scopeId=>{let scope$1=currentScope();return scope$1&&scope$1.scopeId===scopeId},isActiveScope:scopeId=>{let current=currentScope();if(!current)return!1;if(current.scopeId===scopeId)return!0;if(current.activationType===SCOPED_NAV_STATES.partial&&scopeStack.value.length>2){let parentScope=scopeStack.value[scopeStack.value.length-2];if(parentScope.scopeId===scopeId&&parentScope.activationType===SCOPED_NAV_STATES.active)return!0}return!1},getScopes:()=>scopeStack.value}});var focusDebounceTimer=null,pendingFocusAction=null,focusListenersInitialized=!1,isActivatingScope=!1,isDeactivatingScope=!1,FOCUS_DEBOUNCE_TIME=200,focusManagerId=`focusManager`,clearFocusDebounce=()=>{focusDebounceTimer&&=(clearTimeout(focusDebounceTimer),null),pendingFocusAction=null},debouncedFocusAction=action=>{clearFocusDebounce(),pendingFocusAction=action,focusDebounceTimer=setTimeout(()=>{pendingFocusAction&&=(pendingFocusAction(),null),focusDebounceTimer=null},FOCUS_DEBOUNCE_TIME)};function useFocusManager(){let scopedNav=useScopedNav(),onUINavFocus=e=>{let{target,relatedTarget}=e.detail;if(isWithinDashmenu(target)||isWithinPopup(target))return;let targetScope=findParentScope(target,!0),scopeElement=targetScope&&targetScope.isScopedNav?targetScope.element:null,scopedNavProps=scopeElement&&scopeElement._bngScopedNav?scopeElement[SCOPED_NAV_PROPERTY_NAME]:null;if(scopedNavProps&&(scopeElement[SCOPED_NAV_PROPERTY_NAME].lastActiveElement=target),isActivatingScope||isDeactivatingScope||shouldSkipFocusHandling(scopedNavProps)){clearFocusDebounce();return}debouncedFocusAction(()=>handleFocusAction(target,targetScope,scopeElement,scopedNav))},onUINavBlur=e=>{let{target}=e.detail,scopeProperties=getScopeProperties(target);shouldHandleBlur(scopeProperties,scopedNav.currentScope())&&(target[SCOPED_NAV_PROPERTY_NAME].passthroughActive=!1,scopedNav.deactivateScope(scopeProperties.scopeId,{resumePrevious:!0}))};function addFocusListeners(){focusListenersInitialized||=(document.addEventListener(`uinav-focus`,onUINavFocus),document.addEventListener(`uinav-blur`,onUINavBlur),registerScopedNavObserver(focusManagerId,{onBeforeScopeActivated:()=>{clearFocusDebounce(),isActivatingScope=!0},onScopeActivated:()=>{clearFocusDebounce(),isActivatingScope=!1},onBeforeScopeDeactivated:()=>{clearFocusDebounce(),isDeactivatingScope=!0},onScopeDeactivated:()=>{clearFocusDebounce(),isDeactivatingScope=!1}}),!0)}function removeFocusListeners(){focusListenersInitialized&&=(document.removeEventListener(`uinav-focus`,onUINavFocus),document.removeEventListener(`uinav-blur`,onUINavBlur),!1)}function setup$3(){addFocusListeners()}function dispose$2(){removeFocusListeners()}return onMounted(()=>{setup$3()}),onBeforeUnmount(()=>{dispose$2()}),{setup:setup$3,dispose:dispose$2}}function isWithinDashmenu(target){return document.getElementById(`dashmenu`)?.contains(target)}function isWithinPopup(target){return!!target.closest(`dialog`)}function shouldSkipFocusHandling(scopedNavProps){return scopedNavProps?.type===SCOPED_NAV_TYPES.popover}function shouldHandleBlur(scopeProperties,currScope){return scopeProperties?.isScopedNav&&currScope?.scopeId===scopeProperties.scopeId&&currScope?.activationType===SCOPED_NAV_STATES.partial}function handleFocusAction(target,targetScope,scopeElement,scopedNavStore){if(!document.contains(target)&&!document.contains(scopeElement))return;let activeScope=scopedNavStore.currentScope();if(activeScope?.element===target)return;let existingScope,scopes=scopedNavStore.getScopes();for(let i=scopes.length-1;i>=0;i--){let scope$1=scopes[i];if(scope$1.element===scopeElement){existingScope=scope$1;break}}if(existingScope&&activeScope&&existingScope.scopeId!==activeScope.scopeId){scopedNavStore.resumeScope(existingScope.scopeId);return}scopes=scopedNavStore.getScopes();for(let i=scopes.length-1;i>=0;i--){let scope$1=scopes[i];if(scope$1.element===target||scope$1.element.contains(target)||scopeElement===scope$1.element||scope$1.element.contains(scopeElement))break;scopedNavStore.deactivateScope(scope$1.scopeId)}if(scopes=scopedNavStore.getScopes(),targetScope&&targetScope.isScopedNav){let lastScope=scopes.length>0?scopes[scopes.length-1]:null;lastScope&&activeScope&&activeScope.scopeId===lastScope.scopeId&&targetScope.scopeId!==lastScope.scopeId&&lastScope.activationType!==SCOPED_NAV_STATES.suspended&&scopedNavStore.suspendScope(lastScope.scopeId,{scopeId:targetScope.scopeId,scopeElement}),(!activeScope||activeScope.scopeId!==targetScope.scopeId)&&scopeElement._bngScopedNav.canActivate()&&scopedNavStore.activateScope(targetScope.scopeId,scopeElement)}if(target.hasAttribute(`bng-scoped-nav`)){let allowPartialActivation=target[SCOPED_NAV_PROPERTY_NAME].passthroughEnabled,canActivate=target[SCOPED_NAV_PROPERTY_NAME].canActivate();if(target[SCOPED_NAV_PROPERTY_NAME].passthroughActive=!0,allowPartialActivation&&canActivate){let partialScope=getScopeProperties(target);scopedNavStore.activateScope(partialScope.scopeId,target,{activationType:SCOPED_NAV_STATES.partial})}}}var PROPERTY_NAME=`_bngScopedNav`,ATTR_NAME=`bng-scoped-nav`,AUTOFOCUS_ATTR=`bng-scoped-nav-autofocus`,UI_SCOPE_ATTR=`bng-ui-scope`,NAV_ITEM_ATTR=`bng-nav-item`,BNG_ON_UI_NAV_ATTR=`__BngOnUiNav`,DEFAULT_AUTO_FOCUS_DELAY=100,EVENTS_UINAV_MAP={activate:[UI_EVENTS.ok],deactivate:[UI_EVENTS.back],navigation:[...UI_EVENT_GROUPS.focusMove,...UI_EVENT_GROUPS.focusMoveScalar]},NAV_EVENTS={activate:`activate`,deactivate:`deactivate`,suspend:`suspend`,resume:`resume`};const ACTIONS_ON_SUSPEND={allowNavigationLastNavItem:`allowNavigationLastNavItem`,allowNavigationByAttribute:`allowNavigationByAttribute`,disableNavigation:`disableNavigation`};var BngScopedNav_default={beforeMount,mounted,updated,beforeUnmount,unmounted},getDefaultOptions=()=>({type:SCOPED_NAV_TYPES.normal,activateOnMount:!1,actionsOnSuspend:[ACTIONS_ON_SUSPEND.disableNavigation],bubbleWhitelistEvents:[],bubbleBlacklistEvents:[],forcePassthroughEvents:[],canActivate:()=>!0,canDeactivate:()=>!0,autoFocusDelay:DEFAULT_AUTO_FOCUS_DELAY}),canBubbleEventInternal=(el,e)=>{let{bubbleWhitelistEvents,canBubbleEvent}=el[PROPERTY_NAME];return canBubbleEvent&&typeof canBubbleEvent==`function`?canBubbleEvent(e):bubbleWhitelistEvents&&Array.isArray(bubbleWhitelistEvents)&&bubbleWhitelistEvents.length>0?bubbleWhitelistEvents.includes(e.detail.name):!1},shouldBubbleToNextScope=(el,e)=>{let currentScope=useScopedNav().currentScope(),{scopeId,type}=el[PROPERTY_NAME],isActive=currentScope&¤tScope.scopeId===scopeId,isPartial=isActive&¤tScope.activationType===SCOPED_NAV_STATES.partial,isContainer=type===SCOPED_NAV_TYPES.container,isInactiveAndFocused=document.activeElement===el&&!isActive;return!currentScope||isInactiveAndFocused||canBubbleEventInternal(el,e)||isPartial||isContainer},getOptions=(el,binding,vnode)=>{let options={...getDefaultOptions(),...binding.value};if(!Object.values(SCOPED_NAV_TYPES).includes(options.type)){console.error(`Invalid scoped nav type: ${options.type}`);return}return options},applyOptions=(el,options)=>{let attributes={};switch(options.type){case SCOPED_NAV_TYPES.normal:attributes[NAV_ITEM_ATTR]=``,attributes[NO_CHILD_NAV_ATTR]=`true`;break;case SCOPED_NAV_TYPES.nonav:attributes[NO_NAV_ATTR]=`true`,attributes[NO_CHILD_NAV_ATTR]=`true`;break}Object.keys(attributes).forEach(attr=>el.setAttribute(attr,attributes[attr]))},findAutoFocusItem=navItems=>navItems.find(item=>item.hasAttribute(AUTOFOCUS_ATTR)&&item.getAttribute(AUTOFOCUS_ATTR)!==`false`),getAutoFocusItem=el=>findAutoFocusItem(getNavItems(el)),getFirstOrDefaultNavItem=el=>{let navItems,isAutoFocusItem=!1,getNavItems$1=()=>navItems||=getNavItems(el),getLastActive=()=>{let elm=el[PROPERTY_NAME].lastActiveElement;return elm&&!document.contains(elm)?null:elm},getAutoFocus=()=>{let elm=findAutoFocusItem(getNavItems$1());return elm&&!isNavigable(elm)?null:(isAutoFocusItem=!!elm,elm)},getFirst=()=>getNavItems$1()[0],sequence=[getLastActive,getAutoFocus];el[PROPERTY_NAME].preferAutoFocus&&sequence.reverse(),sequence.push(getFirst);for(let func of sequence){let elm=func();if(elm)return{focusItem:elm,isAutoFocusItem}}return{focusItem:null,isAutoFocusItem:!1}},setEnabledNavigation=(el,enabled,settings$1={applyToChildItems:!1,filterElements:void 0})=>{let{type}=el[PROPERTY_NAME];if(type===SCOPED_NAV_TYPES.nonav){logger_default.warn(`Cannot toggle navigation settings for nonav type`,el,enabled,type);return}settings$1.applyToChildItems?getNavItems(el,!1).forEach(item=>{if(!(settings$1.filterElements&&settings$1.filterElements.includes(item))){if(!item[PROPERTY_NAME]){let currentValue=item.hasAttribute(`bng-no-nav`)?item.getAttribute(NO_NAV_ATTR):void 0;item[PROPERTY_NAME]={originalNoNav:currentValue,hadOriginalNoNav:currentValue!==void 0}}enabled?(item[PROPERTY_NAME].hadOriginalNoNav?item.setAttribute(NO_NAV_ATTR,item[PROPERTY_NAME].originalNoNav):item.removeAttribute(NO_NAV_ATTR),item[PROPERTY_NAME].noNavSetByDirective=!1):(!item[PROPERTY_NAME].hadOriginalNoNav||item[PROPERTY_NAME].originalNoNav!==`true`)&&(item.setAttribute(NO_NAV_ATTR,`true`),item[PROPERTY_NAME].noNavSetByDirective=!0)}}):enabled?(el.removeAttribute(NO_CHILD_NAV_ATTR),type===SCOPED_NAV_TYPES.normal&&el.setAttribute(NO_NAV_ATTR,`true`)):(el.setAttribute(NO_CHILD_NAV_ATTR,`true`),type===SCOPED_NAV_TYPES.normal&&el.removeAttribute(NO_NAV_ATTR))},focusFirstOrDefaultNavItem=el=>{let{autoFocusDelay}=el[PROPERTY_NAME];nextTick(()=>{setTimeout(()=>{let{focusItem,isAutoFocusItem}=getFirstOrDefaultNavItem(el);focusItem&&setFocusExternal(focusItem,!0,isAutoFocusItem)},autoFocusDelay)})},ensureFocusOrFocusDefault=el=>{document.activeElement&&isDirectChild(el,document.activeElement)?ensureFocus(document.activeElement,!0):focusFirstOrDefaultNavItem(el)};function beforeMount(el,binding,vnode){let options=getOptions(el,binding,vnode);if(!options)return;let scopeId=options.scopeId||uniqueId(`scoped-nav`);el[PROPERTY_NAME]={scopeId,...options},el[PROPERTY_NAME].shouldBubbleEvent=e=>shouldBubbleToNextScope(el,e),el.setAttribute(ATTR_NAME,scopeId),el.setAttribute(UI_SCOPE_ATTR,scopeId),applyOptions(el,options)}function mounted(el,binding,vnode){addUINavEventListeners(el,binding,vnode),addScopedNavEventListeners(el);let scopedNav=useScopedNav(),options=getOptions(el,binding,vnode);options.type===SCOPED_NAV_TYPES.normal?configurePartialActivation(el):options.type===SCOPED_NAV_TYPES.container&&configureContainer(el,!1),options.activateOnMount&&nextTick(()=>scopedNav.activateScope(el[PROPERTY_NAME].scopeId,el))}var handleDefaultUpdate=(el,binding,vnode)=>{let activeScope=useScopedNav().currentScope(),{scopeId,type}=el[PROPERTY_NAME];!activeScope||activeScope.scopeId!==scopeId||activeScope.activationType!==SCOPED_NAV_STATES.active||ensureFocusOrFocusDefault(el)};function updated(el,binding,vnode){let options=getOptions(el,binding,vnode),{scopeId}=el[PROPERTY_NAME],scopedNav=useScopedNav();if(options.activated===!0&&!scopedNav.isActiveScope(scopeId))if(scopedNav.getScopeById(scopeId)){let popover=usePopover();if(Object.values(popover.popovers).filter(x=>x.show===!0).length>0)return;scopedNav.resumeScope(scopeId,el)}else scopedNav.activateScope(scopeId,el,{activationType:SCOPED_NAV_STATES.active,suspendParentScopes:!0});else options.activated===!1&&scopedNav.isActiveScope(scopeId)?scopedNav.deactivateScope(scopeId,{resumePrevious:!0}):!scopedNav.isActiveScope(scopeId)&&options.type===SCOPED_NAV_TYPES.container&&configureContainer(el,!1);nextTick(()=>{let activeScope=scopedNav.currentScope();activeScope&&activeScope.scopeId===scopeId&&handleDefaultUpdate(el,binding,vnode)})}function beforeUnmount(el,binding,vnode){removeScopedNavEventListeners(el);let scopedNav=useScopedNav();if(scopedNav.getScopeById(el[PROPERTY_NAME].scopeId)){let{type}=el[PROPERTY_NAME];scopedNav.deactivateScope(el[PROPERTY_NAME].scopeId,{resumePrevious:type===SCOPED_NAV_TYPES.popover}),el.dispatchEvent(new CustomEvent(NAV_EVENTS.deactivate,{detail:{force:!0,reason:`unmounted`}}))}}function unmounted(el,binding,vnode){}var handlePartialActivation=(el,event)=>{el[PROPERTY_NAME].forceBubble=!0},handleNormalActivation=(el,event)=>{el[PROPERTY_NAME].forceBubble=!1,nextTick(()=>{setEnabledNavigation(el,!0),(!document.activeElement||el===document.activeElement||!el.contains(document.activeElement))&&focusFirstOrDefaultNavItem(el)})},configurePartialActivation=el=>{let passthroughEvents=getPassthroughEvents(el);el[PROPERTY_NAME].passthroughEnabled=passthroughEvents.length>0,el[PROPERTY_NAME].passthroughEvents=passthroughEvents},configureContainer=(el,activated)=>{el[PROPERTY_NAME].containerSetup&&el[PROPERTY_NAME].containerSetup.cancel(),el[PROPERTY_NAME].containerSetup=debounce(()=>{let autoFocusItem=getAutoFocusItem(el);autoFocusItem&&setEnabledNavigation(el,activated,{applyToChildItems:!0,filterElements:[autoFocusItem]})},100),el[PROPERTY_NAME].containerSetup()},handleContainerActivation=(el,event)=>{configureContainer(el,!0)},handleNoNavActivation=(el,event)=>{},onActivate=(el,event)=>{let{type}=el[PROPERTY_NAME],{activationType}=event.detail;activationType===SCOPED_NAV_STATES.partial?handlePartialActivation(el,event):type===SCOPED_NAV_TYPES.normal?handleNormalActivation(el,event):type===SCOPED_NAV_TYPES.container?handleContainerActivation(el,event):SCOPED_NAV_TYPES.nonav,el.dispatchEvent(new CustomEvent(NAV_EVENTS.activate,{detail:event.detail}))},onDeactivate=(el,event)=>{let{type}=el[PROPERTY_NAME];type===SCOPED_NAV_TYPES.normal&&event.detail.activationType===SCOPED_NAV_STATES.active?setEnabledNavigation(el,!1):type===SCOPED_NAV_TYPES.container&&configureContainer(el,!1),el[PROPERTY_NAME].forceBubble=!1,el.dispatchEvent(new CustomEvent(NAV_EVENTS.deactivate,{detail:event.detail}))},onSuspend=(el,event)=>{let{actionsOnSuspend,type}=el[PROPERTY_NAME],filterElements=[];if(actionsOnSuspend.includes(ACTIONS_ON_SUSPEND.allowNavigationLastNavItem)){let lastActiveElement=el[PROPERTY_NAME].lastActiveElement;lastActiveElement&&document.contains(lastActiveElement)&&filterElements.push(lastActiveElement)}setEnabledNavigation(el,!1,{applyToChildItems:!0,filterElements})},onResume=(el,event)=>{let{actionsOnSuspend,type}=el[PROPERTY_NAME],filterElements=[];if(actionsOnSuspend.includes(ACTIONS_ON_SUSPEND.allowNavigationLastNavItem)){let lastActiveElement=el[PROPERTY_NAME].lastActiveElement;lastActiveElement&&document.contains(lastActiveElement)&&filterElements.push(lastActiveElement)}setEnabledNavigation(el,!0,{applyToChildItems:!0,filterElements}),ensureFocusOrFocusDefault(el)};function addScopedNavEventListeners(el){let eventHandlers={[SCOPED_NAV_EVENTS.activate]:event=>onActivate(el,event),[SCOPED_NAV_EVENTS.deactivate]:event=>onDeactivate(el,event),[SCOPED_NAV_EVENTS.suspend]:event=>onSuspend(el,event),[SCOPED_NAV_EVENTS.resume]:event=>onResume(el,event)};Object.keys(eventHandlers).forEach(eventName=>{el[PROPERTY_NAME].scopedNavListeners||(el[PROPERTY_NAME].scopedNavListeners={}),el.addEventListener(eventName,eventHandlers[eventName]),el[PROPERTY_NAME].scopedNavListeners[eventName]=eventHandlers[eventName]})}function removeScopedNavEventListeners(el){!el||!el[PROPERTY_NAME]||!el[PROPERTY_NAME].scopedNavListeners||Object.keys(el[PROPERTY_NAME].scopedNavListeners).forEach(eventName=>{el.removeEventListener(eventName,el[PROPERTY_NAME].scopedNavListeners[eventName]),delete el[PROPERTY_NAME].scopedNavListeners[eventName]})}var allowsNavigation=el=>{let{type}=el[PROPERTY_NAME];return[SCOPED_NAV_TYPES.normal,SCOPED_NAV_TYPES.container,SCOPED_NAV_TYPES.popover].includes(type)},processNavigationEvent=(el,e)=>{let currentScope=useScopedNav().currentScope(),{scopeId}=el[PROPERTY_NAME];if(!allowsNavigation(el))return!1;document.activeElement===el&¤tScope.scopeId===scopeId?focusFirstOrDefaultNavItem(el):handleUINavEvent(e,el)},isNavigationEvent=e=>UI_EVENT_GROUPS.navigation.includes(e.detail.name),getUINavEventsByEl=el=>{let uiNavEvents=el[BNG_ON_UI_NAV_ATTR]?Object.values(el[BNG_ON_UI_NAV_ATTR]).map(x=>x.eventNames).flat():[],boundEvents=[];return uiNavEvents.forEach(ev=>{boundEvents.includes(ev)||boundEvents.push(ev)}),boundEvents},hasBoundEvent=(el,eventName)=>{let boundEvents=getUINavEventsByEl(el);return boundEvents&&boundEvents.length>0&&boundEvents.includes(eventName)},isUINavEventBoundToChild=(el,e)=>{let{scopeId}=el[PROPERTY_NAME],currentScope=useScopedNav().currentScope();return currentScope&¤tScope.scopeId===scopeId&&e.target!==el&&el.contains(e.target)&&e.target===document.activeElement&&hasBoundEvent(e.target,e.detail.name)},generalHandler=(el,e)=>{let shouldBubble=!1;return isUINavEventBoundToChild(el,e)&&!e.target.hasAttribute(ATTR_NAME)||(shouldBubbleToNextScope(el,e)?shouldBubble=!0:isNavigationEvent(e)&&processNavigationEvent(el,e)),shouldBubble},processOkChildHandler=(el,e)=>{isUINavEventBoundToChild(el,e)||(handleUINavEvent(e,e.target),e.detail.sendToCrossfire=!1)},okHandler=(el,e)=>{if(e.detail.value!==1)return shouldBubbleToNextScope(el,e);let scopedNav=useScopedNav(),scopeId=el[PROPERTY_NAME].scopeId,currentScope=scopedNav.currentScope();return currentScope&¤tScope.scopeId===scopeId&¤tScope.activationType===SCOPED_NAV_STATES.active&&(document.activeElement&&isDirectChild(el,document.activeElement)||e.target&&isDirectChild(el,e.target))?processOkChildHandler(el,e):el[PROPERTY_NAME].canActivate()&&el[PROPERTY_NAME].type===SCOPED_NAV_TYPES.normal&&document.activeElement===el&&scopedNav.activateScope(scopeId,el),shouldBubbleToNextScope(el,e)},backHandler=(el,e)=>{if(e.detail.value!==1)return;let scopedNav=useScopedNav(),{scopeId,type,canDeactivate}=el[PROPERTY_NAME],currentScope=scopedNav.currentScope();if(currentScope&¤tScope.scopeId===scopeId&¤tScope.activationType===SCOPED_NAV_STATES.active)canDeactivate()&&(scopedNav.deactivateScope(scopeId,{resumePrevious:!0,executingScope:scopeId}),type===SCOPED_NAV_TYPES.normal&&nextTick(()=>setFocusExternal(el)));else if(e.target!==el&&isDirectChild(el,e.target))return!1;else return!0},uiNavEventsHandler=(el,e)=>{let uiNavEvent=e.detail.name;return EVENTS_UINAV_MAP.activate.includes(uiNavEvent)?okHandler(el,e):EVENTS_UINAV_MAP.deactivate.includes(uiNavEvent)?backHandler(el,e):generalHandler(el,e)};function addUINavEventListeners(el,binding,vnode){let{bubbleWhitelistEvents}=el[PROPERTY_NAME],generalUINavBinding={arg:[...EVENTS_UINAV_MAP.activate,...EVENTS_UINAV_MAP.deactivate,...EVENTS_UINAV_MAP.navigation].join(`,`),value:e=>uiNavEventsHandler(el,e)};BngOnUiNav_default.mounted(el,generalUINavBinding,vnode)}var ID=`__bngSound`,ID_STOP=`__bngSoundStop`,events$1={click:`click`,dblclick:`dblclick`,focus:`focus`,mouseenter:`mouseenter`};function handler(ev){let el=ev.currentTarget;if(el&&(el[ID]&&events$1[ev.type]&&Lua_default.ui_audio.playEventSound(el[ID],events$1[ev.type]),el[ID_STOP]))for(let event in delete el[ID_STOP],delete el[ID],events$1)el.removeEventListener(event,handler)}var BngSoundClass_default={mounted:(el,binding)=>{delete el[ID_STOP],el[ID]=binding.value,nextTick(()=>{for(let event in events$1)el.addEventListener(event,handler)})},updated:(el,binding)=>{el[ID]=binding.value},unmounted:el=>{el[ID_STOP]=!0}},marker=`__BNG_SD_INPUT`,inputTypes={singleLine:0,multiLine:1};function bindToInputs(elements){let inputs=Array.isArray(elements)?elements:[elements];for(let input of inputs){if(marker in input)continue;input[marker]=!0;let type,tag=input.tagName.toLowerCase();if(tag===`textarea`)type=inputTypes.multiLine;else if(tag===`input`&&[`text`,`number`,`password`,`search`].includes(input.type.toLowerCase()))type=inputTypes.singleLine;else continue;input.addEventListener(`focus`,()=>{let rect=input.getBoundingClientRect();console.log(`SteamDeck input focus:`,type,rect),Lua_default.Steam.showFloatingGamepadTextInput(type,rect.left,rect.top,rect.width,rect.height)})}}async function useSteamDeckInput(inputs){if(!inputs)throw Error(`inputs must be specified (ref, refs, element, elements)`);(await useSettingsAsync()).values.runningOnSteamDeck&&(isRef(inputs)?watch(inputs,bindToInputs,{immediate:!0}):bindToInputs(inputs))}var bridge$1,focused=!1,elms={},elmid=`__BNG_TEXT_INPUT`,focus=id=>async()=>{elms[id].active=!0,focused||=(await bridge$1.lua.setCEFTyping(!0),!0)},blur=id=>async()=>{elms[id].active=!1,focused&&(focused=Object.values(elms).some(e=>e.active),focused||await bridge$1.lua.setCEFTyping(!1))},BngTextInput_default={mounted(el){bridge$1||(bridge$1=useBridge(),bridge$1.events.on(`CEFTypingLostFocus`,()=>focused&&document.activeElement.blur()));let id=el[elmid]||(el[elmid]=uniqueId());elms[id]={el,active:!1,onFocus:focus(id),onBlur:blur(id)},el.addEventListener(`focus`,elms[id].onFocus),el.addEventListener(`blur`,elms[id].onBlur),useSteamDeckInput(el)},beforeUnmount(el){let id=el[elmid];elms[id]&&(el.removeEventListener(`focus`,elms[id].onFocus),el.removeEventListener(`blur`,elms[id].onBlur),elms[id].onBlur(),delete elms[id])}},DEFAULT_POSITION=`left`,TOOLTIP_ATTR_NAME=`data-bng-tooltip`,CONTENT_ATTR_NAME=`data-bng-tooltip-content`,ARROW_ATTR_NAME=`data-bng-tooltip-arrow`,SHOW_TOOLTIP_EVENTS=[`mouseover`,`focusin`],HIDE_TOOLTIP_EVENTS=[`mouseout`,`focusout`],DATA_PROP=`__bngTooltip`,POPOVER_CONTAINER=`.popover-container`,BngTooltip_default={beforeMount(el){initTooltipData(el)},mounted(el,binding,vnode){setupBindings(el,binding),setupTooltip(el),setListeners(el)},beforeUpdate(el,binding){setupBindings(el,binding),el[DATA_PROP].text===void 0?removeTooltip(el):updateTooltipElement(el)},updated(el){let data=el[DATA_PROP];data.update&&requestAnimationFrame(()=>data.update())},beforeUnmount(el){SHOW_TOOLTIP_EVENTS.forEach(eventName=>el.removeEventListener(eventName,el.__showTooltip)),HIDE_TOOLTIP_EVENTS.forEach(eventName=>el.removeEventListener(eventName,el.__hideTooltip));let data=el[DATA_PROP];data.dispose&&data.dispose(),removeTooltip(el)}};function setListeners(el){let data=el[DATA_PROP];data.showTooltip||(data.showTooltip=event=>{data.hideDelay&&=(clearTimeout(data.hideDelay),null),data.tooltipAnimationFrame&&=(cancelAnimationFrame(data.tooltipAnimationFrame),null),el.contains(event.target)&&!data.tooltipElRef.value&&queueTooltipUpdate(el,!0)},SHOW_TOOLTIP_EVENTS.forEach(eventName=>el.addEventListener(eventName,data.showTooltip,!0))),data.hideTooltip||(data.hideTooltip=event=>{data.tooltipAnimationFrame&&=(cancelAnimationFrame(data.tooltipAnimationFrame),null),!el.contains(event.relatedTarget)&&data.tooltipElRef.value&&queueTooltipUpdate(el,!1)},HIDE_TOOLTIP_EVENTS.forEach(eventName=>el.addEventListener(eventName,data.hideTooltip,!0)))}function setupBindings(el,binding){if(binding.value){let bindingValues=getBindings(binding);el[DATA_PROP].text=bindingValues.text,el[DATA_PROP].hideDelayTime=bindingValues.hideDelay,el[DATA_PROP].position=bindingValues.position,el[DATA_PROP].isBBCode=bindingValues.isBBCode,el[DATA_PROP].style=bindingValues.style}else resetTooltipData(el)}function queueTooltipUpdate(el,shouldShow){let data=el[DATA_PROP];data.tooltipAnimationFrame&&cancelAnimationFrame(data.tooltipAnimationFrame),data.pendingTooltipState=shouldShow,data.tooltipAnimationFrame=requestAnimationFrame(()=>{data.pendingTooltipState?showTooltip(el):hideTooltip(el),data.tooltipAnimationFrame=null,data.pendingTooltipState=null})}function showTooltip(el){let data=el[DATA_PROP];data.text&&(addTooltip(el),usePopover().show(data.popoverName,el))}function hideTooltip(el){let data=el[DATA_PROP],hideFn=()=>{removeTooltip(el)};data.hideDelayTime&&typeof data.hideDelayTime==`number`&&data.hideDelayTime>0?data.hideDelay=setTimeout(()=>{hideFn(),data.hideDelay=null},data.hideDelayTime):hideFn()}function setupTooltip(el){let data=el[DATA_PROP],popover=usePopover(),popoverInstance=popover.register(data.popoverName,data.tooltipElRef,data.position,{arrow:data.arrowElRef,offset:4});if(!popoverInstance){console.error(`Failed to register tooltip`);return}el[DATA_PROP].update=popoverInstance.update,el[DATA_PROP].dispose=()=>popover.unregister(data.popoverName),popover.bind(data.popoverName,el,{placement:data.position})}function updateTooltipElement(el){if(el[DATA_PROP].tooltipElRef.value&&el[DATA_PROP].tooltipElRef.value){let updatedContent=parseText(el[DATA_PROP].text,el[DATA_PROP].isBBCode),spanEl=el[DATA_PROP].tooltipElRef.value.querySelector(`span`);spanEl.innerHTML=updatedContent}}function addTooltip(el){let data=el[DATA_PROP];data.tooltipElRef.value=createTooltip(data);let popoverContainer=document.querySelector(POPOVER_CONTAINER);popoverContainer||=(console.warn(`Popover container not found, using parent element`),el.parentElement),el[DATA_PROP].arrowElRef.value=createArrow(),data.tooltipElRef.value.appendChild(el[DATA_PROP].arrowElRef.value),popoverContainer.appendChild(data.tooltipElRef.value)}function removeTooltip(el){let data=el[DATA_PROP];usePopover().hide(data.popoverName),data.tooltipElRef.value&&(data.tooltipElRef.value.remove(),data.tooltipElRef.value=null),data.update&&data.update()}function createTooltip(data){let container=document.createElement(`div`);return data.style&&Object.keys(data.style).forEach(key=>container.style.setProperty(key,data.style[key])),container.setAttribute(TOOLTIP_ATTR_NAME,``),container.appendChild(createContent(data.text,data.isBBCode)),container}function createContent(text,isBBCode){let content=document.createElement(`span`);return Object.assign(content.style,{}),content.innerHTML=parseText(text,isBBCode),content.setAttribute(CONTENT_ATTR_NAME,``),content}function createArrow(){let arrow$3=document.createElement(`span`);return Object.assign(arrow$3.style,{}),arrow$3.setAttribute(ARROW_ATTR_NAME,``),arrow$3}function parseText(text,isBBCode){return isBBCode?parse$1(text):text}var getBindings=binding=>{let position=binding.arg?binding.arg:DEFAULT_POSITION,hideDelay,text,isBBCode=!1,style={};return typeof binding.value==`object`?(hideDelay=binding.value?.hideDelay||0,text=binding.value?.text||void 0,isBBCode=binding.value?.isBBCode||!1,style=binding.value?.style||{}):text=binding.value,{text,position,hideDelay,isBBCode,style}};function initTooltipData(el){el[DATA_PROP]={popoverName:uniqueId(`bng-tooltip`),tooltipElRef:ref(null),arrowElRef:ref(null)},resetTooltipData(el)}function resetTooltipData(el){el[DATA_PROP].text=void 0,el[DATA_PROP].style={},el[DATA_PROP].isBBCode=!1,el[DATA_PROP].hideDelayTime=void 0,el[DATA_PROP].position=void 0,el[DATA_PROP].hideDelay=null,el[DATA_PROP].tooltipAnimationFrame=null}var reg=(elm,{value})=>nextTick(()=>elm&&wantsFocus(elm,value)),BngUiNavFocus_default={mounted:reg,updated:reg,beforeUnmount:unwantsFocus},registry,procEventNames=eventNames=>eventNames.split(`,`).map(name=>name.trim()).filter(Boolean),BngUiNavLabel_default={mounted(el,{arg:eventNames,value:label}){if(!eventNames){console.warn(`Usage: v-bng-ui-nav-label:back,menu="'Back'"`);return}registry||=useUiNavLabel(),label&&(eventNames=procEventNames(eventNames),registry.registerLabel(el,eventNames,label))},updated(el,{arg:eventNames,value:label}){eventNames&&(eventNames=procEventNames(eventNames),label?registry.registerLabel(el,eventNames,label):registry.clearLabels(el,eventNames))},beforeUnmount(el){let events$3=registry.getElementEvents(el);events$3.length>0&®istry.clearLabels(el,events$3)}},SCROLL_PROP=`__bngUiNavScroll`;function enableScroll(id,el){let tracker=useUINavTracker();tracker.addEvent(SCROLL_EVENT_H,id,el),tracker.addEvent(SCROLL_EVENT_V,id,el),tracker.addForceUnblock(SCROLL_EVENT_H,id),tracker.addForceUnblock(SCROLL_EVENT_V,id)}function disableScroll(id,el){let tracker=useUINavTracker();tracker.removeEvent(SCROLL_EVENT_H,id,el),tracker.removeEvent(SCROLL_EVENT_V,id,el),tracker.removeForceUnblock(SCROLL_EVENT_H,id),tracker.removeForceUnblock(SCROLL_EVENT_V,id)}var BngUiNavScroll_default={mounted(element,{arg,value,modifiers}){let prev=element[SCROLL_PROP]||{},dir={id:prev.id||uniqueId(SCROLL_PROP),forced:modifiers.force,enable:()=>enableScroll(dir.id,element),disable:()=>disableScroll(dir.id,element)};if(element[SCROLL_PROP]=dir,prev.forced&&(element.removeEventListener(`focusin`,prev.enable),element.removeEventListener(`focusout`,prev.disable)),typeof value==`boolean`&&!value){prev.id&&prev.disable(),dir.forced=!1;return}dir.forced?(element.setAttribute(SCROLL_FORCE_ATTR,``),dir.enable()):(element.setAttribute(SCROLL_ATTR,``),element.addEventListener(`focusin`,dir.enable),element.addEventListener(`focusout`,dir.disable))},beforeUnmount(element){let dir=element[SCROLL_PROP];dir&&(dir.forced||(element.removeEventListener(`focusin`,dir.enable),element.removeEventListener(`focusout`,dir.disable)),dir.disable(),delete element[SCROLL_PROP])}},observed=new WeakMap;function createObserver(root=null,rootMargin=`0px`){return new IntersectionObserver(entries=>{for(let entry of entries){let data=observed.get(entry.target);if(!data){entry.target.observer?.unobserve(entry.target);return}if(data.onChange)data.onChange(entry.isIntersecting);else{let displayValue=entry.isIntersecting?[`display`,``,``]:[`display`,`none`,`important`];entry.target.style.setProperty(...displayValue),entry.target.querySelectorAll(`*`).forEach(child=>{child.style.setProperty(...displayValue)})}}},{root,rootMargin,threshold:0})}var defaultObserver=createObserver(),_sfc_main$404={__name:`bngActionDrawer`,props:{actions:{type:Object,default:{allowOpenDrawer:!1}},skeletonItems:{type:Number,default:5},usePath:Boolean,alwaysShowBack:Boolean,itemWidth:Number,itemHeight:Number,itemMargin:Number,big:Boolean,position:String,blur:Boolean},emits:[`select`],setup(__props,{expose:__expose,emit:__emit}){let props=__props,emit$1=__emit;__expose({goBack:onBack});let expanded=ref(!1),current=ref(props.actions),lazyItem={label:`…`,icon:icons.stopwatchSectionOutlinedStart};function onSelect(item){(`items`in item||item.lazyLoadItems)&&(current.value&&addBack(current.value),current.value=item),emit$1(`select`,item)}let backState=computed(()=>{let disable=back.value.length===0||!(`items`in current.value);return{show:!disable||props.alwaysShowBack,disable}}),back=ref([]);function onBack(){current.value=null,onSelect(back.value.pop().data)}function addBack(prevItem){let backItem={index:back.value.length,label:prevItem.label,data:prevItem};props.usePath&&prevItem.items&&(backItem.items=prevItem.items.reduce((res,itm)=>[...res,{index:backItem.index+1,label:itm.label,data:itm}],[])),back.value.push(backItem)}let path=computed(()=>props.usePath?[...back.value,{current:!0,label:current.value.label,data:current.value}]:void 0);function onPath(item){item.current||(back.value.splice(item.index),current.value=null,onSelect(item.data))}return watch(()=>props.actions,val=>{back.value.splice(0),current.value=val}),(_ctx,_cache)=>(openBlock(),createBlock(unref(bngDrawer_default),{modelValue:expanded.value,"onUpdate:modelValue":_cache[0]||=$event=>expanded.value=$event,expandable:current.value.allowOpenDrawer,position:__props.position,blur:__props.blur},createSlots({"header-controls":withCtx(()=>[__props.usePath?(openBlock(),createBlock(unref(bngBreadcrumbs_default),{key:0,items:path.value,limit:`5`,onClick:onPath},null,8,[`items`])):backState.value.show?(openBlock(),createBlock(unref(bngButton_default),{key:1,accent:unref(ACCENTS).outlined,disabled:backState.value.disable,onClick:onBack},{default:withCtx(()=>[..._cache[1]||=[createTextVNode(`Back`,-1)]]),_:1},8,[`accent`,`disabled`])):createCommentVNode(``,!0),renderSlot(_ctx.$slots,`controls`)]),content:withCtx(()=>[withDirectives((openBlock(),createBlock(unref(bngList_default),{layout:expanded.value?unref(LIST_LAYOUTS).TILES:unref(LIST_LAYOUTS).RIBBON,big:__props.big,"target-width":__props.itemWidth,"target-height":__props.itemHeight,"target-margin":__props.itemMargin,"no-background":``},{default:withCtx(()=>[`items`in current.value?(openBlock(!0),createElementBlock(Fragment,{key:0},renderList(current.value.items,(item,index)=>renderSlot(_ctx.$slots,`action`,{item,select:onSelect,isLoading:!1,order:index})),256)):(openBlock(!0),createElementBlock(Fragment,{key:1},renderList(__props.skeletonItems,idx=>renderSlot(_ctx.$slots,`action`,{item:lazyItem,select:()=>{},isLoading:!0})),256))]),_:3},8,[`layout`,`big`,`target-width`,`target-height`,`target-margin`])),[[unref(BngDisabled_default),!(`items`in current.value)]])]),_:2},[__props.usePath?void 0:{name:`header`,fn:withCtx(()=>[createTextVNode(toDisplayString(current.value.label),1)]),key:`0`}]),1032,[`modelValue`,`expandable`,`position`,`blur`]))}},bngActionDrawer_default=_sfc_main$404,__plugin_vue_export_helper_default=(sfc,props)=>{let target=sfc.__vccOpts||sfc;for(let[key,val]of props)target[key]=val;return target},_hoisted_1$347={class:`bng-accordion-container`},_sfc_main$403={__name:`accordion`,props:{singular:Boolean,expanded:Boolean,disabled:Boolean,animated:Boolean,selectable:[Boolean,Object],selected:Boolean,provideParent:Boolean},emits:[`selected`],setup(__props,{emit:__emit}){let props=__props,counter$1=0,items$2=[],selopts=null,emit$1=__emit;watch(()=>props.singular,val=>val&&toggle(items$2.find(itm=>itm.expanded),!0)),watch(()=>props.expanded,val=>toggle(null,val)),watch(()=>props.animated,val=>{for(let itm of items$2)itm.animated=val},{immediate:!0}),watch(()=>props.disabled,val=>{for(let itm of items$2)itm.disabled=val},{immediate:!0}),watch(()=>props.selectable,val=>{val?(selopts={multi:!1},typeof val==`object`&&(selopts={selopts,...val})):selopts=null;for(let itm of items$2)itm.selectable=selopts},{immediate:!0}),watch(()=>props.selected,val=>select(null,val));function toggle(item=null,expanded=null){if(props.singular&&!item&&expanded){if(items$2.length===0)return;item=items$2[0]}for(let itm of items$2){let exp=!itm.expandedActual;item&&itm.id!==item.id?exp=props.singular?!1:itm.expandedActual:typeof expanded==`boolean`&&(exp=expanded),itm.expandedActual=exp}}provide(`accordion-item-toggle`,toggle);function select(item=null,selected=null){let state=[];for(let itm of items$2){let sel;sel=item&&itm.id!==item.id?selopts.multi?itm.selected:!1:typeof selected==`boolean`?selected:selopts.multi?!itm.selected:!0,itm.selected!==sel&&(itm.selected=sel,state.push(itm))}state.length>0&&emit$1(`selected`,state)}provide(`accordion-item-select`,select),props.provideParent&&inject(`accordion-item-childSelect`)(select);let waitForOptions=cb=>selopts?cb():setTimeout(()=>waitForOptions(cb),50);return provide(`accordion-item-register`,item=>{item.id=counter$1++,props.expanded&&(item.expanded=props.expanded),props.disabled&&(item.disabled=props.disabled),props.selectable&&(item.selectable=props.selectable),items$2.push(item),waitForOptions(()=>{props.singular&&item.expanded&&toggle(item,!0),item.selected&&select(item,!0)})}),provide(`accordion-item-unregister`,item=>{let idx=items$2.findIndex(itm=>itm.id===item.id);idx>-1&&items$2.splice(idx,1)}),(_ctx,_cache)=>withDirectives((openBlock(),createElementBlock(`div`,_hoisted_1$347,[renderSlot(_ctx.$slots,`default`,{},void 0,!0)])),[[unref(BngDisabled_default),__props.disabled]])}},accordion_default=__plugin_vue_export_helper_default(_sfc_main$403,[[`__scopeId`,`data-v-fcd1832d`]]),_hoisted_1$346={key:0,class:`bng-accitem-content`},_sfc_main$402={__name:`accordionItem`,props:{static:Boolean,expanded:Boolean,disabled:Boolean,animated:Boolean,selectable:{type:[Boolean,Object],default:!1},selected:Boolean,data:{},navigable:{type:[Boolean,Object],default:!1},arrowBig:Boolean,primaryAction:Function,secondaryAction:Function,primaryLabel:String,secondaryLabel:String,primaryHintInline:Boolean,secondaryHintInline:Boolean,expandHintInline:Boolean},emits:[`focus`,`unfocus`,`expanded`,`selected`],setup(__props,{expose:__expose,emit:__emit}){let{showIfController}=storeToRefs(controls_default()),navBlocker=useUINavBlocker(),props=__props,elCaption=ref(),elCaptionContent=ref(),elCaptionControls=ref(),hasFocus=ref(!1),icon=computed(()=>props.arrowBig?icons.arrowLargeRight:icons.arrowSmallRight),popTip=ref();watch([()=>hasFocus.value,()=>showIfController.value],()=>{hasFocus.value&&showIfController.value&&(props.primaryHintInline&&props.primaryAction||props.secondaryHintInline&&props.secondaryAction)?popTip.value.show(elCaption.value):popTip.value.isShown()&&popTip.value.hide()});let reg$1=inject(`accordion-item-register`),unreg=inject(`accordion-item-unregister`),toggle=inject(`accordion-item-toggle`),select=inject(`accordion-item-select`),opts=reactive({id:-1,captionClick:evt=>{props.primaryAction&&evt.fromController?props.primaryAction():opts.selectable?select(opts):opts.expandClick()},expandClick:()=>!props.static&&toggle(opts),static:props.static,expandedActual:props.expanded,disabled:props.disabled,animated:props.animated,selected:props.selected,selectable:props.selectable,navigable:{enabled:!1},data:props.data}),emit$1=__emit;__expose({captionClick:opts.captionClick,focus:()=>setFocusExternal(elCaption.value,!0,!1),captionElement:computed(()=>elCaption.value)}),watch(()=>props.static,val=>opts.static=val),watch(()=>props.expanded,val=>!opts.static&&toggle(opts,val)),watch(()=>props.disabled,val=>opts.disabled=val),watch(()=>opts.disabled,val=>!val&&props.disabled&&(opts.disabled=props.disabled)),watch(()=>props.animated,val=>opts.animated=val),watch(()=>props.selectable,val=>opts.selectable=val),watch(()=>props.selected,val=>opts.selected=val),watch(()=>opts.expandedActual,val=>{emit$1(`expanded`,!opts.static&&!opts.disabled&&val)}),watch(()=>props.data,val=>opts.data=val),watch(()=>props.navigable,val=>{if(typeof val!=`object`&&typeof val==`boolean`&&!val){opts.navigable={enabled:!1};return}opts.navigable={enabled:!0,scope:null,...typeof val==`object`?val:{}}},{immediate:!0}),opts.navigable.scope&&useUINavScope(opts.navigable.scope);let onFocus=evt=>{hasFocus.value=!0,navBlocker.blockOnly(opts.static?[`context`]:[]),emit$1(`focus`,evt)},onLoseFocus=evt=>{hasFocus.value=!1,navBlocker.clear(),emit$1(`unfocus`,evt)};return provide(`accordion-item-childSelect`,select$1=>(item,value)=>opts.selectable&&opts.selectable.multi&&select$1(item,value)),provide(`accordion-item-parent`,opts),onMounted(()=>reg$1(opts)),onBeforeUnmount(()=>{popTip.value.isShown()&&popTip.value.hide(),unreg(opts)}),(_ctx,_cache)=>withDirectives((openBlock(),createElementBlock(`div`,{class:normalizeClass({"bng-accitem":!0,"bng-accitem-normal":!opts.static&&!opts.selectable,"bng-accitem-static":opts.static,"bng-accitem-expandable":!opts.static,"bng-accitem-selectable":opts.selectable,"bng-accitem-expanded":!opts.static&&opts.expandedActual&&!opts.disabled,"bng-accitem-selected":opts.selected})},[withDirectives((openBlock(),createElementBlock(`div`,mergeProps({ref_key:`elCaption`,ref:elCaption,class:`bng-accitem-caption`,onClick:_cache[1]||=(...args)=>opts.captionClick&&opts.captionClick(...args),onFocus,onBlur:onLoseFocus},{"bng-nav-item":opts.navigable.enabled?!0:void 0,"bng-ui-scope":opts.navigable.scope||void 0}),[opts.static?createCommentVNode(``,!0):(openBlock(),createBlock(unref(bngIcon_default),{key:0,class:normalizeClass({"bng-accitem-caption-expander":!0,"bng-accitem-caption-expander-big":__props.arrowBig}),type:icon.value,onClick:withModifiers(opts.expandClick,[`stop`])},null,8,[`class`,`type`,`onClick`])),__props.expandHintInline&&!opts.static&&hasFocus.value&&unref(showIfController)?(openBlock(),createBlock(unref(bngBinding_default),{key:1,style:{"padding-right":`0.2em`},uiEvent:`context`,controller:``})):createCommentVNode(``,!0),createBaseVNode(`span`,{ref_key:`elCaptionContent`,ref:elCaptionContent,class:`bng-accitem-caption-content`},[renderSlot(_ctx.$slots,`caption`,{},()=>[_cache[2]||=createTextVNode(`Unnamed item`,-1)],!0)],512),_ctx.$slots.controls?(openBlock(),createElementBlock(`div`,{key:2,ref_key:`elCaptionControls`,ref:elCaptionControls,class:`bng-accitem-caption-controls`,onClick:_cache[0]||=withModifiers(()=>{},[`stop`])},[renderSlot(_ctx.$slots,`controls`,{},void 0,!0)],512)):createCommentVNode(``,!0),createVNode(unref(bngPopoverContent_default),{ref_key:`popTip`,ref:popTip,placement:`right`},{default:withCtx(()=>[__props.primaryHintInline&&__props.primaryAction?(openBlock(),createBlock(unref(bngBinding_default),{key:0,uiEvent:`ok`,controller:``})):createCommentVNode(``,!0),__props.secondaryHintInline&&__props.secondaryAction?(openBlock(),createBlock(unref(bngBinding_default),{key:1,uiEvent:`action_2`,controller:``})):createCommentVNode(``,!0)]),_:1},512)],16)),[[unref(BngOnUiNav_default),void 0,`ok`,{asMouse:!0,focusRequired:!0}],[unref(BngOnUiNav_default),__props.secondaryAction?__props.secondaryAction:void 0,`action_2`,{focusRequired:!0}],[unref(BngOnUiNav_default),!opts.static&&opts.navigable.enabled?opts.expandClick:void 0,`context`,{focusRequired:!0}],[unref(BngUiNavLabel_default),__props.primaryLabel||`ui.inputActions.menu.menu_item_select.title`,`ok`],[unref(BngUiNavLabel_default),__props.secondaryLabel,`action_2`],[unref(BngUiNavLabel_default),_ctx.$tt(`ui.common.expand`)+`/`+_ctx.$tt(`ui.common.collapse`),`context`]]),createVNode(Transition,{name:opts.animated?`bng-acc-trans`:null},{default:withCtx(()=>[!opts.static&&opts.expandedActual&&!opts.disabled?(openBlock(),createElementBlock(`div`,_hoisted_1$346,[renderSlot(_ctx.$slots,`default`,{},()=>[_cache[3]||=createTextVNode(`Empty`,-1)],!0)])):createCommentVNode(``,!0)]),_:3},8,[`name`])],2)),[[unref(BngDisabled_default),opts.disabled]])}},accordionItem_default=__plugin_vue_export_helper_default(_sfc_main$402,[[`__scopeId`,`data-v-dd6087ee`]]),_sfc_main$401={__name:`accordionTree`,props:{data:[Array,Object],dataField:{type:String,required:!0},propsField:String,contentField:String,selectable:{type:[Boolean,Object],default:!1},selectedField:String,isTreeElement:Boolean},emits:[`selected`],setup(__props,{emit:__emit}){let props=__props,dataView=computed(()=>props.data&&(props.data[props.dataField]||props.data)||[]),emit$1=__emit;props.isTreeElement||(watch(()=>dataView.value,refreshSelected),watch(()=>props.selectedField&&props.selectable&&props.selectable.multi,refreshSelected),refreshSelected());let prevState=[];function refreshSelected(){if(!props.selectedField||!props.selectable||!props.selectable.multi)return;let state=[];function deepScan(arr){for(let itm of arr){let data=itm.data||itm;data[props.selectedField]&&state.push({data,selected:!0}),data[props.dataField]&&deepScan(data[props.dataField])}}deepScan(dataView.value),selected(state)}function selected(state){if(!props.isTreeElement){if(!props.selectable.multi){prevState=prevState.filter(itm=>itm.selected);for(let itm of prevState)itm.selected&&(itm.item.selected=!1,props.selectedField&&(itm.item.data[props.selectedField]=!1),state.includes(itm.item)||state.push(itm.item));prevState=state.map(item=>({selected:!!item.selected,item}))}if(props.selectedField){function deepSet(arr,value=void 0){for(let itm of arr){let val=typeof value==`boolean`?value:itm.selected,data=itm.data||itm;data[props.selectedField]=val,data[props.dataField]&&deepSet(data[props.dataField])}}deepSet(state)}}emit$1(`selected`,state)}function branchSelected(state){props.isTreeElement?emit$1(`selected`,state):selected(state)}return(_ctx,_cache)=>dataView.value.length>0?(openBlock(),createBlock(unref(accordion_default),{key:0,class:`acctree`,selectable:__props.selectable,"provide-parent":__props.isTreeElement,onSelected:selected},{default:withCtx(()=>[(openBlock(!0),createElementBlock(Fragment,null,renderList(dataView.value,entry=>(openBlock(),createBlock(unref(accordionItem_default),mergeProps({ref_for:!0},__props.propsField?entry[__props.propsField]:void 0,{selected:__props.selectedField?entry[__props.selectedField]:void 0,static:(!entry[__props.dataField]||entry[__props.dataField].length===0)&&(!__props.contentField||!entry[__props.contentField]),data:entry}),{caption:withCtx(()=>[renderSlot(_ctx.$slots,`caption`,{entry},void 0,!0)]),controls:withCtx(()=>[renderSlot(_ctx.$slots,`controls`,{entry},void 0,!0)]),default:withCtx(()=>[__props.contentField&&entry[__props.contentField]?renderSlot(_ctx.$slots,`default`,{key:0,entry},void 0,!0):createCommentVNode(``,!0),entry[__props.dataField]&&entry[__props.dataField].length>0?(openBlock(),createBlock(unref(accordionTree_default),mergeProps({key:1,ref_for:!0},props,{data:entry,"is-tree-element":!0,onSelected:branchSelected}),{caption:withCtx(({entry:entry$1})=>[renderSlot(_ctx.$slots,`caption`,{entry:entry$1},void 0,!0)]),controls:withCtx(({entry:entry$1})=>[renderSlot(_ctx.$slots,`controls`,{entry:entry$1},void 0,!0)]),_:2},1040,[`data`])):createCommentVNode(``,!0)]),_:2},1040,[`selected`,`static`,`data`]))),256))]),_:3},8,[`selectable`,`provide-parent`])):createCommentVNode(``,!0)}},accordionTree_default=__plugin_vue_export_helper_default(_sfc_main$401,[[`__scopeId`,`data-v-2ad1085d`]]),_hoisted_1$345={class:`slotted`},_sfc_main$400={__name:`aspectRatio`,props:{ratio:{type:String,default:`16:9`},imageMode:{type:String,default:`cover`,validator:value=>[`cover`,`contain`].includes(value)},image:{type:String,default:null},externalImage:{type:String,default:null}},setup(__props){useCssVars(_ctx=>({v711986eb:__props.imageMode}));let placeholderImageURL=getAssetURL(`images/noimage.png`),slots=useSlots(),props=__props,padding=computed(()=>{if(!props.ratio)return`56.25%`;let[width$1,height$1]=props.ratio.split(`:`).map(Number);return`${height$1/width$1*100}%`}),backgroundStyle=computed(()=>!props.image&&!props.externalImage?{"--padding":padding.value,backgroundImage:`none`}:props.image||props.externalImage?{"--padding":padding.value,backgroundImage:`url("${props.externalImage?props.externalImage:getAssetURL(props.image)}")`}:slots.default?{"--padding":padding.value,backgroundImage:`url("${placeholderImageURL}")`}:{});return(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,{class:`aspect-ratio`,style:normalizeStyle(backgroundStyle.value)},[createBaseVNode(`div`,_hoisted_1$345,[renderSlot(_ctx.$slots,`default`,{},void 0,!0)])],4))}},aspectRatio_default=__plugin_vue_export_helper_default(_sfc_main$400,[[`__scopeId`,`data-v-83698898`]]),_hoisted_1$344=[`data-carousel-item`],_sfc_main$399={__name:`carouselItem`,props:{value:{type:[String,Number],required:!0}},setup(__props){return(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,{class:`bng-carousel-item`,"data-carousel-item":__props.value},[renderSlot(_ctx.$slots,`default`,{},void 0,!0)],8,_hoisted_1$344))}},carouselItem_default=__plugin_vue_export_helper_default(_sfc_main$399,[[`__scopeId`,`data-v-babc74fb`]]),_hoisted_1$343={key:0,class:`navigation`},_hoisted_2$271=[`onClick`],TRANSITION_TYPES=[`fade`],_sfc_main$398={__name:`carousel`,props:{items:{type:Array,required:!0},current:{type:[String,Number],default:0},vertical:Boolean,loop:{type:Boolean,default:!0},transition:Boolean,transitionType:{type:String,default:`fade`,validator:value=>TRANSITION_TYPES.includes(value)},transitionTime:{type:Number,default:3e3},showNav:{type:Boolean,default:!0},parent:Object},setup(__props,{expose:__expose}){let props=__props,transitionTimer,carouselRoot=ref(null),carousel=ref(null),currentIndex=ref(props.current);computed(()=>``);let navState=reactive({selected:null}),showSlide=value=>{let slideIndex=parseInt(value);currentIndex.value=slideIndex,navState.selected=slideIndex,setTransition()},navShown=computed(()=>props.showNav&&!props.parent),children=[],childIndex=child=>children.findIndex(itm=>itm.element===child.element),addChild=child=>{childIndex(child)===-1&&children.push(child)},remChild=child=>{let idx=childIndex(child);idx>-1&&children.splice(idx,1)},tryParent=(_retry=0)=>{if(props.parent.addChild)props.parent.addChild(exposed);else if(_retry<100){let unwatch=watch(()=>props.parent.addChild,()=>{unwatch(),tryParent(++_retry)})}};watch(()=>props.parent,tryParent),watch(()=>navState.selected,sel=>{for(let child of children)child.showSlide&&child.showSlide(sel)}),onMounted(()=>{setTransition(),props.parent&&tryParent()}),onBeforeUnmount(()=>{transitionTimer&&=(clearInterval(transitionTimer),null),props.parent&&props.parent.remChild&&props.parent.remChild(exposed)});function showPrevious(){if(props.parent)return;let prev;currentIndex.value===0&&props.loop?prev=props.items.length-1:currentIndex.value>0&&(prev=currentIndex.value-1),prev!==void 0&&(navState.selected=prev,currentIndex.value=prev,setTransition())}function showNext(){if(props.parent)return;let next=getNext();next>-1&&(navState.selected=next,currentIndex.value=next,setTransition())}function setTransition(){transitionTimer&&clearInterval(transitionTimer),transitionTimer=setInterval(()=>{let next=getNext();next>-1&&(currentIndex.value=next)},props.transitionTime)}function getNext(){return currentIndex.value===props.items.length-1&&props.loop?0:currentIndex.value(openBlock(),createElementBlock(`div`,{ref_key:`carouselRoot`,ref:carouselRoot,class:normalizeClass({"bng-carousel":!0,"carousel-vertical":__props.vertical,[`transition-${__props.transitionType}`]:!0})},[createBaseVNode(`div`,{ref_key:`carousel`,ref:carousel,class:`carousel-content`},[createVNode(Transition,{name:__props.transitionType},{default:withCtx(()=>[(openBlock(),createBlock(carouselItem_default,{key:currentIndex.value,class:`carousel-slide`,value:currentIndex.value},{default:withCtx(()=>[renderSlot(_ctx.$slots,`item`,{item:__props.items[currentIndex.value],index:currentIndex.value},()=>[createTextVNode(toDisplayString(__props.items[currentIndex.value]),1)],!0)]),_:3},8,[`value`]))]),_:3},8,[`name`])],512),renderSlot(_ctx.$slots,`navigation`,{},()=>[navShown.value&&__props.items&&__props.items.length>1?(openBlock(),createElementBlock(`div`,_hoisted_1$343,[(openBlock(!0),createElementBlock(Fragment,null,renderList(__props.items,(item,index)=>(openBlock(),createElementBlock(`div`,{class:normalizeClass([`navigation-item`,{active:index===currentIndex.value}]),key:item.value,onClick:$event=>showSlide(index)},null,10,_hoisted_2$271))),128))])):createCommentVNode(``,!0)],!0)],2))}},carousel_default=__plugin_vue_export_helper_default(_sfc_main$398,[[`__scopeId`,`data-v-f54192e0`]]),_hoisted_1$342={key:0,class:`drawer-header`},_hoisted_2$270={key:1,class:`drawer-content`},_hoisted_3$236={key:2,class:`drawer-header`};const DRAWER_POSITION={bottom:`bottom`,top:`top`,left:`left`,right:`right`};var _sfc_main$397={__name:`drawer`,props:mergeModels({blur:Boolean,position:{type:String,default:DRAWER_POSITION.bottom,validator:val=>Object.values(DRAWER_POSITION).includes(val)}},{modelValue:{type:Boolean},modelModifiers:{}}),emits:mergeModels([`change`],[`update:modelValue`]),setup(__props,{emit:__emit}){let emit$1=__emit,expanded=useModel(__props,`modelValue`);watch(()=>expanded.value,val=>emit$1(`change`,val));let slots=useSlots(),expandedContent=computed(()=>expanded.value&&`expanded-content`in slots),hasAnyContent=computed(()=>expandedContent.value||`content`in slots);return(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,{class:normalizeClass({"bng-drawer":!0,[`drawer-pos-${__props.position}`]:!0,"drawer-expanded":expanded.value})},[__props.position===`bottom`||__props.position===`right`?withDirectives((openBlock(),createElementBlock(`div`,_hoisted_1$342,[renderSlot(_ctx.$slots,`header`,{},void 0,!0)])),[[unref(BngBlur_default),__props.blur]]):createCommentVNode(``,!0),hasAnyContent.value?withDirectives((openBlock(),createElementBlock(`div`,_hoisted_2$270,[expandedContent.value?renderSlot(_ctx.$slots,`expanded-content`,{key:0},void 0,!0):renderSlot(_ctx.$slots,`content`,{key:1},void 0,!0)])),[[unref(BngBlur_default),__props.blur]]):createCommentVNode(``,!0),__props.position===`top`||__props.position===`left`?withDirectives((openBlock(),createElementBlock(`div`,_hoisted_3$236,[renderSlot(_ctx.$slots,`header`,{},void 0,!0)])),[[unref(BngBlur_default),__props.blur]]):createCommentVNode(``,!0)],2))}},drawer_default=__plugin_vue_export_helper_default(_sfc_main$397,[[`__scopeId`,`data-v-8023232b`]]),_sfc_main$396={__name:`dynamicComponent`,props:{template:String,translateId:String,translateContext:Boolean,bbcode:Boolean,useComponents:{type:Boolean,default:!0},extraComponents:{type:Object,default:()=>({})}},setup(__props){let ALL_COMPONENTS=Object.fromEntries(Object.entries({...base_exports,...utility_exports}).filter(([name])=>name!==`DEMOS`)),attrs=useAttrs(),props=__props,template=computed(()=>{let res=props.template;return props.translateId&&(res=props.translateContext?$translate.contextTranslate(props.translateId,!0):$translate.instant(props.translateId)),res&&props.bbcode&&(res=parse$1(res)),res||``}),makeComponent=computed(()=>defineComponent({template:template.value,components:{...props.useComponents&&ALL_COMPONENTS,...props.extraComponents},data(){return attrs}}));return(_ctx,_cache)=>template.value&&makeComponent.value?(openBlock(),createBlock(resolveDynamicComponent(makeComponent.value),{key:0})):createCommentVNode(``,!0)}},dynamicComponent_default=_sfc_main$396,_hoisted_1$341={class:`shelf-wrapper`},_hoisted_2$269=[`disabled`],_hoisted_3$235=[`disabled`],storageKey=`bngshelf`,_sfc_main$395={__name:`shelf`,props:mergeModels({saveName:{type:String,default:null},limit:{type:Number,default:5,validator:val=>val>2&&val%2==1},fade:{type:Boolean,default:!1},showExtra:{type:Boolean,default:!0},neighborsFlatten:{type:Boolean,default:!1},neighborsScale:{type:Number,default:1},keepNeighborsAspectRatio:{type:Boolean,default:!1},noLoop:{type:Boolean,default:!1},navShown:{type:Boolean,default:!1},inward:{type:Number,default:0,validator:val=>val>=0&&val<=1}},{modelValue:{type:Number,default:0},modelModifiers:{}}),emits:mergeModels([`change`,`click`],[`update:modelValue`]),setup(__props,{expose:__expose,emit:__emit}){let selectedIndex=useModel(__props,`modelValue`),props=__props,emit$1=__emit,ready=ref(!1),slots=useSlots(),containerRef=ref(null),shelfItems=ref([]),displayItems=ref([]),isAnimating=ref(!1),itemIdCounter=0,lastValidIndex=0,isReverting=!1,isPrevDisabled=computed(()=>isAnimating.value||props.noLoop&&selectedIndex.value===0),isNextDisabled=computed(()=>isAnimating.value||props.noLoop&&selectedIndex.value===shelfItems.value.length-1);watch(selectedIndex,index=>{if(!isReverting){if(index=parseInt(index,10),isNaN(index)||index<0||shelfItems.value.length>0&&index>=shelfItems.value.length){isReverting=!0,selectedIndex.value=lastValidIndex,isReverting=!1;return}lastValidIndex=index,ready.value&&buildDisplayItems()}},{immediate:!0});let timings={single:400,multiStart:200,multiMiddle:200,multiEnd:200};watch(()=>slots.default?.(),update$6,{immediate:!0});function update$6(vnodes){if(ready.value){if(vnodes===void 0&&(vnodes=slots.default?.()),Array.isArray(vnodes)||(vnodes=[]),shelfItems.value=vnodes.reduce((res,vnode)=>typeof vnode.type==`symbol`&&vnode.type.toString()===`Symbol(v-fgt)`?(res.push(...vnode.children),res):(res.push(vnode),res),[]),props.saveName){let val=localStorage.getItem(`${storageKey}-${props.saveName}`);if(val!==null){let idx=parseInt(val,10);!isNaN(idx)&&idx>=0&&idxhalfLimit)continue;let itemIndex=selectedIndex.value+offset$2;if(props.noLoop){if(itemIndex<0||itemIndex>=shelfItems.value.length)continue}else itemIndex<0?itemIndex=shelfItems.value.length+itemIndex:itemIndex>=shelfItems.value.length&&(itemIndex-=shelfItems.value.length);items$2.push({vnode:shelfItems.value[itemIndex],originalIndex:itemIndex,position:offset$2,id:++itemIdCounter,style:getItemStyle(offset$2,`normal`)})}displayItems.value=items$2}function getItemStyle(position,state=`normal`){let absPosition=Math.abs(position),halfLimit=~~(props.limit/2),isExtraItem=absPosition>halfLimit,factor=halfLimit>0?absPosition/halfLimit:1,leftPercentage;if(leftPercentage=isExtraItem?(position<0?0:props.limit-1)/(props.limit-1)*100:(position+halfLimit)/(props.limit-1)*100,position!==0&&props.inward>0){let pullToCenter=(50-leftPercentage)*props.inward*factor;leftPercentage+=pullToCenter}let rotateY=factor*-30*Math.sign(position),translateZ=0,scaleX=1,scaleY=1,brightness=1;if(position!==0){if(translateZ=-100*factor,props.keepNeighborsAspectRatio){let scale=Math.max(.6,1-factor*.4)*props.neighborsScale;scaleX=scale,scaleY=scale}else scaleX=Math.max(.4,1-factor*.6)*props.neighborsScale,scaleY=Math.max(.6,1-factor*.4)*props.neighborsScale;brightness=Math.max(.5,1-factor*.5),props.neighborsFlatten&&(rotateY=0)}let opacity=1;return state===`entering`||state===`exiting`?(opacity=.1,translateZ=-100*(absPosition/halfLimit),leftPercentage+=2*Math.sign(position)):isExtraItem?opacity=.2:props.fade&&position!==0&&(opacity=Math.max(.4,1-absPosition*.3)),{left:`${leftPercentage}%`,transform:`translateX(-50%) translateY(-50%) translateZ(${translateZ}px) rotateY(${rotateY}deg) scale(${scaleX}, ${scaleY})`,filter:`brightness(${brightness})`,transition:`all 400ms cubic-bezier(0.25, 0.8, 0.25, 1)`,opacity,zIndex:isExtraItem?10-absPosition:100-absPosition}}let abortAnimation=!1;async function toIndex(targetIndex){if(!ready.value||selectedIndex.value===targetIndex||typeof targetIndex!=`number`||targetIndex<0||targetIndex>=shelfItems.value.length)return;if(isAnimating.value)for(abortAnimation=!0;abortAnimation;)await sleep(20);let prevIndex=selectedIndex.value,steps=calculateSteps(selectedIndex.value,targetIndex);if(steps.length!==0){isAnimating.value=!0;try{let stepTimings=calculateStepTimings(steps.length);for(let i=0;i{selectedIndex.value===targetIndex&&setFocusExternal(containerRef.value.querySelector(`[data-shelf-index="${targetIndex}"]`))})}finally{abortAnimation=!1,isAnimating.value=!1}props.saveName&&localStorage.setItem(`${storageKey}-${props.saveName}`,targetIndex.toString()),emit$1(`change`,targetIndex,prevIndex)}}let onFocus=index=>selectedIndex.value!==index&&toIndex(index);function onClick(index,event){selectedIndex.value===index?emit$1(`click`,event,index):toIndex(index)}function calculateStepTimings(stepCount){return stepCount===1?[timings.single]:Array.from({length:stepCount},(_,i)=>i===0?timings.multiStart:i===stepCount-1?timings.multiEnd:timings.multiMiddle)}function calculateSteps(fromIndex,toIndex$1){let targetItemIndex=displayItems.value.findIndex(item=>item.originalIndex===toIndex$1),steps=[];if(targetItemIndex===-1){let current=fromIndex;for(;current!==toIndex$1;){let totalItems=shelfItems.value.length;props.noLoop?toIndex$1>current?current+=1:--current:current=(toIndex$1-current+totalItems)%totalItems<=(current-toIndex$1+totalItems)%totalItems?(current+1)%totalItems:(current-1+totalItems)%totalItems,steps.push(current)}}else{let targetPosition=displayItems.value[targetItemIndex].position;if(targetPosition!==0){let direction$1=targetPosition>0?1:-1,stepsNeeded=Math.abs(targetPosition),current=fromIndex;for(let i=0;i0?current+=1:--current:current=direction$1>0?(current+1)%shelfItems.value.length:(current-1+shelfItems.value.length)%shelfItems.value.length,steps.push(current)}}return steps}async function animateToStep(stepIndex,stepTiming){let halfLimit=Math.floor(props.limit/2),currentIndex=selectedIndex.value,actualDirection=0;if(props.noLoop)actualDirection=stepIndex>currentIndex?1:-1;else{let totalItems=shelfItems.value.length;actualDirection=(stepIndex-currentIndex+totalItems)%totalItems<=(currentIndex-stepIndex+totalItems)%totalItems?1:-1}let newItems=[];if(actualDirection>0){for(let i=0;i=shelfItems.value.length?rightmostIndex-shelfItems.value.length:rightmostIndex),wrappedIndex>=0&&wrappedIndex=0&&wrappedIndexhalfLimit;newItems.push({...currentItem,position:newPosition,style:getItemStyle(newPosition,isExiting?`exiting`:`normal`)})}}displayItems.value=newItems;let delay=stepTiming/2;await sleep(delay),displayItems.value=displayItems.value.map(item=>item.style.opacity===.1&&(item.position===halfLimit||item.position===-halfLimit)?{...item,style:getItemStyle(item.position,`normal`)}:item),await new Promise(resolve$1=>setTimeout(resolve$1,delay))}function navigateNext$1(){isAnimating.value||props.noLoop&&selectedIndex.value===shelfItems.value.length-1||toIndex((selectedIndex.value+1)%shelfItems.value.length)}function navigatePrev(){isAnimating.value||props.noLoop&&selectedIndex.value===0||toIndex(selectedIndex.value===0?shelfItems.value.length-1:selectedIndex.value-1)}__expose({toIndex,next:navigateNext$1,prev:navigatePrev,isSelected:evt=>{let elm=evt.target.closest(`[data-shelf-index]`);if(!elm)return!1;let idx=parseInt(elm.getAttribute(`data-shelf-index`),10);return!isNaN(idx)&&selectedIndex.value===idx}}),onMounted(()=>{ready.value=!0,nextTick(update$6)});function getActiveItem(){let active=document.activeElement;return String(active.dataset.shelfIndex)===String(selectedIndex.value)?null:containerRef.value.querySelector(`[data-shelf-index="${selectedIndex.value}"]`)}return(_ctx,_cache)=>withDirectives((openBlock(),createElementBlock(`div`,_hoisted_1$341,[withDirectives((openBlock(),createElementBlock(`div`,{ref_key:`containerRef`,ref:containerRef,class:`shelf-container`},[(openBlock(!0),createElementBlock(Fragment,null,renderList(displayItems.value,item=>(openBlock(),createElementBlock(`div`,{key:`item-${item.originalIndex}-${item.id}`,class:`shelf-item`,style:normalizeStyle(item.style)},[(openBlock(),createBlock(resolveDynamicComponent(item.vnode),{"data-shelf-index":item.originalIndex,onClick:$event=>onClick(item.originalIndex,$event),onFocus:$event=>onFocus(item.originalIndex),onUinavFocus:$event=>onFocus(item.originalIndex)},null,40,[`data-shelf-index`,`onClick`,`onFocus`,`onUinavFocus`]))],4))),128))])),[[unref(BngFocusCapture_default),getActiveItem,`101`]]),__props.navShown?(openBlock(),createElementBlock(`button`,{key:0,class:`shelf-nav shelf-nav-prev`,onClick:navigatePrev,disabled:isPrevDisabled.value},[createVNode(unref(bngIcon_default),{type:unref(icons).arrowLargeLeft},null,8,[`type`])],8,_hoisted_2$269)):createCommentVNode(``,!0),__props.navShown?(openBlock(),createElementBlock(`button`,{key:1,class:`shelf-nav shelf-nav-next`,onClick:navigateNext$1,disabled:isNextDisabled.value},[createVNode(unref(bngIcon_default),{type:unref(icons).arrowLargeRight},null,8,[`type`])],8,_hoisted_3$235)):createCommentVNode(``,!0)],512)),[[vShow,displayItems.value.length>0]])}},shelf_default=__plugin_vue_export_helper_default(_sfc_main$395,[[`__scopeId`,`data-v-0109573f`]]),_sfc_main$394={__name:`slotSwitcher`,props:{slotId:{type:String,default:`default`}},setup(__props){return(_ctx,_cache)=>renderSlot(_ctx.$slots,__props.slotId,normalizeProps(guardReactiveProps(_ctx.$attrs)))}},slotSwitcher_default=_sfc_main$394,_sfc_main$393={__name:`tab`,props:{heading:String,selected:Boolean},setup(__props){return(_ctx,_cache)=>renderSlot(_ctx.$slots,`default`,{tabHeading:__props.heading,tabSelected:__props.selected})}},tab_default=_sfc_main$393,_hoisted_1$340={class:`tab-list`},_sfc_main$392={__name:`tabList`,setup(__props){let tabs=inject(`tabs`),selectTab=inject(`selectTab`),tabHeaderClasses=tab=>({"tab-item":!0,"tab-active-tab":tab.active,"no-hover":tab.active});function handleTabSelect(index,event){let buttonElement=event.currentTarget,hasFocusVisible=document.activeElement&&document.activeElement.classList.contains(`focus-visible`);selectTab(index),hasFocusVisible&&nextTick(()=>{setFocusExternal(buttonElement)})}return(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$340,[(openBlock(!0),createElementBlock(Fragment,null,renderList(unref(tabs),(tab,i)=>(openBlock(),createBlock(unref(bngButton_default),{key:i,accent:(tab.active,`ghost`),class:normalizeClass(tabHeaderClasses(tab)),tabindex:`0`,"bng-nav-item":``,onClick:$event=>handleTabSelect(tab.index,$event)},{default:withCtx(()=>[createTextVNode(toDisplayString(tab.heading),1)]),_:2},1032,[`accent`,`class`,`onClick`]))),128))]))}},tabList_default=__plugin_vue_export_helper_default(_sfc_main$392,[[`__scopeId`,`data-v-5c322d77`]]),_hoisted_1$339={class:`tab-container`},_sfc_main$391={__name:`tabs`,props:{selectedIndex:{type:Number,default:-1}},emits:[`change`],setup(__props,{expose:__expose,emit:__emit}){let emit$1=__emit,props=__props,ready=ref(!1),slots=useSlots(),tabListStart=shallowRef(),tabListEnd=shallowRef(),tabsList=ref(),tabsContent=ref([]),selectedIndex=ref(-1),isTabList=vnode=>typeof vnode.type==`object`&&vnode.type.__name===tabList_default.__name;provide(`tabs`,tabsList),watch(()=>slots.default?.(),update$6,{immediate:!0}),watch(()=>props.selectedIndex,index=>selectTab(index));function update$6(vnodes){if(!ready.value)return;vnodes===void 0&&(vnodes=slots.default?.()),Array.isArray(vnodes)||(vnodes=[]);let tabListIndex=vnodes.findIndex(vn=>isTabList(vn));tabListStart.value=tabListIndex===0?vnodes[tabListIndex]:tabList_default,tabListEnd.value=tabListIndex===vnodes.length-1?vnodes[tabListIndex]:null,tabsContent.value=vnodes.filter(vn=>!isTabList(vn)).reduce((res,vnode)=>typeof vnode.type==`symbol`&&vnode.type.toString()===`Symbol(v-fgt)`?(res.push(...vnode.children),res):(res.push(vnode),res),[]),tabsList.value=tabsContent.value.map((tab,index)=>({index,heading:tab.props?.[`tab-heading`]||tab.props?.tabHeading||`Tab ${index+1}`,active:selectedIndex.value===-1?props.selectedIndex===index||!!tab.props?.[`tab-selected`]||!!tab.props?.tabSelected:selectedIndex.value===index}));let activeIndex=tabsList.value.findIndex(tab=>tab.active);selectTab(activeIndex>-1?activeIndex:0)}function selectTab(index){if(!ready.value||typeof index!=`number`||index<0||index>=tabsList.value.length||selectedIndex.value===index)return;let prevTab=tabsList.value[selectedIndex.value];tabsList.value.forEach(tab=>{tab.active=tab.index===index}),selectedIndex.value=index,emit$1(`change`,tabsList.value[index],prevTab)}return provide(`selectTab`,selectTab),__expose({goNext:()=>selectTab((selectedIndex.value+1)%tabsList.value.length),goPrev:()=>selectTab(Math.abs(selectedIndex.value-1)%tabsList.value.length),selectTab}),onMounted(()=>{ready.value=!0,nextTick(update$6)}),(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$339,[tabListStart.value?(openBlock(),createBlock(resolveDynamicComponent(tabListStart.value),{key:0})):createCommentVNode(``,!0),tabsContent.value[selectedIndex.value]?(openBlock(),createBlock(resolveDynamicComponent(tabsContent.value[selectedIndex.value]),{key:1,class:`tab-content`})):createCommentVNode(``,!0),tabListEnd.value?(openBlock(),createBlock(resolveDynamicComponent(tabListEnd.value),{key:2})):createCommentVNode(``,!0)]))}},tabs_default=__plugin_vue_export_helper_default(_sfc_main$391,[[`__scopeId`,`data-v-2ff63a4f`]]),_sfc_main$390={__name:`textScroller`,props:{scrollSpeed:{type:Number,default:3},initialPause:{type:Number,default:1},endingPause:{type:Number,default:1},fadeDuration:{type:Number,default:.2},watchContent:{type:Boolean,default:!1}},setup(__props){let props=__props,slots=useSlots(),events$3={start:[`uinav-focus`,`focus`,`mouseenter`],stop:[`uinav-blur`,`blur`,`mouseleave`]},elContainer=ref(null),elText=ref(null),scrollDistance=ref(0),translateX=ref(0),opacity=ref(1),isActive=ref(!1),isScrolling$1=ref(!1),styleOverrides={"button-icon":`.bng-button.l-icon, .bng-button.r-icon`},overrideClasses=ref([]),parentElement=null,fontSize=ref(16),scrollSpeed=computed(()=>props.scrollSpeed*fontSize.value),animTimer=null,animTimeout=(func,ms)=>(animTimer&&=(clearTimeout(animTimer),null),typeof func==`function`?(animTimer=setTimeout(()=>{animTimer=null,isScrolling$1.value&&func()},ms),animTimer):null),scrollStyles=computed(()=>({transform:`translateX(${translateX.value}px)`,opacity:opacity.value,transition:`opacity ${props.fadeDuration}s linear`+(isScrolling$1.value&&opacity.value>0?`, transform ${scrollDistance.value/scrollSpeed.value}s linear`:``)}));function animLoop(){isScrollable()&&(scrollDistance.value=getSize(),!(scrollDistance.value<=0)&&(opacity.value=1,animTimeout(()=>{translateX.value=-scrollDistance.value,animTimeout(()=>{opacity.value=0,animTimeout(()=>{translateX.value=0,nextTick(animLoop)},props.fadeDuration*1e3)},scrollDistance.value/scrollSpeed.value*1e3+props.endingPause*1e3)},Math.max(props.initialPause,props.fadeDuration)*1e3)))}function isScrollable(){if(!elContainer.value||!elText.value)return!1;let containerWidth=elContainer.value.clientWidth;return elText.value.scrollWidth>containerWidth}function getSize(){if(!elContainer.value||!elText.value)return 0;let containerWidth=elContainer.value.clientWidth,textWidth=elText.value.scrollWidth;return Math.max(0,textWidth-containerWidth)}function animStart(){isActive.value=!0,isScrollable()&&(isScrolling$1.value=!0,translateX.value=0,opacity.value=1,animLoop())}function animStop(restartAnim=!1){isActive.value=!1,isScrolling$1.value=!1,animTimeout(),nextTick(()=>{translateX.value=0,opacity.value=1,typeof restartAnim==`boolean`&&restartAnim&&nextTick(animStart)})}return props.watchContent&&watch(()=>slots.default?.(),()=>animStop(isActive.value),{deep:!0}),watch([()=>scrollSpeed.value,()=>props.initialPause,()=>props.endingPause,()=>props.fadeDuration],()=>animStop(isActive.value)),watch(()=>elContainer.value,()=>{if(!elContainer.value)return;for(parentElement=elContainer.value.parentElement;parentElement&&!parentElement.matches(`[is-bng-panel], [bng-nav-item], [ng-click], [href], [bng-all-clicks], [bng-all-clicks-no-nav], [ui-sref], input, textarea, button, md-option, md-slider, md-select, md-checkbox`);)if(parentElement=parentElement.parentElement,parentElement===document.body){parentElement=null;break}if(!parentElement)return;overrideClasses.value=[];for(let[key,selectors]of Object.entries(styleOverrides))parentElement.matches(selectors)&&overrideClasses.value.push(`bng-text-override--${key}`);let fSize=window.getComputedStyle(elContainer.value,null).fontSize;fontSize.value=+fSize.substring(0,fSize.length-2),events$3.start.forEach(event=>parentElement.addEventListener(event,animStart)),events$3.stop.forEach(event=>parentElement.addEventListener(event,animStop))},{immediate:!0}),onUnmounted(()=>{animTimeout(),parentElement&&(events$3.start.forEach(event=>parentElement.removeEventListener(event,animStart)),events$3.stop.forEach(event=>parentElement.removeEventListener(event,animStop)))}),(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,{ref_key:`elContainer`,ref:elContainer,class:normalizeClass([`bng-text-scroller`,[{"is-scrolling":isScrolling$1.value},...overrideClasses.value]])},[createBaseVNode(`div`,{ref_key:`elText`,ref:elText,class:`scroller-text`,style:normalizeStyle(scrollStyles.value)},[renderSlot(_ctx.$slots,`default`,{},void 0,!0)],4)],2))}},textScroller_default=__plugin_vue_export_helper_default(_sfc_main$390,[[`__scopeId`,`data-v-4f311fae`]]),_hoisted_1$338=[`data-tree-node-key`,`data-tree-node-expanded`,`data-tree-node-selected`,`data-tree-node-parent-path`,`data-tree-node-path`],_hoisted_2$268={key:1,class:`node`},_hoisted_3$234=[`disabled`],_hoisted_4$199={key:2,"data-tree-node-children":``},_sfc_main$389={__name:`treeNode`,props:{node:{type:Object,required:!0},keyName:{type:String,required:!0},parentNode:Object,selectMode:String,expandMode:String,expandedKeys:Array,selectedKeys:Array,parentPath:Array},setup(__props){let props=__props,$templates=inject(`$templates`),_expandFn=inject(`expandFn`),_selectFn=inject(`selectFn`),expanded=computed(()=>props.expandMode===`prop`?props.node.expanded:props.expandedKeys&&props.expandedKeys.includes(props.node[props.keyName])),expandable=computed(()=>!props.node.disabled&&props.node.children&&props.node.children.length>0),selected=computed(()=>props.selectMode?props.selectMode===`prop`?props.node.selected:props.selectedKeys&&props.selectedKeys.includes(props.node[props.keyName]):!1),selectable=computed(()=>!props.node.disabled&&props.selectMode&&props.node.selectable!==!1),path=computed(()=>props.parentPath?props.parentPath.concat(props.node[props.keyName]):[props.node[props.keyName]]),parentPathString=computed(()=>props.parentPath?props.parentPath.join(`/`):null),pathString=computed(()=>path.value.join(`/`)),nodeProps=computed(()=>({path:path.value,parentPath:props.parentPath}));return(_ctx,_cache)=>{let _component_TreeNode=resolveComponent(`TreeNode`,!0);return openBlock(),createElementBlock(`li`,{"data-tree-node-key":__props.node[__props.keyName],"data-tree-node-expanded":expanded.value,"data-tree-node-selected":selected.value,"data-tree-node-parent-path":parentPathString.value,"data-tree-node-path":pathString.value,"data-tree-node":``},[unref($templates).node?(openBlock(),createBlock(resolveDynamicComponent(unref($templates).node),{key:0,node:__props.node,parentNode:__props.parentNode,expanded:expanded.value,selected:selected.value,expand:()=>expandable.value?unref(_expandFn)(__props.node,nodeProps.value):{},select:()=>selectable.value?unref(_selectFn)(__props.node,nodeProps.value):{}},null,8,[`node`,`parentNode`,`expanded`,`selected`,`expand`,`select`])):(openBlock(),createElementBlock(`div`,_hoisted_2$268,[__props.node.children&&unref($templates).toggle?(openBlock(),createBlock(resolveDynamicComponent(unref($templates).toggle),{key:0,node:__props.node,parentNode:__props.parentNode,expanded:expanded.value,selected:selected.value,expand:()=>expandable.value?unref(_expandFn)(__props.node,nodeProps.value):{}},null,8,[`node`,`parentNode`,`expanded`,`selected`,`expand`])):(openBlock(),createElementBlock(`span`,{key:1,class:`node-toggle`,onClick:_cache[0]||=()=>expandable.value?unref(_expandFn)(__props.node,nodeProps.value):{},disabled:__props.node.disabled},[__props.node.children?(openBlock(),createBlock(unref(bngIcon_default),{key:0,"bng-nav-item":``,type:expanded.value?unref(icons).arrowSmallDown:unref(icons).arrowSmallRight},null,8,[`type`])):createCommentVNode(``,!0)],8,_hoisted_3$234)),unref($templates).content?(openBlock(),createBlock(resolveDynamicComponent(unref($templates).content),{key:2,node:__props.node,parentNode:__props.parentNode,expanded:expanded.value,selected:selected.value,expand:()=>expandable.value?unref(_expandFn)(__props.node,nodeProps.value):{},select:()=>selectable.value?unref(_selectFn)(__props.node,nodeProps.value):{}},null,8,[`node`,`parentNode`,`expanded`,`selected`,`expand`,`select`])):(openBlock(),createElementBlock(`span`,{key:3,"bng-nav-item":``,class:`node-content`,onClick:_cache[1]||=()=>selectable.value?unref(_selectFn)(__props.node,nodeProps.value):{}},toDisplayString(__props.node.label),1))])),expanded.value&&__props.node.children?(openBlock(),createElementBlock(`ul`,_hoisted_4$199,[(openBlock(!0),createElementBlock(Fragment,null,renderList(__props.node.children,childNode=>(openBlock(),createBlock(_component_TreeNode,{key:childNode[__props.keyName],node:childNode,parentNode:__props.node,keyName:__props.keyName,selectMode:__props.selectMode,expandMode:__props.expandMode,expandedKeys:__props.expandedKeys,selectedKeys:__props.selectedKeys,parentPath:path.value},null,8,[`node`,`parentNode`,`keyName`,`selectMode`,`expandMode`,`expandedKeys`,`selectedKeys`,`parentPath`]))),128))])):createCommentVNode(``,!0)],8,_hoisted_1$338)}}},treeNode_default=__plugin_vue_export_helper_default(_sfc_main$389,[[`__scopeId`,`data-v-aeb14cdb`]]),_hoisted_1$337={class:`tree`},SELECT_SINGLE=`single`,SELECT_MULTIPLE=`multi`,SELECT_PROP=`prop`,SELECT_MODES=[SELECT_SINGLE,SELECT_MULTIPLE,SELECT_PROP],EXPAND_MODEL=`model`,EXPAND_PROP=`prop`,EXPAND_MODES=[EXPAND_MODEL,EXPAND_PROP],_sfc_main$388={__name:`tree`,props:mergeModels({nodes:{type:Array,required:!0},keyName:{type:String,default:`key`},expandMode:{type:String,default:EXPAND_MODEL,validator(value){return EXPAND_MODES.includes(value)}},selectMode:{type:String,validator(value){return SELECT_MODES.includes(value)}}},{expandedKeys:{},expandedKeysModifiers:{},selectedKeys:{},selectedKeysModifiers:{}}),emits:mergeModels([`update:expandedKeys`,`node-expanded`,`node-collapsed`,`expanded-keys-changed`,`node-selected`,`node-unselected`,`selected-keys-changed`],[`update:expandedKeys`,`update:selectedKeys`]),setup(__props,{emit:__emit}){let props=__props,expandedKeys=useModel(__props,`expandedKeys`),selectedKeys=useModel(__props,`selectedKeys`),emit$1=__emit;onBeforeMount(()=>{provide(`$templates`,useSlots()),provide(`expandFn`,expand),provide(`selectFn`,select)});function expand(node,nodeProps){let nodeKey=node[props.keyName];if(props.expandMode===EXPAND_PROP)node.expanded?emit$1(`node-collapsed`,node,nodeProps):emit$1(`node-expanded`,node,nodeProps);else{if(!expandedKeys.value)throw Error(`v-model:expandedKeys must be set`);let expanded=expandedKeys.value.includes(nodeKey),updatedExpandedKeys;expanded?(updatedExpandedKeys=expandedKeys.value.filter(x=>x!==nodeKey),emit$1(`node-collapsed`,node,nodeProps)):(updatedExpandedKeys=[...expandedKeys.value,nodeKey],emit$1(`node-expanded`,node,nodeProps)),expandedKeys.value=updatedExpandedKeys,emit$1(`expanded-keys-changed`,updatedExpandedKeys)}}function select(node,nodeProps){console.log(`select`,node);let nodeKey=node[props.keyName];if(props.selectMode===SELECT_PROP)node.selected?emit$1(`node-selected`,node,nodeProps):emit$1(`node-unselected`,node,nodeProps);else{if(!selectedKeys.value)throw Error(`v-model:selectedKeys must be set`);let selected=selectedKeys.value.includes(nodeKey),updatedSelectedKeys;selected?(updatedSelectedKeys=selectedKeys.value.filter(x=>x!==nodeKey),emit$1(`node-unselected`,node,nodeProps)):props.selectMode===`single`?(updatedSelectedKeys=[nodeKey],emit$1(`node-selected`,node,nodeProps)):props.selectMode===`multi`&&(updatedSelectedKeys=[...selectedKeys.value,nodeKey],emit$1(`node-selected`,node,nodeProps)),selectedKeys.value=updatedSelectedKeys,emit$1(`selected-keys-changed`,updatedSelectedKeys)}}return(_ctx,_cache)=>(openBlock(),createElementBlock(`ul`,_hoisted_1$337,[(openBlock(!0),createElementBlock(Fragment,null,renderList(__props.nodes,node=>(openBlock(),createBlock(treeNode_default,{key:node[__props.keyName],node,keyName:__props.keyName,selectMode:__props.selectMode,expandMode:__props.expandMode,expandedKeys:expandedKeys.value,selectedKeys:selectedKeys.value},null,8,[`node`,`keyName`,`selectMode`,`expandMode`,`expandedKeys`,`selectedKeys`]))),128))]))}},tree_default=__plugin_vue_export_helper_default(_sfc_main$388,[[`__scopeId`,`data-v-7363528a`]]);const DEMOS$1={};var utility_exports=__export({Accordion:()=>accordion_default,AccordionItem:()=>accordionItem_default,AccordionTree:()=>accordionTree_default,AspectRatio:()=>aspectRatio_default,Carousel:()=>carousel_default,CarouselItem:()=>carouselItem_default,DEMOS:()=>DEMOS$1,DRAWER_POSITION:()=>DRAWER_POSITION,Drawer:()=>drawer_default,DynamicComponent:()=>dynamicComponent_default,Shelf:()=>shelf_default,SlotSwitcher:()=>slotSwitcher_default,Tab:()=>tab_default,TabList:()=>tabList_default,Tabs:()=>tabs_default,TextScroller:()=>textScroller_default,Tree:()=>tree_default,TreeNode:()=>treeNode_default}),_hoisted_1$336={class:`actions-drawer`},_sfc_main$387={__name:`bngActionsDrawer`,props:{header:{type:String,required:!0},headerActions:Array,showHeaderActions:{type:Boolean,default:!0},grouped:Boolean,actions:{type:[Array,Object],required:!0},selected:{type:[String,Number]},expanded:Boolean},emits:[`actionClick`,`headerActionClicked`,`categoryChanged`],setup(__props,{emit:__emit}){let emit$1=__emit,onActionClicked=action=>emit$1(`actionClick`,action);return(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$336,[createVNode(unref(bngDrawerOld_default),null,createSlots({header:withCtx(()=>[createTextVNode(toDisplayString(__props.header),1)]),content:withCtx(()=>[__props.grouped?(openBlock(),createBlock(unref(tabs_default),{key:0,class:`categories-tab bng-tabs`},{default:withCtx(()=>[(openBlock(!0),createElementBlock(Fragment,null,renderList(__props.actions,category=>(openBlock(),createBlock(unref(tab_default),{key:category.category,heading:category.category},{default:withCtx(()=>[(openBlock(),createBlock(unref(bngActionsList_default),{key:category.category,actions:category.items,selected:__props.selected,class:normalizeClass({expanded:__props.expanded}),onActionClick:_cache[0]||=value=>onActionClicked(value)},null,8,[`actions`,`selected`,`class`]))]),_:2},1032,[`heading`]))),128))]),_:1})):(openBlock(),createBlock(unref(bngActionsList_default),{key:1,actions:__props.actions,selected:__props.selected,class:normalizeClass({expanded:__props.expanded}),onActionClick:_cache[1]||=value=>onActionClicked(value)},null,8,[`actions`,`selected`,`class`]))]),_:2},[__props.showHeaderActions&&__props.headerActions?{name:`headerOptions`,fn:withCtx(()=>[(openBlock(!0),createElementBlock(Fragment,null,renderList(__props.headerActions,action=>(openBlock(),createBlock(unref(bngButton_default),{key:action.value,tabindex:`1`,accent:action.accent,onClick:$event=>_ctx.$emit(`headerActionClicked`,action.value)},{default:withCtx(()=>[createTextVNode(toDisplayString(action.label),1)]),_:2},1032,[`accent`,`onClick`]))),128))]),key:`0`}:void 0]),1024)]))}},bngActionsDrawer_default=__plugin_vue_export_helper_default(_sfc_main$387,[[`__scopeId`,`data-v-b433a352`]]),_hoisted_1$335={class:`header-wrapper`},_hoisted_2$267={class:`drawer-content`},_hoisted_3$233={key:0,class:`filters-wrapper`},_hoisted_4$198={class:`drawer-actions-wrapper`},_hoisted_5$168={key:0,class:`action-divider`},_hoisted_6$143={key:1,class:`progress-indicator`},_sfc_main$386={__name:`bngActionsDrawerOne`,props:{value:{type:Object,required:!0},flattenChildren:Boolean,allowOpenDrawer:Boolean,openDrawerLabel:String,closeDrawerLabel:String,loading:Boolean,header:String,blur:Boolean},emits:[`update:currentActionPath`,`update:loading`,`actionClicked`,`actionItemChanged`,`drawerOpened`],setup(__props,{emit:__emit}){let props=__props,emit$1=__emit,drawerState=reactive({isOpenCatalog:!1,currentPath:[],drawerFilters:[]}),currentActionPath=computed({get:()=>drawerState.currentPath,set:newValue=>{drawerState.currentPath=newValue}}),parentAction=computed(()=>{if(!currentActionPath.value||currentActionPath.value.length===0)return null;let currentAction$1=props.value;for(let key of currentActionPath.value.slice(0,-1))currentAction$1=currentAction$1.items.find(x=>x.value===key);return currentAction$1}),currentAction=computed(()=>{let currentAction$1=props.value;for(let key of currentActionPath.value)currentAction$1=currentAction$1.items.find(x=>x.value===key);return currentAction$1}),isDrawerOpen=computed({get:()=>drawerState.isOpenCatalog,set:newValue=>{drawerState.isOpenCatalog=newValue,emit$1(`drawerOpened`,newValue)}}),loading=computed({get:()=>props.loading,set:newValue=>emit$1(`update:loading`,newValue)}),canViewCatalogDisplayMode=computed(()=>(console.log(`canViewCatalogDisplayMode`),loading.value===!0||currentAction.value.allowOpenDrawer===!1?!1:(console.log(`currentAction`,currentAction.value),currentAction.value.items.every(x=>x.lazyLoadItems===!0||x.items)))),drawerFilterValue=computed({get:()=>drawerState.drawerFilters&&drawerState.drawerFilters.length>0?drawerState.drawerFilters[0]:null,set:newValue=>{drawerState.drawerFilters=newValue?[newValue]:[]}}),catalogFilters=computed(()=>{let activeAction=isDrawerOpen.value?parentAction.value:currentAction.value;return activeAction.items.every(x=>x.items&&x.items.length>0||x.lazyLoadItems)?activeAction.items.map(x=>({label:x.label,value:x.value})):[]}),showBackButton=computed(()=>currentActionPath.value.length>0);watch(drawerFilterValue,(newValue,oldValue)=>{console.log(`drawerFilterValue`,newValue,oldValue),newValue&&!oldValue?currentActionPath.value=[...currentActionPath.value,newValue]:newValue&&oldValue?currentActionPath.value=[...currentActionPath.value.slice(0,-1),newValue]:!newValue&&oldValue&&(currentActionPath.value=[...currentActionPath.value].slice(0,-1))}),watch(currentActionPath,()=>{emit$1(`actionItemChanged`,currentAction.value,currentActionPath.value)});let selectAction=actionItem=>{(actionItem.items&&actionItem.items.length>0||actionItem.lazyLoadItems===!0)&&(isDrawerOpen.value&&=!1,currentActionPath.value=[...currentActionPath.value,actionItem.value]),emit$1(`actionClicked`,actionItem)},toggleOpenCatalog=()=>{isDrawerOpen.value?closeDrawer():openDrawer()},goBack=()=>{isDrawerOpen.value?closeDrawer():currentActionPath.value=[...currentActionPath.value].slice(0,-1)};function openDrawer(){drawerFilterValue.value=catalogFilters.value[0].value,isDrawerOpen.value=!0}function closeDrawer(){drawerFilterValue.value=null,isDrawerOpen.value=!1}return(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,{class:normalizeClass([`bng-actions-drawer`,{expanded:isDrawerOpen.value}])},[createVNode(unref(bngDrawerOld_default),{blur:__props.blur,class:`bng-drawer`},{header:withCtx(()=>[renderSlot(_ctx.$slots,`header`,{actionItem:currentAction.value,canGoBack:showBackButton.value,goBack},()=>[createBaseVNode(`div`,_hoisted_1$335,[showBackButton.value?(openBlock(),createBlock(unref(bngButton_default),{key:0,icon:unref(icons).arrowLargeLeft,accent:unref(ACCENTS).secondary,class:`back-btn`,onClick:goBack},{default:withCtx(()=>[..._cache[1]||=[createTextVNode(`Back`,-1)]]),_:1},8,[`icon`,`accent`])):createCommentVNode(``,!0),createTextVNode(` `+toDisplayString(currentAction.value.label),1)])],!0)]),content:withCtx(()=>[createBaseVNode(`div`,_hoisted_2$267,[drawerState.isOpenCatalog&&catalogFilters.value.length>0?(openBlock(),createElementBlock(`div`,_hoisted_3$233,[createVNode(unref(bngPillFilters_default),{modelValue:drawerState.drawerFilters,"onUpdate:modelValue":_cache[0]||=$event=>drawerState.drawerFilters=$event,options:catalogFilters.value},null,8,[`modelValue`,`options`])])):createCommentVNode(``,!0),createBaseVNode(`div`,_hoisted_4$198,[createBaseVNode(`div`,{class:normalizeClass([`drawer-actions`,{expanded:drawerState.isOpenCatalog}])},[loading.value?(openBlock(),createElementBlock(`div`,_hoisted_6$143,[..._cache[2]||=[createBaseVNode(`div`,{class:`loader`},null,-1)]])):(openBlock(!0),createElementBlock(Fragment,{key:0},renderList(currentAction.value.items,action=>(openBlock(),createElementBlock(Fragment,{key:action.value},[action.type===`actionDivider`?(openBlock(),createElementBlock(`div`,_hoisted_5$168,toDisplayString(action.label),1)):renderSlot(_ctx.$slots,`item`,{key:1,actionItem:action,onClick:()=>selectAction(action)},()=>[createVNode(unref(bngImageTile_default),{label:action.label,icon:action.icon,onClick:$event=>selectAction(action)},null,8,[`label`,`icon`,`onClick`])],!0)],64))),128))],2)]),canViewCatalogDisplayMode.value?renderSlot(_ctx.$slots,`footer`,{key:1},()=>[createVNode(unref(bngButton_default),{class:`catalog-btn`,accent:unref(ACCENTS).outlined,onClick:toggleOpenCatalog},{default:withCtx(()=>[drawerState.isOpenCatalog?(openBlock(),createElementBlock(Fragment,{key:0},[createTextVNode(toDisplayString(__props.closeDrawerLabel?__props.closeDrawerLabel:`Collapse catalog`),1)],64)):(openBlock(),createElementBlock(Fragment,{key:1},[createTextVNode(toDisplayString(__props.openDrawerLabel?__props.openDrawerLabel:`Open full catalog`),1)],64))]),_:1},8,[`accent`])],!0):createCommentVNode(``,!0)])]),_:3},8,[`blur`])],2))}},bngActionsDrawerOne_default=__plugin_vue_export_helper_default(_sfc_main$386,[[`__scopeId`,`data-v-529c2a59`]]),_hoisted_1$334={class:`actions`},_sfc_main$385={__name:`bngActionsList`,props:{actions:{type:Array,required:!0},selected:{type:[String,Number],required:!1}},emits:[`actionClick`],setup(__props,{emit:__emit}){let emit$1=__emit;return(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$334,[(openBlock(!0),createElementBlock(Fragment,null,renderList(__props.actions,action=>(openBlock(),createBlock(unref(bngImageTile_default),mergeProps({class:`action-tile`,tabindex:`0`,key:action.value},{ref_for:!0},action,{"bng-nav-item":``,onClick:$event=>emit$1(`actionClick`,action.value)}),null,16,[`onClick`]))),128))]))}},bngActionsList_default=__plugin_vue_export_helper_default(_sfc_main$385,[[`__scopeId`,`data-v-8790d45d`]]),_hoisted_1$333=[`ui-event`],_hoisted_2$266={key:0},_hoisted_3$232={key:3,class:`combo-separator`},MULTI_ID=`[PLUS]`,MULTI_LABEL=`+`,_sfc_main$384={__name:`bngBinding`,props:{action:String,showUnassigned:Boolean,device:[String,Array],deviceKey:String,dark:Boolean,deviceMask:[String,Function],controller:Boolean,uiEvent:String,trackIgnore:Boolean,unassignedText:{default:`[N/A]`,type:String},viewerObj:Object,imagePack:String,actionVariants:Boolean,useLastDevice:{type:Boolean,default:!0},vertical:Boolean},setup(__props,{expose:__expose}){let $simplemenu=inject(`$simplemenu`),Controls=controls_default(),{showIfController,lastControllersSignature}=storeToRefs(Controls),props=__props,iconColors={dark:`var(--bng-off-black)`,light:`var(--bng-off-white)`},iconColor=computed(()=>iconColors[props.dark?`dark`:`light`]);computed(()=>iconColors[props.dark?`light`:`dark`]);let controllerOnly=computed(()=>props.controller||$simplemenu.value),LABELS_BIG=[`enter`,`tab`,`capslock`,`backspace`,`lshift`,`rshift`,`left`,`right`,`up`,`down`,`space`,`grave`,`comma`,`period`].map(c=>CONTROL_LABELS[c]||c),LABELS_OFFSET=[`space`].map(c=>CONTROL_LABELS[c]||c),rgxSanitize$1=s=>s.replace(/[-.+*$^?:|[\](){}]/g,`\\$&`),LABELS_RGX=RegExp(`(`+[MULTI_ID,...LABELS_BIG,...LABELS_OFFSET].map(rgxSanitize$1).join(`|`)+`)`,`g`),viewerObj=computed(()=>{if(props.viewerObj)return props.viewerObj;if(controllerOnly.value&&showIfController.value){let opts={...props};return opts.controller=!0,opts._controllerSignature=lastControllersSignature.value,Controls.makeViewerObj(opts)}return Controls.makeViewerObj(props)}),viewerVariants=computed(()=>{if(!viewerObj.value)return[];let variants=viewerObj.value.variants||[viewerObj.value];variants=variants.map(obj=>obj.multiControls||[obj]);for(let objs of variants)for(let obj of objs)if(obj&&(!obj.special||obj.ownLabel)&&!obj.controlSegments){let control=obj.ownLabel||obj.control;control=control.replace(/ \+ /g,MULTI_ID),obj.controlSegments=String(control).split(LABELS_RGX).filter(Boolean).map(segment=>({value:segment===MULTI_ID?MULTI_LABEL:segment,class:(LABELS_BIG.includes(segment)?`label-bigger `:``)+(LABELS_OFFSET.includes(segment)?`label-offset `:``)+(segment===MULTI_ID?`label-multi `:``)}))}return variants}),display=computed(()=>{let res=!!viewerObj.value;if(viewerObj.value)if(props.deviceMask){let dev=viewerObj.value.devName;res=typeof props.deviceMask==`function`?props.deviceMask(dev):dev.startsWith(props.deviceMask)}else controllerOnly.value&&(res=showIfController.value);return res||props.showUnassigned});__expose({displayed:display});let eventName=computed(()=>props.action?props.action:props.uiEvent?props.uiEvent:null),uiNavTracker=useUINavTracker(),ownerId$1=uniqueId(`bngBinding`),trackedEvent=``,track$1=(eventName$1=null)=>{if(trackedEvent&&=(uiNavTracker.removeIgnore(trackedEvent,ownerId$1),``),!(props.trackIgnore||!display.value)&&eventName$1){if(trackedEvent===eventName$1)return;trackedEvent=eventName$1,uiNavTracker.addIgnore(trackedEvent,ownerId$1)}};return watch(()=>props.trackIgnore,val=>track$1(val?null:eventName.value)),watch(display,()=>track$1(eventName.value)),watch(eventName,(val,prev)=>{prev&&track$1(),val&&track$1(val)}),onMounted(()=>track$1(eventName.value)),onUnmounted(()=>track$1()),(_ctx,_cache)=>display.value?(openBlock(),createElementBlock(`span`,{key:0,class:normalizeClass([`binding-wrapper`,{"binding-theme-dark":__props.dark,"binding-theme-light":!__props.dark,"with-variants":viewerVariants.value.length>1,vertical:__props.vertical}]),"ui-event":__props.uiEvent},[(openBlock(!0),createElementBlock(Fragment,null,renderList(viewerVariants.value,(viewerObjs,index)=>(openBlock(),createElementBlock(`span`,{key:index,class:normalizeClass([`binding-container`,{"combo-binding":viewerObjs.length>1}])},[(openBlock(!0),createElementBlock(Fragment,null,renderList(viewerObjs,(viewerObj$1,index$1)=>(openBlock(),createElementBlock(Fragment,{key:index$1},[viewerObj$1&&viewerObj$1.controlSegments?(openBlock(),createElementBlock(`kbd`,_hoisted_2$266,[(openBlock(!0),createElementBlock(Fragment,null,renderList(viewerObj$1.controlSegments,(seg,i)=>(openBlock(),createElementBlock(`span`,{key:i,class:normalizeClass(seg.class)},toDisplayString(seg.value),3))),128))])):viewerObj$1&&viewerObj$1.special?(openBlock(),createBlock(unref(bngIcon_default),{key:1,class:`bng-binding-icon`,type:unref(icons)[viewerObj$1.ownIcon],color:iconColor.value},null,8,[`type`,`color`])):!viewerObj$1&&__props.showUnassigned?(openBlock(),createBlock(unref(bngIcon_default),{key:2,class:`bng-binding-icon n-a`,type:unref(icons).NA,color:iconColor.value},null,8,[`type`,`color`])):createCommentVNode(``,!0),index$1Number(val)>0},simple:Boolean,blur:Boolean,disableLastItem:Boolean,showBackButton:Boolean,showBackBinding:{type:Boolean,default:!0},navigable:{type:Boolean,default:!0}},emits:[`click`,`back`],setup(__props,{emit:__emit}){let bid=uniqueId(`bng-path`),emit$1=__emit,props=__props,pathView=computed(()=>{if(!Array.isArray(props.items))return[];let mapItem=itm=>({label:itm.label,items:itm.items,data:itm,dividerType:itm.dividerType}),items$2=props.items.map(mapItem),res=props.limit?items$2.slice(-props.limit):items$2;if(!props.simple){let looseCmp=(a$1,b)=>a$1.label===b.label&&a$1.value===b.value,len=res.length;for(let i=1;ilooseCmp(itm,res[idx])),items:items$3.map(mapItem)})}}return props.limit&&items$2.length>props.limit&&res.unshift({label:`…`,data:items$2[items$2.length-props.limit-1]}),res.length>0&&(res[0].first=!0,res.at(-1).last=!0),res});function onClick(item,index){(!props.disableLastItem||index(openBlock(),createElementBlock(`div`,{class:`bng-path`,"bng-no-child-nav":!__props.navigable},[__props.showBackButton?(openBlock(),createBlock(unref(bngButton_default),{key:0,class:`back-button`,accent:unref(ACCENTS).custom,onClick:_cache[0]||=$event=>emit$1(`back`),tabindex:`1`},{default:withCtx(()=>[createVNode(unref(bngIcon_default),{type:unref(icons).arrowSmallLeft,class:`back-icon`},null,8,[`type`]),__props.showBackBinding?(openBlock(),createBlock(unref(bngBinding_default),{key:0,"ui-event":`back`,controller:``,"track-ignore":``})):createCommentVNode(``,!0),createTextVNode(` `+toDisplayString(_ctx.$tt(`ui.common.back`)),1)]),_:1},8,[`accent`])):createCommentVNode(``,!0),(openBlock(!0),createElementBlock(Fragment,null,renderList(pathView.value,(item,index)=>(openBlock(),createElementBlock(Fragment,{key:index},[item.dropdown?(openBlock(),createElementBlock(Fragment,{key:1},[withDirectives(createVNode(unref(bngButton_default),{class:`bng-path-item bng-path-has-dropdown`,accent:unref(ACCENTS).text,icon:unref(icons).arrowSmallRight},null,8,[`accent`,`icon`]),[[unref(BngBlur_default),__props.blur],[unref(BngPopover_default),item.dropdown,`bottom-start`,{click:!0}]]),createVNode(unref(bngPopoverMenu_default),{name:item.dropdown,focus:``},{default:withCtx(({hide:hide$2})=>[(openBlock(!0),createElementBlock(Fragment,null,renderList(item.items,(subitem,idx)=>withDirectives((openBlock(),createBlock(unref(bngButton_default),{key:idx,class:normalizeClass({selected:idx===item.selected}),accent:unref(ACCENTS).menu,onClick:$event=>onMenuClick(subitem,hide$2)},{default:withCtx(()=>[createTextVNode(toDisplayString(subitem.label),1)]),_:2},1032,[`class`,`accent`,`onClick`])),[[unref(BngOnUiNav_default),void 0,`ok`,{focusRequired:!0,asMouse:!0}]])),128))]),_:2},1032,[`name`])],64)):(openBlock(),createElementBlock(Fragment,{key:0},[withDirectives((openBlock(),createBlock(unref(bngButton_default),{class:normalizeClass([`bng-path-item`,{"bng-path-simple":__props.simple,"bng-path-disabled":__props.disableLastItem&&item.last,"bng-path-first":item.first,"bng-path-last":item.last}]),accent:unref(ACCENTS).text,onClick:$event=>onClick(item,index)},{default:withCtx(()=>[createTextVNode(toDisplayString(item.label),1)]),_:2},1032,[`class`,`accent`,`onClick`])),[[unref(BngBlur_default),__props.blur]]),__props.simple&&!item.last?(openBlock(),createElementBlock(`div`,_hoisted_2$265,[withDirectives(createVNode(unref(bngIcon_default),{type:item.dividerType||unref(icons).slashRight},null,8,[`type`]),[[unref(BngBlur_default),__props.blur]])])):createCommentVNode(``,!0)],64))],64))),128))],8,_hoisted_1$332))}},bngBreadcrumbs_default=__plugin_vue_export_helper_default(_sfc_main$383,[[`__scopeId`,`data-v-4a2e18d5`]]),_hoisted_1$331=[`accent`,`disabled`],_hoisted_2$264={key:0,class:`hold-arrow`,xmlns:`http://www.w3.org/2000/svg`,viewBox:`0 0 16 12`,preserveAspectRatio:`xMidYMid`},_hoisted_3$231={key:3,class:`label`},_hoisted_4$197={key:5,class:`label`},_hoisted_5$167={key:6};const ACCENTS={main:`main`,secondary:`secondary`,outlined:`outlined`,text:`text`,attention:`attention`,attentionghost:`attentionghost`,attentionoutlined:`attentionoutlined`,ghost:`ghost`,menu:`menu`,custom:`custom`};var _sfc_main$382={__name:`bngButton`,props:{accent:{type:String,default:`main`,validator:v=>Object.values(ACCENTS).includes(v)||v===``},iconLeft:[Object,String],iconRight:[Object,String],label:String,icon:[Object,String],externalIcon:String,showHold:Boolean,holdVertical:Boolean,disabled:Boolean,noSound:Boolean},setup(__props,{expose:__expose}){let slots=useSlots(),uiNavEvent=ref(),btnDOMElRef=ref(),attrs=useAttrs(),useOldIcons=computed(()=>`oldIcons`in attrs);watchUINavEventChange(btnDOMElRef,({eventName,action})=>{}),__expose({getElement(){return btnDOMElRef.value}});let isPlainTextSlot=ref(!1);function checkIfPlainText(){let slotContent=slots.default?slots.default():[];isPlainTextSlot.value=slotContent.length===1&&typeof slotContent[0].type==`symbol`&&String(slotContent[0].type).indexOf(`v-txt`)>-1&&slotContent[0].children.trim().length>0}watch(()=>slots.default,checkIfPlainText),checkIfPlainText();let props=__props,needsFallbackHoldOffset=ref(!0);return watchEffect(()=>{btnDOMElRef.value&&props.accent===`custom`&&window.getComputedStyle(btnDOMElRef.value).getPropertyValue(`--bng-button-custom-hold-offset`).trim()&&(needsFallbackHoldOffset.value=!1)}),(_ctx,_cache)=>withDirectives((openBlock(),createElementBlock(`button`,{ref_key:`btnDOMElRef`,ref:btnDOMElRef,accent:__props.accent,class:normalizeClass({"show-hold":__props.showHold,"hold-vertical":__props.holdVertical,"bng-button":!0,empty:!unref(slots).default&&!__props.label,"l-icon":__props.iconLeft||__props.icon,"r-icon":__props.iconRight,"external-icon":__props.externalIcon,"fallback-hold-offset":props.accent===`custom`&&needsFallbackHoldOffset.value}),disabled:__props.disabled},[__props.showHold?(openBlock(),createElementBlock(`svg`,_hoisted_2$264,[..._cache[0]||=[createBaseVNode(`path`,{d:`M1,1 L8,2 L16,1 L8,11 z`},null,-1)]])):createCommentVNode(``,!0),useOldIcons.value&&(__props.iconLeft||__props.icon)?(openBlock(),createBlock(unref(bngOldIcon_default),{key:1,type:__props.iconLeft||__props.icon},null,8,[`type`])):!useOldIcons.value&&(__props.iconLeft||__props.icon||__props.externalIcon)?(openBlock(),createBlock(unref(bngIcon_default),{key:2,class:`icon`,type:__props.iconLeft||__props.icon,externalImage:__props.externalIcon},null,8,[`type`,`externalImage`])):createCommentVNode(``,!0),isPlainTextSlot.value?(openBlock(),createElementBlock(`span`,_hoisted_3$231,[renderSlot(_ctx.$slots,`default`,{},void 0,!0)])):isPlainTextSlot.value?createCommentVNode(``,!0):renderSlot(_ctx.$slots,`default`,{key:4},void 0,!0),__props.label&&!isPlainTextSlot.value?(openBlock(),createElementBlock(`span`,_hoisted_4$197,toDisplayString(__props.label),1)):createCommentVNode(``,!0),uiNavEvent.value?(openBlock(),createElementBlock(`span`,_hoisted_5$167,toDisplayString(uiNavEvent.value),1)):createCommentVNode(``,!0),useOldIcons.value&&__props.iconRight?(openBlock(),createBlock(unref(bngOldIcon_default),{key:7,span:``,type:__props.iconRight},null,8,[`type`])):!useOldIcons.value&&__props.iconRight?(openBlock(),createBlock(unref(bngIcon_default),{key:8,class:`icon`,type:__props.iconRight},null,8,[`type`])):createCommentVNode(``,!0),_cache[1]||=createBaseVNode(`div`,{class:`background`},null,-1)],10,_hoisted_1$331)),[[unref(BngSoundClass_default),!__props.disabled&&!__props.noSound&&`bng_click_hover_generic`]])}},bngButton_default=__plugin_vue_export_helper_default(_sfc_main$382,[[`__scopeId`,`data-v-8b356414`]]),_hoisted_1$330={class:`card-cnt`},ANIMATION_TYPES=[`fade`,`slide`],_sfc_main$381={__name:`bngCard`,props:{backgroundImage:String,footerStyles:Object,hideFooter:Boolean,animateFooter:Boolean,animateFooterType:{type:String,default:`fade`,validator:value=>ANIMATION_TYPES.includes(value)}},setup(__props,{expose:__expose}){useCssVars(_ctx=>({v3c03b7b2:backgroundImageStyle.value}));let props=__props,slots=useSlots(),hasFooter=computed(()=>(slots.footer||slots.buttons)&&!props.hideFooter),buttonsContainer=ref(),backgroundImageStyle=computed(()=>props.backgroundImage?`url('${props.backgroundImage}')`:``);return __expose({buttonsContainer}),(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,{class:normalizeClass([`bng-card bng-card-wrapper`,{"with-background-image":backgroundImageStyle.value}])},[createBaseVNode(`div`,_hoisted_1$330,[renderSlot(_ctx.$slots,`default`,{},()=>[_cache[0]||=createTextVNode(`BNG Card`,-1)],!0)]),createVNode(Transition,{name:__props.animateFooter?__props.animateFooterType:``},{default:withCtx(()=>[hasFooter.value?(openBlock(),createElementBlock(`div`,{key:0,ref_key:`buttonsContainer`,ref:buttonsContainer,class:`footer-container`,style:normalizeStyle(__props.footerStyles)},[renderSlot(_ctx.$slots,`buttons`,{},void 0,!0),renderSlot(_ctx.$slots,`footer`,{},void 0,!0)],4)):createCommentVNode(``,!0)]),_:3},8,[`name`])],2))}},bngCard_default=__plugin_vue_export_helper_default(_sfc_main$381,[[`__scopeId`,`data-v-32edaae4`]]),_sfc_main$380={__name:`bngCardHeading`,props:{type:{type:String,default:`line`,validator:v=>[`line`,`ribbon`,`none`].includes(v)||v===``},outline:{type:Boolean,default:!1}},setup(__props){return(_ctx,_cache)=>(openBlock(),createElementBlock(`h2`,{class:normalizeClass({"card-heading":!0,[`heading-style-${__props.type}`]:!0,outline:__props.outline})},[renderSlot(_ctx.$slots,`default`,{},()=>[_cache[0]||=createTextVNode(`BNG Card Heading`,-1)],!0)],2))}},bngCardHeading_default=__plugin_vue_export_helper_default(_sfc_main$380,[[`__scopeId`,`data-v-fc76db37`]]),_hoisted_1$329={key:0,class:`colour-picker-switch`};const VIEWS={simple:{slider:!0,picker:!1,saturation:!1,luminosity:!1},compact_saturation:{slider:!0,picker:!0,saturation:!0,luminosity:!1,compact:!0},compact_luminosity:{slider:!0,picker:!0,saturation:!1,luminosity:!0,compact:!0},saturation:{slider:!1,picker:!0,saturation:!0,luminosity:!1},luminosity:{slider:!1,picker:!0,saturation:!1,luminosity:!0},full_saturation:{slider:!0,picker:!0,saturation:!0,luminosity:!1},full_luminosity:{slider:!0,picker:!0,saturation:!1,luminosity:!0}};var valuesDef={hue:.5,saturation:1,luminosity:.5},_sfc_main$379={__name:`bngColorPicker`,props:{modelValue:{type:Object,default:{...valuesDef}},view:{type:[String,Object],default:`full_luminosity`,validator:val=>typeof val==`string`||val in VIEWS},showText:{type:Boolean,default:!0},step:{type:Number,default:.001},disabled:Boolean},emits:[`update:modelValue`,`change`],setup(__props,{emit:__emit}){let $simplemenu=inject(`$simplemenu`),props=__props,sliderIndicator=`popout`,pickerMode=ref(`luminosity`),opts=ref({}),values=reactive({...valuesDef}),colorDot=ref({x:0,y:0});watch([()=>props.view,$simplemenu],()=>{if(typeof props.view==`string`)for(let key in VIEWS[props.view])opts.value[key]=VIEWS[props.view][key];else opts.value={...VIEWS[props.view]};$simplemenu.value?(opts.value.picker=!1,opts.value.compact&&(opts.value.slider=!0)):opts.value.compact&&loadCompactMode(),opts.value.picker&&setColorDot()},{immediate:!0});function updColour(){for(let key in values)values[key]=props.modelValue[key];opts.value.picker&&setColorDot()}watch(()=>props.modelValue,updColour),watch(()=>props.modelValue.hue,updColour),watch(()=>props.modelValue.saturation,updColour),watch(()=>props.modelValue.luminosity,updColour);let current=computed(()=>({hue:~~(values.hue*360),saturation:~~(values.saturation*100),luminosity:~~(values.luminosity*100)})),emitter=__emit;function notify(){for(let key in values)props.modelValue[key]=values[key];emitter(`change`,props.modelValue),emitter(`update:modelValue`,props.modelValue)}let hueLoop=[...Array(7)].map((_,i)=>i/6*360),gradients=reactive({hueStatic:hueLoop.map(hue=>`hsl(${hue}, 100%, 50%)`),hue:computed(()=>hueLoop.map(hue=>`hsl(${hue}, 100%, 50%)`)),overlaySaturation:[`hsla(0, 0%,  0%, 0)`,`hsla(0, 0%, 50%, 1)`],overlayLuminosity:[`hsla(0, 0%, 100%, 1)`,`hsla(0, 0%, 100%, 0) 50%`,`hsla(0, 0%,   0%, 0) 50%`,`hsla(0, 0%,   0%, 1)`],pickerOverlay:computed(()=>opts.value.saturation?gradients.overlaySaturation:gradients.overlayLuminosity),saturation:computed(()=>[`hsl(${current.value.hue},   0%, ${current.value.luminosity}%)`,`hsl(${current.value.hue}, 100%, ${current.value.luminosity}%)`]),luminosity:computed(()=>[`hsl(${current.value.hue}, ${current.value.saturation}%,   0%)`,`hsl(${current.value.hue}, ${current.value.saturation}%,  50%)`,`hsl(${current.value.hue}, ${current.value.saturation}%, 100%)`])}),isMousedown=!1;function onMousedown(){isMousedown=!0}function onMousemove(evt){updateColor(evt)}function onMouseupLeave(evt){updateColor(evt,!0)}function getPosition(evt){let rect=evt.target.getBoundingClientRect();return rect.width<20?colorDot.value:{x:(evt.x-rect.left)/rect.width*100,y:(evt.y-rect.top)/rect.height*100}}function updateColor(evt,mouseLeave=!1){if(!isMousedown)return;mouseLeave&&(isMousedown=!1);let pos=getPosition(evt);values.hue=Math.max(0,Math.min(pos.x,100))/100;let secondary=1-Math.max(0,Math.min(pos.y,100))/100;opts.value.saturation?values.saturation=secondary:values.luminosity=secondary,setColorDot(),nextTick(notify)}function setColorDot(){colorDot.value={x:values.hue*100,y:(1-(opts.value.saturation?values.saturation:values.luminosity))*100}}function toggleCompactMode(){opts.value.slider=!opts.value.slider,opts.value.picker=!opts.value.picker,saveCompactMode()}function togglePickerMode(){pickerMode.value=pickerMode.value===`luminosity`?`saturation`:`luminosity`,opts.value.luminosity=pickerMode.value===`luminosity`,opts.value.saturation=pickerMode.value===`saturation`,saveCompactMode()}function loadCompactMode(){let readOption=(name,val=null)=>JSON.parse(localStorage.getItem(name)||JSON.stringify(val));opts.value.picker=readOption(`bngColorPicker-picker`,!0),opts.value.slider=readOption(`bngColorPicker-slider`,!1),pickerMode.value=readOption(`bngColorPicker-picker-mode`,`luminosity`),opts.value.luminosity=pickerMode.value===`luminosity`,opts.value.saturation=pickerMode.value===`saturation`,!opts.value.luminosity&&!opts.value.saturation&&(opts.value.luminosity=!0)}function saveCompactMode(){let saveOption=(name,val)=>localStorage.setItem(name,JSON.stringify(val));saveOption(`bngColorPicker-picker`,opts.value.picker),saveOption(`bngColorPicker-slider`,opts.value.slider),saveOption(`bngColorPicker-picker-mode`,pickerMode.value)}return onMounted(()=>{updColour(),!$simplemenu.value&&opts.value.compact&&loadCompactMode()}),(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,{class:normalizeClass({"colour-picker-container":!0,"colour-picker-mode-picker":opts.value.picker,"colour-picker-mode-slider":opts.value.slider,"colour-picker-mode-compact":opts.value.compact})},[opts.value.compact?(openBlock(),createElementBlock(`div`,_hoisted_1$329,[_cache[3]||=createBaseVNode(`span`,null,`Custom color`,-1),!unref($simplemenu)&&opts.value.picker?withDirectives((openBlock(),createBlock(unref(bngButton_default),{key:0,accent:unref(ACCENTS).text,icon:unref(icons).materialTransparency01,onClick:togglePickerMode},null,8,[`accent`,`icon`])),[[unref(BngTooltip_default),`Toggle vertical axis mode to ${pickerMode.value===`luminosity`?`saturation`:`brightness`}`,`top`]]):createCommentVNode(``,!0),unref($simplemenu)?createCommentVNode(``,!0):withDirectives((openBlock(),createBlock(unref(bngButton_default),{key:1,accent:opts.value.picker?unref(ACCENTS).outlined:unref(ACCENTS).text,icon:opts.value.picker?unref(icons).materialGlossy:unref(icons).listSmall,onClick:toggleCompactMode},null,8,[`accent`,`icon`])),[[unref(BngTooltip_default),`Toggle picker/slider mode`,`top`]])])):createCommentVNode(``,!0),opts.value.picker?withDirectives((openBlock(),createElementBlock(`div`,{key:1,class:`colour-picker`,onMousemove,onMousedown,onMouseup:onMouseupLeave,onMouseleave:onMouseupLeave,style:normalizeStyle({"--colour-picker-x":`linear-gradient(90deg, ${gradients.hueStatic.join(`, `)})`,"--colour-picker-y":`linear-gradient(180deg, ${gradients.pickerOverlay.join(`, `)})`})},[createBaseVNode(`div`,{class:`colour-picker-dot`,style:normalizeStyle({left:`${colorDot.value.x}%`,top:`${colorDot.value.y}%`,"--colour-picker-dot-fill":`hsl(${current.value.hue}, ${opts.value.saturation?current.value.saturation:100}%, ${opts.value.luminosity?current.value.luminosity:50}%)`})},null,4)],36)),[[unref(BngDisabled_default),__props.disabled]]):createCommentVNode(``,!0),opts.value.slider||opts.value.hue?(openBlock(),createBlock(unref(bngColorSlider_default),{key:2,modelValue:values.hue,"onUpdate:modelValue":_cache[0]||=$event=>values.hue=$event,modelModifiers:{number:!0},onChange:notify,fill:gradients.hue,current:`hsl(${current.value.hue}, 100%, 50%)`,indicator:sliderIndicator,step:__props.step,disabled:__props.disabled},{default:withCtx(()=>[createTextVNode(toDisplayString(__props.showText?_ctx.$t(`ui.color.hue`):null),1)]),_:1},8,[`modelValue`,`fill`,`current`,`step`,`disabled`])):createCommentVNode(``,!0),opts.value.slider||opts.value.luminosity?(openBlock(),createBlock(unref(bngColorSlider_default),{key:3,"X:vertical":`opts.picker`,modelValue:values.saturation,"onUpdate:modelValue":_cache[1]||=$event=>values.saturation=$event,modelModifiers:{number:!0},onChange:notify,fill:gradients.saturation,current:`hsl(${current.value.hue}, ${current.value.saturation}%, ${current.value.luminosity}%)`,indicator:sliderIndicator,step:__props.step,disabled:__props.disabled},{default:withCtx(()=>[createTextVNode(toDisplayString(__props.showText?`${_ctx.$t(`ui.color.saturation`)} (${current.value.saturation}%)`:null),1)]),_:1},8,[`modelValue`,`fill`,`current`,`step`,`disabled`])):createCommentVNode(``,!0),opts.value.slider||opts.value.saturation?(openBlock(),createBlock(unref(bngColorSlider_default),{key:4,"X:vertical":`opts.picker`,modelValue:values.luminosity,"onUpdate:modelValue":_cache[2]||=$event=>values.luminosity=$event,modelModifiers:{number:!0},onChange:notify,fill:gradients.luminosity,current:`hsl(${current.value.hue}, ${current.value.saturation}%, ${current.value.luminosity}%)`,indicator:sliderIndicator,step:__props.step,disabled:__props.disabled},{default:withCtx(()=>[createTextVNode(toDisplayString(__props.showText?`${_ctx.$t(`ui.color.brightness`)} (${current.value.luminosity}%)`:null),1)]),_:1},8,[`modelValue`,`fill`,`current`,`step`,`disabled`])):createCommentVNode(``,!0)],2))}},bngColorPicker_default=__plugin_vue_export_helper_default(_sfc_main$379,[[`__scopeId`,`data-v-f4241405`]]),_hoisted_1$328={key:0},_hoisted_2$263=[`min`,`max`,`step`,`tabindex`,`orient`],_hoisted_3$230={key:0,class:`colour-slider-indicator-container`},_sfc_main$378={__name:`bngColorSlider`,props:{modelValue:{type:[Number,String],default:0},min:{type:Number,default:0},max:{type:Number,default:1},step:{type:Number,default:.001},fill:{type:Array,default:[`rgb(0,0,0)`,`rgb(255,255,255)`]},current:{type:String,default:null},vertical:Boolean,disabled:Boolean,indicator:{type:String,default:`inner`,validator:val=>[`inner`,`popout`].includes(val)},uiNavFocus:{type:[Boolean,Object],default:{},validator:val=>typeof val==`boolean`&&!val||typeof val==`object`}},emits:[`update:modelValue`,`change`],setup(__props,{emit:__emit}){let props=__props,elSlider=ref(),elIndicator=ref(),tabIndex=computed(()=>props.disabled?-1:0),value=ref(props.modelValue);watch(()=>props.modelValue,val=>value.value=Number(val));let indicatorPos=computed(()=>props.indicator===`popout`?(value.value-props.min)/(props.max-props.min):0),indicatorRot=computed(()=>{if(props.indicator!==`popout`||!elSlider.value||!elIndicator.value||!elSlider.value.getBoundingClientRect||!elIndicator.value.firstChild||!elIndicator.value.firstChild.getBoundingClientRect)return 0;let tilt=40,rot=0,srect=elSlider.value.getBoundingClientRect(),irect=elIndicator.value.firstChild.getBoundingClientRect(),abspos=indicatorPos.value*srect.width,iwidth=irect.width/2;return absposwithDirectives((openBlock(),createElementBlock(`div`,{ref_key:`elSlider`,ref:elSlider,class:`colour-slider`,style:normalizeStyle({"--colour-slider-track-fill":__props.fill&&__props.fill.length>0?`linear-gradient(90deg, ${__props.fill.join(`, `)})`:`transparent`,"--colour-slider-thumb-fill":__props.indicator===`inner`&&__props.current?__props.current:`#000`,"--colour-slider-thumb-size":__props.indicator===`inner`&&__props.current?`1em`:`0.25em`,"--colour-slider-indicator-x":`${indicatorPos.value*100}%`,"--colour-slider-indicator-r":`${indicatorRot.value}deg`})},[_ctx.$slots.default&&!__props.vertical?(openBlock(),createElementBlock(`span`,_hoisted_1$328,[renderSlot(_ctx.$slots,`default`,{},void 0,!0)])):createCommentVNode(``,!0),createBaseVNode(`div`,null,[withDirectives(createBaseVNode(`input`,{type:`range`,min:__props.min,max:__props.max,step:__props.step,"onUpdate:modelValue":_cache[0]||=$event=>value.value=$event,onInput:notify,onChange:notify,tabindex:tabIndex.value,class:normalizeClass({"colour-slider-vertical":__props.vertical}),orient:__props.vertical?`vertical`:`horizontal`},null,42,_hoisted_2$263),[[vModelText,value.value,void 0,{number:!0}],[unref(BngOnUiNavFocus_default),__props.uiNavFocus?{callback:(dir,val)=>{value.value=val,notify()},value:()=>value.value,min:__props.min,max:__props.max,step:()=>+__props.step,...__props.uiNavFocus}:!1,void 0,{repeat:!0}]]),__props.indicator===`popout`?(openBlock(),createElementBlock(`div`,_hoisted_3$230,[createBaseVNode(`div`,{ref_key:`elIndicator`,ref:elIndicator,class:`colour-slider-indicator`},[createVNode(unref(bngIconMarker_default),{marker:`circlePin`,color:[`#fff`,__props.current],class:`colour-slider-indicator-marker`},null,8,[`color`])],512)])):createCommentVNode(``,!0)])],4)),[[unref(BngDisabled_default),__props.disabled]])}},bngColorSlider_default=__plugin_vue_export_helper_default(_sfc_main$378,[[`__scopeId`,`data-v-346533a2`]]),_hoisted_1$327={class:`bng-color-tile`},_sfc_main$377={__name:`bngColorTile`,props:{red:{type:Number},blue:{type:Number},green:{type:Number},alpha:{type:Number,default:1}},setup(__props){useCssVars(_ctx=>({cef4bc4e:backgroundColor.value}));let props=__props,backgroundColor=computed(()=>`rgba(${props.red}, ${props.green}, ${props.blue}, ${props.alpha})`);return(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$327))}},bngColorTile_default=__plugin_vue_export_helper_default(_sfc_main$377,[[`__scopeId`,`data-v-32089404`]]),_sfc_main$376={__name:`bngCondition`,props:{integrity:{type:Number,default:1},integrityWarning:Boolean,color:{type:[String,Array],default:`#000`},showTooltip:Boolean},setup(__props){let props=__props,integrity=computed(()=>typeof props.integrity==`number`?Math.min(Math.max(props.integrity,0),1):1),tooltip=computed(()=>{if(!props.showTooltip)return;let tip=`${$translate.instant(`ui.condition.integrity`)}: ${~~(integrity.value*100)}%`;return props.integrityWarning&&(tip+=`\n${$translate.instant(`ui.condition.needsRepair`)}`),tip}),cssColour=computed(()=>{let clr=props.color;return Array.isArray(clr)?(clr=[...clr],clr.length>3&&(clr.splice(3),clr.some(c=>c>1)||(clr=clr.map(c=>c*255))),`rgb(${clr.join(`,`)})`):clr}),cssClipPoly=computed(()=>{let val=integrity.value,corners=[`100% 0%`,`100% 100%`,`0% 100%`,`0% 0%`],poly=`0% 0%`;if(val===1)poly=corners.join(`, `);else if(val>0){let deg=(1-val)*360,x=50+50*Math.sin(deg*Math.PI/180),y=50-50*Math.cos(deg*Math.PI/180);poly=`50% 0%, 50% 50%, ${~~x}% ${~~y}%, `+corners.slice(-Math.ceil((360-deg)/90)).join(`, `)}return poly});return(_ctx,_cache)=>withDirectives((openBlock(),createElementBlock(`div`,{class:normalizeClass({"bng-condition":!0,"cond-warn":__props.integrityWarning}),style:normalizeStyle({backgroundColor:cssColour.value,"--bng-condition-clip-path":`polygon(${cssClipPoly.value})`})},null,6)),[[unref(BngTooltip_default),tooltip.value]])}},bngCondition_default=__plugin_vue_export_helper_default(_sfc_main$376,[[`__scopeId`,`data-v-686a3067`]]),SCOPED_CHANGED_EVENT_NAME=`scopeChanged`,EVENT_CROSSFIRE_MAP={ok:`select`,back:`back`,tab_l:`tabLeft`,tab_r:`tabRight`};const CROSSFIRE_HINTS={select:{id:`select`,content:{type:`binding`,props:{uiEvent:`ok`},label:`Select`}},back:{id:`back`,content:{type:`binding`,props:{uiEvent:`back`},label:`Back`}},tabLeft:{id:`tabLeft`,content:{type:`binding`,props:{uiEvent:`tab_l`},label:`Tab left`}},tabRight:{id:`tabRight`,content:{type:`binding`,props:{uiEvent:`tab_r`},label:`Tab right`}}},CROSSFIRE_HINTS_ALL=Object.values(CROSSFIRE_HINTS),DEFAULT_LABELS={focus_u:`ui.inputActions.controllerui.focus_u.title`,focus_r:`ui.inputActions.controllerui.focus_r.title`,focus_d:`ui.inputActions.controllerui.focus_d.title`,focus_l:`ui.inputActions.controllerui.focus_l.title`,pause:`ui.inputActions.general.pause.title`,menu:`ui.inputActions.controllerui.menu.title`,back:`ui.inputActions.controllerui.back.title`,details:`ui.inputActions.controllerui.details.title`,advanced:`ui.inputActions.controllerui.advanced.title`,camera:`ui.inputActions.controllerui.camera.title`,logs:`ui.inputActions.controllerui.logs.title`,tab_l:`ui.inputActions.controllerui.tab_l.title`,tab_r:`ui.inputActions.controllerui.tab_r.title`,modifier:`ui.inputActions.controllerui.modifier.title`,zoom_out:`ui.inputActions.controllerui.zoom_out.title`,zoom_in:`ui.inputActions.controllerui.zoom_in.title`,subtab_l:`ui.inputActions.controllerui.subtab_l.title`,subtab_r:`ui.inputActions.controllerui.subtab_r.title`,center_cam:`ui.inputActions.controllerui.center_cam.title`,action_4:`ui.inputActions.controllerui.action_4.title`,move_ud:`ui.inputActions.controllerui.move_ud.title`,move_lr:`ui.inputActions.controllerui.move_lr.title`,focus_ud:`ui.inputActions.controllerui.focus_ud.title`,focus_lr:`ui.inputActions.controllerui.focus_lr.title`,rotate_h_cam:`ui.inputActions.controllerui.rotate_h_cam.title`,rotate_v_cam:`ui.inputActions.controllerui.rotate_v_cam.title`,ok:`ui.inputActions.controllerui.ok.title`,cancel:`ui.inputActions.controllerui.cancel.title`,action_2:`ui.inputActions.controllerui.action_2.title`,action_3:`ui.inputActions.controllerui.action_3.title`,context:`ui.inputActions.controllerui.context.title`};var HINT_GROUPS=()=>[{names:[`back`,`menu`],label:`ui.inputActions.controllerui.back.title`},{names:[`focus_u`,`focus_d`,`focus_r`,`focus_l`,`focus_lr`,`focus_ud`],label:`ui.mainmenu.navbar.navigate`,controllerOnly:!0},{names:[`focus_u`,`focus_d`,`focus_r`,`focus_l`],label:`ui.mainmenu.navbar.navigate`},{names:[`focus_lr`,`focus_ud`],label:`ui.mainmenu.navbar.navigate`,controllerOnly:!0},{names:[SCROLL_EVENT_H,SCROLL_EVENT_V],label:`ui.mainmenu.navbar.scroll_label`,controllerOnly:!0},{names:[`tab_r`,`tab_l`],label:`ui.mainmenu.navbar.navigate`,controllerOnly:!0}],AUTOID=`__auto`,AUTOIDS={binding:`${AUTOID}_binding`,group:`${AUTOID}_group`,labelGroup:`${AUTOID}_label_group`},DISPLAY_ACTION_VARIANTS=!1;const useInfoBar=defineStore(`infoBar`,()=>{let{events:events$3}=useBridge(),Controls=controls_default(),{isControllerUsed,lastDevice}=storeToRefs(Controls),hintGroups=HINT_GROUPS(),visible=ref(!1),showSysInfo=ref(!1),withAngular=ref(!1),hintsList=ref([]),hints=ref([]);watch([isControllerUsed,lastDevice],()=>_groupHints());let getControlGroup=(uiEvents,groupLabel)=>{try{let actions=uiEvents.map(event=>ACTIONS_BY_UI_EVENT[event]).filter(Boolean);if(actions.length!==uiEvents.length)return null;let viewerObjs=actions.map(action=>Controls.makeViewerObj({action,actionVariants:DISPLAY_ACTION_VARIANTS,useLastDevice:!0})).flatMap(vo=>vo?.variants?vo.variants:vo?[vo]:[]),matchingItems=[],devNames=viewerObjs.reduce((res,obj)=>obj&&!res.includes(obj.devName)?[...res,obj.devName]:res,[]);for(let devName of devNames){if(!devName)continue;let devViewerObjs=viewerObjs.filter(obj=>obj&&obj.devName===devName&&obj.ownGroups);if(devViewerObjs.length===0)continue;let groups=devViewerObjs[0].ownGroups,controls$1=devViewerObjs.map(obj=>obj.control);for(let group of groups){if(!group.controls.every(control=>controls$1.includes(control)))continue;controls$1=controls$1.filter(control=>!group.controls.includes(control));let item;item=group.label?{type:`binding`,props:{viewerObj:{icon:devViewerObjs[0].icon,ownLabel:group.label}},label:groupLabel}:{type:`icon`,props:{type:icons[group.icon]},label:groupLabel},matchingItems.push(item)}}return matchingItems.length===0?null:matchingItems.length===1?matchingItems[0]:matchingItems}catch(err){return logger_default.error(`Error in checkForControlGroup:`,err),null}},_groupHints=()=>{let res=[],groupCandidates={},labelGroups={},isCustomLabel=content=>content&&!content.autoLabel&&content?.props?.uiEvent&&content.label!==DEFAULT_LABELS[content?.props?.uiEvent];for(let hint of hintsList.value){let normalizedHint=hint.content?hint:{content:hint},{content}=normalizedHint;if(!content?.props?.uiEvent||!content.label){res.push(normalizedHint);continue}let labelKey=content.label;labelGroups[labelKey]?labelGroups[labelKey].hints.push(normalizedHint):labelGroups[labelKey]={hints:[normalizedHint],position:res.length}}let selectMatchingGroup=matchingGroups=>matchingGroups.length<1||isControllerUsed.value?matchingGroups[0]:matchingGroups.find(group=>!group.controllerOnly)||matchingGroups.at(-1);for(let[label,group]of Object.entries(labelGroups)){let action=group.hints[0].action;if(group.hints.length>1){let events$4=group.hints.map(h$1=>h$1.content.props.uiEvent),matchingGroup=selectMatchingGroup(hintGroups.filter(g=>g.content&&g.names.every(name=>events$4.includes(name))&&events$4.filter(e=>g.names.includes(e)).length===g.names.length));if(matchingGroup){if(matchingGroup.controllerOnly&&!isControllerUsed.value)continue;let groupContent=Array.isArray(matchingGroup.content)?matchingGroup.content[0]:matchingGroup.content,groupLabel=matchingGroup.label||groupContent?.label||group.hints[0]?.content?.label,groupEvents=group.hints.map(h$1=>h$1.content.props.uiEvent),labeledBindings=group.hints.map(h$1=>{let newContent={id:h$1.id,type:h$1.content.type,props:{...h$1.content.props}};return newContent.label=isCustomLabel(h$1.content)?h$1.content.label:groupLabel,newContent}),controlGroup=getControlGroup(groupEvents,groupLabel);if(controlGroup){let content=Array.isArray(controlGroup)?controlGroup.map(item=>({...item})):[{...controlGroup}],customLabelItem=group.hints.find(h$1=>isCustomLabel(h$1.content));customLabelItem&&content.forEach(item=>{item.label=customLabelItem.content.label}),res.splice(group.position,0,{id:`${AUTOIDS.labelGroup}_${label}`,content,action})}else res.splice(group.position,0,{id:`${AUTOIDS.labelGroup}_${label}`,content:labeledBindings,action})}else res.splice(group.position,0,{id:`${AUTOIDS.labelGroup}_${label}`,content:group.hints.map(h$1=>h$1.content),action})}else{let hint=group.hints[0],uiEvent=hint.content?.props?.uiEvent,isNoGroup=uiEvent$1=>uiNavTracker.activeEvents.find(e=>e.name===uiEvent$1)?.nogroup;if(isNoGroup(uiEvent)){res.push(hint);continue}let matchingGroup=selectMatchingGroup(hintGroups.filter(group$1=>group$1.names.includes(uiEvent)));if(!matchingGroup){res.push(hint);continue}let groupId=matchingGroup.names.join(`,`);groupId in groupCandidates||(groupCandidates[groupId]={hints:[],content:[],position:res.length});let groupCandidate=groupCandidates[groupId];if(groupCandidate.hints.push(hint),groupCandidate.content.push(hint.content),groupCandidate.hints.length===matchingGroup.names.length){if(matchingGroup.controllerOnly&&!isControllerUsed.value){delete groupCandidates[groupId];continue}if(groupCandidate.hints.some(h$1=>isNoGroup(h$1.content?.props?.uiEvent)))res.splice(groupCandidate.position,0,...groupCandidate.hints);else{let groupContent=Array.isArray(matchingGroup.content)?matchingGroup.content[0]:matchingGroup.content,groupLabel=matchingGroup.label||groupContent?.label||groupCandidate.hints[0]?.content?.label,labeledContent=groupCandidate.content.map(item=>{let newContent={id:item.id,type:item.type,props:{...item.props}};return isCustomLabel(item)?newContent.label=item.label:newContent.label=groupLabel,newContent}),controlGroup=getControlGroup(groupCandidate.hints.map(h$1=>h$1.content.props.uiEvent),groupLabel);if(controlGroup){let content=Array.isArray(controlGroup)?controlGroup.map(icon=>({...icon})):[{...controlGroup}],customLabelItem=groupCandidate.content.find(item=>isCustomLabel(item));customLabelItem&&content.forEach(icon=>icon.label=customLabelItem.label),res.splice(groupCandidate.position,0,{id:`${AUTOIDS.group}_${groupId}`,content,action})}else res.splice(groupCandidate.position,0,{id:`${AUTOIDS.group}_${groupId}`,content:labeledContent,action})}delete groupCandidates[groupId]}}}for(let group of Object.values(groupCandidates))res.splice(group.position,0,...group.hints);hints.value=res},uiNavTracker=useUINavTracker(),clearHints=()=>{hintsList.value=[],_addTrackedEvents()},addHints=(hintOrHints,idOrPos=void 0,before=!1)=>{if(hintOrHints===CROSSFIRE_HINTS_ALL){logger_default.warn(`Approach with CROSSFIRE_HINTS_ALL is deprecated and crossfire hints are added by default.`);return}let toAdd=[hintOrHints].flat().map(hint=>{if(typeof hint!=`object`)return hint;let content=hint.content||hint,uiEvent=content?.props?.uiEvent;return uiEvent&&(content.label||(content.autoLabel=!0,uiEvent in DEFAULT_LABELS?content.label=DEFAULT_LABELS[uiEvent]:content.label=uiEvent.replaceAll(`_`,` `).toUpperCase())),hint});if(idOrPos===void 0)hintsList.value=hintsList.value.concat(toAdd);else if(typeof idOrPos==`number`)hintsList.value.splice(idOrPos,0,...toAdd);else if(typeof idOrPos==`string`){let foundIndex=_findHintIndex(idOrPos);foundIndex>-1&&hintsList.value.splice(foundIndex+(before?0:1),0,...toAdd)}_groupHints()},updateHint=(idOrPos,updatedHint)=>{if(typeof idOrPos==`number`)hintsList.value[idOrPos]=updatedHint;else{let foundIndex=_findHintIndex(idOrPos);hintsList.value[foundIndex]=updatedHint}_groupHints()},removeHints=(...ids)=>{ids.forEach(id=>{let foundIndex=_findHintIndex(id);foundIndex>-1&&hintsList.value.splice(foundIndex,1)}),_groupHints()},flashHints=(...ids)=>{_setFlash(!1,ids),setTimeout(()=>_setFlash(!0,ids),0)},_setFlash=(state,ids)=>ids.forEach(id=>{let foundIndex=_findHintIndex(id);foundIndex>-1&&(hintsList.value[foundIndex].flash=state)}),highlightHints=(state,...ids)=>{},_findHintIndex=id=>hintsList.value.findIndex(h$1=>h$1.id===id);events$3.on(SCOPED_CHANGED_EVENT_NAME,data=>{logger_default.debug(`[infoBar] received data`,data),data&&(clearHints(),data.forEach(ev=>{let content;content=ev.label?{content:{type:`binding`,props:{uiEvent:ev.event},label:ev.label}}:CROSSFIRE_HINTS[EVENT_CROSSFIRE_MAP[ev.event]],addHints(content)}))});function _addTrackedEvents(){let activeEvents=uiNavTracker.activeEvents;hintsList.value=hintsList.value.filter(hint=>!hint.id?.startsWith(AUTOID)&&activeEvents.some(e=>e.name===hint.content.props.uiEvent));let currentBindings=hintsList.value.filter(hint=>hint.content?.type===`binding`).map(hint=>hint.content.props.uiEvent);addHints(activeEvents.filter(({name})=>!currentBindings.includes(name)).map(({name,label,nogroup,action})=>({id:`${AUTOIDS.binding}_${name}`,content:{type:`binding`,props:{uiEvent:name},label,autoLabel:!label||label===DEFAULT_LABELS[name]},nogroup,action})))}return watch(()=>uiNavTracker.activeEvents,_addTrackedEvents,{deep:!0}),{visible,hintsList,hints,showSysInfo,withAngular,clearHints,addHints,updateHint,removeHints,flashHints,highlightHints}});var _hoisted_1$326={key:0,xmlns:`http://www.w3.org/2000/svg`,viewBox:`20 140 460 220`},_hoisted_2$262={class:`bng-controller-hint-labels`},_hoisted_3$229={x:`120`,y:`165`,"text-anchor":`middle`},_hoisted_4$196={x:`120`,y:`335`,"text-anchor":`middle`},_hoisted_5$166={x:`45`,y:`255`,"text-anchor":`end`},_hoisted_6$142={x:`175`,y:`255`,"text-anchor":`start`},_hoisted_7$124={x:`219`,y:`315`,"text-anchor":`middle`},_hoisted_8$102={x:`249`,y:`315`,"text-anchor":`middle`},_hoisted_9$92={x:`340`,y:`175`,"text-anchor":`middle`},_hoisted_10$80={x:`380`,y:`335`,"text-anchor":`middle`},_sfc_main$375={__name:`bngControllerHint`,props:{device:String,actions:[Array,String],dark:Boolean},setup(__props,{expose:__expose}){let Controls=controls_default(),props=__props,available=[`xbox`],devName=computed(()=>{if(!props.device)return Controls.lastDevice;let devName$1=props.device;return/\d$/.test(devName$1)||(devName$1=Controls.lastDevices.find(dev=>dev.startsWith(devName$1)),devName$1||=props.device+`0`),devName$1}),devFamily=computed(()=>{let family=Controls.makeViewerObj({device:devName.value,uiEvent:`back`})?.family;return!family||!available.includes(family)?null:family});__expose({displayed:computed(()=>!!devFamily.value)});let actions=computed(()=>{let actions$1=props.actions;if(!actions$1||!devFamily.value)return{};if(typeof actions$1==`string`)actions$1=[actions$1];else if(!Array.isArray(actions$1)||actions$1.length===0)return{};let bindings={},allEvents=Object.keys(ACTIONS_BY_UI_EVENT),allActions=Object.values(ACTIONS_BY_UI_EVENT);for(let action of actions$1){if(!action)continue;let item=action;if(typeof item==`string`)item={action:item};else if(!item.action&&!item.event)continue;else item={...item};let actIdx=allEvents.indexOf(item.event||item.action);if(actIdx>-1&&(item.event=allEvents[actIdx],item.action=allActions[actIdx]),!allActions.includes(item.action))continue;let binding=Controls.findBindingForAction(item.action,devName.value);if(binding){if(!item.event||item.event===item.action){let idx=allActions.indexOf(item.action);idx>-1&&(item.event=allEvents[idx])}item.label||=DEFAULT_LABELS[item.event]||item.event||item.action,item.shown=!0,item.class={flash:item.flash},bindings[binding.control.toLowerCase()]=item}}logger_default.debug(`resolved actions:`,bindings);for(let keyName of DEVICE_CONTROLS[devFamily.value]){let key=keyName.toLowerCase();key in bindings||(bindings[key]={class:{inactive:!0}})}return bindings});return(_ctx,_cache)=>devFamily.value?(openBlock(),createElementBlock(`div`,{key:0,class:normalizeClass([`bng-controller-hint`,{"bng-controller-hint-dark":__props.dark}])},[devFamily.value===`xbox`?(openBlock(),createElementBlock(`svg`,_hoisted_1$326,[_cache[8]||=createBaseVNode(`rect`,{x:`60`,y:`180`,width:`380`,height:`140`,rx:`20`,fill:`#bcbcbc`,stroke:`#333`,"stroke-width":`8`},null,-1),_cache[9]||=createBaseVNode(`circle`,{cx:`120`,cy:`250`,r:`28`,fill:`#222`},null,-1),createBaseVNode(`rect`,{class:normalizeClass(actions.value.upov.class),x:`114`,y:`222`,width:`12`,height:`20`,rx:`3`,fill:`#444`},null,2),createBaseVNode(`rect`,{class:normalizeClass(actions.value.dpov.class),x:`114`,y:`258`,width:`12`,height:`20`,rx:`3`,fill:`#444`},null,2),createBaseVNode(`rect`,{class:normalizeClass(actions.value.lpov.class),x:`98`,y:`242`,width:`20`,height:`12`,rx:`3`,fill:`#444`},null,2),createBaseVNode(`rect`,{class:normalizeClass(actions.value.rpov.class),x:`122`,y:`242`,width:`20`,height:`12`,rx:`3`,fill:`#444`},null,2),createBaseVNode(`rect`,{class:normalizeClass(actions.value.btn_start.class),x:`210`,y:`240`,width:`18`,height:`10`,rx:`3`,fill:`#888`},null,2),createBaseVNode(`rect`,{class:normalizeClass(actions.value.btn_back.class),x:`240`,y:`240`,width:`18`,height:`10`,rx:`3`,fill:`#888`},null,2),createBaseVNode(`circle`,{class:normalizeClass(actions.value.btn_a.class),cx:`340`,cy:`230`,r:`18`,fill:`#22a`},null,2),createBaseVNode(`circle`,{class:normalizeClass(actions.value.btn_b.class),cx:`380`,cy:`270`,r:`18`,fill:`#22a`},null,2),createBaseVNode(`g`,_hoisted_2$262,[actions.value.upov?.shown?(openBlock(),createElementBlock(Fragment,{key:0},[_cache[0]||=createBaseVNode(`line`,{x1:`120`,y1:`202`,x2:`120`,y2:`170`,stroke:`#666`,"stroke-width":`2`},null,-1),createBaseVNode(`text`,_hoisted_3$229,toDisplayString(_ctx.$tt(actions.value.upov?.label)),1)],64)):createCommentVNode(``,!0),actions.value.dpov?.shown?(openBlock(),createElementBlock(Fragment,{key:1},[_cache[1]||=createBaseVNode(`line`,{x1:`120`,y1:`298`,x2:`120`,y2:`320`,stroke:`#666`,"stroke-width":`2`},null,-1),createBaseVNode(`text`,_hoisted_4$196,toDisplayString(_ctx.$tt(actions.value.dpov?.label)),1)],64)):createCommentVNode(``,!0),actions.value.lpov?.shown?(openBlock(),createElementBlock(Fragment,{key:2},[_cache[2]||=createBaseVNode(`line`,{x1:`78`,y1:`250`,x2:`50`,y2:`250`,stroke:`#666`,"stroke-width":`2`},null,-1),createBaseVNode(`text`,_hoisted_5$166,toDisplayString(_ctx.$tt(actions.value.lpov?.label)),1)],64)):createCommentVNode(``,!0),actions.value.rpov?.shown?(openBlock(),createElementBlock(Fragment,{key:3},[_cache[3]||=createBaseVNode(`line`,{x1:`142`,y1:`250`,x2:`170`,y2:`250`,stroke:`#666`,"stroke-width":`2`},null,-1),createBaseVNode(`text`,_hoisted_6$142,toDisplayString(_ctx.$tt(actions.value.rpov?.label)),1)],64)):createCommentVNode(``,!0),actions.value.btn_start?.shown?(openBlock(),createElementBlock(Fragment,{key:4},[_cache[4]||=createBaseVNode(`line`,{x1:`219`,y1:`270`,x2:`219`,y2:`300`,stroke:`#666`,"stroke-width":`2`},null,-1),createBaseVNode(`text`,_hoisted_7$124,toDisplayString(_ctx.$tt(actions.value.btn_start?.label)),1)],64)):createCommentVNode(``,!0),actions.value.btn_back?.shown?(openBlock(),createElementBlock(Fragment,{key:5},[_cache[5]||=createBaseVNode(`line`,{x1:`249`,y1:`270`,x2:`249`,y2:`300`,stroke:`#666`,"stroke-width":`2`},null,-1),createBaseVNode(`text`,_hoisted_8$102,toDisplayString(_ctx.$tt(actions.value.btn_back?.label)),1)],64)):createCommentVNode(``,!0),actions.value.btn_a?.shown?(openBlock(),createElementBlock(Fragment,{key:6},[_cache[6]||=createBaseVNode(`line`,{x1:`340`,y1:`212`,x2:`340`,y2:`180`,stroke:`#666`,"stroke-width":`2`},null,-1),createBaseVNode(`text`,_hoisted_9$92,toDisplayString(_ctx.$tt(actions.value.btn_a?.label)),1)],64)):createCommentVNode(``,!0),actions.value.btn_b?.shown?(openBlock(),createElementBlock(Fragment,{key:7},[_cache[7]||=createBaseVNode(`line`,{x1:`380`,y1:`288`,x2:`380`,y2:`320`,stroke:`#666`,"stroke-width":`2`},null,-1),createBaseVNode(`text`,_hoisted_10$80,toDisplayString(_ctx.$tt(actions.value.btn_b?.label)),1)],64)):createCommentVNode(``,!0)])])):createCommentVNode(``,!0)],2)):createCommentVNode(``,!0)}},bngControllerHint_default=__plugin_vue_export_helper_default(_sfc_main$375,[[`__scopeId`,`data-v-bb01f791`]]),_sfc_main$374={},_hoisted_1$325={class:`divider vertical-divider`};function _sfc_render$6(_ctx,_cache){return openBlock(),createElementBlock(`div`,_hoisted_1$325)}var bngDivider_default=__plugin_vue_export_helper_default(_sfc_main$374,[[`render`,_sfc_render$6],[`__scopeId`,`data-v-c3fbf7df`]]),_sfc_main$373={__name:`bngDrawer`,props:mergeModels({header:String,blur:Boolean,expandable:{type:Boolean,default:!0},position:String},{modelValue:{type:Boolean},modelModifiers:{}}),emits:mergeModels([`change`],[`update:modelValue`]),setup(__props,{emit:__emit}){let props=__props,emit$1=__emit,slots=useSlots(),arrows=computed(()=>{switch(props.position){default:case DRAWER_POSITION.bottom:case DRAWER_POSITION.right:return{expand:icons.arrowLargeUp,collapse:icons.arrowLargeDown};case DRAWER_POSITION.top:case DRAWER_POSITION.left:return{expand:icons.arrowLargeDown,collapse:icons.arrowLargeUp}}}),expanded=useModel(__props,`modelValue`);return watch(()=>expanded.value,val=>emit$1(`change`,val)),watch([()=>props.expandable,()=>expanded.value],()=>!props.expandable&&expanded.value&&(expanded.value=!1),{immediate:!0}),(_ctx,_cache)=>(openBlock(),createBlock(unref(drawer_default),{modelValue:expanded.value,"onUpdate:modelValue":_cache[1]||=$event=>expanded.value=$event,blur:__props.blur,position:__props.position},createSlots({header:withCtx(()=>[createVNode(unref(bngCardHeading_default),{class:`header`,type:`ribbon`,style:normalizeStyle({marginRight:!__props.header&&!unref(slots).header?`0`:void 0})},{default:withCtx(()=>[__props.header?(openBlock(),createElementBlock(Fragment,{key:0},[createTextVNode(toDisplayString(__props.header),1)],64)):renderSlot(_ctx.$slots,`header`,{key:1},()=>[_cache[2]||=createBaseVNode(`span`,null,null,-1)],!0)]),_:3},8,[`style`]),renderSlot(_ctx.$slots,`header-controls`,{},void 0,!0),__props.expandable?(openBlock(),createBlock(unref(bngButton_default),{key:0,accent:`text`,icon:expanded.value?arrows.value.collapse:arrows.value.expand,onClick:_cache[0]||=$event=>expanded.value=!expanded.value},null,8,[`icon`])):createCommentVNode(``,!0)]),_:2},[`content`in unref(slots)?{name:`content`,fn:withCtx(()=>[renderSlot(_ctx.$slots,`content`,{},void 0,!0)]),key:`0`}:void 0,`expanded-content`in unref(slots)?{name:`expanded-content`,fn:withCtx(()=>[renderSlot(_ctx.$slots,`expanded-content`,{},void 0,!0)]),key:`1`}:`default`in unref(slots)?{name:`expanded-content`,fn:withCtx(()=>[renderSlot(_ctx.$slots,`default`,{},void 0,!0)]),key:`2`}:void 0]),1032,[`modelValue`,`blur`,`position`]))}},bngDrawer_default=__plugin_vue_export_helper_default(_sfc_main$373,[[`__scopeId`,`data-v-30948d98`]]),_hoisted_1$324={class:`bng-drawer`},_hoisted_2$261={class:`header-wrapper`},_hoisted_3$228={class:`content`},_sfc_main$372={__name:`bngDrawerOld`,props:{header:{type:String},blur:{type:Boolean,default:!1}},setup(__props){return(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$324,[withDirectives((openBlock(),createElementBlock(`div`,_hoisted_2$261,[createVNode(unref(bngCardHeading_default),{class:`header`,type:`ribbon`},{default:withCtx(()=>[__props.header?(openBlock(),createElementBlock(Fragment,{key:0},[createTextVNode(toDisplayString(__props.header),1)],64)):renderSlot(_ctx.$slots,`header`,{key:1},void 0,!0)]),_:3}),renderSlot(_ctx.$slots,`headerOptions`,{},void 0,!0)])),[[unref(BngBlur_default),__props.blur]]),withDirectives((openBlock(),createBlock(unref(bngCard_default),null,{default:withCtx(()=>[createBaseVNode(`div`,_hoisted_3$228,[renderSlot(_ctx.$slots,`content`,{},void 0,!0)])]),_:3})),[[unref(BngBlur_default),__props.blur]])]))}},bngDrawerOld_default=__plugin_vue_export_helper_default(_sfc_main$372,[[`__scopeId`,`data-v-9e5c32b1`]]),_hoisted_1$323={class:`dropdown-display`},_hoisted_2$260={key:0,class:`dropdown-search`},_hoisted_3$227={key:1},_hoisted_4$195={key:0,class:`dropdown-group-header`},_hoisted_5$165=[`bng-nav-item`,`tabindex`,`bng-scoped-nav-autofocus`,`onClick`,`onKeyup`],_sfc_main$371={__name:`bngDropdown`,props:{modelValue:{type:[Number,String,Boolean,Object]},items:{type:Array,required:!0},showSearch:Boolean,highlight:{type:[String,Array,RegExp]},disabled:Boolean,longNames:{type:String,default:`oneline`,validator:val=>[`oneline`,`wrap`,`cut`].includes(val)},searchGroupName:Boolean,headless:Boolean,focusTarget:Object,popoverTarget:Object},emits:[`update:modelValue`,`valueChanged`,`open`,`close`],setup(__props,{expose:__expose,emit:__emit}){let attrs=useAttrs(),binds=computed(()=>props.headless?void 0:attrs),props=__props,emit$1=__emit,elContainer=ref(null),opened=ref(!1),searching=ref(!1),search$1=ref(``),searchTerm=computed(()=>search$1.value.toLowerCase());watch(opened,val=>!val&&(search$1.value=``)),__expose({opened,open:()=>opened.value=!0,close:()=>opened.value=!1,toggle:()=>opened.value=!opened.value,get popoverName(){return elContainer.value?.popoverName}});let groupedItems=computed(()=>{let hasGrouping=props.items.some(item=>item.group||item.grouped),searchActive=!!searchTerm.value;if(!hasGrouping)return[{header:null,items:searchActive?props.items.filter(item=>item.label.toLowerCase().includes(searchTerm.value)):props.items}];let groups=[],currentGroup=null;return props.items.forEach(item=>{item.group?(currentGroup={header:item,allItems:[],_headerMatches:item.label.toLowerCase().includes(searchTerm.value)},groups.push(currentGroup)):item.grouped?currentGroup?currentGroup.allItems.push(item):groups.push({header:null,allItems:[item]}):(groups.push({header:null,allItems:[item]}),currentGroup=null)}),groups.map(group=>{if(searchActive)if(group.header){if(props.searchGroupName&&group._headerMatches)return{header:group.header,items:group.allItems,headerMatches:!0};{let filteredItems=group.allItems.filter(item=>item.label.toLowerCase().includes(searchTerm.value));return{header:group.header,items:filteredItems,headerMatches:!1}}}else return{header:null,items:group.allItems.filter(item=>item.label.toLowerCase().includes(searchTerm.value))};else return{header:group.header||null,items:group.allItems}}).filter(group=>group.header&&props.searchGroupName&&group.headerMatches||group.items.length>0)}),highlighter$1=computed(()=>search$1.value||props.highlight),selectedValue=computed({get:()=>props.modelValue,set:newValue=>{emit$1(`update:modelValue`,newValue),emit$1(`valueChanged`,newValue)}}),selectedItem=computed(()=>props.items.find(x=>x.value===selectedValue.value)),headerText=computed(()=>selectedItem.value&&selectedItem.value.value!==null&&selectedItem.value.value!==void 0?selectedItem.value.label:`Select`),tabIndexValue=computed(()=>props.disabled?-1:0),select=item=>{item.disabled||(opened.value=!1,selectedValue.value!==item.value&&(selectedValue.value=item.value),elContainer.value?.focusContainer())};return(_ctx,_cache)=>(openBlock(),createBlock(unref(bngDropdownContainer_default),mergeProps({ref_key:`elContainer`,ref:elContainer},binds.value,{opened:opened.value,"onUpdate:opened":_cache[3]||=$event=>opened.value=$event,disabled:__props.disabled,headless:__props.headless,"focus-target":__props.focusTarget,"popover-target":__props.popoverTarget,class:{"with-search":__props.showSearch,[`dropdown-longnames-${__props.longNames}`]:!0},onShow:_cache[4]||=$event=>emit$1(`open`),onHide:_cache[5]||=$event=>emit$1(`close`)}),createSlots({default:withCtx(()=>[__props.showSearch?(openBlock(),createElementBlock(`div`,_hoisted_2$260,[createVNode(unref(bngInput_default),{modelValue:search$1.value,"onUpdate:modelValue":_cache[0]||=$event=>search$1.value=$event,modelModifiers:{trim:!0},"floating-label":`Search`,onFocus:_cache[1]||=$event=>searching.value=!0,onBlur:_cache[2]||=$event=>searching.value=!1},null,8,[`modelValue`])])):createCommentVNode(``,!0),search$1.value&&groupedItems.value.every(group=>group.items.length===0)?(openBlock(),createElementBlock(`div`,_hoisted_3$227,toDisplayString(_ctx.$t(`ui.common.search.noResults`)),1)):(openBlock(!0),createElementBlock(Fragment,{key:2},renderList(groupedItems.value,(group,groupIndex)=>(openBlock(),createElementBlock(Fragment,{key:groupIndex},[group.header?(openBlock(),createElementBlock(`div`,_hoisted_4$195,toDisplayString(group.header.label),1)):createCommentVNode(``,!0),(openBlock(!0),createElementBlock(Fragment,null,renderList(group.items,(item,idx)=>withDirectives((openBlock(),createElementBlock(`div`,{key:item.value,class:normalizeClass([`dropdown-option`,{selected:selectedItem.value&&selectedItem.value.value===item.value,"grouped-item":group.header,disabled:item.disabled}]),"bng-nav-item":!item.disabled||item.focusable,tabindex:item.disabled?-1:tabIndexValue.value,"bng-scoped-nav-autofocus":!item.disabled&&!searching.value&&(selectedItem.value&&selectedItem.value.value===item.value||!selectedItem.value&&groupIndex===0&&idx===0),onClick:$event=>select(item),onKeyup:withKeys($event=>select(item),[`enter`])},[createTextVNode(toDisplayString(item.label),1)],42,_hoisted_5$165)),[[unref(BngOnUiNav_default),void 0,`ok`,{asMouse:!0,focusRequired:!0}],[unref(BngUiNavLabel_default),`ui.inputActions.menu.menu_item_select.title`,`ok`],[unref(BngTooltip_default),item.tooltip??void 0],[unref(BngHighlighter_default),highlighter$1.value]])),128))],64))),128))]),_:2},[__props.headless?void 0:{name:`display`,fn:withCtx(()=>[renderSlot(_ctx.$slots,`display`,{},()=>[withDirectives((openBlock(),createElementBlock(`span`,_hoisted_1$323,[createTextVNode(toDisplayString(headerText.value),1)])),[[unref(BngHighlighter_default),highlighter$1.value]])],!0)]),key:`0`}]),1040,[`opened`,`disabled`,`headless`,`focus-target`,`popover-target`,`class`]))}},bngDropdown_default=__plugin_vue_export_helper_default(_sfc_main$371,[[`__scopeId`,`data-v-96e56708`]]),popoverBaseName=`bng-dropdown-content`,_sfc_main$370=Object.assign({inheritAttrs:!1},{__name:`bngDropdownContainer`,props:mergeModels({disabled:Boolean,class:[String,Array,Object],headless:Boolean,focusTarget:Object,popoverTarget:Object},{opened:{},openedModifiers:{}}),emits:mergeModels([`provideFocus`,`show`,`hide`],[`update:opened`]),setup(__props,{expose:__expose,emit:__emit}){let navBlocker=useUINavBlocker(),props=__props,attrs=useAttrs(),binds=computed(()=>({...attrs,tabindex:props.headless?-1:0,"bng-nav-item":props.headless?void 0:``})),opened=useModel(__props,`opened`);function open$1(val){opened.value=val,val?(navBlocker.allowOnly([`focus_u`,`focus_d`,`focus_ud`,`back`,`menu`,`ok`]),emit$1(`show`)):(navBlocker.clear(),emit$1(`hide`),focusTarget.value&&setFocusExternal(focusTarget.value,!0,!1))}let emit$1=__emit,popover=usePopover(),popoverName=uniqueId(popoverBaseName),container=ref(null),content=ref(null),focusTarget=computed(()=>props.focusTarget||container.value),popoverTarget=computed(()=>props.popoverTarget||container.value),placement=ref(`bottom-start`),openedTop=computed(()=>placement.value.startsWith(`top`));return watch(()=>opened.value,value=>{value?(Object.keys(popover.popovers).filter(name=>popover.popovers[name].show&&name!==popoverName&&!popover.popovers[name].element.contains(popover.popovers[popoverName].target)).forEach(name=>popover.hide(name)),!popover.popovers[popoverName].show&&popoverTarget.value&&popover.show(popoverName,popoverTarget.value)):popover.hide(popoverName)}),__expose({opened,open:()=>opened.value=!0,close:()=>opened.value=!1,toggle:()=>opened.value=!opened.value,focusContainer:()=>focusTarget.value&&setFocusExternal(focusTarget.value),popoverName}),(_ctx,_cache)=>(openBlock(),createElementBlock(Fragment,null,[__props.headless?createCommentVNode(``,!0):withDirectives((openBlock(),createElementBlock(`div`,mergeProps({key:0,ref_key:`container`,ref:container},binds.value,{class:[`bng-dropdown`,props.class]}),[createVNode(unref(bngIcon_default),{type:unref(icons).arrowSmallRight,class:normalizeClass({"dropdown-arrow":!0,"dropdown-arrow-top":openedTop.value,opened:opened.value})},null,8,[`type`,`class`]),renderSlot(_ctx.$slots,`display`,{},()=>[_cache[8]||=createTextVNode(`Select`,-1)],!0)],16)),[[unref(BngDisabled_default),__props.disabled],[unref(BngOnUiNav_default),void 0,`ok`,{asMouse:!0,focusRequired:!0}],[unref(BngPopover_default),unref(popoverName),`bottom-start`,{click:!0}]]),createVNode(unref(bngPopoverContent_default),{name:unref(popoverName),onShow:_cache[5]||=$event=>open$1(!0),onHide:_cache[6]||=$event=>open$1(!1),"hide-arrow":``,onPlacementChanged:_cache[7]||=value=>placement.value=value},{default:withCtx(()=>[withDirectives((openBlock(),createElementBlock(`div`,{ref_key:`content`,ref:content,class:normalizeClass([`bng-dropdown-content`,__props.class]),"bng-nav-scroll":``,onClick:_cache[0]||=withModifiers(()=>{},[`stop`]),onMouseover:_cache[1]||=withModifiers(()=>{},[`stop`]),onMouseenter:_cache[2]||=withModifiers(()=>{},[`stop`]),onMousedown:_cache[3]||=withModifiers(()=>{},[`stop`]),onMouseup:_cache[4]||=withModifiers(()=>{},[`stop`])},[opened.value?renderSlot(_ctx.$slots,`default`,{key:0},void 0,!0):createCommentVNode(``,!0)],34)),[[unref(BngAutoScroll_default),void 0,`top`],[unref(BngUiNavLabel_default),`ui.common.close`,`back,menu`],[unref(BngUiNavLabel_default),`ui.mainmenu.navbar.navigate`,`focus_u,focus_d`],[unref(BngUiNavScroll_default)],[unref(BngOnUiNav_default),()=>open$1(!1),`menu`]])]),_:3},8,[`name`])],64))}}),bngDropdownContainer_default=__plugin_vue_export_helper_default(_sfc_main$370,[[`__scopeId`,`data-v-840dc960`]]),icons$2=Object.freeze({"4WD":{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/4WD.svg`},"9dividedby10":{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/9dividedby10.svg`},abandon:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/abandon.svg`},ABSIndicator:{glyph:``,size:24,tags:[`vehicle`,`features`,`warning`,`internals`],fileSvg:`svg/ABSIndicator.svg`},addItemPolygon:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`,`road tools`],fileSvg:`svg/addItemPolygon.svg`},addListItem:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`,`road tools`],fileSvg:`svg/addListItem.svg`},addPolygonVertex:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`,`road tools`],fileSvg:`svg/addPolygonVertex.svg`},adjust:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/adjust.svg`},AIMicrochip:{glyph:``,size:24,tags:[`generic`,`ai`,`microchip`],fileSvg:`svg/AIMicrochip.svg`},AIRace:{glyph:``,size:24,tags:[`poi`],fileSvg:`svg/AIRace.svg`},aperture:{glyph:``,size:24,tags:[`generic`,`camera`,`optical`,`sensor`],fileSvg:`svg/aperture.svg`},arrowLargeDown:{glyph:``,size:24,tags:[`arrow`,`large`,`simple`,`outlined`],fileSvg:`svg/arrowLargeDown.svg`},arrowLargeLeft:{glyph:``,size:24,tags:[`arrow`,`large`,`simple`,`outlined`],fileSvg:`svg/arrowLargeLeft.svg`},arrowLargeRight:{glyph:``,size:24,tags:[`arrow`,`large`,`simple`,`outlined`],fileSvg:`svg/arrowLargeRight.svg`},arrowLargeUp:{glyph:``,size:24,tags:[`arrow`,`large`,`simple`,`outlined`],fileSvg:`svg/arrowLargeUp.svg`},arrowSmallDown:{glyph:``,size:24,tags:[`arrow`,`small`,`simple`,`outlined`],fileSvg:`svg/arrowSmallDown.svg`},arrowSmallLeft:{glyph:``,size:24,tags:[`arrow`,`small`,`simple`,`outlined`],fileSvg:`svg/arrowSmallLeft.svg`},arrowSmallRight:{glyph:``,size:24,tags:[`arrow`,`small`,`simple`,`outlined`],fileSvg:`svg/arrowSmallRight.svg`},arrowSmallUp:{glyph:``,size:24,tags:[`arrow`,`small`,`simple`,`outlined`],fileSvg:`svg/arrowSmallUp.svg`},arrowSolidLeft:{glyph:``,size:24,tags:[`arrow`,`large`,`solid`,`detailed`],fileSvg:`svg/arrowSolidLeft.svg`},arrowSolidRight:{glyph:``,size:24,tags:[`arrow`,`large`,`solid`,`detailed`],fileSvg:`svg/arrowSolidRight.svg`},autobahn:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/autobahn.svg`},AWD:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/AWD.svg`},axleLift:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/axleLift.svg`},axleCenter:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/axleCenter.svg`},axleFront:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/axleFront.svg`},axleRear:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/axleRear.svg`},bSpline:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`,`road tools`],fileSvg:`svg/bSpline.svg`},banknotes:{glyph:``,size:24,tags:[`career`,`currencies`],fileSvg:`svg/banknotes.svg`},barrelKnocker01:{glyph:``,size:24,tags:[`poi`],fileSvg:`svg/barrelKnocker01.svg`},barrelKnocker02:{glyph:``,size:24,tags:[`poi`],fileSvg:`svg/barrelKnocker02.svg`},beamCrashBarrier1:{glyph:``,size:24,tags:[`generic`,`world editor`,`we`,`road tools`],fileSvg:`svg/beamCrashBarrier1.svg`},beamCrashBarrier2:{glyph:``,size:24,tags:[`generic`,`world editor`,`we`,`road tools`],fileSvg:`svg/beamCrashBarrier2.svg`},beamCrashBarrier3:{glyph:``,size:24,tags:[`generic`,`world editor`,`we`,`road tools`],fileSvg:`svg/beamCrashBarrier3.svg`},beamCurrency:{glyph:``,size:24,tags:[`career`,`currencies`],fileSvg:`svg/beamCurrency.svg`},beamNG:{glyph:``,size:24,tags:[`brand`,`beamng`,`generic`],fileSvg:`svg/beamNG.svg`},beamXPFull:{glyph:``,size:24,tags:[`career`,`currencies`],fileSvg:`svg/beamXPFull.svg`},beamXPLo:{glyph:``,size:24,tags:[`career`,`currencies`],fileSvg:`svg/beamXPLo.svg`},bezierPath1:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`,`road tools`],fileSvg:`svg/bezierPath1.svg`},bezierPath2:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`,`road tools`],fileSvg:`svg/bezierPath2.svg`},bicycle1:{glyph:``,size:24,tags:[`generic`,`world editor`,`we`,`road tools`],fileSvg:`svg/bicycle1.svg`},bicycle2:{glyph:``,size:24,tags:[`generic`,`world editor`,`we`,`road tools`],fileSvg:`svg/bicycle2.svg`},BNGFolder:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/BNGFolder.svg`},BNGMicrochip:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/BNGMicrochip.svg`},bollard:{glyph:``,size:24,tags:[`generic`,`world editor`,`we`,`road tools`],fileSvg:`svg/bollard.svg`},bookmark:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/bookmark.svg`},booleanIntersect:{glyph:``,size:24,tags:[`decals`,`generic`],fileSvg:`svg/booleanIntersect.svg`},boxDropOff01:{glyph:``,size:24,tags:[`poi`,`delivery`],fileSvg:`svg/boxDropOff01.svg`},boxDropOff02:{glyph:``,size:24,tags:[`poi`,`delivery`],fileSvg:`svg/boxDropOff02.svg`},boxDropOff03:{glyph:``,size:24,tags:[`poi`,`delivery`],fileSvg:`svg/boxDropOff03.svg`},boxPickUp01:{glyph:``,size:24,tags:[`poi`,`delivery`],fileSvg:`svg/boxPickUp01.svg`},boxPickUp02:{glyph:``,size:24,tags:[`poi`,`delivery`],fileSvg:`svg/boxPickUp02.svg`},boxPickUp03:{glyph:``,size:24,tags:[`poi`,`delivery`],fileSvg:`svg/boxPickUp03.svg`},boxPickUpDropOff01:{glyph:``,size:24,tags:[`poi`,`delivery`],fileSvg:`svg/boxPickUpDropOff01.svg`},boxPickUpDropOff02:{glyph:``,size:24,tags:[`poi`,`delivery`],fileSvg:`svg/boxPickUpDropOff02.svg`},boxTruck:{glyph:``,size:24,tags:[`cargo`,`delivery`,`vehicle`],fileSvg:`svg/boxTruck.svg`},broom:{glyph:``,size:24,tags:[`generic`,`sound`],fileSvg:`svg/broom.svg`},bucketAdd:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/bucketAdd.svg`},bucketSubtract:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/bucketSubtract.svg`},bug:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/bug.svg`},bulldozer:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`,`road tools`],fileSvg:`svg/bulldozer.svg`},bus:{glyph:``,size:24,tags:[`poi`,`vehicle`],fileSvg:`svg/bus.svg`},camera3Fourth1:{glyph:``,size:24,tags:[`camera`],fileSvg:`svg/camera3Fourth1.svg`},cameraBack1:{glyph:``,size:24,tags:[`camera`],fileSvg:`svg/cameraBack1.svg`},cameraFocusOnPath:{glyph:``,size:24,tags:[`camera`],fileSvg:`svg/cameraFocusOnPath.svg`},cameraFocusOnVehicle1:{glyph:``,size:24,tags:[`camera`],fileSvg:`svg/cameraFocusOnVehicle1.svg`},cameraFocusOnVehicle2:{glyph:``,size:24,tags:[`camera`,`decals`],fileSvg:`svg/cameraFocusOnVehicle2.svg`},cameraFocusTopDown:{glyph:``,size:24,tags:[`camera`],fileSvg:`svg/cameraFocusTopDown.svg`},cameraFront1:{glyph:``,size:24,tags:[`camera`],fileSvg:`svg/cameraFront1.svg`},cameraSideLeft:{glyph:``,size:24,tags:[`camera`],fileSvg:`svg/cameraSideLeft.svg`},cameraSideLeft2:{glyph:``,size:24,tags:[`camera`],fileSvg:`svg/cameraSideLeft2.svg`},cameraSideRight:{glyph:``,size:24,tags:[`camera`],fileSvg:`svg/cameraSideRight.svg`},cameraSideRight2:{glyph:``,size:24,tags:[`camera`],fileSvg:`svg/cameraSideRight2.svg`},cameraTop1:{glyph:``,size:24,tags:[`camera`],fileSvg:`svg/cameraTop1.svg`},cannon:{glyph:``,size:24,tags:[`poi`],fileSvg:`svg/cannon.svg`},carChase01:{glyph:``,size:24,tags:[`generic`,`police`,`vehicle`],fileSvg:`svg/carChase01.svg`},carCoin:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/carCoin.svg`},carCoins:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/carCoins.svg`},carCrash:{glyph:``,size:24,tags:[`generic`,`vehicle`],fileSvg:`svg/carCrash.svg`},carDealer:{glyph:``,size:24,tags:[`career`,`garage`,`features`],fileSvg:`svg/carDealer.svg`},carOffroadOutlineRear:{glyph:``,size:24,tags:[`generic`,`vehicle`],fileSvg:`svg/carOffroadOutlineRear.svg`},carOffroadOutlineSide:{glyph:``,size:24,tags:[`generic`,`vehicle`],fileSvg:`svg/carOffroadOutlineSide.svg`},carOffroadRear:{glyph:``,size:24,tags:[`generic`,`vehicle`],fileSvg:`svg/carOffroadRear.svg`},carOffroadSide:{glyph:``,size:24,tags:[`generic`,`vehicle`],fileSvg:`svg/carOffroadSide.svg`},carSensors:{glyph:``,size:24,tags:[`generic`,`vehicle`,`sensors`],fileSvg:`svg/carSensors.svg`},carStarred:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/carStarred.svg`},carToWheels:{glyph:``,size:24,tags:[`generic`,`vehicle`],fileSvg:`svg/carToWheels.svg`},carUp:{glyph:``,size:24,tags:[`generic`,`vehicle`],fileSvg:`svg/carUp.svg`},carWithLidar:{glyph:``,size:24,tags:[`generic`,`vehicle`,`tech`,`sensors`],fileSvg:`svg/carWithLidar.svg`},car:{glyph:``,size:24,tags:[`generic`,`vehicle`],fileSvg:`svg/car.svg`},cardboardBox:{glyph:``,size:24,tags:[`generic`,`delivery`],fileSvg:`svg/cardboardBox.svg`},carsChase02:{glyph:``,size:24,tags:[`generic`,`police`,`vehicle`],fileSvg:`svg/carsChase02.svg`},cars:{glyph:``,size:24,tags:[`generic`,`vehicle`],fileSvg:`svg/cars.svg`},catalog01:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/catalog01.svg`},catalog02:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/catalog02.svg`},catalog03:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/catalog03.svg`},centrifugalClutchLocked03:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/centrifugalClutchLocked03.svg`},centrifugalClutchUnlocked03:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/centrifugalClutchUnlocked03.svg`},charge:{glyph:``,size:24,tags:[`fuel`,`electricity`,`ev`],fileSvg:`svg/charge.svg`},charging:{glyph:``,size:24,tags:[`fuel`,`electricity`,`ev`],fileSvg:`svg/charging.svg`},chartBars:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/chartBars.svg`},checkboxOff:{glyph:``,size:24,tags:[`checkbox`,`selection`,`box`],fileSvg:`svg/checkboxOff.svg`},checkboxOn:{glyph:``,size:24,tags:[`checkbox`,`selection`,`box`],fileSvg:`svg/checkboxOn.svg`},checkmarkBold:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/checkmarkBold.svg`},checkmark:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/checkmark.svg`},circuitMicrochip:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/circuitMicrochip.svg`},circuit:{glyph:``,size:24,tags:[`poi`],fileSvg:`svg/circuit.svg`},clapperboard:{glyph:``,size:24,tags:[`generic`,`movie`,`scenery`],fileSvg:`svg/clapperboard.svg`},code:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/code.svg`},cogDamaged:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/cogDamaged.svg`},cogsDamaged:{glyph:``,size:24,tags:[`vehicle`,`features`,`powertrain`,`drivetrain`],fileSvg:`svg/cogsDamaged.svg`},cogs:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/cogs.svg`},concreteRoadBlock:{glyph:``,size:24,tags:[`generic`,`world editor`,`we`,`road tools`],fileSvg:`svg/concreteRoadBlock.svg`},coolantTemp:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/coolantTemp.svg`},copy:{glyph:``,size:24,tags:[`decals`,`generic`],fileSvg:`svg/copy.svg`},crossroads1:{glyph:``,size:24,tags:[`generic`,`world editor`,`we`,`road tools`],fileSvg:`svg/crossroads1.svg`},crossroads2:{glyph:``,size:24,tags:[`generic`,`world editor`,`we`,`road tools`],fileSvg:`svg/crossroads2.svg`},cruiseDisable:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/cruiseDisable.svg`},cruiseEnable:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/cruiseEnable.svg`},cup:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/cup.svg`},dataExchange:{glyph:``,size:24,tags:[`generic`,`data`,`signal`],fileSvg:`svg/dataExchange.svg`},day:{glyph:``,size:24,tags:[`environment`],fileSvg:`svg/day.svg`},DCBattery:{glyph:``,size:24,tags:[`vehicle`,`features`,`warning`,`internals`],fileSvg:`svg/DCBattery.svg`},decalRoad:{glyph:``,size:24,tags:[`generic`,`world editor`,`we`,`road tools`],fileSvg:`svg/decalRoad.svg`},decal:{glyph:``,size:24,tags:[`decals`,`generic`],fileSvg:`svg/decal.svg`},deform:{glyph:``,size:24,tags:[`decals`,`generic`],fileSvg:`svg/deform.svg`},deliveryTruckArrows:{glyph:``,size:24,tags:[`poi`,`delivery`,`vehicle`],fileSvg:`svg/deliveryTruckArrows.svg`},deliveryTruck:{glyph:``,size:24,tags:[`poi`,`delivery`,`vehicle`],fileSvg:`svg/deliveryTruck.svg`},differentialFrontDefault:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/differentialFrontDefault.svg`},differentialFrontLocked:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/differentialFrontLocked.svg`},differentialMiddleDefault:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/differentialMiddleDefault.svg`},differentialMiddleLocked:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/differentialMiddleLocked.svg`},differentialRearDefault:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/differentialRearDefault.svg`},differentialRearLocked:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/differentialRearLocked.svg`},doorHandle:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/doorHandle.svg`},doorIn:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/doorIn.svg`},drag01:{glyph:``,size:24,tags:[`poi`],fileSvg:`svg/drag01.svg`},drag02:{glyph:``,size:24,tags:[`poi`],fileSvg:`svg/drag02.svg`},drift01:{glyph:``,size:24,tags:[`poi`,`vehicle`],fileSvg:`svg/drift01.svg`},drift02:{glyph:``,size:24,tags:[`poi`,`vehicle`],fileSvg:`svg/drift02.svg`},drivetrainGeneric:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/drivetrainGeneric.svg`},drivetrainSpecial:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/drivetrainSpecial.svg`},editCheckmark:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/editCheckmark.svg`},edit:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/edit.svg`},engine:{glyph:``,size:24,tags:[`vehicle`,`part`,`features`],fileSvg:`svg/engine.svg`},ESCOff:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/ESCOff.svg`},ESCOn:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/ESCOn.svg`},ESC:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/ESC.svg`},evade:{glyph:``,size:24,tags:[`poi`,`mission`,`police`],fileSvg:`svg/evade.svg`},exhaustValve:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/exhaustValve.svg`},exit:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/exit.svg`},export:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/export.svg`},eyeOutlineClosed:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/eyeOutlineClosed.svg`},eyeOutlineOpened:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/eyeOutlineOpened.svg`},eyeSolidClosed:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/eyeSolidClosed.svg`},eyeSolidOpened:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/eyeSolidOpened.svg`},eyeWaves:{glyph:``,size:24,tags:[`generic`,`data`,`signal`,`sensor`],fileSvg:`svg/eyeWaves.svg`},facility02:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/facility02.svg`},fastBackward:{glyph:``,size:24,tags:[`playback`],fileSvg:`svg/fastBackward.svg`},fastForward:{glyph:``,size:24,tags:[`playback`],fileSvg:`svg/fastForward.svg`},fastTravel:{glyph:``,size:24,tags:[`poi`],fileSvg:`svg/fastTravel.svg`},filter:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/filter.svg`},flagNew:{glyph:``,size:24,tags:[`poi`],fileSvg:`svg/flagNew.svg`},flag:{glyph:``,size:24,tags:[`poi`],fileSvg:`svg/flag.svg`},flatBulbBeam:{glyph:``,size:24,tags:[`generic`,`world editor`,`we`,`sensor`],fileSvg:`svg/flatBulbBeam.svg`},flatbedTruck:{glyph:``,size:24,tags:[`cargo`,`delivery`,`vehicle`,`truck`],fileSvg:`svg/flatbedTruck.svg`},floppyDisk:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/floppyDisk.svg`},fogLight:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/fogLight.svg`},folder:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/folder.svg`},forklift:{glyph:``,size:24,tags:[`delivery`,`stencil`,`cargo`,`vehicle`],fileSvg:`svg/forklift.svg`},FPS:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/FPS.svg`},fragile:{glyph:``,size:24,tags:[`delivery`,`stencil`,`cargo`],fileSvg:`svg/fragile.svg`},frontAxleMidpoint:{glyph:``,size:24,tags:[`generic`,`world editor`,`we`,`placement`,`sensor`],fileSvg:`svg/frontAxleMidpoint.svg`},frontBumperMidpoint:{glyph:``,size:24,tags:[`generic`,`world editor`,`we`,`placement`,`sensor`],fileSvg:`svg/frontBumperMidpoint.svg`},fuelPumpFilling:{glyph:``,size:24,tags:[`fuel`],fileSvg:`svg/fuelPumpFilling.svg`},fuelPump:{glyph:``,size:24,tags:[`fuel`],fileSvg:`svg/fuelPump.svg`},FWD:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/FWD.svg`},gamepadOld:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/gamepadOld.svg`},gamepad:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/gamepad.svg`},garage01:{glyph:``,size:24,tags:[`career`,`garage`,`features`],fileSvg:`svg/garage01.svg`},garage02:{glyph:``,size:24,tags:[`career`,`garage`,`features`],fileSvg:`svg/garage02.svg`},garage03:{glyph:``,size:24,tags:[`career`,`garage`,`features`],fileSvg:`svg/garage03.svg`},gaugeEmpty:{glyph:``,size:24,tags:[`poi`],fileSvg:`svg/gaugeEmpty.svg`},globe:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/globe.svg`},GPSMark:{glyph:``,size:24,tags:[`generic`,`gps`,`position`,`map`,`sensor`],fileSvg:`svg/GPSMark.svg`},GPSSolid:{glyph:``,size:24,tags:[`generic`,`gps`,`position`,`map`,`sensor`],fileSvg:`svg/GPSSolid.svg`},group:{glyph:``,size:24,tags:[`decals`,`generic`],fileSvg:`svg/group.svg`},gyroscopeMicrochip:{glyph:``,size:24,tags:[`generic`,`data`,`signal`,`sensor`],fileSvg:`svg/gyroscopeMicrochip.svg`},gyroscope:{glyph:``,size:24,tags:[`generic`,`data`,`signal`,`sensor`],fileSvg:`svg/gyroscope.svg`},hazardLights:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/hazardLights.svg`},helmets:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/helmets.svg`},help:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/help.svg`},highBeam:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/highBeam.svg`},HUD:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/HUD.svg`},hydroPump1:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/hydroPump1.svg`},hydroPump2:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/hydroPump2.svg`},hydroPump3:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/hydroPump3.svg`},hydroPump4:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/hydroPump4.svg`},hydroPump5:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/hydroPump5.svg`},hydroPump6:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/hydroPump6.svg`},hydroPump7:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/hydroPump7.svg`},hypermiling:{glyph:``,size:24,tags:[`poi`],fileSvg:`svg/hypermiling.svg`},import:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/import.svg`},infinity:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/infinity.svg`},info:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/info.svg`},jointLocked:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/jointLocked.svg`},jointUnlocked:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/jointUnlocked.svg`},jump:{glyph:``,size:24,tags:[`poi`],fileSvg:`svg/jump.svg`},keyboard:{glyph:``,size:24,tags:[`keyboard`,`input`],fileSvg:`svg/keyboard.svg`},keys1:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/keys1.svg`},keys2:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/keys2.svg`},lampPost1:{glyph:``,size:24,tags:[`generic`,`world editor`,`we`,`road tools`],fileSvg:`svg/lampPost1.svg`},lampPost2:{glyph:``,size:24,tags:[`generic`,`world editor`,`we`,`road tools`],fileSvg:`svg/lampPost2.svg`},lampPost3:{glyph:``,size:24,tags:[`generic`,`world editor`,`we`,`road tools`],fileSvg:`svg/lampPost3.svg`},laneProperties:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`,`road tools`],fileSvg:`svg/laneProperties.svg`},language:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/language.svg`},laptop:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/laptop.svg`},lidarPatternFullArcHighFreq:{glyph:``,size:24,tags:[`generic`,`world editor`,`we`,`sensor`],fileSvg:`svg/lidarPatternFullArcHighFreq.svg`},lidarPatternFullArcMidFreq:{glyph:``,size:24,tags:[`generic`,`world editor`,`we`,`sensor`],fileSvg:`svg/lidarPatternFullArcMidFreq.svg`},lidarPatternNarrowArc:{glyph:``,size:24,tags:[`generic`,`world editor`,`we`,`sensor`],fileSvg:`svg/lidarPatternNarrowArc.svg`},lidar:{glyph:``,size:24,tags:[`generic`,`data`,`signal`,`sensor`],fileSvg:`svg/lidar.svg`},lightGarageG11:{glyph:``,size:24,tags:[`career`,`garage`,`lights`],fileSvg:`svg/lightGarageG11.svg`},lightGarageG12:{glyph:``,size:24,tags:[`career`,`garage`,`lights`],fileSvg:`svg/lightGarageG12.svg`},lightGarageG13:{glyph:``,size:24,tags:[`career`,`garage`,`lights`],fileSvg:`svg/lightGarageG13.svg`},lightGarageG14:{glyph:``,size:24,tags:[`career`,`garage`,`lights`],fileSvg:`svg/lightGarageG14.svg`},lightGarageG21:{glyph:``,size:24,tags:[`career`,`garage`,`lights`],fileSvg:`svg/lightGarageG21.svg`},lightGarageG22:{glyph:``,size:24,tags:[`career`,`garage`,`lights`],fileSvg:`svg/lightGarageG22.svg`},lightGarageG23:{glyph:``,size:24,tags:[`career`,`garage`,`lights`],fileSvg:`svg/lightGarageG23.svg`},lightGarageG24:{glyph:``,size:24,tags:[`career`,`garage`,`lights`],fileSvg:`svg/lightGarageG24.svg`},lightGarageG31:{glyph:``,size:24,tags:[`career`,`garage`,`lights`],fileSvg:`svg/lightGarageG31.svg`},lightGarageG32:{glyph:``,size:24,tags:[`career`,`garage`,`lights`],fileSvg:`svg/lightGarageG32.svg`},lightGarageG33:{glyph:``,size:24,tags:[`career`,`garage`,`lights`],fileSvg:`svg/lightGarageG33.svg`},lightGarageG34:{glyph:``,size:24,tags:[`career`,`garage`,`lights`],fileSvg:`svg/lightGarageG34.svg`},lightrunner:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/lightrunner.svg`},limiterEnable:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/limiterEnable.svg`},lineToTerrain:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`,`road tools`],fileSvg:`svg/lineToTerrain.svg`},link2:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/link2.svg`},link:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/link.svg`},listBig:{glyph:``,size:24,tags:[`generic`,`catalog`,`selector`,`view`],fileSvg:`svg/listBig.svg`},listIndented:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/listIndented.svg`},listSmall:{glyph:``,size:24,tags:[`generic`,`catalog`,`selector`,`view`],fileSvg:`svg/listSmall.svg`},location1:{glyph:``,size:24,tags:[`generic`,`gps`,`position`,`map`,`sensor`],fileSvg:`svg/location1.svg`},location2:{glyph:``,size:24,tags:[`generic`,`gps`,`position`,`map`,`sensor`],fileSvg:`svg/location2.svg`},lockClosed:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/lockClosed.svg`},lockOpened:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/lockOpened.svg`},longRangeBeam1:{glyph:``,size:24,tags:[`generic`,`world editor`,`we`,`sensor`],fileSvg:`svg/longRangeBeam1.svg`},longRangeBeam2:{glyph:``,size:24,tags:[`generic`,`world editor`,`we`,`sensor`],fileSvg:`svg/longRangeBeam2.svg`},lowBeam:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/lowBeam.svg`},magnetOnSurface:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`,`road tools`],fileSvg:`svg/magnetOnSurface.svg`},mapWithEmitter:{glyph:``,size:24,tags:[`generic`,`tech`,`sensors`],fileSvg:`svg/mapWithEmitter.svg`},mapPoint:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/mapPoint.svg`},material:{glyph:``,size:24,tags:[`decals`,`generic`],fileSvg:`svg/material.svg`},mathDivide:{glyph:``,size:24,tags:[`generic`,`math`,`operands`,`small`],fileSvg:`svg/mathDivide.svg`},mathGreaterOrEqualThan:{glyph:``,size:24,tags:[`generic`,`math`,`operands`,`small`],fileSvg:`svg/mathGreaterOrEqualThan.svg`},mathGreaterThan:{glyph:``,size:24,tags:[`generic`,`math`,`operands`,`small`],fileSvg:`svg/mathGreaterThan.svg`},mathLessOrEqualThan:{glyph:``,size:24,tags:[`generic`,`math`,`operands`,`small`],fileSvg:`svg/mathLessOrEqualThan.svg`},mathLessThan:{glyph:``,size:24,tags:[`generic`,`math`,`operands`,`small`],fileSvg:`svg/mathLessThan.svg`},mathMinus:{glyph:``,size:24,tags:[`generic`,`math`,`operands`,`small`],fileSvg:`svg/mathMinus.svg`},mathMultiply:{glyph:``,size:24,tags:[`generic`,`math`,`operands`,`small`],fileSvg:`svg/mathMultiply.svg`},mathPlus:{glyph:``,size:24,tags:[`generic`,`math`,`operands`,`small`],fileSvg:`svg/mathPlus.svg`},medal:{glyph:``,size:24,tags:[`generic`,`reward`,`achievment`],fileSvg:`svg/medal.svg`},mesh4Cells:{glyph:``,size:24,tags:[`tech`,`mesh`,`beams`,`nodes`,`surface`],fileSvg:`svg/mesh4Cells.svg`},mesh9Cells:{glyph:``,size:24,tags:[`tech`,`mesh`,`beams`,`nodes`,`surface`],fileSvg:`svg/mesh9Cells.svg`},meshFence:{glyph:``,size:24,tags:[`generic`,`world editor`,`we`,`road tools`],fileSvg:`svg/meshFence.svg`},meshRoad:{glyph:``,size:24,tags:[`generic`,`world editor`,`we`,`road tools`],fileSvg:`svg/meshRoad.svg`},midRangeBeam1:{glyph:``,size:24,tags:[`generic`,`world editor`,`we`,`sensor`],fileSvg:`svg/midRangeBeam1.svg`},midRangeBeam2:{glyph:``,size:24,tags:[`generic`,`world editor`,`we`,`sensor`],fileSvg:`svg/midRangeBeam2.svg`},minusRes:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/minusRes.svg`},minus:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/minus.svg`},mirrorInteriorMiddle:{glyph:``,size:24,tags:[`vehicle`,`features`,`mirror`,`rearview`],fileSvg:`svg/mirrorInteriorMiddle.svg`},mirrorLeftBigBottomWideAngle:{glyph:``,size:24,tags:[`vehicle`,`features`,`mirror`,`rearview`],fileSvg:`svg/mirrorLeftBigBottomWideAngle.svg`},mirrorLeftBigTop:{glyph:``,size:24,tags:[`vehicle`,`features`,`mirror`,`rearview`],fileSvg:`svg/mirrorLeftBigTop.svg`},mirrorLeftBig:{glyph:``,size:24,tags:[`vehicle`,`features`,`mirror`,`rearview`],fileSvg:`svg/mirrorLeftBig.svg`},mirrorLeftBonnet:{glyph:``,size:24,tags:[`vehicle`,`features`,`mirror`,`rearview`],fileSvg:`svg/mirrorLeftBonnet.svg`},mirrorLeftDefault:{glyph:``,size:24,tags:[`vehicle`,`features`,`mirror`,`rearview`],fileSvg:`svg/mirrorLeftDefault.svg`},mirrorRightBigBottomWideAngle:{glyph:``,size:24,tags:[`vehicle`,`features`,`mirror`,`rearview`],fileSvg:`svg/mirrorRightBigBottomWideAngle.svg`},mirrorRightBigTop:{glyph:``,size:24,tags:[`vehicle`,`features`,`mirror`,`rearview`],fileSvg:`svg/mirrorRightBigTop.svg`},mirrorRightBig:{glyph:``,size:24,tags:[`vehicle`,`features`,`mirror`,`rearview`],fileSvg:`svg/mirrorRightBig.svg`},mirrorRightBonnet:{glyph:``,size:24,tags:[`vehicle`,`features`,`mirror`,`rearview`],fileSvg:`svg/mirrorRightBonnet.svg`},mirrorRightDefault:{glyph:``,size:24,tags:[`vehicle`,`features`,`mirror`,`rearview`],fileSvg:`svg/mirrorRightDefault.svg`},mirrorRoundWideAngle:{glyph:``,size:24,tags:[`vehicle`,`features`,`mirror`,`rearview`],fileSvg:`svg/mirrorRoundWideAngle.svg`},mirrorTopWideAngle:{glyph:``,size:24,tags:[`vehicle`,`features`,`mirror`,`rearview`],fileSvg:`svg/mirrorTopWideAngle.svg`},missionCheckboxCross:{glyph:``,size:24,tags:[`checkbox`,`selection`,`box`],fileSvg:`svg/missionCheckboxCross.svg`},mouseLMB:{glyph:``,size:24,tags:[`mouse`,`input`],fileSvg:`svg/mouseLMB.svg`},mouseMMB:{glyph:``,size:24,tags:[`mouse`,`input`],fileSvg:`svg/mouseMMB.svg`},mouseRMB:{glyph:``,size:24,tags:[`mouse`,`input`],fileSvg:`svg/mouseRMB.svg`},mouseWheel:{glyph:``,size:24,tags:[`mouse`,`input`],fileSvg:`svg/mouseWheel.svg`},mouseXAxis:{glyph:``,size:24,tags:[`mouse`,`input`],fileSvg:`svg/mouseXAxis.svg`},mouseXYAxis:{glyph:``,size:24,tags:[`mouse`,`input`],fileSvg:`svg/mouseXYAxis.svg`},mouseYAxis:{glyph:``,size:24,tags:[`mouse`,`input`],fileSvg:`svg/mouseYAxis.svg`},mouse:{glyph:``,size:24,tags:[`mouse`,`input`],fileSvg:`svg/mouse.svg`},move02:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/move02.svg`},move:{glyph:``,size:24,tags:[`decals`,`generic`],fileSvg:`svg/move.svg`},movieCamera:{glyph:``,size:24,tags:[`camera`],fileSvg:`svg/movieCamera.svg`},music:{glyph:``,size:24,tags:[`playback`],fileSvg:`svg/music.svg`},N2OButton:{glyph:``,size:24,tags:[`fuel`],fileSvg:`svg/N2OButton.svg`},N2OHoriz:{glyph:``,size:24,tags:[`fuel`],fileSvg:`svg/N2OHoriz.svg`},N2OVert:{glyph:``,size:24,tags:[`fuel`],fileSvg:`svg/N2OVert.svg`},nextTrack:{glyph:``,size:24,tags:[`playback`],fileSvg:`svg/nextTrack.svg`},night:{glyph:``,size:24,tags:[`environment`],fileSvg:`svg/night.svg`},noNameControllerButton:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/noNameControllerButton.svg`},nodeAddFirst01:{glyph:``,size:24,tags:[`generic`,`path`,`node`],fileSvg:`svg/nodeAddFirst01.svg`},nodeAddFirst02:{glyph:``,size:24,tags:[`generic`,`path`,`node`],fileSvg:`svg/nodeAddFirst02.svg`},nodeAddLast02:{glyph:``,size:24,tags:[`generic`,`path`,`node`],fileSvg:`svg/nodeAddLast02.svg`},nodeAddMiddle01:{glyph:``,size:24,tags:[`generic`,`path`,`node`],fileSvg:`svg/nodeAddMiddle01.svg`},nodeAddMiddle02:{glyph:``,size:24,tags:[`generic`,`path`,`node`],fileSvg:`svg/nodeAddMiddle02.svg`},nodeAdd:{glyph:``,size:24,tags:[`generic`,`path`,`node`],fileSvg:`svg/nodeAdd.svg`},nodeLast01:{glyph:``,size:24,tags:[`generic`,`path`,`node`],fileSvg:`svg/nodeLast01.svg`},nodeRemove:{glyph:``,size:24,tags:[`generic`,`path`,`node`],fileSvg:`svg/nodeRemove.svg`},odometerKM:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/odometerKM.svg`},odometerMI:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/odometerMI.svg`},odometer:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/odometer.svg`},oilPressureIndicator:{glyph:``,size:24,tags:[`vehicle`,`features`,`warning`,`internals`],fileSvg:`svg/oilPressureIndicator.svg`},order:{glyph:``,size:24,tags:[`decals`,`generic`],fileSvg:`svg/order.svg`},organization:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/organization.svg`},palmCrossed:{glyph:``,size:24,tags:[`touch`,`input`],fileSvg:`svg/palmCrossed.svg`},paperKnife:{glyph:``,size:24,tags:[`decals`,`generic`],fileSvg:`svg/paperKnife.svg`},parkingIndicator:{glyph:``,size:24,tags:[`vehicle`,`features`,`warning`,`internals`],fileSvg:`svg/parkingIndicator.svg`},parking:{glyph:``,size:24,tags:[`poi`],fileSvg:`svg/parking.svg`},pathArc:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`,`road tools`],fileSvg:`svg/pathArc.svg`},pathAroundObstacle:{glyph:``,size:24,tags:[`camera`],fileSvg:`svg/pathAroundObstacle.svg`},pathLine:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`,`road tools`],fileSvg:`svg/pathLine.svg`},pathSpiral:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`,`road tools`],fileSvg:`svg/pathSpiral.svg`},pauseRound:{glyph:``,size:24,tags:[`playback`],fileSvg:`svg/pauseRound.svg`},pause:{glyph:``,size:24,tags:[`playback`],fileSvg:`svg/pause.svg`},personSolid:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/personSolid.svg`},person:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/person.svg`},photo:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/photo.svg`},placeholder:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/placeholder.svg`},playRound:{glyph:``,size:24,tags:[`playback`],fileSvg:`svg/playRound.svg`},play:{glyph:``,size:24,tags:[`playback`],fileSvg:`svg/play.svg`},playlist:{glyph:``,size:24,tags:[`playback`],fileSvg:`svg/playlist.svg`},plusGarage1:{glyph:``,size:24,tags:[`career`,`garage`,`features`],fileSvg:`svg/plusGarage1.svg`},plusGarage2:{glyph:``,size:24,tags:[`career`,`garage`,`features`],fileSvg:`svg/plusGarage2.svg`},plusGarage3:{glyph:``,size:24,tags:[`career`,`garage`,`features`],fileSvg:`svg/plusGarage3.svg`},plusGarage4:{glyph:``,size:24,tags:[`career`,`garage`,`features`],fileSvg:`svg/plusGarage4.svg`},plusSet:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/plusSet.svg`},plus:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/plus.svg`},positionLights:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/positionLights.svg`},powerGauge01:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/powerGauge01.svg`},powerGauge02:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/powerGauge02.svg`},powerGauge03:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/powerGauge03.svg`},powerGauge04:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/powerGauge04.svg`},powerGauge05:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/powerGauge05.svg`},powerOnOff:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/powerOnOff.svg`},prevTrack:{glyph:``,size:24,tags:[`playback`],fileSvg:`svg/prevTrack.svg`},publisher:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/publisher.svg`},puzzleModule:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/puzzleModule.svg`},raceFlag:{glyph:``,size:24,tags:[`poi`],fileSvg:`svg/raceFlag.svg`},radarIdeal:{glyph:``,size:24,tags:[`generic`,`data`,`signal`,`sensor`],fileSvg:`svg/radarIdeal.svg`},radarRoundIdeal:{glyph:``,size:24,tags:[`generic`,`data`,`signal`,`sensor`],fileSvg:`svg/radarRoundIdeal.svg`},radarRound:{glyph:``,size:24,tags:[`generic`,`data`,`signal`,`sensor`],fileSvg:`svg/radarRound.svg`},radar:{glyph:``,size:24,tags:[`generic`,`data`,`signal`,`sensor`],fileSvg:`svg/radar.svg`},rangeboxHi2:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/rangeboxHi2.svg`},rangeboxHi4:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/rangeboxHi4.svg`},rangeboxHiA:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/rangeboxHiA.svg`},rangeboxLo2:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/rangeboxLo2.svg`},rangeboxLo4:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/rangeboxLo4.svg`},rangeboxLoA:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/rangeboxLoA.svg`},rearAxleMidpoint:{glyph:``,size:24,tags:[`generic`,`world editor`,`we`,`placement`,`sensor`],fileSvg:`svg/rearAxleMidpoint.svg`},rearBumperMidpoint:{glyph:``,size:24,tags:[`generic`,`world editor`,`we`,`placement`,`sensor`],fileSvg:`svg/rearBumperMidpoint.svg`},reconfigure:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/reconfigure.svg`},redo:{glyph:``,size:24,tags:[`decals`,`generic`],fileSvg:`svg/redo.svg`},reflectNot:{glyph:``,size:24,tags:[`decals`,`generic`],fileSvg:`svg/reflectNot.svg`},reflect:{glyph:``,size:24,tags:[`decals`,`generic`],fileSvg:`svg/reflect.svg`},rename:{glyph:``,size:24,tags:[`decals`,`generic`],fileSvg:`svg/rename.svg`},replay:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/replay.svg`},restart:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/restart.svg`},roadDividerLinesDecal:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`,`road tools`],fileSvg:`svg/roadDividerLinesDecal.svg`},roadEdgeLineDecal:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`,`road tools`],fileSvg:`svg/roadEdgeLineDecal.svg`},roadEndLineDecal:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`,`road tools`],fileSvg:`svg/roadEndLineDecal.svg`},roadFace:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`,`road tools`],fileSvg:`svg/roadFace.svg`},roadInfo:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/roadInfo.svg`},roadMarkingOutline:{glyph:``,size:24,tags:[`generic`,`world editor`,`we`,`outlined`],fileSvg:`svg/roadMarkingOutline.svg`},roadMarkingSolid:{glyph:``,size:24,tags:[`generic`,`world editor`,`we`,`road tools`],fileSvg:`svg/roadMarkingSolid.svg`},roadOutline:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`,`road tools`],fileSvg:`svg/roadOutline.svg`},roadRefPathDecal:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`,`road tools`],fileSvg:`svg/roadRefPathDecal.svg`},roadRefPath:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`,`road tools`],fileSvg:`svg/roadRefPath.svg`},roadStartLineDecal:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`,`road tools`],fileSvg:`svg/roadStartLineDecal.svg`},road:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/road.svg`},rockCrawling01:{glyph:``,size:24,tags:[`poi`,`vehicle`],fileSvg:`svg/rockCrawling01.svg`},rockCrawling02:{glyph:``,size:24,tags:[`poi`],fileSvg:`svg/rockCrawling02.svg`},routeAdd:{glyph:``,size:24,tags:[`route`,`traffic`],fileSvg:`svg/routeAdd.svg`},routeComplex:{glyph:``,size:24,tags:[`route`,`traffic`],fileSvg:`svg/routeComplex.svg`},routeSimple:{glyph:``,size:24,tags:[`route`,`traffic`],fileSvg:`svg/routeSimple.svg`},runScript:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/runScript.svg`},RWD:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/RWD.svg`},saveAs1:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/saveAs1.svg`},scan:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/scan.svg`},search:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/search.svg`},semiTrailer:{glyph:``,size:24,tags:[`cargo`,`delivery`,`trailer`,`vehicle`],fileSvg:`svg/semiTrailer.svg`},semiTruckCabover:{glyph:``,size:24,tags:[`cargo`,`delivery`,`vehicle`,`truck`],fileSvg:`svg/semiTruckCabover.svg`},semiTruckUS:{glyph:``,size:24,tags:[`cargo`,`delivery`,`vehicle`,`truck`],fileSvg:`svg/semiTruckUS.svg`},semiTruck:{glyph:``,size:24,tags:[`cargo`,`delivery`,`truck`,`trailer`,`vehicle`],fileSvg:`svg/semiTruck.svg`},shortRangeBeam1:{glyph:``,size:24,tags:[`generic`,`world editor`,`we`,`sensor`],fileSvg:`svg/shortRangeBeam1.svg`},shortRangeBeam2:{glyph:``,size:24,tags:[`generic`,`world editor`,`we`,`sensor`],fileSvg:`svg/shortRangeBeam2.svg`},signal01a:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/signal01a.svg`},signal02a:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/signal02a.svg`},signal03a:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/signal03a.svg`},signal04a:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/signal04a.svg`},signal05a:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/signal05a.svg`},slashLeft:{glyph:``,size:24,tags:[`generic`,`math`,`operands`,`small`],fileSvg:`svg/slashLeft.svg`},slashRight:{glyph:``,size:24,tags:[`generic`,`math`,`operands`,`small`],fileSvg:`svg/slashRight.svg`},smallTrailer:{glyph:``,size:24,tags:[`cargo`,`delivery`,`trailer`,`vehicle`],fileSvg:`svg/smallTrailer.svg`},smartphone1:{glyph:``,size:24,tags:[`touch`,`input`],fileSvg:`svg/smartphone1.svg`},smartphone2:{glyph:``,size:24,tags:[`touch`,`input`],fileSvg:`svg/smartphone2.svg`},snowflake:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/snowflake.svg`},soundFadeOut:{glyph:``,size:24,tags:[`generic`,`sound`],fileSvg:`svg/soundFadeOut.svg`},soundLimit:{glyph:``,size:24,tags:[`generic`,`sound`],fileSvg:`svg/soundLimit.svg`},soundLoud:{glyph:``,size:24,tags:[`generic`,`sound`],fileSvg:`svg/soundLoud.svg`},soundMonoL:{glyph:``,size:24,tags:[`generic`,`sound`],fileSvg:`svg/soundMonoL.svg`},soundMonoR:{glyph:``,size:24,tags:[`generic`,`sound`],fileSvg:`svg/soundMonoR.svg`},soundOff:{glyph:``,size:24,tags:[`generic`,`sound`],fileSvg:`svg/soundOff.svg`},soundQuiet:{glyph:``,size:24,tags:[`generic`,`sound`],fileSvg:`svg/soundQuiet.svg`},soundStereo:{glyph:``,size:24,tags:[`generic`,`sound`],fileSvg:`svg/soundStereo.svg`},soundWave01:{glyph:``,size:24,tags:[`generic`,`sound`],fileSvg:`svg/soundWave01.svg`},soundWave02:{glyph:``,size:24,tags:[`generic`,`sound`],fileSvg:`svg/soundWave02.svg`},sphereOnPathNumber:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`,`road tools`],fileSvg:`svg/sphereOnPathNumber.svg`},sphereOnPath:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`,`road tools`],fileSvg:`svg/sphereOnPath.svg`},sphericalBeam:{glyph:``,size:24,tags:[`generic`,`world editor`,`we`,`sensor`],fileSvg:`svg/sphericalBeam.svg`},spoilerLift:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/spoilerLift.svg`},sprayCan:{glyph:``,size:24,tags:[`decals`,`generic`],fileSvg:`svg/sprayCan.svg`},stack3:{glyph:``,size:24,tags:[`delivery`,`stencil`,`cargo`],fileSvg:`svg/stack3.svg`},star:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/star.svg`},starSecondary:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/starSecondary.svg`},steeringWheelCommon:{glyph:``,size:24,tags:[`steering`,`controller`,`input`],fileSvg:`svg/steeringWheelCommon.svg`},steeringWheelSporty:{glyph:``,size:24,tags:[`steering`,`controller`,`input`],fileSvg:`svg/steeringWheelSporty.svg`},stopwatchArrows01:{glyph:``,size:24,tags:[`generic`,`time`,`fast`],fileSvg:`svg/stopwatchArrows01.svg`},stopwatchArrows02:{glyph:``,size:24,tags:[`generic`,`time`,`fast`],fileSvg:`svg/stopwatchArrows02.svg`},stopwatchSectionOutlinedEnd:{glyph:``,size:24,tags:[`generic`,`time`,`fast`],fileSvg:`svg/stopwatchSectionOutlinedEnd.svg`},stopwatchSectionOutlinedStart:{glyph:``,size:24,tags:[`generic`,`time`,`fast`],fileSvg:`svg/stopwatchSectionOutlinedStart.svg`},stopwatchSectionSolidEnd:{glyph:``,size:24,tags:[`generic`,`time`,`fast`],fileSvg:`svg/stopwatchSectionSolidEnd.svg`},stopwatchSectionSolidStart:{glyph:``,size:24,tags:[`generic`,`time`,`fast`],fileSvg:`svg/stopwatchSectionSolidStart.svg`},strobeLights:{glyph:``,size:24,tags:[`vehicle`,`features`,`police`,`emergency`],fileSvg:`svg/strobeLights.svg`},sunRise:{glyph:``,size:24,tags:[`environment`],fileSvg:`svg/sunRise.svg`},survellianceCamera:{glyph:``,size:24,tags:[`generic`,`camera`,`optical`,`sensor`],fileSvg:`svg/survellianceCamera.svg`},suspension01:{glyph:``,size:24,tags:[`vehicle`,`features`,`part`],fileSvg:`svg/suspension01.svg`},suspension02:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/suspension02.svg`},switchBlock:{glyph:``,size:24,tags:[`generic`,`circuit`,`electronics`,`switch`],fileSvg:`svg/switchBlock.svg`},switchOutline:{glyph:``,size:24,tags:[`generic`,`circuit`,`electronics`,`switch`],fileSvg:`svg/switchOutline.svg`},sync:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/sync.svg`},synchro01:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/synchro01.svg`},synchro02:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/synchro02.svg`},tankerTrailer:{glyph:``,size:24,tags:[`cargo`,`delivery`,`tank`,`tanker`,`trailer`,`vehicle`],fileSvg:`svg/tankerTrailer.svg`},targetJump:{glyph:``,size:24,tags:[`poi`],fileSvg:`svg/targetJump.svg`},taxiCar1:{glyph:``,size:24,tags:[`taxi`,`generic`,`vehicle`],fileSvg:`svg/taxiCar1.svg`},taxiCar3:{glyph:``,size:24,tags:[`taxi`,`generic`,`vehicle`],fileSvg:`svg/taxiCar3.svg`},taxiCarT:{glyph:``,size:24,tags:[`taxi`,`generic`,`vehicle`],fileSvg:`svg/taxiCarT.svg`},taxiCheckerLamp:{glyph:``,size:24,tags:[`taxi`,`generic`,`vehicle`],fileSvg:`svg/taxiCheckerLamp.svg`},terrainToLine:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`,`road tools`],fileSvg:`svg/terrainToLine.svg`},terrain:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/terrain.svg`},thinBulbBeam:{glyph:``,size:24,tags:[`generic`,`world editor`,`we`,`sensor`],fileSvg:`svg/thinBulbBeam.svg`},thinnerBulbBeam:{glyph:``,size:24,tags:[`generic`,`world editor`,`we`,`sensor`],fileSvg:`svg/thinnerBulbBeam.svg`},thisSideUp:{glyph:``,size:24,tags:[`delivery`,`stencil`,`cargo`],fileSvg:`svg/thisSideUp.svg`},tiles:{glyph:``,size:24,tags:[`generic`,`catalog`,`selector`,`view`],fileSvg:`svg/tiles.svg`},timer:{glyph:``,size:24,tags:[`generic`,`time`,`fast`],fileSvg:`svg/timer.svg`},tireDirection3Fourth2:{glyph:``,size:24,tags:[`tire`],fileSvg:`svg/tireDirection3Fourth2.svg`},tireDirection3Fourth3:{glyph:``,size:24,tags:[`tire`],fileSvg:`svg/tireDirection3Fourth3.svg`},tireDirectionFront2:{glyph:``,size:24,tags:[`tire`],fileSvg:`svg/tireDirectionFront2.svg`},tireDirectionSide2:{glyph:``,size:24,tags:[`tire`],fileSvg:`svg/tireDirectionSide2.svg`},tireDirectionTop2:{glyph:``,size:24,tags:[`tire`],fileSvg:`svg/tireDirectionTop2.svg`},tirePressureDecrease01:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/tirePressureDecrease01.svg`},tirePressureDecrease02:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/tirePressureDecrease02.svg`},tirePressureGaugeAlt01:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/tirePressureGaugeAlt01.svg`},tirePressureGaugeAlt02:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/tirePressureGaugeAlt02.svg`},tirePressureGaugeAlt03:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/tirePressureGaugeAlt03.svg`},tirePressureGaugeOutlined01:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/tirePressureGaugeOutlined01.svg`},tirePressureGaugeOutlined02:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/tirePressureGaugeOutlined02.svg`},tirePressureGaugeOutlined03:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/tirePressureGaugeOutlined03.svg`},tirePressureGaugeSolid01:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/tirePressureGaugeSolid01.svg`},tirePressureGaugeSolid02:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/tirePressureGaugeSolid02.svg`},tirePressureGaugeSolid03:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/tirePressureGaugeSolid03.svg`},tirePressureIncrease01:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/tirePressureIncrease01.svg`},tirePressureIncrease02:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/tirePressureIncrease02.svg`},tirePressureStopLine:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/tirePressureStopLine.svg`},tirePressureStopOctoLine:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/tirePressureStopOctoLine.svg`},tirePressureStopOctoSolid:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/tirePressureStopOctoSolid.svg`},tirePressureStopSolid:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/tirePressureStopSolid.svg`},toCOMWithWheels:{glyph:``,size:24,tags:[`generic`,`world editor`,`we`,`placement`,`sensor`],fileSvg:`svg/toCOMWithWheels.svg`},toCOM:{glyph:``,size:24,tags:[`generic`,`world editor`,`we`,`placement`,`sensor`],fileSvg:`svg/toCOM.svg`},toGarage:{glyph:``,size:24,tags:[`poi`],fileSvg:`svg/toGarage.svg`},touch:{glyph:``,size:24,tags:[`touch`,`input`],fileSvg:`svg/touch.svg`},tow:{glyph:``,size:24,tags:[`generic`,`vehicle`],fileSvg:`svg/tow.svg`},tractionControl:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/tractionControl.svg`},trafficCone:{glyph:``,size:24,tags:[`route`,`traffic`],fileSvg:`svg/trafficCone.svg`},transform:{glyph:``,size:24,tags:[`decals`,`generic`],fileSvg:`svg/transform.svg`},transmissionA:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/transmissionA.svg`},transmissionM:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/transmissionM.svg`},transparencyMask:{glyph:``,size:24,tags:[`decals`,`generic`],fileSvg:`svg/transparencyMask.svg`},trashBin1:{glyph:``,size:24,tags:[`poi`],fileSvg:`svg/trashBin1.svg`},trashBin2:{glyph:``,size:24,tags:[`decals`,`generic`],fileSvg:`svg/trashBin2.svg`},triangleBeam:{glyph:``,size:24,tags:[`generic`,`world editor`,`we`,`sensor`],fileSvg:`svg/triangleBeam.svg`},trim:{glyph:``,size:24,tags:[`generic`,`sound`],fileSvg:`svg/trim.svg`},tulipBeam:{glyph:``,size:24,tags:[`generic`,`world editor`,`we`,`sensor`],fileSvg:`svg/tulipBeam.svg`},tunnel:{glyph:``,size:24,tags:[`generic`,`world editor`,`we`,`road tools`],fileSvg:`svg/tunnel.svg`},turbine:{glyph:``,size:24,tags:[`vehicle`,`part`,`features`],fileSvg:`svg/turbine.svg`},twoRoadsAdd:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`,`road tools`],fileSvg:`svg/twoRoadsAdd.svg`},twoRoadsCrossAdd:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`,`road tools`],fileSvg:`svg/twoRoadsCrossAdd.svg`},twoRoadsLink:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`,`road tools`],fileSvg:`svg/twoRoadsLink.svg`},twoUnicyclesOnly:{glyph:``,size:24,tags:[`delivery`,`stencil`,`cargo`],fileSvg:`svg/twoUnicyclesOnly.svg`},undo:{glyph:``,size:24,tags:[`decals`,`generic`],fileSvg:`svg/undo.svg`},ungroup:{glyph:``,size:24,tags:[`decals`,`generic`],fileSvg:`svg/ungroup.svg`},unlink:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/unlink.svg`},vehicleDoorsClose:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/vehicleDoorsClose.svg`},vehicleDoorsOpen:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/vehicleDoorsOpen.svg`},vehicleDoors:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/vehicleDoors.svg`},vehicleFeatures01:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/vehicleFeatures01.svg`},vehicleFeatures02:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/vehicleFeatures02.svg`},vehicleFeatures03:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/vehicleFeatures03.svg`},vehicleHood:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/vehicleHood.svg`},vehicleTrunk:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/vehicleTrunk.svg`},view:{glyph:``,size:24,tags:[`decals`,`generic`],fileSvg:`svg/view.svg`},voucherDiagonal1:{glyph:``,size:24,tags:[`generic`,`currency`,`reward`,`career`],fileSvg:`svg/voucherDiagonal1.svg`},voucherDiagonal2:{glyph:``,size:24,tags:[`generic`,`currency`,`reward`,`career`],fileSvg:`svg/voucherDiagonal2.svg`},voucherDiagonal3:{glyph:``,size:24,tags:[`generic`,`currency`,`reward`,`career`],fileSvg:`svg/voucherDiagonal3.svg`},voucherHorizontal1:{glyph:``,size:24,tags:[`generic`,`currency`,`reward`,`career`],fileSvg:`svg/voucherHorizontal1.svg`},voucherHorizontal2:{glyph:``,size:24,tags:[`generic`,`currency`,`reward`,`career`],fileSvg:`svg/voucherHorizontal2.svg`},voucherHorizontal3:{glyph:``,size:24,tags:[`generic`,`currency`,`reward`,`career`],fileSvg:`svg/voucherHorizontal3.svg`},wavesSignalReceived:{glyph:``,size:24,tags:[`generic`,`data`,`signal`,`sensor`],fileSvg:`svg/wavesSignalReceived.svg`},wavesSignalSentLeft:{glyph:``,size:24,tags:[`generic`,`data`,`signal`,`sensor`],fileSvg:`svg/wavesSignalSentLeft.svg`},wavesSignalSentRight:{glyph:``,size:24,tags:[`generic`,`data`,`signal`,`sensor`],fileSvg:`svg/wavesSignalSentRight.svg`},weather:{glyph:``,size:24,tags:[`environment`],fileSvg:`svg/weather.svg`},weight:{glyph:``,size:24,tags:[`decals`,`generic`],fileSvg:`svg/weight.svg`},wheelHubLocked01:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/wheelHubLocked01.svg`},wheelHubUnlocked01:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/wheelHubUnlocked01.svg`},wigwags:{glyph:``,size:24,tags:[`vehicle`,`features`,`police`,`emergency`],fileSvg:`svg/wigwags.svg`},wrench:{glyph:``,size:24,tags:[`generic`,`vehicle`,`features`],fileSvg:`svg/wrench.svg`},xboxA:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/xboxA.svg`},xboxB:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/xboxB.svg`},xboxDDefaultOutline:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/xboxDDefaultOutline.svg`},xboxDDefaultSolid:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/xboxDDefaultSolid.svg`},xboxDDown:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/xboxDDown.svg`},xboxDLeft:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/xboxDLeft.svg`},xboxDRight:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/xboxDRight.svg`},xboxDUp:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/xboxDUp.svg`},xboxLB:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/xboxLB.svg`},xboxLSButton:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/xboxLSButton.svg`},xboxLT:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/xboxLT.svg`},xboxMenu:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/xboxMenu.svg`},xboxRB:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/xboxRB.svg`},xboxRSButton:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/xboxRSButton.svg`},xboxRT:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/xboxRT.svg`},xboxThumbL:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/xboxThumbL.svg`},xboxThumbR:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/xboxThumbR.svg`},xboxView:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/xboxView.svg`},xboxXAxis:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/xboxXAxis.svg`},xboxXRot:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/xboxXRot.svg`},xboxX:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/xboxX.svg`},xboxYAxis:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/xboxYAxis.svg`},xboxYRot:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/xboxYRot.svg`},xboxY:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/xboxY.svg`},AIL:{glyph:``,size:48,tags:[`extra`],fileSvg:`svg/AIL.svg`},arrowLeftOutline:{glyph:``,size:48,tags:[`web`,`outlined`,`large`,`secondary`],fileSvg:`svg/arrowLeftOutline.svg`},arrowRightOutline:{glyph:``,size:48,tags:[`web`,`outlined`,`large`,`secondary`],fileSvg:`svg/arrowRightOutline.svg`},automaticTransmissionL:{glyph:``,size:48,tags:[`extra`],fileSvg:`svg/automaticTransmissionL.svg`},beamsNodesMessageOutline:{glyph:``,size:48,tags:[`web`,`outlined`,`large`,`secondary`],fileSvg:`svg/beamsNodesMessageOutline.svg`},beamsNodesOutline:{glyph:``,size:48,tags:[`web`,`outlined`,`large`,`secondary`],fileSvg:`svg/beamsNodesOutline.svg`},beamsNodesPlugOutline:{glyph:``,size:48,tags:[`web`,`outlined`,`large`,`secondary`],fileSvg:`svg/beamsNodesPlugOutline.svg`},BNGEcosystemOutline:{glyph:``,size:48,tags:[`web`,`outlined`,`large`,`secondary`],fileSvg:`svg/BNGEcosystemOutline.svg`},carFrontRouteOutline:{glyph:``,size:48,tags:[`web`,`outlined`,`large`,`secondary`],fileSvg:`svg/carFrontRouteOutline.svg`},carSensorsOutline:{glyph:``,size:48,tags:[`web`,`outlined`,`large`,`secondary`],fileSvg:`svg/carSensorsOutline.svg`},carSideRouteOutline:{glyph:``,size:48,tags:[`web`,`outlined`,`large`,`secondary`],fileSvg:`svg/carSideRouteOutline.svg`},chargeLL:{glyph:``,size:48,tags:[`extra`],fileSvg:`svg/chargeLL.svg`},cityOutline:{glyph:``,size:48,tags:[`web`,`outlined`,`large`,`secondary`],fileSvg:`svg/cityOutline.svg`},clutchL:{glyph:``,size:48,tags:[`extra`],fileSvg:`svg/clutchL.svg`},couplerL:{glyph:``,size:48,tags:[`extra`],fileSvg:`svg/couplerL.svg`},dialogOutline:{glyph:``,size:48,tags:[`web`,`outlined`,`large`,`secondary`],fileSvg:`svg/dialogOutline.svg`},documentSmileOutline:{glyph:``,size:48,tags:[`web`,`outlined`,`large`,`secondary`],fileSvg:`svg/documentSmileOutline.svg`},drivetrainOutline:{glyph:``,size:48,tags:[`web`,`outlined`,`large`,`secondary`],fileSvg:`svg/drivetrainOutline.svg`},electronicSchemeOutline:{glyph:``,size:48,tags:[`web`,`outlined`,`large`,`secondary`],fileSvg:`svg/electronicSchemeOutline.svg`},engineL:{glyph:``,size:48,tags:[`extra`],fileSvg:`svg/engineL.svg`},engineOutline:{glyph:``,size:48,tags:[`web`,`outlined`,`large`,`secondary`],fileSvg:`svg/engineOutline.svg`},gearTuningOutline:{glyph:``,size:48,tags:[`web`,`outlined`,`large`,`secondary`],fileSvg:`svg/gearTuningOutline.svg`},giftBoxOutline:{glyph:``,size:48,tags:[`web`,`outlined`,`large`,`secondary`],fileSvg:`svg/giftBoxOutline.svg`},lidarOutline:{glyph:``,size:48,tags:[`web`,`outlined`,`large`,`secondary`],fileSvg:`svg/lidarOutline.svg`},medalStarOutline:{glyph:``,size:48,tags:[`web`,`outlined`,`large`,`secondary`],fileSvg:`svg/medalStarOutline.svg`},megaphoneOutline:{glyph:``,size:48,tags:[`web`,`outlined`,`large`,`secondary`],fileSvg:`svg/megaphoneOutline.svg`},multiseatL:{glyph:``,size:48,tags:[`extra`],fileSvg:`svg/multiseatL.svg`},peopleOutline:{glyph:``,size:48,tags:[`web`,`outlined`,`large`,`secondary`],fileSvg:`svg/peopleOutline.svg`},personOutline:{glyph:``,size:48,tags:[`web`,`outlined`,`large`,`secondary`],fileSvg:`svg/personOutline.svg`},physicsOutline:{glyph:``,size:48,tags:[`web`,`outlined`,`large`,`secondary`],fileSvg:`svg/physicsOutline.svg`},playChainOutline:{glyph:``,size:48,tags:[`web`,`outlined`,`large`,`secondary`],fileSvg:`svg/playChainOutline.svg`},POITimeL:{glyph:``,size:48,tags:[`extra`],fileSvg:`svg/POITimeL.svg`},proximitySensorsOutline:{glyph:``,size:48,tags:[`web`,`outlined`,`large`,`secondary`],fileSvg:`svg/proximitySensorsOutline.svg`},qualityBadgeStarOutline:{glyph:``,size:48,tags:[`web`,`outlined`,`large`,`secondary`],fileSvg:`svg/qualityBadgeStarOutline.svg`},qualityBadgeVOutline:{glyph:``,size:48,tags:[`web`,`outlined`,`large`,`secondary`],fileSvg:`svg/qualityBadgeVOutline.svg`},replayL:{glyph:``,size:48,tags:[`extra`],fileSvg:`svg/replayL.svg`},roadblockL:{glyph:``,size:48,tags:[`extra`],fileSvg:`svg/roadblockL.svg`},rotationL:{glyph:``,size:48,tags:[`extra`],fileSvg:`svg/rotationL.svg`},sensorsL:{glyph:``,size:48,tags:[`extra`],fileSvg:`svg/sensorsL.svg`},simRigOutline:{glyph:``,size:48,tags:[`web`,`outlined`,`large`,`secondary`],fileSvg:`svg/simRigOutline.svg`},suspensionOutline:{glyph:``,size:48,tags:[`web`,`outlined`,`large`,`secondary`],fileSvg:`svg/suspensionOutline.svg`},teamOutline:{glyph:``,size:48,tags:[`web`,`outlined`,`large`,`secondary`],fileSvg:`svg/teamOutline.svg`},techLightBulbOutline01:{glyph:``,size:48,tags:[`web`,`outlined`,`large`,`secondary`],fileSvg:`svg/techLightBulbOutline01.svg`},techLightBulbOutline02:{glyph:``,size:48,tags:[`web`,`outlined`,`large`,`secondary`],fileSvg:`svg/techLightBulbOutline02.svg`},temperatureL:{glyph:``,size:48,tags:[`extra`],fileSvg:`svg/temperatureL.svg`},timeUnlockOutline:{glyph:``,size:48,tags:[`web`,`outlined`,`large`,`secondary`],fileSvg:`svg/timeUnlockOutline.svg`},timedLockOutline:{glyph:``,size:48,tags:[`web`,`outlined`,`large`,`secondary`],fileSvg:`svg/timedLockOutline.svg`},trafficOutline:{glyph:``,size:48,tags:[`web`,`outlined`,`large`,`secondary`],fileSvg:`svg/trafficOutline.svg`},tuningL:{glyph:``,size:48,tags:[`extra`],fileSvg:`svg/tuningL.svg`},turbineL:{glyph:``,size:48,tags:[`extra`],fileSvg:`svg/turbineL.svg`},voucherOutline:{glyph:``,size:48,tags:[`web`,`outlined`,`large`,`secondary`],fileSvg:`svg/voucherOutline.svg`},wheelBeamsNodesOutline:{glyph:``,size:48,tags:[`web`,`outlined`,`large`,`secondary`],fileSvg:`svg/wheelBeamsNodesOutline.svg`},wheelOutline:{glyph:``,size:48,tags:[`web`,`outlined`,`large`,`secondary`],fileSvg:`svg/wheelOutline.svg`},circlePinBack:{glyph:``,size:56,tags:[`poi`],fileSvg:`svg/circlePinBack.svg`},circlePinFront:{glyph:``,size:56,tags:[`poi`],fileSvg:`svg/circlePinFront.svg`},markerRectanglePinBack:{glyph:``,size:56,tags:[`poi`],fileSvg:`svg/markerRectanglePinBack.svg`},markerRectanglePinFront:{glyph:``,size:56,tags:[`poi`],fileSvg:`svg/markerRectanglePinFront.svg`},markerTriangleBack:{glyph:``,size:56,tags:[`poi`],fileSvg:`svg/markerTriangleBack.svg`},markerTriangleFront:{glyph:``,size:56,tags:[`poi`],fileSvg:`svg/markerTriangleFront.svg`},danger:{glyph:``,size:24,tags:[`generic`,`hazard`],fileSvg:`svg/danger.svg`},droplet:{glyph:``,size:24,tags:[`generic`,`drop`,`liquid`],fileSvg:`svg/droplet.svg`},envelope:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/envelope.svg`},fireDiamond:{glyph:``,size:24,tags:[`generic`,`hazard`,`nfpa704`],fileSvg:`svg/fireDiamond.svg`},rocks:{glyph:``,size:24,tags:[`dry cargo`,`dry`],fileSvg:`svg/rocks.svg`},xmark:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/xmark.svg`},scale:{glyph:``,size:24,tags:[`decals`,`editor`,`generic`],fileSvg:`svg/scale.svg`},arrowsUp:{glyph:``,size:16,tags:[`marker`,`ribbon`,`content-props`],fileSvg:`svg/arrowsUp.svg`},bigDot:{glyph:``,size:16,tags:[`marker`,`ribbon`,`content-props`],fileSvg:`svg/bigDot.svg`},connectorBold:{glyph:``,size:16,tags:[`marker`,`ribbon`,`content-props`],fileSvg:`svg/connectorBold.svg`},cornerTopRight:{glyph:``,size:16,tags:[`marker`,`ribbon`,`content-props`],fileSvg:`svg/cornerTopRight.svg`},plusBold:{glyph:``,size:16,tags:[`marker`,`ribbon`,`content-props`],fileSvg:`svg/plusBold.svg`},puzzlePieceBold:{glyph:``,size:16,tags:[`marker`,`ribbon`,`content-props`],fileSvg:`svg/puzzlePieceBold.svg`},locationDestination:{glyph:``,size:24,tags:[`generic`,`location`,`route`,`path`,`node`],fileSvg:`svg/locationDestination.svg`},locationSource:{glyph:``,size:24,tags:[`generic`,`location`,`route`,`path`,`node`],fileSvg:`svg/locationSource.svg`},accelerationKPH:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/accelerationKPH.svg`},accelerationMPH:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/accelerationMPH.svg`},boxTruckFast:{glyph:``,size:24,tags:[`cargo`,`delivery`,`vehicle`],fileSvg:`svg/boxTruckFast.svg`},colorBrightnessSun:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/colorBrightnessSun.svg`},colorCirclePalette:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/colorCirclePalette.svg`},colorPalette:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/colorPalette.svg`},colorSaturation:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/colorSaturation.svg`},sortAscDown02:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/sortAscDown02.svg`},sortAscDown:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/sortAscDown.svg`},sortAscUp02:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/sortAscUp02.svg`},sortAscUp:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/sortAscUp.svg`},sortDescDown02:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/sortDescDown02.svg`},sortDescDown:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/sortDescDown.svg`},sortDescUp02:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/sortDescUp02.svg`},sortDescUp:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/sortDescUp.svg`},cardboardBoxCoins:{glyph:``,size:24,tags:[`generic`,`delivery`],fileSvg:`svg/cardboardBoxCoins.svg`},lasso:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`],fileSvg:`svg/lasso.svg`},materialGlossy:{glyph:``,size:24,tags:[`decals`,`generic`],fileSvg:`svg/materialGlossy.svg`},materialMetal:{glyph:``,size:24,tags:[`decals`,`generic`],fileSvg:`svg/materialMetal.svg`},materialRoughness:{glyph:``,size:24,tags:[`decals`,`generic`],fileSvg:`svg/materialRoughness.svg`},materialTransparency01:{glyph:``,size:24,tags:[`decals`,`generic`],fileSvg:`svg/materialTransparency01.svg`},materialTransparency02:{glyph:``,size:24,tags:[`decals`,`generic`],fileSvg:`svg/materialTransparency02.svg`},metal01:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/metal01.svg`},removeItemPolygon:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`,`road tools`],fileSvg:`svg/removeItemPolygon.svg`},removeListItem:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`,`road tools`],fileSvg:`svg/removeListItem.svg`},sortAsc:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/sortAsc.svg`},sortDesc:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/sortDesc.svg`},surfaceRoughness02:{glyph:``,size:24,tags:[`decals`,`generic`],fileSvg:`svg/surfaceRoughness02.svg`},shieldCheckmark:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/shieldCheckmark.svg`},shieldHandCheckmark:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/shieldHandCheckmark.svg`},shieldHandPlus:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/shieldHandPlus.svg`},doorFrontCoins:{glyph:``,size:24,tags:[`vehicle`,`part`,`features`],fileSvg:`svg/doorFrontCoins.svg`},doorFront:{glyph:``,size:24,tags:[`vehicle`,`part`,`features`],fileSvg:`svg/doorFront.svg`},engineCoins:{glyph:``,size:24,tags:[`vehicle`,`part`,`features`],fileSvg:`svg/engineCoins.svg`},exhaustMufflerCoins:{glyph:``,size:24,tags:[`vehicle`,`part`,`features`],fileSvg:`svg/exhaustMufflerCoins.svg`},exhaustMuffler:{glyph:``,size:24,tags:[`vehicle`,`part`,`features`],fileSvg:`svg/exhaustMuffler.svg`},headlightCoins:{glyph:``,size:24,tags:[`vehicle`,`part`,`features`],fileSvg:`svg/headlightCoins.svg`},headlight:{glyph:``,size:24,tags:[`vehicle`,`part`,`features`],fileSvg:`svg/headlight.svg`},tire3FourthCoins:{glyph:``,size:24,tags:[`vehicle`,`part`,`features`,`tire`],fileSvg:`svg/tire3FourthCoins.svg`},tire3Fourth:{glyph:``,size:24,tags:[`vehicle`,`part`,`features`,`tire`],fileSvg:`svg/tire3Fourth.svg`},turbineCoins:{glyph:``,size:24,tags:[`vehicle`,`part`,`features`],fileSvg:`svg/turbineCoins.svg`},wheelDiscCoins:{glyph:``,size:24,tags:[`vehicle`,`part`,`features`],fileSvg:`svg/wheelDiscCoins.svg`},wheelDisc:{glyph:``,size:24,tags:[`vehicle`,`part`,`features`],fileSvg:`svg/wheelDisc.svg`},bridgeWithRiver:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`,`road tools`],fileSvg:`svg/bridgeWithRiver.svg`},gizmosOutline:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`,`road tools`],fileSvg:`svg/gizmosOutline.svg`},gizmosSolid:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`,`road tools`],fileSvg:`svg/gizmosSolid.svg`},highwayRoad3To2Merge01:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`,`road tools`],fileSvg:`svg/highwayRoad3To2Merge01.svg`},highwayRoad3To2Merge02:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`,`road tools`],fileSvg:`svg/highwayRoad3To2Merge02.svg`},highwayToUrbanRoadTransition01:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`,`road tools`],fileSvg:`svg/highwayToUrbanRoadTransition01.svg`},highwayToUrbanRoadTransition02:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`,`road tools`],fileSvg:`svg/highwayToUrbanRoadTransition02.svg`},pedestrianCrossing01:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`,`road tools`],fileSvg:`svg/pedestrianCrossing01.svg`},polygonalCube:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`,`road tools`],fileSvg:`svg/polygonalCube.svg`},roadEditOutline:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`,`road tools`],fileSvg:`svg/roadEditOutline.svg`},roadEditSolid:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`,`road tools`],fileSvg:`svg/roadEditSolid.svg`},roadFolderPlus:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`,`road tools`],fileSvg:`svg/roadFolderPlus.svg`},roadFolder:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`,`road tools`],fileSvg:`svg/roadFolder.svg`},roadGuideArrowOutline:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`,`road tools`],fileSvg:`svg/roadGuideArrowOutline.svg`},roadGuideArrowSolid:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`,`road tools`],fileSvg:`svg/roadGuideArrowSolid.svg`},roadOutlineMesh:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`,`road tools`],fileSvg:`svg/roadOutlineMesh.svg`},roadPedestrianCrossing02:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`,`road tools`],fileSvg:`svg/roadPedestrianCrossing02.svg`},roadProfileWithCheckmark:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`,`road tools`],fileSvg:`svg/roadProfileWithCheckmark.svg`},roadProfile:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`,`road tools`],fileSvg:`svg/roadProfile.svg`},roadRoundaboutJunction:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`,`road tools`],fileSvg:`svg/roadRoundaboutJunction.svg`},roadSidewalkTransition:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`,`road tools`],fileSvg:`svg/roadSidewalkTransition.svg`},roadStackPlus:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`,`road tools`],fileSvg:`svg/roadStackPlus.svg`},roadStack:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`,`road tools`],fileSvg:`svg/roadStack.svg`},roadTJunction:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`,`road tools`],fileSvg:`svg/roadTJunction.svg`},roadXJunction:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`,`road tools`],fileSvg:`svg/roadXJunction.svg`},roadYJunction:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`,`road tools`],fileSvg:`svg/roadYJunction.svg`},shoppingCart:{glyph:``,size:24,tags:[`generic`,`shop`,`purchase`],fileSvg:`svg/shoppingCart.svg`},singleLineToTerrain:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`,`road tools`],fileSvg:`svg/singleLineToTerrain.svg`},sphereOnMesh:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`,`road tools`],fileSvg:`svg/sphereOnMesh.svg`},twoLinesToTerrain:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`,`road tools`],fileSvg:`svg/twoLinesToTerrain.svg`},urbanRoad3To2Merge01:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`,`road tools`],fileSvg:`svg/urbanRoad3To2Merge01.svg`},urbanRoad3To2Merge02:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`,`road tools`],fileSvg:`svg/urbanRoad3To2Merge02.svg`},urbanRoadToHighwayTransition01:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`,`road tools`],fileSvg:`svg/urbanRoadToHighwayTransition01.svg`},urbanRoadToHighwayTransition02:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`,`road tools`],fileSvg:`svg/urbanRoadToHighwayTransition02.svg`},floppyDiskPlus:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/floppyDiskPlus.svg`},highwayMerge:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`,`road tools`],fileSvg:`svg/highwayMerge.svg`},highwaySeparate:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`,`road tools`],fileSvg:`svg/highwaySeparate.svg`},highwayShoulderMerge:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`,`road tools`],fileSvg:`svg/highwayShoulderMerge.svg`},terrainToSingleLine:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`,`road tools`],fileSvg:`svg/terrainToSingleLine.svg`},terrainToTwoLines:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`,`road tools`],fileSvg:`svg/terrainToTwoLines.svg`},urbanRoadMerge:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`,`road tools`],fileSvg:`svg/urbanRoadMerge.svg`},urbanRoadSeparate:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`,`road tools`],fileSvg:`svg/urbanRoadSeparate.svg`},urbanShoulderMerge:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`,`road tools`],fileSvg:`svg/urbanShoulderMerge.svg`},discharging:{glyph:``,size:24,tags:[`fuel`,`electricity`,`ev`],fileSvg:`svg/discharging.svg`},BNGChat:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/BNGChat.svg`},chatBubble:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/chatBubble.svg`},busTilted:{glyph:``,size:24,tags:[`poi`,`vehicle`,`bus`],fileSvg:`svg/busTilted.svg`},cameraFarClip:{glyph:``,size:24,tags:[`decals`,`generic`],fileSvg:`svg/cameraFarClip.svg`},cameraNearClip:{glyph:``,size:24,tags:[`decals`,`generic`],fileSvg:`svg/cameraNearClip.svg`},explosion:{glyph:``,size:24,tags:[`generic`,`destruction`],fileSvg:`svg/explosion.svg`},fireExtinguisher:{glyph:``,size:24,tags:[`generic`,`destruction`],fileSvg:`svg/fireExtinguisher.svg`},fire:{glyph:``,size:24,tags:[`generic`,`destruction`],fileSvg:`svg/fire.svg`},jointLockedMultiple:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/jointLockedMultiple.svg`},jointUnlockedMultiple:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/jointUnlockedMultiple.svg`},toggleOff:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/toggleOff.svg`},toggleOn:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/toggleOn.svg`},viewFarClip:{glyph:``,size:24,tags:[`decals`,`generic`],fileSvg:`svg/viewFarClip.svg`},viewNearClip:{glyph:``,size:24,tags:[`decals`,`generic`],fileSvg:`svg/viewNearClip.svg`},twoArrowsHorizontal:{glyph:``,size:24,tags:[`arrow`,`large`,`solid`,`turn signals`],fileSvg:`svg/twoArrowsHorizontal.svg`},twoArrowsVertical:{glyph:``,size:24,tags:[`arrow`,`large`,`solid`,`turn signals`],fileSvg:`svg/twoArrowsVertical.svg`},bridge:{glyph:``,size:48,tags:[`rally`,`pace notes`,`directions`,`surface`,`features`],fileSvg:`svg/bridge.svg`},bump:{glyph:``,size:48,tags:[`rally`,`pace notes`,`directions`,`surface`,`features`],fileSvg:`svg/bump.svg`},bumps:{glyph:``,size:48,tags:[`rally`,`pace notes`,`directions`,`surface`,`features`],fileSvg:`svg/bumps.svg`},caution:{glyph:``,size:48,tags:[`rally`,`pace notes`,`directions`,`surface`,`features`],fileSvg:`svg/caution.svg`},crest:{glyph:``,size:48,tags:[`rally`,`pace notes`,`directions`,`surface`,`features`],fileSvg:`svg/crest.svg`},doubleCaution:{glyph:``,size:48,tags:[`rally`,`pace notes`,`directions`,`surface`,`features`],fileSvg:`svg/doubleCaution.svg`},finish:{glyph:``,size:48,tags:[`rally`,`pace notes`,`directions`,`surface`,`features`],fileSvg:`svg/finish.svg`},jumpOverBump:{glyph:``,size:48,tags:[`rally`,`pace notes`,`directions`,`surface`,`features`],fileSvg:`svg/jumpOverBump.svg`},narrows:{glyph:``,size:48,tags:[`rally`,`pace notes`,`directions`,`surface`,`features`],fileSvg:`svg/narrows.svg`},pothole:{glyph:``,size:48,tags:[`rally`,`pace notes`,`directions`,`surface`,`features`],fileSvg:`svg/pothole.svg`},turn1:{glyph:``,size:48,tags:[`rally`,`pace notes`,`directions`,`surface`,`features`],fileSvg:`svg/turn1.svg`},turn2:{glyph:``,size:48,tags:[`rally`,`pace notes`,`directions`,`surface`,`features`],fileSvg:`svg/turn2.svg`},turn3:{glyph:``,size:48,tags:[`rally`,`pace notes`,`directions`,`surface`,`features`],fileSvg:`svg/turn3.svg`},turn4:{glyph:``,size:48,tags:[`rally`,`pace notes`,`directions`,`surface`,`features`],fileSvg:`svg/turn4.svg`},turn5:{glyph:``,size:48,tags:[`rally`,`pace notes`,`directions`,`surface`,`features`],fileSvg:`svg/turn5.svg`},turn6:{glyph:``,size:48,tags:[`rally`,`pace notes`,`directions`,`surface`,`features`],fileSvg:`svg/turn6.svg`},turnHp:{glyph:``,size:48,tags:[`rally`,`pace notes`,`directions`,`surface`,`features`],fileSvg:`svg/turnHp.svg`},turnSq:{glyph:``,size:48,tags:[`rally`,`pace notes`,`directions`,`surface`,`features`],fileSvg:`svg/turnSq.svg`},water:{glyph:``,size:48,tags:[`rally`,`pace notes`,`directions`,`surface`,`features`],fileSvg:`svg/water.svg`},circleSlashed:{glyph:``,size:24,tags:[`generic`,`do not cut`,`no entry`],fileSvg:`svg/circleSlashed.svg`},scissorsSlashed:{glyph:``,size:24,tags:[`generic`,`do not cut`],fileSvg:`svg/scissorsSlashed.svg`},scissors:{glyph:``,size:24,tags:[`generic`,`cut`],fileSvg:`svg/scissors.svg`},airPuffRight1:{glyph:``,size:24,tags:[`generic`,`vehicle`,`car`],fileSvg:`svg/airPuffRight1.svg`},airPuffUp1:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/airPuffUp1.svg`},arrowsReplace:{glyph:``,size:24,tags:[`generic`,`arrow`],fileSvg:`svg/arrowsReplace.svg`},arrowsShuffle:{glyph:``,size:24,tags:[`generic`,`arrow`],fileSvg:`svg/arrowsShuffle.svg`},arrowsSwitch:{glyph:``,size:24,tags:[`generic`,`arrow`],fileSvg:`svg/arrowsSwitch.svg`},carClock:{glyph:``,size:24,tags:[`generic`,`vehicle`],fileSvg:`svg/carClock.svg`},carFast:{glyph:``,size:24,tags:[`vehicle`],fileSvg:`svg/carFast.svg`},carNumber1:{glyph:``,size:24,tags:[`generic`,`vehicle`],fileSvg:`svg/carNumber1.svg`},carNumber2:{glyph:``,size:24,tags:[`generic`,`vehicle`],fileSvg:`svg/carNumber2.svg`},carNumber3:{glyph:``,size:24,tags:[`generic`,`vehicle`],fileSvg:`svg/carNumber3.svg`},carNumber4:{glyph:``,size:24,tags:[`generic`,`vehicle`],fileSvg:`svg/carNumber4.svg`},carNumber5:{glyph:``,size:24,tags:[`generic`,`vehicle`],fileSvg:`svg/carNumber5.svg`},carNumber6:{glyph:``,size:24,tags:[`generic`,`vehicle`],fileSvg:`svg/carNumber6.svg`},carNumber7:{glyph:``,size:24,tags:[`generic`,`vehicle`],fileSvg:`svg/carNumber7.svg`},carNumber8:{glyph:``,size:24,tags:[`generic`,`vehicle`],fileSvg:`svg/carNumber8.svg`},carNumber9:{glyph:``,size:24,tags:[`generic`,`vehicle`],fileSvg:`svg/carNumber9.svg`},carPlus:{glyph:``,size:24,tags:[`generic`,`vehicle`],fileSvg:`svg/carPlus.svg`},carsChange:{glyph:``,size:24,tags:[`vehicle`,`select`],fileSvg:`svg/carsChange.svg`},carsFollow:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/carsFollow.svg`},doorFrontDetached:{glyph:``,size:24,tags:[`vehicle`,`part`,`features`],fileSvg:`svg/doorFrontDetached.svg`},forceFieldPull1:{glyph:``,size:24,tags:[`physics`,`field`,`force`],fileSvg:`svg/forceFieldPull1.svg`},forceFieldPull2:{glyph:``,size:24,tags:[`physics`,`field`,`force`],fileSvg:`svg/forceFieldPull2.svg`},forceFieldPull3:{glyph:``,size:24,tags:[`physics`,`field`,`force`],fileSvg:`svg/forceFieldPull3.svg`},forceFieldPush1:{glyph:``,size:24,tags:[`physics`,`field`,`force`],fileSvg:`svg/forceFieldPush1.svg`},forceFieldPush2:{glyph:``,size:24,tags:[`physics`,`field`,`force`],fileSvg:`svg/forceFieldPush2.svg`},forceFieldPush3:{glyph:``,size:24,tags:[`physics`,`field`,`force`],fileSvg:`svg/forceFieldPush3.svg`},garageNumber1:{glyph:``,size:24,tags:[`career`,`garage number`,`features`],fileSvg:`svg/garageNumber1.svg`},garageNumber2:{glyph:``,size:24,tags:[`career`,`garage number`,`features`],fileSvg:`svg/garageNumber2.svg`},garageNumber3:{glyph:``,size:24,tags:[`career`,`garage number`,`features`],fileSvg:`svg/garageNumber3.svg`},garageNumber4:{glyph:``,size:24,tags:[`career`,`garage number`,`features`],fileSvg:`svg/garageNumber4.svg`},garageNumber5:{glyph:``,size:24,tags:[`career`,`garage number`,`features`],fileSvg:`svg/garageNumber5.svg`},garageNumber6:{glyph:``,size:24,tags:[`career`,`garage number`,`features`],fileSvg:`svg/garageNumber6.svg`},garageNumber7:{glyph:``,size:24,tags:[`career`,`garage number`,`features`],fileSvg:`svg/garageNumber7.svg`},garageNumber8:{glyph:``,size:24,tags:[`career`,`garage number`,`features`],fileSvg:`svg/garageNumber8.svg`},garageNumber9:{glyph:``,size:24,tags:[`career`,`garage number`,`features`],fileSvg:`svg/garageNumber9.svg`},hingeBroken:{glyph:``,size:24,tags:[`vehicle`,`part`,`features`],fileSvg:`svg/hingeBroken.svg`},loadMesh:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/loadMesh.svg`},octagonBrick:{glyph:``,size:24,tags:[`generic`,`vehicle`,`car`],fileSvg:`svg/octagonBrick.svg`},octagon:{glyph:``,size:24,tags:[`generic`,`vehicle`,`car`],fileSvg:`svg/octagon.svg`},pushUp:{glyph:``,size:24,tags:[`physics`,`force`],fileSvg:`svg/pushUp.svg`},saveMesh:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/saveMesh.svg`},square:{glyph:``,size:24,tags:[`playback`,`stop`],fileSvg:`svg/square.svg`},tireAirPuff:{glyph:``,size:24,tags:[`vehicle`,`car`],fileSvg:`svg/tireAirPuff.svg`},tireDeflated:{glyph:``,size:24,tags:[`vehicle`,`car`],fileSvg:`svg/tireDeflated.svg`},trafficLight:{glyph:``,size:24,tags:[`generic`,`traffic`,`roads`],fileSvg:`svg/trafficLight.svg`},enter:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/enter.svg`},pedestrianRunning:{glyph:``,size:24,tags:[`generic`,`sign`,`pedestrian`,`traffic`],fileSvg:`svg/pedestrianRunning.svg`},pedestrianStanding:{glyph:``,size:24,tags:[`generic`,`sign`,`pedestrian`,`traffic`],fileSvg:`svg/pedestrianStanding.svg`},seatArrowIn:{glyph:``,size:24,tags:[`generic`,`arrow`,`actions`],fileSvg:`svg/seatArrowIn.svg`},seatArrowOut:{glyph:``,size:24,tags:[`generic`,`arrow`,`actions`],fileSvg:`svg/seatArrowOut.svg`},seatVArrowIn:{glyph:``,size:24,tags:[`generic`,`arrow`,`actions`],fileSvg:`svg/seatVArrowIn.svg`},seatVArrowOut:{glyph:``,size:24,tags:[`generic`,`arrow`,`actions`],fileSvg:`svg/seatVArrowOut.svg`},vehicleArrowIn:{glyph:``,size:24,tags:[`generic`,`arrow`,`actions`],fileSvg:`svg/vehicleArrowIn.svg`},vehicleArrowOut:{glyph:``,size:24,tags:[`generic`,`arrow`,`actions`],fileSvg:`svg/vehicleArrowOut.svg`},leverFrontOperate:{glyph:``,size:24,tags:[`generic`,`actions`],fileSvg:`svg/leverFrontOperate.svg`},leverSideDown:{glyph:``,size:24,tags:[`generic`,`actions`],fileSvg:`svg/leverSideDown.svg`},leverSideOperate:{glyph:``,size:24,tags:[`generic`,`actions`],fileSvg:`svg/leverSideOperate.svg`},leverSideUp:{glyph:``,size:24,tags:[`generic`,`actions`],fileSvg:`svg/leverSideUp.svg`},medalEmpty:{glyph:``,size:24,tags:[`generic`,`reward`,`achievment`],fileSvg:`svg/medalEmpty.svg`},medalStar:{glyph:``,size:24,tags:[`generic`,`reward`,`achievment`],fileSvg:`svg/medalStar.svg`},seatArrowInLeft:{glyph:``,size:24,tags:[`generic`,`arrow`,`actions`],fileSvg:`svg/seatArrowInLeft.svg`},seatArrowOutLeft:{glyph:``,size:24,tags:[`generic`,`arrow`,`actions`],fileSvg:`svg/seatArrowOutLeft.svg`},seatVArrowInLeft:{glyph:``,size:24,tags:[`generic`,`arrow`,`actions`],fileSvg:`svg/seatVArrowInLeft.svg`},seatVArrowOutLeft:{glyph:``,size:24,tags:[`generic`,`arrow`,`actions`],fileSvg:`svg/seatVArrowOutLeft.svg`},badgeRoundEmpty:{glyph:``,size:24,tags:[`generic`,`reward`,`achievment`],fileSvg:`svg/badgeRoundEmpty.svg`},badgeRoundStar:{glyph:``,size:24,tags:[`generic`,`reward`,`achievment`],fileSvg:`svg/badgeRoundStar.svg`},badgeRound:{glyph:``,size:24,tags:[`generic`,`reward`,`achievment`],fileSvg:`svg/badgeRound.svg`},badge:{glyph:``,size:24,tags:[`generic`,`reward`,`achievment`],fileSvg:`svg/badge.svg`},beamCurrencyOutlineLarge:{glyph:``,size:48,tags:[`outline`,`generic`,`currency`],fileSvg:`svg/beamCurrencyOutlineLarge.svg`},carSideOutlineLarge:{glyph:``,size:48,tags:[`generic`,`vehicle`],fileSvg:`svg/carSideOutlineLarge.svg`},flagOutlineLarge:{glyph:``,size:48,tags:[`generic`,`mission`,`scenario`],fileSvg:`svg/flagOutlineLarge.svg`},terrainOutlineLarge:{glyph:``,size:48,tags:[`generic`],fileSvg:`svg/terrainOutlineLarge.svg`},houseWrenchRoof:{glyph:``,size:24,tags:[`career`,`garage`,`features`,`house`],fileSvg:`svg/houseWrenchRoof.svg`},houseWrench:{glyph:``,size:24,tags:[`career`,`garage`,`features`,`house`],fileSvg:`svg/houseWrench.svg`},eject:{glyph:``,size:24,tags:[`playback`],fileSvg:`svg/eject.svg`},rallyHelmet3To4:{glyph:``,size:24,tags:[`helmet`,`rally`,`generic`,`racing`,`game mode`],fileSvg:`svg/rallyHelmet3To4.svg`},rallyHelmet:{glyph:``,size:24,tags:[`helmet`,`rally`,`generic`,`racing`,`game mode`],fileSvg:`svg/rallyHelmet.svg`},test:{glyph:``,size:24,tags:[`generic`,`hazard`],fileSvg:`svg/test.svg`},tripleCaution:{glyph:``,size:48,tags:[`rally`,`pace notes`,`directions`,`surface`,`features`],fileSvg:`svg/tripleCaution.svg`},globeSimpleNotSign:{glyph:``,size:24,tags:[`generic`,`offline`],fileSvg:`svg/globeSimpleNotSign.svg`},globeSimplified:{glyph:``,size:24,tags:[`generic`,`online`],fileSvg:`svg/globeSimplified.svg`},radialMenu:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/radialMenu.svg`},branch:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/branch.svg`},NA:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/NA.svg`},psCircleOutline:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/psCircleOutline.svg`},psCircle:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/psCircle.svg`},psCreate2:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/psCreate2.svg`},psCreate:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/psCreate.svg`},psCrossOutline:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/psCrossOutline.svg`},psCross:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/psCross.svg`},psDDefaultOutline:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/psDDefaultOutline.svg`},psDDefaultSolid:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/psDDefaultSolid.svg`},psDDown:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/psDDown.svg`},psDLeft:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/psDLeft.svg`},psDRight:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/psDRight.svg`},psDUp:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/psDUp.svg`},psL1:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/psL1.svg`},psL2:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/psL2.svg`},psL3ButtonArrowDown:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/psL3ButtonArrowDown.svg`},psL3Button:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/psL3Button.svg`},psLSXLeft:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/psLSXLeft.svg`},psLSXRight:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/psLSXRight.svg`},psLSX:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/psLSX.svg`},psLSYDown:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/psLSYDown.svg`},psLSYUp:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/psLSYUp.svg`},psLSY:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/psLSY.svg`},psLS:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/psLS.svg`},psMenu2:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/psMenu2.svg`},psMenu:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/psMenu.svg`},psR1:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/psR1.svg`},psR2:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/psR2.svg`},psR3ButtonArrowDown:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/psR3ButtonArrowDown.svg`},psR3Button:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/psR3Button.svg`},psRSXLeft:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/psRSXLeft.svg`},psRSXRight:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/psRSXRight.svg`},psRSX:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/psRSX.svg`},psRSYDown:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/psRSYDown.svg`},psRSYUp:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/psRSYUp.svg`},psRSY:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/psRSY.svg`},psRS:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/psRS.svg`},psSquareOutline:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/psSquareOutline.svg`},psSquare:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/psSquare.svg`},psTrackpadNavigate:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/psTrackpadNavigate.svg`},psTrackpadPressCenter:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/psTrackpadPressCenter.svg`},psTrackpadPressLeft:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/psTrackpadPressLeft.svg`},psTrackpadPressRight:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/psTrackpadPressRight.svg`},psTrackpadSwipeDown:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/psTrackpadSwipeDown.svg`},psTrackpadSwipeLeft:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/psTrackpadSwipeLeft.svg`},psTrackpadSwipeRight:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/psTrackpadSwipeRight.svg`},psTrackpadSwipeUp:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/psTrackpadSwipeUp.svg`},psTriangleOutline:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/psTriangleOutline.svg`},psTriangle:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/psTriangle.svg`},xboxAOutline:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/xboxAOutline.svg`},xboxBOutline:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/xboxBOutline.svg`},xboxLSButtonArrowDown:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/xboxLSButtonArrowDown.svg`},xboxRSButtonArrowDown:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/xboxRSButtonArrowDown.svg`},xboxXAxisLeft:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/xboxXAxisLeft.svg`},xboxXAxisRight:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/xboxXAxisRight.svg`},xboxXOutline:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/xboxXOutline.svg`},xboxXRotLeft:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/xboxXRotLeft.svg`},xboxXRotRight:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/xboxXRotRight.svg`},xboxYAxisDown:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/xboxYAxisDown.svg`},xboxYAxisUp:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/xboxYAxisUp.svg`},xboxYOutline:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/xboxYOutline.svg`},xboxYRotDown:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/xboxYRotDown.svg`},xboxYRotUp:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/xboxYRotUp.svg`},cableSection:{glyph:``,size:24,tags:[`material`,`beam`,`strap`],fileSvg:`svg/cableSection.svg`},strapHook:{glyph:``,size:24,tags:[`material`,`strap`],fileSvg:`svg/strapHook.svg`},strapRatchet:{glyph:``,size:24,tags:[`material`,`strap`],fileSvg:`svg/strapRatchet.svg`},carFastReverse:{glyph:``,size:24,tags:[`vehicle`],fileSvg:`svg/carFastReverse.svg`},carsChase:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/carsChase.svg`},carsFlee:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/carsFlee.svg`},gaugeFull:{glyph:``,size:24,tags:[`poi`],fileSvg:`svg/gaugeFull.svg`},hammerParticles:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/hammerParticles.svg`},kbArrowsDown:{glyph:``,size:24,tags:[`keyboard`,`controls`],fileSvg:`svg/kbArrowsDown.svg`},kbArrowsLeftRight:{glyph:``,size:24,tags:[`keyboard`,`controls`],fileSvg:`svg/kbArrowsLeftRight.svg`},kbArrowsLeft:{glyph:``,size:24,tags:[`keyboard`,`controls`],fileSvg:`svg/kbArrowsLeft.svg`},kbArrowsOutline:{glyph:``,size:24,tags:[`keyboard`,`controls`],fileSvg:`svg/kbArrowsOutline.svg`},kbArrowsRight:{glyph:``,size:24,tags:[`keyboard`,`controls`],fileSvg:`svg/kbArrowsRight.svg`},kbArrowsSolid:{glyph:``,size:24,tags:[`keyboard`,`controls`],fileSvg:`svg/kbArrowsSolid.svg`},kbArrowsUpDown:{glyph:``,size:24,tags:[`keyboard`,`controls`],fileSvg:`svg/kbArrowsUpDown.svg`},kbArrowsUp:{glyph:``,size:24,tags:[`keyboard`,`controls`],fileSvg:`svg/kbArrowsUp.svg`},magicWand:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/magicWand.svg`},psDLeftRight:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/psDLeftRight.svg`},psDUpDown:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/psDUpDown.svg`},pushBackward:{glyph:``,size:24,tags:[`physics`,`force`],fileSvg:`svg/pushBackward.svg`},pushDown:{glyph:``,size:24,tags:[`physics`,`force`],fileSvg:`svg/pushDown.svg`},pushForward:{glyph:``,size:24,tags:[`physics`,`force`],fileSvg:`svg/pushForward.svg`},rangeboxHi:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/rangeboxHi.svg`},rangeboxLo:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/rangeboxLo.svg`},routeSimpleFlag:{glyph:``,size:24,tags:[`route`,`traffic`],fileSvg:`svg/routeSimpleFlag.svg`},xboxDLeftRight:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/xboxDLeftRight.svg`},xboxDUpDown:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/xboxDUpDown.svg`},carsWrench:{glyph:``,size:24,tags:[`vehicle`,`select`],fileSvg:`svg/carsWrench.svg`},jointCycleMultiple:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/jointCycleMultiple.svg`},jointCycle:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/jointCycle.svg`},dice24:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/dice24.svg`},diceD6:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/diceD6.svg`},pathDice:{glyph:``,size:24,tags:[`camera`],fileSvg:`svg/pathDice.svg`},sunDown:{glyph:``,size:24,tags:[`environment`],fileSvg:`svg/sunDown.svg`},xmarkBold:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/xmarkBold.svg`},intakeTrumpets:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/intakeTrumpets.svg`},transmissionCvt:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/transmissionCvt.svg`},house:{glyph:``,size:24,tags:[`career`,`generic`,`garage`,`features`,`house`],fileSvg:`svg/house.svg`},playPause:{glyph:``,size:24,tags:[`playback`],fileSvg:`svg/playPause.svg`},picture:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/picture.svg`},auxUpDown:{glyph:``,size:24,tags:[`vehicle`,`features`,`equipment`],fileSvg:`svg/auxUpDown.svg`},bucketArmUpDown:{glyph:``,size:24,tags:[`vehicle`,`features`,`equipment`],fileSvg:`svg/bucketArmUpDown.svg`},bucketTilt:{glyph:``,size:24,tags:[`vehicle`,`features`,`equipment`],fileSvg:`svg/bucketTilt.svg`},bucketArmDown:{glyph:``,size:24,tags:[`vehicle`,`features`,`equipment`],fileSvg:`svg/bucketArmDown.svg`},bucketArmLevel:{glyph:``,size:24,tags:[`vehicle`,`features`,`equipment`],fileSvg:`svg/bucketArmLevel.svg`},bucketArmUp:{glyph:``,size:24,tags:[`vehicle`,`features`,`equipment`],fileSvg:`svg/bucketArmUp.svg`},bucketTiltDown:{glyph:``,size:24,tags:[`vehicle`,`features`,`equipment`],fileSvg:`svg/bucketTiltDown.svg`},bucketTiltLevel:{glyph:``,size:24,tags:[`vehicle`,`features`,`equipment`],fileSvg:`svg/bucketTiltLevel.svg`},bucketTiltUp:{glyph:``,size:24,tags:[`vehicle`,`features`,`equipment`],fileSvg:`svg/bucketTiltUp.svg`},dumpBedDown:{glyph:``,size:24,tags:[`vehicle`,`features`,`equipment`],fileSvg:`svg/dumpBedDown.svg`},dumpBedUpDown:{glyph:``,size:24,tags:[`vehicle`,`features`,`equipment`],fileSvg:`svg/dumpBedUpDown.svg`},dumpBedUp:{glyph:``,size:24,tags:[`vehicle`,`features`,`equipment`],fileSvg:`svg/dumpBedUp.svg`},beamCurrencyThin:{glyph:``,size:24,tags:[`career`,`currencies`],fileSvg:`svg/beamCurrencyThin.svg`},shieldCheckmarkProgressbar:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/shieldCheckmarkProgressbar.svg`}}),iconsBySize=Object.freeze({16:{arrowsUp:icons$2.arrowsUp,bigDot:icons$2.bigDot,connectorBold:icons$2.connectorBold,cornerTopRight:icons$2.cornerTopRight,plusBold:icons$2.plusBold,puzzlePieceBold:icons$2.puzzlePieceBold},24:{"4WD":icons$2[`4WD`],"9dividedby10":icons$2[`9dividedby10`],abandon:icons$2.abandon,ABSIndicator:icons$2.ABSIndicator,addItemPolygon:icons$2.addItemPolygon,addListItem:icons$2.addListItem,addPolygonVertex:icons$2.addPolygonVertex,adjust:icons$2.adjust,AIMicrochip:icons$2.AIMicrochip,AIRace:icons$2.AIRace,aperture:icons$2.aperture,arrowLargeDown:icons$2.arrowLargeDown,arrowLargeLeft:icons$2.arrowLargeLeft,arrowLargeRight:icons$2.arrowLargeRight,arrowLargeUp:icons$2.arrowLargeUp,arrowSmallDown:icons$2.arrowSmallDown,arrowSmallLeft:icons$2.arrowSmallLeft,arrowSmallRight:icons$2.arrowSmallRight,arrowSmallUp:icons$2.arrowSmallUp,arrowSolidLeft:icons$2.arrowSolidLeft,arrowSolidRight:icons$2.arrowSolidRight,autobahn:icons$2.autobahn,AWD:icons$2.AWD,axleLift:icons$2.axleLift,axleCenter:icons$2.axleCenter,axleFront:icons$2.axleFront,axleRear:icons$2.axleRear,bSpline:icons$2.bSpline,banknotes:icons$2.banknotes,barrelKnocker01:icons$2.barrelKnocker01,barrelKnocker02:icons$2.barrelKnocker02,beamCrashBarrier1:icons$2.beamCrashBarrier1,beamCrashBarrier2:icons$2.beamCrashBarrier2,beamCrashBarrier3:icons$2.beamCrashBarrier3,beamCurrency:icons$2.beamCurrency,beamNG:icons$2.beamNG,beamXPFull:icons$2.beamXPFull,beamXPLo:icons$2.beamXPLo,bezierPath1:icons$2.bezierPath1,bezierPath2:icons$2.bezierPath2,bicycle1:icons$2.bicycle1,bicycle2:icons$2.bicycle2,BNGFolder:icons$2.BNGFolder,BNGMicrochip:icons$2.BNGMicrochip,bollard:icons$2.bollard,bookmark:icons$2.bookmark,booleanIntersect:icons$2.booleanIntersect,boxDropOff01:icons$2.boxDropOff01,boxDropOff02:icons$2.boxDropOff02,boxDropOff03:icons$2.boxDropOff03,boxPickUp01:icons$2.boxPickUp01,boxPickUp02:icons$2.boxPickUp02,boxPickUp03:icons$2.boxPickUp03,boxPickUpDropOff01:icons$2.boxPickUpDropOff01,boxPickUpDropOff02:icons$2.boxPickUpDropOff02,boxTruck:icons$2.boxTruck,broom:icons$2.broom,bucketAdd:icons$2.bucketAdd,bucketSubtract:icons$2.bucketSubtract,bug:icons$2.bug,bulldozer:icons$2.bulldozer,bus:icons$2.bus,camera3Fourth1:icons$2.camera3Fourth1,cameraBack1:icons$2.cameraBack1,cameraFocusOnPath:icons$2.cameraFocusOnPath,cameraFocusOnVehicle1:icons$2.cameraFocusOnVehicle1,cameraFocusOnVehicle2:icons$2.cameraFocusOnVehicle2,cameraFocusTopDown:icons$2.cameraFocusTopDown,cameraFront1:icons$2.cameraFront1,cameraSideLeft:icons$2.cameraSideLeft,cameraSideLeft2:icons$2.cameraSideLeft2,cameraSideRight:icons$2.cameraSideRight,cameraSideRight2:icons$2.cameraSideRight2,cameraTop1:icons$2.cameraTop1,cannon:icons$2.cannon,carChase01:icons$2.carChase01,carCoin:icons$2.carCoin,carCoins:icons$2.carCoins,carCrash:icons$2.carCrash,carDealer:icons$2.carDealer,carOffroadOutlineRear:icons$2.carOffroadOutlineRear,carOffroadOutlineSide:icons$2.carOffroadOutlineSide,carOffroadRear:icons$2.carOffroadRear,carOffroadSide:icons$2.carOffroadSide,carSensors:icons$2.carSensors,carStarred:icons$2.carStarred,carToWheels:icons$2.carToWheels,carUp:icons$2.carUp,carWithLidar:icons$2.carWithLidar,car:icons$2.car,cardboardBox:icons$2.cardboardBox,carsChase02:icons$2.carsChase02,cars:icons$2.cars,catalog01:icons$2.catalog01,catalog02:icons$2.catalog02,catalog03:icons$2.catalog03,centrifugalClutchLocked03:icons$2.centrifugalClutchLocked03,centrifugalClutchUnlocked03:icons$2.centrifugalClutchUnlocked03,charge:icons$2.charge,charging:icons$2.charging,chartBars:icons$2.chartBars,checkboxOff:icons$2.checkboxOff,checkboxOn:icons$2.checkboxOn,checkmarkBold:icons$2.checkmarkBold,checkmark:icons$2.checkmark,circuitMicrochip:icons$2.circuitMicrochip,circuit:icons$2.circuit,clapperboard:icons$2.clapperboard,code:icons$2.code,cogDamaged:icons$2.cogDamaged,cogsDamaged:icons$2.cogsDamaged,cogs:icons$2.cogs,concreteRoadBlock:icons$2.concreteRoadBlock,coolantTemp:icons$2.coolantTemp,copy:icons$2.copy,crossroads1:icons$2.crossroads1,crossroads2:icons$2.crossroads2,cruiseDisable:icons$2.cruiseDisable,cruiseEnable:icons$2.cruiseEnable,cup:icons$2.cup,dataExchange:icons$2.dataExchange,day:icons$2.day,DCBattery:icons$2.DCBattery,decalRoad:icons$2.decalRoad,decal:icons$2.decal,deform:icons$2.deform,deliveryTruckArrows:icons$2.deliveryTruckArrows,deliveryTruck:icons$2.deliveryTruck,differentialFrontDefault:icons$2.differentialFrontDefault,differentialFrontLocked:icons$2.differentialFrontLocked,differentialMiddleDefault:icons$2.differentialMiddleDefault,differentialMiddleLocked:icons$2.differentialMiddleLocked,differentialRearDefault:icons$2.differentialRearDefault,differentialRearLocked:icons$2.differentialRearLocked,doorHandle:icons$2.doorHandle,doorIn:icons$2.doorIn,drag01:icons$2.drag01,drag02:icons$2.drag02,drift01:icons$2.drift01,drift02:icons$2.drift02,drivetrainGeneric:icons$2.drivetrainGeneric,drivetrainSpecial:icons$2.drivetrainSpecial,editCheckmark:icons$2.editCheckmark,edit:icons$2.edit,engine:icons$2.engine,ESCOff:icons$2.ESCOff,ESCOn:icons$2.ESCOn,ESC:icons$2.ESC,evade:icons$2.evade,exhaustValve:icons$2.exhaustValve,exit:icons$2.exit,export:icons$2.export,eyeOutlineClosed:icons$2.eyeOutlineClosed,eyeOutlineOpened:icons$2.eyeOutlineOpened,eyeSolidClosed:icons$2.eyeSolidClosed,eyeSolidOpened:icons$2.eyeSolidOpened,eyeWaves:icons$2.eyeWaves,facility02:icons$2.facility02,fastBackward:icons$2.fastBackward,fastForward:icons$2.fastForward,fastTravel:icons$2.fastTravel,filter:icons$2.filter,flagNew:icons$2.flagNew,flag:icons$2.flag,flatBulbBeam:icons$2.flatBulbBeam,flatbedTruck:icons$2.flatbedTruck,floppyDisk:icons$2.floppyDisk,fogLight:icons$2.fogLight,folder:icons$2.folder,forklift:icons$2.forklift,FPS:icons$2.FPS,fragile:icons$2.fragile,frontAxleMidpoint:icons$2.frontAxleMidpoint,frontBumperMidpoint:icons$2.frontBumperMidpoint,fuelPumpFilling:icons$2.fuelPumpFilling,fuelPump:icons$2.fuelPump,FWD:icons$2.FWD,gamepadOld:icons$2.gamepadOld,gamepad:icons$2.gamepad,garage01:icons$2.garage01,garage02:icons$2.garage02,garage03:icons$2.garage03,gaugeEmpty:icons$2.gaugeEmpty,globe:icons$2.globe,GPSMark:icons$2.GPSMark,GPSSolid:icons$2.GPSSolid,group:icons$2.group,gyroscopeMicrochip:icons$2.gyroscopeMicrochip,gyroscope:icons$2.gyroscope,hazardLights:icons$2.hazardLights,helmets:icons$2.helmets,help:icons$2.help,highBeam:icons$2.highBeam,HUD:icons$2.HUD,hydroPump1:icons$2.hydroPump1,hydroPump2:icons$2.hydroPump2,hydroPump3:icons$2.hydroPump3,hydroPump4:icons$2.hydroPump4,hydroPump5:icons$2.hydroPump5,hydroPump6:icons$2.hydroPump6,hydroPump7:icons$2.hydroPump7,hypermiling:icons$2.hypermiling,import:icons$2.import,infinity:icons$2.infinity,info:icons$2.info,jointLocked:icons$2.jointLocked,jointUnlocked:icons$2.jointUnlocked,jump:icons$2.jump,keyboard:icons$2.keyboard,keys1:icons$2.keys1,keys2:icons$2.keys2,lampPost1:icons$2.lampPost1,lampPost2:icons$2.lampPost2,lampPost3:icons$2.lampPost3,laneProperties:icons$2.laneProperties,language:icons$2.language,laptop:icons$2.laptop,lidarPatternFullArcHighFreq:icons$2.lidarPatternFullArcHighFreq,lidarPatternFullArcMidFreq:icons$2.lidarPatternFullArcMidFreq,lidarPatternNarrowArc:icons$2.lidarPatternNarrowArc,lidar:icons$2.lidar,lightGarageG11:icons$2.lightGarageG11,lightGarageG12:icons$2.lightGarageG12,lightGarageG13:icons$2.lightGarageG13,lightGarageG14:icons$2.lightGarageG14,lightGarageG21:icons$2.lightGarageG21,lightGarageG22:icons$2.lightGarageG22,lightGarageG23:icons$2.lightGarageG23,lightGarageG24:icons$2.lightGarageG24,lightGarageG31:icons$2.lightGarageG31,lightGarageG32:icons$2.lightGarageG32,lightGarageG33:icons$2.lightGarageG33,lightGarageG34:icons$2.lightGarageG34,lightrunner:icons$2.lightrunner,limiterEnable:icons$2.limiterEnable,lineToTerrain:icons$2.lineToTerrain,link2:icons$2.link2,link:icons$2.link,listBig:icons$2.listBig,listIndented:icons$2.listIndented,listSmall:icons$2.listSmall,location1:icons$2.location1,location2:icons$2.location2,lockClosed:icons$2.lockClosed,lockOpened:icons$2.lockOpened,longRangeBeam1:icons$2.longRangeBeam1,longRangeBeam2:icons$2.longRangeBeam2,lowBeam:icons$2.lowBeam,magnetOnSurface:icons$2.magnetOnSurface,mapWithEmitter:icons$2.mapWithEmitter,mapPoint:icons$2.mapPoint,material:icons$2.material,mathDivide:icons$2.mathDivide,mathGreaterOrEqualThan:icons$2.mathGreaterOrEqualThan,mathGreaterThan:icons$2.mathGreaterThan,mathLessOrEqualThan:icons$2.mathLessOrEqualThan,mathLessThan:icons$2.mathLessThan,mathMinus:icons$2.mathMinus,mathMultiply:icons$2.mathMultiply,mathPlus:icons$2.mathPlus,medal:icons$2.medal,mesh4Cells:icons$2.mesh4Cells,mesh9Cells:icons$2.mesh9Cells,meshFence:icons$2.meshFence,meshRoad:icons$2.meshRoad,midRangeBeam1:icons$2.midRangeBeam1,midRangeBeam2:icons$2.midRangeBeam2,minusRes:icons$2.minusRes,minus:icons$2.minus,mirrorInteriorMiddle:icons$2.mirrorInteriorMiddle,mirrorLeftBigBottomWideAngle:icons$2.mirrorLeftBigBottomWideAngle,mirrorLeftBigTop:icons$2.mirrorLeftBigTop,mirrorLeftBig:icons$2.mirrorLeftBig,mirrorLeftBonnet:icons$2.mirrorLeftBonnet,mirrorLeftDefault:icons$2.mirrorLeftDefault,mirrorRightBigBottomWideAngle:icons$2.mirrorRightBigBottomWideAngle,mirrorRightBigTop:icons$2.mirrorRightBigTop,mirrorRightBig:icons$2.mirrorRightBig,mirrorRightBonnet:icons$2.mirrorRightBonnet,mirrorRightDefault:icons$2.mirrorRightDefault,mirrorRoundWideAngle:icons$2.mirrorRoundWideAngle,mirrorTopWideAngle:icons$2.mirrorTopWideAngle,missionCheckboxCross:icons$2.missionCheckboxCross,mouseLMB:icons$2.mouseLMB,mouseMMB:icons$2.mouseMMB,mouseRMB:icons$2.mouseRMB,mouseWheel:icons$2.mouseWheel,mouseXAxis:icons$2.mouseXAxis,mouseXYAxis:icons$2.mouseXYAxis,mouseYAxis:icons$2.mouseYAxis,mouse:icons$2.mouse,move02:icons$2.move02,move:icons$2.move,movieCamera:icons$2.movieCamera,music:icons$2.music,N2OButton:icons$2.N2OButton,N2OHoriz:icons$2.N2OHoriz,N2OVert:icons$2.N2OVert,nextTrack:icons$2.nextTrack,night:icons$2.night,noNameControllerButton:icons$2.noNameControllerButton,nodeAddFirst01:icons$2.nodeAddFirst01,nodeAddFirst02:icons$2.nodeAddFirst02,nodeAddLast02:icons$2.nodeAddLast02,nodeAddMiddle01:icons$2.nodeAddMiddle01,nodeAddMiddle02:icons$2.nodeAddMiddle02,nodeAdd:icons$2.nodeAdd,nodeLast01:icons$2.nodeLast01,nodeRemove:icons$2.nodeRemove,odometerKM:icons$2.odometerKM,odometerMI:icons$2.odometerMI,odometer:icons$2.odometer,oilPressureIndicator:icons$2.oilPressureIndicator,order:icons$2.order,organization:icons$2.organization,palmCrossed:icons$2.palmCrossed,paperKnife:icons$2.paperKnife,parkingIndicator:icons$2.parkingIndicator,parking:icons$2.parking,pathArc:icons$2.pathArc,pathAroundObstacle:icons$2.pathAroundObstacle,pathLine:icons$2.pathLine,pathSpiral:icons$2.pathSpiral,pauseRound:icons$2.pauseRound,pause:icons$2.pause,personSolid:icons$2.personSolid,person:icons$2.person,photo:icons$2.photo,placeholder:icons$2.placeholder,playRound:icons$2.playRound,play:icons$2.play,playlist:icons$2.playlist,plusGarage1:icons$2.plusGarage1,plusGarage2:icons$2.plusGarage2,plusGarage3:icons$2.plusGarage3,plusGarage4:icons$2.plusGarage4,plusSet:icons$2.plusSet,plus:icons$2.plus,positionLights:icons$2.positionLights,powerGauge01:icons$2.powerGauge01,powerGauge02:icons$2.powerGauge02,powerGauge03:icons$2.powerGauge03,powerGauge04:icons$2.powerGauge04,powerGauge05:icons$2.powerGauge05,powerOnOff:icons$2.powerOnOff,prevTrack:icons$2.prevTrack,publisher:icons$2.publisher,puzzleModule:icons$2.puzzleModule,raceFlag:icons$2.raceFlag,radarIdeal:icons$2.radarIdeal,radarRoundIdeal:icons$2.radarRoundIdeal,radarRound:icons$2.radarRound,radar:icons$2.radar,rangeboxHi2:icons$2.rangeboxHi2,rangeboxHi4:icons$2.rangeboxHi4,rangeboxHiA:icons$2.rangeboxHiA,rangeboxLo2:icons$2.rangeboxLo2,rangeboxLo4:icons$2.rangeboxLo4,rangeboxLoA:icons$2.rangeboxLoA,rearAxleMidpoint:icons$2.rearAxleMidpoint,rearBumperMidpoint:icons$2.rearBumperMidpoint,reconfigure:icons$2.reconfigure,redo:icons$2.redo,reflectNot:icons$2.reflectNot,reflect:icons$2.reflect,rename:icons$2.rename,replay:icons$2.replay,restart:icons$2.restart,roadDividerLinesDecal:icons$2.roadDividerLinesDecal,roadEdgeLineDecal:icons$2.roadEdgeLineDecal,roadEndLineDecal:icons$2.roadEndLineDecal,roadFace:icons$2.roadFace,roadInfo:icons$2.roadInfo,roadMarkingOutline:icons$2.roadMarkingOutline,roadMarkingSolid:icons$2.roadMarkingSolid,roadOutline:icons$2.roadOutline,roadRefPathDecal:icons$2.roadRefPathDecal,roadRefPath:icons$2.roadRefPath,roadStartLineDecal:icons$2.roadStartLineDecal,road:icons$2.road,rockCrawling01:icons$2.rockCrawling01,rockCrawling02:icons$2.rockCrawling02,routeAdd:icons$2.routeAdd,routeComplex:icons$2.routeComplex,routeSimple:icons$2.routeSimple,runScript:icons$2.runScript,RWD:icons$2.RWD,saveAs1:icons$2.saveAs1,scan:icons$2.scan,search:icons$2.search,semiTrailer:icons$2.semiTrailer,semiTruckCabover:icons$2.semiTruckCabover,semiTruckUS:icons$2.semiTruckUS,semiTruck:icons$2.semiTruck,shortRangeBeam1:icons$2.shortRangeBeam1,shortRangeBeam2:icons$2.shortRangeBeam2,signal01a:icons$2.signal01a,signal02a:icons$2.signal02a,signal03a:icons$2.signal03a,signal04a:icons$2.signal04a,signal05a:icons$2.signal05a,slashLeft:icons$2.slashLeft,slashRight:icons$2.slashRight,smallTrailer:icons$2.smallTrailer,smartphone1:icons$2.smartphone1,smartphone2:icons$2.smartphone2,snowflake:icons$2.snowflake,soundFadeOut:icons$2.soundFadeOut,soundLimit:icons$2.soundLimit,soundLoud:icons$2.soundLoud,soundMonoL:icons$2.soundMonoL,soundMonoR:icons$2.soundMonoR,soundOff:icons$2.soundOff,soundQuiet:icons$2.soundQuiet,soundStereo:icons$2.soundStereo,soundWave01:icons$2.soundWave01,soundWave02:icons$2.soundWave02,sphereOnPathNumber:icons$2.sphereOnPathNumber,sphereOnPath:icons$2.sphereOnPath,sphericalBeam:icons$2.sphericalBeam,spoilerLift:icons$2.spoilerLift,sprayCan:icons$2.sprayCan,stack3:icons$2.stack3,star:icons$2.star,starSecondary:icons$2.starSecondary,steeringWheelCommon:icons$2.steeringWheelCommon,steeringWheelSporty:icons$2.steeringWheelSporty,stopwatchArrows01:icons$2.stopwatchArrows01,stopwatchArrows02:icons$2.stopwatchArrows02,stopwatchSectionOutlinedEnd:icons$2.stopwatchSectionOutlinedEnd,stopwatchSectionOutlinedStart:icons$2.stopwatchSectionOutlinedStart,stopwatchSectionSolidEnd:icons$2.stopwatchSectionSolidEnd,stopwatchSectionSolidStart:icons$2.stopwatchSectionSolidStart,strobeLights:icons$2.strobeLights,sunRise:icons$2.sunRise,survellianceCamera:icons$2.survellianceCamera,suspension01:icons$2.suspension01,suspension02:icons$2.suspension02,switchBlock:icons$2.switchBlock,switchOutline:icons$2.switchOutline,sync:icons$2.sync,synchro01:icons$2.synchro01,synchro02:icons$2.synchro02,tankerTrailer:icons$2.tankerTrailer,targetJump:icons$2.targetJump,taxiCar1:icons$2.taxiCar1,taxiCar3:icons$2.taxiCar3,taxiCarT:icons$2.taxiCarT,taxiCheckerLamp:icons$2.taxiCheckerLamp,terrainToLine:icons$2.terrainToLine,terrain:icons$2.terrain,thinBulbBeam:icons$2.thinBulbBeam,thinnerBulbBeam:icons$2.thinnerBulbBeam,thisSideUp:icons$2.thisSideUp,tiles:icons$2.tiles,timer:icons$2.timer,tireDirection3Fourth2:icons$2.tireDirection3Fourth2,tireDirection3Fourth3:icons$2.tireDirection3Fourth3,tireDirectionFront2:icons$2.tireDirectionFront2,tireDirectionSide2:icons$2.tireDirectionSide2,tireDirectionTop2:icons$2.tireDirectionTop2,tirePressureDecrease01:icons$2.tirePressureDecrease01,tirePressureDecrease02:icons$2.tirePressureDecrease02,tirePressureGaugeAlt01:icons$2.tirePressureGaugeAlt01,tirePressureGaugeAlt02:icons$2.tirePressureGaugeAlt02,tirePressureGaugeAlt03:icons$2.tirePressureGaugeAlt03,tirePressureGaugeOutlined01:icons$2.tirePressureGaugeOutlined01,tirePressureGaugeOutlined02:icons$2.tirePressureGaugeOutlined02,tirePressureGaugeOutlined03:icons$2.tirePressureGaugeOutlined03,tirePressureGaugeSolid01:icons$2.tirePressureGaugeSolid01,tirePressureGaugeSolid02:icons$2.tirePressureGaugeSolid02,tirePressureGaugeSolid03:icons$2.tirePressureGaugeSolid03,tirePressureIncrease01:icons$2.tirePressureIncrease01,tirePressureIncrease02:icons$2.tirePressureIncrease02,tirePressureStopLine:icons$2.tirePressureStopLine,tirePressureStopOctoLine:icons$2.tirePressureStopOctoLine,tirePressureStopOctoSolid:icons$2.tirePressureStopOctoSolid,tirePressureStopSolid:icons$2.tirePressureStopSolid,toCOMWithWheels:icons$2.toCOMWithWheels,toCOM:icons$2.toCOM,toGarage:icons$2.toGarage,touch:icons$2.touch,tow:icons$2.tow,tractionControl:icons$2.tractionControl,trafficCone:icons$2.trafficCone,transform:icons$2.transform,transmissionA:icons$2.transmissionA,transmissionM:icons$2.transmissionM,transparencyMask:icons$2.transparencyMask,trashBin1:icons$2.trashBin1,trashBin2:icons$2.trashBin2,triangleBeam:icons$2.triangleBeam,trim:icons$2.trim,tulipBeam:icons$2.tulipBeam,tunnel:icons$2.tunnel,turbine:icons$2.turbine,twoRoadsAdd:icons$2.twoRoadsAdd,twoRoadsCrossAdd:icons$2.twoRoadsCrossAdd,twoRoadsLink:icons$2.twoRoadsLink,twoUnicyclesOnly:icons$2.twoUnicyclesOnly,undo:icons$2.undo,ungroup:icons$2.ungroup,unlink:icons$2.unlink,vehicleDoorsClose:icons$2.vehicleDoorsClose,vehicleDoorsOpen:icons$2.vehicleDoorsOpen,vehicleDoors:icons$2.vehicleDoors,vehicleFeatures01:icons$2.vehicleFeatures01,vehicleFeatures02:icons$2.vehicleFeatures02,vehicleFeatures03:icons$2.vehicleFeatures03,vehicleHood:icons$2.vehicleHood,vehicleTrunk:icons$2.vehicleTrunk,view:icons$2.view,voucherDiagonal1:icons$2.voucherDiagonal1,voucherDiagonal2:icons$2.voucherDiagonal2,voucherDiagonal3:icons$2.voucherDiagonal3,voucherHorizontal1:icons$2.voucherHorizontal1,voucherHorizontal2:icons$2.voucherHorizontal2,voucherHorizontal3:icons$2.voucherHorizontal3,wavesSignalReceived:icons$2.wavesSignalReceived,wavesSignalSentLeft:icons$2.wavesSignalSentLeft,wavesSignalSentRight:icons$2.wavesSignalSentRight,weather:icons$2.weather,weight:icons$2.weight,wheelHubLocked01:icons$2.wheelHubLocked01,wheelHubUnlocked01:icons$2.wheelHubUnlocked01,wigwags:icons$2.wigwags,wrench:icons$2.wrench,xboxA:icons$2.xboxA,xboxB:icons$2.xboxB,xboxDDefaultOutline:icons$2.xboxDDefaultOutline,xboxDDefaultSolid:icons$2.xboxDDefaultSolid,xboxDDown:icons$2.xboxDDown,xboxDLeft:icons$2.xboxDLeft,xboxDRight:icons$2.xboxDRight,xboxDUp:icons$2.xboxDUp,xboxLB:icons$2.xboxLB,xboxLSButton:icons$2.xboxLSButton,xboxLT:icons$2.xboxLT,xboxMenu:icons$2.xboxMenu,xboxRB:icons$2.xboxRB,xboxRSButton:icons$2.xboxRSButton,xboxRT:icons$2.xboxRT,xboxThumbL:icons$2.xboxThumbL,xboxThumbR:icons$2.xboxThumbR,xboxView:icons$2.xboxView,xboxXAxis:icons$2.xboxXAxis,xboxXRot:icons$2.xboxXRot,xboxX:icons$2.xboxX,xboxYAxis:icons$2.xboxYAxis,xboxYRot:icons$2.xboxYRot,xboxY:icons$2.xboxY,danger:icons$2.danger,droplet:icons$2.droplet,envelope:icons$2.envelope,fireDiamond:icons$2.fireDiamond,rocks:icons$2.rocks,xmark:icons$2.xmark,scale:icons$2.scale,locationDestination:icons$2.locationDestination,locationSource:icons$2.locationSource,accelerationKPH:icons$2.accelerationKPH,accelerationMPH:icons$2.accelerationMPH,boxTruckFast:icons$2.boxTruckFast,colorBrightnessSun:icons$2.colorBrightnessSun,colorCirclePalette:icons$2.colorCirclePalette,colorPalette:icons$2.colorPalette,colorSaturation:icons$2.colorSaturation,sortAscDown02:icons$2.sortAscDown02,sortAscDown:icons$2.sortAscDown,sortAscUp02:icons$2.sortAscUp02,sortAscUp:icons$2.sortAscUp,sortDescDown02:icons$2.sortDescDown02,sortDescDown:icons$2.sortDescDown,sortDescUp02:icons$2.sortDescUp02,sortDescUp:icons$2.sortDescUp,cardboardBoxCoins:icons$2.cardboardBoxCoins,lasso:icons$2.lasso,materialGlossy:icons$2.materialGlossy,materialMetal:icons$2.materialMetal,materialRoughness:icons$2.materialRoughness,materialTransparency01:icons$2.materialTransparency01,materialTransparency02:icons$2.materialTransparency02,metal01:icons$2.metal01,removeItemPolygon:icons$2.removeItemPolygon,removeListItem:icons$2.removeListItem,sortAsc:icons$2.sortAsc,sortDesc:icons$2.sortDesc,surfaceRoughness02:icons$2.surfaceRoughness02,shieldCheckmark:icons$2.shieldCheckmark,shieldHandCheckmark:icons$2.shieldHandCheckmark,shieldHandPlus:icons$2.shieldHandPlus,doorFrontCoins:icons$2.doorFrontCoins,doorFront:icons$2.doorFront,engineCoins:icons$2.engineCoins,exhaustMufflerCoins:icons$2.exhaustMufflerCoins,exhaustMuffler:icons$2.exhaustMuffler,headlightCoins:icons$2.headlightCoins,headlight:icons$2.headlight,tire3FourthCoins:icons$2.tire3FourthCoins,tire3Fourth:icons$2.tire3Fourth,turbineCoins:icons$2.turbineCoins,wheelDiscCoins:icons$2.wheelDiscCoins,wheelDisc:icons$2.wheelDisc,bridgeWithRiver:icons$2.bridgeWithRiver,gizmosOutline:icons$2.gizmosOutline,gizmosSolid:icons$2.gizmosSolid,highwayRoad3To2Merge01:icons$2.highwayRoad3To2Merge01,highwayRoad3To2Merge02:icons$2.highwayRoad3To2Merge02,highwayToUrbanRoadTransition01:icons$2.highwayToUrbanRoadTransition01,highwayToUrbanRoadTransition02:icons$2.highwayToUrbanRoadTransition02,pedestrianCrossing01:icons$2.pedestrianCrossing01,polygonalCube:icons$2.polygonalCube,roadEditOutline:icons$2.roadEditOutline,roadEditSolid:icons$2.roadEditSolid,roadFolderPlus:icons$2.roadFolderPlus,roadFolder:icons$2.roadFolder,roadGuideArrowOutline:icons$2.roadGuideArrowOutline,roadGuideArrowSolid:icons$2.roadGuideArrowSolid,roadOutlineMesh:icons$2.roadOutlineMesh,roadPedestrianCrossing02:icons$2.roadPedestrianCrossing02,roadProfileWithCheckmark:icons$2.roadProfileWithCheckmark,roadProfile:icons$2.roadProfile,roadRoundaboutJunction:icons$2.roadRoundaboutJunction,roadSidewalkTransition:icons$2.roadSidewalkTransition,roadStackPlus:icons$2.roadStackPlus,roadStack:icons$2.roadStack,roadTJunction:icons$2.roadTJunction,roadXJunction:icons$2.roadXJunction,roadYJunction:icons$2.roadYJunction,shoppingCart:icons$2.shoppingCart,singleLineToTerrain:icons$2.singleLineToTerrain,sphereOnMesh:icons$2.sphereOnMesh,twoLinesToTerrain:icons$2.twoLinesToTerrain,urbanRoad3To2Merge01:icons$2.urbanRoad3To2Merge01,urbanRoad3To2Merge02:icons$2.urbanRoad3To2Merge02,urbanRoadToHighwayTransition01:icons$2.urbanRoadToHighwayTransition01,urbanRoadToHighwayTransition02:icons$2.urbanRoadToHighwayTransition02,floppyDiskPlus:icons$2.floppyDiskPlus,highwayMerge:icons$2.highwayMerge,highwaySeparate:icons$2.highwaySeparate,highwayShoulderMerge:icons$2.highwayShoulderMerge,terrainToSingleLine:icons$2.terrainToSingleLine,terrainToTwoLines:icons$2.terrainToTwoLines,urbanRoadMerge:icons$2.urbanRoadMerge,urbanRoadSeparate:icons$2.urbanRoadSeparate,urbanShoulderMerge:icons$2.urbanShoulderMerge,discharging:icons$2.discharging,BNGChat:icons$2.BNGChat,chatBubble:icons$2.chatBubble,busTilted:icons$2.busTilted,cameraFarClip:icons$2.cameraFarClip,cameraNearClip:icons$2.cameraNearClip,explosion:icons$2.explosion,fireExtinguisher:icons$2.fireExtinguisher,fire:icons$2.fire,jointLockedMultiple:icons$2.jointLockedMultiple,jointUnlockedMultiple:icons$2.jointUnlockedMultiple,toggleOff:icons$2.toggleOff,toggleOn:icons$2.toggleOn,viewFarClip:icons$2.viewFarClip,viewNearClip:icons$2.viewNearClip,twoArrowsHorizontal:icons$2.twoArrowsHorizontal,twoArrowsVertical:icons$2.twoArrowsVertical,circleSlashed:icons$2.circleSlashed,scissorsSlashed:icons$2.scissorsSlashed,scissors:icons$2.scissors,airPuffRight1:icons$2.airPuffRight1,airPuffUp1:icons$2.airPuffUp1,arrowsReplace:icons$2.arrowsReplace,arrowsShuffle:icons$2.arrowsShuffle,arrowsSwitch:icons$2.arrowsSwitch,carClock:icons$2.carClock,carFast:icons$2.carFast,carNumber1:icons$2.carNumber1,carNumber2:icons$2.carNumber2,carNumber3:icons$2.carNumber3,carNumber4:icons$2.carNumber4,carNumber5:icons$2.carNumber5,carNumber6:icons$2.carNumber6,carNumber7:icons$2.carNumber7,carNumber8:icons$2.carNumber8,carNumber9:icons$2.carNumber9,carPlus:icons$2.carPlus,carsChange:icons$2.carsChange,carsFollow:icons$2.carsFollow,doorFrontDetached:icons$2.doorFrontDetached,forceFieldPull1:icons$2.forceFieldPull1,forceFieldPull2:icons$2.forceFieldPull2,forceFieldPull3:icons$2.forceFieldPull3,forceFieldPush1:icons$2.forceFieldPush1,forceFieldPush2:icons$2.forceFieldPush2,forceFieldPush3:icons$2.forceFieldPush3,garageNumber1:icons$2.garageNumber1,garageNumber2:icons$2.garageNumber2,garageNumber3:icons$2.garageNumber3,garageNumber4:icons$2.garageNumber4,garageNumber5:icons$2.garageNumber5,garageNumber6:icons$2.garageNumber6,garageNumber7:icons$2.garageNumber7,garageNumber8:icons$2.garageNumber8,garageNumber9:icons$2.garageNumber9,hingeBroken:icons$2.hingeBroken,loadMesh:icons$2.loadMesh,octagonBrick:icons$2.octagonBrick,octagon:icons$2.octagon,pushUp:icons$2.pushUp,saveMesh:icons$2.saveMesh,square:icons$2.square,tireAirPuff:icons$2.tireAirPuff,tireDeflated:icons$2.tireDeflated,trafficLight:icons$2.trafficLight,enter:icons$2.enter,pedestrianRunning:icons$2.pedestrianRunning,pedestrianStanding:icons$2.pedestrianStanding,seatArrowIn:icons$2.seatArrowIn,seatArrowOut:icons$2.seatArrowOut,seatVArrowIn:icons$2.seatVArrowIn,seatVArrowOut:icons$2.seatVArrowOut,vehicleArrowIn:icons$2.vehicleArrowIn,vehicleArrowOut:icons$2.vehicleArrowOut,leverFrontOperate:icons$2.leverFrontOperate,leverSideDown:icons$2.leverSideDown,leverSideOperate:icons$2.leverSideOperate,leverSideUp:icons$2.leverSideUp,medalEmpty:icons$2.medalEmpty,medalStar:icons$2.medalStar,seatArrowInLeft:icons$2.seatArrowInLeft,seatArrowOutLeft:icons$2.seatArrowOutLeft,seatVArrowInLeft:icons$2.seatVArrowInLeft,seatVArrowOutLeft:icons$2.seatVArrowOutLeft,badgeRoundEmpty:icons$2.badgeRoundEmpty,badgeRoundStar:icons$2.badgeRoundStar,badgeRound:icons$2.badgeRound,badge:icons$2.badge,houseWrenchRoof:icons$2.houseWrenchRoof,houseWrench:icons$2.houseWrench,eject:icons$2.eject,rallyHelmet3To4:icons$2.rallyHelmet3To4,rallyHelmet:icons$2.rallyHelmet,test:icons$2.test,globeSimpleNotSign:icons$2.globeSimpleNotSign,globeSimplified:icons$2.globeSimplified,radialMenu:icons$2.radialMenu,branch:icons$2.branch,NA:icons$2.NA,psCircleOutline:icons$2.psCircleOutline,psCircle:icons$2.psCircle,psCreate2:icons$2.psCreate2,psCreate:icons$2.psCreate,psCrossOutline:icons$2.psCrossOutline,psCross:icons$2.psCross,psDDefaultOutline:icons$2.psDDefaultOutline,psDDefaultSolid:icons$2.psDDefaultSolid,psDDown:icons$2.psDDown,psDLeft:icons$2.psDLeft,psDRight:icons$2.psDRight,psDUp:icons$2.psDUp,psL1:icons$2.psL1,psL2:icons$2.psL2,psL3ButtonArrowDown:icons$2.psL3ButtonArrowDown,psL3Button:icons$2.psL3Button,psLSXLeft:icons$2.psLSXLeft,psLSXRight:icons$2.psLSXRight,psLSX:icons$2.psLSX,psLSYDown:icons$2.psLSYDown,psLSYUp:icons$2.psLSYUp,psLSY:icons$2.psLSY,psLS:icons$2.psLS,psMenu2:icons$2.psMenu2,psMenu:icons$2.psMenu,psR1:icons$2.psR1,psR2:icons$2.psR2,psR3ButtonArrowDown:icons$2.psR3ButtonArrowDown,psR3Button:icons$2.psR3Button,psRSXLeft:icons$2.psRSXLeft,psRSXRight:icons$2.psRSXRight,psRSX:icons$2.psRSX,psRSYDown:icons$2.psRSYDown,psRSYUp:icons$2.psRSYUp,psRSY:icons$2.psRSY,psRS:icons$2.psRS,psSquareOutline:icons$2.psSquareOutline,psSquare:icons$2.psSquare,psTrackpadNavigate:icons$2.psTrackpadNavigate,psTrackpadPressCenter:icons$2.psTrackpadPressCenter,psTrackpadPressLeft:icons$2.psTrackpadPressLeft,psTrackpadPressRight:icons$2.psTrackpadPressRight,psTrackpadSwipeDown:icons$2.psTrackpadSwipeDown,psTrackpadSwipeLeft:icons$2.psTrackpadSwipeLeft,psTrackpadSwipeRight:icons$2.psTrackpadSwipeRight,psTrackpadSwipeUp:icons$2.psTrackpadSwipeUp,psTriangleOutline:icons$2.psTriangleOutline,psTriangle:icons$2.psTriangle,xboxAOutline:icons$2.xboxAOutline,xboxBOutline:icons$2.xboxBOutline,xboxLSButtonArrowDown:icons$2.xboxLSButtonArrowDown,xboxRSButtonArrowDown:icons$2.xboxRSButtonArrowDown,xboxXAxisLeft:icons$2.xboxXAxisLeft,xboxXAxisRight:icons$2.xboxXAxisRight,xboxXOutline:icons$2.xboxXOutline,xboxXRotLeft:icons$2.xboxXRotLeft,xboxXRotRight:icons$2.xboxXRotRight,xboxYAxisDown:icons$2.xboxYAxisDown,xboxYAxisUp:icons$2.xboxYAxisUp,xboxYOutline:icons$2.xboxYOutline,xboxYRotDown:icons$2.xboxYRotDown,xboxYRotUp:icons$2.xboxYRotUp,cableSection:icons$2.cableSection,strapHook:icons$2.strapHook,strapRatchet:icons$2.strapRatchet,carFastReverse:icons$2.carFastReverse,carsChase:icons$2.carsChase,carsFlee:icons$2.carsFlee,gaugeFull:icons$2.gaugeFull,hammerParticles:icons$2.hammerParticles,kbArrowsDown:icons$2.kbArrowsDown,kbArrowsLeftRight:icons$2.kbArrowsLeftRight,kbArrowsLeft:icons$2.kbArrowsLeft,kbArrowsOutline:icons$2.kbArrowsOutline,kbArrowsRight:icons$2.kbArrowsRight,kbArrowsSolid:icons$2.kbArrowsSolid,kbArrowsUpDown:icons$2.kbArrowsUpDown,kbArrowsUp:icons$2.kbArrowsUp,magicWand:icons$2.magicWand,psDLeftRight:icons$2.psDLeftRight,psDUpDown:icons$2.psDUpDown,pushBackward:icons$2.pushBackward,pushDown:icons$2.pushDown,pushForward:icons$2.pushForward,rangeboxHi:icons$2.rangeboxHi,rangeboxLo:icons$2.rangeboxLo,routeSimpleFlag:icons$2.routeSimpleFlag,xboxDLeftRight:icons$2.xboxDLeftRight,xboxDUpDown:icons$2.xboxDUpDown,carsWrench:icons$2.carsWrench,jointCycleMultiple:icons$2.jointCycleMultiple,jointCycle:icons$2.jointCycle,dice24:icons$2.dice24,diceD6:icons$2.diceD6,pathDice:icons$2.pathDice,sunDown:icons$2.sunDown,xmarkBold:icons$2.xmarkBold,intakeTrumpets:icons$2.intakeTrumpets,transmissionCvt:icons$2.transmissionCvt,house:icons$2.house,playPause:icons$2.playPause,picture:icons$2.picture,auxUpDown:icons$2.auxUpDown,bucketArmUpDown:icons$2.bucketArmUpDown,bucketTilt:icons$2.bucketTilt,bucketArmDown:icons$2.bucketArmDown,bucketArmLevel:icons$2.bucketArmLevel,bucketArmUp:icons$2.bucketArmUp,bucketTiltDown:icons$2.bucketTiltDown,bucketTiltLevel:icons$2.bucketTiltLevel,bucketTiltUp:icons$2.bucketTiltUp,dumpBedDown:icons$2.dumpBedDown,dumpBedUpDown:icons$2.dumpBedUpDown,dumpBedUp:icons$2.dumpBedUp,beamCurrencyThin:icons$2.beamCurrencyThin,shieldCheckmarkProgressbar:icons$2.shieldCheckmarkProgressbar},48:{AIL:icons$2.AIL,arrowLeftOutline:icons$2.arrowLeftOutline,arrowRightOutline:icons$2.arrowRightOutline,automaticTransmissionL:icons$2.automaticTransmissionL,beamsNodesMessageOutline:icons$2.beamsNodesMessageOutline,beamsNodesOutline:icons$2.beamsNodesOutline,beamsNodesPlugOutline:icons$2.beamsNodesPlugOutline,BNGEcosystemOutline:icons$2.BNGEcosystemOutline,carFrontRouteOutline:icons$2.carFrontRouteOutline,carSensorsOutline:icons$2.carSensorsOutline,carSideRouteOutline:icons$2.carSideRouteOutline,chargeLL:icons$2.chargeLL,cityOutline:icons$2.cityOutline,clutchL:icons$2.clutchL,couplerL:icons$2.couplerL,dialogOutline:icons$2.dialogOutline,documentSmileOutline:icons$2.documentSmileOutline,drivetrainOutline:icons$2.drivetrainOutline,electronicSchemeOutline:icons$2.electronicSchemeOutline,engineL:icons$2.engineL,engineOutline:icons$2.engineOutline,gearTuningOutline:icons$2.gearTuningOutline,giftBoxOutline:icons$2.giftBoxOutline,lidarOutline:icons$2.lidarOutline,medalStarOutline:icons$2.medalStarOutline,megaphoneOutline:icons$2.megaphoneOutline,multiseatL:icons$2.multiseatL,peopleOutline:icons$2.peopleOutline,personOutline:icons$2.personOutline,physicsOutline:icons$2.physicsOutline,playChainOutline:icons$2.playChainOutline,POITimeL:icons$2.POITimeL,proximitySensorsOutline:icons$2.proximitySensorsOutline,qualityBadgeStarOutline:icons$2.qualityBadgeStarOutline,qualityBadgeVOutline:icons$2.qualityBadgeVOutline,replayL:icons$2.replayL,roadblockL:icons$2.roadblockL,rotationL:icons$2.rotationL,sensorsL:icons$2.sensorsL,simRigOutline:icons$2.simRigOutline,suspensionOutline:icons$2.suspensionOutline,teamOutline:icons$2.teamOutline,techLightBulbOutline01:icons$2.techLightBulbOutline01,techLightBulbOutline02:icons$2.techLightBulbOutline02,temperatureL:icons$2.temperatureL,timeUnlockOutline:icons$2.timeUnlockOutline,timedLockOutline:icons$2.timedLockOutline,trafficOutline:icons$2.trafficOutline,tuningL:icons$2.tuningL,turbineL:icons$2.turbineL,voucherOutline:icons$2.voucherOutline,wheelBeamsNodesOutline:icons$2.wheelBeamsNodesOutline,wheelOutline:icons$2.wheelOutline,bridge:icons$2.bridge,bump:icons$2.bump,bumps:icons$2.bumps,caution:icons$2.caution,crest:icons$2.crest,doubleCaution:icons$2.doubleCaution,finish:icons$2.finish,jumpOverBump:icons$2.jumpOverBump,narrows:icons$2.narrows,pothole:icons$2.pothole,turn1:icons$2.turn1,turn2:icons$2.turn2,turn3:icons$2.turn3,turn4:icons$2.turn4,turn5:icons$2.turn5,turn6:icons$2.turn6,turnHp:icons$2.turnHp,turnSq:icons$2.turnSq,water:icons$2.water,beamCurrencyOutlineLarge:icons$2.beamCurrencyOutlineLarge,carSideOutlineLarge:icons$2.carSideOutlineLarge,flagOutlineLarge:icons$2.flagOutlineLarge,terrainOutlineLarge:icons$2.terrainOutlineLarge,tripleCaution:icons$2.tripleCaution},56:{circlePinBack:icons$2.circlePinBack,circlePinFront:icons$2.circlePinFront,markerRectanglePinBack:icons$2.markerRectanglePinBack,markerRectanglePinFront:icons$2.markerRectanglePinFront,markerTriangleBack:icons$2.markerTriangleBack,markerTriangleFront:icons$2.markerTriangleFront}}),iconsByTag=Object.freeze({vehicle:{"4WD":icons$2[`4WD`],ABSIndicator:icons$2.ABSIndicator,AWD:icons$2.AWD,axleLift:icons$2.axleLift,axleCenter:icons$2.axleCenter,axleFront:icons$2.axleFront,axleRear:icons$2.axleRear,boxTruck:icons$2.boxTruck,bus:icons$2.bus,carChase01:icons$2.carChase01,carCoin:icons$2.carCoin,carCoins:icons$2.carCoins,carCrash:icons$2.carCrash,carOffroadOutlineRear:icons$2.carOffroadOutlineRear,carOffroadOutlineSide:icons$2.carOffroadOutlineSide,carOffroadRear:icons$2.carOffroadRear,carOffroadSide:icons$2.carOffroadSide,carSensors:icons$2.carSensors,carStarred:icons$2.carStarred,carToWheels:icons$2.carToWheels,carUp:icons$2.carUp,carWithLidar:icons$2.carWithLidar,car:icons$2.car,carsChase02:icons$2.carsChase02,cars:icons$2.cars,centrifugalClutchLocked03:icons$2.centrifugalClutchLocked03,centrifugalClutchUnlocked03:icons$2.centrifugalClutchUnlocked03,cogDamaged:icons$2.cogDamaged,cogsDamaged:icons$2.cogsDamaged,cogs:icons$2.cogs,coolantTemp:icons$2.coolantTemp,cruiseDisable:icons$2.cruiseDisable,cruiseEnable:icons$2.cruiseEnable,DCBattery:icons$2.DCBattery,deliveryTruckArrows:icons$2.deliveryTruckArrows,deliveryTruck:icons$2.deliveryTruck,differentialFrontDefault:icons$2.differentialFrontDefault,differentialFrontLocked:icons$2.differentialFrontLocked,differentialMiddleDefault:icons$2.differentialMiddleDefault,differentialMiddleLocked:icons$2.differentialMiddleLocked,differentialRearDefault:icons$2.differentialRearDefault,differentialRearLocked:icons$2.differentialRearLocked,doorHandle:icons$2.doorHandle,drift01:icons$2.drift01,drift02:icons$2.drift02,drivetrainGeneric:icons$2.drivetrainGeneric,drivetrainSpecial:icons$2.drivetrainSpecial,engine:icons$2.engine,ESCOff:icons$2.ESCOff,ESCOn:icons$2.ESCOn,ESC:icons$2.ESC,exhaustValve:icons$2.exhaustValve,flatbedTruck:icons$2.flatbedTruck,fogLight:icons$2.fogLight,forklift:icons$2.forklift,FWD:icons$2.FWD,hazardLights:icons$2.hazardLights,highBeam:icons$2.highBeam,hydroPump1:icons$2.hydroPump1,hydroPump2:icons$2.hydroPump2,hydroPump3:icons$2.hydroPump3,hydroPump4:icons$2.hydroPump4,hydroPump5:icons$2.hydroPump5,hydroPump6:icons$2.hydroPump6,hydroPump7:icons$2.hydroPump7,jointLocked:icons$2.jointLocked,jointUnlocked:icons$2.jointUnlocked,keys1:icons$2.keys1,keys2:icons$2.keys2,limiterEnable:icons$2.limiterEnable,lowBeam:icons$2.lowBeam,minusRes:icons$2.minusRes,mirrorInteriorMiddle:icons$2.mirrorInteriorMiddle,mirrorLeftBigBottomWideAngle:icons$2.mirrorLeftBigBottomWideAngle,mirrorLeftBigTop:icons$2.mirrorLeftBigTop,mirrorLeftBig:icons$2.mirrorLeftBig,mirrorLeftBonnet:icons$2.mirrorLeftBonnet,mirrorLeftDefault:icons$2.mirrorLeftDefault,mirrorRightBigBottomWideAngle:icons$2.mirrorRightBigBottomWideAngle,mirrorRightBigTop:icons$2.mirrorRightBigTop,mirrorRightBig:icons$2.mirrorRightBig,mirrorRightBonnet:icons$2.mirrorRightBonnet,mirrorRightDefault:icons$2.mirrorRightDefault,mirrorRoundWideAngle:icons$2.mirrorRoundWideAngle,mirrorTopWideAngle:icons$2.mirrorTopWideAngle,odometerKM:icons$2.odometerKM,odometerMI:icons$2.odometerMI,odometer:icons$2.odometer,oilPressureIndicator:icons$2.oilPressureIndicator,parkingIndicator:icons$2.parkingIndicator,plusSet:icons$2.plusSet,positionLights:icons$2.positionLights,powerGauge01:icons$2.powerGauge01,powerGauge02:icons$2.powerGauge02,powerGauge03:icons$2.powerGauge03,powerGauge04:icons$2.powerGauge04,powerGauge05:icons$2.powerGauge05,rangeboxHi2:icons$2.rangeboxHi2,rangeboxHi4:icons$2.rangeboxHi4,rangeboxHiA:icons$2.rangeboxHiA,rangeboxLo2:icons$2.rangeboxLo2,rangeboxLo4:icons$2.rangeboxLo4,rangeboxLoA:icons$2.rangeboxLoA,rockCrawling01:icons$2.rockCrawling01,RWD:icons$2.RWD,semiTrailer:icons$2.semiTrailer,semiTruckCabover:icons$2.semiTruckCabover,semiTruckUS:icons$2.semiTruckUS,semiTruck:icons$2.semiTruck,smallTrailer:icons$2.smallTrailer,spoilerLift:icons$2.spoilerLift,strobeLights:icons$2.strobeLights,suspension01:icons$2.suspension01,suspension02:icons$2.suspension02,synchro01:icons$2.synchro01,synchro02:icons$2.synchro02,tankerTrailer:icons$2.tankerTrailer,taxiCar1:icons$2.taxiCar1,taxiCar3:icons$2.taxiCar3,taxiCarT:icons$2.taxiCarT,taxiCheckerLamp:icons$2.taxiCheckerLamp,tirePressureDecrease01:icons$2.tirePressureDecrease01,tirePressureDecrease02:icons$2.tirePressureDecrease02,tirePressureGaugeAlt01:icons$2.tirePressureGaugeAlt01,tirePressureGaugeAlt02:icons$2.tirePressureGaugeAlt02,tirePressureGaugeAlt03:icons$2.tirePressureGaugeAlt03,tirePressureGaugeOutlined01:icons$2.tirePressureGaugeOutlined01,tirePressureGaugeOutlined02:icons$2.tirePressureGaugeOutlined02,tirePressureGaugeOutlined03:icons$2.tirePressureGaugeOutlined03,tirePressureGaugeSolid01:icons$2.tirePressureGaugeSolid01,tirePressureGaugeSolid02:icons$2.tirePressureGaugeSolid02,tirePressureGaugeSolid03:icons$2.tirePressureGaugeSolid03,tirePressureIncrease01:icons$2.tirePressureIncrease01,tirePressureIncrease02:icons$2.tirePressureIncrease02,tirePressureStopLine:icons$2.tirePressureStopLine,tirePressureStopOctoLine:icons$2.tirePressureStopOctoLine,tirePressureStopOctoSolid:icons$2.tirePressureStopOctoSolid,tirePressureStopSolid:icons$2.tirePressureStopSolid,tow:icons$2.tow,tractionControl:icons$2.tractionControl,transmissionA:icons$2.transmissionA,transmissionM:icons$2.transmissionM,turbine:icons$2.turbine,vehicleDoorsClose:icons$2.vehicleDoorsClose,vehicleDoorsOpen:icons$2.vehicleDoorsOpen,vehicleDoors:icons$2.vehicleDoors,vehicleFeatures01:icons$2.vehicleFeatures01,vehicleFeatures02:icons$2.vehicleFeatures02,vehicleFeatures03:icons$2.vehicleFeatures03,vehicleHood:icons$2.vehicleHood,vehicleTrunk:icons$2.vehicleTrunk,wheelHubLocked01:icons$2.wheelHubLocked01,wheelHubUnlocked01:icons$2.wheelHubUnlocked01,wigwags:icons$2.wigwags,wrench:icons$2.wrench,accelerationKPH:icons$2.accelerationKPH,accelerationMPH:icons$2.accelerationMPH,boxTruckFast:icons$2.boxTruckFast,doorFrontCoins:icons$2.doorFrontCoins,doorFront:icons$2.doorFront,engineCoins:icons$2.engineCoins,exhaustMufflerCoins:icons$2.exhaustMufflerCoins,exhaustMuffler:icons$2.exhaustMuffler,headlightCoins:icons$2.headlightCoins,headlight:icons$2.headlight,tire3FourthCoins:icons$2.tire3FourthCoins,tire3Fourth:icons$2.tire3Fourth,turbineCoins:icons$2.turbineCoins,wheelDiscCoins:icons$2.wheelDiscCoins,wheelDisc:icons$2.wheelDisc,busTilted:icons$2.busTilted,jointLockedMultiple:icons$2.jointLockedMultiple,jointUnlockedMultiple:icons$2.jointUnlockedMultiple,airPuffRight1:icons$2.airPuffRight1,carClock:icons$2.carClock,carFast:icons$2.carFast,carNumber1:icons$2.carNumber1,carNumber2:icons$2.carNumber2,carNumber3:icons$2.carNumber3,carNumber4:icons$2.carNumber4,carNumber5:icons$2.carNumber5,carNumber6:icons$2.carNumber6,carNumber7:icons$2.carNumber7,carNumber8:icons$2.carNumber8,carNumber9:icons$2.carNumber9,carPlus:icons$2.carPlus,carsChange:icons$2.carsChange,carsFollow:icons$2.carsFollow,doorFrontDetached:icons$2.doorFrontDetached,hingeBroken:icons$2.hingeBroken,octagonBrick:icons$2.octagonBrick,octagon:icons$2.octagon,tireAirPuff:icons$2.tireAirPuff,tireDeflated:icons$2.tireDeflated,carSideOutlineLarge:icons$2.carSideOutlineLarge,carFastReverse:icons$2.carFastReverse,carsChase:icons$2.carsChase,carsFlee:icons$2.carsFlee,hammerParticles:icons$2.hammerParticles,rangeboxHi:icons$2.rangeboxHi,rangeboxLo:icons$2.rangeboxLo,carsWrench:icons$2.carsWrench,jointCycleMultiple:icons$2.jointCycleMultiple,jointCycle:icons$2.jointCycle,intakeTrumpets:icons$2.intakeTrumpets,transmissionCvt:icons$2.transmissionCvt,auxUpDown:icons$2.auxUpDown,bucketArmUpDown:icons$2.bucketArmUpDown,bucketTilt:icons$2.bucketTilt,bucketArmDown:icons$2.bucketArmDown,bucketArmLevel:icons$2.bucketArmLevel,bucketArmUp:icons$2.bucketArmUp,bucketTiltDown:icons$2.bucketTiltDown,bucketTiltLevel:icons$2.bucketTiltLevel,bucketTiltUp:icons$2.bucketTiltUp,dumpBedDown:icons$2.dumpBedDown,dumpBedUpDown:icons$2.dumpBedUpDown,dumpBedUp:icons$2.dumpBedUp},features:{"4WD":icons$2[`4WD`],ABSIndicator:icons$2.ABSIndicator,AWD:icons$2.AWD,axleLift:icons$2.axleLift,axleCenter:icons$2.axleCenter,axleFront:icons$2.axleFront,axleRear:icons$2.axleRear,carCoin:icons$2.carCoin,carCoins:icons$2.carCoins,carDealer:icons$2.carDealer,carStarred:icons$2.carStarred,centrifugalClutchLocked03:icons$2.centrifugalClutchLocked03,centrifugalClutchUnlocked03:icons$2.centrifugalClutchUnlocked03,cogDamaged:icons$2.cogDamaged,cogsDamaged:icons$2.cogsDamaged,cogs:icons$2.cogs,coolantTemp:icons$2.coolantTemp,cruiseDisable:icons$2.cruiseDisable,cruiseEnable:icons$2.cruiseEnable,DCBattery:icons$2.DCBattery,differentialFrontDefault:icons$2.differentialFrontDefault,differentialFrontLocked:icons$2.differentialFrontLocked,differentialMiddleDefault:icons$2.differentialMiddleDefault,differentialMiddleLocked:icons$2.differentialMiddleLocked,differentialRearDefault:icons$2.differentialRearDefault,differentialRearLocked:icons$2.differentialRearLocked,doorHandle:icons$2.doorHandle,drivetrainGeneric:icons$2.drivetrainGeneric,drivetrainSpecial:icons$2.drivetrainSpecial,engine:icons$2.engine,ESCOff:icons$2.ESCOff,ESCOn:icons$2.ESCOn,ESC:icons$2.ESC,exhaustValve:icons$2.exhaustValve,fogLight:icons$2.fogLight,FWD:icons$2.FWD,garage01:icons$2.garage01,garage02:icons$2.garage02,garage03:icons$2.garage03,hazardLights:icons$2.hazardLights,highBeam:icons$2.highBeam,hydroPump1:icons$2.hydroPump1,hydroPump2:icons$2.hydroPump2,hydroPump3:icons$2.hydroPump3,hydroPump4:icons$2.hydroPump4,hydroPump5:icons$2.hydroPump5,hydroPump6:icons$2.hydroPump6,hydroPump7:icons$2.hydroPump7,jointLocked:icons$2.jointLocked,jointUnlocked:icons$2.jointUnlocked,keys1:icons$2.keys1,keys2:icons$2.keys2,limiterEnable:icons$2.limiterEnable,lowBeam:icons$2.lowBeam,minusRes:icons$2.minusRes,mirrorInteriorMiddle:icons$2.mirrorInteriorMiddle,mirrorLeftBigBottomWideAngle:icons$2.mirrorLeftBigBottomWideAngle,mirrorLeftBigTop:icons$2.mirrorLeftBigTop,mirrorLeftBig:icons$2.mirrorLeftBig,mirrorLeftBonnet:icons$2.mirrorLeftBonnet,mirrorLeftDefault:icons$2.mirrorLeftDefault,mirrorRightBigBottomWideAngle:icons$2.mirrorRightBigBottomWideAngle,mirrorRightBigTop:icons$2.mirrorRightBigTop,mirrorRightBig:icons$2.mirrorRightBig,mirrorRightBonnet:icons$2.mirrorRightBonnet,mirrorRightDefault:icons$2.mirrorRightDefault,mirrorRoundWideAngle:icons$2.mirrorRoundWideAngle,mirrorTopWideAngle:icons$2.mirrorTopWideAngle,odometerKM:icons$2.odometerKM,odometerMI:icons$2.odometerMI,odometer:icons$2.odometer,oilPressureIndicator:icons$2.oilPressureIndicator,parkingIndicator:icons$2.parkingIndicator,plusGarage1:icons$2.plusGarage1,plusGarage2:icons$2.plusGarage2,plusGarage3:icons$2.plusGarage3,plusGarage4:icons$2.plusGarage4,plusSet:icons$2.plusSet,positionLights:icons$2.positionLights,powerGauge01:icons$2.powerGauge01,powerGauge02:icons$2.powerGauge02,powerGauge03:icons$2.powerGauge03,powerGauge04:icons$2.powerGauge04,powerGauge05:icons$2.powerGauge05,rangeboxHi2:icons$2.rangeboxHi2,rangeboxHi4:icons$2.rangeboxHi4,rangeboxHiA:icons$2.rangeboxHiA,rangeboxLo2:icons$2.rangeboxLo2,rangeboxLo4:icons$2.rangeboxLo4,rangeboxLoA:icons$2.rangeboxLoA,RWD:icons$2.RWD,spoilerLift:icons$2.spoilerLift,strobeLights:icons$2.strobeLights,suspension01:icons$2.suspension01,suspension02:icons$2.suspension02,synchro01:icons$2.synchro01,synchro02:icons$2.synchro02,tirePressureDecrease01:icons$2.tirePressureDecrease01,tirePressureDecrease02:icons$2.tirePressureDecrease02,tirePressureGaugeAlt01:icons$2.tirePressureGaugeAlt01,tirePressureGaugeAlt02:icons$2.tirePressureGaugeAlt02,tirePressureGaugeAlt03:icons$2.tirePressureGaugeAlt03,tirePressureGaugeOutlined01:icons$2.tirePressureGaugeOutlined01,tirePressureGaugeOutlined02:icons$2.tirePressureGaugeOutlined02,tirePressureGaugeOutlined03:icons$2.tirePressureGaugeOutlined03,tirePressureGaugeSolid01:icons$2.tirePressureGaugeSolid01,tirePressureGaugeSolid02:icons$2.tirePressureGaugeSolid02,tirePressureGaugeSolid03:icons$2.tirePressureGaugeSolid03,tirePressureIncrease01:icons$2.tirePressureIncrease01,tirePressureIncrease02:icons$2.tirePressureIncrease02,tirePressureStopLine:icons$2.tirePressureStopLine,tirePressureStopOctoLine:icons$2.tirePressureStopOctoLine,tirePressureStopOctoSolid:icons$2.tirePressureStopOctoSolid,tirePressureStopSolid:icons$2.tirePressureStopSolid,tractionControl:icons$2.tractionControl,transmissionA:icons$2.transmissionA,transmissionM:icons$2.transmissionM,turbine:icons$2.turbine,vehicleDoorsClose:icons$2.vehicleDoorsClose,vehicleDoorsOpen:icons$2.vehicleDoorsOpen,vehicleDoors:icons$2.vehicleDoors,vehicleFeatures01:icons$2.vehicleFeatures01,vehicleFeatures02:icons$2.vehicleFeatures02,vehicleFeatures03:icons$2.vehicleFeatures03,vehicleHood:icons$2.vehicleHood,vehicleTrunk:icons$2.vehicleTrunk,wheelHubLocked01:icons$2.wheelHubLocked01,wheelHubUnlocked01:icons$2.wheelHubUnlocked01,wigwags:icons$2.wigwags,wrench:icons$2.wrench,accelerationKPH:icons$2.accelerationKPH,accelerationMPH:icons$2.accelerationMPH,doorFrontCoins:icons$2.doorFrontCoins,doorFront:icons$2.doorFront,engineCoins:icons$2.engineCoins,exhaustMufflerCoins:icons$2.exhaustMufflerCoins,exhaustMuffler:icons$2.exhaustMuffler,headlightCoins:icons$2.headlightCoins,headlight:icons$2.headlight,tire3FourthCoins:icons$2.tire3FourthCoins,tire3Fourth:icons$2.tire3Fourth,turbineCoins:icons$2.turbineCoins,wheelDiscCoins:icons$2.wheelDiscCoins,wheelDisc:icons$2.wheelDisc,jointLockedMultiple:icons$2.jointLockedMultiple,jointUnlockedMultiple:icons$2.jointUnlockedMultiple,bridge:icons$2.bridge,bump:icons$2.bump,bumps:icons$2.bumps,caution:icons$2.caution,crest:icons$2.crest,doubleCaution:icons$2.doubleCaution,finish:icons$2.finish,jumpOverBump:icons$2.jumpOverBump,narrows:icons$2.narrows,pothole:icons$2.pothole,turn1:icons$2.turn1,turn2:icons$2.turn2,turn3:icons$2.turn3,turn4:icons$2.turn4,turn5:icons$2.turn5,turn6:icons$2.turn6,turnHp:icons$2.turnHp,turnSq:icons$2.turnSq,water:icons$2.water,carsFollow:icons$2.carsFollow,doorFrontDetached:icons$2.doorFrontDetached,garageNumber1:icons$2.garageNumber1,garageNumber2:icons$2.garageNumber2,garageNumber3:icons$2.garageNumber3,garageNumber4:icons$2.garageNumber4,garageNumber5:icons$2.garageNumber5,garageNumber6:icons$2.garageNumber6,garageNumber7:icons$2.garageNumber7,garageNumber8:icons$2.garageNumber8,garageNumber9:icons$2.garageNumber9,hingeBroken:icons$2.hingeBroken,houseWrenchRoof:icons$2.houseWrenchRoof,houseWrench:icons$2.houseWrench,tripleCaution:icons$2.tripleCaution,carsChase:icons$2.carsChase,carsFlee:icons$2.carsFlee,hammerParticles:icons$2.hammerParticles,rangeboxHi:icons$2.rangeboxHi,rangeboxLo:icons$2.rangeboxLo,jointCycleMultiple:icons$2.jointCycleMultiple,jointCycle:icons$2.jointCycle,intakeTrumpets:icons$2.intakeTrumpets,transmissionCvt:icons$2.transmissionCvt,house:icons$2.house,auxUpDown:icons$2.auxUpDown,bucketArmUpDown:icons$2.bucketArmUpDown,bucketTilt:icons$2.bucketTilt,bucketArmDown:icons$2.bucketArmDown,bucketArmLevel:icons$2.bucketArmLevel,bucketArmUp:icons$2.bucketArmUp,bucketTiltDown:icons$2.bucketTiltDown,bucketTiltLevel:icons$2.bucketTiltLevel,bucketTiltUp:icons$2.bucketTiltUp,dumpBedDown:icons$2.dumpBedDown,dumpBedUpDown:icons$2.dumpBedUpDown,dumpBedUp:icons$2.dumpBedUp},generic:{"9dividedby10":icons$2[`9dividedby10`],abandon:icons$2.abandon,addItemPolygon:icons$2.addItemPolygon,addListItem:icons$2.addListItem,addPolygonVertex:icons$2.addPolygonVertex,adjust:icons$2.adjust,AIMicrochip:icons$2.AIMicrochip,aperture:icons$2.aperture,autobahn:icons$2.autobahn,bSpline:icons$2.bSpline,beamCrashBarrier1:icons$2.beamCrashBarrier1,beamCrashBarrier2:icons$2.beamCrashBarrier2,beamCrashBarrier3:icons$2.beamCrashBarrier3,beamNG:icons$2.beamNG,bezierPath1:icons$2.bezierPath1,bezierPath2:icons$2.bezierPath2,bicycle1:icons$2.bicycle1,bicycle2:icons$2.bicycle2,BNGFolder:icons$2.BNGFolder,BNGMicrochip:icons$2.BNGMicrochip,bollard:icons$2.bollard,bookmark:icons$2.bookmark,booleanIntersect:icons$2.booleanIntersect,broom:icons$2.broom,bucketAdd:icons$2.bucketAdd,bucketSubtract:icons$2.bucketSubtract,bug:icons$2.bug,bulldozer:icons$2.bulldozer,carChase01:icons$2.carChase01,carCrash:icons$2.carCrash,carOffroadOutlineRear:icons$2.carOffroadOutlineRear,carOffroadOutlineSide:icons$2.carOffroadOutlineSide,carOffroadRear:icons$2.carOffroadRear,carOffroadSide:icons$2.carOffroadSide,carSensors:icons$2.carSensors,carToWheels:icons$2.carToWheels,carUp:icons$2.carUp,carWithLidar:icons$2.carWithLidar,car:icons$2.car,cardboardBox:icons$2.cardboardBox,carsChase02:icons$2.carsChase02,cars:icons$2.cars,catalog01:icons$2.catalog01,catalog02:icons$2.catalog02,catalog03:icons$2.catalog03,chartBars:icons$2.chartBars,checkmarkBold:icons$2.checkmarkBold,checkmark:icons$2.checkmark,circuitMicrochip:icons$2.circuitMicrochip,clapperboard:icons$2.clapperboard,code:icons$2.code,concreteRoadBlock:icons$2.concreteRoadBlock,copy:icons$2.copy,crossroads1:icons$2.crossroads1,crossroads2:icons$2.crossroads2,cup:icons$2.cup,dataExchange:icons$2.dataExchange,decalRoad:icons$2.decalRoad,decal:icons$2.decal,deform:icons$2.deform,doorIn:icons$2.doorIn,editCheckmark:icons$2.editCheckmark,edit:icons$2.edit,exit:icons$2.exit,export:icons$2.export,eyeOutlineClosed:icons$2.eyeOutlineClosed,eyeOutlineOpened:icons$2.eyeOutlineOpened,eyeSolidClosed:icons$2.eyeSolidClosed,eyeSolidOpened:icons$2.eyeSolidOpened,eyeWaves:icons$2.eyeWaves,facility02:icons$2.facility02,filter:icons$2.filter,flatBulbBeam:icons$2.flatBulbBeam,floppyDisk:icons$2.floppyDisk,folder:icons$2.folder,FPS:icons$2.FPS,frontAxleMidpoint:icons$2.frontAxleMidpoint,frontBumperMidpoint:icons$2.frontBumperMidpoint,globe:icons$2.globe,GPSMark:icons$2.GPSMark,GPSSolid:icons$2.GPSSolid,group:icons$2.group,gyroscopeMicrochip:icons$2.gyroscopeMicrochip,gyroscope:icons$2.gyroscope,helmets:icons$2.helmets,help:icons$2.help,HUD:icons$2.HUD,import:icons$2.import,infinity:icons$2.infinity,info:icons$2.info,lampPost1:icons$2.lampPost1,lampPost2:icons$2.lampPost2,lampPost3:icons$2.lampPost3,laneProperties:icons$2.laneProperties,language:icons$2.language,laptop:icons$2.laptop,lidarPatternFullArcHighFreq:icons$2.lidarPatternFullArcHighFreq,lidarPatternFullArcMidFreq:icons$2.lidarPatternFullArcMidFreq,lidarPatternNarrowArc:icons$2.lidarPatternNarrowArc,lidar:icons$2.lidar,lightrunner:icons$2.lightrunner,lineToTerrain:icons$2.lineToTerrain,link2:icons$2.link2,link:icons$2.link,listBig:icons$2.listBig,listIndented:icons$2.listIndented,listSmall:icons$2.listSmall,location1:icons$2.location1,location2:icons$2.location2,lockClosed:icons$2.lockClosed,lockOpened:icons$2.lockOpened,longRangeBeam1:icons$2.longRangeBeam1,longRangeBeam2:icons$2.longRangeBeam2,magnetOnSurface:icons$2.magnetOnSurface,mapWithEmitter:icons$2.mapWithEmitter,mapPoint:icons$2.mapPoint,material:icons$2.material,mathDivide:icons$2.mathDivide,mathGreaterOrEqualThan:icons$2.mathGreaterOrEqualThan,mathGreaterThan:icons$2.mathGreaterThan,mathLessOrEqualThan:icons$2.mathLessOrEqualThan,mathLessThan:icons$2.mathLessThan,mathMinus:icons$2.mathMinus,mathMultiply:icons$2.mathMultiply,mathPlus:icons$2.mathPlus,medal:icons$2.medal,meshFence:icons$2.meshFence,meshRoad:icons$2.meshRoad,midRangeBeam1:icons$2.midRangeBeam1,midRangeBeam2:icons$2.midRangeBeam2,minus:icons$2.minus,move02:icons$2.move02,move:icons$2.move,nodeAddFirst01:icons$2.nodeAddFirst01,nodeAddFirst02:icons$2.nodeAddFirst02,nodeAddLast02:icons$2.nodeAddLast02,nodeAddMiddle01:icons$2.nodeAddMiddle01,nodeAddMiddle02:icons$2.nodeAddMiddle02,nodeAdd:icons$2.nodeAdd,nodeLast01:icons$2.nodeLast01,nodeRemove:icons$2.nodeRemove,order:icons$2.order,organization:icons$2.organization,paperKnife:icons$2.paperKnife,pathArc:icons$2.pathArc,pathLine:icons$2.pathLine,pathSpiral:icons$2.pathSpiral,personSolid:icons$2.personSolid,person:icons$2.person,photo:icons$2.photo,placeholder:icons$2.placeholder,plus:icons$2.plus,powerOnOff:icons$2.powerOnOff,publisher:icons$2.publisher,puzzleModule:icons$2.puzzleModule,radarIdeal:icons$2.radarIdeal,radarRoundIdeal:icons$2.radarRoundIdeal,radarRound:icons$2.radarRound,radar:icons$2.radar,rearAxleMidpoint:icons$2.rearAxleMidpoint,rearBumperMidpoint:icons$2.rearBumperMidpoint,reconfigure:icons$2.reconfigure,redo:icons$2.redo,reflectNot:icons$2.reflectNot,reflect:icons$2.reflect,rename:icons$2.rename,replay:icons$2.replay,restart:icons$2.restart,roadDividerLinesDecal:icons$2.roadDividerLinesDecal,roadEdgeLineDecal:icons$2.roadEdgeLineDecal,roadEndLineDecal:icons$2.roadEndLineDecal,roadFace:icons$2.roadFace,roadInfo:icons$2.roadInfo,roadMarkingOutline:icons$2.roadMarkingOutline,roadMarkingSolid:icons$2.roadMarkingSolid,roadOutline:icons$2.roadOutline,roadRefPathDecal:icons$2.roadRefPathDecal,roadRefPath:icons$2.roadRefPath,roadStartLineDecal:icons$2.roadStartLineDecal,road:icons$2.road,runScript:icons$2.runScript,saveAs1:icons$2.saveAs1,scan:icons$2.scan,search:icons$2.search,shortRangeBeam1:icons$2.shortRangeBeam1,shortRangeBeam2:icons$2.shortRangeBeam2,signal01a:icons$2.signal01a,signal02a:icons$2.signal02a,signal03a:icons$2.signal03a,signal04a:icons$2.signal04a,signal05a:icons$2.signal05a,slashLeft:icons$2.slashLeft,slashRight:icons$2.slashRight,snowflake:icons$2.snowflake,soundFadeOut:icons$2.soundFadeOut,soundLimit:icons$2.soundLimit,soundLoud:icons$2.soundLoud,soundMonoL:icons$2.soundMonoL,soundMonoR:icons$2.soundMonoR,soundOff:icons$2.soundOff,soundQuiet:icons$2.soundQuiet,soundStereo:icons$2.soundStereo,soundWave01:icons$2.soundWave01,soundWave02:icons$2.soundWave02,sphereOnPathNumber:icons$2.sphereOnPathNumber,sphereOnPath:icons$2.sphereOnPath,sphericalBeam:icons$2.sphericalBeam,sprayCan:icons$2.sprayCan,star:icons$2.star,starSecondary:icons$2.starSecondary,stopwatchArrows01:icons$2.stopwatchArrows01,stopwatchArrows02:icons$2.stopwatchArrows02,stopwatchSectionOutlinedEnd:icons$2.stopwatchSectionOutlinedEnd,stopwatchSectionOutlinedStart:icons$2.stopwatchSectionOutlinedStart,stopwatchSectionSolidEnd:icons$2.stopwatchSectionSolidEnd,stopwatchSectionSolidStart:icons$2.stopwatchSectionSolidStart,survellianceCamera:icons$2.survellianceCamera,switchBlock:icons$2.switchBlock,switchOutline:icons$2.switchOutline,sync:icons$2.sync,taxiCar1:icons$2.taxiCar1,taxiCar3:icons$2.taxiCar3,taxiCarT:icons$2.taxiCarT,taxiCheckerLamp:icons$2.taxiCheckerLamp,terrainToLine:icons$2.terrainToLine,terrain:icons$2.terrain,thinBulbBeam:icons$2.thinBulbBeam,thinnerBulbBeam:icons$2.thinnerBulbBeam,tiles:icons$2.tiles,timer:icons$2.timer,toCOMWithWheels:icons$2.toCOMWithWheels,toCOM:icons$2.toCOM,tow:icons$2.tow,transform:icons$2.transform,transparencyMask:icons$2.transparencyMask,trashBin2:icons$2.trashBin2,triangleBeam:icons$2.triangleBeam,trim:icons$2.trim,tulipBeam:icons$2.tulipBeam,tunnel:icons$2.tunnel,twoRoadsAdd:icons$2.twoRoadsAdd,twoRoadsCrossAdd:icons$2.twoRoadsCrossAdd,twoRoadsLink:icons$2.twoRoadsLink,undo:icons$2.undo,ungroup:icons$2.ungroup,unlink:icons$2.unlink,view:icons$2.view,voucherDiagonal1:icons$2.voucherDiagonal1,voucherDiagonal2:icons$2.voucherDiagonal2,voucherDiagonal3:icons$2.voucherDiagonal3,voucherHorizontal1:icons$2.voucherHorizontal1,voucherHorizontal2:icons$2.voucherHorizontal2,voucherHorizontal3:icons$2.voucherHorizontal3,wavesSignalReceived:icons$2.wavesSignalReceived,wavesSignalSentLeft:icons$2.wavesSignalSentLeft,wavesSignalSentRight:icons$2.wavesSignalSentRight,weight:icons$2.weight,wrench:icons$2.wrench,danger:icons$2.danger,droplet:icons$2.droplet,envelope:icons$2.envelope,fireDiamond:icons$2.fireDiamond,xmark:icons$2.xmark,scale:icons$2.scale,locationDestination:icons$2.locationDestination,locationSource:icons$2.locationSource,colorBrightnessSun:icons$2.colorBrightnessSun,colorCirclePalette:icons$2.colorCirclePalette,colorPalette:icons$2.colorPalette,colorSaturation:icons$2.colorSaturation,sortAscDown02:icons$2.sortAscDown02,sortAscDown:icons$2.sortAscDown,sortAscUp02:icons$2.sortAscUp02,sortAscUp:icons$2.sortAscUp,sortDescDown02:icons$2.sortDescDown02,sortDescDown:icons$2.sortDescDown,sortDescUp02:icons$2.sortDescUp02,sortDescUp:icons$2.sortDescUp,cardboardBoxCoins:icons$2.cardboardBoxCoins,lasso:icons$2.lasso,materialGlossy:icons$2.materialGlossy,materialMetal:icons$2.materialMetal,materialRoughness:icons$2.materialRoughness,materialTransparency01:icons$2.materialTransparency01,materialTransparency02:icons$2.materialTransparency02,metal01:icons$2.metal01,removeItemPolygon:icons$2.removeItemPolygon,removeListItem:icons$2.removeListItem,sortAsc:icons$2.sortAsc,sortDesc:icons$2.sortDesc,surfaceRoughness02:icons$2.surfaceRoughness02,shieldCheckmark:icons$2.shieldCheckmark,shieldHandCheckmark:icons$2.shieldHandCheckmark,shieldHandPlus:icons$2.shieldHandPlus,bridgeWithRiver:icons$2.bridgeWithRiver,gizmosOutline:icons$2.gizmosOutline,gizmosSolid:icons$2.gizmosSolid,highwayRoad3To2Merge01:icons$2.highwayRoad3To2Merge01,highwayRoad3To2Merge02:icons$2.highwayRoad3To2Merge02,highwayToUrbanRoadTransition01:icons$2.highwayToUrbanRoadTransition01,highwayToUrbanRoadTransition02:icons$2.highwayToUrbanRoadTransition02,pedestrianCrossing01:icons$2.pedestrianCrossing01,polygonalCube:icons$2.polygonalCube,roadEditOutline:icons$2.roadEditOutline,roadEditSolid:icons$2.roadEditSolid,roadFolderPlus:icons$2.roadFolderPlus,roadFolder:icons$2.roadFolder,roadGuideArrowOutline:icons$2.roadGuideArrowOutline,roadGuideArrowSolid:icons$2.roadGuideArrowSolid,roadOutlineMesh:icons$2.roadOutlineMesh,roadPedestrianCrossing02:icons$2.roadPedestrianCrossing02,roadProfileWithCheckmark:icons$2.roadProfileWithCheckmark,roadProfile:icons$2.roadProfile,roadRoundaboutJunction:icons$2.roadRoundaboutJunction,roadSidewalkTransition:icons$2.roadSidewalkTransition,roadStackPlus:icons$2.roadStackPlus,roadStack:icons$2.roadStack,roadTJunction:icons$2.roadTJunction,roadXJunction:icons$2.roadXJunction,roadYJunction:icons$2.roadYJunction,shoppingCart:icons$2.shoppingCart,singleLineToTerrain:icons$2.singleLineToTerrain,sphereOnMesh:icons$2.sphereOnMesh,twoLinesToTerrain:icons$2.twoLinesToTerrain,urbanRoad3To2Merge01:icons$2.urbanRoad3To2Merge01,urbanRoad3To2Merge02:icons$2.urbanRoad3To2Merge02,urbanRoadToHighwayTransition01:icons$2.urbanRoadToHighwayTransition01,urbanRoadToHighwayTransition02:icons$2.urbanRoadToHighwayTransition02,floppyDiskPlus:icons$2.floppyDiskPlus,highwayMerge:icons$2.highwayMerge,highwaySeparate:icons$2.highwaySeparate,highwayShoulderMerge:icons$2.highwayShoulderMerge,terrainToSingleLine:icons$2.terrainToSingleLine,terrainToTwoLines:icons$2.terrainToTwoLines,urbanRoadMerge:icons$2.urbanRoadMerge,urbanRoadSeparate:icons$2.urbanRoadSeparate,urbanShoulderMerge:icons$2.urbanShoulderMerge,BNGChat:icons$2.BNGChat,chatBubble:icons$2.chatBubble,cameraFarClip:icons$2.cameraFarClip,cameraNearClip:icons$2.cameraNearClip,explosion:icons$2.explosion,fireExtinguisher:icons$2.fireExtinguisher,fire:icons$2.fire,toggleOff:icons$2.toggleOff,toggleOn:icons$2.toggleOn,viewFarClip:icons$2.viewFarClip,viewNearClip:icons$2.viewNearClip,circleSlashed:icons$2.circleSlashed,scissorsSlashed:icons$2.scissorsSlashed,scissors:icons$2.scissors,airPuffRight1:icons$2.airPuffRight1,airPuffUp1:icons$2.airPuffUp1,arrowsReplace:icons$2.arrowsReplace,arrowsShuffle:icons$2.arrowsShuffle,arrowsSwitch:icons$2.arrowsSwitch,carClock:icons$2.carClock,carNumber1:icons$2.carNumber1,carNumber2:icons$2.carNumber2,carNumber3:icons$2.carNumber3,carNumber4:icons$2.carNumber4,carNumber5:icons$2.carNumber5,carNumber6:icons$2.carNumber6,carNumber7:icons$2.carNumber7,carNumber8:icons$2.carNumber8,carNumber9:icons$2.carNumber9,carPlus:icons$2.carPlus,loadMesh:icons$2.loadMesh,octagonBrick:icons$2.octagonBrick,octagon:icons$2.octagon,saveMesh:icons$2.saveMesh,trafficLight:icons$2.trafficLight,enter:icons$2.enter,pedestrianRunning:icons$2.pedestrianRunning,pedestrianStanding:icons$2.pedestrianStanding,seatArrowIn:icons$2.seatArrowIn,seatArrowOut:icons$2.seatArrowOut,seatVArrowIn:icons$2.seatVArrowIn,seatVArrowOut:icons$2.seatVArrowOut,vehicleArrowIn:icons$2.vehicleArrowIn,vehicleArrowOut:icons$2.vehicleArrowOut,leverFrontOperate:icons$2.leverFrontOperate,leverSideDown:icons$2.leverSideDown,leverSideOperate:icons$2.leverSideOperate,leverSideUp:icons$2.leverSideUp,medalEmpty:icons$2.medalEmpty,medalStar:icons$2.medalStar,seatArrowInLeft:icons$2.seatArrowInLeft,seatArrowOutLeft:icons$2.seatArrowOutLeft,seatVArrowInLeft:icons$2.seatVArrowInLeft,seatVArrowOutLeft:icons$2.seatVArrowOutLeft,badgeRoundEmpty:icons$2.badgeRoundEmpty,badgeRoundStar:icons$2.badgeRoundStar,badgeRound:icons$2.badgeRound,badge:icons$2.badge,beamCurrencyOutlineLarge:icons$2.beamCurrencyOutlineLarge,carSideOutlineLarge:icons$2.carSideOutlineLarge,flagOutlineLarge:icons$2.flagOutlineLarge,terrainOutlineLarge:icons$2.terrainOutlineLarge,rallyHelmet3To4:icons$2.rallyHelmet3To4,rallyHelmet:icons$2.rallyHelmet,test:icons$2.test,globeSimpleNotSign:icons$2.globeSimpleNotSign,globeSimplified:icons$2.globeSimplified,radialMenu:icons$2.radialMenu,branch:icons$2.branch,NA:icons$2.NA,magicWand:icons$2.magicWand,dice24:icons$2.dice24,diceD6:icons$2.diceD6,xmarkBold:icons$2.xmarkBold,house:icons$2.house,picture:icons$2.picture,shieldCheckmarkProgressbar:icons$2.shieldCheckmarkProgressbar},warning:{ABSIndicator:icons$2.ABSIndicator,DCBattery:icons$2.DCBattery,oilPressureIndicator:icons$2.oilPressureIndicator,parkingIndicator:icons$2.parkingIndicator},internals:{ABSIndicator:icons$2.ABSIndicator,DCBattery:icons$2.DCBattery,oilPressureIndicator:icons$2.oilPressureIndicator,parkingIndicator:icons$2.parkingIndicator},we:{addItemPolygon:icons$2.addItemPolygon,addListItem:icons$2.addListItem,addPolygonVertex:icons$2.addPolygonVertex,bSpline:icons$2.bSpline,beamCrashBarrier1:icons$2.beamCrashBarrier1,beamCrashBarrier2:icons$2.beamCrashBarrier2,beamCrashBarrier3:icons$2.beamCrashBarrier3,bezierPath1:icons$2.bezierPath1,bezierPath2:icons$2.bezierPath2,bicycle1:icons$2.bicycle1,bicycle2:icons$2.bicycle2,bollard:icons$2.bollard,bulldozer:icons$2.bulldozer,concreteRoadBlock:icons$2.concreteRoadBlock,crossroads1:icons$2.crossroads1,crossroads2:icons$2.crossroads2,decalRoad:icons$2.decalRoad,flatBulbBeam:icons$2.flatBulbBeam,frontAxleMidpoint:icons$2.frontAxleMidpoint,frontBumperMidpoint:icons$2.frontBumperMidpoint,lampPost1:icons$2.lampPost1,lampPost2:icons$2.lampPost2,lampPost3:icons$2.lampPost3,laneProperties:icons$2.laneProperties,lidarPatternFullArcHighFreq:icons$2.lidarPatternFullArcHighFreq,lidarPatternFullArcMidFreq:icons$2.lidarPatternFullArcMidFreq,lidarPatternNarrowArc:icons$2.lidarPatternNarrowArc,lineToTerrain:icons$2.lineToTerrain,longRangeBeam1:icons$2.longRangeBeam1,longRangeBeam2:icons$2.longRangeBeam2,magnetOnSurface:icons$2.magnetOnSurface,meshFence:icons$2.meshFence,meshRoad:icons$2.meshRoad,midRangeBeam1:icons$2.midRangeBeam1,midRangeBeam2:icons$2.midRangeBeam2,pathArc:icons$2.pathArc,pathLine:icons$2.pathLine,pathSpiral:icons$2.pathSpiral,rearAxleMidpoint:icons$2.rearAxleMidpoint,rearBumperMidpoint:icons$2.rearBumperMidpoint,roadDividerLinesDecal:icons$2.roadDividerLinesDecal,roadEdgeLineDecal:icons$2.roadEdgeLineDecal,roadEndLineDecal:icons$2.roadEndLineDecal,roadFace:icons$2.roadFace,roadMarkingOutline:icons$2.roadMarkingOutline,roadMarkingSolid:icons$2.roadMarkingSolid,roadOutline:icons$2.roadOutline,roadRefPathDecal:icons$2.roadRefPathDecal,roadRefPath:icons$2.roadRefPath,roadStartLineDecal:icons$2.roadStartLineDecal,shortRangeBeam1:icons$2.shortRangeBeam1,shortRangeBeam2:icons$2.shortRangeBeam2,sphereOnPathNumber:icons$2.sphereOnPathNumber,sphereOnPath:icons$2.sphereOnPath,sphericalBeam:icons$2.sphericalBeam,terrainToLine:icons$2.terrainToLine,thinBulbBeam:icons$2.thinBulbBeam,thinnerBulbBeam:icons$2.thinnerBulbBeam,toCOMWithWheels:icons$2.toCOMWithWheels,toCOM:icons$2.toCOM,triangleBeam:icons$2.triangleBeam,tulipBeam:icons$2.tulipBeam,tunnel:icons$2.tunnel,twoRoadsAdd:icons$2.twoRoadsAdd,twoRoadsCrossAdd:icons$2.twoRoadsCrossAdd,twoRoadsLink:icons$2.twoRoadsLink,lasso:icons$2.lasso,removeItemPolygon:icons$2.removeItemPolygon,removeListItem:icons$2.removeListItem,bridgeWithRiver:icons$2.bridgeWithRiver,gizmosOutline:icons$2.gizmosOutline,gizmosSolid:icons$2.gizmosSolid,highwayRoad3To2Merge01:icons$2.highwayRoad3To2Merge01,highwayRoad3To2Merge02:icons$2.highwayRoad3To2Merge02,highwayToUrbanRoadTransition01:icons$2.highwayToUrbanRoadTransition01,highwayToUrbanRoadTransition02:icons$2.highwayToUrbanRoadTransition02,pedestrianCrossing01:icons$2.pedestrianCrossing01,polygonalCube:icons$2.polygonalCube,roadEditOutline:icons$2.roadEditOutline,roadEditSolid:icons$2.roadEditSolid,roadFolderPlus:icons$2.roadFolderPlus,roadFolder:icons$2.roadFolder,roadGuideArrowOutline:icons$2.roadGuideArrowOutline,roadGuideArrowSolid:icons$2.roadGuideArrowSolid,roadOutlineMesh:icons$2.roadOutlineMesh,roadPedestrianCrossing02:icons$2.roadPedestrianCrossing02,roadProfileWithCheckmark:icons$2.roadProfileWithCheckmark,roadProfile:icons$2.roadProfile,roadRoundaboutJunction:icons$2.roadRoundaboutJunction,roadSidewalkTransition:icons$2.roadSidewalkTransition,roadStackPlus:icons$2.roadStackPlus,roadStack:icons$2.roadStack,roadTJunction:icons$2.roadTJunction,roadXJunction:icons$2.roadXJunction,roadYJunction:icons$2.roadYJunction,singleLineToTerrain:icons$2.singleLineToTerrain,sphereOnMesh:icons$2.sphereOnMesh,twoLinesToTerrain:icons$2.twoLinesToTerrain,urbanRoad3To2Merge01:icons$2.urbanRoad3To2Merge01,urbanRoad3To2Merge02:icons$2.urbanRoad3To2Merge02,urbanRoadToHighwayTransition01:icons$2.urbanRoadToHighwayTransition01,urbanRoadToHighwayTransition02:icons$2.urbanRoadToHighwayTransition02,highwayMerge:icons$2.highwayMerge,highwaySeparate:icons$2.highwaySeparate,highwayShoulderMerge:icons$2.highwayShoulderMerge,terrainToSingleLine:icons$2.terrainToSingleLine,terrainToTwoLines:icons$2.terrainToTwoLines,urbanRoadMerge:icons$2.urbanRoadMerge,urbanRoadSeparate:icons$2.urbanRoadSeparate,urbanShoulderMerge:icons$2.urbanShoulderMerge},"world editor":{addItemPolygon:icons$2.addItemPolygon,addListItem:icons$2.addListItem,addPolygonVertex:icons$2.addPolygonVertex,bSpline:icons$2.bSpline,beamCrashBarrier1:icons$2.beamCrashBarrier1,beamCrashBarrier2:icons$2.beamCrashBarrier2,beamCrashBarrier3:icons$2.beamCrashBarrier3,bezierPath1:icons$2.bezierPath1,bezierPath2:icons$2.bezierPath2,bicycle1:icons$2.bicycle1,bicycle2:icons$2.bicycle2,bollard:icons$2.bollard,bulldozer:icons$2.bulldozer,concreteRoadBlock:icons$2.concreteRoadBlock,crossroads1:icons$2.crossroads1,crossroads2:icons$2.crossroads2,decalRoad:icons$2.decalRoad,flatBulbBeam:icons$2.flatBulbBeam,frontAxleMidpoint:icons$2.frontAxleMidpoint,frontBumperMidpoint:icons$2.frontBumperMidpoint,lampPost1:icons$2.lampPost1,lampPost2:icons$2.lampPost2,lampPost3:icons$2.lampPost3,laneProperties:icons$2.laneProperties,lidarPatternFullArcHighFreq:icons$2.lidarPatternFullArcHighFreq,lidarPatternFullArcMidFreq:icons$2.lidarPatternFullArcMidFreq,lidarPatternNarrowArc:icons$2.lidarPatternNarrowArc,lineToTerrain:icons$2.lineToTerrain,longRangeBeam1:icons$2.longRangeBeam1,longRangeBeam2:icons$2.longRangeBeam2,magnetOnSurface:icons$2.magnetOnSurface,meshFence:icons$2.meshFence,meshRoad:icons$2.meshRoad,midRangeBeam1:icons$2.midRangeBeam1,midRangeBeam2:icons$2.midRangeBeam2,pathArc:icons$2.pathArc,pathLine:icons$2.pathLine,pathSpiral:icons$2.pathSpiral,rearAxleMidpoint:icons$2.rearAxleMidpoint,rearBumperMidpoint:icons$2.rearBumperMidpoint,roadDividerLinesDecal:icons$2.roadDividerLinesDecal,roadEdgeLineDecal:icons$2.roadEdgeLineDecal,roadEndLineDecal:icons$2.roadEndLineDecal,roadFace:icons$2.roadFace,roadMarkingOutline:icons$2.roadMarkingOutline,roadMarkingSolid:icons$2.roadMarkingSolid,roadOutline:icons$2.roadOutline,roadRefPathDecal:icons$2.roadRefPathDecal,roadRefPath:icons$2.roadRefPath,roadStartLineDecal:icons$2.roadStartLineDecal,shortRangeBeam1:icons$2.shortRangeBeam1,shortRangeBeam2:icons$2.shortRangeBeam2,sphereOnPathNumber:icons$2.sphereOnPathNumber,sphereOnPath:icons$2.sphereOnPath,sphericalBeam:icons$2.sphericalBeam,terrainToLine:icons$2.terrainToLine,thinBulbBeam:icons$2.thinBulbBeam,thinnerBulbBeam:icons$2.thinnerBulbBeam,toCOMWithWheels:icons$2.toCOMWithWheels,toCOM:icons$2.toCOM,triangleBeam:icons$2.triangleBeam,tulipBeam:icons$2.tulipBeam,tunnel:icons$2.tunnel,twoRoadsAdd:icons$2.twoRoadsAdd,twoRoadsCrossAdd:icons$2.twoRoadsCrossAdd,twoRoadsLink:icons$2.twoRoadsLink,lasso:icons$2.lasso,removeItemPolygon:icons$2.removeItemPolygon,removeListItem:icons$2.removeListItem,bridgeWithRiver:icons$2.bridgeWithRiver,gizmosOutline:icons$2.gizmosOutline,gizmosSolid:icons$2.gizmosSolid,highwayRoad3To2Merge01:icons$2.highwayRoad3To2Merge01,highwayRoad3To2Merge02:icons$2.highwayRoad3To2Merge02,highwayToUrbanRoadTransition01:icons$2.highwayToUrbanRoadTransition01,highwayToUrbanRoadTransition02:icons$2.highwayToUrbanRoadTransition02,pedestrianCrossing01:icons$2.pedestrianCrossing01,polygonalCube:icons$2.polygonalCube,roadEditOutline:icons$2.roadEditOutline,roadEditSolid:icons$2.roadEditSolid,roadFolderPlus:icons$2.roadFolderPlus,roadFolder:icons$2.roadFolder,roadGuideArrowOutline:icons$2.roadGuideArrowOutline,roadGuideArrowSolid:icons$2.roadGuideArrowSolid,roadOutlineMesh:icons$2.roadOutlineMesh,roadPedestrianCrossing02:icons$2.roadPedestrianCrossing02,roadProfileWithCheckmark:icons$2.roadProfileWithCheckmark,roadProfile:icons$2.roadProfile,roadRoundaboutJunction:icons$2.roadRoundaboutJunction,roadSidewalkTransition:icons$2.roadSidewalkTransition,roadStackPlus:icons$2.roadStackPlus,roadStack:icons$2.roadStack,roadTJunction:icons$2.roadTJunction,roadXJunction:icons$2.roadXJunction,roadYJunction:icons$2.roadYJunction,singleLineToTerrain:icons$2.singleLineToTerrain,sphereOnMesh:icons$2.sphereOnMesh,twoLinesToTerrain:icons$2.twoLinesToTerrain,urbanRoad3To2Merge01:icons$2.urbanRoad3To2Merge01,urbanRoad3To2Merge02:icons$2.urbanRoad3To2Merge02,urbanRoadToHighwayTransition01:icons$2.urbanRoadToHighwayTransition01,urbanRoadToHighwayTransition02:icons$2.urbanRoadToHighwayTransition02,highwayMerge:icons$2.highwayMerge,highwaySeparate:icons$2.highwaySeparate,highwayShoulderMerge:icons$2.highwayShoulderMerge,terrainToSingleLine:icons$2.terrainToSingleLine,terrainToTwoLines:icons$2.terrainToTwoLines,urbanRoadMerge:icons$2.urbanRoadMerge,urbanRoadSeparate:icons$2.urbanRoadSeparate,urbanShoulderMerge:icons$2.urbanShoulderMerge},"road tools":{addItemPolygon:icons$2.addItemPolygon,addListItem:icons$2.addListItem,addPolygonVertex:icons$2.addPolygonVertex,bSpline:icons$2.bSpline,beamCrashBarrier1:icons$2.beamCrashBarrier1,beamCrashBarrier2:icons$2.beamCrashBarrier2,beamCrashBarrier3:icons$2.beamCrashBarrier3,bezierPath1:icons$2.bezierPath1,bezierPath2:icons$2.bezierPath2,bicycle1:icons$2.bicycle1,bicycle2:icons$2.bicycle2,bollard:icons$2.bollard,bulldozer:icons$2.bulldozer,concreteRoadBlock:icons$2.concreteRoadBlock,crossroads1:icons$2.crossroads1,crossroads2:icons$2.crossroads2,decalRoad:icons$2.decalRoad,lampPost1:icons$2.lampPost1,lampPost2:icons$2.lampPost2,lampPost3:icons$2.lampPost3,laneProperties:icons$2.laneProperties,lineToTerrain:icons$2.lineToTerrain,magnetOnSurface:icons$2.magnetOnSurface,meshFence:icons$2.meshFence,meshRoad:icons$2.meshRoad,pathArc:icons$2.pathArc,pathLine:icons$2.pathLine,pathSpiral:icons$2.pathSpiral,roadDividerLinesDecal:icons$2.roadDividerLinesDecal,roadEdgeLineDecal:icons$2.roadEdgeLineDecal,roadEndLineDecal:icons$2.roadEndLineDecal,roadFace:icons$2.roadFace,roadMarkingSolid:icons$2.roadMarkingSolid,roadOutline:icons$2.roadOutline,roadRefPathDecal:icons$2.roadRefPathDecal,roadRefPath:icons$2.roadRefPath,roadStartLineDecal:icons$2.roadStartLineDecal,sphereOnPathNumber:icons$2.sphereOnPathNumber,sphereOnPath:icons$2.sphereOnPath,terrainToLine:icons$2.terrainToLine,tunnel:icons$2.tunnel,twoRoadsAdd:icons$2.twoRoadsAdd,twoRoadsCrossAdd:icons$2.twoRoadsCrossAdd,twoRoadsLink:icons$2.twoRoadsLink,removeItemPolygon:icons$2.removeItemPolygon,removeListItem:icons$2.removeListItem,bridgeWithRiver:icons$2.bridgeWithRiver,gizmosOutline:icons$2.gizmosOutline,gizmosSolid:icons$2.gizmosSolid,highwayRoad3To2Merge01:icons$2.highwayRoad3To2Merge01,highwayRoad3To2Merge02:icons$2.highwayRoad3To2Merge02,highwayToUrbanRoadTransition01:icons$2.highwayToUrbanRoadTransition01,highwayToUrbanRoadTransition02:icons$2.highwayToUrbanRoadTransition02,pedestrianCrossing01:icons$2.pedestrianCrossing01,polygonalCube:icons$2.polygonalCube,roadEditOutline:icons$2.roadEditOutline,roadEditSolid:icons$2.roadEditSolid,roadFolderPlus:icons$2.roadFolderPlus,roadFolder:icons$2.roadFolder,roadGuideArrowOutline:icons$2.roadGuideArrowOutline,roadGuideArrowSolid:icons$2.roadGuideArrowSolid,roadOutlineMesh:icons$2.roadOutlineMesh,roadPedestrianCrossing02:icons$2.roadPedestrianCrossing02,roadProfileWithCheckmark:icons$2.roadProfileWithCheckmark,roadProfile:icons$2.roadProfile,roadRoundaboutJunction:icons$2.roadRoundaboutJunction,roadSidewalkTransition:icons$2.roadSidewalkTransition,roadStackPlus:icons$2.roadStackPlus,roadStack:icons$2.roadStack,roadTJunction:icons$2.roadTJunction,roadXJunction:icons$2.roadXJunction,roadYJunction:icons$2.roadYJunction,singleLineToTerrain:icons$2.singleLineToTerrain,sphereOnMesh:icons$2.sphereOnMesh,twoLinesToTerrain:icons$2.twoLinesToTerrain,urbanRoad3To2Merge01:icons$2.urbanRoad3To2Merge01,urbanRoad3To2Merge02:icons$2.urbanRoad3To2Merge02,urbanRoadToHighwayTransition01:icons$2.urbanRoadToHighwayTransition01,urbanRoadToHighwayTransition02:icons$2.urbanRoadToHighwayTransition02,highwayMerge:icons$2.highwayMerge,highwaySeparate:icons$2.highwaySeparate,highwayShoulderMerge:icons$2.highwayShoulderMerge,terrainToSingleLine:icons$2.terrainToSingleLine,terrainToTwoLines:icons$2.terrainToTwoLines,urbanRoadMerge:icons$2.urbanRoadMerge,urbanRoadSeparate:icons$2.urbanRoadSeparate,urbanShoulderMerge:icons$2.urbanShoulderMerge},ai:{AIMicrochip:icons$2.AIMicrochip},microchip:{AIMicrochip:icons$2.AIMicrochip},poi:{AIRace:icons$2.AIRace,barrelKnocker01:icons$2.barrelKnocker01,barrelKnocker02:icons$2.barrelKnocker02,boxDropOff01:icons$2.boxDropOff01,boxDropOff02:icons$2.boxDropOff02,boxDropOff03:icons$2.boxDropOff03,boxPickUp01:icons$2.boxPickUp01,boxPickUp02:icons$2.boxPickUp02,boxPickUp03:icons$2.boxPickUp03,boxPickUpDropOff01:icons$2.boxPickUpDropOff01,boxPickUpDropOff02:icons$2.boxPickUpDropOff02,bus:icons$2.bus,cannon:icons$2.cannon,circuit:icons$2.circuit,deliveryTruckArrows:icons$2.deliveryTruckArrows,deliveryTruck:icons$2.deliveryTruck,drag01:icons$2.drag01,drag02:icons$2.drag02,drift01:icons$2.drift01,drift02:icons$2.drift02,evade:icons$2.evade,fastTravel:icons$2.fastTravel,flagNew:icons$2.flagNew,flag:icons$2.flag,gaugeEmpty:icons$2.gaugeEmpty,hypermiling:icons$2.hypermiling,jump:icons$2.jump,parking:icons$2.parking,raceFlag:icons$2.raceFlag,rockCrawling01:icons$2.rockCrawling01,rockCrawling02:icons$2.rockCrawling02,targetJump:icons$2.targetJump,toGarage:icons$2.toGarage,trashBin1:icons$2.trashBin1,circlePinBack:icons$2.circlePinBack,circlePinFront:icons$2.circlePinFront,markerRectanglePinBack:icons$2.markerRectanglePinBack,markerRectanglePinFront:icons$2.markerRectanglePinFront,markerTriangleBack:icons$2.markerTriangleBack,markerTriangleFront:icons$2.markerTriangleFront,busTilted:icons$2.busTilted,gaugeFull:icons$2.gaugeFull},camera:{aperture:icons$2.aperture,camera3Fourth1:icons$2.camera3Fourth1,cameraBack1:icons$2.cameraBack1,cameraFocusOnPath:icons$2.cameraFocusOnPath,cameraFocusOnVehicle1:icons$2.cameraFocusOnVehicle1,cameraFocusOnVehicle2:icons$2.cameraFocusOnVehicle2,cameraFocusTopDown:icons$2.cameraFocusTopDown,cameraFront1:icons$2.cameraFront1,cameraSideLeft:icons$2.cameraSideLeft,cameraSideLeft2:icons$2.cameraSideLeft2,cameraSideRight:icons$2.cameraSideRight,cameraSideRight2:icons$2.cameraSideRight2,cameraTop1:icons$2.cameraTop1,movieCamera:icons$2.movieCamera,pathAroundObstacle:icons$2.pathAroundObstacle,survellianceCamera:icons$2.survellianceCamera,pathDice:icons$2.pathDice},optical:{aperture:icons$2.aperture,survellianceCamera:icons$2.survellianceCamera},sensor:{aperture:icons$2.aperture,eyeWaves:icons$2.eyeWaves,flatBulbBeam:icons$2.flatBulbBeam,frontAxleMidpoint:icons$2.frontAxleMidpoint,frontBumperMidpoint:icons$2.frontBumperMidpoint,GPSMark:icons$2.GPSMark,GPSSolid:icons$2.GPSSolid,gyroscopeMicrochip:icons$2.gyroscopeMicrochip,gyroscope:icons$2.gyroscope,lidarPatternFullArcHighFreq:icons$2.lidarPatternFullArcHighFreq,lidarPatternFullArcMidFreq:icons$2.lidarPatternFullArcMidFreq,lidarPatternNarrowArc:icons$2.lidarPatternNarrowArc,lidar:icons$2.lidar,location1:icons$2.location1,location2:icons$2.location2,longRangeBeam1:icons$2.longRangeBeam1,longRangeBeam2:icons$2.longRangeBeam2,midRangeBeam1:icons$2.midRangeBeam1,midRangeBeam2:icons$2.midRangeBeam2,radarIdeal:icons$2.radarIdeal,radarRoundIdeal:icons$2.radarRoundIdeal,radarRound:icons$2.radarRound,radar:icons$2.radar,rearAxleMidpoint:icons$2.rearAxleMidpoint,rearBumperMidpoint:icons$2.rearBumperMidpoint,shortRangeBeam1:icons$2.shortRangeBeam1,shortRangeBeam2:icons$2.shortRangeBeam2,sphericalBeam:icons$2.sphericalBeam,survellianceCamera:icons$2.survellianceCamera,thinBulbBeam:icons$2.thinBulbBeam,thinnerBulbBeam:icons$2.thinnerBulbBeam,toCOMWithWheels:icons$2.toCOMWithWheels,toCOM:icons$2.toCOM,triangleBeam:icons$2.triangleBeam,tulipBeam:icons$2.tulipBeam,wavesSignalReceived:icons$2.wavesSignalReceived,wavesSignalSentLeft:icons$2.wavesSignalSentLeft,wavesSignalSentRight:icons$2.wavesSignalSentRight},arrow:{arrowLargeDown:icons$2.arrowLargeDown,arrowLargeLeft:icons$2.arrowLargeLeft,arrowLargeRight:icons$2.arrowLargeRight,arrowLargeUp:icons$2.arrowLargeUp,arrowSmallDown:icons$2.arrowSmallDown,arrowSmallLeft:icons$2.arrowSmallLeft,arrowSmallRight:icons$2.arrowSmallRight,arrowSmallUp:icons$2.arrowSmallUp,arrowSolidLeft:icons$2.arrowSolidLeft,arrowSolidRight:icons$2.arrowSolidRight,twoArrowsHorizontal:icons$2.twoArrowsHorizontal,twoArrowsVertical:icons$2.twoArrowsVertical,arrowsReplace:icons$2.arrowsReplace,arrowsShuffle:icons$2.arrowsShuffle,arrowsSwitch:icons$2.arrowsSwitch,seatArrowIn:icons$2.seatArrowIn,seatArrowOut:icons$2.seatArrowOut,seatVArrowIn:icons$2.seatVArrowIn,seatVArrowOut:icons$2.seatVArrowOut,vehicleArrowIn:icons$2.vehicleArrowIn,vehicleArrowOut:icons$2.vehicleArrowOut,seatArrowInLeft:icons$2.seatArrowInLeft,seatArrowOutLeft:icons$2.seatArrowOutLeft,seatVArrowInLeft:icons$2.seatVArrowInLeft,seatVArrowOutLeft:icons$2.seatVArrowOutLeft},large:{arrowLargeDown:icons$2.arrowLargeDown,arrowLargeLeft:icons$2.arrowLargeLeft,arrowLargeRight:icons$2.arrowLargeRight,arrowLargeUp:icons$2.arrowLargeUp,arrowSolidLeft:icons$2.arrowSolidLeft,arrowSolidRight:icons$2.arrowSolidRight,arrowLeftOutline:icons$2.arrowLeftOutline,arrowRightOutline:icons$2.arrowRightOutline,beamsNodesMessageOutline:icons$2.beamsNodesMessageOutline,beamsNodesOutline:icons$2.beamsNodesOutline,beamsNodesPlugOutline:icons$2.beamsNodesPlugOutline,BNGEcosystemOutline:icons$2.BNGEcosystemOutline,carFrontRouteOutline:icons$2.carFrontRouteOutline,carSensorsOutline:icons$2.carSensorsOutline,carSideRouteOutline:icons$2.carSideRouteOutline,cityOutline:icons$2.cityOutline,dialogOutline:icons$2.dialogOutline,documentSmileOutline:icons$2.documentSmileOutline,drivetrainOutline:icons$2.drivetrainOutline,electronicSchemeOutline:icons$2.electronicSchemeOutline,engineOutline:icons$2.engineOutline,gearTuningOutline:icons$2.gearTuningOutline,giftBoxOutline:icons$2.giftBoxOutline,lidarOutline:icons$2.lidarOutline,medalStarOutline:icons$2.medalStarOutline,megaphoneOutline:icons$2.megaphoneOutline,peopleOutline:icons$2.peopleOutline,personOutline:icons$2.personOutline,physicsOutline:icons$2.physicsOutline,playChainOutline:icons$2.playChainOutline,proximitySensorsOutline:icons$2.proximitySensorsOutline,qualityBadgeStarOutline:icons$2.qualityBadgeStarOutline,qualityBadgeVOutline:icons$2.qualityBadgeVOutline,simRigOutline:icons$2.simRigOutline,suspensionOutline:icons$2.suspensionOutline,teamOutline:icons$2.teamOutline,techLightBulbOutline01:icons$2.techLightBulbOutline01,techLightBulbOutline02:icons$2.techLightBulbOutline02,timeUnlockOutline:icons$2.timeUnlockOutline,timedLockOutline:icons$2.timedLockOutline,trafficOutline:icons$2.trafficOutline,voucherOutline:icons$2.voucherOutline,wheelBeamsNodesOutline:icons$2.wheelBeamsNodesOutline,wheelOutline:icons$2.wheelOutline,twoArrowsHorizontal:icons$2.twoArrowsHorizontal,twoArrowsVertical:icons$2.twoArrowsVertical},simple:{arrowLargeDown:icons$2.arrowLargeDown,arrowLargeLeft:icons$2.arrowLargeLeft,arrowLargeRight:icons$2.arrowLargeRight,arrowLargeUp:icons$2.arrowLargeUp,arrowSmallDown:icons$2.arrowSmallDown,arrowSmallLeft:icons$2.arrowSmallLeft,arrowSmallRight:icons$2.arrowSmallRight,arrowSmallUp:icons$2.arrowSmallUp},outlined:{arrowLargeDown:icons$2.arrowLargeDown,arrowLargeLeft:icons$2.arrowLargeLeft,arrowLargeRight:icons$2.arrowLargeRight,arrowLargeUp:icons$2.arrowLargeUp,arrowSmallDown:icons$2.arrowSmallDown,arrowSmallLeft:icons$2.arrowSmallLeft,arrowSmallRight:icons$2.arrowSmallRight,arrowSmallUp:icons$2.arrowSmallUp,roadMarkingOutline:icons$2.roadMarkingOutline,arrowLeftOutline:icons$2.arrowLeftOutline,arrowRightOutline:icons$2.arrowRightOutline,beamsNodesMessageOutline:icons$2.beamsNodesMessageOutline,beamsNodesOutline:icons$2.beamsNodesOutline,beamsNodesPlugOutline:icons$2.beamsNodesPlugOutline,BNGEcosystemOutline:icons$2.BNGEcosystemOutline,carFrontRouteOutline:icons$2.carFrontRouteOutline,carSensorsOutline:icons$2.carSensorsOutline,carSideRouteOutline:icons$2.carSideRouteOutline,cityOutline:icons$2.cityOutline,dialogOutline:icons$2.dialogOutline,documentSmileOutline:icons$2.documentSmileOutline,drivetrainOutline:icons$2.drivetrainOutline,electronicSchemeOutline:icons$2.electronicSchemeOutline,engineOutline:icons$2.engineOutline,gearTuningOutline:icons$2.gearTuningOutline,giftBoxOutline:icons$2.giftBoxOutline,lidarOutline:icons$2.lidarOutline,medalStarOutline:icons$2.medalStarOutline,megaphoneOutline:icons$2.megaphoneOutline,peopleOutline:icons$2.peopleOutline,personOutline:icons$2.personOutline,physicsOutline:icons$2.physicsOutline,playChainOutline:icons$2.playChainOutline,proximitySensorsOutline:icons$2.proximitySensorsOutline,qualityBadgeStarOutline:icons$2.qualityBadgeStarOutline,qualityBadgeVOutline:icons$2.qualityBadgeVOutline,simRigOutline:icons$2.simRigOutline,suspensionOutline:icons$2.suspensionOutline,teamOutline:icons$2.teamOutline,techLightBulbOutline01:icons$2.techLightBulbOutline01,techLightBulbOutline02:icons$2.techLightBulbOutline02,timeUnlockOutline:icons$2.timeUnlockOutline,timedLockOutline:icons$2.timedLockOutline,trafficOutline:icons$2.trafficOutline,voucherOutline:icons$2.voucherOutline,wheelBeamsNodesOutline:icons$2.wheelBeamsNodesOutline,wheelOutline:icons$2.wheelOutline},small:{arrowSmallDown:icons$2.arrowSmallDown,arrowSmallLeft:icons$2.arrowSmallLeft,arrowSmallRight:icons$2.arrowSmallRight,arrowSmallUp:icons$2.arrowSmallUp,mathDivide:icons$2.mathDivide,mathGreaterOrEqualThan:icons$2.mathGreaterOrEqualThan,mathGreaterThan:icons$2.mathGreaterThan,mathLessOrEqualThan:icons$2.mathLessOrEqualThan,mathLessThan:icons$2.mathLessThan,mathMinus:icons$2.mathMinus,mathMultiply:icons$2.mathMultiply,mathPlus:icons$2.mathPlus,slashLeft:icons$2.slashLeft,slashRight:icons$2.slashRight},solid:{arrowSolidLeft:icons$2.arrowSolidLeft,arrowSolidRight:icons$2.arrowSolidRight,twoArrowsHorizontal:icons$2.twoArrowsHorizontal,twoArrowsVertical:icons$2.twoArrowsVertical},detailed:{arrowSolidLeft:icons$2.arrowSolidLeft,arrowSolidRight:icons$2.arrowSolidRight},career:{banknotes:icons$2.banknotes,beamCurrency:icons$2.beamCurrency,beamXPFull:icons$2.beamXPFull,beamXPLo:icons$2.beamXPLo,carDealer:icons$2.carDealer,garage01:icons$2.garage01,garage02:icons$2.garage02,garage03:icons$2.garage03,lightGarageG11:icons$2.lightGarageG11,lightGarageG12:icons$2.lightGarageG12,lightGarageG13:icons$2.lightGarageG13,lightGarageG14:icons$2.lightGarageG14,lightGarageG21:icons$2.lightGarageG21,lightGarageG22:icons$2.lightGarageG22,lightGarageG23:icons$2.lightGarageG23,lightGarageG24:icons$2.lightGarageG24,lightGarageG31:icons$2.lightGarageG31,lightGarageG32:icons$2.lightGarageG32,lightGarageG33:icons$2.lightGarageG33,lightGarageG34:icons$2.lightGarageG34,plusGarage1:icons$2.plusGarage1,plusGarage2:icons$2.plusGarage2,plusGarage3:icons$2.plusGarage3,plusGarage4:icons$2.plusGarage4,voucherDiagonal1:icons$2.voucherDiagonal1,voucherDiagonal2:icons$2.voucherDiagonal2,voucherDiagonal3:icons$2.voucherDiagonal3,voucherHorizontal1:icons$2.voucherHorizontal1,voucherHorizontal2:icons$2.voucherHorizontal2,voucherHorizontal3:icons$2.voucherHorizontal3,garageNumber1:icons$2.garageNumber1,garageNumber2:icons$2.garageNumber2,garageNumber3:icons$2.garageNumber3,garageNumber4:icons$2.garageNumber4,garageNumber5:icons$2.garageNumber5,garageNumber6:icons$2.garageNumber6,garageNumber7:icons$2.garageNumber7,garageNumber8:icons$2.garageNumber8,garageNumber9:icons$2.garageNumber9,houseWrenchRoof:icons$2.houseWrenchRoof,houseWrench:icons$2.houseWrench,house:icons$2.house,beamCurrencyThin:icons$2.beamCurrencyThin},currencies:{banknotes:icons$2.banknotes,beamCurrency:icons$2.beamCurrency,beamXPFull:icons$2.beamXPFull,beamXPLo:icons$2.beamXPLo,beamCurrencyThin:icons$2.beamCurrencyThin},brand:{beamNG:icons$2.beamNG},beamng:{beamNG:icons$2.beamNG},decals:{booleanIntersect:icons$2.booleanIntersect,cameraFocusOnVehicle2:icons$2.cameraFocusOnVehicle2,copy:icons$2.copy,decal:icons$2.decal,deform:icons$2.deform,group:icons$2.group,material:icons$2.material,move:icons$2.move,order:icons$2.order,paperKnife:icons$2.paperKnife,redo:icons$2.redo,reflectNot:icons$2.reflectNot,reflect:icons$2.reflect,rename:icons$2.rename,sprayCan:icons$2.sprayCan,transform:icons$2.transform,transparencyMask:icons$2.transparencyMask,trashBin2:icons$2.trashBin2,undo:icons$2.undo,ungroup:icons$2.ungroup,view:icons$2.view,weight:icons$2.weight,scale:icons$2.scale,materialGlossy:icons$2.materialGlossy,materialMetal:icons$2.materialMetal,materialRoughness:icons$2.materialRoughness,materialTransparency01:icons$2.materialTransparency01,materialTransparency02:icons$2.materialTransparency02,surfaceRoughness02:icons$2.surfaceRoughness02,cameraFarClip:icons$2.cameraFarClip,cameraNearClip:icons$2.cameraNearClip,viewFarClip:icons$2.viewFarClip,viewNearClip:icons$2.viewNearClip},delivery:{boxDropOff01:icons$2.boxDropOff01,boxDropOff02:icons$2.boxDropOff02,boxDropOff03:icons$2.boxDropOff03,boxPickUp01:icons$2.boxPickUp01,boxPickUp02:icons$2.boxPickUp02,boxPickUp03:icons$2.boxPickUp03,boxPickUpDropOff01:icons$2.boxPickUpDropOff01,boxPickUpDropOff02:icons$2.boxPickUpDropOff02,boxTruck:icons$2.boxTruck,cardboardBox:icons$2.cardboardBox,deliveryTruckArrows:icons$2.deliveryTruckArrows,deliveryTruck:icons$2.deliveryTruck,flatbedTruck:icons$2.flatbedTruck,forklift:icons$2.forklift,fragile:icons$2.fragile,semiTrailer:icons$2.semiTrailer,semiTruckCabover:icons$2.semiTruckCabover,semiTruckUS:icons$2.semiTruckUS,semiTruck:icons$2.semiTruck,smallTrailer:icons$2.smallTrailer,stack3:icons$2.stack3,tankerTrailer:icons$2.tankerTrailer,thisSideUp:icons$2.thisSideUp,twoUnicyclesOnly:icons$2.twoUnicyclesOnly,boxTruckFast:icons$2.boxTruckFast,cardboardBoxCoins:icons$2.cardboardBoxCoins},cargo:{boxTruck:icons$2.boxTruck,flatbedTruck:icons$2.flatbedTruck,forklift:icons$2.forklift,fragile:icons$2.fragile,semiTrailer:icons$2.semiTrailer,semiTruckCabover:icons$2.semiTruckCabover,semiTruckUS:icons$2.semiTruckUS,semiTruck:icons$2.semiTruck,smallTrailer:icons$2.smallTrailer,stack3:icons$2.stack3,tankerTrailer:icons$2.tankerTrailer,thisSideUp:icons$2.thisSideUp,twoUnicyclesOnly:icons$2.twoUnicyclesOnly,boxTruckFast:icons$2.boxTruckFast},sound:{broom:icons$2.broom,soundFadeOut:icons$2.soundFadeOut,soundLimit:icons$2.soundLimit,soundLoud:icons$2.soundLoud,soundMonoL:icons$2.soundMonoL,soundMonoR:icons$2.soundMonoR,soundOff:icons$2.soundOff,soundQuiet:icons$2.soundQuiet,soundStereo:icons$2.soundStereo,soundWave01:icons$2.soundWave01,soundWave02:icons$2.soundWave02,trim:icons$2.trim},police:{carChase01:icons$2.carChase01,carsChase02:icons$2.carsChase02,evade:icons$2.evade,strobeLights:icons$2.strobeLights,wigwags:icons$2.wigwags},garage:{carDealer:icons$2.carDealer,garage01:icons$2.garage01,garage02:icons$2.garage02,garage03:icons$2.garage03,lightGarageG11:icons$2.lightGarageG11,lightGarageG12:icons$2.lightGarageG12,lightGarageG13:icons$2.lightGarageG13,lightGarageG14:icons$2.lightGarageG14,lightGarageG21:icons$2.lightGarageG21,lightGarageG22:icons$2.lightGarageG22,lightGarageG23:icons$2.lightGarageG23,lightGarageG24:icons$2.lightGarageG24,lightGarageG31:icons$2.lightGarageG31,lightGarageG32:icons$2.lightGarageG32,lightGarageG33:icons$2.lightGarageG33,lightGarageG34:icons$2.lightGarageG34,plusGarage1:icons$2.plusGarage1,plusGarage2:icons$2.plusGarage2,plusGarage3:icons$2.plusGarage3,plusGarage4:icons$2.plusGarage4,houseWrenchRoof:icons$2.houseWrenchRoof,houseWrench:icons$2.houseWrench,house:icons$2.house},sensors:{carSensors:icons$2.carSensors,carWithLidar:icons$2.carWithLidar,mapWithEmitter:icons$2.mapWithEmitter},tech:{carWithLidar:icons$2.carWithLidar,mapWithEmitter:icons$2.mapWithEmitter,mesh4Cells:icons$2.mesh4Cells,mesh9Cells:icons$2.mesh9Cells},fuel:{charge:icons$2.charge,charging:icons$2.charging,fuelPumpFilling:icons$2.fuelPumpFilling,fuelPump:icons$2.fuelPump,N2OButton:icons$2.N2OButton,N2OHoriz:icons$2.N2OHoriz,N2OVert:icons$2.N2OVert,discharging:icons$2.discharging},electricity:{charge:icons$2.charge,charging:icons$2.charging,discharging:icons$2.discharging},ev:{charge:icons$2.charge,charging:icons$2.charging,discharging:icons$2.discharging},checkbox:{checkboxOff:icons$2.checkboxOff,checkboxOn:icons$2.checkboxOn,missionCheckboxCross:icons$2.missionCheckboxCross},selection:{checkboxOff:icons$2.checkboxOff,checkboxOn:icons$2.checkboxOn,missionCheckboxCross:icons$2.missionCheckboxCross},box:{checkboxOff:icons$2.checkboxOff,checkboxOn:icons$2.checkboxOn,missionCheckboxCross:icons$2.missionCheckboxCross},movie:{clapperboard:icons$2.clapperboard},scenery:{clapperboard:icons$2.clapperboard},powertrain:{cogsDamaged:icons$2.cogsDamaged},drivetrain:{cogsDamaged:icons$2.cogsDamaged},data:{dataExchange:icons$2.dataExchange,eyeWaves:icons$2.eyeWaves,gyroscopeMicrochip:icons$2.gyroscopeMicrochip,gyroscope:icons$2.gyroscope,lidar:icons$2.lidar,radarIdeal:icons$2.radarIdeal,radarRoundIdeal:icons$2.radarRoundIdeal,radarRound:icons$2.radarRound,radar:icons$2.radar,wavesSignalReceived:icons$2.wavesSignalReceived,wavesSignalSentLeft:icons$2.wavesSignalSentLeft,wavesSignalSentRight:icons$2.wavesSignalSentRight},signal:{dataExchange:icons$2.dataExchange,eyeWaves:icons$2.eyeWaves,gyroscopeMicrochip:icons$2.gyroscopeMicrochip,gyroscope:icons$2.gyroscope,lidar:icons$2.lidar,radarIdeal:icons$2.radarIdeal,radarRoundIdeal:icons$2.radarRoundIdeal,radarRound:icons$2.radarRound,radar:icons$2.radar,wavesSignalReceived:icons$2.wavesSignalReceived,wavesSignalSentLeft:icons$2.wavesSignalSentLeft,wavesSignalSentRight:icons$2.wavesSignalSentRight},environment:{day:icons$2.day,night:icons$2.night,sunRise:icons$2.sunRise,weather:icons$2.weather,sunDown:icons$2.sunDown},part:{engine:icons$2.engine,suspension01:icons$2.suspension01,turbine:icons$2.turbine,doorFrontCoins:icons$2.doorFrontCoins,doorFront:icons$2.doorFront,engineCoins:icons$2.engineCoins,exhaustMufflerCoins:icons$2.exhaustMufflerCoins,exhaustMuffler:icons$2.exhaustMuffler,headlightCoins:icons$2.headlightCoins,headlight:icons$2.headlight,tire3FourthCoins:icons$2.tire3FourthCoins,tire3Fourth:icons$2.tire3Fourth,turbineCoins:icons$2.turbineCoins,wheelDiscCoins:icons$2.wheelDiscCoins,wheelDisc:icons$2.wheelDisc,doorFrontDetached:icons$2.doorFrontDetached,hingeBroken:icons$2.hingeBroken},mission:{evade:icons$2.evade,flagOutlineLarge:icons$2.flagOutlineLarge},playback:{fastBackward:icons$2.fastBackward,fastForward:icons$2.fastForward,music:icons$2.music,nextTrack:icons$2.nextTrack,pauseRound:icons$2.pauseRound,pause:icons$2.pause,playRound:icons$2.playRound,play:icons$2.play,playlist:icons$2.playlist,prevTrack:icons$2.prevTrack,square:icons$2.square,eject:icons$2.eject,playPause:icons$2.playPause},truck:{flatbedTruck:icons$2.flatbedTruck,semiTruckCabover:icons$2.semiTruckCabover,semiTruckUS:icons$2.semiTruckUS,semiTruck:icons$2.semiTruck},stencil:{forklift:icons$2.forklift,fragile:icons$2.fragile,stack3:icons$2.stack3,thisSideUp:icons$2.thisSideUp,twoUnicyclesOnly:icons$2.twoUnicyclesOnly},placement:{frontAxleMidpoint:icons$2.frontAxleMidpoint,frontBumperMidpoint:icons$2.frontBumperMidpoint,rearAxleMidpoint:icons$2.rearAxleMidpoint,rearBumperMidpoint:icons$2.rearBumperMidpoint,toCOMWithWheels:icons$2.toCOMWithWheels,toCOM:icons$2.toCOM},gamepad:{gamepadOld:icons$2.gamepadOld,gamepad:icons$2.gamepad,noNameControllerButton:icons$2.noNameControllerButton,xboxA:icons$2.xboxA,xboxB:icons$2.xboxB,xboxDDefaultOutline:icons$2.xboxDDefaultOutline,xboxDDefaultSolid:icons$2.xboxDDefaultSolid,xboxDDown:icons$2.xboxDDown,xboxDLeft:icons$2.xboxDLeft,xboxDRight:icons$2.xboxDRight,xboxDUp:icons$2.xboxDUp,xboxLB:icons$2.xboxLB,xboxLSButton:icons$2.xboxLSButton,xboxLT:icons$2.xboxLT,xboxMenu:icons$2.xboxMenu,xboxRB:icons$2.xboxRB,xboxRSButton:icons$2.xboxRSButton,xboxRT:icons$2.xboxRT,xboxThumbL:icons$2.xboxThumbL,xboxThumbR:icons$2.xboxThumbR,xboxView:icons$2.xboxView,xboxXAxis:icons$2.xboxXAxis,xboxXRot:icons$2.xboxXRot,xboxX:icons$2.xboxX,xboxYAxis:icons$2.xboxYAxis,xboxYRot:icons$2.xboxYRot,xboxY:icons$2.xboxY,psCircleOutline:icons$2.psCircleOutline,psCircle:icons$2.psCircle,psCreate2:icons$2.psCreate2,psCreate:icons$2.psCreate,psCrossOutline:icons$2.psCrossOutline,psCross:icons$2.psCross,psDDefaultOutline:icons$2.psDDefaultOutline,psDDefaultSolid:icons$2.psDDefaultSolid,psDDown:icons$2.psDDown,psDLeft:icons$2.psDLeft,psDRight:icons$2.psDRight,psDUp:icons$2.psDUp,psL1:icons$2.psL1,psL2:icons$2.psL2,psL3ButtonArrowDown:icons$2.psL3ButtonArrowDown,psL3Button:icons$2.psL3Button,psLSXLeft:icons$2.psLSXLeft,psLSXRight:icons$2.psLSXRight,psLSX:icons$2.psLSX,psLSYDown:icons$2.psLSYDown,psLSYUp:icons$2.psLSYUp,psLSY:icons$2.psLSY,psLS:icons$2.psLS,psMenu2:icons$2.psMenu2,psMenu:icons$2.psMenu,psR1:icons$2.psR1,psR2:icons$2.psR2,psR3ButtonArrowDown:icons$2.psR3ButtonArrowDown,psR3Button:icons$2.psR3Button,psRSXLeft:icons$2.psRSXLeft,psRSXRight:icons$2.psRSXRight,psRSX:icons$2.psRSX,psRSYDown:icons$2.psRSYDown,psRSYUp:icons$2.psRSYUp,psRSY:icons$2.psRSY,psRS:icons$2.psRS,psSquareOutline:icons$2.psSquareOutline,psSquare:icons$2.psSquare,psTrackpadNavigate:icons$2.psTrackpadNavigate,psTrackpadPressCenter:icons$2.psTrackpadPressCenter,psTrackpadPressLeft:icons$2.psTrackpadPressLeft,psTrackpadPressRight:icons$2.psTrackpadPressRight,psTrackpadSwipeDown:icons$2.psTrackpadSwipeDown,psTrackpadSwipeLeft:icons$2.psTrackpadSwipeLeft,psTrackpadSwipeRight:icons$2.psTrackpadSwipeRight,psTrackpadSwipeUp:icons$2.psTrackpadSwipeUp,psTriangleOutline:icons$2.psTriangleOutline,psTriangle:icons$2.psTriangle,xboxAOutline:icons$2.xboxAOutline,xboxBOutline:icons$2.xboxBOutline,xboxLSButtonArrowDown:icons$2.xboxLSButtonArrowDown,xboxRSButtonArrowDown:icons$2.xboxRSButtonArrowDown,xboxXAxisLeft:icons$2.xboxXAxisLeft,xboxXAxisRight:icons$2.xboxXAxisRight,xboxXOutline:icons$2.xboxXOutline,xboxXRotLeft:icons$2.xboxXRotLeft,xboxXRotRight:icons$2.xboxXRotRight,xboxYAxisDown:icons$2.xboxYAxisDown,xboxYAxisUp:icons$2.xboxYAxisUp,xboxYOutline:icons$2.xboxYOutline,xboxYRotDown:icons$2.xboxYRotDown,xboxYRotUp:icons$2.xboxYRotUp,psDLeftRight:icons$2.psDLeftRight,psDUpDown:icons$2.psDUpDown,xboxDLeftRight:icons$2.xboxDLeftRight,xboxDUpDown:icons$2.xboxDUpDown},controller:{gamepadOld:icons$2.gamepadOld,gamepad:icons$2.gamepad,noNameControllerButton:icons$2.noNameControllerButton,steeringWheelCommon:icons$2.steeringWheelCommon,steeringWheelSporty:icons$2.steeringWheelSporty,xboxA:icons$2.xboxA,xboxB:icons$2.xboxB,xboxDDefaultOutline:icons$2.xboxDDefaultOutline,xboxDDefaultSolid:icons$2.xboxDDefaultSolid,xboxDDown:icons$2.xboxDDown,xboxDLeft:icons$2.xboxDLeft,xboxDRight:icons$2.xboxDRight,xboxDUp:icons$2.xboxDUp,xboxLB:icons$2.xboxLB,xboxLSButton:icons$2.xboxLSButton,xboxLT:icons$2.xboxLT,xboxMenu:icons$2.xboxMenu,xboxRB:icons$2.xboxRB,xboxRSButton:icons$2.xboxRSButton,xboxRT:icons$2.xboxRT,xboxThumbL:icons$2.xboxThumbL,xboxThumbR:icons$2.xboxThumbR,xboxView:icons$2.xboxView,xboxXAxis:icons$2.xboxXAxis,xboxXRot:icons$2.xboxXRot,xboxX:icons$2.xboxX,xboxYAxis:icons$2.xboxYAxis,xboxYRot:icons$2.xboxYRot,xboxY:icons$2.xboxY,psCircleOutline:icons$2.psCircleOutline,psCircle:icons$2.psCircle,psCreate2:icons$2.psCreate2,psCreate:icons$2.psCreate,psCrossOutline:icons$2.psCrossOutline,psCross:icons$2.psCross,psDDefaultOutline:icons$2.psDDefaultOutline,psDDefaultSolid:icons$2.psDDefaultSolid,psDDown:icons$2.psDDown,psDLeft:icons$2.psDLeft,psDRight:icons$2.psDRight,psDUp:icons$2.psDUp,psL1:icons$2.psL1,psL2:icons$2.psL2,psL3ButtonArrowDown:icons$2.psL3ButtonArrowDown,psL3Button:icons$2.psL3Button,psLSXLeft:icons$2.psLSXLeft,psLSXRight:icons$2.psLSXRight,psLSX:icons$2.psLSX,psLSYDown:icons$2.psLSYDown,psLSYUp:icons$2.psLSYUp,psLSY:icons$2.psLSY,psLS:icons$2.psLS,psMenu2:icons$2.psMenu2,psMenu:icons$2.psMenu,psR1:icons$2.psR1,psR2:icons$2.psR2,psR3ButtonArrowDown:icons$2.psR3ButtonArrowDown,psR3Button:icons$2.psR3Button,psRSXLeft:icons$2.psRSXLeft,psRSXRight:icons$2.psRSXRight,psRSX:icons$2.psRSX,psRSYDown:icons$2.psRSYDown,psRSYUp:icons$2.psRSYUp,psRSY:icons$2.psRSY,psRS:icons$2.psRS,psSquareOutline:icons$2.psSquareOutline,psSquare:icons$2.psSquare,psTrackpadNavigate:icons$2.psTrackpadNavigate,psTrackpadPressCenter:icons$2.psTrackpadPressCenter,psTrackpadPressLeft:icons$2.psTrackpadPressLeft,psTrackpadPressRight:icons$2.psTrackpadPressRight,psTrackpadSwipeDown:icons$2.psTrackpadSwipeDown,psTrackpadSwipeLeft:icons$2.psTrackpadSwipeLeft,psTrackpadSwipeRight:icons$2.psTrackpadSwipeRight,psTrackpadSwipeUp:icons$2.psTrackpadSwipeUp,psTriangleOutline:icons$2.psTriangleOutline,psTriangle:icons$2.psTriangle,xboxAOutline:icons$2.xboxAOutline,xboxBOutline:icons$2.xboxBOutline,xboxLSButtonArrowDown:icons$2.xboxLSButtonArrowDown,xboxRSButtonArrowDown:icons$2.xboxRSButtonArrowDown,xboxXAxisLeft:icons$2.xboxXAxisLeft,xboxXAxisRight:icons$2.xboxXAxisRight,xboxXOutline:icons$2.xboxXOutline,xboxXRotLeft:icons$2.xboxXRotLeft,xboxXRotRight:icons$2.xboxXRotRight,xboxYAxisDown:icons$2.xboxYAxisDown,xboxYAxisUp:icons$2.xboxYAxisUp,xboxYOutline:icons$2.xboxYOutline,xboxYRotDown:icons$2.xboxYRotDown,xboxYRotUp:icons$2.xboxYRotUp,psDLeftRight:icons$2.psDLeftRight,psDUpDown:icons$2.psDUpDown,xboxDLeftRight:icons$2.xboxDLeftRight,xboxDUpDown:icons$2.xboxDUpDown},input:{gamepadOld:icons$2.gamepadOld,gamepad:icons$2.gamepad,keyboard:icons$2.keyboard,mouseLMB:icons$2.mouseLMB,mouseMMB:icons$2.mouseMMB,mouseRMB:icons$2.mouseRMB,mouseWheel:icons$2.mouseWheel,mouseXAxis:icons$2.mouseXAxis,mouseXYAxis:icons$2.mouseXYAxis,mouseYAxis:icons$2.mouseYAxis,mouse:icons$2.mouse,noNameControllerButton:icons$2.noNameControllerButton,palmCrossed:icons$2.palmCrossed,smartphone1:icons$2.smartphone1,smartphone2:icons$2.smartphone2,steeringWheelCommon:icons$2.steeringWheelCommon,steeringWheelSporty:icons$2.steeringWheelSporty,touch:icons$2.touch,xboxA:icons$2.xboxA,xboxB:icons$2.xboxB,xboxDDefaultOutline:icons$2.xboxDDefaultOutline,xboxDDefaultSolid:icons$2.xboxDDefaultSolid,xboxDDown:icons$2.xboxDDown,xboxDLeft:icons$2.xboxDLeft,xboxDRight:icons$2.xboxDRight,xboxDUp:icons$2.xboxDUp,xboxLB:icons$2.xboxLB,xboxLSButton:icons$2.xboxLSButton,xboxLT:icons$2.xboxLT,xboxMenu:icons$2.xboxMenu,xboxRB:icons$2.xboxRB,xboxRSButton:icons$2.xboxRSButton,xboxRT:icons$2.xboxRT,xboxThumbL:icons$2.xboxThumbL,xboxThumbR:icons$2.xboxThumbR,xboxView:icons$2.xboxView,xboxXAxis:icons$2.xboxXAxis,xboxXRot:icons$2.xboxXRot,xboxX:icons$2.xboxX,xboxYAxis:icons$2.xboxYAxis,xboxYRot:icons$2.xboxYRot,xboxY:icons$2.xboxY,psCircleOutline:icons$2.psCircleOutline,psCircle:icons$2.psCircle,psCreate2:icons$2.psCreate2,psCreate:icons$2.psCreate,psCrossOutline:icons$2.psCrossOutline,psCross:icons$2.psCross,psDDefaultOutline:icons$2.psDDefaultOutline,psDDefaultSolid:icons$2.psDDefaultSolid,psDDown:icons$2.psDDown,psDLeft:icons$2.psDLeft,psDRight:icons$2.psDRight,psDUp:icons$2.psDUp,psL1:icons$2.psL1,psL2:icons$2.psL2,psL3ButtonArrowDown:icons$2.psL3ButtonArrowDown,psL3Button:icons$2.psL3Button,psLSXLeft:icons$2.psLSXLeft,psLSXRight:icons$2.psLSXRight,psLSX:icons$2.psLSX,psLSYDown:icons$2.psLSYDown,psLSYUp:icons$2.psLSYUp,psLSY:icons$2.psLSY,psLS:icons$2.psLS,psMenu2:icons$2.psMenu2,psMenu:icons$2.psMenu,psR1:icons$2.psR1,psR2:icons$2.psR2,psR3ButtonArrowDown:icons$2.psR3ButtonArrowDown,psR3Button:icons$2.psR3Button,psRSXLeft:icons$2.psRSXLeft,psRSXRight:icons$2.psRSXRight,psRSX:icons$2.psRSX,psRSYDown:icons$2.psRSYDown,psRSYUp:icons$2.psRSYUp,psRSY:icons$2.psRSY,psRS:icons$2.psRS,psSquareOutline:icons$2.psSquareOutline,psSquare:icons$2.psSquare,psTrackpadNavigate:icons$2.psTrackpadNavigate,psTrackpadPressCenter:icons$2.psTrackpadPressCenter,psTrackpadPressLeft:icons$2.psTrackpadPressLeft,psTrackpadPressRight:icons$2.psTrackpadPressRight,psTrackpadSwipeDown:icons$2.psTrackpadSwipeDown,psTrackpadSwipeLeft:icons$2.psTrackpadSwipeLeft,psTrackpadSwipeRight:icons$2.psTrackpadSwipeRight,psTrackpadSwipeUp:icons$2.psTrackpadSwipeUp,psTriangleOutline:icons$2.psTriangleOutline,psTriangle:icons$2.psTriangle,xboxAOutline:icons$2.xboxAOutline,xboxBOutline:icons$2.xboxBOutline,xboxLSButtonArrowDown:icons$2.xboxLSButtonArrowDown,xboxRSButtonArrowDown:icons$2.xboxRSButtonArrowDown,xboxXAxisLeft:icons$2.xboxXAxisLeft,xboxXAxisRight:icons$2.xboxXAxisRight,xboxXOutline:icons$2.xboxXOutline,xboxXRotLeft:icons$2.xboxXRotLeft,xboxXRotRight:icons$2.xboxXRotRight,xboxYAxisDown:icons$2.xboxYAxisDown,xboxYAxisUp:icons$2.xboxYAxisUp,xboxYOutline:icons$2.xboxYOutline,xboxYRotDown:icons$2.xboxYRotDown,xboxYRotUp:icons$2.xboxYRotUp,psDLeftRight:icons$2.psDLeftRight,psDUpDown:icons$2.psDUpDown,xboxDLeftRight:icons$2.xboxDLeftRight,xboxDUpDown:icons$2.xboxDUpDown},gps:{GPSMark:icons$2.GPSMark,GPSSolid:icons$2.GPSSolid,location1:icons$2.location1,location2:icons$2.location2},position:{GPSMark:icons$2.GPSMark,GPSSolid:icons$2.GPSSolid,location1:icons$2.location1,location2:icons$2.location2},map:{GPSMark:icons$2.GPSMark,GPSSolid:icons$2.GPSSolid,location1:icons$2.location1,location2:icons$2.location2},keyboard:{keyboard:icons$2.keyboard,kbArrowsDown:icons$2.kbArrowsDown,kbArrowsLeftRight:icons$2.kbArrowsLeftRight,kbArrowsLeft:icons$2.kbArrowsLeft,kbArrowsOutline:icons$2.kbArrowsOutline,kbArrowsRight:icons$2.kbArrowsRight,kbArrowsSolid:icons$2.kbArrowsSolid,kbArrowsUpDown:icons$2.kbArrowsUpDown,kbArrowsUp:icons$2.kbArrowsUp},lights:{lightGarageG11:icons$2.lightGarageG11,lightGarageG12:icons$2.lightGarageG12,lightGarageG13:icons$2.lightGarageG13,lightGarageG14:icons$2.lightGarageG14,lightGarageG21:icons$2.lightGarageG21,lightGarageG22:icons$2.lightGarageG22,lightGarageG23:icons$2.lightGarageG23,lightGarageG24:icons$2.lightGarageG24,lightGarageG31:icons$2.lightGarageG31,lightGarageG32:icons$2.lightGarageG32,lightGarageG33:icons$2.lightGarageG33,lightGarageG34:icons$2.lightGarageG34},catalog:{listBig:icons$2.listBig,listSmall:icons$2.listSmall,tiles:icons$2.tiles},selector:{listBig:icons$2.listBig,listSmall:icons$2.listSmall,tiles:icons$2.tiles},view:{listBig:icons$2.listBig,listSmall:icons$2.listSmall,tiles:icons$2.tiles},math:{mathDivide:icons$2.mathDivide,mathGreaterOrEqualThan:icons$2.mathGreaterOrEqualThan,mathGreaterThan:icons$2.mathGreaterThan,mathLessOrEqualThan:icons$2.mathLessOrEqualThan,mathLessThan:icons$2.mathLessThan,mathMinus:icons$2.mathMinus,mathMultiply:icons$2.mathMultiply,mathPlus:icons$2.mathPlus,slashLeft:icons$2.slashLeft,slashRight:icons$2.slashRight},operands:{mathDivide:icons$2.mathDivide,mathGreaterOrEqualThan:icons$2.mathGreaterOrEqualThan,mathGreaterThan:icons$2.mathGreaterThan,mathLessOrEqualThan:icons$2.mathLessOrEqualThan,mathLessThan:icons$2.mathLessThan,mathMinus:icons$2.mathMinus,mathMultiply:icons$2.mathMultiply,mathPlus:icons$2.mathPlus,slashLeft:icons$2.slashLeft,slashRight:icons$2.slashRight},reward:{medal:icons$2.medal,voucherDiagonal1:icons$2.voucherDiagonal1,voucherDiagonal2:icons$2.voucherDiagonal2,voucherDiagonal3:icons$2.voucherDiagonal3,voucherHorizontal1:icons$2.voucherHorizontal1,voucherHorizontal2:icons$2.voucherHorizontal2,voucherHorizontal3:icons$2.voucherHorizontal3,medalEmpty:icons$2.medalEmpty,medalStar:icons$2.medalStar,badgeRoundEmpty:icons$2.badgeRoundEmpty,badgeRoundStar:icons$2.badgeRoundStar,badgeRound:icons$2.badgeRound,badge:icons$2.badge},achievment:{medal:icons$2.medal,medalEmpty:icons$2.medalEmpty,medalStar:icons$2.medalStar,badgeRoundEmpty:icons$2.badgeRoundEmpty,badgeRoundStar:icons$2.badgeRoundStar,badgeRound:icons$2.badgeRound,badge:icons$2.badge},mesh:{mesh4Cells:icons$2.mesh4Cells,mesh9Cells:icons$2.mesh9Cells},beams:{mesh4Cells:icons$2.mesh4Cells,mesh9Cells:icons$2.mesh9Cells},nodes:{mesh4Cells:icons$2.mesh4Cells,mesh9Cells:icons$2.mesh9Cells},surface:{mesh4Cells:icons$2.mesh4Cells,mesh9Cells:icons$2.mesh9Cells,bridge:icons$2.bridge,bump:icons$2.bump,bumps:icons$2.bumps,caution:icons$2.caution,crest:icons$2.crest,doubleCaution:icons$2.doubleCaution,finish:icons$2.finish,jumpOverBump:icons$2.jumpOverBump,narrows:icons$2.narrows,pothole:icons$2.pothole,turn1:icons$2.turn1,turn2:icons$2.turn2,turn3:icons$2.turn3,turn4:icons$2.turn4,turn5:icons$2.turn5,turn6:icons$2.turn6,turnHp:icons$2.turnHp,turnSq:icons$2.turnSq,water:icons$2.water,tripleCaution:icons$2.tripleCaution},mirror:{mirrorInteriorMiddle:icons$2.mirrorInteriorMiddle,mirrorLeftBigBottomWideAngle:icons$2.mirrorLeftBigBottomWideAngle,mirrorLeftBigTop:icons$2.mirrorLeftBigTop,mirrorLeftBig:icons$2.mirrorLeftBig,mirrorLeftBonnet:icons$2.mirrorLeftBonnet,mirrorLeftDefault:icons$2.mirrorLeftDefault,mirrorRightBigBottomWideAngle:icons$2.mirrorRightBigBottomWideAngle,mirrorRightBigTop:icons$2.mirrorRightBigTop,mirrorRightBig:icons$2.mirrorRightBig,mirrorRightBonnet:icons$2.mirrorRightBonnet,mirrorRightDefault:icons$2.mirrorRightDefault,mirrorRoundWideAngle:icons$2.mirrorRoundWideAngle,mirrorTopWideAngle:icons$2.mirrorTopWideAngle},rearview:{mirrorInteriorMiddle:icons$2.mirrorInteriorMiddle,mirrorLeftBigBottomWideAngle:icons$2.mirrorLeftBigBottomWideAngle,mirrorLeftBigTop:icons$2.mirrorLeftBigTop,mirrorLeftBig:icons$2.mirrorLeftBig,mirrorLeftBonnet:icons$2.mirrorLeftBonnet,mirrorLeftDefault:icons$2.mirrorLeftDefault,mirrorRightBigBottomWideAngle:icons$2.mirrorRightBigBottomWideAngle,mirrorRightBigTop:icons$2.mirrorRightBigTop,mirrorRightBig:icons$2.mirrorRightBig,mirrorRightBonnet:icons$2.mirrorRightBonnet,mirrorRightDefault:icons$2.mirrorRightDefault,mirrorRoundWideAngle:icons$2.mirrorRoundWideAngle,mirrorTopWideAngle:icons$2.mirrorTopWideAngle},mouse:{mouseLMB:icons$2.mouseLMB,mouseMMB:icons$2.mouseMMB,mouseRMB:icons$2.mouseRMB,mouseWheel:icons$2.mouseWheel,mouseXAxis:icons$2.mouseXAxis,mouseXYAxis:icons$2.mouseXYAxis,mouseYAxis:icons$2.mouseYAxis,mouse:icons$2.mouse},path:{nodeAddFirst01:icons$2.nodeAddFirst01,nodeAddFirst02:icons$2.nodeAddFirst02,nodeAddLast02:icons$2.nodeAddLast02,nodeAddMiddle01:icons$2.nodeAddMiddle01,nodeAddMiddle02:icons$2.nodeAddMiddle02,nodeAdd:icons$2.nodeAdd,nodeLast01:icons$2.nodeLast01,nodeRemove:icons$2.nodeRemove,locationDestination:icons$2.locationDestination,locationSource:icons$2.locationSource},node:{nodeAddFirst01:icons$2.nodeAddFirst01,nodeAddFirst02:icons$2.nodeAddFirst02,nodeAddLast02:icons$2.nodeAddLast02,nodeAddMiddle01:icons$2.nodeAddMiddle01,nodeAddMiddle02:icons$2.nodeAddMiddle02,nodeAdd:icons$2.nodeAdd,nodeLast01:icons$2.nodeLast01,nodeRemove:icons$2.nodeRemove,locationDestination:icons$2.locationDestination,locationSource:icons$2.locationSource},touch:{palmCrossed:icons$2.palmCrossed,smartphone1:icons$2.smartphone1,smartphone2:icons$2.smartphone2,touch:icons$2.touch},route:{routeAdd:icons$2.routeAdd,routeComplex:icons$2.routeComplex,routeSimple:icons$2.routeSimple,trafficCone:icons$2.trafficCone,locationDestination:icons$2.locationDestination,locationSource:icons$2.locationSource,routeSimpleFlag:icons$2.routeSimpleFlag},traffic:{routeAdd:icons$2.routeAdd,routeComplex:icons$2.routeComplex,routeSimple:icons$2.routeSimple,trafficCone:icons$2.trafficCone,trafficLight:icons$2.trafficLight,pedestrianRunning:icons$2.pedestrianRunning,pedestrianStanding:icons$2.pedestrianStanding,routeSimpleFlag:icons$2.routeSimpleFlag},trailer:{semiTrailer:icons$2.semiTrailer,semiTruck:icons$2.semiTruck,smallTrailer:icons$2.smallTrailer,tankerTrailer:icons$2.tankerTrailer},steering:{steeringWheelCommon:icons$2.steeringWheelCommon,steeringWheelSporty:icons$2.steeringWheelSporty},time:{stopwatchArrows01:icons$2.stopwatchArrows01,stopwatchArrows02:icons$2.stopwatchArrows02,stopwatchSectionOutlinedEnd:icons$2.stopwatchSectionOutlinedEnd,stopwatchSectionOutlinedStart:icons$2.stopwatchSectionOutlinedStart,stopwatchSectionSolidEnd:icons$2.stopwatchSectionSolidEnd,stopwatchSectionSolidStart:icons$2.stopwatchSectionSolidStart,timer:icons$2.timer},fast:{stopwatchArrows01:icons$2.stopwatchArrows01,stopwatchArrows02:icons$2.stopwatchArrows02,stopwatchSectionOutlinedEnd:icons$2.stopwatchSectionOutlinedEnd,stopwatchSectionOutlinedStart:icons$2.stopwatchSectionOutlinedStart,stopwatchSectionSolidEnd:icons$2.stopwatchSectionSolidEnd,stopwatchSectionSolidStart:icons$2.stopwatchSectionSolidStart,timer:icons$2.timer},emergency:{strobeLights:icons$2.strobeLights,wigwags:icons$2.wigwags},circuit:{switchBlock:icons$2.switchBlock,switchOutline:icons$2.switchOutline},electronics:{switchBlock:icons$2.switchBlock,switchOutline:icons$2.switchOutline},switch:{switchBlock:icons$2.switchBlock,switchOutline:icons$2.switchOutline},tank:{tankerTrailer:icons$2.tankerTrailer},tanker:{tankerTrailer:icons$2.tankerTrailer},taxi:{taxiCar1:icons$2.taxiCar1,taxiCar3:icons$2.taxiCar3,taxiCarT:icons$2.taxiCarT,taxiCheckerLamp:icons$2.taxiCheckerLamp},tire:{tireDirection3Fourth2:icons$2.tireDirection3Fourth2,tireDirection3Fourth3:icons$2.tireDirection3Fourth3,tireDirectionFront2:icons$2.tireDirectionFront2,tireDirectionSide2:icons$2.tireDirectionSide2,tireDirectionTop2:icons$2.tireDirectionTop2,tire3FourthCoins:icons$2.tire3FourthCoins,tire3Fourth:icons$2.tire3Fourth},currency:{voucherDiagonal1:icons$2.voucherDiagonal1,voucherDiagonal2:icons$2.voucherDiagonal2,voucherDiagonal3:icons$2.voucherDiagonal3,voucherHorizontal1:icons$2.voucherHorizontal1,voucherHorizontal2:icons$2.voucherHorizontal2,voucherHorizontal3:icons$2.voucherHorizontal3,beamCurrencyOutlineLarge:icons$2.beamCurrencyOutlineLarge},extra:{AIL:icons$2.AIL,automaticTransmissionL:icons$2.automaticTransmissionL,chargeLL:icons$2.chargeLL,clutchL:icons$2.clutchL,couplerL:icons$2.couplerL,engineL:icons$2.engineL,multiseatL:icons$2.multiseatL,POITimeL:icons$2.POITimeL,replayL:icons$2.replayL,roadblockL:icons$2.roadblockL,rotationL:icons$2.rotationL,sensorsL:icons$2.sensorsL,temperatureL:icons$2.temperatureL,tuningL:icons$2.tuningL,turbineL:icons$2.turbineL},web:{arrowLeftOutline:icons$2.arrowLeftOutline,arrowRightOutline:icons$2.arrowRightOutline,beamsNodesMessageOutline:icons$2.beamsNodesMessageOutline,beamsNodesOutline:icons$2.beamsNodesOutline,beamsNodesPlugOutline:icons$2.beamsNodesPlugOutline,BNGEcosystemOutline:icons$2.BNGEcosystemOutline,carFrontRouteOutline:icons$2.carFrontRouteOutline,carSensorsOutline:icons$2.carSensorsOutline,carSideRouteOutline:icons$2.carSideRouteOutline,cityOutline:icons$2.cityOutline,dialogOutline:icons$2.dialogOutline,documentSmileOutline:icons$2.documentSmileOutline,drivetrainOutline:icons$2.drivetrainOutline,electronicSchemeOutline:icons$2.electronicSchemeOutline,engineOutline:icons$2.engineOutline,gearTuningOutline:icons$2.gearTuningOutline,giftBoxOutline:icons$2.giftBoxOutline,lidarOutline:icons$2.lidarOutline,medalStarOutline:icons$2.medalStarOutline,megaphoneOutline:icons$2.megaphoneOutline,peopleOutline:icons$2.peopleOutline,personOutline:icons$2.personOutline,physicsOutline:icons$2.physicsOutline,playChainOutline:icons$2.playChainOutline,proximitySensorsOutline:icons$2.proximitySensorsOutline,qualityBadgeStarOutline:icons$2.qualityBadgeStarOutline,qualityBadgeVOutline:icons$2.qualityBadgeVOutline,simRigOutline:icons$2.simRigOutline,suspensionOutline:icons$2.suspensionOutline,teamOutline:icons$2.teamOutline,techLightBulbOutline01:icons$2.techLightBulbOutline01,techLightBulbOutline02:icons$2.techLightBulbOutline02,timeUnlockOutline:icons$2.timeUnlockOutline,timedLockOutline:icons$2.timedLockOutline,trafficOutline:icons$2.trafficOutline,voucherOutline:icons$2.voucherOutline,wheelBeamsNodesOutline:icons$2.wheelBeamsNodesOutline,wheelOutline:icons$2.wheelOutline},secondary:{arrowLeftOutline:icons$2.arrowLeftOutline,arrowRightOutline:icons$2.arrowRightOutline,beamsNodesMessageOutline:icons$2.beamsNodesMessageOutline,beamsNodesOutline:icons$2.beamsNodesOutline,beamsNodesPlugOutline:icons$2.beamsNodesPlugOutline,BNGEcosystemOutline:icons$2.BNGEcosystemOutline,carFrontRouteOutline:icons$2.carFrontRouteOutline,carSensorsOutline:icons$2.carSensorsOutline,carSideRouteOutline:icons$2.carSideRouteOutline,cityOutline:icons$2.cityOutline,dialogOutline:icons$2.dialogOutline,documentSmileOutline:icons$2.documentSmileOutline,drivetrainOutline:icons$2.drivetrainOutline,electronicSchemeOutline:icons$2.electronicSchemeOutline,engineOutline:icons$2.engineOutline,gearTuningOutline:icons$2.gearTuningOutline,giftBoxOutline:icons$2.giftBoxOutline,lidarOutline:icons$2.lidarOutline,medalStarOutline:icons$2.medalStarOutline,megaphoneOutline:icons$2.megaphoneOutline,peopleOutline:icons$2.peopleOutline,personOutline:icons$2.personOutline,physicsOutline:icons$2.physicsOutline,playChainOutline:icons$2.playChainOutline,proximitySensorsOutline:icons$2.proximitySensorsOutline,qualityBadgeStarOutline:icons$2.qualityBadgeStarOutline,qualityBadgeVOutline:icons$2.qualityBadgeVOutline,simRigOutline:icons$2.simRigOutline,suspensionOutline:icons$2.suspensionOutline,teamOutline:icons$2.teamOutline,techLightBulbOutline01:icons$2.techLightBulbOutline01,techLightBulbOutline02:icons$2.techLightBulbOutline02,timeUnlockOutline:icons$2.timeUnlockOutline,timedLockOutline:icons$2.timedLockOutline,trafficOutline:icons$2.trafficOutline,voucherOutline:icons$2.voucherOutline,wheelBeamsNodesOutline:icons$2.wheelBeamsNodesOutline,wheelOutline:icons$2.wheelOutline},hazard:{danger:icons$2.danger,fireDiamond:icons$2.fireDiamond,test:icons$2.test},drop:{droplet:icons$2.droplet},liquid:{droplet:icons$2.droplet},nfpa704:{fireDiamond:icons$2.fireDiamond},"dry cargo":{rocks:icons$2.rocks},dry:{rocks:icons$2.rocks},editor:{scale:icons$2.scale},marker:{arrowsUp:icons$2.arrowsUp,bigDot:icons$2.bigDot,connectorBold:icons$2.connectorBold,cornerTopRight:icons$2.cornerTopRight,plusBold:icons$2.plusBold,puzzlePieceBold:icons$2.puzzlePieceBold},ribbon:{arrowsUp:icons$2.arrowsUp,bigDot:icons$2.bigDot,connectorBold:icons$2.connectorBold,cornerTopRight:icons$2.cornerTopRight,plusBold:icons$2.plusBold,puzzlePieceBold:icons$2.puzzlePieceBold},"content-props":{arrowsUp:icons$2.arrowsUp,bigDot:icons$2.bigDot,connectorBold:icons$2.connectorBold,cornerTopRight:icons$2.cornerTopRight,plusBold:icons$2.plusBold,puzzlePieceBold:icons$2.puzzlePieceBold},location:{locationDestination:icons$2.locationDestination,locationSource:icons$2.locationSource},shop:{shoppingCart:icons$2.shoppingCart},purchase:{shoppingCart:icons$2.shoppingCart},bus:{busTilted:icons$2.busTilted},destruction:{explosion:icons$2.explosion,fireExtinguisher:icons$2.fireExtinguisher,fire:icons$2.fire},"turn signals":{twoArrowsHorizontal:icons$2.twoArrowsHorizontal,twoArrowsVertical:icons$2.twoArrowsVertical},rally:{bridge:icons$2.bridge,bump:icons$2.bump,bumps:icons$2.bumps,caution:icons$2.caution,crest:icons$2.crest,doubleCaution:icons$2.doubleCaution,finish:icons$2.finish,jumpOverBump:icons$2.jumpOverBump,narrows:icons$2.narrows,pothole:icons$2.pothole,turn1:icons$2.turn1,turn2:icons$2.turn2,turn3:icons$2.turn3,turn4:icons$2.turn4,turn5:icons$2.turn5,turn6:icons$2.turn6,turnHp:icons$2.turnHp,turnSq:icons$2.turnSq,water:icons$2.water,rallyHelmet3To4:icons$2.rallyHelmet3To4,rallyHelmet:icons$2.rallyHelmet,tripleCaution:icons$2.tripleCaution},"pace notes":{bridge:icons$2.bridge,bump:icons$2.bump,bumps:icons$2.bumps,caution:icons$2.caution,crest:icons$2.crest,doubleCaution:icons$2.doubleCaution,finish:icons$2.finish,jumpOverBump:icons$2.jumpOverBump,narrows:icons$2.narrows,pothole:icons$2.pothole,turn1:icons$2.turn1,turn2:icons$2.turn2,turn3:icons$2.turn3,turn4:icons$2.turn4,turn5:icons$2.turn5,turn6:icons$2.turn6,turnHp:icons$2.turnHp,turnSq:icons$2.turnSq,water:icons$2.water,tripleCaution:icons$2.tripleCaution},directions:{bridge:icons$2.bridge,bump:icons$2.bump,bumps:icons$2.bumps,caution:icons$2.caution,crest:icons$2.crest,doubleCaution:icons$2.doubleCaution,finish:icons$2.finish,jumpOverBump:icons$2.jumpOverBump,narrows:icons$2.narrows,pothole:icons$2.pothole,turn1:icons$2.turn1,turn2:icons$2.turn2,turn3:icons$2.turn3,turn4:icons$2.turn4,turn5:icons$2.turn5,turn6:icons$2.turn6,turnHp:icons$2.turnHp,turnSq:icons$2.turnSq,water:icons$2.water,tripleCaution:icons$2.tripleCaution},"do not cut":{circleSlashed:icons$2.circleSlashed,scissorsSlashed:icons$2.scissorsSlashed},"no entry":{circleSlashed:icons$2.circleSlashed},cut:{scissors:icons$2.scissors},car:{airPuffRight1:icons$2.airPuffRight1,octagonBrick:icons$2.octagonBrick,octagon:icons$2.octagon,tireAirPuff:icons$2.tireAirPuff,tireDeflated:icons$2.tireDeflated},select:{carsChange:icons$2.carsChange,carsWrench:icons$2.carsWrench},physics:{forceFieldPull1:icons$2.forceFieldPull1,forceFieldPull2:icons$2.forceFieldPull2,forceFieldPull3:icons$2.forceFieldPull3,forceFieldPush1:icons$2.forceFieldPush1,forceFieldPush2:icons$2.forceFieldPush2,forceFieldPush3:icons$2.forceFieldPush3,pushUp:icons$2.pushUp,pushBackward:icons$2.pushBackward,pushDown:icons$2.pushDown,pushForward:icons$2.pushForward},field:{forceFieldPull1:icons$2.forceFieldPull1,forceFieldPull2:icons$2.forceFieldPull2,forceFieldPull3:icons$2.forceFieldPull3,forceFieldPush1:icons$2.forceFieldPush1,forceFieldPush2:icons$2.forceFieldPush2,forceFieldPush3:icons$2.forceFieldPush3},force:{forceFieldPull1:icons$2.forceFieldPull1,forceFieldPull2:icons$2.forceFieldPull2,forceFieldPull3:icons$2.forceFieldPull3,forceFieldPush1:icons$2.forceFieldPush1,forceFieldPush2:icons$2.forceFieldPush2,forceFieldPush3:icons$2.forceFieldPush3,pushUp:icons$2.pushUp,pushBackward:icons$2.pushBackward,pushDown:icons$2.pushDown,pushForward:icons$2.pushForward},"garage number":{garageNumber1:icons$2.garageNumber1,garageNumber2:icons$2.garageNumber2,garageNumber3:icons$2.garageNumber3,garageNumber4:icons$2.garageNumber4,garageNumber5:icons$2.garageNumber5,garageNumber6:icons$2.garageNumber6,garageNumber7:icons$2.garageNumber7,garageNumber8:icons$2.garageNumber8,garageNumber9:icons$2.garageNumber9},stop:{square:icons$2.square},roads:{trafficLight:icons$2.trafficLight},sign:{pedestrianRunning:icons$2.pedestrianRunning,pedestrianStanding:icons$2.pedestrianStanding},pedestrian:{pedestrianRunning:icons$2.pedestrianRunning,pedestrianStanding:icons$2.pedestrianStanding},actions:{seatArrowIn:icons$2.seatArrowIn,seatArrowOut:icons$2.seatArrowOut,seatVArrowIn:icons$2.seatVArrowIn,seatVArrowOut:icons$2.seatVArrowOut,vehicleArrowIn:icons$2.vehicleArrowIn,vehicleArrowOut:icons$2.vehicleArrowOut,leverFrontOperate:icons$2.leverFrontOperate,leverSideDown:icons$2.leverSideDown,leverSideOperate:icons$2.leverSideOperate,leverSideUp:icons$2.leverSideUp,seatArrowInLeft:icons$2.seatArrowInLeft,seatArrowOutLeft:icons$2.seatArrowOutLeft,seatVArrowInLeft:icons$2.seatVArrowInLeft,seatVArrowOutLeft:icons$2.seatVArrowOutLeft},outline:{beamCurrencyOutlineLarge:icons$2.beamCurrencyOutlineLarge},scenario:{flagOutlineLarge:icons$2.flagOutlineLarge},house:{houseWrenchRoof:icons$2.houseWrenchRoof,houseWrench:icons$2.houseWrench,house:icons$2.house},helmet:{rallyHelmet3To4:icons$2.rallyHelmet3To4,rallyHelmet:icons$2.rallyHelmet},racing:{rallyHelmet3To4:icons$2.rallyHelmet3To4,rallyHelmet:icons$2.rallyHelmet},"game mode":{rallyHelmet3To4:icons$2.rallyHelmet3To4,rallyHelmet:icons$2.rallyHelmet},offline:{globeSimpleNotSign:icons$2.globeSimpleNotSign},online:{globeSimplified:icons$2.globeSimplified},material:{cableSection:icons$2.cableSection,strapHook:icons$2.strapHook,strapRatchet:icons$2.strapRatchet},beam:{cableSection:icons$2.cableSection},strap:{cableSection:icons$2.cableSection,strapHook:icons$2.strapHook,strapRatchet:icons$2.strapRatchet},controls:{kbArrowsDown:icons$2.kbArrowsDown,kbArrowsLeftRight:icons$2.kbArrowsLeftRight,kbArrowsLeft:icons$2.kbArrowsLeft,kbArrowsOutline:icons$2.kbArrowsOutline,kbArrowsRight:icons$2.kbArrowsRight,kbArrowsSolid:icons$2.kbArrowsSolid,kbArrowsUpDown:icons$2.kbArrowsUpDown,kbArrowsUp:icons$2.kbArrowsUp},equipment:{auxUpDown:icons$2.auxUpDown,bucketArmUpDown:icons$2.bucketArmUpDown,bucketTilt:icons$2.bucketTilt,bucketArmDown:icons$2.bucketArmDown,bucketArmLevel:icons$2.bucketArmLevel,bucketArmUp:icons$2.bucketArmUp,bucketTiltDown:icons$2.bucketTiltDown,bucketTiltLevel:icons$2.bucketTiltLevel,bucketTiltUp:icons$2.bucketTiltUp,dumpBedDown:icons$2.dumpBedDown,dumpBedUpDown:icons$2.dumpBedUpDown,dumpBedUp:icons$2.dumpBedUp}}),getIconsWithTags=(...tagsToFind)=>Object.fromEntries(Object.entries(icons$2).filter(([name,{tags}])=>{for(let t of tagsToFind)if(!tags.includes(t))return!1;return!0})),icons=Object.freeze({...icons$2,_empty:{...icons$2.minus,invisible:!0}}),_sfc_main$369={__name:`bngIcon`,props:{type:{type:[String,Object],default:``},fallbackType:{type:String,default:`placeholder`},color:{type:String,default:`#fff`},asImage:{},image:String,externalImage:String},setup(__props){useCssVars(_ctx=>({v9bdaf084:__props.color}));let props=__props,hasImageSource=computed(()=>!!props.image||!!props.externalImage),imageSrcKey=computed(()=>props.image||props.externalImage||``),errorSrcKey=ref(``),isCurrentSrcErrored=computed(()=>!!imageSrcKey.value&&errorSrcKey.value===imageSrcKey.value),isGlyph=computed(()=>!!(!hasImageSource.value||isCurrentSrcErrored.value)),icon=computed(()=>{let res;switch(typeof props.type){case`object`:props.type.glyph&&(res=props.type);break;case`string`:props.type in icons&&(res=icons[props.type]);break}return res}),displayIcon=computed(()=>{let fallback=typeof props.fallbackType==`string`&&props.fallbackType in icons?icons[props.fallbackType]:icons.placeholder;return isCurrentSrcErrored.value||!icon.value&&!hasImageSource.value?fallback:icon.value}),iconGlyph=computed(()=>displayIcon.value?displayIcon.value.glyph:icons.placeholder.glyph),OFF_VALUES=[null,void 0,!1,`false`,0,`0`],asImage=computed(()=>OFF_VALUES.includes(props.asImage)?!1:props.asImage||!0),imageProps=computed(()=>{let res={bgColor:props.color,mask:[`mask`,`span`].includes(asImage.value)};return icon.value||(res.bgColor=`#f00`),asImage.value||(props.image?res.src=props.image:props.externalImage&&(res.externalSrc=props.externalImage)),res});function onImageError(){errorSrcKey.value=imageSrcKey.value}return(_ctx,_cache)=>isGlyph.value?(openBlock(),createElementBlock(`span`,{key:0,class:normalizeClass([`icon-base`,{"icon-not-found":displayIcon.value===unref(icons).placeholder,"icon-invisible":displayIcon.value&&displayIcon.value.invisible}])},toDisplayString(iconGlyph.value),3)):(openBlock(),createBlock(unref(bngImageAsset_default),mergeProps({key:1,class:`icon-img`},imageProps.value,{onError:onImageError}),null,16))}},bngIcon_default=__plugin_vue_export_helper_default(_sfc_main$369,[[`__scopeId`,`data-v-978d1732`]]),markerValidate=name=>name.endsWith(`Back`)&&Object.keys(iconsBySize[56]).includes(name.replace(/Back$/,`Front`))||name.endsWith(`Front`)&&Object.keys(iconsBySize[56]).includes(name.replace(/Front$/,`Back`)),markersList=Object.keys(iconsBySize[56]).filter(markerValidate).map(name=>name.replace(/Back$|Front$/,``)).sort((a$1,b)=>a$1.toLowerCase().localeCompare(b.toLowerCase())).reduce((res,name)=>res.includes(name)?res:[...res,name],[]);const markers=Object.fromEntries(markersList.map(i=>[i,i])),MARKER_POINTS={up:`up`,down:`down`,left:`left`,right:`right`};var _sfc_main$368={__name:`bngIconMarker`,props:{marker:{type:String,default:`circlePin`,validator:val=>!!markers[val]},type:[String,Object],color:[String,Array],point:{type:String,default:`down`,validator:val=>MARKER_POINTS[val]}},setup(__props){let props=__props,icon=computed(()=>({back:iconsBySize[56][props.marker+`Back`],front:iconsBySize[56][props.marker+`Front`]})),iconColour=computed(()=>({back:(Array.isArray(props.color)?props.color[0]:props.color)||`#fff`,front:(Array.isArray(props.color)?props.color[1]:null)||`#000`,icon:(Array.isArray(props.color)?props.color[2]||props.color[0]:props.color)||`#fff`}));return(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,{class:normalizeClass([`icon-marker`,`icon-point-${__props.point}`,`icon-type-${__props.marker}`])},[createVNode(unref(bngIcon_default),{class:`icon-back`,type:icon.value.back,color:iconColour.value.back},null,8,[`type`,`color`]),createVNode(unref(bngIcon_default),{class:`icon-front`,type:icon.value.front,color:iconColour.value.front},null,8,[`type`,`color`]),__props.type?(openBlock(),createBlock(unref(bngIcon_default),{key:0,class:`icon-inner`,type:__props.type,color:iconColour.value.icon},null,8,[`type`,`color`])):createCommentVNode(``,!0)],2))}},bngIconMarker_default=__plugin_vue_export_helper_default(_sfc_main$368,[[`__scopeId`,`data-v-1089accc`]]),_hoisted_1$322=[`src`],_sfc_main$367=Object.assign({inheritAttrs:!1},{__name:`bngImage`,props:{src:String,observe:Boolean},setup(__props){let props=__props,attrs=useAttrs(),observe=computed(()=>props.observe?`observe`:void 0),imgAttrs=computed(()=>showCanvas.value?{}:attrs),cvsAttrs=computed(()=>showCanvas.value?attrs:{}),elImg=ref(null),elCanvas=ref(null),showCanvas=ref(!1),imgSrc=ref(emptyImage),parentDataAttrs={};function setImage(elm,url,bmp){bmp?(showCanvas.value=!0,imgSrc.value=emptyImage,elCanvas.value.width=bmp.width,elCanvas.value.height=bmp.height,elCanvas.value.getContext(`2d`).drawImage(bmp,0,0),Object.entries(parentDataAttrs).forEach(([attr,value])=>{elCanvas.value.setAttribute(attr,value)})):(showCanvas.value=!1,imgSrc.value=url||`data:image/svg+xml,`)}return watch(()=>props.src,()=>{elImg.value&&(showCanvas.value=!1,imgSrc.value=emptyImage)}),watch(elImg,elm=>{if(elm){parentDataAttrs={};for(let attr of elm.parentElement.getAttributeNames())attr.startsWith(`data-v-`)&&(parentDataAttrs[attr]=elm.parentElement.getAttribute(attr));Object.entries(parentDataAttrs).forEach(([attr,value])=>{elm.setAttribute(attr,value),elCanvas.value&&elCanvas.value.setAttribute(attr,value)}),elm.__setImage=setImage}},{immediate:!0}),(_ctx,_cache)=>(openBlock(),createElementBlock(Fragment,null,[withDirectives(createBaseVNode(`img`,mergeProps({ref_key:`elImg`,ref:elImg},imgAttrs.value,{src:imgSrc.value,alt:``}),null,16,_hoisted_1$322),[[vShow,!showCanvas.value],[unref(BngLazyImage_default),{url:__props.src,callback:setImage},observe.value]]),withDirectives(createBaseVNode(`canvas`,mergeProps({ref_key:`elCanvas`,ref:elCanvas},cvsAttrs.value),null,16),[[vShow,showCanvas.value]])],64))}}),bngImage_default=_sfc_main$367,_hoisted_1$321=[`src`],_sfc_main$366={__name:`bngImageAsset`,props:{src:String,externalSrc:String,span:Boolean,mask:Boolean,bgColor:{type:String,default:`transparent`}},emits:[`error`,`load`],setup(__props,{emit:__emit}){useCssVars(_ctx=>({v0d0b2c1c:__props.bgColor}));let emit$1=__emit,props=__props,assetURL=computed(()=>props.src?getAssetURL(props.src):props.externalSrc);return(_ctx,_cache)=>__props.span||__props.mask?(openBlock(),createElementBlock(`span`,{key:0,class:`bng-image-asset`,style:normalizeStyle({[__props.mask?`maskImage`:`backgroundImage`]:`url(${assetURL.value})`})},[renderSlot(_ctx.$slots,`default`,{},void 0,!0)],4)):(openBlock(),createElementBlock(`img`,{key:1,class:`bng-image-asset`,src:assetURL.value,alt:``,onError:_cache[0]||=$event=>emit$1(`error`,$event),onLoad:_cache[1]||=$event=>emit$1(`load`,$event)},null,40,_hoisted_1$321))}},bngImageAsset_default=__plugin_vue_export_helper_default(_sfc_main$366,[[`__scopeId`,`data-v-27bf5bcc`]]),_hoisted_1$320={class:`bng-image-carousel`},_sfc_main$365={__name:`bngImageCarousel`,props:{images:{type:Array,required:!0},external:Boolean,current:[String,Number],transition:Boolean,transitionType:{type:String,default:`fade`},transitionTime:{type:Number,default:3e3},loop:{type:Boolean,default:!0},showNav:{type:Boolean,default:!0},parent:Object},setup(__props,{expose:__expose}){let props=__props,carousel=ref();__expose({carousel});let imageAssets=computed(()=>props.external?props.images.map(x=>`/`+x):props.images.map(getAssetURL)),carouselSettings=computed(()=>props.parent&&props.parent.carousel!==carousel?{parent:props.parent.carousel,transition:!1,transitionType:props.transitionType,loop:!1,transitionTime:props.transitionTime}:{current:props.current,transition:props.transition,transitionType:props.transitionType,transitionTime:props.transitionTime,loop:props.loop,showNav:props.showNav});return(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$320,[createVNode(unref(carousel_default),mergeProps({items:imageAssets.value,ref_key:`carousel`,ref:carousel},carouselSettings.value),{item:withCtx(({item})=>[createBaseVNode(`div`,{class:`image-slide`,style:normalizeStyle({"background-image":`url(${item})`})},null,4)]),_:1},16,[`items`])]))}},bngImageCarousel_default=__plugin_vue_export_helper_default(_sfc_main$365,[[`__scopeId`,`data-v-6b0c2d6b`]]),_hoisted_1$319=[`src`],_sfc_main$364={__name:`bngImageTile`,props:{oldIcon:String,src:String,externalSrc:String,label:String,image:String,externalImage:String,icon:[Object,String],ratio:{type:String,default:`4:3`}},setup(__props){let props=__props,slots=useSlots(),assetURL=computed(()=>props.externalSrc?props.externalSrc:getAssetURL(props.src));return(_ctx,_cache)=>(openBlock(),createBlock(unref(bngTile_default),{label:__props.label,backgroundImage:__props.image,backgroundExternalImage:__props.externalImage,ratio:__props.ratio},createSlots({default:withCtx(()=>[__props.oldIcon?(openBlock(),createBlock(unref(bngOldIcon_default),{key:0,class:`icon`,type:__props.oldIcon,span:``},null,8,[`type`])):createCommentVNode(``,!0),__props.icon?(openBlock(),createBlock(unref(bngIcon_default),{key:1,class:`glyph`,type:__props.icon},null,8,[`type`])):__props.src||__props.externalSrc?(openBlock(),createElementBlock(`img`,{key:2,class:`icon`,src:assetURL.value},null,8,_hoisted_1$319)):createCommentVNode(``,!0)]),_:2},[unref(slots).default?{name:`label`,fn:withCtx(()=>[renderSlot(_ctx.$slots,`default`,{},void 0,!0)]),key:`0`}:void 0]),1032,[`label`,`backgroundImage`,`backgroundExternalImage`,`ratio`]))}},bngImageTile_default=__plugin_vue_export_helper_default(_sfc_main$364,[[`__scopeId`,`data-v-d74a4ec4`]]),UNIQUE_CLEAN_VALUE=Symbol(`Unique 'clean' value from Dirty service code`);function useDirty(valueRef,emitter=void 0,setCallback=void 0){if(!valueRef)throw Error(`valueRef must be specified`);let hasInitValue=!1,initialValue=ref();function init$3(val){let type=typeof val;type===`undefined`||type===`number`&&isNaN(val)||(hasInitValue=!0,initialValue.value=val)}if(init$3(valueRef.value),!hasInitValue){let unwatch=watch(valueRef,newVal=>{init$3(newVal),hasInitValue&&unwatch()});onUnmounted(()=>!hasInitValue&&unwatch())}let dirty=computed(()=>{let isDirty$1=valueRef.value!==initialValue.value;return isDirty$1&&hasInitValue&&emitter&&emitter(`dirtied`,valueRef.value,initialValue.value),isDirty$1}),setDirty=state=>{let oldVal=initialValue.value,newVal=state?UNIQUE_CLEAN_VALUE:valueRef.value;initialValue.value=newVal,typeof setCallback==`function`&&setCallback(newVal,oldVal)};return{dirty,currentCleanValue:computed(()=>initialValue.value),setCleanValue:val=>initialValue.value=val,resetValue:()=>valueRef.value=initialValue.value,setDirty,markClean:()=>setDirty(!1)}}var _hoisted_1$318={class:`bng-input-wrapper`},_hoisted_2$259={class:`icons-input-wrapper`},_hoisted_3$226={class:`bng-input-container`},_hoisted_4$194={key:0,class:`prefix-suffix-container`},_hoisted_5$164={"data-testid":`prefix`},_hoisted_6$141={class:`bng-input-group`},_hoisted_7$123=[`value`,`type`,`min`,`max`,`step`,`maxlength`,`placeholder`,`disabled`,`readonly`],_hoisted_8$101={key:0,class:`number-actions`},_hoisted_9$91={key:1,class:`floating-label`,"data-testid":`floating-label`},_hoisted_10$79={key:2,class:`error-message`},_hoisted_11$71={key:1,class:`prefix-suffix-container`},_hoisted_12$59={"data-testid":`suffix`},_hoisted_13$51={key:2,class:`trailing-icon`},_sfc_main$363={__name:`bngInput`,props:{modelValue:[String,Number],type:{type:String,default:`text`,validator(value){return[`text`,`number`].includes(value)}},min:[Number,String],max:[Number,String],step:{type:[Number,String],default:1},decimals:Number,maxlength:[Number,String],readonly:Boolean,floatingLabel:String,externalLabel:String,placeholder:String,initialValue:String,leadingIcon:Object,prefix:String,suffix:String,trailingIcon:Object,trailingIconOutside:Boolean,disabled:Boolean,validate:Function,errorMessage:String},emits:[`update:modelValue`,`valueChanged`,`change`,`focus`,`blur`],setup(__props,{expose:__expose,emit:__emit}){let props=__props,emitter=__emit,input=ref(),value=ref(props.initialValue||props.modelValue),isInputFieldFocused=ref(!1),numMin=computed(()=>props.type===`number`?+props.min:null),numMax=computed(()=>props.type===`number`?+props.max:null),numStep=computed(()=>props.type===`number`?roundDec(+props.step,15):null),numDecimals=computed(()=>props.type===`number`?props.decimals:null),charMax=computed(()=>props.type===`text`?props.maxlength:null),hasValue=computed(()=>value.value!==``&&value.value!==void 0&&value.value!==null),hasError=computed(()=>typeof props.validate==`function`?!props.validate(value.value):!1);if(props.type===`number`){let type=typeof value.value;type===`string`&&/^\d+(?:\.?\d+)?$/.test(value.value)?value.value=+value.value:type!==`number`&&(value.value=0),numMin.value>numMax.value&&console.error(`BngInput: min cannot be greater than max`)}__expose(useDirty(value));let lastNotify;function notify(val){props.readonly||lastNotify===val||(lastNotify=val,emitter(`update:modelValue`,val),emitter(`valueChanged`,val),emitter(`change`,val))}watch(()=>props.modelValue,newVal=>{props.type===`number`&&(newVal=numClamp(newVal)),value.value=newVal,lastNotify=newVal},{immediate:!0});function numClamp(val){return isNaN(val)&&(val=0),typeof numDecimals.value==`number`&&!isNaN(numDecimals.value)?val=roundDec(val,numDecimals.value):typeof numStep.value==`number`&&!isNaN(numStep.value)&&(val=roundDecSample(val,numStep.value)),typeof numMin.value==`number`&&!isNaN(numMin.value)&&valnumMax.value&&(val=numMax.value),val}function increment(by){let val=numClamp(+value.value+by);value.value!==val&&(value.value=val,input.value=val,notify(val))}let onArrowUpClicked=()=>increment(numStep.value),onArrowDownClicked=()=>increment(-numStep.value);function onValueChanged($event){let val=$event.target.value;if(props.type===`number`){val=+val;let prev=val;val=numClamp(val),val!==prev&&(input.value=val)}value.value=val,notify(val)}function onInputFieldFocusIn(){isInputFieldFocused.value=!0,emitter(`focus`)}function onInputFieldFocusOut(){isInputFieldFocused.value=!1,emitter(`blur`),notify(value.value)}return(_ctx,_cache)=>withDirectives((openBlock(),createElementBlock(`div`,_hoisted_1$318,[__props.externalLabel?(openBlock(),createElementBlock(`span`,{key:0,class:`external-label`,style:normalizeStyle([__props.leadingIcon?{"margin-left":`3em`}:{}]),"data-testid":`external-label`},toDisplayString(__props.externalLabel),5)):createCommentVNode(``,!0),createBaseVNode(`div`,_hoisted_2$259,[__props.leadingIcon?(openBlock(),createBlock(unref(bngIcon_default),{key:0,class:`outside-icon`,type:__props.leadingIcon,"data-testid":`leading-icon`},null,8,[`type`])):createCommentVNode(``,!0),createBaseVNode(`div`,{tabindex:`disabled ? -1 : 0`,class:normalizeClass([`bng-highlight-container`,{"bng-input-focused":isInputFieldFocused.value,"has-error":hasError.value}]),onKeydown:withKeys(onInputFieldFocusOut,[`enter`])},[createBaseVNode(`div`,_hoisted_3$226,[__props.prefix?(openBlock(),createElementBlock(`span`,_hoisted_4$194,[createBaseVNode(`span`,_hoisted_5$164,toDisplayString(__props.prefix),1)])):createCommentVNode(``,!0),createBaseVNode(`div`,_hoisted_6$141,[withDirectives(createBaseVNode(`input`,{ref_key:`input`,ref:input,class:normalizeClass([`bng-input`,{"bng-input-empty":!hasValue.value,"bng-input-error":hasError.value}]),"data-testid":`input`,value:value.value,type:__props.type,min:numMin.value,max:numMax.value,step:numStep.value,maxlength:charMax.value,onInput:onValueChanged,onFocusin:onInputFieldFocusIn,onFocusout:onInputFieldFocusOut,placeholder:__props.placeholder,disabled:__props.disabled,readonly:__props.readonly},null,42,_hoisted_7$123),[[unref(BngTextInput_default)]]),__props.type===`number`?(openBlock(),createElementBlock(`div`,_hoisted_8$101,[withDirectives(createVNode(unref(bngIcon_default),{type:unref(iconsByTag).arrow.arrowLargeUp,class:normalizeClass([{"number-action-disabled":__props.readonly},`number-action up-action`])},null,8,[`type`,`class`]),[[unref(BngClick_default),{clickCallback:onArrowUpClicked,holdCallback:onArrowUpClicked}]]),withDirectives(createVNode(unref(bngIcon_default),{type:unref(iconsByTag).arrow.arrowLargeDown,class:normalizeClass([`number-action down-action`,{"number-action-disabled":__props.readonly}])},null,8,[`type`,`class`]),[[unref(BngClick_default),{clickCallback:onArrowDownClicked,holdCallback:onArrowDownClicked}]])])):createCommentVNode(``,!0),__props.floatingLabel?(openBlock(),createElementBlock(`span`,_hoisted_9$91,toDisplayString(__props.floatingLabel),1)):createCommentVNode(``,!0),hasError.value&&__props.errorMessage?(openBlock(),createElementBlock(`span`,_hoisted_10$79,toDisplayString(__props.errorMessage),1)):createCommentVNode(``,!0),_cache[0]||=createBaseVNode(`span`,{class:`input-border`},null,-1)]),__props.suffix?(openBlock(),createElementBlock(`span`,_hoisted_11$71,[createBaseVNode(`span`,_hoisted_12$59,toDisplayString(__props.suffix),1)])):createCommentVNode(``,!0),__props.trailingIcon&&!__props.trailingIconOutside?(openBlock(),createElementBlock(`span`,_hoisted_13$51,[createVNode(unref(bngIcon_default),{type:__props.trailingIcon,class:`input-icon`,"data-testid":`trailing-icon`},null,8,[`type`])])):createCommentVNode(``,!0)])],34),__props.trailingIcon&&__props.trailingIconOutside?(openBlock(),createBlock(unref(bngIcon_default),{key:1,type:__props.trailingIcon,class:`outside-icon`,"data-testid":`external-trailing-icon`},null,8,[`type`])):createCommentVNode(``,!0)])])),[[unref(BngDisabled_default),__props.disabled]])}},bngInput_default=__plugin_vue_export_helper_default(_sfc_main$363,[[`__scopeId`,`data-v-d6c70b5c`]]),_hoisted_1$317=[`readonly`,`disabled`,`placeholder`,`maxlength`],_hoisted_2$258={key:0,class:`floating-label`},_hoisted_3$225={key:7,class:`external-button`},_hoisted_4$193={key:8,class:`error-message`};const INPUT_TYPES={text:`text`,number:`number`},STEP_ICON_TYPES={arrowUpDown:`arrowUpDown`,arrowLeftRight:`arrowLeftRight`,plusMinus:`plusMinus`};var STEP_ICON_TYPES_MAP={[STEP_ICON_TYPES.arrowUpDown]:{up:`arrowSmallUp`,down:`arrowSmallDown`},[STEP_ICON_TYPES.arrowLeftRight]:{up:`arrowSmallRight`,down:`arrowSmallLeft`},[STEP_ICON_TYPES.plusMinus]:{up:`plus`,down:`minus`}},NUMBER_PATTERN=/^\d+(\.d+)?$/,NUMBER_INPUT_KEYS=/^[0-9\.\-]$/,ERROR_TYPES={invalidformat:`invalidformat`,outofrange:`outofrange`,required:`required`,custom:`custom`},ERROR_MESSAGES={[ERROR_TYPES.invalidformat]:`Invalid format`,[ERROR_TYPES.outofrange]:`Value must be between {min} and {max}`,[`${ERROR_TYPES.outofrange}-min`]:`Value must be greater than {min}`,[`${ERROR_TYPES.outofrange}-max`]:`Value must be less than {max}`,[ERROR_TYPES.required]:`Value is required`},ALLOW_DEFAULT_BEHAVIOR_KEYS=[`ArrowLeft`,`ArrowRight`,`ArrowUp`,`ArrowDown`,`Backspace`,`Delete`],NUMBER_INPUT_MODES={spinner:`spinner`,arrowKeys:`arrowKeys`,uinav:`uinav`},_sfc_main$362={__name:`bngInputNew`,props:{modelValue:{type:[Number,String],default:void 0},value:{type:[Number,String],default:void 0},type:{type:String,default:INPUT_TYPES.text,validator(value){return Object.keys(INPUT_TYPES).includes(value)}},showExternalButton:{type:Boolean,default:!0},floatingLabel:[Boolean,String],externalButtonFn:Function,externalLabel:String,label:String,prefix:String,suffix:String,leadingIcon:Object,trailingIcon:Object,maxLength:{type:[Number,String],default:null,validator(value){return value===null?!0:typeof parseInt(value)==`number`&&parseInt(value)>=0}},readonly:Boolean,disabled:Boolean,required:Boolean,placeholder:String,validate:Function,errorMessage:String,min:{type:Number,default:void 0},max:{type:Number,default:void 0},step:{type:Number,default:1},stepIconType:{type:String,default:STEP_ICON_TYPES.arrowUpDown,validator(value){return Object.keys(STEP_ICON_TYPES).includes(value)}},noStepBindings:Boolean},emits:[`update:modelValue`,`change`,`error`,`blur`,`focus`,`valueChanged`],setup(__props,{expose:__expose,emit:__emit}){let props=__props,emit$1=__emit,slots=useSlots(),{showIfController}=storeToRefs(controls_default()),input=ref(null),scopeActivated=ref(!1),rawValue=ref(null),validationState=ref(null),isProgrammaticChange=ref(!1),numberInputState=reactive({inputType:null,isUpActive:!1,isDownActive:!1}),value=computed({get:()=>props.modelValue,set:emitChange}),isEmptyRawValue=computed(()=>isEmpty(rawValue.value)),inputStyle=computed(()=>({"max-width":props.maxLength?`${props.maxLength}ch`:`initial`})),stepIcons=computed(()=>STEP_ICON_TYPES_MAP[props.stepIconType]),exposed=useDirty(value);exposed.scopeActivated=scopeActivated,__expose(exposed),watch(()=>rawValue.value,newValue=>{if(isProgrammaticChange.value){isProgrammaticChange.value=!1;return}let res=validate(newValue);validationState.value=res,rawValue.value!=props.modelValue&&(res.valid||res.error!==ERROR_TYPES.invalidformat)&&(value.value=res.value)}),watch(()=>props.modelValue,modelValue=>{modelValue!=rawValue.value&&(isProgrammaticChange.value=!0,rawValue.value=isEmpty(modelValue)?null:String(modelValue))},{immediate:!0}),watch(()=>props.value,()=>{props.modelValue===void 0&&props.value!=rawValue.value&&(isProgrammaticChange.value=!0,rawValue.value=props.value)},{immediate:!0}),onUnmounted(()=>{resetInputState.cancel()});let activateInput=()=>{props.disabled||props.readonly||nextTick(()=>input.value.focus())},canActivateScope=()=>!props.readonly&&!props.disabled,externalButtonFn=()=>{props.externalButtonFn?props.externalButtonFn():props.type===INPUT_TYPES.number?rawValue.value=props.min||0:rawValue.value=null,activateInput()};function onScopeActivated(event){scopeActivated.value=!0}function onScopeDeactivated(event){scopeActivated.value=!1,nextTick(()=>cleanValue())}let resetInputState=debounce(()=>{numberInputState.inputType=null,numberInputState.isUpActive=!1,numberInputState.isDownActive=!1},150);function onUINavChangeValue(dir){numberInputState.inputType&&numberInputState.inputType!==NUMBER_INPUT_MODES.uinav||(numberInputState.inputType=NUMBER_INPUT_MODES.uinav,updateNumValue(dir),resetInputState())}function onArrowKeysChangeValue(dir){numberInputState.inputType&&numberInputState.inputType!==NUMBER_INPUT_MODES.arrowKeys||(numberInputState.inputType=NUMBER_INPUT_MODES.arrowKeys,updateNumValue(dir),resetInputState())}function onSpinnerChangeValue(dir){numberInputState.inputType&&numberInputState.inputType!==NUMBER_INPUT_MODES.spinner||(numberInputState.inputType=NUMBER_INPUT_MODES.spinner,updateNumValue(dir),resetInputState())}function updateNumValue(dir){props.type!==INPUT_TYPES.number||props.disabled||props.readonly||(dir===1?(numberInputState.isUpActive=!0,changeNumValue(props.step)):(numberInputState.isDownActive=!0,changeNumValue(-props.step)))}function onEnterDown(event){event.preventDefault(),scopeActivated.value=!1}function onKeyDown(event){if(ALLOW_DEFAULT_BEHAVIOR_KEYS.includes(event.key))return;event.key===`Enter`&&event.preventDefault();let rawValueString=typeof rawValue.value!=`string`&&!isNullOrUndefined(rawValue.value)?rawValue.value.toString():rawValue.value;props.type===INPUT_TYPES.number&&(!NUMBER_INPUT_KEYS.test(event.key)||event.key===`.`&&(isNullOrUndefined(rawValueString)||rawValueString.includes(`.`))||event.key===`.`&&!NUMBER_PATTERN.test(rawValueString))&&event.preventDefault()}function changeNumValue(diff){if(props.type!==INPUT_TYPES.number)return;if(isEmpty(rawValue.value)){diff<0?rawValue.value=isNullOrUndefined(props.max)?0:props.max:rawValue.value=isNullOrUndefined(props.min)?0:props.min;return}let{valid,value:validatedValue,error}=validate(rawValue.value);if(!valid&&error!==ERROR_TYPES.outofrange){rawValue.value=0;return}let decimalTokens=props.step.toString().split(`.`),stepDecimalPlaces=decimalTokens.length>1?decimalTokens[1].length:0,newValue=Number((validatedValue+diff).toFixed(stepDecimalPlaces)),{valid:isValidRange}=validateRange(newValue);(isValidRange||diff<0&&newValue>=props.max||diff>0&&newValue<=props.min)&&(rawValue.value=newValue)}function cleanValue(){if(!isNullOrUndefined(rawValue.value)&&props.type===INPUT_TYPES.number){let rawValueString=typeof rawValue.value==`string`?rawValue.value:rawValue.value.toString();rawValueString.endsWith(`.`)&&(rawValue.value=rawValueString.slice(0,-1))}}function validate(value$1){let valid=!0,newValue=value$1,errorMessage=null;if(isEmpty(value$1)&&props.required)return{valid:!1,error:ERROR_TYPES.required};if(isEmpty(value$1)&&props.type===INPUT_TYPES.number)return{valid:!0,value:void 0};if(props.type===INPUT_TYPES.number&&typeof value$1==`string`&&(newValue=value$1.includes(`.`)?parseFloat(value$1):parseInt(value$1),isNaN(newValue)))return{valid:!1,error:ERROR_TYPES.invalidformat};if(props.type===INPUT_TYPES.number)return{...validateRange(newValue),value:newValue};if(props.validate){let res=props.validate(value$1);typeof res==`boolean`?(valid=res,errorMessage=props.errorMessage):typeof res==`object`&&(`valid`in res&&console.warn("`validate` function must return a boolean `valid` property. Ignoring validation result..."),valid=res.valid||!0,valid||(errorMessage=`errorMessage`in res?res.errorMessage:props.errorMessage))}return{valid,value:newValue,errorMessage}}function validateRange(value$1){let lessThanMin=props.min&&value$1props.max,valid=!0,errorMessage=null;return!isNullOrUndefined(props.min)&&!isNullOrUndefined(props.max)&&(lessThanMin||greaterThanMax)?(errorMessage=ERROR_MESSAGES[ERROR_TYPES.outofrange].replace(`{min}`,props.min).replace(`{max}`,props.max),valid=!1):lessThanMin?(errorMessage=ERROR_MESSAGES[`${ERROR_TYPES.outofrange}-min`].replace(`{min}`,props.min),valid=!1):greaterThanMax&&(errorMessage=ERROR_MESSAGES[`${ERROR_TYPES.outofrange}-max`].replace(`{max}`,props.max),valid=!1),{valid,error:valid?null:ERROR_TYPES.outofrange,errorMessage}}function isEmpty(val){return val==null||val===``}function isNullOrUndefined(val){return val==null}function emitChange(value$1){emit$1(`update:modelValue`,value$1),emit$1(`change`,value$1),emit$1(`valueChanged`,value$1)}return(_ctx,_cache)=>withDirectives((openBlock(),createElementBlock(`div`,{class:normalizeClass([{"has-value":!isEmptyRawValue.value,"bng-input-readonly":__props.readonly,"bng-input-invalid":validationState.value&&!validationState.value.valid},`bng-input`]),onActivate:onScopeActivated,onDeactivate:onScopeDeactivated},[(__props.label||__props.externalLabel||unref(slots).label)&&!__props.floatingLabel?(openBlock(),createElementBlock(`label`,{key:0,class:`external-label`,onClick:activateInput,onMousedown:_cache[0]||=withModifiers(()=>{},[`prevent`])},[renderSlot(_ctx.$slots,`label`,{},()=>[createTextVNode(toDisplayString(__props.label||__props.externalLabel),1)],!0)],32)):createCommentVNode(``,!0),__props.leadingIcon||unref(slots).leadingIcon?(openBlock(),createElementBlock(`span`,{key:1,class:`leading-icon`,onClick:activateInput,onMousedown:_cache[1]||=withModifiers(()=>{},[`prevent`])},[renderSlot(_ctx.$slots,`leading-icon`,{},()=>[createVNode(unref(bngIcon_default),{type:__props.leadingIcon},null,8,[`type`])],!0)],32)):createCommentVNode(``,!0),__props.type===INPUT_TYPES.number&&!__props.readonly&&!__props.disabled?(openBlock(),createElementBlock(`span`,{key:2,class:normalizeClass([{"spinner-active":numberInputState.isDownActive},`input-spinner input-spinner-down`]),onMousedown:_cache[2]||=withModifiers(()=>{},[`prevent`])},[renderSlot(_ctx.$slots,`spinner-down`,{changeValue:()=>onSpinnerChangeValue(-1)},()=>[withDirectives((openBlock(),createBlock(unref(bngButton_default),{"bng-no-nav":`true`,accent:`text`},{default:withCtx(()=>[__props.noStepBindings?createCommentVNode(``,!0):(openBlock(),createBlock(unref(bngBinding_default),{key:0,controller:``,uiEvent:`focus_d`})),!unref(showIfController)||__props.noStepBindings?(openBlock(),createBlock(unref(bngIcon_default),{key:1,type:stepIcons.value.down},null,8,[`type`])):createCommentVNode(``,!0)]),_:1})),[[unref(BngClick_default),{clickCallback:()=>onSpinnerChangeValue(-1),holdCallback:()=>onSpinnerChangeValue(-1)}]])],!0)],34)):createCommentVNode(``,!0),__props.prefix||unref(slots).prefix?(openBlock(),createElementBlock(`span`,{key:3,class:`prefix`,onClick:activateInput,onMousedown:_cache[3]||=withModifiers(()=>{},[`prevent`])},[renderSlot(_ctx.$slots,`prefix`,{},()=>[createTextVNode(toDisplayString(__props.prefix),1)],!0)],32)):createCommentVNode(``,!0),createBaseVNode(`div`,{class:`input-container`,style:normalizeStyle(inputStyle.value)},[withDirectives(createBaseVNode(`input`,{ref_key:`input`,ref:input,"onUpdate:modelValue":_cache[4]||=$event=>rawValue.value=$event,readonly:__props.readonly,disabled:__props.disabled,placeholder:__props.placeholder,maxlength:__props.maxLength,type:`text`,onFocusin:_cache[5]||=$event=>_ctx.$emit(`focus`),onFocusout:_cache[6]||=$event=>_ctx.$emit(`blur`),onKeydown:[_cache[7]||=withKeys($event=>onArrowKeysChangeValue(1),[`arrow-up`]),_cache[8]||=withKeys($event=>onArrowKeysChangeValue(-1),[`arrow-down`]),withKeys(onEnterDown,[`enter`]),onKeyDown]},null,40,_hoisted_1$317),[[unref(BngTextInput_default)],[unref(BngOnUiNavFocus_default),dir=>onUINavChangeValue(dir),`vertical`,{repeat:!0}],[vModelText,rawValue.value]]),__props.label&&__props.floatingLabel||typeof __props.floatingLabel==`string`||unref(slots).label?(openBlock(),createElementBlock(`label`,_hoisted_2$258,[renderSlot(_ctx.$slots,`label`,{},()=>[createTextVNode(toDisplayString(__props.label||__props.floatingLabel),1)],!0)])):createCommentVNode(``,!0)],4),__props.suffix||unref(slots).suffix?(openBlock(),createElementBlock(`span`,{key:4,class:`suffix`,onClick:activateInput,onMousedown:_cache[9]||=withModifiers(()=>{},[`prevent`])},[renderSlot(_ctx.$slots,`suffix`,{},()=>[createTextVNode(toDisplayString(__props.suffix),1)],!0)],32)):createCommentVNode(``,!0),__props.trailingIcon||unref(slots).trailingIcon?(openBlock(),createElementBlock(`span`,{key:5,class:`trailing-icon`,onClick:activateInput,onMousedown:_cache[10]||=withModifiers(()=>{},[`prevent`])},[renderSlot(_ctx.$slots,`trailing-icon`,{},()=>[createVNode(unref(bngIcon_default),{type:__props.trailingIcon},null,8,[`type`])],!0)],32)):createCommentVNode(``,!0),__props.type===INPUT_TYPES.number&&!__props.readonly&&!__props.disabled?(openBlock(),createElementBlock(`span`,{key:6,class:normalizeClass([{"spinner-active":numberInputState.isUpActive},`input-spinner input-spinner-up`]),onMousedown:_cache[11]||=withModifiers(()=>{},[`prevent`])},[renderSlot(_ctx.$slots,`spinner-up`,{changeValue:()=>onSpinnerChangeValue(1)},()=>[withDirectives((openBlock(),createBlock(unref(bngButton_default),{"bng-no-nav":`true`,accent:`text`},{default:withCtx(()=>[__props.noStepBindings?createCommentVNode(``,!0):(openBlock(),createBlock(unref(bngBinding_default),{key:0,controller:``,uiEvent:`focus_u`})),!unref(showIfController)||__props.noStepBindings?(openBlock(),createBlock(unref(bngIcon_default),{key:1,type:stepIcons.value.up},null,8,[`type`])):createCommentVNode(``,!0)]),_:1})),[[unref(BngClick_default),{clickCallback:()=>onSpinnerChangeValue(1),holdCallback:()=>onSpinnerChangeValue(1)}]])],!0)],34)):createCommentVNode(``,!0),__props.showExternalButton?(openBlock(),createElementBlock(`span`,_hoisted_3$225,[renderSlot(_ctx.$slots,`external-button`,{externalButtonFn},()=>[__props.readonly?createCommentVNode(``,!0):withDirectives((openBlock(),createBlock(unref(bngButton_default),{key:0,icon:unref(icons).mathMultiply,disabled:__props.disabled,accent:`attention`,onClick:externalButtonFn,onMousedown:_cache[12]||=withModifiers(()=>{},[`prevent`])},null,8,[`icon`,`disabled`])),[[unref(BngOnUiNav_default),void 0,`ok`,{asMouse:!0,focusRequired:!0}],[unref(BngDisabled_default),isEmptyRawValue.value]])],!0)])):createCommentVNode(``,!0),validationState.value&&!validationState.value.valid&&validationState.value.errorMessage||unref(slots).errorMessage?(openBlock(),createElementBlock(`span`,_hoisted_4$193,[renderSlot(_ctx.$slots,`error-message`,{},()=>[createTextVNode(toDisplayString(validationState.value.errorMessage),1)],!0)])):createCommentVNode(``,!0)],34)),[[unref(BngDisabled_default),__props.disabled],[unref(BngScopedNav_default),{activated:scopeActivated.value,canActivate:canActivateScope}]])}},bngInputNew_default=__plugin_vue_export_helper_default(_sfc_main$362,[[`__scopeId`,`data-v-bb1297d5`]]),_hoisted_1$316={class:`list-container`},_hoisted_2$257={key:0,class:`list-toolbar`},_hoisted_3$224={key:1},_hoisted_4$192={class:`list-layout-toggle`};const LIST_LAYOUTS={DEFAULT:`tiles`,TILES:`tiles`,LIST:`list`,RIBBON:`ribbon`};var _sfc_main$361={__name:`bngList`,props:{path:Array,pathLimit:{type:[Number,String],default:3},pathTarget:Object,layoutSelector:Boolean,layoutSelectorTarget:Object,layout:{type:String,default:LIST_LAYOUTS.DEFAULT,validator:val=>Object.values(LIST_LAYOUTS).includes(val)},big:Boolean,immediate:Boolean,keepAlive:[Boolean,Number],tileSizeCalc:Function,tileWidth:Number,tileHeight:Number,tileMargin:Number,targetWidth:Number,targetHeight:Number,targetMargin:Number,titleWidth:Number,titleHeight:Number,titleMargin:Number,targetTitleWidth:Number,targetTitleHeight:Number,targetTitleMargin:Number,noBackground:Boolean},emits:[`layoutChange`,`pathClick`],setup(__props,{expose:__expose,emit:__emit}){let emit$1=__emit,props=__props,elPath=ref();__expose({navBack(){elPath.value&&elPath.value.navBack()},navTo(item){elPath.value&&elPath.value.navTo(item)},async scrollToIndex(index=0){if(!bigmode.enabled){let hasPosObserver=(elCont.value.children||[])[0]?.classList.contains(`bng-pos-observer`),elm=(elCont.value.children||[])[index+(hasPosObserver?1:0)];return elm&&elm.scrollIntoView(),elm}let big=await getBigProps(void 0,index);if(!big)return null;let horizontal=layoutSelected.value===LIST_LAYOUTS.RIBBON,containerSize=horizontal?contWidth:contHeight,rowIndex=layoutCache.itemToRow.get(index),itemRowPos=layoutCache.rows[rowIndex]?.pos||big.position,itemRowSize=layoutCache.rows[rowIndex]?.size||(horizontal?tileWidth.value:tileHeight.value),centeredPos=itemRowPos-containerSize/2+itemRowSize/2;scrollPos.value=Math.max(0,centeredPos),horizontal?elCont.value.scrollLeft=scrollPos.value:elCont.value.scrollTop=scrollPos.value,await updSkeleton();let itm=items$2.value[index];return itm?itm.getElement?.()||itm.el||itm:null},refresh(){tileWidth.value=0,tileHeight.value=0,titleWidth.value=0,titleHeight.value=0,tileProps=getItemProps(items$2.value,!1),titleProps=getItemProps(items$2.value,!0),tileProps&&(tileMargin.value=validNum(tileProps.margin)?tileProps.margin:defTileMargin*fontSize,calcTiles()),titleProps&&(titleMargin.value=validNum(titleProps.margin)?titleProps.margin:defTitleMargin*fontSize,calcTitles()),invalidateLayoutCache(),nextTick(()=>{bigmode.enabled&&contWidth>0&&contHeight>0&&(buildLayoutCache(),calcBig(),updSkeleton())})}});let defFontSize=16,defTileWidth=10,defTileHeight=5,defTileMargin=.2,defTitleWidth=10,defTitleHeight=2.5,defTitleMargin=.2,layoutSelected=ref(props.layout);watch(()=>props.layout,()=>layoutSelected.value=props.layout||LIST_LAYOUTS.DEFAULT),watch(()=>layoutSelected.value,val=>{emit$1(`layoutChange`,val),invalidateLayoutCache(),updSize()});let toolbar=computed(()=>{let res={path:props.path&&props.path.length>0,layout:props.layoutSelector};return res.enabled=res.path||res.layout,res.show=res.enabled&&(res.path&&!props.pathTarget||res.layout&&!props.layoutSelectorTarget),res}),slots=useSlots(),elCont=ref(),elSize=ref(),elSkeleton=ref(),tileWidth=ref(0),tileHeight=ref(0),tileMargin=ref(0),titleWidth=ref(0),titleHeight=ref(0),titleMargin=ref(0),scrollPos=ref(0),skeletonItems=ref([]),processing=computed(()=>bigmode.enabled&&(bigmode.initial||layoutCache.building)),contWidth=0,contHeight=0,fontSize=16,skeletonShown=!1,warnShown=!1,listItemsStyle=computed(()=>bigmode.enabled?{transform:`translate${layoutSelected.value===LIST_LAYOUTS.RIBBON?`X`:`Y`}(${bigmode.position}px)`}:void 0),tileProps=null,titleProps=null,bigmode=reactive({enabled:!1,initial:!0,debounce:500,skeleton:!0,layouts:[],getPos:{[LIST_LAYOUTS.TILES]:()=>elCont.value?.scrollTop||0,[LIST_LAYOUTS.LIST]:()=>elCont.value?.scrollTop||0,[LIST_LAYOUTS.RIBBON]:()=>elCont.value?.scrollLeft||0},overflow:2,skeletonOverflow:2,first:0,last:0,perRow:1,items:[],position:0,full:0,size:0});bigmode.layouts=Object.keys(bigmode.getPos);let layoutCache=reactive({version:0,building:!1,valid:!1,itemCount:0,totalSize:0,rows:[],itemToRow:new Map,rowPositions:[]}),items$2=ref([]),itemsView=ref([]),itemsShown=ref(new Set);watch(()=>props.immediate,val=>{val?(bigmode._skeleton=bigmode.skeleton,bigmode._debounce=bigmode.debounce,bigmode.skeleton=!1,bigmode.debounce=0):(bigmode._skeleton&&(bigmode.skeleton=bigmode._skeleton),bigmode._debounce&&(bigmode.debounce=bigmode._debounce))},{immediate:!0}),watch([()=>slots.default?.(),()=>props.big,()=>layoutSelected.value],()=>{let res=slots.default?slots.default():[];bigmode.enabled=props.big&&bigmode.layouts.includes(layoutSelected.value),bigmode.enabled&&(bigmode.initial=!0,res=getItems(res)),res=res.map((item,key)=>({...item,key})),items$2.value=res,bigmode.enabled||(itemsView.value=res),itemsShown.value.clear(),nextTick(()=>{tileProps=getItemProps(res,!1),titleProps=getItemProps(res,!0),invalidateLayoutCache(),updSize(),updSkeleton()})},{immediate:!0});function getItems(vnodes,_level=0){let res=[];for(let vnode of vnodes)switch(typeof vnode.type){case`object`:{let isTitle=vnode.props&&`bng-list-title`in vnode.props,item={...vnode};isTitle&&(item.isBngListTitle=!0),res.push(item);break}case`symbol`:if(_level===20)return logger_default.debug(`BngList reached max level of nested Vue fragments`),[];res.push(...getItems(vnode.children,_level+1));break}return res}function findItem(vnode,_level=0){let res=null;switch(typeof vnode.type){case`object`:res={el:vnode.el,width:vnode.type.width,height:vnode.type.height,margin:vnode.type.margin};break;case`string`:vnode.el instanceof HTMLElement&&(res={el:vnode.el});break;case`symbol`:if(vnode.children.length>0){if(_level===20)return null;res=findItem(vnode.children[0],++_level)}break}return res}function getItemProps(vnodes,title=!1){if(vnodes.length===0)return null;let sampleItem=vnodes.find(vnode=>title&&vnode.isBngListTitle||!title&&!vnode.isBngListTitle);if(!sampleItem)return null;let res=findItem(sampleItem);if(!res)return null;let valid={width:validNum(res.width),height:validNum(res.height),margin:validNum(res.margin)},fontSize$1,targetWidth=0,targetHeight=0,targetMargin=0;if(!title&&props.tileSizeCalc)try{fontSize$1||=getFontSize();let size$3=props.tileSizeCalc({contWidth,contHeight,fontSize:fontSize$1,layout:layoutSelected.value});if(size$3&&typeof size$3==`object`){let isPx=size$3.unit===`px`;targetWidth=isPx?size$3.width/fontSize$1:size$3.width,targetHeight=isPx?size$3.height/fontSize$1:size$3.height,targetMargin=isPx?size$3.margin/fontSize$1:size$3.margin}}catch(err){logger_default.warn(`BngList: tileSizeCalc function error:`,err)}targetWidth||=title?props.titleWidth||props.targetTitleWidth:props.tileWidth||props.targetWidth,targetHeight||=title?props.titleHeight||props.targetTitleHeight:props.tileHeight||props.targetHeight,targetMargin||=title?props.titleMargin||props.targetTitleMargin:props.tileMargin||props.targetMargin,validNum(targetWidth)&&(res.width=targetWidth,valid.width=!0),validNum(targetHeight)&&(res.height=targetHeight,valid.height=!0),validNum(targetMargin)&&(res.margin=targetMargin,valid.margin=!0);let em2px=em=>(fontSize$1||=getFontSize(),em*fontSize$1);if(valid.width&&res.width&&(res.width=em2px(res.width)),valid.height&&res.height&&(res.height=em2px(res.height)),valid.margin&&res.margin&&(res.margin=em2px(res.margin)),!valid.width||bigmode.enabled&&!valid.height||!valid.margin){if(res.el instanceof HTMLElement){let style=window.getComputedStyle(res.el,null);valid.width||(res.width=+style.width.substring(0,style.width.length-2)),valid.height||(res.height=+style.height.substring(0,style.height.length-2)),valid.margin||(res.margin=[style.marginTop,style.marginRight,style.marginBottom,style.marginLeft].map(m=>+m.substring(0,m.length-2)).sort((a$1,b)=>b-a$1)[0])}else logger_default.warn(`BngList cannot access ${title?`title`:`tile`} element for size auto-detection!`);warnShown||(warnShown=!0,logger_default.debug(`BigList was not provided with ${title?`title`:`target`} sizes (from props or from ${title?`title`:`tile`} component export) and attempted to auto-detect them. This may lead to some size micro-adjustments visible to user or invalid sizes. Please specify ${title?`title`:`target`} sizes manually.`),(res.width<1||res.height<1)&&logger_default.debug(`BigList noticed a detected ${title?`title`:``} size being too low: width = ${res.width}, height = ${res.height}`))}return res}let validNum=num=>typeof num==`number`&&!isNaN(num),getFontSize=()=>{if(!elCont.value)return 16;let size$3=window.getComputedStyle(elCont.value,null).fontSize;return+size$3.substring(0,size$3.length-2)||16},resizeObserver=new ResizeObserver(updSize);onMounted(()=>nextTick(()=>{resizeObserver.observe(elSize.value)})),onBeforeUnmount(()=>{elSize.value&&resizeObserver.unobserve(elSize.value),resizeObserver.disconnect()});let scrolling=ref(!1),scrollTmr,scrollTick=!1,onScrollDebounce=async()=>{scrollPos.value=bigmode.getPos[layoutSelected.value](),await updSkeleton()};watch(scrollPos,async pos=>{if(bigmode.enabled)if(bigmode.debounce>0)clearTimeout(scrollTmr),scrolling.value=!0,scrollTmr=setTimeout(async()=>{scrolling.value=!1,await calcBig(pos),await updSkeleton()},bigmode.debounce);else{if(scrollTick)return;scrollTick=!0,requestAnimationFrame(async()=>{scrollTick=!1,await calcBig(pos),await updSkeleton()})}});function vScroll(evt){evt.deltaY!==0&&elCont.value.scrollBy({left:evt.deltaY,behavior:`instant`})}function updSize(entries=[]){let oldContWidth=contWidth,oldContHeight=contHeight;tileWidth.value=0,tileHeight.value=0,titleWidth.value=0,titleHeight.value=0,tileProps?(tileMargin.value=validNum(tileProps.margin)?tileProps.margin:defTileMargin*fontSize,calcTiles(entries)):tileMargin.value=0,titleProps?(titleMargin.value=validNum(titleProps.margin)?titleProps.margin:defTitleMargin*fontSize,calcTitles(entries)):titleMargin.value=0,(Math.abs(oldContWidth-contWidth)>1||Math.abs(oldContHeight-contHeight)>1)&&invalidateLayoutCache(),bigmode.enabled&&!layoutCache.valid&&contWidth>0&&contHeight>0&&(!titleProps||titleWidth.value>0&&titleHeight.value>0)&&buildLayoutCache(),bigmode.enabled&&bigmode.initial&&(tileProps||titleProps)&&nextTick(async()=>{await calcBig(),await updSkeleton(),setTimeout(async()=>{await calcBig(),await updSkeleton()},50)}),elCont.value.removeEventListener(`mousewheel`,vScroll),layoutSelected.value===LIST_LAYOUTS.RIBBON&&elCont.value.addEventListener(`mousewheel`,vScroll)}function calcSizes(entries=[]){if(contWidth=0,contHeight=0,!elSize.value||!bigmode.enabled&&layoutSelected.value!==LIST_LAYOUTS.TILES)return!1;let baseMargin=tileMargin.value,rect=entries[0]?.contentRect||elSize.value.getBoundingClientRect();if(fontSize=getFontSize(),contWidth=rect.width,layoutSelected.value===LIST_LAYOUTS.RIBBON){let tileHeight$1=(tileProps?.height||5*fontSize)+baseMargin,titleHeight$1=titleProps?(titleProps.height||defTitleHeight*fontSize)+(titleProps.margin||defTitleMargin*fontSize):0;contHeight=Math.max(tileHeight$1,titleHeight$1)}else contHeight=rect.height-baseMargin;return!0}function calcTiles(entries=[]){if(!calcSizes(entries))return;let wantsWidth=layoutSelected.value===LIST_LAYOUTS.TILES||bigmode.enabled&&layoutSelected.value===LIST_LAYOUTS.RIBBON,wantsHeight=bigmode.enabled;if(!wantsWidth&&!wantsHeight)return;let baseMargin=tileMargin.value;if(wantsWidth){let baseWidth=tileProps.width||10*fontSize;if(contWidth>0&&layoutSelected.value===LIST_LAYOUTS.TILES){let prepWidth=baseWidth+baseMargin,amount=contWidth/prepWidth;amount<2?tileWidth.value=contWidth-baseMargin:tileWidth.value=(contWidth-baseMargin)/~~amount-baseMargin}else tileWidth.value=baseWidth}wantsHeight&&(tileHeight.value=tileProps.height||5*fontSize),bigmode.enabled&&bigmode.initial&&((!wantsWidth||contWidth>0)&&(!wantsHeight||contHeight>0)?(bigmode.initial=!1,calcBig(),updSkeleton()):window.requestAnimationFrame(()=>calcTiles()))}function calcTitles(){if(bigmode.enabled&&(fontSize=getFontSize()),!titleProps)return;let baseMargin=titleMargin.value,baseHeight=titleProps.height||defTitleHeight*fontSize;layoutSelected.value===LIST_LAYOUTS.RIBBON?titleWidth.value=titleProps.width||10*fontSize:titleWidth.value=contWidth-baseMargin;let oldTitleHeight=titleHeight.value;titleHeight.value=baseHeight,bigmode.enabled&&oldTitleHeight===0&&titleHeight.value>0&&contWidth>0&&contHeight>0&&(invalidateLayoutCache(),buildLayoutCache())}function clearLayoutCache(){layoutCache.totalSize=0,layoutCache.rows=[],layoutCache.itemToRow.clear(),layoutCache.rowPositions=[],layoutCache.valid=!0,layoutCache.building=!1,bigmode.enabled&&(bigmode.initial=!1,bigmode.full=0,bigmode.position=0,itemsView.value=[])}async function buildLayoutCache(){if(layoutCache.building){for(;layoutCache.building;)await sleep(10);return}if(items$2.value.length===0){clearLayoutCache();return}if(!tileProps&&!titleProps||contWidth<=0||contHeight<=0)return;if(layoutCache.building=!0,layoutCache.version=Date.now(),layoutCache.itemCount=items$2.value.length,await sleep(0),layoutCache.rows=[],layoutCache.itemToRow.clear(),layoutCache.rowPositions=[],layoutCache.itemCount!==items$2.value.length&&(layoutCache.itemCount=0),layoutCache.itemCount===0){clearLayoutCache(),items$2.value.length>0&&buildLayoutCache();return}let baseTileMargin=tileProps?.margin||defTileMargin*fontSize,baseTitleMargin=titleProps?.margin||defTitleMargin*fontSize,horizontal=layoutSelected.value===LIST_LAYOUTS.RIBBON,tilesPerRow=layoutSelected.value===LIST_LAYOUTS.TILES?~~(contWidth/tileWidth.value):1,pos=0,first=0,curItems=0;function completeRow(i){let tileSize=horizontal?tileWidth.value:tileHeight.value,size$3=tileSize+baseTileMargin,row={pos,size:size$3,first,last:i-1};layoutCache.rows.push(row),layoutCache.rowPositions.push(pos);for(let j=first;j0&&(completeRow(i),curItems=0);let titleSize=horizontal?titleWidth.value:titleHeight.value,rowSize=titleSize+baseTitleMargin,row={pos,size:rowSize,first:i,last:i,isTitle:!0};layoutCache.rows.push(row),layoutCache.rowPositions.push(pos),layoutCache.itemToRow.set(i,layoutCache.rows.length-1);let nextMargin=items$2.value[i+1]?.isBngListTitle?baseTitleMargin:baseTileMargin;pos+=titleSize+nextMargin,first=i+1,curItems=0}else if(curItems++,curItems===1&&(first=i),curItems>=tilesPerRow){let tileSize=horizontal?tileWidth.value:tileHeight.value,size$3=tileSize+baseTileMargin,row={pos,size:size$3,first,last:i};layoutCache.rows.push(row),layoutCache.rowPositions.push(pos);for(let j=first;j<=i;j++)layoutCache.itemToRow.set(j,layoutCache.rows.length-1);let nextMargin=items$2.value[i+1]?.isBngListTitle?baseTitleMargin:baseTileMargin;pos+=tileSize+nextMargin,curItems=0,first=i+1}curItems>0&&completeRow(layoutCache.itemCount),pos+=items$2.value[layoutCache.itemCount-1]?.isBngListTitle?baseTitleMargin:baseTileMargin,layoutCache.totalSize=pos,layoutCache.valid=!0,layoutCache.building=!1}function invalidateLayoutCache(){layoutCache.valid=!1,layoutCache.version++}function layoutCacheSearch(arr,target){let left=0,right=arr.length-1;for(;left<=right;){let mid=~~((left+right)/2);arr[mid]<=target?left=mid+1:right=mid-1}return Math.max(0,right)}async function getBigProps(pos=void 0,index=void 0,overflow=void 0){let count$1=items$2.value.length;if(count$1===0)return;if((!layoutCache.valid||layoutCache.itemCount!==count$1)&&(await buildLayoutCache(),!layoutCache.valid))return null;(typeof index!=`number`||index<0)&&(index=void 0,typeof pos!=`number`&&(pos=bigmode.getPos[layoutSelected.value]()));let contSize=layoutSelected.value===LIST_LAYOUTS.RIBBON?contWidth:contHeight;typeof overflow!=`number`&&(overflow=bigmode.overflow);let overflowBefore=Math.ceil(overflow/2),overflowAfter=Math.floor(overflow/2),firstRow=0,currentPos=0;if(typeof index==`number`&&index>=0){let rowIndex=layoutCache.itemToRow.get(index);rowIndex!==void 0&&(firstRow=rowIndex,currentPos=layoutCache.rows[rowIndex].pos,pos=currentPos)}else firstRow=layoutCacheSearch(layoutCache.rowPositions,pos),currentPos=layoutCache.rows[firstRow]?.pos||0;let extendedFirstRow=firstRow,backwardCount=0;for(let i=firstRow-1;i>=0&&backwardCount=contSize));i++);let overflowCount=0;for(let i=lastRow+1;iprops.keepAlive){let center=big.first+(big.last-big.first)/2,farthest=Array.from(itemsShown.value).sort((a$1,b)=>Math.abs(b-center)-Math.abs(a$1-center)).slice(0,itemsShown.value.size-props.keepAlive);for(let idx of farthest)itemsShown.value.delete(idx)}big.items=Array.from(itemsShown.value).sort((a$1,b)=>a$1-b).map(idx=>{let item=items$2.value[idx];return idx>=big.first&&idx<=big.last?item:{...item,keepAliveStyle:`display: none !important;`}})}else itemsShown.value.size>0&&itemsShown.value.clear();bigmode.items=big.items,itemsView.value=big.items}}function showSkeleton(show=!0){skeletonShown!==show&&(show?elSkeleton.value.style.removeProperty(`display`):(skeletonItems.value=[],elSkeleton.value.style.setProperty(`display`,`none`,`important`)),skeletonShown=show)}async function updSkeleton(){if(!elSkeleton.value||!bigmode.enabled||!bigmode.skeleton||!scrolling.value||items$2.value.length===0||!layoutCache.valid){showSkeleton(!1);return}if(bigmode.first===0&&bigmode.last===items$2.value.length-1){showSkeleton(!1);return}let horizontal=layoutSelected.value===LIST_LAYOUTS.RIBBON,contSize=horizontal?contWidth:contHeight,pos=scrollPos.value,start,end;if(pos=bigmode.position||(end=i,visibleSize+=row.size,visibleSize>=contSize))break}let overflowCount=0;for(let i=end+1;i=bigmode.position);i++)end=i,overflowCount++;let neededSize=contSize+bigmode.skeletonOverflow*(horizontal?tileWidth.value:tileHeight.value),backwardSize=visibleSize;for(;start>0&&backwardSize=contSize));i++);let overflowCount=0;for(let i=end+1;i(openBlock(),createElementBlock(`div`,_hoisted_1$316,[toolbar.value.enabled?withDirectives((openBlock(),createElementBlock(`div`,_hoisted_2$257,[toolbar.value.path?(openBlock(),createBlock(Teleport,{key:0,disabled:!__props.pathTarget,to:__props.pathTarget},[createVNode(unref(bngBreadcrumbs_default),{ref_key:`elPath`,ref:elPath,items:__props.path,limit:__props.pathLimit,blur:!__props.noBackground,onClick:_cache[0]||=itm=>emit$1(`pathClick`,itm)},null,8,[`items`,`limit`,`blur`])],8,[`disabled`,`to`])):(openBlock(),createElementBlock(`div`,_hoisted_3$224)),toolbar.value.layout?(openBlock(),createBlock(Teleport,{key:2,disabled:!__props.layoutSelectorTarget,to:__props.layoutSelectorTarget},[createBaseVNode(`div`,_hoisted_4$192,[createVNode(unref(bngButton_default),{accent:layoutSelected.value===LIST_LAYOUTS.TILES?unref(ACCENTS).outlined:unref(ACCENTS).text,icon:unref(icons).tiles,onClick:_cache[1]||=$event=>layoutSelected.value=LIST_LAYOUTS.TILES},null,8,[`accent`,`icon`]),createVNode(unref(bngButton_default),{accent:layoutSelected.value===LIST_LAYOUTS.LIST?unref(ACCENTS).outlined:unref(ACCENTS).text,icon:unref(icons).listSmall,onClick:_cache[2]||=$event=>layoutSelected.value=LIST_LAYOUTS.LIST},null,8,[`accent`,`icon`])])],8,[`disabled`,`to`])):createCommentVNode(``,!0)],512)),[[vShow,toolbar.value.show]]):createCommentVNode(``,!0),withDirectives((openBlock(),createElementBlock(`div`,{ref_key:`elCont`,ref:elCont,class:normalizeClass({"list-content":!0,"list-with-background":!__props.noBackground,[`list-layout-${layoutSelected.value}`]:!0,"list-item-width":!!tileWidth.value,"list-item-height":!!tileHeight.value,"list-item-margin":!!tileMargin.value,"list-title-width":!!titleWidth.value,"list-title-height":!!titleHeight.value,"list-title-margin":!!titleMargin.value,"list-big":bigmode.enabled,"list-scrolling":scrolling.value||bigmode.debounce===0,"list-processing":processing.value}),style:normalizeStyle({"--list-item-width":`${tileWidth.value}px`,"--list-item-height":`${tileHeight.value}px`,"--list-item-margin":`${tileMargin.value}px`,"--list-title-width":`${titleWidth.value}px`,"--list-title-height":`${titleHeight.value}px`,"--list-title-margin":`${titleMargin.value}px`,"--list-big-full":`${bigmode.full}px`}),onScroll:onScrollDebounce},[createBaseVNode(`div`,{ref_key:`elSize`,ref:elSize,class:`list-content-size-observer`},null,512),bigmode.enabled&&bigmode.skeleton?(openBlock(),createElementBlock(`div`,{key:0,ref_key:`elSkeleton`,ref:elSkeleton,class:`list-skeleton`},[(openBlock(!0),createElementBlock(Fragment,null,renderList(skeletonItems.value,(isTitle,i)=>(openBlock(),createElementBlock(`div`,{key:`skeleton-${i}`,class:normalizeClass({"skeleton-item":!0,"skeleton-title":isTitle})},null,2))),128))],512)):createCommentVNode(``,!0),createBaseVNode(`div`,{class:`list-items`,style:normalizeStyle(listItemsStyle.value)},[(openBlock(!0),createElementBlock(Fragment,null,renderList(itemsView.value,vnode=>(openBlock(),createBlock(resolveDynamicComponent(vnode),{key:vnode.key,style:normalizeStyle(vnode.keepAliveStyle)},null,8,[`style`]))),128))],4)],38)),[[unref(BngBlur_default),!__props.noBackground]])]))}},bngList_default=__plugin_vue_export_helper_default(_sfc_main$361,[[`__scopeId`,`data-v-5af5eff2`]]),_hoisted_1$315={class:`bng-stars`},_hoisted_2$256={key:0,class:`stars`},_hoisted_3$223=[`innerHTML`],_hoisted_4$191=[`innerHTML`],_hoisted_5$163={key:1,class:`stars`},_hoisted_6$140={class:`stars-label`},_hoisted_7$122=[`innerHTML`],_sfc_main$360={__name:`bngMainStars`,props:{unlockedStars:{type:Number,default:0,validator:val=>val>=0},totalStars:{type:Number,default:1},scale:{type:Number,default:1},individualStars:{type:Object,default:null,validator:val=>val===null||Array.isArray(val)},numerical:{type:Boolean,default:!1}},setup(__props){useCssVars(_ctx=>({v3c930dd6:fontSize.value}));let props=__props,fontSize=computed(()=>`${props.scale}rem`),starsTotal=computed(()=>props.individualStars?props.individualStars.length:props.totalStars),starsFilled=computed(()=>props.individualStars?props.individualStars.filter(Boolean).length:props.unlockedStars),starsUnfilled=computed(()=>starsTotal.value-starsFilled.value),glyphsFilled=computed(()=>starsFilled.value>0?icons.star.glyph.repeat(starsFilled.value):``),glyphsUnfilled=computed(()=>starsUnfilled.value>0?icons.star.glyph.repeat(starsUnfilled.value):``);return(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$315,[!__props.numerical&&__props.individualStars&&__props.individualStars.length?(openBlock(),createElementBlock(`div`,_hoisted_2$256,[starsFilled.value?(openBlock(),createElementBlock(`span`,{key:0,class:`star star-filled`,innerHTML:glyphsFilled.value},null,8,_hoisted_3$223)):createCommentVNode(``,!0),starsUnfilled.value?(openBlock(),createElementBlock(`span`,{key:1,class:`star star-unfilled`,innerHTML:glyphsUnfilled.value},null,8,_hoisted_4$191)):createCommentVNode(``,!0)])):(openBlock(),createElementBlock(`div`,_hoisted_5$163,[createBaseVNode(`div`,_hoisted_6$140,toDisplayString(starsFilled.value)+` / `+toDisplayString(starsTotal.value),1),createBaseVNode(`span`,{class:`star star-filled`,innerHTML:unref(icons).star.glyph},null,8,_hoisted_7$122)]))]))}},bngMainStars_default=__plugin_vue_export_helper_default(_sfc_main$360,[[`__scopeId`,`data-v-4ba4c794`]]),_hoisted_1$314=[`rows`,`placeholder`,`disabled`],_hoisted_2$255={key:0,class:`floating-label`},_sfc_main$359={__name:`bngMultilineInput`,props:{floatingLabel:String,externalLabel:String,placeholder:String,initialValue:String,leadingIcon:Object,trailingIcon:Object,scalable:Boolean,hasError:Boolean,errorMessage:String,lines:{type:Number,default:1},disabled:{type:Boolean,default:!1}},setup(__props){useCssVars(_ctx=>({v26daab40:bngScalableInputMaxWidth.value}));let props=__props,inputContainer=ref(null),bngMultilineInput=ref(null),focusHighlight=ref(null),leadingIconContainer=ref(null),trailingIconContainer=ref(null),value=ref(``),isInputFieldFocused=ref(!1),hasValue=computed(()=>value.value!==``&&value.value!==void 0),bngScalableInputMaxWidth=computed(()=>`${(leadingIconContainer.value?leadingIconContainer.value.offsetWidth:0)+(trailingIconContainer.value?trailingIconContainer.value.offsetWidth:0)}px`),resizeObserver;onBeforeMount(()=>{value.value=props.initialValue,resizeObserver=new ResizeObserver(onInputResize)}),onMounted(()=>{resizeObserver.observe(bngMultilineInput.value)}),onDeactivated(()=>{resizeObserver.disconnect()});function onInputFieldFocusIn(){isInputFieldFocused.value=!0}function onInputFieldFocusOut(){isInputFieldFocused.value=!1}function onInputResize(){inputContainer.value&&window.requestAnimationFrame(()=>{let focusRight=inputContainer.value.offsetWidth-inputContainer.value.offsetWidth;focusHighlight.value.style.right=`${focusRight-2}px`})}return(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,{class:normalizeClass([`input-icon-wrapper`,{scalable:__props.scalable}])},[__props.leadingIcon?(openBlock(),createElementBlock(`span`,{key:0,ref_key:`leadingIconContainer`,ref:leadingIconContainer,class:`input-icon`},[createVNode(unref(bngIcon_default),{type:__props.leadingIcon},null,8,[`type`])],512)):createCommentVNode(``,!0),createBaseVNode(`div`,{ref_key:`inputContainer`,ref:inputContainer,class:normalizeClass([`bng-multiline-input`,{"input-focused":isInputFieldFocused.value,"has-error":__props.hasError}]),tabindex:`0`},[withDirectives(createBaseVNode(`textarea`,{"onUpdate:modelValue":_cache[0]||=$event=>value.value=$event,ref_key:`bngMultilineInput`,ref:bngMultilineInput,class:normalizeClass([`input-field`,{empty:!hasValue.value,"has-value":hasValue.value,"has-error":__props.hasError,disabled:__props.disabled}]),rows:__props.lines,placeholder:__props.floatingLabel,disabled:__props.disabled,onFocusin:onInputFieldFocusIn,onFocusout:onInputFieldFocusOut},null,42,_hoisted_1$314),[[vModelText,value.value],[unref(BngTextInput_default)]]),__props.floatingLabel?(openBlock(),createElementBlock(`span`,_hoisted_2$255,toDisplayString(__props.floatingLabel),1)):createCommentVNode(``,!0),createBaseVNode(`span`,{ref_key:`focusHighlight`,ref:focusHighlight,class:`focus-highlight`},null,512)],2),__props.trailingIcon?(openBlock(),createElementBlock(`span`,{key:1,ref_key:`trailingIconContainer`,ref:trailingIconContainer,class:`input-icon`},[createVNode(unref(bngIcon_default),{type:__props.trailingIcon},null,8,[`type`])],512)):createCommentVNode(``,!0)],2))}},bngMultilineInput_default=__plugin_vue_export_helper_default(_sfc_main$359,[[`__scopeId`,`data-v-6c6cfdb8`]]);const icons$1={undefined:`undefined`,arrow:{large:{up:`arrow/large_up`,down:`arrow/large_down`,left:`arrow/large_left`,right:`arrow/large_right`},small:{up:`arrow/arrowSmallUp`,down:`arrow/arrowSmallDown`,left:`arrow/arrowSmallLeft`,right:`arrow/arrowSmallRight`}},drive:{autobahn:`drive/autobahn`,busroutes:`drive/busroutes`,campaigns:`drive/campaigns`,career:`drive/career`,freeroam:`drive/freeroam`,garage:`drive/garage`,infinity:`drive/infinity`,lightrunner:`drive/lightrunner`,m_a:`drive/m_a`,m_b:`drive/m_b`,m_c:`drive/m_c`,play:`drive/play`,quit:`drive/quit`,scenarios:`drive/scenarios`,timetrials:`drive/timetrials`},general:{offbtn:`general/offbtn`,unknown:`general/unknown`,check:`general/check`,recharge:`general/recharge`,refuel:`general/refuel`,beambuck:`general/beambuck`,money:`general/beambuck`,beamXP:`general/beamXP`,arrow_small_left:`general/arrow_small-left`,arrow_small_right:`general/arrow_small-right`,fuel_nozzle:`general/fuel-nozzle`,recharge_connector:`general/recharge-connector`,star:`general/star`,star_outlined:`general/star-secondary`,vehicle:`general/vehicle`,awd:`general/awd`,"4wd":`general/4wd`,fwd:`general/fwd`,rwd:`general/rwd`,drivetrain_special:`general/drivetrain-special`,drivetrain_generic:`general/drivetrain-generic`,charge:`general/charge`,fuel:`general/fuel`,odometer:`general/odometer`,power_gauge_01:`general/power-gauge-01c`,power_gauge_02:`general/power-gauge-02c`,power_gauge_03:`general/power-gauge-03c`,power_gauge_04:`general/power-gauge-04c`,power_gauge_05:`general/power-gauge-05c`,weight:`general/weight`,transmission_a:`general/transmission-a`,transmission_m:`general/transmission-m`},device:{keyboard:`device/keyboard`,phone_android:`device/phone_android`,wheel:`device/wheel`,gamepad:`device/gamepad`,videogame_asset:`device/videogame_asset`,mouse:{button0:`device/mouse/button0`,button1:`device/mouse/button1`,button2:`device/mouse/button2`,xaxis:`device/mouse/xaxis`,yaxis:`device/mouse/yaxis`,zaxis:`device/mouse/zaxis`},xbox:{btn_a:`device/xbox/btn_a`,btn_b:`device/xbox/btn_b`,btn_back:`device/xbox/btn_back`,btn_lb:`device/xbox/btn_lb`,btn_lt:`device/xbox/btn_lt`,btn_rb:`device/xbox/btn_rb`,btn_rt:`device/xbox/btn_rt`,btn_start:`device/xbox/btn_start`,btn_x:`device/xbox/btn_x`,btn_y:`device/xbox/btn_y`,btn_dpad_default_filled:`device/xbox/btn_dpad_default_filled`,btn_dpad_default_outline:`device/xbox/btn_dpad_default_outline`,btn_dpad_down:`device/xbox/btn_dpad_down`,btn_dpad_left:`device/xbox/btn_dpad_left`,btn_dpad_right:`device/xbox/btn_dpad_right`,btn_dpad_up:`device/xbox/btn_dpad_up`,btn_thumb_left:`device/xbox/btn_thumb_left`,btn_thumb_left_x:`device/xbox/btn_thumb_left_x`,btn_thumb_left_y:`device/xbox/btn_thumb_left_y`,btn_thumb_right:`device/xbox/btn_thumb_right`,btn_thumb_right_x:`device/xbox/btn_thumb_right_x`,btn_thumb_right_y:`device/xbox/btn_thumb_right_y`}},decals:{camera:{back:`decals/camera/back`,freecam:`decals/camera/freecam`,front:`decals/camera/front`,left:`decals/camera/left`,right:`decals/camera/right`,top:`decals/camera/top`},general:{change_order:`decals/general/change_order`,deform:`decals/general/deform`,delete:`decals/general/delete`,duplicate:`decals/general/duplicate`,hide:`decals/general/hide`,lock:`decals/general/lock`,mirror:`decals/general/mirror`,options:`decals/general/options`,redo:`decals/general/redo`,rename:`decals/general/rename`,save:`decals/general/save`,transform:`decals/general/transform`,undo:`decals/general/undo`,unlock:`decals/general/unlock`,use_mask:`decals/general/mask`},group:{group:`decals/group/group`,ungroup:`decals/group/ungroup`},layer:{decal:`decals/layer/decal`,material:`decals/layer/material`},mirror:{copy_mirrored:`decals/mirror/copy_mirrored`,copy_straight:`decals/mirror/copy_straight`}}},iconTypesList=makeIconTypesList(icons$1);function makeIconTypesList(dict){let key,all=[];for(key in dict)all=all.concat(typeof dict[key]==`string`?dict[key]:makeIconTypesList(dict[key]));return all}var _hoisted_1$313=[`src`],_sfc_main$358={__name:`bngOldIcon`,props:{type:{type:String,validator:v=>iconTypesList.includes(v)},span:{type:Boolean,default:!0},mask:{type:Boolean,default:!0},color:String},setup(__props){let props=__props,iconImageURL=computed(()=>getAssetURL(`icons/${props.type}.svg`)),spanStyle=computed(()=>({[props.mask?`maskImage`:`backgroundImage`]:`url(${iconImageURL.value})`,backgroundColor:props.color||`#fff`}));return(_ctx,_cache)=>__props.span?(openBlock(),createElementBlock(`span`,{key:0,class:`bngicon`,style:normalizeStyle(spanStyle.value)},[renderSlot(_ctx.$slots,`default`,{},void 0,!0)],4)):(openBlock(),createElementBlock(`img`,{key:1,class:`bngicon`,src:iconImageURL.value,alt:``},null,8,_hoisted_1$313))}},bngOldIcon_default=__plugin_vue_export_helper_default(_sfc_main$358,[[`__scopeId`,`data-v-da0e0a74`]]),_hoisted_1$312=[`bng-no-child-nav`],scrollBuildupTime=3e3,scrollMaxSpeedModifier=4,CLICKID=`__bngOverflowContainer`,_sfc_main$357={__name:`bngOverflowContainer`,props:{scrollSpeed:{type:Number,default:5},initialIndex:{type:Number,default:-1},useBindings:[Boolean,Array],useBindingsOnly:[Boolean,Array],showBindings:{type:Boolean,default:!0},showArrows:{type:Boolean,default:!1},noWheel:{type:Boolean,default:!1}},setup(__props,{expose:__expose}){let slots=useSlots(),props=__props,useBindings=props.useBindings||props.useBindingsOnly,useBindingsOnly=props.useBindingsOnly;watch([()=>props.useBindings,()=>props.useBindingsOnly],()=>console.warn(`useBindings and useBindingsOnly can only be set at component mount time`));let uinavBound=!1,focusNav=useBindings&&Array.isArray(useBindings)?useBindings:[`tab_l`,`tab_r`],elBindPrev=ref(null),elBindNext=ref(null),elCont=ref(null),scrollContainer=ref(null),showLeftFade=ref(!1),showRightFade=ref(!1),resizeObserver=new ResizeObserver(updateFadeVisibility),scrollInterval=null,scrollTime=0,lastActive=null,fixingActive=!1;function setActive(elm){clearActive(),elm instanceof Element&&(elm.setAttribute(`active`,`true`),lastActive=elm)}function clearActive(evt){lastActive&&(evt&&(evt.detail?.target||evt.target)===lastActive||(lastActive.removeAttribute(`active`),lastActive=null))}function fixActive(evt){if(fixingActive||useBindings&&evt.type===`focusin`)return;let active=evt.detail?.target||evt.target||document.activeElement;if(active.matches(`[is-bng-panel], [bng-nav-item], [ng-click], [href], [bng-all-clicks], [bng-all-clicks-no-nav], [ui-sref], input, textarea, button, md-option, md-slider, md-select, md-checkbox`)||(active=active.closest(NAVIGABLE_ELEMENTS_SELECTOR)),scrollContainer.value.contains(active)&&!(lastActive&&(lastActive===active||lastActive.contains(active)))){if(useBindingsOnly){fixingActive=!0;let prev=evt.detail.relatedTarget||evt.relatedTarget;prev&&scrollContainer.value.contains(prev)&&(prev=null),prev?setFocusExternal(prev,!0):setFocusExternal(active,!1)}nextTick(()=>{setActive(active),fixingActive=!1})}}let firstTime=!0;function updateContents(){if(!scrollContainer.value)return;let elFirst;for(let elm of scrollContainer.value.children)firstTime&&!elFirst&&(elFirst=elm),!elm[CLICKID]&&(elm[CLICKID]=!0,elm.addEventListener(`click`,fixActive));firstTime&&elFirst&&props.initialIndex>-1&&(firstTime=!1,elFirst.matches(`[is-bng-panel], [bng-nav-item], [ng-click], [href], [bng-all-clicks], [bng-all-clicks-no-nav], [ui-sref], input, textarea, button, md-option, md-slider, md-select, md-checkbox`)||(elFirst=elFirst.querySelector(NAVIGABLE_ELEMENTS_SELECTOR)),elFirst&&activate(elFirst))}watch([()=>slots.default?.(),()=>scrollContainer.value],()=>nextTick(updateContents),{immediate:!0});function navContents(dir,fireClick=!1){let links=collectRects(dir,scrollContainer.value,useBindingsOnly),prev=lastActive;clearActive();let res;if(useBindingsOnly){let idx=links[dir].findIndex(link=>link.dom===prev);idx>-1?res=links[dir][dir===`right`?idx+1:idx-1]:idx===0&&dir===`left`?res=links[dir][links[dir].length-1]:idx===links[dir].length-1&&dir===`right`&&(res=links[dir][0]),res&&(setActive(res.dom),scrollFix(res,dir))}else prev&&(res=navigate(links,dir,prev),res&&setActive(res));res?fireClick&&(res.dom&&(res=res.dom),nextTick(()=>res?.dispatchEvent(new Event(`click`)))):(scrollContainer.value.scrollTo({left:dir===`right`?0:scrollContainer.value.clientWidth,behavior:`instant`}),nextTick(()=>{let elms$4=collectRects(`right`,scrollContainer.value,!0).right;dir===`left`&&elms$4.reverse(),res=elms$4[0],res&&(setActive(res.dom),useBindingsOnly?scrollFix(res,dir):setFocusExternal(res.dom),fireClick&&res.dom.dispatchEvent(new Event(`click`)))}))}let activatePrev=()=>navContents(`left`,!0),activateNext=()=>navContents(`right`,!0);function activate(indexOrElement){let elm;if(typeof indexOrElement==`number`){let elms$4=scrollContainer.value.querySelectorAll(NAVIGABLE_ELEMENTS_SELECTOR);indexOrElement<0&&(indexOrElement=elms$4.length+indexOrElement),elm=elms$4[indexOrElement]}else if(indexOrElement instanceof Element)elm=indexOrElement;else throw Error(`Invalid argument`);if(!elm)throw Error(`Element not found`);scrollFix({dom:elm,rect:elm.getBoundingClientRect()},`right`),setActive(elm),!useBindingsOnly&&setFocusExternal(elm)}if(__expose({scrollBy:amount=>scrollContainer.value?.scrollBy({left:amount,behavior:`smooth`}),activatePrev,activateNext,activate,deactivate:()=>{let active=document.activeElement,activeCorrect=active&&active===lastActive;clearActive(),activeCorrect&&(useBindingsOnly&&setFocusExternal(active,!1),active.blur?.())},refresh:(withActivation=!1)=>{withActivation&&(firstTime=!0),updateContents()}}),useBindings){let instance$1=getCurrentInstance(),contUnwatch=watch(()=>elCont.value,elm=>{elm&&(contUnwatch(),nextTick(()=>{uinavBound=!0;let vnode={ctx:instance$1,el:elm};BngOnUiNav_default.mounted(elm,{arg:focusNav[0],modifiers:{},value:activatePrev},vnode),BngOnUiNav_default.mounted(elm,{arg:focusNav[1],modifiers:{},value:activateNext},vnode),elm.addEventListener(`focusin`,fixActive)}))},{immediate:!0})}watch(scrollContainer,elm=>{elm&&(updateFadeVisibility(),resizeObserver.observe(elm))},{immediate:!0});function updateFadeVisibility(){if(!scrollContainer.value)return;let{scrollLeft,scrollWidth,clientWidth}=scrollContainer.value;showLeftFade.value=scrollLeft>0,showRightFade.value=scrollLeft{let speedModifier=Math.min(1+(scrollMaxSpeedModifier-1)*(scrollTime/scrollBuildupTime),scrollMaxSpeedModifier),scrollAmount=(direction$1===`left`?-props.scrollSpeed:props.scrollSpeed)*speedModifier;scrollContainer.value.scrollLeft+=scrollAmount,updateFadeVisibility(),scrollTime+=1e3/30},1e3/30)}function stopScrolling(){scrollInterval&&=(clearInterval(scrollInterval),null),scrollTime=0}function onWheel(evt){props.noWheel||(evt.preventDefault(),scrollContainer.value.scrollLeft+=evt.deltaY,updateFadeVisibility())}function onScroll(){updateFadeVisibility()}return onBeforeUnmount(()=>{resizeObserver.disconnect(),stopScrolling(),uinavBound&&(BngOnUiNav_default.beforeUnmount(elCont.value),elCont.value.removeEventListener(`focusin`,fixActive))}),(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,{ref_key:`elCont`,ref:elCont,class:normalizeClass([`bng-overflow-container`,{"with-bindings":unref(useBindings)&&(elBindPrev.value?.displayed||elBindNext.value?.displayed),"with-arrows":__props.showArrows&&!(elBindPrev.value?.displayed||elBindNext.value?.displayed),"hide-bindings":!__props.showBindings}]),onWheel},[withDirectives(createBaseVNode(`div`,{class:`fade-left`,onMouseenter:_cache[0]||=$event=>startScrolling(`left`),onMouseleave:stopScrolling},null,544),[[vShow,showLeftFade.value]]),withDirectives(createBaseVNode(`div`,{class:`fade-right`,onMouseenter:_cache[1]||=$event=>startScrolling(`right`),onMouseleave:stopScrolling},null,544),[[vShow,showRightFade.value]]),__props.showArrows&&!elBindPrev.value?.displayed?(openBlock(),createBlock(unref(bngIcon_default),{key:0,type:unref(icons).arrowLargeLeft,class:`hint-prev`},null,8,[`type`])):createCommentVNode(``,!0),__props.showArrows&&!elBindNext.value?.displayed?(openBlock(),createBlock(unref(bngIcon_default),{key:1,type:unref(icons).arrowLargeRight,class:`hint-next`},null,8,[`type`])):createCommentVNode(``,!0),unref(useBindings)?(openBlock(),createBlock(unref(bngBinding_default),{key:2,ref_key:`elBindPrev`,ref:elBindPrev,class:`hint-prev`,"ui-event":unref(focusNav)[0],controller:``},null,8,[`ui-event`])):createCommentVNode(``,!0),unref(useBindings)?(openBlock(),createBlock(unref(bngBinding_default),{key:3,ref_key:`elBindNext`,ref:elBindNext,class:`hint-next`,"ui-event":unref(focusNav)[1],controller:``},null,8,[`ui-event`])):createCommentVNode(``,!0),createBaseVNode(`div`,{ref_key:`scrollContainer`,ref:scrollContainer,class:`scroll-container`,"bng-no-child-nav":unref(useBindingsOnly),onScroll},[renderSlot(_ctx.$slots,`default`,{},void 0,!0)],40,_hoisted_1$312)],34))}},bngOverflowContainer_default=__plugin_vue_export_helper_default(_sfc_main$357,[[`__scopeId`,`data-v-24544cbf`]]);const rainbow=(numOfSteps,step)=>{let r,g,b,h$1=step/numOfSteps,i=~~(h$1*6),f=h$1*6-i,q=1-f;switch(i%6){case 0:[r,g,b]=[1,f,0];break;case 1:[r,g,b]=[q,1,0];break;case 2:[r,g,b]=[0,1,f];break;case 3:[r,g,b]=[0,q,1];break;case 4:[r,g,b]=[f,0,1];break;case 5:[r,g,b]=[1,0,q];break}return[r,g,b]},hueToRGB=(p$1,q,t)=>(t<0&&(t+=1),t>1&&--t,t<1/6?p$1+(q-p$1)*6*t:t<1/2?q:t<2/3?p$1+(q-p$1)*(2/3-t)*6:p$1),HSLToRGB=(h$1,s,l)=>{let r,g,b;if(s===0)r=g=b=l;else{let q=l<.5?l*(1+s):l+s-l*s,p$1=2*l-q;r=hueToRGB(p$1,q,h$1+1/3),g=hueToRGB(p$1,q,h$1),b=hueToRGB(p$1,q,h$1-1/3)}return[r,g,b]},RGBToHSL=(r,g,b)=>{let vmax=Math.max(r,g,b),vmin=Math.min(r,g,b),h$1,s,l=(vmax+vmin)/2;if(vmax===vmin)return[0,0,l];let d=vmax-vmin;return s=l>.5?d/(2-vmax-vmin):d/(vmax+vmin),vmax===r&&(h$1=(g-b)/d+(gnum;else if(val<=15){let prec=10**val;this._precision=num=>~~(num*prec)/prec}else throw TypeError(`Precision can't go higher than 15`)}_sync({hsl=!1,rgb=!1}={}){if(hsl&&rgb)throw Error(`Cannot set both HSL and RGB changes at once`);this._dirty.hsl&&!hsl?this._rgb=HSLToRGB(...this._hsl):this._dirty.rgb&&!rgb&&(this._hsl=RGBToHSL(...this._rgb)),this._dirty.hsl=hsl,this._dirty.rgb=rgb}_parse(val){let res;if(isProxy(val)&&(val=toRaw(val)),typeof val==`string`&&(val=val.split(` `)),typeof val==`object`&&Array.isArray(val)){if(val.length<3)throw Error(`Invalid colour array length`);val.length===3&&(val=[...val,1]),val=val.map(Number);for(let num of val)if(isNaN(num))throw Error(`Values must be numbers`);res=val}if(!res)throw Error(`Color must be either an array or a string`);return res}get hslString(){return this.hsl.join(` `)}get hslaString(){return this.hsla.join(` `)}get rgbString(){return this.rgb.join(` `)}get rgbaString(){return this.rgba.join(` `)}get saturationPercent(){return Math.round(this.saturation*100)}get luminosityPercent(){return Math.round(this.luminosity*100)}get alphaPercent(){return Math.round(this._alpha*50)}get metallicPercent(){return Math.round(this._metallic*100)}get roughnessPercent(){return Math.round(this._roughness*100)}get clearcoatPercent(){return Math.round(this._clearcoat*100)}get clearcoatRoughnessPercent(){return Math.round(this._clearcoatRoughness*100)}get paint(){return[...this._legacy?this.rgba:this.rgb,this.metallic,this.roughness,this.clearcoat,this.clearcoatRoughness].map(this._precision)}get paintString(){return this.paint.join(` `)}get paintObject(){return this._paintObjectNames.reduce((res,name)=>({...res,[name]:this[name]}),{})}set paint(val){let data;if(isProxy(val)&&(val=toRaw(val)),typeof val==`object`){if(!Array.isArray(val)){data={...val};let names=this._paintObjectNames;for(let name of names){if(name===`baseColor`){this.baseColor=name in data?data[name]:[1,1,1,1];continue}let num=0;name in data&&(num=Number(data[name]),isNaN(num)&&(num=0)),this[name]=num}return}data=val}else if(typeof val==`string`)data=val.split(` `);else throw TypeError(`Invalid data type`);if(data.length===8)this.rgba=data.slice(0,4);else if(data.length===7)this.rgb=data.slice(0,3);else throw TypeError(`Invalid data value`);[this._metallic,this._roughness,this._clearcoat,this._clearcoatRoughness]=data.slice(-4)}get metallic(){return this._precision(this._metallic)}set metallic(val){this._metallic=Number(val)}get roughness(){return this._precision(this._roughness)}set roughness(val){this._roughness=Number(val)}get clearcoat(){return this._precision(this._clearcoat)}set clearcoat(val){this._clearcoat=Number(val)}get clearcoatRoughness(){return this._precision(this._clearcoatRoughness)}set clearcoatRoughness(val){this._clearcoatRoughness=Number(val)}get alpha(){return this._precision(this._alpha)}set alpha(val){let type=typeof val;type!==`undefined`&&(type===`number`?this._alpha=val:this._alpha=Number(val))}get hsl(){return this._sync(),this._hsl.map(this._precision)}set hsl(val){let arr=this._parse(val);this._sync({hsl:!0}),this._hsl=arr.slice(0,3),this.alpha=arr[3]}get rgb(){return this._sync(),this._rgb.map(this._precision)}get rgb255(){return this.rgb.map(val=>Math.round(val*255))}set rgb(val){let arr=this._parse(val);this._sync({rgb:!0}),this._rgb=arr.slice(0,3),this.alpha=arr[3]}set rgb255(val){let arr=this._parse(val);this.rgb=[...arr.slice(0,3).map(val$1=>val$1/255),arr[3]]}get hsla(){return[...this.hsl,this.alpha]}set hsla(val){this.hsl=val}get rgba(){return[...this.rgb,this.alpha]}set rgba(val){this.rgb=val}get baseColor(){return this.rgba}set baseColor(val){this.rgba=val}get hue(){return this.hsl[0]}get hue360(){return this.hsl[0]*360}set hue(val){this._sync({hsl:!0}),this._hsl[0]=Number(val)}set hue360(val){this.hue=Number(val)/360}get saturation(){return this.hsl[1]}set saturation(val){this._sync({hsl:!0}),this._hsl[1]=Number(val)}get luminosity(){return this.hsl[2]}set luminosity(val){this._sync({hsl:!0}),this._hsl[2]=Number(val)}get red(){return this.rgb[0]}get red255(){return this.rgb[0]*255}set red(val){this._sync({rgb:!0}),this._rgb[0]=Number(val)}set red255(val){this.red=Number(val)/255}get green(){return this.rgb[1]}get green255(){return this.rgb[1]*255}set green(val){this._sync({rgb:!0}),this._rgb[1]=Number(val)}set green255(val){this.green=Number(val)/255}get blue(){return this.rgb[2]}get blue255(){return this.rgb[2]*255}set blue(val){this._sync({rgb:!0}),this._rgb[2]=Number(val)}set blue255(val){this.blue=Number(val)/255}static anyToArray(val,legacy=!1){if(Array.isArray(val)){let checks=[val$1=>val$1 instanceof Paint,val$1=>typeof val$1==`object`&&Array.isArray(val$1.baseColor),val$1=>typeof val$1==`string`&&val$1.split(` `).length>=7,val$1=>Array.isArray(val$1)&&val$1.length>=7];if(val.some(item=>checks.some(check=>check(item))))return val.map(item=>Paint.anyToArray(item,legacy))}let precision=val$1=>{let num=Number(val$1);return isNaN(num)?val$1:~~(num*1e4)/1e4};return Array.isArray(val)?val.map(precision):typeof val==`string`?val.split(` `).map(precision):val instanceof Paint?val.paint:typeof val==`object`&&val.baseColor?[...legacy?val.baseColor:val.baseColor.slice(0,3),val.metallic,val.roughness,val.clearcoat,val.clearcoatRoughness].map(precision):val}static hslCssStr(arr){return`${Math.round(arr[0]*360)}, ${Math.round(arr[1]*100)}%, ${Math.round(arr[2]*100)}%`}static rgbToHsl(rgb){return RGBToHSL(...rgb)}static hslToRgb(hsl){return HSLToRGB(...hsl)}},CACHE_LIMIT=200,TILE_SIZE=64,MULTI_ANGLE=23,MAX_CONCURRENT_RENDERS=20,QUEUE_INTERVAL=10,reflectionImageUrl=`/ui/ui-vue/src/assets/images/paint-reflection.jpg`,reflectionImage=null,reflectionImageDone=!1,renderCancelledError=Error(`Render cancelled`),cacheCleanedError=Error(`Cache cleared`);function hashPaintData(paintData){return paintData?(paintData=Paint.anyToArray(paintData,!1),Array.isArray(paintData)?Array.isArray(paintData[0])?paintData.map(paint=>Array.isArray(paint)?paint.join(`,`):``).join(`|`):paintData.join(`,`):JSON.stringify(paintData)):``}var checkMultipaint=paintData=>Array.isArray(paintData)&&paintData.length>0&&paintData.some(item=>Array.isArray(item)&&item.length>=7);const usePaintPreviews=defineStore(`paint-previews`,()=>{let previews=ref(new Map),pendingRenders=ref(new Map),renderQueue=ref([]),activeRenders=ref(0),cacheListeners=new Set,pendingBlobCleanup=new Set,queueProcessor=null,blobCleanupTimeout=null;{let img=new Image;img.onload=()=>{reflectionImage=img,reflectionImageDone=!0},img.onerror=()=>{console.warn(`Failed to load metallic reflection image`),reflectionImageDone=!0},img.src=reflectionImageUrl}function startQueue(eager=!1){if(queueProcessor||renderQueue.value.length===0)return;let run$1=()=>{renderQueue.value.length===0?stopQueue():activeRenders.value0||activeRenders.value>0)return!1;for(let entry of previews.value.values())if(entry.blobGenerating)return!1;return!0}function blobCleanup(){blobCleanupTimeout&&clearTimeout(blobCleanupTimeout),blobCleanupTimeout=setTimeout(()=>{if(blobCleanupTimeout=null,isSystemIdle()&&pendingBlobCleanup.size>0){for(let blobUrl of pendingBlobCleanup)URL.revokeObjectURL(blobUrl);pendingBlobCleanup.clear()}},1e3)}async function processQueue({key,paintData,opts,resolve:resolve$1,reject,aborter}){activeRenders.value++;try{let checkAborted=()=>{if(aborter.signal.aborted)throw renderCancelledError};checkAborted();let width$1=opts.width||TILE_SIZE,height$1=opts.height||TILE_SIZE,areas=calculatePaintAreas(paintData,width$1,height$1),cvs=await renderPaint(paintData,width$1,height$1,opts.radialLight||!1,areas,aborter);checkAborted();let bmp=await createImageBitmap(cvs);if(previews.value.size>=CACHE_LIMIT){let oldestKey=previews.value.keys().next().value;cleanupCacheEntry(previews.value.get(oldestKey)),previews.value.delete(oldestKey)}checkAborted(),previews.value.set(key,{bitmap:bmp,paintData,paintHash:hashPaintData(paintData),areas}),resolve$1(bmp)}catch(err){err!==renderCancelledError&&reject(err)}finally{pendingRenders.value.has(key)&&pendingRenders.value.get(key).aborter===aborter&&pendingRenders.value.delete(key),activeRenders.value--}}function getCacheKey({paintId,vehicleName,paintName,width:width$1=TILE_SIZE,height:height$1=TILE_SIZE,radialLight=!1}){if(paintId)return`paint#${paintId}@${width$1}x${height$1}${radialLight?`R`:`L`}`;if(vehicleName&&paintName)return`vehicle:${vehicleName}:${paintName}@${width$1}x${height$1}${radialLight?`R`:`L`}`;throw Error(`Either paintId or vehicleName+paintName must be provided`)}function isCached(opts,paintData){try{let key=getCacheKey(opts),data=previews.value.get(key);return data?!paintData||data.paintHash===hashPaintData(paintData):!1}catch{return!1}}function getCachedPreview(opts,paintData){try{let key=getCacheKey(opts),data=previews.value.get(key);return data?data.paintHash===hashPaintData(paintData)?data.bitmap:(cleanupCacheEntry(data),previews.value.delete(key),null):null}catch{return null}}async function generatePreview(paintData,opts){let key=getCacheKey(opts),paintHash=hashPaintData(paintData);if(pendingRenders.value.has(key)){let existing=pendingRenders.value.get(key);if(existing.paintHash===paintHash)return new Promise((resolve$1,reject)=>existing.others.push({resolve:resolve$1,reject}));{existing.aborter.abort(),renderQueue.value=renderQueue.value.filter(item=>!(item.key===key&&item.aborter===existing.aborter));let aborter$1=new AbortController,others$1=[...existing.others];return pendingRenders.value.set(key,{paintHash,others:others$1,aborter:aborter$1}),new Promise((resolve$1,reject)=>{others$1.push({resolve:resolve$1,reject}),renderQueue.value.unshift({key,paintData:Paint.anyToArray(paintData),opts,resolve:result=>others$1.forEach(p$1=>p$1.resolve(result)),reject:error=>others$1.forEach(p$1=>p$1.reject(error)),aborter:aborter$1}),startQueue(!0)})}}let aborter=new AbortController,others=[];return pendingRenders.value.set(key,{paintHash,others,aborter}),new Promise((resolve$1,reject)=>{others.push({resolve:resolve$1,reject}),renderQueue.value.push({key,paintData:Paint.anyToArray(paintData),opts,resolve:result=>{others.forEach(p$1=>p$1.resolve(result))},reject:error=>{others.forEach(p$1=>p$1.reject(error))},aborter}),startQueue()})}function cleanupCacheEntry(data){data&&(data.bitmap?.close?.(),data.blobUrl&&pendingBlobCleanup.add(data.blobUrl))}function onCacheClear(callback){return cacheListeners.add(callback),()=>cacheListeners.delete(callback)}function notifyCacheCleared(type=`all`,key=null){cacheListeners.forEach(callback=>{try{callback(type,key)}catch(error){console.warn(`Cache clear listener error:`,error)}})}function clearCache(opts=void 0){if(opts)try{let key=getCacheKey(opts);if(cleanupCacheEntry(previews.value.get(key)),previews.value.delete(key),pendingRenders.value.has(key)){let req=pendingRenders.value.get(key);req.aborter.abort(),req.others.forEach(p$1=>p$1.reject(cacheCleanedError)),pendingRenders.value.delete(key)}notifyCacheCleared(`single`,key)}catch{}else stopQueue(),pendingRenders.value.forEach(req=>{req.aborter.abort(),req.others.forEach(p$1=>p$1.reject(cacheCleanedError))}),pendingRenders.value.clear(),previews.value.forEach(cleanupCacheEntry),previews.value.clear(),renderQueue.value.splice(0),activeRenders.value=0,notifyCacheCleared(`all`),startQueue();blobCleanup()}async function getPreview(paintData,opts){return getCachedPreview(opts,paintData)||await generatePreview(paintData,opts)}async function getBlobPreview(paintData,opts){let paintHash=hashPaintData(paintData),key=getCacheKey(opts),bmp=await getPreview(paintData,opts),data=previews.value.get(key);if(!data)return null;if(data.blobUrl&&data.paintHash===paintHash)return data.blobUrl;for(;data.blobGenerating;)await sleep(10);if(data.blobUrl&&data.paintHash===paintHash)return data.blobUrl;data.blobGenerating=!0;let canvas=new OffscreenCanvas(opts.width||TILE_SIZE,opts.height||TILE_SIZE);canvas.getContext(`2d`).drawImage(bmp,0,0);let blobUrl=URL.createObjectURL(await canvas.convertToBlob()),oldBlobUrl=data.blobUrl;return data.blobUrl=blobUrl,delete data.blobGenerating,oldBlobUrl&&pendingBlobCleanup.add(oldBlobUrl),previews.value.has(key)?(blobCleanup(),blobUrl):(pendingBlobCleanup.add(blobUrl),blobCleanup(),null)}function getAreas(opts){let data=previews.value.get(getCacheKey(opts));return data?data.areas:[]}return{cache:previews.value,cacheSize:computed(()=>previews.value.size),isRenderingAny:computed(()=>activeRenders.value>0||renderQueue.value.length>0),queueLength:computed(()=>renderQueue.value.length),activeRenders,isCached,clearCache,onCacheClear,getCacheKey,getPreview,getBlobPreview,getAreas,checkMultipaint,toArray:Paint.anyToArray}});async function renderPaint(paintData,width$1=TILE_SIZE,height$1=TILE_SIZE,radialLight=!1,areas=null,aborter=null){if(paintData=Paint.anyToArray(paintData),!paintData)return renderEmpty(width$1,height$1,aborter);if(checkMultipaint(paintData)){let clipData=areas||calculatePaintAreas(paintData,width$1,height$1);return renderMultipaint(paintData,width$1,height$1,clipData,radialLight,aborter)}else return paintData=Array.isArray(paintData[0])?paintData[0]:paintData,renderSinglePaint(paintData,width$1,height$1,radialLight,aborter)}function createPaint(paintData){let paint={_isEmpty:!0};if(!paintData)return paint;try{paint=new Paint({paint:paintData})}catch{}return paint}function applyAntialiasing(ctx){ctx.imageSmoothingEnabled=!0,ctx.imageSmoothingQuality=`high`,ctx.antialias=!0}function calculatePaintAreas(paintData,width$1,height$1){if(!paintData||!checkMultipaint(paintData))return[[0,0,width$1,height$1]];let paintCount=paintData.length,angle=Math.tan(MULTI_ANGLE*Math.PI/180),stripeWidth=(width$1+height$1*angle)/paintCount,overlap=.5,areas=[];for(let i=0;i0?overlap:0),topRight=startX+stripeWidth+(icoords.map((coord,i)=>coord*(i%2==0?scaleX:scaleY)));for(let i=0;igrad.addColorStop(...args))}else grad=ctx.createLinearGradient(0,0,0,height$1*.65),gradStops.forEach(args=>grad.addColorStop(...args));ctx.fillStyle=grad,ctx.fillRect(0,0,width$1,height$1),ctx.restore()}async function renderPaintLayers(ctx,paint,width$1,height$1,radialLight=!1,aborter=null){if(applyAntialiasing(ctx),ctx.fillStyle=`rgb(${(paint.rgb255||[255,255,255]).join(`, `)})`,ctx.fillRect(0,0,width$1,height$1),aborter?.signal.aborted)return;let grad=ctx.createLinearGradient(0,0,0,height$1);if(grad.addColorStop(0,`rgba(0, 0, 0, 0)`),grad.addColorStop(.65,`rgba(0, 0, 0, 0)`),grad.addColorStop(.8,`rgba(0, 0, 0, 0.15)`),grad.addColorStop(1,`rgba(0, 0, 0, 0.55)`),ctx.fillStyle=grad,ctx.fillRect(0,0,width$1,height$1),aborter?.signal.aborted)return;let metallic=Math.max(0,paint.metallic-paint.roughness/.5);if(metallic>.01){for(;!reflectionImageDone;){if(aborter?.signal.aborted)return;await sleep(10)}if(aborter?.signal.aborted)return;if(ctx.globalCompositeOperation=`multiply`,ctx.globalAlpha=metallic,reflectionImage){let scale=1,imageAspect=reflectionImage.width/reflectionImage.height,canvasAspect=width$1/height$1,drawWidth,drawHeight,offsetX=0,offsetY=0;imageAspect>canvasAspect?(drawHeight=height$1*1,drawWidth=height$1*imageAspect*1):(drawHeight=width$1/imageAspect*1,drawWidth=width$1*1),ctx.drawImage(reflectionImage,0,0,drawWidth,drawHeight)}else{ctx.strokeStyle=`rgba(255, 255, 255, 0.5)`,ctx.lineWidth=1;for(let x=-height$1;x({v889f200a:tileWidth.value,bee2d4dc:tileHeight.value}));let popover=usePopover(),props=__props,emit$1=__emit,mapId=uniqueId(`paint-tile-map`),menuId=uniqueId(`paint-tile-menu`),popMenu=ref(null),elCont=ref(null),elCanvas=ref(null),isLoading=ref(!1),isEmpty=ref(!1),hasRenderedOnce=ref(!1),paintPreviews=usePaintPreviews(),width$1=computed(()=>props.size||props.width),height$1=computed(()=>props.size||props.height),tileWidth=computed(()=>`${width$1.value}px`),tileHeight=computed(()=>`${height$1.value}px`),paints=computed(()=>props.paint?paintPreviews.toArray(props.paint):[]),isMultipaint=computed(()=>paintPreviews.checkMultipaint(paints.value)),paintNames=computed(()=>{let len=props.paint?.length||0;if(len===0)return[];let res=Array.from({length:len}).map((_,idx)=>({tooltip:[`ui.color.paint.unnamed`,{index:idx+1}],menu:[`ui.color.paint.selectOne`,{index:idx+1}],menuAdd:null}));if(props.paintNames?.length>0)for(let i=0;ihoveredPaintIndex.value=idx,tooltip=computed(()=>{let res={name:props.tooltip||props.paintName};return hoveredPaintIndex.value>-1&&paintNames.value[hoveredPaintIndex.value]&&(res.subname=paintNames.value[hoveredPaintIndex.value].tooltip),res}),customMenu=computed(()=>!props.customMenu||props.customMenu.length===0?null:props.customMenu.reduce((res,item,idx)=>item?[...res,{label:item.label||item,click:evt=>{popMenu.value?.hide?.(),nextTick(()=>{item.action?item.action(props.paint,evt):emit$1(`menu-click`,item.value||idx,props.paint,evt)})}}]:res,[])),withMenu=computed(()=>props.withMenu&&(paintAreas.value.length>1||customMenu.value)),opts=computed(()=>({paintId:props.paintId,vehicleName:props.vehicleName,paintName:props.paintName,width:width$1.value,height:height$1.value,radialLight:props.radialLight})),cacheKey=computed(()=>{try{return paintPreviews.getCacheKey(opts.value)}catch{return null}}),paintAreas=computed(()=>{if(!props.paint||isEmpty.value)return[];try{return paintPreviews.getAreas(opts.value)}catch{return[]}}),onContClick=evt=>onClick(-1,evt),onContRMB=()=>withMenu.value&&openMenu();function onClick(idx,evt){popMenu.value?.hide?.(),!props.disabled&&emit$1(`click`,idx,props.paint,evt)}function openMenu(){!elCont.value||!popMenu.value||(popover.hideAll(`paint-tile-menu`),!props.disabled&&popMenu.value.show(elCont.value))}async function renderPreview(){if(!cacheKey.value||!props.paint){isEmpty.value=!0,hasRenderedOnce.value=!1;return}isLoading.value=!0,isEmpty.value=!1;try{let bmp=await paintPreviews.getPreview(paints.value,opts.value);if(elCanvas.value&&bmp){let ctx=elCanvas.value.getContext(`2d`);ctx.clearRect(0,0,width$1.value,height$1.value),ctx.drawImage(bmp,0,0,width$1.value,height$1.value),hasRenderedOnce.value=!0}}catch(error){console.error(`Failed to render preview`,error),isEmpty.value=!0,hasRenderedOnce.value=!1}finally{isLoading.value=!1}}function checkEmpty(){if(!props.paint)return isEmpty.value=!0,hasRenderedOnce.value=!1,!0;if(isMultipaint.value){let allEmpty=paints.value.every(paintArray=>!paintArray||paintArray.length===0);return isEmpty.value=allEmpty,allEmpty&&(hasRenderedOnce.value=!1),allEmpty}return Array.isArray(paints.value)&&paints.value.length===0?(isEmpty.value=!0,hasRenderedOnce.value=!1,!0):(isEmpty.value=!1,!1)}watch(()=>[paints.value,props.paintId,props.vehicleName,props.paintName,width$1.value,height$1.value,props.radialLight],()=>{checkEmpty()?isLoading.value=!1:renderPreview()},{immediate:!0,deep:!0}),watch(()=>props.withAreas,val=>{val||(hoveredPaintIndex.value=-1)});let unsubscribeFromCacheClear=null,outEvents=[`click`,`contextmenu`,`uinav-focus`],listeningOutEvents=!1;function outOfMenu(evt){if(!popMenu.value||!popMenu.value.isShown())return;let el=popMenu.value.getElement();el&&el.contains(evt.detail?.target||evt.target)||nextTick(()=>popMenu.value.hide?.())}return watch(()=>popover.popovers[menuId]?.show,val=>{val?listeningOutEvents||(listeningOutEvents=!0,outEvents.forEach(evt=>document.addEventListener(evt,outOfMenu))):listeningOutEvents&&(listeningOutEvents=!1,outEvents.forEach(evt=>document.removeEventListener(evt,outOfMenu)))}),onMounted(()=>{!checkEmpty()&&renderPreview(),unsubscribeFromCacheClear=paintPreviews.onCacheClear((type,key)=>{(type===`all`||type===`single`&&key===cacheKey.value)&&!checkEmpty()&&hasRenderedOnce.value&&renderPreview()})}),onUnmounted(()=>{unsubscribeFromCacheClear?.(),listeningOutEvents&&outEvents.forEach(evt=>document.removeEventListener(evt,outOfMenu))}),(_ctx,_cache)=>withDirectives((openBlock(),createElementBlock(`div`,{ref_key:`elCont`,ref:elCont,class:normalizeClass([`bng-paint-tile`,{loading:isLoading.value&&!hasRenderedOnce.value,empty:isEmpty.value}]),tabindex:`0`,"bng-nav-item":``,onClick:withModifiers(onContClick,[`stop`]),onContextmenu:withModifiers(onContRMB,[`stop`])},[createBaseVNode(`canvas`,{ref_key:`elCanvas`,ref:elCanvas,width:width$1.value,height:height$1.value},null,8,_hoisted_1$311),__props.withAreas&&paintAreas.value.length>1?(openBlock(),createElementBlock(Fragment,{key:0},[createBaseVNode(`img`,{usemap:`#${unref(mapId)}`,src:unref(emptyImage),alt:``},null,8,_hoisted_2$254),createBaseVNode(`map`,{name:unref(mapId)},[(openBlock(!0),createElementBlock(Fragment,null,renderList(paintAreas.value,(area,index)=>(openBlock(),createElementBlock(`area`,{key:index,shape:`poly`,coords:area.join(`,`),onMouseover:$event=>onMouseOver(index),onMouseleave:_cache[0]||=$event=>onMouseOver(-1),onClick:withModifiers($event=>onClick(index,$event),[`stop`])},null,40,_hoisted_4$190))),128))],8,_hoisted_3$222)],64)):createCommentVNode(``,!0),isEmpty.value||isLoading.value&&!hasRenderedOnce.value?(openBlock(),createElementBlock(`div`,_hoisted_5$162)):createCommentVNode(``,!0),withMenu.value?(openBlock(),createBlock(unref(bngPopoverMenu_default),{key:2,ref_key:`popMenu`,ref:popMenu,name:unref(menuId),focus:``},{default:withCtx(()=>[paintNames.value.length>1?(openBlock(),createElementBlock(Fragment,{key:0},[withDirectives((openBlock(),createBlock(unref(bngButton_default),{accent:unref(ACCENTS).menu,onClick:_cache[1]||=$event=>onClick(-1,$event)},{default:withCtx(()=>[createTextVNode(toDisplayString(_ctx.$tt(`ui.color.paint.selectAll`)),1)]),_:1},8,[`accent`])),[[unref(BngOnUiNav_default),void 0,`ok`,{focusRequired:!0,asMouse:!0}]]),(openBlock(!0),createElementBlock(Fragment,null,renderList(paintNames.value,(paint,index)=>withDirectives((openBlock(),createBlock(unref(bngButton_default),{key:index,accent:unref(ACCENTS).menu,onClick:$event=>onClick(index,$event)},{default:withCtx(()=>[createTextVNode(toDisplayString(_ctx.$tt(...paintNames.value[index].menu))+toDisplayString(paintNames.value[index].menuAdd?`: `+paintNames.value[index].menuAdd:``),1)]),_:2},1032,[`accent`,`onClick`])),[[unref(BngOnUiNav_default),void 0,`ok`,{focusRequired:!0,asMouse:!0}]])),128))],64)):withDirectives((openBlock(),createBlock(unref(bngButton_default),{key:1,accent:unref(ACCENTS).menu,onClick:_cache[2]||=$event=>onClick(0,$event)},{default:withCtx(()=>[createTextVNode(toDisplayString(_ctx.$tt(`ui.color.paint.select`)),1)]),_:1},8,[`accent`])),[[unref(BngOnUiNav_default),void 0,`ok`,{focusRequired:!0,asMouse:!0}]]),customMenu.value?.length>0?(openBlock(!0),createElementBlock(Fragment,{key:2},renderList(customMenu.value,(item,index)=>withDirectives((openBlock(),createBlock(unref(bngButton_default),{key:index,accent:unref(ACCENTS).menu,onClick:$event=>item.click($event)},{default:withCtx(()=>[createTextVNode(toDisplayString(_ctx.$tt(item.label)),1)]),_:2},1032,[`accent`,`onClick`])),[[unref(BngOnUiNav_default),void 0,`ok`,{focusRequired:!0,asMouse:!0}]])),128)):createCommentVNode(``,!0)]),_:1},8,[`name`])):createCommentVNode(``,!0)],34)),[[unref(BngTooltip_default),_ctx.$tt(tooltip.value.name)+(tooltip.value.subname?` - `+_ctx.$tt(...tooltip.value.subname):``),__props.tooltipPosition],[unref(BngOnUiNav_default),void 0,`ok`,{asMouse:!0,focusRequired:!0}]])}},bngPaintTile_default=__plugin_vue_export_helper_default(_sfc_main$356,[[`__scopeId`,`data-v-25bf2552`]]),_hoisted_1$310=[`tabindex`],_sfc_main$355={__name:`bngPill`,props:{marked:{type:Boolean,default:!1}},setup(__props){let props=__props,attrs=useAttrs(),hasClickEvent=computed(()=>attrs&&attrs.onClick),isMarked=ref(props.marked);return watch(()=>props.marked,newValue=>isMarked.value=newValue),(_ctx,_cache)=>(openBlock(),createElementBlock(`span`,{"bng-nav-item":``,class:normalizeClass([`bng-pill`,{"pill-marked":isMarked.value,"pill-clickable":hasClickEvent.value}]),tabindex:hasClickEvent.value?0:-1},[renderSlot(_ctx.$slots,`default`,{},void 0,!0)],10,_hoisted_1$310))}},bngPill_default=__plugin_vue_export_helper_default(_sfc_main$355,[[`__scopeId`,`data-v-2d28d1ed`]]),_sfc_main$354={__name:`bngPillCheckbox`,props:{modelValue:{type:Boolean,default:null},markedIcon:{type:[Boolean,Object],default:!0}},emits:[`update:modelValue`,`valueChanged`,`change`],setup(__props,{emit:__emit}){let props=__props,emit$1=__emit,defaultValue=ref(!1),isChecked=computed({get:()=>props.modelValue!==void 0&&props.modelValue!==null?props.modelValue:defaultValue.value,set:newValue=>{props.modelValue!==void 0&&props.modelValue!==null?notifyListeners(newValue):(defaultValue.value=newValue,emit$1(`valueChanged`,newValue),emit$1(`change`,newValue))}}),onChecked=()=>isChecked.value=!isChecked.value;function notifyListeners(value){emit$1(`update:modelValue`,value),emit$1(`change`,value),emit$1(`valueChanged`,value)}return(_ctx,_cache)=>(openBlock(),createElementBlock(`span`,{class:normalizeClass([`bng-pill-checkbox`,{"show-icon":isChecked.value&&props.markedIcon}])},[createVNode(unref(bngPill_default),{marked:isChecked.value,onClick:onChecked,onKeyup:withKeys(onChecked,[`space`])},{default:withCtx(()=>[createBaseVNode(`span`,{class:normalizeClass({"pill-content":!0,"uses-mark":__props.markedIcon})},[renderSlot(_ctx.$slots,`default`,{},void 0,!0)],2),createVNode(unref(bngIcon_default),{class:`pill-mark-icon`,type:props.markedIcon===!0?unref(icons).checkmark:props.markedIcon||unref(icons).checkmark},null,8,[`type`])]),_:3},8,[`marked`])],2))}},bngPillCheckbox_default=__plugin_vue_export_helper_default(_sfc_main$354,[[`__scopeId`,`data-v-04487830`]]),_hoisted_1$309={class:`bng-pill-filters`,tabindex:`0`},_sfc_main$353={__name:`bngPillFilters`,props:{modelValue:Array,options:{type:Array,required:!0},selectOnFocus:Boolean,selectMany:Boolean,showCheckIcon:{type:Boolean,default:!0},required:Boolean},emits:[`update:modelValue`,`valueChanged`],setup(__props,{expose:__expose,emit:__emit}){let props=__props,emit$1=__emit;__expose({focusPrevious,focusNext,toggleFocusedPill,focusIndex});let scrollable=ref(null),pills=ref([]),currentPillIndex=ref(-1),defaultSelected=ref([]),selectedValues=computed({get:()=>props.modelValue?props.modelValue:defaultSelected.value,set:newValue=>{props.modelValue?(emit$1(`update:modelValue`,newValue),emit$1(`valueChanged`,newValue)):(defaultSelected.value=newValue,emit$1(`valueChanged`,newValue))}}),pillConfigs=computed(()=>toRaw(props.options).map(x=>({...x,selected:selectedValues.value&&selectedValues.value.length>0&&selectedValues.value.includes(x.value)})));function focusPrevious(){currentPillIndex.value=currentPillIndex.value>0?currentPillIndex.value-1:0,pills.value[currentPillIndex.value].querySelector(`.bng-pill`).focus(),console.log(`currentPillIndex.value`,currentPillIndex.value)}function focusNext(){currentPillIndex.value{scrollable.value.addEventListener(`wheel`,evt=>{evt.preventDefault(),scrollable.value.scrollLeft+=evt.deltaY}),currentPillIndex.value=selectedValues.value.length>0?pillConfigs.value.findIndex(x=>x.value===selectedValues.value[0]):-1,currentPillIndex.value>-1&&focusPill(currentPillIndex.value)});let onPillValueChanged=(key,value)=>{props.selectOnFocus||(console.log(`onPillValueChanged`,key,value),setPillValue(key,value))},onPillFocusIn=(key,index)=>{focusPill(index),props.selectOnFocus&&setPillValue(key,!(selectedValues.value.length>0&&selectedValues.value.includes(key)))};function setPillValue(key,checked){if(currentPillIndex.value=pillConfigs.value.findIndex(x=>x.value===key),props.required&&!checked&&selectedValues.value.includes(key)&&selectedValues.value.length==1){selectedValues.value=[key];return}if(!props.selectMany){selectedValues.value=checked?[key]:[];return}let isExisting=selectedValues.value.includes(key);checked&&!isExisting?selectedValues.value=[...selectedValues.value,key]:!checked&&isExisting&&(selectedValues.value=selectedValues.value.filter(x=>x!==key))}function focusPill(index){let pillEl=pills.value[index],scrollableRect=scrollable.value.getBoundingClientRect(),pillRect=pillEl.getBoundingClientRect();pillRect.left>=scrollableRect.left&&pillRect.right<=scrollableRect.right||window.requestAnimationFrame(()=>{scrollable.value.scrollBy({left:pillEl.getBoundingClientRect().right})})}return(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$309,[createBaseVNode(`div`,{class:`pills-wrapper`,ref_key:`scrollable`,ref:scrollable},[(openBlock(!0),createElementBlock(Fragment,null,renderList(pillConfigs.value,(pill,index)=>(openBlock(),createElementBlock(`div`,{key:pill.value,ref_for:!0,ref_key:`pills`,ref:pills,class:`pill-wrapper`},[createVNode(unref(bngPillCheckbox_default),{markedIcon:__props.showCheckIcon,modelValue:pill.selected,"onUpdate:modelValue":$event=>pill.selected=$event,onValueChanged:value=>onPillValueChanged(pill.value,value),onFocusin:$event=>onPillFocusIn(pill.value,index)},{default:withCtx(()=>[createTextVNode(toDisplayString(pill.label),1)]),_:2},1032,[`markedIcon`,`modelValue`,`onUpdate:modelValue`,`onValueChanged`,`onFocusin`])]))),128))],512)]))}},bngPillFilters_default=__plugin_vue_export_helper_default(_sfc_main$353,[[`__scopeId`,`data-v-580a9eac`]]),_sfc_main$352={__name:`bngPillFiltersContainer`,props:{options:{type:Array,required:!0},selectOnNavigation:{type:Boolean,default:!0},required:Boolean,selectMany:Boolean,hasCheckedIcon:{default:!0,type:Boolean}},emits:[`update:modelValue`,`valueChanged`],setup(__props,{expose:__expose,emit:__emit}){let emit$1=__emit,props=__props,selectedItems=ref([]),bngFiltersContainer=ref(null),filtersContainer=ref(null),bngPillFiltersRef=ref(null);__expose({selectPrevious:()=>bngPillFiltersRef.value.selectPrevious(),selectNext:()=>bngPillFiltersRef.value.selectNext(),selectCurrent:()=>bngPillFiltersRef.value.selectCurrent(),focusAndScrollToSelected:focusSelected});let selectedItemId=``;onMounted(()=>{filtersContainer.value.addEventListener(`wheel`,evt=>{evt.preventDefault(),filtersContainer.value.scrollLeft+=evt.deltaY})});function focusSelected(){props.selectMany||!props.selectOnNavigation||scrollToElement(selectedItemId)}function onContainerFocusOut($event){!($event.relatedTarget&&bngFiltersContainer.value.contains($event.relatedTarget))&&!props.selectMany&&selectedItemId&&scrollToElement(selectedItemId)}function onValueChanged(items$2,id){selectedItems.value=items$2,selectedItemId=id,emit$1(`valueChanged`,items$2,id)}function onPillItemFocusIn(id){scrollToElement(id)}function scrollToElement(id){let scrollableContainer=filtersContainer.value,el=scrollableContainer.querySelector(`#${id}`);if(el){let scrollableContainerRect=scrollableContainer.getBoundingClientRect(),itemRect=el.getBoundingClientRect();if(itemRect.left>=scrollableContainerRect.left&&itemRect.right<=scrollableContainerRect.right)return;window.requestAnimationFrame(()=>{let scrollValue=itemRect.left(openBlock(),createElementBlock(`div`,{class:`bng-filters-container`,ref_key:`bngFiltersContainer`,ref:bngFiltersContainer,tabindex:`0`,onFocusout:onContainerFocusOut},[_cache[0]||=createBaseVNode(`div`,{class:`fade-effect left-fade-effect`},null,-1),_cache[1]||=createBaseVNode(`div`,{class:`fade-effect right-fade-effect`},null,-1),createBaseVNode(`div`,{class:`scroll-container`,ref_key:`filtersContainer`,ref:filtersContainer},[createVNode(unref(bngPillFilters_default),{ref_key:`bngPillFiltersRef`,ref:bngPillFiltersRef,options:__props.options,"select-on-navigation":__props.selectOnNavigation,required:__props.required,"select-many":__props.selectMany,"show-checked-icon":__props.hasCheckedIcon,onValueChanged,onPillItemFocusIn},null,8,[`options`,`select-on-navigation`,`required`,`select-many`,`show-checked-icon`])],512)],544))}},bngPillFiltersContainer_default=__plugin_vue_export_helper_default(_sfc_main$352,[[`__scopeId`,`data-v-498af92b`]]),_hoisted_1$308=[`data-bng-popover-name`],containerSelector=`.popover-container`,_sfc_main$351={__name:`bngPopoverContent`,props:{name:String,offset:{type:Number,default:4},hideArrow:Boolean,placement:String,disabled:Boolean},emits:[`show`,`hide`,`placementChanged`],setup(__props,{expose:__expose,emit:__emit}){let props=__props,emit$1=__emit,popover=usePopover(),popoverName,popoverContent=ref(null),arrow$3=ref(null),show=ref(!1),unwatchShow,unwatchPlacement,teleportTargetExists=ref(!1),observer$2=null,scopeActivated=ref(!1),isRender=computed(()=>!props.disabled&&teleportTargetExists.value&&show.value),hide$2=()=>!props.disabled&&popover.hide(popoverName),expose={hide:hide$2,show:(el=void 0)=>!props.disabled&&popover.show(popoverName,el),toggle:(forceVal=void 0)=>popover.toggle(popoverName,!props.disabled&&forceVal),isShown:()=>popover.isShown(popoverName)};__expose(expose),watch(()=>show.value,value=>emit$1(value?`show`:`hide`,{name:props.name,...expose})),watch(()=>props.name,(newName,oldName)=>{oldName&&disposePopover(oldName),props.disabled||setupPopover()},{immediate:!0}),watch(()=>props.disabled,value=>{value?(popover.hide(popoverName),disposePopover(popoverName)):setupPopover()}),watch(isRender,async value=>{value&&(await nextTick(),checkSlotContent())});let onMenu=()=>{scopeActivated.value=!1};onBeforeUnmount(()=>{disposePopover(popoverName),observer$2&&=(observer$2.disconnect(),null)}),onMounted(async()=>{teleportTargetExists.value=!!document.querySelector(containerSelector),teleportTargetExists.value||(observer$2=new MutationObserver(()=>{!teleportTargetExists.value&&document.querySelector(containerSelector)&&(teleportTargetExists.value=!0,observer$2.disconnect(),observer$2=null)}),observer$2.observe(document.body,{childList:!0,subtree:!0})),isRender.value&&(await nextTick(),checkSlotContent())});function onScopeChanged(activated,event){scopeActivated.value=activated,!activated&&!event.detail.force&&popover.hide(popoverName)}function checkSlotContent(){let navigableElements=popoverContent.value.querySelectorAll(NAVIGABLE_ELEMENTS_SELECTOR);navigableElements&&navigableElements.length>0&&!scopeActivated.value&&(scopeActivated.value=!0)}function setupPopover(){popoverName=props.name||uniqueId(`bng-popover-content`);let res=popover.register(popoverName,popoverContent,props.placement,{arrow:props.hideArrow?void 0:arrow$3,offset:props.offset});res&&(unwatchShow=watch(res.show,value=>show.value=value),unwatchPlacement=watch(res.placement,placement=>emit$1(`placementChanged`,placement)))}function disposePopover(name){unwatchShow&&=(unwatchShow(),null),unwatchPlacement&&=(unwatchPlacement(),null),popover.unregister(name),show.value=!1,popoverName=null}return(_ctx,_cache)=>isRender.value?(openBlock(),createBlock(Teleport,{key:0,to:`.popover-container`},[withDirectives((openBlock(),createElementBlock(`div`,{ref_key:`popoverContent`,ref:popoverContent,"data-bng-popover-name":unref(popoverName),class:`bng-popover`,onActivate:_cache[0]||=$event=>onScopeChanged(!0,$event),onDeactivate:_cache[1]||=$event=>onScopeChanged(!1,$event)},[renderSlot(_ctx.$slots,`default`,{hide:hide$2},void 0,!0),__props.hideArrow?createCommentVNode(``,!0):(openBlock(),createElementBlock(`span`,{key:0,ref_key:`arrow`,ref:arrow$3,class:`bng-popover-arrow`},null,512))],40,_hoisted_1$308)),[[unref(BngScopedNav_default),{activated:scopeActivated.value,type:unref(SCOPED_NAV_TYPES).popover}],[unref(BngOnUiNav_default),onMenu,`menu`]])])):createCommentVNode(``,!0)}},bngPopoverContent_default=__plugin_vue_export_helper_default(_sfc_main$351,[[`__scopeId`,`data-v-4938e558`]]),_sfc_main$350=Object.assign({inheritAttrs:!1},{__name:`bngPopoverMenu`,props:{name:String,offset:{type:Number,default:4},hideArrow:Boolean,disabled:Boolean,focus:Boolean},emits:[`show`,`hide`,`placementChanged`],setup(__props,{expose:__expose,emit:__emit}){let popover=usePopover(),props=__props,emit$1=__emit,relay={show:(...args)=>emit$1(`show`,...args),hide:(...args)=>emit$1(`hide`,...args),placementChanged:(...args)=>emit$1(`placementChanged`,...args)},popoverContent=ref(null),popoverMenu=ref(null),hide$2=(...args)=>popoverContent.value.hide(...args);return __expose({hide:hide$2,show:(...args)=>popoverContent.value.show(...args),toggle:(...args)=>popoverContent.value.toggle(...args),isShown:(...args)=>popoverContent.value.isShown(...args),getElement:()=>popoverMenu.value}),watchEffect(()=>{if(props.name in popover.popovers){let pop=popover.popovers[props.name];!pop.show&&nextTick(()=>{pop.target&&document.activeElement===document.body&&setFocusExternal(pop.target,!0,!1)})}}),(_ctx,_cache)=>(openBlock(),createBlock(unref(bngPopoverContent_default),{ref_key:`popoverContent`,ref:popoverContent,name:__props.name,offset:__props.offset,"hide-arrow":__props.hideArrow,disabled:__props.disabled,onPlacementChanged:relay.placementChanged,onHide:hide$2},{default:withCtx(()=>[createBaseVNode(`div`,{ref_key:`popoverMenu`,ref:popoverMenu,class:`bng-popover-menu`},[renderSlot(_ctx.$slots,`default`,{hide:hide$2},void 0,!0)],512)]),_:3},8,[`name`,`offset`,`hide-arrow`,`disabled`,`onPlacementChanged`]))}}),bngPopoverMenu_default=__plugin_vue_export_helper_default(_sfc_main$350,[[`__scopeId`,`data-v-fe39553c`]]),_hoisted_1$307={class:`bng-progress-bar`},_hoisted_2$253={key:0,class:`header`},_hoisted_3$221={class:`header-left`},_hoisted_4$189={class:`header-right`},_hoisted_5$161={class:`progress-bar`},_hoisted_6$139=[`innerHTML`],_hoisted_7$121={key:1,class:`progress-fill-indeterminate`},_sfc_main$349={__name:`bngProgressBar`,props:{value:{type:Number,default:0},oldValue:{type:Number,default:0},min:{type:Number,default:0},max:{type:Number,required:!0},headerLeft:String,headerRight:String,showValueLabel:{type:Boolean,default:!0},valueLabelFormat:{type:[String,Function],default:`#value#`},valueColor:{type:String,default:`#ff6600`},oldValueColor:{type:String,default:`#ffffff`},indeterminate:Boolean,animateDifference:Boolean,gradient:Boolean},setup(__props,{expose:__expose}){useCssVars(_ctx=>({v5113e7b0:__props.valueColor,v14406f01:progressFillUnits.value,v6b373656:oldProgressFillUnits.value}));let props=__props;__expose({decreaseValueBy,increaseValueBy,setValue:value=>updateCurrentValue(value)});let currentValue=ref(null),valueHTML=computed(()=>{let res;return res=typeof props.valueLabelFormat==`function`?props.valueLabelFormat(props.value,{min:props.min,max:props.max}):props.valueLabelFormat.replace(/ +/g,` `).replace(`#value#`,`${currentValue.value}${props.max}`),res}),progressFillUnits=computed(()=>1-(currentValue.value-props.min)/(props.max-props.min)),oldProgressFillUnits=computed(()=>1-(props.oldValue-props.min)/(props.max-props.min));watch(()=>props.value,updateCurrentValue),onMounted(()=>{updateCurrentValue(props.min>props.value?props.min:props.value)});function decreaseValueBy(value){let newValue=currentValue.value-value;newValueprops.max&&(newValue=props.max),updateCurrentValue(newValue)}function updateCurrentValue(newValue){currentValue.value=newValue}return(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$307,[__props.headerLeft||__props.headerRight?(openBlock(),createElementBlock(`div`,_hoisted_2$253,[createBaseVNode(`span`,_hoisted_3$221,toDisplayString(__props.headerLeft),1),createBaseVNode(`span`,_hoisted_4$189,toDisplayString(__props.headerRight),1)])):createCommentVNode(``,!0),createBaseVNode(`div`,_hoisted_5$161,[__props.showValueLabel?(openBlock(),createElementBlock(`div`,{key:0,class:`info`,innerHTML:valueHTML.value},null,8,_hoisted_6$139)):createCommentVNode(``,!0),__props.indeterminate?(openBlock(),createElementBlock(`span`,_hoisted_7$121)):(openBlock(),createElementBlock(`span`,{key:2,class:normalizeClass({"progress-fill":!0,"progress-fill-gradient":__props.gradient,"animate-progress":__props.animateDifference&&__props.value>__props.oldValue}),style:normalizeStyle({backgroundColor:__props.valueColor,zIndex:__props.value<__props.oldValue?2:1})},null,6)),__props.oldValue?(openBlock(),createElementBlock(`span`,{key:3,class:normalizeClass({"second-progress-fill":!0,"progress-fill-gradient":__props.gradient,"animate-progress":__props.animateDifference&&__props.value<__props.oldValue}),style:normalizeStyle({backgroundColor:__props.oldValueColor,zIndex:__props.value<__props.oldValue?1:2})},null,6)):createCommentVNode(``,!0)])]))}},bngProgressBar_default=__plugin_vue_export_helper_default(_sfc_main$349,[[`__scopeId`,`data-v-1ca6aacd`]]);function shrinkNum(num,decimals=0){let units=[``,`K`,`M`,`B`,`T`,`Q`];if(!num)return`0`;if(isNaN(parseFloat(num))||!isFinite(+num))return`n/a`;let power$1=Math.floor(Math.log(Math.abs(+num))/Math.log(1e3));return power$1>=units.length&&(power$1=units.length-1),(num/1e3**power$1).toFixed(decimals).replace(/\.0+$/,``)+units[power$1]}var _hoisted_1$306={key:1,class:`key-label`},_hoisted_2$252={class:`value-label`},_sfc_main$348={__name:`bngPropVal`,props:{iconType:[String,Object],keyLabel:String,valueLabel:{required:!0},shrinkNum:Boolean,iconColor:{type:String,default:`#fff`},noGap:{type:Boolean,default:!1},noIcon:{type:Boolean,default:!1}},setup(__props){let props=__props,itemClass=computed(()=>({"info-item":!0,"with-icon":props.iconType,"no-key":!props.keyLabel,"no-gap":props.noGap})),value=computed(()=>{let i=props.valueLabel;return props.shrinkNum?shrinkNum(i,0):i});return(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,{class:normalizeClass(itemClass.value)},[__props.iconType&&!__props.noIcon?(openBlock(),createBlock(unref(bngIcon_default),{key:0,class:`icon`,type:__props.iconType,color:__props.iconColor},null,8,[`type`,`color`])):createCommentVNode(``,!0),__props.keyLabel?(openBlock(),createElementBlock(`span`,_hoisted_1$306,toDisplayString(__props.keyLabel),1)):createCommentVNode(``,!0),createBaseVNode(`span`,_hoisted_2$252,toDisplayString(value.value),1)],2))}},bngPropVal_default=__plugin_vue_export_helper_default(_sfc_main$348,[[`__scopeId`,`data-v-fa2e2062`]]),_hoisted_1$305={class:`header`},_sfc_main$347={__name:`bngScreenHeading`,props:{blurDelay:Number,preheadings:Array,divider:Boolean,type:{type:String,default:`line`,validator:v=>[`line`,`ribbon`].includes(v)||v===``}},setup(__props){let blurVal=ref(!1);onMounted(()=>window.setTimeout(()=>blurVal.value=!0,~~+props.blurDelay));let props=__props,preheadings=computed(()=>Array.isArray(props.preheadings)&&props.preheadings.length>0?props.preheadings:null);return(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,{class:normalizeClass([`bng-screen-heading`,{[`heading-style-${__props.type}`]:!0,prehead:preheadings.value}])},[preheadings.value?withDirectives((openBlock(),createElementBlock(`span`,{key:0,class:normalizeClass([`pre-header`,{"with-divider":__props.divider}])},[(openBlock(!0),createElementBlock(Fragment,null,renderList(preheadings.value,preheading=>(openBlock(),createElementBlock(`span`,{class:`location`,key:preheading},toDisplayString(preheading),1))),128))],2)),[[unref(BngBlur_default),blurVal.value]]):createCommentVNode(``,!0),withDirectives((openBlock(),createElementBlock(`h1`,_hoisted_1$305,[renderSlot(_ctx.$slots,`default`,{},void 0,!0)])),[[unref(BngBlur_default),blurVal.value]])],2))}},bngScreenHeading_default=__plugin_vue_export_helper_default(_sfc_main$347,[[`__scopeId`,`data-v-f6d9f077`]]),_hoisted_1$304={class:`header`},_hoisted_2$251={key:0,class:`decorator-item`,width:`100%`,height:`100%`,viewBox:`0 0 32 40`,preserveAspectRatio:`none`,fill:`none`,xmlns:`http://www.w3.org/2000/svg`},_hoisted_3$220={key:1,class:`decorator-item`,width:`100%`,height:`100%`,viewBox:`0 0 36 40`,preserveAspectRatio:`xMaxYMid slice`,fill:`none`,xmlns:`http://www.w3.org/2000/svg`},_hoisted_4$188={key:2,class:`decorator-item`,width:`100%`,height:`100%`,viewBox:`0 0 36 40`,preserveAspectRatio:`xMaxYMid slice`,fill:`none`,xmlns:`http://www.w3.org/2000/svg`},_sfc_main$346={__name:`bngScreenHeadingV2`,props:{blurDelay:Number,preheadings:Array,divider:Boolean,type:{type:String,default:`1`,validator:v=>[`1`,`2`,`3`].includes(v)||v===``},hintVisible:Boolean,hintLabel:String,hintIcon:String,hintAccent:String,hintBindingEvent:String},emits:[`hint`],setup(__props,{emit:__emit}){let blurVal=ref(!1);onMounted(()=>window.setTimeout(()=>blurVal.value=!0,~~+props.blurDelay));let props=__props,preheadings=computed(()=>Array.isArray(props.preheadings)&&props.preheadings.length>0?props.preheadings:null);return computed(()=>props.hintVisible??!1),computed(()=>props.hintLabel??``),computed(()=>props.hintIcon??icons.arrowLargeLeft),computed(()=>props.hintAccent??ACCENTS.outlined),(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,{class:normalizeClass([`bng-screen-heading`,{[`heading-style-${__props.type}`]:!0,prehead:preheadings.value}])},[renderSlot(_ctx.$slots,`preheadings`,{},void 0,!0),withDirectives((openBlock(),createElementBlock(`span`,_hoisted_1$304,[createBaseVNode(`div`,{class:normalizeClass(`decorator type${__props.type}`)},[__props.type===`1`?(openBlock(),createElementBlock(`svg`,_hoisted_2$251,[..._cache[0]||=[createBaseVNode(`path`,{d:`M16.6328 40H1.62891L14.0039 6H14.002L11.8174 0H26.8174L29.001 6H29.0078L16.6328 40Z`,fill:`var(--bng-orange-400)`},null,-1)]])):createCommentVNode(``,!0),__props.type===`2`?(openBlock(),createElementBlock(`svg`,_hoisted_3$220,[..._cache[1]||=[createBaseVNode(`path`,{d:`M18.6366 0H34.0094L26.73 20H11.3572L18.6366 0Z`,fill:`#DA5706`},null,-1),createBaseVNode(`path`,{d:`M19.4504 40H4.07812L11.3572 20L4.07812 0H19.4504L26.7295 20L19.4504 40Z`,fill:`var(--bng-orange-400)`},null,-1)]])):createCommentVNode(``,!0),__props.type===`3`?(openBlock(),createElementBlock(`svg`,_hoisted_4$188,[..._cache[2]||=[createBaseVNode(`path`,{d:`M18.6366 0H34.0094L26.73 20H11.3572L18.6366 0Z`,fill:`#DA5706`},null,-1),createBaseVNode(`path`,{d:`M19.4504 40H4.07812L11.3572 20L4.07812 0H19.4504L26.7295 20L19.4504 40Z`,fill:`var(--bng-orange-400)`},null,-1)]])):createCommentVNode(``,!0)],2),createBaseVNode(`h1`,null,[renderSlot(_ctx.$slots,`default`,{},void 0,!0)])])),[[unref(BngBlur_default),blurVal.value]])],2))}},bngScreenHeadingV2_default=__plugin_vue_export_helper_default(_sfc_main$346,[[`__scopeId`,`data-v-4854a8bd`]]),_hoisted_1$303={class:`label select`},_hoisted_2$250={class:`bng-select-indicator`},_sfc_main$345={__name:`bngSelect`,props:mergeModels({value:void 0,options:{type:Array,required:!0},config:{type:Object,default:()=>({value:opt=>opt,label:opt=>opt})},loop:Boolean,labelClickable:Boolean,labelPopover:String,disabled:Boolean,navLeftEvent:{type:String,default:`focus_l`},navRightEvent:{type:String,default:`focus_r`}},{modelValue:{type:[Object,Boolean,Number,String],default:void 0},modelModifiers:{}}),emits:mergeModels([`change`,`valueChanged`,`label-click`],[`update:modelValue`]),setup(__props,{expose:__expose,emit:__emit}){let leftBinding=ref(),rightBinding=ref(),vModel=useModel(__props,`modelValue`),props=__props,elContainer=ref(),elContent=ref(),findOptionValue=(valueToFind,opts)=>Math.max(0,opts.findIndex(opt=>props.config.value(opt)===valueToFind)),index=ref(getInitialValue()),current=computed(()=>({option:props.options[index.value],value:props.config.value(props.options[index.value]),label:props.config.label(props.options[index.value])})),leftIconClass=computed(()=>({"with-binding":leftBinding.value?.displayed})),rightIconClass=computed(()=>({"with-binding":rightBinding.value?.displayed})),isLeftDisabled=props.loop?!1:computed(()=>index.value==0),isRightDisabled=props.loop?!1:computed(()=>index.value==props.options.length-1),emit$1=__emit,goPrev=()=>{!props.disabled&&!isLeftDisabled.value&&changeIndex(-1)},goNext=()=>{!props.disabled&&!isRightDisabled.value&&changeIndex(1)};__expose({goNext,goPrev,getElement:()=>elContainer.value,getContentElement:()=>elContent.value}),watch(()=>props.value,()=>index.value=props.value!==null&&props.value!==void 0?findOptionValue(props.value,props.options):0),watch(vModel,val=>index.value=val==null?0:findOptionValue(val,props.options)),watch(()=>index.value,updateValue);function updateValue(){emit$1(`valueChanged`,current.value.value,current.value.label,current.value.option),emit$1(`change`,current.value.value,current.value.label,current.value.option),vModel.value=current.value.value}function changeIndex(offset$2){props.loop?index.value=(props.options.length+index.value+offset$2)%props.options.length:index.value=clamp(index.value+offset$2,0,props.options.length-1)}function getInitialValue(){return vModel.value!==null&&vModel.value!==void 0?findOptionValue(vModel.value,props.options):`value`in props?findOptionValue(props.value,props.options):0}return(_ctx,_cache)=>withDirectives((openBlock(),createElementBlock(`div`,{ref_key:`elContainer`,ref:elContainer,class:`bng-select`,"bng-nav-item":``},[renderSlot(_ctx.$slots,`previousButton`,{click:goPrev,disabled:unref(isLeftDisabled)},()=>[createVNode(unref(bngButton_default),{"bng-no-nav":`true`,disabled:__props.disabled||unref(isLeftDisabled),accent:unref(ACCENTS).text,mute:_ctx.$attrs.mute,"data-testid":`previous-btn`,onClick:goPrev},{default:withCtx(()=>[createVNode(unref(bngIcon_default),{type:leftBinding.value?.displayed?unref(icons).arrowSmallLeft:unref(icons).arrowLargeLeft,class:normalizeClass(leftIconClass.value)},null,8,[`type`,`class`]),__props.navLeftEvent&&__props.navLeftEvent!==`focus_l`?(openBlock(),createBlock(unref(bngBinding_default),{key:0,ref_key:`leftBinding`,ref:leftBinding,uiEvent:__props.navLeftEvent,controller:``},null,8,[`uiEvent`])):createCommentVNode(``,!0)]),_:1},8,[`disabled`,`accent`,`mute`])],!0),withDirectives((openBlock(),createElementBlock(`div`,{ref_key:`elContent`,ref:elContent,class:normalizeClass([`bng-select-content`,{"label-clickable":__props.labelClickable}]),onClick:_cache[0]||=withModifiers($event=>__props.labelClickable&&emit$1(`label-click`),[`stop`])},[renderSlot(_ctx.$slots,`display`,{label:current.value.label,value:current.value.value},()=>[createBaseVNode(`span`,_hoisted_1$303,toDisplayString(current.value.label),1),_cache[1]||=createBaseVNode(`label`,{flavour:``},null,-1)],!0)],2)),[[unref(BngSoundClass_default),!__props.disabled&&__props.labelClickable&&`bng_click_hover_generic`],[unref(BngPopover_default),__props.labelPopover,`bottom`,{click:!0}]]),renderSlot(_ctx.$slots,`nextButton`,{click:goNext,disabled:unref(isRightDisabled)},()=>[createVNode(unref(bngButton_default),{"bng-no-nav":`true`,disabled:__props.disabled||unref(isRightDisabled),accent:unref(ACCENTS).text,mute:_ctx.$attrs.mute,"data-testid":`next-btn`,onClick:goNext},{default:withCtx(()=>[__props.navRightEvent&&__props.navRightEvent!==`focus_r`?(openBlock(),createBlock(unref(bngBinding_default),{key:0,ref_key:`rightBinding`,ref:rightBinding,uiEvent:__props.navRightEvent,controller:``},null,8,[`uiEvent`])):createCommentVNode(``,!0),createVNode(unref(bngIcon_default),{type:rightBinding.value?.displayed?unref(icons).arrowSmallRight:unref(icons).arrowLargeRight,class:normalizeClass(rightIconClass.value)},null,8,[`type`,`class`])]),_:1},8,[`disabled`,`accent`,`mute`])],!0),createBaseVNode(`div`,_hoisted_2$250,[(openBlock(!0),createElementBlock(Fragment,null,renderList(__props.options.length,idx=>(openBlock(),createElementBlock(`div`,{key:idx,class:normalizeClass({active:idx-1===index.value})},null,2))),128))])])),[[unref(BngOnUiNav_default),goPrev,__props.navLeftEvent,{focusRequired:!0}],[unref(BngOnUiNav_default),goNext,__props.navRightEvent,{focusRequired:!0}],[unref(BngDisabled_default),__props.disabled]])}},bngSelect_default=__plugin_vue_export_helper_default(_sfc_main$345,[[`__scopeId`,`data-v-d1cacb72`]]),_hoisted_1$302={class:`bng-simple-graph`},_hoisted_2$249={key:0,class:`y-axis`},_hoisted_3$219={class:`y-values`},_hoisted_4$187={class:`max-value`},_hoisted_5$160={class:`axis-label`},_hoisted_6$138={key:0,class:`unit`},_hoisted_7$120={class:`min-value`},_hoisted_8$100={viewBox:`0 0 100 100`,preserveAspectRatio:`none`,class:`graph-svg`},_hoisted_9$90=[`width`,`height`],_hoisted_10$78=[`d`,`stroke`],_hoisted_11$70=[`d`,`stroke`],_hoisted_12$58=[`width`,`height`],_hoisted_13$50=[`d`,`stroke`],_hoisted_14$45=[`d`,`stroke`],_hoisted_15$43={key:0,width:`100`,height:`100`,fill:`url(#subgrid)`},_hoisted_16$40={class:`grid`},_hoisted_17$33=[`y1`,`y2`,`stroke`],_hoisted_18$30={class:`background-ranges`},_hoisted_19$25=[`x`,`width`,`fill`,`stroke`,`opacity`],_hoisted_20$21={class:`vertical-guides`},_hoisted_21$19=[`x1`,`x2`,`stroke`,`opacity`],_hoisted_22$17=[`x1`,`x2`],_hoisted_23$16=[`d`,`fill`,`opacity`],_hoisted_24$15=[`d`,`stroke`],_hoisted_25$14={key:2,class:`x-axis`},_hoisted_26$12={class:`x-values`},_hoisted_27$12={class:`min-value`},_hoisted_28$11={class:`axis-label`},_hoisted_29$11={key:0,class:`unit`},_hoisted_30$10={class:`max-value`},_sfc_main$344={__name:`bngSimpleGraph`,props:{config:{type:Object,default:()=>({showLabels:!1,xAxis:{key:`x`,label:`X Axis`,unit:``},yAxis:{key:`y`,label:`Y Axis`,unit:``}})},points:{type:Array,default:()=>[]},gridColor:{type:String,default:`var(--bng-ter-blue-gray-500)`},backgroundColor:{type:String,default:`rgba(0, 0, 0, 0.1)`},currentX:{type:Number,default:null},verticalGuides:{type:Array,default:()=>[]},ranges:{type:Array,default:()=>[]},gridDivisions:{type:Array,default:()=>[50,20]},subgridDivider:{type:Number,default:2},showSubgrid:{type:Boolean,default:!0},singleLabel:{type:Object,default:null}},setup(__props){useCssVars(_ctx=>({v194c2663:__props.config.showLabels?`2rem`:`0`,fdb9891e:__props.backgroundColor}));let props=__props,gridSizes=computed(()=>({x:100/props.gridDivisions[0],y:100/props.gridDivisions[1]})),xScale=computed(()=>{if(props.config?.xAxis?.min!==void 0&&props.config?.xAxis?.max!==void 0){let range$1=props.config.xAxis.max-props.config.xAxis.min;return{min:props.config.xAxis.min,max:props.config.xAxis.max,range:range$1===0?1:range$1}}if(!props.points.length)return{min:0,max:1,range:1};let xValues=[...props.points.flatMap(dataset=>(dataset.points||[]).map(point=>point&&point[0])),...(props.verticalGuides||[]).map(guide=>guide?.x),...(props.ranges||[]).map(range$1=>range$1?.start),...(props.ranges||[]).map(range$1=>range$1?.end)].filter(val=>val!=null&&isFinite(val));if(xValues.length===0)return{min:0,max:1,range:1};let min$1=Math.min(...xValues),max$1=Math.max(...xValues);if(!isFinite(min$1)||!isFinite(max$1))return{min:0,max:1,range:1};let range=max$1-min$1;return{min:min$1,max:max$1,range:range===0?1:range}}),getXPosition=value=>{if(value==null||!isFinite(value))return 0;let result=(value-xScale.value.min)/xScale.value.range*100;return isFinite(result)?result:0},datasetPaths=computed(()=>!props.points.length||!xScale.value?[]:props.points.map(dataset=>{if(!dataset.points||!Array.isArray(dataset.points)||dataset.points.length===0)return{datasetId:dataset.label||`unknown`,linePath:``,areaPath:``};let linePoints=dataset.points.map((point,index)=>{if(!point||point.length<2)return``;let x=getXPosition(point[0]),y=getYPosition(point[1]);return`${index===0?`M`:`L`} ${x} ${y}`}).filter(p$1=>p$1).join(` `),areaPoints=dataset.points.map(point=>!point||point.length<2?``:`L ${getXPosition(point[0])} ${getYPosition(point[1])}`).filter(p$1=>p$1).join(` `),areaPath=``;if(dataset.fill&&dataset.points.length>0){let firstPoint=dataset.points[0],lastPoint=dataset.points[dataset.points.length-1];firstPoint&&lastPoint&&firstPoint.length>=2&&lastPoint.length>=2&&(areaPath=`M -5 105 L -5 ${getYPosition(firstPoint[1])} ${areaPoints} L 105 ${getYPosition(lastPoint[1])} L 105 105 Z`)}return{datasetId:dataset.label||`unknown`,linePath:linePoints,areaPath}})),getLinePathForDataset=dataset=>{let path=datasetPaths.value.find(p$1=>p$1.datasetId===dataset.label);return path?path.linePath:``},getAreaPathForDataset=dataset=>{let path=datasetPaths.value.find(p$1=>p$1.datasetId===dataset.label);return path?path.areaPath:``},getYPosition=value=>{if(value==null||!isFinite(value))return 50;let yMin=yBounds.value.min,yMax=yBounds.value.max;if(yMin==null||yMax==null||!isFinite(yMin)||!isFinite(yMax)||yMin===yMax)return 50;if(yMin>=0||yMax<=0){let yRange$1=yMax-yMin;if(yRange$1===0)return 50;let result$1=97.5-(value-yMin)/yRange$1*95;return isFinite(result$1)?result$1:50}let yRange=Math.max(Math.abs(yMin),Math.abs(yMax));if(yRange===0)return 50;let totalRange=Math.abs(yMin)+Math.abs(yMax);if(totalRange===0)return 50;let zeroLinePosition=Math.abs(yMin)/totalRange*95+2.5,result;return result=value>=0?zeroLinePosition-value/yRange*(zeroLinePosition-2.5):zeroLinePosition+Math.abs(value)/yRange*(97.5-zeroLinePosition),isFinite(result)?result:50},formatNumber=num=>num==null||!isFinite(num)?`0`:Math.floor(num).toString(),yBounds=computed(()=>{if(props.config?.yAxis?.min!==void 0&&props.config?.yAxis?.max!==void 0)return{min:props.config.yAxis.min,max:props.config.yAxis.max};if(!props.points.length)return{min:0,max:0};let allYValues=props.points.flatMap(dataset=>(dataset.points||[]).map(point=>point&&point[1])).filter(val=>val!=null&&isFinite(val));if(allYValues.length===0)return{min:0,max:1};let min$1=Math.min(...allYValues),max$1=Math.max(...allYValues);return!isFinite(min$1)||!isFinite(max$1)?{min:0,max:1}:{min:min$1,max:max$1}}),xMinFormatted=computed(()=>formatNumber(xScale.value?.min||0)),xMaxFormatted=computed(()=>formatNumber(xScale.value?.max||0)),yMinFormatted=computed(()=>formatNumber(yBounds.value.min)),yMaxFormatted=computed(()=>formatNumber(yBounds.value.max)),hasNegativeValues=computed(()=>yBounds.value.min<0),getLabelPosition=()=>{if(!props.singleLabel)return{x:0,y:0,anchor:`start`};let labelX=props.singleLabel.x===void 0?95:getXPosition(props.singleLabel.x),labelY=props.singleLabel.y===void 0?50:getYPosition(props.singleLabel.y),adjustedY=labelY>=25?labelY+4:labelY-2,anchor=labelX>=80?`end`:`start`;return{x:anchor===`end`?Math.min(labelX,98):Math.max(labelX,2),y:adjustedY,anchor}},getLabelStyle=()=>{if(!props.singleLabel)return{};let basePos=getLabelPosition(),estimatedWidth=props.singleLabel.text.length*6.5+6,estimatedHeight=18,containerWidth=300,containerHeight=80,pixelX=basePos.x/100*300,pixelY=basePos.y/100*80,finalX=basePos.x,finalY=basePos.y,anchor=basePos.anchor,verticalAlign=`middle`;anchor===`start`?pixelX+estimatedWidth>290&&(anchor=`end`):pixelX-estimatedWidth<10&&(anchor=`start`);let minGapFromPoint=4,topBuffer=8,bottomBuffer=8,wouldOverflowTop=pixelY-18/2<8;if(pixelY+18/2>72)verticalAlign=`bottom`,finalY=Math.max(basePos.y-4,15);else if(wouldOverflowTop)verticalAlign=`top`,finalY=Math.min(basePos.y+4,85);else{let pointY=basePos.y;pointY>75?(verticalAlign=`bottom`,finalY=pointY-4):pointY<25?(verticalAlign=`top`,finalY=pointY+4):(verticalAlign=`bottom`,finalY=pointY-4)}let transformX=`translateX(0)`,transformY=`translateY(-50%)`;return anchor===`end`&&(transformX=`translateX(-100%)`),verticalAlign===`bottom`?transformY=`translateY(-100%)`:verticalAlign===`top`&&(transformY=`translateY(0)`),{position:`absolute`,left:`${finalX}%`,top:`${finalY}%`,transform:`${transformX} ${transformY}`,color:props.singleLabel.color||`var(--bng-orange)`,fontSize:`11px`,fontFamily:`sans-serif`,pointerEvents:`none`,whiteSpace:`nowrap`}};return(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$302,[__props.config.showLabels?(openBlock(),createElementBlock(`div`,_hoisted_2$249,[createBaseVNode(`div`,_hoisted_3$219,[createBaseVNode(`div`,_hoisted_4$187,toDisplayString(yMaxFormatted.value),1),createBaseVNode(`div`,_hoisted_5$160,[createTextVNode(toDisplayString(__props.config.yAxis.label)+` `,1),__props.config.yAxis.unit?(openBlock(),createElementBlock(`span`,_hoisted_6$138,`(`+toDisplayString(__props.config.yAxis.unit)+`)`,1)):createCommentVNode(``,!0)]),createBaseVNode(`div`,_hoisted_7$120,toDisplayString(yMinFormatted.value),1)])])):createCommentVNode(``,!0),(openBlock(),createElementBlock(`svg`,_hoisted_8$100,[createBaseVNode(`defs`,null,[createBaseVNode(`pattern`,{id:`grid`,width:gridSizes.value.x,height:gridSizes.value.y,patternUnits:`userSpaceOnUse`},[createBaseVNode(`path`,{d:`M ${gridSizes.value.x} 0 L ${gridSizes.value.x} ${gridSizes.value.y}`,stroke:__props.gridColor,"stroke-width":`1`,"vector-effect":`non-scaling-stroke`,opacity:`0.3`},null,8,_hoisted_10$78),createBaseVNode(`path`,{d:`M 0 ${gridSizes.value.y} L 100 ${gridSizes.value.y}`,stroke:__props.gridColor,"stroke-width":`1`,"vector-effect":`non-scaling-stroke`,opacity:`0.3`},null,8,_hoisted_11$70)],8,_hoisted_9$90),createBaseVNode(`pattern`,{id:`subgrid`,width:gridSizes.value.x,height:gridSizes.value.y,patternUnits:`userSpaceOnUse`},[createBaseVNode(`path`,{d:`M ${gridSizes.value.x/__props.subgridDivider} 0 L ${gridSizes.value.x/__props.subgridDivider} ${gridSizes.value.y}`,stroke:__props.gridColor,"stroke-width":`0.5`,"vector-effect":`non-scaling-stroke`,opacity:`0.15`},null,8,_hoisted_13$50),createBaseVNode(`path`,{d:`M 0 ${gridSizes.value.y/__props.subgridDivider} L 100 ${gridSizes.value.y/__props.subgridDivider}`,stroke:__props.gridColor,"stroke-width":`0.5`,"vector-effect":`non-scaling-stroke`,opacity:`0.15`},null,8,_hoisted_14$45)],8,_hoisted_12$58)]),__props.showSubgrid?(openBlock(),createElementBlock(`rect`,_hoisted_15$43)):createCommentVNode(``,!0),_cache[0]||=createBaseVNode(`rect`,{width:`100`,height:`100`,fill:`url(#grid)`},null,-1),createBaseVNode(`g`,_hoisted_16$40,[hasNegativeValues.value?(openBlock(),createElementBlock(`line`,{key:0,x1:`0`,y1:getYPosition(0),x2:`100`,y2:getYPosition(0),stroke:__props.gridColor,"stroke-width":`2`,"vector-effect":`non-scaling-stroke`,opacity:`0.75`},null,8,_hoisted_17$33)):createCommentVNode(``,!0)]),createBaseVNode(`g`,_hoisted_18$30,[(openBlock(!0),createElementBlock(Fragment,null,renderList(__props.ranges,range=>(openBlock(),createElementBlock(`rect`,{key:`range-${range.start}`,x:getXPosition(range.start),y:`-5`,width:getXPosition(range.end)-getXPosition(range.start),height:`110`,fill:range.fill,stroke:range.outline,"stroke-width":`2`,"vector-effect":`non-scaling-stroke`,opacity:range.opacity},null,8,_hoisted_19$25))),128))]),createBaseVNode(`g`,_hoisted_20$21,[(openBlock(!0),createElementBlock(Fragment,null,renderList(__props.verticalGuides,guide=>(openBlock(),createElementBlock(`line`,{key:`guide-${guide.x}`,x1:getXPosition(guide.x),y1:`0`,x2:getXPosition(guide.x),y2:`100`,stroke:guide.color,"stroke-width":`1`,"vector-effect":`non-scaling-stroke`,opacity:guide.opacity},null,8,_hoisted_21$19))),128))]),__props.currentX?(openBlock(),createElementBlock(`line`,{key:1,x1:getXPosition(__props.currentX),y1:`0`,x2:getXPosition(__props.currentX),y2:`100`,stroke:`white`,"stroke-width":`1`,"vector-effect":`non-scaling-stroke`,opacity:`0.8`},null,8,_hoisted_22$17)):createCommentVNode(``,!0),(openBlock(!0),createElementBlock(Fragment,null,renderList(__props.points,dataset=>(openBlock(),createElementBlock(`g`,{key:dataset.label},[dataset.fill?(openBlock(),createElementBlock(`path`,{key:0,d:getAreaPathForDataset(dataset),fill:dataset.color||`white`,opacity:dataset.fillOpacity??.5},null,8,_hoisted_23$16)):createCommentVNode(``,!0),createBaseVNode(`path`,{d:getLinePathForDataset(dataset),stroke:dataset.color||`white`,fill:`none`,"stroke-width":`1`,"vector-effect":`non-scaling-stroke`},null,8,_hoisted_24$15)]))),128))])),__props.singleLabel?(openBlock(),createElementBlock(`div`,{key:1,class:`single-label`,style:normalizeStyle(getLabelStyle())},toDisplayString(__props.singleLabel.text),5)):createCommentVNode(``,!0),__props.config.showLabels?(openBlock(),createElementBlock(`div`,_hoisted_25$14,[createBaseVNode(`div`,_hoisted_26$12,[createBaseVNode(`div`,_hoisted_27$12,toDisplayString(xMinFormatted.value),1),createBaseVNode(`div`,_hoisted_28$11,[createTextVNode(toDisplayString(__props.config.xAxis.label)+` `,1),__props.config.xAxis.unit?(openBlock(),createElementBlock(`span`,_hoisted_29$11,`(`+toDisplayString(__props.config.xAxis.unit)+`)`,1)):createCommentVNode(``,!0)]),createBaseVNode(`div`,_hoisted_30$10,toDisplayString(xMaxFormatted.value),1)])])):createCommentVNode(``,!0)]))}},bngSimpleGraph_default=__plugin_vue_export_helper_default(_sfc_main$344,[[`__scopeId`,`data-v-66d95af3`]]),_hoisted_1$301={class:`bng-slider-container`},_hoisted_2$248=[`disabled`,`min`,`max`,`step`],_sfc_main$343={__name:`bngSlider`,props:{modelValue:Number,origValue:{type:[Number,String],default:NaN},min:{type:[Number,String],default:0},max:{type:[Number,String],required:!0},step:{type:[Number,String],default:0},withReset:{type:Boolean,default:!1},withInput:{type:Boolean,default:!1},inputMultiplier:{type:Number,default:1},unit:{type:String,default:``},disabled:Boolean,uiNavFocus:{type:[Boolean,Object],default:{},validator:val=>typeof val==`boolean`&&!val||typeof val==`object`}},emits:[`change`,`valueChanged`,`update:modelValue`],setup(__props,{expose:__expose,emit:__emit}){let props=__props,emit$1=__emit,slider=ref(null),value=ref(props.modelValue);ref(!1);let uiNavFocusFunction=computed(()=>props.uiNavFocus?{callback:(dir,val)=>{value.value=val,notify()},value:()=>value.value,min:+props.min,max:+props.max,step:()=>+props.step,...props.uiNavFocus}:!1);watch(()=>props.modelValue,val=>{value.value=Number(val),updateSliderBackground()});let dirty=useDirty(value,null,updateSliderBackground),dirtyReset=useDirty(value,null,updateSliderBackground);__expose(dirty);let resetDisabled=computed(()=>props.disabled?!0:isNaN(dirtyReset.currentCleanValue.value)?!dirty.dirty.value:!dirtyReset.dirty.value);onMounted(()=>{updateSliderBackground(),inputProps.value=value.value*props.inputMultiplier});function notify(){emit$1(`update:modelValue`,value.value),emit$1(`valueChanged`,value.value),emit$1(`change`,value.value),updateSliderBackground()}function updateSliderBackground(){if(!slider.value)return;let current=(value.value-props.min)/(props.max-props.min)*100,init$3=[-100,-100],dirtyVal=dirtyReset.currentCleanValue.value;if((typeof dirtyVal!=`number`||isNaN(dirtyVal))&&(dirtyVal=dirty.currentCleanValue.value),typeof dirtyVal==`number`&&!isNaN(dirtyVal)){let initpos=(dirtyVal-props.min)/(props.max-props.min)*100;init$3[currentvalue.value,val=>{inputProps.value=val*props.inputMultiplier}),watch(()=>props.origValue,val=>{val=+val,isNaN(val)||dirtyReset.setCleanValue(val)},{immediate:!0}),watch(()=>inputProps.value,val=>{value.value=val/props.inputMultiplier});function onInputChange(num){num=Number(num);let norm=roundDecSample(num,inputProps.step);num!==norm&&(inputProps.value=norm),num=norm/props.inputMultiplier,num=roundDecSample(num,props.step),numprops.max&&(num=props.max),value.value=num,notify()}function resetValue(){let val=+props.origValue;isNaN(val)?dirty.resetValue():value.value=val,notify()}return(_ctx,_cache)=>withDirectives((openBlock(),createElementBlock(`div`,_hoisted_1$301,[withDirectives(createBaseVNode(`input`,{ref_key:`slider`,ref:slider,class:`bng-slider`,type:`range`,disabled:__props.disabled,"onUpdate:modelValue":_cache[0]||=$event=>value.value=$event,min:+__props.min,max:+__props.max,step:+__props.step,onInput:notify},null,40,_hoisted_2$248),[[vModelText,value.value,void 0,{number:!0}],[unref(BngOnUiNavFocus_default),uiNavFocusFunction.value,void 0,{repeat:!0}]]),__props.withInput?(openBlock(),createBlock(unref(bngInput_default),{key:0,class:`bng-slider-input`,disabled:__props.disabled,modelValue:inputProps.value,"onUpdate:modelValue":_cache[1]||=$event=>inputProps.value=$event,type:`number`,min:inputProps.min,max:inputProps.max,step:inputProps.step,suffix:__props.unit,onValueChanged:onInputChange},null,8,[`disabled`,`modelValue`,`min`,`max`,`step`,`suffix`])):createCommentVNode(``,!0),__props.withReset?(openBlock(),createBlock(unref(bngButton_default),{key:1,class:`bng-slider-reset`,accent:unref(ACCENTS).text,icon:unref(icons).undo,disabled:resetDisabled.value,onClick:resetValue},null,8,[`accent`,`icon`,`disabled`])):createCommentVNode(``,!0)])),[[unref(BngScopedNav_default),{bubbleWhitelistEvents:[`menu`]}],[unref(BngDisabled_default),__props.disabled]])}},bngSlider_default=__plugin_vue_export_helper_default(_sfc_main$343,[[`__scopeId`,`data-v-7d0150a1`]]),_sfc_main$342={__name:`bngSmartSelect`,props:mergeModels({items:{type:Array,required:!0},threshold:{type:Number,default:6},type:{type:String,default:``,validator(val){return[``,`select`,`dropdown`].includes(val)}},highlight:[String,Array,RegExp],disabled:Boolean},{modelValue:{},modelModifiers:{}}),emits:mergeModels([`change`],[`update:modelValue`]),setup(__props,{emit:__emit}){let props=__props,value=useModel(__props,`modelValue`),emit$1=__emit,elDropdown=ref(),elSelect=ref(),types={none:bngSelect_default,select:bngSelect_default,dropdown:bngDropdown_default},items$2=computed(()=>Array.isArray(props.items)?props.items:[]),type=computed(()=>props.type&&props.type in types?props.type:items$2.value.length===0?`none`:items$2.value.length<=props.threshold?`select`:`dropdown`),binds=computed(()=>{let res={disabled:props.disabled};switch(type.value){default:res.options=[`n/a`],res.disabled=!0;break;case`select`:res.loop=!0,res.labelClickable=!0,res.config={label:itm=>itm?.label||`n/a`,value:itm=>itm?.value},res.options=items$2.value.filter(itm=>!itm.disabled&&!itm.group),res.items=items$2.value,res.highlight=props.highlight,res.disabled||=res.options.length===0,res.popoverTarget=elSelect.value?.getElement?.(),res.focusTarget=elSelect.value?.getContentElement?.()||res.popoverTarget;break;case`dropdown`:res.items=items$2.value,res.highlight=props.highlight,res.showSearch=!0;break}return res});function openDropdown(){}function onSelectChanged(newValue){value.value!==newValue&&emit$1(`change`,newValue)}function onDropdownChanged(newValue){value.value!==newValue&&emit$1(`change`,newValue)}return(_ctx,_cache)=>(openBlock(),createElementBlock(Fragment,null,[type.value===`dropdown`?createCommentVNode(``,!0):(openBlock(),createBlock(unref(bngSelect_default),{key:0,ref_key:`elSelect`,ref:elSelect,class:`bng-smart-select`,modelValue:value.value,"onUpdate:modelValue":_cache[0]||=$event=>value.value=$event,options:binds.value.options,config:binds.value.config,disabled:binds.value.disabled,loop:``,"label-clickable":``,"label-popover":elDropdown.value?.popoverName,onLabelClick:openDropdown,onChange:onSelectChanged},null,8,[`modelValue`,`options`,`config`,`disabled`,`label-popover`])),binds.value.items?(openBlock(),createBlock(unref(bngDropdown_default),{key:1,ref_key:`elDropdown`,ref:elDropdown,class:normalizeClass(`bng-smart-${type.value}`),modelValue:value.value,"onUpdate:modelValue":_cache[1]||=$event=>value.value=$event,items:binds.value.items,highlight:binds.value.highlight,disabled:binds.value.disabled,headless:type.value===`select`,"show-search":binds.value.showSearch,"focus-target":binds.value.focusTarget,"popover-target":binds.value.popoverTarget,onValueChanged:onDropdownChanged},null,8,[`class`,`modelValue`,`items`,`highlight`,`disabled`,`headless`,`show-search`,`focus-target`,`popover-target`])):createCommentVNode(``,!0)],64))}},bngSmartSelect_default=__plugin_vue_export_helper_default(_sfc_main$342,[[`__scopeId`,`data-v-a288ad68`]]),_hoisted_1$300=[`xlink:href`],_sfc_main$341={__name:`bngSpriteIcon`,props:{atlasPath:{type:String,default:`sprites/svg-symbols.svg`},src:{type:String,required:!0},color:{type:String,default:`#fff`},deg:{type:Number,default:0}},setup(__props){let props=__props,atlasURL=computed(()=>`${getAssetURL$1(props.atlasPath)}#${props.src.toLowerCase()}`),getAssetURL$1=assetPath=>bngApi.isMock?`http://localhost:9000/${assetPath}`:`/ui/ui-vue/src/assets/${assetPath}`;return(_ctx,_cache)=>(openBlock(),createElementBlock(`svg`,{class:`atlasIcon`,style:normalizeStyle({fill:__props.color,pointerEvents:`none`,transform:`rotate(${__props.deg}deg)`}),version:`1.1`,xmlns:`http://www.w3.org/2000/svg`},[createBaseVNode(`use`,{"xlink:href":atlasURL.value},null,8,_hoisted_1$300)],4))}},bngSpriteIcon_default=__plugin_vue_export_helper_default(_sfc_main$341,[[`__scopeId`,`data-v-0ace1ddc`]]),_hoisted_1$299=[`tabindex`],_hoisted_2$247={key:0};const LABEL_ALIGNMENTS={START:`start`,END:`end`,CENTER:`center`};var _sfc_main$340={__name:`bngSwitch`,props:{modelValue:[Boolean,Number,String],checked:{type:Boolean,default:!1},label:String,labelBefore:Boolean,labelAlignment:{type:String,default:LABEL_ALIGNMENTS.END,validator:value=>Object.values(LABEL_ALIGNMENTS).includes(value)},inline:{type:Boolean,default:!0},alwaysTransparent:Boolean,disabled:Boolean,valueOn:{type:[Boolean,Number,String],default:void 0},valueOff:{type:[Boolean,Number,String],default:void 0}},emits:[`update:modelValue`,`change`,`valueChanged`],setup(__props,{emit:__emit}){let props=__props,emit$1=__emit,slots=useSlots(),bngSwitch=ref(null),valOn=computed(()=>props.valueOn===void 0?!0:props.valueOn),valOff=computed(()=>props.valueOff===void 0?!1:props.valueOff),isSwitchOn=computed(()=>props.modelValue==null?props.checked:props.modelValue===valOn.value);function onClicked(){if(props.disabled)return;let newValue=isSwitchOn.value?valOff.value:valOn.value;props.modelValue!=null&&emit$1(`update:modelValue`,newValue),emit$1(`valueChanged`,newValue),emit$1(`change`,newValue)}return onUpdated(()=>ensureFocus(bngSwitch.value)),(_ctx,_cache)=>withDirectives((openBlock(),createElementBlock(`div`,{ref_key:`bngSwitch`,ref:bngSwitch,"bng-nav-item":``,class:normalizeClass([`bng-switch`,{"bng-switch-on":isSwitchOn.value,"with-background":!__props.alwaysTransparent,"with-label":__props.label||unref(slots).default,"label-position-before":__props.labelBefore,"inline-switch":!__props.label&&!unref(slots).default||__props.inline}]),tabindex:__props.disabled?-1:0,onClick:onClicked},[_cache[0]||=createBaseVNode(`div`,{class:`bng-switch-control`},null,-1),unref(slots).default||__props.label?(openBlock(),createElementBlock(`div`,{key:0,class:normalizeClass([`bng-switch-label`,[`label-alignment-`+__props.labelAlignment]])},[renderSlot(_ctx.$slots,`default`,{},()=>[__props.label?(openBlock(),createElementBlock(`span`,_hoisted_2$247,toDisplayString(__props.label),1)):createCommentVNode(``,!0)],!0)],2)):createCommentVNode(``,!0)],10,_hoisted_1$299)),[[unref(BngOnUiNav_default),void 0,`ok`,{asMouse:!0,focusRequired:!0}],[unref(BngDisabled_default),__props.disabled]])}},bngSwitch_default=__plugin_vue_export_helper_default(_sfc_main$340,[[`__scopeId`,`data-v-8e1c4b05`]]),_hoisted_1$298={class:`bng-switch-label`},_hoisted_2$246={key:0},_sfc_main$339={__name:`bngSwitchOld`,props:{modelValue:Boolean,label:String,checked:Boolean,uncheckedWithBackground:Boolean,disabled:Boolean},emits:[`valueChanged`,`update:modelValue`],setup(__props,{emit:__emit}){let toggleValue=ref(!1),props=__props,emit$1=__emit,slots=useSlots();onBeforeMount(init$3),watch(()=>props.modelValue,init$3),watch(()=>props.checked,init$3),watch(()=>props.disabled,init$3);function init$3(){toggleValue.value=props.checked||props.modelValue}function onValueChanged(){props.disabled||(toggleValue.value=!toggleValue.value,emit$1(`update:modelValue`,toggleValue.value),emit$1(`valueChanged`,toggleValue.value))}return(_ctx,_cache)=>unref(slots).default||__props.label?withDirectives((openBlock(),createElementBlock(`div`,mergeProps({key:0,class:[`bng-labeled-switch`,{"switch-on":toggleValue.value,"with-background":__props.uncheckedWithBackground}]},{...!__props.disabled&&{"bng-nav-item":1}},{tabindex:`{{disabled ? 0 : 1}}`,onClick:onValueChanged,onKeyup:withKeys(onValueChanged,[`space`])}),[_cache[0]||=createBaseVNode(`div`,{class:`bng-switch-wrapper`},[createBaseVNode(`div`,{class:`bng-switch`})],-1),createBaseVNode(`div`,_hoisted_1$298,[renderSlot(_ctx.$slots,`default`,{},()=>[__props.label?(openBlock(),createElementBlock(`label`,_hoisted_2$246,toDisplayString(__props.label),1)):createCommentVNode(``,!0)],!0)])],16)),[[unref(BngDisabled_default),__props.disabled]]):withDirectives((openBlock(),createElementBlock(`div`,mergeProps({key:1},{...!__props.disabled&&{"bng-nav-item":1}},{tabindex:`{{disabled ? 0 : 1}}`,class:[`bng-switch-wrapper`,{"switch-on":toggleValue.value}],onClick:onValueChanged,onKeyup:withKeys(onValueChanged,[`space`])}),[..._cache[1]||=[createBaseVNode(`div`,{class:`bng-switch`},null,-1)]],16)),[[unref(BngDisabled_default),__props.disabled]])}},bngSwitchOld_default=__plugin_vue_export_helper_default(_sfc_main$339,[[`__scopeId`,`data-v-da8dc7b1`]]),_hoisted_1$297={"bng-nav-item":``,class:`bng-tile tile`},_hoisted_2$245={class:`content`},_hoisted_3$218={class:`label`},_sfc_main$338={__name:`bngTile`,props:{label:String,ratio:{type:String,default:`4:3`},backgroundImage:String,backgroundExternalImage:String,disabled:Boolean},setup(__props){return(_ctx,_cache)=>withDirectives((openBlock(),createElementBlock(`div`,_hoisted_1$297,[createVNode(unref(aspectRatio_default),{class:`content-container image`,ratio:__props.ratio,image:__props.backgroundImage,externalImage:__props.backgroundExternalImage,imageMode:`contain`},{default:withCtx(()=>[createBaseVNode(`div`,_hoisted_2$245,[renderSlot(_ctx.$slots,`default`,{},void 0,!0)])]),_:3},8,[`ratio`,`image`,`externalImage`]),renderSlot(_ctx.$slots,`label`,{},()=>[createBaseVNode(`div`,_hoisted_3$218,toDisplayString(__props.label),1)],!0)])),[[unref(BngDisabled_default),__props.disabled]])}},bngTile_default=__plugin_vue_export_helper_default(_sfc_main$338,[[`__scopeId`,`data-v-af5747cc`]]),_sfc_main$337={__name:`bngTooltip`,props:{text:{type:String,required:!0},position:{type:String,default:`top`}},setup(__props){return(_ctx,_cache)=>withDirectives((openBlock(),createElementBlock(`div`,null,[renderSlot(_ctx.$slots,`default`,{},void 0,!0)])),[[unref(BngTooltip_default),__props.text,__props.position]])}},bngTooltip_default=__plugin_vue_export_helper_default(_sfc_main$337,[[`__scopeId`,`data-v-53073c36`]]),toInt=v=>~~+v,_sfc_main$336={__name:`bngUnit`,props:{options:Object,formatter:[Function,String]},setup(__props){let{units}=useBridge(),knownUnits={money:{formatter:v=>units.beamBucks(v)},beamXP:{formatter:toInt},stars:{formatter:toInt},vouchers:{formatter:toInt},insuranceScore:{formatter:toInt},multiplier:{formatter:toInt,noGap:!0}},defaultColors={stars:`var(--bng-ter-yellow-200)`,vouchers:`var(--bng-add-blue-400)`},attrs=useAttrs(),unit=computed(()=>{for(let key of Object.keys(attrs))if(key in knownUnits)return{type:key,value:attrs[key],...knownUnits[key],...props.options};return{type:`unknown`}}),formattedValue=computed(()=>{if(props.formatter){if(typeof props.formatter==`function`)return props.formatter(unit.value.value);if(typeof props.formatter==`string`&&props.formatter in knownUnits)return knownUnits[props.formatter].formatter(unit.value.value)}return typeof unit.value.formatter==`function`?unit.value.formatter(unit.value.value):unit.value.value}),props=__props;return(_ctx,_cache)=>(openBlock(),createBlock(unref(slotSwitcher_default),mergeProps(unref(attrs),{slotId:unit.value.type}),{money:withCtx(props$1=>[createVNode(unref(bngPropVal_default),mergeProps({...props$1,...unit.value},{iconType:props$1.iconType||unref(icons).beamCurrency,valueLabel:formattedValue.value}),null,16,[`iconType`,`valueLabel`])]),beamXP:withCtx(props$1=>[createVNode(unref(bngPropVal_default),mergeProps({...props$1,...unit.value},{iconType:props$1.iconType||unref(icons).beamXPLo,valueLabel:formattedValue.value}),null,16,[`iconType`,`valueLabel`])]),stars:withCtx(props$1=>[createVNode(unref(bngPropVal_default),mergeProps({...props$1,...unit.value},{iconType:props$1.iconType||unref(icons).star,valueLabel:formattedValue.value,"icon-color":defaultColors.stars}),null,16,[`iconType`,`valueLabel`,`icon-color`])]),vouchers:withCtx(props$1=>[createVNode(unref(bngPropVal_default),mergeProps({...props$1,...unit.value},{iconType:props$1.iconType||unref(icons).voucherHorizontal3,valueLabel:formattedValue.value,"icon-color":defaultColors.vouchers}),null,16,[`iconType`,`valueLabel`,`icon-color`])]),insuranceScore:withCtx(props$1=>[createVNode(unref(bngPropVal_default),mergeProps({...props$1,...unit.value},{iconType:props$1.iconType||unref(icons).shieldCheckmarkProgressbar,valueLabel:formattedValue.value}),null,16,[`iconType`,`valueLabel`])]),multiplier:withCtx(props$1=>[createVNode(unref(bngPropVal_default),mergeProps({...props$1,...unit.value},{iconType:props$1.iconType||unref(icons).mathMultiply,valueLabel:formattedValue.value,"icon-color":defaultColors.multiplier}),null,16,[`iconType`,`valueLabel`,`icon-color`])]),unknown:withCtx(props$1=>[createBaseVNode(`span`,normalizeProps(guardReactiveProps(props$1)),`BngUnit: Unknown unit type or no type specified`,16)]),_:1},16,[`slotId`]))}},bngUnit_default=_sfc_main$336;const DEMOS={};var base_exports=__export({ACCENTS:()=>ACCENTS,BngActionDrawer:()=>bngActionDrawer_default,BngActionsDrawer:()=>bngActionsDrawer_default,BngActionsDrawerOne:()=>bngActionsDrawerOne_default,BngActionsList:()=>bngActionsList_default,BngBinding:()=>bngBinding_default,BngBreadcrumbs:()=>bngBreadcrumbs_default,BngButton:()=>bngButton_default,BngCard:()=>bngCard_default,BngCardHeading:()=>bngCardHeading_default,BngColorPicker:()=>bngColorPicker_default,BngColorSlider:()=>bngColorSlider_default,BngColorTile:()=>bngColorTile_default,BngCondition:()=>bngCondition_default,BngControllerHint:()=>bngControllerHint_default,BngDivider:()=>bngDivider_default,BngDrawer:()=>bngDrawer_default,BngDrawerOld:()=>bngDrawerOld_default,BngDropdown:()=>bngDropdown_default,BngDropdownContainer:()=>bngDropdownContainer_default,BngIcon:()=>bngIcon_default,BngIconMarker:()=>bngIconMarker_default,BngImage:()=>bngImage_default,BngImageAsset:()=>bngImageAsset_default,BngImageCarousel:()=>bngImageCarousel_default,BngImageTile:()=>bngImageTile_default,BngInput:()=>bngInput_default,BngInputNew:()=>bngInputNew_default,BngList:()=>bngList_default,BngMainStars:()=>bngMainStars_default,BngMultilineInput:()=>bngMultilineInput_default,BngOldIcon:()=>bngOldIcon_default,BngOverflowContainer:()=>bngOverflowContainer_default,BngPaintTile:()=>bngPaintTile_default,BngPill:()=>bngPill_default,BngPillCheckbox:()=>bngPillCheckbox_default,BngPillFilters:()=>bngPillFilters_default,BngPillFiltersContainer:()=>bngPillFiltersContainer_default,BngPopoverContent:()=>bngPopoverContent_default,BngPopoverMenu:()=>bngPopoverMenu_default,BngProgressBar:()=>bngProgressBar_default,BngPropVal:()=>bngPropVal_default,BngScreenHeading:()=>bngScreenHeading_default,BngScreenHeadingV2:()=>bngScreenHeadingV2_default,BngSelect:()=>bngSelect_default,BngSimpleGraph:()=>bngSimpleGraph_default,BngSlider:()=>bngSlider_default,BngSmartSelect:()=>bngSmartSelect_default,BngSpriteIcon:()=>bngSpriteIcon_default,BngSwitch:()=>bngSwitch_default,BngSwitchOld:()=>bngSwitchOld_default,BngTile:()=>bngTile_default,BngTooltip:()=>bngTooltip_default,BngUnit:()=>bngUnit_default,DEMOS:()=>DEMOS,LABEL_ALIGNMENTS:()=>LABEL_ALIGNMENTS,LIST_LAYOUTS:()=>LIST_LAYOUTS,STEP_ICON_TYPES:()=>STEP_ICON_TYPES,getIconsWithTags:()=>getIconsWithTags,icons:()=>icons,iconsBySize:()=>iconsBySize,iconsByTag:()=>iconsByTag});function getPopupWrapperDefaults(){return{fade:!1,blur:!0,style:[popupContainer.default]}}function getActivityWrapperDefaults(){return{fade:!1,blur:!1,style:[popupContainer.clickthrough]}}const popupContainer=Object.freeze({default:`default`,transparent:`transparent`,clickthrough:`clickthrough`}),popupPosition=Object.freeze({default:`center`,top:`top`,left:`left`,right:`right`,bottom:`bottom`,center:`center`,fullscreen:`fullscreen`});var _hoisted_1$296=[`bng-ui-scope`],_hoisted_2$244={class:`popup-content`},_hoisted_3$217={key:0,class:`popup-title`},_hoisted_4$186={key:1,class:`popup-body`},_hoisted_5$159=[`innerHTML`],_hoisted_6$137={class:`popup-buttons`},__default__$10={wrapper:{blur:!0,style:null},position:popupPosition.center,animated:!0},_sfc_main$335=Object.assign(__default__$10,{__name:`Confirmation`,props:{appearance:String,popupActive:Boolean,message:{type:[String,Object],required:!0},title:String,buttons:Array},emits:[`return`],setup(__props,{emit:__emit}){useUINavBlocker().allowNavigationOnly();let props=__props,emit$1=__emit,scopeName=usePopupUINavScopeName(`_confirmPopup`,props),defaultButtonIndex=props.buttons.findIndex(button=>button.extras&&button.extras.default);defaultButtonIndex===-1&&(defaultButtonIndex=0);let cancelButton=props.buttons.find(button=>button.extras&&button.extras.cancel),exclude=[`default`,`cancel`],buttonProps=computed(()=>{let bp=[];for(let{extras}of props.buttons)extras?bp.push(Object.keys(extras).reduce((ex,key)=>exclude.includes(key)?ex:{...ex,[key]:extras[key]},{})):bp.push({});return bp}),messageIsComponent=computed(()=>props.message&&typeof props.message==`object`&&props.message.component),handleCancelWithBack=()=>emit$1(`return`,cancelButton?cancelButton.value:null);return(_ctx,_cache)=>withDirectives((openBlock(),createElementBlock(`div`,{class:normalizeClass([`popup`,`popup-style-`+__props.appearance]),"bng-ui-scope":unref(scopeName)},[createBaseVNode(`div`,_hoisted_2$244,[__props.title?(openBlock(),createElementBlock(`div`,_hoisted_3$217,toDisplayString(__props.title),1)):createCommentVNode(``,!0),messageIsComponent.value?(openBlock(),createElementBlock(`div`,_hoisted_4$186,[(openBlock(),createBlock(resolveDynamicComponent(__props.message.component),normalizeProps(guardReactiveProps(__props.message.props)),null,16))])):(openBlock(),createElementBlock(`div`,{key:2,class:`popup-body`,innerHTML:__props.message},null,8,_hoisted_5$159)),createBaseVNode(`div`,_hoisted_6$137,[(openBlock(!0),createElementBlock(Fragment,null,renderList(__props.buttons,(button,index)=>withDirectives((openBlock(),createBlock(unref(bngButton_default),mergeProps({key:index},{ref_for:!0},buttonProps.value[index],{onClick:$event=>_ctx.$emit(`return`,button.value)}),{default:withCtx(()=>[createTextVNode(toDisplayString(button.label),1)]),_:2},1040,[`onClick`])),[[unref(BngUiNavFocus_default),index===unref(defaultButtonIndex)?1e3:void 0]])),128))])])],10,_hoisted_1$296)),[[unref(BngOnUiNav_default),handleCancelWithBack,`back,menu`]])}}),Confirmation_default=__plugin_vue_export_helper_default(_sfc_main$335,[[`__scopeId`,`data-v-ce4a758b`]]),_hoisted_1$295=[`bng-ui-scope`],_hoisted_2$243={key:0,class:`form-dialog-toolbar`},_hoisted_3$216={class:`toolbar-title`},_hoisted_4$185={key:0,class:`content-description`},_hoisted_5$158={class:`content-wrapper`},_hoisted_6$136={class:`form-actions-bar`},_sfc_main$334={__name:`FormDialog`,props:mergeModels({title:{type:String},description:{type:String},view:{type:[Object,String],required:!0},formValidator:{type:Function,default:formModel=>!0},buttons:{type:Array,required:!0},maxWidth:{type:String,default:`40rem`}},{formModel:{},formModelModifiers:{}}),emits:mergeModels([`return`],[`update:formModel`]),setup(__props,{emit:__emit}){useUINavBlocker().allowOnly([`focus_u`,`focus_d`,`focus_l`,`focus_r`,`back`,`menu`,`ok`]);let props=__props,emit$1=__emit,formModel=useModel(__props,`formModel`),scopeName=usePopupUINavScopeName(`_formdialog`,props),handleCancelWithBack=()=>{let cancelButton=props.buttons.find(x=>x.extras&&x.extras.cancel);cancelButton?onClick(cancelButton):emit$1(`return`)},onClick=button=>{let data={value:button.value};button.emitData&&(data.formData=formModel.value),emit$1(`return`,data)},formValid=ref(!1),message=ref(null);return watch(formModel,()=>{let res=props.formValidator(formModel.value);message.value=res.error?res.message:props.description,formValid.value=!res.error},{immediate:!0,deep:!0}),(_ctx,_cache)=>withDirectives((openBlock(),createElementBlock(`div`,{class:`form-dialog`,style:normalizeStyle({maxWidth:props.maxWidth}),"bng-ui-scope":unref(scopeName)},[__props.title?(openBlock(),createElementBlock(`div`,_hoisted_2$243,[createBaseVNode(`div`,_hoisted_3$216,toDisplayString(__props.title),1)])):createCommentVNode(``,!0),createBaseVNode(`div`,{class:normalizeClass([{"no-title":!__props.title},`form-dialog-content`])},[message.value?(openBlock(),createElementBlock(`div`,_hoisted_4$185,toDisplayString(message.value),1)):createCommentVNode(``,!0),createBaseVNode(`div`,_hoisted_5$158,[(openBlock(),createBlock(resolveDynamicComponent(__props.view),{modelValue:formModel.value,"onUpdate:modelValue":_cache[0]||=$event=>formModel.value=$event},null,8,[`modelValue`]))])],2),createBaseVNode(`div`,_hoisted_6$136,[(openBlock(!0),createElementBlock(Fragment,null,renderList(__props.buttons,(button,index)=>withDirectives((openBlock(),createBlock(unref(bngButton_default),mergeProps({key:index},{ref_for:!0},button.extras,{disabled:button.disableIfInvalid&&!formValid.value,onClick:$event=>onClick(button)}),{default:withCtx(()=>[createTextVNode(toDisplayString(button.label),1)]),_:2},1040,[`disabled`,`onClick`])),[[unref(BngUiNavFocus_default),__props.buttons.length-index],[unref(BngFocusIf_default),index===0]])),128))])],12,_hoisted_1$295)),[[unref(BngOnUiNav_default),handleCancelWithBack,`back,menu`]])}},FormDialog_default=__plugin_vue_export_helper_default(_sfc_main$334,[[`__scopeId`,`data-v-e78a3aa6`]]),_hoisted_1$294=[`bng-ui-scope`],_hoisted_2$242={class:`popup-content`},_hoisted_3$215={key:0,class:`popup-title`},_hoisted_4$184={class:`popup-body`},_hoisted_5$157={key:0,class:`popup-message`},_hoisted_6$135={class:`popup-buttons`},_sfc_main$333={__name:`Progress`,props:{title:String,message:String,buttons:Array,indeterminate:Boolean,min:{type:Number,default:0},max:{type:Number,default:100},initialValue:{type:Number,default:0},valueLabelFormat:{type:[String,Function],default:()=>val=>`${val}%`},timeout:{type:Number,default:0},cancellable:Boolean,tunnel:Object},emits:[`return`],setup(__props,{emit:__emit}){useUINavBlocker().allowOnly([`focus_u`,`focus_d`,`focus_l`,`focus_r`,`back`,`menu`,`ok`]);let emit$1=__emit,DEFAULT_BUTTON_ID=uniqueId(`___DEFAULT`,`_`),props=__props,defaultButtonIndex=props.buttons.findIndex(button=>button.extras&&button.extras.default),cancelButton=props.buttons.find(button=>button.extras&&button.extras.cancel);~defaultButtonIndex&&onMounted(()=>{document.querySelector(`#${DEFAULT_BUTTON_ID}`).focus()});let scopeName=usePopupUINavScopeName(`_progressPopup`,props),progressValue=ref(props.initialValue),msg=ref(props.message),handleCancelWithBack=e=>{props.cancellable&&close()},close=()=>emit$1(`return`,cancelButton?cancelButton.value:null);return props.tunnel.update=(value,message=void 0)=>{progressValue.value=+value,message!==void 0&&(msg.value=message)},props.tunnel.done=close,props.tunnel.ready=!0,props.timeout&&setTimeout(close,props.timeout*1e3),(_ctx,_cache)=>withDirectives((openBlock(),createElementBlock(`div`,{class:normalizeClass([`popup`]),"bng-ui-scope":unref(scopeName)},[createBaseVNode(`div`,_hoisted_2$242,[__props.title?(openBlock(),createElementBlock(`div`,_hoisted_3$215,toDisplayString(__props.title),1)):createCommentVNode(``,!0),createBaseVNode(`div`,_hoisted_4$184,[msg.value?(openBlock(),createElementBlock(`div`,_hoisted_5$157,toDisplayString(msg.value),1)):createCommentVNode(``,!0),createVNode(unref(bngProgressBar_default),{value:progressValue.value,min:__props.min,max:__props.max,indeterminate:__props.indeterminate,"show-value-label":!__props.indeterminate&&!!__props.valueLabelFormat,"value-label-format":__props.valueLabelFormat},null,8,[`value`,`min`,`max`,`indeterminate`,`show-value-label`,`value-label-format`])]),createBaseVNode(`div`,_hoisted_6$135,[__props.buttons&&__props.buttons.length?(openBlock(!0),createElementBlock(Fragment,{key:0},renderList(__props.buttons,(button,index)=>(openBlock(),createBlock(unref(bngButton_default),mergeProps({key:index},{ref_for:!0},{...index==unref(defaultButtonIndex)&&{id:unref(DEFAULT_BUTTON_ID)},...button.extras},{onClick:$event=>_ctx.$emit(`return`,typeof button.value==`function`?button.value(_ctx.text):button.value)}),{default:withCtx(()=>[createTextVNode(toDisplayString(button.label),1)]),_:2},1040,[`onClick`]))),128)):createCommentVNode(``,!0)])])],8,_hoisted_1$294)),[[unref(BngOnUiNav_default),handleCancelWithBack,`back,menu`]])}},Progress_default=__plugin_vue_export_helper_default(_sfc_main$333,[[`__scopeId`,`data-v-a3c03360`]]),_hoisted_1$293=[`bng-ui-scope`],_hoisted_2$241={class:`popup-content`},_hoisted_3$214={key:0,class:`popup-title`},_hoisted_4$183={class:`popup-body`},_hoisted_5$156={key:0,class:`popup-message`},_hoisted_6$134={class:`popup-buttons`},_sfc_main$332={__name:`Prompt`,props:{buttons:Array,message:String,title:String,maxLength:Number,defaultValue:void 0,validate:Function,errorMessage:String,disableWhenInvalid:Boolean},emits:[`return`],setup(__props,{emit:__emit}){let emit$1=__emit,DEFAULT_BUTTON_ID=uniqueId(`___DEFAULT`,`_`),INPUT_ID=uniqueId(`___INPUT`,`_`),props=__props,scopeName=usePopupUINavScopeName(`_promptPopup`,props),text=ref(props.defaultValue||``),defaultButtonIndex=props.buttons.findIndex(button=>button.extras&&button.extras.default),cancelButton=props.buttons.find(button=>button.extras&&button.extras.cancel),handleEnterButton=text$1=>{props.disableWhenInvalid&&props.validate&&!props.validate(text$1)||emit$1(`return`,text$1)},handleCancelWithBack=e=>{emit$1(`return`,cancelButton?cancelButton.value:null)};return onMounted(()=>{document.querySelector(`#${INPUT_ID} input`).focus()}),(_ctx,_cache)=>withDirectives((openBlock(),createElementBlock(`div`,{class:normalizeClass([`popup`]),"bng-ui-scope":unref(scopeName)},[createBaseVNode(`div`,_hoisted_2$241,[__props.title?(openBlock(),createElementBlock(`div`,_hoisted_3$214,toDisplayString(__props.title),1)):createCommentVNode(``,!0),createBaseVNode(`div`,_hoisted_4$183,[__props.message?(openBlock(),createElementBlock(`div`,_hoisted_5$156,toDisplayString(__props.message),1)):createCommentVNode(``,!0),createVNode(unref(bngInput_default),{id:unref(INPUT_ID),modelValue:text.value,"onUpdate:modelValue":_cache[0]||=$event=>text.value=$event,maxlength:__props.maxLength,onKeyup:_cache[1]||=withKeys($event=>handleEnterButton(text.value),[`enter`]),validate:__props.validate,"error-message":__props.errorMessage},null,8,[`id`,`modelValue`,`maxlength`,`validate`,`error-message`])]),createBaseVNode(`div`,_hoisted_6$134,[(openBlock(!0),createElementBlock(Fragment,null,renderList(__props.buttons,(button,index)=>(openBlock(),createBlock(unref(bngButton_default),mergeProps({key:index},{ref_for:!0},{...index==unref(defaultButtonIndex)&&{id:unref(DEFAULT_BUTTON_ID)},...button.extras},{disabled:__props.disableWhenInvalid&&index>0&&__props.validate&&!__props.validate(text.value),onClick:$event=>_ctx.$emit(`return`,typeof button.value==`function`?button.value(text.value):button.value)}),{default:withCtx(()=>[createTextVNode(toDisplayString(button.label),1)]),_:2},1040,[`disabled`,`onClick`]))),128))])])],8,_hoisted_1$293)),[[unref(BngOnUiNav_default),handleCancelWithBack,`back,menu`]])}},Prompt_default=__plugin_vue_export_helper_default(_sfc_main$332,[[`__scopeId`,`data-v-cce4437b`]]),__default__$9={position:popupPosition.left},_sfc_main$331=Object.assign(__default__$9,{__name:`ScreenOverlay`,props:{view:Object},emits:[`return`],setup(__props){return(_ctx,_cache)=>(openBlock(),createBlock(resolveDynamicComponent(__props.view),{onClose:_cache[0]||=$event=>_ctx.$emit(`return`,!0)},null,32))}}),ScreenOverlay_default=_sfc_main$331,popup_components_exports=__export({Confirmation:()=>Confirmation_default,FormDialog:()=>FormDialog_default,Progress:()=>Progress_default,Prompt:()=>Prompt_default,ScreenOverlay:()=>ScreenOverlay_default}),popupLimit=5,activityLimit=3,count=-1;const PopupTypes=Object.freeze({activity:10,normal:100,priority:1e3});var PopupTypesBack=Object.freeze(Object.keys(PopupTypes).reduce((res,key)=>({...res,[String(PopupTypes[key])]:key}),{})),PopupTypesPairs=Object.freeze(Object.keys(PopupTypes).map(key=>[PopupTypes[key],key]).sort((a$1,b)=>a$1[0]-b[0]));function getPopupTypeName(type=PopupTypes.normal){let strType=String(type);if(strType in PopupTypesBack)return PopupTypesBack[strType];for(let[ptype,pname]of PopupTypesPairs)if(typepopupsAll.filter(itm=>itm.type>=PopupTypes.normal)),activitiesFiltered=computed(()=>popupsAll.filter(itm=>itm.typepopupsFiltered.value.length>0?popupsFiltered.value.slice(-popupLimit):null),popupsWrapper:computed(()=>accumulateWrapper(popupsFiltered.value,getPopupWrapperDefaults())),activities:computed(()=>activitiesFiltered.value.length>0?activitiesFiltered.value.slice(-activityLimit):null),activitiesWrapper:computed(()=>accumulateWrapper(activitiesFiltered.value,getActivityWrapperDefaults()))});function accumulateWrapper(popups,wrapper){for(let popup of popups)wrapper.fade!==popup.wrapper.fade&&(wrapper.fade=popup.wrapper.fade),wrapper.blur!==popup.wrapper.blur&&(wrapper.blur=popup.wrapper.blur),popup.wrapper.style&&wrapper.style.push(...popup.wrapper.style);return wrapper}function addPopup(componentOrName,props={},type=PopupTypes.normal){let component=typeof componentOrName==`string`?popup_components_exports[componentOrName]:componentOrName;if(!component)throw Error(`There is no popup base component named "${componentOrName}".Available components: "${Object.keys(popup_components_exports).join(`", "`)}"`);let popup={id:++count,active:!1,type,typeName:getPopupTypeName(type),component:markRaw({ref:component}),componentName:component.__name,props:{__id:count,...props},position:[popupPosition.default],animated:!0,wrapper:type>=PopupTypes.normal?getPopupWrapperDefaults():getActivityWrapperDefaults()};component.position&&(popup.position=Array.isArray(component.position)?component.position:[component.position]),typeof component.animated==`boolean`&&(popup.animated=component.animated),`wrapper`in component&&(typeof component.wrapper.fade==`boolean`&&(popup.wrapper.fade=component.wrapper.fade),typeof component.wrapper.blur==`boolean`&&(popup.wrapper.blur=component.wrapper.blur),component.wrapper.style&&(popup.wrapper.style=Array.isArray(component.wrapper.style)?component.wrapper.style:[component.wrapper.style])),popup.promise=new Promise((resolve$1,reject)=>{popup._resolve=resolve$1,popup._reject=reject}),popup.return=result=>{for(let i=0;i0&&(popupsAll[popupsAll.length-1].active=!0),reportPopupState(popup,!1);break}result===void 0?popup._reject():popup._resolve(result)},popup.promise.close=popup.return;for(let i=0;itype)return popupsAll.splice(i,0,popup),reportPopupState(popup,!0),popup;return popupsAll.length>0&&(popupsAll[popupsAll.length-1].active=!1),popup.active=!0,popupsAll.push(popup),reportPopupState(popup,!0),popup}function closeLastPopups(count$1=1){popupsAll.slice(-count$1).forEach(popup=>popup.return())}const openMessage=(title,message)=>addPopup(`Confirmation`,{title,message,buttons:[{label:$translate.instant(`ui.common.okay`),value:!0,extras:{default:!0}}]}).promise,openConfirmation=(title,message,buttons=[{label:$translate.instant(`ui.common.okay`),value:!0,extras:{default:!0}},{label:$translate.instant(`ui.common.cancel`),value:!1,extras:{cancel:!0,accent:ACCENTS.secondary}}],appearance=``)=>addPopup(`Confirmation`,{title,message,buttons,appearance}).promise,openPrompt=(message=``,title=``,{buttons=[{label:$translate.instant(`ui.common.okay`),value:text=>text},{label:$translate.instant(`ui.common.cancel`),value:!1,extras:{cancel:!0,accent:ACCENTS.secondary}}],defaultValue,maxLength,validate,errorMessage,disableWhenInvalid}={})=>addPopup(`Prompt`,{message,title,buttons,defaultValue,maxLength,validate,errorMessage,disableWhenInvalid}).promise,openExperimental=(title,message,buttons=[{label:$translate.instant(`ui.common.yes`),value:!0},{label:$translate.instant(`ui.common.no`),value:!1}])=>addPopup(`Confirmation`,{title,message,buttons,appearance:`experimental`}).promise,openScreenOverlay=component=>addPopup(`ScreenOverlay`,{view:markRaw(component)},PopupTypes.activity).promise,openFormDialog=(component,formModel,formValidator,title,description,buttons=[{label:$translate.instant(`ui.common.okay`),value:!0,emitData:!0},{label:$translate.instant(`ui.common.cancel`),value:!1,extras:{cancel:!0,accent:ACCENTS.secondary}}],maxWidth)=>addPopup(`FormDialog`,{view:markRaw(component),formModel,formValidator,title,description,buttons,maxWidth},PopupTypes.normal).promise,openProgress=(message=``,title=``,{buttons=[],indeterminate,min:min$1,max:max$1,initialValue,valueLabelFormat,timeout,cancellable}={})=>{let popup=addPopup(`Progress`,{message,title,buttons,indeterminate,min:min$1,max:max$1,initialValue,valueLabelFormat,timeout,cancellable,tunnel:{}});return popup.progress=popup.props.tunnel,popup.progress.done=popup.return,popup},fixedDelayPopup=(seconds,{makeRemainingText=s=>s?Math.round(s)+`s remaining...`:`Done!`,title=``}={})=>{let popup=openProgress(makeRemainingText(seconds),title,{timeout:seconds+1}),remaining=seconds,endTime=Date.now()+remaining*1e3,countdown=()=>{let timeLeft=(endTime-Date.now())/1e3;timeLeft>0?(remaining=timeLeft,requestAnimationFrame(countdown)):remaining=0,popup.progress.update(~~((seconds-remaining)*100/seconds),makeRemainingText(remaining))};return requestAnimationFrame(countdown),popup};var _hoisted_1$292={class:`activity-selector`},_hoisted_2$240={class:`activities-container`},_hoisted_3$213=[`onClick`],_hoisted_4$182={class:`selector-display`},selectConfig={label:x=>x.label,value:x=>x.value},_sfc_main$330={__name:`ActivitySelector`,props:{activities:{type:Array,required:!0},value:{type:[String,Number]},navLeftEvent:{type:String},navRightEvent:{type:String}},emits:[`valueChanged`],setup(__props,{expose:__expose,emit:__emit}){let props=__props,selectComponent=ref(),emit$1=__emit,activityOptions=computed(()=>props.activities.map((x,index)=>({label:index+1,value:x.value})));computed(()=>(activityOptions.value?activityOptions.value.find(x=>x.value===selectedValue.value):null)||{label:`?`,value:selectedValue.value});let selectedValue=ref(1);watch(()=>props.value,val=>selectedValue.value=val||props.activities[0].value,{immediate:!0});let onValueChanged=value=>{selectedValue.value=value,console.log(`onValueChanged`,value),emit$1(`valueChanged`,value)};return __expose({goNext:()=>selectComponent.value.goNext(),goPrev:()=>selectComponent.value.goPrev()}),computed(()=>`url("${getAssetURL(`icons/temp_debug/map_poi_target.svg`)}")`),(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$292,[createBaseVNode(`div`,_hoisted_2$240,[(openBlock(!0),createElementBlock(Fragment,null,renderList(__props.activities,activity=>(openBlock(),createElementBlock(`div`,{key:activity,class:normalizeClass([`activity-icon`,{highlighted:activity.value===selectedValue.value}]),onClick:$event=>onValueChanged(activity.value)},[createVNode(unref(bngSpriteIcon_default),{src:`map_`+activity.icon,style:{width:`100%`,height:`100%`}},null,8,[`src`])],10,_hoisted_3$213))),128))]),createVNode(unref(bngSelect_default),{ref_key:`selectComponent`,ref:selectComponent,value:selectedValue.value,options:activityOptions.value,config:selectConfig,mute:``,loop:``,onChange:onValueChanged,navLeftEvent:__props.navLeftEvent,navRightEvent:__props.navRightEvent},{display:withCtx(({label})=>[createBaseVNode(`div`,_hoisted_4$182,[createBaseVNode(`span`,null,toDisplayString(label),1),createVNode(unref(bngDivider_default)),createBaseVNode(`span`,null,toDisplayString(__props.activities.length),1)])]),_:1},8,[`value`,`options`,`navLeftEvent`,`navRightEvent`])]))}},ActivitySelector_default=__plugin_vue_export_helper_default(_sfc_main$330,[[`__scopeId`,`data-v-53fb9327`]]),_hoisted_1$291={key:0,class:`activity-start`,"bng-ui-scope":`activityStart`},_hoisted_2$239={class:`activity-props`},_hoisted_3$212={class:`binding-spacer`},BNG_MAIN_STARS_TYPE=`BngMainStars`,_sfc_main$329={__name:`ActivityStart`,setup(__props){useUINavScope(`activityStart`);let activitySelector=ref(null),goNext=()=>activitySelector.value&&activitySelector.value.goNext(),goPrev=()=>activitySelector.value&&activitySelector.value.goPrev(),gameContextStore=useGameContextStore(),{activities}=storeToRefs(gameContextStore),{closeActivitiesPrompt}=gameContextStore,selectedActivityIndex=ref(0),availableActivities=ref([]),activityOptions=computed(()=>{let result=availableActivities.value?availableActivities.value.map((x,index)=>({id:index,value:index,icon:x.icon})):[];return doFiltering&&filterEvents(result.length>1),result}),selectedActivity=computed(()=>{if(selectedActivityIndex.value<0||!availableActivities.value||availableActivities.value.length===0)return null;let activity=availableActivities.value[selectedActivityIndex.value],labels=activity.props&&activity.props.length>0?activity.props.filter(x=>!x.type):[];return{heading:activity.heading,icon:activity.icon,preheadings:activity.preheadings,labels:labels.map(x=>({keyLabel:$translate.instant(x.keyLabel),valueLabel:$translate.instant(x.valueLabel),icon:icons[x.icon]})),stars:activity.props&&activity.props.length>0?activity.props.find(x=>x.type===BNG_MAIN_STARS_TYPE):null,startable:!0,buttonLabel:activity.buttonLabel,action:activity.action,missionInfoPerformActionIndex:activity.missionInfoPerformActionIndex}}),preheadings=computed(()=>selectedActivity.value&&selectedActivity.value.preheadings?selectedActivity.value.preheadings.map(x=>$translate.contextTranslate(x)):[]),invokeActivityAction=()=>{Lua_default.ui_missionInfo.performActivityAction(selectedActivity.value.missionInfoPerformActionIndex)};watch(selectedActivity,()=>{Lua_default.ui_missionInfo.setActivityIndexVisible(selectedActivityIndex.value)});let onActivitySelected=value=>{selectedActivityIndex.value=value},onCancel=()=>{closeActivitiesPrompt()},openPauseMenu=()=>{onCancel(),window.globalAngularRootScope&&window.globalAngularRootScope.$broadcast(`MenuToggle`)};onBeforeMount(()=>{availableActivities.value=activities.value}),onMounted(()=>{getUINavServiceInstance().activate()}),onUnmounted(()=>{doFiltering=!1,getUINavServiceInstance().setFilteredEventsAllExcept(UI_EVENTS.menu,UI_EVENTS.pause,UI_EVENTS.center_cam),Lua_default.ui_missionInfo.setActivityIndexVisible(-1)});let doFiltering=!0,filterEvents=withTabs=>getUINavServiceInstance().setFilteredEventsAllExcept(UI_EVENTS.back,UI_EVENTS.menu,UI_EVENTS.pause,UI_EVENTS.center_cam,...withTabs?[UI_EVENTS.tab_l,UI_EVENTS.tab_r]:[]);return(_ctx,_cache)=>selectedActivity.value?withDirectives((openBlock(),createElementBlock(`div`,_hoisted_1$291,[activityOptions.value&&activityOptions.value.length>1?(openBlock(),createBlock(ActivitySelector_default,{key:0,ref_key:`activitySelector`,ref:activitySelector,activities:activityOptions.value,value:selectedActivityIndex.value,onValueChanged:onActivitySelected,navLeftEvent:`tab_l`,navRightEvent:`tab_r`},null,8,[`activities`,`value`])):createCommentVNode(``,!0),selectedActivity.value.heading?(openBlock(),createBlock(unref(bngScreenHeading_default),{key:1,mute:``,divider:``,preheadings:preheadings.value,"blur-delay":400},{default:withCtx(()=>[createTextVNode(toDisplayString(_ctx.$ctx_t(selectedActivity.value.heading)),1),selectedActivity.value.description?(openBlock(),createElementBlock(Fragment,{key:0},[createTextVNode(`: `+toDisplayString(_ctx.$ctx_t(selectedActivity.value.description)),1)],64)):createCommentVNode(``,!0)]),_:1},8,[`preheadings`])):createCommentVNode(``,!0),createBaseVNode(`div`,_hoisted_2$239,[selectedActivity.value.stars&&selectedActivity.value.stars.defaultStarCount?(openBlock(),createBlock(unref(bngMainStars_default),{key:0,"unlocked-stars":selectedActivity.value.stars.defaultUnlockedStarCount,"total-stars":selectedActivity.value.stars.defaultStarCount,class:`main-stars`},null,8,[`unlocked-stars`,`total-stars`])):createCommentVNode(``,!0),selectedActivity.value.stars&&selectedActivity.value.stars.bonusStarCount?(openBlock(),createBlock(unref(bngMainStars_default),{key:1,"unlocked-stars":selectedActivity.value.stars.bonusStarsUnlockedCount,"total-stars":selectedActivity.value.stars.bonusStarCount,class:`bonus-stars`},null,8,[`unlocked-stars`,`total-stars`])):createCommentVNode(``,!0),(openBlock(!0),createElementBlock(Fragment,null,renderList(selectedActivity.value.labels,(label,index)=>(openBlock(),createBlock(unref(bngPropVal_default),{key:index,iconType:label.icon,keyLabel:label.keyLabel,valueLabel:label.valueLabel},null,8,[`iconType`,`keyLabel`,`valueLabel`]))),128))]),createBaseVNode(`div`,null,[withDirectives((openBlock(),createBlock(unref(bngButton_default),{accent:unref(ACCENTS).main,onClick:invokeActivityAction},{default:withCtx(()=>[createBaseVNode(`span`,_hoisted_3$212,[createVNode(unref(bngBinding_default),{action:`gameplay_interact`})]),selectedActivity.value.startable?(openBlock(),createElementBlock(Fragment,{key:0},[createTextVNode(toDisplayString(_ctx.$ctx_t(selectedActivity.value.buttonLabel)),1)],64)):(openBlock(),createElementBlock(Fragment,{key:1},[createTextVNode(toDisplayString(_ctx.$tt(`ui.mission.action.locked`)),1)],64))]),_:1},8,[`accent`])),[[unref(BngOnUiNav_default),void 0,`gameplay_interact`,{asMouse:!0}]]),withDirectives((openBlock(),createBlock(unref(bngButton_default),{accent:unref(ACCENTS).secondary,onClick:onCancel},{default:withCtx(()=>[createVNode(unref(bngBinding_default),{"ui-event":`back`,controller:``}),createTextVNode(` `+toDisplayString(_ctx.$tt(`ui.common.close`)),1)]),_:1},8,[`accent`])),[[unref(BngOnUiNav_default),void 0,`back`,{asMouse:!0}]])])])),[[unref(BngOnUiNav_default),goPrev,`tab_l`,{up:!0}],[unref(BngOnUiNav_default),goNext,`tab_r`,{up:!0}],[unref(BngOnUiNav_default),openPauseMenu,`menu`]]):createCommentVNode(``,!0)}},ActivityStart_default=__plugin_vue_export_helper_default(_sfc_main$329,[[`__scopeId`,`data-v-1f131cb6`]]),_hoisted_1$290={class:`recovery-wrapper`,"bng-ui-scope":`recoveryPrompt`},_hoisted_2$238={class:`content`},_hoisted_3$211={class:`label`},_hoisted_4$181={key:0,class:`more-options`},_hoisted_5$155={key:0,class:`notification`},__default__$8={wrapper:{fade:!0,blur:!0,style:popupContainer.transparent},position:[popupPosition.center,popupPosition.center]},_sfc_main$328=Object.assign(__default__$8,{__name:`Recovery`,emits:[`return`],setup(__props,{emit:__emit}){let{events:events$3}=useBridge();useUINavScope(`recoveryPrompt`);let emit$1=__emit,{closeRecoveryPrompt}=useGameContextStore(),popupData=ref({}),clickHandler=(index,button,fromController)=>{button.confirmationText||executeButtonAction(index,button)},executeButtonAction=(index,button)=>{Lua_default.core_recoveryPrompt.uiPopupButtonPressed(index+1),button.keepMenuOpen||(closeRecoveryPrompt(),emit$1(`return`,!0))},cancelClickHandler=()=>{Lua_default.core_recoveryPrompt.uiPopupCancelPressed(),popupData.value.cancelButton.keepMenuOpen||(closeRecoveryPrompt(),emit$1(`return`,!0))},updateRecoveryPopupData=()=>{Lua_default.core_recoveryPrompt.getUIData().then(value=>popupData.value=value)};return events$3.on(`updateRecoveryPopupData`,updateRecoveryPopupData),onMounted(()=>{getUINavServiceInstance().activate(),getUINavServiceInstance().clearFilteredEvents(),updateRecoveryPopupData()}),onUnmounted(()=>{events$3.off(`updateRecoveryPopupData`,updateRecoveryPopupData),window.bngVue.getCurrentRoute().name==`unknown`&&getUINavServiceInstance().setFilteredEventsAllExcept(UI_EVENTS.menu,UI_EVENTS.pause,UI_EVENTS.center_cam)}),(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$290,[createVNode(unref(bngCard_default),null,{buttons:withCtx(()=>[unref(popupData).cancelButton?withDirectives((openBlock(),createBlock(unref(bngButton_default),{key:0,label:unref(popupData).cancelButton.label,accent:unref(ACCENTS).attention,onClick:cancelClickHandler},null,8,[`label`,`accent`])),[[unref(BngOnUiNav_default),void 0,`back,menu`,{asMouse:!0}]]):createCommentVNode(``,!0)]),default:withCtx(()=>[createVNode(unref(bngCardHeading_default),{type:`ribbon`},{default:withCtx(()=>[createTextVNode(toDisplayString(unref(popupData).title),1)]),_:1}),createBaseVNode(`div`,_hoisted_2$238,[(openBlock(!0),createElementBlock(Fragment,null,renderList(unref(popupData).buttons,(button,index)=>withDirectives((openBlock(),createBlock(unref(bngButton_default),{"show-hold":!!button.confirmationText,"hold-vertical":``,accent:unref(ACCENTS).outlined,class:`recovery-option-button`},{default:withCtx(()=>[createVNode(unref(bngImageTile_default),{class:`recovery-option-tile`,icon:unref(icons)[button.icon]},{default:withCtx(()=>[createBaseVNode(`span`,_hoisted_3$211,toDisplayString(_ctx.$ctx_t(button.label)),1),button.price?(openBlock(),createBlock(unref(bngDivider_default),{key:0})):createCommentVNode(``,!0),button.price?(openBlock(),createBlock(unref(bngUnit_default),{key:1,class:`units`,money:button.price.money.amount,options:{formatter:x=>~~x}},null,8,[`money`,`options`])):createCommentVNode(``,!0)]),_:2},1032,[`icon`]),button.keepMenuOpen?(openBlock(),createElementBlock(`span`,_hoisted_4$181,`⇢`)):createCommentVNode(``,!0)]),_:2},1032,[`show-hold`,`accent`])),[[unref(BngDisabled_default),!button.enabled],[unref(BngFocusIf_default),!index||button.enabled&&!unref(popupData).buttons[0].enabled],[unref(BngOnUiNav_default),void 0,`ok`,{asMouse:!0,focusRequired:!0}],[unref(BngClick_default),{clickCallback:e=>clickHandler(index,button,e.fromController),holdCallback:button.confirmationText?()=>executeButtonAction(index,button):null,holdDelay:500,repeatInterval:0}]])),256)),unref(popupData).warningMessage?(openBlock(),createElementBlock(`div`,_hoisted_5$155,toDisplayString(unref(popupData).warningMessage),1)):createCommentVNode(``,!0)])]),_:1})]))}}),Recovery_default=__plugin_vue_export_helper_default(_sfc_main$328,[[`__scopeId`,`data-v-8495e64c`]]),_hoisted_1$289={class:`item-container`,navigable:``,tabindex:`0`},_hoisted_2$237={class:`item-content`},_hoisted_3$210={class:`item-container indented`,navigable:``,tabindex:`0`},_hoisted_4$180={class:`item-content`},_sfc_main$327={__name:`FavoriteSelectionItem`,props:{data:Object,level:{type:Number,default:0}},emits:[`addedFunction`,`removedFunction`],setup(__props,{emit:__emit}){let emit$1=__emit,expandedStates=ref({}),focusedItem=ref(null),toggleExpanded=(idx,value)=>{expandedStates.value[idx]=value},select=item=>{focusedItem.value=item},deselect=item=>{focusedItem.value===item&&(focusedItem.value=null)},isFocused=item=>focusedItem.value===item,addActionToQuickAccess=item=>{console.log(`addActionToQuickAccess`,item),item&&item.uniqueID&&emit$1(`addedFunction`,item)},removeFunction=()=>{emit$1(`removedFunction`)};return(_ctx,_cache)=>{let _component_FavoriteSelectionItem=resolveComponent(`FavoriteSelectionItem`,!0);return openBlock(),createBlock(unref(accordion_default),{class:`favorite-selection-item`,expanded:__props.data.expanded},{default:withCtx(()=>[(openBlock(!0),createElementBlock(Fragment,null,renderList(__props.data.items,(item,idx)=>(openBlock(),createElementBlock(`div`,{key:idx,class:`item-wrapper`},[item.items?(openBlock(),createBlock(unref(accordionItem_default),{key:0,navigable:``,static:!item.items,expanded:expandedStates.value[idx],onExpanded:$event=>toggleExpanded(idx,$event),"arrow-big":``,onMouseover:withModifiers($event=>select(item),[`stop`]),onMouseleave:withModifiers($event=>deselect(item),[`stop`]),onFocusin:withModifiers($event=>select(item),[`stop`]),onFocusout:withModifiers($event=>deselect(item),[`stop`]),"primary-action":()=>addActionToQuickAccess(item),"primary-label":`ui.inputActions.menu.menu_item_select.title`,"expand-hint-inline":``},{caption:withCtx(()=>[createBaseVNode(`div`,_hoisted_1$289,[createBaseVNode(`div`,_hoisted_2$237,[createVNode(unref(bngIcon_default),{type:unref(icons)[item.icon]},null,8,[`type`]),createTextVNode(` `+toDisplayString(item.title?unref($translate).instant(item.title):item.niceName),1)]),item.uniqueID&&isFocused(item)?(openBlock(),createBlock(unref(bngButton_default),{key:0,accent:`outlined`,class:`select-button`,onClick:$event=>addActionToQuickAccess(item),"bng-no-nav":``},{default:withCtx(()=>[createVNode(unref(bngBinding_default),{class:`input-icon`,"ui-event":`ok`,controller:``}),_cache[0]||=createTextVNode(` Select `,-1)]),_:1},8,[`onClick`])):createCommentVNode(``,!0)])]),default:withCtx(()=>[createVNode(_component_FavoriteSelectionItem,{data:item,level:__props.level+1,onAddedFunction:addActionToQuickAccess,onRemovedFunction:removeFunction},null,8,[`data`,`level`])]),_:2},1032,[`static`,`expanded`,`onExpanded`,`onMouseover`,`onMouseleave`,`onFocusin`,`onFocusout`,`primary-action`])):(openBlock(),createBlock(unref(accordionItem_default),{key:1,static:!0,navigable:``,onMouseover:withModifiers($event=>select(item),[`stop`]),onMouseleave:withModifiers($event=>deselect(item),[`stop`]),onFocusin:withModifiers($event=>select(item),[`stop`]),onFocusout:withModifiers($event=>deselect(item),[`stop`]),"primary-action":()=>addActionToQuickAccess(item),"primary-label":`ui.inputActions.menu.menu_item_select.title`},{caption:withCtx(()=>[createBaseVNode(`div`,_hoisted_3$210,[createBaseVNode(`div`,_hoisted_4$180,[item.icon?(openBlock(),createBlock(unref(bngIcon_default),{key:0,type:unref(icons)[item.icon]},null,8,[`type`])):createCommentVNode(``,!0),createTextVNode(` `+toDisplayString(unref($translate).instant(item.title)),1)]),item.uniqueID&&isFocused(item)?(openBlock(),createBlock(unref(bngButton_default),{key:0,class:`select-button`,onClick:$event=>addActionToQuickAccess(item),accent:`outlined`,"bng-no-nav":``},{default:withCtx(()=>[createVNode(unref(bngBinding_default),{class:`input-icon`,"ui-event":`ok`,controller:``}),_cache[1]||=createTextVNode(` Select `,-1)]),_:1},8,[`onClick`])):createCommentVNode(``,!0)])]),_:2},1032,[`onMouseover`,`onMouseleave`,`onFocusin`,`onFocusout`,`primary-action`]))]))),128))]),_:1},8,[`expanded`])}}},FavoriteSelectionItem_default=__plugin_vue_export_helper_default(_sfc_main$327,[[`__scopeId`,`data-v-dd594aec`]]),_hoisted_1$288={class:`backgroundContainer`},_hoisted_2$236={key:0,class:`recovery-wrapper`,"bng-ui-scope":`favoriteSelection`},_hoisted_3$209={class:`current-action-container`},_hoisted_4$179={key:0},_hoisted_5$154={key:1},_hoisted_6$133={key:2},_hoisted_7$119={key:0,class:`content`},__default__$7={wrapper:{fade:!0,blur:!0,style:popupContainer.transparent},position:[popupPosition.center,popupPosition.center]},_sfc_main$326=Object.assign(__default__$7,{__name:`FavoriteSelection`,emits:[`return`],setup(__props,{emit:__emit}){let{events:events$3}=useBridge();useUINavScope(`favoriteSelection`);let emit$1=__emit,{closeRecoveryPrompt}=useGameContextStore(),data=ref({}),updateFavoritePopupData=()=>{Lua_default.core_quickAccess.getDynamicSlotConfigurationData().then(value=>data.value=value)};events$3.on(`radialFavoriteSelectionPopupData`,updateFavoritePopupData);let addedFunction=item=>{let config={uniqueID:item.uniqueID,level:item.level,type:item.type,mode:item.mode||`uniqueAction`};console.log(`addedFunction`,config),Lua_default.core_quickAccess.setDynamicSlotConfiguration(data.value.dynamicSlotKey,config),emit$1(`return`,!0)},removeFunction=()=>{Lua_default.core_quickAccess.removeActionFromQuickAccess(data.value.slotIndex),emit$1(`return`,!0)},close=()=>{emit$1(`return`,!0)};return onMounted(()=>{updateFavoritePopupData()}),onUnmounted(()=>{events$3.off(`radialFavoriteSelectionPopupData`,updateFavoritePopupData),window.bngVue.getCurrentRoute().name==`unknown`&&getUINavServiceInstance().setFilteredEventsAllExcept(UI_EVENTS.menu,UI_EVENTS.pause,UI_EVENTS.center_cam)}),(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$288,[unref(data).dynamicSlotKey?(openBlock(),createElementBlock(`div`,_hoisted_2$236,[createVNode(unref(bngCard_default),null,{default:withCtx(()=>[createVNode(unref(bngCardHeading_default),{type:`ribbon`},{default:withCtx(()=>[createTextVNode(` Assign Action to: `+toDisplayString(unref(data).dynamicSlotData.breadcrumbs[0]),1)]),_:1}),createBaseVNode(`div`,_hoisted_3$209,[_cache[3]||=createBaseVNode(`div`,{class:`current-action-label`},`Currently Assigned Action:`,-1),unref(data).dynamicSlotData.mode===`uniqueAction`&&unref(data).uniqueAction?(openBlock(),createElementBlock(`div`,_hoisted_4$179,[unref(data).uniqueAction.icon?(openBlock(),createBlock(unref(bngIcon_default),{key:0,type:unref(icons)[unref(data).uniqueAction.icon]},null,8,[`type`])):createCommentVNode(``,!0),createTextVNode(` `+toDisplayString(unref(data).uniqueAction.title?unref($translate).instant(unref(data).uniqueAction.title):unref(data).uniqueAction.niceName),1)])):createCommentVNode(``,!0),unref(data).dynamicSlotData.mode===`recentActions`?(openBlock(),createElementBlock(`div`,_hoisted_5$154,[createVNode(unref(bngIcon_default),{type:unref(icons).timer},null,8,[`type`]),_cache[1]||=createTextVNode(` Most Recent Action `,-1)])):createCommentVNode(``,!0),unref(data).dynamicSlotData.mode===`empty`?(openBlock(),createElementBlock(`div`,_hoisted_6$133,[createVNode(unref(bngIcon_default),{type:unref(icons).circleSlashed},null,8,[`type`]),_cache[2]||=createTextVNode(` Empty `,-1)])):createCommentVNode(``,!0)]),_cache[5]||=createBaseVNode(`div`,{class:`divider`},null,-1),unref(data).items?(openBlock(),createElementBlock(`div`,_hoisted_7$119,[createVNode(FavoriteSelectionItem_default,{data:unref(data).items,onAddedFunction:addedFunction,onRemovedFunction:removeFunction},null,8,[`data`])])):createCommentVNode(``,!0),withDirectives((openBlock(),createBlock(unref(bngButton_default),{class:`cancel-button`,onClick:_cache[0]||=$event=>close(),accent:`attention`},{default:withCtx(()=>[createVNode(unref(bngBinding_default),{class:`input-icon`,"ui-event":`back`,controller:``}),_cache[4]||=createTextVNode(` Cancel `,-1)]),_:1})),[[unref(BngOnUiNav_default),void 0,`back,menu`,{asMouse:!0}]])]),_:1})])):createCommentVNode(``,!0)]))}}),FavoriteSelection_default=__plugin_vue_export_helper_default(_sfc_main$326,[[`__scopeId`,`data-v-88390882`]]);const useGameContextStore=defineStore(`gameContext`,()=>{let{events:events$3}=useBridge(),activities=ref([]),activityScreen=null,recoveryPrompt=null,radialFavoriteSelectionPrompt=null,deliveryEndScreen=null,simpleDelayPopup=null,startMission=missionId=>{let mission=activities.value.find(x=>x.id===missionId);mission||console.error(`Mission not found ${missionId}. cannot start`);let settings$1=mission.settings,userSettings=mission&&settings$1?settings$1.reduce((a$1,b)=>a$1[b.key]=b.value,a):{};Lua_default.gameplay_markerInteraction.startMissionById(mission.id,userSettings)},closeActivitiesPrompt=()=>{Lua_default.gameplay_markerInteraction.closeViewDetailPrompt(!0)};function openRecoveryPrompt(){recoveryPrompt=addPopup(Recovery_default).promise}function openDynamicSlotConfigurator(){radialFavoriteSelectionPrompt=addPopup(FavoriteSelection_default).promise}function openSimpleDelayPopup(data){simpleDelayPopup=fixedDelayPopup(data.timer,{title:data.heading})}let performActivityAction=activityActionIndex=>Lua_default.ui_missionInfo.performActivityAction(activityActionIndex);events$3.on(`ActivityAcceptUpdate`,onActivityAcceptUpdate),events$3.on(`ActivityAcceptClose`,closeActivitiesPopup),events$3.on(`MenuOpenModule`,closeActivitiesPopup),events$3.on(`ChangeState`,closeActivitiesPopup),events$3.on(`OpenRecoveryPrompt`,openRecoveryPrompt),events$3.on(`OpenDynamicSlotConfigurator`,openDynamicSlotConfigurator),events$3.on(`OpenSimpleDelayPopup`,openSimpleDelayPopup);let deliveryRewardData=ref(!1);function showDeliveryEndScreen(data){deliveryRewardData.value=data,window.bngVue.gotoGameState(`cargoDeliveryReward`)}events$3.on(`OpenDeliveryEndScreen`,showDeliveryEndScreen);function onActivityAcceptUpdate(data){activityScreen&&(activities.value||!data)&&closeActivitiesPopup(),window.location.hash===`#/play`&&(activities.value=data,activities.value&&activities.value.length>0&&(activityScreen=openScreenOverlay(ActivityStart_default)))}function closeActivitiesPopup(){activityScreen&&=(activityScreen.close(!0),null)}function closeRecoveryPrompt(){recoveryPrompt&&=(recoveryPrompt.close(!0),null)}function closeRadialFavoriteSelectionPrompt(){radialFavoriteSelectionPrompt&&=(radialFavoriteSelectionPrompt.close(!0),null)}function closeSimpleDelayPopup(){simpleDelayPopup&&=(simpleDelayPopup.progress.done(),null)}function closeDeliveryEndScreen(){deliveryEndScreen&&=(deliveryEndScreen.close(!0),null)}function dispose$2(){events$3.off(`ActivityAcceptUpdate`,onActivityAcceptUpdate),events$3.off(`ActivityAcceptClose`,closeActivitiesPopup)}return{activities,closeActivitiesPrompt,closeDeliveryEndScreen,closeRecoveryPrompt,closeRadialFavoriteSelectionPrompt,closeSimpleDelayPopup,deliveryRewardData,dispose:dispose$2,performActivityAction,startMission}});var PARSE_NESTED$1=`PARSE_NESTED`,bbcode_main_default=[[/\[url=https?:\/\/([^\s\]]+)\](.*?(?=\[\/url\]))\[\/url\]/gi,`$2`],[/\[url='https?:\/\/([^\s\]]+)'\](.*?(?=\[\/url\]))\[\/url\]/gi,`$2`],[/\[forumurl=https?:\/\/([^\s\]]+)\](\S*?(?=\[\/forumurl\]))\[\/forumurl\]/gi,`$2`],[/\[url\]https?:\/\/(.*?(?=\[\/url\]))\[\/url\]/gi,`$1`],[/\[url=([^\s\]]+)\](.*?(?=\[\/url\]))\[\/url\]/gi,`$2`],[/\[h(\d)\](.*?(?=\[\/h\d\]))\[\/h\d\]/gi,`$2`],[/\[img\]\s*?(\S*?(?=\[\/img\]))\[\/img\]/gi,``],[/\shttp(s|):\/\/(\S*)/gi,`http$1://$2`],[/\[list=\d+\](.*?(?=\[\/list\]))\[\/list\]/gi,`
      $1
    `],[/\[list\]/gi,`
      `],[/\[\/list\]/gi,`
    `],[/\[olist\]/gi,`
      `],[/\[\/olist\]/gi,`
    `],[/\[(\*|\+)\]\s*?((.|\s)*?(?=\[(\*|\+)\]|\<\/ul\>|\<\/ol\>|\n\n|$))/gim,`
  • $2
  • `],[PARSE_NESTED$1,/\[b\](.*?(?=\[\/b\]))\[\/b\]/gi,`$1`],[PARSE_NESTED$1,/\[u\](.*?(?=\[\/u\]))\[\/u\]/gi,`$1`],[PARSE_NESTED$1,/\[s\](.*?(?=\[\/s\]))\[\/s\]/gi,`$1`],[PARSE_NESTED$1,/\[i\](.*?(?=\[\/i\]))\[\/i\]/gi,`$1`],[/\[strike\](.*?(?=\[\/strike\]))\[\/strike\]/gi,`$1`],[/\[code\](.*?(?=\[\/code\]))\[\/code\]/gi,`$1`],[/\[br\]/gi,`
    `],[/\n\n/gi,`

    `],[/\n/gi,`
    `],[/\[attach=?f?u?l?l?\](.*?(?=\[\/attach\]))\[\/attach\]/gi,``],[/\[USER=([\d]+)\](.*?(?=\[\/USER\]))\[\/USER\]/gi,`$2`],[/\[MEDIA=youtube\](.*?(?=\[\/MEDIA\]))\[\/MEDIA\]/gi,`
    `],[/\[MEDIA=beamng\](.*?(?=\[\/MEDIA\]))\[\/MEDIA\]/gi,``],[PARSE_NESTED$1,/\[size=(\d+)\]([^[]*(?:\[(?!size=\d+\]|\/size\])[^[]*)*)\[\/size\]/gi,`$2`],[PARSE_NESTED$1,/\[COLOR=([a-z0-9\#\, \'\"\(\)]+)\]([^[]*(?:\[(?!COLOR=[a-z0-9#\(\)]+\]|\/COLOR\])[^[]*)*)\[\/COLOR\]/gi,`$2`],[PARSE_NESTED$1,/\[font=([^\]]+)\](.*?(?=\[\/font\]))\[\/font\]/gi,`$2`],[/\[hr\]\[\/hr\]/gi,`
    `],[/\[spoiler=([^\]]+)\](.*?(?=\[\/spoiler\]))\[\/spoiler\]/gi,`
    Spoiler: $1
    $2
    `],[/\[spoiler\](.*?(?=\[\/spoiler\]))\[\/spoiler\]/gi,`
    Spoiler
    $1
    `],[PARSE_NESTED$1,/\[left\](.*?(?=\[\/left\]))\[\/left\]/gi,`

    $1

    `],[PARSE_NESTED$1,/\[center\](.*?(?=\[\/center\]))\[\/center\]/gi,`

    $1

    `],[PARSE_NESTED$1,/\[right\](.*?(?=\[\/right\]))\[\/right\]/gi,`

    $1

    `],[PARSE_NESTED$1,/\*\*(.*?(?=\*\*))\*\*/gi,`$1`],[PARSE_NESTED$1,/\*(.*?(?=\*))\*/gi,`$1`],[PARSE_NESTED$1,/\[(.*?(?=\]\())\]\((https?:\/\/((.*?(?=\)))))\)/gi,`$1 ($2)`]],bbcode_vue_default=[[/\[ico=([^\s\]]+)\s*\](.*?(?=\[\/ico\]))\[\/ico\]/gi,`$2`],[/\[ico=([^\s\]]+)\s*\]/gi,``],[/\[action=(.*?)\]\[showunassigned=(.*?)\](.*?)/gi,``],[/\[action=(.*?)\](.*?)/gi,``],[/\[action=(.*?)\]/gi,``],[/\[(money|beamXP|stars|vouchers)=(.*?)\]/g,``]],bbcode_angular_default=[[/\[ico=([^\s\]]+)\s*\](.*?(?=\[\/ico\]))\[\/ico\]/gi,`$2`],[/\[ico=([^\s\]]+)\s*\]/gi,``],[/\[action=(.*?)\]\[showunassigned=(.*?)\](.*?)/gi,``],[/\[action=(.*?)\](.*?)/gi,``],[/\[action=(.*?)\]/gi,``]],bbcode_exports=__export({parse:()=>parse$1,useExtensions:()=>useExtensions}),PARSE_NESTED=`PARSE_NESTED`,_extensions=bbcode_vue_default;const useExtensions=exts=>_extensions=exts,parse$1=(txt,extensions$1=_extensions)=>{let text=``+txt;return[...bbcode_main_default,...extensions$1].forEach(replacement=>{let{nested,fromTo}=replacementDetails(replacement);text=nested?parseNested(text,...fromTo):text.replace(...fromTo)}),text};window.angularParseBBCode=txt=>parse$1(txt,bbcode_angular_default);var replacementDetails=replacement=>({nested:replacement.length==3&&replacement[0]===PARSE_NESTED,fromTo:replacement.slice(-2)}),parseNested=(text,regex,template)=>{for(;~text.search(regex);)text=text.replace(regex,template);return text},markdown_exports=__export({parse:()=>parse});function parse(src){let h$1=``;return src.replace(/^\s+|\r|\s+$/g,``).replace(/\t/g,` `).split(/\n\n+/).forEach(function(b,f,R){f=b[0],R={"*":[/\n\* /,`
    • `,`
    `],1:[/\n[1-9]\d*\.? /,`
    1. `,`
    `]," ":[/\n {4}/,`
    `,`
    `,` `],">":[/\n> /,`
    `,`
    `,`
    `,CHAR_LS=`\u2028`,CHAR_PS=`\u2029`;function createScanner(str){let _buf=str,_index=0,_line=1,_column=1,_peekOffset=0,isCRLF=index$1=>_buf[index$1]===CHAR_CR&&_buf[index$1+1]===CHAR_LF,isLF=index$1=>_buf[index$1]===CHAR_LF,isPS=index$1=>_buf[index$1]===CHAR_PS,isLS=index$1=>_buf[index$1]===CHAR_LS,isLineEnd=index$1=>isCRLF(index$1)||isLF(index$1)||isPS(index$1)||isLS(index$1),index=()=>_index,line=()=>_line,column=()=>_column,peekOffset=()=>_peekOffset,charAt=offset$2=>isCRLF(offset$2)||isPS(offset$2)||isLS(offset$2)?CHAR_LF:_buf[offset$2],currentChar=()=>charAt(_index),currentPeek=()=>charAt(_index+_peekOffset);function next(){return _peekOffset=0,isLineEnd(_index)&&(_line++,_column=0),isCRLF(_index)&&_index++,_index++,_column++,_buf[_index]}function peek(){return isCRLF(_index+_peekOffset)&&_peekOffset++,_peekOffset++,_buf[_index+_peekOffset]}function reset$1(){_index=0,_line=1,_column=1,_peekOffset=0}function resetPeek(offset$2=0){_peekOffset=offset$2}function skipToPeek(){let target=_index+_peekOffset;for(;target!==_index;)next();_peekOffset=0}return{index,line,column,peekOffset,charAt,currentChar,currentPeek,next,peek,reset:reset$1,resetPeek,skipToPeek}}var EOF=void 0,DOT=`.`,LITERAL_DELIMITER=`'`,ERROR_DOMAIN$3=`tokenizer`;function createTokenizer(source,options={}){let location$1=options.location!==!1,_scnr=createScanner(source),currentOffset=()=>_scnr.index(),currentPosition=()=>createPosition(_scnr.line(),_scnr.column(),_scnr.index()),_initLoc=currentPosition(),_initOffset=currentOffset(),_context={currentType:13,offset:_initOffset,startLoc:_initLoc,endLoc:_initLoc,lastType:13,lastOffset:_initOffset,lastStartLoc:_initLoc,lastEndLoc:_initLoc,braceNest:0,inLinked:!1,text:``},context=()=>_context,{onError}=options;function emitError$1(code,pos,offset$2,...args){let ctx=context();pos.column+=offset$2,pos.offset+=offset$2,onError&&onError(createCompileError(code,location$1?createLocation(ctx.startLoc,pos):null,{domain:ERROR_DOMAIN$3,args}))}function getToken(context$1,type,value){context$1.endLoc=currentPosition(),context$1.currentType=type;let token={type};return location$1&&(token.loc=createLocation(context$1.startLoc,context$1.endLoc)),value!=null&&(token.value=value),token}let getEndToken=context$1=>getToken(context$1,13);function eat(scnr,ch){return scnr.currentChar()===ch?(scnr.next(),ch):(emitError$1(CompileErrorCodes.EXPECTED_TOKEN,currentPosition(),0,ch),``)}function peekSpaces(scnr){let buf=``;for(;scnr.currentPeek()===CHAR_SP||scnr.currentPeek()===CHAR_LF;)buf+=scnr.currentPeek(),scnr.peek();return buf}function skipSpaces(scnr){let buf=peekSpaces(scnr);return scnr.skipToPeek(),buf}function isIdentifierStart(ch){if(ch===EOF)return!1;let cc=ch.charCodeAt(0);return cc>=97&&cc<=122||cc>=65&&cc<=90||cc===95}function isNumberStart(ch){if(ch===EOF)return!1;let cc=ch.charCodeAt(0);return cc>=48&&cc<=57}function isNamedIdentifierStart(scnr,context$1){let{currentType}=context$1;if(currentType!==2)return!1;peekSpaces(scnr);let ret=isIdentifierStart(scnr.currentPeek());return scnr.resetPeek(),ret}function isListIdentifierStart(scnr,context$1){let{currentType}=context$1;if(currentType!==2)return!1;peekSpaces(scnr);let ret=isNumberStart(scnr.currentPeek()===`-`?scnr.peek():scnr.currentPeek());return scnr.resetPeek(),ret}function isLiteralStart(scnr,context$1){let{currentType}=context$1;if(currentType!==2)return!1;peekSpaces(scnr);let ret=scnr.currentPeek()===LITERAL_DELIMITER;return scnr.resetPeek(),ret}function isLinkedDotStart(scnr,context$1){let{currentType}=context$1;if(currentType!==7)return!1;peekSpaces(scnr);let ret=scnr.currentPeek()===`.`;return scnr.resetPeek(),ret}function isLinkedModifierStart(scnr,context$1){let{currentType}=context$1;if(currentType!==8)return!1;peekSpaces(scnr);let ret=isIdentifierStart(scnr.currentPeek());return scnr.resetPeek(),ret}function isLinkedDelimiterStart(scnr,context$1){let{currentType}=context$1;if(!(currentType===7||currentType===11))return!1;peekSpaces(scnr);let ret=scnr.currentPeek()===`:`;return scnr.resetPeek(),ret}function isLinkedReferStart(scnr,context$1){let{currentType}=context$1;if(currentType!==9)return!1;let fn=()=>{let ch=scnr.currentPeek();return ch===`{`?isIdentifierStart(scnr.peek()):ch===`@`||ch===`|`||ch===`:`||ch===`.`||ch===CHAR_SP||!ch?!1:ch===CHAR_LF?(scnr.peek(),fn()):isTextStart(scnr,!1)},ret=fn();return scnr.resetPeek(),ret}function isPluralStart(scnr){peekSpaces(scnr);let ret=scnr.currentPeek()===`|`;return scnr.resetPeek(),ret}function isTextStart(scnr,reset$1=!0){let fn=(hasSpace=!1,prev=``)=>{let ch=scnr.currentPeek();return ch===`{`||ch===`@`||!ch?hasSpace:ch===`|`?!(prev===CHAR_SP||prev===CHAR_LF):ch===CHAR_SP?(scnr.peek(),fn(!0,CHAR_SP)):ch===CHAR_LF?(scnr.peek(),fn(!0,CHAR_LF)):!0},ret=fn();return reset$1&&scnr.resetPeek(),ret}function takeChar(scnr,fn){let ch=scnr.currentChar();return ch===EOF?EOF:fn(ch)?(scnr.next(),ch):null}function isIdentifier(ch){let cc=ch.charCodeAt(0);return cc>=97&&cc<=122||cc>=65&&cc<=90||cc>=48&&cc<=57||cc===95||cc===36}function takeIdentifierChar(scnr){return takeChar(scnr,isIdentifier)}function isNamedIdentifier(ch){let cc=ch.charCodeAt(0);return cc>=97&&cc<=122||cc>=65&&cc<=90||cc>=48&&cc<=57||cc===95||cc===36||cc===45}function takeNamedIdentifierChar(scnr){return takeChar(scnr,isNamedIdentifier)}function isDigit(ch){let cc=ch.charCodeAt(0);return cc>=48&&cc<=57}function takeDigit(scnr){return takeChar(scnr,isDigit)}function isHexDigit(ch){let cc=ch.charCodeAt(0);return cc>=48&&cc<=57||cc>=65&&cc<=70||cc>=97&&cc<=102}function takeHexDigit(scnr){return takeChar(scnr,isHexDigit)}function getDigits(scnr){let ch=``,num=``;for(;ch=takeDigit(scnr);)num+=ch;return num}function readText(scnr){let buf=``;for(;;){let ch=scnr.currentChar();if(ch===`{`||ch===`}`||ch===`@`||ch===`|`||!ch)break;if(ch===CHAR_SP||ch===CHAR_LF)if(isTextStart(scnr))buf+=ch,scnr.next();else if(isPluralStart(scnr))break;else buf+=ch,scnr.next();else buf+=ch,scnr.next()}return buf}function readNamedIdentifier(scnr){skipSpaces(scnr);let ch=``,name=``;for(;ch=takeNamedIdentifierChar(scnr);)name+=ch;let currentChar=scnr.currentChar();if(currentChar&¤tChar!==`}`&¤tChar!==EOF&¤tChar!==CHAR_SP&¤tChar!==CHAR_LF&¤tChar!==` `){let invalidPart=readInvalidIdentifier(scnr);return emitError$1(CompileErrorCodes.INVALID_TOKEN_IN_PLACEHOLDER,currentPosition(),0,name+invalidPart),name+invalidPart}return scnr.currentChar()===EOF&&emitError$1(CompileErrorCodes.UNTERMINATED_CLOSING_BRACE,currentPosition(),0),name}function readListIdentifier(scnr){skipSpaces(scnr);let value=``;return scnr.currentChar()===`-`?(scnr.next(),value+=`-${getDigits(scnr)}`):value+=getDigits(scnr),scnr.currentChar()===EOF&&emitError$1(CompileErrorCodes.UNTERMINATED_CLOSING_BRACE,currentPosition(),0),value}function isLiteral(ch){return ch!==LITERAL_DELIMITER&&ch!==CHAR_LF}function readLiteral(scnr){skipSpaces(scnr),eat(scnr,`'`);let ch=``,literal=``;for(;ch=takeChar(scnr,isLiteral);)ch===`\\`?literal+=readEscapeSequence(scnr):literal+=ch;let current=scnr.currentChar();return current===CHAR_LF||current===EOF?(emitError$1(CompileErrorCodes.UNTERMINATED_SINGLE_QUOTE_IN_PLACEHOLDER,currentPosition(),0),current===CHAR_LF&&(scnr.next(),eat(scnr,`'`)),literal):(eat(scnr,`'`),literal)}function readEscapeSequence(scnr){let ch=scnr.currentChar();switch(ch){case`\\`:case`'`:return scnr.next(),`\\${ch}`;case`u`:return readUnicodeEscapeSequence(scnr,ch,4);case`U`:return readUnicodeEscapeSequence(scnr,ch,6);default:return emitError$1(CompileErrorCodes.UNKNOWN_ESCAPE_SEQUENCE,currentPosition(),0,ch),``}}function readUnicodeEscapeSequence(scnr,unicode,digits){eat(scnr,unicode);let sequence=``;for(let i=0;i{let ch=scnr.currentChar();return ch===`{`||ch===`@`||ch===`|`||ch===`(`||ch===`)`||!ch||ch===CHAR_SP?buf:(buf+=ch,scnr.next(),fn(buf))};return fn(``)}function readPlural(scnr){skipSpaces(scnr);let plural=eat(scnr,`|`);return skipSpaces(scnr),plural}function readTokenInPlaceholder(scnr,context$1){let token=null;switch(scnr.currentChar()){case`{`:return context$1.braceNest>=1&&emitError$1(CompileErrorCodes.NOT_ALLOW_NEST_PLACEHOLDER,currentPosition(),0),scnr.next(),token=getToken(context$1,2,`{`),skipSpaces(scnr),context$1.braceNest++,token;case`}`:return context$1.braceNest>0&&context$1.currentType===2&&emitError$1(CompileErrorCodes.EMPTY_PLACEHOLDER,currentPosition(),0),scnr.next(),token=getToken(context$1,3,`}`),context$1.braceNest--,context$1.braceNest>0&&skipSpaces(scnr),context$1.inLinked&&context$1.braceNest===0&&(context$1.inLinked=!1),token;case`@`:return context$1.braceNest>0&&emitError$1(CompileErrorCodes.UNTERMINATED_CLOSING_BRACE,currentPosition(),0),token=readTokenInLinked(scnr,context$1)||getEndToken(context$1),context$1.braceNest=0,token;default:{let validNamedIdentifier=!0,validListIdentifier=!0,validLiteral=!0;if(isPluralStart(scnr))return context$1.braceNest>0&&emitError$1(CompileErrorCodes.UNTERMINATED_CLOSING_BRACE,currentPosition(),0),token=getToken(context$1,1,readPlural(scnr)),context$1.braceNest=0,context$1.inLinked=!1,token;if(context$1.braceNest>0&&(context$1.currentType===4||context$1.currentType===5||context$1.currentType===6))return emitError$1(CompileErrorCodes.UNTERMINATED_CLOSING_BRACE,currentPosition(),0),context$1.braceNest=0,readToken(scnr,context$1);if(validNamedIdentifier=isNamedIdentifierStart(scnr,context$1))return token=getToken(context$1,4,readNamedIdentifier(scnr)),skipSpaces(scnr),token;if(validListIdentifier=isListIdentifierStart(scnr,context$1))return token=getToken(context$1,5,readListIdentifier(scnr)),skipSpaces(scnr),token;if(validLiteral=isLiteralStart(scnr,context$1))return token=getToken(context$1,6,readLiteral(scnr)),skipSpaces(scnr),token;if(!validNamedIdentifier&&!validListIdentifier&&!validLiteral)return token=getToken(context$1,12,readInvalidIdentifier(scnr)),emitError$1(CompileErrorCodes.INVALID_TOKEN_IN_PLACEHOLDER,currentPosition(),0,token.value),skipSpaces(scnr),token;break}}return token}function readTokenInLinked(scnr,context$1){let{currentType}=context$1,token=null,ch=scnr.currentChar();switch((currentType===7||currentType===8||currentType===11||currentType===9)&&(ch===CHAR_LF||ch===CHAR_SP)&&emitError$1(CompileErrorCodes.INVALID_LINKED_FORMAT,currentPosition(),0),ch){case`@`:return scnr.next(),token=getToken(context$1,7,`@`),context$1.inLinked=!0,token;case`.`:return skipSpaces(scnr),scnr.next(),getToken(context$1,8,`.`);case`:`:return skipSpaces(scnr),scnr.next(),getToken(context$1,9,`:`);default:return isPluralStart(scnr)?(token=getToken(context$1,1,readPlural(scnr)),context$1.braceNest=0,context$1.inLinked=!1,token):isLinkedDotStart(scnr,context$1)||isLinkedDelimiterStart(scnr,context$1)?(skipSpaces(scnr),readTokenInLinked(scnr,context$1)):isLinkedModifierStart(scnr,context$1)?(skipSpaces(scnr),getToken(context$1,11,readLinkedModifier(scnr))):isLinkedReferStart(scnr,context$1)?(skipSpaces(scnr),ch===`{`?readTokenInPlaceholder(scnr,context$1)||token:getToken(context$1,10,readLinkedRefer(scnr))):(currentType===7&&emitError$1(CompileErrorCodes.INVALID_LINKED_FORMAT,currentPosition(),0),context$1.braceNest=0,context$1.inLinked=!1,readToken(scnr,context$1))}}function readToken(scnr,context$1){let token={type:13};if(context$1.braceNest>0)return readTokenInPlaceholder(scnr,context$1)||getEndToken(context$1);if(context$1.inLinked)return readTokenInLinked(scnr,context$1)||getEndToken(context$1);switch(scnr.currentChar()){case`{`:return readTokenInPlaceholder(scnr,context$1)||getEndToken(context$1);case`}`:return emitError$1(CompileErrorCodes.UNBALANCED_CLOSING_BRACE,currentPosition(),0),scnr.next(),getToken(context$1,3,`}`);case`@`:return readTokenInLinked(scnr,context$1)||getEndToken(context$1);default:if(isPluralStart(scnr))return token=getToken(context$1,1,readPlural(scnr)),context$1.braceNest=0,context$1.inLinked=!1,token;if(isTextStart(scnr))return getToken(context$1,0,readText(scnr));break}return token}function nextToken(){let{currentType,offset:offset$2,startLoc,endLoc}=_context;return _context.lastType=currentType,_context.lastOffset=offset$2,_context.lastStartLoc=startLoc,_context.lastEndLoc=endLoc,_context.offset=currentOffset(),_context.startLoc=currentPosition(),_scnr.currentChar()===EOF?getToken(_context,13):readToken(_scnr,_context)}return{nextToken,currentOffset,currentPosition,context}}var ERROR_DOMAIN$2=`parser`,KNOWN_ESCAPES=/(?:\\\\|\\'|\\u([0-9a-fA-F]{4})|\\U([0-9a-fA-F]{6}))/g;function fromEscapeSequence(match,codePoint4,codePoint6){switch(match){case`\\\\`:return`\\`;case`\\'`:return`'`;default:{let codePoint=parseInt(codePoint4||codePoint6,16);return codePoint<=55295||codePoint>=57344?String.fromCodePoint(codePoint):`�`}}}function createParser(options={}){let location$1=options.location!==!1,{onError}=options;function emitError$1(tokenzer,code,start,offset$2,...args){let end=tokenzer.currentPosition();end.offset+=offset$2,end.column+=offset$2,onError&&onError(createCompileError(code,location$1?createLocation(start,end):null,{domain:ERROR_DOMAIN$2,args}))}function startNode(type,offset$2,loc){let node={type};return location$1&&(node.start=offset$2,node.end=offset$2,node.loc={start:loc,end:loc}),node}function endNode(node,offset$2,pos,type){location$1&&(node.end=offset$2,node.loc&&(node.loc.end=pos))}function parseText$1(tokenizer$1,value){let context=tokenizer$1.context(),node=startNode(3,context.offset,context.startLoc);return node.value=value,endNode(node,tokenizer$1.currentOffset(),tokenizer$1.currentPosition()),node}function parseList(tokenizer$1,index){let{lastOffset:offset$2,lastStartLoc:loc}=tokenizer$1.context(),node=startNode(5,offset$2,loc);return node.index=parseInt(index,10),tokenizer$1.nextToken(),endNode(node,tokenizer$1.currentOffset(),tokenizer$1.currentPosition()),node}function parseNamed(tokenizer$1,key){let{lastOffset:offset$2,lastStartLoc:loc}=tokenizer$1.context(),node=startNode(4,offset$2,loc);return node.key=key,tokenizer$1.nextToken(),endNode(node,tokenizer$1.currentOffset(),tokenizer$1.currentPosition()),node}function parseLiteral(tokenizer$1,value){let{lastOffset:offset$2,lastStartLoc:loc}=tokenizer$1.context(),node=startNode(9,offset$2,loc);return node.value=value.replace(KNOWN_ESCAPES,fromEscapeSequence),tokenizer$1.nextToken(),endNode(node,tokenizer$1.currentOffset(),tokenizer$1.currentPosition()),node}function parseLinkedModifier(tokenizer$1){let token=tokenizer$1.nextToken(),context=tokenizer$1.context(),{lastOffset:offset$2,lastStartLoc:loc}=context,node=startNode(8,offset$2,loc);return token.type===11?(token.value??emitError$1(tokenizer$1,CompileErrorCodes.UNEXPECTED_LEXICAL_ANALYSIS,context.lastStartLoc,0,getTokenCaption(token)),node.value=token.value||``,endNode(node,tokenizer$1.currentOffset(),tokenizer$1.currentPosition()),{node}):(emitError$1(tokenizer$1,CompileErrorCodes.UNEXPECTED_EMPTY_LINKED_MODIFIER,context.lastStartLoc,0),node.value=``,endNode(node,offset$2,loc),{nextConsumeToken:token,node})}function parseLinkedKey(tokenizer$1,value){let context=tokenizer$1.context(),node=startNode(7,context.offset,context.startLoc);return node.value=value,endNode(node,tokenizer$1.currentOffset(),tokenizer$1.currentPosition()),node}function parseLinked(tokenizer$1){let context=tokenizer$1.context(),linkedNode=startNode(6,context.offset,context.startLoc),token=tokenizer$1.nextToken();if(token.type===8){let parsed=parseLinkedModifier(tokenizer$1);linkedNode.modifier=parsed.node,token=parsed.nextConsumeToken||tokenizer$1.nextToken()}switch(token.type!==9&&emitError$1(tokenizer$1,CompileErrorCodes.UNEXPECTED_LEXICAL_ANALYSIS,context.lastStartLoc,0,getTokenCaption(token)),token=tokenizer$1.nextToken(),token.type===2&&(token=tokenizer$1.nextToken()),token.type){case 10:token.value??emitError$1(tokenizer$1,CompileErrorCodes.UNEXPECTED_LEXICAL_ANALYSIS,context.lastStartLoc,0,getTokenCaption(token)),linkedNode.key=parseLinkedKey(tokenizer$1,token.value||``);break;case 4:token.value??emitError$1(tokenizer$1,CompileErrorCodes.UNEXPECTED_LEXICAL_ANALYSIS,context.lastStartLoc,0,getTokenCaption(token)),linkedNode.key=parseNamed(tokenizer$1,token.value||``);break;case 5:token.value??emitError$1(tokenizer$1,CompileErrorCodes.UNEXPECTED_LEXICAL_ANALYSIS,context.lastStartLoc,0,getTokenCaption(token)),linkedNode.key=parseList(tokenizer$1,token.value||``);break;case 6:token.value??emitError$1(tokenizer$1,CompileErrorCodes.UNEXPECTED_LEXICAL_ANALYSIS,context.lastStartLoc,0,getTokenCaption(token)),linkedNode.key=parseLiteral(tokenizer$1,token.value||``);break;default:{emitError$1(tokenizer$1,CompileErrorCodes.UNEXPECTED_EMPTY_LINKED_KEY,context.lastStartLoc,0);let nextContext=tokenizer$1.context(),emptyLinkedKeyNode=startNode(7,nextContext.offset,nextContext.startLoc);return emptyLinkedKeyNode.value=``,endNode(emptyLinkedKeyNode,nextContext.offset,nextContext.startLoc),linkedNode.key=emptyLinkedKeyNode,endNode(linkedNode,nextContext.offset,nextContext.startLoc),{nextConsumeToken:token,node:linkedNode}}}return endNode(linkedNode,tokenizer$1.currentOffset(),tokenizer$1.currentPosition()),{node:linkedNode}}function parseMessage(tokenizer$1){let context=tokenizer$1.context(),node=startNode(2,context.currentType===1?tokenizer$1.currentOffset():context.offset,context.currentType===1?context.endLoc:context.startLoc);node.items=[];let nextToken=null;do{let token=nextToken||tokenizer$1.nextToken();switch(nextToken=null,token.type){case 0:token.value??emitError$1(tokenizer$1,CompileErrorCodes.UNEXPECTED_LEXICAL_ANALYSIS,context.lastStartLoc,0,getTokenCaption(token)),node.items.push(parseText$1(tokenizer$1,token.value||``));break;case 5:token.value??emitError$1(tokenizer$1,CompileErrorCodes.UNEXPECTED_LEXICAL_ANALYSIS,context.lastStartLoc,0,getTokenCaption(token)),node.items.push(parseList(tokenizer$1,token.value||``));break;case 4:token.value??emitError$1(tokenizer$1,CompileErrorCodes.UNEXPECTED_LEXICAL_ANALYSIS,context.lastStartLoc,0,getTokenCaption(token)),node.items.push(parseNamed(tokenizer$1,token.value||``));break;case 6:token.value??emitError$1(tokenizer$1,CompileErrorCodes.UNEXPECTED_LEXICAL_ANALYSIS,context.lastStartLoc,0,getTokenCaption(token)),node.items.push(parseLiteral(tokenizer$1,token.value||``));break;case 7:{let parsed=parseLinked(tokenizer$1);node.items.push(parsed.node),nextToken=parsed.nextConsumeToken||null;break}}}while(context.currentType!==13&&context.currentType!==1);return endNode(node,context.currentType===1?context.lastOffset:tokenizer$1.currentOffset(),context.currentType===1?context.lastEndLoc:tokenizer$1.currentPosition()),node}function parsePlural(tokenizer$1,offset$2,loc,msgNode){let context=tokenizer$1.context(),hasEmptyMessage=msgNode.items.length===0,node=startNode(1,offset$2,loc);node.cases=[],node.cases.push(msgNode);do{let msg=parseMessage(tokenizer$1);hasEmptyMessage||=msg.items.length===0,node.cases.push(msg)}while(context.currentType!==13);return hasEmptyMessage&&emitError$1(tokenizer$1,CompileErrorCodes.MUST_HAVE_MESSAGES_IN_PLURAL,loc,0),endNode(node,tokenizer$1.currentOffset(),tokenizer$1.currentPosition()),node}function parseResource(tokenizer$1){let context=tokenizer$1.context(),{offset:offset$2,startLoc}=context,msgNode=parseMessage(tokenizer$1);return context.currentType===13?msgNode:parsePlural(tokenizer$1,offset$2,startLoc,msgNode)}function parse$2(source){let tokenizer$1=createTokenizer(source,assign$1({},options)),context=tokenizer$1.context(),node=startNode(0,context.offset,context.startLoc);return location$1&&node.loc&&(node.loc.source=source),node.body=parseResource(tokenizer$1),options.onCacheKey&&(node.cacheKey=options.onCacheKey(source)),context.currentType!==13&&emitError$1(tokenizer$1,CompileErrorCodes.UNEXPECTED_LEXICAL_ANALYSIS,context.lastStartLoc,0,source[context.offset]||``),endNode(node,tokenizer$1.currentOffset(),tokenizer$1.currentPosition()),node}return{parse:parse$2}}function getTokenCaption(token){if(token.type===13)return`EOF`;let name=(token.value||``).replace(/\r?\n/gu,`\\n`);return name.length>10?name.slice(0,9)+`…`:name}function createTransformer(ast,options={}){let _context={ast,helpers:new Set};return{context:()=>_context,helper:name=>(_context.helpers.add(name),name)}}function traverseNodes(nodes,transformer){for(let i=0;ioptimizeMessageNode(c)),ast}function optimizeMessageNode(message){if(message.items.length===1){let item=message.items[0];(item.type===3||item.type===9)&&(message.static=item.value,delete item.value)}else{let values=[];for(let i=0;i_context;function push(code,node){_context.code+=code}function _newline(n,withBreakLine=!0){let _breakLineCode=withBreakLine?breakLineCode:``;push(_needIndent?_breakLineCode+`  `.repeat(n):_breakLineCode)}function indent(withNewLine=!0){let level$1=++_context.indentLevel;withNewLine&&_newline(level$1)}function deindent(withNewLine=!0){let level$1=--_context.indentLevel;withNewLine&&_newline(level$1)}function newline(){_newline(_context.indentLevel)}return{context,push,indent,deindent,newline,helper:key=>`_${key}`,needIndent:()=>_context.needIndent}}function generateLinkedNode(generator,node){let{helper}=generator;generator.push(`${helper(`linked`)}(`),generateNode(generator,node.key),node.modifier?(generator.push(`, `),generateNode(generator,node.modifier),generator.push(`, _type`)):generator.push(`, undefined, _type`),generator.push(`)`)}function generateMessageNode(generator,node){let{helper,needIndent}=generator;generator.push(`${helper(`normalize`)}([`),generator.indent(needIndent());let length=node.items.length;for(let i=0;i1){generator.push(`${helper(`plural`)}([`),generator.indent(needIndent());let length=node.cases.length;for(let i=0;i{let mode=isString(options.mode)?options.mode:`normal`,filename=isString(options.filename)?options.filename:`message.intl`,sourceMap=!!options.sourceMap,breakLineCode=options.breakLineCode==null?mode===`arrow`?`;`:`
    `:options.breakLineCode,needIndent=options.needIndent?options.needIndent:mode!==`arrow`,helpers=ast.helpers||[],generator=createCodeGenerator(ast,{mode,filename,sourceMap,breakLineCode,needIndent});generator.push(mode===`normal`?`function __msg__ (ctx) {`:`(ctx) => {`),generator.indent(needIndent),helpers.length>0&&(generator.push(`const { ${join(helpers.map(s=>`${s}: _${s}`),`, `)} } = ctx`),generator.newline()),generator.push(`return `),generateNode(generator,ast),generator.deindent(needIndent),generator.push(`}`),delete ast.helpers;let{code,map}=generator.context();return{ast,code,map:map?map.toJSON():void 0}};function baseCompile(source,options={}){let assignedOptions=assign$1({},options),jit=!!assignedOptions.jit,enalbeMinify=!!assignedOptions.minify,enambeOptimize=assignedOptions.optimize==null?!0:assignedOptions.optimize,ast=createParser(assignedOptions).parse(source);return jit?(enambeOptimize&&optimize(ast),enalbeMinify&&minify(ast),{ast,code:``}):(transform(ast,assignedOptions),generate(ast,assignedOptions))}function initFeatureFlags$1(){typeof __INTLIFY_PROD_DEVTOOLS__!=`boolean`&&(getGlobalThis().__INTLIFY_PROD_DEVTOOLS__=!1),typeof __INTLIFY_DROP_MESSAGE_COMPILER__!=`boolean`&&(getGlobalThis().__INTLIFY_DROP_MESSAGE_COMPILER__=!1)}function isMessageAST(val){return isObject(val)&&resolveType(val)===0&&(hasOwn(val,`b`)||hasOwn(val,`body`))}var PROPS_BODY=[`b`,`body`];function resolveBody(node){return resolveProps(node,PROPS_BODY)}var PROPS_CASES=[`c`,`cases`];function resolveCases(node){return resolveProps(node,PROPS_CASES,[])}var PROPS_STATIC=[`s`,`static`];function resolveStatic(node){return resolveProps(node,PROPS_STATIC)}var PROPS_ITEMS=[`i`,`items`];function resolveItems(node){return resolveProps(node,PROPS_ITEMS,[])}var PROPS_TYPE=[`t`,`type`];function resolveType(node){return resolveProps(node,PROPS_TYPE)}var PROPS_VALUE=[`v`,`value`];function resolveValue$1(node,type){let resolved=resolveProps(node,PROPS_VALUE);if(resolved!=null)return resolved;throw createUnhandleNodeError(type)}var PROPS_MODIFIER=[`m`,`modifier`];function resolveLinkedModifier(node){return resolveProps(node,PROPS_MODIFIER)}var PROPS_KEY=[`k`,`key`];function resolveLinkedKey(node){let resolved=resolveProps(node,PROPS_KEY);if(resolved)return resolved;throw createUnhandleNodeError(6)}function resolveProps(node,props,defaultValue){for(let i=0;iformatParts(ctx,ast)}function formatParts(ctx,ast){let body=resolveBody(ast);if(body==null)throw createUnhandleNodeError(0);if(resolveType(body)===1){let cases=resolveCases(body);return ctx.plural(cases.reduce((messages,c)=>[...messages,formatMessageParts(ctx,c)],[]))}else return formatMessageParts(ctx,body)}function formatMessageParts(ctx,node){let static_=resolveStatic(node);if(static_!=null)return ctx.type===`text`?static_:ctx.normalize([static_]);{let messages=resolveItems(node).reduce((acm,c)=>[...acm,formatMessagePart(ctx,c)],[]);return ctx.normalize(messages)}}function formatMessagePart(ctx,node){let type=resolveType(node);switch(type){case 3:return resolveValue$1(node,type);case 9:return resolveValue$1(node,type);case 4:{let named=node;if(hasOwn(named,`k`)&&named.k)return ctx.interpolate(ctx.named(named.k));if(hasOwn(named,`key`)&&named.key)return ctx.interpolate(ctx.named(named.key));throw createUnhandleNodeError(type)}case 5:{let list=node;if(hasOwn(list,`i`)&&isNumber(list.i))return ctx.interpolate(ctx.list(list.i));if(hasOwn(list,`index`)&&isNumber(list.index))return ctx.interpolate(ctx.list(list.index));throw createUnhandleNodeError(type)}case 6:{let linked=node,modifier=resolveLinkedModifier(linked),key=resolveLinkedKey(linked);return ctx.linked(formatMessagePart(ctx,key),modifier?formatMessagePart(ctx,modifier):void 0,ctx.type)}case 7:return resolveValue$1(node,type);case 8:return resolveValue$1(node,type);default:throw Error(`unhandled node on format message part: ${type}`)}}var defaultOnCacheKey=message=>message,compileCache=create();function baseCompile$1(message,options={}){let detectError=!1,onError=options.onError||defaultOnError;return options.onError=err=>{detectError=!0,onError(err)},{...baseCompile(message,options),detectError}}function compile(message,context){if(!__INTLIFY_DROP_MESSAGE_COMPILER__&&isString(message)){isBoolean(context.warnHtmlMessage)&&context.warnHtmlMessage;let cacheKey=(context.onCacheKey||defaultOnCacheKey)(message),cached=compileCache[cacheKey];if(cached)return cached;let{ast,detectError}=baseCompile$1(message,{...context,location:!1,jit:!0}),msg=format$1(ast);return detectError?msg:compileCache[cacheKey]=msg}else{let cacheKey=message.cacheKey;return cacheKey?compileCache[cacheKey]||(compileCache[cacheKey]=format$1(message)):format$1(message)}}var devtools=null;function setDevToolsHook(hook){devtools=hook}function initI18nDevTools(i18n,version$2,meta){devtools&&devtools.emit(`i18n:init`,{timestamp:Date.now(),i18n,version:version$2,meta})}var translateDevTools=createDevToolsHook(`function:translate`);function createDevToolsHook(hook){return payloads=>devtools&&devtools.emit(hook,payloads)}var CoreErrorCodes={INVALID_ARGUMENT:17,INVALID_DATE_ARGUMENT:18,INVALID_ISO_DATE_ARGUMENT:19,NOT_SUPPORT_NON_STRING_MESSAGE:20,NOT_SUPPORT_LOCALE_PROMISE_VALUE:21,NOT_SUPPORT_LOCALE_ASYNC_FUNCTION:22,NOT_SUPPORT_LOCALE_TYPE:23},CORE_ERROR_CODES_EXTEND_POINT=24;function createCoreError(code){return createCompileError(code,null,void 0)}CoreErrorCodes.INVALID_ARGUMENT,CoreErrorCodes.INVALID_DATE_ARGUMENT,CoreErrorCodes.INVALID_ISO_DATE_ARGUMENT,CoreErrorCodes.NOT_SUPPORT_NON_STRING_MESSAGE,CoreErrorCodes.NOT_SUPPORT_LOCALE_PROMISE_VALUE,CoreErrorCodes.NOT_SUPPORT_LOCALE_ASYNC_FUNCTION,CoreErrorCodes.NOT_SUPPORT_LOCALE_TYPE;function getLocale(context,options){return options.locale==null?resolveLocale(context.locale):resolveLocale(options.locale)}var _resolveLocale;function resolveLocale(locale){if(isString(locale))return locale;if(isFunction(locale)){if(locale.resolvedOnce&&_resolveLocale!=null)return _resolveLocale;if(locale.constructor.name===`Function`){let resolve$1=locale();if(isPromise(resolve$1))throw createCoreError(CoreErrorCodes.NOT_SUPPORT_LOCALE_PROMISE_VALUE);return _resolveLocale=resolve$1}else throw createCoreError(CoreErrorCodes.NOT_SUPPORT_LOCALE_ASYNC_FUNCTION)}else throw createCoreError(CoreErrorCodes.NOT_SUPPORT_LOCALE_TYPE)}function fallbackWithSimple(ctx,fallback,start){return[...new Set([start,...isArray$1(fallback)?fallback:isObject(fallback)?Object.keys(fallback):isString(fallback)?[fallback]:[start]])]}var pathStateMachine=[];pathStateMachine[0]={w:[0],i:[3,0],"[":[4],o:[7]},pathStateMachine[1]={w:[1],".":[2],"[":[4],o:[7]},pathStateMachine[2]={w:[2],i:[3,0],0:[3,0]},pathStateMachine[3]={i:[3,0],0:[3,0],w:[1,1],".":[2,1],"[":[4,1],o:[7,1]},pathStateMachine[4]={"'":[5,0],'"':[6,0],"[":[4,2],"]":[1,3],o:8,l:[4,0]},pathStateMachine[5]={"'":[4,0],o:8,l:[5,0]},pathStateMachine[6]={'"':[4,0],o:8,l:[6,0]};function resolveWithKeyValue(obj,path){return isObject(obj)?obj[path]:null}var CoreWarnCodes={NOT_FOUND_KEY:1,FALLBACK_TO_TRANSLATE:2,CANNOT_FORMAT_NUMBER:3,FALLBACK_TO_NUMBER_FORMAT:4,CANNOT_FORMAT_DATE:5,FALLBACK_TO_DATE_FORMAT:6,EXPERIMENTAL_CUSTOM_MESSAGE_COMPILER:7},CORE_WARN_CODES_EXTEND_POINT=8,warnMessages={[CoreWarnCodes.NOT_FOUND_KEY]:`Not found '{key}' key in '{locale}' locale messages.`,[CoreWarnCodes.FALLBACK_TO_TRANSLATE]:`Fall back to translate '{key}' key with '{target}' locale.`,[CoreWarnCodes.CANNOT_FORMAT_NUMBER]:`Cannot format a number value due to not supported Intl.NumberFormat.`,[CoreWarnCodes.FALLBACK_TO_NUMBER_FORMAT]:`Fall back to number format '{key}' key with '{target}' locale.`,[CoreWarnCodes.CANNOT_FORMAT_DATE]:`Cannot format a date value due to not supported Intl.DateTimeFormat.`,[CoreWarnCodes.FALLBACK_TO_DATE_FORMAT]:`Fall back to datetime format '{key}' key with '{target}' locale.`,[CoreWarnCodes.EXPERIMENTAL_CUSTOM_MESSAGE_COMPILER]:`This project is using Custom Message Compiler, which is an experimental feature. It may receive breaking changes or be removed in the future.`},VERSION$1=`11.1.12`,NOT_REOSLVED=-1,DEFAULT_LOCALE=`en-US`,capitalize=str=>`${str.charAt(0).toLocaleUpperCase()}${str.substr(1)}`;function getDefaultLinkedModifiers(){return{upper:(val,type)=>type===`text`&&isString(val)?val.toUpperCase():type===`vnode`&&isObject(val)&&`__v_isVNode`in val?val.children.toUpperCase():val,lower:(val,type)=>type===`text`&&isString(val)?val.toLowerCase():type===`vnode`&&isObject(val)&&`__v_isVNode`in val?val.children.toLowerCase():val,capitalize:(val,type)=>type===`text`&&isString(val)?capitalize(val):type===`vnode`&&isObject(val)&&`__v_isVNode`in val?capitalize(val.children):val}}var _compiler;function registerMessageCompiler(compiler){_compiler=compiler}var _resolver,_fallbacker,_additionalMeta=null,setAdditionalMeta=meta=>{_additionalMeta=meta},getAdditionalMeta=()=>_additionalMeta,_fallbackContext=null,setFallbackContext=context=>{_fallbackContext=context},getFallbackContext=()=>_fallbackContext,_cid=0;function createCoreContext(options={}){let onWarn=isFunction(options.onWarn)?options.onWarn:warn,version$2=isString(options.version)?options.version:VERSION$1,locale=isString(options.locale)||isFunction(options.locale)?options.locale:DEFAULT_LOCALE,_locale=isFunction(locale)?DEFAULT_LOCALE:locale,fallbackLocale=isArray$1(options.fallbackLocale)||isPlainObject(options.fallbackLocale)||isString(options.fallbackLocale)||options.fallbackLocale===!1?options.fallbackLocale:_locale,messages=isPlainObject(options.messages)?options.messages:createResources(_locale),datetimeFormats=isPlainObject(options.datetimeFormats)?options.datetimeFormats:createResources(_locale),numberFormats=isPlainObject(options.numberFormats)?options.numberFormats:createResources(_locale),modifiers=assign$1(create(),options.modifiers,getDefaultLinkedModifiers()),pluralRules=options.pluralRules||create(),missing=isFunction(options.missing)?options.missing:null,missingWarn=isBoolean(options.missingWarn)||isRegExp(options.missingWarn)?options.missingWarn:!0,fallbackWarn=isBoolean(options.fallbackWarn)||isRegExp(options.fallbackWarn)?options.fallbackWarn:!0,fallbackFormat=!!options.fallbackFormat,unresolving=!!options.unresolving,postTranslation=isFunction(options.postTranslation)?options.postTranslation:null,processor=isPlainObject(options.processor)?options.processor:null,warnHtmlMessage=isBoolean(options.warnHtmlMessage)?options.warnHtmlMessage:!0,escapeParameter=!!options.escapeParameter,messageCompiler=isFunction(options.messageCompiler)?options.messageCompiler:_compiler,messageResolver=isFunction(options.messageResolver)?options.messageResolver:_resolver||resolveWithKeyValue,localeFallbacker=isFunction(options.localeFallbacker)?options.localeFallbacker:_fallbacker||fallbackWithSimple,fallbackContext=isObject(options.fallbackContext)?options.fallbackContext:void 0,internalOptions=options,__datetimeFormatters=isObject(internalOptions.__datetimeFormatters)?internalOptions.__datetimeFormatters:new Map,__numberFormatters=isObject(internalOptions.__numberFormatters)?internalOptions.__numberFormatters:new Map,__meta=isObject(internalOptions.__meta)?internalOptions.__meta:{};_cid++;let context={version:version$2,cid:_cid,locale,fallbackLocale,messages,modifiers,pluralRules,missing,missingWarn,fallbackWarn,fallbackFormat,unresolving,postTranslation,processor,warnHtmlMessage,escapeParameter,messageCompiler,messageResolver,localeFallbacker,fallbackContext,onWarn,__meta};return context.datetimeFormats=datetimeFormats,context.numberFormats=numberFormats,context.__datetimeFormatters=__datetimeFormatters,context.__numberFormatters=__numberFormatters,__INTLIFY_PROD_DEVTOOLS__&&initI18nDevTools(context,version$2,__meta),context}var createResources=locale=>({[locale]:create()});function handleMissing(context,key,locale,missingWarn,type){let{missing,onWarn}=context;if(missing!==null){let ret=missing(context,locale,key,type);return isString(ret)?ret:key}else return key}function updateFallbackLocale(ctx,locale,fallback){let context=ctx;context.__localeChainCache=new Map,ctx.localeFallbacker(ctx,fallback,locale)}function isAlmostSameLocale(locale,compareLocale){return locale===compareLocale?!1:locale.split(`-`)[0]===compareLocale.split(`-`)[0]}function isImplicitFallback(targetLocale,locales){let index=locales.indexOf(targetLocale);if(index===-1)return!1;for(let i=index+1;istr,DEFAULT_MESSAGE=ctx=>``,DEFAULT_MESSAGE_DATA_TYPE=`text`,DEFAULT_NORMALIZE=values=>values.length===0?``:join(values),DEFAULT_INTERPOLATE=toDisplayString$1;function pluralDefault(choice,choicesLength){return choice=Math.abs(choice),choicesLength===2?choice?choice>1?1:0:1:choice?Math.min(choice,2):0}function getPluralIndex(options){let index=isNumber(options.pluralIndex)?options.pluralIndex:-1;return options.named&&(isNumber(options.named.count)||isNumber(options.named.n))?isNumber(options.named.count)?options.named.count:isNumber(options.named.n)?options.named.n:index:index}function normalizeNamed(pluralIndex,props){props.count||=pluralIndex,props.n||=pluralIndex}function createMessageContext(options={}){let locale=options.locale,pluralIndex=getPluralIndex(options),pluralRule=isObject(options.pluralRules)&&isString(locale)&&isFunction(options.pluralRules[locale])?options.pluralRules[locale]:pluralDefault,orgPluralRule=isObject(options.pluralRules)&&isString(locale)&&isFunction(options.pluralRules[locale])?pluralDefault:void 0,plural=messages=>messages[pluralRule(pluralIndex,messages.length,orgPluralRule)],_list=options.list||[],list=index=>_list[index],_named=options.named||create();isNumber(options.pluralIndex)&&normalizeNamed(pluralIndex,_named);let named=key=>_named[key];function message(key,useLinked){return(isFunction(options.messages)?options.messages(key,!!useLinked):isObject(options.messages)?options.messages[key]:!1)||(options.parent?options.parent.message(key):DEFAULT_MESSAGE)}let _modifier=name=>options.modifiers?options.modifiers[name]:DEFAULT_MODIFIER,normalize=isPlainObject(options.processor)&&isFunction(options.processor.normalize)?options.processor.normalize:DEFAULT_NORMALIZE,interpolate=isPlainObject(options.processor)&&isFunction(options.processor.interpolate)?options.processor.interpolate:DEFAULT_INTERPOLATE,ctx={list,named,plural,linked:(key,...args)=>{let[arg1,arg2]=args,type$1=`text`,modifier=``;args.length===1?isObject(arg1)?(modifier=arg1.modifier||modifier,type$1=arg1.type||type$1):isString(arg1)&&(modifier=arg1||modifier):args.length===2&&(isString(arg1)&&(modifier=arg1||modifier),isString(arg2)&&(type$1=arg2||type$1));let ret=message(key,!0)(ctx),msg=type$1===`vnode`&&isArray$1(ret)&&modifier?ret[0]:ret;return modifier?_modifier(modifier)(msg,type$1):msg},message,type:isPlainObject(options.processor)&&isString(options.processor.type)?options.processor.type:DEFAULT_MESSAGE_DATA_TYPE,interpolate,normalize,values:assign$1(create(),_list,_named)};return ctx}var NOOP_MESSAGE_FUNCTION=()=>``,isMessageFunction=val=>isFunction(val);function translate$1(context,...args){let{fallbackFormat,postTranslation,unresolving,messageCompiler,fallbackLocale,messages}=context,[key,options]=parseTranslateArgs(...args),missingWarn=isBoolean(options.missingWarn)?options.missingWarn:context.missingWarn,fallbackWarn=isBoolean(options.fallbackWarn)?options.fallbackWarn:context.fallbackWarn,escapeParameter=isBoolean(options.escapeParameter)?options.escapeParameter:context.escapeParameter,resolvedMessage=!!options.resolvedMessage,defaultMsgOrKey=isString(options.default)||isBoolean(options.default)?isBoolean(options.default)?messageCompiler?key:()=>key:options.default:fallbackFormat?messageCompiler?key:()=>key:null,enableDefaultMsg=fallbackFormat||defaultMsgOrKey!=null&&(isString(defaultMsgOrKey)||isFunction(defaultMsgOrKey)),locale=getLocale(context,options);escapeParameter&&escapeParams(options);let[formatScope,targetLocale,message]=resolvedMessage?[key,locale,messages[locale]||create()]:resolveMessageFormat(context,key,locale,fallbackLocale,fallbackWarn,missingWarn),format$2=formatScope,cacheBaseKey=key;if(!resolvedMessage&&!(isString(format$2)||isMessageAST(format$2)||isMessageFunction(format$2))&&enableDefaultMsg&&(format$2=defaultMsgOrKey,cacheBaseKey=format$2),!resolvedMessage&&(!(isString(format$2)||isMessageAST(format$2)||isMessageFunction(format$2))||!isString(targetLocale)))return unresolving?-1:key;let occurred=!1,msg=isMessageFunction(format$2)?format$2:compileMessageFormat(context,key,targetLocale,format$2,cacheBaseKey,()=>{occurred=!0});if(occurred)return format$2;let messaged=evaluateMessage(context,msg,createMessageContext(getMessageContextOptions(context,targetLocale,message,options))),ret=postTranslation?postTranslation(messaged,key):messaged;if(escapeParameter&&isString(ret)&&(ret=sanitizeTranslatedHtml(ret)),__INTLIFY_PROD_DEVTOOLS__){let payloads={timestamp:Date.now(),key:isString(key)?key:isMessageFunction(format$2)?format$2.key:``,locale:targetLocale||(isMessageFunction(format$2)?format$2.locale:``),format:isString(format$2)?format$2:isMessageFunction(format$2)?format$2.source:``,message:ret};payloads.meta=assign$1({},context.__meta,getAdditionalMeta()||{}),translateDevTools(payloads)}return ret}function escapeParams(options){isArray$1(options.list)?options.list=options.list.map(item=>isString(item)?escapeHtml(item):item):isObject(options.named)&&Object.keys(options.named).forEach(key=>{isString(options.named[key])&&(options.named[key]=escapeHtml(options.named[key]))})}function resolveMessageFormat(context,key,locale,fallbackLocale,fallbackWarn,missingWarn){let{messages,onWarn,messageResolver:resolveValue,localeFallbacker}=context,locales=localeFallbacker(context,fallbackLocale,locale),message=create(),targetLocale,format$2=null,type=`translate`;for(let i=0;iformat$2);return msg$1.locale=targetLocale,msg$1.key=key,msg$1}let msg=messageCompiler(format$2,getCompileContext(context,targetLocale,cacheBaseKey,format$2,warnHtmlMessage,onError));return msg.locale=targetLocale,msg.key=key,msg.source=format$2,msg}function evaluateMessage(context,msg,msgCtx){return msg(msgCtx)}function parseTranslateArgs(...args){let[arg1,arg2,arg3]=args,options=create();if(!isString(arg1)&&!isNumber(arg1)&&!isMessageFunction(arg1)&&!isMessageAST(arg1))throw createCoreError(CoreErrorCodes.INVALID_ARGUMENT);let key=isNumber(arg1)?String(arg1):(isMessageFunction(arg1),arg1);return isNumber(arg2)?options.plural=arg2:isString(arg2)?options.default=arg2:isPlainObject(arg2)&&!isEmptyObject(arg2)?options.named=arg2:isArray$1(arg2)&&(options.list=arg2),isNumber(arg3)?options.plural=arg3:isString(arg3)?options.default=arg3:isPlainObject(arg3)&&assign$1(options,arg3),[key,options]}function getCompileContext(context,locale,key,source,warnHtmlMessage,onError){return{locale,key,warnHtmlMessage,onError:err=>{throw onError&&onError(err),err},onCacheKey:source$1=>generateFormatCacheKey(locale,key,source$1)}}function getMessageContextOptions(context,locale,message,options){let{modifiers,pluralRules,messageResolver:resolveValue,fallbackLocale,fallbackWarn,missingWarn,fallbackContext}=context,ctxOptions={locale,modifiers,pluralRules,messages:(key,useLinked)=>{let val=resolveValue(message,key);if(val==null&&(fallbackContext||useLinked)){let[,,message$1]=resolveMessageFormat(fallbackContext||context,key,locale,fallbackLocale,fallbackWarn,missingWarn);val=resolveValue(message$1,key)}if(isString(val)||isMessageAST(val)){let occurred=!1,msg=compileMessageFormat(context,key,locale,val,key,()=>{occurred=!0});return occurred?NOOP_MESSAGE_FUNCTION:msg}else if(isMessageFunction(val))return val;else return NOOP_MESSAGE_FUNCTION}};return context.processor&&(ctxOptions.processor=context.processor),options.list&&(ctxOptions.list=options.list),options.named&&(ctxOptions.named=options.named),isNumber(options.plural)&&(ctxOptions.pluralIndex=options.plural),ctxOptions}initFeatureFlags$1();var VERSION=`11.1.12`;function initFeatureFlags(){typeof __VUE_I18N_FULL_INSTALL__!=`boolean`&&(getGlobalThis().__VUE_I18N_FULL_INSTALL__=!0),typeof __VUE_I18N_LEGACY_API__!=`boolean`&&(getGlobalThis().__VUE_I18N_LEGACY_API__=!0),typeof __INTLIFY_DROP_MESSAGE_COMPILER__!=`boolean`&&(getGlobalThis().__INTLIFY_DROP_MESSAGE_COMPILER__=!1),typeof __INTLIFY_PROD_DEVTOOLS__!=`boolean`&&(getGlobalThis().__INTLIFY_PROD_DEVTOOLS__=!1)}var I18nErrorCodes={UNEXPECTED_RETURN_TYPE:24,INVALID_ARGUMENT:25,MUST_BE_CALL_SETUP_TOP:26,NOT_INSTALLED:27,REQUIRED_VALUE:28,INVALID_VALUE:29,CANNOT_SETUP_VUE_DEVTOOLS_PLUGIN:30,NOT_INSTALLED_WITH_PROVIDE:31,UNEXPECTED_ERROR:32,NOT_COMPATIBLE_LEGACY_VUE_I18N:33,NOT_AVAILABLE_COMPOSITION_IN_LEGACY:34};function createI18nError(code,...args){return createCompileError(code,null,void 0)}I18nErrorCodes.UNEXPECTED_RETURN_TYPE,I18nErrorCodes.INVALID_ARGUMENT,I18nErrorCodes.MUST_BE_CALL_SETUP_TOP,I18nErrorCodes.NOT_INSTALLED,I18nErrorCodes.UNEXPECTED_ERROR,I18nErrorCodes.REQUIRED_VALUE,I18nErrorCodes.INVALID_VALUE,I18nErrorCodes.CANNOT_SETUP_VUE_DEVTOOLS_PLUGIN,I18nErrorCodes.NOT_INSTALLED_WITH_PROVIDE,I18nErrorCodes.NOT_COMPATIBLE_LEGACY_VUE_I18N,I18nErrorCodes.NOT_AVAILABLE_COMPOSITION_IN_LEGACY;var SetPluralRulesSymbol=makeSymbol(`__setPluralRules`);makeSymbol(`__intlifyMeta`);var I18nWarnCodes={FALLBACK_TO_ROOT:8,NOT_FOUND_PARENT_SCOPE:9,IGNORE_OBJ_FLATTEN:10,DEPRECATE_LEGACY_MODE:11,DEPRECATE_TRANSLATE_CUSTOME_DIRECTIVE:12,DUPLICATE_USE_I18N_CALLING:13};I18nWarnCodes.FALLBACK_TO_ROOT,I18nWarnCodes.NOT_FOUND_PARENT_SCOPE,I18nWarnCodes.IGNORE_OBJ_FLATTEN,I18nWarnCodes.DEPRECATE_LEGACY_MODE,I18nWarnCodes.DEPRECATE_TRANSLATE_CUSTOME_DIRECTIVE,I18nWarnCodes.DUPLICATE_USE_I18N_CALLING;function handleFlatJson(obj){if(!isObject(obj)||isMessageAST(obj))return obj;for(let key in obj)if(hasOwn(obj,key))if(!key.includes(`.`))isObject(obj[key])&&handleFlatJson(obj[key]);else{let subKeys=key.split(`.`),lastIndex=subKeys.length-1,currentObj=obj,hasStringValue=!1;for(let i=0;i{if(`locale`in custom&&`resource`in custom){let{locale:locale$1,resource}=custom;locale$1?(ret[locale$1]=ret[locale$1]||create(),deepCopy(resource,ret[locale$1])):deepCopy(resource,ret)}else isString(custom)&&deepCopy(JSON.parse(custom),ret)}),messageResolver==null&&flatJson)for(let key in ret)hasOwn(ret,key)&&handleFlatJson(ret[key]);return ret}function getComponentOptions(instance$1){return instance$1.type}var DEVTOOLS_META=`__INTLIFY_META__`,composerID=0;function defineCoreMissingHandler(missing){return((ctx,locale,key,type)=>missing(locale,key,getCurrentInstance()||void 0,type))}var getMetaInfo=()=>{let instance$1=getCurrentInstance(),meta=null;return instance$1&&(meta=getComponentOptions(instance$1)[DEVTOOLS_META])?{[DEVTOOLS_META]:meta}:null};function createComposer(options={}){let{__root,__injectWithOption}=options,_isGlobal=__root===void 0,flatJson=options.flatJson,_ref=inBrowser?ref:shallowRef,_inheritLocale=isBoolean(options.inheritLocale)?options.inheritLocale:!0,_locale=_ref(__root&&_inheritLocale?__root.locale.value:isString(options.locale)?options.locale:DEFAULT_LOCALE),_fallbackLocale=_ref(__root&&_inheritLocale?__root.fallbackLocale.value:isString(options.fallbackLocale)||isArray$1(options.fallbackLocale)||isPlainObject(options.fallbackLocale)||options.fallbackLocale===!1?options.fallbackLocale:_locale.value),_messages=_ref(getLocaleMessages(_locale.value,options)),_missingWarn=__root?__root.missingWarn:isBoolean(options.missingWarn)||isRegExp(options.missingWarn)?options.missingWarn:!0,_fallbackWarn=__root?__root.fallbackWarn:isBoolean(options.fallbackWarn)||isRegExp(options.fallbackWarn)?options.fallbackWarn:!0,_fallbackRoot=__root?__root.fallbackRoot:isBoolean(options.fallbackRoot)?options.fallbackRoot:!0,_fallbackFormat=!!options.fallbackFormat,_missing=isFunction(options.missing)?options.missing:null,_runtimeMissing=isFunction(options.missing)?defineCoreMissingHandler(options.missing):null,_postTranslation=isFunction(options.postTranslation)?options.postTranslation:null,_warnHtmlMessage=__root?__root.warnHtmlMessage:isBoolean(options.warnHtmlMessage)?options.warnHtmlMessage:!0,_escapeParameter=!!options.escapeParameter,_modifiers=__root?__root.modifiers:isPlainObject(options.modifiers)?options.modifiers:{},_pluralRules=options.pluralRules||__root&&__root.pluralRules,_context;_context=(()=>{_isGlobal&&setFallbackContext(null);let ctx=createCoreContext({version:VERSION,locale:_locale.value,fallbackLocale:_fallbackLocale.value,messages:_messages.value,modifiers:_modifiers,pluralRules:_pluralRules,missing:_runtimeMissing===null?void 0:_runtimeMissing,missingWarn:_missingWarn,fallbackWarn:_fallbackWarn,fallbackFormat:_fallbackFormat,unresolving:!0,postTranslation:_postTranslation===null?void 0:_postTranslation,warnHtmlMessage:_warnHtmlMessage,escapeParameter:_escapeParameter,messageResolver:options.messageResolver,messageCompiler:options.messageCompiler,__meta:{framework:`vue`}});return _isGlobal&&setFallbackContext(ctx),ctx})(),updateFallbackLocale(_context,_locale.value,_fallbackLocale.value);function trackReactivityValues(){return[_locale.value,_fallbackLocale.value,_messages.value]}let locale=computed({get:()=>_locale.value,set:val=>{_context.locale=val,_locale.value=val}}),fallbackLocale=computed({get:()=>_fallbackLocale.value,set:val=>{_context.fallbackLocale=val,_fallbackLocale.value=val,updateFallbackLocale(_context,_locale.value,val)}}),messages=computed(()=>_messages.value);function getPostTranslationHandler(){return isFunction(_postTranslation)?_postTranslation:null}function setPostTranslationHandler(handler$1){_postTranslation=handler$1,_context.postTranslation=handler$1}function getMissingHandler(){return _missing}function setMissingHandler(handler$1){handler$1!==null&&(_runtimeMissing=defineCoreMissingHandler(handler$1)),_missing=handler$1,_context.missing=_runtimeMissing}let wrapWithDeps=(fn,argumentParser,warnType,fallbackSuccess,fallbackFail,successCondition)=>{trackReactivityValues();let ret;try{__INTLIFY_PROD_DEVTOOLS__,_isGlobal||(_context.fallbackContext=__root?getFallbackContext():void 0),ret=fn(_context)}finally{__INTLIFY_PROD_DEVTOOLS__,_isGlobal||(_context.fallbackContext=void 0)}if(isNumber(ret)&&ret===-1||warnType===`translate exists`){let[key,arg2]=argumentParser();return __root&&_fallbackRoot?fallbackSuccess(__root):fallbackFail(key)}else if(successCondition(ret))return ret;else throw createI18nError(I18nErrorCodes.UNEXPECTED_RETURN_TYPE)};function t(...args){return wrapWithDeps(context=>Reflect.apply(translate$1,null,[context,...args]),()=>parseTranslateArgs(...args),`translate`,root=>Reflect.apply(root.t,root,[...args]),key=>key,val=>isString(val))}function setPluralRules(rules){_pluralRules=rules,_context.pluralRules=_pluralRules}function getLocaleMessage(locale$1){return _messages.value[locale$1]||{}}function setLocaleMessage(locale$1,message){if(flatJson){let _message={[locale$1]:message};for(let key in _message)hasOwn(_message,key)&&handleFlatJson(_message[key]);message=_message[locale$1]}_messages.value[locale$1]=message,_context.messages=_messages.value}function mergeLocaleMessage(locale$1,message){_messages.value[locale$1]=_messages.value[locale$1]||{};let _message={[locale$1]:message};if(flatJson)for(let key in _message)hasOwn(_message,key)&&handleFlatJson(_message[key]);message=_message[locale$1],deepCopy(message,_messages.value[locale$1]),_context.messages=_messages.value}return composerID++,__root&&inBrowser&&(watch(__root.locale,val=>{_inheritLocale&&(_locale.value=val,_context.locale=val,updateFallbackLocale(_context,_locale.value,_fallbackLocale.value))}),watch(__root.fallbackLocale,val=>{_inheritLocale&&(_fallbackLocale.value=val,_context.fallbackLocale=val,updateFallbackLocale(_context,_locale.value,_fallbackLocale.value))})),{id:composerID,locale,fallbackLocale,get inheritLocale(){return _inheritLocale},set inheritLocale(val){_inheritLocale=val,val&&__root&&(_locale.value=__root.locale.value,_fallbackLocale.value=__root.fallbackLocale.value,updateFallbackLocale(_context,_locale.value,_fallbackLocale.value))},get availableLocales(){return Object.keys(_messages.value).sort()},messages,get modifiers(){return _modifiers},get pluralRules(){return _pluralRules||{}},get isGlobal(){return _isGlobal},get missingWarn(){return _missingWarn},set missingWarn(val){_missingWarn=val,_context.missingWarn=_missingWarn},get fallbackWarn(){return _fallbackWarn},set fallbackWarn(val){_fallbackWarn=val,_context.fallbackWarn=_fallbackWarn},get fallbackRoot(){return _fallbackRoot},set fallbackRoot(val){_fallbackRoot=val},get fallbackFormat(){return _fallbackFormat},set fallbackFormat(val){_fallbackFormat=val,_context.fallbackFormat=_fallbackFormat},get warnHtmlMessage(){return _warnHtmlMessage},set warnHtmlMessage(val){_warnHtmlMessage=val,_context.warnHtmlMessage=val},get escapeParameter(){return _escapeParameter},set escapeParameter(val){_escapeParameter=val,_context.escapeParameter=val},t,getLocaleMessage,setLocaleMessage,mergeLocaleMessage,getPostTranslationHandler,setPostTranslationHandler,getMissingHandler,setMissingHandler,[SetPluralRulesSymbol]:setPluralRules}}function createI18n(options={}){let __globalInjection=isBoolean(options.globalInjection)?options.globalInjection:!0,__instances=new Map,[globalScope,__global]=createGlobal(options),symbol=makeSymbol(``);function __getInstance(component){return __instances.get(component)||null}function __setInstance(component,instance$1){__instances.set(component,instance$1)}function __deleteInstance(component){__instances.delete(component)}let i18n={get mode(){return`composition`},async install(app$1,...options$1){if(app$1.__VUE_I18N_SYMBOL__=symbol,app$1.provide(app$1.__VUE_I18N_SYMBOL__,i18n),isPlainObject(options$1[0])){let opts=options$1[0];i18n.__composerExtend=opts.__composerExtend,i18n.__vueI18nExtend=opts.__vueI18nExtend}let globalReleaseHandler=null;__globalInjection&&(globalReleaseHandler=injectGlobalFields(app$1,i18n.global));let unmountApp=app$1.unmount;app$1.unmount=()=>{globalReleaseHandler&&globalReleaseHandler(),i18n.dispose(),unmountApp()}},get global(){return __global},dispose(){globalScope.stop()},__instances,__getInstance,__setInstance,__deleteInstance};return i18n}function createGlobal(options,legacyMode){let scope$1=effectScope(),obj=scope$1.run(()=>createComposer(options));if(obj==null)throw createI18nError(I18nErrorCodes.UNEXPECTED_ERROR);return[scope$1,obj]}var globalExportProps=[`locale`,`fallbackLocale`,`availableLocales`],globalExportMethods=[`t`];function injectGlobalFields(app$1,composer){let i18n=Object.create(null);return globalExportProps.forEach(prop=>{let desc=Object.getOwnPropertyDescriptor(composer,prop);if(!desc)throw createI18nError(I18nErrorCodes.UNEXPECTED_ERROR);let wrap=isRef(desc.value)?{get(){return desc.value.value},set(val){desc.value.value=val}}:{get(){return desc.get&&desc.get()}};Object.defineProperty(i18n,prop,wrap)}),app$1.config.globalProperties.$i18n=i18n,globalExportMethods.forEach(method=>{let desc=Object.getOwnPropertyDescriptor(composer,method);if(!desc||!desc.value)throw createI18nError(I18nErrorCodes.UNEXPECTED_ERROR);Object.defineProperty(app$1.config.globalProperties,`$${method}`,desc)}),()=>{delete app$1.config.globalProperties.$i18n,globalExportMethods.forEach(method=>{delete app$1.config.globalProperties[`$${method}`]})}}if(initFeatureFlags(),registerMessageCompiler(compile),__INTLIFY_PROD_DEVTOOLS__){let target=getGlobalThis();target.__INTLIFY__=!0,setDevToolsHook(target.__INTLIFY_DEVTOOLS_GLOBAL_HOOK__)}const emptyImage=`data:image/svg+xml,`;function getURL(path){return typeof path!=`string`||!path||path.includes(`://`)?path:(path.startsWith(`/`)&&(path=path.substring(1)),`/${path}`)}function getAssetURL(assetPath){let url=getURL(assetPath);return typeof url!=`string`||!url||url.startsWith(`/`)&&(url=`/ui/ui-vue/src/assets`+url),url}const getFile=(url,timeout=5)=>new Promise((resolve$1,reject)=>{try{let xhr=new XMLHttpRequest,tmr=timeout>0?setTimeout(()=>{xhr.abort(),reject(Error(`Timeout`))},timeout*1e3):null;xhr.open(`GET`,url,!0),xhr.onload=()=>{tmr&&clearTimeout(tmr),xhr.status===200?resolve$1(xhr.responseText):reject(Error(`Failed with code ${xhr.status}`))},xhr.send()}catch(err){reject(err)}}),ucaseFirst=str=>str[0].toUpperCase()+str.slice(1),defer=()=>{let noop$3=()=>{},resolve$1,reject,_notifyHandler=noop$3,promise=new Promise((res,rej)=>{[resolve$1,reject]=[res,rej]});return{promise:{then:(resolveHandler,rejectHandler=noop$3,notifyHandler=noop$3)=>(_notifyHandler=notifyHandler,promise.then(resolveHandler,rejectHandler))},resolve:resolve$1,reject,notify:val=>_notifyHandler(val)}},sleep=ms=>new Promise(resolve$1=>setTimeout(resolve$1,ms)),debounce=(func,wait,immediate)=>{let timeout;function call(...args){let context=this,later=()=>{timeout=null,immediate||func.apply(context,args)},callNow=immediate&&!timeout;timeout&&window.clearTimeout(timeout),timeout=window.setTimeout(later,wait),callNow&&func.apply(context,args)}return call.cancel=()=>timeout&&window.clearTimeout(timeout),call};var Settings=class{options=reactive({});values=reactive({});_previousValues={};_changedValues={};_watcher=null;_syncPending=!1;inited=!1;loaded=!1;_lua;constructor(eventBus$1=void 0,lua=void 0){eventBus$1&&lua&&this.init(eventBus$1,lua)}init(eventBus$1=void 0,lua=void 0){if(!(this.inited||this.loaded)){if(this.inited=!0,!eventBus$1||!lua){let bridge$4=useBridge();eventBus$1||=bridge$4.events,lua||=bridge$4.lua}eventBus$1.on(`SettingsChanged`,data=>{Object.assign(this.options,data.options),Object.assign(this.values,data.values),this._previousValues=this.clone(data.values),this._changedValues={},this._watcher||=watch(()=>this.values,()=>this._syncChanges(),{deep:!0,flush:`sync`}),this.loaded=!0}),this._syncChangesDebounced=debounce(this._syncChangesImmediate,100),this._lua=lua,this.update()}}async waitForData(){for(;!this.inited||!this.loaded;)await sleep(10)}async update(){if(this._lua)return await this._lua.settings.notifyUI()}clone(data){return JSON.parse(JSON.stringify(data))}getValue(field=null){if(this.loaded)return field&&!(field in this.values)?null:this.clone(field?this.values[field]:this.values)}get changesPending(){return this._syncChangesImmediate(),Object.keys(this._changedValues).length>0}get pendingChanges(){return this._syncChangesImmediate(),this.clone(this._changedValues)}_syncChanges(){this._syncPending=!0,this._syncChangesDebounced()}_syncChangesDebounced=()=>{};_syncChangesImmediate(){if(this._syncPending)for(let key in this._syncPending=!1,this.values)this._previousValues[key]===this.values[key]?key in this._changedValues&&delete this._changedValues[key]:this._changedValues[key]=this.values[key]}async apply(values=void 0){if(!this.loaded)return;let res;if(values)res=this.clone(values);else{if(!this.changesPending)return;res={...this._changedValues},this._changedValues={}}return Object.assign(this._previousValues,res),await this._lua.settings.setState(res)}},settings=new Settings;function useSettings(){return settings.init(),settings}async function useSettingsAsync(){return settings.init(),await settings.waitForData(),settings}var ANGULAR_TRANSLATE=[],_angularTranslateFunc,_i18n,i18nVariant=`petite`,defaultLocale=`en-US`,localeCheckId=`ui.common.okay`,checkLocale=()=>_i18n&&_i18n.global.t(localeCheckId)!==localeCheckId,translate=val=>val;const initTranslation=()=>{if(window.vueI18n?.__bng_i18n_variant!==i18nVariant){window.vueI18n&&console.warn(`Localisation library is already initialized, but its variant was not validated. Reloading...`);let creationArguments={locale:defaultLocale,fallbackLocale:defaultLocale,silentTranslationWarn:!0,fallbackWarn:!1,missingWarn:!1,warnHtmlMessage:!1};window.beamng&&!window.beamng.shipping&&(creationArguments.fallbackLocale=[defaultLocale,`not-shipping.internal`]),window.vueI18n=createI18n(creationArguments),window.vueI18n.__bng_i18n_variant=i18nVariant}return _i18n=window.vueI18n,{i18n:_i18n,plugin:translationPlugin}},loadLocale=async(locale,force=!1)=>{if(!(_i18n.global.availableLocales.includes(locale)&&!force))try{let url=getURL(`/locales/${locale}.json`),resp;try{resp=await getFile(url,5)}catch(err){if(err.message!==`Timeout`)throw err;console.warn(`Locale ${locale} load timed out, retrying with a bigger timeout...`),resp=await getFile(url,10)}_i18n.global.setLocaleMessage(locale,preprocessLocaleJSON(JSON.parse(resp)))}catch(err){console.error(`Failed to load ${locale} locale`,err)}};var setupUserLanguage=async()=>{let settings$1=await useSettingsAsync();watch(()=>settings$1.values.uiLanguage,async lang=>{lang&&lang!==defaultLocale&&await loadLocale(lang),_i18n.global.locale.value=_i18n.global.availableLocales.includes(lang)?lang:defaultLocale,lang!==defaultLocale&&!checkLocale()&&console.warn(`Locale ${lang} is not behaving properly`)},{immediate:!0})};const translationPlugin=()=>({install(app$1,options){return _i18n.global.locale.value=defaultLocale,loadLocale(defaultLocale,!0).then(async()=>{checkLocale()||(console.warn(`Failed to load default locale, retrying...`),await loadLocale(defaultLocale,!0),checkLocale()||console.error(`Failed to load default locale!`)),await setupUserLanguage()}),contextTranslatePlugin().install(app$1,options)}}),contextTranslatePlugin=()=>({install(app$1,options){translate=_wrapTranslate(app$1.config.globalProperties.$t||_i18n.global.t),app$1.config.globalProperties.$t=_i18n.global.t,app$1.config.globalProperties.$ctx_t=(val,translateContext=!0)=>contextTranslate(val,translateContext),app$1.config.globalProperties.$mctx_t=multiContextTranslate,app$1.config.globalProperties.$tt=translate}});var contextTranslate=(val,translateContext=!1)=>{let type=typeof val;if(type===`undefined`||val===null)return``;if(type===`object`)if(val.txt&&val.context){let context=val.context;if(translateContext)for(let key in context={...context},context)context[key]=contextTranslate(context[key],!0);return getTranslation(val.txt,context)}else val=val.txt||``;return getTranslation(``+val)},multiContextTranslate=val=>{if(val.txt)return contextTranslate(val);let description=``;for(let i of val)description+=contextTranslate(i);return description},getAngularTranslationFunc=()=>_angularTranslateFunc||(window.angular$translate&&(_angularTranslateFunc=window.angular$translate.instant.bind(window.angular$translate)),_angularTranslateFunc||translate),getTranslation=(...vals)=>(ANGULAR_TRANSLATE.includes(vals[0])?getAngularTranslationFunc():translate)(...vals);const $translate={instant:val=>val===void 0?``:translate(val),contextTranslate,multiContextTranslate};var rgxAngular=/{{.+}}/,rgxAngularTranslation=/([^ ]?){{ *(?::: *)?'([^ |}]+)' *\| *translate *}}([^\w]?)/gi;function translateAngularToVue(text){let vueText=text.replace(rgxAngularTranslation,(_,q1,s,q2)=>(q1?`${q1} `:``)+`@:${s}`+(q2?` ${q2}`:``));return vueText=vueText.replace(/{{ *([a-z\d_.]+) *}}/gi,`{$1}`),vueText===text||rgxAngular.test(vueText)?null:vueText}const preprocessLocaleJSON=obj=>{let messages={};for(let key in obj){if(ANGULAR_TRANSLATE.includes(key))continue;let text=obj[key];if(rgxAngular.test(text)){let vueText=translateAngularToVue(text);vueText?messages[key]=vueText:ANGULAR_TRANSLATE.includes(key)||ANGULAR_TRANSLATE.push(key)}else messages[key]=text}return messages};var rgxLinkedTranslation=/@:([a-zA-Z0-9_][a-zA-Z0-9_.-]+[a-zA-Z0-9_])/g,linkedNamespace=`__linked_custom`;function _linkedTranslation(msg){if(!msg.includes(`@:`)||!rgxLinkedTranslation.test(msg))return msg;let locale=_i18n.global.locale.value,messages=_i18n.global.messages.value[locale];msg=msg.replace(rgxLinkedTranslation,(_,id)=>`@:`+id);let uniqueId$1=``,match;for(rgxLinkedTranslation.lastIndex=0;(match=rgxLinkedTranslation.exec(msg))!==null;)uniqueId$1+=match[1].replace(/\./g,`_`)+`__`;let fullId,messageId,counter$1=0;for(;counter$1<100;){messageId=uniqueId$1+ ++counter$1,fullId=linkedNamespace+`.`+messageId;let existingMessage=messages[fullId];if(!existingMessage){_i18n.global.mergeLocaleMessage(locale,{[fullId]:msg});break}if(existingMessage===msg)break}return fullId}function _wrapTranslate(f){function translate$2(...args){let key=args[0];return key?typeof key!=`string`||(key=_linkedTranslation(key),key.includes(` `))?key:f.apply(this,[key,...args.slice(1)]):``}return Object.defineProperty(translate$2,`name`,{value:f.name}),translate$2}const UI_NAV_ACTION_GROUP=`UINavActions`,GAME_UI_NAVIGATION_EVENT=`UINavigation`,GAME_UI_NAV_MAP_ENABLED_EVENT=`MenuActionMapEnabled`,DOM_UI_NAVIGATION_EVENT=`ui_nav`,ACTIONS_BY_UI_EVENT={focus_u:`menu_item_up`,focus_r:`menu_item_right`,focus_d:`menu_item_down`,focus_l:`menu_item_left`,menu:`toggleMenues`,back:`menu_item_back`,details:`cui_details`,advanced:`cui_advanced`,camera:`cui_camera`,logs:`cui_logs`,tab_l:`menu_tab_left`,tab_r:`menu_tab_right`,modifier:`cui_modifier`,action_4:`cui_action_4`,focus_ud:`menu_item_focus_ud`,focus_lr:`menu_item_focus_lr`,rotate_h_cam:`menu_item_radial_right_x`,rotate_v_cam:`menu_item_radial_right_y`,ok:`menu_item_select`,cancel:`cui_cancel`,action_2:`cui_action_2`,action_3:`cui_action_3`,context:`cui_context`,gameplay_interact:`cui_gameplay_interact`},UI_EVENTS_BY_ACTION=Object.assign({},...Object.entries(ACTIONS_BY_UI_EVENT).map(([k,v])=>({[v]:k}))),UI_EVENTS={focus_u:`focus_u`,focus_r:`focus_r`,focus_d:`focus_d`,focus_l:`focus_l`,pause:`pause`,menu:`menu`,back:`back`,details:`details`,advanced:`advanced`,camera:`camera`,logs:`logs`,tab_l:`tab_l`,tab_r:`tab_r`,modifier:`modifier`,zoom_out:`zoom_out`,zoom_in:`zoom_in`,subtab_l:`subtab_l`,subtab_r:`subtab_r`,center_cam:`center_cam`,action_4:`action_4`,move_ud:`move_ud`,move_lr:`move_lr`,focus_ud:`focus_ud`,focus_lr:`focus_lr`,rotate_h_cam:`rotate_h_cam`,rotate_v_cam:`rotate_v_cam`,ok:`ok`,cancel:`cancel`,action_2:`action_2`,action_3:`action_3`,context:`context`,gameplay_interact:`gameplay_interact`},UI_EVENT_GROUPS={focusMove:[UI_EVENTS.focus_u,UI_EVENTS.focus_d,UI_EVENTS.focus_l,UI_EVENTS.focus_r],focusMoveScalar:[UI_EVENTS.focus_ud,UI_EVENTS.focus_lr],moveScalar:[UI_EVENTS.move_ud,UI_EVENTS.move_lr],navigation:[UI_EVENTS.focus_u,UI_EVENTS.focus_d,UI_EVENTS.focus_l,UI_EVENTS.focus_r,UI_EVENTS.focus_ud,UI_EVENTS.focus_lr,UI_EVENTS.move_ud,UI_EVENTS.move_lr],allEvents:Object.keys(ACTIONS_BY_UI_EVENT)},NAV_ACTIONS=[`focus_u`,`focus_d`,`focus_l`,`focus_r`],VALUE_BASED_EVENTS=[`zoom_out`,`zoom_in`,`subtab_l`,`subtab_r`,`move_ud`,`move_lr`,`focus_ud`,`focus_lr`,`rotate_h_cam`,`rotate_v_cam`],UI_SCOPE_ATTR$2=`bng-ui-scope`,UI_EVENT_ATTR=`ui-nav-event`;var UINavEventProcessor=class{constructor(){this.isModified=!1}processEvent(name,value=void 0,extras=[],context={}){return!this.isValidGameContext()||context.isEventBlocked&&context.isEventBlocked(name)?null:(this.handleModifierState(name,value),this.shouldHandleWithAngular(name,value)?(this.handleAngularIntegration(),null):this.createEventData(name,value,extras))}isValidGameContext(){return window.beamng?.ingame}handleModifierState(name,value){name===`modifier`&&(this.isModified=value===1)}shouldHandleWithAngular(name,value){return window.globalAngularRootScope&&window.bngIntroShown&&(name===`menu`||name===`back`)&&value===1}handleAngularIntegration(){window.globalAngularRootScope.$broadcast(`MenuToggle`)}createEventData(name,value,extras){let activeElement=document.activeElement,targetScope=null;if(activeElement&&activeElement!==document.body){let scopeElement=activeElement.closest(`[${UI_SCOPE_ATTR$2}]`);scopeElement&&(targetScope=scopeElement.getAttribute(UI_SCOPE_ATTR$2))}return{name,value,modified:name!==`modifier`&&this.isModified,extras,boundAction:ACTIONS_BY_UI_EVENT[name],sendToCrossfire:!0,targetScope}}getEventBroadcastElement(activeScope){let activeElement=document.activeElement;if(activeElement&&activeElement!==document.body)return activeElement;if(activeScope){let scopeElement=document.querySelector(`[${UI_SCOPE_ATTR$2}="${activeScope}"]`);if(scopeElement)return scopeElement}return document.body}},UINavActionHandlers=class{constructor(eventBus$1=null){this._useCrossfire=!0,this.eventBus=eventBus$1}setUseCrossfire(enabled){this._useCrossfire=enabled}get useCrossfire(){return this._useCrossfire}setEventBus(eventBus$1){this.eventBus=eventBus$1}handleGlobalEvent=event=>{let eventData=event.detail;eventData.value===1&&(this.handleMenuActions(eventData)||this.handleNavigationActions(eventData)||this.handleGameActions(eventData))||(this.useCrossfire&&eventData.sendToCrossfire&&handleUINavEvent(event),event.defaultPrevented||(this.handleTabNavigation(eventData),this.handleCameraRotation(eventData),this.handleContextActions(eventData)))};handleMenuActions=eventData=>{if(eventData.name===`menu`||eventData.name===`back`){let globalAngularRootScope=window.globalAngularRootScope;return globalAngularRootScope?(globalAngularRootScope.$broadcast(`MenuToggle`),!1):!0}return!1};handleNavigationActions(eventData){if(NAV_ACTIONS.includes(eventData.name)){Lua_default.extensions.hook(`onMenuItemNavigation`);return}return!1}handleGameActions(eventData){switch(eventData.name){case`pause`:return Lua_default.simTimeAuthority.togglePause(),!0;case`center_cam`:return runRaw(`if core_camera then core_camera.resetCamera(${eventData.extras.player}) end`,!1),!0;default:return!1}}handleTabNavigation(eventData){if(eventData.value===1)switch(eventData.name){case`tab_l`:this.eventBus.emit(`ui_topBar_selectPrevious`);break;case`tab_r`:this.eventBus.emit(`ui_topBar_selectNext`);break}}handleCameraRotation(eventData){if(eventData.name===`rotate_h_cam`||eventData.name===`rotate_v_cam`){let camDir=eventData.name===`rotate_v_cam`?`pitch`:`yaw`,[filterType]=eventData.extras||[0];runRaw(`if core_camera then core_camera.rotate_${camDir}(${eventData.value}, ${filterType}) end`,!1)}}handleContextActions(eventData){[`context`,`details`,`camera`].includes(eventData.name)&&eventData.value===1&&this.isBigMapContext()&&runRaw(`if freeroam_bigMapMode then freeroam_bigMapMode.toggleBigMap() end`,!1)}isBigMapContext(){return[`#/bigmap`,`#/menu.bigmap`,`#/play`,`#/menu/bigmap`].includes(window.location.hash)}},UINavService=class{constructor(eventBus$1){this._eventBus=eventBus$1,this._eventsActive=!1,this._globalEventsHooked=!1,this._activeScope=void 0,this._blockedEvents=[],this.eventProcessor=new UINavEventProcessor,this.actionHandlers=new UINavActionHandlers(eventBus$1),this.useCrossfire=!0}initialize(){this.attachEventListeners(),this.hookGlobalEvents()}handleGameEvent=(name,value,...extras)=>{let context={activeScope:this.activeScope,isEventBlocked:eventName=>this.isEventBlocked(eventName)},eventData=this.eventProcessor.processEvent(name,value,extras,context);eventData&&this.dispatchDOMEvent(eventData)};blockEvents(...events$3){let eventsToAdd=events$3.flat().filter(event=>!this._blockedEvents.includes(event));this._blockedEvents.push(...eventsToAdd)}unblockEvents(...events$3){let eventsToRemove=events$3.flat();this._blockedEvents=this._blockedEvents.filter(event=>!eventsToRemove.includes(event))}setBlockedEvents(events$3=[]){this._blockedEvents=[...events$3]}clearBlockedEvents(){this._blockedEvents=[]}isEventBlocked(eventName){return this._blockedEvents.includes(eventName)}getBlockedEvents(){return[...this._blockedEvents]}handleEnabledChange=state=>{this.eventsActive=state};dispatchDOMEvent=eventData=>{let event=new CustomEvent(DOM_UI_NAVIGATION_EVENT,{detail:eventData,cancelable:!0,bubbles:!0});this.eventProcessor.getEventBroadcastElement(this.activeScope).dispatchEvent(event)};fireEvent(uiEvent,value){this._eventBus&&(value instanceof PointerEvent?(this._eventBus.emit(GAME_UI_NAVIGATION_EVENT,uiEvent,1),this._eventBus.emit(GAME_UI_NAVIGATION_EVENT,uiEvent,0)):this._eventBus.emit(GAME_UI_NAVIGATION_EVENT,uiEvent,typeof value==`number`?value:value?1:0))}setActiveScope(scopeId){this._activeScope=scopeId}get activeScope(){return this._activeScope}activate(state=!0){this.attachEventListeners(state),this.eventsActive=state}hookGlobalEvents(state=!0){let listenerAction=document.body[state?`addEventListener`:`removeEventListener`];listenerAction(DOM_UI_NAVIGATION_EVENT,this.actionHandlers.handleGlobalEvent),this.globalEventsHooked=state}attachEventListeners(state=!0){this._eventBus&&(this._eventBus.off(GAME_UI_NAVIGATION_EVENT),this._eventBus.off(GAME_UI_NAV_MAP_ENABLED_EVENT),state&&(this._eventBus.on(GAME_UI_NAVIGATION_EVENT,this.handleGameEvent),this._eventBus.on(GAME_UI_NAV_MAP_ENABLED_EVENT,this.handleEnabledChange)))}setFilteredEvents(...events$3){this.clearFilteredEvents();let actionsToFilter=[...new Set(events$3.flat(1/0))].map(event=>ACTIONS_BY_UI_EVENT[event]);Lua_default.extensions.core_input_actionFilter.setGroup(UI_NAV_ACTION_GROUP,actionsToFilter),Lua_default.extensions.core_input_actionFilter.addAction(0,UI_NAV_ACTION_GROUP,!0)}setFilteredEventsAllExcept(...events$3){let eventsToNotFilter=[...new Set(events$3.flat(1/0))],eventsToFilter=Object.keys(ACTIONS_BY_UI_EVENT).filter(ev=>!eventsToNotFilter.includes(ev));this.setFilteredEvents(eventsToFilter)}clearFilteredEvents(){Lua_default.extensions.core_input_actionFilter.addAction(0,UI_NAV_ACTION_GROUP,!1),Lua_default.extensions.core_input_actionFilter.setGroup(UI_NAV_ACTION_GROUP,[])}set eventsActive(value){this._eventsActive=value}get eventsActive(){return this._eventsActive}set globalEventsHooked(value){this._globalEventsHooked=value}get globalEventsHooked(){return this._globalEventsHooked}get useCrossfire(){return this.actionHandlers.useCrossfire}set useCrossfire(value){this.actionHandlers.setUseCrossfire(value)}get eventBus(){return this._eventBus}},instance=null;const setUINavServiceInstance=serviceInstance=>{instance=serviceInstance},getUINavServiceInstance=()=>{if(!instance)throw Error(`UINavService not initialized.`);return instance},SCOPED_NAV_ATTR=`bng-scoped-nav`,SCOPED_NAV_PROPERTY_NAME=`_bngScopedNav`,UI_SCOPE_ATTR$1=`bng-ui-scope`,BNG_ON_UI_NAV_ATTR$1=`__BngOnUiNav`,ATTR_NAME$1=`bng-scoped-nav`,PASSTHROUGH_EXCLUDED_EVENTS=[UI_EVENTS.ok,UI_EVENTS.back,UI_EVENT_GROUPS.focusMove,UI_EVENT_GROUPS.focusMoveScalar],SCOPED_NAV_STATES={active:`full`,partial:`partial`,suspended:`suspended`,inactive:`inactive`},SCOPED_NAV_EVENTS={activate:`scopednav:activate`,deactivate:`scopednav:deactivate`,suspend:`scopednav:suspend`,resume:`scopednav:resume`},SCOPED_NAV_TYPES={normal:`normal`,container:`container`,nonav:`nonav`,popover:`popover`};var ScopeRegistry=class{constructor(){this.scopeRegistries=new WeakMap,this.depthCache=new WeakMap,this.cleanupTimers=new Map}clearDepthCache(scopeElement){this.depthCache.delete(scopeElement)}getCachedDepth(element,scopeElement){let scopeDepthCache=this.depthCache.get(scopeElement);if(scopeDepthCache||(scopeDepthCache=new Map,this.depthCache.set(scopeElement,scopeDepthCache)),!scopeDepthCache.has(element)){let depth=this._getElementDepth(element,scopeElement);scopeDepthCache.set(element,depth)}return scopeDepthCache.get(element)}register(scopeElement,handlerDescriptor){let scopeRegistry=this.scopeRegistries.get(scopeElement);scopeRegistry||(scopeRegistry={handlers:[],scopeHandler:null,initialized:!1},this.scopeRegistries.set(scopeElement,scopeRegistry));let existingIndex=scopeRegistry.handlers.findIndex(h$1=>h$1.element===handlerDescriptor.element&&this.descriptorsMatch(h$1.eventDescriptor,handlerDescriptor.eventDescriptor));return existingIndex===-1?scopeRegistry.handlers.push(handlerDescriptor):scopeRegistry.handlers[existingIndex]=handlerDescriptor,scopeRegistry.initialized||this.initializeScopeHandler(scopeElement,scopeRegistry),this.clearDepthCache(scopeElement),handlerDescriptor.handler}descriptorsMatch(desc1,desc2){return desc1.name===desc2.name&&desc1.modified===desc2.modified&&desc1.focusRequired===desc2.focusRequired}unregister(element,handlerController){let scopeElement=element.closest(`[${UI_SCOPE_ATTR$2}]`);if(!scopeElement)return;let scopeRegistry=this.scopeRegistries.get(scopeElement);if(!scopeRegistry)return;let handlerIndex=scopeRegistry.handlers.findIndex(h$1=>h$1.element===element&&h$1.handler===handlerController);handlerIndex!==-1&&(scopeRegistry.handlers.splice(handlerIndex,1),this.clearDepthCache(scopeElement)),this.scheduleCleanup(scopeElement,scopeRegistry)}scheduleCleanup(scopeElement,scopeRegistry){this.cleanupTimers.has(scopeElement)&&clearTimeout(this.cleanupTimers.get(scopeElement));let timerId=setTimeout(()=>{this.performCleanup(scopeElement,scopeRegistry),this.cleanupTimers.delete(scopeElement)},100);this.cleanupTimers.set(scopeElement,timerId)}performCleanup(scopeElement,scopeRegistry){scopeRegistry.handlers.length===0&&(scopeElement.removeEventListener(DOM_UI_NAVIGATION_EVENT,scopeRegistry.scopeHandler),this.scopeRegistries.delete(scopeElement),this.clearDepthCache(scopeElement))}destroy(){this.cleanupTimers.forEach(timer=>clearTimeout(timer)),this.cleanupTimers.clear(),this.depthCache=new WeakMap}initializeScopeHandler(scopeElement,scopeRegistry){let scopeHandler=event=>{let scopeId=scopeElement.getAttribute(UI_SCOPE_ATTR$2),uiNavService=getUINavServiceInstance(),targetScope=event.detail?.targetScope||uiNavService.activeScope;if(targetScope&&targetScope!==scopeId&&!this._isTargetScopeNested(targetScope,scopeElement)){console.warn(`UINav: Event target scope is not the intended scope. Ignoring event for this scope(${scopeId})`,{targetScope,scopeId});return}if(scopeElement._bngScopedNav&&scopeElement._bngScopedNav.canIgnoreEvent&&scopeElement._bngScopedNav.canIgnoreEvent(event)){event.stopPropagation();return}let isTargetActiveScope=targetScope===scopeId&&scopeId===uiNavService.activeScope,canPassthrough=isTargetActiveScope&&this._allowsPassthrough(scopeElement,event.detail),monitoredEvents=[...MONITORED_UI_NAV_EVENTS,UI_EVENTS.back];if(!(!isTargetActiveScope&&!canPassthrough&&!monitoredEvents.includes(event.detail.name))){if(!isTargetActiveScope&&!canPassthrough&&monitoredEvents.includes(event.detail.name)){this._executeScopedNavHandler(scopeElement,event,scopeRegistry.handlers)||event.stopPropagation();return}(!this._executeScopedBubbling(scopeElement,event,scopeRegistry.handlers)||!this._checkScopeBubbling(scopeElement,event))&&event.stopPropagation()}};scopeElement.addEventListener(DOM_UI_NAVIGATION_EVENT,scopeHandler),scopeRegistry.scopeHandler=scopeHandler,scopeRegistry.initialized=!0}_isTargetScopeNested(targetScopeId,currentScopeElement){let targetScopeElement=document.querySelector(`[${UI_SCOPE_ATTR$2}="${targetScopeId}"]`);return targetScopeElement?currentScopeElement.contains(targetScopeElement)&&targetScopeElement!==currentScopeElement:!1}_executeScopedNavHandler(scopeElement,event,handlers$1){let matchingHandlers=handlers$1.filter(h$1=>!h$1.disabled&&this._eventMatchesDescriptor(event.detail,h$1.eventDescriptor)&&h$1.element===scopeElement);if(matchingHandlers.length===0)return!0;let results=[];for(let handler$1 of matchingHandlers)try{let result=handler$1.handler(event);results.push(result)}catch(error){console.error(`Error in UINav scope handler:`,error,{element:handler$1.element,event:event.detail.name}),results.push(!1)}return results.some(result=>result===!0)}_executeScopedBubbling(scopeElement,event,handlers$1){let eventData=event.detail,matchingHandlers=handlers$1&&handlers$1.length>0?handlers$1.filter(h$1=>!h$1.disabled&&this._eventMatchesDescriptor(eventData,h$1.eventDescriptor)):[];if(matchingHandlers.length===0)return!0;let activeElement=document.activeElement,startElement=event.target;startElement=activeElement&&scopeElement.contains(activeElement)&&matchingHandlers.some(h$1=>h$1.element===activeElement)?activeElement:this._findDeepestHandlerElement(scopeElement,matchingHandlers);let bubblingPath=this._buildBubblingPath(startElement,scopeElement,matchingHandlers);return bubblingPath.length===0?(console.warn(`UINav: No bubbling path found.`,{scopeElement,event,handlers:handlers$1}),!0):this._executeHandlersAlongPath(bubblingPath,event)}_findDeepestHandlerElement(scopeElement,handlers$1){return[...new Set(handlers$1.map(h$1=>h$1.element))].filter(el=>this.getCachedDepth(el,scopeElement)<0?!1:!this._isElementInNestedScope(el,scopeElement)).sort((a$1,b)=>{let depthA=this.getCachedDepth(a$1,scopeElement);return this.getCachedDepth(b,scopeElement)-depthA})[0]||null}_isElementInNestedScope(element,currentScopeElement){let current=element;for(;current&¤t!==currentScopeElement;){if(current.hasAttribute(`bng-ui-scope`)&¤t!==currentScopeElement)return!0;current=current.parentElement}return!1}_buildBubblingPath(startElement,scopeElement,handlers$1){if(!scopeElement.contains(startElement))return console.warn(`UINav: Start element is outside scope boundary`,startElement,scopeElement),[];let path=[],current=startElement;for(;current&&scopeElement.contains(current);){let elementHandlers=handlers$1.filter(h$1=>h$1.element===current);if(elementHandlers.length>0&&path.push({element:current,handlers:elementHandlers}),current===scopeElement)break;current=current.parentElement}return path}_executeHandlersAlongPath(bubblingPath,event){for(let pathItem of bubblingPath){let results=[];for(let handlerDescriptor of pathItem.handlers)try{let result=handlerDescriptor.handler(event);results.push(result)}catch(error){console.error(`Error in UINav scope handler:`,error,{element:pathItem.element,event:event.detail.name}),results.push(!1)}if(!results.some(result=>result===!0))return!1}return!0}_checkScopeBubbling(scopeElement,event){let scopedNavProps=scopeElement._bngScopedNav;return scopedNavProps?scopedNavProps.shouldBubbleEvent&&typeof scopedNavProps.shouldBubbleEvent==`function`?scopedNavProps.shouldBubbleEvent(event):!1:!0}_getElementDepth(element,parent){let depth=0,current=element;for(;current&¤t!==parent;)depth++,current=current.parentElement;return current===parent?depth:-1}_allowsPassthrough(scopeElement,eventData){let domScopedNavProps=scopeElement.hasAttribute(`bng-scoped-nav`)?scopeElement[SCOPED_NAV_PROPERTY_NAME]:{};return domScopedNavProps.passthroughActive&&domScopedNavProps.passthroughEnabled&&domScopedNavProps.passthroughEvents.includes(eventData.name)}_eventMatchesDescriptor(eventData,descriptor){for(let[item,value]of Object.entries(descriptor))if(value!==void 0)if(item===`focusRequired`){if(value&&!value.contains(document.activeElement))return!1}else{if(!(item in eventData))return!1;if(typeof value==`function`){if(!value(eventData[item]))return!1}else if(eventData[item]!=value)return!1}return!0}};const isOnOffEvent=eventName=>!VALUE_BASED_EVENTS.includes(eventName),checkOn=value=>value,normalizeEventDescriptor=eventDescriptor=>({string:{name:eventDescriptor,value:isOnOffEvent(eventDescriptor)?checkOn:void 0,modified:!1,extras:void 0},object:{...eventDescriptor,value:`value`in eventDescriptor?eventDescriptor.value:isOnOffEvent(eventDescriptor.name)?checkOn:void 0}})[typeof eventDescriptor]||!1,eventMatchesDescriptor=(eventData,descriptor)=>{for(let[item,value]of Object.entries(descriptor))if(value!==void 0)if(item===`focusRequired`){if(value&&!value.contains(document.activeElement))return!1}else{if(!(item in eventData))return!1;if(typeof value==`function`){if(!value(eventData[item]))return!1}else if(eventData[item]!=value)return!1}return!0},getDescriptorEventNameText=descriptor=>descriptor.name?typeof descriptor.name==`function`?descriptor.name.name:descriptor.name:`ALL`;var HandlerFactory=class{static createHandler(eventDescriptor,userHandler){let descriptor=normalizeEventDescriptor(eventDescriptor);if(!descriptor)throw Error(`Invalid event descriptor when trying to create a UINav handler. Expecting a String or an Object.`);let handlerFuncName=userHandler?.name||`uiNav_${getDescriptorEventNameText(descriptor)}_handler`,disabled=!1;function wrapper(event){let eventData=event?.detail||{};return disabled||!eventMatchesDescriptor(eventData,descriptor)?!0:userHandler(event)}return Object.defineProperty(wrapper,`name`,{value:handlerFuncName}),Object.defineProperty(wrapper,`disabled`,{configurable:!1,get:()=>disabled,set:state=>{disabled=state}}),wrapper}static normalizeEventDescriptor(eventDescriptor){return{string:{name:eventDescriptor,value:isOnOffEvent(eventDescriptor)?checkOn:void 0,modified:!1,extras:void 0},object:{...eventDescriptor,value:`value`in eventDescriptor?eventDescriptor.value:isOnOffEvent(eventDescriptor.name)?checkOn:void 0}}[typeof eventDescriptor]||!1}},UINavHandlers=class{constructor(){this.scopeRegistry=new ScopeRegistry}add(domElement,uiNavHandlerOrDescriptor,handler$1=void 0){let scopeElement=domElement.closest(`[${UI_SCOPE_ATTR$2}]`);return scopeElement?this.addWithScope(domElement,uiNavHandlerOrDescriptor,handler$1,scopeElement):this.addIndividual(domElement,uiNavHandlerOrDescriptor,handler$1)}remove(domElement,uiNavHandler){domElement.closest(`[bng-ui-scope]`)?this.scopeRegistry.unregister(domElement,uiNavHandler):this.removeIndividual(domElement,uiNavHandler)}addWithScope(domElement,uiNavHandlerOrDescriptor,handler$1,scopeElement){let targetElement=domElement;if(!scopeElement.contains(targetElement))return console.error(`UINav: Attempting to register handler for element outside scope`,{targetElement,scopeElement,scopeId:scopeElement.getAttribute(UI_SCOPE_ATTR$2)}),this.addIndividual(domElement,uiNavHandlerOrDescriptor,handler$1);let wrapperHandler=handler$1?HandlerFactory.createHandler(uiNavHandlerOrDescriptor,handler$1):uiNavHandlerOrDescriptor,handlerDescriptor={element:domElement,eventDescriptor:HandlerFactory.normalizeEventDescriptor(uiNavHandlerOrDescriptor),handler:wrapperHandler,disabled:!1};return this.scopeRegistry.register(scopeElement,handlerDescriptor)}addIndividual(domElement,uiNavHandlerOrDescriptor,handler$1){let uiNavHandler=handler$1?HandlerFactory.createHandler(uiNavHandlerOrDescriptor,handler$1):uiNavHandlerOrDescriptor;return domElement.addEventListener(DOM_UI_NAVIGATION_EVENT,uiNavHandler),uiNavHandler}removeIndividual(domElement,uiNavHandler){domElement.removeEventListener(DOM_UI_NAVIGATION_EVENT,uiNavHandler)}},handlers_default=new UINavHandlers;function usePopupUINavScopeName(baseName,props){let attrs=useAttrs(),scopeName=baseName+`__`+attrs.__id;return useUINavScope(scopeName),watch(()=>props.popupActive,()=>props.popupActive&&useUINavScope(scopeName)),scopeName}function useUINavScope(scope$1=void 0,restoreScopeOnUnmount=!0){let currentScope=ref(scope$1),oldScope,scopeChanged=!1,setScope=newScope=>{scopeChanged=!0,currentScope.value=newScope,getUINavServiceInstance().setActiveScope(newScope)},restoreOldScope=()=>{getUINavServiceInstance().setActiveScope(oldScope)};return onMounted(()=>{oldScope=getUINavServiceInstance().activeScope,currentScope.value?setScope(currentScope.value):currentScope.value=oldScope}),onUnmounted(()=>{scopeChanged&&restoreScopeOnUnmount&&restoreOldScope()}),{current:computed(()=>currentScope.value),set:setScope,get oldScope(){return oldScope}}}function watchUINavEventChange(domElementRef,handler$1){return watch(()=>{if(!domElementRef.value)return{};let eventName=domElementRef.value.getAttribute(UI_EVENT_ATTR);return{eventName,action:ACTIONS_BY_UI_EVENT[eventName]}},handler$1)}const eventFirer=uiEvent=>value=>getUINavServiceInstance().fireEvent(uiEvent,value);var counter=0;const uniqueNum=()=>++counter%1e5+Math.random(),uniqueId=(name=``,separator=`.`)=>{let str=`${name?name+separator:``}${uniqueNum().toString(16)}`;return separator===`.`?str:str.replace(`.`,separator)},uniqueSafeId=()=>uniqueId(``,`_`);var DEFAULT_NAVIGATION=[...MONITORED_UI_NAV_EVENTS,`back`],ALWAYS_ACTIVE=[`ok`,`menu`,`back`],BLOCKER=Symbol(`uiNavBlocker`);const useUINavTracker=defineStore(`uiNavTracker`,()=>{let{lua,events:events$3}=useBridge(),showErrors=window.beamng&&!window.beamng.shipping,initialised=!1,trackedEvents=ref([]),trackedInstances={},ignoredEvents=ref([]),ignoredInstances={},blockedEvents$1=ref([]),blockedInstances={},unblockedEvents=ref([]),unblockedInstances={},activeEvents=ref([]),labelRegistry=useUiNavLabel();function updateBlocklist(){let uiNavService=getUINavServiceInstance(),eventsToBlock=blockedEvents$1.value.filter(name=>!unblockedEvents.value.includes(name));uiNavService.setBlockedEvents(eventsToBlock)}let raf;function update$6(eventName){cancelAnimationFrame(raf),raf=requestAnimationFrame(()=>{activeEvents.value=trackedEvents.value.filter(e=>!ignoredEvents.value.includes(e.name)&&(unblockedEvents.value.includes(e.name)||!blockedEvents$1.value.includes(e.name))).map(e=>({...e,nogroup:!!trackedInstances[e.name]?.at(-1)?.nogroup}))})}let ownerIdCheck=ownerId$1=>{if(typeof ownerId$1!=`string`||!ownerId$1)throw Error(`ownerId is required and must be a string`)},eventNameCheck=(eventName,quiet=!1)=>{let ok=!0;return typeof eventName!=`string`||!eventName?(showErrors&&logger_default.error(`eventName is required`),ok=!1):eventName in ACTIONS_BY_UI_EVENT||(showErrors&&!quiet&&logger_default.error(`eventName ${eventName} does not exist`),ok=!1),ok},getRecentInstance=eventName=>trackedInstances[eventName].findLast(inst=>inst.element!==BLOCKER),parseActive=(active,eventName)=>typeof active==`boolean`?active:ALWAYS_ACTIVE.includes(eventName);function addEvent(eventName,ownerId$1,element=null,options={}){if(initialised||rebind(),!eventNameCheck(eventName))return;ownerIdCheck(ownerId$1),trackedInstances[eventName]||(trackedInstances[eventName]=[]),element||=window.document.body;let instance$1=trackedInstances[eventName].find(instance$2=>instance$2.ownerId===ownerId$1);if(instance$1){instance$1.element=element,instance$1.nogroup=!!options?.nogroup,instance$1.active=parseActive(options?.active,eventName),update$6(eventName);return}if(trackedInstances[eventName].push({ownerId:ownerId$1,element,nogroup:!!options?.nogroup,active:parseActive(options?.active,eventName)}),trackedInstances[eventName].length===1){let event={name:eventName,label:computed(()=>{let instance$2=getRecentInstance(eventName);return labelRegistry.getLabel(eventName,instance$2?.element)||null}),action:computed(()=>getRecentInstance(eventName)?.active?eventFirer(eventName):null)};trackedEvents.value.push(event),actionSwitch(!0,eventName)}update$6(eventName)}function updateEvent(eventName,ownerId$1,element,options={}){if(ownerIdCheck(ownerId$1),!eventNameCheck(eventName))return;element||=window.document.body;let instance$1=trackedInstances[eventName]?.find(instance$2=>instance$2.ownerId===ownerId$1);if(!instance$1){addEvent(eventName,ownerId$1,element,!1,options);return}instance$1.element=element,instance$1.nogroup=!!options?.nogroup,instance$1.active=parseActive(options?.active,eventName),update$6(eventName)}function removeEvent(eventName,ownerId$1,element=null){if(ownerIdCheck(ownerId$1),!eventNameCheck(eventName)||!trackedInstances[eventName])return;element||=window.document.body;let idx=trackedInstances[eventName].findIndex(instance$1=>instance$1.ownerId===ownerId$1);if(idx!==-1&&(trackedInstances[eventName].splice(idx,1),update$6(eventName),trackedInstances[eventName].length===0)){delete trackedInstances[eventName];let idx$1=trackedEvents.value.findIndex(h$1=>h$1.name===eventName);idx$1>-1&&(trackedEvents.value.splice(idx$1,1),actionSwitch(!1,eventName))}}function addHelper(eventList,instanceList,eventName,ownerId$1,func,quiet=!1){ownerIdCheck(ownerId$1),eventNameCheck(eventName,quiet)&&(eventList.value.includes(eventName)||(eventList.value.push(eventName),func&&func(),instanceList[eventName]||(instanceList[eventName]=[])),instanceList[eventName].push(ownerId$1))}function removeHelper(eventList,instanceList,eventName,ownerId$1,func,quiet=!1){if(ownerIdCheck(ownerId$1),!eventNameCheck(eventName,quiet)||!(eventName in instanceList))return;let instIdx=instanceList[eventName].indexOf(ownerId$1);if(instIdx!==-1&&(instanceList[eventName].splice(instIdx,1),instanceList[eventName].length===0)){let idx=eventList.value.indexOf(eventName);idx>-1&&(eventList.value.splice(idx,1),func&&func())}}function addIgnore(eventName,ownerId$1){addHelper(ignoredEvents,ignoredInstances,eventName,ownerId$1,null,!0)}function removeIgnore(eventName,ownerId$1){removeHelper(ignoredEvents,ignoredInstances,eventName,ownerId$1,null,!0)}function addBlocker(eventName,ownerId$1){addHelper(blockedEvents$1,blockedInstances,eventName,ownerId$1,()=>{addEvent(eventName,ownerId$1,BLOCKER),updateBlocklist()})}function removeBlocker(eventName,ownerId$1){removeHelper(blockedEvents$1,blockedInstances,eventName,ownerId$1,()=>{removeEvent(eventName,ownerId$1,BLOCKER),updateBlocklist()})}function addForceUnblock(eventName,ownerId$1){addHelper(unblockedEvents,unblockedInstances,eventName,ownerId$1,()=>{update$6(eventName),updateBlocklist()})}function removeForceUnblock(eventName,ownerId$1){removeHelper(unblockedEvents,unblockedInstances,eventName,ownerId$1,()=>{update$6(eventName),updateBlocklist()})}let actionSwitch=async(enabled,eventName)=>{eventName!==`menu`&&(!enabled&&blockedEvents$1.value.includes(eventName)||await lua.extensions.core_input_bindings.setMenuActionEnabled(enabled,ACTIONS_BY_UI_EVENT[eventName]))};function rebind(){initialised||(initialised=!0,getUINavServiceInstance().clearBlockedEvents(),DEFAULT_NAVIGATION.forEach(name=>addEvent(name,`__uiNavTracker_default`))),Object.keys(ACTIONS_BY_UI_EVENT).filter(name=>!DEFAULT_NAVIGATION.includes(name)&&!trackedEvents.value.find(e=>e.name===name)).forEach(name=>actionSwitch(!1,name))}return lua.extensions.core_input_bindings.getMenuActionMapEnabled().then(enabled=>enabled&&rebind()),events$3.on(`MenuActionMapEnabled`,enabled=>enabled&&rebind()),{activeEvents,blockedEvents:blockedEvents$1,unblockedEvents,addEvent,updateEvent,removeEvent,addIgnore,removeIgnore,addBlocker,removeBlocker,addForceUnblock,removeForceUnblock}});function useUINavBlocker(){let id=uniqueId(`uiNavBlocker`),tracker=useUINavTracker(),allEventNames=Object.keys(ACTIONS_BY_UI_EVENT),defaultEvents=Object.freeze(Object.fromEntries(DEFAULT_NAVIGATION.map(name=>[name,name]))),allEvents=Object.freeze(UI_EVENTS),blockedEvents$1=[],unblockedEvents=[],filterEvents=events$3=>{if(!events$3)return[];if(typeof events$3==`string`)events$3=[events$3];else if(events$3.length===0)return[];return events$3.reduce((res,name)=>allEventNames.includes(name)&&!res.includes(name)?[...res,name]:res,[])};function allowOnly(events$3=[]){events$3=filterEvents(events$3),blockOnly(allEventNames.filter(name=>!events$3.includes(name)))}function allowNavigationOnly(enforce=!0){if(!enforce)return blockOnly();let events$3=[...DEFAULT_NAVIGATION,`menu`];blockOnly(allEventNames.filter(name=>!events$3.includes(name)))}function blockOnly(events$3=[]){events$3=filterEvents(events$3),blockedEvents$1.filter(name=>!events$3.includes(name)).forEach(name=>tracker.removeBlocker(name,id)),blockedEvents$1.splice(0),blockedEvents$1.push(...events$3),blockedEvents$1.forEach(name=>tracker.addBlocker(name,id))}function ensureNoBlock(events$3=[]){events$3=filterEvents(events$3),unblockedEvents.filter(name=>!events$3.includes(name)).forEach(name=>tracker.removeForceUnblock(name,id)),unblockedEvents.splice(0),unblockedEvents.push(...events$3),events$3.forEach(name=>tracker.addForceUnblock(name,id))}function isBlocked(eventName){return tracker.unblockedEvents.includes(eventName)?!1:tracker.blockedEvents.includes(eventName)}let clear=()=>blockOnly();return onUnmounted(clear),{allEvents,defaultEvents,allowOnly,allowNavigationOnly,blockOnly,clear,ensureNoBlock,isBlocked}}const useUiNavLabel=defineStore(`uiNavLabeler`,()=>{let elementLabels=reactive(new WeakMap),eventElements=reactive({});function registerLabel(element,eventNames,label){elementLabels.has(element)||elementLabels.set(element,{});let elementEvents=elementLabels.get(element);Array.isArray(eventNames)||(eventNames=[eventNames]);for(let eventName of eventNames)elementEvents[eventName]=label,eventElements[eventName]||(eventElements[eventName]=new Set),eventElements[eventName].add(element)}function clearLabels(element,eventNames=null){if(!elementLabels.has(element))return;let elementEvents=elementLabels.get(element);if(eventNames===null){for(let eventName of Object.keys(elementEvents))eventElements[eventName]&&eventElements[eventName].delete(element);elementLabels.delete(element)}else{for(let eventName of eventNames)delete elementEvents[eventName],eventElements[eventName]&&eventElements[eventName].delete(element);Object.keys(elementEvents).length===0&&elementLabels.delete(element)}}function getLabel(eventName,element=null){if(element&&elementLabels.has(element)&&elementLabels.get(element)[eventName])return elementLabels.get(element)[eventName];if(eventElements[eventName])for(let el of eventElements[eventName]){let label=elementLabels.get(el)?.[eventName];if(label)return label}return null}function getElementEvents(element){return elementLabels.has(element)?Object.keys(elementLabels.get(element)):[]}return{registerLabel,clearLabels,getLabel,getElementEvents}});var LUA_EXTENSION_NAME=`ui_topBar`;const useTopBar=defineStore(`topBar`,()=>{let{events:events$3}=useBridge(),setupComplete=!1,_items=ref({}),_activeItem=ref(null),visible=ref(!1),hiddenItems=ref([]),gameState$1=reactive({isInGame:void 0,gameState:void 0,uiState:void 0,isCareerActive:void 0,isGarageActive:void 0,isMissionActive:void 0,isScenarioActive:void 0}),sortItems=(a$1,b)=>(a$1.order??0)-(b.order??0),items$2=computed(()=>Object.values(_items.value).filter(item=>!hiddenItems.value||!hiddenItems.value.includes(item.id)).sort(sortItems)),activeItem=computed({get:()=>_activeItem.value,set:value=>{value!==_activeItem.value&&(_activeItem.value=value,Lua_default.ui_topBar.setActiveItem(value))}}),updateTopBarVisibility=()=>{if(!(!gameState$1.uiState||gameState$1.isInGame===void 0)){if(gameState$1.uiState.startsWith(`menu.mainmenu`)&&!gameState$1.isInGame&&(visible.value=!1),!visible.value||gameState$1.uiState===`unknown`){activeItem.value=null;return}if(gameState$1.uiState){let updatedActiveItem=Object.values(_items.value).find(item=>item.targetState===gameState$1.uiState);updatedActiveItem||=Object.values(_items.value).find(item=>item.substate&&gameState$1.uiState.startsWith(item.substate)),activeItem.value=updatedActiveItem?updatedActiveItem.id:null}updateHiddenItems()}};watch(()=>gameState$1.uiState,()=>nextTick(updateTopBarVisibility)),watch(()=>gameState$1.isInGame,()=>nextTick(updateTopBarVisibility));let selectPrevious=()=>{if(!visible.value)return;let len=items$2.value.length;if(len===0)return;let previousIndex=(items$2.value.findIndex(item=>item.id===activeItem.value)-1+len)%len;selectEntry(items$2.value[previousIndex].id)},selectNext=()=>{if(!visible.value)return;let len=items$2.value.length;if(len===0)return;let nextIndex=(items$2.value.findIndex(item=>item.id===activeItem.value)+1)%len;selectEntry(items$2.value[nextIndex].id)},selectEntry=itemId=>{visible.value&&(activeItem.value=itemId,Lua_default.ui_topBar.selectItem(itemId))},show=()=>{visible.value=!0},hide$2=()=>{visible.value=!1};function updateHiddenItems(){hiddenItems.value=Object.values(_items.value).filter(shouldHideItem).map(item=>item.id)}function shouldHideItem(item){if(!item.flags||item.flags.length===0)return!1;for(let flag of item.flags)if(flag===`inGameOnly`&&!gameState$1.isInGame||flag===`careerOnly`&&!gameState$1.isCareerActive||flag===`noCareer`&&gameState$1.isCareerActive||flag===`missionOnly`&&!gameState$1.isMissionActive||flag===`noMission`&&gameState$1.isMissionActive&&!gameState$1.isScenarioUnrestricted||flag===`garageOnly`&&!gameState$1.isGarageActive||flag===`noGarage`&&gameState$1.isGarageActive||flag===`scenarioOnly`&&!gameState$1.isScenarioActive||flag===`noScenario`&&gameState$1.isScenarioActive&&!gameState$1.isScenarioUnrestricted||flag===`careerGarageOnly`&&(!gameState$1.isCareerActive||!gameState$1.isGarageActive)||flag===`noCareerGarage`&&gameState$1.isCareerActive&&gameState$1.isGarageActive)return!0;return!1}function onCareerStateChanged(data){gameState$1.isCareerActive=data.isActive}function onGarageStateChanged(data){gameState$1.isGarageActive=data.isActive}function onMissionStateChanged(data){gameState$1.isMissionActive=data.isActive}function onScenarioStateChanged(data){gameState$1.isScenarioActive=data.isActive}function onDataRequested(data){let{isInGame,items:dataItems}=data;_items.value=dataItems,gameState$1.isInGame=isInGame,hiddenItems.value=[]}function onGameStateChanged(data){gameState$1.isInGame=data.isInGame,gameState$1.isCareerActive=data.isCareerActive,gameState$1.isGarageActive=data.isGarageActive,gameState$1.isMissionActive=data.isMissionActive,gameState$1.isScenarioActive=data.isScenarioActive,gameState$1.isScenarioUnrestricted=data.isScenarioUnrestricted,nextTick(()=>updateHiddenItems())}function onEntriesChanged(data){_items.value=data}function onVisibleItemsChanged(data){hiddenItems.value=data}function onShow(){visible.value=!0}function onHide(){visible.value=!1}let debouncedStateChange=debounce(data=>{gameState$1.uiState=(data.fullPath||data.name||`unknown`).replace(/^\//,``)},100);function onUIStateChanged(data){debouncedStateChange(data)}let eventHandlerMap={selectPrevious,selectNext,OnCareerActive:onCareerStateChanged,garageStateChanged:onGarageStateChanged,missionStateChanged:onMissionStateChanged,scenarioStateChanged:onScenarioStateChanged,dataRequested:onDataRequested,gameStateChanged:onGameStateChanged,entriesChanged:onEntriesChanged,visibleItemsChanged:onVisibleItemsChanged,show:onShow,hide:onHide};function addListeners(){for(let eventName of Object.keys(eventHandlerMap))events$3.on(`${LUA_EXTENSION_NAME}_${eventName}`,eventHandlerMap[eventName])}function removeListeners$1(){for(let eventName of Object.keys(eventHandlerMap))events$3.off(`${LUA_EXTENSION_NAME}_${eventName}`,eventHandlerMap[eventName])}return(async()=>{setupComplete||=(await Lua_default.extensions.isExtensionLoaded(LUA_EXTENSION_NAME)||await Lua_default.extensions.load(LUA_EXTENSION_NAME),addListeners(),await Lua_default.ui_topBar.requestData(),!0)})(),{activeItem,items:items$2,visible,gameState:gameState$1,show,hide:hide$2,selectEntry,selectPrevious,selectNext,onUIStateChanged,dispose:()=>{removeListeners$1(),Lua_default.extensions.unload(LUA_EXTENSION_NAME)}}});var events$2,beamNG,serviceProviders=ref(),online=ref(!1),videoAdapter=ref(``),modCounts=ref({total:0,active:0}),gameState=ref(),mainMenuBackgroundRequired=ref(),mainMenuFirstTime=ref(!0),serviceProvidersOnline=computed(()=>{let provs=serviceProviders.value,gotInfo=!!provs,ret={eos:gotInfo&&provs.eos&&provs.eos.loggedin,steam:gotInfo&&provs.steam&&provs.steam.loggedin&&provs.steam.working};return ret.any=Object.values(ret).some(v=>v),ret}),version,versionSimple,buildInfo,init$2=()=>{let api$1;({api:api$1,events:events$2,beamNG}=useBridge()),beamNG||=FAKE_BEAMNG_OBJ,api$1.serializeToLuaCheck(`English: hello`),api$1.serializeToLuaCheck(`Spanish: güeñes`),api$1.serializeToLuaCheck(`French: bâguéttè, garçon`),api$1.serializeToLuaCheck(`Czech: Kl�vesnice`),api$1.serializeToLuaCheck(`Korean: \r��\v��\v��`),api$1.serializeToLuaCheck(`Chinese Sim: 欢迎来到简体中文版的`),api$1.serializeToLuaCheck(`Chinese Tr: 歡迎來到`),api$1.serializeToLuaCheck(`Japanese: 』日本語版にようこそ`),api$1.serializeToLuaCheck(`Polish: źćłąóę`),api$1.serializeToLuaCheck(`Russian: абвгеёьъ`),events$2.on(`ServiceProviderInfo`,info=>serviceProviders.value=info),events$2.on(`OnlineStateChanged`,state=>online.value=state),events$2.on(`ModManagerModsChanged`,_processModData),events$2.on(`ShowEntertainingBackground`,state=>mainMenuBackgroundRequired.value=state),events$2.on(`GameStateUpdate`,state=>gameState.value=state.state),version=beamNG.version,versionSimple=_toSimpleVersion(beamNG.version),buildInfo=beamNG.buildinfo,refresh()},refresh=()=>{_requestServiceProviders(),_requestOnlineState(),_refreshVideoAdapter(),_refreshModData()},_refreshVideoAdapter=()=>Lua_default.Engine.Render.getAdapterType().then(adapter=>videoAdapter.value=adapter),_requestServiceProviders=()=>beamNG.requestServiceProviderInfo(),_requestOnlineState=()=>Lua_default.core_online.requestState(),_refreshModData=()=>Lua_default.core_modmanager.requestState(),sysInfo_default={init:init$2,refresh,serviceProviders,serviceProvidersOnline,online,videoAdapter,modCounts,gameState,mainMenuBackgroundRequired,mainMenuFirstTime,get version(){return version},get versionSimple(){return versionSimple},get buildInfo(){return buildInfo}},_toSimpleVersion=versionStr=>{let bits=versionStr.split(`.`);return bits.length==5&&bits.pop(),bits.join(`.`).replace(/(\.0)+$/,``)},_processModData=data=>{let mods=Object.values(data).filter(mod=>mod.modname!=`translations`);modCounts.value.total=mods.length,modCounts.value.active=mods.filter(({active})=>active).length},FAKE_BEAMNG_OBJ={version:`0.12.3.4.FAKE12345`,buildInfo:`Sample Fake BuildInfo - running outside of game`,requestServiceProviderInfo(){events$2.emit(`ServiceProviderInfo`,{steam:{loggedin:!0,accountID:`12345678901234567`,playerName:`fakeplayer`,branch:`qa_latest`,language:`english`,useSteam:!0,working:!0}})}};const useLibStore=defineStore(`lib`,{});var bridge$2,stateStack=[];function add(stateName){rem(stateName),stateStack.push(stateName)}function rem(stateName){let idx=stateStack.lastIndexOf(stateName);idx>-1&&stateStack.splice(idx,1)}var luaStringify=any=>JSON.stringify(any).replace(/^\[(.*)\]$/,`{$1}`),luaReport=(stateName,opened)=>bridge$2.api.engineLua(`extensions.hook("onUIStateTriggered", ${luaStringify(stateName)}, ${luaStringify(!!opened)}, ${luaStringify(stateStack)})`);function reportState(stateName,opened,prevName=null){bridge$2||=useBridge(),prevName&&(rem(prevName),luaReport(prevName,!1)),opened?add(stateName):rem(stateName),luaReport(stateName,opened)}function reportPopupState(popup,opened){reportState(`/popup/${popup.componentName}/${popup.wrapper.blur?`fullscreen`:`aside`}`,opened)}function scroll(el,binding){let direction$1=binding.arg;el.scrollHeight<=el.clientHeight||(direction$1===`top`?el.scrollTop>0&&(el.scrollTop=0):direction$1===`bottom`&&el.scrollTop{let id,blurAmount=1,blurUpdateWrapper=debounce(updateBlur,50),resizeObserver,removePositionObserver;function observe(){resizeObserver||(resizeObserver=new ResizeObserver(blurUpdateWrapper),resizeObserver.observe(el)),removePositionObserver||=observePosition(el,blurUpdateWrapper)}function unobserve(){resizeObserver&&resizeObserver.disconnect(),removePositionObserver&&removePositionObserver(),resizeObserver=null,removePositionObserver=null}elemBlurs.set(el,{blurUpdateWrapper,processBlurVal,observe,unobserve}),processBlurVal(binding.value),window.addEventListener(`resize`,blurUpdateWrapper);function processBlurVal(val){switch(typeof val){case`undefined`:val=1;break;case`boolean`:val=val?1:0;break;case`number`:(val<0||val>1)&&(logger_default.error(`Attempted to use v-bng-blur with a number out of range 0..1: ${val}\nSee stack:`,logger_default.STACK_TRACE),val=1);break;default:logger_default.error(`Attempted to use v-bng-blur with a non-number, non-boolean value: ${val}\nSee stack:`,logger_default.STACK_TRACE),val=0}blurAmount=val,blurUpdateWrapper()}function calcBlur(){let rect=el.getBoundingClientRect();return rect.width>0&&rect.height>0&&rect.bottom>0&&rect.top0&&rect.left{let elemBlur=elemBlurs.get(el);elemBlur&&binding.value!=binding.oldValue&&elemBlur.processBlurVal(binding.value)},unmounted:(el,binding)=>{let elemBlur=elemBlurs.get(el);elemBlur&&(elemBlur.unobserve(),elemBlur.processBlurVal(0),window.removeEventListener(`resize`,elemBlur.blurUpdateWrapper),elemBlurs.delete(el))}},DEFAULT_HOLD_DELAY=400,DEFAULT_REPEAT_INTERVAL=100,HOLD_CSS_TIME_VAR=`--hold-time`,HOLD_START_CSS_CLASS=`hold-start`,HOLD_ACTIVE_CSS_CLASS=`hold-active`,HOLD_COMPLETED_CSS_CLASS=`hold-completed`,EVENT_CLICK=`click`,EVENT_HOLD=`hold`,ELEMENT_ID=`__BNG_CLICK_ID`,curId=0,datas={};function update$5(element,binding){let id=element[ELEMENT_ID]||(element[ELEMENT_ID]=++curId),data=datas[id]||(datas[id]={id,element,events:{},binding:{}});if(typeof binding.value==`object`)data.binding=binding.value;else if(typeof binding.value==`function`){let cbName=binding.modifiers?.hold?`holdCallback`:`clickCallback`;data.binding[cbName]=binding.value}return data.controllerOnly=!!binding.modifiers?.controller,data.hasClick=typeof data.binding.clickCallback==`function`,data.hasHold=typeof data.binding.holdCallback==`function`,typeof data.binding.holdDelay!=`number`&&(data.binding.holdDelay=DEFAULT_HOLD_DELAY),typeof data.binding.repeatInterval!=`number`&&(data.binding.repeatInterval=DEFAULT_REPEAT_INTERVAL),data}function remove(element){let id=element[ELEMENT_ID];if(!id)return;let data=datas[id];data&&(`mouseleave`in data.events&&data.events.mouseleave(),updateEvents(id),delete datas[id],delete element[ELEMENT_ID])}function updateEvents(id,events$3={}){let data=datas[id];if(data){for(let event in data.events)data.element.removeEventListener(event,data.events[event]);for(let event in events$3)data.element.addEventListener(event,events$3[event]);data.events=events$3}}var BngClick_default={mounted:(el,binding)=>{let data=update$5(el,binding),approveEvent=evt=>data.controllerOnly?!!evt.fromController:evt.button===0||evt.fromController,tmrHoldActive;updateEvents(data.id,{mousedown:e=>{approveEvent(e)&&(el.style.setProperty(HOLD_CSS_TIME_VAR,`${data.binding.holdDelay}ms`),el.classList.toggle(HOLD_START_CSS_CLASS,!0),clearTimeout(tmrHoldActive),tmrHoldActive=setTimeout(()=>el.classList.toggle(HOLD_ACTIVE_CSS_CLASS,!0),0),el.classList.toggle(HOLD_COMPLETED_CSS_CLASS,!1),canInvokeEventType(EVENT_CLICK)&&(detectedEventType=EVENT_CLICK),canInvokeEventType(EVENT_HOLD)&&startHoldDelayTimer(e))},mouseup:e=>{if(approveEvent(e)){switch(el.style.removeProperty(HOLD_CSS_TIME_VAR),el.classList.toggle(HOLD_START_CSS_CLASS,!1),el.classList.toggle(HOLD_ACTIVE_CSS_CLASS,!1),clearTimeout(tmrHoldActive),stopHoldDelayTimer(),detectedEventType){case EVENT_CLICK:doAction(EVENT_CLICK,e);break;case EVENT_HOLD:stopHoldTimer();break}detectedEventType=null}},mouseleave:()=>{switch(el.style.removeProperty(HOLD_CSS_TIME_VAR),el.classList.toggle(HOLD_START_CSS_CLASS,!1),el.classList.toggle(HOLD_ACTIVE_CSS_CLASS,!1),clearTimeout(tmrHoldActive),stopHoldDelayTimer(),detectedEventType){case EVENT_HOLD:stopHoldTimer();break}detectedEventType=null},blur:()=>data.events.mouseleave()});let detectedEventType,holdDelayTimer,holdTimer;function startHoldDelayTimer(e){stopHoldTimer(),stopHoldDelayTimer(),holdDelayTimer=setTimeout(()=>{el.classList.toggle(HOLD_COMPLETED_CSS_CLASS,!0),detectedEventType=EVENT_HOLD,startHoldTimer(e)},data.binding.holdDelay)}function stopHoldDelayTimer(){holdDelayTimer&&=(clearTimeout(holdDelayTimer),null)}function startHoldTimer(e){doAction(EVENT_HOLD,e),data.binding.repeatInterval&&(stopHoldTimer(),holdTimer=setInterval(()=>{doAction(EVENT_HOLD,e)},data.binding.repeatInterval))}function stopHoldTimer(){holdTimer&&=(clearInterval(holdTimer),null)}function doAction(eventType,originalEvent){let callback=getCallback(eventType);callback&&(eventType==EVENT_HOLD?setTimeout(()=>callback(originalEvent),100):callback(originalEvent))}function getCallback(arg){switch(arg){case EVENT_CLICK:return data.binding.clickCallback;case EVENT_HOLD:return data.binding.holdCallback}return null}function canInvokeEventType(eventType){switch(eventType){case EVENT_CLICK:return data.hasClick;case EVENT_HOLD:return data.hasHold}return!1}},updated:update$5,beforeUnmount:remove},BngDisabled_default=(el,{value})=>{let has$1={disabled:el.hasAttribute(`disabled`),tabindex:el.hasAttribute(`tabindex`)};!has$1.disabled&&value?(el.setAttribute(`disabled`,`disabled`),has$1.tabindex&&(el._BNG_TABINDEX=el.getAttribute(`tabindex`),el.setAttribute(`tabindex`,`-1`))):has$1.disabled&&!value&&(el.removeAttribute(`disabled`),has$1.tabindex&&`_BNG_TABINDEX`in el&&el.getAttribute(`tabindex`)!==el._BNG_TABINDEX&&(el.setAttribute(`tabindex`,el._BNG_TABINDEX),delete el._BNG_TABINDEX))},DELAY=300,EVENTS_IN=[`uinav-focus`,`focus`,`focusin`],EVENTS_OUT=[`uinav-blur`,`blur`,`focusout`],elems$1=new Map,globInit=!1;function initGlobals(){globInit=!0;let running=!1,targets={in:[],out:[]};function preventer(){for(let[part,list]of Object.entries(targets))if(list.length!==0){for(let target of list)for(let[uid$2,data]of elems$1)if(!(!data.capture||!data.timer||!data.element)){if(part===`in`){if(data.element===target||data.element.contains(target))continue}else if(data.element!==target&&!data.element.contains(target))continue;clearTimeout(data.timer),data.timer=null;break}list.splice(0)}}function handler$1(evt,eventIn){if(elems$1.size===0)return;let target=evt.detail?.target||evt.target;if(!target)return;let part=eventIn?`in`:`out`;targets[part].includes(target)||targets[part].push(target),!running&&(running=!0,window.requestAnimationFrame(()=>{preventer(),running=!1}))}EVENTS_IN.forEach(evt=>document.addEventListener(evt,evt$1=>handler$1(evt$1,!0),!0)),EVENTS_OUT.forEach(evt=>document.addEventListener(evt,evt$1=>handler$1(evt$1,!1),!0))}function createHandler(data){return data.capture?evt=>{evt.detail?.doubleToSingle||(evt.preventDefault(),evt.stopImmediatePropagation(),data.timer?(clearTimeout(data.timer),data.timer=null,data.callback?.()):data.timer=setTimeout(()=>{data.timer=null;let click$1=new CustomEvent(`click`,{...evt,bubbles:!0,cancelable:!0,detail:{doubleToSingle:!0}});data.element.dispatchEvent(click$1)},DELAY))}:()=>{data.timer&&=(clearTimeout(data.timer),null);let now$1=Date.now();if(data.time&&now$1-data.time<=DELAY){data.time=0,data.callback?.();return}data.time=now$1}}function update$4(vnode,callback=void 0,mod={}){!globInit&&initGlobals();let el=vnode?.el;if(!el)return;let uid$2=vnode?.component?.uid||vnode?.key||el,capture=!!mod.capture,data=elems$1.get(uid$2)||{};data.handler&&data.element===el&&callback&&`callback`in data&&data.callback===callback&&data.capture===capture||(`element`in data||(data.element=el,data.callback=callback,data.capture=capture),data.handler&&(!callback||data.capture!==capture||data.element!==el)&&(delete data.callback,el.removeEventListener(`click`,data.handler,{capture:data.capture}),elems$1.delete(uid$2)),callback&&(data.handler?data.callback=callback:(data.capture=capture,data.handler=createHandler(data),el.addEventListener(`click`,data.handler,{capture}),elems$1.set(uid$2,data))))}var BngDoubleClick_default={mounted:(el,{value,modifiers,arg}={},vnode)=>update$4(vnode||{el},value,{capture:arg===`capture`,...modifiers}),updated:(el,{value,modifiers,arg}={},vnode)=>update$4(vnode||{el},value,{capture:arg===`capture`,...modifiers}),unmounted:(el,vnode)=>update$4(vnode||{el})},DRAG_START_EVENT_NAME=`bngDragStart`,DRAG_OVER_EVENT_NAME=`bngDragOver`,DRAG_END_EVENT_NAME=`bngDragEnd`;const DRAG_EVENTS=Object.freeze({dragStart:DRAG_START_EVENT_NAME,dragOver:DRAG_OVER_EVENT_NAME,dragEnd:DRAG_END_EVENT_NAME});var STORE_NAME=`controls`,store,DEVICE_ICONS={key:`keyboard`,mou:`mouseLMB`,vin:`smartphone2`,whe:`steeringWheelCommon`,gam:`gamepadOld`,xin:`gamepadOld`,default:`gamepad`};const CONTROL_LABELS={escape:`ESC`,enter:`⏎`,tab:`⭾`,capslock:`⇪`,backspace:`⌫`,delete:`Del`,insert:`Ins`,home:`Home`,end:`End`,pageup:`PG↑`,pagedown:`PG↓`,lshift:`L⇧`,rshift:`R⇧`,shift:`⇧`,lcontrol:`L Ctrl`,rcontrol:`R Ctrl`,lalt:`L Alt`,ralt:`R Alt`,left:`←`,right:`→`,up:`↑`,down:`↓`,space:`␣`,grave:`~`,backslash:`\\`,"/":`/`,comma:`,`,period:`.`,";":`;`,apostrophe:`'`,"[":`[`,"]":`]`,minus:`-`,"+":`NP+`,"*":`NP*`,numpaddivide:`NP/`,numpad0:`NP0`,numpad1:`NP1`,numpad2:`NP2`,numpad3:`NP3`,numpad4:`NP4`,numpad5:`NP5`,numpad6:`NP6`,numpad7:`NP7`,numpad8:`NP8`,numpad9:`NP9`,numpaddecimal:`NP.`,numpadenter:`NP⏎`,xaxis:`X Axis`,yaxis:`Y Axis`,zaxis:`Z Axis`,rzaxis:`R Z Axis`,thumblx:`L Thumb X`,thumbly:`L Thumb Y`,thumbrx:`R Thumb X`,thumbry:`R Thumb Y`};var controlLabel=control=>control.toLowerCase().split(/[ -]+/).map(ctl=>CONTROL_LABELS[ctl]||(ctl.startsWith(`button`)?`BTN`+ctl.substring(6):ctl)).join(` + `),CONTROL_ICONS={pc_mouse:{button0:`mouseLMB`,button1:`mouseRMB`,button2:`mouseMMB`,xaxis:`mouseXAxis`,yaxis:`mouseYAxis`,zaxis:`mouseWheel`},xbox:{btn_a:`xboxA`,btn_b:`xboxB`,btn_x:`xboxX`,btn_y:`xboxY`,btn_back:`xboxView`,btn_start:`xboxMenu`,btn_l:`xboxLB`,triggerl:`xboxLT`,btn_r:`xboxRB`,triggerr:`xboxRT`,dpov:`xboxDDown`,lpov:`xboxDLeft`,rpov:`xboxDRight`,upov:`xboxDUp`,thumblx:`xboxXAxis`,thumbly:`xboxYAxis`,thumbrx:`xboxXRot`,thumbry:`xboxYRot`,btn_lt:`xboxLSButton`,btn_rt:`xboxRSButton`},ps:{button1:`psCross`,button3:`psTriangle`,button0:`psSquare`,button2:`psCircle`,button8:`psCreate2`,button9:`psMenu2`,button4:`psL1`,button6:`psL2`,button5:`psR1`,button7:`psR2`,dpov:`psDDown`,lpov:`psDLeft`,rpov:`psDRight`,upov:`psDUp`,xaxis:`psLSX`,yaxis:`psLSY`,zaxis:`psRSX`,rzaxis:`psRSY`,rxaxis:`psL2`,ryaxis:`psR2`,button10:`psL3Button`,button11:`psR3Button`,button13:`psTrackpadPressCenter`}};const DEVICE_CONTROLS={pc_mouse:Object.keys(CONTROL_ICONS.pc_mouse),xbox:Object.keys(CONTROL_ICONS.xbox),ps:Object.keys(CONTROL_ICONS.ps)};var extendControlGroupNames=groups=>groups.reduce((res,group)=>(res.push(group),res.push({...group,controls:group.controls.map(ctl=>CONTROL_LABELS[ctl])}),res),[]),GROUPED_CONTROLS={pc_keyboard:extendControlGroupNames([{label:`↑↓←→`,controls:[`left`,`right`,`up`,`down`]},{label:`NP 8↑ 2↓ 4← 6→`,controls:[`numpad2`,`numpad4`,`numpad6`,`numpad8`]}]),xbox:extendControlGroupNames([{icon:`xboxDDefaultSolid`,controls:[`upov`,`dpov`,`lpov`,`rpov`]},{icon:`xboxThumbL`,controls:[`thumblx`,`thumbly`]},{icon:`xboxThumbR`,controls:[`thumbrx`,`thumbry`]}]),ps:extendControlGroupNames([{icon:`psDDefaultSolid`,controls:[`upov`,`dpov`,`lpov`,`rpov`]},{icon:`psLS`,controls:[`xaxis`,`yaxis`]},{icon:`psRS`,controls:[`zaxis`,`rzaxis`]}])},DEVICE_FAMILY={mouse:`pc_mouse`,keyboard:`pc_keyboard`,xinput:`xbox`,ps5:`ps`},CONTROL_ICON_KEYS=Object.keys(DEVICE_FAMILY),getViewerOverrides=(devName=void 0,imagePack=void 0)=>{let family;return imagePack&&(imagePack in DEVICE_FAMILY?family=DEVICE_FAMILY[imagePack]:imagePack in CONTROL_ICONS&&(family=imagePack)),!family&&devName&&(devName=CONTROL_ICON_KEYS.find(key=>devName.startsWith(key))||devName,devName in DEVICE_FAMILY?family=DEVICE_FAMILY[devName]:devName in CONTROL_ICONS&&(family=devName)),family?{family,icons:CONTROL_ICONS[family]||{},groups:GROUPED_CONTROLS[family]||[]}:null},DEVICE_ORDER=[`wheel`,`joystick`,`xinput`,`gamepad`,`mouse`,`keyboard`],makeStore=defineStore(STORE_NAME,()=>{let{events:events$3}=useBridge(),devNamesOrder=DEVICE_ORDER.map(devType=>devType+`0`),actions=ref([]),categories=ref({}),categoriesList=ref([]),bindings=ref([]),bindingsPerDevice=computed(()=>Object.fromEntries(bindings.value.map(b=>[b.devname,b]))),bindingTemplate=ref({}),controllers=ref({}),players=ref({}),lastDeviceOrder=ref([...devNamesOrder]),lastDevice=computed(()=>isKbm(lastDeviceOrder.value[0])?kbmDevNames:lastDeviceOrder.value[0]),lastControllers=computed(()=>lastDeviceOrder.value.filter(devName=>!isKbm(devName))),lastControllersSignature=computed(()=>lastControllers.value.sort().join(`::`)),isControllerUsed=computed(()=>!isKbm(lastDeviceOrder.value[0])),isControllerAvailable=computed(()=>lastDeviceOrder.value.some(devName=>!isKbm(devName))),lastDeviceSimple=computed(()=>isControllerUsed.value?lastDevice.value:null),getDevType=devName=>devName?devName.replace(/\d+$/,``):``,deviceSorter=(a$1,b)=>DEVICE_ORDER.indexOf(getDevType(a$1))-DEVICE_ORDER.indexOf(getDevType(b)),kbmDevNames=[`keyboard0`,`mouse0`].sort(deviceSorter),kbmShortNames=kbmDevNames.map(devName=>devName.slice(0,3)),isKbm=devName=>devName&&kbmShortNames.includes(devName.slice(0,3)),_receiveControlsData=data=>(controllers.value=data,_updateDeviceNotes()),_receivePlayersData=data=>players.value=data,_receiveBindingsData=_processBindingsData,_getBindingsData=()=>Lua_default.extensions.core_input_bindings.notifyUI(`Vue controls service needs the data`),connect=(state=!0)=>{let method=state?`on`:`off`;events$3[method](`ControllersChanged`,_receiveControlsData),events$3[method](`AssignedPlayersChanged`,_receivePlayersData),events$3[method](`InputBindingsChanged`,_receiveBindingsData),events$3[method](`RecentDevicesChanged`,_requestRecentDevices)},disconnect=()=>connect(!1),deviceIcon=deviceName=>DEVICE_ICONS[(deviceName||``).slice(0,3)]||DEVICE_ICONS.default;async function _requestRecentDevices(devNames=void 0){devNames||=await Lua_default.extensions.core_input_bindings.getRecentDevices(),!Array.isArray(devNames)||devNames.length===0?devNames=devNamesOrder:isKbm(devNames[0])&&(devNames=[...kbmDevNames,...devNames.filter(devName=>!isKbm(devName))]),lastDeviceOrder.value.splice(0,lastDeviceOrder.value.length,...devNames)}function*getBindingsIter(devFilter=[],useLastDeviceOrder=!1){if(!useLastDeviceOrder||devFilter.length>0)yield*bindings.value;else for(let devName of lastDeviceOrder.value){let binding=bindingsPerDevice.value[devName];binding&&(yield binding)}}let findBindingForAction=(action,devName=void 0,useLastDeviceOrder=!1)=>{let devFilter=devName?Array.isArray(devName)?devName:[devName]:[],bindingsIter=getBindingsIter(devFilter,useLastDeviceOrder);for(let binding of bindingsIter){if(devFilter.length>0&&!devFilter.includes(binding.devname))continue;let found=binding.contents.bindings.find(b=>b.action===action);if(found){let help=getBindingDetails(binding.devname,found.control,action);if(help)return help.devName=binding.devname,help.imagePack=binding.contents.imagePack,help}}},findAllBindingsForAction=(action,devName=void 0,allDevices=!1,useLastDeviceOrder=!1)=>{let res=[],devFilter=devName?Array.isArray(devName)?devName:[devName]:[],bindingsIter=getBindingsIter(devFilter,useLastDeviceOrder);for(let binding of bindingsIter){if(devFilter.length>0&&!devFilter.includes(binding.devname))continue;let matches$1=binding.contents.bindings.filter(b=>b.action===action);if(matches$1.length>0)for(let match of matches$1){let help=getBindingDetails(binding.devname,match.control,action);help&&(!allDevices&&devFilter.length===0&&devFilter.push(binding.devname),help.devName=binding.devname,help.imagePack=binding.contents.imagePack,res.push(help))}}return res},defaultBindingEntry=(action,control)=>({...bindingTemplate.value,action,control}),isAxis=(device,control)=>{let c=controllers.value[device].controls[control];return c&&c.control_type==`axis`},bindingConflicts=(device,control,action)=>bindings.value.find(b=>b.devname==device).contents.bindings.filter(b=>b.control==control).filter(b=>b.action!=action).map(b=>({...b,...getBindingDetails(device,control,b.action),resolved:!1})),captureBinding=(modifiersAllowed=!0)=>{let controlCaptured=!1,eventsRegister={},d=defer(),capturingBinding=!0;function _listener(data){if(!capturingBinding||controlCaptured)return;let devName=data.devName;eventsRegister[devName]||(eventsRegister[devName]={axis:{},key:[null,null]});let eventData=eventsRegister[devName];d.notify(eventsRegister);let valid=!1,key0,key1,key0Parts,key1Parts,genericModifierKeys=[`lalt`,`lcontrol`,`lshift`,`ralt`,`rcontrol`,`rshift`];switch(data.controlType){case`axis`:if(!eventData.axis[data.control])eventData.axis[data.control]={first:data.value,last:data.value,accumulated:0};else{let detectionThreshold=devName.startsWith(`mouse`)?1:.5;eventData.axis[data.control].accumulated+=Math.abs(eventData.axis[data.control].last-data.value)/detectionThreshold,eventData.axis[data.control].last=data.value}valid=eventData.axis[data.control].accumulated>=1;break;case`button`:case`pov`:case`key`:if(eventData.key=[eventData.key.at(-1),data.control],key0=eventData.key[0],key1=eventData.key[1],key0&&key1){let validSet=!1;key0Parts=key0.split(` `),key1Parts=key1.split(` `),key0Parts.length===1&&key1Parts.length===2&&key1Parts[1]===key0Parts[0]&&(eventData.key[1]=key0,key1=key0,data.control=key0,modifiersAllowed||(valid=!1,validSet=!0)),validSet||(valid=key0===key1,!modifiersAllowed&&(key0Parts.length===2||genericModifierKeys.includes(data.control))&&(valid=!1)),data.value===0&&(eventData.key=[null,null])}break;default:console.error(`Unrecognised raw input controlType: `+JSON.stringify(data))}valid&&data.devName.startsWith(`mouse`)&&data.control===`button1`&&(valid=!1),valid&&(controlCaptured=!0,capturingBinding=!1,data.direction=data.controlType===`axis`?Math.sign(eventData.axis[data.control].last-eventData.axis[data.control].first):0,d.resolve(data),_captureHelper.stopListening())}return Lua_default.ActionMap.enableBindingCapturing(!0),Lua_default.setCEFTyping(!0),_captureHelper.stopListening=()=>{Lua_default.ActionMap.enableBindingCapturing(!1),Lua_default.WinInput.setForwardRawEvents(!1),Lua_default.setCEFTyping(!1),events$3.off(`RawInputChanged`,_listener)},events$3.on(`RawInputChanged`,_listener),Lua_default.WinInput.setForwardRawEvents(!0),d.promise},removeBinding=(device,control,action,mockSave)=>{let deviceContents={...bindings.value.find(b=>b.devname==device).contents};deviceContents.bindings=[...deviceContents.bindings];let entryIndex=deviceContents.bindings.findIndex(b=>b.control==control&&b.action==action)||null;if(entryIndex)if(deviceContents.bindings.splice(entryIndex,1),mockSave){let deviceIndex=bindings.value.findIndex(b=>b.devname==device);bindings.value[deviceIndex].contents=deviceContents}else serializeCheck(deviceContents.name),Lua_default.extensions.core_input_bindings.saveBindingsToDisk(deviceContents)},addBinding=(device,bindingData,replace,mockSave)=>{let deviceContents={...bindings.value.find(b=>b.devname==device).contents};if(deviceContents.bindings=[...deviceContents.bindings],replace){let deprecatedIndex=deviceContents.bindings.findIndex(b=>b.control==bindingData.details.control&&b.action==bindingData.details.action);deviceContents[deprecatedIndex]=bindingData}else serializeCheck(deviceContents.name),Lua_default.extensions.core_input_bindings.saveBindingsToDisk(deviceContents)},isFFBBound=()=>{for(let i=0;i{let ffbCapable=()=>Object.values(controllers.value).some(controller=>controller.ffbAxes&&Object.keys(controller.ffbAxes).length>0);return asRef?computed(()=>ffbCapable()):ffbCapable},getIsControllerAvailable=(asRef=!1)=>asRef?isControllerAvailable:isControllerAvailable.value,isWheelFound=vendorId=>{for(let b of bindings.value)if(b.devname.slice(0,3)===`whe`&&b.contents.vidpid.slice(4,8)==vendorId)return!0;return!1};function isFFBEnabled(asRef=!1){let filter=()=>bindings.value.filter(b=>b.devname.slice(0,3)!==`xin`).some(b=>b.contents.bindings.some(binding=>binding.action===`steering`&&binding.isForceEnabled));return asRef?computed(()=>filter()):filter()}function isPidVidFound(desiredVid,desiredPid,asRef=!1){let filter=()=>bindings.value.some(b=>{let vid=desiredVid===void 0?desiredVid:b.contents.vidpid.slice(4,8),pid$1=desiredPid===void 0?desiredPid:b.contents.vidpid.slice(0,4);return vid==desiredVid&&pid$1==desiredPid});return asRef?computed(()=>filter()):filter()}function getBindingDetails(device,control,action){let actionDetails=getActionDetails(action);if(!actionDetails){console.warn(`Action details not found: `,action);return}let deviceBindings=bindings.value.find(b=>b.devname===device).contents.bindings,common={icon:deviceIcon(device),title:actionDetails.title,desc:actionDetails.desc},details=deviceBindings.find(b=>b.control===control&&b.action===action)||defaultBindingEntry(action,control),isBindingAxis=isAxis(device,control);return{...bindingTemplate.value,...details,...common,isAxis:isBindingAxis,action:actionDetails.action,actionName:actionDetails.actionName}}function getActionDetails(action){let actionDetails=actions.value[action];if(actionDetails)return{...actionDetails,action:actionDetails.actionName}}function addNewBinding(bindingData){let{devname,control,action}=bindingData,device=bindings.value.find(b=>b.devname==devname);if(!device){console.warn(`Device not found: `,devname);return}let deviceContents=device.contents;deviceContents.bindings.push({...bindingTemplate.value,...bindingData,control,action}),serializeCheck(deviceContents.name),Lua_default.extensions.core_input_bindings.saveBindingsToDisk(deviceContents)}function updateBinding(bindingData){let{devname,control,action}=bindingData,oldDevname=bindingData.oldDevname||devname,oldControl=bindingData.oldControl||control,device=bindings.value.find(b=>b.devname==oldDevname);if(!device){console.warn(`Device not found: `,oldDevname);return}let deviceContents=device.contents,deprecatedIndex=deviceContents.bindings.findIndex(b=>b.control==oldControl&&b.action==action);if(deprecatedIndex===-1){console.warn(`Binding not found: `,oldDevname,oldControl,action);return}if(devname===oldDevname)delete bindingData.oldDevname,delete bindingData.oldControl,deviceContents.bindings[deprecatedIndex]={...bindingData};else{deviceContents.bindings.splice(deprecatedIndex,1);let newDeviceContents=bindings.value.find(b=>b.devname===devname).contents;newDeviceContents.bindings.push({...bindingData,bindingTemplate:bindingTemplate.value}),serializeCheck(newDeviceContents.name),Lua_default.extensions.core_input_bindings.saveBindingsToDisk(newDeviceContents)}serializeCheck(deviceContents.name),Lua_default.extensions.core_input_bindings.saveBindingsToDisk(deviceContents)}function deleteBindings(bindingsData){let bindingsByDevname=bindingsData.reduce((acc,b)=>(acc[b.devname]=acc[b.devname]||[],acc[b.devname].push(b),acc),{});for(let devname in bindingsByDevname){let device=bindings.value.find(b=>b.devname==devname);if(!device){console.warn(`Device not found: `,devname);continue}let deviceContents=device.contents;bindingsByDevname[devname].forEach(b=>{let index=deviceContents.bindings.findIndex(binding=>binding.control==b.control&&binding.action==b.action);index!==-1&&deviceContents.bindings.splice(index,1)}),serializeCheck(deviceContents.name),Lua_default.extensions.core_input_bindings.saveBindingsToDisk(deviceContents)}}function deleteBinding({devname,control,action}){let device=bindings.value.find(b=>b.devname==devname);if(!device){console.warn(`Device not found: `,devname);return}let deviceContents=device.contents,index=deviceContents.bindings.findIndex(b=>b.control==control&&b.action==action);if(index===-1){console.warn(`Binding not found: Skipping...`,devname,control,action);return}deviceContents.bindings.splice(index,1),serializeCheck(deviceContents.name),Lua_default.extensions.core_input_bindings.saveBindingsToDisk(deviceContents)}function getAllBindingsForAction(action,devName,asRef=!1){let filteredBindings=()=>bindings.value.filter(b=>(!devName||b.devname==devName)&&b.contents.bindings.find(a$1=>a$1.action===action)).flatMap(b=>b.contents.bindings.filter(x=>x.action===action).map(x=>({...x,...getBindingDetails(b.devname,x.control,x.action),devname:b.devname,action,actionName:action})));return asRef?computed(()=>filteredBindings()):filteredBindings()}let _captureHelper={devName:null,stopListening:null};function _updateDeviceNotes(){Object.values(bindings.value).forEach(({contents:bindingContents})=>{for(let id in controllers.value){let controller=controllers.value[id];if(bindingContents.vidpid==controller.vidpid){controller.notes=bindingContents.notes;break}}})}let lastBindingsData=null;function _processBindingsData(data){let newBindingsData=JSON.stringify(data);if(lastBindingsData===newBindingsData)return;if(lastBindingsData=newBindingsData,Array.isArray(data.bindings)||(data.bindings=[]),data.bindings.forEach(device=>{Array.isArray(device.contents.bindings)||(device.contents.bindings=Object.values(device.contents.bindings))}),bindingTemplate.value=data.bindingTemplate,bindings.value=data.bindings,!data.actionCategories||!data.bindingTemplate||data.bindings.length===0){logger_default.debug(`Did not receive bindings data. Timing issue?`);return}bindings.value.sort((a$1,b)=>deviceSorter(a$1.devname,b.devname)),devNamesOrder.splice(0),kbmDevNames.splice(0);for(let binding of data.bindings){let devName=binding.devname;devNamesOrder.includes(devName)||devNamesOrder.push(devName),isKbm(devName)&&kbmDevNames.push(devName),binding.icon=deviceIcon(devName)}_requestRecentDevices();let acts={};for(let act in data.actions)acts[act]={actionName:act,...data.actions[act]};for(let cat in actions.value=acts,categories.value=data.actionCategories,categories.value)typeof categories.value[cat]==`object`&&(categories.value[cat].actions=[]);for(let act in actions.value){let obj={key:act,...actions.value[act]};actions.value[act].cat in categories.value||(categories.value[actions.value[act].cat]={order:99,icon:`symbol_exclamation`,title:`UNDEFINED CATEGORY: `+actions.value[act].cat,desc:``,actions:[]}),categories.value[actions.value[act].cat].actions.push(obj)}for(let x in categoriesList.value=[],Object.entries(categories.value).forEach(([catName,cat])=>categoriesList.value.push({key:catName,...cat})),categoriesList.value)for(let y in categoriesList.value[x].actions)for(let z in categoriesList.value[x].actions[y].titleTranslated=$translate.instant(categoriesList.value[x].actions[y].title),categoriesList.value[x].actions[y].descTranslated=$translate.instant(categoriesList.value[x].actions[y].desc),categoriesList.value[x].actions[y].tags)categoriesList.value[x].actions[y].tagsTranslated||(categoriesList.value[x].actions[y].tagsTranslated=[]),categoriesList.value[x].actions[y].tagsTranslated[z]=$translate.instant(categoriesList.value[x].actions[y].tags[z]);_updateDeviceNotes()}function makeViewerObj({deviceKey,device,action,uiEvent,imagePack,controller=!1,actionVariants=!1,useLastDevice=!1}){let viewerObj,multiDevice=!1;if(device&&Array.isArray(device)&&device.length===0&&(device=void 0),Array.isArray(device)&&(device.length===0?device=void 0:device.length===1?device=device[0]:multiDevice=!0),!device&&controller&&(device=lastControllers.value,device.length===0?device=void 0:device.length===1?device=device[0]:multiDevice=!0),uiEvent&&(action=ACTIONS_BY_UI_EVENT[uiEvent]),action?actionVariants?(viewerObj=_buildViewerObjVariants(findAllBindingsForAction(action,device,!1,useLastDevice)),actionVariants=!!viewerObj?.variants,actionVariants&&viewerObj.variants.sort((a$1,b)=>a$1.isInverted-b.isInverted)):viewerObj=findBindingForAction(action,device,useLastDevice):actionVariants=!1,deviceKey){let devName=viewerObj?.devName||(multiDevice?device[0]:device);viewerObj={icon:deviceIcon(devName),control:deviceKey,devName,imagePack:viewerObj?.imagePack||imagePack}}return viewerObj&&(_parseViewerObj(viewerObj,imagePack,actionVariants),viewerObj.variants&&viewerObj.variants.forEach(obj=>_parseViewerObj(obj,imagePack,actionVariants,device))),viewerObj}function _buildViewerObjVariants(viewerObjs){let len=viewerObjs?.length||0;if(len!==0)return len===1?viewerObjs[0]:{...viewerObjs[0],variants:viewerObjs}}let rgxCombo=/modifier(?\d+)[ -]+|[ -]*(?.+)/gi;function _parseViewerObj(viewerObj,imagePack=void 0,actionVariants=!1,devNames=void 0){let devName=viewerObj.devName;if(imagePack=viewerObj.imagePack||imagePack,!imagePack){let binding=bindings.value?.find(b=>b.devname===devName);binding?.contents?.imagePack&&(imagePack=binding.contents.imagePack),!imagePack&&devName&&(imagePack=CONTROL_ICON_KEYS.find(key=>devName.startsWith(key))),viewerObj.imagePack=imagePack}if(viewerObj.control.startsWith(`modifier`)){let matches$1=[...viewerObj.control.matchAll(rgxCombo)].map(m=>m.groups);if(matches$1.length>0){viewerObj.multiControls=[];for(let match of matches$1)if(match.mod){let modName=`customModifier`+match.mod,mod=actionVariants?_buildViewerObjVariants(findAllBindingsForAction(modName,devName,!1,!1)):findBindingForAction(modName,devName);mod||=actionVariants?_buildViewerObjVariants(findAllBindingsForAction(modName,devNames,!1,!1)):findBindingForAction(modName,devNames),mod&&viewerObj.multiControls.push(mod)}else viewerObj.multiControls.push({devName,control:match.key,icon:viewerObj.icon,imagePack})}}_addCustomInfo(viewerObj),viewerObj.multiControls&&viewerObj.multiControls.forEach(_addCustomInfo)}function _addCustomInfo(viewerObj){let devOverrides=getViewerOverrides(viewerObj.devName,viewerObj.imagePack);viewerObj.family=devOverrides?.family;let ownIcon=devOverrides?.icons[viewerObj.control];viewerObj.special=!!ownIcon,viewerObj.ownGroups=devOverrides?.groups,viewerObj.special?viewerObj.ownIcon=ownIcon:viewerObj.control=controlLabel(viewerObj.control)}return connect(),_getBindingsData(),{categories:computed(()=>categories.value),categoriesList:computed(()=>categoriesList.value),controllers:computed(()=>controllers.value),players:computed(()=>players.value),bindingTemplate:computed(()=>bindingTemplate.value),lastDevice:lastDeviceSimple,lastDevices:lastDeviceOrder,lastControllers,lastControllersSignature,isControllerAvailable,isControllerUsed,showIfController:isControllerUsed,focusIfController:isControllerAvailable,addNewBinding,connect,deleteBinding,deleteBindings,disconnect,deviceIcon,findBindingForAction,findAllBindingsForAction,getActionDetails,getBindingDetails,getAllBindingsForAction,defaultBindingEntry,isAxis,bindingConflicts,captureBinding,removeBinding,addBinding,isFFBBound,isFFBEnabled,isFFBCapable,isGamepadAvailable:getIsControllerAvailable,isWheelFound,isPidVidFound,makeViewerObj,updateBinding}}),useStore=()=>store||=makeStore(),controls_default=useStore,direction=`right`,focusClass=`focus-visible`,isController$1={value:!1},now=()=>new Date().getTime(),inited=!1,gamepadInited=!1,elms$3=[];function setFocus(elm,enable=!0){if(enable){if(elm.classList.add(focusClass),elm===document.activeElement)return}else if(elm.classList.remove(focusClass),elm!==document.activeElement)return;try{enable&&focusOnElement(elm)}catch{}}function setFocusExternal(elm,enable=!0,attemptScroll=!0){return elm?(!gamepadInited&&gamepadInit(),enable&&!isController$1.value?(attemptScroll&&isOccluded(elm,!0)&&scrollFix({dom:elm,rect:elm.getBoundingClientRect()},`down`),!1):(setFocus(elm,enable),!0)):!1}function ensureFocus(elm,onNextTick=!0){elm&&(!gamepadInited&&gamepadInit(),isController$1.value&&document.activeElement===elm&&!elm.classList.contains(focusClass)&&(onNextTick?nextTick(()=>elm&&setFocus(elm)):setFocus(elm)))}function gamepadInit(){gamepadInited||(gamepadInited=!0,isController$1=storeToRefs(controls_default()).focusIfController)}function init$1(){inited||(inited=!0,gamepadInit(),watch(isController$1,val=>{let active=document.activeElement;if(isNavigable$1(active)){let focused$1=active.classList.contains(focusClass);val&&!focused$1?setFocus(active,!0):!val&&focused$1&&setFocus(active,!1);return}if(val){if(priorityFocus())return;navigate(collectRects(direction),direction)&&window.requestAnimationFrame(()=>setFocus(document.activeElement,!0))}}))}function priorityFocus(){collectRects(direction);for(let{elm}of elms$3)if(isNavigable$1(elm))return setFocus(elm,!0),!0;return!1}function wantsFocus(elm,priority){inited||init$1();let dat=elms$3.find(itm=>itm.element===elm)||{elm,time:now()},isNew=!(`priority`in dat);if(typeof priority!=`number`||isNaN(priority)){if(!isNew){let idx=elms$3.findIndex(itm=>itm.elm===elm);idx>-1&&elms$3.splice(idx,1)}return}dat.priority=priority,isNew&&elms$3.push(dat),elms$3.sort((a$1,b)=>b.priority-a$1.priority||b.time-a$1.time),collectRects(direction,elm.parentNode),isNew&&isController$1.value&&!isNavigable$1(document.activeElement)&&priorityFocus()}function unwantsFocus(elm){let idx=elms$3.findIndex(itm=>itm.elm===elm);idx!==-1&&(elms$3.splice(idx,1),isController$1.value&&!isNavigable$1(document.activeElement)&&priorityFocus())}function initFocusVisible(){let raf=window.requestAnimationFrame,curFocused=null,holdFocus=!1;function notify(type,target,relatedTarget){let evt=new CustomEvent(`uinav-`+type,{bubbles:!0,cancelable:!0,detail:{target,relatedTarget}});document.dispatchEvent(evt)}function procFocus(target,relatedTarget){if(!(target&&target===curFocused)&&(relatedTarget===target&&(relatedTarget=void 0),relatedTarget&&doBlur(relatedTarget),curFocused&&=((!relatedTarget||relatedTarget!==curFocused)&&(relatedTarget=curFocused),doBlur(curFocused),null),target))try{if(target.disabled)return;if(`tabIndex`in target){if(typeof target.tabIndex==`string`&&target.tabIndex===`-1`||typeof target.tabIndex==`number`&&target.tabIndex===-1||target.tabIndex===``)return}else if(`contentEditable`in target){if(typeof target.contentEditable==`string`&&target.contentEditable!==`true`||typeof target.contentEditable==`boolean`&&!target.contentEditable)return}else return;let style=window.getComputedStyle(target);if(style.display===`none`||style.visibility===`hidden`||style.pointerEvents===`none`)return;if(isController$1.value&&target.classList.add(focusClass),curFocused=target,focusRegistry.includes(target)||focusRegistry.push(target),document.activeElement!==curFocused){holdFocus=!0;let holdFocusCounter=0;raf(function check(){!curFocused||holdFocusCounter>10||document.activeElement===curFocused?(holdFocus=!1,!curFocused||target!==curFocused?doBlur(target):notify(`focus`,curFocused,relatedTarget)):(holdFocusCounter++,curFocused.focus(),raf(check))})}else notify(`focus`,target,relatedTarget)}catch{}}function doBlur(target){if(target&&!(holdFocus&&target===curFocused))try{target.classList.remove(focusClass),target===curFocused&&(curFocused=null);let idx=focusRegistry.indexOf(target);idx!==-1&&(focusRegistry.splice(idx,1),notify(`blur`,target))}catch{}}document.addEventListener(`focusin`,evt=>procFocus(evt.target,evt.relatedTarget),!0),document.addEventListener(`focusout`,evt=>doBlur(evt.target),!0);let focusRegistry=[],originalFocus=HTMLElement.prototype.focus.__original__||HTMLElement.prototype.focus,originalBlur=HTMLElement.prototype.blur.__original__||HTMLElement.prototype.blur;HTMLElement.prototype.focus=function(...args){let target=this,prevFocused=document.activeElement;prevFocused.classList.contains(focusClass)||(focusRegistry.length>0?focusRegistry.forEach(elm=>elm!==target&&elm.blur()):document.querySelectorAll(`.`+focusClass).forEach(elm=>elm!==target&&doBlur(elm))),originalFocus.apply(target,args),procFocus(target,prevFocused)},HTMLElement.prototype.blur=function(...args){doBlur(this),originalBlur.apply(this,args)},HTMLElement.prototype.focus.__original__=originalFocus,HTMLElement.prototype.blur.__original__=originalBlur}var EVENT_CALLS=Object.entries({focus:[`uinav-focus`,`focus`,`focusin`,`click`],hide:[`mouseenter`],show:[`uinav-blur`,`blur`,`focusout`,`mouseleave`]}).reduce((res,[name,events$3])=>(events$3.forEach(event=>res[event]=name),res),{}),ID$1=`__bngFocusCapture`,elms$2={},isController;function setupController(){isController||(isController=storeToRefs(controls_default()).isControllerUsed,watch(isController,val=>{for(let data of Object.values(elms$2))val?data.show():data.hide()}))}function getClosestNavigable(elm){let target=collectRects(`down`,elm).down[0]?.dom;return target&&isNavigable$1(target)?target:null}function update$3(data,value,firstTime=!1){if(typeof value==`function`?(data.handler=()=>{let elm=value(data.parent);return elm?.$el||elm},delete data.disabled):typeof value==`boolean`&&!value?data.disabled=!0:delete data.disabled,data.disabled){if(data.hide(),!firstTime)for(let event in data.capture.remove(),EVENT_CALLS)data.parent.removeEventListener(event,data[EVENT_CALLS[event]])}else for(let event in data.parent.appendChild(data.capture),data.show(),EVENT_CALLS)data.parent.addEventListener(event,data[EVENT_CALLS[event]])}var BngFocusCapture_default={mounted(elm,{arg,value}){setupController();let id=uniqueId(ID$1),parent=elm,capture=document.createElement(`div`),data={id,shown:!0,parent,capture,handler:()=>getClosestNavigable(data.parent)};elms$2[id]=data,parent[ID$1]=id,capture.className=`bng-focus-capture`,capture.style.setProperty(`position`,`absolute`,`important`),capture.style.setProperty(`display`,`block`,`important`),capture.style.setProperty(`top`,`0%`,`important`),capture.style.setProperty(`left`,`0%`,`important`),capture.style.setProperty(`width`,`100%`,`important`),capture.style.setProperty(`height`,`100%`,`important`),capture.style.setProperty(`z-index`,arg&&/^\d+$/.test(arg)?arg:`1000`,`important`),capture.style.setProperty(`pointer-events`,`all`,`important`),capture.setAttribute(`bng-nav-item`,``),capture.setAttribute(`tabindex`,`0`),data.focus=()=>{if(data.hide(),!isController.value)return;let active=document.activeElement;if(!(active!==data.capture&&data.parent.contains(active))&&data.handler){let elm$1=data.handler(data.parent);elm$1&&nextTick(()=>setFocusExternal(elm$1))}},data.hide=()=>{data.shown&&(data.shown=!1,capture.style.setProperty(`pointer-events`,`none`,`important`))},data.show=evt=>{if(data.shown||(data.shown=!0,data.disabled||!isController.value))return;let active=document.activeElement;if(data.parent.contains(active))return;let target=evt?.relatedTarget||evt?.target||active;data.parent.contains(target)||capture.style.setProperty(`pointer-events`,`all`,`important`)},update$3(data,value,!0)},updated(elm,{arg,value}){let id=elm[ID$1];if(!id)return;let data=elms$2[id];data&&update$3(data,value)},unmounted(elm){let id=elm[ID$1];if(!id)return;delete elm[ID$1];let data=elms$2[id];if(data){for(let event in data.capture.remove(),EVENT_CALLS)data.parent.removeEventListener(event,data[EVENT_CALLS[event]]);delete elms$2[id]}}},BngFocusIf_default=(el,{value})=>value&&nextTick(()=>{let shouldFocus=typeof value==`object`?value.value:value,findNavItem=typeof value==`object`?value.findNavItem:!1;if(!el||!shouldFocus)return;let targetEl=el;if(findNavItem){let navItems=el.querySelectorAll(`[is-bng-panel], [bng-nav-item], [ng-click], [href], [bng-all-clicks], [bng-all-clicks-no-nav], [ui-sref], input, textarea, button, md-option, md-slider, md-select, md-checkbox`);navItems&&navItems.length>0&&(targetEl=navItems[0])}targetEl.focus();let blur$1=()=>{targetEl.classList.remove(`focus-visible`),targetEl.removeEventListener(`blur`,blur$1)};targetEl.addEventListener(`blur`,blur$1),targetEl.classList.add(`focus-visible`)}),elems=new WeakMap,curHorizontal=0,curVertical=0;function updateGE(horizontal=0,vertical=0){curHorizontal=horizontal,curVertical=vertical,bngApi.engineLua(`scenetree.OnlyGui:setFrustumCameraCenterOffset(Point2F(${horizontal}, ${vertical}))`)}var moveSpeed=1,smoothingUpdate;function updateGEsmooth(horizontal=0,vertical=0){if(smoothingUpdate){smoothingUpdate(horizontal,vertical);return}let dirH=1,dirV=1;function setDir(){dirH=horizontal>=curHorizontal?1:-1,dirV=vertical>=curVertical?1:-1}setDir(),smoothingUpdate=(h$1=0,v=0)=>{horizontal=h$1,vertical=v,setDir()},window.requestAnimationFrame(function(ms){let speed=moveSpeed/1e3,movH=curHorizontal,movV=curVertical,lastTime=ms,smoother=0;window.requestAnimationFrame(function step(ms$1){if(curHorizontal===horizontal&&curVertical===vertical){smoothingUpdate=null;return}smoother+=(ms$1-lastTime-smoother)*.02,lastTime=ms$1;let moveDelta=smoother*speed;movH+=moveDelta*dirH,movV+=moveDelta*dirV,(dirH>0&&movH>horizontal||dirH<0&&movH0&&movV>vertical||dirV<0&&movV{let updateDebounce=debounce(updateFrustum,50),updateWrapper=()=>updateDebounce(),resizeObserver=new ResizeObserver(updateWrapper);resizeObserver.observe(el),elems.set(el,{updateFrustum:updateDebounce,destroy:()=>{resizeObserver.disconnect(),window.removeEventListener(`resize`,updateWrapper),elems.delete(el),updateDebounce(0,0)}}),window.addEventListener(`resize`,updateWrapper);let curDirection=binding.arg||`left`,curSmooth=binding.modifiers.smooth,curState=binding.value===void 0?!0:!!binding.value;function updateFrustum(direction$1,enabled,smooth){direction$1||=curDirection,[`left`,`right`,`up`,`down`].includes(direction$1)?curDirection=direction$1:(console.error(`Frustum mover only supports left/right/up/down directions`),enabled=!1),typeof enabled!=`boolean`&&(enabled=curState),curState=enabled,typeof smooth!=`boolean`&&(smooth=curSmooth),curSmooth=smooth;let updater=smooth?updateGEsmooth:updateGE;if(!enabled){updater();return}let side=direction$1===`left`||direction$1===`right`?`width`:`height`,screenSize=window.screen[side],movePower=el.getBoundingClientRect()[side]/screenSize*power;movePower<.001?movePower=0:(direction$1===`left`||direction$1===`down`)&&(movePower=-movePower),updater(direction$1===`left`||direction$1===`right`?movePower:0,direction$1===`up`||direction$1===`down`?movePower:0)}},updated:(el,binding)=>{let itm=elems.get(el);itm&&itm.updateFrustum(binding.arg,!!binding.value,!!binding.modifiers.smooth)},unmounted:(el,binding)=>{let itm=elems.get(el);itm&&itm.destroy()}},highlighter=[``,``],rgxSanitize=str=>str.replace(/[\\[]\?:.\*\+\-]/g,`\\$1`),BngHighlighter_default=(el,binding,vnode,prevVnode)=>{if(vnode.children.length!==1||vnode.children[0].type.toString()!==`Symbol(v-txt)`){el.__highlightwarned||(el.__highlightwarned=!0,console.warn(`Only a single inner text v-node supported`,el));return}let res=vnode.children[0].children.replace(//g,`>`),highlight=binding.value;if(highlight){let rgx;if(highlight instanceof RegExp)highlight.test(res)&&(rgx=highlight);else{let searchCase=str=>binding.modifiers.case?str:str.toLowerCase(),searchSource=searchCase(res),checkString=str=>searchSource.indexOf(str)>-1,buildRegexp=str=>RegExp(`(${str})`,`gm`+(binding.modifiers.case?``:`i`));if(typeof highlight==`object`&&Array.isArray(highlight)){let found=[];for(let str of highlight)str&&(str=searchCase(String(str)),checkString(str)&&found.push(str));found.length>0&&(rgx=buildRegexp(found.map(str=>rgxSanitize(str)).join(`|`)))}else{let str=searchCase(String(highlight));checkString(str)&&(rgx=buildRegexp(rgxSanitize(str)))}}rgx&&(res=res.replace(rgx,`${highlighter[0]}$1${highlighter[1]}`))}el.innerHTML!==res&&(el.innerHTML=res)},ExecQueue=class{resolution={rejectThis:`rejectThis`,rejectOthers:`rejectOthers`,resolveThis:`resolveThis`,resolveOthers:`resolveOthers`,replaceWithReject:`replaceWithReject`,replaceWithResolve:`replaceWithResolve`,merge:`merge`};_queue=[];_processing=!1;_tick=0;_tickFunc=nextTick;_runningCount=0;_concurrency=1;constructor(tick=0,concurrency=1){this.tick=tick,this.concurrency=concurrency}get tick(){return this._tick}set tick(val){typeof val!=`number`&&(val=0),this._tick=val,this._tickFunc=val===0?func=>nextTick(func.bind(this)):func=>setTimeout(func.bind(this),this._tick)}get concurrency(){return this._concurrency}set concurrency(val){(typeof val!=`number`||val<1)&&(val=1),this._concurrency=val}shuffle(){this._shuffle=!0}async process(){if(!(this._processing||this._queue.length===0))for(this._processing=!0,this._shuffle&&=(this._queue=this._queue.sort(()=>Math.random()-.5),!1);this._runningCount0;){let item=this._queue.shift();if(!item)break;item.running=!0,this._runningCount++,this._processItem(item)}}async _processItem(item){try{let result=await item.func(...item.args);item.resolves?.forEach(resolve$1=>resolve$1?.(result))}catch(err){item.rejects.length>0?item.rejects?.forEach(reject=>reject?.(err)):console.error(err)}finally{this._runningCount--,this._tickFunc(()=>{this._processing=!1,this.process()})}}enqueue(name,func,args=[],conflicts={},resolve$1=null,reject=null){if(typeof conflicts==`object`&&Object.keys(conflicts).length>0)for(let i=this._queue.length-1;i>=0;i--){let item=this._queue[i];if(item.name in conflicts)switch(conflicts[item.name]){case this.resolution.merge:resolve$1&&item.resolves.push(resolve$1),reject&&item.rejects.push(reject);return;default:case this.resolution.rejectThis:reject?.(Error(`Function ${item.name} is rejected due to conflict`));return;case this.resolution.resolveThis:resolve$1?.();return;case this.resolution.rejectOthers:item.running||(item.rejects?.forEach(reject$1=>reject$1?.(Error(`Function ${item.name} is rejected due to conflict`))),this._queue.splice(i,1));break;case this.resolution.resolveOthers:case this.resolution.replaceWithResolve:item.running||(item.resolves?.forEach(resolve$2=>resolve$2?.()),this._queue.splice(i,1));break;case this.resolution.replaceWithReject:item.rejects?.forEach(reject$1=>reject$1?.(Error(`Function ${item.name} is replaced`))),this._queue.splice(i,1);break}}this._queue.push({name,func,args,resolves:[resolve$1],rejects:[reject]}),this._processing||(this._processing=!0,this._tickFunc(()=>{this._processing=!1,this.process()}))}promise(name,func,args=[],conflicts={}){return new Promise((resolve$1,reject)=>this.enqueue(name,func,args,conflicts,resolve$1,reject))}wrap(name,func,conflicts={}){return async(...args)=>await this.promise(name,func,args,conflicts)}},MAX_SIZE=500,OVERSIZE_LIMIT=100,CONCURRENCY_LIMIT=20,QUEUE_INTERVAL$1=0,OBS_ID=`__bngLazyImage`,cache=new Map,queue=new ExecQueue(QUEUE_INTERVAL$1,CONCURRENCY_LIMIT),observer$1=new IntersectionObserver(entries=>{for(let entry of entries)if(entry.isIntersecting){observer$1.unobserve(entry.target);let data=entry.target[OBS_ID];data.observed&&(data.observed=!1,queue.shuffle(),process(entry.target,data))}}),loadImage=url=>new Promise((resolve$1,reject)=>{let img=new Image;img.onload=async()=>{try{if(cache.sizeMAX_SIZE||img.height>MAX_SIZE)){let ratio=img.width/img.height,width$1,height$1;img.width>img.height?(width$1=MAX_SIZE,height$1=MAX_SIZE/ratio):(height$1=MAX_SIZE,width$1=MAX_SIZE*ratio);let cvs=new OffscreenCanvas(width$1,height$1);cvs.getContext(`2d`).drawImage(img,0,0,width$1,height$1);let bmp=await createImageBitmap(cvs);cache.set(img.src,{url,bmp})}}catch(err){reject(err)}resolve$1({url})},img.onerror=()=>reject(Error(`Failed to load image`)),img.src=url});function process(el,data){let{url,callback}=data,apply$1=imgData=>callback(el,imgData.url,imgData.bmp);if(cache.has(url)){apply$1(cache.get(url));return}apply$1(emptyImage),queue.enqueue(url,loadImage,[url],{url:queue.resolution.merge},data$1=>{apply$1(data$1)},err=>{logger_default.error(err),apply$1(url)})}function update$2(el,{arg,value}){let data={url:void 0,target:`src`,callback:void 0};if(typeof value==`string`)data.url=value;else if(typeof value==`object`&&!Array.isArray(value)&&value.url){if(data.url=value.url,data.target=value.target,data.callback=typeof value.callback==`function`?value.callback:void 0,!data.url||!data.target&&!data.callback)return}else return;if(el[OBS_ID]){let old=el[OBS_ID];if(old.observed&&observer$1.unobserve(el),old.url===data.url&&old.target===data.target&&old.callback===data.callback)return}el[OBS_ID]=data,arg===`observe`?(data.observed=!0,observer$1.observe(el)):process(el,data)}var BngLazyImage_default={mounted:update$2,updated:update$2,unmounted(el){el[OBS_ID]&&(el[OBS_ID].observed&&observer$1.unobserve(el),delete el[OBS_ID])}},elms$1=new Map,observer=new ResizeObserver(observed$1);function observed$1(entries){for(let entry of entries)elms$1.has(entry.target)?update$1(entry.target):observer.unobserve(entry.target)}function update$1(elm,data=void 0){if(data||=elms$1.get(elm),data)if(isVisibleFast(elm)){let screen$1={width:window.innerWidth,height:window.innerHeight,scrollX:window.scrollX,scrollY:window.scrollY},rect=elm.getBoundingClientRect(),metrics={x:rect.left+screen$1.scrollX,y:rect.top+screen$1.scrollY,width:rect.width,height:rect.height};data.set(data.id,metrics.x/screen$1.width,metrics.y/screen$1.height,metrics.width/screen$1.width,metrics.height/screen$1.height)}else data.reset(data.id)}var UINAV_PROP=`__BngOnUiNav`,_handlerToElement=handler$1=>{let element;switch(typeof handler$1){case`string`:element=document.querySelectorAll(handler$1)[0];break;case`object`:element=handler$1;break}return element instanceof HTMLElement&&element},_generateSignature=(vnode,eventNames,modifiers)=>`${UINAV_PROP}[${vnode.ctx.uid}]:`+(typeof eventNames==`string`?eventNames.split(`,`):eventNames).sort().join(`,`)+[``,...Object.keys(modifiers)].sort().join(`.`),_normalizedEvents=eventNames=>eventNames===`*`?[]:eventNames.split(`,`),_getDirData=(element,signature)=>element[UINAV_PROP]?.find(dir=>dir.signature===signature);function setup$2(data,element,vnode){if(data.modifiers.asMouse){if(data.eventNames.find(name=>!isOnOffEvent(name))){window.BNG_Logger&&window.BNG_Logger.error(`UINav directive asMouse modifier is only supported for on/off type events`,element);return}setupAsMouse(data,vnode)}typeof data.handler==`function`&&(applyUiNav(data,element),applyTracker(data,element))}function setupAsMouse(data,vnode){let handlerElement=_handlerToElement(data.handler);handlerElement&&(vnode={el:handlerElement});let eventFirer$1=vnode.ctx?.exposed?.fireEvent||eventDispatcherForElement(vnode.el),checkElementDisabled=vnode.ctx?.exposed?.getDisabledState||(()=>vnode.el.hasAttribute(`disabled`));delete data.modifiers.down,delete data.modifiers.up,data.mousedownActive=!1,data.handler=({detail})=>{if(checkElementDisabled())return;let fromControllerMarker={fromController:detail};return detail.value?(eventFirer$1(`mousedown`,fromControllerMarker),data.mousedownActive=!0):(eventFirer$1(`mouseup`,fromControllerMarker),data.mousedownActive&&(data.mousedownActive=!1,eventFirer$1(`click`,fromControllerMarker))),!!data.modifiers.bubble}}function applyTracker(data,element){let uiNavTracker=useUINavTracker();data.modifiers.focusRequired?(element.addEventListener(`focusin`,evt=>{let prevDirs=evt.relatedTarget?.[UINAV_PROP];if(prevDirs)for(let dir of prevDirs)dir.modifiers.focusRequired&&(dir.tracked.forEach(name=>uiNavTracker.removeEvent(name,dir.signature,evt.relatedTarget)),dir.tracked=[]);let cur=_getDirData(element,data.signature);cur&&(cur.tracked.lengthuiNavTracker.updateEvent(name,cur.signature,element,{active:cur.modifiers.active,nogroup:cur.modifiers.nogroup})),cur.tracked=[...cur.eventNames]))}),element.addEventListener(`focusout`,evt=>{let cur=_getDirData(element,data.signature);if(!cur||cur.tracked.length>0)return;let nextDirs=evt.relatedTarget?.[UINAV_PROP];(!nextDirs||!nextDirs.some(directive=>directive.modifiers.focusRequired))&&(cur.tracked.forEach(name=>uiNavTracker.removeEvent(name,cur.signature,element)),cur.tracked=[])})):(data.eventNames.forEach(name=>uiNavTracker.updateEvent(name,data.signature,element,{active:data.modifiers.active,nogroup:data.modifiers.nogroup})),data.tracked=[...data.eventNames])}function applyUiNav(data,element){let valueChecker;data.modifiers.down?valueChecker=checkOn:data.modifiers.up?valueChecker=0:!data.modifiers.asMouse&&!data.eventNames.find(name=>!isOnOffEvent(name))&&(valueChecker=checkOn),data.uiNavHandler=handlers_default.add(element,{name:name=>data.eventNames.includes(name),value:valueChecker,modified:data.modifiers.modified||!1,focusRequired:data.modifiers.focusRequired?element:void 0},data.handler),element.setAttribute(UI_EVENT_ATTR,``)}function mounted$1(element,{arg:eventNames,value:handler$1,modifiers},vnode){modifiers||={};let storage=element[UINAV_PROP]||(element[UINAV_PROP]=[]),signature=_generateSignature(vnode,eventNames,modifiers),data=storage.find(dir=>dir.signature===signature);data?window.BNG_Logger&&window.BNG_Logger.error(`Conflicting vBngOnUiNav directive on element`,element):(data={signature,eventNames:_normalizedEvents(eventNames),modifiers,handler:handler$1,uiNavHandler:null,mousedownActive:!1,tracked:[]},storage.push(data)),setup$2(data,element,vnode)}function updated$1(element,{arg:eventNames,value:handler$1,modifiers},vnode){modifiers||={};let data=_getDirData(element,_generateSignature(vnode,eventNames,modifiers));if(!data)return;typeof data.uiNavHandler==`function`&&handlers_default.remove(element,data.uiNavHandler);let normalizedEvents=_normalizedEvents(eventNames),oldEvents=data.tracked.filter(name=>!normalizedEvents.includes(name));if(oldEvents.length>0){let uiNavTracker=useUINavTracker();oldEvents.forEach(name=>uiNavTracker.removeEvent(name,data.signature,element)),data.tracked=data.tracked.filter(name=>normalizedEvents.includes(name))}data.eventNames=normalizedEvents,data.modifiers=modifiers,data.handler=handler$1,data.uiNavHandler=null,setup$2(data,element,vnode)}function dispose$1(element){let storage=element[UINAV_PROP];if(!storage)return;let uiNavTracker=useUINavTracker();storage.forEach(directive=>{directive.tracked.length>0&&directive.tracked.forEach(name=>uiNavTracker.removeEvent(name,directive.signature,element)),directive.uiNavHandler&&handlers_default.remove(element,directive.uiNavHandler)}),element.removeAttribute(UI_EVENT_ATTR),delete element[UINAV_PROP]}var BngOnUiNav_default={mounted:mounted$1,updated:updated$1,beforeUnmount:dispose$1},DIRECTIONS={horizontal:{[UI_EVENTS.focus_l]:-1,[UI_EVENTS.focus_r]:1},vertical:{[UI_EVENTS.focus_d]:-1,[UI_EVENTS.focus_u]:1}},HOLD_DELAY=400,REPEAT_INTERVAL=100,ELEMENT_FLAG=`__BNG_ONUINAVFOCUS`,BngOnUiNavFocus_default={mounted:(element,binding,vnode)=>{if(!binding.value)return;let opts={direction:binding.arg||`horizontal`,repeat:!!binding.modifiers.repeat,holdDelay:HOLD_DELAY,repeatInterval:REPEAT_INTERVAL,min:-1/0,max:1/0,step:1,value:null,callback:null,...typeof binding.value==`object`?binding.value:typeof binding.value==`function`?{callback:binding.value}:{}};!opts.events&&(opts.events=DIRECTIONS[opts.direction]);function process$1(evt){let detail=evt.fromController||evt.detail;if(!detail||!(detail.name in opts.events))return;let dir=opts.events[detail.name],val;if(typeof opts.value==`function`){let cur=opts.value(),res=cur+(typeof opts.step==`function`?opts.step():opts.step)*dir;dir<0&&res0&&res>opts.max&&(res=opts.max);let precision=10**(opts.step+`.`).split(/[.,]/)[1].length;res=precision>0?Math.round(res*precision)/precision:Math.round(res),cur===res?dir=0:val=res}dir&&opts.callback&&opts.callback(dir,val)}let dirUINav={arg:Object.keys(opts.events).join(`,`),modifiers:{focusRequired:!0,asMouse:!0}},dirClick={value:{clickCallback:process$1,holdCallback:opts.repeat?process$1:void 0,holdDelay:HOLD_DELAY,repeatInterval:REPEAT_INTERVAL}};BngOnUiNav_default.mounted(element,dirUINav,vnode),BngClick_default.mounted(element,dirClick,vnode),element[ELEMENT_FLAG]=!0},beforeUnmount:element=>{element[ELEMENT_FLAG]&&(BngClick_default.beforeUnmount(element),BngOnUiNav_default.beforeUnmount(element))}},DEFAULT_OPTS={intiallyOpen:!1,navEventToOpen:UI_EVENTS.ok,navEventToClose:UI_EVENTS.back},min=Math.min,max=Math.max,round$1=Math.round,floor=Math.floor,createCoords=v=>({x:v,y:v}),oppositeSideMap={left:`right`,right:`left`,bottom:`top`,top:`bottom`},oppositeAlignmentMap={start:`end`,end:`start`};function clamp$1(start,value,end){return max(start,min(value,end))}function evaluate(value,param){return typeof value==`function`?value(param):value}function getSide(placement){return placement.split(`-`)[0]}function getAlignment(placement){return placement.split(`-`)[1]}function getOppositeAxis(axis){return axis===`x`?`y`:`x`}function getAxisLength(axis){return axis===`y`?`height`:`width`}var yAxisSides=new Set([`top`,`bottom`]);function getSideAxis(placement){return yAxisSides.has(getSide(placement))?`y`:`x`}function getAlignmentAxis(placement){return getOppositeAxis(getSideAxis(placement))}function getAlignmentSides(placement,rects,rtl){rtl===void 0&&(rtl=!1);let alignment=getAlignment(placement),alignmentAxis=getAlignmentAxis(placement),length=getAxisLength(alignmentAxis),mainAlignmentSide=alignmentAxis===`x`?alignment===(rtl?`end`:`start`)?`right`:`left`:alignment===`start`?`bottom`:`top`;return rects.reference[length]>rects.floating[length]&&(mainAlignmentSide=getOppositePlacement(mainAlignmentSide)),[mainAlignmentSide,getOppositePlacement(mainAlignmentSide)]}function getExpandedPlacements(placement){let oppositePlacement=getOppositePlacement(placement);return[getOppositeAlignmentPlacement(placement),oppositePlacement,getOppositeAlignmentPlacement(oppositePlacement)]}function getOppositeAlignmentPlacement(placement){return placement.replace(/start|end/g,alignment=>oppositeAlignmentMap[alignment])}var lrPlacement=[`left`,`right`],rlPlacement=[`right`,`left`],tbPlacement=[`top`,`bottom`],btPlacement=[`bottom`,`top`];function getSideList(side,isStart,rtl){switch(side){case`top`:case`bottom`:return rtl?isStart?rlPlacement:lrPlacement:isStart?lrPlacement:rlPlacement;case`left`:case`right`:return isStart?tbPlacement:btPlacement;default:return[]}}function getOppositeAxisPlacements(placement,flipAlignment,direction$1,rtl){let alignment=getAlignment(placement),list=getSideList(getSide(placement),direction$1===`start`,rtl);return alignment&&(list=list.map(side=>side+`-`+alignment),flipAlignment&&(list=list.concat(list.map(getOppositeAlignmentPlacement)))),list}function getOppositePlacement(placement){return placement.replace(/left|right|bottom|top/g,side=>oppositeSideMap[side])}function expandPaddingObject(padding){return{top:0,right:0,bottom:0,left:0,...padding}}function getPaddingObject(padding){return typeof padding==`number`?{top:padding,right:padding,bottom:padding,left:padding}:expandPaddingObject(padding)}function rectToClientRect(rect){let{x,y,width:width$1,height:height$1}=rect;return{width:width$1,height:height$1,top:y,left:x,right:x+width$1,bottom:y+height$1,x,y}}function computeCoordsFromPlacement(_ref,placement,rtl){let{reference,floating}=_ref,sideAxis=getSideAxis(placement),alignmentAxis=getAlignmentAxis(placement),alignLength=getAxisLength(alignmentAxis),side=getSide(placement),isVertical=sideAxis===`y`,commonX=reference.x+reference.width/2-floating.width/2,commonY=reference.y+reference.height/2-floating.height/2,commonAlign=reference[alignLength]/2-floating[alignLength]/2,coords;switch(side){case`top`:coords={x:commonX,y:reference.y-floating.height};break;case`bottom`:coords={x:commonX,y:reference.y+reference.height};break;case`right`:coords={x:reference.x+reference.width,y:commonY};break;case`left`:coords={x:reference.x-floating.width,y:commonY};break;default:coords={x:reference.x,y:reference.y}}switch(getAlignment(placement)){case`start`:coords[alignmentAxis]-=commonAlign*(rtl&&isVertical?-1:1);break;case`end`:coords[alignmentAxis]+=commonAlign*(rtl&&isVertical?-1:1);break}return coords}var computePosition$1=async(reference,floating,config)=>{let{placement=`bottom`,strategy=`absolute`,middleware=[],platform:platform$1}=config,validMiddleware=middleware.filter(Boolean),rtl=await(platform$1.isRTL==null?void 0:platform$1.isRTL(floating)),rects=await platform$1.getElementRects({reference,floating,strategy}),{x,y}=computeCoordsFromPlacement(rects,placement,rtl),statefulPlacement=placement,middlewareData={},resetCount=0;for(let i=0;i({name:`arrow`,options,async fn(state){let{x,y,placement,rects,platform:platform$1,elements,middlewareData}=state,{element,padding=0}=evaluate(options,state)||{};if(element==null)return{};let paddingObject=getPaddingObject(padding),coords={x,y},axis=getAlignmentAxis(placement),length=getAxisLength(axis),arrowDimensions=await platform$1.getDimensions(element),isYAxis=axis===`y`,minProp=isYAxis?`top`:`left`,maxProp=isYAxis?`bottom`:`right`,clientProp=isYAxis?`clientHeight`:`clientWidth`,endDiff=rects.reference[length]+rects.reference[axis]-coords[axis]-rects.floating[length],startDiff=coords[axis]-rects.reference[axis],arrowOffsetParent=await(platform$1.getOffsetParent==null?void 0:platform$1.getOffsetParent(element)),clientSize=arrowOffsetParent?arrowOffsetParent[clientProp]:0;(!clientSize||!await(platform$1.isElement==null?void 0:platform$1.isElement(arrowOffsetParent)))&&(clientSize=elements.floating[clientProp]||rects.floating[length]);let centerToReference=endDiff/2-startDiff/2,largestPossiblePadding=clientSize/2-arrowDimensions[length]/2-1,minPadding=min(paddingObject[minProp],largestPossiblePadding),maxPadding=min(paddingObject[maxProp],largestPossiblePadding),min$1=minPadding,max$1=clientSize-arrowDimensions[length]-maxPadding,center=clientSize/2-arrowDimensions[length]/2+centerToReference,offset$2=clamp$1(min$1,center,max$1),shouldAddOffset=!middlewareData.arrow&&getAlignment(placement)!=null&¢er!==offset$2&&rects.reference[length]/2-(centerside$1<=0)){var _middlewareData$flip2,_overflowsData$filter;let nextIndex=(middlewareData.flip?.index||0)+1,nextPlacement=placements$1[nextIndex];if(nextPlacement&&(!(checkCrossAxis===`alignment`&&initialSideAxis!==getSideAxis(nextPlacement))||overflowsData.every(d=>getSideAxis(d.placement)===initialSideAxis?d.overflows[0]>0:!0)))return{data:{index:nextIndex,overflows:overflowsData},reset:{placement:nextPlacement}};let resetPlacement=overflowsData.filter(d=>d.overflows[0]<=0).sort((a$1,b)=>a$1.overflows[1]-b.overflows[1])[0]?.placement;if(!resetPlacement)switch(fallbackStrategy){case`bestFit`:{var _overflowsData$filter2;let placement$1=overflowsData.filter(d=>{if(hasFallbackAxisSideDirection){let currentSideAxis=getSideAxis(d.placement);return currentSideAxis===initialSideAxis||currentSideAxis===`y`}return!0}).map(d=>[d.placement,d.overflows.filter(overflow$1=>overflow$1>0).reduce((acc,overflow$1)=>acc+overflow$1,0)]).sort((a$1,b)=>a$1[1]-b[1])[0]?.[0];placement$1&&(resetPlacement=placement$1);break}case`initialPlacement`:resetPlacement=initialPlacement;break}if(placement!==resetPlacement)return{reset:{placement:resetPlacement}}}return{}}}},originSides=new Set([`left`,`top`]);async function convertValueToCoords(state,options){let{placement,platform:platform$1,elements}=state,rtl=await(platform$1.isRTL==null?void 0:platform$1.isRTL(elements.floating)),side=getSide(placement),alignment=getAlignment(placement),isVertical=getSideAxis(placement)===`y`,mainAxisMulti=originSides.has(side)?-1:1,crossAxisMulti=rtl&&isVertical?-1:1,rawValue=evaluate(options,state),{mainAxis,crossAxis,alignmentAxis}=typeof rawValue==`number`?{mainAxis:rawValue,crossAxis:0,alignmentAxis:null}:{mainAxis:rawValue.mainAxis||0,crossAxis:rawValue.crossAxis||0,alignmentAxis:rawValue.alignmentAxis};return alignment&&typeof alignmentAxis==`number`&&(crossAxis=alignment===`end`?alignmentAxis*-1:alignmentAxis),isVertical?{x:crossAxis*crossAxisMulti,y:mainAxis*mainAxisMulti}:{x:mainAxis*mainAxisMulti,y:crossAxis*crossAxisMulti}}var offset$1=function(options){return options===void 0&&(options=0),{name:`offset`,options,async fn(state){var _middlewareData$offse,_middlewareData$arrow;let{x,y,placement,middlewareData}=state,diffCoords=await convertValueToCoords(state,options);return placement===middlewareData.offset?.placement&&(_middlewareData$arrow=middlewareData.arrow)!=null&&_middlewareData$arrow.alignmentOffset?{}:{x:x+diffCoords.x,y:y+diffCoords.y,data:{...diffCoords,placement}}}}},shift$1=function(options){return options===void 0&&(options={}),{name:`shift`,options,async fn(state){let{x,y,placement}=state,{mainAxis:checkMainAxis=!0,crossAxis:checkCrossAxis=!1,limiter={fn:_ref=>{let{x:x$1,y:y$1}=_ref;return{x:x$1,y:y$1}}},...detectOverflowOptions}=evaluate(options,state),coords={x,y},overflow=await detectOverflow$1(state,detectOverflowOptions),crossAxis=getSideAxis(getSide(placement)),mainAxis=getOppositeAxis(crossAxis),mainAxisCoord=coords[mainAxis],crossAxisCoord=coords[crossAxis];if(checkMainAxis){let minSide=mainAxis===`y`?`top`:`left`,maxSide=mainAxis===`y`?`bottom`:`right`,min$1=mainAxisCoord+overflow[minSide],max$1=mainAxisCoord-overflow[maxSide];mainAxisCoord=clamp$1(min$1,mainAxisCoord,max$1)}if(checkCrossAxis){let minSide=crossAxis===`y`?`top`:`left`,maxSide=crossAxis===`y`?`bottom`:`right`,min$1=crossAxisCoord+overflow[minSide],max$1=crossAxisCoord-overflow[maxSide];crossAxisCoord=clamp$1(min$1,crossAxisCoord,max$1)}let limitedCoords=limiter.fn({...state,[mainAxis]:mainAxisCoord,[crossAxis]:crossAxisCoord});return{...limitedCoords,data:{x:limitedCoords.x-x,y:limitedCoords.y-y,enabled:{[mainAxis]:checkMainAxis,[crossAxis]:checkCrossAxis}}}}}};function hasWindow(){return typeof window<`u`}function getNodeName(node){return isNode(node)?(node.nodeName||``).toLowerCase():`#document`}function getWindow(node){var _node$ownerDocument;return(node==null||(_node$ownerDocument=node.ownerDocument)==null?void 0:_node$ownerDocument.defaultView)||window}function getDocumentElement(node){var _ref;return((isNode(node)?node.ownerDocument:node.document)||window.document)?.documentElement}function isNode(value){return hasWindow()?value instanceof Node||value instanceof getWindow(value).Node:!1}function isElement(value){return hasWindow()?value instanceof Element||value instanceof getWindow(value).Element:!1}function isHTMLElement(value){return hasWindow()?value instanceof HTMLElement||value instanceof getWindow(value).HTMLElement:!1}function isShadowRoot(value){return!hasWindow()||typeof ShadowRoot>`u`?!1:value instanceof ShadowRoot||value instanceof getWindow(value).ShadowRoot}var invalidOverflowDisplayValues=new Set([`inline`,`contents`]);function isOverflowElement(element){let{overflow,overflowX,overflowY,display}=getComputedStyle$1(element);return/auto|scroll|overlay|hidden|clip/.test(overflow+overflowY+overflowX)&&!invalidOverflowDisplayValues.has(display)}var tableElements=new Set([`table`,`td`,`th`]);function isTableElement(element){return tableElements.has(getNodeName(element))}var topLayerSelectors=[`:popover-open`,`:modal`];function isTopLayer(element){return topLayerSelectors.some(selector=>{try{return element.matches(selector)}catch{return!1}})}var transformProperties=[`transform`,`translate`,`scale`,`rotate`,`perspective`],willChangeValues=[`transform`,`translate`,`scale`,`rotate`,`perspective`,`filter`],containValues=[`paint`,`layout`,`strict`,`content`];function isContainingBlock(elementOrCss){let webkit=isWebKit(),css=isElement(elementOrCss)?getComputedStyle$1(elementOrCss):elementOrCss;return transformProperties.some(value=>css[value]?css[value]!==`none`:!1)||(css.containerType?css.containerType!==`normal`:!1)||!webkit&&(css.backdropFilter?css.backdropFilter!==`none`:!1)||!webkit&&(css.filter?css.filter!==`none`:!1)||willChangeValues.some(value=>(css.willChange||``).includes(value))||containValues.some(value=>(css.contain||``).includes(value))}function getContainingBlock(element){let currentNode=getParentNode(element);for(;isHTMLElement(currentNode)&&!isLastTraversableNode(currentNode);){if(isContainingBlock(currentNode))return currentNode;if(isTopLayer(currentNode))return null;currentNode=getParentNode(currentNode)}return null}function isWebKit(){return typeof CSS>`u`||!CSS.supports?!1:CSS.supports(`-webkit-backdrop-filter`,`none`)}var lastTraversableNodeNames=new Set([`html`,`body`,`#document`]);function isLastTraversableNode(node){return lastTraversableNodeNames.has(getNodeName(node))}function getComputedStyle$1(element){return getWindow(element).getComputedStyle(element)}function getNodeScroll(element){return isElement(element)?{scrollLeft:element.scrollLeft,scrollTop:element.scrollTop}:{scrollLeft:element.scrollX,scrollTop:element.scrollY}}function getParentNode(node){if(getNodeName(node)===`html`)return node;let result=node.assignedSlot||node.parentNode||isShadowRoot(node)&&node.host||getDocumentElement(node);return isShadowRoot(result)?result.host:result}function getNearestOverflowAncestor(node){let parentNode=getParentNode(node);return isLastTraversableNode(parentNode)?node.ownerDocument?node.ownerDocument.body:node.body:isHTMLElement(parentNode)&&isOverflowElement(parentNode)?parentNode:getNearestOverflowAncestor(parentNode)}function getOverflowAncestors(node,list,traverseIframes){var _node$ownerDocument2;list===void 0&&(list=[]),traverseIframes===void 0&&(traverseIframes=!0);let scrollableAncestor=getNearestOverflowAncestor(node),isBody=scrollableAncestor===node.ownerDocument?.body,win=getWindow(scrollableAncestor);if(isBody){let frameElement=getFrameElement(win);return list.concat(win,win.visualViewport||[],isOverflowElement(scrollableAncestor)?scrollableAncestor:[],frameElement&&traverseIframes?getOverflowAncestors(frameElement):[])}return list.concat(scrollableAncestor,getOverflowAncestors(scrollableAncestor,[],traverseIframes))}function getFrameElement(win){return win.parent&&Object.getPrototypeOf(win.parent)?win.frameElement:null}function getCssDimensions(element){let css=getComputedStyle$1(element),width$1=parseFloat(css.width)||0,height$1=parseFloat(css.height)||0,hasOffset=isHTMLElement(element),offsetWidth=hasOffset?element.offsetWidth:width$1,offsetHeight=hasOffset?element.offsetHeight:height$1,shouldFallback=round$1(width$1)!==offsetWidth||round$1(height$1)!==offsetHeight;return shouldFallback&&(width$1=offsetWidth,height$1=offsetHeight),{width:width$1,height:height$1,$:shouldFallback}}function unwrapElement$1(element){return isElement(element)?element:element.contextElement}function getScale(element){let domElement=unwrapElement$1(element);if(!isHTMLElement(domElement))return createCoords(1);let rect=domElement.getBoundingClientRect(),{width:width$1,height:height$1,$}=getCssDimensions(domElement),x=($?round$1(rect.width):rect.width)/width$1,y=($?round$1(rect.height):rect.height)/height$1;return(!x||!Number.isFinite(x))&&(x=1),(!y||!Number.isFinite(y))&&(y=1),{x,y}}var noOffsets=createCoords(0);function getVisualOffsets(element){let win=getWindow(element);return!isWebKit()||!win.visualViewport?noOffsets:{x:win.visualViewport.offsetLeft,y:win.visualViewport.offsetTop}}function shouldAddVisualOffsets(element,isFixed,floatingOffsetParent){return isFixed===void 0&&(isFixed=!1),!floatingOffsetParent||isFixed&&floatingOffsetParent!==getWindow(element)?!1:isFixed}function getBoundingClientRect(element,includeScale,isFixedStrategy,offsetParent){includeScale===void 0&&(includeScale=!1),isFixedStrategy===void 0&&(isFixedStrategy=!1);let clientRect=element.getBoundingClientRect(),domElement=unwrapElement$1(element),scale=createCoords(1);includeScale&&(offsetParent?isElement(offsetParent)&&(scale=getScale(offsetParent)):scale=getScale(element));let visualOffsets=shouldAddVisualOffsets(domElement,isFixedStrategy,offsetParent)?getVisualOffsets(domElement):createCoords(0),x=(clientRect.left+visualOffsets.x)/scale.x,y=(clientRect.top+visualOffsets.y)/scale.y,width$1=clientRect.width/scale.x,height$1=clientRect.height/scale.y;if(domElement){let win=getWindow(domElement),offsetWin=offsetParent&&isElement(offsetParent)?getWindow(offsetParent):offsetParent,currentWin=win,currentIFrame=getFrameElement(currentWin);for(;currentIFrame&&offsetParent&&offsetWin!==currentWin;){let iframeScale=getScale(currentIFrame),iframeRect=currentIFrame.getBoundingClientRect(),css=getComputedStyle$1(currentIFrame),left=iframeRect.left+(currentIFrame.clientLeft+parseFloat(css.paddingLeft))*iframeScale.x,top=iframeRect.top+(currentIFrame.clientTop+parseFloat(css.paddingTop))*iframeScale.y;x*=iframeScale.x,y*=iframeScale.y,width$1*=iframeScale.x,height$1*=iframeScale.y,x+=left,y+=top,currentWin=getWindow(currentIFrame),currentIFrame=getFrameElement(currentWin)}}return rectToClientRect({width:width$1,height:height$1,x,y})}function getWindowScrollBarX(element,rect){let leftScroll=getNodeScroll(element).scrollLeft;return rect?rect.left+leftScroll:getBoundingClientRect(getDocumentElement(element)).left+leftScroll}function getHTMLOffset(documentElement,scroll$1){let htmlRect=documentElement.getBoundingClientRect();return{x:htmlRect.left+scroll$1.scrollLeft-getWindowScrollBarX(documentElement,htmlRect),y:htmlRect.top+scroll$1.scrollTop}}function convertOffsetParentRelativeRectToViewportRelativeRect(_ref){let{elements,rect,offsetParent,strategy}=_ref,isFixed=strategy===`fixed`,documentElement=getDocumentElement(offsetParent),topLayer=elements?isTopLayer(elements.floating):!1;if(offsetParent===documentElement||topLayer&&isFixed)return rect;let scroll$1={scrollLeft:0,scrollTop:0},scale=createCoords(1),offsets=createCoords(0),isOffsetParentAnElement=isHTMLElement(offsetParent);if((isOffsetParentAnElement||!isOffsetParentAnElement&&!isFixed)&&((getNodeName(offsetParent)!==`body`||isOverflowElement(documentElement))&&(scroll$1=getNodeScroll(offsetParent)),isHTMLElement(offsetParent))){let offsetRect=getBoundingClientRect(offsetParent);scale=getScale(offsetParent),offsets.x=offsetRect.x+offsetParent.clientLeft,offsets.y=offsetRect.y+offsetParent.clientTop}let htmlOffset=documentElement&&!isOffsetParentAnElement&&!isFixed?getHTMLOffset(documentElement,scroll$1):createCoords(0);return{width:rect.width*scale.x,height:rect.height*scale.y,x:rect.x*scale.x-scroll$1.scrollLeft*scale.x+offsets.x+htmlOffset.x,y:rect.y*scale.y-scroll$1.scrollTop*scale.y+offsets.y+htmlOffset.y}}function getClientRects(element){return Array.from(element.getClientRects())}function getDocumentRect(element){let html=getDocumentElement(element),scroll$1=getNodeScroll(element),body=element.ownerDocument.body,width$1=max(html.scrollWidth,html.clientWidth,body.scrollWidth,body.clientWidth),height$1=max(html.scrollHeight,html.clientHeight,body.scrollHeight,body.clientHeight),x=-scroll$1.scrollLeft+getWindowScrollBarX(element),y=-scroll$1.scrollTop;return getComputedStyle$1(body).direction===`rtl`&&(x+=max(html.clientWidth,body.clientWidth)-width$1),{width:width$1,height:height$1,x,y}}var SCROLLBAR_MAX=25;function getViewportRect(element,strategy){let win=getWindow(element),html=getDocumentElement(element),visualViewport=win.visualViewport,width$1=html.clientWidth,height$1=html.clientHeight,x=0,y=0;if(visualViewport){width$1=visualViewport.width,height$1=visualViewport.height;let visualViewportBased=isWebKit();(!visualViewportBased||visualViewportBased&&strategy===`fixed`)&&(x=visualViewport.offsetLeft,y=visualViewport.offsetTop)}let windowScrollbarX=getWindowScrollBarX(html);if(windowScrollbarX<=0){let doc$1=html.ownerDocument,body=doc$1.body,bodyStyles=getComputedStyle(body),bodyMarginInline=doc$1.compatMode===`CSS1Compat`&&parseFloat(bodyStyles.marginLeft)+parseFloat(bodyStyles.marginRight)||0,clippingStableScrollbarWidth=Math.abs(html.clientWidth-body.clientWidth-bodyMarginInline);clippingStableScrollbarWidth<=SCROLLBAR_MAX&&(width$1-=clippingStableScrollbarWidth)}else windowScrollbarX<=SCROLLBAR_MAX&&(width$1+=windowScrollbarX);return{width:width$1,height:height$1,x,y}}var absoluteOrFixed=new Set([`absolute`,`fixed`]);function getInnerBoundingClientRect(element,strategy){let clientRect=getBoundingClientRect(element,!0,strategy===`fixed`),top=clientRect.top+element.clientTop,left=clientRect.left+element.clientLeft,scale=isHTMLElement(element)?getScale(element):createCoords(1);return{width:element.clientWidth*scale.x,height:element.clientHeight*scale.y,x:left*scale.x,y:top*scale.y}}function getClientRectFromClippingAncestor(element,clippingAncestor,strategy){let rect;if(clippingAncestor===`viewport`)rect=getViewportRect(element,strategy);else if(clippingAncestor===`document`)rect=getDocumentRect(getDocumentElement(element));else if(isElement(clippingAncestor))rect=getInnerBoundingClientRect(clippingAncestor,strategy);else{let visualOffsets=getVisualOffsets(element);rect={x:clippingAncestor.x-visualOffsets.x,y:clippingAncestor.y-visualOffsets.y,width:clippingAncestor.width,height:clippingAncestor.height}}return rectToClientRect(rect)}function hasFixedPositionAncestor(element,stopNode){let parentNode=getParentNode(element);return parentNode===stopNode||!isElement(parentNode)||isLastTraversableNode(parentNode)?!1:getComputedStyle$1(parentNode).position===`fixed`||hasFixedPositionAncestor(parentNode,stopNode)}function getClippingElementAncestors(element,cache$1){let cachedResult=cache$1.get(element);if(cachedResult)return cachedResult;let result=getOverflowAncestors(element,[],!1).filter(el=>isElement(el)&&getNodeName(el)!==`body`),currentContainingBlockComputedStyle=null,elementIsFixed=getComputedStyle$1(element).position===`fixed`,currentNode=elementIsFixed?getParentNode(element):element;for(;isElement(currentNode)&&!isLastTraversableNode(currentNode);){let computedStyle=getComputedStyle$1(currentNode),currentNodeIsContaining=isContainingBlock(currentNode);!currentNodeIsContaining&&computedStyle.position===`fixed`&&(currentContainingBlockComputedStyle=null),(elementIsFixed?!currentNodeIsContaining&&!currentContainingBlockComputedStyle:!currentNodeIsContaining&&computedStyle.position===`static`&¤tContainingBlockComputedStyle&&absoluteOrFixed.has(currentContainingBlockComputedStyle.position)||isOverflowElement(currentNode)&&!currentNodeIsContaining&&hasFixedPositionAncestor(element,currentNode))?result=result.filter(ancestor=>ancestor!==currentNode):currentContainingBlockComputedStyle=computedStyle,currentNode=getParentNode(currentNode)}return cache$1.set(element,result),result}function getClippingRect(_ref){let{element,boundary,rootBoundary,strategy}=_ref,clippingAncestors=[...boundary===`clippingAncestors`?isTopLayer(element)?[]:getClippingElementAncestors(element,this._c):[].concat(boundary),rootBoundary],firstClippingAncestor=clippingAncestors[0],clippingRect=clippingAncestors.reduce((accRect,clippingAncestor)=>{let rect=getClientRectFromClippingAncestor(element,clippingAncestor,strategy);return accRect.top=max(rect.top,accRect.top),accRect.right=min(rect.right,accRect.right),accRect.bottom=min(rect.bottom,accRect.bottom),accRect.left=max(rect.left,accRect.left),accRect},getClientRectFromClippingAncestor(element,firstClippingAncestor,strategy));return{width:clippingRect.right-clippingRect.left,height:clippingRect.bottom-clippingRect.top,x:clippingRect.left,y:clippingRect.top}}function getDimensions(element){let{width:width$1,height:height$1}=getCssDimensions(element);return{width:width$1,height:height$1}}function getRectRelativeToOffsetParent(element,offsetParent,strategy){let isOffsetParentAnElement=isHTMLElement(offsetParent),documentElement=getDocumentElement(offsetParent),isFixed=strategy===`fixed`,rect=getBoundingClientRect(element,!0,isFixed,offsetParent),scroll$1={scrollLeft:0,scrollTop:0},offsets=createCoords(0);function setLeftRTLScrollbarOffset(){offsets.x=getWindowScrollBarX(documentElement)}if(isOffsetParentAnElement||!isOffsetParentAnElement&&!isFixed)if((getNodeName(offsetParent)!==`body`||isOverflowElement(documentElement))&&(scroll$1=getNodeScroll(offsetParent)),isOffsetParentAnElement){let offsetRect=getBoundingClientRect(offsetParent,!0,isFixed,offsetParent);offsets.x=offsetRect.x+offsetParent.clientLeft,offsets.y=offsetRect.y+offsetParent.clientTop}else documentElement&&setLeftRTLScrollbarOffset();isFixed&&!isOffsetParentAnElement&&documentElement&&setLeftRTLScrollbarOffset();let htmlOffset=documentElement&&!isOffsetParentAnElement&&!isFixed?getHTMLOffset(documentElement,scroll$1):createCoords(0);return{x:rect.left+scroll$1.scrollLeft-offsets.x-htmlOffset.x,y:rect.top+scroll$1.scrollTop-offsets.y-htmlOffset.y,width:rect.width,height:rect.height}}function isStaticPositioned(element){return getComputedStyle$1(element).position===`static`}function getTrueOffsetParent(element,polyfill){if(!isHTMLElement(element)||getComputedStyle$1(element).position===`fixed`)return null;if(polyfill)return polyfill(element);let rawOffsetParent=element.offsetParent;return getDocumentElement(element)===rawOffsetParent&&(rawOffsetParent=rawOffsetParent.ownerDocument.body),rawOffsetParent}function getOffsetParent(element,polyfill){let win=getWindow(element);if(isTopLayer(element))return win;if(!isHTMLElement(element)){let svgOffsetParent=getParentNode(element);for(;svgOffsetParent&&!isLastTraversableNode(svgOffsetParent);){if(isElement(svgOffsetParent)&&!isStaticPositioned(svgOffsetParent))return svgOffsetParent;svgOffsetParent=getParentNode(svgOffsetParent)}return win}let offsetParent=getTrueOffsetParent(element,polyfill);for(;offsetParent&&isTableElement(offsetParent)&&isStaticPositioned(offsetParent);)offsetParent=getTrueOffsetParent(offsetParent,polyfill);return offsetParent&&isLastTraversableNode(offsetParent)&&isStaticPositioned(offsetParent)&&!isContainingBlock(offsetParent)?win:offsetParent||getContainingBlock(element)||win}var getElementRects=async function(data){let getOffsetParentFn=this.getOffsetParent||getOffsetParent,getDimensionsFn=this.getDimensions,floatingDimensions=await getDimensionsFn(data.floating);return{reference:getRectRelativeToOffsetParent(data.reference,await getOffsetParentFn(data.floating),data.strategy),floating:{x:0,y:0,width:floatingDimensions.width,height:floatingDimensions.height}}};function isRTL(element){return getComputedStyle$1(element).direction===`rtl`}var platform={convertOffsetParentRelativeRectToViewportRelativeRect,getDocumentElement,getClippingRect,getOffsetParent,getElementRects,getClientRects,getDimensions,getScale,isElement,isRTL};function rectsAreEqual(a$1,b){return a$1.x===b.x&&a$1.y===b.y&&a$1.width===b.width&&a$1.height===b.height}function observeMove(element,onMove){let io=null,timeoutId,root=getDocumentElement(element);function cleanup(){var _io;clearTimeout(timeoutId),(_io=io)==null||_io.disconnect(),io=null}function refresh$1(skip,threshold){skip===void 0&&(skip=!1),threshold===void 0&&(threshold=1),cleanup();let elementRectForRootMargin=element.getBoundingClientRect(),{left,top,width:width$1,height:height$1}=elementRectForRootMargin;if(skip||onMove(),!width$1||!height$1)return;let insetTop=floor(top),insetRight=floor(root.clientWidth-(left+width$1)),insetBottom=floor(root.clientHeight-(top+height$1)),insetLeft=floor(left),options={rootMargin:-insetTop+`px `+-insetRight+`px `+-insetBottom+`px `+-insetLeft+`px`,threshold:max(0,min(1,threshold))||1},isFirstUpdate=!0;function handleObserve(entries){let ratio=entries[0].intersectionRatio;if(ratio!==threshold){if(!isFirstUpdate)return refresh$1();ratio?refresh$1(!1,ratio):timeoutId=setTimeout(()=>{refresh$1(!1,1e-7)},1e3)}ratio===1&&!rectsAreEqual(elementRectForRootMargin,element.getBoundingClientRect())&&refresh$1(),isFirstUpdate=!1}try{io=new IntersectionObserver(handleObserve,{...options,root:root.ownerDocument})}catch{io=new IntersectionObserver(handleObserve,options)}io.observe(element)}return refresh$1(!0),cleanup}function autoUpdate(reference,floating,update$6,options){options===void 0&&(options={});let{ancestorScroll=!0,ancestorResize=!0,elementResize=typeof ResizeObserver==`function`,layoutShift=typeof IntersectionObserver==`function`,animationFrame=!1}=options,referenceEl=unwrapElement$1(reference),ancestors=ancestorScroll||ancestorResize?[...referenceEl?getOverflowAncestors(referenceEl):[],...getOverflowAncestors(floating)]:[];ancestors.forEach(ancestor=>{ancestorScroll&&ancestor.addEventListener(`scroll`,update$6,{passive:!0}),ancestorResize&&ancestor.addEventListener(`resize`,update$6)});let cleanupIo=referenceEl&&layoutShift?observeMove(referenceEl,update$6):null,reobserveFrame=-1,resizeObserver=null;elementResize&&(resizeObserver=new ResizeObserver(_ref=>{let[firstEntry]=_ref;firstEntry&&firstEntry.target===referenceEl&&resizeObserver&&(resizeObserver.unobserve(floating),cancelAnimationFrame(reobserveFrame),reobserveFrame=requestAnimationFrame(()=>{var _resizeObserver;(_resizeObserver=resizeObserver)==null||_resizeObserver.observe(floating)})),update$6()}),referenceEl&&!animationFrame&&resizeObserver.observe(referenceEl),resizeObserver.observe(floating));let frameId,prevRefRect=animationFrame?getBoundingClientRect(reference):null;animationFrame&&frameLoop();function frameLoop(){let nextRefRect=getBoundingClientRect(reference);prevRefRect&&!rectsAreEqual(prevRefRect,nextRefRect)&&update$6(),prevRefRect=nextRefRect,frameId=requestAnimationFrame(frameLoop)}return update$6(),()=>{var _resizeObserver2;ancestors.forEach(ancestor=>{ancestorScroll&&ancestor.removeEventListener(`scroll`,update$6),ancestorResize&&ancestor.removeEventListener(`resize`,update$6)}),cleanupIo?.(),(_resizeObserver2=resizeObserver)==null||_resizeObserver2.disconnect(),resizeObserver=null,animationFrame&&cancelAnimationFrame(frameId)}}var offset=offset$1,shift=shift$1,flip=flip$1,arrow$1=arrow$2,computePosition=(reference,floating,options)=>{let cache$1=new Map,mergedOptions={platform,...options},platformWithCache={...mergedOptions.platform,_c:cache$1};return computePosition$1(reference,floating,{...mergedOptions,platform:platformWithCache})};function isComponentPublicInstance(target){return typeof target==`object`&&!!target&&`$el`in target}function unwrapElement(target){if(isComponentPublicInstance(target)){let element=target.$el;return isNode(element)&&getNodeName(element)===`#comment`?null:element}return target}function toValue(source){return typeof source==`function`?source():unref(source)}function arrow(options){return{name:`arrow`,options,fn(args){let element=unwrapElement(toValue(options.element));return element==null?{}:arrow$1({element,padding:options.padding}).fn(args)}}}function getDPR(element){return typeof window>`u`?1:(element.ownerDocument.defaultView||window).devicePixelRatio||1}function roundByDPR(element,value){let dpr=getDPR(element);return Math.round(value*dpr)/dpr}function useFloating(reference,floating,options){options===void 0&&(options={});let whileElementsMountedOption=options.whileElementsMounted,openOption=computed(()=>{var _toValue;return toValue(options.open)??!0}),middlewareOption=computed(()=>toValue(options.middleware)),placementOption=computed(()=>{var _toValue2;return toValue(options.placement)??`bottom`}),strategyOption=computed(()=>{var _toValue3;return toValue(options.strategy)??`absolute`}),transformOption=computed(()=>{var _toValue4;return toValue(options.transform)??!0}),referenceElement=computed(()=>unwrapElement(reference.value)),floatingElement=computed(()=>unwrapElement(floating.value)),x=ref(0),y=ref(0),strategy=ref(strategyOption.value),placement=ref(placementOption.value),middlewareData=shallowRef({}),isPositioned=ref(!1),floatingStyles=computed(()=>{let initialStyles={position:strategy.value,left:`0`,top:`0`};if(!floatingElement.value)return initialStyles;let xVal=roundByDPR(floatingElement.value,x.value),yVal=roundByDPR(floatingElement.value,y.value);return transformOption.value?{...initialStyles,transform:`translate(`+xVal+`px, `+yVal+`px)`,...getDPR(floatingElement.value)>=1.5&&{willChange:`transform`}}:{position:strategy.value,left:xVal+`px`,top:yVal+`px`}}),whileElementsMountedCleanup;function update$6(){if(referenceElement.value==null||floatingElement.value==null)return;let open$1=openOption.value;computePosition(referenceElement.value,floatingElement.value,{middleware:middlewareOption.value,placement:placementOption.value,strategy:strategyOption.value}).then(position=>{x.value=position.x,y.value=position.y,strategy.value=position.strategy,placement.value=position.placement,middlewareData.value=position.middlewareData,isPositioned.value=open$1!==!1})}function cleanup(){typeof whileElementsMountedCleanup==`function`&&(whileElementsMountedCleanup(),whileElementsMountedCleanup=void 0)}function attach(){if(cleanup(),whileElementsMountedOption===void 0){update$6();return}if(referenceElement.value!=null&&floatingElement.value!=null){whileElementsMountedCleanup=whileElementsMountedOption(referenceElement.value,floatingElement.value,update$6);return}}function reset$1(){openOption.value||(isPositioned.value=!1)}return watch([middlewareOption,placementOption,strategyOption,openOption],update$6,{flush:`sync`}),watch([referenceElement,floatingElement],attach,{flush:`sync`}),watch(openOption,reset$1,{flush:`sync`}),getCurrentScope()&&onScopeDispose(cleanup),{x:shallowReadonly(x),y:shallowReadonly(y),strategy:shallowReadonly(strategy),placement:shallowReadonly(placement),middlewareData:shallowReadonly(middlewareData),isPositioned:shallowReadonly(isPositioned),floatingStyles,update:update$6}}var ARROW_POSITION={top:`bottom`,right:`left`,bottom:`top`,left:`right`};const usePopover=defineStore(`popover`,()=>{let _counter=ref(0),_currentPopover=ref(null),popovers=ref({}),currentPopover=computed(()=>_currentPopover.value),register=(name,popover,popoverPlacement=void 0,options={})=>{if(popovers.value[name])return;popovers.value[name]={element:popover,target:null,placement:popoverPlacement||`bottom`,show:!1};let popoverInstance=buildPopover(popover,toRef(popovers.value[name],`target`),toRef(popovers.value[name],`placement`),options),scope$1=effectScope(),show$1;scope$1.run(()=>{show$1=computed(()=>popovers.value[name].show)});let dispose$2=()=>{scope$1.stop(),popoverInstance.dispose()};return popovers.value[name].dispose=dispose$2,_counter.value++,{show:show$1,update:popoverInstance.update,placement:popoverInstance.placement}},bind=(popoverName,el,options)=>{let scope$1=effectScope(),hidden,isBound,popoverElement;scope$1.run(()=>{hidden=computed(()=>popovers.value[popoverName]?!popovers.value[popoverName].show:void 0),isBound=computed(()=>popovers.value[popoverName]?popovers.value[popoverName].target===el:void 0),popoverElement=computed(()=>popovers.value[popoverName]?popovers.value[popoverName].element:void 0)});let show$1=()=>{isBound.value||(popovers.value[popoverName].target=el,popovers.value[popoverName].placement=options.placement),popovers.value[popoverName].show=!0},hide$3=()=>{isBound.value&&(popovers.value[popoverName].show=!1)};return{popoverElement,hidden,isBound,show:show$1,hide:hide$3,toggle:(forceValue=void 0)=>{let doShow=forceValue;typeof doShow!=`boolean`&&(doShow=!isBound.value||!popovers.value[popoverName].show),doShow?show$1():hide$3()},isShown:()=>!!popovers.value[popoverName].show,unbind:()=>{scope$1.stop()}}},unregister=name=>{popovers.value[name]&&(popovers.value[name].dispose(),delete popovers.value[name])},isShown=name=>name in popovers.value?popovers.value[name].show:!1,show=(name,target)=>{name in popovers.value&&(popovers.value[name].show=!0,target&&(popovers.value[name].target=target),_currentPopover.value=popovers.value[name])},hide$2=name=>{name in popovers.value&&(popovers.value[name].show=!1,_currentPopover.value=null)};return{popovers,currentPopover,bind,register,unregister,isShown,show,hide:hide$2,toggle:(name,forceValue=void 0)=>{name in popovers.value&&(popovers.value[name].show=typeof forceValue==`boolean`?forceValue:!popovers.value[name].show,_currentPopover.value=popovers.value[name].show?popovers.value[name]:null)},hideAll:(startsWith=void 0)=>{let keys=Object.keys(popovers.value);startsWith&&(keys=keys.filter(name=>name.startsWith(startsWith))),keys.forEach(name=>popovers.value[name].show&&hide$2(name))},getPopover:name=>popovers.value[name],counter:computed(()=>_counter.value)}});function buildPopover(popover,reference,placementArg,options){let{floatingStyles,middlewareData,update:update$6,placement}=useFloating(reference,popover,{placement:placementArg,middleware:buildMiddleware(popover,options),whileElementsMounted:autoUpdate}),watchers$1=[];return watchers$1.push(watch(floatingStyles,async styles=>{popover.value&&await nextTick(()=>{Object.keys(styles).forEach(styleName=>popover.value.style[styleName]=styles[styleName])})})),options.arrow&&watchers$1.push(watch(middlewareData,async middlewareData$1=>{let left=middlewareData$1.arrow&&middlewareData$1.arrow.x!=null?`${middlewareData$1.arrow.x}px`:``,top=middlewareData$1.arrow&&middlewareData$1.arrow.y!=null?`${middlewareData$1.arrow.y}px`:``,arrowSide=ARROW_POSITION[middlewareData$1.offset.placement.split(`-`)[0]];await nextTick(()=>{applyStyles(options.arrow.value,{left,top,right:``,bottom:``,[arrowSide]:`-${options.arrow.value.offsetWidth/2}px`})})})),{placement,update:update$6,dispose:()=>{watchers$1.forEach(unwatch=>unwatch())}}}var arrowOffset=options=>({name:`arrowOffset`,options,fn({...state}){let arrOffset=Math.sqrt(2*options.element.value.offsetWidth**2)/2,side=state.placement.startsWith(`left`)||state.placement.startsWith(`top`)?-1:1;if(state.placement.startsWith(`left`)||state.placement.startsWith(`right`))return{x:state.x+side*arrOffset};if(state.placement.startsWith(`top`)||state.placement.startsWith(`bottom`))return{y:state.y+side*arrOffset}}});function buildMiddleware(popover,options){let middleware=[flip(),shift()],offsetValue=options.offset||0;return middleware.push(offset(offsetValue)),options.arrow&&(middleware.push(arrowOffset({element:options.arrow})),middleware.push(arrow({element:options.arrow}))),middleware}function applyStyles(el,styles){Object.keys(styles).forEach(styleName=>el.style[styleName]=styles[styleName])}var HOVER_SHOW_EVENTS=[`mouseover`,`focus`],HOVER_HIDE_EVENTS=[`mouseleave`,`blur`],TOGGLE_EVENTS=[`click`],BngPopover_default={mounted:setup$1,updated:setup$1,onBeforeUnmount:dispose};function setup$1(el,binding){dispose(el),binding.value&&(setPopoverProperties(el,binding),bindPopover(el),attachListeners(el,binding.modifiers))}function dispose(el){el.__popover&&(el.__popover.unregister&&el.__popover.unbind(),removeListeners(el))}function attachListeners(el,modifiers){el.__popover.showHandler=event=>{el.contains(event.target)&&el.__popover.show()},el.__popover.hideHandler=event=>{el.contains(event.relatedTarget)||el.__popover.hide()},el.__popover.toggleHandler=event=>{el.contains(event.target)&&el.__popover.toggle()},el.__popover.clickOutside=event=>{!el.contains(event.target)&&(!el.__popover.element.value||!el.__popover.element.value.contains(event.target))&&el.__popover.hide()},modifiers.click?(TOGGLE_EVENTS.forEach(eventName=>{el.addEventListener(eventName,el.__popover.toggleHandler)}),TOGGLE_EVENTS.forEach(eventName=>{window.addEventListener(eventName,el.__popover.clickOutside)})):(HOVER_SHOW_EVENTS.forEach(eventName=>el.addEventListener(eventName,el.__popover.showHandler)),HOVER_HIDE_EVENTS.forEach(eventName=>el.addEventListener(eventName,el.__popover.hideHandler)))}function removeListeners(el){el.__popover.toggleHandler&&(TOGGLE_EVENTS.forEach(eventName=>{el.removeEventListener(eventName,el.__popover.toggleHandler)}),TOGGLE_EVENTS.forEach(eventName=>{window.removeEventListener(eventName,el.__popover.clickOutside)})),el.__popover.showHandler&&HOVER_SHOW_EVENTS.forEach(eventName=>el.removeEventListener(eventName,el.__popover.showHandler)),el.__popover.hideHandler&&HOVER_SHOW_EVENTS.forEach(eventName=>el.removeEventListener(eventName,el.__popover.hideHandler))}function bindPopover(el){let popoverBind=usePopover().bind(el.__popover.name,el,getOptions$1(el));Object.assign(el.__popover,{toggle:popoverBind.toggle,show:popoverBind.show,isShown:popoverBind.isShown,hide:popoverBind.hide,toggle:popoverBind.toggle,hidden:popoverBind.hidden,element:popoverBind.popoverElement,unbind:popoverBind.unbind})}function setPopoverProperties(el,binding){el.__popover={name:getPopoverName(binding),placement:getPlacement(binding)}}var getOptions$1=el=>({placement:el.__popover.placement}),getPlacement=binding=>binding.arg?binding.arg:binding.placement?binding.placement:`left`,getPopoverName=binding=>typeof binding.value==`string`?binding.value:binding.value.name,TIMESPAN_TRANSLATE_ID_PREFIX=`ui.timespan.`,$t=i=>$translate.instant(TIMESPAN_TRANSLATE_ID_PREFIX+i),SECONDS_IN={year:3600*24*365,month:3600*24*30,week:3600*24*7,day:3600*24,hour:3600,minute:60,second:1},MINIMUM_SPAN=Object.entries(SECONDS_IN).slice(-1)[0][1],dateToEpoch=date=>date?typeof date==`string`?/^\d+$/.test(date)?+date:~~(new Date(date).getTime()/1e3):typeof date==`number`?date:0:0;const timeSpan=(date1,date2=null,length=2,useRelativeDescription=!1)=>{let res=`-`;if(date1=dateToEpoch(date1),!date1)return res;if(date2){if(date2=dateToEpoch(date2),!date2)return res}else date2=~~(new Date().getTime()/1e3);let diff,isFuture;return date1>=date2?(diff=date1-date2,isFuture=!0):(diff=date2-date1,isFuture=!1),res=formatTime(diff,length,useRelativeDescription,isFuture),res},formatTime=(seconds,length=2,useRelativeDescription=!1,future=!1)=>{let res=`-`;if(seconds20&&abs%10==1?abs+` `+$t(spanName+`.plural_1_pastfuture`):abs<=4||useRelativeDescription&&abs>20&&abs%10<=4?abs+` `+$t(spanName+`.plural_234`):abs+` `+$t(spanName+`.plural`),cur&&resArr.push(cur),length===1)break;length--,seconds%=spanSeconds}res=``;let resArrLen=resArr.length;return resArr.forEach((bit,i)=>{bit=bit.replace(` `,`\xA0`),i?(i===resArrLen-1?res+=` `+$t(`and`)+` `:res+=$t(`separator`)+` `,res+=bit):res+=ucaseFirst(bit)}),useRelativeDescription&&(res+=` `+$t(future?`future`:`past`)),res};var update=(element,{value})=>{let desc=timeSpan(value,null,1,!0);desc!==`-`&&(element.innerHTML=desc)},BngRelativeTime_default=update;const getScopeProperties=el=>{if(!(!el||!el.hasAttribute(`bng-ui-scope`)))return{scopeId:el.getAttribute(UI_SCOPE_ATTR$1),isScopedNav:el.hasAttribute(SCOPED_NAV_ATTR)}},findParentScope=(el,scopedNavOnly=!1)=>{let parent=el.parentElement;for(;parent;){let scopedNavId=parent.getAttribute(SCOPED_NAV_ATTR);if(scopedNavId)return{scopeId:scopedNavId,element:parent,isScopedNav:!0};if(!scopedNavOnly){let uiScopeId=parent.getAttribute(UI_SCOPE_ATTR$1);if(uiScopeId)return{scopeId:uiScopeId,element:parent,isScopedNav:!1}}parent=parent.parentElement}return null},isNavigable=el=>(!el.hasAttribute(`bng-no-nav`)||el.getAttribute(`bng-no-nav`)===`false`)&&(!el.hasAttribute(`disabled`)||el.getAttribute(`disabled`)===`false`),isDirectChild=(el,child)=>child.parentElement.closest(`[bng-scoped-nav]`)===el,getNavItems=(el,navigableOnly=!0)=>{let matches$1=el.querySelectorAll(NAVIGABLE_ELEMENTS_SELECTOR);return Array.from(matches$1).filter(child=>!isNavigable(child)&&navigableOnly?!1:isDirectChild(el,child))},getPassthroughEvents=el=>{let navItems=getNavItems(el,!1);if(navItems.length===0)return!1;let boundEvents=[];for(let elem of navItems){let uiNavEvents=elem.__BngOnUiNav?Object.values(elem.__BngOnUiNav).map(x=>x.eventNames).flat().filter(name=>!PASSTHROUGH_EXCLUDED_EVENTS.includes(name)):[],isDuplicate=uiNavEvents.some(event=>boundEvents.includes(event));if(uiNavEvents.length===0||isDuplicate){boundEvents=[];break}uiNavEvents.forEach(event=>{boundEvents.includes(event)||boundEvents.push(event)})}return boundEvents};var SCOPED_NAV_OBSERVER_EVENTS={onBeforeScopeActivated:`onBeforeScopeActivated`,onScopeActivated:`onScopeActivated`,onBeforeScopeDeactivated:`onBeforeScopeDeactivated`,onScopeDeactivated:`onScopeDeactivated`,onBeforeScopeSuspended:`onBeforeScopeSuspended`,onScopeSuspended:`onScopeSuspended`,onBeforeScopeResumed:`onBeforeScopeResumed`,onScopeResumed:`onScopeResumed`},scopedNavObservers={};function registerScopedNavObserver(id,observer$2){scopedNavObservers[id]=observer$2}function notifyScopedNavObservers(event,detail){Object.keys(scopedNavObservers).forEach(observerId=>{let callback=scopedNavObservers[observerId][event];if(callback&&typeof callback==`function`)try{callback(detail)}catch(error){logger_default.error(`Error in scoped nav observer ${observerId} for event ${event}`,error)}})}const useScopedNav=defineStore(`scopedNav2`,()=>{let scopeStack=ref([]),activateScope=(scopeId,element,options={activationType:SCOPED_NAV_STATES.active,suspendParentScopes:!1})=>{notifyScopedNavObservers(SCOPED_NAV_OBSERVER_EVENTS.onBeforeScopeActivated,{scopeId,element,options});let scopeIndex=scopeStack.value.findIndex(s=>s.scopeId===scopeId),existingScope=scopeIndex===-1?void 0:scopeStack.value[scopeIndex];if(existingScope&&existingScope.activationType===options.activationType){logger_default.warn(`Scope ${scopeId} already active. Ignoring...`),notifyScopedNavObservers(SCOPED_NAV_OBSERVER_EVENTS.onScopeActivated,{scopeId,element,options});return}existingScope?existingScope.activationType=options.activationType:(scopeStack.value.push({scopeId,element,...options}),scopeIndex=scopeStack.value.length-1),notifyScopedNavObservers(SCOPED_NAV_OBSERVER_EVENTS.onScopeActivated,{scopeId,element,options});let scopeData={scopeId,...options},{type}=element[SCOPED_NAV_PROPERTY_NAME];if(type===SCOPED_NAV_TYPES.popover||options.suspendParentScopes){let referenceElement=element;if(type===SCOPED_NAV_TYPES.popover){let popover=usePopover(),popoverName=element.getAttribute(`data-bng-popover-name`),pop=popover.getPopover(popoverName);pop&&pop.target&&(referenceElement=pop.target)}if(!referenceElement){logger_default.warn(`Unable to find popover's target element. Skipping suspending parent scopes...`);return}let parentScopes=scopeStack.value.slice(0,scopeIndex);for(let i=parentScopes.length-1;i>=0;i--){let scope$1=parentScopes[i];referenceElement&&scope$1.element.contains(referenceElement)?suspendScope(scope$1.scopeId,scopeData):referenceElement&&!scope$1.element.contains(referenceElement)&&deactivateScope(scope$1.scopeId)}}return getUINavServiceInstance().setActiveScope(scopeId),element.dispatchEvent(new CustomEvent(SCOPED_NAV_EVENTS.activate,{detail:scopeData})),scopeData},deactivateScope=(scopeId,settings$1={resumePrevious:!1})=>{let scopeIndex=scopeStack.value.findIndex(s=>s.scopeId===scopeId);if(scopeIndex===-1){logger_default.warn(`Scope ${scopeId} not found. Ignoring...`);return}notifyScopedNavObservers(SCOPED_NAV_OBSERVER_EVENTS.onBeforeScopeDeactivated,{scopeId,settings:settings$1});let scopeData=scopeStack.value[scopeIndex],element=scopeData.element,{type}=element[SCOPED_NAV_PROPERTY_NAME];if(scopeStack.value=scopeStack.value.slice(0,scopeIndex),element.dispatchEvent(new CustomEvent(SCOPED_NAV_EVENTS.deactivate,{detail:{scopeId,settings:settings$1,...scopeData}})),notifyScopedNavObservers(SCOPED_NAV_OBSERVER_EVENTS.onScopeDeactivated,{scopeId,settings:settings$1}),!settings$1.resumePrevious){getUINavServiceInstance().setActiveScope(null);return}let parentScope;if(type===SCOPED_NAV_TYPES.popover){let popover=usePopover(),popoverName=element.getAttribute(`data-bng-popover-name`),pop=popover.getPopover(popoverName);pop?parentScope=findParentScope(pop.target,!0):logger_default.warn(`Unable to find popover's target element. Skipping resume...`)}else parentScope=findParentScope(element,!0);parentScope?getScopeById(parentScope.scopeId)?resumeScope(parentScope.scopeId):activateScope(parentScope.scopeId,parentScope.element):getUINavServiceInstance().setActiveScope(null)},resumeScope=scopeId=>{let scopeIndex=scopeStack.value.findIndex(s=>s.scopeId===scopeId);if(scopeIndex===-1){logger_default.warn(`Scope ${scopeId} not found. Ignoring...`);return}notifyScopedNavObservers(SCOPED_NAV_OBSERVER_EVENTS.onBeforeScopeResumed,{scopeId});for(let i=scopeStack.value.length-1;i>scopeIndex;i--){let scope$1=scopeStack.value[i];deactivateScope(scope$1.scopeId)}let scopeData=scopeStack.value[scopeIndex];return scopeData.activationType=SCOPED_NAV_STATES.active,getUINavServiceInstance().setActiveScope(scopeData.scopeId),scopeData.element.dispatchEvent(new CustomEvent(SCOPED_NAV_EVENTS.resume,{detail:scopeData})),notifyScopedNavObservers(SCOPED_NAV_OBSERVER_EVENTS.onScopeResumed,{scopeId}),scopeData},suspendScope=(scopeId,newScope)=>{let scopeIndex=scopeStack.value.findIndex(s=>s.scopeId===scopeId);if(scopeIndex===-1){logger_default.warn(`Scope ${scopeId} not found. Ignoring...`);return}notifyScopedNavObservers(SCOPED_NAV_OBSERVER_EVENTS.onBeforeScopeSuspended,{scopeId,newScope});let scopeData=scopeStack.value[scopeIndex];if(scopeData.activationType===SCOPED_NAV_STATES.suspended){logger_default.warn(`Scope ${scopeId} already suspended. Ignoring...`);return}scopeData.activationType=SCOPED_NAV_STATES.suspended;let element=scopeData.element,payload={scopeId,newScope,...scopeData};return element.dispatchEvent(new CustomEvent(SCOPED_NAV_EVENTS.suspend,{detail:payload})),notifyScopedNavObservers(SCOPED_NAV_OBSERVER_EVENTS.onScopeSuspended,{scopeId,newScope}),scopeData},currentScope=()=>scopeStack.value[scopeStack.value.length-1],getScopeById=scopeId=>scopeStack.value.find(s=>s.scopeId===scopeId);return{activateScope,deactivateScope,resumeScope,suspendScope,getScopeById,currentScope,isCurrentScope:scopeId=>{let scope$1=currentScope();return scope$1&&scope$1.scopeId===scopeId},isActiveScope:scopeId=>{let current=currentScope();if(!current)return!1;if(current.scopeId===scopeId)return!0;if(current.activationType===SCOPED_NAV_STATES.partial&&scopeStack.value.length>2){let parentScope=scopeStack.value[scopeStack.value.length-2];if(parentScope.scopeId===scopeId&&parentScope.activationType===SCOPED_NAV_STATES.active)return!0}return!1},getScopes:()=>scopeStack.value}});var focusDebounceTimer=null,pendingFocusAction=null,focusListenersInitialized=!1,isActivatingScope=!1,isDeactivatingScope=!1,FOCUS_DEBOUNCE_TIME=200,focusManagerId=`focusManager`,clearFocusDebounce=()=>{focusDebounceTimer&&=(clearTimeout(focusDebounceTimer),null),pendingFocusAction=null},debouncedFocusAction=action=>{clearFocusDebounce(),pendingFocusAction=action,focusDebounceTimer=setTimeout(()=>{pendingFocusAction&&=(pendingFocusAction(),null),focusDebounceTimer=null},FOCUS_DEBOUNCE_TIME)};function useFocusManager(){let scopedNav=useScopedNav(),onUINavFocus=e=>{let{target,relatedTarget}=e.detail;if(isWithinDashmenu(target)||isWithinPopup(target))return;let targetScope=findParentScope(target,!0),scopeElement=targetScope&&targetScope.isScopedNav?targetScope.element:null,scopedNavProps=scopeElement&&scopeElement._bngScopedNav?scopeElement[SCOPED_NAV_PROPERTY_NAME]:null;if(scopedNavProps&&(scopeElement[SCOPED_NAV_PROPERTY_NAME].lastActiveElement=target),isActivatingScope||isDeactivatingScope||shouldSkipFocusHandling(scopedNavProps)){clearFocusDebounce();return}debouncedFocusAction(()=>handleFocusAction(target,targetScope,scopeElement,scopedNav))},onUINavBlur=e=>{let{target}=e.detail,scopeProperties=getScopeProperties(target);shouldHandleBlur(scopeProperties,scopedNav.currentScope())&&(target[SCOPED_NAV_PROPERTY_NAME].passthroughActive=!1,scopedNav.deactivateScope(scopeProperties.scopeId,{resumePrevious:!0}))};function addFocusListeners(){focusListenersInitialized||=(document.addEventListener(`uinav-focus`,onUINavFocus),document.addEventListener(`uinav-blur`,onUINavBlur),registerScopedNavObserver(focusManagerId,{onBeforeScopeActivated:()=>{clearFocusDebounce(),isActivatingScope=!0},onScopeActivated:()=>{clearFocusDebounce(),isActivatingScope=!1},onBeforeScopeDeactivated:()=>{clearFocusDebounce(),isDeactivatingScope=!0},onScopeDeactivated:()=>{clearFocusDebounce(),isDeactivatingScope=!1}}),!0)}function removeFocusListeners(){focusListenersInitialized&&=(document.removeEventListener(`uinav-focus`,onUINavFocus),document.removeEventListener(`uinav-blur`,onUINavBlur),!1)}function setup$3(){addFocusListeners()}function dispose$2(){removeFocusListeners()}return onMounted(()=>{setup$3()}),onBeforeUnmount(()=>{dispose$2()}),{setup:setup$3,dispose:dispose$2}}function isWithinDashmenu(target){return document.getElementById(`dashmenu`)?.contains(target)}function isWithinPopup(target){return!!target.closest(`dialog`)}function shouldSkipFocusHandling(scopedNavProps){return scopedNavProps?.type===SCOPED_NAV_TYPES.popover}function shouldHandleBlur(scopeProperties,currScope){return scopeProperties?.isScopedNav&&currScope?.scopeId===scopeProperties.scopeId&&currScope?.activationType===SCOPED_NAV_STATES.partial}function handleFocusAction(target,targetScope,scopeElement,scopedNavStore){if(!document.contains(target)&&!document.contains(scopeElement))return;let activeScope=scopedNavStore.currentScope();if(activeScope?.element===target)return;let existingScope,scopes=scopedNavStore.getScopes();for(let i=scopes.length-1;i>=0;i--){let scope$1=scopes[i];if(scope$1.element===scopeElement){existingScope=scope$1;break}}if(existingScope&&activeScope&&existingScope.scopeId!==activeScope.scopeId){scopedNavStore.resumeScope(existingScope.scopeId);return}scopes=scopedNavStore.getScopes();for(let i=scopes.length-1;i>=0;i--){let scope$1=scopes[i];if(scope$1.element===target||scope$1.element.contains(target)||scopeElement===scope$1.element||scope$1.element.contains(scopeElement))break;scopedNavStore.deactivateScope(scope$1.scopeId)}if(scopes=scopedNavStore.getScopes(),targetScope&&targetScope.isScopedNav){let lastScope=scopes.length>0?scopes[scopes.length-1]:null;lastScope&&activeScope&&activeScope.scopeId===lastScope.scopeId&&targetScope.scopeId!==lastScope.scopeId&&lastScope.activationType!==SCOPED_NAV_STATES.suspended&&scopedNavStore.suspendScope(lastScope.scopeId,{scopeId:targetScope.scopeId,scopeElement}),(!activeScope||activeScope.scopeId!==targetScope.scopeId)&&scopeElement._bngScopedNav.canActivate()&&scopedNavStore.activateScope(targetScope.scopeId,scopeElement)}if(target.hasAttribute(`bng-scoped-nav`)){let allowPartialActivation=target[SCOPED_NAV_PROPERTY_NAME].passthroughEnabled,canActivate=target[SCOPED_NAV_PROPERTY_NAME].canActivate();if(target[SCOPED_NAV_PROPERTY_NAME].passthroughActive=!0,allowPartialActivation&&canActivate){let partialScope=getScopeProperties(target);scopedNavStore.activateScope(partialScope.scopeId,target,{activationType:SCOPED_NAV_STATES.partial})}}}var PROPERTY_NAME=`_bngScopedNav`,ATTR_NAME=`bng-scoped-nav`,AUTOFOCUS_ATTR=`bng-scoped-nav-autofocus`,UI_SCOPE_ATTR=`bng-ui-scope`,NAV_ITEM_ATTR=`bng-nav-item`,BNG_ON_UI_NAV_ATTR=`__BngOnUiNav`,DEFAULT_AUTO_FOCUS_DELAY=100,EVENTS_UINAV_MAP={activate:[UI_EVENTS.ok],deactivate:[UI_EVENTS.back],navigation:[...UI_EVENT_GROUPS.focusMove,...UI_EVENT_GROUPS.focusMoveScalar]},NAV_EVENTS={activate:`activate`,deactivate:`deactivate`,suspend:`suspend`,resume:`resume`};const ACTIONS_ON_SUSPEND={allowNavigationLastNavItem:`allowNavigationLastNavItem`,allowNavigationByAttribute:`allowNavigationByAttribute`,disableNavigation:`disableNavigation`};var BngScopedNav_default={beforeMount,mounted,updated,beforeUnmount,unmounted},getDefaultOptions=()=>({type:SCOPED_NAV_TYPES.normal,activateOnMount:!1,actionsOnSuspend:[ACTIONS_ON_SUSPEND.disableNavigation],bubbleWhitelistEvents:[],bubbleBlacklistEvents:[],forcePassthroughEvents:[],canActivate:()=>!0,canDeactivate:()=>!0,autoFocusDelay:DEFAULT_AUTO_FOCUS_DELAY}),canBubbleEventInternal=(el,e)=>{let{bubbleWhitelistEvents,canBubbleEvent}=el[PROPERTY_NAME];return canBubbleEvent&&typeof canBubbleEvent==`function`?canBubbleEvent(e):bubbleWhitelistEvents&&Array.isArray(bubbleWhitelistEvents)&&bubbleWhitelistEvents.length>0?bubbleWhitelistEvents.includes(e.detail.name):!1},shouldBubbleToNextScope=(el,e)=>{let currentScope=useScopedNav().currentScope(),{scopeId,type}=el[PROPERTY_NAME],isActive=currentScope&¤tScope.scopeId===scopeId,isPartial=isActive&¤tScope.activationType===SCOPED_NAV_STATES.partial,isContainer=type===SCOPED_NAV_TYPES.container,isInactiveAndFocused=document.activeElement===el&&!isActive;return!currentScope||isInactiveAndFocused||canBubbleEventInternal(el,e)||isPartial||isContainer},getOptions=(el,binding,vnode)=>{let options={...getDefaultOptions(),...binding.value};if(!Object.values(SCOPED_NAV_TYPES).includes(options.type)){console.error(`Invalid scoped nav type: ${options.type}`);return}return options},applyOptions=(el,options)=>{let attributes={};switch(options.type){case SCOPED_NAV_TYPES.normal:attributes[NAV_ITEM_ATTR]=``,attributes[NO_CHILD_NAV_ATTR]=`true`;break;case SCOPED_NAV_TYPES.nonav:attributes[NO_NAV_ATTR]=`true`,attributes[NO_CHILD_NAV_ATTR]=`true`;break}Object.keys(attributes).forEach(attr=>el.setAttribute(attr,attributes[attr]))},findAutoFocusItem=navItems=>navItems.find(item=>item.hasAttribute(AUTOFOCUS_ATTR)&&item.getAttribute(AUTOFOCUS_ATTR)!==`false`),getAutoFocusItem=el=>findAutoFocusItem(getNavItems(el)),getFirstOrDefaultNavItem=el=>{let navItems,isAutoFocusItem=!1,getNavItems$1=()=>navItems||=getNavItems(el),getLastActive=()=>{let elm=el[PROPERTY_NAME].lastActiveElement;return elm&&!document.contains(elm)?null:elm},getAutoFocus=()=>{let elm=findAutoFocusItem(getNavItems$1());return elm&&!isNavigable(elm)?null:(isAutoFocusItem=!!elm,elm)},getFirst=()=>getNavItems$1()[0],sequence=[getLastActive,getAutoFocus];el[PROPERTY_NAME].preferAutoFocus&&sequence.reverse(),sequence.push(getFirst);for(let func of sequence){let elm=func();if(elm)return{focusItem:elm,isAutoFocusItem}}return{focusItem:null,isAutoFocusItem:!1}},setEnabledNavigation=(el,enabled,settings$1={applyToChildItems:!1,filterElements:void 0})=>{let{type}=el[PROPERTY_NAME];if(type===SCOPED_NAV_TYPES.nonav){logger_default.warn(`Cannot toggle navigation settings for nonav type`,el,enabled,type);return}settings$1.applyToChildItems?getNavItems(el,!1).forEach(item=>{if(!(settings$1.filterElements&&settings$1.filterElements.includes(item))){if(!item[PROPERTY_NAME]){let currentValue=item.hasAttribute(`bng-no-nav`)?item.getAttribute(NO_NAV_ATTR):void 0;item[PROPERTY_NAME]={originalNoNav:currentValue,hadOriginalNoNav:currentValue!==void 0}}enabled?(item[PROPERTY_NAME].hadOriginalNoNav?item.setAttribute(NO_NAV_ATTR,item[PROPERTY_NAME].originalNoNav):item.removeAttribute(NO_NAV_ATTR),item[PROPERTY_NAME].noNavSetByDirective=!1):(!item[PROPERTY_NAME].hadOriginalNoNav||item[PROPERTY_NAME].originalNoNav!==`true`)&&(item.setAttribute(NO_NAV_ATTR,`true`),item[PROPERTY_NAME].noNavSetByDirective=!0)}}):enabled?(el.removeAttribute(NO_CHILD_NAV_ATTR),type===SCOPED_NAV_TYPES.normal&&el.setAttribute(NO_NAV_ATTR,`true`)):(el.setAttribute(NO_CHILD_NAV_ATTR,`true`),type===SCOPED_NAV_TYPES.normal&&el.removeAttribute(NO_NAV_ATTR))},focusFirstOrDefaultNavItem=el=>{let{autoFocusDelay}=el[PROPERTY_NAME];nextTick(()=>{setTimeout(()=>{let{focusItem,isAutoFocusItem}=getFirstOrDefaultNavItem(el);focusItem&&setFocusExternal(focusItem,!0,isAutoFocusItem)},autoFocusDelay)})},ensureFocusOrFocusDefault=el=>{document.activeElement&&isDirectChild(el,document.activeElement)?ensureFocus(document.activeElement,!0):focusFirstOrDefaultNavItem(el)};function beforeMount(el,binding,vnode){let options=getOptions(el,binding,vnode);if(!options)return;let scopeId=options.scopeId||uniqueId(`scoped-nav`);el[PROPERTY_NAME]={scopeId,...options},el[PROPERTY_NAME].shouldBubbleEvent=e=>shouldBubbleToNextScope(el,e),el.setAttribute(ATTR_NAME,scopeId),el.setAttribute(UI_SCOPE_ATTR,scopeId),applyOptions(el,options)}function mounted(el,binding,vnode){addUINavEventListeners(el,binding,vnode),addScopedNavEventListeners(el);let scopedNav=useScopedNav(),options=getOptions(el,binding,vnode);options.type===SCOPED_NAV_TYPES.normal?configurePartialActivation(el):options.type===SCOPED_NAV_TYPES.container&&configureContainer(el,!1),options.activateOnMount&&nextTick(()=>scopedNav.activateScope(el[PROPERTY_NAME].scopeId,el))}var handleDefaultUpdate=(el,binding,vnode)=>{let activeScope=useScopedNav().currentScope(),{scopeId,type}=el[PROPERTY_NAME];!activeScope||activeScope.scopeId!==scopeId||activeScope.activationType!==SCOPED_NAV_STATES.active||ensureFocusOrFocusDefault(el)};function updated(el,binding,vnode){let options=getOptions(el,binding,vnode),{scopeId}=el[PROPERTY_NAME],scopedNav=useScopedNav();if(options.activated===!0&&!scopedNav.isActiveScope(scopeId))if(scopedNav.getScopeById(scopeId)){let popover=usePopover();if(Object.values(popover.popovers).filter(x=>x.show===!0).length>0)return;scopedNav.resumeScope(scopeId,el)}else scopedNav.activateScope(scopeId,el,{activationType:SCOPED_NAV_STATES.active,suspendParentScopes:!0});else options.activated===!1&&scopedNav.isActiveScope(scopeId)?scopedNav.deactivateScope(scopeId,{resumePrevious:!0}):!scopedNav.isActiveScope(scopeId)&&options.type===SCOPED_NAV_TYPES.container&&configureContainer(el,!1);nextTick(()=>{let activeScope=scopedNav.currentScope();activeScope&&activeScope.scopeId===scopeId&&handleDefaultUpdate(el,binding,vnode)})}function beforeUnmount(el,binding,vnode){removeScopedNavEventListeners(el);let scopedNav=useScopedNav();if(scopedNav.getScopeById(el[PROPERTY_NAME].scopeId)){let{type}=el[PROPERTY_NAME];scopedNav.deactivateScope(el[PROPERTY_NAME].scopeId,{resumePrevious:type===SCOPED_NAV_TYPES.popover}),el.dispatchEvent(new CustomEvent(NAV_EVENTS.deactivate,{detail:{force:!0,reason:`unmounted`}}))}}function unmounted(el,binding,vnode){}var handlePartialActivation=(el,event)=>{el[PROPERTY_NAME].forceBubble=!0},handleNormalActivation=(el,event)=>{el[PROPERTY_NAME].forceBubble=!1,nextTick(()=>{setEnabledNavigation(el,!0),(!document.activeElement||el===document.activeElement||!el.contains(document.activeElement))&&focusFirstOrDefaultNavItem(el)})},configurePartialActivation=el=>{let passthroughEvents=getPassthroughEvents(el);el[PROPERTY_NAME].passthroughEnabled=passthroughEvents.length>0,el[PROPERTY_NAME].passthroughEvents=passthroughEvents},configureContainer=(el,activated)=>{el[PROPERTY_NAME].containerSetup&&el[PROPERTY_NAME].containerSetup.cancel(),el[PROPERTY_NAME].containerSetup=debounce(()=>{let autoFocusItem=getAutoFocusItem(el);autoFocusItem&&setEnabledNavigation(el,activated,{applyToChildItems:!0,filterElements:[autoFocusItem]})},100),el[PROPERTY_NAME].containerSetup()},handleContainerActivation=(el,event)=>{configureContainer(el,!0)},handleNoNavActivation=(el,event)=>{},onActivate=(el,event)=>{let{type}=el[PROPERTY_NAME],{activationType}=event.detail;activationType===SCOPED_NAV_STATES.partial?handlePartialActivation(el,event):type===SCOPED_NAV_TYPES.normal?handleNormalActivation(el,event):type===SCOPED_NAV_TYPES.container?handleContainerActivation(el,event):SCOPED_NAV_TYPES.nonav,el.dispatchEvent(new CustomEvent(NAV_EVENTS.activate,{detail:event.detail}))},onDeactivate=(el,event)=>{let{type}=el[PROPERTY_NAME];type===SCOPED_NAV_TYPES.normal&&event.detail.activationType===SCOPED_NAV_STATES.active?setEnabledNavigation(el,!1):type===SCOPED_NAV_TYPES.container&&configureContainer(el,!1),el[PROPERTY_NAME].forceBubble=!1,el.dispatchEvent(new CustomEvent(NAV_EVENTS.deactivate,{detail:event.detail}))},onSuspend=(el,event)=>{let{actionsOnSuspend,type}=el[PROPERTY_NAME],filterElements=[];if(actionsOnSuspend.includes(ACTIONS_ON_SUSPEND.allowNavigationLastNavItem)){let lastActiveElement=el[PROPERTY_NAME].lastActiveElement;lastActiveElement&&document.contains(lastActiveElement)&&filterElements.push(lastActiveElement)}setEnabledNavigation(el,!1,{applyToChildItems:!0,filterElements})},onResume=(el,event)=>{let{actionsOnSuspend,type}=el[PROPERTY_NAME],filterElements=[];if(actionsOnSuspend.includes(ACTIONS_ON_SUSPEND.allowNavigationLastNavItem)){let lastActiveElement=el[PROPERTY_NAME].lastActiveElement;lastActiveElement&&document.contains(lastActiveElement)&&filterElements.push(lastActiveElement)}setEnabledNavigation(el,!0,{applyToChildItems:!0,filterElements}),ensureFocusOrFocusDefault(el)};function addScopedNavEventListeners(el){let eventHandlers={[SCOPED_NAV_EVENTS.activate]:event=>onActivate(el,event),[SCOPED_NAV_EVENTS.deactivate]:event=>onDeactivate(el,event),[SCOPED_NAV_EVENTS.suspend]:event=>onSuspend(el,event),[SCOPED_NAV_EVENTS.resume]:event=>onResume(el,event)};Object.keys(eventHandlers).forEach(eventName=>{el[PROPERTY_NAME].scopedNavListeners||(el[PROPERTY_NAME].scopedNavListeners={}),el.addEventListener(eventName,eventHandlers[eventName]),el[PROPERTY_NAME].scopedNavListeners[eventName]=eventHandlers[eventName]})}function removeScopedNavEventListeners(el){!el||!el[PROPERTY_NAME]||!el[PROPERTY_NAME].scopedNavListeners||Object.keys(el[PROPERTY_NAME].scopedNavListeners).forEach(eventName=>{el.removeEventListener(eventName,el[PROPERTY_NAME].scopedNavListeners[eventName]),delete el[PROPERTY_NAME].scopedNavListeners[eventName]})}var allowsNavigation=el=>{let{type}=el[PROPERTY_NAME];return[SCOPED_NAV_TYPES.normal,SCOPED_NAV_TYPES.container,SCOPED_NAV_TYPES.popover].includes(type)},processNavigationEvent=(el,e)=>{let currentScope=useScopedNav().currentScope(),{scopeId}=el[PROPERTY_NAME];if(!allowsNavigation(el))return!1;document.activeElement===el&¤tScope.scopeId===scopeId?focusFirstOrDefaultNavItem(el):handleUINavEvent(e,el)},isNavigationEvent=e=>UI_EVENT_GROUPS.navigation.includes(e.detail.name),getUINavEventsByEl=el=>{let uiNavEvents=el[BNG_ON_UI_NAV_ATTR]?Object.values(el[BNG_ON_UI_NAV_ATTR]).map(x=>x.eventNames).flat():[],boundEvents=[];return uiNavEvents.forEach(ev=>{boundEvents.includes(ev)||boundEvents.push(ev)}),boundEvents},hasBoundEvent=(el,eventName)=>{let boundEvents=getUINavEventsByEl(el);return boundEvents&&boundEvents.length>0&&boundEvents.includes(eventName)},isUINavEventBoundToChild=(el,e)=>{let{scopeId}=el[PROPERTY_NAME],currentScope=useScopedNav().currentScope();return currentScope&¤tScope.scopeId===scopeId&&e.target!==el&&el.contains(e.target)&&e.target===document.activeElement&&hasBoundEvent(e.target,e.detail.name)},generalHandler=(el,e)=>{let shouldBubble=!1;return isUINavEventBoundToChild(el,e)&&!e.target.hasAttribute(ATTR_NAME)||(shouldBubbleToNextScope(el,e)?shouldBubble=!0:isNavigationEvent(e)&&processNavigationEvent(el,e)),shouldBubble},processOkChildHandler=(el,e)=>{isUINavEventBoundToChild(el,e)||(handleUINavEvent(e,e.target),e.detail.sendToCrossfire=!1)},okHandler=(el,e)=>{if(e.detail.value!==1)return shouldBubbleToNextScope(el,e);let scopedNav=useScopedNav(),scopeId=el[PROPERTY_NAME].scopeId,currentScope=scopedNav.currentScope();return currentScope&¤tScope.scopeId===scopeId&¤tScope.activationType===SCOPED_NAV_STATES.active&&(document.activeElement&&isDirectChild(el,document.activeElement)||e.target&&isDirectChild(el,e.target))?processOkChildHandler(el,e):el[PROPERTY_NAME].canActivate()&&el[PROPERTY_NAME].type===SCOPED_NAV_TYPES.normal&&document.activeElement===el&&scopedNav.activateScope(scopeId,el),shouldBubbleToNextScope(el,e)},backHandler=(el,e)=>{if(e.detail.value!==1)return;let scopedNav=useScopedNav(),{scopeId,type,canDeactivate}=el[PROPERTY_NAME],currentScope=scopedNav.currentScope();if(currentScope&¤tScope.scopeId===scopeId&¤tScope.activationType===SCOPED_NAV_STATES.active)canDeactivate()&&(scopedNav.deactivateScope(scopeId,{resumePrevious:!0,executingScope:scopeId}),type===SCOPED_NAV_TYPES.normal&&nextTick(()=>setFocusExternal(el)));else if(e.target!==el&&isDirectChild(el,e.target))return!1;else return!0},uiNavEventsHandler=(el,e)=>{let uiNavEvent=e.detail.name;return EVENTS_UINAV_MAP.activate.includes(uiNavEvent)?okHandler(el,e):EVENTS_UINAV_MAP.deactivate.includes(uiNavEvent)?backHandler(el,e):generalHandler(el,e)};function addUINavEventListeners(el,binding,vnode){let{bubbleWhitelistEvents}=el[PROPERTY_NAME],generalUINavBinding={arg:[...EVENTS_UINAV_MAP.activate,...EVENTS_UINAV_MAP.deactivate,...EVENTS_UINAV_MAP.navigation].join(`,`),value:e=>uiNavEventsHandler(el,e)};BngOnUiNav_default.mounted(el,generalUINavBinding,vnode)}var ID=`__bngSound`,ID_STOP=`__bngSoundStop`,events$1={click:`click`,dblclick:`dblclick`,focus:`focus`,mouseenter:`mouseenter`};function handler(ev){let el=ev.currentTarget;if(el&&(el[ID]&&events$1[ev.type]&&Lua_default.ui_audio.playEventSound(el[ID],events$1[ev.type]),el[ID_STOP]))for(let event in delete el[ID_STOP],delete el[ID],events$1)el.removeEventListener(event,handler)}var BngSoundClass_default={mounted:(el,binding)=>{delete el[ID_STOP],el[ID]=binding.value,nextTick(()=>{for(let event in events$1)el.addEventListener(event,handler)})},updated:(el,binding)=>{el[ID]=binding.value},unmounted:el=>{el[ID_STOP]=!0}},marker=`__BNG_SD_INPUT`,inputTypes={singleLine:0,multiLine:1};function bindToInputs(elements){let inputs=Array.isArray(elements)?elements:[elements];for(let input of inputs){if(marker in input)continue;input[marker]=!0;let type,tag=input.tagName.toLowerCase();if(tag===`textarea`)type=inputTypes.multiLine;else if(tag===`input`&&[`text`,`number`,`password`,`search`].includes(input.type.toLowerCase()))type=inputTypes.singleLine;else continue;input.addEventListener(`focus`,()=>{let rect=input.getBoundingClientRect();console.log(`SteamDeck input focus:`,type,rect),Lua_default.Steam.showFloatingGamepadTextInput(type,rect.left,rect.top,rect.width,rect.height)})}}async function useSteamDeckInput(inputs){if(!inputs)throw Error(`inputs must be specified (ref, refs, element, elements)`);(await useSettingsAsync()).values.runningOnSteamDeck&&(isRef(inputs)?watch(inputs,bindToInputs,{immediate:!0}):bindToInputs(inputs))}var bridge$1,focused=!1,elms={},elmid=`__BNG_TEXT_INPUT`,focus=id=>async()=>{elms[id].active=!0,focused||=(await bridge$1.lua.setCEFTyping(!0),!0)},blur=id=>async()=>{elms[id].active=!1,focused&&(focused=Object.values(elms).some(e=>e.active),focused||await bridge$1.lua.setCEFTyping(!1))},BngTextInput_default={mounted(el){bridge$1||(bridge$1=useBridge(),bridge$1.events.on(`CEFTypingLostFocus`,()=>focused&&document.activeElement.blur()));let id=el[elmid]||(el[elmid]=uniqueId());elms[id]={el,active:!1,onFocus:focus(id),onBlur:blur(id)},el.addEventListener(`focus`,elms[id].onFocus),el.addEventListener(`blur`,elms[id].onBlur),useSteamDeckInput(el)},beforeUnmount(el){let id=el[elmid];elms[id]&&(el.removeEventListener(`focus`,elms[id].onFocus),el.removeEventListener(`blur`,elms[id].onBlur),elms[id].onBlur(),delete elms[id])}},DEFAULT_POSITION=`left`,TOOLTIP_ATTR_NAME=`data-bng-tooltip`,CONTENT_ATTR_NAME=`data-bng-tooltip-content`,ARROW_ATTR_NAME=`data-bng-tooltip-arrow`,SHOW_TOOLTIP_EVENTS=[`mouseover`,`focusin`],HIDE_TOOLTIP_EVENTS=[`mouseout`,`focusout`],DATA_PROP=`__bngTooltip`,POPOVER_CONTAINER=`.popover-container`,BngTooltip_default={beforeMount(el){initTooltipData(el)},mounted(el,binding,vnode){setupBindings(el,binding),setupTooltip(el),setListeners(el)},beforeUpdate(el,binding){setupBindings(el,binding),el[DATA_PROP].text===void 0?removeTooltip(el):updateTooltipElement(el)},updated(el){let data=el[DATA_PROP];data.update&&requestAnimationFrame(()=>data.update())},beforeUnmount(el){SHOW_TOOLTIP_EVENTS.forEach(eventName=>el.removeEventListener(eventName,el.__showTooltip)),HIDE_TOOLTIP_EVENTS.forEach(eventName=>el.removeEventListener(eventName,el.__hideTooltip));let data=el[DATA_PROP];data.dispose&&data.dispose(),removeTooltip(el)}};function setListeners(el){let data=el[DATA_PROP];data.showTooltip||(data.showTooltip=event=>{data.hideDelay&&=(clearTimeout(data.hideDelay),null),data.tooltipAnimationFrame&&=(cancelAnimationFrame(data.tooltipAnimationFrame),null),el.contains(event.target)&&!data.tooltipElRef.value&&queueTooltipUpdate(el,!0)},SHOW_TOOLTIP_EVENTS.forEach(eventName=>el.addEventListener(eventName,data.showTooltip,!0))),data.hideTooltip||(data.hideTooltip=event=>{data.tooltipAnimationFrame&&=(cancelAnimationFrame(data.tooltipAnimationFrame),null),!el.contains(event.relatedTarget)&&data.tooltipElRef.value&&queueTooltipUpdate(el,!1)},HIDE_TOOLTIP_EVENTS.forEach(eventName=>el.addEventListener(eventName,data.hideTooltip,!0)))}function setupBindings(el,binding){if(binding.value){let bindingValues=getBindings(binding);el[DATA_PROP].text=bindingValues.text,el[DATA_PROP].hideDelayTime=bindingValues.hideDelay,el[DATA_PROP].position=bindingValues.position,el[DATA_PROP].isBBCode=bindingValues.isBBCode,el[DATA_PROP].style=bindingValues.style}else resetTooltipData(el)}function queueTooltipUpdate(el,shouldShow){let data=el[DATA_PROP];data.tooltipAnimationFrame&&cancelAnimationFrame(data.tooltipAnimationFrame),data.pendingTooltipState=shouldShow,data.tooltipAnimationFrame=requestAnimationFrame(()=>{data.pendingTooltipState?showTooltip(el):hideTooltip(el),data.tooltipAnimationFrame=null,data.pendingTooltipState=null})}function showTooltip(el){let data=el[DATA_PROP];data.text&&(addTooltip(el),usePopover().show(data.popoverName,el))}function hideTooltip(el){let data=el[DATA_PROP],hideFn=()=>{removeTooltip(el)};data.hideDelayTime&&typeof data.hideDelayTime==`number`&&data.hideDelayTime>0?data.hideDelay=setTimeout(()=>{hideFn(),data.hideDelay=null},data.hideDelayTime):hideFn()}function setupTooltip(el){let data=el[DATA_PROP],popover=usePopover(),popoverInstance=popover.register(data.popoverName,data.tooltipElRef,data.position,{arrow:data.arrowElRef,offset:4});if(!popoverInstance){console.error(`Failed to register tooltip`);return}el[DATA_PROP].update=popoverInstance.update,el[DATA_PROP].dispose=()=>popover.unregister(data.popoverName),popover.bind(data.popoverName,el,{placement:data.position})}function updateTooltipElement(el){if(el[DATA_PROP].tooltipElRef.value&&el[DATA_PROP].tooltipElRef.value){let updatedContent=parseText(el[DATA_PROP].text,el[DATA_PROP].isBBCode),spanEl=el[DATA_PROP].tooltipElRef.value.querySelector(`span`);spanEl.innerHTML=updatedContent}}function addTooltip(el){let data=el[DATA_PROP];data.tooltipElRef.value=createTooltip(data);let popoverContainer=document.querySelector(POPOVER_CONTAINER);popoverContainer||=(console.warn(`Popover container not found, using parent element`),el.parentElement),el[DATA_PROP].arrowElRef.value=createArrow(),data.tooltipElRef.value.appendChild(el[DATA_PROP].arrowElRef.value),popoverContainer.appendChild(data.tooltipElRef.value)}function removeTooltip(el){let data=el[DATA_PROP];usePopover().hide(data.popoverName),data.tooltipElRef.value&&(data.tooltipElRef.value.remove(),data.tooltipElRef.value=null),data.update&&data.update()}function createTooltip(data){let container=document.createElement(`div`);return data.style&&Object.keys(data.style).forEach(key=>container.style.setProperty(key,data.style[key])),container.setAttribute(TOOLTIP_ATTR_NAME,``),container.appendChild(createContent(data.text,data.isBBCode)),container}function createContent(text,isBBCode){let content=document.createElement(`span`);return Object.assign(content.style,{}),content.innerHTML=parseText(text,isBBCode),content.setAttribute(CONTENT_ATTR_NAME,``),content}function createArrow(){let arrow$3=document.createElement(`span`);return Object.assign(arrow$3.style,{}),arrow$3.setAttribute(ARROW_ATTR_NAME,``),arrow$3}function parseText(text,isBBCode){return isBBCode?parse$1(text):text}var getBindings=binding=>{let position=binding.arg?binding.arg:DEFAULT_POSITION,hideDelay,text,isBBCode=!1,style={};return typeof binding.value==`object`?(hideDelay=binding.value?.hideDelay||0,text=binding.value?.text||void 0,isBBCode=binding.value?.isBBCode||!1,style=binding.value?.style||{}):text=binding.value,{text,position,hideDelay,isBBCode,style}};function initTooltipData(el){el[DATA_PROP]={popoverName:uniqueId(`bng-tooltip`),tooltipElRef:ref(null),arrowElRef:ref(null)},resetTooltipData(el)}function resetTooltipData(el){el[DATA_PROP].text=void 0,el[DATA_PROP].style={},el[DATA_PROP].isBBCode=!1,el[DATA_PROP].hideDelayTime=void 0,el[DATA_PROP].position=void 0,el[DATA_PROP].hideDelay=null,el[DATA_PROP].tooltipAnimationFrame=null}var reg=(elm,{value})=>nextTick(()=>elm&&wantsFocus(elm,value)),BngUiNavFocus_default={mounted:reg,updated:reg,beforeUnmount:unwantsFocus},registry,procEventNames=eventNames=>eventNames.split(`,`).map(name=>name.trim()).filter(Boolean),BngUiNavLabel_default={mounted(el,{arg:eventNames,value:label}){if(!eventNames){console.warn(`Usage: v-bng-ui-nav-label:back,menu="'Back'"`);return}registry||=useUiNavLabel(),label&&(eventNames=procEventNames(eventNames),registry.registerLabel(el,eventNames,label))},updated(el,{arg:eventNames,value:label}){eventNames&&(eventNames=procEventNames(eventNames),label?registry.registerLabel(el,eventNames,label):registry.clearLabels(el,eventNames))},beforeUnmount(el){let events$3=registry.getElementEvents(el);events$3.length>0&®istry.clearLabels(el,events$3)}},SCROLL_PROP=`__bngUiNavScroll`;function enableScroll(id,el){let tracker=useUINavTracker();tracker.addEvent(SCROLL_EVENT_H,id,el),tracker.addEvent(SCROLL_EVENT_V,id,el),tracker.addForceUnblock(SCROLL_EVENT_H,id),tracker.addForceUnblock(SCROLL_EVENT_V,id)}function disableScroll(id,el){let tracker=useUINavTracker();tracker.removeEvent(SCROLL_EVENT_H,id,el),tracker.removeEvent(SCROLL_EVENT_V,id,el),tracker.removeForceUnblock(SCROLL_EVENT_H,id),tracker.removeForceUnblock(SCROLL_EVENT_V,id)}var BngUiNavScroll_default={mounted(element,{arg,value,modifiers}){let prev=element[SCROLL_PROP]||{},dir={id:prev.id||uniqueId(SCROLL_PROP),forced:modifiers.force,enable:()=>enableScroll(dir.id,element),disable:()=>disableScroll(dir.id,element)};if(element[SCROLL_PROP]=dir,prev.forced&&(element.removeEventListener(`focusin`,prev.enable),element.removeEventListener(`focusout`,prev.disable)),typeof value==`boolean`&&!value){prev.id&&prev.disable(),dir.forced=!1;return}dir.forced?(element.setAttribute(SCROLL_FORCE_ATTR,``),dir.enable()):(element.setAttribute(SCROLL_ATTR,``),element.addEventListener(`focusin`,dir.enable),element.addEventListener(`focusout`,dir.disable))},beforeUnmount(element){let dir=element[SCROLL_PROP];dir&&(dir.forced||(element.removeEventListener(`focusin`,dir.enable),element.removeEventListener(`focusout`,dir.disable)),dir.disable(),delete element[SCROLL_PROP])}},observed=new WeakMap;function createObserver(root=null,rootMargin=`0px`){return new IntersectionObserver(entries=>{for(let entry of entries){let data=observed.get(entry.target);if(!data){entry.target.observer?.unobserve(entry.target);return}if(data.onChange)data.onChange(entry.isIntersecting);else{let displayValue=entry.isIntersecting?[`display`,``,``]:[`display`,`none`,`important`];entry.target.style.setProperty(...displayValue),entry.target.querySelectorAll(`*`).forEach(child=>{child.style.setProperty(...displayValue)})}}},{root,rootMargin,threshold:0})}var defaultObserver=createObserver(),_sfc_main$404={__name:`bngActionDrawer`,props:{actions:{type:Object,default:{allowOpenDrawer:!1}},skeletonItems:{type:Number,default:5},usePath:Boolean,alwaysShowBack:Boolean,itemWidth:Number,itemHeight:Number,itemMargin:Number,big:Boolean,position:String,blur:Boolean},emits:[`select`],setup(__props,{expose:__expose,emit:__emit}){let props=__props,emit$1=__emit;__expose({goBack:onBack});let expanded=ref(!1),current=ref(props.actions),lazyItem={label:`…`,icon:icons.stopwatchSectionOutlinedStart};function onSelect(item){(`items`in item||item.lazyLoadItems)&&(current.value&&addBack(current.value),current.value=item),emit$1(`select`,item)}let backState=computed(()=>{let disable=back.value.length===0||!(`items`in current.value);return{show:!disable||props.alwaysShowBack,disable}}),back=ref([]);function onBack(){current.value=null,onSelect(back.value.pop().data)}function addBack(prevItem){let backItem={index:back.value.length,label:prevItem.label,data:prevItem};props.usePath&&prevItem.items&&(backItem.items=prevItem.items.reduce((res,itm)=>[...res,{index:backItem.index+1,label:itm.label,data:itm}],[])),back.value.push(backItem)}let path=computed(()=>props.usePath?[...back.value,{current:!0,label:current.value.label,data:current.value}]:void 0);function onPath(item){item.current||(back.value.splice(item.index),current.value=null,onSelect(item.data))}return watch(()=>props.actions,val=>{back.value.splice(0),current.value=val}),(_ctx,_cache)=>(openBlock(),createBlock(unref(bngDrawer_default),{modelValue:expanded.value,"onUpdate:modelValue":_cache[0]||=$event=>expanded.value=$event,expandable:current.value.allowOpenDrawer,position:__props.position,blur:__props.blur},createSlots({"header-controls":withCtx(()=>[__props.usePath?(openBlock(),createBlock(unref(bngBreadcrumbs_default),{key:0,items:path.value,limit:`5`,onClick:onPath},null,8,[`items`])):backState.value.show?(openBlock(),createBlock(unref(bngButton_default),{key:1,accent:unref(ACCENTS).outlined,disabled:backState.value.disable,onClick:onBack},{default:withCtx(()=>[..._cache[1]||=[createTextVNode(`Back`,-1)]]),_:1},8,[`accent`,`disabled`])):createCommentVNode(``,!0),renderSlot(_ctx.$slots,`controls`)]),content:withCtx(()=>[withDirectives((openBlock(),createBlock(unref(bngList_default),{layout:expanded.value?unref(LIST_LAYOUTS).TILES:unref(LIST_LAYOUTS).RIBBON,big:__props.big,"target-width":__props.itemWidth,"target-height":__props.itemHeight,"target-margin":__props.itemMargin,"no-background":``},{default:withCtx(()=>[`items`in current.value?(openBlock(!0),createElementBlock(Fragment,{key:0},renderList(current.value.items,(item,index)=>renderSlot(_ctx.$slots,`action`,{item,select:onSelect,isLoading:!1,order:index})),256)):(openBlock(!0),createElementBlock(Fragment,{key:1},renderList(__props.skeletonItems,idx=>renderSlot(_ctx.$slots,`action`,{item:lazyItem,select:()=>{},isLoading:!0})),256))]),_:3},8,[`layout`,`big`,`target-width`,`target-height`,`target-margin`])),[[unref(BngDisabled_default),!(`items`in current.value)]])]),_:2},[__props.usePath?void 0:{name:`header`,fn:withCtx(()=>[createTextVNode(toDisplayString(current.value.label),1)]),key:`0`}]),1032,[`modelValue`,`expandable`,`position`,`blur`]))}},bngActionDrawer_default=_sfc_main$404,__plugin_vue_export_helper_default=(sfc,props)=>{let target=sfc.__vccOpts||sfc;for(let[key,val]of props)target[key]=val;return target},_hoisted_1$347={class:`bng-accordion-container`},_sfc_main$403={__name:`accordion`,props:{singular:Boolean,expanded:Boolean,disabled:Boolean,animated:Boolean,selectable:[Boolean,Object],selected:Boolean,provideParent:Boolean},emits:[`selected`],setup(__props,{emit:__emit}){let props=__props,counter$1=0,items$2=[],selopts=null,emit$1=__emit;watch(()=>props.singular,val=>val&&toggle(items$2.find(itm=>itm.expanded),!0)),watch(()=>props.expanded,val=>toggle(null,val)),watch(()=>props.animated,val=>{for(let itm of items$2)itm.animated=val},{immediate:!0}),watch(()=>props.disabled,val=>{for(let itm of items$2)itm.disabled=val},{immediate:!0}),watch(()=>props.selectable,val=>{val?(selopts={multi:!1},typeof val==`object`&&(selopts={selopts,...val})):selopts=null;for(let itm of items$2)itm.selectable=selopts},{immediate:!0}),watch(()=>props.selected,val=>select(null,val));function toggle(item=null,expanded=null){if(props.singular&&!item&&expanded){if(items$2.length===0)return;item=items$2[0]}for(let itm of items$2){let exp=!itm.expandedActual;item&&itm.id!==item.id?exp=props.singular?!1:itm.expandedActual:typeof expanded==`boolean`&&(exp=expanded),itm.expandedActual=exp}}provide(`accordion-item-toggle`,toggle);function select(item=null,selected=null){let state=[];for(let itm of items$2){let sel;sel=item&&itm.id!==item.id?selopts.multi?itm.selected:!1:typeof selected==`boolean`?selected:selopts.multi?!itm.selected:!0,itm.selected!==sel&&(itm.selected=sel,state.push(itm))}state.length>0&&emit$1(`selected`,state)}provide(`accordion-item-select`,select),props.provideParent&&inject(`accordion-item-childSelect`)(select);let waitForOptions=cb=>selopts?cb():setTimeout(()=>waitForOptions(cb),50);return provide(`accordion-item-register`,item=>{item.id=counter$1++,props.expanded&&(item.expanded=props.expanded),props.disabled&&(item.disabled=props.disabled),props.selectable&&(item.selectable=props.selectable),items$2.push(item),waitForOptions(()=>{props.singular&&item.expanded&&toggle(item,!0),item.selected&&select(item,!0)})}),provide(`accordion-item-unregister`,item=>{let idx=items$2.findIndex(itm=>itm.id===item.id);idx>-1&&items$2.splice(idx,1)}),(_ctx,_cache)=>withDirectives((openBlock(),createElementBlock(`div`,_hoisted_1$347,[renderSlot(_ctx.$slots,`default`,{},void 0,!0)])),[[unref(BngDisabled_default),__props.disabled]])}},accordion_default=__plugin_vue_export_helper_default(_sfc_main$403,[[`__scopeId`,`data-v-fcd1832d`]]),_hoisted_1$346={key:0,class:`bng-accitem-content`},_sfc_main$402={__name:`accordionItem`,props:{static:Boolean,expanded:Boolean,disabled:Boolean,animated:Boolean,selectable:{type:[Boolean,Object],default:!1},selected:Boolean,data:{},navigable:{type:[Boolean,Object],default:!1},arrowBig:Boolean,primaryAction:Function,secondaryAction:Function,primaryLabel:String,secondaryLabel:String,primaryHintInline:Boolean,secondaryHintInline:Boolean,expandHintInline:Boolean},emits:[`focus`,`unfocus`,`expanded`,`selected`],setup(__props,{expose:__expose,emit:__emit}){let{showIfController}=storeToRefs(controls_default()),navBlocker=useUINavBlocker(),props=__props,elCaption=ref(),elCaptionContent=ref(),elCaptionControls=ref(),hasFocus=ref(!1),icon=computed(()=>props.arrowBig?icons.arrowLargeRight:icons.arrowSmallRight),popTip=ref();watch([()=>hasFocus.value,()=>showIfController.value],()=>{hasFocus.value&&showIfController.value&&(props.primaryHintInline&&props.primaryAction||props.secondaryHintInline&&props.secondaryAction)?popTip.value.show(elCaption.value):popTip.value.isShown()&&popTip.value.hide()});let reg$1=inject(`accordion-item-register`),unreg=inject(`accordion-item-unregister`),toggle=inject(`accordion-item-toggle`),select=inject(`accordion-item-select`),opts=reactive({id:-1,captionClick:evt=>{props.primaryAction&&evt.fromController?props.primaryAction():opts.selectable?select(opts):opts.expandClick()},expandClick:()=>!props.static&&toggle(opts),static:props.static,expandedActual:props.expanded,disabled:props.disabled,animated:props.animated,selected:props.selected,selectable:props.selectable,navigable:{enabled:!1},data:props.data}),emit$1=__emit;__expose({captionClick:opts.captionClick,focus:()=>setFocusExternal(elCaption.value,!0,!1),captionElement:computed(()=>elCaption.value)}),watch(()=>props.static,val=>opts.static=val),watch(()=>props.expanded,val=>!opts.static&&toggle(opts,val)),watch(()=>props.disabled,val=>opts.disabled=val),watch(()=>opts.disabled,val=>!val&&props.disabled&&(opts.disabled=props.disabled)),watch(()=>props.animated,val=>opts.animated=val),watch(()=>props.selectable,val=>opts.selectable=val),watch(()=>props.selected,val=>opts.selected=val),watch(()=>opts.expandedActual,val=>{emit$1(`expanded`,!opts.static&&!opts.disabled&&val)}),watch(()=>props.data,val=>opts.data=val),watch(()=>props.navigable,val=>{if(typeof val!=`object`&&typeof val==`boolean`&&!val){opts.navigable={enabled:!1};return}opts.navigable={enabled:!0,scope:null,...typeof val==`object`?val:{}}},{immediate:!0}),opts.navigable.scope&&useUINavScope(opts.navigable.scope);let onFocus=evt=>{hasFocus.value=!0,navBlocker.blockOnly(opts.static?[`context`]:[]),emit$1(`focus`,evt)},onLoseFocus=evt=>{hasFocus.value=!1,navBlocker.clear(),emit$1(`unfocus`,evt)};return provide(`accordion-item-childSelect`,select$1=>(item,value)=>opts.selectable&&opts.selectable.multi&&select$1(item,value)),provide(`accordion-item-parent`,opts),onMounted(()=>reg$1(opts)),onBeforeUnmount(()=>{popTip.value.isShown()&&popTip.value.hide(),unreg(opts)}),(_ctx,_cache)=>withDirectives((openBlock(),createElementBlock(`div`,{class:normalizeClass({"bng-accitem":!0,"bng-accitem-normal":!opts.static&&!opts.selectable,"bng-accitem-static":opts.static,"bng-accitem-expandable":!opts.static,"bng-accitem-selectable":opts.selectable,"bng-accitem-expanded":!opts.static&&opts.expandedActual&&!opts.disabled,"bng-accitem-selected":opts.selected})},[withDirectives((openBlock(),createElementBlock(`div`,mergeProps({ref_key:`elCaption`,ref:elCaption,class:`bng-accitem-caption`,onClick:_cache[1]||=(...args)=>opts.captionClick&&opts.captionClick(...args),onFocus,onBlur:onLoseFocus},{"bng-nav-item":opts.navigable.enabled?!0:void 0,"bng-ui-scope":opts.navigable.scope||void 0}),[opts.static?createCommentVNode(``,!0):(openBlock(),createBlock(unref(bngIcon_default),{key:0,class:normalizeClass({"bng-accitem-caption-expander":!0,"bng-accitem-caption-expander-big":__props.arrowBig}),type:icon.value,onClick:withModifiers(opts.expandClick,[`stop`])},null,8,[`class`,`type`,`onClick`])),__props.expandHintInline&&!opts.static&&hasFocus.value&&unref(showIfController)?(openBlock(),createBlock(unref(bngBinding_default),{key:1,style:{"padding-right":`0.2em`},uiEvent:`context`,controller:``})):createCommentVNode(``,!0),createBaseVNode(`span`,{ref_key:`elCaptionContent`,ref:elCaptionContent,class:`bng-accitem-caption-content`},[renderSlot(_ctx.$slots,`caption`,{},()=>[_cache[2]||=createTextVNode(`Unnamed item`,-1)],!0)],512),_ctx.$slots.controls?(openBlock(),createElementBlock(`div`,{key:2,ref_key:`elCaptionControls`,ref:elCaptionControls,class:`bng-accitem-caption-controls`,onClick:_cache[0]||=withModifiers(()=>{},[`stop`])},[renderSlot(_ctx.$slots,`controls`,{},void 0,!0)],512)):createCommentVNode(``,!0),createVNode(unref(bngPopoverContent_default),{ref_key:`popTip`,ref:popTip,placement:`right`},{default:withCtx(()=>[__props.primaryHintInline&&__props.primaryAction?(openBlock(),createBlock(unref(bngBinding_default),{key:0,uiEvent:`ok`,controller:``})):createCommentVNode(``,!0),__props.secondaryHintInline&&__props.secondaryAction?(openBlock(),createBlock(unref(bngBinding_default),{key:1,uiEvent:`action_2`,controller:``})):createCommentVNode(``,!0)]),_:1},512)],16)),[[unref(BngOnUiNav_default),void 0,`ok`,{asMouse:!0,focusRequired:!0}],[unref(BngOnUiNav_default),__props.secondaryAction?__props.secondaryAction:void 0,`action_2`,{focusRequired:!0}],[unref(BngOnUiNav_default),!opts.static&&opts.navigable.enabled?opts.expandClick:void 0,`context`,{focusRequired:!0}],[unref(BngUiNavLabel_default),__props.primaryLabel||`ui.inputActions.menu.menu_item_select.title`,`ok`],[unref(BngUiNavLabel_default),__props.secondaryLabel,`action_2`],[unref(BngUiNavLabel_default),_ctx.$tt(`ui.common.expand`)+`/`+_ctx.$tt(`ui.common.collapse`),`context`]]),createVNode(Transition,{name:opts.animated?`bng-acc-trans`:null},{default:withCtx(()=>[!opts.static&&opts.expandedActual&&!opts.disabled?(openBlock(),createElementBlock(`div`,_hoisted_1$346,[renderSlot(_ctx.$slots,`default`,{},()=>[_cache[3]||=createTextVNode(`Empty`,-1)],!0)])):createCommentVNode(``,!0)]),_:3},8,[`name`])],2)),[[unref(BngDisabled_default),opts.disabled]])}},accordionItem_default=__plugin_vue_export_helper_default(_sfc_main$402,[[`__scopeId`,`data-v-dd6087ee`]]),_sfc_main$401={__name:`accordionTree`,props:{data:[Array,Object],dataField:{type:String,required:!0},propsField:String,contentField:String,selectable:{type:[Boolean,Object],default:!1},selectedField:String,isTreeElement:Boolean},emits:[`selected`],setup(__props,{emit:__emit}){let props=__props,dataView=computed(()=>props.data&&(props.data[props.dataField]||props.data)||[]),emit$1=__emit;props.isTreeElement||(watch(()=>dataView.value,refreshSelected),watch(()=>props.selectedField&&props.selectable&&props.selectable.multi,refreshSelected),refreshSelected());let prevState=[];function refreshSelected(){if(!props.selectedField||!props.selectable||!props.selectable.multi)return;let state=[];function deepScan(arr){for(let itm of arr){let data=itm.data||itm;data[props.selectedField]&&state.push({data,selected:!0}),data[props.dataField]&&deepScan(data[props.dataField])}}deepScan(dataView.value),selected(state)}function selected(state){if(!props.isTreeElement){if(!props.selectable.multi){prevState=prevState.filter(itm=>itm.selected);for(let itm of prevState)itm.selected&&(itm.item.selected=!1,props.selectedField&&(itm.item.data[props.selectedField]=!1),state.includes(itm.item)||state.push(itm.item));prevState=state.map(item=>({selected:!!item.selected,item}))}if(props.selectedField){function deepSet(arr,value=void 0){for(let itm of arr){let val=typeof value==`boolean`?value:itm.selected,data=itm.data||itm;data[props.selectedField]=val,data[props.dataField]&&deepSet(data[props.dataField])}}deepSet(state)}}emit$1(`selected`,state)}function branchSelected(state){props.isTreeElement?emit$1(`selected`,state):selected(state)}return(_ctx,_cache)=>dataView.value.length>0?(openBlock(),createBlock(unref(accordion_default),{key:0,class:`acctree`,selectable:__props.selectable,"provide-parent":__props.isTreeElement,onSelected:selected},{default:withCtx(()=>[(openBlock(!0),createElementBlock(Fragment,null,renderList(dataView.value,entry=>(openBlock(),createBlock(unref(accordionItem_default),mergeProps({ref_for:!0},__props.propsField?entry[__props.propsField]:void 0,{selected:__props.selectedField?entry[__props.selectedField]:void 0,static:(!entry[__props.dataField]||entry[__props.dataField].length===0)&&(!__props.contentField||!entry[__props.contentField]),data:entry}),{caption:withCtx(()=>[renderSlot(_ctx.$slots,`caption`,{entry},void 0,!0)]),controls:withCtx(()=>[renderSlot(_ctx.$slots,`controls`,{entry},void 0,!0)]),default:withCtx(()=>[__props.contentField&&entry[__props.contentField]?renderSlot(_ctx.$slots,`default`,{key:0,entry},void 0,!0):createCommentVNode(``,!0),entry[__props.dataField]&&entry[__props.dataField].length>0?(openBlock(),createBlock(unref(accordionTree_default),mergeProps({key:1,ref_for:!0},props,{data:entry,"is-tree-element":!0,onSelected:branchSelected}),{caption:withCtx(({entry:entry$1})=>[renderSlot(_ctx.$slots,`caption`,{entry:entry$1},void 0,!0)]),controls:withCtx(({entry:entry$1})=>[renderSlot(_ctx.$slots,`controls`,{entry:entry$1},void 0,!0)]),_:2},1040,[`data`])):createCommentVNode(``,!0)]),_:2},1040,[`selected`,`static`,`data`]))),256))]),_:3},8,[`selectable`,`provide-parent`])):createCommentVNode(``,!0)}},accordionTree_default=__plugin_vue_export_helper_default(_sfc_main$401,[[`__scopeId`,`data-v-2ad1085d`]]),_hoisted_1$345={class:`slotted`},_sfc_main$400={__name:`aspectRatio`,props:{ratio:{type:String,default:`16:9`},imageMode:{type:String,default:`cover`,validator:value=>[`cover`,`contain`].includes(value)},image:{type:String,default:null},externalImage:{type:String,default:null}},setup(__props){useCssVars(_ctx=>({v711986eb:__props.imageMode}));let placeholderImageURL=getAssetURL(`images/noimage.png`),slots=useSlots(),props=__props,padding=computed(()=>{if(!props.ratio)return`56.25%`;let[width$1,height$1]=props.ratio.split(`:`).map(Number);return`${height$1/width$1*100}%`}),backgroundStyle=computed(()=>!props.image&&!props.externalImage?{"--padding":padding.value,backgroundImage:`none`}:props.image||props.externalImage?{"--padding":padding.value,backgroundImage:`url("${props.externalImage?props.externalImage:getAssetURL(props.image)}")`}:slots.default?{"--padding":padding.value,backgroundImage:`url("${placeholderImageURL}")`}:{});return(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,{class:`aspect-ratio`,style:normalizeStyle(backgroundStyle.value)},[createBaseVNode(`div`,_hoisted_1$345,[renderSlot(_ctx.$slots,`default`,{},void 0,!0)])],4))}},aspectRatio_default=__plugin_vue_export_helper_default(_sfc_main$400,[[`__scopeId`,`data-v-83698898`]]),_hoisted_1$344=[`data-carousel-item`],_sfc_main$399={__name:`carouselItem`,props:{value:{type:[String,Number],required:!0}},setup(__props){return(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,{class:`bng-carousel-item`,"data-carousel-item":__props.value},[renderSlot(_ctx.$slots,`default`,{},void 0,!0)],8,_hoisted_1$344))}},carouselItem_default=__plugin_vue_export_helper_default(_sfc_main$399,[[`__scopeId`,`data-v-babc74fb`]]),_hoisted_1$343={key:0,class:`navigation`},_hoisted_2$271=[`onClick`],TRANSITION_TYPES=[`fade`],_sfc_main$398={__name:`carousel`,props:{items:{type:Array,required:!0},current:{type:[String,Number],default:0},vertical:Boolean,loop:{type:Boolean,default:!0},transition:Boolean,transitionType:{type:String,default:`fade`,validator:value=>TRANSITION_TYPES.includes(value)},transitionTime:{type:Number,default:3e3},showNav:{type:Boolean,default:!0},parent:Object},setup(__props,{expose:__expose}){let props=__props,transitionTimer,carouselRoot=ref(null),carousel=ref(null),currentIndex=ref(props.current);computed(()=>``);let navState=reactive({selected:null}),showSlide=value=>{let slideIndex=parseInt(value);currentIndex.value=slideIndex,navState.selected=slideIndex,setTransition()},navShown=computed(()=>props.showNav&&!props.parent),children=[],childIndex=child=>children.findIndex(itm=>itm.element===child.element),addChild=child=>{childIndex(child)===-1&&children.push(child)},remChild=child=>{let idx=childIndex(child);idx>-1&&children.splice(idx,1)},tryParent=(_retry=0)=>{if(props.parent.addChild)props.parent.addChild(exposed);else if(_retry<100){let unwatch=watch(()=>props.parent.addChild,()=>{unwatch(),tryParent(++_retry)})}};watch(()=>props.parent,tryParent),watch(()=>navState.selected,sel=>{for(let child of children)child.showSlide&&child.showSlide(sel)}),onMounted(()=>{setTransition(),props.parent&&tryParent()}),onBeforeUnmount(()=>{transitionTimer&&=(clearInterval(transitionTimer),null),props.parent&&props.parent.remChild&&props.parent.remChild(exposed)});function showPrevious(){if(props.parent)return;let prev;currentIndex.value===0&&props.loop?prev=props.items.length-1:currentIndex.value>0&&(prev=currentIndex.value-1),prev!==void 0&&(navState.selected=prev,currentIndex.value=prev,setTransition())}function showNext(){if(props.parent)return;let next=getNext();next>-1&&(navState.selected=next,currentIndex.value=next,setTransition())}function setTransition(){transitionTimer&&clearInterval(transitionTimer),transitionTimer=setInterval(()=>{let next=getNext();next>-1&&(currentIndex.value=next)},props.transitionTime)}function getNext(){return currentIndex.value===props.items.length-1&&props.loop?0:currentIndex.value(openBlock(),createElementBlock(`div`,{ref_key:`carouselRoot`,ref:carouselRoot,class:normalizeClass({"bng-carousel":!0,"carousel-vertical":__props.vertical,[`transition-${__props.transitionType}`]:!0})},[createBaseVNode(`div`,{ref_key:`carousel`,ref:carousel,class:`carousel-content`},[createVNode(Transition,{name:__props.transitionType},{default:withCtx(()=>[(openBlock(),createBlock(carouselItem_default,{key:currentIndex.value,class:`carousel-slide`,value:currentIndex.value},{default:withCtx(()=>[renderSlot(_ctx.$slots,`item`,{item:__props.items[currentIndex.value],index:currentIndex.value},()=>[createTextVNode(toDisplayString(__props.items[currentIndex.value]),1)],!0)]),_:3},8,[`value`]))]),_:3},8,[`name`])],512),renderSlot(_ctx.$slots,`navigation`,{},()=>[navShown.value&&__props.items&&__props.items.length>1?(openBlock(),createElementBlock(`div`,_hoisted_1$343,[(openBlock(!0),createElementBlock(Fragment,null,renderList(__props.items,(item,index)=>(openBlock(),createElementBlock(`div`,{class:normalizeClass([`navigation-item`,{active:index===currentIndex.value}]),key:item.value,onClick:$event=>showSlide(index)},null,10,_hoisted_2$271))),128))])):createCommentVNode(``,!0)],!0)],2))}},carousel_default=__plugin_vue_export_helper_default(_sfc_main$398,[[`__scopeId`,`data-v-f54192e0`]]),_hoisted_1$342={key:0,class:`drawer-header`},_hoisted_2$270={key:1,class:`drawer-content`},_hoisted_3$236={key:2,class:`drawer-header`};const DRAWER_POSITION={bottom:`bottom`,top:`top`,left:`left`,right:`right`};var _sfc_main$397={__name:`drawer`,props:mergeModels({blur:Boolean,position:{type:String,default:DRAWER_POSITION.bottom,validator:val=>Object.values(DRAWER_POSITION).includes(val)}},{modelValue:{type:Boolean},modelModifiers:{}}),emits:mergeModels([`change`],[`update:modelValue`]),setup(__props,{emit:__emit}){let emit$1=__emit,expanded=useModel(__props,`modelValue`);watch(()=>expanded.value,val=>emit$1(`change`,val));let slots=useSlots(),expandedContent=computed(()=>expanded.value&&`expanded-content`in slots),hasAnyContent=computed(()=>expandedContent.value||`content`in slots);return(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,{class:normalizeClass({"bng-drawer":!0,[`drawer-pos-${__props.position}`]:!0,"drawer-expanded":expanded.value})},[__props.position===`bottom`||__props.position===`right`?withDirectives((openBlock(),createElementBlock(`div`,_hoisted_1$342,[renderSlot(_ctx.$slots,`header`,{},void 0,!0)])),[[unref(BngBlur_default),__props.blur]]):createCommentVNode(``,!0),hasAnyContent.value?withDirectives((openBlock(),createElementBlock(`div`,_hoisted_2$270,[expandedContent.value?renderSlot(_ctx.$slots,`expanded-content`,{key:0},void 0,!0):renderSlot(_ctx.$slots,`content`,{key:1},void 0,!0)])),[[unref(BngBlur_default),__props.blur]]):createCommentVNode(``,!0),__props.position===`top`||__props.position===`left`?withDirectives((openBlock(),createElementBlock(`div`,_hoisted_3$236,[renderSlot(_ctx.$slots,`header`,{},void 0,!0)])),[[unref(BngBlur_default),__props.blur]]):createCommentVNode(``,!0)],2))}},drawer_default=__plugin_vue_export_helper_default(_sfc_main$397,[[`__scopeId`,`data-v-8023232b`]]),_sfc_main$396={__name:`dynamicComponent`,props:{template:String,translateId:String,translateContext:Boolean,bbcode:Boolean,useComponents:{type:Boolean,default:!0},extraComponents:{type:Object,default:()=>({})}},setup(__props){let ALL_COMPONENTS=Object.fromEntries(Object.entries({...base_exports,...utility_exports}).filter(([name])=>name!==`DEMOS`)),attrs=useAttrs(),props=__props,template=computed(()=>{let res=props.template;return props.translateId&&(res=props.translateContext?$translate.contextTranslate(props.translateId,!0):$translate.instant(props.translateId)),res&&props.bbcode&&(res=parse$1(res)),res||``}),makeComponent=computed(()=>defineComponent({template:template.value,components:{...props.useComponents&&ALL_COMPONENTS,...props.extraComponents},data(){return attrs}}));return(_ctx,_cache)=>template.value&&makeComponent.value?(openBlock(),createBlock(resolveDynamicComponent(makeComponent.value),{key:0})):createCommentVNode(``,!0)}},dynamicComponent_default=_sfc_main$396,_hoisted_1$341={class:`shelf-wrapper`},_hoisted_2$269=[`disabled`],_hoisted_3$235=[`disabled`],storageKey=`bngshelf`,_sfc_main$395={__name:`shelf`,props:mergeModels({saveName:{type:String,default:null},limit:{type:Number,default:5,validator:val=>val>2&&val%2==1},fade:{type:Boolean,default:!1},showExtra:{type:Boolean,default:!0},neighborsFlatten:{type:Boolean,default:!1},neighborsScale:{type:Number,default:1},keepNeighborsAspectRatio:{type:Boolean,default:!1},noLoop:{type:Boolean,default:!1},navShown:{type:Boolean,default:!1},inward:{type:Number,default:0,validator:val=>val>=0&&val<=1}},{modelValue:{type:Number,default:0},modelModifiers:{}}),emits:mergeModels([`change`,`click`],[`update:modelValue`]),setup(__props,{expose:__expose,emit:__emit}){let selectedIndex=useModel(__props,`modelValue`),props=__props,emit$1=__emit,ready=ref(!1),slots=useSlots(),containerRef=ref(null),shelfItems=ref([]),displayItems=ref([]),isAnimating=ref(!1),itemIdCounter=0,lastValidIndex=0,isReverting=!1,isPrevDisabled=computed(()=>isAnimating.value||props.noLoop&&selectedIndex.value===0),isNextDisabled=computed(()=>isAnimating.value||props.noLoop&&selectedIndex.value===shelfItems.value.length-1);watch(selectedIndex,index=>{if(!isReverting){if(index=parseInt(index,10),isNaN(index)||index<0||shelfItems.value.length>0&&index>=shelfItems.value.length){isReverting=!0,selectedIndex.value=lastValidIndex,isReverting=!1;return}lastValidIndex=index,ready.value&&buildDisplayItems()}},{immediate:!0});let timings={single:400,multiStart:200,multiMiddle:200,multiEnd:200};watch(()=>slots.default?.(),update$6,{immediate:!0});function update$6(vnodes){if(ready.value){if(vnodes===void 0&&(vnodes=slots.default?.()),Array.isArray(vnodes)||(vnodes=[]),shelfItems.value=vnodes.reduce((res,vnode)=>typeof vnode.type==`symbol`&&vnode.type.toString()===`Symbol(v-fgt)`?(res.push(...vnode.children),res):(res.push(vnode),res),[]),props.saveName){let val=localStorage.getItem(`${storageKey}-${props.saveName}`);if(val!==null){let idx=parseInt(val,10);!isNaN(idx)&&idx>=0&&idxhalfLimit)continue;let itemIndex=selectedIndex.value+offset$2;if(props.noLoop){if(itemIndex<0||itemIndex>=shelfItems.value.length)continue}else itemIndex<0?itemIndex=shelfItems.value.length+itemIndex:itemIndex>=shelfItems.value.length&&(itemIndex-=shelfItems.value.length);items$2.push({vnode:shelfItems.value[itemIndex],originalIndex:itemIndex,position:offset$2,id:++itemIdCounter,style:getItemStyle(offset$2,`normal`)})}displayItems.value=items$2}function getItemStyle(position,state=`normal`){let absPosition=Math.abs(position),halfLimit=~~(props.limit/2),isExtraItem=absPosition>halfLimit,factor=halfLimit>0?absPosition/halfLimit:1,leftPercentage;if(leftPercentage=isExtraItem?(position<0?0:props.limit-1)/(props.limit-1)*100:(position+halfLimit)/(props.limit-1)*100,position!==0&&props.inward>0){let pullToCenter=(50-leftPercentage)*props.inward*factor;leftPercentage+=pullToCenter}let rotateY=factor*-30*Math.sign(position),translateZ=0,scaleX=1,scaleY=1,brightness=1;if(position!==0){if(translateZ=-100*factor,props.keepNeighborsAspectRatio){let scale=Math.max(.6,1-factor*.4)*props.neighborsScale;scaleX=scale,scaleY=scale}else scaleX=Math.max(.4,1-factor*.6)*props.neighborsScale,scaleY=Math.max(.6,1-factor*.4)*props.neighborsScale;brightness=Math.max(.5,1-factor*.5),props.neighborsFlatten&&(rotateY=0)}let opacity=1;return state===`entering`||state===`exiting`?(opacity=.1,translateZ=-100*(absPosition/halfLimit),leftPercentage+=2*Math.sign(position)):isExtraItem?opacity=.2:props.fade&&position!==0&&(opacity=Math.max(.4,1-absPosition*.3)),{left:`${leftPercentage}%`,transform:`translateX(-50%) translateY(-50%) translateZ(${translateZ}px) rotateY(${rotateY}deg) scale(${scaleX}, ${scaleY})`,filter:`brightness(${brightness})`,transition:`all 400ms cubic-bezier(0.25, 0.8, 0.25, 1)`,opacity,zIndex:isExtraItem?10-absPosition:100-absPosition}}let abortAnimation=!1;async function toIndex(targetIndex){if(!ready.value||selectedIndex.value===targetIndex||typeof targetIndex!=`number`||targetIndex<0||targetIndex>=shelfItems.value.length)return;if(isAnimating.value)for(abortAnimation=!0;abortAnimation;)await sleep(20);let prevIndex=selectedIndex.value,steps=calculateSteps(selectedIndex.value,targetIndex);if(steps.length!==0){isAnimating.value=!0;try{let stepTimings=calculateStepTimings(steps.length);for(let i=0;i{selectedIndex.value===targetIndex&&setFocusExternal(containerRef.value.querySelector(`[data-shelf-index="${targetIndex}"]`))})}finally{abortAnimation=!1,isAnimating.value=!1}props.saveName&&localStorage.setItem(`${storageKey}-${props.saveName}`,targetIndex.toString()),emit$1(`change`,targetIndex,prevIndex)}}let onFocus=index=>selectedIndex.value!==index&&toIndex(index);function onClick(index,event){selectedIndex.value===index?emit$1(`click`,event,index):toIndex(index)}function calculateStepTimings(stepCount){return stepCount===1?[timings.single]:Array.from({length:stepCount},(_,i)=>i===0?timings.multiStart:i===stepCount-1?timings.multiEnd:timings.multiMiddle)}function calculateSteps(fromIndex,toIndex$1){let targetItemIndex=displayItems.value.findIndex(item=>item.originalIndex===toIndex$1),steps=[];if(targetItemIndex===-1){let current=fromIndex;for(;current!==toIndex$1;){let totalItems=shelfItems.value.length;props.noLoop?toIndex$1>current?current+=1:--current:current=(toIndex$1-current+totalItems)%totalItems<=(current-toIndex$1+totalItems)%totalItems?(current+1)%totalItems:(current-1+totalItems)%totalItems,steps.push(current)}}else{let targetPosition=displayItems.value[targetItemIndex].position;if(targetPosition!==0){let direction$1=targetPosition>0?1:-1,stepsNeeded=Math.abs(targetPosition),current=fromIndex;for(let i=0;i0?current+=1:--current:current=direction$1>0?(current+1)%shelfItems.value.length:(current-1+shelfItems.value.length)%shelfItems.value.length,steps.push(current)}}return steps}async function animateToStep(stepIndex,stepTiming){let halfLimit=Math.floor(props.limit/2),currentIndex=selectedIndex.value,actualDirection=0;if(props.noLoop)actualDirection=stepIndex>currentIndex?1:-1;else{let totalItems=shelfItems.value.length;actualDirection=(stepIndex-currentIndex+totalItems)%totalItems<=(currentIndex-stepIndex+totalItems)%totalItems?1:-1}let newItems=[];if(actualDirection>0){for(let i=0;i=shelfItems.value.length?rightmostIndex-shelfItems.value.length:rightmostIndex),wrappedIndex>=0&&wrappedIndex=0&&wrappedIndexhalfLimit;newItems.push({...currentItem,position:newPosition,style:getItemStyle(newPosition,isExiting?`exiting`:`normal`)})}}displayItems.value=newItems;let delay=stepTiming/2;await sleep(delay),displayItems.value=displayItems.value.map(item=>item.style.opacity===.1&&(item.position===halfLimit||item.position===-halfLimit)?{...item,style:getItemStyle(item.position,`normal`)}:item),await new Promise(resolve$1=>setTimeout(resolve$1,delay))}function navigateNext$1(){isAnimating.value||props.noLoop&&selectedIndex.value===shelfItems.value.length-1||toIndex((selectedIndex.value+1)%shelfItems.value.length)}function navigatePrev(){isAnimating.value||props.noLoop&&selectedIndex.value===0||toIndex(selectedIndex.value===0?shelfItems.value.length-1:selectedIndex.value-1)}__expose({toIndex,next:navigateNext$1,prev:navigatePrev,isSelected:evt=>{let elm=evt.target.closest(`[data-shelf-index]`);if(!elm)return!1;let idx=parseInt(elm.getAttribute(`data-shelf-index`),10);return!isNaN(idx)&&selectedIndex.value===idx}}),onMounted(()=>{ready.value=!0,nextTick(update$6)});function getActiveItem(){let active=document.activeElement;return String(active.dataset.shelfIndex)===String(selectedIndex.value)?null:containerRef.value.querySelector(`[data-shelf-index="${selectedIndex.value}"]`)}return(_ctx,_cache)=>withDirectives((openBlock(),createElementBlock(`div`,_hoisted_1$341,[withDirectives((openBlock(),createElementBlock(`div`,{ref_key:`containerRef`,ref:containerRef,class:`shelf-container`},[(openBlock(!0),createElementBlock(Fragment,null,renderList(displayItems.value,item=>(openBlock(),createElementBlock(`div`,{key:`item-${item.originalIndex}-${item.id}`,class:`shelf-item`,style:normalizeStyle(item.style)},[(openBlock(),createBlock(resolveDynamicComponent(item.vnode),{"data-shelf-index":item.originalIndex,onClick:$event=>onClick(item.originalIndex,$event),onFocus:$event=>onFocus(item.originalIndex),onUinavFocus:$event=>onFocus(item.originalIndex)},null,40,[`data-shelf-index`,`onClick`,`onFocus`,`onUinavFocus`]))],4))),128))])),[[unref(BngFocusCapture_default),getActiveItem,`101`]]),__props.navShown?(openBlock(),createElementBlock(`button`,{key:0,class:`shelf-nav shelf-nav-prev`,onClick:navigatePrev,disabled:isPrevDisabled.value},[createVNode(unref(bngIcon_default),{type:unref(icons).arrowLargeLeft},null,8,[`type`])],8,_hoisted_2$269)):createCommentVNode(``,!0),__props.navShown?(openBlock(),createElementBlock(`button`,{key:1,class:`shelf-nav shelf-nav-next`,onClick:navigateNext$1,disabled:isNextDisabled.value},[createVNode(unref(bngIcon_default),{type:unref(icons).arrowLargeRight},null,8,[`type`])],8,_hoisted_3$235)):createCommentVNode(``,!0)],512)),[[vShow,displayItems.value.length>0]])}},shelf_default=__plugin_vue_export_helper_default(_sfc_main$395,[[`__scopeId`,`data-v-0109573f`]]),_sfc_main$394={__name:`slotSwitcher`,props:{slotId:{type:String,default:`default`}},setup(__props){return(_ctx,_cache)=>renderSlot(_ctx.$slots,__props.slotId,normalizeProps(guardReactiveProps(_ctx.$attrs)))}},slotSwitcher_default=_sfc_main$394,_sfc_main$393={__name:`tab`,props:{heading:String,selected:Boolean},setup(__props){return(_ctx,_cache)=>renderSlot(_ctx.$slots,`default`,{tabHeading:__props.heading,tabSelected:__props.selected})}},tab_default=_sfc_main$393,_hoisted_1$340={class:`tab-list`},_sfc_main$392={__name:`tabList`,setup(__props){let tabs=inject(`tabs`),selectTab=inject(`selectTab`),tabHeaderClasses=tab=>({"tab-item":!0,"tab-active-tab":tab.active,"no-hover":tab.active});function handleTabSelect(index,event){let buttonElement=event.currentTarget,hasFocusVisible=document.activeElement&&document.activeElement.classList.contains(`focus-visible`);selectTab(index),hasFocusVisible&&nextTick(()=>{setFocusExternal(buttonElement)})}return(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$340,[(openBlock(!0),createElementBlock(Fragment,null,renderList(unref(tabs),(tab,i)=>(openBlock(),createBlock(unref(bngButton_default),{key:i,accent:(tab.active,`ghost`),class:normalizeClass(tabHeaderClasses(tab)),tabindex:`0`,"bng-nav-item":``,onClick:$event=>handleTabSelect(tab.index,$event)},{default:withCtx(()=>[createTextVNode(toDisplayString(tab.heading),1)]),_:2},1032,[`accent`,`class`,`onClick`]))),128))]))}},tabList_default=__plugin_vue_export_helper_default(_sfc_main$392,[[`__scopeId`,`data-v-5c322d77`]]),_hoisted_1$339={class:`tab-container`},_sfc_main$391={__name:`tabs`,props:{selectedIndex:{type:Number,default:-1}},emits:[`change`],setup(__props,{expose:__expose,emit:__emit}){let emit$1=__emit,props=__props,ready=ref(!1),slots=useSlots(),tabListStart=shallowRef(),tabListEnd=shallowRef(),tabsList=ref(),tabsContent=ref([]),selectedIndex=ref(-1),isTabList=vnode=>typeof vnode.type==`object`&&vnode.type.__name===tabList_default.__name;provide(`tabs`,tabsList),watch(()=>slots.default?.(),update$6,{immediate:!0}),watch(()=>props.selectedIndex,index=>selectTab(index));function update$6(vnodes){if(!ready.value)return;vnodes===void 0&&(vnodes=slots.default?.()),Array.isArray(vnodes)||(vnodes=[]);let tabListIndex=vnodes.findIndex(vn=>isTabList(vn));tabListStart.value=tabListIndex===0?vnodes[tabListIndex]:tabList_default,tabListEnd.value=tabListIndex===vnodes.length-1?vnodes[tabListIndex]:null,tabsContent.value=vnodes.filter(vn=>!isTabList(vn)).reduce((res,vnode)=>typeof vnode.type==`symbol`&&vnode.type.toString()===`Symbol(v-fgt)`?(res.push(...vnode.children),res):(res.push(vnode),res),[]),tabsList.value=tabsContent.value.map((tab,index)=>({index,heading:tab.props?.[`tab-heading`]||tab.props?.tabHeading||`Tab ${index+1}`,active:selectedIndex.value===-1?props.selectedIndex===index||!!tab.props?.[`tab-selected`]||!!tab.props?.tabSelected:selectedIndex.value===index}));let activeIndex=tabsList.value.findIndex(tab=>tab.active);selectTab(activeIndex>-1?activeIndex:0)}function selectTab(index){if(!ready.value||typeof index!=`number`||index<0||index>=tabsList.value.length||selectedIndex.value===index)return;let prevTab=tabsList.value[selectedIndex.value];tabsList.value.forEach(tab=>{tab.active=tab.index===index}),selectedIndex.value=index,emit$1(`change`,tabsList.value[index],prevTab)}return provide(`selectTab`,selectTab),__expose({goNext:()=>selectTab((selectedIndex.value+1)%tabsList.value.length),goPrev:()=>selectTab(Math.abs(selectedIndex.value-1)%tabsList.value.length),selectTab}),onMounted(()=>{ready.value=!0,nextTick(update$6)}),(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$339,[tabListStart.value?(openBlock(),createBlock(resolveDynamicComponent(tabListStart.value),{key:0})):createCommentVNode(``,!0),tabsContent.value[selectedIndex.value]?(openBlock(),createBlock(resolveDynamicComponent(tabsContent.value[selectedIndex.value]),{key:1,class:`tab-content`})):createCommentVNode(``,!0),tabListEnd.value?(openBlock(),createBlock(resolveDynamicComponent(tabListEnd.value),{key:2})):createCommentVNode(``,!0)]))}},tabs_default=__plugin_vue_export_helper_default(_sfc_main$391,[[`__scopeId`,`data-v-2ff63a4f`]]),_sfc_main$390={__name:`textScroller`,props:{scrollSpeed:{type:Number,default:3},initialPause:{type:Number,default:1},endingPause:{type:Number,default:1},fadeDuration:{type:Number,default:.2},watchContent:{type:Boolean,default:!1}},setup(__props){let props=__props,slots=useSlots(),events$3={start:[`uinav-focus`,`focus`,`mouseenter`],stop:[`uinav-blur`,`blur`,`mouseleave`]},elContainer=ref(null),elText=ref(null),scrollDistance=ref(0),translateX=ref(0),opacity=ref(1),isActive=ref(!1),isScrolling$1=ref(!1),styleOverrides={"button-icon":`.bng-button.l-icon, .bng-button.r-icon`},overrideClasses=ref([]),parentElement=null,fontSize=ref(16),scrollSpeed=computed(()=>props.scrollSpeed*fontSize.value),animTimer=null,animTimeout=(func,ms)=>(animTimer&&=(clearTimeout(animTimer),null),typeof func==`function`?(animTimer=setTimeout(()=>{animTimer=null,isScrolling$1.value&&func()},ms),animTimer):null),scrollStyles=computed(()=>({transform:`translateX(${translateX.value}px)`,opacity:opacity.value,transition:`opacity ${props.fadeDuration}s linear`+(isScrolling$1.value&&opacity.value>0?`, transform ${scrollDistance.value/scrollSpeed.value}s linear`:``)}));function animLoop(){isScrollable()&&(scrollDistance.value=getSize(),!(scrollDistance.value<=0)&&(opacity.value=1,animTimeout(()=>{translateX.value=-scrollDistance.value,animTimeout(()=>{opacity.value=0,animTimeout(()=>{translateX.value=0,nextTick(animLoop)},props.fadeDuration*1e3)},scrollDistance.value/scrollSpeed.value*1e3+props.endingPause*1e3)},Math.max(props.initialPause,props.fadeDuration)*1e3)))}function isScrollable(){if(!elContainer.value||!elText.value)return!1;let containerWidth=elContainer.value.clientWidth;return elText.value.scrollWidth>containerWidth}function getSize(){if(!elContainer.value||!elText.value)return 0;let containerWidth=elContainer.value.clientWidth,textWidth=elText.value.scrollWidth;return Math.max(0,textWidth-containerWidth)}function animStart(){isActive.value=!0,isScrollable()&&(isScrolling$1.value=!0,translateX.value=0,opacity.value=1,animLoop())}function animStop(restartAnim=!1){isActive.value=!1,isScrolling$1.value=!1,animTimeout(),nextTick(()=>{translateX.value=0,opacity.value=1,typeof restartAnim==`boolean`&&restartAnim&&nextTick(animStart)})}return props.watchContent&&watch(()=>slots.default?.(),()=>animStop(isActive.value),{deep:!0}),watch([()=>scrollSpeed.value,()=>props.initialPause,()=>props.endingPause,()=>props.fadeDuration],()=>animStop(isActive.value)),watch(()=>elContainer.value,()=>{if(!elContainer.value)return;for(parentElement=elContainer.value.parentElement;parentElement&&!parentElement.matches(`[is-bng-panel], [bng-nav-item], [ng-click], [href], [bng-all-clicks], [bng-all-clicks-no-nav], [ui-sref], input, textarea, button, md-option, md-slider, md-select, md-checkbox`);)if(parentElement=parentElement.parentElement,parentElement===document.body){parentElement=null;break}if(!parentElement)return;overrideClasses.value=[];for(let[key,selectors]of Object.entries(styleOverrides))parentElement.matches(selectors)&&overrideClasses.value.push(`bng-text-override--${key}`);let fSize=window.getComputedStyle(elContainer.value,null).fontSize;fontSize.value=+fSize.substring(0,fSize.length-2),events$3.start.forEach(event=>parentElement.addEventListener(event,animStart)),events$3.stop.forEach(event=>parentElement.addEventListener(event,animStop))},{immediate:!0}),onUnmounted(()=>{animTimeout(),parentElement&&(events$3.start.forEach(event=>parentElement.removeEventListener(event,animStart)),events$3.stop.forEach(event=>parentElement.removeEventListener(event,animStop)))}),(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,{ref_key:`elContainer`,ref:elContainer,class:normalizeClass([`bng-text-scroller`,[{"is-scrolling":isScrolling$1.value},...overrideClasses.value]])},[createBaseVNode(`div`,{ref_key:`elText`,ref:elText,class:`scroller-text`,style:normalizeStyle(scrollStyles.value)},[renderSlot(_ctx.$slots,`default`,{},void 0,!0)],4)],2))}},textScroller_default=__plugin_vue_export_helper_default(_sfc_main$390,[[`__scopeId`,`data-v-4f311fae`]]),_hoisted_1$338=[`data-tree-node-key`,`data-tree-node-expanded`,`data-tree-node-selected`,`data-tree-node-parent-path`,`data-tree-node-path`],_hoisted_2$268={key:1,class:`node`},_hoisted_3$234=[`disabled`],_hoisted_4$199={key:2,"data-tree-node-children":``},_sfc_main$389={__name:`treeNode`,props:{node:{type:Object,required:!0},keyName:{type:String,required:!0},parentNode:Object,selectMode:String,expandMode:String,expandedKeys:Array,selectedKeys:Array,parentPath:Array},setup(__props){let props=__props,$templates=inject(`$templates`),_expandFn=inject(`expandFn`),_selectFn=inject(`selectFn`),expanded=computed(()=>props.expandMode===`prop`?props.node.expanded:props.expandedKeys&&props.expandedKeys.includes(props.node[props.keyName])),expandable=computed(()=>!props.node.disabled&&props.node.children&&props.node.children.length>0),selected=computed(()=>props.selectMode?props.selectMode===`prop`?props.node.selected:props.selectedKeys&&props.selectedKeys.includes(props.node[props.keyName]):!1),selectable=computed(()=>!props.node.disabled&&props.selectMode&&props.node.selectable!==!1),path=computed(()=>props.parentPath?props.parentPath.concat(props.node[props.keyName]):[props.node[props.keyName]]),parentPathString=computed(()=>props.parentPath?props.parentPath.join(`/`):null),pathString=computed(()=>path.value.join(`/`)),nodeProps=computed(()=>({path:path.value,parentPath:props.parentPath}));return(_ctx,_cache)=>{let _component_TreeNode=resolveComponent(`TreeNode`,!0);return openBlock(),createElementBlock(`li`,{"data-tree-node-key":__props.node[__props.keyName],"data-tree-node-expanded":expanded.value,"data-tree-node-selected":selected.value,"data-tree-node-parent-path":parentPathString.value,"data-tree-node-path":pathString.value,"data-tree-node":``},[unref($templates).node?(openBlock(),createBlock(resolveDynamicComponent(unref($templates).node),{key:0,node:__props.node,parentNode:__props.parentNode,expanded:expanded.value,selected:selected.value,expand:()=>expandable.value?unref(_expandFn)(__props.node,nodeProps.value):{},select:()=>selectable.value?unref(_selectFn)(__props.node,nodeProps.value):{}},null,8,[`node`,`parentNode`,`expanded`,`selected`,`expand`,`select`])):(openBlock(),createElementBlock(`div`,_hoisted_2$268,[__props.node.children&&unref($templates).toggle?(openBlock(),createBlock(resolveDynamicComponent(unref($templates).toggle),{key:0,node:__props.node,parentNode:__props.parentNode,expanded:expanded.value,selected:selected.value,expand:()=>expandable.value?unref(_expandFn)(__props.node,nodeProps.value):{}},null,8,[`node`,`parentNode`,`expanded`,`selected`,`expand`])):(openBlock(),createElementBlock(`span`,{key:1,class:`node-toggle`,onClick:_cache[0]||=()=>expandable.value?unref(_expandFn)(__props.node,nodeProps.value):{},disabled:__props.node.disabled},[__props.node.children?(openBlock(),createBlock(unref(bngIcon_default),{key:0,"bng-nav-item":``,type:expanded.value?unref(icons).arrowSmallDown:unref(icons).arrowSmallRight},null,8,[`type`])):createCommentVNode(``,!0)],8,_hoisted_3$234)),unref($templates).content?(openBlock(),createBlock(resolveDynamicComponent(unref($templates).content),{key:2,node:__props.node,parentNode:__props.parentNode,expanded:expanded.value,selected:selected.value,expand:()=>expandable.value?unref(_expandFn)(__props.node,nodeProps.value):{},select:()=>selectable.value?unref(_selectFn)(__props.node,nodeProps.value):{}},null,8,[`node`,`parentNode`,`expanded`,`selected`,`expand`,`select`])):(openBlock(),createElementBlock(`span`,{key:3,"bng-nav-item":``,class:`node-content`,onClick:_cache[1]||=()=>selectable.value?unref(_selectFn)(__props.node,nodeProps.value):{}},toDisplayString(__props.node.label),1))])),expanded.value&&__props.node.children?(openBlock(),createElementBlock(`ul`,_hoisted_4$199,[(openBlock(!0),createElementBlock(Fragment,null,renderList(__props.node.children,childNode=>(openBlock(),createBlock(_component_TreeNode,{key:childNode[__props.keyName],node:childNode,parentNode:__props.node,keyName:__props.keyName,selectMode:__props.selectMode,expandMode:__props.expandMode,expandedKeys:__props.expandedKeys,selectedKeys:__props.selectedKeys,parentPath:path.value},null,8,[`node`,`parentNode`,`keyName`,`selectMode`,`expandMode`,`expandedKeys`,`selectedKeys`,`parentPath`]))),128))])):createCommentVNode(``,!0)],8,_hoisted_1$338)}}},treeNode_default=__plugin_vue_export_helper_default(_sfc_main$389,[[`__scopeId`,`data-v-aeb14cdb`]]),_hoisted_1$337={class:`tree`},SELECT_SINGLE=`single`,SELECT_MULTIPLE=`multi`,SELECT_PROP=`prop`,SELECT_MODES=[SELECT_SINGLE,SELECT_MULTIPLE,SELECT_PROP],EXPAND_MODEL=`model`,EXPAND_PROP=`prop`,EXPAND_MODES=[EXPAND_MODEL,EXPAND_PROP],_sfc_main$388={__name:`tree`,props:mergeModels({nodes:{type:Array,required:!0},keyName:{type:String,default:`key`},expandMode:{type:String,default:EXPAND_MODEL,validator(value){return EXPAND_MODES.includes(value)}},selectMode:{type:String,validator(value){return SELECT_MODES.includes(value)}}},{expandedKeys:{},expandedKeysModifiers:{},selectedKeys:{},selectedKeysModifiers:{}}),emits:mergeModels([`update:expandedKeys`,`node-expanded`,`node-collapsed`,`expanded-keys-changed`,`node-selected`,`node-unselected`,`selected-keys-changed`],[`update:expandedKeys`,`update:selectedKeys`]),setup(__props,{emit:__emit}){let props=__props,expandedKeys=useModel(__props,`expandedKeys`),selectedKeys=useModel(__props,`selectedKeys`),emit$1=__emit;onBeforeMount(()=>{provide(`$templates`,useSlots()),provide(`expandFn`,expand),provide(`selectFn`,select)});function expand(node,nodeProps){let nodeKey=node[props.keyName];if(props.expandMode===EXPAND_PROP)node.expanded?emit$1(`node-collapsed`,node,nodeProps):emit$1(`node-expanded`,node,nodeProps);else{if(!expandedKeys.value)throw Error(`v-model:expandedKeys must be set`);let expanded=expandedKeys.value.includes(nodeKey),updatedExpandedKeys;expanded?(updatedExpandedKeys=expandedKeys.value.filter(x=>x!==nodeKey),emit$1(`node-collapsed`,node,nodeProps)):(updatedExpandedKeys=[...expandedKeys.value,nodeKey],emit$1(`node-expanded`,node,nodeProps)),expandedKeys.value=updatedExpandedKeys,emit$1(`expanded-keys-changed`,updatedExpandedKeys)}}function select(node,nodeProps){console.log(`select`,node);let nodeKey=node[props.keyName];if(props.selectMode===SELECT_PROP)node.selected?emit$1(`node-selected`,node,nodeProps):emit$1(`node-unselected`,node,nodeProps);else{if(!selectedKeys.value)throw Error(`v-model:selectedKeys must be set`);let selected=selectedKeys.value.includes(nodeKey),updatedSelectedKeys;selected?(updatedSelectedKeys=selectedKeys.value.filter(x=>x!==nodeKey),emit$1(`node-unselected`,node,nodeProps)):props.selectMode===`single`?(updatedSelectedKeys=[nodeKey],emit$1(`node-selected`,node,nodeProps)):props.selectMode===`multi`&&(updatedSelectedKeys=[...selectedKeys.value,nodeKey],emit$1(`node-selected`,node,nodeProps)),selectedKeys.value=updatedSelectedKeys,emit$1(`selected-keys-changed`,updatedSelectedKeys)}}return(_ctx,_cache)=>(openBlock(),createElementBlock(`ul`,_hoisted_1$337,[(openBlock(!0),createElementBlock(Fragment,null,renderList(__props.nodes,node=>(openBlock(),createBlock(treeNode_default,{key:node[__props.keyName],node,keyName:__props.keyName,selectMode:__props.selectMode,expandMode:__props.expandMode,expandedKeys:expandedKeys.value,selectedKeys:selectedKeys.value},null,8,[`node`,`keyName`,`selectMode`,`expandMode`,`expandedKeys`,`selectedKeys`]))),128))]))}},tree_default=__plugin_vue_export_helper_default(_sfc_main$388,[[`__scopeId`,`data-v-7363528a`]]);const DEMOS$1={};var utility_exports=__export({Accordion:()=>accordion_default,AccordionItem:()=>accordionItem_default,AccordionTree:()=>accordionTree_default,AspectRatio:()=>aspectRatio_default,Carousel:()=>carousel_default,CarouselItem:()=>carouselItem_default,DEMOS:()=>DEMOS$1,DRAWER_POSITION:()=>DRAWER_POSITION,Drawer:()=>drawer_default,DynamicComponent:()=>dynamicComponent_default,Shelf:()=>shelf_default,SlotSwitcher:()=>slotSwitcher_default,Tab:()=>tab_default,TabList:()=>tabList_default,Tabs:()=>tabs_default,TextScroller:()=>textScroller_default,Tree:()=>tree_default,TreeNode:()=>treeNode_default}),_hoisted_1$336={class:`actions-drawer`},_sfc_main$387={__name:`bngActionsDrawer`,props:{header:{type:String,required:!0},headerActions:Array,showHeaderActions:{type:Boolean,default:!0},grouped:Boolean,actions:{type:[Array,Object],required:!0},selected:{type:[String,Number]},expanded:Boolean},emits:[`actionClick`,`headerActionClicked`,`categoryChanged`],setup(__props,{emit:__emit}){let emit$1=__emit,onActionClicked=action=>emit$1(`actionClick`,action);return(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$336,[createVNode(unref(bngDrawerOld_default),null,createSlots({header:withCtx(()=>[createTextVNode(toDisplayString(__props.header),1)]),content:withCtx(()=>[__props.grouped?(openBlock(),createBlock(unref(tabs_default),{key:0,class:`categories-tab bng-tabs`},{default:withCtx(()=>[(openBlock(!0),createElementBlock(Fragment,null,renderList(__props.actions,category=>(openBlock(),createBlock(unref(tab_default),{key:category.category,heading:category.category},{default:withCtx(()=>[(openBlock(),createBlock(unref(bngActionsList_default),{key:category.category,actions:category.items,selected:__props.selected,class:normalizeClass({expanded:__props.expanded}),onActionClick:_cache[0]||=value=>onActionClicked(value)},null,8,[`actions`,`selected`,`class`]))]),_:2},1032,[`heading`]))),128))]),_:1})):(openBlock(),createBlock(unref(bngActionsList_default),{key:1,actions:__props.actions,selected:__props.selected,class:normalizeClass({expanded:__props.expanded}),onActionClick:_cache[1]||=value=>onActionClicked(value)},null,8,[`actions`,`selected`,`class`]))]),_:2},[__props.showHeaderActions&&__props.headerActions?{name:`headerOptions`,fn:withCtx(()=>[(openBlock(!0),createElementBlock(Fragment,null,renderList(__props.headerActions,action=>(openBlock(),createBlock(unref(bngButton_default),{key:action.value,tabindex:`1`,accent:action.accent,onClick:$event=>_ctx.$emit(`headerActionClicked`,action.value)},{default:withCtx(()=>[createTextVNode(toDisplayString(action.label),1)]),_:2},1032,[`accent`,`onClick`]))),128))]),key:`0`}:void 0]),1024)]))}},bngActionsDrawer_default=__plugin_vue_export_helper_default(_sfc_main$387,[[`__scopeId`,`data-v-b433a352`]]),_hoisted_1$335={class:`header-wrapper`},_hoisted_2$267={class:`drawer-content`},_hoisted_3$233={key:0,class:`filters-wrapper`},_hoisted_4$198={class:`drawer-actions-wrapper`},_hoisted_5$168={key:0,class:`action-divider`},_hoisted_6$143={key:1,class:`progress-indicator`},_sfc_main$386={__name:`bngActionsDrawerOne`,props:{value:{type:Object,required:!0},flattenChildren:Boolean,allowOpenDrawer:Boolean,openDrawerLabel:String,closeDrawerLabel:String,loading:Boolean,header:String,blur:Boolean},emits:[`update:currentActionPath`,`update:loading`,`actionClicked`,`actionItemChanged`,`drawerOpened`],setup(__props,{emit:__emit}){let props=__props,emit$1=__emit,drawerState=reactive({isOpenCatalog:!1,currentPath:[],drawerFilters:[]}),currentActionPath=computed({get:()=>drawerState.currentPath,set:newValue=>{drawerState.currentPath=newValue}}),parentAction=computed(()=>{if(!currentActionPath.value||currentActionPath.value.length===0)return null;let currentAction$1=props.value;for(let key of currentActionPath.value.slice(0,-1))currentAction$1=currentAction$1.items.find(x=>x.value===key);return currentAction$1}),currentAction=computed(()=>{let currentAction$1=props.value;for(let key of currentActionPath.value)currentAction$1=currentAction$1.items.find(x=>x.value===key);return currentAction$1}),isDrawerOpen=computed({get:()=>drawerState.isOpenCatalog,set:newValue=>{drawerState.isOpenCatalog=newValue,emit$1(`drawerOpened`,newValue)}}),loading=computed({get:()=>props.loading,set:newValue=>emit$1(`update:loading`,newValue)}),canViewCatalogDisplayMode=computed(()=>(console.log(`canViewCatalogDisplayMode`),loading.value===!0||currentAction.value.allowOpenDrawer===!1?!1:(console.log(`currentAction`,currentAction.value),currentAction.value.items.every(x=>x.lazyLoadItems===!0||x.items)))),drawerFilterValue=computed({get:()=>drawerState.drawerFilters&&drawerState.drawerFilters.length>0?drawerState.drawerFilters[0]:null,set:newValue=>{drawerState.drawerFilters=newValue?[newValue]:[]}}),catalogFilters=computed(()=>{let activeAction=isDrawerOpen.value?parentAction.value:currentAction.value;return activeAction.items.every(x=>x.items&&x.items.length>0||x.lazyLoadItems)?activeAction.items.map(x=>({label:x.label,value:x.value})):[]}),showBackButton=computed(()=>currentActionPath.value.length>0);watch(drawerFilterValue,(newValue,oldValue)=>{console.log(`drawerFilterValue`,newValue,oldValue),newValue&&!oldValue?currentActionPath.value=[...currentActionPath.value,newValue]:newValue&&oldValue?currentActionPath.value=[...currentActionPath.value.slice(0,-1),newValue]:!newValue&&oldValue&&(currentActionPath.value=[...currentActionPath.value].slice(0,-1))}),watch(currentActionPath,()=>{emit$1(`actionItemChanged`,currentAction.value,currentActionPath.value)});let selectAction=actionItem=>{(actionItem.items&&actionItem.items.length>0||actionItem.lazyLoadItems===!0)&&(isDrawerOpen.value&&=!1,currentActionPath.value=[...currentActionPath.value,actionItem.value]),emit$1(`actionClicked`,actionItem)},toggleOpenCatalog=()=>{isDrawerOpen.value?closeDrawer():openDrawer()},goBack=()=>{isDrawerOpen.value?closeDrawer():currentActionPath.value=[...currentActionPath.value].slice(0,-1)};function openDrawer(){drawerFilterValue.value=catalogFilters.value[0].value,isDrawerOpen.value=!0}function closeDrawer(){drawerFilterValue.value=null,isDrawerOpen.value=!1}return(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,{class:normalizeClass([`bng-actions-drawer`,{expanded:isDrawerOpen.value}])},[createVNode(unref(bngDrawerOld_default),{blur:__props.blur,class:`bng-drawer`},{header:withCtx(()=>[renderSlot(_ctx.$slots,`header`,{actionItem:currentAction.value,canGoBack:showBackButton.value,goBack},()=>[createBaseVNode(`div`,_hoisted_1$335,[showBackButton.value?(openBlock(),createBlock(unref(bngButton_default),{key:0,icon:unref(icons).arrowLargeLeft,accent:unref(ACCENTS).secondary,class:`back-btn`,onClick:goBack},{default:withCtx(()=>[..._cache[1]||=[createTextVNode(`Back`,-1)]]),_:1},8,[`icon`,`accent`])):createCommentVNode(``,!0),createTextVNode(` `+toDisplayString(currentAction.value.label),1)])],!0)]),content:withCtx(()=>[createBaseVNode(`div`,_hoisted_2$267,[drawerState.isOpenCatalog&&catalogFilters.value.length>0?(openBlock(),createElementBlock(`div`,_hoisted_3$233,[createVNode(unref(bngPillFilters_default),{modelValue:drawerState.drawerFilters,"onUpdate:modelValue":_cache[0]||=$event=>drawerState.drawerFilters=$event,options:catalogFilters.value},null,8,[`modelValue`,`options`])])):createCommentVNode(``,!0),createBaseVNode(`div`,_hoisted_4$198,[createBaseVNode(`div`,{class:normalizeClass([`drawer-actions`,{expanded:drawerState.isOpenCatalog}])},[loading.value?(openBlock(),createElementBlock(`div`,_hoisted_6$143,[..._cache[2]||=[createBaseVNode(`div`,{class:`loader`},null,-1)]])):(openBlock(!0),createElementBlock(Fragment,{key:0},renderList(currentAction.value.items,action=>(openBlock(),createElementBlock(Fragment,{key:action.value},[action.type===`actionDivider`?(openBlock(),createElementBlock(`div`,_hoisted_5$168,toDisplayString(action.label),1)):renderSlot(_ctx.$slots,`item`,{key:1,actionItem:action,onClick:()=>selectAction(action)},()=>[createVNode(unref(bngImageTile_default),{label:action.label,icon:action.icon,onClick:$event=>selectAction(action)},null,8,[`label`,`icon`,`onClick`])],!0)],64))),128))],2)]),canViewCatalogDisplayMode.value?renderSlot(_ctx.$slots,`footer`,{key:1},()=>[createVNode(unref(bngButton_default),{class:`catalog-btn`,accent:unref(ACCENTS).outlined,onClick:toggleOpenCatalog},{default:withCtx(()=>[drawerState.isOpenCatalog?(openBlock(),createElementBlock(Fragment,{key:0},[createTextVNode(toDisplayString(__props.closeDrawerLabel?__props.closeDrawerLabel:`Collapse catalog`),1)],64)):(openBlock(),createElementBlock(Fragment,{key:1},[createTextVNode(toDisplayString(__props.openDrawerLabel?__props.openDrawerLabel:`Open full catalog`),1)],64))]),_:1},8,[`accent`])],!0):createCommentVNode(``,!0)])]),_:3},8,[`blur`])],2))}},bngActionsDrawerOne_default=__plugin_vue_export_helper_default(_sfc_main$386,[[`__scopeId`,`data-v-529c2a59`]]),_hoisted_1$334={class:`actions`},_sfc_main$385={__name:`bngActionsList`,props:{actions:{type:Array,required:!0},selected:{type:[String,Number],required:!1}},emits:[`actionClick`],setup(__props,{emit:__emit}){let emit$1=__emit;return(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$334,[(openBlock(!0),createElementBlock(Fragment,null,renderList(__props.actions,action=>(openBlock(),createBlock(unref(bngImageTile_default),mergeProps({class:`action-tile`,tabindex:`0`,key:action.value},{ref_for:!0},action,{"bng-nav-item":``,onClick:$event=>emit$1(`actionClick`,action.value)}),null,16,[`onClick`]))),128))]))}},bngActionsList_default=__plugin_vue_export_helper_default(_sfc_main$385,[[`__scopeId`,`data-v-8790d45d`]]),_hoisted_1$333=[`ui-event`],_hoisted_2$266={key:0},_hoisted_3$232={key:3,class:`combo-separator`},MULTI_ID=`[PLUS]`,MULTI_LABEL=`+`,_sfc_main$384={__name:`bngBinding`,props:{action:String,showUnassigned:Boolean,device:[String,Array],deviceKey:String,dark:Boolean,deviceMask:[String,Function],controller:Boolean,uiEvent:String,trackIgnore:Boolean,unassignedText:{default:`[N/A]`,type:String},viewerObj:Object,imagePack:String,actionVariants:Boolean,useLastDevice:{type:Boolean,default:!0},vertical:Boolean},setup(__props,{expose:__expose}){let $simplemenu=inject(`$simplemenu`),Controls=controls_default(),{showIfController,lastControllersSignature}=storeToRefs(Controls),props=__props,iconColors={dark:`var(--bng-off-black)`,light:`var(--bng-off-white)`},iconColor=computed(()=>iconColors[props.dark?`dark`:`light`]);computed(()=>iconColors[props.dark?`light`:`dark`]);let controllerOnly=computed(()=>props.controller||$simplemenu.value),LABELS_BIG=[`enter`,`tab`,`capslock`,`backspace`,`lshift`,`rshift`,`left`,`right`,`up`,`down`,`space`,`grave`,`comma`,`period`].map(c=>CONTROL_LABELS[c]||c),LABELS_OFFSET=[`space`].map(c=>CONTROL_LABELS[c]||c),rgxSanitize$1=s=>s.replace(/[-.+*$^?:|[\](){}]/g,`\\$&`),LABELS_RGX=RegExp(`(`+[MULTI_ID,...LABELS_BIG,...LABELS_OFFSET].map(rgxSanitize$1).join(`|`)+`)`,`g`),viewerObj=computed(()=>{if(props.viewerObj)return props.viewerObj;if(controllerOnly.value&&showIfController.value){let opts={...props};return opts.controller=!0,opts._controllerSignature=lastControllersSignature.value,Controls.makeViewerObj(opts)}return Controls.makeViewerObj(props)}),viewerVariants=computed(()=>{if(!viewerObj.value)return[];let variants=viewerObj.value.variants||[viewerObj.value];variants=variants.map(obj=>obj.multiControls||[obj]);for(let objs of variants)for(let obj of objs)if(obj&&(!obj.special||obj.ownLabel)&&!obj.controlSegments){let control=obj.ownLabel||obj.control;control=control.replace(/ \+ /g,MULTI_ID),obj.controlSegments=String(control).split(LABELS_RGX).filter(Boolean).map(segment=>({value:segment===MULTI_ID?MULTI_LABEL:segment,class:(LABELS_BIG.includes(segment)?`label-bigger `:``)+(LABELS_OFFSET.includes(segment)?`label-offset `:``)+(segment===MULTI_ID?`label-multi `:``)}))}return variants}),display=computed(()=>{let res=!!viewerObj.value;if(viewerObj.value)if(props.deviceMask){let dev=viewerObj.value.devName;res=typeof props.deviceMask==`function`?props.deviceMask(dev):dev.startsWith(props.deviceMask)}else controllerOnly.value&&(res=showIfController.value);return res||props.showUnassigned});__expose({displayed:display});let eventName=computed(()=>props.action?props.action:props.uiEvent?props.uiEvent:null),uiNavTracker=useUINavTracker(),ownerId$1=uniqueId(`bngBinding`),trackedEvent=``,track$1=(eventName$1=null)=>{if(trackedEvent&&=(uiNavTracker.removeIgnore(trackedEvent,ownerId$1),``),!(props.trackIgnore||!display.value)&&eventName$1){if(trackedEvent===eventName$1)return;trackedEvent=eventName$1,uiNavTracker.addIgnore(trackedEvent,ownerId$1)}};return watch(()=>props.trackIgnore,val=>track$1(val?null:eventName.value)),watch(display,()=>track$1(eventName.value)),watch(eventName,(val,prev)=>{prev&&track$1(),val&&track$1(val)}),onMounted(()=>track$1(eventName.value)),onUnmounted(()=>track$1()),(_ctx,_cache)=>display.value?(openBlock(),createElementBlock(`span`,{key:0,class:normalizeClass([`binding-wrapper`,{"binding-theme-dark":__props.dark,"binding-theme-light":!__props.dark,"with-variants":viewerVariants.value.length>1,vertical:__props.vertical}]),"ui-event":__props.uiEvent},[(openBlock(!0),createElementBlock(Fragment,null,renderList(viewerVariants.value,(viewerObjs,index)=>(openBlock(),createElementBlock(`span`,{key:index,class:normalizeClass([`binding-container`,{"combo-binding":viewerObjs.length>1}])},[(openBlock(!0),createElementBlock(Fragment,null,renderList(viewerObjs,(viewerObj$1,index$1)=>(openBlock(),createElementBlock(Fragment,{key:index$1},[viewerObj$1&&viewerObj$1.controlSegments?(openBlock(),createElementBlock(`kbd`,_hoisted_2$266,[(openBlock(!0),createElementBlock(Fragment,null,renderList(viewerObj$1.controlSegments,(seg,i)=>(openBlock(),createElementBlock(`span`,{key:i,class:normalizeClass(seg.class)},toDisplayString(seg.value),3))),128))])):viewerObj$1&&viewerObj$1.special?(openBlock(),createBlock(unref(bngIcon_default),{key:1,class:`bng-binding-icon`,type:unref(icons)[viewerObj$1.ownIcon],color:iconColor.value},null,8,[`type`,`color`])):!viewerObj$1&&__props.showUnassigned?(openBlock(),createBlock(unref(bngIcon_default),{key:2,class:`bng-binding-icon n-a`,type:unref(icons).NA,color:iconColor.value},null,8,[`type`,`color`])):createCommentVNode(``,!0),index$1Number(val)>0},simple:Boolean,blur:Boolean,disableLastItem:Boolean,showBackButton:Boolean,showBackBinding:{type:Boolean,default:!0},navigable:{type:Boolean,default:!0}},emits:[`click`,`back`],setup(__props,{emit:__emit}){let bid=uniqueId(`bng-path`),emit$1=__emit,props=__props,pathView=computed(()=>{if(!Array.isArray(props.items))return[];let mapItem=itm=>({label:itm.label,items:itm.items,data:itm,dividerType:itm.dividerType}),items$2=props.items.map(mapItem),res=props.limit?items$2.slice(-props.limit):items$2;if(!props.simple){let looseCmp=(a$1,b)=>a$1.label===b.label&&a$1.value===b.value,len=res.length;for(let i=1;ilooseCmp(itm,res[idx])),items:items$3.map(mapItem)})}}return props.limit&&items$2.length>props.limit&&res.unshift({label:`…`,data:items$2[items$2.length-props.limit-1]}),res.length>0&&(res[0].first=!0,res.at(-1).last=!0),res});function onClick(item,index){(!props.disableLastItem||index(openBlock(),createElementBlock(`div`,{class:`bng-path`,"bng-no-child-nav":!__props.navigable},[__props.showBackButton?(openBlock(),createBlock(unref(bngButton_default),{key:0,class:`back-button`,accent:unref(ACCENTS).custom,onClick:_cache[0]||=$event=>emit$1(`back`),tabindex:`1`},{default:withCtx(()=>[createVNode(unref(bngIcon_default),{type:unref(icons).arrowSmallLeft,class:`back-icon`},null,8,[`type`]),__props.showBackBinding?(openBlock(),createBlock(unref(bngBinding_default),{key:0,"ui-event":`back`,controller:``,"track-ignore":``})):createCommentVNode(``,!0),createTextVNode(` `+toDisplayString(_ctx.$tt(`ui.common.back`)),1)]),_:1},8,[`accent`])):createCommentVNode(``,!0),(openBlock(!0),createElementBlock(Fragment,null,renderList(pathView.value,(item,index)=>(openBlock(),createElementBlock(Fragment,{key:index},[item.dropdown?(openBlock(),createElementBlock(Fragment,{key:1},[withDirectives(createVNode(unref(bngButton_default),{class:`bng-path-item bng-path-has-dropdown`,accent:unref(ACCENTS).text,icon:unref(icons).arrowSmallRight},null,8,[`accent`,`icon`]),[[unref(BngBlur_default),__props.blur],[unref(BngPopover_default),item.dropdown,`bottom-start`,{click:!0}]]),createVNode(unref(bngPopoverMenu_default),{name:item.dropdown,focus:``},{default:withCtx(({hide:hide$2})=>[(openBlock(!0),createElementBlock(Fragment,null,renderList(item.items,(subitem,idx)=>withDirectives((openBlock(),createBlock(unref(bngButton_default),{key:idx,class:normalizeClass({selected:idx===item.selected}),accent:unref(ACCENTS).menu,onClick:$event=>onMenuClick(subitem,hide$2)},{default:withCtx(()=>[createTextVNode(toDisplayString(subitem.label),1)]),_:2},1032,[`class`,`accent`,`onClick`])),[[unref(BngOnUiNav_default),void 0,`ok`,{focusRequired:!0,asMouse:!0}]])),128))]),_:2},1032,[`name`])],64)):(openBlock(),createElementBlock(Fragment,{key:0},[withDirectives((openBlock(),createBlock(unref(bngButton_default),{class:normalizeClass([`bng-path-item`,{"bng-path-simple":__props.simple,"bng-path-disabled":__props.disableLastItem&&item.last,"bng-path-first":item.first,"bng-path-last":item.last}]),accent:unref(ACCENTS).text,onClick:$event=>onClick(item,index)},{default:withCtx(()=>[createTextVNode(toDisplayString(item.label),1)]),_:2},1032,[`class`,`accent`,`onClick`])),[[unref(BngBlur_default),__props.blur]]),__props.simple&&!item.last?(openBlock(),createElementBlock(`div`,_hoisted_2$265,[withDirectives(createVNode(unref(bngIcon_default),{type:item.dividerType||unref(icons).slashRight},null,8,[`type`]),[[unref(BngBlur_default),__props.blur]])])):createCommentVNode(``,!0)],64))],64))),128))],8,_hoisted_1$332))}},bngBreadcrumbs_default=__plugin_vue_export_helper_default(_sfc_main$383,[[`__scopeId`,`data-v-4a2e18d5`]]),_hoisted_1$331=[`accent`,`disabled`],_hoisted_2$264={key:0,class:`hold-arrow`,xmlns:`http://www.w3.org/2000/svg`,viewBox:`0 0 16 12`,preserveAspectRatio:`xMidYMid`},_hoisted_3$231={key:3,class:`label`},_hoisted_4$197={key:5,class:`label`},_hoisted_5$167={key:6};const ACCENTS={main:`main`,secondary:`secondary`,outlined:`outlined`,text:`text`,attention:`attention`,attentionghost:`attentionghost`,attentionoutlined:`attentionoutlined`,ghost:`ghost`,menu:`menu`,custom:`custom`};var _sfc_main$382={__name:`bngButton`,props:{accent:{type:String,default:`main`,validator:v=>Object.values(ACCENTS).includes(v)||v===``},iconLeft:[Object,String],iconRight:[Object,String],label:String,icon:[Object,String],externalIcon:String,showHold:Boolean,holdVertical:Boolean,disabled:Boolean,noSound:Boolean},setup(__props,{expose:__expose}){let slots=useSlots(),uiNavEvent=ref(),btnDOMElRef=ref(),attrs=useAttrs(),useOldIcons=computed(()=>`oldIcons`in attrs);watchUINavEventChange(btnDOMElRef,({eventName,action})=>{}),__expose({getElement(){return btnDOMElRef.value}});let isPlainTextSlot=ref(!1);function checkIfPlainText(){let slotContent=slots.default?slots.default():[];isPlainTextSlot.value=slotContent.length===1&&typeof slotContent[0].type==`symbol`&&String(slotContent[0].type).indexOf(`v-txt`)>-1&&slotContent[0].children.trim().length>0}watch(()=>slots.default,checkIfPlainText),checkIfPlainText();let props=__props,needsFallbackHoldOffset=ref(!0);return watchEffect(()=>{btnDOMElRef.value&&props.accent===`custom`&&window.getComputedStyle(btnDOMElRef.value).getPropertyValue(`--bng-button-custom-hold-offset`).trim()&&(needsFallbackHoldOffset.value=!1)}),(_ctx,_cache)=>withDirectives((openBlock(),createElementBlock(`button`,{ref_key:`btnDOMElRef`,ref:btnDOMElRef,accent:__props.accent,class:normalizeClass({"show-hold":__props.showHold,"hold-vertical":__props.holdVertical,"bng-button":!0,empty:!unref(slots).default&&!__props.label,"l-icon":__props.iconLeft||__props.icon,"r-icon":__props.iconRight,"external-icon":__props.externalIcon,"fallback-hold-offset":props.accent===`custom`&&needsFallbackHoldOffset.value}),disabled:__props.disabled},[__props.showHold?(openBlock(),createElementBlock(`svg`,_hoisted_2$264,[..._cache[0]||=[createBaseVNode(`path`,{d:`M1,1 L8,2 L16,1 L8,11 z`},null,-1)]])):createCommentVNode(``,!0),useOldIcons.value&&(__props.iconLeft||__props.icon)?(openBlock(),createBlock(unref(bngOldIcon_default),{key:1,type:__props.iconLeft||__props.icon},null,8,[`type`])):!useOldIcons.value&&(__props.iconLeft||__props.icon||__props.externalIcon)?(openBlock(),createBlock(unref(bngIcon_default),{key:2,class:`icon`,type:__props.iconLeft||__props.icon,externalImage:__props.externalIcon},null,8,[`type`,`externalImage`])):createCommentVNode(``,!0),isPlainTextSlot.value?(openBlock(),createElementBlock(`span`,_hoisted_3$231,[renderSlot(_ctx.$slots,`default`,{},void 0,!0)])):isPlainTextSlot.value?createCommentVNode(``,!0):renderSlot(_ctx.$slots,`default`,{key:4},void 0,!0),__props.label&&!isPlainTextSlot.value?(openBlock(),createElementBlock(`span`,_hoisted_4$197,toDisplayString(__props.label),1)):createCommentVNode(``,!0),uiNavEvent.value?(openBlock(),createElementBlock(`span`,_hoisted_5$167,toDisplayString(uiNavEvent.value),1)):createCommentVNode(``,!0),useOldIcons.value&&__props.iconRight?(openBlock(),createBlock(unref(bngOldIcon_default),{key:7,span:``,type:__props.iconRight},null,8,[`type`])):!useOldIcons.value&&__props.iconRight?(openBlock(),createBlock(unref(bngIcon_default),{key:8,class:`icon`,type:__props.iconRight},null,8,[`type`])):createCommentVNode(``,!0),_cache[1]||=createBaseVNode(`div`,{class:`background`},null,-1)],10,_hoisted_1$331)),[[unref(BngSoundClass_default),!__props.disabled&&!__props.noSound&&`bng_click_hover_generic`]])}},bngButton_default=__plugin_vue_export_helper_default(_sfc_main$382,[[`__scopeId`,`data-v-8b356414`]]),_hoisted_1$330={class:`card-cnt`},ANIMATION_TYPES=[`fade`,`slide`],_sfc_main$381={__name:`bngCard`,props:{backgroundImage:String,footerStyles:Object,hideFooter:Boolean,animateFooter:Boolean,animateFooterType:{type:String,default:`fade`,validator:value=>ANIMATION_TYPES.includes(value)}},setup(__props,{expose:__expose}){useCssVars(_ctx=>({v3c03b7b2:backgroundImageStyle.value}));let props=__props,slots=useSlots(),hasFooter=computed(()=>(slots.footer||slots.buttons)&&!props.hideFooter),buttonsContainer=ref(),backgroundImageStyle=computed(()=>props.backgroundImage?`url('${props.backgroundImage}')`:``);return __expose({buttonsContainer}),(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,{class:normalizeClass([`bng-card bng-card-wrapper`,{"with-background-image":backgroundImageStyle.value}])},[createBaseVNode(`div`,_hoisted_1$330,[renderSlot(_ctx.$slots,`default`,{},()=>[_cache[0]||=createTextVNode(`BNG Card`,-1)],!0)]),createVNode(Transition,{name:__props.animateFooter?__props.animateFooterType:``},{default:withCtx(()=>[hasFooter.value?(openBlock(),createElementBlock(`div`,{key:0,ref_key:`buttonsContainer`,ref:buttonsContainer,class:`footer-container`,style:normalizeStyle(__props.footerStyles)},[renderSlot(_ctx.$slots,`buttons`,{},void 0,!0),renderSlot(_ctx.$slots,`footer`,{},void 0,!0)],4)):createCommentVNode(``,!0)]),_:3},8,[`name`])],2))}},bngCard_default=__plugin_vue_export_helper_default(_sfc_main$381,[[`__scopeId`,`data-v-32edaae4`]]),_sfc_main$380={__name:`bngCardHeading`,props:{type:{type:String,default:`line`,validator:v=>[`line`,`ribbon`,`none`].includes(v)||v===``},outline:{type:Boolean,default:!1}},setup(__props){return(_ctx,_cache)=>(openBlock(),createElementBlock(`h2`,{class:normalizeClass({"card-heading":!0,[`heading-style-${__props.type}`]:!0,outline:__props.outline})},[renderSlot(_ctx.$slots,`default`,{},()=>[_cache[0]||=createTextVNode(`BNG Card Heading`,-1)],!0)],2))}},bngCardHeading_default=__plugin_vue_export_helper_default(_sfc_main$380,[[`__scopeId`,`data-v-fc76db37`]]),_hoisted_1$329={key:0,class:`colour-picker-switch`};const VIEWS={simple:{slider:!0,picker:!1,saturation:!1,luminosity:!1},compact_saturation:{slider:!0,picker:!0,saturation:!0,luminosity:!1,compact:!0},compact_luminosity:{slider:!0,picker:!0,saturation:!1,luminosity:!0,compact:!0},saturation:{slider:!1,picker:!0,saturation:!0,luminosity:!1},luminosity:{slider:!1,picker:!0,saturation:!1,luminosity:!0},full_saturation:{slider:!0,picker:!0,saturation:!0,luminosity:!1},full_luminosity:{slider:!0,picker:!0,saturation:!1,luminosity:!0}};var valuesDef={hue:.5,saturation:1,luminosity:.5},_sfc_main$379={__name:`bngColorPicker`,props:{modelValue:{type:Object,default:{...valuesDef}},view:{type:[String,Object],default:`full_luminosity`,validator:val=>typeof val==`string`||val in VIEWS},showText:{type:Boolean,default:!0},step:{type:Number,default:.001},disabled:Boolean},emits:[`update:modelValue`,`change`],setup(__props,{emit:__emit}){let $simplemenu=inject(`$simplemenu`),props=__props,sliderIndicator=`popout`,pickerMode=ref(`luminosity`),opts=ref({}),values=reactive({...valuesDef}),colorDot=ref({x:0,y:0});watch([()=>props.view,$simplemenu],()=>{if(typeof props.view==`string`)for(let key in VIEWS[props.view])opts.value[key]=VIEWS[props.view][key];else opts.value={...VIEWS[props.view]};$simplemenu.value?(opts.value.picker=!1,opts.value.compact&&(opts.value.slider=!0)):opts.value.compact&&loadCompactMode(),opts.value.picker&&setColorDot()},{immediate:!0});function updColour(){for(let key in values)values[key]=props.modelValue[key];opts.value.picker&&setColorDot()}watch(()=>props.modelValue,updColour),watch(()=>props.modelValue.hue,updColour),watch(()=>props.modelValue.saturation,updColour),watch(()=>props.modelValue.luminosity,updColour);let current=computed(()=>({hue:~~(values.hue*360),saturation:~~(values.saturation*100),luminosity:~~(values.luminosity*100)})),emitter=__emit;function notify(){for(let key in values)props.modelValue[key]=values[key];emitter(`change`,props.modelValue),emitter(`update:modelValue`,props.modelValue)}let hueLoop=[...Array(7)].map((_,i)=>i/6*360),gradients=reactive({hueStatic:hueLoop.map(hue=>`hsl(${hue}, 100%, 50%)`),hue:computed(()=>hueLoop.map(hue=>`hsl(${hue}, 100%, 50%)`)),overlaySaturation:[`hsla(0, 0%,  0%, 0)`,`hsla(0, 0%, 50%, 1)`],overlayLuminosity:[`hsla(0, 0%, 100%, 1)`,`hsla(0, 0%, 100%, 0) 50%`,`hsla(0, 0%,   0%, 0) 50%`,`hsla(0, 0%,   0%, 1)`],pickerOverlay:computed(()=>opts.value.saturation?gradients.overlaySaturation:gradients.overlayLuminosity),saturation:computed(()=>[`hsl(${current.value.hue},   0%, ${current.value.luminosity}%)`,`hsl(${current.value.hue}, 100%, ${current.value.luminosity}%)`]),luminosity:computed(()=>[`hsl(${current.value.hue}, ${current.value.saturation}%,   0%)`,`hsl(${current.value.hue}, ${current.value.saturation}%,  50%)`,`hsl(${current.value.hue}, ${current.value.saturation}%, 100%)`])}),isMousedown=!1;function onMousedown(){isMousedown=!0}function onMousemove(evt){updateColor(evt)}function onMouseupLeave(evt){updateColor(evt,!0)}function getPosition(evt){let rect=evt.target.getBoundingClientRect();return rect.width<20?colorDot.value:{x:(evt.x-rect.left)/rect.width*100,y:(evt.y-rect.top)/rect.height*100}}function updateColor(evt,mouseLeave=!1){if(!isMousedown)return;mouseLeave&&(isMousedown=!1);let pos=getPosition(evt);values.hue=Math.max(0,Math.min(pos.x,100))/100;let secondary=1-Math.max(0,Math.min(pos.y,100))/100;opts.value.saturation?values.saturation=secondary:values.luminosity=secondary,setColorDot(),nextTick(notify)}function setColorDot(){colorDot.value={x:values.hue*100,y:(1-(opts.value.saturation?values.saturation:values.luminosity))*100}}function toggleCompactMode(){opts.value.slider=!opts.value.slider,opts.value.picker=!opts.value.picker,saveCompactMode()}function togglePickerMode(){pickerMode.value=pickerMode.value===`luminosity`?`saturation`:`luminosity`,opts.value.luminosity=pickerMode.value===`luminosity`,opts.value.saturation=pickerMode.value===`saturation`,saveCompactMode()}function loadCompactMode(){let readOption=(name,val=null)=>JSON.parse(localStorage.getItem(name)||JSON.stringify(val));opts.value.picker=readOption(`bngColorPicker-picker`,!0),opts.value.slider=readOption(`bngColorPicker-slider`,!1),pickerMode.value=readOption(`bngColorPicker-picker-mode`,`luminosity`),opts.value.luminosity=pickerMode.value===`luminosity`,opts.value.saturation=pickerMode.value===`saturation`,!opts.value.luminosity&&!opts.value.saturation&&(opts.value.luminosity=!0)}function saveCompactMode(){let saveOption=(name,val)=>localStorage.setItem(name,JSON.stringify(val));saveOption(`bngColorPicker-picker`,opts.value.picker),saveOption(`bngColorPicker-slider`,opts.value.slider),saveOption(`bngColorPicker-picker-mode`,pickerMode.value)}return onMounted(()=>{updColour(),!$simplemenu.value&&opts.value.compact&&loadCompactMode()}),(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,{class:normalizeClass({"colour-picker-container":!0,"colour-picker-mode-picker":opts.value.picker,"colour-picker-mode-slider":opts.value.slider,"colour-picker-mode-compact":opts.value.compact})},[opts.value.compact?(openBlock(),createElementBlock(`div`,_hoisted_1$329,[_cache[3]||=createBaseVNode(`span`,null,`Custom color`,-1),!unref($simplemenu)&&opts.value.picker?withDirectives((openBlock(),createBlock(unref(bngButton_default),{key:0,accent:unref(ACCENTS).text,icon:unref(icons).materialTransparency01,onClick:togglePickerMode},null,8,[`accent`,`icon`])),[[unref(BngTooltip_default),`Toggle vertical axis mode to ${pickerMode.value===`luminosity`?`saturation`:`brightness`}`,`top`]]):createCommentVNode(``,!0),unref($simplemenu)?createCommentVNode(``,!0):withDirectives((openBlock(),createBlock(unref(bngButton_default),{key:1,accent:opts.value.picker?unref(ACCENTS).outlined:unref(ACCENTS).text,icon:opts.value.picker?unref(icons).materialGlossy:unref(icons).listSmall,onClick:toggleCompactMode},null,8,[`accent`,`icon`])),[[unref(BngTooltip_default),`Toggle picker/slider mode`,`top`]])])):createCommentVNode(``,!0),opts.value.picker?withDirectives((openBlock(),createElementBlock(`div`,{key:1,class:`colour-picker`,onMousemove,onMousedown,onMouseup:onMouseupLeave,onMouseleave:onMouseupLeave,style:normalizeStyle({"--colour-picker-x":`linear-gradient(90deg, ${gradients.hueStatic.join(`, `)})`,"--colour-picker-y":`linear-gradient(180deg, ${gradients.pickerOverlay.join(`, `)})`})},[createBaseVNode(`div`,{class:`colour-picker-dot`,style:normalizeStyle({left:`${colorDot.value.x}%`,top:`${colorDot.value.y}%`,"--colour-picker-dot-fill":`hsl(${current.value.hue}, ${opts.value.saturation?current.value.saturation:100}%, ${opts.value.luminosity?current.value.luminosity:50}%)`})},null,4)],36)),[[unref(BngDisabled_default),__props.disabled]]):createCommentVNode(``,!0),opts.value.slider||opts.value.hue?(openBlock(),createBlock(unref(bngColorSlider_default),{key:2,modelValue:values.hue,"onUpdate:modelValue":_cache[0]||=$event=>values.hue=$event,modelModifiers:{number:!0},onChange:notify,fill:gradients.hue,current:`hsl(${current.value.hue}, 100%, 50%)`,indicator:sliderIndicator,step:__props.step,disabled:__props.disabled},{default:withCtx(()=>[createTextVNode(toDisplayString(__props.showText?_ctx.$t(`ui.color.hue`):null),1)]),_:1},8,[`modelValue`,`fill`,`current`,`step`,`disabled`])):createCommentVNode(``,!0),opts.value.slider||opts.value.luminosity?(openBlock(),createBlock(unref(bngColorSlider_default),{key:3,"X:vertical":`opts.picker`,modelValue:values.saturation,"onUpdate:modelValue":_cache[1]||=$event=>values.saturation=$event,modelModifiers:{number:!0},onChange:notify,fill:gradients.saturation,current:`hsl(${current.value.hue}, ${current.value.saturation}%, ${current.value.luminosity}%)`,indicator:sliderIndicator,step:__props.step,disabled:__props.disabled},{default:withCtx(()=>[createTextVNode(toDisplayString(__props.showText?`${_ctx.$t(`ui.color.saturation`)} (${current.value.saturation}%)`:null),1)]),_:1},8,[`modelValue`,`fill`,`current`,`step`,`disabled`])):createCommentVNode(``,!0),opts.value.slider||opts.value.saturation?(openBlock(),createBlock(unref(bngColorSlider_default),{key:4,"X:vertical":`opts.picker`,modelValue:values.luminosity,"onUpdate:modelValue":_cache[2]||=$event=>values.luminosity=$event,modelModifiers:{number:!0},onChange:notify,fill:gradients.luminosity,current:`hsl(${current.value.hue}, ${current.value.saturation}%, ${current.value.luminosity}%)`,indicator:sliderIndicator,step:__props.step,disabled:__props.disabled},{default:withCtx(()=>[createTextVNode(toDisplayString(__props.showText?`${_ctx.$t(`ui.color.brightness`)} (${current.value.luminosity}%)`:null),1)]),_:1},8,[`modelValue`,`fill`,`current`,`step`,`disabled`])):createCommentVNode(``,!0)],2))}},bngColorPicker_default=__plugin_vue_export_helper_default(_sfc_main$379,[[`__scopeId`,`data-v-f4241405`]]),_hoisted_1$328={key:0},_hoisted_2$263=[`min`,`max`,`step`,`tabindex`,`orient`],_hoisted_3$230={key:0,class:`colour-slider-indicator-container`},_sfc_main$378={__name:`bngColorSlider`,props:{modelValue:{type:[Number,String],default:0},min:{type:Number,default:0},max:{type:Number,default:1},step:{type:Number,default:.001},fill:{type:Array,default:[`rgb(0,0,0)`,`rgb(255,255,255)`]},current:{type:String,default:null},vertical:Boolean,disabled:Boolean,indicator:{type:String,default:`inner`,validator:val=>[`inner`,`popout`].includes(val)},uiNavFocus:{type:[Boolean,Object],default:{},validator:val=>typeof val==`boolean`&&!val||typeof val==`object`}},emits:[`update:modelValue`,`change`],setup(__props,{emit:__emit}){let props=__props,elSlider=ref(),elIndicator=ref(),tabIndex=computed(()=>props.disabled?-1:0),value=ref(props.modelValue);watch(()=>props.modelValue,val=>value.value=Number(val));let indicatorPos=computed(()=>props.indicator===`popout`?(value.value-props.min)/(props.max-props.min):0),indicatorRot=computed(()=>{if(props.indicator!==`popout`||!elSlider.value||!elIndicator.value||!elSlider.value.getBoundingClientRect||!elIndicator.value.firstChild||!elIndicator.value.firstChild.getBoundingClientRect)return 0;let tilt=40,rot=0,srect=elSlider.value.getBoundingClientRect(),irect=elIndicator.value.firstChild.getBoundingClientRect(),abspos=indicatorPos.value*srect.width,iwidth=irect.width/2;return absposwithDirectives((openBlock(),createElementBlock(`div`,{ref_key:`elSlider`,ref:elSlider,class:`colour-slider`,style:normalizeStyle({"--colour-slider-track-fill":__props.fill&&__props.fill.length>0?`linear-gradient(90deg, ${__props.fill.join(`, `)})`:`transparent`,"--colour-slider-thumb-fill":__props.indicator===`inner`&&__props.current?__props.current:`#000`,"--colour-slider-thumb-size":__props.indicator===`inner`&&__props.current?`1em`:`0.25em`,"--colour-slider-indicator-x":`${indicatorPos.value*100}%`,"--colour-slider-indicator-r":`${indicatorRot.value}deg`})},[_ctx.$slots.default&&!__props.vertical?(openBlock(),createElementBlock(`span`,_hoisted_1$328,[renderSlot(_ctx.$slots,`default`,{},void 0,!0)])):createCommentVNode(``,!0),createBaseVNode(`div`,null,[withDirectives(createBaseVNode(`input`,{type:`range`,min:__props.min,max:__props.max,step:__props.step,"onUpdate:modelValue":_cache[0]||=$event=>value.value=$event,onInput:notify,onChange:notify,tabindex:tabIndex.value,class:normalizeClass({"colour-slider-vertical":__props.vertical}),orient:__props.vertical?`vertical`:`horizontal`},null,42,_hoisted_2$263),[[vModelText,value.value,void 0,{number:!0}],[unref(BngOnUiNavFocus_default),__props.uiNavFocus?{callback:(dir,val)=>{value.value=val,notify()},value:()=>value.value,min:__props.min,max:__props.max,step:()=>+__props.step,...__props.uiNavFocus}:!1,void 0,{repeat:!0}]]),__props.indicator===`popout`?(openBlock(),createElementBlock(`div`,_hoisted_3$230,[createBaseVNode(`div`,{ref_key:`elIndicator`,ref:elIndicator,class:`colour-slider-indicator`},[createVNode(unref(bngIconMarker_default),{marker:`circlePin`,color:[`#fff`,__props.current],class:`colour-slider-indicator-marker`},null,8,[`color`])],512)])):createCommentVNode(``,!0)])],4)),[[unref(BngDisabled_default),__props.disabled]])}},bngColorSlider_default=__plugin_vue_export_helper_default(_sfc_main$378,[[`__scopeId`,`data-v-346533a2`]]),_hoisted_1$327={class:`bng-color-tile`},_sfc_main$377={__name:`bngColorTile`,props:{red:{type:Number},blue:{type:Number},green:{type:Number},alpha:{type:Number,default:1}},setup(__props){useCssVars(_ctx=>({cef4bc4e:backgroundColor.value}));let props=__props,backgroundColor=computed(()=>`rgba(${props.red}, ${props.green}, ${props.blue}, ${props.alpha})`);return(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$327))}},bngColorTile_default=__plugin_vue_export_helper_default(_sfc_main$377,[[`__scopeId`,`data-v-32089404`]]),_sfc_main$376={__name:`bngCondition`,props:{integrity:{type:Number,default:1},integrityWarning:Boolean,color:{type:[String,Array],default:`#000`},showTooltip:Boolean},setup(__props){let props=__props,integrity=computed(()=>typeof props.integrity==`number`?Math.min(Math.max(props.integrity,0),1):1),tooltip=computed(()=>{if(!props.showTooltip)return;let tip=`${$translate.instant(`ui.condition.integrity`)}: ${~~(integrity.value*100)}%`;return props.integrityWarning&&(tip+=`\n${$translate.instant(`ui.condition.needsRepair`)}`),tip}),cssColour=computed(()=>{let clr=props.color;return Array.isArray(clr)?(clr=[...clr],clr.length>3&&(clr.splice(3),clr.some(c=>c>1)||(clr=clr.map(c=>c*255))),`rgb(${clr.join(`,`)})`):clr}),cssClipPoly=computed(()=>{let val=integrity.value,corners=[`100% 0%`,`100% 100%`,`0% 100%`,`0% 0%`],poly=`0% 0%`;if(val===1)poly=corners.join(`, `);else if(val>0){let deg=(1-val)*360,x=50+50*Math.sin(deg*Math.PI/180),y=50-50*Math.cos(deg*Math.PI/180);poly=`50% 0%, 50% 50%, ${~~x}% ${~~y}%, `+corners.slice(-Math.ceil((360-deg)/90)).join(`, `)}return poly});return(_ctx,_cache)=>withDirectives((openBlock(),createElementBlock(`div`,{class:normalizeClass({"bng-condition":!0,"cond-warn":__props.integrityWarning}),style:normalizeStyle({backgroundColor:cssColour.value,"--bng-condition-clip-path":`polygon(${cssClipPoly.value})`})},null,6)),[[unref(BngTooltip_default),tooltip.value]])}},bngCondition_default=__plugin_vue_export_helper_default(_sfc_main$376,[[`__scopeId`,`data-v-686a3067`]]),SCOPED_CHANGED_EVENT_NAME=`scopeChanged`,EVENT_CROSSFIRE_MAP={ok:`select`,back:`back`,tab_l:`tabLeft`,tab_r:`tabRight`};const CROSSFIRE_HINTS={select:{id:`select`,content:{type:`binding`,props:{uiEvent:`ok`},label:`Select`}},back:{id:`back`,content:{type:`binding`,props:{uiEvent:`back`},label:`Back`}},tabLeft:{id:`tabLeft`,content:{type:`binding`,props:{uiEvent:`tab_l`},label:`Tab left`}},tabRight:{id:`tabRight`,content:{type:`binding`,props:{uiEvent:`tab_r`},label:`Tab right`}}},CROSSFIRE_HINTS_ALL=Object.values(CROSSFIRE_HINTS),DEFAULT_LABELS={focus_u:`ui.inputActions.controllerui.focus_u.title`,focus_r:`ui.inputActions.controllerui.focus_r.title`,focus_d:`ui.inputActions.controllerui.focus_d.title`,focus_l:`ui.inputActions.controllerui.focus_l.title`,pause:`ui.inputActions.general.pause.title`,menu:`ui.inputActions.controllerui.menu.title`,back:`ui.inputActions.controllerui.back.title`,details:`ui.inputActions.controllerui.details.title`,advanced:`ui.inputActions.controllerui.advanced.title`,camera:`ui.inputActions.controllerui.camera.title`,logs:`ui.inputActions.controllerui.logs.title`,tab_l:`ui.inputActions.controllerui.tab_l.title`,tab_r:`ui.inputActions.controllerui.tab_r.title`,modifier:`ui.inputActions.controllerui.modifier.title`,zoom_out:`ui.inputActions.controllerui.zoom_out.title`,zoom_in:`ui.inputActions.controllerui.zoom_in.title`,subtab_l:`ui.inputActions.controllerui.subtab_l.title`,subtab_r:`ui.inputActions.controllerui.subtab_r.title`,center_cam:`ui.inputActions.controllerui.center_cam.title`,action_4:`ui.inputActions.controllerui.action_4.title`,move_ud:`ui.inputActions.controllerui.move_ud.title`,move_lr:`ui.inputActions.controllerui.move_lr.title`,focus_ud:`ui.inputActions.controllerui.focus_ud.title`,focus_lr:`ui.inputActions.controllerui.focus_lr.title`,rotate_h_cam:`ui.inputActions.controllerui.rotate_h_cam.title`,rotate_v_cam:`ui.inputActions.controllerui.rotate_v_cam.title`,ok:`ui.inputActions.controllerui.ok.title`,cancel:`ui.inputActions.controllerui.cancel.title`,action_2:`ui.inputActions.controllerui.action_2.title`,action_3:`ui.inputActions.controllerui.action_3.title`,context:`ui.inputActions.controllerui.context.title`};var HINT_GROUPS=()=>[{names:[`back`,`menu`],label:`ui.inputActions.controllerui.back.title`},{names:[`focus_u`,`focus_d`,`focus_r`,`focus_l`,`focus_lr`,`focus_ud`],label:`ui.mainmenu.navbar.navigate`,controllerOnly:!0},{names:[`focus_u`,`focus_d`,`focus_r`,`focus_l`],label:`ui.mainmenu.navbar.navigate`},{names:[`focus_lr`,`focus_ud`],label:`ui.mainmenu.navbar.navigate`,controllerOnly:!0},{names:[SCROLL_EVENT_H,SCROLL_EVENT_V],label:`ui.mainmenu.navbar.scroll_label`,controllerOnly:!0},{names:[`tab_r`,`tab_l`],label:`ui.mainmenu.navbar.navigate`,controllerOnly:!0}],AUTOID=`__auto`,AUTOIDS={binding:`${AUTOID}_binding`,group:`${AUTOID}_group`,labelGroup:`${AUTOID}_label_group`},DISPLAY_ACTION_VARIANTS=!1;const useInfoBar=defineStore(`infoBar`,()=>{let{events:events$3}=useBridge(),Controls=controls_default(),{isControllerUsed,lastDevice}=storeToRefs(Controls),hintGroups=HINT_GROUPS(),visible=ref(!1),showSysInfo=ref(!1),withAngular=ref(!1),hintsList=ref([]),hints=ref([]);watch([isControllerUsed,lastDevice],()=>_groupHints());let getControlGroup=(uiEvents,groupLabel)=>{try{let actions=uiEvents.map(event=>ACTIONS_BY_UI_EVENT[event]).filter(Boolean);if(actions.length!==uiEvents.length)return null;let viewerObjs=actions.map(action=>Controls.makeViewerObj({action,actionVariants:DISPLAY_ACTION_VARIANTS,useLastDevice:!0})).flatMap(vo=>vo?.variants?vo.variants:vo?[vo]:[]),matchingItems=[],devNames=viewerObjs.reduce((res,obj)=>obj&&!res.includes(obj.devName)?[...res,obj.devName]:res,[]);for(let devName of devNames){if(!devName)continue;let devViewerObjs=viewerObjs.filter(obj=>obj&&obj.devName===devName&&obj.ownGroups);if(devViewerObjs.length===0)continue;let groups=devViewerObjs[0].ownGroups,controls$1=devViewerObjs.map(obj=>obj.control);for(let group of groups){if(!group.controls.every(control=>controls$1.includes(control)))continue;controls$1=controls$1.filter(control=>!group.controls.includes(control));let item;item=group.label?{type:`binding`,props:{viewerObj:{icon:devViewerObjs[0].icon,ownLabel:group.label}},label:groupLabel}:{type:`icon`,props:{type:icons[group.icon]},label:groupLabel},matchingItems.push(item)}}return matchingItems.length===0?null:matchingItems.length===1?matchingItems[0]:matchingItems}catch(err){return logger_default.error(`Error in checkForControlGroup:`,err),null}},_groupHints=()=>{let res=[],groupCandidates={},labelGroups={},isCustomLabel=content=>content&&!content.autoLabel&&content?.props?.uiEvent&&content.label!==DEFAULT_LABELS[content?.props?.uiEvent];for(let hint of hintsList.value){let normalizedHint=hint.content?hint:{content:hint},{content}=normalizedHint;if(!content?.props?.uiEvent||!content.label){res.push(normalizedHint);continue}let labelKey=content.label;labelGroups[labelKey]?labelGroups[labelKey].hints.push(normalizedHint):labelGroups[labelKey]={hints:[normalizedHint],position:res.length}}let selectMatchingGroup=matchingGroups=>matchingGroups.length<1||isControllerUsed.value?matchingGroups[0]:matchingGroups.find(group=>!group.controllerOnly)||matchingGroups.at(-1);for(let[label,group]of Object.entries(labelGroups)){let action=group.hints[0].action;if(group.hints.length>1){let events$4=group.hints.map(h$1=>h$1.content.props.uiEvent),matchingGroup=selectMatchingGroup(hintGroups.filter(g=>g.content&&g.names.every(name=>events$4.includes(name))&&events$4.filter(e=>g.names.includes(e)).length===g.names.length));if(matchingGroup){if(matchingGroup.controllerOnly&&!isControllerUsed.value)continue;let groupContent=Array.isArray(matchingGroup.content)?matchingGroup.content[0]:matchingGroup.content,groupLabel=matchingGroup.label||groupContent?.label||group.hints[0]?.content?.label,groupEvents=group.hints.map(h$1=>h$1.content.props.uiEvent),labeledBindings=group.hints.map(h$1=>{let newContent={id:h$1.id,type:h$1.content.type,props:{...h$1.content.props}};return newContent.label=isCustomLabel(h$1.content)?h$1.content.label:groupLabel,newContent}),controlGroup=getControlGroup(groupEvents,groupLabel);if(controlGroup){let content=Array.isArray(controlGroup)?controlGroup.map(item=>({...item})):[{...controlGroup}],customLabelItem=group.hints.find(h$1=>isCustomLabel(h$1.content));customLabelItem&&content.forEach(item=>{item.label=customLabelItem.content.label}),res.splice(group.position,0,{id:`${AUTOIDS.labelGroup}_${label}`,content,action})}else res.splice(group.position,0,{id:`${AUTOIDS.labelGroup}_${label}`,content:labeledBindings,action})}else res.splice(group.position,0,{id:`${AUTOIDS.labelGroup}_${label}`,content:group.hints.map(h$1=>h$1.content),action})}else{let hint=group.hints[0],uiEvent=hint.content?.props?.uiEvent,isNoGroup=uiEvent$1=>uiNavTracker.activeEvents.find(e=>e.name===uiEvent$1)?.nogroup;if(isNoGroup(uiEvent)){res.push(hint);continue}let matchingGroup=selectMatchingGroup(hintGroups.filter(group$1=>group$1.names.includes(uiEvent)));if(!matchingGroup){res.push(hint);continue}let groupId=matchingGroup.names.join(`,`);groupId in groupCandidates||(groupCandidates[groupId]={hints:[],content:[],position:res.length});let groupCandidate=groupCandidates[groupId];if(groupCandidate.hints.push(hint),groupCandidate.content.push(hint.content),groupCandidate.hints.length===matchingGroup.names.length){if(matchingGroup.controllerOnly&&!isControllerUsed.value){delete groupCandidates[groupId];continue}if(groupCandidate.hints.some(h$1=>isNoGroup(h$1.content?.props?.uiEvent)))res.splice(groupCandidate.position,0,...groupCandidate.hints);else{let groupContent=Array.isArray(matchingGroup.content)?matchingGroup.content[0]:matchingGroup.content,groupLabel=matchingGroup.label||groupContent?.label||groupCandidate.hints[0]?.content?.label,labeledContent=groupCandidate.content.map(item=>{let newContent={id:item.id,type:item.type,props:{...item.props}};return isCustomLabel(item)?newContent.label=item.label:newContent.label=groupLabel,newContent}),controlGroup=getControlGroup(groupCandidate.hints.map(h$1=>h$1.content.props.uiEvent),groupLabel);if(controlGroup){let content=Array.isArray(controlGroup)?controlGroup.map(icon=>({...icon})):[{...controlGroup}],customLabelItem=groupCandidate.content.find(item=>isCustomLabel(item));customLabelItem&&content.forEach(icon=>icon.label=customLabelItem.label),res.splice(groupCandidate.position,0,{id:`${AUTOIDS.group}_${groupId}`,content,action})}else res.splice(groupCandidate.position,0,{id:`${AUTOIDS.group}_${groupId}`,content:labeledContent,action})}delete groupCandidates[groupId]}}}for(let group of Object.values(groupCandidates))res.splice(group.position,0,...group.hints);hints.value=res},uiNavTracker=useUINavTracker(),clearHints=()=>{hintsList.value=[],_addTrackedEvents()},addHints=(hintOrHints,idOrPos=void 0,before=!1)=>{if(hintOrHints===CROSSFIRE_HINTS_ALL){logger_default.warn(`Approach with CROSSFIRE_HINTS_ALL is deprecated and crossfire hints are added by default.`);return}let toAdd=[hintOrHints].flat().map(hint=>{if(typeof hint!=`object`)return hint;let content=hint.content||hint,uiEvent=content?.props?.uiEvent;return uiEvent&&(content.label||(content.autoLabel=!0,uiEvent in DEFAULT_LABELS?content.label=DEFAULT_LABELS[uiEvent]:content.label=uiEvent.replaceAll(`_`,` `).toUpperCase())),hint});if(idOrPos===void 0)hintsList.value=hintsList.value.concat(toAdd);else if(typeof idOrPos==`number`)hintsList.value.splice(idOrPos,0,...toAdd);else if(typeof idOrPos==`string`){let foundIndex=_findHintIndex(idOrPos);foundIndex>-1&&hintsList.value.splice(foundIndex+(before?0:1),0,...toAdd)}_groupHints()},updateHint=(idOrPos,updatedHint)=>{if(typeof idOrPos==`number`)hintsList.value[idOrPos]=updatedHint;else{let foundIndex=_findHintIndex(idOrPos);hintsList.value[foundIndex]=updatedHint}_groupHints()},removeHints=(...ids)=>{ids.forEach(id=>{let foundIndex=_findHintIndex(id);foundIndex>-1&&hintsList.value.splice(foundIndex,1)}),_groupHints()},flashHints=(...ids)=>{_setFlash(!1,ids),setTimeout(()=>_setFlash(!0,ids),0)},_setFlash=(state,ids)=>ids.forEach(id=>{let foundIndex=_findHintIndex(id);foundIndex>-1&&(hintsList.value[foundIndex].flash=state)}),highlightHints=(state,...ids)=>{},_findHintIndex=id=>hintsList.value.findIndex(h$1=>h$1.id===id);events$3.on(SCOPED_CHANGED_EVENT_NAME,data=>{logger_default.debug(`[infoBar] received data`,data),data&&(clearHints(),data.forEach(ev=>{let content;content=ev.label?{content:{type:`binding`,props:{uiEvent:ev.event},label:ev.label}}:CROSSFIRE_HINTS[EVENT_CROSSFIRE_MAP[ev.event]],addHints(content)}))});function _addTrackedEvents(){let activeEvents=uiNavTracker.activeEvents;hintsList.value=hintsList.value.filter(hint=>!hint.id?.startsWith(AUTOID)&&activeEvents.some(e=>e.name===hint.content.props.uiEvent));let currentBindings=hintsList.value.filter(hint=>hint.content?.type===`binding`).map(hint=>hint.content.props.uiEvent);addHints(activeEvents.filter(({name})=>!currentBindings.includes(name)).map(({name,label,nogroup,action})=>({id:`${AUTOIDS.binding}_${name}`,content:{type:`binding`,props:{uiEvent:name},label,autoLabel:!label||label===DEFAULT_LABELS[name]},nogroup,action})))}return watch(()=>uiNavTracker.activeEvents,_addTrackedEvents,{deep:!0}),{visible,hintsList,hints,showSysInfo,withAngular,clearHints,addHints,updateHint,removeHints,flashHints,highlightHints}});var _hoisted_1$326={key:0,xmlns:`http://www.w3.org/2000/svg`,viewBox:`20 140 460 220`},_hoisted_2$262={class:`bng-controller-hint-labels`},_hoisted_3$229={x:`120`,y:`165`,"text-anchor":`middle`},_hoisted_4$196={x:`120`,y:`335`,"text-anchor":`middle`},_hoisted_5$166={x:`45`,y:`255`,"text-anchor":`end`},_hoisted_6$142={x:`175`,y:`255`,"text-anchor":`start`},_hoisted_7$124={x:`219`,y:`315`,"text-anchor":`middle`},_hoisted_8$102={x:`249`,y:`315`,"text-anchor":`middle`},_hoisted_9$92={x:`340`,y:`175`,"text-anchor":`middle`},_hoisted_10$80={x:`380`,y:`335`,"text-anchor":`middle`},_sfc_main$375={__name:`bngControllerHint`,props:{device:String,actions:[Array,String],dark:Boolean},setup(__props,{expose:__expose}){let Controls=controls_default(),props=__props,available=[`xbox`],devName=computed(()=>{if(!props.device)return Controls.lastDevice;let devName$1=props.device;return/\d$/.test(devName$1)||(devName$1=Controls.lastDevices.find(dev=>dev.startsWith(devName$1)),devName$1||=props.device+`0`),devName$1}),devFamily=computed(()=>{let family=Controls.makeViewerObj({device:devName.value,uiEvent:`back`})?.family;return!family||!available.includes(family)?null:family});__expose({displayed:computed(()=>!!devFamily.value)});let actions=computed(()=>{let actions$1=props.actions;if(!actions$1||!devFamily.value)return{};if(typeof actions$1==`string`)actions$1=[actions$1];else if(!Array.isArray(actions$1)||actions$1.length===0)return{};let bindings={},allEvents=Object.keys(ACTIONS_BY_UI_EVENT),allActions=Object.values(ACTIONS_BY_UI_EVENT);for(let action of actions$1){if(!action)continue;let item=action;if(typeof item==`string`)item={action:item};else if(!item.action&&!item.event)continue;else item={...item};let actIdx=allEvents.indexOf(item.event||item.action);if(actIdx>-1&&(item.event=allEvents[actIdx],item.action=allActions[actIdx]),!allActions.includes(item.action))continue;let binding=Controls.findBindingForAction(item.action,devName.value);if(binding){if(!item.event||item.event===item.action){let idx=allActions.indexOf(item.action);idx>-1&&(item.event=allEvents[idx])}item.label||=DEFAULT_LABELS[item.event]||item.event||item.action,item.shown=!0,item.class={flash:item.flash},bindings[binding.control.toLowerCase()]=item}}logger_default.debug(`resolved actions:`,bindings);for(let keyName of DEVICE_CONTROLS[devFamily.value]){let key=keyName.toLowerCase();key in bindings||(bindings[key]={class:{inactive:!0}})}return bindings});return(_ctx,_cache)=>devFamily.value?(openBlock(),createElementBlock(`div`,{key:0,class:normalizeClass([`bng-controller-hint`,{"bng-controller-hint-dark":__props.dark}])},[devFamily.value===`xbox`?(openBlock(),createElementBlock(`svg`,_hoisted_1$326,[_cache[8]||=createBaseVNode(`rect`,{x:`60`,y:`180`,width:`380`,height:`140`,rx:`20`,fill:`#bcbcbc`,stroke:`#333`,"stroke-width":`8`},null,-1),_cache[9]||=createBaseVNode(`circle`,{cx:`120`,cy:`250`,r:`28`,fill:`#222`},null,-1),createBaseVNode(`rect`,{class:normalizeClass(actions.value.upov.class),x:`114`,y:`222`,width:`12`,height:`20`,rx:`3`,fill:`#444`},null,2),createBaseVNode(`rect`,{class:normalizeClass(actions.value.dpov.class),x:`114`,y:`258`,width:`12`,height:`20`,rx:`3`,fill:`#444`},null,2),createBaseVNode(`rect`,{class:normalizeClass(actions.value.lpov.class),x:`98`,y:`242`,width:`20`,height:`12`,rx:`3`,fill:`#444`},null,2),createBaseVNode(`rect`,{class:normalizeClass(actions.value.rpov.class),x:`122`,y:`242`,width:`20`,height:`12`,rx:`3`,fill:`#444`},null,2),createBaseVNode(`rect`,{class:normalizeClass(actions.value.btn_start.class),x:`210`,y:`240`,width:`18`,height:`10`,rx:`3`,fill:`#888`},null,2),createBaseVNode(`rect`,{class:normalizeClass(actions.value.btn_back.class),x:`240`,y:`240`,width:`18`,height:`10`,rx:`3`,fill:`#888`},null,2),createBaseVNode(`circle`,{class:normalizeClass(actions.value.btn_a.class),cx:`340`,cy:`230`,r:`18`,fill:`#22a`},null,2),createBaseVNode(`circle`,{class:normalizeClass(actions.value.btn_b.class),cx:`380`,cy:`270`,r:`18`,fill:`#22a`},null,2),createBaseVNode(`g`,_hoisted_2$262,[actions.value.upov?.shown?(openBlock(),createElementBlock(Fragment,{key:0},[_cache[0]||=createBaseVNode(`line`,{x1:`120`,y1:`202`,x2:`120`,y2:`170`,stroke:`#666`,"stroke-width":`2`},null,-1),createBaseVNode(`text`,_hoisted_3$229,toDisplayString(_ctx.$tt(actions.value.upov?.label)),1)],64)):createCommentVNode(``,!0),actions.value.dpov?.shown?(openBlock(),createElementBlock(Fragment,{key:1},[_cache[1]||=createBaseVNode(`line`,{x1:`120`,y1:`298`,x2:`120`,y2:`320`,stroke:`#666`,"stroke-width":`2`},null,-1),createBaseVNode(`text`,_hoisted_4$196,toDisplayString(_ctx.$tt(actions.value.dpov?.label)),1)],64)):createCommentVNode(``,!0),actions.value.lpov?.shown?(openBlock(),createElementBlock(Fragment,{key:2},[_cache[2]||=createBaseVNode(`line`,{x1:`78`,y1:`250`,x2:`50`,y2:`250`,stroke:`#666`,"stroke-width":`2`},null,-1),createBaseVNode(`text`,_hoisted_5$166,toDisplayString(_ctx.$tt(actions.value.lpov?.label)),1)],64)):createCommentVNode(``,!0),actions.value.rpov?.shown?(openBlock(),createElementBlock(Fragment,{key:3},[_cache[3]||=createBaseVNode(`line`,{x1:`142`,y1:`250`,x2:`170`,y2:`250`,stroke:`#666`,"stroke-width":`2`},null,-1),createBaseVNode(`text`,_hoisted_6$142,toDisplayString(_ctx.$tt(actions.value.rpov?.label)),1)],64)):createCommentVNode(``,!0),actions.value.btn_start?.shown?(openBlock(),createElementBlock(Fragment,{key:4},[_cache[4]||=createBaseVNode(`line`,{x1:`219`,y1:`270`,x2:`219`,y2:`300`,stroke:`#666`,"stroke-width":`2`},null,-1),createBaseVNode(`text`,_hoisted_7$124,toDisplayString(_ctx.$tt(actions.value.btn_start?.label)),1)],64)):createCommentVNode(``,!0),actions.value.btn_back?.shown?(openBlock(),createElementBlock(Fragment,{key:5},[_cache[5]||=createBaseVNode(`line`,{x1:`249`,y1:`270`,x2:`249`,y2:`300`,stroke:`#666`,"stroke-width":`2`},null,-1),createBaseVNode(`text`,_hoisted_8$102,toDisplayString(_ctx.$tt(actions.value.btn_back?.label)),1)],64)):createCommentVNode(``,!0),actions.value.btn_a?.shown?(openBlock(),createElementBlock(Fragment,{key:6},[_cache[6]||=createBaseVNode(`line`,{x1:`340`,y1:`212`,x2:`340`,y2:`180`,stroke:`#666`,"stroke-width":`2`},null,-1),createBaseVNode(`text`,_hoisted_9$92,toDisplayString(_ctx.$tt(actions.value.btn_a?.label)),1)],64)):createCommentVNode(``,!0),actions.value.btn_b?.shown?(openBlock(),createElementBlock(Fragment,{key:7},[_cache[7]||=createBaseVNode(`line`,{x1:`380`,y1:`288`,x2:`380`,y2:`320`,stroke:`#666`,"stroke-width":`2`},null,-1),createBaseVNode(`text`,_hoisted_10$80,toDisplayString(_ctx.$tt(actions.value.btn_b?.label)),1)],64)):createCommentVNode(``,!0)])])):createCommentVNode(``,!0)],2)):createCommentVNode(``,!0)}},bngControllerHint_default=__plugin_vue_export_helper_default(_sfc_main$375,[[`__scopeId`,`data-v-bb01f791`]]),_sfc_main$374={},_hoisted_1$325={class:`divider vertical-divider`};function _sfc_render$6(_ctx,_cache){return openBlock(),createElementBlock(`div`,_hoisted_1$325)}var bngDivider_default=__plugin_vue_export_helper_default(_sfc_main$374,[[`render`,_sfc_render$6],[`__scopeId`,`data-v-c3fbf7df`]]),_sfc_main$373={__name:`bngDrawer`,props:mergeModels({header:String,blur:Boolean,expandable:{type:Boolean,default:!0},position:String},{modelValue:{type:Boolean},modelModifiers:{}}),emits:mergeModels([`change`],[`update:modelValue`]),setup(__props,{emit:__emit}){let props=__props,emit$1=__emit,slots=useSlots(),arrows=computed(()=>{switch(props.position){default:case DRAWER_POSITION.bottom:case DRAWER_POSITION.right:return{expand:icons.arrowLargeUp,collapse:icons.arrowLargeDown};case DRAWER_POSITION.top:case DRAWER_POSITION.left:return{expand:icons.arrowLargeDown,collapse:icons.arrowLargeUp}}}),expanded=useModel(__props,`modelValue`);return watch(()=>expanded.value,val=>emit$1(`change`,val)),watch([()=>props.expandable,()=>expanded.value],()=>!props.expandable&&expanded.value&&(expanded.value=!1),{immediate:!0}),(_ctx,_cache)=>(openBlock(),createBlock(unref(drawer_default),{modelValue:expanded.value,"onUpdate:modelValue":_cache[1]||=$event=>expanded.value=$event,blur:__props.blur,position:__props.position},createSlots({header:withCtx(()=>[createVNode(unref(bngCardHeading_default),{class:`header`,type:`ribbon`,style:normalizeStyle({marginRight:!__props.header&&!unref(slots).header?`0`:void 0})},{default:withCtx(()=>[__props.header?(openBlock(),createElementBlock(Fragment,{key:0},[createTextVNode(toDisplayString(__props.header),1)],64)):renderSlot(_ctx.$slots,`header`,{key:1},()=>[_cache[2]||=createBaseVNode(`span`,null,null,-1)],!0)]),_:3},8,[`style`]),renderSlot(_ctx.$slots,`header-controls`,{},void 0,!0),__props.expandable?(openBlock(),createBlock(unref(bngButton_default),{key:0,accent:`text`,icon:expanded.value?arrows.value.collapse:arrows.value.expand,onClick:_cache[0]||=$event=>expanded.value=!expanded.value},null,8,[`icon`])):createCommentVNode(``,!0)]),_:2},[`content`in unref(slots)?{name:`content`,fn:withCtx(()=>[renderSlot(_ctx.$slots,`content`,{},void 0,!0)]),key:`0`}:void 0,`expanded-content`in unref(slots)?{name:`expanded-content`,fn:withCtx(()=>[renderSlot(_ctx.$slots,`expanded-content`,{},void 0,!0)]),key:`1`}:`default`in unref(slots)?{name:`expanded-content`,fn:withCtx(()=>[renderSlot(_ctx.$slots,`default`,{},void 0,!0)]),key:`2`}:void 0]),1032,[`modelValue`,`blur`,`position`]))}},bngDrawer_default=__plugin_vue_export_helper_default(_sfc_main$373,[[`__scopeId`,`data-v-30948d98`]]),_hoisted_1$324={class:`bng-drawer`},_hoisted_2$261={class:`header-wrapper`},_hoisted_3$228={class:`content`},_sfc_main$372={__name:`bngDrawerOld`,props:{header:{type:String},blur:{type:Boolean,default:!1}},setup(__props){return(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$324,[withDirectives((openBlock(),createElementBlock(`div`,_hoisted_2$261,[createVNode(unref(bngCardHeading_default),{class:`header`,type:`ribbon`},{default:withCtx(()=>[__props.header?(openBlock(),createElementBlock(Fragment,{key:0},[createTextVNode(toDisplayString(__props.header),1)],64)):renderSlot(_ctx.$slots,`header`,{key:1},void 0,!0)]),_:3}),renderSlot(_ctx.$slots,`headerOptions`,{},void 0,!0)])),[[unref(BngBlur_default),__props.blur]]),withDirectives((openBlock(),createBlock(unref(bngCard_default),null,{default:withCtx(()=>[createBaseVNode(`div`,_hoisted_3$228,[renderSlot(_ctx.$slots,`content`,{},void 0,!0)])]),_:3})),[[unref(BngBlur_default),__props.blur]])]))}},bngDrawerOld_default=__plugin_vue_export_helper_default(_sfc_main$372,[[`__scopeId`,`data-v-9e5c32b1`]]),_hoisted_1$323={class:`dropdown-display`},_hoisted_2$260={key:0,class:`dropdown-search`},_hoisted_3$227={key:1},_hoisted_4$195={key:0,class:`dropdown-group-header`},_hoisted_5$165=[`bng-nav-item`,`tabindex`,`bng-scoped-nav-autofocus`,`onClick`,`onKeyup`],_sfc_main$371={__name:`bngDropdown`,props:{modelValue:{type:[Number,String,Boolean,Object]},items:{type:Array,required:!0},showSearch:Boolean,highlight:{type:[String,Array,RegExp]},disabled:Boolean,longNames:{type:String,default:`oneline`,validator:val=>[`oneline`,`wrap`,`cut`].includes(val)},searchGroupName:Boolean,headless:Boolean,focusTarget:Object,popoverTarget:Object},emits:[`update:modelValue`,`valueChanged`,`open`,`close`],setup(__props,{expose:__expose,emit:__emit}){let attrs=useAttrs(),binds=computed(()=>props.headless?void 0:attrs),props=__props,emit$1=__emit,elContainer=ref(null),opened=ref(!1),searching=ref(!1),search$1=ref(``),searchTerm=computed(()=>search$1.value.toLowerCase());watch(opened,val=>!val&&(search$1.value=``)),__expose({opened,open:()=>opened.value=!0,close:()=>opened.value=!1,toggle:()=>opened.value=!opened.value,get popoverName(){return elContainer.value?.popoverName}});let groupedItems=computed(()=>{let hasGrouping=props.items.some(item=>item.group||item.grouped),searchActive=!!searchTerm.value;if(!hasGrouping)return[{header:null,items:searchActive?props.items.filter(item=>item.label.toLowerCase().includes(searchTerm.value)):props.items}];let groups=[],currentGroup=null;return props.items.forEach(item=>{item.group?(currentGroup={header:item,allItems:[],_headerMatches:item.label.toLowerCase().includes(searchTerm.value)},groups.push(currentGroup)):item.grouped?currentGroup?currentGroup.allItems.push(item):groups.push({header:null,allItems:[item]}):(groups.push({header:null,allItems:[item]}),currentGroup=null)}),groups.map(group=>{if(searchActive)if(group.header){if(props.searchGroupName&&group._headerMatches)return{header:group.header,items:group.allItems,headerMatches:!0};{let filteredItems=group.allItems.filter(item=>item.label.toLowerCase().includes(searchTerm.value));return{header:group.header,items:filteredItems,headerMatches:!1}}}else return{header:null,items:group.allItems.filter(item=>item.label.toLowerCase().includes(searchTerm.value))};else return{header:group.header||null,items:group.allItems}}).filter(group=>group.header&&props.searchGroupName&&group.headerMatches||group.items.length>0)}),highlighter$1=computed(()=>search$1.value||props.highlight),selectedValue=computed({get:()=>props.modelValue,set:newValue=>{emit$1(`update:modelValue`,newValue),emit$1(`valueChanged`,newValue)}}),selectedItem=computed(()=>props.items.find(x=>x.value===selectedValue.value)),headerText=computed(()=>selectedItem.value&&selectedItem.value.value!==null&&selectedItem.value.value!==void 0?selectedItem.value.label:`Select`),tabIndexValue=computed(()=>props.disabled?-1:0),select=item=>{item.disabled||(opened.value=!1,selectedValue.value!==item.value&&(selectedValue.value=item.value),elContainer.value?.focusContainer())};return(_ctx,_cache)=>(openBlock(),createBlock(unref(bngDropdownContainer_default),mergeProps({ref_key:`elContainer`,ref:elContainer},binds.value,{opened:opened.value,"onUpdate:opened":_cache[3]||=$event=>opened.value=$event,disabled:__props.disabled,headless:__props.headless,"focus-target":__props.focusTarget,"popover-target":__props.popoverTarget,class:{"with-search":__props.showSearch,[`dropdown-longnames-${__props.longNames}`]:!0},onShow:_cache[4]||=$event=>emit$1(`open`),onHide:_cache[5]||=$event=>emit$1(`close`)}),createSlots({default:withCtx(()=>[__props.showSearch?(openBlock(),createElementBlock(`div`,_hoisted_2$260,[createVNode(unref(bngInput_default),{modelValue:search$1.value,"onUpdate:modelValue":_cache[0]||=$event=>search$1.value=$event,modelModifiers:{trim:!0},"floating-label":`Search`,onFocus:_cache[1]||=$event=>searching.value=!0,onBlur:_cache[2]||=$event=>searching.value=!1},null,8,[`modelValue`])])):createCommentVNode(``,!0),search$1.value&&groupedItems.value.every(group=>group.items.length===0)?(openBlock(),createElementBlock(`div`,_hoisted_3$227,toDisplayString(_ctx.$t(`ui.common.search.noResults`)),1)):(openBlock(!0),createElementBlock(Fragment,{key:2},renderList(groupedItems.value,(group,groupIndex)=>(openBlock(),createElementBlock(Fragment,{key:groupIndex},[group.header?(openBlock(),createElementBlock(`div`,_hoisted_4$195,toDisplayString(group.header.label),1)):createCommentVNode(``,!0),(openBlock(!0),createElementBlock(Fragment,null,renderList(group.items,(item,idx)=>withDirectives((openBlock(),createElementBlock(`div`,{key:item.value,class:normalizeClass([`dropdown-option`,{selected:selectedItem.value&&selectedItem.value.value===item.value,"grouped-item":group.header,disabled:item.disabled}]),"bng-nav-item":!item.disabled||item.focusable,tabindex:item.disabled?-1:tabIndexValue.value,"bng-scoped-nav-autofocus":!item.disabled&&!searching.value&&(selectedItem.value&&selectedItem.value.value===item.value||!selectedItem.value&&groupIndex===0&&idx===0),onClick:$event=>select(item),onKeyup:withKeys($event=>select(item),[`enter`])},[createTextVNode(toDisplayString(item.label),1)],42,_hoisted_5$165)),[[unref(BngOnUiNav_default),void 0,`ok`,{asMouse:!0,focusRequired:!0}],[unref(BngUiNavLabel_default),`ui.inputActions.menu.menu_item_select.title`,`ok`],[unref(BngTooltip_default),item.tooltip??void 0],[unref(BngHighlighter_default),highlighter$1.value]])),128))],64))),128))]),_:2},[__props.headless?void 0:{name:`display`,fn:withCtx(()=>[renderSlot(_ctx.$slots,`display`,{},()=>[withDirectives((openBlock(),createElementBlock(`span`,_hoisted_1$323,[createTextVNode(toDisplayString(headerText.value),1)])),[[unref(BngHighlighter_default),highlighter$1.value]])],!0)]),key:`0`}]),1040,[`opened`,`disabled`,`headless`,`focus-target`,`popover-target`,`class`]))}},bngDropdown_default=__plugin_vue_export_helper_default(_sfc_main$371,[[`__scopeId`,`data-v-96e56708`]]),popoverBaseName=`bng-dropdown-content`,_sfc_main$370=Object.assign({inheritAttrs:!1},{__name:`bngDropdownContainer`,props:mergeModels({disabled:Boolean,class:[String,Array,Object],headless:Boolean,focusTarget:Object,popoverTarget:Object},{opened:{},openedModifiers:{}}),emits:mergeModels([`provideFocus`,`show`,`hide`],[`update:opened`]),setup(__props,{expose:__expose,emit:__emit}){let navBlocker=useUINavBlocker(),props=__props,attrs=useAttrs(),binds=computed(()=>({...attrs,tabindex:props.headless?-1:0,"bng-nav-item":props.headless?void 0:``})),opened=useModel(__props,`opened`);function open$1(val){opened.value=val,val?(navBlocker.allowOnly([`focus_u`,`focus_d`,`focus_ud`,`back`,`menu`,`ok`]),emit$1(`show`)):(navBlocker.clear(),emit$1(`hide`),focusTarget.value&&setFocusExternal(focusTarget.value,!0,!1))}let emit$1=__emit,popover=usePopover(),popoverName=uniqueId(popoverBaseName),container=ref(null),content=ref(null),focusTarget=computed(()=>props.focusTarget||container.value),popoverTarget=computed(()=>props.popoverTarget||container.value),placement=ref(`bottom-start`),openedTop=computed(()=>placement.value.startsWith(`top`));return watch(()=>opened.value,value=>{value?(Object.keys(popover.popovers).filter(name=>popover.popovers[name].show&&name!==popoverName&&!popover.popovers[name].element.contains(popover.popovers[popoverName].target)).forEach(name=>popover.hide(name)),!popover.popovers[popoverName].show&&popoverTarget.value&&popover.show(popoverName,popoverTarget.value)):popover.hide(popoverName)}),__expose({opened,open:()=>opened.value=!0,close:()=>opened.value=!1,toggle:()=>opened.value=!opened.value,focusContainer:()=>focusTarget.value&&setFocusExternal(focusTarget.value),popoverName}),(_ctx,_cache)=>(openBlock(),createElementBlock(Fragment,null,[__props.headless?createCommentVNode(``,!0):withDirectives((openBlock(),createElementBlock(`div`,mergeProps({key:0,ref_key:`container`,ref:container},binds.value,{class:[`bng-dropdown`,props.class]}),[createVNode(unref(bngIcon_default),{type:unref(icons).arrowSmallRight,class:normalizeClass({"dropdown-arrow":!0,"dropdown-arrow-top":openedTop.value,opened:opened.value})},null,8,[`type`,`class`]),renderSlot(_ctx.$slots,`display`,{},()=>[_cache[8]||=createTextVNode(`Select`,-1)],!0)],16)),[[unref(BngDisabled_default),__props.disabled],[unref(BngOnUiNav_default),void 0,`ok`,{asMouse:!0,focusRequired:!0}],[unref(BngPopover_default),unref(popoverName),`bottom-start`,{click:!0}]]),createVNode(unref(bngPopoverContent_default),{name:unref(popoverName),onShow:_cache[5]||=$event=>open$1(!0),onHide:_cache[6]||=$event=>open$1(!1),"hide-arrow":``,onPlacementChanged:_cache[7]||=value=>placement.value=value},{default:withCtx(()=>[withDirectives((openBlock(),createElementBlock(`div`,{ref_key:`content`,ref:content,class:normalizeClass([`bng-dropdown-content`,__props.class]),"bng-nav-scroll":``,onClick:_cache[0]||=withModifiers(()=>{},[`stop`]),onMouseover:_cache[1]||=withModifiers(()=>{},[`stop`]),onMouseenter:_cache[2]||=withModifiers(()=>{},[`stop`]),onMousedown:_cache[3]||=withModifiers(()=>{},[`stop`]),onMouseup:_cache[4]||=withModifiers(()=>{},[`stop`])},[opened.value?renderSlot(_ctx.$slots,`default`,{key:0},void 0,!0):createCommentVNode(``,!0)],34)),[[unref(BngAutoScroll_default),void 0,`top`],[unref(BngUiNavLabel_default),`ui.common.close`,`back,menu`],[unref(BngUiNavLabel_default),`ui.mainmenu.navbar.navigate`,`focus_u,focus_d`],[unref(BngUiNavScroll_default)],[unref(BngOnUiNav_default),()=>open$1(!1),`menu`]])]),_:3},8,[`name`])],64))}}),bngDropdownContainer_default=__plugin_vue_export_helper_default(_sfc_main$370,[[`__scopeId`,`data-v-840dc960`]]),icons$2=Object.freeze({"4WD":{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/4WD.svg`},"9dividedby10":{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/9dividedby10.svg`},abandon:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/abandon.svg`},ABSIndicator:{glyph:``,size:24,tags:[`vehicle`,`features`,`warning`,`internals`],fileSvg:`svg/ABSIndicator.svg`},addItemPolygon:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`,`road tools`],fileSvg:`svg/addItemPolygon.svg`},addListItem:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`,`road tools`],fileSvg:`svg/addListItem.svg`},addPolygonVertex:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`,`road tools`],fileSvg:`svg/addPolygonVertex.svg`},adjust:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/adjust.svg`},AIMicrochip:{glyph:``,size:24,tags:[`generic`,`ai`,`microchip`],fileSvg:`svg/AIMicrochip.svg`},AIRace:{glyph:``,size:24,tags:[`poi`],fileSvg:`svg/AIRace.svg`},aperture:{glyph:``,size:24,tags:[`generic`,`camera`,`optical`,`sensor`],fileSvg:`svg/aperture.svg`},arrowLargeDown:{glyph:``,size:24,tags:[`arrow`,`large`,`simple`,`outlined`],fileSvg:`svg/arrowLargeDown.svg`},arrowLargeLeft:{glyph:``,size:24,tags:[`arrow`,`large`,`simple`,`outlined`],fileSvg:`svg/arrowLargeLeft.svg`},arrowLargeRight:{glyph:``,size:24,tags:[`arrow`,`large`,`simple`,`outlined`],fileSvg:`svg/arrowLargeRight.svg`},arrowLargeUp:{glyph:``,size:24,tags:[`arrow`,`large`,`simple`,`outlined`],fileSvg:`svg/arrowLargeUp.svg`},arrowSmallDown:{glyph:``,size:24,tags:[`arrow`,`small`,`simple`,`outlined`],fileSvg:`svg/arrowSmallDown.svg`},arrowSmallLeft:{glyph:``,size:24,tags:[`arrow`,`small`,`simple`,`outlined`],fileSvg:`svg/arrowSmallLeft.svg`},arrowSmallRight:{glyph:``,size:24,tags:[`arrow`,`small`,`simple`,`outlined`],fileSvg:`svg/arrowSmallRight.svg`},arrowSmallUp:{glyph:``,size:24,tags:[`arrow`,`small`,`simple`,`outlined`],fileSvg:`svg/arrowSmallUp.svg`},arrowSolidLeft:{glyph:``,size:24,tags:[`arrow`,`large`,`solid`,`detailed`],fileSvg:`svg/arrowSolidLeft.svg`},arrowSolidRight:{glyph:``,size:24,tags:[`arrow`,`large`,`solid`,`detailed`],fileSvg:`svg/arrowSolidRight.svg`},autobahn:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/autobahn.svg`},AWD:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/AWD.svg`},axleLift:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/axleLift.svg`},axleCenter:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/axleCenter.svg`},axleFront:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/axleFront.svg`},axleRear:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/axleRear.svg`},bSpline:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`,`road tools`],fileSvg:`svg/bSpline.svg`},banknotes:{glyph:``,size:24,tags:[`career`,`currencies`],fileSvg:`svg/banknotes.svg`},barrelKnocker01:{glyph:``,size:24,tags:[`poi`],fileSvg:`svg/barrelKnocker01.svg`},barrelKnocker02:{glyph:``,size:24,tags:[`poi`],fileSvg:`svg/barrelKnocker02.svg`},beamCrashBarrier1:{glyph:``,size:24,tags:[`generic`,`world editor`,`we`,`road tools`],fileSvg:`svg/beamCrashBarrier1.svg`},beamCrashBarrier2:{glyph:``,size:24,tags:[`generic`,`world editor`,`we`,`road tools`],fileSvg:`svg/beamCrashBarrier2.svg`},beamCrashBarrier3:{glyph:``,size:24,tags:[`generic`,`world editor`,`we`,`road tools`],fileSvg:`svg/beamCrashBarrier3.svg`},beamCurrency:{glyph:``,size:24,tags:[`career`,`currencies`],fileSvg:`svg/beamCurrency.svg`},beamNG:{glyph:``,size:24,tags:[`brand`,`beamng`,`generic`],fileSvg:`svg/beamNG.svg`},beamXPFull:{glyph:``,size:24,tags:[`career`,`currencies`],fileSvg:`svg/beamXPFull.svg`},beamXPLo:{glyph:``,size:24,tags:[`career`,`currencies`],fileSvg:`svg/beamXPLo.svg`},bezierPath1:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`,`road tools`],fileSvg:`svg/bezierPath1.svg`},bezierPath2:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`,`road tools`],fileSvg:`svg/bezierPath2.svg`},bicycle1:{glyph:``,size:24,tags:[`generic`,`world editor`,`we`,`road tools`],fileSvg:`svg/bicycle1.svg`},bicycle2:{glyph:``,size:24,tags:[`generic`,`world editor`,`we`,`road tools`],fileSvg:`svg/bicycle2.svg`},BNGFolder:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/BNGFolder.svg`},BNGMicrochip:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/BNGMicrochip.svg`},bollard:{glyph:``,size:24,tags:[`generic`,`world editor`,`we`,`road tools`],fileSvg:`svg/bollard.svg`},bookmark:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/bookmark.svg`},booleanIntersect:{glyph:``,size:24,tags:[`decals`,`generic`],fileSvg:`svg/booleanIntersect.svg`},boxDropOff01:{glyph:``,size:24,tags:[`poi`,`delivery`],fileSvg:`svg/boxDropOff01.svg`},boxDropOff02:{glyph:``,size:24,tags:[`poi`,`delivery`],fileSvg:`svg/boxDropOff02.svg`},boxDropOff03:{glyph:``,size:24,tags:[`poi`,`delivery`],fileSvg:`svg/boxDropOff03.svg`},boxPickUp01:{glyph:``,size:24,tags:[`poi`,`delivery`],fileSvg:`svg/boxPickUp01.svg`},boxPickUp02:{glyph:``,size:24,tags:[`poi`,`delivery`],fileSvg:`svg/boxPickUp02.svg`},boxPickUp03:{glyph:``,size:24,tags:[`poi`,`delivery`],fileSvg:`svg/boxPickUp03.svg`},boxPickUpDropOff01:{glyph:``,size:24,tags:[`poi`,`delivery`],fileSvg:`svg/boxPickUpDropOff01.svg`},boxPickUpDropOff02:{glyph:``,size:24,tags:[`poi`,`delivery`],fileSvg:`svg/boxPickUpDropOff02.svg`},boxTruck:{glyph:``,size:24,tags:[`cargo`,`delivery`,`vehicle`],fileSvg:`svg/boxTruck.svg`},broom:{glyph:``,size:24,tags:[`generic`,`sound`],fileSvg:`svg/broom.svg`},bucketAdd:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/bucketAdd.svg`},bucketSubtract:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/bucketSubtract.svg`},bug:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/bug.svg`},bulldozer:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`,`road tools`],fileSvg:`svg/bulldozer.svg`},bus:{glyph:``,size:24,tags:[`poi`,`vehicle`],fileSvg:`svg/bus.svg`},camera3Fourth1:{glyph:``,size:24,tags:[`camera`],fileSvg:`svg/camera3Fourth1.svg`},cameraBack1:{glyph:``,size:24,tags:[`camera`],fileSvg:`svg/cameraBack1.svg`},cameraFocusOnPath:{glyph:``,size:24,tags:[`camera`],fileSvg:`svg/cameraFocusOnPath.svg`},cameraFocusOnVehicle1:{glyph:``,size:24,tags:[`camera`],fileSvg:`svg/cameraFocusOnVehicle1.svg`},cameraFocusOnVehicle2:{glyph:``,size:24,tags:[`camera`,`decals`],fileSvg:`svg/cameraFocusOnVehicle2.svg`},cameraFocusTopDown:{glyph:``,size:24,tags:[`camera`],fileSvg:`svg/cameraFocusTopDown.svg`},cameraFront1:{glyph:``,size:24,tags:[`camera`],fileSvg:`svg/cameraFront1.svg`},cameraSideLeft:{glyph:``,size:24,tags:[`camera`],fileSvg:`svg/cameraSideLeft.svg`},cameraSideLeft2:{glyph:``,size:24,tags:[`camera`],fileSvg:`svg/cameraSideLeft2.svg`},cameraSideRight:{glyph:``,size:24,tags:[`camera`],fileSvg:`svg/cameraSideRight.svg`},cameraSideRight2:{glyph:``,size:24,tags:[`camera`],fileSvg:`svg/cameraSideRight2.svg`},cameraTop1:{glyph:``,size:24,tags:[`camera`],fileSvg:`svg/cameraTop1.svg`},cannon:{glyph:``,size:24,tags:[`poi`],fileSvg:`svg/cannon.svg`},carChase01:{glyph:``,size:24,tags:[`generic`,`police`,`vehicle`],fileSvg:`svg/carChase01.svg`},carCoin:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/carCoin.svg`},carCoins:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/carCoins.svg`},carCrash:{glyph:``,size:24,tags:[`generic`,`vehicle`],fileSvg:`svg/carCrash.svg`},carDealer:{glyph:``,size:24,tags:[`career`,`garage`,`features`],fileSvg:`svg/carDealer.svg`},carOffroadOutlineRear:{glyph:``,size:24,tags:[`generic`,`vehicle`],fileSvg:`svg/carOffroadOutlineRear.svg`},carOffroadOutlineSide:{glyph:``,size:24,tags:[`generic`,`vehicle`],fileSvg:`svg/carOffroadOutlineSide.svg`},carOffroadRear:{glyph:``,size:24,tags:[`generic`,`vehicle`],fileSvg:`svg/carOffroadRear.svg`},carOffroadSide:{glyph:``,size:24,tags:[`generic`,`vehicle`],fileSvg:`svg/carOffroadSide.svg`},carSensors:{glyph:``,size:24,tags:[`generic`,`vehicle`,`sensors`],fileSvg:`svg/carSensors.svg`},carStarred:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/carStarred.svg`},carToWheels:{glyph:``,size:24,tags:[`generic`,`vehicle`],fileSvg:`svg/carToWheels.svg`},carUp:{glyph:``,size:24,tags:[`generic`,`vehicle`],fileSvg:`svg/carUp.svg`},carWithLidar:{glyph:``,size:24,tags:[`generic`,`vehicle`,`tech`,`sensors`],fileSvg:`svg/carWithLidar.svg`},car:{glyph:``,size:24,tags:[`generic`,`vehicle`],fileSvg:`svg/car.svg`},cardboardBox:{glyph:``,size:24,tags:[`generic`,`delivery`],fileSvg:`svg/cardboardBox.svg`},carsChase02:{glyph:``,size:24,tags:[`generic`,`police`,`vehicle`],fileSvg:`svg/carsChase02.svg`},cars:{glyph:``,size:24,tags:[`generic`,`vehicle`],fileSvg:`svg/cars.svg`},catalog01:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/catalog01.svg`},catalog02:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/catalog02.svg`},catalog03:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/catalog03.svg`},centrifugalClutchLocked03:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/centrifugalClutchLocked03.svg`},centrifugalClutchUnlocked03:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/centrifugalClutchUnlocked03.svg`},charge:{glyph:``,size:24,tags:[`fuel`,`electricity`,`ev`],fileSvg:`svg/charge.svg`},charging:{glyph:``,size:24,tags:[`fuel`,`electricity`,`ev`],fileSvg:`svg/charging.svg`},chartBars:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/chartBars.svg`},checkboxOff:{glyph:``,size:24,tags:[`checkbox`,`selection`,`box`],fileSvg:`svg/checkboxOff.svg`},checkboxOn:{glyph:``,size:24,tags:[`checkbox`,`selection`,`box`],fileSvg:`svg/checkboxOn.svg`},checkmarkBold:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/checkmarkBold.svg`},checkmark:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/checkmark.svg`},circuitMicrochip:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/circuitMicrochip.svg`},circuit:{glyph:``,size:24,tags:[`poi`],fileSvg:`svg/circuit.svg`},clapperboard:{glyph:``,size:24,tags:[`generic`,`movie`,`scenery`],fileSvg:`svg/clapperboard.svg`},code:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/code.svg`},cogDamaged:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/cogDamaged.svg`},cogsDamaged:{glyph:``,size:24,tags:[`vehicle`,`features`,`powertrain`,`drivetrain`],fileSvg:`svg/cogsDamaged.svg`},cogs:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/cogs.svg`},concreteRoadBlock:{glyph:``,size:24,tags:[`generic`,`world editor`,`we`,`road tools`],fileSvg:`svg/concreteRoadBlock.svg`},coolantTemp:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/coolantTemp.svg`},copy:{glyph:``,size:24,tags:[`decals`,`generic`],fileSvg:`svg/copy.svg`},crossroads1:{glyph:``,size:24,tags:[`generic`,`world editor`,`we`,`road tools`],fileSvg:`svg/crossroads1.svg`},crossroads2:{glyph:``,size:24,tags:[`generic`,`world editor`,`we`,`road tools`],fileSvg:`svg/crossroads2.svg`},cruiseDisable:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/cruiseDisable.svg`},cruiseEnable:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/cruiseEnable.svg`},cup:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/cup.svg`},dataExchange:{glyph:``,size:24,tags:[`generic`,`data`,`signal`],fileSvg:`svg/dataExchange.svg`},day:{glyph:``,size:24,tags:[`environment`],fileSvg:`svg/day.svg`},DCBattery:{glyph:``,size:24,tags:[`vehicle`,`features`,`warning`,`internals`],fileSvg:`svg/DCBattery.svg`},decalRoad:{glyph:``,size:24,tags:[`generic`,`world editor`,`we`,`road tools`],fileSvg:`svg/decalRoad.svg`},decal:{glyph:``,size:24,tags:[`decals`,`generic`],fileSvg:`svg/decal.svg`},deform:{glyph:``,size:24,tags:[`decals`,`generic`],fileSvg:`svg/deform.svg`},deliveryTruckArrows:{glyph:``,size:24,tags:[`poi`,`delivery`,`vehicle`],fileSvg:`svg/deliveryTruckArrows.svg`},deliveryTruck:{glyph:``,size:24,tags:[`poi`,`delivery`,`vehicle`],fileSvg:`svg/deliveryTruck.svg`},differentialFrontDefault:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/differentialFrontDefault.svg`},differentialFrontLocked:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/differentialFrontLocked.svg`},differentialMiddleDefault:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/differentialMiddleDefault.svg`},differentialMiddleLocked:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/differentialMiddleLocked.svg`},differentialRearDefault:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/differentialRearDefault.svg`},differentialRearLocked:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/differentialRearLocked.svg`},doorHandle:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/doorHandle.svg`},doorIn:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/doorIn.svg`},drag01:{glyph:``,size:24,tags:[`poi`],fileSvg:`svg/drag01.svg`},drag02:{glyph:``,size:24,tags:[`poi`],fileSvg:`svg/drag02.svg`},drift01:{glyph:``,size:24,tags:[`poi`,`vehicle`],fileSvg:`svg/drift01.svg`},drift02:{glyph:``,size:24,tags:[`poi`,`vehicle`],fileSvg:`svg/drift02.svg`},drivetrainGeneric:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/drivetrainGeneric.svg`},drivetrainSpecial:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/drivetrainSpecial.svg`},editCheckmark:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/editCheckmark.svg`},edit:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/edit.svg`},engine:{glyph:``,size:24,tags:[`vehicle`,`part`,`features`],fileSvg:`svg/engine.svg`},ESCOff:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/ESCOff.svg`},ESCOn:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/ESCOn.svg`},ESC:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/ESC.svg`},evade:{glyph:``,size:24,tags:[`poi`,`mission`,`police`],fileSvg:`svg/evade.svg`},exhaustValve:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/exhaustValve.svg`},exit:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/exit.svg`},export:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/export.svg`},eyeOutlineClosed:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/eyeOutlineClosed.svg`},eyeOutlineOpened:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/eyeOutlineOpened.svg`},eyeSolidClosed:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/eyeSolidClosed.svg`},eyeSolidOpened:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/eyeSolidOpened.svg`},eyeWaves:{glyph:``,size:24,tags:[`generic`,`data`,`signal`,`sensor`],fileSvg:`svg/eyeWaves.svg`},facility02:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/facility02.svg`},fastBackward:{glyph:``,size:24,tags:[`playback`],fileSvg:`svg/fastBackward.svg`},fastForward:{glyph:``,size:24,tags:[`playback`],fileSvg:`svg/fastForward.svg`},fastTravel:{glyph:``,size:24,tags:[`poi`],fileSvg:`svg/fastTravel.svg`},filter:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/filter.svg`},flagNew:{glyph:``,size:24,tags:[`poi`],fileSvg:`svg/flagNew.svg`},flag:{glyph:``,size:24,tags:[`poi`],fileSvg:`svg/flag.svg`},flatBulbBeam:{glyph:``,size:24,tags:[`generic`,`world editor`,`we`,`sensor`],fileSvg:`svg/flatBulbBeam.svg`},flatbedTruck:{glyph:``,size:24,tags:[`cargo`,`delivery`,`vehicle`,`truck`],fileSvg:`svg/flatbedTruck.svg`},floppyDisk:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/floppyDisk.svg`},fogLight:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/fogLight.svg`},folder:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/folder.svg`},forklift:{glyph:``,size:24,tags:[`delivery`,`stencil`,`cargo`,`vehicle`],fileSvg:`svg/forklift.svg`},FPS:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/FPS.svg`},fragile:{glyph:``,size:24,tags:[`delivery`,`stencil`,`cargo`],fileSvg:`svg/fragile.svg`},frontAxleMidpoint:{glyph:``,size:24,tags:[`generic`,`world editor`,`we`,`placement`,`sensor`],fileSvg:`svg/frontAxleMidpoint.svg`},frontBumperMidpoint:{glyph:``,size:24,tags:[`generic`,`world editor`,`we`,`placement`,`sensor`],fileSvg:`svg/frontBumperMidpoint.svg`},fuelPumpFilling:{glyph:``,size:24,tags:[`fuel`],fileSvg:`svg/fuelPumpFilling.svg`},fuelPump:{glyph:``,size:24,tags:[`fuel`],fileSvg:`svg/fuelPump.svg`},FWD:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/FWD.svg`},gamepadOld:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/gamepadOld.svg`},gamepad:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/gamepad.svg`},garage01:{glyph:``,size:24,tags:[`career`,`garage`,`features`],fileSvg:`svg/garage01.svg`},garage02:{glyph:``,size:24,tags:[`career`,`garage`,`features`],fileSvg:`svg/garage02.svg`},garage03:{glyph:``,size:24,tags:[`career`,`garage`,`features`],fileSvg:`svg/garage03.svg`},gaugeEmpty:{glyph:``,size:24,tags:[`poi`],fileSvg:`svg/gaugeEmpty.svg`},globe:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/globe.svg`},GPSMark:{glyph:``,size:24,tags:[`generic`,`gps`,`position`,`map`,`sensor`],fileSvg:`svg/GPSMark.svg`},GPSSolid:{glyph:``,size:24,tags:[`generic`,`gps`,`position`,`map`,`sensor`],fileSvg:`svg/GPSSolid.svg`},group:{glyph:``,size:24,tags:[`decals`,`generic`],fileSvg:`svg/group.svg`},gyroscopeMicrochip:{glyph:``,size:24,tags:[`generic`,`data`,`signal`,`sensor`],fileSvg:`svg/gyroscopeMicrochip.svg`},gyroscope:{glyph:``,size:24,tags:[`generic`,`data`,`signal`,`sensor`],fileSvg:`svg/gyroscope.svg`},hazardLights:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/hazardLights.svg`},helmets:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/helmets.svg`},help:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/help.svg`},highBeam:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/highBeam.svg`},HUD:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/HUD.svg`},hydroPump1:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/hydroPump1.svg`},hydroPump2:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/hydroPump2.svg`},hydroPump3:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/hydroPump3.svg`},hydroPump4:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/hydroPump4.svg`},hydroPump5:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/hydroPump5.svg`},hydroPump6:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/hydroPump6.svg`},hydroPump7:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/hydroPump7.svg`},hypermiling:{glyph:``,size:24,tags:[`poi`],fileSvg:`svg/hypermiling.svg`},import:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/import.svg`},infinity:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/infinity.svg`},info:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/info.svg`},jointLocked:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/jointLocked.svg`},jointUnlocked:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/jointUnlocked.svg`},jump:{glyph:``,size:24,tags:[`poi`],fileSvg:`svg/jump.svg`},keyboard:{glyph:``,size:24,tags:[`keyboard`,`input`],fileSvg:`svg/keyboard.svg`},keys1:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/keys1.svg`},keys2:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/keys2.svg`},lampPost1:{glyph:``,size:24,tags:[`generic`,`world editor`,`we`,`road tools`],fileSvg:`svg/lampPost1.svg`},lampPost2:{glyph:``,size:24,tags:[`generic`,`world editor`,`we`,`road tools`],fileSvg:`svg/lampPost2.svg`},lampPost3:{glyph:``,size:24,tags:[`generic`,`world editor`,`we`,`road tools`],fileSvg:`svg/lampPost3.svg`},laneProperties:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`,`road tools`],fileSvg:`svg/laneProperties.svg`},language:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/language.svg`},laptop:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/laptop.svg`},lidarPatternFullArcHighFreq:{glyph:``,size:24,tags:[`generic`,`world editor`,`we`,`sensor`],fileSvg:`svg/lidarPatternFullArcHighFreq.svg`},lidarPatternFullArcMidFreq:{glyph:``,size:24,tags:[`generic`,`world editor`,`we`,`sensor`],fileSvg:`svg/lidarPatternFullArcMidFreq.svg`},lidarPatternNarrowArc:{glyph:``,size:24,tags:[`generic`,`world editor`,`we`,`sensor`],fileSvg:`svg/lidarPatternNarrowArc.svg`},lidar:{glyph:``,size:24,tags:[`generic`,`data`,`signal`,`sensor`],fileSvg:`svg/lidar.svg`},lightGarageG11:{glyph:``,size:24,tags:[`career`,`garage`,`lights`],fileSvg:`svg/lightGarageG11.svg`},lightGarageG12:{glyph:``,size:24,tags:[`career`,`garage`,`lights`],fileSvg:`svg/lightGarageG12.svg`},lightGarageG13:{glyph:``,size:24,tags:[`career`,`garage`,`lights`],fileSvg:`svg/lightGarageG13.svg`},lightGarageG14:{glyph:``,size:24,tags:[`career`,`garage`,`lights`],fileSvg:`svg/lightGarageG14.svg`},lightGarageG21:{glyph:``,size:24,tags:[`career`,`garage`,`lights`],fileSvg:`svg/lightGarageG21.svg`},lightGarageG22:{glyph:``,size:24,tags:[`career`,`garage`,`lights`],fileSvg:`svg/lightGarageG22.svg`},lightGarageG23:{glyph:``,size:24,tags:[`career`,`garage`,`lights`],fileSvg:`svg/lightGarageG23.svg`},lightGarageG24:{glyph:``,size:24,tags:[`career`,`garage`,`lights`],fileSvg:`svg/lightGarageG24.svg`},lightGarageG31:{glyph:``,size:24,tags:[`career`,`garage`,`lights`],fileSvg:`svg/lightGarageG31.svg`},lightGarageG32:{glyph:``,size:24,tags:[`career`,`garage`,`lights`],fileSvg:`svg/lightGarageG32.svg`},lightGarageG33:{glyph:``,size:24,tags:[`career`,`garage`,`lights`],fileSvg:`svg/lightGarageG33.svg`},lightGarageG34:{glyph:``,size:24,tags:[`career`,`garage`,`lights`],fileSvg:`svg/lightGarageG34.svg`},lightrunner:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/lightrunner.svg`},limiterEnable:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/limiterEnable.svg`},lineToTerrain:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`,`road tools`],fileSvg:`svg/lineToTerrain.svg`},link2:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/link2.svg`},link:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/link.svg`},listBig:{glyph:``,size:24,tags:[`generic`,`catalog`,`selector`,`view`],fileSvg:`svg/listBig.svg`},listIndented:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/listIndented.svg`},listSmall:{glyph:``,size:24,tags:[`generic`,`catalog`,`selector`,`view`],fileSvg:`svg/listSmall.svg`},location1:{glyph:``,size:24,tags:[`generic`,`gps`,`position`,`map`,`sensor`],fileSvg:`svg/location1.svg`},location2:{glyph:``,size:24,tags:[`generic`,`gps`,`position`,`map`,`sensor`],fileSvg:`svg/location2.svg`},lockClosed:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/lockClosed.svg`},lockOpened:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/lockOpened.svg`},longRangeBeam1:{glyph:``,size:24,tags:[`generic`,`world editor`,`we`,`sensor`],fileSvg:`svg/longRangeBeam1.svg`},longRangeBeam2:{glyph:``,size:24,tags:[`generic`,`world editor`,`we`,`sensor`],fileSvg:`svg/longRangeBeam2.svg`},lowBeam:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/lowBeam.svg`},magnetOnSurface:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`,`road tools`],fileSvg:`svg/magnetOnSurface.svg`},mapWithEmitter:{glyph:``,size:24,tags:[`generic`,`tech`,`sensors`],fileSvg:`svg/mapWithEmitter.svg`},mapPoint:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/mapPoint.svg`},material:{glyph:``,size:24,tags:[`decals`,`generic`],fileSvg:`svg/material.svg`},mathDivide:{glyph:``,size:24,tags:[`generic`,`math`,`operands`,`small`],fileSvg:`svg/mathDivide.svg`},mathGreaterOrEqualThan:{glyph:``,size:24,tags:[`generic`,`math`,`operands`,`small`],fileSvg:`svg/mathGreaterOrEqualThan.svg`},mathGreaterThan:{glyph:``,size:24,tags:[`generic`,`math`,`operands`,`small`],fileSvg:`svg/mathGreaterThan.svg`},mathLessOrEqualThan:{glyph:``,size:24,tags:[`generic`,`math`,`operands`,`small`],fileSvg:`svg/mathLessOrEqualThan.svg`},mathLessThan:{glyph:``,size:24,tags:[`generic`,`math`,`operands`,`small`],fileSvg:`svg/mathLessThan.svg`},mathMinus:{glyph:``,size:24,tags:[`generic`,`math`,`operands`,`small`],fileSvg:`svg/mathMinus.svg`},mathMultiply:{glyph:``,size:24,tags:[`generic`,`math`,`operands`,`small`],fileSvg:`svg/mathMultiply.svg`},mathPlus:{glyph:``,size:24,tags:[`generic`,`math`,`operands`,`small`],fileSvg:`svg/mathPlus.svg`},medal:{glyph:``,size:24,tags:[`generic`,`reward`,`achievment`],fileSvg:`svg/medal.svg`},mesh4Cells:{glyph:``,size:24,tags:[`tech`,`mesh`,`beams`,`nodes`,`surface`],fileSvg:`svg/mesh4Cells.svg`},mesh9Cells:{glyph:``,size:24,tags:[`tech`,`mesh`,`beams`,`nodes`,`surface`],fileSvg:`svg/mesh9Cells.svg`},meshFence:{glyph:``,size:24,tags:[`generic`,`world editor`,`we`,`road tools`],fileSvg:`svg/meshFence.svg`},meshRoad:{glyph:``,size:24,tags:[`generic`,`world editor`,`we`,`road tools`],fileSvg:`svg/meshRoad.svg`},midRangeBeam1:{glyph:``,size:24,tags:[`generic`,`world editor`,`we`,`sensor`],fileSvg:`svg/midRangeBeam1.svg`},midRangeBeam2:{glyph:``,size:24,tags:[`generic`,`world editor`,`we`,`sensor`],fileSvg:`svg/midRangeBeam2.svg`},minusRes:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/minusRes.svg`},minus:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/minus.svg`},mirrorInteriorMiddle:{glyph:``,size:24,tags:[`vehicle`,`features`,`mirror`,`rearview`],fileSvg:`svg/mirrorInteriorMiddle.svg`},mirrorLeftBigBottomWideAngle:{glyph:``,size:24,tags:[`vehicle`,`features`,`mirror`,`rearview`],fileSvg:`svg/mirrorLeftBigBottomWideAngle.svg`},mirrorLeftBigTop:{glyph:``,size:24,tags:[`vehicle`,`features`,`mirror`,`rearview`],fileSvg:`svg/mirrorLeftBigTop.svg`},mirrorLeftBig:{glyph:``,size:24,tags:[`vehicle`,`features`,`mirror`,`rearview`],fileSvg:`svg/mirrorLeftBig.svg`},mirrorLeftBonnet:{glyph:``,size:24,tags:[`vehicle`,`features`,`mirror`,`rearview`],fileSvg:`svg/mirrorLeftBonnet.svg`},mirrorLeftDefault:{glyph:``,size:24,tags:[`vehicle`,`features`,`mirror`,`rearview`],fileSvg:`svg/mirrorLeftDefault.svg`},mirrorRightBigBottomWideAngle:{glyph:``,size:24,tags:[`vehicle`,`features`,`mirror`,`rearview`],fileSvg:`svg/mirrorRightBigBottomWideAngle.svg`},mirrorRightBigTop:{glyph:``,size:24,tags:[`vehicle`,`features`,`mirror`,`rearview`],fileSvg:`svg/mirrorRightBigTop.svg`},mirrorRightBig:{glyph:``,size:24,tags:[`vehicle`,`features`,`mirror`,`rearview`],fileSvg:`svg/mirrorRightBig.svg`},mirrorRightBonnet:{glyph:``,size:24,tags:[`vehicle`,`features`,`mirror`,`rearview`],fileSvg:`svg/mirrorRightBonnet.svg`},mirrorRightDefault:{glyph:``,size:24,tags:[`vehicle`,`features`,`mirror`,`rearview`],fileSvg:`svg/mirrorRightDefault.svg`},mirrorRoundWideAngle:{glyph:``,size:24,tags:[`vehicle`,`features`,`mirror`,`rearview`],fileSvg:`svg/mirrorRoundWideAngle.svg`},mirrorTopWideAngle:{glyph:``,size:24,tags:[`vehicle`,`features`,`mirror`,`rearview`],fileSvg:`svg/mirrorTopWideAngle.svg`},missionCheckboxCross:{glyph:``,size:24,tags:[`checkbox`,`selection`,`box`],fileSvg:`svg/missionCheckboxCross.svg`},mouseLMB:{glyph:``,size:24,tags:[`mouse`,`input`],fileSvg:`svg/mouseLMB.svg`},mouseMMB:{glyph:``,size:24,tags:[`mouse`,`input`],fileSvg:`svg/mouseMMB.svg`},mouseRMB:{glyph:``,size:24,tags:[`mouse`,`input`],fileSvg:`svg/mouseRMB.svg`},mouseWheel:{glyph:``,size:24,tags:[`mouse`,`input`],fileSvg:`svg/mouseWheel.svg`},mouseXAxis:{glyph:``,size:24,tags:[`mouse`,`input`],fileSvg:`svg/mouseXAxis.svg`},mouseXYAxis:{glyph:``,size:24,tags:[`mouse`,`input`],fileSvg:`svg/mouseXYAxis.svg`},mouseYAxis:{glyph:``,size:24,tags:[`mouse`,`input`],fileSvg:`svg/mouseYAxis.svg`},mouse:{glyph:``,size:24,tags:[`mouse`,`input`],fileSvg:`svg/mouse.svg`},move02:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/move02.svg`},move:{glyph:``,size:24,tags:[`decals`,`generic`],fileSvg:`svg/move.svg`},movieCamera:{glyph:``,size:24,tags:[`camera`],fileSvg:`svg/movieCamera.svg`},music:{glyph:``,size:24,tags:[`playback`],fileSvg:`svg/music.svg`},N2OButton:{glyph:``,size:24,tags:[`fuel`],fileSvg:`svg/N2OButton.svg`},N2OHoriz:{glyph:``,size:24,tags:[`fuel`],fileSvg:`svg/N2OHoriz.svg`},N2OVert:{glyph:``,size:24,tags:[`fuel`],fileSvg:`svg/N2OVert.svg`},nextTrack:{glyph:``,size:24,tags:[`playback`],fileSvg:`svg/nextTrack.svg`},night:{glyph:``,size:24,tags:[`environment`],fileSvg:`svg/night.svg`},noNameControllerButton:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/noNameControllerButton.svg`},nodeAddFirst01:{glyph:``,size:24,tags:[`generic`,`path`,`node`],fileSvg:`svg/nodeAddFirst01.svg`},nodeAddFirst02:{glyph:``,size:24,tags:[`generic`,`path`,`node`],fileSvg:`svg/nodeAddFirst02.svg`},nodeAddLast02:{glyph:``,size:24,tags:[`generic`,`path`,`node`],fileSvg:`svg/nodeAddLast02.svg`},nodeAddMiddle01:{glyph:``,size:24,tags:[`generic`,`path`,`node`],fileSvg:`svg/nodeAddMiddle01.svg`},nodeAddMiddle02:{glyph:``,size:24,tags:[`generic`,`path`,`node`],fileSvg:`svg/nodeAddMiddle02.svg`},nodeAdd:{glyph:``,size:24,tags:[`generic`,`path`,`node`],fileSvg:`svg/nodeAdd.svg`},nodeLast01:{glyph:``,size:24,tags:[`generic`,`path`,`node`],fileSvg:`svg/nodeLast01.svg`},nodeRemove:{glyph:``,size:24,tags:[`generic`,`path`,`node`],fileSvg:`svg/nodeRemove.svg`},odometerKM:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/odometerKM.svg`},odometerMI:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/odometerMI.svg`},odometer:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/odometer.svg`},oilPressureIndicator:{glyph:``,size:24,tags:[`vehicle`,`features`,`warning`,`internals`],fileSvg:`svg/oilPressureIndicator.svg`},order:{glyph:``,size:24,tags:[`decals`,`generic`],fileSvg:`svg/order.svg`},organization:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/organization.svg`},palmCrossed:{glyph:``,size:24,tags:[`touch`,`input`],fileSvg:`svg/palmCrossed.svg`},paperKnife:{glyph:``,size:24,tags:[`decals`,`generic`],fileSvg:`svg/paperKnife.svg`},parkingIndicator:{glyph:``,size:24,tags:[`vehicle`,`features`,`warning`,`internals`],fileSvg:`svg/parkingIndicator.svg`},parking:{glyph:``,size:24,tags:[`poi`],fileSvg:`svg/parking.svg`},pathArc:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`,`road tools`],fileSvg:`svg/pathArc.svg`},pathAroundObstacle:{glyph:``,size:24,tags:[`camera`],fileSvg:`svg/pathAroundObstacle.svg`},pathLine:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`,`road tools`],fileSvg:`svg/pathLine.svg`},pathSpiral:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`,`road tools`],fileSvg:`svg/pathSpiral.svg`},pauseRound:{glyph:``,size:24,tags:[`playback`],fileSvg:`svg/pauseRound.svg`},pause:{glyph:``,size:24,tags:[`playback`],fileSvg:`svg/pause.svg`},personSolid:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/personSolid.svg`},person:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/person.svg`},photo:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/photo.svg`},placeholder:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/placeholder.svg`},playRound:{glyph:``,size:24,tags:[`playback`],fileSvg:`svg/playRound.svg`},play:{glyph:``,size:24,tags:[`playback`],fileSvg:`svg/play.svg`},playlist:{glyph:``,size:24,tags:[`playback`],fileSvg:`svg/playlist.svg`},plusGarage1:{glyph:``,size:24,tags:[`career`,`garage`,`features`],fileSvg:`svg/plusGarage1.svg`},plusGarage2:{glyph:``,size:24,tags:[`career`,`garage`,`features`],fileSvg:`svg/plusGarage2.svg`},plusGarage3:{glyph:``,size:24,tags:[`career`,`garage`,`features`],fileSvg:`svg/plusGarage3.svg`},plusGarage4:{glyph:``,size:24,tags:[`career`,`garage`,`features`],fileSvg:`svg/plusGarage4.svg`},plusSet:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/plusSet.svg`},plus:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/plus.svg`},positionLights:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/positionLights.svg`},powerGauge01:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/powerGauge01.svg`},powerGauge02:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/powerGauge02.svg`},powerGauge03:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/powerGauge03.svg`},powerGauge04:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/powerGauge04.svg`},powerGauge05:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/powerGauge05.svg`},powerOnOff:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/powerOnOff.svg`},prevTrack:{glyph:``,size:24,tags:[`playback`],fileSvg:`svg/prevTrack.svg`},publisher:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/publisher.svg`},puzzleModule:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/puzzleModule.svg`},raceFlag:{glyph:``,size:24,tags:[`poi`],fileSvg:`svg/raceFlag.svg`},radarIdeal:{glyph:``,size:24,tags:[`generic`,`data`,`signal`,`sensor`],fileSvg:`svg/radarIdeal.svg`},radarRoundIdeal:{glyph:``,size:24,tags:[`generic`,`data`,`signal`,`sensor`],fileSvg:`svg/radarRoundIdeal.svg`},radarRound:{glyph:``,size:24,tags:[`generic`,`data`,`signal`,`sensor`],fileSvg:`svg/radarRound.svg`},radar:{glyph:``,size:24,tags:[`generic`,`data`,`signal`,`sensor`],fileSvg:`svg/radar.svg`},rangeboxHi2:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/rangeboxHi2.svg`},rangeboxHi4:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/rangeboxHi4.svg`},rangeboxHiA:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/rangeboxHiA.svg`},rangeboxLo2:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/rangeboxLo2.svg`},rangeboxLo4:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/rangeboxLo4.svg`},rangeboxLoA:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/rangeboxLoA.svg`},rearAxleMidpoint:{glyph:``,size:24,tags:[`generic`,`world editor`,`we`,`placement`,`sensor`],fileSvg:`svg/rearAxleMidpoint.svg`},rearBumperMidpoint:{glyph:``,size:24,tags:[`generic`,`world editor`,`we`,`placement`,`sensor`],fileSvg:`svg/rearBumperMidpoint.svg`},reconfigure:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/reconfigure.svg`},redo:{glyph:``,size:24,tags:[`decals`,`generic`],fileSvg:`svg/redo.svg`},reflectNot:{glyph:``,size:24,tags:[`decals`,`generic`],fileSvg:`svg/reflectNot.svg`},reflect:{glyph:``,size:24,tags:[`decals`,`generic`],fileSvg:`svg/reflect.svg`},rename:{glyph:``,size:24,tags:[`decals`,`generic`],fileSvg:`svg/rename.svg`},replay:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/replay.svg`},restart:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/restart.svg`},roadDividerLinesDecal:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`,`road tools`],fileSvg:`svg/roadDividerLinesDecal.svg`},roadEdgeLineDecal:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`,`road tools`],fileSvg:`svg/roadEdgeLineDecal.svg`},roadEndLineDecal:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`,`road tools`],fileSvg:`svg/roadEndLineDecal.svg`},roadFace:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`,`road tools`],fileSvg:`svg/roadFace.svg`},roadInfo:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/roadInfo.svg`},roadMarkingOutline:{glyph:``,size:24,tags:[`generic`,`world editor`,`we`,`outlined`],fileSvg:`svg/roadMarkingOutline.svg`},roadMarkingSolid:{glyph:``,size:24,tags:[`generic`,`world editor`,`we`,`road tools`],fileSvg:`svg/roadMarkingSolid.svg`},roadOutline:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`,`road tools`],fileSvg:`svg/roadOutline.svg`},roadRefPathDecal:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`,`road tools`],fileSvg:`svg/roadRefPathDecal.svg`},roadRefPath:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`,`road tools`],fileSvg:`svg/roadRefPath.svg`},roadStartLineDecal:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`,`road tools`],fileSvg:`svg/roadStartLineDecal.svg`},road:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/road.svg`},rockCrawling01:{glyph:``,size:24,tags:[`poi`,`vehicle`],fileSvg:`svg/rockCrawling01.svg`},rockCrawling02:{glyph:``,size:24,tags:[`poi`],fileSvg:`svg/rockCrawling02.svg`},routeAdd:{glyph:``,size:24,tags:[`route`,`traffic`],fileSvg:`svg/routeAdd.svg`},routeComplex:{glyph:``,size:24,tags:[`route`,`traffic`],fileSvg:`svg/routeComplex.svg`},routeSimple:{glyph:``,size:24,tags:[`route`,`traffic`],fileSvg:`svg/routeSimple.svg`},runScript:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/runScript.svg`},RWD:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/RWD.svg`},saveAs1:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/saveAs1.svg`},scan:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/scan.svg`},search:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/search.svg`},semiTrailer:{glyph:``,size:24,tags:[`cargo`,`delivery`,`trailer`,`vehicle`],fileSvg:`svg/semiTrailer.svg`},semiTruckCabover:{glyph:``,size:24,tags:[`cargo`,`delivery`,`vehicle`,`truck`],fileSvg:`svg/semiTruckCabover.svg`},semiTruckUS:{glyph:``,size:24,tags:[`cargo`,`delivery`,`vehicle`,`truck`],fileSvg:`svg/semiTruckUS.svg`},semiTruck:{glyph:``,size:24,tags:[`cargo`,`delivery`,`truck`,`trailer`,`vehicle`],fileSvg:`svg/semiTruck.svg`},shortRangeBeam1:{glyph:``,size:24,tags:[`generic`,`world editor`,`we`,`sensor`],fileSvg:`svg/shortRangeBeam1.svg`},shortRangeBeam2:{glyph:``,size:24,tags:[`generic`,`world editor`,`we`,`sensor`],fileSvg:`svg/shortRangeBeam2.svg`},signal01a:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/signal01a.svg`},signal02a:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/signal02a.svg`},signal03a:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/signal03a.svg`},signal04a:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/signal04a.svg`},signal05a:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/signal05a.svg`},slashLeft:{glyph:``,size:24,tags:[`generic`,`math`,`operands`,`small`],fileSvg:`svg/slashLeft.svg`},slashRight:{glyph:``,size:24,tags:[`generic`,`math`,`operands`,`small`],fileSvg:`svg/slashRight.svg`},smallTrailer:{glyph:``,size:24,tags:[`cargo`,`delivery`,`trailer`,`vehicle`],fileSvg:`svg/smallTrailer.svg`},smartphone1:{glyph:``,size:24,tags:[`touch`,`input`],fileSvg:`svg/smartphone1.svg`},smartphone2:{glyph:``,size:24,tags:[`touch`,`input`],fileSvg:`svg/smartphone2.svg`},snowflake:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/snowflake.svg`},soundFadeOut:{glyph:``,size:24,tags:[`generic`,`sound`],fileSvg:`svg/soundFadeOut.svg`},soundLimit:{glyph:``,size:24,tags:[`generic`,`sound`],fileSvg:`svg/soundLimit.svg`},soundLoud:{glyph:``,size:24,tags:[`generic`,`sound`],fileSvg:`svg/soundLoud.svg`},soundMonoL:{glyph:``,size:24,tags:[`generic`,`sound`],fileSvg:`svg/soundMonoL.svg`},soundMonoR:{glyph:``,size:24,tags:[`generic`,`sound`],fileSvg:`svg/soundMonoR.svg`},soundOff:{glyph:``,size:24,tags:[`generic`,`sound`],fileSvg:`svg/soundOff.svg`},soundQuiet:{glyph:``,size:24,tags:[`generic`,`sound`],fileSvg:`svg/soundQuiet.svg`},soundStereo:{glyph:``,size:24,tags:[`generic`,`sound`],fileSvg:`svg/soundStereo.svg`},soundWave01:{glyph:``,size:24,tags:[`generic`,`sound`],fileSvg:`svg/soundWave01.svg`},soundWave02:{glyph:``,size:24,tags:[`generic`,`sound`],fileSvg:`svg/soundWave02.svg`},sphereOnPathNumber:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`,`road tools`],fileSvg:`svg/sphereOnPathNumber.svg`},sphereOnPath:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`,`road tools`],fileSvg:`svg/sphereOnPath.svg`},sphericalBeam:{glyph:``,size:24,tags:[`generic`,`world editor`,`we`,`sensor`],fileSvg:`svg/sphericalBeam.svg`},spoilerLift:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/spoilerLift.svg`},sprayCan:{glyph:``,size:24,tags:[`decals`,`generic`],fileSvg:`svg/sprayCan.svg`},stack3:{glyph:``,size:24,tags:[`delivery`,`stencil`,`cargo`],fileSvg:`svg/stack3.svg`},star:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/star.svg`},starSecondary:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/starSecondary.svg`},steeringWheelCommon:{glyph:``,size:24,tags:[`steering`,`controller`,`input`],fileSvg:`svg/steeringWheelCommon.svg`},steeringWheelSporty:{glyph:``,size:24,tags:[`steering`,`controller`,`input`],fileSvg:`svg/steeringWheelSporty.svg`},stopwatchArrows01:{glyph:``,size:24,tags:[`generic`,`time`,`fast`],fileSvg:`svg/stopwatchArrows01.svg`},stopwatchArrows02:{glyph:``,size:24,tags:[`generic`,`time`,`fast`],fileSvg:`svg/stopwatchArrows02.svg`},stopwatchSectionOutlinedEnd:{glyph:``,size:24,tags:[`generic`,`time`,`fast`],fileSvg:`svg/stopwatchSectionOutlinedEnd.svg`},stopwatchSectionOutlinedStart:{glyph:``,size:24,tags:[`generic`,`time`,`fast`],fileSvg:`svg/stopwatchSectionOutlinedStart.svg`},stopwatchSectionSolidEnd:{glyph:``,size:24,tags:[`generic`,`time`,`fast`],fileSvg:`svg/stopwatchSectionSolidEnd.svg`},stopwatchSectionSolidStart:{glyph:``,size:24,tags:[`generic`,`time`,`fast`],fileSvg:`svg/stopwatchSectionSolidStart.svg`},strobeLights:{glyph:``,size:24,tags:[`vehicle`,`features`,`police`,`emergency`],fileSvg:`svg/strobeLights.svg`},sunRise:{glyph:``,size:24,tags:[`environment`],fileSvg:`svg/sunRise.svg`},survellianceCamera:{glyph:``,size:24,tags:[`generic`,`camera`,`optical`,`sensor`],fileSvg:`svg/survellianceCamera.svg`},suspension01:{glyph:``,size:24,tags:[`vehicle`,`features`,`part`],fileSvg:`svg/suspension01.svg`},suspension02:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/suspension02.svg`},switchBlock:{glyph:``,size:24,tags:[`generic`,`circuit`,`electronics`,`switch`],fileSvg:`svg/switchBlock.svg`},switchOutline:{glyph:``,size:24,tags:[`generic`,`circuit`,`electronics`,`switch`],fileSvg:`svg/switchOutline.svg`},sync:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/sync.svg`},synchro01:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/synchro01.svg`},synchro02:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/synchro02.svg`},tankerTrailer:{glyph:``,size:24,tags:[`cargo`,`delivery`,`tank`,`tanker`,`trailer`,`vehicle`],fileSvg:`svg/tankerTrailer.svg`},targetJump:{glyph:``,size:24,tags:[`poi`],fileSvg:`svg/targetJump.svg`},taxiCar1:{glyph:``,size:24,tags:[`taxi`,`generic`,`vehicle`],fileSvg:`svg/taxiCar1.svg`},taxiCar3:{glyph:``,size:24,tags:[`taxi`,`generic`,`vehicle`],fileSvg:`svg/taxiCar3.svg`},taxiCarT:{glyph:``,size:24,tags:[`taxi`,`generic`,`vehicle`],fileSvg:`svg/taxiCarT.svg`},taxiCheckerLamp:{glyph:``,size:24,tags:[`taxi`,`generic`,`vehicle`],fileSvg:`svg/taxiCheckerLamp.svg`},terrainToLine:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`,`road tools`],fileSvg:`svg/terrainToLine.svg`},terrain:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/terrain.svg`},thinBulbBeam:{glyph:``,size:24,tags:[`generic`,`world editor`,`we`,`sensor`],fileSvg:`svg/thinBulbBeam.svg`},thinnerBulbBeam:{glyph:``,size:24,tags:[`generic`,`world editor`,`we`,`sensor`],fileSvg:`svg/thinnerBulbBeam.svg`},thisSideUp:{glyph:``,size:24,tags:[`delivery`,`stencil`,`cargo`],fileSvg:`svg/thisSideUp.svg`},tiles:{glyph:``,size:24,tags:[`generic`,`catalog`,`selector`,`view`],fileSvg:`svg/tiles.svg`},timer:{glyph:``,size:24,tags:[`generic`,`time`,`fast`],fileSvg:`svg/timer.svg`},tireDirection3Fourth2:{glyph:``,size:24,tags:[`tire`],fileSvg:`svg/tireDirection3Fourth2.svg`},tireDirection3Fourth3:{glyph:``,size:24,tags:[`tire`],fileSvg:`svg/tireDirection3Fourth3.svg`},tireDirectionFront2:{glyph:``,size:24,tags:[`tire`],fileSvg:`svg/tireDirectionFront2.svg`},tireDirectionSide2:{glyph:``,size:24,tags:[`tire`],fileSvg:`svg/tireDirectionSide2.svg`},tireDirectionTop2:{glyph:``,size:24,tags:[`tire`],fileSvg:`svg/tireDirectionTop2.svg`},tirePressureDecrease01:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/tirePressureDecrease01.svg`},tirePressureDecrease02:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/tirePressureDecrease02.svg`},tirePressureGaugeAlt01:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/tirePressureGaugeAlt01.svg`},tirePressureGaugeAlt02:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/tirePressureGaugeAlt02.svg`},tirePressureGaugeAlt03:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/tirePressureGaugeAlt03.svg`},tirePressureGaugeOutlined01:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/tirePressureGaugeOutlined01.svg`},tirePressureGaugeOutlined02:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/tirePressureGaugeOutlined02.svg`},tirePressureGaugeOutlined03:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/tirePressureGaugeOutlined03.svg`},tirePressureGaugeSolid01:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/tirePressureGaugeSolid01.svg`},tirePressureGaugeSolid02:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/tirePressureGaugeSolid02.svg`},tirePressureGaugeSolid03:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/tirePressureGaugeSolid03.svg`},tirePressureIncrease01:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/tirePressureIncrease01.svg`},tirePressureIncrease02:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/tirePressureIncrease02.svg`},tirePressureStopLine:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/tirePressureStopLine.svg`},tirePressureStopOctoLine:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/tirePressureStopOctoLine.svg`},tirePressureStopOctoSolid:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/tirePressureStopOctoSolid.svg`},tirePressureStopSolid:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/tirePressureStopSolid.svg`},toCOMWithWheels:{glyph:``,size:24,tags:[`generic`,`world editor`,`we`,`placement`,`sensor`],fileSvg:`svg/toCOMWithWheels.svg`},toCOM:{glyph:``,size:24,tags:[`generic`,`world editor`,`we`,`placement`,`sensor`],fileSvg:`svg/toCOM.svg`},toGarage:{glyph:``,size:24,tags:[`poi`],fileSvg:`svg/toGarage.svg`},touch:{glyph:``,size:24,tags:[`touch`,`input`],fileSvg:`svg/touch.svg`},tow:{glyph:``,size:24,tags:[`generic`,`vehicle`],fileSvg:`svg/tow.svg`},tractionControl:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/tractionControl.svg`},trafficCone:{glyph:``,size:24,tags:[`route`,`traffic`],fileSvg:`svg/trafficCone.svg`},transform:{glyph:``,size:24,tags:[`decals`,`generic`],fileSvg:`svg/transform.svg`},transmissionA:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/transmissionA.svg`},transmissionM:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/transmissionM.svg`},transparencyMask:{glyph:``,size:24,tags:[`decals`,`generic`],fileSvg:`svg/transparencyMask.svg`},trashBin1:{glyph:``,size:24,tags:[`poi`],fileSvg:`svg/trashBin1.svg`},trashBin2:{glyph:``,size:24,tags:[`decals`,`generic`],fileSvg:`svg/trashBin2.svg`},triangleBeam:{glyph:``,size:24,tags:[`generic`,`world editor`,`we`,`sensor`],fileSvg:`svg/triangleBeam.svg`},trim:{glyph:``,size:24,tags:[`generic`,`sound`],fileSvg:`svg/trim.svg`},tulipBeam:{glyph:``,size:24,tags:[`generic`,`world editor`,`we`,`sensor`],fileSvg:`svg/tulipBeam.svg`},tunnel:{glyph:``,size:24,tags:[`generic`,`world editor`,`we`,`road tools`],fileSvg:`svg/tunnel.svg`},turbine:{glyph:``,size:24,tags:[`vehicle`,`part`,`features`],fileSvg:`svg/turbine.svg`},twoRoadsAdd:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`,`road tools`],fileSvg:`svg/twoRoadsAdd.svg`},twoRoadsCrossAdd:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`,`road tools`],fileSvg:`svg/twoRoadsCrossAdd.svg`},twoRoadsLink:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`,`road tools`],fileSvg:`svg/twoRoadsLink.svg`},twoUnicyclesOnly:{glyph:``,size:24,tags:[`delivery`,`stencil`,`cargo`],fileSvg:`svg/twoUnicyclesOnly.svg`},undo:{glyph:``,size:24,tags:[`decals`,`generic`],fileSvg:`svg/undo.svg`},ungroup:{glyph:``,size:24,tags:[`decals`,`generic`],fileSvg:`svg/ungroup.svg`},unlink:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/unlink.svg`},vehicleDoorsClose:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/vehicleDoorsClose.svg`},vehicleDoorsOpen:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/vehicleDoorsOpen.svg`},vehicleDoors:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/vehicleDoors.svg`},vehicleFeatures01:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/vehicleFeatures01.svg`},vehicleFeatures02:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/vehicleFeatures02.svg`},vehicleFeatures03:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/vehicleFeatures03.svg`},vehicleHood:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/vehicleHood.svg`},vehicleTrunk:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/vehicleTrunk.svg`},view:{glyph:``,size:24,tags:[`decals`,`generic`],fileSvg:`svg/view.svg`},voucherDiagonal1:{glyph:``,size:24,tags:[`generic`,`currency`,`reward`,`career`],fileSvg:`svg/voucherDiagonal1.svg`},voucherDiagonal2:{glyph:``,size:24,tags:[`generic`,`currency`,`reward`,`career`],fileSvg:`svg/voucherDiagonal2.svg`},voucherDiagonal3:{glyph:``,size:24,tags:[`generic`,`currency`,`reward`,`career`],fileSvg:`svg/voucherDiagonal3.svg`},voucherHorizontal1:{glyph:``,size:24,tags:[`generic`,`currency`,`reward`,`career`],fileSvg:`svg/voucherHorizontal1.svg`},voucherHorizontal2:{glyph:``,size:24,tags:[`generic`,`currency`,`reward`,`career`],fileSvg:`svg/voucherHorizontal2.svg`},voucherHorizontal3:{glyph:``,size:24,tags:[`generic`,`currency`,`reward`,`career`],fileSvg:`svg/voucherHorizontal3.svg`},wavesSignalReceived:{glyph:``,size:24,tags:[`generic`,`data`,`signal`,`sensor`],fileSvg:`svg/wavesSignalReceived.svg`},wavesSignalSentLeft:{glyph:``,size:24,tags:[`generic`,`data`,`signal`,`sensor`],fileSvg:`svg/wavesSignalSentLeft.svg`},wavesSignalSentRight:{glyph:``,size:24,tags:[`generic`,`data`,`signal`,`sensor`],fileSvg:`svg/wavesSignalSentRight.svg`},weather:{glyph:``,size:24,tags:[`environment`],fileSvg:`svg/weather.svg`},weight:{glyph:``,size:24,tags:[`decals`,`generic`],fileSvg:`svg/weight.svg`},wheelHubLocked01:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/wheelHubLocked01.svg`},wheelHubUnlocked01:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/wheelHubUnlocked01.svg`},wigwags:{glyph:``,size:24,tags:[`vehicle`,`features`,`police`,`emergency`],fileSvg:`svg/wigwags.svg`},wrench:{glyph:``,size:24,tags:[`generic`,`vehicle`,`features`],fileSvg:`svg/wrench.svg`},xboxA:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/xboxA.svg`},xboxB:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/xboxB.svg`},xboxDDefaultOutline:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/xboxDDefaultOutline.svg`},xboxDDefaultSolid:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/xboxDDefaultSolid.svg`},xboxDDown:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/xboxDDown.svg`},xboxDLeft:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/xboxDLeft.svg`},xboxDRight:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/xboxDRight.svg`},xboxDUp:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/xboxDUp.svg`},xboxLB:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/xboxLB.svg`},xboxLSButton:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/xboxLSButton.svg`},xboxLT:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/xboxLT.svg`},xboxMenu:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/xboxMenu.svg`},xboxRB:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/xboxRB.svg`},xboxRSButton:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/xboxRSButton.svg`},xboxRT:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/xboxRT.svg`},xboxThumbL:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/xboxThumbL.svg`},xboxThumbR:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/xboxThumbR.svg`},xboxView:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/xboxView.svg`},xboxXAxis:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/xboxXAxis.svg`},xboxXRot:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/xboxXRot.svg`},xboxX:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/xboxX.svg`},xboxYAxis:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/xboxYAxis.svg`},xboxYRot:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/xboxYRot.svg`},xboxY:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/xboxY.svg`},AIL:{glyph:``,size:48,tags:[`extra`],fileSvg:`svg/AIL.svg`},arrowLeftOutline:{glyph:``,size:48,tags:[`web`,`outlined`,`large`,`secondary`],fileSvg:`svg/arrowLeftOutline.svg`},arrowRightOutline:{glyph:``,size:48,tags:[`web`,`outlined`,`large`,`secondary`],fileSvg:`svg/arrowRightOutline.svg`},automaticTransmissionL:{glyph:``,size:48,tags:[`extra`],fileSvg:`svg/automaticTransmissionL.svg`},beamsNodesMessageOutline:{glyph:``,size:48,tags:[`web`,`outlined`,`large`,`secondary`],fileSvg:`svg/beamsNodesMessageOutline.svg`},beamsNodesOutline:{glyph:``,size:48,tags:[`web`,`outlined`,`large`,`secondary`],fileSvg:`svg/beamsNodesOutline.svg`},beamsNodesPlugOutline:{glyph:``,size:48,tags:[`web`,`outlined`,`large`,`secondary`],fileSvg:`svg/beamsNodesPlugOutline.svg`},BNGEcosystemOutline:{glyph:``,size:48,tags:[`web`,`outlined`,`large`,`secondary`],fileSvg:`svg/BNGEcosystemOutline.svg`},carFrontRouteOutline:{glyph:``,size:48,tags:[`web`,`outlined`,`large`,`secondary`],fileSvg:`svg/carFrontRouteOutline.svg`},carSensorsOutline:{glyph:``,size:48,tags:[`web`,`outlined`,`large`,`secondary`],fileSvg:`svg/carSensorsOutline.svg`},carSideRouteOutline:{glyph:``,size:48,tags:[`web`,`outlined`,`large`,`secondary`],fileSvg:`svg/carSideRouteOutline.svg`},chargeLL:{glyph:``,size:48,tags:[`extra`],fileSvg:`svg/chargeLL.svg`},cityOutline:{glyph:``,size:48,tags:[`web`,`outlined`,`large`,`secondary`],fileSvg:`svg/cityOutline.svg`},clutchL:{glyph:``,size:48,tags:[`extra`],fileSvg:`svg/clutchL.svg`},couplerL:{glyph:``,size:48,tags:[`extra`],fileSvg:`svg/couplerL.svg`},dialogOutline:{glyph:``,size:48,tags:[`web`,`outlined`,`large`,`secondary`],fileSvg:`svg/dialogOutline.svg`},documentSmileOutline:{glyph:``,size:48,tags:[`web`,`outlined`,`large`,`secondary`],fileSvg:`svg/documentSmileOutline.svg`},drivetrainOutline:{glyph:``,size:48,tags:[`web`,`outlined`,`large`,`secondary`],fileSvg:`svg/drivetrainOutline.svg`},electronicSchemeOutline:{glyph:``,size:48,tags:[`web`,`outlined`,`large`,`secondary`],fileSvg:`svg/electronicSchemeOutline.svg`},engineL:{glyph:``,size:48,tags:[`extra`],fileSvg:`svg/engineL.svg`},engineOutline:{glyph:``,size:48,tags:[`web`,`outlined`,`large`,`secondary`],fileSvg:`svg/engineOutline.svg`},gearTuningOutline:{glyph:``,size:48,tags:[`web`,`outlined`,`large`,`secondary`],fileSvg:`svg/gearTuningOutline.svg`},giftBoxOutline:{glyph:``,size:48,tags:[`web`,`outlined`,`large`,`secondary`],fileSvg:`svg/giftBoxOutline.svg`},lidarOutline:{glyph:``,size:48,tags:[`web`,`outlined`,`large`,`secondary`],fileSvg:`svg/lidarOutline.svg`},medalStarOutline:{glyph:``,size:48,tags:[`web`,`outlined`,`large`,`secondary`],fileSvg:`svg/medalStarOutline.svg`},megaphoneOutline:{glyph:``,size:48,tags:[`web`,`outlined`,`large`,`secondary`],fileSvg:`svg/megaphoneOutline.svg`},multiseatL:{glyph:``,size:48,tags:[`extra`],fileSvg:`svg/multiseatL.svg`},peopleOutline:{glyph:``,size:48,tags:[`web`,`outlined`,`large`,`secondary`],fileSvg:`svg/peopleOutline.svg`},personOutline:{glyph:``,size:48,tags:[`web`,`outlined`,`large`,`secondary`],fileSvg:`svg/personOutline.svg`},physicsOutline:{glyph:``,size:48,tags:[`web`,`outlined`,`large`,`secondary`],fileSvg:`svg/physicsOutline.svg`},playChainOutline:{glyph:``,size:48,tags:[`web`,`outlined`,`large`,`secondary`],fileSvg:`svg/playChainOutline.svg`},POITimeL:{glyph:``,size:48,tags:[`extra`],fileSvg:`svg/POITimeL.svg`},proximitySensorsOutline:{glyph:``,size:48,tags:[`web`,`outlined`,`large`,`secondary`],fileSvg:`svg/proximitySensorsOutline.svg`},qualityBadgeStarOutline:{glyph:``,size:48,tags:[`web`,`outlined`,`large`,`secondary`],fileSvg:`svg/qualityBadgeStarOutline.svg`},qualityBadgeVOutline:{glyph:``,size:48,tags:[`web`,`outlined`,`large`,`secondary`],fileSvg:`svg/qualityBadgeVOutline.svg`},replayL:{glyph:``,size:48,tags:[`extra`],fileSvg:`svg/replayL.svg`},roadblockL:{glyph:``,size:48,tags:[`extra`],fileSvg:`svg/roadblockL.svg`},rotationL:{glyph:``,size:48,tags:[`extra`],fileSvg:`svg/rotationL.svg`},sensorsL:{glyph:``,size:48,tags:[`extra`],fileSvg:`svg/sensorsL.svg`},simRigOutline:{glyph:``,size:48,tags:[`web`,`outlined`,`large`,`secondary`],fileSvg:`svg/simRigOutline.svg`},suspensionOutline:{glyph:``,size:48,tags:[`web`,`outlined`,`large`,`secondary`],fileSvg:`svg/suspensionOutline.svg`},teamOutline:{glyph:``,size:48,tags:[`web`,`outlined`,`large`,`secondary`],fileSvg:`svg/teamOutline.svg`},techLightBulbOutline01:{glyph:``,size:48,tags:[`web`,`outlined`,`large`,`secondary`],fileSvg:`svg/techLightBulbOutline01.svg`},techLightBulbOutline02:{glyph:``,size:48,tags:[`web`,`outlined`,`large`,`secondary`],fileSvg:`svg/techLightBulbOutline02.svg`},temperatureL:{glyph:``,size:48,tags:[`extra`],fileSvg:`svg/temperatureL.svg`},timeUnlockOutline:{glyph:``,size:48,tags:[`web`,`outlined`,`large`,`secondary`],fileSvg:`svg/timeUnlockOutline.svg`},timedLockOutline:{glyph:``,size:48,tags:[`web`,`outlined`,`large`,`secondary`],fileSvg:`svg/timedLockOutline.svg`},trafficOutline:{glyph:``,size:48,tags:[`web`,`outlined`,`large`,`secondary`],fileSvg:`svg/trafficOutline.svg`},tuningL:{glyph:``,size:48,tags:[`extra`],fileSvg:`svg/tuningL.svg`},turbineL:{glyph:``,size:48,tags:[`extra`],fileSvg:`svg/turbineL.svg`},voucherOutline:{glyph:``,size:48,tags:[`web`,`outlined`,`large`,`secondary`],fileSvg:`svg/voucherOutline.svg`},wheelBeamsNodesOutline:{glyph:``,size:48,tags:[`web`,`outlined`,`large`,`secondary`],fileSvg:`svg/wheelBeamsNodesOutline.svg`},wheelOutline:{glyph:``,size:48,tags:[`web`,`outlined`,`large`,`secondary`],fileSvg:`svg/wheelOutline.svg`},circlePinBack:{glyph:``,size:56,tags:[`poi`],fileSvg:`svg/circlePinBack.svg`},circlePinFront:{glyph:``,size:56,tags:[`poi`],fileSvg:`svg/circlePinFront.svg`},markerRectanglePinBack:{glyph:``,size:56,tags:[`poi`],fileSvg:`svg/markerRectanglePinBack.svg`},markerRectanglePinFront:{glyph:``,size:56,tags:[`poi`],fileSvg:`svg/markerRectanglePinFront.svg`},markerTriangleBack:{glyph:``,size:56,tags:[`poi`],fileSvg:`svg/markerTriangleBack.svg`},markerTriangleFront:{glyph:``,size:56,tags:[`poi`],fileSvg:`svg/markerTriangleFront.svg`},danger:{glyph:``,size:24,tags:[`generic`,`hazard`],fileSvg:`svg/danger.svg`},droplet:{glyph:``,size:24,tags:[`generic`,`drop`,`liquid`],fileSvg:`svg/droplet.svg`},envelope:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/envelope.svg`},fireDiamond:{glyph:``,size:24,tags:[`generic`,`hazard`,`nfpa704`],fileSvg:`svg/fireDiamond.svg`},rocks:{glyph:``,size:24,tags:[`dry cargo`,`dry`],fileSvg:`svg/rocks.svg`},xmark:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/xmark.svg`},scale:{glyph:``,size:24,tags:[`decals`,`editor`,`generic`],fileSvg:`svg/scale.svg`},arrowsUp:{glyph:``,size:16,tags:[`marker`,`ribbon`,`content-props`],fileSvg:`svg/arrowsUp.svg`},bigDot:{glyph:``,size:16,tags:[`marker`,`ribbon`,`content-props`],fileSvg:`svg/bigDot.svg`},connectorBold:{glyph:``,size:16,tags:[`marker`,`ribbon`,`content-props`],fileSvg:`svg/connectorBold.svg`},cornerTopRight:{glyph:``,size:16,tags:[`marker`,`ribbon`,`content-props`],fileSvg:`svg/cornerTopRight.svg`},plusBold:{glyph:``,size:16,tags:[`marker`,`ribbon`,`content-props`],fileSvg:`svg/plusBold.svg`},puzzlePieceBold:{glyph:``,size:16,tags:[`marker`,`ribbon`,`content-props`],fileSvg:`svg/puzzlePieceBold.svg`},locationDestination:{glyph:``,size:24,tags:[`generic`,`location`,`route`,`path`,`node`],fileSvg:`svg/locationDestination.svg`},locationSource:{glyph:``,size:24,tags:[`generic`,`location`,`route`,`path`,`node`],fileSvg:`svg/locationSource.svg`},accelerationKPH:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/accelerationKPH.svg`},accelerationMPH:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/accelerationMPH.svg`},boxTruckFast:{glyph:``,size:24,tags:[`cargo`,`delivery`,`vehicle`],fileSvg:`svg/boxTruckFast.svg`},colorBrightnessSun:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/colorBrightnessSun.svg`},colorCirclePalette:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/colorCirclePalette.svg`},colorPalette:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/colorPalette.svg`},colorSaturation:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/colorSaturation.svg`},sortAscDown02:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/sortAscDown02.svg`},sortAscDown:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/sortAscDown.svg`},sortAscUp02:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/sortAscUp02.svg`},sortAscUp:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/sortAscUp.svg`},sortDescDown02:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/sortDescDown02.svg`},sortDescDown:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/sortDescDown.svg`},sortDescUp02:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/sortDescUp02.svg`},sortDescUp:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/sortDescUp.svg`},cardboardBoxCoins:{glyph:``,size:24,tags:[`generic`,`delivery`],fileSvg:`svg/cardboardBoxCoins.svg`},lasso:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`],fileSvg:`svg/lasso.svg`},materialGlossy:{glyph:``,size:24,tags:[`decals`,`generic`],fileSvg:`svg/materialGlossy.svg`},materialMetal:{glyph:``,size:24,tags:[`decals`,`generic`],fileSvg:`svg/materialMetal.svg`},materialRoughness:{glyph:``,size:24,tags:[`decals`,`generic`],fileSvg:`svg/materialRoughness.svg`},materialTransparency01:{glyph:``,size:24,tags:[`decals`,`generic`],fileSvg:`svg/materialTransparency01.svg`},materialTransparency02:{glyph:``,size:24,tags:[`decals`,`generic`],fileSvg:`svg/materialTransparency02.svg`},metal01:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/metal01.svg`},removeItemPolygon:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`,`road tools`],fileSvg:`svg/removeItemPolygon.svg`},removeListItem:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`,`road tools`],fileSvg:`svg/removeListItem.svg`},sortAsc:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/sortAsc.svg`},sortDesc:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/sortDesc.svg`},surfaceRoughness02:{glyph:``,size:24,tags:[`decals`,`generic`],fileSvg:`svg/surfaceRoughness02.svg`},shieldCheckmark:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/shieldCheckmark.svg`},shieldHandCheckmark:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/shieldHandCheckmark.svg`},shieldHandPlus:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/shieldHandPlus.svg`},doorFrontCoins:{glyph:``,size:24,tags:[`vehicle`,`part`,`features`],fileSvg:`svg/doorFrontCoins.svg`},doorFront:{glyph:``,size:24,tags:[`vehicle`,`part`,`features`],fileSvg:`svg/doorFront.svg`},engineCoins:{glyph:``,size:24,tags:[`vehicle`,`part`,`features`],fileSvg:`svg/engineCoins.svg`},exhaustMufflerCoins:{glyph:``,size:24,tags:[`vehicle`,`part`,`features`],fileSvg:`svg/exhaustMufflerCoins.svg`},exhaustMuffler:{glyph:``,size:24,tags:[`vehicle`,`part`,`features`],fileSvg:`svg/exhaustMuffler.svg`},headlightCoins:{glyph:``,size:24,tags:[`vehicle`,`part`,`features`],fileSvg:`svg/headlightCoins.svg`},headlight:{glyph:``,size:24,tags:[`vehicle`,`part`,`features`],fileSvg:`svg/headlight.svg`},tire3FourthCoins:{glyph:``,size:24,tags:[`vehicle`,`part`,`features`,`tire`],fileSvg:`svg/tire3FourthCoins.svg`},tire3Fourth:{glyph:``,size:24,tags:[`vehicle`,`part`,`features`,`tire`],fileSvg:`svg/tire3Fourth.svg`},turbineCoins:{glyph:``,size:24,tags:[`vehicle`,`part`,`features`],fileSvg:`svg/turbineCoins.svg`},wheelDiscCoins:{glyph:``,size:24,tags:[`vehicle`,`part`,`features`],fileSvg:`svg/wheelDiscCoins.svg`},wheelDisc:{glyph:``,size:24,tags:[`vehicle`,`part`,`features`],fileSvg:`svg/wheelDisc.svg`},bridgeWithRiver:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`,`road tools`],fileSvg:`svg/bridgeWithRiver.svg`},gizmosOutline:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`,`road tools`],fileSvg:`svg/gizmosOutline.svg`},gizmosSolid:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`,`road tools`],fileSvg:`svg/gizmosSolid.svg`},highwayRoad3To2Merge01:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`,`road tools`],fileSvg:`svg/highwayRoad3To2Merge01.svg`},highwayRoad3To2Merge02:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`,`road tools`],fileSvg:`svg/highwayRoad3To2Merge02.svg`},highwayToUrbanRoadTransition01:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`,`road tools`],fileSvg:`svg/highwayToUrbanRoadTransition01.svg`},highwayToUrbanRoadTransition02:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`,`road tools`],fileSvg:`svg/highwayToUrbanRoadTransition02.svg`},pedestrianCrossing01:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`,`road tools`],fileSvg:`svg/pedestrianCrossing01.svg`},polygonalCube:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`,`road tools`],fileSvg:`svg/polygonalCube.svg`},roadEditOutline:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`,`road tools`],fileSvg:`svg/roadEditOutline.svg`},roadEditSolid:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`,`road tools`],fileSvg:`svg/roadEditSolid.svg`},roadFolderPlus:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`,`road tools`],fileSvg:`svg/roadFolderPlus.svg`},roadFolder:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`,`road tools`],fileSvg:`svg/roadFolder.svg`},roadGuideArrowOutline:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`,`road tools`],fileSvg:`svg/roadGuideArrowOutline.svg`},roadGuideArrowSolid:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`,`road tools`],fileSvg:`svg/roadGuideArrowSolid.svg`},roadOutlineMesh:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`,`road tools`],fileSvg:`svg/roadOutlineMesh.svg`},roadPedestrianCrossing02:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`,`road tools`],fileSvg:`svg/roadPedestrianCrossing02.svg`},roadProfileWithCheckmark:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`,`road tools`],fileSvg:`svg/roadProfileWithCheckmark.svg`},roadProfile:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`,`road tools`],fileSvg:`svg/roadProfile.svg`},roadRoundaboutJunction:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`,`road tools`],fileSvg:`svg/roadRoundaboutJunction.svg`},roadSidewalkTransition:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`,`road tools`],fileSvg:`svg/roadSidewalkTransition.svg`},roadStackPlus:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`,`road tools`],fileSvg:`svg/roadStackPlus.svg`},roadStack:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`,`road tools`],fileSvg:`svg/roadStack.svg`},roadTJunction:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`,`road tools`],fileSvg:`svg/roadTJunction.svg`},roadXJunction:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`,`road tools`],fileSvg:`svg/roadXJunction.svg`},roadYJunction:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`,`road tools`],fileSvg:`svg/roadYJunction.svg`},shoppingCart:{glyph:``,size:24,tags:[`generic`,`shop`,`purchase`],fileSvg:`svg/shoppingCart.svg`},singleLineToTerrain:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`,`road tools`],fileSvg:`svg/singleLineToTerrain.svg`},sphereOnMesh:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`,`road tools`],fileSvg:`svg/sphereOnMesh.svg`},twoLinesToTerrain:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`,`road tools`],fileSvg:`svg/twoLinesToTerrain.svg`},urbanRoad3To2Merge01:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`,`road tools`],fileSvg:`svg/urbanRoad3To2Merge01.svg`},urbanRoad3To2Merge02:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`,`road tools`],fileSvg:`svg/urbanRoad3To2Merge02.svg`},urbanRoadToHighwayTransition01:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`,`road tools`],fileSvg:`svg/urbanRoadToHighwayTransition01.svg`},urbanRoadToHighwayTransition02:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`,`road tools`],fileSvg:`svg/urbanRoadToHighwayTransition02.svg`},floppyDiskPlus:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/floppyDiskPlus.svg`},highwayMerge:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`,`road tools`],fileSvg:`svg/highwayMerge.svg`},highwaySeparate:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`,`road tools`],fileSvg:`svg/highwaySeparate.svg`},highwayShoulderMerge:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`,`road tools`],fileSvg:`svg/highwayShoulderMerge.svg`},terrainToSingleLine:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`,`road tools`],fileSvg:`svg/terrainToSingleLine.svg`},terrainToTwoLines:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`,`road tools`],fileSvg:`svg/terrainToTwoLines.svg`},urbanRoadMerge:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`,`road tools`],fileSvg:`svg/urbanRoadMerge.svg`},urbanRoadSeparate:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`,`road tools`],fileSvg:`svg/urbanRoadSeparate.svg`},urbanShoulderMerge:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`,`road tools`],fileSvg:`svg/urbanShoulderMerge.svg`},discharging:{glyph:``,size:24,tags:[`fuel`,`electricity`,`ev`],fileSvg:`svg/discharging.svg`},BNGChat:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/BNGChat.svg`},chatBubble:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/chatBubble.svg`},busTilted:{glyph:``,size:24,tags:[`poi`,`vehicle`,`bus`],fileSvg:`svg/busTilted.svg`},cameraFarClip:{glyph:``,size:24,tags:[`decals`,`generic`],fileSvg:`svg/cameraFarClip.svg`},cameraNearClip:{glyph:``,size:24,tags:[`decals`,`generic`],fileSvg:`svg/cameraNearClip.svg`},explosion:{glyph:``,size:24,tags:[`generic`,`destruction`],fileSvg:`svg/explosion.svg`},fireExtinguisher:{glyph:``,size:24,tags:[`generic`,`destruction`],fileSvg:`svg/fireExtinguisher.svg`},fire:{glyph:``,size:24,tags:[`generic`,`destruction`],fileSvg:`svg/fire.svg`},jointLockedMultiple:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/jointLockedMultiple.svg`},jointUnlockedMultiple:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/jointUnlockedMultiple.svg`},toggleOff:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/toggleOff.svg`},toggleOn:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/toggleOn.svg`},viewFarClip:{glyph:``,size:24,tags:[`decals`,`generic`],fileSvg:`svg/viewFarClip.svg`},viewNearClip:{glyph:``,size:24,tags:[`decals`,`generic`],fileSvg:`svg/viewNearClip.svg`},twoArrowsHorizontal:{glyph:``,size:24,tags:[`arrow`,`large`,`solid`,`turn signals`],fileSvg:`svg/twoArrowsHorizontal.svg`},twoArrowsVertical:{glyph:``,size:24,tags:[`arrow`,`large`,`solid`,`turn signals`],fileSvg:`svg/twoArrowsVertical.svg`},bridge:{glyph:``,size:48,tags:[`rally`,`pace notes`,`directions`,`surface`,`features`],fileSvg:`svg/bridge.svg`},bump:{glyph:``,size:48,tags:[`rally`,`pace notes`,`directions`,`surface`,`features`],fileSvg:`svg/bump.svg`},bumps:{glyph:``,size:48,tags:[`rally`,`pace notes`,`directions`,`surface`,`features`],fileSvg:`svg/bumps.svg`},caution:{glyph:``,size:48,tags:[`rally`,`pace notes`,`directions`,`surface`,`features`],fileSvg:`svg/caution.svg`},crest:{glyph:``,size:48,tags:[`rally`,`pace notes`,`directions`,`surface`,`features`],fileSvg:`svg/crest.svg`},doubleCaution:{glyph:``,size:48,tags:[`rally`,`pace notes`,`directions`,`surface`,`features`],fileSvg:`svg/doubleCaution.svg`},finish:{glyph:``,size:48,tags:[`rally`,`pace notes`,`directions`,`surface`,`features`],fileSvg:`svg/finish.svg`},jumpOverBump:{glyph:``,size:48,tags:[`rally`,`pace notes`,`directions`,`surface`,`features`],fileSvg:`svg/jumpOverBump.svg`},narrows:{glyph:``,size:48,tags:[`rally`,`pace notes`,`directions`,`surface`,`features`],fileSvg:`svg/narrows.svg`},pothole:{glyph:``,size:48,tags:[`rally`,`pace notes`,`directions`,`surface`,`features`],fileSvg:`svg/pothole.svg`},turn1:{glyph:``,size:48,tags:[`rally`,`pace notes`,`directions`,`surface`,`features`],fileSvg:`svg/turn1.svg`},turn2:{glyph:``,size:48,tags:[`rally`,`pace notes`,`directions`,`surface`,`features`],fileSvg:`svg/turn2.svg`},turn3:{glyph:``,size:48,tags:[`rally`,`pace notes`,`directions`,`surface`,`features`],fileSvg:`svg/turn3.svg`},turn4:{glyph:``,size:48,tags:[`rally`,`pace notes`,`directions`,`surface`,`features`],fileSvg:`svg/turn4.svg`},turn5:{glyph:``,size:48,tags:[`rally`,`pace notes`,`directions`,`surface`,`features`],fileSvg:`svg/turn5.svg`},turn6:{glyph:``,size:48,tags:[`rally`,`pace notes`,`directions`,`surface`,`features`],fileSvg:`svg/turn6.svg`},turnHp:{glyph:``,size:48,tags:[`rally`,`pace notes`,`directions`,`surface`,`features`],fileSvg:`svg/turnHp.svg`},turnSq:{glyph:``,size:48,tags:[`rally`,`pace notes`,`directions`,`surface`,`features`],fileSvg:`svg/turnSq.svg`},water:{glyph:``,size:48,tags:[`rally`,`pace notes`,`directions`,`surface`,`features`],fileSvg:`svg/water.svg`},circleSlashed:{glyph:``,size:24,tags:[`generic`,`do not cut`,`no entry`],fileSvg:`svg/circleSlashed.svg`},scissorsSlashed:{glyph:``,size:24,tags:[`generic`,`do not cut`],fileSvg:`svg/scissorsSlashed.svg`},scissors:{glyph:``,size:24,tags:[`generic`,`cut`],fileSvg:`svg/scissors.svg`},airPuffRight1:{glyph:``,size:24,tags:[`generic`,`vehicle`,`car`],fileSvg:`svg/airPuffRight1.svg`},airPuffUp1:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/airPuffUp1.svg`},arrowsReplace:{glyph:``,size:24,tags:[`generic`,`arrow`],fileSvg:`svg/arrowsReplace.svg`},arrowsShuffle:{glyph:``,size:24,tags:[`generic`,`arrow`],fileSvg:`svg/arrowsShuffle.svg`},arrowsSwitch:{glyph:``,size:24,tags:[`generic`,`arrow`],fileSvg:`svg/arrowsSwitch.svg`},carClock:{glyph:``,size:24,tags:[`generic`,`vehicle`],fileSvg:`svg/carClock.svg`},carFast:{glyph:``,size:24,tags:[`vehicle`],fileSvg:`svg/carFast.svg`},carNumber1:{glyph:``,size:24,tags:[`generic`,`vehicle`],fileSvg:`svg/carNumber1.svg`},carNumber2:{glyph:``,size:24,tags:[`generic`,`vehicle`],fileSvg:`svg/carNumber2.svg`},carNumber3:{glyph:``,size:24,tags:[`generic`,`vehicle`],fileSvg:`svg/carNumber3.svg`},carNumber4:{glyph:``,size:24,tags:[`generic`,`vehicle`],fileSvg:`svg/carNumber4.svg`},carNumber5:{glyph:``,size:24,tags:[`generic`,`vehicle`],fileSvg:`svg/carNumber5.svg`},carNumber6:{glyph:``,size:24,tags:[`generic`,`vehicle`],fileSvg:`svg/carNumber6.svg`},carNumber7:{glyph:``,size:24,tags:[`generic`,`vehicle`],fileSvg:`svg/carNumber7.svg`},carNumber8:{glyph:``,size:24,tags:[`generic`,`vehicle`],fileSvg:`svg/carNumber8.svg`},carNumber9:{glyph:``,size:24,tags:[`generic`,`vehicle`],fileSvg:`svg/carNumber9.svg`},carPlus:{glyph:``,size:24,tags:[`generic`,`vehicle`],fileSvg:`svg/carPlus.svg`},carsChange:{glyph:``,size:24,tags:[`vehicle`,`select`],fileSvg:`svg/carsChange.svg`},carsFollow:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/carsFollow.svg`},doorFrontDetached:{glyph:``,size:24,tags:[`vehicle`,`part`,`features`],fileSvg:`svg/doorFrontDetached.svg`},forceFieldPull1:{glyph:``,size:24,tags:[`physics`,`field`,`force`],fileSvg:`svg/forceFieldPull1.svg`},forceFieldPull2:{glyph:``,size:24,tags:[`physics`,`field`,`force`],fileSvg:`svg/forceFieldPull2.svg`},forceFieldPull3:{glyph:``,size:24,tags:[`physics`,`field`,`force`],fileSvg:`svg/forceFieldPull3.svg`},forceFieldPush1:{glyph:``,size:24,tags:[`physics`,`field`,`force`],fileSvg:`svg/forceFieldPush1.svg`},forceFieldPush2:{glyph:``,size:24,tags:[`physics`,`field`,`force`],fileSvg:`svg/forceFieldPush2.svg`},forceFieldPush3:{glyph:``,size:24,tags:[`physics`,`field`,`force`],fileSvg:`svg/forceFieldPush3.svg`},garageNumber1:{glyph:``,size:24,tags:[`career`,`garage number`,`features`],fileSvg:`svg/garageNumber1.svg`},garageNumber2:{glyph:``,size:24,tags:[`career`,`garage number`,`features`],fileSvg:`svg/garageNumber2.svg`},garageNumber3:{glyph:``,size:24,tags:[`career`,`garage number`,`features`],fileSvg:`svg/garageNumber3.svg`},garageNumber4:{glyph:``,size:24,tags:[`career`,`garage number`,`features`],fileSvg:`svg/garageNumber4.svg`},garageNumber5:{glyph:``,size:24,tags:[`career`,`garage number`,`features`],fileSvg:`svg/garageNumber5.svg`},garageNumber6:{glyph:``,size:24,tags:[`career`,`garage number`,`features`],fileSvg:`svg/garageNumber6.svg`},garageNumber7:{glyph:``,size:24,tags:[`career`,`garage number`,`features`],fileSvg:`svg/garageNumber7.svg`},garageNumber8:{glyph:``,size:24,tags:[`career`,`garage number`,`features`],fileSvg:`svg/garageNumber8.svg`},garageNumber9:{glyph:``,size:24,tags:[`career`,`garage number`,`features`],fileSvg:`svg/garageNumber9.svg`},hingeBroken:{glyph:``,size:24,tags:[`vehicle`,`part`,`features`],fileSvg:`svg/hingeBroken.svg`},loadMesh:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/loadMesh.svg`},octagonBrick:{glyph:``,size:24,tags:[`generic`,`vehicle`,`car`],fileSvg:`svg/octagonBrick.svg`},octagon:{glyph:``,size:24,tags:[`generic`,`vehicle`,`car`],fileSvg:`svg/octagon.svg`},pushUp:{glyph:``,size:24,tags:[`physics`,`force`],fileSvg:`svg/pushUp.svg`},saveMesh:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/saveMesh.svg`},square:{glyph:``,size:24,tags:[`playback`,`stop`],fileSvg:`svg/square.svg`},tireAirPuff:{glyph:``,size:24,tags:[`vehicle`,`car`],fileSvg:`svg/tireAirPuff.svg`},tireDeflated:{glyph:``,size:24,tags:[`vehicle`,`car`],fileSvg:`svg/tireDeflated.svg`},trafficLight:{glyph:``,size:24,tags:[`generic`,`traffic`,`roads`],fileSvg:`svg/trafficLight.svg`},enter:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/enter.svg`},pedestrianRunning:{glyph:``,size:24,tags:[`generic`,`sign`,`pedestrian`,`traffic`],fileSvg:`svg/pedestrianRunning.svg`},pedestrianStanding:{glyph:``,size:24,tags:[`generic`,`sign`,`pedestrian`,`traffic`],fileSvg:`svg/pedestrianStanding.svg`},seatArrowIn:{glyph:``,size:24,tags:[`generic`,`arrow`,`actions`],fileSvg:`svg/seatArrowIn.svg`},seatArrowOut:{glyph:``,size:24,tags:[`generic`,`arrow`,`actions`],fileSvg:`svg/seatArrowOut.svg`},seatVArrowIn:{glyph:``,size:24,tags:[`generic`,`arrow`,`actions`],fileSvg:`svg/seatVArrowIn.svg`},seatVArrowOut:{glyph:``,size:24,tags:[`generic`,`arrow`,`actions`],fileSvg:`svg/seatVArrowOut.svg`},vehicleArrowIn:{glyph:``,size:24,tags:[`generic`,`arrow`,`actions`],fileSvg:`svg/vehicleArrowIn.svg`},vehicleArrowOut:{glyph:``,size:24,tags:[`generic`,`arrow`,`actions`],fileSvg:`svg/vehicleArrowOut.svg`},leverFrontOperate:{glyph:``,size:24,tags:[`generic`,`actions`],fileSvg:`svg/leverFrontOperate.svg`},leverSideDown:{glyph:``,size:24,tags:[`generic`,`actions`],fileSvg:`svg/leverSideDown.svg`},leverSideOperate:{glyph:``,size:24,tags:[`generic`,`actions`],fileSvg:`svg/leverSideOperate.svg`},leverSideUp:{glyph:``,size:24,tags:[`generic`,`actions`],fileSvg:`svg/leverSideUp.svg`},medalEmpty:{glyph:``,size:24,tags:[`generic`,`reward`,`achievment`],fileSvg:`svg/medalEmpty.svg`},medalStar:{glyph:``,size:24,tags:[`generic`,`reward`,`achievment`],fileSvg:`svg/medalStar.svg`},seatArrowInLeft:{glyph:``,size:24,tags:[`generic`,`arrow`,`actions`],fileSvg:`svg/seatArrowInLeft.svg`},seatArrowOutLeft:{glyph:``,size:24,tags:[`generic`,`arrow`,`actions`],fileSvg:`svg/seatArrowOutLeft.svg`},seatVArrowInLeft:{glyph:``,size:24,tags:[`generic`,`arrow`,`actions`],fileSvg:`svg/seatVArrowInLeft.svg`},seatVArrowOutLeft:{glyph:``,size:24,tags:[`generic`,`arrow`,`actions`],fileSvg:`svg/seatVArrowOutLeft.svg`},badgeRoundEmpty:{glyph:``,size:24,tags:[`generic`,`reward`,`achievment`],fileSvg:`svg/badgeRoundEmpty.svg`},badgeRoundStar:{glyph:``,size:24,tags:[`generic`,`reward`,`achievment`],fileSvg:`svg/badgeRoundStar.svg`},badgeRound:{glyph:``,size:24,tags:[`generic`,`reward`,`achievment`],fileSvg:`svg/badgeRound.svg`},badge:{glyph:``,size:24,tags:[`generic`,`reward`,`achievment`],fileSvg:`svg/badge.svg`},beamCurrencyOutlineLarge:{glyph:``,size:48,tags:[`outline`,`generic`,`currency`],fileSvg:`svg/beamCurrencyOutlineLarge.svg`},carSideOutlineLarge:{glyph:``,size:48,tags:[`generic`,`vehicle`],fileSvg:`svg/carSideOutlineLarge.svg`},flagOutlineLarge:{glyph:``,size:48,tags:[`generic`,`mission`,`scenario`],fileSvg:`svg/flagOutlineLarge.svg`},terrainOutlineLarge:{glyph:``,size:48,tags:[`generic`],fileSvg:`svg/terrainOutlineLarge.svg`},houseWrenchRoof:{glyph:``,size:24,tags:[`career`,`garage`,`features`,`house`],fileSvg:`svg/houseWrenchRoof.svg`},houseWrench:{glyph:``,size:24,tags:[`career`,`garage`,`features`,`house`],fileSvg:`svg/houseWrench.svg`},eject:{glyph:``,size:24,tags:[`playback`],fileSvg:`svg/eject.svg`},rallyHelmet3To4:{glyph:``,size:24,tags:[`helmet`,`rally`,`generic`,`racing`,`game mode`],fileSvg:`svg/rallyHelmet3To4.svg`},rallyHelmet:{glyph:``,size:24,tags:[`helmet`,`rally`,`generic`,`racing`,`game mode`],fileSvg:`svg/rallyHelmet.svg`},test:{glyph:``,size:24,tags:[`generic`,`hazard`],fileSvg:`svg/test.svg`},tripleCaution:{glyph:``,size:48,tags:[`rally`,`pace notes`,`directions`,`surface`,`features`],fileSvg:`svg/tripleCaution.svg`},globeSimpleNotSign:{glyph:``,size:24,tags:[`generic`,`offline`],fileSvg:`svg/globeSimpleNotSign.svg`},globeSimplified:{glyph:``,size:24,tags:[`generic`,`online`],fileSvg:`svg/globeSimplified.svg`},radialMenu:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/radialMenu.svg`},branch:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/branch.svg`},NA:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/NA.svg`},psCircleOutline:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/psCircleOutline.svg`},psCircle:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/psCircle.svg`},psCreate2:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/psCreate2.svg`},psCreate:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/psCreate.svg`},psCrossOutline:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/psCrossOutline.svg`},psCross:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/psCross.svg`},psDDefaultOutline:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/psDDefaultOutline.svg`},psDDefaultSolid:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/psDDefaultSolid.svg`},psDDown:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/psDDown.svg`},psDLeft:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/psDLeft.svg`},psDRight:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/psDRight.svg`},psDUp:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/psDUp.svg`},psL1:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/psL1.svg`},psL2:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/psL2.svg`},psL3ButtonArrowDown:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/psL3ButtonArrowDown.svg`},psL3Button:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/psL3Button.svg`},psLSXLeft:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/psLSXLeft.svg`},psLSXRight:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/psLSXRight.svg`},psLSX:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/psLSX.svg`},psLSYDown:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/psLSYDown.svg`},psLSYUp:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/psLSYUp.svg`},psLSY:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/psLSY.svg`},psLS:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/psLS.svg`},psMenu2:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/psMenu2.svg`},psMenu:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/psMenu.svg`},psR1:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/psR1.svg`},psR2:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/psR2.svg`},psR3ButtonArrowDown:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/psR3ButtonArrowDown.svg`},psR3Button:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/psR3Button.svg`},psRSXLeft:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/psRSXLeft.svg`},psRSXRight:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/psRSXRight.svg`},psRSX:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/psRSX.svg`},psRSYDown:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/psRSYDown.svg`},psRSYUp:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/psRSYUp.svg`},psRSY:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/psRSY.svg`},psRS:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/psRS.svg`},psSquareOutline:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/psSquareOutline.svg`},psSquare:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/psSquare.svg`},psTrackpadNavigate:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/psTrackpadNavigate.svg`},psTrackpadPressCenter:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/psTrackpadPressCenter.svg`},psTrackpadPressLeft:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/psTrackpadPressLeft.svg`},psTrackpadPressRight:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/psTrackpadPressRight.svg`},psTrackpadSwipeDown:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/psTrackpadSwipeDown.svg`},psTrackpadSwipeLeft:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/psTrackpadSwipeLeft.svg`},psTrackpadSwipeRight:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/psTrackpadSwipeRight.svg`},psTrackpadSwipeUp:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/psTrackpadSwipeUp.svg`},psTriangleOutline:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/psTriangleOutline.svg`},psTriangle:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/psTriangle.svg`},xboxAOutline:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/xboxAOutline.svg`},xboxBOutline:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/xboxBOutline.svg`},xboxLSButtonArrowDown:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/xboxLSButtonArrowDown.svg`},xboxRSButtonArrowDown:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/xboxRSButtonArrowDown.svg`},xboxXAxisLeft:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/xboxXAxisLeft.svg`},xboxXAxisRight:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/xboxXAxisRight.svg`},xboxXOutline:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/xboxXOutline.svg`},xboxXRotLeft:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/xboxXRotLeft.svg`},xboxXRotRight:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/xboxXRotRight.svg`},xboxYAxisDown:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/xboxYAxisDown.svg`},xboxYAxisUp:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/xboxYAxisUp.svg`},xboxYOutline:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/xboxYOutline.svg`},xboxYRotDown:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/xboxYRotDown.svg`},xboxYRotUp:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/xboxYRotUp.svg`},cableSection:{glyph:``,size:24,tags:[`material`,`beam`,`strap`],fileSvg:`svg/cableSection.svg`},strapHook:{glyph:``,size:24,tags:[`material`,`strap`],fileSvg:`svg/strapHook.svg`},strapRatchet:{glyph:``,size:24,tags:[`material`,`strap`],fileSvg:`svg/strapRatchet.svg`},carFastReverse:{glyph:``,size:24,tags:[`vehicle`],fileSvg:`svg/carFastReverse.svg`},carsChase:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/carsChase.svg`},carsFlee:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/carsFlee.svg`},gaugeFull:{glyph:``,size:24,tags:[`poi`],fileSvg:`svg/gaugeFull.svg`},hammerParticles:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/hammerParticles.svg`},kbArrowsDown:{glyph:``,size:24,tags:[`keyboard`,`controls`],fileSvg:`svg/kbArrowsDown.svg`},kbArrowsLeftRight:{glyph:``,size:24,tags:[`keyboard`,`controls`],fileSvg:`svg/kbArrowsLeftRight.svg`},kbArrowsLeft:{glyph:``,size:24,tags:[`keyboard`,`controls`],fileSvg:`svg/kbArrowsLeft.svg`},kbArrowsOutline:{glyph:``,size:24,tags:[`keyboard`,`controls`],fileSvg:`svg/kbArrowsOutline.svg`},kbArrowsRight:{glyph:``,size:24,tags:[`keyboard`,`controls`],fileSvg:`svg/kbArrowsRight.svg`},kbArrowsSolid:{glyph:``,size:24,tags:[`keyboard`,`controls`],fileSvg:`svg/kbArrowsSolid.svg`},kbArrowsUpDown:{glyph:``,size:24,tags:[`keyboard`,`controls`],fileSvg:`svg/kbArrowsUpDown.svg`},kbArrowsUp:{glyph:``,size:24,tags:[`keyboard`,`controls`],fileSvg:`svg/kbArrowsUp.svg`},magicWand:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/magicWand.svg`},psDLeftRight:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/psDLeftRight.svg`},psDUpDown:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/psDUpDown.svg`},pushBackward:{glyph:``,size:24,tags:[`physics`,`force`],fileSvg:`svg/pushBackward.svg`},pushDown:{glyph:``,size:24,tags:[`physics`,`force`],fileSvg:`svg/pushDown.svg`},pushForward:{glyph:``,size:24,tags:[`physics`,`force`],fileSvg:`svg/pushForward.svg`},rangeboxHi:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/rangeboxHi.svg`},rangeboxLo:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/rangeboxLo.svg`},routeSimpleFlag:{glyph:``,size:24,tags:[`route`,`traffic`],fileSvg:`svg/routeSimpleFlag.svg`},xboxDLeftRight:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/xboxDLeftRight.svg`},xboxDUpDown:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/xboxDUpDown.svg`},carsWrench:{glyph:``,size:24,tags:[`vehicle`,`select`],fileSvg:`svg/carsWrench.svg`},jointCycleMultiple:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/jointCycleMultiple.svg`},jointCycle:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/jointCycle.svg`},dice24:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/dice24.svg`},diceD6:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/diceD6.svg`},pathDice:{glyph:``,size:24,tags:[`camera`],fileSvg:`svg/pathDice.svg`},sunDown:{glyph:``,size:24,tags:[`environment`],fileSvg:`svg/sunDown.svg`},xmarkBold:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/xmarkBold.svg`},intakeTrumpets:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/intakeTrumpets.svg`},transmissionCvt:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/transmissionCvt.svg`},house:{glyph:``,size:24,tags:[`career`,`generic`,`garage`,`features`,`house`],fileSvg:`svg/house.svg`},playPause:{glyph:``,size:24,tags:[`playback`],fileSvg:`svg/playPause.svg`},picture:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/picture.svg`},auxUpDown:{glyph:``,size:24,tags:[`vehicle`,`features`,`equipment`],fileSvg:`svg/auxUpDown.svg`},bucketArmUpDown:{glyph:``,size:24,tags:[`vehicle`,`features`,`equipment`],fileSvg:`svg/bucketArmUpDown.svg`},bucketTilt:{glyph:``,size:24,tags:[`vehicle`,`features`,`equipment`],fileSvg:`svg/bucketTilt.svg`},bucketArmDown:{glyph:``,size:24,tags:[`vehicle`,`features`,`equipment`],fileSvg:`svg/bucketArmDown.svg`},bucketArmLevel:{glyph:``,size:24,tags:[`vehicle`,`features`,`equipment`],fileSvg:`svg/bucketArmLevel.svg`},bucketArmUp:{glyph:``,size:24,tags:[`vehicle`,`features`,`equipment`],fileSvg:`svg/bucketArmUp.svg`},bucketTiltDown:{glyph:``,size:24,tags:[`vehicle`,`features`,`equipment`],fileSvg:`svg/bucketTiltDown.svg`},bucketTiltLevel:{glyph:``,size:24,tags:[`vehicle`,`features`,`equipment`],fileSvg:`svg/bucketTiltLevel.svg`},bucketTiltUp:{glyph:``,size:24,tags:[`vehicle`,`features`,`equipment`],fileSvg:`svg/bucketTiltUp.svg`},dumpBedDown:{glyph:``,size:24,tags:[`vehicle`,`features`,`equipment`],fileSvg:`svg/dumpBedDown.svg`},dumpBedUpDown:{glyph:``,size:24,tags:[`vehicle`,`features`,`equipment`],fileSvg:`svg/dumpBedUpDown.svg`},dumpBedUp:{glyph:``,size:24,tags:[`vehicle`,`features`,`equipment`],fileSvg:`svg/dumpBedUp.svg`},beamCurrencyThin:{glyph:``,size:24,tags:[`career`,`currencies`],fileSvg:`svg/beamCurrencyThin.svg`},shieldCheckmarkProgressbar:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/shieldCheckmarkProgressbar.svg`}}),iconsBySize=Object.freeze({16:{arrowsUp:icons$2.arrowsUp,bigDot:icons$2.bigDot,connectorBold:icons$2.connectorBold,cornerTopRight:icons$2.cornerTopRight,plusBold:icons$2.plusBold,puzzlePieceBold:icons$2.puzzlePieceBold},24:{"4WD":icons$2[`4WD`],"9dividedby10":icons$2[`9dividedby10`],abandon:icons$2.abandon,ABSIndicator:icons$2.ABSIndicator,addItemPolygon:icons$2.addItemPolygon,addListItem:icons$2.addListItem,addPolygonVertex:icons$2.addPolygonVertex,adjust:icons$2.adjust,AIMicrochip:icons$2.AIMicrochip,AIRace:icons$2.AIRace,aperture:icons$2.aperture,arrowLargeDown:icons$2.arrowLargeDown,arrowLargeLeft:icons$2.arrowLargeLeft,arrowLargeRight:icons$2.arrowLargeRight,arrowLargeUp:icons$2.arrowLargeUp,arrowSmallDown:icons$2.arrowSmallDown,arrowSmallLeft:icons$2.arrowSmallLeft,arrowSmallRight:icons$2.arrowSmallRight,arrowSmallUp:icons$2.arrowSmallUp,arrowSolidLeft:icons$2.arrowSolidLeft,arrowSolidRight:icons$2.arrowSolidRight,autobahn:icons$2.autobahn,AWD:icons$2.AWD,axleLift:icons$2.axleLift,axleCenter:icons$2.axleCenter,axleFront:icons$2.axleFront,axleRear:icons$2.axleRear,bSpline:icons$2.bSpline,banknotes:icons$2.banknotes,barrelKnocker01:icons$2.barrelKnocker01,barrelKnocker02:icons$2.barrelKnocker02,beamCrashBarrier1:icons$2.beamCrashBarrier1,beamCrashBarrier2:icons$2.beamCrashBarrier2,beamCrashBarrier3:icons$2.beamCrashBarrier3,beamCurrency:icons$2.beamCurrency,beamNG:icons$2.beamNG,beamXPFull:icons$2.beamXPFull,beamXPLo:icons$2.beamXPLo,bezierPath1:icons$2.bezierPath1,bezierPath2:icons$2.bezierPath2,bicycle1:icons$2.bicycle1,bicycle2:icons$2.bicycle2,BNGFolder:icons$2.BNGFolder,BNGMicrochip:icons$2.BNGMicrochip,bollard:icons$2.bollard,bookmark:icons$2.bookmark,booleanIntersect:icons$2.booleanIntersect,boxDropOff01:icons$2.boxDropOff01,boxDropOff02:icons$2.boxDropOff02,boxDropOff03:icons$2.boxDropOff03,boxPickUp01:icons$2.boxPickUp01,boxPickUp02:icons$2.boxPickUp02,boxPickUp03:icons$2.boxPickUp03,boxPickUpDropOff01:icons$2.boxPickUpDropOff01,boxPickUpDropOff02:icons$2.boxPickUpDropOff02,boxTruck:icons$2.boxTruck,broom:icons$2.broom,bucketAdd:icons$2.bucketAdd,bucketSubtract:icons$2.bucketSubtract,bug:icons$2.bug,bulldozer:icons$2.bulldozer,bus:icons$2.bus,camera3Fourth1:icons$2.camera3Fourth1,cameraBack1:icons$2.cameraBack1,cameraFocusOnPath:icons$2.cameraFocusOnPath,cameraFocusOnVehicle1:icons$2.cameraFocusOnVehicle1,cameraFocusOnVehicle2:icons$2.cameraFocusOnVehicle2,cameraFocusTopDown:icons$2.cameraFocusTopDown,cameraFront1:icons$2.cameraFront1,cameraSideLeft:icons$2.cameraSideLeft,cameraSideLeft2:icons$2.cameraSideLeft2,cameraSideRight:icons$2.cameraSideRight,cameraSideRight2:icons$2.cameraSideRight2,cameraTop1:icons$2.cameraTop1,cannon:icons$2.cannon,carChase01:icons$2.carChase01,carCoin:icons$2.carCoin,carCoins:icons$2.carCoins,carCrash:icons$2.carCrash,carDealer:icons$2.carDealer,carOffroadOutlineRear:icons$2.carOffroadOutlineRear,carOffroadOutlineSide:icons$2.carOffroadOutlineSide,carOffroadRear:icons$2.carOffroadRear,carOffroadSide:icons$2.carOffroadSide,carSensors:icons$2.carSensors,carStarred:icons$2.carStarred,carToWheels:icons$2.carToWheels,carUp:icons$2.carUp,carWithLidar:icons$2.carWithLidar,car:icons$2.car,cardboardBox:icons$2.cardboardBox,carsChase02:icons$2.carsChase02,cars:icons$2.cars,catalog01:icons$2.catalog01,catalog02:icons$2.catalog02,catalog03:icons$2.catalog03,centrifugalClutchLocked03:icons$2.centrifugalClutchLocked03,centrifugalClutchUnlocked03:icons$2.centrifugalClutchUnlocked03,charge:icons$2.charge,charging:icons$2.charging,chartBars:icons$2.chartBars,checkboxOff:icons$2.checkboxOff,checkboxOn:icons$2.checkboxOn,checkmarkBold:icons$2.checkmarkBold,checkmark:icons$2.checkmark,circuitMicrochip:icons$2.circuitMicrochip,circuit:icons$2.circuit,clapperboard:icons$2.clapperboard,code:icons$2.code,cogDamaged:icons$2.cogDamaged,cogsDamaged:icons$2.cogsDamaged,cogs:icons$2.cogs,concreteRoadBlock:icons$2.concreteRoadBlock,coolantTemp:icons$2.coolantTemp,copy:icons$2.copy,crossroads1:icons$2.crossroads1,crossroads2:icons$2.crossroads2,cruiseDisable:icons$2.cruiseDisable,cruiseEnable:icons$2.cruiseEnable,cup:icons$2.cup,dataExchange:icons$2.dataExchange,day:icons$2.day,DCBattery:icons$2.DCBattery,decalRoad:icons$2.decalRoad,decal:icons$2.decal,deform:icons$2.deform,deliveryTruckArrows:icons$2.deliveryTruckArrows,deliveryTruck:icons$2.deliveryTruck,differentialFrontDefault:icons$2.differentialFrontDefault,differentialFrontLocked:icons$2.differentialFrontLocked,differentialMiddleDefault:icons$2.differentialMiddleDefault,differentialMiddleLocked:icons$2.differentialMiddleLocked,differentialRearDefault:icons$2.differentialRearDefault,differentialRearLocked:icons$2.differentialRearLocked,doorHandle:icons$2.doorHandle,doorIn:icons$2.doorIn,drag01:icons$2.drag01,drag02:icons$2.drag02,drift01:icons$2.drift01,drift02:icons$2.drift02,drivetrainGeneric:icons$2.drivetrainGeneric,drivetrainSpecial:icons$2.drivetrainSpecial,editCheckmark:icons$2.editCheckmark,edit:icons$2.edit,engine:icons$2.engine,ESCOff:icons$2.ESCOff,ESCOn:icons$2.ESCOn,ESC:icons$2.ESC,evade:icons$2.evade,exhaustValve:icons$2.exhaustValve,exit:icons$2.exit,export:icons$2.export,eyeOutlineClosed:icons$2.eyeOutlineClosed,eyeOutlineOpened:icons$2.eyeOutlineOpened,eyeSolidClosed:icons$2.eyeSolidClosed,eyeSolidOpened:icons$2.eyeSolidOpened,eyeWaves:icons$2.eyeWaves,facility02:icons$2.facility02,fastBackward:icons$2.fastBackward,fastForward:icons$2.fastForward,fastTravel:icons$2.fastTravel,filter:icons$2.filter,flagNew:icons$2.flagNew,flag:icons$2.flag,flatBulbBeam:icons$2.flatBulbBeam,flatbedTruck:icons$2.flatbedTruck,floppyDisk:icons$2.floppyDisk,fogLight:icons$2.fogLight,folder:icons$2.folder,forklift:icons$2.forklift,FPS:icons$2.FPS,fragile:icons$2.fragile,frontAxleMidpoint:icons$2.frontAxleMidpoint,frontBumperMidpoint:icons$2.frontBumperMidpoint,fuelPumpFilling:icons$2.fuelPumpFilling,fuelPump:icons$2.fuelPump,FWD:icons$2.FWD,gamepadOld:icons$2.gamepadOld,gamepad:icons$2.gamepad,garage01:icons$2.garage01,garage02:icons$2.garage02,garage03:icons$2.garage03,gaugeEmpty:icons$2.gaugeEmpty,globe:icons$2.globe,GPSMark:icons$2.GPSMark,GPSSolid:icons$2.GPSSolid,group:icons$2.group,gyroscopeMicrochip:icons$2.gyroscopeMicrochip,gyroscope:icons$2.gyroscope,hazardLights:icons$2.hazardLights,helmets:icons$2.helmets,help:icons$2.help,highBeam:icons$2.highBeam,HUD:icons$2.HUD,hydroPump1:icons$2.hydroPump1,hydroPump2:icons$2.hydroPump2,hydroPump3:icons$2.hydroPump3,hydroPump4:icons$2.hydroPump4,hydroPump5:icons$2.hydroPump5,hydroPump6:icons$2.hydroPump6,hydroPump7:icons$2.hydroPump7,hypermiling:icons$2.hypermiling,import:icons$2.import,infinity:icons$2.infinity,info:icons$2.info,jointLocked:icons$2.jointLocked,jointUnlocked:icons$2.jointUnlocked,jump:icons$2.jump,keyboard:icons$2.keyboard,keys1:icons$2.keys1,keys2:icons$2.keys2,lampPost1:icons$2.lampPost1,lampPost2:icons$2.lampPost2,lampPost3:icons$2.lampPost3,laneProperties:icons$2.laneProperties,language:icons$2.language,laptop:icons$2.laptop,lidarPatternFullArcHighFreq:icons$2.lidarPatternFullArcHighFreq,lidarPatternFullArcMidFreq:icons$2.lidarPatternFullArcMidFreq,lidarPatternNarrowArc:icons$2.lidarPatternNarrowArc,lidar:icons$2.lidar,lightGarageG11:icons$2.lightGarageG11,lightGarageG12:icons$2.lightGarageG12,lightGarageG13:icons$2.lightGarageG13,lightGarageG14:icons$2.lightGarageG14,lightGarageG21:icons$2.lightGarageG21,lightGarageG22:icons$2.lightGarageG22,lightGarageG23:icons$2.lightGarageG23,lightGarageG24:icons$2.lightGarageG24,lightGarageG31:icons$2.lightGarageG31,lightGarageG32:icons$2.lightGarageG32,lightGarageG33:icons$2.lightGarageG33,lightGarageG34:icons$2.lightGarageG34,lightrunner:icons$2.lightrunner,limiterEnable:icons$2.limiterEnable,lineToTerrain:icons$2.lineToTerrain,link2:icons$2.link2,link:icons$2.link,listBig:icons$2.listBig,listIndented:icons$2.listIndented,listSmall:icons$2.listSmall,location1:icons$2.location1,location2:icons$2.location2,lockClosed:icons$2.lockClosed,lockOpened:icons$2.lockOpened,longRangeBeam1:icons$2.longRangeBeam1,longRangeBeam2:icons$2.longRangeBeam2,lowBeam:icons$2.lowBeam,magnetOnSurface:icons$2.magnetOnSurface,mapWithEmitter:icons$2.mapWithEmitter,mapPoint:icons$2.mapPoint,material:icons$2.material,mathDivide:icons$2.mathDivide,mathGreaterOrEqualThan:icons$2.mathGreaterOrEqualThan,mathGreaterThan:icons$2.mathGreaterThan,mathLessOrEqualThan:icons$2.mathLessOrEqualThan,mathLessThan:icons$2.mathLessThan,mathMinus:icons$2.mathMinus,mathMultiply:icons$2.mathMultiply,mathPlus:icons$2.mathPlus,medal:icons$2.medal,mesh4Cells:icons$2.mesh4Cells,mesh9Cells:icons$2.mesh9Cells,meshFence:icons$2.meshFence,meshRoad:icons$2.meshRoad,midRangeBeam1:icons$2.midRangeBeam1,midRangeBeam2:icons$2.midRangeBeam2,minusRes:icons$2.minusRes,minus:icons$2.minus,mirrorInteriorMiddle:icons$2.mirrorInteriorMiddle,mirrorLeftBigBottomWideAngle:icons$2.mirrorLeftBigBottomWideAngle,mirrorLeftBigTop:icons$2.mirrorLeftBigTop,mirrorLeftBig:icons$2.mirrorLeftBig,mirrorLeftBonnet:icons$2.mirrorLeftBonnet,mirrorLeftDefault:icons$2.mirrorLeftDefault,mirrorRightBigBottomWideAngle:icons$2.mirrorRightBigBottomWideAngle,mirrorRightBigTop:icons$2.mirrorRightBigTop,mirrorRightBig:icons$2.mirrorRightBig,mirrorRightBonnet:icons$2.mirrorRightBonnet,mirrorRightDefault:icons$2.mirrorRightDefault,mirrorRoundWideAngle:icons$2.mirrorRoundWideAngle,mirrorTopWideAngle:icons$2.mirrorTopWideAngle,missionCheckboxCross:icons$2.missionCheckboxCross,mouseLMB:icons$2.mouseLMB,mouseMMB:icons$2.mouseMMB,mouseRMB:icons$2.mouseRMB,mouseWheel:icons$2.mouseWheel,mouseXAxis:icons$2.mouseXAxis,mouseXYAxis:icons$2.mouseXYAxis,mouseYAxis:icons$2.mouseYAxis,mouse:icons$2.mouse,move02:icons$2.move02,move:icons$2.move,movieCamera:icons$2.movieCamera,music:icons$2.music,N2OButton:icons$2.N2OButton,N2OHoriz:icons$2.N2OHoriz,N2OVert:icons$2.N2OVert,nextTrack:icons$2.nextTrack,night:icons$2.night,noNameControllerButton:icons$2.noNameControllerButton,nodeAddFirst01:icons$2.nodeAddFirst01,nodeAddFirst02:icons$2.nodeAddFirst02,nodeAddLast02:icons$2.nodeAddLast02,nodeAddMiddle01:icons$2.nodeAddMiddle01,nodeAddMiddle02:icons$2.nodeAddMiddle02,nodeAdd:icons$2.nodeAdd,nodeLast01:icons$2.nodeLast01,nodeRemove:icons$2.nodeRemove,odometerKM:icons$2.odometerKM,odometerMI:icons$2.odometerMI,odometer:icons$2.odometer,oilPressureIndicator:icons$2.oilPressureIndicator,order:icons$2.order,organization:icons$2.organization,palmCrossed:icons$2.palmCrossed,paperKnife:icons$2.paperKnife,parkingIndicator:icons$2.parkingIndicator,parking:icons$2.parking,pathArc:icons$2.pathArc,pathAroundObstacle:icons$2.pathAroundObstacle,pathLine:icons$2.pathLine,pathSpiral:icons$2.pathSpiral,pauseRound:icons$2.pauseRound,pause:icons$2.pause,personSolid:icons$2.personSolid,person:icons$2.person,photo:icons$2.photo,placeholder:icons$2.placeholder,playRound:icons$2.playRound,play:icons$2.play,playlist:icons$2.playlist,plusGarage1:icons$2.plusGarage1,plusGarage2:icons$2.plusGarage2,plusGarage3:icons$2.plusGarage3,plusGarage4:icons$2.plusGarage4,plusSet:icons$2.plusSet,plus:icons$2.plus,positionLights:icons$2.positionLights,powerGauge01:icons$2.powerGauge01,powerGauge02:icons$2.powerGauge02,powerGauge03:icons$2.powerGauge03,powerGauge04:icons$2.powerGauge04,powerGauge05:icons$2.powerGauge05,powerOnOff:icons$2.powerOnOff,prevTrack:icons$2.prevTrack,publisher:icons$2.publisher,puzzleModule:icons$2.puzzleModule,raceFlag:icons$2.raceFlag,radarIdeal:icons$2.radarIdeal,radarRoundIdeal:icons$2.radarRoundIdeal,radarRound:icons$2.radarRound,radar:icons$2.radar,rangeboxHi2:icons$2.rangeboxHi2,rangeboxHi4:icons$2.rangeboxHi4,rangeboxHiA:icons$2.rangeboxHiA,rangeboxLo2:icons$2.rangeboxLo2,rangeboxLo4:icons$2.rangeboxLo4,rangeboxLoA:icons$2.rangeboxLoA,rearAxleMidpoint:icons$2.rearAxleMidpoint,rearBumperMidpoint:icons$2.rearBumperMidpoint,reconfigure:icons$2.reconfigure,redo:icons$2.redo,reflectNot:icons$2.reflectNot,reflect:icons$2.reflect,rename:icons$2.rename,replay:icons$2.replay,restart:icons$2.restart,roadDividerLinesDecal:icons$2.roadDividerLinesDecal,roadEdgeLineDecal:icons$2.roadEdgeLineDecal,roadEndLineDecal:icons$2.roadEndLineDecal,roadFace:icons$2.roadFace,roadInfo:icons$2.roadInfo,roadMarkingOutline:icons$2.roadMarkingOutline,roadMarkingSolid:icons$2.roadMarkingSolid,roadOutline:icons$2.roadOutline,roadRefPathDecal:icons$2.roadRefPathDecal,roadRefPath:icons$2.roadRefPath,roadStartLineDecal:icons$2.roadStartLineDecal,road:icons$2.road,rockCrawling01:icons$2.rockCrawling01,rockCrawling02:icons$2.rockCrawling02,routeAdd:icons$2.routeAdd,routeComplex:icons$2.routeComplex,routeSimple:icons$2.routeSimple,runScript:icons$2.runScript,RWD:icons$2.RWD,saveAs1:icons$2.saveAs1,scan:icons$2.scan,search:icons$2.search,semiTrailer:icons$2.semiTrailer,semiTruckCabover:icons$2.semiTruckCabover,semiTruckUS:icons$2.semiTruckUS,semiTruck:icons$2.semiTruck,shortRangeBeam1:icons$2.shortRangeBeam1,shortRangeBeam2:icons$2.shortRangeBeam2,signal01a:icons$2.signal01a,signal02a:icons$2.signal02a,signal03a:icons$2.signal03a,signal04a:icons$2.signal04a,signal05a:icons$2.signal05a,slashLeft:icons$2.slashLeft,slashRight:icons$2.slashRight,smallTrailer:icons$2.smallTrailer,smartphone1:icons$2.smartphone1,smartphone2:icons$2.smartphone2,snowflake:icons$2.snowflake,soundFadeOut:icons$2.soundFadeOut,soundLimit:icons$2.soundLimit,soundLoud:icons$2.soundLoud,soundMonoL:icons$2.soundMonoL,soundMonoR:icons$2.soundMonoR,soundOff:icons$2.soundOff,soundQuiet:icons$2.soundQuiet,soundStereo:icons$2.soundStereo,soundWave01:icons$2.soundWave01,soundWave02:icons$2.soundWave02,sphereOnPathNumber:icons$2.sphereOnPathNumber,sphereOnPath:icons$2.sphereOnPath,sphericalBeam:icons$2.sphericalBeam,spoilerLift:icons$2.spoilerLift,sprayCan:icons$2.sprayCan,stack3:icons$2.stack3,star:icons$2.star,starSecondary:icons$2.starSecondary,steeringWheelCommon:icons$2.steeringWheelCommon,steeringWheelSporty:icons$2.steeringWheelSporty,stopwatchArrows01:icons$2.stopwatchArrows01,stopwatchArrows02:icons$2.stopwatchArrows02,stopwatchSectionOutlinedEnd:icons$2.stopwatchSectionOutlinedEnd,stopwatchSectionOutlinedStart:icons$2.stopwatchSectionOutlinedStart,stopwatchSectionSolidEnd:icons$2.stopwatchSectionSolidEnd,stopwatchSectionSolidStart:icons$2.stopwatchSectionSolidStart,strobeLights:icons$2.strobeLights,sunRise:icons$2.sunRise,survellianceCamera:icons$2.survellianceCamera,suspension01:icons$2.suspension01,suspension02:icons$2.suspension02,switchBlock:icons$2.switchBlock,switchOutline:icons$2.switchOutline,sync:icons$2.sync,synchro01:icons$2.synchro01,synchro02:icons$2.synchro02,tankerTrailer:icons$2.tankerTrailer,targetJump:icons$2.targetJump,taxiCar1:icons$2.taxiCar1,taxiCar3:icons$2.taxiCar3,taxiCarT:icons$2.taxiCarT,taxiCheckerLamp:icons$2.taxiCheckerLamp,terrainToLine:icons$2.terrainToLine,terrain:icons$2.terrain,thinBulbBeam:icons$2.thinBulbBeam,thinnerBulbBeam:icons$2.thinnerBulbBeam,thisSideUp:icons$2.thisSideUp,tiles:icons$2.tiles,timer:icons$2.timer,tireDirection3Fourth2:icons$2.tireDirection3Fourth2,tireDirection3Fourth3:icons$2.tireDirection3Fourth3,tireDirectionFront2:icons$2.tireDirectionFront2,tireDirectionSide2:icons$2.tireDirectionSide2,tireDirectionTop2:icons$2.tireDirectionTop2,tirePressureDecrease01:icons$2.tirePressureDecrease01,tirePressureDecrease02:icons$2.tirePressureDecrease02,tirePressureGaugeAlt01:icons$2.tirePressureGaugeAlt01,tirePressureGaugeAlt02:icons$2.tirePressureGaugeAlt02,tirePressureGaugeAlt03:icons$2.tirePressureGaugeAlt03,tirePressureGaugeOutlined01:icons$2.tirePressureGaugeOutlined01,tirePressureGaugeOutlined02:icons$2.tirePressureGaugeOutlined02,tirePressureGaugeOutlined03:icons$2.tirePressureGaugeOutlined03,tirePressureGaugeSolid01:icons$2.tirePressureGaugeSolid01,tirePressureGaugeSolid02:icons$2.tirePressureGaugeSolid02,tirePressureGaugeSolid03:icons$2.tirePressureGaugeSolid03,tirePressureIncrease01:icons$2.tirePressureIncrease01,tirePressureIncrease02:icons$2.tirePressureIncrease02,tirePressureStopLine:icons$2.tirePressureStopLine,tirePressureStopOctoLine:icons$2.tirePressureStopOctoLine,tirePressureStopOctoSolid:icons$2.tirePressureStopOctoSolid,tirePressureStopSolid:icons$2.tirePressureStopSolid,toCOMWithWheels:icons$2.toCOMWithWheels,toCOM:icons$2.toCOM,toGarage:icons$2.toGarage,touch:icons$2.touch,tow:icons$2.tow,tractionControl:icons$2.tractionControl,trafficCone:icons$2.trafficCone,transform:icons$2.transform,transmissionA:icons$2.transmissionA,transmissionM:icons$2.transmissionM,transparencyMask:icons$2.transparencyMask,trashBin1:icons$2.trashBin1,trashBin2:icons$2.trashBin2,triangleBeam:icons$2.triangleBeam,trim:icons$2.trim,tulipBeam:icons$2.tulipBeam,tunnel:icons$2.tunnel,turbine:icons$2.turbine,twoRoadsAdd:icons$2.twoRoadsAdd,twoRoadsCrossAdd:icons$2.twoRoadsCrossAdd,twoRoadsLink:icons$2.twoRoadsLink,twoUnicyclesOnly:icons$2.twoUnicyclesOnly,undo:icons$2.undo,ungroup:icons$2.ungroup,unlink:icons$2.unlink,vehicleDoorsClose:icons$2.vehicleDoorsClose,vehicleDoorsOpen:icons$2.vehicleDoorsOpen,vehicleDoors:icons$2.vehicleDoors,vehicleFeatures01:icons$2.vehicleFeatures01,vehicleFeatures02:icons$2.vehicleFeatures02,vehicleFeatures03:icons$2.vehicleFeatures03,vehicleHood:icons$2.vehicleHood,vehicleTrunk:icons$2.vehicleTrunk,view:icons$2.view,voucherDiagonal1:icons$2.voucherDiagonal1,voucherDiagonal2:icons$2.voucherDiagonal2,voucherDiagonal3:icons$2.voucherDiagonal3,voucherHorizontal1:icons$2.voucherHorizontal1,voucherHorizontal2:icons$2.voucherHorizontal2,voucherHorizontal3:icons$2.voucherHorizontal3,wavesSignalReceived:icons$2.wavesSignalReceived,wavesSignalSentLeft:icons$2.wavesSignalSentLeft,wavesSignalSentRight:icons$2.wavesSignalSentRight,weather:icons$2.weather,weight:icons$2.weight,wheelHubLocked01:icons$2.wheelHubLocked01,wheelHubUnlocked01:icons$2.wheelHubUnlocked01,wigwags:icons$2.wigwags,wrench:icons$2.wrench,xboxA:icons$2.xboxA,xboxB:icons$2.xboxB,xboxDDefaultOutline:icons$2.xboxDDefaultOutline,xboxDDefaultSolid:icons$2.xboxDDefaultSolid,xboxDDown:icons$2.xboxDDown,xboxDLeft:icons$2.xboxDLeft,xboxDRight:icons$2.xboxDRight,xboxDUp:icons$2.xboxDUp,xboxLB:icons$2.xboxLB,xboxLSButton:icons$2.xboxLSButton,xboxLT:icons$2.xboxLT,xboxMenu:icons$2.xboxMenu,xboxRB:icons$2.xboxRB,xboxRSButton:icons$2.xboxRSButton,xboxRT:icons$2.xboxRT,xboxThumbL:icons$2.xboxThumbL,xboxThumbR:icons$2.xboxThumbR,xboxView:icons$2.xboxView,xboxXAxis:icons$2.xboxXAxis,xboxXRot:icons$2.xboxXRot,xboxX:icons$2.xboxX,xboxYAxis:icons$2.xboxYAxis,xboxYRot:icons$2.xboxYRot,xboxY:icons$2.xboxY,danger:icons$2.danger,droplet:icons$2.droplet,envelope:icons$2.envelope,fireDiamond:icons$2.fireDiamond,rocks:icons$2.rocks,xmark:icons$2.xmark,scale:icons$2.scale,locationDestination:icons$2.locationDestination,locationSource:icons$2.locationSource,accelerationKPH:icons$2.accelerationKPH,accelerationMPH:icons$2.accelerationMPH,boxTruckFast:icons$2.boxTruckFast,colorBrightnessSun:icons$2.colorBrightnessSun,colorCirclePalette:icons$2.colorCirclePalette,colorPalette:icons$2.colorPalette,colorSaturation:icons$2.colorSaturation,sortAscDown02:icons$2.sortAscDown02,sortAscDown:icons$2.sortAscDown,sortAscUp02:icons$2.sortAscUp02,sortAscUp:icons$2.sortAscUp,sortDescDown02:icons$2.sortDescDown02,sortDescDown:icons$2.sortDescDown,sortDescUp02:icons$2.sortDescUp02,sortDescUp:icons$2.sortDescUp,cardboardBoxCoins:icons$2.cardboardBoxCoins,lasso:icons$2.lasso,materialGlossy:icons$2.materialGlossy,materialMetal:icons$2.materialMetal,materialRoughness:icons$2.materialRoughness,materialTransparency01:icons$2.materialTransparency01,materialTransparency02:icons$2.materialTransparency02,metal01:icons$2.metal01,removeItemPolygon:icons$2.removeItemPolygon,removeListItem:icons$2.removeListItem,sortAsc:icons$2.sortAsc,sortDesc:icons$2.sortDesc,surfaceRoughness02:icons$2.surfaceRoughness02,shieldCheckmark:icons$2.shieldCheckmark,shieldHandCheckmark:icons$2.shieldHandCheckmark,shieldHandPlus:icons$2.shieldHandPlus,doorFrontCoins:icons$2.doorFrontCoins,doorFront:icons$2.doorFront,engineCoins:icons$2.engineCoins,exhaustMufflerCoins:icons$2.exhaustMufflerCoins,exhaustMuffler:icons$2.exhaustMuffler,headlightCoins:icons$2.headlightCoins,headlight:icons$2.headlight,tire3FourthCoins:icons$2.tire3FourthCoins,tire3Fourth:icons$2.tire3Fourth,turbineCoins:icons$2.turbineCoins,wheelDiscCoins:icons$2.wheelDiscCoins,wheelDisc:icons$2.wheelDisc,bridgeWithRiver:icons$2.bridgeWithRiver,gizmosOutline:icons$2.gizmosOutline,gizmosSolid:icons$2.gizmosSolid,highwayRoad3To2Merge01:icons$2.highwayRoad3To2Merge01,highwayRoad3To2Merge02:icons$2.highwayRoad3To2Merge02,highwayToUrbanRoadTransition01:icons$2.highwayToUrbanRoadTransition01,highwayToUrbanRoadTransition02:icons$2.highwayToUrbanRoadTransition02,pedestrianCrossing01:icons$2.pedestrianCrossing01,polygonalCube:icons$2.polygonalCube,roadEditOutline:icons$2.roadEditOutline,roadEditSolid:icons$2.roadEditSolid,roadFolderPlus:icons$2.roadFolderPlus,roadFolder:icons$2.roadFolder,roadGuideArrowOutline:icons$2.roadGuideArrowOutline,roadGuideArrowSolid:icons$2.roadGuideArrowSolid,roadOutlineMesh:icons$2.roadOutlineMesh,roadPedestrianCrossing02:icons$2.roadPedestrianCrossing02,roadProfileWithCheckmark:icons$2.roadProfileWithCheckmark,roadProfile:icons$2.roadProfile,roadRoundaboutJunction:icons$2.roadRoundaboutJunction,roadSidewalkTransition:icons$2.roadSidewalkTransition,roadStackPlus:icons$2.roadStackPlus,roadStack:icons$2.roadStack,roadTJunction:icons$2.roadTJunction,roadXJunction:icons$2.roadXJunction,roadYJunction:icons$2.roadYJunction,shoppingCart:icons$2.shoppingCart,singleLineToTerrain:icons$2.singleLineToTerrain,sphereOnMesh:icons$2.sphereOnMesh,twoLinesToTerrain:icons$2.twoLinesToTerrain,urbanRoad3To2Merge01:icons$2.urbanRoad3To2Merge01,urbanRoad3To2Merge02:icons$2.urbanRoad3To2Merge02,urbanRoadToHighwayTransition01:icons$2.urbanRoadToHighwayTransition01,urbanRoadToHighwayTransition02:icons$2.urbanRoadToHighwayTransition02,floppyDiskPlus:icons$2.floppyDiskPlus,highwayMerge:icons$2.highwayMerge,highwaySeparate:icons$2.highwaySeparate,highwayShoulderMerge:icons$2.highwayShoulderMerge,terrainToSingleLine:icons$2.terrainToSingleLine,terrainToTwoLines:icons$2.terrainToTwoLines,urbanRoadMerge:icons$2.urbanRoadMerge,urbanRoadSeparate:icons$2.urbanRoadSeparate,urbanShoulderMerge:icons$2.urbanShoulderMerge,discharging:icons$2.discharging,BNGChat:icons$2.BNGChat,chatBubble:icons$2.chatBubble,busTilted:icons$2.busTilted,cameraFarClip:icons$2.cameraFarClip,cameraNearClip:icons$2.cameraNearClip,explosion:icons$2.explosion,fireExtinguisher:icons$2.fireExtinguisher,fire:icons$2.fire,jointLockedMultiple:icons$2.jointLockedMultiple,jointUnlockedMultiple:icons$2.jointUnlockedMultiple,toggleOff:icons$2.toggleOff,toggleOn:icons$2.toggleOn,viewFarClip:icons$2.viewFarClip,viewNearClip:icons$2.viewNearClip,twoArrowsHorizontal:icons$2.twoArrowsHorizontal,twoArrowsVertical:icons$2.twoArrowsVertical,circleSlashed:icons$2.circleSlashed,scissorsSlashed:icons$2.scissorsSlashed,scissors:icons$2.scissors,airPuffRight1:icons$2.airPuffRight1,airPuffUp1:icons$2.airPuffUp1,arrowsReplace:icons$2.arrowsReplace,arrowsShuffle:icons$2.arrowsShuffle,arrowsSwitch:icons$2.arrowsSwitch,carClock:icons$2.carClock,carFast:icons$2.carFast,carNumber1:icons$2.carNumber1,carNumber2:icons$2.carNumber2,carNumber3:icons$2.carNumber3,carNumber4:icons$2.carNumber4,carNumber5:icons$2.carNumber5,carNumber6:icons$2.carNumber6,carNumber7:icons$2.carNumber7,carNumber8:icons$2.carNumber8,carNumber9:icons$2.carNumber9,carPlus:icons$2.carPlus,carsChange:icons$2.carsChange,carsFollow:icons$2.carsFollow,doorFrontDetached:icons$2.doorFrontDetached,forceFieldPull1:icons$2.forceFieldPull1,forceFieldPull2:icons$2.forceFieldPull2,forceFieldPull3:icons$2.forceFieldPull3,forceFieldPush1:icons$2.forceFieldPush1,forceFieldPush2:icons$2.forceFieldPush2,forceFieldPush3:icons$2.forceFieldPush3,garageNumber1:icons$2.garageNumber1,garageNumber2:icons$2.garageNumber2,garageNumber3:icons$2.garageNumber3,garageNumber4:icons$2.garageNumber4,garageNumber5:icons$2.garageNumber5,garageNumber6:icons$2.garageNumber6,garageNumber7:icons$2.garageNumber7,garageNumber8:icons$2.garageNumber8,garageNumber9:icons$2.garageNumber9,hingeBroken:icons$2.hingeBroken,loadMesh:icons$2.loadMesh,octagonBrick:icons$2.octagonBrick,octagon:icons$2.octagon,pushUp:icons$2.pushUp,saveMesh:icons$2.saveMesh,square:icons$2.square,tireAirPuff:icons$2.tireAirPuff,tireDeflated:icons$2.tireDeflated,trafficLight:icons$2.trafficLight,enter:icons$2.enter,pedestrianRunning:icons$2.pedestrianRunning,pedestrianStanding:icons$2.pedestrianStanding,seatArrowIn:icons$2.seatArrowIn,seatArrowOut:icons$2.seatArrowOut,seatVArrowIn:icons$2.seatVArrowIn,seatVArrowOut:icons$2.seatVArrowOut,vehicleArrowIn:icons$2.vehicleArrowIn,vehicleArrowOut:icons$2.vehicleArrowOut,leverFrontOperate:icons$2.leverFrontOperate,leverSideDown:icons$2.leverSideDown,leverSideOperate:icons$2.leverSideOperate,leverSideUp:icons$2.leverSideUp,medalEmpty:icons$2.medalEmpty,medalStar:icons$2.medalStar,seatArrowInLeft:icons$2.seatArrowInLeft,seatArrowOutLeft:icons$2.seatArrowOutLeft,seatVArrowInLeft:icons$2.seatVArrowInLeft,seatVArrowOutLeft:icons$2.seatVArrowOutLeft,badgeRoundEmpty:icons$2.badgeRoundEmpty,badgeRoundStar:icons$2.badgeRoundStar,badgeRound:icons$2.badgeRound,badge:icons$2.badge,houseWrenchRoof:icons$2.houseWrenchRoof,houseWrench:icons$2.houseWrench,eject:icons$2.eject,rallyHelmet3To4:icons$2.rallyHelmet3To4,rallyHelmet:icons$2.rallyHelmet,test:icons$2.test,globeSimpleNotSign:icons$2.globeSimpleNotSign,globeSimplified:icons$2.globeSimplified,radialMenu:icons$2.radialMenu,branch:icons$2.branch,NA:icons$2.NA,psCircleOutline:icons$2.psCircleOutline,psCircle:icons$2.psCircle,psCreate2:icons$2.psCreate2,psCreate:icons$2.psCreate,psCrossOutline:icons$2.psCrossOutline,psCross:icons$2.psCross,psDDefaultOutline:icons$2.psDDefaultOutline,psDDefaultSolid:icons$2.psDDefaultSolid,psDDown:icons$2.psDDown,psDLeft:icons$2.psDLeft,psDRight:icons$2.psDRight,psDUp:icons$2.psDUp,psL1:icons$2.psL1,psL2:icons$2.psL2,psL3ButtonArrowDown:icons$2.psL3ButtonArrowDown,psL3Button:icons$2.psL3Button,psLSXLeft:icons$2.psLSXLeft,psLSXRight:icons$2.psLSXRight,psLSX:icons$2.psLSX,psLSYDown:icons$2.psLSYDown,psLSYUp:icons$2.psLSYUp,psLSY:icons$2.psLSY,psLS:icons$2.psLS,psMenu2:icons$2.psMenu2,psMenu:icons$2.psMenu,psR1:icons$2.psR1,psR2:icons$2.psR2,psR3ButtonArrowDown:icons$2.psR3ButtonArrowDown,psR3Button:icons$2.psR3Button,psRSXLeft:icons$2.psRSXLeft,psRSXRight:icons$2.psRSXRight,psRSX:icons$2.psRSX,psRSYDown:icons$2.psRSYDown,psRSYUp:icons$2.psRSYUp,psRSY:icons$2.psRSY,psRS:icons$2.psRS,psSquareOutline:icons$2.psSquareOutline,psSquare:icons$2.psSquare,psTrackpadNavigate:icons$2.psTrackpadNavigate,psTrackpadPressCenter:icons$2.psTrackpadPressCenter,psTrackpadPressLeft:icons$2.psTrackpadPressLeft,psTrackpadPressRight:icons$2.psTrackpadPressRight,psTrackpadSwipeDown:icons$2.psTrackpadSwipeDown,psTrackpadSwipeLeft:icons$2.psTrackpadSwipeLeft,psTrackpadSwipeRight:icons$2.psTrackpadSwipeRight,psTrackpadSwipeUp:icons$2.psTrackpadSwipeUp,psTriangleOutline:icons$2.psTriangleOutline,psTriangle:icons$2.psTriangle,xboxAOutline:icons$2.xboxAOutline,xboxBOutline:icons$2.xboxBOutline,xboxLSButtonArrowDown:icons$2.xboxLSButtonArrowDown,xboxRSButtonArrowDown:icons$2.xboxRSButtonArrowDown,xboxXAxisLeft:icons$2.xboxXAxisLeft,xboxXAxisRight:icons$2.xboxXAxisRight,xboxXOutline:icons$2.xboxXOutline,xboxXRotLeft:icons$2.xboxXRotLeft,xboxXRotRight:icons$2.xboxXRotRight,xboxYAxisDown:icons$2.xboxYAxisDown,xboxYAxisUp:icons$2.xboxYAxisUp,xboxYOutline:icons$2.xboxYOutline,xboxYRotDown:icons$2.xboxYRotDown,xboxYRotUp:icons$2.xboxYRotUp,cableSection:icons$2.cableSection,strapHook:icons$2.strapHook,strapRatchet:icons$2.strapRatchet,carFastReverse:icons$2.carFastReverse,carsChase:icons$2.carsChase,carsFlee:icons$2.carsFlee,gaugeFull:icons$2.gaugeFull,hammerParticles:icons$2.hammerParticles,kbArrowsDown:icons$2.kbArrowsDown,kbArrowsLeftRight:icons$2.kbArrowsLeftRight,kbArrowsLeft:icons$2.kbArrowsLeft,kbArrowsOutline:icons$2.kbArrowsOutline,kbArrowsRight:icons$2.kbArrowsRight,kbArrowsSolid:icons$2.kbArrowsSolid,kbArrowsUpDown:icons$2.kbArrowsUpDown,kbArrowsUp:icons$2.kbArrowsUp,magicWand:icons$2.magicWand,psDLeftRight:icons$2.psDLeftRight,psDUpDown:icons$2.psDUpDown,pushBackward:icons$2.pushBackward,pushDown:icons$2.pushDown,pushForward:icons$2.pushForward,rangeboxHi:icons$2.rangeboxHi,rangeboxLo:icons$2.rangeboxLo,routeSimpleFlag:icons$2.routeSimpleFlag,xboxDLeftRight:icons$2.xboxDLeftRight,xboxDUpDown:icons$2.xboxDUpDown,carsWrench:icons$2.carsWrench,jointCycleMultiple:icons$2.jointCycleMultiple,jointCycle:icons$2.jointCycle,dice24:icons$2.dice24,diceD6:icons$2.diceD6,pathDice:icons$2.pathDice,sunDown:icons$2.sunDown,xmarkBold:icons$2.xmarkBold,intakeTrumpets:icons$2.intakeTrumpets,transmissionCvt:icons$2.transmissionCvt,house:icons$2.house,playPause:icons$2.playPause,picture:icons$2.picture,auxUpDown:icons$2.auxUpDown,bucketArmUpDown:icons$2.bucketArmUpDown,bucketTilt:icons$2.bucketTilt,bucketArmDown:icons$2.bucketArmDown,bucketArmLevel:icons$2.bucketArmLevel,bucketArmUp:icons$2.bucketArmUp,bucketTiltDown:icons$2.bucketTiltDown,bucketTiltLevel:icons$2.bucketTiltLevel,bucketTiltUp:icons$2.bucketTiltUp,dumpBedDown:icons$2.dumpBedDown,dumpBedUpDown:icons$2.dumpBedUpDown,dumpBedUp:icons$2.dumpBedUp,beamCurrencyThin:icons$2.beamCurrencyThin,shieldCheckmarkProgressbar:icons$2.shieldCheckmarkProgressbar},48:{AIL:icons$2.AIL,arrowLeftOutline:icons$2.arrowLeftOutline,arrowRightOutline:icons$2.arrowRightOutline,automaticTransmissionL:icons$2.automaticTransmissionL,beamsNodesMessageOutline:icons$2.beamsNodesMessageOutline,beamsNodesOutline:icons$2.beamsNodesOutline,beamsNodesPlugOutline:icons$2.beamsNodesPlugOutline,BNGEcosystemOutline:icons$2.BNGEcosystemOutline,carFrontRouteOutline:icons$2.carFrontRouteOutline,carSensorsOutline:icons$2.carSensorsOutline,carSideRouteOutline:icons$2.carSideRouteOutline,chargeLL:icons$2.chargeLL,cityOutline:icons$2.cityOutline,clutchL:icons$2.clutchL,couplerL:icons$2.couplerL,dialogOutline:icons$2.dialogOutline,documentSmileOutline:icons$2.documentSmileOutline,drivetrainOutline:icons$2.drivetrainOutline,electronicSchemeOutline:icons$2.electronicSchemeOutline,engineL:icons$2.engineL,engineOutline:icons$2.engineOutline,gearTuningOutline:icons$2.gearTuningOutline,giftBoxOutline:icons$2.giftBoxOutline,lidarOutline:icons$2.lidarOutline,medalStarOutline:icons$2.medalStarOutline,megaphoneOutline:icons$2.megaphoneOutline,multiseatL:icons$2.multiseatL,peopleOutline:icons$2.peopleOutline,personOutline:icons$2.personOutline,physicsOutline:icons$2.physicsOutline,playChainOutline:icons$2.playChainOutline,POITimeL:icons$2.POITimeL,proximitySensorsOutline:icons$2.proximitySensorsOutline,qualityBadgeStarOutline:icons$2.qualityBadgeStarOutline,qualityBadgeVOutline:icons$2.qualityBadgeVOutline,replayL:icons$2.replayL,roadblockL:icons$2.roadblockL,rotationL:icons$2.rotationL,sensorsL:icons$2.sensorsL,simRigOutline:icons$2.simRigOutline,suspensionOutline:icons$2.suspensionOutline,teamOutline:icons$2.teamOutline,techLightBulbOutline01:icons$2.techLightBulbOutline01,techLightBulbOutline02:icons$2.techLightBulbOutline02,temperatureL:icons$2.temperatureL,timeUnlockOutline:icons$2.timeUnlockOutline,timedLockOutline:icons$2.timedLockOutline,trafficOutline:icons$2.trafficOutline,tuningL:icons$2.tuningL,turbineL:icons$2.turbineL,voucherOutline:icons$2.voucherOutline,wheelBeamsNodesOutline:icons$2.wheelBeamsNodesOutline,wheelOutline:icons$2.wheelOutline,bridge:icons$2.bridge,bump:icons$2.bump,bumps:icons$2.bumps,caution:icons$2.caution,crest:icons$2.crest,doubleCaution:icons$2.doubleCaution,finish:icons$2.finish,jumpOverBump:icons$2.jumpOverBump,narrows:icons$2.narrows,pothole:icons$2.pothole,turn1:icons$2.turn1,turn2:icons$2.turn2,turn3:icons$2.turn3,turn4:icons$2.turn4,turn5:icons$2.turn5,turn6:icons$2.turn6,turnHp:icons$2.turnHp,turnSq:icons$2.turnSq,water:icons$2.water,beamCurrencyOutlineLarge:icons$2.beamCurrencyOutlineLarge,carSideOutlineLarge:icons$2.carSideOutlineLarge,flagOutlineLarge:icons$2.flagOutlineLarge,terrainOutlineLarge:icons$2.terrainOutlineLarge,tripleCaution:icons$2.tripleCaution},56:{circlePinBack:icons$2.circlePinBack,circlePinFront:icons$2.circlePinFront,markerRectanglePinBack:icons$2.markerRectanglePinBack,markerRectanglePinFront:icons$2.markerRectanglePinFront,markerTriangleBack:icons$2.markerTriangleBack,markerTriangleFront:icons$2.markerTriangleFront}}),iconsByTag=Object.freeze({vehicle:{"4WD":icons$2[`4WD`],ABSIndicator:icons$2.ABSIndicator,AWD:icons$2.AWD,axleLift:icons$2.axleLift,axleCenter:icons$2.axleCenter,axleFront:icons$2.axleFront,axleRear:icons$2.axleRear,boxTruck:icons$2.boxTruck,bus:icons$2.bus,carChase01:icons$2.carChase01,carCoin:icons$2.carCoin,carCoins:icons$2.carCoins,carCrash:icons$2.carCrash,carOffroadOutlineRear:icons$2.carOffroadOutlineRear,carOffroadOutlineSide:icons$2.carOffroadOutlineSide,carOffroadRear:icons$2.carOffroadRear,carOffroadSide:icons$2.carOffroadSide,carSensors:icons$2.carSensors,carStarred:icons$2.carStarred,carToWheels:icons$2.carToWheels,carUp:icons$2.carUp,carWithLidar:icons$2.carWithLidar,car:icons$2.car,carsChase02:icons$2.carsChase02,cars:icons$2.cars,centrifugalClutchLocked03:icons$2.centrifugalClutchLocked03,centrifugalClutchUnlocked03:icons$2.centrifugalClutchUnlocked03,cogDamaged:icons$2.cogDamaged,cogsDamaged:icons$2.cogsDamaged,cogs:icons$2.cogs,coolantTemp:icons$2.coolantTemp,cruiseDisable:icons$2.cruiseDisable,cruiseEnable:icons$2.cruiseEnable,DCBattery:icons$2.DCBattery,deliveryTruckArrows:icons$2.deliveryTruckArrows,deliveryTruck:icons$2.deliveryTruck,differentialFrontDefault:icons$2.differentialFrontDefault,differentialFrontLocked:icons$2.differentialFrontLocked,differentialMiddleDefault:icons$2.differentialMiddleDefault,differentialMiddleLocked:icons$2.differentialMiddleLocked,differentialRearDefault:icons$2.differentialRearDefault,differentialRearLocked:icons$2.differentialRearLocked,doorHandle:icons$2.doorHandle,drift01:icons$2.drift01,drift02:icons$2.drift02,drivetrainGeneric:icons$2.drivetrainGeneric,drivetrainSpecial:icons$2.drivetrainSpecial,engine:icons$2.engine,ESCOff:icons$2.ESCOff,ESCOn:icons$2.ESCOn,ESC:icons$2.ESC,exhaustValve:icons$2.exhaustValve,flatbedTruck:icons$2.flatbedTruck,fogLight:icons$2.fogLight,forklift:icons$2.forklift,FWD:icons$2.FWD,hazardLights:icons$2.hazardLights,highBeam:icons$2.highBeam,hydroPump1:icons$2.hydroPump1,hydroPump2:icons$2.hydroPump2,hydroPump3:icons$2.hydroPump3,hydroPump4:icons$2.hydroPump4,hydroPump5:icons$2.hydroPump5,hydroPump6:icons$2.hydroPump6,hydroPump7:icons$2.hydroPump7,jointLocked:icons$2.jointLocked,jointUnlocked:icons$2.jointUnlocked,keys1:icons$2.keys1,keys2:icons$2.keys2,limiterEnable:icons$2.limiterEnable,lowBeam:icons$2.lowBeam,minusRes:icons$2.minusRes,mirrorInteriorMiddle:icons$2.mirrorInteriorMiddle,mirrorLeftBigBottomWideAngle:icons$2.mirrorLeftBigBottomWideAngle,mirrorLeftBigTop:icons$2.mirrorLeftBigTop,mirrorLeftBig:icons$2.mirrorLeftBig,mirrorLeftBonnet:icons$2.mirrorLeftBonnet,mirrorLeftDefault:icons$2.mirrorLeftDefault,mirrorRightBigBottomWideAngle:icons$2.mirrorRightBigBottomWideAngle,mirrorRightBigTop:icons$2.mirrorRightBigTop,mirrorRightBig:icons$2.mirrorRightBig,mirrorRightBonnet:icons$2.mirrorRightBonnet,mirrorRightDefault:icons$2.mirrorRightDefault,mirrorRoundWideAngle:icons$2.mirrorRoundWideAngle,mirrorTopWideAngle:icons$2.mirrorTopWideAngle,odometerKM:icons$2.odometerKM,odometerMI:icons$2.odometerMI,odometer:icons$2.odometer,oilPressureIndicator:icons$2.oilPressureIndicator,parkingIndicator:icons$2.parkingIndicator,plusSet:icons$2.plusSet,positionLights:icons$2.positionLights,powerGauge01:icons$2.powerGauge01,powerGauge02:icons$2.powerGauge02,powerGauge03:icons$2.powerGauge03,powerGauge04:icons$2.powerGauge04,powerGauge05:icons$2.powerGauge05,rangeboxHi2:icons$2.rangeboxHi2,rangeboxHi4:icons$2.rangeboxHi4,rangeboxHiA:icons$2.rangeboxHiA,rangeboxLo2:icons$2.rangeboxLo2,rangeboxLo4:icons$2.rangeboxLo4,rangeboxLoA:icons$2.rangeboxLoA,rockCrawling01:icons$2.rockCrawling01,RWD:icons$2.RWD,semiTrailer:icons$2.semiTrailer,semiTruckCabover:icons$2.semiTruckCabover,semiTruckUS:icons$2.semiTruckUS,semiTruck:icons$2.semiTruck,smallTrailer:icons$2.smallTrailer,spoilerLift:icons$2.spoilerLift,strobeLights:icons$2.strobeLights,suspension01:icons$2.suspension01,suspension02:icons$2.suspension02,synchro01:icons$2.synchro01,synchro02:icons$2.synchro02,tankerTrailer:icons$2.tankerTrailer,taxiCar1:icons$2.taxiCar1,taxiCar3:icons$2.taxiCar3,taxiCarT:icons$2.taxiCarT,taxiCheckerLamp:icons$2.taxiCheckerLamp,tirePressureDecrease01:icons$2.tirePressureDecrease01,tirePressureDecrease02:icons$2.tirePressureDecrease02,tirePressureGaugeAlt01:icons$2.tirePressureGaugeAlt01,tirePressureGaugeAlt02:icons$2.tirePressureGaugeAlt02,tirePressureGaugeAlt03:icons$2.tirePressureGaugeAlt03,tirePressureGaugeOutlined01:icons$2.tirePressureGaugeOutlined01,tirePressureGaugeOutlined02:icons$2.tirePressureGaugeOutlined02,tirePressureGaugeOutlined03:icons$2.tirePressureGaugeOutlined03,tirePressureGaugeSolid01:icons$2.tirePressureGaugeSolid01,tirePressureGaugeSolid02:icons$2.tirePressureGaugeSolid02,tirePressureGaugeSolid03:icons$2.tirePressureGaugeSolid03,tirePressureIncrease01:icons$2.tirePressureIncrease01,tirePressureIncrease02:icons$2.tirePressureIncrease02,tirePressureStopLine:icons$2.tirePressureStopLine,tirePressureStopOctoLine:icons$2.tirePressureStopOctoLine,tirePressureStopOctoSolid:icons$2.tirePressureStopOctoSolid,tirePressureStopSolid:icons$2.tirePressureStopSolid,tow:icons$2.tow,tractionControl:icons$2.tractionControl,transmissionA:icons$2.transmissionA,transmissionM:icons$2.transmissionM,turbine:icons$2.turbine,vehicleDoorsClose:icons$2.vehicleDoorsClose,vehicleDoorsOpen:icons$2.vehicleDoorsOpen,vehicleDoors:icons$2.vehicleDoors,vehicleFeatures01:icons$2.vehicleFeatures01,vehicleFeatures02:icons$2.vehicleFeatures02,vehicleFeatures03:icons$2.vehicleFeatures03,vehicleHood:icons$2.vehicleHood,vehicleTrunk:icons$2.vehicleTrunk,wheelHubLocked01:icons$2.wheelHubLocked01,wheelHubUnlocked01:icons$2.wheelHubUnlocked01,wigwags:icons$2.wigwags,wrench:icons$2.wrench,accelerationKPH:icons$2.accelerationKPH,accelerationMPH:icons$2.accelerationMPH,boxTruckFast:icons$2.boxTruckFast,doorFrontCoins:icons$2.doorFrontCoins,doorFront:icons$2.doorFront,engineCoins:icons$2.engineCoins,exhaustMufflerCoins:icons$2.exhaustMufflerCoins,exhaustMuffler:icons$2.exhaustMuffler,headlightCoins:icons$2.headlightCoins,headlight:icons$2.headlight,tire3FourthCoins:icons$2.tire3FourthCoins,tire3Fourth:icons$2.tire3Fourth,turbineCoins:icons$2.turbineCoins,wheelDiscCoins:icons$2.wheelDiscCoins,wheelDisc:icons$2.wheelDisc,busTilted:icons$2.busTilted,jointLockedMultiple:icons$2.jointLockedMultiple,jointUnlockedMultiple:icons$2.jointUnlockedMultiple,airPuffRight1:icons$2.airPuffRight1,carClock:icons$2.carClock,carFast:icons$2.carFast,carNumber1:icons$2.carNumber1,carNumber2:icons$2.carNumber2,carNumber3:icons$2.carNumber3,carNumber4:icons$2.carNumber4,carNumber5:icons$2.carNumber5,carNumber6:icons$2.carNumber6,carNumber7:icons$2.carNumber7,carNumber8:icons$2.carNumber8,carNumber9:icons$2.carNumber9,carPlus:icons$2.carPlus,carsChange:icons$2.carsChange,carsFollow:icons$2.carsFollow,doorFrontDetached:icons$2.doorFrontDetached,hingeBroken:icons$2.hingeBroken,octagonBrick:icons$2.octagonBrick,octagon:icons$2.octagon,tireAirPuff:icons$2.tireAirPuff,tireDeflated:icons$2.tireDeflated,carSideOutlineLarge:icons$2.carSideOutlineLarge,carFastReverse:icons$2.carFastReverse,carsChase:icons$2.carsChase,carsFlee:icons$2.carsFlee,hammerParticles:icons$2.hammerParticles,rangeboxHi:icons$2.rangeboxHi,rangeboxLo:icons$2.rangeboxLo,carsWrench:icons$2.carsWrench,jointCycleMultiple:icons$2.jointCycleMultiple,jointCycle:icons$2.jointCycle,intakeTrumpets:icons$2.intakeTrumpets,transmissionCvt:icons$2.transmissionCvt,auxUpDown:icons$2.auxUpDown,bucketArmUpDown:icons$2.bucketArmUpDown,bucketTilt:icons$2.bucketTilt,bucketArmDown:icons$2.bucketArmDown,bucketArmLevel:icons$2.bucketArmLevel,bucketArmUp:icons$2.bucketArmUp,bucketTiltDown:icons$2.bucketTiltDown,bucketTiltLevel:icons$2.bucketTiltLevel,bucketTiltUp:icons$2.bucketTiltUp,dumpBedDown:icons$2.dumpBedDown,dumpBedUpDown:icons$2.dumpBedUpDown,dumpBedUp:icons$2.dumpBedUp},features:{"4WD":icons$2[`4WD`],ABSIndicator:icons$2.ABSIndicator,AWD:icons$2.AWD,axleLift:icons$2.axleLift,axleCenter:icons$2.axleCenter,axleFront:icons$2.axleFront,axleRear:icons$2.axleRear,carCoin:icons$2.carCoin,carCoins:icons$2.carCoins,carDealer:icons$2.carDealer,carStarred:icons$2.carStarred,centrifugalClutchLocked03:icons$2.centrifugalClutchLocked03,centrifugalClutchUnlocked03:icons$2.centrifugalClutchUnlocked03,cogDamaged:icons$2.cogDamaged,cogsDamaged:icons$2.cogsDamaged,cogs:icons$2.cogs,coolantTemp:icons$2.coolantTemp,cruiseDisable:icons$2.cruiseDisable,cruiseEnable:icons$2.cruiseEnable,DCBattery:icons$2.DCBattery,differentialFrontDefault:icons$2.differentialFrontDefault,differentialFrontLocked:icons$2.differentialFrontLocked,differentialMiddleDefault:icons$2.differentialMiddleDefault,differentialMiddleLocked:icons$2.differentialMiddleLocked,differentialRearDefault:icons$2.differentialRearDefault,differentialRearLocked:icons$2.differentialRearLocked,doorHandle:icons$2.doorHandle,drivetrainGeneric:icons$2.drivetrainGeneric,drivetrainSpecial:icons$2.drivetrainSpecial,engine:icons$2.engine,ESCOff:icons$2.ESCOff,ESCOn:icons$2.ESCOn,ESC:icons$2.ESC,exhaustValve:icons$2.exhaustValve,fogLight:icons$2.fogLight,FWD:icons$2.FWD,garage01:icons$2.garage01,garage02:icons$2.garage02,garage03:icons$2.garage03,hazardLights:icons$2.hazardLights,highBeam:icons$2.highBeam,hydroPump1:icons$2.hydroPump1,hydroPump2:icons$2.hydroPump2,hydroPump3:icons$2.hydroPump3,hydroPump4:icons$2.hydroPump4,hydroPump5:icons$2.hydroPump5,hydroPump6:icons$2.hydroPump6,hydroPump7:icons$2.hydroPump7,jointLocked:icons$2.jointLocked,jointUnlocked:icons$2.jointUnlocked,keys1:icons$2.keys1,keys2:icons$2.keys2,limiterEnable:icons$2.limiterEnable,lowBeam:icons$2.lowBeam,minusRes:icons$2.minusRes,mirrorInteriorMiddle:icons$2.mirrorInteriorMiddle,mirrorLeftBigBottomWideAngle:icons$2.mirrorLeftBigBottomWideAngle,mirrorLeftBigTop:icons$2.mirrorLeftBigTop,mirrorLeftBig:icons$2.mirrorLeftBig,mirrorLeftBonnet:icons$2.mirrorLeftBonnet,mirrorLeftDefault:icons$2.mirrorLeftDefault,mirrorRightBigBottomWideAngle:icons$2.mirrorRightBigBottomWideAngle,mirrorRightBigTop:icons$2.mirrorRightBigTop,mirrorRightBig:icons$2.mirrorRightBig,mirrorRightBonnet:icons$2.mirrorRightBonnet,mirrorRightDefault:icons$2.mirrorRightDefault,mirrorRoundWideAngle:icons$2.mirrorRoundWideAngle,mirrorTopWideAngle:icons$2.mirrorTopWideAngle,odometerKM:icons$2.odometerKM,odometerMI:icons$2.odometerMI,odometer:icons$2.odometer,oilPressureIndicator:icons$2.oilPressureIndicator,parkingIndicator:icons$2.parkingIndicator,plusGarage1:icons$2.plusGarage1,plusGarage2:icons$2.plusGarage2,plusGarage3:icons$2.plusGarage3,plusGarage4:icons$2.plusGarage4,plusSet:icons$2.plusSet,positionLights:icons$2.positionLights,powerGauge01:icons$2.powerGauge01,powerGauge02:icons$2.powerGauge02,powerGauge03:icons$2.powerGauge03,powerGauge04:icons$2.powerGauge04,powerGauge05:icons$2.powerGauge05,rangeboxHi2:icons$2.rangeboxHi2,rangeboxHi4:icons$2.rangeboxHi4,rangeboxHiA:icons$2.rangeboxHiA,rangeboxLo2:icons$2.rangeboxLo2,rangeboxLo4:icons$2.rangeboxLo4,rangeboxLoA:icons$2.rangeboxLoA,RWD:icons$2.RWD,spoilerLift:icons$2.spoilerLift,strobeLights:icons$2.strobeLights,suspension01:icons$2.suspension01,suspension02:icons$2.suspension02,synchro01:icons$2.synchro01,synchro02:icons$2.synchro02,tirePressureDecrease01:icons$2.tirePressureDecrease01,tirePressureDecrease02:icons$2.tirePressureDecrease02,tirePressureGaugeAlt01:icons$2.tirePressureGaugeAlt01,tirePressureGaugeAlt02:icons$2.tirePressureGaugeAlt02,tirePressureGaugeAlt03:icons$2.tirePressureGaugeAlt03,tirePressureGaugeOutlined01:icons$2.tirePressureGaugeOutlined01,tirePressureGaugeOutlined02:icons$2.tirePressureGaugeOutlined02,tirePressureGaugeOutlined03:icons$2.tirePressureGaugeOutlined03,tirePressureGaugeSolid01:icons$2.tirePressureGaugeSolid01,tirePressureGaugeSolid02:icons$2.tirePressureGaugeSolid02,tirePressureGaugeSolid03:icons$2.tirePressureGaugeSolid03,tirePressureIncrease01:icons$2.tirePressureIncrease01,tirePressureIncrease02:icons$2.tirePressureIncrease02,tirePressureStopLine:icons$2.tirePressureStopLine,tirePressureStopOctoLine:icons$2.tirePressureStopOctoLine,tirePressureStopOctoSolid:icons$2.tirePressureStopOctoSolid,tirePressureStopSolid:icons$2.tirePressureStopSolid,tractionControl:icons$2.tractionControl,transmissionA:icons$2.transmissionA,transmissionM:icons$2.transmissionM,turbine:icons$2.turbine,vehicleDoorsClose:icons$2.vehicleDoorsClose,vehicleDoorsOpen:icons$2.vehicleDoorsOpen,vehicleDoors:icons$2.vehicleDoors,vehicleFeatures01:icons$2.vehicleFeatures01,vehicleFeatures02:icons$2.vehicleFeatures02,vehicleFeatures03:icons$2.vehicleFeatures03,vehicleHood:icons$2.vehicleHood,vehicleTrunk:icons$2.vehicleTrunk,wheelHubLocked01:icons$2.wheelHubLocked01,wheelHubUnlocked01:icons$2.wheelHubUnlocked01,wigwags:icons$2.wigwags,wrench:icons$2.wrench,accelerationKPH:icons$2.accelerationKPH,accelerationMPH:icons$2.accelerationMPH,doorFrontCoins:icons$2.doorFrontCoins,doorFront:icons$2.doorFront,engineCoins:icons$2.engineCoins,exhaustMufflerCoins:icons$2.exhaustMufflerCoins,exhaustMuffler:icons$2.exhaustMuffler,headlightCoins:icons$2.headlightCoins,headlight:icons$2.headlight,tire3FourthCoins:icons$2.tire3FourthCoins,tire3Fourth:icons$2.tire3Fourth,turbineCoins:icons$2.turbineCoins,wheelDiscCoins:icons$2.wheelDiscCoins,wheelDisc:icons$2.wheelDisc,jointLockedMultiple:icons$2.jointLockedMultiple,jointUnlockedMultiple:icons$2.jointUnlockedMultiple,bridge:icons$2.bridge,bump:icons$2.bump,bumps:icons$2.bumps,caution:icons$2.caution,crest:icons$2.crest,doubleCaution:icons$2.doubleCaution,finish:icons$2.finish,jumpOverBump:icons$2.jumpOverBump,narrows:icons$2.narrows,pothole:icons$2.pothole,turn1:icons$2.turn1,turn2:icons$2.turn2,turn3:icons$2.turn3,turn4:icons$2.turn4,turn5:icons$2.turn5,turn6:icons$2.turn6,turnHp:icons$2.turnHp,turnSq:icons$2.turnSq,water:icons$2.water,carsFollow:icons$2.carsFollow,doorFrontDetached:icons$2.doorFrontDetached,garageNumber1:icons$2.garageNumber1,garageNumber2:icons$2.garageNumber2,garageNumber3:icons$2.garageNumber3,garageNumber4:icons$2.garageNumber4,garageNumber5:icons$2.garageNumber5,garageNumber6:icons$2.garageNumber6,garageNumber7:icons$2.garageNumber7,garageNumber8:icons$2.garageNumber8,garageNumber9:icons$2.garageNumber9,hingeBroken:icons$2.hingeBroken,houseWrenchRoof:icons$2.houseWrenchRoof,houseWrench:icons$2.houseWrench,tripleCaution:icons$2.tripleCaution,carsChase:icons$2.carsChase,carsFlee:icons$2.carsFlee,hammerParticles:icons$2.hammerParticles,rangeboxHi:icons$2.rangeboxHi,rangeboxLo:icons$2.rangeboxLo,jointCycleMultiple:icons$2.jointCycleMultiple,jointCycle:icons$2.jointCycle,intakeTrumpets:icons$2.intakeTrumpets,transmissionCvt:icons$2.transmissionCvt,house:icons$2.house,auxUpDown:icons$2.auxUpDown,bucketArmUpDown:icons$2.bucketArmUpDown,bucketTilt:icons$2.bucketTilt,bucketArmDown:icons$2.bucketArmDown,bucketArmLevel:icons$2.bucketArmLevel,bucketArmUp:icons$2.bucketArmUp,bucketTiltDown:icons$2.bucketTiltDown,bucketTiltLevel:icons$2.bucketTiltLevel,bucketTiltUp:icons$2.bucketTiltUp,dumpBedDown:icons$2.dumpBedDown,dumpBedUpDown:icons$2.dumpBedUpDown,dumpBedUp:icons$2.dumpBedUp},generic:{"9dividedby10":icons$2[`9dividedby10`],abandon:icons$2.abandon,addItemPolygon:icons$2.addItemPolygon,addListItem:icons$2.addListItem,addPolygonVertex:icons$2.addPolygonVertex,adjust:icons$2.adjust,AIMicrochip:icons$2.AIMicrochip,aperture:icons$2.aperture,autobahn:icons$2.autobahn,bSpline:icons$2.bSpline,beamCrashBarrier1:icons$2.beamCrashBarrier1,beamCrashBarrier2:icons$2.beamCrashBarrier2,beamCrashBarrier3:icons$2.beamCrashBarrier3,beamNG:icons$2.beamNG,bezierPath1:icons$2.bezierPath1,bezierPath2:icons$2.bezierPath2,bicycle1:icons$2.bicycle1,bicycle2:icons$2.bicycle2,BNGFolder:icons$2.BNGFolder,BNGMicrochip:icons$2.BNGMicrochip,bollard:icons$2.bollard,bookmark:icons$2.bookmark,booleanIntersect:icons$2.booleanIntersect,broom:icons$2.broom,bucketAdd:icons$2.bucketAdd,bucketSubtract:icons$2.bucketSubtract,bug:icons$2.bug,bulldozer:icons$2.bulldozer,carChase01:icons$2.carChase01,carCrash:icons$2.carCrash,carOffroadOutlineRear:icons$2.carOffroadOutlineRear,carOffroadOutlineSide:icons$2.carOffroadOutlineSide,carOffroadRear:icons$2.carOffroadRear,carOffroadSide:icons$2.carOffroadSide,carSensors:icons$2.carSensors,carToWheels:icons$2.carToWheels,carUp:icons$2.carUp,carWithLidar:icons$2.carWithLidar,car:icons$2.car,cardboardBox:icons$2.cardboardBox,carsChase02:icons$2.carsChase02,cars:icons$2.cars,catalog01:icons$2.catalog01,catalog02:icons$2.catalog02,catalog03:icons$2.catalog03,chartBars:icons$2.chartBars,checkmarkBold:icons$2.checkmarkBold,checkmark:icons$2.checkmark,circuitMicrochip:icons$2.circuitMicrochip,clapperboard:icons$2.clapperboard,code:icons$2.code,concreteRoadBlock:icons$2.concreteRoadBlock,copy:icons$2.copy,crossroads1:icons$2.crossroads1,crossroads2:icons$2.crossroads2,cup:icons$2.cup,dataExchange:icons$2.dataExchange,decalRoad:icons$2.decalRoad,decal:icons$2.decal,deform:icons$2.deform,doorIn:icons$2.doorIn,editCheckmark:icons$2.editCheckmark,edit:icons$2.edit,exit:icons$2.exit,export:icons$2.export,eyeOutlineClosed:icons$2.eyeOutlineClosed,eyeOutlineOpened:icons$2.eyeOutlineOpened,eyeSolidClosed:icons$2.eyeSolidClosed,eyeSolidOpened:icons$2.eyeSolidOpened,eyeWaves:icons$2.eyeWaves,facility02:icons$2.facility02,filter:icons$2.filter,flatBulbBeam:icons$2.flatBulbBeam,floppyDisk:icons$2.floppyDisk,folder:icons$2.folder,FPS:icons$2.FPS,frontAxleMidpoint:icons$2.frontAxleMidpoint,frontBumperMidpoint:icons$2.frontBumperMidpoint,globe:icons$2.globe,GPSMark:icons$2.GPSMark,GPSSolid:icons$2.GPSSolid,group:icons$2.group,gyroscopeMicrochip:icons$2.gyroscopeMicrochip,gyroscope:icons$2.gyroscope,helmets:icons$2.helmets,help:icons$2.help,HUD:icons$2.HUD,import:icons$2.import,infinity:icons$2.infinity,info:icons$2.info,lampPost1:icons$2.lampPost1,lampPost2:icons$2.lampPost2,lampPost3:icons$2.lampPost3,laneProperties:icons$2.laneProperties,language:icons$2.language,laptop:icons$2.laptop,lidarPatternFullArcHighFreq:icons$2.lidarPatternFullArcHighFreq,lidarPatternFullArcMidFreq:icons$2.lidarPatternFullArcMidFreq,lidarPatternNarrowArc:icons$2.lidarPatternNarrowArc,lidar:icons$2.lidar,lightrunner:icons$2.lightrunner,lineToTerrain:icons$2.lineToTerrain,link2:icons$2.link2,link:icons$2.link,listBig:icons$2.listBig,listIndented:icons$2.listIndented,listSmall:icons$2.listSmall,location1:icons$2.location1,location2:icons$2.location2,lockClosed:icons$2.lockClosed,lockOpened:icons$2.lockOpened,longRangeBeam1:icons$2.longRangeBeam1,longRangeBeam2:icons$2.longRangeBeam2,magnetOnSurface:icons$2.magnetOnSurface,mapWithEmitter:icons$2.mapWithEmitter,mapPoint:icons$2.mapPoint,material:icons$2.material,mathDivide:icons$2.mathDivide,mathGreaterOrEqualThan:icons$2.mathGreaterOrEqualThan,mathGreaterThan:icons$2.mathGreaterThan,mathLessOrEqualThan:icons$2.mathLessOrEqualThan,mathLessThan:icons$2.mathLessThan,mathMinus:icons$2.mathMinus,mathMultiply:icons$2.mathMultiply,mathPlus:icons$2.mathPlus,medal:icons$2.medal,meshFence:icons$2.meshFence,meshRoad:icons$2.meshRoad,midRangeBeam1:icons$2.midRangeBeam1,midRangeBeam2:icons$2.midRangeBeam2,minus:icons$2.minus,move02:icons$2.move02,move:icons$2.move,nodeAddFirst01:icons$2.nodeAddFirst01,nodeAddFirst02:icons$2.nodeAddFirst02,nodeAddLast02:icons$2.nodeAddLast02,nodeAddMiddle01:icons$2.nodeAddMiddle01,nodeAddMiddle02:icons$2.nodeAddMiddle02,nodeAdd:icons$2.nodeAdd,nodeLast01:icons$2.nodeLast01,nodeRemove:icons$2.nodeRemove,order:icons$2.order,organization:icons$2.organization,paperKnife:icons$2.paperKnife,pathArc:icons$2.pathArc,pathLine:icons$2.pathLine,pathSpiral:icons$2.pathSpiral,personSolid:icons$2.personSolid,person:icons$2.person,photo:icons$2.photo,placeholder:icons$2.placeholder,plus:icons$2.plus,powerOnOff:icons$2.powerOnOff,publisher:icons$2.publisher,puzzleModule:icons$2.puzzleModule,radarIdeal:icons$2.radarIdeal,radarRoundIdeal:icons$2.radarRoundIdeal,radarRound:icons$2.radarRound,radar:icons$2.radar,rearAxleMidpoint:icons$2.rearAxleMidpoint,rearBumperMidpoint:icons$2.rearBumperMidpoint,reconfigure:icons$2.reconfigure,redo:icons$2.redo,reflectNot:icons$2.reflectNot,reflect:icons$2.reflect,rename:icons$2.rename,replay:icons$2.replay,restart:icons$2.restart,roadDividerLinesDecal:icons$2.roadDividerLinesDecal,roadEdgeLineDecal:icons$2.roadEdgeLineDecal,roadEndLineDecal:icons$2.roadEndLineDecal,roadFace:icons$2.roadFace,roadInfo:icons$2.roadInfo,roadMarkingOutline:icons$2.roadMarkingOutline,roadMarkingSolid:icons$2.roadMarkingSolid,roadOutline:icons$2.roadOutline,roadRefPathDecal:icons$2.roadRefPathDecal,roadRefPath:icons$2.roadRefPath,roadStartLineDecal:icons$2.roadStartLineDecal,road:icons$2.road,runScript:icons$2.runScript,saveAs1:icons$2.saveAs1,scan:icons$2.scan,search:icons$2.search,shortRangeBeam1:icons$2.shortRangeBeam1,shortRangeBeam2:icons$2.shortRangeBeam2,signal01a:icons$2.signal01a,signal02a:icons$2.signal02a,signal03a:icons$2.signal03a,signal04a:icons$2.signal04a,signal05a:icons$2.signal05a,slashLeft:icons$2.slashLeft,slashRight:icons$2.slashRight,snowflake:icons$2.snowflake,soundFadeOut:icons$2.soundFadeOut,soundLimit:icons$2.soundLimit,soundLoud:icons$2.soundLoud,soundMonoL:icons$2.soundMonoL,soundMonoR:icons$2.soundMonoR,soundOff:icons$2.soundOff,soundQuiet:icons$2.soundQuiet,soundStereo:icons$2.soundStereo,soundWave01:icons$2.soundWave01,soundWave02:icons$2.soundWave02,sphereOnPathNumber:icons$2.sphereOnPathNumber,sphereOnPath:icons$2.sphereOnPath,sphericalBeam:icons$2.sphericalBeam,sprayCan:icons$2.sprayCan,star:icons$2.star,starSecondary:icons$2.starSecondary,stopwatchArrows01:icons$2.stopwatchArrows01,stopwatchArrows02:icons$2.stopwatchArrows02,stopwatchSectionOutlinedEnd:icons$2.stopwatchSectionOutlinedEnd,stopwatchSectionOutlinedStart:icons$2.stopwatchSectionOutlinedStart,stopwatchSectionSolidEnd:icons$2.stopwatchSectionSolidEnd,stopwatchSectionSolidStart:icons$2.stopwatchSectionSolidStart,survellianceCamera:icons$2.survellianceCamera,switchBlock:icons$2.switchBlock,switchOutline:icons$2.switchOutline,sync:icons$2.sync,taxiCar1:icons$2.taxiCar1,taxiCar3:icons$2.taxiCar3,taxiCarT:icons$2.taxiCarT,taxiCheckerLamp:icons$2.taxiCheckerLamp,terrainToLine:icons$2.terrainToLine,terrain:icons$2.terrain,thinBulbBeam:icons$2.thinBulbBeam,thinnerBulbBeam:icons$2.thinnerBulbBeam,tiles:icons$2.tiles,timer:icons$2.timer,toCOMWithWheels:icons$2.toCOMWithWheels,toCOM:icons$2.toCOM,tow:icons$2.tow,transform:icons$2.transform,transparencyMask:icons$2.transparencyMask,trashBin2:icons$2.trashBin2,triangleBeam:icons$2.triangleBeam,trim:icons$2.trim,tulipBeam:icons$2.tulipBeam,tunnel:icons$2.tunnel,twoRoadsAdd:icons$2.twoRoadsAdd,twoRoadsCrossAdd:icons$2.twoRoadsCrossAdd,twoRoadsLink:icons$2.twoRoadsLink,undo:icons$2.undo,ungroup:icons$2.ungroup,unlink:icons$2.unlink,view:icons$2.view,voucherDiagonal1:icons$2.voucherDiagonal1,voucherDiagonal2:icons$2.voucherDiagonal2,voucherDiagonal3:icons$2.voucherDiagonal3,voucherHorizontal1:icons$2.voucherHorizontal1,voucherHorizontal2:icons$2.voucherHorizontal2,voucherHorizontal3:icons$2.voucherHorizontal3,wavesSignalReceived:icons$2.wavesSignalReceived,wavesSignalSentLeft:icons$2.wavesSignalSentLeft,wavesSignalSentRight:icons$2.wavesSignalSentRight,weight:icons$2.weight,wrench:icons$2.wrench,danger:icons$2.danger,droplet:icons$2.droplet,envelope:icons$2.envelope,fireDiamond:icons$2.fireDiamond,xmark:icons$2.xmark,scale:icons$2.scale,locationDestination:icons$2.locationDestination,locationSource:icons$2.locationSource,colorBrightnessSun:icons$2.colorBrightnessSun,colorCirclePalette:icons$2.colorCirclePalette,colorPalette:icons$2.colorPalette,colorSaturation:icons$2.colorSaturation,sortAscDown02:icons$2.sortAscDown02,sortAscDown:icons$2.sortAscDown,sortAscUp02:icons$2.sortAscUp02,sortAscUp:icons$2.sortAscUp,sortDescDown02:icons$2.sortDescDown02,sortDescDown:icons$2.sortDescDown,sortDescUp02:icons$2.sortDescUp02,sortDescUp:icons$2.sortDescUp,cardboardBoxCoins:icons$2.cardboardBoxCoins,lasso:icons$2.lasso,materialGlossy:icons$2.materialGlossy,materialMetal:icons$2.materialMetal,materialRoughness:icons$2.materialRoughness,materialTransparency01:icons$2.materialTransparency01,materialTransparency02:icons$2.materialTransparency02,metal01:icons$2.metal01,removeItemPolygon:icons$2.removeItemPolygon,removeListItem:icons$2.removeListItem,sortAsc:icons$2.sortAsc,sortDesc:icons$2.sortDesc,surfaceRoughness02:icons$2.surfaceRoughness02,shieldCheckmark:icons$2.shieldCheckmark,shieldHandCheckmark:icons$2.shieldHandCheckmark,shieldHandPlus:icons$2.shieldHandPlus,bridgeWithRiver:icons$2.bridgeWithRiver,gizmosOutline:icons$2.gizmosOutline,gizmosSolid:icons$2.gizmosSolid,highwayRoad3To2Merge01:icons$2.highwayRoad3To2Merge01,highwayRoad3To2Merge02:icons$2.highwayRoad3To2Merge02,highwayToUrbanRoadTransition01:icons$2.highwayToUrbanRoadTransition01,highwayToUrbanRoadTransition02:icons$2.highwayToUrbanRoadTransition02,pedestrianCrossing01:icons$2.pedestrianCrossing01,polygonalCube:icons$2.polygonalCube,roadEditOutline:icons$2.roadEditOutline,roadEditSolid:icons$2.roadEditSolid,roadFolderPlus:icons$2.roadFolderPlus,roadFolder:icons$2.roadFolder,roadGuideArrowOutline:icons$2.roadGuideArrowOutline,roadGuideArrowSolid:icons$2.roadGuideArrowSolid,roadOutlineMesh:icons$2.roadOutlineMesh,roadPedestrianCrossing02:icons$2.roadPedestrianCrossing02,roadProfileWithCheckmark:icons$2.roadProfileWithCheckmark,roadProfile:icons$2.roadProfile,roadRoundaboutJunction:icons$2.roadRoundaboutJunction,roadSidewalkTransition:icons$2.roadSidewalkTransition,roadStackPlus:icons$2.roadStackPlus,roadStack:icons$2.roadStack,roadTJunction:icons$2.roadTJunction,roadXJunction:icons$2.roadXJunction,roadYJunction:icons$2.roadYJunction,shoppingCart:icons$2.shoppingCart,singleLineToTerrain:icons$2.singleLineToTerrain,sphereOnMesh:icons$2.sphereOnMesh,twoLinesToTerrain:icons$2.twoLinesToTerrain,urbanRoad3To2Merge01:icons$2.urbanRoad3To2Merge01,urbanRoad3To2Merge02:icons$2.urbanRoad3To2Merge02,urbanRoadToHighwayTransition01:icons$2.urbanRoadToHighwayTransition01,urbanRoadToHighwayTransition02:icons$2.urbanRoadToHighwayTransition02,floppyDiskPlus:icons$2.floppyDiskPlus,highwayMerge:icons$2.highwayMerge,highwaySeparate:icons$2.highwaySeparate,highwayShoulderMerge:icons$2.highwayShoulderMerge,terrainToSingleLine:icons$2.terrainToSingleLine,terrainToTwoLines:icons$2.terrainToTwoLines,urbanRoadMerge:icons$2.urbanRoadMerge,urbanRoadSeparate:icons$2.urbanRoadSeparate,urbanShoulderMerge:icons$2.urbanShoulderMerge,BNGChat:icons$2.BNGChat,chatBubble:icons$2.chatBubble,cameraFarClip:icons$2.cameraFarClip,cameraNearClip:icons$2.cameraNearClip,explosion:icons$2.explosion,fireExtinguisher:icons$2.fireExtinguisher,fire:icons$2.fire,toggleOff:icons$2.toggleOff,toggleOn:icons$2.toggleOn,viewFarClip:icons$2.viewFarClip,viewNearClip:icons$2.viewNearClip,circleSlashed:icons$2.circleSlashed,scissorsSlashed:icons$2.scissorsSlashed,scissors:icons$2.scissors,airPuffRight1:icons$2.airPuffRight1,airPuffUp1:icons$2.airPuffUp1,arrowsReplace:icons$2.arrowsReplace,arrowsShuffle:icons$2.arrowsShuffle,arrowsSwitch:icons$2.arrowsSwitch,carClock:icons$2.carClock,carNumber1:icons$2.carNumber1,carNumber2:icons$2.carNumber2,carNumber3:icons$2.carNumber3,carNumber4:icons$2.carNumber4,carNumber5:icons$2.carNumber5,carNumber6:icons$2.carNumber6,carNumber7:icons$2.carNumber7,carNumber8:icons$2.carNumber8,carNumber9:icons$2.carNumber9,carPlus:icons$2.carPlus,loadMesh:icons$2.loadMesh,octagonBrick:icons$2.octagonBrick,octagon:icons$2.octagon,saveMesh:icons$2.saveMesh,trafficLight:icons$2.trafficLight,enter:icons$2.enter,pedestrianRunning:icons$2.pedestrianRunning,pedestrianStanding:icons$2.pedestrianStanding,seatArrowIn:icons$2.seatArrowIn,seatArrowOut:icons$2.seatArrowOut,seatVArrowIn:icons$2.seatVArrowIn,seatVArrowOut:icons$2.seatVArrowOut,vehicleArrowIn:icons$2.vehicleArrowIn,vehicleArrowOut:icons$2.vehicleArrowOut,leverFrontOperate:icons$2.leverFrontOperate,leverSideDown:icons$2.leverSideDown,leverSideOperate:icons$2.leverSideOperate,leverSideUp:icons$2.leverSideUp,medalEmpty:icons$2.medalEmpty,medalStar:icons$2.medalStar,seatArrowInLeft:icons$2.seatArrowInLeft,seatArrowOutLeft:icons$2.seatArrowOutLeft,seatVArrowInLeft:icons$2.seatVArrowInLeft,seatVArrowOutLeft:icons$2.seatVArrowOutLeft,badgeRoundEmpty:icons$2.badgeRoundEmpty,badgeRoundStar:icons$2.badgeRoundStar,badgeRound:icons$2.badgeRound,badge:icons$2.badge,beamCurrencyOutlineLarge:icons$2.beamCurrencyOutlineLarge,carSideOutlineLarge:icons$2.carSideOutlineLarge,flagOutlineLarge:icons$2.flagOutlineLarge,terrainOutlineLarge:icons$2.terrainOutlineLarge,rallyHelmet3To4:icons$2.rallyHelmet3To4,rallyHelmet:icons$2.rallyHelmet,test:icons$2.test,globeSimpleNotSign:icons$2.globeSimpleNotSign,globeSimplified:icons$2.globeSimplified,radialMenu:icons$2.radialMenu,branch:icons$2.branch,NA:icons$2.NA,magicWand:icons$2.magicWand,dice24:icons$2.dice24,diceD6:icons$2.diceD6,xmarkBold:icons$2.xmarkBold,house:icons$2.house,picture:icons$2.picture,shieldCheckmarkProgressbar:icons$2.shieldCheckmarkProgressbar},warning:{ABSIndicator:icons$2.ABSIndicator,DCBattery:icons$2.DCBattery,oilPressureIndicator:icons$2.oilPressureIndicator,parkingIndicator:icons$2.parkingIndicator},internals:{ABSIndicator:icons$2.ABSIndicator,DCBattery:icons$2.DCBattery,oilPressureIndicator:icons$2.oilPressureIndicator,parkingIndicator:icons$2.parkingIndicator},we:{addItemPolygon:icons$2.addItemPolygon,addListItem:icons$2.addListItem,addPolygonVertex:icons$2.addPolygonVertex,bSpline:icons$2.bSpline,beamCrashBarrier1:icons$2.beamCrashBarrier1,beamCrashBarrier2:icons$2.beamCrashBarrier2,beamCrashBarrier3:icons$2.beamCrashBarrier3,bezierPath1:icons$2.bezierPath1,bezierPath2:icons$2.bezierPath2,bicycle1:icons$2.bicycle1,bicycle2:icons$2.bicycle2,bollard:icons$2.bollard,bulldozer:icons$2.bulldozer,concreteRoadBlock:icons$2.concreteRoadBlock,crossroads1:icons$2.crossroads1,crossroads2:icons$2.crossroads2,decalRoad:icons$2.decalRoad,flatBulbBeam:icons$2.flatBulbBeam,frontAxleMidpoint:icons$2.frontAxleMidpoint,frontBumperMidpoint:icons$2.frontBumperMidpoint,lampPost1:icons$2.lampPost1,lampPost2:icons$2.lampPost2,lampPost3:icons$2.lampPost3,laneProperties:icons$2.laneProperties,lidarPatternFullArcHighFreq:icons$2.lidarPatternFullArcHighFreq,lidarPatternFullArcMidFreq:icons$2.lidarPatternFullArcMidFreq,lidarPatternNarrowArc:icons$2.lidarPatternNarrowArc,lineToTerrain:icons$2.lineToTerrain,longRangeBeam1:icons$2.longRangeBeam1,longRangeBeam2:icons$2.longRangeBeam2,magnetOnSurface:icons$2.magnetOnSurface,meshFence:icons$2.meshFence,meshRoad:icons$2.meshRoad,midRangeBeam1:icons$2.midRangeBeam1,midRangeBeam2:icons$2.midRangeBeam2,pathArc:icons$2.pathArc,pathLine:icons$2.pathLine,pathSpiral:icons$2.pathSpiral,rearAxleMidpoint:icons$2.rearAxleMidpoint,rearBumperMidpoint:icons$2.rearBumperMidpoint,roadDividerLinesDecal:icons$2.roadDividerLinesDecal,roadEdgeLineDecal:icons$2.roadEdgeLineDecal,roadEndLineDecal:icons$2.roadEndLineDecal,roadFace:icons$2.roadFace,roadMarkingOutline:icons$2.roadMarkingOutline,roadMarkingSolid:icons$2.roadMarkingSolid,roadOutline:icons$2.roadOutline,roadRefPathDecal:icons$2.roadRefPathDecal,roadRefPath:icons$2.roadRefPath,roadStartLineDecal:icons$2.roadStartLineDecal,shortRangeBeam1:icons$2.shortRangeBeam1,shortRangeBeam2:icons$2.shortRangeBeam2,sphereOnPathNumber:icons$2.sphereOnPathNumber,sphereOnPath:icons$2.sphereOnPath,sphericalBeam:icons$2.sphericalBeam,terrainToLine:icons$2.terrainToLine,thinBulbBeam:icons$2.thinBulbBeam,thinnerBulbBeam:icons$2.thinnerBulbBeam,toCOMWithWheels:icons$2.toCOMWithWheels,toCOM:icons$2.toCOM,triangleBeam:icons$2.triangleBeam,tulipBeam:icons$2.tulipBeam,tunnel:icons$2.tunnel,twoRoadsAdd:icons$2.twoRoadsAdd,twoRoadsCrossAdd:icons$2.twoRoadsCrossAdd,twoRoadsLink:icons$2.twoRoadsLink,lasso:icons$2.lasso,removeItemPolygon:icons$2.removeItemPolygon,removeListItem:icons$2.removeListItem,bridgeWithRiver:icons$2.bridgeWithRiver,gizmosOutline:icons$2.gizmosOutline,gizmosSolid:icons$2.gizmosSolid,highwayRoad3To2Merge01:icons$2.highwayRoad3To2Merge01,highwayRoad3To2Merge02:icons$2.highwayRoad3To2Merge02,highwayToUrbanRoadTransition01:icons$2.highwayToUrbanRoadTransition01,highwayToUrbanRoadTransition02:icons$2.highwayToUrbanRoadTransition02,pedestrianCrossing01:icons$2.pedestrianCrossing01,polygonalCube:icons$2.polygonalCube,roadEditOutline:icons$2.roadEditOutline,roadEditSolid:icons$2.roadEditSolid,roadFolderPlus:icons$2.roadFolderPlus,roadFolder:icons$2.roadFolder,roadGuideArrowOutline:icons$2.roadGuideArrowOutline,roadGuideArrowSolid:icons$2.roadGuideArrowSolid,roadOutlineMesh:icons$2.roadOutlineMesh,roadPedestrianCrossing02:icons$2.roadPedestrianCrossing02,roadProfileWithCheckmark:icons$2.roadProfileWithCheckmark,roadProfile:icons$2.roadProfile,roadRoundaboutJunction:icons$2.roadRoundaboutJunction,roadSidewalkTransition:icons$2.roadSidewalkTransition,roadStackPlus:icons$2.roadStackPlus,roadStack:icons$2.roadStack,roadTJunction:icons$2.roadTJunction,roadXJunction:icons$2.roadXJunction,roadYJunction:icons$2.roadYJunction,singleLineToTerrain:icons$2.singleLineToTerrain,sphereOnMesh:icons$2.sphereOnMesh,twoLinesToTerrain:icons$2.twoLinesToTerrain,urbanRoad3To2Merge01:icons$2.urbanRoad3To2Merge01,urbanRoad3To2Merge02:icons$2.urbanRoad3To2Merge02,urbanRoadToHighwayTransition01:icons$2.urbanRoadToHighwayTransition01,urbanRoadToHighwayTransition02:icons$2.urbanRoadToHighwayTransition02,highwayMerge:icons$2.highwayMerge,highwaySeparate:icons$2.highwaySeparate,highwayShoulderMerge:icons$2.highwayShoulderMerge,terrainToSingleLine:icons$2.terrainToSingleLine,terrainToTwoLines:icons$2.terrainToTwoLines,urbanRoadMerge:icons$2.urbanRoadMerge,urbanRoadSeparate:icons$2.urbanRoadSeparate,urbanShoulderMerge:icons$2.urbanShoulderMerge},"world editor":{addItemPolygon:icons$2.addItemPolygon,addListItem:icons$2.addListItem,addPolygonVertex:icons$2.addPolygonVertex,bSpline:icons$2.bSpline,beamCrashBarrier1:icons$2.beamCrashBarrier1,beamCrashBarrier2:icons$2.beamCrashBarrier2,beamCrashBarrier3:icons$2.beamCrashBarrier3,bezierPath1:icons$2.bezierPath1,bezierPath2:icons$2.bezierPath2,bicycle1:icons$2.bicycle1,bicycle2:icons$2.bicycle2,bollard:icons$2.bollard,bulldozer:icons$2.bulldozer,concreteRoadBlock:icons$2.concreteRoadBlock,crossroads1:icons$2.crossroads1,crossroads2:icons$2.crossroads2,decalRoad:icons$2.decalRoad,flatBulbBeam:icons$2.flatBulbBeam,frontAxleMidpoint:icons$2.frontAxleMidpoint,frontBumperMidpoint:icons$2.frontBumperMidpoint,lampPost1:icons$2.lampPost1,lampPost2:icons$2.lampPost2,lampPost3:icons$2.lampPost3,laneProperties:icons$2.laneProperties,lidarPatternFullArcHighFreq:icons$2.lidarPatternFullArcHighFreq,lidarPatternFullArcMidFreq:icons$2.lidarPatternFullArcMidFreq,lidarPatternNarrowArc:icons$2.lidarPatternNarrowArc,lineToTerrain:icons$2.lineToTerrain,longRangeBeam1:icons$2.longRangeBeam1,longRangeBeam2:icons$2.longRangeBeam2,magnetOnSurface:icons$2.magnetOnSurface,meshFence:icons$2.meshFence,meshRoad:icons$2.meshRoad,midRangeBeam1:icons$2.midRangeBeam1,midRangeBeam2:icons$2.midRangeBeam2,pathArc:icons$2.pathArc,pathLine:icons$2.pathLine,pathSpiral:icons$2.pathSpiral,rearAxleMidpoint:icons$2.rearAxleMidpoint,rearBumperMidpoint:icons$2.rearBumperMidpoint,roadDividerLinesDecal:icons$2.roadDividerLinesDecal,roadEdgeLineDecal:icons$2.roadEdgeLineDecal,roadEndLineDecal:icons$2.roadEndLineDecal,roadFace:icons$2.roadFace,roadMarkingOutline:icons$2.roadMarkingOutline,roadMarkingSolid:icons$2.roadMarkingSolid,roadOutline:icons$2.roadOutline,roadRefPathDecal:icons$2.roadRefPathDecal,roadRefPath:icons$2.roadRefPath,roadStartLineDecal:icons$2.roadStartLineDecal,shortRangeBeam1:icons$2.shortRangeBeam1,shortRangeBeam2:icons$2.shortRangeBeam2,sphereOnPathNumber:icons$2.sphereOnPathNumber,sphereOnPath:icons$2.sphereOnPath,sphericalBeam:icons$2.sphericalBeam,terrainToLine:icons$2.terrainToLine,thinBulbBeam:icons$2.thinBulbBeam,thinnerBulbBeam:icons$2.thinnerBulbBeam,toCOMWithWheels:icons$2.toCOMWithWheels,toCOM:icons$2.toCOM,triangleBeam:icons$2.triangleBeam,tulipBeam:icons$2.tulipBeam,tunnel:icons$2.tunnel,twoRoadsAdd:icons$2.twoRoadsAdd,twoRoadsCrossAdd:icons$2.twoRoadsCrossAdd,twoRoadsLink:icons$2.twoRoadsLink,lasso:icons$2.lasso,removeItemPolygon:icons$2.removeItemPolygon,removeListItem:icons$2.removeListItem,bridgeWithRiver:icons$2.bridgeWithRiver,gizmosOutline:icons$2.gizmosOutline,gizmosSolid:icons$2.gizmosSolid,highwayRoad3To2Merge01:icons$2.highwayRoad3To2Merge01,highwayRoad3To2Merge02:icons$2.highwayRoad3To2Merge02,highwayToUrbanRoadTransition01:icons$2.highwayToUrbanRoadTransition01,highwayToUrbanRoadTransition02:icons$2.highwayToUrbanRoadTransition02,pedestrianCrossing01:icons$2.pedestrianCrossing01,polygonalCube:icons$2.polygonalCube,roadEditOutline:icons$2.roadEditOutline,roadEditSolid:icons$2.roadEditSolid,roadFolderPlus:icons$2.roadFolderPlus,roadFolder:icons$2.roadFolder,roadGuideArrowOutline:icons$2.roadGuideArrowOutline,roadGuideArrowSolid:icons$2.roadGuideArrowSolid,roadOutlineMesh:icons$2.roadOutlineMesh,roadPedestrianCrossing02:icons$2.roadPedestrianCrossing02,roadProfileWithCheckmark:icons$2.roadProfileWithCheckmark,roadProfile:icons$2.roadProfile,roadRoundaboutJunction:icons$2.roadRoundaboutJunction,roadSidewalkTransition:icons$2.roadSidewalkTransition,roadStackPlus:icons$2.roadStackPlus,roadStack:icons$2.roadStack,roadTJunction:icons$2.roadTJunction,roadXJunction:icons$2.roadXJunction,roadYJunction:icons$2.roadYJunction,singleLineToTerrain:icons$2.singleLineToTerrain,sphereOnMesh:icons$2.sphereOnMesh,twoLinesToTerrain:icons$2.twoLinesToTerrain,urbanRoad3To2Merge01:icons$2.urbanRoad3To2Merge01,urbanRoad3To2Merge02:icons$2.urbanRoad3To2Merge02,urbanRoadToHighwayTransition01:icons$2.urbanRoadToHighwayTransition01,urbanRoadToHighwayTransition02:icons$2.urbanRoadToHighwayTransition02,highwayMerge:icons$2.highwayMerge,highwaySeparate:icons$2.highwaySeparate,highwayShoulderMerge:icons$2.highwayShoulderMerge,terrainToSingleLine:icons$2.terrainToSingleLine,terrainToTwoLines:icons$2.terrainToTwoLines,urbanRoadMerge:icons$2.urbanRoadMerge,urbanRoadSeparate:icons$2.urbanRoadSeparate,urbanShoulderMerge:icons$2.urbanShoulderMerge},"road tools":{addItemPolygon:icons$2.addItemPolygon,addListItem:icons$2.addListItem,addPolygonVertex:icons$2.addPolygonVertex,bSpline:icons$2.bSpline,beamCrashBarrier1:icons$2.beamCrashBarrier1,beamCrashBarrier2:icons$2.beamCrashBarrier2,beamCrashBarrier3:icons$2.beamCrashBarrier3,bezierPath1:icons$2.bezierPath1,bezierPath2:icons$2.bezierPath2,bicycle1:icons$2.bicycle1,bicycle2:icons$2.bicycle2,bollard:icons$2.bollard,bulldozer:icons$2.bulldozer,concreteRoadBlock:icons$2.concreteRoadBlock,crossroads1:icons$2.crossroads1,crossroads2:icons$2.crossroads2,decalRoad:icons$2.decalRoad,lampPost1:icons$2.lampPost1,lampPost2:icons$2.lampPost2,lampPost3:icons$2.lampPost3,laneProperties:icons$2.laneProperties,lineToTerrain:icons$2.lineToTerrain,magnetOnSurface:icons$2.magnetOnSurface,meshFence:icons$2.meshFence,meshRoad:icons$2.meshRoad,pathArc:icons$2.pathArc,pathLine:icons$2.pathLine,pathSpiral:icons$2.pathSpiral,roadDividerLinesDecal:icons$2.roadDividerLinesDecal,roadEdgeLineDecal:icons$2.roadEdgeLineDecal,roadEndLineDecal:icons$2.roadEndLineDecal,roadFace:icons$2.roadFace,roadMarkingSolid:icons$2.roadMarkingSolid,roadOutline:icons$2.roadOutline,roadRefPathDecal:icons$2.roadRefPathDecal,roadRefPath:icons$2.roadRefPath,roadStartLineDecal:icons$2.roadStartLineDecal,sphereOnPathNumber:icons$2.sphereOnPathNumber,sphereOnPath:icons$2.sphereOnPath,terrainToLine:icons$2.terrainToLine,tunnel:icons$2.tunnel,twoRoadsAdd:icons$2.twoRoadsAdd,twoRoadsCrossAdd:icons$2.twoRoadsCrossAdd,twoRoadsLink:icons$2.twoRoadsLink,removeItemPolygon:icons$2.removeItemPolygon,removeListItem:icons$2.removeListItem,bridgeWithRiver:icons$2.bridgeWithRiver,gizmosOutline:icons$2.gizmosOutline,gizmosSolid:icons$2.gizmosSolid,highwayRoad3To2Merge01:icons$2.highwayRoad3To2Merge01,highwayRoad3To2Merge02:icons$2.highwayRoad3To2Merge02,highwayToUrbanRoadTransition01:icons$2.highwayToUrbanRoadTransition01,highwayToUrbanRoadTransition02:icons$2.highwayToUrbanRoadTransition02,pedestrianCrossing01:icons$2.pedestrianCrossing01,polygonalCube:icons$2.polygonalCube,roadEditOutline:icons$2.roadEditOutline,roadEditSolid:icons$2.roadEditSolid,roadFolderPlus:icons$2.roadFolderPlus,roadFolder:icons$2.roadFolder,roadGuideArrowOutline:icons$2.roadGuideArrowOutline,roadGuideArrowSolid:icons$2.roadGuideArrowSolid,roadOutlineMesh:icons$2.roadOutlineMesh,roadPedestrianCrossing02:icons$2.roadPedestrianCrossing02,roadProfileWithCheckmark:icons$2.roadProfileWithCheckmark,roadProfile:icons$2.roadProfile,roadRoundaboutJunction:icons$2.roadRoundaboutJunction,roadSidewalkTransition:icons$2.roadSidewalkTransition,roadStackPlus:icons$2.roadStackPlus,roadStack:icons$2.roadStack,roadTJunction:icons$2.roadTJunction,roadXJunction:icons$2.roadXJunction,roadYJunction:icons$2.roadYJunction,singleLineToTerrain:icons$2.singleLineToTerrain,sphereOnMesh:icons$2.sphereOnMesh,twoLinesToTerrain:icons$2.twoLinesToTerrain,urbanRoad3To2Merge01:icons$2.urbanRoad3To2Merge01,urbanRoad3To2Merge02:icons$2.urbanRoad3To2Merge02,urbanRoadToHighwayTransition01:icons$2.urbanRoadToHighwayTransition01,urbanRoadToHighwayTransition02:icons$2.urbanRoadToHighwayTransition02,highwayMerge:icons$2.highwayMerge,highwaySeparate:icons$2.highwaySeparate,highwayShoulderMerge:icons$2.highwayShoulderMerge,terrainToSingleLine:icons$2.terrainToSingleLine,terrainToTwoLines:icons$2.terrainToTwoLines,urbanRoadMerge:icons$2.urbanRoadMerge,urbanRoadSeparate:icons$2.urbanRoadSeparate,urbanShoulderMerge:icons$2.urbanShoulderMerge},ai:{AIMicrochip:icons$2.AIMicrochip},microchip:{AIMicrochip:icons$2.AIMicrochip},poi:{AIRace:icons$2.AIRace,barrelKnocker01:icons$2.barrelKnocker01,barrelKnocker02:icons$2.barrelKnocker02,boxDropOff01:icons$2.boxDropOff01,boxDropOff02:icons$2.boxDropOff02,boxDropOff03:icons$2.boxDropOff03,boxPickUp01:icons$2.boxPickUp01,boxPickUp02:icons$2.boxPickUp02,boxPickUp03:icons$2.boxPickUp03,boxPickUpDropOff01:icons$2.boxPickUpDropOff01,boxPickUpDropOff02:icons$2.boxPickUpDropOff02,bus:icons$2.bus,cannon:icons$2.cannon,circuit:icons$2.circuit,deliveryTruckArrows:icons$2.deliveryTruckArrows,deliveryTruck:icons$2.deliveryTruck,drag01:icons$2.drag01,drag02:icons$2.drag02,drift01:icons$2.drift01,drift02:icons$2.drift02,evade:icons$2.evade,fastTravel:icons$2.fastTravel,flagNew:icons$2.flagNew,flag:icons$2.flag,gaugeEmpty:icons$2.gaugeEmpty,hypermiling:icons$2.hypermiling,jump:icons$2.jump,parking:icons$2.parking,raceFlag:icons$2.raceFlag,rockCrawling01:icons$2.rockCrawling01,rockCrawling02:icons$2.rockCrawling02,targetJump:icons$2.targetJump,toGarage:icons$2.toGarage,trashBin1:icons$2.trashBin1,circlePinBack:icons$2.circlePinBack,circlePinFront:icons$2.circlePinFront,markerRectanglePinBack:icons$2.markerRectanglePinBack,markerRectanglePinFront:icons$2.markerRectanglePinFront,markerTriangleBack:icons$2.markerTriangleBack,markerTriangleFront:icons$2.markerTriangleFront,busTilted:icons$2.busTilted,gaugeFull:icons$2.gaugeFull},camera:{aperture:icons$2.aperture,camera3Fourth1:icons$2.camera3Fourth1,cameraBack1:icons$2.cameraBack1,cameraFocusOnPath:icons$2.cameraFocusOnPath,cameraFocusOnVehicle1:icons$2.cameraFocusOnVehicle1,cameraFocusOnVehicle2:icons$2.cameraFocusOnVehicle2,cameraFocusTopDown:icons$2.cameraFocusTopDown,cameraFront1:icons$2.cameraFront1,cameraSideLeft:icons$2.cameraSideLeft,cameraSideLeft2:icons$2.cameraSideLeft2,cameraSideRight:icons$2.cameraSideRight,cameraSideRight2:icons$2.cameraSideRight2,cameraTop1:icons$2.cameraTop1,movieCamera:icons$2.movieCamera,pathAroundObstacle:icons$2.pathAroundObstacle,survellianceCamera:icons$2.survellianceCamera,pathDice:icons$2.pathDice},optical:{aperture:icons$2.aperture,survellianceCamera:icons$2.survellianceCamera},sensor:{aperture:icons$2.aperture,eyeWaves:icons$2.eyeWaves,flatBulbBeam:icons$2.flatBulbBeam,frontAxleMidpoint:icons$2.frontAxleMidpoint,frontBumperMidpoint:icons$2.frontBumperMidpoint,GPSMark:icons$2.GPSMark,GPSSolid:icons$2.GPSSolid,gyroscopeMicrochip:icons$2.gyroscopeMicrochip,gyroscope:icons$2.gyroscope,lidarPatternFullArcHighFreq:icons$2.lidarPatternFullArcHighFreq,lidarPatternFullArcMidFreq:icons$2.lidarPatternFullArcMidFreq,lidarPatternNarrowArc:icons$2.lidarPatternNarrowArc,lidar:icons$2.lidar,location1:icons$2.location1,location2:icons$2.location2,longRangeBeam1:icons$2.longRangeBeam1,longRangeBeam2:icons$2.longRangeBeam2,midRangeBeam1:icons$2.midRangeBeam1,midRangeBeam2:icons$2.midRangeBeam2,radarIdeal:icons$2.radarIdeal,radarRoundIdeal:icons$2.radarRoundIdeal,radarRound:icons$2.radarRound,radar:icons$2.radar,rearAxleMidpoint:icons$2.rearAxleMidpoint,rearBumperMidpoint:icons$2.rearBumperMidpoint,shortRangeBeam1:icons$2.shortRangeBeam1,shortRangeBeam2:icons$2.shortRangeBeam2,sphericalBeam:icons$2.sphericalBeam,survellianceCamera:icons$2.survellianceCamera,thinBulbBeam:icons$2.thinBulbBeam,thinnerBulbBeam:icons$2.thinnerBulbBeam,toCOMWithWheels:icons$2.toCOMWithWheels,toCOM:icons$2.toCOM,triangleBeam:icons$2.triangleBeam,tulipBeam:icons$2.tulipBeam,wavesSignalReceived:icons$2.wavesSignalReceived,wavesSignalSentLeft:icons$2.wavesSignalSentLeft,wavesSignalSentRight:icons$2.wavesSignalSentRight},arrow:{arrowLargeDown:icons$2.arrowLargeDown,arrowLargeLeft:icons$2.arrowLargeLeft,arrowLargeRight:icons$2.arrowLargeRight,arrowLargeUp:icons$2.arrowLargeUp,arrowSmallDown:icons$2.arrowSmallDown,arrowSmallLeft:icons$2.arrowSmallLeft,arrowSmallRight:icons$2.arrowSmallRight,arrowSmallUp:icons$2.arrowSmallUp,arrowSolidLeft:icons$2.arrowSolidLeft,arrowSolidRight:icons$2.arrowSolidRight,twoArrowsHorizontal:icons$2.twoArrowsHorizontal,twoArrowsVertical:icons$2.twoArrowsVertical,arrowsReplace:icons$2.arrowsReplace,arrowsShuffle:icons$2.arrowsShuffle,arrowsSwitch:icons$2.arrowsSwitch,seatArrowIn:icons$2.seatArrowIn,seatArrowOut:icons$2.seatArrowOut,seatVArrowIn:icons$2.seatVArrowIn,seatVArrowOut:icons$2.seatVArrowOut,vehicleArrowIn:icons$2.vehicleArrowIn,vehicleArrowOut:icons$2.vehicleArrowOut,seatArrowInLeft:icons$2.seatArrowInLeft,seatArrowOutLeft:icons$2.seatArrowOutLeft,seatVArrowInLeft:icons$2.seatVArrowInLeft,seatVArrowOutLeft:icons$2.seatVArrowOutLeft},large:{arrowLargeDown:icons$2.arrowLargeDown,arrowLargeLeft:icons$2.arrowLargeLeft,arrowLargeRight:icons$2.arrowLargeRight,arrowLargeUp:icons$2.arrowLargeUp,arrowSolidLeft:icons$2.arrowSolidLeft,arrowSolidRight:icons$2.arrowSolidRight,arrowLeftOutline:icons$2.arrowLeftOutline,arrowRightOutline:icons$2.arrowRightOutline,beamsNodesMessageOutline:icons$2.beamsNodesMessageOutline,beamsNodesOutline:icons$2.beamsNodesOutline,beamsNodesPlugOutline:icons$2.beamsNodesPlugOutline,BNGEcosystemOutline:icons$2.BNGEcosystemOutline,carFrontRouteOutline:icons$2.carFrontRouteOutline,carSensorsOutline:icons$2.carSensorsOutline,carSideRouteOutline:icons$2.carSideRouteOutline,cityOutline:icons$2.cityOutline,dialogOutline:icons$2.dialogOutline,documentSmileOutline:icons$2.documentSmileOutline,drivetrainOutline:icons$2.drivetrainOutline,electronicSchemeOutline:icons$2.electronicSchemeOutline,engineOutline:icons$2.engineOutline,gearTuningOutline:icons$2.gearTuningOutline,giftBoxOutline:icons$2.giftBoxOutline,lidarOutline:icons$2.lidarOutline,medalStarOutline:icons$2.medalStarOutline,megaphoneOutline:icons$2.megaphoneOutline,peopleOutline:icons$2.peopleOutline,personOutline:icons$2.personOutline,physicsOutline:icons$2.physicsOutline,playChainOutline:icons$2.playChainOutline,proximitySensorsOutline:icons$2.proximitySensorsOutline,qualityBadgeStarOutline:icons$2.qualityBadgeStarOutline,qualityBadgeVOutline:icons$2.qualityBadgeVOutline,simRigOutline:icons$2.simRigOutline,suspensionOutline:icons$2.suspensionOutline,teamOutline:icons$2.teamOutline,techLightBulbOutline01:icons$2.techLightBulbOutline01,techLightBulbOutline02:icons$2.techLightBulbOutline02,timeUnlockOutline:icons$2.timeUnlockOutline,timedLockOutline:icons$2.timedLockOutline,trafficOutline:icons$2.trafficOutline,voucherOutline:icons$2.voucherOutline,wheelBeamsNodesOutline:icons$2.wheelBeamsNodesOutline,wheelOutline:icons$2.wheelOutline,twoArrowsHorizontal:icons$2.twoArrowsHorizontal,twoArrowsVertical:icons$2.twoArrowsVertical},simple:{arrowLargeDown:icons$2.arrowLargeDown,arrowLargeLeft:icons$2.arrowLargeLeft,arrowLargeRight:icons$2.arrowLargeRight,arrowLargeUp:icons$2.arrowLargeUp,arrowSmallDown:icons$2.arrowSmallDown,arrowSmallLeft:icons$2.arrowSmallLeft,arrowSmallRight:icons$2.arrowSmallRight,arrowSmallUp:icons$2.arrowSmallUp},outlined:{arrowLargeDown:icons$2.arrowLargeDown,arrowLargeLeft:icons$2.arrowLargeLeft,arrowLargeRight:icons$2.arrowLargeRight,arrowLargeUp:icons$2.arrowLargeUp,arrowSmallDown:icons$2.arrowSmallDown,arrowSmallLeft:icons$2.arrowSmallLeft,arrowSmallRight:icons$2.arrowSmallRight,arrowSmallUp:icons$2.arrowSmallUp,roadMarkingOutline:icons$2.roadMarkingOutline,arrowLeftOutline:icons$2.arrowLeftOutline,arrowRightOutline:icons$2.arrowRightOutline,beamsNodesMessageOutline:icons$2.beamsNodesMessageOutline,beamsNodesOutline:icons$2.beamsNodesOutline,beamsNodesPlugOutline:icons$2.beamsNodesPlugOutline,BNGEcosystemOutline:icons$2.BNGEcosystemOutline,carFrontRouteOutline:icons$2.carFrontRouteOutline,carSensorsOutline:icons$2.carSensorsOutline,carSideRouteOutline:icons$2.carSideRouteOutline,cityOutline:icons$2.cityOutline,dialogOutline:icons$2.dialogOutline,documentSmileOutline:icons$2.documentSmileOutline,drivetrainOutline:icons$2.drivetrainOutline,electronicSchemeOutline:icons$2.electronicSchemeOutline,engineOutline:icons$2.engineOutline,gearTuningOutline:icons$2.gearTuningOutline,giftBoxOutline:icons$2.giftBoxOutline,lidarOutline:icons$2.lidarOutline,medalStarOutline:icons$2.medalStarOutline,megaphoneOutline:icons$2.megaphoneOutline,peopleOutline:icons$2.peopleOutline,personOutline:icons$2.personOutline,physicsOutline:icons$2.physicsOutline,playChainOutline:icons$2.playChainOutline,proximitySensorsOutline:icons$2.proximitySensorsOutline,qualityBadgeStarOutline:icons$2.qualityBadgeStarOutline,qualityBadgeVOutline:icons$2.qualityBadgeVOutline,simRigOutline:icons$2.simRigOutline,suspensionOutline:icons$2.suspensionOutline,teamOutline:icons$2.teamOutline,techLightBulbOutline01:icons$2.techLightBulbOutline01,techLightBulbOutline02:icons$2.techLightBulbOutline02,timeUnlockOutline:icons$2.timeUnlockOutline,timedLockOutline:icons$2.timedLockOutline,trafficOutline:icons$2.trafficOutline,voucherOutline:icons$2.voucherOutline,wheelBeamsNodesOutline:icons$2.wheelBeamsNodesOutline,wheelOutline:icons$2.wheelOutline},small:{arrowSmallDown:icons$2.arrowSmallDown,arrowSmallLeft:icons$2.arrowSmallLeft,arrowSmallRight:icons$2.arrowSmallRight,arrowSmallUp:icons$2.arrowSmallUp,mathDivide:icons$2.mathDivide,mathGreaterOrEqualThan:icons$2.mathGreaterOrEqualThan,mathGreaterThan:icons$2.mathGreaterThan,mathLessOrEqualThan:icons$2.mathLessOrEqualThan,mathLessThan:icons$2.mathLessThan,mathMinus:icons$2.mathMinus,mathMultiply:icons$2.mathMultiply,mathPlus:icons$2.mathPlus,slashLeft:icons$2.slashLeft,slashRight:icons$2.slashRight},solid:{arrowSolidLeft:icons$2.arrowSolidLeft,arrowSolidRight:icons$2.arrowSolidRight,twoArrowsHorizontal:icons$2.twoArrowsHorizontal,twoArrowsVertical:icons$2.twoArrowsVertical},detailed:{arrowSolidLeft:icons$2.arrowSolidLeft,arrowSolidRight:icons$2.arrowSolidRight},career:{banknotes:icons$2.banknotes,beamCurrency:icons$2.beamCurrency,beamXPFull:icons$2.beamXPFull,beamXPLo:icons$2.beamXPLo,carDealer:icons$2.carDealer,garage01:icons$2.garage01,garage02:icons$2.garage02,garage03:icons$2.garage03,lightGarageG11:icons$2.lightGarageG11,lightGarageG12:icons$2.lightGarageG12,lightGarageG13:icons$2.lightGarageG13,lightGarageG14:icons$2.lightGarageG14,lightGarageG21:icons$2.lightGarageG21,lightGarageG22:icons$2.lightGarageG22,lightGarageG23:icons$2.lightGarageG23,lightGarageG24:icons$2.lightGarageG24,lightGarageG31:icons$2.lightGarageG31,lightGarageG32:icons$2.lightGarageG32,lightGarageG33:icons$2.lightGarageG33,lightGarageG34:icons$2.lightGarageG34,plusGarage1:icons$2.plusGarage1,plusGarage2:icons$2.plusGarage2,plusGarage3:icons$2.plusGarage3,plusGarage4:icons$2.plusGarage4,voucherDiagonal1:icons$2.voucherDiagonal1,voucherDiagonal2:icons$2.voucherDiagonal2,voucherDiagonal3:icons$2.voucherDiagonal3,voucherHorizontal1:icons$2.voucherHorizontal1,voucherHorizontal2:icons$2.voucherHorizontal2,voucherHorizontal3:icons$2.voucherHorizontal3,garageNumber1:icons$2.garageNumber1,garageNumber2:icons$2.garageNumber2,garageNumber3:icons$2.garageNumber3,garageNumber4:icons$2.garageNumber4,garageNumber5:icons$2.garageNumber5,garageNumber6:icons$2.garageNumber6,garageNumber7:icons$2.garageNumber7,garageNumber8:icons$2.garageNumber8,garageNumber9:icons$2.garageNumber9,houseWrenchRoof:icons$2.houseWrenchRoof,houseWrench:icons$2.houseWrench,house:icons$2.house,beamCurrencyThin:icons$2.beamCurrencyThin},currencies:{banknotes:icons$2.banknotes,beamCurrency:icons$2.beamCurrency,beamXPFull:icons$2.beamXPFull,beamXPLo:icons$2.beamXPLo,beamCurrencyThin:icons$2.beamCurrencyThin},brand:{beamNG:icons$2.beamNG},beamng:{beamNG:icons$2.beamNG},decals:{booleanIntersect:icons$2.booleanIntersect,cameraFocusOnVehicle2:icons$2.cameraFocusOnVehicle2,copy:icons$2.copy,decal:icons$2.decal,deform:icons$2.deform,group:icons$2.group,material:icons$2.material,move:icons$2.move,order:icons$2.order,paperKnife:icons$2.paperKnife,redo:icons$2.redo,reflectNot:icons$2.reflectNot,reflect:icons$2.reflect,rename:icons$2.rename,sprayCan:icons$2.sprayCan,transform:icons$2.transform,transparencyMask:icons$2.transparencyMask,trashBin2:icons$2.trashBin2,undo:icons$2.undo,ungroup:icons$2.ungroup,view:icons$2.view,weight:icons$2.weight,scale:icons$2.scale,materialGlossy:icons$2.materialGlossy,materialMetal:icons$2.materialMetal,materialRoughness:icons$2.materialRoughness,materialTransparency01:icons$2.materialTransparency01,materialTransparency02:icons$2.materialTransparency02,surfaceRoughness02:icons$2.surfaceRoughness02,cameraFarClip:icons$2.cameraFarClip,cameraNearClip:icons$2.cameraNearClip,viewFarClip:icons$2.viewFarClip,viewNearClip:icons$2.viewNearClip},delivery:{boxDropOff01:icons$2.boxDropOff01,boxDropOff02:icons$2.boxDropOff02,boxDropOff03:icons$2.boxDropOff03,boxPickUp01:icons$2.boxPickUp01,boxPickUp02:icons$2.boxPickUp02,boxPickUp03:icons$2.boxPickUp03,boxPickUpDropOff01:icons$2.boxPickUpDropOff01,boxPickUpDropOff02:icons$2.boxPickUpDropOff02,boxTruck:icons$2.boxTruck,cardboardBox:icons$2.cardboardBox,deliveryTruckArrows:icons$2.deliveryTruckArrows,deliveryTruck:icons$2.deliveryTruck,flatbedTruck:icons$2.flatbedTruck,forklift:icons$2.forklift,fragile:icons$2.fragile,semiTrailer:icons$2.semiTrailer,semiTruckCabover:icons$2.semiTruckCabover,semiTruckUS:icons$2.semiTruckUS,semiTruck:icons$2.semiTruck,smallTrailer:icons$2.smallTrailer,stack3:icons$2.stack3,tankerTrailer:icons$2.tankerTrailer,thisSideUp:icons$2.thisSideUp,twoUnicyclesOnly:icons$2.twoUnicyclesOnly,boxTruckFast:icons$2.boxTruckFast,cardboardBoxCoins:icons$2.cardboardBoxCoins},cargo:{boxTruck:icons$2.boxTruck,flatbedTruck:icons$2.flatbedTruck,forklift:icons$2.forklift,fragile:icons$2.fragile,semiTrailer:icons$2.semiTrailer,semiTruckCabover:icons$2.semiTruckCabover,semiTruckUS:icons$2.semiTruckUS,semiTruck:icons$2.semiTruck,smallTrailer:icons$2.smallTrailer,stack3:icons$2.stack3,tankerTrailer:icons$2.tankerTrailer,thisSideUp:icons$2.thisSideUp,twoUnicyclesOnly:icons$2.twoUnicyclesOnly,boxTruckFast:icons$2.boxTruckFast},sound:{broom:icons$2.broom,soundFadeOut:icons$2.soundFadeOut,soundLimit:icons$2.soundLimit,soundLoud:icons$2.soundLoud,soundMonoL:icons$2.soundMonoL,soundMonoR:icons$2.soundMonoR,soundOff:icons$2.soundOff,soundQuiet:icons$2.soundQuiet,soundStereo:icons$2.soundStereo,soundWave01:icons$2.soundWave01,soundWave02:icons$2.soundWave02,trim:icons$2.trim},police:{carChase01:icons$2.carChase01,carsChase02:icons$2.carsChase02,evade:icons$2.evade,strobeLights:icons$2.strobeLights,wigwags:icons$2.wigwags},garage:{carDealer:icons$2.carDealer,garage01:icons$2.garage01,garage02:icons$2.garage02,garage03:icons$2.garage03,lightGarageG11:icons$2.lightGarageG11,lightGarageG12:icons$2.lightGarageG12,lightGarageG13:icons$2.lightGarageG13,lightGarageG14:icons$2.lightGarageG14,lightGarageG21:icons$2.lightGarageG21,lightGarageG22:icons$2.lightGarageG22,lightGarageG23:icons$2.lightGarageG23,lightGarageG24:icons$2.lightGarageG24,lightGarageG31:icons$2.lightGarageG31,lightGarageG32:icons$2.lightGarageG32,lightGarageG33:icons$2.lightGarageG33,lightGarageG34:icons$2.lightGarageG34,plusGarage1:icons$2.plusGarage1,plusGarage2:icons$2.plusGarage2,plusGarage3:icons$2.plusGarage3,plusGarage4:icons$2.plusGarage4,houseWrenchRoof:icons$2.houseWrenchRoof,houseWrench:icons$2.houseWrench,house:icons$2.house},sensors:{carSensors:icons$2.carSensors,carWithLidar:icons$2.carWithLidar,mapWithEmitter:icons$2.mapWithEmitter},tech:{carWithLidar:icons$2.carWithLidar,mapWithEmitter:icons$2.mapWithEmitter,mesh4Cells:icons$2.mesh4Cells,mesh9Cells:icons$2.mesh9Cells},fuel:{charge:icons$2.charge,charging:icons$2.charging,fuelPumpFilling:icons$2.fuelPumpFilling,fuelPump:icons$2.fuelPump,N2OButton:icons$2.N2OButton,N2OHoriz:icons$2.N2OHoriz,N2OVert:icons$2.N2OVert,discharging:icons$2.discharging},electricity:{charge:icons$2.charge,charging:icons$2.charging,discharging:icons$2.discharging},ev:{charge:icons$2.charge,charging:icons$2.charging,discharging:icons$2.discharging},checkbox:{checkboxOff:icons$2.checkboxOff,checkboxOn:icons$2.checkboxOn,missionCheckboxCross:icons$2.missionCheckboxCross},selection:{checkboxOff:icons$2.checkboxOff,checkboxOn:icons$2.checkboxOn,missionCheckboxCross:icons$2.missionCheckboxCross},box:{checkboxOff:icons$2.checkboxOff,checkboxOn:icons$2.checkboxOn,missionCheckboxCross:icons$2.missionCheckboxCross},movie:{clapperboard:icons$2.clapperboard},scenery:{clapperboard:icons$2.clapperboard},powertrain:{cogsDamaged:icons$2.cogsDamaged},drivetrain:{cogsDamaged:icons$2.cogsDamaged},data:{dataExchange:icons$2.dataExchange,eyeWaves:icons$2.eyeWaves,gyroscopeMicrochip:icons$2.gyroscopeMicrochip,gyroscope:icons$2.gyroscope,lidar:icons$2.lidar,radarIdeal:icons$2.radarIdeal,radarRoundIdeal:icons$2.radarRoundIdeal,radarRound:icons$2.radarRound,radar:icons$2.radar,wavesSignalReceived:icons$2.wavesSignalReceived,wavesSignalSentLeft:icons$2.wavesSignalSentLeft,wavesSignalSentRight:icons$2.wavesSignalSentRight},signal:{dataExchange:icons$2.dataExchange,eyeWaves:icons$2.eyeWaves,gyroscopeMicrochip:icons$2.gyroscopeMicrochip,gyroscope:icons$2.gyroscope,lidar:icons$2.lidar,radarIdeal:icons$2.radarIdeal,radarRoundIdeal:icons$2.radarRoundIdeal,radarRound:icons$2.radarRound,radar:icons$2.radar,wavesSignalReceived:icons$2.wavesSignalReceived,wavesSignalSentLeft:icons$2.wavesSignalSentLeft,wavesSignalSentRight:icons$2.wavesSignalSentRight},environment:{day:icons$2.day,night:icons$2.night,sunRise:icons$2.sunRise,weather:icons$2.weather,sunDown:icons$2.sunDown},part:{engine:icons$2.engine,suspension01:icons$2.suspension01,turbine:icons$2.turbine,doorFrontCoins:icons$2.doorFrontCoins,doorFront:icons$2.doorFront,engineCoins:icons$2.engineCoins,exhaustMufflerCoins:icons$2.exhaustMufflerCoins,exhaustMuffler:icons$2.exhaustMuffler,headlightCoins:icons$2.headlightCoins,headlight:icons$2.headlight,tire3FourthCoins:icons$2.tire3FourthCoins,tire3Fourth:icons$2.tire3Fourth,turbineCoins:icons$2.turbineCoins,wheelDiscCoins:icons$2.wheelDiscCoins,wheelDisc:icons$2.wheelDisc,doorFrontDetached:icons$2.doorFrontDetached,hingeBroken:icons$2.hingeBroken},mission:{evade:icons$2.evade,flagOutlineLarge:icons$2.flagOutlineLarge},playback:{fastBackward:icons$2.fastBackward,fastForward:icons$2.fastForward,music:icons$2.music,nextTrack:icons$2.nextTrack,pauseRound:icons$2.pauseRound,pause:icons$2.pause,playRound:icons$2.playRound,play:icons$2.play,playlist:icons$2.playlist,prevTrack:icons$2.prevTrack,square:icons$2.square,eject:icons$2.eject,playPause:icons$2.playPause},truck:{flatbedTruck:icons$2.flatbedTruck,semiTruckCabover:icons$2.semiTruckCabover,semiTruckUS:icons$2.semiTruckUS,semiTruck:icons$2.semiTruck},stencil:{forklift:icons$2.forklift,fragile:icons$2.fragile,stack3:icons$2.stack3,thisSideUp:icons$2.thisSideUp,twoUnicyclesOnly:icons$2.twoUnicyclesOnly},placement:{frontAxleMidpoint:icons$2.frontAxleMidpoint,frontBumperMidpoint:icons$2.frontBumperMidpoint,rearAxleMidpoint:icons$2.rearAxleMidpoint,rearBumperMidpoint:icons$2.rearBumperMidpoint,toCOMWithWheels:icons$2.toCOMWithWheels,toCOM:icons$2.toCOM},gamepad:{gamepadOld:icons$2.gamepadOld,gamepad:icons$2.gamepad,noNameControllerButton:icons$2.noNameControllerButton,xboxA:icons$2.xboxA,xboxB:icons$2.xboxB,xboxDDefaultOutline:icons$2.xboxDDefaultOutline,xboxDDefaultSolid:icons$2.xboxDDefaultSolid,xboxDDown:icons$2.xboxDDown,xboxDLeft:icons$2.xboxDLeft,xboxDRight:icons$2.xboxDRight,xboxDUp:icons$2.xboxDUp,xboxLB:icons$2.xboxLB,xboxLSButton:icons$2.xboxLSButton,xboxLT:icons$2.xboxLT,xboxMenu:icons$2.xboxMenu,xboxRB:icons$2.xboxRB,xboxRSButton:icons$2.xboxRSButton,xboxRT:icons$2.xboxRT,xboxThumbL:icons$2.xboxThumbL,xboxThumbR:icons$2.xboxThumbR,xboxView:icons$2.xboxView,xboxXAxis:icons$2.xboxXAxis,xboxXRot:icons$2.xboxXRot,xboxX:icons$2.xboxX,xboxYAxis:icons$2.xboxYAxis,xboxYRot:icons$2.xboxYRot,xboxY:icons$2.xboxY,psCircleOutline:icons$2.psCircleOutline,psCircle:icons$2.psCircle,psCreate2:icons$2.psCreate2,psCreate:icons$2.psCreate,psCrossOutline:icons$2.psCrossOutline,psCross:icons$2.psCross,psDDefaultOutline:icons$2.psDDefaultOutline,psDDefaultSolid:icons$2.psDDefaultSolid,psDDown:icons$2.psDDown,psDLeft:icons$2.psDLeft,psDRight:icons$2.psDRight,psDUp:icons$2.psDUp,psL1:icons$2.psL1,psL2:icons$2.psL2,psL3ButtonArrowDown:icons$2.psL3ButtonArrowDown,psL3Button:icons$2.psL3Button,psLSXLeft:icons$2.psLSXLeft,psLSXRight:icons$2.psLSXRight,psLSX:icons$2.psLSX,psLSYDown:icons$2.psLSYDown,psLSYUp:icons$2.psLSYUp,psLSY:icons$2.psLSY,psLS:icons$2.psLS,psMenu2:icons$2.psMenu2,psMenu:icons$2.psMenu,psR1:icons$2.psR1,psR2:icons$2.psR2,psR3ButtonArrowDown:icons$2.psR3ButtonArrowDown,psR3Button:icons$2.psR3Button,psRSXLeft:icons$2.psRSXLeft,psRSXRight:icons$2.psRSXRight,psRSX:icons$2.psRSX,psRSYDown:icons$2.psRSYDown,psRSYUp:icons$2.psRSYUp,psRSY:icons$2.psRSY,psRS:icons$2.psRS,psSquareOutline:icons$2.psSquareOutline,psSquare:icons$2.psSquare,psTrackpadNavigate:icons$2.psTrackpadNavigate,psTrackpadPressCenter:icons$2.psTrackpadPressCenter,psTrackpadPressLeft:icons$2.psTrackpadPressLeft,psTrackpadPressRight:icons$2.psTrackpadPressRight,psTrackpadSwipeDown:icons$2.psTrackpadSwipeDown,psTrackpadSwipeLeft:icons$2.psTrackpadSwipeLeft,psTrackpadSwipeRight:icons$2.psTrackpadSwipeRight,psTrackpadSwipeUp:icons$2.psTrackpadSwipeUp,psTriangleOutline:icons$2.psTriangleOutline,psTriangle:icons$2.psTriangle,xboxAOutline:icons$2.xboxAOutline,xboxBOutline:icons$2.xboxBOutline,xboxLSButtonArrowDown:icons$2.xboxLSButtonArrowDown,xboxRSButtonArrowDown:icons$2.xboxRSButtonArrowDown,xboxXAxisLeft:icons$2.xboxXAxisLeft,xboxXAxisRight:icons$2.xboxXAxisRight,xboxXOutline:icons$2.xboxXOutline,xboxXRotLeft:icons$2.xboxXRotLeft,xboxXRotRight:icons$2.xboxXRotRight,xboxYAxisDown:icons$2.xboxYAxisDown,xboxYAxisUp:icons$2.xboxYAxisUp,xboxYOutline:icons$2.xboxYOutline,xboxYRotDown:icons$2.xboxYRotDown,xboxYRotUp:icons$2.xboxYRotUp,psDLeftRight:icons$2.psDLeftRight,psDUpDown:icons$2.psDUpDown,xboxDLeftRight:icons$2.xboxDLeftRight,xboxDUpDown:icons$2.xboxDUpDown},controller:{gamepadOld:icons$2.gamepadOld,gamepad:icons$2.gamepad,noNameControllerButton:icons$2.noNameControllerButton,steeringWheelCommon:icons$2.steeringWheelCommon,steeringWheelSporty:icons$2.steeringWheelSporty,xboxA:icons$2.xboxA,xboxB:icons$2.xboxB,xboxDDefaultOutline:icons$2.xboxDDefaultOutline,xboxDDefaultSolid:icons$2.xboxDDefaultSolid,xboxDDown:icons$2.xboxDDown,xboxDLeft:icons$2.xboxDLeft,xboxDRight:icons$2.xboxDRight,xboxDUp:icons$2.xboxDUp,xboxLB:icons$2.xboxLB,xboxLSButton:icons$2.xboxLSButton,xboxLT:icons$2.xboxLT,xboxMenu:icons$2.xboxMenu,xboxRB:icons$2.xboxRB,xboxRSButton:icons$2.xboxRSButton,xboxRT:icons$2.xboxRT,xboxThumbL:icons$2.xboxThumbL,xboxThumbR:icons$2.xboxThumbR,xboxView:icons$2.xboxView,xboxXAxis:icons$2.xboxXAxis,xboxXRot:icons$2.xboxXRot,xboxX:icons$2.xboxX,xboxYAxis:icons$2.xboxYAxis,xboxYRot:icons$2.xboxYRot,xboxY:icons$2.xboxY,psCircleOutline:icons$2.psCircleOutline,psCircle:icons$2.psCircle,psCreate2:icons$2.psCreate2,psCreate:icons$2.psCreate,psCrossOutline:icons$2.psCrossOutline,psCross:icons$2.psCross,psDDefaultOutline:icons$2.psDDefaultOutline,psDDefaultSolid:icons$2.psDDefaultSolid,psDDown:icons$2.psDDown,psDLeft:icons$2.psDLeft,psDRight:icons$2.psDRight,psDUp:icons$2.psDUp,psL1:icons$2.psL1,psL2:icons$2.psL2,psL3ButtonArrowDown:icons$2.psL3ButtonArrowDown,psL3Button:icons$2.psL3Button,psLSXLeft:icons$2.psLSXLeft,psLSXRight:icons$2.psLSXRight,psLSX:icons$2.psLSX,psLSYDown:icons$2.psLSYDown,psLSYUp:icons$2.psLSYUp,psLSY:icons$2.psLSY,psLS:icons$2.psLS,psMenu2:icons$2.psMenu2,psMenu:icons$2.psMenu,psR1:icons$2.psR1,psR2:icons$2.psR2,psR3ButtonArrowDown:icons$2.psR3ButtonArrowDown,psR3Button:icons$2.psR3Button,psRSXLeft:icons$2.psRSXLeft,psRSXRight:icons$2.psRSXRight,psRSX:icons$2.psRSX,psRSYDown:icons$2.psRSYDown,psRSYUp:icons$2.psRSYUp,psRSY:icons$2.psRSY,psRS:icons$2.psRS,psSquareOutline:icons$2.psSquareOutline,psSquare:icons$2.psSquare,psTrackpadNavigate:icons$2.psTrackpadNavigate,psTrackpadPressCenter:icons$2.psTrackpadPressCenter,psTrackpadPressLeft:icons$2.psTrackpadPressLeft,psTrackpadPressRight:icons$2.psTrackpadPressRight,psTrackpadSwipeDown:icons$2.psTrackpadSwipeDown,psTrackpadSwipeLeft:icons$2.psTrackpadSwipeLeft,psTrackpadSwipeRight:icons$2.psTrackpadSwipeRight,psTrackpadSwipeUp:icons$2.psTrackpadSwipeUp,psTriangleOutline:icons$2.psTriangleOutline,psTriangle:icons$2.psTriangle,xboxAOutline:icons$2.xboxAOutline,xboxBOutline:icons$2.xboxBOutline,xboxLSButtonArrowDown:icons$2.xboxLSButtonArrowDown,xboxRSButtonArrowDown:icons$2.xboxRSButtonArrowDown,xboxXAxisLeft:icons$2.xboxXAxisLeft,xboxXAxisRight:icons$2.xboxXAxisRight,xboxXOutline:icons$2.xboxXOutline,xboxXRotLeft:icons$2.xboxXRotLeft,xboxXRotRight:icons$2.xboxXRotRight,xboxYAxisDown:icons$2.xboxYAxisDown,xboxYAxisUp:icons$2.xboxYAxisUp,xboxYOutline:icons$2.xboxYOutline,xboxYRotDown:icons$2.xboxYRotDown,xboxYRotUp:icons$2.xboxYRotUp,psDLeftRight:icons$2.psDLeftRight,psDUpDown:icons$2.psDUpDown,xboxDLeftRight:icons$2.xboxDLeftRight,xboxDUpDown:icons$2.xboxDUpDown},input:{gamepadOld:icons$2.gamepadOld,gamepad:icons$2.gamepad,keyboard:icons$2.keyboard,mouseLMB:icons$2.mouseLMB,mouseMMB:icons$2.mouseMMB,mouseRMB:icons$2.mouseRMB,mouseWheel:icons$2.mouseWheel,mouseXAxis:icons$2.mouseXAxis,mouseXYAxis:icons$2.mouseXYAxis,mouseYAxis:icons$2.mouseYAxis,mouse:icons$2.mouse,noNameControllerButton:icons$2.noNameControllerButton,palmCrossed:icons$2.palmCrossed,smartphone1:icons$2.smartphone1,smartphone2:icons$2.smartphone2,steeringWheelCommon:icons$2.steeringWheelCommon,steeringWheelSporty:icons$2.steeringWheelSporty,touch:icons$2.touch,xboxA:icons$2.xboxA,xboxB:icons$2.xboxB,xboxDDefaultOutline:icons$2.xboxDDefaultOutline,xboxDDefaultSolid:icons$2.xboxDDefaultSolid,xboxDDown:icons$2.xboxDDown,xboxDLeft:icons$2.xboxDLeft,xboxDRight:icons$2.xboxDRight,xboxDUp:icons$2.xboxDUp,xboxLB:icons$2.xboxLB,xboxLSButton:icons$2.xboxLSButton,xboxLT:icons$2.xboxLT,xboxMenu:icons$2.xboxMenu,xboxRB:icons$2.xboxRB,xboxRSButton:icons$2.xboxRSButton,xboxRT:icons$2.xboxRT,xboxThumbL:icons$2.xboxThumbL,xboxThumbR:icons$2.xboxThumbR,xboxView:icons$2.xboxView,xboxXAxis:icons$2.xboxXAxis,xboxXRot:icons$2.xboxXRot,xboxX:icons$2.xboxX,xboxYAxis:icons$2.xboxYAxis,xboxYRot:icons$2.xboxYRot,xboxY:icons$2.xboxY,psCircleOutline:icons$2.psCircleOutline,psCircle:icons$2.psCircle,psCreate2:icons$2.psCreate2,psCreate:icons$2.psCreate,psCrossOutline:icons$2.psCrossOutline,psCross:icons$2.psCross,psDDefaultOutline:icons$2.psDDefaultOutline,psDDefaultSolid:icons$2.psDDefaultSolid,psDDown:icons$2.psDDown,psDLeft:icons$2.psDLeft,psDRight:icons$2.psDRight,psDUp:icons$2.psDUp,psL1:icons$2.psL1,psL2:icons$2.psL2,psL3ButtonArrowDown:icons$2.psL3ButtonArrowDown,psL3Button:icons$2.psL3Button,psLSXLeft:icons$2.psLSXLeft,psLSXRight:icons$2.psLSXRight,psLSX:icons$2.psLSX,psLSYDown:icons$2.psLSYDown,psLSYUp:icons$2.psLSYUp,psLSY:icons$2.psLSY,psLS:icons$2.psLS,psMenu2:icons$2.psMenu2,psMenu:icons$2.psMenu,psR1:icons$2.psR1,psR2:icons$2.psR2,psR3ButtonArrowDown:icons$2.psR3ButtonArrowDown,psR3Button:icons$2.psR3Button,psRSXLeft:icons$2.psRSXLeft,psRSXRight:icons$2.psRSXRight,psRSX:icons$2.psRSX,psRSYDown:icons$2.psRSYDown,psRSYUp:icons$2.psRSYUp,psRSY:icons$2.psRSY,psRS:icons$2.psRS,psSquareOutline:icons$2.psSquareOutline,psSquare:icons$2.psSquare,psTrackpadNavigate:icons$2.psTrackpadNavigate,psTrackpadPressCenter:icons$2.psTrackpadPressCenter,psTrackpadPressLeft:icons$2.psTrackpadPressLeft,psTrackpadPressRight:icons$2.psTrackpadPressRight,psTrackpadSwipeDown:icons$2.psTrackpadSwipeDown,psTrackpadSwipeLeft:icons$2.psTrackpadSwipeLeft,psTrackpadSwipeRight:icons$2.psTrackpadSwipeRight,psTrackpadSwipeUp:icons$2.psTrackpadSwipeUp,psTriangleOutline:icons$2.psTriangleOutline,psTriangle:icons$2.psTriangle,xboxAOutline:icons$2.xboxAOutline,xboxBOutline:icons$2.xboxBOutline,xboxLSButtonArrowDown:icons$2.xboxLSButtonArrowDown,xboxRSButtonArrowDown:icons$2.xboxRSButtonArrowDown,xboxXAxisLeft:icons$2.xboxXAxisLeft,xboxXAxisRight:icons$2.xboxXAxisRight,xboxXOutline:icons$2.xboxXOutline,xboxXRotLeft:icons$2.xboxXRotLeft,xboxXRotRight:icons$2.xboxXRotRight,xboxYAxisDown:icons$2.xboxYAxisDown,xboxYAxisUp:icons$2.xboxYAxisUp,xboxYOutline:icons$2.xboxYOutline,xboxYRotDown:icons$2.xboxYRotDown,xboxYRotUp:icons$2.xboxYRotUp,psDLeftRight:icons$2.psDLeftRight,psDUpDown:icons$2.psDUpDown,xboxDLeftRight:icons$2.xboxDLeftRight,xboxDUpDown:icons$2.xboxDUpDown},gps:{GPSMark:icons$2.GPSMark,GPSSolid:icons$2.GPSSolid,location1:icons$2.location1,location2:icons$2.location2},position:{GPSMark:icons$2.GPSMark,GPSSolid:icons$2.GPSSolid,location1:icons$2.location1,location2:icons$2.location2},map:{GPSMark:icons$2.GPSMark,GPSSolid:icons$2.GPSSolid,location1:icons$2.location1,location2:icons$2.location2},keyboard:{keyboard:icons$2.keyboard,kbArrowsDown:icons$2.kbArrowsDown,kbArrowsLeftRight:icons$2.kbArrowsLeftRight,kbArrowsLeft:icons$2.kbArrowsLeft,kbArrowsOutline:icons$2.kbArrowsOutline,kbArrowsRight:icons$2.kbArrowsRight,kbArrowsSolid:icons$2.kbArrowsSolid,kbArrowsUpDown:icons$2.kbArrowsUpDown,kbArrowsUp:icons$2.kbArrowsUp},lights:{lightGarageG11:icons$2.lightGarageG11,lightGarageG12:icons$2.lightGarageG12,lightGarageG13:icons$2.lightGarageG13,lightGarageG14:icons$2.lightGarageG14,lightGarageG21:icons$2.lightGarageG21,lightGarageG22:icons$2.lightGarageG22,lightGarageG23:icons$2.lightGarageG23,lightGarageG24:icons$2.lightGarageG24,lightGarageG31:icons$2.lightGarageG31,lightGarageG32:icons$2.lightGarageG32,lightGarageG33:icons$2.lightGarageG33,lightGarageG34:icons$2.lightGarageG34},catalog:{listBig:icons$2.listBig,listSmall:icons$2.listSmall,tiles:icons$2.tiles},selector:{listBig:icons$2.listBig,listSmall:icons$2.listSmall,tiles:icons$2.tiles},view:{listBig:icons$2.listBig,listSmall:icons$2.listSmall,tiles:icons$2.tiles},math:{mathDivide:icons$2.mathDivide,mathGreaterOrEqualThan:icons$2.mathGreaterOrEqualThan,mathGreaterThan:icons$2.mathGreaterThan,mathLessOrEqualThan:icons$2.mathLessOrEqualThan,mathLessThan:icons$2.mathLessThan,mathMinus:icons$2.mathMinus,mathMultiply:icons$2.mathMultiply,mathPlus:icons$2.mathPlus,slashLeft:icons$2.slashLeft,slashRight:icons$2.slashRight},operands:{mathDivide:icons$2.mathDivide,mathGreaterOrEqualThan:icons$2.mathGreaterOrEqualThan,mathGreaterThan:icons$2.mathGreaterThan,mathLessOrEqualThan:icons$2.mathLessOrEqualThan,mathLessThan:icons$2.mathLessThan,mathMinus:icons$2.mathMinus,mathMultiply:icons$2.mathMultiply,mathPlus:icons$2.mathPlus,slashLeft:icons$2.slashLeft,slashRight:icons$2.slashRight},reward:{medal:icons$2.medal,voucherDiagonal1:icons$2.voucherDiagonal1,voucherDiagonal2:icons$2.voucherDiagonal2,voucherDiagonal3:icons$2.voucherDiagonal3,voucherHorizontal1:icons$2.voucherHorizontal1,voucherHorizontal2:icons$2.voucherHorizontal2,voucherHorizontal3:icons$2.voucherHorizontal3,medalEmpty:icons$2.medalEmpty,medalStar:icons$2.medalStar,badgeRoundEmpty:icons$2.badgeRoundEmpty,badgeRoundStar:icons$2.badgeRoundStar,badgeRound:icons$2.badgeRound,badge:icons$2.badge},achievment:{medal:icons$2.medal,medalEmpty:icons$2.medalEmpty,medalStar:icons$2.medalStar,badgeRoundEmpty:icons$2.badgeRoundEmpty,badgeRoundStar:icons$2.badgeRoundStar,badgeRound:icons$2.badgeRound,badge:icons$2.badge},mesh:{mesh4Cells:icons$2.mesh4Cells,mesh9Cells:icons$2.mesh9Cells},beams:{mesh4Cells:icons$2.mesh4Cells,mesh9Cells:icons$2.mesh9Cells},nodes:{mesh4Cells:icons$2.mesh4Cells,mesh9Cells:icons$2.mesh9Cells},surface:{mesh4Cells:icons$2.mesh4Cells,mesh9Cells:icons$2.mesh9Cells,bridge:icons$2.bridge,bump:icons$2.bump,bumps:icons$2.bumps,caution:icons$2.caution,crest:icons$2.crest,doubleCaution:icons$2.doubleCaution,finish:icons$2.finish,jumpOverBump:icons$2.jumpOverBump,narrows:icons$2.narrows,pothole:icons$2.pothole,turn1:icons$2.turn1,turn2:icons$2.turn2,turn3:icons$2.turn3,turn4:icons$2.turn4,turn5:icons$2.turn5,turn6:icons$2.turn6,turnHp:icons$2.turnHp,turnSq:icons$2.turnSq,water:icons$2.water,tripleCaution:icons$2.tripleCaution},mirror:{mirrorInteriorMiddle:icons$2.mirrorInteriorMiddle,mirrorLeftBigBottomWideAngle:icons$2.mirrorLeftBigBottomWideAngle,mirrorLeftBigTop:icons$2.mirrorLeftBigTop,mirrorLeftBig:icons$2.mirrorLeftBig,mirrorLeftBonnet:icons$2.mirrorLeftBonnet,mirrorLeftDefault:icons$2.mirrorLeftDefault,mirrorRightBigBottomWideAngle:icons$2.mirrorRightBigBottomWideAngle,mirrorRightBigTop:icons$2.mirrorRightBigTop,mirrorRightBig:icons$2.mirrorRightBig,mirrorRightBonnet:icons$2.mirrorRightBonnet,mirrorRightDefault:icons$2.mirrorRightDefault,mirrorRoundWideAngle:icons$2.mirrorRoundWideAngle,mirrorTopWideAngle:icons$2.mirrorTopWideAngle},rearview:{mirrorInteriorMiddle:icons$2.mirrorInteriorMiddle,mirrorLeftBigBottomWideAngle:icons$2.mirrorLeftBigBottomWideAngle,mirrorLeftBigTop:icons$2.mirrorLeftBigTop,mirrorLeftBig:icons$2.mirrorLeftBig,mirrorLeftBonnet:icons$2.mirrorLeftBonnet,mirrorLeftDefault:icons$2.mirrorLeftDefault,mirrorRightBigBottomWideAngle:icons$2.mirrorRightBigBottomWideAngle,mirrorRightBigTop:icons$2.mirrorRightBigTop,mirrorRightBig:icons$2.mirrorRightBig,mirrorRightBonnet:icons$2.mirrorRightBonnet,mirrorRightDefault:icons$2.mirrorRightDefault,mirrorRoundWideAngle:icons$2.mirrorRoundWideAngle,mirrorTopWideAngle:icons$2.mirrorTopWideAngle},mouse:{mouseLMB:icons$2.mouseLMB,mouseMMB:icons$2.mouseMMB,mouseRMB:icons$2.mouseRMB,mouseWheel:icons$2.mouseWheel,mouseXAxis:icons$2.mouseXAxis,mouseXYAxis:icons$2.mouseXYAxis,mouseYAxis:icons$2.mouseYAxis,mouse:icons$2.mouse},path:{nodeAddFirst01:icons$2.nodeAddFirst01,nodeAddFirst02:icons$2.nodeAddFirst02,nodeAddLast02:icons$2.nodeAddLast02,nodeAddMiddle01:icons$2.nodeAddMiddle01,nodeAddMiddle02:icons$2.nodeAddMiddle02,nodeAdd:icons$2.nodeAdd,nodeLast01:icons$2.nodeLast01,nodeRemove:icons$2.nodeRemove,locationDestination:icons$2.locationDestination,locationSource:icons$2.locationSource},node:{nodeAddFirst01:icons$2.nodeAddFirst01,nodeAddFirst02:icons$2.nodeAddFirst02,nodeAddLast02:icons$2.nodeAddLast02,nodeAddMiddle01:icons$2.nodeAddMiddle01,nodeAddMiddle02:icons$2.nodeAddMiddle02,nodeAdd:icons$2.nodeAdd,nodeLast01:icons$2.nodeLast01,nodeRemove:icons$2.nodeRemove,locationDestination:icons$2.locationDestination,locationSource:icons$2.locationSource},touch:{palmCrossed:icons$2.palmCrossed,smartphone1:icons$2.smartphone1,smartphone2:icons$2.smartphone2,touch:icons$2.touch},route:{routeAdd:icons$2.routeAdd,routeComplex:icons$2.routeComplex,routeSimple:icons$2.routeSimple,trafficCone:icons$2.trafficCone,locationDestination:icons$2.locationDestination,locationSource:icons$2.locationSource,routeSimpleFlag:icons$2.routeSimpleFlag},traffic:{routeAdd:icons$2.routeAdd,routeComplex:icons$2.routeComplex,routeSimple:icons$2.routeSimple,trafficCone:icons$2.trafficCone,trafficLight:icons$2.trafficLight,pedestrianRunning:icons$2.pedestrianRunning,pedestrianStanding:icons$2.pedestrianStanding,routeSimpleFlag:icons$2.routeSimpleFlag},trailer:{semiTrailer:icons$2.semiTrailer,semiTruck:icons$2.semiTruck,smallTrailer:icons$2.smallTrailer,tankerTrailer:icons$2.tankerTrailer},steering:{steeringWheelCommon:icons$2.steeringWheelCommon,steeringWheelSporty:icons$2.steeringWheelSporty},time:{stopwatchArrows01:icons$2.stopwatchArrows01,stopwatchArrows02:icons$2.stopwatchArrows02,stopwatchSectionOutlinedEnd:icons$2.stopwatchSectionOutlinedEnd,stopwatchSectionOutlinedStart:icons$2.stopwatchSectionOutlinedStart,stopwatchSectionSolidEnd:icons$2.stopwatchSectionSolidEnd,stopwatchSectionSolidStart:icons$2.stopwatchSectionSolidStart,timer:icons$2.timer},fast:{stopwatchArrows01:icons$2.stopwatchArrows01,stopwatchArrows02:icons$2.stopwatchArrows02,stopwatchSectionOutlinedEnd:icons$2.stopwatchSectionOutlinedEnd,stopwatchSectionOutlinedStart:icons$2.stopwatchSectionOutlinedStart,stopwatchSectionSolidEnd:icons$2.stopwatchSectionSolidEnd,stopwatchSectionSolidStart:icons$2.stopwatchSectionSolidStart,timer:icons$2.timer},emergency:{strobeLights:icons$2.strobeLights,wigwags:icons$2.wigwags},circuit:{switchBlock:icons$2.switchBlock,switchOutline:icons$2.switchOutline},electronics:{switchBlock:icons$2.switchBlock,switchOutline:icons$2.switchOutline},switch:{switchBlock:icons$2.switchBlock,switchOutline:icons$2.switchOutline},tank:{tankerTrailer:icons$2.tankerTrailer},tanker:{tankerTrailer:icons$2.tankerTrailer},taxi:{taxiCar1:icons$2.taxiCar1,taxiCar3:icons$2.taxiCar3,taxiCarT:icons$2.taxiCarT,taxiCheckerLamp:icons$2.taxiCheckerLamp},tire:{tireDirection3Fourth2:icons$2.tireDirection3Fourth2,tireDirection3Fourth3:icons$2.tireDirection3Fourth3,tireDirectionFront2:icons$2.tireDirectionFront2,tireDirectionSide2:icons$2.tireDirectionSide2,tireDirectionTop2:icons$2.tireDirectionTop2,tire3FourthCoins:icons$2.tire3FourthCoins,tire3Fourth:icons$2.tire3Fourth},currency:{voucherDiagonal1:icons$2.voucherDiagonal1,voucherDiagonal2:icons$2.voucherDiagonal2,voucherDiagonal3:icons$2.voucherDiagonal3,voucherHorizontal1:icons$2.voucherHorizontal1,voucherHorizontal2:icons$2.voucherHorizontal2,voucherHorizontal3:icons$2.voucherHorizontal3,beamCurrencyOutlineLarge:icons$2.beamCurrencyOutlineLarge},extra:{AIL:icons$2.AIL,automaticTransmissionL:icons$2.automaticTransmissionL,chargeLL:icons$2.chargeLL,clutchL:icons$2.clutchL,couplerL:icons$2.couplerL,engineL:icons$2.engineL,multiseatL:icons$2.multiseatL,POITimeL:icons$2.POITimeL,replayL:icons$2.replayL,roadblockL:icons$2.roadblockL,rotationL:icons$2.rotationL,sensorsL:icons$2.sensorsL,temperatureL:icons$2.temperatureL,tuningL:icons$2.tuningL,turbineL:icons$2.turbineL},web:{arrowLeftOutline:icons$2.arrowLeftOutline,arrowRightOutline:icons$2.arrowRightOutline,beamsNodesMessageOutline:icons$2.beamsNodesMessageOutline,beamsNodesOutline:icons$2.beamsNodesOutline,beamsNodesPlugOutline:icons$2.beamsNodesPlugOutline,BNGEcosystemOutline:icons$2.BNGEcosystemOutline,carFrontRouteOutline:icons$2.carFrontRouteOutline,carSensorsOutline:icons$2.carSensorsOutline,carSideRouteOutline:icons$2.carSideRouteOutline,cityOutline:icons$2.cityOutline,dialogOutline:icons$2.dialogOutline,documentSmileOutline:icons$2.documentSmileOutline,drivetrainOutline:icons$2.drivetrainOutline,electronicSchemeOutline:icons$2.electronicSchemeOutline,engineOutline:icons$2.engineOutline,gearTuningOutline:icons$2.gearTuningOutline,giftBoxOutline:icons$2.giftBoxOutline,lidarOutline:icons$2.lidarOutline,medalStarOutline:icons$2.medalStarOutline,megaphoneOutline:icons$2.megaphoneOutline,peopleOutline:icons$2.peopleOutline,personOutline:icons$2.personOutline,physicsOutline:icons$2.physicsOutline,playChainOutline:icons$2.playChainOutline,proximitySensorsOutline:icons$2.proximitySensorsOutline,qualityBadgeStarOutline:icons$2.qualityBadgeStarOutline,qualityBadgeVOutline:icons$2.qualityBadgeVOutline,simRigOutline:icons$2.simRigOutline,suspensionOutline:icons$2.suspensionOutline,teamOutline:icons$2.teamOutline,techLightBulbOutline01:icons$2.techLightBulbOutline01,techLightBulbOutline02:icons$2.techLightBulbOutline02,timeUnlockOutline:icons$2.timeUnlockOutline,timedLockOutline:icons$2.timedLockOutline,trafficOutline:icons$2.trafficOutline,voucherOutline:icons$2.voucherOutline,wheelBeamsNodesOutline:icons$2.wheelBeamsNodesOutline,wheelOutline:icons$2.wheelOutline},secondary:{arrowLeftOutline:icons$2.arrowLeftOutline,arrowRightOutline:icons$2.arrowRightOutline,beamsNodesMessageOutline:icons$2.beamsNodesMessageOutline,beamsNodesOutline:icons$2.beamsNodesOutline,beamsNodesPlugOutline:icons$2.beamsNodesPlugOutline,BNGEcosystemOutline:icons$2.BNGEcosystemOutline,carFrontRouteOutline:icons$2.carFrontRouteOutline,carSensorsOutline:icons$2.carSensorsOutline,carSideRouteOutline:icons$2.carSideRouteOutline,cityOutline:icons$2.cityOutline,dialogOutline:icons$2.dialogOutline,documentSmileOutline:icons$2.documentSmileOutline,drivetrainOutline:icons$2.drivetrainOutline,electronicSchemeOutline:icons$2.electronicSchemeOutline,engineOutline:icons$2.engineOutline,gearTuningOutline:icons$2.gearTuningOutline,giftBoxOutline:icons$2.giftBoxOutline,lidarOutline:icons$2.lidarOutline,medalStarOutline:icons$2.medalStarOutline,megaphoneOutline:icons$2.megaphoneOutline,peopleOutline:icons$2.peopleOutline,personOutline:icons$2.personOutline,physicsOutline:icons$2.physicsOutline,playChainOutline:icons$2.playChainOutline,proximitySensorsOutline:icons$2.proximitySensorsOutline,qualityBadgeStarOutline:icons$2.qualityBadgeStarOutline,qualityBadgeVOutline:icons$2.qualityBadgeVOutline,simRigOutline:icons$2.simRigOutline,suspensionOutline:icons$2.suspensionOutline,teamOutline:icons$2.teamOutline,techLightBulbOutline01:icons$2.techLightBulbOutline01,techLightBulbOutline02:icons$2.techLightBulbOutline02,timeUnlockOutline:icons$2.timeUnlockOutline,timedLockOutline:icons$2.timedLockOutline,trafficOutline:icons$2.trafficOutline,voucherOutline:icons$2.voucherOutline,wheelBeamsNodesOutline:icons$2.wheelBeamsNodesOutline,wheelOutline:icons$2.wheelOutline},hazard:{danger:icons$2.danger,fireDiamond:icons$2.fireDiamond,test:icons$2.test},drop:{droplet:icons$2.droplet},liquid:{droplet:icons$2.droplet},nfpa704:{fireDiamond:icons$2.fireDiamond},"dry cargo":{rocks:icons$2.rocks},dry:{rocks:icons$2.rocks},editor:{scale:icons$2.scale},marker:{arrowsUp:icons$2.arrowsUp,bigDot:icons$2.bigDot,connectorBold:icons$2.connectorBold,cornerTopRight:icons$2.cornerTopRight,plusBold:icons$2.plusBold,puzzlePieceBold:icons$2.puzzlePieceBold},ribbon:{arrowsUp:icons$2.arrowsUp,bigDot:icons$2.bigDot,connectorBold:icons$2.connectorBold,cornerTopRight:icons$2.cornerTopRight,plusBold:icons$2.plusBold,puzzlePieceBold:icons$2.puzzlePieceBold},"content-props":{arrowsUp:icons$2.arrowsUp,bigDot:icons$2.bigDot,connectorBold:icons$2.connectorBold,cornerTopRight:icons$2.cornerTopRight,plusBold:icons$2.plusBold,puzzlePieceBold:icons$2.puzzlePieceBold},location:{locationDestination:icons$2.locationDestination,locationSource:icons$2.locationSource},shop:{shoppingCart:icons$2.shoppingCart},purchase:{shoppingCart:icons$2.shoppingCart},bus:{busTilted:icons$2.busTilted},destruction:{explosion:icons$2.explosion,fireExtinguisher:icons$2.fireExtinguisher,fire:icons$2.fire},"turn signals":{twoArrowsHorizontal:icons$2.twoArrowsHorizontal,twoArrowsVertical:icons$2.twoArrowsVertical},rally:{bridge:icons$2.bridge,bump:icons$2.bump,bumps:icons$2.bumps,caution:icons$2.caution,crest:icons$2.crest,doubleCaution:icons$2.doubleCaution,finish:icons$2.finish,jumpOverBump:icons$2.jumpOverBump,narrows:icons$2.narrows,pothole:icons$2.pothole,turn1:icons$2.turn1,turn2:icons$2.turn2,turn3:icons$2.turn3,turn4:icons$2.turn4,turn5:icons$2.turn5,turn6:icons$2.turn6,turnHp:icons$2.turnHp,turnSq:icons$2.turnSq,water:icons$2.water,rallyHelmet3To4:icons$2.rallyHelmet3To4,rallyHelmet:icons$2.rallyHelmet,tripleCaution:icons$2.tripleCaution},"pace notes":{bridge:icons$2.bridge,bump:icons$2.bump,bumps:icons$2.bumps,caution:icons$2.caution,crest:icons$2.crest,doubleCaution:icons$2.doubleCaution,finish:icons$2.finish,jumpOverBump:icons$2.jumpOverBump,narrows:icons$2.narrows,pothole:icons$2.pothole,turn1:icons$2.turn1,turn2:icons$2.turn2,turn3:icons$2.turn3,turn4:icons$2.turn4,turn5:icons$2.turn5,turn6:icons$2.turn6,turnHp:icons$2.turnHp,turnSq:icons$2.turnSq,water:icons$2.water,tripleCaution:icons$2.tripleCaution},directions:{bridge:icons$2.bridge,bump:icons$2.bump,bumps:icons$2.bumps,caution:icons$2.caution,crest:icons$2.crest,doubleCaution:icons$2.doubleCaution,finish:icons$2.finish,jumpOverBump:icons$2.jumpOverBump,narrows:icons$2.narrows,pothole:icons$2.pothole,turn1:icons$2.turn1,turn2:icons$2.turn2,turn3:icons$2.turn3,turn4:icons$2.turn4,turn5:icons$2.turn5,turn6:icons$2.turn6,turnHp:icons$2.turnHp,turnSq:icons$2.turnSq,water:icons$2.water,tripleCaution:icons$2.tripleCaution},"do not cut":{circleSlashed:icons$2.circleSlashed,scissorsSlashed:icons$2.scissorsSlashed},"no entry":{circleSlashed:icons$2.circleSlashed},cut:{scissors:icons$2.scissors},car:{airPuffRight1:icons$2.airPuffRight1,octagonBrick:icons$2.octagonBrick,octagon:icons$2.octagon,tireAirPuff:icons$2.tireAirPuff,tireDeflated:icons$2.tireDeflated},select:{carsChange:icons$2.carsChange,carsWrench:icons$2.carsWrench},physics:{forceFieldPull1:icons$2.forceFieldPull1,forceFieldPull2:icons$2.forceFieldPull2,forceFieldPull3:icons$2.forceFieldPull3,forceFieldPush1:icons$2.forceFieldPush1,forceFieldPush2:icons$2.forceFieldPush2,forceFieldPush3:icons$2.forceFieldPush3,pushUp:icons$2.pushUp,pushBackward:icons$2.pushBackward,pushDown:icons$2.pushDown,pushForward:icons$2.pushForward},field:{forceFieldPull1:icons$2.forceFieldPull1,forceFieldPull2:icons$2.forceFieldPull2,forceFieldPull3:icons$2.forceFieldPull3,forceFieldPush1:icons$2.forceFieldPush1,forceFieldPush2:icons$2.forceFieldPush2,forceFieldPush3:icons$2.forceFieldPush3},force:{forceFieldPull1:icons$2.forceFieldPull1,forceFieldPull2:icons$2.forceFieldPull2,forceFieldPull3:icons$2.forceFieldPull3,forceFieldPush1:icons$2.forceFieldPush1,forceFieldPush2:icons$2.forceFieldPush2,forceFieldPush3:icons$2.forceFieldPush3,pushUp:icons$2.pushUp,pushBackward:icons$2.pushBackward,pushDown:icons$2.pushDown,pushForward:icons$2.pushForward},"garage number":{garageNumber1:icons$2.garageNumber1,garageNumber2:icons$2.garageNumber2,garageNumber3:icons$2.garageNumber3,garageNumber4:icons$2.garageNumber4,garageNumber5:icons$2.garageNumber5,garageNumber6:icons$2.garageNumber6,garageNumber7:icons$2.garageNumber7,garageNumber8:icons$2.garageNumber8,garageNumber9:icons$2.garageNumber9},stop:{square:icons$2.square},roads:{trafficLight:icons$2.trafficLight},sign:{pedestrianRunning:icons$2.pedestrianRunning,pedestrianStanding:icons$2.pedestrianStanding},pedestrian:{pedestrianRunning:icons$2.pedestrianRunning,pedestrianStanding:icons$2.pedestrianStanding},actions:{seatArrowIn:icons$2.seatArrowIn,seatArrowOut:icons$2.seatArrowOut,seatVArrowIn:icons$2.seatVArrowIn,seatVArrowOut:icons$2.seatVArrowOut,vehicleArrowIn:icons$2.vehicleArrowIn,vehicleArrowOut:icons$2.vehicleArrowOut,leverFrontOperate:icons$2.leverFrontOperate,leverSideDown:icons$2.leverSideDown,leverSideOperate:icons$2.leverSideOperate,leverSideUp:icons$2.leverSideUp,seatArrowInLeft:icons$2.seatArrowInLeft,seatArrowOutLeft:icons$2.seatArrowOutLeft,seatVArrowInLeft:icons$2.seatVArrowInLeft,seatVArrowOutLeft:icons$2.seatVArrowOutLeft},outline:{beamCurrencyOutlineLarge:icons$2.beamCurrencyOutlineLarge},scenario:{flagOutlineLarge:icons$2.flagOutlineLarge},house:{houseWrenchRoof:icons$2.houseWrenchRoof,houseWrench:icons$2.houseWrench,house:icons$2.house},helmet:{rallyHelmet3To4:icons$2.rallyHelmet3To4,rallyHelmet:icons$2.rallyHelmet},racing:{rallyHelmet3To4:icons$2.rallyHelmet3To4,rallyHelmet:icons$2.rallyHelmet},"game mode":{rallyHelmet3To4:icons$2.rallyHelmet3To4,rallyHelmet:icons$2.rallyHelmet},offline:{globeSimpleNotSign:icons$2.globeSimpleNotSign},online:{globeSimplified:icons$2.globeSimplified},material:{cableSection:icons$2.cableSection,strapHook:icons$2.strapHook,strapRatchet:icons$2.strapRatchet},beam:{cableSection:icons$2.cableSection},strap:{cableSection:icons$2.cableSection,strapHook:icons$2.strapHook,strapRatchet:icons$2.strapRatchet},controls:{kbArrowsDown:icons$2.kbArrowsDown,kbArrowsLeftRight:icons$2.kbArrowsLeftRight,kbArrowsLeft:icons$2.kbArrowsLeft,kbArrowsOutline:icons$2.kbArrowsOutline,kbArrowsRight:icons$2.kbArrowsRight,kbArrowsSolid:icons$2.kbArrowsSolid,kbArrowsUpDown:icons$2.kbArrowsUpDown,kbArrowsUp:icons$2.kbArrowsUp},equipment:{auxUpDown:icons$2.auxUpDown,bucketArmUpDown:icons$2.bucketArmUpDown,bucketTilt:icons$2.bucketTilt,bucketArmDown:icons$2.bucketArmDown,bucketArmLevel:icons$2.bucketArmLevel,bucketArmUp:icons$2.bucketArmUp,bucketTiltDown:icons$2.bucketTiltDown,bucketTiltLevel:icons$2.bucketTiltLevel,bucketTiltUp:icons$2.bucketTiltUp,dumpBedDown:icons$2.dumpBedDown,dumpBedUpDown:icons$2.dumpBedUpDown,dumpBedUp:icons$2.dumpBedUp}}),getIconsWithTags=(...tagsToFind)=>Object.fromEntries(Object.entries(icons$2).filter(([name,{tags}])=>{for(let t of tagsToFind)if(!tags.includes(t))return!1;return!0})),icons=Object.freeze({...icons$2,_empty:{...icons$2.minus,invisible:!0}}),_sfc_main$369={__name:`bngIcon`,props:{type:{type:[String,Object],default:``},fallbackType:{type:String,default:`placeholder`},color:{type:String,default:`#fff`},asImage:{},image:String,externalImage:String},setup(__props){useCssVars(_ctx=>({v9bdaf084:__props.color}));let props=__props,hasImageSource=computed(()=>!!props.image||!!props.externalImage),imageSrcKey=computed(()=>props.image||props.externalImage||``),errorSrcKey=ref(``),isCurrentSrcErrored=computed(()=>!!imageSrcKey.value&&errorSrcKey.value===imageSrcKey.value),isGlyph=computed(()=>!!(!hasImageSource.value||isCurrentSrcErrored.value)),icon=computed(()=>{let res;switch(typeof props.type){case`object`:props.type.glyph&&(res=props.type);break;case`string`:props.type in icons&&(res=icons[props.type]);break}return res}),displayIcon=computed(()=>{let fallback=typeof props.fallbackType==`string`&&props.fallbackType in icons?icons[props.fallbackType]:icons.placeholder;return isCurrentSrcErrored.value||!icon.value&&!hasImageSource.value?fallback:icon.value}),iconGlyph=computed(()=>displayIcon.value?displayIcon.value.glyph:icons.placeholder.glyph),OFF_VALUES=[null,void 0,!1,`false`,0,`0`],asImage=computed(()=>OFF_VALUES.includes(props.asImage)?!1:props.asImage||!0),imageProps=computed(()=>{let res={bgColor:props.color,mask:[`mask`,`span`].includes(asImage.value)};return icon.value||(res.bgColor=`#f00`),asImage.value||(props.image?res.src=props.image:props.externalImage&&(res.externalSrc=props.externalImage)),res});function onImageError(){errorSrcKey.value=imageSrcKey.value}return(_ctx,_cache)=>isGlyph.value?(openBlock(),createElementBlock(`span`,{key:0,class:normalizeClass([`icon-base`,{"icon-not-found":displayIcon.value===unref(icons).placeholder,"icon-invisible":displayIcon.value&&displayIcon.value.invisible}])},toDisplayString(iconGlyph.value),3)):(openBlock(),createBlock(unref(bngImageAsset_default),mergeProps({key:1,class:`icon-img`},imageProps.value,{onError:onImageError}),null,16))}},bngIcon_default=__plugin_vue_export_helper_default(_sfc_main$369,[[`__scopeId`,`data-v-978d1732`]]),markerValidate=name=>name.endsWith(`Back`)&&Object.keys(iconsBySize[56]).includes(name.replace(/Back$/,`Front`))||name.endsWith(`Front`)&&Object.keys(iconsBySize[56]).includes(name.replace(/Front$/,`Back`)),markersList=Object.keys(iconsBySize[56]).filter(markerValidate).map(name=>name.replace(/Back$|Front$/,``)).sort((a$1,b)=>a$1.toLowerCase().localeCompare(b.toLowerCase())).reduce((res,name)=>res.includes(name)?res:[...res,name],[]);const markers=Object.fromEntries(markersList.map(i=>[i,i])),MARKER_POINTS={up:`up`,down:`down`,left:`left`,right:`right`};var _sfc_main$368={__name:`bngIconMarker`,props:{marker:{type:String,default:`circlePin`,validator:val=>!!markers[val]},type:[String,Object],color:[String,Array],point:{type:String,default:`down`,validator:val=>MARKER_POINTS[val]}},setup(__props){let props=__props,icon=computed(()=>({back:iconsBySize[56][props.marker+`Back`],front:iconsBySize[56][props.marker+`Front`]})),iconColour=computed(()=>({back:(Array.isArray(props.color)?props.color[0]:props.color)||`#fff`,front:(Array.isArray(props.color)?props.color[1]:null)||`#000`,icon:(Array.isArray(props.color)?props.color[2]||props.color[0]:props.color)||`#fff`}));return(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,{class:normalizeClass([`icon-marker`,`icon-point-${__props.point}`,`icon-type-${__props.marker}`])},[createVNode(unref(bngIcon_default),{class:`icon-back`,type:icon.value.back,color:iconColour.value.back},null,8,[`type`,`color`]),createVNode(unref(bngIcon_default),{class:`icon-front`,type:icon.value.front,color:iconColour.value.front},null,8,[`type`,`color`]),__props.type?(openBlock(),createBlock(unref(bngIcon_default),{key:0,class:`icon-inner`,type:__props.type,color:iconColour.value.icon},null,8,[`type`,`color`])):createCommentVNode(``,!0)],2))}},bngIconMarker_default=__plugin_vue_export_helper_default(_sfc_main$368,[[`__scopeId`,`data-v-1089accc`]]),_hoisted_1$322=[`src`],_sfc_main$367=Object.assign({inheritAttrs:!1},{__name:`bngImage`,props:{src:String,observe:Boolean},setup(__props){let props=__props,attrs=useAttrs(),observe=computed(()=>props.observe?`observe`:void 0),imgAttrs=computed(()=>showCanvas.value?{}:attrs),cvsAttrs=computed(()=>showCanvas.value?attrs:{}),elImg=ref(null),elCanvas=ref(null),showCanvas=ref(!1),imgSrc=ref(emptyImage),parentDataAttrs={};function setImage(elm,url,bmp){bmp?(showCanvas.value=!0,imgSrc.value=emptyImage,elCanvas.value.width=bmp.width,elCanvas.value.height=bmp.height,elCanvas.value.getContext(`2d`).drawImage(bmp,0,0),Object.entries(parentDataAttrs).forEach(([attr,value])=>{elCanvas.value.setAttribute(attr,value)})):(showCanvas.value=!1,imgSrc.value=url||`data:image/svg+xml,`)}return watch(()=>props.src,()=>{elImg.value&&(showCanvas.value=!1,imgSrc.value=emptyImage)}),watch(elImg,elm=>{if(elm){parentDataAttrs={};for(let attr of elm.parentElement.getAttributeNames())attr.startsWith(`data-v-`)&&(parentDataAttrs[attr]=elm.parentElement.getAttribute(attr));Object.entries(parentDataAttrs).forEach(([attr,value])=>{elm.setAttribute(attr,value),elCanvas.value&&elCanvas.value.setAttribute(attr,value)}),elm.__setImage=setImage}},{immediate:!0}),(_ctx,_cache)=>(openBlock(),createElementBlock(Fragment,null,[withDirectives(createBaseVNode(`img`,mergeProps({ref_key:`elImg`,ref:elImg},imgAttrs.value,{src:imgSrc.value,alt:``}),null,16,_hoisted_1$322),[[vShow,!showCanvas.value],[unref(BngLazyImage_default),{url:__props.src,callback:setImage},observe.value]]),withDirectives(createBaseVNode(`canvas`,mergeProps({ref_key:`elCanvas`,ref:elCanvas},cvsAttrs.value),null,16),[[vShow,showCanvas.value]])],64))}}),bngImage_default=_sfc_main$367,_hoisted_1$321=[`src`],_sfc_main$366={__name:`bngImageAsset`,props:{src:String,externalSrc:String,span:Boolean,mask:Boolean,bgColor:{type:String,default:`transparent`}},emits:[`error`,`load`],setup(__props,{emit:__emit}){useCssVars(_ctx=>({v0d0b2c1c:__props.bgColor}));let emit$1=__emit,props=__props,assetURL=computed(()=>props.src?getAssetURL(props.src):props.externalSrc);return(_ctx,_cache)=>__props.span||__props.mask?(openBlock(),createElementBlock(`span`,{key:0,class:`bng-image-asset`,style:normalizeStyle({[__props.mask?`maskImage`:`backgroundImage`]:`url(${assetURL.value})`})},[renderSlot(_ctx.$slots,`default`,{},void 0,!0)],4)):(openBlock(),createElementBlock(`img`,{key:1,class:`bng-image-asset`,src:assetURL.value,alt:``,onError:_cache[0]||=$event=>emit$1(`error`,$event),onLoad:_cache[1]||=$event=>emit$1(`load`,$event)},null,40,_hoisted_1$321))}},bngImageAsset_default=__plugin_vue_export_helper_default(_sfc_main$366,[[`__scopeId`,`data-v-27bf5bcc`]]),_hoisted_1$320={class:`bng-image-carousel`},_sfc_main$365={__name:`bngImageCarousel`,props:{images:{type:Array,required:!0},external:Boolean,current:[String,Number],transition:Boolean,transitionType:{type:String,default:`fade`},transitionTime:{type:Number,default:3e3},loop:{type:Boolean,default:!0},showNav:{type:Boolean,default:!0},parent:Object},setup(__props,{expose:__expose}){let props=__props,carousel=ref();__expose({carousel});let imageAssets=computed(()=>props.external?props.images.map(x=>`/`+x):props.images.map(getAssetURL)),carouselSettings=computed(()=>props.parent&&props.parent.carousel!==carousel?{parent:props.parent.carousel,transition:!1,transitionType:props.transitionType,loop:!1,transitionTime:props.transitionTime}:{current:props.current,transition:props.transition,transitionType:props.transitionType,transitionTime:props.transitionTime,loop:props.loop,showNav:props.showNav});return(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$320,[createVNode(unref(carousel_default),mergeProps({items:imageAssets.value,ref_key:`carousel`,ref:carousel},carouselSettings.value),{item:withCtx(({item})=>[createBaseVNode(`div`,{class:`image-slide`,style:normalizeStyle({"background-image":`url(${item})`})},null,4)]),_:1},16,[`items`])]))}},bngImageCarousel_default=__plugin_vue_export_helper_default(_sfc_main$365,[[`__scopeId`,`data-v-6b0c2d6b`]]),_hoisted_1$319=[`src`],_sfc_main$364={__name:`bngImageTile`,props:{oldIcon:String,src:String,externalSrc:String,label:String,image:String,externalImage:String,icon:[Object,String],ratio:{type:String,default:`4:3`}},setup(__props){let props=__props,slots=useSlots(),assetURL=computed(()=>props.externalSrc?props.externalSrc:getAssetURL(props.src));return(_ctx,_cache)=>(openBlock(),createBlock(unref(bngTile_default),{label:__props.label,backgroundImage:__props.image,backgroundExternalImage:__props.externalImage,ratio:__props.ratio},createSlots({default:withCtx(()=>[__props.oldIcon?(openBlock(),createBlock(unref(bngOldIcon_default),{key:0,class:`icon`,type:__props.oldIcon,span:``},null,8,[`type`])):createCommentVNode(``,!0),__props.icon?(openBlock(),createBlock(unref(bngIcon_default),{key:1,class:`glyph`,type:__props.icon},null,8,[`type`])):__props.src||__props.externalSrc?(openBlock(),createElementBlock(`img`,{key:2,class:`icon`,src:assetURL.value},null,8,_hoisted_1$319)):createCommentVNode(``,!0)]),_:2},[unref(slots).default?{name:`label`,fn:withCtx(()=>[renderSlot(_ctx.$slots,`default`,{},void 0,!0)]),key:`0`}:void 0]),1032,[`label`,`backgroundImage`,`backgroundExternalImage`,`ratio`]))}},bngImageTile_default=__plugin_vue_export_helper_default(_sfc_main$364,[[`__scopeId`,`data-v-d74a4ec4`]]),UNIQUE_CLEAN_VALUE=Symbol(`Unique 'clean' value from Dirty service code`);function useDirty(valueRef,emitter=void 0,setCallback=void 0){if(!valueRef)throw Error(`valueRef must be specified`);let hasInitValue=!1,initialValue=ref();function init$3(val){let type=typeof val;type===`undefined`||type===`number`&&isNaN(val)||(hasInitValue=!0,initialValue.value=val)}if(init$3(valueRef.value),!hasInitValue){let unwatch=watch(valueRef,newVal=>{init$3(newVal),hasInitValue&&unwatch()});onUnmounted(()=>!hasInitValue&&unwatch())}let dirty=computed(()=>{let isDirty$1=valueRef.value!==initialValue.value;return isDirty$1&&hasInitValue&&emitter&&emitter(`dirtied`,valueRef.value,initialValue.value),isDirty$1}),setDirty=state=>{let oldVal=initialValue.value,newVal=state?UNIQUE_CLEAN_VALUE:valueRef.value;initialValue.value=newVal,typeof setCallback==`function`&&setCallback(newVal,oldVal)};return{dirty,currentCleanValue:computed(()=>initialValue.value),setCleanValue:val=>initialValue.value=val,resetValue:()=>valueRef.value=initialValue.value,setDirty,markClean:()=>setDirty(!1)}}var _hoisted_1$318={class:`bng-input-wrapper`},_hoisted_2$259={class:`icons-input-wrapper`},_hoisted_3$226={class:`bng-input-container`},_hoisted_4$194={key:0,class:`prefix-suffix-container`},_hoisted_5$164={"data-testid":`prefix`},_hoisted_6$141={class:`bng-input-group`},_hoisted_7$123=[`value`,`type`,`min`,`max`,`step`,`maxlength`,`placeholder`,`disabled`,`readonly`],_hoisted_8$101={key:0,class:`number-actions`},_hoisted_9$91={key:1,class:`floating-label`,"data-testid":`floating-label`},_hoisted_10$79={key:2,class:`error-message`},_hoisted_11$71={key:1,class:`prefix-suffix-container`},_hoisted_12$59={"data-testid":`suffix`},_hoisted_13$51={key:2,class:`trailing-icon`},_sfc_main$363={__name:`bngInput`,props:{modelValue:[String,Number],type:{type:String,default:`text`,validator(value){return[`text`,`number`].includes(value)}},min:[Number,String],max:[Number,String],step:{type:[Number,String],default:1},decimals:Number,maxlength:[Number,String],readonly:Boolean,floatingLabel:String,externalLabel:String,placeholder:String,initialValue:String,leadingIcon:Object,prefix:String,suffix:String,trailingIcon:Object,trailingIconOutside:Boolean,disabled:Boolean,validate:Function,errorMessage:String},emits:[`update:modelValue`,`valueChanged`,`change`,`focus`,`blur`],setup(__props,{expose:__expose,emit:__emit}){let props=__props,emitter=__emit,input=ref(),value=ref(props.initialValue||props.modelValue),isInputFieldFocused=ref(!1),numMin=computed(()=>props.type===`number`?+props.min:null),numMax=computed(()=>props.type===`number`?+props.max:null),numStep=computed(()=>props.type===`number`?roundDec(+props.step,15):null),numDecimals=computed(()=>props.type===`number`?props.decimals:null),charMax=computed(()=>props.type===`text`?props.maxlength:null),hasValue=computed(()=>value.value!==``&&value.value!==void 0&&value.value!==null),hasError=computed(()=>typeof props.validate==`function`?!props.validate(value.value):!1);if(props.type===`number`){let type=typeof value.value;type===`string`&&/^\d+(?:\.?\d+)?$/.test(value.value)?value.value=+value.value:type!==`number`&&(value.value=0),numMin.value>numMax.value&&console.error(`BngInput: min cannot be greater than max`)}__expose(useDirty(value));let lastNotify;function notify(val){props.readonly||lastNotify===val||(lastNotify=val,emitter(`update:modelValue`,val),emitter(`valueChanged`,val),emitter(`change`,val))}watch(()=>props.modelValue,newVal=>{props.type===`number`&&(newVal=numClamp(newVal)),value.value=newVal,lastNotify=newVal},{immediate:!0});function numClamp(val){return isNaN(val)&&(val=0),typeof numDecimals.value==`number`&&!isNaN(numDecimals.value)?val=roundDec(val,numDecimals.value):typeof numStep.value==`number`&&!isNaN(numStep.value)&&(val=roundDecSample(val,numStep.value)),typeof numMin.value==`number`&&!isNaN(numMin.value)&&valnumMax.value&&(val=numMax.value),val}function increment(by){let val=numClamp(+value.value+by);value.value!==val&&(value.value=val,input.value=val,notify(val))}let onArrowUpClicked=()=>increment(numStep.value),onArrowDownClicked=()=>increment(-numStep.value);function onValueChanged($event){let val=$event.target.value;if(props.type===`number`){val=+val;let prev=val;val=numClamp(val),val!==prev&&(input.value=val)}value.value=val,notify(val)}function onInputFieldFocusIn(){isInputFieldFocused.value=!0,emitter(`focus`)}function onInputFieldFocusOut(){isInputFieldFocused.value=!1,emitter(`blur`),notify(value.value)}return(_ctx,_cache)=>withDirectives((openBlock(),createElementBlock(`div`,_hoisted_1$318,[__props.externalLabel?(openBlock(),createElementBlock(`span`,{key:0,class:`external-label`,style:normalizeStyle([__props.leadingIcon?{"margin-left":`3em`}:{}]),"data-testid":`external-label`},toDisplayString(__props.externalLabel),5)):createCommentVNode(``,!0),createBaseVNode(`div`,_hoisted_2$259,[__props.leadingIcon?(openBlock(),createBlock(unref(bngIcon_default),{key:0,class:`outside-icon`,type:__props.leadingIcon,"data-testid":`leading-icon`},null,8,[`type`])):createCommentVNode(``,!0),createBaseVNode(`div`,{tabindex:`disabled ? -1 : 0`,class:normalizeClass([`bng-highlight-container`,{"bng-input-focused":isInputFieldFocused.value,"has-error":hasError.value}]),onKeydown:withKeys(onInputFieldFocusOut,[`enter`])},[createBaseVNode(`div`,_hoisted_3$226,[__props.prefix?(openBlock(),createElementBlock(`span`,_hoisted_4$194,[createBaseVNode(`span`,_hoisted_5$164,toDisplayString(__props.prefix),1)])):createCommentVNode(``,!0),createBaseVNode(`div`,_hoisted_6$141,[withDirectives(createBaseVNode(`input`,{ref_key:`input`,ref:input,class:normalizeClass([`bng-input`,{"bng-input-empty":!hasValue.value,"bng-input-error":hasError.value}]),"data-testid":`input`,value:value.value,type:__props.type,min:numMin.value,max:numMax.value,step:numStep.value,maxlength:charMax.value,onInput:onValueChanged,onFocusin:onInputFieldFocusIn,onFocusout:onInputFieldFocusOut,placeholder:__props.placeholder,disabled:__props.disabled,readonly:__props.readonly},null,42,_hoisted_7$123),[[unref(BngTextInput_default)]]),__props.type===`number`?(openBlock(),createElementBlock(`div`,_hoisted_8$101,[withDirectives(createVNode(unref(bngIcon_default),{type:unref(iconsByTag).arrow.arrowLargeUp,class:normalizeClass([{"number-action-disabled":__props.readonly},`number-action up-action`])},null,8,[`type`,`class`]),[[unref(BngClick_default),{clickCallback:onArrowUpClicked,holdCallback:onArrowUpClicked}]]),withDirectives(createVNode(unref(bngIcon_default),{type:unref(iconsByTag).arrow.arrowLargeDown,class:normalizeClass([`number-action down-action`,{"number-action-disabled":__props.readonly}])},null,8,[`type`,`class`]),[[unref(BngClick_default),{clickCallback:onArrowDownClicked,holdCallback:onArrowDownClicked}]])])):createCommentVNode(``,!0),__props.floatingLabel?(openBlock(),createElementBlock(`span`,_hoisted_9$91,toDisplayString(__props.floatingLabel),1)):createCommentVNode(``,!0),hasError.value&&__props.errorMessage?(openBlock(),createElementBlock(`span`,_hoisted_10$79,toDisplayString(__props.errorMessage),1)):createCommentVNode(``,!0),_cache[0]||=createBaseVNode(`span`,{class:`input-border`},null,-1)]),__props.suffix?(openBlock(),createElementBlock(`span`,_hoisted_11$71,[createBaseVNode(`span`,_hoisted_12$59,toDisplayString(__props.suffix),1)])):createCommentVNode(``,!0),__props.trailingIcon&&!__props.trailingIconOutside?(openBlock(),createElementBlock(`span`,_hoisted_13$51,[createVNode(unref(bngIcon_default),{type:__props.trailingIcon,class:`input-icon`,"data-testid":`trailing-icon`},null,8,[`type`])])):createCommentVNode(``,!0)])],34),__props.trailingIcon&&__props.trailingIconOutside?(openBlock(),createBlock(unref(bngIcon_default),{key:1,type:__props.trailingIcon,class:`outside-icon`,"data-testid":`external-trailing-icon`},null,8,[`type`])):createCommentVNode(``,!0)])])),[[unref(BngDisabled_default),__props.disabled]])}},bngInput_default=__plugin_vue_export_helper_default(_sfc_main$363,[[`__scopeId`,`data-v-d6c70b5c`]]),_hoisted_1$317=[`readonly`,`disabled`,`placeholder`,`maxlength`],_hoisted_2$258={key:0,class:`floating-label`},_hoisted_3$225={key:7,class:`external-button`},_hoisted_4$193={key:8,class:`error-message`};const INPUT_TYPES={text:`text`,number:`number`},STEP_ICON_TYPES={arrowUpDown:`arrowUpDown`,arrowLeftRight:`arrowLeftRight`,plusMinus:`plusMinus`};var STEP_ICON_TYPES_MAP={[STEP_ICON_TYPES.arrowUpDown]:{up:`arrowSmallUp`,down:`arrowSmallDown`},[STEP_ICON_TYPES.arrowLeftRight]:{up:`arrowSmallRight`,down:`arrowSmallLeft`},[STEP_ICON_TYPES.plusMinus]:{up:`plus`,down:`minus`}},NUMBER_PATTERN=/^\d+(\.d+)?$/,NUMBER_INPUT_KEYS=/^[0-9\.\-]$/,ERROR_TYPES={invalidformat:`invalidformat`,outofrange:`outofrange`,required:`required`,custom:`custom`},ERROR_MESSAGES={[ERROR_TYPES.invalidformat]:`Invalid format`,[ERROR_TYPES.outofrange]:`Value must be between {min} and {max}`,[`${ERROR_TYPES.outofrange}-min`]:`Value must be greater than {min}`,[`${ERROR_TYPES.outofrange}-max`]:`Value must be less than {max}`,[ERROR_TYPES.required]:`Value is required`},ALLOW_DEFAULT_BEHAVIOR_KEYS=[`ArrowLeft`,`ArrowRight`,`ArrowUp`,`ArrowDown`,`Backspace`,`Delete`],NUMBER_INPUT_MODES={spinner:`spinner`,arrowKeys:`arrowKeys`,uinav:`uinav`},_sfc_main$362={__name:`bngInputNew`,props:{modelValue:{type:[Number,String],default:void 0},value:{type:[Number,String],default:void 0},type:{type:String,default:INPUT_TYPES.text,validator(value){return Object.keys(INPUT_TYPES).includes(value)}},showExternalButton:{type:Boolean,default:!0},floatingLabel:[Boolean,String],externalButtonFn:Function,externalLabel:String,label:String,prefix:String,suffix:String,leadingIcon:Object,trailingIcon:Object,maxLength:{type:[Number,String],default:null,validator(value){return value===null?!0:typeof parseInt(value)==`number`&&parseInt(value)>=0}},readonly:Boolean,disabled:Boolean,required:Boolean,placeholder:String,validate:Function,errorMessage:String,min:{type:Number,default:void 0},max:{type:Number,default:void 0},step:{type:Number,default:1},stepIconType:{type:String,default:STEP_ICON_TYPES.arrowUpDown,validator(value){return Object.keys(STEP_ICON_TYPES).includes(value)}},noStepBindings:Boolean},emits:[`update:modelValue`,`change`,`error`,`blur`,`focus`,`valueChanged`],setup(__props,{expose:__expose,emit:__emit}){let props=__props,emit$1=__emit,slots=useSlots(),{showIfController}=storeToRefs(controls_default()),input=ref(null),scopeActivated=ref(!1),rawValue=ref(null),validationState=ref(null),isProgrammaticChange=ref(!1),numberInputState=reactive({inputType:null,isUpActive:!1,isDownActive:!1}),value=computed({get:()=>props.modelValue,set:emitChange}),isEmptyRawValue=computed(()=>isEmpty(rawValue.value)),inputStyle=computed(()=>({"max-width":props.maxLength?`${props.maxLength}ch`:`initial`})),stepIcons=computed(()=>STEP_ICON_TYPES_MAP[props.stepIconType]),exposed=useDirty(value);exposed.scopeActivated=scopeActivated,__expose(exposed),watch(()=>rawValue.value,newValue=>{if(isProgrammaticChange.value){isProgrammaticChange.value=!1;return}let res=validate(newValue);validationState.value=res,rawValue.value!=props.modelValue&&(res.valid||res.error!==ERROR_TYPES.invalidformat)&&(value.value=res.value)}),watch(()=>props.modelValue,modelValue=>{modelValue!=rawValue.value&&(isProgrammaticChange.value=!0,rawValue.value=isEmpty(modelValue)?null:String(modelValue))},{immediate:!0}),watch(()=>props.value,()=>{props.modelValue===void 0&&props.value!=rawValue.value&&(isProgrammaticChange.value=!0,rawValue.value=props.value)},{immediate:!0}),onUnmounted(()=>{resetInputState.cancel()});let activateInput=()=>{props.disabled||props.readonly||nextTick(()=>input.value.focus())},canActivateScope=()=>!props.readonly&&!props.disabled,externalButtonFn=()=>{props.externalButtonFn?props.externalButtonFn():props.type===INPUT_TYPES.number?rawValue.value=props.min||0:rawValue.value=null,activateInput()};function onScopeActivated(event){scopeActivated.value=!0}function onScopeDeactivated(event){scopeActivated.value=!1,nextTick(()=>cleanValue())}let resetInputState=debounce(()=>{numberInputState.inputType=null,numberInputState.isUpActive=!1,numberInputState.isDownActive=!1},150);function onUINavChangeValue(dir){numberInputState.inputType&&numberInputState.inputType!==NUMBER_INPUT_MODES.uinav||(numberInputState.inputType=NUMBER_INPUT_MODES.uinav,updateNumValue(dir),resetInputState())}function onArrowKeysChangeValue(dir){numberInputState.inputType&&numberInputState.inputType!==NUMBER_INPUT_MODES.arrowKeys||(numberInputState.inputType=NUMBER_INPUT_MODES.arrowKeys,updateNumValue(dir),resetInputState())}function onSpinnerChangeValue(dir){numberInputState.inputType&&numberInputState.inputType!==NUMBER_INPUT_MODES.spinner||(numberInputState.inputType=NUMBER_INPUT_MODES.spinner,updateNumValue(dir),resetInputState())}function updateNumValue(dir){props.type!==INPUT_TYPES.number||props.disabled||props.readonly||(dir===1?(numberInputState.isUpActive=!0,changeNumValue(props.step)):(numberInputState.isDownActive=!0,changeNumValue(-props.step)))}function onEnterDown(event){event.preventDefault(),scopeActivated.value=!1}function onKeyDown(event){if(ALLOW_DEFAULT_BEHAVIOR_KEYS.includes(event.key))return;event.key===`Enter`&&event.preventDefault();let rawValueString=typeof rawValue.value!=`string`&&!isNullOrUndefined(rawValue.value)?rawValue.value.toString():rawValue.value;props.type===INPUT_TYPES.number&&(!NUMBER_INPUT_KEYS.test(event.key)||event.key===`.`&&(isNullOrUndefined(rawValueString)||rawValueString.includes(`.`))||event.key===`.`&&!NUMBER_PATTERN.test(rawValueString))&&event.preventDefault()}function changeNumValue(diff){if(props.type!==INPUT_TYPES.number)return;if(isEmpty(rawValue.value)){diff<0?rawValue.value=isNullOrUndefined(props.max)?0:props.max:rawValue.value=isNullOrUndefined(props.min)?0:props.min;return}let{valid,value:validatedValue,error}=validate(rawValue.value);if(!valid&&error!==ERROR_TYPES.outofrange){rawValue.value=0;return}let decimalTokens=props.step.toString().split(`.`),stepDecimalPlaces=decimalTokens.length>1?decimalTokens[1].length:0,newValue=Number((validatedValue+diff).toFixed(stepDecimalPlaces)),{valid:isValidRange}=validateRange(newValue);(isValidRange||diff<0&&newValue>=props.max||diff>0&&newValue<=props.min)&&(rawValue.value=newValue)}function cleanValue(){if(!isNullOrUndefined(rawValue.value)&&props.type===INPUT_TYPES.number){let rawValueString=typeof rawValue.value==`string`?rawValue.value:rawValue.value.toString();rawValueString.endsWith(`.`)&&(rawValue.value=rawValueString.slice(0,-1))}}function validate(value$1){let valid=!0,newValue=value$1,errorMessage=null;if(isEmpty(value$1)&&props.required)return{valid:!1,error:ERROR_TYPES.required};if(isEmpty(value$1)&&props.type===INPUT_TYPES.number)return{valid:!0,value:void 0};if(props.type===INPUT_TYPES.number&&typeof value$1==`string`&&(newValue=value$1.includes(`.`)?parseFloat(value$1):parseInt(value$1),isNaN(newValue)))return{valid:!1,error:ERROR_TYPES.invalidformat};if(props.type===INPUT_TYPES.number)return{...validateRange(newValue),value:newValue};if(props.validate){let res=props.validate(value$1);typeof res==`boolean`?(valid=res,errorMessage=props.errorMessage):typeof res==`object`&&(`valid`in res&&console.warn("`validate` function must return a boolean `valid` property. Ignoring validation result..."),valid=res.valid||!0,valid||(errorMessage=`errorMessage`in res?res.errorMessage:props.errorMessage))}return{valid,value:newValue,errorMessage}}function validateRange(value$1){let lessThanMin=props.min&&value$1props.max,valid=!0,errorMessage=null;return!isNullOrUndefined(props.min)&&!isNullOrUndefined(props.max)&&(lessThanMin||greaterThanMax)?(errorMessage=ERROR_MESSAGES[ERROR_TYPES.outofrange].replace(`{min}`,props.min).replace(`{max}`,props.max),valid=!1):lessThanMin?(errorMessage=ERROR_MESSAGES[`${ERROR_TYPES.outofrange}-min`].replace(`{min}`,props.min),valid=!1):greaterThanMax&&(errorMessage=ERROR_MESSAGES[`${ERROR_TYPES.outofrange}-max`].replace(`{max}`,props.max),valid=!1),{valid,error:valid?null:ERROR_TYPES.outofrange,errorMessage}}function isEmpty(val){return val==null||val===``}function isNullOrUndefined(val){return val==null}function emitChange(value$1){emit$1(`update:modelValue`,value$1),emit$1(`change`,value$1),emit$1(`valueChanged`,value$1)}return(_ctx,_cache)=>withDirectives((openBlock(),createElementBlock(`div`,{class:normalizeClass([{"has-value":!isEmptyRawValue.value,"bng-input-readonly":__props.readonly,"bng-input-invalid":validationState.value&&!validationState.value.valid},`bng-input`]),onActivate:onScopeActivated,onDeactivate:onScopeDeactivated},[(__props.label||__props.externalLabel||unref(slots).label)&&!__props.floatingLabel?(openBlock(),createElementBlock(`label`,{key:0,class:`external-label`,onClick:activateInput,onMousedown:_cache[0]||=withModifiers(()=>{},[`prevent`])},[renderSlot(_ctx.$slots,`label`,{},()=>[createTextVNode(toDisplayString(__props.label||__props.externalLabel),1)],!0)],32)):createCommentVNode(``,!0),__props.leadingIcon||unref(slots).leadingIcon?(openBlock(),createElementBlock(`span`,{key:1,class:`leading-icon`,onClick:activateInput,onMousedown:_cache[1]||=withModifiers(()=>{},[`prevent`])},[renderSlot(_ctx.$slots,`leading-icon`,{},()=>[createVNode(unref(bngIcon_default),{type:__props.leadingIcon},null,8,[`type`])],!0)],32)):createCommentVNode(``,!0),__props.type===INPUT_TYPES.number&&!__props.readonly&&!__props.disabled?(openBlock(),createElementBlock(`span`,{key:2,class:normalizeClass([{"spinner-active":numberInputState.isDownActive},`input-spinner input-spinner-down`]),onMousedown:_cache[2]||=withModifiers(()=>{},[`prevent`])},[renderSlot(_ctx.$slots,`spinner-down`,{changeValue:()=>onSpinnerChangeValue(-1)},()=>[withDirectives((openBlock(),createBlock(unref(bngButton_default),{"bng-no-nav":`true`,accent:`text`},{default:withCtx(()=>[__props.noStepBindings?createCommentVNode(``,!0):(openBlock(),createBlock(unref(bngBinding_default),{key:0,controller:``,uiEvent:`focus_d`})),!unref(showIfController)||__props.noStepBindings?(openBlock(),createBlock(unref(bngIcon_default),{key:1,type:stepIcons.value.down},null,8,[`type`])):createCommentVNode(``,!0)]),_:1})),[[unref(BngClick_default),{clickCallback:()=>onSpinnerChangeValue(-1),holdCallback:()=>onSpinnerChangeValue(-1)}]])],!0)],34)):createCommentVNode(``,!0),__props.prefix||unref(slots).prefix?(openBlock(),createElementBlock(`span`,{key:3,class:`prefix`,onClick:activateInput,onMousedown:_cache[3]||=withModifiers(()=>{},[`prevent`])},[renderSlot(_ctx.$slots,`prefix`,{},()=>[createTextVNode(toDisplayString(__props.prefix),1)],!0)],32)):createCommentVNode(``,!0),createBaseVNode(`div`,{class:`input-container`,style:normalizeStyle(inputStyle.value)},[withDirectives(createBaseVNode(`input`,{ref_key:`input`,ref:input,"onUpdate:modelValue":_cache[4]||=$event=>rawValue.value=$event,readonly:__props.readonly,disabled:__props.disabled,placeholder:__props.placeholder,maxlength:__props.maxLength,type:`text`,onFocusin:_cache[5]||=$event=>_ctx.$emit(`focus`),onFocusout:_cache[6]||=$event=>_ctx.$emit(`blur`),onKeydown:[_cache[7]||=withKeys($event=>onArrowKeysChangeValue(1),[`arrow-up`]),_cache[8]||=withKeys($event=>onArrowKeysChangeValue(-1),[`arrow-down`]),withKeys(onEnterDown,[`enter`]),onKeyDown]},null,40,_hoisted_1$317),[[unref(BngTextInput_default)],[unref(BngOnUiNavFocus_default),dir=>onUINavChangeValue(dir),`vertical`,{repeat:!0}],[vModelText,rawValue.value]]),__props.label&&__props.floatingLabel||typeof __props.floatingLabel==`string`||unref(slots).label?(openBlock(),createElementBlock(`label`,_hoisted_2$258,[renderSlot(_ctx.$slots,`label`,{},()=>[createTextVNode(toDisplayString(__props.label||__props.floatingLabel),1)],!0)])):createCommentVNode(``,!0)],4),__props.suffix||unref(slots).suffix?(openBlock(),createElementBlock(`span`,{key:4,class:`suffix`,onClick:activateInput,onMousedown:_cache[9]||=withModifiers(()=>{},[`prevent`])},[renderSlot(_ctx.$slots,`suffix`,{},()=>[createTextVNode(toDisplayString(__props.suffix),1)],!0)],32)):createCommentVNode(``,!0),__props.trailingIcon||unref(slots).trailingIcon?(openBlock(),createElementBlock(`span`,{key:5,class:`trailing-icon`,onClick:activateInput,onMousedown:_cache[10]||=withModifiers(()=>{},[`prevent`])},[renderSlot(_ctx.$slots,`trailing-icon`,{},()=>[createVNode(unref(bngIcon_default),{type:__props.trailingIcon},null,8,[`type`])],!0)],32)):createCommentVNode(``,!0),__props.type===INPUT_TYPES.number&&!__props.readonly&&!__props.disabled?(openBlock(),createElementBlock(`span`,{key:6,class:normalizeClass([{"spinner-active":numberInputState.isUpActive},`input-spinner input-spinner-up`]),onMousedown:_cache[11]||=withModifiers(()=>{},[`prevent`])},[renderSlot(_ctx.$slots,`spinner-up`,{changeValue:()=>onSpinnerChangeValue(1)},()=>[withDirectives((openBlock(),createBlock(unref(bngButton_default),{"bng-no-nav":`true`,accent:`text`},{default:withCtx(()=>[__props.noStepBindings?createCommentVNode(``,!0):(openBlock(),createBlock(unref(bngBinding_default),{key:0,controller:``,uiEvent:`focus_u`})),!unref(showIfController)||__props.noStepBindings?(openBlock(),createBlock(unref(bngIcon_default),{key:1,type:stepIcons.value.up},null,8,[`type`])):createCommentVNode(``,!0)]),_:1})),[[unref(BngClick_default),{clickCallback:()=>onSpinnerChangeValue(1),holdCallback:()=>onSpinnerChangeValue(1)}]])],!0)],34)):createCommentVNode(``,!0),__props.showExternalButton?(openBlock(),createElementBlock(`span`,_hoisted_3$225,[renderSlot(_ctx.$slots,`external-button`,{externalButtonFn},()=>[__props.readonly?createCommentVNode(``,!0):withDirectives((openBlock(),createBlock(unref(bngButton_default),{key:0,icon:unref(icons).mathMultiply,disabled:__props.disabled,accent:`attention`,onClick:externalButtonFn,onMousedown:_cache[12]||=withModifiers(()=>{},[`prevent`])},null,8,[`icon`,`disabled`])),[[unref(BngOnUiNav_default),void 0,`ok`,{asMouse:!0,focusRequired:!0}],[unref(BngDisabled_default),isEmptyRawValue.value]])],!0)])):createCommentVNode(``,!0),validationState.value&&!validationState.value.valid&&validationState.value.errorMessage||unref(slots).errorMessage?(openBlock(),createElementBlock(`span`,_hoisted_4$193,[renderSlot(_ctx.$slots,`error-message`,{},()=>[createTextVNode(toDisplayString(validationState.value.errorMessage),1)],!0)])):createCommentVNode(``,!0)],34)),[[unref(BngDisabled_default),__props.disabled],[unref(BngScopedNav_default),{activated:scopeActivated.value,canActivate:canActivateScope}]])}},bngInputNew_default=__plugin_vue_export_helper_default(_sfc_main$362,[[`__scopeId`,`data-v-bb1297d5`]]),_hoisted_1$316={class:`list-container`},_hoisted_2$257={key:0,class:`list-toolbar`},_hoisted_3$224={key:1},_hoisted_4$192={class:`list-layout-toggle`};const LIST_LAYOUTS={DEFAULT:`tiles`,TILES:`tiles`,LIST:`list`,RIBBON:`ribbon`};var _sfc_main$361={__name:`bngList`,props:{path:Array,pathLimit:{type:[Number,String],default:3},pathTarget:Object,layoutSelector:Boolean,layoutSelectorTarget:Object,layout:{type:String,default:LIST_LAYOUTS.DEFAULT,validator:val=>Object.values(LIST_LAYOUTS).includes(val)},big:Boolean,immediate:Boolean,keepAlive:[Boolean,Number],tileSizeCalc:Function,tileWidth:Number,tileHeight:Number,tileMargin:Number,targetWidth:Number,targetHeight:Number,targetMargin:Number,titleWidth:Number,titleHeight:Number,titleMargin:Number,targetTitleWidth:Number,targetTitleHeight:Number,targetTitleMargin:Number,noBackground:Boolean},emits:[`layoutChange`,`pathClick`],setup(__props,{expose:__expose,emit:__emit}){let emit$1=__emit,props=__props,elPath=ref();__expose({navBack(){elPath.value&&elPath.value.navBack()},navTo(item){elPath.value&&elPath.value.navTo(item)},async scrollToIndex(index=0){if(!bigmode.enabled){let hasPosObserver=(elCont.value.children||[])[0]?.classList.contains(`bng-pos-observer`),elm=(elCont.value.children||[])[index+(hasPosObserver?1:0)];return elm&&elm.scrollIntoView(),elm}let big=await getBigProps(void 0,index);if(!big)return null;let horizontal=layoutSelected.value===LIST_LAYOUTS.RIBBON,containerSize=horizontal?contWidth:contHeight,rowIndex=layoutCache.itemToRow.get(index),itemRowPos=layoutCache.rows[rowIndex]?.pos||big.position,itemRowSize=layoutCache.rows[rowIndex]?.size||(horizontal?tileWidth.value:tileHeight.value),centeredPos=itemRowPos-containerSize/2+itemRowSize/2;scrollPos.value=Math.max(0,centeredPos),horizontal?elCont.value.scrollLeft=scrollPos.value:elCont.value.scrollTop=scrollPos.value,await updSkeleton();let itm=items$2.value[index];return itm?itm.getElement?.()||itm.el||itm:null},refresh(){tileWidth.value=0,tileHeight.value=0,titleWidth.value=0,titleHeight.value=0,tileProps=getItemProps(items$2.value,!1),titleProps=getItemProps(items$2.value,!0),tileProps&&(tileMargin.value=validNum(tileProps.margin)?tileProps.margin:defTileMargin*fontSize,calcTiles()),titleProps&&(titleMargin.value=validNum(titleProps.margin)?titleProps.margin:defTitleMargin*fontSize,calcTitles()),invalidateLayoutCache(),nextTick(()=>{bigmode.enabled&&contWidth>0&&contHeight>0&&(buildLayoutCache(),calcBig(),updSkeleton())})}});let defFontSize=16,defTileWidth=10,defTileHeight=5,defTileMargin=.2,defTitleWidth=10,defTitleHeight=2.5,defTitleMargin=.2,layoutSelected=ref(props.layout);watch(()=>props.layout,()=>layoutSelected.value=props.layout||LIST_LAYOUTS.DEFAULT),watch(()=>layoutSelected.value,val=>{emit$1(`layoutChange`,val),invalidateLayoutCache(),updSize()});let toolbar=computed(()=>{let res={path:props.path&&props.path.length>0,layout:props.layoutSelector};return res.enabled=res.path||res.layout,res.show=res.enabled&&(res.path&&!props.pathTarget||res.layout&&!props.layoutSelectorTarget),res}),slots=useSlots(),elCont=ref(),elSize=ref(),elSkeleton=ref(),tileWidth=ref(0),tileHeight=ref(0),tileMargin=ref(0),titleWidth=ref(0),titleHeight=ref(0),titleMargin=ref(0),scrollPos=ref(0),skeletonItems=ref([]),processing=computed(()=>bigmode.enabled&&(bigmode.initial||layoutCache.building)),contWidth=0,contHeight=0,fontSize=16,skeletonShown=!1,warnShown=!1,listItemsStyle=computed(()=>bigmode.enabled?{transform:`translate${layoutSelected.value===LIST_LAYOUTS.RIBBON?`X`:`Y`}(${bigmode.position}px)`}:void 0),tileProps=null,titleProps=null,bigmode=reactive({enabled:!1,initial:!0,debounce:500,skeleton:!0,layouts:[],getPos:{[LIST_LAYOUTS.TILES]:()=>elCont.value?.scrollTop||0,[LIST_LAYOUTS.LIST]:()=>elCont.value?.scrollTop||0,[LIST_LAYOUTS.RIBBON]:()=>elCont.value?.scrollLeft||0},overflow:2,skeletonOverflow:2,first:0,last:0,perRow:1,items:[],position:0,full:0,size:0});bigmode.layouts=Object.keys(bigmode.getPos);let layoutCache=reactive({version:0,building:!1,valid:!1,itemCount:0,totalSize:0,rows:[],itemToRow:new Map,rowPositions:[]}),items$2=ref([]),itemsView=ref([]),itemsShown=ref(new Set);watch(()=>props.immediate,val=>{val?(bigmode._skeleton=bigmode.skeleton,bigmode._debounce=bigmode.debounce,bigmode.skeleton=!1,bigmode.debounce=0):(bigmode._skeleton&&(bigmode.skeleton=bigmode._skeleton),bigmode._debounce&&(bigmode.debounce=bigmode._debounce))},{immediate:!0}),watch([()=>slots.default?.(),()=>props.big,()=>layoutSelected.value],()=>{let res=slots.default?slots.default():[];bigmode.enabled=props.big&&bigmode.layouts.includes(layoutSelected.value),bigmode.enabled&&(bigmode.initial=!0,res=getItems(res)),res=res.map((item,key)=>({...item,key})),items$2.value=res,bigmode.enabled||(itemsView.value=res),itemsShown.value.clear(),nextTick(()=>{tileProps=getItemProps(res,!1),titleProps=getItemProps(res,!0),invalidateLayoutCache(),updSize(),updSkeleton()})},{immediate:!0});function getItems(vnodes,_level=0){let res=[];for(let vnode of vnodes)switch(typeof vnode.type){case`object`:{let isTitle=vnode.props&&`bng-list-title`in vnode.props,item={...vnode};isTitle&&(item.isBngListTitle=!0),res.push(item);break}case`symbol`:if(_level===20)return logger_default.debug(`BngList reached max level of nested Vue fragments`),[];res.push(...getItems(vnode.children,_level+1));break}return res}function findItem(vnode,_level=0){let res=null;switch(typeof vnode.type){case`object`:res={el:vnode.el,width:vnode.type.width,height:vnode.type.height,margin:vnode.type.margin};break;case`string`:vnode.el instanceof HTMLElement&&(res={el:vnode.el});break;case`symbol`:if(vnode.children.length>0){if(_level===20)return null;res=findItem(vnode.children[0],++_level)}break}return res}function getItemProps(vnodes,title=!1){if(vnodes.length===0)return null;let sampleItem=vnodes.find(vnode=>title&&vnode.isBngListTitle||!title&&!vnode.isBngListTitle);if(!sampleItem)return null;let res=findItem(sampleItem);if(!res)return null;let valid={width:validNum(res.width),height:validNum(res.height),margin:validNum(res.margin)},fontSize$1,targetWidth=0,targetHeight=0,targetMargin=0;if(!title&&props.tileSizeCalc)try{fontSize$1||=getFontSize();let size$3=props.tileSizeCalc({contWidth,contHeight,fontSize:fontSize$1,layout:layoutSelected.value});if(size$3&&typeof size$3==`object`){let isPx=size$3.unit===`px`;targetWidth=isPx?size$3.width/fontSize$1:size$3.width,targetHeight=isPx?size$3.height/fontSize$1:size$3.height,targetMargin=isPx?size$3.margin/fontSize$1:size$3.margin}}catch(err){logger_default.warn(`BngList: tileSizeCalc function error:`,err)}targetWidth||=title?props.titleWidth||props.targetTitleWidth:props.tileWidth||props.targetWidth,targetHeight||=title?props.titleHeight||props.targetTitleHeight:props.tileHeight||props.targetHeight,targetMargin||=title?props.titleMargin||props.targetTitleMargin:props.tileMargin||props.targetMargin,validNum(targetWidth)&&(res.width=targetWidth,valid.width=!0),validNum(targetHeight)&&(res.height=targetHeight,valid.height=!0),validNum(targetMargin)&&(res.margin=targetMargin,valid.margin=!0);let em2px=em=>(fontSize$1||=getFontSize(),em*fontSize$1);if(valid.width&&res.width&&(res.width=em2px(res.width)),valid.height&&res.height&&(res.height=em2px(res.height)),valid.margin&&res.margin&&(res.margin=em2px(res.margin)),!valid.width||bigmode.enabled&&!valid.height||!valid.margin){if(res.el instanceof HTMLElement){let style=window.getComputedStyle(res.el,null);valid.width||(res.width=+style.width.substring(0,style.width.length-2)),valid.height||(res.height=+style.height.substring(0,style.height.length-2)),valid.margin||(res.margin=[style.marginTop,style.marginRight,style.marginBottom,style.marginLeft].map(m=>+m.substring(0,m.length-2)).sort((a$1,b)=>b-a$1)[0])}else logger_default.warn(`BngList cannot access ${title?`title`:`tile`} element for size auto-detection!`);warnShown||(warnShown=!0,logger_default.debug(`BigList was not provided with ${title?`title`:`target`} sizes (from props or from ${title?`title`:`tile`} component export) and attempted to auto-detect them. This may lead to some size micro-adjustments visible to user or invalid sizes. Please specify ${title?`title`:`target`} sizes manually.`),(res.width<1||res.height<1)&&logger_default.debug(`BigList noticed a detected ${title?`title`:``} size being too low: width = ${res.width}, height = ${res.height}`))}return res}let validNum=num=>typeof num==`number`&&!isNaN(num),getFontSize=()=>{if(!elCont.value)return 16;let size$3=window.getComputedStyle(elCont.value,null).fontSize;return+size$3.substring(0,size$3.length-2)||16},resizeObserver=new ResizeObserver(updSize);onMounted(()=>nextTick(()=>{resizeObserver.observe(elSize.value)})),onBeforeUnmount(()=>{elSize.value&&resizeObserver.unobserve(elSize.value),resizeObserver.disconnect()});let scrolling=ref(!1),scrollTmr,scrollTick=!1,onScrollDebounce=async()=>{scrollPos.value=bigmode.getPos[layoutSelected.value](),await updSkeleton()};watch(scrollPos,async pos=>{if(bigmode.enabled)if(bigmode.debounce>0)clearTimeout(scrollTmr),scrolling.value=!0,scrollTmr=setTimeout(async()=>{scrolling.value=!1,await calcBig(pos),await updSkeleton()},bigmode.debounce);else{if(scrollTick)return;scrollTick=!0,requestAnimationFrame(async()=>{scrollTick=!1,await calcBig(pos),await updSkeleton()})}});function vScroll(evt){evt.deltaY!==0&&elCont.value.scrollBy({left:evt.deltaY,behavior:`instant`})}function updSize(entries=[]){let oldContWidth=contWidth,oldContHeight=contHeight;tileWidth.value=0,tileHeight.value=0,titleWidth.value=0,titleHeight.value=0,tileProps?(tileMargin.value=validNum(tileProps.margin)?tileProps.margin:defTileMargin*fontSize,calcTiles(entries)):tileMargin.value=0,titleProps?(titleMargin.value=validNum(titleProps.margin)?titleProps.margin:defTitleMargin*fontSize,calcTitles(entries)):titleMargin.value=0,(Math.abs(oldContWidth-contWidth)>1||Math.abs(oldContHeight-contHeight)>1)&&invalidateLayoutCache(),bigmode.enabled&&!layoutCache.valid&&contWidth>0&&contHeight>0&&(!titleProps||titleWidth.value>0&&titleHeight.value>0)&&buildLayoutCache(),bigmode.enabled&&bigmode.initial&&(tileProps||titleProps)&&nextTick(async()=>{await calcBig(),await updSkeleton(),setTimeout(async()=>{await calcBig(),await updSkeleton()},50)}),elCont.value.removeEventListener(`mousewheel`,vScroll),layoutSelected.value===LIST_LAYOUTS.RIBBON&&elCont.value.addEventListener(`mousewheel`,vScroll)}function calcSizes(entries=[]){if(contWidth=0,contHeight=0,!elSize.value||!bigmode.enabled&&layoutSelected.value!==LIST_LAYOUTS.TILES)return!1;let baseMargin=tileMargin.value,rect=entries[0]?.contentRect||elSize.value.getBoundingClientRect();if(fontSize=getFontSize(),contWidth=rect.width,layoutSelected.value===LIST_LAYOUTS.RIBBON){let tileHeight$1=(tileProps?.height||5*fontSize)+baseMargin,titleHeight$1=titleProps?(titleProps.height||defTitleHeight*fontSize)+(titleProps.margin||defTitleMargin*fontSize):0;contHeight=Math.max(tileHeight$1,titleHeight$1)}else contHeight=rect.height-baseMargin;return!0}function calcTiles(entries=[]){if(!calcSizes(entries))return;let wantsWidth=layoutSelected.value===LIST_LAYOUTS.TILES||bigmode.enabled&&layoutSelected.value===LIST_LAYOUTS.RIBBON,wantsHeight=bigmode.enabled;if(!wantsWidth&&!wantsHeight)return;let baseMargin=tileMargin.value;if(wantsWidth){let baseWidth=tileProps.width||10*fontSize;if(contWidth>0&&layoutSelected.value===LIST_LAYOUTS.TILES){let prepWidth=baseWidth+baseMargin,amount=contWidth/prepWidth;amount<2?tileWidth.value=contWidth-baseMargin:tileWidth.value=(contWidth-baseMargin)/~~amount-baseMargin}else tileWidth.value=baseWidth}wantsHeight&&(tileHeight.value=tileProps.height||5*fontSize),bigmode.enabled&&bigmode.initial&&((!wantsWidth||contWidth>0)&&(!wantsHeight||contHeight>0)?(bigmode.initial=!1,calcBig(),updSkeleton()):window.requestAnimationFrame(()=>calcTiles()))}function calcTitles(){if(bigmode.enabled&&(fontSize=getFontSize()),!titleProps)return;let baseMargin=titleMargin.value,baseHeight=titleProps.height||defTitleHeight*fontSize;layoutSelected.value===LIST_LAYOUTS.RIBBON?titleWidth.value=titleProps.width||10*fontSize:titleWidth.value=contWidth-baseMargin;let oldTitleHeight=titleHeight.value;titleHeight.value=baseHeight,bigmode.enabled&&oldTitleHeight===0&&titleHeight.value>0&&contWidth>0&&contHeight>0&&(invalidateLayoutCache(),buildLayoutCache())}function clearLayoutCache(){layoutCache.totalSize=0,layoutCache.rows=[],layoutCache.itemToRow.clear(),layoutCache.rowPositions=[],layoutCache.valid=!0,layoutCache.building=!1,bigmode.enabled&&(bigmode.initial=!1,bigmode.full=0,bigmode.position=0,itemsView.value=[])}async function buildLayoutCache(){if(layoutCache.building){for(;layoutCache.building;)await sleep(10);return}if(items$2.value.length===0){clearLayoutCache();return}if(!tileProps&&!titleProps||contWidth<=0||contHeight<=0)return;if(layoutCache.building=!0,layoutCache.version=Date.now(),layoutCache.itemCount=items$2.value.length,await sleep(0),layoutCache.rows=[],layoutCache.itemToRow.clear(),layoutCache.rowPositions=[],layoutCache.itemCount!==items$2.value.length&&(layoutCache.itemCount=0),layoutCache.itemCount===0){clearLayoutCache(),items$2.value.length>0&&buildLayoutCache();return}let baseTileMargin=tileProps?.margin||defTileMargin*fontSize,baseTitleMargin=titleProps?.margin||defTitleMargin*fontSize,horizontal=layoutSelected.value===LIST_LAYOUTS.RIBBON,tilesPerRow=layoutSelected.value===LIST_LAYOUTS.TILES?~~(contWidth/tileWidth.value):1,pos=0,first=0,curItems=0;function completeRow(i){let tileSize=horizontal?tileWidth.value:tileHeight.value,size$3=tileSize+baseTileMargin,row={pos,size:size$3,first,last:i-1};layoutCache.rows.push(row),layoutCache.rowPositions.push(pos);for(let j=first;j0&&(completeRow(i),curItems=0);let titleSize=horizontal?titleWidth.value:titleHeight.value,rowSize=titleSize+baseTitleMargin,row={pos,size:rowSize,first:i,last:i,isTitle:!0};layoutCache.rows.push(row),layoutCache.rowPositions.push(pos),layoutCache.itemToRow.set(i,layoutCache.rows.length-1);let nextMargin=items$2.value[i+1]?.isBngListTitle?baseTitleMargin:baseTileMargin;pos+=titleSize+nextMargin,first=i+1,curItems=0}else if(curItems++,curItems===1&&(first=i),curItems>=tilesPerRow){let tileSize=horizontal?tileWidth.value:tileHeight.value,size$3=tileSize+baseTileMargin,row={pos,size:size$3,first,last:i};layoutCache.rows.push(row),layoutCache.rowPositions.push(pos);for(let j=first;j<=i;j++)layoutCache.itemToRow.set(j,layoutCache.rows.length-1);let nextMargin=items$2.value[i+1]?.isBngListTitle?baseTitleMargin:baseTileMargin;pos+=tileSize+nextMargin,curItems=0,first=i+1}curItems>0&&completeRow(layoutCache.itemCount),pos+=items$2.value[layoutCache.itemCount-1]?.isBngListTitle?baseTitleMargin:baseTileMargin,layoutCache.totalSize=pos,layoutCache.valid=!0,layoutCache.building=!1}function invalidateLayoutCache(){layoutCache.valid=!1,layoutCache.version++}function layoutCacheSearch(arr,target){let left=0,right=arr.length-1;for(;left<=right;){let mid=~~((left+right)/2);arr[mid]<=target?left=mid+1:right=mid-1}return Math.max(0,right)}async function getBigProps(pos=void 0,index=void 0,overflow=void 0){let count$1=items$2.value.length;if(count$1===0)return;if((!layoutCache.valid||layoutCache.itemCount!==count$1)&&(await buildLayoutCache(),!layoutCache.valid))return null;(typeof index!=`number`||index<0)&&(index=void 0,typeof pos!=`number`&&(pos=bigmode.getPos[layoutSelected.value]()));let contSize=layoutSelected.value===LIST_LAYOUTS.RIBBON?contWidth:contHeight;typeof overflow!=`number`&&(overflow=bigmode.overflow);let overflowBefore=Math.ceil(overflow/2),overflowAfter=Math.floor(overflow/2),firstRow=0,currentPos=0;if(typeof index==`number`&&index>=0){let rowIndex=layoutCache.itemToRow.get(index);rowIndex!==void 0&&(firstRow=rowIndex,currentPos=layoutCache.rows[rowIndex].pos,pos=currentPos)}else firstRow=layoutCacheSearch(layoutCache.rowPositions,pos),currentPos=layoutCache.rows[firstRow]?.pos||0;let extendedFirstRow=firstRow,backwardCount=0;for(let i=firstRow-1;i>=0&&backwardCount=contSize));i++);let overflowCount=0;for(let i=lastRow+1;iprops.keepAlive){let center=big.first+(big.last-big.first)/2,farthest=Array.from(itemsShown.value).sort((a$1,b)=>Math.abs(b-center)-Math.abs(a$1-center)).slice(0,itemsShown.value.size-props.keepAlive);for(let idx of farthest)itemsShown.value.delete(idx)}big.items=Array.from(itemsShown.value).sort((a$1,b)=>a$1-b).map(idx=>{let item=items$2.value[idx];return idx>=big.first&&idx<=big.last?item:{...item,keepAliveStyle:`display: none !important;`}})}else itemsShown.value.size>0&&itemsShown.value.clear();bigmode.items=big.items,itemsView.value=big.items}}function showSkeleton(show=!0){skeletonShown!==show&&(show?elSkeleton.value.style.removeProperty(`display`):(skeletonItems.value=[],elSkeleton.value.style.setProperty(`display`,`none`,`important`)),skeletonShown=show)}async function updSkeleton(){if(!elSkeleton.value||!bigmode.enabled||!bigmode.skeleton||!scrolling.value||items$2.value.length===0||!layoutCache.valid){showSkeleton(!1);return}if(bigmode.first===0&&bigmode.last===items$2.value.length-1){showSkeleton(!1);return}let horizontal=layoutSelected.value===LIST_LAYOUTS.RIBBON,contSize=horizontal?contWidth:contHeight,pos=scrollPos.value,start,end;if(pos=bigmode.position||(end=i,visibleSize+=row.size,visibleSize>=contSize))break}let overflowCount=0;for(let i=end+1;i=bigmode.position);i++)end=i,overflowCount++;let neededSize=contSize+bigmode.skeletonOverflow*(horizontal?tileWidth.value:tileHeight.value),backwardSize=visibleSize;for(;start>0&&backwardSize=contSize));i++);let overflowCount=0;for(let i=end+1;i(openBlock(),createElementBlock(`div`,_hoisted_1$316,[toolbar.value.enabled?withDirectives((openBlock(),createElementBlock(`div`,_hoisted_2$257,[toolbar.value.path?(openBlock(),createBlock(Teleport,{key:0,disabled:!__props.pathTarget,to:__props.pathTarget},[createVNode(unref(bngBreadcrumbs_default),{ref_key:`elPath`,ref:elPath,items:__props.path,limit:__props.pathLimit,blur:!__props.noBackground,onClick:_cache[0]||=itm=>emit$1(`pathClick`,itm)},null,8,[`items`,`limit`,`blur`])],8,[`disabled`,`to`])):(openBlock(),createElementBlock(`div`,_hoisted_3$224)),toolbar.value.layout?(openBlock(),createBlock(Teleport,{key:2,disabled:!__props.layoutSelectorTarget,to:__props.layoutSelectorTarget},[createBaseVNode(`div`,_hoisted_4$192,[createVNode(unref(bngButton_default),{accent:layoutSelected.value===LIST_LAYOUTS.TILES?unref(ACCENTS).outlined:unref(ACCENTS).text,icon:unref(icons).tiles,onClick:_cache[1]||=$event=>layoutSelected.value=LIST_LAYOUTS.TILES},null,8,[`accent`,`icon`]),createVNode(unref(bngButton_default),{accent:layoutSelected.value===LIST_LAYOUTS.LIST?unref(ACCENTS).outlined:unref(ACCENTS).text,icon:unref(icons).listSmall,onClick:_cache[2]||=$event=>layoutSelected.value=LIST_LAYOUTS.LIST},null,8,[`accent`,`icon`])])],8,[`disabled`,`to`])):createCommentVNode(``,!0)],512)),[[vShow,toolbar.value.show]]):createCommentVNode(``,!0),withDirectives((openBlock(),createElementBlock(`div`,{ref_key:`elCont`,ref:elCont,class:normalizeClass({"list-content":!0,"list-with-background":!__props.noBackground,[`list-layout-${layoutSelected.value}`]:!0,"list-item-width":!!tileWidth.value,"list-item-height":!!tileHeight.value,"list-item-margin":!!tileMargin.value,"list-title-width":!!titleWidth.value,"list-title-height":!!titleHeight.value,"list-title-margin":!!titleMargin.value,"list-big":bigmode.enabled,"list-scrolling":scrolling.value||bigmode.debounce===0,"list-processing":processing.value}),style:normalizeStyle({"--list-item-width":`${tileWidth.value}px`,"--list-item-height":`${tileHeight.value}px`,"--list-item-margin":`${tileMargin.value}px`,"--list-title-width":`${titleWidth.value}px`,"--list-title-height":`${titleHeight.value}px`,"--list-title-margin":`${titleMargin.value}px`,"--list-big-full":`${bigmode.full}px`}),onScroll:onScrollDebounce},[createBaseVNode(`div`,{ref_key:`elSize`,ref:elSize,class:`list-content-size-observer`},null,512),bigmode.enabled&&bigmode.skeleton?(openBlock(),createElementBlock(`div`,{key:0,ref_key:`elSkeleton`,ref:elSkeleton,class:`list-skeleton`},[(openBlock(!0),createElementBlock(Fragment,null,renderList(skeletonItems.value,(isTitle,i)=>(openBlock(),createElementBlock(`div`,{key:`skeleton-${i}`,class:normalizeClass({"skeleton-item":!0,"skeleton-title":isTitle})},null,2))),128))],512)):createCommentVNode(``,!0),createBaseVNode(`div`,{class:`list-items`,style:normalizeStyle(listItemsStyle.value)},[(openBlock(!0),createElementBlock(Fragment,null,renderList(itemsView.value,vnode=>(openBlock(),createBlock(resolveDynamicComponent(vnode),{key:vnode.key,style:normalizeStyle(vnode.keepAliveStyle)},null,8,[`style`]))),128))],4)],38)),[[unref(BngBlur_default),!__props.noBackground]])]))}},bngList_default=__plugin_vue_export_helper_default(_sfc_main$361,[[`__scopeId`,`data-v-5af5eff2`]]),_hoisted_1$315={class:`bng-stars`},_hoisted_2$256={key:0,class:`stars`},_hoisted_3$223=[`innerHTML`],_hoisted_4$191=[`innerHTML`],_hoisted_5$163={key:1,class:`stars`},_hoisted_6$140={class:`stars-label`},_hoisted_7$122=[`innerHTML`],_sfc_main$360={__name:`bngMainStars`,props:{unlockedStars:{type:Number,default:0,validator:val=>val>=0},totalStars:{type:Number,default:1},scale:{type:Number,default:1},individualStars:{type:Object,default:null,validator:val=>val===null||Array.isArray(val)},numerical:{type:Boolean,default:!1}},setup(__props){useCssVars(_ctx=>({v3c930dd6:fontSize.value}));let props=__props,fontSize=computed(()=>`${props.scale}rem`),starsTotal=computed(()=>props.individualStars?props.individualStars.length:props.totalStars),starsFilled=computed(()=>props.individualStars?props.individualStars.filter(Boolean).length:props.unlockedStars),starsUnfilled=computed(()=>starsTotal.value-starsFilled.value),glyphsFilled=computed(()=>starsFilled.value>0?icons.star.glyph.repeat(starsFilled.value):``),glyphsUnfilled=computed(()=>starsUnfilled.value>0?icons.star.glyph.repeat(starsUnfilled.value):``);return(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$315,[!__props.numerical&&__props.individualStars&&__props.individualStars.length?(openBlock(),createElementBlock(`div`,_hoisted_2$256,[starsFilled.value?(openBlock(),createElementBlock(`span`,{key:0,class:`star star-filled`,innerHTML:glyphsFilled.value},null,8,_hoisted_3$223)):createCommentVNode(``,!0),starsUnfilled.value?(openBlock(),createElementBlock(`span`,{key:1,class:`star star-unfilled`,innerHTML:glyphsUnfilled.value},null,8,_hoisted_4$191)):createCommentVNode(``,!0)])):(openBlock(),createElementBlock(`div`,_hoisted_5$163,[createBaseVNode(`div`,_hoisted_6$140,toDisplayString(starsFilled.value)+` / `+toDisplayString(starsTotal.value),1),createBaseVNode(`span`,{class:`star star-filled`,innerHTML:unref(icons).star.glyph},null,8,_hoisted_7$122)]))]))}},bngMainStars_default=__plugin_vue_export_helper_default(_sfc_main$360,[[`__scopeId`,`data-v-4ba4c794`]]),_hoisted_1$314=[`rows`,`placeholder`,`disabled`],_hoisted_2$255={key:0,class:`floating-label`},_sfc_main$359={__name:`bngMultilineInput`,props:{floatingLabel:String,externalLabel:String,placeholder:String,initialValue:String,leadingIcon:Object,trailingIcon:Object,scalable:Boolean,hasError:Boolean,errorMessage:String,lines:{type:Number,default:1},disabled:{type:Boolean,default:!1}},setup(__props){useCssVars(_ctx=>({v26daab40:bngScalableInputMaxWidth.value}));let props=__props,inputContainer=ref(null),bngMultilineInput=ref(null),focusHighlight=ref(null),leadingIconContainer=ref(null),trailingIconContainer=ref(null),value=ref(``),isInputFieldFocused=ref(!1),hasValue=computed(()=>value.value!==``&&value.value!==void 0),bngScalableInputMaxWidth=computed(()=>`${(leadingIconContainer.value?leadingIconContainer.value.offsetWidth:0)+(trailingIconContainer.value?trailingIconContainer.value.offsetWidth:0)}px`),resizeObserver;onBeforeMount(()=>{value.value=props.initialValue,resizeObserver=new ResizeObserver(onInputResize)}),onMounted(()=>{resizeObserver.observe(bngMultilineInput.value)}),onDeactivated(()=>{resizeObserver.disconnect()});function onInputFieldFocusIn(){isInputFieldFocused.value=!0}function onInputFieldFocusOut(){isInputFieldFocused.value=!1}function onInputResize(){inputContainer.value&&window.requestAnimationFrame(()=>{let focusRight=inputContainer.value.offsetWidth-inputContainer.value.offsetWidth;focusHighlight.value.style.right=`${focusRight-2}px`})}return(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,{class:normalizeClass([`input-icon-wrapper`,{scalable:__props.scalable}])},[__props.leadingIcon?(openBlock(),createElementBlock(`span`,{key:0,ref_key:`leadingIconContainer`,ref:leadingIconContainer,class:`input-icon`},[createVNode(unref(bngIcon_default),{type:__props.leadingIcon},null,8,[`type`])],512)):createCommentVNode(``,!0),createBaseVNode(`div`,{ref_key:`inputContainer`,ref:inputContainer,class:normalizeClass([`bng-multiline-input`,{"input-focused":isInputFieldFocused.value,"has-error":__props.hasError}]),tabindex:`0`},[withDirectives(createBaseVNode(`textarea`,{"onUpdate:modelValue":_cache[0]||=$event=>value.value=$event,ref_key:`bngMultilineInput`,ref:bngMultilineInput,class:normalizeClass([`input-field`,{empty:!hasValue.value,"has-value":hasValue.value,"has-error":__props.hasError,disabled:__props.disabled}]),rows:__props.lines,placeholder:__props.floatingLabel,disabled:__props.disabled,onFocusin:onInputFieldFocusIn,onFocusout:onInputFieldFocusOut},null,42,_hoisted_1$314),[[vModelText,value.value],[unref(BngTextInput_default)]]),__props.floatingLabel?(openBlock(),createElementBlock(`span`,_hoisted_2$255,toDisplayString(__props.floatingLabel),1)):createCommentVNode(``,!0),createBaseVNode(`span`,{ref_key:`focusHighlight`,ref:focusHighlight,class:`focus-highlight`},null,512)],2),__props.trailingIcon?(openBlock(),createElementBlock(`span`,{key:1,ref_key:`trailingIconContainer`,ref:trailingIconContainer,class:`input-icon`},[createVNode(unref(bngIcon_default),{type:__props.trailingIcon},null,8,[`type`])],512)):createCommentVNode(``,!0)],2))}},bngMultilineInput_default=__plugin_vue_export_helper_default(_sfc_main$359,[[`__scopeId`,`data-v-6c6cfdb8`]]);const icons$1={undefined:`undefined`,arrow:{large:{up:`arrow/large_up`,down:`arrow/large_down`,left:`arrow/large_left`,right:`arrow/large_right`},small:{up:`arrow/arrowSmallUp`,down:`arrow/arrowSmallDown`,left:`arrow/arrowSmallLeft`,right:`arrow/arrowSmallRight`}},drive:{autobahn:`drive/autobahn`,busroutes:`drive/busroutes`,campaigns:`drive/campaigns`,career:`drive/career`,freeroam:`drive/freeroam`,garage:`drive/garage`,infinity:`drive/infinity`,lightrunner:`drive/lightrunner`,m_a:`drive/m_a`,m_b:`drive/m_b`,m_c:`drive/m_c`,play:`drive/play`,quit:`drive/quit`,scenarios:`drive/scenarios`,timetrials:`drive/timetrials`},general:{offbtn:`general/offbtn`,unknown:`general/unknown`,check:`general/check`,recharge:`general/recharge`,refuel:`general/refuel`,beambuck:`general/beambuck`,money:`general/beambuck`,beamXP:`general/beamXP`,arrow_small_left:`general/arrow_small-left`,arrow_small_right:`general/arrow_small-right`,fuel_nozzle:`general/fuel-nozzle`,recharge_connector:`general/recharge-connector`,star:`general/star`,star_outlined:`general/star-secondary`,vehicle:`general/vehicle`,awd:`general/awd`,"4wd":`general/4wd`,fwd:`general/fwd`,rwd:`general/rwd`,drivetrain_special:`general/drivetrain-special`,drivetrain_generic:`general/drivetrain-generic`,charge:`general/charge`,fuel:`general/fuel`,odometer:`general/odometer`,power_gauge_01:`general/power-gauge-01c`,power_gauge_02:`general/power-gauge-02c`,power_gauge_03:`general/power-gauge-03c`,power_gauge_04:`general/power-gauge-04c`,power_gauge_05:`general/power-gauge-05c`,weight:`general/weight`,transmission_a:`general/transmission-a`,transmission_m:`general/transmission-m`},device:{keyboard:`device/keyboard`,phone_android:`device/phone_android`,wheel:`device/wheel`,gamepad:`device/gamepad`,videogame_asset:`device/videogame_asset`,mouse:{button0:`device/mouse/button0`,button1:`device/mouse/button1`,button2:`device/mouse/button2`,xaxis:`device/mouse/xaxis`,yaxis:`device/mouse/yaxis`,zaxis:`device/mouse/zaxis`},xbox:{btn_a:`device/xbox/btn_a`,btn_b:`device/xbox/btn_b`,btn_back:`device/xbox/btn_back`,btn_lb:`device/xbox/btn_lb`,btn_lt:`device/xbox/btn_lt`,btn_rb:`device/xbox/btn_rb`,btn_rt:`device/xbox/btn_rt`,btn_start:`device/xbox/btn_start`,btn_x:`device/xbox/btn_x`,btn_y:`device/xbox/btn_y`,btn_dpad_default_filled:`device/xbox/btn_dpad_default_filled`,btn_dpad_default_outline:`device/xbox/btn_dpad_default_outline`,btn_dpad_down:`device/xbox/btn_dpad_down`,btn_dpad_left:`device/xbox/btn_dpad_left`,btn_dpad_right:`device/xbox/btn_dpad_right`,btn_dpad_up:`device/xbox/btn_dpad_up`,btn_thumb_left:`device/xbox/btn_thumb_left`,btn_thumb_left_x:`device/xbox/btn_thumb_left_x`,btn_thumb_left_y:`device/xbox/btn_thumb_left_y`,btn_thumb_right:`device/xbox/btn_thumb_right`,btn_thumb_right_x:`device/xbox/btn_thumb_right_x`,btn_thumb_right_y:`device/xbox/btn_thumb_right_y`}},decals:{camera:{back:`decals/camera/back`,freecam:`decals/camera/freecam`,front:`decals/camera/front`,left:`decals/camera/left`,right:`decals/camera/right`,top:`decals/camera/top`},general:{change_order:`decals/general/change_order`,deform:`decals/general/deform`,delete:`decals/general/delete`,duplicate:`decals/general/duplicate`,hide:`decals/general/hide`,lock:`decals/general/lock`,mirror:`decals/general/mirror`,options:`decals/general/options`,redo:`decals/general/redo`,rename:`decals/general/rename`,save:`decals/general/save`,transform:`decals/general/transform`,undo:`decals/general/undo`,unlock:`decals/general/unlock`,use_mask:`decals/general/mask`},group:{group:`decals/group/group`,ungroup:`decals/group/ungroup`},layer:{decal:`decals/layer/decal`,material:`decals/layer/material`},mirror:{copy_mirrored:`decals/mirror/copy_mirrored`,copy_straight:`decals/mirror/copy_straight`}}},iconTypesList=makeIconTypesList(icons$1);function makeIconTypesList(dict){let key,all=[];for(key in dict)all=all.concat(typeof dict[key]==`string`?dict[key]:makeIconTypesList(dict[key]));return all}var _hoisted_1$313=[`src`],_sfc_main$358={__name:`bngOldIcon`,props:{type:{type:String,validator:v=>iconTypesList.includes(v)},span:{type:Boolean,default:!0},mask:{type:Boolean,default:!0},color:String},setup(__props){let props=__props,iconImageURL=computed(()=>getAssetURL(`icons/${props.type}.svg`)),spanStyle=computed(()=>({[props.mask?`maskImage`:`backgroundImage`]:`url(${iconImageURL.value})`,backgroundColor:props.color||`#fff`}));return(_ctx,_cache)=>__props.span?(openBlock(),createElementBlock(`span`,{key:0,class:`bngicon`,style:normalizeStyle(spanStyle.value)},[renderSlot(_ctx.$slots,`default`,{},void 0,!0)],4)):(openBlock(),createElementBlock(`img`,{key:1,class:`bngicon`,src:iconImageURL.value,alt:``},null,8,_hoisted_1$313))}},bngOldIcon_default=__plugin_vue_export_helper_default(_sfc_main$358,[[`__scopeId`,`data-v-da0e0a74`]]),_hoisted_1$312=[`bng-no-child-nav`],scrollBuildupTime=3e3,scrollMaxSpeedModifier=4,CLICKID=`__bngOverflowContainer`,_sfc_main$357={__name:`bngOverflowContainer`,props:{scrollSpeed:{type:Number,default:5},initialIndex:{type:Number,default:-1},useBindings:[Boolean,Array],useBindingsOnly:[Boolean,Array],showBindings:{type:Boolean,default:!0},showArrows:{type:Boolean,default:!1},noWheel:{type:Boolean,default:!1}},setup(__props,{expose:__expose}){let slots=useSlots(),props=__props,useBindings=props.useBindings||props.useBindingsOnly,useBindingsOnly=props.useBindingsOnly;watch([()=>props.useBindings,()=>props.useBindingsOnly],()=>console.warn(`useBindings and useBindingsOnly can only be set at component mount time`));let uinavBound=!1,focusNav=useBindings&&Array.isArray(useBindings)?useBindings:[`tab_l`,`tab_r`],elBindPrev=ref(null),elBindNext=ref(null),elCont=ref(null),scrollContainer=ref(null),showLeftFade=ref(!1),showRightFade=ref(!1),resizeObserver=new ResizeObserver(updateFadeVisibility),scrollInterval=null,scrollTime=0,lastActive=null,fixingActive=!1;function setActive(elm){clearActive(),elm instanceof Element&&(elm.setAttribute(`active`,`true`),lastActive=elm)}function clearActive(evt){lastActive&&(evt&&(evt.detail?.target||evt.target)===lastActive||(lastActive.removeAttribute(`active`),lastActive=null))}function fixActive(evt){if(fixingActive||useBindings&&evt.type===`focusin`)return;let active=evt.detail?.target||evt.target||document.activeElement;if(active.matches(`[is-bng-panel], [bng-nav-item], [ng-click], [href], [bng-all-clicks], [bng-all-clicks-no-nav], [ui-sref], input, textarea, button, md-option, md-slider, md-select, md-checkbox`)||(active=active.closest(NAVIGABLE_ELEMENTS_SELECTOR)),scrollContainer.value.contains(active)&&!(lastActive&&(lastActive===active||lastActive.contains(active)))){if(useBindingsOnly){fixingActive=!0;let prev=evt.detail.relatedTarget||evt.relatedTarget;prev&&scrollContainer.value.contains(prev)&&(prev=null),prev?setFocusExternal(prev,!0):setFocusExternal(active,!1)}nextTick(()=>{setActive(active),fixingActive=!1})}}let firstTime=!0;function updateContents(){if(!scrollContainer.value)return;let elFirst;for(let elm of scrollContainer.value.children)firstTime&&!elFirst&&(elFirst=elm),!elm[CLICKID]&&(elm[CLICKID]=!0,elm.addEventListener(`click`,fixActive));firstTime&&elFirst&&props.initialIndex>-1&&(firstTime=!1,elFirst.matches(`[is-bng-panel], [bng-nav-item], [ng-click], [href], [bng-all-clicks], [bng-all-clicks-no-nav], [ui-sref], input, textarea, button, md-option, md-slider, md-select, md-checkbox`)||(elFirst=elFirst.querySelector(NAVIGABLE_ELEMENTS_SELECTOR)),elFirst&&activate(elFirst))}watch([()=>slots.default?.(),()=>scrollContainer.value],()=>nextTick(updateContents),{immediate:!0});function navContents(dir,fireClick=!1){let links=collectRects(dir,scrollContainer.value,useBindingsOnly),prev=lastActive;clearActive();let res;if(useBindingsOnly){let idx=links[dir].findIndex(link=>link.dom===prev);idx>-1?res=links[dir][dir===`right`?idx+1:idx-1]:idx===0&&dir===`left`?res=links[dir][links[dir].length-1]:idx===links[dir].length-1&&dir===`right`&&(res=links[dir][0]),res&&(setActive(res.dom),scrollFix(res,dir))}else prev&&(res=navigate(links,dir,prev),res&&setActive(res));res?fireClick&&(res.dom&&(res=res.dom),nextTick(()=>res?.dispatchEvent(new Event(`click`)))):(scrollContainer.value.scrollTo({left:dir===`right`?0:scrollContainer.value.clientWidth,behavior:`instant`}),nextTick(()=>{let elms$4=collectRects(`right`,scrollContainer.value,!0).right;dir===`left`&&elms$4.reverse(),res=elms$4[0],res&&(setActive(res.dom),useBindingsOnly?scrollFix(res,dir):setFocusExternal(res.dom),fireClick&&res.dom.dispatchEvent(new Event(`click`)))}))}let activatePrev=()=>navContents(`left`,!0),activateNext=()=>navContents(`right`,!0);function activate(indexOrElement){let elm;if(typeof indexOrElement==`number`){let elms$4=scrollContainer.value.querySelectorAll(NAVIGABLE_ELEMENTS_SELECTOR);indexOrElement<0&&(indexOrElement=elms$4.length+indexOrElement),elm=elms$4[indexOrElement]}else if(indexOrElement instanceof Element)elm=indexOrElement;else throw Error(`Invalid argument`);if(!elm)throw Error(`Element not found`);scrollFix({dom:elm,rect:elm.getBoundingClientRect()},`right`),setActive(elm),!useBindingsOnly&&setFocusExternal(elm)}if(__expose({scrollBy:amount=>scrollContainer.value?.scrollBy({left:amount,behavior:`smooth`}),activatePrev,activateNext,activate,deactivate:()=>{let active=document.activeElement,activeCorrect=active&&active===lastActive;clearActive(),activeCorrect&&(useBindingsOnly&&setFocusExternal(active,!1),active.blur?.())},refresh:(withActivation=!1)=>{withActivation&&(firstTime=!0),updateContents()}}),useBindings){let instance$1=getCurrentInstance(),contUnwatch=watch(()=>elCont.value,elm=>{elm&&(contUnwatch(),nextTick(()=>{uinavBound=!0;let vnode={ctx:instance$1,el:elm};BngOnUiNav_default.mounted(elm,{arg:focusNav[0],modifiers:{},value:activatePrev},vnode),BngOnUiNav_default.mounted(elm,{arg:focusNav[1],modifiers:{},value:activateNext},vnode),elm.addEventListener(`focusin`,fixActive)}))},{immediate:!0})}watch(scrollContainer,elm=>{elm&&(updateFadeVisibility(),resizeObserver.observe(elm))},{immediate:!0});function updateFadeVisibility(){if(!scrollContainer.value)return;let{scrollLeft,scrollWidth,clientWidth}=scrollContainer.value;showLeftFade.value=scrollLeft>0,showRightFade.value=scrollLeft{let speedModifier=Math.min(1+(scrollMaxSpeedModifier-1)*(scrollTime/scrollBuildupTime),scrollMaxSpeedModifier),scrollAmount=(direction$1===`left`?-props.scrollSpeed:props.scrollSpeed)*speedModifier;scrollContainer.value.scrollLeft+=scrollAmount,updateFadeVisibility(),scrollTime+=1e3/30},1e3/30)}function stopScrolling(){scrollInterval&&=(clearInterval(scrollInterval),null),scrollTime=0}function onWheel(evt){props.noWheel||(evt.preventDefault(),scrollContainer.value.scrollLeft+=evt.deltaY,updateFadeVisibility())}function onScroll(){updateFadeVisibility()}return onBeforeUnmount(()=>{resizeObserver.disconnect(),stopScrolling(),uinavBound&&(BngOnUiNav_default.beforeUnmount(elCont.value),elCont.value.removeEventListener(`focusin`,fixActive))}),(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,{ref_key:`elCont`,ref:elCont,class:normalizeClass([`bng-overflow-container`,{"with-bindings":unref(useBindings)&&(elBindPrev.value?.displayed||elBindNext.value?.displayed),"with-arrows":__props.showArrows&&!(elBindPrev.value?.displayed||elBindNext.value?.displayed),"hide-bindings":!__props.showBindings}]),onWheel},[withDirectives(createBaseVNode(`div`,{class:`fade-left`,onMouseenter:_cache[0]||=$event=>startScrolling(`left`),onMouseleave:stopScrolling},null,544),[[vShow,showLeftFade.value]]),withDirectives(createBaseVNode(`div`,{class:`fade-right`,onMouseenter:_cache[1]||=$event=>startScrolling(`right`),onMouseleave:stopScrolling},null,544),[[vShow,showRightFade.value]]),__props.showArrows&&!elBindPrev.value?.displayed?(openBlock(),createBlock(unref(bngIcon_default),{key:0,type:unref(icons).arrowLargeLeft,class:`hint-prev`},null,8,[`type`])):createCommentVNode(``,!0),__props.showArrows&&!elBindNext.value?.displayed?(openBlock(),createBlock(unref(bngIcon_default),{key:1,type:unref(icons).arrowLargeRight,class:`hint-next`},null,8,[`type`])):createCommentVNode(``,!0),unref(useBindings)?(openBlock(),createBlock(unref(bngBinding_default),{key:2,ref_key:`elBindPrev`,ref:elBindPrev,class:`hint-prev`,"ui-event":unref(focusNav)[0],controller:``},null,8,[`ui-event`])):createCommentVNode(``,!0),unref(useBindings)?(openBlock(),createBlock(unref(bngBinding_default),{key:3,ref_key:`elBindNext`,ref:elBindNext,class:`hint-next`,"ui-event":unref(focusNav)[1],controller:``},null,8,[`ui-event`])):createCommentVNode(``,!0),createBaseVNode(`div`,{ref_key:`scrollContainer`,ref:scrollContainer,class:`scroll-container`,"bng-no-child-nav":unref(useBindingsOnly),onScroll},[renderSlot(_ctx.$slots,`default`,{},void 0,!0)],40,_hoisted_1$312)],34))}},bngOverflowContainer_default=__plugin_vue_export_helper_default(_sfc_main$357,[[`__scopeId`,`data-v-24544cbf`]]);const rainbow=(numOfSteps,step)=>{let r,g,b,h$1=step/numOfSteps,i=~~(h$1*6),f=h$1*6-i,q=1-f;switch(i%6){case 0:[r,g,b]=[1,f,0];break;case 1:[r,g,b]=[q,1,0];break;case 2:[r,g,b]=[0,1,f];break;case 3:[r,g,b]=[0,q,1];break;case 4:[r,g,b]=[f,0,1];break;case 5:[r,g,b]=[1,0,q];break}return[r,g,b]},hueToRGB=(p$1,q,t)=>(t<0&&(t+=1),t>1&&--t,t<1/6?p$1+(q-p$1)*6*t:t<1/2?q:t<2/3?p$1+(q-p$1)*(2/3-t)*6:p$1),HSLToRGB=(h$1,s,l)=>{let r,g,b;if(s===0)r=g=b=l;else{let q=l<.5?l*(1+s):l+s-l*s,p$1=2*l-q;r=hueToRGB(p$1,q,h$1+1/3),g=hueToRGB(p$1,q,h$1),b=hueToRGB(p$1,q,h$1-1/3)}return[r,g,b]},RGBToHSL=(r,g,b)=>{let vmax=Math.max(r,g,b),vmin=Math.min(r,g,b),h$1,s,l=(vmax+vmin)/2;if(vmax===vmin)return[0,0,l];let d=vmax-vmin;return s=l>.5?d/(2-vmax-vmin):d/(vmax+vmin),vmax===r&&(h$1=(g-b)/d+(gnum;else if(val<=15){let prec=10**val;this._precision=num=>~~(num*prec)/prec}else throw TypeError(`Precision can't go higher than 15`)}_sync({hsl=!1,rgb=!1}={}){if(hsl&&rgb)throw Error(`Cannot set both HSL and RGB changes at once`);this._dirty.hsl&&!hsl?this._rgb=HSLToRGB(...this._hsl):this._dirty.rgb&&!rgb&&(this._hsl=RGBToHSL(...this._rgb)),this._dirty.hsl=hsl,this._dirty.rgb=rgb}_parse(val){let res;if(isProxy(val)&&(val=toRaw(val)),typeof val==`string`&&(val=val.split(` `)),typeof val==`object`&&Array.isArray(val)){if(val.length<3)throw Error(`Invalid colour array length`);val.length===3&&(val=[...val,1]),val=val.map(Number);for(let num of val)if(isNaN(num))throw Error(`Values must be numbers`);res=val}if(!res)throw Error(`Color must be either an array or a string`);return res}get hslString(){return this.hsl.join(` `)}get hslaString(){return this.hsla.join(` `)}get rgbString(){return this.rgb.join(` `)}get rgbaString(){return this.rgba.join(` `)}get saturationPercent(){return Math.round(this.saturation*100)}get luminosityPercent(){return Math.round(this.luminosity*100)}get alphaPercent(){return Math.round(this._alpha*50)}get metallicPercent(){return Math.round(this._metallic*100)}get roughnessPercent(){return Math.round(this._roughness*100)}get clearcoatPercent(){return Math.round(this._clearcoat*100)}get clearcoatRoughnessPercent(){return Math.round(this._clearcoatRoughness*100)}get paint(){return[...this._legacy?this.rgba:this.rgb,this.metallic,this.roughness,this.clearcoat,this.clearcoatRoughness].map(this._precision)}get paintString(){return this.paint.join(` `)}get paintObject(){return this._paintObjectNames.reduce((res,name)=>({...res,[name]:this[name]}),{})}set paint(val){let data;if(isProxy(val)&&(val=toRaw(val)),typeof val==`object`){if(!Array.isArray(val)){data={...val};let names=this._paintObjectNames;for(let name of names){if(name===`baseColor`){this.baseColor=name in data?data[name]:[1,1,1,1];continue}let num=0;name in data&&(num=Number(data[name]),isNaN(num)&&(num=0)),this[name]=num}return}data=val}else if(typeof val==`string`)data=val.split(` `);else throw TypeError(`Invalid data type`);if(data.length===8)this.rgba=data.slice(0,4);else if(data.length===7)this.rgb=data.slice(0,3);else throw TypeError(`Invalid data value`);[this._metallic,this._roughness,this._clearcoat,this._clearcoatRoughness]=data.slice(-4)}get metallic(){return this._precision(this._metallic)}set metallic(val){this._metallic=Number(val)}get roughness(){return this._precision(this._roughness)}set roughness(val){this._roughness=Number(val)}get clearcoat(){return this._precision(this._clearcoat)}set clearcoat(val){this._clearcoat=Number(val)}get clearcoatRoughness(){return this._precision(this._clearcoatRoughness)}set clearcoatRoughness(val){this._clearcoatRoughness=Number(val)}get alpha(){return this._precision(this._alpha)}set alpha(val){let type=typeof val;type!==`undefined`&&(type===`number`?this._alpha=val:this._alpha=Number(val))}get hsl(){return this._sync(),this._hsl.map(this._precision)}set hsl(val){let arr=this._parse(val);this._sync({hsl:!0}),this._hsl=arr.slice(0,3),this.alpha=arr[3]}get rgb(){return this._sync(),this._rgb.map(this._precision)}get rgb255(){return this.rgb.map(val=>Math.round(val*255))}set rgb(val){let arr=this._parse(val);this._sync({rgb:!0}),this._rgb=arr.slice(0,3),this.alpha=arr[3]}set rgb255(val){let arr=this._parse(val);this.rgb=[...arr.slice(0,3).map(val$1=>val$1/255),arr[3]]}get hsla(){return[...this.hsl,this.alpha]}set hsla(val){this.hsl=val}get rgba(){return[...this.rgb,this.alpha]}set rgba(val){this.rgb=val}get baseColor(){return this.rgba}set baseColor(val){this.rgba=val}get hue(){return this.hsl[0]}get hue360(){return this.hsl[0]*360}set hue(val){this._sync({hsl:!0}),this._hsl[0]=Number(val)}set hue360(val){this.hue=Number(val)/360}get saturation(){return this.hsl[1]}set saturation(val){this._sync({hsl:!0}),this._hsl[1]=Number(val)}get luminosity(){return this.hsl[2]}set luminosity(val){this._sync({hsl:!0}),this._hsl[2]=Number(val)}get red(){return this.rgb[0]}get red255(){return this.rgb[0]*255}set red(val){this._sync({rgb:!0}),this._rgb[0]=Number(val)}set red255(val){this.red=Number(val)/255}get green(){return this.rgb[1]}get green255(){return this.rgb[1]*255}set green(val){this._sync({rgb:!0}),this._rgb[1]=Number(val)}set green255(val){this.green=Number(val)/255}get blue(){return this.rgb[2]}get blue255(){return this.rgb[2]*255}set blue(val){this._sync({rgb:!0}),this._rgb[2]=Number(val)}set blue255(val){this.blue=Number(val)/255}static anyToArray(val,legacy=!1){if(Array.isArray(val)){let checks=[val$1=>val$1 instanceof Paint,val$1=>typeof val$1==`object`&&Array.isArray(val$1.baseColor),val$1=>typeof val$1==`string`&&val$1.split(` `).length>=7,val$1=>Array.isArray(val$1)&&val$1.length>=7];if(val.some(item=>checks.some(check=>check(item))))return val.map(item=>Paint.anyToArray(item,legacy))}let precision=val$1=>{let num=Number(val$1);return isNaN(num)?val$1:~~(num*1e4)/1e4};return Array.isArray(val)?val.map(precision):typeof val==`string`?val.split(` `).map(precision):val instanceof Paint?val.paint:typeof val==`object`&&val.baseColor?[...legacy?val.baseColor:val.baseColor.slice(0,3),val.metallic,val.roughness,val.clearcoat,val.clearcoatRoughness].map(precision):val}static hslCssStr(arr){return`${Math.round(arr[0]*360)}, ${Math.round(arr[1]*100)}%, ${Math.round(arr[2]*100)}%`}static rgbToHsl(rgb){return RGBToHSL(...rgb)}static hslToRgb(hsl){return HSLToRGB(...hsl)}},CACHE_LIMIT=200,TILE_SIZE=64,MULTI_ANGLE=23,MAX_CONCURRENT_RENDERS=20,QUEUE_INTERVAL=10,reflectionImageUrl=`/ui/ui-vue/src/assets/images/paint-reflection.jpg`,reflectionImage=null,reflectionImageDone=!1,renderCancelledError=Error(`Render cancelled`),cacheCleanedError=Error(`Cache cleared`);function hashPaintData(paintData){return paintData?(paintData=Paint.anyToArray(paintData,!1),Array.isArray(paintData)?Array.isArray(paintData[0])?paintData.map(paint=>Array.isArray(paint)?paint.join(`,`):``).join(`|`):paintData.join(`,`):JSON.stringify(paintData)):``}var checkMultipaint=paintData=>Array.isArray(paintData)&&paintData.length>0&&paintData.some(item=>Array.isArray(item)&&item.length>=7);const usePaintPreviews=defineStore(`paint-previews`,()=>{let previews=ref(new Map),pendingRenders=ref(new Map),renderQueue=ref([]),activeRenders=ref(0),cacheListeners=new Set,pendingBlobCleanup=new Set,queueProcessor=null,blobCleanupTimeout=null;{let img=new Image;img.onload=()=>{reflectionImage=img,reflectionImageDone=!0},img.onerror=()=>{console.warn(`Failed to load metallic reflection image`),reflectionImageDone=!0},img.src=reflectionImageUrl}function startQueue(eager=!1){if(queueProcessor||renderQueue.value.length===0)return;let run$1=()=>{renderQueue.value.length===0?stopQueue():activeRenders.value0||activeRenders.value>0)return!1;for(let entry of previews.value.values())if(entry.blobGenerating)return!1;return!0}function blobCleanup(){blobCleanupTimeout&&clearTimeout(blobCleanupTimeout),blobCleanupTimeout=setTimeout(()=>{if(blobCleanupTimeout=null,isSystemIdle()&&pendingBlobCleanup.size>0){for(let blobUrl of pendingBlobCleanup)URL.revokeObjectURL(blobUrl);pendingBlobCleanup.clear()}},1e3)}async function processQueue({key,paintData,opts,resolve:resolve$1,reject,aborter}){activeRenders.value++;try{let checkAborted=()=>{if(aborter.signal.aborted)throw renderCancelledError};checkAborted();let width$1=opts.width||TILE_SIZE,height$1=opts.height||TILE_SIZE,areas=calculatePaintAreas(paintData,width$1,height$1),cvs=await renderPaint(paintData,width$1,height$1,opts.radialLight||!1,areas,aborter);checkAborted();let bmp=await createImageBitmap(cvs);if(previews.value.size>=CACHE_LIMIT){let oldestKey=previews.value.keys().next().value;cleanupCacheEntry(previews.value.get(oldestKey)),previews.value.delete(oldestKey)}checkAborted(),previews.value.set(key,{bitmap:bmp,paintData,paintHash:hashPaintData(paintData),areas}),resolve$1(bmp)}catch(err){err!==renderCancelledError&&reject(err)}finally{pendingRenders.value.has(key)&&pendingRenders.value.get(key).aborter===aborter&&pendingRenders.value.delete(key),activeRenders.value--}}function getCacheKey({paintId,vehicleName,paintName,width:width$1=TILE_SIZE,height:height$1=TILE_SIZE,radialLight=!1}){if(paintId)return`paint#${paintId}@${width$1}x${height$1}${radialLight?`R`:`L`}`;if(vehicleName&&paintName)return`vehicle:${vehicleName}:${paintName}@${width$1}x${height$1}${radialLight?`R`:`L`}`;throw Error(`Either paintId or vehicleName+paintName must be provided`)}function isCached(opts,paintData){try{let key=getCacheKey(opts),data=previews.value.get(key);return data?!paintData||data.paintHash===hashPaintData(paintData):!1}catch{return!1}}function getCachedPreview(opts,paintData){try{let key=getCacheKey(opts),data=previews.value.get(key);return data?data.paintHash===hashPaintData(paintData)?data.bitmap:(cleanupCacheEntry(data),previews.value.delete(key),null):null}catch{return null}}async function generatePreview(paintData,opts){let key=getCacheKey(opts),paintHash=hashPaintData(paintData);if(pendingRenders.value.has(key)){let existing=pendingRenders.value.get(key);if(existing.paintHash===paintHash)return new Promise((resolve$1,reject)=>existing.others.push({resolve:resolve$1,reject}));{existing.aborter.abort(),renderQueue.value=renderQueue.value.filter(item=>!(item.key===key&&item.aborter===existing.aborter));let aborter$1=new AbortController,others$1=[...existing.others];return pendingRenders.value.set(key,{paintHash,others:others$1,aborter:aborter$1}),new Promise((resolve$1,reject)=>{others$1.push({resolve:resolve$1,reject}),renderQueue.value.unshift({key,paintData:Paint.anyToArray(paintData),opts,resolve:result=>others$1.forEach(p$1=>p$1.resolve(result)),reject:error=>others$1.forEach(p$1=>p$1.reject(error)),aborter:aborter$1}),startQueue(!0)})}}let aborter=new AbortController,others=[];return pendingRenders.value.set(key,{paintHash,others,aborter}),new Promise((resolve$1,reject)=>{others.push({resolve:resolve$1,reject}),renderQueue.value.push({key,paintData:Paint.anyToArray(paintData),opts,resolve:result=>{others.forEach(p$1=>p$1.resolve(result))},reject:error=>{others.forEach(p$1=>p$1.reject(error))},aborter}),startQueue()})}function cleanupCacheEntry(data){data&&(data.bitmap?.close?.(),data.blobUrl&&pendingBlobCleanup.add(data.blobUrl))}function onCacheClear(callback){return cacheListeners.add(callback),()=>cacheListeners.delete(callback)}function notifyCacheCleared(type=`all`,key=null){cacheListeners.forEach(callback=>{try{callback(type,key)}catch(error){console.warn(`Cache clear listener error:`,error)}})}function clearCache(opts=void 0){if(opts)try{let key=getCacheKey(opts);if(cleanupCacheEntry(previews.value.get(key)),previews.value.delete(key),pendingRenders.value.has(key)){let req=pendingRenders.value.get(key);req.aborter.abort(),req.others.forEach(p$1=>p$1.reject(cacheCleanedError)),pendingRenders.value.delete(key)}notifyCacheCleared(`single`,key)}catch{}else stopQueue(),pendingRenders.value.forEach(req=>{req.aborter.abort(),req.others.forEach(p$1=>p$1.reject(cacheCleanedError))}),pendingRenders.value.clear(),previews.value.forEach(cleanupCacheEntry),previews.value.clear(),renderQueue.value.splice(0),activeRenders.value=0,notifyCacheCleared(`all`),startQueue();blobCleanup()}async function getPreview(paintData,opts){return getCachedPreview(opts,paintData)||await generatePreview(paintData,opts)}async function getBlobPreview(paintData,opts){let paintHash=hashPaintData(paintData),key=getCacheKey(opts),bmp=await getPreview(paintData,opts),data=previews.value.get(key);if(!data)return null;if(data.blobUrl&&data.paintHash===paintHash)return data.blobUrl;for(;data.blobGenerating;)await sleep(10);if(data.blobUrl&&data.paintHash===paintHash)return data.blobUrl;data.blobGenerating=!0;let canvas=new OffscreenCanvas(opts.width||TILE_SIZE,opts.height||TILE_SIZE);canvas.getContext(`2d`).drawImage(bmp,0,0);let blobUrl=URL.createObjectURL(await canvas.convertToBlob()),oldBlobUrl=data.blobUrl;return data.blobUrl=blobUrl,delete data.blobGenerating,oldBlobUrl&&pendingBlobCleanup.add(oldBlobUrl),previews.value.has(key)?(blobCleanup(),blobUrl):(pendingBlobCleanup.add(blobUrl),blobCleanup(),null)}function getAreas(opts){let data=previews.value.get(getCacheKey(opts));return data?data.areas:[]}return{cache:previews.value,cacheSize:computed(()=>previews.value.size),isRenderingAny:computed(()=>activeRenders.value>0||renderQueue.value.length>0),queueLength:computed(()=>renderQueue.value.length),activeRenders,isCached,clearCache,onCacheClear,getCacheKey,getPreview,getBlobPreview,getAreas,checkMultipaint,toArray:Paint.anyToArray}});async function renderPaint(paintData,width$1=TILE_SIZE,height$1=TILE_SIZE,radialLight=!1,areas=null,aborter=null){if(paintData=Paint.anyToArray(paintData),!paintData)return renderEmpty(width$1,height$1,aborter);if(checkMultipaint(paintData)){let clipData=areas||calculatePaintAreas(paintData,width$1,height$1);return renderMultipaint(paintData,width$1,height$1,clipData,radialLight,aborter)}else return paintData=Array.isArray(paintData[0])?paintData[0]:paintData,renderSinglePaint(paintData,width$1,height$1,radialLight,aborter)}function createPaint(paintData){let paint={_isEmpty:!0};if(!paintData)return paint;try{paint=new Paint({paint:paintData})}catch{}return paint}function applyAntialiasing(ctx){ctx.imageSmoothingEnabled=!0,ctx.imageSmoothingQuality=`high`,ctx.antialias=!0}function calculatePaintAreas(paintData,width$1,height$1){if(!paintData||!checkMultipaint(paintData))return[[0,0,width$1,height$1]];let paintCount=paintData.length,angle=Math.tan(MULTI_ANGLE*Math.PI/180),stripeWidth=(width$1+height$1*angle)/paintCount,overlap=.5,areas=[];for(let i=0;i0?overlap:0),topRight=startX+stripeWidth+(icoords.map((coord,i)=>coord*(i%2==0?scaleX:scaleY)));for(let i=0;igrad.addColorStop(...args))}else grad=ctx.createLinearGradient(0,0,0,height$1*.65),gradStops.forEach(args=>grad.addColorStop(...args));ctx.fillStyle=grad,ctx.fillRect(0,0,width$1,height$1),ctx.restore()}async function renderPaintLayers(ctx,paint,width$1,height$1,radialLight=!1,aborter=null){if(applyAntialiasing(ctx),ctx.fillStyle=`rgb(${(paint.rgb255||[255,255,255]).join(`, `)})`,ctx.fillRect(0,0,width$1,height$1),aborter?.signal.aborted)return;let grad=ctx.createLinearGradient(0,0,0,height$1);if(grad.addColorStop(0,`rgba(0, 0, 0, 0)`),grad.addColorStop(.65,`rgba(0, 0, 0, 0)`),grad.addColorStop(.8,`rgba(0, 0, 0, 0.15)`),grad.addColorStop(1,`rgba(0, 0, 0, 0.55)`),ctx.fillStyle=grad,ctx.fillRect(0,0,width$1,height$1),aborter?.signal.aborted)return;let metallic=Math.max(0,paint.metallic-paint.roughness/.5);if(metallic>.01){for(;!reflectionImageDone;){if(aborter?.signal.aborted)return;await sleep(10)}if(aborter?.signal.aborted)return;if(ctx.globalCompositeOperation=`multiply`,ctx.globalAlpha=metallic,reflectionImage){let scale=1,imageAspect=reflectionImage.width/reflectionImage.height,canvasAspect=width$1/height$1,drawWidth,drawHeight,offsetX=0,offsetY=0;imageAspect>canvasAspect?(drawHeight=height$1*1,drawWidth=height$1*imageAspect*1):(drawHeight=width$1/imageAspect*1,drawWidth=width$1*1),ctx.drawImage(reflectionImage,0,0,drawWidth,drawHeight)}else{ctx.strokeStyle=`rgba(255, 255, 255, 0.5)`,ctx.lineWidth=1;for(let x=-height$1;x({v889f200a:tileWidth.value,bee2d4dc:tileHeight.value}));let popover=usePopover(),props=__props,emit$1=__emit,mapId=uniqueId(`paint-tile-map`),menuId=uniqueId(`paint-tile-menu`),popMenu=ref(null),elCont=ref(null),elCanvas=ref(null),isLoading=ref(!1),isEmpty=ref(!1),hasRenderedOnce=ref(!1),paintPreviews=usePaintPreviews(),width$1=computed(()=>props.size||props.width),height$1=computed(()=>props.size||props.height),tileWidth=computed(()=>`${width$1.value}px`),tileHeight=computed(()=>`${height$1.value}px`),paints=computed(()=>props.paint?paintPreviews.toArray(props.paint):[]),isMultipaint=computed(()=>paintPreviews.checkMultipaint(paints.value)),paintNames=computed(()=>{let len=props.paint?.length||0;if(len===0)return[];let res=Array.from({length:len}).map((_,idx)=>({tooltip:[`ui.color.paint.unnamed`,{index:idx+1}],menu:[`ui.color.paint.selectOne`,{index:idx+1}],menuAdd:null}));if(props.paintNames?.length>0)for(let i=0;ihoveredPaintIndex.value=idx,tooltip=computed(()=>{let res={name:props.tooltip||props.paintName};return hoveredPaintIndex.value>-1&&paintNames.value[hoveredPaintIndex.value]&&(res.subname=paintNames.value[hoveredPaintIndex.value].tooltip),res}),customMenu=computed(()=>!props.customMenu||props.customMenu.length===0?null:props.customMenu.reduce((res,item,idx)=>item?[...res,{label:item.label||item,click:evt=>{popMenu.value?.hide?.(),nextTick(()=>{item.action?item.action(props.paint,evt):emit$1(`menu-click`,item.value||idx,props.paint,evt)})}}]:res,[])),withMenu=computed(()=>props.withMenu&&(paintAreas.value.length>1||customMenu.value)),opts=computed(()=>({paintId:props.paintId,vehicleName:props.vehicleName,paintName:props.paintName,width:width$1.value,height:height$1.value,radialLight:props.radialLight})),cacheKey=computed(()=>{try{return paintPreviews.getCacheKey(opts.value)}catch{return null}}),paintAreas=computed(()=>{if(!props.paint||isEmpty.value)return[];try{return paintPreviews.getAreas(opts.value)}catch{return[]}}),onContClick=evt=>onClick(-1,evt),onContRMB=()=>withMenu.value&&openMenu();function onClick(idx,evt){popMenu.value?.hide?.(),!props.disabled&&emit$1(`click`,idx,props.paint,evt)}function openMenu(){!elCont.value||!popMenu.value||(popover.hideAll(`paint-tile-menu`),!props.disabled&&popMenu.value.show(elCont.value))}async function renderPreview(){if(!cacheKey.value||!props.paint){isEmpty.value=!0,hasRenderedOnce.value=!1;return}isLoading.value=!0,isEmpty.value=!1;try{let bmp=await paintPreviews.getPreview(paints.value,opts.value);if(elCanvas.value&&bmp){let ctx=elCanvas.value.getContext(`2d`);ctx.clearRect(0,0,width$1.value,height$1.value),ctx.drawImage(bmp,0,0,width$1.value,height$1.value),hasRenderedOnce.value=!0}}catch(error){console.error(`Failed to render preview`,error),isEmpty.value=!0,hasRenderedOnce.value=!1}finally{isLoading.value=!1}}function checkEmpty(){if(!props.paint)return isEmpty.value=!0,hasRenderedOnce.value=!1,!0;if(isMultipaint.value){let allEmpty=paints.value.every(paintArray=>!paintArray||paintArray.length===0);return isEmpty.value=allEmpty,allEmpty&&(hasRenderedOnce.value=!1),allEmpty}return Array.isArray(paints.value)&&paints.value.length===0?(isEmpty.value=!0,hasRenderedOnce.value=!1,!0):(isEmpty.value=!1,!1)}watch(()=>[paints.value,props.paintId,props.vehicleName,props.paintName,width$1.value,height$1.value,props.radialLight],()=>{checkEmpty()?isLoading.value=!1:renderPreview()},{immediate:!0,deep:!0}),watch(()=>props.withAreas,val=>{val||(hoveredPaintIndex.value=-1)});let unsubscribeFromCacheClear=null,outEvents=[`click`,`contextmenu`,`uinav-focus`],listeningOutEvents=!1;function outOfMenu(evt){if(!popMenu.value||!popMenu.value.isShown())return;let el=popMenu.value.getElement();el&&el.contains(evt.detail?.target||evt.target)||nextTick(()=>popMenu.value.hide?.())}return watch(()=>popover.popovers[menuId]?.show,val=>{val?listeningOutEvents||(listeningOutEvents=!0,outEvents.forEach(evt=>document.addEventListener(evt,outOfMenu))):listeningOutEvents&&(listeningOutEvents=!1,outEvents.forEach(evt=>document.removeEventListener(evt,outOfMenu)))}),onMounted(()=>{!checkEmpty()&&renderPreview(),unsubscribeFromCacheClear=paintPreviews.onCacheClear((type,key)=>{(type===`all`||type===`single`&&key===cacheKey.value)&&!checkEmpty()&&hasRenderedOnce.value&&renderPreview()})}),onUnmounted(()=>{unsubscribeFromCacheClear?.(),listeningOutEvents&&outEvents.forEach(evt=>document.removeEventListener(evt,outOfMenu))}),(_ctx,_cache)=>withDirectives((openBlock(),createElementBlock(`div`,{ref_key:`elCont`,ref:elCont,class:normalizeClass([`bng-paint-tile`,{loading:isLoading.value&&!hasRenderedOnce.value,empty:isEmpty.value}]),tabindex:`0`,"bng-nav-item":``,onClick:withModifiers(onContClick,[`stop`]),onContextmenu:withModifiers(onContRMB,[`stop`])},[createBaseVNode(`canvas`,{ref_key:`elCanvas`,ref:elCanvas,width:width$1.value,height:height$1.value},null,8,_hoisted_1$311),__props.withAreas&&paintAreas.value.length>1?(openBlock(),createElementBlock(Fragment,{key:0},[createBaseVNode(`img`,{usemap:`#${unref(mapId)}`,src:unref(emptyImage),alt:``},null,8,_hoisted_2$254),createBaseVNode(`map`,{name:unref(mapId)},[(openBlock(!0),createElementBlock(Fragment,null,renderList(paintAreas.value,(area,index)=>(openBlock(),createElementBlock(`area`,{key:index,shape:`poly`,coords:area.join(`,`),onMouseover:$event=>onMouseOver(index),onMouseleave:_cache[0]||=$event=>onMouseOver(-1),onClick:withModifiers($event=>onClick(index,$event),[`stop`])},null,40,_hoisted_4$190))),128))],8,_hoisted_3$222)],64)):createCommentVNode(``,!0),isEmpty.value||isLoading.value&&!hasRenderedOnce.value?(openBlock(),createElementBlock(`div`,_hoisted_5$162)):createCommentVNode(``,!0),withMenu.value?(openBlock(),createBlock(unref(bngPopoverMenu_default),{key:2,ref_key:`popMenu`,ref:popMenu,name:unref(menuId),focus:``},{default:withCtx(()=>[paintNames.value.length>1?(openBlock(),createElementBlock(Fragment,{key:0},[withDirectives((openBlock(),createBlock(unref(bngButton_default),{accent:unref(ACCENTS).menu,onClick:_cache[1]||=$event=>onClick(-1,$event)},{default:withCtx(()=>[createTextVNode(toDisplayString(_ctx.$tt(`ui.color.paint.selectAll`)),1)]),_:1},8,[`accent`])),[[unref(BngOnUiNav_default),void 0,`ok`,{focusRequired:!0,asMouse:!0}]]),(openBlock(!0),createElementBlock(Fragment,null,renderList(paintNames.value,(paint,index)=>withDirectives((openBlock(),createBlock(unref(bngButton_default),{key:index,accent:unref(ACCENTS).menu,onClick:$event=>onClick(index,$event)},{default:withCtx(()=>[createTextVNode(toDisplayString(_ctx.$tt(...paintNames.value[index].menu))+toDisplayString(paintNames.value[index].menuAdd?`: `+paintNames.value[index].menuAdd:``),1)]),_:2},1032,[`accent`,`onClick`])),[[unref(BngOnUiNav_default),void 0,`ok`,{focusRequired:!0,asMouse:!0}]])),128))],64)):withDirectives((openBlock(),createBlock(unref(bngButton_default),{key:1,accent:unref(ACCENTS).menu,onClick:_cache[2]||=$event=>onClick(0,$event)},{default:withCtx(()=>[createTextVNode(toDisplayString(_ctx.$tt(`ui.color.paint.select`)),1)]),_:1},8,[`accent`])),[[unref(BngOnUiNav_default),void 0,`ok`,{focusRequired:!0,asMouse:!0}]]),customMenu.value?.length>0?(openBlock(!0),createElementBlock(Fragment,{key:2},renderList(customMenu.value,(item,index)=>withDirectives((openBlock(),createBlock(unref(bngButton_default),{key:index,accent:unref(ACCENTS).menu,onClick:$event=>item.click($event)},{default:withCtx(()=>[createTextVNode(toDisplayString(_ctx.$tt(item.label)),1)]),_:2},1032,[`accent`,`onClick`])),[[unref(BngOnUiNav_default),void 0,`ok`,{focusRequired:!0,asMouse:!0}]])),128)):createCommentVNode(``,!0)]),_:1},8,[`name`])):createCommentVNode(``,!0)],34)),[[unref(BngTooltip_default),_ctx.$tt(tooltip.value.name)+(tooltip.value.subname?` - `+_ctx.$tt(...tooltip.value.subname):``),__props.tooltipPosition],[unref(BngOnUiNav_default),void 0,`ok`,{asMouse:!0,focusRequired:!0}]])}},bngPaintTile_default=__plugin_vue_export_helper_default(_sfc_main$356,[[`__scopeId`,`data-v-25bf2552`]]),_hoisted_1$310=[`tabindex`],_sfc_main$355={__name:`bngPill`,props:{marked:{type:Boolean,default:!1}},setup(__props){let props=__props,attrs=useAttrs(),hasClickEvent=computed(()=>attrs&&attrs.onClick),isMarked=ref(props.marked);return watch(()=>props.marked,newValue=>isMarked.value=newValue),(_ctx,_cache)=>(openBlock(),createElementBlock(`span`,{"bng-nav-item":``,class:normalizeClass([`bng-pill`,{"pill-marked":isMarked.value,"pill-clickable":hasClickEvent.value}]),tabindex:hasClickEvent.value?0:-1},[renderSlot(_ctx.$slots,`default`,{},void 0,!0)],10,_hoisted_1$310))}},bngPill_default=__plugin_vue_export_helper_default(_sfc_main$355,[[`__scopeId`,`data-v-2d28d1ed`]]),_sfc_main$354={__name:`bngPillCheckbox`,props:{modelValue:{type:Boolean,default:null},markedIcon:{type:[Boolean,Object],default:!0}},emits:[`update:modelValue`,`valueChanged`,`change`],setup(__props,{emit:__emit}){let props=__props,emit$1=__emit,defaultValue=ref(!1),isChecked=computed({get:()=>props.modelValue!==void 0&&props.modelValue!==null?props.modelValue:defaultValue.value,set:newValue=>{props.modelValue!==void 0&&props.modelValue!==null?notifyListeners(newValue):(defaultValue.value=newValue,emit$1(`valueChanged`,newValue),emit$1(`change`,newValue))}}),onChecked=()=>isChecked.value=!isChecked.value;function notifyListeners(value){emit$1(`update:modelValue`,value),emit$1(`change`,value),emit$1(`valueChanged`,value)}return(_ctx,_cache)=>(openBlock(),createElementBlock(`span`,{class:normalizeClass([`bng-pill-checkbox`,{"show-icon":isChecked.value&&props.markedIcon}])},[createVNode(unref(bngPill_default),{marked:isChecked.value,onClick:onChecked,onKeyup:withKeys(onChecked,[`space`])},{default:withCtx(()=>[createBaseVNode(`span`,{class:normalizeClass({"pill-content":!0,"uses-mark":__props.markedIcon})},[renderSlot(_ctx.$slots,`default`,{},void 0,!0)],2),createVNode(unref(bngIcon_default),{class:`pill-mark-icon`,type:props.markedIcon===!0?unref(icons).checkmark:props.markedIcon||unref(icons).checkmark},null,8,[`type`])]),_:3},8,[`marked`])],2))}},bngPillCheckbox_default=__plugin_vue_export_helper_default(_sfc_main$354,[[`__scopeId`,`data-v-04487830`]]),_hoisted_1$309={class:`bng-pill-filters`,tabindex:`0`},_sfc_main$353={__name:`bngPillFilters`,props:{modelValue:Array,options:{type:Array,required:!0},selectOnFocus:Boolean,selectMany:Boolean,showCheckIcon:{type:Boolean,default:!0},required:Boolean},emits:[`update:modelValue`,`valueChanged`],setup(__props,{expose:__expose,emit:__emit}){let props=__props,emit$1=__emit;__expose({focusPrevious,focusNext,toggleFocusedPill,focusIndex});let scrollable=ref(null),pills=ref([]),currentPillIndex=ref(-1),defaultSelected=ref([]),selectedValues=computed({get:()=>props.modelValue?props.modelValue:defaultSelected.value,set:newValue=>{props.modelValue?(emit$1(`update:modelValue`,newValue),emit$1(`valueChanged`,newValue)):(defaultSelected.value=newValue,emit$1(`valueChanged`,newValue))}}),pillConfigs=computed(()=>toRaw(props.options).map(x=>({...x,selected:selectedValues.value&&selectedValues.value.length>0&&selectedValues.value.includes(x.value)})));function focusPrevious(){currentPillIndex.value=currentPillIndex.value>0?currentPillIndex.value-1:0,pills.value[currentPillIndex.value].querySelector(`.bng-pill`).focus(),console.log(`currentPillIndex.value`,currentPillIndex.value)}function focusNext(){currentPillIndex.value{scrollable.value.addEventListener(`wheel`,evt=>{evt.preventDefault(),scrollable.value.scrollLeft+=evt.deltaY}),currentPillIndex.value=selectedValues.value.length>0?pillConfigs.value.findIndex(x=>x.value===selectedValues.value[0]):-1,currentPillIndex.value>-1&&focusPill(currentPillIndex.value)});let onPillValueChanged=(key,value)=>{props.selectOnFocus||(console.log(`onPillValueChanged`,key,value),setPillValue(key,value))},onPillFocusIn=(key,index)=>{focusPill(index),props.selectOnFocus&&setPillValue(key,!(selectedValues.value.length>0&&selectedValues.value.includes(key)))};function setPillValue(key,checked){if(currentPillIndex.value=pillConfigs.value.findIndex(x=>x.value===key),props.required&&!checked&&selectedValues.value.includes(key)&&selectedValues.value.length==1){selectedValues.value=[key];return}if(!props.selectMany){selectedValues.value=checked?[key]:[];return}let isExisting=selectedValues.value.includes(key);checked&&!isExisting?selectedValues.value=[...selectedValues.value,key]:!checked&&isExisting&&(selectedValues.value=selectedValues.value.filter(x=>x!==key))}function focusPill(index){let pillEl=pills.value[index],scrollableRect=scrollable.value.getBoundingClientRect(),pillRect=pillEl.getBoundingClientRect();pillRect.left>=scrollableRect.left&&pillRect.right<=scrollableRect.right||window.requestAnimationFrame(()=>{scrollable.value.scrollBy({left:pillEl.getBoundingClientRect().right})})}return(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$309,[createBaseVNode(`div`,{class:`pills-wrapper`,ref_key:`scrollable`,ref:scrollable},[(openBlock(!0),createElementBlock(Fragment,null,renderList(pillConfigs.value,(pill,index)=>(openBlock(),createElementBlock(`div`,{key:pill.value,ref_for:!0,ref_key:`pills`,ref:pills,class:`pill-wrapper`},[createVNode(unref(bngPillCheckbox_default),{markedIcon:__props.showCheckIcon,modelValue:pill.selected,"onUpdate:modelValue":$event=>pill.selected=$event,onValueChanged:value=>onPillValueChanged(pill.value,value),onFocusin:$event=>onPillFocusIn(pill.value,index)},{default:withCtx(()=>[createTextVNode(toDisplayString(pill.label),1)]),_:2},1032,[`markedIcon`,`modelValue`,`onUpdate:modelValue`,`onValueChanged`,`onFocusin`])]))),128))],512)]))}},bngPillFilters_default=__plugin_vue_export_helper_default(_sfc_main$353,[[`__scopeId`,`data-v-580a9eac`]]),_sfc_main$352={__name:`bngPillFiltersContainer`,props:{options:{type:Array,required:!0},selectOnNavigation:{type:Boolean,default:!0},required:Boolean,selectMany:Boolean,hasCheckedIcon:{default:!0,type:Boolean}},emits:[`update:modelValue`,`valueChanged`],setup(__props,{expose:__expose,emit:__emit}){let emit$1=__emit,props=__props,selectedItems=ref([]),bngFiltersContainer=ref(null),filtersContainer=ref(null),bngPillFiltersRef=ref(null);__expose({selectPrevious:()=>bngPillFiltersRef.value.selectPrevious(),selectNext:()=>bngPillFiltersRef.value.selectNext(),selectCurrent:()=>bngPillFiltersRef.value.selectCurrent(),focusAndScrollToSelected:focusSelected});let selectedItemId=``;onMounted(()=>{filtersContainer.value.addEventListener(`wheel`,evt=>{evt.preventDefault(),filtersContainer.value.scrollLeft+=evt.deltaY})});function focusSelected(){props.selectMany||!props.selectOnNavigation||scrollToElement(selectedItemId)}function onContainerFocusOut($event){!($event.relatedTarget&&bngFiltersContainer.value.contains($event.relatedTarget))&&!props.selectMany&&selectedItemId&&scrollToElement(selectedItemId)}function onValueChanged(items$2,id){selectedItems.value=items$2,selectedItemId=id,emit$1(`valueChanged`,items$2,id)}function onPillItemFocusIn(id){scrollToElement(id)}function scrollToElement(id){let scrollableContainer=filtersContainer.value,el=scrollableContainer.querySelector(`#${id}`);if(el){let scrollableContainerRect=scrollableContainer.getBoundingClientRect(),itemRect=el.getBoundingClientRect();if(itemRect.left>=scrollableContainerRect.left&&itemRect.right<=scrollableContainerRect.right)return;window.requestAnimationFrame(()=>{let scrollValue=itemRect.left(openBlock(),createElementBlock(`div`,{class:`bng-filters-container`,ref_key:`bngFiltersContainer`,ref:bngFiltersContainer,tabindex:`0`,onFocusout:onContainerFocusOut},[_cache[0]||=createBaseVNode(`div`,{class:`fade-effect left-fade-effect`},null,-1),_cache[1]||=createBaseVNode(`div`,{class:`fade-effect right-fade-effect`},null,-1),createBaseVNode(`div`,{class:`scroll-container`,ref_key:`filtersContainer`,ref:filtersContainer},[createVNode(unref(bngPillFilters_default),{ref_key:`bngPillFiltersRef`,ref:bngPillFiltersRef,options:__props.options,"select-on-navigation":__props.selectOnNavigation,required:__props.required,"select-many":__props.selectMany,"show-checked-icon":__props.hasCheckedIcon,onValueChanged,onPillItemFocusIn},null,8,[`options`,`select-on-navigation`,`required`,`select-many`,`show-checked-icon`])],512)],544))}},bngPillFiltersContainer_default=__plugin_vue_export_helper_default(_sfc_main$352,[[`__scopeId`,`data-v-498af92b`]]),_hoisted_1$308=[`data-bng-popover-name`],containerSelector=`.popover-container`,_sfc_main$351={__name:`bngPopoverContent`,props:{name:String,offset:{type:Number,default:4},hideArrow:Boolean,placement:String,disabled:Boolean},emits:[`show`,`hide`,`placementChanged`],setup(__props,{expose:__expose,emit:__emit}){let props=__props,emit$1=__emit,popover=usePopover(),popoverName,popoverContent=ref(null),arrow$3=ref(null),show=ref(!1),unwatchShow,unwatchPlacement,teleportTargetExists=ref(!1),observer$2=null,scopeActivated=ref(!1),isRender=computed(()=>!props.disabled&&teleportTargetExists.value&&show.value),hide$2=()=>!props.disabled&&popover.hide(popoverName),expose={hide:hide$2,show:(el=void 0)=>!props.disabled&&popover.show(popoverName,el),toggle:(forceVal=void 0)=>popover.toggle(popoverName,!props.disabled&&forceVal),isShown:()=>popover.isShown(popoverName)};__expose(expose),watch(()=>show.value,value=>emit$1(value?`show`:`hide`,{name:props.name,...expose})),watch(()=>props.name,(newName,oldName)=>{oldName&&disposePopover(oldName),props.disabled||setupPopover()},{immediate:!0}),watch(()=>props.disabled,value=>{value?(popover.hide(popoverName),disposePopover(popoverName)):setupPopover()}),watch(isRender,async value=>{value&&(await nextTick(),checkSlotContent())});let onMenu=()=>{scopeActivated.value=!1};onBeforeUnmount(()=>{disposePopover(popoverName),observer$2&&=(observer$2.disconnect(),null)}),onMounted(async()=>{teleportTargetExists.value=!!document.querySelector(containerSelector),teleportTargetExists.value||(observer$2=new MutationObserver(()=>{!teleportTargetExists.value&&document.querySelector(containerSelector)&&(teleportTargetExists.value=!0,observer$2.disconnect(),observer$2=null)}),observer$2.observe(document.body,{childList:!0,subtree:!0})),isRender.value&&(await nextTick(),checkSlotContent())});function onScopeChanged(activated,event){scopeActivated.value=activated,!activated&&!event.detail.force&&popover.hide(popoverName)}function checkSlotContent(){let navigableElements=popoverContent.value.querySelectorAll(NAVIGABLE_ELEMENTS_SELECTOR);navigableElements&&navigableElements.length>0&&!scopeActivated.value&&(scopeActivated.value=!0)}function setupPopover(){popoverName=props.name||uniqueId(`bng-popover-content`);let res=popover.register(popoverName,popoverContent,props.placement,{arrow:props.hideArrow?void 0:arrow$3,offset:props.offset});res&&(unwatchShow=watch(res.show,value=>show.value=value),unwatchPlacement=watch(res.placement,placement=>emit$1(`placementChanged`,placement)))}function disposePopover(name){unwatchShow&&=(unwatchShow(),null),unwatchPlacement&&=(unwatchPlacement(),null),popover.unregister(name),show.value=!1,popoverName=null}return(_ctx,_cache)=>isRender.value?(openBlock(),createBlock(Teleport,{key:0,to:`.popover-container`},[withDirectives((openBlock(),createElementBlock(`div`,{ref_key:`popoverContent`,ref:popoverContent,"data-bng-popover-name":unref(popoverName),class:`bng-popover`,onActivate:_cache[0]||=$event=>onScopeChanged(!0,$event),onDeactivate:_cache[1]||=$event=>onScopeChanged(!1,$event)},[renderSlot(_ctx.$slots,`default`,{hide:hide$2},void 0,!0),__props.hideArrow?createCommentVNode(``,!0):(openBlock(),createElementBlock(`span`,{key:0,ref_key:`arrow`,ref:arrow$3,class:`bng-popover-arrow`},null,512))],40,_hoisted_1$308)),[[unref(BngScopedNav_default),{activated:scopeActivated.value,type:unref(SCOPED_NAV_TYPES).popover}],[unref(BngOnUiNav_default),onMenu,`menu`]])])):createCommentVNode(``,!0)}},bngPopoverContent_default=__plugin_vue_export_helper_default(_sfc_main$351,[[`__scopeId`,`data-v-4938e558`]]),_sfc_main$350=Object.assign({inheritAttrs:!1},{__name:`bngPopoverMenu`,props:{name:String,offset:{type:Number,default:4},hideArrow:Boolean,disabled:Boolean,focus:Boolean},emits:[`show`,`hide`,`placementChanged`],setup(__props,{expose:__expose,emit:__emit}){let popover=usePopover(),props=__props,emit$1=__emit,relay={show:(...args)=>emit$1(`show`,...args),hide:(...args)=>emit$1(`hide`,...args),placementChanged:(...args)=>emit$1(`placementChanged`,...args)},popoverContent=ref(null),popoverMenu=ref(null),hide$2=(...args)=>popoverContent.value.hide(...args);return __expose({hide:hide$2,show:(...args)=>popoverContent.value.show(...args),toggle:(...args)=>popoverContent.value.toggle(...args),isShown:(...args)=>popoverContent.value.isShown(...args),getElement:()=>popoverMenu.value}),watchEffect(()=>{if(props.name in popover.popovers){let pop=popover.popovers[props.name];!pop.show&&nextTick(()=>{pop.target&&document.activeElement===document.body&&setFocusExternal(pop.target,!0,!1)})}}),(_ctx,_cache)=>(openBlock(),createBlock(unref(bngPopoverContent_default),{ref_key:`popoverContent`,ref:popoverContent,name:__props.name,offset:__props.offset,"hide-arrow":__props.hideArrow,disabled:__props.disabled,onPlacementChanged:relay.placementChanged,onHide:hide$2},{default:withCtx(()=>[createBaseVNode(`div`,{ref_key:`popoverMenu`,ref:popoverMenu,class:`bng-popover-menu`},[renderSlot(_ctx.$slots,`default`,{hide:hide$2},void 0,!0)],512)]),_:3},8,[`name`,`offset`,`hide-arrow`,`disabled`,`onPlacementChanged`]))}}),bngPopoverMenu_default=__plugin_vue_export_helper_default(_sfc_main$350,[[`__scopeId`,`data-v-fe39553c`]]),_hoisted_1$307={class:`bng-progress-bar`},_hoisted_2$253={key:0,class:`header`},_hoisted_3$221={class:`header-left`},_hoisted_4$189={class:`header-right`},_hoisted_5$161={class:`progress-bar`},_hoisted_6$139=[`innerHTML`],_hoisted_7$121={key:1,class:`progress-fill-indeterminate`},_sfc_main$349={__name:`bngProgressBar`,props:{value:{type:Number,default:0},oldValue:{type:Number,default:0},min:{type:Number,default:0},max:{type:Number,required:!0},headerLeft:String,headerRight:String,showValueLabel:{type:Boolean,default:!0},valueLabelFormat:{type:[String,Function],default:`#value#`},valueColor:{type:String,default:`#ff6600`},oldValueColor:{type:String,default:`#ffffff`},indeterminate:Boolean,animateDifference:Boolean,gradient:Boolean},setup(__props,{expose:__expose}){useCssVars(_ctx=>({v5113e7b0:__props.valueColor,v14406f01:progressFillUnits.value,v6b373656:oldProgressFillUnits.value}));let props=__props;__expose({decreaseValueBy,increaseValueBy,setValue:value=>updateCurrentValue(value)});let currentValue=ref(null),valueHTML=computed(()=>{let res;return res=typeof props.valueLabelFormat==`function`?props.valueLabelFormat(props.value,{min:props.min,max:props.max}):props.valueLabelFormat.replace(/ +/g,` `).replace(`#value#`,`${currentValue.value}${props.max}`),res}),progressFillUnits=computed(()=>1-(currentValue.value-props.min)/(props.max-props.min)),oldProgressFillUnits=computed(()=>1-(props.oldValue-props.min)/(props.max-props.min));watch(()=>props.value,updateCurrentValue),onMounted(()=>{updateCurrentValue(props.min>props.value?props.min:props.value)});function decreaseValueBy(value){let newValue=currentValue.value-value;newValueprops.max&&(newValue=props.max),updateCurrentValue(newValue)}function updateCurrentValue(newValue){currentValue.value=newValue}return(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$307,[__props.headerLeft||__props.headerRight?(openBlock(),createElementBlock(`div`,_hoisted_2$253,[createBaseVNode(`span`,_hoisted_3$221,toDisplayString(__props.headerLeft),1),createBaseVNode(`span`,_hoisted_4$189,toDisplayString(__props.headerRight),1)])):createCommentVNode(``,!0),createBaseVNode(`div`,_hoisted_5$161,[__props.showValueLabel?(openBlock(),createElementBlock(`div`,{key:0,class:`info`,innerHTML:valueHTML.value},null,8,_hoisted_6$139)):createCommentVNode(``,!0),__props.indeterminate?(openBlock(),createElementBlock(`span`,_hoisted_7$121)):(openBlock(),createElementBlock(`span`,{key:2,class:normalizeClass({"progress-fill":!0,"progress-fill-gradient":__props.gradient,"animate-progress":__props.animateDifference&&__props.value>__props.oldValue}),style:normalizeStyle({backgroundColor:__props.valueColor,zIndex:__props.value<__props.oldValue?2:1})},null,6)),__props.oldValue?(openBlock(),createElementBlock(`span`,{key:3,class:normalizeClass({"second-progress-fill":!0,"progress-fill-gradient":__props.gradient,"animate-progress":__props.animateDifference&&__props.value<__props.oldValue}),style:normalizeStyle({backgroundColor:__props.oldValueColor,zIndex:__props.value<__props.oldValue?1:2})},null,6)):createCommentVNode(``,!0)])]))}},bngProgressBar_default=__plugin_vue_export_helper_default(_sfc_main$349,[[`__scopeId`,`data-v-1ca6aacd`]]);function shrinkNum(num,decimals=0){let units=[``,`K`,`M`,`B`,`T`,`Q`];if(!num)return`0`;if(isNaN(parseFloat(num))||!isFinite(+num))return`n/a`;let power$1=Math.floor(Math.log(Math.abs(+num))/Math.log(1e3));return power$1>=units.length&&(power$1=units.length-1),(num/1e3**power$1).toFixed(decimals).replace(/\.0+$/,``)+units[power$1]}var _hoisted_1$306={key:1,class:`key-label`},_hoisted_2$252={class:`value-label`},_sfc_main$348={__name:`bngPropVal`,props:{iconType:[String,Object],keyLabel:String,valueLabel:{required:!0},shrinkNum:Boolean,iconColor:{type:String,default:`#fff`},noGap:{type:Boolean,default:!1},noIcon:{type:Boolean,default:!1}},setup(__props){let props=__props,itemClass=computed(()=>({"info-item":!0,"with-icon":props.iconType,"no-key":!props.keyLabel,"no-gap":props.noGap})),value=computed(()=>{let i=props.valueLabel;return props.shrinkNum?shrinkNum(i,0):i});return(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,{class:normalizeClass(itemClass.value)},[__props.iconType&&!__props.noIcon?(openBlock(),createBlock(unref(bngIcon_default),{key:0,class:`icon`,type:__props.iconType,color:__props.iconColor},null,8,[`type`,`color`])):createCommentVNode(``,!0),__props.keyLabel?(openBlock(),createElementBlock(`span`,_hoisted_1$306,toDisplayString(__props.keyLabel),1)):createCommentVNode(``,!0),createBaseVNode(`span`,_hoisted_2$252,toDisplayString(value.value),1)],2))}},bngPropVal_default=__plugin_vue_export_helper_default(_sfc_main$348,[[`__scopeId`,`data-v-fa2e2062`]]),_hoisted_1$305={class:`header`},_sfc_main$347={__name:`bngScreenHeading`,props:{blurDelay:Number,preheadings:Array,divider:Boolean,type:{type:String,default:`line`,validator:v=>[`line`,`ribbon`].includes(v)||v===``}},setup(__props){let blurVal=ref(!1);onMounted(()=>window.setTimeout(()=>blurVal.value=!0,~~+props.blurDelay));let props=__props,preheadings=computed(()=>Array.isArray(props.preheadings)&&props.preheadings.length>0?props.preheadings:null);return(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,{class:normalizeClass([`bng-screen-heading`,{[`heading-style-${__props.type}`]:!0,prehead:preheadings.value}])},[preheadings.value?withDirectives((openBlock(),createElementBlock(`span`,{key:0,class:normalizeClass([`pre-header`,{"with-divider":__props.divider}])},[(openBlock(!0),createElementBlock(Fragment,null,renderList(preheadings.value,preheading=>(openBlock(),createElementBlock(`span`,{class:`location`,key:preheading},toDisplayString(preheading),1))),128))],2)),[[unref(BngBlur_default),blurVal.value]]):createCommentVNode(``,!0),withDirectives((openBlock(),createElementBlock(`h1`,_hoisted_1$305,[renderSlot(_ctx.$slots,`default`,{},void 0,!0)])),[[unref(BngBlur_default),blurVal.value]])],2))}},bngScreenHeading_default=__plugin_vue_export_helper_default(_sfc_main$347,[[`__scopeId`,`data-v-f6d9f077`]]),_hoisted_1$304={class:`header`},_hoisted_2$251={key:0,class:`decorator-item`,width:`100%`,height:`100%`,viewBox:`0 0 32 40`,preserveAspectRatio:`none`,fill:`none`,xmlns:`http://www.w3.org/2000/svg`},_hoisted_3$220={key:1,class:`decorator-item`,width:`100%`,height:`100%`,viewBox:`0 0 36 40`,preserveAspectRatio:`xMaxYMid slice`,fill:`none`,xmlns:`http://www.w3.org/2000/svg`},_hoisted_4$188={key:2,class:`decorator-item`,width:`100%`,height:`100%`,viewBox:`0 0 36 40`,preserveAspectRatio:`xMaxYMid slice`,fill:`none`,xmlns:`http://www.w3.org/2000/svg`},_sfc_main$346={__name:`bngScreenHeadingV2`,props:{blurDelay:Number,preheadings:Array,divider:Boolean,type:{type:String,default:`1`,validator:v=>[`1`,`2`,`3`].includes(v)||v===``},hintVisible:Boolean,hintLabel:String,hintIcon:String,hintAccent:String,hintBindingEvent:String},emits:[`hint`],setup(__props,{emit:__emit}){let blurVal=ref(!1);onMounted(()=>window.setTimeout(()=>blurVal.value=!0,~~+props.blurDelay));let props=__props,preheadings=computed(()=>Array.isArray(props.preheadings)&&props.preheadings.length>0?props.preheadings:null);return computed(()=>props.hintVisible??!1),computed(()=>props.hintLabel??``),computed(()=>props.hintIcon??icons.arrowLargeLeft),computed(()=>props.hintAccent??ACCENTS.outlined),(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,{class:normalizeClass([`bng-screen-heading`,{[`heading-style-${__props.type}`]:!0,prehead:preheadings.value}])},[renderSlot(_ctx.$slots,`preheadings`,{},void 0,!0),withDirectives((openBlock(),createElementBlock(`span`,_hoisted_1$304,[createBaseVNode(`div`,{class:normalizeClass(`decorator type${__props.type}`)},[__props.type===`1`?(openBlock(),createElementBlock(`svg`,_hoisted_2$251,[..._cache[0]||=[createBaseVNode(`path`,{d:`M16.6328 40H1.62891L14.0039 6H14.002L11.8174 0H26.8174L29.001 6H29.0078L16.6328 40Z`,fill:`var(--bng-orange-400)`},null,-1)]])):createCommentVNode(``,!0),__props.type===`2`?(openBlock(),createElementBlock(`svg`,_hoisted_3$220,[..._cache[1]||=[createBaseVNode(`path`,{d:`M18.6366 0H34.0094L26.73 20H11.3572L18.6366 0Z`,fill:`#DA5706`},null,-1),createBaseVNode(`path`,{d:`M19.4504 40H4.07812L11.3572 20L4.07812 0H19.4504L26.7295 20L19.4504 40Z`,fill:`var(--bng-orange-400)`},null,-1)]])):createCommentVNode(``,!0),__props.type===`3`?(openBlock(),createElementBlock(`svg`,_hoisted_4$188,[..._cache[2]||=[createBaseVNode(`path`,{d:`M18.6366 0H34.0094L26.73 20H11.3572L18.6366 0Z`,fill:`#DA5706`},null,-1),createBaseVNode(`path`,{d:`M19.4504 40H4.07812L11.3572 20L4.07812 0H19.4504L26.7295 20L19.4504 40Z`,fill:`var(--bng-orange-400)`},null,-1)]])):createCommentVNode(``,!0)],2),createBaseVNode(`h1`,null,[renderSlot(_ctx.$slots,`default`,{},void 0,!0)])])),[[unref(BngBlur_default),blurVal.value]])],2))}},bngScreenHeadingV2_default=__plugin_vue_export_helper_default(_sfc_main$346,[[`__scopeId`,`data-v-4854a8bd`]]),_hoisted_1$303={class:`label select`},_hoisted_2$250={class:`bng-select-indicator`},_sfc_main$345={__name:`bngSelect`,props:mergeModels({value:void 0,options:{type:Array,required:!0},config:{type:Object,default:()=>({value:opt=>opt,label:opt=>opt})},loop:Boolean,labelClickable:Boolean,labelPopover:String,disabled:Boolean,navLeftEvent:{type:String,default:`focus_l`},navRightEvent:{type:String,default:`focus_r`}},{modelValue:{type:[Object,Boolean,Number,String],default:void 0},modelModifiers:{}}),emits:mergeModels([`change`,`valueChanged`,`label-click`],[`update:modelValue`]),setup(__props,{expose:__expose,emit:__emit}){let leftBinding=ref(),rightBinding=ref(),vModel=useModel(__props,`modelValue`),props=__props,elContainer=ref(),elContent=ref(),findOptionValue=(valueToFind,opts)=>Math.max(0,opts.findIndex(opt=>props.config.value(opt)===valueToFind)),index=ref(getInitialValue()),current=computed(()=>({option:props.options[index.value],value:props.config.value(props.options[index.value]),label:props.config.label(props.options[index.value])})),leftIconClass=computed(()=>({"with-binding":leftBinding.value?.displayed})),rightIconClass=computed(()=>({"with-binding":rightBinding.value?.displayed})),isLeftDisabled=props.loop?!1:computed(()=>index.value==0),isRightDisabled=props.loop?!1:computed(()=>index.value==props.options.length-1),emit$1=__emit,goPrev=()=>{!props.disabled&&!isLeftDisabled.value&&changeIndex(-1)},goNext=()=>{!props.disabled&&!isRightDisabled.value&&changeIndex(1)};__expose({goNext,goPrev,getElement:()=>elContainer.value,getContentElement:()=>elContent.value}),watch(()=>props.value,()=>index.value=props.value!==null&&props.value!==void 0?findOptionValue(props.value,props.options):0),watch(vModel,val=>index.value=val==null?0:findOptionValue(val,props.options)),watch(()=>index.value,updateValue);function updateValue(){emit$1(`valueChanged`,current.value.value,current.value.label,current.value.option),emit$1(`change`,current.value.value,current.value.label,current.value.option),vModel.value=current.value.value}function changeIndex(offset$2){props.loop?index.value=(props.options.length+index.value+offset$2)%props.options.length:index.value=clamp(index.value+offset$2,0,props.options.length-1)}function getInitialValue(){return vModel.value!==null&&vModel.value!==void 0?findOptionValue(vModel.value,props.options):`value`in props?findOptionValue(props.value,props.options):0}return(_ctx,_cache)=>withDirectives((openBlock(),createElementBlock(`div`,{ref_key:`elContainer`,ref:elContainer,class:`bng-select`,"bng-nav-item":``},[renderSlot(_ctx.$slots,`previousButton`,{click:goPrev,disabled:unref(isLeftDisabled)},()=>[createVNode(unref(bngButton_default),{"bng-no-nav":`true`,disabled:__props.disabled||unref(isLeftDisabled),accent:unref(ACCENTS).text,mute:_ctx.$attrs.mute,"data-testid":`previous-btn`,onClick:goPrev},{default:withCtx(()=>[createVNode(unref(bngIcon_default),{type:leftBinding.value?.displayed?unref(icons).arrowSmallLeft:unref(icons).arrowLargeLeft,class:normalizeClass(leftIconClass.value)},null,8,[`type`,`class`]),__props.navLeftEvent&&__props.navLeftEvent!==`focus_l`?(openBlock(),createBlock(unref(bngBinding_default),{key:0,ref_key:`leftBinding`,ref:leftBinding,uiEvent:__props.navLeftEvent,controller:``},null,8,[`uiEvent`])):createCommentVNode(``,!0)]),_:1},8,[`disabled`,`accent`,`mute`])],!0),withDirectives((openBlock(),createElementBlock(`div`,{ref_key:`elContent`,ref:elContent,class:normalizeClass([`bng-select-content`,{"label-clickable":__props.labelClickable}]),onClick:_cache[0]||=withModifiers($event=>__props.labelClickable&&emit$1(`label-click`),[`stop`])},[renderSlot(_ctx.$slots,`display`,{label:current.value.label,value:current.value.value},()=>[createBaseVNode(`span`,_hoisted_1$303,toDisplayString(current.value.label),1),_cache[1]||=createBaseVNode(`label`,{flavour:``},null,-1)],!0)],2)),[[unref(BngSoundClass_default),!__props.disabled&&__props.labelClickable&&`bng_click_hover_generic`],[unref(BngPopover_default),__props.labelPopover,`bottom`,{click:!0}]]),renderSlot(_ctx.$slots,`nextButton`,{click:goNext,disabled:unref(isRightDisabled)},()=>[createVNode(unref(bngButton_default),{"bng-no-nav":`true`,disabled:__props.disabled||unref(isRightDisabled),accent:unref(ACCENTS).text,mute:_ctx.$attrs.mute,"data-testid":`next-btn`,onClick:goNext},{default:withCtx(()=>[__props.navRightEvent&&__props.navRightEvent!==`focus_r`?(openBlock(),createBlock(unref(bngBinding_default),{key:0,ref_key:`rightBinding`,ref:rightBinding,uiEvent:__props.navRightEvent,controller:``},null,8,[`uiEvent`])):createCommentVNode(``,!0),createVNode(unref(bngIcon_default),{type:rightBinding.value?.displayed?unref(icons).arrowSmallRight:unref(icons).arrowLargeRight,class:normalizeClass(rightIconClass.value)},null,8,[`type`,`class`])]),_:1},8,[`disabled`,`accent`,`mute`])],!0),createBaseVNode(`div`,_hoisted_2$250,[(openBlock(!0),createElementBlock(Fragment,null,renderList(__props.options.length,idx=>(openBlock(),createElementBlock(`div`,{key:idx,class:normalizeClass({active:idx-1===index.value})},null,2))),128))])])),[[unref(BngOnUiNav_default),goPrev,__props.navLeftEvent,{focusRequired:!0}],[unref(BngOnUiNav_default),goNext,__props.navRightEvent,{focusRequired:!0}],[unref(BngDisabled_default),__props.disabled]])}},bngSelect_default=__plugin_vue_export_helper_default(_sfc_main$345,[[`__scopeId`,`data-v-d1cacb72`]]),_hoisted_1$302={class:`bng-simple-graph`},_hoisted_2$249={key:0,class:`y-axis`},_hoisted_3$219={class:`y-values`},_hoisted_4$187={class:`max-value`},_hoisted_5$160={class:`axis-label`},_hoisted_6$138={key:0,class:`unit`},_hoisted_7$120={class:`min-value`},_hoisted_8$100={viewBox:`0 0 100 100`,preserveAspectRatio:`none`,class:`graph-svg`},_hoisted_9$90=[`width`,`height`],_hoisted_10$78=[`d`,`stroke`],_hoisted_11$70=[`d`,`stroke`],_hoisted_12$58=[`width`,`height`],_hoisted_13$50=[`d`,`stroke`],_hoisted_14$45=[`d`,`stroke`],_hoisted_15$43={key:0,width:`100`,height:`100`,fill:`url(#subgrid)`},_hoisted_16$40={class:`grid`},_hoisted_17$33=[`y1`,`y2`,`stroke`],_hoisted_18$30={class:`background-ranges`},_hoisted_19$25=[`x`,`width`,`fill`,`stroke`,`opacity`],_hoisted_20$21={class:`vertical-guides`},_hoisted_21$19=[`x1`,`x2`,`stroke`,`opacity`],_hoisted_22$17=[`x1`,`x2`],_hoisted_23$16=[`d`,`fill`,`opacity`],_hoisted_24$15=[`d`,`stroke`],_hoisted_25$14={key:2,class:`x-axis`},_hoisted_26$12={class:`x-values`},_hoisted_27$12={class:`min-value`},_hoisted_28$11={class:`axis-label`},_hoisted_29$11={key:0,class:`unit`},_hoisted_30$10={class:`max-value`},_sfc_main$344={__name:`bngSimpleGraph`,props:{config:{type:Object,default:()=>({showLabels:!1,xAxis:{key:`x`,label:`X Axis`,unit:``},yAxis:{key:`y`,label:`Y Axis`,unit:``}})},points:{type:Array,default:()=>[]},gridColor:{type:String,default:`var(--bng-ter-blue-gray-500)`},backgroundColor:{type:String,default:`rgba(0, 0, 0, 0.1)`},currentX:{type:Number,default:null},verticalGuides:{type:Array,default:()=>[]},ranges:{type:Array,default:()=>[]},gridDivisions:{type:Array,default:()=>[50,20]},subgridDivider:{type:Number,default:2},showSubgrid:{type:Boolean,default:!0},singleLabel:{type:Object,default:null}},setup(__props){useCssVars(_ctx=>({v194c2663:__props.config.showLabels?`2rem`:`0`,fdb9891e:__props.backgroundColor}));let props=__props,gridSizes=computed(()=>({x:100/props.gridDivisions[0],y:100/props.gridDivisions[1]})),xScale=computed(()=>{if(props.config?.xAxis?.min!==void 0&&props.config?.xAxis?.max!==void 0){let range$1=props.config.xAxis.max-props.config.xAxis.min;return{min:props.config.xAxis.min,max:props.config.xAxis.max,range:range$1===0?1:range$1}}if(!props.points.length)return{min:0,max:1,range:1};let xValues=[...props.points.flatMap(dataset=>(dataset.points||[]).map(point=>point&&point[0])),...(props.verticalGuides||[]).map(guide=>guide?.x),...(props.ranges||[]).map(range$1=>range$1?.start),...(props.ranges||[]).map(range$1=>range$1?.end)].filter(val=>val!=null&&isFinite(val));if(xValues.length===0)return{min:0,max:1,range:1};let min$1=Math.min(...xValues),max$1=Math.max(...xValues);if(!isFinite(min$1)||!isFinite(max$1))return{min:0,max:1,range:1};let range=max$1-min$1;return{min:min$1,max:max$1,range:range===0?1:range}}),getXPosition=value=>{if(value==null||!isFinite(value))return 0;let result=(value-xScale.value.min)/xScale.value.range*100;return isFinite(result)?result:0},datasetPaths=computed(()=>!props.points.length||!xScale.value?[]:props.points.map(dataset=>{if(!dataset.points||!Array.isArray(dataset.points)||dataset.points.length===0)return{datasetId:dataset.label||`unknown`,linePath:``,areaPath:``};let linePoints=dataset.points.map((point,index)=>{if(!point||point.length<2)return``;let x=getXPosition(point[0]),y=getYPosition(point[1]);return`${index===0?`M`:`L`} ${x} ${y}`}).filter(p$1=>p$1).join(` `),areaPoints=dataset.points.map(point=>!point||point.length<2?``:`L ${getXPosition(point[0])} ${getYPosition(point[1])}`).filter(p$1=>p$1).join(` `),areaPath=``;if(dataset.fill&&dataset.points.length>0){let firstPoint=dataset.points[0],lastPoint=dataset.points[dataset.points.length-1];firstPoint&&lastPoint&&firstPoint.length>=2&&lastPoint.length>=2&&(areaPath=`M -5 105 L -5 ${getYPosition(firstPoint[1])} ${areaPoints} L 105 ${getYPosition(lastPoint[1])} L 105 105 Z`)}return{datasetId:dataset.label||`unknown`,linePath:linePoints,areaPath}})),getLinePathForDataset=dataset=>{let path=datasetPaths.value.find(p$1=>p$1.datasetId===dataset.label);return path?path.linePath:``},getAreaPathForDataset=dataset=>{let path=datasetPaths.value.find(p$1=>p$1.datasetId===dataset.label);return path?path.areaPath:``},getYPosition=value=>{if(value==null||!isFinite(value))return 50;let yMin=yBounds.value.min,yMax=yBounds.value.max;if(yMin==null||yMax==null||!isFinite(yMin)||!isFinite(yMax)||yMin===yMax)return 50;if(yMin>=0||yMax<=0){let yRange$1=yMax-yMin;if(yRange$1===0)return 50;let result$1=97.5-(value-yMin)/yRange$1*95;return isFinite(result$1)?result$1:50}let yRange=Math.max(Math.abs(yMin),Math.abs(yMax));if(yRange===0)return 50;let totalRange=Math.abs(yMin)+Math.abs(yMax);if(totalRange===0)return 50;let zeroLinePosition=Math.abs(yMin)/totalRange*95+2.5,result;return result=value>=0?zeroLinePosition-value/yRange*(zeroLinePosition-2.5):zeroLinePosition+Math.abs(value)/yRange*(97.5-zeroLinePosition),isFinite(result)?result:50},formatNumber=num=>num==null||!isFinite(num)?`0`:Math.floor(num).toString(),yBounds=computed(()=>{if(props.config?.yAxis?.min!==void 0&&props.config?.yAxis?.max!==void 0)return{min:props.config.yAxis.min,max:props.config.yAxis.max};if(!props.points.length)return{min:0,max:0};let allYValues=props.points.flatMap(dataset=>(dataset.points||[]).map(point=>point&&point[1])).filter(val=>val!=null&&isFinite(val));if(allYValues.length===0)return{min:0,max:1};let min$1=Math.min(...allYValues),max$1=Math.max(...allYValues);return!isFinite(min$1)||!isFinite(max$1)?{min:0,max:1}:{min:min$1,max:max$1}}),xMinFormatted=computed(()=>formatNumber(xScale.value?.min||0)),xMaxFormatted=computed(()=>formatNumber(xScale.value?.max||0)),yMinFormatted=computed(()=>formatNumber(yBounds.value.min)),yMaxFormatted=computed(()=>formatNumber(yBounds.value.max)),hasNegativeValues=computed(()=>yBounds.value.min<0),getLabelPosition=()=>{if(!props.singleLabel)return{x:0,y:0,anchor:`start`};let labelX=props.singleLabel.x===void 0?95:getXPosition(props.singleLabel.x),labelY=props.singleLabel.y===void 0?50:getYPosition(props.singleLabel.y),adjustedY=labelY>=25?labelY+4:labelY-2,anchor=labelX>=80?`end`:`start`;return{x:anchor===`end`?Math.min(labelX,98):Math.max(labelX,2),y:adjustedY,anchor}},getLabelStyle=()=>{if(!props.singleLabel)return{};let basePos=getLabelPosition(),estimatedWidth=props.singleLabel.text.length*6.5+6,estimatedHeight=18,containerWidth=300,containerHeight=80,pixelX=basePos.x/100*300,pixelY=basePos.y/100*80,finalX=basePos.x,finalY=basePos.y,anchor=basePos.anchor,verticalAlign=`middle`;anchor===`start`?pixelX+estimatedWidth>290&&(anchor=`end`):pixelX-estimatedWidth<10&&(anchor=`start`);let minGapFromPoint=4,topBuffer=8,bottomBuffer=8,wouldOverflowTop=pixelY-18/2<8;if(pixelY+18/2>72)verticalAlign=`bottom`,finalY=Math.max(basePos.y-4,15);else if(wouldOverflowTop)verticalAlign=`top`,finalY=Math.min(basePos.y+4,85);else{let pointY=basePos.y;pointY>75?(verticalAlign=`bottom`,finalY=pointY-4):pointY<25?(verticalAlign=`top`,finalY=pointY+4):(verticalAlign=`bottom`,finalY=pointY-4)}let transformX=`translateX(0)`,transformY=`translateY(-50%)`;return anchor===`end`&&(transformX=`translateX(-100%)`),verticalAlign===`bottom`?transformY=`translateY(-100%)`:verticalAlign===`top`&&(transformY=`translateY(0)`),{position:`absolute`,left:`${finalX}%`,top:`${finalY}%`,transform:`${transformX} ${transformY}`,color:props.singleLabel.color||`var(--bng-orange)`,fontSize:`11px`,fontFamily:`sans-serif`,pointerEvents:`none`,whiteSpace:`nowrap`}};return(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$302,[__props.config.showLabels?(openBlock(),createElementBlock(`div`,_hoisted_2$249,[createBaseVNode(`div`,_hoisted_3$219,[createBaseVNode(`div`,_hoisted_4$187,toDisplayString(yMaxFormatted.value),1),createBaseVNode(`div`,_hoisted_5$160,[createTextVNode(toDisplayString(__props.config.yAxis.label)+` `,1),__props.config.yAxis.unit?(openBlock(),createElementBlock(`span`,_hoisted_6$138,`(`+toDisplayString(__props.config.yAxis.unit)+`)`,1)):createCommentVNode(``,!0)]),createBaseVNode(`div`,_hoisted_7$120,toDisplayString(yMinFormatted.value),1)])])):createCommentVNode(``,!0),(openBlock(),createElementBlock(`svg`,_hoisted_8$100,[createBaseVNode(`defs`,null,[createBaseVNode(`pattern`,{id:`grid`,width:gridSizes.value.x,height:gridSizes.value.y,patternUnits:`userSpaceOnUse`},[createBaseVNode(`path`,{d:`M ${gridSizes.value.x} 0 L ${gridSizes.value.x} ${gridSizes.value.y}`,stroke:__props.gridColor,"stroke-width":`1`,"vector-effect":`non-scaling-stroke`,opacity:`0.3`},null,8,_hoisted_10$78),createBaseVNode(`path`,{d:`M 0 ${gridSizes.value.y} L 100 ${gridSizes.value.y}`,stroke:__props.gridColor,"stroke-width":`1`,"vector-effect":`non-scaling-stroke`,opacity:`0.3`},null,8,_hoisted_11$70)],8,_hoisted_9$90),createBaseVNode(`pattern`,{id:`subgrid`,width:gridSizes.value.x,height:gridSizes.value.y,patternUnits:`userSpaceOnUse`},[createBaseVNode(`path`,{d:`M ${gridSizes.value.x/__props.subgridDivider} 0 L ${gridSizes.value.x/__props.subgridDivider} ${gridSizes.value.y}`,stroke:__props.gridColor,"stroke-width":`0.5`,"vector-effect":`non-scaling-stroke`,opacity:`0.15`},null,8,_hoisted_13$50),createBaseVNode(`path`,{d:`M 0 ${gridSizes.value.y/__props.subgridDivider} L 100 ${gridSizes.value.y/__props.subgridDivider}`,stroke:__props.gridColor,"stroke-width":`0.5`,"vector-effect":`non-scaling-stroke`,opacity:`0.15`},null,8,_hoisted_14$45)],8,_hoisted_12$58)]),__props.showSubgrid?(openBlock(),createElementBlock(`rect`,_hoisted_15$43)):createCommentVNode(``,!0),_cache[0]||=createBaseVNode(`rect`,{width:`100`,height:`100`,fill:`url(#grid)`},null,-1),createBaseVNode(`g`,_hoisted_16$40,[hasNegativeValues.value?(openBlock(),createElementBlock(`line`,{key:0,x1:`0`,y1:getYPosition(0),x2:`100`,y2:getYPosition(0),stroke:__props.gridColor,"stroke-width":`2`,"vector-effect":`non-scaling-stroke`,opacity:`0.75`},null,8,_hoisted_17$33)):createCommentVNode(``,!0)]),createBaseVNode(`g`,_hoisted_18$30,[(openBlock(!0),createElementBlock(Fragment,null,renderList(__props.ranges,range=>(openBlock(),createElementBlock(`rect`,{key:`range-${range.start}`,x:getXPosition(range.start),y:`-5`,width:getXPosition(range.end)-getXPosition(range.start),height:`110`,fill:range.fill,stroke:range.outline,"stroke-width":`2`,"vector-effect":`non-scaling-stroke`,opacity:range.opacity},null,8,_hoisted_19$25))),128))]),createBaseVNode(`g`,_hoisted_20$21,[(openBlock(!0),createElementBlock(Fragment,null,renderList(__props.verticalGuides,guide=>(openBlock(),createElementBlock(`line`,{key:`guide-${guide.x}`,x1:getXPosition(guide.x),y1:`0`,x2:getXPosition(guide.x),y2:`100`,stroke:guide.color,"stroke-width":`1`,"vector-effect":`non-scaling-stroke`,opacity:guide.opacity},null,8,_hoisted_21$19))),128))]),__props.currentX?(openBlock(),createElementBlock(`line`,{key:1,x1:getXPosition(__props.currentX),y1:`0`,x2:getXPosition(__props.currentX),y2:`100`,stroke:`white`,"stroke-width":`1`,"vector-effect":`non-scaling-stroke`,opacity:`0.8`},null,8,_hoisted_22$17)):createCommentVNode(``,!0),(openBlock(!0),createElementBlock(Fragment,null,renderList(__props.points,dataset=>(openBlock(),createElementBlock(`g`,{key:dataset.label},[dataset.fill?(openBlock(),createElementBlock(`path`,{key:0,d:getAreaPathForDataset(dataset),fill:dataset.color||`white`,opacity:dataset.fillOpacity??.5},null,8,_hoisted_23$16)):createCommentVNode(``,!0),createBaseVNode(`path`,{d:getLinePathForDataset(dataset),stroke:dataset.color||`white`,fill:`none`,"stroke-width":`1`,"vector-effect":`non-scaling-stroke`},null,8,_hoisted_24$15)]))),128))])),__props.singleLabel?(openBlock(),createElementBlock(`div`,{key:1,class:`single-label`,style:normalizeStyle(getLabelStyle())},toDisplayString(__props.singleLabel.text),5)):createCommentVNode(``,!0),__props.config.showLabels?(openBlock(),createElementBlock(`div`,_hoisted_25$14,[createBaseVNode(`div`,_hoisted_26$12,[createBaseVNode(`div`,_hoisted_27$12,toDisplayString(xMinFormatted.value),1),createBaseVNode(`div`,_hoisted_28$11,[createTextVNode(toDisplayString(__props.config.xAxis.label)+` `,1),__props.config.xAxis.unit?(openBlock(),createElementBlock(`span`,_hoisted_29$11,`(`+toDisplayString(__props.config.xAxis.unit)+`)`,1)):createCommentVNode(``,!0)]),createBaseVNode(`div`,_hoisted_30$10,toDisplayString(xMaxFormatted.value),1)])])):createCommentVNode(``,!0)]))}},bngSimpleGraph_default=__plugin_vue_export_helper_default(_sfc_main$344,[[`__scopeId`,`data-v-66d95af3`]]),_hoisted_1$301={class:`bng-slider-container`},_hoisted_2$248=[`disabled`,`min`,`max`,`step`],_sfc_main$343={__name:`bngSlider`,props:{modelValue:Number,origValue:{type:[Number,String],default:NaN},min:{type:[Number,String],default:0},max:{type:[Number,String],required:!0},step:{type:[Number,String],default:0},withReset:{type:Boolean,default:!1},withInput:{type:Boolean,default:!1},inputMultiplier:{type:Number,default:1},unit:{type:String,default:``},disabled:Boolean,uiNavFocus:{type:[Boolean,Object],default:{},validator:val=>typeof val==`boolean`&&!val||typeof val==`object`}},emits:[`change`,`valueChanged`,`update:modelValue`],setup(__props,{expose:__expose,emit:__emit}){let props=__props,emit$1=__emit,slider=ref(null),value=ref(props.modelValue);ref(!1);let uiNavFocusFunction=computed(()=>props.uiNavFocus?{callback:(dir,val)=>{value.value=val,notify()},value:()=>value.value,min:+props.min,max:+props.max,step:()=>+props.step,...props.uiNavFocus}:!1);watch(()=>props.modelValue,val=>{value.value=Number(val),updateSliderBackground()});let dirty=useDirty(value,null,updateSliderBackground),dirtyReset=useDirty(value,null,updateSliderBackground);__expose(dirty);let resetDisabled=computed(()=>props.disabled?!0:isNaN(dirtyReset.currentCleanValue.value)?!dirty.dirty.value:!dirtyReset.dirty.value);onMounted(()=>{updateSliderBackground(),inputProps.value=value.value*props.inputMultiplier});function notify(){emit$1(`update:modelValue`,value.value),emit$1(`valueChanged`,value.value),emit$1(`change`,value.value),updateSliderBackground()}function updateSliderBackground(){if(!slider.value)return;let current=(value.value-props.min)/(props.max-props.min)*100,init$3=[-100,-100],dirtyVal=dirtyReset.currentCleanValue.value;if((typeof dirtyVal!=`number`||isNaN(dirtyVal))&&(dirtyVal=dirty.currentCleanValue.value),typeof dirtyVal==`number`&&!isNaN(dirtyVal)){let initpos=(dirtyVal-props.min)/(props.max-props.min)*100;init$3[currentvalue.value,val=>{inputProps.value=val*props.inputMultiplier}),watch(()=>props.origValue,val=>{val=+val,isNaN(val)||dirtyReset.setCleanValue(val)},{immediate:!0}),watch(()=>inputProps.value,val=>{value.value=val/props.inputMultiplier});function onInputChange(num){num=Number(num);let norm=roundDecSample(num,inputProps.step);num!==norm&&(inputProps.value=norm),num=norm/props.inputMultiplier,num=roundDecSample(num,props.step),numprops.max&&(num=props.max),value.value=num,notify()}function resetValue(){let val=+props.origValue;isNaN(val)?dirty.resetValue():value.value=val,notify()}return(_ctx,_cache)=>withDirectives((openBlock(),createElementBlock(`div`,_hoisted_1$301,[withDirectives(createBaseVNode(`input`,{ref_key:`slider`,ref:slider,class:`bng-slider`,type:`range`,disabled:__props.disabled,"onUpdate:modelValue":_cache[0]||=$event=>value.value=$event,min:+__props.min,max:+__props.max,step:+__props.step,onInput:notify},null,40,_hoisted_2$248),[[vModelText,value.value,void 0,{number:!0}],[unref(BngOnUiNavFocus_default),uiNavFocusFunction.value,void 0,{repeat:!0}]]),__props.withInput?(openBlock(),createBlock(unref(bngInput_default),{key:0,class:`bng-slider-input`,disabled:__props.disabled,modelValue:inputProps.value,"onUpdate:modelValue":_cache[1]||=$event=>inputProps.value=$event,type:`number`,min:inputProps.min,max:inputProps.max,step:inputProps.step,suffix:__props.unit,onValueChanged:onInputChange},null,8,[`disabled`,`modelValue`,`min`,`max`,`step`,`suffix`])):createCommentVNode(``,!0),__props.withReset?(openBlock(),createBlock(unref(bngButton_default),{key:1,class:`bng-slider-reset`,accent:unref(ACCENTS).text,icon:unref(icons).undo,disabled:resetDisabled.value,onClick:resetValue},null,8,[`accent`,`icon`,`disabled`])):createCommentVNode(``,!0)])),[[unref(BngScopedNav_default),{bubbleWhitelistEvents:[`menu`]}],[unref(BngDisabled_default),__props.disabled]])}},bngSlider_default=__plugin_vue_export_helper_default(_sfc_main$343,[[`__scopeId`,`data-v-7d0150a1`]]),_sfc_main$342={__name:`bngSmartSelect`,props:mergeModels({items:{type:Array,required:!0},threshold:{type:Number,default:6},type:{type:String,default:``,validator(val){return[``,`select`,`dropdown`].includes(val)}},highlight:[String,Array,RegExp],disabled:Boolean},{modelValue:{},modelModifiers:{}}),emits:mergeModels([`change`],[`update:modelValue`]),setup(__props,{emit:__emit}){let props=__props,value=useModel(__props,`modelValue`),emit$1=__emit,elDropdown=ref(),elSelect=ref(),types={none:bngSelect_default,select:bngSelect_default,dropdown:bngDropdown_default},items$2=computed(()=>Array.isArray(props.items)?props.items:[]),type=computed(()=>props.type&&props.type in types?props.type:items$2.value.length===0?`none`:items$2.value.length<=props.threshold?`select`:`dropdown`),binds=computed(()=>{let res={disabled:props.disabled};switch(type.value){default:res.options=[`n/a`],res.disabled=!0;break;case`select`:res.loop=!0,res.labelClickable=!0,res.config={label:itm=>itm?.label||`n/a`,value:itm=>itm?.value},res.options=items$2.value.filter(itm=>!itm.disabled&&!itm.group),res.items=items$2.value,res.highlight=props.highlight,res.disabled||=res.options.length===0,res.popoverTarget=elSelect.value?.getElement?.(),res.focusTarget=elSelect.value?.getContentElement?.()||res.popoverTarget;break;case`dropdown`:res.items=items$2.value,res.highlight=props.highlight,res.showSearch=!0;break}return res});function openDropdown(){}function onSelectChanged(newValue){value.value!==newValue&&emit$1(`change`,newValue)}function onDropdownChanged(newValue){value.value!==newValue&&emit$1(`change`,newValue)}return(_ctx,_cache)=>(openBlock(),createElementBlock(Fragment,null,[type.value===`dropdown`?createCommentVNode(``,!0):(openBlock(),createBlock(unref(bngSelect_default),{key:0,ref_key:`elSelect`,ref:elSelect,class:`bng-smart-select`,modelValue:value.value,"onUpdate:modelValue":_cache[0]||=$event=>value.value=$event,options:binds.value.options,config:binds.value.config,disabled:binds.value.disabled,loop:``,"label-clickable":``,"label-popover":elDropdown.value?.popoverName,onLabelClick:openDropdown,onChange:onSelectChanged},null,8,[`modelValue`,`options`,`config`,`disabled`,`label-popover`])),binds.value.items?(openBlock(),createBlock(unref(bngDropdown_default),{key:1,ref_key:`elDropdown`,ref:elDropdown,class:normalizeClass(`bng-smart-${type.value}`),modelValue:value.value,"onUpdate:modelValue":_cache[1]||=$event=>value.value=$event,items:binds.value.items,highlight:binds.value.highlight,disabled:binds.value.disabled,headless:type.value===`select`,"show-search":binds.value.showSearch,"focus-target":binds.value.focusTarget,"popover-target":binds.value.popoverTarget,onValueChanged:onDropdownChanged},null,8,[`class`,`modelValue`,`items`,`highlight`,`disabled`,`headless`,`show-search`,`focus-target`,`popover-target`])):createCommentVNode(``,!0)],64))}},bngSmartSelect_default=__plugin_vue_export_helper_default(_sfc_main$342,[[`__scopeId`,`data-v-a288ad68`]]),_hoisted_1$300=[`xlink:href`],_sfc_main$341={__name:`bngSpriteIcon`,props:{atlasPath:{type:String,default:`sprites/svg-symbols.svg`},src:{type:String,required:!0},color:{type:String,default:`#fff`},deg:{type:Number,default:0}},setup(__props){let props=__props,atlasURL=computed(()=>`${getAssetURL$1(props.atlasPath)}#${props.src.toLowerCase()}`),getAssetURL$1=assetPath=>bngApi.isMock?`http://localhost:9000/${assetPath}`:`/ui/ui-vue/src/assets/${assetPath}`;return(_ctx,_cache)=>(openBlock(),createElementBlock(`svg`,{class:`atlasIcon`,style:normalizeStyle({fill:__props.color,pointerEvents:`none`,transform:`rotate(${__props.deg}deg)`}),version:`1.1`,xmlns:`http://www.w3.org/2000/svg`},[createBaseVNode(`use`,{"xlink:href":atlasURL.value},null,8,_hoisted_1$300)],4))}},bngSpriteIcon_default=__plugin_vue_export_helper_default(_sfc_main$341,[[`__scopeId`,`data-v-0ace1ddc`]]),_hoisted_1$299=[`tabindex`],_hoisted_2$247={key:0};const LABEL_ALIGNMENTS={START:`start`,END:`end`,CENTER:`center`};var _sfc_main$340={__name:`bngSwitch`,props:{modelValue:[Boolean,Number,String],checked:{type:Boolean,default:!1},label:String,labelBefore:Boolean,labelAlignment:{type:String,default:LABEL_ALIGNMENTS.END,validator:value=>Object.values(LABEL_ALIGNMENTS).includes(value)},inline:{type:Boolean,default:!0},alwaysTransparent:Boolean,disabled:Boolean,valueOn:{type:[Boolean,Number,String],default:void 0},valueOff:{type:[Boolean,Number,String],default:void 0}},emits:[`update:modelValue`,`change`,`valueChanged`],setup(__props,{emit:__emit}){let props=__props,emit$1=__emit,slots=useSlots(),bngSwitch=ref(null),valOn=computed(()=>props.valueOn===void 0?!0:props.valueOn),valOff=computed(()=>props.valueOff===void 0?!1:props.valueOff),isSwitchOn=computed(()=>props.modelValue==null?props.checked:props.modelValue===valOn.value);function onClicked(){if(props.disabled)return;let newValue=isSwitchOn.value?valOff.value:valOn.value;props.modelValue!=null&&emit$1(`update:modelValue`,newValue),emit$1(`valueChanged`,newValue),emit$1(`change`,newValue)}return onUpdated(()=>ensureFocus(bngSwitch.value)),(_ctx,_cache)=>withDirectives((openBlock(),createElementBlock(`div`,{ref_key:`bngSwitch`,ref:bngSwitch,"bng-nav-item":``,class:normalizeClass([`bng-switch`,{"bng-switch-on":isSwitchOn.value,"with-background":!__props.alwaysTransparent,"with-label":__props.label||unref(slots).default,"label-position-before":__props.labelBefore,"inline-switch":!__props.label&&!unref(slots).default||__props.inline}]),tabindex:__props.disabled?-1:0,onClick:onClicked},[_cache[0]||=createBaseVNode(`div`,{class:`bng-switch-control`},null,-1),unref(slots).default||__props.label?(openBlock(),createElementBlock(`div`,{key:0,class:normalizeClass([`bng-switch-label`,[`label-alignment-`+__props.labelAlignment]])},[renderSlot(_ctx.$slots,`default`,{},()=>[__props.label?(openBlock(),createElementBlock(`span`,_hoisted_2$247,toDisplayString(__props.label),1)):createCommentVNode(``,!0)],!0)],2)):createCommentVNode(``,!0)],10,_hoisted_1$299)),[[unref(BngOnUiNav_default),void 0,`ok`,{asMouse:!0,focusRequired:!0}],[unref(BngDisabled_default),__props.disabled]])}},bngSwitch_default=__plugin_vue_export_helper_default(_sfc_main$340,[[`__scopeId`,`data-v-8e1c4b05`]]),_hoisted_1$298={class:`bng-switch-label`},_hoisted_2$246={key:0},_sfc_main$339={__name:`bngSwitchOld`,props:{modelValue:Boolean,label:String,checked:Boolean,uncheckedWithBackground:Boolean,disabled:Boolean},emits:[`valueChanged`,`update:modelValue`],setup(__props,{emit:__emit}){let toggleValue=ref(!1),props=__props,emit$1=__emit,slots=useSlots();onBeforeMount(init$3),watch(()=>props.modelValue,init$3),watch(()=>props.checked,init$3),watch(()=>props.disabled,init$3);function init$3(){toggleValue.value=props.checked||props.modelValue}function onValueChanged(){props.disabled||(toggleValue.value=!toggleValue.value,emit$1(`update:modelValue`,toggleValue.value),emit$1(`valueChanged`,toggleValue.value))}return(_ctx,_cache)=>unref(slots).default||__props.label?withDirectives((openBlock(),createElementBlock(`div`,mergeProps({key:0,class:[`bng-labeled-switch`,{"switch-on":toggleValue.value,"with-background":__props.uncheckedWithBackground}]},{...!__props.disabled&&{"bng-nav-item":1}},{tabindex:`{{disabled ? 0 : 1}}`,onClick:onValueChanged,onKeyup:withKeys(onValueChanged,[`space`])}),[_cache[0]||=createBaseVNode(`div`,{class:`bng-switch-wrapper`},[createBaseVNode(`div`,{class:`bng-switch`})],-1),createBaseVNode(`div`,_hoisted_1$298,[renderSlot(_ctx.$slots,`default`,{},()=>[__props.label?(openBlock(),createElementBlock(`label`,_hoisted_2$246,toDisplayString(__props.label),1)):createCommentVNode(``,!0)],!0)])],16)),[[unref(BngDisabled_default),__props.disabled]]):withDirectives((openBlock(),createElementBlock(`div`,mergeProps({key:1},{...!__props.disabled&&{"bng-nav-item":1}},{tabindex:`{{disabled ? 0 : 1}}`,class:[`bng-switch-wrapper`,{"switch-on":toggleValue.value}],onClick:onValueChanged,onKeyup:withKeys(onValueChanged,[`space`])}),[..._cache[1]||=[createBaseVNode(`div`,{class:`bng-switch`},null,-1)]],16)),[[unref(BngDisabled_default),__props.disabled]])}},bngSwitchOld_default=__plugin_vue_export_helper_default(_sfc_main$339,[[`__scopeId`,`data-v-da8dc7b1`]]),_hoisted_1$297={"bng-nav-item":``,class:`bng-tile tile`},_hoisted_2$245={class:`content`},_hoisted_3$218={class:`label`},_sfc_main$338={__name:`bngTile`,props:{label:String,ratio:{type:String,default:`4:3`},backgroundImage:String,backgroundExternalImage:String,disabled:Boolean},setup(__props){return(_ctx,_cache)=>withDirectives((openBlock(),createElementBlock(`div`,_hoisted_1$297,[createVNode(unref(aspectRatio_default),{class:`content-container image`,ratio:__props.ratio,image:__props.backgroundImage,externalImage:__props.backgroundExternalImage,imageMode:`contain`},{default:withCtx(()=>[createBaseVNode(`div`,_hoisted_2$245,[renderSlot(_ctx.$slots,`default`,{},void 0,!0)])]),_:3},8,[`ratio`,`image`,`externalImage`]),renderSlot(_ctx.$slots,`label`,{},()=>[createBaseVNode(`div`,_hoisted_3$218,toDisplayString(__props.label),1)],!0)])),[[unref(BngDisabled_default),__props.disabled]])}},bngTile_default=__plugin_vue_export_helper_default(_sfc_main$338,[[`__scopeId`,`data-v-af5747cc`]]),_sfc_main$337={__name:`bngTooltip`,props:{text:{type:String,required:!0},position:{type:String,default:`top`}},setup(__props){return(_ctx,_cache)=>withDirectives((openBlock(),createElementBlock(`div`,null,[renderSlot(_ctx.$slots,`default`,{},void 0,!0)])),[[unref(BngTooltip_default),__props.text,__props.position]])}},bngTooltip_default=__plugin_vue_export_helper_default(_sfc_main$337,[[`__scopeId`,`data-v-53073c36`]]),toInt=v=>~~+v,_sfc_main$336={__name:`bngUnit`,props:{options:Object,formatter:[Function,String]},setup(__props){let{units}=useBridge(),knownUnits={money:{formatter:v=>units.beamBucks(v)},beamXP:{formatter:toInt},stars:{formatter:toInt},vouchers:{formatter:toInt},insuranceScore:{formatter:toInt},multiplier:{formatter:toInt,noGap:!0}},defaultColors={stars:`var(--bng-ter-yellow-200)`,vouchers:`var(--bng-add-blue-400)`},attrs=useAttrs(),unit=computed(()=>{for(let key of Object.keys(attrs))if(key in knownUnits)return{type:key,value:attrs[key],...knownUnits[key],...props.options};return{type:`unknown`}}),formattedValue=computed(()=>{if(props.formatter){if(typeof props.formatter==`function`)return props.formatter(unit.value.value);if(typeof props.formatter==`string`&&props.formatter in knownUnits)return knownUnits[props.formatter].formatter(unit.value.value)}return typeof unit.value.formatter==`function`?unit.value.formatter(unit.value.value):unit.value.value}),props=__props;return(_ctx,_cache)=>(openBlock(),createBlock(unref(slotSwitcher_default),mergeProps(unref(attrs),{slotId:unit.value.type}),{money:withCtx(props$1=>[createVNode(unref(bngPropVal_default),mergeProps({...props$1,...unit.value},{iconType:props$1.iconType||unref(icons).beamCurrency,valueLabel:formattedValue.value}),null,16,[`iconType`,`valueLabel`])]),beamXP:withCtx(props$1=>[createVNode(unref(bngPropVal_default),mergeProps({...props$1,...unit.value},{iconType:props$1.iconType||unref(icons).beamXPLo,valueLabel:formattedValue.value}),null,16,[`iconType`,`valueLabel`])]),stars:withCtx(props$1=>[createVNode(unref(bngPropVal_default),mergeProps({...props$1,...unit.value},{iconType:props$1.iconType||unref(icons).star,valueLabel:formattedValue.value,"icon-color":defaultColors.stars}),null,16,[`iconType`,`valueLabel`,`icon-color`])]),vouchers:withCtx(props$1=>[createVNode(unref(bngPropVal_default),mergeProps({...props$1,...unit.value},{iconType:props$1.iconType||unref(icons).voucherHorizontal3,valueLabel:formattedValue.value,"icon-color":defaultColors.vouchers}),null,16,[`iconType`,`valueLabel`,`icon-color`])]),insuranceScore:withCtx(props$1=>[createVNode(unref(bngPropVal_default),mergeProps({...props$1,...unit.value},{iconType:props$1.iconType||unref(icons).shieldCheckmarkProgressbar,valueLabel:formattedValue.value}),null,16,[`iconType`,`valueLabel`])]),multiplier:withCtx(props$1=>[createVNode(unref(bngPropVal_default),mergeProps({...props$1,...unit.value},{iconType:props$1.iconType||unref(icons).mathMultiply,valueLabel:formattedValue.value,"icon-color":defaultColors.multiplier}),null,16,[`iconType`,`valueLabel`,`icon-color`])]),unknown:withCtx(props$1=>[createBaseVNode(`span`,normalizeProps(guardReactiveProps(props$1)),`BngUnit: Unknown unit type or no type specified`,16)]),_:1},16,[`slotId`]))}},bngUnit_default=_sfc_main$336;const DEMOS={};var base_exports=__export({ACCENTS:()=>ACCENTS,BngActionDrawer:()=>bngActionDrawer_default,BngActionsDrawer:()=>bngActionsDrawer_default,BngActionsDrawerOne:()=>bngActionsDrawerOne_default,BngActionsList:()=>bngActionsList_default,BngBinding:()=>bngBinding_default,BngBreadcrumbs:()=>bngBreadcrumbs_default,BngButton:()=>bngButton_default,BngCard:()=>bngCard_default,BngCardHeading:()=>bngCardHeading_default,BngColorPicker:()=>bngColorPicker_default,BngColorSlider:()=>bngColorSlider_default,BngColorTile:()=>bngColorTile_default,BngCondition:()=>bngCondition_default,BngControllerHint:()=>bngControllerHint_default,BngDivider:()=>bngDivider_default,BngDrawer:()=>bngDrawer_default,BngDrawerOld:()=>bngDrawerOld_default,BngDropdown:()=>bngDropdown_default,BngDropdownContainer:()=>bngDropdownContainer_default,BngIcon:()=>bngIcon_default,BngIconMarker:()=>bngIconMarker_default,BngImage:()=>bngImage_default,BngImageAsset:()=>bngImageAsset_default,BngImageCarousel:()=>bngImageCarousel_default,BngImageTile:()=>bngImageTile_default,BngInput:()=>bngInput_default,BngInputNew:()=>bngInputNew_default,BngList:()=>bngList_default,BngMainStars:()=>bngMainStars_default,BngMultilineInput:()=>bngMultilineInput_default,BngOldIcon:()=>bngOldIcon_default,BngOverflowContainer:()=>bngOverflowContainer_default,BngPaintTile:()=>bngPaintTile_default,BngPill:()=>bngPill_default,BngPillCheckbox:()=>bngPillCheckbox_default,BngPillFilters:()=>bngPillFilters_default,BngPillFiltersContainer:()=>bngPillFiltersContainer_default,BngPopoverContent:()=>bngPopoverContent_default,BngPopoverMenu:()=>bngPopoverMenu_default,BngProgressBar:()=>bngProgressBar_default,BngPropVal:()=>bngPropVal_default,BngScreenHeading:()=>bngScreenHeading_default,BngScreenHeadingV2:()=>bngScreenHeadingV2_default,BngSelect:()=>bngSelect_default,BngSimpleGraph:()=>bngSimpleGraph_default,BngSlider:()=>bngSlider_default,BngSmartSelect:()=>bngSmartSelect_default,BngSpriteIcon:()=>bngSpriteIcon_default,BngSwitch:()=>bngSwitch_default,BngSwitchOld:()=>bngSwitchOld_default,BngTile:()=>bngTile_default,BngTooltip:()=>bngTooltip_default,BngUnit:()=>bngUnit_default,DEMOS:()=>DEMOS,LABEL_ALIGNMENTS:()=>LABEL_ALIGNMENTS,LIST_LAYOUTS:()=>LIST_LAYOUTS,STEP_ICON_TYPES:()=>STEP_ICON_TYPES,getIconsWithTags:()=>getIconsWithTags,icons:()=>icons,iconsBySize:()=>iconsBySize,iconsByTag:()=>iconsByTag});function getPopupWrapperDefaults(){return{fade:!1,blur:!0,style:[popupContainer.default]}}function getActivityWrapperDefaults(){return{fade:!1,blur:!1,style:[popupContainer.clickthrough]}}const popupContainer=Object.freeze({default:`default`,transparent:`transparent`,clickthrough:`clickthrough`}),popupPosition=Object.freeze({default:`center`,top:`top`,left:`left`,right:`right`,bottom:`bottom`,center:`center`,fullscreen:`fullscreen`});var _hoisted_1$296=[`bng-ui-scope`],_hoisted_2$244={class:`popup-content`},_hoisted_3$217={key:0,class:`popup-title`},_hoisted_4$186={key:1,class:`popup-body`},_hoisted_5$159=[`innerHTML`],_hoisted_6$137={class:`popup-buttons`},__default__$10={wrapper:{blur:!0,style:null},position:popupPosition.center,animated:!0},_sfc_main$335=Object.assign(__default__$10,{__name:`Confirmation`,props:{appearance:String,popupActive:Boolean,message:{type:[String,Object],required:!0},title:String,buttons:Array},emits:[`return`],setup(__props,{emit:__emit}){useUINavBlocker().allowNavigationOnly();let props=__props,emit$1=__emit,scopeName=usePopupUINavScopeName(`_confirmPopup`,props),defaultButtonIndex=props.buttons.findIndex(button=>button.extras&&button.extras.default);defaultButtonIndex===-1&&(defaultButtonIndex=0);let cancelButton=props.buttons.find(button=>button.extras&&button.extras.cancel),exclude=[`default`,`cancel`],buttonProps=computed(()=>{let bp=[];for(let{extras}of props.buttons)extras?bp.push(Object.keys(extras).reduce((ex,key)=>exclude.includes(key)?ex:{...ex,[key]:extras[key]},{})):bp.push({});return bp}),messageIsComponent=computed(()=>props.message&&typeof props.message==`object`&&props.message.component),handleCancelWithBack=()=>emit$1(`return`,cancelButton?cancelButton.value:null);return(_ctx,_cache)=>withDirectives((openBlock(),createElementBlock(`div`,{class:normalizeClass([`popup`,`popup-style-`+__props.appearance]),"bng-ui-scope":unref(scopeName)},[createBaseVNode(`div`,_hoisted_2$244,[__props.title?(openBlock(),createElementBlock(`div`,_hoisted_3$217,toDisplayString(__props.title),1)):createCommentVNode(``,!0),messageIsComponent.value?(openBlock(),createElementBlock(`div`,_hoisted_4$186,[(openBlock(),createBlock(resolveDynamicComponent(__props.message.component),normalizeProps(guardReactiveProps(__props.message.props)),null,16))])):(openBlock(),createElementBlock(`div`,{key:2,class:`popup-body`,innerHTML:__props.message},null,8,_hoisted_5$159)),createBaseVNode(`div`,_hoisted_6$137,[(openBlock(!0),createElementBlock(Fragment,null,renderList(__props.buttons,(button,index)=>withDirectives((openBlock(),createBlock(unref(bngButton_default),mergeProps({key:index},{ref_for:!0},buttonProps.value[index],{onClick:$event=>_ctx.$emit(`return`,button.value)}),{default:withCtx(()=>[createTextVNode(toDisplayString(button.label),1)]),_:2},1040,[`onClick`])),[[unref(BngUiNavFocus_default),index===unref(defaultButtonIndex)?1e3:void 0]])),128))])])],10,_hoisted_1$296)),[[unref(BngOnUiNav_default),handleCancelWithBack,`back,menu`]])}}),Confirmation_default=__plugin_vue_export_helper_default(_sfc_main$335,[[`__scopeId`,`data-v-ce4a758b`]]),_hoisted_1$295=[`bng-ui-scope`],_hoisted_2$243={key:0,class:`form-dialog-toolbar`},_hoisted_3$216={class:`toolbar-title`},_hoisted_4$185={key:0,class:`content-description`},_hoisted_5$158={class:`content-wrapper`},_hoisted_6$136={class:`form-actions-bar`},_sfc_main$334={__name:`FormDialog`,props:mergeModels({title:{type:String},description:{type:String},view:{type:[Object,String],required:!0},formValidator:{type:Function,default:formModel=>!0},buttons:{type:Array,required:!0},maxWidth:{type:String,default:`40rem`}},{formModel:{},formModelModifiers:{}}),emits:mergeModels([`return`],[`update:formModel`]),setup(__props,{emit:__emit}){useUINavBlocker().allowOnly([`focus_u`,`focus_d`,`focus_l`,`focus_r`,`back`,`menu`,`ok`]);let props=__props,emit$1=__emit,formModel=useModel(__props,`formModel`),scopeName=usePopupUINavScopeName(`_formdialog`,props),handleCancelWithBack=()=>{let cancelButton=props.buttons.find(x=>x.extras&&x.extras.cancel);cancelButton?onClick(cancelButton):emit$1(`return`)},onClick=button=>{let data={value:button.value};button.emitData&&(data.formData=formModel.value),emit$1(`return`,data)},formValid=ref(!1),message=ref(null);return watch(formModel,()=>{let res=props.formValidator(formModel.value);message.value=res.error?res.message:props.description,formValid.value=!res.error},{immediate:!0,deep:!0}),(_ctx,_cache)=>withDirectives((openBlock(),createElementBlock(`div`,{class:`form-dialog`,style:normalizeStyle({maxWidth:props.maxWidth}),"bng-ui-scope":unref(scopeName)},[__props.title?(openBlock(),createElementBlock(`div`,_hoisted_2$243,[createBaseVNode(`div`,_hoisted_3$216,toDisplayString(__props.title),1)])):createCommentVNode(``,!0),createBaseVNode(`div`,{class:normalizeClass([{"no-title":!__props.title},`form-dialog-content`])},[message.value?(openBlock(),createElementBlock(`div`,_hoisted_4$185,toDisplayString(message.value),1)):createCommentVNode(``,!0),createBaseVNode(`div`,_hoisted_5$158,[(openBlock(),createBlock(resolveDynamicComponent(__props.view),{modelValue:formModel.value,"onUpdate:modelValue":_cache[0]||=$event=>formModel.value=$event},null,8,[`modelValue`]))])],2),createBaseVNode(`div`,_hoisted_6$136,[(openBlock(!0),createElementBlock(Fragment,null,renderList(__props.buttons,(button,index)=>withDirectives((openBlock(),createBlock(unref(bngButton_default),mergeProps({key:index},{ref_for:!0},button.extras,{disabled:button.disableIfInvalid&&!formValid.value,onClick:$event=>onClick(button)}),{default:withCtx(()=>[createTextVNode(toDisplayString(button.label),1)]),_:2},1040,[`disabled`,`onClick`])),[[unref(BngUiNavFocus_default),__props.buttons.length-index],[unref(BngFocusIf_default),index===0]])),128))])],12,_hoisted_1$295)),[[unref(BngOnUiNav_default),handleCancelWithBack,`back,menu`]])}},FormDialog_default=__plugin_vue_export_helper_default(_sfc_main$334,[[`__scopeId`,`data-v-e78a3aa6`]]),_hoisted_1$294=[`bng-ui-scope`],_hoisted_2$242={class:`popup-content`},_hoisted_3$215={key:0,class:`popup-title`},_hoisted_4$184={class:`popup-body`},_hoisted_5$157={key:0,class:`popup-message`},_hoisted_6$135={class:`popup-buttons`},_sfc_main$333={__name:`Progress`,props:{title:String,message:String,buttons:Array,indeterminate:Boolean,min:{type:Number,default:0},max:{type:Number,default:100},initialValue:{type:Number,default:0},valueLabelFormat:{type:[String,Function],default:()=>val=>`${val}%`},timeout:{type:Number,default:0},cancellable:Boolean,tunnel:Object},emits:[`return`],setup(__props,{emit:__emit}){useUINavBlocker().allowOnly([`focus_u`,`focus_d`,`focus_l`,`focus_r`,`back`,`menu`,`ok`]);let emit$1=__emit,DEFAULT_BUTTON_ID=uniqueId(`___DEFAULT`,`_`),props=__props,defaultButtonIndex=props.buttons.findIndex(button=>button.extras&&button.extras.default),cancelButton=props.buttons.find(button=>button.extras&&button.extras.cancel);~defaultButtonIndex&&onMounted(()=>{document.querySelector(`#${DEFAULT_BUTTON_ID}`).focus()});let scopeName=usePopupUINavScopeName(`_progressPopup`,props),progressValue=ref(props.initialValue),msg=ref(props.message),handleCancelWithBack=e=>{props.cancellable&&close()},close=()=>emit$1(`return`,cancelButton?cancelButton.value:null);return props.tunnel.update=(value,message=void 0)=>{progressValue.value=+value,message!==void 0&&(msg.value=message)},props.tunnel.done=close,props.tunnel.ready=!0,props.timeout&&setTimeout(close,props.timeout*1e3),(_ctx,_cache)=>withDirectives((openBlock(),createElementBlock(`div`,{class:normalizeClass([`popup`]),"bng-ui-scope":unref(scopeName)},[createBaseVNode(`div`,_hoisted_2$242,[__props.title?(openBlock(),createElementBlock(`div`,_hoisted_3$215,toDisplayString(__props.title),1)):createCommentVNode(``,!0),createBaseVNode(`div`,_hoisted_4$184,[msg.value?(openBlock(),createElementBlock(`div`,_hoisted_5$157,toDisplayString(msg.value),1)):createCommentVNode(``,!0),createVNode(unref(bngProgressBar_default),{value:progressValue.value,min:__props.min,max:__props.max,indeterminate:__props.indeterminate,"show-value-label":!__props.indeterminate&&!!__props.valueLabelFormat,"value-label-format":__props.valueLabelFormat},null,8,[`value`,`min`,`max`,`indeterminate`,`show-value-label`,`value-label-format`])]),createBaseVNode(`div`,_hoisted_6$135,[__props.buttons&&__props.buttons.length?(openBlock(!0),createElementBlock(Fragment,{key:0},renderList(__props.buttons,(button,index)=>(openBlock(),createBlock(unref(bngButton_default),mergeProps({key:index},{ref_for:!0},{...index==unref(defaultButtonIndex)&&{id:unref(DEFAULT_BUTTON_ID)},...button.extras},{onClick:$event=>_ctx.$emit(`return`,typeof button.value==`function`?button.value(_ctx.text):button.value)}),{default:withCtx(()=>[createTextVNode(toDisplayString(button.label),1)]),_:2},1040,[`onClick`]))),128)):createCommentVNode(``,!0)])])],8,_hoisted_1$294)),[[unref(BngOnUiNav_default),handleCancelWithBack,`back,menu`]])}},Progress_default=__plugin_vue_export_helper_default(_sfc_main$333,[[`__scopeId`,`data-v-a3c03360`]]),_hoisted_1$293=[`bng-ui-scope`],_hoisted_2$241={class:`popup-content`},_hoisted_3$214={key:0,class:`popup-title`},_hoisted_4$183={class:`popup-body`},_hoisted_5$156={key:0,class:`popup-message`},_hoisted_6$134={class:`popup-buttons`},_sfc_main$332={__name:`Prompt`,props:{buttons:Array,message:String,title:String,maxLength:Number,defaultValue:void 0,validate:Function,errorMessage:String,disableWhenInvalid:Boolean},emits:[`return`],setup(__props,{emit:__emit}){let emit$1=__emit,DEFAULT_BUTTON_ID=uniqueId(`___DEFAULT`,`_`),INPUT_ID=uniqueId(`___INPUT`,`_`),props=__props,scopeName=usePopupUINavScopeName(`_promptPopup`,props),text=ref(props.defaultValue||``),defaultButtonIndex=props.buttons.findIndex(button=>button.extras&&button.extras.default),cancelButton=props.buttons.find(button=>button.extras&&button.extras.cancel),handleEnterButton=text$1=>{props.disableWhenInvalid&&props.validate&&!props.validate(text$1)||emit$1(`return`,text$1)},handleCancelWithBack=e=>{emit$1(`return`,cancelButton?cancelButton.value:null)};return onMounted(()=>{document.querySelector(`#${INPUT_ID} input`).focus()}),(_ctx,_cache)=>withDirectives((openBlock(),createElementBlock(`div`,{class:normalizeClass([`popup`]),"bng-ui-scope":unref(scopeName)},[createBaseVNode(`div`,_hoisted_2$241,[__props.title?(openBlock(),createElementBlock(`div`,_hoisted_3$214,toDisplayString(__props.title),1)):createCommentVNode(``,!0),createBaseVNode(`div`,_hoisted_4$183,[__props.message?(openBlock(),createElementBlock(`div`,_hoisted_5$156,toDisplayString(__props.message),1)):createCommentVNode(``,!0),createVNode(unref(bngInput_default),{id:unref(INPUT_ID),modelValue:text.value,"onUpdate:modelValue":_cache[0]||=$event=>text.value=$event,maxlength:__props.maxLength,onKeyup:_cache[1]||=withKeys($event=>handleEnterButton(text.value),[`enter`]),validate:__props.validate,"error-message":__props.errorMessage},null,8,[`id`,`modelValue`,`maxlength`,`validate`,`error-message`])]),createBaseVNode(`div`,_hoisted_6$134,[(openBlock(!0),createElementBlock(Fragment,null,renderList(__props.buttons,(button,index)=>(openBlock(),createBlock(unref(bngButton_default),mergeProps({key:index},{ref_for:!0},{...index==unref(defaultButtonIndex)&&{id:unref(DEFAULT_BUTTON_ID)},...button.extras},{disabled:__props.disableWhenInvalid&&index>0&&__props.validate&&!__props.validate(text.value),onClick:$event=>_ctx.$emit(`return`,typeof button.value==`function`?button.value(text.value):button.value)}),{default:withCtx(()=>[createTextVNode(toDisplayString(button.label),1)]),_:2},1040,[`disabled`,`onClick`]))),128))])])],8,_hoisted_1$293)),[[unref(BngOnUiNav_default),handleCancelWithBack,`back,menu`]])}},Prompt_default=__plugin_vue_export_helper_default(_sfc_main$332,[[`__scopeId`,`data-v-cce4437b`]]),__default__$9={position:popupPosition.left},_sfc_main$331=Object.assign(__default__$9,{__name:`ScreenOverlay`,props:{view:Object},emits:[`return`],setup(__props){return(_ctx,_cache)=>(openBlock(),createBlock(resolveDynamicComponent(__props.view),{onClose:_cache[0]||=$event=>_ctx.$emit(`return`,!0)},null,32))}}),ScreenOverlay_default=_sfc_main$331,popup_components_exports=__export({Confirmation:()=>Confirmation_default,FormDialog:()=>FormDialog_default,Progress:()=>Progress_default,Prompt:()=>Prompt_default,ScreenOverlay:()=>ScreenOverlay_default}),popupLimit=5,activityLimit=3,count=-1;const PopupTypes=Object.freeze({activity:10,normal:100,priority:1e3});var PopupTypesBack=Object.freeze(Object.keys(PopupTypes).reduce((res,key)=>({...res,[String(PopupTypes[key])]:key}),{})),PopupTypesPairs=Object.freeze(Object.keys(PopupTypes).map(key=>[PopupTypes[key],key]).sort((a$1,b)=>a$1[0]-b[0]));function getPopupTypeName(type=PopupTypes.normal){let strType=String(type);if(strType in PopupTypesBack)return PopupTypesBack[strType];for(let[ptype,pname]of PopupTypesPairs)if(typepopupsAll.filter(itm=>itm.type>=PopupTypes.normal)),activitiesFiltered=computed(()=>popupsAll.filter(itm=>itm.typepopupsFiltered.value.length>0?popupsFiltered.value.slice(-popupLimit):null),popupsWrapper:computed(()=>accumulateWrapper(popupsFiltered.value,getPopupWrapperDefaults())),activities:computed(()=>activitiesFiltered.value.length>0?activitiesFiltered.value.slice(-activityLimit):null),activitiesWrapper:computed(()=>accumulateWrapper(activitiesFiltered.value,getActivityWrapperDefaults()))});function accumulateWrapper(popups,wrapper){for(let popup of popups)wrapper.fade!==popup.wrapper.fade&&(wrapper.fade=popup.wrapper.fade),wrapper.blur!==popup.wrapper.blur&&(wrapper.blur=popup.wrapper.blur),popup.wrapper.style&&wrapper.style.push(...popup.wrapper.style);return wrapper}function addPopup(componentOrName,props={},type=PopupTypes.normal){let component=typeof componentOrName==`string`?popup_components_exports[componentOrName]:componentOrName;if(!component)throw Error(`There is no popup base component named "${componentOrName}".Available components: "${Object.keys(popup_components_exports).join(`", "`)}"`);let popup={id:++count,active:!1,type,typeName:getPopupTypeName(type),component:markRaw({ref:component}),componentName:component.__name,props:{__id:count,...props},position:[popupPosition.default],animated:!0,wrapper:type>=PopupTypes.normal?getPopupWrapperDefaults():getActivityWrapperDefaults()};component.position&&(popup.position=Array.isArray(component.position)?component.position:[component.position]),typeof component.animated==`boolean`&&(popup.animated=component.animated),`wrapper`in component&&(typeof component.wrapper.fade==`boolean`&&(popup.wrapper.fade=component.wrapper.fade),typeof component.wrapper.blur==`boolean`&&(popup.wrapper.blur=component.wrapper.blur),component.wrapper.style&&(popup.wrapper.style=Array.isArray(component.wrapper.style)?component.wrapper.style:[component.wrapper.style])),popup.promise=new Promise((resolve$1,reject)=>{popup._resolve=resolve$1,popup._reject=reject}),popup.return=result=>{for(let i=0;i0&&(popupsAll[popupsAll.length-1].active=!0),reportPopupState(popup,!1);break}result===void 0?popup._reject():popup._resolve(result)},popup.promise.close=popup.return;for(let i=0;itype)return popupsAll.splice(i,0,popup),reportPopupState(popup,!0),popup;return popupsAll.length>0&&(popupsAll[popupsAll.length-1].active=!1),popup.active=!0,popupsAll.push(popup),reportPopupState(popup,!0),popup}function closeLastPopups(count$1=1){popupsAll.slice(-count$1).forEach(popup=>popup.return())}const openMessage=(title,message)=>addPopup(`Confirmation`,{title,message,buttons:[{label:$translate.instant(`ui.common.okay`),value:!0,extras:{default:!0}}]}).promise,openConfirmation=(title,message,buttons=[{label:$translate.instant(`ui.common.okay`),value:!0,extras:{default:!0}},{label:$translate.instant(`ui.common.cancel`),value:!1,extras:{cancel:!0,accent:ACCENTS.secondary}}],appearance=``)=>addPopup(`Confirmation`,{title,message,buttons,appearance}).promise,openPrompt=(message=``,title=``,{buttons=[{label:$translate.instant(`ui.common.okay`),value:text=>text},{label:$translate.instant(`ui.common.cancel`),value:!1,extras:{cancel:!0,accent:ACCENTS.secondary}}],defaultValue,maxLength,validate,errorMessage,disableWhenInvalid}={})=>addPopup(`Prompt`,{message,title,buttons,defaultValue,maxLength,validate,errorMessage,disableWhenInvalid}).promise,openExperimental=(title,message,buttons=[{label:$translate.instant(`ui.common.yes`),value:!0},{label:$translate.instant(`ui.common.no`),value:!1}])=>addPopup(`Confirmation`,{title,message,buttons,appearance:`experimental`}).promise,openScreenOverlay=component=>addPopup(`ScreenOverlay`,{view:markRaw(component)},PopupTypes.activity).promise,openFormDialog=(component,formModel,formValidator,title,description,buttons=[{label:$translate.instant(`ui.common.okay`),value:!0,emitData:!0},{label:$translate.instant(`ui.common.cancel`),value:!1,extras:{cancel:!0,accent:ACCENTS.secondary}}],maxWidth)=>addPopup(`FormDialog`,{view:markRaw(component),formModel,formValidator,title,description,buttons,maxWidth},PopupTypes.normal).promise,openProgress=(message=``,title=``,{buttons=[],indeterminate,min:min$1,max:max$1,initialValue,valueLabelFormat,timeout,cancellable}={})=>{let popup=addPopup(`Progress`,{message,title,buttons,indeterminate,min:min$1,max:max$1,initialValue,valueLabelFormat,timeout,cancellable,tunnel:{}});return popup.progress=popup.props.tunnel,popup.progress.done=popup.return,popup},fixedDelayPopup=(seconds,{makeRemainingText=s=>s?Math.round(s)+`s remaining...`:`Done!`,title=``}={})=>{let popup=openProgress(makeRemainingText(seconds),title,{timeout:seconds+1}),remaining=seconds,endTime=Date.now()+remaining*1e3,countdown=()=>{let timeLeft=(endTime-Date.now())/1e3;timeLeft>0?(remaining=timeLeft,requestAnimationFrame(countdown)):remaining=0,popup.progress.update(~~((seconds-remaining)*100/seconds),makeRemainingText(remaining))};return requestAnimationFrame(countdown),popup};var _hoisted_1$292={class:`activity-selector`},_hoisted_2$240={class:`activities-container`},_hoisted_3$213=[`onClick`],_hoisted_4$182={class:`selector-display`},selectConfig={label:x=>x.label,value:x=>x.value},_sfc_main$330={__name:`ActivitySelector`,props:{activities:{type:Array,required:!0},value:{type:[String,Number]},navLeftEvent:{type:String},navRightEvent:{type:String}},emits:[`valueChanged`],setup(__props,{expose:__expose,emit:__emit}){let props=__props,selectComponent=ref(),emit$1=__emit,activityOptions=computed(()=>props.activities.map((x,index)=>({label:index+1,value:x.value})));computed(()=>(activityOptions.value?activityOptions.value.find(x=>x.value===selectedValue.value):null)||{label:`?`,value:selectedValue.value});let selectedValue=ref(1);watch(()=>props.value,val=>selectedValue.value=val||props.activities[0].value,{immediate:!0});let onValueChanged=value=>{selectedValue.value=value,console.log(`onValueChanged`,value),emit$1(`valueChanged`,value)};return __expose({goNext:()=>selectComponent.value.goNext(),goPrev:()=>selectComponent.value.goPrev()}),computed(()=>`url("${getAssetURL(`icons/temp_debug/map_poi_target.svg`)}")`),(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$292,[createBaseVNode(`div`,_hoisted_2$240,[(openBlock(!0),createElementBlock(Fragment,null,renderList(__props.activities,activity=>(openBlock(),createElementBlock(`div`,{key:activity,class:normalizeClass([`activity-icon`,{highlighted:activity.value===selectedValue.value}]),onClick:$event=>onValueChanged(activity.value)},[createVNode(unref(bngSpriteIcon_default),{src:`map_`+activity.icon,style:{width:`100%`,height:`100%`}},null,8,[`src`])],10,_hoisted_3$213))),128))]),createVNode(unref(bngSelect_default),{ref_key:`selectComponent`,ref:selectComponent,value:selectedValue.value,options:activityOptions.value,config:selectConfig,mute:``,loop:``,onChange:onValueChanged,navLeftEvent:__props.navLeftEvent,navRightEvent:__props.navRightEvent},{display:withCtx(({label})=>[createBaseVNode(`div`,_hoisted_4$182,[createBaseVNode(`span`,null,toDisplayString(label),1),createVNode(unref(bngDivider_default)),createBaseVNode(`span`,null,toDisplayString(__props.activities.length),1)])]),_:1},8,[`value`,`options`,`navLeftEvent`,`navRightEvent`])]))}},ActivitySelector_default=__plugin_vue_export_helper_default(_sfc_main$330,[[`__scopeId`,`data-v-53fb9327`]]),_hoisted_1$291={key:0,class:`activity-start`,"bng-ui-scope":`activityStart`},_hoisted_2$239={class:`activity-props`},_hoisted_3$212={class:`binding-spacer`},BNG_MAIN_STARS_TYPE=`BngMainStars`,_sfc_main$329={__name:`ActivityStart`,setup(__props){useUINavScope(`activityStart`);let activitySelector=ref(null),goNext=()=>activitySelector.value&&activitySelector.value.goNext(),goPrev=()=>activitySelector.value&&activitySelector.value.goPrev(),gameContextStore=useGameContextStore(),{activities}=storeToRefs(gameContextStore),{closeActivitiesPrompt}=gameContextStore,selectedActivityIndex=ref(0),availableActivities=ref([]),activityOptions=computed(()=>{let result=availableActivities.value?availableActivities.value.map((x,index)=>({id:index,value:index,icon:x.icon})):[];return doFiltering&&filterEvents(result.length>1),result}),selectedActivity=computed(()=>{if(selectedActivityIndex.value<0||!availableActivities.value||availableActivities.value.length===0)return null;let activity=availableActivities.value[selectedActivityIndex.value],labels=activity.props&&activity.props.length>0?activity.props.filter(x=>!x.type):[];return{heading:activity.heading,icon:activity.icon,preheadings:activity.preheadings,labels:labels.map(x=>({keyLabel:$translate.instant(x.keyLabel),valueLabel:$translate.instant(x.valueLabel),icon:icons[x.icon]})),stars:activity.props&&activity.props.length>0?activity.props.find(x=>x.type===BNG_MAIN_STARS_TYPE):null,startable:!0,buttonLabel:activity.buttonLabel,action:activity.action,missionInfoPerformActionIndex:activity.missionInfoPerformActionIndex}}),preheadings=computed(()=>selectedActivity.value&&selectedActivity.value.preheadings?selectedActivity.value.preheadings.map(x=>$translate.contextTranslate(x)):[]),invokeActivityAction=()=>{Lua_default.ui_missionInfo.performActivityAction(selectedActivity.value.missionInfoPerformActionIndex)};watch(selectedActivity,()=>{Lua_default.ui_missionInfo.setActivityIndexVisible(selectedActivityIndex.value)});let onActivitySelected=value=>{selectedActivityIndex.value=value},onCancel=()=>{closeActivitiesPrompt()},openPauseMenu=()=>{onCancel(),window.globalAngularRootScope&&window.globalAngularRootScope.$broadcast(`MenuToggle`)};onBeforeMount(()=>{availableActivities.value=activities.value}),onMounted(()=>{getUINavServiceInstance().activate()}),onUnmounted(()=>{doFiltering=!1,getUINavServiceInstance().setFilteredEventsAllExcept(UI_EVENTS.menu,UI_EVENTS.pause,UI_EVENTS.center_cam),Lua_default.ui_missionInfo.setActivityIndexVisible(-1)});let doFiltering=!0,filterEvents=withTabs=>getUINavServiceInstance().setFilteredEventsAllExcept(UI_EVENTS.back,UI_EVENTS.menu,UI_EVENTS.pause,UI_EVENTS.center_cam,...withTabs?[UI_EVENTS.tab_l,UI_EVENTS.tab_r]:[]);return(_ctx,_cache)=>selectedActivity.value?withDirectives((openBlock(),createElementBlock(`div`,_hoisted_1$291,[activityOptions.value&&activityOptions.value.length>1?(openBlock(),createBlock(ActivitySelector_default,{key:0,ref_key:`activitySelector`,ref:activitySelector,activities:activityOptions.value,value:selectedActivityIndex.value,onValueChanged:onActivitySelected,navLeftEvent:`tab_l`,navRightEvent:`tab_r`},null,8,[`activities`,`value`])):createCommentVNode(``,!0),selectedActivity.value.heading?(openBlock(),createBlock(unref(bngScreenHeading_default),{key:1,mute:``,divider:``,preheadings:preheadings.value,"blur-delay":400},{default:withCtx(()=>[createTextVNode(toDisplayString(_ctx.$ctx_t(selectedActivity.value.heading)),1),selectedActivity.value.description?(openBlock(),createElementBlock(Fragment,{key:0},[createTextVNode(`: `+toDisplayString(_ctx.$ctx_t(selectedActivity.value.description)),1)],64)):createCommentVNode(``,!0)]),_:1},8,[`preheadings`])):createCommentVNode(``,!0),createBaseVNode(`div`,_hoisted_2$239,[selectedActivity.value.stars&&selectedActivity.value.stars.defaultStarCount?(openBlock(),createBlock(unref(bngMainStars_default),{key:0,"unlocked-stars":selectedActivity.value.stars.defaultUnlockedStarCount,"total-stars":selectedActivity.value.stars.defaultStarCount,class:`main-stars`},null,8,[`unlocked-stars`,`total-stars`])):createCommentVNode(``,!0),selectedActivity.value.stars&&selectedActivity.value.stars.bonusStarCount?(openBlock(),createBlock(unref(bngMainStars_default),{key:1,"unlocked-stars":selectedActivity.value.stars.bonusStarsUnlockedCount,"total-stars":selectedActivity.value.stars.bonusStarCount,class:`bonus-stars`},null,8,[`unlocked-stars`,`total-stars`])):createCommentVNode(``,!0),(openBlock(!0),createElementBlock(Fragment,null,renderList(selectedActivity.value.labels,(label,index)=>(openBlock(),createBlock(unref(bngPropVal_default),{key:index,iconType:label.icon,keyLabel:label.keyLabel,valueLabel:label.valueLabel},null,8,[`iconType`,`keyLabel`,`valueLabel`]))),128))]),createBaseVNode(`div`,null,[withDirectives((openBlock(),createBlock(unref(bngButton_default),{accent:unref(ACCENTS).main,onClick:invokeActivityAction},{default:withCtx(()=>[createBaseVNode(`span`,_hoisted_3$212,[createVNode(unref(bngBinding_default),{action:`gameplay_interact`})]),selectedActivity.value.startable?(openBlock(),createElementBlock(Fragment,{key:0},[createTextVNode(toDisplayString(_ctx.$ctx_t(selectedActivity.value.buttonLabel)),1)],64)):(openBlock(),createElementBlock(Fragment,{key:1},[createTextVNode(toDisplayString(_ctx.$tt(`ui.mission.action.locked`)),1)],64))]),_:1},8,[`accent`])),[[unref(BngOnUiNav_default),void 0,`gameplay_interact`,{asMouse:!0}]]),withDirectives((openBlock(),createBlock(unref(bngButton_default),{accent:unref(ACCENTS).secondary,onClick:onCancel},{default:withCtx(()=>[createVNode(unref(bngBinding_default),{"ui-event":`back`,controller:``}),createTextVNode(` `+toDisplayString(_ctx.$tt(`ui.common.close`)),1)]),_:1},8,[`accent`])),[[unref(BngOnUiNav_default),void 0,`back`,{asMouse:!0}]])])])),[[unref(BngOnUiNav_default),goPrev,`tab_l`,{up:!0}],[unref(BngOnUiNav_default),goNext,`tab_r`,{up:!0}],[unref(BngOnUiNav_default),openPauseMenu,`menu`]]):createCommentVNode(``,!0)}},ActivityStart_default=__plugin_vue_export_helper_default(_sfc_main$329,[[`__scopeId`,`data-v-1f131cb6`]]),_hoisted_1$290={class:`recovery-wrapper`,"bng-ui-scope":`recoveryPrompt`},_hoisted_2$238={class:`content`},_hoisted_3$211={class:`label`},_hoisted_4$181={key:0,class:`more-options`},_hoisted_5$155={key:0,class:`notification`},__default__$8={wrapper:{fade:!0,blur:!0,style:popupContainer.transparent},position:[popupPosition.center,popupPosition.center]},_sfc_main$328=Object.assign(__default__$8,{__name:`Recovery`,emits:[`return`],setup(__props,{emit:__emit}){let{events:events$3}=useBridge();useUINavScope(`recoveryPrompt`);let emit$1=__emit,{closeRecoveryPrompt}=useGameContextStore(),popupData=ref({}),clickHandler=(index,button,fromController)=>{button.confirmationText||executeButtonAction(index,button)},executeButtonAction=(index,button)=>{Lua_default.core_recoveryPrompt.uiPopupButtonPressed(index+1),button.keepMenuOpen||(closeRecoveryPrompt(),emit$1(`return`,!0))},cancelClickHandler=()=>{Lua_default.core_recoveryPrompt.uiPopupCancelPressed(),popupData.value.cancelButton.keepMenuOpen||(closeRecoveryPrompt(),emit$1(`return`,!0))},updateRecoveryPopupData=()=>{Lua_default.core_recoveryPrompt.getUIData().then(value=>popupData.value=value)};return events$3.on(`updateRecoveryPopupData`,updateRecoveryPopupData),onMounted(()=>{getUINavServiceInstance().activate(),getUINavServiceInstance().clearFilteredEvents(),updateRecoveryPopupData()}),onUnmounted(()=>{events$3.off(`updateRecoveryPopupData`,updateRecoveryPopupData),window.bngVue.getCurrentRoute().name==`unknown`&&getUINavServiceInstance().setFilteredEventsAllExcept(UI_EVENTS.menu,UI_EVENTS.pause,UI_EVENTS.center_cam)}),(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$290,[createVNode(unref(bngCard_default),null,{buttons:withCtx(()=>[unref(popupData).cancelButton?withDirectives((openBlock(),createBlock(unref(bngButton_default),{key:0,label:unref(popupData).cancelButton.label,accent:unref(ACCENTS).attention,onClick:cancelClickHandler},null,8,[`label`,`accent`])),[[unref(BngOnUiNav_default),void 0,`back,menu`,{asMouse:!0}]]):createCommentVNode(``,!0)]),default:withCtx(()=>[createVNode(unref(bngCardHeading_default),{type:`ribbon`},{default:withCtx(()=>[createTextVNode(toDisplayString(unref(popupData).title),1)]),_:1}),createBaseVNode(`div`,_hoisted_2$238,[(openBlock(!0),createElementBlock(Fragment,null,renderList(unref(popupData).buttons,(button,index)=>withDirectives((openBlock(),createBlock(unref(bngButton_default),{"show-hold":!!button.confirmationText,"hold-vertical":``,accent:unref(ACCENTS).outlined,class:`recovery-option-button`},{default:withCtx(()=>[createVNode(unref(bngImageTile_default),{class:`recovery-option-tile`,icon:unref(icons)[button.icon]},{default:withCtx(()=>[createBaseVNode(`span`,_hoisted_3$211,toDisplayString(_ctx.$ctx_t(button.label)),1),button.price?(openBlock(),createBlock(unref(bngDivider_default),{key:0})):createCommentVNode(``,!0),button.price?(openBlock(),createBlock(unref(bngUnit_default),{key:1,class:`units`,money:button.price.money.amount,options:{formatter:x=>~~x}},null,8,[`money`,`options`])):createCommentVNode(``,!0)]),_:2},1032,[`icon`]),button.keepMenuOpen?(openBlock(),createElementBlock(`span`,_hoisted_4$181,`⇢`)):createCommentVNode(``,!0)]),_:2},1032,[`show-hold`,`accent`])),[[unref(BngDisabled_default),!button.enabled],[unref(BngFocusIf_default),!index||button.enabled&&!unref(popupData).buttons[0].enabled],[unref(BngOnUiNav_default),void 0,`ok`,{asMouse:!0,focusRequired:!0}],[unref(BngClick_default),{clickCallback:e=>clickHandler(index,button,e.fromController),holdCallback:button.confirmationText?()=>executeButtonAction(index,button):null,holdDelay:500,repeatInterval:0}]])),256)),unref(popupData).warningMessage?(openBlock(),createElementBlock(`div`,_hoisted_5$155,toDisplayString(unref(popupData).warningMessage),1)):createCommentVNode(``,!0)])]),_:1})]))}}),Recovery_default=__plugin_vue_export_helper_default(_sfc_main$328,[[`__scopeId`,`data-v-8495e64c`]]),_hoisted_1$289={class:`item-container`,navigable:``,tabindex:`0`},_hoisted_2$237={class:`item-content`},_hoisted_3$210={class:`item-container indented`,navigable:``,tabindex:`0`},_hoisted_4$180={class:`item-content`},_sfc_main$327={__name:`FavoriteSelectionItem`,props:{data:Object,level:{type:Number,default:0}},emits:[`addedFunction`,`removedFunction`],setup(__props,{emit:__emit}){let emit$1=__emit,expandedStates=ref({}),focusedItem=ref(null),toggleExpanded=(idx,value)=>{expandedStates.value[idx]=value},select=item=>{focusedItem.value=item},deselect=item=>{focusedItem.value===item&&(focusedItem.value=null)},isFocused=item=>focusedItem.value===item,addActionToQuickAccess=item=>{console.log(`addActionToQuickAccess`,item),item&&item.uniqueID&&emit$1(`addedFunction`,item)},removeFunction=()=>{emit$1(`removedFunction`)};return(_ctx,_cache)=>{let _component_FavoriteSelectionItem=resolveComponent(`FavoriteSelectionItem`,!0);return openBlock(),createBlock(unref(accordion_default),{class:`favorite-selection-item`,expanded:__props.data.expanded},{default:withCtx(()=>[(openBlock(!0),createElementBlock(Fragment,null,renderList(__props.data.items,(item,idx)=>(openBlock(),createElementBlock(`div`,{key:idx,class:`item-wrapper`},[item.items?(openBlock(),createBlock(unref(accordionItem_default),{key:0,navigable:``,static:!item.items,expanded:expandedStates.value[idx],onExpanded:$event=>toggleExpanded(idx,$event),"arrow-big":``,onMouseover:withModifiers($event=>select(item),[`stop`]),onMouseleave:withModifiers($event=>deselect(item),[`stop`]),onFocusin:withModifiers($event=>select(item),[`stop`]),onFocusout:withModifiers($event=>deselect(item),[`stop`]),"primary-action":()=>addActionToQuickAccess(item),"primary-label":`ui.inputActions.menu.menu_item_select.title`,"expand-hint-inline":``},{caption:withCtx(()=>[createBaseVNode(`div`,_hoisted_1$289,[createBaseVNode(`div`,_hoisted_2$237,[createVNode(unref(bngIcon_default),{type:unref(icons)[item.icon]},null,8,[`type`]),createTextVNode(` `+toDisplayString(item.title?unref($translate).instant(item.title):item.niceName),1)]),item.uniqueID&&isFocused(item)?(openBlock(),createBlock(unref(bngButton_default),{key:0,accent:`outlined`,class:`select-button`,onClick:$event=>addActionToQuickAccess(item),"bng-no-nav":``},{default:withCtx(()=>[createVNode(unref(bngBinding_default),{class:`input-icon`,"ui-event":`ok`,controller:``}),_cache[0]||=createTextVNode(` Select `,-1)]),_:1},8,[`onClick`])):createCommentVNode(``,!0)])]),default:withCtx(()=>[createVNode(_component_FavoriteSelectionItem,{data:item,level:__props.level+1,onAddedFunction:addActionToQuickAccess,onRemovedFunction:removeFunction},null,8,[`data`,`level`])]),_:2},1032,[`static`,`expanded`,`onExpanded`,`onMouseover`,`onMouseleave`,`onFocusin`,`onFocusout`,`primary-action`])):(openBlock(),createBlock(unref(accordionItem_default),{key:1,static:!0,navigable:``,onMouseover:withModifiers($event=>select(item),[`stop`]),onMouseleave:withModifiers($event=>deselect(item),[`stop`]),onFocusin:withModifiers($event=>select(item),[`stop`]),onFocusout:withModifiers($event=>deselect(item),[`stop`]),"primary-action":()=>addActionToQuickAccess(item),"primary-label":`ui.inputActions.menu.menu_item_select.title`},{caption:withCtx(()=>[createBaseVNode(`div`,_hoisted_3$210,[createBaseVNode(`div`,_hoisted_4$180,[item.icon?(openBlock(),createBlock(unref(bngIcon_default),{key:0,type:unref(icons)[item.icon]},null,8,[`type`])):createCommentVNode(``,!0),createTextVNode(` `+toDisplayString(unref($translate).instant(item.title)),1)]),item.uniqueID&&isFocused(item)?(openBlock(),createBlock(unref(bngButton_default),{key:0,class:`select-button`,onClick:$event=>addActionToQuickAccess(item),accent:`outlined`,"bng-no-nav":``},{default:withCtx(()=>[createVNode(unref(bngBinding_default),{class:`input-icon`,"ui-event":`ok`,controller:``}),_cache[1]||=createTextVNode(` Select `,-1)]),_:1},8,[`onClick`])):createCommentVNode(``,!0)])]),_:2},1032,[`onMouseover`,`onMouseleave`,`onFocusin`,`onFocusout`,`primary-action`]))]))),128))]),_:1},8,[`expanded`])}}},FavoriteSelectionItem_default=__plugin_vue_export_helper_default(_sfc_main$327,[[`__scopeId`,`data-v-dd594aec`]]),_hoisted_1$288={class:`backgroundContainer`},_hoisted_2$236={key:0,class:`recovery-wrapper`,"bng-ui-scope":`favoriteSelection`},_hoisted_3$209={class:`current-action-container`},_hoisted_4$179={key:0},_hoisted_5$154={key:1},_hoisted_6$133={key:2},_hoisted_7$119={key:0,class:`content`},__default__$7={wrapper:{fade:!0,blur:!0,style:popupContainer.transparent},position:[popupPosition.center,popupPosition.center]},_sfc_main$326=Object.assign(__default__$7,{__name:`FavoriteSelection`,emits:[`return`],setup(__props,{emit:__emit}){let{events:events$3}=useBridge();useUINavScope(`favoriteSelection`);let emit$1=__emit,{closeRecoveryPrompt}=useGameContextStore(),data=ref({}),updateFavoritePopupData=()=>{Lua_default.core_quickAccess.getDynamicSlotConfigurationData().then(value=>data.value=value)};events$3.on(`radialFavoriteSelectionPopupData`,updateFavoritePopupData);let addedFunction=item=>{let config={uniqueID:item.uniqueID,level:item.level,type:item.type,mode:item.mode||`uniqueAction`};console.log(`addedFunction`,config),Lua_default.core_quickAccess.setDynamicSlotConfiguration(data.value.dynamicSlotKey,config),emit$1(`return`,!0)},removeFunction=()=>{Lua_default.core_quickAccess.removeActionFromQuickAccess(data.value.slotIndex),emit$1(`return`,!0)},close=()=>{emit$1(`return`,!0)};return onMounted(()=>{updateFavoritePopupData()}),onUnmounted(()=>{events$3.off(`radialFavoriteSelectionPopupData`,updateFavoritePopupData),window.bngVue.getCurrentRoute().name==`unknown`&&getUINavServiceInstance().setFilteredEventsAllExcept(UI_EVENTS.menu,UI_EVENTS.pause,UI_EVENTS.center_cam)}),(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$288,[unref(data).dynamicSlotKey?(openBlock(),createElementBlock(`div`,_hoisted_2$236,[createVNode(unref(bngCard_default),null,{default:withCtx(()=>[createVNode(unref(bngCardHeading_default),{type:`ribbon`},{default:withCtx(()=>[createTextVNode(` Assign Action to: `+toDisplayString(unref(data).dynamicSlotData.breadcrumbs[0]),1)]),_:1}),createBaseVNode(`div`,_hoisted_3$209,[_cache[3]||=createBaseVNode(`div`,{class:`current-action-label`},`Currently Assigned Action:`,-1),unref(data).dynamicSlotData.mode===`uniqueAction`&&unref(data).uniqueAction?(openBlock(),createElementBlock(`div`,_hoisted_4$179,[unref(data).uniqueAction.icon?(openBlock(),createBlock(unref(bngIcon_default),{key:0,type:unref(icons)[unref(data).uniqueAction.icon]},null,8,[`type`])):createCommentVNode(``,!0),createTextVNode(` `+toDisplayString(unref(data).uniqueAction.title?unref($translate).instant(unref(data).uniqueAction.title):unref(data).uniqueAction.niceName),1)])):createCommentVNode(``,!0),unref(data).dynamicSlotData.mode===`recentActions`?(openBlock(),createElementBlock(`div`,_hoisted_5$154,[createVNode(unref(bngIcon_default),{type:unref(icons).timer},null,8,[`type`]),_cache[1]||=createTextVNode(` Most Recent Action `,-1)])):createCommentVNode(``,!0),unref(data).dynamicSlotData.mode===`empty`?(openBlock(),createElementBlock(`div`,_hoisted_6$133,[createVNode(unref(bngIcon_default),{type:unref(icons).circleSlashed},null,8,[`type`]),_cache[2]||=createTextVNode(` Empty `,-1)])):createCommentVNode(``,!0)]),_cache[5]||=createBaseVNode(`div`,{class:`divider`},null,-1),unref(data).items?(openBlock(),createElementBlock(`div`,_hoisted_7$119,[createVNode(FavoriteSelectionItem_default,{data:unref(data).items,onAddedFunction:addedFunction,onRemovedFunction:removeFunction},null,8,[`data`])])):createCommentVNode(``,!0),withDirectives((openBlock(),createBlock(unref(bngButton_default),{class:`cancel-button`,onClick:_cache[0]||=$event=>close(),accent:`attention`},{default:withCtx(()=>[createVNode(unref(bngBinding_default),{class:`input-icon`,"ui-event":`back`,controller:``}),_cache[4]||=createTextVNode(` Cancel `,-1)]),_:1})),[[unref(BngOnUiNav_default),void 0,`back,menu`,{asMouse:!0}]])]),_:1})])):createCommentVNode(``,!0)]))}}),FavoriteSelection_default=__plugin_vue_export_helper_default(_sfc_main$326,[[`__scopeId`,`data-v-88390882`]]);const useGameContextStore=defineStore(`gameContext`,()=>{let{events:events$3}=useBridge(),activities=ref([]),activityScreen=null,recoveryPrompt=null,radialFavoriteSelectionPrompt=null,deliveryEndScreen=null,simpleDelayPopup=null,startMission=missionId=>{let mission=activities.value.find(x=>x.id===missionId);mission||console.error(`Mission not found ${missionId}. cannot start`);let settings$1=mission.settings,userSettings=mission&&settings$1?settings$1.reduce((a$1,b)=>a$1[b.key]=b.value,a):{};Lua_default.gameplay_markerInteraction.startMissionById(mission.id,userSettings)},closeActivitiesPrompt=()=>{Lua_default.gameplay_markerInteraction.closeViewDetailPrompt(!0)};function openRecoveryPrompt(){recoveryPrompt=addPopup(Recovery_default).promise}function openDynamicSlotConfigurator(){radialFavoriteSelectionPrompt=addPopup(FavoriteSelection_default).promise}function openSimpleDelayPopup(data){simpleDelayPopup=fixedDelayPopup(data.timer,{title:data.heading})}let performActivityAction=activityActionIndex=>Lua_default.ui_missionInfo.performActivityAction(activityActionIndex);events$3.on(`ActivityAcceptUpdate`,onActivityAcceptUpdate),events$3.on(`ActivityAcceptClose`,closeActivitiesPopup),events$3.on(`MenuOpenModule`,closeActivitiesPopup),events$3.on(`ChangeState`,closeActivitiesPopup),events$3.on(`OpenRecoveryPrompt`,openRecoveryPrompt),events$3.on(`OpenDynamicSlotConfigurator`,openDynamicSlotConfigurator),events$3.on(`OpenSimpleDelayPopup`,openSimpleDelayPopup);let deliveryRewardData=ref(!1);function showDeliveryEndScreen(data){deliveryRewardData.value=data,window.bngVue.gotoGameState(`cargoDeliveryReward`)}events$3.on(`OpenDeliveryEndScreen`,showDeliveryEndScreen);function onActivityAcceptUpdate(data){activityScreen&&(activities.value||!data)&&closeActivitiesPopup(),window.location.hash===`#/play`&&(activities.value=data,activities.value&&activities.value.length>0&&(activityScreen=openScreenOverlay(ActivityStart_default)))}function closeActivitiesPopup(){activityScreen&&=(activityScreen.close(!0),null)}function closeRecoveryPrompt(){recoveryPrompt&&=(recoveryPrompt.close(!0),null)}function closeRadialFavoriteSelectionPrompt(){radialFavoriteSelectionPrompt&&=(radialFavoriteSelectionPrompt.close(!0),null)}function closeSimpleDelayPopup(){simpleDelayPopup&&=(simpleDelayPopup.progress.done(),null)}function closeDeliveryEndScreen(){deliveryEndScreen&&=(deliveryEndScreen.close(!0),null)}function dispose$2(){events$3.off(`ActivityAcceptUpdate`,onActivityAcceptUpdate),events$3.off(`ActivityAcceptClose`,closeActivitiesPopup)}return{activities,closeActivitiesPrompt,closeDeliveryEndScreen,closeRecoveryPrompt,closeRadialFavoriteSelectionPrompt,closeSimpleDelayPopup,deliveryRewardData,dispose:dispose$2,performActivityAction,startMission}});var PARSE_NESTED$1=`PARSE_NESTED`,bbcode_main_default=[[/\[url=https?:\/\/([^\s\]]+)\](.*?(?=\[\/url\]))\[\/url\]/gi,`$2`],[/\[url='https?:\/\/([^\s\]]+)'\](.*?(?=\[\/url\]))\[\/url\]/gi,`$2`],[/\[forumurl=https?:\/\/([^\s\]]+)\](\S*?(?=\[\/forumurl\]))\[\/forumurl\]/gi,`$2`],[/\[url\]https?:\/\/(.*?(?=\[\/url\]))\[\/url\]/gi,`$1`],[/\[url=([^\s\]]+)\](.*?(?=\[\/url\]))\[\/url\]/gi,`$2`],[/\[h(\d)\](.*?(?=\[\/h\d\]))\[\/h\d\]/gi,`$2`],[/\[img\]\s*?(\S*?(?=\[\/img\]))\[\/img\]/gi,``],[/\shttp(s|):\/\/(\S*)/gi,`http$1://$2`],[/\[list=\d+\](.*?(?=\[\/list\]))\[\/list\]/gi,`
      $1
    `],[/\[list\]/gi,`
      `],[/\[\/list\]/gi,`
    `],[/\[olist\]/gi,`
      `],[/\[\/olist\]/gi,`
    `],[/\[(\*|\+)\]\s*?((.|\s)*?(?=\[(\*|\+)\]|\<\/ul\>|\<\/ol\>|\n\n|$))/gim,`
  • $2
  • `],[PARSE_NESTED$1,/\[b\](.*?(?=\[\/b\]))\[\/b\]/gi,`$1`],[PARSE_NESTED$1,/\[u\](.*?(?=\[\/u\]))\[\/u\]/gi,`$1`],[PARSE_NESTED$1,/\[s\](.*?(?=\[\/s\]))\[\/s\]/gi,`$1`],[PARSE_NESTED$1,/\[i\](.*?(?=\[\/i\]))\[\/i\]/gi,`$1`],[/\[strike\](.*?(?=\[\/strike\]))\[\/strike\]/gi,`$1`],[/\[code\](.*?(?=\[\/code\]))\[\/code\]/gi,`$1`],[/\[br\]/gi,`
    `],[/\n\n/gi,`

    `],[/\n/gi,`
    `],[/\[attach=?f?u?l?l?\](.*?(?=\[\/attach\]))\[\/attach\]/gi,``],[/\[USER=([\d]+)\](.*?(?=\[\/USER\]))\[\/USER\]/gi,`$2`],[/\[MEDIA=youtube\](.*?(?=\[\/MEDIA\]))\[\/MEDIA\]/gi,`
    `],[/\[MEDIA=beamng\](.*?(?=\[\/MEDIA\]))\[\/MEDIA\]/gi,``],[PARSE_NESTED$1,/\[size=(\d+)\]([^[]*(?:\[(?!size=\d+\]|\/size\])[^[]*)*)\[\/size\]/gi,`$2`],[PARSE_NESTED$1,/\[COLOR=([a-z0-9\#\, \'\"\(\)]+)\]([^[]*(?:\[(?!COLOR=[a-z0-9#\(\)]+\]|\/COLOR\])[^[]*)*)\[\/COLOR\]/gi,`$2`],[PARSE_NESTED$1,/\[font=([^\]]+)\](.*?(?=\[\/font\]))\[\/font\]/gi,`$2`],[/\[hr\]\[\/hr\]/gi,`
    `],[/\[spoiler=([^\]]+)\](.*?(?=\[\/spoiler\]))\[\/spoiler\]/gi,`
    Spoiler: $1
    $2
    `],[/\[spoiler\](.*?(?=\[\/spoiler\]))\[\/spoiler\]/gi,`
    Spoiler
    $1
    `],[PARSE_NESTED$1,/\[left\](.*?(?=\[\/left\]))\[\/left\]/gi,`

    $1

    `],[PARSE_NESTED$1,/\[center\](.*?(?=\[\/center\]))\[\/center\]/gi,`

    $1

    `],[PARSE_NESTED$1,/\[right\](.*?(?=\[\/right\]))\[\/right\]/gi,`

    $1

    `],[PARSE_NESTED$1,/\*\*(.*?(?=\*\*))\*\*/gi,`$1`],[PARSE_NESTED$1,/\*(.*?(?=\*))\*/gi,`$1`],[PARSE_NESTED$1,/\[(.*?(?=\]\())\]\((https?:\/\/((.*?(?=\)))))\)/gi,`$1 ($2)`]],bbcode_vue_default=[[/\[ico=([^\s\]]+)\s*\](.*?(?=\[\/ico\]))\[\/ico\]/gi,`$2`],[/\[ico=([^\s\]]+)\s*\]/gi,``],[/\[action=(.*?)\]\[showunassigned=(.*?)\](.*?)/gi,``],[/\[action=(.*?)\](.*?)/gi,``],[/\[action=(.*?)\]/gi,``],[/\[(money|beamXP|stars|vouchers)=(.*?)\]/g,``]],bbcode_angular_default=[[/\[ico=([^\s\]]+)\s*\](.*?(?=\[\/ico\]))\[\/ico\]/gi,`$2`],[/\[ico=([^\s\]]+)\s*\]/gi,``],[/\[action=(.*?)\]\[showunassigned=(.*?)\](.*?)/gi,``],[/\[action=(.*?)\](.*?)/gi,``],[/\[action=(.*?)\]/gi,``]],bbcode_exports=__export({parse:()=>parse$1,useExtensions:()=>useExtensions}),PARSE_NESTED=`PARSE_NESTED`,_extensions=bbcode_vue_default;const useExtensions=exts=>_extensions=exts,parse$1=(txt,extensions$1=_extensions)=>{let text=``+txt;return[...bbcode_main_default,...extensions$1].forEach(replacement=>{let{nested,fromTo}=replacementDetails(replacement);text=nested?parseNested(text,...fromTo):text.replace(...fromTo)}),text};window.angularParseBBCode=txt=>parse$1(txt,bbcode_angular_default);var replacementDetails=replacement=>({nested:replacement.length==3&&replacement[0]===PARSE_NESTED,fromTo:replacement.slice(-2)}),parseNested=(text,regex,template)=>{for(;~text.search(regex);)text=text.replace(regex,template);return text},markdown_exports=__export({parse:()=>parse});function parse(src){let h$1=``;return src.replace(/^\s+|\r|\s+$/g,``).replace(/\t/g,` `).split(/\n\n+/).forEach(function(b,f,R){f=b[0],R={"*":[/\n\* /,`
    • `,`
    `],1:[/\n[1-9]\d*\.? /,`
    1. `,`
    `]," ":[/\n {4}/,`
    `,`
    `,` `],">":[/\n> /,`
    `,`
    `,`
    `,CHAR_LS=`\u2028`,CHAR_PS=`\u2029`;function createScanner(str){let _buf=str,_index=0,_line=1,_column=1,_peekOffset=0,isCRLF=index$1=>_buf[index$1]===CHAR_CR&&_buf[index$1+1]===CHAR_LF,isLF=index$1=>_buf[index$1]===CHAR_LF,isPS=index$1=>_buf[index$1]===CHAR_PS,isLS=index$1=>_buf[index$1]===CHAR_LS,isLineEnd=index$1=>isCRLF(index$1)||isLF(index$1)||isPS(index$1)||isLS(index$1),index=()=>_index,line=()=>_line,column=()=>_column,peekOffset=()=>_peekOffset,charAt=offset$2=>isCRLF(offset$2)||isPS(offset$2)||isLS(offset$2)?CHAR_LF:_buf[offset$2],currentChar=()=>charAt(_index),currentPeek=()=>charAt(_index+_peekOffset);function next(){return _peekOffset=0,isLineEnd(_index)&&(_line++,_column=0),isCRLF(_index)&&_index++,_index++,_column++,_buf[_index]}function peek(){return isCRLF(_index+_peekOffset)&&_peekOffset++,_peekOffset++,_buf[_index+_peekOffset]}function reset$1(){_index=0,_line=1,_column=1,_peekOffset=0}function resetPeek(offset$2=0){_peekOffset=offset$2}function skipToPeek(){let target=_index+_peekOffset;for(;target!==_index;)next();_peekOffset=0}return{index,line,column,peekOffset,charAt,currentChar,currentPeek,next,peek,reset:reset$1,resetPeek,skipToPeek}}var EOF=void 0,DOT=`.`,LITERAL_DELIMITER=`'`,ERROR_DOMAIN$3=`tokenizer`;function createTokenizer(source,options={}){let location$1=options.location!==!1,_scnr=createScanner(source),currentOffset=()=>_scnr.index(),currentPosition=()=>createPosition(_scnr.line(),_scnr.column(),_scnr.index()),_initLoc=currentPosition(),_initOffset=currentOffset(),_context={currentType:13,offset:_initOffset,startLoc:_initLoc,endLoc:_initLoc,lastType:13,lastOffset:_initOffset,lastStartLoc:_initLoc,lastEndLoc:_initLoc,braceNest:0,inLinked:!1,text:``},context=()=>_context,{onError}=options;function emitError$1(code,pos,offset$2,...args){let ctx=context();pos.column+=offset$2,pos.offset+=offset$2,onError&&onError(createCompileError(code,location$1?createLocation(ctx.startLoc,pos):null,{domain:ERROR_DOMAIN$3,args}))}function getToken(context$1,type,value){context$1.endLoc=currentPosition(),context$1.currentType=type;let token={type};return location$1&&(token.loc=createLocation(context$1.startLoc,context$1.endLoc)),value!=null&&(token.value=value),token}let getEndToken=context$1=>getToken(context$1,13);function eat(scnr,ch){return scnr.currentChar()===ch?(scnr.next(),ch):(emitError$1(CompileErrorCodes.EXPECTED_TOKEN,currentPosition(),0,ch),``)}function peekSpaces(scnr){let buf=``;for(;scnr.currentPeek()===CHAR_SP||scnr.currentPeek()===CHAR_LF;)buf+=scnr.currentPeek(),scnr.peek();return buf}function skipSpaces(scnr){let buf=peekSpaces(scnr);return scnr.skipToPeek(),buf}function isIdentifierStart(ch){if(ch===EOF)return!1;let cc=ch.charCodeAt(0);return cc>=97&&cc<=122||cc>=65&&cc<=90||cc===95}function isNumberStart(ch){if(ch===EOF)return!1;let cc=ch.charCodeAt(0);return cc>=48&&cc<=57}function isNamedIdentifierStart(scnr,context$1){let{currentType}=context$1;if(currentType!==2)return!1;peekSpaces(scnr);let ret=isIdentifierStart(scnr.currentPeek());return scnr.resetPeek(),ret}function isListIdentifierStart(scnr,context$1){let{currentType}=context$1;if(currentType!==2)return!1;peekSpaces(scnr);let ret=isNumberStart(scnr.currentPeek()===`-`?scnr.peek():scnr.currentPeek());return scnr.resetPeek(),ret}function isLiteralStart(scnr,context$1){let{currentType}=context$1;if(currentType!==2)return!1;peekSpaces(scnr);let ret=scnr.currentPeek()===LITERAL_DELIMITER;return scnr.resetPeek(),ret}function isLinkedDotStart(scnr,context$1){let{currentType}=context$1;if(currentType!==7)return!1;peekSpaces(scnr);let ret=scnr.currentPeek()===`.`;return scnr.resetPeek(),ret}function isLinkedModifierStart(scnr,context$1){let{currentType}=context$1;if(currentType!==8)return!1;peekSpaces(scnr);let ret=isIdentifierStart(scnr.currentPeek());return scnr.resetPeek(),ret}function isLinkedDelimiterStart(scnr,context$1){let{currentType}=context$1;if(!(currentType===7||currentType===11))return!1;peekSpaces(scnr);let ret=scnr.currentPeek()===`:`;return scnr.resetPeek(),ret}function isLinkedReferStart(scnr,context$1){let{currentType}=context$1;if(currentType!==9)return!1;let fn=()=>{let ch=scnr.currentPeek();return ch===`{`?isIdentifierStart(scnr.peek()):ch===`@`||ch===`|`||ch===`:`||ch===`.`||ch===CHAR_SP||!ch?!1:ch===CHAR_LF?(scnr.peek(),fn()):isTextStart(scnr,!1)},ret=fn();return scnr.resetPeek(),ret}function isPluralStart(scnr){peekSpaces(scnr);let ret=scnr.currentPeek()===`|`;return scnr.resetPeek(),ret}function isTextStart(scnr,reset$1=!0){let fn=(hasSpace=!1,prev=``)=>{let ch=scnr.currentPeek();return ch===`{`||ch===`@`||!ch?hasSpace:ch===`|`?!(prev===CHAR_SP||prev===CHAR_LF):ch===CHAR_SP?(scnr.peek(),fn(!0,CHAR_SP)):ch===CHAR_LF?(scnr.peek(),fn(!0,CHAR_LF)):!0},ret=fn();return reset$1&&scnr.resetPeek(),ret}function takeChar(scnr,fn){let ch=scnr.currentChar();return ch===EOF?EOF:fn(ch)?(scnr.next(),ch):null}function isIdentifier(ch){let cc=ch.charCodeAt(0);return cc>=97&&cc<=122||cc>=65&&cc<=90||cc>=48&&cc<=57||cc===95||cc===36}function takeIdentifierChar(scnr){return takeChar(scnr,isIdentifier)}function isNamedIdentifier(ch){let cc=ch.charCodeAt(0);return cc>=97&&cc<=122||cc>=65&&cc<=90||cc>=48&&cc<=57||cc===95||cc===36||cc===45}function takeNamedIdentifierChar(scnr){return takeChar(scnr,isNamedIdentifier)}function isDigit(ch){let cc=ch.charCodeAt(0);return cc>=48&&cc<=57}function takeDigit(scnr){return takeChar(scnr,isDigit)}function isHexDigit(ch){let cc=ch.charCodeAt(0);return cc>=48&&cc<=57||cc>=65&&cc<=70||cc>=97&&cc<=102}function takeHexDigit(scnr){return takeChar(scnr,isHexDigit)}function getDigits(scnr){let ch=``,num=``;for(;ch=takeDigit(scnr);)num+=ch;return num}function readText(scnr){let buf=``;for(;;){let ch=scnr.currentChar();if(ch===`{`||ch===`}`||ch===`@`||ch===`|`||!ch)break;if(ch===CHAR_SP||ch===CHAR_LF)if(isTextStart(scnr))buf+=ch,scnr.next();else if(isPluralStart(scnr))break;else buf+=ch,scnr.next();else buf+=ch,scnr.next()}return buf}function readNamedIdentifier(scnr){skipSpaces(scnr);let ch=``,name=``;for(;ch=takeNamedIdentifierChar(scnr);)name+=ch;let currentChar=scnr.currentChar();if(currentChar&¤tChar!==`}`&¤tChar!==EOF&¤tChar!==CHAR_SP&¤tChar!==CHAR_LF&¤tChar!==` `){let invalidPart=readInvalidIdentifier(scnr);return emitError$1(CompileErrorCodes.INVALID_TOKEN_IN_PLACEHOLDER,currentPosition(),0,name+invalidPart),name+invalidPart}return scnr.currentChar()===EOF&&emitError$1(CompileErrorCodes.UNTERMINATED_CLOSING_BRACE,currentPosition(),0),name}function readListIdentifier(scnr){skipSpaces(scnr);let value=``;return scnr.currentChar()===`-`?(scnr.next(),value+=`-${getDigits(scnr)}`):value+=getDigits(scnr),scnr.currentChar()===EOF&&emitError$1(CompileErrorCodes.UNTERMINATED_CLOSING_BRACE,currentPosition(),0),value}function isLiteral(ch){return ch!==LITERAL_DELIMITER&&ch!==CHAR_LF}function readLiteral(scnr){skipSpaces(scnr),eat(scnr,`'`);let ch=``,literal=``;for(;ch=takeChar(scnr,isLiteral);)ch===`\\`?literal+=readEscapeSequence(scnr):literal+=ch;let current=scnr.currentChar();return current===CHAR_LF||current===EOF?(emitError$1(CompileErrorCodes.UNTERMINATED_SINGLE_QUOTE_IN_PLACEHOLDER,currentPosition(),0),current===CHAR_LF&&(scnr.next(),eat(scnr,`'`)),literal):(eat(scnr,`'`),literal)}function readEscapeSequence(scnr){let ch=scnr.currentChar();switch(ch){case`\\`:case`'`:return scnr.next(),`\\${ch}`;case`u`:return readUnicodeEscapeSequence(scnr,ch,4);case`U`:return readUnicodeEscapeSequence(scnr,ch,6);default:return emitError$1(CompileErrorCodes.UNKNOWN_ESCAPE_SEQUENCE,currentPosition(),0,ch),``}}function readUnicodeEscapeSequence(scnr,unicode,digits){eat(scnr,unicode);let sequence=``;for(let i=0;i{let ch=scnr.currentChar();return ch===`{`||ch===`@`||ch===`|`||ch===`(`||ch===`)`||!ch||ch===CHAR_SP?buf:(buf+=ch,scnr.next(),fn(buf))};return fn(``)}function readPlural(scnr){skipSpaces(scnr);let plural=eat(scnr,`|`);return skipSpaces(scnr),plural}function readTokenInPlaceholder(scnr,context$1){let token=null;switch(scnr.currentChar()){case`{`:return context$1.braceNest>=1&&emitError$1(CompileErrorCodes.NOT_ALLOW_NEST_PLACEHOLDER,currentPosition(),0),scnr.next(),token=getToken(context$1,2,`{`),skipSpaces(scnr),context$1.braceNest++,token;case`}`:return context$1.braceNest>0&&context$1.currentType===2&&emitError$1(CompileErrorCodes.EMPTY_PLACEHOLDER,currentPosition(),0),scnr.next(),token=getToken(context$1,3,`}`),context$1.braceNest--,context$1.braceNest>0&&skipSpaces(scnr),context$1.inLinked&&context$1.braceNest===0&&(context$1.inLinked=!1),token;case`@`:return context$1.braceNest>0&&emitError$1(CompileErrorCodes.UNTERMINATED_CLOSING_BRACE,currentPosition(),0),token=readTokenInLinked(scnr,context$1)||getEndToken(context$1),context$1.braceNest=0,token;default:{let validNamedIdentifier=!0,validListIdentifier=!0,validLiteral=!0;if(isPluralStart(scnr))return context$1.braceNest>0&&emitError$1(CompileErrorCodes.UNTERMINATED_CLOSING_BRACE,currentPosition(),0),token=getToken(context$1,1,readPlural(scnr)),context$1.braceNest=0,context$1.inLinked=!1,token;if(context$1.braceNest>0&&(context$1.currentType===4||context$1.currentType===5||context$1.currentType===6))return emitError$1(CompileErrorCodes.UNTERMINATED_CLOSING_BRACE,currentPosition(),0),context$1.braceNest=0,readToken(scnr,context$1);if(validNamedIdentifier=isNamedIdentifierStart(scnr,context$1))return token=getToken(context$1,4,readNamedIdentifier(scnr)),skipSpaces(scnr),token;if(validListIdentifier=isListIdentifierStart(scnr,context$1))return token=getToken(context$1,5,readListIdentifier(scnr)),skipSpaces(scnr),token;if(validLiteral=isLiteralStart(scnr,context$1))return token=getToken(context$1,6,readLiteral(scnr)),skipSpaces(scnr),token;if(!validNamedIdentifier&&!validListIdentifier&&!validLiteral)return token=getToken(context$1,12,readInvalidIdentifier(scnr)),emitError$1(CompileErrorCodes.INVALID_TOKEN_IN_PLACEHOLDER,currentPosition(),0,token.value),skipSpaces(scnr),token;break}}return token}function readTokenInLinked(scnr,context$1){let{currentType}=context$1,token=null,ch=scnr.currentChar();switch((currentType===7||currentType===8||currentType===11||currentType===9)&&(ch===CHAR_LF||ch===CHAR_SP)&&emitError$1(CompileErrorCodes.INVALID_LINKED_FORMAT,currentPosition(),0),ch){case`@`:return scnr.next(),token=getToken(context$1,7,`@`),context$1.inLinked=!0,token;case`.`:return skipSpaces(scnr),scnr.next(),getToken(context$1,8,`.`);case`:`:return skipSpaces(scnr),scnr.next(),getToken(context$1,9,`:`);default:return isPluralStart(scnr)?(token=getToken(context$1,1,readPlural(scnr)),context$1.braceNest=0,context$1.inLinked=!1,token):isLinkedDotStart(scnr,context$1)||isLinkedDelimiterStart(scnr,context$1)?(skipSpaces(scnr),readTokenInLinked(scnr,context$1)):isLinkedModifierStart(scnr,context$1)?(skipSpaces(scnr),getToken(context$1,11,readLinkedModifier(scnr))):isLinkedReferStart(scnr,context$1)?(skipSpaces(scnr),ch===`{`?readTokenInPlaceholder(scnr,context$1)||token:getToken(context$1,10,readLinkedRefer(scnr))):(currentType===7&&emitError$1(CompileErrorCodes.INVALID_LINKED_FORMAT,currentPosition(),0),context$1.braceNest=0,context$1.inLinked=!1,readToken(scnr,context$1))}}function readToken(scnr,context$1){let token={type:13};if(context$1.braceNest>0)return readTokenInPlaceholder(scnr,context$1)||getEndToken(context$1);if(context$1.inLinked)return readTokenInLinked(scnr,context$1)||getEndToken(context$1);switch(scnr.currentChar()){case`{`:return readTokenInPlaceholder(scnr,context$1)||getEndToken(context$1);case`}`:return emitError$1(CompileErrorCodes.UNBALANCED_CLOSING_BRACE,currentPosition(),0),scnr.next(),getToken(context$1,3,`}`);case`@`:return readTokenInLinked(scnr,context$1)||getEndToken(context$1);default:if(isPluralStart(scnr))return token=getToken(context$1,1,readPlural(scnr)),context$1.braceNest=0,context$1.inLinked=!1,token;if(isTextStart(scnr))return getToken(context$1,0,readText(scnr));break}return token}function nextToken(){let{currentType,offset:offset$2,startLoc,endLoc}=_context;return _context.lastType=currentType,_context.lastOffset=offset$2,_context.lastStartLoc=startLoc,_context.lastEndLoc=endLoc,_context.offset=currentOffset(),_context.startLoc=currentPosition(),_scnr.currentChar()===EOF?getToken(_context,13):readToken(_scnr,_context)}return{nextToken,currentOffset,currentPosition,context}}var ERROR_DOMAIN$2=`parser`,KNOWN_ESCAPES=/(?:\\\\|\\'|\\u([0-9a-fA-F]{4})|\\U([0-9a-fA-F]{6}))/g;function fromEscapeSequence(match,codePoint4,codePoint6){switch(match){case`\\\\`:return`\\`;case`\\'`:return`'`;default:{let codePoint=parseInt(codePoint4||codePoint6,16);return codePoint<=55295||codePoint>=57344?String.fromCodePoint(codePoint):`�`}}}function createParser(options={}){let location$1=options.location!==!1,{onError}=options;function emitError$1(tokenzer,code,start,offset$2,...args){let end=tokenzer.currentPosition();end.offset+=offset$2,end.column+=offset$2,onError&&onError(createCompileError(code,location$1?createLocation(start,end):null,{domain:ERROR_DOMAIN$2,args}))}function startNode(type,offset$2,loc){let node={type};return location$1&&(node.start=offset$2,node.end=offset$2,node.loc={start:loc,end:loc}),node}function endNode(node,offset$2,pos,type){location$1&&(node.end=offset$2,node.loc&&(node.loc.end=pos))}function parseText$1(tokenizer$1,value){let context=tokenizer$1.context(),node=startNode(3,context.offset,context.startLoc);return node.value=value,endNode(node,tokenizer$1.currentOffset(),tokenizer$1.currentPosition()),node}function parseList(tokenizer$1,index){let{lastOffset:offset$2,lastStartLoc:loc}=tokenizer$1.context(),node=startNode(5,offset$2,loc);return node.index=parseInt(index,10),tokenizer$1.nextToken(),endNode(node,tokenizer$1.currentOffset(),tokenizer$1.currentPosition()),node}function parseNamed(tokenizer$1,key){let{lastOffset:offset$2,lastStartLoc:loc}=tokenizer$1.context(),node=startNode(4,offset$2,loc);return node.key=key,tokenizer$1.nextToken(),endNode(node,tokenizer$1.currentOffset(),tokenizer$1.currentPosition()),node}function parseLiteral(tokenizer$1,value){let{lastOffset:offset$2,lastStartLoc:loc}=tokenizer$1.context(),node=startNode(9,offset$2,loc);return node.value=value.replace(KNOWN_ESCAPES,fromEscapeSequence),tokenizer$1.nextToken(),endNode(node,tokenizer$1.currentOffset(),tokenizer$1.currentPosition()),node}function parseLinkedModifier(tokenizer$1){let token=tokenizer$1.nextToken(),context=tokenizer$1.context(),{lastOffset:offset$2,lastStartLoc:loc}=context,node=startNode(8,offset$2,loc);return token.type===11?(token.value??emitError$1(tokenizer$1,CompileErrorCodes.UNEXPECTED_LEXICAL_ANALYSIS,context.lastStartLoc,0,getTokenCaption(token)),node.value=token.value||``,endNode(node,tokenizer$1.currentOffset(),tokenizer$1.currentPosition()),{node}):(emitError$1(tokenizer$1,CompileErrorCodes.UNEXPECTED_EMPTY_LINKED_MODIFIER,context.lastStartLoc,0),node.value=``,endNode(node,offset$2,loc),{nextConsumeToken:token,node})}function parseLinkedKey(tokenizer$1,value){let context=tokenizer$1.context(),node=startNode(7,context.offset,context.startLoc);return node.value=value,endNode(node,tokenizer$1.currentOffset(),tokenizer$1.currentPosition()),node}function parseLinked(tokenizer$1){let context=tokenizer$1.context(),linkedNode=startNode(6,context.offset,context.startLoc),token=tokenizer$1.nextToken();if(token.type===8){let parsed=parseLinkedModifier(tokenizer$1);linkedNode.modifier=parsed.node,token=parsed.nextConsumeToken||tokenizer$1.nextToken()}switch(token.type!==9&&emitError$1(tokenizer$1,CompileErrorCodes.UNEXPECTED_LEXICAL_ANALYSIS,context.lastStartLoc,0,getTokenCaption(token)),token=tokenizer$1.nextToken(),token.type===2&&(token=tokenizer$1.nextToken()),token.type){case 10:token.value??emitError$1(tokenizer$1,CompileErrorCodes.UNEXPECTED_LEXICAL_ANALYSIS,context.lastStartLoc,0,getTokenCaption(token)),linkedNode.key=parseLinkedKey(tokenizer$1,token.value||``);break;case 4:token.value??emitError$1(tokenizer$1,CompileErrorCodes.UNEXPECTED_LEXICAL_ANALYSIS,context.lastStartLoc,0,getTokenCaption(token)),linkedNode.key=parseNamed(tokenizer$1,token.value||``);break;case 5:token.value??emitError$1(tokenizer$1,CompileErrorCodes.UNEXPECTED_LEXICAL_ANALYSIS,context.lastStartLoc,0,getTokenCaption(token)),linkedNode.key=parseList(tokenizer$1,token.value||``);break;case 6:token.value??emitError$1(tokenizer$1,CompileErrorCodes.UNEXPECTED_LEXICAL_ANALYSIS,context.lastStartLoc,0,getTokenCaption(token)),linkedNode.key=parseLiteral(tokenizer$1,token.value||``);break;default:{emitError$1(tokenizer$1,CompileErrorCodes.UNEXPECTED_EMPTY_LINKED_KEY,context.lastStartLoc,0);let nextContext=tokenizer$1.context(),emptyLinkedKeyNode=startNode(7,nextContext.offset,nextContext.startLoc);return emptyLinkedKeyNode.value=``,endNode(emptyLinkedKeyNode,nextContext.offset,nextContext.startLoc),linkedNode.key=emptyLinkedKeyNode,endNode(linkedNode,nextContext.offset,nextContext.startLoc),{nextConsumeToken:token,node:linkedNode}}}return endNode(linkedNode,tokenizer$1.currentOffset(),tokenizer$1.currentPosition()),{node:linkedNode}}function parseMessage(tokenizer$1){let context=tokenizer$1.context(),node=startNode(2,context.currentType===1?tokenizer$1.currentOffset():context.offset,context.currentType===1?context.endLoc:context.startLoc);node.items=[];let nextToken=null;do{let token=nextToken||tokenizer$1.nextToken();switch(nextToken=null,token.type){case 0:token.value??emitError$1(tokenizer$1,CompileErrorCodes.UNEXPECTED_LEXICAL_ANALYSIS,context.lastStartLoc,0,getTokenCaption(token)),node.items.push(parseText$1(tokenizer$1,token.value||``));break;case 5:token.value??emitError$1(tokenizer$1,CompileErrorCodes.UNEXPECTED_LEXICAL_ANALYSIS,context.lastStartLoc,0,getTokenCaption(token)),node.items.push(parseList(tokenizer$1,token.value||``));break;case 4:token.value??emitError$1(tokenizer$1,CompileErrorCodes.UNEXPECTED_LEXICAL_ANALYSIS,context.lastStartLoc,0,getTokenCaption(token)),node.items.push(parseNamed(tokenizer$1,token.value||``));break;case 6:token.value??emitError$1(tokenizer$1,CompileErrorCodes.UNEXPECTED_LEXICAL_ANALYSIS,context.lastStartLoc,0,getTokenCaption(token)),node.items.push(parseLiteral(tokenizer$1,token.value||``));break;case 7:{let parsed=parseLinked(tokenizer$1);node.items.push(parsed.node),nextToken=parsed.nextConsumeToken||null;break}}}while(context.currentType!==13&&context.currentType!==1);return endNode(node,context.currentType===1?context.lastOffset:tokenizer$1.currentOffset(),context.currentType===1?context.lastEndLoc:tokenizer$1.currentPosition()),node}function parsePlural(tokenizer$1,offset$2,loc,msgNode){let context=tokenizer$1.context(),hasEmptyMessage=msgNode.items.length===0,node=startNode(1,offset$2,loc);node.cases=[],node.cases.push(msgNode);do{let msg=parseMessage(tokenizer$1);hasEmptyMessage||=msg.items.length===0,node.cases.push(msg)}while(context.currentType!==13);return hasEmptyMessage&&emitError$1(tokenizer$1,CompileErrorCodes.MUST_HAVE_MESSAGES_IN_PLURAL,loc,0),endNode(node,tokenizer$1.currentOffset(),tokenizer$1.currentPosition()),node}function parseResource(tokenizer$1){let context=tokenizer$1.context(),{offset:offset$2,startLoc}=context,msgNode=parseMessage(tokenizer$1);return context.currentType===13?msgNode:parsePlural(tokenizer$1,offset$2,startLoc,msgNode)}function parse$2(source){let tokenizer$1=createTokenizer(source,assign$1({},options)),context=tokenizer$1.context(),node=startNode(0,context.offset,context.startLoc);return location$1&&node.loc&&(node.loc.source=source),node.body=parseResource(tokenizer$1),options.onCacheKey&&(node.cacheKey=options.onCacheKey(source)),context.currentType!==13&&emitError$1(tokenizer$1,CompileErrorCodes.UNEXPECTED_LEXICAL_ANALYSIS,context.lastStartLoc,0,source[context.offset]||``),endNode(node,tokenizer$1.currentOffset(),tokenizer$1.currentPosition()),node}return{parse:parse$2}}function getTokenCaption(token){if(token.type===13)return`EOF`;let name=(token.value||``).replace(/\r?\n/gu,`\\n`);return name.length>10?name.slice(0,9)+`…`:name}function createTransformer(ast,options={}){let _context={ast,helpers:new Set};return{context:()=>_context,helper:name=>(_context.helpers.add(name),name)}}function traverseNodes(nodes,transformer){for(let i=0;ioptimizeMessageNode(c)),ast}function optimizeMessageNode(message){if(message.items.length===1){let item=message.items[0];(item.type===3||item.type===9)&&(message.static=item.value,delete item.value)}else{let values=[];for(let i=0;i_context;function push(code,node){_context.code+=code}function _newline(n,withBreakLine=!0){let _breakLineCode=withBreakLine?breakLineCode:``;push(_needIndent?_breakLineCode+`  `.repeat(n):_breakLineCode)}function indent(withNewLine=!0){let level$1=++_context.indentLevel;withNewLine&&_newline(level$1)}function deindent(withNewLine=!0){let level$1=--_context.indentLevel;withNewLine&&_newline(level$1)}function newline(){_newline(_context.indentLevel)}return{context,push,indent,deindent,newline,helper:key=>`_${key}`,needIndent:()=>_context.needIndent}}function generateLinkedNode(generator,node){let{helper}=generator;generator.push(`${helper(`linked`)}(`),generateNode(generator,node.key),node.modifier?(generator.push(`, `),generateNode(generator,node.modifier),generator.push(`, _type`)):generator.push(`, undefined, _type`),generator.push(`)`)}function generateMessageNode(generator,node){let{helper,needIndent}=generator;generator.push(`${helper(`normalize`)}([`),generator.indent(needIndent());let length=node.items.length;for(let i=0;i1){generator.push(`${helper(`plural`)}([`),generator.indent(needIndent());let length=node.cases.length;for(let i=0;i{let mode=isString(options.mode)?options.mode:`normal`,filename=isString(options.filename)?options.filename:`message.intl`,sourceMap=!!options.sourceMap,breakLineCode=options.breakLineCode==null?mode===`arrow`?`;`:`
    `:options.breakLineCode,needIndent=options.needIndent?options.needIndent:mode!==`arrow`,helpers=ast.helpers||[],generator=createCodeGenerator(ast,{mode,filename,sourceMap,breakLineCode,needIndent});generator.push(mode===`normal`?`function __msg__ (ctx) {`:`(ctx) => {`),generator.indent(needIndent),helpers.length>0&&(generator.push(`const { ${join(helpers.map(s=>`${s}: _${s}`),`, `)} } = ctx`),generator.newline()),generator.push(`return `),generateNode(generator,ast),generator.deindent(needIndent),generator.push(`}`),delete ast.helpers;let{code,map}=generator.context();return{ast,code,map:map?map.toJSON():void 0}};function baseCompile(source,options={}){let assignedOptions=assign$1({},options),jit=!!assignedOptions.jit,enalbeMinify=!!assignedOptions.minify,enambeOptimize=assignedOptions.optimize==null?!0:assignedOptions.optimize,ast=createParser(assignedOptions).parse(source);return jit?(enambeOptimize&&optimize(ast),enalbeMinify&&minify(ast),{ast,code:``}):(transform(ast,assignedOptions),generate(ast,assignedOptions))}function initFeatureFlags$1(){typeof __INTLIFY_PROD_DEVTOOLS__!=`boolean`&&(getGlobalThis().__INTLIFY_PROD_DEVTOOLS__=!1),typeof __INTLIFY_DROP_MESSAGE_COMPILER__!=`boolean`&&(getGlobalThis().__INTLIFY_DROP_MESSAGE_COMPILER__=!1)}function isMessageAST(val){return isObject(val)&&resolveType(val)===0&&(hasOwn(val,`b`)||hasOwn(val,`body`))}var PROPS_BODY=[`b`,`body`];function resolveBody(node){return resolveProps(node,PROPS_BODY)}var PROPS_CASES=[`c`,`cases`];function resolveCases(node){return resolveProps(node,PROPS_CASES,[])}var PROPS_STATIC=[`s`,`static`];function resolveStatic(node){return resolveProps(node,PROPS_STATIC)}var PROPS_ITEMS=[`i`,`items`];function resolveItems(node){return resolveProps(node,PROPS_ITEMS,[])}var PROPS_TYPE=[`t`,`type`];function resolveType(node){return resolveProps(node,PROPS_TYPE)}var PROPS_VALUE=[`v`,`value`];function resolveValue$1(node,type){let resolved=resolveProps(node,PROPS_VALUE);if(resolved!=null)return resolved;throw createUnhandleNodeError(type)}var PROPS_MODIFIER=[`m`,`modifier`];function resolveLinkedModifier(node){return resolveProps(node,PROPS_MODIFIER)}var PROPS_KEY=[`k`,`key`];function resolveLinkedKey(node){let resolved=resolveProps(node,PROPS_KEY);if(resolved)return resolved;throw createUnhandleNodeError(6)}function resolveProps(node,props,defaultValue){for(let i=0;iformatParts(ctx,ast)}function formatParts(ctx,ast){let body=resolveBody(ast);if(body==null)throw createUnhandleNodeError(0);if(resolveType(body)===1){let cases=resolveCases(body);return ctx.plural(cases.reduce((messages,c)=>[...messages,formatMessageParts(ctx,c)],[]))}else return formatMessageParts(ctx,body)}function formatMessageParts(ctx,node){let static_=resolveStatic(node);if(static_!=null)return ctx.type===`text`?static_:ctx.normalize([static_]);{let messages=resolveItems(node).reduce((acm,c)=>[...acm,formatMessagePart(ctx,c)],[]);return ctx.normalize(messages)}}function formatMessagePart(ctx,node){let type=resolveType(node);switch(type){case 3:return resolveValue$1(node,type);case 9:return resolveValue$1(node,type);case 4:{let named=node;if(hasOwn(named,`k`)&&named.k)return ctx.interpolate(ctx.named(named.k));if(hasOwn(named,`key`)&&named.key)return ctx.interpolate(ctx.named(named.key));throw createUnhandleNodeError(type)}case 5:{let list=node;if(hasOwn(list,`i`)&&isNumber(list.i))return ctx.interpolate(ctx.list(list.i));if(hasOwn(list,`index`)&&isNumber(list.index))return ctx.interpolate(ctx.list(list.index));throw createUnhandleNodeError(type)}case 6:{let linked=node,modifier=resolveLinkedModifier(linked),key=resolveLinkedKey(linked);return ctx.linked(formatMessagePart(ctx,key),modifier?formatMessagePart(ctx,modifier):void 0,ctx.type)}case 7:return resolveValue$1(node,type);case 8:return resolveValue$1(node,type);default:throw Error(`unhandled node on format message part: ${type}`)}}var defaultOnCacheKey=message=>message,compileCache=create();function baseCompile$1(message,options={}){let detectError=!1,onError=options.onError||defaultOnError;return options.onError=err=>{detectError=!0,onError(err)},{...baseCompile(message,options),detectError}}function compile(message,context){if(!__INTLIFY_DROP_MESSAGE_COMPILER__&&isString(message)){isBoolean(context.warnHtmlMessage)&&context.warnHtmlMessage;let cacheKey=(context.onCacheKey||defaultOnCacheKey)(message),cached=compileCache[cacheKey];if(cached)return cached;let{ast,detectError}=baseCompile$1(message,{...context,location:!1,jit:!0}),msg=format$1(ast);return detectError?msg:compileCache[cacheKey]=msg}else{let cacheKey=message.cacheKey;return cacheKey?compileCache[cacheKey]||(compileCache[cacheKey]=format$1(message)):format$1(message)}}var devtools=null;function setDevToolsHook(hook){devtools=hook}function initI18nDevTools(i18n,version$2,meta){devtools&&devtools.emit(`i18n:init`,{timestamp:Date.now(),i18n,version:version$2,meta})}var translateDevTools=createDevToolsHook(`function:translate`);function createDevToolsHook(hook){return payloads=>devtools&&devtools.emit(hook,payloads)}var CoreErrorCodes={INVALID_ARGUMENT:17,INVALID_DATE_ARGUMENT:18,INVALID_ISO_DATE_ARGUMENT:19,NOT_SUPPORT_NON_STRING_MESSAGE:20,NOT_SUPPORT_LOCALE_PROMISE_VALUE:21,NOT_SUPPORT_LOCALE_ASYNC_FUNCTION:22,NOT_SUPPORT_LOCALE_TYPE:23},CORE_ERROR_CODES_EXTEND_POINT=24;function createCoreError(code){return createCompileError(code,null,void 0)}CoreErrorCodes.INVALID_ARGUMENT,CoreErrorCodes.INVALID_DATE_ARGUMENT,CoreErrorCodes.INVALID_ISO_DATE_ARGUMENT,CoreErrorCodes.NOT_SUPPORT_NON_STRING_MESSAGE,CoreErrorCodes.NOT_SUPPORT_LOCALE_PROMISE_VALUE,CoreErrorCodes.NOT_SUPPORT_LOCALE_ASYNC_FUNCTION,CoreErrorCodes.NOT_SUPPORT_LOCALE_TYPE;function getLocale(context,options){return options.locale==null?resolveLocale(context.locale):resolveLocale(options.locale)}var _resolveLocale;function resolveLocale(locale){if(isString(locale))return locale;if(isFunction(locale)){if(locale.resolvedOnce&&_resolveLocale!=null)return _resolveLocale;if(locale.constructor.name===`Function`){let resolve$1=locale();if(isPromise(resolve$1))throw createCoreError(CoreErrorCodes.NOT_SUPPORT_LOCALE_PROMISE_VALUE);return _resolveLocale=resolve$1}else throw createCoreError(CoreErrorCodes.NOT_SUPPORT_LOCALE_ASYNC_FUNCTION)}else throw createCoreError(CoreErrorCodes.NOT_SUPPORT_LOCALE_TYPE)}function fallbackWithSimple(ctx,fallback,start){return[...new Set([start,...isArray$1(fallback)?fallback:isObject(fallback)?Object.keys(fallback):isString(fallback)?[fallback]:[start]])]}var pathStateMachine=[];pathStateMachine[0]={w:[0],i:[3,0],"[":[4],o:[7]},pathStateMachine[1]={w:[1],".":[2],"[":[4],o:[7]},pathStateMachine[2]={w:[2],i:[3,0],0:[3,0]},pathStateMachine[3]={i:[3,0],0:[3,0],w:[1,1],".":[2,1],"[":[4,1],o:[7,1]},pathStateMachine[4]={"'":[5,0],'"':[6,0],"[":[4,2],"]":[1,3],o:8,l:[4,0]},pathStateMachine[5]={"'":[4,0],o:8,l:[5,0]},pathStateMachine[6]={'"':[4,0],o:8,l:[6,0]};function resolveWithKeyValue(obj,path){return isObject(obj)?obj[path]:null}var CoreWarnCodes={NOT_FOUND_KEY:1,FALLBACK_TO_TRANSLATE:2,CANNOT_FORMAT_NUMBER:3,FALLBACK_TO_NUMBER_FORMAT:4,CANNOT_FORMAT_DATE:5,FALLBACK_TO_DATE_FORMAT:6,EXPERIMENTAL_CUSTOM_MESSAGE_COMPILER:7},CORE_WARN_CODES_EXTEND_POINT=8,warnMessages={[CoreWarnCodes.NOT_FOUND_KEY]:`Not found '{key}' key in '{locale}' locale messages.`,[CoreWarnCodes.FALLBACK_TO_TRANSLATE]:`Fall back to translate '{key}' key with '{target}' locale.`,[CoreWarnCodes.CANNOT_FORMAT_NUMBER]:`Cannot format a number value due to not supported Intl.NumberFormat.`,[CoreWarnCodes.FALLBACK_TO_NUMBER_FORMAT]:`Fall back to number format '{key}' key with '{target}' locale.`,[CoreWarnCodes.CANNOT_FORMAT_DATE]:`Cannot format a date value due to not supported Intl.DateTimeFormat.`,[CoreWarnCodes.FALLBACK_TO_DATE_FORMAT]:`Fall back to datetime format '{key}' key with '{target}' locale.`,[CoreWarnCodes.EXPERIMENTAL_CUSTOM_MESSAGE_COMPILER]:`This project is using Custom Message Compiler, which is an experimental feature. It may receive breaking changes or be removed in the future.`},VERSION$1=`11.1.12`,NOT_REOSLVED=-1,DEFAULT_LOCALE=`en-US`,capitalize=str=>`${str.charAt(0).toLocaleUpperCase()}${str.substr(1)}`;function getDefaultLinkedModifiers(){return{upper:(val,type)=>type===`text`&&isString(val)?val.toUpperCase():type===`vnode`&&isObject(val)&&`__v_isVNode`in val?val.children.toUpperCase():val,lower:(val,type)=>type===`text`&&isString(val)?val.toLowerCase():type===`vnode`&&isObject(val)&&`__v_isVNode`in val?val.children.toLowerCase():val,capitalize:(val,type)=>type===`text`&&isString(val)?capitalize(val):type===`vnode`&&isObject(val)&&`__v_isVNode`in val?capitalize(val.children):val}}var _compiler;function registerMessageCompiler(compiler){_compiler=compiler}var _resolver,_fallbacker,_additionalMeta=null,setAdditionalMeta=meta=>{_additionalMeta=meta},getAdditionalMeta=()=>_additionalMeta,_fallbackContext=null,setFallbackContext=context=>{_fallbackContext=context},getFallbackContext=()=>_fallbackContext,_cid=0;function createCoreContext(options={}){let onWarn=isFunction(options.onWarn)?options.onWarn:warn,version$2=isString(options.version)?options.version:VERSION$1,locale=isString(options.locale)||isFunction(options.locale)?options.locale:DEFAULT_LOCALE,_locale=isFunction(locale)?DEFAULT_LOCALE:locale,fallbackLocale=isArray$1(options.fallbackLocale)||isPlainObject(options.fallbackLocale)||isString(options.fallbackLocale)||options.fallbackLocale===!1?options.fallbackLocale:_locale,messages=isPlainObject(options.messages)?options.messages:createResources(_locale),datetimeFormats=isPlainObject(options.datetimeFormats)?options.datetimeFormats:createResources(_locale),numberFormats=isPlainObject(options.numberFormats)?options.numberFormats:createResources(_locale),modifiers=assign$1(create(),options.modifiers,getDefaultLinkedModifiers()),pluralRules=options.pluralRules||create(),missing=isFunction(options.missing)?options.missing:null,missingWarn=isBoolean(options.missingWarn)||isRegExp(options.missingWarn)?options.missingWarn:!0,fallbackWarn=isBoolean(options.fallbackWarn)||isRegExp(options.fallbackWarn)?options.fallbackWarn:!0,fallbackFormat=!!options.fallbackFormat,unresolving=!!options.unresolving,postTranslation=isFunction(options.postTranslation)?options.postTranslation:null,processor=isPlainObject(options.processor)?options.processor:null,warnHtmlMessage=isBoolean(options.warnHtmlMessage)?options.warnHtmlMessage:!0,escapeParameter=!!options.escapeParameter,messageCompiler=isFunction(options.messageCompiler)?options.messageCompiler:_compiler,messageResolver=isFunction(options.messageResolver)?options.messageResolver:_resolver||resolveWithKeyValue,localeFallbacker=isFunction(options.localeFallbacker)?options.localeFallbacker:_fallbacker||fallbackWithSimple,fallbackContext=isObject(options.fallbackContext)?options.fallbackContext:void 0,internalOptions=options,__datetimeFormatters=isObject(internalOptions.__datetimeFormatters)?internalOptions.__datetimeFormatters:new Map,__numberFormatters=isObject(internalOptions.__numberFormatters)?internalOptions.__numberFormatters:new Map,__meta=isObject(internalOptions.__meta)?internalOptions.__meta:{};_cid++;let context={version:version$2,cid:_cid,locale,fallbackLocale,messages,modifiers,pluralRules,missing,missingWarn,fallbackWarn,fallbackFormat,unresolving,postTranslation,processor,warnHtmlMessage,escapeParameter,messageCompiler,messageResolver,localeFallbacker,fallbackContext,onWarn,__meta};return context.datetimeFormats=datetimeFormats,context.numberFormats=numberFormats,context.__datetimeFormatters=__datetimeFormatters,context.__numberFormatters=__numberFormatters,__INTLIFY_PROD_DEVTOOLS__&&initI18nDevTools(context,version$2,__meta),context}var createResources=locale=>({[locale]:create()});function handleMissing(context,key,locale,missingWarn,type){let{missing,onWarn}=context;if(missing!==null){let ret=missing(context,locale,key,type);return isString(ret)?ret:key}else return key}function updateFallbackLocale(ctx,locale,fallback){let context=ctx;context.__localeChainCache=new Map,ctx.localeFallbacker(ctx,fallback,locale)}function isAlmostSameLocale(locale,compareLocale){return locale===compareLocale?!1:locale.split(`-`)[0]===compareLocale.split(`-`)[0]}function isImplicitFallback(targetLocale,locales){let index=locales.indexOf(targetLocale);if(index===-1)return!1;for(let i=index+1;istr,DEFAULT_MESSAGE=ctx=>``,DEFAULT_MESSAGE_DATA_TYPE=`text`,DEFAULT_NORMALIZE=values=>values.length===0?``:join(values),DEFAULT_INTERPOLATE=toDisplayString$1;function pluralDefault(choice,choicesLength){return choice=Math.abs(choice),choicesLength===2?choice?choice>1?1:0:1:choice?Math.min(choice,2):0}function getPluralIndex(options){let index=isNumber(options.pluralIndex)?options.pluralIndex:-1;return options.named&&(isNumber(options.named.count)||isNumber(options.named.n))?isNumber(options.named.count)?options.named.count:isNumber(options.named.n)?options.named.n:index:index}function normalizeNamed(pluralIndex,props){props.count||=pluralIndex,props.n||=pluralIndex}function createMessageContext(options={}){let locale=options.locale,pluralIndex=getPluralIndex(options),pluralRule=isObject(options.pluralRules)&&isString(locale)&&isFunction(options.pluralRules[locale])?options.pluralRules[locale]:pluralDefault,orgPluralRule=isObject(options.pluralRules)&&isString(locale)&&isFunction(options.pluralRules[locale])?pluralDefault:void 0,plural=messages=>messages[pluralRule(pluralIndex,messages.length,orgPluralRule)],_list=options.list||[],list=index=>_list[index],_named=options.named||create();isNumber(options.pluralIndex)&&normalizeNamed(pluralIndex,_named);let named=key=>_named[key];function message(key,useLinked){return(isFunction(options.messages)?options.messages(key,!!useLinked):isObject(options.messages)?options.messages[key]:!1)||(options.parent?options.parent.message(key):DEFAULT_MESSAGE)}let _modifier=name=>options.modifiers?options.modifiers[name]:DEFAULT_MODIFIER,normalize=isPlainObject(options.processor)&&isFunction(options.processor.normalize)?options.processor.normalize:DEFAULT_NORMALIZE,interpolate=isPlainObject(options.processor)&&isFunction(options.processor.interpolate)?options.processor.interpolate:DEFAULT_INTERPOLATE,ctx={list,named,plural,linked:(key,...args)=>{let[arg1,arg2]=args,type$1=`text`,modifier=``;args.length===1?isObject(arg1)?(modifier=arg1.modifier||modifier,type$1=arg1.type||type$1):isString(arg1)&&(modifier=arg1||modifier):args.length===2&&(isString(arg1)&&(modifier=arg1||modifier),isString(arg2)&&(type$1=arg2||type$1));let ret=message(key,!0)(ctx),msg=type$1===`vnode`&&isArray$1(ret)&&modifier?ret[0]:ret;return modifier?_modifier(modifier)(msg,type$1):msg},message,type:isPlainObject(options.processor)&&isString(options.processor.type)?options.processor.type:DEFAULT_MESSAGE_DATA_TYPE,interpolate,normalize,values:assign$1(create(),_list,_named)};return ctx}var NOOP_MESSAGE_FUNCTION=()=>``,isMessageFunction=val=>isFunction(val);function translate$1(context,...args){let{fallbackFormat,postTranslation,unresolving,messageCompiler,fallbackLocale,messages}=context,[key,options]=parseTranslateArgs(...args),missingWarn=isBoolean(options.missingWarn)?options.missingWarn:context.missingWarn,fallbackWarn=isBoolean(options.fallbackWarn)?options.fallbackWarn:context.fallbackWarn,escapeParameter=isBoolean(options.escapeParameter)?options.escapeParameter:context.escapeParameter,resolvedMessage=!!options.resolvedMessage,defaultMsgOrKey=isString(options.default)||isBoolean(options.default)?isBoolean(options.default)?messageCompiler?key:()=>key:options.default:fallbackFormat?messageCompiler?key:()=>key:null,enableDefaultMsg=fallbackFormat||defaultMsgOrKey!=null&&(isString(defaultMsgOrKey)||isFunction(defaultMsgOrKey)),locale=getLocale(context,options);escapeParameter&&escapeParams(options);let[formatScope,targetLocale,message]=resolvedMessage?[key,locale,messages[locale]||create()]:resolveMessageFormat(context,key,locale,fallbackLocale,fallbackWarn,missingWarn),format$2=formatScope,cacheBaseKey=key;if(!resolvedMessage&&!(isString(format$2)||isMessageAST(format$2)||isMessageFunction(format$2))&&enableDefaultMsg&&(format$2=defaultMsgOrKey,cacheBaseKey=format$2),!resolvedMessage&&(!(isString(format$2)||isMessageAST(format$2)||isMessageFunction(format$2))||!isString(targetLocale)))return unresolving?-1:key;let occurred=!1,msg=isMessageFunction(format$2)?format$2:compileMessageFormat(context,key,targetLocale,format$2,cacheBaseKey,()=>{occurred=!0});if(occurred)return format$2;let messaged=evaluateMessage(context,msg,createMessageContext(getMessageContextOptions(context,targetLocale,message,options))),ret=postTranslation?postTranslation(messaged,key):messaged;if(escapeParameter&&isString(ret)&&(ret=sanitizeTranslatedHtml(ret)),__INTLIFY_PROD_DEVTOOLS__){let payloads={timestamp:Date.now(),key:isString(key)?key:isMessageFunction(format$2)?format$2.key:``,locale:targetLocale||(isMessageFunction(format$2)?format$2.locale:``),format:isString(format$2)?format$2:isMessageFunction(format$2)?format$2.source:``,message:ret};payloads.meta=assign$1({},context.__meta,getAdditionalMeta()||{}),translateDevTools(payloads)}return ret}function escapeParams(options){isArray$1(options.list)?options.list=options.list.map(item=>isString(item)?escapeHtml(item):item):isObject(options.named)&&Object.keys(options.named).forEach(key=>{isString(options.named[key])&&(options.named[key]=escapeHtml(options.named[key]))})}function resolveMessageFormat(context,key,locale,fallbackLocale,fallbackWarn,missingWarn){let{messages,onWarn,messageResolver:resolveValue,localeFallbacker}=context,locales=localeFallbacker(context,fallbackLocale,locale),message=create(),targetLocale,format$2=null,type=`translate`;for(let i=0;iformat$2);return msg$1.locale=targetLocale,msg$1.key=key,msg$1}let msg=messageCompiler(format$2,getCompileContext(context,targetLocale,cacheBaseKey,format$2,warnHtmlMessage,onError));return msg.locale=targetLocale,msg.key=key,msg.source=format$2,msg}function evaluateMessage(context,msg,msgCtx){return msg(msgCtx)}function parseTranslateArgs(...args){let[arg1,arg2,arg3]=args,options=create();if(!isString(arg1)&&!isNumber(arg1)&&!isMessageFunction(arg1)&&!isMessageAST(arg1))throw createCoreError(CoreErrorCodes.INVALID_ARGUMENT);let key=isNumber(arg1)?String(arg1):(isMessageFunction(arg1),arg1);return isNumber(arg2)?options.plural=arg2:isString(arg2)?options.default=arg2:isPlainObject(arg2)&&!isEmptyObject(arg2)?options.named=arg2:isArray$1(arg2)&&(options.list=arg2),isNumber(arg3)?options.plural=arg3:isString(arg3)?options.default=arg3:isPlainObject(arg3)&&assign$1(options,arg3),[key,options]}function getCompileContext(context,locale,key,source,warnHtmlMessage,onError){return{locale,key,warnHtmlMessage,onError:err=>{throw onError&&onError(err),err},onCacheKey:source$1=>generateFormatCacheKey(locale,key,source$1)}}function getMessageContextOptions(context,locale,message,options){let{modifiers,pluralRules,messageResolver:resolveValue,fallbackLocale,fallbackWarn,missingWarn,fallbackContext}=context,ctxOptions={locale,modifiers,pluralRules,messages:(key,useLinked)=>{let val=resolveValue(message,key);if(val==null&&(fallbackContext||useLinked)){let[,,message$1]=resolveMessageFormat(fallbackContext||context,key,locale,fallbackLocale,fallbackWarn,missingWarn);val=resolveValue(message$1,key)}if(isString(val)||isMessageAST(val)){let occurred=!1,msg=compileMessageFormat(context,key,locale,val,key,()=>{occurred=!0});return occurred?NOOP_MESSAGE_FUNCTION:msg}else if(isMessageFunction(val))return val;else return NOOP_MESSAGE_FUNCTION}};return context.processor&&(ctxOptions.processor=context.processor),options.list&&(ctxOptions.list=options.list),options.named&&(ctxOptions.named=options.named),isNumber(options.plural)&&(ctxOptions.pluralIndex=options.plural),ctxOptions}initFeatureFlags$1();var VERSION=`11.1.12`;function initFeatureFlags(){typeof __VUE_I18N_FULL_INSTALL__!=`boolean`&&(getGlobalThis().__VUE_I18N_FULL_INSTALL__=!0),typeof __VUE_I18N_LEGACY_API__!=`boolean`&&(getGlobalThis().__VUE_I18N_LEGACY_API__=!0),typeof __INTLIFY_DROP_MESSAGE_COMPILER__!=`boolean`&&(getGlobalThis().__INTLIFY_DROP_MESSAGE_COMPILER__=!1),typeof __INTLIFY_PROD_DEVTOOLS__!=`boolean`&&(getGlobalThis().__INTLIFY_PROD_DEVTOOLS__=!1)}var I18nErrorCodes={UNEXPECTED_RETURN_TYPE:24,INVALID_ARGUMENT:25,MUST_BE_CALL_SETUP_TOP:26,NOT_INSTALLED:27,REQUIRED_VALUE:28,INVALID_VALUE:29,CANNOT_SETUP_VUE_DEVTOOLS_PLUGIN:30,NOT_INSTALLED_WITH_PROVIDE:31,UNEXPECTED_ERROR:32,NOT_COMPATIBLE_LEGACY_VUE_I18N:33,NOT_AVAILABLE_COMPOSITION_IN_LEGACY:34};function createI18nError(code,...args){return createCompileError(code,null,void 0)}I18nErrorCodes.UNEXPECTED_RETURN_TYPE,I18nErrorCodes.INVALID_ARGUMENT,I18nErrorCodes.MUST_BE_CALL_SETUP_TOP,I18nErrorCodes.NOT_INSTALLED,I18nErrorCodes.UNEXPECTED_ERROR,I18nErrorCodes.REQUIRED_VALUE,I18nErrorCodes.INVALID_VALUE,I18nErrorCodes.CANNOT_SETUP_VUE_DEVTOOLS_PLUGIN,I18nErrorCodes.NOT_INSTALLED_WITH_PROVIDE,I18nErrorCodes.NOT_COMPATIBLE_LEGACY_VUE_I18N,I18nErrorCodes.NOT_AVAILABLE_COMPOSITION_IN_LEGACY;var SetPluralRulesSymbol=makeSymbol(`__setPluralRules`);makeSymbol(`__intlifyMeta`);var I18nWarnCodes={FALLBACK_TO_ROOT:8,NOT_FOUND_PARENT_SCOPE:9,IGNORE_OBJ_FLATTEN:10,DEPRECATE_LEGACY_MODE:11,DEPRECATE_TRANSLATE_CUSTOME_DIRECTIVE:12,DUPLICATE_USE_I18N_CALLING:13};I18nWarnCodes.FALLBACK_TO_ROOT,I18nWarnCodes.NOT_FOUND_PARENT_SCOPE,I18nWarnCodes.IGNORE_OBJ_FLATTEN,I18nWarnCodes.DEPRECATE_LEGACY_MODE,I18nWarnCodes.DEPRECATE_TRANSLATE_CUSTOME_DIRECTIVE,I18nWarnCodes.DUPLICATE_USE_I18N_CALLING;function handleFlatJson(obj){if(!isObject(obj)||isMessageAST(obj))return obj;for(let key in obj)if(hasOwn(obj,key))if(!key.includes(`.`))isObject(obj[key])&&handleFlatJson(obj[key]);else{let subKeys=key.split(`.`),lastIndex=subKeys.length-1,currentObj=obj,hasStringValue=!1;for(let i=0;i{if(`locale`in custom&&`resource`in custom){let{locale:locale$1,resource}=custom;locale$1?(ret[locale$1]=ret[locale$1]||create(),deepCopy(resource,ret[locale$1])):deepCopy(resource,ret)}else isString(custom)&&deepCopy(JSON.parse(custom),ret)}),messageResolver==null&&flatJson)for(let key in ret)hasOwn(ret,key)&&handleFlatJson(ret[key]);return ret}function getComponentOptions(instance$1){return instance$1.type}var DEVTOOLS_META=`__INTLIFY_META__`,composerID=0;function defineCoreMissingHandler(missing){return((ctx,locale,key,type)=>missing(locale,key,getCurrentInstance()||void 0,type))}var getMetaInfo=()=>{let instance$1=getCurrentInstance(),meta=null;return instance$1&&(meta=getComponentOptions(instance$1)[DEVTOOLS_META])?{[DEVTOOLS_META]:meta}:null};function createComposer(options={}){let{__root,__injectWithOption}=options,_isGlobal=__root===void 0,flatJson=options.flatJson,_ref=inBrowser?ref:shallowRef,_inheritLocale=isBoolean(options.inheritLocale)?options.inheritLocale:!0,_locale=_ref(__root&&_inheritLocale?__root.locale.value:isString(options.locale)?options.locale:DEFAULT_LOCALE),_fallbackLocale=_ref(__root&&_inheritLocale?__root.fallbackLocale.value:isString(options.fallbackLocale)||isArray$1(options.fallbackLocale)||isPlainObject(options.fallbackLocale)||options.fallbackLocale===!1?options.fallbackLocale:_locale.value),_messages=_ref(getLocaleMessages(_locale.value,options)),_missingWarn=__root?__root.missingWarn:isBoolean(options.missingWarn)||isRegExp(options.missingWarn)?options.missingWarn:!0,_fallbackWarn=__root?__root.fallbackWarn:isBoolean(options.fallbackWarn)||isRegExp(options.fallbackWarn)?options.fallbackWarn:!0,_fallbackRoot=__root?__root.fallbackRoot:isBoolean(options.fallbackRoot)?options.fallbackRoot:!0,_fallbackFormat=!!options.fallbackFormat,_missing=isFunction(options.missing)?options.missing:null,_runtimeMissing=isFunction(options.missing)?defineCoreMissingHandler(options.missing):null,_postTranslation=isFunction(options.postTranslation)?options.postTranslation:null,_warnHtmlMessage=__root?__root.warnHtmlMessage:isBoolean(options.warnHtmlMessage)?options.warnHtmlMessage:!0,_escapeParameter=!!options.escapeParameter,_modifiers=__root?__root.modifiers:isPlainObject(options.modifiers)?options.modifiers:{},_pluralRules=options.pluralRules||__root&&__root.pluralRules,_context;_context=(()=>{_isGlobal&&setFallbackContext(null);let ctx=createCoreContext({version:VERSION,locale:_locale.value,fallbackLocale:_fallbackLocale.value,messages:_messages.value,modifiers:_modifiers,pluralRules:_pluralRules,missing:_runtimeMissing===null?void 0:_runtimeMissing,missingWarn:_missingWarn,fallbackWarn:_fallbackWarn,fallbackFormat:_fallbackFormat,unresolving:!0,postTranslation:_postTranslation===null?void 0:_postTranslation,warnHtmlMessage:_warnHtmlMessage,escapeParameter:_escapeParameter,messageResolver:options.messageResolver,messageCompiler:options.messageCompiler,__meta:{framework:`vue`}});return _isGlobal&&setFallbackContext(ctx),ctx})(),updateFallbackLocale(_context,_locale.value,_fallbackLocale.value);function trackReactivityValues(){return[_locale.value,_fallbackLocale.value,_messages.value]}let locale=computed({get:()=>_locale.value,set:val=>{_context.locale=val,_locale.value=val}}),fallbackLocale=computed({get:()=>_fallbackLocale.value,set:val=>{_context.fallbackLocale=val,_fallbackLocale.value=val,updateFallbackLocale(_context,_locale.value,val)}}),messages=computed(()=>_messages.value);function getPostTranslationHandler(){return isFunction(_postTranslation)?_postTranslation:null}function setPostTranslationHandler(handler$1){_postTranslation=handler$1,_context.postTranslation=handler$1}function getMissingHandler(){return _missing}function setMissingHandler(handler$1){handler$1!==null&&(_runtimeMissing=defineCoreMissingHandler(handler$1)),_missing=handler$1,_context.missing=_runtimeMissing}let wrapWithDeps=(fn,argumentParser,warnType,fallbackSuccess,fallbackFail,successCondition)=>{trackReactivityValues();let ret;try{__INTLIFY_PROD_DEVTOOLS__,_isGlobal||(_context.fallbackContext=__root?getFallbackContext():void 0),ret=fn(_context)}finally{__INTLIFY_PROD_DEVTOOLS__,_isGlobal||(_context.fallbackContext=void 0)}if(isNumber(ret)&&ret===-1||warnType===`translate exists`){let[key,arg2]=argumentParser();return __root&&_fallbackRoot?fallbackSuccess(__root):fallbackFail(key)}else if(successCondition(ret))return ret;else throw createI18nError(I18nErrorCodes.UNEXPECTED_RETURN_TYPE)};function t(...args){return wrapWithDeps(context=>Reflect.apply(translate$1,null,[context,...args]),()=>parseTranslateArgs(...args),`translate`,root=>Reflect.apply(root.t,root,[...args]),key=>key,val=>isString(val))}function setPluralRules(rules){_pluralRules=rules,_context.pluralRules=_pluralRules}function getLocaleMessage(locale$1){return _messages.value[locale$1]||{}}function setLocaleMessage(locale$1,message){if(flatJson){let _message={[locale$1]:message};for(let key in _message)hasOwn(_message,key)&&handleFlatJson(_message[key]);message=_message[locale$1]}_messages.value[locale$1]=message,_context.messages=_messages.value}function mergeLocaleMessage(locale$1,message){_messages.value[locale$1]=_messages.value[locale$1]||{};let _message={[locale$1]:message};if(flatJson)for(let key in _message)hasOwn(_message,key)&&handleFlatJson(_message[key]);message=_message[locale$1],deepCopy(message,_messages.value[locale$1]),_context.messages=_messages.value}return composerID++,__root&&inBrowser&&(watch(__root.locale,val=>{_inheritLocale&&(_locale.value=val,_context.locale=val,updateFallbackLocale(_context,_locale.value,_fallbackLocale.value))}),watch(__root.fallbackLocale,val=>{_inheritLocale&&(_fallbackLocale.value=val,_context.fallbackLocale=val,updateFallbackLocale(_context,_locale.value,_fallbackLocale.value))})),{id:composerID,locale,fallbackLocale,get inheritLocale(){return _inheritLocale},set inheritLocale(val){_inheritLocale=val,val&&__root&&(_locale.value=__root.locale.value,_fallbackLocale.value=__root.fallbackLocale.value,updateFallbackLocale(_context,_locale.value,_fallbackLocale.value))},get availableLocales(){return Object.keys(_messages.value).sort()},messages,get modifiers(){return _modifiers},get pluralRules(){return _pluralRules||{}},get isGlobal(){return _isGlobal},get missingWarn(){return _missingWarn},set missingWarn(val){_missingWarn=val,_context.missingWarn=_missingWarn},get fallbackWarn(){return _fallbackWarn},set fallbackWarn(val){_fallbackWarn=val,_context.fallbackWarn=_fallbackWarn},get fallbackRoot(){return _fallbackRoot},set fallbackRoot(val){_fallbackRoot=val},get fallbackFormat(){return _fallbackFormat},set fallbackFormat(val){_fallbackFormat=val,_context.fallbackFormat=_fallbackFormat},get warnHtmlMessage(){return _warnHtmlMessage},set warnHtmlMessage(val){_warnHtmlMessage=val,_context.warnHtmlMessage=val},get escapeParameter(){return _escapeParameter},set escapeParameter(val){_escapeParameter=val,_context.escapeParameter=val},t,getLocaleMessage,setLocaleMessage,mergeLocaleMessage,getPostTranslationHandler,setPostTranslationHandler,getMissingHandler,setMissingHandler,[SetPluralRulesSymbol]:setPluralRules}}function createI18n(options={}){let __globalInjection=isBoolean(options.globalInjection)?options.globalInjection:!0,__instances=new Map,[globalScope,__global]=createGlobal(options),symbol=makeSymbol(``);function __getInstance(component){return __instances.get(component)||null}function __setInstance(component,instance$1){__instances.set(component,instance$1)}function __deleteInstance(component){__instances.delete(component)}let i18n={get mode(){return`composition`},async install(app$1,...options$1){if(app$1.__VUE_I18N_SYMBOL__=symbol,app$1.provide(app$1.__VUE_I18N_SYMBOL__,i18n),isPlainObject(options$1[0])){let opts=options$1[0];i18n.__composerExtend=opts.__composerExtend,i18n.__vueI18nExtend=opts.__vueI18nExtend}let globalReleaseHandler=null;__globalInjection&&(globalReleaseHandler=injectGlobalFields(app$1,i18n.global));let unmountApp=app$1.unmount;app$1.unmount=()=>{globalReleaseHandler&&globalReleaseHandler(),i18n.dispose(),unmountApp()}},get global(){return __global},dispose(){globalScope.stop()},__instances,__getInstance,__setInstance,__deleteInstance};return i18n}function createGlobal(options,legacyMode){let scope$1=effectScope(),obj=scope$1.run(()=>createComposer(options));if(obj==null)throw createI18nError(I18nErrorCodes.UNEXPECTED_ERROR);return[scope$1,obj]}var globalExportProps=[`locale`,`fallbackLocale`,`availableLocales`],globalExportMethods=[`t`];function injectGlobalFields(app$1,composer){let i18n=Object.create(null);return globalExportProps.forEach(prop=>{let desc=Object.getOwnPropertyDescriptor(composer,prop);if(!desc)throw createI18nError(I18nErrorCodes.UNEXPECTED_ERROR);let wrap=isRef(desc.value)?{get(){return desc.value.value},set(val){desc.value.value=val}}:{get(){return desc.get&&desc.get()}};Object.defineProperty(i18n,prop,wrap)}),app$1.config.globalProperties.$i18n=i18n,globalExportMethods.forEach(method=>{let desc=Object.getOwnPropertyDescriptor(composer,method);if(!desc||!desc.value)throw createI18nError(I18nErrorCodes.UNEXPECTED_ERROR);Object.defineProperty(app$1.config.globalProperties,`$${method}`,desc)}),()=>{delete app$1.config.globalProperties.$i18n,globalExportMethods.forEach(method=>{delete app$1.config.globalProperties[`$${method}`]})}}if(initFeatureFlags(),registerMessageCompiler(compile),__INTLIFY_PROD_DEVTOOLS__){let target=getGlobalThis();target.__INTLIFY__=!0,setDevToolsHook(target.__INTLIFY_DEVTOOLS_GLOBAL_HOOK__)}const emptyImage=`data:image/svg+xml,`;function getURL(path){return typeof path!=`string`||!path||path.includes(`://`)?path:(path.startsWith(`/`)&&(path=path.substring(1)),`/${path}`)}function getAssetURL(assetPath){let url=getURL(assetPath);return typeof url!=`string`||!url||url.startsWith(`/`)&&(url=`/ui/ui-vue/src/assets`+url),url}const getFile=(url,timeout=5)=>new Promise((resolve$1,reject)=>{try{let xhr=new XMLHttpRequest,tmr=timeout>0?setTimeout(()=>{xhr.abort(),reject(Error(`Timeout`))},timeout*1e3):null;xhr.open(`GET`,url,!0),xhr.onload=()=>{tmr&&clearTimeout(tmr),xhr.status===200?resolve$1(xhr.responseText):reject(Error(`Failed with code ${xhr.status}`))},xhr.send()}catch(err){reject(err)}}),ucaseFirst=str=>str[0].toUpperCase()+str.slice(1),defer=()=>{let noop$3=()=>{},resolve$1,reject,_notifyHandler=noop$3,promise=new Promise((res,rej)=>{[resolve$1,reject]=[res,rej]});return{promise:{then:(resolveHandler,rejectHandler=noop$3,notifyHandler=noop$3)=>(_notifyHandler=notifyHandler,promise.then(resolveHandler,rejectHandler))},resolve:resolve$1,reject,notify:val=>_notifyHandler(val)}},sleep=ms=>new Promise(resolve$1=>setTimeout(resolve$1,ms)),debounce=(func,wait,immediate)=>{let timeout;function call(...args){let context=this,later=()=>{timeout=null,immediate||func.apply(context,args)},callNow=immediate&&!timeout;timeout&&window.clearTimeout(timeout),timeout=window.setTimeout(later,wait),callNow&&func.apply(context,args)}return call.cancel=()=>timeout&&window.clearTimeout(timeout),call};var Settings=class{options=reactive({});values=reactive({});_previousValues={};_changedValues={};_watcher=null;_syncPending=!1;inited=!1;loaded=!1;_lua;constructor(eventBus$1=void 0,lua=void 0){eventBus$1&&lua&&this.init(eventBus$1,lua)}init(eventBus$1=void 0,lua=void 0){if(!(this.inited||this.loaded)){if(this.inited=!0,!eventBus$1||!lua){let bridge$4=useBridge();eventBus$1||=bridge$4.events,lua||=bridge$4.lua}eventBus$1.on(`SettingsChanged`,data=>{Object.assign(this.options,data.options),Object.assign(this.values,data.values),this._previousValues=this.clone(data.values),this._changedValues={},this._watcher||=watch(()=>this.values,()=>this._syncChanges(),{deep:!0,flush:`sync`}),this.loaded=!0}),this._syncChangesDebounced=debounce(this._syncChangesImmediate,100),this._lua=lua,this.update()}}async waitForData(){for(;!this.inited||!this.loaded;)await sleep(10)}async update(){if(this._lua)return await this._lua.settings.notifyUI()}clone(data){return JSON.parse(JSON.stringify(data))}getValue(field=null){if(this.loaded)return field&&!(field in this.values)?null:this.clone(field?this.values[field]:this.values)}get changesPending(){return this._syncChangesImmediate(),Object.keys(this._changedValues).length>0}get pendingChanges(){return this._syncChangesImmediate(),this.clone(this._changedValues)}_syncChanges(){this._syncPending=!0,this._syncChangesDebounced()}_syncChangesDebounced=()=>{};_syncChangesImmediate(){if(this._syncPending)for(let key in this._syncPending=!1,this.values)this._previousValues[key]===this.values[key]?key in this._changedValues&&delete this._changedValues[key]:this._changedValues[key]=this.values[key]}async apply(values=void 0){if(!this.loaded)return;let res;if(values)res=this.clone(values);else{if(!this.changesPending)return;res={...this._changedValues},this._changedValues={}}return Object.assign(this._previousValues,res),await this._lua.settings.setState(res)}},settings=new Settings;function useSettings(){return settings.init(),settings}async function useSettingsAsync(){return settings.init(),await settings.waitForData(),settings}var ANGULAR_TRANSLATE=[],_angularTranslateFunc,_i18n,i18nVariant=`petite`,defaultLocale=`en-US`,localeCheckId=`ui.common.okay`,checkLocale=()=>_i18n&&_i18n.global.t(localeCheckId)!==localeCheckId,translate=val=>val;const initTranslation=()=>{if(window.vueI18n?.__bng_i18n_variant!==i18nVariant){window.vueI18n&&console.warn(`Localisation library is already initialized, but its variant was not validated. Reloading...`);let creationArguments={locale:defaultLocale,fallbackLocale:defaultLocale,silentTranslationWarn:!0,fallbackWarn:!1,missingWarn:!1,warnHtmlMessage:!1};window.beamng&&!window.beamng.shipping&&(creationArguments.fallbackLocale=[defaultLocale,`not-shipping.internal`]),window.vueI18n=createI18n(creationArguments),window.vueI18n.__bng_i18n_variant=i18nVariant}return _i18n=window.vueI18n,{i18n:_i18n,plugin:translationPlugin}},loadLocale=async(locale,force=!1)=>{if(!(_i18n.global.availableLocales.includes(locale)&&!force))try{let url=getURL(`/locales/${locale}.json`),resp;try{resp=await getFile(url,5)}catch(err){if(err.message!==`Timeout`)throw err;console.warn(`Locale ${locale} load timed out, retrying with a bigger timeout...`),resp=await getFile(url,10)}_i18n.global.setLocaleMessage(locale,preprocessLocaleJSON(JSON.parse(resp)))}catch(err){console.error(`Failed to load ${locale} locale`,err)}};var setupUserLanguage=async()=>{let settings$1=await useSettingsAsync();watch(()=>settings$1.values.uiLanguage,async lang=>{lang&&lang!==defaultLocale&&await loadLocale(lang),_i18n.global.locale.value=_i18n.global.availableLocales.includes(lang)?lang:defaultLocale,lang!==defaultLocale&&!checkLocale()&&console.warn(`Locale ${lang} is not behaving properly`)},{immediate:!0})};const translationPlugin=()=>({install(app$1,options){return _i18n.global.locale.value=defaultLocale,loadLocale(defaultLocale,!0).then(async()=>{checkLocale()||(console.warn(`Failed to load default locale, retrying...`),await loadLocale(defaultLocale,!0),checkLocale()||console.error(`Failed to load default locale!`)),await setupUserLanguage()}),contextTranslatePlugin().install(app$1,options)}}),contextTranslatePlugin=()=>({install(app$1,options){translate=_wrapTranslate(app$1.config.globalProperties.$t||_i18n.global.t),app$1.config.globalProperties.$t=_i18n.global.t,app$1.config.globalProperties.$ctx_t=(val,translateContext=!0)=>contextTranslate(val,translateContext),app$1.config.globalProperties.$mctx_t=multiContextTranslate,app$1.config.globalProperties.$tt=translate}});var contextTranslate=(val,translateContext=!1)=>{let type=typeof val;if(type===`undefined`||val===null)return``;if(type===`object`)if(val.txt&&val.context){let context=val.context;if(translateContext)for(let key in context={...context},context)context[key]=contextTranslate(context[key],!0);return getTranslation(val.txt,context)}else val=val.txt||``;return getTranslation(``+val)},multiContextTranslate=val=>{if(val.txt)return contextTranslate(val);let description=``;for(let i of val)description+=contextTranslate(i);return description},getAngularTranslationFunc=()=>_angularTranslateFunc||(window.angular$translate&&(_angularTranslateFunc=window.angular$translate.instant.bind(window.angular$translate)),_angularTranslateFunc||translate),getTranslation=(...vals)=>(ANGULAR_TRANSLATE.includes(vals[0])?getAngularTranslationFunc():translate)(...vals);const $translate={instant:val=>val===void 0?``:translate(val),contextTranslate,multiContextTranslate};var rgxAngular=/{{.+}}/,rgxAngularTranslation=/([^ ]?){{ *(?::: *)?'([^ |}]+)' *\| *translate *}}([^\w]?)/gi;function translateAngularToVue(text){let vueText=text.replace(rgxAngularTranslation,(_,q1,s,q2)=>(q1?`${q1} `:``)+`@:${s}`+(q2?` ${q2}`:``));return vueText=vueText.replace(/{{ *([a-z\d_.]+) *}}/gi,`{$1}`),vueText===text||rgxAngular.test(vueText)?null:vueText}const preprocessLocaleJSON=obj=>{let messages={};for(let key in obj){if(ANGULAR_TRANSLATE.includes(key))continue;let text=obj[key];if(rgxAngular.test(text)){let vueText=translateAngularToVue(text);vueText?messages[key]=vueText:ANGULAR_TRANSLATE.includes(key)||ANGULAR_TRANSLATE.push(key)}else messages[key]=text}return messages};var rgxLinkedTranslation=/@:([a-zA-Z0-9_][a-zA-Z0-9_.-]+[a-zA-Z0-9_])/g,linkedNamespace=`__linked_custom`;function _linkedTranslation(msg){if(!msg.includes(`@:`)||!rgxLinkedTranslation.test(msg))return msg;let locale=_i18n.global.locale.value,messages=_i18n.global.messages.value[locale];msg=msg.replace(rgxLinkedTranslation,(_,id)=>`@:`+id);let uniqueId$1=``,match;for(rgxLinkedTranslation.lastIndex=0;(match=rgxLinkedTranslation.exec(msg))!==null;)uniqueId$1+=match[1].replace(/\./g,`_`)+`__`;let fullId,messageId,counter$1=0;for(;counter$1<100;){messageId=uniqueId$1+ ++counter$1,fullId=linkedNamespace+`.`+messageId;let existingMessage=messages[fullId];if(!existingMessage){_i18n.global.mergeLocaleMessage(locale,{[fullId]:msg});break}if(existingMessage===msg)break}return fullId}function _wrapTranslate(f){function translate$2(...args){let key=args[0];return key?typeof key!=`string`||(key=_linkedTranslation(key),key.includes(` `))?key:f.apply(this,[key,...args.slice(1)]):``}return Object.defineProperty(translate$2,`name`,{value:f.name}),translate$2}const UI_NAV_ACTION_GROUP=`UINavActions`,GAME_UI_NAVIGATION_EVENT=`UINavigation`,GAME_UI_NAV_MAP_ENABLED_EVENT=`MenuActionMapEnabled`,DOM_UI_NAVIGATION_EVENT=`ui_nav`,ACTIONS_BY_UI_EVENT={focus_u:`menu_item_up`,focus_r:`menu_item_right`,focus_d:`menu_item_down`,focus_l:`menu_item_left`,menu:`toggleMenues`,back:`menu_item_back`,details:`cui_details`,advanced:`cui_advanced`,camera:`cui_camera`,logs:`cui_logs`,tab_l:`menu_tab_left`,tab_r:`menu_tab_right`,modifier:`cui_modifier`,action_4:`cui_action_4`,focus_ud:`menu_item_focus_ud`,focus_lr:`menu_item_focus_lr`,rotate_h_cam:`menu_item_radial_right_x`,rotate_v_cam:`menu_item_radial_right_y`,ok:`menu_item_select`,cancel:`cui_cancel`,action_2:`cui_action_2`,action_3:`cui_action_3`,context:`cui_context`,gameplay_interact:`cui_gameplay_interact`},UI_EVENTS_BY_ACTION=Object.assign({},...Object.entries(ACTIONS_BY_UI_EVENT).map(([k,v])=>({[v]:k}))),UI_EVENTS={focus_u:`focus_u`,focus_r:`focus_r`,focus_d:`focus_d`,focus_l:`focus_l`,pause:`pause`,menu:`menu`,back:`back`,details:`details`,advanced:`advanced`,camera:`camera`,logs:`logs`,tab_l:`tab_l`,tab_r:`tab_r`,modifier:`modifier`,zoom_out:`zoom_out`,zoom_in:`zoom_in`,subtab_l:`subtab_l`,subtab_r:`subtab_r`,center_cam:`center_cam`,action_4:`action_4`,move_ud:`move_ud`,move_lr:`move_lr`,focus_ud:`focus_ud`,focus_lr:`focus_lr`,rotate_h_cam:`rotate_h_cam`,rotate_v_cam:`rotate_v_cam`,ok:`ok`,cancel:`cancel`,action_2:`action_2`,action_3:`action_3`,context:`context`,gameplay_interact:`gameplay_interact`},UI_EVENT_GROUPS={focusMove:[UI_EVENTS.focus_u,UI_EVENTS.focus_d,UI_EVENTS.focus_l,UI_EVENTS.focus_r],focusMoveScalar:[UI_EVENTS.focus_ud,UI_EVENTS.focus_lr],moveScalar:[UI_EVENTS.move_ud,UI_EVENTS.move_lr],navigation:[UI_EVENTS.focus_u,UI_EVENTS.focus_d,UI_EVENTS.focus_l,UI_EVENTS.focus_r,UI_EVENTS.focus_ud,UI_EVENTS.focus_lr,UI_EVENTS.move_ud,UI_EVENTS.move_lr],allEvents:Object.keys(ACTIONS_BY_UI_EVENT)},NAV_ACTIONS=[`focus_u`,`focus_d`,`focus_l`,`focus_r`],VALUE_BASED_EVENTS=[`zoom_out`,`zoom_in`,`subtab_l`,`subtab_r`,`move_ud`,`move_lr`,`focus_ud`,`focus_lr`,`rotate_h_cam`,`rotate_v_cam`],UI_SCOPE_ATTR$2=`bng-ui-scope`,UI_EVENT_ATTR=`ui-nav-event`;var UINavEventProcessor=class{constructor(){this.isModified=!1}processEvent(name,value=void 0,extras=[],context={}){return!this.isValidGameContext()||context.isEventBlocked&&context.isEventBlocked(name)?null:(this.handleModifierState(name,value),this.shouldHandleWithAngular(name,value)?(this.handleAngularIntegration(),null):this.createEventData(name,value,extras))}isValidGameContext(){return window.beamng?.ingame}handleModifierState(name,value){name===`modifier`&&(this.isModified=value===1)}shouldHandleWithAngular(name,value){return window.globalAngularRootScope&&window.bngIntroShown&&(name===`menu`||name===`back`)&&value===1}handleAngularIntegration(){window.globalAngularRootScope.$broadcast(`MenuToggle`)}createEventData(name,value,extras){let activeElement=document.activeElement,targetScope=null;if(activeElement&&activeElement!==document.body){let scopeElement=activeElement.closest(`[${UI_SCOPE_ATTR$2}]`);scopeElement&&(targetScope=scopeElement.getAttribute(UI_SCOPE_ATTR$2))}return{name,value,modified:name!==`modifier`&&this.isModified,extras,boundAction:ACTIONS_BY_UI_EVENT[name],sendToCrossfire:!0,targetScope}}getEventBroadcastElement(activeScope){let activeElement=document.activeElement;if(activeElement&&activeElement!==document.body)return activeElement;if(activeScope){let scopeElement=document.querySelector(`[${UI_SCOPE_ATTR$2}="${activeScope}"]`);if(scopeElement)return scopeElement}return document.body}},UINavActionHandlers=class{constructor(eventBus$1=null){this._useCrossfire=!0,this.eventBus=eventBus$1}setUseCrossfire(enabled){this._useCrossfire=enabled}get useCrossfire(){return this._useCrossfire}setEventBus(eventBus$1){this.eventBus=eventBus$1}handleGlobalEvent=event=>{let eventData=event.detail;eventData.value===1&&(this.handleMenuActions(eventData)||this.handleNavigationActions(eventData)||this.handleGameActions(eventData))||(this.useCrossfire&&eventData.sendToCrossfire&&handleUINavEvent(event),event.defaultPrevented||(this.handleTabNavigation(eventData),this.handleCameraRotation(eventData),this.handleContextActions(eventData)))};handleMenuActions=eventData=>{if(eventData.name===`menu`||eventData.name===`back`){let globalAngularRootScope=window.globalAngularRootScope;return globalAngularRootScope?(globalAngularRootScope.$broadcast(`MenuToggle`),!1):!0}return!1};handleNavigationActions(eventData){if(NAV_ACTIONS.includes(eventData.name)){Lua_default.extensions.hook(`onMenuItemNavigation`);return}return!1}handleGameActions(eventData){switch(eventData.name){case`pause`:return Lua_default.simTimeAuthority.togglePause(),!0;case`center_cam`:return runRaw(`if core_camera then core_camera.resetCamera(${eventData.extras.player}) end`,!1),!0;default:return!1}}handleTabNavigation(eventData){if(eventData.value===1)switch(eventData.name){case`tab_l`:this.eventBus.emit(`ui_topBar_selectPrevious`);break;case`tab_r`:this.eventBus.emit(`ui_topBar_selectNext`);break}}handleCameraRotation(eventData){if(eventData.name===`rotate_h_cam`||eventData.name===`rotate_v_cam`){let camDir=eventData.name===`rotate_v_cam`?`pitch`:`yaw`,[filterType]=eventData.extras||[0];runRaw(`if core_camera then core_camera.rotate_${camDir}(${eventData.value}, ${filterType}) end`,!1)}}handleContextActions(eventData){[`context`,`details`,`camera`].includes(eventData.name)&&eventData.value===1&&this.isBigMapContext()&&runRaw(`if freeroam_bigMapMode then freeroam_bigMapMode.toggleBigMap() end`,!1)}isBigMapContext(){return[`#/bigmap`,`#/menu.bigmap`,`#/play`,`#/menu/bigmap`].includes(window.location.hash)}},UINavService=class{constructor(eventBus$1){this._eventBus=eventBus$1,this._eventsActive=!1,this._globalEventsHooked=!1,this._activeScope=void 0,this._blockedEvents=[],this.eventProcessor=new UINavEventProcessor,this.actionHandlers=new UINavActionHandlers(eventBus$1),this.useCrossfire=!0}initialize(){this.attachEventListeners(),this.hookGlobalEvents()}handleGameEvent=(name,value,...extras)=>{let context={activeScope:this.activeScope,isEventBlocked:eventName=>this.isEventBlocked(eventName)},eventData=this.eventProcessor.processEvent(name,value,extras,context);eventData&&this.dispatchDOMEvent(eventData)};blockEvents(...events$3){let eventsToAdd=events$3.flat().filter(event=>!this._blockedEvents.includes(event));this._blockedEvents.push(...eventsToAdd)}unblockEvents(...events$3){let eventsToRemove=events$3.flat();this._blockedEvents=this._blockedEvents.filter(event=>!eventsToRemove.includes(event))}setBlockedEvents(events$3=[]){this._blockedEvents=[...events$3]}clearBlockedEvents(){this._blockedEvents=[]}isEventBlocked(eventName){return this._blockedEvents.includes(eventName)}getBlockedEvents(){return[...this._blockedEvents]}handleEnabledChange=state=>{this.eventsActive=state};dispatchDOMEvent=eventData=>{let event=new CustomEvent(DOM_UI_NAVIGATION_EVENT,{detail:eventData,cancelable:!0,bubbles:!0});this.eventProcessor.getEventBroadcastElement(this.activeScope).dispatchEvent(event)};fireEvent(uiEvent,value){this._eventBus&&(value instanceof PointerEvent?(this._eventBus.emit(GAME_UI_NAVIGATION_EVENT,uiEvent,1),this._eventBus.emit(GAME_UI_NAVIGATION_EVENT,uiEvent,0)):this._eventBus.emit(GAME_UI_NAVIGATION_EVENT,uiEvent,typeof value==`number`?value:value?1:0))}setActiveScope(scopeId){this._activeScope=scopeId}get activeScope(){return this._activeScope}activate(state=!0){this.attachEventListeners(state),this.eventsActive=state}hookGlobalEvents(state=!0){let listenerAction=document.body[state?`addEventListener`:`removeEventListener`];listenerAction(DOM_UI_NAVIGATION_EVENT,this.actionHandlers.handleGlobalEvent),this.globalEventsHooked=state}attachEventListeners(state=!0){this._eventBus&&(this._eventBus.off(GAME_UI_NAVIGATION_EVENT),this._eventBus.off(GAME_UI_NAV_MAP_ENABLED_EVENT),state&&(this._eventBus.on(GAME_UI_NAVIGATION_EVENT,this.handleGameEvent),this._eventBus.on(GAME_UI_NAV_MAP_ENABLED_EVENT,this.handleEnabledChange)))}setFilteredEvents(...events$3){this.clearFilteredEvents();let actionsToFilter=[...new Set(events$3.flat(1/0))].map(event=>ACTIONS_BY_UI_EVENT[event]);Lua_default.extensions.core_input_actionFilter.setGroup(UI_NAV_ACTION_GROUP,actionsToFilter),Lua_default.extensions.core_input_actionFilter.addAction(0,UI_NAV_ACTION_GROUP,!0)}setFilteredEventsAllExcept(...events$3){let eventsToNotFilter=[...new Set(events$3.flat(1/0))],eventsToFilter=Object.keys(ACTIONS_BY_UI_EVENT).filter(ev=>!eventsToNotFilter.includes(ev));this.setFilteredEvents(eventsToFilter)}clearFilteredEvents(){Lua_default.extensions.core_input_actionFilter.addAction(0,UI_NAV_ACTION_GROUP,!1),Lua_default.extensions.core_input_actionFilter.setGroup(UI_NAV_ACTION_GROUP,[])}set eventsActive(value){this._eventsActive=value}get eventsActive(){return this._eventsActive}set globalEventsHooked(value){this._globalEventsHooked=value}get globalEventsHooked(){return this._globalEventsHooked}get useCrossfire(){return this.actionHandlers.useCrossfire}set useCrossfire(value){this.actionHandlers.setUseCrossfire(value)}get eventBus(){return this._eventBus}},instance=null;const setUINavServiceInstance=serviceInstance=>{instance=serviceInstance},getUINavServiceInstance=()=>{if(!instance)throw Error(`UINavService not initialized.`);return instance},SCOPED_NAV_ATTR=`bng-scoped-nav`,SCOPED_NAV_PROPERTY_NAME=`_bngScopedNav`,UI_SCOPE_ATTR$1=`bng-ui-scope`,BNG_ON_UI_NAV_ATTR$1=`__BngOnUiNav`,ATTR_NAME$1=`bng-scoped-nav`,PASSTHROUGH_EXCLUDED_EVENTS=[UI_EVENTS.ok,UI_EVENTS.back,UI_EVENT_GROUPS.focusMove,UI_EVENT_GROUPS.focusMoveScalar],SCOPED_NAV_STATES={active:`full`,partial:`partial`,suspended:`suspended`,inactive:`inactive`},SCOPED_NAV_EVENTS={activate:`scopednav:activate`,deactivate:`scopednav:deactivate`,suspend:`scopednav:suspend`,resume:`scopednav:resume`},SCOPED_NAV_TYPES={normal:`normal`,container:`container`,nonav:`nonav`,popover:`popover`};var ScopeRegistry=class{constructor(){this.scopeRegistries=new WeakMap,this.depthCache=new WeakMap,this.cleanupTimers=new Map}clearDepthCache(scopeElement){this.depthCache.delete(scopeElement)}getCachedDepth(element,scopeElement){let scopeDepthCache=this.depthCache.get(scopeElement);if(scopeDepthCache||(scopeDepthCache=new Map,this.depthCache.set(scopeElement,scopeDepthCache)),!scopeDepthCache.has(element)){let depth=this._getElementDepth(element,scopeElement);scopeDepthCache.set(element,depth)}return scopeDepthCache.get(element)}register(scopeElement,handlerDescriptor){let scopeRegistry=this.scopeRegistries.get(scopeElement);scopeRegistry||(scopeRegistry={handlers:[],scopeHandler:null,initialized:!1},this.scopeRegistries.set(scopeElement,scopeRegistry));let existingIndex=scopeRegistry.handlers.findIndex(h$1=>h$1.element===handlerDescriptor.element&&this.descriptorsMatch(h$1.eventDescriptor,handlerDescriptor.eventDescriptor));return existingIndex===-1?scopeRegistry.handlers.push(handlerDescriptor):scopeRegistry.handlers[existingIndex]=handlerDescriptor,scopeRegistry.initialized||this.initializeScopeHandler(scopeElement,scopeRegistry),this.clearDepthCache(scopeElement),handlerDescriptor.handler}descriptorsMatch(desc1,desc2){return desc1.name===desc2.name&&desc1.modified===desc2.modified&&desc1.focusRequired===desc2.focusRequired}unregister(element,handlerController){let scopeElement=element.closest(`[${UI_SCOPE_ATTR$2}]`);if(!scopeElement)return;let scopeRegistry=this.scopeRegistries.get(scopeElement);if(!scopeRegistry)return;let handlerIndex=scopeRegistry.handlers.findIndex(h$1=>h$1.element===element&&h$1.handler===handlerController);handlerIndex!==-1&&(scopeRegistry.handlers.splice(handlerIndex,1),this.clearDepthCache(scopeElement)),this.scheduleCleanup(scopeElement,scopeRegistry)}scheduleCleanup(scopeElement,scopeRegistry){this.cleanupTimers.has(scopeElement)&&clearTimeout(this.cleanupTimers.get(scopeElement));let timerId=setTimeout(()=>{this.performCleanup(scopeElement,scopeRegistry),this.cleanupTimers.delete(scopeElement)},100);this.cleanupTimers.set(scopeElement,timerId)}performCleanup(scopeElement,scopeRegistry){scopeRegistry.handlers.length===0&&(scopeElement.removeEventListener(DOM_UI_NAVIGATION_EVENT,scopeRegistry.scopeHandler),this.scopeRegistries.delete(scopeElement),this.clearDepthCache(scopeElement))}destroy(){this.cleanupTimers.forEach(timer=>clearTimeout(timer)),this.cleanupTimers.clear(),this.depthCache=new WeakMap}initializeScopeHandler(scopeElement,scopeRegistry){let scopeHandler=event=>{let scopeId=scopeElement.getAttribute(UI_SCOPE_ATTR$2),uiNavService=getUINavServiceInstance(),targetScope=event.detail?.targetScope||uiNavService.activeScope;if(targetScope&&targetScope!==scopeId&&!this._isTargetScopeNested(targetScope,scopeElement)){console.warn(`UINav: Event target scope is not the intended scope. Ignoring event for this scope(${scopeId})`,{targetScope,scopeId});return}if(scopeElement._bngScopedNav&&scopeElement._bngScopedNav.canIgnoreEvent&&scopeElement._bngScopedNav.canIgnoreEvent(event)){event.stopPropagation();return}let isTargetActiveScope=targetScope===scopeId&&scopeId===uiNavService.activeScope,canPassthrough=isTargetActiveScope&&this._allowsPassthrough(scopeElement,event.detail),monitoredEvents=[...MONITORED_UI_NAV_EVENTS,UI_EVENTS.back];if(!(!isTargetActiveScope&&!canPassthrough&&!monitoredEvents.includes(event.detail.name))){if(!isTargetActiveScope&&!canPassthrough&&monitoredEvents.includes(event.detail.name)){this._executeScopedNavHandler(scopeElement,event,scopeRegistry.handlers)||event.stopPropagation();return}(!this._executeScopedBubbling(scopeElement,event,scopeRegistry.handlers)||!this._checkScopeBubbling(scopeElement,event))&&event.stopPropagation()}};scopeElement.addEventListener(DOM_UI_NAVIGATION_EVENT,scopeHandler),scopeRegistry.scopeHandler=scopeHandler,scopeRegistry.initialized=!0}_isTargetScopeNested(targetScopeId,currentScopeElement){let targetScopeElement=document.querySelector(`[${UI_SCOPE_ATTR$2}="${targetScopeId}"]`);return targetScopeElement?currentScopeElement.contains(targetScopeElement)&&targetScopeElement!==currentScopeElement:!1}_executeScopedNavHandler(scopeElement,event,handlers$1){let matchingHandlers=handlers$1.filter(h$1=>!h$1.disabled&&this._eventMatchesDescriptor(event.detail,h$1.eventDescriptor)&&h$1.element===scopeElement);if(matchingHandlers.length===0)return!0;let results=[];for(let handler$1 of matchingHandlers)try{let result=handler$1.handler(event);results.push(result)}catch(error){console.error(`Error in UINav scope handler:`,error,{element:handler$1.element,event:event.detail.name}),results.push(!1)}return results.some(result=>result===!0)}_executeScopedBubbling(scopeElement,event,handlers$1){let eventData=event.detail,matchingHandlers=handlers$1&&handlers$1.length>0?handlers$1.filter(h$1=>!h$1.disabled&&this._eventMatchesDescriptor(eventData,h$1.eventDescriptor)):[];if(matchingHandlers.length===0)return!0;let activeElement=document.activeElement,startElement=event.target;startElement=activeElement&&scopeElement.contains(activeElement)&&matchingHandlers.some(h$1=>h$1.element===activeElement)?activeElement:this._findDeepestHandlerElement(scopeElement,matchingHandlers);let bubblingPath=this._buildBubblingPath(startElement,scopeElement,matchingHandlers);return bubblingPath.length===0?(console.warn(`UINav: No bubbling path found.`,{scopeElement,event,handlers:handlers$1}),!0):this._executeHandlersAlongPath(bubblingPath,event)}_findDeepestHandlerElement(scopeElement,handlers$1){return[...new Set(handlers$1.map(h$1=>h$1.element))].filter(el=>this.getCachedDepth(el,scopeElement)<0?!1:!this._isElementInNestedScope(el,scopeElement)).sort((a$1,b)=>{let depthA=this.getCachedDepth(a$1,scopeElement);return this.getCachedDepth(b,scopeElement)-depthA})[0]||null}_isElementInNestedScope(element,currentScopeElement){let current=element;for(;current&¤t!==currentScopeElement;){if(current.hasAttribute(`bng-ui-scope`)&¤t!==currentScopeElement)return!0;current=current.parentElement}return!1}_buildBubblingPath(startElement,scopeElement,handlers$1){if(!scopeElement.contains(startElement))return console.warn(`UINav: Start element is outside scope boundary`,startElement,scopeElement),[];let path=[],current=startElement;for(;current&&scopeElement.contains(current);){let elementHandlers=handlers$1.filter(h$1=>h$1.element===current);if(elementHandlers.length>0&&path.push({element:current,handlers:elementHandlers}),current===scopeElement)break;current=current.parentElement}return path}_executeHandlersAlongPath(bubblingPath,event){for(let pathItem of bubblingPath){let results=[];for(let handlerDescriptor of pathItem.handlers)try{let result=handlerDescriptor.handler(event);results.push(result)}catch(error){console.error(`Error in UINav scope handler:`,error,{element:pathItem.element,event:event.detail.name}),results.push(!1)}if(!results.some(result=>result===!0))return!1}return!0}_checkScopeBubbling(scopeElement,event){let scopedNavProps=scopeElement._bngScopedNav;return scopedNavProps?scopedNavProps.shouldBubbleEvent&&typeof scopedNavProps.shouldBubbleEvent==`function`?scopedNavProps.shouldBubbleEvent(event):!1:!0}_getElementDepth(element,parent){let depth=0,current=element;for(;current&¤t!==parent;)depth++,current=current.parentElement;return current===parent?depth:-1}_allowsPassthrough(scopeElement,eventData){let domScopedNavProps=scopeElement.hasAttribute(`bng-scoped-nav`)?scopeElement[SCOPED_NAV_PROPERTY_NAME]:{};return domScopedNavProps.passthroughActive&&domScopedNavProps.passthroughEnabled&&domScopedNavProps.passthroughEvents.includes(eventData.name)}_eventMatchesDescriptor(eventData,descriptor){for(let[item,value]of Object.entries(descriptor))if(value!==void 0)if(item===`focusRequired`){if(value&&!value.contains(document.activeElement))return!1}else{if(!(item in eventData))return!1;if(typeof value==`function`){if(!value(eventData[item]))return!1}else if(eventData[item]!=value)return!1}return!0}};const isOnOffEvent=eventName=>!VALUE_BASED_EVENTS.includes(eventName),checkOn=value=>value,normalizeEventDescriptor=eventDescriptor=>({string:{name:eventDescriptor,value:isOnOffEvent(eventDescriptor)?checkOn:void 0,modified:!1,extras:void 0},object:{...eventDescriptor,value:`value`in eventDescriptor?eventDescriptor.value:isOnOffEvent(eventDescriptor.name)?checkOn:void 0}})[typeof eventDescriptor]||!1,eventMatchesDescriptor=(eventData,descriptor)=>{for(let[item,value]of Object.entries(descriptor))if(value!==void 0)if(item===`focusRequired`){if(value&&!value.contains(document.activeElement))return!1}else{if(!(item in eventData))return!1;if(typeof value==`function`){if(!value(eventData[item]))return!1}else if(eventData[item]!=value)return!1}return!0},getDescriptorEventNameText=descriptor=>descriptor.name?typeof descriptor.name==`function`?descriptor.name.name:descriptor.name:`ALL`;var HandlerFactory=class{static createHandler(eventDescriptor,userHandler){let descriptor=normalizeEventDescriptor(eventDescriptor);if(!descriptor)throw Error(`Invalid event descriptor when trying to create a UINav handler. Expecting a String or an Object.`);let handlerFuncName=userHandler?.name||`uiNav_${getDescriptorEventNameText(descriptor)}_handler`,disabled=!1;function wrapper(event){let eventData=event?.detail||{};return disabled||!eventMatchesDescriptor(eventData,descriptor)?!0:userHandler(event)}return Object.defineProperty(wrapper,`name`,{value:handlerFuncName}),Object.defineProperty(wrapper,`disabled`,{configurable:!1,get:()=>disabled,set:state=>{disabled=state}}),wrapper}static normalizeEventDescriptor(eventDescriptor){return{string:{name:eventDescriptor,value:isOnOffEvent(eventDescriptor)?checkOn:void 0,modified:!1,extras:void 0},object:{...eventDescriptor,value:`value`in eventDescriptor?eventDescriptor.value:isOnOffEvent(eventDescriptor.name)?checkOn:void 0}}[typeof eventDescriptor]||!1}},UINavHandlers=class{constructor(){this.scopeRegistry=new ScopeRegistry}add(domElement,uiNavHandlerOrDescriptor,handler$1=void 0){let scopeElement=domElement.closest(`[${UI_SCOPE_ATTR$2}]`);return scopeElement?this.addWithScope(domElement,uiNavHandlerOrDescriptor,handler$1,scopeElement):this.addIndividual(domElement,uiNavHandlerOrDescriptor,handler$1)}remove(domElement,uiNavHandler){domElement.closest(`[bng-ui-scope]`)?this.scopeRegistry.unregister(domElement,uiNavHandler):this.removeIndividual(domElement,uiNavHandler)}addWithScope(domElement,uiNavHandlerOrDescriptor,handler$1,scopeElement){let targetElement=domElement;if(!scopeElement.contains(targetElement))return console.error(`UINav: Attempting to register handler for element outside scope`,{targetElement,scopeElement,scopeId:scopeElement.getAttribute(UI_SCOPE_ATTR$2)}),this.addIndividual(domElement,uiNavHandlerOrDescriptor,handler$1);let wrapperHandler=handler$1?HandlerFactory.createHandler(uiNavHandlerOrDescriptor,handler$1):uiNavHandlerOrDescriptor,handlerDescriptor={element:domElement,eventDescriptor:HandlerFactory.normalizeEventDescriptor(uiNavHandlerOrDescriptor),handler:wrapperHandler,disabled:!1};return this.scopeRegistry.register(scopeElement,handlerDescriptor)}addIndividual(domElement,uiNavHandlerOrDescriptor,handler$1){let uiNavHandler=handler$1?HandlerFactory.createHandler(uiNavHandlerOrDescriptor,handler$1):uiNavHandlerOrDescriptor;return domElement.addEventListener(DOM_UI_NAVIGATION_EVENT,uiNavHandler),uiNavHandler}removeIndividual(domElement,uiNavHandler){domElement.removeEventListener(DOM_UI_NAVIGATION_EVENT,uiNavHandler)}},handlers_default=new UINavHandlers;function usePopupUINavScopeName(baseName,props){let attrs=useAttrs(),scopeName=baseName+`__`+attrs.__id;return useUINavScope(scopeName),watch(()=>props.popupActive,()=>props.popupActive&&useUINavScope(scopeName)),scopeName}function useUINavScope(scope$1=void 0,restoreScopeOnUnmount=!0){let currentScope=ref(scope$1),oldScope,scopeChanged=!1,setScope=newScope=>{scopeChanged=!0,currentScope.value=newScope,getUINavServiceInstance().setActiveScope(newScope)},restoreOldScope=()=>{getUINavServiceInstance().setActiveScope(oldScope)};return onMounted(()=>{oldScope=getUINavServiceInstance().activeScope,currentScope.value?setScope(currentScope.value):currentScope.value=oldScope}),onUnmounted(()=>{scopeChanged&&restoreScopeOnUnmount&&restoreOldScope()}),{current:computed(()=>currentScope.value),set:setScope,get oldScope(){return oldScope}}}function watchUINavEventChange(domElementRef,handler$1){return watch(()=>{if(!domElementRef.value)return{};let eventName=domElementRef.value.getAttribute(UI_EVENT_ATTR);return{eventName,action:ACTIONS_BY_UI_EVENT[eventName]}},handler$1)}const eventFirer=uiEvent=>value=>getUINavServiceInstance().fireEvent(uiEvent,value);var counter=0;const uniqueNum=()=>++counter%1e5+Math.random(),uniqueId=(name=``,separator=`.`)=>{let str=`${name?name+separator:``}${uniqueNum().toString(16)}`;return separator===`.`?str:str.replace(`.`,separator)},uniqueSafeId=()=>uniqueId(``,`_`);var DEFAULT_NAVIGATION=[...MONITORED_UI_NAV_EVENTS,`back`],ALWAYS_ACTIVE=[`ok`,`menu`,`back`],BLOCKER=Symbol(`uiNavBlocker`);const useUINavTracker=defineStore(`uiNavTracker`,()=>{let{lua,events:events$3}=useBridge(),showErrors=window.beamng&&!window.beamng.shipping,initialised=!1,trackedEvents=ref([]),trackedInstances={},ignoredEvents=ref([]),ignoredInstances={},blockedEvents$1=ref([]),blockedInstances={},unblockedEvents=ref([]),unblockedInstances={},activeEvents=ref([]),labelRegistry=useUiNavLabel();function updateBlocklist(){let uiNavService=getUINavServiceInstance(),eventsToBlock=blockedEvents$1.value.filter(name=>!unblockedEvents.value.includes(name));uiNavService.setBlockedEvents(eventsToBlock)}let raf;function update$6(eventName){cancelAnimationFrame(raf),raf=requestAnimationFrame(()=>{activeEvents.value=trackedEvents.value.filter(e=>!ignoredEvents.value.includes(e.name)&&(unblockedEvents.value.includes(e.name)||!blockedEvents$1.value.includes(e.name))).map(e=>({...e,nogroup:!!trackedInstances[e.name]?.at(-1)?.nogroup}))})}let ownerIdCheck=ownerId$1=>{if(typeof ownerId$1!=`string`||!ownerId$1)throw Error(`ownerId is required and must be a string`)},eventNameCheck=(eventName,quiet=!1)=>{let ok=!0;return typeof eventName!=`string`||!eventName?(showErrors&&logger_default.error(`eventName is required`),ok=!1):eventName in ACTIONS_BY_UI_EVENT||(showErrors&&!quiet&&logger_default.error(`eventName ${eventName} does not exist`),ok=!1),ok},getRecentInstance=eventName=>trackedInstances[eventName].findLast(inst=>inst.element!==BLOCKER),parseActive=(active,eventName)=>typeof active==`boolean`?active:ALWAYS_ACTIVE.includes(eventName);function addEvent(eventName,ownerId$1,element=null,options={}){if(initialised||rebind(),!eventNameCheck(eventName))return;ownerIdCheck(ownerId$1),trackedInstances[eventName]||(trackedInstances[eventName]=[]),element||=window.document.body;let instance$1=trackedInstances[eventName].find(instance$2=>instance$2.ownerId===ownerId$1);if(instance$1){instance$1.element=element,instance$1.nogroup=!!options?.nogroup,instance$1.active=parseActive(options?.active,eventName),update$6(eventName);return}if(trackedInstances[eventName].push({ownerId:ownerId$1,element,nogroup:!!options?.nogroup,active:parseActive(options?.active,eventName)}),trackedInstances[eventName].length===1){let event={name:eventName,label:computed(()=>{let instance$2=getRecentInstance(eventName);return labelRegistry.getLabel(eventName,instance$2?.element)||null}),action:computed(()=>getRecentInstance(eventName)?.active?eventFirer(eventName):null)};trackedEvents.value.push(event),actionSwitch(!0,eventName)}update$6(eventName)}function updateEvent(eventName,ownerId$1,element,options={}){if(ownerIdCheck(ownerId$1),!eventNameCheck(eventName))return;element||=window.document.body;let instance$1=trackedInstances[eventName]?.find(instance$2=>instance$2.ownerId===ownerId$1);if(!instance$1){addEvent(eventName,ownerId$1,element,!1,options);return}instance$1.element=element,instance$1.nogroup=!!options?.nogroup,instance$1.active=parseActive(options?.active,eventName),update$6(eventName)}function removeEvent(eventName,ownerId$1,element=null){if(ownerIdCheck(ownerId$1),!eventNameCheck(eventName)||!trackedInstances[eventName])return;element||=window.document.body;let idx=trackedInstances[eventName].findIndex(instance$1=>instance$1.ownerId===ownerId$1);if(idx!==-1&&(trackedInstances[eventName].splice(idx,1),update$6(eventName),trackedInstances[eventName].length===0)){delete trackedInstances[eventName];let idx$1=trackedEvents.value.findIndex(h$1=>h$1.name===eventName);idx$1>-1&&(trackedEvents.value.splice(idx$1,1),actionSwitch(!1,eventName))}}function addHelper(eventList,instanceList,eventName,ownerId$1,func,quiet=!1){ownerIdCheck(ownerId$1),eventNameCheck(eventName,quiet)&&(eventList.value.includes(eventName)||(eventList.value.push(eventName),func&&func(),instanceList[eventName]||(instanceList[eventName]=[])),instanceList[eventName].push(ownerId$1))}function removeHelper(eventList,instanceList,eventName,ownerId$1,func,quiet=!1){if(ownerIdCheck(ownerId$1),!eventNameCheck(eventName,quiet)||!(eventName in instanceList))return;let instIdx=instanceList[eventName].indexOf(ownerId$1);if(instIdx!==-1&&(instanceList[eventName].splice(instIdx,1),instanceList[eventName].length===0)){let idx=eventList.value.indexOf(eventName);idx>-1&&(eventList.value.splice(idx,1),func&&func())}}function addIgnore(eventName,ownerId$1){addHelper(ignoredEvents,ignoredInstances,eventName,ownerId$1,null,!0)}function removeIgnore(eventName,ownerId$1){removeHelper(ignoredEvents,ignoredInstances,eventName,ownerId$1,null,!0)}function addBlocker(eventName,ownerId$1){addHelper(blockedEvents$1,blockedInstances,eventName,ownerId$1,()=>{addEvent(eventName,ownerId$1,BLOCKER),updateBlocklist()})}function removeBlocker(eventName,ownerId$1){removeHelper(blockedEvents$1,blockedInstances,eventName,ownerId$1,()=>{removeEvent(eventName,ownerId$1,BLOCKER),updateBlocklist()})}function addForceUnblock(eventName,ownerId$1){addHelper(unblockedEvents,unblockedInstances,eventName,ownerId$1,()=>{update$6(eventName),updateBlocklist()})}function removeForceUnblock(eventName,ownerId$1){removeHelper(unblockedEvents,unblockedInstances,eventName,ownerId$1,()=>{update$6(eventName),updateBlocklist()})}let actionSwitch=async(enabled,eventName)=>{eventName!==`menu`&&(!enabled&&blockedEvents$1.value.includes(eventName)||await lua.extensions.core_input_bindings.setMenuActionEnabled(enabled,ACTIONS_BY_UI_EVENT[eventName]))};function rebind(){initialised||(initialised=!0,getUINavServiceInstance().clearBlockedEvents(),DEFAULT_NAVIGATION.forEach(name=>addEvent(name,`__uiNavTracker_default`))),Object.keys(ACTIONS_BY_UI_EVENT).filter(name=>!DEFAULT_NAVIGATION.includes(name)&&!trackedEvents.value.find(e=>e.name===name)).forEach(name=>actionSwitch(!1,name))}return lua.extensions.core_input_bindings.getMenuActionMapEnabled().then(enabled=>enabled&&rebind()),events$3.on(`MenuActionMapEnabled`,enabled=>enabled&&rebind()),{activeEvents,blockedEvents:blockedEvents$1,unblockedEvents,addEvent,updateEvent,removeEvent,addIgnore,removeIgnore,addBlocker,removeBlocker,addForceUnblock,removeForceUnblock}});function useUINavBlocker(){let id=uniqueId(`uiNavBlocker`),tracker=useUINavTracker(),allEventNames=Object.keys(ACTIONS_BY_UI_EVENT),defaultEvents=Object.freeze(Object.fromEntries(DEFAULT_NAVIGATION.map(name=>[name,name]))),allEvents=Object.freeze(UI_EVENTS),blockedEvents$1=[],unblockedEvents=[],filterEvents=events$3=>{if(!events$3)return[];if(typeof events$3==`string`)events$3=[events$3];else if(events$3.length===0)return[];return events$3.reduce((res,name)=>allEventNames.includes(name)&&!res.includes(name)?[...res,name]:res,[])};function allowOnly(events$3=[]){events$3=filterEvents(events$3),blockOnly(allEventNames.filter(name=>!events$3.includes(name)))}function allowNavigationOnly(enforce=!0){if(!enforce)return blockOnly();let events$3=[...DEFAULT_NAVIGATION,`menu`];blockOnly(allEventNames.filter(name=>!events$3.includes(name)))}function blockOnly(events$3=[]){events$3=filterEvents(events$3),blockedEvents$1.filter(name=>!events$3.includes(name)).forEach(name=>tracker.removeBlocker(name,id)),blockedEvents$1.splice(0),blockedEvents$1.push(...events$3),blockedEvents$1.forEach(name=>tracker.addBlocker(name,id))}function ensureNoBlock(events$3=[]){events$3=filterEvents(events$3),unblockedEvents.filter(name=>!events$3.includes(name)).forEach(name=>tracker.removeForceUnblock(name,id)),unblockedEvents.splice(0),unblockedEvents.push(...events$3),events$3.forEach(name=>tracker.addForceUnblock(name,id))}function isBlocked(eventName){return tracker.unblockedEvents.includes(eventName)?!1:tracker.blockedEvents.includes(eventName)}let clear=()=>blockOnly();return onUnmounted(clear),{allEvents,defaultEvents,allowOnly,allowNavigationOnly,blockOnly,clear,ensureNoBlock,isBlocked}}const useUiNavLabel=defineStore(`uiNavLabeler`,()=>{let elementLabels=reactive(new WeakMap),eventElements=reactive({});function registerLabel(element,eventNames,label){elementLabels.has(element)||elementLabels.set(element,{});let elementEvents=elementLabels.get(element);Array.isArray(eventNames)||(eventNames=[eventNames]);for(let eventName of eventNames)elementEvents[eventName]=label,eventElements[eventName]||(eventElements[eventName]=new Set),eventElements[eventName].add(element)}function clearLabels(element,eventNames=null){if(!elementLabels.has(element))return;let elementEvents=elementLabels.get(element);if(eventNames===null){for(let eventName of Object.keys(elementEvents))eventElements[eventName]&&eventElements[eventName].delete(element);elementLabels.delete(element)}else{for(let eventName of eventNames)delete elementEvents[eventName],eventElements[eventName]&&eventElements[eventName].delete(element);Object.keys(elementEvents).length===0&&elementLabels.delete(element)}}function getLabel(eventName,element=null){if(element&&elementLabels.has(element)&&elementLabels.get(element)[eventName])return elementLabels.get(element)[eventName];if(eventElements[eventName])for(let el of eventElements[eventName]){let label=elementLabels.get(el)?.[eventName];if(label)return label}return null}function getElementEvents(element){return elementLabels.has(element)?Object.keys(elementLabels.get(element)):[]}return{registerLabel,clearLabels,getLabel,getElementEvents}});var LUA_EXTENSION_NAME=`ui_topBar`;const useTopBar=defineStore(`topBar`,()=>{let{events:events$3}=useBridge(),setupComplete=!1,_items=ref({}),_activeItem=ref(null),visible=ref(!1),hiddenItems=ref([]),gameState$1=reactive({isInGame:void 0,gameState:void 0,uiState:void 0,isCareerActive:void 0,isGarageActive:void 0,isMissionActive:void 0,isScenarioActive:void 0}),sortItems=(a$1,b)=>(a$1.order??0)-(b.order??0),items$2=computed(()=>Object.values(_items.value).filter(item=>!hiddenItems.value||!hiddenItems.value.includes(item.id)).sort(sortItems)),activeItem=computed({get:()=>_activeItem.value,set:value=>{value!==_activeItem.value&&(_activeItem.value=value,Lua_default.ui_topBar.setActiveItem(value))}}),updateTopBarVisibility=()=>{if(!(!gameState$1.uiState||gameState$1.isInGame===void 0)){if(gameState$1.uiState.startsWith(`menu.mainmenu`)&&!gameState$1.isInGame&&(visible.value=!1),!visible.value||gameState$1.uiState===`unknown`){activeItem.value=null;return}if(gameState$1.uiState){let updatedActiveItem=Object.values(_items.value).find(item=>item.targetState===gameState$1.uiState);updatedActiveItem||=Object.values(_items.value).find(item=>item.substate&&gameState$1.uiState.startsWith(item.substate)),activeItem.value=updatedActiveItem?updatedActiveItem.id:null}updateHiddenItems()}};watch(()=>gameState$1.uiState,()=>nextTick(updateTopBarVisibility)),watch(()=>gameState$1.isInGame,()=>nextTick(updateTopBarVisibility));let selectPrevious=()=>{if(!visible.value)return;let len=items$2.value.length;if(len===0)return;let previousIndex=(items$2.value.findIndex(item=>item.id===activeItem.value)-1+len)%len;selectEntry(items$2.value[previousIndex].id)},selectNext=()=>{if(!visible.value)return;let len=items$2.value.length;if(len===0)return;let nextIndex=(items$2.value.findIndex(item=>item.id===activeItem.value)+1)%len;selectEntry(items$2.value[nextIndex].id)},selectEntry=itemId=>{visible.value&&(activeItem.value=itemId,Lua_default.ui_topBar.selectItem(itemId))},show=()=>{visible.value=!0},hide$2=()=>{visible.value=!1};function updateHiddenItems(){hiddenItems.value=Object.values(_items.value).filter(shouldHideItem).map(item=>item.id)}function shouldHideItem(item){if(!item.flags||item.flags.length===0)return!1;for(let flag of item.flags)if(flag===`inGameOnly`&&!gameState$1.isInGame||flag===`careerOnly`&&!gameState$1.isCareerActive||flag===`noCareer`&&gameState$1.isCareerActive||flag===`missionOnly`&&!gameState$1.isMissionActive||flag===`noMission`&&gameState$1.isMissionActive&&!gameState$1.isScenarioUnrestricted||flag===`garageOnly`&&!gameState$1.isGarageActive||flag===`noGarage`&&gameState$1.isGarageActive||flag===`scenarioOnly`&&!gameState$1.isScenarioActive||flag===`noScenario`&&gameState$1.isScenarioActive&&!gameState$1.isScenarioUnrestricted||flag===`careerGarageOnly`&&(!gameState$1.isCareerActive||!gameState$1.isGarageActive)||flag===`noCareerGarage`&&gameState$1.isCareerActive&&gameState$1.isGarageActive)return!0;return!1}function onCareerStateChanged(data){gameState$1.isCareerActive=data.isActive}function onGarageStateChanged(data){gameState$1.isGarageActive=data.isActive}function onMissionStateChanged(data){gameState$1.isMissionActive=data.isActive}function onScenarioStateChanged(data){gameState$1.isScenarioActive=data.isActive}function onDataRequested(data){let{isInGame,items:dataItems}=data;_items.value=dataItems,gameState$1.isInGame=isInGame,hiddenItems.value=[]}function onGameStateChanged(data){gameState$1.isInGame=data.isInGame,gameState$1.isCareerActive=data.isCareerActive,gameState$1.isGarageActive=data.isGarageActive,gameState$1.isMissionActive=data.isMissionActive,gameState$1.isScenarioActive=data.isScenarioActive,gameState$1.isScenarioUnrestricted=data.isScenarioUnrestricted,nextTick(()=>updateHiddenItems())}function onEntriesChanged(data){_items.value=data}function onVisibleItemsChanged(data){hiddenItems.value=data}function onShow(){visible.value=!0}function onHide(){visible.value=!1}let debouncedStateChange=debounce(data=>{gameState$1.uiState=(data.fullPath||data.name||`unknown`).replace(/^\//,``)},100);function onUIStateChanged(data){debouncedStateChange(data)}let eventHandlerMap={selectPrevious,selectNext,OnCareerActive:onCareerStateChanged,garageStateChanged:onGarageStateChanged,missionStateChanged:onMissionStateChanged,scenarioStateChanged:onScenarioStateChanged,dataRequested:onDataRequested,gameStateChanged:onGameStateChanged,entriesChanged:onEntriesChanged,visibleItemsChanged:onVisibleItemsChanged,show:onShow,hide:onHide};function addListeners(){for(let eventName of Object.keys(eventHandlerMap))events$3.on(`${LUA_EXTENSION_NAME}_${eventName}`,eventHandlerMap[eventName])}function removeListeners$1(){for(let eventName of Object.keys(eventHandlerMap))events$3.off(`${LUA_EXTENSION_NAME}_${eventName}`,eventHandlerMap[eventName])}return(async()=>{setupComplete||=(await Lua_default.extensions.isExtensionLoaded(LUA_EXTENSION_NAME)||await Lua_default.extensions.load(LUA_EXTENSION_NAME),addListeners(),await Lua_default.ui_topBar.requestData(),!0)})(),{activeItem,items:items$2,visible,gameState:gameState$1,show,hide:hide$2,selectEntry,selectPrevious,selectNext,onUIStateChanged,dispose:()=>{removeListeners$1(),Lua_default.extensions.unload(LUA_EXTENSION_NAME)}}});var events$2,beamNG,serviceProviders=ref(),online=ref(!1),videoAdapter=ref(``),modCounts=ref({total:0,active:0}),gameState=ref(),mainMenuBackgroundRequired=ref(),mainMenuFirstTime=ref(!0),serviceProvidersOnline=computed(()=>{let provs=serviceProviders.value,gotInfo=!!provs,ret={eos:gotInfo&&provs.eos&&provs.eos.loggedin,steam:gotInfo&&provs.steam&&provs.steam.loggedin&&provs.steam.working};return ret.any=Object.values(ret).some(v=>v),ret}),version,versionSimple,buildInfo,init$2=()=>{let api$1;({api:api$1,events:events$2,beamNG}=useBridge()),beamNG||=FAKE_BEAMNG_OBJ,api$1.serializeToLuaCheck(`English: hello`),api$1.serializeToLuaCheck(`Spanish: güeñes`),api$1.serializeToLuaCheck(`French: bâguéttè, garçon`),api$1.serializeToLuaCheck(`Czech: Kl�vesnice`),api$1.serializeToLuaCheck(`Korean: \r��\v��\v��`),api$1.serializeToLuaCheck(`Chinese Sim: 欢迎来到简体中文版的`),api$1.serializeToLuaCheck(`Chinese Tr: 歡迎來到`),api$1.serializeToLuaCheck(`Japanese: 』日本語版にようこそ`),api$1.serializeToLuaCheck(`Polish: źćłąóę`),api$1.serializeToLuaCheck(`Russian: абвгеёьъ`),events$2.on(`ServiceProviderInfo`,info=>serviceProviders.value=info),events$2.on(`OnlineStateChanged`,state=>online.value=state),events$2.on(`ModManagerModsChanged`,_processModData),events$2.on(`ShowEntertainingBackground`,state=>mainMenuBackgroundRequired.value=state),events$2.on(`GameStateUpdate`,state=>gameState.value=state.state),version=beamNG.version,versionSimple=_toSimpleVersion(beamNG.version),buildInfo=beamNG.buildinfo,refresh()},refresh=()=>{_requestServiceProviders(),_requestOnlineState(),_refreshVideoAdapter(),_refreshModData()},_refreshVideoAdapter=()=>Lua_default.Engine.Render.getAdapterType().then(adapter=>videoAdapter.value=adapter),_requestServiceProviders=()=>beamNG.requestServiceProviderInfo(),_requestOnlineState=()=>Lua_default.core_online.requestState(),_refreshModData=()=>Lua_default.core_modmanager.requestState(),sysInfo_default={init:init$2,refresh,serviceProviders,serviceProvidersOnline,online,videoAdapter,modCounts,gameState,mainMenuBackgroundRequired,mainMenuFirstTime,get version(){return version},get versionSimple(){return versionSimple},get buildInfo(){return buildInfo}},_toSimpleVersion=versionStr=>{let bits=versionStr.split(`.`);return bits.length==5&&bits.pop(),bits.join(`.`).replace(/(\.0)+$/,``)},_processModData=data=>{let mods=Object.values(data).filter(mod=>mod.modname!=`translations`);modCounts.value.total=mods.length,modCounts.value.active=mods.filter(({active})=>active).length},FAKE_BEAMNG_OBJ={version:`0.12.3.4.FAKE12345`,buildInfo:`Sample Fake BuildInfo - running outside of game`,requestServiceProviderInfo(){events$2.emit(`ServiceProviderInfo`,{steam:{loggedin:!0,accountID:`12345678901234567`,playerName:`fakeplayer`,branch:`qa_latest`,language:`english`,useSteam:!0,working:!0}})}};const useLibStore=defineStore(`lib`,{});var bridge$2,stateStack=[];function add(stateName){rem(stateName),stateStack.push(stateName)}function rem(stateName){let idx=stateStack.lastIndexOf(stateName);idx>-1&&stateStack.splice(idx,1)}var luaStringify=any=>JSON.stringify(any).replace(/^\[(.*)\]$/,`{$1}`),luaReport=(stateName,opened)=>bridge$2.api.engineLua(`extensions.hook("onUIStateTriggered", ${luaStringify(stateName)}, ${luaStringify(!!opened)}, ${luaStringify(stateStack)})`);function reportState(stateName,opened,prevName=null){bridge$2||=useBridge(),prevName&&(rem(prevName),luaReport(prevName,!1)),opened?add(stateName):rem(stateName),luaReport(stateName,opened)}function reportPopupState(popup,opened){reportState(`/popup/${popup.componentName}/${popup.wrapper.blur?`fullscreen`:`aside`}`,opened)}function scroll(el,binding){let direction$1=binding.arg;el.scrollHeight<=el.clientHeight||(direction$1===`top`?el.scrollTop>0&&(el.scrollTop=0):direction$1===`bottom`&&el.scrollTop{let id,blurAmount=1,blurUpdateWrapper=debounce(updateBlur,50),resizeObserver,removePositionObserver;function observe(){resizeObserver||(resizeObserver=new ResizeObserver(blurUpdateWrapper),resizeObserver.observe(el)),removePositionObserver||=observePosition(el,blurUpdateWrapper)}function unobserve(){resizeObserver&&resizeObserver.disconnect(),removePositionObserver&&removePositionObserver(),resizeObserver=null,removePositionObserver=null}elemBlurs.set(el,{blurUpdateWrapper,processBlurVal,observe,unobserve}),processBlurVal(binding.value),window.addEventListener(`resize`,blurUpdateWrapper);function processBlurVal(val){switch(typeof val){case`undefined`:val=1;break;case`boolean`:val=val?1:0;break;case`number`:(val<0||val>1)&&(logger_default.error(`Attempted to use v-bng-blur with a number out of range 0..1: ${val}\nSee stack:`,logger_default.STACK_TRACE),val=1);break;default:logger_default.error(`Attempted to use v-bng-blur with a non-number, non-boolean value: ${val}\nSee stack:`,logger_default.STACK_TRACE),val=0}blurAmount=val,blurUpdateWrapper()}function calcBlur(){let rect=el.getBoundingClientRect();return rect.width>0&&rect.height>0&&rect.bottom>0&&rect.top0&&rect.left{let elemBlur=elemBlurs.get(el);elemBlur&&binding.value!=binding.oldValue&&elemBlur.processBlurVal(binding.value)},unmounted:(el,binding)=>{let elemBlur=elemBlurs.get(el);elemBlur&&(elemBlur.unobserve(),elemBlur.processBlurVal(0),window.removeEventListener(`resize`,elemBlur.blurUpdateWrapper),elemBlurs.delete(el))}},DEFAULT_HOLD_DELAY=400,DEFAULT_REPEAT_INTERVAL=100,HOLD_CSS_TIME_VAR=`--hold-time`,HOLD_START_CSS_CLASS=`hold-start`,HOLD_ACTIVE_CSS_CLASS=`hold-active`,HOLD_COMPLETED_CSS_CLASS=`hold-completed`,EVENT_CLICK=`click`,EVENT_HOLD=`hold`,ELEMENT_ID=`__BNG_CLICK_ID`,curId=0,datas={};function update$5(element,binding){let id=element[ELEMENT_ID]||(element[ELEMENT_ID]=++curId),data=datas[id]||(datas[id]={id,element,events:{},binding:{}});if(typeof binding.value==`object`)data.binding=binding.value;else if(typeof binding.value==`function`){let cbName=binding.modifiers?.hold?`holdCallback`:`clickCallback`;data.binding[cbName]=binding.value}return data.controllerOnly=!!binding.modifiers?.controller,data.hasClick=typeof data.binding.clickCallback==`function`,data.hasHold=typeof data.binding.holdCallback==`function`,typeof data.binding.holdDelay!=`number`&&(data.binding.holdDelay=DEFAULT_HOLD_DELAY),typeof data.binding.repeatInterval!=`number`&&(data.binding.repeatInterval=DEFAULT_REPEAT_INTERVAL),data}function remove(element){let id=element[ELEMENT_ID];if(!id)return;let data=datas[id];data&&(`mouseleave`in data.events&&data.events.mouseleave(),updateEvents(id),delete datas[id],delete element[ELEMENT_ID])}function updateEvents(id,events$3={}){let data=datas[id];if(data){for(let event in data.events)data.element.removeEventListener(event,data.events[event]);for(let event in events$3)data.element.addEventListener(event,events$3[event]);data.events=events$3}}var BngClick_default={mounted:(el,binding)=>{let data=update$5(el,binding),approveEvent=evt=>data.controllerOnly?!!evt.fromController:evt.button===0||evt.fromController,tmrHoldActive;updateEvents(data.id,{mousedown:e=>{approveEvent(e)&&(el.style.setProperty(HOLD_CSS_TIME_VAR,`${data.binding.holdDelay}ms`),el.classList.toggle(HOLD_START_CSS_CLASS,!0),clearTimeout(tmrHoldActive),tmrHoldActive=setTimeout(()=>el.classList.toggle(HOLD_ACTIVE_CSS_CLASS,!0),0),el.classList.toggle(HOLD_COMPLETED_CSS_CLASS,!1),canInvokeEventType(EVENT_CLICK)&&(detectedEventType=EVENT_CLICK),canInvokeEventType(EVENT_HOLD)&&startHoldDelayTimer(e))},mouseup:e=>{if(approveEvent(e)){switch(el.style.removeProperty(HOLD_CSS_TIME_VAR),el.classList.toggle(HOLD_START_CSS_CLASS,!1),el.classList.toggle(HOLD_ACTIVE_CSS_CLASS,!1),clearTimeout(tmrHoldActive),stopHoldDelayTimer(),detectedEventType){case EVENT_CLICK:doAction(EVENT_CLICK,e);break;case EVENT_HOLD:stopHoldTimer();break}detectedEventType=null}},mouseleave:()=>{switch(el.style.removeProperty(HOLD_CSS_TIME_VAR),el.classList.toggle(HOLD_START_CSS_CLASS,!1),el.classList.toggle(HOLD_ACTIVE_CSS_CLASS,!1),clearTimeout(tmrHoldActive),stopHoldDelayTimer(),detectedEventType){case EVENT_HOLD:stopHoldTimer();break}detectedEventType=null},blur:()=>data.events.mouseleave()});let detectedEventType,holdDelayTimer,holdTimer;function startHoldDelayTimer(e){stopHoldTimer(),stopHoldDelayTimer(),holdDelayTimer=setTimeout(()=>{el.classList.toggle(HOLD_COMPLETED_CSS_CLASS,!0),detectedEventType=EVENT_HOLD,startHoldTimer(e)},data.binding.holdDelay)}function stopHoldDelayTimer(){holdDelayTimer&&=(clearTimeout(holdDelayTimer),null)}function startHoldTimer(e){doAction(EVENT_HOLD,e),data.binding.repeatInterval&&(stopHoldTimer(),holdTimer=setInterval(()=>{doAction(EVENT_HOLD,e)},data.binding.repeatInterval))}function stopHoldTimer(){holdTimer&&=(clearInterval(holdTimer),null)}function doAction(eventType,originalEvent){let callback=getCallback(eventType);callback&&(eventType==EVENT_HOLD?setTimeout(()=>callback(originalEvent),100):callback(originalEvent))}function getCallback(arg){switch(arg){case EVENT_CLICK:return data.binding.clickCallback;case EVENT_HOLD:return data.binding.holdCallback}return null}function canInvokeEventType(eventType){switch(eventType){case EVENT_CLICK:return data.hasClick;case EVENT_HOLD:return data.hasHold}return!1}},updated:update$5,beforeUnmount:remove},BngDisabled_default=(el,{value})=>{let has$1={disabled:el.hasAttribute(`disabled`),tabindex:el.hasAttribute(`tabindex`)};!has$1.disabled&&value?(el.setAttribute(`disabled`,`disabled`),has$1.tabindex&&(el._BNG_TABINDEX=el.getAttribute(`tabindex`),el.setAttribute(`tabindex`,`-1`))):has$1.disabled&&!value&&(el.removeAttribute(`disabled`),has$1.tabindex&&`_BNG_TABINDEX`in el&&el.getAttribute(`tabindex`)!==el._BNG_TABINDEX&&(el.setAttribute(`tabindex`,el._BNG_TABINDEX),delete el._BNG_TABINDEX))},DELAY=300,EVENTS_IN=[`uinav-focus`,`focus`,`focusin`],EVENTS_OUT=[`uinav-blur`,`blur`,`focusout`],elems$1=new Map,globInit=!1;function initGlobals(){globInit=!0;let running=!1,targets={in:[],out:[]};function preventer(){for(let[part,list]of Object.entries(targets))if(list.length!==0){for(let target of list)for(let[uid$2,data]of elems$1)if(!(!data.capture||!data.timer||!data.element)){if(part===`in`){if(data.element===target||data.element.contains(target))continue}else if(data.element!==target&&!data.element.contains(target))continue;clearTimeout(data.timer),data.timer=null;break}list.splice(0)}}function handler$1(evt,eventIn){if(elems$1.size===0)return;let target=evt.detail?.target||evt.target;if(!target)return;let part=eventIn?`in`:`out`;targets[part].includes(target)||targets[part].push(target),!running&&(running=!0,window.requestAnimationFrame(()=>{preventer(),running=!1}))}EVENTS_IN.forEach(evt=>document.addEventListener(evt,evt$1=>handler$1(evt$1,!0),!0)),EVENTS_OUT.forEach(evt=>document.addEventListener(evt,evt$1=>handler$1(evt$1,!1),!0))}function createHandler(data){return data.capture?evt=>{evt.detail?.doubleToSingle||(evt.preventDefault(),evt.stopImmediatePropagation(),data.timer?(clearTimeout(data.timer),data.timer=null,data.callback?.()):data.timer=setTimeout(()=>{data.timer=null;let click$1=new CustomEvent(`click`,{...evt,bubbles:!0,cancelable:!0,detail:{doubleToSingle:!0}});data.element.dispatchEvent(click$1)},DELAY))}:()=>{data.timer&&=(clearTimeout(data.timer),null);let now$1=Date.now();if(data.time&&now$1-data.time<=DELAY){data.time=0,data.callback?.();return}data.time=now$1}}function update$4(vnode,callback=void 0,mod={}){!globInit&&initGlobals();let el=vnode?.el;if(!el)return;let uid$2=vnode?.component?.uid||vnode?.key||el,capture=!!mod.capture,data=elems$1.get(uid$2)||{};data.handler&&data.element===el&&callback&&`callback`in data&&data.callback===callback&&data.capture===capture||(`element`in data||(data.element=el,data.callback=callback,data.capture=capture),data.handler&&(!callback||data.capture!==capture||data.element!==el)&&(delete data.callback,el.removeEventListener(`click`,data.handler,{capture:data.capture}),elems$1.delete(uid$2)),callback&&(data.handler?data.callback=callback:(data.capture=capture,data.handler=createHandler(data),el.addEventListener(`click`,data.handler,{capture}),elems$1.set(uid$2,data))))}var BngDoubleClick_default={mounted:(el,{value,modifiers,arg}={},vnode)=>update$4(vnode||{el},value,{capture:arg===`capture`,...modifiers}),updated:(el,{value,modifiers,arg}={},vnode)=>update$4(vnode||{el},value,{capture:arg===`capture`,...modifiers}),unmounted:(el,vnode)=>update$4(vnode||{el})},DRAG_START_EVENT_NAME=`bngDragStart`,DRAG_OVER_EVENT_NAME=`bngDragOver`,DRAG_END_EVENT_NAME=`bngDragEnd`;const DRAG_EVENTS=Object.freeze({dragStart:DRAG_START_EVENT_NAME,dragOver:DRAG_OVER_EVENT_NAME,dragEnd:DRAG_END_EVENT_NAME});var STORE_NAME=`controls`,store,DEVICE_ICONS={key:`keyboard`,mou:`mouseLMB`,vin:`smartphone2`,whe:`steeringWheelCommon`,gam:`gamepadOld`,xin:`gamepadOld`,default:`gamepad`};const CONTROL_LABELS={escape:`ESC`,enter:`⏎`,tab:`⭾`,capslock:`⇪`,backspace:`⌫`,delete:`Del`,insert:`Ins`,home:`Home`,end:`End`,pageup:`PG↑`,pagedown:`PG↓`,lshift:`L⇧`,rshift:`R⇧`,shift:`⇧`,lcontrol:`L Ctrl`,rcontrol:`R Ctrl`,lalt:`L Alt`,ralt:`R Alt`,left:`←`,right:`→`,up:`↑`,down:`↓`,space:`␣`,grave:`~`,backslash:`\\`,"/":`/`,comma:`,`,period:`.`,";":`;`,apostrophe:`'`,"[":`[`,"]":`]`,minus:`-`,"+":`NP+`,"*":`NP*`,numpaddivide:`NP/`,numpad0:`NP0`,numpad1:`NP1`,numpad2:`NP2`,numpad3:`NP3`,numpad4:`NP4`,numpad5:`NP5`,numpad6:`NP6`,numpad7:`NP7`,numpad8:`NP8`,numpad9:`NP9`,numpaddecimal:`NP.`,numpadenter:`NP⏎`,xaxis:`X Axis`,yaxis:`Y Axis`,zaxis:`Z Axis`,rzaxis:`R Z Axis`,thumblx:`L Thumb X`,thumbly:`L Thumb Y`,thumbrx:`R Thumb X`,thumbry:`R Thumb Y`};var controlLabel=control=>control.toLowerCase().split(/[ -]+/).map(ctl=>CONTROL_LABELS[ctl]||(ctl.startsWith(`button`)?`BTN`+ctl.substring(6):ctl)).join(` + `),CONTROL_ICONS={pc_mouse:{button0:`mouseLMB`,button1:`mouseRMB`,button2:`mouseMMB`,xaxis:`mouseXAxis`,yaxis:`mouseYAxis`,zaxis:`mouseWheel`},xbox:{btn_a:`xboxA`,btn_b:`xboxB`,btn_x:`xboxX`,btn_y:`xboxY`,btn_back:`xboxView`,btn_start:`xboxMenu`,btn_l:`xboxLB`,triggerl:`xboxLT`,btn_r:`xboxRB`,triggerr:`xboxRT`,dpov:`xboxDDown`,lpov:`xboxDLeft`,rpov:`xboxDRight`,upov:`xboxDUp`,thumblx:`xboxXAxis`,thumbly:`xboxYAxis`,thumbrx:`xboxXRot`,thumbry:`xboxYRot`,btn_lt:`xboxLSButton`,btn_rt:`xboxRSButton`},ps:{button1:`psCross`,button3:`psTriangle`,button0:`psSquare`,button2:`psCircle`,button8:`psCreate2`,button9:`psMenu2`,button4:`psL1`,button6:`psL2`,button5:`psR1`,button7:`psR2`,dpov:`psDDown`,lpov:`psDLeft`,rpov:`psDRight`,upov:`psDUp`,xaxis:`psLSX`,yaxis:`psLSY`,zaxis:`psRSX`,rzaxis:`psRSY`,rxaxis:`psL2`,ryaxis:`psR2`,button10:`psL3Button`,button11:`psR3Button`,button13:`psTrackpadPressCenter`}};const DEVICE_CONTROLS={pc_mouse:Object.keys(CONTROL_ICONS.pc_mouse),xbox:Object.keys(CONTROL_ICONS.xbox),ps:Object.keys(CONTROL_ICONS.ps)};var extendControlGroupNames=groups=>groups.reduce((res,group)=>(res.push(group),res.push({...group,controls:group.controls.map(ctl=>CONTROL_LABELS[ctl])}),res),[]),GROUPED_CONTROLS={pc_keyboard:extendControlGroupNames([{label:`↑↓←→`,controls:[`left`,`right`,`up`,`down`]},{label:`NP 8↑ 2↓ 4← 6→`,controls:[`numpad2`,`numpad4`,`numpad6`,`numpad8`]}]),xbox:extendControlGroupNames([{icon:`xboxDDefaultSolid`,controls:[`upov`,`dpov`,`lpov`,`rpov`]},{icon:`xboxThumbL`,controls:[`thumblx`,`thumbly`]},{icon:`xboxThumbR`,controls:[`thumbrx`,`thumbry`]}]),ps:extendControlGroupNames([{icon:`psDDefaultSolid`,controls:[`upov`,`dpov`,`lpov`,`rpov`]},{icon:`psLS`,controls:[`xaxis`,`yaxis`]},{icon:`psRS`,controls:[`zaxis`,`rzaxis`]}])},DEVICE_FAMILY={mouse:`pc_mouse`,keyboard:`pc_keyboard`,xinput:`xbox`,ps5:`ps`},CONTROL_ICON_KEYS=Object.keys(DEVICE_FAMILY),getViewerOverrides=(devName=void 0,imagePack=void 0)=>{let family;return imagePack&&(imagePack in DEVICE_FAMILY?family=DEVICE_FAMILY[imagePack]:imagePack in CONTROL_ICONS&&(family=imagePack)),!family&&devName&&(devName=CONTROL_ICON_KEYS.find(key=>devName.startsWith(key))||devName,devName in DEVICE_FAMILY?family=DEVICE_FAMILY[devName]:devName in CONTROL_ICONS&&(family=devName)),family?{family,icons:CONTROL_ICONS[family]||{},groups:GROUPED_CONTROLS[family]||[]}:null},DEVICE_ORDER=[`wheel`,`joystick`,`xinput`,`gamepad`,`mouse`,`keyboard`],makeStore=defineStore(STORE_NAME,()=>{let{events:events$3}=useBridge(),devNamesOrder=DEVICE_ORDER.map(devType=>devType+`0`),actions=ref([]),categories=ref({}),categoriesList=ref([]),bindings=ref([]),bindingsPerDevice=computed(()=>Object.fromEntries(bindings.value.map(b=>[b.devname,b]))),bindingTemplate=ref({}),controllers=ref({}),players=ref({}),lastDeviceOrder=ref([...devNamesOrder]),lastDevice=computed(()=>isKbm(lastDeviceOrder.value[0])?kbmDevNames:lastDeviceOrder.value[0]),lastControllers=computed(()=>lastDeviceOrder.value.filter(devName=>!isKbm(devName))),lastControllersSignature=computed(()=>lastControllers.value.sort().join(`::`)),isControllerUsed=computed(()=>!isKbm(lastDeviceOrder.value[0])),isControllerAvailable=computed(()=>lastDeviceOrder.value.some(devName=>!isKbm(devName))),lastDeviceSimple=computed(()=>isControllerUsed.value?lastDevice.value:null),getDevType=devName=>devName?devName.replace(/\d+$/,``):``,deviceSorter=(a$1,b)=>DEVICE_ORDER.indexOf(getDevType(a$1))-DEVICE_ORDER.indexOf(getDevType(b)),kbmDevNames=[`keyboard0`,`mouse0`].sort(deviceSorter),kbmShortNames=kbmDevNames.map(devName=>devName.slice(0,3)),isKbm=devName=>devName&&kbmShortNames.includes(devName.slice(0,3)),_receiveControlsData=data=>(controllers.value=data,_updateDeviceNotes()),_receivePlayersData=data=>players.value=data,_receiveBindingsData=_processBindingsData,_getBindingsData=()=>Lua_default.extensions.core_input_bindings.notifyUI(`Vue controls service needs the data`),connect=(state=!0)=>{let method=state?`on`:`off`;events$3[method](`ControllersChanged`,_receiveControlsData),events$3[method](`AssignedPlayersChanged`,_receivePlayersData),events$3[method](`InputBindingsChanged`,_receiveBindingsData),events$3[method](`RecentDevicesChanged`,_requestRecentDevices)},disconnect=()=>connect(!1),deviceIcon=deviceName=>DEVICE_ICONS[(deviceName||``).slice(0,3)]||DEVICE_ICONS.default;async function _requestRecentDevices(devNames=void 0){devNames||=await Lua_default.extensions.core_input_bindings.getRecentDevices(),!Array.isArray(devNames)||devNames.length===0?devNames=devNamesOrder:isKbm(devNames[0])&&(devNames=[...kbmDevNames,...devNames.filter(devName=>!isKbm(devName))]),lastDeviceOrder.value.splice(0,lastDeviceOrder.value.length,...devNames)}function*getBindingsIter(devFilter=[],useLastDeviceOrder=!1){if(!useLastDeviceOrder||devFilter.length>0)yield*bindings.value;else for(let devName of lastDeviceOrder.value){let binding=bindingsPerDevice.value[devName];binding&&(yield binding)}}let findBindingForAction=(action,devName=void 0,useLastDeviceOrder=!1)=>{let devFilter=devName?Array.isArray(devName)?devName:[devName]:[],bindingsIter=getBindingsIter(devFilter,useLastDeviceOrder);for(let binding of bindingsIter){if(devFilter.length>0&&!devFilter.includes(binding.devname))continue;let found=binding.contents.bindings.find(b=>b.action===action);if(found){let help=getBindingDetails(binding.devname,found.control,action);if(help)return help.devName=binding.devname,help.imagePack=binding.contents.imagePack,help}}},findAllBindingsForAction=(action,devName=void 0,allDevices=!1,useLastDeviceOrder=!1)=>{let res=[],devFilter=devName?Array.isArray(devName)?devName:[devName]:[],bindingsIter=getBindingsIter(devFilter,useLastDeviceOrder);for(let binding of bindingsIter){if(devFilter.length>0&&!devFilter.includes(binding.devname))continue;let matches$1=binding.contents.bindings.filter(b=>b.action===action);if(matches$1.length>0)for(let match of matches$1){let help=getBindingDetails(binding.devname,match.control,action);help&&(!allDevices&&devFilter.length===0&&devFilter.push(binding.devname),help.devName=binding.devname,help.imagePack=binding.contents.imagePack,res.push(help))}}return res},defaultBindingEntry=(action,control)=>({...bindingTemplate.value,action,control}),isAxis=(device,control)=>{let c=controllers.value[device].controls[control];return c&&c.control_type==`axis`},bindingConflicts=(device,control,action)=>bindings.value.find(b=>b.devname==device).contents.bindings.filter(b=>b.control==control).filter(b=>b.action!=action).map(b=>({...b,...getBindingDetails(device,control,b.action),resolved:!1})),captureBinding=(modifiersAllowed=!0)=>{let controlCaptured=!1,eventsRegister={},d=defer(),capturingBinding=!0;function _listener(data){if(!capturingBinding||controlCaptured)return;let devName=data.devName;eventsRegister[devName]||(eventsRegister[devName]={axis:{},key:[null,null]});let eventData=eventsRegister[devName];d.notify(eventsRegister);let valid=!1,key0,key1,key0Parts,key1Parts,genericModifierKeys=[`lalt`,`lcontrol`,`lshift`,`ralt`,`rcontrol`,`rshift`];switch(data.controlType){case`axis`:if(!eventData.axis[data.control])eventData.axis[data.control]={first:data.value,last:data.value,accumulated:0};else{let detectionThreshold=devName.startsWith(`mouse`)?1:.5;eventData.axis[data.control].accumulated+=Math.abs(eventData.axis[data.control].last-data.value)/detectionThreshold,eventData.axis[data.control].last=data.value}valid=eventData.axis[data.control].accumulated>=1;break;case`button`:case`pov`:case`key`:if(eventData.key=[eventData.key.at(-1),data.control],key0=eventData.key[0],key1=eventData.key[1],key0&&key1){let validSet=!1;key0Parts=key0.split(` `),key1Parts=key1.split(` `),key0Parts.length===1&&key1Parts.length===2&&key1Parts[1]===key0Parts[0]&&(eventData.key[1]=key0,key1=key0,data.control=key0,modifiersAllowed||(valid=!1,validSet=!0)),validSet||(valid=key0===key1,!modifiersAllowed&&(key0Parts.length===2||genericModifierKeys.includes(data.control))&&(valid=!1)),data.value===0&&(eventData.key=[null,null])}break;default:console.error(`Unrecognised raw input controlType: `+JSON.stringify(data))}valid&&data.devName.startsWith(`mouse`)&&data.control===`button1`&&(valid=!1),valid&&(controlCaptured=!0,capturingBinding=!1,data.direction=data.controlType===`axis`?Math.sign(eventData.axis[data.control].last-eventData.axis[data.control].first):0,d.resolve(data),_captureHelper.stopListening())}return Lua_default.ActionMap.enableBindingCapturing(!0),Lua_default.setCEFTyping(!0),_captureHelper.stopListening=()=>{Lua_default.ActionMap.enableBindingCapturing(!1),Lua_default.WinInput.setForwardRawEvents(!1),Lua_default.setCEFTyping(!1),events$3.off(`RawInputChanged`,_listener)},events$3.on(`RawInputChanged`,_listener),Lua_default.WinInput.setForwardRawEvents(!0),d.promise},removeBinding=(device,control,action,mockSave)=>{let deviceContents={...bindings.value.find(b=>b.devname==device).contents};deviceContents.bindings=[...deviceContents.bindings];let entryIndex=deviceContents.bindings.findIndex(b=>b.control==control&&b.action==action)||null;if(entryIndex)if(deviceContents.bindings.splice(entryIndex,1),mockSave){let deviceIndex=bindings.value.findIndex(b=>b.devname==device);bindings.value[deviceIndex].contents=deviceContents}else serializeCheck(deviceContents.name),Lua_default.extensions.core_input_bindings.saveBindingsToDisk(deviceContents)},addBinding=(device,bindingData,replace,mockSave)=>{let deviceContents={...bindings.value.find(b=>b.devname==device).contents};if(deviceContents.bindings=[...deviceContents.bindings],replace){let deprecatedIndex=deviceContents.bindings.findIndex(b=>b.control==bindingData.details.control&&b.action==bindingData.details.action);deviceContents[deprecatedIndex]=bindingData}else serializeCheck(deviceContents.name),Lua_default.extensions.core_input_bindings.saveBindingsToDisk(deviceContents)},isFFBBound=()=>{for(let i=0;i{let ffbCapable=()=>Object.values(controllers.value).some(controller=>controller.ffbAxes&&Object.keys(controller.ffbAxes).length>0);return asRef?computed(()=>ffbCapable()):ffbCapable},getIsControllerAvailable=(asRef=!1)=>asRef?isControllerAvailable:isControllerAvailable.value,isWheelFound=vendorId=>{for(let b of bindings.value)if(b.devname.slice(0,3)===`whe`&&b.contents.vidpid.slice(4,8)==vendorId)return!0;return!1};function isFFBEnabled(asRef=!1){let filter=()=>bindings.value.filter(b=>b.devname.slice(0,3)!==`xin`).some(b=>b.contents.bindings.some(binding=>binding.action===`steering`&&binding.isForceEnabled));return asRef?computed(()=>filter()):filter()}function isPidVidFound(desiredVid,desiredPid,asRef=!1){let filter=()=>bindings.value.some(b=>{let vid=desiredVid===void 0?desiredVid:b.contents.vidpid.slice(4,8),pid$1=desiredPid===void 0?desiredPid:b.contents.vidpid.slice(0,4);return vid==desiredVid&&pid$1==desiredPid});return asRef?computed(()=>filter()):filter()}function getBindingDetails(device,control,action){let actionDetails=getActionDetails(action);if(!actionDetails){console.warn(`Action details not found: `,action);return}let deviceBindings=bindings.value.find(b=>b.devname===device).contents.bindings,common={icon:deviceIcon(device),title:actionDetails.title,desc:actionDetails.desc},details=deviceBindings.find(b=>b.control===control&&b.action===action)||defaultBindingEntry(action,control),isBindingAxis=isAxis(device,control);return{...bindingTemplate.value,...details,...common,isAxis:isBindingAxis,action:actionDetails.action,actionName:actionDetails.actionName}}function getActionDetails(action){let actionDetails=actions.value[action];if(actionDetails)return{...actionDetails,action:actionDetails.actionName}}function addNewBinding(bindingData){let{devname,control,action}=bindingData,device=bindings.value.find(b=>b.devname==devname);if(!device){console.warn(`Device not found: `,devname);return}let deviceContents=device.contents;deviceContents.bindings.push({...bindingTemplate.value,...bindingData,control,action}),serializeCheck(deviceContents.name),Lua_default.extensions.core_input_bindings.saveBindingsToDisk(deviceContents)}function updateBinding(bindingData){let{devname,control,action}=bindingData,oldDevname=bindingData.oldDevname||devname,oldControl=bindingData.oldControl||control,device=bindings.value.find(b=>b.devname==oldDevname);if(!device){console.warn(`Device not found: `,oldDevname);return}let deviceContents=device.contents,deprecatedIndex=deviceContents.bindings.findIndex(b=>b.control==oldControl&&b.action==action);if(deprecatedIndex===-1){console.warn(`Binding not found: `,oldDevname,oldControl,action);return}if(devname===oldDevname)delete bindingData.oldDevname,delete bindingData.oldControl,deviceContents.bindings[deprecatedIndex]={...bindingData};else{deviceContents.bindings.splice(deprecatedIndex,1);let newDeviceContents=bindings.value.find(b=>b.devname===devname).contents;newDeviceContents.bindings.push({...bindingData,bindingTemplate:bindingTemplate.value}),serializeCheck(newDeviceContents.name),Lua_default.extensions.core_input_bindings.saveBindingsToDisk(newDeviceContents)}serializeCheck(deviceContents.name),Lua_default.extensions.core_input_bindings.saveBindingsToDisk(deviceContents)}function deleteBindings(bindingsData){let bindingsByDevname=bindingsData.reduce((acc,b)=>(acc[b.devname]=acc[b.devname]||[],acc[b.devname].push(b),acc),{});for(let devname in bindingsByDevname){let device=bindings.value.find(b=>b.devname==devname);if(!device){console.warn(`Device not found: `,devname);continue}let deviceContents=device.contents;bindingsByDevname[devname].forEach(b=>{let index=deviceContents.bindings.findIndex(binding=>binding.control==b.control&&binding.action==b.action);index!==-1&&deviceContents.bindings.splice(index,1)}),serializeCheck(deviceContents.name),Lua_default.extensions.core_input_bindings.saveBindingsToDisk(deviceContents)}}function deleteBinding({devname,control,action}){let device=bindings.value.find(b=>b.devname==devname);if(!device){console.warn(`Device not found: `,devname);return}let deviceContents=device.contents,index=deviceContents.bindings.findIndex(b=>b.control==control&&b.action==action);if(index===-1){console.warn(`Binding not found: Skipping...`,devname,control,action);return}deviceContents.bindings.splice(index,1),serializeCheck(deviceContents.name),Lua_default.extensions.core_input_bindings.saveBindingsToDisk(deviceContents)}function getAllBindingsForAction(action,devName,asRef=!1){let filteredBindings=()=>bindings.value.filter(b=>(!devName||b.devname==devName)&&b.contents.bindings.find(a$1=>a$1.action===action)).flatMap(b=>b.contents.bindings.filter(x=>x.action===action).map(x=>({...x,...getBindingDetails(b.devname,x.control,x.action),devname:b.devname,action,actionName:action})));return asRef?computed(()=>filteredBindings()):filteredBindings()}let _captureHelper={devName:null,stopListening:null};function _updateDeviceNotes(){Object.values(bindings.value).forEach(({contents:bindingContents})=>{for(let id in controllers.value){let controller=controllers.value[id];if(bindingContents.vidpid==controller.vidpid){controller.notes=bindingContents.notes;break}}})}let lastBindingsData=null;function _processBindingsData(data){let newBindingsData=JSON.stringify(data);if(lastBindingsData===newBindingsData)return;if(lastBindingsData=newBindingsData,Array.isArray(data.bindings)||(data.bindings=[]),data.bindings.forEach(device=>{Array.isArray(device.contents.bindings)||(device.contents.bindings=Object.values(device.contents.bindings))}),bindingTemplate.value=data.bindingTemplate,bindings.value=data.bindings,!data.actionCategories||!data.bindingTemplate||data.bindings.length===0){logger_default.debug(`Did not receive bindings data. Timing issue?`);return}bindings.value.sort((a$1,b)=>deviceSorter(a$1.devname,b.devname)),devNamesOrder.splice(0),kbmDevNames.splice(0);for(let binding of data.bindings){let devName=binding.devname;devNamesOrder.includes(devName)||devNamesOrder.push(devName),isKbm(devName)&&kbmDevNames.push(devName),binding.icon=deviceIcon(devName)}_requestRecentDevices();let acts={};for(let act in data.actions)acts[act]={actionName:act,...data.actions[act]};for(let cat in actions.value=acts,categories.value=data.actionCategories,categories.value)typeof categories.value[cat]==`object`&&(categories.value[cat].actions=[]);for(let act in actions.value){let obj={key:act,...actions.value[act]};actions.value[act].cat in categories.value||(categories.value[actions.value[act].cat]={order:99,icon:`symbol_exclamation`,title:`UNDEFINED CATEGORY: `+actions.value[act].cat,desc:``,actions:[]}),categories.value[actions.value[act].cat].actions.push(obj)}for(let x in categoriesList.value=[],Object.entries(categories.value).forEach(([catName,cat])=>categoriesList.value.push({key:catName,...cat})),categoriesList.value)for(let y in categoriesList.value[x].actions)for(let z in categoriesList.value[x].actions[y].titleTranslated=$translate.instant(categoriesList.value[x].actions[y].title),categoriesList.value[x].actions[y].descTranslated=$translate.instant(categoriesList.value[x].actions[y].desc),categoriesList.value[x].actions[y].tags)categoriesList.value[x].actions[y].tagsTranslated||(categoriesList.value[x].actions[y].tagsTranslated=[]),categoriesList.value[x].actions[y].tagsTranslated[z]=$translate.instant(categoriesList.value[x].actions[y].tags[z]);_updateDeviceNotes()}function makeViewerObj({deviceKey,device,action,uiEvent,imagePack,controller=!1,actionVariants=!1,useLastDevice=!1}){let viewerObj,multiDevice=!1;if(device&&Array.isArray(device)&&device.length===0&&(device=void 0),Array.isArray(device)&&(device.length===0?device=void 0:device.length===1?device=device[0]:multiDevice=!0),!device&&controller&&(device=lastControllers.value,device.length===0?device=void 0:device.length===1?device=device[0]:multiDevice=!0),uiEvent&&(action=ACTIONS_BY_UI_EVENT[uiEvent]),action?actionVariants?(viewerObj=_buildViewerObjVariants(findAllBindingsForAction(action,device,!1,useLastDevice)),actionVariants=!!viewerObj?.variants,actionVariants&&viewerObj.variants.sort((a$1,b)=>a$1.isInverted-b.isInverted)):viewerObj=findBindingForAction(action,device,useLastDevice):actionVariants=!1,deviceKey){let devName=viewerObj?.devName||(multiDevice?device[0]:device);viewerObj={icon:deviceIcon(devName),control:deviceKey,devName,imagePack:viewerObj?.imagePack||imagePack}}return viewerObj&&(_parseViewerObj(viewerObj,imagePack,actionVariants),viewerObj.variants&&viewerObj.variants.forEach(obj=>_parseViewerObj(obj,imagePack,actionVariants,device))),viewerObj}function _buildViewerObjVariants(viewerObjs){let len=viewerObjs?.length||0;if(len!==0)return len===1?viewerObjs[0]:{...viewerObjs[0],variants:viewerObjs}}let rgxCombo=/modifier(?\d+)[ -]+|[ -]*(?.+)/gi;function _parseViewerObj(viewerObj,imagePack=void 0,actionVariants=!1,devNames=void 0){let devName=viewerObj.devName;if(imagePack=viewerObj.imagePack||imagePack,!imagePack){let binding=bindings.value?.find(b=>b.devname===devName);binding?.contents?.imagePack&&(imagePack=binding.contents.imagePack),!imagePack&&devName&&(imagePack=CONTROL_ICON_KEYS.find(key=>devName.startsWith(key))),viewerObj.imagePack=imagePack}if(viewerObj.control.startsWith(`modifier`)){let matches$1=[...viewerObj.control.matchAll(rgxCombo)].map(m=>m.groups);if(matches$1.length>0){viewerObj.multiControls=[];for(let match of matches$1)if(match.mod){let modName=`customModifier`+match.mod,mod=actionVariants?_buildViewerObjVariants(findAllBindingsForAction(modName,devName,!1,!1)):findBindingForAction(modName,devName);mod||=actionVariants?_buildViewerObjVariants(findAllBindingsForAction(modName,devNames,!1,!1)):findBindingForAction(modName,devNames),mod&&viewerObj.multiControls.push(mod)}else viewerObj.multiControls.push({devName,control:match.key,icon:viewerObj.icon,imagePack})}}_addCustomInfo(viewerObj),viewerObj.multiControls&&viewerObj.multiControls.forEach(_addCustomInfo)}function _addCustomInfo(viewerObj){let devOverrides=getViewerOverrides(viewerObj.devName,viewerObj.imagePack);viewerObj.family=devOverrides?.family;let ownIcon=devOverrides?.icons[viewerObj.control];viewerObj.special=!!ownIcon,viewerObj.ownGroups=devOverrides?.groups,viewerObj.special?viewerObj.ownIcon=ownIcon:viewerObj.control=controlLabel(viewerObj.control)}return connect(),_getBindingsData(),{categories:computed(()=>categories.value),categoriesList:computed(()=>categoriesList.value),controllers:computed(()=>controllers.value),players:computed(()=>players.value),bindingTemplate:computed(()=>bindingTemplate.value),lastDevice:lastDeviceSimple,lastDevices:lastDeviceOrder,lastControllers,lastControllersSignature,isControllerAvailable,isControllerUsed,showIfController:isControllerUsed,focusIfController:isControllerAvailable,addNewBinding,connect,deleteBinding,deleteBindings,disconnect,deviceIcon,findBindingForAction,findAllBindingsForAction,getActionDetails,getBindingDetails,getAllBindingsForAction,defaultBindingEntry,isAxis,bindingConflicts,captureBinding,removeBinding,addBinding,isFFBBound,isFFBEnabled,isFFBCapable,isGamepadAvailable:getIsControllerAvailable,isWheelFound,isPidVidFound,makeViewerObj,updateBinding}}),useStore=()=>store||=makeStore(),controls_default=useStore,direction=`right`,focusClass=`focus-visible`,isController$1={value:!1},now=()=>new Date().getTime(),inited=!1,gamepadInited=!1,elms$3=[];function setFocus(elm,enable=!0){if(enable){if(elm.classList.add(focusClass),elm===document.activeElement)return}else if(elm.classList.remove(focusClass),elm!==document.activeElement)return;try{enable&&focusOnElement(elm)}catch{}}function setFocusExternal(elm,enable=!0,attemptScroll=!0){return elm?(!gamepadInited&&gamepadInit(),enable&&!isController$1.value?(attemptScroll&&isOccluded(elm,!0)&&scrollFix({dom:elm,rect:elm.getBoundingClientRect()},`down`),!1):(setFocus(elm,enable),!0)):!1}function ensureFocus(elm,onNextTick=!0){elm&&(!gamepadInited&&gamepadInit(),isController$1.value&&document.activeElement===elm&&!elm.classList.contains(focusClass)&&(onNextTick?nextTick(()=>elm&&setFocus(elm)):setFocus(elm)))}function gamepadInit(){gamepadInited||(gamepadInited=!0,isController$1=storeToRefs(controls_default()).focusIfController)}function init$1(){inited||(inited=!0,gamepadInit(),watch(isController$1,val=>{let active=document.activeElement;if(isNavigable$1(active)){let focused$1=active.classList.contains(focusClass);val&&!focused$1?setFocus(active,!0):!val&&focused$1&&setFocus(active,!1);return}if(val){if(priorityFocus())return;navigate(collectRects(direction),direction)&&window.requestAnimationFrame(()=>setFocus(document.activeElement,!0))}}))}function priorityFocus(){collectRects(direction);for(let{elm}of elms$3)if(isNavigable$1(elm))return setFocus(elm,!0),!0;return!1}function wantsFocus(elm,priority){inited||init$1();let dat=elms$3.find(itm=>itm.element===elm)||{elm,time:now()},isNew=!(`priority`in dat);if(typeof priority!=`number`||isNaN(priority)){if(!isNew){let idx=elms$3.findIndex(itm=>itm.elm===elm);idx>-1&&elms$3.splice(idx,1)}return}dat.priority=priority,isNew&&elms$3.push(dat),elms$3.sort((a$1,b)=>b.priority-a$1.priority||b.time-a$1.time),collectRects(direction,elm.parentNode),isNew&&isController$1.value&&!isNavigable$1(document.activeElement)&&priorityFocus()}function unwantsFocus(elm){let idx=elms$3.findIndex(itm=>itm.elm===elm);idx!==-1&&(elms$3.splice(idx,1),isController$1.value&&!isNavigable$1(document.activeElement)&&priorityFocus())}function initFocusVisible(){let raf=window.requestAnimationFrame,curFocused=null,holdFocus=!1;function notify(type,target,relatedTarget){let evt=new CustomEvent(`uinav-`+type,{bubbles:!0,cancelable:!0,detail:{target,relatedTarget}});document.dispatchEvent(evt)}function procFocus(target,relatedTarget){if(!(target&&target===curFocused)&&(relatedTarget===target&&(relatedTarget=void 0),relatedTarget&&doBlur(relatedTarget),curFocused&&=((!relatedTarget||relatedTarget!==curFocused)&&(relatedTarget=curFocused),doBlur(curFocused),null),target))try{if(target.disabled)return;if(`tabIndex`in target){if(typeof target.tabIndex==`string`&&target.tabIndex===`-1`||typeof target.tabIndex==`number`&&target.tabIndex===-1||target.tabIndex===``)return}else if(`contentEditable`in target){if(typeof target.contentEditable==`string`&&target.contentEditable!==`true`||typeof target.contentEditable==`boolean`&&!target.contentEditable)return}else return;let style=window.getComputedStyle(target);if(style.display===`none`||style.visibility===`hidden`||style.pointerEvents===`none`)return;if(isController$1.value&&target.classList.add(focusClass),curFocused=target,focusRegistry.includes(target)||focusRegistry.push(target),document.activeElement!==curFocused){holdFocus=!0;let holdFocusCounter=0;raf(function check(){!curFocused||holdFocusCounter>10||document.activeElement===curFocused?(holdFocus=!1,!curFocused||target!==curFocused?doBlur(target):notify(`focus`,curFocused,relatedTarget)):(holdFocusCounter++,curFocused.focus(),raf(check))})}else notify(`focus`,target,relatedTarget)}catch{}}function doBlur(target){if(target&&!(holdFocus&&target===curFocused))try{target.classList.remove(focusClass),target===curFocused&&(curFocused=null);let idx=focusRegistry.indexOf(target);idx!==-1&&(focusRegistry.splice(idx,1),notify(`blur`,target))}catch{}}document.addEventListener(`focusin`,evt=>procFocus(evt.target,evt.relatedTarget),!0),document.addEventListener(`focusout`,evt=>doBlur(evt.target),!0);let focusRegistry=[],originalFocus=HTMLElement.prototype.focus.__original__||HTMLElement.prototype.focus,originalBlur=HTMLElement.prototype.blur.__original__||HTMLElement.prototype.blur;HTMLElement.prototype.focus=function(...args){let target=this,prevFocused=document.activeElement;prevFocused.classList.contains(focusClass)||(focusRegistry.length>0?focusRegistry.forEach(elm=>elm!==target&&elm.blur()):document.querySelectorAll(`.`+focusClass).forEach(elm=>elm!==target&&doBlur(elm))),originalFocus.apply(target,args),procFocus(target,prevFocused)},HTMLElement.prototype.blur=function(...args){doBlur(this),originalBlur.apply(this,args)},HTMLElement.prototype.focus.__original__=originalFocus,HTMLElement.prototype.blur.__original__=originalBlur}var EVENT_CALLS=Object.entries({focus:[`uinav-focus`,`focus`,`focusin`,`click`],hide:[`mouseenter`],show:[`uinav-blur`,`blur`,`focusout`,`mouseleave`]}).reduce((res,[name,events$3])=>(events$3.forEach(event=>res[event]=name),res),{}),ID$1=`__bngFocusCapture`,elms$2={},isController;function setupController(){isController||(isController=storeToRefs(controls_default()).isControllerUsed,watch(isController,val=>{for(let data of Object.values(elms$2))val?data.show():data.hide()}))}function getClosestNavigable(elm){let target=collectRects(`down`,elm).down[0]?.dom;return target&&isNavigable$1(target)?target:null}function update$3(data,value,firstTime=!1){if(typeof value==`function`?(data.handler=()=>{let elm=value(data.parent);return elm?.$el||elm},delete data.disabled):typeof value==`boolean`&&!value?data.disabled=!0:delete data.disabled,data.disabled){if(data.hide(),!firstTime)for(let event in data.capture.remove(),EVENT_CALLS)data.parent.removeEventListener(event,data[EVENT_CALLS[event]])}else for(let event in data.parent.appendChild(data.capture),data.show(),EVENT_CALLS)data.parent.addEventListener(event,data[EVENT_CALLS[event]])}var BngFocusCapture_default={mounted(elm,{arg,value}){setupController();let id=uniqueId(ID$1),parent=elm,capture=document.createElement(`div`),data={id,shown:!0,parent,capture,handler:()=>getClosestNavigable(data.parent)};elms$2[id]=data,parent[ID$1]=id,capture.className=`bng-focus-capture`,capture.style.setProperty(`position`,`absolute`,`important`),capture.style.setProperty(`display`,`block`,`important`),capture.style.setProperty(`top`,`0%`,`important`),capture.style.setProperty(`left`,`0%`,`important`),capture.style.setProperty(`width`,`100%`,`important`),capture.style.setProperty(`height`,`100%`,`important`),capture.style.setProperty(`z-index`,arg&&/^\d+$/.test(arg)?arg:`1000`,`important`),capture.style.setProperty(`pointer-events`,`all`,`important`),capture.setAttribute(`bng-nav-item`,``),capture.setAttribute(`tabindex`,`0`),data.focus=()=>{if(data.hide(),!isController.value)return;let active=document.activeElement;if(!(active!==data.capture&&data.parent.contains(active))&&data.handler){let elm$1=data.handler(data.parent);elm$1&&nextTick(()=>setFocusExternal(elm$1))}},data.hide=()=>{data.shown&&(data.shown=!1,capture.style.setProperty(`pointer-events`,`none`,`important`))},data.show=evt=>{if(data.shown||(data.shown=!0,data.disabled||!isController.value))return;let active=document.activeElement;if(data.parent.contains(active))return;let target=evt?.relatedTarget||evt?.target||active;data.parent.contains(target)||capture.style.setProperty(`pointer-events`,`all`,`important`)},update$3(data,value,!0)},updated(elm,{arg,value}){let id=elm[ID$1];if(!id)return;let data=elms$2[id];data&&update$3(data,value)},unmounted(elm){let id=elm[ID$1];if(!id)return;delete elm[ID$1];let data=elms$2[id];if(data){for(let event in data.capture.remove(),EVENT_CALLS)data.parent.removeEventListener(event,data[EVENT_CALLS[event]]);delete elms$2[id]}}},BngFocusIf_default=(el,{value})=>value&&nextTick(()=>{let shouldFocus=typeof value==`object`?value.value:value,findNavItem=typeof value==`object`?value.findNavItem:!1;if(!el||!shouldFocus)return;let targetEl=el;if(findNavItem){let navItems=el.querySelectorAll(`[is-bng-panel], [bng-nav-item], [ng-click], [href], [bng-all-clicks], [bng-all-clicks-no-nav], [ui-sref], input, textarea, button, md-option, md-slider, md-select, md-checkbox`);navItems&&navItems.length>0&&(targetEl=navItems[0])}targetEl.focus();let blur$1=()=>{targetEl.classList.remove(`focus-visible`),targetEl.removeEventListener(`blur`,blur$1)};targetEl.addEventListener(`blur`,blur$1),targetEl.classList.add(`focus-visible`)}),elems=new WeakMap,curHorizontal=0,curVertical=0;function updateGE(horizontal=0,vertical=0){curHorizontal=horizontal,curVertical=vertical,bngApi.engineLua(`scenetree.OnlyGui:setFrustumCameraCenterOffset(Point2F(${horizontal}, ${vertical}))`)}var moveSpeed=1,smoothingUpdate;function updateGEsmooth(horizontal=0,vertical=0){if(smoothingUpdate){smoothingUpdate(horizontal,vertical);return}let dirH=1,dirV=1;function setDir(){dirH=horizontal>=curHorizontal?1:-1,dirV=vertical>=curVertical?1:-1}setDir(),smoothingUpdate=(h$1=0,v=0)=>{horizontal=h$1,vertical=v,setDir()},window.requestAnimationFrame(function(ms){let speed=moveSpeed/1e3,movH=curHorizontal,movV=curVertical,lastTime=ms,smoother=0;window.requestAnimationFrame(function step(ms$1){if(curHorizontal===horizontal&&curVertical===vertical){smoothingUpdate=null;return}smoother+=(ms$1-lastTime-smoother)*.02,lastTime=ms$1;let moveDelta=smoother*speed;movH+=moveDelta*dirH,movV+=moveDelta*dirV,(dirH>0&&movH>horizontal||dirH<0&&movH0&&movV>vertical||dirV<0&&movV{let updateDebounce=debounce(updateFrustum,50),updateWrapper=()=>updateDebounce(),resizeObserver=new ResizeObserver(updateWrapper);resizeObserver.observe(el),elems.set(el,{updateFrustum:updateDebounce,destroy:()=>{resizeObserver.disconnect(),window.removeEventListener(`resize`,updateWrapper),elems.delete(el),updateDebounce(0,0)}}),window.addEventListener(`resize`,updateWrapper);let curDirection=binding.arg||`left`,curSmooth=binding.modifiers.smooth,curState=binding.value===void 0?!0:!!binding.value;function updateFrustum(direction$1,enabled,smooth){direction$1||=curDirection,[`left`,`right`,`up`,`down`].includes(direction$1)?curDirection=direction$1:(console.error(`Frustum mover only supports left/right/up/down directions`),enabled=!1),typeof enabled!=`boolean`&&(enabled=curState),curState=enabled,typeof smooth!=`boolean`&&(smooth=curSmooth),curSmooth=smooth;let updater=smooth?updateGEsmooth:updateGE;if(!enabled){updater();return}let side=direction$1===`left`||direction$1===`right`?`width`:`height`,screenSize=window.screen[side],movePower=el.getBoundingClientRect()[side]/screenSize*power;movePower<.001?movePower=0:(direction$1===`left`||direction$1===`down`)&&(movePower=-movePower),updater(direction$1===`left`||direction$1===`right`?movePower:0,direction$1===`up`||direction$1===`down`?movePower:0)}},updated:(el,binding)=>{let itm=elems.get(el);itm&&itm.updateFrustum(binding.arg,!!binding.value,!!binding.modifiers.smooth)},unmounted:(el,binding)=>{let itm=elems.get(el);itm&&itm.destroy()}},highlighter=[``,``],rgxSanitize=str=>str.replace(/[\\[]\?:.\*\+\-]/g,`\\$1`),BngHighlighter_default=(el,binding,vnode,prevVnode)=>{if(vnode.children.length!==1||vnode.children[0].type.toString()!==`Symbol(v-txt)`){el.__highlightwarned||(el.__highlightwarned=!0,console.warn(`Only a single inner text v-node supported`,el));return}let res=vnode.children[0].children.replace(//g,`>`),highlight=binding.value;if(highlight){let rgx;if(highlight instanceof RegExp)highlight.test(res)&&(rgx=highlight);else{let searchCase=str=>binding.modifiers.case?str:str.toLowerCase(),searchSource=searchCase(res),checkString=str=>searchSource.indexOf(str)>-1,buildRegexp=str=>RegExp(`(${str})`,`gm`+(binding.modifiers.case?``:`i`));if(typeof highlight==`object`&&Array.isArray(highlight)){let found=[];for(let str of highlight)str&&(str=searchCase(String(str)),checkString(str)&&found.push(str));found.length>0&&(rgx=buildRegexp(found.map(str=>rgxSanitize(str)).join(`|`)))}else{let str=searchCase(String(highlight));checkString(str)&&(rgx=buildRegexp(rgxSanitize(str)))}}rgx&&(res=res.replace(rgx,`${highlighter[0]}$1${highlighter[1]}`))}el.innerHTML!==res&&(el.innerHTML=res)},ExecQueue=class{resolution={rejectThis:`rejectThis`,rejectOthers:`rejectOthers`,resolveThis:`resolveThis`,resolveOthers:`resolveOthers`,replaceWithReject:`replaceWithReject`,replaceWithResolve:`replaceWithResolve`,merge:`merge`};_queue=[];_processing=!1;_tick=0;_tickFunc=nextTick;_runningCount=0;_concurrency=1;constructor(tick=0,concurrency=1){this.tick=tick,this.concurrency=concurrency}get tick(){return this._tick}set tick(val){typeof val!=`number`&&(val=0),this._tick=val,this._tickFunc=val===0?func=>nextTick(func.bind(this)):func=>setTimeout(func.bind(this),this._tick)}get concurrency(){return this._concurrency}set concurrency(val){(typeof val!=`number`||val<1)&&(val=1),this._concurrency=val}shuffle(){this._shuffle=!0}async process(){if(!(this._processing||this._queue.length===0))for(this._processing=!0,this._shuffle&&=(this._queue=this._queue.sort(()=>Math.random()-.5),!1);this._runningCount0;){let item=this._queue.shift();if(!item)break;item.running=!0,this._runningCount++,this._processItem(item)}}async _processItem(item){try{let result=await item.func(...item.args);item.resolves?.forEach(resolve$1=>resolve$1?.(result))}catch(err){item.rejects.length>0?item.rejects?.forEach(reject=>reject?.(err)):console.error(err)}finally{this._runningCount--,this._tickFunc(()=>{this._processing=!1,this.process()})}}enqueue(name,func,args=[],conflicts={},resolve$1=null,reject=null){if(typeof conflicts==`object`&&Object.keys(conflicts).length>0)for(let i=this._queue.length-1;i>=0;i--){let item=this._queue[i];if(item.name in conflicts)switch(conflicts[item.name]){case this.resolution.merge:resolve$1&&item.resolves.push(resolve$1),reject&&item.rejects.push(reject);return;default:case this.resolution.rejectThis:reject?.(Error(`Function ${item.name} is rejected due to conflict`));return;case this.resolution.resolveThis:resolve$1?.();return;case this.resolution.rejectOthers:item.running||(item.rejects?.forEach(reject$1=>reject$1?.(Error(`Function ${item.name} is rejected due to conflict`))),this._queue.splice(i,1));break;case this.resolution.resolveOthers:case this.resolution.replaceWithResolve:item.running||(item.resolves?.forEach(resolve$2=>resolve$2?.()),this._queue.splice(i,1));break;case this.resolution.replaceWithReject:item.rejects?.forEach(reject$1=>reject$1?.(Error(`Function ${item.name} is replaced`))),this._queue.splice(i,1);break}}this._queue.push({name,func,args,resolves:[resolve$1],rejects:[reject]}),this._processing||(this._processing=!0,this._tickFunc(()=>{this._processing=!1,this.process()}))}promise(name,func,args=[],conflicts={}){return new Promise((resolve$1,reject)=>this.enqueue(name,func,args,conflicts,resolve$1,reject))}wrap(name,func,conflicts={}){return async(...args)=>await this.promise(name,func,args,conflicts)}},MAX_SIZE=500,OVERSIZE_LIMIT=100,CONCURRENCY_LIMIT=20,QUEUE_INTERVAL$1=0,OBS_ID=`__bngLazyImage`,cache=new Map,queue=new ExecQueue(QUEUE_INTERVAL$1,CONCURRENCY_LIMIT),observer$1=new IntersectionObserver(entries=>{for(let entry of entries)if(entry.isIntersecting){observer$1.unobserve(entry.target);let data=entry.target[OBS_ID];data.observed&&(data.observed=!1,queue.shuffle(),process(entry.target,data))}}),loadImage=url=>new Promise((resolve$1,reject)=>{let img=new Image;img.onload=async()=>{try{if(cache.sizeMAX_SIZE||img.height>MAX_SIZE)){let ratio=img.width/img.height,width$1,height$1;img.width>img.height?(width$1=MAX_SIZE,height$1=MAX_SIZE/ratio):(height$1=MAX_SIZE,width$1=MAX_SIZE*ratio);let cvs=new OffscreenCanvas(width$1,height$1);cvs.getContext(`2d`).drawImage(img,0,0,width$1,height$1);let bmp=await createImageBitmap(cvs);cache.set(img.src,{url,bmp})}}catch(err){reject(err)}resolve$1({url})},img.onerror=()=>reject(Error(`Failed to load image`)),img.src=url});function process(el,data){let{url,callback}=data,apply$1=imgData=>callback(el,imgData.url,imgData.bmp);if(cache.has(url)){apply$1(cache.get(url));return}apply$1(emptyImage),queue.enqueue(url,loadImage,[url],{url:queue.resolution.merge},data$1=>{apply$1(data$1)},err=>{logger_default.error(err),apply$1(url)})}function update$2(el,{arg,value}){let data={url:void 0,target:`src`,callback:void 0};if(typeof value==`string`)data.url=value;else if(typeof value==`object`&&!Array.isArray(value)&&value.url){if(data.url=value.url,data.target=value.target,data.callback=typeof value.callback==`function`?value.callback:void 0,!data.url||!data.target&&!data.callback)return}else return;if(el[OBS_ID]){let old=el[OBS_ID];if(old.observed&&observer$1.unobserve(el),old.url===data.url&&old.target===data.target&&old.callback===data.callback)return}el[OBS_ID]=data,arg===`observe`?(data.observed=!0,observer$1.observe(el)):process(el,data)}var BngLazyImage_default={mounted:update$2,updated:update$2,unmounted(el){el[OBS_ID]&&(el[OBS_ID].observed&&observer$1.unobserve(el),delete el[OBS_ID])}},elms$1=new Map,observer=new ResizeObserver(observed$1);function observed$1(entries){for(let entry of entries)elms$1.has(entry.target)?update$1(entry.target):observer.unobserve(entry.target)}function update$1(elm,data=void 0){if(data||=elms$1.get(elm),data)if(isVisibleFast(elm)){let screen$1={width:window.innerWidth,height:window.innerHeight,scrollX:window.scrollX,scrollY:window.scrollY},rect=elm.getBoundingClientRect(),metrics={x:rect.left+screen$1.scrollX,y:rect.top+screen$1.scrollY,width:rect.width,height:rect.height};data.set(data.id,metrics.x/screen$1.width,metrics.y/screen$1.height,metrics.width/screen$1.width,metrics.height/screen$1.height)}else data.reset(data.id)}var UINAV_PROP=`__BngOnUiNav`,_handlerToElement=handler$1=>{let element;switch(typeof handler$1){case`string`:element=document.querySelectorAll(handler$1)[0];break;case`object`:element=handler$1;break}return element instanceof HTMLElement&&element},_generateSignature=(vnode,eventNames,modifiers)=>`${UINAV_PROP}[${vnode.ctx.uid}]:`+(typeof eventNames==`string`?eventNames.split(`,`):eventNames).sort().join(`,`)+[``,...Object.keys(modifiers)].sort().join(`.`),_normalizedEvents=eventNames=>eventNames===`*`?[]:eventNames.split(`,`),_getDirData=(element,signature)=>element[UINAV_PROP]?.find(dir=>dir.signature===signature);function setup$2(data,element,vnode){if(data.modifiers.asMouse){if(data.eventNames.find(name=>!isOnOffEvent(name))){window.BNG_Logger&&window.BNG_Logger.error(`UINav directive asMouse modifier is only supported for on/off type events`,element);return}setupAsMouse(data,vnode)}typeof data.handler==`function`&&(applyUiNav(data,element),applyTracker(data,element))}function setupAsMouse(data,vnode){let handlerElement=_handlerToElement(data.handler);handlerElement&&(vnode={el:handlerElement});let eventFirer$1=vnode.ctx?.exposed?.fireEvent||eventDispatcherForElement(vnode.el),checkElementDisabled=vnode.ctx?.exposed?.getDisabledState||(()=>vnode.el.hasAttribute(`disabled`));delete data.modifiers.down,delete data.modifiers.up,data.mousedownActive=!1,data.handler=({detail})=>{if(checkElementDisabled())return;let fromControllerMarker={fromController:detail};return detail.value?(eventFirer$1(`mousedown`,fromControllerMarker),data.mousedownActive=!0):(eventFirer$1(`mouseup`,fromControllerMarker),data.mousedownActive&&(data.mousedownActive=!1,eventFirer$1(`click`,fromControllerMarker))),!!data.modifiers.bubble}}function applyTracker(data,element){let uiNavTracker=useUINavTracker();data.modifiers.focusRequired?(element.addEventListener(`focusin`,evt=>{let prevDirs=evt.relatedTarget?.[UINAV_PROP];if(prevDirs)for(let dir of prevDirs)dir.modifiers.focusRequired&&(dir.tracked.forEach(name=>uiNavTracker.removeEvent(name,dir.signature,evt.relatedTarget)),dir.tracked=[]);let cur=_getDirData(element,data.signature);cur&&(cur.tracked.lengthuiNavTracker.updateEvent(name,cur.signature,element,{active:cur.modifiers.active,nogroup:cur.modifiers.nogroup})),cur.tracked=[...cur.eventNames]))}),element.addEventListener(`focusout`,evt=>{let cur=_getDirData(element,data.signature);if(!cur||cur.tracked.length>0)return;let nextDirs=evt.relatedTarget?.[UINAV_PROP];(!nextDirs||!nextDirs.some(directive=>directive.modifiers.focusRequired))&&(cur.tracked.forEach(name=>uiNavTracker.removeEvent(name,cur.signature,element)),cur.tracked=[])})):(data.eventNames.forEach(name=>uiNavTracker.updateEvent(name,data.signature,element,{active:data.modifiers.active,nogroup:data.modifiers.nogroup})),data.tracked=[...data.eventNames])}function applyUiNav(data,element){let valueChecker;data.modifiers.down?valueChecker=checkOn:data.modifiers.up?valueChecker=0:!data.modifiers.asMouse&&!data.eventNames.find(name=>!isOnOffEvent(name))&&(valueChecker=checkOn),data.uiNavHandler=handlers_default.add(element,{name:name=>data.eventNames.includes(name),value:valueChecker,modified:data.modifiers.modified||!1,focusRequired:data.modifiers.focusRequired?element:void 0},data.handler),element.setAttribute(UI_EVENT_ATTR,``)}function mounted$1(element,{arg:eventNames,value:handler$1,modifiers},vnode){modifiers||={};let storage=element[UINAV_PROP]||(element[UINAV_PROP]=[]),signature=_generateSignature(vnode,eventNames,modifiers),data=storage.find(dir=>dir.signature===signature);data?window.BNG_Logger&&window.BNG_Logger.error(`Conflicting vBngOnUiNav directive on element`,element):(data={signature,eventNames:_normalizedEvents(eventNames),modifiers,handler:handler$1,uiNavHandler:null,mousedownActive:!1,tracked:[]},storage.push(data)),setup$2(data,element,vnode)}function updated$1(element,{arg:eventNames,value:handler$1,modifiers},vnode){modifiers||={};let data=_getDirData(element,_generateSignature(vnode,eventNames,modifiers));if(!data)return;typeof data.uiNavHandler==`function`&&handlers_default.remove(element,data.uiNavHandler);let normalizedEvents=_normalizedEvents(eventNames),oldEvents=data.tracked.filter(name=>!normalizedEvents.includes(name));if(oldEvents.length>0){let uiNavTracker=useUINavTracker();oldEvents.forEach(name=>uiNavTracker.removeEvent(name,data.signature,element)),data.tracked=data.tracked.filter(name=>normalizedEvents.includes(name))}data.eventNames=normalizedEvents,data.modifiers=modifiers,data.handler=handler$1,data.uiNavHandler=null,setup$2(data,element,vnode)}function dispose$1(element){let storage=element[UINAV_PROP];if(!storage)return;let uiNavTracker=useUINavTracker();storage.forEach(directive=>{directive.tracked.length>0&&directive.tracked.forEach(name=>uiNavTracker.removeEvent(name,directive.signature,element)),directive.uiNavHandler&&handlers_default.remove(element,directive.uiNavHandler)}),element.removeAttribute(UI_EVENT_ATTR),delete element[UINAV_PROP]}var BngOnUiNav_default={mounted:mounted$1,updated:updated$1,beforeUnmount:dispose$1},DIRECTIONS={horizontal:{[UI_EVENTS.focus_l]:-1,[UI_EVENTS.focus_r]:1},vertical:{[UI_EVENTS.focus_d]:-1,[UI_EVENTS.focus_u]:1}},HOLD_DELAY=400,REPEAT_INTERVAL=100,ELEMENT_FLAG=`__BNG_ONUINAVFOCUS`,BngOnUiNavFocus_default={mounted:(element,binding,vnode)=>{if(!binding.value)return;let opts={direction:binding.arg||`horizontal`,repeat:!!binding.modifiers.repeat,holdDelay:HOLD_DELAY,repeatInterval:REPEAT_INTERVAL,min:-1/0,max:1/0,step:1,value:null,callback:null,...typeof binding.value==`object`?binding.value:typeof binding.value==`function`?{callback:binding.value}:{}};!opts.events&&(opts.events=DIRECTIONS[opts.direction]);function process$1(evt){let detail=evt.fromController||evt.detail;if(!detail||!(detail.name in opts.events))return;let dir=opts.events[detail.name],val;if(typeof opts.value==`function`){let cur=opts.value(),res=cur+(typeof opts.step==`function`?opts.step():opts.step)*dir;dir<0&&res0&&res>opts.max&&(res=opts.max);let precision=10**(opts.step+`.`).split(/[.,]/)[1].length;res=precision>0?Math.round(res*precision)/precision:Math.round(res),cur===res?dir=0:val=res}dir&&opts.callback&&opts.callback(dir,val)}let dirUINav={arg:Object.keys(opts.events).join(`,`),modifiers:{focusRequired:!0,asMouse:!0}},dirClick={value:{clickCallback:process$1,holdCallback:opts.repeat?process$1:void 0,holdDelay:HOLD_DELAY,repeatInterval:REPEAT_INTERVAL}};BngOnUiNav_default.mounted(element,dirUINav,vnode),BngClick_default.mounted(element,dirClick,vnode),element[ELEMENT_FLAG]=!0},beforeUnmount:element=>{element[ELEMENT_FLAG]&&(BngClick_default.beforeUnmount(element),BngOnUiNav_default.beforeUnmount(element))}},DEFAULT_OPTS={intiallyOpen:!1,navEventToOpen:UI_EVENTS.ok,navEventToClose:UI_EVENTS.back},min=Math.min,max=Math.max,round$1=Math.round,floor=Math.floor,createCoords=v=>({x:v,y:v}),oppositeSideMap={left:`right`,right:`left`,bottom:`top`,top:`bottom`},oppositeAlignmentMap={start:`end`,end:`start`};function clamp$1(start,value,end){return max(start,min(value,end))}function evaluate(value,param){return typeof value==`function`?value(param):value}function getSide(placement){return placement.split(`-`)[0]}function getAlignment(placement){return placement.split(`-`)[1]}function getOppositeAxis(axis){return axis===`x`?`y`:`x`}function getAxisLength(axis){return axis===`y`?`height`:`width`}var yAxisSides=new Set([`top`,`bottom`]);function getSideAxis(placement){return yAxisSides.has(getSide(placement))?`y`:`x`}function getAlignmentAxis(placement){return getOppositeAxis(getSideAxis(placement))}function getAlignmentSides(placement,rects,rtl){rtl===void 0&&(rtl=!1);let alignment=getAlignment(placement),alignmentAxis=getAlignmentAxis(placement),length=getAxisLength(alignmentAxis),mainAlignmentSide=alignmentAxis===`x`?alignment===(rtl?`end`:`start`)?`right`:`left`:alignment===`start`?`bottom`:`top`;return rects.reference[length]>rects.floating[length]&&(mainAlignmentSide=getOppositePlacement(mainAlignmentSide)),[mainAlignmentSide,getOppositePlacement(mainAlignmentSide)]}function getExpandedPlacements(placement){let oppositePlacement=getOppositePlacement(placement);return[getOppositeAlignmentPlacement(placement),oppositePlacement,getOppositeAlignmentPlacement(oppositePlacement)]}function getOppositeAlignmentPlacement(placement){return placement.replace(/start|end/g,alignment=>oppositeAlignmentMap[alignment])}var lrPlacement=[`left`,`right`],rlPlacement=[`right`,`left`],tbPlacement=[`top`,`bottom`],btPlacement=[`bottom`,`top`];function getSideList(side,isStart,rtl){switch(side){case`top`:case`bottom`:return rtl?isStart?rlPlacement:lrPlacement:isStart?lrPlacement:rlPlacement;case`left`:case`right`:return isStart?tbPlacement:btPlacement;default:return[]}}function getOppositeAxisPlacements(placement,flipAlignment,direction$1,rtl){let alignment=getAlignment(placement),list=getSideList(getSide(placement),direction$1===`start`,rtl);return alignment&&(list=list.map(side=>side+`-`+alignment),flipAlignment&&(list=list.concat(list.map(getOppositeAlignmentPlacement)))),list}function getOppositePlacement(placement){return placement.replace(/left|right|bottom|top/g,side=>oppositeSideMap[side])}function expandPaddingObject(padding){return{top:0,right:0,bottom:0,left:0,...padding}}function getPaddingObject(padding){return typeof padding==`number`?{top:padding,right:padding,bottom:padding,left:padding}:expandPaddingObject(padding)}function rectToClientRect(rect){let{x,y,width:width$1,height:height$1}=rect;return{width:width$1,height:height$1,top:y,left:x,right:x+width$1,bottom:y+height$1,x,y}}function computeCoordsFromPlacement(_ref,placement,rtl){let{reference,floating}=_ref,sideAxis=getSideAxis(placement),alignmentAxis=getAlignmentAxis(placement),alignLength=getAxisLength(alignmentAxis),side=getSide(placement),isVertical=sideAxis===`y`,commonX=reference.x+reference.width/2-floating.width/2,commonY=reference.y+reference.height/2-floating.height/2,commonAlign=reference[alignLength]/2-floating[alignLength]/2,coords;switch(side){case`top`:coords={x:commonX,y:reference.y-floating.height};break;case`bottom`:coords={x:commonX,y:reference.y+reference.height};break;case`right`:coords={x:reference.x+reference.width,y:commonY};break;case`left`:coords={x:reference.x-floating.width,y:commonY};break;default:coords={x:reference.x,y:reference.y}}switch(getAlignment(placement)){case`start`:coords[alignmentAxis]-=commonAlign*(rtl&&isVertical?-1:1);break;case`end`:coords[alignmentAxis]+=commonAlign*(rtl&&isVertical?-1:1);break}return coords}var computePosition$1=async(reference,floating,config)=>{let{placement=`bottom`,strategy=`absolute`,middleware=[],platform:platform$1}=config,validMiddleware=middleware.filter(Boolean),rtl=await(platform$1.isRTL==null?void 0:platform$1.isRTL(floating)),rects=await platform$1.getElementRects({reference,floating,strategy}),{x,y}=computeCoordsFromPlacement(rects,placement,rtl),statefulPlacement=placement,middlewareData={},resetCount=0;for(let i=0;i({name:`arrow`,options,async fn(state){let{x,y,placement,rects,platform:platform$1,elements,middlewareData}=state,{element,padding=0}=evaluate(options,state)||{};if(element==null)return{};let paddingObject=getPaddingObject(padding),coords={x,y},axis=getAlignmentAxis(placement),length=getAxisLength(axis),arrowDimensions=await platform$1.getDimensions(element),isYAxis=axis===`y`,minProp=isYAxis?`top`:`left`,maxProp=isYAxis?`bottom`:`right`,clientProp=isYAxis?`clientHeight`:`clientWidth`,endDiff=rects.reference[length]+rects.reference[axis]-coords[axis]-rects.floating[length],startDiff=coords[axis]-rects.reference[axis],arrowOffsetParent=await(platform$1.getOffsetParent==null?void 0:platform$1.getOffsetParent(element)),clientSize=arrowOffsetParent?arrowOffsetParent[clientProp]:0;(!clientSize||!await(platform$1.isElement==null?void 0:platform$1.isElement(arrowOffsetParent)))&&(clientSize=elements.floating[clientProp]||rects.floating[length]);let centerToReference=endDiff/2-startDiff/2,largestPossiblePadding=clientSize/2-arrowDimensions[length]/2-1,minPadding=min(paddingObject[minProp],largestPossiblePadding),maxPadding=min(paddingObject[maxProp],largestPossiblePadding),min$1=minPadding,max$1=clientSize-arrowDimensions[length]-maxPadding,center=clientSize/2-arrowDimensions[length]/2+centerToReference,offset$2=clamp$1(min$1,center,max$1),shouldAddOffset=!middlewareData.arrow&&getAlignment(placement)!=null&¢er!==offset$2&&rects.reference[length]/2-(centerside$1<=0)){var _middlewareData$flip2,_overflowsData$filter;let nextIndex=(middlewareData.flip?.index||0)+1,nextPlacement=placements$1[nextIndex];if(nextPlacement&&(!(checkCrossAxis===`alignment`&&initialSideAxis!==getSideAxis(nextPlacement))||overflowsData.every(d=>getSideAxis(d.placement)===initialSideAxis?d.overflows[0]>0:!0)))return{data:{index:nextIndex,overflows:overflowsData},reset:{placement:nextPlacement}};let resetPlacement=overflowsData.filter(d=>d.overflows[0]<=0).sort((a$1,b)=>a$1.overflows[1]-b.overflows[1])[0]?.placement;if(!resetPlacement)switch(fallbackStrategy){case`bestFit`:{var _overflowsData$filter2;let placement$1=overflowsData.filter(d=>{if(hasFallbackAxisSideDirection){let currentSideAxis=getSideAxis(d.placement);return currentSideAxis===initialSideAxis||currentSideAxis===`y`}return!0}).map(d=>[d.placement,d.overflows.filter(overflow$1=>overflow$1>0).reduce((acc,overflow$1)=>acc+overflow$1,0)]).sort((a$1,b)=>a$1[1]-b[1])[0]?.[0];placement$1&&(resetPlacement=placement$1);break}case`initialPlacement`:resetPlacement=initialPlacement;break}if(placement!==resetPlacement)return{reset:{placement:resetPlacement}}}return{}}}},originSides=new Set([`left`,`top`]);async function convertValueToCoords(state,options){let{placement,platform:platform$1,elements}=state,rtl=await(platform$1.isRTL==null?void 0:platform$1.isRTL(elements.floating)),side=getSide(placement),alignment=getAlignment(placement),isVertical=getSideAxis(placement)===`y`,mainAxisMulti=originSides.has(side)?-1:1,crossAxisMulti=rtl&&isVertical?-1:1,rawValue=evaluate(options,state),{mainAxis,crossAxis,alignmentAxis}=typeof rawValue==`number`?{mainAxis:rawValue,crossAxis:0,alignmentAxis:null}:{mainAxis:rawValue.mainAxis||0,crossAxis:rawValue.crossAxis||0,alignmentAxis:rawValue.alignmentAxis};return alignment&&typeof alignmentAxis==`number`&&(crossAxis=alignment===`end`?alignmentAxis*-1:alignmentAxis),isVertical?{x:crossAxis*crossAxisMulti,y:mainAxis*mainAxisMulti}:{x:mainAxis*mainAxisMulti,y:crossAxis*crossAxisMulti}}var offset$1=function(options){return options===void 0&&(options=0),{name:`offset`,options,async fn(state){var _middlewareData$offse,_middlewareData$arrow;let{x,y,placement,middlewareData}=state,diffCoords=await convertValueToCoords(state,options);return placement===middlewareData.offset?.placement&&(_middlewareData$arrow=middlewareData.arrow)!=null&&_middlewareData$arrow.alignmentOffset?{}:{x:x+diffCoords.x,y:y+diffCoords.y,data:{...diffCoords,placement}}}}},shift$1=function(options){return options===void 0&&(options={}),{name:`shift`,options,async fn(state){let{x,y,placement}=state,{mainAxis:checkMainAxis=!0,crossAxis:checkCrossAxis=!1,limiter={fn:_ref=>{let{x:x$1,y:y$1}=_ref;return{x:x$1,y:y$1}}},...detectOverflowOptions}=evaluate(options,state),coords={x,y},overflow=await detectOverflow$1(state,detectOverflowOptions),crossAxis=getSideAxis(getSide(placement)),mainAxis=getOppositeAxis(crossAxis),mainAxisCoord=coords[mainAxis],crossAxisCoord=coords[crossAxis];if(checkMainAxis){let minSide=mainAxis===`y`?`top`:`left`,maxSide=mainAxis===`y`?`bottom`:`right`,min$1=mainAxisCoord+overflow[minSide],max$1=mainAxisCoord-overflow[maxSide];mainAxisCoord=clamp$1(min$1,mainAxisCoord,max$1)}if(checkCrossAxis){let minSide=crossAxis===`y`?`top`:`left`,maxSide=crossAxis===`y`?`bottom`:`right`,min$1=crossAxisCoord+overflow[minSide],max$1=crossAxisCoord-overflow[maxSide];crossAxisCoord=clamp$1(min$1,crossAxisCoord,max$1)}let limitedCoords=limiter.fn({...state,[mainAxis]:mainAxisCoord,[crossAxis]:crossAxisCoord});return{...limitedCoords,data:{x:limitedCoords.x-x,y:limitedCoords.y-y,enabled:{[mainAxis]:checkMainAxis,[crossAxis]:checkCrossAxis}}}}}};function hasWindow(){return typeof window<`u`}function getNodeName(node){return isNode(node)?(node.nodeName||``).toLowerCase():`#document`}function getWindow(node){var _node$ownerDocument;return(node==null||(_node$ownerDocument=node.ownerDocument)==null?void 0:_node$ownerDocument.defaultView)||window}function getDocumentElement(node){var _ref;return((isNode(node)?node.ownerDocument:node.document)||window.document)?.documentElement}function isNode(value){return hasWindow()?value instanceof Node||value instanceof getWindow(value).Node:!1}function isElement(value){return hasWindow()?value instanceof Element||value instanceof getWindow(value).Element:!1}function isHTMLElement(value){return hasWindow()?value instanceof HTMLElement||value instanceof getWindow(value).HTMLElement:!1}function isShadowRoot(value){return!hasWindow()||typeof ShadowRoot>`u`?!1:value instanceof ShadowRoot||value instanceof getWindow(value).ShadowRoot}var invalidOverflowDisplayValues=new Set([`inline`,`contents`]);function isOverflowElement(element){let{overflow,overflowX,overflowY,display}=getComputedStyle$1(element);return/auto|scroll|overlay|hidden|clip/.test(overflow+overflowY+overflowX)&&!invalidOverflowDisplayValues.has(display)}var tableElements=new Set([`table`,`td`,`th`]);function isTableElement(element){return tableElements.has(getNodeName(element))}var topLayerSelectors=[`:popover-open`,`:modal`];function isTopLayer(element){return topLayerSelectors.some(selector=>{try{return element.matches(selector)}catch{return!1}})}var transformProperties=[`transform`,`translate`,`scale`,`rotate`,`perspective`],willChangeValues=[`transform`,`translate`,`scale`,`rotate`,`perspective`,`filter`],containValues=[`paint`,`layout`,`strict`,`content`];function isContainingBlock(elementOrCss){let webkit=isWebKit(),css=isElement(elementOrCss)?getComputedStyle$1(elementOrCss):elementOrCss;return transformProperties.some(value=>css[value]?css[value]!==`none`:!1)||(css.containerType?css.containerType!==`normal`:!1)||!webkit&&(css.backdropFilter?css.backdropFilter!==`none`:!1)||!webkit&&(css.filter?css.filter!==`none`:!1)||willChangeValues.some(value=>(css.willChange||``).includes(value))||containValues.some(value=>(css.contain||``).includes(value))}function getContainingBlock(element){let currentNode=getParentNode(element);for(;isHTMLElement(currentNode)&&!isLastTraversableNode(currentNode);){if(isContainingBlock(currentNode))return currentNode;if(isTopLayer(currentNode))return null;currentNode=getParentNode(currentNode)}return null}function isWebKit(){return typeof CSS>`u`||!CSS.supports?!1:CSS.supports(`-webkit-backdrop-filter`,`none`)}var lastTraversableNodeNames=new Set([`html`,`body`,`#document`]);function isLastTraversableNode(node){return lastTraversableNodeNames.has(getNodeName(node))}function getComputedStyle$1(element){return getWindow(element).getComputedStyle(element)}function getNodeScroll(element){return isElement(element)?{scrollLeft:element.scrollLeft,scrollTop:element.scrollTop}:{scrollLeft:element.scrollX,scrollTop:element.scrollY}}function getParentNode(node){if(getNodeName(node)===`html`)return node;let result=node.assignedSlot||node.parentNode||isShadowRoot(node)&&node.host||getDocumentElement(node);return isShadowRoot(result)?result.host:result}function getNearestOverflowAncestor(node){let parentNode=getParentNode(node);return isLastTraversableNode(parentNode)?node.ownerDocument?node.ownerDocument.body:node.body:isHTMLElement(parentNode)&&isOverflowElement(parentNode)?parentNode:getNearestOverflowAncestor(parentNode)}function getOverflowAncestors(node,list,traverseIframes){var _node$ownerDocument2;list===void 0&&(list=[]),traverseIframes===void 0&&(traverseIframes=!0);let scrollableAncestor=getNearestOverflowAncestor(node),isBody=scrollableAncestor===node.ownerDocument?.body,win=getWindow(scrollableAncestor);if(isBody){let frameElement=getFrameElement(win);return list.concat(win,win.visualViewport||[],isOverflowElement(scrollableAncestor)?scrollableAncestor:[],frameElement&&traverseIframes?getOverflowAncestors(frameElement):[])}return list.concat(scrollableAncestor,getOverflowAncestors(scrollableAncestor,[],traverseIframes))}function getFrameElement(win){return win.parent&&Object.getPrototypeOf(win.parent)?win.frameElement:null}function getCssDimensions(element){let css=getComputedStyle$1(element),width$1=parseFloat(css.width)||0,height$1=parseFloat(css.height)||0,hasOffset=isHTMLElement(element),offsetWidth=hasOffset?element.offsetWidth:width$1,offsetHeight=hasOffset?element.offsetHeight:height$1,shouldFallback=round$1(width$1)!==offsetWidth||round$1(height$1)!==offsetHeight;return shouldFallback&&(width$1=offsetWidth,height$1=offsetHeight),{width:width$1,height:height$1,$:shouldFallback}}function unwrapElement$1(element){return isElement(element)?element:element.contextElement}function getScale(element){let domElement=unwrapElement$1(element);if(!isHTMLElement(domElement))return createCoords(1);let rect=domElement.getBoundingClientRect(),{width:width$1,height:height$1,$}=getCssDimensions(domElement),x=($?round$1(rect.width):rect.width)/width$1,y=($?round$1(rect.height):rect.height)/height$1;return(!x||!Number.isFinite(x))&&(x=1),(!y||!Number.isFinite(y))&&(y=1),{x,y}}var noOffsets=createCoords(0);function getVisualOffsets(element){let win=getWindow(element);return!isWebKit()||!win.visualViewport?noOffsets:{x:win.visualViewport.offsetLeft,y:win.visualViewport.offsetTop}}function shouldAddVisualOffsets(element,isFixed,floatingOffsetParent){return isFixed===void 0&&(isFixed=!1),!floatingOffsetParent||isFixed&&floatingOffsetParent!==getWindow(element)?!1:isFixed}function getBoundingClientRect(element,includeScale,isFixedStrategy,offsetParent){includeScale===void 0&&(includeScale=!1),isFixedStrategy===void 0&&(isFixedStrategy=!1);let clientRect=element.getBoundingClientRect(),domElement=unwrapElement$1(element),scale=createCoords(1);includeScale&&(offsetParent?isElement(offsetParent)&&(scale=getScale(offsetParent)):scale=getScale(element));let visualOffsets=shouldAddVisualOffsets(domElement,isFixedStrategy,offsetParent)?getVisualOffsets(domElement):createCoords(0),x=(clientRect.left+visualOffsets.x)/scale.x,y=(clientRect.top+visualOffsets.y)/scale.y,width$1=clientRect.width/scale.x,height$1=clientRect.height/scale.y;if(domElement){let win=getWindow(domElement),offsetWin=offsetParent&&isElement(offsetParent)?getWindow(offsetParent):offsetParent,currentWin=win,currentIFrame=getFrameElement(currentWin);for(;currentIFrame&&offsetParent&&offsetWin!==currentWin;){let iframeScale=getScale(currentIFrame),iframeRect=currentIFrame.getBoundingClientRect(),css=getComputedStyle$1(currentIFrame),left=iframeRect.left+(currentIFrame.clientLeft+parseFloat(css.paddingLeft))*iframeScale.x,top=iframeRect.top+(currentIFrame.clientTop+parseFloat(css.paddingTop))*iframeScale.y;x*=iframeScale.x,y*=iframeScale.y,width$1*=iframeScale.x,height$1*=iframeScale.y,x+=left,y+=top,currentWin=getWindow(currentIFrame),currentIFrame=getFrameElement(currentWin)}}return rectToClientRect({width:width$1,height:height$1,x,y})}function getWindowScrollBarX(element,rect){let leftScroll=getNodeScroll(element).scrollLeft;return rect?rect.left+leftScroll:getBoundingClientRect(getDocumentElement(element)).left+leftScroll}function getHTMLOffset(documentElement,scroll$1){let htmlRect=documentElement.getBoundingClientRect();return{x:htmlRect.left+scroll$1.scrollLeft-getWindowScrollBarX(documentElement,htmlRect),y:htmlRect.top+scroll$1.scrollTop}}function convertOffsetParentRelativeRectToViewportRelativeRect(_ref){let{elements,rect,offsetParent,strategy}=_ref,isFixed=strategy===`fixed`,documentElement=getDocumentElement(offsetParent),topLayer=elements?isTopLayer(elements.floating):!1;if(offsetParent===documentElement||topLayer&&isFixed)return rect;let scroll$1={scrollLeft:0,scrollTop:0},scale=createCoords(1),offsets=createCoords(0),isOffsetParentAnElement=isHTMLElement(offsetParent);if((isOffsetParentAnElement||!isOffsetParentAnElement&&!isFixed)&&((getNodeName(offsetParent)!==`body`||isOverflowElement(documentElement))&&(scroll$1=getNodeScroll(offsetParent)),isHTMLElement(offsetParent))){let offsetRect=getBoundingClientRect(offsetParent);scale=getScale(offsetParent),offsets.x=offsetRect.x+offsetParent.clientLeft,offsets.y=offsetRect.y+offsetParent.clientTop}let htmlOffset=documentElement&&!isOffsetParentAnElement&&!isFixed?getHTMLOffset(documentElement,scroll$1):createCoords(0);return{width:rect.width*scale.x,height:rect.height*scale.y,x:rect.x*scale.x-scroll$1.scrollLeft*scale.x+offsets.x+htmlOffset.x,y:rect.y*scale.y-scroll$1.scrollTop*scale.y+offsets.y+htmlOffset.y}}function getClientRects(element){return Array.from(element.getClientRects())}function getDocumentRect(element){let html=getDocumentElement(element),scroll$1=getNodeScroll(element),body=element.ownerDocument.body,width$1=max(html.scrollWidth,html.clientWidth,body.scrollWidth,body.clientWidth),height$1=max(html.scrollHeight,html.clientHeight,body.scrollHeight,body.clientHeight),x=-scroll$1.scrollLeft+getWindowScrollBarX(element),y=-scroll$1.scrollTop;return getComputedStyle$1(body).direction===`rtl`&&(x+=max(html.clientWidth,body.clientWidth)-width$1),{width:width$1,height:height$1,x,y}}var SCROLLBAR_MAX=25;function getViewportRect(element,strategy){let win=getWindow(element),html=getDocumentElement(element),visualViewport=win.visualViewport,width$1=html.clientWidth,height$1=html.clientHeight,x=0,y=0;if(visualViewport){width$1=visualViewport.width,height$1=visualViewport.height;let visualViewportBased=isWebKit();(!visualViewportBased||visualViewportBased&&strategy===`fixed`)&&(x=visualViewport.offsetLeft,y=visualViewport.offsetTop)}let windowScrollbarX=getWindowScrollBarX(html);if(windowScrollbarX<=0){let doc$1=html.ownerDocument,body=doc$1.body,bodyStyles=getComputedStyle(body),bodyMarginInline=doc$1.compatMode===`CSS1Compat`&&parseFloat(bodyStyles.marginLeft)+parseFloat(bodyStyles.marginRight)||0,clippingStableScrollbarWidth=Math.abs(html.clientWidth-body.clientWidth-bodyMarginInline);clippingStableScrollbarWidth<=SCROLLBAR_MAX&&(width$1-=clippingStableScrollbarWidth)}else windowScrollbarX<=SCROLLBAR_MAX&&(width$1+=windowScrollbarX);return{width:width$1,height:height$1,x,y}}var absoluteOrFixed=new Set([`absolute`,`fixed`]);function getInnerBoundingClientRect(element,strategy){let clientRect=getBoundingClientRect(element,!0,strategy===`fixed`),top=clientRect.top+element.clientTop,left=clientRect.left+element.clientLeft,scale=isHTMLElement(element)?getScale(element):createCoords(1);return{width:element.clientWidth*scale.x,height:element.clientHeight*scale.y,x:left*scale.x,y:top*scale.y}}function getClientRectFromClippingAncestor(element,clippingAncestor,strategy){let rect;if(clippingAncestor===`viewport`)rect=getViewportRect(element,strategy);else if(clippingAncestor===`document`)rect=getDocumentRect(getDocumentElement(element));else if(isElement(clippingAncestor))rect=getInnerBoundingClientRect(clippingAncestor,strategy);else{let visualOffsets=getVisualOffsets(element);rect={x:clippingAncestor.x-visualOffsets.x,y:clippingAncestor.y-visualOffsets.y,width:clippingAncestor.width,height:clippingAncestor.height}}return rectToClientRect(rect)}function hasFixedPositionAncestor(element,stopNode){let parentNode=getParentNode(element);return parentNode===stopNode||!isElement(parentNode)||isLastTraversableNode(parentNode)?!1:getComputedStyle$1(parentNode).position===`fixed`||hasFixedPositionAncestor(parentNode,stopNode)}function getClippingElementAncestors(element,cache$1){let cachedResult=cache$1.get(element);if(cachedResult)return cachedResult;let result=getOverflowAncestors(element,[],!1).filter(el=>isElement(el)&&getNodeName(el)!==`body`),currentContainingBlockComputedStyle=null,elementIsFixed=getComputedStyle$1(element).position===`fixed`,currentNode=elementIsFixed?getParentNode(element):element;for(;isElement(currentNode)&&!isLastTraversableNode(currentNode);){let computedStyle=getComputedStyle$1(currentNode),currentNodeIsContaining=isContainingBlock(currentNode);!currentNodeIsContaining&&computedStyle.position===`fixed`&&(currentContainingBlockComputedStyle=null),(elementIsFixed?!currentNodeIsContaining&&!currentContainingBlockComputedStyle:!currentNodeIsContaining&&computedStyle.position===`static`&¤tContainingBlockComputedStyle&&absoluteOrFixed.has(currentContainingBlockComputedStyle.position)||isOverflowElement(currentNode)&&!currentNodeIsContaining&&hasFixedPositionAncestor(element,currentNode))?result=result.filter(ancestor=>ancestor!==currentNode):currentContainingBlockComputedStyle=computedStyle,currentNode=getParentNode(currentNode)}return cache$1.set(element,result),result}function getClippingRect(_ref){let{element,boundary,rootBoundary,strategy}=_ref,clippingAncestors=[...boundary===`clippingAncestors`?isTopLayer(element)?[]:getClippingElementAncestors(element,this._c):[].concat(boundary),rootBoundary],firstClippingAncestor=clippingAncestors[0],clippingRect=clippingAncestors.reduce((accRect,clippingAncestor)=>{let rect=getClientRectFromClippingAncestor(element,clippingAncestor,strategy);return accRect.top=max(rect.top,accRect.top),accRect.right=min(rect.right,accRect.right),accRect.bottom=min(rect.bottom,accRect.bottom),accRect.left=max(rect.left,accRect.left),accRect},getClientRectFromClippingAncestor(element,firstClippingAncestor,strategy));return{width:clippingRect.right-clippingRect.left,height:clippingRect.bottom-clippingRect.top,x:clippingRect.left,y:clippingRect.top}}function getDimensions(element){let{width:width$1,height:height$1}=getCssDimensions(element);return{width:width$1,height:height$1}}function getRectRelativeToOffsetParent(element,offsetParent,strategy){let isOffsetParentAnElement=isHTMLElement(offsetParent),documentElement=getDocumentElement(offsetParent),isFixed=strategy===`fixed`,rect=getBoundingClientRect(element,!0,isFixed,offsetParent),scroll$1={scrollLeft:0,scrollTop:0},offsets=createCoords(0);function setLeftRTLScrollbarOffset(){offsets.x=getWindowScrollBarX(documentElement)}if(isOffsetParentAnElement||!isOffsetParentAnElement&&!isFixed)if((getNodeName(offsetParent)!==`body`||isOverflowElement(documentElement))&&(scroll$1=getNodeScroll(offsetParent)),isOffsetParentAnElement){let offsetRect=getBoundingClientRect(offsetParent,!0,isFixed,offsetParent);offsets.x=offsetRect.x+offsetParent.clientLeft,offsets.y=offsetRect.y+offsetParent.clientTop}else documentElement&&setLeftRTLScrollbarOffset();isFixed&&!isOffsetParentAnElement&&documentElement&&setLeftRTLScrollbarOffset();let htmlOffset=documentElement&&!isOffsetParentAnElement&&!isFixed?getHTMLOffset(documentElement,scroll$1):createCoords(0);return{x:rect.left+scroll$1.scrollLeft-offsets.x-htmlOffset.x,y:rect.top+scroll$1.scrollTop-offsets.y-htmlOffset.y,width:rect.width,height:rect.height}}function isStaticPositioned(element){return getComputedStyle$1(element).position===`static`}function getTrueOffsetParent(element,polyfill){if(!isHTMLElement(element)||getComputedStyle$1(element).position===`fixed`)return null;if(polyfill)return polyfill(element);let rawOffsetParent=element.offsetParent;return getDocumentElement(element)===rawOffsetParent&&(rawOffsetParent=rawOffsetParent.ownerDocument.body),rawOffsetParent}function getOffsetParent(element,polyfill){let win=getWindow(element);if(isTopLayer(element))return win;if(!isHTMLElement(element)){let svgOffsetParent=getParentNode(element);for(;svgOffsetParent&&!isLastTraversableNode(svgOffsetParent);){if(isElement(svgOffsetParent)&&!isStaticPositioned(svgOffsetParent))return svgOffsetParent;svgOffsetParent=getParentNode(svgOffsetParent)}return win}let offsetParent=getTrueOffsetParent(element,polyfill);for(;offsetParent&&isTableElement(offsetParent)&&isStaticPositioned(offsetParent);)offsetParent=getTrueOffsetParent(offsetParent,polyfill);return offsetParent&&isLastTraversableNode(offsetParent)&&isStaticPositioned(offsetParent)&&!isContainingBlock(offsetParent)?win:offsetParent||getContainingBlock(element)||win}var getElementRects=async function(data){let getOffsetParentFn=this.getOffsetParent||getOffsetParent,getDimensionsFn=this.getDimensions,floatingDimensions=await getDimensionsFn(data.floating);return{reference:getRectRelativeToOffsetParent(data.reference,await getOffsetParentFn(data.floating),data.strategy),floating:{x:0,y:0,width:floatingDimensions.width,height:floatingDimensions.height}}};function isRTL(element){return getComputedStyle$1(element).direction===`rtl`}var platform={convertOffsetParentRelativeRectToViewportRelativeRect,getDocumentElement,getClippingRect,getOffsetParent,getElementRects,getClientRects,getDimensions,getScale,isElement,isRTL};function rectsAreEqual(a$1,b){return a$1.x===b.x&&a$1.y===b.y&&a$1.width===b.width&&a$1.height===b.height}function observeMove(element,onMove){let io=null,timeoutId,root=getDocumentElement(element);function cleanup(){var _io;clearTimeout(timeoutId),(_io=io)==null||_io.disconnect(),io=null}function refresh$1(skip,threshold){skip===void 0&&(skip=!1),threshold===void 0&&(threshold=1),cleanup();let elementRectForRootMargin=element.getBoundingClientRect(),{left,top,width:width$1,height:height$1}=elementRectForRootMargin;if(skip||onMove(),!width$1||!height$1)return;let insetTop=floor(top),insetRight=floor(root.clientWidth-(left+width$1)),insetBottom=floor(root.clientHeight-(top+height$1)),insetLeft=floor(left),options={rootMargin:-insetTop+`px `+-insetRight+`px `+-insetBottom+`px `+-insetLeft+`px`,threshold:max(0,min(1,threshold))||1},isFirstUpdate=!0;function handleObserve(entries){let ratio=entries[0].intersectionRatio;if(ratio!==threshold){if(!isFirstUpdate)return refresh$1();ratio?refresh$1(!1,ratio):timeoutId=setTimeout(()=>{refresh$1(!1,1e-7)},1e3)}ratio===1&&!rectsAreEqual(elementRectForRootMargin,element.getBoundingClientRect())&&refresh$1(),isFirstUpdate=!1}try{io=new IntersectionObserver(handleObserve,{...options,root:root.ownerDocument})}catch{io=new IntersectionObserver(handleObserve,options)}io.observe(element)}return refresh$1(!0),cleanup}function autoUpdate(reference,floating,update$6,options){options===void 0&&(options={});let{ancestorScroll=!0,ancestorResize=!0,elementResize=typeof ResizeObserver==`function`,layoutShift=typeof IntersectionObserver==`function`,animationFrame=!1}=options,referenceEl=unwrapElement$1(reference),ancestors=ancestorScroll||ancestorResize?[...referenceEl?getOverflowAncestors(referenceEl):[],...getOverflowAncestors(floating)]:[];ancestors.forEach(ancestor=>{ancestorScroll&&ancestor.addEventListener(`scroll`,update$6,{passive:!0}),ancestorResize&&ancestor.addEventListener(`resize`,update$6)});let cleanupIo=referenceEl&&layoutShift?observeMove(referenceEl,update$6):null,reobserveFrame=-1,resizeObserver=null;elementResize&&(resizeObserver=new ResizeObserver(_ref=>{let[firstEntry]=_ref;firstEntry&&firstEntry.target===referenceEl&&resizeObserver&&(resizeObserver.unobserve(floating),cancelAnimationFrame(reobserveFrame),reobserveFrame=requestAnimationFrame(()=>{var _resizeObserver;(_resizeObserver=resizeObserver)==null||_resizeObserver.observe(floating)})),update$6()}),referenceEl&&!animationFrame&&resizeObserver.observe(referenceEl),resizeObserver.observe(floating));let frameId,prevRefRect=animationFrame?getBoundingClientRect(reference):null;animationFrame&&frameLoop();function frameLoop(){let nextRefRect=getBoundingClientRect(reference);prevRefRect&&!rectsAreEqual(prevRefRect,nextRefRect)&&update$6(),prevRefRect=nextRefRect,frameId=requestAnimationFrame(frameLoop)}return update$6(),()=>{var _resizeObserver2;ancestors.forEach(ancestor=>{ancestorScroll&&ancestor.removeEventListener(`scroll`,update$6),ancestorResize&&ancestor.removeEventListener(`resize`,update$6)}),cleanupIo?.(),(_resizeObserver2=resizeObserver)==null||_resizeObserver2.disconnect(),resizeObserver=null,animationFrame&&cancelAnimationFrame(frameId)}}var offset=offset$1,shift=shift$1,flip=flip$1,arrow$1=arrow$2,computePosition=(reference,floating,options)=>{let cache$1=new Map,mergedOptions={platform,...options},platformWithCache={...mergedOptions.platform,_c:cache$1};return computePosition$1(reference,floating,{...mergedOptions,platform:platformWithCache})};function isComponentPublicInstance(target){return typeof target==`object`&&!!target&&`$el`in target}function unwrapElement(target){if(isComponentPublicInstance(target)){let element=target.$el;return isNode(element)&&getNodeName(element)===`#comment`?null:element}return target}function toValue(source){return typeof source==`function`?source():unref(source)}function arrow(options){return{name:`arrow`,options,fn(args){let element=unwrapElement(toValue(options.element));return element==null?{}:arrow$1({element,padding:options.padding}).fn(args)}}}function getDPR(element){return typeof window>`u`?1:(element.ownerDocument.defaultView||window).devicePixelRatio||1}function roundByDPR(element,value){let dpr=getDPR(element);return Math.round(value*dpr)/dpr}function useFloating(reference,floating,options){options===void 0&&(options={});let whileElementsMountedOption=options.whileElementsMounted,openOption=computed(()=>{var _toValue;return toValue(options.open)??!0}),middlewareOption=computed(()=>toValue(options.middleware)),placementOption=computed(()=>{var _toValue2;return toValue(options.placement)??`bottom`}),strategyOption=computed(()=>{var _toValue3;return toValue(options.strategy)??`absolute`}),transformOption=computed(()=>{var _toValue4;return toValue(options.transform)??!0}),referenceElement=computed(()=>unwrapElement(reference.value)),floatingElement=computed(()=>unwrapElement(floating.value)),x=ref(0),y=ref(0),strategy=ref(strategyOption.value),placement=ref(placementOption.value),middlewareData=shallowRef({}),isPositioned=ref(!1),floatingStyles=computed(()=>{let initialStyles={position:strategy.value,left:`0`,top:`0`};if(!floatingElement.value)return initialStyles;let xVal=roundByDPR(floatingElement.value,x.value),yVal=roundByDPR(floatingElement.value,y.value);return transformOption.value?{...initialStyles,transform:`translate(`+xVal+`px, `+yVal+`px)`,...getDPR(floatingElement.value)>=1.5&&{willChange:`transform`}}:{position:strategy.value,left:xVal+`px`,top:yVal+`px`}}),whileElementsMountedCleanup;function update$6(){if(referenceElement.value==null||floatingElement.value==null)return;let open$1=openOption.value;computePosition(referenceElement.value,floatingElement.value,{middleware:middlewareOption.value,placement:placementOption.value,strategy:strategyOption.value}).then(position=>{x.value=position.x,y.value=position.y,strategy.value=position.strategy,placement.value=position.placement,middlewareData.value=position.middlewareData,isPositioned.value=open$1!==!1})}function cleanup(){typeof whileElementsMountedCleanup==`function`&&(whileElementsMountedCleanup(),whileElementsMountedCleanup=void 0)}function attach(){if(cleanup(),whileElementsMountedOption===void 0){update$6();return}if(referenceElement.value!=null&&floatingElement.value!=null){whileElementsMountedCleanup=whileElementsMountedOption(referenceElement.value,floatingElement.value,update$6);return}}function reset$1(){openOption.value||(isPositioned.value=!1)}return watch([middlewareOption,placementOption,strategyOption,openOption],update$6,{flush:`sync`}),watch([referenceElement,floatingElement],attach,{flush:`sync`}),watch(openOption,reset$1,{flush:`sync`}),getCurrentScope()&&onScopeDispose(cleanup),{x:shallowReadonly(x),y:shallowReadonly(y),strategy:shallowReadonly(strategy),placement:shallowReadonly(placement),middlewareData:shallowReadonly(middlewareData),isPositioned:shallowReadonly(isPositioned),floatingStyles,update:update$6}}var ARROW_POSITION={top:`bottom`,right:`left`,bottom:`top`,left:`right`};const usePopover=defineStore(`popover`,()=>{let _counter=ref(0),_currentPopover=ref(null),popovers=ref({}),currentPopover=computed(()=>_currentPopover.value),register=(name,popover,popoverPlacement=void 0,options={})=>{if(popovers.value[name])return;popovers.value[name]={element:popover,target:null,placement:popoverPlacement||`bottom`,show:!1};let popoverInstance=buildPopover(popover,toRef(popovers.value[name],`target`),toRef(popovers.value[name],`placement`),options),scope$1=effectScope(),show$1;scope$1.run(()=>{show$1=computed(()=>popovers.value[name].show)});let dispose$2=()=>{scope$1.stop(),popoverInstance.dispose()};return popovers.value[name].dispose=dispose$2,_counter.value++,{show:show$1,update:popoverInstance.update,placement:popoverInstance.placement}},bind=(popoverName,el,options)=>{let scope$1=effectScope(),hidden,isBound,popoverElement;scope$1.run(()=>{hidden=computed(()=>popovers.value[popoverName]?!popovers.value[popoverName].show:void 0),isBound=computed(()=>popovers.value[popoverName]?popovers.value[popoverName].target===el:void 0),popoverElement=computed(()=>popovers.value[popoverName]?popovers.value[popoverName].element:void 0)});let show$1=()=>{isBound.value||(popovers.value[popoverName].target=el,popovers.value[popoverName].placement=options.placement),popovers.value[popoverName].show=!0},hide$3=()=>{isBound.value&&(popovers.value[popoverName].show=!1)};return{popoverElement,hidden,isBound,show:show$1,hide:hide$3,toggle:(forceValue=void 0)=>{let doShow=forceValue;typeof doShow!=`boolean`&&(doShow=!isBound.value||!popovers.value[popoverName].show),doShow?show$1():hide$3()},isShown:()=>!!popovers.value[popoverName].show,unbind:()=>{scope$1.stop()}}},unregister=name=>{popovers.value[name]&&(popovers.value[name].dispose(),delete popovers.value[name])},isShown=name=>name in popovers.value?popovers.value[name].show:!1,show=(name,target)=>{name in popovers.value&&(popovers.value[name].show=!0,target&&(popovers.value[name].target=target),_currentPopover.value=popovers.value[name])},hide$2=name=>{name in popovers.value&&(popovers.value[name].show=!1,_currentPopover.value=null)};return{popovers,currentPopover,bind,register,unregister,isShown,show,hide:hide$2,toggle:(name,forceValue=void 0)=>{name in popovers.value&&(popovers.value[name].show=typeof forceValue==`boolean`?forceValue:!popovers.value[name].show,_currentPopover.value=popovers.value[name].show?popovers.value[name]:null)},hideAll:(startsWith=void 0)=>{let keys=Object.keys(popovers.value);startsWith&&(keys=keys.filter(name=>name.startsWith(startsWith))),keys.forEach(name=>popovers.value[name].show&&hide$2(name))},getPopover:name=>popovers.value[name],counter:computed(()=>_counter.value)}});function buildPopover(popover,reference,placementArg,options){let{floatingStyles,middlewareData,update:update$6,placement}=useFloating(reference,popover,{placement:placementArg,middleware:buildMiddleware(popover,options),whileElementsMounted:autoUpdate}),watchers$1=[];return watchers$1.push(watch(floatingStyles,async styles=>{popover.value&&await nextTick(()=>{Object.keys(styles).forEach(styleName=>popover.value.style[styleName]=styles[styleName])})})),options.arrow&&watchers$1.push(watch(middlewareData,async middlewareData$1=>{let left=middlewareData$1.arrow&&middlewareData$1.arrow.x!=null?`${middlewareData$1.arrow.x}px`:``,top=middlewareData$1.arrow&&middlewareData$1.arrow.y!=null?`${middlewareData$1.arrow.y}px`:``,arrowSide=ARROW_POSITION[middlewareData$1.offset.placement.split(`-`)[0]];await nextTick(()=>{applyStyles(options.arrow.value,{left,top,right:``,bottom:``,[arrowSide]:`-${options.arrow.value.offsetWidth/2}px`})})})),{placement,update:update$6,dispose:()=>{watchers$1.forEach(unwatch=>unwatch())}}}var arrowOffset=options=>({name:`arrowOffset`,options,fn({...state}){let arrOffset=Math.sqrt(2*options.element.value.offsetWidth**2)/2,side=state.placement.startsWith(`left`)||state.placement.startsWith(`top`)?-1:1;if(state.placement.startsWith(`left`)||state.placement.startsWith(`right`))return{x:state.x+side*arrOffset};if(state.placement.startsWith(`top`)||state.placement.startsWith(`bottom`))return{y:state.y+side*arrOffset}}});function buildMiddleware(popover,options){let middleware=[flip(),shift()],offsetValue=options.offset||0;return middleware.push(offset(offsetValue)),options.arrow&&(middleware.push(arrowOffset({element:options.arrow})),middleware.push(arrow({element:options.arrow}))),middleware}function applyStyles(el,styles){Object.keys(styles).forEach(styleName=>el.style[styleName]=styles[styleName])}var HOVER_SHOW_EVENTS=[`mouseover`,`focus`],HOVER_HIDE_EVENTS=[`mouseleave`,`blur`],TOGGLE_EVENTS=[`click`],BngPopover_default={mounted:setup$1,updated:setup$1,onBeforeUnmount:dispose};function setup$1(el,binding){dispose(el),binding.value&&(setPopoverProperties(el,binding),bindPopover(el),attachListeners(el,binding.modifiers))}function dispose(el){el.__popover&&(el.__popover.unregister&&el.__popover.unbind(),removeListeners(el))}function attachListeners(el,modifiers){el.__popover.showHandler=event=>{el.contains(event.target)&&el.__popover.show()},el.__popover.hideHandler=event=>{el.contains(event.relatedTarget)||el.__popover.hide()},el.__popover.toggleHandler=event=>{el.contains(event.target)&&el.__popover.toggle()},el.__popover.clickOutside=event=>{!el.contains(event.target)&&(!el.__popover.element.value||!el.__popover.element.value.contains(event.target))&&el.__popover.hide()},modifiers.click?(TOGGLE_EVENTS.forEach(eventName=>{el.addEventListener(eventName,el.__popover.toggleHandler)}),TOGGLE_EVENTS.forEach(eventName=>{window.addEventListener(eventName,el.__popover.clickOutside)})):(HOVER_SHOW_EVENTS.forEach(eventName=>el.addEventListener(eventName,el.__popover.showHandler)),HOVER_HIDE_EVENTS.forEach(eventName=>el.addEventListener(eventName,el.__popover.hideHandler)))}function removeListeners(el){el.__popover.toggleHandler&&(TOGGLE_EVENTS.forEach(eventName=>{el.removeEventListener(eventName,el.__popover.toggleHandler)}),TOGGLE_EVENTS.forEach(eventName=>{window.removeEventListener(eventName,el.__popover.clickOutside)})),el.__popover.showHandler&&HOVER_SHOW_EVENTS.forEach(eventName=>el.removeEventListener(eventName,el.__popover.showHandler)),el.__popover.hideHandler&&HOVER_SHOW_EVENTS.forEach(eventName=>el.removeEventListener(eventName,el.__popover.hideHandler))}function bindPopover(el){let popoverBind=usePopover().bind(el.__popover.name,el,getOptions$1(el));Object.assign(el.__popover,{toggle:popoverBind.toggle,show:popoverBind.show,isShown:popoverBind.isShown,hide:popoverBind.hide,toggle:popoverBind.toggle,hidden:popoverBind.hidden,element:popoverBind.popoverElement,unbind:popoverBind.unbind})}function setPopoverProperties(el,binding){el.__popover={name:getPopoverName(binding),placement:getPlacement(binding)}}var getOptions$1=el=>({placement:el.__popover.placement}),getPlacement=binding=>binding.arg?binding.arg:binding.placement?binding.placement:`left`,getPopoverName=binding=>typeof binding.value==`string`?binding.value:binding.value.name,TIMESPAN_TRANSLATE_ID_PREFIX=`ui.timespan.`,$t=i=>$translate.instant(TIMESPAN_TRANSLATE_ID_PREFIX+i),SECONDS_IN={year:3600*24*365,month:3600*24*30,week:3600*24*7,day:3600*24,hour:3600,minute:60,second:1},MINIMUM_SPAN=Object.entries(SECONDS_IN).slice(-1)[0][1],dateToEpoch=date=>date?typeof date==`string`?/^\d+$/.test(date)?+date:~~(new Date(date).getTime()/1e3):typeof date==`number`?date:0:0;const timeSpan=(date1,date2=null,length=2,useRelativeDescription=!1)=>{let res=`-`;if(date1=dateToEpoch(date1),!date1)return res;if(date2){if(date2=dateToEpoch(date2),!date2)return res}else date2=~~(new Date().getTime()/1e3);let diff,isFuture;return date1>=date2?(diff=date1-date2,isFuture=!0):(diff=date2-date1,isFuture=!1),res=formatTime(diff,length,useRelativeDescription,isFuture),res},formatTime=(seconds,length=2,useRelativeDescription=!1,future=!1)=>{let res=`-`;if(seconds20&&abs%10==1?abs+` `+$t(spanName+`.plural_1_pastfuture`):abs<=4||useRelativeDescription&&abs>20&&abs%10<=4?abs+` `+$t(spanName+`.plural_234`):abs+` `+$t(spanName+`.plural`),cur&&resArr.push(cur),length===1)break;length--,seconds%=spanSeconds}res=``;let resArrLen=resArr.length;return resArr.forEach((bit,i)=>{bit=bit.replace(` `,`\xA0`),i?(i===resArrLen-1?res+=` `+$t(`and`)+` `:res+=$t(`separator`)+` `,res+=bit):res+=ucaseFirst(bit)}),useRelativeDescription&&(res+=` `+$t(future?`future`:`past`)),res};var update=(element,{value})=>{let desc=timeSpan(value,null,1,!0);desc!==`-`&&(element.innerHTML=desc)},BngRelativeTime_default=update;const getScopeProperties=el=>{if(!(!el||!el.hasAttribute(`bng-ui-scope`)))return{scopeId:el.getAttribute(UI_SCOPE_ATTR$1),isScopedNav:el.hasAttribute(SCOPED_NAV_ATTR)}},findParentScope=(el,scopedNavOnly=!1)=>{let parent=el.parentElement;for(;parent;){let scopedNavId=parent.getAttribute(SCOPED_NAV_ATTR);if(scopedNavId)return{scopeId:scopedNavId,element:parent,isScopedNav:!0};if(!scopedNavOnly){let uiScopeId=parent.getAttribute(UI_SCOPE_ATTR$1);if(uiScopeId)return{scopeId:uiScopeId,element:parent,isScopedNav:!1}}parent=parent.parentElement}return null},isNavigable=el=>(!el.hasAttribute(`bng-no-nav`)||el.getAttribute(`bng-no-nav`)===`false`)&&(!el.hasAttribute(`disabled`)||el.getAttribute(`disabled`)===`false`),isDirectChild=(el,child)=>child.parentElement.closest(`[bng-scoped-nav]`)===el,getNavItems=(el,navigableOnly=!0)=>{let matches$1=el.querySelectorAll(NAVIGABLE_ELEMENTS_SELECTOR);return Array.from(matches$1).filter(child=>!isNavigable(child)&&navigableOnly?!1:isDirectChild(el,child))},getPassthroughEvents=el=>{let navItems=getNavItems(el,!1);if(navItems.length===0)return!1;let boundEvents=[];for(let elem of navItems){let uiNavEvents=elem.__BngOnUiNav?Object.values(elem.__BngOnUiNav).map(x=>x.eventNames).flat().filter(name=>!PASSTHROUGH_EXCLUDED_EVENTS.includes(name)):[],isDuplicate=uiNavEvents.some(event=>boundEvents.includes(event));if(uiNavEvents.length===0||isDuplicate){boundEvents=[];break}uiNavEvents.forEach(event=>{boundEvents.includes(event)||boundEvents.push(event)})}return boundEvents};var SCOPED_NAV_OBSERVER_EVENTS={onBeforeScopeActivated:`onBeforeScopeActivated`,onScopeActivated:`onScopeActivated`,onBeforeScopeDeactivated:`onBeforeScopeDeactivated`,onScopeDeactivated:`onScopeDeactivated`,onBeforeScopeSuspended:`onBeforeScopeSuspended`,onScopeSuspended:`onScopeSuspended`,onBeforeScopeResumed:`onBeforeScopeResumed`,onScopeResumed:`onScopeResumed`},scopedNavObservers={};function registerScopedNavObserver(id,observer$2){scopedNavObservers[id]=observer$2}function notifyScopedNavObservers(event,detail){Object.keys(scopedNavObservers).forEach(observerId=>{let callback=scopedNavObservers[observerId][event];if(callback&&typeof callback==`function`)try{callback(detail)}catch(error){logger_default.error(`Error in scoped nav observer ${observerId} for event ${event}`,error)}})}const useScopedNav=defineStore(`scopedNav2`,()=>{let scopeStack=ref([]),activateScope=(scopeId,element,options={activationType:SCOPED_NAV_STATES.active,suspendParentScopes:!1})=>{notifyScopedNavObservers(SCOPED_NAV_OBSERVER_EVENTS.onBeforeScopeActivated,{scopeId,element,options});let scopeIndex=scopeStack.value.findIndex(s=>s.scopeId===scopeId),existingScope=scopeIndex===-1?void 0:scopeStack.value[scopeIndex];if(existingScope&&existingScope.activationType===options.activationType){logger_default.warn(`Scope ${scopeId} already active. Ignoring...`),notifyScopedNavObservers(SCOPED_NAV_OBSERVER_EVENTS.onScopeActivated,{scopeId,element,options});return}existingScope?existingScope.activationType=options.activationType:(scopeStack.value.push({scopeId,element,...options}),scopeIndex=scopeStack.value.length-1),notifyScopedNavObservers(SCOPED_NAV_OBSERVER_EVENTS.onScopeActivated,{scopeId,element,options});let scopeData={scopeId,...options},{type}=element[SCOPED_NAV_PROPERTY_NAME];if(type===SCOPED_NAV_TYPES.popover||options.suspendParentScopes){let referenceElement=element;if(type===SCOPED_NAV_TYPES.popover){let popover=usePopover(),popoverName=element.getAttribute(`data-bng-popover-name`),pop=popover.getPopover(popoverName);pop&&pop.target&&(referenceElement=pop.target)}if(!referenceElement){logger_default.warn(`Unable to find popover's target element. Skipping suspending parent scopes...`);return}let parentScopes=scopeStack.value.slice(0,scopeIndex);for(let i=parentScopes.length-1;i>=0;i--){let scope$1=parentScopes[i];referenceElement&&scope$1.element.contains(referenceElement)?suspendScope(scope$1.scopeId,scopeData):referenceElement&&!scope$1.element.contains(referenceElement)&&deactivateScope(scope$1.scopeId)}}return getUINavServiceInstance().setActiveScope(scopeId),element.dispatchEvent(new CustomEvent(SCOPED_NAV_EVENTS.activate,{detail:scopeData})),scopeData},deactivateScope=(scopeId,settings$1={resumePrevious:!1})=>{let scopeIndex=scopeStack.value.findIndex(s=>s.scopeId===scopeId);if(scopeIndex===-1){logger_default.warn(`Scope ${scopeId} not found. Ignoring...`);return}notifyScopedNavObservers(SCOPED_NAV_OBSERVER_EVENTS.onBeforeScopeDeactivated,{scopeId,settings:settings$1});let scopeData=scopeStack.value[scopeIndex],element=scopeData.element,{type}=element[SCOPED_NAV_PROPERTY_NAME];if(scopeStack.value=scopeStack.value.slice(0,scopeIndex),element.dispatchEvent(new CustomEvent(SCOPED_NAV_EVENTS.deactivate,{detail:{scopeId,settings:settings$1,...scopeData}})),notifyScopedNavObservers(SCOPED_NAV_OBSERVER_EVENTS.onScopeDeactivated,{scopeId,settings:settings$1}),!settings$1.resumePrevious){getUINavServiceInstance().setActiveScope(null);return}let parentScope;if(type===SCOPED_NAV_TYPES.popover){let popover=usePopover(),popoverName=element.getAttribute(`data-bng-popover-name`),pop=popover.getPopover(popoverName);pop?parentScope=findParentScope(pop.target,!0):logger_default.warn(`Unable to find popover's target element. Skipping resume...`)}else parentScope=findParentScope(element,!0);parentScope?getScopeById(parentScope.scopeId)?resumeScope(parentScope.scopeId):activateScope(parentScope.scopeId,parentScope.element):getUINavServiceInstance().setActiveScope(null)},resumeScope=scopeId=>{let scopeIndex=scopeStack.value.findIndex(s=>s.scopeId===scopeId);if(scopeIndex===-1){logger_default.warn(`Scope ${scopeId} not found. Ignoring...`);return}notifyScopedNavObservers(SCOPED_NAV_OBSERVER_EVENTS.onBeforeScopeResumed,{scopeId});for(let i=scopeStack.value.length-1;i>scopeIndex;i--){let scope$1=scopeStack.value[i];deactivateScope(scope$1.scopeId)}let scopeData=scopeStack.value[scopeIndex];return scopeData.activationType=SCOPED_NAV_STATES.active,getUINavServiceInstance().setActiveScope(scopeData.scopeId),scopeData.element.dispatchEvent(new CustomEvent(SCOPED_NAV_EVENTS.resume,{detail:scopeData})),notifyScopedNavObservers(SCOPED_NAV_OBSERVER_EVENTS.onScopeResumed,{scopeId}),scopeData},suspendScope=(scopeId,newScope)=>{let scopeIndex=scopeStack.value.findIndex(s=>s.scopeId===scopeId);if(scopeIndex===-1){logger_default.warn(`Scope ${scopeId} not found. Ignoring...`);return}notifyScopedNavObservers(SCOPED_NAV_OBSERVER_EVENTS.onBeforeScopeSuspended,{scopeId,newScope});let scopeData=scopeStack.value[scopeIndex];if(scopeData.activationType===SCOPED_NAV_STATES.suspended){logger_default.warn(`Scope ${scopeId} already suspended. Ignoring...`);return}scopeData.activationType=SCOPED_NAV_STATES.suspended;let element=scopeData.element,payload={scopeId,newScope,...scopeData};return element.dispatchEvent(new CustomEvent(SCOPED_NAV_EVENTS.suspend,{detail:payload})),notifyScopedNavObservers(SCOPED_NAV_OBSERVER_EVENTS.onScopeSuspended,{scopeId,newScope}),scopeData},currentScope=()=>scopeStack.value[scopeStack.value.length-1],getScopeById=scopeId=>scopeStack.value.find(s=>s.scopeId===scopeId);return{activateScope,deactivateScope,resumeScope,suspendScope,getScopeById,currentScope,isCurrentScope:scopeId=>{let scope$1=currentScope();return scope$1&&scope$1.scopeId===scopeId},isActiveScope:scopeId=>{let current=currentScope();if(!current)return!1;if(current.scopeId===scopeId)return!0;if(current.activationType===SCOPED_NAV_STATES.partial&&scopeStack.value.length>2){let parentScope=scopeStack.value[scopeStack.value.length-2];if(parentScope.scopeId===scopeId&&parentScope.activationType===SCOPED_NAV_STATES.active)return!0}return!1},getScopes:()=>scopeStack.value}});var focusDebounceTimer=null,pendingFocusAction=null,focusListenersInitialized=!1,isActivatingScope=!1,isDeactivatingScope=!1,FOCUS_DEBOUNCE_TIME=200,focusManagerId=`focusManager`,clearFocusDebounce=()=>{focusDebounceTimer&&=(clearTimeout(focusDebounceTimer),null),pendingFocusAction=null},debouncedFocusAction=action=>{clearFocusDebounce(),pendingFocusAction=action,focusDebounceTimer=setTimeout(()=>{pendingFocusAction&&=(pendingFocusAction(),null),focusDebounceTimer=null},FOCUS_DEBOUNCE_TIME)};function useFocusManager(){let scopedNav=useScopedNav(),onUINavFocus=e=>{let{target,relatedTarget}=e.detail;if(isWithinDashmenu(target)||isWithinPopup(target))return;let targetScope=findParentScope(target,!0),scopeElement=targetScope&&targetScope.isScopedNav?targetScope.element:null,scopedNavProps=scopeElement&&scopeElement._bngScopedNav?scopeElement[SCOPED_NAV_PROPERTY_NAME]:null;if(scopedNavProps&&(scopeElement[SCOPED_NAV_PROPERTY_NAME].lastActiveElement=target),isActivatingScope||isDeactivatingScope||shouldSkipFocusHandling(scopedNavProps)){clearFocusDebounce();return}debouncedFocusAction(()=>handleFocusAction(target,targetScope,scopeElement,scopedNav))},onUINavBlur=e=>{let{target}=e.detail,scopeProperties=getScopeProperties(target);shouldHandleBlur(scopeProperties,scopedNav.currentScope())&&(target[SCOPED_NAV_PROPERTY_NAME].passthroughActive=!1,scopedNav.deactivateScope(scopeProperties.scopeId,{resumePrevious:!0}))};function addFocusListeners(){focusListenersInitialized||=(document.addEventListener(`uinav-focus`,onUINavFocus),document.addEventListener(`uinav-blur`,onUINavBlur),registerScopedNavObserver(focusManagerId,{onBeforeScopeActivated:()=>{clearFocusDebounce(),isActivatingScope=!0},onScopeActivated:()=>{clearFocusDebounce(),isActivatingScope=!1},onBeforeScopeDeactivated:()=>{clearFocusDebounce(),isDeactivatingScope=!0},onScopeDeactivated:()=>{clearFocusDebounce(),isDeactivatingScope=!1}}),!0)}function removeFocusListeners(){focusListenersInitialized&&=(document.removeEventListener(`uinav-focus`,onUINavFocus),document.removeEventListener(`uinav-blur`,onUINavBlur),!1)}function setup$3(){addFocusListeners()}function dispose$2(){removeFocusListeners()}return onMounted(()=>{setup$3()}),onBeforeUnmount(()=>{dispose$2()}),{setup:setup$3,dispose:dispose$2}}function isWithinDashmenu(target){return document.getElementById(`dashmenu`)?.contains(target)}function isWithinPopup(target){return!!target.closest(`dialog`)}function shouldSkipFocusHandling(scopedNavProps){return scopedNavProps?.type===SCOPED_NAV_TYPES.popover}function shouldHandleBlur(scopeProperties,currScope){return scopeProperties?.isScopedNav&&currScope?.scopeId===scopeProperties.scopeId&&currScope?.activationType===SCOPED_NAV_STATES.partial}function handleFocusAction(target,targetScope,scopeElement,scopedNavStore){if(!document.contains(target)&&!document.contains(scopeElement))return;let activeScope=scopedNavStore.currentScope();if(activeScope?.element===target)return;let existingScope,scopes=scopedNavStore.getScopes();for(let i=scopes.length-1;i>=0;i--){let scope$1=scopes[i];if(scope$1.element===scopeElement){existingScope=scope$1;break}}if(existingScope&&activeScope&&existingScope.scopeId!==activeScope.scopeId){scopedNavStore.resumeScope(existingScope.scopeId);return}scopes=scopedNavStore.getScopes();for(let i=scopes.length-1;i>=0;i--){let scope$1=scopes[i];if(scope$1.element===target||scope$1.element.contains(target)||scopeElement===scope$1.element||scope$1.element.contains(scopeElement))break;scopedNavStore.deactivateScope(scope$1.scopeId)}if(scopes=scopedNavStore.getScopes(),targetScope&&targetScope.isScopedNav){let lastScope=scopes.length>0?scopes[scopes.length-1]:null;lastScope&&activeScope&&activeScope.scopeId===lastScope.scopeId&&targetScope.scopeId!==lastScope.scopeId&&lastScope.activationType!==SCOPED_NAV_STATES.suspended&&scopedNavStore.suspendScope(lastScope.scopeId,{scopeId:targetScope.scopeId,scopeElement}),(!activeScope||activeScope.scopeId!==targetScope.scopeId)&&scopeElement._bngScopedNav.canActivate()&&scopedNavStore.activateScope(targetScope.scopeId,scopeElement)}if(target.hasAttribute(`bng-scoped-nav`)){let allowPartialActivation=target[SCOPED_NAV_PROPERTY_NAME].passthroughEnabled,canActivate=target[SCOPED_NAV_PROPERTY_NAME].canActivate();if(target[SCOPED_NAV_PROPERTY_NAME].passthroughActive=!0,allowPartialActivation&&canActivate){let partialScope=getScopeProperties(target);scopedNavStore.activateScope(partialScope.scopeId,target,{activationType:SCOPED_NAV_STATES.partial})}}}var PROPERTY_NAME=`_bngScopedNav`,ATTR_NAME=`bng-scoped-nav`,AUTOFOCUS_ATTR=`bng-scoped-nav-autofocus`,UI_SCOPE_ATTR=`bng-ui-scope`,NAV_ITEM_ATTR=`bng-nav-item`,BNG_ON_UI_NAV_ATTR=`__BngOnUiNav`,DEFAULT_AUTO_FOCUS_DELAY=100,EVENTS_UINAV_MAP={activate:[UI_EVENTS.ok],deactivate:[UI_EVENTS.back],navigation:[...UI_EVENT_GROUPS.focusMove,...UI_EVENT_GROUPS.focusMoveScalar]},NAV_EVENTS={activate:`activate`,deactivate:`deactivate`,suspend:`suspend`,resume:`resume`};const ACTIONS_ON_SUSPEND={allowNavigationLastNavItem:`allowNavigationLastNavItem`,allowNavigationByAttribute:`allowNavigationByAttribute`,disableNavigation:`disableNavigation`};var BngScopedNav_default={beforeMount,mounted,updated,beforeUnmount,unmounted},getDefaultOptions=()=>({type:SCOPED_NAV_TYPES.normal,activateOnMount:!1,actionsOnSuspend:[ACTIONS_ON_SUSPEND.disableNavigation],bubbleWhitelistEvents:[],bubbleBlacklistEvents:[],forcePassthroughEvents:[],canActivate:()=>!0,canDeactivate:()=>!0,autoFocusDelay:DEFAULT_AUTO_FOCUS_DELAY}),canBubbleEventInternal=(el,e)=>{let{bubbleWhitelistEvents,canBubbleEvent}=el[PROPERTY_NAME];return canBubbleEvent&&typeof canBubbleEvent==`function`?canBubbleEvent(e):bubbleWhitelistEvents&&Array.isArray(bubbleWhitelistEvents)&&bubbleWhitelistEvents.length>0?bubbleWhitelistEvents.includes(e.detail.name):!1},shouldBubbleToNextScope=(el,e)=>{let currentScope=useScopedNav().currentScope(),{scopeId,type}=el[PROPERTY_NAME],isActive=currentScope&¤tScope.scopeId===scopeId,isPartial=isActive&¤tScope.activationType===SCOPED_NAV_STATES.partial,isContainer=type===SCOPED_NAV_TYPES.container,isInactiveAndFocused=document.activeElement===el&&!isActive;return!currentScope||isInactiveAndFocused||canBubbleEventInternal(el,e)||isPartial||isContainer},getOptions=(el,binding,vnode)=>{let options={...getDefaultOptions(),...binding.value};if(!Object.values(SCOPED_NAV_TYPES).includes(options.type)){console.error(`Invalid scoped nav type: ${options.type}`);return}return options},applyOptions=(el,options)=>{let attributes={};switch(options.type){case SCOPED_NAV_TYPES.normal:attributes[NAV_ITEM_ATTR]=``,attributes[NO_CHILD_NAV_ATTR]=`true`;break;case SCOPED_NAV_TYPES.nonav:attributes[NO_NAV_ATTR]=`true`,attributes[NO_CHILD_NAV_ATTR]=`true`;break}Object.keys(attributes).forEach(attr=>el.setAttribute(attr,attributes[attr]))},findAutoFocusItem=navItems=>navItems.find(item=>item.hasAttribute(AUTOFOCUS_ATTR)&&item.getAttribute(AUTOFOCUS_ATTR)!==`false`),getAutoFocusItem=el=>findAutoFocusItem(getNavItems(el)),getFirstOrDefaultNavItem=el=>{let navItems,isAutoFocusItem=!1,getNavItems$1=()=>navItems||=getNavItems(el),getLastActive=()=>{let elm=el[PROPERTY_NAME].lastActiveElement;return elm&&!document.contains(elm)?null:elm},getAutoFocus=()=>{let elm=findAutoFocusItem(getNavItems$1());return elm&&!isNavigable(elm)?null:(isAutoFocusItem=!!elm,elm)},getFirst=()=>getNavItems$1()[0],sequence=[getLastActive,getAutoFocus];el[PROPERTY_NAME].preferAutoFocus&&sequence.reverse(),sequence.push(getFirst);for(let func of sequence){let elm=func();if(elm)return{focusItem:elm,isAutoFocusItem}}return{focusItem:null,isAutoFocusItem:!1}},setEnabledNavigation=(el,enabled,settings$1={applyToChildItems:!1,filterElements:void 0})=>{let{type}=el[PROPERTY_NAME];if(type===SCOPED_NAV_TYPES.nonav){logger_default.warn(`Cannot toggle navigation settings for nonav type`,el,enabled,type);return}settings$1.applyToChildItems?getNavItems(el,!1).forEach(item=>{if(!(settings$1.filterElements&&settings$1.filterElements.includes(item))){if(!item[PROPERTY_NAME]){let currentValue=item.hasAttribute(`bng-no-nav`)?item.getAttribute(NO_NAV_ATTR):void 0;item[PROPERTY_NAME]={originalNoNav:currentValue,hadOriginalNoNav:currentValue!==void 0}}enabled?(item[PROPERTY_NAME].hadOriginalNoNav?item.setAttribute(NO_NAV_ATTR,item[PROPERTY_NAME].originalNoNav):item.removeAttribute(NO_NAV_ATTR),item[PROPERTY_NAME].noNavSetByDirective=!1):(!item[PROPERTY_NAME].hadOriginalNoNav||item[PROPERTY_NAME].originalNoNav!==`true`)&&(item.setAttribute(NO_NAV_ATTR,`true`),item[PROPERTY_NAME].noNavSetByDirective=!0)}}):enabled?(el.removeAttribute(NO_CHILD_NAV_ATTR),type===SCOPED_NAV_TYPES.normal&&el.setAttribute(NO_NAV_ATTR,`true`)):(el.setAttribute(NO_CHILD_NAV_ATTR,`true`),type===SCOPED_NAV_TYPES.normal&&el.removeAttribute(NO_NAV_ATTR))},focusFirstOrDefaultNavItem=el=>{let{autoFocusDelay}=el[PROPERTY_NAME];nextTick(()=>{setTimeout(()=>{let{focusItem,isAutoFocusItem}=getFirstOrDefaultNavItem(el);focusItem&&setFocusExternal(focusItem,!0,isAutoFocusItem)},autoFocusDelay)})},ensureFocusOrFocusDefault=el=>{document.activeElement&&isDirectChild(el,document.activeElement)?ensureFocus(document.activeElement,!0):focusFirstOrDefaultNavItem(el)};function beforeMount(el,binding,vnode){let options=getOptions(el,binding,vnode);if(!options)return;let scopeId=options.scopeId||uniqueId(`scoped-nav`);el[PROPERTY_NAME]={scopeId,...options},el[PROPERTY_NAME].shouldBubbleEvent=e=>shouldBubbleToNextScope(el,e),el.setAttribute(ATTR_NAME,scopeId),el.setAttribute(UI_SCOPE_ATTR,scopeId),applyOptions(el,options)}function mounted(el,binding,vnode){addUINavEventListeners(el,binding,vnode),addScopedNavEventListeners(el);let scopedNav=useScopedNav(),options=getOptions(el,binding,vnode);options.type===SCOPED_NAV_TYPES.normal?configurePartialActivation(el):options.type===SCOPED_NAV_TYPES.container&&configureContainer(el,!1),options.activateOnMount&&nextTick(()=>scopedNav.activateScope(el[PROPERTY_NAME].scopeId,el))}var handleDefaultUpdate=(el,binding,vnode)=>{let activeScope=useScopedNav().currentScope(),{scopeId,type}=el[PROPERTY_NAME];!activeScope||activeScope.scopeId!==scopeId||activeScope.activationType!==SCOPED_NAV_STATES.active||ensureFocusOrFocusDefault(el)};function updated(el,binding,vnode){let options=getOptions(el,binding,vnode),{scopeId}=el[PROPERTY_NAME],scopedNav=useScopedNav();if(options.activated===!0&&!scopedNav.isActiveScope(scopeId))if(scopedNav.getScopeById(scopeId)){let popover=usePopover();if(Object.values(popover.popovers).filter(x=>x.show===!0).length>0)return;scopedNav.resumeScope(scopeId,el)}else scopedNav.activateScope(scopeId,el,{activationType:SCOPED_NAV_STATES.active,suspendParentScopes:!0});else options.activated===!1&&scopedNav.isActiveScope(scopeId)?scopedNav.deactivateScope(scopeId,{resumePrevious:!0}):!scopedNav.isActiveScope(scopeId)&&options.type===SCOPED_NAV_TYPES.container&&configureContainer(el,!1);nextTick(()=>{let activeScope=scopedNav.currentScope();activeScope&&activeScope.scopeId===scopeId&&handleDefaultUpdate(el,binding,vnode)})}function beforeUnmount(el,binding,vnode){removeScopedNavEventListeners(el);let scopedNav=useScopedNav();if(scopedNav.getScopeById(el[PROPERTY_NAME].scopeId)){let{type}=el[PROPERTY_NAME];scopedNav.deactivateScope(el[PROPERTY_NAME].scopeId,{resumePrevious:type===SCOPED_NAV_TYPES.popover}),el.dispatchEvent(new CustomEvent(NAV_EVENTS.deactivate,{detail:{force:!0,reason:`unmounted`}}))}}function unmounted(el,binding,vnode){}var handlePartialActivation=(el,event)=>{el[PROPERTY_NAME].forceBubble=!0},handleNormalActivation=(el,event)=>{el[PROPERTY_NAME].forceBubble=!1,nextTick(()=>{setEnabledNavigation(el,!0),(!document.activeElement||el===document.activeElement||!el.contains(document.activeElement))&&focusFirstOrDefaultNavItem(el)})},configurePartialActivation=el=>{let passthroughEvents=getPassthroughEvents(el);el[PROPERTY_NAME].passthroughEnabled=passthroughEvents.length>0,el[PROPERTY_NAME].passthroughEvents=passthroughEvents},configureContainer=(el,activated)=>{el[PROPERTY_NAME].containerSetup&&el[PROPERTY_NAME].containerSetup.cancel(),el[PROPERTY_NAME].containerSetup=debounce(()=>{let autoFocusItem=getAutoFocusItem(el);autoFocusItem&&setEnabledNavigation(el,activated,{applyToChildItems:!0,filterElements:[autoFocusItem]})},100),el[PROPERTY_NAME].containerSetup()},handleContainerActivation=(el,event)=>{configureContainer(el,!0)},handleNoNavActivation=(el,event)=>{},onActivate=(el,event)=>{let{type}=el[PROPERTY_NAME],{activationType}=event.detail;activationType===SCOPED_NAV_STATES.partial?handlePartialActivation(el,event):type===SCOPED_NAV_TYPES.normal?handleNormalActivation(el,event):type===SCOPED_NAV_TYPES.container?handleContainerActivation(el,event):SCOPED_NAV_TYPES.nonav,el.dispatchEvent(new CustomEvent(NAV_EVENTS.activate,{detail:event.detail}))},onDeactivate=(el,event)=>{let{type}=el[PROPERTY_NAME];type===SCOPED_NAV_TYPES.normal&&event.detail.activationType===SCOPED_NAV_STATES.active?setEnabledNavigation(el,!1):type===SCOPED_NAV_TYPES.container&&configureContainer(el,!1),el[PROPERTY_NAME].forceBubble=!1,el.dispatchEvent(new CustomEvent(NAV_EVENTS.deactivate,{detail:event.detail}))},onSuspend=(el,event)=>{let{actionsOnSuspend,type}=el[PROPERTY_NAME],filterElements=[];if(actionsOnSuspend.includes(ACTIONS_ON_SUSPEND.allowNavigationLastNavItem)){let lastActiveElement=el[PROPERTY_NAME].lastActiveElement;lastActiveElement&&document.contains(lastActiveElement)&&filterElements.push(lastActiveElement)}setEnabledNavigation(el,!1,{applyToChildItems:!0,filterElements})},onResume=(el,event)=>{let{actionsOnSuspend,type}=el[PROPERTY_NAME],filterElements=[];if(actionsOnSuspend.includes(ACTIONS_ON_SUSPEND.allowNavigationLastNavItem)){let lastActiveElement=el[PROPERTY_NAME].lastActiveElement;lastActiveElement&&document.contains(lastActiveElement)&&filterElements.push(lastActiveElement)}setEnabledNavigation(el,!0,{applyToChildItems:!0,filterElements}),ensureFocusOrFocusDefault(el)};function addScopedNavEventListeners(el){let eventHandlers={[SCOPED_NAV_EVENTS.activate]:event=>onActivate(el,event),[SCOPED_NAV_EVENTS.deactivate]:event=>onDeactivate(el,event),[SCOPED_NAV_EVENTS.suspend]:event=>onSuspend(el,event),[SCOPED_NAV_EVENTS.resume]:event=>onResume(el,event)};Object.keys(eventHandlers).forEach(eventName=>{el[PROPERTY_NAME].scopedNavListeners||(el[PROPERTY_NAME].scopedNavListeners={}),el.addEventListener(eventName,eventHandlers[eventName]),el[PROPERTY_NAME].scopedNavListeners[eventName]=eventHandlers[eventName]})}function removeScopedNavEventListeners(el){!el||!el[PROPERTY_NAME]||!el[PROPERTY_NAME].scopedNavListeners||Object.keys(el[PROPERTY_NAME].scopedNavListeners).forEach(eventName=>{el.removeEventListener(eventName,el[PROPERTY_NAME].scopedNavListeners[eventName]),delete el[PROPERTY_NAME].scopedNavListeners[eventName]})}var allowsNavigation=el=>{let{type}=el[PROPERTY_NAME];return[SCOPED_NAV_TYPES.normal,SCOPED_NAV_TYPES.container,SCOPED_NAV_TYPES.popover].includes(type)},processNavigationEvent=(el,e)=>{let currentScope=useScopedNav().currentScope(),{scopeId}=el[PROPERTY_NAME];if(!allowsNavigation(el))return!1;document.activeElement===el&¤tScope.scopeId===scopeId?focusFirstOrDefaultNavItem(el):handleUINavEvent(e,el)},isNavigationEvent=e=>UI_EVENT_GROUPS.navigation.includes(e.detail.name),getUINavEventsByEl=el=>{let uiNavEvents=el[BNG_ON_UI_NAV_ATTR]?Object.values(el[BNG_ON_UI_NAV_ATTR]).map(x=>x.eventNames).flat():[],boundEvents=[];return uiNavEvents.forEach(ev=>{boundEvents.includes(ev)||boundEvents.push(ev)}),boundEvents},hasBoundEvent=(el,eventName)=>{let boundEvents=getUINavEventsByEl(el);return boundEvents&&boundEvents.length>0&&boundEvents.includes(eventName)},isUINavEventBoundToChild=(el,e)=>{let{scopeId}=el[PROPERTY_NAME],currentScope=useScopedNav().currentScope();return currentScope&¤tScope.scopeId===scopeId&&e.target!==el&&el.contains(e.target)&&e.target===document.activeElement&&hasBoundEvent(e.target,e.detail.name)},generalHandler=(el,e)=>{let shouldBubble=!1;return isUINavEventBoundToChild(el,e)&&!e.target.hasAttribute(ATTR_NAME)||(shouldBubbleToNextScope(el,e)?shouldBubble=!0:isNavigationEvent(e)&&processNavigationEvent(el,e)),shouldBubble},processOkChildHandler=(el,e)=>{isUINavEventBoundToChild(el,e)||(handleUINavEvent(e,e.target),e.detail.sendToCrossfire=!1)},okHandler=(el,e)=>{if(e.detail.value!==1)return shouldBubbleToNextScope(el,e);let scopedNav=useScopedNav(),scopeId=el[PROPERTY_NAME].scopeId,currentScope=scopedNav.currentScope();return currentScope&¤tScope.scopeId===scopeId&¤tScope.activationType===SCOPED_NAV_STATES.active&&(document.activeElement&&isDirectChild(el,document.activeElement)||e.target&&isDirectChild(el,e.target))?processOkChildHandler(el,e):el[PROPERTY_NAME].canActivate()&&el[PROPERTY_NAME].type===SCOPED_NAV_TYPES.normal&&document.activeElement===el&&scopedNav.activateScope(scopeId,el),shouldBubbleToNextScope(el,e)},backHandler=(el,e)=>{if(e.detail.value!==1)return;let scopedNav=useScopedNav(),{scopeId,type,canDeactivate}=el[PROPERTY_NAME],currentScope=scopedNav.currentScope();if(currentScope&¤tScope.scopeId===scopeId&¤tScope.activationType===SCOPED_NAV_STATES.active)canDeactivate()&&(scopedNav.deactivateScope(scopeId,{resumePrevious:!0,executingScope:scopeId}),type===SCOPED_NAV_TYPES.normal&&nextTick(()=>setFocusExternal(el)));else if(e.target!==el&&isDirectChild(el,e.target))return!1;else return!0},uiNavEventsHandler=(el,e)=>{let uiNavEvent=e.detail.name;return EVENTS_UINAV_MAP.activate.includes(uiNavEvent)?okHandler(el,e):EVENTS_UINAV_MAP.deactivate.includes(uiNavEvent)?backHandler(el,e):generalHandler(el,e)};function addUINavEventListeners(el,binding,vnode){let{bubbleWhitelistEvents}=el[PROPERTY_NAME],generalUINavBinding={arg:[...EVENTS_UINAV_MAP.activate,...EVENTS_UINAV_MAP.deactivate,...EVENTS_UINAV_MAP.navigation].join(`,`),value:e=>uiNavEventsHandler(el,e)};BngOnUiNav_default.mounted(el,generalUINavBinding,vnode)}var ID=`__bngSound`,ID_STOP=`__bngSoundStop`,events$1={click:`click`,dblclick:`dblclick`,focus:`focus`,mouseenter:`mouseenter`};function handler(ev){let el=ev.currentTarget;if(el&&(el[ID]&&events$1[ev.type]&&Lua_default.ui_audio.playEventSound(el[ID],events$1[ev.type]),el[ID_STOP]))for(let event in delete el[ID_STOP],delete el[ID],events$1)el.removeEventListener(event,handler)}var BngSoundClass_default={mounted:(el,binding)=>{delete el[ID_STOP],el[ID]=binding.value,nextTick(()=>{for(let event in events$1)el.addEventListener(event,handler)})},updated:(el,binding)=>{el[ID]=binding.value},unmounted:el=>{el[ID_STOP]=!0}},marker=`__BNG_SD_INPUT`,inputTypes={singleLine:0,multiLine:1};function bindToInputs(elements){let inputs=Array.isArray(elements)?elements:[elements];for(let input of inputs){if(marker in input)continue;input[marker]=!0;let type,tag=input.tagName.toLowerCase();if(tag===`textarea`)type=inputTypes.multiLine;else if(tag===`input`&&[`text`,`number`,`password`,`search`].includes(input.type.toLowerCase()))type=inputTypes.singleLine;else continue;input.addEventListener(`focus`,()=>{let rect=input.getBoundingClientRect();console.log(`SteamDeck input focus:`,type,rect),Lua_default.Steam.showFloatingGamepadTextInput(type,rect.left,rect.top,rect.width,rect.height)})}}async function useSteamDeckInput(inputs){if(!inputs)throw Error(`inputs must be specified (ref, refs, element, elements)`);(await useSettingsAsync()).values.runningOnSteamDeck&&(isRef(inputs)?watch(inputs,bindToInputs,{immediate:!0}):bindToInputs(inputs))}var bridge$1,focused=!1,elms={},elmid=`__BNG_TEXT_INPUT`,focus=id=>async()=>{elms[id].active=!0,focused||=(await bridge$1.lua.setCEFTyping(!0),!0)},blur=id=>async()=>{elms[id].active=!1,focused&&(focused=Object.values(elms).some(e=>e.active),focused||await bridge$1.lua.setCEFTyping(!1))},BngTextInput_default={mounted(el){bridge$1||(bridge$1=useBridge(),bridge$1.events.on(`CEFTypingLostFocus`,()=>focused&&document.activeElement.blur()));let id=el[elmid]||(el[elmid]=uniqueId());elms[id]={el,active:!1,onFocus:focus(id),onBlur:blur(id)},el.addEventListener(`focus`,elms[id].onFocus),el.addEventListener(`blur`,elms[id].onBlur),useSteamDeckInput(el)},beforeUnmount(el){let id=el[elmid];elms[id]&&(el.removeEventListener(`focus`,elms[id].onFocus),el.removeEventListener(`blur`,elms[id].onBlur),elms[id].onBlur(),delete elms[id])}},DEFAULT_POSITION=`left`,TOOLTIP_ATTR_NAME=`data-bng-tooltip`,CONTENT_ATTR_NAME=`data-bng-tooltip-content`,ARROW_ATTR_NAME=`data-bng-tooltip-arrow`,SHOW_TOOLTIP_EVENTS=[`mouseover`,`focusin`],HIDE_TOOLTIP_EVENTS=[`mouseout`,`focusout`],DATA_PROP=`__bngTooltip`,POPOVER_CONTAINER=`.popover-container`,BngTooltip_default={beforeMount(el){initTooltipData(el)},mounted(el,binding,vnode){setupBindings(el,binding),setupTooltip(el),setListeners(el)},beforeUpdate(el,binding){setupBindings(el,binding),el[DATA_PROP].text===void 0?removeTooltip(el):updateTooltipElement(el)},updated(el){let data=el[DATA_PROP];data.update&&requestAnimationFrame(()=>data.update())},beforeUnmount(el){SHOW_TOOLTIP_EVENTS.forEach(eventName=>el.removeEventListener(eventName,el.__showTooltip)),HIDE_TOOLTIP_EVENTS.forEach(eventName=>el.removeEventListener(eventName,el.__hideTooltip));let data=el[DATA_PROP];data.dispose&&data.dispose(),removeTooltip(el)}};function setListeners(el){let data=el[DATA_PROP];data.showTooltip||(data.showTooltip=event=>{data.hideDelay&&=(clearTimeout(data.hideDelay),null),data.tooltipAnimationFrame&&=(cancelAnimationFrame(data.tooltipAnimationFrame),null),el.contains(event.target)&&!data.tooltipElRef.value&&queueTooltipUpdate(el,!0)},SHOW_TOOLTIP_EVENTS.forEach(eventName=>el.addEventListener(eventName,data.showTooltip,!0))),data.hideTooltip||(data.hideTooltip=event=>{data.tooltipAnimationFrame&&=(cancelAnimationFrame(data.tooltipAnimationFrame),null),!el.contains(event.relatedTarget)&&data.tooltipElRef.value&&queueTooltipUpdate(el,!1)},HIDE_TOOLTIP_EVENTS.forEach(eventName=>el.addEventListener(eventName,data.hideTooltip,!0)))}function setupBindings(el,binding){if(binding.value){let bindingValues=getBindings(binding);el[DATA_PROP].text=bindingValues.text,el[DATA_PROP].hideDelayTime=bindingValues.hideDelay,el[DATA_PROP].position=bindingValues.position,el[DATA_PROP].isBBCode=bindingValues.isBBCode,el[DATA_PROP].style=bindingValues.style}else resetTooltipData(el)}function queueTooltipUpdate(el,shouldShow){let data=el[DATA_PROP];data.tooltipAnimationFrame&&cancelAnimationFrame(data.tooltipAnimationFrame),data.pendingTooltipState=shouldShow,data.tooltipAnimationFrame=requestAnimationFrame(()=>{data.pendingTooltipState?showTooltip(el):hideTooltip(el),data.tooltipAnimationFrame=null,data.pendingTooltipState=null})}function showTooltip(el){let data=el[DATA_PROP];data.text&&(addTooltip(el),usePopover().show(data.popoverName,el))}function hideTooltip(el){let data=el[DATA_PROP],hideFn=()=>{removeTooltip(el)};data.hideDelayTime&&typeof data.hideDelayTime==`number`&&data.hideDelayTime>0?data.hideDelay=setTimeout(()=>{hideFn(),data.hideDelay=null},data.hideDelayTime):hideFn()}function setupTooltip(el){let data=el[DATA_PROP],popover=usePopover(),popoverInstance=popover.register(data.popoverName,data.tooltipElRef,data.position,{arrow:data.arrowElRef,offset:4});if(!popoverInstance){console.error(`Failed to register tooltip`);return}el[DATA_PROP].update=popoverInstance.update,el[DATA_PROP].dispose=()=>popover.unregister(data.popoverName),popover.bind(data.popoverName,el,{placement:data.position})}function updateTooltipElement(el){if(el[DATA_PROP].tooltipElRef.value&&el[DATA_PROP].tooltipElRef.value){let updatedContent=parseText(el[DATA_PROP].text,el[DATA_PROP].isBBCode),spanEl=el[DATA_PROP].tooltipElRef.value.querySelector(`span`);spanEl.innerHTML=updatedContent}}function addTooltip(el){let data=el[DATA_PROP];data.tooltipElRef.value=createTooltip(data);let popoverContainer=document.querySelector(POPOVER_CONTAINER);popoverContainer||=(console.warn(`Popover container not found, using parent element`),el.parentElement),el[DATA_PROP].arrowElRef.value=createArrow(),data.tooltipElRef.value.appendChild(el[DATA_PROP].arrowElRef.value),popoverContainer.appendChild(data.tooltipElRef.value)}function removeTooltip(el){let data=el[DATA_PROP];usePopover().hide(data.popoverName),data.tooltipElRef.value&&(data.tooltipElRef.value.remove(),data.tooltipElRef.value=null),data.update&&data.update()}function createTooltip(data){let container=document.createElement(`div`);return data.style&&Object.keys(data.style).forEach(key=>container.style.setProperty(key,data.style[key])),container.setAttribute(TOOLTIP_ATTR_NAME,``),container.appendChild(createContent(data.text,data.isBBCode)),container}function createContent(text,isBBCode){let content=document.createElement(`span`);return Object.assign(content.style,{}),content.innerHTML=parseText(text,isBBCode),content.setAttribute(CONTENT_ATTR_NAME,``),content}function createArrow(){let arrow$3=document.createElement(`span`);return Object.assign(arrow$3.style,{}),arrow$3.setAttribute(ARROW_ATTR_NAME,``),arrow$3}function parseText(text,isBBCode){return isBBCode?parse$1(text):text}var getBindings=binding=>{let position=binding.arg?binding.arg:DEFAULT_POSITION,hideDelay,text,isBBCode=!1,style={};return typeof binding.value==`object`?(hideDelay=binding.value?.hideDelay||0,text=binding.value?.text||void 0,isBBCode=binding.value?.isBBCode||!1,style=binding.value?.style||{}):text=binding.value,{text,position,hideDelay,isBBCode,style}};function initTooltipData(el){el[DATA_PROP]={popoverName:uniqueId(`bng-tooltip`),tooltipElRef:ref(null),arrowElRef:ref(null)},resetTooltipData(el)}function resetTooltipData(el){el[DATA_PROP].text=void 0,el[DATA_PROP].style={},el[DATA_PROP].isBBCode=!1,el[DATA_PROP].hideDelayTime=void 0,el[DATA_PROP].position=void 0,el[DATA_PROP].hideDelay=null,el[DATA_PROP].tooltipAnimationFrame=null}var reg=(elm,{value})=>nextTick(()=>elm&&wantsFocus(elm,value)),BngUiNavFocus_default={mounted:reg,updated:reg,beforeUnmount:unwantsFocus},registry,procEventNames=eventNames=>eventNames.split(`,`).map(name=>name.trim()).filter(Boolean),BngUiNavLabel_default={mounted(el,{arg:eventNames,value:label}){if(!eventNames){console.warn(`Usage: v-bng-ui-nav-label:back,menu="'Back'"`);return}registry||=useUiNavLabel(),label&&(eventNames=procEventNames(eventNames),registry.registerLabel(el,eventNames,label))},updated(el,{arg:eventNames,value:label}){eventNames&&(eventNames=procEventNames(eventNames),label?registry.registerLabel(el,eventNames,label):registry.clearLabels(el,eventNames))},beforeUnmount(el){let events$3=registry.getElementEvents(el);events$3.length>0&®istry.clearLabels(el,events$3)}},SCROLL_PROP=`__bngUiNavScroll`;function enableScroll(id,el){let tracker=useUINavTracker();tracker.addEvent(SCROLL_EVENT_H,id,el),tracker.addEvent(SCROLL_EVENT_V,id,el),tracker.addForceUnblock(SCROLL_EVENT_H,id),tracker.addForceUnblock(SCROLL_EVENT_V,id)}function disableScroll(id,el){let tracker=useUINavTracker();tracker.removeEvent(SCROLL_EVENT_H,id,el),tracker.removeEvent(SCROLL_EVENT_V,id,el),tracker.removeForceUnblock(SCROLL_EVENT_H,id),tracker.removeForceUnblock(SCROLL_EVENT_V,id)}var BngUiNavScroll_default={mounted(element,{arg,value,modifiers}){let prev=element[SCROLL_PROP]||{},dir={id:prev.id||uniqueId(SCROLL_PROP),forced:modifiers.force,enable:()=>enableScroll(dir.id,element),disable:()=>disableScroll(dir.id,element)};if(element[SCROLL_PROP]=dir,prev.forced&&(element.removeEventListener(`focusin`,prev.enable),element.removeEventListener(`focusout`,prev.disable)),typeof value==`boolean`&&!value){prev.id&&prev.disable(),dir.forced=!1;return}dir.forced?(element.setAttribute(SCROLL_FORCE_ATTR,``),dir.enable()):(element.setAttribute(SCROLL_ATTR,``),element.addEventListener(`focusin`,dir.enable),element.addEventListener(`focusout`,dir.disable))},beforeUnmount(element){let dir=element[SCROLL_PROP];dir&&(dir.forced||(element.removeEventListener(`focusin`,dir.enable),element.removeEventListener(`focusout`,dir.disable)),dir.disable(),delete element[SCROLL_PROP])}},observed=new WeakMap;function createObserver(root=null,rootMargin=`0px`){return new IntersectionObserver(entries=>{for(let entry of entries){let data=observed.get(entry.target);if(!data){entry.target.observer?.unobserve(entry.target);return}if(data.onChange)data.onChange(entry.isIntersecting);else{let displayValue=entry.isIntersecting?[`display`,``,``]:[`display`,`none`,`important`];entry.target.style.setProperty(...displayValue),entry.target.querySelectorAll(`*`).forEach(child=>{child.style.setProperty(...displayValue)})}}},{root,rootMargin,threshold:0})}var defaultObserver=createObserver(),_sfc_main$404={__name:`bngActionDrawer`,props:{actions:{type:Object,default:{allowOpenDrawer:!1}},skeletonItems:{type:Number,default:5},usePath:Boolean,alwaysShowBack:Boolean,itemWidth:Number,itemHeight:Number,itemMargin:Number,big:Boolean,position:String,blur:Boolean},emits:[`select`],setup(__props,{expose:__expose,emit:__emit}){let props=__props,emit$1=__emit;__expose({goBack:onBack});let expanded=ref(!1),current=ref(props.actions),lazyItem={label:`…`,icon:icons.stopwatchSectionOutlinedStart};function onSelect(item){(`items`in item||item.lazyLoadItems)&&(current.value&&addBack(current.value),current.value=item),emit$1(`select`,item)}let backState=computed(()=>{let disable=back.value.length===0||!(`items`in current.value);return{show:!disable||props.alwaysShowBack,disable}}),back=ref([]);function onBack(){current.value=null,onSelect(back.value.pop().data)}function addBack(prevItem){let backItem={index:back.value.length,label:prevItem.label,data:prevItem};props.usePath&&prevItem.items&&(backItem.items=prevItem.items.reduce((res,itm)=>[...res,{index:backItem.index+1,label:itm.label,data:itm}],[])),back.value.push(backItem)}let path=computed(()=>props.usePath?[...back.value,{current:!0,label:current.value.label,data:current.value}]:void 0);function onPath(item){item.current||(back.value.splice(item.index),current.value=null,onSelect(item.data))}return watch(()=>props.actions,val=>{back.value.splice(0),current.value=val}),(_ctx,_cache)=>(openBlock(),createBlock(unref(bngDrawer_default),{modelValue:expanded.value,"onUpdate:modelValue":_cache[0]||=$event=>expanded.value=$event,expandable:current.value.allowOpenDrawer,position:__props.position,blur:__props.blur},createSlots({"header-controls":withCtx(()=>[__props.usePath?(openBlock(),createBlock(unref(bngBreadcrumbs_default),{key:0,items:path.value,limit:`5`,onClick:onPath},null,8,[`items`])):backState.value.show?(openBlock(),createBlock(unref(bngButton_default),{key:1,accent:unref(ACCENTS).outlined,disabled:backState.value.disable,onClick:onBack},{default:withCtx(()=>[..._cache[1]||=[createTextVNode(`Back`,-1)]]),_:1},8,[`accent`,`disabled`])):createCommentVNode(``,!0),renderSlot(_ctx.$slots,`controls`)]),content:withCtx(()=>[withDirectives((openBlock(),createBlock(unref(bngList_default),{layout:expanded.value?unref(LIST_LAYOUTS).TILES:unref(LIST_LAYOUTS).RIBBON,big:__props.big,"target-width":__props.itemWidth,"target-height":__props.itemHeight,"target-margin":__props.itemMargin,"no-background":``},{default:withCtx(()=>[`items`in current.value?(openBlock(!0),createElementBlock(Fragment,{key:0},renderList(current.value.items,(item,index)=>renderSlot(_ctx.$slots,`action`,{item,select:onSelect,isLoading:!1,order:index})),256)):(openBlock(!0),createElementBlock(Fragment,{key:1},renderList(__props.skeletonItems,idx=>renderSlot(_ctx.$slots,`action`,{item:lazyItem,select:()=>{},isLoading:!0})),256))]),_:3},8,[`layout`,`big`,`target-width`,`target-height`,`target-margin`])),[[unref(BngDisabled_default),!(`items`in current.value)]])]),_:2},[__props.usePath?void 0:{name:`header`,fn:withCtx(()=>[createTextVNode(toDisplayString(current.value.label),1)]),key:`0`}]),1032,[`modelValue`,`expandable`,`position`,`blur`]))}},bngActionDrawer_default=_sfc_main$404,__plugin_vue_export_helper_default=(sfc,props)=>{let target=sfc.__vccOpts||sfc;for(let[key,val]of props)target[key]=val;return target},_hoisted_1$347={class:`bng-accordion-container`},_sfc_main$403={__name:`accordion`,props:{singular:Boolean,expanded:Boolean,disabled:Boolean,animated:Boolean,selectable:[Boolean,Object],selected:Boolean,provideParent:Boolean},emits:[`selected`],setup(__props,{emit:__emit}){let props=__props,counter$1=0,items$2=[],selopts=null,emit$1=__emit;watch(()=>props.singular,val=>val&&toggle(items$2.find(itm=>itm.expanded),!0)),watch(()=>props.expanded,val=>toggle(null,val)),watch(()=>props.animated,val=>{for(let itm of items$2)itm.animated=val},{immediate:!0}),watch(()=>props.disabled,val=>{for(let itm of items$2)itm.disabled=val},{immediate:!0}),watch(()=>props.selectable,val=>{val?(selopts={multi:!1},typeof val==`object`&&(selopts={selopts,...val})):selopts=null;for(let itm of items$2)itm.selectable=selopts},{immediate:!0}),watch(()=>props.selected,val=>select(null,val));function toggle(item=null,expanded=null){if(props.singular&&!item&&expanded){if(items$2.length===0)return;item=items$2[0]}for(let itm of items$2){let exp=!itm.expandedActual;item&&itm.id!==item.id?exp=props.singular?!1:itm.expandedActual:typeof expanded==`boolean`&&(exp=expanded),itm.expandedActual=exp}}provide(`accordion-item-toggle`,toggle);function select(item=null,selected=null){let state=[];for(let itm of items$2){let sel;sel=item&&itm.id!==item.id?selopts.multi?itm.selected:!1:typeof selected==`boolean`?selected:selopts.multi?!itm.selected:!0,itm.selected!==sel&&(itm.selected=sel,state.push(itm))}state.length>0&&emit$1(`selected`,state)}provide(`accordion-item-select`,select),props.provideParent&&inject(`accordion-item-childSelect`)(select);let waitForOptions=cb=>selopts?cb():setTimeout(()=>waitForOptions(cb),50);return provide(`accordion-item-register`,item=>{item.id=counter$1++,props.expanded&&(item.expanded=props.expanded),props.disabled&&(item.disabled=props.disabled),props.selectable&&(item.selectable=props.selectable),items$2.push(item),waitForOptions(()=>{props.singular&&item.expanded&&toggle(item,!0),item.selected&&select(item,!0)})}),provide(`accordion-item-unregister`,item=>{let idx=items$2.findIndex(itm=>itm.id===item.id);idx>-1&&items$2.splice(idx,1)}),(_ctx,_cache)=>withDirectives((openBlock(),createElementBlock(`div`,_hoisted_1$347,[renderSlot(_ctx.$slots,`default`,{},void 0,!0)])),[[unref(BngDisabled_default),__props.disabled]])}},accordion_default=__plugin_vue_export_helper_default(_sfc_main$403,[[`__scopeId`,`data-v-fcd1832d`]]),_hoisted_1$346={key:0,class:`bng-accitem-content`},_sfc_main$402={__name:`accordionItem`,props:{static:Boolean,expanded:Boolean,disabled:Boolean,animated:Boolean,selectable:{type:[Boolean,Object],default:!1},selected:Boolean,data:{},navigable:{type:[Boolean,Object],default:!1},arrowBig:Boolean,primaryAction:Function,secondaryAction:Function,primaryLabel:String,secondaryLabel:String,primaryHintInline:Boolean,secondaryHintInline:Boolean,expandHintInline:Boolean},emits:[`focus`,`unfocus`,`expanded`,`selected`],setup(__props,{expose:__expose,emit:__emit}){let{showIfController}=storeToRefs(controls_default()),navBlocker=useUINavBlocker(),props=__props,elCaption=ref(),elCaptionContent=ref(),elCaptionControls=ref(),hasFocus=ref(!1),icon=computed(()=>props.arrowBig?icons.arrowLargeRight:icons.arrowSmallRight),popTip=ref();watch([()=>hasFocus.value,()=>showIfController.value],()=>{hasFocus.value&&showIfController.value&&(props.primaryHintInline&&props.primaryAction||props.secondaryHintInline&&props.secondaryAction)?popTip.value.show(elCaption.value):popTip.value.isShown()&&popTip.value.hide()});let reg$1=inject(`accordion-item-register`),unreg=inject(`accordion-item-unregister`),toggle=inject(`accordion-item-toggle`),select=inject(`accordion-item-select`),opts=reactive({id:-1,captionClick:evt=>{props.primaryAction&&evt.fromController?props.primaryAction():opts.selectable?select(opts):opts.expandClick()},expandClick:()=>!props.static&&toggle(opts),static:props.static,expandedActual:props.expanded,disabled:props.disabled,animated:props.animated,selected:props.selected,selectable:props.selectable,navigable:{enabled:!1},data:props.data}),emit$1=__emit;__expose({captionClick:opts.captionClick,focus:()=>setFocusExternal(elCaption.value,!0,!1),captionElement:computed(()=>elCaption.value)}),watch(()=>props.static,val=>opts.static=val),watch(()=>props.expanded,val=>!opts.static&&toggle(opts,val)),watch(()=>props.disabled,val=>opts.disabled=val),watch(()=>opts.disabled,val=>!val&&props.disabled&&(opts.disabled=props.disabled)),watch(()=>props.animated,val=>opts.animated=val),watch(()=>props.selectable,val=>opts.selectable=val),watch(()=>props.selected,val=>opts.selected=val),watch(()=>opts.expandedActual,val=>{emit$1(`expanded`,!opts.static&&!opts.disabled&&val)}),watch(()=>props.data,val=>opts.data=val),watch(()=>props.navigable,val=>{if(typeof val!=`object`&&typeof val==`boolean`&&!val){opts.navigable={enabled:!1};return}opts.navigable={enabled:!0,scope:null,...typeof val==`object`?val:{}}},{immediate:!0}),opts.navigable.scope&&useUINavScope(opts.navigable.scope);let onFocus=evt=>{hasFocus.value=!0,navBlocker.blockOnly(opts.static?[`context`]:[]),emit$1(`focus`,evt)},onLoseFocus=evt=>{hasFocus.value=!1,navBlocker.clear(),emit$1(`unfocus`,evt)};return provide(`accordion-item-childSelect`,select$1=>(item,value)=>opts.selectable&&opts.selectable.multi&&select$1(item,value)),provide(`accordion-item-parent`,opts),onMounted(()=>reg$1(opts)),onBeforeUnmount(()=>{popTip.value.isShown()&&popTip.value.hide(),unreg(opts)}),(_ctx,_cache)=>withDirectives((openBlock(),createElementBlock(`div`,{class:normalizeClass({"bng-accitem":!0,"bng-accitem-normal":!opts.static&&!opts.selectable,"bng-accitem-static":opts.static,"bng-accitem-expandable":!opts.static,"bng-accitem-selectable":opts.selectable,"bng-accitem-expanded":!opts.static&&opts.expandedActual&&!opts.disabled,"bng-accitem-selected":opts.selected})},[withDirectives((openBlock(),createElementBlock(`div`,mergeProps({ref_key:`elCaption`,ref:elCaption,class:`bng-accitem-caption`,onClick:_cache[1]||=(...args)=>opts.captionClick&&opts.captionClick(...args),onFocus,onBlur:onLoseFocus},{"bng-nav-item":opts.navigable.enabled?!0:void 0,"bng-ui-scope":opts.navigable.scope||void 0}),[opts.static?createCommentVNode(``,!0):(openBlock(),createBlock(unref(bngIcon_default),{key:0,class:normalizeClass({"bng-accitem-caption-expander":!0,"bng-accitem-caption-expander-big":__props.arrowBig}),type:icon.value,onClick:withModifiers(opts.expandClick,[`stop`])},null,8,[`class`,`type`,`onClick`])),__props.expandHintInline&&!opts.static&&hasFocus.value&&unref(showIfController)?(openBlock(),createBlock(unref(bngBinding_default),{key:1,style:{"padding-right":`0.2em`},uiEvent:`context`,controller:``})):createCommentVNode(``,!0),createBaseVNode(`span`,{ref_key:`elCaptionContent`,ref:elCaptionContent,class:`bng-accitem-caption-content`},[renderSlot(_ctx.$slots,`caption`,{},()=>[_cache[2]||=createTextVNode(`Unnamed item`,-1)],!0)],512),_ctx.$slots.controls?(openBlock(),createElementBlock(`div`,{key:2,ref_key:`elCaptionControls`,ref:elCaptionControls,class:`bng-accitem-caption-controls`,onClick:_cache[0]||=withModifiers(()=>{},[`stop`])},[renderSlot(_ctx.$slots,`controls`,{},void 0,!0)],512)):createCommentVNode(``,!0),createVNode(unref(bngPopoverContent_default),{ref_key:`popTip`,ref:popTip,placement:`right`},{default:withCtx(()=>[__props.primaryHintInline&&__props.primaryAction?(openBlock(),createBlock(unref(bngBinding_default),{key:0,uiEvent:`ok`,controller:``})):createCommentVNode(``,!0),__props.secondaryHintInline&&__props.secondaryAction?(openBlock(),createBlock(unref(bngBinding_default),{key:1,uiEvent:`action_2`,controller:``})):createCommentVNode(``,!0)]),_:1},512)],16)),[[unref(BngOnUiNav_default),void 0,`ok`,{asMouse:!0,focusRequired:!0}],[unref(BngOnUiNav_default),__props.secondaryAction?__props.secondaryAction:void 0,`action_2`,{focusRequired:!0}],[unref(BngOnUiNav_default),!opts.static&&opts.navigable.enabled?opts.expandClick:void 0,`context`,{focusRequired:!0}],[unref(BngUiNavLabel_default),__props.primaryLabel||`ui.inputActions.menu.menu_item_select.title`,`ok`],[unref(BngUiNavLabel_default),__props.secondaryLabel,`action_2`],[unref(BngUiNavLabel_default),_ctx.$tt(`ui.common.expand`)+`/`+_ctx.$tt(`ui.common.collapse`),`context`]]),createVNode(Transition,{name:opts.animated?`bng-acc-trans`:null},{default:withCtx(()=>[!opts.static&&opts.expandedActual&&!opts.disabled?(openBlock(),createElementBlock(`div`,_hoisted_1$346,[renderSlot(_ctx.$slots,`default`,{},()=>[_cache[3]||=createTextVNode(`Empty`,-1)],!0)])):createCommentVNode(``,!0)]),_:3},8,[`name`])],2)),[[unref(BngDisabled_default),opts.disabled]])}},accordionItem_default=__plugin_vue_export_helper_default(_sfc_main$402,[[`__scopeId`,`data-v-dd6087ee`]]),_sfc_main$401={__name:`accordionTree`,props:{data:[Array,Object],dataField:{type:String,required:!0},propsField:String,contentField:String,selectable:{type:[Boolean,Object],default:!1},selectedField:String,isTreeElement:Boolean},emits:[`selected`],setup(__props,{emit:__emit}){let props=__props,dataView=computed(()=>props.data&&(props.data[props.dataField]||props.data)||[]),emit$1=__emit;props.isTreeElement||(watch(()=>dataView.value,refreshSelected),watch(()=>props.selectedField&&props.selectable&&props.selectable.multi,refreshSelected),refreshSelected());let prevState=[];function refreshSelected(){if(!props.selectedField||!props.selectable||!props.selectable.multi)return;let state=[];function deepScan(arr){for(let itm of arr){let data=itm.data||itm;data[props.selectedField]&&state.push({data,selected:!0}),data[props.dataField]&&deepScan(data[props.dataField])}}deepScan(dataView.value),selected(state)}function selected(state){if(!props.isTreeElement){if(!props.selectable.multi){prevState=prevState.filter(itm=>itm.selected);for(let itm of prevState)itm.selected&&(itm.item.selected=!1,props.selectedField&&(itm.item.data[props.selectedField]=!1),state.includes(itm.item)||state.push(itm.item));prevState=state.map(item=>({selected:!!item.selected,item}))}if(props.selectedField){function deepSet(arr,value=void 0){for(let itm of arr){let val=typeof value==`boolean`?value:itm.selected,data=itm.data||itm;data[props.selectedField]=val,data[props.dataField]&&deepSet(data[props.dataField])}}deepSet(state)}}emit$1(`selected`,state)}function branchSelected(state){props.isTreeElement?emit$1(`selected`,state):selected(state)}return(_ctx,_cache)=>dataView.value.length>0?(openBlock(),createBlock(unref(accordion_default),{key:0,class:`acctree`,selectable:__props.selectable,"provide-parent":__props.isTreeElement,onSelected:selected},{default:withCtx(()=>[(openBlock(!0),createElementBlock(Fragment,null,renderList(dataView.value,entry=>(openBlock(),createBlock(unref(accordionItem_default),mergeProps({ref_for:!0},__props.propsField?entry[__props.propsField]:void 0,{selected:__props.selectedField?entry[__props.selectedField]:void 0,static:(!entry[__props.dataField]||entry[__props.dataField].length===0)&&(!__props.contentField||!entry[__props.contentField]),data:entry}),{caption:withCtx(()=>[renderSlot(_ctx.$slots,`caption`,{entry},void 0,!0)]),controls:withCtx(()=>[renderSlot(_ctx.$slots,`controls`,{entry},void 0,!0)]),default:withCtx(()=>[__props.contentField&&entry[__props.contentField]?renderSlot(_ctx.$slots,`default`,{key:0,entry},void 0,!0):createCommentVNode(``,!0),entry[__props.dataField]&&entry[__props.dataField].length>0?(openBlock(),createBlock(unref(accordionTree_default),mergeProps({key:1,ref_for:!0},props,{data:entry,"is-tree-element":!0,onSelected:branchSelected}),{caption:withCtx(({entry:entry$1})=>[renderSlot(_ctx.$slots,`caption`,{entry:entry$1},void 0,!0)]),controls:withCtx(({entry:entry$1})=>[renderSlot(_ctx.$slots,`controls`,{entry:entry$1},void 0,!0)]),_:2},1040,[`data`])):createCommentVNode(``,!0)]),_:2},1040,[`selected`,`static`,`data`]))),256))]),_:3},8,[`selectable`,`provide-parent`])):createCommentVNode(``,!0)}},accordionTree_default=__plugin_vue_export_helper_default(_sfc_main$401,[[`__scopeId`,`data-v-2ad1085d`]]),_hoisted_1$345={class:`slotted`},_sfc_main$400={__name:`aspectRatio`,props:{ratio:{type:String,default:`16:9`},imageMode:{type:String,default:`cover`,validator:value=>[`cover`,`contain`].includes(value)},image:{type:String,default:null},externalImage:{type:String,default:null}},setup(__props){useCssVars(_ctx=>({v711986eb:__props.imageMode}));let placeholderImageURL=getAssetURL(`images/noimage.png`),slots=useSlots(),props=__props,padding=computed(()=>{if(!props.ratio)return`56.25%`;let[width$1,height$1]=props.ratio.split(`:`).map(Number);return`${height$1/width$1*100}%`}),backgroundStyle=computed(()=>!props.image&&!props.externalImage?{"--padding":padding.value,backgroundImage:`none`}:props.image||props.externalImage?{"--padding":padding.value,backgroundImage:`url("${props.externalImage?props.externalImage:getAssetURL(props.image)}")`}:slots.default?{"--padding":padding.value,backgroundImage:`url("${placeholderImageURL}")`}:{});return(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,{class:`aspect-ratio`,style:normalizeStyle(backgroundStyle.value)},[createBaseVNode(`div`,_hoisted_1$345,[renderSlot(_ctx.$slots,`default`,{},void 0,!0)])],4))}},aspectRatio_default=__plugin_vue_export_helper_default(_sfc_main$400,[[`__scopeId`,`data-v-83698898`]]),_hoisted_1$344=[`data-carousel-item`],_sfc_main$399={__name:`carouselItem`,props:{value:{type:[String,Number],required:!0}},setup(__props){return(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,{class:`bng-carousel-item`,"data-carousel-item":__props.value},[renderSlot(_ctx.$slots,`default`,{},void 0,!0)],8,_hoisted_1$344))}},carouselItem_default=__plugin_vue_export_helper_default(_sfc_main$399,[[`__scopeId`,`data-v-babc74fb`]]),_hoisted_1$343={key:0,class:`navigation`},_hoisted_2$271=[`onClick`],TRANSITION_TYPES=[`fade`],_sfc_main$398={__name:`carousel`,props:{items:{type:Array,required:!0},current:{type:[String,Number],default:0},vertical:Boolean,loop:{type:Boolean,default:!0},transition:Boolean,transitionType:{type:String,default:`fade`,validator:value=>TRANSITION_TYPES.includes(value)},transitionTime:{type:Number,default:3e3},showNav:{type:Boolean,default:!0},parent:Object},setup(__props,{expose:__expose}){let props=__props,transitionTimer,carouselRoot=ref(null),carousel=ref(null),currentIndex=ref(props.current);computed(()=>``);let navState=reactive({selected:null}),showSlide=value=>{let slideIndex=parseInt(value);currentIndex.value=slideIndex,navState.selected=slideIndex,setTransition()},navShown=computed(()=>props.showNav&&!props.parent),children=[],childIndex=child=>children.findIndex(itm=>itm.element===child.element),addChild=child=>{childIndex(child)===-1&&children.push(child)},remChild=child=>{let idx=childIndex(child);idx>-1&&children.splice(idx,1)},tryParent=(_retry=0)=>{if(props.parent.addChild)props.parent.addChild(exposed);else if(_retry<100){let unwatch=watch(()=>props.parent.addChild,()=>{unwatch(),tryParent(++_retry)})}};watch(()=>props.parent,tryParent),watch(()=>navState.selected,sel=>{for(let child of children)child.showSlide&&child.showSlide(sel)}),onMounted(()=>{setTransition(),props.parent&&tryParent()}),onBeforeUnmount(()=>{transitionTimer&&=(clearInterval(transitionTimer),null),props.parent&&props.parent.remChild&&props.parent.remChild(exposed)});function showPrevious(){if(props.parent)return;let prev;currentIndex.value===0&&props.loop?prev=props.items.length-1:currentIndex.value>0&&(prev=currentIndex.value-1),prev!==void 0&&(navState.selected=prev,currentIndex.value=prev,setTransition())}function showNext(){if(props.parent)return;let next=getNext();next>-1&&(navState.selected=next,currentIndex.value=next,setTransition())}function setTransition(){transitionTimer&&clearInterval(transitionTimer),transitionTimer=setInterval(()=>{let next=getNext();next>-1&&(currentIndex.value=next)},props.transitionTime)}function getNext(){return currentIndex.value===props.items.length-1&&props.loop?0:currentIndex.value(openBlock(),createElementBlock(`div`,{ref_key:`carouselRoot`,ref:carouselRoot,class:normalizeClass({"bng-carousel":!0,"carousel-vertical":__props.vertical,[`transition-${__props.transitionType}`]:!0})},[createBaseVNode(`div`,{ref_key:`carousel`,ref:carousel,class:`carousel-content`},[createVNode(Transition,{name:__props.transitionType},{default:withCtx(()=>[(openBlock(),createBlock(carouselItem_default,{key:currentIndex.value,class:`carousel-slide`,value:currentIndex.value},{default:withCtx(()=>[renderSlot(_ctx.$slots,`item`,{item:__props.items[currentIndex.value],index:currentIndex.value},()=>[createTextVNode(toDisplayString(__props.items[currentIndex.value]),1)],!0)]),_:3},8,[`value`]))]),_:3},8,[`name`])],512),renderSlot(_ctx.$slots,`navigation`,{},()=>[navShown.value&&__props.items&&__props.items.length>1?(openBlock(),createElementBlock(`div`,_hoisted_1$343,[(openBlock(!0),createElementBlock(Fragment,null,renderList(__props.items,(item,index)=>(openBlock(),createElementBlock(`div`,{class:normalizeClass([`navigation-item`,{active:index===currentIndex.value}]),key:item.value,onClick:$event=>showSlide(index)},null,10,_hoisted_2$271))),128))])):createCommentVNode(``,!0)],!0)],2))}},carousel_default=__plugin_vue_export_helper_default(_sfc_main$398,[[`__scopeId`,`data-v-f54192e0`]]),_hoisted_1$342={key:0,class:`drawer-header`},_hoisted_2$270={key:1,class:`drawer-content`},_hoisted_3$236={key:2,class:`drawer-header`};const DRAWER_POSITION={bottom:`bottom`,top:`top`,left:`left`,right:`right`};var _sfc_main$397={__name:`drawer`,props:mergeModels({blur:Boolean,position:{type:String,default:DRAWER_POSITION.bottom,validator:val=>Object.values(DRAWER_POSITION).includes(val)}},{modelValue:{type:Boolean},modelModifiers:{}}),emits:mergeModels([`change`],[`update:modelValue`]),setup(__props,{emit:__emit}){let emit$1=__emit,expanded=useModel(__props,`modelValue`);watch(()=>expanded.value,val=>emit$1(`change`,val));let slots=useSlots(),expandedContent=computed(()=>expanded.value&&`expanded-content`in slots),hasAnyContent=computed(()=>expandedContent.value||`content`in slots);return(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,{class:normalizeClass({"bng-drawer":!0,[`drawer-pos-${__props.position}`]:!0,"drawer-expanded":expanded.value})},[__props.position===`bottom`||__props.position===`right`?withDirectives((openBlock(),createElementBlock(`div`,_hoisted_1$342,[renderSlot(_ctx.$slots,`header`,{},void 0,!0)])),[[unref(BngBlur_default),__props.blur]]):createCommentVNode(``,!0),hasAnyContent.value?withDirectives((openBlock(),createElementBlock(`div`,_hoisted_2$270,[expandedContent.value?renderSlot(_ctx.$slots,`expanded-content`,{key:0},void 0,!0):renderSlot(_ctx.$slots,`content`,{key:1},void 0,!0)])),[[unref(BngBlur_default),__props.blur]]):createCommentVNode(``,!0),__props.position===`top`||__props.position===`left`?withDirectives((openBlock(),createElementBlock(`div`,_hoisted_3$236,[renderSlot(_ctx.$slots,`header`,{},void 0,!0)])),[[unref(BngBlur_default),__props.blur]]):createCommentVNode(``,!0)],2))}},drawer_default=__plugin_vue_export_helper_default(_sfc_main$397,[[`__scopeId`,`data-v-8023232b`]]),_sfc_main$396={__name:`dynamicComponent`,props:{template:String,translateId:String,translateContext:Boolean,bbcode:Boolean,useComponents:{type:Boolean,default:!0},extraComponents:{type:Object,default:()=>({})}},setup(__props){let ALL_COMPONENTS=Object.fromEntries(Object.entries({...base_exports,...utility_exports}).filter(([name])=>name!==`DEMOS`)),attrs=useAttrs(),props=__props,template=computed(()=>{let res=props.template;return props.translateId&&(res=props.translateContext?$translate.contextTranslate(props.translateId,!0):$translate.instant(props.translateId)),res&&props.bbcode&&(res=parse$1(res)),res||``}),makeComponent=computed(()=>defineComponent({template:template.value,components:{...props.useComponents&&ALL_COMPONENTS,...props.extraComponents},data(){return attrs}}));return(_ctx,_cache)=>template.value&&makeComponent.value?(openBlock(),createBlock(resolveDynamicComponent(makeComponent.value),{key:0})):createCommentVNode(``,!0)}},dynamicComponent_default=_sfc_main$396,_hoisted_1$341={class:`shelf-wrapper`},_hoisted_2$269=[`disabled`],_hoisted_3$235=[`disabled`],storageKey=`bngshelf`,_sfc_main$395={__name:`shelf`,props:mergeModels({saveName:{type:String,default:null},limit:{type:Number,default:5,validator:val=>val>2&&val%2==1},fade:{type:Boolean,default:!1},showExtra:{type:Boolean,default:!0},neighborsFlatten:{type:Boolean,default:!1},neighborsScale:{type:Number,default:1},keepNeighborsAspectRatio:{type:Boolean,default:!1},noLoop:{type:Boolean,default:!1},navShown:{type:Boolean,default:!1},inward:{type:Number,default:0,validator:val=>val>=0&&val<=1}},{modelValue:{type:Number,default:0},modelModifiers:{}}),emits:mergeModels([`change`,`click`],[`update:modelValue`]),setup(__props,{expose:__expose,emit:__emit}){let selectedIndex=useModel(__props,`modelValue`),props=__props,emit$1=__emit,ready=ref(!1),slots=useSlots(),containerRef=ref(null),shelfItems=ref([]),displayItems=ref([]),isAnimating=ref(!1),itemIdCounter=0,lastValidIndex=0,isReverting=!1,isPrevDisabled=computed(()=>isAnimating.value||props.noLoop&&selectedIndex.value===0),isNextDisabled=computed(()=>isAnimating.value||props.noLoop&&selectedIndex.value===shelfItems.value.length-1);watch(selectedIndex,index=>{if(!isReverting){if(index=parseInt(index,10),isNaN(index)||index<0||shelfItems.value.length>0&&index>=shelfItems.value.length){isReverting=!0,selectedIndex.value=lastValidIndex,isReverting=!1;return}lastValidIndex=index,ready.value&&buildDisplayItems()}},{immediate:!0});let timings={single:400,multiStart:200,multiMiddle:200,multiEnd:200};watch(()=>slots.default?.(),update$6,{immediate:!0});function update$6(vnodes){if(ready.value){if(vnodes===void 0&&(vnodes=slots.default?.()),Array.isArray(vnodes)||(vnodes=[]),shelfItems.value=vnodes.reduce((res,vnode)=>typeof vnode.type==`symbol`&&vnode.type.toString()===`Symbol(v-fgt)`?(res.push(...vnode.children),res):(res.push(vnode),res),[]),props.saveName){let val=localStorage.getItem(`${storageKey}-${props.saveName}`);if(val!==null){let idx=parseInt(val,10);!isNaN(idx)&&idx>=0&&idxhalfLimit)continue;let itemIndex=selectedIndex.value+offset$2;if(props.noLoop){if(itemIndex<0||itemIndex>=shelfItems.value.length)continue}else itemIndex<0?itemIndex=shelfItems.value.length+itemIndex:itemIndex>=shelfItems.value.length&&(itemIndex-=shelfItems.value.length);items$2.push({vnode:shelfItems.value[itemIndex],originalIndex:itemIndex,position:offset$2,id:++itemIdCounter,style:getItemStyle(offset$2,`normal`)})}displayItems.value=items$2}function getItemStyle(position,state=`normal`){let absPosition=Math.abs(position),halfLimit=~~(props.limit/2),isExtraItem=absPosition>halfLimit,factor=halfLimit>0?absPosition/halfLimit:1,leftPercentage;if(leftPercentage=isExtraItem?(position<0?0:props.limit-1)/(props.limit-1)*100:(position+halfLimit)/(props.limit-1)*100,position!==0&&props.inward>0){let pullToCenter=(50-leftPercentage)*props.inward*factor;leftPercentage+=pullToCenter}let rotateY=factor*-30*Math.sign(position),translateZ=0,scaleX=1,scaleY=1,brightness=1;if(position!==0){if(translateZ=-100*factor,props.keepNeighborsAspectRatio){let scale=Math.max(.6,1-factor*.4)*props.neighborsScale;scaleX=scale,scaleY=scale}else scaleX=Math.max(.4,1-factor*.6)*props.neighborsScale,scaleY=Math.max(.6,1-factor*.4)*props.neighborsScale;brightness=Math.max(.5,1-factor*.5),props.neighborsFlatten&&(rotateY=0)}let opacity=1;return state===`entering`||state===`exiting`?(opacity=.1,translateZ=-100*(absPosition/halfLimit),leftPercentage+=2*Math.sign(position)):isExtraItem?opacity=.2:props.fade&&position!==0&&(opacity=Math.max(.4,1-absPosition*.3)),{left:`${leftPercentage}%`,transform:`translateX(-50%) translateY(-50%) translateZ(${translateZ}px) rotateY(${rotateY}deg) scale(${scaleX}, ${scaleY})`,filter:`brightness(${brightness})`,transition:`all 400ms cubic-bezier(0.25, 0.8, 0.25, 1)`,opacity,zIndex:isExtraItem?10-absPosition:100-absPosition}}let abortAnimation=!1;async function toIndex(targetIndex){if(!ready.value||selectedIndex.value===targetIndex||typeof targetIndex!=`number`||targetIndex<0||targetIndex>=shelfItems.value.length)return;if(isAnimating.value)for(abortAnimation=!0;abortAnimation;)await sleep(20);let prevIndex=selectedIndex.value,steps=calculateSteps(selectedIndex.value,targetIndex);if(steps.length!==0){isAnimating.value=!0;try{let stepTimings=calculateStepTimings(steps.length);for(let i=0;i{selectedIndex.value===targetIndex&&setFocusExternal(containerRef.value.querySelector(`[data-shelf-index="${targetIndex}"]`))})}finally{abortAnimation=!1,isAnimating.value=!1}props.saveName&&localStorage.setItem(`${storageKey}-${props.saveName}`,targetIndex.toString()),emit$1(`change`,targetIndex,prevIndex)}}let onFocus=index=>selectedIndex.value!==index&&toIndex(index);function onClick(index,event){selectedIndex.value===index?emit$1(`click`,event,index):toIndex(index)}function calculateStepTimings(stepCount){return stepCount===1?[timings.single]:Array.from({length:stepCount},(_,i)=>i===0?timings.multiStart:i===stepCount-1?timings.multiEnd:timings.multiMiddle)}function calculateSteps(fromIndex,toIndex$1){let targetItemIndex=displayItems.value.findIndex(item=>item.originalIndex===toIndex$1),steps=[];if(targetItemIndex===-1){let current=fromIndex;for(;current!==toIndex$1;){let totalItems=shelfItems.value.length;props.noLoop?toIndex$1>current?current+=1:--current:current=(toIndex$1-current+totalItems)%totalItems<=(current-toIndex$1+totalItems)%totalItems?(current+1)%totalItems:(current-1+totalItems)%totalItems,steps.push(current)}}else{let targetPosition=displayItems.value[targetItemIndex].position;if(targetPosition!==0){let direction$1=targetPosition>0?1:-1,stepsNeeded=Math.abs(targetPosition),current=fromIndex;for(let i=0;i0?current+=1:--current:current=direction$1>0?(current+1)%shelfItems.value.length:(current-1+shelfItems.value.length)%shelfItems.value.length,steps.push(current)}}return steps}async function animateToStep(stepIndex,stepTiming){let halfLimit=Math.floor(props.limit/2),currentIndex=selectedIndex.value,actualDirection=0;if(props.noLoop)actualDirection=stepIndex>currentIndex?1:-1;else{let totalItems=shelfItems.value.length;actualDirection=(stepIndex-currentIndex+totalItems)%totalItems<=(currentIndex-stepIndex+totalItems)%totalItems?1:-1}let newItems=[];if(actualDirection>0){for(let i=0;i=shelfItems.value.length?rightmostIndex-shelfItems.value.length:rightmostIndex),wrappedIndex>=0&&wrappedIndex=0&&wrappedIndexhalfLimit;newItems.push({...currentItem,position:newPosition,style:getItemStyle(newPosition,isExiting?`exiting`:`normal`)})}}displayItems.value=newItems;let delay=stepTiming/2;await sleep(delay),displayItems.value=displayItems.value.map(item=>item.style.opacity===.1&&(item.position===halfLimit||item.position===-halfLimit)?{...item,style:getItemStyle(item.position,`normal`)}:item),await new Promise(resolve$1=>setTimeout(resolve$1,delay))}function navigateNext$1(){isAnimating.value||props.noLoop&&selectedIndex.value===shelfItems.value.length-1||toIndex((selectedIndex.value+1)%shelfItems.value.length)}function navigatePrev(){isAnimating.value||props.noLoop&&selectedIndex.value===0||toIndex(selectedIndex.value===0?shelfItems.value.length-1:selectedIndex.value-1)}__expose({toIndex,next:navigateNext$1,prev:navigatePrev,isSelected:evt=>{let elm=evt.target.closest(`[data-shelf-index]`);if(!elm)return!1;let idx=parseInt(elm.getAttribute(`data-shelf-index`),10);return!isNaN(idx)&&selectedIndex.value===idx}}),onMounted(()=>{ready.value=!0,nextTick(update$6)});function getActiveItem(){let active=document.activeElement;return String(active.dataset.shelfIndex)===String(selectedIndex.value)?null:containerRef.value.querySelector(`[data-shelf-index="${selectedIndex.value}"]`)}return(_ctx,_cache)=>withDirectives((openBlock(),createElementBlock(`div`,_hoisted_1$341,[withDirectives((openBlock(),createElementBlock(`div`,{ref_key:`containerRef`,ref:containerRef,class:`shelf-container`},[(openBlock(!0),createElementBlock(Fragment,null,renderList(displayItems.value,item=>(openBlock(),createElementBlock(`div`,{key:`item-${item.originalIndex}-${item.id}`,class:`shelf-item`,style:normalizeStyle(item.style)},[(openBlock(),createBlock(resolveDynamicComponent(item.vnode),{"data-shelf-index":item.originalIndex,onClick:$event=>onClick(item.originalIndex,$event),onFocus:$event=>onFocus(item.originalIndex),onUinavFocus:$event=>onFocus(item.originalIndex)},null,40,[`data-shelf-index`,`onClick`,`onFocus`,`onUinavFocus`]))],4))),128))])),[[unref(BngFocusCapture_default),getActiveItem,`101`]]),__props.navShown?(openBlock(),createElementBlock(`button`,{key:0,class:`shelf-nav shelf-nav-prev`,onClick:navigatePrev,disabled:isPrevDisabled.value},[createVNode(unref(bngIcon_default),{type:unref(icons).arrowLargeLeft},null,8,[`type`])],8,_hoisted_2$269)):createCommentVNode(``,!0),__props.navShown?(openBlock(),createElementBlock(`button`,{key:1,class:`shelf-nav shelf-nav-next`,onClick:navigateNext$1,disabled:isNextDisabled.value},[createVNode(unref(bngIcon_default),{type:unref(icons).arrowLargeRight},null,8,[`type`])],8,_hoisted_3$235)):createCommentVNode(``,!0)],512)),[[vShow,displayItems.value.length>0]])}},shelf_default=__plugin_vue_export_helper_default(_sfc_main$395,[[`__scopeId`,`data-v-0109573f`]]),_sfc_main$394={__name:`slotSwitcher`,props:{slotId:{type:String,default:`default`}},setup(__props){return(_ctx,_cache)=>renderSlot(_ctx.$slots,__props.slotId,normalizeProps(guardReactiveProps(_ctx.$attrs)))}},slotSwitcher_default=_sfc_main$394,_sfc_main$393={__name:`tab`,props:{heading:String,selected:Boolean},setup(__props){return(_ctx,_cache)=>renderSlot(_ctx.$slots,`default`,{tabHeading:__props.heading,tabSelected:__props.selected})}},tab_default=_sfc_main$393,_hoisted_1$340={class:`tab-list`},_sfc_main$392={__name:`tabList`,setup(__props){let tabs=inject(`tabs`),selectTab=inject(`selectTab`),tabHeaderClasses=tab=>({"tab-item":!0,"tab-active-tab":tab.active,"no-hover":tab.active});function handleTabSelect(index,event){let buttonElement=event.currentTarget,hasFocusVisible=document.activeElement&&document.activeElement.classList.contains(`focus-visible`);selectTab(index),hasFocusVisible&&nextTick(()=>{setFocusExternal(buttonElement)})}return(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$340,[(openBlock(!0),createElementBlock(Fragment,null,renderList(unref(tabs),(tab,i)=>(openBlock(),createBlock(unref(bngButton_default),{key:i,accent:(tab.active,`ghost`),class:normalizeClass(tabHeaderClasses(tab)),tabindex:`0`,"bng-nav-item":``,onClick:$event=>handleTabSelect(tab.index,$event)},{default:withCtx(()=>[createTextVNode(toDisplayString(tab.heading),1)]),_:2},1032,[`accent`,`class`,`onClick`]))),128))]))}},tabList_default=__plugin_vue_export_helper_default(_sfc_main$392,[[`__scopeId`,`data-v-5c322d77`]]),_hoisted_1$339={class:`tab-container`},_sfc_main$391={__name:`tabs`,props:{selectedIndex:{type:Number,default:-1}},emits:[`change`],setup(__props,{expose:__expose,emit:__emit}){let emit$1=__emit,props=__props,ready=ref(!1),slots=useSlots(),tabListStart=shallowRef(),tabListEnd=shallowRef(),tabsList=ref(),tabsContent=ref([]),selectedIndex=ref(-1),isTabList=vnode=>typeof vnode.type==`object`&&vnode.type.__name===tabList_default.__name;provide(`tabs`,tabsList),watch(()=>slots.default?.(),update$6,{immediate:!0}),watch(()=>props.selectedIndex,index=>selectTab(index));function update$6(vnodes){if(!ready.value)return;vnodes===void 0&&(vnodes=slots.default?.()),Array.isArray(vnodes)||(vnodes=[]);let tabListIndex=vnodes.findIndex(vn=>isTabList(vn));tabListStart.value=tabListIndex===0?vnodes[tabListIndex]:tabList_default,tabListEnd.value=tabListIndex===vnodes.length-1?vnodes[tabListIndex]:null,tabsContent.value=vnodes.filter(vn=>!isTabList(vn)).reduce((res,vnode)=>typeof vnode.type==`symbol`&&vnode.type.toString()===`Symbol(v-fgt)`?(res.push(...vnode.children),res):(res.push(vnode),res),[]),tabsList.value=tabsContent.value.map((tab,index)=>({index,heading:tab.props?.[`tab-heading`]||tab.props?.tabHeading||`Tab ${index+1}`,active:selectedIndex.value===-1?props.selectedIndex===index||!!tab.props?.[`tab-selected`]||!!tab.props?.tabSelected:selectedIndex.value===index}));let activeIndex=tabsList.value.findIndex(tab=>tab.active);selectTab(activeIndex>-1?activeIndex:0)}function selectTab(index){if(!ready.value||typeof index!=`number`||index<0||index>=tabsList.value.length||selectedIndex.value===index)return;let prevTab=tabsList.value[selectedIndex.value];tabsList.value.forEach(tab=>{tab.active=tab.index===index}),selectedIndex.value=index,emit$1(`change`,tabsList.value[index],prevTab)}return provide(`selectTab`,selectTab),__expose({goNext:()=>selectTab((selectedIndex.value+1)%tabsList.value.length),goPrev:()=>selectTab(Math.abs(selectedIndex.value-1)%tabsList.value.length),selectTab}),onMounted(()=>{ready.value=!0,nextTick(update$6)}),(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$339,[tabListStart.value?(openBlock(),createBlock(resolveDynamicComponent(tabListStart.value),{key:0})):createCommentVNode(``,!0),tabsContent.value[selectedIndex.value]?(openBlock(),createBlock(resolveDynamicComponent(tabsContent.value[selectedIndex.value]),{key:1,class:`tab-content`})):createCommentVNode(``,!0),tabListEnd.value?(openBlock(),createBlock(resolveDynamicComponent(tabListEnd.value),{key:2})):createCommentVNode(``,!0)]))}},tabs_default=__plugin_vue_export_helper_default(_sfc_main$391,[[`__scopeId`,`data-v-2ff63a4f`]]),_sfc_main$390={__name:`textScroller`,props:{scrollSpeed:{type:Number,default:3},initialPause:{type:Number,default:1},endingPause:{type:Number,default:1},fadeDuration:{type:Number,default:.2},watchContent:{type:Boolean,default:!1}},setup(__props){let props=__props,slots=useSlots(),events$3={start:[`uinav-focus`,`focus`,`mouseenter`],stop:[`uinav-blur`,`blur`,`mouseleave`]},elContainer=ref(null),elText=ref(null),scrollDistance=ref(0),translateX=ref(0),opacity=ref(1),isActive=ref(!1),isScrolling$1=ref(!1),styleOverrides={"button-icon":`.bng-button.l-icon, .bng-button.r-icon`},overrideClasses=ref([]),parentElement=null,fontSize=ref(16),scrollSpeed=computed(()=>props.scrollSpeed*fontSize.value),animTimer=null,animTimeout=(func,ms)=>(animTimer&&=(clearTimeout(animTimer),null),typeof func==`function`?(animTimer=setTimeout(()=>{animTimer=null,isScrolling$1.value&&func()},ms),animTimer):null),scrollStyles=computed(()=>({transform:`translateX(${translateX.value}px)`,opacity:opacity.value,transition:`opacity ${props.fadeDuration}s linear`+(isScrolling$1.value&&opacity.value>0?`, transform ${scrollDistance.value/scrollSpeed.value}s linear`:``)}));function animLoop(){isScrollable()&&(scrollDistance.value=getSize(),!(scrollDistance.value<=0)&&(opacity.value=1,animTimeout(()=>{translateX.value=-scrollDistance.value,animTimeout(()=>{opacity.value=0,animTimeout(()=>{translateX.value=0,nextTick(animLoop)},props.fadeDuration*1e3)},scrollDistance.value/scrollSpeed.value*1e3+props.endingPause*1e3)},Math.max(props.initialPause,props.fadeDuration)*1e3)))}function isScrollable(){if(!elContainer.value||!elText.value)return!1;let containerWidth=elContainer.value.clientWidth;return elText.value.scrollWidth>containerWidth}function getSize(){if(!elContainer.value||!elText.value)return 0;let containerWidth=elContainer.value.clientWidth,textWidth=elText.value.scrollWidth;return Math.max(0,textWidth-containerWidth)}function animStart(){isActive.value=!0,isScrollable()&&(isScrolling$1.value=!0,translateX.value=0,opacity.value=1,animLoop())}function animStop(restartAnim=!1){isActive.value=!1,isScrolling$1.value=!1,animTimeout(),nextTick(()=>{translateX.value=0,opacity.value=1,typeof restartAnim==`boolean`&&restartAnim&&nextTick(animStart)})}return props.watchContent&&watch(()=>slots.default?.(),()=>animStop(isActive.value),{deep:!0}),watch([()=>scrollSpeed.value,()=>props.initialPause,()=>props.endingPause,()=>props.fadeDuration],()=>animStop(isActive.value)),watch(()=>elContainer.value,()=>{if(!elContainer.value)return;for(parentElement=elContainer.value.parentElement;parentElement&&!parentElement.matches(`[is-bng-panel], [bng-nav-item], [ng-click], [href], [bng-all-clicks], [bng-all-clicks-no-nav], [ui-sref], input, textarea, button, md-option, md-slider, md-select, md-checkbox`);)if(parentElement=parentElement.parentElement,parentElement===document.body){parentElement=null;break}if(!parentElement)return;overrideClasses.value=[];for(let[key,selectors]of Object.entries(styleOverrides))parentElement.matches(selectors)&&overrideClasses.value.push(`bng-text-override--${key}`);let fSize=window.getComputedStyle(elContainer.value,null).fontSize;fontSize.value=+fSize.substring(0,fSize.length-2),events$3.start.forEach(event=>parentElement.addEventListener(event,animStart)),events$3.stop.forEach(event=>parentElement.addEventListener(event,animStop))},{immediate:!0}),onUnmounted(()=>{animTimeout(),parentElement&&(events$3.start.forEach(event=>parentElement.removeEventListener(event,animStart)),events$3.stop.forEach(event=>parentElement.removeEventListener(event,animStop)))}),(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,{ref_key:`elContainer`,ref:elContainer,class:normalizeClass([`bng-text-scroller`,[{"is-scrolling":isScrolling$1.value},...overrideClasses.value]])},[createBaseVNode(`div`,{ref_key:`elText`,ref:elText,class:`scroller-text`,style:normalizeStyle(scrollStyles.value)},[renderSlot(_ctx.$slots,`default`,{},void 0,!0)],4)],2))}},textScroller_default=__plugin_vue_export_helper_default(_sfc_main$390,[[`__scopeId`,`data-v-4f311fae`]]),_hoisted_1$338=[`data-tree-node-key`,`data-tree-node-expanded`,`data-tree-node-selected`,`data-tree-node-parent-path`,`data-tree-node-path`],_hoisted_2$268={key:1,class:`node`},_hoisted_3$234=[`disabled`],_hoisted_4$199={key:2,"data-tree-node-children":``},_sfc_main$389={__name:`treeNode`,props:{node:{type:Object,required:!0},keyName:{type:String,required:!0},parentNode:Object,selectMode:String,expandMode:String,expandedKeys:Array,selectedKeys:Array,parentPath:Array},setup(__props){let props=__props,$templates=inject(`$templates`),_expandFn=inject(`expandFn`),_selectFn=inject(`selectFn`),expanded=computed(()=>props.expandMode===`prop`?props.node.expanded:props.expandedKeys&&props.expandedKeys.includes(props.node[props.keyName])),expandable=computed(()=>!props.node.disabled&&props.node.children&&props.node.children.length>0),selected=computed(()=>props.selectMode?props.selectMode===`prop`?props.node.selected:props.selectedKeys&&props.selectedKeys.includes(props.node[props.keyName]):!1),selectable=computed(()=>!props.node.disabled&&props.selectMode&&props.node.selectable!==!1),path=computed(()=>props.parentPath?props.parentPath.concat(props.node[props.keyName]):[props.node[props.keyName]]),parentPathString=computed(()=>props.parentPath?props.parentPath.join(`/`):null),pathString=computed(()=>path.value.join(`/`)),nodeProps=computed(()=>({path:path.value,parentPath:props.parentPath}));return(_ctx,_cache)=>{let _component_TreeNode=resolveComponent(`TreeNode`,!0);return openBlock(),createElementBlock(`li`,{"data-tree-node-key":__props.node[__props.keyName],"data-tree-node-expanded":expanded.value,"data-tree-node-selected":selected.value,"data-tree-node-parent-path":parentPathString.value,"data-tree-node-path":pathString.value,"data-tree-node":``},[unref($templates).node?(openBlock(),createBlock(resolveDynamicComponent(unref($templates).node),{key:0,node:__props.node,parentNode:__props.parentNode,expanded:expanded.value,selected:selected.value,expand:()=>expandable.value?unref(_expandFn)(__props.node,nodeProps.value):{},select:()=>selectable.value?unref(_selectFn)(__props.node,nodeProps.value):{}},null,8,[`node`,`parentNode`,`expanded`,`selected`,`expand`,`select`])):(openBlock(),createElementBlock(`div`,_hoisted_2$268,[__props.node.children&&unref($templates).toggle?(openBlock(),createBlock(resolveDynamicComponent(unref($templates).toggle),{key:0,node:__props.node,parentNode:__props.parentNode,expanded:expanded.value,selected:selected.value,expand:()=>expandable.value?unref(_expandFn)(__props.node,nodeProps.value):{}},null,8,[`node`,`parentNode`,`expanded`,`selected`,`expand`])):(openBlock(),createElementBlock(`span`,{key:1,class:`node-toggle`,onClick:_cache[0]||=()=>expandable.value?unref(_expandFn)(__props.node,nodeProps.value):{},disabled:__props.node.disabled},[__props.node.children?(openBlock(),createBlock(unref(bngIcon_default),{key:0,"bng-nav-item":``,type:expanded.value?unref(icons).arrowSmallDown:unref(icons).arrowSmallRight},null,8,[`type`])):createCommentVNode(``,!0)],8,_hoisted_3$234)),unref($templates).content?(openBlock(),createBlock(resolveDynamicComponent(unref($templates).content),{key:2,node:__props.node,parentNode:__props.parentNode,expanded:expanded.value,selected:selected.value,expand:()=>expandable.value?unref(_expandFn)(__props.node,nodeProps.value):{},select:()=>selectable.value?unref(_selectFn)(__props.node,nodeProps.value):{}},null,8,[`node`,`parentNode`,`expanded`,`selected`,`expand`,`select`])):(openBlock(),createElementBlock(`span`,{key:3,"bng-nav-item":``,class:`node-content`,onClick:_cache[1]||=()=>selectable.value?unref(_selectFn)(__props.node,nodeProps.value):{}},toDisplayString(__props.node.label),1))])),expanded.value&&__props.node.children?(openBlock(),createElementBlock(`ul`,_hoisted_4$199,[(openBlock(!0),createElementBlock(Fragment,null,renderList(__props.node.children,childNode=>(openBlock(),createBlock(_component_TreeNode,{key:childNode[__props.keyName],node:childNode,parentNode:__props.node,keyName:__props.keyName,selectMode:__props.selectMode,expandMode:__props.expandMode,expandedKeys:__props.expandedKeys,selectedKeys:__props.selectedKeys,parentPath:path.value},null,8,[`node`,`parentNode`,`keyName`,`selectMode`,`expandMode`,`expandedKeys`,`selectedKeys`,`parentPath`]))),128))])):createCommentVNode(``,!0)],8,_hoisted_1$338)}}},treeNode_default=__plugin_vue_export_helper_default(_sfc_main$389,[[`__scopeId`,`data-v-aeb14cdb`]]),_hoisted_1$337={class:`tree`},SELECT_SINGLE=`single`,SELECT_MULTIPLE=`multi`,SELECT_PROP=`prop`,SELECT_MODES=[SELECT_SINGLE,SELECT_MULTIPLE,SELECT_PROP],EXPAND_MODEL=`model`,EXPAND_PROP=`prop`,EXPAND_MODES=[EXPAND_MODEL,EXPAND_PROP],_sfc_main$388={__name:`tree`,props:mergeModels({nodes:{type:Array,required:!0},keyName:{type:String,default:`key`},expandMode:{type:String,default:EXPAND_MODEL,validator(value){return EXPAND_MODES.includes(value)}},selectMode:{type:String,validator(value){return SELECT_MODES.includes(value)}}},{expandedKeys:{},expandedKeysModifiers:{},selectedKeys:{},selectedKeysModifiers:{}}),emits:mergeModels([`update:expandedKeys`,`node-expanded`,`node-collapsed`,`expanded-keys-changed`,`node-selected`,`node-unselected`,`selected-keys-changed`],[`update:expandedKeys`,`update:selectedKeys`]),setup(__props,{emit:__emit}){let props=__props,expandedKeys=useModel(__props,`expandedKeys`),selectedKeys=useModel(__props,`selectedKeys`),emit$1=__emit;onBeforeMount(()=>{provide(`$templates`,useSlots()),provide(`expandFn`,expand),provide(`selectFn`,select)});function expand(node,nodeProps){let nodeKey=node[props.keyName];if(props.expandMode===EXPAND_PROP)node.expanded?emit$1(`node-collapsed`,node,nodeProps):emit$1(`node-expanded`,node,nodeProps);else{if(!expandedKeys.value)throw Error(`v-model:expandedKeys must be set`);let expanded=expandedKeys.value.includes(nodeKey),updatedExpandedKeys;expanded?(updatedExpandedKeys=expandedKeys.value.filter(x=>x!==nodeKey),emit$1(`node-collapsed`,node,nodeProps)):(updatedExpandedKeys=[...expandedKeys.value,nodeKey],emit$1(`node-expanded`,node,nodeProps)),expandedKeys.value=updatedExpandedKeys,emit$1(`expanded-keys-changed`,updatedExpandedKeys)}}function select(node,nodeProps){console.log(`select`,node);let nodeKey=node[props.keyName];if(props.selectMode===SELECT_PROP)node.selected?emit$1(`node-selected`,node,nodeProps):emit$1(`node-unselected`,node,nodeProps);else{if(!selectedKeys.value)throw Error(`v-model:selectedKeys must be set`);let selected=selectedKeys.value.includes(nodeKey),updatedSelectedKeys;selected?(updatedSelectedKeys=selectedKeys.value.filter(x=>x!==nodeKey),emit$1(`node-unselected`,node,nodeProps)):props.selectMode===`single`?(updatedSelectedKeys=[nodeKey],emit$1(`node-selected`,node,nodeProps)):props.selectMode===`multi`&&(updatedSelectedKeys=[...selectedKeys.value,nodeKey],emit$1(`node-selected`,node,nodeProps)),selectedKeys.value=updatedSelectedKeys,emit$1(`selected-keys-changed`,updatedSelectedKeys)}}return(_ctx,_cache)=>(openBlock(),createElementBlock(`ul`,_hoisted_1$337,[(openBlock(!0),createElementBlock(Fragment,null,renderList(__props.nodes,node=>(openBlock(),createBlock(treeNode_default,{key:node[__props.keyName],node,keyName:__props.keyName,selectMode:__props.selectMode,expandMode:__props.expandMode,expandedKeys:expandedKeys.value,selectedKeys:selectedKeys.value},null,8,[`node`,`keyName`,`selectMode`,`expandMode`,`expandedKeys`,`selectedKeys`]))),128))]))}},tree_default=__plugin_vue_export_helper_default(_sfc_main$388,[[`__scopeId`,`data-v-7363528a`]]);const DEMOS$1={};var utility_exports=__export({Accordion:()=>accordion_default,AccordionItem:()=>accordionItem_default,AccordionTree:()=>accordionTree_default,AspectRatio:()=>aspectRatio_default,Carousel:()=>carousel_default,CarouselItem:()=>carouselItem_default,DEMOS:()=>DEMOS$1,DRAWER_POSITION:()=>DRAWER_POSITION,Drawer:()=>drawer_default,DynamicComponent:()=>dynamicComponent_default,Shelf:()=>shelf_default,SlotSwitcher:()=>slotSwitcher_default,Tab:()=>tab_default,TabList:()=>tabList_default,Tabs:()=>tabs_default,TextScroller:()=>textScroller_default,Tree:()=>tree_default,TreeNode:()=>treeNode_default}),_hoisted_1$336={class:`actions-drawer`},_sfc_main$387={__name:`bngActionsDrawer`,props:{header:{type:String,required:!0},headerActions:Array,showHeaderActions:{type:Boolean,default:!0},grouped:Boolean,actions:{type:[Array,Object],required:!0},selected:{type:[String,Number]},expanded:Boolean},emits:[`actionClick`,`headerActionClicked`,`categoryChanged`],setup(__props,{emit:__emit}){let emit$1=__emit,onActionClicked=action=>emit$1(`actionClick`,action);return(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$336,[createVNode(unref(bngDrawerOld_default),null,createSlots({header:withCtx(()=>[createTextVNode(toDisplayString(__props.header),1)]),content:withCtx(()=>[__props.grouped?(openBlock(),createBlock(unref(tabs_default),{key:0,class:`categories-tab bng-tabs`},{default:withCtx(()=>[(openBlock(!0),createElementBlock(Fragment,null,renderList(__props.actions,category=>(openBlock(),createBlock(unref(tab_default),{key:category.category,heading:category.category},{default:withCtx(()=>[(openBlock(),createBlock(unref(bngActionsList_default),{key:category.category,actions:category.items,selected:__props.selected,class:normalizeClass({expanded:__props.expanded}),onActionClick:_cache[0]||=value=>onActionClicked(value)},null,8,[`actions`,`selected`,`class`]))]),_:2},1032,[`heading`]))),128))]),_:1})):(openBlock(),createBlock(unref(bngActionsList_default),{key:1,actions:__props.actions,selected:__props.selected,class:normalizeClass({expanded:__props.expanded}),onActionClick:_cache[1]||=value=>onActionClicked(value)},null,8,[`actions`,`selected`,`class`]))]),_:2},[__props.showHeaderActions&&__props.headerActions?{name:`headerOptions`,fn:withCtx(()=>[(openBlock(!0),createElementBlock(Fragment,null,renderList(__props.headerActions,action=>(openBlock(),createBlock(unref(bngButton_default),{key:action.value,tabindex:`1`,accent:action.accent,onClick:$event=>_ctx.$emit(`headerActionClicked`,action.value)},{default:withCtx(()=>[createTextVNode(toDisplayString(action.label),1)]),_:2},1032,[`accent`,`onClick`]))),128))]),key:`0`}:void 0]),1024)]))}},bngActionsDrawer_default=__plugin_vue_export_helper_default(_sfc_main$387,[[`__scopeId`,`data-v-b433a352`]]),_hoisted_1$335={class:`header-wrapper`},_hoisted_2$267={class:`drawer-content`},_hoisted_3$233={key:0,class:`filters-wrapper`},_hoisted_4$198={class:`drawer-actions-wrapper`},_hoisted_5$168={key:0,class:`action-divider`},_hoisted_6$143={key:1,class:`progress-indicator`},_sfc_main$386={__name:`bngActionsDrawerOne`,props:{value:{type:Object,required:!0},flattenChildren:Boolean,allowOpenDrawer:Boolean,openDrawerLabel:String,closeDrawerLabel:String,loading:Boolean,header:String,blur:Boolean},emits:[`update:currentActionPath`,`update:loading`,`actionClicked`,`actionItemChanged`,`drawerOpened`],setup(__props,{emit:__emit}){let props=__props,emit$1=__emit,drawerState=reactive({isOpenCatalog:!1,currentPath:[],drawerFilters:[]}),currentActionPath=computed({get:()=>drawerState.currentPath,set:newValue=>{drawerState.currentPath=newValue}}),parentAction=computed(()=>{if(!currentActionPath.value||currentActionPath.value.length===0)return null;let currentAction$1=props.value;for(let key of currentActionPath.value.slice(0,-1))currentAction$1=currentAction$1.items.find(x=>x.value===key);return currentAction$1}),currentAction=computed(()=>{let currentAction$1=props.value;for(let key of currentActionPath.value)currentAction$1=currentAction$1.items.find(x=>x.value===key);return currentAction$1}),isDrawerOpen=computed({get:()=>drawerState.isOpenCatalog,set:newValue=>{drawerState.isOpenCatalog=newValue,emit$1(`drawerOpened`,newValue)}}),loading=computed({get:()=>props.loading,set:newValue=>emit$1(`update:loading`,newValue)}),canViewCatalogDisplayMode=computed(()=>(console.log(`canViewCatalogDisplayMode`),loading.value===!0||currentAction.value.allowOpenDrawer===!1?!1:(console.log(`currentAction`,currentAction.value),currentAction.value.items.every(x=>x.lazyLoadItems===!0||x.items)))),drawerFilterValue=computed({get:()=>drawerState.drawerFilters&&drawerState.drawerFilters.length>0?drawerState.drawerFilters[0]:null,set:newValue=>{drawerState.drawerFilters=newValue?[newValue]:[]}}),catalogFilters=computed(()=>{let activeAction=isDrawerOpen.value?parentAction.value:currentAction.value;return activeAction.items.every(x=>x.items&&x.items.length>0||x.lazyLoadItems)?activeAction.items.map(x=>({label:x.label,value:x.value})):[]}),showBackButton=computed(()=>currentActionPath.value.length>0);watch(drawerFilterValue,(newValue,oldValue)=>{console.log(`drawerFilterValue`,newValue,oldValue),newValue&&!oldValue?currentActionPath.value=[...currentActionPath.value,newValue]:newValue&&oldValue?currentActionPath.value=[...currentActionPath.value.slice(0,-1),newValue]:!newValue&&oldValue&&(currentActionPath.value=[...currentActionPath.value].slice(0,-1))}),watch(currentActionPath,()=>{emit$1(`actionItemChanged`,currentAction.value,currentActionPath.value)});let selectAction=actionItem=>{(actionItem.items&&actionItem.items.length>0||actionItem.lazyLoadItems===!0)&&(isDrawerOpen.value&&=!1,currentActionPath.value=[...currentActionPath.value,actionItem.value]),emit$1(`actionClicked`,actionItem)},toggleOpenCatalog=()=>{isDrawerOpen.value?closeDrawer():openDrawer()},goBack=()=>{isDrawerOpen.value?closeDrawer():currentActionPath.value=[...currentActionPath.value].slice(0,-1)};function openDrawer(){drawerFilterValue.value=catalogFilters.value[0].value,isDrawerOpen.value=!0}function closeDrawer(){drawerFilterValue.value=null,isDrawerOpen.value=!1}return(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,{class:normalizeClass([`bng-actions-drawer`,{expanded:isDrawerOpen.value}])},[createVNode(unref(bngDrawerOld_default),{blur:__props.blur,class:`bng-drawer`},{header:withCtx(()=>[renderSlot(_ctx.$slots,`header`,{actionItem:currentAction.value,canGoBack:showBackButton.value,goBack},()=>[createBaseVNode(`div`,_hoisted_1$335,[showBackButton.value?(openBlock(),createBlock(unref(bngButton_default),{key:0,icon:unref(icons).arrowLargeLeft,accent:unref(ACCENTS).secondary,class:`back-btn`,onClick:goBack},{default:withCtx(()=>[..._cache[1]||=[createTextVNode(`Back`,-1)]]),_:1},8,[`icon`,`accent`])):createCommentVNode(``,!0),createTextVNode(` `+toDisplayString(currentAction.value.label),1)])],!0)]),content:withCtx(()=>[createBaseVNode(`div`,_hoisted_2$267,[drawerState.isOpenCatalog&&catalogFilters.value.length>0?(openBlock(),createElementBlock(`div`,_hoisted_3$233,[createVNode(unref(bngPillFilters_default),{modelValue:drawerState.drawerFilters,"onUpdate:modelValue":_cache[0]||=$event=>drawerState.drawerFilters=$event,options:catalogFilters.value},null,8,[`modelValue`,`options`])])):createCommentVNode(``,!0),createBaseVNode(`div`,_hoisted_4$198,[createBaseVNode(`div`,{class:normalizeClass([`drawer-actions`,{expanded:drawerState.isOpenCatalog}])},[loading.value?(openBlock(),createElementBlock(`div`,_hoisted_6$143,[..._cache[2]||=[createBaseVNode(`div`,{class:`loader`},null,-1)]])):(openBlock(!0),createElementBlock(Fragment,{key:0},renderList(currentAction.value.items,action=>(openBlock(),createElementBlock(Fragment,{key:action.value},[action.type===`actionDivider`?(openBlock(),createElementBlock(`div`,_hoisted_5$168,toDisplayString(action.label),1)):renderSlot(_ctx.$slots,`item`,{key:1,actionItem:action,onClick:()=>selectAction(action)},()=>[createVNode(unref(bngImageTile_default),{label:action.label,icon:action.icon,onClick:$event=>selectAction(action)},null,8,[`label`,`icon`,`onClick`])],!0)],64))),128))],2)]),canViewCatalogDisplayMode.value?renderSlot(_ctx.$slots,`footer`,{key:1},()=>[createVNode(unref(bngButton_default),{class:`catalog-btn`,accent:unref(ACCENTS).outlined,onClick:toggleOpenCatalog},{default:withCtx(()=>[drawerState.isOpenCatalog?(openBlock(),createElementBlock(Fragment,{key:0},[createTextVNode(toDisplayString(__props.closeDrawerLabel?__props.closeDrawerLabel:`Collapse catalog`),1)],64)):(openBlock(),createElementBlock(Fragment,{key:1},[createTextVNode(toDisplayString(__props.openDrawerLabel?__props.openDrawerLabel:`Open full catalog`),1)],64))]),_:1},8,[`accent`])],!0):createCommentVNode(``,!0)])]),_:3},8,[`blur`])],2))}},bngActionsDrawerOne_default=__plugin_vue_export_helper_default(_sfc_main$386,[[`__scopeId`,`data-v-529c2a59`]]),_hoisted_1$334={class:`actions`},_sfc_main$385={__name:`bngActionsList`,props:{actions:{type:Array,required:!0},selected:{type:[String,Number],required:!1}},emits:[`actionClick`],setup(__props,{emit:__emit}){let emit$1=__emit;return(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$334,[(openBlock(!0),createElementBlock(Fragment,null,renderList(__props.actions,action=>(openBlock(),createBlock(unref(bngImageTile_default),mergeProps({class:`action-tile`,tabindex:`0`,key:action.value},{ref_for:!0},action,{"bng-nav-item":``,onClick:$event=>emit$1(`actionClick`,action.value)}),null,16,[`onClick`]))),128))]))}},bngActionsList_default=__plugin_vue_export_helper_default(_sfc_main$385,[[`__scopeId`,`data-v-8790d45d`]]),_hoisted_1$333=[`ui-event`],_hoisted_2$266={key:0},_hoisted_3$232={key:3,class:`combo-separator`},MULTI_ID=`[PLUS]`,MULTI_LABEL=`+`,_sfc_main$384={__name:`bngBinding`,props:{action:String,showUnassigned:Boolean,device:[String,Array],deviceKey:String,dark:Boolean,deviceMask:[String,Function],controller:Boolean,uiEvent:String,trackIgnore:Boolean,unassignedText:{default:`[N/A]`,type:String},viewerObj:Object,imagePack:String,actionVariants:Boolean,useLastDevice:{type:Boolean,default:!0},vertical:Boolean},setup(__props,{expose:__expose}){let $simplemenu=inject(`$simplemenu`),Controls=controls_default(),{showIfController,lastControllersSignature}=storeToRefs(Controls),props=__props,iconColors={dark:`var(--bng-off-black)`,light:`var(--bng-off-white)`},iconColor=computed(()=>iconColors[props.dark?`dark`:`light`]);computed(()=>iconColors[props.dark?`light`:`dark`]);let controllerOnly=computed(()=>props.controller||$simplemenu.value),LABELS_BIG=[`enter`,`tab`,`capslock`,`backspace`,`lshift`,`rshift`,`left`,`right`,`up`,`down`,`space`,`grave`,`comma`,`period`].map(c=>CONTROL_LABELS[c]||c),LABELS_OFFSET=[`space`].map(c=>CONTROL_LABELS[c]||c),rgxSanitize$1=s=>s.replace(/[-.+*$^?:|[\](){}]/g,`\\$&`),LABELS_RGX=RegExp(`(`+[MULTI_ID,...LABELS_BIG,...LABELS_OFFSET].map(rgxSanitize$1).join(`|`)+`)`,`g`),viewerObj=computed(()=>{if(props.viewerObj)return props.viewerObj;if(controllerOnly.value&&showIfController.value){let opts={...props};return opts.controller=!0,opts._controllerSignature=lastControllersSignature.value,Controls.makeViewerObj(opts)}return Controls.makeViewerObj(props)}),viewerVariants=computed(()=>{if(!viewerObj.value)return[];let variants=viewerObj.value.variants||[viewerObj.value];variants=variants.map(obj=>obj.multiControls||[obj]);for(let objs of variants)for(let obj of objs)if(obj&&(!obj.special||obj.ownLabel)&&!obj.controlSegments){let control=obj.ownLabel||obj.control;control=control.replace(/ \+ /g,MULTI_ID),obj.controlSegments=String(control).split(LABELS_RGX).filter(Boolean).map(segment=>({value:segment===MULTI_ID?MULTI_LABEL:segment,class:(LABELS_BIG.includes(segment)?`label-bigger `:``)+(LABELS_OFFSET.includes(segment)?`label-offset `:``)+(segment===MULTI_ID?`label-multi `:``)}))}return variants}),display=computed(()=>{let res=!!viewerObj.value;if(viewerObj.value)if(props.deviceMask){let dev=viewerObj.value.devName;res=typeof props.deviceMask==`function`?props.deviceMask(dev):dev.startsWith(props.deviceMask)}else controllerOnly.value&&(res=showIfController.value);return res||props.showUnassigned});__expose({displayed:display});let eventName=computed(()=>props.action?props.action:props.uiEvent?props.uiEvent:null),uiNavTracker=useUINavTracker(),ownerId$1=uniqueId(`bngBinding`),trackedEvent=``,track$1=(eventName$1=null)=>{if(trackedEvent&&=(uiNavTracker.removeIgnore(trackedEvent,ownerId$1),``),!(props.trackIgnore||!display.value)&&eventName$1){if(trackedEvent===eventName$1)return;trackedEvent=eventName$1,uiNavTracker.addIgnore(trackedEvent,ownerId$1)}};return watch(()=>props.trackIgnore,val=>track$1(val?null:eventName.value)),watch(display,()=>track$1(eventName.value)),watch(eventName,(val,prev)=>{prev&&track$1(),val&&track$1(val)}),onMounted(()=>track$1(eventName.value)),onUnmounted(()=>track$1()),(_ctx,_cache)=>display.value?(openBlock(),createElementBlock(`span`,{key:0,class:normalizeClass([`binding-wrapper`,{"binding-theme-dark":__props.dark,"binding-theme-light":!__props.dark,"with-variants":viewerVariants.value.length>1,vertical:__props.vertical}]),"ui-event":__props.uiEvent},[(openBlock(!0),createElementBlock(Fragment,null,renderList(viewerVariants.value,(viewerObjs,index)=>(openBlock(),createElementBlock(`span`,{key:index,class:normalizeClass([`binding-container`,{"combo-binding":viewerObjs.length>1}])},[(openBlock(!0),createElementBlock(Fragment,null,renderList(viewerObjs,(viewerObj$1,index$1)=>(openBlock(),createElementBlock(Fragment,{key:index$1},[viewerObj$1&&viewerObj$1.controlSegments?(openBlock(),createElementBlock(`kbd`,_hoisted_2$266,[(openBlock(!0),createElementBlock(Fragment,null,renderList(viewerObj$1.controlSegments,(seg,i)=>(openBlock(),createElementBlock(`span`,{key:i,class:normalizeClass(seg.class)},toDisplayString(seg.value),3))),128))])):viewerObj$1&&viewerObj$1.special?(openBlock(),createBlock(unref(bngIcon_default),{key:1,class:`bng-binding-icon`,type:unref(icons)[viewerObj$1.ownIcon],color:iconColor.value},null,8,[`type`,`color`])):!viewerObj$1&&__props.showUnassigned?(openBlock(),createBlock(unref(bngIcon_default),{key:2,class:`bng-binding-icon n-a`,type:unref(icons).NA,color:iconColor.value},null,8,[`type`,`color`])):createCommentVNode(``,!0),index$1Number(val)>0},simple:Boolean,blur:Boolean,disableLastItem:Boolean,showBackButton:Boolean,showBackBinding:{type:Boolean,default:!0},navigable:{type:Boolean,default:!0}},emits:[`click`,`back`],setup(__props,{emit:__emit}){let bid=uniqueId(`bng-path`),emit$1=__emit,props=__props,pathView=computed(()=>{if(!Array.isArray(props.items))return[];let mapItem=itm=>({label:itm.label,items:itm.items,data:itm,dividerType:itm.dividerType}),items$2=props.items.map(mapItem),res=props.limit?items$2.slice(-props.limit):items$2;if(!props.simple){let looseCmp=(a$1,b)=>a$1.label===b.label&&a$1.value===b.value,len=res.length;for(let i=1;ilooseCmp(itm,res[idx])),items:items$3.map(mapItem)})}}return props.limit&&items$2.length>props.limit&&res.unshift({label:`…`,data:items$2[items$2.length-props.limit-1]}),res.length>0&&(res[0].first=!0,res.at(-1).last=!0),res});function onClick(item,index){(!props.disableLastItem||index(openBlock(),createElementBlock(`div`,{class:`bng-path`,"bng-no-child-nav":!__props.navigable},[__props.showBackButton?(openBlock(),createBlock(unref(bngButton_default),{key:0,class:`back-button`,accent:unref(ACCENTS).custom,onClick:_cache[0]||=$event=>emit$1(`back`),tabindex:`1`},{default:withCtx(()=>[createVNode(unref(bngIcon_default),{type:unref(icons).arrowSmallLeft,class:`back-icon`},null,8,[`type`]),__props.showBackBinding?(openBlock(),createBlock(unref(bngBinding_default),{key:0,"ui-event":`back`,controller:``,"track-ignore":``})):createCommentVNode(``,!0),createTextVNode(` `+toDisplayString(_ctx.$tt(`ui.common.back`)),1)]),_:1},8,[`accent`])):createCommentVNode(``,!0),(openBlock(!0),createElementBlock(Fragment,null,renderList(pathView.value,(item,index)=>(openBlock(),createElementBlock(Fragment,{key:index},[item.dropdown?(openBlock(),createElementBlock(Fragment,{key:1},[withDirectives(createVNode(unref(bngButton_default),{class:`bng-path-item bng-path-has-dropdown`,accent:unref(ACCENTS).text,icon:unref(icons).arrowSmallRight},null,8,[`accent`,`icon`]),[[unref(BngBlur_default),__props.blur],[unref(BngPopover_default),item.dropdown,`bottom-start`,{click:!0}]]),createVNode(unref(bngPopoverMenu_default),{name:item.dropdown,focus:``},{default:withCtx(({hide:hide$2})=>[(openBlock(!0),createElementBlock(Fragment,null,renderList(item.items,(subitem,idx)=>withDirectives((openBlock(),createBlock(unref(bngButton_default),{key:idx,class:normalizeClass({selected:idx===item.selected}),accent:unref(ACCENTS).menu,onClick:$event=>onMenuClick(subitem,hide$2)},{default:withCtx(()=>[createTextVNode(toDisplayString(subitem.label),1)]),_:2},1032,[`class`,`accent`,`onClick`])),[[unref(BngOnUiNav_default),void 0,`ok`,{focusRequired:!0,asMouse:!0}]])),128))]),_:2},1032,[`name`])],64)):(openBlock(),createElementBlock(Fragment,{key:0},[withDirectives((openBlock(),createBlock(unref(bngButton_default),{class:normalizeClass([`bng-path-item`,{"bng-path-simple":__props.simple,"bng-path-disabled":__props.disableLastItem&&item.last,"bng-path-first":item.first,"bng-path-last":item.last}]),accent:unref(ACCENTS).text,onClick:$event=>onClick(item,index)},{default:withCtx(()=>[createTextVNode(toDisplayString(item.label),1)]),_:2},1032,[`class`,`accent`,`onClick`])),[[unref(BngBlur_default),__props.blur]]),__props.simple&&!item.last?(openBlock(),createElementBlock(`div`,_hoisted_2$265,[withDirectives(createVNode(unref(bngIcon_default),{type:item.dividerType||unref(icons).slashRight},null,8,[`type`]),[[unref(BngBlur_default),__props.blur]])])):createCommentVNode(``,!0)],64))],64))),128))],8,_hoisted_1$332))}},bngBreadcrumbs_default=__plugin_vue_export_helper_default(_sfc_main$383,[[`__scopeId`,`data-v-4a2e18d5`]]),_hoisted_1$331=[`accent`,`disabled`],_hoisted_2$264={key:0,class:`hold-arrow`,xmlns:`http://www.w3.org/2000/svg`,viewBox:`0 0 16 12`,preserveAspectRatio:`xMidYMid`},_hoisted_3$231={key:3,class:`label`},_hoisted_4$197={key:5,class:`label`},_hoisted_5$167={key:6};const ACCENTS={main:`main`,secondary:`secondary`,outlined:`outlined`,text:`text`,attention:`attention`,attentionghost:`attentionghost`,attentionoutlined:`attentionoutlined`,ghost:`ghost`,menu:`menu`,custom:`custom`};var _sfc_main$382={__name:`bngButton`,props:{accent:{type:String,default:`main`,validator:v=>Object.values(ACCENTS).includes(v)||v===``},iconLeft:[Object,String],iconRight:[Object,String],label:String,icon:[Object,String],externalIcon:String,showHold:Boolean,holdVertical:Boolean,disabled:Boolean,noSound:Boolean},setup(__props,{expose:__expose}){let slots=useSlots(),uiNavEvent=ref(),btnDOMElRef=ref(),attrs=useAttrs(),useOldIcons=computed(()=>`oldIcons`in attrs);watchUINavEventChange(btnDOMElRef,({eventName,action})=>{}),__expose({getElement(){return btnDOMElRef.value}});let isPlainTextSlot=ref(!1);function checkIfPlainText(){let slotContent=slots.default?slots.default():[];isPlainTextSlot.value=slotContent.length===1&&typeof slotContent[0].type==`symbol`&&String(slotContent[0].type).indexOf(`v-txt`)>-1&&slotContent[0].children.trim().length>0}watch(()=>slots.default,checkIfPlainText),checkIfPlainText();let props=__props,needsFallbackHoldOffset=ref(!0);return watchEffect(()=>{btnDOMElRef.value&&props.accent===`custom`&&window.getComputedStyle(btnDOMElRef.value).getPropertyValue(`--bng-button-custom-hold-offset`).trim()&&(needsFallbackHoldOffset.value=!1)}),(_ctx,_cache)=>withDirectives((openBlock(),createElementBlock(`button`,{ref_key:`btnDOMElRef`,ref:btnDOMElRef,accent:__props.accent,class:normalizeClass({"show-hold":__props.showHold,"hold-vertical":__props.holdVertical,"bng-button":!0,empty:!unref(slots).default&&!__props.label,"l-icon":__props.iconLeft||__props.icon,"r-icon":__props.iconRight,"external-icon":__props.externalIcon,"fallback-hold-offset":props.accent===`custom`&&needsFallbackHoldOffset.value}),disabled:__props.disabled},[__props.showHold?(openBlock(),createElementBlock(`svg`,_hoisted_2$264,[..._cache[0]||=[createBaseVNode(`path`,{d:`M1,1 L8,2 L16,1 L8,11 z`},null,-1)]])):createCommentVNode(``,!0),useOldIcons.value&&(__props.iconLeft||__props.icon)?(openBlock(),createBlock(unref(bngOldIcon_default),{key:1,type:__props.iconLeft||__props.icon},null,8,[`type`])):!useOldIcons.value&&(__props.iconLeft||__props.icon||__props.externalIcon)?(openBlock(),createBlock(unref(bngIcon_default),{key:2,class:`icon`,type:__props.iconLeft||__props.icon,externalImage:__props.externalIcon},null,8,[`type`,`externalImage`])):createCommentVNode(``,!0),isPlainTextSlot.value?(openBlock(),createElementBlock(`span`,_hoisted_3$231,[renderSlot(_ctx.$slots,`default`,{},void 0,!0)])):isPlainTextSlot.value?createCommentVNode(``,!0):renderSlot(_ctx.$slots,`default`,{key:4},void 0,!0),__props.label&&!isPlainTextSlot.value?(openBlock(),createElementBlock(`span`,_hoisted_4$197,toDisplayString(__props.label),1)):createCommentVNode(``,!0),uiNavEvent.value?(openBlock(),createElementBlock(`span`,_hoisted_5$167,toDisplayString(uiNavEvent.value),1)):createCommentVNode(``,!0),useOldIcons.value&&__props.iconRight?(openBlock(),createBlock(unref(bngOldIcon_default),{key:7,span:``,type:__props.iconRight},null,8,[`type`])):!useOldIcons.value&&__props.iconRight?(openBlock(),createBlock(unref(bngIcon_default),{key:8,class:`icon`,type:__props.iconRight},null,8,[`type`])):createCommentVNode(``,!0),_cache[1]||=createBaseVNode(`div`,{class:`background`},null,-1)],10,_hoisted_1$331)),[[unref(BngSoundClass_default),!__props.disabled&&!__props.noSound&&`bng_click_hover_generic`]])}},bngButton_default=__plugin_vue_export_helper_default(_sfc_main$382,[[`__scopeId`,`data-v-8b356414`]]),_hoisted_1$330={class:`card-cnt`},ANIMATION_TYPES=[`fade`,`slide`],_sfc_main$381={__name:`bngCard`,props:{backgroundImage:String,footerStyles:Object,hideFooter:Boolean,animateFooter:Boolean,animateFooterType:{type:String,default:`fade`,validator:value=>ANIMATION_TYPES.includes(value)}},setup(__props,{expose:__expose}){useCssVars(_ctx=>({v3c03b7b2:backgroundImageStyle.value}));let props=__props,slots=useSlots(),hasFooter=computed(()=>(slots.footer||slots.buttons)&&!props.hideFooter),buttonsContainer=ref(),backgroundImageStyle=computed(()=>props.backgroundImage?`url('${props.backgroundImage}')`:``);return __expose({buttonsContainer}),(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,{class:normalizeClass([`bng-card bng-card-wrapper`,{"with-background-image":backgroundImageStyle.value}])},[createBaseVNode(`div`,_hoisted_1$330,[renderSlot(_ctx.$slots,`default`,{},()=>[_cache[0]||=createTextVNode(`BNG Card`,-1)],!0)]),createVNode(Transition,{name:__props.animateFooter?__props.animateFooterType:``},{default:withCtx(()=>[hasFooter.value?(openBlock(),createElementBlock(`div`,{key:0,ref_key:`buttonsContainer`,ref:buttonsContainer,class:`footer-container`,style:normalizeStyle(__props.footerStyles)},[renderSlot(_ctx.$slots,`buttons`,{},void 0,!0),renderSlot(_ctx.$slots,`footer`,{},void 0,!0)],4)):createCommentVNode(``,!0)]),_:3},8,[`name`])],2))}},bngCard_default=__plugin_vue_export_helper_default(_sfc_main$381,[[`__scopeId`,`data-v-32edaae4`]]),_sfc_main$380={__name:`bngCardHeading`,props:{type:{type:String,default:`line`,validator:v=>[`line`,`ribbon`,`none`].includes(v)||v===``},outline:{type:Boolean,default:!1}},setup(__props){return(_ctx,_cache)=>(openBlock(),createElementBlock(`h2`,{class:normalizeClass({"card-heading":!0,[`heading-style-${__props.type}`]:!0,outline:__props.outline})},[renderSlot(_ctx.$slots,`default`,{},()=>[_cache[0]||=createTextVNode(`BNG Card Heading`,-1)],!0)],2))}},bngCardHeading_default=__plugin_vue_export_helper_default(_sfc_main$380,[[`__scopeId`,`data-v-fc76db37`]]),_hoisted_1$329={key:0,class:`colour-picker-switch`};const VIEWS={simple:{slider:!0,picker:!1,saturation:!1,luminosity:!1},compact_saturation:{slider:!0,picker:!0,saturation:!0,luminosity:!1,compact:!0},compact_luminosity:{slider:!0,picker:!0,saturation:!1,luminosity:!0,compact:!0},saturation:{slider:!1,picker:!0,saturation:!0,luminosity:!1},luminosity:{slider:!1,picker:!0,saturation:!1,luminosity:!0},full_saturation:{slider:!0,picker:!0,saturation:!0,luminosity:!1},full_luminosity:{slider:!0,picker:!0,saturation:!1,luminosity:!0}};var valuesDef={hue:.5,saturation:1,luminosity:.5},_sfc_main$379={__name:`bngColorPicker`,props:{modelValue:{type:Object,default:{...valuesDef}},view:{type:[String,Object],default:`full_luminosity`,validator:val=>typeof val==`string`||val in VIEWS},showText:{type:Boolean,default:!0},step:{type:Number,default:.001},disabled:Boolean},emits:[`update:modelValue`,`change`],setup(__props,{emit:__emit}){let $simplemenu=inject(`$simplemenu`),props=__props,sliderIndicator=`popout`,pickerMode=ref(`luminosity`),opts=ref({}),values=reactive({...valuesDef}),colorDot=ref({x:0,y:0});watch([()=>props.view,$simplemenu],()=>{if(typeof props.view==`string`)for(let key in VIEWS[props.view])opts.value[key]=VIEWS[props.view][key];else opts.value={...VIEWS[props.view]};$simplemenu.value?(opts.value.picker=!1,opts.value.compact&&(opts.value.slider=!0)):opts.value.compact&&loadCompactMode(),opts.value.picker&&setColorDot()},{immediate:!0});function updColour(){for(let key in values)values[key]=props.modelValue[key];opts.value.picker&&setColorDot()}watch(()=>props.modelValue,updColour),watch(()=>props.modelValue.hue,updColour),watch(()=>props.modelValue.saturation,updColour),watch(()=>props.modelValue.luminosity,updColour);let current=computed(()=>({hue:~~(values.hue*360),saturation:~~(values.saturation*100),luminosity:~~(values.luminosity*100)})),emitter=__emit;function notify(){for(let key in values)props.modelValue[key]=values[key];emitter(`change`,props.modelValue),emitter(`update:modelValue`,props.modelValue)}let hueLoop=[...Array(7)].map((_,i)=>i/6*360),gradients=reactive({hueStatic:hueLoop.map(hue=>`hsl(${hue}, 100%, 50%)`),hue:computed(()=>hueLoop.map(hue=>`hsl(${hue}, 100%, 50%)`)),overlaySaturation:[`hsla(0, 0%,  0%, 0)`,`hsla(0, 0%, 50%, 1)`],overlayLuminosity:[`hsla(0, 0%, 100%, 1)`,`hsla(0, 0%, 100%, 0) 50%`,`hsla(0, 0%,   0%, 0) 50%`,`hsla(0, 0%,   0%, 1)`],pickerOverlay:computed(()=>opts.value.saturation?gradients.overlaySaturation:gradients.overlayLuminosity),saturation:computed(()=>[`hsl(${current.value.hue},   0%, ${current.value.luminosity}%)`,`hsl(${current.value.hue}, 100%, ${current.value.luminosity}%)`]),luminosity:computed(()=>[`hsl(${current.value.hue}, ${current.value.saturation}%,   0%)`,`hsl(${current.value.hue}, ${current.value.saturation}%,  50%)`,`hsl(${current.value.hue}, ${current.value.saturation}%, 100%)`])}),isMousedown=!1;function onMousedown(){isMousedown=!0}function onMousemove(evt){updateColor(evt)}function onMouseupLeave(evt){updateColor(evt,!0)}function getPosition(evt){let rect=evt.target.getBoundingClientRect();return rect.width<20?colorDot.value:{x:(evt.x-rect.left)/rect.width*100,y:(evt.y-rect.top)/rect.height*100}}function updateColor(evt,mouseLeave=!1){if(!isMousedown)return;mouseLeave&&(isMousedown=!1);let pos=getPosition(evt);values.hue=Math.max(0,Math.min(pos.x,100))/100;let secondary=1-Math.max(0,Math.min(pos.y,100))/100;opts.value.saturation?values.saturation=secondary:values.luminosity=secondary,setColorDot(),nextTick(notify)}function setColorDot(){colorDot.value={x:values.hue*100,y:(1-(opts.value.saturation?values.saturation:values.luminosity))*100}}function toggleCompactMode(){opts.value.slider=!opts.value.slider,opts.value.picker=!opts.value.picker,saveCompactMode()}function togglePickerMode(){pickerMode.value=pickerMode.value===`luminosity`?`saturation`:`luminosity`,opts.value.luminosity=pickerMode.value===`luminosity`,opts.value.saturation=pickerMode.value===`saturation`,saveCompactMode()}function loadCompactMode(){let readOption=(name,val=null)=>JSON.parse(localStorage.getItem(name)||JSON.stringify(val));opts.value.picker=readOption(`bngColorPicker-picker`,!0),opts.value.slider=readOption(`bngColorPicker-slider`,!1),pickerMode.value=readOption(`bngColorPicker-picker-mode`,`luminosity`),opts.value.luminosity=pickerMode.value===`luminosity`,opts.value.saturation=pickerMode.value===`saturation`,!opts.value.luminosity&&!opts.value.saturation&&(opts.value.luminosity=!0)}function saveCompactMode(){let saveOption=(name,val)=>localStorage.setItem(name,JSON.stringify(val));saveOption(`bngColorPicker-picker`,opts.value.picker),saveOption(`bngColorPicker-slider`,opts.value.slider),saveOption(`bngColorPicker-picker-mode`,pickerMode.value)}return onMounted(()=>{updColour(),!$simplemenu.value&&opts.value.compact&&loadCompactMode()}),(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,{class:normalizeClass({"colour-picker-container":!0,"colour-picker-mode-picker":opts.value.picker,"colour-picker-mode-slider":opts.value.slider,"colour-picker-mode-compact":opts.value.compact})},[opts.value.compact?(openBlock(),createElementBlock(`div`,_hoisted_1$329,[_cache[3]||=createBaseVNode(`span`,null,`Custom color`,-1),!unref($simplemenu)&&opts.value.picker?withDirectives((openBlock(),createBlock(unref(bngButton_default),{key:0,accent:unref(ACCENTS).text,icon:unref(icons).materialTransparency01,onClick:togglePickerMode},null,8,[`accent`,`icon`])),[[unref(BngTooltip_default),`Toggle vertical axis mode to ${pickerMode.value===`luminosity`?`saturation`:`brightness`}`,`top`]]):createCommentVNode(``,!0),unref($simplemenu)?createCommentVNode(``,!0):withDirectives((openBlock(),createBlock(unref(bngButton_default),{key:1,accent:opts.value.picker?unref(ACCENTS).outlined:unref(ACCENTS).text,icon:opts.value.picker?unref(icons).materialGlossy:unref(icons).listSmall,onClick:toggleCompactMode},null,8,[`accent`,`icon`])),[[unref(BngTooltip_default),`Toggle picker/slider mode`,`top`]])])):createCommentVNode(``,!0),opts.value.picker?withDirectives((openBlock(),createElementBlock(`div`,{key:1,class:`colour-picker`,onMousemove,onMousedown,onMouseup:onMouseupLeave,onMouseleave:onMouseupLeave,style:normalizeStyle({"--colour-picker-x":`linear-gradient(90deg, ${gradients.hueStatic.join(`, `)})`,"--colour-picker-y":`linear-gradient(180deg, ${gradients.pickerOverlay.join(`, `)})`})},[createBaseVNode(`div`,{class:`colour-picker-dot`,style:normalizeStyle({left:`${colorDot.value.x}%`,top:`${colorDot.value.y}%`,"--colour-picker-dot-fill":`hsl(${current.value.hue}, ${opts.value.saturation?current.value.saturation:100}%, ${opts.value.luminosity?current.value.luminosity:50}%)`})},null,4)],36)),[[unref(BngDisabled_default),__props.disabled]]):createCommentVNode(``,!0),opts.value.slider||opts.value.hue?(openBlock(),createBlock(unref(bngColorSlider_default),{key:2,modelValue:values.hue,"onUpdate:modelValue":_cache[0]||=$event=>values.hue=$event,modelModifiers:{number:!0},onChange:notify,fill:gradients.hue,current:`hsl(${current.value.hue}, 100%, 50%)`,indicator:sliderIndicator,step:__props.step,disabled:__props.disabled},{default:withCtx(()=>[createTextVNode(toDisplayString(__props.showText?_ctx.$t(`ui.color.hue`):null),1)]),_:1},8,[`modelValue`,`fill`,`current`,`step`,`disabled`])):createCommentVNode(``,!0),opts.value.slider||opts.value.luminosity?(openBlock(),createBlock(unref(bngColorSlider_default),{key:3,"X:vertical":`opts.picker`,modelValue:values.saturation,"onUpdate:modelValue":_cache[1]||=$event=>values.saturation=$event,modelModifiers:{number:!0},onChange:notify,fill:gradients.saturation,current:`hsl(${current.value.hue}, ${current.value.saturation}%, ${current.value.luminosity}%)`,indicator:sliderIndicator,step:__props.step,disabled:__props.disabled},{default:withCtx(()=>[createTextVNode(toDisplayString(__props.showText?`${_ctx.$t(`ui.color.saturation`)} (${current.value.saturation}%)`:null),1)]),_:1},8,[`modelValue`,`fill`,`current`,`step`,`disabled`])):createCommentVNode(``,!0),opts.value.slider||opts.value.saturation?(openBlock(),createBlock(unref(bngColorSlider_default),{key:4,"X:vertical":`opts.picker`,modelValue:values.luminosity,"onUpdate:modelValue":_cache[2]||=$event=>values.luminosity=$event,modelModifiers:{number:!0},onChange:notify,fill:gradients.luminosity,current:`hsl(${current.value.hue}, ${current.value.saturation}%, ${current.value.luminosity}%)`,indicator:sliderIndicator,step:__props.step,disabled:__props.disabled},{default:withCtx(()=>[createTextVNode(toDisplayString(__props.showText?`${_ctx.$t(`ui.color.brightness`)} (${current.value.luminosity}%)`:null),1)]),_:1},8,[`modelValue`,`fill`,`current`,`step`,`disabled`])):createCommentVNode(``,!0)],2))}},bngColorPicker_default=__plugin_vue_export_helper_default(_sfc_main$379,[[`__scopeId`,`data-v-f4241405`]]),_hoisted_1$328={key:0},_hoisted_2$263=[`min`,`max`,`step`,`tabindex`,`orient`],_hoisted_3$230={key:0,class:`colour-slider-indicator-container`},_sfc_main$378={__name:`bngColorSlider`,props:{modelValue:{type:[Number,String],default:0},min:{type:Number,default:0},max:{type:Number,default:1},step:{type:Number,default:.001},fill:{type:Array,default:[`rgb(0,0,0)`,`rgb(255,255,255)`]},current:{type:String,default:null},vertical:Boolean,disabled:Boolean,indicator:{type:String,default:`inner`,validator:val=>[`inner`,`popout`].includes(val)},uiNavFocus:{type:[Boolean,Object],default:{},validator:val=>typeof val==`boolean`&&!val||typeof val==`object`}},emits:[`update:modelValue`,`change`],setup(__props,{emit:__emit}){let props=__props,elSlider=ref(),elIndicator=ref(),tabIndex=computed(()=>props.disabled?-1:0),value=ref(props.modelValue);watch(()=>props.modelValue,val=>value.value=Number(val));let indicatorPos=computed(()=>props.indicator===`popout`?(value.value-props.min)/(props.max-props.min):0),indicatorRot=computed(()=>{if(props.indicator!==`popout`||!elSlider.value||!elIndicator.value||!elSlider.value.getBoundingClientRect||!elIndicator.value.firstChild||!elIndicator.value.firstChild.getBoundingClientRect)return 0;let tilt=40,rot=0,srect=elSlider.value.getBoundingClientRect(),irect=elIndicator.value.firstChild.getBoundingClientRect(),abspos=indicatorPos.value*srect.width,iwidth=irect.width/2;return absposwithDirectives((openBlock(),createElementBlock(`div`,{ref_key:`elSlider`,ref:elSlider,class:`colour-slider`,style:normalizeStyle({"--colour-slider-track-fill":__props.fill&&__props.fill.length>0?`linear-gradient(90deg, ${__props.fill.join(`, `)})`:`transparent`,"--colour-slider-thumb-fill":__props.indicator===`inner`&&__props.current?__props.current:`#000`,"--colour-slider-thumb-size":__props.indicator===`inner`&&__props.current?`1em`:`0.25em`,"--colour-slider-indicator-x":`${indicatorPos.value*100}%`,"--colour-slider-indicator-r":`${indicatorRot.value}deg`})},[_ctx.$slots.default&&!__props.vertical?(openBlock(),createElementBlock(`span`,_hoisted_1$328,[renderSlot(_ctx.$slots,`default`,{},void 0,!0)])):createCommentVNode(``,!0),createBaseVNode(`div`,null,[withDirectives(createBaseVNode(`input`,{type:`range`,min:__props.min,max:__props.max,step:__props.step,"onUpdate:modelValue":_cache[0]||=$event=>value.value=$event,onInput:notify,onChange:notify,tabindex:tabIndex.value,class:normalizeClass({"colour-slider-vertical":__props.vertical}),orient:__props.vertical?`vertical`:`horizontal`},null,42,_hoisted_2$263),[[vModelText,value.value,void 0,{number:!0}],[unref(BngOnUiNavFocus_default),__props.uiNavFocus?{callback:(dir,val)=>{value.value=val,notify()},value:()=>value.value,min:__props.min,max:__props.max,step:()=>+__props.step,...__props.uiNavFocus}:!1,void 0,{repeat:!0}]]),__props.indicator===`popout`?(openBlock(),createElementBlock(`div`,_hoisted_3$230,[createBaseVNode(`div`,{ref_key:`elIndicator`,ref:elIndicator,class:`colour-slider-indicator`},[createVNode(unref(bngIconMarker_default),{marker:`circlePin`,color:[`#fff`,__props.current],class:`colour-slider-indicator-marker`},null,8,[`color`])],512)])):createCommentVNode(``,!0)])],4)),[[unref(BngDisabled_default),__props.disabled]])}},bngColorSlider_default=__plugin_vue_export_helper_default(_sfc_main$378,[[`__scopeId`,`data-v-346533a2`]]),_hoisted_1$327={class:`bng-color-tile`},_sfc_main$377={__name:`bngColorTile`,props:{red:{type:Number},blue:{type:Number},green:{type:Number},alpha:{type:Number,default:1}},setup(__props){useCssVars(_ctx=>({cef4bc4e:backgroundColor.value}));let props=__props,backgroundColor=computed(()=>`rgba(${props.red}, ${props.green}, ${props.blue}, ${props.alpha})`);return(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$327))}},bngColorTile_default=__plugin_vue_export_helper_default(_sfc_main$377,[[`__scopeId`,`data-v-32089404`]]),_sfc_main$376={__name:`bngCondition`,props:{integrity:{type:Number,default:1},integrityWarning:Boolean,color:{type:[String,Array],default:`#000`},showTooltip:Boolean},setup(__props){let props=__props,integrity=computed(()=>typeof props.integrity==`number`?Math.min(Math.max(props.integrity,0),1):1),tooltip=computed(()=>{if(!props.showTooltip)return;let tip=`${$translate.instant(`ui.condition.integrity`)}: ${~~(integrity.value*100)}%`;return props.integrityWarning&&(tip+=`\n${$translate.instant(`ui.condition.needsRepair`)}`),tip}),cssColour=computed(()=>{let clr=props.color;return Array.isArray(clr)?(clr=[...clr],clr.length>3&&(clr.splice(3),clr.some(c=>c>1)||(clr=clr.map(c=>c*255))),`rgb(${clr.join(`,`)})`):clr}),cssClipPoly=computed(()=>{let val=integrity.value,corners=[`100% 0%`,`100% 100%`,`0% 100%`,`0% 0%`],poly=`0% 0%`;if(val===1)poly=corners.join(`, `);else if(val>0){let deg=(1-val)*360,x=50+50*Math.sin(deg*Math.PI/180),y=50-50*Math.cos(deg*Math.PI/180);poly=`50% 0%, 50% 50%, ${~~x}% ${~~y}%, `+corners.slice(-Math.ceil((360-deg)/90)).join(`, `)}return poly});return(_ctx,_cache)=>withDirectives((openBlock(),createElementBlock(`div`,{class:normalizeClass({"bng-condition":!0,"cond-warn":__props.integrityWarning}),style:normalizeStyle({backgroundColor:cssColour.value,"--bng-condition-clip-path":`polygon(${cssClipPoly.value})`})},null,6)),[[unref(BngTooltip_default),tooltip.value]])}},bngCondition_default=__plugin_vue_export_helper_default(_sfc_main$376,[[`__scopeId`,`data-v-686a3067`]]),SCOPED_CHANGED_EVENT_NAME=`scopeChanged`,EVENT_CROSSFIRE_MAP={ok:`select`,back:`back`,tab_l:`tabLeft`,tab_r:`tabRight`};const CROSSFIRE_HINTS={select:{id:`select`,content:{type:`binding`,props:{uiEvent:`ok`},label:`Select`}},back:{id:`back`,content:{type:`binding`,props:{uiEvent:`back`},label:`Back`}},tabLeft:{id:`tabLeft`,content:{type:`binding`,props:{uiEvent:`tab_l`},label:`Tab left`}},tabRight:{id:`tabRight`,content:{type:`binding`,props:{uiEvent:`tab_r`},label:`Tab right`}}},CROSSFIRE_HINTS_ALL=Object.values(CROSSFIRE_HINTS),DEFAULT_LABELS={focus_u:`ui.inputActions.controllerui.focus_u.title`,focus_r:`ui.inputActions.controllerui.focus_r.title`,focus_d:`ui.inputActions.controllerui.focus_d.title`,focus_l:`ui.inputActions.controllerui.focus_l.title`,pause:`ui.inputActions.general.pause.title`,menu:`ui.inputActions.controllerui.menu.title`,back:`ui.inputActions.controllerui.back.title`,details:`ui.inputActions.controllerui.details.title`,advanced:`ui.inputActions.controllerui.advanced.title`,camera:`ui.inputActions.controllerui.camera.title`,logs:`ui.inputActions.controllerui.logs.title`,tab_l:`ui.inputActions.controllerui.tab_l.title`,tab_r:`ui.inputActions.controllerui.tab_r.title`,modifier:`ui.inputActions.controllerui.modifier.title`,zoom_out:`ui.inputActions.controllerui.zoom_out.title`,zoom_in:`ui.inputActions.controllerui.zoom_in.title`,subtab_l:`ui.inputActions.controllerui.subtab_l.title`,subtab_r:`ui.inputActions.controllerui.subtab_r.title`,center_cam:`ui.inputActions.controllerui.center_cam.title`,action_4:`ui.inputActions.controllerui.action_4.title`,move_ud:`ui.inputActions.controllerui.move_ud.title`,move_lr:`ui.inputActions.controllerui.move_lr.title`,focus_ud:`ui.inputActions.controllerui.focus_ud.title`,focus_lr:`ui.inputActions.controllerui.focus_lr.title`,rotate_h_cam:`ui.inputActions.controllerui.rotate_h_cam.title`,rotate_v_cam:`ui.inputActions.controllerui.rotate_v_cam.title`,ok:`ui.inputActions.controllerui.ok.title`,cancel:`ui.inputActions.controllerui.cancel.title`,action_2:`ui.inputActions.controllerui.action_2.title`,action_3:`ui.inputActions.controllerui.action_3.title`,context:`ui.inputActions.controllerui.context.title`};var HINT_GROUPS=()=>[{names:[`back`,`menu`],label:`ui.inputActions.controllerui.back.title`},{names:[`focus_u`,`focus_d`,`focus_r`,`focus_l`,`focus_lr`,`focus_ud`],label:`ui.mainmenu.navbar.navigate`,controllerOnly:!0},{names:[`focus_u`,`focus_d`,`focus_r`,`focus_l`],label:`ui.mainmenu.navbar.navigate`},{names:[`focus_lr`,`focus_ud`],label:`ui.mainmenu.navbar.navigate`,controllerOnly:!0},{names:[SCROLL_EVENT_H,SCROLL_EVENT_V],label:`ui.mainmenu.navbar.scroll_label`,controllerOnly:!0},{names:[`tab_r`,`tab_l`],label:`ui.mainmenu.navbar.navigate`,controllerOnly:!0}],AUTOID=`__auto`,AUTOIDS={binding:`${AUTOID}_binding`,group:`${AUTOID}_group`,labelGroup:`${AUTOID}_label_group`},DISPLAY_ACTION_VARIANTS=!1;const useInfoBar=defineStore(`infoBar`,()=>{let{events:events$3}=useBridge(),Controls=controls_default(),{isControllerUsed,lastDevice}=storeToRefs(Controls),hintGroups=HINT_GROUPS(),visible=ref(!1),showSysInfo=ref(!1),withAngular=ref(!1),hintsList=ref([]),hints=ref([]);watch([isControllerUsed,lastDevice],()=>_groupHints());let getControlGroup=(uiEvents,groupLabel)=>{try{let actions=uiEvents.map(event=>ACTIONS_BY_UI_EVENT[event]).filter(Boolean);if(actions.length!==uiEvents.length)return null;let viewerObjs=actions.map(action=>Controls.makeViewerObj({action,actionVariants:DISPLAY_ACTION_VARIANTS,useLastDevice:!0})).flatMap(vo=>vo?.variants?vo.variants:vo?[vo]:[]),matchingItems=[],devNames=viewerObjs.reduce((res,obj)=>obj&&!res.includes(obj.devName)?[...res,obj.devName]:res,[]);for(let devName of devNames){if(!devName)continue;let devViewerObjs=viewerObjs.filter(obj=>obj&&obj.devName===devName&&obj.ownGroups);if(devViewerObjs.length===0)continue;let groups=devViewerObjs[0].ownGroups,controls$1=devViewerObjs.map(obj=>obj.control);for(let group of groups){if(!group.controls.every(control=>controls$1.includes(control)))continue;controls$1=controls$1.filter(control=>!group.controls.includes(control));let item;item=group.label?{type:`binding`,props:{viewerObj:{icon:devViewerObjs[0].icon,ownLabel:group.label}},label:groupLabel}:{type:`icon`,props:{type:icons[group.icon]},label:groupLabel},matchingItems.push(item)}}return matchingItems.length===0?null:matchingItems.length===1?matchingItems[0]:matchingItems}catch(err){return logger_default.error(`Error in checkForControlGroup:`,err),null}},_groupHints=()=>{let res=[],groupCandidates={},labelGroups={},isCustomLabel=content=>content&&!content.autoLabel&&content?.props?.uiEvent&&content.label!==DEFAULT_LABELS[content?.props?.uiEvent];for(let hint of hintsList.value){let normalizedHint=hint.content?hint:{content:hint},{content}=normalizedHint;if(!content?.props?.uiEvent||!content.label){res.push(normalizedHint);continue}let labelKey=content.label;labelGroups[labelKey]?labelGroups[labelKey].hints.push(normalizedHint):labelGroups[labelKey]={hints:[normalizedHint],position:res.length}}let selectMatchingGroup=matchingGroups=>matchingGroups.length<1||isControllerUsed.value?matchingGroups[0]:matchingGroups.find(group=>!group.controllerOnly)||matchingGroups.at(-1);for(let[label,group]of Object.entries(labelGroups)){let action=group.hints[0].action;if(group.hints.length>1){let events$4=group.hints.map(h$1=>h$1.content.props.uiEvent),matchingGroup=selectMatchingGroup(hintGroups.filter(g=>g.content&&g.names.every(name=>events$4.includes(name))&&events$4.filter(e=>g.names.includes(e)).length===g.names.length));if(matchingGroup){if(matchingGroup.controllerOnly&&!isControllerUsed.value)continue;let groupContent=Array.isArray(matchingGroup.content)?matchingGroup.content[0]:matchingGroup.content,groupLabel=matchingGroup.label||groupContent?.label||group.hints[0]?.content?.label,groupEvents=group.hints.map(h$1=>h$1.content.props.uiEvent),labeledBindings=group.hints.map(h$1=>{let newContent={id:h$1.id,type:h$1.content.type,props:{...h$1.content.props}};return newContent.label=isCustomLabel(h$1.content)?h$1.content.label:groupLabel,newContent}),controlGroup=getControlGroup(groupEvents,groupLabel);if(controlGroup){let content=Array.isArray(controlGroup)?controlGroup.map(item=>({...item})):[{...controlGroup}],customLabelItem=group.hints.find(h$1=>isCustomLabel(h$1.content));customLabelItem&&content.forEach(item=>{item.label=customLabelItem.content.label}),res.splice(group.position,0,{id:`${AUTOIDS.labelGroup}_${label}`,content,action})}else res.splice(group.position,0,{id:`${AUTOIDS.labelGroup}_${label}`,content:labeledBindings,action})}else res.splice(group.position,0,{id:`${AUTOIDS.labelGroup}_${label}`,content:group.hints.map(h$1=>h$1.content),action})}else{let hint=group.hints[0],uiEvent=hint.content?.props?.uiEvent,isNoGroup=uiEvent$1=>uiNavTracker.activeEvents.find(e=>e.name===uiEvent$1)?.nogroup;if(isNoGroup(uiEvent)){res.push(hint);continue}let matchingGroup=selectMatchingGroup(hintGroups.filter(group$1=>group$1.names.includes(uiEvent)));if(!matchingGroup){res.push(hint);continue}let groupId=matchingGroup.names.join(`,`);groupId in groupCandidates||(groupCandidates[groupId]={hints:[],content:[],position:res.length});let groupCandidate=groupCandidates[groupId];if(groupCandidate.hints.push(hint),groupCandidate.content.push(hint.content),groupCandidate.hints.length===matchingGroup.names.length){if(matchingGroup.controllerOnly&&!isControllerUsed.value){delete groupCandidates[groupId];continue}if(groupCandidate.hints.some(h$1=>isNoGroup(h$1.content?.props?.uiEvent)))res.splice(groupCandidate.position,0,...groupCandidate.hints);else{let groupContent=Array.isArray(matchingGroup.content)?matchingGroup.content[0]:matchingGroup.content,groupLabel=matchingGroup.label||groupContent?.label||groupCandidate.hints[0]?.content?.label,labeledContent=groupCandidate.content.map(item=>{let newContent={id:item.id,type:item.type,props:{...item.props}};return isCustomLabel(item)?newContent.label=item.label:newContent.label=groupLabel,newContent}),controlGroup=getControlGroup(groupCandidate.hints.map(h$1=>h$1.content.props.uiEvent),groupLabel);if(controlGroup){let content=Array.isArray(controlGroup)?controlGroup.map(icon=>({...icon})):[{...controlGroup}],customLabelItem=groupCandidate.content.find(item=>isCustomLabel(item));customLabelItem&&content.forEach(icon=>icon.label=customLabelItem.label),res.splice(groupCandidate.position,0,{id:`${AUTOIDS.group}_${groupId}`,content,action})}else res.splice(groupCandidate.position,0,{id:`${AUTOIDS.group}_${groupId}`,content:labeledContent,action})}delete groupCandidates[groupId]}}}for(let group of Object.values(groupCandidates))res.splice(group.position,0,...group.hints);hints.value=res},uiNavTracker=useUINavTracker(),clearHints=()=>{hintsList.value=[],_addTrackedEvents()},addHints=(hintOrHints,idOrPos=void 0,before=!1)=>{if(hintOrHints===CROSSFIRE_HINTS_ALL){logger_default.warn(`Approach with CROSSFIRE_HINTS_ALL is deprecated and crossfire hints are added by default.`);return}let toAdd=[hintOrHints].flat().map(hint=>{if(typeof hint!=`object`)return hint;let content=hint.content||hint,uiEvent=content?.props?.uiEvent;return uiEvent&&(content.label||(content.autoLabel=!0,uiEvent in DEFAULT_LABELS?content.label=DEFAULT_LABELS[uiEvent]:content.label=uiEvent.replaceAll(`_`,` `).toUpperCase())),hint});if(idOrPos===void 0)hintsList.value=hintsList.value.concat(toAdd);else if(typeof idOrPos==`number`)hintsList.value.splice(idOrPos,0,...toAdd);else if(typeof idOrPos==`string`){let foundIndex=_findHintIndex(idOrPos);foundIndex>-1&&hintsList.value.splice(foundIndex+(before?0:1),0,...toAdd)}_groupHints()},updateHint=(idOrPos,updatedHint)=>{if(typeof idOrPos==`number`)hintsList.value[idOrPos]=updatedHint;else{let foundIndex=_findHintIndex(idOrPos);hintsList.value[foundIndex]=updatedHint}_groupHints()},removeHints=(...ids)=>{ids.forEach(id=>{let foundIndex=_findHintIndex(id);foundIndex>-1&&hintsList.value.splice(foundIndex,1)}),_groupHints()},flashHints=(...ids)=>{_setFlash(!1,ids),setTimeout(()=>_setFlash(!0,ids),0)},_setFlash=(state,ids)=>ids.forEach(id=>{let foundIndex=_findHintIndex(id);foundIndex>-1&&(hintsList.value[foundIndex].flash=state)}),highlightHints=(state,...ids)=>{},_findHintIndex=id=>hintsList.value.findIndex(h$1=>h$1.id===id);events$3.on(SCOPED_CHANGED_EVENT_NAME,data=>{logger_default.debug(`[infoBar] received data`,data),data&&(clearHints(),data.forEach(ev=>{let content;content=ev.label?{content:{type:`binding`,props:{uiEvent:ev.event},label:ev.label}}:CROSSFIRE_HINTS[EVENT_CROSSFIRE_MAP[ev.event]],addHints(content)}))});function _addTrackedEvents(){let activeEvents=uiNavTracker.activeEvents;hintsList.value=hintsList.value.filter(hint=>!hint.id?.startsWith(AUTOID)&&activeEvents.some(e=>e.name===hint.content.props.uiEvent));let currentBindings=hintsList.value.filter(hint=>hint.content?.type===`binding`).map(hint=>hint.content.props.uiEvent);addHints(activeEvents.filter(({name})=>!currentBindings.includes(name)).map(({name,label,nogroup,action})=>({id:`${AUTOIDS.binding}_${name}`,content:{type:`binding`,props:{uiEvent:name},label,autoLabel:!label||label===DEFAULT_LABELS[name]},nogroup,action})))}return watch(()=>uiNavTracker.activeEvents,_addTrackedEvents,{deep:!0}),{visible,hintsList,hints,showSysInfo,withAngular,clearHints,addHints,updateHint,removeHints,flashHints,highlightHints}});var _hoisted_1$326={key:0,xmlns:`http://www.w3.org/2000/svg`,viewBox:`20 140 460 220`},_hoisted_2$262={class:`bng-controller-hint-labels`},_hoisted_3$229={x:`120`,y:`165`,"text-anchor":`middle`},_hoisted_4$196={x:`120`,y:`335`,"text-anchor":`middle`},_hoisted_5$166={x:`45`,y:`255`,"text-anchor":`end`},_hoisted_6$142={x:`175`,y:`255`,"text-anchor":`start`},_hoisted_7$124={x:`219`,y:`315`,"text-anchor":`middle`},_hoisted_8$102={x:`249`,y:`315`,"text-anchor":`middle`},_hoisted_9$92={x:`340`,y:`175`,"text-anchor":`middle`},_hoisted_10$80={x:`380`,y:`335`,"text-anchor":`middle`},_sfc_main$375={__name:`bngControllerHint`,props:{device:String,actions:[Array,String],dark:Boolean},setup(__props,{expose:__expose}){let Controls=controls_default(),props=__props,available=[`xbox`],devName=computed(()=>{if(!props.device)return Controls.lastDevice;let devName$1=props.device;return/\d$/.test(devName$1)||(devName$1=Controls.lastDevices.find(dev=>dev.startsWith(devName$1)),devName$1||=props.device+`0`),devName$1}),devFamily=computed(()=>{let family=Controls.makeViewerObj({device:devName.value,uiEvent:`back`})?.family;return!family||!available.includes(family)?null:family});__expose({displayed:computed(()=>!!devFamily.value)});let actions=computed(()=>{let actions$1=props.actions;if(!actions$1||!devFamily.value)return{};if(typeof actions$1==`string`)actions$1=[actions$1];else if(!Array.isArray(actions$1)||actions$1.length===0)return{};let bindings={},allEvents=Object.keys(ACTIONS_BY_UI_EVENT),allActions=Object.values(ACTIONS_BY_UI_EVENT);for(let action of actions$1){if(!action)continue;let item=action;if(typeof item==`string`)item={action:item};else if(!item.action&&!item.event)continue;else item={...item};let actIdx=allEvents.indexOf(item.event||item.action);if(actIdx>-1&&(item.event=allEvents[actIdx],item.action=allActions[actIdx]),!allActions.includes(item.action))continue;let binding=Controls.findBindingForAction(item.action,devName.value);if(binding){if(!item.event||item.event===item.action){let idx=allActions.indexOf(item.action);idx>-1&&(item.event=allEvents[idx])}item.label||=DEFAULT_LABELS[item.event]||item.event||item.action,item.shown=!0,item.class={flash:item.flash},bindings[binding.control.toLowerCase()]=item}}logger_default.debug(`resolved actions:`,bindings);for(let keyName of DEVICE_CONTROLS[devFamily.value]){let key=keyName.toLowerCase();key in bindings||(bindings[key]={class:{inactive:!0}})}return bindings});return(_ctx,_cache)=>devFamily.value?(openBlock(),createElementBlock(`div`,{key:0,class:normalizeClass([`bng-controller-hint`,{"bng-controller-hint-dark":__props.dark}])},[devFamily.value===`xbox`?(openBlock(),createElementBlock(`svg`,_hoisted_1$326,[_cache[8]||=createBaseVNode(`rect`,{x:`60`,y:`180`,width:`380`,height:`140`,rx:`20`,fill:`#bcbcbc`,stroke:`#333`,"stroke-width":`8`},null,-1),_cache[9]||=createBaseVNode(`circle`,{cx:`120`,cy:`250`,r:`28`,fill:`#222`},null,-1),createBaseVNode(`rect`,{class:normalizeClass(actions.value.upov.class),x:`114`,y:`222`,width:`12`,height:`20`,rx:`3`,fill:`#444`},null,2),createBaseVNode(`rect`,{class:normalizeClass(actions.value.dpov.class),x:`114`,y:`258`,width:`12`,height:`20`,rx:`3`,fill:`#444`},null,2),createBaseVNode(`rect`,{class:normalizeClass(actions.value.lpov.class),x:`98`,y:`242`,width:`20`,height:`12`,rx:`3`,fill:`#444`},null,2),createBaseVNode(`rect`,{class:normalizeClass(actions.value.rpov.class),x:`122`,y:`242`,width:`20`,height:`12`,rx:`3`,fill:`#444`},null,2),createBaseVNode(`rect`,{class:normalizeClass(actions.value.btn_start.class),x:`210`,y:`240`,width:`18`,height:`10`,rx:`3`,fill:`#888`},null,2),createBaseVNode(`rect`,{class:normalizeClass(actions.value.btn_back.class),x:`240`,y:`240`,width:`18`,height:`10`,rx:`3`,fill:`#888`},null,2),createBaseVNode(`circle`,{class:normalizeClass(actions.value.btn_a.class),cx:`340`,cy:`230`,r:`18`,fill:`#22a`},null,2),createBaseVNode(`circle`,{class:normalizeClass(actions.value.btn_b.class),cx:`380`,cy:`270`,r:`18`,fill:`#22a`},null,2),createBaseVNode(`g`,_hoisted_2$262,[actions.value.upov?.shown?(openBlock(),createElementBlock(Fragment,{key:0},[_cache[0]||=createBaseVNode(`line`,{x1:`120`,y1:`202`,x2:`120`,y2:`170`,stroke:`#666`,"stroke-width":`2`},null,-1),createBaseVNode(`text`,_hoisted_3$229,toDisplayString(_ctx.$tt(actions.value.upov?.label)),1)],64)):createCommentVNode(``,!0),actions.value.dpov?.shown?(openBlock(),createElementBlock(Fragment,{key:1},[_cache[1]||=createBaseVNode(`line`,{x1:`120`,y1:`298`,x2:`120`,y2:`320`,stroke:`#666`,"stroke-width":`2`},null,-1),createBaseVNode(`text`,_hoisted_4$196,toDisplayString(_ctx.$tt(actions.value.dpov?.label)),1)],64)):createCommentVNode(``,!0),actions.value.lpov?.shown?(openBlock(),createElementBlock(Fragment,{key:2},[_cache[2]||=createBaseVNode(`line`,{x1:`78`,y1:`250`,x2:`50`,y2:`250`,stroke:`#666`,"stroke-width":`2`},null,-1),createBaseVNode(`text`,_hoisted_5$166,toDisplayString(_ctx.$tt(actions.value.lpov?.label)),1)],64)):createCommentVNode(``,!0),actions.value.rpov?.shown?(openBlock(),createElementBlock(Fragment,{key:3},[_cache[3]||=createBaseVNode(`line`,{x1:`142`,y1:`250`,x2:`170`,y2:`250`,stroke:`#666`,"stroke-width":`2`},null,-1),createBaseVNode(`text`,_hoisted_6$142,toDisplayString(_ctx.$tt(actions.value.rpov?.label)),1)],64)):createCommentVNode(``,!0),actions.value.btn_start?.shown?(openBlock(),createElementBlock(Fragment,{key:4},[_cache[4]||=createBaseVNode(`line`,{x1:`219`,y1:`270`,x2:`219`,y2:`300`,stroke:`#666`,"stroke-width":`2`},null,-1),createBaseVNode(`text`,_hoisted_7$124,toDisplayString(_ctx.$tt(actions.value.btn_start?.label)),1)],64)):createCommentVNode(``,!0),actions.value.btn_back?.shown?(openBlock(),createElementBlock(Fragment,{key:5},[_cache[5]||=createBaseVNode(`line`,{x1:`249`,y1:`270`,x2:`249`,y2:`300`,stroke:`#666`,"stroke-width":`2`},null,-1),createBaseVNode(`text`,_hoisted_8$102,toDisplayString(_ctx.$tt(actions.value.btn_back?.label)),1)],64)):createCommentVNode(``,!0),actions.value.btn_a?.shown?(openBlock(),createElementBlock(Fragment,{key:6},[_cache[6]||=createBaseVNode(`line`,{x1:`340`,y1:`212`,x2:`340`,y2:`180`,stroke:`#666`,"stroke-width":`2`},null,-1),createBaseVNode(`text`,_hoisted_9$92,toDisplayString(_ctx.$tt(actions.value.btn_a?.label)),1)],64)):createCommentVNode(``,!0),actions.value.btn_b?.shown?(openBlock(),createElementBlock(Fragment,{key:7},[_cache[7]||=createBaseVNode(`line`,{x1:`380`,y1:`288`,x2:`380`,y2:`320`,stroke:`#666`,"stroke-width":`2`},null,-1),createBaseVNode(`text`,_hoisted_10$80,toDisplayString(_ctx.$tt(actions.value.btn_b?.label)),1)],64)):createCommentVNode(``,!0)])])):createCommentVNode(``,!0)],2)):createCommentVNode(``,!0)}},bngControllerHint_default=__plugin_vue_export_helper_default(_sfc_main$375,[[`__scopeId`,`data-v-bb01f791`]]),_sfc_main$374={},_hoisted_1$325={class:`divider vertical-divider`};function _sfc_render$6(_ctx,_cache){return openBlock(),createElementBlock(`div`,_hoisted_1$325)}var bngDivider_default=__plugin_vue_export_helper_default(_sfc_main$374,[[`render`,_sfc_render$6],[`__scopeId`,`data-v-c3fbf7df`]]),_sfc_main$373={__name:`bngDrawer`,props:mergeModels({header:String,blur:Boolean,expandable:{type:Boolean,default:!0},position:String},{modelValue:{type:Boolean},modelModifiers:{}}),emits:mergeModels([`change`],[`update:modelValue`]),setup(__props,{emit:__emit}){let props=__props,emit$1=__emit,slots=useSlots(),arrows=computed(()=>{switch(props.position){default:case DRAWER_POSITION.bottom:case DRAWER_POSITION.right:return{expand:icons.arrowLargeUp,collapse:icons.arrowLargeDown};case DRAWER_POSITION.top:case DRAWER_POSITION.left:return{expand:icons.arrowLargeDown,collapse:icons.arrowLargeUp}}}),expanded=useModel(__props,`modelValue`);return watch(()=>expanded.value,val=>emit$1(`change`,val)),watch([()=>props.expandable,()=>expanded.value],()=>!props.expandable&&expanded.value&&(expanded.value=!1),{immediate:!0}),(_ctx,_cache)=>(openBlock(),createBlock(unref(drawer_default),{modelValue:expanded.value,"onUpdate:modelValue":_cache[1]||=$event=>expanded.value=$event,blur:__props.blur,position:__props.position},createSlots({header:withCtx(()=>[createVNode(unref(bngCardHeading_default),{class:`header`,type:`ribbon`,style:normalizeStyle({marginRight:!__props.header&&!unref(slots).header?`0`:void 0})},{default:withCtx(()=>[__props.header?(openBlock(),createElementBlock(Fragment,{key:0},[createTextVNode(toDisplayString(__props.header),1)],64)):renderSlot(_ctx.$slots,`header`,{key:1},()=>[_cache[2]||=createBaseVNode(`span`,null,null,-1)],!0)]),_:3},8,[`style`]),renderSlot(_ctx.$slots,`header-controls`,{},void 0,!0),__props.expandable?(openBlock(),createBlock(unref(bngButton_default),{key:0,accent:`text`,icon:expanded.value?arrows.value.collapse:arrows.value.expand,onClick:_cache[0]||=$event=>expanded.value=!expanded.value},null,8,[`icon`])):createCommentVNode(``,!0)]),_:2},[`content`in unref(slots)?{name:`content`,fn:withCtx(()=>[renderSlot(_ctx.$slots,`content`,{},void 0,!0)]),key:`0`}:void 0,`expanded-content`in unref(slots)?{name:`expanded-content`,fn:withCtx(()=>[renderSlot(_ctx.$slots,`expanded-content`,{},void 0,!0)]),key:`1`}:`default`in unref(slots)?{name:`expanded-content`,fn:withCtx(()=>[renderSlot(_ctx.$slots,`default`,{},void 0,!0)]),key:`2`}:void 0]),1032,[`modelValue`,`blur`,`position`]))}},bngDrawer_default=__plugin_vue_export_helper_default(_sfc_main$373,[[`__scopeId`,`data-v-30948d98`]]),_hoisted_1$324={class:`bng-drawer`},_hoisted_2$261={class:`header-wrapper`},_hoisted_3$228={class:`content`},_sfc_main$372={__name:`bngDrawerOld`,props:{header:{type:String},blur:{type:Boolean,default:!1}},setup(__props){return(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$324,[withDirectives((openBlock(),createElementBlock(`div`,_hoisted_2$261,[createVNode(unref(bngCardHeading_default),{class:`header`,type:`ribbon`},{default:withCtx(()=>[__props.header?(openBlock(),createElementBlock(Fragment,{key:0},[createTextVNode(toDisplayString(__props.header),1)],64)):renderSlot(_ctx.$slots,`header`,{key:1},void 0,!0)]),_:3}),renderSlot(_ctx.$slots,`headerOptions`,{},void 0,!0)])),[[unref(BngBlur_default),__props.blur]]),withDirectives((openBlock(),createBlock(unref(bngCard_default),null,{default:withCtx(()=>[createBaseVNode(`div`,_hoisted_3$228,[renderSlot(_ctx.$slots,`content`,{},void 0,!0)])]),_:3})),[[unref(BngBlur_default),__props.blur]])]))}},bngDrawerOld_default=__plugin_vue_export_helper_default(_sfc_main$372,[[`__scopeId`,`data-v-9e5c32b1`]]),_hoisted_1$323={class:`dropdown-display`},_hoisted_2$260={key:0,class:`dropdown-search`},_hoisted_3$227={key:1},_hoisted_4$195={key:0,class:`dropdown-group-header`},_hoisted_5$165=[`bng-nav-item`,`tabindex`,`bng-scoped-nav-autofocus`,`onClick`,`onKeyup`],_sfc_main$371={__name:`bngDropdown`,props:{modelValue:{type:[Number,String,Boolean,Object]},items:{type:Array,required:!0},showSearch:Boolean,highlight:{type:[String,Array,RegExp]},disabled:Boolean,longNames:{type:String,default:`oneline`,validator:val=>[`oneline`,`wrap`,`cut`].includes(val)},searchGroupName:Boolean,headless:Boolean,focusTarget:Object,popoverTarget:Object},emits:[`update:modelValue`,`valueChanged`,`open`,`close`],setup(__props,{expose:__expose,emit:__emit}){let attrs=useAttrs(),binds=computed(()=>props.headless?void 0:attrs),props=__props,emit$1=__emit,elContainer=ref(null),opened=ref(!1),searching=ref(!1),search$1=ref(``),searchTerm=computed(()=>search$1.value.toLowerCase());watch(opened,val=>!val&&(search$1.value=``)),__expose({opened,open:()=>opened.value=!0,close:()=>opened.value=!1,toggle:()=>opened.value=!opened.value,get popoverName(){return elContainer.value?.popoverName}});let groupedItems=computed(()=>{let hasGrouping=props.items.some(item=>item.group||item.grouped),searchActive=!!searchTerm.value;if(!hasGrouping)return[{header:null,items:searchActive?props.items.filter(item=>item.label.toLowerCase().includes(searchTerm.value)):props.items}];let groups=[],currentGroup=null;return props.items.forEach(item=>{item.group?(currentGroup={header:item,allItems:[],_headerMatches:item.label.toLowerCase().includes(searchTerm.value)},groups.push(currentGroup)):item.grouped?currentGroup?currentGroup.allItems.push(item):groups.push({header:null,allItems:[item]}):(groups.push({header:null,allItems:[item]}),currentGroup=null)}),groups.map(group=>{if(searchActive)if(group.header){if(props.searchGroupName&&group._headerMatches)return{header:group.header,items:group.allItems,headerMatches:!0};{let filteredItems=group.allItems.filter(item=>item.label.toLowerCase().includes(searchTerm.value));return{header:group.header,items:filteredItems,headerMatches:!1}}}else return{header:null,items:group.allItems.filter(item=>item.label.toLowerCase().includes(searchTerm.value))};else return{header:group.header||null,items:group.allItems}}).filter(group=>group.header&&props.searchGroupName&&group.headerMatches||group.items.length>0)}),highlighter$1=computed(()=>search$1.value||props.highlight),selectedValue=computed({get:()=>props.modelValue,set:newValue=>{emit$1(`update:modelValue`,newValue),emit$1(`valueChanged`,newValue)}}),selectedItem=computed(()=>props.items.find(x=>x.value===selectedValue.value)),headerText=computed(()=>selectedItem.value&&selectedItem.value.value!==null&&selectedItem.value.value!==void 0?selectedItem.value.label:`Select`),tabIndexValue=computed(()=>props.disabled?-1:0),select=item=>{item.disabled||(opened.value=!1,selectedValue.value!==item.value&&(selectedValue.value=item.value),elContainer.value?.focusContainer())};return(_ctx,_cache)=>(openBlock(),createBlock(unref(bngDropdownContainer_default),mergeProps({ref_key:`elContainer`,ref:elContainer},binds.value,{opened:opened.value,"onUpdate:opened":_cache[3]||=$event=>opened.value=$event,disabled:__props.disabled,headless:__props.headless,"focus-target":__props.focusTarget,"popover-target":__props.popoverTarget,class:{"with-search":__props.showSearch,[`dropdown-longnames-${__props.longNames}`]:!0},onShow:_cache[4]||=$event=>emit$1(`open`),onHide:_cache[5]||=$event=>emit$1(`close`)}),createSlots({default:withCtx(()=>[__props.showSearch?(openBlock(),createElementBlock(`div`,_hoisted_2$260,[createVNode(unref(bngInput_default),{modelValue:search$1.value,"onUpdate:modelValue":_cache[0]||=$event=>search$1.value=$event,modelModifiers:{trim:!0},"floating-label":`Search`,onFocus:_cache[1]||=$event=>searching.value=!0,onBlur:_cache[2]||=$event=>searching.value=!1},null,8,[`modelValue`])])):createCommentVNode(``,!0),search$1.value&&groupedItems.value.every(group=>group.items.length===0)?(openBlock(),createElementBlock(`div`,_hoisted_3$227,toDisplayString(_ctx.$t(`ui.common.search.noResults`)),1)):(openBlock(!0),createElementBlock(Fragment,{key:2},renderList(groupedItems.value,(group,groupIndex)=>(openBlock(),createElementBlock(Fragment,{key:groupIndex},[group.header?(openBlock(),createElementBlock(`div`,_hoisted_4$195,toDisplayString(group.header.label),1)):createCommentVNode(``,!0),(openBlock(!0),createElementBlock(Fragment,null,renderList(group.items,(item,idx)=>withDirectives((openBlock(),createElementBlock(`div`,{key:item.value,class:normalizeClass([`dropdown-option`,{selected:selectedItem.value&&selectedItem.value.value===item.value,"grouped-item":group.header,disabled:item.disabled}]),"bng-nav-item":!item.disabled||item.focusable,tabindex:item.disabled?-1:tabIndexValue.value,"bng-scoped-nav-autofocus":!item.disabled&&!searching.value&&(selectedItem.value&&selectedItem.value.value===item.value||!selectedItem.value&&groupIndex===0&&idx===0),onClick:$event=>select(item),onKeyup:withKeys($event=>select(item),[`enter`])},[createTextVNode(toDisplayString(item.label),1)],42,_hoisted_5$165)),[[unref(BngOnUiNav_default),void 0,`ok`,{asMouse:!0,focusRequired:!0}],[unref(BngUiNavLabel_default),`ui.inputActions.menu.menu_item_select.title`,`ok`],[unref(BngTooltip_default),item.tooltip??void 0],[unref(BngHighlighter_default),highlighter$1.value]])),128))],64))),128))]),_:2},[__props.headless?void 0:{name:`display`,fn:withCtx(()=>[renderSlot(_ctx.$slots,`display`,{},()=>[withDirectives((openBlock(),createElementBlock(`span`,_hoisted_1$323,[createTextVNode(toDisplayString(headerText.value),1)])),[[unref(BngHighlighter_default),highlighter$1.value]])],!0)]),key:`0`}]),1040,[`opened`,`disabled`,`headless`,`focus-target`,`popover-target`,`class`]))}},bngDropdown_default=__plugin_vue_export_helper_default(_sfc_main$371,[[`__scopeId`,`data-v-96e56708`]]),popoverBaseName=`bng-dropdown-content`,_sfc_main$370=Object.assign({inheritAttrs:!1},{__name:`bngDropdownContainer`,props:mergeModels({disabled:Boolean,class:[String,Array,Object],headless:Boolean,focusTarget:Object,popoverTarget:Object},{opened:{},openedModifiers:{}}),emits:mergeModels([`provideFocus`,`show`,`hide`],[`update:opened`]),setup(__props,{expose:__expose,emit:__emit}){let navBlocker=useUINavBlocker(),props=__props,attrs=useAttrs(),binds=computed(()=>({...attrs,tabindex:props.headless?-1:0,"bng-nav-item":props.headless?void 0:``})),opened=useModel(__props,`opened`);function open$1(val){opened.value=val,val?(navBlocker.allowOnly([`focus_u`,`focus_d`,`focus_ud`,`back`,`menu`,`ok`]),emit$1(`show`)):(navBlocker.clear(),emit$1(`hide`),focusTarget.value&&setFocusExternal(focusTarget.value,!0,!1))}let emit$1=__emit,popover=usePopover(),popoverName=uniqueId(popoverBaseName),container=ref(null),content=ref(null),focusTarget=computed(()=>props.focusTarget||container.value),popoverTarget=computed(()=>props.popoverTarget||container.value),placement=ref(`bottom-start`),openedTop=computed(()=>placement.value.startsWith(`top`));return watch(()=>opened.value,value=>{value?(Object.keys(popover.popovers).filter(name=>popover.popovers[name].show&&name!==popoverName&&!popover.popovers[name].element.contains(popover.popovers[popoverName].target)).forEach(name=>popover.hide(name)),!popover.popovers[popoverName].show&&popoverTarget.value&&popover.show(popoverName,popoverTarget.value)):popover.hide(popoverName)}),__expose({opened,open:()=>opened.value=!0,close:()=>opened.value=!1,toggle:()=>opened.value=!opened.value,focusContainer:()=>focusTarget.value&&setFocusExternal(focusTarget.value),popoverName}),(_ctx,_cache)=>(openBlock(),createElementBlock(Fragment,null,[__props.headless?createCommentVNode(``,!0):withDirectives((openBlock(),createElementBlock(`div`,mergeProps({key:0,ref_key:`container`,ref:container},binds.value,{class:[`bng-dropdown`,props.class]}),[createVNode(unref(bngIcon_default),{type:unref(icons).arrowSmallRight,class:normalizeClass({"dropdown-arrow":!0,"dropdown-arrow-top":openedTop.value,opened:opened.value})},null,8,[`type`,`class`]),renderSlot(_ctx.$slots,`display`,{},()=>[_cache[8]||=createTextVNode(`Select`,-1)],!0)],16)),[[unref(BngDisabled_default),__props.disabled],[unref(BngOnUiNav_default),void 0,`ok`,{asMouse:!0,focusRequired:!0}],[unref(BngPopover_default),unref(popoverName),`bottom-start`,{click:!0}]]),createVNode(unref(bngPopoverContent_default),{name:unref(popoverName),onShow:_cache[5]||=$event=>open$1(!0),onHide:_cache[6]||=$event=>open$1(!1),"hide-arrow":``,onPlacementChanged:_cache[7]||=value=>placement.value=value},{default:withCtx(()=>[withDirectives((openBlock(),createElementBlock(`div`,{ref_key:`content`,ref:content,class:normalizeClass([`bng-dropdown-content`,__props.class]),"bng-nav-scroll":``,onClick:_cache[0]||=withModifiers(()=>{},[`stop`]),onMouseover:_cache[1]||=withModifiers(()=>{},[`stop`]),onMouseenter:_cache[2]||=withModifiers(()=>{},[`stop`]),onMousedown:_cache[3]||=withModifiers(()=>{},[`stop`]),onMouseup:_cache[4]||=withModifiers(()=>{},[`stop`])},[opened.value?renderSlot(_ctx.$slots,`default`,{key:0},void 0,!0):createCommentVNode(``,!0)],34)),[[unref(BngAutoScroll_default),void 0,`top`],[unref(BngUiNavLabel_default),`ui.common.close`,`back,menu`],[unref(BngUiNavLabel_default),`ui.mainmenu.navbar.navigate`,`focus_u,focus_d`],[unref(BngUiNavScroll_default)],[unref(BngOnUiNav_default),()=>open$1(!1),`menu`]])]),_:3},8,[`name`])],64))}}),bngDropdownContainer_default=__plugin_vue_export_helper_default(_sfc_main$370,[[`__scopeId`,`data-v-840dc960`]]),icons$2=Object.freeze({"4WD":{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/4WD.svg`},"9dividedby10":{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/9dividedby10.svg`},abandon:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/abandon.svg`},ABSIndicator:{glyph:``,size:24,tags:[`vehicle`,`features`,`warning`,`internals`],fileSvg:`svg/ABSIndicator.svg`},addItemPolygon:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`,`road tools`],fileSvg:`svg/addItemPolygon.svg`},addListItem:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`,`road tools`],fileSvg:`svg/addListItem.svg`},addPolygonVertex:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`,`road tools`],fileSvg:`svg/addPolygonVertex.svg`},adjust:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/adjust.svg`},AIMicrochip:{glyph:``,size:24,tags:[`generic`,`ai`,`microchip`],fileSvg:`svg/AIMicrochip.svg`},AIRace:{glyph:``,size:24,tags:[`poi`],fileSvg:`svg/AIRace.svg`},aperture:{glyph:``,size:24,tags:[`generic`,`camera`,`optical`,`sensor`],fileSvg:`svg/aperture.svg`},arrowLargeDown:{glyph:``,size:24,tags:[`arrow`,`large`,`simple`,`outlined`],fileSvg:`svg/arrowLargeDown.svg`},arrowLargeLeft:{glyph:``,size:24,tags:[`arrow`,`large`,`simple`,`outlined`],fileSvg:`svg/arrowLargeLeft.svg`},arrowLargeRight:{glyph:``,size:24,tags:[`arrow`,`large`,`simple`,`outlined`],fileSvg:`svg/arrowLargeRight.svg`},arrowLargeUp:{glyph:``,size:24,tags:[`arrow`,`large`,`simple`,`outlined`],fileSvg:`svg/arrowLargeUp.svg`},arrowSmallDown:{glyph:``,size:24,tags:[`arrow`,`small`,`simple`,`outlined`],fileSvg:`svg/arrowSmallDown.svg`},arrowSmallLeft:{glyph:``,size:24,tags:[`arrow`,`small`,`simple`,`outlined`],fileSvg:`svg/arrowSmallLeft.svg`},arrowSmallRight:{glyph:``,size:24,tags:[`arrow`,`small`,`simple`,`outlined`],fileSvg:`svg/arrowSmallRight.svg`},arrowSmallUp:{glyph:``,size:24,tags:[`arrow`,`small`,`simple`,`outlined`],fileSvg:`svg/arrowSmallUp.svg`},arrowSolidLeft:{glyph:``,size:24,tags:[`arrow`,`large`,`solid`,`detailed`],fileSvg:`svg/arrowSolidLeft.svg`},arrowSolidRight:{glyph:``,size:24,tags:[`arrow`,`large`,`solid`,`detailed`],fileSvg:`svg/arrowSolidRight.svg`},autobahn:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/autobahn.svg`},AWD:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/AWD.svg`},axleLift:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/axleLift.svg`},axleCenter:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/axleCenter.svg`},axleFront:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/axleFront.svg`},axleRear:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/axleRear.svg`},bSpline:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`,`road tools`],fileSvg:`svg/bSpline.svg`},banknotes:{glyph:``,size:24,tags:[`career`,`currencies`],fileSvg:`svg/banknotes.svg`},barrelKnocker01:{glyph:``,size:24,tags:[`poi`],fileSvg:`svg/barrelKnocker01.svg`},barrelKnocker02:{glyph:``,size:24,tags:[`poi`],fileSvg:`svg/barrelKnocker02.svg`},beamCrashBarrier1:{glyph:``,size:24,tags:[`generic`,`world editor`,`we`,`road tools`],fileSvg:`svg/beamCrashBarrier1.svg`},beamCrashBarrier2:{glyph:``,size:24,tags:[`generic`,`world editor`,`we`,`road tools`],fileSvg:`svg/beamCrashBarrier2.svg`},beamCrashBarrier3:{glyph:``,size:24,tags:[`generic`,`world editor`,`we`,`road tools`],fileSvg:`svg/beamCrashBarrier3.svg`},beamCurrency:{glyph:``,size:24,tags:[`career`,`currencies`],fileSvg:`svg/beamCurrency.svg`},beamNG:{glyph:``,size:24,tags:[`brand`,`beamng`,`generic`],fileSvg:`svg/beamNG.svg`},beamXPFull:{glyph:``,size:24,tags:[`career`,`currencies`],fileSvg:`svg/beamXPFull.svg`},beamXPLo:{glyph:``,size:24,tags:[`career`,`currencies`],fileSvg:`svg/beamXPLo.svg`},bezierPath1:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`,`road tools`],fileSvg:`svg/bezierPath1.svg`},bezierPath2:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`,`road tools`],fileSvg:`svg/bezierPath2.svg`},bicycle1:{glyph:``,size:24,tags:[`generic`,`world editor`,`we`,`road tools`],fileSvg:`svg/bicycle1.svg`},bicycle2:{glyph:``,size:24,tags:[`generic`,`world editor`,`we`,`road tools`],fileSvg:`svg/bicycle2.svg`},BNGFolder:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/BNGFolder.svg`},BNGMicrochip:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/BNGMicrochip.svg`},bollard:{glyph:``,size:24,tags:[`generic`,`world editor`,`we`,`road tools`],fileSvg:`svg/bollard.svg`},bookmark:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/bookmark.svg`},booleanIntersect:{glyph:``,size:24,tags:[`decals`,`generic`],fileSvg:`svg/booleanIntersect.svg`},boxDropOff01:{glyph:``,size:24,tags:[`poi`,`delivery`],fileSvg:`svg/boxDropOff01.svg`},boxDropOff02:{glyph:``,size:24,tags:[`poi`,`delivery`],fileSvg:`svg/boxDropOff02.svg`},boxDropOff03:{glyph:``,size:24,tags:[`poi`,`delivery`],fileSvg:`svg/boxDropOff03.svg`},boxPickUp01:{glyph:``,size:24,tags:[`poi`,`delivery`],fileSvg:`svg/boxPickUp01.svg`},boxPickUp02:{glyph:``,size:24,tags:[`poi`,`delivery`],fileSvg:`svg/boxPickUp02.svg`},boxPickUp03:{glyph:``,size:24,tags:[`poi`,`delivery`],fileSvg:`svg/boxPickUp03.svg`},boxPickUpDropOff01:{glyph:``,size:24,tags:[`poi`,`delivery`],fileSvg:`svg/boxPickUpDropOff01.svg`},boxPickUpDropOff02:{glyph:``,size:24,tags:[`poi`,`delivery`],fileSvg:`svg/boxPickUpDropOff02.svg`},boxTruck:{glyph:``,size:24,tags:[`cargo`,`delivery`,`vehicle`],fileSvg:`svg/boxTruck.svg`},broom:{glyph:``,size:24,tags:[`generic`,`sound`],fileSvg:`svg/broom.svg`},bucketAdd:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/bucketAdd.svg`},bucketSubtract:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/bucketSubtract.svg`},bug:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/bug.svg`},bulldozer:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`,`road tools`],fileSvg:`svg/bulldozer.svg`},bus:{glyph:``,size:24,tags:[`poi`,`vehicle`],fileSvg:`svg/bus.svg`},camera3Fourth1:{glyph:``,size:24,tags:[`camera`],fileSvg:`svg/camera3Fourth1.svg`},cameraBack1:{glyph:``,size:24,tags:[`camera`],fileSvg:`svg/cameraBack1.svg`},cameraFocusOnPath:{glyph:``,size:24,tags:[`camera`],fileSvg:`svg/cameraFocusOnPath.svg`},cameraFocusOnVehicle1:{glyph:``,size:24,tags:[`camera`],fileSvg:`svg/cameraFocusOnVehicle1.svg`},cameraFocusOnVehicle2:{glyph:``,size:24,tags:[`camera`,`decals`],fileSvg:`svg/cameraFocusOnVehicle2.svg`},cameraFocusTopDown:{glyph:``,size:24,tags:[`camera`],fileSvg:`svg/cameraFocusTopDown.svg`},cameraFront1:{glyph:``,size:24,tags:[`camera`],fileSvg:`svg/cameraFront1.svg`},cameraSideLeft:{glyph:``,size:24,tags:[`camera`],fileSvg:`svg/cameraSideLeft.svg`},cameraSideLeft2:{glyph:``,size:24,tags:[`camera`],fileSvg:`svg/cameraSideLeft2.svg`},cameraSideRight:{glyph:``,size:24,tags:[`camera`],fileSvg:`svg/cameraSideRight.svg`},cameraSideRight2:{glyph:``,size:24,tags:[`camera`],fileSvg:`svg/cameraSideRight2.svg`},cameraTop1:{glyph:``,size:24,tags:[`camera`],fileSvg:`svg/cameraTop1.svg`},cannon:{glyph:``,size:24,tags:[`poi`],fileSvg:`svg/cannon.svg`},carChase01:{glyph:``,size:24,tags:[`generic`,`police`,`vehicle`],fileSvg:`svg/carChase01.svg`},carCoin:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/carCoin.svg`},carCoins:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/carCoins.svg`},carCrash:{glyph:``,size:24,tags:[`generic`,`vehicle`],fileSvg:`svg/carCrash.svg`},carDealer:{glyph:``,size:24,tags:[`career`,`garage`,`features`],fileSvg:`svg/carDealer.svg`},carOffroadOutlineRear:{glyph:``,size:24,tags:[`generic`,`vehicle`],fileSvg:`svg/carOffroadOutlineRear.svg`},carOffroadOutlineSide:{glyph:``,size:24,tags:[`generic`,`vehicle`],fileSvg:`svg/carOffroadOutlineSide.svg`},carOffroadRear:{glyph:``,size:24,tags:[`generic`,`vehicle`],fileSvg:`svg/carOffroadRear.svg`},carOffroadSide:{glyph:``,size:24,tags:[`generic`,`vehicle`],fileSvg:`svg/carOffroadSide.svg`},carSensors:{glyph:``,size:24,tags:[`generic`,`vehicle`,`sensors`],fileSvg:`svg/carSensors.svg`},carStarred:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/carStarred.svg`},carToWheels:{glyph:``,size:24,tags:[`generic`,`vehicle`],fileSvg:`svg/carToWheels.svg`},carUp:{glyph:``,size:24,tags:[`generic`,`vehicle`],fileSvg:`svg/carUp.svg`},carWithLidar:{glyph:``,size:24,tags:[`generic`,`vehicle`,`tech`,`sensors`],fileSvg:`svg/carWithLidar.svg`},car:{glyph:``,size:24,tags:[`generic`,`vehicle`],fileSvg:`svg/car.svg`},cardboardBox:{glyph:``,size:24,tags:[`generic`,`delivery`],fileSvg:`svg/cardboardBox.svg`},carsChase02:{glyph:``,size:24,tags:[`generic`,`police`,`vehicle`],fileSvg:`svg/carsChase02.svg`},cars:{glyph:``,size:24,tags:[`generic`,`vehicle`],fileSvg:`svg/cars.svg`},catalog01:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/catalog01.svg`},catalog02:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/catalog02.svg`},catalog03:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/catalog03.svg`},centrifugalClutchLocked03:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/centrifugalClutchLocked03.svg`},centrifugalClutchUnlocked03:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/centrifugalClutchUnlocked03.svg`},charge:{glyph:``,size:24,tags:[`fuel`,`electricity`,`ev`],fileSvg:`svg/charge.svg`},charging:{glyph:``,size:24,tags:[`fuel`,`electricity`,`ev`],fileSvg:`svg/charging.svg`},chartBars:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/chartBars.svg`},checkboxOff:{glyph:``,size:24,tags:[`checkbox`,`selection`,`box`],fileSvg:`svg/checkboxOff.svg`},checkboxOn:{glyph:``,size:24,tags:[`checkbox`,`selection`,`box`],fileSvg:`svg/checkboxOn.svg`},checkmarkBold:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/checkmarkBold.svg`},checkmark:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/checkmark.svg`},circuitMicrochip:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/circuitMicrochip.svg`},circuit:{glyph:``,size:24,tags:[`poi`],fileSvg:`svg/circuit.svg`},clapperboard:{glyph:``,size:24,tags:[`generic`,`movie`,`scenery`],fileSvg:`svg/clapperboard.svg`},code:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/code.svg`},cogDamaged:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/cogDamaged.svg`},cogsDamaged:{glyph:``,size:24,tags:[`vehicle`,`features`,`powertrain`,`drivetrain`],fileSvg:`svg/cogsDamaged.svg`},cogs:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/cogs.svg`},concreteRoadBlock:{glyph:``,size:24,tags:[`generic`,`world editor`,`we`,`road tools`],fileSvg:`svg/concreteRoadBlock.svg`},coolantTemp:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/coolantTemp.svg`},copy:{glyph:``,size:24,tags:[`decals`,`generic`],fileSvg:`svg/copy.svg`},crossroads1:{glyph:``,size:24,tags:[`generic`,`world editor`,`we`,`road tools`],fileSvg:`svg/crossroads1.svg`},crossroads2:{glyph:``,size:24,tags:[`generic`,`world editor`,`we`,`road tools`],fileSvg:`svg/crossroads2.svg`},cruiseDisable:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/cruiseDisable.svg`},cruiseEnable:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/cruiseEnable.svg`},cup:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/cup.svg`},dataExchange:{glyph:``,size:24,tags:[`generic`,`data`,`signal`],fileSvg:`svg/dataExchange.svg`},day:{glyph:``,size:24,tags:[`environment`],fileSvg:`svg/day.svg`},DCBattery:{glyph:``,size:24,tags:[`vehicle`,`features`,`warning`,`internals`],fileSvg:`svg/DCBattery.svg`},decalRoad:{glyph:``,size:24,tags:[`generic`,`world editor`,`we`,`road tools`],fileSvg:`svg/decalRoad.svg`},decal:{glyph:``,size:24,tags:[`decals`,`generic`],fileSvg:`svg/decal.svg`},deform:{glyph:``,size:24,tags:[`decals`,`generic`],fileSvg:`svg/deform.svg`},deliveryTruckArrows:{glyph:``,size:24,tags:[`poi`,`delivery`,`vehicle`],fileSvg:`svg/deliveryTruckArrows.svg`},deliveryTruck:{glyph:``,size:24,tags:[`poi`,`delivery`,`vehicle`],fileSvg:`svg/deliveryTruck.svg`},differentialFrontDefault:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/differentialFrontDefault.svg`},differentialFrontLocked:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/differentialFrontLocked.svg`},differentialMiddleDefault:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/differentialMiddleDefault.svg`},differentialMiddleLocked:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/differentialMiddleLocked.svg`},differentialRearDefault:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/differentialRearDefault.svg`},differentialRearLocked:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/differentialRearLocked.svg`},doorHandle:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/doorHandle.svg`},doorIn:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/doorIn.svg`},drag01:{glyph:``,size:24,tags:[`poi`],fileSvg:`svg/drag01.svg`},drag02:{glyph:``,size:24,tags:[`poi`],fileSvg:`svg/drag02.svg`},drift01:{glyph:``,size:24,tags:[`poi`,`vehicle`],fileSvg:`svg/drift01.svg`},drift02:{glyph:``,size:24,tags:[`poi`,`vehicle`],fileSvg:`svg/drift02.svg`},drivetrainGeneric:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/drivetrainGeneric.svg`},drivetrainSpecial:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/drivetrainSpecial.svg`},editCheckmark:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/editCheckmark.svg`},edit:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/edit.svg`},engine:{glyph:``,size:24,tags:[`vehicle`,`part`,`features`],fileSvg:`svg/engine.svg`},ESCOff:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/ESCOff.svg`},ESCOn:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/ESCOn.svg`},ESC:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/ESC.svg`},evade:{glyph:``,size:24,tags:[`poi`,`mission`,`police`],fileSvg:`svg/evade.svg`},exhaustValve:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/exhaustValve.svg`},exit:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/exit.svg`},export:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/export.svg`},eyeOutlineClosed:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/eyeOutlineClosed.svg`},eyeOutlineOpened:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/eyeOutlineOpened.svg`},eyeSolidClosed:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/eyeSolidClosed.svg`},eyeSolidOpened:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/eyeSolidOpened.svg`},eyeWaves:{glyph:``,size:24,tags:[`generic`,`data`,`signal`,`sensor`],fileSvg:`svg/eyeWaves.svg`},facility02:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/facility02.svg`},fastBackward:{glyph:``,size:24,tags:[`playback`],fileSvg:`svg/fastBackward.svg`},fastForward:{glyph:``,size:24,tags:[`playback`],fileSvg:`svg/fastForward.svg`},fastTravel:{glyph:``,size:24,tags:[`poi`],fileSvg:`svg/fastTravel.svg`},filter:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/filter.svg`},flagNew:{glyph:``,size:24,tags:[`poi`],fileSvg:`svg/flagNew.svg`},flag:{glyph:``,size:24,tags:[`poi`],fileSvg:`svg/flag.svg`},flatBulbBeam:{glyph:``,size:24,tags:[`generic`,`world editor`,`we`,`sensor`],fileSvg:`svg/flatBulbBeam.svg`},flatbedTruck:{glyph:``,size:24,tags:[`cargo`,`delivery`,`vehicle`,`truck`],fileSvg:`svg/flatbedTruck.svg`},floppyDisk:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/floppyDisk.svg`},fogLight:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/fogLight.svg`},folder:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/folder.svg`},forklift:{glyph:``,size:24,tags:[`delivery`,`stencil`,`cargo`,`vehicle`],fileSvg:`svg/forklift.svg`},FPS:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/FPS.svg`},fragile:{glyph:``,size:24,tags:[`delivery`,`stencil`,`cargo`],fileSvg:`svg/fragile.svg`},frontAxleMidpoint:{glyph:``,size:24,tags:[`generic`,`world editor`,`we`,`placement`,`sensor`],fileSvg:`svg/frontAxleMidpoint.svg`},frontBumperMidpoint:{glyph:``,size:24,tags:[`generic`,`world editor`,`we`,`placement`,`sensor`],fileSvg:`svg/frontBumperMidpoint.svg`},fuelPumpFilling:{glyph:``,size:24,tags:[`fuel`],fileSvg:`svg/fuelPumpFilling.svg`},fuelPump:{glyph:``,size:24,tags:[`fuel`],fileSvg:`svg/fuelPump.svg`},FWD:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/FWD.svg`},gamepadOld:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/gamepadOld.svg`},gamepad:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/gamepad.svg`},garage01:{glyph:``,size:24,tags:[`career`,`garage`,`features`],fileSvg:`svg/garage01.svg`},garage02:{glyph:``,size:24,tags:[`career`,`garage`,`features`],fileSvg:`svg/garage02.svg`},garage03:{glyph:``,size:24,tags:[`career`,`garage`,`features`],fileSvg:`svg/garage03.svg`},gaugeEmpty:{glyph:``,size:24,tags:[`poi`],fileSvg:`svg/gaugeEmpty.svg`},globe:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/globe.svg`},GPSMark:{glyph:``,size:24,tags:[`generic`,`gps`,`position`,`map`,`sensor`],fileSvg:`svg/GPSMark.svg`},GPSSolid:{glyph:``,size:24,tags:[`generic`,`gps`,`position`,`map`,`sensor`],fileSvg:`svg/GPSSolid.svg`},group:{glyph:``,size:24,tags:[`decals`,`generic`],fileSvg:`svg/group.svg`},gyroscopeMicrochip:{glyph:``,size:24,tags:[`generic`,`data`,`signal`,`sensor`],fileSvg:`svg/gyroscopeMicrochip.svg`},gyroscope:{glyph:``,size:24,tags:[`generic`,`data`,`signal`,`sensor`],fileSvg:`svg/gyroscope.svg`},hazardLights:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/hazardLights.svg`},helmets:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/helmets.svg`},help:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/help.svg`},highBeam:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/highBeam.svg`},HUD:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/HUD.svg`},hydroPump1:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/hydroPump1.svg`},hydroPump2:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/hydroPump2.svg`},hydroPump3:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/hydroPump3.svg`},hydroPump4:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/hydroPump4.svg`},hydroPump5:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/hydroPump5.svg`},hydroPump6:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/hydroPump6.svg`},hydroPump7:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/hydroPump7.svg`},hypermiling:{glyph:``,size:24,tags:[`poi`],fileSvg:`svg/hypermiling.svg`},import:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/import.svg`},infinity:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/infinity.svg`},info:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/info.svg`},jointLocked:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/jointLocked.svg`},jointUnlocked:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/jointUnlocked.svg`},jump:{glyph:``,size:24,tags:[`poi`],fileSvg:`svg/jump.svg`},keyboard:{glyph:``,size:24,tags:[`keyboard`,`input`],fileSvg:`svg/keyboard.svg`},keys1:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/keys1.svg`},keys2:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/keys2.svg`},lampPost1:{glyph:``,size:24,tags:[`generic`,`world editor`,`we`,`road tools`],fileSvg:`svg/lampPost1.svg`},lampPost2:{glyph:``,size:24,tags:[`generic`,`world editor`,`we`,`road tools`],fileSvg:`svg/lampPost2.svg`},lampPost3:{glyph:``,size:24,tags:[`generic`,`world editor`,`we`,`road tools`],fileSvg:`svg/lampPost3.svg`},laneProperties:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`,`road tools`],fileSvg:`svg/laneProperties.svg`},language:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/language.svg`},laptop:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/laptop.svg`},lidarPatternFullArcHighFreq:{glyph:``,size:24,tags:[`generic`,`world editor`,`we`,`sensor`],fileSvg:`svg/lidarPatternFullArcHighFreq.svg`},lidarPatternFullArcMidFreq:{glyph:``,size:24,tags:[`generic`,`world editor`,`we`,`sensor`],fileSvg:`svg/lidarPatternFullArcMidFreq.svg`},lidarPatternNarrowArc:{glyph:``,size:24,tags:[`generic`,`world editor`,`we`,`sensor`],fileSvg:`svg/lidarPatternNarrowArc.svg`},lidar:{glyph:``,size:24,tags:[`generic`,`data`,`signal`,`sensor`],fileSvg:`svg/lidar.svg`},lightGarageG11:{glyph:``,size:24,tags:[`career`,`garage`,`lights`],fileSvg:`svg/lightGarageG11.svg`},lightGarageG12:{glyph:``,size:24,tags:[`career`,`garage`,`lights`],fileSvg:`svg/lightGarageG12.svg`},lightGarageG13:{glyph:``,size:24,tags:[`career`,`garage`,`lights`],fileSvg:`svg/lightGarageG13.svg`},lightGarageG14:{glyph:``,size:24,tags:[`career`,`garage`,`lights`],fileSvg:`svg/lightGarageG14.svg`},lightGarageG21:{glyph:``,size:24,tags:[`career`,`garage`,`lights`],fileSvg:`svg/lightGarageG21.svg`},lightGarageG22:{glyph:``,size:24,tags:[`career`,`garage`,`lights`],fileSvg:`svg/lightGarageG22.svg`},lightGarageG23:{glyph:``,size:24,tags:[`career`,`garage`,`lights`],fileSvg:`svg/lightGarageG23.svg`},lightGarageG24:{glyph:``,size:24,tags:[`career`,`garage`,`lights`],fileSvg:`svg/lightGarageG24.svg`},lightGarageG31:{glyph:``,size:24,tags:[`career`,`garage`,`lights`],fileSvg:`svg/lightGarageG31.svg`},lightGarageG32:{glyph:``,size:24,tags:[`career`,`garage`,`lights`],fileSvg:`svg/lightGarageG32.svg`},lightGarageG33:{glyph:``,size:24,tags:[`career`,`garage`,`lights`],fileSvg:`svg/lightGarageG33.svg`},lightGarageG34:{glyph:``,size:24,tags:[`career`,`garage`,`lights`],fileSvg:`svg/lightGarageG34.svg`},lightrunner:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/lightrunner.svg`},limiterEnable:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/limiterEnable.svg`},lineToTerrain:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`,`road tools`],fileSvg:`svg/lineToTerrain.svg`},link2:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/link2.svg`},link:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/link.svg`},listBig:{glyph:``,size:24,tags:[`generic`,`catalog`,`selector`,`view`],fileSvg:`svg/listBig.svg`},listIndented:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/listIndented.svg`},listSmall:{glyph:``,size:24,tags:[`generic`,`catalog`,`selector`,`view`],fileSvg:`svg/listSmall.svg`},location1:{glyph:``,size:24,tags:[`generic`,`gps`,`position`,`map`,`sensor`],fileSvg:`svg/location1.svg`},location2:{glyph:``,size:24,tags:[`generic`,`gps`,`position`,`map`,`sensor`],fileSvg:`svg/location2.svg`},lockClosed:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/lockClosed.svg`},lockOpened:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/lockOpened.svg`},longRangeBeam1:{glyph:``,size:24,tags:[`generic`,`world editor`,`we`,`sensor`],fileSvg:`svg/longRangeBeam1.svg`},longRangeBeam2:{glyph:``,size:24,tags:[`generic`,`world editor`,`we`,`sensor`],fileSvg:`svg/longRangeBeam2.svg`},lowBeam:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/lowBeam.svg`},magnetOnSurface:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`,`road tools`],fileSvg:`svg/magnetOnSurface.svg`},mapWithEmitter:{glyph:``,size:24,tags:[`generic`,`tech`,`sensors`],fileSvg:`svg/mapWithEmitter.svg`},mapPoint:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/mapPoint.svg`},material:{glyph:``,size:24,tags:[`decals`,`generic`],fileSvg:`svg/material.svg`},mathDivide:{glyph:``,size:24,tags:[`generic`,`math`,`operands`,`small`],fileSvg:`svg/mathDivide.svg`},mathGreaterOrEqualThan:{glyph:``,size:24,tags:[`generic`,`math`,`operands`,`small`],fileSvg:`svg/mathGreaterOrEqualThan.svg`},mathGreaterThan:{glyph:``,size:24,tags:[`generic`,`math`,`operands`,`small`],fileSvg:`svg/mathGreaterThan.svg`},mathLessOrEqualThan:{glyph:``,size:24,tags:[`generic`,`math`,`operands`,`small`],fileSvg:`svg/mathLessOrEqualThan.svg`},mathLessThan:{glyph:``,size:24,tags:[`generic`,`math`,`operands`,`small`],fileSvg:`svg/mathLessThan.svg`},mathMinus:{glyph:``,size:24,tags:[`generic`,`math`,`operands`,`small`],fileSvg:`svg/mathMinus.svg`},mathMultiply:{glyph:``,size:24,tags:[`generic`,`math`,`operands`,`small`],fileSvg:`svg/mathMultiply.svg`},mathPlus:{glyph:``,size:24,tags:[`generic`,`math`,`operands`,`small`],fileSvg:`svg/mathPlus.svg`},medal:{glyph:``,size:24,tags:[`generic`,`reward`,`achievment`],fileSvg:`svg/medal.svg`},mesh4Cells:{glyph:``,size:24,tags:[`tech`,`mesh`,`beams`,`nodes`,`surface`],fileSvg:`svg/mesh4Cells.svg`},mesh9Cells:{glyph:``,size:24,tags:[`tech`,`mesh`,`beams`,`nodes`,`surface`],fileSvg:`svg/mesh9Cells.svg`},meshFence:{glyph:``,size:24,tags:[`generic`,`world editor`,`we`,`road tools`],fileSvg:`svg/meshFence.svg`},meshRoad:{glyph:``,size:24,tags:[`generic`,`world editor`,`we`,`road tools`],fileSvg:`svg/meshRoad.svg`},midRangeBeam1:{glyph:``,size:24,tags:[`generic`,`world editor`,`we`,`sensor`],fileSvg:`svg/midRangeBeam1.svg`},midRangeBeam2:{glyph:``,size:24,tags:[`generic`,`world editor`,`we`,`sensor`],fileSvg:`svg/midRangeBeam2.svg`},minusRes:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/minusRes.svg`},minus:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/minus.svg`},mirrorInteriorMiddle:{glyph:``,size:24,tags:[`vehicle`,`features`,`mirror`,`rearview`],fileSvg:`svg/mirrorInteriorMiddle.svg`},mirrorLeftBigBottomWideAngle:{glyph:``,size:24,tags:[`vehicle`,`features`,`mirror`,`rearview`],fileSvg:`svg/mirrorLeftBigBottomWideAngle.svg`},mirrorLeftBigTop:{glyph:``,size:24,tags:[`vehicle`,`features`,`mirror`,`rearview`],fileSvg:`svg/mirrorLeftBigTop.svg`},mirrorLeftBig:{glyph:``,size:24,tags:[`vehicle`,`features`,`mirror`,`rearview`],fileSvg:`svg/mirrorLeftBig.svg`},mirrorLeftBonnet:{glyph:``,size:24,tags:[`vehicle`,`features`,`mirror`,`rearview`],fileSvg:`svg/mirrorLeftBonnet.svg`},mirrorLeftDefault:{glyph:``,size:24,tags:[`vehicle`,`features`,`mirror`,`rearview`],fileSvg:`svg/mirrorLeftDefault.svg`},mirrorRightBigBottomWideAngle:{glyph:``,size:24,tags:[`vehicle`,`features`,`mirror`,`rearview`],fileSvg:`svg/mirrorRightBigBottomWideAngle.svg`},mirrorRightBigTop:{glyph:``,size:24,tags:[`vehicle`,`features`,`mirror`,`rearview`],fileSvg:`svg/mirrorRightBigTop.svg`},mirrorRightBig:{glyph:``,size:24,tags:[`vehicle`,`features`,`mirror`,`rearview`],fileSvg:`svg/mirrorRightBig.svg`},mirrorRightBonnet:{glyph:``,size:24,tags:[`vehicle`,`features`,`mirror`,`rearview`],fileSvg:`svg/mirrorRightBonnet.svg`},mirrorRightDefault:{glyph:``,size:24,tags:[`vehicle`,`features`,`mirror`,`rearview`],fileSvg:`svg/mirrorRightDefault.svg`},mirrorRoundWideAngle:{glyph:``,size:24,tags:[`vehicle`,`features`,`mirror`,`rearview`],fileSvg:`svg/mirrorRoundWideAngle.svg`},mirrorTopWideAngle:{glyph:``,size:24,tags:[`vehicle`,`features`,`mirror`,`rearview`],fileSvg:`svg/mirrorTopWideAngle.svg`},missionCheckboxCross:{glyph:``,size:24,tags:[`checkbox`,`selection`,`box`],fileSvg:`svg/missionCheckboxCross.svg`},mouseLMB:{glyph:``,size:24,tags:[`mouse`,`input`],fileSvg:`svg/mouseLMB.svg`},mouseMMB:{glyph:``,size:24,tags:[`mouse`,`input`],fileSvg:`svg/mouseMMB.svg`},mouseRMB:{glyph:``,size:24,tags:[`mouse`,`input`],fileSvg:`svg/mouseRMB.svg`},mouseWheel:{glyph:``,size:24,tags:[`mouse`,`input`],fileSvg:`svg/mouseWheel.svg`},mouseXAxis:{glyph:``,size:24,tags:[`mouse`,`input`],fileSvg:`svg/mouseXAxis.svg`},mouseXYAxis:{glyph:``,size:24,tags:[`mouse`,`input`],fileSvg:`svg/mouseXYAxis.svg`},mouseYAxis:{glyph:``,size:24,tags:[`mouse`,`input`],fileSvg:`svg/mouseYAxis.svg`},mouse:{glyph:``,size:24,tags:[`mouse`,`input`],fileSvg:`svg/mouse.svg`},move02:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/move02.svg`},move:{glyph:``,size:24,tags:[`decals`,`generic`],fileSvg:`svg/move.svg`},movieCamera:{glyph:``,size:24,tags:[`camera`],fileSvg:`svg/movieCamera.svg`},music:{glyph:``,size:24,tags:[`playback`],fileSvg:`svg/music.svg`},N2OButton:{glyph:``,size:24,tags:[`fuel`],fileSvg:`svg/N2OButton.svg`},N2OHoriz:{glyph:``,size:24,tags:[`fuel`],fileSvg:`svg/N2OHoriz.svg`},N2OVert:{glyph:``,size:24,tags:[`fuel`],fileSvg:`svg/N2OVert.svg`},nextTrack:{glyph:``,size:24,tags:[`playback`],fileSvg:`svg/nextTrack.svg`},night:{glyph:``,size:24,tags:[`environment`],fileSvg:`svg/night.svg`},noNameControllerButton:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/noNameControllerButton.svg`},nodeAddFirst01:{glyph:``,size:24,tags:[`generic`,`path`,`node`],fileSvg:`svg/nodeAddFirst01.svg`},nodeAddFirst02:{glyph:``,size:24,tags:[`generic`,`path`,`node`],fileSvg:`svg/nodeAddFirst02.svg`},nodeAddLast02:{glyph:``,size:24,tags:[`generic`,`path`,`node`],fileSvg:`svg/nodeAddLast02.svg`},nodeAddMiddle01:{glyph:``,size:24,tags:[`generic`,`path`,`node`],fileSvg:`svg/nodeAddMiddle01.svg`},nodeAddMiddle02:{glyph:``,size:24,tags:[`generic`,`path`,`node`],fileSvg:`svg/nodeAddMiddle02.svg`},nodeAdd:{glyph:``,size:24,tags:[`generic`,`path`,`node`],fileSvg:`svg/nodeAdd.svg`},nodeLast01:{glyph:``,size:24,tags:[`generic`,`path`,`node`],fileSvg:`svg/nodeLast01.svg`},nodeRemove:{glyph:``,size:24,tags:[`generic`,`path`,`node`],fileSvg:`svg/nodeRemove.svg`},odometerKM:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/odometerKM.svg`},odometerMI:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/odometerMI.svg`},odometer:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/odometer.svg`},oilPressureIndicator:{glyph:``,size:24,tags:[`vehicle`,`features`,`warning`,`internals`],fileSvg:`svg/oilPressureIndicator.svg`},order:{glyph:``,size:24,tags:[`decals`,`generic`],fileSvg:`svg/order.svg`},organization:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/organization.svg`},palmCrossed:{glyph:``,size:24,tags:[`touch`,`input`],fileSvg:`svg/palmCrossed.svg`},paperKnife:{glyph:``,size:24,tags:[`decals`,`generic`],fileSvg:`svg/paperKnife.svg`},parkingIndicator:{glyph:``,size:24,tags:[`vehicle`,`features`,`warning`,`internals`],fileSvg:`svg/parkingIndicator.svg`},parking:{glyph:``,size:24,tags:[`poi`],fileSvg:`svg/parking.svg`},pathArc:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`,`road tools`],fileSvg:`svg/pathArc.svg`},pathAroundObstacle:{glyph:``,size:24,tags:[`camera`],fileSvg:`svg/pathAroundObstacle.svg`},pathLine:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`,`road tools`],fileSvg:`svg/pathLine.svg`},pathSpiral:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`,`road tools`],fileSvg:`svg/pathSpiral.svg`},pauseRound:{glyph:``,size:24,tags:[`playback`],fileSvg:`svg/pauseRound.svg`},pause:{glyph:``,size:24,tags:[`playback`],fileSvg:`svg/pause.svg`},personSolid:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/personSolid.svg`},person:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/person.svg`},photo:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/photo.svg`},placeholder:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/placeholder.svg`},playRound:{glyph:``,size:24,tags:[`playback`],fileSvg:`svg/playRound.svg`},play:{glyph:``,size:24,tags:[`playback`],fileSvg:`svg/play.svg`},playlist:{glyph:``,size:24,tags:[`playback`],fileSvg:`svg/playlist.svg`},plusGarage1:{glyph:``,size:24,tags:[`career`,`garage`,`features`],fileSvg:`svg/plusGarage1.svg`},plusGarage2:{glyph:``,size:24,tags:[`career`,`garage`,`features`],fileSvg:`svg/plusGarage2.svg`},plusGarage3:{glyph:``,size:24,tags:[`career`,`garage`,`features`],fileSvg:`svg/plusGarage3.svg`},plusGarage4:{glyph:``,size:24,tags:[`career`,`garage`,`features`],fileSvg:`svg/plusGarage4.svg`},plusSet:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/plusSet.svg`},plus:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/plus.svg`},positionLights:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/positionLights.svg`},powerGauge01:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/powerGauge01.svg`},powerGauge02:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/powerGauge02.svg`},powerGauge03:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/powerGauge03.svg`},powerGauge04:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/powerGauge04.svg`},powerGauge05:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/powerGauge05.svg`},powerOnOff:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/powerOnOff.svg`},prevTrack:{glyph:``,size:24,tags:[`playback`],fileSvg:`svg/prevTrack.svg`},publisher:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/publisher.svg`},puzzleModule:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/puzzleModule.svg`},raceFlag:{glyph:``,size:24,tags:[`poi`],fileSvg:`svg/raceFlag.svg`},radarIdeal:{glyph:``,size:24,tags:[`generic`,`data`,`signal`,`sensor`],fileSvg:`svg/radarIdeal.svg`},radarRoundIdeal:{glyph:``,size:24,tags:[`generic`,`data`,`signal`,`sensor`],fileSvg:`svg/radarRoundIdeal.svg`},radarRound:{glyph:``,size:24,tags:[`generic`,`data`,`signal`,`sensor`],fileSvg:`svg/radarRound.svg`},radar:{glyph:``,size:24,tags:[`generic`,`data`,`signal`,`sensor`],fileSvg:`svg/radar.svg`},rangeboxHi2:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/rangeboxHi2.svg`},rangeboxHi4:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/rangeboxHi4.svg`},rangeboxHiA:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/rangeboxHiA.svg`},rangeboxLo2:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/rangeboxLo2.svg`},rangeboxLo4:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/rangeboxLo4.svg`},rangeboxLoA:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/rangeboxLoA.svg`},rearAxleMidpoint:{glyph:``,size:24,tags:[`generic`,`world editor`,`we`,`placement`,`sensor`],fileSvg:`svg/rearAxleMidpoint.svg`},rearBumperMidpoint:{glyph:``,size:24,tags:[`generic`,`world editor`,`we`,`placement`,`sensor`],fileSvg:`svg/rearBumperMidpoint.svg`},reconfigure:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/reconfigure.svg`},redo:{glyph:``,size:24,tags:[`decals`,`generic`],fileSvg:`svg/redo.svg`},reflectNot:{glyph:``,size:24,tags:[`decals`,`generic`],fileSvg:`svg/reflectNot.svg`},reflect:{glyph:``,size:24,tags:[`decals`,`generic`],fileSvg:`svg/reflect.svg`},rename:{glyph:``,size:24,tags:[`decals`,`generic`],fileSvg:`svg/rename.svg`},replay:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/replay.svg`},restart:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/restart.svg`},roadDividerLinesDecal:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`,`road tools`],fileSvg:`svg/roadDividerLinesDecal.svg`},roadEdgeLineDecal:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`,`road tools`],fileSvg:`svg/roadEdgeLineDecal.svg`},roadEndLineDecal:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`,`road tools`],fileSvg:`svg/roadEndLineDecal.svg`},roadFace:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`,`road tools`],fileSvg:`svg/roadFace.svg`},roadInfo:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/roadInfo.svg`},roadMarkingOutline:{glyph:``,size:24,tags:[`generic`,`world editor`,`we`,`outlined`],fileSvg:`svg/roadMarkingOutline.svg`},roadMarkingSolid:{glyph:``,size:24,tags:[`generic`,`world editor`,`we`,`road tools`],fileSvg:`svg/roadMarkingSolid.svg`},roadOutline:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`,`road tools`],fileSvg:`svg/roadOutline.svg`},roadRefPathDecal:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`,`road tools`],fileSvg:`svg/roadRefPathDecal.svg`},roadRefPath:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`,`road tools`],fileSvg:`svg/roadRefPath.svg`},roadStartLineDecal:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`,`road tools`],fileSvg:`svg/roadStartLineDecal.svg`},road:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/road.svg`},rockCrawling01:{glyph:``,size:24,tags:[`poi`,`vehicle`],fileSvg:`svg/rockCrawling01.svg`},rockCrawling02:{glyph:``,size:24,tags:[`poi`],fileSvg:`svg/rockCrawling02.svg`},routeAdd:{glyph:``,size:24,tags:[`route`,`traffic`],fileSvg:`svg/routeAdd.svg`},routeComplex:{glyph:``,size:24,tags:[`route`,`traffic`],fileSvg:`svg/routeComplex.svg`},routeSimple:{glyph:``,size:24,tags:[`route`,`traffic`],fileSvg:`svg/routeSimple.svg`},runScript:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/runScript.svg`},RWD:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/RWD.svg`},saveAs1:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/saveAs1.svg`},scan:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/scan.svg`},search:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/search.svg`},semiTrailer:{glyph:``,size:24,tags:[`cargo`,`delivery`,`trailer`,`vehicle`],fileSvg:`svg/semiTrailer.svg`},semiTruckCabover:{glyph:``,size:24,tags:[`cargo`,`delivery`,`vehicle`,`truck`],fileSvg:`svg/semiTruckCabover.svg`},semiTruckUS:{glyph:``,size:24,tags:[`cargo`,`delivery`,`vehicle`,`truck`],fileSvg:`svg/semiTruckUS.svg`},semiTruck:{glyph:``,size:24,tags:[`cargo`,`delivery`,`truck`,`trailer`,`vehicle`],fileSvg:`svg/semiTruck.svg`},shortRangeBeam1:{glyph:``,size:24,tags:[`generic`,`world editor`,`we`,`sensor`],fileSvg:`svg/shortRangeBeam1.svg`},shortRangeBeam2:{glyph:``,size:24,tags:[`generic`,`world editor`,`we`,`sensor`],fileSvg:`svg/shortRangeBeam2.svg`},signal01a:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/signal01a.svg`},signal02a:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/signal02a.svg`},signal03a:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/signal03a.svg`},signal04a:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/signal04a.svg`},signal05a:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/signal05a.svg`},slashLeft:{glyph:``,size:24,tags:[`generic`,`math`,`operands`,`small`],fileSvg:`svg/slashLeft.svg`},slashRight:{glyph:``,size:24,tags:[`generic`,`math`,`operands`,`small`],fileSvg:`svg/slashRight.svg`},smallTrailer:{glyph:``,size:24,tags:[`cargo`,`delivery`,`trailer`,`vehicle`],fileSvg:`svg/smallTrailer.svg`},smartphone1:{glyph:``,size:24,tags:[`touch`,`input`],fileSvg:`svg/smartphone1.svg`},smartphone2:{glyph:``,size:24,tags:[`touch`,`input`],fileSvg:`svg/smartphone2.svg`},snowflake:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/snowflake.svg`},soundFadeOut:{glyph:``,size:24,tags:[`generic`,`sound`],fileSvg:`svg/soundFadeOut.svg`},soundLimit:{glyph:``,size:24,tags:[`generic`,`sound`],fileSvg:`svg/soundLimit.svg`},soundLoud:{glyph:``,size:24,tags:[`generic`,`sound`],fileSvg:`svg/soundLoud.svg`},soundMonoL:{glyph:``,size:24,tags:[`generic`,`sound`],fileSvg:`svg/soundMonoL.svg`},soundMonoR:{glyph:``,size:24,tags:[`generic`,`sound`],fileSvg:`svg/soundMonoR.svg`},soundOff:{glyph:``,size:24,tags:[`generic`,`sound`],fileSvg:`svg/soundOff.svg`},soundQuiet:{glyph:``,size:24,tags:[`generic`,`sound`],fileSvg:`svg/soundQuiet.svg`},soundStereo:{glyph:``,size:24,tags:[`generic`,`sound`],fileSvg:`svg/soundStereo.svg`},soundWave01:{glyph:``,size:24,tags:[`generic`,`sound`],fileSvg:`svg/soundWave01.svg`},soundWave02:{glyph:``,size:24,tags:[`generic`,`sound`],fileSvg:`svg/soundWave02.svg`},sphereOnPathNumber:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`,`road tools`],fileSvg:`svg/sphereOnPathNumber.svg`},sphereOnPath:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`,`road tools`],fileSvg:`svg/sphereOnPath.svg`},sphericalBeam:{glyph:``,size:24,tags:[`generic`,`world editor`,`we`,`sensor`],fileSvg:`svg/sphericalBeam.svg`},spoilerLift:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/spoilerLift.svg`},sprayCan:{glyph:``,size:24,tags:[`decals`,`generic`],fileSvg:`svg/sprayCan.svg`},stack3:{glyph:``,size:24,tags:[`delivery`,`stencil`,`cargo`],fileSvg:`svg/stack3.svg`},star:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/star.svg`},starSecondary:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/starSecondary.svg`},steeringWheelCommon:{glyph:``,size:24,tags:[`steering`,`controller`,`input`],fileSvg:`svg/steeringWheelCommon.svg`},steeringWheelSporty:{glyph:``,size:24,tags:[`steering`,`controller`,`input`],fileSvg:`svg/steeringWheelSporty.svg`},stopwatchArrows01:{glyph:``,size:24,tags:[`generic`,`time`,`fast`],fileSvg:`svg/stopwatchArrows01.svg`},stopwatchArrows02:{glyph:``,size:24,tags:[`generic`,`time`,`fast`],fileSvg:`svg/stopwatchArrows02.svg`},stopwatchSectionOutlinedEnd:{glyph:``,size:24,tags:[`generic`,`time`,`fast`],fileSvg:`svg/stopwatchSectionOutlinedEnd.svg`},stopwatchSectionOutlinedStart:{glyph:``,size:24,tags:[`generic`,`time`,`fast`],fileSvg:`svg/stopwatchSectionOutlinedStart.svg`},stopwatchSectionSolidEnd:{glyph:``,size:24,tags:[`generic`,`time`,`fast`],fileSvg:`svg/stopwatchSectionSolidEnd.svg`},stopwatchSectionSolidStart:{glyph:``,size:24,tags:[`generic`,`time`,`fast`],fileSvg:`svg/stopwatchSectionSolidStart.svg`},strobeLights:{glyph:``,size:24,tags:[`vehicle`,`features`,`police`,`emergency`],fileSvg:`svg/strobeLights.svg`},sunRise:{glyph:``,size:24,tags:[`environment`],fileSvg:`svg/sunRise.svg`},survellianceCamera:{glyph:``,size:24,tags:[`generic`,`camera`,`optical`,`sensor`],fileSvg:`svg/survellianceCamera.svg`},suspension01:{glyph:``,size:24,tags:[`vehicle`,`features`,`part`],fileSvg:`svg/suspension01.svg`},suspension02:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/suspension02.svg`},switchBlock:{glyph:``,size:24,tags:[`generic`,`circuit`,`electronics`,`switch`],fileSvg:`svg/switchBlock.svg`},switchOutline:{glyph:``,size:24,tags:[`generic`,`circuit`,`electronics`,`switch`],fileSvg:`svg/switchOutline.svg`},sync:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/sync.svg`},synchro01:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/synchro01.svg`},synchro02:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/synchro02.svg`},tankerTrailer:{glyph:``,size:24,tags:[`cargo`,`delivery`,`tank`,`tanker`,`trailer`,`vehicle`],fileSvg:`svg/tankerTrailer.svg`},targetJump:{glyph:``,size:24,tags:[`poi`],fileSvg:`svg/targetJump.svg`},taxiCar1:{glyph:``,size:24,tags:[`taxi`,`generic`,`vehicle`],fileSvg:`svg/taxiCar1.svg`},taxiCar3:{glyph:``,size:24,tags:[`taxi`,`generic`,`vehicle`],fileSvg:`svg/taxiCar3.svg`},taxiCarT:{glyph:``,size:24,tags:[`taxi`,`generic`,`vehicle`],fileSvg:`svg/taxiCarT.svg`},taxiCheckerLamp:{glyph:``,size:24,tags:[`taxi`,`generic`,`vehicle`],fileSvg:`svg/taxiCheckerLamp.svg`},terrainToLine:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`,`road tools`],fileSvg:`svg/terrainToLine.svg`},terrain:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/terrain.svg`},thinBulbBeam:{glyph:``,size:24,tags:[`generic`,`world editor`,`we`,`sensor`],fileSvg:`svg/thinBulbBeam.svg`},thinnerBulbBeam:{glyph:``,size:24,tags:[`generic`,`world editor`,`we`,`sensor`],fileSvg:`svg/thinnerBulbBeam.svg`},thisSideUp:{glyph:``,size:24,tags:[`delivery`,`stencil`,`cargo`],fileSvg:`svg/thisSideUp.svg`},tiles:{glyph:``,size:24,tags:[`generic`,`catalog`,`selector`,`view`],fileSvg:`svg/tiles.svg`},timer:{glyph:``,size:24,tags:[`generic`,`time`,`fast`],fileSvg:`svg/timer.svg`},tireDirection3Fourth2:{glyph:``,size:24,tags:[`tire`],fileSvg:`svg/tireDirection3Fourth2.svg`},tireDirection3Fourth3:{glyph:``,size:24,tags:[`tire`],fileSvg:`svg/tireDirection3Fourth3.svg`},tireDirectionFront2:{glyph:``,size:24,tags:[`tire`],fileSvg:`svg/tireDirectionFront2.svg`},tireDirectionSide2:{glyph:``,size:24,tags:[`tire`],fileSvg:`svg/tireDirectionSide2.svg`},tireDirectionTop2:{glyph:``,size:24,tags:[`tire`],fileSvg:`svg/tireDirectionTop2.svg`},tirePressureDecrease01:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/tirePressureDecrease01.svg`},tirePressureDecrease02:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/tirePressureDecrease02.svg`},tirePressureGaugeAlt01:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/tirePressureGaugeAlt01.svg`},tirePressureGaugeAlt02:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/tirePressureGaugeAlt02.svg`},tirePressureGaugeAlt03:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/tirePressureGaugeAlt03.svg`},tirePressureGaugeOutlined01:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/tirePressureGaugeOutlined01.svg`},tirePressureGaugeOutlined02:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/tirePressureGaugeOutlined02.svg`},tirePressureGaugeOutlined03:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/tirePressureGaugeOutlined03.svg`},tirePressureGaugeSolid01:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/tirePressureGaugeSolid01.svg`},tirePressureGaugeSolid02:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/tirePressureGaugeSolid02.svg`},tirePressureGaugeSolid03:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/tirePressureGaugeSolid03.svg`},tirePressureIncrease01:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/tirePressureIncrease01.svg`},tirePressureIncrease02:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/tirePressureIncrease02.svg`},tirePressureStopLine:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/tirePressureStopLine.svg`},tirePressureStopOctoLine:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/tirePressureStopOctoLine.svg`},tirePressureStopOctoSolid:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/tirePressureStopOctoSolid.svg`},tirePressureStopSolid:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/tirePressureStopSolid.svg`},toCOMWithWheels:{glyph:``,size:24,tags:[`generic`,`world editor`,`we`,`placement`,`sensor`],fileSvg:`svg/toCOMWithWheels.svg`},toCOM:{glyph:``,size:24,tags:[`generic`,`world editor`,`we`,`placement`,`sensor`],fileSvg:`svg/toCOM.svg`},toGarage:{glyph:``,size:24,tags:[`poi`],fileSvg:`svg/toGarage.svg`},touch:{glyph:``,size:24,tags:[`touch`,`input`],fileSvg:`svg/touch.svg`},tow:{glyph:``,size:24,tags:[`generic`,`vehicle`],fileSvg:`svg/tow.svg`},tractionControl:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/tractionControl.svg`},trafficCone:{glyph:``,size:24,tags:[`route`,`traffic`],fileSvg:`svg/trafficCone.svg`},transform:{glyph:``,size:24,tags:[`decals`,`generic`],fileSvg:`svg/transform.svg`},transmissionA:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/transmissionA.svg`},transmissionM:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/transmissionM.svg`},transparencyMask:{glyph:``,size:24,tags:[`decals`,`generic`],fileSvg:`svg/transparencyMask.svg`},trashBin1:{glyph:``,size:24,tags:[`poi`],fileSvg:`svg/trashBin1.svg`},trashBin2:{glyph:``,size:24,tags:[`decals`,`generic`],fileSvg:`svg/trashBin2.svg`},triangleBeam:{glyph:``,size:24,tags:[`generic`,`world editor`,`we`,`sensor`],fileSvg:`svg/triangleBeam.svg`},trim:{glyph:``,size:24,tags:[`generic`,`sound`],fileSvg:`svg/trim.svg`},tulipBeam:{glyph:``,size:24,tags:[`generic`,`world editor`,`we`,`sensor`],fileSvg:`svg/tulipBeam.svg`},tunnel:{glyph:``,size:24,tags:[`generic`,`world editor`,`we`,`road tools`],fileSvg:`svg/tunnel.svg`},turbine:{glyph:``,size:24,tags:[`vehicle`,`part`,`features`],fileSvg:`svg/turbine.svg`},twoRoadsAdd:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`,`road tools`],fileSvg:`svg/twoRoadsAdd.svg`},twoRoadsCrossAdd:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`,`road tools`],fileSvg:`svg/twoRoadsCrossAdd.svg`},twoRoadsLink:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`,`road tools`],fileSvg:`svg/twoRoadsLink.svg`},twoUnicyclesOnly:{glyph:``,size:24,tags:[`delivery`,`stencil`,`cargo`],fileSvg:`svg/twoUnicyclesOnly.svg`},undo:{glyph:``,size:24,tags:[`decals`,`generic`],fileSvg:`svg/undo.svg`},ungroup:{glyph:``,size:24,tags:[`decals`,`generic`],fileSvg:`svg/ungroup.svg`},unlink:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/unlink.svg`},vehicleDoorsClose:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/vehicleDoorsClose.svg`},vehicleDoorsOpen:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/vehicleDoorsOpen.svg`},vehicleDoors:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/vehicleDoors.svg`},vehicleFeatures01:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/vehicleFeatures01.svg`},vehicleFeatures02:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/vehicleFeatures02.svg`},vehicleFeatures03:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/vehicleFeatures03.svg`},vehicleHood:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/vehicleHood.svg`},vehicleTrunk:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/vehicleTrunk.svg`},view:{glyph:``,size:24,tags:[`decals`,`generic`],fileSvg:`svg/view.svg`},voucherDiagonal1:{glyph:``,size:24,tags:[`generic`,`currency`,`reward`,`career`],fileSvg:`svg/voucherDiagonal1.svg`},voucherDiagonal2:{glyph:``,size:24,tags:[`generic`,`currency`,`reward`,`career`],fileSvg:`svg/voucherDiagonal2.svg`},voucherDiagonal3:{glyph:``,size:24,tags:[`generic`,`currency`,`reward`,`career`],fileSvg:`svg/voucherDiagonal3.svg`},voucherHorizontal1:{glyph:``,size:24,tags:[`generic`,`currency`,`reward`,`career`],fileSvg:`svg/voucherHorizontal1.svg`},voucherHorizontal2:{glyph:``,size:24,tags:[`generic`,`currency`,`reward`,`career`],fileSvg:`svg/voucherHorizontal2.svg`},voucherHorizontal3:{glyph:``,size:24,tags:[`generic`,`currency`,`reward`,`career`],fileSvg:`svg/voucherHorizontal3.svg`},wavesSignalReceived:{glyph:``,size:24,tags:[`generic`,`data`,`signal`,`sensor`],fileSvg:`svg/wavesSignalReceived.svg`},wavesSignalSentLeft:{glyph:``,size:24,tags:[`generic`,`data`,`signal`,`sensor`],fileSvg:`svg/wavesSignalSentLeft.svg`},wavesSignalSentRight:{glyph:``,size:24,tags:[`generic`,`data`,`signal`,`sensor`],fileSvg:`svg/wavesSignalSentRight.svg`},weather:{glyph:``,size:24,tags:[`environment`],fileSvg:`svg/weather.svg`},weight:{glyph:``,size:24,tags:[`decals`,`generic`],fileSvg:`svg/weight.svg`},wheelHubLocked01:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/wheelHubLocked01.svg`},wheelHubUnlocked01:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/wheelHubUnlocked01.svg`},wigwags:{glyph:``,size:24,tags:[`vehicle`,`features`,`police`,`emergency`],fileSvg:`svg/wigwags.svg`},wrench:{glyph:``,size:24,tags:[`generic`,`vehicle`,`features`],fileSvg:`svg/wrench.svg`},xboxA:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/xboxA.svg`},xboxB:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/xboxB.svg`},xboxDDefaultOutline:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/xboxDDefaultOutline.svg`},xboxDDefaultSolid:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/xboxDDefaultSolid.svg`},xboxDDown:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/xboxDDown.svg`},xboxDLeft:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/xboxDLeft.svg`},xboxDRight:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/xboxDRight.svg`},xboxDUp:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/xboxDUp.svg`},xboxLB:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/xboxLB.svg`},xboxLSButton:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/xboxLSButton.svg`},xboxLT:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/xboxLT.svg`},xboxMenu:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/xboxMenu.svg`},xboxRB:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/xboxRB.svg`},xboxRSButton:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/xboxRSButton.svg`},xboxRT:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/xboxRT.svg`},xboxThumbL:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/xboxThumbL.svg`},xboxThumbR:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/xboxThumbR.svg`},xboxView:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/xboxView.svg`},xboxXAxis:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/xboxXAxis.svg`},xboxXRot:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/xboxXRot.svg`},xboxX:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/xboxX.svg`},xboxYAxis:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/xboxYAxis.svg`},xboxYRot:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/xboxYRot.svg`},xboxY:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/xboxY.svg`},AIL:{glyph:``,size:48,tags:[`extra`],fileSvg:`svg/AIL.svg`},arrowLeftOutline:{glyph:``,size:48,tags:[`web`,`outlined`,`large`,`secondary`],fileSvg:`svg/arrowLeftOutline.svg`},arrowRightOutline:{glyph:``,size:48,tags:[`web`,`outlined`,`large`,`secondary`],fileSvg:`svg/arrowRightOutline.svg`},automaticTransmissionL:{glyph:``,size:48,tags:[`extra`],fileSvg:`svg/automaticTransmissionL.svg`},beamsNodesMessageOutline:{glyph:``,size:48,tags:[`web`,`outlined`,`large`,`secondary`],fileSvg:`svg/beamsNodesMessageOutline.svg`},beamsNodesOutline:{glyph:``,size:48,tags:[`web`,`outlined`,`large`,`secondary`],fileSvg:`svg/beamsNodesOutline.svg`},beamsNodesPlugOutline:{glyph:``,size:48,tags:[`web`,`outlined`,`large`,`secondary`],fileSvg:`svg/beamsNodesPlugOutline.svg`},BNGEcosystemOutline:{glyph:``,size:48,tags:[`web`,`outlined`,`large`,`secondary`],fileSvg:`svg/BNGEcosystemOutline.svg`},carFrontRouteOutline:{glyph:``,size:48,tags:[`web`,`outlined`,`large`,`secondary`],fileSvg:`svg/carFrontRouteOutline.svg`},carSensorsOutline:{glyph:``,size:48,tags:[`web`,`outlined`,`large`,`secondary`],fileSvg:`svg/carSensorsOutline.svg`},carSideRouteOutline:{glyph:``,size:48,tags:[`web`,`outlined`,`large`,`secondary`],fileSvg:`svg/carSideRouteOutline.svg`},chargeLL:{glyph:``,size:48,tags:[`extra`],fileSvg:`svg/chargeLL.svg`},cityOutline:{glyph:``,size:48,tags:[`web`,`outlined`,`large`,`secondary`],fileSvg:`svg/cityOutline.svg`},clutchL:{glyph:``,size:48,tags:[`extra`],fileSvg:`svg/clutchL.svg`},couplerL:{glyph:``,size:48,tags:[`extra`],fileSvg:`svg/couplerL.svg`},dialogOutline:{glyph:``,size:48,tags:[`web`,`outlined`,`large`,`secondary`],fileSvg:`svg/dialogOutline.svg`},documentSmileOutline:{glyph:``,size:48,tags:[`web`,`outlined`,`large`,`secondary`],fileSvg:`svg/documentSmileOutline.svg`},drivetrainOutline:{glyph:``,size:48,tags:[`web`,`outlined`,`large`,`secondary`],fileSvg:`svg/drivetrainOutline.svg`},electronicSchemeOutline:{glyph:``,size:48,tags:[`web`,`outlined`,`large`,`secondary`],fileSvg:`svg/electronicSchemeOutline.svg`},engineL:{glyph:``,size:48,tags:[`extra`],fileSvg:`svg/engineL.svg`},engineOutline:{glyph:``,size:48,tags:[`web`,`outlined`,`large`,`secondary`],fileSvg:`svg/engineOutline.svg`},gearTuningOutline:{glyph:``,size:48,tags:[`web`,`outlined`,`large`,`secondary`],fileSvg:`svg/gearTuningOutline.svg`},giftBoxOutline:{glyph:``,size:48,tags:[`web`,`outlined`,`large`,`secondary`],fileSvg:`svg/giftBoxOutline.svg`},lidarOutline:{glyph:``,size:48,tags:[`web`,`outlined`,`large`,`secondary`],fileSvg:`svg/lidarOutline.svg`},medalStarOutline:{glyph:``,size:48,tags:[`web`,`outlined`,`large`,`secondary`],fileSvg:`svg/medalStarOutline.svg`},megaphoneOutline:{glyph:``,size:48,tags:[`web`,`outlined`,`large`,`secondary`],fileSvg:`svg/megaphoneOutline.svg`},multiseatL:{glyph:``,size:48,tags:[`extra`],fileSvg:`svg/multiseatL.svg`},peopleOutline:{glyph:``,size:48,tags:[`web`,`outlined`,`large`,`secondary`],fileSvg:`svg/peopleOutline.svg`},personOutline:{glyph:``,size:48,tags:[`web`,`outlined`,`large`,`secondary`],fileSvg:`svg/personOutline.svg`},physicsOutline:{glyph:``,size:48,tags:[`web`,`outlined`,`large`,`secondary`],fileSvg:`svg/physicsOutline.svg`},playChainOutline:{glyph:``,size:48,tags:[`web`,`outlined`,`large`,`secondary`],fileSvg:`svg/playChainOutline.svg`},POITimeL:{glyph:``,size:48,tags:[`extra`],fileSvg:`svg/POITimeL.svg`},proximitySensorsOutline:{glyph:``,size:48,tags:[`web`,`outlined`,`large`,`secondary`],fileSvg:`svg/proximitySensorsOutline.svg`},qualityBadgeStarOutline:{glyph:``,size:48,tags:[`web`,`outlined`,`large`,`secondary`],fileSvg:`svg/qualityBadgeStarOutline.svg`},qualityBadgeVOutline:{glyph:``,size:48,tags:[`web`,`outlined`,`large`,`secondary`],fileSvg:`svg/qualityBadgeVOutline.svg`},replayL:{glyph:``,size:48,tags:[`extra`],fileSvg:`svg/replayL.svg`},roadblockL:{glyph:``,size:48,tags:[`extra`],fileSvg:`svg/roadblockL.svg`},rotationL:{glyph:``,size:48,tags:[`extra`],fileSvg:`svg/rotationL.svg`},sensorsL:{glyph:``,size:48,tags:[`extra`],fileSvg:`svg/sensorsL.svg`},simRigOutline:{glyph:``,size:48,tags:[`web`,`outlined`,`large`,`secondary`],fileSvg:`svg/simRigOutline.svg`},suspensionOutline:{glyph:``,size:48,tags:[`web`,`outlined`,`large`,`secondary`],fileSvg:`svg/suspensionOutline.svg`},teamOutline:{glyph:``,size:48,tags:[`web`,`outlined`,`large`,`secondary`],fileSvg:`svg/teamOutline.svg`},techLightBulbOutline01:{glyph:``,size:48,tags:[`web`,`outlined`,`large`,`secondary`],fileSvg:`svg/techLightBulbOutline01.svg`},techLightBulbOutline02:{glyph:``,size:48,tags:[`web`,`outlined`,`large`,`secondary`],fileSvg:`svg/techLightBulbOutline02.svg`},temperatureL:{glyph:``,size:48,tags:[`extra`],fileSvg:`svg/temperatureL.svg`},timeUnlockOutline:{glyph:``,size:48,tags:[`web`,`outlined`,`large`,`secondary`],fileSvg:`svg/timeUnlockOutline.svg`},timedLockOutline:{glyph:``,size:48,tags:[`web`,`outlined`,`large`,`secondary`],fileSvg:`svg/timedLockOutline.svg`},trafficOutline:{glyph:``,size:48,tags:[`web`,`outlined`,`large`,`secondary`],fileSvg:`svg/trafficOutline.svg`},tuningL:{glyph:``,size:48,tags:[`extra`],fileSvg:`svg/tuningL.svg`},turbineL:{glyph:``,size:48,tags:[`extra`],fileSvg:`svg/turbineL.svg`},voucherOutline:{glyph:``,size:48,tags:[`web`,`outlined`,`large`,`secondary`],fileSvg:`svg/voucherOutline.svg`},wheelBeamsNodesOutline:{glyph:``,size:48,tags:[`web`,`outlined`,`large`,`secondary`],fileSvg:`svg/wheelBeamsNodesOutline.svg`},wheelOutline:{glyph:``,size:48,tags:[`web`,`outlined`,`large`,`secondary`],fileSvg:`svg/wheelOutline.svg`},circlePinBack:{glyph:``,size:56,tags:[`poi`],fileSvg:`svg/circlePinBack.svg`},circlePinFront:{glyph:``,size:56,tags:[`poi`],fileSvg:`svg/circlePinFront.svg`},markerRectanglePinBack:{glyph:``,size:56,tags:[`poi`],fileSvg:`svg/markerRectanglePinBack.svg`},markerRectanglePinFront:{glyph:``,size:56,tags:[`poi`],fileSvg:`svg/markerRectanglePinFront.svg`},markerTriangleBack:{glyph:``,size:56,tags:[`poi`],fileSvg:`svg/markerTriangleBack.svg`},markerTriangleFront:{glyph:``,size:56,tags:[`poi`],fileSvg:`svg/markerTriangleFront.svg`},danger:{glyph:``,size:24,tags:[`generic`,`hazard`],fileSvg:`svg/danger.svg`},droplet:{glyph:``,size:24,tags:[`generic`,`drop`,`liquid`],fileSvg:`svg/droplet.svg`},envelope:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/envelope.svg`},fireDiamond:{glyph:``,size:24,tags:[`generic`,`hazard`,`nfpa704`],fileSvg:`svg/fireDiamond.svg`},rocks:{glyph:``,size:24,tags:[`dry cargo`,`dry`],fileSvg:`svg/rocks.svg`},xmark:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/xmark.svg`},scale:{glyph:``,size:24,tags:[`decals`,`editor`,`generic`],fileSvg:`svg/scale.svg`},arrowsUp:{glyph:``,size:16,tags:[`marker`,`ribbon`,`content-props`],fileSvg:`svg/arrowsUp.svg`},bigDot:{glyph:``,size:16,tags:[`marker`,`ribbon`,`content-props`],fileSvg:`svg/bigDot.svg`},connectorBold:{glyph:``,size:16,tags:[`marker`,`ribbon`,`content-props`],fileSvg:`svg/connectorBold.svg`},cornerTopRight:{glyph:``,size:16,tags:[`marker`,`ribbon`,`content-props`],fileSvg:`svg/cornerTopRight.svg`},plusBold:{glyph:``,size:16,tags:[`marker`,`ribbon`,`content-props`],fileSvg:`svg/plusBold.svg`},puzzlePieceBold:{glyph:``,size:16,tags:[`marker`,`ribbon`,`content-props`],fileSvg:`svg/puzzlePieceBold.svg`},locationDestination:{glyph:``,size:24,tags:[`generic`,`location`,`route`,`path`,`node`],fileSvg:`svg/locationDestination.svg`},locationSource:{glyph:``,size:24,tags:[`generic`,`location`,`route`,`path`,`node`],fileSvg:`svg/locationSource.svg`},accelerationKPH:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/accelerationKPH.svg`},accelerationMPH:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/accelerationMPH.svg`},boxTruckFast:{glyph:``,size:24,tags:[`cargo`,`delivery`,`vehicle`],fileSvg:`svg/boxTruckFast.svg`},colorBrightnessSun:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/colorBrightnessSun.svg`},colorCirclePalette:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/colorCirclePalette.svg`},colorPalette:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/colorPalette.svg`},colorSaturation:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/colorSaturation.svg`},sortAscDown02:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/sortAscDown02.svg`},sortAscDown:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/sortAscDown.svg`},sortAscUp02:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/sortAscUp02.svg`},sortAscUp:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/sortAscUp.svg`},sortDescDown02:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/sortDescDown02.svg`},sortDescDown:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/sortDescDown.svg`},sortDescUp02:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/sortDescUp02.svg`},sortDescUp:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/sortDescUp.svg`},cardboardBoxCoins:{glyph:``,size:24,tags:[`generic`,`delivery`],fileSvg:`svg/cardboardBoxCoins.svg`},lasso:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`],fileSvg:`svg/lasso.svg`},materialGlossy:{glyph:``,size:24,tags:[`decals`,`generic`],fileSvg:`svg/materialGlossy.svg`},materialMetal:{glyph:``,size:24,tags:[`decals`,`generic`],fileSvg:`svg/materialMetal.svg`},materialRoughness:{glyph:``,size:24,tags:[`decals`,`generic`],fileSvg:`svg/materialRoughness.svg`},materialTransparency01:{glyph:``,size:24,tags:[`decals`,`generic`],fileSvg:`svg/materialTransparency01.svg`},materialTransparency02:{glyph:``,size:24,tags:[`decals`,`generic`],fileSvg:`svg/materialTransparency02.svg`},metal01:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/metal01.svg`},removeItemPolygon:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`,`road tools`],fileSvg:`svg/removeItemPolygon.svg`},removeListItem:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`,`road tools`],fileSvg:`svg/removeListItem.svg`},sortAsc:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/sortAsc.svg`},sortDesc:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/sortDesc.svg`},surfaceRoughness02:{glyph:``,size:24,tags:[`decals`,`generic`],fileSvg:`svg/surfaceRoughness02.svg`},shieldCheckmark:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/shieldCheckmark.svg`},shieldHandCheckmark:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/shieldHandCheckmark.svg`},shieldHandPlus:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/shieldHandPlus.svg`},doorFrontCoins:{glyph:``,size:24,tags:[`vehicle`,`part`,`features`],fileSvg:`svg/doorFrontCoins.svg`},doorFront:{glyph:``,size:24,tags:[`vehicle`,`part`,`features`],fileSvg:`svg/doorFront.svg`},engineCoins:{glyph:``,size:24,tags:[`vehicle`,`part`,`features`],fileSvg:`svg/engineCoins.svg`},exhaustMufflerCoins:{glyph:``,size:24,tags:[`vehicle`,`part`,`features`],fileSvg:`svg/exhaustMufflerCoins.svg`},exhaustMuffler:{glyph:``,size:24,tags:[`vehicle`,`part`,`features`],fileSvg:`svg/exhaustMuffler.svg`},headlightCoins:{glyph:``,size:24,tags:[`vehicle`,`part`,`features`],fileSvg:`svg/headlightCoins.svg`},headlight:{glyph:``,size:24,tags:[`vehicle`,`part`,`features`],fileSvg:`svg/headlight.svg`},tire3FourthCoins:{glyph:``,size:24,tags:[`vehicle`,`part`,`features`,`tire`],fileSvg:`svg/tire3FourthCoins.svg`},tire3Fourth:{glyph:``,size:24,tags:[`vehicle`,`part`,`features`,`tire`],fileSvg:`svg/tire3Fourth.svg`},turbineCoins:{glyph:``,size:24,tags:[`vehicle`,`part`,`features`],fileSvg:`svg/turbineCoins.svg`},wheelDiscCoins:{glyph:``,size:24,tags:[`vehicle`,`part`,`features`],fileSvg:`svg/wheelDiscCoins.svg`},wheelDisc:{glyph:``,size:24,tags:[`vehicle`,`part`,`features`],fileSvg:`svg/wheelDisc.svg`},bridgeWithRiver:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`,`road tools`],fileSvg:`svg/bridgeWithRiver.svg`},gizmosOutline:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`,`road tools`],fileSvg:`svg/gizmosOutline.svg`},gizmosSolid:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`,`road tools`],fileSvg:`svg/gizmosSolid.svg`},highwayRoad3To2Merge01:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`,`road tools`],fileSvg:`svg/highwayRoad3To2Merge01.svg`},highwayRoad3To2Merge02:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`,`road tools`],fileSvg:`svg/highwayRoad3To2Merge02.svg`},highwayToUrbanRoadTransition01:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`,`road tools`],fileSvg:`svg/highwayToUrbanRoadTransition01.svg`},highwayToUrbanRoadTransition02:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`,`road tools`],fileSvg:`svg/highwayToUrbanRoadTransition02.svg`},pedestrianCrossing01:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`,`road tools`],fileSvg:`svg/pedestrianCrossing01.svg`},polygonalCube:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`,`road tools`],fileSvg:`svg/polygonalCube.svg`},roadEditOutline:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`,`road tools`],fileSvg:`svg/roadEditOutline.svg`},roadEditSolid:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`,`road tools`],fileSvg:`svg/roadEditSolid.svg`},roadFolderPlus:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`,`road tools`],fileSvg:`svg/roadFolderPlus.svg`},roadFolder:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`,`road tools`],fileSvg:`svg/roadFolder.svg`},roadGuideArrowOutline:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`,`road tools`],fileSvg:`svg/roadGuideArrowOutline.svg`},roadGuideArrowSolid:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`,`road tools`],fileSvg:`svg/roadGuideArrowSolid.svg`},roadOutlineMesh:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`,`road tools`],fileSvg:`svg/roadOutlineMesh.svg`},roadPedestrianCrossing02:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`,`road tools`],fileSvg:`svg/roadPedestrianCrossing02.svg`},roadProfileWithCheckmark:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`,`road tools`],fileSvg:`svg/roadProfileWithCheckmark.svg`},roadProfile:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`,`road tools`],fileSvg:`svg/roadProfile.svg`},roadRoundaboutJunction:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`,`road tools`],fileSvg:`svg/roadRoundaboutJunction.svg`},roadSidewalkTransition:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`,`road tools`],fileSvg:`svg/roadSidewalkTransition.svg`},roadStackPlus:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`,`road tools`],fileSvg:`svg/roadStackPlus.svg`},roadStack:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`,`road tools`],fileSvg:`svg/roadStack.svg`},roadTJunction:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`,`road tools`],fileSvg:`svg/roadTJunction.svg`},roadXJunction:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`,`road tools`],fileSvg:`svg/roadXJunction.svg`},roadYJunction:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`,`road tools`],fileSvg:`svg/roadYJunction.svg`},shoppingCart:{glyph:``,size:24,tags:[`generic`,`shop`,`purchase`],fileSvg:`svg/shoppingCart.svg`},singleLineToTerrain:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`,`road tools`],fileSvg:`svg/singleLineToTerrain.svg`},sphereOnMesh:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`,`road tools`],fileSvg:`svg/sphereOnMesh.svg`},twoLinesToTerrain:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`,`road tools`],fileSvg:`svg/twoLinesToTerrain.svg`},urbanRoad3To2Merge01:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`,`road tools`],fileSvg:`svg/urbanRoad3To2Merge01.svg`},urbanRoad3To2Merge02:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`,`road tools`],fileSvg:`svg/urbanRoad3To2Merge02.svg`},urbanRoadToHighwayTransition01:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`,`road tools`],fileSvg:`svg/urbanRoadToHighwayTransition01.svg`},urbanRoadToHighwayTransition02:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`,`road tools`],fileSvg:`svg/urbanRoadToHighwayTransition02.svg`},floppyDiskPlus:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/floppyDiskPlus.svg`},highwayMerge:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`,`road tools`],fileSvg:`svg/highwayMerge.svg`},highwaySeparate:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`,`road tools`],fileSvg:`svg/highwaySeparate.svg`},highwayShoulderMerge:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`,`road tools`],fileSvg:`svg/highwayShoulderMerge.svg`},terrainToSingleLine:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`,`road tools`],fileSvg:`svg/terrainToSingleLine.svg`},terrainToTwoLines:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`,`road tools`],fileSvg:`svg/terrainToTwoLines.svg`},urbanRoadMerge:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`,`road tools`],fileSvg:`svg/urbanRoadMerge.svg`},urbanRoadSeparate:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`,`road tools`],fileSvg:`svg/urbanRoadSeparate.svg`},urbanShoulderMerge:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`,`road tools`],fileSvg:`svg/urbanShoulderMerge.svg`},discharging:{glyph:``,size:24,tags:[`fuel`,`electricity`,`ev`],fileSvg:`svg/discharging.svg`},BNGChat:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/BNGChat.svg`},chatBubble:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/chatBubble.svg`},busTilted:{glyph:``,size:24,tags:[`poi`,`vehicle`,`bus`],fileSvg:`svg/busTilted.svg`},cameraFarClip:{glyph:``,size:24,tags:[`decals`,`generic`],fileSvg:`svg/cameraFarClip.svg`},cameraNearClip:{glyph:``,size:24,tags:[`decals`,`generic`],fileSvg:`svg/cameraNearClip.svg`},explosion:{glyph:``,size:24,tags:[`generic`,`destruction`],fileSvg:`svg/explosion.svg`},fireExtinguisher:{glyph:``,size:24,tags:[`generic`,`destruction`],fileSvg:`svg/fireExtinguisher.svg`},fire:{glyph:``,size:24,tags:[`generic`,`destruction`],fileSvg:`svg/fire.svg`},jointLockedMultiple:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/jointLockedMultiple.svg`},jointUnlockedMultiple:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/jointUnlockedMultiple.svg`},toggleOff:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/toggleOff.svg`},toggleOn:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/toggleOn.svg`},viewFarClip:{glyph:``,size:24,tags:[`decals`,`generic`],fileSvg:`svg/viewFarClip.svg`},viewNearClip:{glyph:``,size:24,tags:[`decals`,`generic`],fileSvg:`svg/viewNearClip.svg`},twoArrowsHorizontal:{glyph:``,size:24,tags:[`arrow`,`large`,`solid`,`turn signals`],fileSvg:`svg/twoArrowsHorizontal.svg`},twoArrowsVertical:{glyph:``,size:24,tags:[`arrow`,`large`,`solid`,`turn signals`],fileSvg:`svg/twoArrowsVertical.svg`},bridge:{glyph:``,size:48,tags:[`rally`,`pace notes`,`directions`,`surface`,`features`],fileSvg:`svg/bridge.svg`},bump:{glyph:``,size:48,tags:[`rally`,`pace notes`,`directions`,`surface`,`features`],fileSvg:`svg/bump.svg`},bumps:{glyph:``,size:48,tags:[`rally`,`pace notes`,`directions`,`surface`,`features`],fileSvg:`svg/bumps.svg`},caution:{glyph:``,size:48,tags:[`rally`,`pace notes`,`directions`,`surface`,`features`],fileSvg:`svg/caution.svg`},crest:{glyph:``,size:48,tags:[`rally`,`pace notes`,`directions`,`surface`,`features`],fileSvg:`svg/crest.svg`},doubleCaution:{glyph:``,size:48,tags:[`rally`,`pace notes`,`directions`,`surface`,`features`],fileSvg:`svg/doubleCaution.svg`},finish:{glyph:``,size:48,tags:[`rally`,`pace notes`,`directions`,`surface`,`features`],fileSvg:`svg/finish.svg`},jumpOverBump:{glyph:``,size:48,tags:[`rally`,`pace notes`,`directions`,`surface`,`features`],fileSvg:`svg/jumpOverBump.svg`},narrows:{glyph:``,size:48,tags:[`rally`,`pace notes`,`directions`,`surface`,`features`],fileSvg:`svg/narrows.svg`},pothole:{glyph:``,size:48,tags:[`rally`,`pace notes`,`directions`,`surface`,`features`],fileSvg:`svg/pothole.svg`},turn1:{glyph:``,size:48,tags:[`rally`,`pace notes`,`directions`,`surface`,`features`],fileSvg:`svg/turn1.svg`},turn2:{glyph:``,size:48,tags:[`rally`,`pace notes`,`directions`,`surface`,`features`],fileSvg:`svg/turn2.svg`},turn3:{glyph:``,size:48,tags:[`rally`,`pace notes`,`directions`,`surface`,`features`],fileSvg:`svg/turn3.svg`},turn4:{glyph:``,size:48,tags:[`rally`,`pace notes`,`directions`,`surface`,`features`],fileSvg:`svg/turn4.svg`},turn5:{glyph:``,size:48,tags:[`rally`,`pace notes`,`directions`,`surface`,`features`],fileSvg:`svg/turn5.svg`},turn6:{glyph:``,size:48,tags:[`rally`,`pace notes`,`directions`,`surface`,`features`],fileSvg:`svg/turn6.svg`},turnHp:{glyph:``,size:48,tags:[`rally`,`pace notes`,`directions`,`surface`,`features`],fileSvg:`svg/turnHp.svg`},turnSq:{glyph:``,size:48,tags:[`rally`,`pace notes`,`directions`,`surface`,`features`],fileSvg:`svg/turnSq.svg`},water:{glyph:``,size:48,tags:[`rally`,`pace notes`,`directions`,`surface`,`features`],fileSvg:`svg/water.svg`},circleSlashed:{glyph:``,size:24,tags:[`generic`,`do not cut`,`no entry`],fileSvg:`svg/circleSlashed.svg`},scissorsSlashed:{glyph:``,size:24,tags:[`generic`,`do not cut`],fileSvg:`svg/scissorsSlashed.svg`},scissors:{glyph:``,size:24,tags:[`generic`,`cut`],fileSvg:`svg/scissors.svg`},airPuffRight1:{glyph:``,size:24,tags:[`generic`,`vehicle`,`car`],fileSvg:`svg/airPuffRight1.svg`},airPuffUp1:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/airPuffUp1.svg`},arrowsReplace:{glyph:``,size:24,tags:[`generic`,`arrow`],fileSvg:`svg/arrowsReplace.svg`},arrowsShuffle:{glyph:``,size:24,tags:[`generic`,`arrow`],fileSvg:`svg/arrowsShuffle.svg`},arrowsSwitch:{glyph:``,size:24,tags:[`generic`,`arrow`],fileSvg:`svg/arrowsSwitch.svg`},carClock:{glyph:``,size:24,tags:[`generic`,`vehicle`],fileSvg:`svg/carClock.svg`},carFast:{glyph:``,size:24,tags:[`vehicle`],fileSvg:`svg/carFast.svg`},carNumber1:{glyph:``,size:24,tags:[`generic`,`vehicle`],fileSvg:`svg/carNumber1.svg`},carNumber2:{glyph:``,size:24,tags:[`generic`,`vehicle`],fileSvg:`svg/carNumber2.svg`},carNumber3:{glyph:``,size:24,tags:[`generic`,`vehicle`],fileSvg:`svg/carNumber3.svg`},carNumber4:{glyph:``,size:24,tags:[`generic`,`vehicle`],fileSvg:`svg/carNumber4.svg`},carNumber5:{glyph:``,size:24,tags:[`generic`,`vehicle`],fileSvg:`svg/carNumber5.svg`},carNumber6:{glyph:``,size:24,tags:[`generic`,`vehicle`],fileSvg:`svg/carNumber6.svg`},carNumber7:{glyph:``,size:24,tags:[`generic`,`vehicle`],fileSvg:`svg/carNumber7.svg`},carNumber8:{glyph:``,size:24,tags:[`generic`,`vehicle`],fileSvg:`svg/carNumber8.svg`},carNumber9:{glyph:``,size:24,tags:[`generic`,`vehicle`],fileSvg:`svg/carNumber9.svg`},carPlus:{glyph:``,size:24,tags:[`generic`,`vehicle`],fileSvg:`svg/carPlus.svg`},carsChange:{glyph:``,size:24,tags:[`vehicle`,`select`],fileSvg:`svg/carsChange.svg`},carsFollow:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/carsFollow.svg`},doorFrontDetached:{glyph:``,size:24,tags:[`vehicle`,`part`,`features`],fileSvg:`svg/doorFrontDetached.svg`},forceFieldPull1:{glyph:``,size:24,tags:[`physics`,`field`,`force`],fileSvg:`svg/forceFieldPull1.svg`},forceFieldPull2:{glyph:``,size:24,tags:[`physics`,`field`,`force`],fileSvg:`svg/forceFieldPull2.svg`},forceFieldPull3:{glyph:``,size:24,tags:[`physics`,`field`,`force`],fileSvg:`svg/forceFieldPull3.svg`},forceFieldPush1:{glyph:``,size:24,tags:[`physics`,`field`,`force`],fileSvg:`svg/forceFieldPush1.svg`},forceFieldPush2:{glyph:``,size:24,tags:[`physics`,`field`,`force`],fileSvg:`svg/forceFieldPush2.svg`},forceFieldPush3:{glyph:``,size:24,tags:[`physics`,`field`,`force`],fileSvg:`svg/forceFieldPush3.svg`},garageNumber1:{glyph:``,size:24,tags:[`career`,`garage number`,`features`],fileSvg:`svg/garageNumber1.svg`},garageNumber2:{glyph:``,size:24,tags:[`career`,`garage number`,`features`],fileSvg:`svg/garageNumber2.svg`},garageNumber3:{glyph:``,size:24,tags:[`career`,`garage number`,`features`],fileSvg:`svg/garageNumber3.svg`},garageNumber4:{glyph:``,size:24,tags:[`career`,`garage number`,`features`],fileSvg:`svg/garageNumber4.svg`},garageNumber5:{glyph:``,size:24,tags:[`career`,`garage number`,`features`],fileSvg:`svg/garageNumber5.svg`},garageNumber6:{glyph:``,size:24,tags:[`career`,`garage number`,`features`],fileSvg:`svg/garageNumber6.svg`},garageNumber7:{glyph:``,size:24,tags:[`career`,`garage number`,`features`],fileSvg:`svg/garageNumber7.svg`},garageNumber8:{glyph:``,size:24,tags:[`career`,`garage number`,`features`],fileSvg:`svg/garageNumber8.svg`},garageNumber9:{glyph:``,size:24,tags:[`career`,`garage number`,`features`],fileSvg:`svg/garageNumber9.svg`},hingeBroken:{glyph:``,size:24,tags:[`vehicle`,`part`,`features`],fileSvg:`svg/hingeBroken.svg`},loadMesh:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/loadMesh.svg`},octagonBrick:{glyph:``,size:24,tags:[`generic`,`vehicle`,`car`],fileSvg:`svg/octagonBrick.svg`},octagon:{glyph:``,size:24,tags:[`generic`,`vehicle`,`car`],fileSvg:`svg/octagon.svg`},pushUp:{glyph:``,size:24,tags:[`physics`,`force`],fileSvg:`svg/pushUp.svg`},saveMesh:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/saveMesh.svg`},square:{glyph:``,size:24,tags:[`playback`,`stop`],fileSvg:`svg/square.svg`},tireAirPuff:{glyph:``,size:24,tags:[`vehicle`,`car`],fileSvg:`svg/tireAirPuff.svg`},tireDeflated:{glyph:``,size:24,tags:[`vehicle`,`car`],fileSvg:`svg/tireDeflated.svg`},trafficLight:{glyph:``,size:24,tags:[`generic`,`traffic`,`roads`],fileSvg:`svg/trafficLight.svg`},enter:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/enter.svg`},pedestrianRunning:{glyph:``,size:24,tags:[`generic`,`sign`,`pedestrian`,`traffic`],fileSvg:`svg/pedestrianRunning.svg`},pedestrianStanding:{glyph:``,size:24,tags:[`generic`,`sign`,`pedestrian`,`traffic`],fileSvg:`svg/pedestrianStanding.svg`},seatArrowIn:{glyph:``,size:24,tags:[`generic`,`arrow`,`actions`],fileSvg:`svg/seatArrowIn.svg`},seatArrowOut:{glyph:``,size:24,tags:[`generic`,`arrow`,`actions`],fileSvg:`svg/seatArrowOut.svg`},seatVArrowIn:{glyph:``,size:24,tags:[`generic`,`arrow`,`actions`],fileSvg:`svg/seatVArrowIn.svg`},seatVArrowOut:{glyph:``,size:24,tags:[`generic`,`arrow`,`actions`],fileSvg:`svg/seatVArrowOut.svg`},vehicleArrowIn:{glyph:``,size:24,tags:[`generic`,`arrow`,`actions`],fileSvg:`svg/vehicleArrowIn.svg`},vehicleArrowOut:{glyph:``,size:24,tags:[`generic`,`arrow`,`actions`],fileSvg:`svg/vehicleArrowOut.svg`},leverFrontOperate:{glyph:``,size:24,tags:[`generic`,`actions`],fileSvg:`svg/leverFrontOperate.svg`},leverSideDown:{glyph:``,size:24,tags:[`generic`,`actions`],fileSvg:`svg/leverSideDown.svg`},leverSideOperate:{glyph:``,size:24,tags:[`generic`,`actions`],fileSvg:`svg/leverSideOperate.svg`},leverSideUp:{glyph:``,size:24,tags:[`generic`,`actions`],fileSvg:`svg/leverSideUp.svg`},medalEmpty:{glyph:``,size:24,tags:[`generic`,`reward`,`achievment`],fileSvg:`svg/medalEmpty.svg`},medalStar:{glyph:``,size:24,tags:[`generic`,`reward`,`achievment`],fileSvg:`svg/medalStar.svg`},seatArrowInLeft:{glyph:``,size:24,tags:[`generic`,`arrow`,`actions`],fileSvg:`svg/seatArrowInLeft.svg`},seatArrowOutLeft:{glyph:``,size:24,tags:[`generic`,`arrow`,`actions`],fileSvg:`svg/seatArrowOutLeft.svg`},seatVArrowInLeft:{glyph:``,size:24,tags:[`generic`,`arrow`,`actions`],fileSvg:`svg/seatVArrowInLeft.svg`},seatVArrowOutLeft:{glyph:``,size:24,tags:[`generic`,`arrow`,`actions`],fileSvg:`svg/seatVArrowOutLeft.svg`},badgeRoundEmpty:{glyph:``,size:24,tags:[`generic`,`reward`,`achievment`],fileSvg:`svg/badgeRoundEmpty.svg`},badgeRoundStar:{glyph:``,size:24,tags:[`generic`,`reward`,`achievment`],fileSvg:`svg/badgeRoundStar.svg`},badgeRound:{glyph:``,size:24,tags:[`generic`,`reward`,`achievment`],fileSvg:`svg/badgeRound.svg`},badge:{glyph:``,size:24,tags:[`generic`,`reward`,`achievment`],fileSvg:`svg/badge.svg`},beamCurrencyOutlineLarge:{glyph:``,size:48,tags:[`outline`,`generic`,`currency`],fileSvg:`svg/beamCurrencyOutlineLarge.svg`},carSideOutlineLarge:{glyph:``,size:48,tags:[`generic`,`vehicle`],fileSvg:`svg/carSideOutlineLarge.svg`},flagOutlineLarge:{glyph:``,size:48,tags:[`generic`,`mission`,`scenario`],fileSvg:`svg/flagOutlineLarge.svg`},terrainOutlineLarge:{glyph:``,size:48,tags:[`generic`],fileSvg:`svg/terrainOutlineLarge.svg`},houseWrenchRoof:{glyph:``,size:24,tags:[`career`,`garage`,`features`,`house`],fileSvg:`svg/houseWrenchRoof.svg`},houseWrench:{glyph:``,size:24,tags:[`career`,`garage`,`features`,`house`],fileSvg:`svg/houseWrench.svg`},eject:{glyph:``,size:24,tags:[`playback`],fileSvg:`svg/eject.svg`},rallyHelmet3To4:{glyph:``,size:24,tags:[`helmet`,`rally`,`generic`,`racing`,`game mode`],fileSvg:`svg/rallyHelmet3To4.svg`},rallyHelmet:{glyph:``,size:24,tags:[`helmet`,`rally`,`generic`,`racing`,`game mode`],fileSvg:`svg/rallyHelmet.svg`},test:{glyph:``,size:24,tags:[`generic`,`hazard`],fileSvg:`svg/test.svg`},tripleCaution:{glyph:``,size:48,tags:[`rally`,`pace notes`,`directions`,`surface`,`features`],fileSvg:`svg/tripleCaution.svg`},globeSimpleNotSign:{glyph:``,size:24,tags:[`generic`,`offline`],fileSvg:`svg/globeSimpleNotSign.svg`},globeSimplified:{glyph:``,size:24,tags:[`generic`,`online`],fileSvg:`svg/globeSimplified.svg`},radialMenu:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/radialMenu.svg`},branch:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/branch.svg`},NA:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/NA.svg`},psCircleOutline:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/psCircleOutline.svg`},psCircle:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/psCircle.svg`},psCreate2:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/psCreate2.svg`},psCreate:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/psCreate.svg`},psCrossOutline:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/psCrossOutline.svg`},psCross:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/psCross.svg`},psDDefaultOutline:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/psDDefaultOutline.svg`},psDDefaultSolid:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/psDDefaultSolid.svg`},psDDown:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/psDDown.svg`},psDLeft:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/psDLeft.svg`},psDRight:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/psDRight.svg`},psDUp:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/psDUp.svg`},psL1:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/psL1.svg`},psL2:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/psL2.svg`},psL3ButtonArrowDown:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/psL3ButtonArrowDown.svg`},psL3Button:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/psL3Button.svg`},psLSXLeft:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/psLSXLeft.svg`},psLSXRight:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/psLSXRight.svg`},psLSX:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/psLSX.svg`},psLSYDown:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/psLSYDown.svg`},psLSYUp:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/psLSYUp.svg`},psLSY:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/psLSY.svg`},psLS:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/psLS.svg`},psMenu2:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/psMenu2.svg`},psMenu:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/psMenu.svg`},psR1:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/psR1.svg`},psR2:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/psR2.svg`},psR3ButtonArrowDown:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/psR3ButtonArrowDown.svg`},psR3Button:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/psR3Button.svg`},psRSXLeft:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/psRSXLeft.svg`},psRSXRight:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/psRSXRight.svg`},psRSX:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/psRSX.svg`},psRSYDown:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/psRSYDown.svg`},psRSYUp:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/psRSYUp.svg`},psRSY:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/psRSY.svg`},psRS:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/psRS.svg`},psSquareOutline:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/psSquareOutline.svg`},psSquare:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/psSquare.svg`},psTrackpadNavigate:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/psTrackpadNavigate.svg`},psTrackpadPressCenter:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/psTrackpadPressCenter.svg`},psTrackpadPressLeft:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/psTrackpadPressLeft.svg`},psTrackpadPressRight:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/psTrackpadPressRight.svg`},psTrackpadSwipeDown:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/psTrackpadSwipeDown.svg`},psTrackpadSwipeLeft:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/psTrackpadSwipeLeft.svg`},psTrackpadSwipeRight:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/psTrackpadSwipeRight.svg`},psTrackpadSwipeUp:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/psTrackpadSwipeUp.svg`},psTriangleOutline:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/psTriangleOutline.svg`},psTriangle:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/psTriangle.svg`},xboxAOutline:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/xboxAOutline.svg`},xboxBOutline:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/xboxBOutline.svg`},xboxLSButtonArrowDown:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/xboxLSButtonArrowDown.svg`},xboxRSButtonArrowDown:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/xboxRSButtonArrowDown.svg`},xboxXAxisLeft:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/xboxXAxisLeft.svg`},xboxXAxisRight:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/xboxXAxisRight.svg`},xboxXOutline:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/xboxXOutline.svg`},xboxXRotLeft:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/xboxXRotLeft.svg`},xboxXRotRight:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/xboxXRotRight.svg`},xboxYAxisDown:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/xboxYAxisDown.svg`},xboxYAxisUp:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/xboxYAxisUp.svg`},xboxYOutline:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/xboxYOutline.svg`},xboxYRotDown:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/xboxYRotDown.svg`},xboxYRotUp:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/xboxYRotUp.svg`},cableSection:{glyph:``,size:24,tags:[`material`,`beam`,`strap`],fileSvg:`svg/cableSection.svg`},strapHook:{glyph:``,size:24,tags:[`material`,`strap`],fileSvg:`svg/strapHook.svg`},strapRatchet:{glyph:``,size:24,tags:[`material`,`strap`],fileSvg:`svg/strapRatchet.svg`},carFastReverse:{glyph:``,size:24,tags:[`vehicle`],fileSvg:`svg/carFastReverse.svg`},carsChase:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/carsChase.svg`},carsFlee:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/carsFlee.svg`},gaugeFull:{glyph:``,size:24,tags:[`poi`],fileSvg:`svg/gaugeFull.svg`},hammerParticles:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/hammerParticles.svg`},kbArrowsDown:{glyph:``,size:24,tags:[`keyboard`,`controls`],fileSvg:`svg/kbArrowsDown.svg`},kbArrowsLeftRight:{glyph:``,size:24,tags:[`keyboard`,`controls`],fileSvg:`svg/kbArrowsLeftRight.svg`},kbArrowsLeft:{glyph:``,size:24,tags:[`keyboard`,`controls`],fileSvg:`svg/kbArrowsLeft.svg`},kbArrowsOutline:{glyph:``,size:24,tags:[`keyboard`,`controls`],fileSvg:`svg/kbArrowsOutline.svg`},kbArrowsRight:{glyph:``,size:24,tags:[`keyboard`,`controls`],fileSvg:`svg/kbArrowsRight.svg`},kbArrowsSolid:{glyph:``,size:24,tags:[`keyboard`,`controls`],fileSvg:`svg/kbArrowsSolid.svg`},kbArrowsUpDown:{glyph:``,size:24,tags:[`keyboard`,`controls`],fileSvg:`svg/kbArrowsUpDown.svg`},kbArrowsUp:{glyph:``,size:24,tags:[`keyboard`,`controls`],fileSvg:`svg/kbArrowsUp.svg`},magicWand:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/magicWand.svg`},psDLeftRight:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/psDLeftRight.svg`},psDUpDown:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/psDUpDown.svg`},pushBackward:{glyph:``,size:24,tags:[`physics`,`force`],fileSvg:`svg/pushBackward.svg`},pushDown:{glyph:``,size:24,tags:[`physics`,`force`],fileSvg:`svg/pushDown.svg`},pushForward:{glyph:``,size:24,tags:[`physics`,`force`],fileSvg:`svg/pushForward.svg`},rangeboxHi:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/rangeboxHi.svg`},rangeboxLo:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/rangeboxLo.svg`},routeSimpleFlag:{glyph:``,size:24,tags:[`route`,`traffic`],fileSvg:`svg/routeSimpleFlag.svg`},xboxDLeftRight:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/xboxDLeftRight.svg`},xboxDUpDown:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/xboxDUpDown.svg`},carsWrench:{glyph:``,size:24,tags:[`vehicle`,`select`],fileSvg:`svg/carsWrench.svg`},jointCycleMultiple:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/jointCycleMultiple.svg`},jointCycle:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/jointCycle.svg`},dice24:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/dice24.svg`},diceD6:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/diceD6.svg`},pathDice:{glyph:``,size:24,tags:[`camera`],fileSvg:`svg/pathDice.svg`},sunDown:{glyph:``,size:24,tags:[`environment`],fileSvg:`svg/sunDown.svg`},xmarkBold:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/xmarkBold.svg`},intakeTrumpets:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/intakeTrumpets.svg`},transmissionCvt:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/transmissionCvt.svg`},house:{glyph:``,size:24,tags:[`career`,`generic`,`garage`,`features`,`house`],fileSvg:`svg/house.svg`},playPause:{glyph:``,size:24,tags:[`playback`],fileSvg:`svg/playPause.svg`},picture:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/picture.svg`},auxUpDown:{glyph:``,size:24,tags:[`vehicle`,`features`,`equipment`],fileSvg:`svg/auxUpDown.svg`},bucketArmUpDown:{glyph:``,size:24,tags:[`vehicle`,`features`,`equipment`],fileSvg:`svg/bucketArmUpDown.svg`},bucketTilt:{glyph:``,size:24,tags:[`vehicle`,`features`,`equipment`],fileSvg:`svg/bucketTilt.svg`},bucketArmDown:{glyph:``,size:24,tags:[`vehicle`,`features`,`equipment`],fileSvg:`svg/bucketArmDown.svg`},bucketArmLevel:{glyph:``,size:24,tags:[`vehicle`,`features`,`equipment`],fileSvg:`svg/bucketArmLevel.svg`},bucketArmUp:{glyph:``,size:24,tags:[`vehicle`,`features`,`equipment`],fileSvg:`svg/bucketArmUp.svg`},bucketTiltDown:{glyph:``,size:24,tags:[`vehicle`,`features`,`equipment`],fileSvg:`svg/bucketTiltDown.svg`},bucketTiltLevel:{glyph:``,size:24,tags:[`vehicle`,`features`,`equipment`],fileSvg:`svg/bucketTiltLevel.svg`},bucketTiltUp:{glyph:``,size:24,tags:[`vehicle`,`features`,`equipment`],fileSvg:`svg/bucketTiltUp.svg`},dumpBedDown:{glyph:``,size:24,tags:[`vehicle`,`features`,`equipment`],fileSvg:`svg/dumpBedDown.svg`},dumpBedUpDown:{glyph:``,size:24,tags:[`vehicle`,`features`,`equipment`],fileSvg:`svg/dumpBedUpDown.svg`},dumpBedUp:{glyph:``,size:24,tags:[`vehicle`,`features`,`equipment`],fileSvg:`svg/dumpBedUp.svg`},beamCurrencyThin:{glyph:``,size:24,tags:[`career`,`currencies`],fileSvg:`svg/beamCurrencyThin.svg`},shieldCheckmarkProgressbar:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/shieldCheckmarkProgressbar.svg`}}),iconsBySize=Object.freeze({16:{arrowsUp:icons$2.arrowsUp,bigDot:icons$2.bigDot,connectorBold:icons$2.connectorBold,cornerTopRight:icons$2.cornerTopRight,plusBold:icons$2.plusBold,puzzlePieceBold:icons$2.puzzlePieceBold},24:{"4WD":icons$2[`4WD`],"9dividedby10":icons$2[`9dividedby10`],abandon:icons$2.abandon,ABSIndicator:icons$2.ABSIndicator,addItemPolygon:icons$2.addItemPolygon,addListItem:icons$2.addListItem,addPolygonVertex:icons$2.addPolygonVertex,adjust:icons$2.adjust,AIMicrochip:icons$2.AIMicrochip,AIRace:icons$2.AIRace,aperture:icons$2.aperture,arrowLargeDown:icons$2.arrowLargeDown,arrowLargeLeft:icons$2.arrowLargeLeft,arrowLargeRight:icons$2.arrowLargeRight,arrowLargeUp:icons$2.arrowLargeUp,arrowSmallDown:icons$2.arrowSmallDown,arrowSmallLeft:icons$2.arrowSmallLeft,arrowSmallRight:icons$2.arrowSmallRight,arrowSmallUp:icons$2.arrowSmallUp,arrowSolidLeft:icons$2.arrowSolidLeft,arrowSolidRight:icons$2.arrowSolidRight,autobahn:icons$2.autobahn,AWD:icons$2.AWD,axleLift:icons$2.axleLift,axleCenter:icons$2.axleCenter,axleFront:icons$2.axleFront,axleRear:icons$2.axleRear,bSpline:icons$2.bSpline,banknotes:icons$2.banknotes,barrelKnocker01:icons$2.barrelKnocker01,barrelKnocker02:icons$2.barrelKnocker02,beamCrashBarrier1:icons$2.beamCrashBarrier1,beamCrashBarrier2:icons$2.beamCrashBarrier2,beamCrashBarrier3:icons$2.beamCrashBarrier3,beamCurrency:icons$2.beamCurrency,beamNG:icons$2.beamNG,beamXPFull:icons$2.beamXPFull,beamXPLo:icons$2.beamXPLo,bezierPath1:icons$2.bezierPath1,bezierPath2:icons$2.bezierPath2,bicycle1:icons$2.bicycle1,bicycle2:icons$2.bicycle2,BNGFolder:icons$2.BNGFolder,BNGMicrochip:icons$2.BNGMicrochip,bollard:icons$2.bollard,bookmark:icons$2.bookmark,booleanIntersect:icons$2.booleanIntersect,boxDropOff01:icons$2.boxDropOff01,boxDropOff02:icons$2.boxDropOff02,boxDropOff03:icons$2.boxDropOff03,boxPickUp01:icons$2.boxPickUp01,boxPickUp02:icons$2.boxPickUp02,boxPickUp03:icons$2.boxPickUp03,boxPickUpDropOff01:icons$2.boxPickUpDropOff01,boxPickUpDropOff02:icons$2.boxPickUpDropOff02,boxTruck:icons$2.boxTruck,broom:icons$2.broom,bucketAdd:icons$2.bucketAdd,bucketSubtract:icons$2.bucketSubtract,bug:icons$2.bug,bulldozer:icons$2.bulldozer,bus:icons$2.bus,camera3Fourth1:icons$2.camera3Fourth1,cameraBack1:icons$2.cameraBack1,cameraFocusOnPath:icons$2.cameraFocusOnPath,cameraFocusOnVehicle1:icons$2.cameraFocusOnVehicle1,cameraFocusOnVehicle2:icons$2.cameraFocusOnVehicle2,cameraFocusTopDown:icons$2.cameraFocusTopDown,cameraFront1:icons$2.cameraFront1,cameraSideLeft:icons$2.cameraSideLeft,cameraSideLeft2:icons$2.cameraSideLeft2,cameraSideRight:icons$2.cameraSideRight,cameraSideRight2:icons$2.cameraSideRight2,cameraTop1:icons$2.cameraTop1,cannon:icons$2.cannon,carChase01:icons$2.carChase01,carCoin:icons$2.carCoin,carCoins:icons$2.carCoins,carCrash:icons$2.carCrash,carDealer:icons$2.carDealer,carOffroadOutlineRear:icons$2.carOffroadOutlineRear,carOffroadOutlineSide:icons$2.carOffroadOutlineSide,carOffroadRear:icons$2.carOffroadRear,carOffroadSide:icons$2.carOffroadSide,carSensors:icons$2.carSensors,carStarred:icons$2.carStarred,carToWheels:icons$2.carToWheels,carUp:icons$2.carUp,carWithLidar:icons$2.carWithLidar,car:icons$2.car,cardboardBox:icons$2.cardboardBox,carsChase02:icons$2.carsChase02,cars:icons$2.cars,catalog01:icons$2.catalog01,catalog02:icons$2.catalog02,catalog03:icons$2.catalog03,centrifugalClutchLocked03:icons$2.centrifugalClutchLocked03,centrifugalClutchUnlocked03:icons$2.centrifugalClutchUnlocked03,charge:icons$2.charge,charging:icons$2.charging,chartBars:icons$2.chartBars,checkboxOff:icons$2.checkboxOff,checkboxOn:icons$2.checkboxOn,checkmarkBold:icons$2.checkmarkBold,checkmark:icons$2.checkmark,circuitMicrochip:icons$2.circuitMicrochip,circuit:icons$2.circuit,clapperboard:icons$2.clapperboard,code:icons$2.code,cogDamaged:icons$2.cogDamaged,cogsDamaged:icons$2.cogsDamaged,cogs:icons$2.cogs,concreteRoadBlock:icons$2.concreteRoadBlock,coolantTemp:icons$2.coolantTemp,copy:icons$2.copy,crossroads1:icons$2.crossroads1,crossroads2:icons$2.crossroads2,cruiseDisable:icons$2.cruiseDisable,cruiseEnable:icons$2.cruiseEnable,cup:icons$2.cup,dataExchange:icons$2.dataExchange,day:icons$2.day,DCBattery:icons$2.DCBattery,decalRoad:icons$2.decalRoad,decal:icons$2.decal,deform:icons$2.deform,deliveryTruckArrows:icons$2.deliveryTruckArrows,deliveryTruck:icons$2.deliveryTruck,differentialFrontDefault:icons$2.differentialFrontDefault,differentialFrontLocked:icons$2.differentialFrontLocked,differentialMiddleDefault:icons$2.differentialMiddleDefault,differentialMiddleLocked:icons$2.differentialMiddleLocked,differentialRearDefault:icons$2.differentialRearDefault,differentialRearLocked:icons$2.differentialRearLocked,doorHandle:icons$2.doorHandle,doorIn:icons$2.doorIn,drag01:icons$2.drag01,drag02:icons$2.drag02,drift01:icons$2.drift01,drift02:icons$2.drift02,drivetrainGeneric:icons$2.drivetrainGeneric,drivetrainSpecial:icons$2.drivetrainSpecial,editCheckmark:icons$2.editCheckmark,edit:icons$2.edit,engine:icons$2.engine,ESCOff:icons$2.ESCOff,ESCOn:icons$2.ESCOn,ESC:icons$2.ESC,evade:icons$2.evade,exhaustValve:icons$2.exhaustValve,exit:icons$2.exit,export:icons$2.export,eyeOutlineClosed:icons$2.eyeOutlineClosed,eyeOutlineOpened:icons$2.eyeOutlineOpened,eyeSolidClosed:icons$2.eyeSolidClosed,eyeSolidOpened:icons$2.eyeSolidOpened,eyeWaves:icons$2.eyeWaves,facility02:icons$2.facility02,fastBackward:icons$2.fastBackward,fastForward:icons$2.fastForward,fastTravel:icons$2.fastTravel,filter:icons$2.filter,flagNew:icons$2.flagNew,flag:icons$2.flag,flatBulbBeam:icons$2.flatBulbBeam,flatbedTruck:icons$2.flatbedTruck,floppyDisk:icons$2.floppyDisk,fogLight:icons$2.fogLight,folder:icons$2.folder,forklift:icons$2.forklift,FPS:icons$2.FPS,fragile:icons$2.fragile,frontAxleMidpoint:icons$2.frontAxleMidpoint,frontBumperMidpoint:icons$2.frontBumperMidpoint,fuelPumpFilling:icons$2.fuelPumpFilling,fuelPump:icons$2.fuelPump,FWD:icons$2.FWD,gamepadOld:icons$2.gamepadOld,gamepad:icons$2.gamepad,garage01:icons$2.garage01,garage02:icons$2.garage02,garage03:icons$2.garage03,gaugeEmpty:icons$2.gaugeEmpty,globe:icons$2.globe,GPSMark:icons$2.GPSMark,GPSSolid:icons$2.GPSSolid,group:icons$2.group,gyroscopeMicrochip:icons$2.gyroscopeMicrochip,gyroscope:icons$2.gyroscope,hazardLights:icons$2.hazardLights,helmets:icons$2.helmets,help:icons$2.help,highBeam:icons$2.highBeam,HUD:icons$2.HUD,hydroPump1:icons$2.hydroPump1,hydroPump2:icons$2.hydroPump2,hydroPump3:icons$2.hydroPump3,hydroPump4:icons$2.hydroPump4,hydroPump5:icons$2.hydroPump5,hydroPump6:icons$2.hydroPump6,hydroPump7:icons$2.hydroPump7,hypermiling:icons$2.hypermiling,import:icons$2.import,infinity:icons$2.infinity,info:icons$2.info,jointLocked:icons$2.jointLocked,jointUnlocked:icons$2.jointUnlocked,jump:icons$2.jump,keyboard:icons$2.keyboard,keys1:icons$2.keys1,keys2:icons$2.keys2,lampPost1:icons$2.lampPost1,lampPost2:icons$2.lampPost2,lampPost3:icons$2.lampPost3,laneProperties:icons$2.laneProperties,language:icons$2.language,laptop:icons$2.laptop,lidarPatternFullArcHighFreq:icons$2.lidarPatternFullArcHighFreq,lidarPatternFullArcMidFreq:icons$2.lidarPatternFullArcMidFreq,lidarPatternNarrowArc:icons$2.lidarPatternNarrowArc,lidar:icons$2.lidar,lightGarageG11:icons$2.lightGarageG11,lightGarageG12:icons$2.lightGarageG12,lightGarageG13:icons$2.lightGarageG13,lightGarageG14:icons$2.lightGarageG14,lightGarageG21:icons$2.lightGarageG21,lightGarageG22:icons$2.lightGarageG22,lightGarageG23:icons$2.lightGarageG23,lightGarageG24:icons$2.lightGarageG24,lightGarageG31:icons$2.lightGarageG31,lightGarageG32:icons$2.lightGarageG32,lightGarageG33:icons$2.lightGarageG33,lightGarageG34:icons$2.lightGarageG34,lightrunner:icons$2.lightrunner,limiterEnable:icons$2.limiterEnable,lineToTerrain:icons$2.lineToTerrain,link2:icons$2.link2,link:icons$2.link,listBig:icons$2.listBig,listIndented:icons$2.listIndented,listSmall:icons$2.listSmall,location1:icons$2.location1,location2:icons$2.location2,lockClosed:icons$2.lockClosed,lockOpened:icons$2.lockOpened,longRangeBeam1:icons$2.longRangeBeam1,longRangeBeam2:icons$2.longRangeBeam2,lowBeam:icons$2.lowBeam,magnetOnSurface:icons$2.magnetOnSurface,mapWithEmitter:icons$2.mapWithEmitter,mapPoint:icons$2.mapPoint,material:icons$2.material,mathDivide:icons$2.mathDivide,mathGreaterOrEqualThan:icons$2.mathGreaterOrEqualThan,mathGreaterThan:icons$2.mathGreaterThan,mathLessOrEqualThan:icons$2.mathLessOrEqualThan,mathLessThan:icons$2.mathLessThan,mathMinus:icons$2.mathMinus,mathMultiply:icons$2.mathMultiply,mathPlus:icons$2.mathPlus,medal:icons$2.medal,mesh4Cells:icons$2.mesh4Cells,mesh9Cells:icons$2.mesh9Cells,meshFence:icons$2.meshFence,meshRoad:icons$2.meshRoad,midRangeBeam1:icons$2.midRangeBeam1,midRangeBeam2:icons$2.midRangeBeam2,minusRes:icons$2.minusRes,minus:icons$2.minus,mirrorInteriorMiddle:icons$2.mirrorInteriorMiddle,mirrorLeftBigBottomWideAngle:icons$2.mirrorLeftBigBottomWideAngle,mirrorLeftBigTop:icons$2.mirrorLeftBigTop,mirrorLeftBig:icons$2.mirrorLeftBig,mirrorLeftBonnet:icons$2.mirrorLeftBonnet,mirrorLeftDefault:icons$2.mirrorLeftDefault,mirrorRightBigBottomWideAngle:icons$2.mirrorRightBigBottomWideAngle,mirrorRightBigTop:icons$2.mirrorRightBigTop,mirrorRightBig:icons$2.mirrorRightBig,mirrorRightBonnet:icons$2.mirrorRightBonnet,mirrorRightDefault:icons$2.mirrorRightDefault,mirrorRoundWideAngle:icons$2.mirrorRoundWideAngle,mirrorTopWideAngle:icons$2.mirrorTopWideAngle,missionCheckboxCross:icons$2.missionCheckboxCross,mouseLMB:icons$2.mouseLMB,mouseMMB:icons$2.mouseMMB,mouseRMB:icons$2.mouseRMB,mouseWheel:icons$2.mouseWheel,mouseXAxis:icons$2.mouseXAxis,mouseXYAxis:icons$2.mouseXYAxis,mouseYAxis:icons$2.mouseYAxis,mouse:icons$2.mouse,move02:icons$2.move02,move:icons$2.move,movieCamera:icons$2.movieCamera,music:icons$2.music,N2OButton:icons$2.N2OButton,N2OHoriz:icons$2.N2OHoriz,N2OVert:icons$2.N2OVert,nextTrack:icons$2.nextTrack,night:icons$2.night,noNameControllerButton:icons$2.noNameControllerButton,nodeAddFirst01:icons$2.nodeAddFirst01,nodeAddFirst02:icons$2.nodeAddFirst02,nodeAddLast02:icons$2.nodeAddLast02,nodeAddMiddle01:icons$2.nodeAddMiddle01,nodeAddMiddle02:icons$2.nodeAddMiddle02,nodeAdd:icons$2.nodeAdd,nodeLast01:icons$2.nodeLast01,nodeRemove:icons$2.nodeRemove,odometerKM:icons$2.odometerKM,odometerMI:icons$2.odometerMI,odometer:icons$2.odometer,oilPressureIndicator:icons$2.oilPressureIndicator,order:icons$2.order,organization:icons$2.organization,palmCrossed:icons$2.palmCrossed,paperKnife:icons$2.paperKnife,parkingIndicator:icons$2.parkingIndicator,parking:icons$2.parking,pathArc:icons$2.pathArc,pathAroundObstacle:icons$2.pathAroundObstacle,pathLine:icons$2.pathLine,pathSpiral:icons$2.pathSpiral,pauseRound:icons$2.pauseRound,pause:icons$2.pause,personSolid:icons$2.personSolid,person:icons$2.person,photo:icons$2.photo,placeholder:icons$2.placeholder,playRound:icons$2.playRound,play:icons$2.play,playlist:icons$2.playlist,plusGarage1:icons$2.plusGarage1,plusGarage2:icons$2.plusGarage2,plusGarage3:icons$2.plusGarage3,plusGarage4:icons$2.plusGarage4,plusSet:icons$2.plusSet,plus:icons$2.plus,positionLights:icons$2.positionLights,powerGauge01:icons$2.powerGauge01,powerGauge02:icons$2.powerGauge02,powerGauge03:icons$2.powerGauge03,powerGauge04:icons$2.powerGauge04,powerGauge05:icons$2.powerGauge05,powerOnOff:icons$2.powerOnOff,prevTrack:icons$2.prevTrack,publisher:icons$2.publisher,puzzleModule:icons$2.puzzleModule,raceFlag:icons$2.raceFlag,radarIdeal:icons$2.radarIdeal,radarRoundIdeal:icons$2.radarRoundIdeal,radarRound:icons$2.radarRound,radar:icons$2.radar,rangeboxHi2:icons$2.rangeboxHi2,rangeboxHi4:icons$2.rangeboxHi4,rangeboxHiA:icons$2.rangeboxHiA,rangeboxLo2:icons$2.rangeboxLo2,rangeboxLo4:icons$2.rangeboxLo4,rangeboxLoA:icons$2.rangeboxLoA,rearAxleMidpoint:icons$2.rearAxleMidpoint,rearBumperMidpoint:icons$2.rearBumperMidpoint,reconfigure:icons$2.reconfigure,redo:icons$2.redo,reflectNot:icons$2.reflectNot,reflect:icons$2.reflect,rename:icons$2.rename,replay:icons$2.replay,restart:icons$2.restart,roadDividerLinesDecal:icons$2.roadDividerLinesDecal,roadEdgeLineDecal:icons$2.roadEdgeLineDecal,roadEndLineDecal:icons$2.roadEndLineDecal,roadFace:icons$2.roadFace,roadInfo:icons$2.roadInfo,roadMarkingOutline:icons$2.roadMarkingOutline,roadMarkingSolid:icons$2.roadMarkingSolid,roadOutline:icons$2.roadOutline,roadRefPathDecal:icons$2.roadRefPathDecal,roadRefPath:icons$2.roadRefPath,roadStartLineDecal:icons$2.roadStartLineDecal,road:icons$2.road,rockCrawling01:icons$2.rockCrawling01,rockCrawling02:icons$2.rockCrawling02,routeAdd:icons$2.routeAdd,routeComplex:icons$2.routeComplex,routeSimple:icons$2.routeSimple,runScript:icons$2.runScript,RWD:icons$2.RWD,saveAs1:icons$2.saveAs1,scan:icons$2.scan,search:icons$2.search,semiTrailer:icons$2.semiTrailer,semiTruckCabover:icons$2.semiTruckCabover,semiTruckUS:icons$2.semiTruckUS,semiTruck:icons$2.semiTruck,shortRangeBeam1:icons$2.shortRangeBeam1,shortRangeBeam2:icons$2.shortRangeBeam2,signal01a:icons$2.signal01a,signal02a:icons$2.signal02a,signal03a:icons$2.signal03a,signal04a:icons$2.signal04a,signal05a:icons$2.signal05a,slashLeft:icons$2.slashLeft,slashRight:icons$2.slashRight,smallTrailer:icons$2.smallTrailer,smartphone1:icons$2.smartphone1,smartphone2:icons$2.smartphone2,snowflake:icons$2.snowflake,soundFadeOut:icons$2.soundFadeOut,soundLimit:icons$2.soundLimit,soundLoud:icons$2.soundLoud,soundMonoL:icons$2.soundMonoL,soundMonoR:icons$2.soundMonoR,soundOff:icons$2.soundOff,soundQuiet:icons$2.soundQuiet,soundStereo:icons$2.soundStereo,soundWave01:icons$2.soundWave01,soundWave02:icons$2.soundWave02,sphereOnPathNumber:icons$2.sphereOnPathNumber,sphereOnPath:icons$2.sphereOnPath,sphericalBeam:icons$2.sphericalBeam,spoilerLift:icons$2.spoilerLift,sprayCan:icons$2.sprayCan,stack3:icons$2.stack3,star:icons$2.star,starSecondary:icons$2.starSecondary,steeringWheelCommon:icons$2.steeringWheelCommon,steeringWheelSporty:icons$2.steeringWheelSporty,stopwatchArrows01:icons$2.stopwatchArrows01,stopwatchArrows02:icons$2.stopwatchArrows02,stopwatchSectionOutlinedEnd:icons$2.stopwatchSectionOutlinedEnd,stopwatchSectionOutlinedStart:icons$2.stopwatchSectionOutlinedStart,stopwatchSectionSolidEnd:icons$2.stopwatchSectionSolidEnd,stopwatchSectionSolidStart:icons$2.stopwatchSectionSolidStart,strobeLights:icons$2.strobeLights,sunRise:icons$2.sunRise,survellianceCamera:icons$2.survellianceCamera,suspension01:icons$2.suspension01,suspension02:icons$2.suspension02,switchBlock:icons$2.switchBlock,switchOutline:icons$2.switchOutline,sync:icons$2.sync,synchro01:icons$2.synchro01,synchro02:icons$2.synchro02,tankerTrailer:icons$2.tankerTrailer,targetJump:icons$2.targetJump,taxiCar1:icons$2.taxiCar1,taxiCar3:icons$2.taxiCar3,taxiCarT:icons$2.taxiCarT,taxiCheckerLamp:icons$2.taxiCheckerLamp,terrainToLine:icons$2.terrainToLine,terrain:icons$2.terrain,thinBulbBeam:icons$2.thinBulbBeam,thinnerBulbBeam:icons$2.thinnerBulbBeam,thisSideUp:icons$2.thisSideUp,tiles:icons$2.tiles,timer:icons$2.timer,tireDirection3Fourth2:icons$2.tireDirection3Fourth2,tireDirection3Fourth3:icons$2.tireDirection3Fourth3,tireDirectionFront2:icons$2.tireDirectionFront2,tireDirectionSide2:icons$2.tireDirectionSide2,tireDirectionTop2:icons$2.tireDirectionTop2,tirePressureDecrease01:icons$2.tirePressureDecrease01,tirePressureDecrease02:icons$2.tirePressureDecrease02,tirePressureGaugeAlt01:icons$2.tirePressureGaugeAlt01,tirePressureGaugeAlt02:icons$2.tirePressureGaugeAlt02,tirePressureGaugeAlt03:icons$2.tirePressureGaugeAlt03,tirePressureGaugeOutlined01:icons$2.tirePressureGaugeOutlined01,tirePressureGaugeOutlined02:icons$2.tirePressureGaugeOutlined02,tirePressureGaugeOutlined03:icons$2.tirePressureGaugeOutlined03,tirePressureGaugeSolid01:icons$2.tirePressureGaugeSolid01,tirePressureGaugeSolid02:icons$2.tirePressureGaugeSolid02,tirePressureGaugeSolid03:icons$2.tirePressureGaugeSolid03,tirePressureIncrease01:icons$2.tirePressureIncrease01,tirePressureIncrease02:icons$2.tirePressureIncrease02,tirePressureStopLine:icons$2.tirePressureStopLine,tirePressureStopOctoLine:icons$2.tirePressureStopOctoLine,tirePressureStopOctoSolid:icons$2.tirePressureStopOctoSolid,tirePressureStopSolid:icons$2.tirePressureStopSolid,toCOMWithWheels:icons$2.toCOMWithWheels,toCOM:icons$2.toCOM,toGarage:icons$2.toGarage,touch:icons$2.touch,tow:icons$2.tow,tractionControl:icons$2.tractionControl,trafficCone:icons$2.trafficCone,transform:icons$2.transform,transmissionA:icons$2.transmissionA,transmissionM:icons$2.transmissionM,transparencyMask:icons$2.transparencyMask,trashBin1:icons$2.trashBin1,trashBin2:icons$2.trashBin2,triangleBeam:icons$2.triangleBeam,trim:icons$2.trim,tulipBeam:icons$2.tulipBeam,tunnel:icons$2.tunnel,turbine:icons$2.turbine,twoRoadsAdd:icons$2.twoRoadsAdd,twoRoadsCrossAdd:icons$2.twoRoadsCrossAdd,twoRoadsLink:icons$2.twoRoadsLink,twoUnicyclesOnly:icons$2.twoUnicyclesOnly,undo:icons$2.undo,ungroup:icons$2.ungroup,unlink:icons$2.unlink,vehicleDoorsClose:icons$2.vehicleDoorsClose,vehicleDoorsOpen:icons$2.vehicleDoorsOpen,vehicleDoors:icons$2.vehicleDoors,vehicleFeatures01:icons$2.vehicleFeatures01,vehicleFeatures02:icons$2.vehicleFeatures02,vehicleFeatures03:icons$2.vehicleFeatures03,vehicleHood:icons$2.vehicleHood,vehicleTrunk:icons$2.vehicleTrunk,view:icons$2.view,voucherDiagonal1:icons$2.voucherDiagonal1,voucherDiagonal2:icons$2.voucherDiagonal2,voucherDiagonal3:icons$2.voucherDiagonal3,voucherHorizontal1:icons$2.voucherHorizontal1,voucherHorizontal2:icons$2.voucherHorizontal2,voucherHorizontal3:icons$2.voucherHorizontal3,wavesSignalReceived:icons$2.wavesSignalReceived,wavesSignalSentLeft:icons$2.wavesSignalSentLeft,wavesSignalSentRight:icons$2.wavesSignalSentRight,weather:icons$2.weather,weight:icons$2.weight,wheelHubLocked01:icons$2.wheelHubLocked01,wheelHubUnlocked01:icons$2.wheelHubUnlocked01,wigwags:icons$2.wigwags,wrench:icons$2.wrench,xboxA:icons$2.xboxA,xboxB:icons$2.xboxB,xboxDDefaultOutline:icons$2.xboxDDefaultOutline,xboxDDefaultSolid:icons$2.xboxDDefaultSolid,xboxDDown:icons$2.xboxDDown,xboxDLeft:icons$2.xboxDLeft,xboxDRight:icons$2.xboxDRight,xboxDUp:icons$2.xboxDUp,xboxLB:icons$2.xboxLB,xboxLSButton:icons$2.xboxLSButton,xboxLT:icons$2.xboxLT,xboxMenu:icons$2.xboxMenu,xboxRB:icons$2.xboxRB,xboxRSButton:icons$2.xboxRSButton,xboxRT:icons$2.xboxRT,xboxThumbL:icons$2.xboxThumbL,xboxThumbR:icons$2.xboxThumbR,xboxView:icons$2.xboxView,xboxXAxis:icons$2.xboxXAxis,xboxXRot:icons$2.xboxXRot,xboxX:icons$2.xboxX,xboxYAxis:icons$2.xboxYAxis,xboxYRot:icons$2.xboxYRot,xboxY:icons$2.xboxY,danger:icons$2.danger,droplet:icons$2.droplet,envelope:icons$2.envelope,fireDiamond:icons$2.fireDiamond,rocks:icons$2.rocks,xmark:icons$2.xmark,scale:icons$2.scale,locationDestination:icons$2.locationDestination,locationSource:icons$2.locationSource,accelerationKPH:icons$2.accelerationKPH,accelerationMPH:icons$2.accelerationMPH,boxTruckFast:icons$2.boxTruckFast,colorBrightnessSun:icons$2.colorBrightnessSun,colorCirclePalette:icons$2.colorCirclePalette,colorPalette:icons$2.colorPalette,colorSaturation:icons$2.colorSaturation,sortAscDown02:icons$2.sortAscDown02,sortAscDown:icons$2.sortAscDown,sortAscUp02:icons$2.sortAscUp02,sortAscUp:icons$2.sortAscUp,sortDescDown02:icons$2.sortDescDown02,sortDescDown:icons$2.sortDescDown,sortDescUp02:icons$2.sortDescUp02,sortDescUp:icons$2.sortDescUp,cardboardBoxCoins:icons$2.cardboardBoxCoins,lasso:icons$2.lasso,materialGlossy:icons$2.materialGlossy,materialMetal:icons$2.materialMetal,materialRoughness:icons$2.materialRoughness,materialTransparency01:icons$2.materialTransparency01,materialTransparency02:icons$2.materialTransparency02,metal01:icons$2.metal01,removeItemPolygon:icons$2.removeItemPolygon,removeListItem:icons$2.removeListItem,sortAsc:icons$2.sortAsc,sortDesc:icons$2.sortDesc,surfaceRoughness02:icons$2.surfaceRoughness02,shieldCheckmark:icons$2.shieldCheckmark,shieldHandCheckmark:icons$2.shieldHandCheckmark,shieldHandPlus:icons$2.shieldHandPlus,doorFrontCoins:icons$2.doorFrontCoins,doorFront:icons$2.doorFront,engineCoins:icons$2.engineCoins,exhaustMufflerCoins:icons$2.exhaustMufflerCoins,exhaustMuffler:icons$2.exhaustMuffler,headlightCoins:icons$2.headlightCoins,headlight:icons$2.headlight,tire3FourthCoins:icons$2.tire3FourthCoins,tire3Fourth:icons$2.tire3Fourth,turbineCoins:icons$2.turbineCoins,wheelDiscCoins:icons$2.wheelDiscCoins,wheelDisc:icons$2.wheelDisc,bridgeWithRiver:icons$2.bridgeWithRiver,gizmosOutline:icons$2.gizmosOutline,gizmosSolid:icons$2.gizmosSolid,highwayRoad3To2Merge01:icons$2.highwayRoad3To2Merge01,highwayRoad3To2Merge02:icons$2.highwayRoad3To2Merge02,highwayToUrbanRoadTransition01:icons$2.highwayToUrbanRoadTransition01,highwayToUrbanRoadTransition02:icons$2.highwayToUrbanRoadTransition02,pedestrianCrossing01:icons$2.pedestrianCrossing01,polygonalCube:icons$2.polygonalCube,roadEditOutline:icons$2.roadEditOutline,roadEditSolid:icons$2.roadEditSolid,roadFolderPlus:icons$2.roadFolderPlus,roadFolder:icons$2.roadFolder,roadGuideArrowOutline:icons$2.roadGuideArrowOutline,roadGuideArrowSolid:icons$2.roadGuideArrowSolid,roadOutlineMesh:icons$2.roadOutlineMesh,roadPedestrianCrossing02:icons$2.roadPedestrianCrossing02,roadProfileWithCheckmark:icons$2.roadProfileWithCheckmark,roadProfile:icons$2.roadProfile,roadRoundaboutJunction:icons$2.roadRoundaboutJunction,roadSidewalkTransition:icons$2.roadSidewalkTransition,roadStackPlus:icons$2.roadStackPlus,roadStack:icons$2.roadStack,roadTJunction:icons$2.roadTJunction,roadXJunction:icons$2.roadXJunction,roadYJunction:icons$2.roadYJunction,shoppingCart:icons$2.shoppingCart,singleLineToTerrain:icons$2.singleLineToTerrain,sphereOnMesh:icons$2.sphereOnMesh,twoLinesToTerrain:icons$2.twoLinesToTerrain,urbanRoad3To2Merge01:icons$2.urbanRoad3To2Merge01,urbanRoad3To2Merge02:icons$2.urbanRoad3To2Merge02,urbanRoadToHighwayTransition01:icons$2.urbanRoadToHighwayTransition01,urbanRoadToHighwayTransition02:icons$2.urbanRoadToHighwayTransition02,floppyDiskPlus:icons$2.floppyDiskPlus,highwayMerge:icons$2.highwayMerge,highwaySeparate:icons$2.highwaySeparate,highwayShoulderMerge:icons$2.highwayShoulderMerge,terrainToSingleLine:icons$2.terrainToSingleLine,terrainToTwoLines:icons$2.terrainToTwoLines,urbanRoadMerge:icons$2.urbanRoadMerge,urbanRoadSeparate:icons$2.urbanRoadSeparate,urbanShoulderMerge:icons$2.urbanShoulderMerge,discharging:icons$2.discharging,BNGChat:icons$2.BNGChat,chatBubble:icons$2.chatBubble,busTilted:icons$2.busTilted,cameraFarClip:icons$2.cameraFarClip,cameraNearClip:icons$2.cameraNearClip,explosion:icons$2.explosion,fireExtinguisher:icons$2.fireExtinguisher,fire:icons$2.fire,jointLockedMultiple:icons$2.jointLockedMultiple,jointUnlockedMultiple:icons$2.jointUnlockedMultiple,toggleOff:icons$2.toggleOff,toggleOn:icons$2.toggleOn,viewFarClip:icons$2.viewFarClip,viewNearClip:icons$2.viewNearClip,twoArrowsHorizontal:icons$2.twoArrowsHorizontal,twoArrowsVertical:icons$2.twoArrowsVertical,circleSlashed:icons$2.circleSlashed,scissorsSlashed:icons$2.scissorsSlashed,scissors:icons$2.scissors,airPuffRight1:icons$2.airPuffRight1,airPuffUp1:icons$2.airPuffUp1,arrowsReplace:icons$2.arrowsReplace,arrowsShuffle:icons$2.arrowsShuffle,arrowsSwitch:icons$2.arrowsSwitch,carClock:icons$2.carClock,carFast:icons$2.carFast,carNumber1:icons$2.carNumber1,carNumber2:icons$2.carNumber2,carNumber3:icons$2.carNumber3,carNumber4:icons$2.carNumber4,carNumber5:icons$2.carNumber5,carNumber6:icons$2.carNumber6,carNumber7:icons$2.carNumber7,carNumber8:icons$2.carNumber8,carNumber9:icons$2.carNumber9,carPlus:icons$2.carPlus,carsChange:icons$2.carsChange,carsFollow:icons$2.carsFollow,doorFrontDetached:icons$2.doorFrontDetached,forceFieldPull1:icons$2.forceFieldPull1,forceFieldPull2:icons$2.forceFieldPull2,forceFieldPull3:icons$2.forceFieldPull3,forceFieldPush1:icons$2.forceFieldPush1,forceFieldPush2:icons$2.forceFieldPush2,forceFieldPush3:icons$2.forceFieldPush3,garageNumber1:icons$2.garageNumber1,garageNumber2:icons$2.garageNumber2,garageNumber3:icons$2.garageNumber3,garageNumber4:icons$2.garageNumber4,garageNumber5:icons$2.garageNumber5,garageNumber6:icons$2.garageNumber6,garageNumber7:icons$2.garageNumber7,garageNumber8:icons$2.garageNumber8,garageNumber9:icons$2.garageNumber9,hingeBroken:icons$2.hingeBroken,loadMesh:icons$2.loadMesh,octagonBrick:icons$2.octagonBrick,octagon:icons$2.octagon,pushUp:icons$2.pushUp,saveMesh:icons$2.saveMesh,square:icons$2.square,tireAirPuff:icons$2.tireAirPuff,tireDeflated:icons$2.tireDeflated,trafficLight:icons$2.trafficLight,enter:icons$2.enter,pedestrianRunning:icons$2.pedestrianRunning,pedestrianStanding:icons$2.pedestrianStanding,seatArrowIn:icons$2.seatArrowIn,seatArrowOut:icons$2.seatArrowOut,seatVArrowIn:icons$2.seatVArrowIn,seatVArrowOut:icons$2.seatVArrowOut,vehicleArrowIn:icons$2.vehicleArrowIn,vehicleArrowOut:icons$2.vehicleArrowOut,leverFrontOperate:icons$2.leverFrontOperate,leverSideDown:icons$2.leverSideDown,leverSideOperate:icons$2.leverSideOperate,leverSideUp:icons$2.leverSideUp,medalEmpty:icons$2.medalEmpty,medalStar:icons$2.medalStar,seatArrowInLeft:icons$2.seatArrowInLeft,seatArrowOutLeft:icons$2.seatArrowOutLeft,seatVArrowInLeft:icons$2.seatVArrowInLeft,seatVArrowOutLeft:icons$2.seatVArrowOutLeft,badgeRoundEmpty:icons$2.badgeRoundEmpty,badgeRoundStar:icons$2.badgeRoundStar,badgeRound:icons$2.badgeRound,badge:icons$2.badge,houseWrenchRoof:icons$2.houseWrenchRoof,houseWrench:icons$2.houseWrench,eject:icons$2.eject,rallyHelmet3To4:icons$2.rallyHelmet3To4,rallyHelmet:icons$2.rallyHelmet,test:icons$2.test,globeSimpleNotSign:icons$2.globeSimpleNotSign,globeSimplified:icons$2.globeSimplified,radialMenu:icons$2.radialMenu,branch:icons$2.branch,NA:icons$2.NA,psCircleOutline:icons$2.psCircleOutline,psCircle:icons$2.psCircle,psCreate2:icons$2.psCreate2,psCreate:icons$2.psCreate,psCrossOutline:icons$2.psCrossOutline,psCross:icons$2.psCross,psDDefaultOutline:icons$2.psDDefaultOutline,psDDefaultSolid:icons$2.psDDefaultSolid,psDDown:icons$2.psDDown,psDLeft:icons$2.psDLeft,psDRight:icons$2.psDRight,psDUp:icons$2.psDUp,psL1:icons$2.psL1,psL2:icons$2.psL2,psL3ButtonArrowDown:icons$2.psL3ButtonArrowDown,psL3Button:icons$2.psL3Button,psLSXLeft:icons$2.psLSXLeft,psLSXRight:icons$2.psLSXRight,psLSX:icons$2.psLSX,psLSYDown:icons$2.psLSYDown,psLSYUp:icons$2.psLSYUp,psLSY:icons$2.psLSY,psLS:icons$2.psLS,psMenu2:icons$2.psMenu2,psMenu:icons$2.psMenu,psR1:icons$2.psR1,psR2:icons$2.psR2,psR3ButtonArrowDown:icons$2.psR3ButtonArrowDown,psR3Button:icons$2.psR3Button,psRSXLeft:icons$2.psRSXLeft,psRSXRight:icons$2.psRSXRight,psRSX:icons$2.psRSX,psRSYDown:icons$2.psRSYDown,psRSYUp:icons$2.psRSYUp,psRSY:icons$2.psRSY,psRS:icons$2.psRS,psSquareOutline:icons$2.psSquareOutline,psSquare:icons$2.psSquare,psTrackpadNavigate:icons$2.psTrackpadNavigate,psTrackpadPressCenter:icons$2.psTrackpadPressCenter,psTrackpadPressLeft:icons$2.psTrackpadPressLeft,psTrackpadPressRight:icons$2.psTrackpadPressRight,psTrackpadSwipeDown:icons$2.psTrackpadSwipeDown,psTrackpadSwipeLeft:icons$2.psTrackpadSwipeLeft,psTrackpadSwipeRight:icons$2.psTrackpadSwipeRight,psTrackpadSwipeUp:icons$2.psTrackpadSwipeUp,psTriangleOutline:icons$2.psTriangleOutline,psTriangle:icons$2.psTriangle,xboxAOutline:icons$2.xboxAOutline,xboxBOutline:icons$2.xboxBOutline,xboxLSButtonArrowDown:icons$2.xboxLSButtonArrowDown,xboxRSButtonArrowDown:icons$2.xboxRSButtonArrowDown,xboxXAxisLeft:icons$2.xboxXAxisLeft,xboxXAxisRight:icons$2.xboxXAxisRight,xboxXOutline:icons$2.xboxXOutline,xboxXRotLeft:icons$2.xboxXRotLeft,xboxXRotRight:icons$2.xboxXRotRight,xboxYAxisDown:icons$2.xboxYAxisDown,xboxYAxisUp:icons$2.xboxYAxisUp,xboxYOutline:icons$2.xboxYOutline,xboxYRotDown:icons$2.xboxYRotDown,xboxYRotUp:icons$2.xboxYRotUp,cableSection:icons$2.cableSection,strapHook:icons$2.strapHook,strapRatchet:icons$2.strapRatchet,carFastReverse:icons$2.carFastReverse,carsChase:icons$2.carsChase,carsFlee:icons$2.carsFlee,gaugeFull:icons$2.gaugeFull,hammerParticles:icons$2.hammerParticles,kbArrowsDown:icons$2.kbArrowsDown,kbArrowsLeftRight:icons$2.kbArrowsLeftRight,kbArrowsLeft:icons$2.kbArrowsLeft,kbArrowsOutline:icons$2.kbArrowsOutline,kbArrowsRight:icons$2.kbArrowsRight,kbArrowsSolid:icons$2.kbArrowsSolid,kbArrowsUpDown:icons$2.kbArrowsUpDown,kbArrowsUp:icons$2.kbArrowsUp,magicWand:icons$2.magicWand,psDLeftRight:icons$2.psDLeftRight,psDUpDown:icons$2.psDUpDown,pushBackward:icons$2.pushBackward,pushDown:icons$2.pushDown,pushForward:icons$2.pushForward,rangeboxHi:icons$2.rangeboxHi,rangeboxLo:icons$2.rangeboxLo,routeSimpleFlag:icons$2.routeSimpleFlag,xboxDLeftRight:icons$2.xboxDLeftRight,xboxDUpDown:icons$2.xboxDUpDown,carsWrench:icons$2.carsWrench,jointCycleMultiple:icons$2.jointCycleMultiple,jointCycle:icons$2.jointCycle,dice24:icons$2.dice24,diceD6:icons$2.diceD6,pathDice:icons$2.pathDice,sunDown:icons$2.sunDown,xmarkBold:icons$2.xmarkBold,intakeTrumpets:icons$2.intakeTrumpets,transmissionCvt:icons$2.transmissionCvt,house:icons$2.house,playPause:icons$2.playPause,picture:icons$2.picture,auxUpDown:icons$2.auxUpDown,bucketArmUpDown:icons$2.bucketArmUpDown,bucketTilt:icons$2.bucketTilt,bucketArmDown:icons$2.bucketArmDown,bucketArmLevel:icons$2.bucketArmLevel,bucketArmUp:icons$2.bucketArmUp,bucketTiltDown:icons$2.bucketTiltDown,bucketTiltLevel:icons$2.bucketTiltLevel,bucketTiltUp:icons$2.bucketTiltUp,dumpBedDown:icons$2.dumpBedDown,dumpBedUpDown:icons$2.dumpBedUpDown,dumpBedUp:icons$2.dumpBedUp,beamCurrencyThin:icons$2.beamCurrencyThin,shieldCheckmarkProgressbar:icons$2.shieldCheckmarkProgressbar},48:{AIL:icons$2.AIL,arrowLeftOutline:icons$2.arrowLeftOutline,arrowRightOutline:icons$2.arrowRightOutline,automaticTransmissionL:icons$2.automaticTransmissionL,beamsNodesMessageOutline:icons$2.beamsNodesMessageOutline,beamsNodesOutline:icons$2.beamsNodesOutline,beamsNodesPlugOutline:icons$2.beamsNodesPlugOutline,BNGEcosystemOutline:icons$2.BNGEcosystemOutline,carFrontRouteOutline:icons$2.carFrontRouteOutline,carSensorsOutline:icons$2.carSensorsOutline,carSideRouteOutline:icons$2.carSideRouteOutline,chargeLL:icons$2.chargeLL,cityOutline:icons$2.cityOutline,clutchL:icons$2.clutchL,couplerL:icons$2.couplerL,dialogOutline:icons$2.dialogOutline,documentSmileOutline:icons$2.documentSmileOutline,drivetrainOutline:icons$2.drivetrainOutline,electronicSchemeOutline:icons$2.electronicSchemeOutline,engineL:icons$2.engineL,engineOutline:icons$2.engineOutline,gearTuningOutline:icons$2.gearTuningOutline,giftBoxOutline:icons$2.giftBoxOutline,lidarOutline:icons$2.lidarOutline,medalStarOutline:icons$2.medalStarOutline,megaphoneOutline:icons$2.megaphoneOutline,multiseatL:icons$2.multiseatL,peopleOutline:icons$2.peopleOutline,personOutline:icons$2.personOutline,physicsOutline:icons$2.physicsOutline,playChainOutline:icons$2.playChainOutline,POITimeL:icons$2.POITimeL,proximitySensorsOutline:icons$2.proximitySensorsOutline,qualityBadgeStarOutline:icons$2.qualityBadgeStarOutline,qualityBadgeVOutline:icons$2.qualityBadgeVOutline,replayL:icons$2.replayL,roadblockL:icons$2.roadblockL,rotationL:icons$2.rotationL,sensorsL:icons$2.sensorsL,simRigOutline:icons$2.simRigOutline,suspensionOutline:icons$2.suspensionOutline,teamOutline:icons$2.teamOutline,techLightBulbOutline01:icons$2.techLightBulbOutline01,techLightBulbOutline02:icons$2.techLightBulbOutline02,temperatureL:icons$2.temperatureL,timeUnlockOutline:icons$2.timeUnlockOutline,timedLockOutline:icons$2.timedLockOutline,trafficOutline:icons$2.trafficOutline,tuningL:icons$2.tuningL,turbineL:icons$2.turbineL,voucherOutline:icons$2.voucherOutline,wheelBeamsNodesOutline:icons$2.wheelBeamsNodesOutline,wheelOutline:icons$2.wheelOutline,bridge:icons$2.bridge,bump:icons$2.bump,bumps:icons$2.bumps,caution:icons$2.caution,crest:icons$2.crest,doubleCaution:icons$2.doubleCaution,finish:icons$2.finish,jumpOverBump:icons$2.jumpOverBump,narrows:icons$2.narrows,pothole:icons$2.pothole,turn1:icons$2.turn1,turn2:icons$2.turn2,turn3:icons$2.turn3,turn4:icons$2.turn4,turn5:icons$2.turn5,turn6:icons$2.turn6,turnHp:icons$2.turnHp,turnSq:icons$2.turnSq,water:icons$2.water,beamCurrencyOutlineLarge:icons$2.beamCurrencyOutlineLarge,carSideOutlineLarge:icons$2.carSideOutlineLarge,flagOutlineLarge:icons$2.flagOutlineLarge,terrainOutlineLarge:icons$2.terrainOutlineLarge,tripleCaution:icons$2.tripleCaution},56:{circlePinBack:icons$2.circlePinBack,circlePinFront:icons$2.circlePinFront,markerRectanglePinBack:icons$2.markerRectanglePinBack,markerRectanglePinFront:icons$2.markerRectanglePinFront,markerTriangleBack:icons$2.markerTriangleBack,markerTriangleFront:icons$2.markerTriangleFront}}),iconsByTag=Object.freeze({vehicle:{"4WD":icons$2[`4WD`],ABSIndicator:icons$2.ABSIndicator,AWD:icons$2.AWD,axleLift:icons$2.axleLift,axleCenter:icons$2.axleCenter,axleFront:icons$2.axleFront,axleRear:icons$2.axleRear,boxTruck:icons$2.boxTruck,bus:icons$2.bus,carChase01:icons$2.carChase01,carCoin:icons$2.carCoin,carCoins:icons$2.carCoins,carCrash:icons$2.carCrash,carOffroadOutlineRear:icons$2.carOffroadOutlineRear,carOffroadOutlineSide:icons$2.carOffroadOutlineSide,carOffroadRear:icons$2.carOffroadRear,carOffroadSide:icons$2.carOffroadSide,carSensors:icons$2.carSensors,carStarred:icons$2.carStarred,carToWheels:icons$2.carToWheels,carUp:icons$2.carUp,carWithLidar:icons$2.carWithLidar,car:icons$2.car,carsChase02:icons$2.carsChase02,cars:icons$2.cars,centrifugalClutchLocked03:icons$2.centrifugalClutchLocked03,centrifugalClutchUnlocked03:icons$2.centrifugalClutchUnlocked03,cogDamaged:icons$2.cogDamaged,cogsDamaged:icons$2.cogsDamaged,cogs:icons$2.cogs,coolantTemp:icons$2.coolantTemp,cruiseDisable:icons$2.cruiseDisable,cruiseEnable:icons$2.cruiseEnable,DCBattery:icons$2.DCBattery,deliveryTruckArrows:icons$2.deliveryTruckArrows,deliveryTruck:icons$2.deliveryTruck,differentialFrontDefault:icons$2.differentialFrontDefault,differentialFrontLocked:icons$2.differentialFrontLocked,differentialMiddleDefault:icons$2.differentialMiddleDefault,differentialMiddleLocked:icons$2.differentialMiddleLocked,differentialRearDefault:icons$2.differentialRearDefault,differentialRearLocked:icons$2.differentialRearLocked,doorHandle:icons$2.doorHandle,drift01:icons$2.drift01,drift02:icons$2.drift02,drivetrainGeneric:icons$2.drivetrainGeneric,drivetrainSpecial:icons$2.drivetrainSpecial,engine:icons$2.engine,ESCOff:icons$2.ESCOff,ESCOn:icons$2.ESCOn,ESC:icons$2.ESC,exhaustValve:icons$2.exhaustValve,flatbedTruck:icons$2.flatbedTruck,fogLight:icons$2.fogLight,forklift:icons$2.forklift,FWD:icons$2.FWD,hazardLights:icons$2.hazardLights,highBeam:icons$2.highBeam,hydroPump1:icons$2.hydroPump1,hydroPump2:icons$2.hydroPump2,hydroPump3:icons$2.hydroPump3,hydroPump4:icons$2.hydroPump4,hydroPump5:icons$2.hydroPump5,hydroPump6:icons$2.hydroPump6,hydroPump7:icons$2.hydroPump7,jointLocked:icons$2.jointLocked,jointUnlocked:icons$2.jointUnlocked,keys1:icons$2.keys1,keys2:icons$2.keys2,limiterEnable:icons$2.limiterEnable,lowBeam:icons$2.lowBeam,minusRes:icons$2.minusRes,mirrorInteriorMiddle:icons$2.mirrorInteriorMiddle,mirrorLeftBigBottomWideAngle:icons$2.mirrorLeftBigBottomWideAngle,mirrorLeftBigTop:icons$2.mirrorLeftBigTop,mirrorLeftBig:icons$2.mirrorLeftBig,mirrorLeftBonnet:icons$2.mirrorLeftBonnet,mirrorLeftDefault:icons$2.mirrorLeftDefault,mirrorRightBigBottomWideAngle:icons$2.mirrorRightBigBottomWideAngle,mirrorRightBigTop:icons$2.mirrorRightBigTop,mirrorRightBig:icons$2.mirrorRightBig,mirrorRightBonnet:icons$2.mirrorRightBonnet,mirrorRightDefault:icons$2.mirrorRightDefault,mirrorRoundWideAngle:icons$2.mirrorRoundWideAngle,mirrorTopWideAngle:icons$2.mirrorTopWideAngle,odometerKM:icons$2.odometerKM,odometerMI:icons$2.odometerMI,odometer:icons$2.odometer,oilPressureIndicator:icons$2.oilPressureIndicator,parkingIndicator:icons$2.parkingIndicator,plusSet:icons$2.plusSet,positionLights:icons$2.positionLights,powerGauge01:icons$2.powerGauge01,powerGauge02:icons$2.powerGauge02,powerGauge03:icons$2.powerGauge03,powerGauge04:icons$2.powerGauge04,powerGauge05:icons$2.powerGauge05,rangeboxHi2:icons$2.rangeboxHi2,rangeboxHi4:icons$2.rangeboxHi4,rangeboxHiA:icons$2.rangeboxHiA,rangeboxLo2:icons$2.rangeboxLo2,rangeboxLo4:icons$2.rangeboxLo4,rangeboxLoA:icons$2.rangeboxLoA,rockCrawling01:icons$2.rockCrawling01,RWD:icons$2.RWD,semiTrailer:icons$2.semiTrailer,semiTruckCabover:icons$2.semiTruckCabover,semiTruckUS:icons$2.semiTruckUS,semiTruck:icons$2.semiTruck,smallTrailer:icons$2.smallTrailer,spoilerLift:icons$2.spoilerLift,strobeLights:icons$2.strobeLights,suspension01:icons$2.suspension01,suspension02:icons$2.suspension02,synchro01:icons$2.synchro01,synchro02:icons$2.synchro02,tankerTrailer:icons$2.tankerTrailer,taxiCar1:icons$2.taxiCar1,taxiCar3:icons$2.taxiCar3,taxiCarT:icons$2.taxiCarT,taxiCheckerLamp:icons$2.taxiCheckerLamp,tirePressureDecrease01:icons$2.tirePressureDecrease01,tirePressureDecrease02:icons$2.tirePressureDecrease02,tirePressureGaugeAlt01:icons$2.tirePressureGaugeAlt01,tirePressureGaugeAlt02:icons$2.tirePressureGaugeAlt02,tirePressureGaugeAlt03:icons$2.tirePressureGaugeAlt03,tirePressureGaugeOutlined01:icons$2.tirePressureGaugeOutlined01,tirePressureGaugeOutlined02:icons$2.tirePressureGaugeOutlined02,tirePressureGaugeOutlined03:icons$2.tirePressureGaugeOutlined03,tirePressureGaugeSolid01:icons$2.tirePressureGaugeSolid01,tirePressureGaugeSolid02:icons$2.tirePressureGaugeSolid02,tirePressureGaugeSolid03:icons$2.tirePressureGaugeSolid03,tirePressureIncrease01:icons$2.tirePressureIncrease01,tirePressureIncrease02:icons$2.tirePressureIncrease02,tirePressureStopLine:icons$2.tirePressureStopLine,tirePressureStopOctoLine:icons$2.tirePressureStopOctoLine,tirePressureStopOctoSolid:icons$2.tirePressureStopOctoSolid,tirePressureStopSolid:icons$2.tirePressureStopSolid,tow:icons$2.tow,tractionControl:icons$2.tractionControl,transmissionA:icons$2.transmissionA,transmissionM:icons$2.transmissionM,turbine:icons$2.turbine,vehicleDoorsClose:icons$2.vehicleDoorsClose,vehicleDoorsOpen:icons$2.vehicleDoorsOpen,vehicleDoors:icons$2.vehicleDoors,vehicleFeatures01:icons$2.vehicleFeatures01,vehicleFeatures02:icons$2.vehicleFeatures02,vehicleFeatures03:icons$2.vehicleFeatures03,vehicleHood:icons$2.vehicleHood,vehicleTrunk:icons$2.vehicleTrunk,wheelHubLocked01:icons$2.wheelHubLocked01,wheelHubUnlocked01:icons$2.wheelHubUnlocked01,wigwags:icons$2.wigwags,wrench:icons$2.wrench,accelerationKPH:icons$2.accelerationKPH,accelerationMPH:icons$2.accelerationMPH,boxTruckFast:icons$2.boxTruckFast,doorFrontCoins:icons$2.doorFrontCoins,doorFront:icons$2.doorFront,engineCoins:icons$2.engineCoins,exhaustMufflerCoins:icons$2.exhaustMufflerCoins,exhaustMuffler:icons$2.exhaustMuffler,headlightCoins:icons$2.headlightCoins,headlight:icons$2.headlight,tire3FourthCoins:icons$2.tire3FourthCoins,tire3Fourth:icons$2.tire3Fourth,turbineCoins:icons$2.turbineCoins,wheelDiscCoins:icons$2.wheelDiscCoins,wheelDisc:icons$2.wheelDisc,busTilted:icons$2.busTilted,jointLockedMultiple:icons$2.jointLockedMultiple,jointUnlockedMultiple:icons$2.jointUnlockedMultiple,airPuffRight1:icons$2.airPuffRight1,carClock:icons$2.carClock,carFast:icons$2.carFast,carNumber1:icons$2.carNumber1,carNumber2:icons$2.carNumber2,carNumber3:icons$2.carNumber3,carNumber4:icons$2.carNumber4,carNumber5:icons$2.carNumber5,carNumber6:icons$2.carNumber6,carNumber7:icons$2.carNumber7,carNumber8:icons$2.carNumber8,carNumber9:icons$2.carNumber9,carPlus:icons$2.carPlus,carsChange:icons$2.carsChange,carsFollow:icons$2.carsFollow,doorFrontDetached:icons$2.doorFrontDetached,hingeBroken:icons$2.hingeBroken,octagonBrick:icons$2.octagonBrick,octagon:icons$2.octagon,tireAirPuff:icons$2.tireAirPuff,tireDeflated:icons$2.tireDeflated,carSideOutlineLarge:icons$2.carSideOutlineLarge,carFastReverse:icons$2.carFastReverse,carsChase:icons$2.carsChase,carsFlee:icons$2.carsFlee,hammerParticles:icons$2.hammerParticles,rangeboxHi:icons$2.rangeboxHi,rangeboxLo:icons$2.rangeboxLo,carsWrench:icons$2.carsWrench,jointCycleMultiple:icons$2.jointCycleMultiple,jointCycle:icons$2.jointCycle,intakeTrumpets:icons$2.intakeTrumpets,transmissionCvt:icons$2.transmissionCvt,auxUpDown:icons$2.auxUpDown,bucketArmUpDown:icons$2.bucketArmUpDown,bucketTilt:icons$2.bucketTilt,bucketArmDown:icons$2.bucketArmDown,bucketArmLevel:icons$2.bucketArmLevel,bucketArmUp:icons$2.bucketArmUp,bucketTiltDown:icons$2.bucketTiltDown,bucketTiltLevel:icons$2.bucketTiltLevel,bucketTiltUp:icons$2.bucketTiltUp,dumpBedDown:icons$2.dumpBedDown,dumpBedUpDown:icons$2.dumpBedUpDown,dumpBedUp:icons$2.dumpBedUp},features:{"4WD":icons$2[`4WD`],ABSIndicator:icons$2.ABSIndicator,AWD:icons$2.AWD,axleLift:icons$2.axleLift,axleCenter:icons$2.axleCenter,axleFront:icons$2.axleFront,axleRear:icons$2.axleRear,carCoin:icons$2.carCoin,carCoins:icons$2.carCoins,carDealer:icons$2.carDealer,carStarred:icons$2.carStarred,centrifugalClutchLocked03:icons$2.centrifugalClutchLocked03,centrifugalClutchUnlocked03:icons$2.centrifugalClutchUnlocked03,cogDamaged:icons$2.cogDamaged,cogsDamaged:icons$2.cogsDamaged,cogs:icons$2.cogs,coolantTemp:icons$2.coolantTemp,cruiseDisable:icons$2.cruiseDisable,cruiseEnable:icons$2.cruiseEnable,DCBattery:icons$2.DCBattery,differentialFrontDefault:icons$2.differentialFrontDefault,differentialFrontLocked:icons$2.differentialFrontLocked,differentialMiddleDefault:icons$2.differentialMiddleDefault,differentialMiddleLocked:icons$2.differentialMiddleLocked,differentialRearDefault:icons$2.differentialRearDefault,differentialRearLocked:icons$2.differentialRearLocked,doorHandle:icons$2.doorHandle,drivetrainGeneric:icons$2.drivetrainGeneric,drivetrainSpecial:icons$2.drivetrainSpecial,engine:icons$2.engine,ESCOff:icons$2.ESCOff,ESCOn:icons$2.ESCOn,ESC:icons$2.ESC,exhaustValve:icons$2.exhaustValve,fogLight:icons$2.fogLight,FWD:icons$2.FWD,garage01:icons$2.garage01,garage02:icons$2.garage02,garage03:icons$2.garage03,hazardLights:icons$2.hazardLights,highBeam:icons$2.highBeam,hydroPump1:icons$2.hydroPump1,hydroPump2:icons$2.hydroPump2,hydroPump3:icons$2.hydroPump3,hydroPump4:icons$2.hydroPump4,hydroPump5:icons$2.hydroPump5,hydroPump6:icons$2.hydroPump6,hydroPump7:icons$2.hydroPump7,jointLocked:icons$2.jointLocked,jointUnlocked:icons$2.jointUnlocked,keys1:icons$2.keys1,keys2:icons$2.keys2,limiterEnable:icons$2.limiterEnable,lowBeam:icons$2.lowBeam,minusRes:icons$2.minusRes,mirrorInteriorMiddle:icons$2.mirrorInteriorMiddle,mirrorLeftBigBottomWideAngle:icons$2.mirrorLeftBigBottomWideAngle,mirrorLeftBigTop:icons$2.mirrorLeftBigTop,mirrorLeftBig:icons$2.mirrorLeftBig,mirrorLeftBonnet:icons$2.mirrorLeftBonnet,mirrorLeftDefault:icons$2.mirrorLeftDefault,mirrorRightBigBottomWideAngle:icons$2.mirrorRightBigBottomWideAngle,mirrorRightBigTop:icons$2.mirrorRightBigTop,mirrorRightBig:icons$2.mirrorRightBig,mirrorRightBonnet:icons$2.mirrorRightBonnet,mirrorRightDefault:icons$2.mirrorRightDefault,mirrorRoundWideAngle:icons$2.mirrorRoundWideAngle,mirrorTopWideAngle:icons$2.mirrorTopWideAngle,odometerKM:icons$2.odometerKM,odometerMI:icons$2.odometerMI,odometer:icons$2.odometer,oilPressureIndicator:icons$2.oilPressureIndicator,parkingIndicator:icons$2.parkingIndicator,plusGarage1:icons$2.plusGarage1,plusGarage2:icons$2.plusGarage2,plusGarage3:icons$2.plusGarage3,plusGarage4:icons$2.plusGarage4,plusSet:icons$2.plusSet,positionLights:icons$2.positionLights,powerGauge01:icons$2.powerGauge01,powerGauge02:icons$2.powerGauge02,powerGauge03:icons$2.powerGauge03,powerGauge04:icons$2.powerGauge04,powerGauge05:icons$2.powerGauge05,rangeboxHi2:icons$2.rangeboxHi2,rangeboxHi4:icons$2.rangeboxHi4,rangeboxHiA:icons$2.rangeboxHiA,rangeboxLo2:icons$2.rangeboxLo2,rangeboxLo4:icons$2.rangeboxLo4,rangeboxLoA:icons$2.rangeboxLoA,RWD:icons$2.RWD,spoilerLift:icons$2.spoilerLift,strobeLights:icons$2.strobeLights,suspension01:icons$2.suspension01,suspension02:icons$2.suspension02,synchro01:icons$2.synchro01,synchro02:icons$2.synchro02,tirePressureDecrease01:icons$2.tirePressureDecrease01,tirePressureDecrease02:icons$2.tirePressureDecrease02,tirePressureGaugeAlt01:icons$2.tirePressureGaugeAlt01,tirePressureGaugeAlt02:icons$2.tirePressureGaugeAlt02,tirePressureGaugeAlt03:icons$2.tirePressureGaugeAlt03,tirePressureGaugeOutlined01:icons$2.tirePressureGaugeOutlined01,tirePressureGaugeOutlined02:icons$2.tirePressureGaugeOutlined02,tirePressureGaugeOutlined03:icons$2.tirePressureGaugeOutlined03,tirePressureGaugeSolid01:icons$2.tirePressureGaugeSolid01,tirePressureGaugeSolid02:icons$2.tirePressureGaugeSolid02,tirePressureGaugeSolid03:icons$2.tirePressureGaugeSolid03,tirePressureIncrease01:icons$2.tirePressureIncrease01,tirePressureIncrease02:icons$2.tirePressureIncrease02,tirePressureStopLine:icons$2.tirePressureStopLine,tirePressureStopOctoLine:icons$2.tirePressureStopOctoLine,tirePressureStopOctoSolid:icons$2.tirePressureStopOctoSolid,tirePressureStopSolid:icons$2.tirePressureStopSolid,tractionControl:icons$2.tractionControl,transmissionA:icons$2.transmissionA,transmissionM:icons$2.transmissionM,turbine:icons$2.turbine,vehicleDoorsClose:icons$2.vehicleDoorsClose,vehicleDoorsOpen:icons$2.vehicleDoorsOpen,vehicleDoors:icons$2.vehicleDoors,vehicleFeatures01:icons$2.vehicleFeatures01,vehicleFeatures02:icons$2.vehicleFeatures02,vehicleFeatures03:icons$2.vehicleFeatures03,vehicleHood:icons$2.vehicleHood,vehicleTrunk:icons$2.vehicleTrunk,wheelHubLocked01:icons$2.wheelHubLocked01,wheelHubUnlocked01:icons$2.wheelHubUnlocked01,wigwags:icons$2.wigwags,wrench:icons$2.wrench,accelerationKPH:icons$2.accelerationKPH,accelerationMPH:icons$2.accelerationMPH,doorFrontCoins:icons$2.doorFrontCoins,doorFront:icons$2.doorFront,engineCoins:icons$2.engineCoins,exhaustMufflerCoins:icons$2.exhaustMufflerCoins,exhaustMuffler:icons$2.exhaustMuffler,headlightCoins:icons$2.headlightCoins,headlight:icons$2.headlight,tire3FourthCoins:icons$2.tire3FourthCoins,tire3Fourth:icons$2.tire3Fourth,turbineCoins:icons$2.turbineCoins,wheelDiscCoins:icons$2.wheelDiscCoins,wheelDisc:icons$2.wheelDisc,jointLockedMultiple:icons$2.jointLockedMultiple,jointUnlockedMultiple:icons$2.jointUnlockedMultiple,bridge:icons$2.bridge,bump:icons$2.bump,bumps:icons$2.bumps,caution:icons$2.caution,crest:icons$2.crest,doubleCaution:icons$2.doubleCaution,finish:icons$2.finish,jumpOverBump:icons$2.jumpOverBump,narrows:icons$2.narrows,pothole:icons$2.pothole,turn1:icons$2.turn1,turn2:icons$2.turn2,turn3:icons$2.turn3,turn4:icons$2.turn4,turn5:icons$2.turn5,turn6:icons$2.turn6,turnHp:icons$2.turnHp,turnSq:icons$2.turnSq,water:icons$2.water,carsFollow:icons$2.carsFollow,doorFrontDetached:icons$2.doorFrontDetached,garageNumber1:icons$2.garageNumber1,garageNumber2:icons$2.garageNumber2,garageNumber3:icons$2.garageNumber3,garageNumber4:icons$2.garageNumber4,garageNumber5:icons$2.garageNumber5,garageNumber6:icons$2.garageNumber6,garageNumber7:icons$2.garageNumber7,garageNumber8:icons$2.garageNumber8,garageNumber9:icons$2.garageNumber9,hingeBroken:icons$2.hingeBroken,houseWrenchRoof:icons$2.houseWrenchRoof,houseWrench:icons$2.houseWrench,tripleCaution:icons$2.tripleCaution,carsChase:icons$2.carsChase,carsFlee:icons$2.carsFlee,hammerParticles:icons$2.hammerParticles,rangeboxHi:icons$2.rangeboxHi,rangeboxLo:icons$2.rangeboxLo,jointCycleMultiple:icons$2.jointCycleMultiple,jointCycle:icons$2.jointCycle,intakeTrumpets:icons$2.intakeTrumpets,transmissionCvt:icons$2.transmissionCvt,house:icons$2.house,auxUpDown:icons$2.auxUpDown,bucketArmUpDown:icons$2.bucketArmUpDown,bucketTilt:icons$2.bucketTilt,bucketArmDown:icons$2.bucketArmDown,bucketArmLevel:icons$2.bucketArmLevel,bucketArmUp:icons$2.bucketArmUp,bucketTiltDown:icons$2.bucketTiltDown,bucketTiltLevel:icons$2.bucketTiltLevel,bucketTiltUp:icons$2.bucketTiltUp,dumpBedDown:icons$2.dumpBedDown,dumpBedUpDown:icons$2.dumpBedUpDown,dumpBedUp:icons$2.dumpBedUp},generic:{"9dividedby10":icons$2[`9dividedby10`],abandon:icons$2.abandon,addItemPolygon:icons$2.addItemPolygon,addListItem:icons$2.addListItem,addPolygonVertex:icons$2.addPolygonVertex,adjust:icons$2.adjust,AIMicrochip:icons$2.AIMicrochip,aperture:icons$2.aperture,autobahn:icons$2.autobahn,bSpline:icons$2.bSpline,beamCrashBarrier1:icons$2.beamCrashBarrier1,beamCrashBarrier2:icons$2.beamCrashBarrier2,beamCrashBarrier3:icons$2.beamCrashBarrier3,beamNG:icons$2.beamNG,bezierPath1:icons$2.bezierPath1,bezierPath2:icons$2.bezierPath2,bicycle1:icons$2.bicycle1,bicycle2:icons$2.bicycle2,BNGFolder:icons$2.BNGFolder,BNGMicrochip:icons$2.BNGMicrochip,bollard:icons$2.bollard,bookmark:icons$2.bookmark,booleanIntersect:icons$2.booleanIntersect,broom:icons$2.broom,bucketAdd:icons$2.bucketAdd,bucketSubtract:icons$2.bucketSubtract,bug:icons$2.bug,bulldozer:icons$2.bulldozer,carChase01:icons$2.carChase01,carCrash:icons$2.carCrash,carOffroadOutlineRear:icons$2.carOffroadOutlineRear,carOffroadOutlineSide:icons$2.carOffroadOutlineSide,carOffroadRear:icons$2.carOffroadRear,carOffroadSide:icons$2.carOffroadSide,carSensors:icons$2.carSensors,carToWheels:icons$2.carToWheels,carUp:icons$2.carUp,carWithLidar:icons$2.carWithLidar,car:icons$2.car,cardboardBox:icons$2.cardboardBox,carsChase02:icons$2.carsChase02,cars:icons$2.cars,catalog01:icons$2.catalog01,catalog02:icons$2.catalog02,catalog03:icons$2.catalog03,chartBars:icons$2.chartBars,checkmarkBold:icons$2.checkmarkBold,checkmark:icons$2.checkmark,circuitMicrochip:icons$2.circuitMicrochip,clapperboard:icons$2.clapperboard,code:icons$2.code,concreteRoadBlock:icons$2.concreteRoadBlock,copy:icons$2.copy,crossroads1:icons$2.crossroads1,crossroads2:icons$2.crossroads2,cup:icons$2.cup,dataExchange:icons$2.dataExchange,decalRoad:icons$2.decalRoad,decal:icons$2.decal,deform:icons$2.deform,doorIn:icons$2.doorIn,editCheckmark:icons$2.editCheckmark,edit:icons$2.edit,exit:icons$2.exit,export:icons$2.export,eyeOutlineClosed:icons$2.eyeOutlineClosed,eyeOutlineOpened:icons$2.eyeOutlineOpened,eyeSolidClosed:icons$2.eyeSolidClosed,eyeSolidOpened:icons$2.eyeSolidOpened,eyeWaves:icons$2.eyeWaves,facility02:icons$2.facility02,filter:icons$2.filter,flatBulbBeam:icons$2.flatBulbBeam,floppyDisk:icons$2.floppyDisk,folder:icons$2.folder,FPS:icons$2.FPS,frontAxleMidpoint:icons$2.frontAxleMidpoint,frontBumperMidpoint:icons$2.frontBumperMidpoint,globe:icons$2.globe,GPSMark:icons$2.GPSMark,GPSSolid:icons$2.GPSSolid,group:icons$2.group,gyroscopeMicrochip:icons$2.gyroscopeMicrochip,gyroscope:icons$2.gyroscope,helmets:icons$2.helmets,help:icons$2.help,HUD:icons$2.HUD,import:icons$2.import,infinity:icons$2.infinity,info:icons$2.info,lampPost1:icons$2.lampPost1,lampPost2:icons$2.lampPost2,lampPost3:icons$2.lampPost3,laneProperties:icons$2.laneProperties,language:icons$2.language,laptop:icons$2.laptop,lidarPatternFullArcHighFreq:icons$2.lidarPatternFullArcHighFreq,lidarPatternFullArcMidFreq:icons$2.lidarPatternFullArcMidFreq,lidarPatternNarrowArc:icons$2.lidarPatternNarrowArc,lidar:icons$2.lidar,lightrunner:icons$2.lightrunner,lineToTerrain:icons$2.lineToTerrain,link2:icons$2.link2,link:icons$2.link,listBig:icons$2.listBig,listIndented:icons$2.listIndented,listSmall:icons$2.listSmall,location1:icons$2.location1,location2:icons$2.location2,lockClosed:icons$2.lockClosed,lockOpened:icons$2.lockOpened,longRangeBeam1:icons$2.longRangeBeam1,longRangeBeam2:icons$2.longRangeBeam2,magnetOnSurface:icons$2.magnetOnSurface,mapWithEmitter:icons$2.mapWithEmitter,mapPoint:icons$2.mapPoint,material:icons$2.material,mathDivide:icons$2.mathDivide,mathGreaterOrEqualThan:icons$2.mathGreaterOrEqualThan,mathGreaterThan:icons$2.mathGreaterThan,mathLessOrEqualThan:icons$2.mathLessOrEqualThan,mathLessThan:icons$2.mathLessThan,mathMinus:icons$2.mathMinus,mathMultiply:icons$2.mathMultiply,mathPlus:icons$2.mathPlus,medal:icons$2.medal,meshFence:icons$2.meshFence,meshRoad:icons$2.meshRoad,midRangeBeam1:icons$2.midRangeBeam1,midRangeBeam2:icons$2.midRangeBeam2,minus:icons$2.minus,move02:icons$2.move02,move:icons$2.move,nodeAddFirst01:icons$2.nodeAddFirst01,nodeAddFirst02:icons$2.nodeAddFirst02,nodeAddLast02:icons$2.nodeAddLast02,nodeAddMiddle01:icons$2.nodeAddMiddle01,nodeAddMiddle02:icons$2.nodeAddMiddle02,nodeAdd:icons$2.nodeAdd,nodeLast01:icons$2.nodeLast01,nodeRemove:icons$2.nodeRemove,order:icons$2.order,organization:icons$2.organization,paperKnife:icons$2.paperKnife,pathArc:icons$2.pathArc,pathLine:icons$2.pathLine,pathSpiral:icons$2.pathSpiral,personSolid:icons$2.personSolid,person:icons$2.person,photo:icons$2.photo,placeholder:icons$2.placeholder,plus:icons$2.plus,powerOnOff:icons$2.powerOnOff,publisher:icons$2.publisher,puzzleModule:icons$2.puzzleModule,radarIdeal:icons$2.radarIdeal,radarRoundIdeal:icons$2.radarRoundIdeal,radarRound:icons$2.radarRound,radar:icons$2.radar,rearAxleMidpoint:icons$2.rearAxleMidpoint,rearBumperMidpoint:icons$2.rearBumperMidpoint,reconfigure:icons$2.reconfigure,redo:icons$2.redo,reflectNot:icons$2.reflectNot,reflect:icons$2.reflect,rename:icons$2.rename,replay:icons$2.replay,restart:icons$2.restart,roadDividerLinesDecal:icons$2.roadDividerLinesDecal,roadEdgeLineDecal:icons$2.roadEdgeLineDecal,roadEndLineDecal:icons$2.roadEndLineDecal,roadFace:icons$2.roadFace,roadInfo:icons$2.roadInfo,roadMarkingOutline:icons$2.roadMarkingOutline,roadMarkingSolid:icons$2.roadMarkingSolid,roadOutline:icons$2.roadOutline,roadRefPathDecal:icons$2.roadRefPathDecal,roadRefPath:icons$2.roadRefPath,roadStartLineDecal:icons$2.roadStartLineDecal,road:icons$2.road,runScript:icons$2.runScript,saveAs1:icons$2.saveAs1,scan:icons$2.scan,search:icons$2.search,shortRangeBeam1:icons$2.shortRangeBeam1,shortRangeBeam2:icons$2.shortRangeBeam2,signal01a:icons$2.signal01a,signal02a:icons$2.signal02a,signal03a:icons$2.signal03a,signal04a:icons$2.signal04a,signal05a:icons$2.signal05a,slashLeft:icons$2.slashLeft,slashRight:icons$2.slashRight,snowflake:icons$2.snowflake,soundFadeOut:icons$2.soundFadeOut,soundLimit:icons$2.soundLimit,soundLoud:icons$2.soundLoud,soundMonoL:icons$2.soundMonoL,soundMonoR:icons$2.soundMonoR,soundOff:icons$2.soundOff,soundQuiet:icons$2.soundQuiet,soundStereo:icons$2.soundStereo,soundWave01:icons$2.soundWave01,soundWave02:icons$2.soundWave02,sphereOnPathNumber:icons$2.sphereOnPathNumber,sphereOnPath:icons$2.sphereOnPath,sphericalBeam:icons$2.sphericalBeam,sprayCan:icons$2.sprayCan,star:icons$2.star,starSecondary:icons$2.starSecondary,stopwatchArrows01:icons$2.stopwatchArrows01,stopwatchArrows02:icons$2.stopwatchArrows02,stopwatchSectionOutlinedEnd:icons$2.stopwatchSectionOutlinedEnd,stopwatchSectionOutlinedStart:icons$2.stopwatchSectionOutlinedStart,stopwatchSectionSolidEnd:icons$2.stopwatchSectionSolidEnd,stopwatchSectionSolidStart:icons$2.stopwatchSectionSolidStart,survellianceCamera:icons$2.survellianceCamera,switchBlock:icons$2.switchBlock,switchOutline:icons$2.switchOutline,sync:icons$2.sync,taxiCar1:icons$2.taxiCar1,taxiCar3:icons$2.taxiCar3,taxiCarT:icons$2.taxiCarT,taxiCheckerLamp:icons$2.taxiCheckerLamp,terrainToLine:icons$2.terrainToLine,terrain:icons$2.terrain,thinBulbBeam:icons$2.thinBulbBeam,thinnerBulbBeam:icons$2.thinnerBulbBeam,tiles:icons$2.tiles,timer:icons$2.timer,toCOMWithWheels:icons$2.toCOMWithWheels,toCOM:icons$2.toCOM,tow:icons$2.tow,transform:icons$2.transform,transparencyMask:icons$2.transparencyMask,trashBin2:icons$2.trashBin2,triangleBeam:icons$2.triangleBeam,trim:icons$2.trim,tulipBeam:icons$2.tulipBeam,tunnel:icons$2.tunnel,twoRoadsAdd:icons$2.twoRoadsAdd,twoRoadsCrossAdd:icons$2.twoRoadsCrossAdd,twoRoadsLink:icons$2.twoRoadsLink,undo:icons$2.undo,ungroup:icons$2.ungroup,unlink:icons$2.unlink,view:icons$2.view,voucherDiagonal1:icons$2.voucherDiagonal1,voucherDiagonal2:icons$2.voucherDiagonal2,voucherDiagonal3:icons$2.voucherDiagonal3,voucherHorizontal1:icons$2.voucherHorizontal1,voucherHorizontal2:icons$2.voucherHorizontal2,voucherHorizontal3:icons$2.voucherHorizontal3,wavesSignalReceived:icons$2.wavesSignalReceived,wavesSignalSentLeft:icons$2.wavesSignalSentLeft,wavesSignalSentRight:icons$2.wavesSignalSentRight,weight:icons$2.weight,wrench:icons$2.wrench,danger:icons$2.danger,droplet:icons$2.droplet,envelope:icons$2.envelope,fireDiamond:icons$2.fireDiamond,xmark:icons$2.xmark,scale:icons$2.scale,locationDestination:icons$2.locationDestination,locationSource:icons$2.locationSource,colorBrightnessSun:icons$2.colorBrightnessSun,colorCirclePalette:icons$2.colorCirclePalette,colorPalette:icons$2.colorPalette,colorSaturation:icons$2.colorSaturation,sortAscDown02:icons$2.sortAscDown02,sortAscDown:icons$2.sortAscDown,sortAscUp02:icons$2.sortAscUp02,sortAscUp:icons$2.sortAscUp,sortDescDown02:icons$2.sortDescDown02,sortDescDown:icons$2.sortDescDown,sortDescUp02:icons$2.sortDescUp02,sortDescUp:icons$2.sortDescUp,cardboardBoxCoins:icons$2.cardboardBoxCoins,lasso:icons$2.lasso,materialGlossy:icons$2.materialGlossy,materialMetal:icons$2.materialMetal,materialRoughness:icons$2.materialRoughness,materialTransparency01:icons$2.materialTransparency01,materialTransparency02:icons$2.materialTransparency02,metal01:icons$2.metal01,removeItemPolygon:icons$2.removeItemPolygon,removeListItem:icons$2.removeListItem,sortAsc:icons$2.sortAsc,sortDesc:icons$2.sortDesc,surfaceRoughness02:icons$2.surfaceRoughness02,shieldCheckmark:icons$2.shieldCheckmark,shieldHandCheckmark:icons$2.shieldHandCheckmark,shieldHandPlus:icons$2.shieldHandPlus,bridgeWithRiver:icons$2.bridgeWithRiver,gizmosOutline:icons$2.gizmosOutline,gizmosSolid:icons$2.gizmosSolid,highwayRoad3To2Merge01:icons$2.highwayRoad3To2Merge01,highwayRoad3To2Merge02:icons$2.highwayRoad3To2Merge02,highwayToUrbanRoadTransition01:icons$2.highwayToUrbanRoadTransition01,highwayToUrbanRoadTransition02:icons$2.highwayToUrbanRoadTransition02,pedestrianCrossing01:icons$2.pedestrianCrossing01,polygonalCube:icons$2.polygonalCube,roadEditOutline:icons$2.roadEditOutline,roadEditSolid:icons$2.roadEditSolid,roadFolderPlus:icons$2.roadFolderPlus,roadFolder:icons$2.roadFolder,roadGuideArrowOutline:icons$2.roadGuideArrowOutline,roadGuideArrowSolid:icons$2.roadGuideArrowSolid,roadOutlineMesh:icons$2.roadOutlineMesh,roadPedestrianCrossing02:icons$2.roadPedestrianCrossing02,roadProfileWithCheckmark:icons$2.roadProfileWithCheckmark,roadProfile:icons$2.roadProfile,roadRoundaboutJunction:icons$2.roadRoundaboutJunction,roadSidewalkTransition:icons$2.roadSidewalkTransition,roadStackPlus:icons$2.roadStackPlus,roadStack:icons$2.roadStack,roadTJunction:icons$2.roadTJunction,roadXJunction:icons$2.roadXJunction,roadYJunction:icons$2.roadYJunction,shoppingCart:icons$2.shoppingCart,singleLineToTerrain:icons$2.singleLineToTerrain,sphereOnMesh:icons$2.sphereOnMesh,twoLinesToTerrain:icons$2.twoLinesToTerrain,urbanRoad3To2Merge01:icons$2.urbanRoad3To2Merge01,urbanRoad3To2Merge02:icons$2.urbanRoad3To2Merge02,urbanRoadToHighwayTransition01:icons$2.urbanRoadToHighwayTransition01,urbanRoadToHighwayTransition02:icons$2.urbanRoadToHighwayTransition02,floppyDiskPlus:icons$2.floppyDiskPlus,highwayMerge:icons$2.highwayMerge,highwaySeparate:icons$2.highwaySeparate,highwayShoulderMerge:icons$2.highwayShoulderMerge,terrainToSingleLine:icons$2.terrainToSingleLine,terrainToTwoLines:icons$2.terrainToTwoLines,urbanRoadMerge:icons$2.urbanRoadMerge,urbanRoadSeparate:icons$2.urbanRoadSeparate,urbanShoulderMerge:icons$2.urbanShoulderMerge,BNGChat:icons$2.BNGChat,chatBubble:icons$2.chatBubble,cameraFarClip:icons$2.cameraFarClip,cameraNearClip:icons$2.cameraNearClip,explosion:icons$2.explosion,fireExtinguisher:icons$2.fireExtinguisher,fire:icons$2.fire,toggleOff:icons$2.toggleOff,toggleOn:icons$2.toggleOn,viewFarClip:icons$2.viewFarClip,viewNearClip:icons$2.viewNearClip,circleSlashed:icons$2.circleSlashed,scissorsSlashed:icons$2.scissorsSlashed,scissors:icons$2.scissors,airPuffRight1:icons$2.airPuffRight1,airPuffUp1:icons$2.airPuffUp1,arrowsReplace:icons$2.arrowsReplace,arrowsShuffle:icons$2.arrowsShuffle,arrowsSwitch:icons$2.arrowsSwitch,carClock:icons$2.carClock,carNumber1:icons$2.carNumber1,carNumber2:icons$2.carNumber2,carNumber3:icons$2.carNumber3,carNumber4:icons$2.carNumber4,carNumber5:icons$2.carNumber5,carNumber6:icons$2.carNumber6,carNumber7:icons$2.carNumber7,carNumber8:icons$2.carNumber8,carNumber9:icons$2.carNumber9,carPlus:icons$2.carPlus,loadMesh:icons$2.loadMesh,octagonBrick:icons$2.octagonBrick,octagon:icons$2.octagon,saveMesh:icons$2.saveMesh,trafficLight:icons$2.trafficLight,enter:icons$2.enter,pedestrianRunning:icons$2.pedestrianRunning,pedestrianStanding:icons$2.pedestrianStanding,seatArrowIn:icons$2.seatArrowIn,seatArrowOut:icons$2.seatArrowOut,seatVArrowIn:icons$2.seatVArrowIn,seatVArrowOut:icons$2.seatVArrowOut,vehicleArrowIn:icons$2.vehicleArrowIn,vehicleArrowOut:icons$2.vehicleArrowOut,leverFrontOperate:icons$2.leverFrontOperate,leverSideDown:icons$2.leverSideDown,leverSideOperate:icons$2.leverSideOperate,leverSideUp:icons$2.leverSideUp,medalEmpty:icons$2.medalEmpty,medalStar:icons$2.medalStar,seatArrowInLeft:icons$2.seatArrowInLeft,seatArrowOutLeft:icons$2.seatArrowOutLeft,seatVArrowInLeft:icons$2.seatVArrowInLeft,seatVArrowOutLeft:icons$2.seatVArrowOutLeft,badgeRoundEmpty:icons$2.badgeRoundEmpty,badgeRoundStar:icons$2.badgeRoundStar,badgeRound:icons$2.badgeRound,badge:icons$2.badge,beamCurrencyOutlineLarge:icons$2.beamCurrencyOutlineLarge,carSideOutlineLarge:icons$2.carSideOutlineLarge,flagOutlineLarge:icons$2.flagOutlineLarge,terrainOutlineLarge:icons$2.terrainOutlineLarge,rallyHelmet3To4:icons$2.rallyHelmet3To4,rallyHelmet:icons$2.rallyHelmet,test:icons$2.test,globeSimpleNotSign:icons$2.globeSimpleNotSign,globeSimplified:icons$2.globeSimplified,radialMenu:icons$2.radialMenu,branch:icons$2.branch,NA:icons$2.NA,magicWand:icons$2.magicWand,dice24:icons$2.dice24,diceD6:icons$2.diceD6,xmarkBold:icons$2.xmarkBold,house:icons$2.house,picture:icons$2.picture,shieldCheckmarkProgressbar:icons$2.shieldCheckmarkProgressbar},warning:{ABSIndicator:icons$2.ABSIndicator,DCBattery:icons$2.DCBattery,oilPressureIndicator:icons$2.oilPressureIndicator,parkingIndicator:icons$2.parkingIndicator},internals:{ABSIndicator:icons$2.ABSIndicator,DCBattery:icons$2.DCBattery,oilPressureIndicator:icons$2.oilPressureIndicator,parkingIndicator:icons$2.parkingIndicator},we:{addItemPolygon:icons$2.addItemPolygon,addListItem:icons$2.addListItem,addPolygonVertex:icons$2.addPolygonVertex,bSpline:icons$2.bSpline,beamCrashBarrier1:icons$2.beamCrashBarrier1,beamCrashBarrier2:icons$2.beamCrashBarrier2,beamCrashBarrier3:icons$2.beamCrashBarrier3,bezierPath1:icons$2.bezierPath1,bezierPath2:icons$2.bezierPath2,bicycle1:icons$2.bicycle1,bicycle2:icons$2.bicycle2,bollard:icons$2.bollard,bulldozer:icons$2.bulldozer,concreteRoadBlock:icons$2.concreteRoadBlock,crossroads1:icons$2.crossroads1,crossroads2:icons$2.crossroads2,decalRoad:icons$2.decalRoad,flatBulbBeam:icons$2.flatBulbBeam,frontAxleMidpoint:icons$2.frontAxleMidpoint,frontBumperMidpoint:icons$2.frontBumperMidpoint,lampPost1:icons$2.lampPost1,lampPost2:icons$2.lampPost2,lampPost3:icons$2.lampPost3,laneProperties:icons$2.laneProperties,lidarPatternFullArcHighFreq:icons$2.lidarPatternFullArcHighFreq,lidarPatternFullArcMidFreq:icons$2.lidarPatternFullArcMidFreq,lidarPatternNarrowArc:icons$2.lidarPatternNarrowArc,lineToTerrain:icons$2.lineToTerrain,longRangeBeam1:icons$2.longRangeBeam1,longRangeBeam2:icons$2.longRangeBeam2,magnetOnSurface:icons$2.magnetOnSurface,meshFence:icons$2.meshFence,meshRoad:icons$2.meshRoad,midRangeBeam1:icons$2.midRangeBeam1,midRangeBeam2:icons$2.midRangeBeam2,pathArc:icons$2.pathArc,pathLine:icons$2.pathLine,pathSpiral:icons$2.pathSpiral,rearAxleMidpoint:icons$2.rearAxleMidpoint,rearBumperMidpoint:icons$2.rearBumperMidpoint,roadDividerLinesDecal:icons$2.roadDividerLinesDecal,roadEdgeLineDecal:icons$2.roadEdgeLineDecal,roadEndLineDecal:icons$2.roadEndLineDecal,roadFace:icons$2.roadFace,roadMarkingOutline:icons$2.roadMarkingOutline,roadMarkingSolid:icons$2.roadMarkingSolid,roadOutline:icons$2.roadOutline,roadRefPathDecal:icons$2.roadRefPathDecal,roadRefPath:icons$2.roadRefPath,roadStartLineDecal:icons$2.roadStartLineDecal,shortRangeBeam1:icons$2.shortRangeBeam1,shortRangeBeam2:icons$2.shortRangeBeam2,sphereOnPathNumber:icons$2.sphereOnPathNumber,sphereOnPath:icons$2.sphereOnPath,sphericalBeam:icons$2.sphericalBeam,terrainToLine:icons$2.terrainToLine,thinBulbBeam:icons$2.thinBulbBeam,thinnerBulbBeam:icons$2.thinnerBulbBeam,toCOMWithWheels:icons$2.toCOMWithWheels,toCOM:icons$2.toCOM,triangleBeam:icons$2.triangleBeam,tulipBeam:icons$2.tulipBeam,tunnel:icons$2.tunnel,twoRoadsAdd:icons$2.twoRoadsAdd,twoRoadsCrossAdd:icons$2.twoRoadsCrossAdd,twoRoadsLink:icons$2.twoRoadsLink,lasso:icons$2.lasso,removeItemPolygon:icons$2.removeItemPolygon,removeListItem:icons$2.removeListItem,bridgeWithRiver:icons$2.bridgeWithRiver,gizmosOutline:icons$2.gizmosOutline,gizmosSolid:icons$2.gizmosSolid,highwayRoad3To2Merge01:icons$2.highwayRoad3To2Merge01,highwayRoad3To2Merge02:icons$2.highwayRoad3To2Merge02,highwayToUrbanRoadTransition01:icons$2.highwayToUrbanRoadTransition01,highwayToUrbanRoadTransition02:icons$2.highwayToUrbanRoadTransition02,pedestrianCrossing01:icons$2.pedestrianCrossing01,polygonalCube:icons$2.polygonalCube,roadEditOutline:icons$2.roadEditOutline,roadEditSolid:icons$2.roadEditSolid,roadFolderPlus:icons$2.roadFolderPlus,roadFolder:icons$2.roadFolder,roadGuideArrowOutline:icons$2.roadGuideArrowOutline,roadGuideArrowSolid:icons$2.roadGuideArrowSolid,roadOutlineMesh:icons$2.roadOutlineMesh,roadPedestrianCrossing02:icons$2.roadPedestrianCrossing02,roadProfileWithCheckmark:icons$2.roadProfileWithCheckmark,roadProfile:icons$2.roadProfile,roadRoundaboutJunction:icons$2.roadRoundaboutJunction,roadSidewalkTransition:icons$2.roadSidewalkTransition,roadStackPlus:icons$2.roadStackPlus,roadStack:icons$2.roadStack,roadTJunction:icons$2.roadTJunction,roadXJunction:icons$2.roadXJunction,roadYJunction:icons$2.roadYJunction,singleLineToTerrain:icons$2.singleLineToTerrain,sphereOnMesh:icons$2.sphereOnMesh,twoLinesToTerrain:icons$2.twoLinesToTerrain,urbanRoad3To2Merge01:icons$2.urbanRoad3To2Merge01,urbanRoad3To2Merge02:icons$2.urbanRoad3To2Merge02,urbanRoadToHighwayTransition01:icons$2.urbanRoadToHighwayTransition01,urbanRoadToHighwayTransition02:icons$2.urbanRoadToHighwayTransition02,highwayMerge:icons$2.highwayMerge,highwaySeparate:icons$2.highwaySeparate,highwayShoulderMerge:icons$2.highwayShoulderMerge,terrainToSingleLine:icons$2.terrainToSingleLine,terrainToTwoLines:icons$2.terrainToTwoLines,urbanRoadMerge:icons$2.urbanRoadMerge,urbanRoadSeparate:icons$2.urbanRoadSeparate,urbanShoulderMerge:icons$2.urbanShoulderMerge},"world editor":{addItemPolygon:icons$2.addItemPolygon,addListItem:icons$2.addListItem,addPolygonVertex:icons$2.addPolygonVertex,bSpline:icons$2.bSpline,beamCrashBarrier1:icons$2.beamCrashBarrier1,beamCrashBarrier2:icons$2.beamCrashBarrier2,beamCrashBarrier3:icons$2.beamCrashBarrier3,bezierPath1:icons$2.bezierPath1,bezierPath2:icons$2.bezierPath2,bicycle1:icons$2.bicycle1,bicycle2:icons$2.bicycle2,bollard:icons$2.bollard,bulldozer:icons$2.bulldozer,concreteRoadBlock:icons$2.concreteRoadBlock,crossroads1:icons$2.crossroads1,crossroads2:icons$2.crossroads2,decalRoad:icons$2.decalRoad,flatBulbBeam:icons$2.flatBulbBeam,frontAxleMidpoint:icons$2.frontAxleMidpoint,frontBumperMidpoint:icons$2.frontBumperMidpoint,lampPost1:icons$2.lampPost1,lampPost2:icons$2.lampPost2,lampPost3:icons$2.lampPost3,laneProperties:icons$2.laneProperties,lidarPatternFullArcHighFreq:icons$2.lidarPatternFullArcHighFreq,lidarPatternFullArcMidFreq:icons$2.lidarPatternFullArcMidFreq,lidarPatternNarrowArc:icons$2.lidarPatternNarrowArc,lineToTerrain:icons$2.lineToTerrain,longRangeBeam1:icons$2.longRangeBeam1,longRangeBeam2:icons$2.longRangeBeam2,magnetOnSurface:icons$2.magnetOnSurface,meshFence:icons$2.meshFence,meshRoad:icons$2.meshRoad,midRangeBeam1:icons$2.midRangeBeam1,midRangeBeam2:icons$2.midRangeBeam2,pathArc:icons$2.pathArc,pathLine:icons$2.pathLine,pathSpiral:icons$2.pathSpiral,rearAxleMidpoint:icons$2.rearAxleMidpoint,rearBumperMidpoint:icons$2.rearBumperMidpoint,roadDividerLinesDecal:icons$2.roadDividerLinesDecal,roadEdgeLineDecal:icons$2.roadEdgeLineDecal,roadEndLineDecal:icons$2.roadEndLineDecal,roadFace:icons$2.roadFace,roadMarkingOutline:icons$2.roadMarkingOutline,roadMarkingSolid:icons$2.roadMarkingSolid,roadOutline:icons$2.roadOutline,roadRefPathDecal:icons$2.roadRefPathDecal,roadRefPath:icons$2.roadRefPath,roadStartLineDecal:icons$2.roadStartLineDecal,shortRangeBeam1:icons$2.shortRangeBeam1,shortRangeBeam2:icons$2.shortRangeBeam2,sphereOnPathNumber:icons$2.sphereOnPathNumber,sphereOnPath:icons$2.sphereOnPath,sphericalBeam:icons$2.sphericalBeam,terrainToLine:icons$2.terrainToLine,thinBulbBeam:icons$2.thinBulbBeam,thinnerBulbBeam:icons$2.thinnerBulbBeam,toCOMWithWheels:icons$2.toCOMWithWheels,toCOM:icons$2.toCOM,triangleBeam:icons$2.triangleBeam,tulipBeam:icons$2.tulipBeam,tunnel:icons$2.tunnel,twoRoadsAdd:icons$2.twoRoadsAdd,twoRoadsCrossAdd:icons$2.twoRoadsCrossAdd,twoRoadsLink:icons$2.twoRoadsLink,lasso:icons$2.lasso,removeItemPolygon:icons$2.removeItemPolygon,removeListItem:icons$2.removeListItem,bridgeWithRiver:icons$2.bridgeWithRiver,gizmosOutline:icons$2.gizmosOutline,gizmosSolid:icons$2.gizmosSolid,highwayRoad3To2Merge01:icons$2.highwayRoad3To2Merge01,highwayRoad3To2Merge02:icons$2.highwayRoad3To2Merge02,highwayToUrbanRoadTransition01:icons$2.highwayToUrbanRoadTransition01,highwayToUrbanRoadTransition02:icons$2.highwayToUrbanRoadTransition02,pedestrianCrossing01:icons$2.pedestrianCrossing01,polygonalCube:icons$2.polygonalCube,roadEditOutline:icons$2.roadEditOutline,roadEditSolid:icons$2.roadEditSolid,roadFolderPlus:icons$2.roadFolderPlus,roadFolder:icons$2.roadFolder,roadGuideArrowOutline:icons$2.roadGuideArrowOutline,roadGuideArrowSolid:icons$2.roadGuideArrowSolid,roadOutlineMesh:icons$2.roadOutlineMesh,roadPedestrianCrossing02:icons$2.roadPedestrianCrossing02,roadProfileWithCheckmark:icons$2.roadProfileWithCheckmark,roadProfile:icons$2.roadProfile,roadRoundaboutJunction:icons$2.roadRoundaboutJunction,roadSidewalkTransition:icons$2.roadSidewalkTransition,roadStackPlus:icons$2.roadStackPlus,roadStack:icons$2.roadStack,roadTJunction:icons$2.roadTJunction,roadXJunction:icons$2.roadXJunction,roadYJunction:icons$2.roadYJunction,singleLineToTerrain:icons$2.singleLineToTerrain,sphereOnMesh:icons$2.sphereOnMesh,twoLinesToTerrain:icons$2.twoLinesToTerrain,urbanRoad3To2Merge01:icons$2.urbanRoad3To2Merge01,urbanRoad3To2Merge02:icons$2.urbanRoad3To2Merge02,urbanRoadToHighwayTransition01:icons$2.urbanRoadToHighwayTransition01,urbanRoadToHighwayTransition02:icons$2.urbanRoadToHighwayTransition02,highwayMerge:icons$2.highwayMerge,highwaySeparate:icons$2.highwaySeparate,highwayShoulderMerge:icons$2.highwayShoulderMerge,terrainToSingleLine:icons$2.terrainToSingleLine,terrainToTwoLines:icons$2.terrainToTwoLines,urbanRoadMerge:icons$2.urbanRoadMerge,urbanRoadSeparate:icons$2.urbanRoadSeparate,urbanShoulderMerge:icons$2.urbanShoulderMerge},"road tools":{addItemPolygon:icons$2.addItemPolygon,addListItem:icons$2.addListItem,addPolygonVertex:icons$2.addPolygonVertex,bSpline:icons$2.bSpline,beamCrashBarrier1:icons$2.beamCrashBarrier1,beamCrashBarrier2:icons$2.beamCrashBarrier2,beamCrashBarrier3:icons$2.beamCrashBarrier3,bezierPath1:icons$2.bezierPath1,bezierPath2:icons$2.bezierPath2,bicycle1:icons$2.bicycle1,bicycle2:icons$2.bicycle2,bollard:icons$2.bollard,bulldozer:icons$2.bulldozer,concreteRoadBlock:icons$2.concreteRoadBlock,crossroads1:icons$2.crossroads1,crossroads2:icons$2.crossroads2,decalRoad:icons$2.decalRoad,lampPost1:icons$2.lampPost1,lampPost2:icons$2.lampPost2,lampPost3:icons$2.lampPost3,laneProperties:icons$2.laneProperties,lineToTerrain:icons$2.lineToTerrain,magnetOnSurface:icons$2.magnetOnSurface,meshFence:icons$2.meshFence,meshRoad:icons$2.meshRoad,pathArc:icons$2.pathArc,pathLine:icons$2.pathLine,pathSpiral:icons$2.pathSpiral,roadDividerLinesDecal:icons$2.roadDividerLinesDecal,roadEdgeLineDecal:icons$2.roadEdgeLineDecal,roadEndLineDecal:icons$2.roadEndLineDecal,roadFace:icons$2.roadFace,roadMarkingSolid:icons$2.roadMarkingSolid,roadOutline:icons$2.roadOutline,roadRefPathDecal:icons$2.roadRefPathDecal,roadRefPath:icons$2.roadRefPath,roadStartLineDecal:icons$2.roadStartLineDecal,sphereOnPathNumber:icons$2.sphereOnPathNumber,sphereOnPath:icons$2.sphereOnPath,terrainToLine:icons$2.terrainToLine,tunnel:icons$2.tunnel,twoRoadsAdd:icons$2.twoRoadsAdd,twoRoadsCrossAdd:icons$2.twoRoadsCrossAdd,twoRoadsLink:icons$2.twoRoadsLink,removeItemPolygon:icons$2.removeItemPolygon,removeListItem:icons$2.removeListItem,bridgeWithRiver:icons$2.bridgeWithRiver,gizmosOutline:icons$2.gizmosOutline,gizmosSolid:icons$2.gizmosSolid,highwayRoad3To2Merge01:icons$2.highwayRoad3To2Merge01,highwayRoad3To2Merge02:icons$2.highwayRoad3To2Merge02,highwayToUrbanRoadTransition01:icons$2.highwayToUrbanRoadTransition01,highwayToUrbanRoadTransition02:icons$2.highwayToUrbanRoadTransition02,pedestrianCrossing01:icons$2.pedestrianCrossing01,polygonalCube:icons$2.polygonalCube,roadEditOutline:icons$2.roadEditOutline,roadEditSolid:icons$2.roadEditSolid,roadFolderPlus:icons$2.roadFolderPlus,roadFolder:icons$2.roadFolder,roadGuideArrowOutline:icons$2.roadGuideArrowOutline,roadGuideArrowSolid:icons$2.roadGuideArrowSolid,roadOutlineMesh:icons$2.roadOutlineMesh,roadPedestrianCrossing02:icons$2.roadPedestrianCrossing02,roadProfileWithCheckmark:icons$2.roadProfileWithCheckmark,roadProfile:icons$2.roadProfile,roadRoundaboutJunction:icons$2.roadRoundaboutJunction,roadSidewalkTransition:icons$2.roadSidewalkTransition,roadStackPlus:icons$2.roadStackPlus,roadStack:icons$2.roadStack,roadTJunction:icons$2.roadTJunction,roadXJunction:icons$2.roadXJunction,roadYJunction:icons$2.roadYJunction,singleLineToTerrain:icons$2.singleLineToTerrain,sphereOnMesh:icons$2.sphereOnMesh,twoLinesToTerrain:icons$2.twoLinesToTerrain,urbanRoad3To2Merge01:icons$2.urbanRoad3To2Merge01,urbanRoad3To2Merge02:icons$2.urbanRoad3To2Merge02,urbanRoadToHighwayTransition01:icons$2.urbanRoadToHighwayTransition01,urbanRoadToHighwayTransition02:icons$2.urbanRoadToHighwayTransition02,highwayMerge:icons$2.highwayMerge,highwaySeparate:icons$2.highwaySeparate,highwayShoulderMerge:icons$2.highwayShoulderMerge,terrainToSingleLine:icons$2.terrainToSingleLine,terrainToTwoLines:icons$2.terrainToTwoLines,urbanRoadMerge:icons$2.urbanRoadMerge,urbanRoadSeparate:icons$2.urbanRoadSeparate,urbanShoulderMerge:icons$2.urbanShoulderMerge},ai:{AIMicrochip:icons$2.AIMicrochip},microchip:{AIMicrochip:icons$2.AIMicrochip},poi:{AIRace:icons$2.AIRace,barrelKnocker01:icons$2.barrelKnocker01,barrelKnocker02:icons$2.barrelKnocker02,boxDropOff01:icons$2.boxDropOff01,boxDropOff02:icons$2.boxDropOff02,boxDropOff03:icons$2.boxDropOff03,boxPickUp01:icons$2.boxPickUp01,boxPickUp02:icons$2.boxPickUp02,boxPickUp03:icons$2.boxPickUp03,boxPickUpDropOff01:icons$2.boxPickUpDropOff01,boxPickUpDropOff02:icons$2.boxPickUpDropOff02,bus:icons$2.bus,cannon:icons$2.cannon,circuit:icons$2.circuit,deliveryTruckArrows:icons$2.deliveryTruckArrows,deliveryTruck:icons$2.deliveryTruck,drag01:icons$2.drag01,drag02:icons$2.drag02,drift01:icons$2.drift01,drift02:icons$2.drift02,evade:icons$2.evade,fastTravel:icons$2.fastTravel,flagNew:icons$2.flagNew,flag:icons$2.flag,gaugeEmpty:icons$2.gaugeEmpty,hypermiling:icons$2.hypermiling,jump:icons$2.jump,parking:icons$2.parking,raceFlag:icons$2.raceFlag,rockCrawling01:icons$2.rockCrawling01,rockCrawling02:icons$2.rockCrawling02,targetJump:icons$2.targetJump,toGarage:icons$2.toGarage,trashBin1:icons$2.trashBin1,circlePinBack:icons$2.circlePinBack,circlePinFront:icons$2.circlePinFront,markerRectanglePinBack:icons$2.markerRectanglePinBack,markerRectanglePinFront:icons$2.markerRectanglePinFront,markerTriangleBack:icons$2.markerTriangleBack,markerTriangleFront:icons$2.markerTriangleFront,busTilted:icons$2.busTilted,gaugeFull:icons$2.gaugeFull},camera:{aperture:icons$2.aperture,camera3Fourth1:icons$2.camera3Fourth1,cameraBack1:icons$2.cameraBack1,cameraFocusOnPath:icons$2.cameraFocusOnPath,cameraFocusOnVehicle1:icons$2.cameraFocusOnVehicle1,cameraFocusOnVehicle2:icons$2.cameraFocusOnVehicle2,cameraFocusTopDown:icons$2.cameraFocusTopDown,cameraFront1:icons$2.cameraFront1,cameraSideLeft:icons$2.cameraSideLeft,cameraSideLeft2:icons$2.cameraSideLeft2,cameraSideRight:icons$2.cameraSideRight,cameraSideRight2:icons$2.cameraSideRight2,cameraTop1:icons$2.cameraTop1,movieCamera:icons$2.movieCamera,pathAroundObstacle:icons$2.pathAroundObstacle,survellianceCamera:icons$2.survellianceCamera,pathDice:icons$2.pathDice},optical:{aperture:icons$2.aperture,survellianceCamera:icons$2.survellianceCamera},sensor:{aperture:icons$2.aperture,eyeWaves:icons$2.eyeWaves,flatBulbBeam:icons$2.flatBulbBeam,frontAxleMidpoint:icons$2.frontAxleMidpoint,frontBumperMidpoint:icons$2.frontBumperMidpoint,GPSMark:icons$2.GPSMark,GPSSolid:icons$2.GPSSolid,gyroscopeMicrochip:icons$2.gyroscopeMicrochip,gyroscope:icons$2.gyroscope,lidarPatternFullArcHighFreq:icons$2.lidarPatternFullArcHighFreq,lidarPatternFullArcMidFreq:icons$2.lidarPatternFullArcMidFreq,lidarPatternNarrowArc:icons$2.lidarPatternNarrowArc,lidar:icons$2.lidar,location1:icons$2.location1,location2:icons$2.location2,longRangeBeam1:icons$2.longRangeBeam1,longRangeBeam2:icons$2.longRangeBeam2,midRangeBeam1:icons$2.midRangeBeam1,midRangeBeam2:icons$2.midRangeBeam2,radarIdeal:icons$2.radarIdeal,radarRoundIdeal:icons$2.radarRoundIdeal,radarRound:icons$2.radarRound,radar:icons$2.radar,rearAxleMidpoint:icons$2.rearAxleMidpoint,rearBumperMidpoint:icons$2.rearBumperMidpoint,shortRangeBeam1:icons$2.shortRangeBeam1,shortRangeBeam2:icons$2.shortRangeBeam2,sphericalBeam:icons$2.sphericalBeam,survellianceCamera:icons$2.survellianceCamera,thinBulbBeam:icons$2.thinBulbBeam,thinnerBulbBeam:icons$2.thinnerBulbBeam,toCOMWithWheels:icons$2.toCOMWithWheels,toCOM:icons$2.toCOM,triangleBeam:icons$2.triangleBeam,tulipBeam:icons$2.tulipBeam,wavesSignalReceived:icons$2.wavesSignalReceived,wavesSignalSentLeft:icons$2.wavesSignalSentLeft,wavesSignalSentRight:icons$2.wavesSignalSentRight},arrow:{arrowLargeDown:icons$2.arrowLargeDown,arrowLargeLeft:icons$2.arrowLargeLeft,arrowLargeRight:icons$2.arrowLargeRight,arrowLargeUp:icons$2.arrowLargeUp,arrowSmallDown:icons$2.arrowSmallDown,arrowSmallLeft:icons$2.arrowSmallLeft,arrowSmallRight:icons$2.arrowSmallRight,arrowSmallUp:icons$2.arrowSmallUp,arrowSolidLeft:icons$2.arrowSolidLeft,arrowSolidRight:icons$2.arrowSolidRight,twoArrowsHorizontal:icons$2.twoArrowsHorizontal,twoArrowsVertical:icons$2.twoArrowsVertical,arrowsReplace:icons$2.arrowsReplace,arrowsShuffle:icons$2.arrowsShuffle,arrowsSwitch:icons$2.arrowsSwitch,seatArrowIn:icons$2.seatArrowIn,seatArrowOut:icons$2.seatArrowOut,seatVArrowIn:icons$2.seatVArrowIn,seatVArrowOut:icons$2.seatVArrowOut,vehicleArrowIn:icons$2.vehicleArrowIn,vehicleArrowOut:icons$2.vehicleArrowOut,seatArrowInLeft:icons$2.seatArrowInLeft,seatArrowOutLeft:icons$2.seatArrowOutLeft,seatVArrowInLeft:icons$2.seatVArrowInLeft,seatVArrowOutLeft:icons$2.seatVArrowOutLeft},large:{arrowLargeDown:icons$2.arrowLargeDown,arrowLargeLeft:icons$2.arrowLargeLeft,arrowLargeRight:icons$2.arrowLargeRight,arrowLargeUp:icons$2.arrowLargeUp,arrowSolidLeft:icons$2.arrowSolidLeft,arrowSolidRight:icons$2.arrowSolidRight,arrowLeftOutline:icons$2.arrowLeftOutline,arrowRightOutline:icons$2.arrowRightOutline,beamsNodesMessageOutline:icons$2.beamsNodesMessageOutline,beamsNodesOutline:icons$2.beamsNodesOutline,beamsNodesPlugOutline:icons$2.beamsNodesPlugOutline,BNGEcosystemOutline:icons$2.BNGEcosystemOutline,carFrontRouteOutline:icons$2.carFrontRouteOutline,carSensorsOutline:icons$2.carSensorsOutline,carSideRouteOutline:icons$2.carSideRouteOutline,cityOutline:icons$2.cityOutline,dialogOutline:icons$2.dialogOutline,documentSmileOutline:icons$2.documentSmileOutline,drivetrainOutline:icons$2.drivetrainOutline,electronicSchemeOutline:icons$2.electronicSchemeOutline,engineOutline:icons$2.engineOutline,gearTuningOutline:icons$2.gearTuningOutline,giftBoxOutline:icons$2.giftBoxOutline,lidarOutline:icons$2.lidarOutline,medalStarOutline:icons$2.medalStarOutline,megaphoneOutline:icons$2.megaphoneOutline,peopleOutline:icons$2.peopleOutline,personOutline:icons$2.personOutline,physicsOutline:icons$2.physicsOutline,playChainOutline:icons$2.playChainOutline,proximitySensorsOutline:icons$2.proximitySensorsOutline,qualityBadgeStarOutline:icons$2.qualityBadgeStarOutline,qualityBadgeVOutline:icons$2.qualityBadgeVOutline,simRigOutline:icons$2.simRigOutline,suspensionOutline:icons$2.suspensionOutline,teamOutline:icons$2.teamOutline,techLightBulbOutline01:icons$2.techLightBulbOutline01,techLightBulbOutline02:icons$2.techLightBulbOutline02,timeUnlockOutline:icons$2.timeUnlockOutline,timedLockOutline:icons$2.timedLockOutline,trafficOutline:icons$2.trafficOutline,voucherOutline:icons$2.voucherOutline,wheelBeamsNodesOutline:icons$2.wheelBeamsNodesOutline,wheelOutline:icons$2.wheelOutline,twoArrowsHorizontal:icons$2.twoArrowsHorizontal,twoArrowsVertical:icons$2.twoArrowsVertical},simple:{arrowLargeDown:icons$2.arrowLargeDown,arrowLargeLeft:icons$2.arrowLargeLeft,arrowLargeRight:icons$2.arrowLargeRight,arrowLargeUp:icons$2.arrowLargeUp,arrowSmallDown:icons$2.arrowSmallDown,arrowSmallLeft:icons$2.arrowSmallLeft,arrowSmallRight:icons$2.arrowSmallRight,arrowSmallUp:icons$2.arrowSmallUp},outlined:{arrowLargeDown:icons$2.arrowLargeDown,arrowLargeLeft:icons$2.arrowLargeLeft,arrowLargeRight:icons$2.arrowLargeRight,arrowLargeUp:icons$2.arrowLargeUp,arrowSmallDown:icons$2.arrowSmallDown,arrowSmallLeft:icons$2.arrowSmallLeft,arrowSmallRight:icons$2.arrowSmallRight,arrowSmallUp:icons$2.arrowSmallUp,roadMarkingOutline:icons$2.roadMarkingOutline,arrowLeftOutline:icons$2.arrowLeftOutline,arrowRightOutline:icons$2.arrowRightOutline,beamsNodesMessageOutline:icons$2.beamsNodesMessageOutline,beamsNodesOutline:icons$2.beamsNodesOutline,beamsNodesPlugOutline:icons$2.beamsNodesPlugOutline,BNGEcosystemOutline:icons$2.BNGEcosystemOutline,carFrontRouteOutline:icons$2.carFrontRouteOutline,carSensorsOutline:icons$2.carSensorsOutline,carSideRouteOutline:icons$2.carSideRouteOutline,cityOutline:icons$2.cityOutline,dialogOutline:icons$2.dialogOutline,documentSmileOutline:icons$2.documentSmileOutline,drivetrainOutline:icons$2.drivetrainOutline,electronicSchemeOutline:icons$2.electronicSchemeOutline,engineOutline:icons$2.engineOutline,gearTuningOutline:icons$2.gearTuningOutline,giftBoxOutline:icons$2.giftBoxOutline,lidarOutline:icons$2.lidarOutline,medalStarOutline:icons$2.medalStarOutline,megaphoneOutline:icons$2.megaphoneOutline,peopleOutline:icons$2.peopleOutline,personOutline:icons$2.personOutline,physicsOutline:icons$2.physicsOutline,playChainOutline:icons$2.playChainOutline,proximitySensorsOutline:icons$2.proximitySensorsOutline,qualityBadgeStarOutline:icons$2.qualityBadgeStarOutline,qualityBadgeVOutline:icons$2.qualityBadgeVOutline,simRigOutline:icons$2.simRigOutline,suspensionOutline:icons$2.suspensionOutline,teamOutline:icons$2.teamOutline,techLightBulbOutline01:icons$2.techLightBulbOutline01,techLightBulbOutline02:icons$2.techLightBulbOutline02,timeUnlockOutline:icons$2.timeUnlockOutline,timedLockOutline:icons$2.timedLockOutline,trafficOutline:icons$2.trafficOutline,voucherOutline:icons$2.voucherOutline,wheelBeamsNodesOutline:icons$2.wheelBeamsNodesOutline,wheelOutline:icons$2.wheelOutline},small:{arrowSmallDown:icons$2.arrowSmallDown,arrowSmallLeft:icons$2.arrowSmallLeft,arrowSmallRight:icons$2.arrowSmallRight,arrowSmallUp:icons$2.arrowSmallUp,mathDivide:icons$2.mathDivide,mathGreaterOrEqualThan:icons$2.mathGreaterOrEqualThan,mathGreaterThan:icons$2.mathGreaterThan,mathLessOrEqualThan:icons$2.mathLessOrEqualThan,mathLessThan:icons$2.mathLessThan,mathMinus:icons$2.mathMinus,mathMultiply:icons$2.mathMultiply,mathPlus:icons$2.mathPlus,slashLeft:icons$2.slashLeft,slashRight:icons$2.slashRight},solid:{arrowSolidLeft:icons$2.arrowSolidLeft,arrowSolidRight:icons$2.arrowSolidRight,twoArrowsHorizontal:icons$2.twoArrowsHorizontal,twoArrowsVertical:icons$2.twoArrowsVertical},detailed:{arrowSolidLeft:icons$2.arrowSolidLeft,arrowSolidRight:icons$2.arrowSolidRight},career:{banknotes:icons$2.banknotes,beamCurrency:icons$2.beamCurrency,beamXPFull:icons$2.beamXPFull,beamXPLo:icons$2.beamXPLo,carDealer:icons$2.carDealer,garage01:icons$2.garage01,garage02:icons$2.garage02,garage03:icons$2.garage03,lightGarageG11:icons$2.lightGarageG11,lightGarageG12:icons$2.lightGarageG12,lightGarageG13:icons$2.lightGarageG13,lightGarageG14:icons$2.lightGarageG14,lightGarageG21:icons$2.lightGarageG21,lightGarageG22:icons$2.lightGarageG22,lightGarageG23:icons$2.lightGarageG23,lightGarageG24:icons$2.lightGarageG24,lightGarageG31:icons$2.lightGarageG31,lightGarageG32:icons$2.lightGarageG32,lightGarageG33:icons$2.lightGarageG33,lightGarageG34:icons$2.lightGarageG34,plusGarage1:icons$2.plusGarage1,plusGarage2:icons$2.plusGarage2,plusGarage3:icons$2.plusGarage3,plusGarage4:icons$2.plusGarage4,voucherDiagonal1:icons$2.voucherDiagonal1,voucherDiagonal2:icons$2.voucherDiagonal2,voucherDiagonal3:icons$2.voucherDiagonal3,voucherHorizontal1:icons$2.voucherHorizontal1,voucherHorizontal2:icons$2.voucherHorizontal2,voucherHorizontal3:icons$2.voucherHorizontal3,garageNumber1:icons$2.garageNumber1,garageNumber2:icons$2.garageNumber2,garageNumber3:icons$2.garageNumber3,garageNumber4:icons$2.garageNumber4,garageNumber5:icons$2.garageNumber5,garageNumber6:icons$2.garageNumber6,garageNumber7:icons$2.garageNumber7,garageNumber8:icons$2.garageNumber8,garageNumber9:icons$2.garageNumber9,houseWrenchRoof:icons$2.houseWrenchRoof,houseWrench:icons$2.houseWrench,house:icons$2.house,beamCurrencyThin:icons$2.beamCurrencyThin},currencies:{banknotes:icons$2.banknotes,beamCurrency:icons$2.beamCurrency,beamXPFull:icons$2.beamXPFull,beamXPLo:icons$2.beamXPLo,beamCurrencyThin:icons$2.beamCurrencyThin},brand:{beamNG:icons$2.beamNG},beamng:{beamNG:icons$2.beamNG},decals:{booleanIntersect:icons$2.booleanIntersect,cameraFocusOnVehicle2:icons$2.cameraFocusOnVehicle2,copy:icons$2.copy,decal:icons$2.decal,deform:icons$2.deform,group:icons$2.group,material:icons$2.material,move:icons$2.move,order:icons$2.order,paperKnife:icons$2.paperKnife,redo:icons$2.redo,reflectNot:icons$2.reflectNot,reflect:icons$2.reflect,rename:icons$2.rename,sprayCan:icons$2.sprayCan,transform:icons$2.transform,transparencyMask:icons$2.transparencyMask,trashBin2:icons$2.trashBin2,undo:icons$2.undo,ungroup:icons$2.ungroup,view:icons$2.view,weight:icons$2.weight,scale:icons$2.scale,materialGlossy:icons$2.materialGlossy,materialMetal:icons$2.materialMetal,materialRoughness:icons$2.materialRoughness,materialTransparency01:icons$2.materialTransparency01,materialTransparency02:icons$2.materialTransparency02,surfaceRoughness02:icons$2.surfaceRoughness02,cameraFarClip:icons$2.cameraFarClip,cameraNearClip:icons$2.cameraNearClip,viewFarClip:icons$2.viewFarClip,viewNearClip:icons$2.viewNearClip},delivery:{boxDropOff01:icons$2.boxDropOff01,boxDropOff02:icons$2.boxDropOff02,boxDropOff03:icons$2.boxDropOff03,boxPickUp01:icons$2.boxPickUp01,boxPickUp02:icons$2.boxPickUp02,boxPickUp03:icons$2.boxPickUp03,boxPickUpDropOff01:icons$2.boxPickUpDropOff01,boxPickUpDropOff02:icons$2.boxPickUpDropOff02,boxTruck:icons$2.boxTruck,cardboardBox:icons$2.cardboardBox,deliveryTruckArrows:icons$2.deliveryTruckArrows,deliveryTruck:icons$2.deliveryTruck,flatbedTruck:icons$2.flatbedTruck,forklift:icons$2.forklift,fragile:icons$2.fragile,semiTrailer:icons$2.semiTrailer,semiTruckCabover:icons$2.semiTruckCabover,semiTruckUS:icons$2.semiTruckUS,semiTruck:icons$2.semiTruck,smallTrailer:icons$2.smallTrailer,stack3:icons$2.stack3,tankerTrailer:icons$2.tankerTrailer,thisSideUp:icons$2.thisSideUp,twoUnicyclesOnly:icons$2.twoUnicyclesOnly,boxTruckFast:icons$2.boxTruckFast,cardboardBoxCoins:icons$2.cardboardBoxCoins},cargo:{boxTruck:icons$2.boxTruck,flatbedTruck:icons$2.flatbedTruck,forklift:icons$2.forklift,fragile:icons$2.fragile,semiTrailer:icons$2.semiTrailer,semiTruckCabover:icons$2.semiTruckCabover,semiTruckUS:icons$2.semiTruckUS,semiTruck:icons$2.semiTruck,smallTrailer:icons$2.smallTrailer,stack3:icons$2.stack3,tankerTrailer:icons$2.tankerTrailer,thisSideUp:icons$2.thisSideUp,twoUnicyclesOnly:icons$2.twoUnicyclesOnly,boxTruckFast:icons$2.boxTruckFast},sound:{broom:icons$2.broom,soundFadeOut:icons$2.soundFadeOut,soundLimit:icons$2.soundLimit,soundLoud:icons$2.soundLoud,soundMonoL:icons$2.soundMonoL,soundMonoR:icons$2.soundMonoR,soundOff:icons$2.soundOff,soundQuiet:icons$2.soundQuiet,soundStereo:icons$2.soundStereo,soundWave01:icons$2.soundWave01,soundWave02:icons$2.soundWave02,trim:icons$2.trim},police:{carChase01:icons$2.carChase01,carsChase02:icons$2.carsChase02,evade:icons$2.evade,strobeLights:icons$2.strobeLights,wigwags:icons$2.wigwags},garage:{carDealer:icons$2.carDealer,garage01:icons$2.garage01,garage02:icons$2.garage02,garage03:icons$2.garage03,lightGarageG11:icons$2.lightGarageG11,lightGarageG12:icons$2.lightGarageG12,lightGarageG13:icons$2.lightGarageG13,lightGarageG14:icons$2.lightGarageG14,lightGarageG21:icons$2.lightGarageG21,lightGarageG22:icons$2.lightGarageG22,lightGarageG23:icons$2.lightGarageG23,lightGarageG24:icons$2.lightGarageG24,lightGarageG31:icons$2.lightGarageG31,lightGarageG32:icons$2.lightGarageG32,lightGarageG33:icons$2.lightGarageG33,lightGarageG34:icons$2.lightGarageG34,plusGarage1:icons$2.plusGarage1,plusGarage2:icons$2.plusGarage2,plusGarage3:icons$2.plusGarage3,plusGarage4:icons$2.plusGarage4,houseWrenchRoof:icons$2.houseWrenchRoof,houseWrench:icons$2.houseWrench,house:icons$2.house},sensors:{carSensors:icons$2.carSensors,carWithLidar:icons$2.carWithLidar,mapWithEmitter:icons$2.mapWithEmitter},tech:{carWithLidar:icons$2.carWithLidar,mapWithEmitter:icons$2.mapWithEmitter,mesh4Cells:icons$2.mesh4Cells,mesh9Cells:icons$2.mesh9Cells},fuel:{charge:icons$2.charge,charging:icons$2.charging,fuelPumpFilling:icons$2.fuelPumpFilling,fuelPump:icons$2.fuelPump,N2OButton:icons$2.N2OButton,N2OHoriz:icons$2.N2OHoriz,N2OVert:icons$2.N2OVert,discharging:icons$2.discharging},electricity:{charge:icons$2.charge,charging:icons$2.charging,discharging:icons$2.discharging},ev:{charge:icons$2.charge,charging:icons$2.charging,discharging:icons$2.discharging},checkbox:{checkboxOff:icons$2.checkboxOff,checkboxOn:icons$2.checkboxOn,missionCheckboxCross:icons$2.missionCheckboxCross},selection:{checkboxOff:icons$2.checkboxOff,checkboxOn:icons$2.checkboxOn,missionCheckboxCross:icons$2.missionCheckboxCross},box:{checkboxOff:icons$2.checkboxOff,checkboxOn:icons$2.checkboxOn,missionCheckboxCross:icons$2.missionCheckboxCross},movie:{clapperboard:icons$2.clapperboard},scenery:{clapperboard:icons$2.clapperboard},powertrain:{cogsDamaged:icons$2.cogsDamaged},drivetrain:{cogsDamaged:icons$2.cogsDamaged},data:{dataExchange:icons$2.dataExchange,eyeWaves:icons$2.eyeWaves,gyroscopeMicrochip:icons$2.gyroscopeMicrochip,gyroscope:icons$2.gyroscope,lidar:icons$2.lidar,radarIdeal:icons$2.radarIdeal,radarRoundIdeal:icons$2.radarRoundIdeal,radarRound:icons$2.radarRound,radar:icons$2.radar,wavesSignalReceived:icons$2.wavesSignalReceived,wavesSignalSentLeft:icons$2.wavesSignalSentLeft,wavesSignalSentRight:icons$2.wavesSignalSentRight},signal:{dataExchange:icons$2.dataExchange,eyeWaves:icons$2.eyeWaves,gyroscopeMicrochip:icons$2.gyroscopeMicrochip,gyroscope:icons$2.gyroscope,lidar:icons$2.lidar,radarIdeal:icons$2.radarIdeal,radarRoundIdeal:icons$2.radarRoundIdeal,radarRound:icons$2.radarRound,radar:icons$2.radar,wavesSignalReceived:icons$2.wavesSignalReceived,wavesSignalSentLeft:icons$2.wavesSignalSentLeft,wavesSignalSentRight:icons$2.wavesSignalSentRight},environment:{day:icons$2.day,night:icons$2.night,sunRise:icons$2.sunRise,weather:icons$2.weather,sunDown:icons$2.sunDown},part:{engine:icons$2.engine,suspension01:icons$2.suspension01,turbine:icons$2.turbine,doorFrontCoins:icons$2.doorFrontCoins,doorFront:icons$2.doorFront,engineCoins:icons$2.engineCoins,exhaustMufflerCoins:icons$2.exhaustMufflerCoins,exhaustMuffler:icons$2.exhaustMuffler,headlightCoins:icons$2.headlightCoins,headlight:icons$2.headlight,tire3FourthCoins:icons$2.tire3FourthCoins,tire3Fourth:icons$2.tire3Fourth,turbineCoins:icons$2.turbineCoins,wheelDiscCoins:icons$2.wheelDiscCoins,wheelDisc:icons$2.wheelDisc,doorFrontDetached:icons$2.doorFrontDetached,hingeBroken:icons$2.hingeBroken},mission:{evade:icons$2.evade,flagOutlineLarge:icons$2.flagOutlineLarge},playback:{fastBackward:icons$2.fastBackward,fastForward:icons$2.fastForward,music:icons$2.music,nextTrack:icons$2.nextTrack,pauseRound:icons$2.pauseRound,pause:icons$2.pause,playRound:icons$2.playRound,play:icons$2.play,playlist:icons$2.playlist,prevTrack:icons$2.prevTrack,square:icons$2.square,eject:icons$2.eject,playPause:icons$2.playPause},truck:{flatbedTruck:icons$2.flatbedTruck,semiTruckCabover:icons$2.semiTruckCabover,semiTruckUS:icons$2.semiTruckUS,semiTruck:icons$2.semiTruck},stencil:{forklift:icons$2.forklift,fragile:icons$2.fragile,stack3:icons$2.stack3,thisSideUp:icons$2.thisSideUp,twoUnicyclesOnly:icons$2.twoUnicyclesOnly},placement:{frontAxleMidpoint:icons$2.frontAxleMidpoint,frontBumperMidpoint:icons$2.frontBumperMidpoint,rearAxleMidpoint:icons$2.rearAxleMidpoint,rearBumperMidpoint:icons$2.rearBumperMidpoint,toCOMWithWheels:icons$2.toCOMWithWheels,toCOM:icons$2.toCOM},gamepad:{gamepadOld:icons$2.gamepadOld,gamepad:icons$2.gamepad,noNameControllerButton:icons$2.noNameControllerButton,xboxA:icons$2.xboxA,xboxB:icons$2.xboxB,xboxDDefaultOutline:icons$2.xboxDDefaultOutline,xboxDDefaultSolid:icons$2.xboxDDefaultSolid,xboxDDown:icons$2.xboxDDown,xboxDLeft:icons$2.xboxDLeft,xboxDRight:icons$2.xboxDRight,xboxDUp:icons$2.xboxDUp,xboxLB:icons$2.xboxLB,xboxLSButton:icons$2.xboxLSButton,xboxLT:icons$2.xboxLT,xboxMenu:icons$2.xboxMenu,xboxRB:icons$2.xboxRB,xboxRSButton:icons$2.xboxRSButton,xboxRT:icons$2.xboxRT,xboxThumbL:icons$2.xboxThumbL,xboxThumbR:icons$2.xboxThumbR,xboxView:icons$2.xboxView,xboxXAxis:icons$2.xboxXAxis,xboxXRot:icons$2.xboxXRot,xboxX:icons$2.xboxX,xboxYAxis:icons$2.xboxYAxis,xboxYRot:icons$2.xboxYRot,xboxY:icons$2.xboxY,psCircleOutline:icons$2.psCircleOutline,psCircle:icons$2.psCircle,psCreate2:icons$2.psCreate2,psCreate:icons$2.psCreate,psCrossOutline:icons$2.psCrossOutline,psCross:icons$2.psCross,psDDefaultOutline:icons$2.psDDefaultOutline,psDDefaultSolid:icons$2.psDDefaultSolid,psDDown:icons$2.psDDown,psDLeft:icons$2.psDLeft,psDRight:icons$2.psDRight,psDUp:icons$2.psDUp,psL1:icons$2.psL1,psL2:icons$2.psL2,psL3ButtonArrowDown:icons$2.psL3ButtonArrowDown,psL3Button:icons$2.psL3Button,psLSXLeft:icons$2.psLSXLeft,psLSXRight:icons$2.psLSXRight,psLSX:icons$2.psLSX,psLSYDown:icons$2.psLSYDown,psLSYUp:icons$2.psLSYUp,psLSY:icons$2.psLSY,psLS:icons$2.psLS,psMenu2:icons$2.psMenu2,psMenu:icons$2.psMenu,psR1:icons$2.psR1,psR2:icons$2.psR2,psR3ButtonArrowDown:icons$2.psR3ButtonArrowDown,psR3Button:icons$2.psR3Button,psRSXLeft:icons$2.psRSXLeft,psRSXRight:icons$2.psRSXRight,psRSX:icons$2.psRSX,psRSYDown:icons$2.psRSYDown,psRSYUp:icons$2.psRSYUp,psRSY:icons$2.psRSY,psRS:icons$2.psRS,psSquareOutline:icons$2.psSquareOutline,psSquare:icons$2.psSquare,psTrackpadNavigate:icons$2.psTrackpadNavigate,psTrackpadPressCenter:icons$2.psTrackpadPressCenter,psTrackpadPressLeft:icons$2.psTrackpadPressLeft,psTrackpadPressRight:icons$2.psTrackpadPressRight,psTrackpadSwipeDown:icons$2.psTrackpadSwipeDown,psTrackpadSwipeLeft:icons$2.psTrackpadSwipeLeft,psTrackpadSwipeRight:icons$2.psTrackpadSwipeRight,psTrackpadSwipeUp:icons$2.psTrackpadSwipeUp,psTriangleOutline:icons$2.psTriangleOutline,psTriangle:icons$2.psTriangle,xboxAOutline:icons$2.xboxAOutline,xboxBOutline:icons$2.xboxBOutline,xboxLSButtonArrowDown:icons$2.xboxLSButtonArrowDown,xboxRSButtonArrowDown:icons$2.xboxRSButtonArrowDown,xboxXAxisLeft:icons$2.xboxXAxisLeft,xboxXAxisRight:icons$2.xboxXAxisRight,xboxXOutline:icons$2.xboxXOutline,xboxXRotLeft:icons$2.xboxXRotLeft,xboxXRotRight:icons$2.xboxXRotRight,xboxYAxisDown:icons$2.xboxYAxisDown,xboxYAxisUp:icons$2.xboxYAxisUp,xboxYOutline:icons$2.xboxYOutline,xboxYRotDown:icons$2.xboxYRotDown,xboxYRotUp:icons$2.xboxYRotUp,psDLeftRight:icons$2.psDLeftRight,psDUpDown:icons$2.psDUpDown,xboxDLeftRight:icons$2.xboxDLeftRight,xboxDUpDown:icons$2.xboxDUpDown},controller:{gamepadOld:icons$2.gamepadOld,gamepad:icons$2.gamepad,noNameControllerButton:icons$2.noNameControllerButton,steeringWheelCommon:icons$2.steeringWheelCommon,steeringWheelSporty:icons$2.steeringWheelSporty,xboxA:icons$2.xboxA,xboxB:icons$2.xboxB,xboxDDefaultOutline:icons$2.xboxDDefaultOutline,xboxDDefaultSolid:icons$2.xboxDDefaultSolid,xboxDDown:icons$2.xboxDDown,xboxDLeft:icons$2.xboxDLeft,xboxDRight:icons$2.xboxDRight,xboxDUp:icons$2.xboxDUp,xboxLB:icons$2.xboxLB,xboxLSButton:icons$2.xboxLSButton,xboxLT:icons$2.xboxLT,xboxMenu:icons$2.xboxMenu,xboxRB:icons$2.xboxRB,xboxRSButton:icons$2.xboxRSButton,xboxRT:icons$2.xboxRT,xboxThumbL:icons$2.xboxThumbL,xboxThumbR:icons$2.xboxThumbR,xboxView:icons$2.xboxView,xboxXAxis:icons$2.xboxXAxis,xboxXRot:icons$2.xboxXRot,xboxX:icons$2.xboxX,xboxYAxis:icons$2.xboxYAxis,xboxYRot:icons$2.xboxYRot,xboxY:icons$2.xboxY,psCircleOutline:icons$2.psCircleOutline,psCircle:icons$2.psCircle,psCreate2:icons$2.psCreate2,psCreate:icons$2.psCreate,psCrossOutline:icons$2.psCrossOutline,psCross:icons$2.psCross,psDDefaultOutline:icons$2.psDDefaultOutline,psDDefaultSolid:icons$2.psDDefaultSolid,psDDown:icons$2.psDDown,psDLeft:icons$2.psDLeft,psDRight:icons$2.psDRight,psDUp:icons$2.psDUp,psL1:icons$2.psL1,psL2:icons$2.psL2,psL3ButtonArrowDown:icons$2.psL3ButtonArrowDown,psL3Button:icons$2.psL3Button,psLSXLeft:icons$2.psLSXLeft,psLSXRight:icons$2.psLSXRight,psLSX:icons$2.psLSX,psLSYDown:icons$2.psLSYDown,psLSYUp:icons$2.psLSYUp,psLSY:icons$2.psLSY,psLS:icons$2.psLS,psMenu2:icons$2.psMenu2,psMenu:icons$2.psMenu,psR1:icons$2.psR1,psR2:icons$2.psR2,psR3ButtonArrowDown:icons$2.psR3ButtonArrowDown,psR3Button:icons$2.psR3Button,psRSXLeft:icons$2.psRSXLeft,psRSXRight:icons$2.psRSXRight,psRSX:icons$2.psRSX,psRSYDown:icons$2.psRSYDown,psRSYUp:icons$2.psRSYUp,psRSY:icons$2.psRSY,psRS:icons$2.psRS,psSquareOutline:icons$2.psSquareOutline,psSquare:icons$2.psSquare,psTrackpadNavigate:icons$2.psTrackpadNavigate,psTrackpadPressCenter:icons$2.psTrackpadPressCenter,psTrackpadPressLeft:icons$2.psTrackpadPressLeft,psTrackpadPressRight:icons$2.psTrackpadPressRight,psTrackpadSwipeDown:icons$2.psTrackpadSwipeDown,psTrackpadSwipeLeft:icons$2.psTrackpadSwipeLeft,psTrackpadSwipeRight:icons$2.psTrackpadSwipeRight,psTrackpadSwipeUp:icons$2.psTrackpadSwipeUp,psTriangleOutline:icons$2.psTriangleOutline,psTriangle:icons$2.psTriangle,xboxAOutline:icons$2.xboxAOutline,xboxBOutline:icons$2.xboxBOutline,xboxLSButtonArrowDown:icons$2.xboxLSButtonArrowDown,xboxRSButtonArrowDown:icons$2.xboxRSButtonArrowDown,xboxXAxisLeft:icons$2.xboxXAxisLeft,xboxXAxisRight:icons$2.xboxXAxisRight,xboxXOutline:icons$2.xboxXOutline,xboxXRotLeft:icons$2.xboxXRotLeft,xboxXRotRight:icons$2.xboxXRotRight,xboxYAxisDown:icons$2.xboxYAxisDown,xboxYAxisUp:icons$2.xboxYAxisUp,xboxYOutline:icons$2.xboxYOutline,xboxYRotDown:icons$2.xboxYRotDown,xboxYRotUp:icons$2.xboxYRotUp,psDLeftRight:icons$2.psDLeftRight,psDUpDown:icons$2.psDUpDown,xboxDLeftRight:icons$2.xboxDLeftRight,xboxDUpDown:icons$2.xboxDUpDown},input:{gamepadOld:icons$2.gamepadOld,gamepad:icons$2.gamepad,keyboard:icons$2.keyboard,mouseLMB:icons$2.mouseLMB,mouseMMB:icons$2.mouseMMB,mouseRMB:icons$2.mouseRMB,mouseWheel:icons$2.mouseWheel,mouseXAxis:icons$2.mouseXAxis,mouseXYAxis:icons$2.mouseXYAxis,mouseYAxis:icons$2.mouseYAxis,mouse:icons$2.mouse,noNameControllerButton:icons$2.noNameControllerButton,palmCrossed:icons$2.palmCrossed,smartphone1:icons$2.smartphone1,smartphone2:icons$2.smartphone2,steeringWheelCommon:icons$2.steeringWheelCommon,steeringWheelSporty:icons$2.steeringWheelSporty,touch:icons$2.touch,xboxA:icons$2.xboxA,xboxB:icons$2.xboxB,xboxDDefaultOutline:icons$2.xboxDDefaultOutline,xboxDDefaultSolid:icons$2.xboxDDefaultSolid,xboxDDown:icons$2.xboxDDown,xboxDLeft:icons$2.xboxDLeft,xboxDRight:icons$2.xboxDRight,xboxDUp:icons$2.xboxDUp,xboxLB:icons$2.xboxLB,xboxLSButton:icons$2.xboxLSButton,xboxLT:icons$2.xboxLT,xboxMenu:icons$2.xboxMenu,xboxRB:icons$2.xboxRB,xboxRSButton:icons$2.xboxRSButton,xboxRT:icons$2.xboxRT,xboxThumbL:icons$2.xboxThumbL,xboxThumbR:icons$2.xboxThumbR,xboxView:icons$2.xboxView,xboxXAxis:icons$2.xboxXAxis,xboxXRot:icons$2.xboxXRot,xboxX:icons$2.xboxX,xboxYAxis:icons$2.xboxYAxis,xboxYRot:icons$2.xboxYRot,xboxY:icons$2.xboxY,psCircleOutline:icons$2.psCircleOutline,psCircle:icons$2.psCircle,psCreate2:icons$2.psCreate2,psCreate:icons$2.psCreate,psCrossOutline:icons$2.psCrossOutline,psCross:icons$2.psCross,psDDefaultOutline:icons$2.psDDefaultOutline,psDDefaultSolid:icons$2.psDDefaultSolid,psDDown:icons$2.psDDown,psDLeft:icons$2.psDLeft,psDRight:icons$2.psDRight,psDUp:icons$2.psDUp,psL1:icons$2.psL1,psL2:icons$2.psL2,psL3ButtonArrowDown:icons$2.psL3ButtonArrowDown,psL3Button:icons$2.psL3Button,psLSXLeft:icons$2.psLSXLeft,psLSXRight:icons$2.psLSXRight,psLSX:icons$2.psLSX,psLSYDown:icons$2.psLSYDown,psLSYUp:icons$2.psLSYUp,psLSY:icons$2.psLSY,psLS:icons$2.psLS,psMenu2:icons$2.psMenu2,psMenu:icons$2.psMenu,psR1:icons$2.psR1,psR2:icons$2.psR2,psR3ButtonArrowDown:icons$2.psR3ButtonArrowDown,psR3Button:icons$2.psR3Button,psRSXLeft:icons$2.psRSXLeft,psRSXRight:icons$2.psRSXRight,psRSX:icons$2.psRSX,psRSYDown:icons$2.psRSYDown,psRSYUp:icons$2.psRSYUp,psRSY:icons$2.psRSY,psRS:icons$2.psRS,psSquareOutline:icons$2.psSquareOutline,psSquare:icons$2.psSquare,psTrackpadNavigate:icons$2.psTrackpadNavigate,psTrackpadPressCenter:icons$2.psTrackpadPressCenter,psTrackpadPressLeft:icons$2.psTrackpadPressLeft,psTrackpadPressRight:icons$2.psTrackpadPressRight,psTrackpadSwipeDown:icons$2.psTrackpadSwipeDown,psTrackpadSwipeLeft:icons$2.psTrackpadSwipeLeft,psTrackpadSwipeRight:icons$2.psTrackpadSwipeRight,psTrackpadSwipeUp:icons$2.psTrackpadSwipeUp,psTriangleOutline:icons$2.psTriangleOutline,psTriangle:icons$2.psTriangle,xboxAOutline:icons$2.xboxAOutline,xboxBOutline:icons$2.xboxBOutline,xboxLSButtonArrowDown:icons$2.xboxLSButtonArrowDown,xboxRSButtonArrowDown:icons$2.xboxRSButtonArrowDown,xboxXAxisLeft:icons$2.xboxXAxisLeft,xboxXAxisRight:icons$2.xboxXAxisRight,xboxXOutline:icons$2.xboxXOutline,xboxXRotLeft:icons$2.xboxXRotLeft,xboxXRotRight:icons$2.xboxXRotRight,xboxYAxisDown:icons$2.xboxYAxisDown,xboxYAxisUp:icons$2.xboxYAxisUp,xboxYOutline:icons$2.xboxYOutline,xboxYRotDown:icons$2.xboxYRotDown,xboxYRotUp:icons$2.xboxYRotUp,psDLeftRight:icons$2.psDLeftRight,psDUpDown:icons$2.psDUpDown,xboxDLeftRight:icons$2.xboxDLeftRight,xboxDUpDown:icons$2.xboxDUpDown},gps:{GPSMark:icons$2.GPSMark,GPSSolid:icons$2.GPSSolid,location1:icons$2.location1,location2:icons$2.location2},position:{GPSMark:icons$2.GPSMark,GPSSolid:icons$2.GPSSolid,location1:icons$2.location1,location2:icons$2.location2},map:{GPSMark:icons$2.GPSMark,GPSSolid:icons$2.GPSSolid,location1:icons$2.location1,location2:icons$2.location2},keyboard:{keyboard:icons$2.keyboard,kbArrowsDown:icons$2.kbArrowsDown,kbArrowsLeftRight:icons$2.kbArrowsLeftRight,kbArrowsLeft:icons$2.kbArrowsLeft,kbArrowsOutline:icons$2.kbArrowsOutline,kbArrowsRight:icons$2.kbArrowsRight,kbArrowsSolid:icons$2.kbArrowsSolid,kbArrowsUpDown:icons$2.kbArrowsUpDown,kbArrowsUp:icons$2.kbArrowsUp},lights:{lightGarageG11:icons$2.lightGarageG11,lightGarageG12:icons$2.lightGarageG12,lightGarageG13:icons$2.lightGarageG13,lightGarageG14:icons$2.lightGarageG14,lightGarageG21:icons$2.lightGarageG21,lightGarageG22:icons$2.lightGarageG22,lightGarageG23:icons$2.lightGarageG23,lightGarageG24:icons$2.lightGarageG24,lightGarageG31:icons$2.lightGarageG31,lightGarageG32:icons$2.lightGarageG32,lightGarageG33:icons$2.lightGarageG33,lightGarageG34:icons$2.lightGarageG34},catalog:{listBig:icons$2.listBig,listSmall:icons$2.listSmall,tiles:icons$2.tiles},selector:{listBig:icons$2.listBig,listSmall:icons$2.listSmall,tiles:icons$2.tiles},view:{listBig:icons$2.listBig,listSmall:icons$2.listSmall,tiles:icons$2.tiles},math:{mathDivide:icons$2.mathDivide,mathGreaterOrEqualThan:icons$2.mathGreaterOrEqualThan,mathGreaterThan:icons$2.mathGreaterThan,mathLessOrEqualThan:icons$2.mathLessOrEqualThan,mathLessThan:icons$2.mathLessThan,mathMinus:icons$2.mathMinus,mathMultiply:icons$2.mathMultiply,mathPlus:icons$2.mathPlus,slashLeft:icons$2.slashLeft,slashRight:icons$2.slashRight},operands:{mathDivide:icons$2.mathDivide,mathGreaterOrEqualThan:icons$2.mathGreaterOrEqualThan,mathGreaterThan:icons$2.mathGreaterThan,mathLessOrEqualThan:icons$2.mathLessOrEqualThan,mathLessThan:icons$2.mathLessThan,mathMinus:icons$2.mathMinus,mathMultiply:icons$2.mathMultiply,mathPlus:icons$2.mathPlus,slashLeft:icons$2.slashLeft,slashRight:icons$2.slashRight},reward:{medal:icons$2.medal,voucherDiagonal1:icons$2.voucherDiagonal1,voucherDiagonal2:icons$2.voucherDiagonal2,voucherDiagonal3:icons$2.voucherDiagonal3,voucherHorizontal1:icons$2.voucherHorizontal1,voucherHorizontal2:icons$2.voucherHorizontal2,voucherHorizontal3:icons$2.voucherHorizontal3,medalEmpty:icons$2.medalEmpty,medalStar:icons$2.medalStar,badgeRoundEmpty:icons$2.badgeRoundEmpty,badgeRoundStar:icons$2.badgeRoundStar,badgeRound:icons$2.badgeRound,badge:icons$2.badge},achievment:{medal:icons$2.medal,medalEmpty:icons$2.medalEmpty,medalStar:icons$2.medalStar,badgeRoundEmpty:icons$2.badgeRoundEmpty,badgeRoundStar:icons$2.badgeRoundStar,badgeRound:icons$2.badgeRound,badge:icons$2.badge},mesh:{mesh4Cells:icons$2.mesh4Cells,mesh9Cells:icons$2.mesh9Cells},beams:{mesh4Cells:icons$2.mesh4Cells,mesh9Cells:icons$2.mesh9Cells},nodes:{mesh4Cells:icons$2.mesh4Cells,mesh9Cells:icons$2.mesh9Cells},surface:{mesh4Cells:icons$2.mesh4Cells,mesh9Cells:icons$2.mesh9Cells,bridge:icons$2.bridge,bump:icons$2.bump,bumps:icons$2.bumps,caution:icons$2.caution,crest:icons$2.crest,doubleCaution:icons$2.doubleCaution,finish:icons$2.finish,jumpOverBump:icons$2.jumpOverBump,narrows:icons$2.narrows,pothole:icons$2.pothole,turn1:icons$2.turn1,turn2:icons$2.turn2,turn3:icons$2.turn3,turn4:icons$2.turn4,turn5:icons$2.turn5,turn6:icons$2.turn6,turnHp:icons$2.turnHp,turnSq:icons$2.turnSq,water:icons$2.water,tripleCaution:icons$2.tripleCaution},mirror:{mirrorInteriorMiddle:icons$2.mirrorInteriorMiddle,mirrorLeftBigBottomWideAngle:icons$2.mirrorLeftBigBottomWideAngle,mirrorLeftBigTop:icons$2.mirrorLeftBigTop,mirrorLeftBig:icons$2.mirrorLeftBig,mirrorLeftBonnet:icons$2.mirrorLeftBonnet,mirrorLeftDefault:icons$2.mirrorLeftDefault,mirrorRightBigBottomWideAngle:icons$2.mirrorRightBigBottomWideAngle,mirrorRightBigTop:icons$2.mirrorRightBigTop,mirrorRightBig:icons$2.mirrorRightBig,mirrorRightBonnet:icons$2.mirrorRightBonnet,mirrorRightDefault:icons$2.mirrorRightDefault,mirrorRoundWideAngle:icons$2.mirrorRoundWideAngle,mirrorTopWideAngle:icons$2.mirrorTopWideAngle},rearview:{mirrorInteriorMiddle:icons$2.mirrorInteriorMiddle,mirrorLeftBigBottomWideAngle:icons$2.mirrorLeftBigBottomWideAngle,mirrorLeftBigTop:icons$2.mirrorLeftBigTop,mirrorLeftBig:icons$2.mirrorLeftBig,mirrorLeftBonnet:icons$2.mirrorLeftBonnet,mirrorLeftDefault:icons$2.mirrorLeftDefault,mirrorRightBigBottomWideAngle:icons$2.mirrorRightBigBottomWideAngle,mirrorRightBigTop:icons$2.mirrorRightBigTop,mirrorRightBig:icons$2.mirrorRightBig,mirrorRightBonnet:icons$2.mirrorRightBonnet,mirrorRightDefault:icons$2.mirrorRightDefault,mirrorRoundWideAngle:icons$2.mirrorRoundWideAngle,mirrorTopWideAngle:icons$2.mirrorTopWideAngle},mouse:{mouseLMB:icons$2.mouseLMB,mouseMMB:icons$2.mouseMMB,mouseRMB:icons$2.mouseRMB,mouseWheel:icons$2.mouseWheel,mouseXAxis:icons$2.mouseXAxis,mouseXYAxis:icons$2.mouseXYAxis,mouseYAxis:icons$2.mouseYAxis,mouse:icons$2.mouse},path:{nodeAddFirst01:icons$2.nodeAddFirst01,nodeAddFirst02:icons$2.nodeAddFirst02,nodeAddLast02:icons$2.nodeAddLast02,nodeAddMiddle01:icons$2.nodeAddMiddle01,nodeAddMiddle02:icons$2.nodeAddMiddle02,nodeAdd:icons$2.nodeAdd,nodeLast01:icons$2.nodeLast01,nodeRemove:icons$2.nodeRemove,locationDestination:icons$2.locationDestination,locationSource:icons$2.locationSource},node:{nodeAddFirst01:icons$2.nodeAddFirst01,nodeAddFirst02:icons$2.nodeAddFirst02,nodeAddLast02:icons$2.nodeAddLast02,nodeAddMiddle01:icons$2.nodeAddMiddle01,nodeAddMiddle02:icons$2.nodeAddMiddle02,nodeAdd:icons$2.nodeAdd,nodeLast01:icons$2.nodeLast01,nodeRemove:icons$2.nodeRemove,locationDestination:icons$2.locationDestination,locationSource:icons$2.locationSource},touch:{palmCrossed:icons$2.palmCrossed,smartphone1:icons$2.smartphone1,smartphone2:icons$2.smartphone2,touch:icons$2.touch},route:{routeAdd:icons$2.routeAdd,routeComplex:icons$2.routeComplex,routeSimple:icons$2.routeSimple,trafficCone:icons$2.trafficCone,locationDestination:icons$2.locationDestination,locationSource:icons$2.locationSource,routeSimpleFlag:icons$2.routeSimpleFlag},traffic:{routeAdd:icons$2.routeAdd,routeComplex:icons$2.routeComplex,routeSimple:icons$2.routeSimple,trafficCone:icons$2.trafficCone,trafficLight:icons$2.trafficLight,pedestrianRunning:icons$2.pedestrianRunning,pedestrianStanding:icons$2.pedestrianStanding,routeSimpleFlag:icons$2.routeSimpleFlag},trailer:{semiTrailer:icons$2.semiTrailer,semiTruck:icons$2.semiTruck,smallTrailer:icons$2.smallTrailer,tankerTrailer:icons$2.tankerTrailer},steering:{steeringWheelCommon:icons$2.steeringWheelCommon,steeringWheelSporty:icons$2.steeringWheelSporty},time:{stopwatchArrows01:icons$2.stopwatchArrows01,stopwatchArrows02:icons$2.stopwatchArrows02,stopwatchSectionOutlinedEnd:icons$2.stopwatchSectionOutlinedEnd,stopwatchSectionOutlinedStart:icons$2.stopwatchSectionOutlinedStart,stopwatchSectionSolidEnd:icons$2.stopwatchSectionSolidEnd,stopwatchSectionSolidStart:icons$2.stopwatchSectionSolidStart,timer:icons$2.timer},fast:{stopwatchArrows01:icons$2.stopwatchArrows01,stopwatchArrows02:icons$2.stopwatchArrows02,stopwatchSectionOutlinedEnd:icons$2.stopwatchSectionOutlinedEnd,stopwatchSectionOutlinedStart:icons$2.stopwatchSectionOutlinedStart,stopwatchSectionSolidEnd:icons$2.stopwatchSectionSolidEnd,stopwatchSectionSolidStart:icons$2.stopwatchSectionSolidStart,timer:icons$2.timer},emergency:{strobeLights:icons$2.strobeLights,wigwags:icons$2.wigwags},circuit:{switchBlock:icons$2.switchBlock,switchOutline:icons$2.switchOutline},electronics:{switchBlock:icons$2.switchBlock,switchOutline:icons$2.switchOutline},switch:{switchBlock:icons$2.switchBlock,switchOutline:icons$2.switchOutline},tank:{tankerTrailer:icons$2.tankerTrailer},tanker:{tankerTrailer:icons$2.tankerTrailer},taxi:{taxiCar1:icons$2.taxiCar1,taxiCar3:icons$2.taxiCar3,taxiCarT:icons$2.taxiCarT,taxiCheckerLamp:icons$2.taxiCheckerLamp},tire:{tireDirection3Fourth2:icons$2.tireDirection3Fourth2,tireDirection3Fourth3:icons$2.tireDirection3Fourth3,tireDirectionFront2:icons$2.tireDirectionFront2,tireDirectionSide2:icons$2.tireDirectionSide2,tireDirectionTop2:icons$2.tireDirectionTop2,tire3FourthCoins:icons$2.tire3FourthCoins,tire3Fourth:icons$2.tire3Fourth},currency:{voucherDiagonal1:icons$2.voucherDiagonal1,voucherDiagonal2:icons$2.voucherDiagonal2,voucherDiagonal3:icons$2.voucherDiagonal3,voucherHorizontal1:icons$2.voucherHorizontal1,voucherHorizontal2:icons$2.voucherHorizontal2,voucherHorizontal3:icons$2.voucherHorizontal3,beamCurrencyOutlineLarge:icons$2.beamCurrencyOutlineLarge},extra:{AIL:icons$2.AIL,automaticTransmissionL:icons$2.automaticTransmissionL,chargeLL:icons$2.chargeLL,clutchL:icons$2.clutchL,couplerL:icons$2.couplerL,engineL:icons$2.engineL,multiseatL:icons$2.multiseatL,POITimeL:icons$2.POITimeL,replayL:icons$2.replayL,roadblockL:icons$2.roadblockL,rotationL:icons$2.rotationL,sensorsL:icons$2.sensorsL,temperatureL:icons$2.temperatureL,tuningL:icons$2.tuningL,turbineL:icons$2.turbineL},web:{arrowLeftOutline:icons$2.arrowLeftOutline,arrowRightOutline:icons$2.arrowRightOutline,beamsNodesMessageOutline:icons$2.beamsNodesMessageOutline,beamsNodesOutline:icons$2.beamsNodesOutline,beamsNodesPlugOutline:icons$2.beamsNodesPlugOutline,BNGEcosystemOutline:icons$2.BNGEcosystemOutline,carFrontRouteOutline:icons$2.carFrontRouteOutline,carSensorsOutline:icons$2.carSensorsOutline,carSideRouteOutline:icons$2.carSideRouteOutline,cityOutline:icons$2.cityOutline,dialogOutline:icons$2.dialogOutline,documentSmileOutline:icons$2.documentSmileOutline,drivetrainOutline:icons$2.drivetrainOutline,electronicSchemeOutline:icons$2.electronicSchemeOutline,engineOutline:icons$2.engineOutline,gearTuningOutline:icons$2.gearTuningOutline,giftBoxOutline:icons$2.giftBoxOutline,lidarOutline:icons$2.lidarOutline,medalStarOutline:icons$2.medalStarOutline,megaphoneOutline:icons$2.megaphoneOutline,peopleOutline:icons$2.peopleOutline,personOutline:icons$2.personOutline,physicsOutline:icons$2.physicsOutline,playChainOutline:icons$2.playChainOutline,proximitySensorsOutline:icons$2.proximitySensorsOutline,qualityBadgeStarOutline:icons$2.qualityBadgeStarOutline,qualityBadgeVOutline:icons$2.qualityBadgeVOutline,simRigOutline:icons$2.simRigOutline,suspensionOutline:icons$2.suspensionOutline,teamOutline:icons$2.teamOutline,techLightBulbOutline01:icons$2.techLightBulbOutline01,techLightBulbOutline02:icons$2.techLightBulbOutline02,timeUnlockOutline:icons$2.timeUnlockOutline,timedLockOutline:icons$2.timedLockOutline,trafficOutline:icons$2.trafficOutline,voucherOutline:icons$2.voucherOutline,wheelBeamsNodesOutline:icons$2.wheelBeamsNodesOutline,wheelOutline:icons$2.wheelOutline},secondary:{arrowLeftOutline:icons$2.arrowLeftOutline,arrowRightOutline:icons$2.arrowRightOutline,beamsNodesMessageOutline:icons$2.beamsNodesMessageOutline,beamsNodesOutline:icons$2.beamsNodesOutline,beamsNodesPlugOutline:icons$2.beamsNodesPlugOutline,BNGEcosystemOutline:icons$2.BNGEcosystemOutline,carFrontRouteOutline:icons$2.carFrontRouteOutline,carSensorsOutline:icons$2.carSensorsOutline,carSideRouteOutline:icons$2.carSideRouteOutline,cityOutline:icons$2.cityOutline,dialogOutline:icons$2.dialogOutline,documentSmileOutline:icons$2.documentSmileOutline,drivetrainOutline:icons$2.drivetrainOutline,electronicSchemeOutline:icons$2.electronicSchemeOutline,engineOutline:icons$2.engineOutline,gearTuningOutline:icons$2.gearTuningOutline,giftBoxOutline:icons$2.giftBoxOutline,lidarOutline:icons$2.lidarOutline,medalStarOutline:icons$2.medalStarOutline,megaphoneOutline:icons$2.megaphoneOutline,peopleOutline:icons$2.peopleOutline,personOutline:icons$2.personOutline,physicsOutline:icons$2.physicsOutline,playChainOutline:icons$2.playChainOutline,proximitySensorsOutline:icons$2.proximitySensorsOutline,qualityBadgeStarOutline:icons$2.qualityBadgeStarOutline,qualityBadgeVOutline:icons$2.qualityBadgeVOutline,simRigOutline:icons$2.simRigOutline,suspensionOutline:icons$2.suspensionOutline,teamOutline:icons$2.teamOutline,techLightBulbOutline01:icons$2.techLightBulbOutline01,techLightBulbOutline02:icons$2.techLightBulbOutline02,timeUnlockOutline:icons$2.timeUnlockOutline,timedLockOutline:icons$2.timedLockOutline,trafficOutline:icons$2.trafficOutline,voucherOutline:icons$2.voucherOutline,wheelBeamsNodesOutline:icons$2.wheelBeamsNodesOutline,wheelOutline:icons$2.wheelOutline},hazard:{danger:icons$2.danger,fireDiamond:icons$2.fireDiamond,test:icons$2.test},drop:{droplet:icons$2.droplet},liquid:{droplet:icons$2.droplet},nfpa704:{fireDiamond:icons$2.fireDiamond},"dry cargo":{rocks:icons$2.rocks},dry:{rocks:icons$2.rocks},editor:{scale:icons$2.scale},marker:{arrowsUp:icons$2.arrowsUp,bigDot:icons$2.bigDot,connectorBold:icons$2.connectorBold,cornerTopRight:icons$2.cornerTopRight,plusBold:icons$2.plusBold,puzzlePieceBold:icons$2.puzzlePieceBold},ribbon:{arrowsUp:icons$2.arrowsUp,bigDot:icons$2.bigDot,connectorBold:icons$2.connectorBold,cornerTopRight:icons$2.cornerTopRight,plusBold:icons$2.plusBold,puzzlePieceBold:icons$2.puzzlePieceBold},"content-props":{arrowsUp:icons$2.arrowsUp,bigDot:icons$2.bigDot,connectorBold:icons$2.connectorBold,cornerTopRight:icons$2.cornerTopRight,plusBold:icons$2.plusBold,puzzlePieceBold:icons$2.puzzlePieceBold},location:{locationDestination:icons$2.locationDestination,locationSource:icons$2.locationSource},shop:{shoppingCart:icons$2.shoppingCart},purchase:{shoppingCart:icons$2.shoppingCart},bus:{busTilted:icons$2.busTilted},destruction:{explosion:icons$2.explosion,fireExtinguisher:icons$2.fireExtinguisher,fire:icons$2.fire},"turn signals":{twoArrowsHorizontal:icons$2.twoArrowsHorizontal,twoArrowsVertical:icons$2.twoArrowsVertical},rally:{bridge:icons$2.bridge,bump:icons$2.bump,bumps:icons$2.bumps,caution:icons$2.caution,crest:icons$2.crest,doubleCaution:icons$2.doubleCaution,finish:icons$2.finish,jumpOverBump:icons$2.jumpOverBump,narrows:icons$2.narrows,pothole:icons$2.pothole,turn1:icons$2.turn1,turn2:icons$2.turn2,turn3:icons$2.turn3,turn4:icons$2.turn4,turn5:icons$2.turn5,turn6:icons$2.turn6,turnHp:icons$2.turnHp,turnSq:icons$2.turnSq,water:icons$2.water,rallyHelmet3To4:icons$2.rallyHelmet3To4,rallyHelmet:icons$2.rallyHelmet,tripleCaution:icons$2.tripleCaution},"pace notes":{bridge:icons$2.bridge,bump:icons$2.bump,bumps:icons$2.bumps,caution:icons$2.caution,crest:icons$2.crest,doubleCaution:icons$2.doubleCaution,finish:icons$2.finish,jumpOverBump:icons$2.jumpOverBump,narrows:icons$2.narrows,pothole:icons$2.pothole,turn1:icons$2.turn1,turn2:icons$2.turn2,turn3:icons$2.turn3,turn4:icons$2.turn4,turn5:icons$2.turn5,turn6:icons$2.turn6,turnHp:icons$2.turnHp,turnSq:icons$2.turnSq,water:icons$2.water,tripleCaution:icons$2.tripleCaution},directions:{bridge:icons$2.bridge,bump:icons$2.bump,bumps:icons$2.bumps,caution:icons$2.caution,crest:icons$2.crest,doubleCaution:icons$2.doubleCaution,finish:icons$2.finish,jumpOverBump:icons$2.jumpOverBump,narrows:icons$2.narrows,pothole:icons$2.pothole,turn1:icons$2.turn1,turn2:icons$2.turn2,turn3:icons$2.turn3,turn4:icons$2.turn4,turn5:icons$2.turn5,turn6:icons$2.turn6,turnHp:icons$2.turnHp,turnSq:icons$2.turnSq,water:icons$2.water,tripleCaution:icons$2.tripleCaution},"do not cut":{circleSlashed:icons$2.circleSlashed,scissorsSlashed:icons$2.scissorsSlashed},"no entry":{circleSlashed:icons$2.circleSlashed},cut:{scissors:icons$2.scissors},car:{airPuffRight1:icons$2.airPuffRight1,octagonBrick:icons$2.octagonBrick,octagon:icons$2.octagon,tireAirPuff:icons$2.tireAirPuff,tireDeflated:icons$2.tireDeflated},select:{carsChange:icons$2.carsChange,carsWrench:icons$2.carsWrench},physics:{forceFieldPull1:icons$2.forceFieldPull1,forceFieldPull2:icons$2.forceFieldPull2,forceFieldPull3:icons$2.forceFieldPull3,forceFieldPush1:icons$2.forceFieldPush1,forceFieldPush2:icons$2.forceFieldPush2,forceFieldPush3:icons$2.forceFieldPush3,pushUp:icons$2.pushUp,pushBackward:icons$2.pushBackward,pushDown:icons$2.pushDown,pushForward:icons$2.pushForward},field:{forceFieldPull1:icons$2.forceFieldPull1,forceFieldPull2:icons$2.forceFieldPull2,forceFieldPull3:icons$2.forceFieldPull3,forceFieldPush1:icons$2.forceFieldPush1,forceFieldPush2:icons$2.forceFieldPush2,forceFieldPush3:icons$2.forceFieldPush3},force:{forceFieldPull1:icons$2.forceFieldPull1,forceFieldPull2:icons$2.forceFieldPull2,forceFieldPull3:icons$2.forceFieldPull3,forceFieldPush1:icons$2.forceFieldPush1,forceFieldPush2:icons$2.forceFieldPush2,forceFieldPush3:icons$2.forceFieldPush3,pushUp:icons$2.pushUp,pushBackward:icons$2.pushBackward,pushDown:icons$2.pushDown,pushForward:icons$2.pushForward},"garage number":{garageNumber1:icons$2.garageNumber1,garageNumber2:icons$2.garageNumber2,garageNumber3:icons$2.garageNumber3,garageNumber4:icons$2.garageNumber4,garageNumber5:icons$2.garageNumber5,garageNumber6:icons$2.garageNumber6,garageNumber7:icons$2.garageNumber7,garageNumber8:icons$2.garageNumber8,garageNumber9:icons$2.garageNumber9},stop:{square:icons$2.square},roads:{trafficLight:icons$2.trafficLight},sign:{pedestrianRunning:icons$2.pedestrianRunning,pedestrianStanding:icons$2.pedestrianStanding},pedestrian:{pedestrianRunning:icons$2.pedestrianRunning,pedestrianStanding:icons$2.pedestrianStanding},actions:{seatArrowIn:icons$2.seatArrowIn,seatArrowOut:icons$2.seatArrowOut,seatVArrowIn:icons$2.seatVArrowIn,seatVArrowOut:icons$2.seatVArrowOut,vehicleArrowIn:icons$2.vehicleArrowIn,vehicleArrowOut:icons$2.vehicleArrowOut,leverFrontOperate:icons$2.leverFrontOperate,leverSideDown:icons$2.leverSideDown,leverSideOperate:icons$2.leverSideOperate,leverSideUp:icons$2.leverSideUp,seatArrowInLeft:icons$2.seatArrowInLeft,seatArrowOutLeft:icons$2.seatArrowOutLeft,seatVArrowInLeft:icons$2.seatVArrowInLeft,seatVArrowOutLeft:icons$2.seatVArrowOutLeft},outline:{beamCurrencyOutlineLarge:icons$2.beamCurrencyOutlineLarge},scenario:{flagOutlineLarge:icons$2.flagOutlineLarge},house:{houseWrenchRoof:icons$2.houseWrenchRoof,houseWrench:icons$2.houseWrench,house:icons$2.house},helmet:{rallyHelmet3To4:icons$2.rallyHelmet3To4,rallyHelmet:icons$2.rallyHelmet},racing:{rallyHelmet3To4:icons$2.rallyHelmet3To4,rallyHelmet:icons$2.rallyHelmet},"game mode":{rallyHelmet3To4:icons$2.rallyHelmet3To4,rallyHelmet:icons$2.rallyHelmet},offline:{globeSimpleNotSign:icons$2.globeSimpleNotSign},online:{globeSimplified:icons$2.globeSimplified},material:{cableSection:icons$2.cableSection,strapHook:icons$2.strapHook,strapRatchet:icons$2.strapRatchet},beam:{cableSection:icons$2.cableSection},strap:{cableSection:icons$2.cableSection,strapHook:icons$2.strapHook,strapRatchet:icons$2.strapRatchet},controls:{kbArrowsDown:icons$2.kbArrowsDown,kbArrowsLeftRight:icons$2.kbArrowsLeftRight,kbArrowsLeft:icons$2.kbArrowsLeft,kbArrowsOutline:icons$2.kbArrowsOutline,kbArrowsRight:icons$2.kbArrowsRight,kbArrowsSolid:icons$2.kbArrowsSolid,kbArrowsUpDown:icons$2.kbArrowsUpDown,kbArrowsUp:icons$2.kbArrowsUp},equipment:{auxUpDown:icons$2.auxUpDown,bucketArmUpDown:icons$2.bucketArmUpDown,bucketTilt:icons$2.bucketTilt,bucketArmDown:icons$2.bucketArmDown,bucketArmLevel:icons$2.bucketArmLevel,bucketArmUp:icons$2.bucketArmUp,bucketTiltDown:icons$2.bucketTiltDown,bucketTiltLevel:icons$2.bucketTiltLevel,bucketTiltUp:icons$2.bucketTiltUp,dumpBedDown:icons$2.dumpBedDown,dumpBedUpDown:icons$2.dumpBedUpDown,dumpBedUp:icons$2.dumpBedUp}}),getIconsWithTags=(...tagsToFind)=>Object.fromEntries(Object.entries(icons$2).filter(([name,{tags}])=>{for(let t of tagsToFind)if(!tags.includes(t))return!1;return!0})),icons=Object.freeze({...icons$2,_empty:{...icons$2.minus,invisible:!0}}),_sfc_main$369={__name:`bngIcon`,props:{type:{type:[String,Object],default:``},fallbackType:{type:String,default:`placeholder`},color:{type:String,default:`#fff`},asImage:{},image:String,externalImage:String},setup(__props){useCssVars(_ctx=>({v9bdaf084:__props.color}));let props=__props,hasImageSource=computed(()=>!!props.image||!!props.externalImage),imageSrcKey=computed(()=>props.image||props.externalImage||``),errorSrcKey=ref(``),isCurrentSrcErrored=computed(()=>!!imageSrcKey.value&&errorSrcKey.value===imageSrcKey.value),isGlyph=computed(()=>!!(!hasImageSource.value||isCurrentSrcErrored.value)),icon=computed(()=>{let res;switch(typeof props.type){case`object`:props.type.glyph&&(res=props.type);break;case`string`:props.type in icons&&(res=icons[props.type]);break}return res}),displayIcon=computed(()=>{let fallback=typeof props.fallbackType==`string`&&props.fallbackType in icons?icons[props.fallbackType]:icons.placeholder;return isCurrentSrcErrored.value||!icon.value&&!hasImageSource.value?fallback:icon.value}),iconGlyph=computed(()=>displayIcon.value?displayIcon.value.glyph:icons.placeholder.glyph),OFF_VALUES=[null,void 0,!1,`false`,0,`0`],asImage=computed(()=>OFF_VALUES.includes(props.asImage)?!1:props.asImage||!0),imageProps=computed(()=>{let res={bgColor:props.color,mask:[`mask`,`span`].includes(asImage.value)};return icon.value||(res.bgColor=`#f00`),asImage.value||(props.image?res.src=props.image:props.externalImage&&(res.externalSrc=props.externalImage)),res});function onImageError(){errorSrcKey.value=imageSrcKey.value}return(_ctx,_cache)=>isGlyph.value?(openBlock(),createElementBlock(`span`,{key:0,class:normalizeClass([`icon-base`,{"icon-not-found":displayIcon.value===unref(icons).placeholder,"icon-invisible":displayIcon.value&&displayIcon.value.invisible}])},toDisplayString(iconGlyph.value),3)):(openBlock(),createBlock(unref(bngImageAsset_default),mergeProps({key:1,class:`icon-img`},imageProps.value,{onError:onImageError}),null,16))}},bngIcon_default=__plugin_vue_export_helper_default(_sfc_main$369,[[`__scopeId`,`data-v-978d1732`]]),markerValidate=name=>name.endsWith(`Back`)&&Object.keys(iconsBySize[56]).includes(name.replace(/Back$/,`Front`))||name.endsWith(`Front`)&&Object.keys(iconsBySize[56]).includes(name.replace(/Front$/,`Back`)),markersList=Object.keys(iconsBySize[56]).filter(markerValidate).map(name=>name.replace(/Back$|Front$/,``)).sort((a$1,b)=>a$1.toLowerCase().localeCompare(b.toLowerCase())).reduce((res,name)=>res.includes(name)?res:[...res,name],[]);const markers=Object.fromEntries(markersList.map(i=>[i,i])),MARKER_POINTS={up:`up`,down:`down`,left:`left`,right:`right`};var _sfc_main$368={__name:`bngIconMarker`,props:{marker:{type:String,default:`circlePin`,validator:val=>!!markers[val]},type:[String,Object],color:[String,Array],point:{type:String,default:`down`,validator:val=>MARKER_POINTS[val]}},setup(__props){let props=__props,icon=computed(()=>({back:iconsBySize[56][props.marker+`Back`],front:iconsBySize[56][props.marker+`Front`]})),iconColour=computed(()=>({back:(Array.isArray(props.color)?props.color[0]:props.color)||`#fff`,front:(Array.isArray(props.color)?props.color[1]:null)||`#000`,icon:(Array.isArray(props.color)?props.color[2]||props.color[0]:props.color)||`#fff`}));return(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,{class:normalizeClass([`icon-marker`,`icon-point-${__props.point}`,`icon-type-${__props.marker}`])},[createVNode(unref(bngIcon_default),{class:`icon-back`,type:icon.value.back,color:iconColour.value.back},null,8,[`type`,`color`]),createVNode(unref(bngIcon_default),{class:`icon-front`,type:icon.value.front,color:iconColour.value.front},null,8,[`type`,`color`]),__props.type?(openBlock(),createBlock(unref(bngIcon_default),{key:0,class:`icon-inner`,type:__props.type,color:iconColour.value.icon},null,8,[`type`,`color`])):createCommentVNode(``,!0)],2))}},bngIconMarker_default=__plugin_vue_export_helper_default(_sfc_main$368,[[`__scopeId`,`data-v-1089accc`]]),_hoisted_1$322=[`src`],_sfc_main$367=Object.assign({inheritAttrs:!1},{__name:`bngImage`,props:{src:String,observe:Boolean},setup(__props){let props=__props,attrs=useAttrs(),observe=computed(()=>props.observe?`observe`:void 0),imgAttrs=computed(()=>showCanvas.value?{}:attrs),cvsAttrs=computed(()=>showCanvas.value?attrs:{}),elImg=ref(null),elCanvas=ref(null),showCanvas=ref(!1),imgSrc=ref(emptyImage),parentDataAttrs={};function setImage(elm,url,bmp){bmp?(showCanvas.value=!0,imgSrc.value=emptyImage,elCanvas.value.width=bmp.width,elCanvas.value.height=bmp.height,elCanvas.value.getContext(`2d`).drawImage(bmp,0,0),Object.entries(parentDataAttrs).forEach(([attr,value])=>{elCanvas.value.setAttribute(attr,value)})):(showCanvas.value=!1,imgSrc.value=url||`data:image/svg+xml,`)}return watch(()=>props.src,()=>{elImg.value&&(showCanvas.value=!1,imgSrc.value=emptyImage)}),watch(elImg,elm=>{if(elm){parentDataAttrs={};for(let attr of elm.parentElement.getAttributeNames())attr.startsWith(`data-v-`)&&(parentDataAttrs[attr]=elm.parentElement.getAttribute(attr));Object.entries(parentDataAttrs).forEach(([attr,value])=>{elm.setAttribute(attr,value),elCanvas.value&&elCanvas.value.setAttribute(attr,value)}),elm.__setImage=setImage}},{immediate:!0}),(_ctx,_cache)=>(openBlock(),createElementBlock(Fragment,null,[withDirectives(createBaseVNode(`img`,mergeProps({ref_key:`elImg`,ref:elImg},imgAttrs.value,{src:imgSrc.value,alt:``}),null,16,_hoisted_1$322),[[vShow,!showCanvas.value],[unref(BngLazyImage_default),{url:__props.src,callback:setImage},observe.value]]),withDirectives(createBaseVNode(`canvas`,mergeProps({ref_key:`elCanvas`,ref:elCanvas},cvsAttrs.value),null,16),[[vShow,showCanvas.value]])],64))}}),bngImage_default=_sfc_main$367,_hoisted_1$321=[`src`],_sfc_main$366={__name:`bngImageAsset`,props:{src:String,externalSrc:String,span:Boolean,mask:Boolean,bgColor:{type:String,default:`transparent`}},emits:[`error`,`load`],setup(__props,{emit:__emit}){useCssVars(_ctx=>({v0d0b2c1c:__props.bgColor}));let emit$1=__emit,props=__props,assetURL=computed(()=>props.src?getAssetURL(props.src):props.externalSrc);return(_ctx,_cache)=>__props.span||__props.mask?(openBlock(),createElementBlock(`span`,{key:0,class:`bng-image-asset`,style:normalizeStyle({[__props.mask?`maskImage`:`backgroundImage`]:`url(${assetURL.value})`})},[renderSlot(_ctx.$slots,`default`,{},void 0,!0)],4)):(openBlock(),createElementBlock(`img`,{key:1,class:`bng-image-asset`,src:assetURL.value,alt:``,onError:_cache[0]||=$event=>emit$1(`error`,$event),onLoad:_cache[1]||=$event=>emit$1(`load`,$event)},null,40,_hoisted_1$321))}},bngImageAsset_default=__plugin_vue_export_helper_default(_sfc_main$366,[[`__scopeId`,`data-v-27bf5bcc`]]),_hoisted_1$320={class:`bng-image-carousel`},_sfc_main$365={__name:`bngImageCarousel`,props:{images:{type:Array,required:!0},external:Boolean,current:[String,Number],transition:Boolean,transitionType:{type:String,default:`fade`},transitionTime:{type:Number,default:3e3},loop:{type:Boolean,default:!0},showNav:{type:Boolean,default:!0},parent:Object},setup(__props,{expose:__expose}){let props=__props,carousel=ref();__expose({carousel});let imageAssets=computed(()=>props.external?props.images.map(x=>`/`+x):props.images.map(getAssetURL)),carouselSettings=computed(()=>props.parent&&props.parent.carousel!==carousel?{parent:props.parent.carousel,transition:!1,transitionType:props.transitionType,loop:!1,transitionTime:props.transitionTime}:{current:props.current,transition:props.transition,transitionType:props.transitionType,transitionTime:props.transitionTime,loop:props.loop,showNav:props.showNav});return(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$320,[createVNode(unref(carousel_default),mergeProps({items:imageAssets.value,ref_key:`carousel`,ref:carousel},carouselSettings.value),{item:withCtx(({item})=>[createBaseVNode(`div`,{class:`image-slide`,style:normalizeStyle({"background-image":`url(${item})`})},null,4)]),_:1},16,[`items`])]))}},bngImageCarousel_default=__plugin_vue_export_helper_default(_sfc_main$365,[[`__scopeId`,`data-v-6b0c2d6b`]]),_hoisted_1$319=[`src`],_sfc_main$364={__name:`bngImageTile`,props:{oldIcon:String,src:String,externalSrc:String,label:String,image:String,externalImage:String,icon:[Object,String],ratio:{type:String,default:`4:3`}},setup(__props){let props=__props,slots=useSlots(),assetURL=computed(()=>props.externalSrc?props.externalSrc:getAssetURL(props.src));return(_ctx,_cache)=>(openBlock(),createBlock(unref(bngTile_default),{label:__props.label,backgroundImage:__props.image,backgroundExternalImage:__props.externalImage,ratio:__props.ratio},createSlots({default:withCtx(()=>[__props.oldIcon?(openBlock(),createBlock(unref(bngOldIcon_default),{key:0,class:`icon`,type:__props.oldIcon,span:``},null,8,[`type`])):createCommentVNode(``,!0),__props.icon?(openBlock(),createBlock(unref(bngIcon_default),{key:1,class:`glyph`,type:__props.icon},null,8,[`type`])):__props.src||__props.externalSrc?(openBlock(),createElementBlock(`img`,{key:2,class:`icon`,src:assetURL.value},null,8,_hoisted_1$319)):createCommentVNode(``,!0)]),_:2},[unref(slots).default?{name:`label`,fn:withCtx(()=>[renderSlot(_ctx.$slots,`default`,{},void 0,!0)]),key:`0`}:void 0]),1032,[`label`,`backgroundImage`,`backgroundExternalImage`,`ratio`]))}},bngImageTile_default=__plugin_vue_export_helper_default(_sfc_main$364,[[`__scopeId`,`data-v-d74a4ec4`]]),UNIQUE_CLEAN_VALUE=Symbol(`Unique 'clean' value from Dirty service code`);function useDirty(valueRef,emitter=void 0,setCallback=void 0){if(!valueRef)throw Error(`valueRef must be specified`);let hasInitValue=!1,initialValue=ref();function init$3(val){let type=typeof val;type===`undefined`||type===`number`&&isNaN(val)||(hasInitValue=!0,initialValue.value=val)}if(init$3(valueRef.value),!hasInitValue){let unwatch=watch(valueRef,newVal=>{init$3(newVal),hasInitValue&&unwatch()});onUnmounted(()=>!hasInitValue&&unwatch())}let dirty=computed(()=>{let isDirty$1=valueRef.value!==initialValue.value;return isDirty$1&&hasInitValue&&emitter&&emitter(`dirtied`,valueRef.value,initialValue.value),isDirty$1}),setDirty=state=>{let oldVal=initialValue.value,newVal=state?UNIQUE_CLEAN_VALUE:valueRef.value;initialValue.value=newVal,typeof setCallback==`function`&&setCallback(newVal,oldVal)};return{dirty,currentCleanValue:computed(()=>initialValue.value),setCleanValue:val=>initialValue.value=val,resetValue:()=>valueRef.value=initialValue.value,setDirty,markClean:()=>setDirty(!1)}}var _hoisted_1$318={class:`bng-input-wrapper`},_hoisted_2$259={class:`icons-input-wrapper`},_hoisted_3$226={class:`bng-input-container`},_hoisted_4$194={key:0,class:`prefix-suffix-container`},_hoisted_5$164={"data-testid":`prefix`},_hoisted_6$141={class:`bng-input-group`},_hoisted_7$123=[`value`,`type`,`min`,`max`,`step`,`maxlength`,`placeholder`,`disabled`,`readonly`],_hoisted_8$101={key:0,class:`number-actions`},_hoisted_9$91={key:1,class:`floating-label`,"data-testid":`floating-label`},_hoisted_10$79={key:2,class:`error-message`},_hoisted_11$71={key:1,class:`prefix-suffix-container`},_hoisted_12$59={"data-testid":`suffix`},_hoisted_13$51={key:2,class:`trailing-icon`},_sfc_main$363={__name:`bngInput`,props:{modelValue:[String,Number],type:{type:String,default:`text`,validator(value){return[`text`,`number`].includes(value)}},min:[Number,String],max:[Number,String],step:{type:[Number,String],default:1},decimals:Number,maxlength:[Number,String],readonly:Boolean,floatingLabel:String,externalLabel:String,placeholder:String,initialValue:String,leadingIcon:Object,prefix:String,suffix:String,trailingIcon:Object,trailingIconOutside:Boolean,disabled:Boolean,validate:Function,errorMessage:String},emits:[`update:modelValue`,`valueChanged`,`change`,`focus`,`blur`],setup(__props,{expose:__expose,emit:__emit}){let props=__props,emitter=__emit,input=ref(),value=ref(props.initialValue||props.modelValue),isInputFieldFocused=ref(!1),numMin=computed(()=>props.type===`number`?+props.min:null),numMax=computed(()=>props.type===`number`?+props.max:null),numStep=computed(()=>props.type===`number`?roundDec(+props.step,15):null),numDecimals=computed(()=>props.type===`number`?props.decimals:null),charMax=computed(()=>props.type===`text`?props.maxlength:null),hasValue=computed(()=>value.value!==``&&value.value!==void 0&&value.value!==null),hasError=computed(()=>typeof props.validate==`function`?!props.validate(value.value):!1);if(props.type===`number`){let type=typeof value.value;type===`string`&&/^\d+(?:\.?\d+)?$/.test(value.value)?value.value=+value.value:type!==`number`&&(value.value=0),numMin.value>numMax.value&&console.error(`BngInput: min cannot be greater than max`)}__expose(useDirty(value));let lastNotify;function notify(val){props.readonly||lastNotify===val||(lastNotify=val,emitter(`update:modelValue`,val),emitter(`valueChanged`,val),emitter(`change`,val))}watch(()=>props.modelValue,newVal=>{props.type===`number`&&(newVal=numClamp(newVal)),value.value=newVal,lastNotify=newVal},{immediate:!0});function numClamp(val){return isNaN(val)&&(val=0),typeof numDecimals.value==`number`&&!isNaN(numDecimals.value)?val=roundDec(val,numDecimals.value):typeof numStep.value==`number`&&!isNaN(numStep.value)&&(val=roundDecSample(val,numStep.value)),typeof numMin.value==`number`&&!isNaN(numMin.value)&&valnumMax.value&&(val=numMax.value),val}function increment(by){let val=numClamp(+value.value+by);value.value!==val&&(value.value=val,input.value=val,notify(val))}let onArrowUpClicked=()=>increment(numStep.value),onArrowDownClicked=()=>increment(-numStep.value);function onValueChanged($event){let val=$event.target.value;if(props.type===`number`){val=+val;let prev=val;val=numClamp(val),val!==prev&&(input.value=val)}value.value=val,notify(val)}function onInputFieldFocusIn(){isInputFieldFocused.value=!0,emitter(`focus`)}function onInputFieldFocusOut(){isInputFieldFocused.value=!1,emitter(`blur`),notify(value.value)}return(_ctx,_cache)=>withDirectives((openBlock(),createElementBlock(`div`,_hoisted_1$318,[__props.externalLabel?(openBlock(),createElementBlock(`span`,{key:0,class:`external-label`,style:normalizeStyle([__props.leadingIcon?{"margin-left":`3em`}:{}]),"data-testid":`external-label`},toDisplayString(__props.externalLabel),5)):createCommentVNode(``,!0),createBaseVNode(`div`,_hoisted_2$259,[__props.leadingIcon?(openBlock(),createBlock(unref(bngIcon_default),{key:0,class:`outside-icon`,type:__props.leadingIcon,"data-testid":`leading-icon`},null,8,[`type`])):createCommentVNode(``,!0),createBaseVNode(`div`,{tabindex:`disabled ? -1 : 0`,class:normalizeClass([`bng-highlight-container`,{"bng-input-focused":isInputFieldFocused.value,"has-error":hasError.value}]),onKeydown:withKeys(onInputFieldFocusOut,[`enter`])},[createBaseVNode(`div`,_hoisted_3$226,[__props.prefix?(openBlock(),createElementBlock(`span`,_hoisted_4$194,[createBaseVNode(`span`,_hoisted_5$164,toDisplayString(__props.prefix),1)])):createCommentVNode(``,!0),createBaseVNode(`div`,_hoisted_6$141,[withDirectives(createBaseVNode(`input`,{ref_key:`input`,ref:input,class:normalizeClass([`bng-input`,{"bng-input-empty":!hasValue.value,"bng-input-error":hasError.value}]),"data-testid":`input`,value:value.value,type:__props.type,min:numMin.value,max:numMax.value,step:numStep.value,maxlength:charMax.value,onInput:onValueChanged,onFocusin:onInputFieldFocusIn,onFocusout:onInputFieldFocusOut,placeholder:__props.placeholder,disabled:__props.disabled,readonly:__props.readonly},null,42,_hoisted_7$123),[[unref(BngTextInput_default)]]),__props.type===`number`?(openBlock(),createElementBlock(`div`,_hoisted_8$101,[withDirectives(createVNode(unref(bngIcon_default),{type:unref(iconsByTag).arrow.arrowLargeUp,class:normalizeClass([{"number-action-disabled":__props.readonly},`number-action up-action`])},null,8,[`type`,`class`]),[[unref(BngClick_default),{clickCallback:onArrowUpClicked,holdCallback:onArrowUpClicked}]]),withDirectives(createVNode(unref(bngIcon_default),{type:unref(iconsByTag).arrow.arrowLargeDown,class:normalizeClass([`number-action down-action`,{"number-action-disabled":__props.readonly}])},null,8,[`type`,`class`]),[[unref(BngClick_default),{clickCallback:onArrowDownClicked,holdCallback:onArrowDownClicked}]])])):createCommentVNode(``,!0),__props.floatingLabel?(openBlock(),createElementBlock(`span`,_hoisted_9$91,toDisplayString(__props.floatingLabel),1)):createCommentVNode(``,!0),hasError.value&&__props.errorMessage?(openBlock(),createElementBlock(`span`,_hoisted_10$79,toDisplayString(__props.errorMessage),1)):createCommentVNode(``,!0),_cache[0]||=createBaseVNode(`span`,{class:`input-border`},null,-1)]),__props.suffix?(openBlock(),createElementBlock(`span`,_hoisted_11$71,[createBaseVNode(`span`,_hoisted_12$59,toDisplayString(__props.suffix),1)])):createCommentVNode(``,!0),__props.trailingIcon&&!__props.trailingIconOutside?(openBlock(),createElementBlock(`span`,_hoisted_13$51,[createVNode(unref(bngIcon_default),{type:__props.trailingIcon,class:`input-icon`,"data-testid":`trailing-icon`},null,8,[`type`])])):createCommentVNode(``,!0)])],34),__props.trailingIcon&&__props.trailingIconOutside?(openBlock(),createBlock(unref(bngIcon_default),{key:1,type:__props.trailingIcon,class:`outside-icon`,"data-testid":`external-trailing-icon`},null,8,[`type`])):createCommentVNode(``,!0)])])),[[unref(BngDisabled_default),__props.disabled]])}},bngInput_default=__plugin_vue_export_helper_default(_sfc_main$363,[[`__scopeId`,`data-v-d6c70b5c`]]),_hoisted_1$317=[`readonly`,`disabled`,`placeholder`,`maxlength`],_hoisted_2$258={key:0,class:`floating-label`},_hoisted_3$225={key:7,class:`external-button`},_hoisted_4$193={key:8,class:`error-message`};const INPUT_TYPES={text:`text`,number:`number`},STEP_ICON_TYPES={arrowUpDown:`arrowUpDown`,arrowLeftRight:`arrowLeftRight`,plusMinus:`plusMinus`};var STEP_ICON_TYPES_MAP={[STEP_ICON_TYPES.arrowUpDown]:{up:`arrowSmallUp`,down:`arrowSmallDown`},[STEP_ICON_TYPES.arrowLeftRight]:{up:`arrowSmallRight`,down:`arrowSmallLeft`},[STEP_ICON_TYPES.plusMinus]:{up:`plus`,down:`minus`}},NUMBER_PATTERN=/^\d+(\.d+)?$/,NUMBER_INPUT_KEYS=/^[0-9\.\-]$/,ERROR_TYPES={invalidformat:`invalidformat`,outofrange:`outofrange`,required:`required`,custom:`custom`},ERROR_MESSAGES={[ERROR_TYPES.invalidformat]:`Invalid format`,[ERROR_TYPES.outofrange]:`Value must be between {min} and {max}`,[`${ERROR_TYPES.outofrange}-min`]:`Value must be greater than {min}`,[`${ERROR_TYPES.outofrange}-max`]:`Value must be less than {max}`,[ERROR_TYPES.required]:`Value is required`},ALLOW_DEFAULT_BEHAVIOR_KEYS=[`ArrowLeft`,`ArrowRight`,`ArrowUp`,`ArrowDown`,`Backspace`,`Delete`],NUMBER_INPUT_MODES={spinner:`spinner`,arrowKeys:`arrowKeys`,uinav:`uinav`},_sfc_main$362={__name:`bngInputNew`,props:{modelValue:{type:[Number,String],default:void 0},value:{type:[Number,String],default:void 0},type:{type:String,default:INPUT_TYPES.text,validator(value){return Object.keys(INPUT_TYPES).includes(value)}},showExternalButton:{type:Boolean,default:!0},floatingLabel:[Boolean,String],externalButtonFn:Function,externalLabel:String,label:String,prefix:String,suffix:String,leadingIcon:Object,trailingIcon:Object,maxLength:{type:[Number,String],default:null,validator(value){return value===null?!0:typeof parseInt(value)==`number`&&parseInt(value)>=0}},readonly:Boolean,disabled:Boolean,required:Boolean,placeholder:String,validate:Function,errorMessage:String,min:{type:Number,default:void 0},max:{type:Number,default:void 0},step:{type:Number,default:1},stepIconType:{type:String,default:STEP_ICON_TYPES.arrowUpDown,validator(value){return Object.keys(STEP_ICON_TYPES).includes(value)}},noStepBindings:Boolean},emits:[`update:modelValue`,`change`,`error`,`blur`,`focus`,`valueChanged`],setup(__props,{expose:__expose,emit:__emit}){let props=__props,emit$1=__emit,slots=useSlots(),{showIfController}=storeToRefs(controls_default()),input=ref(null),scopeActivated=ref(!1),rawValue=ref(null),validationState=ref(null),isProgrammaticChange=ref(!1),numberInputState=reactive({inputType:null,isUpActive:!1,isDownActive:!1}),value=computed({get:()=>props.modelValue,set:emitChange}),isEmptyRawValue=computed(()=>isEmpty(rawValue.value)),inputStyle=computed(()=>({"max-width":props.maxLength?`${props.maxLength}ch`:`initial`})),stepIcons=computed(()=>STEP_ICON_TYPES_MAP[props.stepIconType]),exposed=useDirty(value);exposed.scopeActivated=scopeActivated,__expose(exposed),watch(()=>rawValue.value,newValue=>{if(isProgrammaticChange.value){isProgrammaticChange.value=!1;return}let res=validate(newValue);validationState.value=res,rawValue.value!=props.modelValue&&(res.valid||res.error!==ERROR_TYPES.invalidformat)&&(value.value=res.value)}),watch(()=>props.modelValue,modelValue=>{modelValue!=rawValue.value&&(isProgrammaticChange.value=!0,rawValue.value=isEmpty(modelValue)?null:String(modelValue))},{immediate:!0}),watch(()=>props.value,()=>{props.modelValue===void 0&&props.value!=rawValue.value&&(isProgrammaticChange.value=!0,rawValue.value=props.value)},{immediate:!0}),onUnmounted(()=>{resetInputState.cancel()});let activateInput=()=>{props.disabled||props.readonly||nextTick(()=>input.value.focus())},canActivateScope=()=>!props.readonly&&!props.disabled,externalButtonFn=()=>{props.externalButtonFn?props.externalButtonFn():props.type===INPUT_TYPES.number?rawValue.value=props.min||0:rawValue.value=null,activateInput()};function onScopeActivated(event){scopeActivated.value=!0}function onScopeDeactivated(event){scopeActivated.value=!1,nextTick(()=>cleanValue())}let resetInputState=debounce(()=>{numberInputState.inputType=null,numberInputState.isUpActive=!1,numberInputState.isDownActive=!1},150);function onUINavChangeValue(dir){numberInputState.inputType&&numberInputState.inputType!==NUMBER_INPUT_MODES.uinav||(numberInputState.inputType=NUMBER_INPUT_MODES.uinav,updateNumValue(dir),resetInputState())}function onArrowKeysChangeValue(dir){numberInputState.inputType&&numberInputState.inputType!==NUMBER_INPUT_MODES.arrowKeys||(numberInputState.inputType=NUMBER_INPUT_MODES.arrowKeys,updateNumValue(dir),resetInputState())}function onSpinnerChangeValue(dir){numberInputState.inputType&&numberInputState.inputType!==NUMBER_INPUT_MODES.spinner||(numberInputState.inputType=NUMBER_INPUT_MODES.spinner,updateNumValue(dir),resetInputState())}function updateNumValue(dir){props.type!==INPUT_TYPES.number||props.disabled||props.readonly||(dir===1?(numberInputState.isUpActive=!0,changeNumValue(props.step)):(numberInputState.isDownActive=!0,changeNumValue(-props.step)))}function onEnterDown(event){event.preventDefault(),scopeActivated.value=!1}function onKeyDown(event){if(ALLOW_DEFAULT_BEHAVIOR_KEYS.includes(event.key))return;event.key===`Enter`&&event.preventDefault();let rawValueString=typeof rawValue.value!=`string`&&!isNullOrUndefined(rawValue.value)?rawValue.value.toString():rawValue.value;props.type===INPUT_TYPES.number&&(!NUMBER_INPUT_KEYS.test(event.key)||event.key===`.`&&(isNullOrUndefined(rawValueString)||rawValueString.includes(`.`))||event.key===`.`&&!NUMBER_PATTERN.test(rawValueString))&&event.preventDefault()}function changeNumValue(diff){if(props.type!==INPUT_TYPES.number)return;if(isEmpty(rawValue.value)){diff<0?rawValue.value=isNullOrUndefined(props.max)?0:props.max:rawValue.value=isNullOrUndefined(props.min)?0:props.min;return}let{valid,value:validatedValue,error}=validate(rawValue.value);if(!valid&&error!==ERROR_TYPES.outofrange){rawValue.value=0;return}let decimalTokens=props.step.toString().split(`.`),stepDecimalPlaces=decimalTokens.length>1?decimalTokens[1].length:0,newValue=Number((validatedValue+diff).toFixed(stepDecimalPlaces)),{valid:isValidRange}=validateRange(newValue);(isValidRange||diff<0&&newValue>=props.max||diff>0&&newValue<=props.min)&&(rawValue.value=newValue)}function cleanValue(){if(!isNullOrUndefined(rawValue.value)&&props.type===INPUT_TYPES.number){let rawValueString=typeof rawValue.value==`string`?rawValue.value:rawValue.value.toString();rawValueString.endsWith(`.`)&&(rawValue.value=rawValueString.slice(0,-1))}}function validate(value$1){let valid=!0,newValue=value$1,errorMessage=null;if(isEmpty(value$1)&&props.required)return{valid:!1,error:ERROR_TYPES.required};if(isEmpty(value$1)&&props.type===INPUT_TYPES.number)return{valid:!0,value:void 0};if(props.type===INPUT_TYPES.number&&typeof value$1==`string`&&(newValue=value$1.includes(`.`)?parseFloat(value$1):parseInt(value$1),isNaN(newValue)))return{valid:!1,error:ERROR_TYPES.invalidformat};if(props.type===INPUT_TYPES.number)return{...validateRange(newValue),value:newValue};if(props.validate){let res=props.validate(value$1);typeof res==`boolean`?(valid=res,errorMessage=props.errorMessage):typeof res==`object`&&(`valid`in res&&console.warn("`validate` function must return a boolean `valid` property. Ignoring validation result..."),valid=res.valid||!0,valid||(errorMessage=`errorMessage`in res?res.errorMessage:props.errorMessage))}return{valid,value:newValue,errorMessage}}function validateRange(value$1){let lessThanMin=props.min&&value$1props.max,valid=!0,errorMessage=null;return!isNullOrUndefined(props.min)&&!isNullOrUndefined(props.max)&&(lessThanMin||greaterThanMax)?(errorMessage=ERROR_MESSAGES[ERROR_TYPES.outofrange].replace(`{min}`,props.min).replace(`{max}`,props.max),valid=!1):lessThanMin?(errorMessage=ERROR_MESSAGES[`${ERROR_TYPES.outofrange}-min`].replace(`{min}`,props.min),valid=!1):greaterThanMax&&(errorMessage=ERROR_MESSAGES[`${ERROR_TYPES.outofrange}-max`].replace(`{max}`,props.max),valid=!1),{valid,error:valid?null:ERROR_TYPES.outofrange,errorMessage}}function isEmpty(val){return val==null||val===``}function isNullOrUndefined(val){return val==null}function emitChange(value$1){emit$1(`update:modelValue`,value$1),emit$1(`change`,value$1),emit$1(`valueChanged`,value$1)}return(_ctx,_cache)=>withDirectives((openBlock(),createElementBlock(`div`,{class:normalizeClass([{"has-value":!isEmptyRawValue.value,"bng-input-readonly":__props.readonly,"bng-input-invalid":validationState.value&&!validationState.value.valid},`bng-input`]),onActivate:onScopeActivated,onDeactivate:onScopeDeactivated},[(__props.label||__props.externalLabel||unref(slots).label)&&!__props.floatingLabel?(openBlock(),createElementBlock(`label`,{key:0,class:`external-label`,onClick:activateInput,onMousedown:_cache[0]||=withModifiers(()=>{},[`prevent`])},[renderSlot(_ctx.$slots,`label`,{},()=>[createTextVNode(toDisplayString(__props.label||__props.externalLabel),1)],!0)],32)):createCommentVNode(``,!0),__props.leadingIcon||unref(slots).leadingIcon?(openBlock(),createElementBlock(`span`,{key:1,class:`leading-icon`,onClick:activateInput,onMousedown:_cache[1]||=withModifiers(()=>{},[`prevent`])},[renderSlot(_ctx.$slots,`leading-icon`,{},()=>[createVNode(unref(bngIcon_default),{type:__props.leadingIcon},null,8,[`type`])],!0)],32)):createCommentVNode(``,!0),__props.type===INPUT_TYPES.number&&!__props.readonly&&!__props.disabled?(openBlock(),createElementBlock(`span`,{key:2,class:normalizeClass([{"spinner-active":numberInputState.isDownActive},`input-spinner input-spinner-down`]),onMousedown:_cache[2]||=withModifiers(()=>{},[`prevent`])},[renderSlot(_ctx.$slots,`spinner-down`,{changeValue:()=>onSpinnerChangeValue(-1)},()=>[withDirectives((openBlock(),createBlock(unref(bngButton_default),{"bng-no-nav":`true`,accent:`text`},{default:withCtx(()=>[__props.noStepBindings?createCommentVNode(``,!0):(openBlock(),createBlock(unref(bngBinding_default),{key:0,controller:``,uiEvent:`focus_d`})),!unref(showIfController)||__props.noStepBindings?(openBlock(),createBlock(unref(bngIcon_default),{key:1,type:stepIcons.value.down},null,8,[`type`])):createCommentVNode(``,!0)]),_:1})),[[unref(BngClick_default),{clickCallback:()=>onSpinnerChangeValue(-1),holdCallback:()=>onSpinnerChangeValue(-1)}]])],!0)],34)):createCommentVNode(``,!0),__props.prefix||unref(slots).prefix?(openBlock(),createElementBlock(`span`,{key:3,class:`prefix`,onClick:activateInput,onMousedown:_cache[3]||=withModifiers(()=>{},[`prevent`])},[renderSlot(_ctx.$slots,`prefix`,{},()=>[createTextVNode(toDisplayString(__props.prefix),1)],!0)],32)):createCommentVNode(``,!0),createBaseVNode(`div`,{class:`input-container`,style:normalizeStyle(inputStyle.value)},[withDirectives(createBaseVNode(`input`,{ref_key:`input`,ref:input,"onUpdate:modelValue":_cache[4]||=$event=>rawValue.value=$event,readonly:__props.readonly,disabled:__props.disabled,placeholder:__props.placeholder,maxlength:__props.maxLength,type:`text`,onFocusin:_cache[5]||=$event=>_ctx.$emit(`focus`),onFocusout:_cache[6]||=$event=>_ctx.$emit(`blur`),onKeydown:[_cache[7]||=withKeys($event=>onArrowKeysChangeValue(1),[`arrow-up`]),_cache[8]||=withKeys($event=>onArrowKeysChangeValue(-1),[`arrow-down`]),withKeys(onEnterDown,[`enter`]),onKeyDown]},null,40,_hoisted_1$317),[[unref(BngTextInput_default)],[unref(BngOnUiNavFocus_default),dir=>onUINavChangeValue(dir),`vertical`,{repeat:!0}],[vModelText,rawValue.value]]),__props.label&&__props.floatingLabel||typeof __props.floatingLabel==`string`||unref(slots).label?(openBlock(),createElementBlock(`label`,_hoisted_2$258,[renderSlot(_ctx.$slots,`label`,{},()=>[createTextVNode(toDisplayString(__props.label||__props.floatingLabel),1)],!0)])):createCommentVNode(``,!0)],4),__props.suffix||unref(slots).suffix?(openBlock(),createElementBlock(`span`,{key:4,class:`suffix`,onClick:activateInput,onMousedown:_cache[9]||=withModifiers(()=>{},[`prevent`])},[renderSlot(_ctx.$slots,`suffix`,{},()=>[createTextVNode(toDisplayString(__props.suffix),1)],!0)],32)):createCommentVNode(``,!0),__props.trailingIcon||unref(slots).trailingIcon?(openBlock(),createElementBlock(`span`,{key:5,class:`trailing-icon`,onClick:activateInput,onMousedown:_cache[10]||=withModifiers(()=>{},[`prevent`])},[renderSlot(_ctx.$slots,`trailing-icon`,{},()=>[createVNode(unref(bngIcon_default),{type:__props.trailingIcon},null,8,[`type`])],!0)],32)):createCommentVNode(``,!0),__props.type===INPUT_TYPES.number&&!__props.readonly&&!__props.disabled?(openBlock(),createElementBlock(`span`,{key:6,class:normalizeClass([{"spinner-active":numberInputState.isUpActive},`input-spinner input-spinner-up`]),onMousedown:_cache[11]||=withModifiers(()=>{},[`prevent`])},[renderSlot(_ctx.$slots,`spinner-up`,{changeValue:()=>onSpinnerChangeValue(1)},()=>[withDirectives((openBlock(),createBlock(unref(bngButton_default),{"bng-no-nav":`true`,accent:`text`},{default:withCtx(()=>[__props.noStepBindings?createCommentVNode(``,!0):(openBlock(),createBlock(unref(bngBinding_default),{key:0,controller:``,uiEvent:`focus_u`})),!unref(showIfController)||__props.noStepBindings?(openBlock(),createBlock(unref(bngIcon_default),{key:1,type:stepIcons.value.up},null,8,[`type`])):createCommentVNode(``,!0)]),_:1})),[[unref(BngClick_default),{clickCallback:()=>onSpinnerChangeValue(1),holdCallback:()=>onSpinnerChangeValue(1)}]])],!0)],34)):createCommentVNode(``,!0),__props.showExternalButton?(openBlock(),createElementBlock(`span`,_hoisted_3$225,[renderSlot(_ctx.$slots,`external-button`,{externalButtonFn},()=>[__props.readonly?createCommentVNode(``,!0):withDirectives((openBlock(),createBlock(unref(bngButton_default),{key:0,icon:unref(icons).mathMultiply,disabled:__props.disabled,accent:`attention`,onClick:externalButtonFn,onMousedown:_cache[12]||=withModifiers(()=>{},[`prevent`])},null,8,[`icon`,`disabled`])),[[unref(BngOnUiNav_default),void 0,`ok`,{asMouse:!0,focusRequired:!0}],[unref(BngDisabled_default),isEmptyRawValue.value]])],!0)])):createCommentVNode(``,!0),validationState.value&&!validationState.value.valid&&validationState.value.errorMessage||unref(slots).errorMessage?(openBlock(),createElementBlock(`span`,_hoisted_4$193,[renderSlot(_ctx.$slots,`error-message`,{},()=>[createTextVNode(toDisplayString(validationState.value.errorMessage),1)],!0)])):createCommentVNode(``,!0)],34)),[[unref(BngDisabled_default),__props.disabled],[unref(BngScopedNav_default),{activated:scopeActivated.value,canActivate:canActivateScope}]])}},bngInputNew_default=__plugin_vue_export_helper_default(_sfc_main$362,[[`__scopeId`,`data-v-bb1297d5`]]),_hoisted_1$316={class:`list-container`},_hoisted_2$257={key:0,class:`list-toolbar`},_hoisted_3$224={key:1},_hoisted_4$192={class:`list-layout-toggle`};const LIST_LAYOUTS={DEFAULT:`tiles`,TILES:`tiles`,LIST:`list`,RIBBON:`ribbon`};var _sfc_main$361={__name:`bngList`,props:{path:Array,pathLimit:{type:[Number,String],default:3},pathTarget:Object,layoutSelector:Boolean,layoutSelectorTarget:Object,layout:{type:String,default:LIST_LAYOUTS.DEFAULT,validator:val=>Object.values(LIST_LAYOUTS).includes(val)},big:Boolean,immediate:Boolean,keepAlive:[Boolean,Number],tileSizeCalc:Function,tileWidth:Number,tileHeight:Number,tileMargin:Number,targetWidth:Number,targetHeight:Number,targetMargin:Number,titleWidth:Number,titleHeight:Number,titleMargin:Number,targetTitleWidth:Number,targetTitleHeight:Number,targetTitleMargin:Number,noBackground:Boolean},emits:[`layoutChange`,`pathClick`],setup(__props,{expose:__expose,emit:__emit}){let emit$1=__emit,props=__props,elPath=ref();__expose({navBack(){elPath.value&&elPath.value.navBack()},navTo(item){elPath.value&&elPath.value.navTo(item)},async scrollToIndex(index=0){if(!bigmode.enabled){let hasPosObserver=(elCont.value.children||[])[0]?.classList.contains(`bng-pos-observer`),elm=(elCont.value.children||[])[index+(hasPosObserver?1:0)];return elm&&elm.scrollIntoView(),elm}let big=await getBigProps(void 0,index);if(!big)return null;let horizontal=layoutSelected.value===LIST_LAYOUTS.RIBBON,containerSize=horizontal?contWidth:contHeight,rowIndex=layoutCache.itemToRow.get(index),itemRowPos=layoutCache.rows[rowIndex]?.pos||big.position,itemRowSize=layoutCache.rows[rowIndex]?.size||(horizontal?tileWidth.value:tileHeight.value),centeredPos=itemRowPos-containerSize/2+itemRowSize/2;scrollPos.value=Math.max(0,centeredPos),horizontal?elCont.value.scrollLeft=scrollPos.value:elCont.value.scrollTop=scrollPos.value,await updSkeleton();let itm=items$2.value[index];return itm?itm.getElement?.()||itm.el||itm:null},refresh(){tileWidth.value=0,tileHeight.value=0,titleWidth.value=0,titleHeight.value=0,tileProps=getItemProps(items$2.value,!1),titleProps=getItemProps(items$2.value,!0),tileProps&&(tileMargin.value=validNum(tileProps.margin)?tileProps.margin:defTileMargin*fontSize,calcTiles()),titleProps&&(titleMargin.value=validNum(titleProps.margin)?titleProps.margin:defTitleMargin*fontSize,calcTitles()),invalidateLayoutCache(),nextTick(()=>{bigmode.enabled&&contWidth>0&&contHeight>0&&(buildLayoutCache(),calcBig(),updSkeleton())})}});let defFontSize=16,defTileWidth=10,defTileHeight=5,defTileMargin=.2,defTitleWidth=10,defTitleHeight=2.5,defTitleMargin=.2,layoutSelected=ref(props.layout);watch(()=>props.layout,()=>layoutSelected.value=props.layout||LIST_LAYOUTS.DEFAULT),watch(()=>layoutSelected.value,val=>{emit$1(`layoutChange`,val),invalidateLayoutCache(),updSize()});let toolbar=computed(()=>{let res={path:props.path&&props.path.length>0,layout:props.layoutSelector};return res.enabled=res.path||res.layout,res.show=res.enabled&&(res.path&&!props.pathTarget||res.layout&&!props.layoutSelectorTarget),res}),slots=useSlots(),elCont=ref(),elSize=ref(),elSkeleton=ref(),tileWidth=ref(0),tileHeight=ref(0),tileMargin=ref(0),titleWidth=ref(0),titleHeight=ref(0),titleMargin=ref(0),scrollPos=ref(0),skeletonItems=ref([]),processing=computed(()=>bigmode.enabled&&(bigmode.initial||layoutCache.building)),contWidth=0,contHeight=0,fontSize=16,skeletonShown=!1,warnShown=!1,listItemsStyle=computed(()=>bigmode.enabled?{transform:`translate${layoutSelected.value===LIST_LAYOUTS.RIBBON?`X`:`Y`}(${bigmode.position}px)`}:void 0),tileProps=null,titleProps=null,bigmode=reactive({enabled:!1,initial:!0,debounce:500,skeleton:!0,layouts:[],getPos:{[LIST_LAYOUTS.TILES]:()=>elCont.value?.scrollTop||0,[LIST_LAYOUTS.LIST]:()=>elCont.value?.scrollTop||0,[LIST_LAYOUTS.RIBBON]:()=>elCont.value?.scrollLeft||0},overflow:2,skeletonOverflow:2,first:0,last:0,perRow:1,items:[],position:0,full:0,size:0});bigmode.layouts=Object.keys(bigmode.getPos);let layoutCache=reactive({version:0,building:!1,valid:!1,itemCount:0,totalSize:0,rows:[],itemToRow:new Map,rowPositions:[]}),items$2=ref([]),itemsView=ref([]),itemsShown=ref(new Set);watch(()=>props.immediate,val=>{val?(bigmode._skeleton=bigmode.skeleton,bigmode._debounce=bigmode.debounce,bigmode.skeleton=!1,bigmode.debounce=0):(bigmode._skeleton&&(bigmode.skeleton=bigmode._skeleton),bigmode._debounce&&(bigmode.debounce=bigmode._debounce))},{immediate:!0}),watch([()=>slots.default?.(),()=>props.big,()=>layoutSelected.value],()=>{let res=slots.default?slots.default():[];bigmode.enabled=props.big&&bigmode.layouts.includes(layoutSelected.value),bigmode.enabled&&(bigmode.initial=!0,res=getItems(res)),res=res.map((item,key)=>({...item,key})),items$2.value=res,bigmode.enabled||(itemsView.value=res),itemsShown.value.clear(),nextTick(()=>{tileProps=getItemProps(res,!1),titleProps=getItemProps(res,!0),invalidateLayoutCache(),updSize(),updSkeleton()})},{immediate:!0});function getItems(vnodes,_level=0){let res=[];for(let vnode of vnodes)switch(typeof vnode.type){case`object`:{let isTitle=vnode.props&&`bng-list-title`in vnode.props,item={...vnode};isTitle&&(item.isBngListTitle=!0),res.push(item);break}case`symbol`:if(_level===20)return logger_default.debug(`BngList reached max level of nested Vue fragments`),[];res.push(...getItems(vnode.children,_level+1));break}return res}function findItem(vnode,_level=0){let res=null;switch(typeof vnode.type){case`object`:res={el:vnode.el,width:vnode.type.width,height:vnode.type.height,margin:vnode.type.margin};break;case`string`:vnode.el instanceof HTMLElement&&(res={el:vnode.el});break;case`symbol`:if(vnode.children.length>0){if(_level===20)return null;res=findItem(vnode.children[0],++_level)}break}return res}function getItemProps(vnodes,title=!1){if(vnodes.length===0)return null;let sampleItem=vnodes.find(vnode=>title&&vnode.isBngListTitle||!title&&!vnode.isBngListTitle);if(!sampleItem)return null;let res=findItem(sampleItem);if(!res)return null;let valid={width:validNum(res.width),height:validNum(res.height),margin:validNum(res.margin)},fontSize$1,targetWidth=0,targetHeight=0,targetMargin=0;if(!title&&props.tileSizeCalc)try{fontSize$1||=getFontSize();let size$3=props.tileSizeCalc({contWidth,contHeight,fontSize:fontSize$1,layout:layoutSelected.value});if(size$3&&typeof size$3==`object`){let isPx=size$3.unit===`px`;targetWidth=isPx?size$3.width/fontSize$1:size$3.width,targetHeight=isPx?size$3.height/fontSize$1:size$3.height,targetMargin=isPx?size$3.margin/fontSize$1:size$3.margin}}catch(err){logger_default.warn(`BngList: tileSizeCalc function error:`,err)}targetWidth||=title?props.titleWidth||props.targetTitleWidth:props.tileWidth||props.targetWidth,targetHeight||=title?props.titleHeight||props.targetTitleHeight:props.tileHeight||props.targetHeight,targetMargin||=title?props.titleMargin||props.targetTitleMargin:props.tileMargin||props.targetMargin,validNum(targetWidth)&&(res.width=targetWidth,valid.width=!0),validNum(targetHeight)&&(res.height=targetHeight,valid.height=!0),validNum(targetMargin)&&(res.margin=targetMargin,valid.margin=!0);let em2px=em=>(fontSize$1||=getFontSize(),em*fontSize$1);if(valid.width&&res.width&&(res.width=em2px(res.width)),valid.height&&res.height&&(res.height=em2px(res.height)),valid.margin&&res.margin&&(res.margin=em2px(res.margin)),!valid.width||bigmode.enabled&&!valid.height||!valid.margin){if(res.el instanceof HTMLElement){let style=window.getComputedStyle(res.el,null);valid.width||(res.width=+style.width.substring(0,style.width.length-2)),valid.height||(res.height=+style.height.substring(0,style.height.length-2)),valid.margin||(res.margin=[style.marginTop,style.marginRight,style.marginBottom,style.marginLeft].map(m=>+m.substring(0,m.length-2)).sort((a$1,b)=>b-a$1)[0])}else logger_default.warn(`BngList cannot access ${title?`title`:`tile`} element for size auto-detection!`);warnShown||(warnShown=!0,logger_default.debug(`BigList was not provided with ${title?`title`:`target`} sizes (from props or from ${title?`title`:`tile`} component export) and attempted to auto-detect them. This may lead to some size micro-adjustments visible to user or invalid sizes. Please specify ${title?`title`:`target`} sizes manually.`),(res.width<1||res.height<1)&&logger_default.debug(`BigList noticed a detected ${title?`title`:``} size being too low: width = ${res.width}, height = ${res.height}`))}return res}let validNum=num=>typeof num==`number`&&!isNaN(num),getFontSize=()=>{if(!elCont.value)return 16;let size$3=window.getComputedStyle(elCont.value,null).fontSize;return+size$3.substring(0,size$3.length-2)||16},resizeObserver=new ResizeObserver(updSize);onMounted(()=>nextTick(()=>{resizeObserver.observe(elSize.value)})),onBeforeUnmount(()=>{elSize.value&&resizeObserver.unobserve(elSize.value),resizeObserver.disconnect()});let scrolling=ref(!1),scrollTmr,scrollTick=!1,onScrollDebounce=async()=>{scrollPos.value=bigmode.getPos[layoutSelected.value](),await updSkeleton()};watch(scrollPos,async pos=>{if(bigmode.enabled)if(bigmode.debounce>0)clearTimeout(scrollTmr),scrolling.value=!0,scrollTmr=setTimeout(async()=>{scrolling.value=!1,await calcBig(pos),await updSkeleton()},bigmode.debounce);else{if(scrollTick)return;scrollTick=!0,requestAnimationFrame(async()=>{scrollTick=!1,await calcBig(pos),await updSkeleton()})}});function vScroll(evt){evt.deltaY!==0&&elCont.value.scrollBy({left:evt.deltaY,behavior:`instant`})}function updSize(entries=[]){let oldContWidth=contWidth,oldContHeight=contHeight;tileWidth.value=0,tileHeight.value=0,titleWidth.value=0,titleHeight.value=0,tileProps?(tileMargin.value=validNum(tileProps.margin)?tileProps.margin:defTileMargin*fontSize,calcTiles(entries)):tileMargin.value=0,titleProps?(titleMargin.value=validNum(titleProps.margin)?titleProps.margin:defTitleMargin*fontSize,calcTitles(entries)):titleMargin.value=0,(Math.abs(oldContWidth-contWidth)>1||Math.abs(oldContHeight-contHeight)>1)&&invalidateLayoutCache(),bigmode.enabled&&!layoutCache.valid&&contWidth>0&&contHeight>0&&(!titleProps||titleWidth.value>0&&titleHeight.value>0)&&buildLayoutCache(),bigmode.enabled&&bigmode.initial&&(tileProps||titleProps)&&nextTick(async()=>{await calcBig(),await updSkeleton(),setTimeout(async()=>{await calcBig(),await updSkeleton()},50)}),elCont.value.removeEventListener(`mousewheel`,vScroll),layoutSelected.value===LIST_LAYOUTS.RIBBON&&elCont.value.addEventListener(`mousewheel`,vScroll)}function calcSizes(entries=[]){if(contWidth=0,contHeight=0,!elSize.value||!bigmode.enabled&&layoutSelected.value!==LIST_LAYOUTS.TILES)return!1;let baseMargin=tileMargin.value,rect=entries[0]?.contentRect||elSize.value.getBoundingClientRect();if(fontSize=getFontSize(),contWidth=rect.width,layoutSelected.value===LIST_LAYOUTS.RIBBON){let tileHeight$1=(tileProps?.height||5*fontSize)+baseMargin,titleHeight$1=titleProps?(titleProps.height||defTitleHeight*fontSize)+(titleProps.margin||defTitleMargin*fontSize):0;contHeight=Math.max(tileHeight$1,titleHeight$1)}else contHeight=rect.height-baseMargin;return!0}function calcTiles(entries=[]){if(!calcSizes(entries))return;let wantsWidth=layoutSelected.value===LIST_LAYOUTS.TILES||bigmode.enabled&&layoutSelected.value===LIST_LAYOUTS.RIBBON,wantsHeight=bigmode.enabled;if(!wantsWidth&&!wantsHeight)return;let baseMargin=tileMargin.value;if(wantsWidth){let baseWidth=tileProps.width||10*fontSize;if(contWidth>0&&layoutSelected.value===LIST_LAYOUTS.TILES){let prepWidth=baseWidth+baseMargin,amount=contWidth/prepWidth;amount<2?tileWidth.value=contWidth-baseMargin:tileWidth.value=(contWidth-baseMargin)/~~amount-baseMargin}else tileWidth.value=baseWidth}wantsHeight&&(tileHeight.value=tileProps.height||5*fontSize),bigmode.enabled&&bigmode.initial&&((!wantsWidth||contWidth>0)&&(!wantsHeight||contHeight>0)?(bigmode.initial=!1,calcBig(),updSkeleton()):window.requestAnimationFrame(()=>calcTiles()))}function calcTitles(){if(bigmode.enabled&&(fontSize=getFontSize()),!titleProps)return;let baseMargin=titleMargin.value,baseHeight=titleProps.height||defTitleHeight*fontSize;layoutSelected.value===LIST_LAYOUTS.RIBBON?titleWidth.value=titleProps.width||10*fontSize:titleWidth.value=contWidth-baseMargin;let oldTitleHeight=titleHeight.value;titleHeight.value=baseHeight,bigmode.enabled&&oldTitleHeight===0&&titleHeight.value>0&&contWidth>0&&contHeight>0&&(invalidateLayoutCache(),buildLayoutCache())}function clearLayoutCache(){layoutCache.totalSize=0,layoutCache.rows=[],layoutCache.itemToRow.clear(),layoutCache.rowPositions=[],layoutCache.valid=!0,layoutCache.building=!1,bigmode.enabled&&(bigmode.initial=!1,bigmode.full=0,bigmode.position=0,itemsView.value=[])}async function buildLayoutCache(){if(layoutCache.building){for(;layoutCache.building;)await sleep(10);return}if(items$2.value.length===0){clearLayoutCache();return}if(!tileProps&&!titleProps||contWidth<=0||contHeight<=0)return;if(layoutCache.building=!0,layoutCache.version=Date.now(),layoutCache.itemCount=items$2.value.length,await sleep(0),layoutCache.rows=[],layoutCache.itemToRow.clear(),layoutCache.rowPositions=[],layoutCache.itemCount!==items$2.value.length&&(layoutCache.itemCount=0),layoutCache.itemCount===0){clearLayoutCache(),items$2.value.length>0&&buildLayoutCache();return}let baseTileMargin=tileProps?.margin||defTileMargin*fontSize,baseTitleMargin=titleProps?.margin||defTitleMargin*fontSize,horizontal=layoutSelected.value===LIST_LAYOUTS.RIBBON,tilesPerRow=layoutSelected.value===LIST_LAYOUTS.TILES?~~(contWidth/tileWidth.value):1,pos=0,first=0,curItems=0;function completeRow(i){let tileSize=horizontal?tileWidth.value:tileHeight.value,size$3=tileSize+baseTileMargin,row={pos,size:size$3,first,last:i-1};layoutCache.rows.push(row),layoutCache.rowPositions.push(pos);for(let j=first;j0&&(completeRow(i),curItems=0);let titleSize=horizontal?titleWidth.value:titleHeight.value,rowSize=titleSize+baseTitleMargin,row={pos,size:rowSize,first:i,last:i,isTitle:!0};layoutCache.rows.push(row),layoutCache.rowPositions.push(pos),layoutCache.itemToRow.set(i,layoutCache.rows.length-1);let nextMargin=items$2.value[i+1]?.isBngListTitle?baseTitleMargin:baseTileMargin;pos+=titleSize+nextMargin,first=i+1,curItems=0}else if(curItems++,curItems===1&&(first=i),curItems>=tilesPerRow){let tileSize=horizontal?tileWidth.value:tileHeight.value,size$3=tileSize+baseTileMargin,row={pos,size:size$3,first,last:i};layoutCache.rows.push(row),layoutCache.rowPositions.push(pos);for(let j=first;j<=i;j++)layoutCache.itemToRow.set(j,layoutCache.rows.length-1);let nextMargin=items$2.value[i+1]?.isBngListTitle?baseTitleMargin:baseTileMargin;pos+=tileSize+nextMargin,curItems=0,first=i+1}curItems>0&&completeRow(layoutCache.itemCount),pos+=items$2.value[layoutCache.itemCount-1]?.isBngListTitle?baseTitleMargin:baseTileMargin,layoutCache.totalSize=pos,layoutCache.valid=!0,layoutCache.building=!1}function invalidateLayoutCache(){layoutCache.valid=!1,layoutCache.version++}function layoutCacheSearch(arr,target){let left=0,right=arr.length-1;for(;left<=right;){let mid=~~((left+right)/2);arr[mid]<=target?left=mid+1:right=mid-1}return Math.max(0,right)}async function getBigProps(pos=void 0,index=void 0,overflow=void 0){let count$1=items$2.value.length;if(count$1===0)return;if((!layoutCache.valid||layoutCache.itemCount!==count$1)&&(await buildLayoutCache(),!layoutCache.valid))return null;(typeof index!=`number`||index<0)&&(index=void 0,typeof pos!=`number`&&(pos=bigmode.getPos[layoutSelected.value]()));let contSize=layoutSelected.value===LIST_LAYOUTS.RIBBON?contWidth:contHeight;typeof overflow!=`number`&&(overflow=bigmode.overflow);let overflowBefore=Math.ceil(overflow/2),overflowAfter=Math.floor(overflow/2),firstRow=0,currentPos=0;if(typeof index==`number`&&index>=0){let rowIndex=layoutCache.itemToRow.get(index);rowIndex!==void 0&&(firstRow=rowIndex,currentPos=layoutCache.rows[rowIndex].pos,pos=currentPos)}else firstRow=layoutCacheSearch(layoutCache.rowPositions,pos),currentPos=layoutCache.rows[firstRow]?.pos||0;let extendedFirstRow=firstRow,backwardCount=0;for(let i=firstRow-1;i>=0&&backwardCount=contSize));i++);let overflowCount=0;for(let i=lastRow+1;iprops.keepAlive){let center=big.first+(big.last-big.first)/2,farthest=Array.from(itemsShown.value).sort((a$1,b)=>Math.abs(b-center)-Math.abs(a$1-center)).slice(0,itemsShown.value.size-props.keepAlive);for(let idx of farthest)itemsShown.value.delete(idx)}big.items=Array.from(itemsShown.value).sort((a$1,b)=>a$1-b).map(idx=>{let item=items$2.value[idx];return idx>=big.first&&idx<=big.last?item:{...item,keepAliveStyle:`display: none !important;`}})}else itemsShown.value.size>0&&itemsShown.value.clear();bigmode.items=big.items,itemsView.value=big.items}}function showSkeleton(show=!0){skeletonShown!==show&&(show?elSkeleton.value.style.removeProperty(`display`):(skeletonItems.value=[],elSkeleton.value.style.setProperty(`display`,`none`,`important`)),skeletonShown=show)}async function updSkeleton(){if(!elSkeleton.value||!bigmode.enabled||!bigmode.skeleton||!scrolling.value||items$2.value.length===0||!layoutCache.valid){showSkeleton(!1);return}if(bigmode.first===0&&bigmode.last===items$2.value.length-1){showSkeleton(!1);return}let horizontal=layoutSelected.value===LIST_LAYOUTS.RIBBON,contSize=horizontal?contWidth:contHeight,pos=scrollPos.value,start,end;if(pos=bigmode.position||(end=i,visibleSize+=row.size,visibleSize>=contSize))break}let overflowCount=0;for(let i=end+1;i=bigmode.position);i++)end=i,overflowCount++;let neededSize=contSize+bigmode.skeletonOverflow*(horizontal?tileWidth.value:tileHeight.value),backwardSize=visibleSize;for(;start>0&&backwardSize=contSize));i++);let overflowCount=0;for(let i=end+1;i(openBlock(),createElementBlock(`div`,_hoisted_1$316,[toolbar.value.enabled?withDirectives((openBlock(),createElementBlock(`div`,_hoisted_2$257,[toolbar.value.path?(openBlock(),createBlock(Teleport,{key:0,disabled:!__props.pathTarget,to:__props.pathTarget},[createVNode(unref(bngBreadcrumbs_default),{ref_key:`elPath`,ref:elPath,items:__props.path,limit:__props.pathLimit,blur:!__props.noBackground,onClick:_cache[0]||=itm=>emit$1(`pathClick`,itm)},null,8,[`items`,`limit`,`blur`])],8,[`disabled`,`to`])):(openBlock(),createElementBlock(`div`,_hoisted_3$224)),toolbar.value.layout?(openBlock(),createBlock(Teleport,{key:2,disabled:!__props.layoutSelectorTarget,to:__props.layoutSelectorTarget},[createBaseVNode(`div`,_hoisted_4$192,[createVNode(unref(bngButton_default),{accent:layoutSelected.value===LIST_LAYOUTS.TILES?unref(ACCENTS).outlined:unref(ACCENTS).text,icon:unref(icons).tiles,onClick:_cache[1]||=$event=>layoutSelected.value=LIST_LAYOUTS.TILES},null,8,[`accent`,`icon`]),createVNode(unref(bngButton_default),{accent:layoutSelected.value===LIST_LAYOUTS.LIST?unref(ACCENTS).outlined:unref(ACCENTS).text,icon:unref(icons).listSmall,onClick:_cache[2]||=$event=>layoutSelected.value=LIST_LAYOUTS.LIST},null,8,[`accent`,`icon`])])],8,[`disabled`,`to`])):createCommentVNode(``,!0)],512)),[[vShow,toolbar.value.show]]):createCommentVNode(``,!0),withDirectives((openBlock(),createElementBlock(`div`,{ref_key:`elCont`,ref:elCont,class:normalizeClass({"list-content":!0,"list-with-background":!__props.noBackground,[`list-layout-${layoutSelected.value}`]:!0,"list-item-width":!!tileWidth.value,"list-item-height":!!tileHeight.value,"list-item-margin":!!tileMargin.value,"list-title-width":!!titleWidth.value,"list-title-height":!!titleHeight.value,"list-title-margin":!!titleMargin.value,"list-big":bigmode.enabled,"list-scrolling":scrolling.value||bigmode.debounce===0,"list-processing":processing.value}),style:normalizeStyle({"--list-item-width":`${tileWidth.value}px`,"--list-item-height":`${tileHeight.value}px`,"--list-item-margin":`${tileMargin.value}px`,"--list-title-width":`${titleWidth.value}px`,"--list-title-height":`${titleHeight.value}px`,"--list-title-margin":`${titleMargin.value}px`,"--list-big-full":`${bigmode.full}px`}),onScroll:onScrollDebounce},[createBaseVNode(`div`,{ref_key:`elSize`,ref:elSize,class:`list-content-size-observer`},null,512),bigmode.enabled&&bigmode.skeleton?(openBlock(),createElementBlock(`div`,{key:0,ref_key:`elSkeleton`,ref:elSkeleton,class:`list-skeleton`},[(openBlock(!0),createElementBlock(Fragment,null,renderList(skeletonItems.value,(isTitle,i)=>(openBlock(),createElementBlock(`div`,{key:`skeleton-${i}`,class:normalizeClass({"skeleton-item":!0,"skeleton-title":isTitle})},null,2))),128))],512)):createCommentVNode(``,!0),createBaseVNode(`div`,{class:`list-items`,style:normalizeStyle(listItemsStyle.value)},[(openBlock(!0),createElementBlock(Fragment,null,renderList(itemsView.value,vnode=>(openBlock(),createBlock(resolveDynamicComponent(vnode),{key:vnode.key,style:normalizeStyle(vnode.keepAliveStyle)},null,8,[`style`]))),128))],4)],38)),[[unref(BngBlur_default),!__props.noBackground]])]))}},bngList_default=__plugin_vue_export_helper_default(_sfc_main$361,[[`__scopeId`,`data-v-5af5eff2`]]),_hoisted_1$315={class:`bng-stars`},_hoisted_2$256={key:0,class:`stars`},_hoisted_3$223=[`innerHTML`],_hoisted_4$191=[`innerHTML`],_hoisted_5$163={key:1,class:`stars`},_hoisted_6$140={class:`stars-label`},_hoisted_7$122=[`innerHTML`],_sfc_main$360={__name:`bngMainStars`,props:{unlockedStars:{type:Number,default:0,validator:val=>val>=0},totalStars:{type:Number,default:1},scale:{type:Number,default:1},individualStars:{type:Object,default:null,validator:val=>val===null||Array.isArray(val)},numerical:{type:Boolean,default:!1}},setup(__props){useCssVars(_ctx=>({v3c930dd6:fontSize.value}));let props=__props,fontSize=computed(()=>`${props.scale}rem`),starsTotal=computed(()=>props.individualStars?props.individualStars.length:props.totalStars),starsFilled=computed(()=>props.individualStars?props.individualStars.filter(Boolean).length:props.unlockedStars),starsUnfilled=computed(()=>starsTotal.value-starsFilled.value),glyphsFilled=computed(()=>starsFilled.value>0?icons.star.glyph.repeat(starsFilled.value):``),glyphsUnfilled=computed(()=>starsUnfilled.value>0?icons.star.glyph.repeat(starsUnfilled.value):``);return(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$315,[!__props.numerical&&__props.individualStars&&__props.individualStars.length?(openBlock(),createElementBlock(`div`,_hoisted_2$256,[starsFilled.value?(openBlock(),createElementBlock(`span`,{key:0,class:`star star-filled`,innerHTML:glyphsFilled.value},null,8,_hoisted_3$223)):createCommentVNode(``,!0),starsUnfilled.value?(openBlock(),createElementBlock(`span`,{key:1,class:`star star-unfilled`,innerHTML:glyphsUnfilled.value},null,8,_hoisted_4$191)):createCommentVNode(``,!0)])):(openBlock(),createElementBlock(`div`,_hoisted_5$163,[createBaseVNode(`div`,_hoisted_6$140,toDisplayString(starsFilled.value)+` / `+toDisplayString(starsTotal.value),1),createBaseVNode(`span`,{class:`star star-filled`,innerHTML:unref(icons).star.glyph},null,8,_hoisted_7$122)]))]))}},bngMainStars_default=__plugin_vue_export_helper_default(_sfc_main$360,[[`__scopeId`,`data-v-4ba4c794`]]),_hoisted_1$314=[`rows`,`placeholder`,`disabled`],_hoisted_2$255={key:0,class:`floating-label`},_sfc_main$359={__name:`bngMultilineInput`,props:{floatingLabel:String,externalLabel:String,placeholder:String,initialValue:String,leadingIcon:Object,trailingIcon:Object,scalable:Boolean,hasError:Boolean,errorMessage:String,lines:{type:Number,default:1},disabled:{type:Boolean,default:!1}},setup(__props){useCssVars(_ctx=>({v26daab40:bngScalableInputMaxWidth.value}));let props=__props,inputContainer=ref(null),bngMultilineInput=ref(null),focusHighlight=ref(null),leadingIconContainer=ref(null),trailingIconContainer=ref(null),value=ref(``),isInputFieldFocused=ref(!1),hasValue=computed(()=>value.value!==``&&value.value!==void 0),bngScalableInputMaxWidth=computed(()=>`${(leadingIconContainer.value?leadingIconContainer.value.offsetWidth:0)+(trailingIconContainer.value?trailingIconContainer.value.offsetWidth:0)}px`),resizeObserver;onBeforeMount(()=>{value.value=props.initialValue,resizeObserver=new ResizeObserver(onInputResize)}),onMounted(()=>{resizeObserver.observe(bngMultilineInput.value)}),onDeactivated(()=>{resizeObserver.disconnect()});function onInputFieldFocusIn(){isInputFieldFocused.value=!0}function onInputFieldFocusOut(){isInputFieldFocused.value=!1}function onInputResize(){inputContainer.value&&window.requestAnimationFrame(()=>{let focusRight=inputContainer.value.offsetWidth-inputContainer.value.offsetWidth;focusHighlight.value.style.right=`${focusRight-2}px`})}return(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,{class:normalizeClass([`input-icon-wrapper`,{scalable:__props.scalable}])},[__props.leadingIcon?(openBlock(),createElementBlock(`span`,{key:0,ref_key:`leadingIconContainer`,ref:leadingIconContainer,class:`input-icon`},[createVNode(unref(bngIcon_default),{type:__props.leadingIcon},null,8,[`type`])],512)):createCommentVNode(``,!0),createBaseVNode(`div`,{ref_key:`inputContainer`,ref:inputContainer,class:normalizeClass([`bng-multiline-input`,{"input-focused":isInputFieldFocused.value,"has-error":__props.hasError}]),tabindex:`0`},[withDirectives(createBaseVNode(`textarea`,{"onUpdate:modelValue":_cache[0]||=$event=>value.value=$event,ref_key:`bngMultilineInput`,ref:bngMultilineInput,class:normalizeClass([`input-field`,{empty:!hasValue.value,"has-value":hasValue.value,"has-error":__props.hasError,disabled:__props.disabled}]),rows:__props.lines,placeholder:__props.floatingLabel,disabled:__props.disabled,onFocusin:onInputFieldFocusIn,onFocusout:onInputFieldFocusOut},null,42,_hoisted_1$314),[[vModelText,value.value],[unref(BngTextInput_default)]]),__props.floatingLabel?(openBlock(),createElementBlock(`span`,_hoisted_2$255,toDisplayString(__props.floatingLabel),1)):createCommentVNode(``,!0),createBaseVNode(`span`,{ref_key:`focusHighlight`,ref:focusHighlight,class:`focus-highlight`},null,512)],2),__props.trailingIcon?(openBlock(),createElementBlock(`span`,{key:1,ref_key:`trailingIconContainer`,ref:trailingIconContainer,class:`input-icon`},[createVNode(unref(bngIcon_default),{type:__props.trailingIcon},null,8,[`type`])],512)):createCommentVNode(``,!0)],2))}},bngMultilineInput_default=__plugin_vue_export_helper_default(_sfc_main$359,[[`__scopeId`,`data-v-6c6cfdb8`]]);const icons$1={undefined:`undefined`,arrow:{large:{up:`arrow/large_up`,down:`arrow/large_down`,left:`arrow/large_left`,right:`arrow/large_right`},small:{up:`arrow/arrowSmallUp`,down:`arrow/arrowSmallDown`,left:`arrow/arrowSmallLeft`,right:`arrow/arrowSmallRight`}},drive:{autobahn:`drive/autobahn`,busroutes:`drive/busroutes`,campaigns:`drive/campaigns`,career:`drive/career`,freeroam:`drive/freeroam`,garage:`drive/garage`,infinity:`drive/infinity`,lightrunner:`drive/lightrunner`,m_a:`drive/m_a`,m_b:`drive/m_b`,m_c:`drive/m_c`,play:`drive/play`,quit:`drive/quit`,scenarios:`drive/scenarios`,timetrials:`drive/timetrials`},general:{offbtn:`general/offbtn`,unknown:`general/unknown`,check:`general/check`,recharge:`general/recharge`,refuel:`general/refuel`,beambuck:`general/beambuck`,money:`general/beambuck`,beamXP:`general/beamXP`,arrow_small_left:`general/arrow_small-left`,arrow_small_right:`general/arrow_small-right`,fuel_nozzle:`general/fuel-nozzle`,recharge_connector:`general/recharge-connector`,star:`general/star`,star_outlined:`general/star-secondary`,vehicle:`general/vehicle`,awd:`general/awd`,"4wd":`general/4wd`,fwd:`general/fwd`,rwd:`general/rwd`,drivetrain_special:`general/drivetrain-special`,drivetrain_generic:`general/drivetrain-generic`,charge:`general/charge`,fuel:`general/fuel`,odometer:`general/odometer`,power_gauge_01:`general/power-gauge-01c`,power_gauge_02:`general/power-gauge-02c`,power_gauge_03:`general/power-gauge-03c`,power_gauge_04:`general/power-gauge-04c`,power_gauge_05:`general/power-gauge-05c`,weight:`general/weight`,transmission_a:`general/transmission-a`,transmission_m:`general/transmission-m`},device:{keyboard:`device/keyboard`,phone_android:`device/phone_android`,wheel:`device/wheel`,gamepad:`device/gamepad`,videogame_asset:`device/videogame_asset`,mouse:{button0:`device/mouse/button0`,button1:`device/mouse/button1`,button2:`device/mouse/button2`,xaxis:`device/mouse/xaxis`,yaxis:`device/mouse/yaxis`,zaxis:`device/mouse/zaxis`},xbox:{btn_a:`device/xbox/btn_a`,btn_b:`device/xbox/btn_b`,btn_back:`device/xbox/btn_back`,btn_lb:`device/xbox/btn_lb`,btn_lt:`device/xbox/btn_lt`,btn_rb:`device/xbox/btn_rb`,btn_rt:`device/xbox/btn_rt`,btn_start:`device/xbox/btn_start`,btn_x:`device/xbox/btn_x`,btn_y:`device/xbox/btn_y`,btn_dpad_default_filled:`device/xbox/btn_dpad_default_filled`,btn_dpad_default_outline:`device/xbox/btn_dpad_default_outline`,btn_dpad_down:`device/xbox/btn_dpad_down`,btn_dpad_left:`device/xbox/btn_dpad_left`,btn_dpad_right:`device/xbox/btn_dpad_right`,btn_dpad_up:`device/xbox/btn_dpad_up`,btn_thumb_left:`device/xbox/btn_thumb_left`,btn_thumb_left_x:`device/xbox/btn_thumb_left_x`,btn_thumb_left_y:`device/xbox/btn_thumb_left_y`,btn_thumb_right:`device/xbox/btn_thumb_right`,btn_thumb_right_x:`device/xbox/btn_thumb_right_x`,btn_thumb_right_y:`device/xbox/btn_thumb_right_y`}},decals:{camera:{back:`decals/camera/back`,freecam:`decals/camera/freecam`,front:`decals/camera/front`,left:`decals/camera/left`,right:`decals/camera/right`,top:`decals/camera/top`},general:{change_order:`decals/general/change_order`,deform:`decals/general/deform`,delete:`decals/general/delete`,duplicate:`decals/general/duplicate`,hide:`decals/general/hide`,lock:`decals/general/lock`,mirror:`decals/general/mirror`,options:`decals/general/options`,redo:`decals/general/redo`,rename:`decals/general/rename`,save:`decals/general/save`,transform:`decals/general/transform`,undo:`decals/general/undo`,unlock:`decals/general/unlock`,use_mask:`decals/general/mask`},group:{group:`decals/group/group`,ungroup:`decals/group/ungroup`},layer:{decal:`decals/layer/decal`,material:`decals/layer/material`},mirror:{copy_mirrored:`decals/mirror/copy_mirrored`,copy_straight:`decals/mirror/copy_straight`}}},iconTypesList=makeIconTypesList(icons$1);function makeIconTypesList(dict){let key,all=[];for(key in dict)all=all.concat(typeof dict[key]==`string`?dict[key]:makeIconTypesList(dict[key]));return all}var _hoisted_1$313=[`src`],_sfc_main$358={__name:`bngOldIcon`,props:{type:{type:String,validator:v=>iconTypesList.includes(v)},span:{type:Boolean,default:!0},mask:{type:Boolean,default:!0},color:String},setup(__props){let props=__props,iconImageURL=computed(()=>getAssetURL(`icons/${props.type}.svg`)),spanStyle=computed(()=>({[props.mask?`maskImage`:`backgroundImage`]:`url(${iconImageURL.value})`,backgroundColor:props.color||`#fff`}));return(_ctx,_cache)=>__props.span?(openBlock(),createElementBlock(`span`,{key:0,class:`bngicon`,style:normalizeStyle(spanStyle.value)},[renderSlot(_ctx.$slots,`default`,{},void 0,!0)],4)):(openBlock(),createElementBlock(`img`,{key:1,class:`bngicon`,src:iconImageURL.value,alt:``},null,8,_hoisted_1$313))}},bngOldIcon_default=__plugin_vue_export_helper_default(_sfc_main$358,[[`__scopeId`,`data-v-da0e0a74`]]),_hoisted_1$312=[`bng-no-child-nav`],scrollBuildupTime=3e3,scrollMaxSpeedModifier=4,CLICKID=`__bngOverflowContainer`,_sfc_main$357={__name:`bngOverflowContainer`,props:{scrollSpeed:{type:Number,default:5},initialIndex:{type:Number,default:-1},useBindings:[Boolean,Array],useBindingsOnly:[Boolean,Array],showBindings:{type:Boolean,default:!0},showArrows:{type:Boolean,default:!1},noWheel:{type:Boolean,default:!1}},setup(__props,{expose:__expose}){let slots=useSlots(),props=__props,useBindings=props.useBindings||props.useBindingsOnly,useBindingsOnly=props.useBindingsOnly;watch([()=>props.useBindings,()=>props.useBindingsOnly],()=>console.warn(`useBindings and useBindingsOnly can only be set at component mount time`));let uinavBound=!1,focusNav=useBindings&&Array.isArray(useBindings)?useBindings:[`tab_l`,`tab_r`],elBindPrev=ref(null),elBindNext=ref(null),elCont=ref(null),scrollContainer=ref(null),showLeftFade=ref(!1),showRightFade=ref(!1),resizeObserver=new ResizeObserver(updateFadeVisibility),scrollInterval=null,scrollTime=0,lastActive=null,fixingActive=!1;function setActive(elm){clearActive(),elm instanceof Element&&(elm.setAttribute(`active`,`true`),lastActive=elm)}function clearActive(evt){lastActive&&(evt&&(evt.detail?.target||evt.target)===lastActive||(lastActive.removeAttribute(`active`),lastActive=null))}function fixActive(evt){if(fixingActive||useBindings&&evt.type===`focusin`)return;let active=evt.detail?.target||evt.target||document.activeElement;if(active.matches(`[is-bng-panel], [bng-nav-item], [ng-click], [href], [bng-all-clicks], [bng-all-clicks-no-nav], [ui-sref], input, textarea, button, md-option, md-slider, md-select, md-checkbox`)||(active=active.closest(NAVIGABLE_ELEMENTS_SELECTOR)),scrollContainer.value.contains(active)&&!(lastActive&&(lastActive===active||lastActive.contains(active)))){if(useBindingsOnly){fixingActive=!0;let prev=evt.detail.relatedTarget||evt.relatedTarget;prev&&scrollContainer.value.contains(prev)&&(prev=null),prev?setFocusExternal(prev,!0):setFocusExternal(active,!1)}nextTick(()=>{setActive(active),fixingActive=!1})}}let firstTime=!0;function updateContents(){if(!scrollContainer.value)return;let elFirst;for(let elm of scrollContainer.value.children)firstTime&&!elFirst&&(elFirst=elm),!elm[CLICKID]&&(elm[CLICKID]=!0,elm.addEventListener(`click`,fixActive));firstTime&&elFirst&&props.initialIndex>-1&&(firstTime=!1,elFirst.matches(`[is-bng-panel], [bng-nav-item], [ng-click], [href], [bng-all-clicks], [bng-all-clicks-no-nav], [ui-sref], input, textarea, button, md-option, md-slider, md-select, md-checkbox`)||(elFirst=elFirst.querySelector(NAVIGABLE_ELEMENTS_SELECTOR)),elFirst&&activate(elFirst))}watch([()=>slots.default?.(),()=>scrollContainer.value],()=>nextTick(updateContents),{immediate:!0});function navContents(dir,fireClick=!1){let links=collectRects(dir,scrollContainer.value,useBindingsOnly),prev=lastActive;clearActive();let res;if(useBindingsOnly){let idx=links[dir].findIndex(link=>link.dom===prev);idx>-1?res=links[dir][dir===`right`?idx+1:idx-1]:idx===0&&dir===`left`?res=links[dir][links[dir].length-1]:idx===links[dir].length-1&&dir===`right`&&(res=links[dir][0]),res&&(setActive(res.dom),scrollFix(res,dir))}else prev&&(res=navigate(links,dir,prev),res&&setActive(res));res?fireClick&&(res.dom&&(res=res.dom),nextTick(()=>res?.dispatchEvent(new Event(`click`)))):(scrollContainer.value.scrollTo({left:dir===`right`?0:scrollContainer.value.clientWidth,behavior:`instant`}),nextTick(()=>{let elms$4=collectRects(`right`,scrollContainer.value,!0).right;dir===`left`&&elms$4.reverse(),res=elms$4[0],res&&(setActive(res.dom),useBindingsOnly?scrollFix(res,dir):setFocusExternal(res.dom),fireClick&&res.dom.dispatchEvent(new Event(`click`)))}))}let activatePrev=()=>navContents(`left`,!0),activateNext=()=>navContents(`right`,!0);function activate(indexOrElement){let elm;if(typeof indexOrElement==`number`){let elms$4=scrollContainer.value.querySelectorAll(NAVIGABLE_ELEMENTS_SELECTOR);indexOrElement<0&&(indexOrElement=elms$4.length+indexOrElement),elm=elms$4[indexOrElement]}else if(indexOrElement instanceof Element)elm=indexOrElement;else throw Error(`Invalid argument`);if(!elm)throw Error(`Element not found`);scrollFix({dom:elm,rect:elm.getBoundingClientRect()},`right`),setActive(elm),!useBindingsOnly&&setFocusExternal(elm)}if(__expose({scrollBy:amount=>scrollContainer.value?.scrollBy({left:amount,behavior:`smooth`}),activatePrev,activateNext,activate,deactivate:()=>{let active=document.activeElement,activeCorrect=active&&active===lastActive;clearActive(),activeCorrect&&(useBindingsOnly&&setFocusExternal(active,!1),active.blur?.())},refresh:(withActivation=!1)=>{withActivation&&(firstTime=!0),updateContents()}}),useBindings){let instance$1=getCurrentInstance(),contUnwatch=watch(()=>elCont.value,elm=>{elm&&(contUnwatch(),nextTick(()=>{uinavBound=!0;let vnode={ctx:instance$1,el:elm};BngOnUiNav_default.mounted(elm,{arg:focusNav[0],modifiers:{},value:activatePrev},vnode),BngOnUiNav_default.mounted(elm,{arg:focusNav[1],modifiers:{},value:activateNext},vnode),elm.addEventListener(`focusin`,fixActive)}))},{immediate:!0})}watch(scrollContainer,elm=>{elm&&(updateFadeVisibility(),resizeObserver.observe(elm))},{immediate:!0});function updateFadeVisibility(){if(!scrollContainer.value)return;let{scrollLeft,scrollWidth,clientWidth}=scrollContainer.value;showLeftFade.value=scrollLeft>0,showRightFade.value=scrollLeft{let speedModifier=Math.min(1+(scrollMaxSpeedModifier-1)*(scrollTime/scrollBuildupTime),scrollMaxSpeedModifier),scrollAmount=(direction$1===`left`?-props.scrollSpeed:props.scrollSpeed)*speedModifier;scrollContainer.value.scrollLeft+=scrollAmount,updateFadeVisibility(),scrollTime+=1e3/30},1e3/30)}function stopScrolling(){scrollInterval&&=(clearInterval(scrollInterval),null),scrollTime=0}function onWheel(evt){props.noWheel||(evt.preventDefault(),scrollContainer.value.scrollLeft+=evt.deltaY,updateFadeVisibility())}function onScroll(){updateFadeVisibility()}return onBeforeUnmount(()=>{resizeObserver.disconnect(),stopScrolling(),uinavBound&&(BngOnUiNav_default.beforeUnmount(elCont.value),elCont.value.removeEventListener(`focusin`,fixActive))}),(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,{ref_key:`elCont`,ref:elCont,class:normalizeClass([`bng-overflow-container`,{"with-bindings":unref(useBindings)&&(elBindPrev.value?.displayed||elBindNext.value?.displayed),"with-arrows":__props.showArrows&&!(elBindPrev.value?.displayed||elBindNext.value?.displayed),"hide-bindings":!__props.showBindings}]),onWheel},[withDirectives(createBaseVNode(`div`,{class:`fade-left`,onMouseenter:_cache[0]||=$event=>startScrolling(`left`),onMouseleave:stopScrolling},null,544),[[vShow,showLeftFade.value]]),withDirectives(createBaseVNode(`div`,{class:`fade-right`,onMouseenter:_cache[1]||=$event=>startScrolling(`right`),onMouseleave:stopScrolling},null,544),[[vShow,showRightFade.value]]),__props.showArrows&&!elBindPrev.value?.displayed?(openBlock(),createBlock(unref(bngIcon_default),{key:0,type:unref(icons).arrowLargeLeft,class:`hint-prev`},null,8,[`type`])):createCommentVNode(``,!0),__props.showArrows&&!elBindNext.value?.displayed?(openBlock(),createBlock(unref(bngIcon_default),{key:1,type:unref(icons).arrowLargeRight,class:`hint-next`},null,8,[`type`])):createCommentVNode(``,!0),unref(useBindings)?(openBlock(),createBlock(unref(bngBinding_default),{key:2,ref_key:`elBindPrev`,ref:elBindPrev,class:`hint-prev`,"ui-event":unref(focusNav)[0],controller:``},null,8,[`ui-event`])):createCommentVNode(``,!0),unref(useBindings)?(openBlock(),createBlock(unref(bngBinding_default),{key:3,ref_key:`elBindNext`,ref:elBindNext,class:`hint-next`,"ui-event":unref(focusNav)[1],controller:``},null,8,[`ui-event`])):createCommentVNode(``,!0),createBaseVNode(`div`,{ref_key:`scrollContainer`,ref:scrollContainer,class:`scroll-container`,"bng-no-child-nav":unref(useBindingsOnly),onScroll},[renderSlot(_ctx.$slots,`default`,{},void 0,!0)],40,_hoisted_1$312)],34))}},bngOverflowContainer_default=__plugin_vue_export_helper_default(_sfc_main$357,[[`__scopeId`,`data-v-24544cbf`]]);const rainbow=(numOfSteps,step)=>{let r,g,b,h$1=step/numOfSteps,i=~~(h$1*6),f=h$1*6-i,q=1-f;switch(i%6){case 0:[r,g,b]=[1,f,0];break;case 1:[r,g,b]=[q,1,0];break;case 2:[r,g,b]=[0,1,f];break;case 3:[r,g,b]=[0,q,1];break;case 4:[r,g,b]=[f,0,1];break;case 5:[r,g,b]=[1,0,q];break}return[r,g,b]},hueToRGB=(p$1,q,t)=>(t<0&&(t+=1),t>1&&--t,t<1/6?p$1+(q-p$1)*6*t:t<1/2?q:t<2/3?p$1+(q-p$1)*(2/3-t)*6:p$1),HSLToRGB=(h$1,s,l)=>{let r,g,b;if(s===0)r=g=b=l;else{let q=l<.5?l*(1+s):l+s-l*s,p$1=2*l-q;r=hueToRGB(p$1,q,h$1+1/3),g=hueToRGB(p$1,q,h$1),b=hueToRGB(p$1,q,h$1-1/3)}return[r,g,b]},RGBToHSL=(r,g,b)=>{let vmax=Math.max(r,g,b),vmin=Math.min(r,g,b),h$1,s,l=(vmax+vmin)/2;if(vmax===vmin)return[0,0,l];let d=vmax-vmin;return s=l>.5?d/(2-vmax-vmin):d/(vmax+vmin),vmax===r&&(h$1=(g-b)/d+(gnum;else if(val<=15){let prec=10**val;this._precision=num=>~~(num*prec)/prec}else throw TypeError(`Precision can't go higher than 15`)}_sync({hsl=!1,rgb=!1}={}){if(hsl&&rgb)throw Error(`Cannot set both HSL and RGB changes at once`);this._dirty.hsl&&!hsl?this._rgb=HSLToRGB(...this._hsl):this._dirty.rgb&&!rgb&&(this._hsl=RGBToHSL(...this._rgb)),this._dirty.hsl=hsl,this._dirty.rgb=rgb}_parse(val){let res;if(isProxy(val)&&(val=toRaw(val)),typeof val==`string`&&(val=val.split(` `)),typeof val==`object`&&Array.isArray(val)){if(val.length<3)throw Error(`Invalid colour array length`);val.length===3&&(val=[...val,1]),val=val.map(Number);for(let num of val)if(isNaN(num))throw Error(`Values must be numbers`);res=val}if(!res)throw Error(`Color must be either an array or a string`);return res}get hslString(){return this.hsl.join(` `)}get hslaString(){return this.hsla.join(` `)}get rgbString(){return this.rgb.join(` `)}get rgbaString(){return this.rgba.join(` `)}get saturationPercent(){return Math.round(this.saturation*100)}get luminosityPercent(){return Math.round(this.luminosity*100)}get alphaPercent(){return Math.round(this._alpha*50)}get metallicPercent(){return Math.round(this._metallic*100)}get roughnessPercent(){return Math.round(this._roughness*100)}get clearcoatPercent(){return Math.round(this._clearcoat*100)}get clearcoatRoughnessPercent(){return Math.round(this._clearcoatRoughness*100)}get paint(){return[...this._legacy?this.rgba:this.rgb,this.metallic,this.roughness,this.clearcoat,this.clearcoatRoughness].map(this._precision)}get paintString(){return this.paint.join(` `)}get paintObject(){return this._paintObjectNames.reduce((res,name)=>({...res,[name]:this[name]}),{})}set paint(val){let data;if(isProxy(val)&&(val=toRaw(val)),typeof val==`object`){if(!Array.isArray(val)){data={...val};let names=this._paintObjectNames;for(let name of names){if(name===`baseColor`){this.baseColor=name in data?data[name]:[1,1,1,1];continue}let num=0;name in data&&(num=Number(data[name]),isNaN(num)&&(num=0)),this[name]=num}return}data=val}else if(typeof val==`string`)data=val.split(` `);else throw TypeError(`Invalid data type`);if(data.length===8)this.rgba=data.slice(0,4);else if(data.length===7)this.rgb=data.slice(0,3);else throw TypeError(`Invalid data value`);[this._metallic,this._roughness,this._clearcoat,this._clearcoatRoughness]=data.slice(-4)}get metallic(){return this._precision(this._metallic)}set metallic(val){this._metallic=Number(val)}get roughness(){return this._precision(this._roughness)}set roughness(val){this._roughness=Number(val)}get clearcoat(){return this._precision(this._clearcoat)}set clearcoat(val){this._clearcoat=Number(val)}get clearcoatRoughness(){return this._precision(this._clearcoatRoughness)}set clearcoatRoughness(val){this._clearcoatRoughness=Number(val)}get alpha(){return this._precision(this._alpha)}set alpha(val){let type=typeof val;type!==`undefined`&&(type===`number`?this._alpha=val:this._alpha=Number(val))}get hsl(){return this._sync(),this._hsl.map(this._precision)}set hsl(val){let arr=this._parse(val);this._sync({hsl:!0}),this._hsl=arr.slice(0,3),this.alpha=arr[3]}get rgb(){return this._sync(),this._rgb.map(this._precision)}get rgb255(){return this.rgb.map(val=>Math.round(val*255))}set rgb(val){let arr=this._parse(val);this._sync({rgb:!0}),this._rgb=arr.slice(0,3),this.alpha=arr[3]}set rgb255(val){let arr=this._parse(val);this.rgb=[...arr.slice(0,3).map(val$1=>val$1/255),arr[3]]}get hsla(){return[...this.hsl,this.alpha]}set hsla(val){this.hsl=val}get rgba(){return[...this.rgb,this.alpha]}set rgba(val){this.rgb=val}get baseColor(){return this.rgba}set baseColor(val){this.rgba=val}get hue(){return this.hsl[0]}get hue360(){return this.hsl[0]*360}set hue(val){this._sync({hsl:!0}),this._hsl[0]=Number(val)}set hue360(val){this.hue=Number(val)/360}get saturation(){return this.hsl[1]}set saturation(val){this._sync({hsl:!0}),this._hsl[1]=Number(val)}get luminosity(){return this.hsl[2]}set luminosity(val){this._sync({hsl:!0}),this._hsl[2]=Number(val)}get red(){return this.rgb[0]}get red255(){return this.rgb[0]*255}set red(val){this._sync({rgb:!0}),this._rgb[0]=Number(val)}set red255(val){this.red=Number(val)/255}get green(){return this.rgb[1]}get green255(){return this.rgb[1]*255}set green(val){this._sync({rgb:!0}),this._rgb[1]=Number(val)}set green255(val){this.green=Number(val)/255}get blue(){return this.rgb[2]}get blue255(){return this.rgb[2]*255}set blue(val){this._sync({rgb:!0}),this._rgb[2]=Number(val)}set blue255(val){this.blue=Number(val)/255}static anyToArray(val,legacy=!1){if(Array.isArray(val)){let checks=[val$1=>val$1 instanceof Paint,val$1=>typeof val$1==`object`&&Array.isArray(val$1.baseColor),val$1=>typeof val$1==`string`&&val$1.split(` `).length>=7,val$1=>Array.isArray(val$1)&&val$1.length>=7];if(val.some(item=>checks.some(check=>check(item))))return val.map(item=>Paint.anyToArray(item,legacy))}let precision=val$1=>{let num=Number(val$1);return isNaN(num)?val$1:~~(num*1e4)/1e4};return Array.isArray(val)?val.map(precision):typeof val==`string`?val.split(` `).map(precision):val instanceof Paint?val.paint:typeof val==`object`&&val.baseColor?[...legacy?val.baseColor:val.baseColor.slice(0,3),val.metallic,val.roughness,val.clearcoat,val.clearcoatRoughness].map(precision):val}static hslCssStr(arr){return`${Math.round(arr[0]*360)}, ${Math.round(arr[1]*100)}%, ${Math.round(arr[2]*100)}%`}static rgbToHsl(rgb){return RGBToHSL(...rgb)}static hslToRgb(hsl){return HSLToRGB(...hsl)}},CACHE_LIMIT=200,TILE_SIZE=64,MULTI_ANGLE=23,MAX_CONCURRENT_RENDERS=20,QUEUE_INTERVAL=10,reflectionImageUrl=`/ui/ui-vue/src/assets/images/paint-reflection.jpg`,reflectionImage=null,reflectionImageDone=!1,renderCancelledError=Error(`Render cancelled`),cacheCleanedError=Error(`Cache cleared`);function hashPaintData(paintData){return paintData?(paintData=Paint.anyToArray(paintData,!1),Array.isArray(paintData)?Array.isArray(paintData[0])?paintData.map(paint=>Array.isArray(paint)?paint.join(`,`):``).join(`|`):paintData.join(`,`):JSON.stringify(paintData)):``}var checkMultipaint=paintData=>Array.isArray(paintData)&&paintData.length>0&&paintData.some(item=>Array.isArray(item)&&item.length>=7);const usePaintPreviews=defineStore(`paint-previews`,()=>{let previews=ref(new Map),pendingRenders=ref(new Map),renderQueue=ref([]),activeRenders=ref(0),cacheListeners=new Set,pendingBlobCleanup=new Set,queueProcessor=null,blobCleanupTimeout=null;{let img=new Image;img.onload=()=>{reflectionImage=img,reflectionImageDone=!0},img.onerror=()=>{console.warn(`Failed to load metallic reflection image`),reflectionImageDone=!0},img.src=reflectionImageUrl}function startQueue(eager=!1){if(queueProcessor||renderQueue.value.length===0)return;let run$1=()=>{renderQueue.value.length===0?stopQueue():activeRenders.value0||activeRenders.value>0)return!1;for(let entry of previews.value.values())if(entry.blobGenerating)return!1;return!0}function blobCleanup(){blobCleanupTimeout&&clearTimeout(blobCleanupTimeout),blobCleanupTimeout=setTimeout(()=>{if(blobCleanupTimeout=null,isSystemIdle()&&pendingBlobCleanup.size>0){for(let blobUrl of pendingBlobCleanup)URL.revokeObjectURL(blobUrl);pendingBlobCleanup.clear()}},1e3)}async function processQueue({key,paintData,opts,resolve:resolve$1,reject,aborter}){activeRenders.value++;try{let checkAborted=()=>{if(aborter.signal.aborted)throw renderCancelledError};checkAborted();let width$1=opts.width||TILE_SIZE,height$1=opts.height||TILE_SIZE,areas=calculatePaintAreas(paintData,width$1,height$1),cvs=await renderPaint(paintData,width$1,height$1,opts.radialLight||!1,areas,aborter);checkAborted();let bmp=await createImageBitmap(cvs);if(previews.value.size>=CACHE_LIMIT){let oldestKey=previews.value.keys().next().value;cleanupCacheEntry(previews.value.get(oldestKey)),previews.value.delete(oldestKey)}checkAborted(),previews.value.set(key,{bitmap:bmp,paintData,paintHash:hashPaintData(paintData),areas}),resolve$1(bmp)}catch(err){err!==renderCancelledError&&reject(err)}finally{pendingRenders.value.has(key)&&pendingRenders.value.get(key).aborter===aborter&&pendingRenders.value.delete(key),activeRenders.value--}}function getCacheKey({paintId,vehicleName,paintName,width:width$1=TILE_SIZE,height:height$1=TILE_SIZE,radialLight=!1}){if(paintId)return`paint#${paintId}@${width$1}x${height$1}${radialLight?`R`:`L`}`;if(vehicleName&&paintName)return`vehicle:${vehicleName}:${paintName}@${width$1}x${height$1}${radialLight?`R`:`L`}`;throw Error(`Either paintId or vehicleName+paintName must be provided`)}function isCached(opts,paintData){try{let key=getCacheKey(opts),data=previews.value.get(key);return data?!paintData||data.paintHash===hashPaintData(paintData):!1}catch{return!1}}function getCachedPreview(opts,paintData){try{let key=getCacheKey(opts),data=previews.value.get(key);return data?data.paintHash===hashPaintData(paintData)?data.bitmap:(cleanupCacheEntry(data),previews.value.delete(key),null):null}catch{return null}}async function generatePreview(paintData,opts){let key=getCacheKey(opts),paintHash=hashPaintData(paintData);if(pendingRenders.value.has(key)){let existing=pendingRenders.value.get(key);if(existing.paintHash===paintHash)return new Promise((resolve$1,reject)=>existing.others.push({resolve:resolve$1,reject}));{existing.aborter.abort(),renderQueue.value=renderQueue.value.filter(item=>!(item.key===key&&item.aborter===existing.aborter));let aborter$1=new AbortController,others$1=[...existing.others];return pendingRenders.value.set(key,{paintHash,others:others$1,aborter:aborter$1}),new Promise((resolve$1,reject)=>{others$1.push({resolve:resolve$1,reject}),renderQueue.value.unshift({key,paintData:Paint.anyToArray(paintData),opts,resolve:result=>others$1.forEach(p$1=>p$1.resolve(result)),reject:error=>others$1.forEach(p$1=>p$1.reject(error)),aborter:aborter$1}),startQueue(!0)})}}let aborter=new AbortController,others=[];return pendingRenders.value.set(key,{paintHash,others,aborter}),new Promise((resolve$1,reject)=>{others.push({resolve:resolve$1,reject}),renderQueue.value.push({key,paintData:Paint.anyToArray(paintData),opts,resolve:result=>{others.forEach(p$1=>p$1.resolve(result))},reject:error=>{others.forEach(p$1=>p$1.reject(error))},aborter}),startQueue()})}function cleanupCacheEntry(data){data&&(data.bitmap?.close?.(),data.blobUrl&&pendingBlobCleanup.add(data.blobUrl))}function onCacheClear(callback){return cacheListeners.add(callback),()=>cacheListeners.delete(callback)}function notifyCacheCleared(type=`all`,key=null){cacheListeners.forEach(callback=>{try{callback(type,key)}catch(error){console.warn(`Cache clear listener error:`,error)}})}function clearCache(opts=void 0){if(opts)try{let key=getCacheKey(opts);if(cleanupCacheEntry(previews.value.get(key)),previews.value.delete(key),pendingRenders.value.has(key)){let req=pendingRenders.value.get(key);req.aborter.abort(),req.others.forEach(p$1=>p$1.reject(cacheCleanedError)),pendingRenders.value.delete(key)}notifyCacheCleared(`single`,key)}catch{}else stopQueue(),pendingRenders.value.forEach(req=>{req.aborter.abort(),req.others.forEach(p$1=>p$1.reject(cacheCleanedError))}),pendingRenders.value.clear(),previews.value.forEach(cleanupCacheEntry),previews.value.clear(),renderQueue.value.splice(0),activeRenders.value=0,notifyCacheCleared(`all`),startQueue();blobCleanup()}async function getPreview(paintData,opts){return getCachedPreview(opts,paintData)||await generatePreview(paintData,opts)}async function getBlobPreview(paintData,opts){let paintHash=hashPaintData(paintData),key=getCacheKey(opts),bmp=await getPreview(paintData,opts),data=previews.value.get(key);if(!data)return null;if(data.blobUrl&&data.paintHash===paintHash)return data.blobUrl;for(;data.blobGenerating;)await sleep(10);if(data.blobUrl&&data.paintHash===paintHash)return data.blobUrl;data.blobGenerating=!0;let canvas=new OffscreenCanvas(opts.width||TILE_SIZE,opts.height||TILE_SIZE);canvas.getContext(`2d`).drawImage(bmp,0,0);let blobUrl=URL.createObjectURL(await canvas.convertToBlob()),oldBlobUrl=data.blobUrl;return data.blobUrl=blobUrl,delete data.blobGenerating,oldBlobUrl&&pendingBlobCleanup.add(oldBlobUrl),previews.value.has(key)?(blobCleanup(),blobUrl):(pendingBlobCleanup.add(blobUrl),blobCleanup(),null)}function getAreas(opts){let data=previews.value.get(getCacheKey(opts));return data?data.areas:[]}return{cache:previews.value,cacheSize:computed(()=>previews.value.size),isRenderingAny:computed(()=>activeRenders.value>0||renderQueue.value.length>0),queueLength:computed(()=>renderQueue.value.length),activeRenders,isCached,clearCache,onCacheClear,getCacheKey,getPreview,getBlobPreview,getAreas,checkMultipaint,toArray:Paint.anyToArray}});async function renderPaint(paintData,width$1=TILE_SIZE,height$1=TILE_SIZE,radialLight=!1,areas=null,aborter=null){if(paintData=Paint.anyToArray(paintData),!paintData)return renderEmpty(width$1,height$1,aborter);if(checkMultipaint(paintData)){let clipData=areas||calculatePaintAreas(paintData,width$1,height$1);return renderMultipaint(paintData,width$1,height$1,clipData,radialLight,aborter)}else return paintData=Array.isArray(paintData[0])?paintData[0]:paintData,renderSinglePaint(paintData,width$1,height$1,radialLight,aborter)}function createPaint(paintData){let paint={_isEmpty:!0};if(!paintData)return paint;try{paint=new Paint({paint:paintData})}catch{}return paint}function applyAntialiasing(ctx){ctx.imageSmoothingEnabled=!0,ctx.imageSmoothingQuality=`high`,ctx.antialias=!0}function calculatePaintAreas(paintData,width$1,height$1){if(!paintData||!checkMultipaint(paintData))return[[0,0,width$1,height$1]];let paintCount=paintData.length,angle=Math.tan(MULTI_ANGLE*Math.PI/180),stripeWidth=(width$1+height$1*angle)/paintCount,overlap=.5,areas=[];for(let i=0;i0?overlap:0),topRight=startX+stripeWidth+(icoords.map((coord,i)=>coord*(i%2==0?scaleX:scaleY)));for(let i=0;igrad.addColorStop(...args))}else grad=ctx.createLinearGradient(0,0,0,height$1*.65),gradStops.forEach(args=>grad.addColorStop(...args));ctx.fillStyle=grad,ctx.fillRect(0,0,width$1,height$1),ctx.restore()}async function renderPaintLayers(ctx,paint,width$1,height$1,radialLight=!1,aborter=null){if(applyAntialiasing(ctx),ctx.fillStyle=`rgb(${(paint.rgb255||[255,255,255]).join(`, `)})`,ctx.fillRect(0,0,width$1,height$1),aborter?.signal.aborted)return;let grad=ctx.createLinearGradient(0,0,0,height$1);if(grad.addColorStop(0,`rgba(0, 0, 0, 0)`),grad.addColorStop(.65,`rgba(0, 0, 0, 0)`),grad.addColorStop(.8,`rgba(0, 0, 0, 0.15)`),grad.addColorStop(1,`rgba(0, 0, 0, 0.55)`),ctx.fillStyle=grad,ctx.fillRect(0,0,width$1,height$1),aborter?.signal.aborted)return;let metallic=Math.max(0,paint.metallic-paint.roughness/.5);if(metallic>.01){for(;!reflectionImageDone;){if(aborter?.signal.aborted)return;await sleep(10)}if(aborter?.signal.aborted)return;if(ctx.globalCompositeOperation=`multiply`,ctx.globalAlpha=metallic,reflectionImage){let scale=1,imageAspect=reflectionImage.width/reflectionImage.height,canvasAspect=width$1/height$1,drawWidth,drawHeight,offsetX=0,offsetY=0;imageAspect>canvasAspect?(drawHeight=height$1*1,drawWidth=height$1*imageAspect*1):(drawHeight=width$1/imageAspect*1,drawWidth=width$1*1),ctx.drawImage(reflectionImage,0,0,drawWidth,drawHeight)}else{ctx.strokeStyle=`rgba(255, 255, 255, 0.5)`,ctx.lineWidth=1;for(let x=-height$1;x({v889f200a:tileWidth.value,bee2d4dc:tileHeight.value}));let popover=usePopover(),props=__props,emit$1=__emit,mapId=uniqueId(`paint-tile-map`),menuId=uniqueId(`paint-tile-menu`),popMenu=ref(null),elCont=ref(null),elCanvas=ref(null),isLoading=ref(!1),isEmpty=ref(!1),hasRenderedOnce=ref(!1),paintPreviews=usePaintPreviews(),width$1=computed(()=>props.size||props.width),height$1=computed(()=>props.size||props.height),tileWidth=computed(()=>`${width$1.value}px`),tileHeight=computed(()=>`${height$1.value}px`),paints=computed(()=>props.paint?paintPreviews.toArray(props.paint):[]),isMultipaint=computed(()=>paintPreviews.checkMultipaint(paints.value)),paintNames=computed(()=>{let len=props.paint?.length||0;if(len===0)return[];let res=Array.from({length:len}).map((_,idx)=>({tooltip:[`ui.color.paint.unnamed`,{index:idx+1}],menu:[`ui.color.paint.selectOne`,{index:idx+1}],menuAdd:null}));if(props.paintNames?.length>0)for(let i=0;ihoveredPaintIndex.value=idx,tooltip=computed(()=>{let res={name:props.tooltip||props.paintName};return hoveredPaintIndex.value>-1&&paintNames.value[hoveredPaintIndex.value]&&(res.subname=paintNames.value[hoveredPaintIndex.value].tooltip),res}),customMenu=computed(()=>!props.customMenu||props.customMenu.length===0?null:props.customMenu.reduce((res,item,idx)=>item?[...res,{label:item.label||item,click:evt=>{popMenu.value?.hide?.(),nextTick(()=>{item.action?item.action(props.paint,evt):emit$1(`menu-click`,item.value||idx,props.paint,evt)})}}]:res,[])),withMenu=computed(()=>props.withMenu&&(paintAreas.value.length>1||customMenu.value)),opts=computed(()=>({paintId:props.paintId,vehicleName:props.vehicleName,paintName:props.paintName,width:width$1.value,height:height$1.value,radialLight:props.radialLight})),cacheKey=computed(()=>{try{return paintPreviews.getCacheKey(opts.value)}catch{return null}}),paintAreas=computed(()=>{if(!props.paint||isEmpty.value)return[];try{return paintPreviews.getAreas(opts.value)}catch{return[]}}),onContClick=evt=>onClick(-1,evt),onContRMB=()=>withMenu.value&&openMenu();function onClick(idx,evt){popMenu.value?.hide?.(),!props.disabled&&emit$1(`click`,idx,props.paint,evt)}function openMenu(){!elCont.value||!popMenu.value||(popover.hideAll(`paint-tile-menu`),!props.disabled&&popMenu.value.show(elCont.value))}async function renderPreview(){if(!cacheKey.value||!props.paint){isEmpty.value=!0,hasRenderedOnce.value=!1;return}isLoading.value=!0,isEmpty.value=!1;try{let bmp=await paintPreviews.getPreview(paints.value,opts.value);if(elCanvas.value&&bmp){let ctx=elCanvas.value.getContext(`2d`);ctx.clearRect(0,0,width$1.value,height$1.value),ctx.drawImage(bmp,0,0,width$1.value,height$1.value),hasRenderedOnce.value=!0}}catch(error){console.error(`Failed to render preview`,error),isEmpty.value=!0,hasRenderedOnce.value=!1}finally{isLoading.value=!1}}function checkEmpty(){if(!props.paint)return isEmpty.value=!0,hasRenderedOnce.value=!1,!0;if(isMultipaint.value){let allEmpty=paints.value.every(paintArray=>!paintArray||paintArray.length===0);return isEmpty.value=allEmpty,allEmpty&&(hasRenderedOnce.value=!1),allEmpty}return Array.isArray(paints.value)&&paints.value.length===0?(isEmpty.value=!0,hasRenderedOnce.value=!1,!0):(isEmpty.value=!1,!1)}watch(()=>[paints.value,props.paintId,props.vehicleName,props.paintName,width$1.value,height$1.value,props.radialLight],()=>{checkEmpty()?isLoading.value=!1:renderPreview()},{immediate:!0,deep:!0}),watch(()=>props.withAreas,val=>{val||(hoveredPaintIndex.value=-1)});let unsubscribeFromCacheClear=null,outEvents=[`click`,`contextmenu`,`uinav-focus`],listeningOutEvents=!1;function outOfMenu(evt){if(!popMenu.value||!popMenu.value.isShown())return;let el=popMenu.value.getElement();el&&el.contains(evt.detail?.target||evt.target)||nextTick(()=>popMenu.value.hide?.())}return watch(()=>popover.popovers[menuId]?.show,val=>{val?listeningOutEvents||(listeningOutEvents=!0,outEvents.forEach(evt=>document.addEventListener(evt,outOfMenu))):listeningOutEvents&&(listeningOutEvents=!1,outEvents.forEach(evt=>document.removeEventListener(evt,outOfMenu)))}),onMounted(()=>{!checkEmpty()&&renderPreview(),unsubscribeFromCacheClear=paintPreviews.onCacheClear((type,key)=>{(type===`all`||type===`single`&&key===cacheKey.value)&&!checkEmpty()&&hasRenderedOnce.value&&renderPreview()})}),onUnmounted(()=>{unsubscribeFromCacheClear?.(),listeningOutEvents&&outEvents.forEach(evt=>document.removeEventListener(evt,outOfMenu))}),(_ctx,_cache)=>withDirectives((openBlock(),createElementBlock(`div`,{ref_key:`elCont`,ref:elCont,class:normalizeClass([`bng-paint-tile`,{loading:isLoading.value&&!hasRenderedOnce.value,empty:isEmpty.value}]),tabindex:`0`,"bng-nav-item":``,onClick:withModifiers(onContClick,[`stop`]),onContextmenu:withModifiers(onContRMB,[`stop`])},[createBaseVNode(`canvas`,{ref_key:`elCanvas`,ref:elCanvas,width:width$1.value,height:height$1.value},null,8,_hoisted_1$311),__props.withAreas&&paintAreas.value.length>1?(openBlock(),createElementBlock(Fragment,{key:0},[createBaseVNode(`img`,{usemap:`#${unref(mapId)}`,src:unref(emptyImage),alt:``},null,8,_hoisted_2$254),createBaseVNode(`map`,{name:unref(mapId)},[(openBlock(!0),createElementBlock(Fragment,null,renderList(paintAreas.value,(area,index)=>(openBlock(),createElementBlock(`area`,{key:index,shape:`poly`,coords:area.join(`,`),onMouseover:$event=>onMouseOver(index),onMouseleave:_cache[0]||=$event=>onMouseOver(-1),onClick:withModifiers($event=>onClick(index,$event),[`stop`])},null,40,_hoisted_4$190))),128))],8,_hoisted_3$222)],64)):createCommentVNode(``,!0),isEmpty.value||isLoading.value&&!hasRenderedOnce.value?(openBlock(),createElementBlock(`div`,_hoisted_5$162)):createCommentVNode(``,!0),withMenu.value?(openBlock(),createBlock(unref(bngPopoverMenu_default),{key:2,ref_key:`popMenu`,ref:popMenu,name:unref(menuId),focus:``},{default:withCtx(()=>[paintNames.value.length>1?(openBlock(),createElementBlock(Fragment,{key:0},[withDirectives((openBlock(),createBlock(unref(bngButton_default),{accent:unref(ACCENTS).menu,onClick:_cache[1]||=$event=>onClick(-1,$event)},{default:withCtx(()=>[createTextVNode(toDisplayString(_ctx.$tt(`ui.color.paint.selectAll`)),1)]),_:1},8,[`accent`])),[[unref(BngOnUiNav_default),void 0,`ok`,{focusRequired:!0,asMouse:!0}]]),(openBlock(!0),createElementBlock(Fragment,null,renderList(paintNames.value,(paint,index)=>withDirectives((openBlock(),createBlock(unref(bngButton_default),{key:index,accent:unref(ACCENTS).menu,onClick:$event=>onClick(index,$event)},{default:withCtx(()=>[createTextVNode(toDisplayString(_ctx.$tt(...paintNames.value[index].menu))+toDisplayString(paintNames.value[index].menuAdd?`: `+paintNames.value[index].menuAdd:``),1)]),_:2},1032,[`accent`,`onClick`])),[[unref(BngOnUiNav_default),void 0,`ok`,{focusRequired:!0,asMouse:!0}]])),128))],64)):withDirectives((openBlock(),createBlock(unref(bngButton_default),{key:1,accent:unref(ACCENTS).menu,onClick:_cache[2]||=$event=>onClick(0,$event)},{default:withCtx(()=>[createTextVNode(toDisplayString(_ctx.$tt(`ui.color.paint.select`)),1)]),_:1},8,[`accent`])),[[unref(BngOnUiNav_default),void 0,`ok`,{focusRequired:!0,asMouse:!0}]]),customMenu.value?.length>0?(openBlock(!0),createElementBlock(Fragment,{key:2},renderList(customMenu.value,(item,index)=>withDirectives((openBlock(),createBlock(unref(bngButton_default),{key:index,accent:unref(ACCENTS).menu,onClick:$event=>item.click($event)},{default:withCtx(()=>[createTextVNode(toDisplayString(_ctx.$tt(item.label)),1)]),_:2},1032,[`accent`,`onClick`])),[[unref(BngOnUiNav_default),void 0,`ok`,{focusRequired:!0,asMouse:!0}]])),128)):createCommentVNode(``,!0)]),_:1},8,[`name`])):createCommentVNode(``,!0)],34)),[[unref(BngTooltip_default),_ctx.$tt(tooltip.value.name)+(tooltip.value.subname?` - `+_ctx.$tt(...tooltip.value.subname):``),__props.tooltipPosition],[unref(BngOnUiNav_default),void 0,`ok`,{asMouse:!0,focusRequired:!0}]])}},bngPaintTile_default=__plugin_vue_export_helper_default(_sfc_main$356,[[`__scopeId`,`data-v-25bf2552`]]),_hoisted_1$310=[`tabindex`],_sfc_main$355={__name:`bngPill`,props:{marked:{type:Boolean,default:!1}},setup(__props){let props=__props,attrs=useAttrs(),hasClickEvent=computed(()=>attrs&&attrs.onClick),isMarked=ref(props.marked);return watch(()=>props.marked,newValue=>isMarked.value=newValue),(_ctx,_cache)=>(openBlock(),createElementBlock(`span`,{"bng-nav-item":``,class:normalizeClass([`bng-pill`,{"pill-marked":isMarked.value,"pill-clickable":hasClickEvent.value}]),tabindex:hasClickEvent.value?0:-1},[renderSlot(_ctx.$slots,`default`,{},void 0,!0)],10,_hoisted_1$310))}},bngPill_default=__plugin_vue_export_helper_default(_sfc_main$355,[[`__scopeId`,`data-v-2d28d1ed`]]),_sfc_main$354={__name:`bngPillCheckbox`,props:{modelValue:{type:Boolean,default:null},markedIcon:{type:[Boolean,Object],default:!0}},emits:[`update:modelValue`,`valueChanged`,`change`],setup(__props,{emit:__emit}){let props=__props,emit$1=__emit,defaultValue=ref(!1),isChecked=computed({get:()=>props.modelValue!==void 0&&props.modelValue!==null?props.modelValue:defaultValue.value,set:newValue=>{props.modelValue!==void 0&&props.modelValue!==null?notifyListeners(newValue):(defaultValue.value=newValue,emit$1(`valueChanged`,newValue),emit$1(`change`,newValue))}}),onChecked=()=>isChecked.value=!isChecked.value;function notifyListeners(value){emit$1(`update:modelValue`,value),emit$1(`change`,value),emit$1(`valueChanged`,value)}return(_ctx,_cache)=>(openBlock(),createElementBlock(`span`,{class:normalizeClass([`bng-pill-checkbox`,{"show-icon":isChecked.value&&props.markedIcon}])},[createVNode(unref(bngPill_default),{marked:isChecked.value,onClick:onChecked,onKeyup:withKeys(onChecked,[`space`])},{default:withCtx(()=>[createBaseVNode(`span`,{class:normalizeClass({"pill-content":!0,"uses-mark":__props.markedIcon})},[renderSlot(_ctx.$slots,`default`,{},void 0,!0)],2),createVNode(unref(bngIcon_default),{class:`pill-mark-icon`,type:props.markedIcon===!0?unref(icons).checkmark:props.markedIcon||unref(icons).checkmark},null,8,[`type`])]),_:3},8,[`marked`])],2))}},bngPillCheckbox_default=__plugin_vue_export_helper_default(_sfc_main$354,[[`__scopeId`,`data-v-04487830`]]),_hoisted_1$309={class:`bng-pill-filters`,tabindex:`0`},_sfc_main$353={__name:`bngPillFilters`,props:{modelValue:Array,options:{type:Array,required:!0},selectOnFocus:Boolean,selectMany:Boolean,showCheckIcon:{type:Boolean,default:!0},required:Boolean},emits:[`update:modelValue`,`valueChanged`],setup(__props,{expose:__expose,emit:__emit}){let props=__props,emit$1=__emit;__expose({focusPrevious,focusNext,toggleFocusedPill,focusIndex});let scrollable=ref(null),pills=ref([]),currentPillIndex=ref(-1),defaultSelected=ref([]),selectedValues=computed({get:()=>props.modelValue?props.modelValue:defaultSelected.value,set:newValue=>{props.modelValue?(emit$1(`update:modelValue`,newValue),emit$1(`valueChanged`,newValue)):(defaultSelected.value=newValue,emit$1(`valueChanged`,newValue))}}),pillConfigs=computed(()=>toRaw(props.options).map(x=>({...x,selected:selectedValues.value&&selectedValues.value.length>0&&selectedValues.value.includes(x.value)})));function focusPrevious(){currentPillIndex.value=currentPillIndex.value>0?currentPillIndex.value-1:0,pills.value[currentPillIndex.value].querySelector(`.bng-pill`).focus(),console.log(`currentPillIndex.value`,currentPillIndex.value)}function focusNext(){currentPillIndex.value{scrollable.value.addEventListener(`wheel`,evt=>{evt.preventDefault(),scrollable.value.scrollLeft+=evt.deltaY}),currentPillIndex.value=selectedValues.value.length>0?pillConfigs.value.findIndex(x=>x.value===selectedValues.value[0]):-1,currentPillIndex.value>-1&&focusPill(currentPillIndex.value)});let onPillValueChanged=(key,value)=>{props.selectOnFocus||(console.log(`onPillValueChanged`,key,value),setPillValue(key,value))},onPillFocusIn=(key,index)=>{focusPill(index),props.selectOnFocus&&setPillValue(key,!(selectedValues.value.length>0&&selectedValues.value.includes(key)))};function setPillValue(key,checked){if(currentPillIndex.value=pillConfigs.value.findIndex(x=>x.value===key),props.required&&!checked&&selectedValues.value.includes(key)&&selectedValues.value.length==1){selectedValues.value=[key];return}if(!props.selectMany){selectedValues.value=checked?[key]:[];return}let isExisting=selectedValues.value.includes(key);checked&&!isExisting?selectedValues.value=[...selectedValues.value,key]:!checked&&isExisting&&(selectedValues.value=selectedValues.value.filter(x=>x!==key))}function focusPill(index){let pillEl=pills.value[index],scrollableRect=scrollable.value.getBoundingClientRect(),pillRect=pillEl.getBoundingClientRect();pillRect.left>=scrollableRect.left&&pillRect.right<=scrollableRect.right||window.requestAnimationFrame(()=>{scrollable.value.scrollBy({left:pillEl.getBoundingClientRect().right})})}return(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$309,[createBaseVNode(`div`,{class:`pills-wrapper`,ref_key:`scrollable`,ref:scrollable},[(openBlock(!0),createElementBlock(Fragment,null,renderList(pillConfigs.value,(pill,index)=>(openBlock(),createElementBlock(`div`,{key:pill.value,ref_for:!0,ref_key:`pills`,ref:pills,class:`pill-wrapper`},[createVNode(unref(bngPillCheckbox_default),{markedIcon:__props.showCheckIcon,modelValue:pill.selected,"onUpdate:modelValue":$event=>pill.selected=$event,onValueChanged:value=>onPillValueChanged(pill.value,value),onFocusin:$event=>onPillFocusIn(pill.value,index)},{default:withCtx(()=>[createTextVNode(toDisplayString(pill.label),1)]),_:2},1032,[`markedIcon`,`modelValue`,`onUpdate:modelValue`,`onValueChanged`,`onFocusin`])]))),128))],512)]))}},bngPillFilters_default=__plugin_vue_export_helper_default(_sfc_main$353,[[`__scopeId`,`data-v-580a9eac`]]),_sfc_main$352={__name:`bngPillFiltersContainer`,props:{options:{type:Array,required:!0},selectOnNavigation:{type:Boolean,default:!0},required:Boolean,selectMany:Boolean,hasCheckedIcon:{default:!0,type:Boolean}},emits:[`update:modelValue`,`valueChanged`],setup(__props,{expose:__expose,emit:__emit}){let emit$1=__emit,props=__props,selectedItems=ref([]),bngFiltersContainer=ref(null),filtersContainer=ref(null),bngPillFiltersRef=ref(null);__expose({selectPrevious:()=>bngPillFiltersRef.value.selectPrevious(),selectNext:()=>bngPillFiltersRef.value.selectNext(),selectCurrent:()=>bngPillFiltersRef.value.selectCurrent(),focusAndScrollToSelected:focusSelected});let selectedItemId=``;onMounted(()=>{filtersContainer.value.addEventListener(`wheel`,evt=>{evt.preventDefault(),filtersContainer.value.scrollLeft+=evt.deltaY})});function focusSelected(){props.selectMany||!props.selectOnNavigation||scrollToElement(selectedItemId)}function onContainerFocusOut($event){!($event.relatedTarget&&bngFiltersContainer.value.contains($event.relatedTarget))&&!props.selectMany&&selectedItemId&&scrollToElement(selectedItemId)}function onValueChanged(items$2,id){selectedItems.value=items$2,selectedItemId=id,emit$1(`valueChanged`,items$2,id)}function onPillItemFocusIn(id){scrollToElement(id)}function scrollToElement(id){let scrollableContainer=filtersContainer.value,el=scrollableContainer.querySelector(`#${id}`);if(el){let scrollableContainerRect=scrollableContainer.getBoundingClientRect(),itemRect=el.getBoundingClientRect();if(itemRect.left>=scrollableContainerRect.left&&itemRect.right<=scrollableContainerRect.right)return;window.requestAnimationFrame(()=>{let scrollValue=itemRect.left(openBlock(),createElementBlock(`div`,{class:`bng-filters-container`,ref_key:`bngFiltersContainer`,ref:bngFiltersContainer,tabindex:`0`,onFocusout:onContainerFocusOut},[_cache[0]||=createBaseVNode(`div`,{class:`fade-effect left-fade-effect`},null,-1),_cache[1]||=createBaseVNode(`div`,{class:`fade-effect right-fade-effect`},null,-1),createBaseVNode(`div`,{class:`scroll-container`,ref_key:`filtersContainer`,ref:filtersContainer},[createVNode(unref(bngPillFilters_default),{ref_key:`bngPillFiltersRef`,ref:bngPillFiltersRef,options:__props.options,"select-on-navigation":__props.selectOnNavigation,required:__props.required,"select-many":__props.selectMany,"show-checked-icon":__props.hasCheckedIcon,onValueChanged,onPillItemFocusIn},null,8,[`options`,`select-on-navigation`,`required`,`select-many`,`show-checked-icon`])],512)],544))}},bngPillFiltersContainer_default=__plugin_vue_export_helper_default(_sfc_main$352,[[`__scopeId`,`data-v-498af92b`]]),_hoisted_1$308=[`data-bng-popover-name`],containerSelector=`.popover-container`,_sfc_main$351={__name:`bngPopoverContent`,props:{name:String,offset:{type:Number,default:4},hideArrow:Boolean,placement:String,disabled:Boolean},emits:[`show`,`hide`,`placementChanged`],setup(__props,{expose:__expose,emit:__emit}){let props=__props,emit$1=__emit,popover=usePopover(),popoverName,popoverContent=ref(null),arrow$3=ref(null),show=ref(!1),unwatchShow,unwatchPlacement,teleportTargetExists=ref(!1),observer$2=null,scopeActivated=ref(!1),isRender=computed(()=>!props.disabled&&teleportTargetExists.value&&show.value),hide$2=()=>!props.disabled&&popover.hide(popoverName),expose={hide:hide$2,show:(el=void 0)=>!props.disabled&&popover.show(popoverName,el),toggle:(forceVal=void 0)=>popover.toggle(popoverName,!props.disabled&&forceVal),isShown:()=>popover.isShown(popoverName)};__expose(expose),watch(()=>show.value,value=>emit$1(value?`show`:`hide`,{name:props.name,...expose})),watch(()=>props.name,(newName,oldName)=>{oldName&&disposePopover(oldName),props.disabled||setupPopover()},{immediate:!0}),watch(()=>props.disabled,value=>{value?(popover.hide(popoverName),disposePopover(popoverName)):setupPopover()}),watch(isRender,async value=>{value&&(await nextTick(),checkSlotContent())});let onMenu=()=>{scopeActivated.value=!1};onBeforeUnmount(()=>{disposePopover(popoverName),observer$2&&=(observer$2.disconnect(),null)}),onMounted(async()=>{teleportTargetExists.value=!!document.querySelector(containerSelector),teleportTargetExists.value||(observer$2=new MutationObserver(()=>{!teleportTargetExists.value&&document.querySelector(containerSelector)&&(teleportTargetExists.value=!0,observer$2.disconnect(),observer$2=null)}),observer$2.observe(document.body,{childList:!0,subtree:!0})),isRender.value&&(await nextTick(),checkSlotContent())});function onScopeChanged(activated,event){scopeActivated.value=activated,!activated&&!event.detail.force&&popover.hide(popoverName)}function checkSlotContent(){let navigableElements=popoverContent.value.querySelectorAll(NAVIGABLE_ELEMENTS_SELECTOR);navigableElements&&navigableElements.length>0&&!scopeActivated.value&&(scopeActivated.value=!0)}function setupPopover(){popoverName=props.name||uniqueId(`bng-popover-content`);let res=popover.register(popoverName,popoverContent,props.placement,{arrow:props.hideArrow?void 0:arrow$3,offset:props.offset});res&&(unwatchShow=watch(res.show,value=>show.value=value),unwatchPlacement=watch(res.placement,placement=>emit$1(`placementChanged`,placement)))}function disposePopover(name){unwatchShow&&=(unwatchShow(),null),unwatchPlacement&&=(unwatchPlacement(),null),popover.unregister(name),show.value=!1,popoverName=null}return(_ctx,_cache)=>isRender.value?(openBlock(),createBlock(Teleport,{key:0,to:`.popover-container`},[withDirectives((openBlock(),createElementBlock(`div`,{ref_key:`popoverContent`,ref:popoverContent,"data-bng-popover-name":unref(popoverName),class:`bng-popover`,onActivate:_cache[0]||=$event=>onScopeChanged(!0,$event),onDeactivate:_cache[1]||=$event=>onScopeChanged(!1,$event)},[renderSlot(_ctx.$slots,`default`,{hide:hide$2},void 0,!0),__props.hideArrow?createCommentVNode(``,!0):(openBlock(),createElementBlock(`span`,{key:0,ref_key:`arrow`,ref:arrow$3,class:`bng-popover-arrow`},null,512))],40,_hoisted_1$308)),[[unref(BngScopedNav_default),{activated:scopeActivated.value,type:unref(SCOPED_NAV_TYPES).popover}],[unref(BngOnUiNav_default),onMenu,`menu`]])])):createCommentVNode(``,!0)}},bngPopoverContent_default=__plugin_vue_export_helper_default(_sfc_main$351,[[`__scopeId`,`data-v-4938e558`]]),_sfc_main$350=Object.assign({inheritAttrs:!1},{__name:`bngPopoverMenu`,props:{name:String,offset:{type:Number,default:4},hideArrow:Boolean,disabled:Boolean,focus:Boolean},emits:[`show`,`hide`,`placementChanged`],setup(__props,{expose:__expose,emit:__emit}){let popover=usePopover(),props=__props,emit$1=__emit,relay={show:(...args)=>emit$1(`show`,...args),hide:(...args)=>emit$1(`hide`,...args),placementChanged:(...args)=>emit$1(`placementChanged`,...args)},popoverContent=ref(null),popoverMenu=ref(null),hide$2=(...args)=>popoverContent.value.hide(...args);return __expose({hide:hide$2,show:(...args)=>popoverContent.value.show(...args),toggle:(...args)=>popoverContent.value.toggle(...args),isShown:(...args)=>popoverContent.value.isShown(...args),getElement:()=>popoverMenu.value}),watchEffect(()=>{if(props.name in popover.popovers){let pop=popover.popovers[props.name];!pop.show&&nextTick(()=>{pop.target&&document.activeElement===document.body&&setFocusExternal(pop.target,!0,!1)})}}),(_ctx,_cache)=>(openBlock(),createBlock(unref(bngPopoverContent_default),{ref_key:`popoverContent`,ref:popoverContent,name:__props.name,offset:__props.offset,"hide-arrow":__props.hideArrow,disabled:__props.disabled,onPlacementChanged:relay.placementChanged,onHide:hide$2},{default:withCtx(()=>[createBaseVNode(`div`,{ref_key:`popoverMenu`,ref:popoverMenu,class:`bng-popover-menu`},[renderSlot(_ctx.$slots,`default`,{hide:hide$2},void 0,!0)],512)]),_:3},8,[`name`,`offset`,`hide-arrow`,`disabled`,`onPlacementChanged`]))}}),bngPopoverMenu_default=__plugin_vue_export_helper_default(_sfc_main$350,[[`__scopeId`,`data-v-fe39553c`]]),_hoisted_1$307={class:`bng-progress-bar`},_hoisted_2$253={key:0,class:`header`},_hoisted_3$221={class:`header-left`},_hoisted_4$189={class:`header-right`},_hoisted_5$161={class:`progress-bar`},_hoisted_6$139=[`innerHTML`],_hoisted_7$121={key:1,class:`progress-fill-indeterminate`},_sfc_main$349={__name:`bngProgressBar`,props:{value:{type:Number,default:0},oldValue:{type:Number,default:0},min:{type:Number,default:0},max:{type:Number,required:!0},headerLeft:String,headerRight:String,showValueLabel:{type:Boolean,default:!0},valueLabelFormat:{type:[String,Function],default:`#value#`},valueColor:{type:String,default:`#ff6600`},oldValueColor:{type:String,default:`#ffffff`},indeterminate:Boolean,animateDifference:Boolean,gradient:Boolean},setup(__props,{expose:__expose}){useCssVars(_ctx=>({v5113e7b0:__props.valueColor,v14406f01:progressFillUnits.value,v6b373656:oldProgressFillUnits.value}));let props=__props;__expose({decreaseValueBy,increaseValueBy,setValue:value=>updateCurrentValue(value)});let currentValue=ref(null),valueHTML=computed(()=>{let res;return res=typeof props.valueLabelFormat==`function`?props.valueLabelFormat(props.value,{min:props.min,max:props.max}):props.valueLabelFormat.replace(/ +/g,` `).replace(`#value#`,`${currentValue.value}${props.max}`),res}),progressFillUnits=computed(()=>1-(currentValue.value-props.min)/(props.max-props.min)),oldProgressFillUnits=computed(()=>1-(props.oldValue-props.min)/(props.max-props.min));watch(()=>props.value,updateCurrentValue),onMounted(()=>{updateCurrentValue(props.min>props.value?props.min:props.value)});function decreaseValueBy(value){let newValue=currentValue.value-value;newValueprops.max&&(newValue=props.max),updateCurrentValue(newValue)}function updateCurrentValue(newValue){currentValue.value=newValue}return(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$307,[__props.headerLeft||__props.headerRight?(openBlock(),createElementBlock(`div`,_hoisted_2$253,[createBaseVNode(`span`,_hoisted_3$221,toDisplayString(__props.headerLeft),1),createBaseVNode(`span`,_hoisted_4$189,toDisplayString(__props.headerRight),1)])):createCommentVNode(``,!0),createBaseVNode(`div`,_hoisted_5$161,[__props.showValueLabel?(openBlock(),createElementBlock(`div`,{key:0,class:`info`,innerHTML:valueHTML.value},null,8,_hoisted_6$139)):createCommentVNode(``,!0),__props.indeterminate?(openBlock(),createElementBlock(`span`,_hoisted_7$121)):(openBlock(),createElementBlock(`span`,{key:2,class:normalizeClass({"progress-fill":!0,"progress-fill-gradient":__props.gradient,"animate-progress":__props.animateDifference&&__props.value>__props.oldValue}),style:normalizeStyle({backgroundColor:__props.valueColor,zIndex:__props.value<__props.oldValue?2:1})},null,6)),__props.oldValue?(openBlock(),createElementBlock(`span`,{key:3,class:normalizeClass({"second-progress-fill":!0,"progress-fill-gradient":__props.gradient,"animate-progress":__props.animateDifference&&__props.value<__props.oldValue}),style:normalizeStyle({backgroundColor:__props.oldValueColor,zIndex:__props.value<__props.oldValue?1:2})},null,6)):createCommentVNode(``,!0)])]))}},bngProgressBar_default=__plugin_vue_export_helper_default(_sfc_main$349,[[`__scopeId`,`data-v-1ca6aacd`]]);function shrinkNum(num,decimals=0){let units=[``,`K`,`M`,`B`,`T`,`Q`];if(!num)return`0`;if(isNaN(parseFloat(num))||!isFinite(+num))return`n/a`;let power$1=Math.floor(Math.log(Math.abs(+num))/Math.log(1e3));return power$1>=units.length&&(power$1=units.length-1),(num/1e3**power$1).toFixed(decimals).replace(/\.0+$/,``)+units[power$1]}var _hoisted_1$306={key:1,class:`key-label`},_hoisted_2$252={class:`value-label`},_sfc_main$348={__name:`bngPropVal`,props:{iconType:[String,Object],keyLabel:String,valueLabel:{required:!0},shrinkNum:Boolean,iconColor:{type:String,default:`#fff`},noGap:{type:Boolean,default:!1},noIcon:{type:Boolean,default:!1}},setup(__props){let props=__props,itemClass=computed(()=>({"info-item":!0,"with-icon":props.iconType,"no-key":!props.keyLabel,"no-gap":props.noGap})),value=computed(()=>{let i=props.valueLabel;return props.shrinkNum?shrinkNum(i,0):i});return(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,{class:normalizeClass(itemClass.value)},[__props.iconType&&!__props.noIcon?(openBlock(),createBlock(unref(bngIcon_default),{key:0,class:`icon`,type:__props.iconType,color:__props.iconColor},null,8,[`type`,`color`])):createCommentVNode(``,!0),__props.keyLabel?(openBlock(),createElementBlock(`span`,_hoisted_1$306,toDisplayString(__props.keyLabel),1)):createCommentVNode(``,!0),createBaseVNode(`span`,_hoisted_2$252,toDisplayString(value.value),1)],2))}},bngPropVal_default=__plugin_vue_export_helper_default(_sfc_main$348,[[`__scopeId`,`data-v-fa2e2062`]]),_hoisted_1$305={class:`header`},_sfc_main$347={__name:`bngScreenHeading`,props:{blurDelay:Number,preheadings:Array,divider:Boolean,type:{type:String,default:`line`,validator:v=>[`line`,`ribbon`].includes(v)||v===``}},setup(__props){let blurVal=ref(!1);onMounted(()=>window.setTimeout(()=>blurVal.value=!0,~~+props.blurDelay));let props=__props,preheadings=computed(()=>Array.isArray(props.preheadings)&&props.preheadings.length>0?props.preheadings:null);return(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,{class:normalizeClass([`bng-screen-heading`,{[`heading-style-${__props.type}`]:!0,prehead:preheadings.value}])},[preheadings.value?withDirectives((openBlock(),createElementBlock(`span`,{key:0,class:normalizeClass([`pre-header`,{"with-divider":__props.divider}])},[(openBlock(!0),createElementBlock(Fragment,null,renderList(preheadings.value,preheading=>(openBlock(),createElementBlock(`span`,{class:`location`,key:preheading},toDisplayString(preheading),1))),128))],2)),[[unref(BngBlur_default),blurVal.value]]):createCommentVNode(``,!0),withDirectives((openBlock(),createElementBlock(`h1`,_hoisted_1$305,[renderSlot(_ctx.$slots,`default`,{},void 0,!0)])),[[unref(BngBlur_default),blurVal.value]])],2))}},bngScreenHeading_default=__plugin_vue_export_helper_default(_sfc_main$347,[[`__scopeId`,`data-v-f6d9f077`]]),_hoisted_1$304={class:`header`},_hoisted_2$251={key:0,class:`decorator-item`,width:`100%`,height:`100%`,viewBox:`0 0 32 40`,preserveAspectRatio:`none`,fill:`none`,xmlns:`http://www.w3.org/2000/svg`},_hoisted_3$220={key:1,class:`decorator-item`,width:`100%`,height:`100%`,viewBox:`0 0 36 40`,preserveAspectRatio:`xMaxYMid slice`,fill:`none`,xmlns:`http://www.w3.org/2000/svg`},_hoisted_4$188={key:2,class:`decorator-item`,width:`100%`,height:`100%`,viewBox:`0 0 36 40`,preserveAspectRatio:`xMaxYMid slice`,fill:`none`,xmlns:`http://www.w3.org/2000/svg`},_sfc_main$346={__name:`bngScreenHeadingV2`,props:{blurDelay:Number,preheadings:Array,divider:Boolean,type:{type:String,default:`1`,validator:v=>[`1`,`2`,`3`].includes(v)||v===``},hintVisible:Boolean,hintLabel:String,hintIcon:String,hintAccent:String,hintBindingEvent:String},emits:[`hint`],setup(__props,{emit:__emit}){let blurVal=ref(!1);onMounted(()=>window.setTimeout(()=>blurVal.value=!0,~~+props.blurDelay));let props=__props,preheadings=computed(()=>Array.isArray(props.preheadings)&&props.preheadings.length>0?props.preheadings:null);return computed(()=>props.hintVisible??!1),computed(()=>props.hintLabel??``),computed(()=>props.hintIcon??icons.arrowLargeLeft),computed(()=>props.hintAccent??ACCENTS.outlined),(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,{class:normalizeClass([`bng-screen-heading`,{[`heading-style-${__props.type}`]:!0,prehead:preheadings.value}])},[renderSlot(_ctx.$slots,`preheadings`,{},void 0,!0),withDirectives((openBlock(),createElementBlock(`span`,_hoisted_1$304,[createBaseVNode(`div`,{class:normalizeClass(`decorator type${__props.type}`)},[__props.type===`1`?(openBlock(),createElementBlock(`svg`,_hoisted_2$251,[..._cache[0]||=[createBaseVNode(`path`,{d:`M16.6328 40H1.62891L14.0039 6H14.002L11.8174 0H26.8174L29.001 6H29.0078L16.6328 40Z`,fill:`var(--bng-orange-400)`},null,-1)]])):createCommentVNode(``,!0),__props.type===`2`?(openBlock(),createElementBlock(`svg`,_hoisted_3$220,[..._cache[1]||=[createBaseVNode(`path`,{d:`M18.6366 0H34.0094L26.73 20H11.3572L18.6366 0Z`,fill:`#DA5706`},null,-1),createBaseVNode(`path`,{d:`M19.4504 40H4.07812L11.3572 20L4.07812 0H19.4504L26.7295 20L19.4504 40Z`,fill:`var(--bng-orange-400)`},null,-1)]])):createCommentVNode(``,!0),__props.type===`3`?(openBlock(),createElementBlock(`svg`,_hoisted_4$188,[..._cache[2]||=[createBaseVNode(`path`,{d:`M18.6366 0H34.0094L26.73 20H11.3572L18.6366 0Z`,fill:`#DA5706`},null,-1),createBaseVNode(`path`,{d:`M19.4504 40H4.07812L11.3572 20L4.07812 0H19.4504L26.7295 20L19.4504 40Z`,fill:`var(--bng-orange-400)`},null,-1)]])):createCommentVNode(``,!0)],2),createBaseVNode(`h1`,null,[renderSlot(_ctx.$slots,`default`,{},void 0,!0)])])),[[unref(BngBlur_default),blurVal.value]])],2))}},bngScreenHeadingV2_default=__plugin_vue_export_helper_default(_sfc_main$346,[[`__scopeId`,`data-v-4854a8bd`]]),_hoisted_1$303={class:`label select`},_hoisted_2$250={class:`bng-select-indicator`},_sfc_main$345={__name:`bngSelect`,props:mergeModels({value:void 0,options:{type:Array,required:!0},config:{type:Object,default:()=>({value:opt=>opt,label:opt=>opt})},loop:Boolean,labelClickable:Boolean,labelPopover:String,disabled:Boolean,navLeftEvent:{type:String,default:`focus_l`},navRightEvent:{type:String,default:`focus_r`}},{modelValue:{type:[Object,Boolean,Number,String],default:void 0},modelModifiers:{}}),emits:mergeModels([`change`,`valueChanged`,`label-click`],[`update:modelValue`]),setup(__props,{expose:__expose,emit:__emit}){let leftBinding=ref(),rightBinding=ref(),vModel=useModel(__props,`modelValue`),props=__props,elContainer=ref(),elContent=ref(),findOptionValue=(valueToFind,opts)=>Math.max(0,opts.findIndex(opt=>props.config.value(opt)===valueToFind)),index=ref(getInitialValue()),current=computed(()=>({option:props.options[index.value],value:props.config.value(props.options[index.value]),label:props.config.label(props.options[index.value])})),leftIconClass=computed(()=>({"with-binding":leftBinding.value?.displayed})),rightIconClass=computed(()=>({"with-binding":rightBinding.value?.displayed})),isLeftDisabled=props.loop?!1:computed(()=>index.value==0),isRightDisabled=props.loop?!1:computed(()=>index.value==props.options.length-1),emit$1=__emit,goPrev=()=>{!props.disabled&&!isLeftDisabled.value&&changeIndex(-1)},goNext=()=>{!props.disabled&&!isRightDisabled.value&&changeIndex(1)};__expose({goNext,goPrev,getElement:()=>elContainer.value,getContentElement:()=>elContent.value}),watch(()=>props.value,()=>index.value=props.value!==null&&props.value!==void 0?findOptionValue(props.value,props.options):0),watch(vModel,val=>index.value=val==null?0:findOptionValue(val,props.options)),watch(()=>index.value,updateValue);function updateValue(){emit$1(`valueChanged`,current.value.value,current.value.label,current.value.option),emit$1(`change`,current.value.value,current.value.label,current.value.option),vModel.value=current.value.value}function changeIndex(offset$2){props.loop?index.value=(props.options.length+index.value+offset$2)%props.options.length:index.value=clamp(index.value+offset$2,0,props.options.length-1)}function getInitialValue(){return vModel.value!==null&&vModel.value!==void 0?findOptionValue(vModel.value,props.options):`value`in props?findOptionValue(props.value,props.options):0}return(_ctx,_cache)=>withDirectives((openBlock(),createElementBlock(`div`,{ref_key:`elContainer`,ref:elContainer,class:`bng-select`,"bng-nav-item":``},[renderSlot(_ctx.$slots,`previousButton`,{click:goPrev,disabled:unref(isLeftDisabled)},()=>[createVNode(unref(bngButton_default),{"bng-no-nav":`true`,disabled:__props.disabled||unref(isLeftDisabled),accent:unref(ACCENTS).text,mute:_ctx.$attrs.mute,"data-testid":`previous-btn`,onClick:goPrev},{default:withCtx(()=>[createVNode(unref(bngIcon_default),{type:leftBinding.value?.displayed?unref(icons).arrowSmallLeft:unref(icons).arrowLargeLeft,class:normalizeClass(leftIconClass.value)},null,8,[`type`,`class`]),__props.navLeftEvent&&__props.navLeftEvent!==`focus_l`?(openBlock(),createBlock(unref(bngBinding_default),{key:0,ref_key:`leftBinding`,ref:leftBinding,uiEvent:__props.navLeftEvent,controller:``},null,8,[`uiEvent`])):createCommentVNode(``,!0)]),_:1},8,[`disabled`,`accent`,`mute`])],!0),withDirectives((openBlock(),createElementBlock(`div`,{ref_key:`elContent`,ref:elContent,class:normalizeClass([`bng-select-content`,{"label-clickable":__props.labelClickable}]),onClick:_cache[0]||=withModifiers($event=>__props.labelClickable&&emit$1(`label-click`),[`stop`])},[renderSlot(_ctx.$slots,`display`,{label:current.value.label,value:current.value.value},()=>[createBaseVNode(`span`,_hoisted_1$303,toDisplayString(current.value.label),1),_cache[1]||=createBaseVNode(`label`,{flavour:``},null,-1)],!0)],2)),[[unref(BngSoundClass_default),!__props.disabled&&__props.labelClickable&&`bng_click_hover_generic`],[unref(BngPopover_default),__props.labelPopover,`bottom`,{click:!0}]]),renderSlot(_ctx.$slots,`nextButton`,{click:goNext,disabled:unref(isRightDisabled)},()=>[createVNode(unref(bngButton_default),{"bng-no-nav":`true`,disabled:__props.disabled||unref(isRightDisabled),accent:unref(ACCENTS).text,mute:_ctx.$attrs.mute,"data-testid":`next-btn`,onClick:goNext},{default:withCtx(()=>[__props.navRightEvent&&__props.navRightEvent!==`focus_r`?(openBlock(),createBlock(unref(bngBinding_default),{key:0,ref_key:`rightBinding`,ref:rightBinding,uiEvent:__props.navRightEvent,controller:``},null,8,[`uiEvent`])):createCommentVNode(``,!0),createVNode(unref(bngIcon_default),{type:rightBinding.value?.displayed?unref(icons).arrowSmallRight:unref(icons).arrowLargeRight,class:normalizeClass(rightIconClass.value)},null,8,[`type`,`class`])]),_:1},8,[`disabled`,`accent`,`mute`])],!0),createBaseVNode(`div`,_hoisted_2$250,[(openBlock(!0),createElementBlock(Fragment,null,renderList(__props.options.length,idx=>(openBlock(),createElementBlock(`div`,{key:idx,class:normalizeClass({active:idx-1===index.value})},null,2))),128))])])),[[unref(BngOnUiNav_default),goPrev,__props.navLeftEvent,{focusRequired:!0}],[unref(BngOnUiNav_default),goNext,__props.navRightEvent,{focusRequired:!0}],[unref(BngDisabled_default),__props.disabled]])}},bngSelect_default=__plugin_vue_export_helper_default(_sfc_main$345,[[`__scopeId`,`data-v-d1cacb72`]]),_hoisted_1$302={class:`bng-simple-graph`},_hoisted_2$249={key:0,class:`y-axis`},_hoisted_3$219={class:`y-values`},_hoisted_4$187={class:`max-value`},_hoisted_5$160={class:`axis-label`},_hoisted_6$138={key:0,class:`unit`},_hoisted_7$120={class:`min-value`},_hoisted_8$100={viewBox:`0 0 100 100`,preserveAspectRatio:`none`,class:`graph-svg`},_hoisted_9$90=[`width`,`height`],_hoisted_10$78=[`d`,`stroke`],_hoisted_11$70=[`d`,`stroke`],_hoisted_12$58=[`width`,`height`],_hoisted_13$50=[`d`,`stroke`],_hoisted_14$45=[`d`,`stroke`],_hoisted_15$43={key:0,width:`100`,height:`100`,fill:`url(#subgrid)`},_hoisted_16$40={class:`grid`},_hoisted_17$33=[`y1`,`y2`,`stroke`],_hoisted_18$30={class:`background-ranges`},_hoisted_19$25=[`x`,`width`,`fill`,`stroke`,`opacity`],_hoisted_20$21={class:`vertical-guides`},_hoisted_21$19=[`x1`,`x2`,`stroke`,`opacity`],_hoisted_22$17=[`x1`,`x2`],_hoisted_23$16=[`d`,`fill`,`opacity`],_hoisted_24$15=[`d`,`stroke`],_hoisted_25$14={key:2,class:`x-axis`},_hoisted_26$12={class:`x-values`},_hoisted_27$12={class:`min-value`},_hoisted_28$11={class:`axis-label`},_hoisted_29$11={key:0,class:`unit`},_hoisted_30$10={class:`max-value`},_sfc_main$344={__name:`bngSimpleGraph`,props:{config:{type:Object,default:()=>({showLabels:!1,xAxis:{key:`x`,label:`X Axis`,unit:``},yAxis:{key:`y`,label:`Y Axis`,unit:``}})},points:{type:Array,default:()=>[]},gridColor:{type:String,default:`var(--bng-ter-blue-gray-500)`},backgroundColor:{type:String,default:`rgba(0, 0, 0, 0.1)`},currentX:{type:Number,default:null},verticalGuides:{type:Array,default:()=>[]},ranges:{type:Array,default:()=>[]},gridDivisions:{type:Array,default:()=>[50,20]},subgridDivider:{type:Number,default:2},showSubgrid:{type:Boolean,default:!0},singleLabel:{type:Object,default:null}},setup(__props){useCssVars(_ctx=>({v194c2663:__props.config.showLabels?`2rem`:`0`,fdb9891e:__props.backgroundColor}));let props=__props,gridSizes=computed(()=>({x:100/props.gridDivisions[0],y:100/props.gridDivisions[1]})),xScale=computed(()=>{if(props.config?.xAxis?.min!==void 0&&props.config?.xAxis?.max!==void 0){let range$1=props.config.xAxis.max-props.config.xAxis.min;return{min:props.config.xAxis.min,max:props.config.xAxis.max,range:range$1===0?1:range$1}}if(!props.points.length)return{min:0,max:1,range:1};let xValues=[...props.points.flatMap(dataset=>(dataset.points||[]).map(point=>point&&point[0])),...(props.verticalGuides||[]).map(guide=>guide?.x),...(props.ranges||[]).map(range$1=>range$1?.start),...(props.ranges||[]).map(range$1=>range$1?.end)].filter(val=>val!=null&&isFinite(val));if(xValues.length===0)return{min:0,max:1,range:1};let min$1=Math.min(...xValues),max$1=Math.max(...xValues);if(!isFinite(min$1)||!isFinite(max$1))return{min:0,max:1,range:1};let range=max$1-min$1;return{min:min$1,max:max$1,range:range===0?1:range}}),getXPosition=value=>{if(value==null||!isFinite(value))return 0;let result=(value-xScale.value.min)/xScale.value.range*100;return isFinite(result)?result:0},datasetPaths=computed(()=>!props.points.length||!xScale.value?[]:props.points.map(dataset=>{if(!dataset.points||!Array.isArray(dataset.points)||dataset.points.length===0)return{datasetId:dataset.label||`unknown`,linePath:``,areaPath:``};let linePoints=dataset.points.map((point,index)=>{if(!point||point.length<2)return``;let x=getXPosition(point[0]),y=getYPosition(point[1]);return`${index===0?`M`:`L`} ${x} ${y}`}).filter(p$1=>p$1).join(` `),areaPoints=dataset.points.map(point=>!point||point.length<2?``:`L ${getXPosition(point[0])} ${getYPosition(point[1])}`).filter(p$1=>p$1).join(` `),areaPath=``;if(dataset.fill&&dataset.points.length>0){let firstPoint=dataset.points[0],lastPoint=dataset.points[dataset.points.length-1];firstPoint&&lastPoint&&firstPoint.length>=2&&lastPoint.length>=2&&(areaPath=`M -5 105 L -5 ${getYPosition(firstPoint[1])} ${areaPoints} L 105 ${getYPosition(lastPoint[1])} L 105 105 Z`)}return{datasetId:dataset.label||`unknown`,linePath:linePoints,areaPath}})),getLinePathForDataset=dataset=>{let path=datasetPaths.value.find(p$1=>p$1.datasetId===dataset.label);return path?path.linePath:``},getAreaPathForDataset=dataset=>{let path=datasetPaths.value.find(p$1=>p$1.datasetId===dataset.label);return path?path.areaPath:``},getYPosition=value=>{if(value==null||!isFinite(value))return 50;let yMin=yBounds.value.min,yMax=yBounds.value.max;if(yMin==null||yMax==null||!isFinite(yMin)||!isFinite(yMax)||yMin===yMax)return 50;if(yMin>=0||yMax<=0){let yRange$1=yMax-yMin;if(yRange$1===0)return 50;let result$1=97.5-(value-yMin)/yRange$1*95;return isFinite(result$1)?result$1:50}let yRange=Math.max(Math.abs(yMin),Math.abs(yMax));if(yRange===0)return 50;let totalRange=Math.abs(yMin)+Math.abs(yMax);if(totalRange===0)return 50;let zeroLinePosition=Math.abs(yMin)/totalRange*95+2.5,result;return result=value>=0?zeroLinePosition-value/yRange*(zeroLinePosition-2.5):zeroLinePosition+Math.abs(value)/yRange*(97.5-zeroLinePosition),isFinite(result)?result:50},formatNumber=num=>num==null||!isFinite(num)?`0`:Math.floor(num).toString(),yBounds=computed(()=>{if(props.config?.yAxis?.min!==void 0&&props.config?.yAxis?.max!==void 0)return{min:props.config.yAxis.min,max:props.config.yAxis.max};if(!props.points.length)return{min:0,max:0};let allYValues=props.points.flatMap(dataset=>(dataset.points||[]).map(point=>point&&point[1])).filter(val=>val!=null&&isFinite(val));if(allYValues.length===0)return{min:0,max:1};let min$1=Math.min(...allYValues),max$1=Math.max(...allYValues);return!isFinite(min$1)||!isFinite(max$1)?{min:0,max:1}:{min:min$1,max:max$1}}),xMinFormatted=computed(()=>formatNumber(xScale.value?.min||0)),xMaxFormatted=computed(()=>formatNumber(xScale.value?.max||0)),yMinFormatted=computed(()=>formatNumber(yBounds.value.min)),yMaxFormatted=computed(()=>formatNumber(yBounds.value.max)),hasNegativeValues=computed(()=>yBounds.value.min<0),getLabelPosition=()=>{if(!props.singleLabel)return{x:0,y:0,anchor:`start`};let labelX=props.singleLabel.x===void 0?95:getXPosition(props.singleLabel.x),labelY=props.singleLabel.y===void 0?50:getYPosition(props.singleLabel.y),adjustedY=labelY>=25?labelY+4:labelY-2,anchor=labelX>=80?`end`:`start`;return{x:anchor===`end`?Math.min(labelX,98):Math.max(labelX,2),y:adjustedY,anchor}},getLabelStyle=()=>{if(!props.singleLabel)return{};let basePos=getLabelPosition(),estimatedWidth=props.singleLabel.text.length*6.5+6,estimatedHeight=18,containerWidth=300,containerHeight=80,pixelX=basePos.x/100*300,pixelY=basePos.y/100*80,finalX=basePos.x,finalY=basePos.y,anchor=basePos.anchor,verticalAlign=`middle`;anchor===`start`?pixelX+estimatedWidth>290&&(anchor=`end`):pixelX-estimatedWidth<10&&(anchor=`start`);let minGapFromPoint=4,topBuffer=8,bottomBuffer=8,wouldOverflowTop=pixelY-18/2<8;if(pixelY+18/2>72)verticalAlign=`bottom`,finalY=Math.max(basePos.y-4,15);else if(wouldOverflowTop)verticalAlign=`top`,finalY=Math.min(basePos.y+4,85);else{let pointY=basePos.y;pointY>75?(verticalAlign=`bottom`,finalY=pointY-4):pointY<25?(verticalAlign=`top`,finalY=pointY+4):(verticalAlign=`bottom`,finalY=pointY-4)}let transformX=`translateX(0)`,transformY=`translateY(-50%)`;return anchor===`end`&&(transformX=`translateX(-100%)`),verticalAlign===`bottom`?transformY=`translateY(-100%)`:verticalAlign===`top`&&(transformY=`translateY(0)`),{position:`absolute`,left:`${finalX}%`,top:`${finalY}%`,transform:`${transformX} ${transformY}`,color:props.singleLabel.color||`var(--bng-orange)`,fontSize:`11px`,fontFamily:`sans-serif`,pointerEvents:`none`,whiteSpace:`nowrap`}};return(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$302,[__props.config.showLabels?(openBlock(),createElementBlock(`div`,_hoisted_2$249,[createBaseVNode(`div`,_hoisted_3$219,[createBaseVNode(`div`,_hoisted_4$187,toDisplayString(yMaxFormatted.value),1),createBaseVNode(`div`,_hoisted_5$160,[createTextVNode(toDisplayString(__props.config.yAxis.label)+` `,1),__props.config.yAxis.unit?(openBlock(),createElementBlock(`span`,_hoisted_6$138,`(`+toDisplayString(__props.config.yAxis.unit)+`)`,1)):createCommentVNode(``,!0)]),createBaseVNode(`div`,_hoisted_7$120,toDisplayString(yMinFormatted.value),1)])])):createCommentVNode(``,!0),(openBlock(),createElementBlock(`svg`,_hoisted_8$100,[createBaseVNode(`defs`,null,[createBaseVNode(`pattern`,{id:`grid`,width:gridSizes.value.x,height:gridSizes.value.y,patternUnits:`userSpaceOnUse`},[createBaseVNode(`path`,{d:`M ${gridSizes.value.x} 0 L ${gridSizes.value.x} ${gridSizes.value.y}`,stroke:__props.gridColor,"stroke-width":`1`,"vector-effect":`non-scaling-stroke`,opacity:`0.3`},null,8,_hoisted_10$78),createBaseVNode(`path`,{d:`M 0 ${gridSizes.value.y} L 100 ${gridSizes.value.y}`,stroke:__props.gridColor,"stroke-width":`1`,"vector-effect":`non-scaling-stroke`,opacity:`0.3`},null,8,_hoisted_11$70)],8,_hoisted_9$90),createBaseVNode(`pattern`,{id:`subgrid`,width:gridSizes.value.x,height:gridSizes.value.y,patternUnits:`userSpaceOnUse`},[createBaseVNode(`path`,{d:`M ${gridSizes.value.x/__props.subgridDivider} 0 L ${gridSizes.value.x/__props.subgridDivider} ${gridSizes.value.y}`,stroke:__props.gridColor,"stroke-width":`0.5`,"vector-effect":`non-scaling-stroke`,opacity:`0.15`},null,8,_hoisted_13$50),createBaseVNode(`path`,{d:`M 0 ${gridSizes.value.y/__props.subgridDivider} L 100 ${gridSizes.value.y/__props.subgridDivider}`,stroke:__props.gridColor,"stroke-width":`0.5`,"vector-effect":`non-scaling-stroke`,opacity:`0.15`},null,8,_hoisted_14$45)],8,_hoisted_12$58)]),__props.showSubgrid?(openBlock(),createElementBlock(`rect`,_hoisted_15$43)):createCommentVNode(``,!0),_cache[0]||=createBaseVNode(`rect`,{width:`100`,height:`100`,fill:`url(#grid)`},null,-1),createBaseVNode(`g`,_hoisted_16$40,[hasNegativeValues.value?(openBlock(),createElementBlock(`line`,{key:0,x1:`0`,y1:getYPosition(0),x2:`100`,y2:getYPosition(0),stroke:__props.gridColor,"stroke-width":`2`,"vector-effect":`non-scaling-stroke`,opacity:`0.75`},null,8,_hoisted_17$33)):createCommentVNode(``,!0)]),createBaseVNode(`g`,_hoisted_18$30,[(openBlock(!0),createElementBlock(Fragment,null,renderList(__props.ranges,range=>(openBlock(),createElementBlock(`rect`,{key:`range-${range.start}`,x:getXPosition(range.start),y:`-5`,width:getXPosition(range.end)-getXPosition(range.start),height:`110`,fill:range.fill,stroke:range.outline,"stroke-width":`2`,"vector-effect":`non-scaling-stroke`,opacity:range.opacity},null,8,_hoisted_19$25))),128))]),createBaseVNode(`g`,_hoisted_20$21,[(openBlock(!0),createElementBlock(Fragment,null,renderList(__props.verticalGuides,guide=>(openBlock(),createElementBlock(`line`,{key:`guide-${guide.x}`,x1:getXPosition(guide.x),y1:`0`,x2:getXPosition(guide.x),y2:`100`,stroke:guide.color,"stroke-width":`1`,"vector-effect":`non-scaling-stroke`,opacity:guide.opacity},null,8,_hoisted_21$19))),128))]),__props.currentX?(openBlock(),createElementBlock(`line`,{key:1,x1:getXPosition(__props.currentX),y1:`0`,x2:getXPosition(__props.currentX),y2:`100`,stroke:`white`,"stroke-width":`1`,"vector-effect":`non-scaling-stroke`,opacity:`0.8`},null,8,_hoisted_22$17)):createCommentVNode(``,!0),(openBlock(!0),createElementBlock(Fragment,null,renderList(__props.points,dataset=>(openBlock(),createElementBlock(`g`,{key:dataset.label},[dataset.fill?(openBlock(),createElementBlock(`path`,{key:0,d:getAreaPathForDataset(dataset),fill:dataset.color||`white`,opacity:dataset.fillOpacity??.5},null,8,_hoisted_23$16)):createCommentVNode(``,!0),createBaseVNode(`path`,{d:getLinePathForDataset(dataset),stroke:dataset.color||`white`,fill:`none`,"stroke-width":`1`,"vector-effect":`non-scaling-stroke`},null,8,_hoisted_24$15)]))),128))])),__props.singleLabel?(openBlock(),createElementBlock(`div`,{key:1,class:`single-label`,style:normalizeStyle(getLabelStyle())},toDisplayString(__props.singleLabel.text),5)):createCommentVNode(``,!0),__props.config.showLabels?(openBlock(),createElementBlock(`div`,_hoisted_25$14,[createBaseVNode(`div`,_hoisted_26$12,[createBaseVNode(`div`,_hoisted_27$12,toDisplayString(xMinFormatted.value),1),createBaseVNode(`div`,_hoisted_28$11,[createTextVNode(toDisplayString(__props.config.xAxis.label)+` `,1),__props.config.xAxis.unit?(openBlock(),createElementBlock(`span`,_hoisted_29$11,`(`+toDisplayString(__props.config.xAxis.unit)+`)`,1)):createCommentVNode(``,!0)]),createBaseVNode(`div`,_hoisted_30$10,toDisplayString(xMaxFormatted.value),1)])])):createCommentVNode(``,!0)]))}},bngSimpleGraph_default=__plugin_vue_export_helper_default(_sfc_main$344,[[`__scopeId`,`data-v-66d95af3`]]),_hoisted_1$301={class:`bng-slider-container`},_hoisted_2$248=[`disabled`,`min`,`max`,`step`],_sfc_main$343={__name:`bngSlider`,props:{modelValue:Number,origValue:{type:[Number,String],default:NaN},min:{type:[Number,String],default:0},max:{type:[Number,String],required:!0},step:{type:[Number,String],default:0},withReset:{type:Boolean,default:!1},withInput:{type:Boolean,default:!1},inputMultiplier:{type:Number,default:1},unit:{type:String,default:``},disabled:Boolean,uiNavFocus:{type:[Boolean,Object],default:{},validator:val=>typeof val==`boolean`&&!val||typeof val==`object`}},emits:[`change`,`valueChanged`,`update:modelValue`],setup(__props,{expose:__expose,emit:__emit}){let props=__props,emit$1=__emit,slider=ref(null),value=ref(props.modelValue);ref(!1);let uiNavFocusFunction=computed(()=>props.uiNavFocus?{callback:(dir,val)=>{value.value=val,notify()},value:()=>value.value,min:+props.min,max:+props.max,step:()=>+props.step,...props.uiNavFocus}:!1);watch(()=>props.modelValue,val=>{value.value=Number(val),updateSliderBackground()});let dirty=useDirty(value,null,updateSliderBackground),dirtyReset=useDirty(value,null,updateSliderBackground);__expose(dirty);let resetDisabled=computed(()=>props.disabled?!0:isNaN(dirtyReset.currentCleanValue.value)?!dirty.dirty.value:!dirtyReset.dirty.value);onMounted(()=>{updateSliderBackground(),inputProps.value=value.value*props.inputMultiplier});function notify(){emit$1(`update:modelValue`,value.value),emit$1(`valueChanged`,value.value),emit$1(`change`,value.value),updateSliderBackground()}function updateSliderBackground(){if(!slider.value)return;let current=(value.value-props.min)/(props.max-props.min)*100,init$3=[-100,-100],dirtyVal=dirtyReset.currentCleanValue.value;if((typeof dirtyVal!=`number`||isNaN(dirtyVal))&&(dirtyVal=dirty.currentCleanValue.value),typeof dirtyVal==`number`&&!isNaN(dirtyVal)){let initpos=(dirtyVal-props.min)/(props.max-props.min)*100;init$3[currentvalue.value,val=>{inputProps.value=val*props.inputMultiplier}),watch(()=>props.origValue,val=>{val=+val,isNaN(val)||dirtyReset.setCleanValue(val)},{immediate:!0}),watch(()=>inputProps.value,val=>{value.value=val/props.inputMultiplier});function onInputChange(num){num=Number(num);let norm=roundDecSample(num,inputProps.step);num!==norm&&(inputProps.value=norm),num=norm/props.inputMultiplier,num=roundDecSample(num,props.step),numprops.max&&(num=props.max),value.value=num,notify()}function resetValue(){let val=+props.origValue;isNaN(val)?dirty.resetValue():value.value=val,notify()}return(_ctx,_cache)=>withDirectives((openBlock(),createElementBlock(`div`,_hoisted_1$301,[withDirectives(createBaseVNode(`input`,{ref_key:`slider`,ref:slider,class:`bng-slider`,type:`range`,disabled:__props.disabled,"onUpdate:modelValue":_cache[0]||=$event=>value.value=$event,min:+__props.min,max:+__props.max,step:+__props.step,onInput:notify},null,40,_hoisted_2$248),[[vModelText,value.value,void 0,{number:!0}],[unref(BngOnUiNavFocus_default),uiNavFocusFunction.value,void 0,{repeat:!0}]]),__props.withInput?(openBlock(),createBlock(unref(bngInput_default),{key:0,class:`bng-slider-input`,disabled:__props.disabled,modelValue:inputProps.value,"onUpdate:modelValue":_cache[1]||=$event=>inputProps.value=$event,type:`number`,min:inputProps.min,max:inputProps.max,step:inputProps.step,suffix:__props.unit,onValueChanged:onInputChange},null,8,[`disabled`,`modelValue`,`min`,`max`,`step`,`suffix`])):createCommentVNode(``,!0),__props.withReset?(openBlock(),createBlock(unref(bngButton_default),{key:1,class:`bng-slider-reset`,accent:unref(ACCENTS).text,icon:unref(icons).undo,disabled:resetDisabled.value,onClick:resetValue},null,8,[`accent`,`icon`,`disabled`])):createCommentVNode(``,!0)])),[[unref(BngScopedNav_default),{bubbleWhitelistEvents:[`menu`]}],[unref(BngDisabled_default),__props.disabled]])}},bngSlider_default=__plugin_vue_export_helper_default(_sfc_main$343,[[`__scopeId`,`data-v-7d0150a1`]]),_sfc_main$342={__name:`bngSmartSelect`,props:mergeModels({items:{type:Array,required:!0},threshold:{type:Number,default:6},type:{type:String,default:``,validator(val){return[``,`select`,`dropdown`].includes(val)}},highlight:[String,Array,RegExp],disabled:Boolean},{modelValue:{},modelModifiers:{}}),emits:mergeModels([`change`],[`update:modelValue`]),setup(__props,{emit:__emit}){let props=__props,value=useModel(__props,`modelValue`),emit$1=__emit,elDropdown=ref(),elSelect=ref(),types={none:bngSelect_default,select:bngSelect_default,dropdown:bngDropdown_default},items$2=computed(()=>Array.isArray(props.items)?props.items:[]),type=computed(()=>props.type&&props.type in types?props.type:items$2.value.length===0?`none`:items$2.value.length<=props.threshold?`select`:`dropdown`),binds=computed(()=>{let res={disabled:props.disabled};switch(type.value){default:res.options=[`n/a`],res.disabled=!0;break;case`select`:res.loop=!0,res.labelClickable=!0,res.config={label:itm=>itm?.label||`n/a`,value:itm=>itm?.value},res.options=items$2.value.filter(itm=>!itm.disabled&&!itm.group),res.items=items$2.value,res.highlight=props.highlight,res.disabled||=res.options.length===0,res.popoverTarget=elSelect.value?.getElement?.(),res.focusTarget=elSelect.value?.getContentElement?.()||res.popoverTarget;break;case`dropdown`:res.items=items$2.value,res.highlight=props.highlight,res.showSearch=!0;break}return res});function openDropdown(){}function onSelectChanged(newValue){value.value!==newValue&&emit$1(`change`,newValue)}function onDropdownChanged(newValue){value.value!==newValue&&emit$1(`change`,newValue)}return(_ctx,_cache)=>(openBlock(),createElementBlock(Fragment,null,[type.value===`dropdown`?createCommentVNode(``,!0):(openBlock(),createBlock(unref(bngSelect_default),{key:0,ref_key:`elSelect`,ref:elSelect,class:`bng-smart-select`,modelValue:value.value,"onUpdate:modelValue":_cache[0]||=$event=>value.value=$event,options:binds.value.options,config:binds.value.config,disabled:binds.value.disabled,loop:``,"label-clickable":``,"label-popover":elDropdown.value?.popoverName,onLabelClick:openDropdown,onChange:onSelectChanged},null,8,[`modelValue`,`options`,`config`,`disabled`,`label-popover`])),binds.value.items?(openBlock(),createBlock(unref(bngDropdown_default),{key:1,ref_key:`elDropdown`,ref:elDropdown,class:normalizeClass(`bng-smart-${type.value}`),modelValue:value.value,"onUpdate:modelValue":_cache[1]||=$event=>value.value=$event,items:binds.value.items,highlight:binds.value.highlight,disabled:binds.value.disabled,headless:type.value===`select`,"show-search":binds.value.showSearch,"focus-target":binds.value.focusTarget,"popover-target":binds.value.popoverTarget,onValueChanged:onDropdownChanged},null,8,[`class`,`modelValue`,`items`,`highlight`,`disabled`,`headless`,`show-search`,`focus-target`,`popover-target`])):createCommentVNode(``,!0)],64))}},bngSmartSelect_default=__plugin_vue_export_helper_default(_sfc_main$342,[[`__scopeId`,`data-v-a288ad68`]]),_hoisted_1$300=[`xlink:href`],_sfc_main$341={__name:`bngSpriteIcon`,props:{atlasPath:{type:String,default:`sprites/svg-symbols.svg`},src:{type:String,required:!0},color:{type:String,default:`#fff`},deg:{type:Number,default:0}},setup(__props){let props=__props,atlasURL=computed(()=>`${getAssetURL$1(props.atlasPath)}#${props.src.toLowerCase()}`),getAssetURL$1=assetPath=>bngApi.isMock?`http://localhost:9000/${assetPath}`:`/ui/ui-vue/src/assets/${assetPath}`;return(_ctx,_cache)=>(openBlock(),createElementBlock(`svg`,{class:`atlasIcon`,style:normalizeStyle({fill:__props.color,pointerEvents:`none`,transform:`rotate(${__props.deg}deg)`}),version:`1.1`,xmlns:`http://www.w3.org/2000/svg`},[createBaseVNode(`use`,{"xlink:href":atlasURL.value},null,8,_hoisted_1$300)],4))}},bngSpriteIcon_default=__plugin_vue_export_helper_default(_sfc_main$341,[[`__scopeId`,`data-v-0ace1ddc`]]),_hoisted_1$299=[`tabindex`],_hoisted_2$247={key:0};const LABEL_ALIGNMENTS={START:`start`,END:`end`,CENTER:`center`};var _sfc_main$340={__name:`bngSwitch`,props:{modelValue:[Boolean,Number,String],checked:{type:Boolean,default:!1},label:String,labelBefore:Boolean,labelAlignment:{type:String,default:LABEL_ALIGNMENTS.END,validator:value=>Object.values(LABEL_ALIGNMENTS).includes(value)},inline:{type:Boolean,default:!0},alwaysTransparent:Boolean,disabled:Boolean,valueOn:{type:[Boolean,Number,String],default:void 0},valueOff:{type:[Boolean,Number,String],default:void 0}},emits:[`update:modelValue`,`change`,`valueChanged`],setup(__props,{emit:__emit}){let props=__props,emit$1=__emit,slots=useSlots(),bngSwitch=ref(null),valOn=computed(()=>props.valueOn===void 0?!0:props.valueOn),valOff=computed(()=>props.valueOff===void 0?!1:props.valueOff),isSwitchOn=computed(()=>props.modelValue==null?props.checked:props.modelValue===valOn.value);function onClicked(){if(props.disabled)return;let newValue=isSwitchOn.value?valOff.value:valOn.value;props.modelValue!=null&&emit$1(`update:modelValue`,newValue),emit$1(`valueChanged`,newValue),emit$1(`change`,newValue)}return onUpdated(()=>ensureFocus(bngSwitch.value)),(_ctx,_cache)=>withDirectives((openBlock(),createElementBlock(`div`,{ref_key:`bngSwitch`,ref:bngSwitch,"bng-nav-item":``,class:normalizeClass([`bng-switch`,{"bng-switch-on":isSwitchOn.value,"with-background":!__props.alwaysTransparent,"with-label":__props.label||unref(slots).default,"label-position-before":__props.labelBefore,"inline-switch":!__props.label&&!unref(slots).default||__props.inline}]),tabindex:__props.disabled?-1:0,onClick:onClicked},[_cache[0]||=createBaseVNode(`div`,{class:`bng-switch-control`},null,-1),unref(slots).default||__props.label?(openBlock(),createElementBlock(`div`,{key:0,class:normalizeClass([`bng-switch-label`,[`label-alignment-`+__props.labelAlignment]])},[renderSlot(_ctx.$slots,`default`,{},()=>[__props.label?(openBlock(),createElementBlock(`span`,_hoisted_2$247,toDisplayString(__props.label),1)):createCommentVNode(``,!0)],!0)],2)):createCommentVNode(``,!0)],10,_hoisted_1$299)),[[unref(BngOnUiNav_default),void 0,`ok`,{asMouse:!0,focusRequired:!0}],[unref(BngDisabled_default),__props.disabled]])}},bngSwitch_default=__plugin_vue_export_helper_default(_sfc_main$340,[[`__scopeId`,`data-v-8e1c4b05`]]),_hoisted_1$298={class:`bng-switch-label`},_hoisted_2$246={key:0},_sfc_main$339={__name:`bngSwitchOld`,props:{modelValue:Boolean,label:String,checked:Boolean,uncheckedWithBackground:Boolean,disabled:Boolean},emits:[`valueChanged`,`update:modelValue`],setup(__props,{emit:__emit}){let toggleValue=ref(!1),props=__props,emit$1=__emit,slots=useSlots();onBeforeMount(init$3),watch(()=>props.modelValue,init$3),watch(()=>props.checked,init$3),watch(()=>props.disabled,init$3);function init$3(){toggleValue.value=props.checked||props.modelValue}function onValueChanged(){props.disabled||(toggleValue.value=!toggleValue.value,emit$1(`update:modelValue`,toggleValue.value),emit$1(`valueChanged`,toggleValue.value))}return(_ctx,_cache)=>unref(slots).default||__props.label?withDirectives((openBlock(),createElementBlock(`div`,mergeProps({key:0,class:[`bng-labeled-switch`,{"switch-on":toggleValue.value,"with-background":__props.uncheckedWithBackground}]},{...!__props.disabled&&{"bng-nav-item":1}},{tabindex:`{{disabled ? 0 : 1}}`,onClick:onValueChanged,onKeyup:withKeys(onValueChanged,[`space`])}),[_cache[0]||=createBaseVNode(`div`,{class:`bng-switch-wrapper`},[createBaseVNode(`div`,{class:`bng-switch`})],-1),createBaseVNode(`div`,_hoisted_1$298,[renderSlot(_ctx.$slots,`default`,{},()=>[__props.label?(openBlock(),createElementBlock(`label`,_hoisted_2$246,toDisplayString(__props.label),1)):createCommentVNode(``,!0)],!0)])],16)),[[unref(BngDisabled_default),__props.disabled]]):withDirectives((openBlock(),createElementBlock(`div`,mergeProps({key:1},{...!__props.disabled&&{"bng-nav-item":1}},{tabindex:`{{disabled ? 0 : 1}}`,class:[`bng-switch-wrapper`,{"switch-on":toggleValue.value}],onClick:onValueChanged,onKeyup:withKeys(onValueChanged,[`space`])}),[..._cache[1]||=[createBaseVNode(`div`,{class:`bng-switch`},null,-1)]],16)),[[unref(BngDisabled_default),__props.disabled]])}},bngSwitchOld_default=__plugin_vue_export_helper_default(_sfc_main$339,[[`__scopeId`,`data-v-da8dc7b1`]]),_hoisted_1$297={"bng-nav-item":``,class:`bng-tile tile`},_hoisted_2$245={class:`content`},_hoisted_3$218={class:`label`},_sfc_main$338={__name:`bngTile`,props:{label:String,ratio:{type:String,default:`4:3`},backgroundImage:String,backgroundExternalImage:String,disabled:Boolean},setup(__props){return(_ctx,_cache)=>withDirectives((openBlock(),createElementBlock(`div`,_hoisted_1$297,[createVNode(unref(aspectRatio_default),{class:`content-container image`,ratio:__props.ratio,image:__props.backgroundImage,externalImage:__props.backgroundExternalImage,imageMode:`contain`},{default:withCtx(()=>[createBaseVNode(`div`,_hoisted_2$245,[renderSlot(_ctx.$slots,`default`,{},void 0,!0)])]),_:3},8,[`ratio`,`image`,`externalImage`]),renderSlot(_ctx.$slots,`label`,{},()=>[createBaseVNode(`div`,_hoisted_3$218,toDisplayString(__props.label),1)],!0)])),[[unref(BngDisabled_default),__props.disabled]])}},bngTile_default=__plugin_vue_export_helper_default(_sfc_main$338,[[`__scopeId`,`data-v-af5747cc`]]),_sfc_main$337={__name:`bngTooltip`,props:{text:{type:String,required:!0},position:{type:String,default:`top`}},setup(__props){return(_ctx,_cache)=>withDirectives((openBlock(),createElementBlock(`div`,null,[renderSlot(_ctx.$slots,`default`,{},void 0,!0)])),[[unref(BngTooltip_default),__props.text,__props.position]])}},bngTooltip_default=__plugin_vue_export_helper_default(_sfc_main$337,[[`__scopeId`,`data-v-53073c36`]]),toInt=v=>~~+v,_sfc_main$336={__name:`bngUnit`,props:{options:Object,formatter:[Function,String]},setup(__props){let{units}=useBridge(),knownUnits={money:{formatter:v=>units.beamBucks(v)},beamXP:{formatter:toInt},stars:{formatter:toInt},vouchers:{formatter:toInt},insuranceScore:{formatter:toInt},multiplier:{formatter:toInt,noGap:!0}},defaultColors={stars:`var(--bng-ter-yellow-200)`,vouchers:`var(--bng-add-blue-400)`},attrs=useAttrs(),unit=computed(()=>{for(let key of Object.keys(attrs))if(key in knownUnits)return{type:key,value:attrs[key],...knownUnits[key],...props.options};return{type:`unknown`}}),formattedValue=computed(()=>{if(props.formatter){if(typeof props.formatter==`function`)return props.formatter(unit.value.value);if(typeof props.formatter==`string`&&props.formatter in knownUnits)return knownUnits[props.formatter].formatter(unit.value.value)}return typeof unit.value.formatter==`function`?unit.value.formatter(unit.value.value):unit.value.value}),props=__props;return(_ctx,_cache)=>(openBlock(),createBlock(unref(slotSwitcher_default),mergeProps(unref(attrs),{slotId:unit.value.type}),{money:withCtx(props$1=>[createVNode(unref(bngPropVal_default),mergeProps({...props$1,...unit.value},{iconType:props$1.iconType||unref(icons).beamCurrency,valueLabel:formattedValue.value}),null,16,[`iconType`,`valueLabel`])]),beamXP:withCtx(props$1=>[createVNode(unref(bngPropVal_default),mergeProps({...props$1,...unit.value},{iconType:props$1.iconType||unref(icons).beamXPLo,valueLabel:formattedValue.value}),null,16,[`iconType`,`valueLabel`])]),stars:withCtx(props$1=>[createVNode(unref(bngPropVal_default),mergeProps({...props$1,...unit.value},{iconType:props$1.iconType||unref(icons).star,valueLabel:formattedValue.value,"icon-color":defaultColors.stars}),null,16,[`iconType`,`valueLabel`,`icon-color`])]),vouchers:withCtx(props$1=>[createVNode(unref(bngPropVal_default),mergeProps({...props$1,...unit.value},{iconType:props$1.iconType||unref(icons).voucherHorizontal3,valueLabel:formattedValue.value,"icon-color":defaultColors.vouchers}),null,16,[`iconType`,`valueLabel`,`icon-color`])]),insuranceScore:withCtx(props$1=>[createVNode(unref(bngPropVal_default),mergeProps({...props$1,...unit.value},{iconType:props$1.iconType||unref(icons).shieldCheckmarkProgressbar,valueLabel:formattedValue.value}),null,16,[`iconType`,`valueLabel`])]),multiplier:withCtx(props$1=>[createVNode(unref(bngPropVal_default),mergeProps({...props$1,...unit.value},{iconType:props$1.iconType||unref(icons).mathMultiply,valueLabel:formattedValue.value,"icon-color":defaultColors.multiplier}),null,16,[`iconType`,`valueLabel`,`icon-color`])]),unknown:withCtx(props$1=>[createBaseVNode(`span`,normalizeProps(guardReactiveProps(props$1)),`BngUnit: Unknown unit type or no type specified`,16)]),_:1},16,[`slotId`]))}},bngUnit_default=_sfc_main$336;const DEMOS={};var base_exports=__export({ACCENTS:()=>ACCENTS,BngActionDrawer:()=>bngActionDrawer_default,BngActionsDrawer:()=>bngActionsDrawer_default,BngActionsDrawerOne:()=>bngActionsDrawerOne_default,BngActionsList:()=>bngActionsList_default,BngBinding:()=>bngBinding_default,BngBreadcrumbs:()=>bngBreadcrumbs_default,BngButton:()=>bngButton_default,BngCard:()=>bngCard_default,BngCardHeading:()=>bngCardHeading_default,BngColorPicker:()=>bngColorPicker_default,BngColorSlider:()=>bngColorSlider_default,BngColorTile:()=>bngColorTile_default,BngCondition:()=>bngCondition_default,BngControllerHint:()=>bngControllerHint_default,BngDivider:()=>bngDivider_default,BngDrawer:()=>bngDrawer_default,BngDrawerOld:()=>bngDrawerOld_default,BngDropdown:()=>bngDropdown_default,BngDropdownContainer:()=>bngDropdownContainer_default,BngIcon:()=>bngIcon_default,BngIconMarker:()=>bngIconMarker_default,BngImage:()=>bngImage_default,BngImageAsset:()=>bngImageAsset_default,BngImageCarousel:()=>bngImageCarousel_default,BngImageTile:()=>bngImageTile_default,BngInput:()=>bngInput_default,BngInputNew:()=>bngInputNew_default,BngList:()=>bngList_default,BngMainStars:()=>bngMainStars_default,BngMultilineInput:()=>bngMultilineInput_default,BngOldIcon:()=>bngOldIcon_default,BngOverflowContainer:()=>bngOverflowContainer_default,BngPaintTile:()=>bngPaintTile_default,BngPill:()=>bngPill_default,BngPillCheckbox:()=>bngPillCheckbox_default,BngPillFilters:()=>bngPillFilters_default,BngPillFiltersContainer:()=>bngPillFiltersContainer_default,BngPopoverContent:()=>bngPopoverContent_default,BngPopoverMenu:()=>bngPopoverMenu_default,BngProgressBar:()=>bngProgressBar_default,BngPropVal:()=>bngPropVal_default,BngScreenHeading:()=>bngScreenHeading_default,BngScreenHeadingV2:()=>bngScreenHeadingV2_default,BngSelect:()=>bngSelect_default,BngSimpleGraph:()=>bngSimpleGraph_default,BngSlider:()=>bngSlider_default,BngSmartSelect:()=>bngSmartSelect_default,BngSpriteIcon:()=>bngSpriteIcon_default,BngSwitch:()=>bngSwitch_default,BngSwitchOld:()=>bngSwitchOld_default,BngTile:()=>bngTile_default,BngTooltip:()=>bngTooltip_default,BngUnit:()=>bngUnit_default,DEMOS:()=>DEMOS,LABEL_ALIGNMENTS:()=>LABEL_ALIGNMENTS,LIST_LAYOUTS:()=>LIST_LAYOUTS,STEP_ICON_TYPES:()=>STEP_ICON_TYPES,getIconsWithTags:()=>getIconsWithTags,icons:()=>icons,iconsBySize:()=>iconsBySize,iconsByTag:()=>iconsByTag});function getPopupWrapperDefaults(){return{fade:!1,blur:!0,style:[popupContainer.default]}}function getActivityWrapperDefaults(){return{fade:!1,blur:!1,style:[popupContainer.clickthrough]}}const popupContainer=Object.freeze({default:`default`,transparent:`transparent`,clickthrough:`clickthrough`}),popupPosition=Object.freeze({default:`center`,top:`top`,left:`left`,right:`right`,bottom:`bottom`,center:`center`,fullscreen:`fullscreen`});var _hoisted_1$296=[`bng-ui-scope`],_hoisted_2$244={class:`popup-content`},_hoisted_3$217={key:0,class:`popup-title`},_hoisted_4$186={key:1,class:`popup-body`},_hoisted_5$159=[`innerHTML`],_hoisted_6$137={class:`popup-buttons`},__default__$10={wrapper:{blur:!0,style:null},position:popupPosition.center,animated:!0},_sfc_main$335=Object.assign(__default__$10,{__name:`Confirmation`,props:{appearance:String,popupActive:Boolean,message:{type:[String,Object],required:!0},title:String,buttons:Array},emits:[`return`],setup(__props,{emit:__emit}){useUINavBlocker().allowNavigationOnly();let props=__props,emit$1=__emit,scopeName=usePopupUINavScopeName(`_confirmPopup`,props),defaultButtonIndex=props.buttons.findIndex(button=>button.extras&&button.extras.default);defaultButtonIndex===-1&&(defaultButtonIndex=0);let cancelButton=props.buttons.find(button=>button.extras&&button.extras.cancel),exclude=[`default`,`cancel`],buttonProps=computed(()=>{let bp=[];for(let{extras}of props.buttons)extras?bp.push(Object.keys(extras).reduce((ex,key)=>exclude.includes(key)?ex:{...ex,[key]:extras[key]},{})):bp.push({});return bp}),messageIsComponent=computed(()=>props.message&&typeof props.message==`object`&&props.message.component),handleCancelWithBack=()=>emit$1(`return`,cancelButton?cancelButton.value:null);return(_ctx,_cache)=>withDirectives((openBlock(),createElementBlock(`div`,{class:normalizeClass([`popup`,`popup-style-`+__props.appearance]),"bng-ui-scope":unref(scopeName)},[createBaseVNode(`div`,_hoisted_2$244,[__props.title?(openBlock(),createElementBlock(`div`,_hoisted_3$217,toDisplayString(__props.title),1)):createCommentVNode(``,!0),messageIsComponent.value?(openBlock(),createElementBlock(`div`,_hoisted_4$186,[(openBlock(),createBlock(resolveDynamicComponent(__props.message.component),normalizeProps(guardReactiveProps(__props.message.props)),null,16))])):(openBlock(),createElementBlock(`div`,{key:2,class:`popup-body`,innerHTML:__props.message},null,8,_hoisted_5$159)),createBaseVNode(`div`,_hoisted_6$137,[(openBlock(!0),createElementBlock(Fragment,null,renderList(__props.buttons,(button,index)=>withDirectives((openBlock(),createBlock(unref(bngButton_default),mergeProps({key:index},{ref_for:!0},buttonProps.value[index],{onClick:$event=>_ctx.$emit(`return`,button.value)}),{default:withCtx(()=>[createTextVNode(toDisplayString(button.label),1)]),_:2},1040,[`onClick`])),[[unref(BngUiNavFocus_default),index===unref(defaultButtonIndex)?1e3:void 0]])),128))])])],10,_hoisted_1$296)),[[unref(BngOnUiNav_default),handleCancelWithBack,`back,menu`]])}}),Confirmation_default=__plugin_vue_export_helper_default(_sfc_main$335,[[`__scopeId`,`data-v-ce4a758b`]]),_hoisted_1$295=[`bng-ui-scope`],_hoisted_2$243={key:0,class:`form-dialog-toolbar`},_hoisted_3$216={class:`toolbar-title`},_hoisted_4$185={key:0,class:`content-description`},_hoisted_5$158={class:`content-wrapper`},_hoisted_6$136={class:`form-actions-bar`},_sfc_main$334={__name:`FormDialog`,props:mergeModels({title:{type:String},description:{type:String},view:{type:[Object,String],required:!0},formValidator:{type:Function,default:formModel=>!0},buttons:{type:Array,required:!0},maxWidth:{type:String,default:`40rem`}},{formModel:{},formModelModifiers:{}}),emits:mergeModels([`return`],[`update:formModel`]),setup(__props,{emit:__emit}){useUINavBlocker().allowOnly([`focus_u`,`focus_d`,`focus_l`,`focus_r`,`back`,`menu`,`ok`]);let props=__props,emit$1=__emit,formModel=useModel(__props,`formModel`),scopeName=usePopupUINavScopeName(`_formdialog`,props),handleCancelWithBack=()=>{let cancelButton=props.buttons.find(x=>x.extras&&x.extras.cancel);cancelButton?onClick(cancelButton):emit$1(`return`)},onClick=button=>{let data={value:button.value};button.emitData&&(data.formData=formModel.value),emit$1(`return`,data)},formValid=ref(!1),message=ref(null);return watch(formModel,()=>{let res=props.formValidator(formModel.value);message.value=res.error?res.message:props.description,formValid.value=!res.error},{immediate:!0,deep:!0}),(_ctx,_cache)=>withDirectives((openBlock(),createElementBlock(`div`,{class:`form-dialog`,style:normalizeStyle({maxWidth:props.maxWidth}),"bng-ui-scope":unref(scopeName)},[__props.title?(openBlock(),createElementBlock(`div`,_hoisted_2$243,[createBaseVNode(`div`,_hoisted_3$216,toDisplayString(__props.title),1)])):createCommentVNode(``,!0),createBaseVNode(`div`,{class:normalizeClass([{"no-title":!__props.title},`form-dialog-content`])},[message.value?(openBlock(),createElementBlock(`div`,_hoisted_4$185,toDisplayString(message.value),1)):createCommentVNode(``,!0),createBaseVNode(`div`,_hoisted_5$158,[(openBlock(),createBlock(resolveDynamicComponent(__props.view),{modelValue:formModel.value,"onUpdate:modelValue":_cache[0]||=$event=>formModel.value=$event},null,8,[`modelValue`]))])],2),createBaseVNode(`div`,_hoisted_6$136,[(openBlock(!0),createElementBlock(Fragment,null,renderList(__props.buttons,(button,index)=>withDirectives((openBlock(),createBlock(unref(bngButton_default),mergeProps({key:index},{ref_for:!0},button.extras,{disabled:button.disableIfInvalid&&!formValid.value,onClick:$event=>onClick(button)}),{default:withCtx(()=>[createTextVNode(toDisplayString(button.label),1)]),_:2},1040,[`disabled`,`onClick`])),[[unref(BngUiNavFocus_default),__props.buttons.length-index],[unref(BngFocusIf_default),index===0]])),128))])],12,_hoisted_1$295)),[[unref(BngOnUiNav_default),handleCancelWithBack,`back,menu`]])}},FormDialog_default=__plugin_vue_export_helper_default(_sfc_main$334,[[`__scopeId`,`data-v-e78a3aa6`]]),_hoisted_1$294=[`bng-ui-scope`],_hoisted_2$242={class:`popup-content`},_hoisted_3$215={key:0,class:`popup-title`},_hoisted_4$184={class:`popup-body`},_hoisted_5$157={key:0,class:`popup-message`},_hoisted_6$135={class:`popup-buttons`},_sfc_main$333={__name:`Progress`,props:{title:String,message:String,buttons:Array,indeterminate:Boolean,min:{type:Number,default:0},max:{type:Number,default:100},initialValue:{type:Number,default:0},valueLabelFormat:{type:[String,Function],default:()=>val=>`${val}%`},timeout:{type:Number,default:0},cancellable:Boolean,tunnel:Object},emits:[`return`],setup(__props,{emit:__emit}){useUINavBlocker().allowOnly([`focus_u`,`focus_d`,`focus_l`,`focus_r`,`back`,`menu`,`ok`]);let emit$1=__emit,DEFAULT_BUTTON_ID=uniqueId(`___DEFAULT`,`_`),props=__props,defaultButtonIndex=props.buttons.findIndex(button=>button.extras&&button.extras.default),cancelButton=props.buttons.find(button=>button.extras&&button.extras.cancel);~defaultButtonIndex&&onMounted(()=>{document.querySelector(`#${DEFAULT_BUTTON_ID}`).focus()});let scopeName=usePopupUINavScopeName(`_progressPopup`,props),progressValue=ref(props.initialValue),msg=ref(props.message),handleCancelWithBack=e=>{props.cancellable&&close()},close=()=>emit$1(`return`,cancelButton?cancelButton.value:null);return props.tunnel.update=(value,message=void 0)=>{progressValue.value=+value,message!==void 0&&(msg.value=message)},props.tunnel.done=close,props.tunnel.ready=!0,props.timeout&&setTimeout(close,props.timeout*1e3),(_ctx,_cache)=>withDirectives((openBlock(),createElementBlock(`div`,{class:normalizeClass([`popup`]),"bng-ui-scope":unref(scopeName)},[createBaseVNode(`div`,_hoisted_2$242,[__props.title?(openBlock(),createElementBlock(`div`,_hoisted_3$215,toDisplayString(__props.title),1)):createCommentVNode(``,!0),createBaseVNode(`div`,_hoisted_4$184,[msg.value?(openBlock(),createElementBlock(`div`,_hoisted_5$157,toDisplayString(msg.value),1)):createCommentVNode(``,!0),createVNode(unref(bngProgressBar_default),{value:progressValue.value,min:__props.min,max:__props.max,indeterminate:__props.indeterminate,"show-value-label":!__props.indeterminate&&!!__props.valueLabelFormat,"value-label-format":__props.valueLabelFormat},null,8,[`value`,`min`,`max`,`indeterminate`,`show-value-label`,`value-label-format`])]),createBaseVNode(`div`,_hoisted_6$135,[__props.buttons&&__props.buttons.length?(openBlock(!0),createElementBlock(Fragment,{key:0},renderList(__props.buttons,(button,index)=>(openBlock(),createBlock(unref(bngButton_default),mergeProps({key:index},{ref_for:!0},{...index==unref(defaultButtonIndex)&&{id:unref(DEFAULT_BUTTON_ID)},...button.extras},{onClick:$event=>_ctx.$emit(`return`,typeof button.value==`function`?button.value(_ctx.text):button.value)}),{default:withCtx(()=>[createTextVNode(toDisplayString(button.label),1)]),_:2},1040,[`onClick`]))),128)):createCommentVNode(``,!0)])])],8,_hoisted_1$294)),[[unref(BngOnUiNav_default),handleCancelWithBack,`back,menu`]])}},Progress_default=__plugin_vue_export_helper_default(_sfc_main$333,[[`__scopeId`,`data-v-a3c03360`]]),_hoisted_1$293=[`bng-ui-scope`],_hoisted_2$241={class:`popup-content`},_hoisted_3$214={key:0,class:`popup-title`},_hoisted_4$183={class:`popup-body`},_hoisted_5$156={key:0,class:`popup-message`},_hoisted_6$134={class:`popup-buttons`},_sfc_main$332={__name:`Prompt`,props:{buttons:Array,message:String,title:String,maxLength:Number,defaultValue:void 0,validate:Function,errorMessage:String,disableWhenInvalid:Boolean},emits:[`return`],setup(__props,{emit:__emit}){let emit$1=__emit,DEFAULT_BUTTON_ID=uniqueId(`___DEFAULT`,`_`),INPUT_ID=uniqueId(`___INPUT`,`_`),props=__props,scopeName=usePopupUINavScopeName(`_promptPopup`,props),text=ref(props.defaultValue||``),defaultButtonIndex=props.buttons.findIndex(button=>button.extras&&button.extras.default),cancelButton=props.buttons.find(button=>button.extras&&button.extras.cancel),handleEnterButton=text$1=>{props.disableWhenInvalid&&props.validate&&!props.validate(text$1)||emit$1(`return`,text$1)},handleCancelWithBack=e=>{emit$1(`return`,cancelButton?cancelButton.value:null)};return onMounted(()=>{document.querySelector(`#${INPUT_ID} input`).focus()}),(_ctx,_cache)=>withDirectives((openBlock(),createElementBlock(`div`,{class:normalizeClass([`popup`]),"bng-ui-scope":unref(scopeName)},[createBaseVNode(`div`,_hoisted_2$241,[__props.title?(openBlock(),createElementBlock(`div`,_hoisted_3$214,toDisplayString(__props.title),1)):createCommentVNode(``,!0),createBaseVNode(`div`,_hoisted_4$183,[__props.message?(openBlock(),createElementBlock(`div`,_hoisted_5$156,toDisplayString(__props.message),1)):createCommentVNode(``,!0),createVNode(unref(bngInput_default),{id:unref(INPUT_ID),modelValue:text.value,"onUpdate:modelValue":_cache[0]||=$event=>text.value=$event,maxlength:__props.maxLength,onKeyup:_cache[1]||=withKeys($event=>handleEnterButton(text.value),[`enter`]),validate:__props.validate,"error-message":__props.errorMessage},null,8,[`id`,`modelValue`,`maxlength`,`validate`,`error-message`])]),createBaseVNode(`div`,_hoisted_6$134,[(openBlock(!0),createElementBlock(Fragment,null,renderList(__props.buttons,(button,index)=>(openBlock(),createBlock(unref(bngButton_default),mergeProps({key:index},{ref_for:!0},{...index==unref(defaultButtonIndex)&&{id:unref(DEFAULT_BUTTON_ID)},...button.extras},{disabled:__props.disableWhenInvalid&&index>0&&__props.validate&&!__props.validate(text.value),onClick:$event=>_ctx.$emit(`return`,typeof button.value==`function`?button.value(text.value):button.value)}),{default:withCtx(()=>[createTextVNode(toDisplayString(button.label),1)]),_:2},1040,[`disabled`,`onClick`]))),128))])])],8,_hoisted_1$293)),[[unref(BngOnUiNav_default),handleCancelWithBack,`back,menu`]])}},Prompt_default=__plugin_vue_export_helper_default(_sfc_main$332,[[`__scopeId`,`data-v-cce4437b`]]),__default__$9={position:popupPosition.left},_sfc_main$331=Object.assign(__default__$9,{__name:`ScreenOverlay`,props:{view:Object},emits:[`return`],setup(__props){return(_ctx,_cache)=>(openBlock(),createBlock(resolveDynamicComponent(__props.view),{onClose:_cache[0]||=$event=>_ctx.$emit(`return`,!0)},null,32))}}),ScreenOverlay_default=_sfc_main$331,popup_components_exports=__export({Confirmation:()=>Confirmation_default,FormDialog:()=>FormDialog_default,Progress:()=>Progress_default,Prompt:()=>Prompt_default,ScreenOverlay:()=>ScreenOverlay_default}),popupLimit=5,activityLimit=3,count=-1;const PopupTypes=Object.freeze({activity:10,normal:100,priority:1e3});var PopupTypesBack=Object.freeze(Object.keys(PopupTypes).reduce((res,key)=>({...res,[String(PopupTypes[key])]:key}),{})),PopupTypesPairs=Object.freeze(Object.keys(PopupTypes).map(key=>[PopupTypes[key],key]).sort((a$1,b)=>a$1[0]-b[0]));function getPopupTypeName(type=PopupTypes.normal){let strType=String(type);if(strType in PopupTypesBack)return PopupTypesBack[strType];for(let[ptype,pname]of PopupTypesPairs)if(typepopupsAll.filter(itm=>itm.type>=PopupTypes.normal)),activitiesFiltered=computed(()=>popupsAll.filter(itm=>itm.typepopupsFiltered.value.length>0?popupsFiltered.value.slice(-popupLimit):null),popupsWrapper:computed(()=>accumulateWrapper(popupsFiltered.value,getPopupWrapperDefaults())),activities:computed(()=>activitiesFiltered.value.length>0?activitiesFiltered.value.slice(-activityLimit):null),activitiesWrapper:computed(()=>accumulateWrapper(activitiesFiltered.value,getActivityWrapperDefaults()))});function accumulateWrapper(popups,wrapper){for(let popup of popups)wrapper.fade!==popup.wrapper.fade&&(wrapper.fade=popup.wrapper.fade),wrapper.blur!==popup.wrapper.blur&&(wrapper.blur=popup.wrapper.blur),popup.wrapper.style&&wrapper.style.push(...popup.wrapper.style);return wrapper}function addPopup(componentOrName,props={},type=PopupTypes.normal){let component=typeof componentOrName==`string`?popup_components_exports[componentOrName]:componentOrName;if(!component)throw Error(`There is no popup base component named "${componentOrName}".Available components: "${Object.keys(popup_components_exports).join(`", "`)}"`);let popup={id:++count,active:!1,type,typeName:getPopupTypeName(type),component:markRaw({ref:component}),componentName:component.__name,props:{__id:count,...props},position:[popupPosition.default],animated:!0,wrapper:type>=PopupTypes.normal?getPopupWrapperDefaults():getActivityWrapperDefaults()};component.position&&(popup.position=Array.isArray(component.position)?component.position:[component.position]),typeof component.animated==`boolean`&&(popup.animated=component.animated),`wrapper`in component&&(typeof component.wrapper.fade==`boolean`&&(popup.wrapper.fade=component.wrapper.fade),typeof component.wrapper.blur==`boolean`&&(popup.wrapper.blur=component.wrapper.blur),component.wrapper.style&&(popup.wrapper.style=Array.isArray(component.wrapper.style)?component.wrapper.style:[component.wrapper.style])),popup.promise=new Promise((resolve$1,reject)=>{popup._resolve=resolve$1,popup._reject=reject}),popup.return=result=>{for(let i=0;i0&&(popupsAll[popupsAll.length-1].active=!0),reportPopupState(popup,!1);break}result===void 0?popup._reject():popup._resolve(result)},popup.promise.close=popup.return;for(let i=0;itype)return popupsAll.splice(i,0,popup),reportPopupState(popup,!0),popup;return popupsAll.length>0&&(popupsAll[popupsAll.length-1].active=!1),popup.active=!0,popupsAll.push(popup),reportPopupState(popup,!0),popup}function closeLastPopups(count$1=1){popupsAll.slice(-count$1).forEach(popup=>popup.return())}const openMessage=(title,message)=>addPopup(`Confirmation`,{title,message,buttons:[{label:$translate.instant(`ui.common.okay`),value:!0,extras:{default:!0}}]}).promise,openConfirmation=(title,message,buttons=[{label:$translate.instant(`ui.common.okay`),value:!0,extras:{default:!0}},{label:$translate.instant(`ui.common.cancel`),value:!1,extras:{cancel:!0,accent:ACCENTS.secondary}}],appearance=``)=>addPopup(`Confirmation`,{title,message,buttons,appearance}).promise,openPrompt=(message=``,title=``,{buttons=[{label:$translate.instant(`ui.common.okay`),value:text=>text},{label:$translate.instant(`ui.common.cancel`),value:!1,extras:{cancel:!0,accent:ACCENTS.secondary}}],defaultValue,maxLength,validate,errorMessage,disableWhenInvalid}={})=>addPopup(`Prompt`,{message,title,buttons,defaultValue,maxLength,validate,errorMessage,disableWhenInvalid}).promise,openExperimental=(title,message,buttons=[{label:$translate.instant(`ui.common.yes`),value:!0},{label:$translate.instant(`ui.common.no`),value:!1}])=>addPopup(`Confirmation`,{title,message,buttons,appearance:`experimental`}).promise,openScreenOverlay=component=>addPopup(`ScreenOverlay`,{view:markRaw(component)},PopupTypes.activity).promise,openFormDialog=(component,formModel,formValidator,title,description,buttons=[{label:$translate.instant(`ui.common.okay`),value:!0,emitData:!0},{label:$translate.instant(`ui.common.cancel`),value:!1,extras:{cancel:!0,accent:ACCENTS.secondary}}],maxWidth)=>addPopup(`FormDialog`,{view:markRaw(component),formModel,formValidator,title,description,buttons,maxWidth},PopupTypes.normal).promise,openProgress=(message=``,title=``,{buttons=[],indeterminate,min:min$1,max:max$1,initialValue,valueLabelFormat,timeout,cancellable}={})=>{let popup=addPopup(`Progress`,{message,title,buttons,indeterminate,min:min$1,max:max$1,initialValue,valueLabelFormat,timeout,cancellable,tunnel:{}});return popup.progress=popup.props.tunnel,popup.progress.done=popup.return,popup},fixedDelayPopup=(seconds,{makeRemainingText=s=>s?Math.round(s)+`s remaining...`:`Done!`,title=``}={})=>{let popup=openProgress(makeRemainingText(seconds),title,{timeout:seconds+1}),remaining=seconds,endTime=Date.now()+remaining*1e3,countdown=()=>{let timeLeft=(endTime-Date.now())/1e3;timeLeft>0?(remaining=timeLeft,requestAnimationFrame(countdown)):remaining=0,popup.progress.update(~~((seconds-remaining)*100/seconds),makeRemainingText(remaining))};return requestAnimationFrame(countdown),popup};var _hoisted_1$292={class:`activity-selector`},_hoisted_2$240={class:`activities-container`},_hoisted_3$213=[`onClick`],_hoisted_4$182={class:`selector-display`},selectConfig={label:x=>x.label,value:x=>x.value},_sfc_main$330={__name:`ActivitySelector`,props:{activities:{type:Array,required:!0},value:{type:[String,Number]},navLeftEvent:{type:String},navRightEvent:{type:String}},emits:[`valueChanged`],setup(__props,{expose:__expose,emit:__emit}){let props=__props,selectComponent=ref(),emit$1=__emit,activityOptions=computed(()=>props.activities.map((x,index)=>({label:index+1,value:x.value})));computed(()=>(activityOptions.value?activityOptions.value.find(x=>x.value===selectedValue.value):null)||{label:`?`,value:selectedValue.value});let selectedValue=ref(1);watch(()=>props.value,val=>selectedValue.value=val||props.activities[0].value,{immediate:!0});let onValueChanged=value=>{selectedValue.value=value,console.log(`onValueChanged`,value),emit$1(`valueChanged`,value)};return __expose({goNext:()=>selectComponent.value.goNext(),goPrev:()=>selectComponent.value.goPrev()}),computed(()=>`url("${getAssetURL(`icons/temp_debug/map_poi_target.svg`)}")`),(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$292,[createBaseVNode(`div`,_hoisted_2$240,[(openBlock(!0),createElementBlock(Fragment,null,renderList(__props.activities,activity=>(openBlock(),createElementBlock(`div`,{key:activity,class:normalizeClass([`activity-icon`,{highlighted:activity.value===selectedValue.value}]),onClick:$event=>onValueChanged(activity.value)},[createVNode(unref(bngSpriteIcon_default),{src:`map_`+activity.icon,style:{width:`100%`,height:`100%`}},null,8,[`src`])],10,_hoisted_3$213))),128))]),createVNode(unref(bngSelect_default),{ref_key:`selectComponent`,ref:selectComponent,value:selectedValue.value,options:activityOptions.value,config:selectConfig,mute:``,loop:``,onChange:onValueChanged,navLeftEvent:__props.navLeftEvent,navRightEvent:__props.navRightEvent},{display:withCtx(({label})=>[createBaseVNode(`div`,_hoisted_4$182,[createBaseVNode(`span`,null,toDisplayString(label),1),createVNode(unref(bngDivider_default)),createBaseVNode(`span`,null,toDisplayString(__props.activities.length),1)])]),_:1},8,[`value`,`options`,`navLeftEvent`,`navRightEvent`])]))}},ActivitySelector_default=__plugin_vue_export_helper_default(_sfc_main$330,[[`__scopeId`,`data-v-53fb9327`]]),_hoisted_1$291={key:0,class:`activity-start`,"bng-ui-scope":`activityStart`},_hoisted_2$239={class:`activity-props`},_hoisted_3$212={class:`binding-spacer`},BNG_MAIN_STARS_TYPE=`BngMainStars`,_sfc_main$329={__name:`ActivityStart`,setup(__props){useUINavScope(`activityStart`);let activitySelector=ref(null),goNext=()=>activitySelector.value&&activitySelector.value.goNext(),goPrev=()=>activitySelector.value&&activitySelector.value.goPrev(),gameContextStore=useGameContextStore(),{activities}=storeToRefs(gameContextStore),{closeActivitiesPrompt}=gameContextStore,selectedActivityIndex=ref(0),availableActivities=ref([]),activityOptions=computed(()=>{let result=availableActivities.value?availableActivities.value.map((x,index)=>({id:index,value:index,icon:x.icon})):[];return doFiltering&&filterEvents(result.length>1),result}),selectedActivity=computed(()=>{if(selectedActivityIndex.value<0||!availableActivities.value||availableActivities.value.length===0)return null;let activity=availableActivities.value[selectedActivityIndex.value],labels=activity.props&&activity.props.length>0?activity.props.filter(x=>!x.type):[];return{heading:activity.heading,icon:activity.icon,preheadings:activity.preheadings,labels:labels.map(x=>({keyLabel:$translate.instant(x.keyLabel),valueLabel:$translate.instant(x.valueLabel),icon:icons[x.icon]})),stars:activity.props&&activity.props.length>0?activity.props.find(x=>x.type===BNG_MAIN_STARS_TYPE):null,startable:!0,buttonLabel:activity.buttonLabel,action:activity.action,missionInfoPerformActionIndex:activity.missionInfoPerformActionIndex}}),preheadings=computed(()=>selectedActivity.value&&selectedActivity.value.preheadings?selectedActivity.value.preheadings.map(x=>$translate.contextTranslate(x)):[]),invokeActivityAction=()=>{Lua_default.ui_missionInfo.performActivityAction(selectedActivity.value.missionInfoPerformActionIndex)};watch(selectedActivity,()=>{Lua_default.ui_missionInfo.setActivityIndexVisible(selectedActivityIndex.value)});let onActivitySelected=value=>{selectedActivityIndex.value=value},onCancel=()=>{closeActivitiesPrompt()},openPauseMenu=()=>{onCancel(),window.globalAngularRootScope&&window.globalAngularRootScope.$broadcast(`MenuToggle`)};onBeforeMount(()=>{availableActivities.value=activities.value}),onMounted(()=>{getUINavServiceInstance().activate()}),onUnmounted(()=>{doFiltering=!1,getUINavServiceInstance().setFilteredEventsAllExcept(UI_EVENTS.menu,UI_EVENTS.pause,UI_EVENTS.center_cam),Lua_default.ui_missionInfo.setActivityIndexVisible(-1)});let doFiltering=!0,filterEvents=withTabs=>getUINavServiceInstance().setFilteredEventsAllExcept(UI_EVENTS.back,UI_EVENTS.menu,UI_EVENTS.pause,UI_EVENTS.center_cam,...withTabs?[UI_EVENTS.tab_l,UI_EVENTS.tab_r]:[]);return(_ctx,_cache)=>selectedActivity.value?withDirectives((openBlock(),createElementBlock(`div`,_hoisted_1$291,[activityOptions.value&&activityOptions.value.length>1?(openBlock(),createBlock(ActivitySelector_default,{key:0,ref_key:`activitySelector`,ref:activitySelector,activities:activityOptions.value,value:selectedActivityIndex.value,onValueChanged:onActivitySelected,navLeftEvent:`tab_l`,navRightEvent:`tab_r`},null,8,[`activities`,`value`])):createCommentVNode(``,!0),selectedActivity.value.heading?(openBlock(),createBlock(unref(bngScreenHeading_default),{key:1,mute:``,divider:``,preheadings:preheadings.value,"blur-delay":400},{default:withCtx(()=>[createTextVNode(toDisplayString(_ctx.$ctx_t(selectedActivity.value.heading)),1),selectedActivity.value.description?(openBlock(),createElementBlock(Fragment,{key:0},[createTextVNode(`: `+toDisplayString(_ctx.$ctx_t(selectedActivity.value.description)),1)],64)):createCommentVNode(``,!0)]),_:1},8,[`preheadings`])):createCommentVNode(``,!0),createBaseVNode(`div`,_hoisted_2$239,[selectedActivity.value.stars&&selectedActivity.value.stars.defaultStarCount?(openBlock(),createBlock(unref(bngMainStars_default),{key:0,"unlocked-stars":selectedActivity.value.stars.defaultUnlockedStarCount,"total-stars":selectedActivity.value.stars.defaultStarCount,class:`main-stars`},null,8,[`unlocked-stars`,`total-stars`])):createCommentVNode(``,!0),selectedActivity.value.stars&&selectedActivity.value.stars.bonusStarCount?(openBlock(),createBlock(unref(bngMainStars_default),{key:1,"unlocked-stars":selectedActivity.value.stars.bonusStarsUnlockedCount,"total-stars":selectedActivity.value.stars.bonusStarCount,class:`bonus-stars`},null,8,[`unlocked-stars`,`total-stars`])):createCommentVNode(``,!0),(openBlock(!0),createElementBlock(Fragment,null,renderList(selectedActivity.value.labels,(label,index)=>(openBlock(),createBlock(unref(bngPropVal_default),{key:index,iconType:label.icon,keyLabel:label.keyLabel,valueLabel:label.valueLabel},null,8,[`iconType`,`keyLabel`,`valueLabel`]))),128))]),createBaseVNode(`div`,null,[withDirectives((openBlock(),createBlock(unref(bngButton_default),{accent:unref(ACCENTS).main,onClick:invokeActivityAction},{default:withCtx(()=>[createBaseVNode(`span`,_hoisted_3$212,[createVNode(unref(bngBinding_default),{action:`gameplay_interact`})]),selectedActivity.value.startable?(openBlock(),createElementBlock(Fragment,{key:0},[createTextVNode(toDisplayString(_ctx.$ctx_t(selectedActivity.value.buttonLabel)),1)],64)):(openBlock(),createElementBlock(Fragment,{key:1},[createTextVNode(toDisplayString(_ctx.$tt(`ui.mission.action.locked`)),1)],64))]),_:1},8,[`accent`])),[[unref(BngOnUiNav_default),void 0,`gameplay_interact`,{asMouse:!0}]]),withDirectives((openBlock(),createBlock(unref(bngButton_default),{accent:unref(ACCENTS).secondary,onClick:onCancel},{default:withCtx(()=>[createVNode(unref(bngBinding_default),{"ui-event":`back`,controller:``}),createTextVNode(` `+toDisplayString(_ctx.$tt(`ui.common.close`)),1)]),_:1},8,[`accent`])),[[unref(BngOnUiNav_default),void 0,`back`,{asMouse:!0}]])])])),[[unref(BngOnUiNav_default),goPrev,`tab_l`,{up:!0}],[unref(BngOnUiNav_default),goNext,`tab_r`,{up:!0}],[unref(BngOnUiNav_default),openPauseMenu,`menu`]]):createCommentVNode(``,!0)}},ActivityStart_default=__plugin_vue_export_helper_default(_sfc_main$329,[[`__scopeId`,`data-v-1f131cb6`]]),_hoisted_1$290={class:`recovery-wrapper`,"bng-ui-scope":`recoveryPrompt`},_hoisted_2$238={class:`content`},_hoisted_3$211={class:`label`},_hoisted_4$181={key:0,class:`more-options`},_hoisted_5$155={key:0,class:`notification`},__default__$8={wrapper:{fade:!0,blur:!0,style:popupContainer.transparent},position:[popupPosition.center,popupPosition.center]},_sfc_main$328=Object.assign(__default__$8,{__name:`Recovery`,emits:[`return`],setup(__props,{emit:__emit}){let{events:events$3}=useBridge();useUINavScope(`recoveryPrompt`);let emit$1=__emit,{closeRecoveryPrompt}=useGameContextStore(),popupData=ref({}),clickHandler=(index,button,fromController)=>{button.confirmationText||executeButtonAction(index,button)},executeButtonAction=(index,button)=>{Lua_default.core_recoveryPrompt.uiPopupButtonPressed(index+1),button.keepMenuOpen||(closeRecoveryPrompt(),emit$1(`return`,!0))},cancelClickHandler=()=>{Lua_default.core_recoveryPrompt.uiPopupCancelPressed(),popupData.value.cancelButton.keepMenuOpen||(closeRecoveryPrompt(),emit$1(`return`,!0))},updateRecoveryPopupData=()=>{Lua_default.core_recoveryPrompt.getUIData().then(value=>popupData.value=value)};return events$3.on(`updateRecoveryPopupData`,updateRecoveryPopupData),onMounted(()=>{getUINavServiceInstance().activate(),getUINavServiceInstance().clearFilteredEvents(),updateRecoveryPopupData()}),onUnmounted(()=>{events$3.off(`updateRecoveryPopupData`,updateRecoveryPopupData),window.bngVue.getCurrentRoute().name==`unknown`&&getUINavServiceInstance().setFilteredEventsAllExcept(UI_EVENTS.menu,UI_EVENTS.pause,UI_EVENTS.center_cam)}),(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$290,[createVNode(unref(bngCard_default),null,{buttons:withCtx(()=>[unref(popupData).cancelButton?withDirectives((openBlock(),createBlock(unref(bngButton_default),{key:0,label:unref(popupData).cancelButton.label,accent:unref(ACCENTS).attention,onClick:cancelClickHandler},null,8,[`label`,`accent`])),[[unref(BngOnUiNav_default),void 0,`back,menu`,{asMouse:!0}]]):createCommentVNode(``,!0)]),default:withCtx(()=>[createVNode(unref(bngCardHeading_default),{type:`ribbon`},{default:withCtx(()=>[createTextVNode(toDisplayString(unref(popupData).title),1)]),_:1}),createBaseVNode(`div`,_hoisted_2$238,[(openBlock(!0),createElementBlock(Fragment,null,renderList(unref(popupData).buttons,(button,index)=>withDirectives((openBlock(),createBlock(unref(bngButton_default),{"show-hold":!!button.confirmationText,"hold-vertical":``,accent:unref(ACCENTS).outlined,class:`recovery-option-button`},{default:withCtx(()=>[createVNode(unref(bngImageTile_default),{class:`recovery-option-tile`,icon:unref(icons)[button.icon]},{default:withCtx(()=>[createBaseVNode(`span`,_hoisted_3$211,toDisplayString(_ctx.$ctx_t(button.label)),1),button.price?(openBlock(),createBlock(unref(bngDivider_default),{key:0})):createCommentVNode(``,!0),button.price?(openBlock(),createBlock(unref(bngUnit_default),{key:1,class:`units`,money:button.price.money.amount,options:{formatter:x=>~~x}},null,8,[`money`,`options`])):createCommentVNode(``,!0)]),_:2},1032,[`icon`]),button.keepMenuOpen?(openBlock(),createElementBlock(`span`,_hoisted_4$181,`⇢`)):createCommentVNode(``,!0)]),_:2},1032,[`show-hold`,`accent`])),[[unref(BngDisabled_default),!button.enabled],[unref(BngFocusIf_default),!index||button.enabled&&!unref(popupData).buttons[0].enabled],[unref(BngOnUiNav_default),void 0,`ok`,{asMouse:!0,focusRequired:!0}],[unref(BngClick_default),{clickCallback:e=>clickHandler(index,button,e.fromController),holdCallback:button.confirmationText?()=>executeButtonAction(index,button):null,holdDelay:500,repeatInterval:0}]])),256)),unref(popupData).warningMessage?(openBlock(),createElementBlock(`div`,_hoisted_5$155,toDisplayString(unref(popupData).warningMessage),1)):createCommentVNode(``,!0)])]),_:1})]))}}),Recovery_default=__plugin_vue_export_helper_default(_sfc_main$328,[[`__scopeId`,`data-v-8495e64c`]]),_hoisted_1$289={class:`item-container`,navigable:``,tabindex:`0`},_hoisted_2$237={class:`item-content`},_hoisted_3$210={class:`item-container indented`,navigable:``,tabindex:`0`},_hoisted_4$180={class:`item-content`},_sfc_main$327={__name:`FavoriteSelectionItem`,props:{data:Object,level:{type:Number,default:0}},emits:[`addedFunction`,`removedFunction`],setup(__props,{emit:__emit}){let emit$1=__emit,expandedStates=ref({}),focusedItem=ref(null),toggleExpanded=(idx,value)=>{expandedStates.value[idx]=value},select=item=>{focusedItem.value=item},deselect=item=>{focusedItem.value===item&&(focusedItem.value=null)},isFocused=item=>focusedItem.value===item,addActionToQuickAccess=item=>{console.log(`addActionToQuickAccess`,item),item&&item.uniqueID&&emit$1(`addedFunction`,item)},removeFunction=()=>{emit$1(`removedFunction`)};return(_ctx,_cache)=>{let _component_FavoriteSelectionItem=resolveComponent(`FavoriteSelectionItem`,!0);return openBlock(),createBlock(unref(accordion_default),{class:`favorite-selection-item`,expanded:__props.data.expanded},{default:withCtx(()=>[(openBlock(!0),createElementBlock(Fragment,null,renderList(__props.data.items,(item,idx)=>(openBlock(),createElementBlock(`div`,{key:idx,class:`item-wrapper`},[item.items?(openBlock(),createBlock(unref(accordionItem_default),{key:0,navigable:``,static:!item.items,expanded:expandedStates.value[idx],onExpanded:$event=>toggleExpanded(idx,$event),"arrow-big":``,onMouseover:withModifiers($event=>select(item),[`stop`]),onMouseleave:withModifiers($event=>deselect(item),[`stop`]),onFocusin:withModifiers($event=>select(item),[`stop`]),onFocusout:withModifiers($event=>deselect(item),[`stop`]),"primary-action":()=>addActionToQuickAccess(item),"primary-label":`ui.inputActions.menu.menu_item_select.title`,"expand-hint-inline":``},{caption:withCtx(()=>[createBaseVNode(`div`,_hoisted_1$289,[createBaseVNode(`div`,_hoisted_2$237,[createVNode(unref(bngIcon_default),{type:unref(icons)[item.icon]},null,8,[`type`]),createTextVNode(` `+toDisplayString(item.title?unref($translate).instant(item.title):item.niceName),1)]),item.uniqueID&&isFocused(item)?(openBlock(),createBlock(unref(bngButton_default),{key:0,accent:`outlined`,class:`select-button`,onClick:$event=>addActionToQuickAccess(item),"bng-no-nav":``},{default:withCtx(()=>[createVNode(unref(bngBinding_default),{class:`input-icon`,"ui-event":`ok`,controller:``}),_cache[0]||=createTextVNode(` Select `,-1)]),_:1},8,[`onClick`])):createCommentVNode(``,!0)])]),default:withCtx(()=>[createVNode(_component_FavoriteSelectionItem,{data:item,level:__props.level+1,onAddedFunction:addActionToQuickAccess,onRemovedFunction:removeFunction},null,8,[`data`,`level`])]),_:2},1032,[`static`,`expanded`,`onExpanded`,`onMouseover`,`onMouseleave`,`onFocusin`,`onFocusout`,`primary-action`])):(openBlock(),createBlock(unref(accordionItem_default),{key:1,static:!0,navigable:``,onMouseover:withModifiers($event=>select(item),[`stop`]),onMouseleave:withModifiers($event=>deselect(item),[`stop`]),onFocusin:withModifiers($event=>select(item),[`stop`]),onFocusout:withModifiers($event=>deselect(item),[`stop`]),"primary-action":()=>addActionToQuickAccess(item),"primary-label":`ui.inputActions.menu.menu_item_select.title`},{caption:withCtx(()=>[createBaseVNode(`div`,_hoisted_3$210,[createBaseVNode(`div`,_hoisted_4$180,[item.icon?(openBlock(),createBlock(unref(bngIcon_default),{key:0,type:unref(icons)[item.icon]},null,8,[`type`])):createCommentVNode(``,!0),createTextVNode(` `+toDisplayString(unref($translate).instant(item.title)),1)]),item.uniqueID&&isFocused(item)?(openBlock(),createBlock(unref(bngButton_default),{key:0,class:`select-button`,onClick:$event=>addActionToQuickAccess(item),accent:`outlined`,"bng-no-nav":``},{default:withCtx(()=>[createVNode(unref(bngBinding_default),{class:`input-icon`,"ui-event":`ok`,controller:``}),_cache[1]||=createTextVNode(` Select `,-1)]),_:1},8,[`onClick`])):createCommentVNode(``,!0)])]),_:2},1032,[`onMouseover`,`onMouseleave`,`onFocusin`,`onFocusout`,`primary-action`]))]))),128))]),_:1},8,[`expanded`])}}},FavoriteSelectionItem_default=__plugin_vue_export_helper_default(_sfc_main$327,[[`__scopeId`,`data-v-dd594aec`]]),_hoisted_1$288={class:`backgroundContainer`},_hoisted_2$236={key:0,class:`recovery-wrapper`,"bng-ui-scope":`favoriteSelection`},_hoisted_3$209={class:`current-action-container`},_hoisted_4$179={key:0},_hoisted_5$154={key:1},_hoisted_6$133={key:2},_hoisted_7$119={key:0,class:`content`},__default__$7={wrapper:{fade:!0,blur:!0,style:popupContainer.transparent},position:[popupPosition.center,popupPosition.center]},_sfc_main$326=Object.assign(__default__$7,{__name:`FavoriteSelection`,emits:[`return`],setup(__props,{emit:__emit}){let{events:events$3}=useBridge();useUINavScope(`favoriteSelection`);let emit$1=__emit,{closeRecoveryPrompt}=useGameContextStore(),data=ref({}),updateFavoritePopupData=()=>{Lua_default.core_quickAccess.getDynamicSlotConfigurationData().then(value=>data.value=value)};events$3.on(`radialFavoriteSelectionPopupData`,updateFavoritePopupData);let addedFunction=item=>{let config={uniqueID:item.uniqueID,level:item.level,type:item.type,mode:item.mode||`uniqueAction`};console.log(`addedFunction`,config),Lua_default.core_quickAccess.setDynamicSlotConfiguration(data.value.dynamicSlotKey,config),emit$1(`return`,!0)},removeFunction=()=>{Lua_default.core_quickAccess.removeActionFromQuickAccess(data.value.slotIndex),emit$1(`return`,!0)},close=()=>{emit$1(`return`,!0)};return onMounted(()=>{updateFavoritePopupData()}),onUnmounted(()=>{events$3.off(`radialFavoriteSelectionPopupData`,updateFavoritePopupData),window.bngVue.getCurrentRoute().name==`unknown`&&getUINavServiceInstance().setFilteredEventsAllExcept(UI_EVENTS.menu,UI_EVENTS.pause,UI_EVENTS.center_cam)}),(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$288,[unref(data).dynamicSlotKey?(openBlock(),createElementBlock(`div`,_hoisted_2$236,[createVNode(unref(bngCard_default),null,{default:withCtx(()=>[createVNode(unref(bngCardHeading_default),{type:`ribbon`},{default:withCtx(()=>[createTextVNode(` Assign Action to: `+toDisplayString(unref(data).dynamicSlotData.breadcrumbs[0]),1)]),_:1}),createBaseVNode(`div`,_hoisted_3$209,[_cache[3]||=createBaseVNode(`div`,{class:`current-action-label`},`Currently Assigned Action:`,-1),unref(data).dynamicSlotData.mode===`uniqueAction`&&unref(data).uniqueAction?(openBlock(),createElementBlock(`div`,_hoisted_4$179,[unref(data).uniqueAction.icon?(openBlock(),createBlock(unref(bngIcon_default),{key:0,type:unref(icons)[unref(data).uniqueAction.icon]},null,8,[`type`])):createCommentVNode(``,!0),createTextVNode(` `+toDisplayString(unref(data).uniqueAction.title?unref($translate).instant(unref(data).uniqueAction.title):unref(data).uniqueAction.niceName),1)])):createCommentVNode(``,!0),unref(data).dynamicSlotData.mode===`recentActions`?(openBlock(),createElementBlock(`div`,_hoisted_5$154,[createVNode(unref(bngIcon_default),{type:unref(icons).timer},null,8,[`type`]),_cache[1]||=createTextVNode(` Most Recent Action `,-1)])):createCommentVNode(``,!0),unref(data).dynamicSlotData.mode===`empty`?(openBlock(),createElementBlock(`div`,_hoisted_6$133,[createVNode(unref(bngIcon_default),{type:unref(icons).circleSlashed},null,8,[`type`]),_cache[2]||=createTextVNode(` Empty `,-1)])):createCommentVNode(``,!0)]),_cache[5]||=createBaseVNode(`div`,{class:`divider`},null,-1),unref(data).items?(openBlock(),createElementBlock(`div`,_hoisted_7$119,[createVNode(FavoriteSelectionItem_default,{data:unref(data).items,onAddedFunction:addedFunction,onRemovedFunction:removeFunction},null,8,[`data`])])):createCommentVNode(``,!0),withDirectives((openBlock(),createBlock(unref(bngButton_default),{class:`cancel-button`,onClick:_cache[0]||=$event=>close(),accent:`attention`},{default:withCtx(()=>[createVNode(unref(bngBinding_default),{class:`input-icon`,"ui-event":`back`,controller:``}),_cache[4]||=createTextVNode(` Cancel `,-1)]),_:1})),[[unref(BngOnUiNav_default),void 0,`back,menu`,{asMouse:!0}]])]),_:1})])):createCommentVNode(``,!0)]))}}),FavoriteSelection_default=__plugin_vue_export_helper_default(_sfc_main$326,[[`__scopeId`,`data-v-88390882`]]);const useGameContextStore=defineStore(`gameContext`,()=>{let{events:events$3}=useBridge(),activities=ref([]),activityScreen=null,recoveryPrompt=null,radialFavoriteSelectionPrompt=null,deliveryEndScreen=null,simpleDelayPopup=null,startMission=missionId=>{let mission=activities.value.find(x=>x.id===missionId);mission||console.error(`Mission not found ${missionId}. cannot start`);let settings$1=mission.settings,userSettings=mission&&settings$1?settings$1.reduce((a$1,b)=>a$1[b.key]=b.value,a):{};Lua_default.gameplay_markerInteraction.startMissionById(mission.id,userSettings)},closeActivitiesPrompt=()=>{Lua_default.gameplay_markerInteraction.closeViewDetailPrompt(!0)};function openRecoveryPrompt(){recoveryPrompt=addPopup(Recovery_default).promise}function openDynamicSlotConfigurator(){radialFavoriteSelectionPrompt=addPopup(FavoriteSelection_default).promise}function openSimpleDelayPopup(data){simpleDelayPopup=fixedDelayPopup(data.timer,{title:data.heading})}let performActivityAction=activityActionIndex=>Lua_default.ui_missionInfo.performActivityAction(activityActionIndex);events$3.on(`ActivityAcceptUpdate`,onActivityAcceptUpdate),events$3.on(`ActivityAcceptClose`,closeActivitiesPopup),events$3.on(`MenuOpenModule`,closeActivitiesPopup),events$3.on(`ChangeState`,closeActivitiesPopup),events$3.on(`OpenRecoveryPrompt`,openRecoveryPrompt),events$3.on(`OpenDynamicSlotConfigurator`,openDynamicSlotConfigurator),events$3.on(`OpenSimpleDelayPopup`,openSimpleDelayPopup);let deliveryRewardData=ref(!1);function showDeliveryEndScreen(data){deliveryRewardData.value=data,window.bngVue.gotoGameState(`cargoDeliveryReward`)}events$3.on(`OpenDeliveryEndScreen`,showDeliveryEndScreen);function onActivityAcceptUpdate(data){activityScreen&&(activities.value||!data)&&closeActivitiesPopup(),window.location.hash===`#/play`&&(activities.value=data,activities.value&&activities.value.length>0&&(activityScreen=openScreenOverlay(ActivityStart_default)))}function closeActivitiesPopup(){activityScreen&&=(activityScreen.close(!0),null)}function closeRecoveryPrompt(){recoveryPrompt&&=(recoveryPrompt.close(!0),null)}function closeRadialFavoriteSelectionPrompt(){radialFavoriteSelectionPrompt&&=(radialFavoriteSelectionPrompt.close(!0),null)}function closeSimpleDelayPopup(){simpleDelayPopup&&=(simpleDelayPopup.progress.done(),null)}function closeDeliveryEndScreen(){deliveryEndScreen&&=(deliveryEndScreen.close(!0),null)}function dispose$2(){events$3.off(`ActivityAcceptUpdate`,onActivityAcceptUpdate),events$3.off(`ActivityAcceptClose`,closeActivitiesPopup)}return{activities,closeActivitiesPrompt,closeDeliveryEndScreen,closeRecoveryPrompt,closeRadialFavoriteSelectionPrompt,closeSimpleDelayPopup,deliveryRewardData,dispose:dispose$2,performActivityAction,startMission}});var PARSE_NESTED$1=`PARSE_NESTED`,bbcode_main_default=[[/\[url=https?:\/\/([^\s\]]+)\](.*?(?=\[\/url\]))\[\/url\]/gi,`$2`],[/\[url='https?:\/\/([^\s\]]+)'\](.*?(?=\[\/url\]))\[\/url\]/gi,`$2`],[/\[forumurl=https?:\/\/([^\s\]]+)\](\S*?(?=\[\/forumurl\]))\[\/forumurl\]/gi,`$2`],[/\[url\]https?:\/\/(.*?(?=\[\/url\]))\[\/url\]/gi,`$1`],[/\[url=([^\s\]]+)\](.*?(?=\[\/url\]))\[\/url\]/gi,`$2`],[/\[h(\d)\](.*?(?=\[\/h\d\]))\[\/h\d\]/gi,`$2`],[/\[img\]\s*?(\S*?(?=\[\/img\]))\[\/img\]/gi,``],[/\shttp(s|):\/\/(\S*)/gi,`http$1://$2`],[/\[list=\d+\](.*?(?=\[\/list\]))\[\/list\]/gi,`
      $1
    `],[/\[list\]/gi,`
      `],[/\[\/list\]/gi,`
    `],[/\[olist\]/gi,`
      `],[/\[\/olist\]/gi,`
    `],[/\[(\*|\+)\]\s*?((.|\s)*?(?=\[(\*|\+)\]|\<\/ul\>|\<\/ol\>|\n\n|$))/gim,`
  • $2
  • `],[PARSE_NESTED$1,/\[b\](.*?(?=\[\/b\]))\[\/b\]/gi,`$1`],[PARSE_NESTED$1,/\[u\](.*?(?=\[\/u\]))\[\/u\]/gi,`$1`],[PARSE_NESTED$1,/\[s\](.*?(?=\[\/s\]))\[\/s\]/gi,`$1`],[PARSE_NESTED$1,/\[i\](.*?(?=\[\/i\]))\[\/i\]/gi,`$1`],[/\[strike\](.*?(?=\[\/strike\]))\[\/strike\]/gi,`$1`],[/\[code\](.*?(?=\[\/code\]))\[\/code\]/gi,`$1`],[/\[br\]/gi,`
    `],[/\n\n/gi,`

    `],[/\n/gi,`
    `],[/\[attach=?f?u?l?l?\](.*?(?=\[\/attach\]))\[\/attach\]/gi,``],[/\[USER=([\d]+)\](.*?(?=\[\/USER\]))\[\/USER\]/gi,`$2`],[/\[MEDIA=youtube\](.*?(?=\[\/MEDIA\]))\[\/MEDIA\]/gi,`
    `],[/\[MEDIA=beamng\](.*?(?=\[\/MEDIA\]))\[\/MEDIA\]/gi,``],[PARSE_NESTED$1,/\[size=(\d+)\]([^[]*(?:\[(?!size=\d+\]|\/size\])[^[]*)*)\[\/size\]/gi,`$2`],[PARSE_NESTED$1,/\[COLOR=([a-z0-9\#\, \'\"\(\)]+)\]([^[]*(?:\[(?!COLOR=[a-z0-9#\(\)]+\]|\/COLOR\])[^[]*)*)\[\/COLOR\]/gi,`$2`],[PARSE_NESTED$1,/\[font=([^\]]+)\](.*?(?=\[\/font\]))\[\/font\]/gi,`$2`],[/\[hr\]\[\/hr\]/gi,`
    `],[/\[spoiler=([^\]]+)\](.*?(?=\[\/spoiler\]))\[\/spoiler\]/gi,`
    Spoiler: $1
    $2
    `],[/\[spoiler\](.*?(?=\[\/spoiler\]))\[\/spoiler\]/gi,`
    Spoiler
    $1
    `],[PARSE_NESTED$1,/\[left\](.*?(?=\[\/left\]))\[\/left\]/gi,`

    $1

    `],[PARSE_NESTED$1,/\[center\](.*?(?=\[\/center\]))\[\/center\]/gi,`

    $1

    `],[PARSE_NESTED$1,/\[right\](.*?(?=\[\/right\]))\[\/right\]/gi,`

    $1

    `],[PARSE_NESTED$1,/\*\*(.*?(?=\*\*))\*\*/gi,`$1`],[PARSE_NESTED$1,/\*(.*?(?=\*))\*/gi,`$1`],[PARSE_NESTED$1,/\[(.*?(?=\]\())\]\((https?:\/\/((.*?(?=\)))))\)/gi,`$1 ($2)`]],bbcode_vue_default=[[/\[ico=([^\s\]]+)\s*\](.*?(?=\[\/ico\]))\[\/ico\]/gi,`$2`],[/\[ico=([^\s\]]+)\s*\]/gi,``],[/\[action=(.*?)\]\[showunassigned=(.*?)\](.*?)/gi,``],[/\[action=(.*?)\](.*?)/gi,``],[/\[action=(.*?)\]/gi,``],[/\[(money|beamXP|stars|vouchers)=(.*?)\]/g,``]],bbcode_angular_default=[[/\[ico=([^\s\]]+)\s*\](.*?(?=\[\/ico\]))\[\/ico\]/gi,`$2`],[/\[ico=([^\s\]]+)\s*\]/gi,``],[/\[action=(.*?)\]\[showunassigned=(.*?)\](.*?)/gi,``],[/\[action=(.*?)\](.*?)/gi,``],[/\[action=(.*?)\]/gi,``]],bbcode_exports=__export({parse:()=>parse$1,useExtensions:()=>useExtensions}),PARSE_NESTED=`PARSE_NESTED`,_extensions=bbcode_vue_default;const useExtensions=exts=>_extensions=exts,parse$1=(txt,extensions$1=_extensions)=>{let text=``+txt;return[...bbcode_main_default,...extensions$1].forEach(replacement=>{let{nested,fromTo}=replacementDetails(replacement);text=nested?parseNested(text,...fromTo):text.replace(...fromTo)}),text};window.angularParseBBCode=txt=>parse$1(txt,bbcode_angular_default);var replacementDetails=replacement=>({nested:replacement.length==3&&replacement[0]===PARSE_NESTED,fromTo:replacement.slice(-2)}),parseNested=(text,regex,template)=>{for(;~text.search(regex);)text=text.replace(regex,template);return text},markdown_exports=__export({parse:()=>parse});function parse(src){let h$1=``;return src.replace(/^\s+|\r|\s+$/g,``).replace(/\t/g,` `).split(/\n\n+/).forEach(function(b,f,R){f=b[0],R={"*":[/\n\* /,`
    • `,`
    `],1:[/\n[1-9]\d*\.? /,`
    1. `,`
    `]," ":[/\n {4}/,`
    `,`
    `,` `],">":[/\n> /,`
    `,`
    `,`
    `,CHAR_LS=`\u2028`,CHAR_PS=`\u2029`;function createScanner(str){let _buf=str,_index=0,_line=1,_column=1,_peekOffset=0,isCRLF=index$1=>_buf[index$1]===CHAR_CR&&_buf[index$1+1]===CHAR_LF,isLF=index$1=>_buf[index$1]===CHAR_LF,isPS=index$1=>_buf[index$1]===CHAR_PS,isLS=index$1=>_buf[index$1]===CHAR_LS,isLineEnd=index$1=>isCRLF(index$1)||isLF(index$1)||isPS(index$1)||isLS(index$1),index=()=>_index,line=()=>_line,column=()=>_column,peekOffset=()=>_peekOffset,charAt=offset$2=>isCRLF(offset$2)||isPS(offset$2)||isLS(offset$2)?CHAR_LF:_buf[offset$2],currentChar=()=>charAt(_index),currentPeek=()=>charAt(_index+_peekOffset);function next(){return _peekOffset=0,isLineEnd(_index)&&(_line++,_column=0),isCRLF(_index)&&_index++,_index++,_column++,_buf[_index]}function peek(){return isCRLF(_index+_peekOffset)&&_peekOffset++,_peekOffset++,_buf[_index+_peekOffset]}function reset$1(){_index=0,_line=1,_column=1,_peekOffset=0}function resetPeek(offset$2=0){_peekOffset=offset$2}function skipToPeek(){let target=_index+_peekOffset;for(;target!==_index;)next();_peekOffset=0}return{index,line,column,peekOffset,charAt,currentChar,currentPeek,next,peek,reset:reset$1,resetPeek,skipToPeek}}var EOF=void 0,DOT=`.`,LITERAL_DELIMITER=`'`,ERROR_DOMAIN$3=`tokenizer`;function createTokenizer(source,options={}){let location$1=options.location!==!1,_scnr=createScanner(source),currentOffset=()=>_scnr.index(),currentPosition=()=>createPosition(_scnr.line(),_scnr.column(),_scnr.index()),_initLoc=currentPosition(),_initOffset=currentOffset(),_context={currentType:13,offset:_initOffset,startLoc:_initLoc,endLoc:_initLoc,lastType:13,lastOffset:_initOffset,lastStartLoc:_initLoc,lastEndLoc:_initLoc,braceNest:0,inLinked:!1,text:``},context=()=>_context,{onError}=options;function emitError$1(code,pos,offset$2,...args){let ctx=context();pos.column+=offset$2,pos.offset+=offset$2,onError&&onError(createCompileError(code,location$1?createLocation(ctx.startLoc,pos):null,{domain:ERROR_DOMAIN$3,args}))}function getToken(context$1,type,value){context$1.endLoc=currentPosition(),context$1.currentType=type;let token={type};return location$1&&(token.loc=createLocation(context$1.startLoc,context$1.endLoc)),value!=null&&(token.value=value),token}let getEndToken=context$1=>getToken(context$1,13);function eat(scnr,ch){return scnr.currentChar()===ch?(scnr.next(),ch):(emitError$1(CompileErrorCodes.EXPECTED_TOKEN,currentPosition(),0,ch),``)}function peekSpaces(scnr){let buf=``;for(;scnr.currentPeek()===CHAR_SP||scnr.currentPeek()===CHAR_LF;)buf+=scnr.currentPeek(),scnr.peek();return buf}function skipSpaces(scnr){let buf=peekSpaces(scnr);return scnr.skipToPeek(),buf}function isIdentifierStart(ch){if(ch===EOF)return!1;let cc=ch.charCodeAt(0);return cc>=97&&cc<=122||cc>=65&&cc<=90||cc===95}function isNumberStart(ch){if(ch===EOF)return!1;let cc=ch.charCodeAt(0);return cc>=48&&cc<=57}function isNamedIdentifierStart(scnr,context$1){let{currentType}=context$1;if(currentType!==2)return!1;peekSpaces(scnr);let ret=isIdentifierStart(scnr.currentPeek());return scnr.resetPeek(),ret}function isListIdentifierStart(scnr,context$1){let{currentType}=context$1;if(currentType!==2)return!1;peekSpaces(scnr);let ret=isNumberStart(scnr.currentPeek()===`-`?scnr.peek():scnr.currentPeek());return scnr.resetPeek(),ret}function isLiteralStart(scnr,context$1){let{currentType}=context$1;if(currentType!==2)return!1;peekSpaces(scnr);let ret=scnr.currentPeek()===LITERAL_DELIMITER;return scnr.resetPeek(),ret}function isLinkedDotStart(scnr,context$1){let{currentType}=context$1;if(currentType!==7)return!1;peekSpaces(scnr);let ret=scnr.currentPeek()===`.`;return scnr.resetPeek(),ret}function isLinkedModifierStart(scnr,context$1){let{currentType}=context$1;if(currentType!==8)return!1;peekSpaces(scnr);let ret=isIdentifierStart(scnr.currentPeek());return scnr.resetPeek(),ret}function isLinkedDelimiterStart(scnr,context$1){let{currentType}=context$1;if(!(currentType===7||currentType===11))return!1;peekSpaces(scnr);let ret=scnr.currentPeek()===`:`;return scnr.resetPeek(),ret}function isLinkedReferStart(scnr,context$1){let{currentType}=context$1;if(currentType!==9)return!1;let fn=()=>{let ch=scnr.currentPeek();return ch===`{`?isIdentifierStart(scnr.peek()):ch===`@`||ch===`|`||ch===`:`||ch===`.`||ch===CHAR_SP||!ch?!1:ch===CHAR_LF?(scnr.peek(),fn()):isTextStart(scnr,!1)},ret=fn();return scnr.resetPeek(),ret}function isPluralStart(scnr){peekSpaces(scnr);let ret=scnr.currentPeek()===`|`;return scnr.resetPeek(),ret}function isTextStart(scnr,reset$1=!0){let fn=(hasSpace=!1,prev=``)=>{let ch=scnr.currentPeek();return ch===`{`||ch===`@`||!ch?hasSpace:ch===`|`?!(prev===CHAR_SP||prev===CHAR_LF):ch===CHAR_SP?(scnr.peek(),fn(!0,CHAR_SP)):ch===CHAR_LF?(scnr.peek(),fn(!0,CHAR_LF)):!0},ret=fn();return reset$1&&scnr.resetPeek(),ret}function takeChar(scnr,fn){let ch=scnr.currentChar();return ch===EOF?EOF:fn(ch)?(scnr.next(),ch):null}function isIdentifier(ch){let cc=ch.charCodeAt(0);return cc>=97&&cc<=122||cc>=65&&cc<=90||cc>=48&&cc<=57||cc===95||cc===36}function takeIdentifierChar(scnr){return takeChar(scnr,isIdentifier)}function isNamedIdentifier(ch){let cc=ch.charCodeAt(0);return cc>=97&&cc<=122||cc>=65&&cc<=90||cc>=48&&cc<=57||cc===95||cc===36||cc===45}function takeNamedIdentifierChar(scnr){return takeChar(scnr,isNamedIdentifier)}function isDigit(ch){let cc=ch.charCodeAt(0);return cc>=48&&cc<=57}function takeDigit(scnr){return takeChar(scnr,isDigit)}function isHexDigit(ch){let cc=ch.charCodeAt(0);return cc>=48&&cc<=57||cc>=65&&cc<=70||cc>=97&&cc<=102}function takeHexDigit(scnr){return takeChar(scnr,isHexDigit)}function getDigits(scnr){let ch=``,num=``;for(;ch=takeDigit(scnr);)num+=ch;return num}function readText(scnr){let buf=``;for(;;){let ch=scnr.currentChar();if(ch===`{`||ch===`}`||ch===`@`||ch===`|`||!ch)break;if(ch===CHAR_SP||ch===CHAR_LF)if(isTextStart(scnr))buf+=ch,scnr.next();else if(isPluralStart(scnr))break;else buf+=ch,scnr.next();else buf+=ch,scnr.next()}return buf}function readNamedIdentifier(scnr){skipSpaces(scnr);let ch=``,name=``;for(;ch=takeNamedIdentifierChar(scnr);)name+=ch;let currentChar=scnr.currentChar();if(currentChar&¤tChar!==`}`&¤tChar!==EOF&¤tChar!==CHAR_SP&¤tChar!==CHAR_LF&¤tChar!==` `){let invalidPart=readInvalidIdentifier(scnr);return emitError$1(CompileErrorCodes.INVALID_TOKEN_IN_PLACEHOLDER,currentPosition(),0,name+invalidPart),name+invalidPart}return scnr.currentChar()===EOF&&emitError$1(CompileErrorCodes.UNTERMINATED_CLOSING_BRACE,currentPosition(),0),name}function readListIdentifier(scnr){skipSpaces(scnr);let value=``;return scnr.currentChar()===`-`?(scnr.next(),value+=`-${getDigits(scnr)}`):value+=getDigits(scnr),scnr.currentChar()===EOF&&emitError$1(CompileErrorCodes.UNTERMINATED_CLOSING_BRACE,currentPosition(),0),value}function isLiteral(ch){return ch!==LITERAL_DELIMITER&&ch!==CHAR_LF}function readLiteral(scnr){skipSpaces(scnr),eat(scnr,`'`);let ch=``,literal=``;for(;ch=takeChar(scnr,isLiteral);)ch===`\\`?literal+=readEscapeSequence(scnr):literal+=ch;let current=scnr.currentChar();return current===CHAR_LF||current===EOF?(emitError$1(CompileErrorCodes.UNTERMINATED_SINGLE_QUOTE_IN_PLACEHOLDER,currentPosition(),0),current===CHAR_LF&&(scnr.next(),eat(scnr,`'`)),literal):(eat(scnr,`'`),literal)}function readEscapeSequence(scnr){let ch=scnr.currentChar();switch(ch){case`\\`:case`'`:return scnr.next(),`\\${ch}`;case`u`:return readUnicodeEscapeSequence(scnr,ch,4);case`U`:return readUnicodeEscapeSequence(scnr,ch,6);default:return emitError$1(CompileErrorCodes.UNKNOWN_ESCAPE_SEQUENCE,currentPosition(),0,ch),``}}function readUnicodeEscapeSequence(scnr,unicode,digits){eat(scnr,unicode);let sequence=``;for(let i=0;i{let ch=scnr.currentChar();return ch===`{`||ch===`@`||ch===`|`||ch===`(`||ch===`)`||!ch||ch===CHAR_SP?buf:(buf+=ch,scnr.next(),fn(buf))};return fn(``)}function readPlural(scnr){skipSpaces(scnr);let plural=eat(scnr,`|`);return skipSpaces(scnr),plural}function readTokenInPlaceholder(scnr,context$1){let token=null;switch(scnr.currentChar()){case`{`:return context$1.braceNest>=1&&emitError$1(CompileErrorCodes.NOT_ALLOW_NEST_PLACEHOLDER,currentPosition(),0),scnr.next(),token=getToken(context$1,2,`{`),skipSpaces(scnr),context$1.braceNest++,token;case`}`:return context$1.braceNest>0&&context$1.currentType===2&&emitError$1(CompileErrorCodes.EMPTY_PLACEHOLDER,currentPosition(),0),scnr.next(),token=getToken(context$1,3,`}`),context$1.braceNest--,context$1.braceNest>0&&skipSpaces(scnr),context$1.inLinked&&context$1.braceNest===0&&(context$1.inLinked=!1),token;case`@`:return context$1.braceNest>0&&emitError$1(CompileErrorCodes.UNTERMINATED_CLOSING_BRACE,currentPosition(),0),token=readTokenInLinked(scnr,context$1)||getEndToken(context$1),context$1.braceNest=0,token;default:{let validNamedIdentifier=!0,validListIdentifier=!0,validLiteral=!0;if(isPluralStart(scnr))return context$1.braceNest>0&&emitError$1(CompileErrorCodes.UNTERMINATED_CLOSING_BRACE,currentPosition(),0),token=getToken(context$1,1,readPlural(scnr)),context$1.braceNest=0,context$1.inLinked=!1,token;if(context$1.braceNest>0&&(context$1.currentType===4||context$1.currentType===5||context$1.currentType===6))return emitError$1(CompileErrorCodes.UNTERMINATED_CLOSING_BRACE,currentPosition(),0),context$1.braceNest=0,readToken(scnr,context$1);if(validNamedIdentifier=isNamedIdentifierStart(scnr,context$1))return token=getToken(context$1,4,readNamedIdentifier(scnr)),skipSpaces(scnr),token;if(validListIdentifier=isListIdentifierStart(scnr,context$1))return token=getToken(context$1,5,readListIdentifier(scnr)),skipSpaces(scnr),token;if(validLiteral=isLiteralStart(scnr,context$1))return token=getToken(context$1,6,readLiteral(scnr)),skipSpaces(scnr),token;if(!validNamedIdentifier&&!validListIdentifier&&!validLiteral)return token=getToken(context$1,12,readInvalidIdentifier(scnr)),emitError$1(CompileErrorCodes.INVALID_TOKEN_IN_PLACEHOLDER,currentPosition(),0,token.value),skipSpaces(scnr),token;break}}return token}function readTokenInLinked(scnr,context$1){let{currentType}=context$1,token=null,ch=scnr.currentChar();switch((currentType===7||currentType===8||currentType===11||currentType===9)&&(ch===CHAR_LF||ch===CHAR_SP)&&emitError$1(CompileErrorCodes.INVALID_LINKED_FORMAT,currentPosition(),0),ch){case`@`:return scnr.next(),token=getToken(context$1,7,`@`),context$1.inLinked=!0,token;case`.`:return skipSpaces(scnr),scnr.next(),getToken(context$1,8,`.`);case`:`:return skipSpaces(scnr),scnr.next(),getToken(context$1,9,`:`);default:return isPluralStart(scnr)?(token=getToken(context$1,1,readPlural(scnr)),context$1.braceNest=0,context$1.inLinked=!1,token):isLinkedDotStart(scnr,context$1)||isLinkedDelimiterStart(scnr,context$1)?(skipSpaces(scnr),readTokenInLinked(scnr,context$1)):isLinkedModifierStart(scnr,context$1)?(skipSpaces(scnr),getToken(context$1,11,readLinkedModifier(scnr))):isLinkedReferStart(scnr,context$1)?(skipSpaces(scnr),ch===`{`?readTokenInPlaceholder(scnr,context$1)||token:getToken(context$1,10,readLinkedRefer(scnr))):(currentType===7&&emitError$1(CompileErrorCodes.INVALID_LINKED_FORMAT,currentPosition(),0),context$1.braceNest=0,context$1.inLinked=!1,readToken(scnr,context$1))}}function readToken(scnr,context$1){let token={type:13};if(context$1.braceNest>0)return readTokenInPlaceholder(scnr,context$1)||getEndToken(context$1);if(context$1.inLinked)return readTokenInLinked(scnr,context$1)||getEndToken(context$1);switch(scnr.currentChar()){case`{`:return readTokenInPlaceholder(scnr,context$1)||getEndToken(context$1);case`}`:return emitError$1(CompileErrorCodes.UNBALANCED_CLOSING_BRACE,currentPosition(),0),scnr.next(),getToken(context$1,3,`}`);case`@`:return readTokenInLinked(scnr,context$1)||getEndToken(context$1);default:if(isPluralStart(scnr))return token=getToken(context$1,1,readPlural(scnr)),context$1.braceNest=0,context$1.inLinked=!1,token;if(isTextStart(scnr))return getToken(context$1,0,readText(scnr));break}return token}function nextToken(){let{currentType,offset:offset$2,startLoc,endLoc}=_context;return _context.lastType=currentType,_context.lastOffset=offset$2,_context.lastStartLoc=startLoc,_context.lastEndLoc=endLoc,_context.offset=currentOffset(),_context.startLoc=currentPosition(),_scnr.currentChar()===EOF?getToken(_context,13):readToken(_scnr,_context)}return{nextToken,currentOffset,currentPosition,context}}var ERROR_DOMAIN$2=`parser`,KNOWN_ESCAPES=/(?:\\\\|\\'|\\u([0-9a-fA-F]{4})|\\U([0-9a-fA-F]{6}))/g;function fromEscapeSequence(match,codePoint4,codePoint6){switch(match){case`\\\\`:return`\\`;case`\\'`:return`'`;default:{let codePoint=parseInt(codePoint4||codePoint6,16);return codePoint<=55295||codePoint>=57344?String.fromCodePoint(codePoint):`�`}}}function createParser(options={}){let location$1=options.location!==!1,{onError}=options;function emitError$1(tokenzer,code,start,offset$2,...args){let end=tokenzer.currentPosition();end.offset+=offset$2,end.column+=offset$2,onError&&onError(createCompileError(code,location$1?createLocation(start,end):null,{domain:ERROR_DOMAIN$2,args}))}function startNode(type,offset$2,loc){let node={type};return location$1&&(node.start=offset$2,node.end=offset$2,node.loc={start:loc,end:loc}),node}function endNode(node,offset$2,pos,type){location$1&&(node.end=offset$2,node.loc&&(node.loc.end=pos))}function parseText$1(tokenizer$1,value){let context=tokenizer$1.context(),node=startNode(3,context.offset,context.startLoc);return node.value=value,endNode(node,tokenizer$1.currentOffset(),tokenizer$1.currentPosition()),node}function parseList(tokenizer$1,index){let{lastOffset:offset$2,lastStartLoc:loc}=tokenizer$1.context(),node=startNode(5,offset$2,loc);return node.index=parseInt(index,10),tokenizer$1.nextToken(),endNode(node,tokenizer$1.currentOffset(),tokenizer$1.currentPosition()),node}function parseNamed(tokenizer$1,key){let{lastOffset:offset$2,lastStartLoc:loc}=tokenizer$1.context(),node=startNode(4,offset$2,loc);return node.key=key,tokenizer$1.nextToken(),endNode(node,tokenizer$1.currentOffset(),tokenizer$1.currentPosition()),node}function parseLiteral(tokenizer$1,value){let{lastOffset:offset$2,lastStartLoc:loc}=tokenizer$1.context(),node=startNode(9,offset$2,loc);return node.value=value.replace(KNOWN_ESCAPES,fromEscapeSequence),tokenizer$1.nextToken(),endNode(node,tokenizer$1.currentOffset(),tokenizer$1.currentPosition()),node}function parseLinkedModifier(tokenizer$1){let token=tokenizer$1.nextToken(),context=tokenizer$1.context(),{lastOffset:offset$2,lastStartLoc:loc}=context,node=startNode(8,offset$2,loc);return token.type===11?(token.value??emitError$1(tokenizer$1,CompileErrorCodes.UNEXPECTED_LEXICAL_ANALYSIS,context.lastStartLoc,0,getTokenCaption(token)),node.value=token.value||``,endNode(node,tokenizer$1.currentOffset(),tokenizer$1.currentPosition()),{node}):(emitError$1(tokenizer$1,CompileErrorCodes.UNEXPECTED_EMPTY_LINKED_MODIFIER,context.lastStartLoc,0),node.value=``,endNode(node,offset$2,loc),{nextConsumeToken:token,node})}function parseLinkedKey(tokenizer$1,value){let context=tokenizer$1.context(),node=startNode(7,context.offset,context.startLoc);return node.value=value,endNode(node,tokenizer$1.currentOffset(),tokenizer$1.currentPosition()),node}function parseLinked(tokenizer$1){let context=tokenizer$1.context(),linkedNode=startNode(6,context.offset,context.startLoc),token=tokenizer$1.nextToken();if(token.type===8){let parsed=parseLinkedModifier(tokenizer$1);linkedNode.modifier=parsed.node,token=parsed.nextConsumeToken||tokenizer$1.nextToken()}switch(token.type!==9&&emitError$1(tokenizer$1,CompileErrorCodes.UNEXPECTED_LEXICAL_ANALYSIS,context.lastStartLoc,0,getTokenCaption(token)),token=tokenizer$1.nextToken(),token.type===2&&(token=tokenizer$1.nextToken()),token.type){case 10:token.value??emitError$1(tokenizer$1,CompileErrorCodes.UNEXPECTED_LEXICAL_ANALYSIS,context.lastStartLoc,0,getTokenCaption(token)),linkedNode.key=parseLinkedKey(tokenizer$1,token.value||``);break;case 4:token.value??emitError$1(tokenizer$1,CompileErrorCodes.UNEXPECTED_LEXICAL_ANALYSIS,context.lastStartLoc,0,getTokenCaption(token)),linkedNode.key=parseNamed(tokenizer$1,token.value||``);break;case 5:token.value??emitError$1(tokenizer$1,CompileErrorCodes.UNEXPECTED_LEXICAL_ANALYSIS,context.lastStartLoc,0,getTokenCaption(token)),linkedNode.key=parseList(tokenizer$1,token.value||``);break;case 6:token.value??emitError$1(tokenizer$1,CompileErrorCodes.UNEXPECTED_LEXICAL_ANALYSIS,context.lastStartLoc,0,getTokenCaption(token)),linkedNode.key=parseLiteral(tokenizer$1,token.value||``);break;default:{emitError$1(tokenizer$1,CompileErrorCodes.UNEXPECTED_EMPTY_LINKED_KEY,context.lastStartLoc,0);let nextContext=tokenizer$1.context(),emptyLinkedKeyNode=startNode(7,nextContext.offset,nextContext.startLoc);return emptyLinkedKeyNode.value=``,endNode(emptyLinkedKeyNode,nextContext.offset,nextContext.startLoc),linkedNode.key=emptyLinkedKeyNode,endNode(linkedNode,nextContext.offset,nextContext.startLoc),{nextConsumeToken:token,node:linkedNode}}}return endNode(linkedNode,tokenizer$1.currentOffset(),tokenizer$1.currentPosition()),{node:linkedNode}}function parseMessage(tokenizer$1){let context=tokenizer$1.context(),node=startNode(2,context.currentType===1?tokenizer$1.currentOffset():context.offset,context.currentType===1?context.endLoc:context.startLoc);node.items=[];let nextToken=null;do{let token=nextToken||tokenizer$1.nextToken();switch(nextToken=null,token.type){case 0:token.value??emitError$1(tokenizer$1,CompileErrorCodes.UNEXPECTED_LEXICAL_ANALYSIS,context.lastStartLoc,0,getTokenCaption(token)),node.items.push(parseText$1(tokenizer$1,token.value||``));break;case 5:token.value??emitError$1(tokenizer$1,CompileErrorCodes.UNEXPECTED_LEXICAL_ANALYSIS,context.lastStartLoc,0,getTokenCaption(token)),node.items.push(parseList(tokenizer$1,token.value||``));break;case 4:token.value??emitError$1(tokenizer$1,CompileErrorCodes.UNEXPECTED_LEXICAL_ANALYSIS,context.lastStartLoc,0,getTokenCaption(token)),node.items.push(parseNamed(tokenizer$1,token.value||``));break;case 6:token.value??emitError$1(tokenizer$1,CompileErrorCodes.UNEXPECTED_LEXICAL_ANALYSIS,context.lastStartLoc,0,getTokenCaption(token)),node.items.push(parseLiteral(tokenizer$1,token.value||``));break;case 7:{let parsed=parseLinked(tokenizer$1);node.items.push(parsed.node),nextToken=parsed.nextConsumeToken||null;break}}}while(context.currentType!==13&&context.currentType!==1);return endNode(node,context.currentType===1?context.lastOffset:tokenizer$1.currentOffset(),context.currentType===1?context.lastEndLoc:tokenizer$1.currentPosition()),node}function parsePlural(tokenizer$1,offset$2,loc,msgNode){let context=tokenizer$1.context(),hasEmptyMessage=msgNode.items.length===0,node=startNode(1,offset$2,loc);node.cases=[],node.cases.push(msgNode);do{let msg=parseMessage(tokenizer$1);hasEmptyMessage||=msg.items.length===0,node.cases.push(msg)}while(context.currentType!==13);return hasEmptyMessage&&emitError$1(tokenizer$1,CompileErrorCodes.MUST_HAVE_MESSAGES_IN_PLURAL,loc,0),endNode(node,tokenizer$1.currentOffset(),tokenizer$1.currentPosition()),node}function parseResource(tokenizer$1){let context=tokenizer$1.context(),{offset:offset$2,startLoc}=context,msgNode=parseMessage(tokenizer$1);return context.currentType===13?msgNode:parsePlural(tokenizer$1,offset$2,startLoc,msgNode)}function parse$2(source){let tokenizer$1=createTokenizer(source,assign$1({},options)),context=tokenizer$1.context(),node=startNode(0,context.offset,context.startLoc);return location$1&&node.loc&&(node.loc.source=source),node.body=parseResource(tokenizer$1),options.onCacheKey&&(node.cacheKey=options.onCacheKey(source)),context.currentType!==13&&emitError$1(tokenizer$1,CompileErrorCodes.UNEXPECTED_LEXICAL_ANALYSIS,context.lastStartLoc,0,source[context.offset]||``),endNode(node,tokenizer$1.currentOffset(),tokenizer$1.currentPosition()),node}return{parse:parse$2}}function getTokenCaption(token){if(token.type===13)return`EOF`;let name=(token.value||``).replace(/\r?\n/gu,`\\n`);return name.length>10?name.slice(0,9)+`…`:name}function createTransformer(ast,options={}){let _context={ast,helpers:new Set};return{context:()=>_context,helper:name=>(_context.helpers.add(name),name)}}function traverseNodes(nodes,transformer){for(let i=0;ioptimizeMessageNode(c)),ast}function optimizeMessageNode(message){if(message.items.length===1){let item=message.items[0];(item.type===3||item.type===9)&&(message.static=item.value,delete item.value)}else{let values=[];for(let i=0;i_context;function push(code,node){_context.code+=code}function _newline(n,withBreakLine=!0){let _breakLineCode=withBreakLine?breakLineCode:``;push(_needIndent?_breakLineCode+`  `.repeat(n):_breakLineCode)}function indent(withNewLine=!0){let level$1=++_context.indentLevel;withNewLine&&_newline(level$1)}function deindent(withNewLine=!0){let level$1=--_context.indentLevel;withNewLine&&_newline(level$1)}function newline(){_newline(_context.indentLevel)}return{context,push,indent,deindent,newline,helper:key=>`_${key}`,needIndent:()=>_context.needIndent}}function generateLinkedNode(generator,node){let{helper}=generator;generator.push(`${helper(`linked`)}(`),generateNode(generator,node.key),node.modifier?(generator.push(`, `),generateNode(generator,node.modifier),generator.push(`, _type`)):generator.push(`, undefined, _type`),generator.push(`)`)}function generateMessageNode(generator,node){let{helper,needIndent}=generator;generator.push(`${helper(`normalize`)}([`),generator.indent(needIndent());let length=node.items.length;for(let i=0;i1){generator.push(`${helper(`plural`)}([`),generator.indent(needIndent());let length=node.cases.length;for(let i=0;i{let mode=isString(options.mode)?options.mode:`normal`,filename=isString(options.filename)?options.filename:`message.intl`,sourceMap=!!options.sourceMap,breakLineCode=options.breakLineCode==null?mode===`arrow`?`;`:`
    `:options.breakLineCode,needIndent=options.needIndent?options.needIndent:mode!==`arrow`,helpers=ast.helpers||[],generator=createCodeGenerator(ast,{mode,filename,sourceMap,breakLineCode,needIndent});generator.push(mode===`normal`?`function __msg__ (ctx) {`:`(ctx) => {`),generator.indent(needIndent),helpers.length>0&&(generator.push(`const { ${join(helpers.map(s=>`${s}: _${s}`),`, `)} } = ctx`),generator.newline()),generator.push(`return `),generateNode(generator,ast),generator.deindent(needIndent),generator.push(`}`),delete ast.helpers;let{code,map}=generator.context();return{ast,code,map:map?map.toJSON():void 0}};function baseCompile(source,options={}){let assignedOptions=assign$1({},options),jit=!!assignedOptions.jit,enalbeMinify=!!assignedOptions.minify,enambeOptimize=assignedOptions.optimize==null?!0:assignedOptions.optimize,ast=createParser(assignedOptions).parse(source);return jit?(enambeOptimize&&optimize(ast),enalbeMinify&&minify(ast),{ast,code:``}):(transform(ast,assignedOptions),generate(ast,assignedOptions))}function initFeatureFlags$1(){typeof __INTLIFY_PROD_DEVTOOLS__!=`boolean`&&(getGlobalThis().__INTLIFY_PROD_DEVTOOLS__=!1),typeof __INTLIFY_DROP_MESSAGE_COMPILER__!=`boolean`&&(getGlobalThis().__INTLIFY_DROP_MESSAGE_COMPILER__=!1)}function isMessageAST(val){return isObject(val)&&resolveType(val)===0&&(hasOwn(val,`b`)||hasOwn(val,`body`))}var PROPS_BODY=[`b`,`body`];function resolveBody(node){return resolveProps(node,PROPS_BODY)}var PROPS_CASES=[`c`,`cases`];function resolveCases(node){return resolveProps(node,PROPS_CASES,[])}var PROPS_STATIC=[`s`,`static`];function resolveStatic(node){return resolveProps(node,PROPS_STATIC)}var PROPS_ITEMS=[`i`,`items`];function resolveItems(node){return resolveProps(node,PROPS_ITEMS,[])}var PROPS_TYPE=[`t`,`type`];function resolveType(node){return resolveProps(node,PROPS_TYPE)}var PROPS_VALUE=[`v`,`value`];function resolveValue$1(node,type){let resolved=resolveProps(node,PROPS_VALUE);if(resolved!=null)return resolved;throw createUnhandleNodeError(type)}var PROPS_MODIFIER=[`m`,`modifier`];function resolveLinkedModifier(node){return resolveProps(node,PROPS_MODIFIER)}var PROPS_KEY=[`k`,`key`];function resolveLinkedKey(node){let resolved=resolveProps(node,PROPS_KEY);if(resolved)return resolved;throw createUnhandleNodeError(6)}function resolveProps(node,props,defaultValue){for(let i=0;iformatParts(ctx,ast)}function formatParts(ctx,ast){let body=resolveBody(ast);if(body==null)throw createUnhandleNodeError(0);if(resolveType(body)===1){let cases=resolveCases(body);return ctx.plural(cases.reduce((messages,c)=>[...messages,formatMessageParts(ctx,c)],[]))}else return formatMessageParts(ctx,body)}function formatMessageParts(ctx,node){let static_=resolveStatic(node);if(static_!=null)return ctx.type===`text`?static_:ctx.normalize([static_]);{let messages=resolveItems(node).reduce((acm,c)=>[...acm,formatMessagePart(ctx,c)],[]);return ctx.normalize(messages)}}function formatMessagePart(ctx,node){let type=resolveType(node);switch(type){case 3:return resolveValue$1(node,type);case 9:return resolveValue$1(node,type);case 4:{let named=node;if(hasOwn(named,`k`)&&named.k)return ctx.interpolate(ctx.named(named.k));if(hasOwn(named,`key`)&&named.key)return ctx.interpolate(ctx.named(named.key));throw createUnhandleNodeError(type)}case 5:{let list=node;if(hasOwn(list,`i`)&&isNumber(list.i))return ctx.interpolate(ctx.list(list.i));if(hasOwn(list,`index`)&&isNumber(list.index))return ctx.interpolate(ctx.list(list.index));throw createUnhandleNodeError(type)}case 6:{let linked=node,modifier=resolveLinkedModifier(linked),key=resolveLinkedKey(linked);return ctx.linked(formatMessagePart(ctx,key),modifier?formatMessagePart(ctx,modifier):void 0,ctx.type)}case 7:return resolveValue$1(node,type);case 8:return resolveValue$1(node,type);default:throw Error(`unhandled node on format message part: ${type}`)}}var defaultOnCacheKey=message=>message,compileCache=create();function baseCompile$1(message,options={}){let detectError=!1,onError=options.onError||defaultOnError;return options.onError=err=>{detectError=!0,onError(err)},{...baseCompile(message,options),detectError}}function compile(message,context){if(!__INTLIFY_DROP_MESSAGE_COMPILER__&&isString(message)){isBoolean(context.warnHtmlMessage)&&context.warnHtmlMessage;let cacheKey=(context.onCacheKey||defaultOnCacheKey)(message),cached=compileCache[cacheKey];if(cached)return cached;let{ast,detectError}=baseCompile$1(message,{...context,location:!1,jit:!0}),msg=format$1(ast);return detectError?msg:compileCache[cacheKey]=msg}else{let cacheKey=message.cacheKey;return cacheKey?compileCache[cacheKey]||(compileCache[cacheKey]=format$1(message)):format$1(message)}}var devtools=null;function setDevToolsHook(hook){devtools=hook}function initI18nDevTools(i18n,version$2,meta){devtools&&devtools.emit(`i18n:init`,{timestamp:Date.now(),i18n,version:version$2,meta})}var translateDevTools=createDevToolsHook(`function:translate`);function createDevToolsHook(hook){return payloads=>devtools&&devtools.emit(hook,payloads)}var CoreErrorCodes={INVALID_ARGUMENT:17,INVALID_DATE_ARGUMENT:18,INVALID_ISO_DATE_ARGUMENT:19,NOT_SUPPORT_NON_STRING_MESSAGE:20,NOT_SUPPORT_LOCALE_PROMISE_VALUE:21,NOT_SUPPORT_LOCALE_ASYNC_FUNCTION:22,NOT_SUPPORT_LOCALE_TYPE:23},CORE_ERROR_CODES_EXTEND_POINT=24;function createCoreError(code){return createCompileError(code,null,void 0)}CoreErrorCodes.INVALID_ARGUMENT,CoreErrorCodes.INVALID_DATE_ARGUMENT,CoreErrorCodes.INVALID_ISO_DATE_ARGUMENT,CoreErrorCodes.NOT_SUPPORT_NON_STRING_MESSAGE,CoreErrorCodes.NOT_SUPPORT_LOCALE_PROMISE_VALUE,CoreErrorCodes.NOT_SUPPORT_LOCALE_ASYNC_FUNCTION,CoreErrorCodes.NOT_SUPPORT_LOCALE_TYPE;function getLocale(context,options){return options.locale==null?resolveLocale(context.locale):resolveLocale(options.locale)}var _resolveLocale;function resolveLocale(locale){if(isString(locale))return locale;if(isFunction(locale)){if(locale.resolvedOnce&&_resolveLocale!=null)return _resolveLocale;if(locale.constructor.name===`Function`){let resolve$1=locale();if(isPromise(resolve$1))throw createCoreError(CoreErrorCodes.NOT_SUPPORT_LOCALE_PROMISE_VALUE);return _resolveLocale=resolve$1}else throw createCoreError(CoreErrorCodes.NOT_SUPPORT_LOCALE_ASYNC_FUNCTION)}else throw createCoreError(CoreErrorCodes.NOT_SUPPORT_LOCALE_TYPE)}function fallbackWithSimple(ctx,fallback,start){return[...new Set([start,...isArray$1(fallback)?fallback:isObject(fallback)?Object.keys(fallback):isString(fallback)?[fallback]:[start]])]}var pathStateMachine=[];pathStateMachine[0]={w:[0],i:[3,0],"[":[4],o:[7]},pathStateMachine[1]={w:[1],".":[2],"[":[4],o:[7]},pathStateMachine[2]={w:[2],i:[3,0],0:[3,0]},pathStateMachine[3]={i:[3,0],0:[3,0],w:[1,1],".":[2,1],"[":[4,1],o:[7,1]},pathStateMachine[4]={"'":[5,0],'"':[6,0],"[":[4,2],"]":[1,3],o:8,l:[4,0]},pathStateMachine[5]={"'":[4,0],o:8,l:[5,0]},pathStateMachine[6]={'"':[4,0],o:8,l:[6,0]};function resolveWithKeyValue(obj,path){return isObject(obj)?obj[path]:null}var CoreWarnCodes={NOT_FOUND_KEY:1,FALLBACK_TO_TRANSLATE:2,CANNOT_FORMAT_NUMBER:3,FALLBACK_TO_NUMBER_FORMAT:4,CANNOT_FORMAT_DATE:5,FALLBACK_TO_DATE_FORMAT:6,EXPERIMENTAL_CUSTOM_MESSAGE_COMPILER:7},CORE_WARN_CODES_EXTEND_POINT=8,warnMessages={[CoreWarnCodes.NOT_FOUND_KEY]:`Not found '{key}' key in '{locale}' locale messages.`,[CoreWarnCodes.FALLBACK_TO_TRANSLATE]:`Fall back to translate '{key}' key with '{target}' locale.`,[CoreWarnCodes.CANNOT_FORMAT_NUMBER]:`Cannot format a number value due to not supported Intl.NumberFormat.`,[CoreWarnCodes.FALLBACK_TO_NUMBER_FORMAT]:`Fall back to number format '{key}' key with '{target}' locale.`,[CoreWarnCodes.CANNOT_FORMAT_DATE]:`Cannot format a date value due to not supported Intl.DateTimeFormat.`,[CoreWarnCodes.FALLBACK_TO_DATE_FORMAT]:`Fall back to datetime format '{key}' key with '{target}' locale.`,[CoreWarnCodes.EXPERIMENTAL_CUSTOM_MESSAGE_COMPILER]:`This project is using Custom Message Compiler, which is an experimental feature. It may receive breaking changes or be removed in the future.`},VERSION$1=`11.1.12`,NOT_REOSLVED=-1,DEFAULT_LOCALE=`en-US`,capitalize=str=>`${str.charAt(0).toLocaleUpperCase()}${str.substr(1)}`;function getDefaultLinkedModifiers(){return{upper:(val,type)=>type===`text`&&isString(val)?val.toUpperCase():type===`vnode`&&isObject(val)&&`__v_isVNode`in val?val.children.toUpperCase():val,lower:(val,type)=>type===`text`&&isString(val)?val.toLowerCase():type===`vnode`&&isObject(val)&&`__v_isVNode`in val?val.children.toLowerCase():val,capitalize:(val,type)=>type===`text`&&isString(val)?capitalize(val):type===`vnode`&&isObject(val)&&`__v_isVNode`in val?capitalize(val.children):val}}var _compiler;function registerMessageCompiler(compiler){_compiler=compiler}var _resolver,_fallbacker,_additionalMeta=null,setAdditionalMeta=meta=>{_additionalMeta=meta},getAdditionalMeta=()=>_additionalMeta,_fallbackContext=null,setFallbackContext=context=>{_fallbackContext=context},getFallbackContext=()=>_fallbackContext,_cid=0;function createCoreContext(options={}){let onWarn=isFunction(options.onWarn)?options.onWarn:warn,version$2=isString(options.version)?options.version:VERSION$1,locale=isString(options.locale)||isFunction(options.locale)?options.locale:DEFAULT_LOCALE,_locale=isFunction(locale)?DEFAULT_LOCALE:locale,fallbackLocale=isArray$1(options.fallbackLocale)||isPlainObject(options.fallbackLocale)||isString(options.fallbackLocale)||options.fallbackLocale===!1?options.fallbackLocale:_locale,messages=isPlainObject(options.messages)?options.messages:createResources(_locale),datetimeFormats=isPlainObject(options.datetimeFormats)?options.datetimeFormats:createResources(_locale),numberFormats=isPlainObject(options.numberFormats)?options.numberFormats:createResources(_locale),modifiers=assign$1(create(),options.modifiers,getDefaultLinkedModifiers()),pluralRules=options.pluralRules||create(),missing=isFunction(options.missing)?options.missing:null,missingWarn=isBoolean(options.missingWarn)||isRegExp(options.missingWarn)?options.missingWarn:!0,fallbackWarn=isBoolean(options.fallbackWarn)||isRegExp(options.fallbackWarn)?options.fallbackWarn:!0,fallbackFormat=!!options.fallbackFormat,unresolving=!!options.unresolving,postTranslation=isFunction(options.postTranslation)?options.postTranslation:null,processor=isPlainObject(options.processor)?options.processor:null,warnHtmlMessage=isBoolean(options.warnHtmlMessage)?options.warnHtmlMessage:!0,escapeParameter=!!options.escapeParameter,messageCompiler=isFunction(options.messageCompiler)?options.messageCompiler:_compiler,messageResolver=isFunction(options.messageResolver)?options.messageResolver:_resolver||resolveWithKeyValue,localeFallbacker=isFunction(options.localeFallbacker)?options.localeFallbacker:_fallbacker||fallbackWithSimple,fallbackContext=isObject(options.fallbackContext)?options.fallbackContext:void 0,internalOptions=options,__datetimeFormatters=isObject(internalOptions.__datetimeFormatters)?internalOptions.__datetimeFormatters:new Map,__numberFormatters=isObject(internalOptions.__numberFormatters)?internalOptions.__numberFormatters:new Map,__meta=isObject(internalOptions.__meta)?internalOptions.__meta:{};_cid++;let context={version:version$2,cid:_cid,locale,fallbackLocale,messages,modifiers,pluralRules,missing,missingWarn,fallbackWarn,fallbackFormat,unresolving,postTranslation,processor,warnHtmlMessage,escapeParameter,messageCompiler,messageResolver,localeFallbacker,fallbackContext,onWarn,__meta};return context.datetimeFormats=datetimeFormats,context.numberFormats=numberFormats,context.__datetimeFormatters=__datetimeFormatters,context.__numberFormatters=__numberFormatters,__INTLIFY_PROD_DEVTOOLS__&&initI18nDevTools(context,version$2,__meta),context}var createResources=locale=>({[locale]:create()});function handleMissing(context,key,locale,missingWarn,type){let{missing,onWarn}=context;if(missing!==null){let ret=missing(context,locale,key,type);return isString(ret)?ret:key}else return key}function updateFallbackLocale(ctx,locale,fallback){let context=ctx;context.__localeChainCache=new Map,ctx.localeFallbacker(ctx,fallback,locale)}function isAlmostSameLocale(locale,compareLocale){return locale===compareLocale?!1:locale.split(`-`)[0]===compareLocale.split(`-`)[0]}function isImplicitFallback(targetLocale,locales){let index=locales.indexOf(targetLocale);if(index===-1)return!1;for(let i=index+1;istr,DEFAULT_MESSAGE=ctx=>``,DEFAULT_MESSAGE_DATA_TYPE=`text`,DEFAULT_NORMALIZE=values=>values.length===0?``:join(values),DEFAULT_INTERPOLATE=toDisplayString$1;function pluralDefault(choice,choicesLength){return choice=Math.abs(choice),choicesLength===2?choice?choice>1?1:0:1:choice?Math.min(choice,2):0}function getPluralIndex(options){let index=isNumber(options.pluralIndex)?options.pluralIndex:-1;return options.named&&(isNumber(options.named.count)||isNumber(options.named.n))?isNumber(options.named.count)?options.named.count:isNumber(options.named.n)?options.named.n:index:index}function normalizeNamed(pluralIndex,props){props.count||=pluralIndex,props.n||=pluralIndex}function createMessageContext(options={}){let locale=options.locale,pluralIndex=getPluralIndex(options),pluralRule=isObject(options.pluralRules)&&isString(locale)&&isFunction(options.pluralRules[locale])?options.pluralRules[locale]:pluralDefault,orgPluralRule=isObject(options.pluralRules)&&isString(locale)&&isFunction(options.pluralRules[locale])?pluralDefault:void 0,plural=messages=>messages[pluralRule(pluralIndex,messages.length,orgPluralRule)],_list=options.list||[],list=index=>_list[index],_named=options.named||create();isNumber(options.pluralIndex)&&normalizeNamed(pluralIndex,_named);let named=key=>_named[key];function message(key,useLinked){return(isFunction(options.messages)?options.messages(key,!!useLinked):isObject(options.messages)?options.messages[key]:!1)||(options.parent?options.parent.message(key):DEFAULT_MESSAGE)}let _modifier=name=>options.modifiers?options.modifiers[name]:DEFAULT_MODIFIER,normalize=isPlainObject(options.processor)&&isFunction(options.processor.normalize)?options.processor.normalize:DEFAULT_NORMALIZE,interpolate=isPlainObject(options.processor)&&isFunction(options.processor.interpolate)?options.processor.interpolate:DEFAULT_INTERPOLATE,ctx={list,named,plural,linked:(key,...args)=>{let[arg1,arg2]=args,type$1=`text`,modifier=``;args.length===1?isObject(arg1)?(modifier=arg1.modifier||modifier,type$1=arg1.type||type$1):isString(arg1)&&(modifier=arg1||modifier):args.length===2&&(isString(arg1)&&(modifier=arg1||modifier),isString(arg2)&&(type$1=arg2||type$1));let ret=message(key,!0)(ctx),msg=type$1===`vnode`&&isArray$1(ret)&&modifier?ret[0]:ret;return modifier?_modifier(modifier)(msg,type$1):msg},message,type:isPlainObject(options.processor)&&isString(options.processor.type)?options.processor.type:DEFAULT_MESSAGE_DATA_TYPE,interpolate,normalize,values:assign$1(create(),_list,_named)};return ctx}var NOOP_MESSAGE_FUNCTION=()=>``,isMessageFunction=val=>isFunction(val);function translate$1(context,...args){let{fallbackFormat,postTranslation,unresolving,messageCompiler,fallbackLocale,messages}=context,[key,options]=parseTranslateArgs(...args),missingWarn=isBoolean(options.missingWarn)?options.missingWarn:context.missingWarn,fallbackWarn=isBoolean(options.fallbackWarn)?options.fallbackWarn:context.fallbackWarn,escapeParameter=isBoolean(options.escapeParameter)?options.escapeParameter:context.escapeParameter,resolvedMessage=!!options.resolvedMessage,defaultMsgOrKey=isString(options.default)||isBoolean(options.default)?isBoolean(options.default)?messageCompiler?key:()=>key:options.default:fallbackFormat?messageCompiler?key:()=>key:null,enableDefaultMsg=fallbackFormat||defaultMsgOrKey!=null&&(isString(defaultMsgOrKey)||isFunction(defaultMsgOrKey)),locale=getLocale(context,options);escapeParameter&&escapeParams(options);let[formatScope,targetLocale,message]=resolvedMessage?[key,locale,messages[locale]||create()]:resolveMessageFormat(context,key,locale,fallbackLocale,fallbackWarn,missingWarn),format$2=formatScope,cacheBaseKey=key;if(!resolvedMessage&&!(isString(format$2)||isMessageAST(format$2)||isMessageFunction(format$2))&&enableDefaultMsg&&(format$2=defaultMsgOrKey,cacheBaseKey=format$2),!resolvedMessage&&(!(isString(format$2)||isMessageAST(format$2)||isMessageFunction(format$2))||!isString(targetLocale)))return unresolving?-1:key;let occurred=!1,msg=isMessageFunction(format$2)?format$2:compileMessageFormat(context,key,targetLocale,format$2,cacheBaseKey,()=>{occurred=!0});if(occurred)return format$2;let messaged=evaluateMessage(context,msg,createMessageContext(getMessageContextOptions(context,targetLocale,message,options))),ret=postTranslation?postTranslation(messaged,key):messaged;if(escapeParameter&&isString(ret)&&(ret=sanitizeTranslatedHtml(ret)),__INTLIFY_PROD_DEVTOOLS__){let payloads={timestamp:Date.now(),key:isString(key)?key:isMessageFunction(format$2)?format$2.key:``,locale:targetLocale||(isMessageFunction(format$2)?format$2.locale:``),format:isString(format$2)?format$2:isMessageFunction(format$2)?format$2.source:``,message:ret};payloads.meta=assign$1({},context.__meta,getAdditionalMeta()||{}),translateDevTools(payloads)}return ret}function escapeParams(options){isArray$1(options.list)?options.list=options.list.map(item=>isString(item)?escapeHtml(item):item):isObject(options.named)&&Object.keys(options.named).forEach(key=>{isString(options.named[key])&&(options.named[key]=escapeHtml(options.named[key]))})}function resolveMessageFormat(context,key,locale,fallbackLocale,fallbackWarn,missingWarn){let{messages,onWarn,messageResolver:resolveValue,localeFallbacker}=context,locales=localeFallbacker(context,fallbackLocale,locale),message=create(),targetLocale,format$2=null,type=`translate`;for(let i=0;iformat$2);return msg$1.locale=targetLocale,msg$1.key=key,msg$1}let msg=messageCompiler(format$2,getCompileContext(context,targetLocale,cacheBaseKey,format$2,warnHtmlMessage,onError));return msg.locale=targetLocale,msg.key=key,msg.source=format$2,msg}function evaluateMessage(context,msg,msgCtx){return msg(msgCtx)}function parseTranslateArgs(...args){let[arg1,arg2,arg3]=args,options=create();if(!isString(arg1)&&!isNumber(arg1)&&!isMessageFunction(arg1)&&!isMessageAST(arg1))throw createCoreError(CoreErrorCodes.INVALID_ARGUMENT);let key=isNumber(arg1)?String(arg1):(isMessageFunction(arg1),arg1);return isNumber(arg2)?options.plural=arg2:isString(arg2)?options.default=arg2:isPlainObject(arg2)&&!isEmptyObject(arg2)?options.named=arg2:isArray$1(arg2)&&(options.list=arg2),isNumber(arg3)?options.plural=arg3:isString(arg3)?options.default=arg3:isPlainObject(arg3)&&assign$1(options,arg3),[key,options]}function getCompileContext(context,locale,key,source,warnHtmlMessage,onError){return{locale,key,warnHtmlMessage,onError:err=>{throw onError&&onError(err),err},onCacheKey:source$1=>generateFormatCacheKey(locale,key,source$1)}}function getMessageContextOptions(context,locale,message,options){let{modifiers,pluralRules,messageResolver:resolveValue,fallbackLocale,fallbackWarn,missingWarn,fallbackContext}=context,ctxOptions={locale,modifiers,pluralRules,messages:(key,useLinked)=>{let val=resolveValue(message,key);if(val==null&&(fallbackContext||useLinked)){let[,,message$1]=resolveMessageFormat(fallbackContext||context,key,locale,fallbackLocale,fallbackWarn,missingWarn);val=resolveValue(message$1,key)}if(isString(val)||isMessageAST(val)){let occurred=!1,msg=compileMessageFormat(context,key,locale,val,key,()=>{occurred=!0});return occurred?NOOP_MESSAGE_FUNCTION:msg}else if(isMessageFunction(val))return val;else return NOOP_MESSAGE_FUNCTION}};return context.processor&&(ctxOptions.processor=context.processor),options.list&&(ctxOptions.list=options.list),options.named&&(ctxOptions.named=options.named),isNumber(options.plural)&&(ctxOptions.pluralIndex=options.plural),ctxOptions}initFeatureFlags$1();var VERSION=`11.1.12`;function initFeatureFlags(){typeof __VUE_I18N_FULL_INSTALL__!=`boolean`&&(getGlobalThis().__VUE_I18N_FULL_INSTALL__=!0),typeof __VUE_I18N_LEGACY_API__!=`boolean`&&(getGlobalThis().__VUE_I18N_LEGACY_API__=!0),typeof __INTLIFY_DROP_MESSAGE_COMPILER__!=`boolean`&&(getGlobalThis().__INTLIFY_DROP_MESSAGE_COMPILER__=!1),typeof __INTLIFY_PROD_DEVTOOLS__!=`boolean`&&(getGlobalThis().__INTLIFY_PROD_DEVTOOLS__=!1)}var I18nErrorCodes={UNEXPECTED_RETURN_TYPE:24,INVALID_ARGUMENT:25,MUST_BE_CALL_SETUP_TOP:26,NOT_INSTALLED:27,REQUIRED_VALUE:28,INVALID_VALUE:29,CANNOT_SETUP_VUE_DEVTOOLS_PLUGIN:30,NOT_INSTALLED_WITH_PROVIDE:31,UNEXPECTED_ERROR:32,NOT_COMPATIBLE_LEGACY_VUE_I18N:33,NOT_AVAILABLE_COMPOSITION_IN_LEGACY:34};function createI18nError(code,...args){return createCompileError(code,null,void 0)}I18nErrorCodes.UNEXPECTED_RETURN_TYPE,I18nErrorCodes.INVALID_ARGUMENT,I18nErrorCodes.MUST_BE_CALL_SETUP_TOP,I18nErrorCodes.NOT_INSTALLED,I18nErrorCodes.UNEXPECTED_ERROR,I18nErrorCodes.REQUIRED_VALUE,I18nErrorCodes.INVALID_VALUE,I18nErrorCodes.CANNOT_SETUP_VUE_DEVTOOLS_PLUGIN,I18nErrorCodes.NOT_INSTALLED_WITH_PROVIDE,I18nErrorCodes.NOT_COMPATIBLE_LEGACY_VUE_I18N,I18nErrorCodes.NOT_AVAILABLE_COMPOSITION_IN_LEGACY;var SetPluralRulesSymbol=makeSymbol(`__setPluralRules`);makeSymbol(`__intlifyMeta`);var I18nWarnCodes={FALLBACK_TO_ROOT:8,NOT_FOUND_PARENT_SCOPE:9,IGNORE_OBJ_FLATTEN:10,DEPRECATE_LEGACY_MODE:11,DEPRECATE_TRANSLATE_CUSTOME_DIRECTIVE:12,DUPLICATE_USE_I18N_CALLING:13};I18nWarnCodes.FALLBACK_TO_ROOT,I18nWarnCodes.NOT_FOUND_PARENT_SCOPE,I18nWarnCodes.IGNORE_OBJ_FLATTEN,I18nWarnCodes.DEPRECATE_LEGACY_MODE,I18nWarnCodes.DEPRECATE_TRANSLATE_CUSTOME_DIRECTIVE,I18nWarnCodes.DUPLICATE_USE_I18N_CALLING;function handleFlatJson(obj){if(!isObject(obj)||isMessageAST(obj))return obj;for(let key in obj)if(hasOwn(obj,key))if(!key.includes(`.`))isObject(obj[key])&&handleFlatJson(obj[key]);else{let subKeys=key.split(`.`),lastIndex=subKeys.length-1,currentObj=obj,hasStringValue=!1;for(let i=0;i{if(`locale`in custom&&`resource`in custom){let{locale:locale$1,resource}=custom;locale$1?(ret[locale$1]=ret[locale$1]||create(),deepCopy(resource,ret[locale$1])):deepCopy(resource,ret)}else isString(custom)&&deepCopy(JSON.parse(custom),ret)}),messageResolver==null&&flatJson)for(let key in ret)hasOwn(ret,key)&&handleFlatJson(ret[key]);return ret}function getComponentOptions(instance$1){return instance$1.type}var DEVTOOLS_META=`__INTLIFY_META__`,composerID=0;function defineCoreMissingHandler(missing){return((ctx,locale,key,type)=>missing(locale,key,getCurrentInstance()||void 0,type))}var getMetaInfo=()=>{let instance$1=getCurrentInstance(),meta=null;return instance$1&&(meta=getComponentOptions(instance$1)[DEVTOOLS_META])?{[DEVTOOLS_META]:meta}:null};function createComposer(options={}){let{__root,__injectWithOption}=options,_isGlobal=__root===void 0,flatJson=options.flatJson,_ref=inBrowser?ref:shallowRef,_inheritLocale=isBoolean(options.inheritLocale)?options.inheritLocale:!0,_locale=_ref(__root&&_inheritLocale?__root.locale.value:isString(options.locale)?options.locale:DEFAULT_LOCALE),_fallbackLocale=_ref(__root&&_inheritLocale?__root.fallbackLocale.value:isString(options.fallbackLocale)||isArray$1(options.fallbackLocale)||isPlainObject(options.fallbackLocale)||options.fallbackLocale===!1?options.fallbackLocale:_locale.value),_messages=_ref(getLocaleMessages(_locale.value,options)),_missingWarn=__root?__root.missingWarn:isBoolean(options.missingWarn)||isRegExp(options.missingWarn)?options.missingWarn:!0,_fallbackWarn=__root?__root.fallbackWarn:isBoolean(options.fallbackWarn)||isRegExp(options.fallbackWarn)?options.fallbackWarn:!0,_fallbackRoot=__root?__root.fallbackRoot:isBoolean(options.fallbackRoot)?options.fallbackRoot:!0,_fallbackFormat=!!options.fallbackFormat,_missing=isFunction(options.missing)?options.missing:null,_runtimeMissing=isFunction(options.missing)?defineCoreMissingHandler(options.missing):null,_postTranslation=isFunction(options.postTranslation)?options.postTranslation:null,_warnHtmlMessage=__root?__root.warnHtmlMessage:isBoolean(options.warnHtmlMessage)?options.warnHtmlMessage:!0,_escapeParameter=!!options.escapeParameter,_modifiers=__root?__root.modifiers:isPlainObject(options.modifiers)?options.modifiers:{},_pluralRules=options.pluralRules||__root&&__root.pluralRules,_context;_context=(()=>{_isGlobal&&setFallbackContext(null);let ctx=createCoreContext({version:VERSION,locale:_locale.value,fallbackLocale:_fallbackLocale.value,messages:_messages.value,modifiers:_modifiers,pluralRules:_pluralRules,missing:_runtimeMissing===null?void 0:_runtimeMissing,missingWarn:_missingWarn,fallbackWarn:_fallbackWarn,fallbackFormat:_fallbackFormat,unresolving:!0,postTranslation:_postTranslation===null?void 0:_postTranslation,warnHtmlMessage:_warnHtmlMessage,escapeParameter:_escapeParameter,messageResolver:options.messageResolver,messageCompiler:options.messageCompiler,__meta:{framework:`vue`}});return _isGlobal&&setFallbackContext(ctx),ctx})(),updateFallbackLocale(_context,_locale.value,_fallbackLocale.value);function trackReactivityValues(){return[_locale.value,_fallbackLocale.value,_messages.value]}let locale=computed({get:()=>_locale.value,set:val=>{_context.locale=val,_locale.value=val}}),fallbackLocale=computed({get:()=>_fallbackLocale.value,set:val=>{_context.fallbackLocale=val,_fallbackLocale.value=val,updateFallbackLocale(_context,_locale.value,val)}}),messages=computed(()=>_messages.value);function getPostTranslationHandler(){return isFunction(_postTranslation)?_postTranslation:null}function setPostTranslationHandler(handler$1){_postTranslation=handler$1,_context.postTranslation=handler$1}function getMissingHandler(){return _missing}function setMissingHandler(handler$1){handler$1!==null&&(_runtimeMissing=defineCoreMissingHandler(handler$1)),_missing=handler$1,_context.missing=_runtimeMissing}let wrapWithDeps=(fn,argumentParser,warnType,fallbackSuccess,fallbackFail,successCondition)=>{trackReactivityValues();let ret;try{__INTLIFY_PROD_DEVTOOLS__,_isGlobal||(_context.fallbackContext=__root?getFallbackContext():void 0),ret=fn(_context)}finally{__INTLIFY_PROD_DEVTOOLS__,_isGlobal||(_context.fallbackContext=void 0)}if(isNumber(ret)&&ret===-1||warnType===`translate exists`){let[key,arg2]=argumentParser();return __root&&_fallbackRoot?fallbackSuccess(__root):fallbackFail(key)}else if(successCondition(ret))return ret;else throw createI18nError(I18nErrorCodes.UNEXPECTED_RETURN_TYPE)};function t(...args){return wrapWithDeps(context=>Reflect.apply(translate$1,null,[context,...args]),()=>parseTranslateArgs(...args),`translate`,root=>Reflect.apply(root.t,root,[...args]),key=>key,val=>isString(val))}function setPluralRules(rules){_pluralRules=rules,_context.pluralRules=_pluralRules}function getLocaleMessage(locale$1){return _messages.value[locale$1]||{}}function setLocaleMessage(locale$1,message){if(flatJson){let _message={[locale$1]:message};for(let key in _message)hasOwn(_message,key)&&handleFlatJson(_message[key]);message=_message[locale$1]}_messages.value[locale$1]=message,_context.messages=_messages.value}function mergeLocaleMessage(locale$1,message){_messages.value[locale$1]=_messages.value[locale$1]||{};let _message={[locale$1]:message};if(flatJson)for(let key in _message)hasOwn(_message,key)&&handleFlatJson(_message[key]);message=_message[locale$1],deepCopy(message,_messages.value[locale$1]),_context.messages=_messages.value}return composerID++,__root&&inBrowser&&(watch(__root.locale,val=>{_inheritLocale&&(_locale.value=val,_context.locale=val,updateFallbackLocale(_context,_locale.value,_fallbackLocale.value))}),watch(__root.fallbackLocale,val=>{_inheritLocale&&(_fallbackLocale.value=val,_context.fallbackLocale=val,updateFallbackLocale(_context,_locale.value,_fallbackLocale.value))})),{id:composerID,locale,fallbackLocale,get inheritLocale(){return _inheritLocale},set inheritLocale(val){_inheritLocale=val,val&&__root&&(_locale.value=__root.locale.value,_fallbackLocale.value=__root.fallbackLocale.value,updateFallbackLocale(_context,_locale.value,_fallbackLocale.value))},get availableLocales(){return Object.keys(_messages.value).sort()},messages,get modifiers(){return _modifiers},get pluralRules(){return _pluralRules||{}},get isGlobal(){return _isGlobal},get missingWarn(){return _missingWarn},set missingWarn(val){_missingWarn=val,_context.missingWarn=_missingWarn},get fallbackWarn(){return _fallbackWarn},set fallbackWarn(val){_fallbackWarn=val,_context.fallbackWarn=_fallbackWarn},get fallbackRoot(){return _fallbackRoot},set fallbackRoot(val){_fallbackRoot=val},get fallbackFormat(){return _fallbackFormat},set fallbackFormat(val){_fallbackFormat=val,_context.fallbackFormat=_fallbackFormat},get warnHtmlMessage(){return _warnHtmlMessage},set warnHtmlMessage(val){_warnHtmlMessage=val,_context.warnHtmlMessage=val},get escapeParameter(){return _escapeParameter},set escapeParameter(val){_escapeParameter=val,_context.escapeParameter=val},t,getLocaleMessage,setLocaleMessage,mergeLocaleMessage,getPostTranslationHandler,setPostTranslationHandler,getMissingHandler,setMissingHandler,[SetPluralRulesSymbol]:setPluralRules}}function createI18n(options={}){let __globalInjection=isBoolean(options.globalInjection)?options.globalInjection:!0,__instances=new Map,[globalScope,__global]=createGlobal(options),symbol=makeSymbol(``);function __getInstance(component){return __instances.get(component)||null}function __setInstance(component,instance$1){__instances.set(component,instance$1)}function __deleteInstance(component){__instances.delete(component)}let i18n={get mode(){return`composition`},async install(app$1,...options$1){if(app$1.__VUE_I18N_SYMBOL__=symbol,app$1.provide(app$1.__VUE_I18N_SYMBOL__,i18n),isPlainObject(options$1[0])){let opts=options$1[0];i18n.__composerExtend=opts.__composerExtend,i18n.__vueI18nExtend=opts.__vueI18nExtend}let globalReleaseHandler=null;__globalInjection&&(globalReleaseHandler=injectGlobalFields(app$1,i18n.global));let unmountApp=app$1.unmount;app$1.unmount=()=>{globalReleaseHandler&&globalReleaseHandler(),i18n.dispose(),unmountApp()}},get global(){return __global},dispose(){globalScope.stop()},__instances,__getInstance,__setInstance,__deleteInstance};return i18n}function createGlobal(options,legacyMode){let scope$1=effectScope(),obj=scope$1.run(()=>createComposer(options));if(obj==null)throw createI18nError(I18nErrorCodes.UNEXPECTED_ERROR);return[scope$1,obj]}var globalExportProps=[`locale`,`fallbackLocale`,`availableLocales`],globalExportMethods=[`t`];function injectGlobalFields(app$1,composer){let i18n=Object.create(null);return globalExportProps.forEach(prop=>{let desc=Object.getOwnPropertyDescriptor(composer,prop);if(!desc)throw createI18nError(I18nErrorCodes.UNEXPECTED_ERROR);let wrap=isRef(desc.value)?{get(){return desc.value.value},set(val){desc.value.value=val}}:{get(){return desc.get&&desc.get()}};Object.defineProperty(i18n,prop,wrap)}),app$1.config.globalProperties.$i18n=i18n,globalExportMethods.forEach(method=>{let desc=Object.getOwnPropertyDescriptor(composer,method);if(!desc||!desc.value)throw createI18nError(I18nErrorCodes.UNEXPECTED_ERROR);Object.defineProperty(app$1.config.globalProperties,`$${method}`,desc)}),()=>{delete app$1.config.globalProperties.$i18n,globalExportMethods.forEach(method=>{delete app$1.config.globalProperties[`$${method}`]})}}if(initFeatureFlags(),registerMessageCompiler(compile),__INTLIFY_PROD_DEVTOOLS__){let target=getGlobalThis();target.__INTLIFY__=!0,setDevToolsHook(target.__INTLIFY_DEVTOOLS_GLOBAL_HOOK__)}const emptyImage=`data:image/svg+xml,`;function getURL(path){return typeof path!=`string`||!path||path.includes(`://`)?path:(path.startsWith(`/`)&&(path=path.substring(1)),`/${path}`)}function getAssetURL(assetPath){let url=getURL(assetPath);return typeof url!=`string`||!url||url.startsWith(`/`)&&(url=`/ui/ui-vue/src/assets`+url),url}const getFile=(url,timeout=5)=>new Promise((resolve$1,reject)=>{try{let xhr=new XMLHttpRequest,tmr=timeout>0?setTimeout(()=>{xhr.abort(),reject(Error(`Timeout`))},timeout*1e3):null;xhr.open(`GET`,url,!0),xhr.onload=()=>{tmr&&clearTimeout(tmr),xhr.status===200?resolve$1(xhr.responseText):reject(Error(`Failed with code ${xhr.status}`))},xhr.send()}catch(err){reject(err)}}),ucaseFirst=str=>str[0].toUpperCase()+str.slice(1),defer=()=>{let noop$3=()=>{},resolve$1,reject,_notifyHandler=noop$3,promise=new Promise((res,rej)=>{[resolve$1,reject]=[res,rej]});return{promise:{then:(resolveHandler,rejectHandler=noop$3,notifyHandler=noop$3)=>(_notifyHandler=notifyHandler,promise.then(resolveHandler,rejectHandler))},resolve:resolve$1,reject,notify:val=>_notifyHandler(val)}},sleep=ms=>new Promise(resolve$1=>setTimeout(resolve$1,ms)),debounce=(func,wait,immediate)=>{let timeout;function call(...args){let context=this,later=()=>{timeout=null,immediate||func.apply(context,args)},callNow=immediate&&!timeout;timeout&&window.clearTimeout(timeout),timeout=window.setTimeout(later,wait),callNow&&func.apply(context,args)}return call.cancel=()=>timeout&&window.clearTimeout(timeout),call};var Settings=class{options=reactive({});values=reactive({});_previousValues={};_changedValues={};_watcher=null;_syncPending=!1;inited=!1;loaded=!1;_lua;constructor(eventBus$1=void 0,lua=void 0){eventBus$1&&lua&&this.init(eventBus$1,lua)}init(eventBus$1=void 0,lua=void 0){if(!(this.inited||this.loaded)){if(this.inited=!0,!eventBus$1||!lua){let bridge$4=useBridge();eventBus$1||=bridge$4.events,lua||=bridge$4.lua}eventBus$1.on(`SettingsChanged`,data=>{Object.assign(this.options,data.options),Object.assign(this.values,data.values),this._previousValues=this.clone(data.values),this._changedValues={},this._watcher||=watch(()=>this.values,()=>this._syncChanges(),{deep:!0,flush:`sync`}),this.loaded=!0}),this._syncChangesDebounced=debounce(this._syncChangesImmediate,100),this._lua=lua,this.update()}}async waitForData(){for(;!this.inited||!this.loaded;)await sleep(10)}async update(){if(this._lua)return await this._lua.settings.notifyUI()}clone(data){return JSON.parse(JSON.stringify(data))}getValue(field=null){if(this.loaded)return field&&!(field in this.values)?null:this.clone(field?this.values[field]:this.values)}get changesPending(){return this._syncChangesImmediate(),Object.keys(this._changedValues).length>0}get pendingChanges(){return this._syncChangesImmediate(),this.clone(this._changedValues)}_syncChanges(){this._syncPending=!0,this._syncChangesDebounced()}_syncChangesDebounced=()=>{};_syncChangesImmediate(){if(this._syncPending)for(let key in this._syncPending=!1,this.values)this._previousValues[key]===this.values[key]?key in this._changedValues&&delete this._changedValues[key]:this._changedValues[key]=this.values[key]}async apply(values=void 0){if(!this.loaded)return;let res;if(values)res=this.clone(values);else{if(!this.changesPending)return;res={...this._changedValues},this._changedValues={}}return Object.assign(this._previousValues,res),await this._lua.settings.setState(res)}},settings=new Settings;function useSettings(){return settings.init(),settings}async function useSettingsAsync(){return settings.init(),await settings.waitForData(),settings}var ANGULAR_TRANSLATE=[],_angularTranslateFunc,_i18n,i18nVariant=`petite`,defaultLocale=`en-US`,localeCheckId=`ui.common.okay`,checkLocale=()=>_i18n&&_i18n.global.t(localeCheckId)!==localeCheckId,translate=val=>val;const initTranslation=()=>{if(window.vueI18n?.__bng_i18n_variant!==i18nVariant){window.vueI18n&&console.warn(`Localisation library is already initialized, but its variant was not validated. Reloading...`);let creationArguments={locale:defaultLocale,fallbackLocale:defaultLocale,silentTranslationWarn:!0,fallbackWarn:!1,missingWarn:!1,warnHtmlMessage:!1};window.beamng&&!window.beamng.shipping&&(creationArguments.fallbackLocale=[defaultLocale,`not-shipping.internal`]),window.vueI18n=createI18n(creationArguments),window.vueI18n.__bng_i18n_variant=i18nVariant}return _i18n=window.vueI18n,{i18n:_i18n,plugin:translationPlugin}},loadLocale=async(locale,force=!1)=>{if(!(_i18n.global.availableLocales.includes(locale)&&!force))try{let url=getURL(`/locales/${locale}.json`),resp;try{resp=await getFile(url,5)}catch(err){if(err.message!==`Timeout`)throw err;console.warn(`Locale ${locale} load timed out, retrying with a bigger timeout...`),resp=await getFile(url,10)}_i18n.global.setLocaleMessage(locale,preprocessLocaleJSON(JSON.parse(resp)))}catch(err){console.error(`Failed to load ${locale} locale`,err)}};var setupUserLanguage=async()=>{let settings$1=await useSettingsAsync();watch(()=>settings$1.values.uiLanguage,async lang=>{lang&&lang!==defaultLocale&&await loadLocale(lang),_i18n.global.locale.value=_i18n.global.availableLocales.includes(lang)?lang:defaultLocale,lang!==defaultLocale&&!checkLocale()&&console.warn(`Locale ${lang} is not behaving properly`)},{immediate:!0})};const translationPlugin=()=>({install(app$1,options){return _i18n.global.locale.value=defaultLocale,loadLocale(defaultLocale,!0).then(async()=>{checkLocale()||(console.warn(`Failed to load default locale, retrying...`),await loadLocale(defaultLocale,!0),checkLocale()||console.error(`Failed to load default locale!`)),await setupUserLanguage()}),contextTranslatePlugin().install(app$1,options)}}),contextTranslatePlugin=()=>({install(app$1,options){translate=_wrapTranslate(app$1.config.globalProperties.$t||_i18n.global.t),app$1.config.globalProperties.$t=_i18n.global.t,app$1.config.globalProperties.$ctx_t=(val,translateContext=!0)=>contextTranslate(val,translateContext),app$1.config.globalProperties.$mctx_t=multiContextTranslate,app$1.config.globalProperties.$tt=translate}});var contextTranslate=(val,translateContext=!1)=>{let type=typeof val;if(type===`undefined`||val===null)return``;if(type===`object`)if(val.txt&&val.context){let context=val.context;if(translateContext)for(let key in context={...context},context)context[key]=contextTranslate(context[key],!0);return getTranslation(val.txt,context)}else val=val.txt||``;return getTranslation(``+val)},multiContextTranslate=val=>{if(val.txt)return contextTranslate(val);let description=``;for(let i of val)description+=contextTranslate(i);return description},getAngularTranslationFunc=()=>_angularTranslateFunc||(window.angular$translate&&(_angularTranslateFunc=window.angular$translate.instant.bind(window.angular$translate)),_angularTranslateFunc||translate),getTranslation=(...vals)=>(ANGULAR_TRANSLATE.includes(vals[0])?getAngularTranslationFunc():translate)(...vals);const $translate={instant:val=>val===void 0?``:translate(val),contextTranslate,multiContextTranslate};var rgxAngular=/{{.+}}/,rgxAngularTranslation=/([^ ]?){{ *(?::: *)?'([^ |}]+)' *\| *translate *}}([^\w]?)/gi;function translateAngularToVue(text){let vueText=text.replace(rgxAngularTranslation,(_,q1,s,q2)=>(q1?`${q1} `:``)+`@:${s}`+(q2?` ${q2}`:``));return vueText=vueText.replace(/{{ *([a-z\d_.]+) *}}/gi,`{$1}`),vueText===text||rgxAngular.test(vueText)?null:vueText}const preprocessLocaleJSON=obj=>{let messages={};for(let key in obj){if(ANGULAR_TRANSLATE.includes(key))continue;let text=obj[key];if(rgxAngular.test(text)){let vueText=translateAngularToVue(text);vueText?messages[key]=vueText:ANGULAR_TRANSLATE.includes(key)||ANGULAR_TRANSLATE.push(key)}else messages[key]=text}return messages};var rgxLinkedTranslation=/@:([a-zA-Z0-9_][a-zA-Z0-9_.-]+[a-zA-Z0-9_])/g,linkedNamespace=`__linked_custom`;function _linkedTranslation(msg){if(!msg.includes(`@:`)||!rgxLinkedTranslation.test(msg))return msg;let locale=_i18n.global.locale.value,messages=_i18n.global.messages.value[locale];msg=msg.replace(rgxLinkedTranslation,(_,id)=>`@:`+id);let uniqueId$1=``,match;for(rgxLinkedTranslation.lastIndex=0;(match=rgxLinkedTranslation.exec(msg))!==null;)uniqueId$1+=match[1].replace(/\./g,`_`)+`__`;let fullId,messageId,counter$1=0;for(;counter$1<100;){messageId=uniqueId$1+ ++counter$1,fullId=linkedNamespace+`.`+messageId;let existingMessage=messages[fullId];if(!existingMessage){_i18n.global.mergeLocaleMessage(locale,{[fullId]:msg});break}if(existingMessage===msg)break}return fullId}function _wrapTranslate(f){function translate$2(...args){let key=args[0];return key?typeof key!=`string`||(key=_linkedTranslation(key),key.includes(` `))?key:f.apply(this,[key,...args.slice(1)]):``}return Object.defineProperty(translate$2,`name`,{value:f.name}),translate$2}const UI_NAV_ACTION_GROUP=`UINavActions`,GAME_UI_NAVIGATION_EVENT=`UINavigation`,GAME_UI_NAV_MAP_ENABLED_EVENT=`MenuActionMapEnabled`,DOM_UI_NAVIGATION_EVENT=`ui_nav`,ACTIONS_BY_UI_EVENT={focus_u:`menu_item_up`,focus_r:`menu_item_right`,focus_d:`menu_item_down`,focus_l:`menu_item_left`,menu:`toggleMenues`,back:`menu_item_back`,details:`cui_details`,advanced:`cui_advanced`,camera:`cui_camera`,logs:`cui_logs`,tab_l:`menu_tab_left`,tab_r:`menu_tab_right`,modifier:`cui_modifier`,action_4:`cui_action_4`,focus_ud:`menu_item_focus_ud`,focus_lr:`menu_item_focus_lr`,rotate_h_cam:`menu_item_radial_right_x`,rotate_v_cam:`menu_item_radial_right_y`,ok:`menu_item_select`,cancel:`cui_cancel`,action_2:`cui_action_2`,action_3:`cui_action_3`,context:`cui_context`,gameplay_interact:`cui_gameplay_interact`},UI_EVENTS_BY_ACTION=Object.assign({},...Object.entries(ACTIONS_BY_UI_EVENT).map(([k,v])=>({[v]:k}))),UI_EVENTS={focus_u:`focus_u`,focus_r:`focus_r`,focus_d:`focus_d`,focus_l:`focus_l`,pause:`pause`,menu:`menu`,back:`back`,details:`details`,advanced:`advanced`,camera:`camera`,logs:`logs`,tab_l:`tab_l`,tab_r:`tab_r`,modifier:`modifier`,zoom_out:`zoom_out`,zoom_in:`zoom_in`,subtab_l:`subtab_l`,subtab_r:`subtab_r`,center_cam:`center_cam`,action_4:`action_4`,move_ud:`move_ud`,move_lr:`move_lr`,focus_ud:`focus_ud`,focus_lr:`focus_lr`,rotate_h_cam:`rotate_h_cam`,rotate_v_cam:`rotate_v_cam`,ok:`ok`,cancel:`cancel`,action_2:`action_2`,action_3:`action_3`,context:`context`,gameplay_interact:`gameplay_interact`},UI_EVENT_GROUPS={focusMove:[UI_EVENTS.focus_u,UI_EVENTS.focus_d,UI_EVENTS.focus_l,UI_EVENTS.focus_r],focusMoveScalar:[UI_EVENTS.focus_ud,UI_EVENTS.focus_lr],moveScalar:[UI_EVENTS.move_ud,UI_EVENTS.move_lr],navigation:[UI_EVENTS.focus_u,UI_EVENTS.focus_d,UI_EVENTS.focus_l,UI_EVENTS.focus_r,UI_EVENTS.focus_ud,UI_EVENTS.focus_lr,UI_EVENTS.move_ud,UI_EVENTS.move_lr],allEvents:Object.keys(ACTIONS_BY_UI_EVENT)},NAV_ACTIONS=[`focus_u`,`focus_d`,`focus_l`,`focus_r`],VALUE_BASED_EVENTS=[`zoom_out`,`zoom_in`,`subtab_l`,`subtab_r`,`move_ud`,`move_lr`,`focus_ud`,`focus_lr`,`rotate_h_cam`,`rotate_v_cam`],UI_SCOPE_ATTR$2=`bng-ui-scope`,UI_EVENT_ATTR=`ui-nav-event`;var UINavEventProcessor=class{constructor(){this.isModified=!1}processEvent(name,value=void 0,extras=[],context={}){return!this.isValidGameContext()||context.isEventBlocked&&context.isEventBlocked(name)?null:(this.handleModifierState(name,value),this.shouldHandleWithAngular(name,value)?(this.handleAngularIntegration(),null):this.createEventData(name,value,extras))}isValidGameContext(){return window.beamng?.ingame}handleModifierState(name,value){name===`modifier`&&(this.isModified=value===1)}shouldHandleWithAngular(name,value){return window.globalAngularRootScope&&window.bngIntroShown&&(name===`menu`||name===`back`)&&value===1}handleAngularIntegration(){window.globalAngularRootScope.$broadcast(`MenuToggle`)}createEventData(name,value,extras){let activeElement=document.activeElement,targetScope=null;if(activeElement&&activeElement!==document.body){let scopeElement=activeElement.closest(`[${UI_SCOPE_ATTR$2}]`);scopeElement&&(targetScope=scopeElement.getAttribute(UI_SCOPE_ATTR$2))}return{name,value,modified:name!==`modifier`&&this.isModified,extras,boundAction:ACTIONS_BY_UI_EVENT[name],sendToCrossfire:!0,targetScope}}getEventBroadcastElement(activeScope){let activeElement=document.activeElement;if(activeElement&&activeElement!==document.body)return activeElement;if(activeScope){let scopeElement=document.querySelector(`[${UI_SCOPE_ATTR$2}="${activeScope}"]`);if(scopeElement)return scopeElement}return document.body}},UINavActionHandlers=class{constructor(eventBus$1=null){this._useCrossfire=!0,this.eventBus=eventBus$1}setUseCrossfire(enabled){this._useCrossfire=enabled}get useCrossfire(){return this._useCrossfire}setEventBus(eventBus$1){this.eventBus=eventBus$1}handleGlobalEvent=event=>{let eventData=event.detail;eventData.value===1&&(this.handleMenuActions(eventData)||this.handleNavigationActions(eventData)||this.handleGameActions(eventData))||(this.useCrossfire&&eventData.sendToCrossfire&&handleUINavEvent(event),event.defaultPrevented||(this.handleTabNavigation(eventData),this.handleCameraRotation(eventData),this.handleContextActions(eventData)))};handleMenuActions=eventData=>{if(eventData.name===`menu`||eventData.name===`back`){let globalAngularRootScope=window.globalAngularRootScope;return globalAngularRootScope?(globalAngularRootScope.$broadcast(`MenuToggle`),!1):!0}return!1};handleNavigationActions(eventData){if(NAV_ACTIONS.includes(eventData.name)){Lua_default.extensions.hook(`onMenuItemNavigation`);return}return!1}handleGameActions(eventData){switch(eventData.name){case`pause`:return Lua_default.simTimeAuthority.togglePause(),!0;case`center_cam`:return runRaw(`if core_camera then core_camera.resetCamera(${eventData.extras.player}) end`,!1),!0;default:return!1}}handleTabNavigation(eventData){if(eventData.value===1)switch(eventData.name){case`tab_l`:this.eventBus.emit(`ui_topBar_selectPrevious`);break;case`tab_r`:this.eventBus.emit(`ui_topBar_selectNext`);break}}handleCameraRotation(eventData){if(eventData.name===`rotate_h_cam`||eventData.name===`rotate_v_cam`){let camDir=eventData.name===`rotate_v_cam`?`pitch`:`yaw`,[filterType]=eventData.extras||[0];runRaw(`if core_camera then core_camera.rotate_${camDir}(${eventData.value}, ${filterType}) end`,!1)}}handleContextActions(eventData){[`context`,`details`,`camera`].includes(eventData.name)&&eventData.value===1&&this.isBigMapContext()&&runRaw(`if freeroam_bigMapMode then freeroam_bigMapMode.toggleBigMap() end`,!1)}isBigMapContext(){return[`#/bigmap`,`#/menu.bigmap`,`#/play`,`#/menu/bigmap`].includes(window.location.hash)}},UINavService=class{constructor(eventBus$1){this._eventBus=eventBus$1,this._eventsActive=!1,this._globalEventsHooked=!1,this._activeScope=void 0,this._blockedEvents=[],this.eventProcessor=new UINavEventProcessor,this.actionHandlers=new UINavActionHandlers(eventBus$1),this.useCrossfire=!0}initialize(){this.attachEventListeners(),this.hookGlobalEvents()}handleGameEvent=(name,value,...extras)=>{let context={activeScope:this.activeScope,isEventBlocked:eventName=>this.isEventBlocked(eventName)},eventData=this.eventProcessor.processEvent(name,value,extras,context);eventData&&this.dispatchDOMEvent(eventData)};blockEvents(...events$3){let eventsToAdd=events$3.flat().filter(event=>!this._blockedEvents.includes(event));this._blockedEvents.push(...eventsToAdd)}unblockEvents(...events$3){let eventsToRemove=events$3.flat();this._blockedEvents=this._blockedEvents.filter(event=>!eventsToRemove.includes(event))}setBlockedEvents(events$3=[]){this._blockedEvents=[...events$3]}clearBlockedEvents(){this._blockedEvents=[]}isEventBlocked(eventName){return this._blockedEvents.includes(eventName)}getBlockedEvents(){return[...this._blockedEvents]}handleEnabledChange=state=>{this.eventsActive=state};dispatchDOMEvent=eventData=>{let event=new CustomEvent(DOM_UI_NAVIGATION_EVENT,{detail:eventData,cancelable:!0,bubbles:!0});this.eventProcessor.getEventBroadcastElement(this.activeScope).dispatchEvent(event)};fireEvent(uiEvent,value){this._eventBus&&(value instanceof PointerEvent?(this._eventBus.emit(GAME_UI_NAVIGATION_EVENT,uiEvent,1),this._eventBus.emit(GAME_UI_NAVIGATION_EVENT,uiEvent,0)):this._eventBus.emit(GAME_UI_NAVIGATION_EVENT,uiEvent,typeof value==`number`?value:value?1:0))}setActiveScope(scopeId){this._activeScope=scopeId}get activeScope(){return this._activeScope}activate(state=!0){this.attachEventListeners(state),this.eventsActive=state}hookGlobalEvents(state=!0){let listenerAction=document.body[state?`addEventListener`:`removeEventListener`];listenerAction(DOM_UI_NAVIGATION_EVENT,this.actionHandlers.handleGlobalEvent),this.globalEventsHooked=state}attachEventListeners(state=!0){this._eventBus&&(this._eventBus.off(GAME_UI_NAVIGATION_EVENT),this._eventBus.off(GAME_UI_NAV_MAP_ENABLED_EVENT),state&&(this._eventBus.on(GAME_UI_NAVIGATION_EVENT,this.handleGameEvent),this._eventBus.on(GAME_UI_NAV_MAP_ENABLED_EVENT,this.handleEnabledChange)))}setFilteredEvents(...events$3){this.clearFilteredEvents();let actionsToFilter=[...new Set(events$3.flat(1/0))].map(event=>ACTIONS_BY_UI_EVENT[event]);Lua_default.extensions.core_input_actionFilter.setGroup(UI_NAV_ACTION_GROUP,actionsToFilter),Lua_default.extensions.core_input_actionFilter.addAction(0,UI_NAV_ACTION_GROUP,!0)}setFilteredEventsAllExcept(...events$3){let eventsToNotFilter=[...new Set(events$3.flat(1/0))],eventsToFilter=Object.keys(ACTIONS_BY_UI_EVENT).filter(ev=>!eventsToNotFilter.includes(ev));this.setFilteredEvents(eventsToFilter)}clearFilteredEvents(){Lua_default.extensions.core_input_actionFilter.addAction(0,UI_NAV_ACTION_GROUP,!1),Lua_default.extensions.core_input_actionFilter.setGroup(UI_NAV_ACTION_GROUP,[])}set eventsActive(value){this._eventsActive=value}get eventsActive(){return this._eventsActive}set globalEventsHooked(value){this._globalEventsHooked=value}get globalEventsHooked(){return this._globalEventsHooked}get useCrossfire(){return this.actionHandlers.useCrossfire}set useCrossfire(value){this.actionHandlers.setUseCrossfire(value)}get eventBus(){return this._eventBus}},instance=null;const setUINavServiceInstance=serviceInstance=>{instance=serviceInstance},getUINavServiceInstance=()=>{if(!instance)throw Error(`UINavService not initialized.`);return instance},SCOPED_NAV_ATTR=`bng-scoped-nav`,SCOPED_NAV_PROPERTY_NAME=`_bngScopedNav`,UI_SCOPE_ATTR$1=`bng-ui-scope`,BNG_ON_UI_NAV_ATTR$1=`__BngOnUiNav`,ATTR_NAME$1=`bng-scoped-nav`,PASSTHROUGH_EXCLUDED_EVENTS=[UI_EVENTS.ok,UI_EVENTS.back,UI_EVENT_GROUPS.focusMove,UI_EVENT_GROUPS.focusMoveScalar],SCOPED_NAV_STATES={active:`full`,partial:`partial`,suspended:`suspended`,inactive:`inactive`},SCOPED_NAV_EVENTS={activate:`scopednav:activate`,deactivate:`scopednav:deactivate`,suspend:`scopednav:suspend`,resume:`scopednav:resume`},SCOPED_NAV_TYPES={normal:`normal`,container:`container`,nonav:`nonav`,popover:`popover`};var ScopeRegistry=class{constructor(){this.scopeRegistries=new WeakMap,this.depthCache=new WeakMap,this.cleanupTimers=new Map}clearDepthCache(scopeElement){this.depthCache.delete(scopeElement)}getCachedDepth(element,scopeElement){let scopeDepthCache=this.depthCache.get(scopeElement);if(scopeDepthCache||(scopeDepthCache=new Map,this.depthCache.set(scopeElement,scopeDepthCache)),!scopeDepthCache.has(element)){let depth=this._getElementDepth(element,scopeElement);scopeDepthCache.set(element,depth)}return scopeDepthCache.get(element)}register(scopeElement,handlerDescriptor){let scopeRegistry=this.scopeRegistries.get(scopeElement);scopeRegistry||(scopeRegistry={handlers:[],scopeHandler:null,initialized:!1},this.scopeRegistries.set(scopeElement,scopeRegistry));let existingIndex=scopeRegistry.handlers.findIndex(h$1=>h$1.element===handlerDescriptor.element&&this.descriptorsMatch(h$1.eventDescriptor,handlerDescriptor.eventDescriptor));return existingIndex===-1?scopeRegistry.handlers.push(handlerDescriptor):scopeRegistry.handlers[existingIndex]=handlerDescriptor,scopeRegistry.initialized||this.initializeScopeHandler(scopeElement,scopeRegistry),this.clearDepthCache(scopeElement),handlerDescriptor.handler}descriptorsMatch(desc1,desc2){return desc1.name===desc2.name&&desc1.modified===desc2.modified&&desc1.focusRequired===desc2.focusRequired}unregister(element,handlerController){let scopeElement=element.closest(`[${UI_SCOPE_ATTR$2}]`);if(!scopeElement)return;let scopeRegistry=this.scopeRegistries.get(scopeElement);if(!scopeRegistry)return;let handlerIndex=scopeRegistry.handlers.findIndex(h$1=>h$1.element===element&&h$1.handler===handlerController);handlerIndex!==-1&&(scopeRegistry.handlers.splice(handlerIndex,1),this.clearDepthCache(scopeElement)),this.scheduleCleanup(scopeElement,scopeRegistry)}scheduleCleanup(scopeElement,scopeRegistry){this.cleanupTimers.has(scopeElement)&&clearTimeout(this.cleanupTimers.get(scopeElement));let timerId=setTimeout(()=>{this.performCleanup(scopeElement,scopeRegistry),this.cleanupTimers.delete(scopeElement)},100);this.cleanupTimers.set(scopeElement,timerId)}performCleanup(scopeElement,scopeRegistry){scopeRegistry.handlers.length===0&&(scopeElement.removeEventListener(DOM_UI_NAVIGATION_EVENT,scopeRegistry.scopeHandler),this.scopeRegistries.delete(scopeElement),this.clearDepthCache(scopeElement))}destroy(){this.cleanupTimers.forEach(timer=>clearTimeout(timer)),this.cleanupTimers.clear(),this.depthCache=new WeakMap}initializeScopeHandler(scopeElement,scopeRegistry){let scopeHandler=event=>{let scopeId=scopeElement.getAttribute(UI_SCOPE_ATTR$2),uiNavService=getUINavServiceInstance(),targetScope=event.detail?.targetScope||uiNavService.activeScope;if(targetScope&&targetScope!==scopeId&&!this._isTargetScopeNested(targetScope,scopeElement)){console.warn(`UINav: Event target scope is not the intended scope. Ignoring event for this scope(${scopeId})`,{targetScope,scopeId});return}if(scopeElement._bngScopedNav&&scopeElement._bngScopedNav.canIgnoreEvent&&scopeElement._bngScopedNav.canIgnoreEvent(event)){event.stopPropagation();return}let isTargetActiveScope=targetScope===scopeId&&scopeId===uiNavService.activeScope,canPassthrough=isTargetActiveScope&&this._allowsPassthrough(scopeElement,event.detail),monitoredEvents=[...MONITORED_UI_NAV_EVENTS,UI_EVENTS.back];if(!(!isTargetActiveScope&&!canPassthrough&&!monitoredEvents.includes(event.detail.name))){if(!isTargetActiveScope&&!canPassthrough&&monitoredEvents.includes(event.detail.name)){this._executeScopedNavHandler(scopeElement,event,scopeRegistry.handlers)||event.stopPropagation();return}(!this._executeScopedBubbling(scopeElement,event,scopeRegistry.handlers)||!this._checkScopeBubbling(scopeElement,event))&&event.stopPropagation()}};scopeElement.addEventListener(DOM_UI_NAVIGATION_EVENT,scopeHandler),scopeRegistry.scopeHandler=scopeHandler,scopeRegistry.initialized=!0}_isTargetScopeNested(targetScopeId,currentScopeElement){let targetScopeElement=document.querySelector(`[${UI_SCOPE_ATTR$2}="${targetScopeId}"]`);return targetScopeElement?currentScopeElement.contains(targetScopeElement)&&targetScopeElement!==currentScopeElement:!1}_executeScopedNavHandler(scopeElement,event,handlers$1){let matchingHandlers=handlers$1.filter(h$1=>!h$1.disabled&&this._eventMatchesDescriptor(event.detail,h$1.eventDescriptor)&&h$1.element===scopeElement);if(matchingHandlers.length===0)return!0;let results=[];for(let handler$1 of matchingHandlers)try{let result=handler$1.handler(event);results.push(result)}catch(error){console.error(`Error in UINav scope handler:`,error,{element:handler$1.element,event:event.detail.name}),results.push(!1)}return results.some(result=>result===!0)}_executeScopedBubbling(scopeElement,event,handlers$1){let eventData=event.detail,matchingHandlers=handlers$1&&handlers$1.length>0?handlers$1.filter(h$1=>!h$1.disabled&&this._eventMatchesDescriptor(eventData,h$1.eventDescriptor)):[];if(matchingHandlers.length===0)return!0;let activeElement=document.activeElement,startElement=event.target;startElement=activeElement&&scopeElement.contains(activeElement)&&matchingHandlers.some(h$1=>h$1.element===activeElement)?activeElement:this._findDeepestHandlerElement(scopeElement,matchingHandlers);let bubblingPath=this._buildBubblingPath(startElement,scopeElement,matchingHandlers);return bubblingPath.length===0?(console.warn(`UINav: No bubbling path found.`,{scopeElement,event,handlers:handlers$1}),!0):this._executeHandlersAlongPath(bubblingPath,event)}_findDeepestHandlerElement(scopeElement,handlers$1){return[...new Set(handlers$1.map(h$1=>h$1.element))].filter(el=>this.getCachedDepth(el,scopeElement)<0?!1:!this._isElementInNestedScope(el,scopeElement)).sort((a$1,b)=>{let depthA=this.getCachedDepth(a$1,scopeElement);return this.getCachedDepth(b,scopeElement)-depthA})[0]||null}_isElementInNestedScope(element,currentScopeElement){let current=element;for(;current&¤t!==currentScopeElement;){if(current.hasAttribute(`bng-ui-scope`)&¤t!==currentScopeElement)return!0;current=current.parentElement}return!1}_buildBubblingPath(startElement,scopeElement,handlers$1){if(!scopeElement.contains(startElement))return console.warn(`UINav: Start element is outside scope boundary`,startElement,scopeElement),[];let path=[],current=startElement;for(;current&&scopeElement.contains(current);){let elementHandlers=handlers$1.filter(h$1=>h$1.element===current);if(elementHandlers.length>0&&path.push({element:current,handlers:elementHandlers}),current===scopeElement)break;current=current.parentElement}return path}_executeHandlersAlongPath(bubblingPath,event){for(let pathItem of bubblingPath){let results=[];for(let handlerDescriptor of pathItem.handlers)try{let result=handlerDescriptor.handler(event);results.push(result)}catch(error){console.error(`Error in UINav scope handler:`,error,{element:pathItem.element,event:event.detail.name}),results.push(!1)}if(!results.some(result=>result===!0))return!1}return!0}_checkScopeBubbling(scopeElement,event){let scopedNavProps=scopeElement._bngScopedNav;return scopedNavProps?scopedNavProps.shouldBubbleEvent&&typeof scopedNavProps.shouldBubbleEvent==`function`?scopedNavProps.shouldBubbleEvent(event):!1:!0}_getElementDepth(element,parent){let depth=0,current=element;for(;current&¤t!==parent;)depth++,current=current.parentElement;return current===parent?depth:-1}_allowsPassthrough(scopeElement,eventData){let domScopedNavProps=scopeElement.hasAttribute(`bng-scoped-nav`)?scopeElement[SCOPED_NAV_PROPERTY_NAME]:{};return domScopedNavProps.passthroughActive&&domScopedNavProps.passthroughEnabled&&domScopedNavProps.passthroughEvents.includes(eventData.name)}_eventMatchesDescriptor(eventData,descriptor){for(let[item,value]of Object.entries(descriptor))if(value!==void 0)if(item===`focusRequired`){if(value&&!value.contains(document.activeElement))return!1}else{if(!(item in eventData))return!1;if(typeof value==`function`){if(!value(eventData[item]))return!1}else if(eventData[item]!=value)return!1}return!0}};const isOnOffEvent=eventName=>!VALUE_BASED_EVENTS.includes(eventName),checkOn=value=>value,normalizeEventDescriptor=eventDescriptor=>({string:{name:eventDescriptor,value:isOnOffEvent(eventDescriptor)?checkOn:void 0,modified:!1,extras:void 0},object:{...eventDescriptor,value:`value`in eventDescriptor?eventDescriptor.value:isOnOffEvent(eventDescriptor.name)?checkOn:void 0}})[typeof eventDescriptor]||!1,eventMatchesDescriptor=(eventData,descriptor)=>{for(let[item,value]of Object.entries(descriptor))if(value!==void 0)if(item===`focusRequired`){if(value&&!value.contains(document.activeElement))return!1}else{if(!(item in eventData))return!1;if(typeof value==`function`){if(!value(eventData[item]))return!1}else if(eventData[item]!=value)return!1}return!0},getDescriptorEventNameText=descriptor=>descriptor.name?typeof descriptor.name==`function`?descriptor.name.name:descriptor.name:`ALL`;var HandlerFactory=class{static createHandler(eventDescriptor,userHandler){let descriptor=normalizeEventDescriptor(eventDescriptor);if(!descriptor)throw Error(`Invalid event descriptor when trying to create a UINav handler. Expecting a String or an Object.`);let handlerFuncName=userHandler?.name||`uiNav_${getDescriptorEventNameText(descriptor)}_handler`,disabled=!1;function wrapper(event){let eventData=event?.detail||{};return disabled||!eventMatchesDescriptor(eventData,descriptor)?!0:userHandler(event)}return Object.defineProperty(wrapper,`name`,{value:handlerFuncName}),Object.defineProperty(wrapper,`disabled`,{configurable:!1,get:()=>disabled,set:state=>{disabled=state}}),wrapper}static normalizeEventDescriptor(eventDescriptor){return{string:{name:eventDescriptor,value:isOnOffEvent(eventDescriptor)?checkOn:void 0,modified:!1,extras:void 0},object:{...eventDescriptor,value:`value`in eventDescriptor?eventDescriptor.value:isOnOffEvent(eventDescriptor.name)?checkOn:void 0}}[typeof eventDescriptor]||!1}},UINavHandlers=class{constructor(){this.scopeRegistry=new ScopeRegistry}add(domElement,uiNavHandlerOrDescriptor,handler$1=void 0){let scopeElement=domElement.closest(`[${UI_SCOPE_ATTR$2}]`);return scopeElement?this.addWithScope(domElement,uiNavHandlerOrDescriptor,handler$1,scopeElement):this.addIndividual(domElement,uiNavHandlerOrDescriptor,handler$1)}remove(domElement,uiNavHandler){domElement.closest(`[bng-ui-scope]`)?this.scopeRegistry.unregister(domElement,uiNavHandler):this.removeIndividual(domElement,uiNavHandler)}addWithScope(domElement,uiNavHandlerOrDescriptor,handler$1,scopeElement){let targetElement=domElement;if(!scopeElement.contains(targetElement))return console.error(`UINav: Attempting to register handler for element outside scope`,{targetElement,scopeElement,scopeId:scopeElement.getAttribute(UI_SCOPE_ATTR$2)}),this.addIndividual(domElement,uiNavHandlerOrDescriptor,handler$1);let wrapperHandler=handler$1?HandlerFactory.createHandler(uiNavHandlerOrDescriptor,handler$1):uiNavHandlerOrDescriptor,handlerDescriptor={element:domElement,eventDescriptor:HandlerFactory.normalizeEventDescriptor(uiNavHandlerOrDescriptor),handler:wrapperHandler,disabled:!1};return this.scopeRegistry.register(scopeElement,handlerDescriptor)}addIndividual(domElement,uiNavHandlerOrDescriptor,handler$1){let uiNavHandler=handler$1?HandlerFactory.createHandler(uiNavHandlerOrDescriptor,handler$1):uiNavHandlerOrDescriptor;return domElement.addEventListener(DOM_UI_NAVIGATION_EVENT,uiNavHandler),uiNavHandler}removeIndividual(domElement,uiNavHandler){domElement.removeEventListener(DOM_UI_NAVIGATION_EVENT,uiNavHandler)}},handlers_default=new UINavHandlers;function usePopupUINavScopeName(baseName,props){let attrs=useAttrs(),scopeName=baseName+`__`+attrs.__id;return useUINavScope(scopeName),watch(()=>props.popupActive,()=>props.popupActive&&useUINavScope(scopeName)),scopeName}function useUINavScope(scope$1=void 0,restoreScopeOnUnmount=!0){let currentScope=ref(scope$1),oldScope,scopeChanged=!1,setScope=newScope=>{scopeChanged=!0,currentScope.value=newScope,getUINavServiceInstance().setActiveScope(newScope)},restoreOldScope=()=>{getUINavServiceInstance().setActiveScope(oldScope)};return onMounted(()=>{oldScope=getUINavServiceInstance().activeScope,currentScope.value?setScope(currentScope.value):currentScope.value=oldScope}),onUnmounted(()=>{scopeChanged&&restoreScopeOnUnmount&&restoreOldScope()}),{current:computed(()=>currentScope.value),set:setScope,get oldScope(){return oldScope}}}function watchUINavEventChange(domElementRef,handler$1){return watch(()=>{if(!domElementRef.value)return{};let eventName=domElementRef.value.getAttribute(UI_EVENT_ATTR);return{eventName,action:ACTIONS_BY_UI_EVENT[eventName]}},handler$1)}const eventFirer=uiEvent=>value=>getUINavServiceInstance().fireEvent(uiEvent,value);var counter=0;const uniqueNum=()=>++counter%1e5+Math.random(),uniqueId=(name=``,separator=`.`)=>{let str=`${name?name+separator:``}${uniqueNum().toString(16)}`;return separator===`.`?str:str.replace(`.`,separator)},uniqueSafeId=()=>uniqueId(``,`_`);var DEFAULT_NAVIGATION=[...MONITORED_UI_NAV_EVENTS,`back`],ALWAYS_ACTIVE=[`ok`,`menu`,`back`],BLOCKER=Symbol(`uiNavBlocker`);const useUINavTracker=defineStore(`uiNavTracker`,()=>{let{lua,events:events$3}=useBridge(),showErrors=window.beamng&&!window.beamng.shipping,initialised=!1,trackedEvents=ref([]),trackedInstances={},ignoredEvents=ref([]),ignoredInstances={},blockedEvents$1=ref([]),blockedInstances={},unblockedEvents=ref([]),unblockedInstances={},activeEvents=ref([]),labelRegistry=useUiNavLabel();function updateBlocklist(){let uiNavService=getUINavServiceInstance(),eventsToBlock=blockedEvents$1.value.filter(name=>!unblockedEvents.value.includes(name));uiNavService.setBlockedEvents(eventsToBlock)}let raf;function update$6(eventName){cancelAnimationFrame(raf),raf=requestAnimationFrame(()=>{activeEvents.value=trackedEvents.value.filter(e=>!ignoredEvents.value.includes(e.name)&&(unblockedEvents.value.includes(e.name)||!blockedEvents$1.value.includes(e.name))).map(e=>({...e,nogroup:!!trackedInstances[e.name]?.at(-1)?.nogroup}))})}let ownerIdCheck=ownerId$1=>{if(typeof ownerId$1!=`string`||!ownerId$1)throw Error(`ownerId is required and must be a string`)},eventNameCheck=(eventName,quiet=!1)=>{let ok=!0;return typeof eventName!=`string`||!eventName?(showErrors&&logger_default.error(`eventName is required`),ok=!1):eventName in ACTIONS_BY_UI_EVENT||(showErrors&&!quiet&&logger_default.error(`eventName ${eventName} does not exist`),ok=!1),ok},getRecentInstance=eventName=>trackedInstances[eventName].findLast(inst=>inst.element!==BLOCKER),parseActive=(active,eventName)=>typeof active==`boolean`?active:ALWAYS_ACTIVE.includes(eventName);function addEvent(eventName,ownerId$1,element=null,options={}){if(initialised||rebind(),!eventNameCheck(eventName))return;ownerIdCheck(ownerId$1),trackedInstances[eventName]||(trackedInstances[eventName]=[]),element||=window.document.body;let instance$1=trackedInstances[eventName].find(instance$2=>instance$2.ownerId===ownerId$1);if(instance$1){instance$1.element=element,instance$1.nogroup=!!options?.nogroup,instance$1.active=parseActive(options?.active,eventName),update$6(eventName);return}if(trackedInstances[eventName].push({ownerId:ownerId$1,element,nogroup:!!options?.nogroup,active:parseActive(options?.active,eventName)}),trackedInstances[eventName].length===1){let event={name:eventName,label:computed(()=>{let instance$2=getRecentInstance(eventName);return labelRegistry.getLabel(eventName,instance$2?.element)||null}),action:computed(()=>getRecentInstance(eventName)?.active?eventFirer(eventName):null)};trackedEvents.value.push(event),actionSwitch(!0,eventName)}update$6(eventName)}function updateEvent(eventName,ownerId$1,element,options={}){if(ownerIdCheck(ownerId$1),!eventNameCheck(eventName))return;element||=window.document.body;let instance$1=trackedInstances[eventName]?.find(instance$2=>instance$2.ownerId===ownerId$1);if(!instance$1){addEvent(eventName,ownerId$1,element,!1,options);return}instance$1.element=element,instance$1.nogroup=!!options?.nogroup,instance$1.active=parseActive(options?.active,eventName),update$6(eventName)}function removeEvent(eventName,ownerId$1,element=null){if(ownerIdCheck(ownerId$1),!eventNameCheck(eventName)||!trackedInstances[eventName])return;element||=window.document.body;let idx=trackedInstances[eventName].findIndex(instance$1=>instance$1.ownerId===ownerId$1);if(idx!==-1&&(trackedInstances[eventName].splice(idx,1),update$6(eventName),trackedInstances[eventName].length===0)){delete trackedInstances[eventName];let idx$1=trackedEvents.value.findIndex(h$1=>h$1.name===eventName);idx$1>-1&&(trackedEvents.value.splice(idx$1,1),actionSwitch(!1,eventName))}}function addHelper(eventList,instanceList,eventName,ownerId$1,func,quiet=!1){ownerIdCheck(ownerId$1),eventNameCheck(eventName,quiet)&&(eventList.value.includes(eventName)||(eventList.value.push(eventName),func&&func(),instanceList[eventName]||(instanceList[eventName]=[])),instanceList[eventName].push(ownerId$1))}function removeHelper(eventList,instanceList,eventName,ownerId$1,func,quiet=!1){if(ownerIdCheck(ownerId$1),!eventNameCheck(eventName,quiet)||!(eventName in instanceList))return;let instIdx=instanceList[eventName].indexOf(ownerId$1);if(instIdx!==-1&&(instanceList[eventName].splice(instIdx,1),instanceList[eventName].length===0)){let idx=eventList.value.indexOf(eventName);idx>-1&&(eventList.value.splice(idx,1),func&&func())}}function addIgnore(eventName,ownerId$1){addHelper(ignoredEvents,ignoredInstances,eventName,ownerId$1,null,!0)}function removeIgnore(eventName,ownerId$1){removeHelper(ignoredEvents,ignoredInstances,eventName,ownerId$1,null,!0)}function addBlocker(eventName,ownerId$1){addHelper(blockedEvents$1,blockedInstances,eventName,ownerId$1,()=>{addEvent(eventName,ownerId$1,BLOCKER),updateBlocklist()})}function removeBlocker(eventName,ownerId$1){removeHelper(blockedEvents$1,blockedInstances,eventName,ownerId$1,()=>{removeEvent(eventName,ownerId$1,BLOCKER),updateBlocklist()})}function addForceUnblock(eventName,ownerId$1){addHelper(unblockedEvents,unblockedInstances,eventName,ownerId$1,()=>{update$6(eventName),updateBlocklist()})}function removeForceUnblock(eventName,ownerId$1){removeHelper(unblockedEvents,unblockedInstances,eventName,ownerId$1,()=>{update$6(eventName),updateBlocklist()})}let actionSwitch=async(enabled,eventName)=>{eventName!==`menu`&&(!enabled&&blockedEvents$1.value.includes(eventName)||await lua.extensions.core_input_bindings.setMenuActionEnabled(enabled,ACTIONS_BY_UI_EVENT[eventName]))};function rebind(){initialised||(initialised=!0,getUINavServiceInstance().clearBlockedEvents(),DEFAULT_NAVIGATION.forEach(name=>addEvent(name,`__uiNavTracker_default`))),Object.keys(ACTIONS_BY_UI_EVENT).filter(name=>!DEFAULT_NAVIGATION.includes(name)&&!trackedEvents.value.find(e=>e.name===name)).forEach(name=>actionSwitch(!1,name))}return lua.extensions.core_input_bindings.getMenuActionMapEnabled().then(enabled=>enabled&&rebind()),events$3.on(`MenuActionMapEnabled`,enabled=>enabled&&rebind()),{activeEvents,blockedEvents:blockedEvents$1,unblockedEvents,addEvent,updateEvent,removeEvent,addIgnore,removeIgnore,addBlocker,removeBlocker,addForceUnblock,removeForceUnblock}});function useUINavBlocker(){let id=uniqueId(`uiNavBlocker`),tracker=useUINavTracker(),allEventNames=Object.keys(ACTIONS_BY_UI_EVENT),defaultEvents=Object.freeze(Object.fromEntries(DEFAULT_NAVIGATION.map(name=>[name,name]))),allEvents=Object.freeze(UI_EVENTS),blockedEvents$1=[],unblockedEvents=[],filterEvents=events$3=>{if(!events$3)return[];if(typeof events$3==`string`)events$3=[events$3];else if(events$3.length===0)return[];return events$3.reduce((res,name)=>allEventNames.includes(name)&&!res.includes(name)?[...res,name]:res,[])};function allowOnly(events$3=[]){events$3=filterEvents(events$3),blockOnly(allEventNames.filter(name=>!events$3.includes(name)))}function allowNavigationOnly(enforce=!0){if(!enforce)return blockOnly();let events$3=[...DEFAULT_NAVIGATION,`menu`];blockOnly(allEventNames.filter(name=>!events$3.includes(name)))}function blockOnly(events$3=[]){events$3=filterEvents(events$3),blockedEvents$1.filter(name=>!events$3.includes(name)).forEach(name=>tracker.removeBlocker(name,id)),blockedEvents$1.splice(0),blockedEvents$1.push(...events$3),blockedEvents$1.forEach(name=>tracker.addBlocker(name,id))}function ensureNoBlock(events$3=[]){events$3=filterEvents(events$3),unblockedEvents.filter(name=>!events$3.includes(name)).forEach(name=>tracker.removeForceUnblock(name,id)),unblockedEvents.splice(0),unblockedEvents.push(...events$3),events$3.forEach(name=>tracker.addForceUnblock(name,id))}function isBlocked(eventName){return tracker.unblockedEvents.includes(eventName)?!1:tracker.blockedEvents.includes(eventName)}let clear=()=>blockOnly();return onUnmounted(clear),{allEvents,defaultEvents,allowOnly,allowNavigationOnly,blockOnly,clear,ensureNoBlock,isBlocked}}const useUiNavLabel=defineStore(`uiNavLabeler`,()=>{let elementLabels=reactive(new WeakMap),eventElements=reactive({});function registerLabel(element,eventNames,label){elementLabels.has(element)||elementLabels.set(element,{});let elementEvents=elementLabels.get(element);Array.isArray(eventNames)||(eventNames=[eventNames]);for(let eventName of eventNames)elementEvents[eventName]=label,eventElements[eventName]||(eventElements[eventName]=new Set),eventElements[eventName].add(element)}function clearLabels(element,eventNames=null){if(!elementLabels.has(element))return;let elementEvents=elementLabels.get(element);if(eventNames===null){for(let eventName of Object.keys(elementEvents))eventElements[eventName]&&eventElements[eventName].delete(element);elementLabels.delete(element)}else{for(let eventName of eventNames)delete elementEvents[eventName],eventElements[eventName]&&eventElements[eventName].delete(element);Object.keys(elementEvents).length===0&&elementLabels.delete(element)}}function getLabel(eventName,element=null){if(element&&elementLabels.has(element)&&elementLabels.get(element)[eventName])return elementLabels.get(element)[eventName];if(eventElements[eventName])for(let el of eventElements[eventName]){let label=elementLabels.get(el)?.[eventName];if(label)return label}return null}function getElementEvents(element){return elementLabels.has(element)?Object.keys(elementLabels.get(element)):[]}return{registerLabel,clearLabels,getLabel,getElementEvents}});var LUA_EXTENSION_NAME=`ui_topBar`;const useTopBar=defineStore(`topBar`,()=>{let{events:events$3}=useBridge(),setupComplete=!1,_items=ref({}),_activeItem=ref(null),visible=ref(!1),hiddenItems=ref([]),gameState$1=reactive({isInGame:void 0,gameState:void 0,uiState:void 0,isCareerActive:void 0,isGarageActive:void 0,isMissionActive:void 0,isScenarioActive:void 0}),sortItems=(a$1,b)=>(a$1.order??0)-(b.order??0),items$2=computed(()=>Object.values(_items.value).filter(item=>!hiddenItems.value||!hiddenItems.value.includes(item.id)).sort(sortItems)),activeItem=computed({get:()=>_activeItem.value,set:value=>{value!==_activeItem.value&&(_activeItem.value=value,Lua_default.ui_topBar.setActiveItem(value))}}),updateTopBarVisibility=()=>{if(!(!gameState$1.uiState||gameState$1.isInGame===void 0)){if(gameState$1.uiState.startsWith(`menu.mainmenu`)&&!gameState$1.isInGame&&(visible.value=!1),!visible.value||gameState$1.uiState===`unknown`){activeItem.value=null;return}if(gameState$1.uiState){let updatedActiveItem=Object.values(_items.value).find(item=>item.targetState===gameState$1.uiState);updatedActiveItem||=Object.values(_items.value).find(item=>item.substate&&gameState$1.uiState.startsWith(item.substate)),activeItem.value=updatedActiveItem?updatedActiveItem.id:null}updateHiddenItems()}};watch(()=>gameState$1.uiState,()=>nextTick(updateTopBarVisibility)),watch(()=>gameState$1.isInGame,()=>nextTick(updateTopBarVisibility));let selectPrevious=()=>{if(!visible.value)return;let len=items$2.value.length;if(len===0)return;let previousIndex=(items$2.value.findIndex(item=>item.id===activeItem.value)-1+len)%len;selectEntry(items$2.value[previousIndex].id)},selectNext=()=>{if(!visible.value)return;let len=items$2.value.length;if(len===0)return;let nextIndex=(items$2.value.findIndex(item=>item.id===activeItem.value)+1)%len;selectEntry(items$2.value[nextIndex].id)},selectEntry=itemId=>{visible.value&&(activeItem.value=itemId,Lua_default.ui_topBar.selectItem(itemId))},show=()=>{visible.value=!0},hide$2=()=>{visible.value=!1};function updateHiddenItems(){hiddenItems.value=Object.values(_items.value).filter(shouldHideItem).map(item=>item.id)}function shouldHideItem(item){if(!item.flags||item.flags.length===0)return!1;for(let flag of item.flags)if(flag===`inGameOnly`&&!gameState$1.isInGame||flag===`careerOnly`&&!gameState$1.isCareerActive||flag===`noCareer`&&gameState$1.isCareerActive||flag===`missionOnly`&&!gameState$1.isMissionActive||flag===`noMission`&&gameState$1.isMissionActive&&!gameState$1.isScenarioUnrestricted||flag===`garageOnly`&&!gameState$1.isGarageActive||flag===`noGarage`&&gameState$1.isGarageActive||flag===`scenarioOnly`&&!gameState$1.isScenarioActive||flag===`noScenario`&&gameState$1.isScenarioActive&&!gameState$1.isScenarioUnrestricted||flag===`careerGarageOnly`&&(!gameState$1.isCareerActive||!gameState$1.isGarageActive)||flag===`noCareerGarage`&&gameState$1.isCareerActive&&gameState$1.isGarageActive)return!0;return!1}function onCareerStateChanged(data){gameState$1.isCareerActive=data.isActive}function onGarageStateChanged(data){gameState$1.isGarageActive=data.isActive}function onMissionStateChanged(data){gameState$1.isMissionActive=data.isActive}function onScenarioStateChanged(data){gameState$1.isScenarioActive=data.isActive}function onDataRequested(data){let{isInGame,items:dataItems}=data;_items.value=dataItems,gameState$1.isInGame=isInGame,hiddenItems.value=[]}function onGameStateChanged(data){gameState$1.isInGame=data.isInGame,gameState$1.isCareerActive=data.isCareerActive,gameState$1.isGarageActive=data.isGarageActive,gameState$1.isMissionActive=data.isMissionActive,gameState$1.isScenarioActive=data.isScenarioActive,gameState$1.isScenarioUnrestricted=data.isScenarioUnrestricted,nextTick(()=>updateHiddenItems())}function onEntriesChanged(data){_items.value=data}function onVisibleItemsChanged(data){hiddenItems.value=data}function onShow(){visible.value=!0}function onHide(){visible.value=!1}let debouncedStateChange=debounce(data=>{gameState$1.uiState=(data.fullPath||data.name||`unknown`).replace(/^\//,``)},100);function onUIStateChanged(data){debouncedStateChange(data)}let eventHandlerMap={selectPrevious,selectNext,OnCareerActive:onCareerStateChanged,garageStateChanged:onGarageStateChanged,missionStateChanged:onMissionStateChanged,scenarioStateChanged:onScenarioStateChanged,dataRequested:onDataRequested,gameStateChanged:onGameStateChanged,entriesChanged:onEntriesChanged,visibleItemsChanged:onVisibleItemsChanged,show:onShow,hide:onHide};function addListeners(){for(let eventName of Object.keys(eventHandlerMap))events$3.on(`${LUA_EXTENSION_NAME}_${eventName}`,eventHandlerMap[eventName])}function removeListeners$1(){for(let eventName of Object.keys(eventHandlerMap))events$3.off(`${LUA_EXTENSION_NAME}_${eventName}`,eventHandlerMap[eventName])}return(async()=>{setupComplete||=(await Lua_default.extensions.isExtensionLoaded(LUA_EXTENSION_NAME)||await Lua_default.extensions.load(LUA_EXTENSION_NAME),addListeners(),await Lua_default.ui_topBar.requestData(),!0)})(),{activeItem,items:items$2,visible,gameState:gameState$1,show,hide:hide$2,selectEntry,selectPrevious,selectNext,onUIStateChanged,dispose:()=>{removeListeners$1(),Lua_default.extensions.unload(LUA_EXTENSION_NAME)}}});var events$2,beamNG,serviceProviders=ref(),online=ref(!1),videoAdapter=ref(``),modCounts=ref({total:0,active:0}),gameState=ref(),mainMenuBackgroundRequired=ref(),mainMenuFirstTime=ref(!0),serviceProvidersOnline=computed(()=>{let provs=serviceProviders.value,gotInfo=!!provs,ret={eos:gotInfo&&provs.eos&&provs.eos.loggedin,steam:gotInfo&&provs.steam&&provs.steam.loggedin&&provs.steam.working};return ret.any=Object.values(ret).some(v=>v),ret}),version,versionSimple,buildInfo,init$2=()=>{let api$1;({api:api$1,events:events$2,beamNG}=useBridge()),beamNG||=FAKE_BEAMNG_OBJ,api$1.serializeToLuaCheck(`English: hello`),api$1.serializeToLuaCheck(`Spanish: güeñes`),api$1.serializeToLuaCheck(`French: bâguéttè, garçon`),api$1.serializeToLuaCheck(`Czech: Kl�vesnice`),api$1.serializeToLuaCheck(`Korean: \r��\v��\v��`),api$1.serializeToLuaCheck(`Chinese Sim: 欢迎来到简体中文版的`),api$1.serializeToLuaCheck(`Chinese Tr: 歡迎來到`),api$1.serializeToLuaCheck(`Japanese: 』日本語版にようこそ`),api$1.serializeToLuaCheck(`Polish: źćłąóę`),api$1.serializeToLuaCheck(`Russian: абвгеёьъ`),events$2.on(`ServiceProviderInfo`,info=>serviceProviders.value=info),events$2.on(`OnlineStateChanged`,state=>online.value=state),events$2.on(`ModManagerModsChanged`,_processModData),events$2.on(`ShowEntertainingBackground`,state=>mainMenuBackgroundRequired.value=state),events$2.on(`GameStateUpdate`,state=>gameState.value=state.state),version=beamNG.version,versionSimple=_toSimpleVersion(beamNG.version),buildInfo=beamNG.buildinfo,refresh()},refresh=()=>{_requestServiceProviders(),_requestOnlineState(),_refreshVideoAdapter(),_refreshModData()},_refreshVideoAdapter=()=>Lua_default.Engine.Render.getAdapterType().then(adapter=>videoAdapter.value=adapter),_requestServiceProviders=()=>beamNG.requestServiceProviderInfo(),_requestOnlineState=()=>Lua_default.core_online.requestState(),_refreshModData=()=>Lua_default.core_modmanager.requestState(),sysInfo_default={init:init$2,refresh,serviceProviders,serviceProvidersOnline,online,videoAdapter,modCounts,gameState,mainMenuBackgroundRequired,mainMenuFirstTime,get version(){return version},get versionSimple(){return versionSimple},get buildInfo(){return buildInfo}},_toSimpleVersion=versionStr=>{let bits=versionStr.split(`.`);return bits.length==5&&bits.pop(),bits.join(`.`).replace(/(\.0)+$/,``)},_processModData=data=>{let mods=Object.values(data).filter(mod=>mod.modname!=`translations`);modCounts.value.total=mods.length,modCounts.value.active=mods.filter(({active})=>active).length},FAKE_BEAMNG_OBJ={version:`0.12.3.4.FAKE12345`,buildInfo:`Sample Fake BuildInfo - running outside of game`,requestServiceProviderInfo(){events$2.emit(`ServiceProviderInfo`,{steam:{loggedin:!0,accountID:`12345678901234567`,playerName:`fakeplayer`,branch:`qa_latest`,language:`english`,useSteam:!0,working:!0}})}};const useLibStore=defineStore(`lib`,{});var bridge$2,stateStack=[];function add(stateName){rem(stateName),stateStack.push(stateName)}function rem(stateName){let idx=stateStack.lastIndexOf(stateName);idx>-1&&stateStack.splice(idx,1)}var luaStringify=any=>JSON.stringify(any).replace(/^\[(.*)\]$/,`{$1}`),luaReport=(stateName,opened)=>bridge$2.api.engineLua(`extensions.hook("onUIStateTriggered", ${luaStringify(stateName)}, ${luaStringify(!!opened)}, ${luaStringify(stateStack)})`);function reportState(stateName,opened,prevName=null){bridge$2||=useBridge(),prevName&&(rem(prevName),luaReport(prevName,!1)),opened?add(stateName):rem(stateName),luaReport(stateName,opened)}function reportPopupState(popup,opened){reportState(`/popup/${popup.componentName}/${popup.wrapper.blur?`fullscreen`:`aside`}`,opened)}function scroll(el,binding){let direction$1=binding.arg;el.scrollHeight<=el.clientHeight||(direction$1===`top`?el.scrollTop>0&&(el.scrollTop=0):direction$1===`bottom`&&el.scrollTop{let id,blurAmount=1,blurUpdateWrapper=debounce(updateBlur,50),resizeObserver,removePositionObserver;function observe(){resizeObserver||(resizeObserver=new ResizeObserver(blurUpdateWrapper),resizeObserver.observe(el)),removePositionObserver||=observePosition(el,blurUpdateWrapper)}function unobserve(){resizeObserver&&resizeObserver.disconnect(),removePositionObserver&&removePositionObserver(),resizeObserver=null,removePositionObserver=null}elemBlurs.set(el,{blurUpdateWrapper,processBlurVal,observe,unobserve}),processBlurVal(binding.value),window.addEventListener(`resize`,blurUpdateWrapper);function processBlurVal(val){switch(typeof val){case`undefined`:val=1;break;case`boolean`:val=val?1:0;break;case`number`:(val<0||val>1)&&(logger_default.error(`Attempted to use v-bng-blur with a number out of range 0..1: ${val}\nSee stack:`,logger_default.STACK_TRACE),val=1);break;default:logger_default.error(`Attempted to use v-bng-blur with a non-number, non-boolean value: ${val}\nSee stack:`,logger_default.STACK_TRACE),val=0}blurAmount=val,blurUpdateWrapper()}function calcBlur(){let rect=el.getBoundingClientRect();return rect.width>0&&rect.height>0&&rect.bottom>0&&rect.top0&&rect.left{let elemBlur=elemBlurs.get(el);elemBlur&&binding.value!=binding.oldValue&&elemBlur.processBlurVal(binding.value)},unmounted:(el,binding)=>{let elemBlur=elemBlurs.get(el);elemBlur&&(elemBlur.unobserve(),elemBlur.processBlurVal(0),window.removeEventListener(`resize`,elemBlur.blurUpdateWrapper),elemBlurs.delete(el))}},DEFAULT_HOLD_DELAY=400,DEFAULT_REPEAT_INTERVAL=100,HOLD_CSS_TIME_VAR=`--hold-time`,HOLD_START_CSS_CLASS=`hold-start`,HOLD_ACTIVE_CSS_CLASS=`hold-active`,HOLD_COMPLETED_CSS_CLASS=`hold-completed`,EVENT_CLICK=`click`,EVENT_HOLD=`hold`,ELEMENT_ID=`__BNG_CLICK_ID`,curId=0,datas={};function update$5(element,binding){let id=element[ELEMENT_ID]||(element[ELEMENT_ID]=++curId),data=datas[id]||(datas[id]={id,element,events:{},binding:{}});if(typeof binding.value==`object`)data.binding=binding.value;else if(typeof binding.value==`function`){let cbName=binding.modifiers?.hold?`holdCallback`:`clickCallback`;data.binding[cbName]=binding.value}return data.controllerOnly=!!binding.modifiers?.controller,data.hasClick=typeof data.binding.clickCallback==`function`,data.hasHold=typeof data.binding.holdCallback==`function`,typeof data.binding.holdDelay!=`number`&&(data.binding.holdDelay=DEFAULT_HOLD_DELAY),typeof data.binding.repeatInterval!=`number`&&(data.binding.repeatInterval=DEFAULT_REPEAT_INTERVAL),data}function remove(element){let id=element[ELEMENT_ID];if(!id)return;let data=datas[id];data&&(`mouseleave`in data.events&&data.events.mouseleave(),updateEvents(id),delete datas[id],delete element[ELEMENT_ID])}function updateEvents(id,events$3={}){let data=datas[id];if(data){for(let event in data.events)data.element.removeEventListener(event,data.events[event]);for(let event in events$3)data.element.addEventListener(event,events$3[event]);data.events=events$3}}var BngClick_default={mounted:(el,binding)=>{let data=update$5(el,binding),approveEvent=evt=>data.controllerOnly?!!evt.fromController:evt.button===0||evt.fromController,tmrHoldActive;updateEvents(data.id,{mousedown:e=>{approveEvent(e)&&(el.style.setProperty(HOLD_CSS_TIME_VAR,`${data.binding.holdDelay}ms`),el.classList.toggle(HOLD_START_CSS_CLASS,!0),clearTimeout(tmrHoldActive),tmrHoldActive=setTimeout(()=>el.classList.toggle(HOLD_ACTIVE_CSS_CLASS,!0),0),el.classList.toggle(HOLD_COMPLETED_CSS_CLASS,!1),canInvokeEventType(EVENT_CLICK)&&(detectedEventType=EVENT_CLICK),canInvokeEventType(EVENT_HOLD)&&startHoldDelayTimer(e))},mouseup:e=>{if(approveEvent(e)){switch(el.style.removeProperty(HOLD_CSS_TIME_VAR),el.classList.toggle(HOLD_START_CSS_CLASS,!1),el.classList.toggle(HOLD_ACTIVE_CSS_CLASS,!1),clearTimeout(tmrHoldActive),stopHoldDelayTimer(),detectedEventType){case EVENT_CLICK:doAction(EVENT_CLICK,e);break;case EVENT_HOLD:stopHoldTimer();break}detectedEventType=null}},mouseleave:()=>{switch(el.style.removeProperty(HOLD_CSS_TIME_VAR),el.classList.toggle(HOLD_START_CSS_CLASS,!1),el.classList.toggle(HOLD_ACTIVE_CSS_CLASS,!1),clearTimeout(tmrHoldActive),stopHoldDelayTimer(),detectedEventType){case EVENT_HOLD:stopHoldTimer();break}detectedEventType=null},blur:()=>data.events.mouseleave()});let detectedEventType,holdDelayTimer,holdTimer;function startHoldDelayTimer(e){stopHoldTimer(),stopHoldDelayTimer(),holdDelayTimer=setTimeout(()=>{el.classList.toggle(HOLD_COMPLETED_CSS_CLASS,!0),detectedEventType=EVENT_HOLD,startHoldTimer(e)},data.binding.holdDelay)}function stopHoldDelayTimer(){holdDelayTimer&&=(clearTimeout(holdDelayTimer),null)}function startHoldTimer(e){doAction(EVENT_HOLD,e),data.binding.repeatInterval&&(stopHoldTimer(),holdTimer=setInterval(()=>{doAction(EVENT_HOLD,e)},data.binding.repeatInterval))}function stopHoldTimer(){holdTimer&&=(clearInterval(holdTimer),null)}function doAction(eventType,originalEvent){let callback=getCallback(eventType);callback&&(eventType==EVENT_HOLD?setTimeout(()=>callback(originalEvent),100):callback(originalEvent))}function getCallback(arg){switch(arg){case EVENT_CLICK:return data.binding.clickCallback;case EVENT_HOLD:return data.binding.holdCallback}return null}function canInvokeEventType(eventType){switch(eventType){case EVENT_CLICK:return data.hasClick;case EVENT_HOLD:return data.hasHold}return!1}},updated:update$5,beforeUnmount:remove},BngDisabled_default=(el,{value})=>{let has$1={disabled:el.hasAttribute(`disabled`),tabindex:el.hasAttribute(`tabindex`)};!has$1.disabled&&value?(el.setAttribute(`disabled`,`disabled`),has$1.tabindex&&(el._BNG_TABINDEX=el.getAttribute(`tabindex`),el.setAttribute(`tabindex`,`-1`))):has$1.disabled&&!value&&(el.removeAttribute(`disabled`),has$1.tabindex&&`_BNG_TABINDEX`in el&&el.getAttribute(`tabindex`)!==el._BNG_TABINDEX&&(el.setAttribute(`tabindex`,el._BNG_TABINDEX),delete el._BNG_TABINDEX))},DELAY=300,EVENTS_IN=[`uinav-focus`,`focus`,`focusin`],EVENTS_OUT=[`uinav-blur`,`blur`,`focusout`],elems$1=new Map,globInit=!1;function initGlobals(){globInit=!0;let running=!1,targets={in:[],out:[]};function preventer(){for(let[part,list]of Object.entries(targets))if(list.length!==0){for(let target of list)for(let[uid$2,data]of elems$1)if(!(!data.capture||!data.timer||!data.element)){if(part===`in`){if(data.element===target||data.element.contains(target))continue}else if(data.element!==target&&!data.element.contains(target))continue;clearTimeout(data.timer),data.timer=null;break}list.splice(0)}}function handler$1(evt,eventIn){if(elems$1.size===0)return;let target=evt.detail?.target||evt.target;if(!target)return;let part=eventIn?`in`:`out`;targets[part].includes(target)||targets[part].push(target),!running&&(running=!0,window.requestAnimationFrame(()=>{preventer(),running=!1}))}EVENTS_IN.forEach(evt=>document.addEventListener(evt,evt$1=>handler$1(evt$1,!0),!0)),EVENTS_OUT.forEach(evt=>document.addEventListener(evt,evt$1=>handler$1(evt$1,!1),!0))}function createHandler(data){return data.capture?evt=>{evt.detail?.doubleToSingle||(evt.preventDefault(),evt.stopImmediatePropagation(),data.timer?(clearTimeout(data.timer),data.timer=null,data.callback?.()):data.timer=setTimeout(()=>{data.timer=null;let click$1=new CustomEvent(`click`,{...evt,bubbles:!0,cancelable:!0,detail:{doubleToSingle:!0}});data.element.dispatchEvent(click$1)},DELAY))}:()=>{data.timer&&=(clearTimeout(data.timer),null);let now$1=Date.now();if(data.time&&now$1-data.time<=DELAY){data.time=0,data.callback?.();return}data.time=now$1}}function update$4(vnode,callback=void 0,mod={}){!globInit&&initGlobals();let el=vnode?.el;if(!el)return;let uid$2=vnode?.component?.uid||vnode?.key||el,capture=!!mod.capture,data=elems$1.get(uid$2)||{};data.handler&&data.element===el&&callback&&`callback`in data&&data.callback===callback&&data.capture===capture||(`element`in data||(data.element=el,data.callback=callback,data.capture=capture),data.handler&&(!callback||data.capture!==capture||data.element!==el)&&(delete data.callback,el.removeEventListener(`click`,data.handler,{capture:data.capture}),elems$1.delete(uid$2)),callback&&(data.handler?data.callback=callback:(data.capture=capture,data.handler=createHandler(data),el.addEventListener(`click`,data.handler,{capture}),elems$1.set(uid$2,data))))}var BngDoubleClick_default={mounted:(el,{value,modifiers,arg}={},vnode)=>update$4(vnode||{el},value,{capture:arg===`capture`,...modifiers}),updated:(el,{value,modifiers,arg}={},vnode)=>update$4(vnode||{el},value,{capture:arg===`capture`,...modifiers}),unmounted:(el,vnode)=>update$4(vnode||{el})},DRAG_START_EVENT_NAME=`bngDragStart`,DRAG_OVER_EVENT_NAME=`bngDragOver`,DRAG_END_EVENT_NAME=`bngDragEnd`;const DRAG_EVENTS=Object.freeze({dragStart:DRAG_START_EVENT_NAME,dragOver:DRAG_OVER_EVENT_NAME,dragEnd:DRAG_END_EVENT_NAME});var STORE_NAME=`controls`,store,DEVICE_ICONS={key:`keyboard`,mou:`mouseLMB`,vin:`smartphone2`,whe:`steeringWheelCommon`,gam:`gamepadOld`,xin:`gamepadOld`,default:`gamepad`};const CONTROL_LABELS={escape:`ESC`,enter:`⏎`,tab:`⭾`,capslock:`⇪`,backspace:`⌫`,delete:`Del`,insert:`Ins`,home:`Home`,end:`End`,pageup:`PG↑`,pagedown:`PG↓`,lshift:`L⇧`,rshift:`R⇧`,shift:`⇧`,lcontrol:`L Ctrl`,rcontrol:`R Ctrl`,lalt:`L Alt`,ralt:`R Alt`,left:`←`,right:`→`,up:`↑`,down:`↓`,space:`␣`,grave:`~`,backslash:`\\`,"/":`/`,comma:`,`,period:`.`,";":`;`,apostrophe:`'`,"[":`[`,"]":`]`,minus:`-`,"+":`NP+`,"*":`NP*`,numpaddivide:`NP/`,numpad0:`NP0`,numpad1:`NP1`,numpad2:`NP2`,numpad3:`NP3`,numpad4:`NP4`,numpad5:`NP5`,numpad6:`NP6`,numpad7:`NP7`,numpad8:`NP8`,numpad9:`NP9`,numpaddecimal:`NP.`,numpadenter:`NP⏎`,xaxis:`X Axis`,yaxis:`Y Axis`,zaxis:`Z Axis`,rzaxis:`R Z Axis`,thumblx:`L Thumb X`,thumbly:`L Thumb Y`,thumbrx:`R Thumb X`,thumbry:`R Thumb Y`};var controlLabel=control=>control.toLowerCase().split(/[ -]+/).map(ctl=>CONTROL_LABELS[ctl]||(ctl.startsWith(`button`)?`BTN`+ctl.substring(6):ctl)).join(` + `),CONTROL_ICONS={pc_mouse:{button0:`mouseLMB`,button1:`mouseRMB`,button2:`mouseMMB`,xaxis:`mouseXAxis`,yaxis:`mouseYAxis`,zaxis:`mouseWheel`},xbox:{btn_a:`xboxA`,btn_b:`xboxB`,btn_x:`xboxX`,btn_y:`xboxY`,btn_back:`xboxView`,btn_start:`xboxMenu`,btn_l:`xboxLB`,triggerl:`xboxLT`,btn_r:`xboxRB`,triggerr:`xboxRT`,dpov:`xboxDDown`,lpov:`xboxDLeft`,rpov:`xboxDRight`,upov:`xboxDUp`,thumblx:`xboxXAxis`,thumbly:`xboxYAxis`,thumbrx:`xboxXRot`,thumbry:`xboxYRot`,btn_lt:`xboxLSButton`,btn_rt:`xboxRSButton`},ps:{button1:`psCross`,button3:`psTriangle`,button0:`psSquare`,button2:`psCircle`,button8:`psCreate2`,button9:`psMenu2`,button4:`psL1`,button6:`psL2`,button5:`psR1`,button7:`psR2`,dpov:`psDDown`,lpov:`psDLeft`,rpov:`psDRight`,upov:`psDUp`,xaxis:`psLSX`,yaxis:`psLSY`,zaxis:`psRSX`,rzaxis:`psRSY`,rxaxis:`psL2`,ryaxis:`psR2`,button10:`psL3Button`,button11:`psR3Button`,button13:`psTrackpadPressCenter`}};const DEVICE_CONTROLS={pc_mouse:Object.keys(CONTROL_ICONS.pc_mouse),xbox:Object.keys(CONTROL_ICONS.xbox),ps:Object.keys(CONTROL_ICONS.ps)};var extendControlGroupNames=groups=>groups.reduce((res,group)=>(res.push(group),res.push({...group,controls:group.controls.map(ctl=>CONTROL_LABELS[ctl])}),res),[]),GROUPED_CONTROLS={pc_keyboard:extendControlGroupNames([{label:`↑↓←→`,controls:[`left`,`right`,`up`,`down`]},{label:`NP 8↑ 2↓ 4← 6→`,controls:[`numpad2`,`numpad4`,`numpad6`,`numpad8`]}]),xbox:extendControlGroupNames([{icon:`xboxDDefaultSolid`,controls:[`upov`,`dpov`,`lpov`,`rpov`]},{icon:`xboxThumbL`,controls:[`thumblx`,`thumbly`]},{icon:`xboxThumbR`,controls:[`thumbrx`,`thumbry`]}]),ps:extendControlGroupNames([{icon:`psDDefaultSolid`,controls:[`upov`,`dpov`,`lpov`,`rpov`]},{icon:`psLS`,controls:[`xaxis`,`yaxis`]},{icon:`psRS`,controls:[`zaxis`,`rzaxis`]}])},DEVICE_FAMILY={mouse:`pc_mouse`,keyboard:`pc_keyboard`,xinput:`xbox`,ps5:`ps`},CONTROL_ICON_KEYS=Object.keys(DEVICE_FAMILY),getViewerOverrides=(devName=void 0,imagePack=void 0)=>{let family;return imagePack&&(imagePack in DEVICE_FAMILY?family=DEVICE_FAMILY[imagePack]:imagePack in CONTROL_ICONS&&(family=imagePack)),!family&&devName&&(devName=CONTROL_ICON_KEYS.find(key=>devName.startsWith(key))||devName,devName in DEVICE_FAMILY?family=DEVICE_FAMILY[devName]:devName in CONTROL_ICONS&&(family=devName)),family?{family,icons:CONTROL_ICONS[family]||{},groups:GROUPED_CONTROLS[family]||[]}:null},DEVICE_ORDER=[`wheel`,`joystick`,`xinput`,`gamepad`,`mouse`,`keyboard`],makeStore=defineStore(STORE_NAME,()=>{let{events:events$3}=useBridge(),devNamesOrder=DEVICE_ORDER.map(devType=>devType+`0`),actions=ref([]),categories=ref({}),categoriesList=ref([]),bindings=ref([]),bindingsPerDevice=computed(()=>Object.fromEntries(bindings.value.map(b=>[b.devname,b]))),bindingTemplate=ref({}),controllers=ref({}),players=ref({}),lastDeviceOrder=ref([...devNamesOrder]),lastDevice=computed(()=>isKbm(lastDeviceOrder.value[0])?kbmDevNames:lastDeviceOrder.value[0]),lastControllers=computed(()=>lastDeviceOrder.value.filter(devName=>!isKbm(devName))),lastControllersSignature=computed(()=>lastControllers.value.sort().join(`::`)),isControllerUsed=computed(()=>!isKbm(lastDeviceOrder.value[0])),isControllerAvailable=computed(()=>lastDeviceOrder.value.some(devName=>!isKbm(devName))),lastDeviceSimple=computed(()=>isControllerUsed.value?lastDevice.value:null),getDevType=devName=>devName?devName.replace(/\d+$/,``):``,deviceSorter=(a$1,b)=>DEVICE_ORDER.indexOf(getDevType(a$1))-DEVICE_ORDER.indexOf(getDevType(b)),kbmDevNames=[`keyboard0`,`mouse0`].sort(deviceSorter),kbmShortNames=kbmDevNames.map(devName=>devName.slice(0,3)),isKbm=devName=>devName&&kbmShortNames.includes(devName.slice(0,3)),_receiveControlsData=data=>(controllers.value=data,_updateDeviceNotes()),_receivePlayersData=data=>players.value=data,_receiveBindingsData=_processBindingsData,_getBindingsData=()=>Lua_default.extensions.core_input_bindings.notifyUI(`Vue controls service needs the data`),connect=(state=!0)=>{let method=state?`on`:`off`;events$3[method](`ControllersChanged`,_receiveControlsData),events$3[method](`AssignedPlayersChanged`,_receivePlayersData),events$3[method](`InputBindingsChanged`,_receiveBindingsData),events$3[method](`RecentDevicesChanged`,_requestRecentDevices)},disconnect=()=>connect(!1),deviceIcon=deviceName=>DEVICE_ICONS[(deviceName||``).slice(0,3)]||DEVICE_ICONS.default;async function _requestRecentDevices(devNames=void 0){devNames||=await Lua_default.extensions.core_input_bindings.getRecentDevices(),!Array.isArray(devNames)||devNames.length===0?devNames=devNamesOrder:isKbm(devNames[0])&&(devNames=[...kbmDevNames,...devNames.filter(devName=>!isKbm(devName))]),lastDeviceOrder.value.splice(0,lastDeviceOrder.value.length,...devNames)}function*getBindingsIter(devFilter=[],useLastDeviceOrder=!1){if(!useLastDeviceOrder||devFilter.length>0)yield*bindings.value;else for(let devName of lastDeviceOrder.value){let binding=bindingsPerDevice.value[devName];binding&&(yield binding)}}let findBindingForAction=(action,devName=void 0,useLastDeviceOrder=!1)=>{let devFilter=devName?Array.isArray(devName)?devName:[devName]:[],bindingsIter=getBindingsIter(devFilter,useLastDeviceOrder);for(let binding of bindingsIter){if(devFilter.length>0&&!devFilter.includes(binding.devname))continue;let found=binding.contents.bindings.find(b=>b.action===action);if(found){let help=getBindingDetails(binding.devname,found.control,action);if(help)return help.devName=binding.devname,help.imagePack=binding.contents.imagePack,help}}},findAllBindingsForAction=(action,devName=void 0,allDevices=!1,useLastDeviceOrder=!1)=>{let res=[],devFilter=devName?Array.isArray(devName)?devName:[devName]:[],bindingsIter=getBindingsIter(devFilter,useLastDeviceOrder);for(let binding of bindingsIter){if(devFilter.length>0&&!devFilter.includes(binding.devname))continue;let matches$1=binding.contents.bindings.filter(b=>b.action===action);if(matches$1.length>0)for(let match of matches$1){let help=getBindingDetails(binding.devname,match.control,action);help&&(!allDevices&&devFilter.length===0&&devFilter.push(binding.devname),help.devName=binding.devname,help.imagePack=binding.contents.imagePack,res.push(help))}}return res},defaultBindingEntry=(action,control)=>({...bindingTemplate.value,action,control}),isAxis=(device,control)=>{let c=controllers.value[device].controls[control];return c&&c.control_type==`axis`},bindingConflicts=(device,control,action)=>bindings.value.find(b=>b.devname==device).contents.bindings.filter(b=>b.control==control).filter(b=>b.action!=action).map(b=>({...b,...getBindingDetails(device,control,b.action),resolved:!1})),captureBinding=(modifiersAllowed=!0)=>{let controlCaptured=!1,eventsRegister={},d=defer(),capturingBinding=!0;function _listener(data){if(!capturingBinding||controlCaptured)return;let devName=data.devName;eventsRegister[devName]||(eventsRegister[devName]={axis:{},key:[null,null]});let eventData=eventsRegister[devName];d.notify(eventsRegister);let valid=!1,key0,key1,key0Parts,key1Parts,genericModifierKeys=[`lalt`,`lcontrol`,`lshift`,`ralt`,`rcontrol`,`rshift`];switch(data.controlType){case`axis`:if(!eventData.axis[data.control])eventData.axis[data.control]={first:data.value,last:data.value,accumulated:0};else{let detectionThreshold=devName.startsWith(`mouse`)?1:.5;eventData.axis[data.control].accumulated+=Math.abs(eventData.axis[data.control].last-data.value)/detectionThreshold,eventData.axis[data.control].last=data.value}valid=eventData.axis[data.control].accumulated>=1;break;case`button`:case`pov`:case`key`:if(eventData.key=[eventData.key.at(-1),data.control],key0=eventData.key[0],key1=eventData.key[1],key0&&key1){let validSet=!1;key0Parts=key0.split(` `),key1Parts=key1.split(` `),key0Parts.length===1&&key1Parts.length===2&&key1Parts[1]===key0Parts[0]&&(eventData.key[1]=key0,key1=key0,data.control=key0,modifiersAllowed||(valid=!1,validSet=!0)),validSet||(valid=key0===key1,!modifiersAllowed&&(key0Parts.length===2||genericModifierKeys.includes(data.control))&&(valid=!1)),data.value===0&&(eventData.key=[null,null])}break;default:console.error(`Unrecognised raw input controlType: `+JSON.stringify(data))}valid&&data.devName.startsWith(`mouse`)&&data.control===`button1`&&(valid=!1),valid&&(controlCaptured=!0,capturingBinding=!1,data.direction=data.controlType===`axis`?Math.sign(eventData.axis[data.control].last-eventData.axis[data.control].first):0,d.resolve(data),_captureHelper.stopListening())}return Lua_default.ActionMap.enableBindingCapturing(!0),Lua_default.setCEFTyping(!0),_captureHelper.stopListening=()=>{Lua_default.ActionMap.enableBindingCapturing(!1),Lua_default.WinInput.setForwardRawEvents(!1),Lua_default.setCEFTyping(!1),events$3.off(`RawInputChanged`,_listener)},events$3.on(`RawInputChanged`,_listener),Lua_default.WinInput.setForwardRawEvents(!0),d.promise},removeBinding=(device,control,action,mockSave)=>{let deviceContents={...bindings.value.find(b=>b.devname==device).contents};deviceContents.bindings=[...deviceContents.bindings];let entryIndex=deviceContents.bindings.findIndex(b=>b.control==control&&b.action==action)||null;if(entryIndex)if(deviceContents.bindings.splice(entryIndex,1),mockSave){let deviceIndex=bindings.value.findIndex(b=>b.devname==device);bindings.value[deviceIndex].contents=deviceContents}else serializeCheck(deviceContents.name),Lua_default.extensions.core_input_bindings.saveBindingsToDisk(deviceContents)},addBinding=(device,bindingData,replace,mockSave)=>{let deviceContents={...bindings.value.find(b=>b.devname==device).contents};if(deviceContents.bindings=[...deviceContents.bindings],replace){let deprecatedIndex=deviceContents.bindings.findIndex(b=>b.control==bindingData.details.control&&b.action==bindingData.details.action);deviceContents[deprecatedIndex]=bindingData}else serializeCheck(deviceContents.name),Lua_default.extensions.core_input_bindings.saveBindingsToDisk(deviceContents)},isFFBBound=()=>{for(let i=0;i{let ffbCapable=()=>Object.values(controllers.value).some(controller=>controller.ffbAxes&&Object.keys(controller.ffbAxes).length>0);return asRef?computed(()=>ffbCapable()):ffbCapable},getIsControllerAvailable=(asRef=!1)=>asRef?isControllerAvailable:isControllerAvailable.value,isWheelFound=vendorId=>{for(let b of bindings.value)if(b.devname.slice(0,3)===`whe`&&b.contents.vidpid.slice(4,8)==vendorId)return!0;return!1};function isFFBEnabled(asRef=!1){let filter=()=>bindings.value.filter(b=>b.devname.slice(0,3)!==`xin`).some(b=>b.contents.bindings.some(binding=>binding.action===`steering`&&binding.isForceEnabled));return asRef?computed(()=>filter()):filter()}function isPidVidFound(desiredVid,desiredPid,asRef=!1){let filter=()=>bindings.value.some(b=>{let vid=desiredVid===void 0?desiredVid:b.contents.vidpid.slice(4,8),pid$1=desiredPid===void 0?desiredPid:b.contents.vidpid.slice(0,4);return vid==desiredVid&&pid$1==desiredPid});return asRef?computed(()=>filter()):filter()}function getBindingDetails(device,control,action){let actionDetails=getActionDetails(action);if(!actionDetails){console.warn(`Action details not found: `,action);return}let deviceBindings=bindings.value.find(b=>b.devname===device).contents.bindings,common={icon:deviceIcon(device),title:actionDetails.title,desc:actionDetails.desc},details=deviceBindings.find(b=>b.control===control&&b.action===action)||defaultBindingEntry(action,control),isBindingAxis=isAxis(device,control);return{...bindingTemplate.value,...details,...common,isAxis:isBindingAxis,action:actionDetails.action,actionName:actionDetails.actionName}}function getActionDetails(action){let actionDetails=actions.value[action];if(actionDetails)return{...actionDetails,action:actionDetails.actionName}}function addNewBinding(bindingData){let{devname,control,action}=bindingData,device=bindings.value.find(b=>b.devname==devname);if(!device){console.warn(`Device not found: `,devname);return}let deviceContents=device.contents;deviceContents.bindings.push({...bindingTemplate.value,...bindingData,control,action}),serializeCheck(deviceContents.name),Lua_default.extensions.core_input_bindings.saveBindingsToDisk(deviceContents)}function updateBinding(bindingData){let{devname,control,action}=bindingData,oldDevname=bindingData.oldDevname||devname,oldControl=bindingData.oldControl||control,device=bindings.value.find(b=>b.devname==oldDevname);if(!device){console.warn(`Device not found: `,oldDevname);return}let deviceContents=device.contents,deprecatedIndex=deviceContents.bindings.findIndex(b=>b.control==oldControl&&b.action==action);if(deprecatedIndex===-1){console.warn(`Binding not found: `,oldDevname,oldControl,action);return}if(devname===oldDevname)delete bindingData.oldDevname,delete bindingData.oldControl,deviceContents.bindings[deprecatedIndex]={...bindingData};else{deviceContents.bindings.splice(deprecatedIndex,1);let newDeviceContents=bindings.value.find(b=>b.devname===devname).contents;newDeviceContents.bindings.push({...bindingData,bindingTemplate:bindingTemplate.value}),serializeCheck(newDeviceContents.name),Lua_default.extensions.core_input_bindings.saveBindingsToDisk(newDeviceContents)}serializeCheck(deviceContents.name),Lua_default.extensions.core_input_bindings.saveBindingsToDisk(deviceContents)}function deleteBindings(bindingsData){let bindingsByDevname=bindingsData.reduce((acc,b)=>(acc[b.devname]=acc[b.devname]||[],acc[b.devname].push(b),acc),{});for(let devname in bindingsByDevname){let device=bindings.value.find(b=>b.devname==devname);if(!device){console.warn(`Device not found: `,devname);continue}let deviceContents=device.contents;bindingsByDevname[devname].forEach(b=>{let index=deviceContents.bindings.findIndex(binding=>binding.control==b.control&&binding.action==b.action);index!==-1&&deviceContents.bindings.splice(index,1)}),serializeCheck(deviceContents.name),Lua_default.extensions.core_input_bindings.saveBindingsToDisk(deviceContents)}}function deleteBinding({devname,control,action}){let device=bindings.value.find(b=>b.devname==devname);if(!device){console.warn(`Device not found: `,devname);return}let deviceContents=device.contents,index=deviceContents.bindings.findIndex(b=>b.control==control&&b.action==action);if(index===-1){console.warn(`Binding not found: Skipping...`,devname,control,action);return}deviceContents.bindings.splice(index,1),serializeCheck(deviceContents.name),Lua_default.extensions.core_input_bindings.saveBindingsToDisk(deviceContents)}function getAllBindingsForAction(action,devName,asRef=!1){let filteredBindings=()=>bindings.value.filter(b=>(!devName||b.devname==devName)&&b.contents.bindings.find(a$1=>a$1.action===action)).flatMap(b=>b.contents.bindings.filter(x=>x.action===action).map(x=>({...x,...getBindingDetails(b.devname,x.control,x.action),devname:b.devname,action,actionName:action})));return asRef?computed(()=>filteredBindings()):filteredBindings()}let _captureHelper={devName:null,stopListening:null};function _updateDeviceNotes(){Object.values(bindings.value).forEach(({contents:bindingContents})=>{for(let id in controllers.value){let controller=controllers.value[id];if(bindingContents.vidpid==controller.vidpid){controller.notes=bindingContents.notes;break}}})}let lastBindingsData=null;function _processBindingsData(data){let newBindingsData=JSON.stringify(data);if(lastBindingsData===newBindingsData)return;if(lastBindingsData=newBindingsData,Array.isArray(data.bindings)||(data.bindings=[]),data.bindings.forEach(device=>{Array.isArray(device.contents.bindings)||(device.contents.bindings=Object.values(device.contents.bindings))}),bindingTemplate.value=data.bindingTemplate,bindings.value=data.bindings,!data.actionCategories||!data.bindingTemplate||data.bindings.length===0){logger_default.debug(`Did not receive bindings data. Timing issue?`);return}bindings.value.sort((a$1,b)=>deviceSorter(a$1.devname,b.devname)),devNamesOrder.splice(0),kbmDevNames.splice(0);for(let binding of data.bindings){let devName=binding.devname;devNamesOrder.includes(devName)||devNamesOrder.push(devName),isKbm(devName)&&kbmDevNames.push(devName),binding.icon=deviceIcon(devName)}_requestRecentDevices();let acts={};for(let act in data.actions)acts[act]={actionName:act,...data.actions[act]};for(let cat in actions.value=acts,categories.value=data.actionCategories,categories.value)typeof categories.value[cat]==`object`&&(categories.value[cat].actions=[]);for(let act in actions.value){let obj={key:act,...actions.value[act]};actions.value[act].cat in categories.value||(categories.value[actions.value[act].cat]={order:99,icon:`symbol_exclamation`,title:`UNDEFINED CATEGORY: `+actions.value[act].cat,desc:``,actions:[]}),categories.value[actions.value[act].cat].actions.push(obj)}for(let x in categoriesList.value=[],Object.entries(categories.value).forEach(([catName,cat])=>categoriesList.value.push({key:catName,...cat})),categoriesList.value)for(let y in categoriesList.value[x].actions)for(let z in categoriesList.value[x].actions[y].titleTranslated=$translate.instant(categoriesList.value[x].actions[y].title),categoriesList.value[x].actions[y].descTranslated=$translate.instant(categoriesList.value[x].actions[y].desc),categoriesList.value[x].actions[y].tags)categoriesList.value[x].actions[y].tagsTranslated||(categoriesList.value[x].actions[y].tagsTranslated=[]),categoriesList.value[x].actions[y].tagsTranslated[z]=$translate.instant(categoriesList.value[x].actions[y].tags[z]);_updateDeviceNotes()}function makeViewerObj({deviceKey,device,action,uiEvent,imagePack,controller=!1,actionVariants=!1,useLastDevice=!1}){let viewerObj,multiDevice=!1;if(device&&Array.isArray(device)&&device.length===0&&(device=void 0),Array.isArray(device)&&(device.length===0?device=void 0:device.length===1?device=device[0]:multiDevice=!0),!device&&controller&&(device=lastControllers.value,device.length===0?device=void 0:device.length===1?device=device[0]:multiDevice=!0),uiEvent&&(action=ACTIONS_BY_UI_EVENT[uiEvent]),action?actionVariants?(viewerObj=_buildViewerObjVariants(findAllBindingsForAction(action,device,!1,useLastDevice)),actionVariants=!!viewerObj?.variants,actionVariants&&viewerObj.variants.sort((a$1,b)=>a$1.isInverted-b.isInverted)):viewerObj=findBindingForAction(action,device,useLastDevice):actionVariants=!1,deviceKey){let devName=viewerObj?.devName||(multiDevice?device[0]:device);viewerObj={icon:deviceIcon(devName),control:deviceKey,devName,imagePack:viewerObj?.imagePack||imagePack}}return viewerObj&&(_parseViewerObj(viewerObj,imagePack,actionVariants),viewerObj.variants&&viewerObj.variants.forEach(obj=>_parseViewerObj(obj,imagePack,actionVariants,device))),viewerObj}function _buildViewerObjVariants(viewerObjs){let len=viewerObjs?.length||0;if(len!==0)return len===1?viewerObjs[0]:{...viewerObjs[0],variants:viewerObjs}}let rgxCombo=/modifier(?\d+)[ -]+|[ -]*(?.+)/gi;function _parseViewerObj(viewerObj,imagePack=void 0,actionVariants=!1,devNames=void 0){let devName=viewerObj.devName;if(imagePack=viewerObj.imagePack||imagePack,!imagePack){let binding=bindings.value?.find(b=>b.devname===devName);binding?.contents?.imagePack&&(imagePack=binding.contents.imagePack),!imagePack&&devName&&(imagePack=CONTROL_ICON_KEYS.find(key=>devName.startsWith(key))),viewerObj.imagePack=imagePack}if(viewerObj.control.startsWith(`modifier`)){let matches$1=[...viewerObj.control.matchAll(rgxCombo)].map(m=>m.groups);if(matches$1.length>0){viewerObj.multiControls=[];for(let match of matches$1)if(match.mod){let modName=`customModifier`+match.mod,mod=actionVariants?_buildViewerObjVariants(findAllBindingsForAction(modName,devName,!1,!1)):findBindingForAction(modName,devName);mod||=actionVariants?_buildViewerObjVariants(findAllBindingsForAction(modName,devNames,!1,!1)):findBindingForAction(modName,devNames),mod&&viewerObj.multiControls.push(mod)}else viewerObj.multiControls.push({devName,control:match.key,icon:viewerObj.icon,imagePack})}}_addCustomInfo(viewerObj),viewerObj.multiControls&&viewerObj.multiControls.forEach(_addCustomInfo)}function _addCustomInfo(viewerObj){let devOverrides=getViewerOverrides(viewerObj.devName,viewerObj.imagePack);viewerObj.family=devOverrides?.family;let ownIcon=devOverrides?.icons[viewerObj.control];viewerObj.special=!!ownIcon,viewerObj.ownGroups=devOverrides?.groups,viewerObj.special?viewerObj.ownIcon=ownIcon:viewerObj.control=controlLabel(viewerObj.control)}return connect(),_getBindingsData(),{categories:computed(()=>categories.value),categoriesList:computed(()=>categoriesList.value),controllers:computed(()=>controllers.value),players:computed(()=>players.value),bindingTemplate:computed(()=>bindingTemplate.value),lastDevice:lastDeviceSimple,lastDevices:lastDeviceOrder,lastControllers,lastControllersSignature,isControllerAvailable,isControllerUsed,showIfController:isControllerUsed,focusIfController:isControllerAvailable,addNewBinding,connect,deleteBinding,deleteBindings,disconnect,deviceIcon,findBindingForAction,findAllBindingsForAction,getActionDetails,getBindingDetails,getAllBindingsForAction,defaultBindingEntry,isAxis,bindingConflicts,captureBinding,removeBinding,addBinding,isFFBBound,isFFBEnabled,isFFBCapable,isGamepadAvailable:getIsControllerAvailable,isWheelFound,isPidVidFound,makeViewerObj,updateBinding}}),useStore=()=>store||=makeStore(),controls_default=useStore,direction=`right`,focusClass=`focus-visible`,isController$1={value:!1},now=()=>new Date().getTime(),inited=!1,gamepadInited=!1,elms$3=[];function setFocus(elm,enable=!0){if(enable){if(elm.classList.add(focusClass),elm===document.activeElement)return}else if(elm.classList.remove(focusClass),elm!==document.activeElement)return;try{enable&&focusOnElement(elm)}catch{}}function setFocusExternal(elm,enable=!0,attemptScroll=!0){return elm?(!gamepadInited&&gamepadInit(),enable&&!isController$1.value?(attemptScroll&&isOccluded(elm,!0)&&scrollFix({dom:elm,rect:elm.getBoundingClientRect()},`down`),!1):(setFocus(elm,enable),!0)):!1}function ensureFocus(elm,onNextTick=!0){elm&&(!gamepadInited&&gamepadInit(),isController$1.value&&document.activeElement===elm&&!elm.classList.contains(focusClass)&&(onNextTick?nextTick(()=>elm&&setFocus(elm)):setFocus(elm)))}function gamepadInit(){gamepadInited||(gamepadInited=!0,isController$1=storeToRefs(controls_default()).focusIfController)}function init$1(){inited||(inited=!0,gamepadInit(),watch(isController$1,val=>{let active=document.activeElement;if(isNavigable$1(active)){let focused$1=active.classList.contains(focusClass);val&&!focused$1?setFocus(active,!0):!val&&focused$1&&setFocus(active,!1);return}if(val){if(priorityFocus())return;navigate(collectRects(direction),direction)&&window.requestAnimationFrame(()=>setFocus(document.activeElement,!0))}}))}function priorityFocus(){collectRects(direction);for(let{elm}of elms$3)if(isNavigable$1(elm))return setFocus(elm,!0),!0;return!1}function wantsFocus(elm,priority){inited||init$1();let dat=elms$3.find(itm=>itm.element===elm)||{elm,time:now()},isNew=!(`priority`in dat);if(typeof priority!=`number`||isNaN(priority)){if(!isNew){let idx=elms$3.findIndex(itm=>itm.elm===elm);idx>-1&&elms$3.splice(idx,1)}return}dat.priority=priority,isNew&&elms$3.push(dat),elms$3.sort((a$1,b)=>b.priority-a$1.priority||b.time-a$1.time),collectRects(direction,elm.parentNode),isNew&&isController$1.value&&!isNavigable$1(document.activeElement)&&priorityFocus()}function unwantsFocus(elm){let idx=elms$3.findIndex(itm=>itm.elm===elm);idx!==-1&&(elms$3.splice(idx,1),isController$1.value&&!isNavigable$1(document.activeElement)&&priorityFocus())}function initFocusVisible(){let raf=window.requestAnimationFrame,curFocused=null,holdFocus=!1;function notify(type,target,relatedTarget){let evt=new CustomEvent(`uinav-`+type,{bubbles:!0,cancelable:!0,detail:{target,relatedTarget}});document.dispatchEvent(evt)}function procFocus(target,relatedTarget){if(!(target&&target===curFocused)&&(relatedTarget===target&&(relatedTarget=void 0),relatedTarget&&doBlur(relatedTarget),curFocused&&=((!relatedTarget||relatedTarget!==curFocused)&&(relatedTarget=curFocused),doBlur(curFocused),null),target))try{if(target.disabled)return;if(`tabIndex`in target){if(typeof target.tabIndex==`string`&&target.tabIndex===`-1`||typeof target.tabIndex==`number`&&target.tabIndex===-1||target.tabIndex===``)return}else if(`contentEditable`in target){if(typeof target.contentEditable==`string`&&target.contentEditable!==`true`||typeof target.contentEditable==`boolean`&&!target.contentEditable)return}else return;let style=window.getComputedStyle(target);if(style.display===`none`||style.visibility===`hidden`||style.pointerEvents===`none`)return;if(isController$1.value&&target.classList.add(focusClass),curFocused=target,focusRegistry.includes(target)||focusRegistry.push(target),document.activeElement!==curFocused){holdFocus=!0;let holdFocusCounter=0;raf(function check(){!curFocused||holdFocusCounter>10||document.activeElement===curFocused?(holdFocus=!1,!curFocused||target!==curFocused?doBlur(target):notify(`focus`,curFocused,relatedTarget)):(holdFocusCounter++,curFocused.focus(),raf(check))})}else notify(`focus`,target,relatedTarget)}catch{}}function doBlur(target){if(target&&!(holdFocus&&target===curFocused))try{target.classList.remove(focusClass),target===curFocused&&(curFocused=null);let idx=focusRegistry.indexOf(target);idx!==-1&&(focusRegistry.splice(idx,1),notify(`blur`,target))}catch{}}document.addEventListener(`focusin`,evt=>procFocus(evt.target,evt.relatedTarget),!0),document.addEventListener(`focusout`,evt=>doBlur(evt.target),!0);let focusRegistry=[],originalFocus=HTMLElement.prototype.focus.__original__||HTMLElement.prototype.focus,originalBlur=HTMLElement.prototype.blur.__original__||HTMLElement.prototype.blur;HTMLElement.prototype.focus=function(...args){let target=this,prevFocused=document.activeElement;prevFocused.classList.contains(focusClass)||(focusRegistry.length>0?focusRegistry.forEach(elm=>elm!==target&&elm.blur()):document.querySelectorAll(`.`+focusClass).forEach(elm=>elm!==target&&doBlur(elm))),originalFocus.apply(target,args),procFocus(target,prevFocused)},HTMLElement.prototype.blur=function(...args){doBlur(this),originalBlur.apply(this,args)},HTMLElement.prototype.focus.__original__=originalFocus,HTMLElement.prototype.blur.__original__=originalBlur}var EVENT_CALLS=Object.entries({focus:[`uinav-focus`,`focus`,`focusin`,`click`],hide:[`mouseenter`],show:[`uinav-blur`,`blur`,`focusout`,`mouseleave`]}).reduce((res,[name,events$3])=>(events$3.forEach(event=>res[event]=name),res),{}),ID$1=`__bngFocusCapture`,elms$2={},isController;function setupController(){isController||(isController=storeToRefs(controls_default()).isControllerUsed,watch(isController,val=>{for(let data of Object.values(elms$2))val?data.show():data.hide()}))}function getClosestNavigable(elm){let target=collectRects(`down`,elm).down[0]?.dom;return target&&isNavigable$1(target)?target:null}function update$3(data,value,firstTime=!1){if(typeof value==`function`?(data.handler=()=>{let elm=value(data.parent);return elm?.$el||elm},delete data.disabled):typeof value==`boolean`&&!value?data.disabled=!0:delete data.disabled,data.disabled){if(data.hide(),!firstTime)for(let event in data.capture.remove(),EVENT_CALLS)data.parent.removeEventListener(event,data[EVENT_CALLS[event]])}else for(let event in data.parent.appendChild(data.capture),data.show(),EVENT_CALLS)data.parent.addEventListener(event,data[EVENT_CALLS[event]])}var BngFocusCapture_default={mounted(elm,{arg,value}){setupController();let id=uniqueId(ID$1),parent=elm,capture=document.createElement(`div`),data={id,shown:!0,parent,capture,handler:()=>getClosestNavigable(data.parent)};elms$2[id]=data,parent[ID$1]=id,capture.className=`bng-focus-capture`,capture.style.setProperty(`position`,`absolute`,`important`),capture.style.setProperty(`display`,`block`,`important`),capture.style.setProperty(`top`,`0%`,`important`),capture.style.setProperty(`left`,`0%`,`important`),capture.style.setProperty(`width`,`100%`,`important`),capture.style.setProperty(`height`,`100%`,`important`),capture.style.setProperty(`z-index`,arg&&/^\d+$/.test(arg)?arg:`1000`,`important`),capture.style.setProperty(`pointer-events`,`all`,`important`),capture.setAttribute(`bng-nav-item`,``),capture.setAttribute(`tabindex`,`0`),data.focus=()=>{if(data.hide(),!isController.value)return;let active=document.activeElement;if(!(active!==data.capture&&data.parent.contains(active))&&data.handler){let elm$1=data.handler(data.parent);elm$1&&nextTick(()=>setFocusExternal(elm$1))}},data.hide=()=>{data.shown&&(data.shown=!1,capture.style.setProperty(`pointer-events`,`none`,`important`))},data.show=evt=>{if(data.shown||(data.shown=!0,data.disabled||!isController.value))return;let active=document.activeElement;if(data.parent.contains(active))return;let target=evt?.relatedTarget||evt?.target||active;data.parent.contains(target)||capture.style.setProperty(`pointer-events`,`all`,`important`)},update$3(data,value,!0)},updated(elm,{arg,value}){let id=elm[ID$1];if(!id)return;let data=elms$2[id];data&&update$3(data,value)},unmounted(elm){let id=elm[ID$1];if(!id)return;delete elm[ID$1];let data=elms$2[id];if(data){for(let event in data.capture.remove(),EVENT_CALLS)data.parent.removeEventListener(event,data[EVENT_CALLS[event]]);delete elms$2[id]}}},BngFocusIf_default=(el,{value})=>value&&nextTick(()=>{let shouldFocus=typeof value==`object`?value.value:value,findNavItem=typeof value==`object`?value.findNavItem:!1;if(!el||!shouldFocus)return;let targetEl=el;if(findNavItem){let navItems=el.querySelectorAll(`[is-bng-panel], [bng-nav-item], [ng-click], [href], [bng-all-clicks], [bng-all-clicks-no-nav], [ui-sref], input, textarea, button, md-option, md-slider, md-select, md-checkbox`);navItems&&navItems.length>0&&(targetEl=navItems[0])}targetEl.focus();let blur$1=()=>{targetEl.classList.remove(`focus-visible`),targetEl.removeEventListener(`blur`,blur$1)};targetEl.addEventListener(`blur`,blur$1),targetEl.classList.add(`focus-visible`)}),elems=new WeakMap,curHorizontal=0,curVertical=0;function updateGE(horizontal=0,vertical=0){curHorizontal=horizontal,curVertical=vertical,bngApi.engineLua(`scenetree.OnlyGui:setFrustumCameraCenterOffset(Point2F(${horizontal}, ${vertical}))`)}var moveSpeed=1,smoothingUpdate;function updateGEsmooth(horizontal=0,vertical=0){if(smoothingUpdate){smoothingUpdate(horizontal,vertical);return}let dirH=1,dirV=1;function setDir(){dirH=horizontal>=curHorizontal?1:-1,dirV=vertical>=curVertical?1:-1}setDir(),smoothingUpdate=(h$1=0,v=0)=>{horizontal=h$1,vertical=v,setDir()},window.requestAnimationFrame(function(ms){let speed=moveSpeed/1e3,movH=curHorizontal,movV=curVertical,lastTime=ms,smoother=0;window.requestAnimationFrame(function step(ms$1){if(curHorizontal===horizontal&&curVertical===vertical){smoothingUpdate=null;return}smoother+=(ms$1-lastTime-smoother)*.02,lastTime=ms$1;let moveDelta=smoother*speed;movH+=moveDelta*dirH,movV+=moveDelta*dirV,(dirH>0&&movH>horizontal||dirH<0&&movH0&&movV>vertical||dirV<0&&movV{let updateDebounce=debounce(updateFrustum,50),updateWrapper=()=>updateDebounce(),resizeObserver=new ResizeObserver(updateWrapper);resizeObserver.observe(el),elems.set(el,{updateFrustum:updateDebounce,destroy:()=>{resizeObserver.disconnect(),window.removeEventListener(`resize`,updateWrapper),elems.delete(el),updateDebounce(0,0)}}),window.addEventListener(`resize`,updateWrapper);let curDirection=binding.arg||`left`,curSmooth=binding.modifiers.smooth,curState=binding.value===void 0?!0:!!binding.value;function updateFrustum(direction$1,enabled,smooth){direction$1||=curDirection,[`left`,`right`,`up`,`down`].includes(direction$1)?curDirection=direction$1:(console.error(`Frustum mover only supports left/right/up/down directions`),enabled=!1),typeof enabled!=`boolean`&&(enabled=curState),curState=enabled,typeof smooth!=`boolean`&&(smooth=curSmooth),curSmooth=smooth;let updater=smooth?updateGEsmooth:updateGE;if(!enabled){updater();return}let side=direction$1===`left`||direction$1===`right`?`width`:`height`,screenSize=window.screen[side],movePower=el.getBoundingClientRect()[side]/screenSize*power;movePower<.001?movePower=0:(direction$1===`left`||direction$1===`down`)&&(movePower=-movePower),updater(direction$1===`left`||direction$1===`right`?movePower:0,direction$1===`up`||direction$1===`down`?movePower:0)}},updated:(el,binding)=>{let itm=elems.get(el);itm&&itm.updateFrustum(binding.arg,!!binding.value,!!binding.modifiers.smooth)},unmounted:(el,binding)=>{let itm=elems.get(el);itm&&itm.destroy()}},highlighter=[``,``],rgxSanitize=str=>str.replace(/[\\[]\?:.\*\+\-]/g,`\\$1`),BngHighlighter_default=(el,binding,vnode,prevVnode)=>{if(vnode.children.length!==1||vnode.children[0].type.toString()!==`Symbol(v-txt)`){el.__highlightwarned||(el.__highlightwarned=!0,console.warn(`Only a single inner text v-node supported`,el));return}let res=vnode.children[0].children.replace(//g,`>`),highlight=binding.value;if(highlight){let rgx;if(highlight instanceof RegExp)highlight.test(res)&&(rgx=highlight);else{let searchCase=str=>binding.modifiers.case?str:str.toLowerCase(),searchSource=searchCase(res),checkString=str=>searchSource.indexOf(str)>-1,buildRegexp=str=>RegExp(`(${str})`,`gm`+(binding.modifiers.case?``:`i`));if(typeof highlight==`object`&&Array.isArray(highlight)){let found=[];for(let str of highlight)str&&(str=searchCase(String(str)),checkString(str)&&found.push(str));found.length>0&&(rgx=buildRegexp(found.map(str=>rgxSanitize(str)).join(`|`)))}else{let str=searchCase(String(highlight));checkString(str)&&(rgx=buildRegexp(rgxSanitize(str)))}}rgx&&(res=res.replace(rgx,`${highlighter[0]}$1${highlighter[1]}`))}el.innerHTML!==res&&(el.innerHTML=res)},ExecQueue=class{resolution={rejectThis:`rejectThis`,rejectOthers:`rejectOthers`,resolveThis:`resolveThis`,resolveOthers:`resolveOthers`,replaceWithReject:`replaceWithReject`,replaceWithResolve:`replaceWithResolve`,merge:`merge`};_queue=[];_processing=!1;_tick=0;_tickFunc=nextTick;_runningCount=0;_concurrency=1;constructor(tick=0,concurrency=1){this.tick=tick,this.concurrency=concurrency}get tick(){return this._tick}set tick(val){typeof val!=`number`&&(val=0),this._tick=val,this._tickFunc=val===0?func=>nextTick(func.bind(this)):func=>setTimeout(func.bind(this),this._tick)}get concurrency(){return this._concurrency}set concurrency(val){(typeof val!=`number`||val<1)&&(val=1),this._concurrency=val}shuffle(){this._shuffle=!0}async process(){if(!(this._processing||this._queue.length===0))for(this._processing=!0,this._shuffle&&=(this._queue=this._queue.sort(()=>Math.random()-.5),!1);this._runningCount0;){let item=this._queue.shift();if(!item)break;item.running=!0,this._runningCount++,this._processItem(item)}}async _processItem(item){try{let result=await item.func(...item.args);item.resolves?.forEach(resolve$1=>resolve$1?.(result))}catch(err){item.rejects.length>0?item.rejects?.forEach(reject=>reject?.(err)):console.error(err)}finally{this._runningCount--,this._tickFunc(()=>{this._processing=!1,this.process()})}}enqueue(name,func,args=[],conflicts={},resolve$1=null,reject=null){if(typeof conflicts==`object`&&Object.keys(conflicts).length>0)for(let i=this._queue.length-1;i>=0;i--){let item=this._queue[i];if(item.name in conflicts)switch(conflicts[item.name]){case this.resolution.merge:resolve$1&&item.resolves.push(resolve$1),reject&&item.rejects.push(reject);return;default:case this.resolution.rejectThis:reject?.(Error(`Function ${item.name} is rejected due to conflict`));return;case this.resolution.resolveThis:resolve$1?.();return;case this.resolution.rejectOthers:item.running||(item.rejects?.forEach(reject$1=>reject$1?.(Error(`Function ${item.name} is rejected due to conflict`))),this._queue.splice(i,1));break;case this.resolution.resolveOthers:case this.resolution.replaceWithResolve:item.running||(item.resolves?.forEach(resolve$2=>resolve$2?.()),this._queue.splice(i,1));break;case this.resolution.replaceWithReject:item.rejects?.forEach(reject$1=>reject$1?.(Error(`Function ${item.name} is replaced`))),this._queue.splice(i,1);break}}this._queue.push({name,func,args,resolves:[resolve$1],rejects:[reject]}),this._processing||(this._processing=!0,this._tickFunc(()=>{this._processing=!1,this.process()}))}promise(name,func,args=[],conflicts={}){return new Promise((resolve$1,reject)=>this.enqueue(name,func,args,conflicts,resolve$1,reject))}wrap(name,func,conflicts={}){return async(...args)=>await this.promise(name,func,args,conflicts)}},MAX_SIZE=500,OVERSIZE_LIMIT=100,CONCURRENCY_LIMIT=20,QUEUE_INTERVAL$1=0,OBS_ID=`__bngLazyImage`,cache=new Map,queue=new ExecQueue(QUEUE_INTERVAL$1,CONCURRENCY_LIMIT),observer$1=new IntersectionObserver(entries=>{for(let entry of entries)if(entry.isIntersecting){observer$1.unobserve(entry.target);let data=entry.target[OBS_ID];data.observed&&(data.observed=!1,queue.shuffle(),process(entry.target,data))}}),loadImage=url=>new Promise((resolve$1,reject)=>{let img=new Image;img.onload=async()=>{try{if(cache.sizeMAX_SIZE||img.height>MAX_SIZE)){let ratio=img.width/img.height,width$1,height$1;img.width>img.height?(width$1=MAX_SIZE,height$1=MAX_SIZE/ratio):(height$1=MAX_SIZE,width$1=MAX_SIZE*ratio);let cvs=new OffscreenCanvas(width$1,height$1);cvs.getContext(`2d`).drawImage(img,0,0,width$1,height$1);let bmp=await createImageBitmap(cvs);cache.set(img.src,{url,bmp})}}catch(err){reject(err)}resolve$1({url})},img.onerror=()=>reject(Error(`Failed to load image`)),img.src=url});function process(el,data){let{url,callback}=data,apply$1=imgData=>callback(el,imgData.url,imgData.bmp);if(cache.has(url)){apply$1(cache.get(url));return}apply$1(emptyImage),queue.enqueue(url,loadImage,[url],{url:queue.resolution.merge},data$1=>{apply$1(data$1)},err=>{logger_default.error(err),apply$1(url)})}function update$2(el,{arg,value}){let data={url:void 0,target:`src`,callback:void 0};if(typeof value==`string`)data.url=value;else if(typeof value==`object`&&!Array.isArray(value)&&value.url){if(data.url=value.url,data.target=value.target,data.callback=typeof value.callback==`function`?value.callback:void 0,!data.url||!data.target&&!data.callback)return}else return;if(el[OBS_ID]){let old=el[OBS_ID];if(old.observed&&observer$1.unobserve(el),old.url===data.url&&old.target===data.target&&old.callback===data.callback)return}el[OBS_ID]=data,arg===`observe`?(data.observed=!0,observer$1.observe(el)):process(el,data)}var BngLazyImage_default={mounted:update$2,updated:update$2,unmounted(el){el[OBS_ID]&&(el[OBS_ID].observed&&observer$1.unobserve(el),delete el[OBS_ID])}},elms$1=new Map,observer=new ResizeObserver(observed$1);function observed$1(entries){for(let entry of entries)elms$1.has(entry.target)?update$1(entry.target):observer.unobserve(entry.target)}function update$1(elm,data=void 0){if(data||=elms$1.get(elm),data)if(isVisibleFast(elm)){let screen$1={width:window.innerWidth,height:window.innerHeight,scrollX:window.scrollX,scrollY:window.scrollY},rect=elm.getBoundingClientRect(),metrics={x:rect.left+screen$1.scrollX,y:rect.top+screen$1.scrollY,width:rect.width,height:rect.height};data.set(data.id,metrics.x/screen$1.width,metrics.y/screen$1.height,metrics.width/screen$1.width,metrics.height/screen$1.height)}else data.reset(data.id)}var UINAV_PROP=`__BngOnUiNav`,_handlerToElement=handler$1=>{let element;switch(typeof handler$1){case`string`:element=document.querySelectorAll(handler$1)[0];break;case`object`:element=handler$1;break}return element instanceof HTMLElement&&element},_generateSignature=(vnode,eventNames,modifiers)=>`${UINAV_PROP}[${vnode.ctx.uid}]:`+(typeof eventNames==`string`?eventNames.split(`,`):eventNames).sort().join(`,`)+[``,...Object.keys(modifiers)].sort().join(`.`),_normalizedEvents=eventNames=>eventNames===`*`?[]:eventNames.split(`,`),_getDirData=(element,signature)=>element[UINAV_PROP]?.find(dir=>dir.signature===signature);function setup$2(data,element,vnode){if(data.modifiers.asMouse){if(data.eventNames.find(name=>!isOnOffEvent(name))){window.BNG_Logger&&window.BNG_Logger.error(`UINav directive asMouse modifier is only supported for on/off type events`,element);return}setupAsMouse(data,vnode)}typeof data.handler==`function`&&(applyUiNav(data,element),applyTracker(data,element))}function setupAsMouse(data,vnode){let handlerElement=_handlerToElement(data.handler);handlerElement&&(vnode={el:handlerElement});let eventFirer$1=vnode.ctx?.exposed?.fireEvent||eventDispatcherForElement(vnode.el),checkElementDisabled=vnode.ctx?.exposed?.getDisabledState||(()=>vnode.el.hasAttribute(`disabled`));delete data.modifiers.down,delete data.modifiers.up,data.mousedownActive=!1,data.handler=({detail})=>{if(checkElementDisabled())return;let fromControllerMarker={fromController:detail};return detail.value?(eventFirer$1(`mousedown`,fromControllerMarker),data.mousedownActive=!0):(eventFirer$1(`mouseup`,fromControllerMarker),data.mousedownActive&&(data.mousedownActive=!1,eventFirer$1(`click`,fromControllerMarker))),!!data.modifiers.bubble}}function applyTracker(data,element){let uiNavTracker=useUINavTracker();data.modifiers.focusRequired?(element.addEventListener(`focusin`,evt=>{let prevDirs=evt.relatedTarget?.[UINAV_PROP];if(prevDirs)for(let dir of prevDirs)dir.modifiers.focusRequired&&(dir.tracked.forEach(name=>uiNavTracker.removeEvent(name,dir.signature,evt.relatedTarget)),dir.tracked=[]);let cur=_getDirData(element,data.signature);cur&&(cur.tracked.lengthuiNavTracker.updateEvent(name,cur.signature,element,{active:cur.modifiers.active,nogroup:cur.modifiers.nogroup})),cur.tracked=[...cur.eventNames]))}),element.addEventListener(`focusout`,evt=>{let cur=_getDirData(element,data.signature);if(!cur||cur.tracked.length>0)return;let nextDirs=evt.relatedTarget?.[UINAV_PROP];(!nextDirs||!nextDirs.some(directive=>directive.modifiers.focusRequired))&&(cur.tracked.forEach(name=>uiNavTracker.removeEvent(name,cur.signature,element)),cur.tracked=[])})):(data.eventNames.forEach(name=>uiNavTracker.updateEvent(name,data.signature,element,{active:data.modifiers.active,nogroup:data.modifiers.nogroup})),data.tracked=[...data.eventNames])}function applyUiNav(data,element){let valueChecker;data.modifiers.down?valueChecker=checkOn:data.modifiers.up?valueChecker=0:!data.modifiers.asMouse&&!data.eventNames.find(name=>!isOnOffEvent(name))&&(valueChecker=checkOn),data.uiNavHandler=handlers_default.add(element,{name:name=>data.eventNames.includes(name),value:valueChecker,modified:data.modifiers.modified||!1,focusRequired:data.modifiers.focusRequired?element:void 0},data.handler),element.setAttribute(UI_EVENT_ATTR,``)}function mounted$1(element,{arg:eventNames,value:handler$1,modifiers},vnode){modifiers||={};let storage=element[UINAV_PROP]||(element[UINAV_PROP]=[]),signature=_generateSignature(vnode,eventNames,modifiers),data=storage.find(dir=>dir.signature===signature);data?window.BNG_Logger&&window.BNG_Logger.error(`Conflicting vBngOnUiNav directive on element`,element):(data={signature,eventNames:_normalizedEvents(eventNames),modifiers,handler:handler$1,uiNavHandler:null,mousedownActive:!1,tracked:[]},storage.push(data)),setup$2(data,element,vnode)}function updated$1(element,{arg:eventNames,value:handler$1,modifiers},vnode){modifiers||={};let data=_getDirData(element,_generateSignature(vnode,eventNames,modifiers));if(!data)return;typeof data.uiNavHandler==`function`&&handlers_default.remove(element,data.uiNavHandler);let normalizedEvents=_normalizedEvents(eventNames),oldEvents=data.tracked.filter(name=>!normalizedEvents.includes(name));if(oldEvents.length>0){let uiNavTracker=useUINavTracker();oldEvents.forEach(name=>uiNavTracker.removeEvent(name,data.signature,element)),data.tracked=data.tracked.filter(name=>normalizedEvents.includes(name))}data.eventNames=normalizedEvents,data.modifiers=modifiers,data.handler=handler$1,data.uiNavHandler=null,setup$2(data,element,vnode)}function dispose$1(element){let storage=element[UINAV_PROP];if(!storage)return;let uiNavTracker=useUINavTracker();storage.forEach(directive=>{directive.tracked.length>0&&directive.tracked.forEach(name=>uiNavTracker.removeEvent(name,directive.signature,element)),directive.uiNavHandler&&handlers_default.remove(element,directive.uiNavHandler)}),element.removeAttribute(UI_EVENT_ATTR),delete element[UINAV_PROP]}var BngOnUiNav_default={mounted:mounted$1,updated:updated$1,beforeUnmount:dispose$1},DIRECTIONS={horizontal:{[UI_EVENTS.focus_l]:-1,[UI_EVENTS.focus_r]:1},vertical:{[UI_EVENTS.focus_d]:-1,[UI_EVENTS.focus_u]:1}},HOLD_DELAY=400,REPEAT_INTERVAL=100,ELEMENT_FLAG=`__BNG_ONUINAVFOCUS`,BngOnUiNavFocus_default={mounted:(element,binding,vnode)=>{if(!binding.value)return;let opts={direction:binding.arg||`horizontal`,repeat:!!binding.modifiers.repeat,holdDelay:HOLD_DELAY,repeatInterval:REPEAT_INTERVAL,min:-1/0,max:1/0,step:1,value:null,callback:null,...typeof binding.value==`object`?binding.value:typeof binding.value==`function`?{callback:binding.value}:{}};!opts.events&&(opts.events=DIRECTIONS[opts.direction]);function process$1(evt){let detail=evt.fromController||evt.detail;if(!detail||!(detail.name in opts.events))return;let dir=opts.events[detail.name],val;if(typeof opts.value==`function`){let cur=opts.value(),res=cur+(typeof opts.step==`function`?opts.step():opts.step)*dir;dir<0&&res0&&res>opts.max&&(res=opts.max);let precision=10**(opts.step+`.`).split(/[.,]/)[1].length;res=precision>0?Math.round(res*precision)/precision:Math.round(res),cur===res?dir=0:val=res}dir&&opts.callback&&opts.callback(dir,val)}let dirUINav={arg:Object.keys(opts.events).join(`,`),modifiers:{focusRequired:!0,asMouse:!0}},dirClick={value:{clickCallback:process$1,holdCallback:opts.repeat?process$1:void 0,holdDelay:HOLD_DELAY,repeatInterval:REPEAT_INTERVAL}};BngOnUiNav_default.mounted(element,dirUINav,vnode),BngClick_default.mounted(element,dirClick,vnode),element[ELEMENT_FLAG]=!0},beforeUnmount:element=>{element[ELEMENT_FLAG]&&(BngClick_default.beforeUnmount(element),BngOnUiNav_default.beforeUnmount(element))}},DEFAULT_OPTS={intiallyOpen:!1,navEventToOpen:UI_EVENTS.ok,navEventToClose:UI_EVENTS.back},min=Math.min,max=Math.max,round$1=Math.round,floor=Math.floor,createCoords=v=>({x:v,y:v}),oppositeSideMap={left:`right`,right:`left`,bottom:`top`,top:`bottom`},oppositeAlignmentMap={start:`end`,end:`start`};function clamp$1(start,value,end){return max(start,min(value,end))}function evaluate(value,param){return typeof value==`function`?value(param):value}function getSide(placement){return placement.split(`-`)[0]}function getAlignment(placement){return placement.split(`-`)[1]}function getOppositeAxis(axis){return axis===`x`?`y`:`x`}function getAxisLength(axis){return axis===`y`?`height`:`width`}var yAxisSides=new Set([`top`,`bottom`]);function getSideAxis(placement){return yAxisSides.has(getSide(placement))?`y`:`x`}function getAlignmentAxis(placement){return getOppositeAxis(getSideAxis(placement))}function getAlignmentSides(placement,rects,rtl){rtl===void 0&&(rtl=!1);let alignment=getAlignment(placement),alignmentAxis=getAlignmentAxis(placement),length=getAxisLength(alignmentAxis),mainAlignmentSide=alignmentAxis===`x`?alignment===(rtl?`end`:`start`)?`right`:`left`:alignment===`start`?`bottom`:`top`;return rects.reference[length]>rects.floating[length]&&(mainAlignmentSide=getOppositePlacement(mainAlignmentSide)),[mainAlignmentSide,getOppositePlacement(mainAlignmentSide)]}function getExpandedPlacements(placement){let oppositePlacement=getOppositePlacement(placement);return[getOppositeAlignmentPlacement(placement),oppositePlacement,getOppositeAlignmentPlacement(oppositePlacement)]}function getOppositeAlignmentPlacement(placement){return placement.replace(/start|end/g,alignment=>oppositeAlignmentMap[alignment])}var lrPlacement=[`left`,`right`],rlPlacement=[`right`,`left`],tbPlacement=[`top`,`bottom`],btPlacement=[`bottom`,`top`];function getSideList(side,isStart,rtl){switch(side){case`top`:case`bottom`:return rtl?isStart?rlPlacement:lrPlacement:isStart?lrPlacement:rlPlacement;case`left`:case`right`:return isStart?tbPlacement:btPlacement;default:return[]}}function getOppositeAxisPlacements(placement,flipAlignment,direction$1,rtl){let alignment=getAlignment(placement),list=getSideList(getSide(placement),direction$1===`start`,rtl);return alignment&&(list=list.map(side=>side+`-`+alignment),flipAlignment&&(list=list.concat(list.map(getOppositeAlignmentPlacement)))),list}function getOppositePlacement(placement){return placement.replace(/left|right|bottom|top/g,side=>oppositeSideMap[side])}function expandPaddingObject(padding){return{top:0,right:0,bottom:0,left:0,...padding}}function getPaddingObject(padding){return typeof padding==`number`?{top:padding,right:padding,bottom:padding,left:padding}:expandPaddingObject(padding)}function rectToClientRect(rect){let{x,y,width:width$1,height:height$1}=rect;return{width:width$1,height:height$1,top:y,left:x,right:x+width$1,bottom:y+height$1,x,y}}function computeCoordsFromPlacement(_ref,placement,rtl){let{reference,floating}=_ref,sideAxis=getSideAxis(placement),alignmentAxis=getAlignmentAxis(placement),alignLength=getAxisLength(alignmentAxis),side=getSide(placement),isVertical=sideAxis===`y`,commonX=reference.x+reference.width/2-floating.width/2,commonY=reference.y+reference.height/2-floating.height/2,commonAlign=reference[alignLength]/2-floating[alignLength]/2,coords;switch(side){case`top`:coords={x:commonX,y:reference.y-floating.height};break;case`bottom`:coords={x:commonX,y:reference.y+reference.height};break;case`right`:coords={x:reference.x+reference.width,y:commonY};break;case`left`:coords={x:reference.x-floating.width,y:commonY};break;default:coords={x:reference.x,y:reference.y}}switch(getAlignment(placement)){case`start`:coords[alignmentAxis]-=commonAlign*(rtl&&isVertical?-1:1);break;case`end`:coords[alignmentAxis]+=commonAlign*(rtl&&isVertical?-1:1);break}return coords}var computePosition$1=async(reference,floating,config)=>{let{placement=`bottom`,strategy=`absolute`,middleware=[],platform:platform$1}=config,validMiddleware=middleware.filter(Boolean),rtl=await(platform$1.isRTL==null?void 0:platform$1.isRTL(floating)),rects=await platform$1.getElementRects({reference,floating,strategy}),{x,y}=computeCoordsFromPlacement(rects,placement,rtl),statefulPlacement=placement,middlewareData={},resetCount=0;for(let i=0;i({name:`arrow`,options,async fn(state){let{x,y,placement,rects,platform:platform$1,elements,middlewareData}=state,{element,padding=0}=evaluate(options,state)||{};if(element==null)return{};let paddingObject=getPaddingObject(padding),coords={x,y},axis=getAlignmentAxis(placement),length=getAxisLength(axis),arrowDimensions=await platform$1.getDimensions(element),isYAxis=axis===`y`,minProp=isYAxis?`top`:`left`,maxProp=isYAxis?`bottom`:`right`,clientProp=isYAxis?`clientHeight`:`clientWidth`,endDiff=rects.reference[length]+rects.reference[axis]-coords[axis]-rects.floating[length],startDiff=coords[axis]-rects.reference[axis],arrowOffsetParent=await(platform$1.getOffsetParent==null?void 0:platform$1.getOffsetParent(element)),clientSize=arrowOffsetParent?arrowOffsetParent[clientProp]:0;(!clientSize||!await(platform$1.isElement==null?void 0:platform$1.isElement(arrowOffsetParent)))&&(clientSize=elements.floating[clientProp]||rects.floating[length]);let centerToReference=endDiff/2-startDiff/2,largestPossiblePadding=clientSize/2-arrowDimensions[length]/2-1,minPadding=min(paddingObject[minProp],largestPossiblePadding),maxPadding=min(paddingObject[maxProp],largestPossiblePadding),min$1=minPadding,max$1=clientSize-arrowDimensions[length]-maxPadding,center=clientSize/2-arrowDimensions[length]/2+centerToReference,offset$2=clamp$1(min$1,center,max$1),shouldAddOffset=!middlewareData.arrow&&getAlignment(placement)!=null&¢er!==offset$2&&rects.reference[length]/2-(centerside$1<=0)){var _middlewareData$flip2,_overflowsData$filter;let nextIndex=(middlewareData.flip?.index||0)+1,nextPlacement=placements$1[nextIndex];if(nextPlacement&&(!(checkCrossAxis===`alignment`&&initialSideAxis!==getSideAxis(nextPlacement))||overflowsData.every(d=>getSideAxis(d.placement)===initialSideAxis?d.overflows[0]>0:!0)))return{data:{index:nextIndex,overflows:overflowsData},reset:{placement:nextPlacement}};let resetPlacement=overflowsData.filter(d=>d.overflows[0]<=0).sort((a$1,b)=>a$1.overflows[1]-b.overflows[1])[0]?.placement;if(!resetPlacement)switch(fallbackStrategy){case`bestFit`:{var _overflowsData$filter2;let placement$1=overflowsData.filter(d=>{if(hasFallbackAxisSideDirection){let currentSideAxis=getSideAxis(d.placement);return currentSideAxis===initialSideAxis||currentSideAxis===`y`}return!0}).map(d=>[d.placement,d.overflows.filter(overflow$1=>overflow$1>0).reduce((acc,overflow$1)=>acc+overflow$1,0)]).sort((a$1,b)=>a$1[1]-b[1])[0]?.[0];placement$1&&(resetPlacement=placement$1);break}case`initialPlacement`:resetPlacement=initialPlacement;break}if(placement!==resetPlacement)return{reset:{placement:resetPlacement}}}return{}}}},originSides=new Set([`left`,`top`]);async function convertValueToCoords(state,options){let{placement,platform:platform$1,elements}=state,rtl=await(platform$1.isRTL==null?void 0:platform$1.isRTL(elements.floating)),side=getSide(placement),alignment=getAlignment(placement),isVertical=getSideAxis(placement)===`y`,mainAxisMulti=originSides.has(side)?-1:1,crossAxisMulti=rtl&&isVertical?-1:1,rawValue=evaluate(options,state),{mainAxis,crossAxis,alignmentAxis}=typeof rawValue==`number`?{mainAxis:rawValue,crossAxis:0,alignmentAxis:null}:{mainAxis:rawValue.mainAxis||0,crossAxis:rawValue.crossAxis||0,alignmentAxis:rawValue.alignmentAxis};return alignment&&typeof alignmentAxis==`number`&&(crossAxis=alignment===`end`?alignmentAxis*-1:alignmentAxis),isVertical?{x:crossAxis*crossAxisMulti,y:mainAxis*mainAxisMulti}:{x:mainAxis*mainAxisMulti,y:crossAxis*crossAxisMulti}}var offset$1=function(options){return options===void 0&&(options=0),{name:`offset`,options,async fn(state){var _middlewareData$offse,_middlewareData$arrow;let{x,y,placement,middlewareData}=state,diffCoords=await convertValueToCoords(state,options);return placement===middlewareData.offset?.placement&&(_middlewareData$arrow=middlewareData.arrow)!=null&&_middlewareData$arrow.alignmentOffset?{}:{x:x+diffCoords.x,y:y+diffCoords.y,data:{...diffCoords,placement}}}}},shift$1=function(options){return options===void 0&&(options={}),{name:`shift`,options,async fn(state){let{x,y,placement}=state,{mainAxis:checkMainAxis=!0,crossAxis:checkCrossAxis=!1,limiter={fn:_ref=>{let{x:x$1,y:y$1}=_ref;return{x:x$1,y:y$1}}},...detectOverflowOptions}=evaluate(options,state),coords={x,y},overflow=await detectOverflow$1(state,detectOverflowOptions),crossAxis=getSideAxis(getSide(placement)),mainAxis=getOppositeAxis(crossAxis),mainAxisCoord=coords[mainAxis],crossAxisCoord=coords[crossAxis];if(checkMainAxis){let minSide=mainAxis===`y`?`top`:`left`,maxSide=mainAxis===`y`?`bottom`:`right`,min$1=mainAxisCoord+overflow[minSide],max$1=mainAxisCoord-overflow[maxSide];mainAxisCoord=clamp$1(min$1,mainAxisCoord,max$1)}if(checkCrossAxis){let minSide=crossAxis===`y`?`top`:`left`,maxSide=crossAxis===`y`?`bottom`:`right`,min$1=crossAxisCoord+overflow[minSide],max$1=crossAxisCoord-overflow[maxSide];crossAxisCoord=clamp$1(min$1,crossAxisCoord,max$1)}let limitedCoords=limiter.fn({...state,[mainAxis]:mainAxisCoord,[crossAxis]:crossAxisCoord});return{...limitedCoords,data:{x:limitedCoords.x-x,y:limitedCoords.y-y,enabled:{[mainAxis]:checkMainAxis,[crossAxis]:checkCrossAxis}}}}}};function hasWindow(){return typeof window<`u`}function getNodeName(node){return isNode(node)?(node.nodeName||``).toLowerCase():`#document`}function getWindow(node){var _node$ownerDocument;return(node==null||(_node$ownerDocument=node.ownerDocument)==null?void 0:_node$ownerDocument.defaultView)||window}function getDocumentElement(node){var _ref;return((isNode(node)?node.ownerDocument:node.document)||window.document)?.documentElement}function isNode(value){return hasWindow()?value instanceof Node||value instanceof getWindow(value).Node:!1}function isElement(value){return hasWindow()?value instanceof Element||value instanceof getWindow(value).Element:!1}function isHTMLElement(value){return hasWindow()?value instanceof HTMLElement||value instanceof getWindow(value).HTMLElement:!1}function isShadowRoot(value){return!hasWindow()||typeof ShadowRoot>`u`?!1:value instanceof ShadowRoot||value instanceof getWindow(value).ShadowRoot}var invalidOverflowDisplayValues=new Set([`inline`,`contents`]);function isOverflowElement(element){let{overflow,overflowX,overflowY,display}=getComputedStyle$1(element);return/auto|scroll|overlay|hidden|clip/.test(overflow+overflowY+overflowX)&&!invalidOverflowDisplayValues.has(display)}var tableElements=new Set([`table`,`td`,`th`]);function isTableElement(element){return tableElements.has(getNodeName(element))}var topLayerSelectors=[`:popover-open`,`:modal`];function isTopLayer(element){return topLayerSelectors.some(selector=>{try{return element.matches(selector)}catch{return!1}})}var transformProperties=[`transform`,`translate`,`scale`,`rotate`,`perspective`],willChangeValues=[`transform`,`translate`,`scale`,`rotate`,`perspective`,`filter`],containValues=[`paint`,`layout`,`strict`,`content`];function isContainingBlock(elementOrCss){let webkit=isWebKit(),css=isElement(elementOrCss)?getComputedStyle$1(elementOrCss):elementOrCss;return transformProperties.some(value=>css[value]?css[value]!==`none`:!1)||(css.containerType?css.containerType!==`normal`:!1)||!webkit&&(css.backdropFilter?css.backdropFilter!==`none`:!1)||!webkit&&(css.filter?css.filter!==`none`:!1)||willChangeValues.some(value=>(css.willChange||``).includes(value))||containValues.some(value=>(css.contain||``).includes(value))}function getContainingBlock(element){let currentNode=getParentNode(element);for(;isHTMLElement(currentNode)&&!isLastTraversableNode(currentNode);){if(isContainingBlock(currentNode))return currentNode;if(isTopLayer(currentNode))return null;currentNode=getParentNode(currentNode)}return null}function isWebKit(){return typeof CSS>`u`||!CSS.supports?!1:CSS.supports(`-webkit-backdrop-filter`,`none`)}var lastTraversableNodeNames=new Set([`html`,`body`,`#document`]);function isLastTraversableNode(node){return lastTraversableNodeNames.has(getNodeName(node))}function getComputedStyle$1(element){return getWindow(element).getComputedStyle(element)}function getNodeScroll(element){return isElement(element)?{scrollLeft:element.scrollLeft,scrollTop:element.scrollTop}:{scrollLeft:element.scrollX,scrollTop:element.scrollY}}function getParentNode(node){if(getNodeName(node)===`html`)return node;let result=node.assignedSlot||node.parentNode||isShadowRoot(node)&&node.host||getDocumentElement(node);return isShadowRoot(result)?result.host:result}function getNearestOverflowAncestor(node){let parentNode=getParentNode(node);return isLastTraversableNode(parentNode)?node.ownerDocument?node.ownerDocument.body:node.body:isHTMLElement(parentNode)&&isOverflowElement(parentNode)?parentNode:getNearestOverflowAncestor(parentNode)}function getOverflowAncestors(node,list,traverseIframes){var _node$ownerDocument2;list===void 0&&(list=[]),traverseIframes===void 0&&(traverseIframes=!0);let scrollableAncestor=getNearestOverflowAncestor(node),isBody=scrollableAncestor===node.ownerDocument?.body,win=getWindow(scrollableAncestor);if(isBody){let frameElement=getFrameElement(win);return list.concat(win,win.visualViewport||[],isOverflowElement(scrollableAncestor)?scrollableAncestor:[],frameElement&&traverseIframes?getOverflowAncestors(frameElement):[])}return list.concat(scrollableAncestor,getOverflowAncestors(scrollableAncestor,[],traverseIframes))}function getFrameElement(win){return win.parent&&Object.getPrototypeOf(win.parent)?win.frameElement:null}function getCssDimensions(element){let css=getComputedStyle$1(element),width$1=parseFloat(css.width)||0,height$1=parseFloat(css.height)||0,hasOffset=isHTMLElement(element),offsetWidth=hasOffset?element.offsetWidth:width$1,offsetHeight=hasOffset?element.offsetHeight:height$1,shouldFallback=round$1(width$1)!==offsetWidth||round$1(height$1)!==offsetHeight;return shouldFallback&&(width$1=offsetWidth,height$1=offsetHeight),{width:width$1,height:height$1,$:shouldFallback}}function unwrapElement$1(element){return isElement(element)?element:element.contextElement}function getScale(element){let domElement=unwrapElement$1(element);if(!isHTMLElement(domElement))return createCoords(1);let rect=domElement.getBoundingClientRect(),{width:width$1,height:height$1,$}=getCssDimensions(domElement),x=($?round$1(rect.width):rect.width)/width$1,y=($?round$1(rect.height):rect.height)/height$1;return(!x||!Number.isFinite(x))&&(x=1),(!y||!Number.isFinite(y))&&(y=1),{x,y}}var noOffsets=createCoords(0);function getVisualOffsets(element){let win=getWindow(element);return!isWebKit()||!win.visualViewport?noOffsets:{x:win.visualViewport.offsetLeft,y:win.visualViewport.offsetTop}}function shouldAddVisualOffsets(element,isFixed,floatingOffsetParent){return isFixed===void 0&&(isFixed=!1),!floatingOffsetParent||isFixed&&floatingOffsetParent!==getWindow(element)?!1:isFixed}function getBoundingClientRect(element,includeScale,isFixedStrategy,offsetParent){includeScale===void 0&&(includeScale=!1),isFixedStrategy===void 0&&(isFixedStrategy=!1);let clientRect=element.getBoundingClientRect(),domElement=unwrapElement$1(element),scale=createCoords(1);includeScale&&(offsetParent?isElement(offsetParent)&&(scale=getScale(offsetParent)):scale=getScale(element));let visualOffsets=shouldAddVisualOffsets(domElement,isFixedStrategy,offsetParent)?getVisualOffsets(domElement):createCoords(0),x=(clientRect.left+visualOffsets.x)/scale.x,y=(clientRect.top+visualOffsets.y)/scale.y,width$1=clientRect.width/scale.x,height$1=clientRect.height/scale.y;if(domElement){let win=getWindow(domElement),offsetWin=offsetParent&&isElement(offsetParent)?getWindow(offsetParent):offsetParent,currentWin=win,currentIFrame=getFrameElement(currentWin);for(;currentIFrame&&offsetParent&&offsetWin!==currentWin;){let iframeScale=getScale(currentIFrame),iframeRect=currentIFrame.getBoundingClientRect(),css=getComputedStyle$1(currentIFrame),left=iframeRect.left+(currentIFrame.clientLeft+parseFloat(css.paddingLeft))*iframeScale.x,top=iframeRect.top+(currentIFrame.clientTop+parseFloat(css.paddingTop))*iframeScale.y;x*=iframeScale.x,y*=iframeScale.y,width$1*=iframeScale.x,height$1*=iframeScale.y,x+=left,y+=top,currentWin=getWindow(currentIFrame),currentIFrame=getFrameElement(currentWin)}}return rectToClientRect({width:width$1,height:height$1,x,y})}function getWindowScrollBarX(element,rect){let leftScroll=getNodeScroll(element).scrollLeft;return rect?rect.left+leftScroll:getBoundingClientRect(getDocumentElement(element)).left+leftScroll}function getHTMLOffset(documentElement,scroll$1){let htmlRect=documentElement.getBoundingClientRect();return{x:htmlRect.left+scroll$1.scrollLeft-getWindowScrollBarX(documentElement,htmlRect),y:htmlRect.top+scroll$1.scrollTop}}function convertOffsetParentRelativeRectToViewportRelativeRect(_ref){let{elements,rect,offsetParent,strategy}=_ref,isFixed=strategy===`fixed`,documentElement=getDocumentElement(offsetParent),topLayer=elements?isTopLayer(elements.floating):!1;if(offsetParent===documentElement||topLayer&&isFixed)return rect;let scroll$1={scrollLeft:0,scrollTop:0},scale=createCoords(1),offsets=createCoords(0),isOffsetParentAnElement=isHTMLElement(offsetParent);if((isOffsetParentAnElement||!isOffsetParentAnElement&&!isFixed)&&((getNodeName(offsetParent)!==`body`||isOverflowElement(documentElement))&&(scroll$1=getNodeScroll(offsetParent)),isHTMLElement(offsetParent))){let offsetRect=getBoundingClientRect(offsetParent);scale=getScale(offsetParent),offsets.x=offsetRect.x+offsetParent.clientLeft,offsets.y=offsetRect.y+offsetParent.clientTop}let htmlOffset=documentElement&&!isOffsetParentAnElement&&!isFixed?getHTMLOffset(documentElement,scroll$1):createCoords(0);return{width:rect.width*scale.x,height:rect.height*scale.y,x:rect.x*scale.x-scroll$1.scrollLeft*scale.x+offsets.x+htmlOffset.x,y:rect.y*scale.y-scroll$1.scrollTop*scale.y+offsets.y+htmlOffset.y}}function getClientRects(element){return Array.from(element.getClientRects())}function getDocumentRect(element){let html=getDocumentElement(element),scroll$1=getNodeScroll(element),body=element.ownerDocument.body,width$1=max(html.scrollWidth,html.clientWidth,body.scrollWidth,body.clientWidth),height$1=max(html.scrollHeight,html.clientHeight,body.scrollHeight,body.clientHeight),x=-scroll$1.scrollLeft+getWindowScrollBarX(element),y=-scroll$1.scrollTop;return getComputedStyle$1(body).direction===`rtl`&&(x+=max(html.clientWidth,body.clientWidth)-width$1),{width:width$1,height:height$1,x,y}}var SCROLLBAR_MAX=25;function getViewportRect(element,strategy){let win=getWindow(element),html=getDocumentElement(element),visualViewport=win.visualViewport,width$1=html.clientWidth,height$1=html.clientHeight,x=0,y=0;if(visualViewport){width$1=visualViewport.width,height$1=visualViewport.height;let visualViewportBased=isWebKit();(!visualViewportBased||visualViewportBased&&strategy===`fixed`)&&(x=visualViewport.offsetLeft,y=visualViewport.offsetTop)}let windowScrollbarX=getWindowScrollBarX(html);if(windowScrollbarX<=0){let doc$1=html.ownerDocument,body=doc$1.body,bodyStyles=getComputedStyle(body),bodyMarginInline=doc$1.compatMode===`CSS1Compat`&&parseFloat(bodyStyles.marginLeft)+parseFloat(bodyStyles.marginRight)||0,clippingStableScrollbarWidth=Math.abs(html.clientWidth-body.clientWidth-bodyMarginInline);clippingStableScrollbarWidth<=SCROLLBAR_MAX&&(width$1-=clippingStableScrollbarWidth)}else windowScrollbarX<=SCROLLBAR_MAX&&(width$1+=windowScrollbarX);return{width:width$1,height:height$1,x,y}}var absoluteOrFixed=new Set([`absolute`,`fixed`]);function getInnerBoundingClientRect(element,strategy){let clientRect=getBoundingClientRect(element,!0,strategy===`fixed`),top=clientRect.top+element.clientTop,left=clientRect.left+element.clientLeft,scale=isHTMLElement(element)?getScale(element):createCoords(1);return{width:element.clientWidth*scale.x,height:element.clientHeight*scale.y,x:left*scale.x,y:top*scale.y}}function getClientRectFromClippingAncestor(element,clippingAncestor,strategy){let rect;if(clippingAncestor===`viewport`)rect=getViewportRect(element,strategy);else if(clippingAncestor===`document`)rect=getDocumentRect(getDocumentElement(element));else if(isElement(clippingAncestor))rect=getInnerBoundingClientRect(clippingAncestor,strategy);else{let visualOffsets=getVisualOffsets(element);rect={x:clippingAncestor.x-visualOffsets.x,y:clippingAncestor.y-visualOffsets.y,width:clippingAncestor.width,height:clippingAncestor.height}}return rectToClientRect(rect)}function hasFixedPositionAncestor(element,stopNode){let parentNode=getParentNode(element);return parentNode===stopNode||!isElement(parentNode)||isLastTraversableNode(parentNode)?!1:getComputedStyle$1(parentNode).position===`fixed`||hasFixedPositionAncestor(parentNode,stopNode)}function getClippingElementAncestors(element,cache$1){let cachedResult=cache$1.get(element);if(cachedResult)return cachedResult;let result=getOverflowAncestors(element,[],!1).filter(el=>isElement(el)&&getNodeName(el)!==`body`),currentContainingBlockComputedStyle=null,elementIsFixed=getComputedStyle$1(element).position===`fixed`,currentNode=elementIsFixed?getParentNode(element):element;for(;isElement(currentNode)&&!isLastTraversableNode(currentNode);){let computedStyle=getComputedStyle$1(currentNode),currentNodeIsContaining=isContainingBlock(currentNode);!currentNodeIsContaining&&computedStyle.position===`fixed`&&(currentContainingBlockComputedStyle=null),(elementIsFixed?!currentNodeIsContaining&&!currentContainingBlockComputedStyle:!currentNodeIsContaining&&computedStyle.position===`static`&¤tContainingBlockComputedStyle&&absoluteOrFixed.has(currentContainingBlockComputedStyle.position)||isOverflowElement(currentNode)&&!currentNodeIsContaining&&hasFixedPositionAncestor(element,currentNode))?result=result.filter(ancestor=>ancestor!==currentNode):currentContainingBlockComputedStyle=computedStyle,currentNode=getParentNode(currentNode)}return cache$1.set(element,result),result}function getClippingRect(_ref){let{element,boundary,rootBoundary,strategy}=_ref,clippingAncestors=[...boundary===`clippingAncestors`?isTopLayer(element)?[]:getClippingElementAncestors(element,this._c):[].concat(boundary),rootBoundary],firstClippingAncestor=clippingAncestors[0],clippingRect=clippingAncestors.reduce((accRect,clippingAncestor)=>{let rect=getClientRectFromClippingAncestor(element,clippingAncestor,strategy);return accRect.top=max(rect.top,accRect.top),accRect.right=min(rect.right,accRect.right),accRect.bottom=min(rect.bottom,accRect.bottom),accRect.left=max(rect.left,accRect.left),accRect},getClientRectFromClippingAncestor(element,firstClippingAncestor,strategy));return{width:clippingRect.right-clippingRect.left,height:clippingRect.bottom-clippingRect.top,x:clippingRect.left,y:clippingRect.top}}function getDimensions(element){let{width:width$1,height:height$1}=getCssDimensions(element);return{width:width$1,height:height$1}}function getRectRelativeToOffsetParent(element,offsetParent,strategy){let isOffsetParentAnElement=isHTMLElement(offsetParent),documentElement=getDocumentElement(offsetParent),isFixed=strategy===`fixed`,rect=getBoundingClientRect(element,!0,isFixed,offsetParent),scroll$1={scrollLeft:0,scrollTop:0},offsets=createCoords(0);function setLeftRTLScrollbarOffset(){offsets.x=getWindowScrollBarX(documentElement)}if(isOffsetParentAnElement||!isOffsetParentAnElement&&!isFixed)if((getNodeName(offsetParent)!==`body`||isOverflowElement(documentElement))&&(scroll$1=getNodeScroll(offsetParent)),isOffsetParentAnElement){let offsetRect=getBoundingClientRect(offsetParent,!0,isFixed,offsetParent);offsets.x=offsetRect.x+offsetParent.clientLeft,offsets.y=offsetRect.y+offsetParent.clientTop}else documentElement&&setLeftRTLScrollbarOffset();isFixed&&!isOffsetParentAnElement&&documentElement&&setLeftRTLScrollbarOffset();let htmlOffset=documentElement&&!isOffsetParentAnElement&&!isFixed?getHTMLOffset(documentElement,scroll$1):createCoords(0);return{x:rect.left+scroll$1.scrollLeft-offsets.x-htmlOffset.x,y:rect.top+scroll$1.scrollTop-offsets.y-htmlOffset.y,width:rect.width,height:rect.height}}function isStaticPositioned(element){return getComputedStyle$1(element).position===`static`}function getTrueOffsetParent(element,polyfill){if(!isHTMLElement(element)||getComputedStyle$1(element).position===`fixed`)return null;if(polyfill)return polyfill(element);let rawOffsetParent=element.offsetParent;return getDocumentElement(element)===rawOffsetParent&&(rawOffsetParent=rawOffsetParent.ownerDocument.body),rawOffsetParent}function getOffsetParent(element,polyfill){let win=getWindow(element);if(isTopLayer(element))return win;if(!isHTMLElement(element)){let svgOffsetParent=getParentNode(element);for(;svgOffsetParent&&!isLastTraversableNode(svgOffsetParent);){if(isElement(svgOffsetParent)&&!isStaticPositioned(svgOffsetParent))return svgOffsetParent;svgOffsetParent=getParentNode(svgOffsetParent)}return win}let offsetParent=getTrueOffsetParent(element,polyfill);for(;offsetParent&&isTableElement(offsetParent)&&isStaticPositioned(offsetParent);)offsetParent=getTrueOffsetParent(offsetParent,polyfill);return offsetParent&&isLastTraversableNode(offsetParent)&&isStaticPositioned(offsetParent)&&!isContainingBlock(offsetParent)?win:offsetParent||getContainingBlock(element)||win}var getElementRects=async function(data){let getOffsetParentFn=this.getOffsetParent||getOffsetParent,getDimensionsFn=this.getDimensions,floatingDimensions=await getDimensionsFn(data.floating);return{reference:getRectRelativeToOffsetParent(data.reference,await getOffsetParentFn(data.floating),data.strategy),floating:{x:0,y:0,width:floatingDimensions.width,height:floatingDimensions.height}}};function isRTL(element){return getComputedStyle$1(element).direction===`rtl`}var platform={convertOffsetParentRelativeRectToViewportRelativeRect,getDocumentElement,getClippingRect,getOffsetParent,getElementRects,getClientRects,getDimensions,getScale,isElement,isRTL};function rectsAreEqual(a$1,b){return a$1.x===b.x&&a$1.y===b.y&&a$1.width===b.width&&a$1.height===b.height}function observeMove(element,onMove){let io=null,timeoutId,root=getDocumentElement(element);function cleanup(){var _io;clearTimeout(timeoutId),(_io=io)==null||_io.disconnect(),io=null}function refresh$1(skip,threshold){skip===void 0&&(skip=!1),threshold===void 0&&(threshold=1),cleanup();let elementRectForRootMargin=element.getBoundingClientRect(),{left,top,width:width$1,height:height$1}=elementRectForRootMargin;if(skip||onMove(),!width$1||!height$1)return;let insetTop=floor(top),insetRight=floor(root.clientWidth-(left+width$1)),insetBottom=floor(root.clientHeight-(top+height$1)),insetLeft=floor(left),options={rootMargin:-insetTop+`px `+-insetRight+`px `+-insetBottom+`px `+-insetLeft+`px`,threshold:max(0,min(1,threshold))||1},isFirstUpdate=!0;function handleObserve(entries){let ratio=entries[0].intersectionRatio;if(ratio!==threshold){if(!isFirstUpdate)return refresh$1();ratio?refresh$1(!1,ratio):timeoutId=setTimeout(()=>{refresh$1(!1,1e-7)},1e3)}ratio===1&&!rectsAreEqual(elementRectForRootMargin,element.getBoundingClientRect())&&refresh$1(),isFirstUpdate=!1}try{io=new IntersectionObserver(handleObserve,{...options,root:root.ownerDocument})}catch{io=new IntersectionObserver(handleObserve,options)}io.observe(element)}return refresh$1(!0),cleanup}function autoUpdate(reference,floating,update$6,options){options===void 0&&(options={});let{ancestorScroll=!0,ancestorResize=!0,elementResize=typeof ResizeObserver==`function`,layoutShift=typeof IntersectionObserver==`function`,animationFrame=!1}=options,referenceEl=unwrapElement$1(reference),ancestors=ancestorScroll||ancestorResize?[...referenceEl?getOverflowAncestors(referenceEl):[],...getOverflowAncestors(floating)]:[];ancestors.forEach(ancestor=>{ancestorScroll&&ancestor.addEventListener(`scroll`,update$6,{passive:!0}),ancestorResize&&ancestor.addEventListener(`resize`,update$6)});let cleanupIo=referenceEl&&layoutShift?observeMove(referenceEl,update$6):null,reobserveFrame=-1,resizeObserver=null;elementResize&&(resizeObserver=new ResizeObserver(_ref=>{let[firstEntry]=_ref;firstEntry&&firstEntry.target===referenceEl&&resizeObserver&&(resizeObserver.unobserve(floating),cancelAnimationFrame(reobserveFrame),reobserveFrame=requestAnimationFrame(()=>{var _resizeObserver;(_resizeObserver=resizeObserver)==null||_resizeObserver.observe(floating)})),update$6()}),referenceEl&&!animationFrame&&resizeObserver.observe(referenceEl),resizeObserver.observe(floating));let frameId,prevRefRect=animationFrame?getBoundingClientRect(reference):null;animationFrame&&frameLoop();function frameLoop(){let nextRefRect=getBoundingClientRect(reference);prevRefRect&&!rectsAreEqual(prevRefRect,nextRefRect)&&update$6(),prevRefRect=nextRefRect,frameId=requestAnimationFrame(frameLoop)}return update$6(),()=>{var _resizeObserver2;ancestors.forEach(ancestor=>{ancestorScroll&&ancestor.removeEventListener(`scroll`,update$6),ancestorResize&&ancestor.removeEventListener(`resize`,update$6)}),cleanupIo?.(),(_resizeObserver2=resizeObserver)==null||_resizeObserver2.disconnect(),resizeObserver=null,animationFrame&&cancelAnimationFrame(frameId)}}var offset=offset$1,shift=shift$1,flip=flip$1,arrow$1=arrow$2,computePosition=(reference,floating,options)=>{let cache$1=new Map,mergedOptions={platform,...options},platformWithCache={...mergedOptions.platform,_c:cache$1};return computePosition$1(reference,floating,{...mergedOptions,platform:platformWithCache})};function isComponentPublicInstance(target){return typeof target==`object`&&!!target&&`$el`in target}function unwrapElement(target){if(isComponentPublicInstance(target)){let element=target.$el;return isNode(element)&&getNodeName(element)===`#comment`?null:element}return target}function toValue(source){return typeof source==`function`?source():unref(source)}function arrow(options){return{name:`arrow`,options,fn(args){let element=unwrapElement(toValue(options.element));return element==null?{}:arrow$1({element,padding:options.padding}).fn(args)}}}function getDPR(element){return typeof window>`u`?1:(element.ownerDocument.defaultView||window).devicePixelRatio||1}function roundByDPR(element,value){let dpr=getDPR(element);return Math.round(value*dpr)/dpr}function useFloating(reference,floating,options){options===void 0&&(options={});let whileElementsMountedOption=options.whileElementsMounted,openOption=computed(()=>{var _toValue;return toValue(options.open)??!0}),middlewareOption=computed(()=>toValue(options.middleware)),placementOption=computed(()=>{var _toValue2;return toValue(options.placement)??`bottom`}),strategyOption=computed(()=>{var _toValue3;return toValue(options.strategy)??`absolute`}),transformOption=computed(()=>{var _toValue4;return toValue(options.transform)??!0}),referenceElement=computed(()=>unwrapElement(reference.value)),floatingElement=computed(()=>unwrapElement(floating.value)),x=ref(0),y=ref(0),strategy=ref(strategyOption.value),placement=ref(placementOption.value),middlewareData=shallowRef({}),isPositioned=ref(!1),floatingStyles=computed(()=>{let initialStyles={position:strategy.value,left:`0`,top:`0`};if(!floatingElement.value)return initialStyles;let xVal=roundByDPR(floatingElement.value,x.value),yVal=roundByDPR(floatingElement.value,y.value);return transformOption.value?{...initialStyles,transform:`translate(`+xVal+`px, `+yVal+`px)`,...getDPR(floatingElement.value)>=1.5&&{willChange:`transform`}}:{position:strategy.value,left:xVal+`px`,top:yVal+`px`}}),whileElementsMountedCleanup;function update$6(){if(referenceElement.value==null||floatingElement.value==null)return;let open$1=openOption.value;computePosition(referenceElement.value,floatingElement.value,{middleware:middlewareOption.value,placement:placementOption.value,strategy:strategyOption.value}).then(position=>{x.value=position.x,y.value=position.y,strategy.value=position.strategy,placement.value=position.placement,middlewareData.value=position.middlewareData,isPositioned.value=open$1!==!1})}function cleanup(){typeof whileElementsMountedCleanup==`function`&&(whileElementsMountedCleanup(),whileElementsMountedCleanup=void 0)}function attach(){if(cleanup(),whileElementsMountedOption===void 0){update$6();return}if(referenceElement.value!=null&&floatingElement.value!=null){whileElementsMountedCleanup=whileElementsMountedOption(referenceElement.value,floatingElement.value,update$6);return}}function reset$1(){openOption.value||(isPositioned.value=!1)}return watch([middlewareOption,placementOption,strategyOption,openOption],update$6,{flush:`sync`}),watch([referenceElement,floatingElement],attach,{flush:`sync`}),watch(openOption,reset$1,{flush:`sync`}),getCurrentScope()&&onScopeDispose(cleanup),{x:shallowReadonly(x),y:shallowReadonly(y),strategy:shallowReadonly(strategy),placement:shallowReadonly(placement),middlewareData:shallowReadonly(middlewareData),isPositioned:shallowReadonly(isPositioned),floatingStyles,update:update$6}}var ARROW_POSITION={top:`bottom`,right:`left`,bottom:`top`,left:`right`};const usePopover=defineStore(`popover`,()=>{let _counter=ref(0),_currentPopover=ref(null),popovers=ref({}),currentPopover=computed(()=>_currentPopover.value),register=(name,popover,popoverPlacement=void 0,options={})=>{if(popovers.value[name])return;popovers.value[name]={element:popover,target:null,placement:popoverPlacement||`bottom`,show:!1};let popoverInstance=buildPopover(popover,toRef(popovers.value[name],`target`),toRef(popovers.value[name],`placement`),options),scope$1=effectScope(),show$1;scope$1.run(()=>{show$1=computed(()=>popovers.value[name].show)});let dispose$2=()=>{scope$1.stop(),popoverInstance.dispose()};return popovers.value[name].dispose=dispose$2,_counter.value++,{show:show$1,update:popoverInstance.update,placement:popoverInstance.placement}},bind=(popoverName,el,options)=>{let scope$1=effectScope(),hidden,isBound,popoverElement;scope$1.run(()=>{hidden=computed(()=>popovers.value[popoverName]?!popovers.value[popoverName].show:void 0),isBound=computed(()=>popovers.value[popoverName]?popovers.value[popoverName].target===el:void 0),popoverElement=computed(()=>popovers.value[popoverName]?popovers.value[popoverName].element:void 0)});let show$1=()=>{isBound.value||(popovers.value[popoverName].target=el,popovers.value[popoverName].placement=options.placement),popovers.value[popoverName].show=!0},hide$3=()=>{isBound.value&&(popovers.value[popoverName].show=!1)};return{popoverElement,hidden,isBound,show:show$1,hide:hide$3,toggle:(forceValue=void 0)=>{let doShow=forceValue;typeof doShow!=`boolean`&&(doShow=!isBound.value||!popovers.value[popoverName].show),doShow?show$1():hide$3()},isShown:()=>!!popovers.value[popoverName].show,unbind:()=>{scope$1.stop()}}},unregister=name=>{popovers.value[name]&&(popovers.value[name].dispose(),delete popovers.value[name])},isShown=name=>name in popovers.value?popovers.value[name].show:!1,show=(name,target)=>{name in popovers.value&&(popovers.value[name].show=!0,target&&(popovers.value[name].target=target),_currentPopover.value=popovers.value[name])},hide$2=name=>{name in popovers.value&&(popovers.value[name].show=!1,_currentPopover.value=null)};return{popovers,currentPopover,bind,register,unregister,isShown,show,hide:hide$2,toggle:(name,forceValue=void 0)=>{name in popovers.value&&(popovers.value[name].show=typeof forceValue==`boolean`?forceValue:!popovers.value[name].show,_currentPopover.value=popovers.value[name].show?popovers.value[name]:null)},hideAll:(startsWith=void 0)=>{let keys=Object.keys(popovers.value);startsWith&&(keys=keys.filter(name=>name.startsWith(startsWith))),keys.forEach(name=>popovers.value[name].show&&hide$2(name))},getPopover:name=>popovers.value[name],counter:computed(()=>_counter.value)}});function buildPopover(popover,reference,placementArg,options){let{floatingStyles,middlewareData,update:update$6,placement}=useFloating(reference,popover,{placement:placementArg,middleware:buildMiddleware(popover,options),whileElementsMounted:autoUpdate}),watchers$1=[];return watchers$1.push(watch(floatingStyles,async styles=>{popover.value&&await nextTick(()=>{Object.keys(styles).forEach(styleName=>popover.value.style[styleName]=styles[styleName])})})),options.arrow&&watchers$1.push(watch(middlewareData,async middlewareData$1=>{let left=middlewareData$1.arrow&&middlewareData$1.arrow.x!=null?`${middlewareData$1.arrow.x}px`:``,top=middlewareData$1.arrow&&middlewareData$1.arrow.y!=null?`${middlewareData$1.arrow.y}px`:``,arrowSide=ARROW_POSITION[middlewareData$1.offset.placement.split(`-`)[0]];await nextTick(()=>{applyStyles(options.arrow.value,{left,top,right:``,bottom:``,[arrowSide]:`-${options.arrow.value.offsetWidth/2}px`})})})),{placement,update:update$6,dispose:()=>{watchers$1.forEach(unwatch=>unwatch())}}}var arrowOffset=options=>({name:`arrowOffset`,options,fn({...state}){let arrOffset=Math.sqrt(2*options.element.value.offsetWidth**2)/2,side=state.placement.startsWith(`left`)||state.placement.startsWith(`top`)?-1:1;if(state.placement.startsWith(`left`)||state.placement.startsWith(`right`))return{x:state.x+side*arrOffset};if(state.placement.startsWith(`top`)||state.placement.startsWith(`bottom`))return{y:state.y+side*arrOffset}}});function buildMiddleware(popover,options){let middleware=[flip(),shift()],offsetValue=options.offset||0;return middleware.push(offset(offsetValue)),options.arrow&&(middleware.push(arrowOffset({element:options.arrow})),middleware.push(arrow({element:options.arrow}))),middleware}function applyStyles(el,styles){Object.keys(styles).forEach(styleName=>el.style[styleName]=styles[styleName])}var HOVER_SHOW_EVENTS=[`mouseover`,`focus`],HOVER_HIDE_EVENTS=[`mouseleave`,`blur`],TOGGLE_EVENTS=[`click`],BngPopover_default={mounted:setup$1,updated:setup$1,onBeforeUnmount:dispose};function setup$1(el,binding){dispose(el),binding.value&&(setPopoverProperties(el,binding),bindPopover(el),attachListeners(el,binding.modifiers))}function dispose(el){el.__popover&&(el.__popover.unregister&&el.__popover.unbind(),removeListeners(el))}function attachListeners(el,modifiers){el.__popover.showHandler=event=>{el.contains(event.target)&&el.__popover.show()},el.__popover.hideHandler=event=>{el.contains(event.relatedTarget)||el.__popover.hide()},el.__popover.toggleHandler=event=>{el.contains(event.target)&&el.__popover.toggle()},el.__popover.clickOutside=event=>{!el.contains(event.target)&&(!el.__popover.element.value||!el.__popover.element.value.contains(event.target))&&el.__popover.hide()},modifiers.click?(TOGGLE_EVENTS.forEach(eventName=>{el.addEventListener(eventName,el.__popover.toggleHandler)}),TOGGLE_EVENTS.forEach(eventName=>{window.addEventListener(eventName,el.__popover.clickOutside)})):(HOVER_SHOW_EVENTS.forEach(eventName=>el.addEventListener(eventName,el.__popover.showHandler)),HOVER_HIDE_EVENTS.forEach(eventName=>el.addEventListener(eventName,el.__popover.hideHandler)))}function removeListeners(el){el.__popover.toggleHandler&&(TOGGLE_EVENTS.forEach(eventName=>{el.removeEventListener(eventName,el.__popover.toggleHandler)}),TOGGLE_EVENTS.forEach(eventName=>{window.removeEventListener(eventName,el.__popover.clickOutside)})),el.__popover.showHandler&&HOVER_SHOW_EVENTS.forEach(eventName=>el.removeEventListener(eventName,el.__popover.showHandler)),el.__popover.hideHandler&&HOVER_SHOW_EVENTS.forEach(eventName=>el.removeEventListener(eventName,el.__popover.hideHandler))}function bindPopover(el){let popoverBind=usePopover().bind(el.__popover.name,el,getOptions$1(el));Object.assign(el.__popover,{toggle:popoverBind.toggle,show:popoverBind.show,isShown:popoverBind.isShown,hide:popoverBind.hide,toggle:popoverBind.toggle,hidden:popoverBind.hidden,element:popoverBind.popoverElement,unbind:popoverBind.unbind})}function setPopoverProperties(el,binding){el.__popover={name:getPopoverName(binding),placement:getPlacement(binding)}}var getOptions$1=el=>({placement:el.__popover.placement}),getPlacement=binding=>binding.arg?binding.arg:binding.placement?binding.placement:`left`,getPopoverName=binding=>typeof binding.value==`string`?binding.value:binding.value.name,TIMESPAN_TRANSLATE_ID_PREFIX=`ui.timespan.`,$t=i=>$translate.instant(TIMESPAN_TRANSLATE_ID_PREFIX+i),SECONDS_IN={year:3600*24*365,month:3600*24*30,week:3600*24*7,day:3600*24,hour:3600,minute:60,second:1},MINIMUM_SPAN=Object.entries(SECONDS_IN).slice(-1)[0][1],dateToEpoch=date=>date?typeof date==`string`?/^\d+$/.test(date)?+date:~~(new Date(date).getTime()/1e3):typeof date==`number`?date:0:0;const timeSpan=(date1,date2=null,length=2,useRelativeDescription=!1)=>{let res=`-`;if(date1=dateToEpoch(date1),!date1)return res;if(date2){if(date2=dateToEpoch(date2),!date2)return res}else date2=~~(new Date().getTime()/1e3);let diff,isFuture;return date1>=date2?(diff=date1-date2,isFuture=!0):(diff=date2-date1,isFuture=!1),res=formatTime(diff,length,useRelativeDescription,isFuture),res},formatTime=(seconds,length=2,useRelativeDescription=!1,future=!1)=>{let res=`-`;if(seconds20&&abs%10==1?abs+` `+$t(spanName+`.plural_1_pastfuture`):abs<=4||useRelativeDescription&&abs>20&&abs%10<=4?abs+` `+$t(spanName+`.plural_234`):abs+` `+$t(spanName+`.plural`),cur&&resArr.push(cur),length===1)break;length--,seconds%=spanSeconds}res=``;let resArrLen=resArr.length;return resArr.forEach((bit,i)=>{bit=bit.replace(` `,`\xA0`),i?(i===resArrLen-1?res+=` `+$t(`and`)+` `:res+=$t(`separator`)+` `,res+=bit):res+=ucaseFirst(bit)}),useRelativeDescription&&(res+=` `+$t(future?`future`:`past`)),res};var update=(element,{value})=>{let desc=timeSpan(value,null,1,!0);desc!==`-`&&(element.innerHTML=desc)},BngRelativeTime_default=update;const getScopeProperties=el=>{if(!(!el||!el.hasAttribute(`bng-ui-scope`)))return{scopeId:el.getAttribute(UI_SCOPE_ATTR$1),isScopedNav:el.hasAttribute(SCOPED_NAV_ATTR)}},findParentScope=(el,scopedNavOnly=!1)=>{let parent=el.parentElement;for(;parent;){let scopedNavId=parent.getAttribute(SCOPED_NAV_ATTR);if(scopedNavId)return{scopeId:scopedNavId,element:parent,isScopedNav:!0};if(!scopedNavOnly){let uiScopeId=parent.getAttribute(UI_SCOPE_ATTR$1);if(uiScopeId)return{scopeId:uiScopeId,element:parent,isScopedNav:!1}}parent=parent.parentElement}return null},isNavigable=el=>(!el.hasAttribute(`bng-no-nav`)||el.getAttribute(`bng-no-nav`)===`false`)&&(!el.hasAttribute(`disabled`)||el.getAttribute(`disabled`)===`false`),isDirectChild=(el,child)=>child.parentElement.closest(`[bng-scoped-nav]`)===el,getNavItems=(el,navigableOnly=!0)=>{let matches$1=el.querySelectorAll(NAVIGABLE_ELEMENTS_SELECTOR);return Array.from(matches$1).filter(child=>!isNavigable(child)&&navigableOnly?!1:isDirectChild(el,child))},getPassthroughEvents=el=>{let navItems=getNavItems(el,!1);if(navItems.length===0)return!1;let boundEvents=[];for(let elem of navItems){let uiNavEvents=elem.__BngOnUiNav?Object.values(elem.__BngOnUiNav).map(x=>x.eventNames).flat().filter(name=>!PASSTHROUGH_EXCLUDED_EVENTS.includes(name)):[],isDuplicate=uiNavEvents.some(event=>boundEvents.includes(event));if(uiNavEvents.length===0||isDuplicate){boundEvents=[];break}uiNavEvents.forEach(event=>{boundEvents.includes(event)||boundEvents.push(event)})}return boundEvents};var SCOPED_NAV_OBSERVER_EVENTS={onBeforeScopeActivated:`onBeforeScopeActivated`,onScopeActivated:`onScopeActivated`,onBeforeScopeDeactivated:`onBeforeScopeDeactivated`,onScopeDeactivated:`onScopeDeactivated`,onBeforeScopeSuspended:`onBeforeScopeSuspended`,onScopeSuspended:`onScopeSuspended`,onBeforeScopeResumed:`onBeforeScopeResumed`,onScopeResumed:`onScopeResumed`},scopedNavObservers={};function registerScopedNavObserver(id,observer$2){scopedNavObservers[id]=observer$2}function notifyScopedNavObservers(event,detail){Object.keys(scopedNavObservers).forEach(observerId=>{let callback=scopedNavObservers[observerId][event];if(callback&&typeof callback==`function`)try{callback(detail)}catch(error){logger_default.error(`Error in scoped nav observer ${observerId} for event ${event}`,error)}})}const useScopedNav=defineStore(`scopedNav2`,()=>{let scopeStack=ref([]),activateScope=(scopeId,element,options={activationType:SCOPED_NAV_STATES.active,suspendParentScopes:!1})=>{notifyScopedNavObservers(SCOPED_NAV_OBSERVER_EVENTS.onBeforeScopeActivated,{scopeId,element,options});let scopeIndex=scopeStack.value.findIndex(s=>s.scopeId===scopeId),existingScope=scopeIndex===-1?void 0:scopeStack.value[scopeIndex];if(existingScope&&existingScope.activationType===options.activationType){logger_default.warn(`Scope ${scopeId} already active. Ignoring...`),notifyScopedNavObservers(SCOPED_NAV_OBSERVER_EVENTS.onScopeActivated,{scopeId,element,options});return}existingScope?existingScope.activationType=options.activationType:(scopeStack.value.push({scopeId,element,...options}),scopeIndex=scopeStack.value.length-1),notifyScopedNavObservers(SCOPED_NAV_OBSERVER_EVENTS.onScopeActivated,{scopeId,element,options});let scopeData={scopeId,...options},{type}=element[SCOPED_NAV_PROPERTY_NAME];if(type===SCOPED_NAV_TYPES.popover||options.suspendParentScopes){let referenceElement=element;if(type===SCOPED_NAV_TYPES.popover){let popover=usePopover(),popoverName=element.getAttribute(`data-bng-popover-name`),pop=popover.getPopover(popoverName);pop&&pop.target&&(referenceElement=pop.target)}if(!referenceElement){logger_default.warn(`Unable to find popover's target element. Skipping suspending parent scopes...`);return}let parentScopes=scopeStack.value.slice(0,scopeIndex);for(let i=parentScopes.length-1;i>=0;i--){let scope$1=parentScopes[i];referenceElement&&scope$1.element.contains(referenceElement)?suspendScope(scope$1.scopeId,scopeData):referenceElement&&!scope$1.element.contains(referenceElement)&&deactivateScope(scope$1.scopeId)}}return getUINavServiceInstance().setActiveScope(scopeId),element.dispatchEvent(new CustomEvent(SCOPED_NAV_EVENTS.activate,{detail:scopeData})),scopeData},deactivateScope=(scopeId,settings$1={resumePrevious:!1})=>{let scopeIndex=scopeStack.value.findIndex(s=>s.scopeId===scopeId);if(scopeIndex===-1){logger_default.warn(`Scope ${scopeId} not found. Ignoring...`);return}notifyScopedNavObservers(SCOPED_NAV_OBSERVER_EVENTS.onBeforeScopeDeactivated,{scopeId,settings:settings$1});let scopeData=scopeStack.value[scopeIndex],element=scopeData.element,{type}=element[SCOPED_NAV_PROPERTY_NAME];if(scopeStack.value=scopeStack.value.slice(0,scopeIndex),element.dispatchEvent(new CustomEvent(SCOPED_NAV_EVENTS.deactivate,{detail:{scopeId,settings:settings$1,...scopeData}})),notifyScopedNavObservers(SCOPED_NAV_OBSERVER_EVENTS.onScopeDeactivated,{scopeId,settings:settings$1}),!settings$1.resumePrevious){getUINavServiceInstance().setActiveScope(null);return}let parentScope;if(type===SCOPED_NAV_TYPES.popover){let popover=usePopover(),popoverName=element.getAttribute(`data-bng-popover-name`),pop=popover.getPopover(popoverName);pop?parentScope=findParentScope(pop.target,!0):logger_default.warn(`Unable to find popover's target element. Skipping resume...`)}else parentScope=findParentScope(element,!0);parentScope?getScopeById(parentScope.scopeId)?resumeScope(parentScope.scopeId):activateScope(parentScope.scopeId,parentScope.element):getUINavServiceInstance().setActiveScope(null)},resumeScope=scopeId=>{let scopeIndex=scopeStack.value.findIndex(s=>s.scopeId===scopeId);if(scopeIndex===-1){logger_default.warn(`Scope ${scopeId} not found. Ignoring...`);return}notifyScopedNavObservers(SCOPED_NAV_OBSERVER_EVENTS.onBeforeScopeResumed,{scopeId});for(let i=scopeStack.value.length-1;i>scopeIndex;i--){let scope$1=scopeStack.value[i];deactivateScope(scope$1.scopeId)}let scopeData=scopeStack.value[scopeIndex];return scopeData.activationType=SCOPED_NAV_STATES.active,getUINavServiceInstance().setActiveScope(scopeData.scopeId),scopeData.element.dispatchEvent(new CustomEvent(SCOPED_NAV_EVENTS.resume,{detail:scopeData})),notifyScopedNavObservers(SCOPED_NAV_OBSERVER_EVENTS.onScopeResumed,{scopeId}),scopeData},suspendScope=(scopeId,newScope)=>{let scopeIndex=scopeStack.value.findIndex(s=>s.scopeId===scopeId);if(scopeIndex===-1){logger_default.warn(`Scope ${scopeId} not found. Ignoring...`);return}notifyScopedNavObservers(SCOPED_NAV_OBSERVER_EVENTS.onBeforeScopeSuspended,{scopeId,newScope});let scopeData=scopeStack.value[scopeIndex];if(scopeData.activationType===SCOPED_NAV_STATES.suspended){logger_default.warn(`Scope ${scopeId} already suspended. Ignoring...`);return}scopeData.activationType=SCOPED_NAV_STATES.suspended;let element=scopeData.element,payload={scopeId,newScope,...scopeData};return element.dispatchEvent(new CustomEvent(SCOPED_NAV_EVENTS.suspend,{detail:payload})),notifyScopedNavObservers(SCOPED_NAV_OBSERVER_EVENTS.onScopeSuspended,{scopeId,newScope}),scopeData},currentScope=()=>scopeStack.value[scopeStack.value.length-1],getScopeById=scopeId=>scopeStack.value.find(s=>s.scopeId===scopeId);return{activateScope,deactivateScope,resumeScope,suspendScope,getScopeById,currentScope,isCurrentScope:scopeId=>{let scope$1=currentScope();return scope$1&&scope$1.scopeId===scopeId},isActiveScope:scopeId=>{let current=currentScope();if(!current)return!1;if(current.scopeId===scopeId)return!0;if(current.activationType===SCOPED_NAV_STATES.partial&&scopeStack.value.length>2){let parentScope=scopeStack.value[scopeStack.value.length-2];if(parentScope.scopeId===scopeId&&parentScope.activationType===SCOPED_NAV_STATES.active)return!0}return!1},getScopes:()=>scopeStack.value}});var focusDebounceTimer=null,pendingFocusAction=null,focusListenersInitialized=!1,isActivatingScope=!1,isDeactivatingScope=!1,FOCUS_DEBOUNCE_TIME=200,focusManagerId=`focusManager`,clearFocusDebounce=()=>{focusDebounceTimer&&=(clearTimeout(focusDebounceTimer),null),pendingFocusAction=null},debouncedFocusAction=action=>{clearFocusDebounce(),pendingFocusAction=action,focusDebounceTimer=setTimeout(()=>{pendingFocusAction&&=(pendingFocusAction(),null),focusDebounceTimer=null},FOCUS_DEBOUNCE_TIME)};function useFocusManager(){let scopedNav=useScopedNav(),onUINavFocus=e=>{let{target,relatedTarget}=e.detail;if(isWithinDashmenu(target)||isWithinPopup(target))return;let targetScope=findParentScope(target,!0),scopeElement=targetScope&&targetScope.isScopedNav?targetScope.element:null,scopedNavProps=scopeElement&&scopeElement._bngScopedNav?scopeElement[SCOPED_NAV_PROPERTY_NAME]:null;if(scopedNavProps&&(scopeElement[SCOPED_NAV_PROPERTY_NAME].lastActiveElement=target),isActivatingScope||isDeactivatingScope||shouldSkipFocusHandling(scopedNavProps)){clearFocusDebounce();return}debouncedFocusAction(()=>handleFocusAction(target,targetScope,scopeElement,scopedNav))},onUINavBlur=e=>{let{target}=e.detail,scopeProperties=getScopeProperties(target);shouldHandleBlur(scopeProperties,scopedNav.currentScope())&&(target[SCOPED_NAV_PROPERTY_NAME].passthroughActive=!1,scopedNav.deactivateScope(scopeProperties.scopeId,{resumePrevious:!0}))};function addFocusListeners(){focusListenersInitialized||=(document.addEventListener(`uinav-focus`,onUINavFocus),document.addEventListener(`uinav-blur`,onUINavBlur),registerScopedNavObserver(focusManagerId,{onBeforeScopeActivated:()=>{clearFocusDebounce(),isActivatingScope=!0},onScopeActivated:()=>{clearFocusDebounce(),isActivatingScope=!1},onBeforeScopeDeactivated:()=>{clearFocusDebounce(),isDeactivatingScope=!0},onScopeDeactivated:()=>{clearFocusDebounce(),isDeactivatingScope=!1}}),!0)}function removeFocusListeners(){focusListenersInitialized&&=(document.removeEventListener(`uinav-focus`,onUINavFocus),document.removeEventListener(`uinav-blur`,onUINavBlur),!1)}function setup$3(){addFocusListeners()}function dispose$2(){removeFocusListeners()}return onMounted(()=>{setup$3()}),onBeforeUnmount(()=>{dispose$2()}),{setup:setup$3,dispose:dispose$2}}function isWithinDashmenu(target){return document.getElementById(`dashmenu`)?.contains(target)}function isWithinPopup(target){return!!target.closest(`dialog`)}function shouldSkipFocusHandling(scopedNavProps){return scopedNavProps?.type===SCOPED_NAV_TYPES.popover}function shouldHandleBlur(scopeProperties,currScope){return scopeProperties?.isScopedNav&&currScope?.scopeId===scopeProperties.scopeId&&currScope?.activationType===SCOPED_NAV_STATES.partial}function handleFocusAction(target,targetScope,scopeElement,scopedNavStore){if(!document.contains(target)&&!document.contains(scopeElement))return;let activeScope=scopedNavStore.currentScope();if(activeScope?.element===target)return;let existingScope,scopes=scopedNavStore.getScopes();for(let i=scopes.length-1;i>=0;i--){let scope$1=scopes[i];if(scope$1.element===scopeElement){existingScope=scope$1;break}}if(existingScope&&activeScope&&existingScope.scopeId!==activeScope.scopeId){scopedNavStore.resumeScope(existingScope.scopeId);return}scopes=scopedNavStore.getScopes();for(let i=scopes.length-1;i>=0;i--){let scope$1=scopes[i];if(scope$1.element===target||scope$1.element.contains(target)||scopeElement===scope$1.element||scope$1.element.contains(scopeElement))break;scopedNavStore.deactivateScope(scope$1.scopeId)}if(scopes=scopedNavStore.getScopes(),targetScope&&targetScope.isScopedNav){let lastScope=scopes.length>0?scopes[scopes.length-1]:null;lastScope&&activeScope&&activeScope.scopeId===lastScope.scopeId&&targetScope.scopeId!==lastScope.scopeId&&lastScope.activationType!==SCOPED_NAV_STATES.suspended&&scopedNavStore.suspendScope(lastScope.scopeId,{scopeId:targetScope.scopeId,scopeElement}),(!activeScope||activeScope.scopeId!==targetScope.scopeId)&&scopeElement._bngScopedNav.canActivate()&&scopedNavStore.activateScope(targetScope.scopeId,scopeElement)}if(target.hasAttribute(`bng-scoped-nav`)){let allowPartialActivation=target[SCOPED_NAV_PROPERTY_NAME].passthroughEnabled,canActivate=target[SCOPED_NAV_PROPERTY_NAME].canActivate();if(target[SCOPED_NAV_PROPERTY_NAME].passthroughActive=!0,allowPartialActivation&&canActivate){let partialScope=getScopeProperties(target);scopedNavStore.activateScope(partialScope.scopeId,target,{activationType:SCOPED_NAV_STATES.partial})}}}var PROPERTY_NAME=`_bngScopedNav`,ATTR_NAME=`bng-scoped-nav`,AUTOFOCUS_ATTR=`bng-scoped-nav-autofocus`,UI_SCOPE_ATTR=`bng-ui-scope`,NAV_ITEM_ATTR=`bng-nav-item`,BNG_ON_UI_NAV_ATTR=`__BngOnUiNav`,DEFAULT_AUTO_FOCUS_DELAY=100,EVENTS_UINAV_MAP={activate:[UI_EVENTS.ok],deactivate:[UI_EVENTS.back],navigation:[...UI_EVENT_GROUPS.focusMove,...UI_EVENT_GROUPS.focusMoveScalar]},NAV_EVENTS={activate:`activate`,deactivate:`deactivate`,suspend:`suspend`,resume:`resume`};const ACTIONS_ON_SUSPEND={allowNavigationLastNavItem:`allowNavigationLastNavItem`,allowNavigationByAttribute:`allowNavigationByAttribute`,disableNavigation:`disableNavigation`};var BngScopedNav_default={beforeMount,mounted,updated,beforeUnmount,unmounted},getDefaultOptions=()=>({type:SCOPED_NAV_TYPES.normal,activateOnMount:!1,actionsOnSuspend:[ACTIONS_ON_SUSPEND.disableNavigation],bubbleWhitelistEvents:[],bubbleBlacklistEvents:[],forcePassthroughEvents:[],canActivate:()=>!0,canDeactivate:()=>!0,autoFocusDelay:DEFAULT_AUTO_FOCUS_DELAY}),canBubbleEventInternal=(el,e)=>{let{bubbleWhitelistEvents,canBubbleEvent}=el[PROPERTY_NAME];return canBubbleEvent&&typeof canBubbleEvent==`function`?canBubbleEvent(e):bubbleWhitelistEvents&&Array.isArray(bubbleWhitelistEvents)&&bubbleWhitelistEvents.length>0?bubbleWhitelistEvents.includes(e.detail.name):!1},shouldBubbleToNextScope=(el,e)=>{let currentScope=useScopedNav().currentScope(),{scopeId,type}=el[PROPERTY_NAME],isActive=currentScope&¤tScope.scopeId===scopeId,isPartial=isActive&¤tScope.activationType===SCOPED_NAV_STATES.partial,isContainer=type===SCOPED_NAV_TYPES.container,isInactiveAndFocused=document.activeElement===el&&!isActive;return!currentScope||isInactiveAndFocused||canBubbleEventInternal(el,e)||isPartial||isContainer},getOptions=(el,binding,vnode)=>{let options={...getDefaultOptions(),...binding.value};if(!Object.values(SCOPED_NAV_TYPES).includes(options.type)){console.error(`Invalid scoped nav type: ${options.type}`);return}return options},applyOptions=(el,options)=>{let attributes={};switch(options.type){case SCOPED_NAV_TYPES.normal:attributes[NAV_ITEM_ATTR]=``,attributes[NO_CHILD_NAV_ATTR]=`true`;break;case SCOPED_NAV_TYPES.nonav:attributes[NO_NAV_ATTR]=`true`,attributes[NO_CHILD_NAV_ATTR]=`true`;break}Object.keys(attributes).forEach(attr=>el.setAttribute(attr,attributes[attr]))},findAutoFocusItem=navItems=>navItems.find(item=>item.hasAttribute(AUTOFOCUS_ATTR)&&item.getAttribute(AUTOFOCUS_ATTR)!==`false`),getAutoFocusItem=el=>findAutoFocusItem(getNavItems(el)),getFirstOrDefaultNavItem=el=>{let navItems,isAutoFocusItem=!1,getNavItems$1=()=>navItems||=getNavItems(el),getLastActive=()=>{let elm=el[PROPERTY_NAME].lastActiveElement;return elm&&!document.contains(elm)?null:elm},getAutoFocus=()=>{let elm=findAutoFocusItem(getNavItems$1());return elm&&!isNavigable(elm)?null:(isAutoFocusItem=!!elm,elm)},getFirst=()=>getNavItems$1()[0],sequence=[getLastActive,getAutoFocus];el[PROPERTY_NAME].preferAutoFocus&&sequence.reverse(),sequence.push(getFirst);for(let func of sequence){let elm=func();if(elm)return{focusItem:elm,isAutoFocusItem}}return{focusItem:null,isAutoFocusItem:!1}},setEnabledNavigation=(el,enabled,settings$1={applyToChildItems:!1,filterElements:void 0})=>{let{type}=el[PROPERTY_NAME];if(type===SCOPED_NAV_TYPES.nonav){logger_default.warn(`Cannot toggle navigation settings for nonav type`,el,enabled,type);return}settings$1.applyToChildItems?getNavItems(el,!1).forEach(item=>{if(!(settings$1.filterElements&&settings$1.filterElements.includes(item))){if(!item[PROPERTY_NAME]){let currentValue=item.hasAttribute(`bng-no-nav`)?item.getAttribute(NO_NAV_ATTR):void 0;item[PROPERTY_NAME]={originalNoNav:currentValue,hadOriginalNoNav:currentValue!==void 0}}enabled?(item[PROPERTY_NAME].hadOriginalNoNav?item.setAttribute(NO_NAV_ATTR,item[PROPERTY_NAME].originalNoNav):item.removeAttribute(NO_NAV_ATTR),item[PROPERTY_NAME].noNavSetByDirective=!1):(!item[PROPERTY_NAME].hadOriginalNoNav||item[PROPERTY_NAME].originalNoNav!==`true`)&&(item.setAttribute(NO_NAV_ATTR,`true`),item[PROPERTY_NAME].noNavSetByDirective=!0)}}):enabled?(el.removeAttribute(NO_CHILD_NAV_ATTR),type===SCOPED_NAV_TYPES.normal&&el.setAttribute(NO_NAV_ATTR,`true`)):(el.setAttribute(NO_CHILD_NAV_ATTR,`true`),type===SCOPED_NAV_TYPES.normal&&el.removeAttribute(NO_NAV_ATTR))},focusFirstOrDefaultNavItem=el=>{let{autoFocusDelay}=el[PROPERTY_NAME];nextTick(()=>{setTimeout(()=>{let{focusItem,isAutoFocusItem}=getFirstOrDefaultNavItem(el);focusItem&&setFocusExternal(focusItem,!0,isAutoFocusItem)},autoFocusDelay)})},ensureFocusOrFocusDefault=el=>{document.activeElement&&isDirectChild(el,document.activeElement)?ensureFocus(document.activeElement,!0):focusFirstOrDefaultNavItem(el)};function beforeMount(el,binding,vnode){let options=getOptions(el,binding,vnode);if(!options)return;let scopeId=options.scopeId||uniqueId(`scoped-nav`);el[PROPERTY_NAME]={scopeId,...options},el[PROPERTY_NAME].shouldBubbleEvent=e=>shouldBubbleToNextScope(el,e),el.setAttribute(ATTR_NAME,scopeId),el.setAttribute(UI_SCOPE_ATTR,scopeId),applyOptions(el,options)}function mounted(el,binding,vnode){addUINavEventListeners(el,binding,vnode),addScopedNavEventListeners(el);let scopedNav=useScopedNav(),options=getOptions(el,binding,vnode);options.type===SCOPED_NAV_TYPES.normal?configurePartialActivation(el):options.type===SCOPED_NAV_TYPES.container&&configureContainer(el,!1),options.activateOnMount&&nextTick(()=>scopedNav.activateScope(el[PROPERTY_NAME].scopeId,el))}var handleDefaultUpdate=(el,binding,vnode)=>{let activeScope=useScopedNav().currentScope(),{scopeId,type}=el[PROPERTY_NAME];!activeScope||activeScope.scopeId!==scopeId||activeScope.activationType!==SCOPED_NAV_STATES.active||ensureFocusOrFocusDefault(el)};function updated(el,binding,vnode){let options=getOptions(el,binding,vnode),{scopeId}=el[PROPERTY_NAME],scopedNav=useScopedNav();if(options.activated===!0&&!scopedNav.isActiveScope(scopeId))if(scopedNav.getScopeById(scopeId)){let popover=usePopover();if(Object.values(popover.popovers).filter(x=>x.show===!0).length>0)return;scopedNav.resumeScope(scopeId,el)}else scopedNav.activateScope(scopeId,el,{activationType:SCOPED_NAV_STATES.active,suspendParentScopes:!0});else options.activated===!1&&scopedNav.isActiveScope(scopeId)?scopedNav.deactivateScope(scopeId,{resumePrevious:!0}):!scopedNav.isActiveScope(scopeId)&&options.type===SCOPED_NAV_TYPES.container&&configureContainer(el,!1);nextTick(()=>{let activeScope=scopedNav.currentScope();activeScope&&activeScope.scopeId===scopeId&&handleDefaultUpdate(el,binding,vnode)})}function beforeUnmount(el,binding,vnode){removeScopedNavEventListeners(el);let scopedNav=useScopedNav();if(scopedNav.getScopeById(el[PROPERTY_NAME].scopeId)){let{type}=el[PROPERTY_NAME];scopedNav.deactivateScope(el[PROPERTY_NAME].scopeId,{resumePrevious:type===SCOPED_NAV_TYPES.popover}),el.dispatchEvent(new CustomEvent(NAV_EVENTS.deactivate,{detail:{force:!0,reason:`unmounted`}}))}}function unmounted(el,binding,vnode){}var handlePartialActivation=(el,event)=>{el[PROPERTY_NAME].forceBubble=!0},handleNormalActivation=(el,event)=>{el[PROPERTY_NAME].forceBubble=!1,nextTick(()=>{setEnabledNavigation(el,!0),(!document.activeElement||el===document.activeElement||!el.contains(document.activeElement))&&focusFirstOrDefaultNavItem(el)})},configurePartialActivation=el=>{let passthroughEvents=getPassthroughEvents(el);el[PROPERTY_NAME].passthroughEnabled=passthroughEvents.length>0,el[PROPERTY_NAME].passthroughEvents=passthroughEvents},configureContainer=(el,activated)=>{el[PROPERTY_NAME].containerSetup&&el[PROPERTY_NAME].containerSetup.cancel(),el[PROPERTY_NAME].containerSetup=debounce(()=>{let autoFocusItem=getAutoFocusItem(el);autoFocusItem&&setEnabledNavigation(el,activated,{applyToChildItems:!0,filterElements:[autoFocusItem]})},100),el[PROPERTY_NAME].containerSetup()},handleContainerActivation=(el,event)=>{configureContainer(el,!0)},handleNoNavActivation=(el,event)=>{},onActivate=(el,event)=>{let{type}=el[PROPERTY_NAME],{activationType}=event.detail;activationType===SCOPED_NAV_STATES.partial?handlePartialActivation(el,event):type===SCOPED_NAV_TYPES.normal?handleNormalActivation(el,event):type===SCOPED_NAV_TYPES.container?handleContainerActivation(el,event):SCOPED_NAV_TYPES.nonav,el.dispatchEvent(new CustomEvent(NAV_EVENTS.activate,{detail:event.detail}))},onDeactivate=(el,event)=>{let{type}=el[PROPERTY_NAME];type===SCOPED_NAV_TYPES.normal&&event.detail.activationType===SCOPED_NAV_STATES.active?setEnabledNavigation(el,!1):type===SCOPED_NAV_TYPES.container&&configureContainer(el,!1),el[PROPERTY_NAME].forceBubble=!1,el.dispatchEvent(new CustomEvent(NAV_EVENTS.deactivate,{detail:event.detail}))},onSuspend=(el,event)=>{let{actionsOnSuspend,type}=el[PROPERTY_NAME],filterElements=[];if(actionsOnSuspend.includes(ACTIONS_ON_SUSPEND.allowNavigationLastNavItem)){let lastActiveElement=el[PROPERTY_NAME].lastActiveElement;lastActiveElement&&document.contains(lastActiveElement)&&filterElements.push(lastActiveElement)}setEnabledNavigation(el,!1,{applyToChildItems:!0,filterElements})},onResume=(el,event)=>{let{actionsOnSuspend,type}=el[PROPERTY_NAME],filterElements=[];if(actionsOnSuspend.includes(ACTIONS_ON_SUSPEND.allowNavigationLastNavItem)){let lastActiveElement=el[PROPERTY_NAME].lastActiveElement;lastActiveElement&&document.contains(lastActiveElement)&&filterElements.push(lastActiveElement)}setEnabledNavigation(el,!0,{applyToChildItems:!0,filterElements}),ensureFocusOrFocusDefault(el)};function addScopedNavEventListeners(el){let eventHandlers={[SCOPED_NAV_EVENTS.activate]:event=>onActivate(el,event),[SCOPED_NAV_EVENTS.deactivate]:event=>onDeactivate(el,event),[SCOPED_NAV_EVENTS.suspend]:event=>onSuspend(el,event),[SCOPED_NAV_EVENTS.resume]:event=>onResume(el,event)};Object.keys(eventHandlers).forEach(eventName=>{el[PROPERTY_NAME].scopedNavListeners||(el[PROPERTY_NAME].scopedNavListeners={}),el.addEventListener(eventName,eventHandlers[eventName]),el[PROPERTY_NAME].scopedNavListeners[eventName]=eventHandlers[eventName]})}function removeScopedNavEventListeners(el){!el||!el[PROPERTY_NAME]||!el[PROPERTY_NAME].scopedNavListeners||Object.keys(el[PROPERTY_NAME].scopedNavListeners).forEach(eventName=>{el.removeEventListener(eventName,el[PROPERTY_NAME].scopedNavListeners[eventName]),delete el[PROPERTY_NAME].scopedNavListeners[eventName]})}var allowsNavigation=el=>{let{type}=el[PROPERTY_NAME];return[SCOPED_NAV_TYPES.normal,SCOPED_NAV_TYPES.container,SCOPED_NAV_TYPES.popover].includes(type)},processNavigationEvent=(el,e)=>{let currentScope=useScopedNav().currentScope(),{scopeId}=el[PROPERTY_NAME];if(!allowsNavigation(el))return!1;document.activeElement===el&¤tScope.scopeId===scopeId?focusFirstOrDefaultNavItem(el):handleUINavEvent(e,el)},isNavigationEvent=e=>UI_EVENT_GROUPS.navigation.includes(e.detail.name),getUINavEventsByEl=el=>{let uiNavEvents=el[BNG_ON_UI_NAV_ATTR]?Object.values(el[BNG_ON_UI_NAV_ATTR]).map(x=>x.eventNames).flat():[],boundEvents=[];return uiNavEvents.forEach(ev=>{boundEvents.includes(ev)||boundEvents.push(ev)}),boundEvents},hasBoundEvent=(el,eventName)=>{let boundEvents=getUINavEventsByEl(el);return boundEvents&&boundEvents.length>0&&boundEvents.includes(eventName)},isUINavEventBoundToChild=(el,e)=>{let{scopeId}=el[PROPERTY_NAME],currentScope=useScopedNav().currentScope();return currentScope&¤tScope.scopeId===scopeId&&e.target!==el&&el.contains(e.target)&&e.target===document.activeElement&&hasBoundEvent(e.target,e.detail.name)},generalHandler=(el,e)=>{let shouldBubble=!1;return isUINavEventBoundToChild(el,e)&&!e.target.hasAttribute(ATTR_NAME)||(shouldBubbleToNextScope(el,e)?shouldBubble=!0:isNavigationEvent(e)&&processNavigationEvent(el,e)),shouldBubble},processOkChildHandler=(el,e)=>{isUINavEventBoundToChild(el,e)||(handleUINavEvent(e,e.target),e.detail.sendToCrossfire=!1)},okHandler=(el,e)=>{if(e.detail.value!==1)return shouldBubbleToNextScope(el,e);let scopedNav=useScopedNav(),scopeId=el[PROPERTY_NAME].scopeId,currentScope=scopedNav.currentScope();return currentScope&¤tScope.scopeId===scopeId&¤tScope.activationType===SCOPED_NAV_STATES.active&&(document.activeElement&&isDirectChild(el,document.activeElement)||e.target&&isDirectChild(el,e.target))?processOkChildHandler(el,e):el[PROPERTY_NAME].canActivate()&&el[PROPERTY_NAME].type===SCOPED_NAV_TYPES.normal&&document.activeElement===el&&scopedNav.activateScope(scopeId,el),shouldBubbleToNextScope(el,e)},backHandler=(el,e)=>{if(e.detail.value!==1)return;let scopedNav=useScopedNav(),{scopeId,type,canDeactivate}=el[PROPERTY_NAME],currentScope=scopedNav.currentScope();if(currentScope&¤tScope.scopeId===scopeId&¤tScope.activationType===SCOPED_NAV_STATES.active)canDeactivate()&&(scopedNav.deactivateScope(scopeId,{resumePrevious:!0,executingScope:scopeId}),type===SCOPED_NAV_TYPES.normal&&nextTick(()=>setFocusExternal(el)));else if(e.target!==el&&isDirectChild(el,e.target))return!1;else return!0},uiNavEventsHandler=(el,e)=>{let uiNavEvent=e.detail.name;return EVENTS_UINAV_MAP.activate.includes(uiNavEvent)?okHandler(el,e):EVENTS_UINAV_MAP.deactivate.includes(uiNavEvent)?backHandler(el,e):generalHandler(el,e)};function addUINavEventListeners(el,binding,vnode){let{bubbleWhitelistEvents}=el[PROPERTY_NAME],generalUINavBinding={arg:[...EVENTS_UINAV_MAP.activate,...EVENTS_UINAV_MAP.deactivate,...EVENTS_UINAV_MAP.navigation].join(`,`),value:e=>uiNavEventsHandler(el,e)};BngOnUiNav_default.mounted(el,generalUINavBinding,vnode)}var ID=`__bngSound`,ID_STOP=`__bngSoundStop`,events$1={click:`click`,dblclick:`dblclick`,focus:`focus`,mouseenter:`mouseenter`};function handler(ev){let el=ev.currentTarget;if(el&&(el[ID]&&events$1[ev.type]&&Lua_default.ui_audio.playEventSound(el[ID],events$1[ev.type]),el[ID_STOP]))for(let event in delete el[ID_STOP],delete el[ID],events$1)el.removeEventListener(event,handler)}var BngSoundClass_default={mounted:(el,binding)=>{delete el[ID_STOP],el[ID]=binding.value,nextTick(()=>{for(let event in events$1)el.addEventListener(event,handler)})},updated:(el,binding)=>{el[ID]=binding.value},unmounted:el=>{el[ID_STOP]=!0}},marker=`__BNG_SD_INPUT`,inputTypes={singleLine:0,multiLine:1};function bindToInputs(elements){let inputs=Array.isArray(elements)?elements:[elements];for(let input of inputs){if(marker in input)continue;input[marker]=!0;let type,tag=input.tagName.toLowerCase();if(tag===`textarea`)type=inputTypes.multiLine;else if(tag===`input`&&[`text`,`number`,`password`,`search`].includes(input.type.toLowerCase()))type=inputTypes.singleLine;else continue;input.addEventListener(`focus`,()=>{let rect=input.getBoundingClientRect();console.log(`SteamDeck input focus:`,type,rect),Lua_default.Steam.showFloatingGamepadTextInput(type,rect.left,rect.top,rect.width,rect.height)})}}async function useSteamDeckInput(inputs){if(!inputs)throw Error(`inputs must be specified (ref, refs, element, elements)`);(await useSettingsAsync()).values.runningOnSteamDeck&&(isRef(inputs)?watch(inputs,bindToInputs,{immediate:!0}):bindToInputs(inputs))}var bridge$1,focused=!1,elms={},elmid=`__BNG_TEXT_INPUT`,focus=id=>async()=>{elms[id].active=!0,focused||=(await bridge$1.lua.setCEFTyping(!0),!0)},blur=id=>async()=>{elms[id].active=!1,focused&&(focused=Object.values(elms).some(e=>e.active),focused||await bridge$1.lua.setCEFTyping(!1))},BngTextInput_default={mounted(el){bridge$1||(bridge$1=useBridge(),bridge$1.events.on(`CEFTypingLostFocus`,()=>focused&&document.activeElement.blur()));let id=el[elmid]||(el[elmid]=uniqueId());elms[id]={el,active:!1,onFocus:focus(id),onBlur:blur(id)},el.addEventListener(`focus`,elms[id].onFocus),el.addEventListener(`blur`,elms[id].onBlur),useSteamDeckInput(el)},beforeUnmount(el){let id=el[elmid];elms[id]&&(el.removeEventListener(`focus`,elms[id].onFocus),el.removeEventListener(`blur`,elms[id].onBlur),elms[id].onBlur(),delete elms[id])}},DEFAULT_POSITION=`left`,TOOLTIP_ATTR_NAME=`data-bng-tooltip`,CONTENT_ATTR_NAME=`data-bng-tooltip-content`,ARROW_ATTR_NAME=`data-bng-tooltip-arrow`,SHOW_TOOLTIP_EVENTS=[`mouseover`,`focusin`],HIDE_TOOLTIP_EVENTS=[`mouseout`,`focusout`],DATA_PROP=`__bngTooltip`,POPOVER_CONTAINER=`.popover-container`,BngTooltip_default={beforeMount(el){initTooltipData(el)},mounted(el,binding,vnode){setupBindings(el,binding),setupTooltip(el),setListeners(el)},beforeUpdate(el,binding){setupBindings(el,binding),el[DATA_PROP].text===void 0?removeTooltip(el):updateTooltipElement(el)},updated(el){let data=el[DATA_PROP];data.update&&requestAnimationFrame(()=>data.update())},beforeUnmount(el){SHOW_TOOLTIP_EVENTS.forEach(eventName=>el.removeEventListener(eventName,el.__showTooltip)),HIDE_TOOLTIP_EVENTS.forEach(eventName=>el.removeEventListener(eventName,el.__hideTooltip));let data=el[DATA_PROP];data.dispose&&data.dispose(),removeTooltip(el)}};function setListeners(el){let data=el[DATA_PROP];data.showTooltip||(data.showTooltip=event=>{data.hideDelay&&=(clearTimeout(data.hideDelay),null),data.tooltipAnimationFrame&&=(cancelAnimationFrame(data.tooltipAnimationFrame),null),el.contains(event.target)&&!data.tooltipElRef.value&&queueTooltipUpdate(el,!0)},SHOW_TOOLTIP_EVENTS.forEach(eventName=>el.addEventListener(eventName,data.showTooltip,!0))),data.hideTooltip||(data.hideTooltip=event=>{data.tooltipAnimationFrame&&=(cancelAnimationFrame(data.tooltipAnimationFrame),null),!el.contains(event.relatedTarget)&&data.tooltipElRef.value&&queueTooltipUpdate(el,!1)},HIDE_TOOLTIP_EVENTS.forEach(eventName=>el.addEventListener(eventName,data.hideTooltip,!0)))}function setupBindings(el,binding){if(binding.value){let bindingValues=getBindings(binding);el[DATA_PROP].text=bindingValues.text,el[DATA_PROP].hideDelayTime=bindingValues.hideDelay,el[DATA_PROP].position=bindingValues.position,el[DATA_PROP].isBBCode=bindingValues.isBBCode,el[DATA_PROP].style=bindingValues.style}else resetTooltipData(el)}function queueTooltipUpdate(el,shouldShow){let data=el[DATA_PROP];data.tooltipAnimationFrame&&cancelAnimationFrame(data.tooltipAnimationFrame),data.pendingTooltipState=shouldShow,data.tooltipAnimationFrame=requestAnimationFrame(()=>{data.pendingTooltipState?showTooltip(el):hideTooltip(el),data.tooltipAnimationFrame=null,data.pendingTooltipState=null})}function showTooltip(el){let data=el[DATA_PROP];data.text&&(addTooltip(el),usePopover().show(data.popoverName,el))}function hideTooltip(el){let data=el[DATA_PROP],hideFn=()=>{removeTooltip(el)};data.hideDelayTime&&typeof data.hideDelayTime==`number`&&data.hideDelayTime>0?data.hideDelay=setTimeout(()=>{hideFn(),data.hideDelay=null},data.hideDelayTime):hideFn()}function setupTooltip(el){let data=el[DATA_PROP],popover=usePopover(),popoverInstance=popover.register(data.popoverName,data.tooltipElRef,data.position,{arrow:data.arrowElRef,offset:4});if(!popoverInstance){console.error(`Failed to register tooltip`);return}el[DATA_PROP].update=popoverInstance.update,el[DATA_PROP].dispose=()=>popover.unregister(data.popoverName),popover.bind(data.popoverName,el,{placement:data.position})}function updateTooltipElement(el){if(el[DATA_PROP].tooltipElRef.value&&el[DATA_PROP].tooltipElRef.value){let updatedContent=parseText(el[DATA_PROP].text,el[DATA_PROP].isBBCode),spanEl=el[DATA_PROP].tooltipElRef.value.querySelector(`span`);spanEl.innerHTML=updatedContent}}function addTooltip(el){let data=el[DATA_PROP];data.tooltipElRef.value=createTooltip(data);let popoverContainer=document.querySelector(POPOVER_CONTAINER);popoverContainer||=(console.warn(`Popover container not found, using parent element`),el.parentElement),el[DATA_PROP].arrowElRef.value=createArrow(),data.tooltipElRef.value.appendChild(el[DATA_PROP].arrowElRef.value),popoverContainer.appendChild(data.tooltipElRef.value)}function removeTooltip(el){let data=el[DATA_PROP];usePopover().hide(data.popoverName),data.tooltipElRef.value&&(data.tooltipElRef.value.remove(),data.tooltipElRef.value=null),data.update&&data.update()}function createTooltip(data){let container=document.createElement(`div`);return data.style&&Object.keys(data.style).forEach(key=>container.style.setProperty(key,data.style[key])),container.setAttribute(TOOLTIP_ATTR_NAME,``),container.appendChild(createContent(data.text,data.isBBCode)),container}function createContent(text,isBBCode){let content=document.createElement(`span`);return Object.assign(content.style,{}),content.innerHTML=parseText(text,isBBCode),content.setAttribute(CONTENT_ATTR_NAME,``),content}function createArrow(){let arrow$3=document.createElement(`span`);return Object.assign(arrow$3.style,{}),arrow$3.setAttribute(ARROW_ATTR_NAME,``),arrow$3}function parseText(text,isBBCode){return isBBCode?parse$1(text):text}var getBindings=binding=>{let position=binding.arg?binding.arg:DEFAULT_POSITION,hideDelay,text,isBBCode=!1,style={};return typeof binding.value==`object`?(hideDelay=binding.value?.hideDelay||0,text=binding.value?.text||void 0,isBBCode=binding.value?.isBBCode||!1,style=binding.value?.style||{}):text=binding.value,{text,position,hideDelay,isBBCode,style}};function initTooltipData(el){el[DATA_PROP]={popoverName:uniqueId(`bng-tooltip`),tooltipElRef:ref(null),arrowElRef:ref(null)},resetTooltipData(el)}function resetTooltipData(el){el[DATA_PROP].text=void 0,el[DATA_PROP].style={},el[DATA_PROP].isBBCode=!1,el[DATA_PROP].hideDelayTime=void 0,el[DATA_PROP].position=void 0,el[DATA_PROP].hideDelay=null,el[DATA_PROP].tooltipAnimationFrame=null}var reg=(elm,{value})=>nextTick(()=>elm&&wantsFocus(elm,value)),BngUiNavFocus_default={mounted:reg,updated:reg,beforeUnmount:unwantsFocus},registry,procEventNames=eventNames=>eventNames.split(`,`).map(name=>name.trim()).filter(Boolean),BngUiNavLabel_default={mounted(el,{arg:eventNames,value:label}){if(!eventNames){console.warn(`Usage: v-bng-ui-nav-label:back,menu="'Back'"`);return}registry||=useUiNavLabel(),label&&(eventNames=procEventNames(eventNames),registry.registerLabel(el,eventNames,label))},updated(el,{arg:eventNames,value:label}){eventNames&&(eventNames=procEventNames(eventNames),label?registry.registerLabel(el,eventNames,label):registry.clearLabels(el,eventNames))},beforeUnmount(el){let events$3=registry.getElementEvents(el);events$3.length>0&®istry.clearLabels(el,events$3)}},SCROLL_PROP=`__bngUiNavScroll`;function enableScroll(id,el){let tracker=useUINavTracker();tracker.addEvent(SCROLL_EVENT_H,id,el),tracker.addEvent(SCROLL_EVENT_V,id,el),tracker.addForceUnblock(SCROLL_EVENT_H,id),tracker.addForceUnblock(SCROLL_EVENT_V,id)}function disableScroll(id,el){let tracker=useUINavTracker();tracker.removeEvent(SCROLL_EVENT_H,id,el),tracker.removeEvent(SCROLL_EVENT_V,id,el),tracker.removeForceUnblock(SCROLL_EVENT_H,id),tracker.removeForceUnblock(SCROLL_EVENT_V,id)}var BngUiNavScroll_default={mounted(element,{arg,value,modifiers}){let prev=element[SCROLL_PROP]||{},dir={id:prev.id||uniqueId(SCROLL_PROP),forced:modifiers.force,enable:()=>enableScroll(dir.id,element),disable:()=>disableScroll(dir.id,element)};if(element[SCROLL_PROP]=dir,prev.forced&&(element.removeEventListener(`focusin`,prev.enable),element.removeEventListener(`focusout`,prev.disable)),typeof value==`boolean`&&!value){prev.id&&prev.disable(),dir.forced=!1;return}dir.forced?(element.setAttribute(SCROLL_FORCE_ATTR,``),dir.enable()):(element.setAttribute(SCROLL_ATTR,``),element.addEventListener(`focusin`,dir.enable),element.addEventListener(`focusout`,dir.disable))},beforeUnmount(element){let dir=element[SCROLL_PROP];dir&&(dir.forced||(element.removeEventListener(`focusin`,dir.enable),element.removeEventListener(`focusout`,dir.disable)),dir.disable(),delete element[SCROLL_PROP])}},observed=new WeakMap;function createObserver(root=null,rootMargin=`0px`){return new IntersectionObserver(entries=>{for(let entry of entries){let data=observed.get(entry.target);if(!data){entry.target.observer?.unobserve(entry.target);return}if(data.onChange)data.onChange(entry.isIntersecting);else{let displayValue=entry.isIntersecting?[`display`,``,``]:[`display`,`none`,`important`];entry.target.style.setProperty(...displayValue),entry.target.querySelectorAll(`*`).forEach(child=>{child.style.setProperty(...displayValue)})}}},{root,rootMargin,threshold:0})}var defaultObserver=createObserver(),_sfc_main$404={__name:`bngActionDrawer`,props:{actions:{type:Object,default:{allowOpenDrawer:!1}},skeletonItems:{type:Number,default:5},usePath:Boolean,alwaysShowBack:Boolean,itemWidth:Number,itemHeight:Number,itemMargin:Number,big:Boolean,position:String,blur:Boolean},emits:[`select`],setup(__props,{expose:__expose,emit:__emit}){let props=__props,emit$1=__emit;__expose({goBack:onBack});let expanded=ref(!1),current=ref(props.actions),lazyItem={label:`…`,icon:icons.stopwatchSectionOutlinedStart};function onSelect(item){(`items`in item||item.lazyLoadItems)&&(current.value&&addBack(current.value),current.value=item),emit$1(`select`,item)}let backState=computed(()=>{let disable=back.value.length===0||!(`items`in current.value);return{show:!disable||props.alwaysShowBack,disable}}),back=ref([]);function onBack(){current.value=null,onSelect(back.value.pop().data)}function addBack(prevItem){let backItem={index:back.value.length,label:prevItem.label,data:prevItem};props.usePath&&prevItem.items&&(backItem.items=prevItem.items.reduce((res,itm)=>[...res,{index:backItem.index+1,label:itm.label,data:itm}],[])),back.value.push(backItem)}let path=computed(()=>props.usePath?[...back.value,{current:!0,label:current.value.label,data:current.value}]:void 0);function onPath(item){item.current||(back.value.splice(item.index),current.value=null,onSelect(item.data))}return watch(()=>props.actions,val=>{back.value.splice(0),current.value=val}),(_ctx,_cache)=>(openBlock(),createBlock(unref(bngDrawer_default),{modelValue:expanded.value,"onUpdate:modelValue":_cache[0]||=$event=>expanded.value=$event,expandable:current.value.allowOpenDrawer,position:__props.position,blur:__props.blur},createSlots({"header-controls":withCtx(()=>[__props.usePath?(openBlock(),createBlock(unref(bngBreadcrumbs_default),{key:0,items:path.value,limit:`5`,onClick:onPath},null,8,[`items`])):backState.value.show?(openBlock(),createBlock(unref(bngButton_default),{key:1,accent:unref(ACCENTS).outlined,disabled:backState.value.disable,onClick:onBack},{default:withCtx(()=>[..._cache[1]||=[createTextVNode(`Back`,-1)]]),_:1},8,[`accent`,`disabled`])):createCommentVNode(``,!0),renderSlot(_ctx.$slots,`controls`)]),content:withCtx(()=>[withDirectives((openBlock(),createBlock(unref(bngList_default),{layout:expanded.value?unref(LIST_LAYOUTS).TILES:unref(LIST_LAYOUTS).RIBBON,big:__props.big,"target-width":__props.itemWidth,"target-height":__props.itemHeight,"target-margin":__props.itemMargin,"no-background":``},{default:withCtx(()=>[`items`in current.value?(openBlock(!0),createElementBlock(Fragment,{key:0},renderList(current.value.items,(item,index)=>renderSlot(_ctx.$slots,`action`,{item,select:onSelect,isLoading:!1,order:index})),256)):(openBlock(!0),createElementBlock(Fragment,{key:1},renderList(__props.skeletonItems,idx=>renderSlot(_ctx.$slots,`action`,{item:lazyItem,select:()=>{},isLoading:!0})),256))]),_:3},8,[`layout`,`big`,`target-width`,`target-height`,`target-margin`])),[[unref(BngDisabled_default),!(`items`in current.value)]])]),_:2},[__props.usePath?void 0:{name:`header`,fn:withCtx(()=>[createTextVNode(toDisplayString(current.value.label),1)]),key:`0`}]),1032,[`modelValue`,`expandable`,`position`,`blur`]))}},bngActionDrawer_default=_sfc_main$404,__plugin_vue_export_helper_default=(sfc,props)=>{let target=sfc.__vccOpts||sfc;for(let[key,val]of props)target[key]=val;return target},_hoisted_1$347={class:`bng-accordion-container`},_sfc_main$403={__name:`accordion`,props:{singular:Boolean,expanded:Boolean,disabled:Boolean,animated:Boolean,selectable:[Boolean,Object],selected:Boolean,provideParent:Boolean},emits:[`selected`],setup(__props,{emit:__emit}){let props=__props,counter$1=0,items$2=[],selopts=null,emit$1=__emit;watch(()=>props.singular,val=>val&&toggle(items$2.find(itm=>itm.expanded),!0)),watch(()=>props.expanded,val=>toggle(null,val)),watch(()=>props.animated,val=>{for(let itm of items$2)itm.animated=val},{immediate:!0}),watch(()=>props.disabled,val=>{for(let itm of items$2)itm.disabled=val},{immediate:!0}),watch(()=>props.selectable,val=>{val?(selopts={multi:!1},typeof val==`object`&&(selopts={selopts,...val})):selopts=null;for(let itm of items$2)itm.selectable=selopts},{immediate:!0}),watch(()=>props.selected,val=>select(null,val));function toggle(item=null,expanded=null){if(props.singular&&!item&&expanded){if(items$2.length===0)return;item=items$2[0]}for(let itm of items$2){let exp=!itm.expandedActual;item&&itm.id!==item.id?exp=props.singular?!1:itm.expandedActual:typeof expanded==`boolean`&&(exp=expanded),itm.expandedActual=exp}}provide(`accordion-item-toggle`,toggle);function select(item=null,selected=null){let state=[];for(let itm of items$2){let sel;sel=item&&itm.id!==item.id?selopts.multi?itm.selected:!1:typeof selected==`boolean`?selected:selopts.multi?!itm.selected:!0,itm.selected!==sel&&(itm.selected=sel,state.push(itm))}state.length>0&&emit$1(`selected`,state)}provide(`accordion-item-select`,select),props.provideParent&&inject(`accordion-item-childSelect`)(select);let waitForOptions=cb=>selopts?cb():setTimeout(()=>waitForOptions(cb),50);return provide(`accordion-item-register`,item=>{item.id=counter$1++,props.expanded&&(item.expanded=props.expanded),props.disabled&&(item.disabled=props.disabled),props.selectable&&(item.selectable=props.selectable),items$2.push(item),waitForOptions(()=>{props.singular&&item.expanded&&toggle(item,!0),item.selected&&select(item,!0)})}),provide(`accordion-item-unregister`,item=>{let idx=items$2.findIndex(itm=>itm.id===item.id);idx>-1&&items$2.splice(idx,1)}),(_ctx,_cache)=>withDirectives((openBlock(),createElementBlock(`div`,_hoisted_1$347,[renderSlot(_ctx.$slots,`default`,{},void 0,!0)])),[[unref(BngDisabled_default),__props.disabled]])}},accordion_default=__plugin_vue_export_helper_default(_sfc_main$403,[[`__scopeId`,`data-v-fcd1832d`]]),_hoisted_1$346={key:0,class:`bng-accitem-content`},_sfc_main$402={__name:`accordionItem`,props:{static:Boolean,expanded:Boolean,disabled:Boolean,animated:Boolean,selectable:{type:[Boolean,Object],default:!1},selected:Boolean,data:{},navigable:{type:[Boolean,Object],default:!1},arrowBig:Boolean,primaryAction:Function,secondaryAction:Function,primaryLabel:String,secondaryLabel:String,primaryHintInline:Boolean,secondaryHintInline:Boolean,expandHintInline:Boolean},emits:[`focus`,`unfocus`,`expanded`,`selected`],setup(__props,{expose:__expose,emit:__emit}){let{showIfController}=storeToRefs(controls_default()),navBlocker=useUINavBlocker(),props=__props,elCaption=ref(),elCaptionContent=ref(),elCaptionControls=ref(),hasFocus=ref(!1),icon=computed(()=>props.arrowBig?icons.arrowLargeRight:icons.arrowSmallRight),popTip=ref();watch([()=>hasFocus.value,()=>showIfController.value],()=>{hasFocus.value&&showIfController.value&&(props.primaryHintInline&&props.primaryAction||props.secondaryHintInline&&props.secondaryAction)?popTip.value.show(elCaption.value):popTip.value.isShown()&&popTip.value.hide()});let reg$1=inject(`accordion-item-register`),unreg=inject(`accordion-item-unregister`),toggle=inject(`accordion-item-toggle`),select=inject(`accordion-item-select`),opts=reactive({id:-1,captionClick:evt=>{props.primaryAction&&evt.fromController?props.primaryAction():opts.selectable?select(opts):opts.expandClick()},expandClick:()=>!props.static&&toggle(opts),static:props.static,expandedActual:props.expanded,disabled:props.disabled,animated:props.animated,selected:props.selected,selectable:props.selectable,navigable:{enabled:!1},data:props.data}),emit$1=__emit;__expose({captionClick:opts.captionClick,focus:()=>setFocusExternal(elCaption.value,!0,!1),captionElement:computed(()=>elCaption.value)}),watch(()=>props.static,val=>opts.static=val),watch(()=>props.expanded,val=>!opts.static&&toggle(opts,val)),watch(()=>props.disabled,val=>opts.disabled=val),watch(()=>opts.disabled,val=>!val&&props.disabled&&(opts.disabled=props.disabled)),watch(()=>props.animated,val=>opts.animated=val),watch(()=>props.selectable,val=>opts.selectable=val),watch(()=>props.selected,val=>opts.selected=val),watch(()=>opts.expandedActual,val=>{emit$1(`expanded`,!opts.static&&!opts.disabled&&val)}),watch(()=>props.data,val=>opts.data=val),watch(()=>props.navigable,val=>{if(typeof val!=`object`&&typeof val==`boolean`&&!val){opts.navigable={enabled:!1};return}opts.navigable={enabled:!0,scope:null,...typeof val==`object`?val:{}}},{immediate:!0}),opts.navigable.scope&&useUINavScope(opts.navigable.scope);let onFocus=evt=>{hasFocus.value=!0,navBlocker.blockOnly(opts.static?[`context`]:[]),emit$1(`focus`,evt)},onLoseFocus=evt=>{hasFocus.value=!1,navBlocker.clear(),emit$1(`unfocus`,evt)};return provide(`accordion-item-childSelect`,select$1=>(item,value)=>opts.selectable&&opts.selectable.multi&&select$1(item,value)),provide(`accordion-item-parent`,opts),onMounted(()=>reg$1(opts)),onBeforeUnmount(()=>{popTip.value.isShown()&&popTip.value.hide(),unreg(opts)}),(_ctx,_cache)=>withDirectives((openBlock(),createElementBlock(`div`,{class:normalizeClass({"bng-accitem":!0,"bng-accitem-normal":!opts.static&&!opts.selectable,"bng-accitem-static":opts.static,"bng-accitem-expandable":!opts.static,"bng-accitem-selectable":opts.selectable,"bng-accitem-expanded":!opts.static&&opts.expandedActual&&!opts.disabled,"bng-accitem-selected":opts.selected})},[withDirectives((openBlock(),createElementBlock(`div`,mergeProps({ref_key:`elCaption`,ref:elCaption,class:`bng-accitem-caption`,onClick:_cache[1]||=(...args)=>opts.captionClick&&opts.captionClick(...args),onFocus,onBlur:onLoseFocus},{"bng-nav-item":opts.navigable.enabled?!0:void 0,"bng-ui-scope":opts.navigable.scope||void 0}),[opts.static?createCommentVNode(``,!0):(openBlock(),createBlock(unref(bngIcon_default),{key:0,class:normalizeClass({"bng-accitem-caption-expander":!0,"bng-accitem-caption-expander-big":__props.arrowBig}),type:icon.value,onClick:withModifiers(opts.expandClick,[`stop`])},null,8,[`class`,`type`,`onClick`])),__props.expandHintInline&&!opts.static&&hasFocus.value&&unref(showIfController)?(openBlock(),createBlock(unref(bngBinding_default),{key:1,style:{"padding-right":`0.2em`},uiEvent:`context`,controller:``})):createCommentVNode(``,!0),createBaseVNode(`span`,{ref_key:`elCaptionContent`,ref:elCaptionContent,class:`bng-accitem-caption-content`},[renderSlot(_ctx.$slots,`caption`,{},()=>[_cache[2]||=createTextVNode(`Unnamed item`,-1)],!0)],512),_ctx.$slots.controls?(openBlock(),createElementBlock(`div`,{key:2,ref_key:`elCaptionControls`,ref:elCaptionControls,class:`bng-accitem-caption-controls`,onClick:_cache[0]||=withModifiers(()=>{},[`stop`])},[renderSlot(_ctx.$slots,`controls`,{},void 0,!0)],512)):createCommentVNode(``,!0),createVNode(unref(bngPopoverContent_default),{ref_key:`popTip`,ref:popTip,placement:`right`},{default:withCtx(()=>[__props.primaryHintInline&&__props.primaryAction?(openBlock(),createBlock(unref(bngBinding_default),{key:0,uiEvent:`ok`,controller:``})):createCommentVNode(``,!0),__props.secondaryHintInline&&__props.secondaryAction?(openBlock(),createBlock(unref(bngBinding_default),{key:1,uiEvent:`action_2`,controller:``})):createCommentVNode(``,!0)]),_:1},512)],16)),[[unref(BngOnUiNav_default),void 0,`ok`,{asMouse:!0,focusRequired:!0}],[unref(BngOnUiNav_default),__props.secondaryAction?__props.secondaryAction:void 0,`action_2`,{focusRequired:!0}],[unref(BngOnUiNav_default),!opts.static&&opts.navigable.enabled?opts.expandClick:void 0,`context`,{focusRequired:!0}],[unref(BngUiNavLabel_default),__props.primaryLabel||`ui.inputActions.menu.menu_item_select.title`,`ok`],[unref(BngUiNavLabel_default),__props.secondaryLabel,`action_2`],[unref(BngUiNavLabel_default),_ctx.$tt(`ui.common.expand`)+`/`+_ctx.$tt(`ui.common.collapse`),`context`]]),createVNode(Transition,{name:opts.animated?`bng-acc-trans`:null},{default:withCtx(()=>[!opts.static&&opts.expandedActual&&!opts.disabled?(openBlock(),createElementBlock(`div`,_hoisted_1$346,[renderSlot(_ctx.$slots,`default`,{},()=>[_cache[3]||=createTextVNode(`Empty`,-1)],!0)])):createCommentVNode(``,!0)]),_:3},8,[`name`])],2)),[[unref(BngDisabled_default),opts.disabled]])}},accordionItem_default=__plugin_vue_export_helper_default(_sfc_main$402,[[`__scopeId`,`data-v-dd6087ee`]]),_sfc_main$401={__name:`accordionTree`,props:{data:[Array,Object],dataField:{type:String,required:!0},propsField:String,contentField:String,selectable:{type:[Boolean,Object],default:!1},selectedField:String,isTreeElement:Boolean},emits:[`selected`],setup(__props,{emit:__emit}){let props=__props,dataView=computed(()=>props.data&&(props.data[props.dataField]||props.data)||[]),emit$1=__emit;props.isTreeElement||(watch(()=>dataView.value,refreshSelected),watch(()=>props.selectedField&&props.selectable&&props.selectable.multi,refreshSelected),refreshSelected());let prevState=[];function refreshSelected(){if(!props.selectedField||!props.selectable||!props.selectable.multi)return;let state=[];function deepScan(arr){for(let itm of arr){let data=itm.data||itm;data[props.selectedField]&&state.push({data,selected:!0}),data[props.dataField]&&deepScan(data[props.dataField])}}deepScan(dataView.value),selected(state)}function selected(state){if(!props.isTreeElement){if(!props.selectable.multi){prevState=prevState.filter(itm=>itm.selected);for(let itm of prevState)itm.selected&&(itm.item.selected=!1,props.selectedField&&(itm.item.data[props.selectedField]=!1),state.includes(itm.item)||state.push(itm.item));prevState=state.map(item=>({selected:!!item.selected,item}))}if(props.selectedField){function deepSet(arr,value=void 0){for(let itm of arr){let val=typeof value==`boolean`?value:itm.selected,data=itm.data||itm;data[props.selectedField]=val,data[props.dataField]&&deepSet(data[props.dataField])}}deepSet(state)}}emit$1(`selected`,state)}function branchSelected(state){props.isTreeElement?emit$1(`selected`,state):selected(state)}return(_ctx,_cache)=>dataView.value.length>0?(openBlock(),createBlock(unref(accordion_default),{key:0,class:`acctree`,selectable:__props.selectable,"provide-parent":__props.isTreeElement,onSelected:selected},{default:withCtx(()=>[(openBlock(!0),createElementBlock(Fragment,null,renderList(dataView.value,entry=>(openBlock(),createBlock(unref(accordionItem_default),mergeProps({ref_for:!0},__props.propsField?entry[__props.propsField]:void 0,{selected:__props.selectedField?entry[__props.selectedField]:void 0,static:(!entry[__props.dataField]||entry[__props.dataField].length===0)&&(!__props.contentField||!entry[__props.contentField]),data:entry}),{caption:withCtx(()=>[renderSlot(_ctx.$slots,`caption`,{entry},void 0,!0)]),controls:withCtx(()=>[renderSlot(_ctx.$slots,`controls`,{entry},void 0,!0)]),default:withCtx(()=>[__props.contentField&&entry[__props.contentField]?renderSlot(_ctx.$slots,`default`,{key:0,entry},void 0,!0):createCommentVNode(``,!0),entry[__props.dataField]&&entry[__props.dataField].length>0?(openBlock(),createBlock(unref(accordionTree_default),mergeProps({key:1,ref_for:!0},props,{data:entry,"is-tree-element":!0,onSelected:branchSelected}),{caption:withCtx(({entry:entry$1})=>[renderSlot(_ctx.$slots,`caption`,{entry:entry$1},void 0,!0)]),controls:withCtx(({entry:entry$1})=>[renderSlot(_ctx.$slots,`controls`,{entry:entry$1},void 0,!0)]),_:2},1040,[`data`])):createCommentVNode(``,!0)]),_:2},1040,[`selected`,`static`,`data`]))),256))]),_:3},8,[`selectable`,`provide-parent`])):createCommentVNode(``,!0)}},accordionTree_default=__plugin_vue_export_helper_default(_sfc_main$401,[[`__scopeId`,`data-v-2ad1085d`]]),_hoisted_1$345={class:`slotted`},_sfc_main$400={__name:`aspectRatio`,props:{ratio:{type:String,default:`16:9`},imageMode:{type:String,default:`cover`,validator:value=>[`cover`,`contain`].includes(value)},image:{type:String,default:null},externalImage:{type:String,default:null}},setup(__props){useCssVars(_ctx=>({v711986eb:__props.imageMode}));let placeholderImageURL=getAssetURL(`images/noimage.png`),slots=useSlots(),props=__props,padding=computed(()=>{if(!props.ratio)return`56.25%`;let[width$1,height$1]=props.ratio.split(`:`).map(Number);return`${height$1/width$1*100}%`}),backgroundStyle=computed(()=>!props.image&&!props.externalImage?{"--padding":padding.value,backgroundImage:`none`}:props.image||props.externalImage?{"--padding":padding.value,backgroundImage:`url("${props.externalImage?props.externalImage:getAssetURL(props.image)}")`}:slots.default?{"--padding":padding.value,backgroundImage:`url("${placeholderImageURL}")`}:{});return(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,{class:`aspect-ratio`,style:normalizeStyle(backgroundStyle.value)},[createBaseVNode(`div`,_hoisted_1$345,[renderSlot(_ctx.$slots,`default`,{},void 0,!0)])],4))}},aspectRatio_default=__plugin_vue_export_helper_default(_sfc_main$400,[[`__scopeId`,`data-v-83698898`]]),_hoisted_1$344=[`data-carousel-item`],_sfc_main$399={__name:`carouselItem`,props:{value:{type:[String,Number],required:!0}},setup(__props){return(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,{class:`bng-carousel-item`,"data-carousel-item":__props.value},[renderSlot(_ctx.$slots,`default`,{},void 0,!0)],8,_hoisted_1$344))}},carouselItem_default=__plugin_vue_export_helper_default(_sfc_main$399,[[`__scopeId`,`data-v-babc74fb`]]),_hoisted_1$343={key:0,class:`navigation`},_hoisted_2$271=[`onClick`],TRANSITION_TYPES=[`fade`],_sfc_main$398={__name:`carousel`,props:{items:{type:Array,required:!0},current:{type:[String,Number],default:0},vertical:Boolean,loop:{type:Boolean,default:!0},transition:Boolean,transitionType:{type:String,default:`fade`,validator:value=>TRANSITION_TYPES.includes(value)},transitionTime:{type:Number,default:3e3},showNav:{type:Boolean,default:!0},parent:Object},setup(__props,{expose:__expose}){let props=__props,transitionTimer,carouselRoot=ref(null),carousel=ref(null),currentIndex=ref(props.current);computed(()=>``);let navState=reactive({selected:null}),showSlide=value=>{let slideIndex=parseInt(value);currentIndex.value=slideIndex,navState.selected=slideIndex,setTransition()},navShown=computed(()=>props.showNav&&!props.parent),children=[],childIndex=child=>children.findIndex(itm=>itm.element===child.element),addChild=child=>{childIndex(child)===-1&&children.push(child)},remChild=child=>{let idx=childIndex(child);idx>-1&&children.splice(idx,1)},tryParent=(_retry=0)=>{if(props.parent.addChild)props.parent.addChild(exposed);else if(_retry<100){let unwatch=watch(()=>props.parent.addChild,()=>{unwatch(),tryParent(++_retry)})}};watch(()=>props.parent,tryParent),watch(()=>navState.selected,sel=>{for(let child of children)child.showSlide&&child.showSlide(sel)}),onMounted(()=>{setTransition(),props.parent&&tryParent()}),onBeforeUnmount(()=>{transitionTimer&&=(clearInterval(transitionTimer),null),props.parent&&props.parent.remChild&&props.parent.remChild(exposed)});function showPrevious(){if(props.parent)return;let prev;currentIndex.value===0&&props.loop?prev=props.items.length-1:currentIndex.value>0&&(prev=currentIndex.value-1),prev!==void 0&&(navState.selected=prev,currentIndex.value=prev,setTransition())}function showNext(){if(props.parent)return;let next=getNext();next>-1&&(navState.selected=next,currentIndex.value=next,setTransition())}function setTransition(){transitionTimer&&clearInterval(transitionTimer),transitionTimer=setInterval(()=>{let next=getNext();next>-1&&(currentIndex.value=next)},props.transitionTime)}function getNext(){return currentIndex.value===props.items.length-1&&props.loop?0:currentIndex.value(openBlock(),createElementBlock(`div`,{ref_key:`carouselRoot`,ref:carouselRoot,class:normalizeClass({"bng-carousel":!0,"carousel-vertical":__props.vertical,[`transition-${__props.transitionType}`]:!0})},[createBaseVNode(`div`,{ref_key:`carousel`,ref:carousel,class:`carousel-content`},[createVNode(Transition,{name:__props.transitionType},{default:withCtx(()=>[(openBlock(),createBlock(carouselItem_default,{key:currentIndex.value,class:`carousel-slide`,value:currentIndex.value},{default:withCtx(()=>[renderSlot(_ctx.$slots,`item`,{item:__props.items[currentIndex.value],index:currentIndex.value},()=>[createTextVNode(toDisplayString(__props.items[currentIndex.value]),1)],!0)]),_:3},8,[`value`]))]),_:3},8,[`name`])],512),renderSlot(_ctx.$slots,`navigation`,{},()=>[navShown.value&&__props.items&&__props.items.length>1?(openBlock(),createElementBlock(`div`,_hoisted_1$343,[(openBlock(!0),createElementBlock(Fragment,null,renderList(__props.items,(item,index)=>(openBlock(),createElementBlock(`div`,{class:normalizeClass([`navigation-item`,{active:index===currentIndex.value}]),key:item.value,onClick:$event=>showSlide(index)},null,10,_hoisted_2$271))),128))])):createCommentVNode(``,!0)],!0)],2))}},carousel_default=__plugin_vue_export_helper_default(_sfc_main$398,[[`__scopeId`,`data-v-f54192e0`]]),_hoisted_1$342={key:0,class:`drawer-header`},_hoisted_2$270={key:1,class:`drawer-content`},_hoisted_3$236={key:2,class:`drawer-header`};const DRAWER_POSITION={bottom:`bottom`,top:`top`,left:`left`,right:`right`};var _sfc_main$397={__name:`drawer`,props:mergeModels({blur:Boolean,position:{type:String,default:DRAWER_POSITION.bottom,validator:val=>Object.values(DRAWER_POSITION).includes(val)}},{modelValue:{type:Boolean},modelModifiers:{}}),emits:mergeModels([`change`],[`update:modelValue`]),setup(__props,{emit:__emit}){let emit$1=__emit,expanded=useModel(__props,`modelValue`);watch(()=>expanded.value,val=>emit$1(`change`,val));let slots=useSlots(),expandedContent=computed(()=>expanded.value&&`expanded-content`in slots),hasAnyContent=computed(()=>expandedContent.value||`content`in slots);return(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,{class:normalizeClass({"bng-drawer":!0,[`drawer-pos-${__props.position}`]:!0,"drawer-expanded":expanded.value})},[__props.position===`bottom`||__props.position===`right`?withDirectives((openBlock(),createElementBlock(`div`,_hoisted_1$342,[renderSlot(_ctx.$slots,`header`,{},void 0,!0)])),[[unref(BngBlur_default),__props.blur]]):createCommentVNode(``,!0),hasAnyContent.value?withDirectives((openBlock(),createElementBlock(`div`,_hoisted_2$270,[expandedContent.value?renderSlot(_ctx.$slots,`expanded-content`,{key:0},void 0,!0):renderSlot(_ctx.$slots,`content`,{key:1},void 0,!0)])),[[unref(BngBlur_default),__props.blur]]):createCommentVNode(``,!0),__props.position===`top`||__props.position===`left`?withDirectives((openBlock(),createElementBlock(`div`,_hoisted_3$236,[renderSlot(_ctx.$slots,`header`,{},void 0,!0)])),[[unref(BngBlur_default),__props.blur]]):createCommentVNode(``,!0)],2))}},drawer_default=__plugin_vue_export_helper_default(_sfc_main$397,[[`__scopeId`,`data-v-8023232b`]]),_sfc_main$396={__name:`dynamicComponent`,props:{template:String,translateId:String,translateContext:Boolean,bbcode:Boolean,useComponents:{type:Boolean,default:!0},extraComponents:{type:Object,default:()=>({})}},setup(__props){let ALL_COMPONENTS=Object.fromEntries(Object.entries({...base_exports,...utility_exports}).filter(([name])=>name!==`DEMOS`)),attrs=useAttrs(),props=__props,template=computed(()=>{let res=props.template;return props.translateId&&(res=props.translateContext?$translate.contextTranslate(props.translateId,!0):$translate.instant(props.translateId)),res&&props.bbcode&&(res=parse$1(res)),res||``}),makeComponent=computed(()=>defineComponent({template:template.value,components:{...props.useComponents&&ALL_COMPONENTS,...props.extraComponents},data(){return attrs}}));return(_ctx,_cache)=>template.value&&makeComponent.value?(openBlock(),createBlock(resolveDynamicComponent(makeComponent.value),{key:0})):createCommentVNode(``,!0)}},dynamicComponent_default=_sfc_main$396,_hoisted_1$341={class:`shelf-wrapper`},_hoisted_2$269=[`disabled`],_hoisted_3$235=[`disabled`],storageKey=`bngshelf`,_sfc_main$395={__name:`shelf`,props:mergeModels({saveName:{type:String,default:null},limit:{type:Number,default:5,validator:val=>val>2&&val%2==1},fade:{type:Boolean,default:!1},showExtra:{type:Boolean,default:!0},neighborsFlatten:{type:Boolean,default:!1},neighborsScale:{type:Number,default:1},keepNeighborsAspectRatio:{type:Boolean,default:!1},noLoop:{type:Boolean,default:!1},navShown:{type:Boolean,default:!1},inward:{type:Number,default:0,validator:val=>val>=0&&val<=1}},{modelValue:{type:Number,default:0},modelModifiers:{}}),emits:mergeModels([`change`,`click`],[`update:modelValue`]),setup(__props,{expose:__expose,emit:__emit}){let selectedIndex=useModel(__props,`modelValue`),props=__props,emit$1=__emit,ready=ref(!1),slots=useSlots(),containerRef=ref(null),shelfItems=ref([]),displayItems=ref([]),isAnimating=ref(!1),itemIdCounter=0,lastValidIndex=0,isReverting=!1,isPrevDisabled=computed(()=>isAnimating.value||props.noLoop&&selectedIndex.value===0),isNextDisabled=computed(()=>isAnimating.value||props.noLoop&&selectedIndex.value===shelfItems.value.length-1);watch(selectedIndex,index=>{if(!isReverting){if(index=parseInt(index,10),isNaN(index)||index<0||shelfItems.value.length>0&&index>=shelfItems.value.length){isReverting=!0,selectedIndex.value=lastValidIndex,isReverting=!1;return}lastValidIndex=index,ready.value&&buildDisplayItems()}},{immediate:!0});let timings={single:400,multiStart:200,multiMiddle:200,multiEnd:200};watch(()=>slots.default?.(),update$6,{immediate:!0});function update$6(vnodes){if(ready.value){if(vnodes===void 0&&(vnodes=slots.default?.()),Array.isArray(vnodes)||(vnodes=[]),shelfItems.value=vnodes.reduce((res,vnode)=>typeof vnode.type==`symbol`&&vnode.type.toString()===`Symbol(v-fgt)`?(res.push(...vnode.children),res):(res.push(vnode),res),[]),props.saveName){let val=localStorage.getItem(`${storageKey}-${props.saveName}`);if(val!==null){let idx=parseInt(val,10);!isNaN(idx)&&idx>=0&&idxhalfLimit)continue;let itemIndex=selectedIndex.value+offset$2;if(props.noLoop){if(itemIndex<0||itemIndex>=shelfItems.value.length)continue}else itemIndex<0?itemIndex=shelfItems.value.length+itemIndex:itemIndex>=shelfItems.value.length&&(itemIndex-=shelfItems.value.length);items$2.push({vnode:shelfItems.value[itemIndex],originalIndex:itemIndex,position:offset$2,id:++itemIdCounter,style:getItemStyle(offset$2,`normal`)})}displayItems.value=items$2}function getItemStyle(position,state=`normal`){let absPosition=Math.abs(position),halfLimit=~~(props.limit/2),isExtraItem=absPosition>halfLimit,factor=halfLimit>0?absPosition/halfLimit:1,leftPercentage;if(leftPercentage=isExtraItem?(position<0?0:props.limit-1)/(props.limit-1)*100:(position+halfLimit)/(props.limit-1)*100,position!==0&&props.inward>0){let pullToCenter=(50-leftPercentage)*props.inward*factor;leftPercentage+=pullToCenter}let rotateY=factor*-30*Math.sign(position),translateZ=0,scaleX=1,scaleY=1,brightness=1;if(position!==0){if(translateZ=-100*factor,props.keepNeighborsAspectRatio){let scale=Math.max(.6,1-factor*.4)*props.neighborsScale;scaleX=scale,scaleY=scale}else scaleX=Math.max(.4,1-factor*.6)*props.neighborsScale,scaleY=Math.max(.6,1-factor*.4)*props.neighborsScale;brightness=Math.max(.5,1-factor*.5),props.neighborsFlatten&&(rotateY=0)}let opacity=1;return state===`entering`||state===`exiting`?(opacity=.1,translateZ=-100*(absPosition/halfLimit),leftPercentage+=2*Math.sign(position)):isExtraItem?opacity=.2:props.fade&&position!==0&&(opacity=Math.max(.4,1-absPosition*.3)),{left:`${leftPercentage}%`,transform:`translateX(-50%) translateY(-50%) translateZ(${translateZ}px) rotateY(${rotateY}deg) scale(${scaleX}, ${scaleY})`,filter:`brightness(${brightness})`,transition:`all 400ms cubic-bezier(0.25, 0.8, 0.25, 1)`,opacity,zIndex:isExtraItem?10-absPosition:100-absPosition}}let abortAnimation=!1;async function toIndex(targetIndex){if(!ready.value||selectedIndex.value===targetIndex||typeof targetIndex!=`number`||targetIndex<0||targetIndex>=shelfItems.value.length)return;if(isAnimating.value)for(abortAnimation=!0;abortAnimation;)await sleep(20);let prevIndex=selectedIndex.value,steps=calculateSteps(selectedIndex.value,targetIndex);if(steps.length!==0){isAnimating.value=!0;try{let stepTimings=calculateStepTimings(steps.length);for(let i=0;i{selectedIndex.value===targetIndex&&setFocusExternal(containerRef.value.querySelector(`[data-shelf-index="${targetIndex}"]`))})}finally{abortAnimation=!1,isAnimating.value=!1}props.saveName&&localStorage.setItem(`${storageKey}-${props.saveName}`,targetIndex.toString()),emit$1(`change`,targetIndex,prevIndex)}}let onFocus=index=>selectedIndex.value!==index&&toIndex(index);function onClick(index,event){selectedIndex.value===index?emit$1(`click`,event,index):toIndex(index)}function calculateStepTimings(stepCount){return stepCount===1?[timings.single]:Array.from({length:stepCount},(_,i)=>i===0?timings.multiStart:i===stepCount-1?timings.multiEnd:timings.multiMiddle)}function calculateSteps(fromIndex,toIndex$1){let targetItemIndex=displayItems.value.findIndex(item=>item.originalIndex===toIndex$1),steps=[];if(targetItemIndex===-1){let current=fromIndex;for(;current!==toIndex$1;){let totalItems=shelfItems.value.length;props.noLoop?toIndex$1>current?current+=1:--current:current=(toIndex$1-current+totalItems)%totalItems<=(current-toIndex$1+totalItems)%totalItems?(current+1)%totalItems:(current-1+totalItems)%totalItems,steps.push(current)}}else{let targetPosition=displayItems.value[targetItemIndex].position;if(targetPosition!==0){let direction$1=targetPosition>0?1:-1,stepsNeeded=Math.abs(targetPosition),current=fromIndex;for(let i=0;i0?current+=1:--current:current=direction$1>0?(current+1)%shelfItems.value.length:(current-1+shelfItems.value.length)%shelfItems.value.length,steps.push(current)}}return steps}async function animateToStep(stepIndex,stepTiming){let halfLimit=Math.floor(props.limit/2),currentIndex=selectedIndex.value,actualDirection=0;if(props.noLoop)actualDirection=stepIndex>currentIndex?1:-1;else{let totalItems=shelfItems.value.length;actualDirection=(stepIndex-currentIndex+totalItems)%totalItems<=(currentIndex-stepIndex+totalItems)%totalItems?1:-1}let newItems=[];if(actualDirection>0){for(let i=0;i=shelfItems.value.length?rightmostIndex-shelfItems.value.length:rightmostIndex),wrappedIndex>=0&&wrappedIndex=0&&wrappedIndexhalfLimit;newItems.push({...currentItem,position:newPosition,style:getItemStyle(newPosition,isExiting?`exiting`:`normal`)})}}displayItems.value=newItems;let delay=stepTiming/2;await sleep(delay),displayItems.value=displayItems.value.map(item=>item.style.opacity===.1&&(item.position===halfLimit||item.position===-halfLimit)?{...item,style:getItemStyle(item.position,`normal`)}:item),await new Promise(resolve$1=>setTimeout(resolve$1,delay))}function navigateNext$1(){isAnimating.value||props.noLoop&&selectedIndex.value===shelfItems.value.length-1||toIndex((selectedIndex.value+1)%shelfItems.value.length)}function navigatePrev(){isAnimating.value||props.noLoop&&selectedIndex.value===0||toIndex(selectedIndex.value===0?shelfItems.value.length-1:selectedIndex.value-1)}__expose({toIndex,next:navigateNext$1,prev:navigatePrev,isSelected:evt=>{let elm=evt.target.closest(`[data-shelf-index]`);if(!elm)return!1;let idx=parseInt(elm.getAttribute(`data-shelf-index`),10);return!isNaN(idx)&&selectedIndex.value===idx}}),onMounted(()=>{ready.value=!0,nextTick(update$6)});function getActiveItem(){let active=document.activeElement;return String(active.dataset.shelfIndex)===String(selectedIndex.value)?null:containerRef.value.querySelector(`[data-shelf-index="${selectedIndex.value}"]`)}return(_ctx,_cache)=>withDirectives((openBlock(),createElementBlock(`div`,_hoisted_1$341,[withDirectives((openBlock(),createElementBlock(`div`,{ref_key:`containerRef`,ref:containerRef,class:`shelf-container`},[(openBlock(!0),createElementBlock(Fragment,null,renderList(displayItems.value,item=>(openBlock(),createElementBlock(`div`,{key:`item-${item.originalIndex}-${item.id}`,class:`shelf-item`,style:normalizeStyle(item.style)},[(openBlock(),createBlock(resolveDynamicComponent(item.vnode),{"data-shelf-index":item.originalIndex,onClick:$event=>onClick(item.originalIndex,$event),onFocus:$event=>onFocus(item.originalIndex),onUinavFocus:$event=>onFocus(item.originalIndex)},null,40,[`data-shelf-index`,`onClick`,`onFocus`,`onUinavFocus`]))],4))),128))])),[[unref(BngFocusCapture_default),getActiveItem,`101`]]),__props.navShown?(openBlock(),createElementBlock(`button`,{key:0,class:`shelf-nav shelf-nav-prev`,onClick:navigatePrev,disabled:isPrevDisabled.value},[createVNode(unref(bngIcon_default),{type:unref(icons).arrowLargeLeft},null,8,[`type`])],8,_hoisted_2$269)):createCommentVNode(``,!0),__props.navShown?(openBlock(),createElementBlock(`button`,{key:1,class:`shelf-nav shelf-nav-next`,onClick:navigateNext$1,disabled:isNextDisabled.value},[createVNode(unref(bngIcon_default),{type:unref(icons).arrowLargeRight},null,8,[`type`])],8,_hoisted_3$235)):createCommentVNode(``,!0)],512)),[[vShow,displayItems.value.length>0]])}},shelf_default=__plugin_vue_export_helper_default(_sfc_main$395,[[`__scopeId`,`data-v-0109573f`]]),_sfc_main$394={__name:`slotSwitcher`,props:{slotId:{type:String,default:`default`}},setup(__props){return(_ctx,_cache)=>renderSlot(_ctx.$slots,__props.slotId,normalizeProps(guardReactiveProps(_ctx.$attrs)))}},slotSwitcher_default=_sfc_main$394,_sfc_main$393={__name:`tab`,props:{heading:String,selected:Boolean},setup(__props){return(_ctx,_cache)=>renderSlot(_ctx.$slots,`default`,{tabHeading:__props.heading,tabSelected:__props.selected})}},tab_default=_sfc_main$393,_hoisted_1$340={class:`tab-list`},_sfc_main$392={__name:`tabList`,setup(__props){let tabs=inject(`tabs`),selectTab=inject(`selectTab`),tabHeaderClasses=tab=>({"tab-item":!0,"tab-active-tab":tab.active,"no-hover":tab.active});function handleTabSelect(index,event){let buttonElement=event.currentTarget,hasFocusVisible=document.activeElement&&document.activeElement.classList.contains(`focus-visible`);selectTab(index),hasFocusVisible&&nextTick(()=>{setFocusExternal(buttonElement)})}return(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$340,[(openBlock(!0),createElementBlock(Fragment,null,renderList(unref(tabs),(tab,i)=>(openBlock(),createBlock(unref(bngButton_default),{key:i,accent:(tab.active,`ghost`),class:normalizeClass(tabHeaderClasses(tab)),tabindex:`0`,"bng-nav-item":``,onClick:$event=>handleTabSelect(tab.index,$event)},{default:withCtx(()=>[createTextVNode(toDisplayString(tab.heading),1)]),_:2},1032,[`accent`,`class`,`onClick`]))),128))]))}},tabList_default=__plugin_vue_export_helper_default(_sfc_main$392,[[`__scopeId`,`data-v-5c322d77`]]),_hoisted_1$339={class:`tab-container`},_sfc_main$391={__name:`tabs`,props:{selectedIndex:{type:Number,default:-1}},emits:[`change`],setup(__props,{expose:__expose,emit:__emit}){let emit$1=__emit,props=__props,ready=ref(!1),slots=useSlots(),tabListStart=shallowRef(),tabListEnd=shallowRef(),tabsList=ref(),tabsContent=ref([]),selectedIndex=ref(-1),isTabList=vnode=>typeof vnode.type==`object`&&vnode.type.__name===tabList_default.__name;provide(`tabs`,tabsList),watch(()=>slots.default?.(),update$6,{immediate:!0}),watch(()=>props.selectedIndex,index=>selectTab(index));function update$6(vnodes){if(!ready.value)return;vnodes===void 0&&(vnodes=slots.default?.()),Array.isArray(vnodes)||(vnodes=[]);let tabListIndex=vnodes.findIndex(vn=>isTabList(vn));tabListStart.value=tabListIndex===0?vnodes[tabListIndex]:tabList_default,tabListEnd.value=tabListIndex===vnodes.length-1?vnodes[tabListIndex]:null,tabsContent.value=vnodes.filter(vn=>!isTabList(vn)).reduce((res,vnode)=>typeof vnode.type==`symbol`&&vnode.type.toString()===`Symbol(v-fgt)`?(res.push(...vnode.children),res):(res.push(vnode),res),[]),tabsList.value=tabsContent.value.map((tab,index)=>({index,heading:tab.props?.[`tab-heading`]||tab.props?.tabHeading||`Tab ${index+1}`,active:selectedIndex.value===-1?props.selectedIndex===index||!!tab.props?.[`tab-selected`]||!!tab.props?.tabSelected:selectedIndex.value===index}));let activeIndex=tabsList.value.findIndex(tab=>tab.active);selectTab(activeIndex>-1?activeIndex:0)}function selectTab(index){if(!ready.value||typeof index!=`number`||index<0||index>=tabsList.value.length||selectedIndex.value===index)return;let prevTab=tabsList.value[selectedIndex.value];tabsList.value.forEach(tab=>{tab.active=tab.index===index}),selectedIndex.value=index,emit$1(`change`,tabsList.value[index],prevTab)}return provide(`selectTab`,selectTab),__expose({goNext:()=>selectTab((selectedIndex.value+1)%tabsList.value.length),goPrev:()=>selectTab(Math.abs(selectedIndex.value-1)%tabsList.value.length),selectTab}),onMounted(()=>{ready.value=!0,nextTick(update$6)}),(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$339,[tabListStart.value?(openBlock(),createBlock(resolveDynamicComponent(tabListStart.value),{key:0})):createCommentVNode(``,!0),tabsContent.value[selectedIndex.value]?(openBlock(),createBlock(resolveDynamicComponent(tabsContent.value[selectedIndex.value]),{key:1,class:`tab-content`})):createCommentVNode(``,!0),tabListEnd.value?(openBlock(),createBlock(resolveDynamicComponent(tabListEnd.value),{key:2})):createCommentVNode(``,!0)]))}},tabs_default=__plugin_vue_export_helper_default(_sfc_main$391,[[`__scopeId`,`data-v-2ff63a4f`]]),_sfc_main$390={__name:`textScroller`,props:{scrollSpeed:{type:Number,default:3},initialPause:{type:Number,default:1},endingPause:{type:Number,default:1},fadeDuration:{type:Number,default:.2},watchContent:{type:Boolean,default:!1}},setup(__props){let props=__props,slots=useSlots(),events$3={start:[`uinav-focus`,`focus`,`mouseenter`],stop:[`uinav-blur`,`blur`,`mouseleave`]},elContainer=ref(null),elText=ref(null),scrollDistance=ref(0),translateX=ref(0),opacity=ref(1),isActive=ref(!1),isScrolling$1=ref(!1),styleOverrides={"button-icon":`.bng-button.l-icon, .bng-button.r-icon`},overrideClasses=ref([]),parentElement=null,fontSize=ref(16),scrollSpeed=computed(()=>props.scrollSpeed*fontSize.value),animTimer=null,animTimeout=(func,ms)=>(animTimer&&=(clearTimeout(animTimer),null),typeof func==`function`?(animTimer=setTimeout(()=>{animTimer=null,isScrolling$1.value&&func()},ms),animTimer):null),scrollStyles=computed(()=>({transform:`translateX(${translateX.value}px)`,opacity:opacity.value,transition:`opacity ${props.fadeDuration}s linear`+(isScrolling$1.value&&opacity.value>0?`, transform ${scrollDistance.value/scrollSpeed.value}s linear`:``)}));function animLoop(){isScrollable()&&(scrollDistance.value=getSize(),!(scrollDistance.value<=0)&&(opacity.value=1,animTimeout(()=>{translateX.value=-scrollDistance.value,animTimeout(()=>{opacity.value=0,animTimeout(()=>{translateX.value=0,nextTick(animLoop)},props.fadeDuration*1e3)},scrollDistance.value/scrollSpeed.value*1e3+props.endingPause*1e3)},Math.max(props.initialPause,props.fadeDuration)*1e3)))}function isScrollable(){if(!elContainer.value||!elText.value)return!1;let containerWidth=elContainer.value.clientWidth;return elText.value.scrollWidth>containerWidth}function getSize(){if(!elContainer.value||!elText.value)return 0;let containerWidth=elContainer.value.clientWidth,textWidth=elText.value.scrollWidth;return Math.max(0,textWidth-containerWidth)}function animStart(){isActive.value=!0,isScrollable()&&(isScrolling$1.value=!0,translateX.value=0,opacity.value=1,animLoop())}function animStop(restartAnim=!1){isActive.value=!1,isScrolling$1.value=!1,animTimeout(),nextTick(()=>{translateX.value=0,opacity.value=1,typeof restartAnim==`boolean`&&restartAnim&&nextTick(animStart)})}return props.watchContent&&watch(()=>slots.default?.(),()=>animStop(isActive.value),{deep:!0}),watch([()=>scrollSpeed.value,()=>props.initialPause,()=>props.endingPause,()=>props.fadeDuration],()=>animStop(isActive.value)),watch(()=>elContainer.value,()=>{if(!elContainer.value)return;for(parentElement=elContainer.value.parentElement;parentElement&&!parentElement.matches(`[is-bng-panel], [bng-nav-item], [ng-click], [href], [bng-all-clicks], [bng-all-clicks-no-nav], [ui-sref], input, textarea, button, md-option, md-slider, md-select, md-checkbox`);)if(parentElement=parentElement.parentElement,parentElement===document.body){parentElement=null;break}if(!parentElement)return;overrideClasses.value=[];for(let[key,selectors]of Object.entries(styleOverrides))parentElement.matches(selectors)&&overrideClasses.value.push(`bng-text-override--${key}`);let fSize=window.getComputedStyle(elContainer.value,null).fontSize;fontSize.value=+fSize.substring(0,fSize.length-2),events$3.start.forEach(event=>parentElement.addEventListener(event,animStart)),events$3.stop.forEach(event=>parentElement.addEventListener(event,animStop))},{immediate:!0}),onUnmounted(()=>{animTimeout(),parentElement&&(events$3.start.forEach(event=>parentElement.removeEventListener(event,animStart)),events$3.stop.forEach(event=>parentElement.removeEventListener(event,animStop)))}),(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,{ref_key:`elContainer`,ref:elContainer,class:normalizeClass([`bng-text-scroller`,[{"is-scrolling":isScrolling$1.value},...overrideClasses.value]])},[createBaseVNode(`div`,{ref_key:`elText`,ref:elText,class:`scroller-text`,style:normalizeStyle(scrollStyles.value)},[renderSlot(_ctx.$slots,`default`,{},void 0,!0)],4)],2))}},textScroller_default=__plugin_vue_export_helper_default(_sfc_main$390,[[`__scopeId`,`data-v-4f311fae`]]),_hoisted_1$338=[`data-tree-node-key`,`data-tree-node-expanded`,`data-tree-node-selected`,`data-tree-node-parent-path`,`data-tree-node-path`],_hoisted_2$268={key:1,class:`node`},_hoisted_3$234=[`disabled`],_hoisted_4$199={key:2,"data-tree-node-children":``},_sfc_main$389={__name:`treeNode`,props:{node:{type:Object,required:!0},keyName:{type:String,required:!0},parentNode:Object,selectMode:String,expandMode:String,expandedKeys:Array,selectedKeys:Array,parentPath:Array},setup(__props){let props=__props,$templates=inject(`$templates`),_expandFn=inject(`expandFn`),_selectFn=inject(`selectFn`),expanded=computed(()=>props.expandMode===`prop`?props.node.expanded:props.expandedKeys&&props.expandedKeys.includes(props.node[props.keyName])),expandable=computed(()=>!props.node.disabled&&props.node.children&&props.node.children.length>0),selected=computed(()=>props.selectMode?props.selectMode===`prop`?props.node.selected:props.selectedKeys&&props.selectedKeys.includes(props.node[props.keyName]):!1),selectable=computed(()=>!props.node.disabled&&props.selectMode&&props.node.selectable!==!1),path=computed(()=>props.parentPath?props.parentPath.concat(props.node[props.keyName]):[props.node[props.keyName]]),parentPathString=computed(()=>props.parentPath?props.parentPath.join(`/`):null),pathString=computed(()=>path.value.join(`/`)),nodeProps=computed(()=>({path:path.value,parentPath:props.parentPath}));return(_ctx,_cache)=>{let _component_TreeNode=resolveComponent(`TreeNode`,!0);return openBlock(),createElementBlock(`li`,{"data-tree-node-key":__props.node[__props.keyName],"data-tree-node-expanded":expanded.value,"data-tree-node-selected":selected.value,"data-tree-node-parent-path":parentPathString.value,"data-tree-node-path":pathString.value,"data-tree-node":``},[unref($templates).node?(openBlock(),createBlock(resolveDynamicComponent(unref($templates).node),{key:0,node:__props.node,parentNode:__props.parentNode,expanded:expanded.value,selected:selected.value,expand:()=>expandable.value?unref(_expandFn)(__props.node,nodeProps.value):{},select:()=>selectable.value?unref(_selectFn)(__props.node,nodeProps.value):{}},null,8,[`node`,`parentNode`,`expanded`,`selected`,`expand`,`select`])):(openBlock(),createElementBlock(`div`,_hoisted_2$268,[__props.node.children&&unref($templates).toggle?(openBlock(),createBlock(resolveDynamicComponent(unref($templates).toggle),{key:0,node:__props.node,parentNode:__props.parentNode,expanded:expanded.value,selected:selected.value,expand:()=>expandable.value?unref(_expandFn)(__props.node,nodeProps.value):{}},null,8,[`node`,`parentNode`,`expanded`,`selected`,`expand`])):(openBlock(),createElementBlock(`span`,{key:1,class:`node-toggle`,onClick:_cache[0]||=()=>expandable.value?unref(_expandFn)(__props.node,nodeProps.value):{},disabled:__props.node.disabled},[__props.node.children?(openBlock(),createBlock(unref(bngIcon_default),{key:0,"bng-nav-item":``,type:expanded.value?unref(icons).arrowSmallDown:unref(icons).arrowSmallRight},null,8,[`type`])):createCommentVNode(``,!0)],8,_hoisted_3$234)),unref($templates).content?(openBlock(),createBlock(resolveDynamicComponent(unref($templates).content),{key:2,node:__props.node,parentNode:__props.parentNode,expanded:expanded.value,selected:selected.value,expand:()=>expandable.value?unref(_expandFn)(__props.node,nodeProps.value):{},select:()=>selectable.value?unref(_selectFn)(__props.node,nodeProps.value):{}},null,8,[`node`,`parentNode`,`expanded`,`selected`,`expand`,`select`])):(openBlock(),createElementBlock(`span`,{key:3,"bng-nav-item":``,class:`node-content`,onClick:_cache[1]||=()=>selectable.value?unref(_selectFn)(__props.node,nodeProps.value):{}},toDisplayString(__props.node.label),1))])),expanded.value&&__props.node.children?(openBlock(),createElementBlock(`ul`,_hoisted_4$199,[(openBlock(!0),createElementBlock(Fragment,null,renderList(__props.node.children,childNode=>(openBlock(),createBlock(_component_TreeNode,{key:childNode[__props.keyName],node:childNode,parentNode:__props.node,keyName:__props.keyName,selectMode:__props.selectMode,expandMode:__props.expandMode,expandedKeys:__props.expandedKeys,selectedKeys:__props.selectedKeys,parentPath:path.value},null,8,[`node`,`parentNode`,`keyName`,`selectMode`,`expandMode`,`expandedKeys`,`selectedKeys`,`parentPath`]))),128))])):createCommentVNode(``,!0)],8,_hoisted_1$338)}}},treeNode_default=__plugin_vue_export_helper_default(_sfc_main$389,[[`__scopeId`,`data-v-aeb14cdb`]]),_hoisted_1$337={class:`tree`},SELECT_SINGLE=`single`,SELECT_MULTIPLE=`multi`,SELECT_PROP=`prop`,SELECT_MODES=[SELECT_SINGLE,SELECT_MULTIPLE,SELECT_PROP],EXPAND_MODEL=`model`,EXPAND_PROP=`prop`,EXPAND_MODES=[EXPAND_MODEL,EXPAND_PROP],_sfc_main$388={__name:`tree`,props:mergeModels({nodes:{type:Array,required:!0},keyName:{type:String,default:`key`},expandMode:{type:String,default:EXPAND_MODEL,validator(value){return EXPAND_MODES.includes(value)}},selectMode:{type:String,validator(value){return SELECT_MODES.includes(value)}}},{expandedKeys:{},expandedKeysModifiers:{},selectedKeys:{},selectedKeysModifiers:{}}),emits:mergeModels([`update:expandedKeys`,`node-expanded`,`node-collapsed`,`expanded-keys-changed`,`node-selected`,`node-unselected`,`selected-keys-changed`],[`update:expandedKeys`,`update:selectedKeys`]),setup(__props,{emit:__emit}){let props=__props,expandedKeys=useModel(__props,`expandedKeys`),selectedKeys=useModel(__props,`selectedKeys`),emit$1=__emit;onBeforeMount(()=>{provide(`$templates`,useSlots()),provide(`expandFn`,expand),provide(`selectFn`,select)});function expand(node,nodeProps){let nodeKey=node[props.keyName];if(props.expandMode===EXPAND_PROP)node.expanded?emit$1(`node-collapsed`,node,nodeProps):emit$1(`node-expanded`,node,nodeProps);else{if(!expandedKeys.value)throw Error(`v-model:expandedKeys must be set`);let expanded=expandedKeys.value.includes(nodeKey),updatedExpandedKeys;expanded?(updatedExpandedKeys=expandedKeys.value.filter(x=>x!==nodeKey),emit$1(`node-collapsed`,node,nodeProps)):(updatedExpandedKeys=[...expandedKeys.value,nodeKey],emit$1(`node-expanded`,node,nodeProps)),expandedKeys.value=updatedExpandedKeys,emit$1(`expanded-keys-changed`,updatedExpandedKeys)}}function select(node,nodeProps){console.log(`select`,node);let nodeKey=node[props.keyName];if(props.selectMode===SELECT_PROP)node.selected?emit$1(`node-selected`,node,nodeProps):emit$1(`node-unselected`,node,nodeProps);else{if(!selectedKeys.value)throw Error(`v-model:selectedKeys must be set`);let selected=selectedKeys.value.includes(nodeKey),updatedSelectedKeys;selected?(updatedSelectedKeys=selectedKeys.value.filter(x=>x!==nodeKey),emit$1(`node-unselected`,node,nodeProps)):props.selectMode===`single`?(updatedSelectedKeys=[nodeKey],emit$1(`node-selected`,node,nodeProps)):props.selectMode===`multi`&&(updatedSelectedKeys=[...selectedKeys.value,nodeKey],emit$1(`node-selected`,node,nodeProps)),selectedKeys.value=updatedSelectedKeys,emit$1(`selected-keys-changed`,updatedSelectedKeys)}}return(_ctx,_cache)=>(openBlock(),createElementBlock(`ul`,_hoisted_1$337,[(openBlock(!0),createElementBlock(Fragment,null,renderList(__props.nodes,node=>(openBlock(),createBlock(treeNode_default,{key:node[__props.keyName],node,keyName:__props.keyName,selectMode:__props.selectMode,expandMode:__props.expandMode,expandedKeys:expandedKeys.value,selectedKeys:selectedKeys.value},null,8,[`node`,`keyName`,`selectMode`,`expandMode`,`expandedKeys`,`selectedKeys`]))),128))]))}},tree_default=__plugin_vue_export_helper_default(_sfc_main$388,[[`__scopeId`,`data-v-7363528a`]]);const DEMOS$1={};var utility_exports=__export({Accordion:()=>accordion_default,AccordionItem:()=>accordionItem_default,AccordionTree:()=>accordionTree_default,AspectRatio:()=>aspectRatio_default,Carousel:()=>carousel_default,CarouselItem:()=>carouselItem_default,DEMOS:()=>DEMOS$1,DRAWER_POSITION:()=>DRAWER_POSITION,Drawer:()=>drawer_default,DynamicComponent:()=>dynamicComponent_default,Shelf:()=>shelf_default,SlotSwitcher:()=>slotSwitcher_default,Tab:()=>tab_default,TabList:()=>tabList_default,Tabs:()=>tabs_default,TextScroller:()=>textScroller_default,Tree:()=>tree_default,TreeNode:()=>treeNode_default}),_hoisted_1$336={class:`actions-drawer`},_sfc_main$387={__name:`bngActionsDrawer`,props:{header:{type:String,required:!0},headerActions:Array,showHeaderActions:{type:Boolean,default:!0},grouped:Boolean,actions:{type:[Array,Object],required:!0},selected:{type:[String,Number]},expanded:Boolean},emits:[`actionClick`,`headerActionClicked`,`categoryChanged`],setup(__props,{emit:__emit}){let emit$1=__emit,onActionClicked=action=>emit$1(`actionClick`,action);return(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$336,[createVNode(unref(bngDrawerOld_default),null,createSlots({header:withCtx(()=>[createTextVNode(toDisplayString(__props.header),1)]),content:withCtx(()=>[__props.grouped?(openBlock(),createBlock(unref(tabs_default),{key:0,class:`categories-tab bng-tabs`},{default:withCtx(()=>[(openBlock(!0),createElementBlock(Fragment,null,renderList(__props.actions,category=>(openBlock(),createBlock(unref(tab_default),{key:category.category,heading:category.category},{default:withCtx(()=>[(openBlock(),createBlock(unref(bngActionsList_default),{key:category.category,actions:category.items,selected:__props.selected,class:normalizeClass({expanded:__props.expanded}),onActionClick:_cache[0]||=value=>onActionClicked(value)},null,8,[`actions`,`selected`,`class`]))]),_:2},1032,[`heading`]))),128))]),_:1})):(openBlock(),createBlock(unref(bngActionsList_default),{key:1,actions:__props.actions,selected:__props.selected,class:normalizeClass({expanded:__props.expanded}),onActionClick:_cache[1]||=value=>onActionClicked(value)},null,8,[`actions`,`selected`,`class`]))]),_:2},[__props.showHeaderActions&&__props.headerActions?{name:`headerOptions`,fn:withCtx(()=>[(openBlock(!0),createElementBlock(Fragment,null,renderList(__props.headerActions,action=>(openBlock(),createBlock(unref(bngButton_default),{key:action.value,tabindex:`1`,accent:action.accent,onClick:$event=>_ctx.$emit(`headerActionClicked`,action.value)},{default:withCtx(()=>[createTextVNode(toDisplayString(action.label),1)]),_:2},1032,[`accent`,`onClick`]))),128))]),key:`0`}:void 0]),1024)]))}},bngActionsDrawer_default=__plugin_vue_export_helper_default(_sfc_main$387,[[`__scopeId`,`data-v-b433a352`]]),_hoisted_1$335={class:`header-wrapper`},_hoisted_2$267={class:`drawer-content`},_hoisted_3$233={key:0,class:`filters-wrapper`},_hoisted_4$198={class:`drawer-actions-wrapper`},_hoisted_5$168={key:0,class:`action-divider`},_hoisted_6$143={key:1,class:`progress-indicator`},_sfc_main$386={__name:`bngActionsDrawerOne`,props:{value:{type:Object,required:!0},flattenChildren:Boolean,allowOpenDrawer:Boolean,openDrawerLabel:String,closeDrawerLabel:String,loading:Boolean,header:String,blur:Boolean},emits:[`update:currentActionPath`,`update:loading`,`actionClicked`,`actionItemChanged`,`drawerOpened`],setup(__props,{emit:__emit}){let props=__props,emit$1=__emit,drawerState=reactive({isOpenCatalog:!1,currentPath:[],drawerFilters:[]}),currentActionPath=computed({get:()=>drawerState.currentPath,set:newValue=>{drawerState.currentPath=newValue}}),parentAction=computed(()=>{if(!currentActionPath.value||currentActionPath.value.length===0)return null;let currentAction$1=props.value;for(let key of currentActionPath.value.slice(0,-1))currentAction$1=currentAction$1.items.find(x=>x.value===key);return currentAction$1}),currentAction=computed(()=>{let currentAction$1=props.value;for(let key of currentActionPath.value)currentAction$1=currentAction$1.items.find(x=>x.value===key);return currentAction$1}),isDrawerOpen=computed({get:()=>drawerState.isOpenCatalog,set:newValue=>{drawerState.isOpenCatalog=newValue,emit$1(`drawerOpened`,newValue)}}),loading=computed({get:()=>props.loading,set:newValue=>emit$1(`update:loading`,newValue)}),canViewCatalogDisplayMode=computed(()=>(console.log(`canViewCatalogDisplayMode`),loading.value===!0||currentAction.value.allowOpenDrawer===!1?!1:(console.log(`currentAction`,currentAction.value),currentAction.value.items.every(x=>x.lazyLoadItems===!0||x.items)))),drawerFilterValue=computed({get:()=>drawerState.drawerFilters&&drawerState.drawerFilters.length>0?drawerState.drawerFilters[0]:null,set:newValue=>{drawerState.drawerFilters=newValue?[newValue]:[]}}),catalogFilters=computed(()=>{let activeAction=isDrawerOpen.value?parentAction.value:currentAction.value;return activeAction.items.every(x=>x.items&&x.items.length>0||x.lazyLoadItems)?activeAction.items.map(x=>({label:x.label,value:x.value})):[]}),showBackButton=computed(()=>currentActionPath.value.length>0);watch(drawerFilterValue,(newValue,oldValue)=>{console.log(`drawerFilterValue`,newValue,oldValue),newValue&&!oldValue?currentActionPath.value=[...currentActionPath.value,newValue]:newValue&&oldValue?currentActionPath.value=[...currentActionPath.value.slice(0,-1),newValue]:!newValue&&oldValue&&(currentActionPath.value=[...currentActionPath.value].slice(0,-1))}),watch(currentActionPath,()=>{emit$1(`actionItemChanged`,currentAction.value,currentActionPath.value)});let selectAction=actionItem=>{(actionItem.items&&actionItem.items.length>0||actionItem.lazyLoadItems===!0)&&(isDrawerOpen.value&&=!1,currentActionPath.value=[...currentActionPath.value,actionItem.value]),emit$1(`actionClicked`,actionItem)},toggleOpenCatalog=()=>{isDrawerOpen.value?closeDrawer():openDrawer()},goBack=()=>{isDrawerOpen.value?closeDrawer():currentActionPath.value=[...currentActionPath.value].slice(0,-1)};function openDrawer(){drawerFilterValue.value=catalogFilters.value[0].value,isDrawerOpen.value=!0}function closeDrawer(){drawerFilterValue.value=null,isDrawerOpen.value=!1}return(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,{class:normalizeClass([`bng-actions-drawer`,{expanded:isDrawerOpen.value}])},[createVNode(unref(bngDrawerOld_default),{blur:__props.blur,class:`bng-drawer`},{header:withCtx(()=>[renderSlot(_ctx.$slots,`header`,{actionItem:currentAction.value,canGoBack:showBackButton.value,goBack},()=>[createBaseVNode(`div`,_hoisted_1$335,[showBackButton.value?(openBlock(),createBlock(unref(bngButton_default),{key:0,icon:unref(icons).arrowLargeLeft,accent:unref(ACCENTS).secondary,class:`back-btn`,onClick:goBack},{default:withCtx(()=>[..._cache[1]||=[createTextVNode(`Back`,-1)]]),_:1},8,[`icon`,`accent`])):createCommentVNode(``,!0),createTextVNode(` `+toDisplayString(currentAction.value.label),1)])],!0)]),content:withCtx(()=>[createBaseVNode(`div`,_hoisted_2$267,[drawerState.isOpenCatalog&&catalogFilters.value.length>0?(openBlock(),createElementBlock(`div`,_hoisted_3$233,[createVNode(unref(bngPillFilters_default),{modelValue:drawerState.drawerFilters,"onUpdate:modelValue":_cache[0]||=$event=>drawerState.drawerFilters=$event,options:catalogFilters.value},null,8,[`modelValue`,`options`])])):createCommentVNode(``,!0),createBaseVNode(`div`,_hoisted_4$198,[createBaseVNode(`div`,{class:normalizeClass([`drawer-actions`,{expanded:drawerState.isOpenCatalog}])},[loading.value?(openBlock(),createElementBlock(`div`,_hoisted_6$143,[..._cache[2]||=[createBaseVNode(`div`,{class:`loader`},null,-1)]])):(openBlock(!0),createElementBlock(Fragment,{key:0},renderList(currentAction.value.items,action=>(openBlock(),createElementBlock(Fragment,{key:action.value},[action.type===`actionDivider`?(openBlock(),createElementBlock(`div`,_hoisted_5$168,toDisplayString(action.label),1)):renderSlot(_ctx.$slots,`item`,{key:1,actionItem:action,onClick:()=>selectAction(action)},()=>[createVNode(unref(bngImageTile_default),{label:action.label,icon:action.icon,onClick:$event=>selectAction(action)},null,8,[`label`,`icon`,`onClick`])],!0)],64))),128))],2)]),canViewCatalogDisplayMode.value?renderSlot(_ctx.$slots,`footer`,{key:1},()=>[createVNode(unref(bngButton_default),{class:`catalog-btn`,accent:unref(ACCENTS).outlined,onClick:toggleOpenCatalog},{default:withCtx(()=>[drawerState.isOpenCatalog?(openBlock(),createElementBlock(Fragment,{key:0},[createTextVNode(toDisplayString(__props.closeDrawerLabel?__props.closeDrawerLabel:`Collapse catalog`),1)],64)):(openBlock(),createElementBlock(Fragment,{key:1},[createTextVNode(toDisplayString(__props.openDrawerLabel?__props.openDrawerLabel:`Open full catalog`),1)],64))]),_:1},8,[`accent`])],!0):createCommentVNode(``,!0)])]),_:3},8,[`blur`])],2))}},bngActionsDrawerOne_default=__plugin_vue_export_helper_default(_sfc_main$386,[[`__scopeId`,`data-v-529c2a59`]]),_hoisted_1$334={class:`actions`},_sfc_main$385={__name:`bngActionsList`,props:{actions:{type:Array,required:!0},selected:{type:[String,Number],required:!1}},emits:[`actionClick`],setup(__props,{emit:__emit}){let emit$1=__emit;return(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$334,[(openBlock(!0),createElementBlock(Fragment,null,renderList(__props.actions,action=>(openBlock(),createBlock(unref(bngImageTile_default),mergeProps({class:`action-tile`,tabindex:`0`,key:action.value},{ref_for:!0},action,{"bng-nav-item":``,onClick:$event=>emit$1(`actionClick`,action.value)}),null,16,[`onClick`]))),128))]))}},bngActionsList_default=__plugin_vue_export_helper_default(_sfc_main$385,[[`__scopeId`,`data-v-8790d45d`]]),_hoisted_1$333=[`ui-event`],_hoisted_2$266={key:0},_hoisted_3$232={key:3,class:`combo-separator`},MULTI_ID=`[PLUS]`,MULTI_LABEL=`+`,_sfc_main$384={__name:`bngBinding`,props:{action:String,showUnassigned:Boolean,device:[String,Array],deviceKey:String,dark:Boolean,deviceMask:[String,Function],controller:Boolean,uiEvent:String,trackIgnore:Boolean,unassignedText:{default:`[N/A]`,type:String},viewerObj:Object,imagePack:String,actionVariants:Boolean,useLastDevice:{type:Boolean,default:!0},vertical:Boolean},setup(__props,{expose:__expose}){let $simplemenu=inject(`$simplemenu`),Controls=controls_default(),{showIfController,lastControllersSignature}=storeToRefs(Controls),props=__props,iconColors={dark:`var(--bng-off-black)`,light:`var(--bng-off-white)`},iconColor=computed(()=>iconColors[props.dark?`dark`:`light`]);computed(()=>iconColors[props.dark?`light`:`dark`]);let controllerOnly=computed(()=>props.controller||$simplemenu.value),LABELS_BIG=[`enter`,`tab`,`capslock`,`backspace`,`lshift`,`rshift`,`left`,`right`,`up`,`down`,`space`,`grave`,`comma`,`period`].map(c=>CONTROL_LABELS[c]||c),LABELS_OFFSET=[`space`].map(c=>CONTROL_LABELS[c]||c),rgxSanitize$1=s=>s.replace(/[-.+*$^?:|[\](){}]/g,`\\$&`),LABELS_RGX=RegExp(`(`+[MULTI_ID,...LABELS_BIG,...LABELS_OFFSET].map(rgxSanitize$1).join(`|`)+`)`,`g`),viewerObj=computed(()=>{if(props.viewerObj)return props.viewerObj;if(controllerOnly.value&&showIfController.value){let opts={...props};return opts.controller=!0,opts._controllerSignature=lastControllersSignature.value,Controls.makeViewerObj(opts)}return Controls.makeViewerObj(props)}),viewerVariants=computed(()=>{if(!viewerObj.value)return[];let variants=viewerObj.value.variants||[viewerObj.value];variants=variants.map(obj=>obj.multiControls||[obj]);for(let objs of variants)for(let obj of objs)if(obj&&(!obj.special||obj.ownLabel)&&!obj.controlSegments){let control=obj.ownLabel||obj.control;control=control.replace(/ \+ /g,MULTI_ID),obj.controlSegments=String(control).split(LABELS_RGX).filter(Boolean).map(segment=>({value:segment===MULTI_ID?MULTI_LABEL:segment,class:(LABELS_BIG.includes(segment)?`label-bigger `:``)+(LABELS_OFFSET.includes(segment)?`label-offset `:``)+(segment===MULTI_ID?`label-multi `:``)}))}return variants}),display=computed(()=>{let res=!!viewerObj.value;if(viewerObj.value)if(props.deviceMask){let dev=viewerObj.value.devName;res=typeof props.deviceMask==`function`?props.deviceMask(dev):dev.startsWith(props.deviceMask)}else controllerOnly.value&&(res=showIfController.value);return res||props.showUnassigned});__expose({displayed:display});let eventName=computed(()=>props.action?props.action:props.uiEvent?props.uiEvent:null),uiNavTracker=useUINavTracker(),ownerId$1=uniqueId(`bngBinding`),trackedEvent=``,track$1=(eventName$1=null)=>{if(trackedEvent&&=(uiNavTracker.removeIgnore(trackedEvent,ownerId$1),``),!(props.trackIgnore||!display.value)&&eventName$1){if(trackedEvent===eventName$1)return;trackedEvent=eventName$1,uiNavTracker.addIgnore(trackedEvent,ownerId$1)}};return watch(()=>props.trackIgnore,val=>track$1(val?null:eventName.value)),watch(display,()=>track$1(eventName.value)),watch(eventName,(val,prev)=>{prev&&track$1(),val&&track$1(val)}),onMounted(()=>track$1(eventName.value)),onUnmounted(()=>track$1()),(_ctx,_cache)=>display.value?(openBlock(),createElementBlock(`span`,{key:0,class:normalizeClass([`binding-wrapper`,{"binding-theme-dark":__props.dark,"binding-theme-light":!__props.dark,"with-variants":viewerVariants.value.length>1,vertical:__props.vertical}]),"ui-event":__props.uiEvent},[(openBlock(!0),createElementBlock(Fragment,null,renderList(viewerVariants.value,(viewerObjs,index)=>(openBlock(),createElementBlock(`span`,{key:index,class:normalizeClass([`binding-container`,{"combo-binding":viewerObjs.length>1}])},[(openBlock(!0),createElementBlock(Fragment,null,renderList(viewerObjs,(viewerObj$1,index$1)=>(openBlock(),createElementBlock(Fragment,{key:index$1},[viewerObj$1&&viewerObj$1.controlSegments?(openBlock(),createElementBlock(`kbd`,_hoisted_2$266,[(openBlock(!0),createElementBlock(Fragment,null,renderList(viewerObj$1.controlSegments,(seg,i)=>(openBlock(),createElementBlock(`span`,{key:i,class:normalizeClass(seg.class)},toDisplayString(seg.value),3))),128))])):viewerObj$1&&viewerObj$1.special?(openBlock(),createBlock(unref(bngIcon_default),{key:1,class:`bng-binding-icon`,type:unref(icons)[viewerObj$1.ownIcon],color:iconColor.value},null,8,[`type`,`color`])):!viewerObj$1&&__props.showUnassigned?(openBlock(),createBlock(unref(bngIcon_default),{key:2,class:`bng-binding-icon n-a`,type:unref(icons).NA,color:iconColor.value},null,8,[`type`,`color`])):createCommentVNode(``,!0),index$1Number(val)>0},simple:Boolean,blur:Boolean,disableLastItem:Boolean,showBackButton:Boolean,showBackBinding:{type:Boolean,default:!0},navigable:{type:Boolean,default:!0}},emits:[`click`,`back`],setup(__props,{emit:__emit}){let bid=uniqueId(`bng-path`),emit$1=__emit,props=__props,pathView=computed(()=>{if(!Array.isArray(props.items))return[];let mapItem=itm=>({label:itm.label,items:itm.items,data:itm,dividerType:itm.dividerType}),items$2=props.items.map(mapItem),res=props.limit?items$2.slice(-props.limit):items$2;if(!props.simple){let looseCmp=(a$1,b)=>a$1.label===b.label&&a$1.value===b.value,len=res.length;for(let i=1;ilooseCmp(itm,res[idx])),items:items$3.map(mapItem)})}}return props.limit&&items$2.length>props.limit&&res.unshift({label:`…`,data:items$2[items$2.length-props.limit-1]}),res.length>0&&(res[0].first=!0,res.at(-1).last=!0),res});function onClick(item,index){(!props.disableLastItem||index(openBlock(),createElementBlock(`div`,{class:`bng-path`,"bng-no-child-nav":!__props.navigable},[__props.showBackButton?(openBlock(),createBlock(unref(bngButton_default),{key:0,class:`back-button`,accent:unref(ACCENTS).custom,onClick:_cache[0]||=$event=>emit$1(`back`),tabindex:`1`},{default:withCtx(()=>[createVNode(unref(bngIcon_default),{type:unref(icons).arrowSmallLeft,class:`back-icon`},null,8,[`type`]),__props.showBackBinding?(openBlock(),createBlock(unref(bngBinding_default),{key:0,"ui-event":`back`,controller:``,"track-ignore":``})):createCommentVNode(``,!0),createTextVNode(` `+toDisplayString(_ctx.$tt(`ui.common.back`)),1)]),_:1},8,[`accent`])):createCommentVNode(``,!0),(openBlock(!0),createElementBlock(Fragment,null,renderList(pathView.value,(item,index)=>(openBlock(),createElementBlock(Fragment,{key:index},[item.dropdown?(openBlock(),createElementBlock(Fragment,{key:1},[withDirectives(createVNode(unref(bngButton_default),{class:`bng-path-item bng-path-has-dropdown`,accent:unref(ACCENTS).text,icon:unref(icons).arrowSmallRight},null,8,[`accent`,`icon`]),[[unref(BngBlur_default),__props.blur],[unref(BngPopover_default),item.dropdown,`bottom-start`,{click:!0}]]),createVNode(unref(bngPopoverMenu_default),{name:item.dropdown,focus:``},{default:withCtx(({hide:hide$2})=>[(openBlock(!0),createElementBlock(Fragment,null,renderList(item.items,(subitem,idx)=>withDirectives((openBlock(),createBlock(unref(bngButton_default),{key:idx,class:normalizeClass({selected:idx===item.selected}),accent:unref(ACCENTS).menu,onClick:$event=>onMenuClick(subitem,hide$2)},{default:withCtx(()=>[createTextVNode(toDisplayString(subitem.label),1)]),_:2},1032,[`class`,`accent`,`onClick`])),[[unref(BngOnUiNav_default),void 0,`ok`,{focusRequired:!0,asMouse:!0}]])),128))]),_:2},1032,[`name`])],64)):(openBlock(),createElementBlock(Fragment,{key:0},[withDirectives((openBlock(),createBlock(unref(bngButton_default),{class:normalizeClass([`bng-path-item`,{"bng-path-simple":__props.simple,"bng-path-disabled":__props.disableLastItem&&item.last,"bng-path-first":item.first,"bng-path-last":item.last}]),accent:unref(ACCENTS).text,onClick:$event=>onClick(item,index)},{default:withCtx(()=>[createTextVNode(toDisplayString(item.label),1)]),_:2},1032,[`class`,`accent`,`onClick`])),[[unref(BngBlur_default),__props.blur]]),__props.simple&&!item.last?(openBlock(),createElementBlock(`div`,_hoisted_2$265,[withDirectives(createVNode(unref(bngIcon_default),{type:item.dividerType||unref(icons).slashRight},null,8,[`type`]),[[unref(BngBlur_default),__props.blur]])])):createCommentVNode(``,!0)],64))],64))),128))],8,_hoisted_1$332))}},bngBreadcrumbs_default=__plugin_vue_export_helper_default(_sfc_main$383,[[`__scopeId`,`data-v-4a2e18d5`]]),_hoisted_1$331=[`accent`,`disabled`],_hoisted_2$264={key:0,class:`hold-arrow`,xmlns:`http://www.w3.org/2000/svg`,viewBox:`0 0 16 12`,preserveAspectRatio:`xMidYMid`},_hoisted_3$231={key:3,class:`label`},_hoisted_4$197={key:5,class:`label`},_hoisted_5$167={key:6};const ACCENTS={main:`main`,secondary:`secondary`,outlined:`outlined`,text:`text`,attention:`attention`,attentionghost:`attentionghost`,attentionoutlined:`attentionoutlined`,ghost:`ghost`,menu:`menu`,custom:`custom`};var _sfc_main$382={__name:`bngButton`,props:{accent:{type:String,default:`main`,validator:v=>Object.values(ACCENTS).includes(v)||v===``},iconLeft:[Object,String],iconRight:[Object,String],label:String,icon:[Object,String],externalIcon:String,showHold:Boolean,holdVertical:Boolean,disabled:Boolean,noSound:Boolean},setup(__props,{expose:__expose}){let slots=useSlots(),uiNavEvent=ref(),btnDOMElRef=ref(),attrs=useAttrs(),useOldIcons=computed(()=>`oldIcons`in attrs);watchUINavEventChange(btnDOMElRef,({eventName,action})=>{}),__expose({getElement(){return btnDOMElRef.value}});let isPlainTextSlot=ref(!1);function checkIfPlainText(){let slotContent=slots.default?slots.default():[];isPlainTextSlot.value=slotContent.length===1&&typeof slotContent[0].type==`symbol`&&String(slotContent[0].type).indexOf(`v-txt`)>-1&&slotContent[0].children.trim().length>0}watch(()=>slots.default,checkIfPlainText),checkIfPlainText();let props=__props,needsFallbackHoldOffset=ref(!0);return watchEffect(()=>{btnDOMElRef.value&&props.accent===`custom`&&window.getComputedStyle(btnDOMElRef.value).getPropertyValue(`--bng-button-custom-hold-offset`).trim()&&(needsFallbackHoldOffset.value=!1)}),(_ctx,_cache)=>withDirectives((openBlock(),createElementBlock(`button`,{ref_key:`btnDOMElRef`,ref:btnDOMElRef,accent:__props.accent,class:normalizeClass({"show-hold":__props.showHold,"hold-vertical":__props.holdVertical,"bng-button":!0,empty:!unref(slots).default&&!__props.label,"l-icon":__props.iconLeft||__props.icon,"r-icon":__props.iconRight,"external-icon":__props.externalIcon,"fallback-hold-offset":props.accent===`custom`&&needsFallbackHoldOffset.value}),disabled:__props.disabled},[__props.showHold?(openBlock(),createElementBlock(`svg`,_hoisted_2$264,[..._cache[0]||=[createBaseVNode(`path`,{d:`M1,1 L8,2 L16,1 L8,11 z`},null,-1)]])):createCommentVNode(``,!0),useOldIcons.value&&(__props.iconLeft||__props.icon)?(openBlock(),createBlock(unref(bngOldIcon_default),{key:1,type:__props.iconLeft||__props.icon},null,8,[`type`])):!useOldIcons.value&&(__props.iconLeft||__props.icon||__props.externalIcon)?(openBlock(),createBlock(unref(bngIcon_default),{key:2,class:`icon`,type:__props.iconLeft||__props.icon,externalImage:__props.externalIcon},null,8,[`type`,`externalImage`])):createCommentVNode(``,!0),isPlainTextSlot.value?(openBlock(),createElementBlock(`span`,_hoisted_3$231,[renderSlot(_ctx.$slots,`default`,{},void 0,!0)])):isPlainTextSlot.value?createCommentVNode(``,!0):renderSlot(_ctx.$slots,`default`,{key:4},void 0,!0),__props.label&&!isPlainTextSlot.value?(openBlock(),createElementBlock(`span`,_hoisted_4$197,toDisplayString(__props.label),1)):createCommentVNode(``,!0),uiNavEvent.value?(openBlock(),createElementBlock(`span`,_hoisted_5$167,toDisplayString(uiNavEvent.value),1)):createCommentVNode(``,!0),useOldIcons.value&&__props.iconRight?(openBlock(),createBlock(unref(bngOldIcon_default),{key:7,span:``,type:__props.iconRight},null,8,[`type`])):!useOldIcons.value&&__props.iconRight?(openBlock(),createBlock(unref(bngIcon_default),{key:8,class:`icon`,type:__props.iconRight},null,8,[`type`])):createCommentVNode(``,!0),_cache[1]||=createBaseVNode(`div`,{class:`background`},null,-1)],10,_hoisted_1$331)),[[unref(BngSoundClass_default),!__props.disabled&&!__props.noSound&&`bng_click_hover_generic`]])}},bngButton_default=__plugin_vue_export_helper_default(_sfc_main$382,[[`__scopeId`,`data-v-8b356414`]]),_hoisted_1$330={class:`card-cnt`},ANIMATION_TYPES=[`fade`,`slide`],_sfc_main$381={__name:`bngCard`,props:{backgroundImage:String,footerStyles:Object,hideFooter:Boolean,animateFooter:Boolean,animateFooterType:{type:String,default:`fade`,validator:value=>ANIMATION_TYPES.includes(value)}},setup(__props,{expose:__expose}){useCssVars(_ctx=>({v3c03b7b2:backgroundImageStyle.value}));let props=__props,slots=useSlots(),hasFooter=computed(()=>(slots.footer||slots.buttons)&&!props.hideFooter),buttonsContainer=ref(),backgroundImageStyle=computed(()=>props.backgroundImage?`url('${props.backgroundImage}')`:``);return __expose({buttonsContainer}),(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,{class:normalizeClass([`bng-card bng-card-wrapper`,{"with-background-image":backgroundImageStyle.value}])},[createBaseVNode(`div`,_hoisted_1$330,[renderSlot(_ctx.$slots,`default`,{},()=>[_cache[0]||=createTextVNode(`BNG Card`,-1)],!0)]),createVNode(Transition,{name:__props.animateFooter?__props.animateFooterType:``},{default:withCtx(()=>[hasFooter.value?(openBlock(),createElementBlock(`div`,{key:0,ref_key:`buttonsContainer`,ref:buttonsContainer,class:`footer-container`,style:normalizeStyle(__props.footerStyles)},[renderSlot(_ctx.$slots,`buttons`,{},void 0,!0),renderSlot(_ctx.$slots,`footer`,{},void 0,!0)],4)):createCommentVNode(``,!0)]),_:3},8,[`name`])],2))}},bngCard_default=__plugin_vue_export_helper_default(_sfc_main$381,[[`__scopeId`,`data-v-32edaae4`]]),_sfc_main$380={__name:`bngCardHeading`,props:{type:{type:String,default:`line`,validator:v=>[`line`,`ribbon`,`none`].includes(v)||v===``},outline:{type:Boolean,default:!1}},setup(__props){return(_ctx,_cache)=>(openBlock(),createElementBlock(`h2`,{class:normalizeClass({"card-heading":!0,[`heading-style-${__props.type}`]:!0,outline:__props.outline})},[renderSlot(_ctx.$slots,`default`,{},()=>[_cache[0]||=createTextVNode(`BNG Card Heading`,-1)],!0)],2))}},bngCardHeading_default=__plugin_vue_export_helper_default(_sfc_main$380,[[`__scopeId`,`data-v-fc76db37`]]),_hoisted_1$329={key:0,class:`colour-picker-switch`};const VIEWS={simple:{slider:!0,picker:!1,saturation:!1,luminosity:!1},compact_saturation:{slider:!0,picker:!0,saturation:!0,luminosity:!1,compact:!0},compact_luminosity:{slider:!0,picker:!0,saturation:!1,luminosity:!0,compact:!0},saturation:{slider:!1,picker:!0,saturation:!0,luminosity:!1},luminosity:{slider:!1,picker:!0,saturation:!1,luminosity:!0},full_saturation:{slider:!0,picker:!0,saturation:!0,luminosity:!1},full_luminosity:{slider:!0,picker:!0,saturation:!1,luminosity:!0}};var valuesDef={hue:.5,saturation:1,luminosity:.5},_sfc_main$379={__name:`bngColorPicker`,props:{modelValue:{type:Object,default:{...valuesDef}},view:{type:[String,Object],default:`full_luminosity`,validator:val=>typeof val==`string`||val in VIEWS},showText:{type:Boolean,default:!0},step:{type:Number,default:.001},disabled:Boolean},emits:[`update:modelValue`,`change`],setup(__props,{emit:__emit}){let $simplemenu=inject(`$simplemenu`),props=__props,sliderIndicator=`popout`,pickerMode=ref(`luminosity`),opts=ref({}),values=reactive({...valuesDef}),colorDot=ref({x:0,y:0});watch([()=>props.view,$simplemenu],()=>{if(typeof props.view==`string`)for(let key in VIEWS[props.view])opts.value[key]=VIEWS[props.view][key];else opts.value={...VIEWS[props.view]};$simplemenu.value?(opts.value.picker=!1,opts.value.compact&&(opts.value.slider=!0)):opts.value.compact&&loadCompactMode(),opts.value.picker&&setColorDot()},{immediate:!0});function updColour(){for(let key in values)values[key]=props.modelValue[key];opts.value.picker&&setColorDot()}watch(()=>props.modelValue,updColour),watch(()=>props.modelValue.hue,updColour),watch(()=>props.modelValue.saturation,updColour),watch(()=>props.modelValue.luminosity,updColour);let current=computed(()=>({hue:~~(values.hue*360),saturation:~~(values.saturation*100),luminosity:~~(values.luminosity*100)})),emitter=__emit;function notify(){for(let key in values)props.modelValue[key]=values[key];emitter(`change`,props.modelValue),emitter(`update:modelValue`,props.modelValue)}let hueLoop=[...Array(7)].map((_,i)=>i/6*360),gradients=reactive({hueStatic:hueLoop.map(hue=>`hsl(${hue}, 100%, 50%)`),hue:computed(()=>hueLoop.map(hue=>`hsl(${hue}, 100%, 50%)`)),overlaySaturation:[`hsla(0, 0%,  0%, 0)`,`hsla(0, 0%, 50%, 1)`],overlayLuminosity:[`hsla(0, 0%, 100%, 1)`,`hsla(0, 0%, 100%, 0) 50%`,`hsla(0, 0%,   0%, 0) 50%`,`hsla(0, 0%,   0%, 1)`],pickerOverlay:computed(()=>opts.value.saturation?gradients.overlaySaturation:gradients.overlayLuminosity),saturation:computed(()=>[`hsl(${current.value.hue},   0%, ${current.value.luminosity}%)`,`hsl(${current.value.hue}, 100%, ${current.value.luminosity}%)`]),luminosity:computed(()=>[`hsl(${current.value.hue}, ${current.value.saturation}%,   0%)`,`hsl(${current.value.hue}, ${current.value.saturation}%,  50%)`,`hsl(${current.value.hue}, ${current.value.saturation}%, 100%)`])}),isMousedown=!1;function onMousedown(){isMousedown=!0}function onMousemove(evt){updateColor(evt)}function onMouseupLeave(evt){updateColor(evt,!0)}function getPosition(evt){let rect=evt.target.getBoundingClientRect();return rect.width<20?colorDot.value:{x:(evt.x-rect.left)/rect.width*100,y:(evt.y-rect.top)/rect.height*100}}function updateColor(evt,mouseLeave=!1){if(!isMousedown)return;mouseLeave&&(isMousedown=!1);let pos=getPosition(evt);values.hue=Math.max(0,Math.min(pos.x,100))/100;let secondary=1-Math.max(0,Math.min(pos.y,100))/100;opts.value.saturation?values.saturation=secondary:values.luminosity=secondary,setColorDot(),nextTick(notify)}function setColorDot(){colorDot.value={x:values.hue*100,y:(1-(opts.value.saturation?values.saturation:values.luminosity))*100}}function toggleCompactMode(){opts.value.slider=!opts.value.slider,opts.value.picker=!opts.value.picker,saveCompactMode()}function togglePickerMode(){pickerMode.value=pickerMode.value===`luminosity`?`saturation`:`luminosity`,opts.value.luminosity=pickerMode.value===`luminosity`,opts.value.saturation=pickerMode.value===`saturation`,saveCompactMode()}function loadCompactMode(){let readOption=(name,val=null)=>JSON.parse(localStorage.getItem(name)||JSON.stringify(val));opts.value.picker=readOption(`bngColorPicker-picker`,!0),opts.value.slider=readOption(`bngColorPicker-slider`,!1),pickerMode.value=readOption(`bngColorPicker-picker-mode`,`luminosity`),opts.value.luminosity=pickerMode.value===`luminosity`,opts.value.saturation=pickerMode.value===`saturation`,!opts.value.luminosity&&!opts.value.saturation&&(opts.value.luminosity=!0)}function saveCompactMode(){let saveOption=(name,val)=>localStorage.setItem(name,JSON.stringify(val));saveOption(`bngColorPicker-picker`,opts.value.picker),saveOption(`bngColorPicker-slider`,opts.value.slider),saveOption(`bngColorPicker-picker-mode`,pickerMode.value)}return onMounted(()=>{updColour(),!$simplemenu.value&&opts.value.compact&&loadCompactMode()}),(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,{class:normalizeClass({"colour-picker-container":!0,"colour-picker-mode-picker":opts.value.picker,"colour-picker-mode-slider":opts.value.slider,"colour-picker-mode-compact":opts.value.compact})},[opts.value.compact?(openBlock(),createElementBlock(`div`,_hoisted_1$329,[_cache[3]||=createBaseVNode(`span`,null,`Custom color`,-1),!unref($simplemenu)&&opts.value.picker?withDirectives((openBlock(),createBlock(unref(bngButton_default),{key:0,accent:unref(ACCENTS).text,icon:unref(icons).materialTransparency01,onClick:togglePickerMode},null,8,[`accent`,`icon`])),[[unref(BngTooltip_default),`Toggle vertical axis mode to ${pickerMode.value===`luminosity`?`saturation`:`brightness`}`,`top`]]):createCommentVNode(``,!0),unref($simplemenu)?createCommentVNode(``,!0):withDirectives((openBlock(),createBlock(unref(bngButton_default),{key:1,accent:opts.value.picker?unref(ACCENTS).outlined:unref(ACCENTS).text,icon:opts.value.picker?unref(icons).materialGlossy:unref(icons).listSmall,onClick:toggleCompactMode},null,8,[`accent`,`icon`])),[[unref(BngTooltip_default),`Toggle picker/slider mode`,`top`]])])):createCommentVNode(``,!0),opts.value.picker?withDirectives((openBlock(),createElementBlock(`div`,{key:1,class:`colour-picker`,onMousemove,onMousedown,onMouseup:onMouseupLeave,onMouseleave:onMouseupLeave,style:normalizeStyle({"--colour-picker-x":`linear-gradient(90deg, ${gradients.hueStatic.join(`, `)})`,"--colour-picker-y":`linear-gradient(180deg, ${gradients.pickerOverlay.join(`, `)})`})},[createBaseVNode(`div`,{class:`colour-picker-dot`,style:normalizeStyle({left:`${colorDot.value.x}%`,top:`${colorDot.value.y}%`,"--colour-picker-dot-fill":`hsl(${current.value.hue}, ${opts.value.saturation?current.value.saturation:100}%, ${opts.value.luminosity?current.value.luminosity:50}%)`})},null,4)],36)),[[unref(BngDisabled_default),__props.disabled]]):createCommentVNode(``,!0),opts.value.slider||opts.value.hue?(openBlock(),createBlock(unref(bngColorSlider_default),{key:2,modelValue:values.hue,"onUpdate:modelValue":_cache[0]||=$event=>values.hue=$event,modelModifiers:{number:!0},onChange:notify,fill:gradients.hue,current:`hsl(${current.value.hue}, 100%, 50%)`,indicator:sliderIndicator,step:__props.step,disabled:__props.disabled},{default:withCtx(()=>[createTextVNode(toDisplayString(__props.showText?_ctx.$t(`ui.color.hue`):null),1)]),_:1},8,[`modelValue`,`fill`,`current`,`step`,`disabled`])):createCommentVNode(``,!0),opts.value.slider||opts.value.luminosity?(openBlock(),createBlock(unref(bngColorSlider_default),{key:3,"X:vertical":`opts.picker`,modelValue:values.saturation,"onUpdate:modelValue":_cache[1]||=$event=>values.saturation=$event,modelModifiers:{number:!0},onChange:notify,fill:gradients.saturation,current:`hsl(${current.value.hue}, ${current.value.saturation}%, ${current.value.luminosity}%)`,indicator:sliderIndicator,step:__props.step,disabled:__props.disabled},{default:withCtx(()=>[createTextVNode(toDisplayString(__props.showText?`${_ctx.$t(`ui.color.saturation`)} (${current.value.saturation}%)`:null),1)]),_:1},8,[`modelValue`,`fill`,`current`,`step`,`disabled`])):createCommentVNode(``,!0),opts.value.slider||opts.value.saturation?(openBlock(),createBlock(unref(bngColorSlider_default),{key:4,"X:vertical":`opts.picker`,modelValue:values.luminosity,"onUpdate:modelValue":_cache[2]||=$event=>values.luminosity=$event,modelModifiers:{number:!0},onChange:notify,fill:gradients.luminosity,current:`hsl(${current.value.hue}, ${current.value.saturation}%, ${current.value.luminosity}%)`,indicator:sliderIndicator,step:__props.step,disabled:__props.disabled},{default:withCtx(()=>[createTextVNode(toDisplayString(__props.showText?`${_ctx.$t(`ui.color.brightness`)} (${current.value.luminosity}%)`:null),1)]),_:1},8,[`modelValue`,`fill`,`current`,`step`,`disabled`])):createCommentVNode(``,!0)],2))}},bngColorPicker_default=__plugin_vue_export_helper_default(_sfc_main$379,[[`__scopeId`,`data-v-f4241405`]]),_hoisted_1$328={key:0},_hoisted_2$263=[`min`,`max`,`step`,`tabindex`,`orient`],_hoisted_3$230={key:0,class:`colour-slider-indicator-container`},_sfc_main$378={__name:`bngColorSlider`,props:{modelValue:{type:[Number,String],default:0},min:{type:Number,default:0},max:{type:Number,default:1},step:{type:Number,default:.001},fill:{type:Array,default:[`rgb(0,0,0)`,`rgb(255,255,255)`]},current:{type:String,default:null},vertical:Boolean,disabled:Boolean,indicator:{type:String,default:`inner`,validator:val=>[`inner`,`popout`].includes(val)},uiNavFocus:{type:[Boolean,Object],default:{},validator:val=>typeof val==`boolean`&&!val||typeof val==`object`}},emits:[`update:modelValue`,`change`],setup(__props,{emit:__emit}){let props=__props,elSlider=ref(),elIndicator=ref(),tabIndex=computed(()=>props.disabled?-1:0),value=ref(props.modelValue);watch(()=>props.modelValue,val=>value.value=Number(val));let indicatorPos=computed(()=>props.indicator===`popout`?(value.value-props.min)/(props.max-props.min):0),indicatorRot=computed(()=>{if(props.indicator!==`popout`||!elSlider.value||!elIndicator.value||!elSlider.value.getBoundingClientRect||!elIndicator.value.firstChild||!elIndicator.value.firstChild.getBoundingClientRect)return 0;let tilt=40,rot=0,srect=elSlider.value.getBoundingClientRect(),irect=elIndicator.value.firstChild.getBoundingClientRect(),abspos=indicatorPos.value*srect.width,iwidth=irect.width/2;return absposwithDirectives((openBlock(),createElementBlock(`div`,{ref_key:`elSlider`,ref:elSlider,class:`colour-slider`,style:normalizeStyle({"--colour-slider-track-fill":__props.fill&&__props.fill.length>0?`linear-gradient(90deg, ${__props.fill.join(`, `)})`:`transparent`,"--colour-slider-thumb-fill":__props.indicator===`inner`&&__props.current?__props.current:`#000`,"--colour-slider-thumb-size":__props.indicator===`inner`&&__props.current?`1em`:`0.25em`,"--colour-slider-indicator-x":`${indicatorPos.value*100}%`,"--colour-slider-indicator-r":`${indicatorRot.value}deg`})},[_ctx.$slots.default&&!__props.vertical?(openBlock(),createElementBlock(`span`,_hoisted_1$328,[renderSlot(_ctx.$slots,`default`,{},void 0,!0)])):createCommentVNode(``,!0),createBaseVNode(`div`,null,[withDirectives(createBaseVNode(`input`,{type:`range`,min:__props.min,max:__props.max,step:__props.step,"onUpdate:modelValue":_cache[0]||=$event=>value.value=$event,onInput:notify,onChange:notify,tabindex:tabIndex.value,class:normalizeClass({"colour-slider-vertical":__props.vertical}),orient:__props.vertical?`vertical`:`horizontal`},null,42,_hoisted_2$263),[[vModelText,value.value,void 0,{number:!0}],[unref(BngOnUiNavFocus_default),__props.uiNavFocus?{callback:(dir,val)=>{value.value=val,notify()},value:()=>value.value,min:__props.min,max:__props.max,step:()=>+__props.step,...__props.uiNavFocus}:!1,void 0,{repeat:!0}]]),__props.indicator===`popout`?(openBlock(),createElementBlock(`div`,_hoisted_3$230,[createBaseVNode(`div`,{ref_key:`elIndicator`,ref:elIndicator,class:`colour-slider-indicator`},[createVNode(unref(bngIconMarker_default),{marker:`circlePin`,color:[`#fff`,__props.current],class:`colour-slider-indicator-marker`},null,8,[`color`])],512)])):createCommentVNode(``,!0)])],4)),[[unref(BngDisabled_default),__props.disabled]])}},bngColorSlider_default=__plugin_vue_export_helper_default(_sfc_main$378,[[`__scopeId`,`data-v-346533a2`]]),_hoisted_1$327={class:`bng-color-tile`},_sfc_main$377={__name:`bngColorTile`,props:{red:{type:Number},blue:{type:Number},green:{type:Number},alpha:{type:Number,default:1}},setup(__props){useCssVars(_ctx=>({cef4bc4e:backgroundColor.value}));let props=__props,backgroundColor=computed(()=>`rgba(${props.red}, ${props.green}, ${props.blue}, ${props.alpha})`);return(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$327))}},bngColorTile_default=__plugin_vue_export_helper_default(_sfc_main$377,[[`__scopeId`,`data-v-32089404`]]),_sfc_main$376={__name:`bngCondition`,props:{integrity:{type:Number,default:1},integrityWarning:Boolean,color:{type:[String,Array],default:`#000`},showTooltip:Boolean},setup(__props){let props=__props,integrity=computed(()=>typeof props.integrity==`number`?Math.min(Math.max(props.integrity,0),1):1),tooltip=computed(()=>{if(!props.showTooltip)return;let tip=`${$translate.instant(`ui.condition.integrity`)}: ${~~(integrity.value*100)}%`;return props.integrityWarning&&(tip+=`\n${$translate.instant(`ui.condition.needsRepair`)}`),tip}),cssColour=computed(()=>{let clr=props.color;return Array.isArray(clr)?(clr=[...clr],clr.length>3&&(clr.splice(3),clr.some(c=>c>1)||(clr=clr.map(c=>c*255))),`rgb(${clr.join(`,`)})`):clr}),cssClipPoly=computed(()=>{let val=integrity.value,corners=[`100% 0%`,`100% 100%`,`0% 100%`,`0% 0%`],poly=`0% 0%`;if(val===1)poly=corners.join(`, `);else if(val>0){let deg=(1-val)*360,x=50+50*Math.sin(deg*Math.PI/180),y=50-50*Math.cos(deg*Math.PI/180);poly=`50% 0%, 50% 50%, ${~~x}% ${~~y}%, `+corners.slice(-Math.ceil((360-deg)/90)).join(`, `)}return poly});return(_ctx,_cache)=>withDirectives((openBlock(),createElementBlock(`div`,{class:normalizeClass({"bng-condition":!0,"cond-warn":__props.integrityWarning}),style:normalizeStyle({backgroundColor:cssColour.value,"--bng-condition-clip-path":`polygon(${cssClipPoly.value})`})},null,6)),[[unref(BngTooltip_default),tooltip.value]])}},bngCondition_default=__plugin_vue_export_helper_default(_sfc_main$376,[[`__scopeId`,`data-v-686a3067`]]),SCOPED_CHANGED_EVENT_NAME=`scopeChanged`,EVENT_CROSSFIRE_MAP={ok:`select`,back:`back`,tab_l:`tabLeft`,tab_r:`tabRight`};const CROSSFIRE_HINTS={select:{id:`select`,content:{type:`binding`,props:{uiEvent:`ok`},label:`Select`}},back:{id:`back`,content:{type:`binding`,props:{uiEvent:`back`},label:`Back`}},tabLeft:{id:`tabLeft`,content:{type:`binding`,props:{uiEvent:`tab_l`},label:`Tab left`}},tabRight:{id:`tabRight`,content:{type:`binding`,props:{uiEvent:`tab_r`},label:`Tab right`}}},CROSSFIRE_HINTS_ALL=Object.values(CROSSFIRE_HINTS),DEFAULT_LABELS={focus_u:`ui.inputActions.controllerui.focus_u.title`,focus_r:`ui.inputActions.controllerui.focus_r.title`,focus_d:`ui.inputActions.controllerui.focus_d.title`,focus_l:`ui.inputActions.controllerui.focus_l.title`,pause:`ui.inputActions.general.pause.title`,menu:`ui.inputActions.controllerui.menu.title`,back:`ui.inputActions.controllerui.back.title`,details:`ui.inputActions.controllerui.details.title`,advanced:`ui.inputActions.controllerui.advanced.title`,camera:`ui.inputActions.controllerui.camera.title`,logs:`ui.inputActions.controllerui.logs.title`,tab_l:`ui.inputActions.controllerui.tab_l.title`,tab_r:`ui.inputActions.controllerui.tab_r.title`,modifier:`ui.inputActions.controllerui.modifier.title`,zoom_out:`ui.inputActions.controllerui.zoom_out.title`,zoom_in:`ui.inputActions.controllerui.zoom_in.title`,subtab_l:`ui.inputActions.controllerui.subtab_l.title`,subtab_r:`ui.inputActions.controllerui.subtab_r.title`,center_cam:`ui.inputActions.controllerui.center_cam.title`,action_4:`ui.inputActions.controllerui.action_4.title`,move_ud:`ui.inputActions.controllerui.move_ud.title`,move_lr:`ui.inputActions.controllerui.move_lr.title`,focus_ud:`ui.inputActions.controllerui.focus_ud.title`,focus_lr:`ui.inputActions.controllerui.focus_lr.title`,rotate_h_cam:`ui.inputActions.controllerui.rotate_h_cam.title`,rotate_v_cam:`ui.inputActions.controllerui.rotate_v_cam.title`,ok:`ui.inputActions.controllerui.ok.title`,cancel:`ui.inputActions.controllerui.cancel.title`,action_2:`ui.inputActions.controllerui.action_2.title`,action_3:`ui.inputActions.controllerui.action_3.title`,context:`ui.inputActions.controllerui.context.title`};var HINT_GROUPS=()=>[{names:[`back`,`menu`],label:`ui.inputActions.controllerui.back.title`},{names:[`focus_u`,`focus_d`,`focus_r`,`focus_l`,`focus_lr`,`focus_ud`],label:`ui.mainmenu.navbar.navigate`,controllerOnly:!0},{names:[`focus_u`,`focus_d`,`focus_r`,`focus_l`],label:`ui.mainmenu.navbar.navigate`},{names:[`focus_lr`,`focus_ud`],label:`ui.mainmenu.navbar.navigate`,controllerOnly:!0},{names:[SCROLL_EVENT_H,SCROLL_EVENT_V],label:`ui.mainmenu.navbar.scroll_label`,controllerOnly:!0},{names:[`tab_r`,`tab_l`],label:`ui.mainmenu.navbar.navigate`,controllerOnly:!0}],AUTOID=`__auto`,AUTOIDS={binding:`${AUTOID}_binding`,group:`${AUTOID}_group`,labelGroup:`${AUTOID}_label_group`},DISPLAY_ACTION_VARIANTS=!1;const useInfoBar=defineStore(`infoBar`,()=>{let{events:events$3}=useBridge(),Controls=controls_default(),{isControllerUsed,lastDevice}=storeToRefs(Controls),hintGroups=HINT_GROUPS(),visible=ref(!1),showSysInfo=ref(!1),withAngular=ref(!1),hintsList=ref([]),hints=ref([]);watch([isControllerUsed,lastDevice],()=>_groupHints());let getControlGroup=(uiEvents,groupLabel)=>{try{let actions=uiEvents.map(event=>ACTIONS_BY_UI_EVENT[event]).filter(Boolean);if(actions.length!==uiEvents.length)return null;let viewerObjs=actions.map(action=>Controls.makeViewerObj({action,actionVariants:DISPLAY_ACTION_VARIANTS,useLastDevice:!0})).flatMap(vo=>vo?.variants?vo.variants:vo?[vo]:[]),matchingItems=[],devNames=viewerObjs.reduce((res,obj)=>obj&&!res.includes(obj.devName)?[...res,obj.devName]:res,[]);for(let devName of devNames){if(!devName)continue;let devViewerObjs=viewerObjs.filter(obj=>obj&&obj.devName===devName&&obj.ownGroups);if(devViewerObjs.length===0)continue;let groups=devViewerObjs[0].ownGroups,controls$1=devViewerObjs.map(obj=>obj.control);for(let group of groups){if(!group.controls.every(control=>controls$1.includes(control)))continue;controls$1=controls$1.filter(control=>!group.controls.includes(control));let item;item=group.label?{type:`binding`,props:{viewerObj:{icon:devViewerObjs[0].icon,ownLabel:group.label}},label:groupLabel}:{type:`icon`,props:{type:icons[group.icon]},label:groupLabel},matchingItems.push(item)}}return matchingItems.length===0?null:matchingItems.length===1?matchingItems[0]:matchingItems}catch(err){return logger_default.error(`Error in checkForControlGroup:`,err),null}},_groupHints=()=>{let res=[],groupCandidates={},labelGroups={},isCustomLabel=content=>content&&!content.autoLabel&&content?.props?.uiEvent&&content.label!==DEFAULT_LABELS[content?.props?.uiEvent];for(let hint of hintsList.value){let normalizedHint=hint.content?hint:{content:hint},{content}=normalizedHint;if(!content?.props?.uiEvent||!content.label){res.push(normalizedHint);continue}let labelKey=content.label;labelGroups[labelKey]?labelGroups[labelKey].hints.push(normalizedHint):labelGroups[labelKey]={hints:[normalizedHint],position:res.length}}let selectMatchingGroup=matchingGroups=>matchingGroups.length<1||isControllerUsed.value?matchingGroups[0]:matchingGroups.find(group=>!group.controllerOnly)||matchingGroups.at(-1);for(let[label,group]of Object.entries(labelGroups)){let action=group.hints[0].action;if(group.hints.length>1){let events$4=group.hints.map(h$1=>h$1.content.props.uiEvent),matchingGroup=selectMatchingGroup(hintGroups.filter(g=>g.content&&g.names.every(name=>events$4.includes(name))&&events$4.filter(e=>g.names.includes(e)).length===g.names.length));if(matchingGroup){if(matchingGroup.controllerOnly&&!isControllerUsed.value)continue;let groupContent=Array.isArray(matchingGroup.content)?matchingGroup.content[0]:matchingGroup.content,groupLabel=matchingGroup.label||groupContent?.label||group.hints[0]?.content?.label,groupEvents=group.hints.map(h$1=>h$1.content.props.uiEvent),labeledBindings=group.hints.map(h$1=>{let newContent={id:h$1.id,type:h$1.content.type,props:{...h$1.content.props}};return newContent.label=isCustomLabel(h$1.content)?h$1.content.label:groupLabel,newContent}),controlGroup=getControlGroup(groupEvents,groupLabel);if(controlGroup){let content=Array.isArray(controlGroup)?controlGroup.map(item=>({...item})):[{...controlGroup}],customLabelItem=group.hints.find(h$1=>isCustomLabel(h$1.content));customLabelItem&&content.forEach(item=>{item.label=customLabelItem.content.label}),res.splice(group.position,0,{id:`${AUTOIDS.labelGroup}_${label}`,content,action})}else res.splice(group.position,0,{id:`${AUTOIDS.labelGroup}_${label}`,content:labeledBindings,action})}else res.splice(group.position,0,{id:`${AUTOIDS.labelGroup}_${label}`,content:group.hints.map(h$1=>h$1.content),action})}else{let hint=group.hints[0],uiEvent=hint.content?.props?.uiEvent,isNoGroup=uiEvent$1=>uiNavTracker.activeEvents.find(e=>e.name===uiEvent$1)?.nogroup;if(isNoGroup(uiEvent)){res.push(hint);continue}let matchingGroup=selectMatchingGroup(hintGroups.filter(group$1=>group$1.names.includes(uiEvent)));if(!matchingGroup){res.push(hint);continue}let groupId=matchingGroup.names.join(`,`);groupId in groupCandidates||(groupCandidates[groupId]={hints:[],content:[],position:res.length});let groupCandidate=groupCandidates[groupId];if(groupCandidate.hints.push(hint),groupCandidate.content.push(hint.content),groupCandidate.hints.length===matchingGroup.names.length){if(matchingGroup.controllerOnly&&!isControllerUsed.value){delete groupCandidates[groupId];continue}if(groupCandidate.hints.some(h$1=>isNoGroup(h$1.content?.props?.uiEvent)))res.splice(groupCandidate.position,0,...groupCandidate.hints);else{let groupContent=Array.isArray(matchingGroup.content)?matchingGroup.content[0]:matchingGroup.content,groupLabel=matchingGroup.label||groupContent?.label||groupCandidate.hints[0]?.content?.label,labeledContent=groupCandidate.content.map(item=>{let newContent={id:item.id,type:item.type,props:{...item.props}};return isCustomLabel(item)?newContent.label=item.label:newContent.label=groupLabel,newContent}),controlGroup=getControlGroup(groupCandidate.hints.map(h$1=>h$1.content.props.uiEvent),groupLabel);if(controlGroup){let content=Array.isArray(controlGroup)?controlGroup.map(icon=>({...icon})):[{...controlGroup}],customLabelItem=groupCandidate.content.find(item=>isCustomLabel(item));customLabelItem&&content.forEach(icon=>icon.label=customLabelItem.label),res.splice(groupCandidate.position,0,{id:`${AUTOIDS.group}_${groupId}`,content,action})}else res.splice(groupCandidate.position,0,{id:`${AUTOIDS.group}_${groupId}`,content:labeledContent,action})}delete groupCandidates[groupId]}}}for(let group of Object.values(groupCandidates))res.splice(group.position,0,...group.hints);hints.value=res},uiNavTracker=useUINavTracker(),clearHints=()=>{hintsList.value=[],_addTrackedEvents()},addHints=(hintOrHints,idOrPos=void 0,before=!1)=>{if(hintOrHints===CROSSFIRE_HINTS_ALL){logger_default.warn(`Approach with CROSSFIRE_HINTS_ALL is deprecated and crossfire hints are added by default.`);return}let toAdd=[hintOrHints].flat().map(hint=>{if(typeof hint!=`object`)return hint;let content=hint.content||hint,uiEvent=content?.props?.uiEvent;return uiEvent&&(content.label||(content.autoLabel=!0,uiEvent in DEFAULT_LABELS?content.label=DEFAULT_LABELS[uiEvent]:content.label=uiEvent.replaceAll(`_`,` `).toUpperCase())),hint});if(idOrPos===void 0)hintsList.value=hintsList.value.concat(toAdd);else if(typeof idOrPos==`number`)hintsList.value.splice(idOrPos,0,...toAdd);else if(typeof idOrPos==`string`){let foundIndex=_findHintIndex(idOrPos);foundIndex>-1&&hintsList.value.splice(foundIndex+(before?0:1),0,...toAdd)}_groupHints()},updateHint=(idOrPos,updatedHint)=>{if(typeof idOrPos==`number`)hintsList.value[idOrPos]=updatedHint;else{let foundIndex=_findHintIndex(idOrPos);hintsList.value[foundIndex]=updatedHint}_groupHints()},removeHints=(...ids)=>{ids.forEach(id=>{let foundIndex=_findHintIndex(id);foundIndex>-1&&hintsList.value.splice(foundIndex,1)}),_groupHints()},flashHints=(...ids)=>{_setFlash(!1,ids),setTimeout(()=>_setFlash(!0,ids),0)},_setFlash=(state,ids)=>ids.forEach(id=>{let foundIndex=_findHintIndex(id);foundIndex>-1&&(hintsList.value[foundIndex].flash=state)}),highlightHints=(state,...ids)=>{},_findHintIndex=id=>hintsList.value.findIndex(h$1=>h$1.id===id);events$3.on(SCOPED_CHANGED_EVENT_NAME,data=>{logger_default.debug(`[infoBar] received data`,data),data&&(clearHints(),data.forEach(ev=>{let content;content=ev.label?{content:{type:`binding`,props:{uiEvent:ev.event},label:ev.label}}:CROSSFIRE_HINTS[EVENT_CROSSFIRE_MAP[ev.event]],addHints(content)}))});function _addTrackedEvents(){let activeEvents=uiNavTracker.activeEvents;hintsList.value=hintsList.value.filter(hint=>!hint.id?.startsWith(AUTOID)&&activeEvents.some(e=>e.name===hint.content.props.uiEvent));let currentBindings=hintsList.value.filter(hint=>hint.content?.type===`binding`).map(hint=>hint.content.props.uiEvent);addHints(activeEvents.filter(({name})=>!currentBindings.includes(name)).map(({name,label,nogroup,action})=>({id:`${AUTOIDS.binding}_${name}`,content:{type:`binding`,props:{uiEvent:name},label,autoLabel:!label||label===DEFAULT_LABELS[name]},nogroup,action})))}return watch(()=>uiNavTracker.activeEvents,_addTrackedEvents,{deep:!0}),{visible,hintsList,hints,showSysInfo,withAngular,clearHints,addHints,updateHint,removeHints,flashHints,highlightHints}});var _hoisted_1$326={key:0,xmlns:`http://www.w3.org/2000/svg`,viewBox:`20 140 460 220`},_hoisted_2$262={class:`bng-controller-hint-labels`},_hoisted_3$229={x:`120`,y:`165`,"text-anchor":`middle`},_hoisted_4$196={x:`120`,y:`335`,"text-anchor":`middle`},_hoisted_5$166={x:`45`,y:`255`,"text-anchor":`end`},_hoisted_6$142={x:`175`,y:`255`,"text-anchor":`start`},_hoisted_7$124={x:`219`,y:`315`,"text-anchor":`middle`},_hoisted_8$102={x:`249`,y:`315`,"text-anchor":`middle`},_hoisted_9$92={x:`340`,y:`175`,"text-anchor":`middle`},_hoisted_10$80={x:`380`,y:`335`,"text-anchor":`middle`},_sfc_main$375={__name:`bngControllerHint`,props:{device:String,actions:[Array,String],dark:Boolean},setup(__props,{expose:__expose}){let Controls=controls_default(),props=__props,available=[`xbox`],devName=computed(()=>{if(!props.device)return Controls.lastDevice;let devName$1=props.device;return/\d$/.test(devName$1)||(devName$1=Controls.lastDevices.find(dev=>dev.startsWith(devName$1)),devName$1||=props.device+`0`),devName$1}),devFamily=computed(()=>{let family=Controls.makeViewerObj({device:devName.value,uiEvent:`back`})?.family;return!family||!available.includes(family)?null:family});__expose({displayed:computed(()=>!!devFamily.value)});let actions=computed(()=>{let actions$1=props.actions;if(!actions$1||!devFamily.value)return{};if(typeof actions$1==`string`)actions$1=[actions$1];else if(!Array.isArray(actions$1)||actions$1.length===0)return{};let bindings={},allEvents=Object.keys(ACTIONS_BY_UI_EVENT),allActions=Object.values(ACTIONS_BY_UI_EVENT);for(let action of actions$1){if(!action)continue;let item=action;if(typeof item==`string`)item={action:item};else if(!item.action&&!item.event)continue;else item={...item};let actIdx=allEvents.indexOf(item.event||item.action);if(actIdx>-1&&(item.event=allEvents[actIdx],item.action=allActions[actIdx]),!allActions.includes(item.action))continue;let binding=Controls.findBindingForAction(item.action,devName.value);if(binding){if(!item.event||item.event===item.action){let idx=allActions.indexOf(item.action);idx>-1&&(item.event=allEvents[idx])}item.label||=DEFAULT_LABELS[item.event]||item.event||item.action,item.shown=!0,item.class={flash:item.flash},bindings[binding.control.toLowerCase()]=item}}logger_default.debug(`resolved actions:`,bindings);for(let keyName of DEVICE_CONTROLS[devFamily.value]){let key=keyName.toLowerCase();key in bindings||(bindings[key]={class:{inactive:!0}})}return bindings});return(_ctx,_cache)=>devFamily.value?(openBlock(),createElementBlock(`div`,{key:0,class:normalizeClass([`bng-controller-hint`,{"bng-controller-hint-dark":__props.dark}])},[devFamily.value===`xbox`?(openBlock(),createElementBlock(`svg`,_hoisted_1$326,[_cache[8]||=createBaseVNode(`rect`,{x:`60`,y:`180`,width:`380`,height:`140`,rx:`20`,fill:`#bcbcbc`,stroke:`#333`,"stroke-width":`8`},null,-1),_cache[9]||=createBaseVNode(`circle`,{cx:`120`,cy:`250`,r:`28`,fill:`#222`},null,-1),createBaseVNode(`rect`,{class:normalizeClass(actions.value.upov.class),x:`114`,y:`222`,width:`12`,height:`20`,rx:`3`,fill:`#444`},null,2),createBaseVNode(`rect`,{class:normalizeClass(actions.value.dpov.class),x:`114`,y:`258`,width:`12`,height:`20`,rx:`3`,fill:`#444`},null,2),createBaseVNode(`rect`,{class:normalizeClass(actions.value.lpov.class),x:`98`,y:`242`,width:`20`,height:`12`,rx:`3`,fill:`#444`},null,2),createBaseVNode(`rect`,{class:normalizeClass(actions.value.rpov.class),x:`122`,y:`242`,width:`20`,height:`12`,rx:`3`,fill:`#444`},null,2),createBaseVNode(`rect`,{class:normalizeClass(actions.value.btn_start.class),x:`210`,y:`240`,width:`18`,height:`10`,rx:`3`,fill:`#888`},null,2),createBaseVNode(`rect`,{class:normalizeClass(actions.value.btn_back.class),x:`240`,y:`240`,width:`18`,height:`10`,rx:`3`,fill:`#888`},null,2),createBaseVNode(`circle`,{class:normalizeClass(actions.value.btn_a.class),cx:`340`,cy:`230`,r:`18`,fill:`#22a`},null,2),createBaseVNode(`circle`,{class:normalizeClass(actions.value.btn_b.class),cx:`380`,cy:`270`,r:`18`,fill:`#22a`},null,2),createBaseVNode(`g`,_hoisted_2$262,[actions.value.upov?.shown?(openBlock(),createElementBlock(Fragment,{key:0},[_cache[0]||=createBaseVNode(`line`,{x1:`120`,y1:`202`,x2:`120`,y2:`170`,stroke:`#666`,"stroke-width":`2`},null,-1),createBaseVNode(`text`,_hoisted_3$229,toDisplayString(_ctx.$tt(actions.value.upov?.label)),1)],64)):createCommentVNode(``,!0),actions.value.dpov?.shown?(openBlock(),createElementBlock(Fragment,{key:1},[_cache[1]||=createBaseVNode(`line`,{x1:`120`,y1:`298`,x2:`120`,y2:`320`,stroke:`#666`,"stroke-width":`2`},null,-1),createBaseVNode(`text`,_hoisted_4$196,toDisplayString(_ctx.$tt(actions.value.dpov?.label)),1)],64)):createCommentVNode(``,!0),actions.value.lpov?.shown?(openBlock(),createElementBlock(Fragment,{key:2},[_cache[2]||=createBaseVNode(`line`,{x1:`78`,y1:`250`,x2:`50`,y2:`250`,stroke:`#666`,"stroke-width":`2`},null,-1),createBaseVNode(`text`,_hoisted_5$166,toDisplayString(_ctx.$tt(actions.value.lpov?.label)),1)],64)):createCommentVNode(``,!0),actions.value.rpov?.shown?(openBlock(),createElementBlock(Fragment,{key:3},[_cache[3]||=createBaseVNode(`line`,{x1:`142`,y1:`250`,x2:`170`,y2:`250`,stroke:`#666`,"stroke-width":`2`},null,-1),createBaseVNode(`text`,_hoisted_6$142,toDisplayString(_ctx.$tt(actions.value.rpov?.label)),1)],64)):createCommentVNode(``,!0),actions.value.btn_start?.shown?(openBlock(),createElementBlock(Fragment,{key:4},[_cache[4]||=createBaseVNode(`line`,{x1:`219`,y1:`270`,x2:`219`,y2:`300`,stroke:`#666`,"stroke-width":`2`},null,-1),createBaseVNode(`text`,_hoisted_7$124,toDisplayString(_ctx.$tt(actions.value.btn_start?.label)),1)],64)):createCommentVNode(``,!0),actions.value.btn_back?.shown?(openBlock(),createElementBlock(Fragment,{key:5},[_cache[5]||=createBaseVNode(`line`,{x1:`249`,y1:`270`,x2:`249`,y2:`300`,stroke:`#666`,"stroke-width":`2`},null,-1),createBaseVNode(`text`,_hoisted_8$102,toDisplayString(_ctx.$tt(actions.value.btn_back?.label)),1)],64)):createCommentVNode(``,!0),actions.value.btn_a?.shown?(openBlock(),createElementBlock(Fragment,{key:6},[_cache[6]||=createBaseVNode(`line`,{x1:`340`,y1:`212`,x2:`340`,y2:`180`,stroke:`#666`,"stroke-width":`2`},null,-1),createBaseVNode(`text`,_hoisted_9$92,toDisplayString(_ctx.$tt(actions.value.btn_a?.label)),1)],64)):createCommentVNode(``,!0),actions.value.btn_b?.shown?(openBlock(),createElementBlock(Fragment,{key:7},[_cache[7]||=createBaseVNode(`line`,{x1:`380`,y1:`288`,x2:`380`,y2:`320`,stroke:`#666`,"stroke-width":`2`},null,-1),createBaseVNode(`text`,_hoisted_10$80,toDisplayString(_ctx.$tt(actions.value.btn_b?.label)),1)],64)):createCommentVNode(``,!0)])])):createCommentVNode(``,!0)],2)):createCommentVNode(``,!0)}},bngControllerHint_default=__plugin_vue_export_helper_default(_sfc_main$375,[[`__scopeId`,`data-v-bb01f791`]]),_sfc_main$374={},_hoisted_1$325={class:`divider vertical-divider`};function _sfc_render$6(_ctx,_cache){return openBlock(),createElementBlock(`div`,_hoisted_1$325)}var bngDivider_default=__plugin_vue_export_helper_default(_sfc_main$374,[[`render`,_sfc_render$6],[`__scopeId`,`data-v-c3fbf7df`]]),_sfc_main$373={__name:`bngDrawer`,props:mergeModels({header:String,blur:Boolean,expandable:{type:Boolean,default:!0},position:String},{modelValue:{type:Boolean},modelModifiers:{}}),emits:mergeModels([`change`],[`update:modelValue`]),setup(__props,{emit:__emit}){let props=__props,emit$1=__emit,slots=useSlots(),arrows=computed(()=>{switch(props.position){default:case DRAWER_POSITION.bottom:case DRAWER_POSITION.right:return{expand:icons.arrowLargeUp,collapse:icons.arrowLargeDown};case DRAWER_POSITION.top:case DRAWER_POSITION.left:return{expand:icons.arrowLargeDown,collapse:icons.arrowLargeUp}}}),expanded=useModel(__props,`modelValue`);return watch(()=>expanded.value,val=>emit$1(`change`,val)),watch([()=>props.expandable,()=>expanded.value],()=>!props.expandable&&expanded.value&&(expanded.value=!1),{immediate:!0}),(_ctx,_cache)=>(openBlock(),createBlock(unref(drawer_default),{modelValue:expanded.value,"onUpdate:modelValue":_cache[1]||=$event=>expanded.value=$event,blur:__props.blur,position:__props.position},createSlots({header:withCtx(()=>[createVNode(unref(bngCardHeading_default),{class:`header`,type:`ribbon`,style:normalizeStyle({marginRight:!__props.header&&!unref(slots).header?`0`:void 0})},{default:withCtx(()=>[__props.header?(openBlock(),createElementBlock(Fragment,{key:0},[createTextVNode(toDisplayString(__props.header),1)],64)):renderSlot(_ctx.$slots,`header`,{key:1},()=>[_cache[2]||=createBaseVNode(`span`,null,null,-1)],!0)]),_:3},8,[`style`]),renderSlot(_ctx.$slots,`header-controls`,{},void 0,!0),__props.expandable?(openBlock(),createBlock(unref(bngButton_default),{key:0,accent:`text`,icon:expanded.value?arrows.value.collapse:arrows.value.expand,onClick:_cache[0]||=$event=>expanded.value=!expanded.value},null,8,[`icon`])):createCommentVNode(``,!0)]),_:2},[`content`in unref(slots)?{name:`content`,fn:withCtx(()=>[renderSlot(_ctx.$slots,`content`,{},void 0,!0)]),key:`0`}:void 0,`expanded-content`in unref(slots)?{name:`expanded-content`,fn:withCtx(()=>[renderSlot(_ctx.$slots,`expanded-content`,{},void 0,!0)]),key:`1`}:`default`in unref(slots)?{name:`expanded-content`,fn:withCtx(()=>[renderSlot(_ctx.$slots,`default`,{},void 0,!0)]),key:`2`}:void 0]),1032,[`modelValue`,`blur`,`position`]))}},bngDrawer_default=__plugin_vue_export_helper_default(_sfc_main$373,[[`__scopeId`,`data-v-30948d98`]]),_hoisted_1$324={class:`bng-drawer`},_hoisted_2$261={class:`header-wrapper`},_hoisted_3$228={class:`content`},_sfc_main$372={__name:`bngDrawerOld`,props:{header:{type:String},blur:{type:Boolean,default:!1}},setup(__props){return(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$324,[withDirectives((openBlock(),createElementBlock(`div`,_hoisted_2$261,[createVNode(unref(bngCardHeading_default),{class:`header`,type:`ribbon`},{default:withCtx(()=>[__props.header?(openBlock(),createElementBlock(Fragment,{key:0},[createTextVNode(toDisplayString(__props.header),1)],64)):renderSlot(_ctx.$slots,`header`,{key:1},void 0,!0)]),_:3}),renderSlot(_ctx.$slots,`headerOptions`,{},void 0,!0)])),[[unref(BngBlur_default),__props.blur]]),withDirectives((openBlock(),createBlock(unref(bngCard_default),null,{default:withCtx(()=>[createBaseVNode(`div`,_hoisted_3$228,[renderSlot(_ctx.$slots,`content`,{},void 0,!0)])]),_:3})),[[unref(BngBlur_default),__props.blur]])]))}},bngDrawerOld_default=__plugin_vue_export_helper_default(_sfc_main$372,[[`__scopeId`,`data-v-9e5c32b1`]]),_hoisted_1$323={class:`dropdown-display`},_hoisted_2$260={key:0,class:`dropdown-search`},_hoisted_3$227={key:1},_hoisted_4$195={key:0,class:`dropdown-group-header`},_hoisted_5$165=[`bng-nav-item`,`tabindex`,`bng-scoped-nav-autofocus`,`onClick`,`onKeyup`],_sfc_main$371={__name:`bngDropdown`,props:{modelValue:{type:[Number,String,Boolean,Object]},items:{type:Array,required:!0},showSearch:Boolean,highlight:{type:[String,Array,RegExp]},disabled:Boolean,longNames:{type:String,default:`oneline`,validator:val=>[`oneline`,`wrap`,`cut`].includes(val)},searchGroupName:Boolean,headless:Boolean,focusTarget:Object,popoverTarget:Object},emits:[`update:modelValue`,`valueChanged`,`open`,`close`],setup(__props,{expose:__expose,emit:__emit}){let attrs=useAttrs(),binds=computed(()=>props.headless?void 0:attrs),props=__props,emit$1=__emit,elContainer=ref(null),opened=ref(!1),searching=ref(!1),search$1=ref(``),searchTerm=computed(()=>search$1.value.toLowerCase());watch(opened,val=>!val&&(search$1.value=``)),__expose({opened,open:()=>opened.value=!0,close:()=>opened.value=!1,toggle:()=>opened.value=!opened.value,get popoverName(){return elContainer.value?.popoverName}});let groupedItems=computed(()=>{let hasGrouping=props.items.some(item=>item.group||item.grouped),searchActive=!!searchTerm.value;if(!hasGrouping)return[{header:null,items:searchActive?props.items.filter(item=>item.label.toLowerCase().includes(searchTerm.value)):props.items}];let groups=[],currentGroup=null;return props.items.forEach(item=>{item.group?(currentGroup={header:item,allItems:[],_headerMatches:item.label.toLowerCase().includes(searchTerm.value)},groups.push(currentGroup)):item.grouped?currentGroup?currentGroup.allItems.push(item):groups.push({header:null,allItems:[item]}):(groups.push({header:null,allItems:[item]}),currentGroup=null)}),groups.map(group=>{if(searchActive)if(group.header){if(props.searchGroupName&&group._headerMatches)return{header:group.header,items:group.allItems,headerMatches:!0};{let filteredItems=group.allItems.filter(item=>item.label.toLowerCase().includes(searchTerm.value));return{header:group.header,items:filteredItems,headerMatches:!1}}}else return{header:null,items:group.allItems.filter(item=>item.label.toLowerCase().includes(searchTerm.value))};else return{header:group.header||null,items:group.allItems}}).filter(group=>group.header&&props.searchGroupName&&group.headerMatches||group.items.length>0)}),highlighter$1=computed(()=>search$1.value||props.highlight),selectedValue=computed({get:()=>props.modelValue,set:newValue=>{emit$1(`update:modelValue`,newValue),emit$1(`valueChanged`,newValue)}}),selectedItem=computed(()=>props.items.find(x=>x.value===selectedValue.value)),headerText=computed(()=>selectedItem.value&&selectedItem.value.value!==null&&selectedItem.value.value!==void 0?selectedItem.value.label:`Select`),tabIndexValue=computed(()=>props.disabled?-1:0),select=item=>{item.disabled||(opened.value=!1,selectedValue.value!==item.value&&(selectedValue.value=item.value),elContainer.value?.focusContainer())};return(_ctx,_cache)=>(openBlock(),createBlock(unref(bngDropdownContainer_default),mergeProps({ref_key:`elContainer`,ref:elContainer},binds.value,{opened:opened.value,"onUpdate:opened":_cache[3]||=$event=>opened.value=$event,disabled:__props.disabled,headless:__props.headless,"focus-target":__props.focusTarget,"popover-target":__props.popoverTarget,class:{"with-search":__props.showSearch,[`dropdown-longnames-${__props.longNames}`]:!0},onShow:_cache[4]||=$event=>emit$1(`open`),onHide:_cache[5]||=$event=>emit$1(`close`)}),createSlots({default:withCtx(()=>[__props.showSearch?(openBlock(),createElementBlock(`div`,_hoisted_2$260,[createVNode(unref(bngInput_default),{modelValue:search$1.value,"onUpdate:modelValue":_cache[0]||=$event=>search$1.value=$event,modelModifiers:{trim:!0},"floating-label":`Search`,onFocus:_cache[1]||=$event=>searching.value=!0,onBlur:_cache[2]||=$event=>searching.value=!1},null,8,[`modelValue`])])):createCommentVNode(``,!0),search$1.value&&groupedItems.value.every(group=>group.items.length===0)?(openBlock(),createElementBlock(`div`,_hoisted_3$227,toDisplayString(_ctx.$t(`ui.common.search.noResults`)),1)):(openBlock(!0),createElementBlock(Fragment,{key:2},renderList(groupedItems.value,(group,groupIndex)=>(openBlock(),createElementBlock(Fragment,{key:groupIndex},[group.header?(openBlock(),createElementBlock(`div`,_hoisted_4$195,toDisplayString(group.header.label),1)):createCommentVNode(``,!0),(openBlock(!0),createElementBlock(Fragment,null,renderList(group.items,(item,idx)=>withDirectives((openBlock(),createElementBlock(`div`,{key:item.value,class:normalizeClass([`dropdown-option`,{selected:selectedItem.value&&selectedItem.value.value===item.value,"grouped-item":group.header,disabled:item.disabled}]),"bng-nav-item":!item.disabled||item.focusable,tabindex:item.disabled?-1:tabIndexValue.value,"bng-scoped-nav-autofocus":!item.disabled&&!searching.value&&(selectedItem.value&&selectedItem.value.value===item.value||!selectedItem.value&&groupIndex===0&&idx===0),onClick:$event=>select(item),onKeyup:withKeys($event=>select(item),[`enter`])},[createTextVNode(toDisplayString(item.label),1)],42,_hoisted_5$165)),[[unref(BngOnUiNav_default),void 0,`ok`,{asMouse:!0,focusRequired:!0}],[unref(BngUiNavLabel_default),`ui.inputActions.menu.menu_item_select.title`,`ok`],[unref(BngTooltip_default),item.tooltip??void 0],[unref(BngHighlighter_default),highlighter$1.value]])),128))],64))),128))]),_:2},[__props.headless?void 0:{name:`display`,fn:withCtx(()=>[renderSlot(_ctx.$slots,`display`,{},()=>[withDirectives((openBlock(),createElementBlock(`span`,_hoisted_1$323,[createTextVNode(toDisplayString(headerText.value),1)])),[[unref(BngHighlighter_default),highlighter$1.value]])],!0)]),key:`0`}]),1040,[`opened`,`disabled`,`headless`,`focus-target`,`popover-target`,`class`]))}},bngDropdown_default=__plugin_vue_export_helper_default(_sfc_main$371,[[`__scopeId`,`data-v-96e56708`]]),popoverBaseName=`bng-dropdown-content`,_sfc_main$370=Object.assign({inheritAttrs:!1},{__name:`bngDropdownContainer`,props:mergeModels({disabled:Boolean,class:[String,Array,Object],headless:Boolean,focusTarget:Object,popoverTarget:Object},{opened:{},openedModifiers:{}}),emits:mergeModels([`provideFocus`,`show`,`hide`],[`update:opened`]),setup(__props,{expose:__expose,emit:__emit}){let navBlocker=useUINavBlocker(),props=__props,attrs=useAttrs(),binds=computed(()=>({...attrs,tabindex:props.headless?-1:0,"bng-nav-item":props.headless?void 0:``})),opened=useModel(__props,`opened`);function open$1(val){opened.value=val,val?(navBlocker.allowOnly([`focus_u`,`focus_d`,`focus_ud`,`back`,`menu`,`ok`]),emit$1(`show`)):(navBlocker.clear(),emit$1(`hide`),focusTarget.value&&setFocusExternal(focusTarget.value,!0,!1))}let emit$1=__emit,popover=usePopover(),popoverName=uniqueId(popoverBaseName),container=ref(null),content=ref(null),focusTarget=computed(()=>props.focusTarget||container.value),popoverTarget=computed(()=>props.popoverTarget||container.value),placement=ref(`bottom-start`),openedTop=computed(()=>placement.value.startsWith(`top`));return watch(()=>opened.value,value=>{value?(Object.keys(popover.popovers).filter(name=>popover.popovers[name].show&&name!==popoverName&&!popover.popovers[name].element.contains(popover.popovers[popoverName].target)).forEach(name=>popover.hide(name)),!popover.popovers[popoverName].show&&popoverTarget.value&&popover.show(popoverName,popoverTarget.value)):popover.hide(popoverName)}),__expose({opened,open:()=>opened.value=!0,close:()=>opened.value=!1,toggle:()=>opened.value=!opened.value,focusContainer:()=>focusTarget.value&&setFocusExternal(focusTarget.value),popoverName}),(_ctx,_cache)=>(openBlock(),createElementBlock(Fragment,null,[__props.headless?createCommentVNode(``,!0):withDirectives((openBlock(),createElementBlock(`div`,mergeProps({key:0,ref_key:`container`,ref:container},binds.value,{class:[`bng-dropdown`,props.class]}),[createVNode(unref(bngIcon_default),{type:unref(icons).arrowSmallRight,class:normalizeClass({"dropdown-arrow":!0,"dropdown-arrow-top":openedTop.value,opened:opened.value})},null,8,[`type`,`class`]),renderSlot(_ctx.$slots,`display`,{},()=>[_cache[8]||=createTextVNode(`Select`,-1)],!0)],16)),[[unref(BngDisabled_default),__props.disabled],[unref(BngOnUiNav_default),void 0,`ok`,{asMouse:!0,focusRequired:!0}],[unref(BngPopover_default),unref(popoverName),`bottom-start`,{click:!0}]]),createVNode(unref(bngPopoverContent_default),{name:unref(popoverName),onShow:_cache[5]||=$event=>open$1(!0),onHide:_cache[6]||=$event=>open$1(!1),"hide-arrow":``,onPlacementChanged:_cache[7]||=value=>placement.value=value},{default:withCtx(()=>[withDirectives((openBlock(),createElementBlock(`div`,{ref_key:`content`,ref:content,class:normalizeClass([`bng-dropdown-content`,__props.class]),"bng-nav-scroll":``,onClick:_cache[0]||=withModifiers(()=>{},[`stop`]),onMouseover:_cache[1]||=withModifiers(()=>{},[`stop`]),onMouseenter:_cache[2]||=withModifiers(()=>{},[`stop`]),onMousedown:_cache[3]||=withModifiers(()=>{},[`stop`]),onMouseup:_cache[4]||=withModifiers(()=>{},[`stop`])},[opened.value?renderSlot(_ctx.$slots,`default`,{key:0},void 0,!0):createCommentVNode(``,!0)],34)),[[unref(BngAutoScroll_default),void 0,`top`],[unref(BngUiNavLabel_default),`ui.common.close`,`back,menu`],[unref(BngUiNavLabel_default),`ui.mainmenu.navbar.navigate`,`focus_u,focus_d`],[unref(BngUiNavScroll_default)],[unref(BngOnUiNav_default),()=>open$1(!1),`menu`]])]),_:3},8,[`name`])],64))}}),bngDropdownContainer_default=__plugin_vue_export_helper_default(_sfc_main$370,[[`__scopeId`,`data-v-840dc960`]]),icons$2=Object.freeze({"4WD":{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/4WD.svg`},"9dividedby10":{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/9dividedby10.svg`},abandon:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/abandon.svg`},ABSIndicator:{glyph:``,size:24,tags:[`vehicle`,`features`,`warning`,`internals`],fileSvg:`svg/ABSIndicator.svg`},addItemPolygon:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`,`road tools`],fileSvg:`svg/addItemPolygon.svg`},addListItem:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`,`road tools`],fileSvg:`svg/addListItem.svg`},addPolygonVertex:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`,`road tools`],fileSvg:`svg/addPolygonVertex.svg`},adjust:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/adjust.svg`},AIMicrochip:{glyph:``,size:24,tags:[`generic`,`ai`,`microchip`],fileSvg:`svg/AIMicrochip.svg`},AIRace:{glyph:``,size:24,tags:[`poi`],fileSvg:`svg/AIRace.svg`},aperture:{glyph:``,size:24,tags:[`generic`,`camera`,`optical`,`sensor`],fileSvg:`svg/aperture.svg`},arrowLargeDown:{glyph:``,size:24,tags:[`arrow`,`large`,`simple`,`outlined`],fileSvg:`svg/arrowLargeDown.svg`},arrowLargeLeft:{glyph:``,size:24,tags:[`arrow`,`large`,`simple`,`outlined`],fileSvg:`svg/arrowLargeLeft.svg`},arrowLargeRight:{glyph:``,size:24,tags:[`arrow`,`large`,`simple`,`outlined`],fileSvg:`svg/arrowLargeRight.svg`},arrowLargeUp:{glyph:``,size:24,tags:[`arrow`,`large`,`simple`,`outlined`],fileSvg:`svg/arrowLargeUp.svg`},arrowSmallDown:{glyph:``,size:24,tags:[`arrow`,`small`,`simple`,`outlined`],fileSvg:`svg/arrowSmallDown.svg`},arrowSmallLeft:{glyph:``,size:24,tags:[`arrow`,`small`,`simple`,`outlined`],fileSvg:`svg/arrowSmallLeft.svg`},arrowSmallRight:{glyph:``,size:24,tags:[`arrow`,`small`,`simple`,`outlined`],fileSvg:`svg/arrowSmallRight.svg`},arrowSmallUp:{glyph:``,size:24,tags:[`arrow`,`small`,`simple`,`outlined`],fileSvg:`svg/arrowSmallUp.svg`},arrowSolidLeft:{glyph:``,size:24,tags:[`arrow`,`large`,`solid`,`detailed`],fileSvg:`svg/arrowSolidLeft.svg`},arrowSolidRight:{glyph:``,size:24,tags:[`arrow`,`large`,`solid`,`detailed`],fileSvg:`svg/arrowSolidRight.svg`},autobahn:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/autobahn.svg`},AWD:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/AWD.svg`},axleLift:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/axleLift.svg`},axleCenter:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/axleCenter.svg`},axleFront:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/axleFront.svg`},axleRear:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/axleRear.svg`},bSpline:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`,`road tools`],fileSvg:`svg/bSpline.svg`},banknotes:{glyph:``,size:24,tags:[`career`,`currencies`],fileSvg:`svg/banknotes.svg`},barrelKnocker01:{glyph:``,size:24,tags:[`poi`],fileSvg:`svg/barrelKnocker01.svg`},barrelKnocker02:{glyph:``,size:24,tags:[`poi`],fileSvg:`svg/barrelKnocker02.svg`},beamCrashBarrier1:{glyph:``,size:24,tags:[`generic`,`world editor`,`we`,`road tools`],fileSvg:`svg/beamCrashBarrier1.svg`},beamCrashBarrier2:{glyph:``,size:24,tags:[`generic`,`world editor`,`we`,`road tools`],fileSvg:`svg/beamCrashBarrier2.svg`},beamCrashBarrier3:{glyph:``,size:24,tags:[`generic`,`world editor`,`we`,`road tools`],fileSvg:`svg/beamCrashBarrier3.svg`},beamCurrency:{glyph:``,size:24,tags:[`career`,`currencies`],fileSvg:`svg/beamCurrency.svg`},beamNG:{glyph:``,size:24,tags:[`brand`,`beamng`,`generic`],fileSvg:`svg/beamNG.svg`},beamXPFull:{glyph:``,size:24,tags:[`career`,`currencies`],fileSvg:`svg/beamXPFull.svg`},beamXPLo:{glyph:``,size:24,tags:[`career`,`currencies`],fileSvg:`svg/beamXPLo.svg`},bezierPath1:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`,`road tools`],fileSvg:`svg/bezierPath1.svg`},bezierPath2:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`,`road tools`],fileSvg:`svg/bezierPath2.svg`},bicycle1:{glyph:``,size:24,tags:[`generic`,`world editor`,`we`,`road tools`],fileSvg:`svg/bicycle1.svg`},bicycle2:{glyph:``,size:24,tags:[`generic`,`world editor`,`we`,`road tools`],fileSvg:`svg/bicycle2.svg`},BNGFolder:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/BNGFolder.svg`},BNGMicrochip:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/BNGMicrochip.svg`},bollard:{glyph:``,size:24,tags:[`generic`,`world editor`,`we`,`road tools`],fileSvg:`svg/bollard.svg`},bookmark:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/bookmark.svg`},booleanIntersect:{glyph:``,size:24,tags:[`decals`,`generic`],fileSvg:`svg/booleanIntersect.svg`},boxDropOff01:{glyph:``,size:24,tags:[`poi`,`delivery`],fileSvg:`svg/boxDropOff01.svg`},boxDropOff02:{glyph:``,size:24,tags:[`poi`,`delivery`],fileSvg:`svg/boxDropOff02.svg`},boxDropOff03:{glyph:``,size:24,tags:[`poi`,`delivery`],fileSvg:`svg/boxDropOff03.svg`},boxPickUp01:{glyph:``,size:24,tags:[`poi`,`delivery`],fileSvg:`svg/boxPickUp01.svg`},boxPickUp02:{glyph:``,size:24,tags:[`poi`,`delivery`],fileSvg:`svg/boxPickUp02.svg`},boxPickUp03:{glyph:``,size:24,tags:[`poi`,`delivery`],fileSvg:`svg/boxPickUp03.svg`},boxPickUpDropOff01:{glyph:``,size:24,tags:[`poi`,`delivery`],fileSvg:`svg/boxPickUpDropOff01.svg`},boxPickUpDropOff02:{glyph:``,size:24,tags:[`poi`,`delivery`],fileSvg:`svg/boxPickUpDropOff02.svg`},boxTruck:{glyph:``,size:24,tags:[`cargo`,`delivery`,`vehicle`],fileSvg:`svg/boxTruck.svg`},broom:{glyph:``,size:24,tags:[`generic`,`sound`],fileSvg:`svg/broom.svg`},bucketAdd:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/bucketAdd.svg`},bucketSubtract:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/bucketSubtract.svg`},bug:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/bug.svg`},bulldozer:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`,`road tools`],fileSvg:`svg/bulldozer.svg`},bus:{glyph:``,size:24,tags:[`poi`,`vehicle`],fileSvg:`svg/bus.svg`},camera3Fourth1:{glyph:``,size:24,tags:[`camera`],fileSvg:`svg/camera3Fourth1.svg`},cameraBack1:{glyph:``,size:24,tags:[`camera`],fileSvg:`svg/cameraBack1.svg`},cameraFocusOnPath:{glyph:``,size:24,tags:[`camera`],fileSvg:`svg/cameraFocusOnPath.svg`},cameraFocusOnVehicle1:{glyph:``,size:24,tags:[`camera`],fileSvg:`svg/cameraFocusOnVehicle1.svg`},cameraFocusOnVehicle2:{glyph:``,size:24,tags:[`camera`,`decals`],fileSvg:`svg/cameraFocusOnVehicle2.svg`},cameraFocusTopDown:{glyph:``,size:24,tags:[`camera`],fileSvg:`svg/cameraFocusTopDown.svg`},cameraFront1:{glyph:``,size:24,tags:[`camera`],fileSvg:`svg/cameraFront1.svg`},cameraSideLeft:{glyph:``,size:24,tags:[`camera`],fileSvg:`svg/cameraSideLeft.svg`},cameraSideLeft2:{glyph:``,size:24,tags:[`camera`],fileSvg:`svg/cameraSideLeft2.svg`},cameraSideRight:{glyph:``,size:24,tags:[`camera`],fileSvg:`svg/cameraSideRight.svg`},cameraSideRight2:{glyph:``,size:24,tags:[`camera`],fileSvg:`svg/cameraSideRight2.svg`},cameraTop1:{glyph:``,size:24,tags:[`camera`],fileSvg:`svg/cameraTop1.svg`},cannon:{glyph:``,size:24,tags:[`poi`],fileSvg:`svg/cannon.svg`},carChase01:{glyph:``,size:24,tags:[`generic`,`police`,`vehicle`],fileSvg:`svg/carChase01.svg`},carCoin:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/carCoin.svg`},carCoins:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/carCoins.svg`},carCrash:{glyph:``,size:24,tags:[`generic`,`vehicle`],fileSvg:`svg/carCrash.svg`},carDealer:{glyph:``,size:24,tags:[`career`,`garage`,`features`],fileSvg:`svg/carDealer.svg`},carOffroadOutlineRear:{glyph:``,size:24,tags:[`generic`,`vehicle`],fileSvg:`svg/carOffroadOutlineRear.svg`},carOffroadOutlineSide:{glyph:``,size:24,tags:[`generic`,`vehicle`],fileSvg:`svg/carOffroadOutlineSide.svg`},carOffroadRear:{glyph:``,size:24,tags:[`generic`,`vehicle`],fileSvg:`svg/carOffroadRear.svg`},carOffroadSide:{glyph:``,size:24,tags:[`generic`,`vehicle`],fileSvg:`svg/carOffroadSide.svg`},carSensors:{glyph:``,size:24,tags:[`generic`,`vehicle`,`sensors`],fileSvg:`svg/carSensors.svg`},carStarred:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/carStarred.svg`},carToWheels:{glyph:``,size:24,tags:[`generic`,`vehicle`],fileSvg:`svg/carToWheels.svg`},carUp:{glyph:``,size:24,tags:[`generic`,`vehicle`],fileSvg:`svg/carUp.svg`},carWithLidar:{glyph:``,size:24,tags:[`generic`,`vehicle`,`tech`,`sensors`],fileSvg:`svg/carWithLidar.svg`},car:{glyph:``,size:24,tags:[`generic`,`vehicle`],fileSvg:`svg/car.svg`},cardboardBox:{glyph:``,size:24,tags:[`generic`,`delivery`],fileSvg:`svg/cardboardBox.svg`},carsChase02:{glyph:``,size:24,tags:[`generic`,`police`,`vehicle`],fileSvg:`svg/carsChase02.svg`},cars:{glyph:``,size:24,tags:[`generic`,`vehicle`],fileSvg:`svg/cars.svg`},catalog01:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/catalog01.svg`},catalog02:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/catalog02.svg`},catalog03:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/catalog03.svg`},centrifugalClutchLocked03:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/centrifugalClutchLocked03.svg`},centrifugalClutchUnlocked03:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/centrifugalClutchUnlocked03.svg`},charge:{glyph:``,size:24,tags:[`fuel`,`electricity`,`ev`],fileSvg:`svg/charge.svg`},charging:{glyph:``,size:24,tags:[`fuel`,`electricity`,`ev`],fileSvg:`svg/charging.svg`},chartBars:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/chartBars.svg`},checkboxOff:{glyph:``,size:24,tags:[`checkbox`,`selection`,`box`],fileSvg:`svg/checkboxOff.svg`},checkboxOn:{glyph:``,size:24,tags:[`checkbox`,`selection`,`box`],fileSvg:`svg/checkboxOn.svg`},checkmarkBold:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/checkmarkBold.svg`},checkmark:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/checkmark.svg`},circuitMicrochip:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/circuitMicrochip.svg`},circuit:{glyph:``,size:24,tags:[`poi`],fileSvg:`svg/circuit.svg`},clapperboard:{glyph:``,size:24,tags:[`generic`,`movie`,`scenery`],fileSvg:`svg/clapperboard.svg`},code:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/code.svg`},cogDamaged:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/cogDamaged.svg`},cogsDamaged:{glyph:``,size:24,tags:[`vehicle`,`features`,`powertrain`,`drivetrain`],fileSvg:`svg/cogsDamaged.svg`},cogs:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/cogs.svg`},concreteRoadBlock:{glyph:``,size:24,tags:[`generic`,`world editor`,`we`,`road tools`],fileSvg:`svg/concreteRoadBlock.svg`},coolantTemp:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/coolantTemp.svg`},copy:{glyph:``,size:24,tags:[`decals`,`generic`],fileSvg:`svg/copy.svg`},crossroads1:{glyph:``,size:24,tags:[`generic`,`world editor`,`we`,`road tools`],fileSvg:`svg/crossroads1.svg`},crossroads2:{glyph:``,size:24,tags:[`generic`,`world editor`,`we`,`road tools`],fileSvg:`svg/crossroads2.svg`},cruiseDisable:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/cruiseDisable.svg`},cruiseEnable:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/cruiseEnable.svg`},cup:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/cup.svg`},dataExchange:{glyph:``,size:24,tags:[`generic`,`data`,`signal`],fileSvg:`svg/dataExchange.svg`},day:{glyph:``,size:24,tags:[`environment`],fileSvg:`svg/day.svg`},DCBattery:{glyph:``,size:24,tags:[`vehicle`,`features`,`warning`,`internals`],fileSvg:`svg/DCBattery.svg`},decalRoad:{glyph:``,size:24,tags:[`generic`,`world editor`,`we`,`road tools`],fileSvg:`svg/decalRoad.svg`},decal:{glyph:``,size:24,tags:[`decals`,`generic`],fileSvg:`svg/decal.svg`},deform:{glyph:``,size:24,tags:[`decals`,`generic`],fileSvg:`svg/deform.svg`},deliveryTruckArrows:{glyph:``,size:24,tags:[`poi`,`delivery`,`vehicle`],fileSvg:`svg/deliveryTruckArrows.svg`},deliveryTruck:{glyph:``,size:24,tags:[`poi`,`delivery`,`vehicle`],fileSvg:`svg/deliveryTruck.svg`},differentialFrontDefault:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/differentialFrontDefault.svg`},differentialFrontLocked:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/differentialFrontLocked.svg`},differentialMiddleDefault:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/differentialMiddleDefault.svg`},differentialMiddleLocked:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/differentialMiddleLocked.svg`},differentialRearDefault:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/differentialRearDefault.svg`},differentialRearLocked:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/differentialRearLocked.svg`},doorHandle:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/doorHandle.svg`},doorIn:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/doorIn.svg`},drag01:{glyph:``,size:24,tags:[`poi`],fileSvg:`svg/drag01.svg`},drag02:{glyph:``,size:24,tags:[`poi`],fileSvg:`svg/drag02.svg`},drift01:{glyph:``,size:24,tags:[`poi`,`vehicle`],fileSvg:`svg/drift01.svg`},drift02:{glyph:``,size:24,tags:[`poi`,`vehicle`],fileSvg:`svg/drift02.svg`},drivetrainGeneric:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/drivetrainGeneric.svg`},drivetrainSpecial:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/drivetrainSpecial.svg`},editCheckmark:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/editCheckmark.svg`},edit:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/edit.svg`},engine:{glyph:``,size:24,tags:[`vehicle`,`part`,`features`],fileSvg:`svg/engine.svg`},ESCOff:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/ESCOff.svg`},ESCOn:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/ESCOn.svg`},ESC:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/ESC.svg`},evade:{glyph:``,size:24,tags:[`poi`,`mission`,`police`],fileSvg:`svg/evade.svg`},exhaustValve:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/exhaustValve.svg`},exit:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/exit.svg`},export:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/export.svg`},eyeOutlineClosed:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/eyeOutlineClosed.svg`},eyeOutlineOpened:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/eyeOutlineOpened.svg`},eyeSolidClosed:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/eyeSolidClosed.svg`},eyeSolidOpened:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/eyeSolidOpened.svg`},eyeWaves:{glyph:``,size:24,tags:[`generic`,`data`,`signal`,`sensor`],fileSvg:`svg/eyeWaves.svg`},facility02:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/facility02.svg`},fastBackward:{glyph:``,size:24,tags:[`playback`],fileSvg:`svg/fastBackward.svg`},fastForward:{glyph:``,size:24,tags:[`playback`],fileSvg:`svg/fastForward.svg`},fastTravel:{glyph:``,size:24,tags:[`poi`],fileSvg:`svg/fastTravel.svg`},filter:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/filter.svg`},flagNew:{glyph:``,size:24,tags:[`poi`],fileSvg:`svg/flagNew.svg`},flag:{glyph:``,size:24,tags:[`poi`],fileSvg:`svg/flag.svg`},flatBulbBeam:{glyph:``,size:24,tags:[`generic`,`world editor`,`we`,`sensor`],fileSvg:`svg/flatBulbBeam.svg`},flatbedTruck:{glyph:``,size:24,tags:[`cargo`,`delivery`,`vehicle`,`truck`],fileSvg:`svg/flatbedTruck.svg`},floppyDisk:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/floppyDisk.svg`},fogLight:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/fogLight.svg`},folder:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/folder.svg`},forklift:{glyph:``,size:24,tags:[`delivery`,`stencil`,`cargo`,`vehicle`],fileSvg:`svg/forklift.svg`},FPS:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/FPS.svg`},fragile:{glyph:``,size:24,tags:[`delivery`,`stencil`,`cargo`],fileSvg:`svg/fragile.svg`},frontAxleMidpoint:{glyph:``,size:24,tags:[`generic`,`world editor`,`we`,`placement`,`sensor`],fileSvg:`svg/frontAxleMidpoint.svg`},frontBumperMidpoint:{glyph:``,size:24,tags:[`generic`,`world editor`,`we`,`placement`,`sensor`],fileSvg:`svg/frontBumperMidpoint.svg`},fuelPumpFilling:{glyph:``,size:24,tags:[`fuel`],fileSvg:`svg/fuelPumpFilling.svg`},fuelPump:{glyph:``,size:24,tags:[`fuel`],fileSvg:`svg/fuelPump.svg`},FWD:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/FWD.svg`},gamepadOld:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/gamepadOld.svg`},gamepad:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/gamepad.svg`},garage01:{glyph:``,size:24,tags:[`career`,`garage`,`features`],fileSvg:`svg/garage01.svg`},garage02:{glyph:``,size:24,tags:[`career`,`garage`,`features`],fileSvg:`svg/garage02.svg`},garage03:{glyph:``,size:24,tags:[`career`,`garage`,`features`],fileSvg:`svg/garage03.svg`},gaugeEmpty:{glyph:``,size:24,tags:[`poi`],fileSvg:`svg/gaugeEmpty.svg`},globe:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/globe.svg`},GPSMark:{glyph:``,size:24,tags:[`generic`,`gps`,`position`,`map`,`sensor`],fileSvg:`svg/GPSMark.svg`},GPSSolid:{glyph:``,size:24,tags:[`generic`,`gps`,`position`,`map`,`sensor`],fileSvg:`svg/GPSSolid.svg`},group:{glyph:``,size:24,tags:[`decals`,`generic`],fileSvg:`svg/group.svg`},gyroscopeMicrochip:{glyph:``,size:24,tags:[`generic`,`data`,`signal`,`sensor`],fileSvg:`svg/gyroscopeMicrochip.svg`},gyroscope:{glyph:``,size:24,tags:[`generic`,`data`,`signal`,`sensor`],fileSvg:`svg/gyroscope.svg`},hazardLights:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/hazardLights.svg`},helmets:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/helmets.svg`},help:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/help.svg`},highBeam:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/highBeam.svg`},HUD:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/HUD.svg`},hydroPump1:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/hydroPump1.svg`},hydroPump2:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/hydroPump2.svg`},hydroPump3:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/hydroPump3.svg`},hydroPump4:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/hydroPump4.svg`},hydroPump5:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/hydroPump5.svg`},hydroPump6:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/hydroPump6.svg`},hydroPump7:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/hydroPump7.svg`},hypermiling:{glyph:``,size:24,tags:[`poi`],fileSvg:`svg/hypermiling.svg`},import:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/import.svg`},infinity:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/infinity.svg`},info:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/info.svg`},jointLocked:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/jointLocked.svg`},jointUnlocked:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/jointUnlocked.svg`},jump:{glyph:``,size:24,tags:[`poi`],fileSvg:`svg/jump.svg`},keyboard:{glyph:``,size:24,tags:[`keyboard`,`input`],fileSvg:`svg/keyboard.svg`},keys1:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/keys1.svg`},keys2:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/keys2.svg`},lampPost1:{glyph:``,size:24,tags:[`generic`,`world editor`,`we`,`road tools`],fileSvg:`svg/lampPost1.svg`},lampPost2:{glyph:``,size:24,tags:[`generic`,`world editor`,`we`,`road tools`],fileSvg:`svg/lampPost2.svg`},lampPost3:{glyph:``,size:24,tags:[`generic`,`world editor`,`we`,`road tools`],fileSvg:`svg/lampPost3.svg`},laneProperties:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`,`road tools`],fileSvg:`svg/laneProperties.svg`},language:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/language.svg`},laptop:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/laptop.svg`},lidarPatternFullArcHighFreq:{glyph:``,size:24,tags:[`generic`,`world editor`,`we`,`sensor`],fileSvg:`svg/lidarPatternFullArcHighFreq.svg`},lidarPatternFullArcMidFreq:{glyph:``,size:24,tags:[`generic`,`world editor`,`we`,`sensor`],fileSvg:`svg/lidarPatternFullArcMidFreq.svg`},lidarPatternNarrowArc:{glyph:``,size:24,tags:[`generic`,`world editor`,`we`,`sensor`],fileSvg:`svg/lidarPatternNarrowArc.svg`},lidar:{glyph:``,size:24,tags:[`generic`,`data`,`signal`,`sensor`],fileSvg:`svg/lidar.svg`},lightGarageG11:{glyph:``,size:24,tags:[`career`,`garage`,`lights`],fileSvg:`svg/lightGarageG11.svg`},lightGarageG12:{glyph:``,size:24,tags:[`career`,`garage`,`lights`],fileSvg:`svg/lightGarageG12.svg`},lightGarageG13:{glyph:``,size:24,tags:[`career`,`garage`,`lights`],fileSvg:`svg/lightGarageG13.svg`},lightGarageG14:{glyph:``,size:24,tags:[`career`,`garage`,`lights`],fileSvg:`svg/lightGarageG14.svg`},lightGarageG21:{glyph:``,size:24,tags:[`career`,`garage`,`lights`],fileSvg:`svg/lightGarageG21.svg`},lightGarageG22:{glyph:``,size:24,tags:[`career`,`garage`,`lights`],fileSvg:`svg/lightGarageG22.svg`},lightGarageG23:{glyph:``,size:24,tags:[`career`,`garage`,`lights`],fileSvg:`svg/lightGarageG23.svg`},lightGarageG24:{glyph:``,size:24,tags:[`career`,`garage`,`lights`],fileSvg:`svg/lightGarageG24.svg`},lightGarageG31:{glyph:``,size:24,tags:[`career`,`garage`,`lights`],fileSvg:`svg/lightGarageG31.svg`},lightGarageG32:{glyph:``,size:24,tags:[`career`,`garage`,`lights`],fileSvg:`svg/lightGarageG32.svg`},lightGarageG33:{glyph:``,size:24,tags:[`career`,`garage`,`lights`],fileSvg:`svg/lightGarageG33.svg`},lightGarageG34:{glyph:``,size:24,tags:[`career`,`garage`,`lights`],fileSvg:`svg/lightGarageG34.svg`},lightrunner:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/lightrunner.svg`},limiterEnable:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/limiterEnable.svg`},lineToTerrain:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`,`road tools`],fileSvg:`svg/lineToTerrain.svg`},link2:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/link2.svg`},link:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/link.svg`},listBig:{glyph:``,size:24,tags:[`generic`,`catalog`,`selector`,`view`],fileSvg:`svg/listBig.svg`},listIndented:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/listIndented.svg`},listSmall:{glyph:``,size:24,tags:[`generic`,`catalog`,`selector`,`view`],fileSvg:`svg/listSmall.svg`},location1:{glyph:``,size:24,tags:[`generic`,`gps`,`position`,`map`,`sensor`],fileSvg:`svg/location1.svg`},location2:{glyph:``,size:24,tags:[`generic`,`gps`,`position`,`map`,`sensor`],fileSvg:`svg/location2.svg`},lockClosed:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/lockClosed.svg`},lockOpened:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/lockOpened.svg`},longRangeBeam1:{glyph:``,size:24,tags:[`generic`,`world editor`,`we`,`sensor`],fileSvg:`svg/longRangeBeam1.svg`},longRangeBeam2:{glyph:``,size:24,tags:[`generic`,`world editor`,`we`,`sensor`],fileSvg:`svg/longRangeBeam2.svg`},lowBeam:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/lowBeam.svg`},magnetOnSurface:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`,`road tools`],fileSvg:`svg/magnetOnSurface.svg`},mapWithEmitter:{glyph:``,size:24,tags:[`generic`,`tech`,`sensors`],fileSvg:`svg/mapWithEmitter.svg`},mapPoint:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/mapPoint.svg`},material:{glyph:``,size:24,tags:[`decals`,`generic`],fileSvg:`svg/material.svg`},mathDivide:{glyph:``,size:24,tags:[`generic`,`math`,`operands`,`small`],fileSvg:`svg/mathDivide.svg`},mathGreaterOrEqualThan:{glyph:``,size:24,tags:[`generic`,`math`,`operands`,`small`],fileSvg:`svg/mathGreaterOrEqualThan.svg`},mathGreaterThan:{glyph:``,size:24,tags:[`generic`,`math`,`operands`,`small`],fileSvg:`svg/mathGreaterThan.svg`},mathLessOrEqualThan:{glyph:``,size:24,tags:[`generic`,`math`,`operands`,`small`],fileSvg:`svg/mathLessOrEqualThan.svg`},mathLessThan:{glyph:``,size:24,tags:[`generic`,`math`,`operands`,`small`],fileSvg:`svg/mathLessThan.svg`},mathMinus:{glyph:``,size:24,tags:[`generic`,`math`,`operands`,`small`],fileSvg:`svg/mathMinus.svg`},mathMultiply:{glyph:``,size:24,tags:[`generic`,`math`,`operands`,`small`],fileSvg:`svg/mathMultiply.svg`},mathPlus:{glyph:``,size:24,tags:[`generic`,`math`,`operands`,`small`],fileSvg:`svg/mathPlus.svg`},medal:{glyph:``,size:24,tags:[`generic`,`reward`,`achievment`],fileSvg:`svg/medal.svg`},mesh4Cells:{glyph:``,size:24,tags:[`tech`,`mesh`,`beams`,`nodes`,`surface`],fileSvg:`svg/mesh4Cells.svg`},mesh9Cells:{glyph:``,size:24,tags:[`tech`,`mesh`,`beams`,`nodes`,`surface`],fileSvg:`svg/mesh9Cells.svg`},meshFence:{glyph:``,size:24,tags:[`generic`,`world editor`,`we`,`road tools`],fileSvg:`svg/meshFence.svg`},meshRoad:{glyph:``,size:24,tags:[`generic`,`world editor`,`we`,`road tools`],fileSvg:`svg/meshRoad.svg`},midRangeBeam1:{glyph:``,size:24,tags:[`generic`,`world editor`,`we`,`sensor`],fileSvg:`svg/midRangeBeam1.svg`},midRangeBeam2:{glyph:``,size:24,tags:[`generic`,`world editor`,`we`,`sensor`],fileSvg:`svg/midRangeBeam2.svg`},minusRes:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/minusRes.svg`},minus:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/minus.svg`},mirrorInteriorMiddle:{glyph:``,size:24,tags:[`vehicle`,`features`,`mirror`,`rearview`],fileSvg:`svg/mirrorInteriorMiddle.svg`},mirrorLeftBigBottomWideAngle:{glyph:``,size:24,tags:[`vehicle`,`features`,`mirror`,`rearview`],fileSvg:`svg/mirrorLeftBigBottomWideAngle.svg`},mirrorLeftBigTop:{glyph:``,size:24,tags:[`vehicle`,`features`,`mirror`,`rearview`],fileSvg:`svg/mirrorLeftBigTop.svg`},mirrorLeftBig:{glyph:``,size:24,tags:[`vehicle`,`features`,`mirror`,`rearview`],fileSvg:`svg/mirrorLeftBig.svg`},mirrorLeftBonnet:{glyph:``,size:24,tags:[`vehicle`,`features`,`mirror`,`rearview`],fileSvg:`svg/mirrorLeftBonnet.svg`},mirrorLeftDefault:{glyph:``,size:24,tags:[`vehicle`,`features`,`mirror`,`rearview`],fileSvg:`svg/mirrorLeftDefault.svg`},mirrorRightBigBottomWideAngle:{glyph:``,size:24,tags:[`vehicle`,`features`,`mirror`,`rearview`],fileSvg:`svg/mirrorRightBigBottomWideAngle.svg`},mirrorRightBigTop:{glyph:``,size:24,tags:[`vehicle`,`features`,`mirror`,`rearview`],fileSvg:`svg/mirrorRightBigTop.svg`},mirrorRightBig:{glyph:``,size:24,tags:[`vehicle`,`features`,`mirror`,`rearview`],fileSvg:`svg/mirrorRightBig.svg`},mirrorRightBonnet:{glyph:``,size:24,tags:[`vehicle`,`features`,`mirror`,`rearview`],fileSvg:`svg/mirrorRightBonnet.svg`},mirrorRightDefault:{glyph:``,size:24,tags:[`vehicle`,`features`,`mirror`,`rearview`],fileSvg:`svg/mirrorRightDefault.svg`},mirrorRoundWideAngle:{glyph:``,size:24,tags:[`vehicle`,`features`,`mirror`,`rearview`],fileSvg:`svg/mirrorRoundWideAngle.svg`},mirrorTopWideAngle:{glyph:``,size:24,tags:[`vehicle`,`features`,`mirror`,`rearview`],fileSvg:`svg/mirrorTopWideAngle.svg`},missionCheckboxCross:{glyph:``,size:24,tags:[`checkbox`,`selection`,`box`],fileSvg:`svg/missionCheckboxCross.svg`},mouseLMB:{glyph:``,size:24,tags:[`mouse`,`input`],fileSvg:`svg/mouseLMB.svg`},mouseMMB:{glyph:``,size:24,tags:[`mouse`,`input`],fileSvg:`svg/mouseMMB.svg`},mouseRMB:{glyph:``,size:24,tags:[`mouse`,`input`],fileSvg:`svg/mouseRMB.svg`},mouseWheel:{glyph:``,size:24,tags:[`mouse`,`input`],fileSvg:`svg/mouseWheel.svg`},mouseXAxis:{glyph:``,size:24,tags:[`mouse`,`input`],fileSvg:`svg/mouseXAxis.svg`},mouseXYAxis:{glyph:``,size:24,tags:[`mouse`,`input`],fileSvg:`svg/mouseXYAxis.svg`},mouseYAxis:{glyph:``,size:24,tags:[`mouse`,`input`],fileSvg:`svg/mouseYAxis.svg`},mouse:{glyph:``,size:24,tags:[`mouse`,`input`],fileSvg:`svg/mouse.svg`},move02:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/move02.svg`},move:{glyph:``,size:24,tags:[`decals`,`generic`],fileSvg:`svg/move.svg`},movieCamera:{glyph:``,size:24,tags:[`camera`],fileSvg:`svg/movieCamera.svg`},music:{glyph:``,size:24,tags:[`playback`],fileSvg:`svg/music.svg`},N2OButton:{glyph:``,size:24,tags:[`fuel`],fileSvg:`svg/N2OButton.svg`},N2OHoriz:{glyph:``,size:24,tags:[`fuel`],fileSvg:`svg/N2OHoriz.svg`},N2OVert:{glyph:``,size:24,tags:[`fuel`],fileSvg:`svg/N2OVert.svg`},nextTrack:{glyph:``,size:24,tags:[`playback`],fileSvg:`svg/nextTrack.svg`},night:{glyph:``,size:24,tags:[`environment`],fileSvg:`svg/night.svg`},noNameControllerButton:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/noNameControllerButton.svg`},nodeAddFirst01:{glyph:``,size:24,tags:[`generic`,`path`,`node`],fileSvg:`svg/nodeAddFirst01.svg`},nodeAddFirst02:{glyph:``,size:24,tags:[`generic`,`path`,`node`],fileSvg:`svg/nodeAddFirst02.svg`},nodeAddLast02:{glyph:``,size:24,tags:[`generic`,`path`,`node`],fileSvg:`svg/nodeAddLast02.svg`},nodeAddMiddle01:{glyph:``,size:24,tags:[`generic`,`path`,`node`],fileSvg:`svg/nodeAddMiddle01.svg`},nodeAddMiddle02:{glyph:``,size:24,tags:[`generic`,`path`,`node`],fileSvg:`svg/nodeAddMiddle02.svg`},nodeAdd:{glyph:``,size:24,tags:[`generic`,`path`,`node`],fileSvg:`svg/nodeAdd.svg`},nodeLast01:{glyph:``,size:24,tags:[`generic`,`path`,`node`],fileSvg:`svg/nodeLast01.svg`},nodeRemove:{glyph:``,size:24,tags:[`generic`,`path`,`node`],fileSvg:`svg/nodeRemove.svg`},odometerKM:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/odometerKM.svg`},odometerMI:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/odometerMI.svg`},odometer:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/odometer.svg`},oilPressureIndicator:{glyph:``,size:24,tags:[`vehicle`,`features`,`warning`,`internals`],fileSvg:`svg/oilPressureIndicator.svg`},order:{glyph:``,size:24,tags:[`decals`,`generic`],fileSvg:`svg/order.svg`},organization:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/organization.svg`},palmCrossed:{glyph:``,size:24,tags:[`touch`,`input`],fileSvg:`svg/palmCrossed.svg`},paperKnife:{glyph:``,size:24,tags:[`decals`,`generic`],fileSvg:`svg/paperKnife.svg`},parkingIndicator:{glyph:``,size:24,tags:[`vehicle`,`features`,`warning`,`internals`],fileSvg:`svg/parkingIndicator.svg`},parking:{glyph:``,size:24,tags:[`poi`],fileSvg:`svg/parking.svg`},pathArc:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`,`road tools`],fileSvg:`svg/pathArc.svg`},pathAroundObstacle:{glyph:``,size:24,tags:[`camera`],fileSvg:`svg/pathAroundObstacle.svg`},pathLine:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`,`road tools`],fileSvg:`svg/pathLine.svg`},pathSpiral:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`,`road tools`],fileSvg:`svg/pathSpiral.svg`},pauseRound:{glyph:``,size:24,tags:[`playback`],fileSvg:`svg/pauseRound.svg`},pause:{glyph:``,size:24,tags:[`playback`],fileSvg:`svg/pause.svg`},personSolid:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/personSolid.svg`},person:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/person.svg`},photo:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/photo.svg`},placeholder:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/placeholder.svg`},playRound:{glyph:``,size:24,tags:[`playback`],fileSvg:`svg/playRound.svg`},play:{glyph:``,size:24,tags:[`playback`],fileSvg:`svg/play.svg`},playlist:{glyph:``,size:24,tags:[`playback`],fileSvg:`svg/playlist.svg`},plusGarage1:{glyph:``,size:24,tags:[`career`,`garage`,`features`],fileSvg:`svg/plusGarage1.svg`},plusGarage2:{glyph:``,size:24,tags:[`career`,`garage`,`features`],fileSvg:`svg/plusGarage2.svg`},plusGarage3:{glyph:``,size:24,tags:[`career`,`garage`,`features`],fileSvg:`svg/plusGarage3.svg`},plusGarage4:{glyph:``,size:24,tags:[`career`,`garage`,`features`],fileSvg:`svg/plusGarage4.svg`},plusSet:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/plusSet.svg`},plus:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/plus.svg`},positionLights:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/positionLights.svg`},powerGauge01:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/powerGauge01.svg`},powerGauge02:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/powerGauge02.svg`},powerGauge03:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/powerGauge03.svg`},powerGauge04:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/powerGauge04.svg`},powerGauge05:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/powerGauge05.svg`},powerOnOff:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/powerOnOff.svg`},prevTrack:{glyph:``,size:24,tags:[`playback`],fileSvg:`svg/prevTrack.svg`},publisher:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/publisher.svg`},puzzleModule:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/puzzleModule.svg`},raceFlag:{glyph:``,size:24,tags:[`poi`],fileSvg:`svg/raceFlag.svg`},radarIdeal:{glyph:``,size:24,tags:[`generic`,`data`,`signal`,`sensor`],fileSvg:`svg/radarIdeal.svg`},radarRoundIdeal:{glyph:``,size:24,tags:[`generic`,`data`,`signal`,`sensor`],fileSvg:`svg/radarRoundIdeal.svg`},radarRound:{glyph:``,size:24,tags:[`generic`,`data`,`signal`,`sensor`],fileSvg:`svg/radarRound.svg`},radar:{glyph:``,size:24,tags:[`generic`,`data`,`signal`,`sensor`],fileSvg:`svg/radar.svg`},rangeboxHi2:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/rangeboxHi2.svg`},rangeboxHi4:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/rangeboxHi4.svg`},rangeboxHiA:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/rangeboxHiA.svg`},rangeboxLo2:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/rangeboxLo2.svg`},rangeboxLo4:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/rangeboxLo4.svg`},rangeboxLoA:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/rangeboxLoA.svg`},rearAxleMidpoint:{glyph:``,size:24,tags:[`generic`,`world editor`,`we`,`placement`,`sensor`],fileSvg:`svg/rearAxleMidpoint.svg`},rearBumperMidpoint:{glyph:``,size:24,tags:[`generic`,`world editor`,`we`,`placement`,`sensor`],fileSvg:`svg/rearBumperMidpoint.svg`},reconfigure:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/reconfigure.svg`},redo:{glyph:``,size:24,tags:[`decals`,`generic`],fileSvg:`svg/redo.svg`},reflectNot:{glyph:``,size:24,tags:[`decals`,`generic`],fileSvg:`svg/reflectNot.svg`},reflect:{glyph:``,size:24,tags:[`decals`,`generic`],fileSvg:`svg/reflect.svg`},rename:{glyph:``,size:24,tags:[`decals`,`generic`],fileSvg:`svg/rename.svg`},replay:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/replay.svg`},restart:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/restart.svg`},roadDividerLinesDecal:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`,`road tools`],fileSvg:`svg/roadDividerLinesDecal.svg`},roadEdgeLineDecal:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`,`road tools`],fileSvg:`svg/roadEdgeLineDecal.svg`},roadEndLineDecal:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`,`road tools`],fileSvg:`svg/roadEndLineDecal.svg`},roadFace:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`,`road tools`],fileSvg:`svg/roadFace.svg`},roadInfo:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/roadInfo.svg`},roadMarkingOutline:{glyph:``,size:24,tags:[`generic`,`world editor`,`we`,`outlined`],fileSvg:`svg/roadMarkingOutline.svg`},roadMarkingSolid:{glyph:``,size:24,tags:[`generic`,`world editor`,`we`,`road tools`],fileSvg:`svg/roadMarkingSolid.svg`},roadOutline:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`,`road tools`],fileSvg:`svg/roadOutline.svg`},roadRefPathDecal:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`,`road tools`],fileSvg:`svg/roadRefPathDecal.svg`},roadRefPath:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`,`road tools`],fileSvg:`svg/roadRefPath.svg`},roadStartLineDecal:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`,`road tools`],fileSvg:`svg/roadStartLineDecal.svg`},road:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/road.svg`},rockCrawling01:{glyph:``,size:24,tags:[`poi`,`vehicle`],fileSvg:`svg/rockCrawling01.svg`},rockCrawling02:{glyph:``,size:24,tags:[`poi`],fileSvg:`svg/rockCrawling02.svg`},routeAdd:{glyph:``,size:24,tags:[`route`,`traffic`],fileSvg:`svg/routeAdd.svg`},routeComplex:{glyph:``,size:24,tags:[`route`,`traffic`],fileSvg:`svg/routeComplex.svg`},routeSimple:{glyph:``,size:24,tags:[`route`,`traffic`],fileSvg:`svg/routeSimple.svg`},runScript:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/runScript.svg`},RWD:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/RWD.svg`},saveAs1:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/saveAs1.svg`},scan:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/scan.svg`},search:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/search.svg`},semiTrailer:{glyph:``,size:24,tags:[`cargo`,`delivery`,`trailer`,`vehicle`],fileSvg:`svg/semiTrailer.svg`},semiTruckCabover:{glyph:``,size:24,tags:[`cargo`,`delivery`,`vehicle`,`truck`],fileSvg:`svg/semiTruckCabover.svg`},semiTruckUS:{glyph:``,size:24,tags:[`cargo`,`delivery`,`vehicle`,`truck`],fileSvg:`svg/semiTruckUS.svg`},semiTruck:{glyph:``,size:24,tags:[`cargo`,`delivery`,`truck`,`trailer`,`vehicle`],fileSvg:`svg/semiTruck.svg`},shortRangeBeam1:{glyph:``,size:24,tags:[`generic`,`world editor`,`we`,`sensor`],fileSvg:`svg/shortRangeBeam1.svg`},shortRangeBeam2:{glyph:``,size:24,tags:[`generic`,`world editor`,`we`,`sensor`],fileSvg:`svg/shortRangeBeam2.svg`},signal01a:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/signal01a.svg`},signal02a:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/signal02a.svg`},signal03a:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/signal03a.svg`},signal04a:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/signal04a.svg`},signal05a:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/signal05a.svg`},slashLeft:{glyph:``,size:24,tags:[`generic`,`math`,`operands`,`small`],fileSvg:`svg/slashLeft.svg`},slashRight:{glyph:``,size:24,tags:[`generic`,`math`,`operands`,`small`],fileSvg:`svg/slashRight.svg`},smallTrailer:{glyph:``,size:24,tags:[`cargo`,`delivery`,`trailer`,`vehicle`],fileSvg:`svg/smallTrailer.svg`},smartphone1:{glyph:``,size:24,tags:[`touch`,`input`],fileSvg:`svg/smartphone1.svg`},smartphone2:{glyph:``,size:24,tags:[`touch`,`input`],fileSvg:`svg/smartphone2.svg`},snowflake:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/snowflake.svg`},soundFadeOut:{glyph:``,size:24,tags:[`generic`,`sound`],fileSvg:`svg/soundFadeOut.svg`},soundLimit:{glyph:``,size:24,tags:[`generic`,`sound`],fileSvg:`svg/soundLimit.svg`},soundLoud:{glyph:``,size:24,tags:[`generic`,`sound`],fileSvg:`svg/soundLoud.svg`},soundMonoL:{glyph:``,size:24,tags:[`generic`,`sound`],fileSvg:`svg/soundMonoL.svg`},soundMonoR:{glyph:``,size:24,tags:[`generic`,`sound`],fileSvg:`svg/soundMonoR.svg`},soundOff:{glyph:``,size:24,tags:[`generic`,`sound`],fileSvg:`svg/soundOff.svg`},soundQuiet:{glyph:``,size:24,tags:[`generic`,`sound`],fileSvg:`svg/soundQuiet.svg`},soundStereo:{glyph:``,size:24,tags:[`generic`,`sound`],fileSvg:`svg/soundStereo.svg`},soundWave01:{glyph:``,size:24,tags:[`generic`,`sound`],fileSvg:`svg/soundWave01.svg`},soundWave02:{glyph:``,size:24,tags:[`generic`,`sound`],fileSvg:`svg/soundWave02.svg`},sphereOnPathNumber:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`,`road tools`],fileSvg:`svg/sphereOnPathNumber.svg`},sphereOnPath:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`,`road tools`],fileSvg:`svg/sphereOnPath.svg`},sphericalBeam:{glyph:``,size:24,tags:[`generic`,`world editor`,`we`,`sensor`],fileSvg:`svg/sphericalBeam.svg`},spoilerLift:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/spoilerLift.svg`},sprayCan:{glyph:``,size:24,tags:[`decals`,`generic`],fileSvg:`svg/sprayCan.svg`},stack3:{glyph:``,size:24,tags:[`delivery`,`stencil`,`cargo`],fileSvg:`svg/stack3.svg`},star:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/star.svg`},starSecondary:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/starSecondary.svg`},steeringWheelCommon:{glyph:``,size:24,tags:[`steering`,`controller`,`input`],fileSvg:`svg/steeringWheelCommon.svg`},steeringWheelSporty:{glyph:``,size:24,tags:[`steering`,`controller`,`input`],fileSvg:`svg/steeringWheelSporty.svg`},stopwatchArrows01:{glyph:``,size:24,tags:[`generic`,`time`,`fast`],fileSvg:`svg/stopwatchArrows01.svg`},stopwatchArrows02:{glyph:``,size:24,tags:[`generic`,`time`,`fast`],fileSvg:`svg/stopwatchArrows02.svg`},stopwatchSectionOutlinedEnd:{glyph:``,size:24,tags:[`generic`,`time`,`fast`],fileSvg:`svg/stopwatchSectionOutlinedEnd.svg`},stopwatchSectionOutlinedStart:{glyph:``,size:24,tags:[`generic`,`time`,`fast`],fileSvg:`svg/stopwatchSectionOutlinedStart.svg`},stopwatchSectionSolidEnd:{glyph:``,size:24,tags:[`generic`,`time`,`fast`],fileSvg:`svg/stopwatchSectionSolidEnd.svg`},stopwatchSectionSolidStart:{glyph:``,size:24,tags:[`generic`,`time`,`fast`],fileSvg:`svg/stopwatchSectionSolidStart.svg`},strobeLights:{glyph:``,size:24,tags:[`vehicle`,`features`,`police`,`emergency`],fileSvg:`svg/strobeLights.svg`},sunRise:{glyph:``,size:24,tags:[`environment`],fileSvg:`svg/sunRise.svg`},survellianceCamera:{glyph:``,size:24,tags:[`generic`,`camera`,`optical`,`sensor`],fileSvg:`svg/survellianceCamera.svg`},suspension01:{glyph:``,size:24,tags:[`vehicle`,`features`,`part`],fileSvg:`svg/suspension01.svg`},suspension02:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/suspension02.svg`},switchBlock:{glyph:``,size:24,tags:[`generic`,`circuit`,`electronics`,`switch`],fileSvg:`svg/switchBlock.svg`},switchOutline:{glyph:``,size:24,tags:[`generic`,`circuit`,`electronics`,`switch`],fileSvg:`svg/switchOutline.svg`},sync:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/sync.svg`},synchro01:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/synchro01.svg`},synchro02:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/synchro02.svg`},tankerTrailer:{glyph:``,size:24,tags:[`cargo`,`delivery`,`tank`,`tanker`,`trailer`,`vehicle`],fileSvg:`svg/tankerTrailer.svg`},targetJump:{glyph:``,size:24,tags:[`poi`],fileSvg:`svg/targetJump.svg`},taxiCar1:{glyph:``,size:24,tags:[`taxi`,`generic`,`vehicle`],fileSvg:`svg/taxiCar1.svg`},taxiCar3:{glyph:``,size:24,tags:[`taxi`,`generic`,`vehicle`],fileSvg:`svg/taxiCar3.svg`},taxiCarT:{glyph:``,size:24,tags:[`taxi`,`generic`,`vehicle`],fileSvg:`svg/taxiCarT.svg`},taxiCheckerLamp:{glyph:``,size:24,tags:[`taxi`,`generic`,`vehicle`],fileSvg:`svg/taxiCheckerLamp.svg`},terrainToLine:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`,`road tools`],fileSvg:`svg/terrainToLine.svg`},terrain:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/terrain.svg`},thinBulbBeam:{glyph:``,size:24,tags:[`generic`,`world editor`,`we`,`sensor`],fileSvg:`svg/thinBulbBeam.svg`},thinnerBulbBeam:{glyph:``,size:24,tags:[`generic`,`world editor`,`we`,`sensor`],fileSvg:`svg/thinnerBulbBeam.svg`},thisSideUp:{glyph:``,size:24,tags:[`delivery`,`stencil`,`cargo`],fileSvg:`svg/thisSideUp.svg`},tiles:{glyph:``,size:24,tags:[`generic`,`catalog`,`selector`,`view`],fileSvg:`svg/tiles.svg`},timer:{glyph:``,size:24,tags:[`generic`,`time`,`fast`],fileSvg:`svg/timer.svg`},tireDirection3Fourth2:{glyph:``,size:24,tags:[`tire`],fileSvg:`svg/tireDirection3Fourth2.svg`},tireDirection3Fourth3:{glyph:``,size:24,tags:[`tire`],fileSvg:`svg/tireDirection3Fourth3.svg`},tireDirectionFront2:{glyph:``,size:24,tags:[`tire`],fileSvg:`svg/tireDirectionFront2.svg`},tireDirectionSide2:{glyph:``,size:24,tags:[`tire`],fileSvg:`svg/tireDirectionSide2.svg`},tireDirectionTop2:{glyph:``,size:24,tags:[`tire`],fileSvg:`svg/tireDirectionTop2.svg`},tirePressureDecrease01:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/tirePressureDecrease01.svg`},tirePressureDecrease02:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/tirePressureDecrease02.svg`},tirePressureGaugeAlt01:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/tirePressureGaugeAlt01.svg`},tirePressureGaugeAlt02:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/tirePressureGaugeAlt02.svg`},tirePressureGaugeAlt03:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/tirePressureGaugeAlt03.svg`},tirePressureGaugeOutlined01:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/tirePressureGaugeOutlined01.svg`},tirePressureGaugeOutlined02:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/tirePressureGaugeOutlined02.svg`},tirePressureGaugeOutlined03:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/tirePressureGaugeOutlined03.svg`},tirePressureGaugeSolid01:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/tirePressureGaugeSolid01.svg`},tirePressureGaugeSolid02:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/tirePressureGaugeSolid02.svg`},tirePressureGaugeSolid03:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/tirePressureGaugeSolid03.svg`},tirePressureIncrease01:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/tirePressureIncrease01.svg`},tirePressureIncrease02:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/tirePressureIncrease02.svg`},tirePressureStopLine:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/tirePressureStopLine.svg`},tirePressureStopOctoLine:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/tirePressureStopOctoLine.svg`},tirePressureStopOctoSolid:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/tirePressureStopOctoSolid.svg`},tirePressureStopSolid:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/tirePressureStopSolid.svg`},toCOMWithWheels:{glyph:``,size:24,tags:[`generic`,`world editor`,`we`,`placement`,`sensor`],fileSvg:`svg/toCOMWithWheels.svg`},toCOM:{glyph:``,size:24,tags:[`generic`,`world editor`,`we`,`placement`,`sensor`],fileSvg:`svg/toCOM.svg`},toGarage:{glyph:``,size:24,tags:[`poi`],fileSvg:`svg/toGarage.svg`},touch:{glyph:``,size:24,tags:[`touch`,`input`],fileSvg:`svg/touch.svg`},tow:{glyph:``,size:24,tags:[`generic`,`vehicle`],fileSvg:`svg/tow.svg`},tractionControl:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/tractionControl.svg`},trafficCone:{glyph:``,size:24,tags:[`route`,`traffic`],fileSvg:`svg/trafficCone.svg`},transform:{glyph:``,size:24,tags:[`decals`,`generic`],fileSvg:`svg/transform.svg`},transmissionA:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/transmissionA.svg`},transmissionM:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/transmissionM.svg`},transparencyMask:{glyph:``,size:24,tags:[`decals`,`generic`],fileSvg:`svg/transparencyMask.svg`},trashBin1:{glyph:``,size:24,tags:[`poi`],fileSvg:`svg/trashBin1.svg`},trashBin2:{glyph:``,size:24,tags:[`decals`,`generic`],fileSvg:`svg/trashBin2.svg`},triangleBeam:{glyph:``,size:24,tags:[`generic`,`world editor`,`we`,`sensor`],fileSvg:`svg/triangleBeam.svg`},trim:{glyph:``,size:24,tags:[`generic`,`sound`],fileSvg:`svg/trim.svg`},tulipBeam:{glyph:``,size:24,tags:[`generic`,`world editor`,`we`,`sensor`],fileSvg:`svg/tulipBeam.svg`},tunnel:{glyph:``,size:24,tags:[`generic`,`world editor`,`we`,`road tools`],fileSvg:`svg/tunnel.svg`},turbine:{glyph:``,size:24,tags:[`vehicle`,`part`,`features`],fileSvg:`svg/turbine.svg`},twoRoadsAdd:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`,`road tools`],fileSvg:`svg/twoRoadsAdd.svg`},twoRoadsCrossAdd:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`,`road tools`],fileSvg:`svg/twoRoadsCrossAdd.svg`},twoRoadsLink:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`,`road tools`],fileSvg:`svg/twoRoadsLink.svg`},twoUnicyclesOnly:{glyph:``,size:24,tags:[`delivery`,`stencil`,`cargo`],fileSvg:`svg/twoUnicyclesOnly.svg`},undo:{glyph:``,size:24,tags:[`decals`,`generic`],fileSvg:`svg/undo.svg`},ungroup:{glyph:``,size:24,tags:[`decals`,`generic`],fileSvg:`svg/ungroup.svg`},unlink:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/unlink.svg`},vehicleDoorsClose:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/vehicleDoorsClose.svg`},vehicleDoorsOpen:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/vehicleDoorsOpen.svg`},vehicleDoors:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/vehicleDoors.svg`},vehicleFeatures01:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/vehicleFeatures01.svg`},vehicleFeatures02:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/vehicleFeatures02.svg`},vehicleFeatures03:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/vehicleFeatures03.svg`},vehicleHood:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/vehicleHood.svg`},vehicleTrunk:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/vehicleTrunk.svg`},view:{glyph:``,size:24,tags:[`decals`,`generic`],fileSvg:`svg/view.svg`},voucherDiagonal1:{glyph:``,size:24,tags:[`generic`,`currency`,`reward`,`career`],fileSvg:`svg/voucherDiagonal1.svg`},voucherDiagonal2:{glyph:``,size:24,tags:[`generic`,`currency`,`reward`,`career`],fileSvg:`svg/voucherDiagonal2.svg`},voucherDiagonal3:{glyph:``,size:24,tags:[`generic`,`currency`,`reward`,`career`],fileSvg:`svg/voucherDiagonal3.svg`},voucherHorizontal1:{glyph:``,size:24,tags:[`generic`,`currency`,`reward`,`career`],fileSvg:`svg/voucherHorizontal1.svg`},voucherHorizontal2:{glyph:``,size:24,tags:[`generic`,`currency`,`reward`,`career`],fileSvg:`svg/voucherHorizontal2.svg`},voucherHorizontal3:{glyph:``,size:24,tags:[`generic`,`currency`,`reward`,`career`],fileSvg:`svg/voucherHorizontal3.svg`},wavesSignalReceived:{glyph:``,size:24,tags:[`generic`,`data`,`signal`,`sensor`],fileSvg:`svg/wavesSignalReceived.svg`},wavesSignalSentLeft:{glyph:``,size:24,tags:[`generic`,`data`,`signal`,`sensor`],fileSvg:`svg/wavesSignalSentLeft.svg`},wavesSignalSentRight:{glyph:``,size:24,tags:[`generic`,`data`,`signal`,`sensor`],fileSvg:`svg/wavesSignalSentRight.svg`},weather:{glyph:``,size:24,tags:[`environment`],fileSvg:`svg/weather.svg`},weight:{glyph:``,size:24,tags:[`decals`,`generic`],fileSvg:`svg/weight.svg`},wheelHubLocked01:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/wheelHubLocked01.svg`},wheelHubUnlocked01:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/wheelHubUnlocked01.svg`},wigwags:{glyph:``,size:24,tags:[`vehicle`,`features`,`police`,`emergency`],fileSvg:`svg/wigwags.svg`},wrench:{glyph:``,size:24,tags:[`generic`,`vehicle`,`features`],fileSvg:`svg/wrench.svg`},xboxA:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/xboxA.svg`},xboxB:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/xboxB.svg`},xboxDDefaultOutline:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/xboxDDefaultOutline.svg`},xboxDDefaultSolid:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/xboxDDefaultSolid.svg`},xboxDDown:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/xboxDDown.svg`},xboxDLeft:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/xboxDLeft.svg`},xboxDRight:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/xboxDRight.svg`},xboxDUp:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/xboxDUp.svg`},xboxLB:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/xboxLB.svg`},xboxLSButton:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/xboxLSButton.svg`},xboxLT:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/xboxLT.svg`},xboxMenu:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/xboxMenu.svg`},xboxRB:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/xboxRB.svg`},xboxRSButton:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/xboxRSButton.svg`},xboxRT:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/xboxRT.svg`},xboxThumbL:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/xboxThumbL.svg`},xboxThumbR:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/xboxThumbR.svg`},xboxView:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/xboxView.svg`},xboxXAxis:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/xboxXAxis.svg`},xboxXRot:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/xboxXRot.svg`},xboxX:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/xboxX.svg`},xboxYAxis:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/xboxYAxis.svg`},xboxYRot:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/xboxYRot.svg`},xboxY:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/xboxY.svg`},AIL:{glyph:``,size:48,tags:[`extra`],fileSvg:`svg/AIL.svg`},arrowLeftOutline:{glyph:``,size:48,tags:[`web`,`outlined`,`large`,`secondary`],fileSvg:`svg/arrowLeftOutline.svg`},arrowRightOutline:{glyph:``,size:48,tags:[`web`,`outlined`,`large`,`secondary`],fileSvg:`svg/arrowRightOutline.svg`},automaticTransmissionL:{glyph:``,size:48,tags:[`extra`],fileSvg:`svg/automaticTransmissionL.svg`},beamsNodesMessageOutline:{glyph:``,size:48,tags:[`web`,`outlined`,`large`,`secondary`],fileSvg:`svg/beamsNodesMessageOutline.svg`},beamsNodesOutline:{glyph:``,size:48,tags:[`web`,`outlined`,`large`,`secondary`],fileSvg:`svg/beamsNodesOutline.svg`},beamsNodesPlugOutline:{glyph:``,size:48,tags:[`web`,`outlined`,`large`,`secondary`],fileSvg:`svg/beamsNodesPlugOutline.svg`},BNGEcosystemOutline:{glyph:``,size:48,tags:[`web`,`outlined`,`large`,`secondary`],fileSvg:`svg/BNGEcosystemOutline.svg`},carFrontRouteOutline:{glyph:``,size:48,tags:[`web`,`outlined`,`large`,`secondary`],fileSvg:`svg/carFrontRouteOutline.svg`},carSensorsOutline:{glyph:``,size:48,tags:[`web`,`outlined`,`large`,`secondary`],fileSvg:`svg/carSensorsOutline.svg`},carSideRouteOutline:{glyph:``,size:48,tags:[`web`,`outlined`,`large`,`secondary`],fileSvg:`svg/carSideRouteOutline.svg`},chargeLL:{glyph:``,size:48,tags:[`extra`],fileSvg:`svg/chargeLL.svg`},cityOutline:{glyph:``,size:48,tags:[`web`,`outlined`,`large`,`secondary`],fileSvg:`svg/cityOutline.svg`},clutchL:{glyph:``,size:48,tags:[`extra`],fileSvg:`svg/clutchL.svg`},couplerL:{glyph:``,size:48,tags:[`extra`],fileSvg:`svg/couplerL.svg`},dialogOutline:{glyph:``,size:48,tags:[`web`,`outlined`,`large`,`secondary`],fileSvg:`svg/dialogOutline.svg`},documentSmileOutline:{glyph:``,size:48,tags:[`web`,`outlined`,`large`,`secondary`],fileSvg:`svg/documentSmileOutline.svg`},drivetrainOutline:{glyph:``,size:48,tags:[`web`,`outlined`,`large`,`secondary`],fileSvg:`svg/drivetrainOutline.svg`},electronicSchemeOutline:{glyph:``,size:48,tags:[`web`,`outlined`,`large`,`secondary`],fileSvg:`svg/electronicSchemeOutline.svg`},engineL:{glyph:``,size:48,tags:[`extra`],fileSvg:`svg/engineL.svg`},engineOutline:{glyph:``,size:48,tags:[`web`,`outlined`,`large`,`secondary`],fileSvg:`svg/engineOutline.svg`},gearTuningOutline:{glyph:``,size:48,tags:[`web`,`outlined`,`large`,`secondary`],fileSvg:`svg/gearTuningOutline.svg`},giftBoxOutline:{glyph:``,size:48,tags:[`web`,`outlined`,`large`,`secondary`],fileSvg:`svg/giftBoxOutline.svg`},lidarOutline:{glyph:``,size:48,tags:[`web`,`outlined`,`large`,`secondary`],fileSvg:`svg/lidarOutline.svg`},medalStarOutline:{glyph:``,size:48,tags:[`web`,`outlined`,`large`,`secondary`],fileSvg:`svg/medalStarOutline.svg`},megaphoneOutline:{glyph:``,size:48,tags:[`web`,`outlined`,`large`,`secondary`],fileSvg:`svg/megaphoneOutline.svg`},multiseatL:{glyph:``,size:48,tags:[`extra`],fileSvg:`svg/multiseatL.svg`},peopleOutline:{glyph:``,size:48,tags:[`web`,`outlined`,`large`,`secondary`],fileSvg:`svg/peopleOutline.svg`},personOutline:{glyph:``,size:48,tags:[`web`,`outlined`,`large`,`secondary`],fileSvg:`svg/personOutline.svg`},physicsOutline:{glyph:``,size:48,tags:[`web`,`outlined`,`large`,`secondary`],fileSvg:`svg/physicsOutline.svg`},playChainOutline:{glyph:``,size:48,tags:[`web`,`outlined`,`large`,`secondary`],fileSvg:`svg/playChainOutline.svg`},POITimeL:{glyph:``,size:48,tags:[`extra`],fileSvg:`svg/POITimeL.svg`},proximitySensorsOutline:{glyph:``,size:48,tags:[`web`,`outlined`,`large`,`secondary`],fileSvg:`svg/proximitySensorsOutline.svg`},qualityBadgeStarOutline:{glyph:``,size:48,tags:[`web`,`outlined`,`large`,`secondary`],fileSvg:`svg/qualityBadgeStarOutline.svg`},qualityBadgeVOutline:{glyph:``,size:48,tags:[`web`,`outlined`,`large`,`secondary`],fileSvg:`svg/qualityBadgeVOutline.svg`},replayL:{glyph:``,size:48,tags:[`extra`],fileSvg:`svg/replayL.svg`},roadblockL:{glyph:``,size:48,tags:[`extra`],fileSvg:`svg/roadblockL.svg`},rotationL:{glyph:``,size:48,tags:[`extra`],fileSvg:`svg/rotationL.svg`},sensorsL:{glyph:``,size:48,tags:[`extra`],fileSvg:`svg/sensorsL.svg`},simRigOutline:{glyph:``,size:48,tags:[`web`,`outlined`,`large`,`secondary`],fileSvg:`svg/simRigOutline.svg`},suspensionOutline:{glyph:``,size:48,tags:[`web`,`outlined`,`large`,`secondary`],fileSvg:`svg/suspensionOutline.svg`},teamOutline:{glyph:``,size:48,tags:[`web`,`outlined`,`large`,`secondary`],fileSvg:`svg/teamOutline.svg`},techLightBulbOutline01:{glyph:``,size:48,tags:[`web`,`outlined`,`large`,`secondary`],fileSvg:`svg/techLightBulbOutline01.svg`},techLightBulbOutline02:{glyph:``,size:48,tags:[`web`,`outlined`,`large`,`secondary`],fileSvg:`svg/techLightBulbOutline02.svg`},temperatureL:{glyph:``,size:48,tags:[`extra`],fileSvg:`svg/temperatureL.svg`},timeUnlockOutline:{glyph:``,size:48,tags:[`web`,`outlined`,`large`,`secondary`],fileSvg:`svg/timeUnlockOutline.svg`},timedLockOutline:{glyph:``,size:48,tags:[`web`,`outlined`,`large`,`secondary`],fileSvg:`svg/timedLockOutline.svg`},trafficOutline:{glyph:``,size:48,tags:[`web`,`outlined`,`large`,`secondary`],fileSvg:`svg/trafficOutline.svg`},tuningL:{glyph:``,size:48,tags:[`extra`],fileSvg:`svg/tuningL.svg`},turbineL:{glyph:``,size:48,tags:[`extra`],fileSvg:`svg/turbineL.svg`},voucherOutline:{glyph:``,size:48,tags:[`web`,`outlined`,`large`,`secondary`],fileSvg:`svg/voucherOutline.svg`},wheelBeamsNodesOutline:{glyph:``,size:48,tags:[`web`,`outlined`,`large`,`secondary`],fileSvg:`svg/wheelBeamsNodesOutline.svg`},wheelOutline:{glyph:``,size:48,tags:[`web`,`outlined`,`large`,`secondary`],fileSvg:`svg/wheelOutline.svg`},circlePinBack:{glyph:``,size:56,tags:[`poi`],fileSvg:`svg/circlePinBack.svg`},circlePinFront:{glyph:``,size:56,tags:[`poi`],fileSvg:`svg/circlePinFront.svg`},markerRectanglePinBack:{glyph:``,size:56,tags:[`poi`],fileSvg:`svg/markerRectanglePinBack.svg`},markerRectanglePinFront:{glyph:``,size:56,tags:[`poi`],fileSvg:`svg/markerRectanglePinFront.svg`},markerTriangleBack:{glyph:``,size:56,tags:[`poi`],fileSvg:`svg/markerTriangleBack.svg`},markerTriangleFront:{glyph:``,size:56,tags:[`poi`],fileSvg:`svg/markerTriangleFront.svg`},danger:{glyph:``,size:24,tags:[`generic`,`hazard`],fileSvg:`svg/danger.svg`},droplet:{glyph:``,size:24,tags:[`generic`,`drop`,`liquid`],fileSvg:`svg/droplet.svg`},envelope:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/envelope.svg`},fireDiamond:{glyph:``,size:24,tags:[`generic`,`hazard`,`nfpa704`],fileSvg:`svg/fireDiamond.svg`},rocks:{glyph:``,size:24,tags:[`dry cargo`,`dry`],fileSvg:`svg/rocks.svg`},xmark:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/xmark.svg`},scale:{glyph:``,size:24,tags:[`decals`,`editor`,`generic`],fileSvg:`svg/scale.svg`},arrowsUp:{glyph:``,size:16,tags:[`marker`,`ribbon`,`content-props`],fileSvg:`svg/arrowsUp.svg`},bigDot:{glyph:``,size:16,tags:[`marker`,`ribbon`,`content-props`],fileSvg:`svg/bigDot.svg`},connectorBold:{glyph:``,size:16,tags:[`marker`,`ribbon`,`content-props`],fileSvg:`svg/connectorBold.svg`},cornerTopRight:{glyph:``,size:16,tags:[`marker`,`ribbon`,`content-props`],fileSvg:`svg/cornerTopRight.svg`},plusBold:{glyph:``,size:16,tags:[`marker`,`ribbon`,`content-props`],fileSvg:`svg/plusBold.svg`},puzzlePieceBold:{glyph:``,size:16,tags:[`marker`,`ribbon`,`content-props`],fileSvg:`svg/puzzlePieceBold.svg`},locationDestination:{glyph:``,size:24,tags:[`generic`,`location`,`route`,`path`,`node`],fileSvg:`svg/locationDestination.svg`},locationSource:{glyph:``,size:24,tags:[`generic`,`location`,`route`,`path`,`node`],fileSvg:`svg/locationSource.svg`},accelerationKPH:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/accelerationKPH.svg`},accelerationMPH:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/accelerationMPH.svg`},boxTruckFast:{glyph:``,size:24,tags:[`cargo`,`delivery`,`vehicle`],fileSvg:`svg/boxTruckFast.svg`},colorBrightnessSun:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/colorBrightnessSun.svg`},colorCirclePalette:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/colorCirclePalette.svg`},colorPalette:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/colorPalette.svg`},colorSaturation:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/colorSaturation.svg`},sortAscDown02:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/sortAscDown02.svg`},sortAscDown:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/sortAscDown.svg`},sortAscUp02:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/sortAscUp02.svg`},sortAscUp:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/sortAscUp.svg`},sortDescDown02:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/sortDescDown02.svg`},sortDescDown:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/sortDescDown.svg`},sortDescUp02:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/sortDescUp02.svg`},sortDescUp:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/sortDescUp.svg`},cardboardBoxCoins:{glyph:``,size:24,tags:[`generic`,`delivery`],fileSvg:`svg/cardboardBoxCoins.svg`},lasso:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`],fileSvg:`svg/lasso.svg`},materialGlossy:{glyph:``,size:24,tags:[`decals`,`generic`],fileSvg:`svg/materialGlossy.svg`},materialMetal:{glyph:``,size:24,tags:[`decals`,`generic`],fileSvg:`svg/materialMetal.svg`},materialRoughness:{glyph:``,size:24,tags:[`decals`,`generic`],fileSvg:`svg/materialRoughness.svg`},materialTransparency01:{glyph:``,size:24,tags:[`decals`,`generic`],fileSvg:`svg/materialTransparency01.svg`},materialTransparency02:{glyph:``,size:24,tags:[`decals`,`generic`],fileSvg:`svg/materialTransparency02.svg`},metal01:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/metal01.svg`},removeItemPolygon:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`,`road tools`],fileSvg:`svg/removeItemPolygon.svg`},removeListItem:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`,`road tools`],fileSvg:`svg/removeListItem.svg`},sortAsc:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/sortAsc.svg`},sortDesc:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/sortDesc.svg`},surfaceRoughness02:{glyph:``,size:24,tags:[`decals`,`generic`],fileSvg:`svg/surfaceRoughness02.svg`},shieldCheckmark:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/shieldCheckmark.svg`},shieldHandCheckmark:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/shieldHandCheckmark.svg`},shieldHandPlus:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/shieldHandPlus.svg`},doorFrontCoins:{glyph:``,size:24,tags:[`vehicle`,`part`,`features`],fileSvg:`svg/doorFrontCoins.svg`},doorFront:{glyph:``,size:24,tags:[`vehicle`,`part`,`features`],fileSvg:`svg/doorFront.svg`},engineCoins:{glyph:``,size:24,tags:[`vehicle`,`part`,`features`],fileSvg:`svg/engineCoins.svg`},exhaustMufflerCoins:{glyph:``,size:24,tags:[`vehicle`,`part`,`features`],fileSvg:`svg/exhaustMufflerCoins.svg`},exhaustMuffler:{glyph:``,size:24,tags:[`vehicle`,`part`,`features`],fileSvg:`svg/exhaustMuffler.svg`},headlightCoins:{glyph:``,size:24,tags:[`vehicle`,`part`,`features`],fileSvg:`svg/headlightCoins.svg`},headlight:{glyph:``,size:24,tags:[`vehicle`,`part`,`features`],fileSvg:`svg/headlight.svg`},tire3FourthCoins:{glyph:``,size:24,tags:[`vehicle`,`part`,`features`,`tire`],fileSvg:`svg/tire3FourthCoins.svg`},tire3Fourth:{glyph:``,size:24,tags:[`vehicle`,`part`,`features`,`tire`],fileSvg:`svg/tire3Fourth.svg`},turbineCoins:{glyph:``,size:24,tags:[`vehicle`,`part`,`features`],fileSvg:`svg/turbineCoins.svg`},wheelDiscCoins:{glyph:``,size:24,tags:[`vehicle`,`part`,`features`],fileSvg:`svg/wheelDiscCoins.svg`},wheelDisc:{glyph:``,size:24,tags:[`vehicle`,`part`,`features`],fileSvg:`svg/wheelDisc.svg`},bridgeWithRiver:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`,`road tools`],fileSvg:`svg/bridgeWithRiver.svg`},gizmosOutline:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`,`road tools`],fileSvg:`svg/gizmosOutline.svg`},gizmosSolid:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`,`road tools`],fileSvg:`svg/gizmosSolid.svg`},highwayRoad3To2Merge01:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`,`road tools`],fileSvg:`svg/highwayRoad3To2Merge01.svg`},highwayRoad3To2Merge02:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`,`road tools`],fileSvg:`svg/highwayRoad3To2Merge02.svg`},highwayToUrbanRoadTransition01:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`,`road tools`],fileSvg:`svg/highwayToUrbanRoadTransition01.svg`},highwayToUrbanRoadTransition02:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`,`road tools`],fileSvg:`svg/highwayToUrbanRoadTransition02.svg`},pedestrianCrossing01:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`,`road tools`],fileSvg:`svg/pedestrianCrossing01.svg`},polygonalCube:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`,`road tools`],fileSvg:`svg/polygonalCube.svg`},roadEditOutline:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`,`road tools`],fileSvg:`svg/roadEditOutline.svg`},roadEditSolid:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`,`road tools`],fileSvg:`svg/roadEditSolid.svg`},roadFolderPlus:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`,`road tools`],fileSvg:`svg/roadFolderPlus.svg`},roadFolder:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`,`road tools`],fileSvg:`svg/roadFolder.svg`},roadGuideArrowOutline:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`,`road tools`],fileSvg:`svg/roadGuideArrowOutline.svg`},roadGuideArrowSolid:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`,`road tools`],fileSvg:`svg/roadGuideArrowSolid.svg`},roadOutlineMesh:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`,`road tools`],fileSvg:`svg/roadOutlineMesh.svg`},roadPedestrianCrossing02:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`,`road tools`],fileSvg:`svg/roadPedestrianCrossing02.svg`},roadProfileWithCheckmark:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`,`road tools`],fileSvg:`svg/roadProfileWithCheckmark.svg`},roadProfile:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`,`road tools`],fileSvg:`svg/roadProfile.svg`},roadRoundaboutJunction:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`,`road tools`],fileSvg:`svg/roadRoundaboutJunction.svg`},roadSidewalkTransition:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`,`road tools`],fileSvg:`svg/roadSidewalkTransition.svg`},roadStackPlus:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`,`road tools`],fileSvg:`svg/roadStackPlus.svg`},roadStack:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`,`road tools`],fileSvg:`svg/roadStack.svg`},roadTJunction:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`,`road tools`],fileSvg:`svg/roadTJunction.svg`},roadXJunction:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`,`road tools`],fileSvg:`svg/roadXJunction.svg`},roadYJunction:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`,`road tools`],fileSvg:`svg/roadYJunction.svg`},shoppingCart:{glyph:``,size:24,tags:[`generic`,`shop`,`purchase`],fileSvg:`svg/shoppingCart.svg`},singleLineToTerrain:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`,`road tools`],fileSvg:`svg/singleLineToTerrain.svg`},sphereOnMesh:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`,`road tools`],fileSvg:`svg/sphereOnMesh.svg`},twoLinesToTerrain:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`,`road tools`],fileSvg:`svg/twoLinesToTerrain.svg`},urbanRoad3To2Merge01:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`,`road tools`],fileSvg:`svg/urbanRoad3To2Merge01.svg`},urbanRoad3To2Merge02:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`,`road tools`],fileSvg:`svg/urbanRoad3To2Merge02.svg`},urbanRoadToHighwayTransition01:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`,`road tools`],fileSvg:`svg/urbanRoadToHighwayTransition01.svg`},urbanRoadToHighwayTransition02:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`,`road tools`],fileSvg:`svg/urbanRoadToHighwayTransition02.svg`},floppyDiskPlus:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/floppyDiskPlus.svg`},highwayMerge:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`,`road tools`],fileSvg:`svg/highwayMerge.svg`},highwaySeparate:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`,`road tools`],fileSvg:`svg/highwaySeparate.svg`},highwayShoulderMerge:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`,`road tools`],fileSvg:`svg/highwayShoulderMerge.svg`},terrainToSingleLine:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`,`road tools`],fileSvg:`svg/terrainToSingleLine.svg`},terrainToTwoLines:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`,`road tools`],fileSvg:`svg/terrainToTwoLines.svg`},urbanRoadMerge:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`,`road tools`],fileSvg:`svg/urbanRoadMerge.svg`},urbanRoadSeparate:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`,`road tools`],fileSvg:`svg/urbanRoadSeparate.svg`},urbanShoulderMerge:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`,`road tools`],fileSvg:`svg/urbanShoulderMerge.svg`},discharging:{glyph:``,size:24,tags:[`fuel`,`electricity`,`ev`],fileSvg:`svg/discharging.svg`},BNGChat:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/BNGChat.svg`},chatBubble:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/chatBubble.svg`},busTilted:{glyph:``,size:24,tags:[`poi`,`vehicle`,`bus`],fileSvg:`svg/busTilted.svg`},cameraFarClip:{glyph:``,size:24,tags:[`decals`,`generic`],fileSvg:`svg/cameraFarClip.svg`},cameraNearClip:{glyph:``,size:24,tags:[`decals`,`generic`],fileSvg:`svg/cameraNearClip.svg`},explosion:{glyph:``,size:24,tags:[`generic`,`destruction`],fileSvg:`svg/explosion.svg`},fireExtinguisher:{glyph:``,size:24,tags:[`generic`,`destruction`],fileSvg:`svg/fireExtinguisher.svg`},fire:{glyph:``,size:24,tags:[`generic`,`destruction`],fileSvg:`svg/fire.svg`},jointLockedMultiple:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/jointLockedMultiple.svg`},jointUnlockedMultiple:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/jointUnlockedMultiple.svg`},toggleOff:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/toggleOff.svg`},toggleOn:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/toggleOn.svg`},viewFarClip:{glyph:``,size:24,tags:[`decals`,`generic`],fileSvg:`svg/viewFarClip.svg`},viewNearClip:{glyph:``,size:24,tags:[`decals`,`generic`],fileSvg:`svg/viewNearClip.svg`},twoArrowsHorizontal:{glyph:``,size:24,tags:[`arrow`,`large`,`solid`,`turn signals`],fileSvg:`svg/twoArrowsHorizontal.svg`},twoArrowsVertical:{glyph:``,size:24,tags:[`arrow`,`large`,`solid`,`turn signals`],fileSvg:`svg/twoArrowsVertical.svg`},bridge:{glyph:``,size:48,tags:[`rally`,`pace notes`,`directions`,`surface`,`features`],fileSvg:`svg/bridge.svg`},bump:{glyph:``,size:48,tags:[`rally`,`pace notes`,`directions`,`surface`,`features`],fileSvg:`svg/bump.svg`},bumps:{glyph:``,size:48,tags:[`rally`,`pace notes`,`directions`,`surface`,`features`],fileSvg:`svg/bumps.svg`},caution:{glyph:``,size:48,tags:[`rally`,`pace notes`,`directions`,`surface`,`features`],fileSvg:`svg/caution.svg`},crest:{glyph:``,size:48,tags:[`rally`,`pace notes`,`directions`,`surface`,`features`],fileSvg:`svg/crest.svg`},doubleCaution:{glyph:``,size:48,tags:[`rally`,`pace notes`,`directions`,`surface`,`features`],fileSvg:`svg/doubleCaution.svg`},finish:{glyph:``,size:48,tags:[`rally`,`pace notes`,`directions`,`surface`,`features`],fileSvg:`svg/finish.svg`},jumpOverBump:{glyph:``,size:48,tags:[`rally`,`pace notes`,`directions`,`surface`,`features`],fileSvg:`svg/jumpOverBump.svg`},narrows:{glyph:``,size:48,tags:[`rally`,`pace notes`,`directions`,`surface`,`features`],fileSvg:`svg/narrows.svg`},pothole:{glyph:``,size:48,tags:[`rally`,`pace notes`,`directions`,`surface`,`features`],fileSvg:`svg/pothole.svg`},turn1:{glyph:``,size:48,tags:[`rally`,`pace notes`,`directions`,`surface`,`features`],fileSvg:`svg/turn1.svg`},turn2:{glyph:``,size:48,tags:[`rally`,`pace notes`,`directions`,`surface`,`features`],fileSvg:`svg/turn2.svg`},turn3:{glyph:``,size:48,tags:[`rally`,`pace notes`,`directions`,`surface`,`features`],fileSvg:`svg/turn3.svg`},turn4:{glyph:``,size:48,tags:[`rally`,`pace notes`,`directions`,`surface`,`features`],fileSvg:`svg/turn4.svg`},turn5:{glyph:``,size:48,tags:[`rally`,`pace notes`,`directions`,`surface`,`features`],fileSvg:`svg/turn5.svg`},turn6:{glyph:``,size:48,tags:[`rally`,`pace notes`,`directions`,`surface`,`features`],fileSvg:`svg/turn6.svg`},turnHp:{glyph:``,size:48,tags:[`rally`,`pace notes`,`directions`,`surface`,`features`],fileSvg:`svg/turnHp.svg`},turnSq:{glyph:``,size:48,tags:[`rally`,`pace notes`,`directions`,`surface`,`features`],fileSvg:`svg/turnSq.svg`},water:{glyph:``,size:48,tags:[`rally`,`pace notes`,`directions`,`surface`,`features`],fileSvg:`svg/water.svg`},circleSlashed:{glyph:``,size:24,tags:[`generic`,`do not cut`,`no entry`],fileSvg:`svg/circleSlashed.svg`},scissorsSlashed:{glyph:``,size:24,tags:[`generic`,`do not cut`],fileSvg:`svg/scissorsSlashed.svg`},scissors:{glyph:``,size:24,tags:[`generic`,`cut`],fileSvg:`svg/scissors.svg`},airPuffRight1:{glyph:``,size:24,tags:[`generic`,`vehicle`,`car`],fileSvg:`svg/airPuffRight1.svg`},airPuffUp1:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/airPuffUp1.svg`},arrowsReplace:{glyph:``,size:24,tags:[`generic`,`arrow`],fileSvg:`svg/arrowsReplace.svg`},arrowsShuffle:{glyph:``,size:24,tags:[`generic`,`arrow`],fileSvg:`svg/arrowsShuffle.svg`},arrowsSwitch:{glyph:``,size:24,tags:[`generic`,`arrow`],fileSvg:`svg/arrowsSwitch.svg`},carClock:{glyph:``,size:24,tags:[`generic`,`vehicle`],fileSvg:`svg/carClock.svg`},carFast:{glyph:``,size:24,tags:[`vehicle`],fileSvg:`svg/carFast.svg`},carNumber1:{glyph:``,size:24,tags:[`generic`,`vehicle`],fileSvg:`svg/carNumber1.svg`},carNumber2:{glyph:``,size:24,tags:[`generic`,`vehicle`],fileSvg:`svg/carNumber2.svg`},carNumber3:{glyph:``,size:24,tags:[`generic`,`vehicle`],fileSvg:`svg/carNumber3.svg`},carNumber4:{glyph:``,size:24,tags:[`generic`,`vehicle`],fileSvg:`svg/carNumber4.svg`},carNumber5:{glyph:``,size:24,tags:[`generic`,`vehicle`],fileSvg:`svg/carNumber5.svg`},carNumber6:{glyph:``,size:24,tags:[`generic`,`vehicle`],fileSvg:`svg/carNumber6.svg`},carNumber7:{glyph:``,size:24,tags:[`generic`,`vehicle`],fileSvg:`svg/carNumber7.svg`},carNumber8:{glyph:``,size:24,tags:[`generic`,`vehicle`],fileSvg:`svg/carNumber8.svg`},carNumber9:{glyph:``,size:24,tags:[`generic`,`vehicle`],fileSvg:`svg/carNumber9.svg`},carPlus:{glyph:``,size:24,tags:[`generic`,`vehicle`],fileSvg:`svg/carPlus.svg`},carsChange:{glyph:``,size:24,tags:[`vehicle`,`select`],fileSvg:`svg/carsChange.svg`},carsFollow:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/carsFollow.svg`},doorFrontDetached:{glyph:``,size:24,tags:[`vehicle`,`part`,`features`],fileSvg:`svg/doorFrontDetached.svg`},forceFieldPull1:{glyph:``,size:24,tags:[`physics`,`field`,`force`],fileSvg:`svg/forceFieldPull1.svg`},forceFieldPull2:{glyph:``,size:24,tags:[`physics`,`field`,`force`],fileSvg:`svg/forceFieldPull2.svg`},forceFieldPull3:{glyph:``,size:24,tags:[`physics`,`field`,`force`],fileSvg:`svg/forceFieldPull3.svg`},forceFieldPush1:{glyph:``,size:24,tags:[`physics`,`field`,`force`],fileSvg:`svg/forceFieldPush1.svg`},forceFieldPush2:{glyph:``,size:24,tags:[`physics`,`field`,`force`],fileSvg:`svg/forceFieldPush2.svg`},forceFieldPush3:{glyph:``,size:24,tags:[`physics`,`field`,`force`],fileSvg:`svg/forceFieldPush3.svg`},garageNumber1:{glyph:``,size:24,tags:[`career`,`garage number`,`features`],fileSvg:`svg/garageNumber1.svg`},garageNumber2:{glyph:``,size:24,tags:[`career`,`garage number`,`features`],fileSvg:`svg/garageNumber2.svg`},garageNumber3:{glyph:``,size:24,tags:[`career`,`garage number`,`features`],fileSvg:`svg/garageNumber3.svg`},garageNumber4:{glyph:``,size:24,tags:[`career`,`garage number`,`features`],fileSvg:`svg/garageNumber4.svg`},garageNumber5:{glyph:``,size:24,tags:[`career`,`garage number`,`features`],fileSvg:`svg/garageNumber5.svg`},garageNumber6:{glyph:``,size:24,tags:[`career`,`garage number`,`features`],fileSvg:`svg/garageNumber6.svg`},garageNumber7:{glyph:``,size:24,tags:[`career`,`garage number`,`features`],fileSvg:`svg/garageNumber7.svg`},garageNumber8:{glyph:``,size:24,tags:[`career`,`garage number`,`features`],fileSvg:`svg/garageNumber8.svg`},garageNumber9:{glyph:``,size:24,tags:[`career`,`garage number`,`features`],fileSvg:`svg/garageNumber9.svg`},hingeBroken:{glyph:``,size:24,tags:[`vehicle`,`part`,`features`],fileSvg:`svg/hingeBroken.svg`},loadMesh:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/loadMesh.svg`},octagonBrick:{glyph:``,size:24,tags:[`generic`,`vehicle`,`car`],fileSvg:`svg/octagonBrick.svg`},octagon:{glyph:``,size:24,tags:[`generic`,`vehicle`,`car`],fileSvg:`svg/octagon.svg`},pushUp:{glyph:``,size:24,tags:[`physics`,`force`],fileSvg:`svg/pushUp.svg`},saveMesh:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/saveMesh.svg`},square:{glyph:``,size:24,tags:[`playback`,`stop`],fileSvg:`svg/square.svg`},tireAirPuff:{glyph:``,size:24,tags:[`vehicle`,`car`],fileSvg:`svg/tireAirPuff.svg`},tireDeflated:{glyph:``,size:24,tags:[`vehicle`,`car`],fileSvg:`svg/tireDeflated.svg`},trafficLight:{glyph:``,size:24,tags:[`generic`,`traffic`,`roads`],fileSvg:`svg/trafficLight.svg`},enter:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/enter.svg`},pedestrianRunning:{glyph:``,size:24,tags:[`generic`,`sign`,`pedestrian`,`traffic`],fileSvg:`svg/pedestrianRunning.svg`},pedestrianStanding:{glyph:``,size:24,tags:[`generic`,`sign`,`pedestrian`,`traffic`],fileSvg:`svg/pedestrianStanding.svg`},seatArrowIn:{glyph:``,size:24,tags:[`generic`,`arrow`,`actions`],fileSvg:`svg/seatArrowIn.svg`},seatArrowOut:{glyph:``,size:24,tags:[`generic`,`arrow`,`actions`],fileSvg:`svg/seatArrowOut.svg`},seatVArrowIn:{glyph:``,size:24,tags:[`generic`,`arrow`,`actions`],fileSvg:`svg/seatVArrowIn.svg`},seatVArrowOut:{glyph:``,size:24,tags:[`generic`,`arrow`,`actions`],fileSvg:`svg/seatVArrowOut.svg`},vehicleArrowIn:{glyph:``,size:24,tags:[`generic`,`arrow`,`actions`],fileSvg:`svg/vehicleArrowIn.svg`},vehicleArrowOut:{glyph:``,size:24,tags:[`generic`,`arrow`,`actions`],fileSvg:`svg/vehicleArrowOut.svg`},leverFrontOperate:{glyph:``,size:24,tags:[`generic`,`actions`],fileSvg:`svg/leverFrontOperate.svg`},leverSideDown:{glyph:``,size:24,tags:[`generic`,`actions`],fileSvg:`svg/leverSideDown.svg`},leverSideOperate:{glyph:``,size:24,tags:[`generic`,`actions`],fileSvg:`svg/leverSideOperate.svg`},leverSideUp:{glyph:``,size:24,tags:[`generic`,`actions`],fileSvg:`svg/leverSideUp.svg`},medalEmpty:{glyph:``,size:24,tags:[`generic`,`reward`,`achievment`],fileSvg:`svg/medalEmpty.svg`},medalStar:{glyph:``,size:24,tags:[`generic`,`reward`,`achievment`],fileSvg:`svg/medalStar.svg`},seatArrowInLeft:{glyph:``,size:24,tags:[`generic`,`arrow`,`actions`],fileSvg:`svg/seatArrowInLeft.svg`},seatArrowOutLeft:{glyph:``,size:24,tags:[`generic`,`arrow`,`actions`],fileSvg:`svg/seatArrowOutLeft.svg`},seatVArrowInLeft:{glyph:``,size:24,tags:[`generic`,`arrow`,`actions`],fileSvg:`svg/seatVArrowInLeft.svg`},seatVArrowOutLeft:{glyph:``,size:24,tags:[`generic`,`arrow`,`actions`],fileSvg:`svg/seatVArrowOutLeft.svg`},badgeRoundEmpty:{glyph:``,size:24,tags:[`generic`,`reward`,`achievment`],fileSvg:`svg/badgeRoundEmpty.svg`},badgeRoundStar:{glyph:``,size:24,tags:[`generic`,`reward`,`achievment`],fileSvg:`svg/badgeRoundStar.svg`},badgeRound:{glyph:``,size:24,tags:[`generic`,`reward`,`achievment`],fileSvg:`svg/badgeRound.svg`},badge:{glyph:``,size:24,tags:[`generic`,`reward`,`achievment`],fileSvg:`svg/badge.svg`},beamCurrencyOutlineLarge:{glyph:``,size:48,tags:[`outline`,`generic`,`currency`],fileSvg:`svg/beamCurrencyOutlineLarge.svg`},carSideOutlineLarge:{glyph:``,size:48,tags:[`generic`,`vehicle`],fileSvg:`svg/carSideOutlineLarge.svg`},flagOutlineLarge:{glyph:``,size:48,tags:[`generic`,`mission`,`scenario`],fileSvg:`svg/flagOutlineLarge.svg`},terrainOutlineLarge:{glyph:``,size:48,tags:[`generic`],fileSvg:`svg/terrainOutlineLarge.svg`},houseWrenchRoof:{glyph:``,size:24,tags:[`career`,`garage`,`features`,`house`],fileSvg:`svg/houseWrenchRoof.svg`},houseWrench:{glyph:``,size:24,tags:[`career`,`garage`,`features`,`house`],fileSvg:`svg/houseWrench.svg`},eject:{glyph:``,size:24,tags:[`playback`],fileSvg:`svg/eject.svg`},rallyHelmet3To4:{glyph:``,size:24,tags:[`helmet`,`rally`,`generic`,`racing`,`game mode`],fileSvg:`svg/rallyHelmet3To4.svg`},rallyHelmet:{glyph:``,size:24,tags:[`helmet`,`rally`,`generic`,`racing`,`game mode`],fileSvg:`svg/rallyHelmet.svg`},test:{glyph:``,size:24,tags:[`generic`,`hazard`],fileSvg:`svg/test.svg`},tripleCaution:{glyph:``,size:48,tags:[`rally`,`pace notes`,`directions`,`surface`,`features`],fileSvg:`svg/tripleCaution.svg`},globeSimpleNotSign:{glyph:``,size:24,tags:[`generic`,`offline`],fileSvg:`svg/globeSimpleNotSign.svg`},globeSimplified:{glyph:``,size:24,tags:[`generic`,`online`],fileSvg:`svg/globeSimplified.svg`},radialMenu:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/radialMenu.svg`},branch:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/branch.svg`},NA:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/NA.svg`},psCircleOutline:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/psCircleOutline.svg`},psCircle:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/psCircle.svg`},psCreate2:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/psCreate2.svg`},psCreate:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/psCreate.svg`},psCrossOutline:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/psCrossOutline.svg`},psCross:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/psCross.svg`},psDDefaultOutline:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/psDDefaultOutline.svg`},psDDefaultSolid:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/psDDefaultSolid.svg`},psDDown:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/psDDown.svg`},psDLeft:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/psDLeft.svg`},psDRight:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/psDRight.svg`},psDUp:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/psDUp.svg`},psL1:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/psL1.svg`},psL2:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/psL2.svg`},psL3ButtonArrowDown:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/psL3ButtonArrowDown.svg`},psL3Button:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/psL3Button.svg`},psLSXLeft:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/psLSXLeft.svg`},psLSXRight:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/psLSXRight.svg`},psLSX:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/psLSX.svg`},psLSYDown:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/psLSYDown.svg`},psLSYUp:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/psLSYUp.svg`},psLSY:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/psLSY.svg`},psLS:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/psLS.svg`},psMenu2:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/psMenu2.svg`},psMenu:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/psMenu.svg`},psR1:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/psR1.svg`},psR2:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/psR2.svg`},psR3ButtonArrowDown:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/psR3ButtonArrowDown.svg`},psR3Button:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/psR3Button.svg`},psRSXLeft:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/psRSXLeft.svg`},psRSXRight:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/psRSXRight.svg`},psRSX:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/psRSX.svg`},psRSYDown:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/psRSYDown.svg`},psRSYUp:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/psRSYUp.svg`},psRSY:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/psRSY.svg`},psRS:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/psRS.svg`},psSquareOutline:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/psSquareOutline.svg`},psSquare:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/psSquare.svg`},psTrackpadNavigate:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/psTrackpadNavigate.svg`},psTrackpadPressCenter:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/psTrackpadPressCenter.svg`},psTrackpadPressLeft:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/psTrackpadPressLeft.svg`},psTrackpadPressRight:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/psTrackpadPressRight.svg`},psTrackpadSwipeDown:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/psTrackpadSwipeDown.svg`},psTrackpadSwipeLeft:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/psTrackpadSwipeLeft.svg`},psTrackpadSwipeRight:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/psTrackpadSwipeRight.svg`},psTrackpadSwipeUp:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/psTrackpadSwipeUp.svg`},psTriangleOutline:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/psTriangleOutline.svg`},psTriangle:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/psTriangle.svg`},xboxAOutline:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/xboxAOutline.svg`},xboxBOutline:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/xboxBOutline.svg`},xboxLSButtonArrowDown:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/xboxLSButtonArrowDown.svg`},xboxRSButtonArrowDown:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/xboxRSButtonArrowDown.svg`},xboxXAxisLeft:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/xboxXAxisLeft.svg`},xboxXAxisRight:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/xboxXAxisRight.svg`},xboxXOutline:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/xboxXOutline.svg`},xboxXRotLeft:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/xboxXRotLeft.svg`},xboxXRotRight:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/xboxXRotRight.svg`},xboxYAxisDown:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/xboxYAxisDown.svg`},xboxYAxisUp:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/xboxYAxisUp.svg`},xboxYOutline:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/xboxYOutline.svg`},xboxYRotDown:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/xboxYRotDown.svg`},xboxYRotUp:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/xboxYRotUp.svg`},cableSection:{glyph:``,size:24,tags:[`material`,`beam`,`strap`],fileSvg:`svg/cableSection.svg`},strapHook:{glyph:``,size:24,tags:[`material`,`strap`],fileSvg:`svg/strapHook.svg`},strapRatchet:{glyph:``,size:24,tags:[`material`,`strap`],fileSvg:`svg/strapRatchet.svg`},carFastReverse:{glyph:``,size:24,tags:[`vehicle`],fileSvg:`svg/carFastReverse.svg`},carsChase:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/carsChase.svg`},carsFlee:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/carsFlee.svg`},gaugeFull:{glyph:``,size:24,tags:[`poi`],fileSvg:`svg/gaugeFull.svg`},hammerParticles:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/hammerParticles.svg`},kbArrowsDown:{glyph:``,size:24,tags:[`keyboard`,`controls`],fileSvg:`svg/kbArrowsDown.svg`},kbArrowsLeftRight:{glyph:``,size:24,tags:[`keyboard`,`controls`],fileSvg:`svg/kbArrowsLeftRight.svg`},kbArrowsLeft:{glyph:``,size:24,tags:[`keyboard`,`controls`],fileSvg:`svg/kbArrowsLeft.svg`},kbArrowsOutline:{glyph:``,size:24,tags:[`keyboard`,`controls`],fileSvg:`svg/kbArrowsOutline.svg`},kbArrowsRight:{glyph:``,size:24,tags:[`keyboard`,`controls`],fileSvg:`svg/kbArrowsRight.svg`},kbArrowsSolid:{glyph:``,size:24,tags:[`keyboard`,`controls`],fileSvg:`svg/kbArrowsSolid.svg`},kbArrowsUpDown:{glyph:``,size:24,tags:[`keyboard`,`controls`],fileSvg:`svg/kbArrowsUpDown.svg`},kbArrowsUp:{glyph:``,size:24,tags:[`keyboard`,`controls`],fileSvg:`svg/kbArrowsUp.svg`},magicWand:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/magicWand.svg`},psDLeftRight:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/psDLeftRight.svg`},psDUpDown:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/psDUpDown.svg`},pushBackward:{glyph:``,size:24,tags:[`physics`,`force`],fileSvg:`svg/pushBackward.svg`},pushDown:{glyph:``,size:24,tags:[`physics`,`force`],fileSvg:`svg/pushDown.svg`},pushForward:{glyph:``,size:24,tags:[`physics`,`force`],fileSvg:`svg/pushForward.svg`},rangeboxHi:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/rangeboxHi.svg`},rangeboxLo:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/rangeboxLo.svg`},routeSimpleFlag:{glyph:``,size:24,tags:[`route`,`traffic`],fileSvg:`svg/routeSimpleFlag.svg`},xboxDLeftRight:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/xboxDLeftRight.svg`},xboxDUpDown:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/xboxDUpDown.svg`},carsWrench:{glyph:``,size:24,tags:[`vehicle`,`select`],fileSvg:`svg/carsWrench.svg`},jointCycleMultiple:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/jointCycleMultiple.svg`},jointCycle:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/jointCycle.svg`},dice24:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/dice24.svg`},diceD6:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/diceD6.svg`},pathDice:{glyph:``,size:24,tags:[`camera`],fileSvg:`svg/pathDice.svg`},sunDown:{glyph:``,size:24,tags:[`environment`],fileSvg:`svg/sunDown.svg`},xmarkBold:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/xmarkBold.svg`},intakeTrumpets:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/intakeTrumpets.svg`},transmissionCvt:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/transmissionCvt.svg`},house:{glyph:``,size:24,tags:[`career`,`generic`,`garage`,`features`,`house`],fileSvg:`svg/house.svg`},playPause:{glyph:``,size:24,tags:[`playback`],fileSvg:`svg/playPause.svg`},picture:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/picture.svg`},auxUpDown:{glyph:``,size:24,tags:[`vehicle`,`features`,`equipment`],fileSvg:`svg/auxUpDown.svg`},bucketArmUpDown:{glyph:``,size:24,tags:[`vehicle`,`features`,`equipment`],fileSvg:`svg/bucketArmUpDown.svg`},bucketTilt:{glyph:``,size:24,tags:[`vehicle`,`features`,`equipment`],fileSvg:`svg/bucketTilt.svg`},bucketArmDown:{glyph:``,size:24,tags:[`vehicle`,`features`,`equipment`],fileSvg:`svg/bucketArmDown.svg`},bucketArmLevel:{glyph:``,size:24,tags:[`vehicle`,`features`,`equipment`],fileSvg:`svg/bucketArmLevel.svg`},bucketArmUp:{glyph:``,size:24,tags:[`vehicle`,`features`,`equipment`],fileSvg:`svg/bucketArmUp.svg`},bucketTiltDown:{glyph:``,size:24,tags:[`vehicle`,`features`,`equipment`],fileSvg:`svg/bucketTiltDown.svg`},bucketTiltLevel:{glyph:``,size:24,tags:[`vehicle`,`features`,`equipment`],fileSvg:`svg/bucketTiltLevel.svg`},bucketTiltUp:{glyph:``,size:24,tags:[`vehicle`,`features`,`equipment`],fileSvg:`svg/bucketTiltUp.svg`},dumpBedDown:{glyph:``,size:24,tags:[`vehicle`,`features`,`equipment`],fileSvg:`svg/dumpBedDown.svg`},dumpBedUpDown:{glyph:``,size:24,tags:[`vehicle`,`features`,`equipment`],fileSvg:`svg/dumpBedUpDown.svg`},dumpBedUp:{glyph:``,size:24,tags:[`vehicle`,`features`,`equipment`],fileSvg:`svg/dumpBedUp.svg`},beamCurrencyThin:{glyph:``,size:24,tags:[`career`,`currencies`],fileSvg:`svg/beamCurrencyThin.svg`},shieldCheckmarkProgressbar:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/shieldCheckmarkProgressbar.svg`}}),iconsBySize=Object.freeze({16:{arrowsUp:icons$2.arrowsUp,bigDot:icons$2.bigDot,connectorBold:icons$2.connectorBold,cornerTopRight:icons$2.cornerTopRight,plusBold:icons$2.plusBold,puzzlePieceBold:icons$2.puzzlePieceBold},24:{"4WD":icons$2[`4WD`],"9dividedby10":icons$2[`9dividedby10`],abandon:icons$2.abandon,ABSIndicator:icons$2.ABSIndicator,addItemPolygon:icons$2.addItemPolygon,addListItem:icons$2.addListItem,addPolygonVertex:icons$2.addPolygonVertex,adjust:icons$2.adjust,AIMicrochip:icons$2.AIMicrochip,AIRace:icons$2.AIRace,aperture:icons$2.aperture,arrowLargeDown:icons$2.arrowLargeDown,arrowLargeLeft:icons$2.arrowLargeLeft,arrowLargeRight:icons$2.arrowLargeRight,arrowLargeUp:icons$2.arrowLargeUp,arrowSmallDown:icons$2.arrowSmallDown,arrowSmallLeft:icons$2.arrowSmallLeft,arrowSmallRight:icons$2.arrowSmallRight,arrowSmallUp:icons$2.arrowSmallUp,arrowSolidLeft:icons$2.arrowSolidLeft,arrowSolidRight:icons$2.arrowSolidRight,autobahn:icons$2.autobahn,AWD:icons$2.AWD,axleLift:icons$2.axleLift,axleCenter:icons$2.axleCenter,axleFront:icons$2.axleFront,axleRear:icons$2.axleRear,bSpline:icons$2.bSpline,banknotes:icons$2.banknotes,barrelKnocker01:icons$2.barrelKnocker01,barrelKnocker02:icons$2.barrelKnocker02,beamCrashBarrier1:icons$2.beamCrashBarrier1,beamCrashBarrier2:icons$2.beamCrashBarrier2,beamCrashBarrier3:icons$2.beamCrashBarrier3,beamCurrency:icons$2.beamCurrency,beamNG:icons$2.beamNG,beamXPFull:icons$2.beamXPFull,beamXPLo:icons$2.beamXPLo,bezierPath1:icons$2.bezierPath1,bezierPath2:icons$2.bezierPath2,bicycle1:icons$2.bicycle1,bicycle2:icons$2.bicycle2,BNGFolder:icons$2.BNGFolder,BNGMicrochip:icons$2.BNGMicrochip,bollard:icons$2.bollard,bookmark:icons$2.bookmark,booleanIntersect:icons$2.booleanIntersect,boxDropOff01:icons$2.boxDropOff01,boxDropOff02:icons$2.boxDropOff02,boxDropOff03:icons$2.boxDropOff03,boxPickUp01:icons$2.boxPickUp01,boxPickUp02:icons$2.boxPickUp02,boxPickUp03:icons$2.boxPickUp03,boxPickUpDropOff01:icons$2.boxPickUpDropOff01,boxPickUpDropOff02:icons$2.boxPickUpDropOff02,boxTruck:icons$2.boxTruck,broom:icons$2.broom,bucketAdd:icons$2.bucketAdd,bucketSubtract:icons$2.bucketSubtract,bug:icons$2.bug,bulldozer:icons$2.bulldozer,bus:icons$2.bus,camera3Fourth1:icons$2.camera3Fourth1,cameraBack1:icons$2.cameraBack1,cameraFocusOnPath:icons$2.cameraFocusOnPath,cameraFocusOnVehicle1:icons$2.cameraFocusOnVehicle1,cameraFocusOnVehicle2:icons$2.cameraFocusOnVehicle2,cameraFocusTopDown:icons$2.cameraFocusTopDown,cameraFront1:icons$2.cameraFront1,cameraSideLeft:icons$2.cameraSideLeft,cameraSideLeft2:icons$2.cameraSideLeft2,cameraSideRight:icons$2.cameraSideRight,cameraSideRight2:icons$2.cameraSideRight2,cameraTop1:icons$2.cameraTop1,cannon:icons$2.cannon,carChase01:icons$2.carChase01,carCoin:icons$2.carCoin,carCoins:icons$2.carCoins,carCrash:icons$2.carCrash,carDealer:icons$2.carDealer,carOffroadOutlineRear:icons$2.carOffroadOutlineRear,carOffroadOutlineSide:icons$2.carOffroadOutlineSide,carOffroadRear:icons$2.carOffroadRear,carOffroadSide:icons$2.carOffroadSide,carSensors:icons$2.carSensors,carStarred:icons$2.carStarred,carToWheels:icons$2.carToWheels,carUp:icons$2.carUp,carWithLidar:icons$2.carWithLidar,car:icons$2.car,cardboardBox:icons$2.cardboardBox,carsChase02:icons$2.carsChase02,cars:icons$2.cars,catalog01:icons$2.catalog01,catalog02:icons$2.catalog02,catalog03:icons$2.catalog03,centrifugalClutchLocked03:icons$2.centrifugalClutchLocked03,centrifugalClutchUnlocked03:icons$2.centrifugalClutchUnlocked03,charge:icons$2.charge,charging:icons$2.charging,chartBars:icons$2.chartBars,checkboxOff:icons$2.checkboxOff,checkboxOn:icons$2.checkboxOn,checkmarkBold:icons$2.checkmarkBold,checkmark:icons$2.checkmark,circuitMicrochip:icons$2.circuitMicrochip,circuit:icons$2.circuit,clapperboard:icons$2.clapperboard,code:icons$2.code,cogDamaged:icons$2.cogDamaged,cogsDamaged:icons$2.cogsDamaged,cogs:icons$2.cogs,concreteRoadBlock:icons$2.concreteRoadBlock,coolantTemp:icons$2.coolantTemp,copy:icons$2.copy,crossroads1:icons$2.crossroads1,crossroads2:icons$2.crossroads2,cruiseDisable:icons$2.cruiseDisable,cruiseEnable:icons$2.cruiseEnable,cup:icons$2.cup,dataExchange:icons$2.dataExchange,day:icons$2.day,DCBattery:icons$2.DCBattery,decalRoad:icons$2.decalRoad,decal:icons$2.decal,deform:icons$2.deform,deliveryTruckArrows:icons$2.deliveryTruckArrows,deliveryTruck:icons$2.deliveryTruck,differentialFrontDefault:icons$2.differentialFrontDefault,differentialFrontLocked:icons$2.differentialFrontLocked,differentialMiddleDefault:icons$2.differentialMiddleDefault,differentialMiddleLocked:icons$2.differentialMiddleLocked,differentialRearDefault:icons$2.differentialRearDefault,differentialRearLocked:icons$2.differentialRearLocked,doorHandle:icons$2.doorHandle,doorIn:icons$2.doorIn,drag01:icons$2.drag01,drag02:icons$2.drag02,drift01:icons$2.drift01,drift02:icons$2.drift02,drivetrainGeneric:icons$2.drivetrainGeneric,drivetrainSpecial:icons$2.drivetrainSpecial,editCheckmark:icons$2.editCheckmark,edit:icons$2.edit,engine:icons$2.engine,ESCOff:icons$2.ESCOff,ESCOn:icons$2.ESCOn,ESC:icons$2.ESC,evade:icons$2.evade,exhaustValve:icons$2.exhaustValve,exit:icons$2.exit,export:icons$2.export,eyeOutlineClosed:icons$2.eyeOutlineClosed,eyeOutlineOpened:icons$2.eyeOutlineOpened,eyeSolidClosed:icons$2.eyeSolidClosed,eyeSolidOpened:icons$2.eyeSolidOpened,eyeWaves:icons$2.eyeWaves,facility02:icons$2.facility02,fastBackward:icons$2.fastBackward,fastForward:icons$2.fastForward,fastTravel:icons$2.fastTravel,filter:icons$2.filter,flagNew:icons$2.flagNew,flag:icons$2.flag,flatBulbBeam:icons$2.flatBulbBeam,flatbedTruck:icons$2.flatbedTruck,floppyDisk:icons$2.floppyDisk,fogLight:icons$2.fogLight,folder:icons$2.folder,forklift:icons$2.forklift,FPS:icons$2.FPS,fragile:icons$2.fragile,frontAxleMidpoint:icons$2.frontAxleMidpoint,frontBumperMidpoint:icons$2.frontBumperMidpoint,fuelPumpFilling:icons$2.fuelPumpFilling,fuelPump:icons$2.fuelPump,FWD:icons$2.FWD,gamepadOld:icons$2.gamepadOld,gamepad:icons$2.gamepad,garage01:icons$2.garage01,garage02:icons$2.garage02,garage03:icons$2.garage03,gaugeEmpty:icons$2.gaugeEmpty,globe:icons$2.globe,GPSMark:icons$2.GPSMark,GPSSolid:icons$2.GPSSolid,group:icons$2.group,gyroscopeMicrochip:icons$2.gyroscopeMicrochip,gyroscope:icons$2.gyroscope,hazardLights:icons$2.hazardLights,helmets:icons$2.helmets,help:icons$2.help,highBeam:icons$2.highBeam,HUD:icons$2.HUD,hydroPump1:icons$2.hydroPump1,hydroPump2:icons$2.hydroPump2,hydroPump3:icons$2.hydroPump3,hydroPump4:icons$2.hydroPump4,hydroPump5:icons$2.hydroPump5,hydroPump6:icons$2.hydroPump6,hydroPump7:icons$2.hydroPump7,hypermiling:icons$2.hypermiling,import:icons$2.import,infinity:icons$2.infinity,info:icons$2.info,jointLocked:icons$2.jointLocked,jointUnlocked:icons$2.jointUnlocked,jump:icons$2.jump,keyboard:icons$2.keyboard,keys1:icons$2.keys1,keys2:icons$2.keys2,lampPost1:icons$2.lampPost1,lampPost2:icons$2.lampPost2,lampPost3:icons$2.lampPost3,laneProperties:icons$2.laneProperties,language:icons$2.language,laptop:icons$2.laptop,lidarPatternFullArcHighFreq:icons$2.lidarPatternFullArcHighFreq,lidarPatternFullArcMidFreq:icons$2.lidarPatternFullArcMidFreq,lidarPatternNarrowArc:icons$2.lidarPatternNarrowArc,lidar:icons$2.lidar,lightGarageG11:icons$2.lightGarageG11,lightGarageG12:icons$2.lightGarageG12,lightGarageG13:icons$2.lightGarageG13,lightGarageG14:icons$2.lightGarageG14,lightGarageG21:icons$2.lightGarageG21,lightGarageG22:icons$2.lightGarageG22,lightGarageG23:icons$2.lightGarageG23,lightGarageG24:icons$2.lightGarageG24,lightGarageG31:icons$2.lightGarageG31,lightGarageG32:icons$2.lightGarageG32,lightGarageG33:icons$2.lightGarageG33,lightGarageG34:icons$2.lightGarageG34,lightrunner:icons$2.lightrunner,limiterEnable:icons$2.limiterEnable,lineToTerrain:icons$2.lineToTerrain,link2:icons$2.link2,link:icons$2.link,listBig:icons$2.listBig,listIndented:icons$2.listIndented,listSmall:icons$2.listSmall,location1:icons$2.location1,location2:icons$2.location2,lockClosed:icons$2.lockClosed,lockOpened:icons$2.lockOpened,longRangeBeam1:icons$2.longRangeBeam1,longRangeBeam2:icons$2.longRangeBeam2,lowBeam:icons$2.lowBeam,magnetOnSurface:icons$2.magnetOnSurface,mapWithEmitter:icons$2.mapWithEmitter,mapPoint:icons$2.mapPoint,material:icons$2.material,mathDivide:icons$2.mathDivide,mathGreaterOrEqualThan:icons$2.mathGreaterOrEqualThan,mathGreaterThan:icons$2.mathGreaterThan,mathLessOrEqualThan:icons$2.mathLessOrEqualThan,mathLessThan:icons$2.mathLessThan,mathMinus:icons$2.mathMinus,mathMultiply:icons$2.mathMultiply,mathPlus:icons$2.mathPlus,medal:icons$2.medal,mesh4Cells:icons$2.mesh4Cells,mesh9Cells:icons$2.mesh9Cells,meshFence:icons$2.meshFence,meshRoad:icons$2.meshRoad,midRangeBeam1:icons$2.midRangeBeam1,midRangeBeam2:icons$2.midRangeBeam2,minusRes:icons$2.minusRes,minus:icons$2.minus,mirrorInteriorMiddle:icons$2.mirrorInteriorMiddle,mirrorLeftBigBottomWideAngle:icons$2.mirrorLeftBigBottomWideAngle,mirrorLeftBigTop:icons$2.mirrorLeftBigTop,mirrorLeftBig:icons$2.mirrorLeftBig,mirrorLeftBonnet:icons$2.mirrorLeftBonnet,mirrorLeftDefault:icons$2.mirrorLeftDefault,mirrorRightBigBottomWideAngle:icons$2.mirrorRightBigBottomWideAngle,mirrorRightBigTop:icons$2.mirrorRightBigTop,mirrorRightBig:icons$2.mirrorRightBig,mirrorRightBonnet:icons$2.mirrorRightBonnet,mirrorRightDefault:icons$2.mirrorRightDefault,mirrorRoundWideAngle:icons$2.mirrorRoundWideAngle,mirrorTopWideAngle:icons$2.mirrorTopWideAngle,missionCheckboxCross:icons$2.missionCheckboxCross,mouseLMB:icons$2.mouseLMB,mouseMMB:icons$2.mouseMMB,mouseRMB:icons$2.mouseRMB,mouseWheel:icons$2.mouseWheel,mouseXAxis:icons$2.mouseXAxis,mouseXYAxis:icons$2.mouseXYAxis,mouseYAxis:icons$2.mouseYAxis,mouse:icons$2.mouse,move02:icons$2.move02,move:icons$2.move,movieCamera:icons$2.movieCamera,music:icons$2.music,N2OButton:icons$2.N2OButton,N2OHoriz:icons$2.N2OHoriz,N2OVert:icons$2.N2OVert,nextTrack:icons$2.nextTrack,night:icons$2.night,noNameControllerButton:icons$2.noNameControllerButton,nodeAddFirst01:icons$2.nodeAddFirst01,nodeAddFirst02:icons$2.nodeAddFirst02,nodeAddLast02:icons$2.nodeAddLast02,nodeAddMiddle01:icons$2.nodeAddMiddle01,nodeAddMiddle02:icons$2.nodeAddMiddle02,nodeAdd:icons$2.nodeAdd,nodeLast01:icons$2.nodeLast01,nodeRemove:icons$2.nodeRemove,odometerKM:icons$2.odometerKM,odometerMI:icons$2.odometerMI,odometer:icons$2.odometer,oilPressureIndicator:icons$2.oilPressureIndicator,order:icons$2.order,organization:icons$2.organization,palmCrossed:icons$2.palmCrossed,paperKnife:icons$2.paperKnife,parkingIndicator:icons$2.parkingIndicator,parking:icons$2.parking,pathArc:icons$2.pathArc,pathAroundObstacle:icons$2.pathAroundObstacle,pathLine:icons$2.pathLine,pathSpiral:icons$2.pathSpiral,pauseRound:icons$2.pauseRound,pause:icons$2.pause,personSolid:icons$2.personSolid,person:icons$2.person,photo:icons$2.photo,placeholder:icons$2.placeholder,playRound:icons$2.playRound,play:icons$2.play,playlist:icons$2.playlist,plusGarage1:icons$2.plusGarage1,plusGarage2:icons$2.plusGarage2,plusGarage3:icons$2.plusGarage3,plusGarage4:icons$2.plusGarage4,plusSet:icons$2.plusSet,plus:icons$2.plus,positionLights:icons$2.positionLights,powerGauge01:icons$2.powerGauge01,powerGauge02:icons$2.powerGauge02,powerGauge03:icons$2.powerGauge03,powerGauge04:icons$2.powerGauge04,powerGauge05:icons$2.powerGauge05,powerOnOff:icons$2.powerOnOff,prevTrack:icons$2.prevTrack,publisher:icons$2.publisher,puzzleModule:icons$2.puzzleModule,raceFlag:icons$2.raceFlag,radarIdeal:icons$2.radarIdeal,radarRoundIdeal:icons$2.radarRoundIdeal,radarRound:icons$2.radarRound,radar:icons$2.radar,rangeboxHi2:icons$2.rangeboxHi2,rangeboxHi4:icons$2.rangeboxHi4,rangeboxHiA:icons$2.rangeboxHiA,rangeboxLo2:icons$2.rangeboxLo2,rangeboxLo4:icons$2.rangeboxLo4,rangeboxLoA:icons$2.rangeboxLoA,rearAxleMidpoint:icons$2.rearAxleMidpoint,rearBumperMidpoint:icons$2.rearBumperMidpoint,reconfigure:icons$2.reconfigure,redo:icons$2.redo,reflectNot:icons$2.reflectNot,reflect:icons$2.reflect,rename:icons$2.rename,replay:icons$2.replay,restart:icons$2.restart,roadDividerLinesDecal:icons$2.roadDividerLinesDecal,roadEdgeLineDecal:icons$2.roadEdgeLineDecal,roadEndLineDecal:icons$2.roadEndLineDecal,roadFace:icons$2.roadFace,roadInfo:icons$2.roadInfo,roadMarkingOutline:icons$2.roadMarkingOutline,roadMarkingSolid:icons$2.roadMarkingSolid,roadOutline:icons$2.roadOutline,roadRefPathDecal:icons$2.roadRefPathDecal,roadRefPath:icons$2.roadRefPath,roadStartLineDecal:icons$2.roadStartLineDecal,road:icons$2.road,rockCrawling01:icons$2.rockCrawling01,rockCrawling02:icons$2.rockCrawling02,routeAdd:icons$2.routeAdd,routeComplex:icons$2.routeComplex,routeSimple:icons$2.routeSimple,runScript:icons$2.runScript,RWD:icons$2.RWD,saveAs1:icons$2.saveAs1,scan:icons$2.scan,search:icons$2.search,semiTrailer:icons$2.semiTrailer,semiTruckCabover:icons$2.semiTruckCabover,semiTruckUS:icons$2.semiTruckUS,semiTruck:icons$2.semiTruck,shortRangeBeam1:icons$2.shortRangeBeam1,shortRangeBeam2:icons$2.shortRangeBeam2,signal01a:icons$2.signal01a,signal02a:icons$2.signal02a,signal03a:icons$2.signal03a,signal04a:icons$2.signal04a,signal05a:icons$2.signal05a,slashLeft:icons$2.slashLeft,slashRight:icons$2.slashRight,smallTrailer:icons$2.smallTrailer,smartphone1:icons$2.smartphone1,smartphone2:icons$2.smartphone2,snowflake:icons$2.snowflake,soundFadeOut:icons$2.soundFadeOut,soundLimit:icons$2.soundLimit,soundLoud:icons$2.soundLoud,soundMonoL:icons$2.soundMonoL,soundMonoR:icons$2.soundMonoR,soundOff:icons$2.soundOff,soundQuiet:icons$2.soundQuiet,soundStereo:icons$2.soundStereo,soundWave01:icons$2.soundWave01,soundWave02:icons$2.soundWave02,sphereOnPathNumber:icons$2.sphereOnPathNumber,sphereOnPath:icons$2.sphereOnPath,sphericalBeam:icons$2.sphericalBeam,spoilerLift:icons$2.spoilerLift,sprayCan:icons$2.sprayCan,stack3:icons$2.stack3,star:icons$2.star,starSecondary:icons$2.starSecondary,steeringWheelCommon:icons$2.steeringWheelCommon,steeringWheelSporty:icons$2.steeringWheelSporty,stopwatchArrows01:icons$2.stopwatchArrows01,stopwatchArrows02:icons$2.stopwatchArrows02,stopwatchSectionOutlinedEnd:icons$2.stopwatchSectionOutlinedEnd,stopwatchSectionOutlinedStart:icons$2.stopwatchSectionOutlinedStart,stopwatchSectionSolidEnd:icons$2.stopwatchSectionSolidEnd,stopwatchSectionSolidStart:icons$2.stopwatchSectionSolidStart,strobeLights:icons$2.strobeLights,sunRise:icons$2.sunRise,survellianceCamera:icons$2.survellianceCamera,suspension01:icons$2.suspension01,suspension02:icons$2.suspension02,switchBlock:icons$2.switchBlock,switchOutline:icons$2.switchOutline,sync:icons$2.sync,synchro01:icons$2.synchro01,synchro02:icons$2.synchro02,tankerTrailer:icons$2.tankerTrailer,targetJump:icons$2.targetJump,taxiCar1:icons$2.taxiCar1,taxiCar3:icons$2.taxiCar3,taxiCarT:icons$2.taxiCarT,taxiCheckerLamp:icons$2.taxiCheckerLamp,terrainToLine:icons$2.terrainToLine,terrain:icons$2.terrain,thinBulbBeam:icons$2.thinBulbBeam,thinnerBulbBeam:icons$2.thinnerBulbBeam,thisSideUp:icons$2.thisSideUp,tiles:icons$2.tiles,timer:icons$2.timer,tireDirection3Fourth2:icons$2.tireDirection3Fourth2,tireDirection3Fourth3:icons$2.tireDirection3Fourth3,tireDirectionFront2:icons$2.tireDirectionFront2,tireDirectionSide2:icons$2.tireDirectionSide2,tireDirectionTop2:icons$2.tireDirectionTop2,tirePressureDecrease01:icons$2.tirePressureDecrease01,tirePressureDecrease02:icons$2.tirePressureDecrease02,tirePressureGaugeAlt01:icons$2.tirePressureGaugeAlt01,tirePressureGaugeAlt02:icons$2.tirePressureGaugeAlt02,tirePressureGaugeAlt03:icons$2.tirePressureGaugeAlt03,tirePressureGaugeOutlined01:icons$2.tirePressureGaugeOutlined01,tirePressureGaugeOutlined02:icons$2.tirePressureGaugeOutlined02,tirePressureGaugeOutlined03:icons$2.tirePressureGaugeOutlined03,tirePressureGaugeSolid01:icons$2.tirePressureGaugeSolid01,tirePressureGaugeSolid02:icons$2.tirePressureGaugeSolid02,tirePressureGaugeSolid03:icons$2.tirePressureGaugeSolid03,tirePressureIncrease01:icons$2.tirePressureIncrease01,tirePressureIncrease02:icons$2.tirePressureIncrease02,tirePressureStopLine:icons$2.tirePressureStopLine,tirePressureStopOctoLine:icons$2.tirePressureStopOctoLine,tirePressureStopOctoSolid:icons$2.tirePressureStopOctoSolid,tirePressureStopSolid:icons$2.tirePressureStopSolid,toCOMWithWheels:icons$2.toCOMWithWheels,toCOM:icons$2.toCOM,toGarage:icons$2.toGarage,touch:icons$2.touch,tow:icons$2.tow,tractionControl:icons$2.tractionControl,trafficCone:icons$2.trafficCone,transform:icons$2.transform,transmissionA:icons$2.transmissionA,transmissionM:icons$2.transmissionM,transparencyMask:icons$2.transparencyMask,trashBin1:icons$2.trashBin1,trashBin2:icons$2.trashBin2,triangleBeam:icons$2.triangleBeam,trim:icons$2.trim,tulipBeam:icons$2.tulipBeam,tunnel:icons$2.tunnel,turbine:icons$2.turbine,twoRoadsAdd:icons$2.twoRoadsAdd,twoRoadsCrossAdd:icons$2.twoRoadsCrossAdd,twoRoadsLink:icons$2.twoRoadsLink,twoUnicyclesOnly:icons$2.twoUnicyclesOnly,undo:icons$2.undo,ungroup:icons$2.ungroup,unlink:icons$2.unlink,vehicleDoorsClose:icons$2.vehicleDoorsClose,vehicleDoorsOpen:icons$2.vehicleDoorsOpen,vehicleDoors:icons$2.vehicleDoors,vehicleFeatures01:icons$2.vehicleFeatures01,vehicleFeatures02:icons$2.vehicleFeatures02,vehicleFeatures03:icons$2.vehicleFeatures03,vehicleHood:icons$2.vehicleHood,vehicleTrunk:icons$2.vehicleTrunk,view:icons$2.view,voucherDiagonal1:icons$2.voucherDiagonal1,voucherDiagonal2:icons$2.voucherDiagonal2,voucherDiagonal3:icons$2.voucherDiagonal3,voucherHorizontal1:icons$2.voucherHorizontal1,voucherHorizontal2:icons$2.voucherHorizontal2,voucherHorizontal3:icons$2.voucherHorizontal3,wavesSignalReceived:icons$2.wavesSignalReceived,wavesSignalSentLeft:icons$2.wavesSignalSentLeft,wavesSignalSentRight:icons$2.wavesSignalSentRight,weather:icons$2.weather,weight:icons$2.weight,wheelHubLocked01:icons$2.wheelHubLocked01,wheelHubUnlocked01:icons$2.wheelHubUnlocked01,wigwags:icons$2.wigwags,wrench:icons$2.wrench,xboxA:icons$2.xboxA,xboxB:icons$2.xboxB,xboxDDefaultOutline:icons$2.xboxDDefaultOutline,xboxDDefaultSolid:icons$2.xboxDDefaultSolid,xboxDDown:icons$2.xboxDDown,xboxDLeft:icons$2.xboxDLeft,xboxDRight:icons$2.xboxDRight,xboxDUp:icons$2.xboxDUp,xboxLB:icons$2.xboxLB,xboxLSButton:icons$2.xboxLSButton,xboxLT:icons$2.xboxLT,xboxMenu:icons$2.xboxMenu,xboxRB:icons$2.xboxRB,xboxRSButton:icons$2.xboxRSButton,xboxRT:icons$2.xboxRT,xboxThumbL:icons$2.xboxThumbL,xboxThumbR:icons$2.xboxThumbR,xboxView:icons$2.xboxView,xboxXAxis:icons$2.xboxXAxis,xboxXRot:icons$2.xboxXRot,xboxX:icons$2.xboxX,xboxYAxis:icons$2.xboxYAxis,xboxYRot:icons$2.xboxYRot,xboxY:icons$2.xboxY,danger:icons$2.danger,droplet:icons$2.droplet,envelope:icons$2.envelope,fireDiamond:icons$2.fireDiamond,rocks:icons$2.rocks,xmark:icons$2.xmark,scale:icons$2.scale,locationDestination:icons$2.locationDestination,locationSource:icons$2.locationSource,accelerationKPH:icons$2.accelerationKPH,accelerationMPH:icons$2.accelerationMPH,boxTruckFast:icons$2.boxTruckFast,colorBrightnessSun:icons$2.colorBrightnessSun,colorCirclePalette:icons$2.colorCirclePalette,colorPalette:icons$2.colorPalette,colorSaturation:icons$2.colorSaturation,sortAscDown02:icons$2.sortAscDown02,sortAscDown:icons$2.sortAscDown,sortAscUp02:icons$2.sortAscUp02,sortAscUp:icons$2.sortAscUp,sortDescDown02:icons$2.sortDescDown02,sortDescDown:icons$2.sortDescDown,sortDescUp02:icons$2.sortDescUp02,sortDescUp:icons$2.sortDescUp,cardboardBoxCoins:icons$2.cardboardBoxCoins,lasso:icons$2.lasso,materialGlossy:icons$2.materialGlossy,materialMetal:icons$2.materialMetal,materialRoughness:icons$2.materialRoughness,materialTransparency01:icons$2.materialTransparency01,materialTransparency02:icons$2.materialTransparency02,metal01:icons$2.metal01,removeItemPolygon:icons$2.removeItemPolygon,removeListItem:icons$2.removeListItem,sortAsc:icons$2.sortAsc,sortDesc:icons$2.sortDesc,surfaceRoughness02:icons$2.surfaceRoughness02,shieldCheckmark:icons$2.shieldCheckmark,shieldHandCheckmark:icons$2.shieldHandCheckmark,shieldHandPlus:icons$2.shieldHandPlus,doorFrontCoins:icons$2.doorFrontCoins,doorFront:icons$2.doorFront,engineCoins:icons$2.engineCoins,exhaustMufflerCoins:icons$2.exhaustMufflerCoins,exhaustMuffler:icons$2.exhaustMuffler,headlightCoins:icons$2.headlightCoins,headlight:icons$2.headlight,tire3FourthCoins:icons$2.tire3FourthCoins,tire3Fourth:icons$2.tire3Fourth,turbineCoins:icons$2.turbineCoins,wheelDiscCoins:icons$2.wheelDiscCoins,wheelDisc:icons$2.wheelDisc,bridgeWithRiver:icons$2.bridgeWithRiver,gizmosOutline:icons$2.gizmosOutline,gizmosSolid:icons$2.gizmosSolid,highwayRoad3To2Merge01:icons$2.highwayRoad3To2Merge01,highwayRoad3To2Merge02:icons$2.highwayRoad3To2Merge02,highwayToUrbanRoadTransition01:icons$2.highwayToUrbanRoadTransition01,highwayToUrbanRoadTransition02:icons$2.highwayToUrbanRoadTransition02,pedestrianCrossing01:icons$2.pedestrianCrossing01,polygonalCube:icons$2.polygonalCube,roadEditOutline:icons$2.roadEditOutline,roadEditSolid:icons$2.roadEditSolid,roadFolderPlus:icons$2.roadFolderPlus,roadFolder:icons$2.roadFolder,roadGuideArrowOutline:icons$2.roadGuideArrowOutline,roadGuideArrowSolid:icons$2.roadGuideArrowSolid,roadOutlineMesh:icons$2.roadOutlineMesh,roadPedestrianCrossing02:icons$2.roadPedestrianCrossing02,roadProfileWithCheckmark:icons$2.roadProfileWithCheckmark,roadProfile:icons$2.roadProfile,roadRoundaboutJunction:icons$2.roadRoundaboutJunction,roadSidewalkTransition:icons$2.roadSidewalkTransition,roadStackPlus:icons$2.roadStackPlus,roadStack:icons$2.roadStack,roadTJunction:icons$2.roadTJunction,roadXJunction:icons$2.roadXJunction,roadYJunction:icons$2.roadYJunction,shoppingCart:icons$2.shoppingCart,singleLineToTerrain:icons$2.singleLineToTerrain,sphereOnMesh:icons$2.sphereOnMesh,twoLinesToTerrain:icons$2.twoLinesToTerrain,urbanRoad3To2Merge01:icons$2.urbanRoad3To2Merge01,urbanRoad3To2Merge02:icons$2.urbanRoad3To2Merge02,urbanRoadToHighwayTransition01:icons$2.urbanRoadToHighwayTransition01,urbanRoadToHighwayTransition02:icons$2.urbanRoadToHighwayTransition02,floppyDiskPlus:icons$2.floppyDiskPlus,highwayMerge:icons$2.highwayMerge,highwaySeparate:icons$2.highwaySeparate,highwayShoulderMerge:icons$2.highwayShoulderMerge,terrainToSingleLine:icons$2.terrainToSingleLine,terrainToTwoLines:icons$2.terrainToTwoLines,urbanRoadMerge:icons$2.urbanRoadMerge,urbanRoadSeparate:icons$2.urbanRoadSeparate,urbanShoulderMerge:icons$2.urbanShoulderMerge,discharging:icons$2.discharging,BNGChat:icons$2.BNGChat,chatBubble:icons$2.chatBubble,busTilted:icons$2.busTilted,cameraFarClip:icons$2.cameraFarClip,cameraNearClip:icons$2.cameraNearClip,explosion:icons$2.explosion,fireExtinguisher:icons$2.fireExtinguisher,fire:icons$2.fire,jointLockedMultiple:icons$2.jointLockedMultiple,jointUnlockedMultiple:icons$2.jointUnlockedMultiple,toggleOff:icons$2.toggleOff,toggleOn:icons$2.toggleOn,viewFarClip:icons$2.viewFarClip,viewNearClip:icons$2.viewNearClip,twoArrowsHorizontal:icons$2.twoArrowsHorizontal,twoArrowsVertical:icons$2.twoArrowsVertical,circleSlashed:icons$2.circleSlashed,scissorsSlashed:icons$2.scissorsSlashed,scissors:icons$2.scissors,airPuffRight1:icons$2.airPuffRight1,airPuffUp1:icons$2.airPuffUp1,arrowsReplace:icons$2.arrowsReplace,arrowsShuffle:icons$2.arrowsShuffle,arrowsSwitch:icons$2.arrowsSwitch,carClock:icons$2.carClock,carFast:icons$2.carFast,carNumber1:icons$2.carNumber1,carNumber2:icons$2.carNumber2,carNumber3:icons$2.carNumber3,carNumber4:icons$2.carNumber4,carNumber5:icons$2.carNumber5,carNumber6:icons$2.carNumber6,carNumber7:icons$2.carNumber7,carNumber8:icons$2.carNumber8,carNumber9:icons$2.carNumber9,carPlus:icons$2.carPlus,carsChange:icons$2.carsChange,carsFollow:icons$2.carsFollow,doorFrontDetached:icons$2.doorFrontDetached,forceFieldPull1:icons$2.forceFieldPull1,forceFieldPull2:icons$2.forceFieldPull2,forceFieldPull3:icons$2.forceFieldPull3,forceFieldPush1:icons$2.forceFieldPush1,forceFieldPush2:icons$2.forceFieldPush2,forceFieldPush3:icons$2.forceFieldPush3,garageNumber1:icons$2.garageNumber1,garageNumber2:icons$2.garageNumber2,garageNumber3:icons$2.garageNumber3,garageNumber4:icons$2.garageNumber4,garageNumber5:icons$2.garageNumber5,garageNumber6:icons$2.garageNumber6,garageNumber7:icons$2.garageNumber7,garageNumber8:icons$2.garageNumber8,garageNumber9:icons$2.garageNumber9,hingeBroken:icons$2.hingeBroken,loadMesh:icons$2.loadMesh,octagonBrick:icons$2.octagonBrick,octagon:icons$2.octagon,pushUp:icons$2.pushUp,saveMesh:icons$2.saveMesh,square:icons$2.square,tireAirPuff:icons$2.tireAirPuff,tireDeflated:icons$2.tireDeflated,trafficLight:icons$2.trafficLight,enter:icons$2.enter,pedestrianRunning:icons$2.pedestrianRunning,pedestrianStanding:icons$2.pedestrianStanding,seatArrowIn:icons$2.seatArrowIn,seatArrowOut:icons$2.seatArrowOut,seatVArrowIn:icons$2.seatVArrowIn,seatVArrowOut:icons$2.seatVArrowOut,vehicleArrowIn:icons$2.vehicleArrowIn,vehicleArrowOut:icons$2.vehicleArrowOut,leverFrontOperate:icons$2.leverFrontOperate,leverSideDown:icons$2.leverSideDown,leverSideOperate:icons$2.leverSideOperate,leverSideUp:icons$2.leverSideUp,medalEmpty:icons$2.medalEmpty,medalStar:icons$2.medalStar,seatArrowInLeft:icons$2.seatArrowInLeft,seatArrowOutLeft:icons$2.seatArrowOutLeft,seatVArrowInLeft:icons$2.seatVArrowInLeft,seatVArrowOutLeft:icons$2.seatVArrowOutLeft,badgeRoundEmpty:icons$2.badgeRoundEmpty,badgeRoundStar:icons$2.badgeRoundStar,badgeRound:icons$2.badgeRound,badge:icons$2.badge,houseWrenchRoof:icons$2.houseWrenchRoof,houseWrench:icons$2.houseWrench,eject:icons$2.eject,rallyHelmet3To4:icons$2.rallyHelmet3To4,rallyHelmet:icons$2.rallyHelmet,test:icons$2.test,globeSimpleNotSign:icons$2.globeSimpleNotSign,globeSimplified:icons$2.globeSimplified,radialMenu:icons$2.radialMenu,branch:icons$2.branch,NA:icons$2.NA,psCircleOutline:icons$2.psCircleOutline,psCircle:icons$2.psCircle,psCreate2:icons$2.psCreate2,psCreate:icons$2.psCreate,psCrossOutline:icons$2.psCrossOutline,psCross:icons$2.psCross,psDDefaultOutline:icons$2.psDDefaultOutline,psDDefaultSolid:icons$2.psDDefaultSolid,psDDown:icons$2.psDDown,psDLeft:icons$2.psDLeft,psDRight:icons$2.psDRight,psDUp:icons$2.psDUp,psL1:icons$2.psL1,psL2:icons$2.psL2,psL3ButtonArrowDown:icons$2.psL3ButtonArrowDown,psL3Button:icons$2.psL3Button,psLSXLeft:icons$2.psLSXLeft,psLSXRight:icons$2.psLSXRight,psLSX:icons$2.psLSX,psLSYDown:icons$2.psLSYDown,psLSYUp:icons$2.psLSYUp,psLSY:icons$2.psLSY,psLS:icons$2.psLS,psMenu2:icons$2.psMenu2,psMenu:icons$2.psMenu,psR1:icons$2.psR1,psR2:icons$2.psR2,psR3ButtonArrowDown:icons$2.psR3ButtonArrowDown,psR3Button:icons$2.psR3Button,psRSXLeft:icons$2.psRSXLeft,psRSXRight:icons$2.psRSXRight,psRSX:icons$2.psRSX,psRSYDown:icons$2.psRSYDown,psRSYUp:icons$2.psRSYUp,psRSY:icons$2.psRSY,psRS:icons$2.psRS,psSquareOutline:icons$2.psSquareOutline,psSquare:icons$2.psSquare,psTrackpadNavigate:icons$2.psTrackpadNavigate,psTrackpadPressCenter:icons$2.psTrackpadPressCenter,psTrackpadPressLeft:icons$2.psTrackpadPressLeft,psTrackpadPressRight:icons$2.psTrackpadPressRight,psTrackpadSwipeDown:icons$2.psTrackpadSwipeDown,psTrackpadSwipeLeft:icons$2.psTrackpadSwipeLeft,psTrackpadSwipeRight:icons$2.psTrackpadSwipeRight,psTrackpadSwipeUp:icons$2.psTrackpadSwipeUp,psTriangleOutline:icons$2.psTriangleOutline,psTriangle:icons$2.psTriangle,xboxAOutline:icons$2.xboxAOutline,xboxBOutline:icons$2.xboxBOutline,xboxLSButtonArrowDown:icons$2.xboxLSButtonArrowDown,xboxRSButtonArrowDown:icons$2.xboxRSButtonArrowDown,xboxXAxisLeft:icons$2.xboxXAxisLeft,xboxXAxisRight:icons$2.xboxXAxisRight,xboxXOutline:icons$2.xboxXOutline,xboxXRotLeft:icons$2.xboxXRotLeft,xboxXRotRight:icons$2.xboxXRotRight,xboxYAxisDown:icons$2.xboxYAxisDown,xboxYAxisUp:icons$2.xboxYAxisUp,xboxYOutline:icons$2.xboxYOutline,xboxYRotDown:icons$2.xboxYRotDown,xboxYRotUp:icons$2.xboxYRotUp,cableSection:icons$2.cableSection,strapHook:icons$2.strapHook,strapRatchet:icons$2.strapRatchet,carFastReverse:icons$2.carFastReverse,carsChase:icons$2.carsChase,carsFlee:icons$2.carsFlee,gaugeFull:icons$2.gaugeFull,hammerParticles:icons$2.hammerParticles,kbArrowsDown:icons$2.kbArrowsDown,kbArrowsLeftRight:icons$2.kbArrowsLeftRight,kbArrowsLeft:icons$2.kbArrowsLeft,kbArrowsOutline:icons$2.kbArrowsOutline,kbArrowsRight:icons$2.kbArrowsRight,kbArrowsSolid:icons$2.kbArrowsSolid,kbArrowsUpDown:icons$2.kbArrowsUpDown,kbArrowsUp:icons$2.kbArrowsUp,magicWand:icons$2.magicWand,psDLeftRight:icons$2.psDLeftRight,psDUpDown:icons$2.psDUpDown,pushBackward:icons$2.pushBackward,pushDown:icons$2.pushDown,pushForward:icons$2.pushForward,rangeboxHi:icons$2.rangeboxHi,rangeboxLo:icons$2.rangeboxLo,routeSimpleFlag:icons$2.routeSimpleFlag,xboxDLeftRight:icons$2.xboxDLeftRight,xboxDUpDown:icons$2.xboxDUpDown,carsWrench:icons$2.carsWrench,jointCycleMultiple:icons$2.jointCycleMultiple,jointCycle:icons$2.jointCycle,dice24:icons$2.dice24,diceD6:icons$2.diceD6,pathDice:icons$2.pathDice,sunDown:icons$2.sunDown,xmarkBold:icons$2.xmarkBold,intakeTrumpets:icons$2.intakeTrumpets,transmissionCvt:icons$2.transmissionCvt,house:icons$2.house,playPause:icons$2.playPause,picture:icons$2.picture,auxUpDown:icons$2.auxUpDown,bucketArmUpDown:icons$2.bucketArmUpDown,bucketTilt:icons$2.bucketTilt,bucketArmDown:icons$2.bucketArmDown,bucketArmLevel:icons$2.bucketArmLevel,bucketArmUp:icons$2.bucketArmUp,bucketTiltDown:icons$2.bucketTiltDown,bucketTiltLevel:icons$2.bucketTiltLevel,bucketTiltUp:icons$2.bucketTiltUp,dumpBedDown:icons$2.dumpBedDown,dumpBedUpDown:icons$2.dumpBedUpDown,dumpBedUp:icons$2.dumpBedUp,beamCurrencyThin:icons$2.beamCurrencyThin,shieldCheckmarkProgressbar:icons$2.shieldCheckmarkProgressbar},48:{AIL:icons$2.AIL,arrowLeftOutline:icons$2.arrowLeftOutline,arrowRightOutline:icons$2.arrowRightOutline,automaticTransmissionL:icons$2.automaticTransmissionL,beamsNodesMessageOutline:icons$2.beamsNodesMessageOutline,beamsNodesOutline:icons$2.beamsNodesOutline,beamsNodesPlugOutline:icons$2.beamsNodesPlugOutline,BNGEcosystemOutline:icons$2.BNGEcosystemOutline,carFrontRouteOutline:icons$2.carFrontRouteOutline,carSensorsOutline:icons$2.carSensorsOutline,carSideRouteOutline:icons$2.carSideRouteOutline,chargeLL:icons$2.chargeLL,cityOutline:icons$2.cityOutline,clutchL:icons$2.clutchL,couplerL:icons$2.couplerL,dialogOutline:icons$2.dialogOutline,documentSmileOutline:icons$2.documentSmileOutline,drivetrainOutline:icons$2.drivetrainOutline,electronicSchemeOutline:icons$2.electronicSchemeOutline,engineL:icons$2.engineL,engineOutline:icons$2.engineOutline,gearTuningOutline:icons$2.gearTuningOutline,giftBoxOutline:icons$2.giftBoxOutline,lidarOutline:icons$2.lidarOutline,medalStarOutline:icons$2.medalStarOutline,megaphoneOutline:icons$2.megaphoneOutline,multiseatL:icons$2.multiseatL,peopleOutline:icons$2.peopleOutline,personOutline:icons$2.personOutline,physicsOutline:icons$2.physicsOutline,playChainOutline:icons$2.playChainOutline,POITimeL:icons$2.POITimeL,proximitySensorsOutline:icons$2.proximitySensorsOutline,qualityBadgeStarOutline:icons$2.qualityBadgeStarOutline,qualityBadgeVOutline:icons$2.qualityBadgeVOutline,replayL:icons$2.replayL,roadblockL:icons$2.roadblockL,rotationL:icons$2.rotationL,sensorsL:icons$2.sensorsL,simRigOutline:icons$2.simRigOutline,suspensionOutline:icons$2.suspensionOutline,teamOutline:icons$2.teamOutline,techLightBulbOutline01:icons$2.techLightBulbOutline01,techLightBulbOutline02:icons$2.techLightBulbOutline02,temperatureL:icons$2.temperatureL,timeUnlockOutline:icons$2.timeUnlockOutline,timedLockOutline:icons$2.timedLockOutline,trafficOutline:icons$2.trafficOutline,tuningL:icons$2.tuningL,turbineL:icons$2.turbineL,voucherOutline:icons$2.voucherOutline,wheelBeamsNodesOutline:icons$2.wheelBeamsNodesOutline,wheelOutline:icons$2.wheelOutline,bridge:icons$2.bridge,bump:icons$2.bump,bumps:icons$2.bumps,caution:icons$2.caution,crest:icons$2.crest,doubleCaution:icons$2.doubleCaution,finish:icons$2.finish,jumpOverBump:icons$2.jumpOverBump,narrows:icons$2.narrows,pothole:icons$2.pothole,turn1:icons$2.turn1,turn2:icons$2.turn2,turn3:icons$2.turn3,turn4:icons$2.turn4,turn5:icons$2.turn5,turn6:icons$2.turn6,turnHp:icons$2.turnHp,turnSq:icons$2.turnSq,water:icons$2.water,beamCurrencyOutlineLarge:icons$2.beamCurrencyOutlineLarge,carSideOutlineLarge:icons$2.carSideOutlineLarge,flagOutlineLarge:icons$2.flagOutlineLarge,terrainOutlineLarge:icons$2.terrainOutlineLarge,tripleCaution:icons$2.tripleCaution},56:{circlePinBack:icons$2.circlePinBack,circlePinFront:icons$2.circlePinFront,markerRectanglePinBack:icons$2.markerRectanglePinBack,markerRectanglePinFront:icons$2.markerRectanglePinFront,markerTriangleBack:icons$2.markerTriangleBack,markerTriangleFront:icons$2.markerTriangleFront}}),iconsByTag=Object.freeze({vehicle:{"4WD":icons$2[`4WD`],ABSIndicator:icons$2.ABSIndicator,AWD:icons$2.AWD,axleLift:icons$2.axleLift,axleCenter:icons$2.axleCenter,axleFront:icons$2.axleFront,axleRear:icons$2.axleRear,boxTruck:icons$2.boxTruck,bus:icons$2.bus,carChase01:icons$2.carChase01,carCoin:icons$2.carCoin,carCoins:icons$2.carCoins,carCrash:icons$2.carCrash,carOffroadOutlineRear:icons$2.carOffroadOutlineRear,carOffroadOutlineSide:icons$2.carOffroadOutlineSide,carOffroadRear:icons$2.carOffroadRear,carOffroadSide:icons$2.carOffroadSide,carSensors:icons$2.carSensors,carStarred:icons$2.carStarred,carToWheels:icons$2.carToWheels,carUp:icons$2.carUp,carWithLidar:icons$2.carWithLidar,car:icons$2.car,carsChase02:icons$2.carsChase02,cars:icons$2.cars,centrifugalClutchLocked03:icons$2.centrifugalClutchLocked03,centrifugalClutchUnlocked03:icons$2.centrifugalClutchUnlocked03,cogDamaged:icons$2.cogDamaged,cogsDamaged:icons$2.cogsDamaged,cogs:icons$2.cogs,coolantTemp:icons$2.coolantTemp,cruiseDisable:icons$2.cruiseDisable,cruiseEnable:icons$2.cruiseEnable,DCBattery:icons$2.DCBattery,deliveryTruckArrows:icons$2.deliveryTruckArrows,deliveryTruck:icons$2.deliveryTruck,differentialFrontDefault:icons$2.differentialFrontDefault,differentialFrontLocked:icons$2.differentialFrontLocked,differentialMiddleDefault:icons$2.differentialMiddleDefault,differentialMiddleLocked:icons$2.differentialMiddleLocked,differentialRearDefault:icons$2.differentialRearDefault,differentialRearLocked:icons$2.differentialRearLocked,doorHandle:icons$2.doorHandle,drift01:icons$2.drift01,drift02:icons$2.drift02,drivetrainGeneric:icons$2.drivetrainGeneric,drivetrainSpecial:icons$2.drivetrainSpecial,engine:icons$2.engine,ESCOff:icons$2.ESCOff,ESCOn:icons$2.ESCOn,ESC:icons$2.ESC,exhaustValve:icons$2.exhaustValve,flatbedTruck:icons$2.flatbedTruck,fogLight:icons$2.fogLight,forklift:icons$2.forklift,FWD:icons$2.FWD,hazardLights:icons$2.hazardLights,highBeam:icons$2.highBeam,hydroPump1:icons$2.hydroPump1,hydroPump2:icons$2.hydroPump2,hydroPump3:icons$2.hydroPump3,hydroPump4:icons$2.hydroPump4,hydroPump5:icons$2.hydroPump5,hydroPump6:icons$2.hydroPump6,hydroPump7:icons$2.hydroPump7,jointLocked:icons$2.jointLocked,jointUnlocked:icons$2.jointUnlocked,keys1:icons$2.keys1,keys2:icons$2.keys2,limiterEnable:icons$2.limiterEnable,lowBeam:icons$2.lowBeam,minusRes:icons$2.minusRes,mirrorInteriorMiddle:icons$2.mirrorInteriorMiddle,mirrorLeftBigBottomWideAngle:icons$2.mirrorLeftBigBottomWideAngle,mirrorLeftBigTop:icons$2.mirrorLeftBigTop,mirrorLeftBig:icons$2.mirrorLeftBig,mirrorLeftBonnet:icons$2.mirrorLeftBonnet,mirrorLeftDefault:icons$2.mirrorLeftDefault,mirrorRightBigBottomWideAngle:icons$2.mirrorRightBigBottomWideAngle,mirrorRightBigTop:icons$2.mirrorRightBigTop,mirrorRightBig:icons$2.mirrorRightBig,mirrorRightBonnet:icons$2.mirrorRightBonnet,mirrorRightDefault:icons$2.mirrorRightDefault,mirrorRoundWideAngle:icons$2.mirrorRoundWideAngle,mirrorTopWideAngle:icons$2.mirrorTopWideAngle,odometerKM:icons$2.odometerKM,odometerMI:icons$2.odometerMI,odometer:icons$2.odometer,oilPressureIndicator:icons$2.oilPressureIndicator,parkingIndicator:icons$2.parkingIndicator,plusSet:icons$2.plusSet,positionLights:icons$2.positionLights,powerGauge01:icons$2.powerGauge01,powerGauge02:icons$2.powerGauge02,powerGauge03:icons$2.powerGauge03,powerGauge04:icons$2.powerGauge04,powerGauge05:icons$2.powerGauge05,rangeboxHi2:icons$2.rangeboxHi2,rangeboxHi4:icons$2.rangeboxHi4,rangeboxHiA:icons$2.rangeboxHiA,rangeboxLo2:icons$2.rangeboxLo2,rangeboxLo4:icons$2.rangeboxLo4,rangeboxLoA:icons$2.rangeboxLoA,rockCrawling01:icons$2.rockCrawling01,RWD:icons$2.RWD,semiTrailer:icons$2.semiTrailer,semiTruckCabover:icons$2.semiTruckCabover,semiTruckUS:icons$2.semiTruckUS,semiTruck:icons$2.semiTruck,smallTrailer:icons$2.smallTrailer,spoilerLift:icons$2.spoilerLift,strobeLights:icons$2.strobeLights,suspension01:icons$2.suspension01,suspension02:icons$2.suspension02,synchro01:icons$2.synchro01,synchro02:icons$2.synchro02,tankerTrailer:icons$2.tankerTrailer,taxiCar1:icons$2.taxiCar1,taxiCar3:icons$2.taxiCar3,taxiCarT:icons$2.taxiCarT,taxiCheckerLamp:icons$2.taxiCheckerLamp,tirePressureDecrease01:icons$2.tirePressureDecrease01,tirePressureDecrease02:icons$2.tirePressureDecrease02,tirePressureGaugeAlt01:icons$2.tirePressureGaugeAlt01,tirePressureGaugeAlt02:icons$2.tirePressureGaugeAlt02,tirePressureGaugeAlt03:icons$2.tirePressureGaugeAlt03,tirePressureGaugeOutlined01:icons$2.tirePressureGaugeOutlined01,tirePressureGaugeOutlined02:icons$2.tirePressureGaugeOutlined02,tirePressureGaugeOutlined03:icons$2.tirePressureGaugeOutlined03,tirePressureGaugeSolid01:icons$2.tirePressureGaugeSolid01,tirePressureGaugeSolid02:icons$2.tirePressureGaugeSolid02,tirePressureGaugeSolid03:icons$2.tirePressureGaugeSolid03,tirePressureIncrease01:icons$2.tirePressureIncrease01,tirePressureIncrease02:icons$2.tirePressureIncrease02,tirePressureStopLine:icons$2.tirePressureStopLine,tirePressureStopOctoLine:icons$2.tirePressureStopOctoLine,tirePressureStopOctoSolid:icons$2.tirePressureStopOctoSolid,tirePressureStopSolid:icons$2.tirePressureStopSolid,tow:icons$2.tow,tractionControl:icons$2.tractionControl,transmissionA:icons$2.transmissionA,transmissionM:icons$2.transmissionM,turbine:icons$2.turbine,vehicleDoorsClose:icons$2.vehicleDoorsClose,vehicleDoorsOpen:icons$2.vehicleDoorsOpen,vehicleDoors:icons$2.vehicleDoors,vehicleFeatures01:icons$2.vehicleFeatures01,vehicleFeatures02:icons$2.vehicleFeatures02,vehicleFeatures03:icons$2.vehicleFeatures03,vehicleHood:icons$2.vehicleHood,vehicleTrunk:icons$2.vehicleTrunk,wheelHubLocked01:icons$2.wheelHubLocked01,wheelHubUnlocked01:icons$2.wheelHubUnlocked01,wigwags:icons$2.wigwags,wrench:icons$2.wrench,accelerationKPH:icons$2.accelerationKPH,accelerationMPH:icons$2.accelerationMPH,boxTruckFast:icons$2.boxTruckFast,doorFrontCoins:icons$2.doorFrontCoins,doorFront:icons$2.doorFront,engineCoins:icons$2.engineCoins,exhaustMufflerCoins:icons$2.exhaustMufflerCoins,exhaustMuffler:icons$2.exhaustMuffler,headlightCoins:icons$2.headlightCoins,headlight:icons$2.headlight,tire3FourthCoins:icons$2.tire3FourthCoins,tire3Fourth:icons$2.tire3Fourth,turbineCoins:icons$2.turbineCoins,wheelDiscCoins:icons$2.wheelDiscCoins,wheelDisc:icons$2.wheelDisc,busTilted:icons$2.busTilted,jointLockedMultiple:icons$2.jointLockedMultiple,jointUnlockedMultiple:icons$2.jointUnlockedMultiple,airPuffRight1:icons$2.airPuffRight1,carClock:icons$2.carClock,carFast:icons$2.carFast,carNumber1:icons$2.carNumber1,carNumber2:icons$2.carNumber2,carNumber3:icons$2.carNumber3,carNumber4:icons$2.carNumber4,carNumber5:icons$2.carNumber5,carNumber6:icons$2.carNumber6,carNumber7:icons$2.carNumber7,carNumber8:icons$2.carNumber8,carNumber9:icons$2.carNumber9,carPlus:icons$2.carPlus,carsChange:icons$2.carsChange,carsFollow:icons$2.carsFollow,doorFrontDetached:icons$2.doorFrontDetached,hingeBroken:icons$2.hingeBroken,octagonBrick:icons$2.octagonBrick,octagon:icons$2.octagon,tireAirPuff:icons$2.tireAirPuff,tireDeflated:icons$2.tireDeflated,carSideOutlineLarge:icons$2.carSideOutlineLarge,carFastReverse:icons$2.carFastReverse,carsChase:icons$2.carsChase,carsFlee:icons$2.carsFlee,hammerParticles:icons$2.hammerParticles,rangeboxHi:icons$2.rangeboxHi,rangeboxLo:icons$2.rangeboxLo,carsWrench:icons$2.carsWrench,jointCycleMultiple:icons$2.jointCycleMultiple,jointCycle:icons$2.jointCycle,intakeTrumpets:icons$2.intakeTrumpets,transmissionCvt:icons$2.transmissionCvt,auxUpDown:icons$2.auxUpDown,bucketArmUpDown:icons$2.bucketArmUpDown,bucketTilt:icons$2.bucketTilt,bucketArmDown:icons$2.bucketArmDown,bucketArmLevel:icons$2.bucketArmLevel,bucketArmUp:icons$2.bucketArmUp,bucketTiltDown:icons$2.bucketTiltDown,bucketTiltLevel:icons$2.bucketTiltLevel,bucketTiltUp:icons$2.bucketTiltUp,dumpBedDown:icons$2.dumpBedDown,dumpBedUpDown:icons$2.dumpBedUpDown,dumpBedUp:icons$2.dumpBedUp},features:{"4WD":icons$2[`4WD`],ABSIndicator:icons$2.ABSIndicator,AWD:icons$2.AWD,axleLift:icons$2.axleLift,axleCenter:icons$2.axleCenter,axleFront:icons$2.axleFront,axleRear:icons$2.axleRear,carCoin:icons$2.carCoin,carCoins:icons$2.carCoins,carDealer:icons$2.carDealer,carStarred:icons$2.carStarred,centrifugalClutchLocked03:icons$2.centrifugalClutchLocked03,centrifugalClutchUnlocked03:icons$2.centrifugalClutchUnlocked03,cogDamaged:icons$2.cogDamaged,cogsDamaged:icons$2.cogsDamaged,cogs:icons$2.cogs,coolantTemp:icons$2.coolantTemp,cruiseDisable:icons$2.cruiseDisable,cruiseEnable:icons$2.cruiseEnable,DCBattery:icons$2.DCBattery,differentialFrontDefault:icons$2.differentialFrontDefault,differentialFrontLocked:icons$2.differentialFrontLocked,differentialMiddleDefault:icons$2.differentialMiddleDefault,differentialMiddleLocked:icons$2.differentialMiddleLocked,differentialRearDefault:icons$2.differentialRearDefault,differentialRearLocked:icons$2.differentialRearLocked,doorHandle:icons$2.doorHandle,drivetrainGeneric:icons$2.drivetrainGeneric,drivetrainSpecial:icons$2.drivetrainSpecial,engine:icons$2.engine,ESCOff:icons$2.ESCOff,ESCOn:icons$2.ESCOn,ESC:icons$2.ESC,exhaustValve:icons$2.exhaustValve,fogLight:icons$2.fogLight,FWD:icons$2.FWD,garage01:icons$2.garage01,garage02:icons$2.garage02,garage03:icons$2.garage03,hazardLights:icons$2.hazardLights,highBeam:icons$2.highBeam,hydroPump1:icons$2.hydroPump1,hydroPump2:icons$2.hydroPump2,hydroPump3:icons$2.hydroPump3,hydroPump4:icons$2.hydroPump4,hydroPump5:icons$2.hydroPump5,hydroPump6:icons$2.hydroPump6,hydroPump7:icons$2.hydroPump7,jointLocked:icons$2.jointLocked,jointUnlocked:icons$2.jointUnlocked,keys1:icons$2.keys1,keys2:icons$2.keys2,limiterEnable:icons$2.limiterEnable,lowBeam:icons$2.lowBeam,minusRes:icons$2.minusRes,mirrorInteriorMiddle:icons$2.mirrorInteriorMiddle,mirrorLeftBigBottomWideAngle:icons$2.mirrorLeftBigBottomWideAngle,mirrorLeftBigTop:icons$2.mirrorLeftBigTop,mirrorLeftBig:icons$2.mirrorLeftBig,mirrorLeftBonnet:icons$2.mirrorLeftBonnet,mirrorLeftDefault:icons$2.mirrorLeftDefault,mirrorRightBigBottomWideAngle:icons$2.mirrorRightBigBottomWideAngle,mirrorRightBigTop:icons$2.mirrorRightBigTop,mirrorRightBig:icons$2.mirrorRightBig,mirrorRightBonnet:icons$2.mirrorRightBonnet,mirrorRightDefault:icons$2.mirrorRightDefault,mirrorRoundWideAngle:icons$2.mirrorRoundWideAngle,mirrorTopWideAngle:icons$2.mirrorTopWideAngle,odometerKM:icons$2.odometerKM,odometerMI:icons$2.odometerMI,odometer:icons$2.odometer,oilPressureIndicator:icons$2.oilPressureIndicator,parkingIndicator:icons$2.parkingIndicator,plusGarage1:icons$2.plusGarage1,plusGarage2:icons$2.plusGarage2,plusGarage3:icons$2.plusGarage3,plusGarage4:icons$2.plusGarage4,plusSet:icons$2.plusSet,positionLights:icons$2.positionLights,powerGauge01:icons$2.powerGauge01,powerGauge02:icons$2.powerGauge02,powerGauge03:icons$2.powerGauge03,powerGauge04:icons$2.powerGauge04,powerGauge05:icons$2.powerGauge05,rangeboxHi2:icons$2.rangeboxHi2,rangeboxHi4:icons$2.rangeboxHi4,rangeboxHiA:icons$2.rangeboxHiA,rangeboxLo2:icons$2.rangeboxLo2,rangeboxLo4:icons$2.rangeboxLo4,rangeboxLoA:icons$2.rangeboxLoA,RWD:icons$2.RWD,spoilerLift:icons$2.spoilerLift,strobeLights:icons$2.strobeLights,suspension01:icons$2.suspension01,suspension02:icons$2.suspension02,synchro01:icons$2.synchro01,synchro02:icons$2.synchro02,tirePressureDecrease01:icons$2.tirePressureDecrease01,tirePressureDecrease02:icons$2.tirePressureDecrease02,tirePressureGaugeAlt01:icons$2.tirePressureGaugeAlt01,tirePressureGaugeAlt02:icons$2.tirePressureGaugeAlt02,tirePressureGaugeAlt03:icons$2.tirePressureGaugeAlt03,tirePressureGaugeOutlined01:icons$2.tirePressureGaugeOutlined01,tirePressureGaugeOutlined02:icons$2.tirePressureGaugeOutlined02,tirePressureGaugeOutlined03:icons$2.tirePressureGaugeOutlined03,tirePressureGaugeSolid01:icons$2.tirePressureGaugeSolid01,tirePressureGaugeSolid02:icons$2.tirePressureGaugeSolid02,tirePressureGaugeSolid03:icons$2.tirePressureGaugeSolid03,tirePressureIncrease01:icons$2.tirePressureIncrease01,tirePressureIncrease02:icons$2.tirePressureIncrease02,tirePressureStopLine:icons$2.tirePressureStopLine,tirePressureStopOctoLine:icons$2.tirePressureStopOctoLine,tirePressureStopOctoSolid:icons$2.tirePressureStopOctoSolid,tirePressureStopSolid:icons$2.tirePressureStopSolid,tractionControl:icons$2.tractionControl,transmissionA:icons$2.transmissionA,transmissionM:icons$2.transmissionM,turbine:icons$2.turbine,vehicleDoorsClose:icons$2.vehicleDoorsClose,vehicleDoorsOpen:icons$2.vehicleDoorsOpen,vehicleDoors:icons$2.vehicleDoors,vehicleFeatures01:icons$2.vehicleFeatures01,vehicleFeatures02:icons$2.vehicleFeatures02,vehicleFeatures03:icons$2.vehicleFeatures03,vehicleHood:icons$2.vehicleHood,vehicleTrunk:icons$2.vehicleTrunk,wheelHubLocked01:icons$2.wheelHubLocked01,wheelHubUnlocked01:icons$2.wheelHubUnlocked01,wigwags:icons$2.wigwags,wrench:icons$2.wrench,accelerationKPH:icons$2.accelerationKPH,accelerationMPH:icons$2.accelerationMPH,doorFrontCoins:icons$2.doorFrontCoins,doorFront:icons$2.doorFront,engineCoins:icons$2.engineCoins,exhaustMufflerCoins:icons$2.exhaustMufflerCoins,exhaustMuffler:icons$2.exhaustMuffler,headlightCoins:icons$2.headlightCoins,headlight:icons$2.headlight,tire3FourthCoins:icons$2.tire3FourthCoins,tire3Fourth:icons$2.tire3Fourth,turbineCoins:icons$2.turbineCoins,wheelDiscCoins:icons$2.wheelDiscCoins,wheelDisc:icons$2.wheelDisc,jointLockedMultiple:icons$2.jointLockedMultiple,jointUnlockedMultiple:icons$2.jointUnlockedMultiple,bridge:icons$2.bridge,bump:icons$2.bump,bumps:icons$2.bumps,caution:icons$2.caution,crest:icons$2.crest,doubleCaution:icons$2.doubleCaution,finish:icons$2.finish,jumpOverBump:icons$2.jumpOverBump,narrows:icons$2.narrows,pothole:icons$2.pothole,turn1:icons$2.turn1,turn2:icons$2.turn2,turn3:icons$2.turn3,turn4:icons$2.turn4,turn5:icons$2.turn5,turn6:icons$2.turn6,turnHp:icons$2.turnHp,turnSq:icons$2.turnSq,water:icons$2.water,carsFollow:icons$2.carsFollow,doorFrontDetached:icons$2.doorFrontDetached,garageNumber1:icons$2.garageNumber1,garageNumber2:icons$2.garageNumber2,garageNumber3:icons$2.garageNumber3,garageNumber4:icons$2.garageNumber4,garageNumber5:icons$2.garageNumber5,garageNumber6:icons$2.garageNumber6,garageNumber7:icons$2.garageNumber7,garageNumber8:icons$2.garageNumber8,garageNumber9:icons$2.garageNumber9,hingeBroken:icons$2.hingeBroken,houseWrenchRoof:icons$2.houseWrenchRoof,houseWrench:icons$2.houseWrench,tripleCaution:icons$2.tripleCaution,carsChase:icons$2.carsChase,carsFlee:icons$2.carsFlee,hammerParticles:icons$2.hammerParticles,rangeboxHi:icons$2.rangeboxHi,rangeboxLo:icons$2.rangeboxLo,jointCycleMultiple:icons$2.jointCycleMultiple,jointCycle:icons$2.jointCycle,intakeTrumpets:icons$2.intakeTrumpets,transmissionCvt:icons$2.transmissionCvt,house:icons$2.house,auxUpDown:icons$2.auxUpDown,bucketArmUpDown:icons$2.bucketArmUpDown,bucketTilt:icons$2.bucketTilt,bucketArmDown:icons$2.bucketArmDown,bucketArmLevel:icons$2.bucketArmLevel,bucketArmUp:icons$2.bucketArmUp,bucketTiltDown:icons$2.bucketTiltDown,bucketTiltLevel:icons$2.bucketTiltLevel,bucketTiltUp:icons$2.bucketTiltUp,dumpBedDown:icons$2.dumpBedDown,dumpBedUpDown:icons$2.dumpBedUpDown,dumpBedUp:icons$2.dumpBedUp},generic:{"9dividedby10":icons$2[`9dividedby10`],abandon:icons$2.abandon,addItemPolygon:icons$2.addItemPolygon,addListItem:icons$2.addListItem,addPolygonVertex:icons$2.addPolygonVertex,adjust:icons$2.adjust,AIMicrochip:icons$2.AIMicrochip,aperture:icons$2.aperture,autobahn:icons$2.autobahn,bSpline:icons$2.bSpline,beamCrashBarrier1:icons$2.beamCrashBarrier1,beamCrashBarrier2:icons$2.beamCrashBarrier2,beamCrashBarrier3:icons$2.beamCrashBarrier3,beamNG:icons$2.beamNG,bezierPath1:icons$2.bezierPath1,bezierPath2:icons$2.bezierPath2,bicycle1:icons$2.bicycle1,bicycle2:icons$2.bicycle2,BNGFolder:icons$2.BNGFolder,BNGMicrochip:icons$2.BNGMicrochip,bollard:icons$2.bollard,bookmark:icons$2.bookmark,booleanIntersect:icons$2.booleanIntersect,broom:icons$2.broom,bucketAdd:icons$2.bucketAdd,bucketSubtract:icons$2.bucketSubtract,bug:icons$2.bug,bulldozer:icons$2.bulldozer,carChase01:icons$2.carChase01,carCrash:icons$2.carCrash,carOffroadOutlineRear:icons$2.carOffroadOutlineRear,carOffroadOutlineSide:icons$2.carOffroadOutlineSide,carOffroadRear:icons$2.carOffroadRear,carOffroadSide:icons$2.carOffroadSide,carSensors:icons$2.carSensors,carToWheels:icons$2.carToWheels,carUp:icons$2.carUp,carWithLidar:icons$2.carWithLidar,car:icons$2.car,cardboardBox:icons$2.cardboardBox,carsChase02:icons$2.carsChase02,cars:icons$2.cars,catalog01:icons$2.catalog01,catalog02:icons$2.catalog02,catalog03:icons$2.catalog03,chartBars:icons$2.chartBars,checkmarkBold:icons$2.checkmarkBold,checkmark:icons$2.checkmark,circuitMicrochip:icons$2.circuitMicrochip,clapperboard:icons$2.clapperboard,code:icons$2.code,concreteRoadBlock:icons$2.concreteRoadBlock,copy:icons$2.copy,crossroads1:icons$2.crossroads1,crossroads2:icons$2.crossroads2,cup:icons$2.cup,dataExchange:icons$2.dataExchange,decalRoad:icons$2.decalRoad,decal:icons$2.decal,deform:icons$2.deform,doorIn:icons$2.doorIn,editCheckmark:icons$2.editCheckmark,edit:icons$2.edit,exit:icons$2.exit,export:icons$2.export,eyeOutlineClosed:icons$2.eyeOutlineClosed,eyeOutlineOpened:icons$2.eyeOutlineOpened,eyeSolidClosed:icons$2.eyeSolidClosed,eyeSolidOpened:icons$2.eyeSolidOpened,eyeWaves:icons$2.eyeWaves,facility02:icons$2.facility02,filter:icons$2.filter,flatBulbBeam:icons$2.flatBulbBeam,floppyDisk:icons$2.floppyDisk,folder:icons$2.folder,FPS:icons$2.FPS,frontAxleMidpoint:icons$2.frontAxleMidpoint,frontBumperMidpoint:icons$2.frontBumperMidpoint,globe:icons$2.globe,GPSMark:icons$2.GPSMark,GPSSolid:icons$2.GPSSolid,group:icons$2.group,gyroscopeMicrochip:icons$2.gyroscopeMicrochip,gyroscope:icons$2.gyroscope,helmets:icons$2.helmets,help:icons$2.help,HUD:icons$2.HUD,import:icons$2.import,infinity:icons$2.infinity,info:icons$2.info,lampPost1:icons$2.lampPost1,lampPost2:icons$2.lampPost2,lampPost3:icons$2.lampPost3,laneProperties:icons$2.laneProperties,language:icons$2.language,laptop:icons$2.laptop,lidarPatternFullArcHighFreq:icons$2.lidarPatternFullArcHighFreq,lidarPatternFullArcMidFreq:icons$2.lidarPatternFullArcMidFreq,lidarPatternNarrowArc:icons$2.lidarPatternNarrowArc,lidar:icons$2.lidar,lightrunner:icons$2.lightrunner,lineToTerrain:icons$2.lineToTerrain,link2:icons$2.link2,link:icons$2.link,listBig:icons$2.listBig,listIndented:icons$2.listIndented,listSmall:icons$2.listSmall,location1:icons$2.location1,location2:icons$2.location2,lockClosed:icons$2.lockClosed,lockOpened:icons$2.lockOpened,longRangeBeam1:icons$2.longRangeBeam1,longRangeBeam2:icons$2.longRangeBeam2,magnetOnSurface:icons$2.magnetOnSurface,mapWithEmitter:icons$2.mapWithEmitter,mapPoint:icons$2.mapPoint,material:icons$2.material,mathDivide:icons$2.mathDivide,mathGreaterOrEqualThan:icons$2.mathGreaterOrEqualThan,mathGreaterThan:icons$2.mathGreaterThan,mathLessOrEqualThan:icons$2.mathLessOrEqualThan,mathLessThan:icons$2.mathLessThan,mathMinus:icons$2.mathMinus,mathMultiply:icons$2.mathMultiply,mathPlus:icons$2.mathPlus,medal:icons$2.medal,meshFence:icons$2.meshFence,meshRoad:icons$2.meshRoad,midRangeBeam1:icons$2.midRangeBeam1,midRangeBeam2:icons$2.midRangeBeam2,minus:icons$2.minus,move02:icons$2.move02,move:icons$2.move,nodeAddFirst01:icons$2.nodeAddFirst01,nodeAddFirst02:icons$2.nodeAddFirst02,nodeAddLast02:icons$2.nodeAddLast02,nodeAddMiddle01:icons$2.nodeAddMiddle01,nodeAddMiddle02:icons$2.nodeAddMiddle02,nodeAdd:icons$2.nodeAdd,nodeLast01:icons$2.nodeLast01,nodeRemove:icons$2.nodeRemove,order:icons$2.order,organization:icons$2.organization,paperKnife:icons$2.paperKnife,pathArc:icons$2.pathArc,pathLine:icons$2.pathLine,pathSpiral:icons$2.pathSpiral,personSolid:icons$2.personSolid,person:icons$2.person,photo:icons$2.photo,placeholder:icons$2.placeholder,plus:icons$2.plus,powerOnOff:icons$2.powerOnOff,publisher:icons$2.publisher,puzzleModule:icons$2.puzzleModule,radarIdeal:icons$2.radarIdeal,radarRoundIdeal:icons$2.radarRoundIdeal,radarRound:icons$2.radarRound,radar:icons$2.radar,rearAxleMidpoint:icons$2.rearAxleMidpoint,rearBumperMidpoint:icons$2.rearBumperMidpoint,reconfigure:icons$2.reconfigure,redo:icons$2.redo,reflectNot:icons$2.reflectNot,reflect:icons$2.reflect,rename:icons$2.rename,replay:icons$2.replay,restart:icons$2.restart,roadDividerLinesDecal:icons$2.roadDividerLinesDecal,roadEdgeLineDecal:icons$2.roadEdgeLineDecal,roadEndLineDecal:icons$2.roadEndLineDecal,roadFace:icons$2.roadFace,roadInfo:icons$2.roadInfo,roadMarkingOutline:icons$2.roadMarkingOutline,roadMarkingSolid:icons$2.roadMarkingSolid,roadOutline:icons$2.roadOutline,roadRefPathDecal:icons$2.roadRefPathDecal,roadRefPath:icons$2.roadRefPath,roadStartLineDecal:icons$2.roadStartLineDecal,road:icons$2.road,runScript:icons$2.runScript,saveAs1:icons$2.saveAs1,scan:icons$2.scan,search:icons$2.search,shortRangeBeam1:icons$2.shortRangeBeam1,shortRangeBeam2:icons$2.shortRangeBeam2,signal01a:icons$2.signal01a,signal02a:icons$2.signal02a,signal03a:icons$2.signal03a,signal04a:icons$2.signal04a,signal05a:icons$2.signal05a,slashLeft:icons$2.slashLeft,slashRight:icons$2.slashRight,snowflake:icons$2.snowflake,soundFadeOut:icons$2.soundFadeOut,soundLimit:icons$2.soundLimit,soundLoud:icons$2.soundLoud,soundMonoL:icons$2.soundMonoL,soundMonoR:icons$2.soundMonoR,soundOff:icons$2.soundOff,soundQuiet:icons$2.soundQuiet,soundStereo:icons$2.soundStereo,soundWave01:icons$2.soundWave01,soundWave02:icons$2.soundWave02,sphereOnPathNumber:icons$2.sphereOnPathNumber,sphereOnPath:icons$2.sphereOnPath,sphericalBeam:icons$2.sphericalBeam,sprayCan:icons$2.sprayCan,star:icons$2.star,starSecondary:icons$2.starSecondary,stopwatchArrows01:icons$2.stopwatchArrows01,stopwatchArrows02:icons$2.stopwatchArrows02,stopwatchSectionOutlinedEnd:icons$2.stopwatchSectionOutlinedEnd,stopwatchSectionOutlinedStart:icons$2.stopwatchSectionOutlinedStart,stopwatchSectionSolidEnd:icons$2.stopwatchSectionSolidEnd,stopwatchSectionSolidStart:icons$2.stopwatchSectionSolidStart,survellianceCamera:icons$2.survellianceCamera,switchBlock:icons$2.switchBlock,switchOutline:icons$2.switchOutline,sync:icons$2.sync,taxiCar1:icons$2.taxiCar1,taxiCar3:icons$2.taxiCar3,taxiCarT:icons$2.taxiCarT,taxiCheckerLamp:icons$2.taxiCheckerLamp,terrainToLine:icons$2.terrainToLine,terrain:icons$2.terrain,thinBulbBeam:icons$2.thinBulbBeam,thinnerBulbBeam:icons$2.thinnerBulbBeam,tiles:icons$2.tiles,timer:icons$2.timer,toCOMWithWheels:icons$2.toCOMWithWheels,toCOM:icons$2.toCOM,tow:icons$2.tow,transform:icons$2.transform,transparencyMask:icons$2.transparencyMask,trashBin2:icons$2.trashBin2,triangleBeam:icons$2.triangleBeam,trim:icons$2.trim,tulipBeam:icons$2.tulipBeam,tunnel:icons$2.tunnel,twoRoadsAdd:icons$2.twoRoadsAdd,twoRoadsCrossAdd:icons$2.twoRoadsCrossAdd,twoRoadsLink:icons$2.twoRoadsLink,undo:icons$2.undo,ungroup:icons$2.ungroup,unlink:icons$2.unlink,view:icons$2.view,voucherDiagonal1:icons$2.voucherDiagonal1,voucherDiagonal2:icons$2.voucherDiagonal2,voucherDiagonal3:icons$2.voucherDiagonal3,voucherHorizontal1:icons$2.voucherHorizontal1,voucherHorizontal2:icons$2.voucherHorizontal2,voucherHorizontal3:icons$2.voucherHorizontal3,wavesSignalReceived:icons$2.wavesSignalReceived,wavesSignalSentLeft:icons$2.wavesSignalSentLeft,wavesSignalSentRight:icons$2.wavesSignalSentRight,weight:icons$2.weight,wrench:icons$2.wrench,danger:icons$2.danger,droplet:icons$2.droplet,envelope:icons$2.envelope,fireDiamond:icons$2.fireDiamond,xmark:icons$2.xmark,scale:icons$2.scale,locationDestination:icons$2.locationDestination,locationSource:icons$2.locationSource,colorBrightnessSun:icons$2.colorBrightnessSun,colorCirclePalette:icons$2.colorCirclePalette,colorPalette:icons$2.colorPalette,colorSaturation:icons$2.colorSaturation,sortAscDown02:icons$2.sortAscDown02,sortAscDown:icons$2.sortAscDown,sortAscUp02:icons$2.sortAscUp02,sortAscUp:icons$2.sortAscUp,sortDescDown02:icons$2.sortDescDown02,sortDescDown:icons$2.sortDescDown,sortDescUp02:icons$2.sortDescUp02,sortDescUp:icons$2.sortDescUp,cardboardBoxCoins:icons$2.cardboardBoxCoins,lasso:icons$2.lasso,materialGlossy:icons$2.materialGlossy,materialMetal:icons$2.materialMetal,materialRoughness:icons$2.materialRoughness,materialTransparency01:icons$2.materialTransparency01,materialTransparency02:icons$2.materialTransparency02,metal01:icons$2.metal01,removeItemPolygon:icons$2.removeItemPolygon,removeListItem:icons$2.removeListItem,sortAsc:icons$2.sortAsc,sortDesc:icons$2.sortDesc,surfaceRoughness02:icons$2.surfaceRoughness02,shieldCheckmark:icons$2.shieldCheckmark,shieldHandCheckmark:icons$2.shieldHandCheckmark,shieldHandPlus:icons$2.shieldHandPlus,bridgeWithRiver:icons$2.bridgeWithRiver,gizmosOutline:icons$2.gizmosOutline,gizmosSolid:icons$2.gizmosSolid,highwayRoad3To2Merge01:icons$2.highwayRoad3To2Merge01,highwayRoad3To2Merge02:icons$2.highwayRoad3To2Merge02,highwayToUrbanRoadTransition01:icons$2.highwayToUrbanRoadTransition01,highwayToUrbanRoadTransition02:icons$2.highwayToUrbanRoadTransition02,pedestrianCrossing01:icons$2.pedestrianCrossing01,polygonalCube:icons$2.polygonalCube,roadEditOutline:icons$2.roadEditOutline,roadEditSolid:icons$2.roadEditSolid,roadFolderPlus:icons$2.roadFolderPlus,roadFolder:icons$2.roadFolder,roadGuideArrowOutline:icons$2.roadGuideArrowOutline,roadGuideArrowSolid:icons$2.roadGuideArrowSolid,roadOutlineMesh:icons$2.roadOutlineMesh,roadPedestrianCrossing02:icons$2.roadPedestrianCrossing02,roadProfileWithCheckmark:icons$2.roadProfileWithCheckmark,roadProfile:icons$2.roadProfile,roadRoundaboutJunction:icons$2.roadRoundaboutJunction,roadSidewalkTransition:icons$2.roadSidewalkTransition,roadStackPlus:icons$2.roadStackPlus,roadStack:icons$2.roadStack,roadTJunction:icons$2.roadTJunction,roadXJunction:icons$2.roadXJunction,roadYJunction:icons$2.roadYJunction,shoppingCart:icons$2.shoppingCart,singleLineToTerrain:icons$2.singleLineToTerrain,sphereOnMesh:icons$2.sphereOnMesh,twoLinesToTerrain:icons$2.twoLinesToTerrain,urbanRoad3To2Merge01:icons$2.urbanRoad3To2Merge01,urbanRoad3To2Merge02:icons$2.urbanRoad3To2Merge02,urbanRoadToHighwayTransition01:icons$2.urbanRoadToHighwayTransition01,urbanRoadToHighwayTransition02:icons$2.urbanRoadToHighwayTransition02,floppyDiskPlus:icons$2.floppyDiskPlus,highwayMerge:icons$2.highwayMerge,highwaySeparate:icons$2.highwaySeparate,highwayShoulderMerge:icons$2.highwayShoulderMerge,terrainToSingleLine:icons$2.terrainToSingleLine,terrainToTwoLines:icons$2.terrainToTwoLines,urbanRoadMerge:icons$2.urbanRoadMerge,urbanRoadSeparate:icons$2.urbanRoadSeparate,urbanShoulderMerge:icons$2.urbanShoulderMerge,BNGChat:icons$2.BNGChat,chatBubble:icons$2.chatBubble,cameraFarClip:icons$2.cameraFarClip,cameraNearClip:icons$2.cameraNearClip,explosion:icons$2.explosion,fireExtinguisher:icons$2.fireExtinguisher,fire:icons$2.fire,toggleOff:icons$2.toggleOff,toggleOn:icons$2.toggleOn,viewFarClip:icons$2.viewFarClip,viewNearClip:icons$2.viewNearClip,circleSlashed:icons$2.circleSlashed,scissorsSlashed:icons$2.scissorsSlashed,scissors:icons$2.scissors,airPuffRight1:icons$2.airPuffRight1,airPuffUp1:icons$2.airPuffUp1,arrowsReplace:icons$2.arrowsReplace,arrowsShuffle:icons$2.arrowsShuffle,arrowsSwitch:icons$2.arrowsSwitch,carClock:icons$2.carClock,carNumber1:icons$2.carNumber1,carNumber2:icons$2.carNumber2,carNumber3:icons$2.carNumber3,carNumber4:icons$2.carNumber4,carNumber5:icons$2.carNumber5,carNumber6:icons$2.carNumber6,carNumber7:icons$2.carNumber7,carNumber8:icons$2.carNumber8,carNumber9:icons$2.carNumber9,carPlus:icons$2.carPlus,loadMesh:icons$2.loadMesh,octagonBrick:icons$2.octagonBrick,octagon:icons$2.octagon,saveMesh:icons$2.saveMesh,trafficLight:icons$2.trafficLight,enter:icons$2.enter,pedestrianRunning:icons$2.pedestrianRunning,pedestrianStanding:icons$2.pedestrianStanding,seatArrowIn:icons$2.seatArrowIn,seatArrowOut:icons$2.seatArrowOut,seatVArrowIn:icons$2.seatVArrowIn,seatVArrowOut:icons$2.seatVArrowOut,vehicleArrowIn:icons$2.vehicleArrowIn,vehicleArrowOut:icons$2.vehicleArrowOut,leverFrontOperate:icons$2.leverFrontOperate,leverSideDown:icons$2.leverSideDown,leverSideOperate:icons$2.leverSideOperate,leverSideUp:icons$2.leverSideUp,medalEmpty:icons$2.medalEmpty,medalStar:icons$2.medalStar,seatArrowInLeft:icons$2.seatArrowInLeft,seatArrowOutLeft:icons$2.seatArrowOutLeft,seatVArrowInLeft:icons$2.seatVArrowInLeft,seatVArrowOutLeft:icons$2.seatVArrowOutLeft,badgeRoundEmpty:icons$2.badgeRoundEmpty,badgeRoundStar:icons$2.badgeRoundStar,badgeRound:icons$2.badgeRound,badge:icons$2.badge,beamCurrencyOutlineLarge:icons$2.beamCurrencyOutlineLarge,carSideOutlineLarge:icons$2.carSideOutlineLarge,flagOutlineLarge:icons$2.flagOutlineLarge,terrainOutlineLarge:icons$2.terrainOutlineLarge,rallyHelmet3To4:icons$2.rallyHelmet3To4,rallyHelmet:icons$2.rallyHelmet,test:icons$2.test,globeSimpleNotSign:icons$2.globeSimpleNotSign,globeSimplified:icons$2.globeSimplified,radialMenu:icons$2.radialMenu,branch:icons$2.branch,NA:icons$2.NA,magicWand:icons$2.magicWand,dice24:icons$2.dice24,diceD6:icons$2.diceD6,xmarkBold:icons$2.xmarkBold,house:icons$2.house,picture:icons$2.picture,shieldCheckmarkProgressbar:icons$2.shieldCheckmarkProgressbar},warning:{ABSIndicator:icons$2.ABSIndicator,DCBattery:icons$2.DCBattery,oilPressureIndicator:icons$2.oilPressureIndicator,parkingIndicator:icons$2.parkingIndicator},internals:{ABSIndicator:icons$2.ABSIndicator,DCBattery:icons$2.DCBattery,oilPressureIndicator:icons$2.oilPressureIndicator,parkingIndicator:icons$2.parkingIndicator},we:{addItemPolygon:icons$2.addItemPolygon,addListItem:icons$2.addListItem,addPolygonVertex:icons$2.addPolygonVertex,bSpline:icons$2.bSpline,beamCrashBarrier1:icons$2.beamCrashBarrier1,beamCrashBarrier2:icons$2.beamCrashBarrier2,beamCrashBarrier3:icons$2.beamCrashBarrier3,bezierPath1:icons$2.bezierPath1,bezierPath2:icons$2.bezierPath2,bicycle1:icons$2.bicycle1,bicycle2:icons$2.bicycle2,bollard:icons$2.bollard,bulldozer:icons$2.bulldozer,concreteRoadBlock:icons$2.concreteRoadBlock,crossroads1:icons$2.crossroads1,crossroads2:icons$2.crossroads2,decalRoad:icons$2.decalRoad,flatBulbBeam:icons$2.flatBulbBeam,frontAxleMidpoint:icons$2.frontAxleMidpoint,frontBumperMidpoint:icons$2.frontBumperMidpoint,lampPost1:icons$2.lampPost1,lampPost2:icons$2.lampPost2,lampPost3:icons$2.lampPost3,laneProperties:icons$2.laneProperties,lidarPatternFullArcHighFreq:icons$2.lidarPatternFullArcHighFreq,lidarPatternFullArcMidFreq:icons$2.lidarPatternFullArcMidFreq,lidarPatternNarrowArc:icons$2.lidarPatternNarrowArc,lineToTerrain:icons$2.lineToTerrain,longRangeBeam1:icons$2.longRangeBeam1,longRangeBeam2:icons$2.longRangeBeam2,magnetOnSurface:icons$2.magnetOnSurface,meshFence:icons$2.meshFence,meshRoad:icons$2.meshRoad,midRangeBeam1:icons$2.midRangeBeam1,midRangeBeam2:icons$2.midRangeBeam2,pathArc:icons$2.pathArc,pathLine:icons$2.pathLine,pathSpiral:icons$2.pathSpiral,rearAxleMidpoint:icons$2.rearAxleMidpoint,rearBumperMidpoint:icons$2.rearBumperMidpoint,roadDividerLinesDecal:icons$2.roadDividerLinesDecal,roadEdgeLineDecal:icons$2.roadEdgeLineDecal,roadEndLineDecal:icons$2.roadEndLineDecal,roadFace:icons$2.roadFace,roadMarkingOutline:icons$2.roadMarkingOutline,roadMarkingSolid:icons$2.roadMarkingSolid,roadOutline:icons$2.roadOutline,roadRefPathDecal:icons$2.roadRefPathDecal,roadRefPath:icons$2.roadRefPath,roadStartLineDecal:icons$2.roadStartLineDecal,shortRangeBeam1:icons$2.shortRangeBeam1,shortRangeBeam2:icons$2.shortRangeBeam2,sphereOnPathNumber:icons$2.sphereOnPathNumber,sphereOnPath:icons$2.sphereOnPath,sphericalBeam:icons$2.sphericalBeam,terrainToLine:icons$2.terrainToLine,thinBulbBeam:icons$2.thinBulbBeam,thinnerBulbBeam:icons$2.thinnerBulbBeam,toCOMWithWheels:icons$2.toCOMWithWheels,toCOM:icons$2.toCOM,triangleBeam:icons$2.triangleBeam,tulipBeam:icons$2.tulipBeam,tunnel:icons$2.tunnel,twoRoadsAdd:icons$2.twoRoadsAdd,twoRoadsCrossAdd:icons$2.twoRoadsCrossAdd,twoRoadsLink:icons$2.twoRoadsLink,lasso:icons$2.lasso,removeItemPolygon:icons$2.removeItemPolygon,removeListItem:icons$2.removeListItem,bridgeWithRiver:icons$2.bridgeWithRiver,gizmosOutline:icons$2.gizmosOutline,gizmosSolid:icons$2.gizmosSolid,highwayRoad3To2Merge01:icons$2.highwayRoad3To2Merge01,highwayRoad3To2Merge02:icons$2.highwayRoad3To2Merge02,highwayToUrbanRoadTransition01:icons$2.highwayToUrbanRoadTransition01,highwayToUrbanRoadTransition02:icons$2.highwayToUrbanRoadTransition02,pedestrianCrossing01:icons$2.pedestrianCrossing01,polygonalCube:icons$2.polygonalCube,roadEditOutline:icons$2.roadEditOutline,roadEditSolid:icons$2.roadEditSolid,roadFolderPlus:icons$2.roadFolderPlus,roadFolder:icons$2.roadFolder,roadGuideArrowOutline:icons$2.roadGuideArrowOutline,roadGuideArrowSolid:icons$2.roadGuideArrowSolid,roadOutlineMesh:icons$2.roadOutlineMesh,roadPedestrianCrossing02:icons$2.roadPedestrianCrossing02,roadProfileWithCheckmark:icons$2.roadProfileWithCheckmark,roadProfile:icons$2.roadProfile,roadRoundaboutJunction:icons$2.roadRoundaboutJunction,roadSidewalkTransition:icons$2.roadSidewalkTransition,roadStackPlus:icons$2.roadStackPlus,roadStack:icons$2.roadStack,roadTJunction:icons$2.roadTJunction,roadXJunction:icons$2.roadXJunction,roadYJunction:icons$2.roadYJunction,singleLineToTerrain:icons$2.singleLineToTerrain,sphereOnMesh:icons$2.sphereOnMesh,twoLinesToTerrain:icons$2.twoLinesToTerrain,urbanRoad3To2Merge01:icons$2.urbanRoad3To2Merge01,urbanRoad3To2Merge02:icons$2.urbanRoad3To2Merge02,urbanRoadToHighwayTransition01:icons$2.urbanRoadToHighwayTransition01,urbanRoadToHighwayTransition02:icons$2.urbanRoadToHighwayTransition02,highwayMerge:icons$2.highwayMerge,highwaySeparate:icons$2.highwaySeparate,highwayShoulderMerge:icons$2.highwayShoulderMerge,terrainToSingleLine:icons$2.terrainToSingleLine,terrainToTwoLines:icons$2.terrainToTwoLines,urbanRoadMerge:icons$2.urbanRoadMerge,urbanRoadSeparate:icons$2.urbanRoadSeparate,urbanShoulderMerge:icons$2.urbanShoulderMerge},"world editor":{addItemPolygon:icons$2.addItemPolygon,addListItem:icons$2.addListItem,addPolygonVertex:icons$2.addPolygonVertex,bSpline:icons$2.bSpline,beamCrashBarrier1:icons$2.beamCrashBarrier1,beamCrashBarrier2:icons$2.beamCrashBarrier2,beamCrashBarrier3:icons$2.beamCrashBarrier3,bezierPath1:icons$2.bezierPath1,bezierPath2:icons$2.bezierPath2,bicycle1:icons$2.bicycle1,bicycle2:icons$2.bicycle2,bollard:icons$2.bollard,bulldozer:icons$2.bulldozer,concreteRoadBlock:icons$2.concreteRoadBlock,crossroads1:icons$2.crossroads1,crossroads2:icons$2.crossroads2,decalRoad:icons$2.decalRoad,flatBulbBeam:icons$2.flatBulbBeam,frontAxleMidpoint:icons$2.frontAxleMidpoint,frontBumperMidpoint:icons$2.frontBumperMidpoint,lampPost1:icons$2.lampPost1,lampPost2:icons$2.lampPost2,lampPost3:icons$2.lampPost3,laneProperties:icons$2.laneProperties,lidarPatternFullArcHighFreq:icons$2.lidarPatternFullArcHighFreq,lidarPatternFullArcMidFreq:icons$2.lidarPatternFullArcMidFreq,lidarPatternNarrowArc:icons$2.lidarPatternNarrowArc,lineToTerrain:icons$2.lineToTerrain,longRangeBeam1:icons$2.longRangeBeam1,longRangeBeam2:icons$2.longRangeBeam2,magnetOnSurface:icons$2.magnetOnSurface,meshFence:icons$2.meshFence,meshRoad:icons$2.meshRoad,midRangeBeam1:icons$2.midRangeBeam1,midRangeBeam2:icons$2.midRangeBeam2,pathArc:icons$2.pathArc,pathLine:icons$2.pathLine,pathSpiral:icons$2.pathSpiral,rearAxleMidpoint:icons$2.rearAxleMidpoint,rearBumperMidpoint:icons$2.rearBumperMidpoint,roadDividerLinesDecal:icons$2.roadDividerLinesDecal,roadEdgeLineDecal:icons$2.roadEdgeLineDecal,roadEndLineDecal:icons$2.roadEndLineDecal,roadFace:icons$2.roadFace,roadMarkingOutline:icons$2.roadMarkingOutline,roadMarkingSolid:icons$2.roadMarkingSolid,roadOutline:icons$2.roadOutline,roadRefPathDecal:icons$2.roadRefPathDecal,roadRefPath:icons$2.roadRefPath,roadStartLineDecal:icons$2.roadStartLineDecal,shortRangeBeam1:icons$2.shortRangeBeam1,shortRangeBeam2:icons$2.shortRangeBeam2,sphereOnPathNumber:icons$2.sphereOnPathNumber,sphereOnPath:icons$2.sphereOnPath,sphericalBeam:icons$2.sphericalBeam,terrainToLine:icons$2.terrainToLine,thinBulbBeam:icons$2.thinBulbBeam,thinnerBulbBeam:icons$2.thinnerBulbBeam,toCOMWithWheels:icons$2.toCOMWithWheels,toCOM:icons$2.toCOM,triangleBeam:icons$2.triangleBeam,tulipBeam:icons$2.tulipBeam,tunnel:icons$2.tunnel,twoRoadsAdd:icons$2.twoRoadsAdd,twoRoadsCrossAdd:icons$2.twoRoadsCrossAdd,twoRoadsLink:icons$2.twoRoadsLink,lasso:icons$2.lasso,removeItemPolygon:icons$2.removeItemPolygon,removeListItem:icons$2.removeListItem,bridgeWithRiver:icons$2.bridgeWithRiver,gizmosOutline:icons$2.gizmosOutline,gizmosSolid:icons$2.gizmosSolid,highwayRoad3To2Merge01:icons$2.highwayRoad3To2Merge01,highwayRoad3To2Merge02:icons$2.highwayRoad3To2Merge02,highwayToUrbanRoadTransition01:icons$2.highwayToUrbanRoadTransition01,highwayToUrbanRoadTransition02:icons$2.highwayToUrbanRoadTransition02,pedestrianCrossing01:icons$2.pedestrianCrossing01,polygonalCube:icons$2.polygonalCube,roadEditOutline:icons$2.roadEditOutline,roadEditSolid:icons$2.roadEditSolid,roadFolderPlus:icons$2.roadFolderPlus,roadFolder:icons$2.roadFolder,roadGuideArrowOutline:icons$2.roadGuideArrowOutline,roadGuideArrowSolid:icons$2.roadGuideArrowSolid,roadOutlineMesh:icons$2.roadOutlineMesh,roadPedestrianCrossing02:icons$2.roadPedestrianCrossing02,roadProfileWithCheckmark:icons$2.roadProfileWithCheckmark,roadProfile:icons$2.roadProfile,roadRoundaboutJunction:icons$2.roadRoundaboutJunction,roadSidewalkTransition:icons$2.roadSidewalkTransition,roadStackPlus:icons$2.roadStackPlus,roadStack:icons$2.roadStack,roadTJunction:icons$2.roadTJunction,roadXJunction:icons$2.roadXJunction,roadYJunction:icons$2.roadYJunction,singleLineToTerrain:icons$2.singleLineToTerrain,sphereOnMesh:icons$2.sphereOnMesh,twoLinesToTerrain:icons$2.twoLinesToTerrain,urbanRoad3To2Merge01:icons$2.urbanRoad3To2Merge01,urbanRoad3To2Merge02:icons$2.urbanRoad3To2Merge02,urbanRoadToHighwayTransition01:icons$2.urbanRoadToHighwayTransition01,urbanRoadToHighwayTransition02:icons$2.urbanRoadToHighwayTransition02,highwayMerge:icons$2.highwayMerge,highwaySeparate:icons$2.highwaySeparate,highwayShoulderMerge:icons$2.highwayShoulderMerge,terrainToSingleLine:icons$2.terrainToSingleLine,terrainToTwoLines:icons$2.terrainToTwoLines,urbanRoadMerge:icons$2.urbanRoadMerge,urbanRoadSeparate:icons$2.urbanRoadSeparate,urbanShoulderMerge:icons$2.urbanShoulderMerge},"road tools":{addItemPolygon:icons$2.addItemPolygon,addListItem:icons$2.addListItem,addPolygonVertex:icons$2.addPolygonVertex,bSpline:icons$2.bSpline,beamCrashBarrier1:icons$2.beamCrashBarrier1,beamCrashBarrier2:icons$2.beamCrashBarrier2,beamCrashBarrier3:icons$2.beamCrashBarrier3,bezierPath1:icons$2.bezierPath1,bezierPath2:icons$2.bezierPath2,bicycle1:icons$2.bicycle1,bicycle2:icons$2.bicycle2,bollard:icons$2.bollard,bulldozer:icons$2.bulldozer,concreteRoadBlock:icons$2.concreteRoadBlock,crossroads1:icons$2.crossroads1,crossroads2:icons$2.crossroads2,decalRoad:icons$2.decalRoad,lampPost1:icons$2.lampPost1,lampPost2:icons$2.lampPost2,lampPost3:icons$2.lampPost3,laneProperties:icons$2.laneProperties,lineToTerrain:icons$2.lineToTerrain,magnetOnSurface:icons$2.magnetOnSurface,meshFence:icons$2.meshFence,meshRoad:icons$2.meshRoad,pathArc:icons$2.pathArc,pathLine:icons$2.pathLine,pathSpiral:icons$2.pathSpiral,roadDividerLinesDecal:icons$2.roadDividerLinesDecal,roadEdgeLineDecal:icons$2.roadEdgeLineDecal,roadEndLineDecal:icons$2.roadEndLineDecal,roadFace:icons$2.roadFace,roadMarkingSolid:icons$2.roadMarkingSolid,roadOutline:icons$2.roadOutline,roadRefPathDecal:icons$2.roadRefPathDecal,roadRefPath:icons$2.roadRefPath,roadStartLineDecal:icons$2.roadStartLineDecal,sphereOnPathNumber:icons$2.sphereOnPathNumber,sphereOnPath:icons$2.sphereOnPath,terrainToLine:icons$2.terrainToLine,tunnel:icons$2.tunnel,twoRoadsAdd:icons$2.twoRoadsAdd,twoRoadsCrossAdd:icons$2.twoRoadsCrossAdd,twoRoadsLink:icons$2.twoRoadsLink,removeItemPolygon:icons$2.removeItemPolygon,removeListItem:icons$2.removeListItem,bridgeWithRiver:icons$2.bridgeWithRiver,gizmosOutline:icons$2.gizmosOutline,gizmosSolid:icons$2.gizmosSolid,highwayRoad3To2Merge01:icons$2.highwayRoad3To2Merge01,highwayRoad3To2Merge02:icons$2.highwayRoad3To2Merge02,highwayToUrbanRoadTransition01:icons$2.highwayToUrbanRoadTransition01,highwayToUrbanRoadTransition02:icons$2.highwayToUrbanRoadTransition02,pedestrianCrossing01:icons$2.pedestrianCrossing01,polygonalCube:icons$2.polygonalCube,roadEditOutline:icons$2.roadEditOutline,roadEditSolid:icons$2.roadEditSolid,roadFolderPlus:icons$2.roadFolderPlus,roadFolder:icons$2.roadFolder,roadGuideArrowOutline:icons$2.roadGuideArrowOutline,roadGuideArrowSolid:icons$2.roadGuideArrowSolid,roadOutlineMesh:icons$2.roadOutlineMesh,roadPedestrianCrossing02:icons$2.roadPedestrianCrossing02,roadProfileWithCheckmark:icons$2.roadProfileWithCheckmark,roadProfile:icons$2.roadProfile,roadRoundaboutJunction:icons$2.roadRoundaboutJunction,roadSidewalkTransition:icons$2.roadSidewalkTransition,roadStackPlus:icons$2.roadStackPlus,roadStack:icons$2.roadStack,roadTJunction:icons$2.roadTJunction,roadXJunction:icons$2.roadXJunction,roadYJunction:icons$2.roadYJunction,singleLineToTerrain:icons$2.singleLineToTerrain,sphereOnMesh:icons$2.sphereOnMesh,twoLinesToTerrain:icons$2.twoLinesToTerrain,urbanRoad3To2Merge01:icons$2.urbanRoad3To2Merge01,urbanRoad3To2Merge02:icons$2.urbanRoad3To2Merge02,urbanRoadToHighwayTransition01:icons$2.urbanRoadToHighwayTransition01,urbanRoadToHighwayTransition02:icons$2.urbanRoadToHighwayTransition02,highwayMerge:icons$2.highwayMerge,highwaySeparate:icons$2.highwaySeparate,highwayShoulderMerge:icons$2.highwayShoulderMerge,terrainToSingleLine:icons$2.terrainToSingleLine,terrainToTwoLines:icons$2.terrainToTwoLines,urbanRoadMerge:icons$2.urbanRoadMerge,urbanRoadSeparate:icons$2.urbanRoadSeparate,urbanShoulderMerge:icons$2.urbanShoulderMerge},ai:{AIMicrochip:icons$2.AIMicrochip},microchip:{AIMicrochip:icons$2.AIMicrochip},poi:{AIRace:icons$2.AIRace,barrelKnocker01:icons$2.barrelKnocker01,barrelKnocker02:icons$2.barrelKnocker02,boxDropOff01:icons$2.boxDropOff01,boxDropOff02:icons$2.boxDropOff02,boxDropOff03:icons$2.boxDropOff03,boxPickUp01:icons$2.boxPickUp01,boxPickUp02:icons$2.boxPickUp02,boxPickUp03:icons$2.boxPickUp03,boxPickUpDropOff01:icons$2.boxPickUpDropOff01,boxPickUpDropOff02:icons$2.boxPickUpDropOff02,bus:icons$2.bus,cannon:icons$2.cannon,circuit:icons$2.circuit,deliveryTruckArrows:icons$2.deliveryTruckArrows,deliveryTruck:icons$2.deliveryTruck,drag01:icons$2.drag01,drag02:icons$2.drag02,drift01:icons$2.drift01,drift02:icons$2.drift02,evade:icons$2.evade,fastTravel:icons$2.fastTravel,flagNew:icons$2.flagNew,flag:icons$2.flag,gaugeEmpty:icons$2.gaugeEmpty,hypermiling:icons$2.hypermiling,jump:icons$2.jump,parking:icons$2.parking,raceFlag:icons$2.raceFlag,rockCrawling01:icons$2.rockCrawling01,rockCrawling02:icons$2.rockCrawling02,targetJump:icons$2.targetJump,toGarage:icons$2.toGarage,trashBin1:icons$2.trashBin1,circlePinBack:icons$2.circlePinBack,circlePinFront:icons$2.circlePinFront,markerRectanglePinBack:icons$2.markerRectanglePinBack,markerRectanglePinFront:icons$2.markerRectanglePinFront,markerTriangleBack:icons$2.markerTriangleBack,markerTriangleFront:icons$2.markerTriangleFront,busTilted:icons$2.busTilted,gaugeFull:icons$2.gaugeFull},camera:{aperture:icons$2.aperture,camera3Fourth1:icons$2.camera3Fourth1,cameraBack1:icons$2.cameraBack1,cameraFocusOnPath:icons$2.cameraFocusOnPath,cameraFocusOnVehicle1:icons$2.cameraFocusOnVehicle1,cameraFocusOnVehicle2:icons$2.cameraFocusOnVehicle2,cameraFocusTopDown:icons$2.cameraFocusTopDown,cameraFront1:icons$2.cameraFront1,cameraSideLeft:icons$2.cameraSideLeft,cameraSideLeft2:icons$2.cameraSideLeft2,cameraSideRight:icons$2.cameraSideRight,cameraSideRight2:icons$2.cameraSideRight2,cameraTop1:icons$2.cameraTop1,movieCamera:icons$2.movieCamera,pathAroundObstacle:icons$2.pathAroundObstacle,survellianceCamera:icons$2.survellianceCamera,pathDice:icons$2.pathDice},optical:{aperture:icons$2.aperture,survellianceCamera:icons$2.survellianceCamera},sensor:{aperture:icons$2.aperture,eyeWaves:icons$2.eyeWaves,flatBulbBeam:icons$2.flatBulbBeam,frontAxleMidpoint:icons$2.frontAxleMidpoint,frontBumperMidpoint:icons$2.frontBumperMidpoint,GPSMark:icons$2.GPSMark,GPSSolid:icons$2.GPSSolid,gyroscopeMicrochip:icons$2.gyroscopeMicrochip,gyroscope:icons$2.gyroscope,lidarPatternFullArcHighFreq:icons$2.lidarPatternFullArcHighFreq,lidarPatternFullArcMidFreq:icons$2.lidarPatternFullArcMidFreq,lidarPatternNarrowArc:icons$2.lidarPatternNarrowArc,lidar:icons$2.lidar,location1:icons$2.location1,location2:icons$2.location2,longRangeBeam1:icons$2.longRangeBeam1,longRangeBeam2:icons$2.longRangeBeam2,midRangeBeam1:icons$2.midRangeBeam1,midRangeBeam2:icons$2.midRangeBeam2,radarIdeal:icons$2.radarIdeal,radarRoundIdeal:icons$2.radarRoundIdeal,radarRound:icons$2.radarRound,radar:icons$2.radar,rearAxleMidpoint:icons$2.rearAxleMidpoint,rearBumperMidpoint:icons$2.rearBumperMidpoint,shortRangeBeam1:icons$2.shortRangeBeam1,shortRangeBeam2:icons$2.shortRangeBeam2,sphericalBeam:icons$2.sphericalBeam,survellianceCamera:icons$2.survellianceCamera,thinBulbBeam:icons$2.thinBulbBeam,thinnerBulbBeam:icons$2.thinnerBulbBeam,toCOMWithWheels:icons$2.toCOMWithWheels,toCOM:icons$2.toCOM,triangleBeam:icons$2.triangleBeam,tulipBeam:icons$2.tulipBeam,wavesSignalReceived:icons$2.wavesSignalReceived,wavesSignalSentLeft:icons$2.wavesSignalSentLeft,wavesSignalSentRight:icons$2.wavesSignalSentRight},arrow:{arrowLargeDown:icons$2.arrowLargeDown,arrowLargeLeft:icons$2.arrowLargeLeft,arrowLargeRight:icons$2.arrowLargeRight,arrowLargeUp:icons$2.arrowLargeUp,arrowSmallDown:icons$2.arrowSmallDown,arrowSmallLeft:icons$2.arrowSmallLeft,arrowSmallRight:icons$2.arrowSmallRight,arrowSmallUp:icons$2.arrowSmallUp,arrowSolidLeft:icons$2.arrowSolidLeft,arrowSolidRight:icons$2.arrowSolidRight,twoArrowsHorizontal:icons$2.twoArrowsHorizontal,twoArrowsVertical:icons$2.twoArrowsVertical,arrowsReplace:icons$2.arrowsReplace,arrowsShuffle:icons$2.arrowsShuffle,arrowsSwitch:icons$2.arrowsSwitch,seatArrowIn:icons$2.seatArrowIn,seatArrowOut:icons$2.seatArrowOut,seatVArrowIn:icons$2.seatVArrowIn,seatVArrowOut:icons$2.seatVArrowOut,vehicleArrowIn:icons$2.vehicleArrowIn,vehicleArrowOut:icons$2.vehicleArrowOut,seatArrowInLeft:icons$2.seatArrowInLeft,seatArrowOutLeft:icons$2.seatArrowOutLeft,seatVArrowInLeft:icons$2.seatVArrowInLeft,seatVArrowOutLeft:icons$2.seatVArrowOutLeft},large:{arrowLargeDown:icons$2.arrowLargeDown,arrowLargeLeft:icons$2.arrowLargeLeft,arrowLargeRight:icons$2.arrowLargeRight,arrowLargeUp:icons$2.arrowLargeUp,arrowSolidLeft:icons$2.arrowSolidLeft,arrowSolidRight:icons$2.arrowSolidRight,arrowLeftOutline:icons$2.arrowLeftOutline,arrowRightOutline:icons$2.arrowRightOutline,beamsNodesMessageOutline:icons$2.beamsNodesMessageOutline,beamsNodesOutline:icons$2.beamsNodesOutline,beamsNodesPlugOutline:icons$2.beamsNodesPlugOutline,BNGEcosystemOutline:icons$2.BNGEcosystemOutline,carFrontRouteOutline:icons$2.carFrontRouteOutline,carSensorsOutline:icons$2.carSensorsOutline,carSideRouteOutline:icons$2.carSideRouteOutline,cityOutline:icons$2.cityOutline,dialogOutline:icons$2.dialogOutline,documentSmileOutline:icons$2.documentSmileOutline,drivetrainOutline:icons$2.drivetrainOutline,electronicSchemeOutline:icons$2.electronicSchemeOutline,engineOutline:icons$2.engineOutline,gearTuningOutline:icons$2.gearTuningOutline,giftBoxOutline:icons$2.giftBoxOutline,lidarOutline:icons$2.lidarOutline,medalStarOutline:icons$2.medalStarOutline,megaphoneOutline:icons$2.megaphoneOutline,peopleOutline:icons$2.peopleOutline,personOutline:icons$2.personOutline,physicsOutline:icons$2.physicsOutline,playChainOutline:icons$2.playChainOutline,proximitySensorsOutline:icons$2.proximitySensorsOutline,qualityBadgeStarOutline:icons$2.qualityBadgeStarOutline,qualityBadgeVOutline:icons$2.qualityBadgeVOutline,simRigOutline:icons$2.simRigOutline,suspensionOutline:icons$2.suspensionOutline,teamOutline:icons$2.teamOutline,techLightBulbOutline01:icons$2.techLightBulbOutline01,techLightBulbOutline02:icons$2.techLightBulbOutline02,timeUnlockOutline:icons$2.timeUnlockOutline,timedLockOutline:icons$2.timedLockOutline,trafficOutline:icons$2.trafficOutline,voucherOutline:icons$2.voucherOutline,wheelBeamsNodesOutline:icons$2.wheelBeamsNodesOutline,wheelOutline:icons$2.wheelOutline,twoArrowsHorizontal:icons$2.twoArrowsHorizontal,twoArrowsVertical:icons$2.twoArrowsVertical},simple:{arrowLargeDown:icons$2.arrowLargeDown,arrowLargeLeft:icons$2.arrowLargeLeft,arrowLargeRight:icons$2.arrowLargeRight,arrowLargeUp:icons$2.arrowLargeUp,arrowSmallDown:icons$2.arrowSmallDown,arrowSmallLeft:icons$2.arrowSmallLeft,arrowSmallRight:icons$2.arrowSmallRight,arrowSmallUp:icons$2.arrowSmallUp},outlined:{arrowLargeDown:icons$2.arrowLargeDown,arrowLargeLeft:icons$2.arrowLargeLeft,arrowLargeRight:icons$2.arrowLargeRight,arrowLargeUp:icons$2.arrowLargeUp,arrowSmallDown:icons$2.arrowSmallDown,arrowSmallLeft:icons$2.arrowSmallLeft,arrowSmallRight:icons$2.arrowSmallRight,arrowSmallUp:icons$2.arrowSmallUp,roadMarkingOutline:icons$2.roadMarkingOutline,arrowLeftOutline:icons$2.arrowLeftOutline,arrowRightOutline:icons$2.arrowRightOutline,beamsNodesMessageOutline:icons$2.beamsNodesMessageOutline,beamsNodesOutline:icons$2.beamsNodesOutline,beamsNodesPlugOutline:icons$2.beamsNodesPlugOutline,BNGEcosystemOutline:icons$2.BNGEcosystemOutline,carFrontRouteOutline:icons$2.carFrontRouteOutline,carSensorsOutline:icons$2.carSensorsOutline,carSideRouteOutline:icons$2.carSideRouteOutline,cityOutline:icons$2.cityOutline,dialogOutline:icons$2.dialogOutline,documentSmileOutline:icons$2.documentSmileOutline,drivetrainOutline:icons$2.drivetrainOutline,electronicSchemeOutline:icons$2.electronicSchemeOutline,engineOutline:icons$2.engineOutline,gearTuningOutline:icons$2.gearTuningOutline,giftBoxOutline:icons$2.giftBoxOutline,lidarOutline:icons$2.lidarOutline,medalStarOutline:icons$2.medalStarOutline,megaphoneOutline:icons$2.megaphoneOutline,peopleOutline:icons$2.peopleOutline,personOutline:icons$2.personOutline,physicsOutline:icons$2.physicsOutline,playChainOutline:icons$2.playChainOutline,proximitySensorsOutline:icons$2.proximitySensorsOutline,qualityBadgeStarOutline:icons$2.qualityBadgeStarOutline,qualityBadgeVOutline:icons$2.qualityBadgeVOutline,simRigOutline:icons$2.simRigOutline,suspensionOutline:icons$2.suspensionOutline,teamOutline:icons$2.teamOutline,techLightBulbOutline01:icons$2.techLightBulbOutline01,techLightBulbOutline02:icons$2.techLightBulbOutline02,timeUnlockOutline:icons$2.timeUnlockOutline,timedLockOutline:icons$2.timedLockOutline,trafficOutline:icons$2.trafficOutline,voucherOutline:icons$2.voucherOutline,wheelBeamsNodesOutline:icons$2.wheelBeamsNodesOutline,wheelOutline:icons$2.wheelOutline},small:{arrowSmallDown:icons$2.arrowSmallDown,arrowSmallLeft:icons$2.arrowSmallLeft,arrowSmallRight:icons$2.arrowSmallRight,arrowSmallUp:icons$2.arrowSmallUp,mathDivide:icons$2.mathDivide,mathGreaterOrEqualThan:icons$2.mathGreaterOrEqualThan,mathGreaterThan:icons$2.mathGreaterThan,mathLessOrEqualThan:icons$2.mathLessOrEqualThan,mathLessThan:icons$2.mathLessThan,mathMinus:icons$2.mathMinus,mathMultiply:icons$2.mathMultiply,mathPlus:icons$2.mathPlus,slashLeft:icons$2.slashLeft,slashRight:icons$2.slashRight},solid:{arrowSolidLeft:icons$2.arrowSolidLeft,arrowSolidRight:icons$2.arrowSolidRight,twoArrowsHorizontal:icons$2.twoArrowsHorizontal,twoArrowsVertical:icons$2.twoArrowsVertical},detailed:{arrowSolidLeft:icons$2.arrowSolidLeft,arrowSolidRight:icons$2.arrowSolidRight},career:{banknotes:icons$2.banknotes,beamCurrency:icons$2.beamCurrency,beamXPFull:icons$2.beamXPFull,beamXPLo:icons$2.beamXPLo,carDealer:icons$2.carDealer,garage01:icons$2.garage01,garage02:icons$2.garage02,garage03:icons$2.garage03,lightGarageG11:icons$2.lightGarageG11,lightGarageG12:icons$2.lightGarageG12,lightGarageG13:icons$2.lightGarageG13,lightGarageG14:icons$2.lightGarageG14,lightGarageG21:icons$2.lightGarageG21,lightGarageG22:icons$2.lightGarageG22,lightGarageG23:icons$2.lightGarageG23,lightGarageG24:icons$2.lightGarageG24,lightGarageG31:icons$2.lightGarageG31,lightGarageG32:icons$2.lightGarageG32,lightGarageG33:icons$2.lightGarageG33,lightGarageG34:icons$2.lightGarageG34,plusGarage1:icons$2.plusGarage1,plusGarage2:icons$2.plusGarage2,plusGarage3:icons$2.plusGarage3,plusGarage4:icons$2.plusGarage4,voucherDiagonal1:icons$2.voucherDiagonal1,voucherDiagonal2:icons$2.voucherDiagonal2,voucherDiagonal3:icons$2.voucherDiagonal3,voucherHorizontal1:icons$2.voucherHorizontal1,voucherHorizontal2:icons$2.voucherHorizontal2,voucherHorizontal3:icons$2.voucherHorizontal3,garageNumber1:icons$2.garageNumber1,garageNumber2:icons$2.garageNumber2,garageNumber3:icons$2.garageNumber3,garageNumber4:icons$2.garageNumber4,garageNumber5:icons$2.garageNumber5,garageNumber6:icons$2.garageNumber6,garageNumber7:icons$2.garageNumber7,garageNumber8:icons$2.garageNumber8,garageNumber9:icons$2.garageNumber9,houseWrenchRoof:icons$2.houseWrenchRoof,houseWrench:icons$2.houseWrench,house:icons$2.house,beamCurrencyThin:icons$2.beamCurrencyThin},currencies:{banknotes:icons$2.banknotes,beamCurrency:icons$2.beamCurrency,beamXPFull:icons$2.beamXPFull,beamXPLo:icons$2.beamXPLo,beamCurrencyThin:icons$2.beamCurrencyThin},brand:{beamNG:icons$2.beamNG},beamng:{beamNG:icons$2.beamNG},decals:{booleanIntersect:icons$2.booleanIntersect,cameraFocusOnVehicle2:icons$2.cameraFocusOnVehicle2,copy:icons$2.copy,decal:icons$2.decal,deform:icons$2.deform,group:icons$2.group,material:icons$2.material,move:icons$2.move,order:icons$2.order,paperKnife:icons$2.paperKnife,redo:icons$2.redo,reflectNot:icons$2.reflectNot,reflect:icons$2.reflect,rename:icons$2.rename,sprayCan:icons$2.sprayCan,transform:icons$2.transform,transparencyMask:icons$2.transparencyMask,trashBin2:icons$2.trashBin2,undo:icons$2.undo,ungroup:icons$2.ungroup,view:icons$2.view,weight:icons$2.weight,scale:icons$2.scale,materialGlossy:icons$2.materialGlossy,materialMetal:icons$2.materialMetal,materialRoughness:icons$2.materialRoughness,materialTransparency01:icons$2.materialTransparency01,materialTransparency02:icons$2.materialTransparency02,surfaceRoughness02:icons$2.surfaceRoughness02,cameraFarClip:icons$2.cameraFarClip,cameraNearClip:icons$2.cameraNearClip,viewFarClip:icons$2.viewFarClip,viewNearClip:icons$2.viewNearClip},delivery:{boxDropOff01:icons$2.boxDropOff01,boxDropOff02:icons$2.boxDropOff02,boxDropOff03:icons$2.boxDropOff03,boxPickUp01:icons$2.boxPickUp01,boxPickUp02:icons$2.boxPickUp02,boxPickUp03:icons$2.boxPickUp03,boxPickUpDropOff01:icons$2.boxPickUpDropOff01,boxPickUpDropOff02:icons$2.boxPickUpDropOff02,boxTruck:icons$2.boxTruck,cardboardBox:icons$2.cardboardBox,deliveryTruckArrows:icons$2.deliveryTruckArrows,deliveryTruck:icons$2.deliveryTruck,flatbedTruck:icons$2.flatbedTruck,forklift:icons$2.forklift,fragile:icons$2.fragile,semiTrailer:icons$2.semiTrailer,semiTruckCabover:icons$2.semiTruckCabover,semiTruckUS:icons$2.semiTruckUS,semiTruck:icons$2.semiTruck,smallTrailer:icons$2.smallTrailer,stack3:icons$2.stack3,tankerTrailer:icons$2.tankerTrailer,thisSideUp:icons$2.thisSideUp,twoUnicyclesOnly:icons$2.twoUnicyclesOnly,boxTruckFast:icons$2.boxTruckFast,cardboardBoxCoins:icons$2.cardboardBoxCoins},cargo:{boxTruck:icons$2.boxTruck,flatbedTruck:icons$2.flatbedTruck,forklift:icons$2.forklift,fragile:icons$2.fragile,semiTrailer:icons$2.semiTrailer,semiTruckCabover:icons$2.semiTruckCabover,semiTruckUS:icons$2.semiTruckUS,semiTruck:icons$2.semiTruck,smallTrailer:icons$2.smallTrailer,stack3:icons$2.stack3,tankerTrailer:icons$2.tankerTrailer,thisSideUp:icons$2.thisSideUp,twoUnicyclesOnly:icons$2.twoUnicyclesOnly,boxTruckFast:icons$2.boxTruckFast},sound:{broom:icons$2.broom,soundFadeOut:icons$2.soundFadeOut,soundLimit:icons$2.soundLimit,soundLoud:icons$2.soundLoud,soundMonoL:icons$2.soundMonoL,soundMonoR:icons$2.soundMonoR,soundOff:icons$2.soundOff,soundQuiet:icons$2.soundQuiet,soundStereo:icons$2.soundStereo,soundWave01:icons$2.soundWave01,soundWave02:icons$2.soundWave02,trim:icons$2.trim},police:{carChase01:icons$2.carChase01,carsChase02:icons$2.carsChase02,evade:icons$2.evade,strobeLights:icons$2.strobeLights,wigwags:icons$2.wigwags},garage:{carDealer:icons$2.carDealer,garage01:icons$2.garage01,garage02:icons$2.garage02,garage03:icons$2.garage03,lightGarageG11:icons$2.lightGarageG11,lightGarageG12:icons$2.lightGarageG12,lightGarageG13:icons$2.lightGarageG13,lightGarageG14:icons$2.lightGarageG14,lightGarageG21:icons$2.lightGarageG21,lightGarageG22:icons$2.lightGarageG22,lightGarageG23:icons$2.lightGarageG23,lightGarageG24:icons$2.lightGarageG24,lightGarageG31:icons$2.lightGarageG31,lightGarageG32:icons$2.lightGarageG32,lightGarageG33:icons$2.lightGarageG33,lightGarageG34:icons$2.lightGarageG34,plusGarage1:icons$2.plusGarage1,plusGarage2:icons$2.plusGarage2,plusGarage3:icons$2.plusGarage3,plusGarage4:icons$2.plusGarage4,houseWrenchRoof:icons$2.houseWrenchRoof,houseWrench:icons$2.houseWrench,house:icons$2.house},sensors:{carSensors:icons$2.carSensors,carWithLidar:icons$2.carWithLidar,mapWithEmitter:icons$2.mapWithEmitter},tech:{carWithLidar:icons$2.carWithLidar,mapWithEmitter:icons$2.mapWithEmitter,mesh4Cells:icons$2.mesh4Cells,mesh9Cells:icons$2.mesh9Cells},fuel:{charge:icons$2.charge,charging:icons$2.charging,fuelPumpFilling:icons$2.fuelPumpFilling,fuelPump:icons$2.fuelPump,N2OButton:icons$2.N2OButton,N2OHoriz:icons$2.N2OHoriz,N2OVert:icons$2.N2OVert,discharging:icons$2.discharging},electricity:{charge:icons$2.charge,charging:icons$2.charging,discharging:icons$2.discharging},ev:{charge:icons$2.charge,charging:icons$2.charging,discharging:icons$2.discharging},checkbox:{checkboxOff:icons$2.checkboxOff,checkboxOn:icons$2.checkboxOn,missionCheckboxCross:icons$2.missionCheckboxCross},selection:{checkboxOff:icons$2.checkboxOff,checkboxOn:icons$2.checkboxOn,missionCheckboxCross:icons$2.missionCheckboxCross},box:{checkboxOff:icons$2.checkboxOff,checkboxOn:icons$2.checkboxOn,missionCheckboxCross:icons$2.missionCheckboxCross},movie:{clapperboard:icons$2.clapperboard},scenery:{clapperboard:icons$2.clapperboard},powertrain:{cogsDamaged:icons$2.cogsDamaged},drivetrain:{cogsDamaged:icons$2.cogsDamaged},data:{dataExchange:icons$2.dataExchange,eyeWaves:icons$2.eyeWaves,gyroscopeMicrochip:icons$2.gyroscopeMicrochip,gyroscope:icons$2.gyroscope,lidar:icons$2.lidar,radarIdeal:icons$2.radarIdeal,radarRoundIdeal:icons$2.radarRoundIdeal,radarRound:icons$2.radarRound,radar:icons$2.radar,wavesSignalReceived:icons$2.wavesSignalReceived,wavesSignalSentLeft:icons$2.wavesSignalSentLeft,wavesSignalSentRight:icons$2.wavesSignalSentRight},signal:{dataExchange:icons$2.dataExchange,eyeWaves:icons$2.eyeWaves,gyroscopeMicrochip:icons$2.gyroscopeMicrochip,gyroscope:icons$2.gyroscope,lidar:icons$2.lidar,radarIdeal:icons$2.radarIdeal,radarRoundIdeal:icons$2.radarRoundIdeal,radarRound:icons$2.radarRound,radar:icons$2.radar,wavesSignalReceived:icons$2.wavesSignalReceived,wavesSignalSentLeft:icons$2.wavesSignalSentLeft,wavesSignalSentRight:icons$2.wavesSignalSentRight},environment:{day:icons$2.day,night:icons$2.night,sunRise:icons$2.sunRise,weather:icons$2.weather,sunDown:icons$2.sunDown},part:{engine:icons$2.engine,suspension01:icons$2.suspension01,turbine:icons$2.turbine,doorFrontCoins:icons$2.doorFrontCoins,doorFront:icons$2.doorFront,engineCoins:icons$2.engineCoins,exhaustMufflerCoins:icons$2.exhaustMufflerCoins,exhaustMuffler:icons$2.exhaustMuffler,headlightCoins:icons$2.headlightCoins,headlight:icons$2.headlight,tire3FourthCoins:icons$2.tire3FourthCoins,tire3Fourth:icons$2.tire3Fourth,turbineCoins:icons$2.turbineCoins,wheelDiscCoins:icons$2.wheelDiscCoins,wheelDisc:icons$2.wheelDisc,doorFrontDetached:icons$2.doorFrontDetached,hingeBroken:icons$2.hingeBroken},mission:{evade:icons$2.evade,flagOutlineLarge:icons$2.flagOutlineLarge},playback:{fastBackward:icons$2.fastBackward,fastForward:icons$2.fastForward,music:icons$2.music,nextTrack:icons$2.nextTrack,pauseRound:icons$2.pauseRound,pause:icons$2.pause,playRound:icons$2.playRound,play:icons$2.play,playlist:icons$2.playlist,prevTrack:icons$2.prevTrack,square:icons$2.square,eject:icons$2.eject,playPause:icons$2.playPause},truck:{flatbedTruck:icons$2.flatbedTruck,semiTruckCabover:icons$2.semiTruckCabover,semiTruckUS:icons$2.semiTruckUS,semiTruck:icons$2.semiTruck},stencil:{forklift:icons$2.forklift,fragile:icons$2.fragile,stack3:icons$2.stack3,thisSideUp:icons$2.thisSideUp,twoUnicyclesOnly:icons$2.twoUnicyclesOnly},placement:{frontAxleMidpoint:icons$2.frontAxleMidpoint,frontBumperMidpoint:icons$2.frontBumperMidpoint,rearAxleMidpoint:icons$2.rearAxleMidpoint,rearBumperMidpoint:icons$2.rearBumperMidpoint,toCOMWithWheels:icons$2.toCOMWithWheels,toCOM:icons$2.toCOM},gamepad:{gamepadOld:icons$2.gamepadOld,gamepad:icons$2.gamepad,noNameControllerButton:icons$2.noNameControllerButton,xboxA:icons$2.xboxA,xboxB:icons$2.xboxB,xboxDDefaultOutline:icons$2.xboxDDefaultOutline,xboxDDefaultSolid:icons$2.xboxDDefaultSolid,xboxDDown:icons$2.xboxDDown,xboxDLeft:icons$2.xboxDLeft,xboxDRight:icons$2.xboxDRight,xboxDUp:icons$2.xboxDUp,xboxLB:icons$2.xboxLB,xboxLSButton:icons$2.xboxLSButton,xboxLT:icons$2.xboxLT,xboxMenu:icons$2.xboxMenu,xboxRB:icons$2.xboxRB,xboxRSButton:icons$2.xboxRSButton,xboxRT:icons$2.xboxRT,xboxThumbL:icons$2.xboxThumbL,xboxThumbR:icons$2.xboxThumbR,xboxView:icons$2.xboxView,xboxXAxis:icons$2.xboxXAxis,xboxXRot:icons$2.xboxXRot,xboxX:icons$2.xboxX,xboxYAxis:icons$2.xboxYAxis,xboxYRot:icons$2.xboxYRot,xboxY:icons$2.xboxY,psCircleOutline:icons$2.psCircleOutline,psCircle:icons$2.psCircle,psCreate2:icons$2.psCreate2,psCreate:icons$2.psCreate,psCrossOutline:icons$2.psCrossOutline,psCross:icons$2.psCross,psDDefaultOutline:icons$2.psDDefaultOutline,psDDefaultSolid:icons$2.psDDefaultSolid,psDDown:icons$2.psDDown,psDLeft:icons$2.psDLeft,psDRight:icons$2.psDRight,psDUp:icons$2.psDUp,psL1:icons$2.psL1,psL2:icons$2.psL2,psL3ButtonArrowDown:icons$2.psL3ButtonArrowDown,psL3Button:icons$2.psL3Button,psLSXLeft:icons$2.psLSXLeft,psLSXRight:icons$2.psLSXRight,psLSX:icons$2.psLSX,psLSYDown:icons$2.psLSYDown,psLSYUp:icons$2.psLSYUp,psLSY:icons$2.psLSY,psLS:icons$2.psLS,psMenu2:icons$2.psMenu2,psMenu:icons$2.psMenu,psR1:icons$2.psR1,psR2:icons$2.psR2,psR3ButtonArrowDown:icons$2.psR3ButtonArrowDown,psR3Button:icons$2.psR3Button,psRSXLeft:icons$2.psRSXLeft,psRSXRight:icons$2.psRSXRight,psRSX:icons$2.psRSX,psRSYDown:icons$2.psRSYDown,psRSYUp:icons$2.psRSYUp,psRSY:icons$2.psRSY,psRS:icons$2.psRS,psSquareOutline:icons$2.psSquareOutline,psSquare:icons$2.psSquare,psTrackpadNavigate:icons$2.psTrackpadNavigate,psTrackpadPressCenter:icons$2.psTrackpadPressCenter,psTrackpadPressLeft:icons$2.psTrackpadPressLeft,psTrackpadPressRight:icons$2.psTrackpadPressRight,psTrackpadSwipeDown:icons$2.psTrackpadSwipeDown,psTrackpadSwipeLeft:icons$2.psTrackpadSwipeLeft,psTrackpadSwipeRight:icons$2.psTrackpadSwipeRight,psTrackpadSwipeUp:icons$2.psTrackpadSwipeUp,psTriangleOutline:icons$2.psTriangleOutline,psTriangle:icons$2.psTriangle,xboxAOutline:icons$2.xboxAOutline,xboxBOutline:icons$2.xboxBOutline,xboxLSButtonArrowDown:icons$2.xboxLSButtonArrowDown,xboxRSButtonArrowDown:icons$2.xboxRSButtonArrowDown,xboxXAxisLeft:icons$2.xboxXAxisLeft,xboxXAxisRight:icons$2.xboxXAxisRight,xboxXOutline:icons$2.xboxXOutline,xboxXRotLeft:icons$2.xboxXRotLeft,xboxXRotRight:icons$2.xboxXRotRight,xboxYAxisDown:icons$2.xboxYAxisDown,xboxYAxisUp:icons$2.xboxYAxisUp,xboxYOutline:icons$2.xboxYOutline,xboxYRotDown:icons$2.xboxYRotDown,xboxYRotUp:icons$2.xboxYRotUp,psDLeftRight:icons$2.psDLeftRight,psDUpDown:icons$2.psDUpDown,xboxDLeftRight:icons$2.xboxDLeftRight,xboxDUpDown:icons$2.xboxDUpDown},controller:{gamepadOld:icons$2.gamepadOld,gamepad:icons$2.gamepad,noNameControllerButton:icons$2.noNameControllerButton,steeringWheelCommon:icons$2.steeringWheelCommon,steeringWheelSporty:icons$2.steeringWheelSporty,xboxA:icons$2.xboxA,xboxB:icons$2.xboxB,xboxDDefaultOutline:icons$2.xboxDDefaultOutline,xboxDDefaultSolid:icons$2.xboxDDefaultSolid,xboxDDown:icons$2.xboxDDown,xboxDLeft:icons$2.xboxDLeft,xboxDRight:icons$2.xboxDRight,xboxDUp:icons$2.xboxDUp,xboxLB:icons$2.xboxLB,xboxLSButton:icons$2.xboxLSButton,xboxLT:icons$2.xboxLT,xboxMenu:icons$2.xboxMenu,xboxRB:icons$2.xboxRB,xboxRSButton:icons$2.xboxRSButton,xboxRT:icons$2.xboxRT,xboxThumbL:icons$2.xboxThumbL,xboxThumbR:icons$2.xboxThumbR,xboxView:icons$2.xboxView,xboxXAxis:icons$2.xboxXAxis,xboxXRot:icons$2.xboxXRot,xboxX:icons$2.xboxX,xboxYAxis:icons$2.xboxYAxis,xboxYRot:icons$2.xboxYRot,xboxY:icons$2.xboxY,psCircleOutline:icons$2.psCircleOutline,psCircle:icons$2.psCircle,psCreate2:icons$2.psCreate2,psCreate:icons$2.psCreate,psCrossOutline:icons$2.psCrossOutline,psCross:icons$2.psCross,psDDefaultOutline:icons$2.psDDefaultOutline,psDDefaultSolid:icons$2.psDDefaultSolid,psDDown:icons$2.psDDown,psDLeft:icons$2.psDLeft,psDRight:icons$2.psDRight,psDUp:icons$2.psDUp,psL1:icons$2.psL1,psL2:icons$2.psL2,psL3ButtonArrowDown:icons$2.psL3ButtonArrowDown,psL3Button:icons$2.psL3Button,psLSXLeft:icons$2.psLSXLeft,psLSXRight:icons$2.psLSXRight,psLSX:icons$2.psLSX,psLSYDown:icons$2.psLSYDown,psLSYUp:icons$2.psLSYUp,psLSY:icons$2.psLSY,psLS:icons$2.psLS,psMenu2:icons$2.psMenu2,psMenu:icons$2.psMenu,psR1:icons$2.psR1,psR2:icons$2.psR2,psR3ButtonArrowDown:icons$2.psR3ButtonArrowDown,psR3Button:icons$2.psR3Button,psRSXLeft:icons$2.psRSXLeft,psRSXRight:icons$2.psRSXRight,psRSX:icons$2.psRSX,psRSYDown:icons$2.psRSYDown,psRSYUp:icons$2.psRSYUp,psRSY:icons$2.psRSY,psRS:icons$2.psRS,psSquareOutline:icons$2.psSquareOutline,psSquare:icons$2.psSquare,psTrackpadNavigate:icons$2.psTrackpadNavigate,psTrackpadPressCenter:icons$2.psTrackpadPressCenter,psTrackpadPressLeft:icons$2.psTrackpadPressLeft,psTrackpadPressRight:icons$2.psTrackpadPressRight,psTrackpadSwipeDown:icons$2.psTrackpadSwipeDown,psTrackpadSwipeLeft:icons$2.psTrackpadSwipeLeft,psTrackpadSwipeRight:icons$2.psTrackpadSwipeRight,psTrackpadSwipeUp:icons$2.psTrackpadSwipeUp,psTriangleOutline:icons$2.psTriangleOutline,psTriangle:icons$2.psTriangle,xboxAOutline:icons$2.xboxAOutline,xboxBOutline:icons$2.xboxBOutline,xboxLSButtonArrowDown:icons$2.xboxLSButtonArrowDown,xboxRSButtonArrowDown:icons$2.xboxRSButtonArrowDown,xboxXAxisLeft:icons$2.xboxXAxisLeft,xboxXAxisRight:icons$2.xboxXAxisRight,xboxXOutline:icons$2.xboxXOutline,xboxXRotLeft:icons$2.xboxXRotLeft,xboxXRotRight:icons$2.xboxXRotRight,xboxYAxisDown:icons$2.xboxYAxisDown,xboxYAxisUp:icons$2.xboxYAxisUp,xboxYOutline:icons$2.xboxYOutline,xboxYRotDown:icons$2.xboxYRotDown,xboxYRotUp:icons$2.xboxYRotUp,psDLeftRight:icons$2.psDLeftRight,psDUpDown:icons$2.psDUpDown,xboxDLeftRight:icons$2.xboxDLeftRight,xboxDUpDown:icons$2.xboxDUpDown},input:{gamepadOld:icons$2.gamepadOld,gamepad:icons$2.gamepad,keyboard:icons$2.keyboard,mouseLMB:icons$2.mouseLMB,mouseMMB:icons$2.mouseMMB,mouseRMB:icons$2.mouseRMB,mouseWheel:icons$2.mouseWheel,mouseXAxis:icons$2.mouseXAxis,mouseXYAxis:icons$2.mouseXYAxis,mouseYAxis:icons$2.mouseYAxis,mouse:icons$2.mouse,noNameControllerButton:icons$2.noNameControllerButton,palmCrossed:icons$2.palmCrossed,smartphone1:icons$2.smartphone1,smartphone2:icons$2.smartphone2,steeringWheelCommon:icons$2.steeringWheelCommon,steeringWheelSporty:icons$2.steeringWheelSporty,touch:icons$2.touch,xboxA:icons$2.xboxA,xboxB:icons$2.xboxB,xboxDDefaultOutline:icons$2.xboxDDefaultOutline,xboxDDefaultSolid:icons$2.xboxDDefaultSolid,xboxDDown:icons$2.xboxDDown,xboxDLeft:icons$2.xboxDLeft,xboxDRight:icons$2.xboxDRight,xboxDUp:icons$2.xboxDUp,xboxLB:icons$2.xboxLB,xboxLSButton:icons$2.xboxLSButton,xboxLT:icons$2.xboxLT,xboxMenu:icons$2.xboxMenu,xboxRB:icons$2.xboxRB,xboxRSButton:icons$2.xboxRSButton,xboxRT:icons$2.xboxRT,xboxThumbL:icons$2.xboxThumbL,xboxThumbR:icons$2.xboxThumbR,xboxView:icons$2.xboxView,xboxXAxis:icons$2.xboxXAxis,xboxXRot:icons$2.xboxXRot,xboxX:icons$2.xboxX,xboxYAxis:icons$2.xboxYAxis,xboxYRot:icons$2.xboxYRot,xboxY:icons$2.xboxY,psCircleOutline:icons$2.psCircleOutline,psCircle:icons$2.psCircle,psCreate2:icons$2.psCreate2,psCreate:icons$2.psCreate,psCrossOutline:icons$2.psCrossOutline,psCross:icons$2.psCross,psDDefaultOutline:icons$2.psDDefaultOutline,psDDefaultSolid:icons$2.psDDefaultSolid,psDDown:icons$2.psDDown,psDLeft:icons$2.psDLeft,psDRight:icons$2.psDRight,psDUp:icons$2.psDUp,psL1:icons$2.psL1,psL2:icons$2.psL2,psL3ButtonArrowDown:icons$2.psL3ButtonArrowDown,psL3Button:icons$2.psL3Button,psLSXLeft:icons$2.psLSXLeft,psLSXRight:icons$2.psLSXRight,psLSX:icons$2.psLSX,psLSYDown:icons$2.psLSYDown,psLSYUp:icons$2.psLSYUp,psLSY:icons$2.psLSY,psLS:icons$2.psLS,psMenu2:icons$2.psMenu2,psMenu:icons$2.psMenu,psR1:icons$2.psR1,psR2:icons$2.psR2,psR3ButtonArrowDown:icons$2.psR3ButtonArrowDown,psR3Button:icons$2.psR3Button,psRSXLeft:icons$2.psRSXLeft,psRSXRight:icons$2.psRSXRight,psRSX:icons$2.psRSX,psRSYDown:icons$2.psRSYDown,psRSYUp:icons$2.psRSYUp,psRSY:icons$2.psRSY,psRS:icons$2.psRS,psSquareOutline:icons$2.psSquareOutline,psSquare:icons$2.psSquare,psTrackpadNavigate:icons$2.psTrackpadNavigate,psTrackpadPressCenter:icons$2.psTrackpadPressCenter,psTrackpadPressLeft:icons$2.psTrackpadPressLeft,psTrackpadPressRight:icons$2.psTrackpadPressRight,psTrackpadSwipeDown:icons$2.psTrackpadSwipeDown,psTrackpadSwipeLeft:icons$2.psTrackpadSwipeLeft,psTrackpadSwipeRight:icons$2.psTrackpadSwipeRight,psTrackpadSwipeUp:icons$2.psTrackpadSwipeUp,psTriangleOutline:icons$2.psTriangleOutline,psTriangle:icons$2.psTriangle,xboxAOutline:icons$2.xboxAOutline,xboxBOutline:icons$2.xboxBOutline,xboxLSButtonArrowDown:icons$2.xboxLSButtonArrowDown,xboxRSButtonArrowDown:icons$2.xboxRSButtonArrowDown,xboxXAxisLeft:icons$2.xboxXAxisLeft,xboxXAxisRight:icons$2.xboxXAxisRight,xboxXOutline:icons$2.xboxXOutline,xboxXRotLeft:icons$2.xboxXRotLeft,xboxXRotRight:icons$2.xboxXRotRight,xboxYAxisDown:icons$2.xboxYAxisDown,xboxYAxisUp:icons$2.xboxYAxisUp,xboxYOutline:icons$2.xboxYOutline,xboxYRotDown:icons$2.xboxYRotDown,xboxYRotUp:icons$2.xboxYRotUp,psDLeftRight:icons$2.psDLeftRight,psDUpDown:icons$2.psDUpDown,xboxDLeftRight:icons$2.xboxDLeftRight,xboxDUpDown:icons$2.xboxDUpDown},gps:{GPSMark:icons$2.GPSMark,GPSSolid:icons$2.GPSSolid,location1:icons$2.location1,location2:icons$2.location2},position:{GPSMark:icons$2.GPSMark,GPSSolid:icons$2.GPSSolid,location1:icons$2.location1,location2:icons$2.location2},map:{GPSMark:icons$2.GPSMark,GPSSolid:icons$2.GPSSolid,location1:icons$2.location1,location2:icons$2.location2},keyboard:{keyboard:icons$2.keyboard,kbArrowsDown:icons$2.kbArrowsDown,kbArrowsLeftRight:icons$2.kbArrowsLeftRight,kbArrowsLeft:icons$2.kbArrowsLeft,kbArrowsOutline:icons$2.kbArrowsOutline,kbArrowsRight:icons$2.kbArrowsRight,kbArrowsSolid:icons$2.kbArrowsSolid,kbArrowsUpDown:icons$2.kbArrowsUpDown,kbArrowsUp:icons$2.kbArrowsUp},lights:{lightGarageG11:icons$2.lightGarageG11,lightGarageG12:icons$2.lightGarageG12,lightGarageG13:icons$2.lightGarageG13,lightGarageG14:icons$2.lightGarageG14,lightGarageG21:icons$2.lightGarageG21,lightGarageG22:icons$2.lightGarageG22,lightGarageG23:icons$2.lightGarageG23,lightGarageG24:icons$2.lightGarageG24,lightGarageG31:icons$2.lightGarageG31,lightGarageG32:icons$2.lightGarageG32,lightGarageG33:icons$2.lightGarageG33,lightGarageG34:icons$2.lightGarageG34},catalog:{listBig:icons$2.listBig,listSmall:icons$2.listSmall,tiles:icons$2.tiles},selector:{listBig:icons$2.listBig,listSmall:icons$2.listSmall,tiles:icons$2.tiles},view:{listBig:icons$2.listBig,listSmall:icons$2.listSmall,tiles:icons$2.tiles},math:{mathDivide:icons$2.mathDivide,mathGreaterOrEqualThan:icons$2.mathGreaterOrEqualThan,mathGreaterThan:icons$2.mathGreaterThan,mathLessOrEqualThan:icons$2.mathLessOrEqualThan,mathLessThan:icons$2.mathLessThan,mathMinus:icons$2.mathMinus,mathMultiply:icons$2.mathMultiply,mathPlus:icons$2.mathPlus,slashLeft:icons$2.slashLeft,slashRight:icons$2.slashRight},operands:{mathDivide:icons$2.mathDivide,mathGreaterOrEqualThan:icons$2.mathGreaterOrEqualThan,mathGreaterThan:icons$2.mathGreaterThan,mathLessOrEqualThan:icons$2.mathLessOrEqualThan,mathLessThan:icons$2.mathLessThan,mathMinus:icons$2.mathMinus,mathMultiply:icons$2.mathMultiply,mathPlus:icons$2.mathPlus,slashLeft:icons$2.slashLeft,slashRight:icons$2.slashRight},reward:{medal:icons$2.medal,voucherDiagonal1:icons$2.voucherDiagonal1,voucherDiagonal2:icons$2.voucherDiagonal2,voucherDiagonal3:icons$2.voucherDiagonal3,voucherHorizontal1:icons$2.voucherHorizontal1,voucherHorizontal2:icons$2.voucherHorizontal2,voucherHorizontal3:icons$2.voucherHorizontal3,medalEmpty:icons$2.medalEmpty,medalStar:icons$2.medalStar,badgeRoundEmpty:icons$2.badgeRoundEmpty,badgeRoundStar:icons$2.badgeRoundStar,badgeRound:icons$2.badgeRound,badge:icons$2.badge},achievment:{medal:icons$2.medal,medalEmpty:icons$2.medalEmpty,medalStar:icons$2.medalStar,badgeRoundEmpty:icons$2.badgeRoundEmpty,badgeRoundStar:icons$2.badgeRoundStar,badgeRound:icons$2.badgeRound,badge:icons$2.badge},mesh:{mesh4Cells:icons$2.mesh4Cells,mesh9Cells:icons$2.mesh9Cells},beams:{mesh4Cells:icons$2.mesh4Cells,mesh9Cells:icons$2.mesh9Cells},nodes:{mesh4Cells:icons$2.mesh4Cells,mesh9Cells:icons$2.mesh9Cells},surface:{mesh4Cells:icons$2.mesh4Cells,mesh9Cells:icons$2.mesh9Cells,bridge:icons$2.bridge,bump:icons$2.bump,bumps:icons$2.bumps,caution:icons$2.caution,crest:icons$2.crest,doubleCaution:icons$2.doubleCaution,finish:icons$2.finish,jumpOverBump:icons$2.jumpOverBump,narrows:icons$2.narrows,pothole:icons$2.pothole,turn1:icons$2.turn1,turn2:icons$2.turn2,turn3:icons$2.turn3,turn4:icons$2.turn4,turn5:icons$2.turn5,turn6:icons$2.turn6,turnHp:icons$2.turnHp,turnSq:icons$2.turnSq,water:icons$2.water,tripleCaution:icons$2.tripleCaution},mirror:{mirrorInteriorMiddle:icons$2.mirrorInteriorMiddle,mirrorLeftBigBottomWideAngle:icons$2.mirrorLeftBigBottomWideAngle,mirrorLeftBigTop:icons$2.mirrorLeftBigTop,mirrorLeftBig:icons$2.mirrorLeftBig,mirrorLeftBonnet:icons$2.mirrorLeftBonnet,mirrorLeftDefault:icons$2.mirrorLeftDefault,mirrorRightBigBottomWideAngle:icons$2.mirrorRightBigBottomWideAngle,mirrorRightBigTop:icons$2.mirrorRightBigTop,mirrorRightBig:icons$2.mirrorRightBig,mirrorRightBonnet:icons$2.mirrorRightBonnet,mirrorRightDefault:icons$2.mirrorRightDefault,mirrorRoundWideAngle:icons$2.mirrorRoundWideAngle,mirrorTopWideAngle:icons$2.mirrorTopWideAngle},rearview:{mirrorInteriorMiddle:icons$2.mirrorInteriorMiddle,mirrorLeftBigBottomWideAngle:icons$2.mirrorLeftBigBottomWideAngle,mirrorLeftBigTop:icons$2.mirrorLeftBigTop,mirrorLeftBig:icons$2.mirrorLeftBig,mirrorLeftBonnet:icons$2.mirrorLeftBonnet,mirrorLeftDefault:icons$2.mirrorLeftDefault,mirrorRightBigBottomWideAngle:icons$2.mirrorRightBigBottomWideAngle,mirrorRightBigTop:icons$2.mirrorRightBigTop,mirrorRightBig:icons$2.mirrorRightBig,mirrorRightBonnet:icons$2.mirrorRightBonnet,mirrorRightDefault:icons$2.mirrorRightDefault,mirrorRoundWideAngle:icons$2.mirrorRoundWideAngle,mirrorTopWideAngle:icons$2.mirrorTopWideAngle},mouse:{mouseLMB:icons$2.mouseLMB,mouseMMB:icons$2.mouseMMB,mouseRMB:icons$2.mouseRMB,mouseWheel:icons$2.mouseWheel,mouseXAxis:icons$2.mouseXAxis,mouseXYAxis:icons$2.mouseXYAxis,mouseYAxis:icons$2.mouseYAxis,mouse:icons$2.mouse},path:{nodeAddFirst01:icons$2.nodeAddFirst01,nodeAddFirst02:icons$2.nodeAddFirst02,nodeAddLast02:icons$2.nodeAddLast02,nodeAddMiddle01:icons$2.nodeAddMiddle01,nodeAddMiddle02:icons$2.nodeAddMiddle02,nodeAdd:icons$2.nodeAdd,nodeLast01:icons$2.nodeLast01,nodeRemove:icons$2.nodeRemove,locationDestination:icons$2.locationDestination,locationSource:icons$2.locationSource},node:{nodeAddFirst01:icons$2.nodeAddFirst01,nodeAddFirst02:icons$2.nodeAddFirst02,nodeAddLast02:icons$2.nodeAddLast02,nodeAddMiddle01:icons$2.nodeAddMiddle01,nodeAddMiddle02:icons$2.nodeAddMiddle02,nodeAdd:icons$2.nodeAdd,nodeLast01:icons$2.nodeLast01,nodeRemove:icons$2.nodeRemove,locationDestination:icons$2.locationDestination,locationSource:icons$2.locationSource},touch:{palmCrossed:icons$2.palmCrossed,smartphone1:icons$2.smartphone1,smartphone2:icons$2.smartphone2,touch:icons$2.touch},route:{routeAdd:icons$2.routeAdd,routeComplex:icons$2.routeComplex,routeSimple:icons$2.routeSimple,trafficCone:icons$2.trafficCone,locationDestination:icons$2.locationDestination,locationSource:icons$2.locationSource,routeSimpleFlag:icons$2.routeSimpleFlag},traffic:{routeAdd:icons$2.routeAdd,routeComplex:icons$2.routeComplex,routeSimple:icons$2.routeSimple,trafficCone:icons$2.trafficCone,trafficLight:icons$2.trafficLight,pedestrianRunning:icons$2.pedestrianRunning,pedestrianStanding:icons$2.pedestrianStanding,routeSimpleFlag:icons$2.routeSimpleFlag},trailer:{semiTrailer:icons$2.semiTrailer,semiTruck:icons$2.semiTruck,smallTrailer:icons$2.smallTrailer,tankerTrailer:icons$2.tankerTrailer},steering:{steeringWheelCommon:icons$2.steeringWheelCommon,steeringWheelSporty:icons$2.steeringWheelSporty},time:{stopwatchArrows01:icons$2.stopwatchArrows01,stopwatchArrows02:icons$2.stopwatchArrows02,stopwatchSectionOutlinedEnd:icons$2.stopwatchSectionOutlinedEnd,stopwatchSectionOutlinedStart:icons$2.stopwatchSectionOutlinedStart,stopwatchSectionSolidEnd:icons$2.stopwatchSectionSolidEnd,stopwatchSectionSolidStart:icons$2.stopwatchSectionSolidStart,timer:icons$2.timer},fast:{stopwatchArrows01:icons$2.stopwatchArrows01,stopwatchArrows02:icons$2.stopwatchArrows02,stopwatchSectionOutlinedEnd:icons$2.stopwatchSectionOutlinedEnd,stopwatchSectionOutlinedStart:icons$2.stopwatchSectionOutlinedStart,stopwatchSectionSolidEnd:icons$2.stopwatchSectionSolidEnd,stopwatchSectionSolidStart:icons$2.stopwatchSectionSolidStart,timer:icons$2.timer},emergency:{strobeLights:icons$2.strobeLights,wigwags:icons$2.wigwags},circuit:{switchBlock:icons$2.switchBlock,switchOutline:icons$2.switchOutline},electronics:{switchBlock:icons$2.switchBlock,switchOutline:icons$2.switchOutline},switch:{switchBlock:icons$2.switchBlock,switchOutline:icons$2.switchOutline},tank:{tankerTrailer:icons$2.tankerTrailer},tanker:{tankerTrailer:icons$2.tankerTrailer},taxi:{taxiCar1:icons$2.taxiCar1,taxiCar3:icons$2.taxiCar3,taxiCarT:icons$2.taxiCarT,taxiCheckerLamp:icons$2.taxiCheckerLamp},tire:{tireDirection3Fourth2:icons$2.tireDirection3Fourth2,tireDirection3Fourth3:icons$2.tireDirection3Fourth3,tireDirectionFront2:icons$2.tireDirectionFront2,tireDirectionSide2:icons$2.tireDirectionSide2,tireDirectionTop2:icons$2.tireDirectionTop2,tire3FourthCoins:icons$2.tire3FourthCoins,tire3Fourth:icons$2.tire3Fourth},currency:{voucherDiagonal1:icons$2.voucherDiagonal1,voucherDiagonal2:icons$2.voucherDiagonal2,voucherDiagonal3:icons$2.voucherDiagonal3,voucherHorizontal1:icons$2.voucherHorizontal1,voucherHorizontal2:icons$2.voucherHorizontal2,voucherHorizontal3:icons$2.voucherHorizontal3,beamCurrencyOutlineLarge:icons$2.beamCurrencyOutlineLarge},extra:{AIL:icons$2.AIL,automaticTransmissionL:icons$2.automaticTransmissionL,chargeLL:icons$2.chargeLL,clutchL:icons$2.clutchL,couplerL:icons$2.couplerL,engineL:icons$2.engineL,multiseatL:icons$2.multiseatL,POITimeL:icons$2.POITimeL,replayL:icons$2.replayL,roadblockL:icons$2.roadblockL,rotationL:icons$2.rotationL,sensorsL:icons$2.sensorsL,temperatureL:icons$2.temperatureL,tuningL:icons$2.tuningL,turbineL:icons$2.turbineL},web:{arrowLeftOutline:icons$2.arrowLeftOutline,arrowRightOutline:icons$2.arrowRightOutline,beamsNodesMessageOutline:icons$2.beamsNodesMessageOutline,beamsNodesOutline:icons$2.beamsNodesOutline,beamsNodesPlugOutline:icons$2.beamsNodesPlugOutline,BNGEcosystemOutline:icons$2.BNGEcosystemOutline,carFrontRouteOutline:icons$2.carFrontRouteOutline,carSensorsOutline:icons$2.carSensorsOutline,carSideRouteOutline:icons$2.carSideRouteOutline,cityOutline:icons$2.cityOutline,dialogOutline:icons$2.dialogOutline,documentSmileOutline:icons$2.documentSmileOutline,drivetrainOutline:icons$2.drivetrainOutline,electronicSchemeOutline:icons$2.electronicSchemeOutline,engineOutline:icons$2.engineOutline,gearTuningOutline:icons$2.gearTuningOutline,giftBoxOutline:icons$2.giftBoxOutline,lidarOutline:icons$2.lidarOutline,medalStarOutline:icons$2.medalStarOutline,megaphoneOutline:icons$2.megaphoneOutline,peopleOutline:icons$2.peopleOutline,personOutline:icons$2.personOutline,physicsOutline:icons$2.physicsOutline,playChainOutline:icons$2.playChainOutline,proximitySensorsOutline:icons$2.proximitySensorsOutline,qualityBadgeStarOutline:icons$2.qualityBadgeStarOutline,qualityBadgeVOutline:icons$2.qualityBadgeVOutline,simRigOutline:icons$2.simRigOutline,suspensionOutline:icons$2.suspensionOutline,teamOutline:icons$2.teamOutline,techLightBulbOutline01:icons$2.techLightBulbOutline01,techLightBulbOutline02:icons$2.techLightBulbOutline02,timeUnlockOutline:icons$2.timeUnlockOutline,timedLockOutline:icons$2.timedLockOutline,trafficOutline:icons$2.trafficOutline,voucherOutline:icons$2.voucherOutline,wheelBeamsNodesOutline:icons$2.wheelBeamsNodesOutline,wheelOutline:icons$2.wheelOutline},secondary:{arrowLeftOutline:icons$2.arrowLeftOutline,arrowRightOutline:icons$2.arrowRightOutline,beamsNodesMessageOutline:icons$2.beamsNodesMessageOutline,beamsNodesOutline:icons$2.beamsNodesOutline,beamsNodesPlugOutline:icons$2.beamsNodesPlugOutline,BNGEcosystemOutline:icons$2.BNGEcosystemOutline,carFrontRouteOutline:icons$2.carFrontRouteOutline,carSensorsOutline:icons$2.carSensorsOutline,carSideRouteOutline:icons$2.carSideRouteOutline,cityOutline:icons$2.cityOutline,dialogOutline:icons$2.dialogOutline,documentSmileOutline:icons$2.documentSmileOutline,drivetrainOutline:icons$2.drivetrainOutline,electronicSchemeOutline:icons$2.electronicSchemeOutline,engineOutline:icons$2.engineOutline,gearTuningOutline:icons$2.gearTuningOutline,giftBoxOutline:icons$2.giftBoxOutline,lidarOutline:icons$2.lidarOutline,medalStarOutline:icons$2.medalStarOutline,megaphoneOutline:icons$2.megaphoneOutline,peopleOutline:icons$2.peopleOutline,personOutline:icons$2.personOutline,physicsOutline:icons$2.physicsOutline,playChainOutline:icons$2.playChainOutline,proximitySensorsOutline:icons$2.proximitySensorsOutline,qualityBadgeStarOutline:icons$2.qualityBadgeStarOutline,qualityBadgeVOutline:icons$2.qualityBadgeVOutline,simRigOutline:icons$2.simRigOutline,suspensionOutline:icons$2.suspensionOutline,teamOutline:icons$2.teamOutline,techLightBulbOutline01:icons$2.techLightBulbOutline01,techLightBulbOutline02:icons$2.techLightBulbOutline02,timeUnlockOutline:icons$2.timeUnlockOutline,timedLockOutline:icons$2.timedLockOutline,trafficOutline:icons$2.trafficOutline,voucherOutline:icons$2.voucherOutline,wheelBeamsNodesOutline:icons$2.wheelBeamsNodesOutline,wheelOutline:icons$2.wheelOutline},hazard:{danger:icons$2.danger,fireDiamond:icons$2.fireDiamond,test:icons$2.test},drop:{droplet:icons$2.droplet},liquid:{droplet:icons$2.droplet},nfpa704:{fireDiamond:icons$2.fireDiamond},"dry cargo":{rocks:icons$2.rocks},dry:{rocks:icons$2.rocks},editor:{scale:icons$2.scale},marker:{arrowsUp:icons$2.arrowsUp,bigDot:icons$2.bigDot,connectorBold:icons$2.connectorBold,cornerTopRight:icons$2.cornerTopRight,plusBold:icons$2.plusBold,puzzlePieceBold:icons$2.puzzlePieceBold},ribbon:{arrowsUp:icons$2.arrowsUp,bigDot:icons$2.bigDot,connectorBold:icons$2.connectorBold,cornerTopRight:icons$2.cornerTopRight,plusBold:icons$2.plusBold,puzzlePieceBold:icons$2.puzzlePieceBold},"content-props":{arrowsUp:icons$2.arrowsUp,bigDot:icons$2.bigDot,connectorBold:icons$2.connectorBold,cornerTopRight:icons$2.cornerTopRight,plusBold:icons$2.plusBold,puzzlePieceBold:icons$2.puzzlePieceBold},location:{locationDestination:icons$2.locationDestination,locationSource:icons$2.locationSource},shop:{shoppingCart:icons$2.shoppingCart},purchase:{shoppingCart:icons$2.shoppingCart},bus:{busTilted:icons$2.busTilted},destruction:{explosion:icons$2.explosion,fireExtinguisher:icons$2.fireExtinguisher,fire:icons$2.fire},"turn signals":{twoArrowsHorizontal:icons$2.twoArrowsHorizontal,twoArrowsVertical:icons$2.twoArrowsVertical},rally:{bridge:icons$2.bridge,bump:icons$2.bump,bumps:icons$2.bumps,caution:icons$2.caution,crest:icons$2.crest,doubleCaution:icons$2.doubleCaution,finish:icons$2.finish,jumpOverBump:icons$2.jumpOverBump,narrows:icons$2.narrows,pothole:icons$2.pothole,turn1:icons$2.turn1,turn2:icons$2.turn2,turn3:icons$2.turn3,turn4:icons$2.turn4,turn5:icons$2.turn5,turn6:icons$2.turn6,turnHp:icons$2.turnHp,turnSq:icons$2.turnSq,water:icons$2.water,rallyHelmet3To4:icons$2.rallyHelmet3To4,rallyHelmet:icons$2.rallyHelmet,tripleCaution:icons$2.tripleCaution},"pace notes":{bridge:icons$2.bridge,bump:icons$2.bump,bumps:icons$2.bumps,caution:icons$2.caution,crest:icons$2.crest,doubleCaution:icons$2.doubleCaution,finish:icons$2.finish,jumpOverBump:icons$2.jumpOverBump,narrows:icons$2.narrows,pothole:icons$2.pothole,turn1:icons$2.turn1,turn2:icons$2.turn2,turn3:icons$2.turn3,turn4:icons$2.turn4,turn5:icons$2.turn5,turn6:icons$2.turn6,turnHp:icons$2.turnHp,turnSq:icons$2.turnSq,water:icons$2.water,tripleCaution:icons$2.tripleCaution},directions:{bridge:icons$2.bridge,bump:icons$2.bump,bumps:icons$2.bumps,caution:icons$2.caution,crest:icons$2.crest,doubleCaution:icons$2.doubleCaution,finish:icons$2.finish,jumpOverBump:icons$2.jumpOverBump,narrows:icons$2.narrows,pothole:icons$2.pothole,turn1:icons$2.turn1,turn2:icons$2.turn2,turn3:icons$2.turn3,turn4:icons$2.turn4,turn5:icons$2.turn5,turn6:icons$2.turn6,turnHp:icons$2.turnHp,turnSq:icons$2.turnSq,water:icons$2.water,tripleCaution:icons$2.tripleCaution},"do not cut":{circleSlashed:icons$2.circleSlashed,scissorsSlashed:icons$2.scissorsSlashed},"no entry":{circleSlashed:icons$2.circleSlashed},cut:{scissors:icons$2.scissors},car:{airPuffRight1:icons$2.airPuffRight1,octagonBrick:icons$2.octagonBrick,octagon:icons$2.octagon,tireAirPuff:icons$2.tireAirPuff,tireDeflated:icons$2.tireDeflated},select:{carsChange:icons$2.carsChange,carsWrench:icons$2.carsWrench},physics:{forceFieldPull1:icons$2.forceFieldPull1,forceFieldPull2:icons$2.forceFieldPull2,forceFieldPull3:icons$2.forceFieldPull3,forceFieldPush1:icons$2.forceFieldPush1,forceFieldPush2:icons$2.forceFieldPush2,forceFieldPush3:icons$2.forceFieldPush3,pushUp:icons$2.pushUp,pushBackward:icons$2.pushBackward,pushDown:icons$2.pushDown,pushForward:icons$2.pushForward},field:{forceFieldPull1:icons$2.forceFieldPull1,forceFieldPull2:icons$2.forceFieldPull2,forceFieldPull3:icons$2.forceFieldPull3,forceFieldPush1:icons$2.forceFieldPush1,forceFieldPush2:icons$2.forceFieldPush2,forceFieldPush3:icons$2.forceFieldPush3},force:{forceFieldPull1:icons$2.forceFieldPull1,forceFieldPull2:icons$2.forceFieldPull2,forceFieldPull3:icons$2.forceFieldPull3,forceFieldPush1:icons$2.forceFieldPush1,forceFieldPush2:icons$2.forceFieldPush2,forceFieldPush3:icons$2.forceFieldPush3,pushUp:icons$2.pushUp,pushBackward:icons$2.pushBackward,pushDown:icons$2.pushDown,pushForward:icons$2.pushForward},"garage number":{garageNumber1:icons$2.garageNumber1,garageNumber2:icons$2.garageNumber2,garageNumber3:icons$2.garageNumber3,garageNumber4:icons$2.garageNumber4,garageNumber5:icons$2.garageNumber5,garageNumber6:icons$2.garageNumber6,garageNumber7:icons$2.garageNumber7,garageNumber8:icons$2.garageNumber8,garageNumber9:icons$2.garageNumber9},stop:{square:icons$2.square},roads:{trafficLight:icons$2.trafficLight},sign:{pedestrianRunning:icons$2.pedestrianRunning,pedestrianStanding:icons$2.pedestrianStanding},pedestrian:{pedestrianRunning:icons$2.pedestrianRunning,pedestrianStanding:icons$2.pedestrianStanding},actions:{seatArrowIn:icons$2.seatArrowIn,seatArrowOut:icons$2.seatArrowOut,seatVArrowIn:icons$2.seatVArrowIn,seatVArrowOut:icons$2.seatVArrowOut,vehicleArrowIn:icons$2.vehicleArrowIn,vehicleArrowOut:icons$2.vehicleArrowOut,leverFrontOperate:icons$2.leverFrontOperate,leverSideDown:icons$2.leverSideDown,leverSideOperate:icons$2.leverSideOperate,leverSideUp:icons$2.leverSideUp,seatArrowInLeft:icons$2.seatArrowInLeft,seatArrowOutLeft:icons$2.seatArrowOutLeft,seatVArrowInLeft:icons$2.seatVArrowInLeft,seatVArrowOutLeft:icons$2.seatVArrowOutLeft},outline:{beamCurrencyOutlineLarge:icons$2.beamCurrencyOutlineLarge},scenario:{flagOutlineLarge:icons$2.flagOutlineLarge},house:{houseWrenchRoof:icons$2.houseWrenchRoof,houseWrench:icons$2.houseWrench,house:icons$2.house},helmet:{rallyHelmet3To4:icons$2.rallyHelmet3To4,rallyHelmet:icons$2.rallyHelmet},racing:{rallyHelmet3To4:icons$2.rallyHelmet3To4,rallyHelmet:icons$2.rallyHelmet},"game mode":{rallyHelmet3To4:icons$2.rallyHelmet3To4,rallyHelmet:icons$2.rallyHelmet},offline:{globeSimpleNotSign:icons$2.globeSimpleNotSign},online:{globeSimplified:icons$2.globeSimplified},material:{cableSection:icons$2.cableSection,strapHook:icons$2.strapHook,strapRatchet:icons$2.strapRatchet},beam:{cableSection:icons$2.cableSection},strap:{cableSection:icons$2.cableSection,strapHook:icons$2.strapHook,strapRatchet:icons$2.strapRatchet},controls:{kbArrowsDown:icons$2.kbArrowsDown,kbArrowsLeftRight:icons$2.kbArrowsLeftRight,kbArrowsLeft:icons$2.kbArrowsLeft,kbArrowsOutline:icons$2.kbArrowsOutline,kbArrowsRight:icons$2.kbArrowsRight,kbArrowsSolid:icons$2.kbArrowsSolid,kbArrowsUpDown:icons$2.kbArrowsUpDown,kbArrowsUp:icons$2.kbArrowsUp},equipment:{auxUpDown:icons$2.auxUpDown,bucketArmUpDown:icons$2.bucketArmUpDown,bucketTilt:icons$2.bucketTilt,bucketArmDown:icons$2.bucketArmDown,bucketArmLevel:icons$2.bucketArmLevel,bucketArmUp:icons$2.bucketArmUp,bucketTiltDown:icons$2.bucketTiltDown,bucketTiltLevel:icons$2.bucketTiltLevel,bucketTiltUp:icons$2.bucketTiltUp,dumpBedDown:icons$2.dumpBedDown,dumpBedUpDown:icons$2.dumpBedUpDown,dumpBedUp:icons$2.dumpBedUp}}),getIconsWithTags=(...tagsToFind)=>Object.fromEntries(Object.entries(icons$2).filter(([name,{tags}])=>{for(let t of tagsToFind)if(!tags.includes(t))return!1;return!0})),icons=Object.freeze({...icons$2,_empty:{...icons$2.minus,invisible:!0}}),_sfc_main$369={__name:`bngIcon`,props:{type:{type:[String,Object],default:``},fallbackType:{type:String,default:`placeholder`},color:{type:String,default:`#fff`},asImage:{},image:String,externalImage:String},setup(__props){useCssVars(_ctx=>({v9bdaf084:__props.color}));let props=__props,hasImageSource=computed(()=>!!props.image||!!props.externalImage),imageSrcKey=computed(()=>props.image||props.externalImage||``),errorSrcKey=ref(``),isCurrentSrcErrored=computed(()=>!!imageSrcKey.value&&errorSrcKey.value===imageSrcKey.value),isGlyph=computed(()=>!!(!hasImageSource.value||isCurrentSrcErrored.value)),icon=computed(()=>{let res;switch(typeof props.type){case`object`:props.type.glyph&&(res=props.type);break;case`string`:props.type in icons&&(res=icons[props.type]);break}return res}),displayIcon=computed(()=>{let fallback=typeof props.fallbackType==`string`&&props.fallbackType in icons?icons[props.fallbackType]:icons.placeholder;return isCurrentSrcErrored.value||!icon.value&&!hasImageSource.value?fallback:icon.value}),iconGlyph=computed(()=>displayIcon.value?displayIcon.value.glyph:icons.placeholder.glyph),OFF_VALUES=[null,void 0,!1,`false`,0,`0`],asImage=computed(()=>OFF_VALUES.includes(props.asImage)?!1:props.asImage||!0),imageProps=computed(()=>{let res={bgColor:props.color,mask:[`mask`,`span`].includes(asImage.value)};return icon.value||(res.bgColor=`#f00`),asImage.value||(props.image?res.src=props.image:props.externalImage&&(res.externalSrc=props.externalImage)),res});function onImageError(){errorSrcKey.value=imageSrcKey.value}return(_ctx,_cache)=>isGlyph.value?(openBlock(),createElementBlock(`span`,{key:0,class:normalizeClass([`icon-base`,{"icon-not-found":displayIcon.value===unref(icons).placeholder,"icon-invisible":displayIcon.value&&displayIcon.value.invisible}])},toDisplayString(iconGlyph.value),3)):(openBlock(),createBlock(unref(bngImageAsset_default),mergeProps({key:1,class:`icon-img`},imageProps.value,{onError:onImageError}),null,16))}},bngIcon_default=__plugin_vue_export_helper_default(_sfc_main$369,[[`__scopeId`,`data-v-978d1732`]]),markerValidate=name=>name.endsWith(`Back`)&&Object.keys(iconsBySize[56]).includes(name.replace(/Back$/,`Front`))||name.endsWith(`Front`)&&Object.keys(iconsBySize[56]).includes(name.replace(/Front$/,`Back`)),markersList=Object.keys(iconsBySize[56]).filter(markerValidate).map(name=>name.replace(/Back$|Front$/,``)).sort((a$1,b)=>a$1.toLowerCase().localeCompare(b.toLowerCase())).reduce((res,name)=>res.includes(name)?res:[...res,name],[]);const markers=Object.fromEntries(markersList.map(i=>[i,i])),MARKER_POINTS={up:`up`,down:`down`,left:`left`,right:`right`};var _sfc_main$368={__name:`bngIconMarker`,props:{marker:{type:String,default:`circlePin`,validator:val=>!!markers[val]},type:[String,Object],color:[String,Array],point:{type:String,default:`down`,validator:val=>MARKER_POINTS[val]}},setup(__props){let props=__props,icon=computed(()=>({back:iconsBySize[56][props.marker+`Back`],front:iconsBySize[56][props.marker+`Front`]})),iconColour=computed(()=>({back:(Array.isArray(props.color)?props.color[0]:props.color)||`#fff`,front:(Array.isArray(props.color)?props.color[1]:null)||`#000`,icon:(Array.isArray(props.color)?props.color[2]||props.color[0]:props.color)||`#fff`}));return(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,{class:normalizeClass([`icon-marker`,`icon-point-${__props.point}`,`icon-type-${__props.marker}`])},[createVNode(unref(bngIcon_default),{class:`icon-back`,type:icon.value.back,color:iconColour.value.back},null,8,[`type`,`color`]),createVNode(unref(bngIcon_default),{class:`icon-front`,type:icon.value.front,color:iconColour.value.front},null,8,[`type`,`color`]),__props.type?(openBlock(),createBlock(unref(bngIcon_default),{key:0,class:`icon-inner`,type:__props.type,color:iconColour.value.icon},null,8,[`type`,`color`])):createCommentVNode(``,!0)],2))}},bngIconMarker_default=__plugin_vue_export_helper_default(_sfc_main$368,[[`__scopeId`,`data-v-1089accc`]]),_hoisted_1$322=[`src`],_sfc_main$367=Object.assign({inheritAttrs:!1},{__name:`bngImage`,props:{src:String,observe:Boolean},setup(__props){let props=__props,attrs=useAttrs(),observe=computed(()=>props.observe?`observe`:void 0),imgAttrs=computed(()=>showCanvas.value?{}:attrs),cvsAttrs=computed(()=>showCanvas.value?attrs:{}),elImg=ref(null),elCanvas=ref(null),showCanvas=ref(!1),imgSrc=ref(emptyImage),parentDataAttrs={};function setImage(elm,url,bmp){bmp?(showCanvas.value=!0,imgSrc.value=emptyImage,elCanvas.value.width=bmp.width,elCanvas.value.height=bmp.height,elCanvas.value.getContext(`2d`).drawImage(bmp,0,0),Object.entries(parentDataAttrs).forEach(([attr,value])=>{elCanvas.value.setAttribute(attr,value)})):(showCanvas.value=!1,imgSrc.value=url||`data:image/svg+xml,`)}return watch(()=>props.src,()=>{elImg.value&&(showCanvas.value=!1,imgSrc.value=emptyImage)}),watch(elImg,elm=>{if(elm){parentDataAttrs={};for(let attr of elm.parentElement.getAttributeNames())attr.startsWith(`data-v-`)&&(parentDataAttrs[attr]=elm.parentElement.getAttribute(attr));Object.entries(parentDataAttrs).forEach(([attr,value])=>{elm.setAttribute(attr,value),elCanvas.value&&elCanvas.value.setAttribute(attr,value)}),elm.__setImage=setImage}},{immediate:!0}),(_ctx,_cache)=>(openBlock(),createElementBlock(Fragment,null,[withDirectives(createBaseVNode(`img`,mergeProps({ref_key:`elImg`,ref:elImg},imgAttrs.value,{src:imgSrc.value,alt:``}),null,16,_hoisted_1$322),[[vShow,!showCanvas.value],[unref(BngLazyImage_default),{url:__props.src,callback:setImage},observe.value]]),withDirectives(createBaseVNode(`canvas`,mergeProps({ref_key:`elCanvas`,ref:elCanvas},cvsAttrs.value),null,16),[[vShow,showCanvas.value]])],64))}}),bngImage_default=_sfc_main$367,_hoisted_1$321=[`src`],_sfc_main$366={__name:`bngImageAsset`,props:{src:String,externalSrc:String,span:Boolean,mask:Boolean,bgColor:{type:String,default:`transparent`}},emits:[`error`,`load`],setup(__props,{emit:__emit}){useCssVars(_ctx=>({v0d0b2c1c:__props.bgColor}));let emit$1=__emit,props=__props,assetURL=computed(()=>props.src?getAssetURL(props.src):props.externalSrc);return(_ctx,_cache)=>__props.span||__props.mask?(openBlock(),createElementBlock(`span`,{key:0,class:`bng-image-asset`,style:normalizeStyle({[__props.mask?`maskImage`:`backgroundImage`]:`url(${assetURL.value})`})},[renderSlot(_ctx.$slots,`default`,{},void 0,!0)],4)):(openBlock(),createElementBlock(`img`,{key:1,class:`bng-image-asset`,src:assetURL.value,alt:``,onError:_cache[0]||=$event=>emit$1(`error`,$event),onLoad:_cache[1]||=$event=>emit$1(`load`,$event)},null,40,_hoisted_1$321))}},bngImageAsset_default=__plugin_vue_export_helper_default(_sfc_main$366,[[`__scopeId`,`data-v-27bf5bcc`]]),_hoisted_1$320={class:`bng-image-carousel`},_sfc_main$365={__name:`bngImageCarousel`,props:{images:{type:Array,required:!0},external:Boolean,current:[String,Number],transition:Boolean,transitionType:{type:String,default:`fade`},transitionTime:{type:Number,default:3e3},loop:{type:Boolean,default:!0},showNav:{type:Boolean,default:!0},parent:Object},setup(__props,{expose:__expose}){let props=__props,carousel=ref();__expose({carousel});let imageAssets=computed(()=>props.external?props.images.map(x=>`/`+x):props.images.map(getAssetURL)),carouselSettings=computed(()=>props.parent&&props.parent.carousel!==carousel?{parent:props.parent.carousel,transition:!1,transitionType:props.transitionType,loop:!1,transitionTime:props.transitionTime}:{current:props.current,transition:props.transition,transitionType:props.transitionType,transitionTime:props.transitionTime,loop:props.loop,showNav:props.showNav});return(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$320,[createVNode(unref(carousel_default),mergeProps({items:imageAssets.value,ref_key:`carousel`,ref:carousel},carouselSettings.value),{item:withCtx(({item})=>[createBaseVNode(`div`,{class:`image-slide`,style:normalizeStyle({"background-image":`url(${item})`})},null,4)]),_:1},16,[`items`])]))}},bngImageCarousel_default=__plugin_vue_export_helper_default(_sfc_main$365,[[`__scopeId`,`data-v-6b0c2d6b`]]),_hoisted_1$319=[`src`],_sfc_main$364={__name:`bngImageTile`,props:{oldIcon:String,src:String,externalSrc:String,label:String,image:String,externalImage:String,icon:[Object,String],ratio:{type:String,default:`4:3`}},setup(__props){let props=__props,slots=useSlots(),assetURL=computed(()=>props.externalSrc?props.externalSrc:getAssetURL(props.src));return(_ctx,_cache)=>(openBlock(),createBlock(unref(bngTile_default),{label:__props.label,backgroundImage:__props.image,backgroundExternalImage:__props.externalImage,ratio:__props.ratio},createSlots({default:withCtx(()=>[__props.oldIcon?(openBlock(),createBlock(unref(bngOldIcon_default),{key:0,class:`icon`,type:__props.oldIcon,span:``},null,8,[`type`])):createCommentVNode(``,!0),__props.icon?(openBlock(),createBlock(unref(bngIcon_default),{key:1,class:`glyph`,type:__props.icon},null,8,[`type`])):__props.src||__props.externalSrc?(openBlock(),createElementBlock(`img`,{key:2,class:`icon`,src:assetURL.value},null,8,_hoisted_1$319)):createCommentVNode(``,!0)]),_:2},[unref(slots).default?{name:`label`,fn:withCtx(()=>[renderSlot(_ctx.$slots,`default`,{},void 0,!0)]),key:`0`}:void 0]),1032,[`label`,`backgroundImage`,`backgroundExternalImage`,`ratio`]))}},bngImageTile_default=__plugin_vue_export_helper_default(_sfc_main$364,[[`__scopeId`,`data-v-d74a4ec4`]]),UNIQUE_CLEAN_VALUE=Symbol(`Unique 'clean' value from Dirty service code`);function useDirty(valueRef,emitter=void 0,setCallback=void 0){if(!valueRef)throw Error(`valueRef must be specified`);let hasInitValue=!1,initialValue=ref();function init$3(val){let type=typeof val;type===`undefined`||type===`number`&&isNaN(val)||(hasInitValue=!0,initialValue.value=val)}if(init$3(valueRef.value),!hasInitValue){let unwatch=watch(valueRef,newVal=>{init$3(newVal),hasInitValue&&unwatch()});onUnmounted(()=>!hasInitValue&&unwatch())}let dirty=computed(()=>{let isDirty$1=valueRef.value!==initialValue.value;return isDirty$1&&hasInitValue&&emitter&&emitter(`dirtied`,valueRef.value,initialValue.value),isDirty$1}),setDirty=state=>{let oldVal=initialValue.value,newVal=state?UNIQUE_CLEAN_VALUE:valueRef.value;initialValue.value=newVal,typeof setCallback==`function`&&setCallback(newVal,oldVal)};return{dirty,currentCleanValue:computed(()=>initialValue.value),setCleanValue:val=>initialValue.value=val,resetValue:()=>valueRef.value=initialValue.value,setDirty,markClean:()=>setDirty(!1)}}var _hoisted_1$318={class:`bng-input-wrapper`},_hoisted_2$259={class:`icons-input-wrapper`},_hoisted_3$226={class:`bng-input-container`},_hoisted_4$194={key:0,class:`prefix-suffix-container`},_hoisted_5$164={"data-testid":`prefix`},_hoisted_6$141={class:`bng-input-group`},_hoisted_7$123=[`value`,`type`,`min`,`max`,`step`,`maxlength`,`placeholder`,`disabled`,`readonly`],_hoisted_8$101={key:0,class:`number-actions`},_hoisted_9$91={key:1,class:`floating-label`,"data-testid":`floating-label`},_hoisted_10$79={key:2,class:`error-message`},_hoisted_11$71={key:1,class:`prefix-suffix-container`},_hoisted_12$59={"data-testid":`suffix`},_hoisted_13$51={key:2,class:`trailing-icon`},_sfc_main$363={__name:`bngInput`,props:{modelValue:[String,Number],type:{type:String,default:`text`,validator(value){return[`text`,`number`].includes(value)}},min:[Number,String],max:[Number,String],step:{type:[Number,String],default:1},decimals:Number,maxlength:[Number,String],readonly:Boolean,floatingLabel:String,externalLabel:String,placeholder:String,initialValue:String,leadingIcon:Object,prefix:String,suffix:String,trailingIcon:Object,trailingIconOutside:Boolean,disabled:Boolean,validate:Function,errorMessage:String},emits:[`update:modelValue`,`valueChanged`,`change`,`focus`,`blur`],setup(__props,{expose:__expose,emit:__emit}){let props=__props,emitter=__emit,input=ref(),value=ref(props.initialValue||props.modelValue),isInputFieldFocused=ref(!1),numMin=computed(()=>props.type===`number`?+props.min:null),numMax=computed(()=>props.type===`number`?+props.max:null),numStep=computed(()=>props.type===`number`?roundDec(+props.step,15):null),numDecimals=computed(()=>props.type===`number`?props.decimals:null),charMax=computed(()=>props.type===`text`?props.maxlength:null),hasValue=computed(()=>value.value!==``&&value.value!==void 0&&value.value!==null),hasError=computed(()=>typeof props.validate==`function`?!props.validate(value.value):!1);if(props.type===`number`){let type=typeof value.value;type===`string`&&/^\d+(?:\.?\d+)?$/.test(value.value)?value.value=+value.value:type!==`number`&&(value.value=0),numMin.value>numMax.value&&console.error(`BngInput: min cannot be greater than max`)}__expose(useDirty(value));let lastNotify;function notify(val){props.readonly||lastNotify===val||(lastNotify=val,emitter(`update:modelValue`,val),emitter(`valueChanged`,val),emitter(`change`,val))}watch(()=>props.modelValue,newVal=>{props.type===`number`&&(newVal=numClamp(newVal)),value.value=newVal,lastNotify=newVal},{immediate:!0});function numClamp(val){return isNaN(val)&&(val=0),typeof numDecimals.value==`number`&&!isNaN(numDecimals.value)?val=roundDec(val,numDecimals.value):typeof numStep.value==`number`&&!isNaN(numStep.value)&&(val=roundDecSample(val,numStep.value)),typeof numMin.value==`number`&&!isNaN(numMin.value)&&valnumMax.value&&(val=numMax.value),val}function increment(by){let val=numClamp(+value.value+by);value.value!==val&&(value.value=val,input.value=val,notify(val))}let onArrowUpClicked=()=>increment(numStep.value),onArrowDownClicked=()=>increment(-numStep.value);function onValueChanged($event){let val=$event.target.value;if(props.type===`number`){val=+val;let prev=val;val=numClamp(val),val!==prev&&(input.value=val)}value.value=val,notify(val)}function onInputFieldFocusIn(){isInputFieldFocused.value=!0,emitter(`focus`)}function onInputFieldFocusOut(){isInputFieldFocused.value=!1,emitter(`blur`),notify(value.value)}return(_ctx,_cache)=>withDirectives((openBlock(),createElementBlock(`div`,_hoisted_1$318,[__props.externalLabel?(openBlock(),createElementBlock(`span`,{key:0,class:`external-label`,style:normalizeStyle([__props.leadingIcon?{"margin-left":`3em`}:{}]),"data-testid":`external-label`},toDisplayString(__props.externalLabel),5)):createCommentVNode(``,!0),createBaseVNode(`div`,_hoisted_2$259,[__props.leadingIcon?(openBlock(),createBlock(unref(bngIcon_default),{key:0,class:`outside-icon`,type:__props.leadingIcon,"data-testid":`leading-icon`},null,8,[`type`])):createCommentVNode(``,!0),createBaseVNode(`div`,{tabindex:`disabled ? -1 : 0`,class:normalizeClass([`bng-highlight-container`,{"bng-input-focused":isInputFieldFocused.value,"has-error":hasError.value}]),onKeydown:withKeys(onInputFieldFocusOut,[`enter`])},[createBaseVNode(`div`,_hoisted_3$226,[__props.prefix?(openBlock(),createElementBlock(`span`,_hoisted_4$194,[createBaseVNode(`span`,_hoisted_5$164,toDisplayString(__props.prefix),1)])):createCommentVNode(``,!0),createBaseVNode(`div`,_hoisted_6$141,[withDirectives(createBaseVNode(`input`,{ref_key:`input`,ref:input,class:normalizeClass([`bng-input`,{"bng-input-empty":!hasValue.value,"bng-input-error":hasError.value}]),"data-testid":`input`,value:value.value,type:__props.type,min:numMin.value,max:numMax.value,step:numStep.value,maxlength:charMax.value,onInput:onValueChanged,onFocusin:onInputFieldFocusIn,onFocusout:onInputFieldFocusOut,placeholder:__props.placeholder,disabled:__props.disabled,readonly:__props.readonly},null,42,_hoisted_7$123),[[unref(BngTextInput_default)]]),__props.type===`number`?(openBlock(),createElementBlock(`div`,_hoisted_8$101,[withDirectives(createVNode(unref(bngIcon_default),{type:unref(iconsByTag).arrow.arrowLargeUp,class:normalizeClass([{"number-action-disabled":__props.readonly},`number-action up-action`])},null,8,[`type`,`class`]),[[unref(BngClick_default),{clickCallback:onArrowUpClicked,holdCallback:onArrowUpClicked}]]),withDirectives(createVNode(unref(bngIcon_default),{type:unref(iconsByTag).arrow.arrowLargeDown,class:normalizeClass([`number-action down-action`,{"number-action-disabled":__props.readonly}])},null,8,[`type`,`class`]),[[unref(BngClick_default),{clickCallback:onArrowDownClicked,holdCallback:onArrowDownClicked}]])])):createCommentVNode(``,!0),__props.floatingLabel?(openBlock(),createElementBlock(`span`,_hoisted_9$91,toDisplayString(__props.floatingLabel),1)):createCommentVNode(``,!0),hasError.value&&__props.errorMessage?(openBlock(),createElementBlock(`span`,_hoisted_10$79,toDisplayString(__props.errorMessage),1)):createCommentVNode(``,!0),_cache[0]||=createBaseVNode(`span`,{class:`input-border`},null,-1)]),__props.suffix?(openBlock(),createElementBlock(`span`,_hoisted_11$71,[createBaseVNode(`span`,_hoisted_12$59,toDisplayString(__props.suffix),1)])):createCommentVNode(``,!0),__props.trailingIcon&&!__props.trailingIconOutside?(openBlock(),createElementBlock(`span`,_hoisted_13$51,[createVNode(unref(bngIcon_default),{type:__props.trailingIcon,class:`input-icon`,"data-testid":`trailing-icon`},null,8,[`type`])])):createCommentVNode(``,!0)])],34),__props.trailingIcon&&__props.trailingIconOutside?(openBlock(),createBlock(unref(bngIcon_default),{key:1,type:__props.trailingIcon,class:`outside-icon`,"data-testid":`external-trailing-icon`},null,8,[`type`])):createCommentVNode(``,!0)])])),[[unref(BngDisabled_default),__props.disabled]])}},bngInput_default=__plugin_vue_export_helper_default(_sfc_main$363,[[`__scopeId`,`data-v-d6c70b5c`]]),_hoisted_1$317=[`readonly`,`disabled`,`placeholder`,`maxlength`],_hoisted_2$258={key:0,class:`floating-label`},_hoisted_3$225={key:7,class:`external-button`},_hoisted_4$193={key:8,class:`error-message`};const INPUT_TYPES={text:`text`,number:`number`},STEP_ICON_TYPES={arrowUpDown:`arrowUpDown`,arrowLeftRight:`arrowLeftRight`,plusMinus:`plusMinus`};var STEP_ICON_TYPES_MAP={[STEP_ICON_TYPES.arrowUpDown]:{up:`arrowSmallUp`,down:`arrowSmallDown`},[STEP_ICON_TYPES.arrowLeftRight]:{up:`arrowSmallRight`,down:`arrowSmallLeft`},[STEP_ICON_TYPES.plusMinus]:{up:`plus`,down:`minus`}},NUMBER_PATTERN=/^\d+(\.d+)?$/,NUMBER_INPUT_KEYS=/^[0-9\.\-]$/,ERROR_TYPES={invalidformat:`invalidformat`,outofrange:`outofrange`,required:`required`,custom:`custom`},ERROR_MESSAGES={[ERROR_TYPES.invalidformat]:`Invalid format`,[ERROR_TYPES.outofrange]:`Value must be between {min} and {max}`,[`${ERROR_TYPES.outofrange}-min`]:`Value must be greater than {min}`,[`${ERROR_TYPES.outofrange}-max`]:`Value must be less than {max}`,[ERROR_TYPES.required]:`Value is required`},ALLOW_DEFAULT_BEHAVIOR_KEYS=[`ArrowLeft`,`ArrowRight`,`ArrowUp`,`ArrowDown`,`Backspace`,`Delete`],NUMBER_INPUT_MODES={spinner:`spinner`,arrowKeys:`arrowKeys`,uinav:`uinav`},_sfc_main$362={__name:`bngInputNew`,props:{modelValue:{type:[Number,String],default:void 0},value:{type:[Number,String],default:void 0},type:{type:String,default:INPUT_TYPES.text,validator(value){return Object.keys(INPUT_TYPES).includes(value)}},showExternalButton:{type:Boolean,default:!0},floatingLabel:[Boolean,String],externalButtonFn:Function,externalLabel:String,label:String,prefix:String,suffix:String,leadingIcon:Object,trailingIcon:Object,maxLength:{type:[Number,String],default:null,validator(value){return value===null?!0:typeof parseInt(value)==`number`&&parseInt(value)>=0}},readonly:Boolean,disabled:Boolean,required:Boolean,placeholder:String,validate:Function,errorMessage:String,min:{type:Number,default:void 0},max:{type:Number,default:void 0},step:{type:Number,default:1},stepIconType:{type:String,default:STEP_ICON_TYPES.arrowUpDown,validator(value){return Object.keys(STEP_ICON_TYPES).includes(value)}},noStepBindings:Boolean},emits:[`update:modelValue`,`change`,`error`,`blur`,`focus`,`valueChanged`],setup(__props,{expose:__expose,emit:__emit}){let props=__props,emit$1=__emit,slots=useSlots(),{showIfController}=storeToRefs(controls_default()),input=ref(null),scopeActivated=ref(!1),rawValue=ref(null),validationState=ref(null),isProgrammaticChange=ref(!1),numberInputState=reactive({inputType:null,isUpActive:!1,isDownActive:!1}),value=computed({get:()=>props.modelValue,set:emitChange}),isEmptyRawValue=computed(()=>isEmpty(rawValue.value)),inputStyle=computed(()=>({"max-width":props.maxLength?`${props.maxLength}ch`:`initial`})),stepIcons=computed(()=>STEP_ICON_TYPES_MAP[props.stepIconType]),exposed=useDirty(value);exposed.scopeActivated=scopeActivated,__expose(exposed),watch(()=>rawValue.value,newValue=>{if(isProgrammaticChange.value){isProgrammaticChange.value=!1;return}let res=validate(newValue);validationState.value=res,rawValue.value!=props.modelValue&&(res.valid||res.error!==ERROR_TYPES.invalidformat)&&(value.value=res.value)}),watch(()=>props.modelValue,modelValue=>{modelValue!=rawValue.value&&(isProgrammaticChange.value=!0,rawValue.value=isEmpty(modelValue)?null:String(modelValue))},{immediate:!0}),watch(()=>props.value,()=>{props.modelValue===void 0&&props.value!=rawValue.value&&(isProgrammaticChange.value=!0,rawValue.value=props.value)},{immediate:!0}),onUnmounted(()=>{resetInputState.cancel()});let activateInput=()=>{props.disabled||props.readonly||nextTick(()=>input.value.focus())},canActivateScope=()=>!props.readonly&&!props.disabled,externalButtonFn=()=>{props.externalButtonFn?props.externalButtonFn():props.type===INPUT_TYPES.number?rawValue.value=props.min||0:rawValue.value=null,activateInput()};function onScopeActivated(event){scopeActivated.value=!0}function onScopeDeactivated(event){scopeActivated.value=!1,nextTick(()=>cleanValue())}let resetInputState=debounce(()=>{numberInputState.inputType=null,numberInputState.isUpActive=!1,numberInputState.isDownActive=!1},150);function onUINavChangeValue(dir){numberInputState.inputType&&numberInputState.inputType!==NUMBER_INPUT_MODES.uinav||(numberInputState.inputType=NUMBER_INPUT_MODES.uinav,updateNumValue(dir),resetInputState())}function onArrowKeysChangeValue(dir){numberInputState.inputType&&numberInputState.inputType!==NUMBER_INPUT_MODES.arrowKeys||(numberInputState.inputType=NUMBER_INPUT_MODES.arrowKeys,updateNumValue(dir),resetInputState())}function onSpinnerChangeValue(dir){numberInputState.inputType&&numberInputState.inputType!==NUMBER_INPUT_MODES.spinner||(numberInputState.inputType=NUMBER_INPUT_MODES.spinner,updateNumValue(dir),resetInputState())}function updateNumValue(dir){props.type!==INPUT_TYPES.number||props.disabled||props.readonly||(dir===1?(numberInputState.isUpActive=!0,changeNumValue(props.step)):(numberInputState.isDownActive=!0,changeNumValue(-props.step)))}function onEnterDown(event){event.preventDefault(),scopeActivated.value=!1}function onKeyDown(event){if(ALLOW_DEFAULT_BEHAVIOR_KEYS.includes(event.key))return;event.key===`Enter`&&event.preventDefault();let rawValueString=typeof rawValue.value!=`string`&&!isNullOrUndefined(rawValue.value)?rawValue.value.toString():rawValue.value;props.type===INPUT_TYPES.number&&(!NUMBER_INPUT_KEYS.test(event.key)||event.key===`.`&&(isNullOrUndefined(rawValueString)||rawValueString.includes(`.`))||event.key===`.`&&!NUMBER_PATTERN.test(rawValueString))&&event.preventDefault()}function changeNumValue(diff){if(props.type!==INPUT_TYPES.number)return;if(isEmpty(rawValue.value)){diff<0?rawValue.value=isNullOrUndefined(props.max)?0:props.max:rawValue.value=isNullOrUndefined(props.min)?0:props.min;return}let{valid,value:validatedValue,error}=validate(rawValue.value);if(!valid&&error!==ERROR_TYPES.outofrange){rawValue.value=0;return}let decimalTokens=props.step.toString().split(`.`),stepDecimalPlaces=decimalTokens.length>1?decimalTokens[1].length:0,newValue=Number((validatedValue+diff).toFixed(stepDecimalPlaces)),{valid:isValidRange}=validateRange(newValue);(isValidRange||diff<0&&newValue>=props.max||diff>0&&newValue<=props.min)&&(rawValue.value=newValue)}function cleanValue(){if(!isNullOrUndefined(rawValue.value)&&props.type===INPUT_TYPES.number){let rawValueString=typeof rawValue.value==`string`?rawValue.value:rawValue.value.toString();rawValueString.endsWith(`.`)&&(rawValue.value=rawValueString.slice(0,-1))}}function validate(value$1){let valid=!0,newValue=value$1,errorMessage=null;if(isEmpty(value$1)&&props.required)return{valid:!1,error:ERROR_TYPES.required};if(isEmpty(value$1)&&props.type===INPUT_TYPES.number)return{valid:!0,value:void 0};if(props.type===INPUT_TYPES.number&&typeof value$1==`string`&&(newValue=value$1.includes(`.`)?parseFloat(value$1):parseInt(value$1),isNaN(newValue)))return{valid:!1,error:ERROR_TYPES.invalidformat};if(props.type===INPUT_TYPES.number)return{...validateRange(newValue),value:newValue};if(props.validate){let res=props.validate(value$1);typeof res==`boolean`?(valid=res,errorMessage=props.errorMessage):typeof res==`object`&&(`valid`in res&&console.warn("`validate` function must return a boolean `valid` property. Ignoring validation result..."),valid=res.valid||!0,valid||(errorMessage=`errorMessage`in res?res.errorMessage:props.errorMessage))}return{valid,value:newValue,errorMessage}}function validateRange(value$1){let lessThanMin=props.min&&value$1props.max,valid=!0,errorMessage=null;return!isNullOrUndefined(props.min)&&!isNullOrUndefined(props.max)&&(lessThanMin||greaterThanMax)?(errorMessage=ERROR_MESSAGES[ERROR_TYPES.outofrange].replace(`{min}`,props.min).replace(`{max}`,props.max),valid=!1):lessThanMin?(errorMessage=ERROR_MESSAGES[`${ERROR_TYPES.outofrange}-min`].replace(`{min}`,props.min),valid=!1):greaterThanMax&&(errorMessage=ERROR_MESSAGES[`${ERROR_TYPES.outofrange}-max`].replace(`{max}`,props.max),valid=!1),{valid,error:valid?null:ERROR_TYPES.outofrange,errorMessage}}function isEmpty(val){return val==null||val===``}function isNullOrUndefined(val){return val==null}function emitChange(value$1){emit$1(`update:modelValue`,value$1),emit$1(`change`,value$1),emit$1(`valueChanged`,value$1)}return(_ctx,_cache)=>withDirectives((openBlock(),createElementBlock(`div`,{class:normalizeClass([{"has-value":!isEmptyRawValue.value,"bng-input-readonly":__props.readonly,"bng-input-invalid":validationState.value&&!validationState.value.valid},`bng-input`]),onActivate:onScopeActivated,onDeactivate:onScopeDeactivated},[(__props.label||__props.externalLabel||unref(slots).label)&&!__props.floatingLabel?(openBlock(),createElementBlock(`label`,{key:0,class:`external-label`,onClick:activateInput,onMousedown:_cache[0]||=withModifiers(()=>{},[`prevent`])},[renderSlot(_ctx.$slots,`label`,{},()=>[createTextVNode(toDisplayString(__props.label||__props.externalLabel),1)],!0)],32)):createCommentVNode(``,!0),__props.leadingIcon||unref(slots).leadingIcon?(openBlock(),createElementBlock(`span`,{key:1,class:`leading-icon`,onClick:activateInput,onMousedown:_cache[1]||=withModifiers(()=>{},[`prevent`])},[renderSlot(_ctx.$slots,`leading-icon`,{},()=>[createVNode(unref(bngIcon_default),{type:__props.leadingIcon},null,8,[`type`])],!0)],32)):createCommentVNode(``,!0),__props.type===INPUT_TYPES.number&&!__props.readonly&&!__props.disabled?(openBlock(),createElementBlock(`span`,{key:2,class:normalizeClass([{"spinner-active":numberInputState.isDownActive},`input-spinner input-spinner-down`]),onMousedown:_cache[2]||=withModifiers(()=>{},[`prevent`])},[renderSlot(_ctx.$slots,`spinner-down`,{changeValue:()=>onSpinnerChangeValue(-1)},()=>[withDirectives((openBlock(),createBlock(unref(bngButton_default),{"bng-no-nav":`true`,accent:`text`},{default:withCtx(()=>[__props.noStepBindings?createCommentVNode(``,!0):(openBlock(),createBlock(unref(bngBinding_default),{key:0,controller:``,uiEvent:`focus_d`})),!unref(showIfController)||__props.noStepBindings?(openBlock(),createBlock(unref(bngIcon_default),{key:1,type:stepIcons.value.down},null,8,[`type`])):createCommentVNode(``,!0)]),_:1})),[[unref(BngClick_default),{clickCallback:()=>onSpinnerChangeValue(-1),holdCallback:()=>onSpinnerChangeValue(-1)}]])],!0)],34)):createCommentVNode(``,!0),__props.prefix||unref(slots).prefix?(openBlock(),createElementBlock(`span`,{key:3,class:`prefix`,onClick:activateInput,onMousedown:_cache[3]||=withModifiers(()=>{},[`prevent`])},[renderSlot(_ctx.$slots,`prefix`,{},()=>[createTextVNode(toDisplayString(__props.prefix),1)],!0)],32)):createCommentVNode(``,!0),createBaseVNode(`div`,{class:`input-container`,style:normalizeStyle(inputStyle.value)},[withDirectives(createBaseVNode(`input`,{ref_key:`input`,ref:input,"onUpdate:modelValue":_cache[4]||=$event=>rawValue.value=$event,readonly:__props.readonly,disabled:__props.disabled,placeholder:__props.placeholder,maxlength:__props.maxLength,type:`text`,onFocusin:_cache[5]||=$event=>_ctx.$emit(`focus`),onFocusout:_cache[6]||=$event=>_ctx.$emit(`blur`),onKeydown:[_cache[7]||=withKeys($event=>onArrowKeysChangeValue(1),[`arrow-up`]),_cache[8]||=withKeys($event=>onArrowKeysChangeValue(-1),[`arrow-down`]),withKeys(onEnterDown,[`enter`]),onKeyDown]},null,40,_hoisted_1$317),[[unref(BngTextInput_default)],[unref(BngOnUiNavFocus_default),dir=>onUINavChangeValue(dir),`vertical`,{repeat:!0}],[vModelText,rawValue.value]]),__props.label&&__props.floatingLabel||typeof __props.floatingLabel==`string`||unref(slots).label?(openBlock(),createElementBlock(`label`,_hoisted_2$258,[renderSlot(_ctx.$slots,`label`,{},()=>[createTextVNode(toDisplayString(__props.label||__props.floatingLabel),1)],!0)])):createCommentVNode(``,!0)],4),__props.suffix||unref(slots).suffix?(openBlock(),createElementBlock(`span`,{key:4,class:`suffix`,onClick:activateInput,onMousedown:_cache[9]||=withModifiers(()=>{},[`prevent`])},[renderSlot(_ctx.$slots,`suffix`,{},()=>[createTextVNode(toDisplayString(__props.suffix),1)],!0)],32)):createCommentVNode(``,!0),__props.trailingIcon||unref(slots).trailingIcon?(openBlock(),createElementBlock(`span`,{key:5,class:`trailing-icon`,onClick:activateInput,onMousedown:_cache[10]||=withModifiers(()=>{},[`prevent`])},[renderSlot(_ctx.$slots,`trailing-icon`,{},()=>[createVNode(unref(bngIcon_default),{type:__props.trailingIcon},null,8,[`type`])],!0)],32)):createCommentVNode(``,!0),__props.type===INPUT_TYPES.number&&!__props.readonly&&!__props.disabled?(openBlock(),createElementBlock(`span`,{key:6,class:normalizeClass([{"spinner-active":numberInputState.isUpActive},`input-spinner input-spinner-up`]),onMousedown:_cache[11]||=withModifiers(()=>{},[`prevent`])},[renderSlot(_ctx.$slots,`spinner-up`,{changeValue:()=>onSpinnerChangeValue(1)},()=>[withDirectives((openBlock(),createBlock(unref(bngButton_default),{"bng-no-nav":`true`,accent:`text`},{default:withCtx(()=>[__props.noStepBindings?createCommentVNode(``,!0):(openBlock(),createBlock(unref(bngBinding_default),{key:0,controller:``,uiEvent:`focus_u`})),!unref(showIfController)||__props.noStepBindings?(openBlock(),createBlock(unref(bngIcon_default),{key:1,type:stepIcons.value.up},null,8,[`type`])):createCommentVNode(``,!0)]),_:1})),[[unref(BngClick_default),{clickCallback:()=>onSpinnerChangeValue(1),holdCallback:()=>onSpinnerChangeValue(1)}]])],!0)],34)):createCommentVNode(``,!0),__props.showExternalButton?(openBlock(),createElementBlock(`span`,_hoisted_3$225,[renderSlot(_ctx.$slots,`external-button`,{externalButtonFn},()=>[__props.readonly?createCommentVNode(``,!0):withDirectives((openBlock(),createBlock(unref(bngButton_default),{key:0,icon:unref(icons).mathMultiply,disabled:__props.disabled,accent:`attention`,onClick:externalButtonFn,onMousedown:_cache[12]||=withModifiers(()=>{},[`prevent`])},null,8,[`icon`,`disabled`])),[[unref(BngOnUiNav_default),void 0,`ok`,{asMouse:!0,focusRequired:!0}],[unref(BngDisabled_default),isEmptyRawValue.value]])],!0)])):createCommentVNode(``,!0),validationState.value&&!validationState.value.valid&&validationState.value.errorMessage||unref(slots).errorMessage?(openBlock(),createElementBlock(`span`,_hoisted_4$193,[renderSlot(_ctx.$slots,`error-message`,{},()=>[createTextVNode(toDisplayString(validationState.value.errorMessage),1)],!0)])):createCommentVNode(``,!0)],34)),[[unref(BngDisabled_default),__props.disabled],[unref(BngScopedNav_default),{activated:scopeActivated.value,canActivate:canActivateScope}]])}},bngInputNew_default=__plugin_vue_export_helper_default(_sfc_main$362,[[`__scopeId`,`data-v-bb1297d5`]]),_hoisted_1$316={class:`list-container`},_hoisted_2$257={key:0,class:`list-toolbar`},_hoisted_3$224={key:1},_hoisted_4$192={class:`list-layout-toggle`};const LIST_LAYOUTS={DEFAULT:`tiles`,TILES:`tiles`,LIST:`list`,RIBBON:`ribbon`};var _sfc_main$361={__name:`bngList`,props:{path:Array,pathLimit:{type:[Number,String],default:3},pathTarget:Object,layoutSelector:Boolean,layoutSelectorTarget:Object,layout:{type:String,default:LIST_LAYOUTS.DEFAULT,validator:val=>Object.values(LIST_LAYOUTS).includes(val)},big:Boolean,immediate:Boolean,keepAlive:[Boolean,Number],tileSizeCalc:Function,tileWidth:Number,tileHeight:Number,tileMargin:Number,targetWidth:Number,targetHeight:Number,targetMargin:Number,titleWidth:Number,titleHeight:Number,titleMargin:Number,targetTitleWidth:Number,targetTitleHeight:Number,targetTitleMargin:Number,noBackground:Boolean},emits:[`layoutChange`,`pathClick`],setup(__props,{expose:__expose,emit:__emit}){let emit$1=__emit,props=__props,elPath=ref();__expose({navBack(){elPath.value&&elPath.value.navBack()},navTo(item){elPath.value&&elPath.value.navTo(item)},async scrollToIndex(index=0){if(!bigmode.enabled){let hasPosObserver=(elCont.value.children||[])[0]?.classList.contains(`bng-pos-observer`),elm=(elCont.value.children||[])[index+(hasPosObserver?1:0)];return elm&&elm.scrollIntoView(),elm}let big=await getBigProps(void 0,index);if(!big)return null;let horizontal=layoutSelected.value===LIST_LAYOUTS.RIBBON,containerSize=horizontal?contWidth:contHeight,rowIndex=layoutCache.itemToRow.get(index),itemRowPos=layoutCache.rows[rowIndex]?.pos||big.position,itemRowSize=layoutCache.rows[rowIndex]?.size||(horizontal?tileWidth.value:tileHeight.value),centeredPos=itemRowPos-containerSize/2+itemRowSize/2;scrollPos.value=Math.max(0,centeredPos),horizontal?elCont.value.scrollLeft=scrollPos.value:elCont.value.scrollTop=scrollPos.value,await updSkeleton();let itm=items$2.value[index];return itm?itm.getElement?.()||itm.el||itm:null},refresh(){tileWidth.value=0,tileHeight.value=0,titleWidth.value=0,titleHeight.value=0,tileProps=getItemProps(items$2.value,!1),titleProps=getItemProps(items$2.value,!0),tileProps&&(tileMargin.value=validNum(tileProps.margin)?tileProps.margin:defTileMargin*fontSize,calcTiles()),titleProps&&(titleMargin.value=validNum(titleProps.margin)?titleProps.margin:defTitleMargin*fontSize,calcTitles()),invalidateLayoutCache(),nextTick(()=>{bigmode.enabled&&contWidth>0&&contHeight>0&&(buildLayoutCache(),calcBig(),updSkeleton())})}});let defFontSize=16,defTileWidth=10,defTileHeight=5,defTileMargin=.2,defTitleWidth=10,defTitleHeight=2.5,defTitleMargin=.2,layoutSelected=ref(props.layout);watch(()=>props.layout,()=>layoutSelected.value=props.layout||LIST_LAYOUTS.DEFAULT),watch(()=>layoutSelected.value,val=>{emit$1(`layoutChange`,val),invalidateLayoutCache(),updSize()});let toolbar=computed(()=>{let res={path:props.path&&props.path.length>0,layout:props.layoutSelector};return res.enabled=res.path||res.layout,res.show=res.enabled&&(res.path&&!props.pathTarget||res.layout&&!props.layoutSelectorTarget),res}),slots=useSlots(),elCont=ref(),elSize=ref(),elSkeleton=ref(),tileWidth=ref(0),tileHeight=ref(0),tileMargin=ref(0),titleWidth=ref(0),titleHeight=ref(0),titleMargin=ref(0),scrollPos=ref(0),skeletonItems=ref([]),processing=computed(()=>bigmode.enabled&&(bigmode.initial||layoutCache.building)),contWidth=0,contHeight=0,fontSize=16,skeletonShown=!1,warnShown=!1,listItemsStyle=computed(()=>bigmode.enabled?{transform:`translate${layoutSelected.value===LIST_LAYOUTS.RIBBON?`X`:`Y`}(${bigmode.position}px)`}:void 0),tileProps=null,titleProps=null,bigmode=reactive({enabled:!1,initial:!0,debounce:500,skeleton:!0,layouts:[],getPos:{[LIST_LAYOUTS.TILES]:()=>elCont.value?.scrollTop||0,[LIST_LAYOUTS.LIST]:()=>elCont.value?.scrollTop||0,[LIST_LAYOUTS.RIBBON]:()=>elCont.value?.scrollLeft||0},overflow:2,skeletonOverflow:2,first:0,last:0,perRow:1,items:[],position:0,full:0,size:0});bigmode.layouts=Object.keys(bigmode.getPos);let layoutCache=reactive({version:0,building:!1,valid:!1,itemCount:0,totalSize:0,rows:[],itemToRow:new Map,rowPositions:[]}),items$2=ref([]),itemsView=ref([]),itemsShown=ref(new Set);watch(()=>props.immediate,val=>{val?(bigmode._skeleton=bigmode.skeleton,bigmode._debounce=bigmode.debounce,bigmode.skeleton=!1,bigmode.debounce=0):(bigmode._skeleton&&(bigmode.skeleton=bigmode._skeleton),bigmode._debounce&&(bigmode.debounce=bigmode._debounce))},{immediate:!0}),watch([()=>slots.default?.(),()=>props.big,()=>layoutSelected.value],()=>{let res=slots.default?slots.default():[];bigmode.enabled=props.big&&bigmode.layouts.includes(layoutSelected.value),bigmode.enabled&&(bigmode.initial=!0,res=getItems(res)),res=res.map((item,key)=>({...item,key})),items$2.value=res,bigmode.enabled||(itemsView.value=res),itemsShown.value.clear(),nextTick(()=>{tileProps=getItemProps(res,!1),titleProps=getItemProps(res,!0),invalidateLayoutCache(),updSize(),updSkeleton()})},{immediate:!0});function getItems(vnodes,_level=0){let res=[];for(let vnode of vnodes)switch(typeof vnode.type){case`object`:{let isTitle=vnode.props&&`bng-list-title`in vnode.props,item={...vnode};isTitle&&(item.isBngListTitle=!0),res.push(item);break}case`symbol`:if(_level===20)return logger_default.debug(`BngList reached max level of nested Vue fragments`),[];res.push(...getItems(vnode.children,_level+1));break}return res}function findItem(vnode,_level=0){let res=null;switch(typeof vnode.type){case`object`:res={el:vnode.el,width:vnode.type.width,height:vnode.type.height,margin:vnode.type.margin};break;case`string`:vnode.el instanceof HTMLElement&&(res={el:vnode.el});break;case`symbol`:if(vnode.children.length>0){if(_level===20)return null;res=findItem(vnode.children[0],++_level)}break}return res}function getItemProps(vnodes,title=!1){if(vnodes.length===0)return null;let sampleItem=vnodes.find(vnode=>title&&vnode.isBngListTitle||!title&&!vnode.isBngListTitle);if(!sampleItem)return null;let res=findItem(sampleItem);if(!res)return null;let valid={width:validNum(res.width),height:validNum(res.height),margin:validNum(res.margin)},fontSize$1,targetWidth=0,targetHeight=0,targetMargin=0;if(!title&&props.tileSizeCalc)try{fontSize$1||=getFontSize();let size$3=props.tileSizeCalc({contWidth,contHeight,fontSize:fontSize$1,layout:layoutSelected.value});if(size$3&&typeof size$3==`object`){let isPx=size$3.unit===`px`;targetWidth=isPx?size$3.width/fontSize$1:size$3.width,targetHeight=isPx?size$3.height/fontSize$1:size$3.height,targetMargin=isPx?size$3.margin/fontSize$1:size$3.margin}}catch(err){logger_default.warn(`BngList: tileSizeCalc function error:`,err)}targetWidth||=title?props.titleWidth||props.targetTitleWidth:props.tileWidth||props.targetWidth,targetHeight||=title?props.titleHeight||props.targetTitleHeight:props.tileHeight||props.targetHeight,targetMargin||=title?props.titleMargin||props.targetTitleMargin:props.tileMargin||props.targetMargin,validNum(targetWidth)&&(res.width=targetWidth,valid.width=!0),validNum(targetHeight)&&(res.height=targetHeight,valid.height=!0),validNum(targetMargin)&&(res.margin=targetMargin,valid.margin=!0);let em2px=em=>(fontSize$1||=getFontSize(),em*fontSize$1);if(valid.width&&res.width&&(res.width=em2px(res.width)),valid.height&&res.height&&(res.height=em2px(res.height)),valid.margin&&res.margin&&(res.margin=em2px(res.margin)),!valid.width||bigmode.enabled&&!valid.height||!valid.margin){if(res.el instanceof HTMLElement){let style=window.getComputedStyle(res.el,null);valid.width||(res.width=+style.width.substring(0,style.width.length-2)),valid.height||(res.height=+style.height.substring(0,style.height.length-2)),valid.margin||(res.margin=[style.marginTop,style.marginRight,style.marginBottom,style.marginLeft].map(m=>+m.substring(0,m.length-2)).sort((a$1,b)=>b-a$1)[0])}else logger_default.warn(`BngList cannot access ${title?`title`:`tile`} element for size auto-detection!`);warnShown||(warnShown=!0,logger_default.debug(`BigList was not provided with ${title?`title`:`target`} sizes (from props or from ${title?`title`:`tile`} component export) and attempted to auto-detect them. This may lead to some size micro-adjustments visible to user or invalid sizes. Please specify ${title?`title`:`target`} sizes manually.`),(res.width<1||res.height<1)&&logger_default.debug(`BigList noticed a detected ${title?`title`:``} size being too low: width = ${res.width}, height = ${res.height}`))}return res}let validNum=num=>typeof num==`number`&&!isNaN(num),getFontSize=()=>{if(!elCont.value)return 16;let size$3=window.getComputedStyle(elCont.value,null).fontSize;return+size$3.substring(0,size$3.length-2)||16},resizeObserver=new ResizeObserver(updSize);onMounted(()=>nextTick(()=>{resizeObserver.observe(elSize.value)})),onBeforeUnmount(()=>{elSize.value&&resizeObserver.unobserve(elSize.value),resizeObserver.disconnect()});let scrolling=ref(!1),scrollTmr,scrollTick=!1,onScrollDebounce=async()=>{scrollPos.value=bigmode.getPos[layoutSelected.value](),await updSkeleton()};watch(scrollPos,async pos=>{if(bigmode.enabled)if(bigmode.debounce>0)clearTimeout(scrollTmr),scrolling.value=!0,scrollTmr=setTimeout(async()=>{scrolling.value=!1,await calcBig(pos),await updSkeleton()},bigmode.debounce);else{if(scrollTick)return;scrollTick=!0,requestAnimationFrame(async()=>{scrollTick=!1,await calcBig(pos),await updSkeleton()})}});function vScroll(evt){evt.deltaY!==0&&elCont.value.scrollBy({left:evt.deltaY,behavior:`instant`})}function updSize(entries=[]){let oldContWidth=contWidth,oldContHeight=contHeight;tileWidth.value=0,tileHeight.value=0,titleWidth.value=0,titleHeight.value=0,tileProps?(tileMargin.value=validNum(tileProps.margin)?tileProps.margin:defTileMargin*fontSize,calcTiles(entries)):tileMargin.value=0,titleProps?(titleMargin.value=validNum(titleProps.margin)?titleProps.margin:defTitleMargin*fontSize,calcTitles(entries)):titleMargin.value=0,(Math.abs(oldContWidth-contWidth)>1||Math.abs(oldContHeight-contHeight)>1)&&invalidateLayoutCache(),bigmode.enabled&&!layoutCache.valid&&contWidth>0&&contHeight>0&&(!titleProps||titleWidth.value>0&&titleHeight.value>0)&&buildLayoutCache(),bigmode.enabled&&bigmode.initial&&(tileProps||titleProps)&&nextTick(async()=>{await calcBig(),await updSkeleton(),setTimeout(async()=>{await calcBig(),await updSkeleton()},50)}),elCont.value.removeEventListener(`mousewheel`,vScroll),layoutSelected.value===LIST_LAYOUTS.RIBBON&&elCont.value.addEventListener(`mousewheel`,vScroll)}function calcSizes(entries=[]){if(contWidth=0,contHeight=0,!elSize.value||!bigmode.enabled&&layoutSelected.value!==LIST_LAYOUTS.TILES)return!1;let baseMargin=tileMargin.value,rect=entries[0]?.contentRect||elSize.value.getBoundingClientRect();if(fontSize=getFontSize(),contWidth=rect.width,layoutSelected.value===LIST_LAYOUTS.RIBBON){let tileHeight$1=(tileProps?.height||5*fontSize)+baseMargin,titleHeight$1=titleProps?(titleProps.height||defTitleHeight*fontSize)+(titleProps.margin||defTitleMargin*fontSize):0;contHeight=Math.max(tileHeight$1,titleHeight$1)}else contHeight=rect.height-baseMargin;return!0}function calcTiles(entries=[]){if(!calcSizes(entries))return;let wantsWidth=layoutSelected.value===LIST_LAYOUTS.TILES||bigmode.enabled&&layoutSelected.value===LIST_LAYOUTS.RIBBON,wantsHeight=bigmode.enabled;if(!wantsWidth&&!wantsHeight)return;let baseMargin=tileMargin.value;if(wantsWidth){let baseWidth=tileProps.width||10*fontSize;if(contWidth>0&&layoutSelected.value===LIST_LAYOUTS.TILES){let prepWidth=baseWidth+baseMargin,amount=contWidth/prepWidth;amount<2?tileWidth.value=contWidth-baseMargin:tileWidth.value=(contWidth-baseMargin)/~~amount-baseMargin}else tileWidth.value=baseWidth}wantsHeight&&(tileHeight.value=tileProps.height||5*fontSize),bigmode.enabled&&bigmode.initial&&((!wantsWidth||contWidth>0)&&(!wantsHeight||contHeight>0)?(bigmode.initial=!1,calcBig(),updSkeleton()):window.requestAnimationFrame(()=>calcTiles()))}function calcTitles(){if(bigmode.enabled&&(fontSize=getFontSize()),!titleProps)return;let baseMargin=titleMargin.value,baseHeight=titleProps.height||defTitleHeight*fontSize;layoutSelected.value===LIST_LAYOUTS.RIBBON?titleWidth.value=titleProps.width||10*fontSize:titleWidth.value=contWidth-baseMargin;let oldTitleHeight=titleHeight.value;titleHeight.value=baseHeight,bigmode.enabled&&oldTitleHeight===0&&titleHeight.value>0&&contWidth>0&&contHeight>0&&(invalidateLayoutCache(),buildLayoutCache())}function clearLayoutCache(){layoutCache.totalSize=0,layoutCache.rows=[],layoutCache.itemToRow.clear(),layoutCache.rowPositions=[],layoutCache.valid=!0,layoutCache.building=!1,bigmode.enabled&&(bigmode.initial=!1,bigmode.full=0,bigmode.position=0,itemsView.value=[])}async function buildLayoutCache(){if(layoutCache.building){for(;layoutCache.building;)await sleep(10);return}if(items$2.value.length===0){clearLayoutCache();return}if(!tileProps&&!titleProps||contWidth<=0||contHeight<=0)return;if(layoutCache.building=!0,layoutCache.version=Date.now(),layoutCache.itemCount=items$2.value.length,await sleep(0),layoutCache.rows=[],layoutCache.itemToRow.clear(),layoutCache.rowPositions=[],layoutCache.itemCount!==items$2.value.length&&(layoutCache.itemCount=0),layoutCache.itemCount===0){clearLayoutCache(),items$2.value.length>0&&buildLayoutCache();return}let baseTileMargin=tileProps?.margin||defTileMargin*fontSize,baseTitleMargin=titleProps?.margin||defTitleMargin*fontSize,horizontal=layoutSelected.value===LIST_LAYOUTS.RIBBON,tilesPerRow=layoutSelected.value===LIST_LAYOUTS.TILES?~~(contWidth/tileWidth.value):1,pos=0,first=0,curItems=0;function completeRow(i){let tileSize=horizontal?tileWidth.value:tileHeight.value,size$3=tileSize+baseTileMargin,row={pos,size:size$3,first,last:i-1};layoutCache.rows.push(row),layoutCache.rowPositions.push(pos);for(let j=first;j0&&(completeRow(i),curItems=0);let titleSize=horizontal?titleWidth.value:titleHeight.value,rowSize=titleSize+baseTitleMargin,row={pos,size:rowSize,first:i,last:i,isTitle:!0};layoutCache.rows.push(row),layoutCache.rowPositions.push(pos),layoutCache.itemToRow.set(i,layoutCache.rows.length-1);let nextMargin=items$2.value[i+1]?.isBngListTitle?baseTitleMargin:baseTileMargin;pos+=titleSize+nextMargin,first=i+1,curItems=0}else if(curItems++,curItems===1&&(first=i),curItems>=tilesPerRow){let tileSize=horizontal?tileWidth.value:tileHeight.value,size$3=tileSize+baseTileMargin,row={pos,size:size$3,first,last:i};layoutCache.rows.push(row),layoutCache.rowPositions.push(pos);for(let j=first;j<=i;j++)layoutCache.itemToRow.set(j,layoutCache.rows.length-1);let nextMargin=items$2.value[i+1]?.isBngListTitle?baseTitleMargin:baseTileMargin;pos+=tileSize+nextMargin,curItems=0,first=i+1}curItems>0&&completeRow(layoutCache.itemCount),pos+=items$2.value[layoutCache.itemCount-1]?.isBngListTitle?baseTitleMargin:baseTileMargin,layoutCache.totalSize=pos,layoutCache.valid=!0,layoutCache.building=!1}function invalidateLayoutCache(){layoutCache.valid=!1,layoutCache.version++}function layoutCacheSearch(arr,target){let left=0,right=arr.length-1;for(;left<=right;){let mid=~~((left+right)/2);arr[mid]<=target?left=mid+1:right=mid-1}return Math.max(0,right)}async function getBigProps(pos=void 0,index=void 0,overflow=void 0){let count$1=items$2.value.length;if(count$1===0)return;if((!layoutCache.valid||layoutCache.itemCount!==count$1)&&(await buildLayoutCache(),!layoutCache.valid))return null;(typeof index!=`number`||index<0)&&(index=void 0,typeof pos!=`number`&&(pos=bigmode.getPos[layoutSelected.value]()));let contSize=layoutSelected.value===LIST_LAYOUTS.RIBBON?contWidth:contHeight;typeof overflow!=`number`&&(overflow=bigmode.overflow);let overflowBefore=Math.ceil(overflow/2),overflowAfter=Math.floor(overflow/2),firstRow=0,currentPos=0;if(typeof index==`number`&&index>=0){let rowIndex=layoutCache.itemToRow.get(index);rowIndex!==void 0&&(firstRow=rowIndex,currentPos=layoutCache.rows[rowIndex].pos,pos=currentPos)}else firstRow=layoutCacheSearch(layoutCache.rowPositions,pos),currentPos=layoutCache.rows[firstRow]?.pos||0;let extendedFirstRow=firstRow,backwardCount=0;for(let i=firstRow-1;i>=0&&backwardCount=contSize));i++);let overflowCount=0;for(let i=lastRow+1;iprops.keepAlive){let center=big.first+(big.last-big.first)/2,farthest=Array.from(itemsShown.value).sort((a$1,b)=>Math.abs(b-center)-Math.abs(a$1-center)).slice(0,itemsShown.value.size-props.keepAlive);for(let idx of farthest)itemsShown.value.delete(idx)}big.items=Array.from(itemsShown.value).sort((a$1,b)=>a$1-b).map(idx=>{let item=items$2.value[idx];return idx>=big.first&&idx<=big.last?item:{...item,keepAliveStyle:`display: none !important;`}})}else itemsShown.value.size>0&&itemsShown.value.clear();bigmode.items=big.items,itemsView.value=big.items}}function showSkeleton(show=!0){skeletonShown!==show&&(show?elSkeleton.value.style.removeProperty(`display`):(skeletonItems.value=[],elSkeleton.value.style.setProperty(`display`,`none`,`important`)),skeletonShown=show)}async function updSkeleton(){if(!elSkeleton.value||!bigmode.enabled||!bigmode.skeleton||!scrolling.value||items$2.value.length===0||!layoutCache.valid){showSkeleton(!1);return}if(bigmode.first===0&&bigmode.last===items$2.value.length-1){showSkeleton(!1);return}let horizontal=layoutSelected.value===LIST_LAYOUTS.RIBBON,contSize=horizontal?contWidth:contHeight,pos=scrollPos.value,start,end;if(pos=bigmode.position||(end=i,visibleSize+=row.size,visibleSize>=contSize))break}let overflowCount=0;for(let i=end+1;i=bigmode.position);i++)end=i,overflowCount++;let neededSize=contSize+bigmode.skeletonOverflow*(horizontal?tileWidth.value:tileHeight.value),backwardSize=visibleSize;for(;start>0&&backwardSize=contSize));i++);let overflowCount=0;for(let i=end+1;i(openBlock(),createElementBlock(`div`,_hoisted_1$316,[toolbar.value.enabled?withDirectives((openBlock(),createElementBlock(`div`,_hoisted_2$257,[toolbar.value.path?(openBlock(),createBlock(Teleport,{key:0,disabled:!__props.pathTarget,to:__props.pathTarget},[createVNode(unref(bngBreadcrumbs_default),{ref_key:`elPath`,ref:elPath,items:__props.path,limit:__props.pathLimit,blur:!__props.noBackground,onClick:_cache[0]||=itm=>emit$1(`pathClick`,itm)},null,8,[`items`,`limit`,`blur`])],8,[`disabled`,`to`])):(openBlock(),createElementBlock(`div`,_hoisted_3$224)),toolbar.value.layout?(openBlock(),createBlock(Teleport,{key:2,disabled:!__props.layoutSelectorTarget,to:__props.layoutSelectorTarget},[createBaseVNode(`div`,_hoisted_4$192,[createVNode(unref(bngButton_default),{accent:layoutSelected.value===LIST_LAYOUTS.TILES?unref(ACCENTS).outlined:unref(ACCENTS).text,icon:unref(icons).tiles,onClick:_cache[1]||=$event=>layoutSelected.value=LIST_LAYOUTS.TILES},null,8,[`accent`,`icon`]),createVNode(unref(bngButton_default),{accent:layoutSelected.value===LIST_LAYOUTS.LIST?unref(ACCENTS).outlined:unref(ACCENTS).text,icon:unref(icons).listSmall,onClick:_cache[2]||=$event=>layoutSelected.value=LIST_LAYOUTS.LIST},null,8,[`accent`,`icon`])])],8,[`disabled`,`to`])):createCommentVNode(``,!0)],512)),[[vShow,toolbar.value.show]]):createCommentVNode(``,!0),withDirectives((openBlock(),createElementBlock(`div`,{ref_key:`elCont`,ref:elCont,class:normalizeClass({"list-content":!0,"list-with-background":!__props.noBackground,[`list-layout-${layoutSelected.value}`]:!0,"list-item-width":!!tileWidth.value,"list-item-height":!!tileHeight.value,"list-item-margin":!!tileMargin.value,"list-title-width":!!titleWidth.value,"list-title-height":!!titleHeight.value,"list-title-margin":!!titleMargin.value,"list-big":bigmode.enabled,"list-scrolling":scrolling.value||bigmode.debounce===0,"list-processing":processing.value}),style:normalizeStyle({"--list-item-width":`${tileWidth.value}px`,"--list-item-height":`${tileHeight.value}px`,"--list-item-margin":`${tileMargin.value}px`,"--list-title-width":`${titleWidth.value}px`,"--list-title-height":`${titleHeight.value}px`,"--list-title-margin":`${titleMargin.value}px`,"--list-big-full":`${bigmode.full}px`}),onScroll:onScrollDebounce},[createBaseVNode(`div`,{ref_key:`elSize`,ref:elSize,class:`list-content-size-observer`},null,512),bigmode.enabled&&bigmode.skeleton?(openBlock(),createElementBlock(`div`,{key:0,ref_key:`elSkeleton`,ref:elSkeleton,class:`list-skeleton`},[(openBlock(!0),createElementBlock(Fragment,null,renderList(skeletonItems.value,(isTitle,i)=>(openBlock(),createElementBlock(`div`,{key:`skeleton-${i}`,class:normalizeClass({"skeleton-item":!0,"skeleton-title":isTitle})},null,2))),128))],512)):createCommentVNode(``,!0),createBaseVNode(`div`,{class:`list-items`,style:normalizeStyle(listItemsStyle.value)},[(openBlock(!0),createElementBlock(Fragment,null,renderList(itemsView.value,vnode=>(openBlock(),createBlock(resolveDynamicComponent(vnode),{key:vnode.key,style:normalizeStyle(vnode.keepAliveStyle)},null,8,[`style`]))),128))],4)],38)),[[unref(BngBlur_default),!__props.noBackground]])]))}},bngList_default=__plugin_vue_export_helper_default(_sfc_main$361,[[`__scopeId`,`data-v-5af5eff2`]]),_hoisted_1$315={class:`bng-stars`},_hoisted_2$256={key:0,class:`stars`},_hoisted_3$223=[`innerHTML`],_hoisted_4$191=[`innerHTML`],_hoisted_5$163={key:1,class:`stars`},_hoisted_6$140={class:`stars-label`},_hoisted_7$122=[`innerHTML`],_sfc_main$360={__name:`bngMainStars`,props:{unlockedStars:{type:Number,default:0,validator:val=>val>=0},totalStars:{type:Number,default:1},scale:{type:Number,default:1},individualStars:{type:Object,default:null,validator:val=>val===null||Array.isArray(val)},numerical:{type:Boolean,default:!1}},setup(__props){useCssVars(_ctx=>({v3c930dd6:fontSize.value}));let props=__props,fontSize=computed(()=>`${props.scale}rem`),starsTotal=computed(()=>props.individualStars?props.individualStars.length:props.totalStars),starsFilled=computed(()=>props.individualStars?props.individualStars.filter(Boolean).length:props.unlockedStars),starsUnfilled=computed(()=>starsTotal.value-starsFilled.value),glyphsFilled=computed(()=>starsFilled.value>0?icons.star.glyph.repeat(starsFilled.value):``),glyphsUnfilled=computed(()=>starsUnfilled.value>0?icons.star.glyph.repeat(starsUnfilled.value):``);return(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$315,[!__props.numerical&&__props.individualStars&&__props.individualStars.length?(openBlock(),createElementBlock(`div`,_hoisted_2$256,[starsFilled.value?(openBlock(),createElementBlock(`span`,{key:0,class:`star star-filled`,innerHTML:glyphsFilled.value},null,8,_hoisted_3$223)):createCommentVNode(``,!0),starsUnfilled.value?(openBlock(),createElementBlock(`span`,{key:1,class:`star star-unfilled`,innerHTML:glyphsUnfilled.value},null,8,_hoisted_4$191)):createCommentVNode(``,!0)])):(openBlock(),createElementBlock(`div`,_hoisted_5$163,[createBaseVNode(`div`,_hoisted_6$140,toDisplayString(starsFilled.value)+` / `+toDisplayString(starsTotal.value),1),createBaseVNode(`span`,{class:`star star-filled`,innerHTML:unref(icons).star.glyph},null,8,_hoisted_7$122)]))]))}},bngMainStars_default=__plugin_vue_export_helper_default(_sfc_main$360,[[`__scopeId`,`data-v-4ba4c794`]]),_hoisted_1$314=[`rows`,`placeholder`,`disabled`],_hoisted_2$255={key:0,class:`floating-label`},_sfc_main$359={__name:`bngMultilineInput`,props:{floatingLabel:String,externalLabel:String,placeholder:String,initialValue:String,leadingIcon:Object,trailingIcon:Object,scalable:Boolean,hasError:Boolean,errorMessage:String,lines:{type:Number,default:1},disabled:{type:Boolean,default:!1}},setup(__props){useCssVars(_ctx=>({v26daab40:bngScalableInputMaxWidth.value}));let props=__props,inputContainer=ref(null),bngMultilineInput=ref(null),focusHighlight=ref(null),leadingIconContainer=ref(null),trailingIconContainer=ref(null),value=ref(``),isInputFieldFocused=ref(!1),hasValue=computed(()=>value.value!==``&&value.value!==void 0),bngScalableInputMaxWidth=computed(()=>`${(leadingIconContainer.value?leadingIconContainer.value.offsetWidth:0)+(trailingIconContainer.value?trailingIconContainer.value.offsetWidth:0)}px`),resizeObserver;onBeforeMount(()=>{value.value=props.initialValue,resizeObserver=new ResizeObserver(onInputResize)}),onMounted(()=>{resizeObserver.observe(bngMultilineInput.value)}),onDeactivated(()=>{resizeObserver.disconnect()});function onInputFieldFocusIn(){isInputFieldFocused.value=!0}function onInputFieldFocusOut(){isInputFieldFocused.value=!1}function onInputResize(){inputContainer.value&&window.requestAnimationFrame(()=>{let focusRight=inputContainer.value.offsetWidth-inputContainer.value.offsetWidth;focusHighlight.value.style.right=`${focusRight-2}px`})}return(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,{class:normalizeClass([`input-icon-wrapper`,{scalable:__props.scalable}])},[__props.leadingIcon?(openBlock(),createElementBlock(`span`,{key:0,ref_key:`leadingIconContainer`,ref:leadingIconContainer,class:`input-icon`},[createVNode(unref(bngIcon_default),{type:__props.leadingIcon},null,8,[`type`])],512)):createCommentVNode(``,!0),createBaseVNode(`div`,{ref_key:`inputContainer`,ref:inputContainer,class:normalizeClass([`bng-multiline-input`,{"input-focused":isInputFieldFocused.value,"has-error":__props.hasError}]),tabindex:`0`},[withDirectives(createBaseVNode(`textarea`,{"onUpdate:modelValue":_cache[0]||=$event=>value.value=$event,ref_key:`bngMultilineInput`,ref:bngMultilineInput,class:normalizeClass([`input-field`,{empty:!hasValue.value,"has-value":hasValue.value,"has-error":__props.hasError,disabled:__props.disabled}]),rows:__props.lines,placeholder:__props.floatingLabel,disabled:__props.disabled,onFocusin:onInputFieldFocusIn,onFocusout:onInputFieldFocusOut},null,42,_hoisted_1$314),[[vModelText,value.value],[unref(BngTextInput_default)]]),__props.floatingLabel?(openBlock(),createElementBlock(`span`,_hoisted_2$255,toDisplayString(__props.floatingLabel),1)):createCommentVNode(``,!0),createBaseVNode(`span`,{ref_key:`focusHighlight`,ref:focusHighlight,class:`focus-highlight`},null,512)],2),__props.trailingIcon?(openBlock(),createElementBlock(`span`,{key:1,ref_key:`trailingIconContainer`,ref:trailingIconContainer,class:`input-icon`},[createVNode(unref(bngIcon_default),{type:__props.trailingIcon},null,8,[`type`])],512)):createCommentVNode(``,!0)],2))}},bngMultilineInput_default=__plugin_vue_export_helper_default(_sfc_main$359,[[`__scopeId`,`data-v-6c6cfdb8`]]);const icons$1={undefined:`undefined`,arrow:{large:{up:`arrow/large_up`,down:`arrow/large_down`,left:`arrow/large_left`,right:`arrow/large_right`},small:{up:`arrow/arrowSmallUp`,down:`arrow/arrowSmallDown`,left:`arrow/arrowSmallLeft`,right:`arrow/arrowSmallRight`}},drive:{autobahn:`drive/autobahn`,busroutes:`drive/busroutes`,campaigns:`drive/campaigns`,career:`drive/career`,freeroam:`drive/freeroam`,garage:`drive/garage`,infinity:`drive/infinity`,lightrunner:`drive/lightrunner`,m_a:`drive/m_a`,m_b:`drive/m_b`,m_c:`drive/m_c`,play:`drive/play`,quit:`drive/quit`,scenarios:`drive/scenarios`,timetrials:`drive/timetrials`},general:{offbtn:`general/offbtn`,unknown:`general/unknown`,check:`general/check`,recharge:`general/recharge`,refuel:`general/refuel`,beambuck:`general/beambuck`,money:`general/beambuck`,beamXP:`general/beamXP`,arrow_small_left:`general/arrow_small-left`,arrow_small_right:`general/arrow_small-right`,fuel_nozzle:`general/fuel-nozzle`,recharge_connector:`general/recharge-connector`,star:`general/star`,star_outlined:`general/star-secondary`,vehicle:`general/vehicle`,awd:`general/awd`,"4wd":`general/4wd`,fwd:`general/fwd`,rwd:`general/rwd`,drivetrain_special:`general/drivetrain-special`,drivetrain_generic:`general/drivetrain-generic`,charge:`general/charge`,fuel:`general/fuel`,odometer:`general/odometer`,power_gauge_01:`general/power-gauge-01c`,power_gauge_02:`general/power-gauge-02c`,power_gauge_03:`general/power-gauge-03c`,power_gauge_04:`general/power-gauge-04c`,power_gauge_05:`general/power-gauge-05c`,weight:`general/weight`,transmission_a:`general/transmission-a`,transmission_m:`general/transmission-m`},device:{keyboard:`device/keyboard`,phone_android:`device/phone_android`,wheel:`device/wheel`,gamepad:`device/gamepad`,videogame_asset:`device/videogame_asset`,mouse:{button0:`device/mouse/button0`,button1:`device/mouse/button1`,button2:`device/mouse/button2`,xaxis:`device/mouse/xaxis`,yaxis:`device/mouse/yaxis`,zaxis:`device/mouse/zaxis`},xbox:{btn_a:`device/xbox/btn_a`,btn_b:`device/xbox/btn_b`,btn_back:`device/xbox/btn_back`,btn_lb:`device/xbox/btn_lb`,btn_lt:`device/xbox/btn_lt`,btn_rb:`device/xbox/btn_rb`,btn_rt:`device/xbox/btn_rt`,btn_start:`device/xbox/btn_start`,btn_x:`device/xbox/btn_x`,btn_y:`device/xbox/btn_y`,btn_dpad_default_filled:`device/xbox/btn_dpad_default_filled`,btn_dpad_default_outline:`device/xbox/btn_dpad_default_outline`,btn_dpad_down:`device/xbox/btn_dpad_down`,btn_dpad_left:`device/xbox/btn_dpad_left`,btn_dpad_right:`device/xbox/btn_dpad_right`,btn_dpad_up:`device/xbox/btn_dpad_up`,btn_thumb_left:`device/xbox/btn_thumb_left`,btn_thumb_left_x:`device/xbox/btn_thumb_left_x`,btn_thumb_left_y:`device/xbox/btn_thumb_left_y`,btn_thumb_right:`device/xbox/btn_thumb_right`,btn_thumb_right_x:`device/xbox/btn_thumb_right_x`,btn_thumb_right_y:`device/xbox/btn_thumb_right_y`}},decals:{camera:{back:`decals/camera/back`,freecam:`decals/camera/freecam`,front:`decals/camera/front`,left:`decals/camera/left`,right:`decals/camera/right`,top:`decals/camera/top`},general:{change_order:`decals/general/change_order`,deform:`decals/general/deform`,delete:`decals/general/delete`,duplicate:`decals/general/duplicate`,hide:`decals/general/hide`,lock:`decals/general/lock`,mirror:`decals/general/mirror`,options:`decals/general/options`,redo:`decals/general/redo`,rename:`decals/general/rename`,save:`decals/general/save`,transform:`decals/general/transform`,undo:`decals/general/undo`,unlock:`decals/general/unlock`,use_mask:`decals/general/mask`},group:{group:`decals/group/group`,ungroup:`decals/group/ungroup`},layer:{decal:`decals/layer/decal`,material:`decals/layer/material`},mirror:{copy_mirrored:`decals/mirror/copy_mirrored`,copy_straight:`decals/mirror/copy_straight`}}},iconTypesList=makeIconTypesList(icons$1);function makeIconTypesList(dict){let key,all=[];for(key in dict)all=all.concat(typeof dict[key]==`string`?dict[key]:makeIconTypesList(dict[key]));return all}var _hoisted_1$313=[`src`],_sfc_main$358={__name:`bngOldIcon`,props:{type:{type:String,validator:v=>iconTypesList.includes(v)},span:{type:Boolean,default:!0},mask:{type:Boolean,default:!0},color:String},setup(__props){let props=__props,iconImageURL=computed(()=>getAssetURL(`icons/${props.type}.svg`)),spanStyle=computed(()=>({[props.mask?`maskImage`:`backgroundImage`]:`url(${iconImageURL.value})`,backgroundColor:props.color||`#fff`}));return(_ctx,_cache)=>__props.span?(openBlock(),createElementBlock(`span`,{key:0,class:`bngicon`,style:normalizeStyle(spanStyle.value)},[renderSlot(_ctx.$slots,`default`,{},void 0,!0)],4)):(openBlock(),createElementBlock(`img`,{key:1,class:`bngicon`,src:iconImageURL.value,alt:``},null,8,_hoisted_1$313))}},bngOldIcon_default=__plugin_vue_export_helper_default(_sfc_main$358,[[`__scopeId`,`data-v-da0e0a74`]]),_hoisted_1$312=[`bng-no-child-nav`],scrollBuildupTime=3e3,scrollMaxSpeedModifier=4,CLICKID=`__bngOverflowContainer`,_sfc_main$357={__name:`bngOverflowContainer`,props:{scrollSpeed:{type:Number,default:5},initialIndex:{type:Number,default:-1},useBindings:[Boolean,Array],useBindingsOnly:[Boolean,Array],showBindings:{type:Boolean,default:!0},showArrows:{type:Boolean,default:!1},noWheel:{type:Boolean,default:!1}},setup(__props,{expose:__expose}){let slots=useSlots(),props=__props,useBindings=props.useBindings||props.useBindingsOnly,useBindingsOnly=props.useBindingsOnly;watch([()=>props.useBindings,()=>props.useBindingsOnly],()=>console.warn(`useBindings and useBindingsOnly can only be set at component mount time`));let uinavBound=!1,focusNav=useBindings&&Array.isArray(useBindings)?useBindings:[`tab_l`,`tab_r`],elBindPrev=ref(null),elBindNext=ref(null),elCont=ref(null),scrollContainer=ref(null),showLeftFade=ref(!1),showRightFade=ref(!1),resizeObserver=new ResizeObserver(updateFadeVisibility),scrollInterval=null,scrollTime=0,lastActive=null,fixingActive=!1;function setActive(elm){clearActive(),elm instanceof Element&&(elm.setAttribute(`active`,`true`),lastActive=elm)}function clearActive(evt){lastActive&&(evt&&(evt.detail?.target||evt.target)===lastActive||(lastActive.removeAttribute(`active`),lastActive=null))}function fixActive(evt){if(fixingActive||useBindings&&evt.type===`focusin`)return;let active=evt.detail?.target||evt.target||document.activeElement;if(active.matches(`[is-bng-panel], [bng-nav-item], [ng-click], [href], [bng-all-clicks], [bng-all-clicks-no-nav], [ui-sref], input, textarea, button, md-option, md-slider, md-select, md-checkbox`)||(active=active.closest(NAVIGABLE_ELEMENTS_SELECTOR)),scrollContainer.value.contains(active)&&!(lastActive&&(lastActive===active||lastActive.contains(active)))){if(useBindingsOnly){fixingActive=!0;let prev=evt.detail.relatedTarget||evt.relatedTarget;prev&&scrollContainer.value.contains(prev)&&(prev=null),prev?setFocusExternal(prev,!0):setFocusExternal(active,!1)}nextTick(()=>{setActive(active),fixingActive=!1})}}let firstTime=!0;function updateContents(){if(!scrollContainer.value)return;let elFirst;for(let elm of scrollContainer.value.children)firstTime&&!elFirst&&(elFirst=elm),!elm[CLICKID]&&(elm[CLICKID]=!0,elm.addEventListener(`click`,fixActive));firstTime&&elFirst&&props.initialIndex>-1&&(firstTime=!1,elFirst.matches(`[is-bng-panel], [bng-nav-item], [ng-click], [href], [bng-all-clicks], [bng-all-clicks-no-nav], [ui-sref], input, textarea, button, md-option, md-slider, md-select, md-checkbox`)||(elFirst=elFirst.querySelector(NAVIGABLE_ELEMENTS_SELECTOR)),elFirst&&activate(elFirst))}watch([()=>slots.default?.(),()=>scrollContainer.value],()=>nextTick(updateContents),{immediate:!0});function navContents(dir,fireClick=!1){let links=collectRects(dir,scrollContainer.value,useBindingsOnly),prev=lastActive;clearActive();let res;if(useBindingsOnly){let idx=links[dir].findIndex(link=>link.dom===prev);idx>-1?res=links[dir][dir===`right`?idx+1:idx-1]:idx===0&&dir===`left`?res=links[dir][links[dir].length-1]:idx===links[dir].length-1&&dir===`right`&&(res=links[dir][0]),res&&(setActive(res.dom),scrollFix(res,dir))}else prev&&(res=navigate(links,dir,prev),res&&setActive(res));res?fireClick&&(res.dom&&(res=res.dom),nextTick(()=>res?.dispatchEvent(new Event(`click`)))):(scrollContainer.value.scrollTo({left:dir===`right`?0:scrollContainer.value.clientWidth,behavior:`instant`}),nextTick(()=>{let elms$4=collectRects(`right`,scrollContainer.value,!0).right;dir===`left`&&elms$4.reverse(),res=elms$4[0],res&&(setActive(res.dom),useBindingsOnly?scrollFix(res,dir):setFocusExternal(res.dom),fireClick&&res.dom.dispatchEvent(new Event(`click`)))}))}let activatePrev=()=>navContents(`left`,!0),activateNext=()=>navContents(`right`,!0);function activate(indexOrElement){let elm;if(typeof indexOrElement==`number`){let elms$4=scrollContainer.value.querySelectorAll(NAVIGABLE_ELEMENTS_SELECTOR);indexOrElement<0&&(indexOrElement=elms$4.length+indexOrElement),elm=elms$4[indexOrElement]}else if(indexOrElement instanceof Element)elm=indexOrElement;else throw Error(`Invalid argument`);if(!elm)throw Error(`Element not found`);scrollFix({dom:elm,rect:elm.getBoundingClientRect()},`right`),setActive(elm),!useBindingsOnly&&setFocusExternal(elm)}if(__expose({scrollBy:amount=>scrollContainer.value?.scrollBy({left:amount,behavior:`smooth`}),activatePrev,activateNext,activate,deactivate:()=>{let active=document.activeElement,activeCorrect=active&&active===lastActive;clearActive(),activeCorrect&&(useBindingsOnly&&setFocusExternal(active,!1),active.blur?.())},refresh:(withActivation=!1)=>{withActivation&&(firstTime=!0),updateContents()}}),useBindings){let instance$1=getCurrentInstance(),contUnwatch=watch(()=>elCont.value,elm=>{elm&&(contUnwatch(),nextTick(()=>{uinavBound=!0;let vnode={ctx:instance$1,el:elm};BngOnUiNav_default.mounted(elm,{arg:focusNav[0],modifiers:{},value:activatePrev},vnode),BngOnUiNav_default.mounted(elm,{arg:focusNav[1],modifiers:{},value:activateNext},vnode),elm.addEventListener(`focusin`,fixActive)}))},{immediate:!0})}watch(scrollContainer,elm=>{elm&&(updateFadeVisibility(),resizeObserver.observe(elm))},{immediate:!0});function updateFadeVisibility(){if(!scrollContainer.value)return;let{scrollLeft,scrollWidth,clientWidth}=scrollContainer.value;showLeftFade.value=scrollLeft>0,showRightFade.value=scrollLeft{let speedModifier=Math.min(1+(scrollMaxSpeedModifier-1)*(scrollTime/scrollBuildupTime),scrollMaxSpeedModifier),scrollAmount=(direction$1===`left`?-props.scrollSpeed:props.scrollSpeed)*speedModifier;scrollContainer.value.scrollLeft+=scrollAmount,updateFadeVisibility(),scrollTime+=1e3/30},1e3/30)}function stopScrolling(){scrollInterval&&=(clearInterval(scrollInterval),null),scrollTime=0}function onWheel(evt){props.noWheel||(evt.preventDefault(),scrollContainer.value.scrollLeft+=evt.deltaY,updateFadeVisibility())}function onScroll(){updateFadeVisibility()}return onBeforeUnmount(()=>{resizeObserver.disconnect(),stopScrolling(),uinavBound&&(BngOnUiNav_default.beforeUnmount(elCont.value),elCont.value.removeEventListener(`focusin`,fixActive))}),(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,{ref_key:`elCont`,ref:elCont,class:normalizeClass([`bng-overflow-container`,{"with-bindings":unref(useBindings)&&(elBindPrev.value?.displayed||elBindNext.value?.displayed),"with-arrows":__props.showArrows&&!(elBindPrev.value?.displayed||elBindNext.value?.displayed),"hide-bindings":!__props.showBindings}]),onWheel},[withDirectives(createBaseVNode(`div`,{class:`fade-left`,onMouseenter:_cache[0]||=$event=>startScrolling(`left`),onMouseleave:stopScrolling},null,544),[[vShow,showLeftFade.value]]),withDirectives(createBaseVNode(`div`,{class:`fade-right`,onMouseenter:_cache[1]||=$event=>startScrolling(`right`),onMouseleave:stopScrolling},null,544),[[vShow,showRightFade.value]]),__props.showArrows&&!elBindPrev.value?.displayed?(openBlock(),createBlock(unref(bngIcon_default),{key:0,type:unref(icons).arrowLargeLeft,class:`hint-prev`},null,8,[`type`])):createCommentVNode(``,!0),__props.showArrows&&!elBindNext.value?.displayed?(openBlock(),createBlock(unref(bngIcon_default),{key:1,type:unref(icons).arrowLargeRight,class:`hint-next`},null,8,[`type`])):createCommentVNode(``,!0),unref(useBindings)?(openBlock(),createBlock(unref(bngBinding_default),{key:2,ref_key:`elBindPrev`,ref:elBindPrev,class:`hint-prev`,"ui-event":unref(focusNav)[0],controller:``},null,8,[`ui-event`])):createCommentVNode(``,!0),unref(useBindings)?(openBlock(),createBlock(unref(bngBinding_default),{key:3,ref_key:`elBindNext`,ref:elBindNext,class:`hint-next`,"ui-event":unref(focusNav)[1],controller:``},null,8,[`ui-event`])):createCommentVNode(``,!0),createBaseVNode(`div`,{ref_key:`scrollContainer`,ref:scrollContainer,class:`scroll-container`,"bng-no-child-nav":unref(useBindingsOnly),onScroll},[renderSlot(_ctx.$slots,`default`,{},void 0,!0)],40,_hoisted_1$312)],34))}},bngOverflowContainer_default=__plugin_vue_export_helper_default(_sfc_main$357,[[`__scopeId`,`data-v-24544cbf`]]);const rainbow=(numOfSteps,step)=>{let r,g,b,h$1=step/numOfSteps,i=~~(h$1*6),f=h$1*6-i,q=1-f;switch(i%6){case 0:[r,g,b]=[1,f,0];break;case 1:[r,g,b]=[q,1,0];break;case 2:[r,g,b]=[0,1,f];break;case 3:[r,g,b]=[0,q,1];break;case 4:[r,g,b]=[f,0,1];break;case 5:[r,g,b]=[1,0,q];break}return[r,g,b]},hueToRGB=(p$1,q,t)=>(t<0&&(t+=1),t>1&&--t,t<1/6?p$1+(q-p$1)*6*t:t<1/2?q:t<2/3?p$1+(q-p$1)*(2/3-t)*6:p$1),HSLToRGB=(h$1,s,l)=>{let r,g,b;if(s===0)r=g=b=l;else{let q=l<.5?l*(1+s):l+s-l*s,p$1=2*l-q;r=hueToRGB(p$1,q,h$1+1/3),g=hueToRGB(p$1,q,h$1),b=hueToRGB(p$1,q,h$1-1/3)}return[r,g,b]},RGBToHSL=(r,g,b)=>{let vmax=Math.max(r,g,b),vmin=Math.min(r,g,b),h$1,s,l=(vmax+vmin)/2;if(vmax===vmin)return[0,0,l];let d=vmax-vmin;return s=l>.5?d/(2-vmax-vmin):d/(vmax+vmin),vmax===r&&(h$1=(g-b)/d+(gnum;else if(val<=15){let prec=10**val;this._precision=num=>~~(num*prec)/prec}else throw TypeError(`Precision can't go higher than 15`)}_sync({hsl=!1,rgb=!1}={}){if(hsl&&rgb)throw Error(`Cannot set both HSL and RGB changes at once`);this._dirty.hsl&&!hsl?this._rgb=HSLToRGB(...this._hsl):this._dirty.rgb&&!rgb&&(this._hsl=RGBToHSL(...this._rgb)),this._dirty.hsl=hsl,this._dirty.rgb=rgb}_parse(val){let res;if(isProxy(val)&&(val=toRaw(val)),typeof val==`string`&&(val=val.split(` `)),typeof val==`object`&&Array.isArray(val)){if(val.length<3)throw Error(`Invalid colour array length`);val.length===3&&(val=[...val,1]),val=val.map(Number);for(let num of val)if(isNaN(num))throw Error(`Values must be numbers`);res=val}if(!res)throw Error(`Color must be either an array or a string`);return res}get hslString(){return this.hsl.join(` `)}get hslaString(){return this.hsla.join(` `)}get rgbString(){return this.rgb.join(` `)}get rgbaString(){return this.rgba.join(` `)}get saturationPercent(){return Math.round(this.saturation*100)}get luminosityPercent(){return Math.round(this.luminosity*100)}get alphaPercent(){return Math.round(this._alpha*50)}get metallicPercent(){return Math.round(this._metallic*100)}get roughnessPercent(){return Math.round(this._roughness*100)}get clearcoatPercent(){return Math.round(this._clearcoat*100)}get clearcoatRoughnessPercent(){return Math.round(this._clearcoatRoughness*100)}get paint(){return[...this._legacy?this.rgba:this.rgb,this.metallic,this.roughness,this.clearcoat,this.clearcoatRoughness].map(this._precision)}get paintString(){return this.paint.join(` `)}get paintObject(){return this._paintObjectNames.reduce((res,name)=>({...res,[name]:this[name]}),{})}set paint(val){let data;if(isProxy(val)&&(val=toRaw(val)),typeof val==`object`){if(!Array.isArray(val)){data={...val};let names=this._paintObjectNames;for(let name of names){if(name===`baseColor`){this.baseColor=name in data?data[name]:[1,1,1,1];continue}let num=0;name in data&&(num=Number(data[name]),isNaN(num)&&(num=0)),this[name]=num}return}data=val}else if(typeof val==`string`)data=val.split(` `);else throw TypeError(`Invalid data type`);if(data.length===8)this.rgba=data.slice(0,4);else if(data.length===7)this.rgb=data.slice(0,3);else throw TypeError(`Invalid data value`);[this._metallic,this._roughness,this._clearcoat,this._clearcoatRoughness]=data.slice(-4)}get metallic(){return this._precision(this._metallic)}set metallic(val){this._metallic=Number(val)}get roughness(){return this._precision(this._roughness)}set roughness(val){this._roughness=Number(val)}get clearcoat(){return this._precision(this._clearcoat)}set clearcoat(val){this._clearcoat=Number(val)}get clearcoatRoughness(){return this._precision(this._clearcoatRoughness)}set clearcoatRoughness(val){this._clearcoatRoughness=Number(val)}get alpha(){return this._precision(this._alpha)}set alpha(val){let type=typeof val;type!==`undefined`&&(type===`number`?this._alpha=val:this._alpha=Number(val))}get hsl(){return this._sync(),this._hsl.map(this._precision)}set hsl(val){let arr=this._parse(val);this._sync({hsl:!0}),this._hsl=arr.slice(0,3),this.alpha=arr[3]}get rgb(){return this._sync(),this._rgb.map(this._precision)}get rgb255(){return this.rgb.map(val=>Math.round(val*255))}set rgb(val){let arr=this._parse(val);this._sync({rgb:!0}),this._rgb=arr.slice(0,3),this.alpha=arr[3]}set rgb255(val){let arr=this._parse(val);this.rgb=[...arr.slice(0,3).map(val$1=>val$1/255),arr[3]]}get hsla(){return[...this.hsl,this.alpha]}set hsla(val){this.hsl=val}get rgba(){return[...this.rgb,this.alpha]}set rgba(val){this.rgb=val}get baseColor(){return this.rgba}set baseColor(val){this.rgba=val}get hue(){return this.hsl[0]}get hue360(){return this.hsl[0]*360}set hue(val){this._sync({hsl:!0}),this._hsl[0]=Number(val)}set hue360(val){this.hue=Number(val)/360}get saturation(){return this.hsl[1]}set saturation(val){this._sync({hsl:!0}),this._hsl[1]=Number(val)}get luminosity(){return this.hsl[2]}set luminosity(val){this._sync({hsl:!0}),this._hsl[2]=Number(val)}get red(){return this.rgb[0]}get red255(){return this.rgb[0]*255}set red(val){this._sync({rgb:!0}),this._rgb[0]=Number(val)}set red255(val){this.red=Number(val)/255}get green(){return this.rgb[1]}get green255(){return this.rgb[1]*255}set green(val){this._sync({rgb:!0}),this._rgb[1]=Number(val)}set green255(val){this.green=Number(val)/255}get blue(){return this.rgb[2]}get blue255(){return this.rgb[2]*255}set blue(val){this._sync({rgb:!0}),this._rgb[2]=Number(val)}set blue255(val){this.blue=Number(val)/255}static anyToArray(val,legacy=!1){if(Array.isArray(val)){let checks=[val$1=>val$1 instanceof Paint,val$1=>typeof val$1==`object`&&Array.isArray(val$1.baseColor),val$1=>typeof val$1==`string`&&val$1.split(` `).length>=7,val$1=>Array.isArray(val$1)&&val$1.length>=7];if(val.some(item=>checks.some(check=>check(item))))return val.map(item=>Paint.anyToArray(item,legacy))}let precision=val$1=>{let num=Number(val$1);return isNaN(num)?val$1:~~(num*1e4)/1e4};return Array.isArray(val)?val.map(precision):typeof val==`string`?val.split(` `).map(precision):val instanceof Paint?val.paint:typeof val==`object`&&val.baseColor?[...legacy?val.baseColor:val.baseColor.slice(0,3),val.metallic,val.roughness,val.clearcoat,val.clearcoatRoughness].map(precision):val}static hslCssStr(arr){return`${Math.round(arr[0]*360)}, ${Math.round(arr[1]*100)}%, ${Math.round(arr[2]*100)}%`}static rgbToHsl(rgb){return RGBToHSL(...rgb)}static hslToRgb(hsl){return HSLToRGB(...hsl)}},CACHE_LIMIT=200,TILE_SIZE=64,MULTI_ANGLE=23,MAX_CONCURRENT_RENDERS=20,QUEUE_INTERVAL=10,reflectionImageUrl=`/ui/ui-vue/src/assets/images/paint-reflection.jpg`,reflectionImage=null,reflectionImageDone=!1,renderCancelledError=Error(`Render cancelled`),cacheCleanedError=Error(`Cache cleared`);function hashPaintData(paintData){return paintData?(paintData=Paint.anyToArray(paintData,!1),Array.isArray(paintData)?Array.isArray(paintData[0])?paintData.map(paint=>Array.isArray(paint)?paint.join(`,`):``).join(`|`):paintData.join(`,`):JSON.stringify(paintData)):``}var checkMultipaint=paintData=>Array.isArray(paintData)&&paintData.length>0&&paintData.some(item=>Array.isArray(item)&&item.length>=7);const usePaintPreviews=defineStore(`paint-previews`,()=>{let previews=ref(new Map),pendingRenders=ref(new Map),renderQueue=ref([]),activeRenders=ref(0),cacheListeners=new Set,pendingBlobCleanup=new Set,queueProcessor=null,blobCleanupTimeout=null;{let img=new Image;img.onload=()=>{reflectionImage=img,reflectionImageDone=!0},img.onerror=()=>{console.warn(`Failed to load metallic reflection image`),reflectionImageDone=!0},img.src=reflectionImageUrl}function startQueue(eager=!1){if(queueProcessor||renderQueue.value.length===0)return;let run$1=()=>{renderQueue.value.length===0?stopQueue():activeRenders.value0||activeRenders.value>0)return!1;for(let entry of previews.value.values())if(entry.blobGenerating)return!1;return!0}function blobCleanup(){blobCleanupTimeout&&clearTimeout(blobCleanupTimeout),blobCleanupTimeout=setTimeout(()=>{if(blobCleanupTimeout=null,isSystemIdle()&&pendingBlobCleanup.size>0){for(let blobUrl of pendingBlobCleanup)URL.revokeObjectURL(blobUrl);pendingBlobCleanup.clear()}},1e3)}async function processQueue({key,paintData,opts,resolve:resolve$1,reject,aborter}){activeRenders.value++;try{let checkAborted=()=>{if(aborter.signal.aborted)throw renderCancelledError};checkAborted();let width$1=opts.width||TILE_SIZE,height$1=opts.height||TILE_SIZE,areas=calculatePaintAreas(paintData,width$1,height$1),cvs=await renderPaint(paintData,width$1,height$1,opts.radialLight||!1,areas,aborter);checkAborted();let bmp=await createImageBitmap(cvs);if(previews.value.size>=CACHE_LIMIT){let oldestKey=previews.value.keys().next().value;cleanupCacheEntry(previews.value.get(oldestKey)),previews.value.delete(oldestKey)}checkAborted(),previews.value.set(key,{bitmap:bmp,paintData,paintHash:hashPaintData(paintData),areas}),resolve$1(bmp)}catch(err){err!==renderCancelledError&&reject(err)}finally{pendingRenders.value.has(key)&&pendingRenders.value.get(key).aborter===aborter&&pendingRenders.value.delete(key),activeRenders.value--}}function getCacheKey({paintId,vehicleName,paintName,width:width$1=TILE_SIZE,height:height$1=TILE_SIZE,radialLight=!1}){if(paintId)return`paint#${paintId}@${width$1}x${height$1}${radialLight?`R`:`L`}`;if(vehicleName&&paintName)return`vehicle:${vehicleName}:${paintName}@${width$1}x${height$1}${radialLight?`R`:`L`}`;throw Error(`Either paintId or vehicleName+paintName must be provided`)}function isCached(opts,paintData){try{let key=getCacheKey(opts),data=previews.value.get(key);return data?!paintData||data.paintHash===hashPaintData(paintData):!1}catch{return!1}}function getCachedPreview(opts,paintData){try{let key=getCacheKey(opts),data=previews.value.get(key);return data?data.paintHash===hashPaintData(paintData)?data.bitmap:(cleanupCacheEntry(data),previews.value.delete(key),null):null}catch{return null}}async function generatePreview(paintData,opts){let key=getCacheKey(opts),paintHash=hashPaintData(paintData);if(pendingRenders.value.has(key)){let existing=pendingRenders.value.get(key);if(existing.paintHash===paintHash)return new Promise((resolve$1,reject)=>existing.others.push({resolve:resolve$1,reject}));{existing.aborter.abort(),renderQueue.value=renderQueue.value.filter(item=>!(item.key===key&&item.aborter===existing.aborter));let aborter$1=new AbortController,others$1=[...existing.others];return pendingRenders.value.set(key,{paintHash,others:others$1,aborter:aborter$1}),new Promise((resolve$1,reject)=>{others$1.push({resolve:resolve$1,reject}),renderQueue.value.unshift({key,paintData:Paint.anyToArray(paintData),opts,resolve:result=>others$1.forEach(p$1=>p$1.resolve(result)),reject:error=>others$1.forEach(p$1=>p$1.reject(error)),aborter:aborter$1}),startQueue(!0)})}}let aborter=new AbortController,others=[];return pendingRenders.value.set(key,{paintHash,others,aborter}),new Promise((resolve$1,reject)=>{others.push({resolve:resolve$1,reject}),renderQueue.value.push({key,paintData:Paint.anyToArray(paintData),opts,resolve:result=>{others.forEach(p$1=>p$1.resolve(result))},reject:error=>{others.forEach(p$1=>p$1.reject(error))},aborter}),startQueue()})}function cleanupCacheEntry(data){data&&(data.bitmap?.close?.(),data.blobUrl&&pendingBlobCleanup.add(data.blobUrl))}function onCacheClear(callback){return cacheListeners.add(callback),()=>cacheListeners.delete(callback)}function notifyCacheCleared(type=`all`,key=null){cacheListeners.forEach(callback=>{try{callback(type,key)}catch(error){console.warn(`Cache clear listener error:`,error)}})}function clearCache(opts=void 0){if(opts)try{let key=getCacheKey(opts);if(cleanupCacheEntry(previews.value.get(key)),previews.value.delete(key),pendingRenders.value.has(key)){let req=pendingRenders.value.get(key);req.aborter.abort(),req.others.forEach(p$1=>p$1.reject(cacheCleanedError)),pendingRenders.value.delete(key)}notifyCacheCleared(`single`,key)}catch{}else stopQueue(),pendingRenders.value.forEach(req=>{req.aborter.abort(),req.others.forEach(p$1=>p$1.reject(cacheCleanedError))}),pendingRenders.value.clear(),previews.value.forEach(cleanupCacheEntry),previews.value.clear(),renderQueue.value.splice(0),activeRenders.value=0,notifyCacheCleared(`all`),startQueue();blobCleanup()}async function getPreview(paintData,opts){return getCachedPreview(opts,paintData)||await generatePreview(paintData,opts)}async function getBlobPreview(paintData,opts){let paintHash=hashPaintData(paintData),key=getCacheKey(opts),bmp=await getPreview(paintData,opts),data=previews.value.get(key);if(!data)return null;if(data.blobUrl&&data.paintHash===paintHash)return data.blobUrl;for(;data.blobGenerating;)await sleep(10);if(data.blobUrl&&data.paintHash===paintHash)return data.blobUrl;data.blobGenerating=!0;let canvas=new OffscreenCanvas(opts.width||TILE_SIZE,opts.height||TILE_SIZE);canvas.getContext(`2d`).drawImage(bmp,0,0);let blobUrl=URL.createObjectURL(await canvas.convertToBlob()),oldBlobUrl=data.blobUrl;return data.blobUrl=blobUrl,delete data.blobGenerating,oldBlobUrl&&pendingBlobCleanup.add(oldBlobUrl),previews.value.has(key)?(blobCleanup(),blobUrl):(pendingBlobCleanup.add(blobUrl),blobCleanup(),null)}function getAreas(opts){let data=previews.value.get(getCacheKey(opts));return data?data.areas:[]}return{cache:previews.value,cacheSize:computed(()=>previews.value.size),isRenderingAny:computed(()=>activeRenders.value>0||renderQueue.value.length>0),queueLength:computed(()=>renderQueue.value.length),activeRenders,isCached,clearCache,onCacheClear,getCacheKey,getPreview,getBlobPreview,getAreas,checkMultipaint,toArray:Paint.anyToArray}});async function renderPaint(paintData,width$1=TILE_SIZE,height$1=TILE_SIZE,radialLight=!1,areas=null,aborter=null){if(paintData=Paint.anyToArray(paintData),!paintData)return renderEmpty(width$1,height$1,aborter);if(checkMultipaint(paintData)){let clipData=areas||calculatePaintAreas(paintData,width$1,height$1);return renderMultipaint(paintData,width$1,height$1,clipData,radialLight,aborter)}else return paintData=Array.isArray(paintData[0])?paintData[0]:paintData,renderSinglePaint(paintData,width$1,height$1,radialLight,aborter)}function createPaint(paintData){let paint={_isEmpty:!0};if(!paintData)return paint;try{paint=new Paint({paint:paintData})}catch{}return paint}function applyAntialiasing(ctx){ctx.imageSmoothingEnabled=!0,ctx.imageSmoothingQuality=`high`,ctx.antialias=!0}function calculatePaintAreas(paintData,width$1,height$1){if(!paintData||!checkMultipaint(paintData))return[[0,0,width$1,height$1]];let paintCount=paintData.length,angle=Math.tan(MULTI_ANGLE*Math.PI/180),stripeWidth=(width$1+height$1*angle)/paintCount,overlap=.5,areas=[];for(let i=0;i0?overlap:0),topRight=startX+stripeWidth+(icoords.map((coord,i)=>coord*(i%2==0?scaleX:scaleY)));for(let i=0;igrad.addColorStop(...args))}else grad=ctx.createLinearGradient(0,0,0,height$1*.65),gradStops.forEach(args=>grad.addColorStop(...args));ctx.fillStyle=grad,ctx.fillRect(0,0,width$1,height$1),ctx.restore()}async function renderPaintLayers(ctx,paint,width$1,height$1,radialLight=!1,aborter=null){if(applyAntialiasing(ctx),ctx.fillStyle=`rgb(${(paint.rgb255||[255,255,255]).join(`, `)})`,ctx.fillRect(0,0,width$1,height$1),aborter?.signal.aborted)return;let grad=ctx.createLinearGradient(0,0,0,height$1);if(grad.addColorStop(0,`rgba(0, 0, 0, 0)`),grad.addColorStop(.65,`rgba(0, 0, 0, 0)`),grad.addColorStop(.8,`rgba(0, 0, 0, 0.15)`),grad.addColorStop(1,`rgba(0, 0, 0, 0.55)`),ctx.fillStyle=grad,ctx.fillRect(0,0,width$1,height$1),aborter?.signal.aborted)return;let metallic=Math.max(0,paint.metallic-paint.roughness/.5);if(metallic>.01){for(;!reflectionImageDone;){if(aborter?.signal.aborted)return;await sleep(10)}if(aborter?.signal.aborted)return;if(ctx.globalCompositeOperation=`multiply`,ctx.globalAlpha=metallic,reflectionImage){let scale=1,imageAspect=reflectionImage.width/reflectionImage.height,canvasAspect=width$1/height$1,drawWidth,drawHeight,offsetX=0,offsetY=0;imageAspect>canvasAspect?(drawHeight=height$1*1,drawWidth=height$1*imageAspect*1):(drawHeight=width$1/imageAspect*1,drawWidth=width$1*1),ctx.drawImage(reflectionImage,0,0,drawWidth,drawHeight)}else{ctx.strokeStyle=`rgba(255, 255, 255, 0.5)`,ctx.lineWidth=1;for(let x=-height$1;x({v889f200a:tileWidth.value,bee2d4dc:tileHeight.value}));let popover=usePopover(),props=__props,emit$1=__emit,mapId=uniqueId(`paint-tile-map`),menuId=uniqueId(`paint-tile-menu`),popMenu=ref(null),elCont=ref(null),elCanvas=ref(null),isLoading=ref(!1),isEmpty=ref(!1),hasRenderedOnce=ref(!1),paintPreviews=usePaintPreviews(),width$1=computed(()=>props.size||props.width),height$1=computed(()=>props.size||props.height),tileWidth=computed(()=>`${width$1.value}px`),tileHeight=computed(()=>`${height$1.value}px`),paints=computed(()=>props.paint?paintPreviews.toArray(props.paint):[]),isMultipaint=computed(()=>paintPreviews.checkMultipaint(paints.value)),paintNames=computed(()=>{let len=props.paint?.length||0;if(len===0)return[];let res=Array.from({length:len}).map((_,idx)=>({tooltip:[`ui.color.paint.unnamed`,{index:idx+1}],menu:[`ui.color.paint.selectOne`,{index:idx+1}],menuAdd:null}));if(props.paintNames?.length>0)for(let i=0;ihoveredPaintIndex.value=idx,tooltip=computed(()=>{let res={name:props.tooltip||props.paintName};return hoveredPaintIndex.value>-1&&paintNames.value[hoveredPaintIndex.value]&&(res.subname=paintNames.value[hoveredPaintIndex.value].tooltip),res}),customMenu=computed(()=>!props.customMenu||props.customMenu.length===0?null:props.customMenu.reduce((res,item,idx)=>item?[...res,{label:item.label||item,click:evt=>{popMenu.value?.hide?.(),nextTick(()=>{item.action?item.action(props.paint,evt):emit$1(`menu-click`,item.value||idx,props.paint,evt)})}}]:res,[])),withMenu=computed(()=>props.withMenu&&(paintAreas.value.length>1||customMenu.value)),opts=computed(()=>({paintId:props.paintId,vehicleName:props.vehicleName,paintName:props.paintName,width:width$1.value,height:height$1.value,radialLight:props.radialLight})),cacheKey=computed(()=>{try{return paintPreviews.getCacheKey(opts.value)}catch{return null}}),paintAreas=computed(()=>{if(!props.paint||isEmpty.value)return[];try{return paintPreviews.getAreas(opts.value)}catch{return[]}}),onContClick=evt=>onClick(-1,evt),onContRMB=()=>withMenu.value&&openMenu();function onClick(idx,evt){popMenu.value?.hide?.(),!props.disabled&&emit$1(`click`,idx,props.paint,evt)}function openMenu(){!elCont.value||!popMenu.value||(popover.hideAll(`paint-tile-menu`),!props.disabled&&popMenu.value.show(elCont.value))}async function renderPreview(){if(!cacheKey.value||!props.paint){isEmpty.value=!0,hasRenderedOnce.value=!1;return}isLoading.value=!0,isEmpty.value=!1;try{let bmp=await paintPreviews.getPreview(paints.value,opts.value);if(elCanvas.value&&bmp){let ctx=elCanvas.value.getContext(`2d`);ctx.clearRect(0,0,width$1.value,height$1.value),ctx.drawImage(bmp,0,0,width$1.value,height$1.value),hasRenderedOnce.value=!0}}catch(error){console.error(`Failed to render preview`,error),isEmpty.value=!0,hasRenderedOnce.value=!1}finally{isLoading.value=!1}}function checkEmpty(){if(!props.paint)return isEmpty.value=!0,hasRenderedOnce.value=!1,!0;if(isMultipaint.value){let allEmpty=paints.value.every(paintArray=>!paintArray||paintArray.length===0);return isEmpty.value=allEmpty,allEmpty&&(hasRenderedOnce.value=!1),allEmpty}return Array.isArray(paints.value)&&paints.value.length===0?(isEmpty.value=!0,hasRenderedOnce.value=!1,!0):(isEmpty.value=!1,!1)}watch(()=>[paints.value,props.paintId,props.vehicleName,props.paintName,width$1.value,height$1.value,props.radialLight],()=>{checkEmpty()?isLoading.value=!1:renderPreview()},{immediate:!0,deep:!0}),watch(()=>props.withAreas,val=>{val||(hoveredPaintIndex.value=-1)});let unsubscribeFromCacheClear=null,outEvents=[`click`,`contextmenu`,`uinav-focus`],listeningOutEvents=!1;function outOfMenu(evt){if(!popMenu.value||!popMenu.value.isShown())return;let el=popMenu.value.getElement();el&&el.contains(evt.detail?.target||evt.target)||nextTick(()=>popMenu.value.hide?.())}return watch(()=>popover.popovers[menuId]?.show,val=>{val?listeningOutEvents||(listeningOutEvents=!0,outEvents.forEach(evt=>document.addEventListener(evt,outOfMenu))):listeningOutEvents&&(listeningOutEvents=!1,outEvents.forEach(evt=>document.removeEventListener(evt,outOfMenu)))}),onMounted(()=>{!checkEmpty()&&renderPreview(),unsubscribeFromCacheClear=paintPreviews.onCacheClear((type,key)=>{(type===`all`||type===`single`&&key===cacheKey.value)&&!checkEmpty()&&hasRenderedOnce.value&&renderPreview()})}),onUnmounted(()=>{unsubscribeFromCacheClear?.(),listeningOutEvents&&outEvents.forEach(evt=>document.removeEventListener(evt,outOfMenu))}),(_ctx,_cache)=>withDirectives((openBlock(),createElementBlock(`div`,{ref_key:`elCont`,ref:elCont,class:normalizeClass([`bng-paint-tile`,{loading:isLoading.value&&!hasRenderedOnce.value,empty:isEmpty.value}]),tabindex:`0`,"bng-nav-item":``,onClick:withModifiers(onContClick,[`stop`]),onContextmenu:withModifiers(onContRMB,[`stop`])},[createBaseVNode(`canvas`,{ref_key:`elCanvas`,ref:elCanvas,width:width$1.value,height:height$1.value},null,8,_hoisted_1$311),__props.withAreas&&paintAreas.value.length>1?(openBlock(),createElementBlock(Fragment,{key:0},[createBaseVNode(`img`,{usemap:`#${unref(mapId)}`,src:unref(emptyImage),alt:``},null,8,_hoisted_2$254),createBaseVNode(`map`,{name:unref(mapId)},[(openBlock(!0),createElementBlock(Fragment,null,renderList(paintAreas.value,(area,index)=>(openBlock(),createElementBlock(`area`,{key:index,shape:`poly`,coords:area.join(`,`),onMouseover:$event=>onMouseOver(index),onMouseleave:_cache[0]||=$event=>onMouseOver(-1),onClick:withModifiers($event=>onClick(index,$event),[`stop`])},null,40,_hoisted_4$190))),128))],8,_hoisted_3$222)],64)):createCommentVNode(``,!0),isEmpty.value||isLoading.value&&!hasRenderedOnce.value?(openBlock(),createElementBlock(`div`,_hoisted_5$162)):createCommentVNode(``,!0),withMenu.value?(openBlock(),createBlock(unref(bngPopoverMenu_default),{key:2,ref_key:`popMenu`,ref:popMenu,name:unref(menuId),focus:``},{default:withCtx(()=>[paintNames.value.length>1?(openBlock(),createElementBlock(Fragment,{key:0},[withDirectives((openBlock(),createBlock(unref(bngButton_default),{accent:unref(ACCENTS).menu,onClick:_cache[1]||=$event=>onClick(-1,$event)},{default:withCtx(()=>[createTextVNode(toDisplayString(_ctx.$tt(`ui.color.paint.selectAll`)),1)]),_:1},8,[`accent`])),[[unref(BngOnUiNav_default),void 0,`ok`,{focusRequired:!0,asMouse:!0}]]),(openBlock(!0),createElementBlock(Fragment,null,renderList(paintNames.value,(paint,index)=>withDirectives((openBlock(),createBlock(unref(bngButton_default),{key:index,accent:unref(ACCENTS).menu,onClick:$event=>onClick(index,$event)},{default:withCtx(()=>[createTextVNode(toDisplayString(_ctx.$tt(...paintNames.value[index].menu))+toDisplayString(paintNames.value[index].menuAdd?`: `+paintNames.value[index].menuAdd:``),1)]),_:2},1032,[`accent`,`onClick`])),[[unref(BngOnUiNav_default),void 0,`ok`,{focusRequired:!0,asMouse:!0}]])),128))],64)):withDirectives((openBlock(),createBlock(unref(bngButton_default),{key:1,accent:unref(ACCENTS).menu,onClick:_cache[2]||=$event=>onClick(0,$event)},{default:withCtx(()=>[createTextVNode(toDisplayString(_ctx.$tt(`ui.color.paint.select`)),1)]),_:1},8,[`accent`])),[[unref(BngOnUiNav_default),void 0,`ok`,{focusRequired:!0,asMouse:!0}]]),customMenu.value?.length>0?(openBlock(!0),createElementBlock(Fragment,{key:2},renderList(customMenu.value,(item,index)=>withDirectives((openBlock(),createBlock(unref(bngButton_default),{key:index,accent:unref(ACCENTS).menu,onClick:$event=>item.click($event)},{default:withCtx(()=>[createTextVNode(toDisplayString(_ctx.$tt(item.label)),1)]),_:2},1032,[`accent`,`onClick`])),[[unref(BngOnUiNav_default),void 0,`ok`,{focusRequired:!0,asMouse:!0}]])),128)):createCommentVNode(``,!0)]),_:1},8,[`name`])):createCommentVNode(``,!0)],34)),[[unref(BngTooltip_default),_ctx.$tt(tooltip.value.name)+(tooltip.value.subname?` - `+_ctx.$tt(...tooltip.value.subname):``),__props.tooltipPosition],[unref(BngOnUiNav_default),void 0,`ok`,{asMouse:!0,focusRequired:!0}]])}},bngPaintTile_default=__plugin_vue_export_helper_default(_sfc_main$356,[[`__scopeId`,`data-v-25bf2552`]]),_hoisted_1$310=[`tabindex`],_sfc_main$355={__name:`bngPill`,props:{marked:{type:Boolean,default:!1}},setup(__props){let props=__props,attrs=useAttrs(),hasClickEvent=computed(()=>attrs&&attrs.onClick),isMarked=ref(props.marked);return watch(()=>props.marked,newValue=>isMarked.value=newValue),(_ctx,_cache)=>(openBlock(),createElementBlock(`span`,{"bng-nav-item":``,class:normalizeClass([`bng-pill`,{"pill-marked":isMarked.value,"pill-clickable":hasClickEvent.value}]),tabindex:hasClickEvent.value?0:-1},[renderSlot(_ctx.$slots,`default`,{},void 0,!0)],10,_hoisted_1$310))}},bngPill_default=__plugin_vue_export_helper_default(_sfc_main$355,[[`__scopeId`,`data-v-2d28d1ed`]]),_sfc_main$354={__name:`bngPillCheckbox`,props:{modelValue:{type:Boolean,default:null},markedIcon:{type:[Boolean,Object],default:!0}},emits:[`update:modelValue`,`valueChanged`,`change`],setup(__props,{emit:__emit}){let props=__props,emit$1=__emit,defaultValue=ref(!1),isChecked=computed({get:()=>props.modelValue!==void 0&&props.modelValue!==null?props.modelValue:defaultValue.value,set:newValue=>{props.modelValue!==void 0&&props.modelValue!==null?notifyListeners(newValue):(defaultValue.value=newValue,emit$1(`valueChanged`,newValue),emit$1(`change`,newValue))}}),onChecked=()=>isChecked.value=!isChecked.value;function notifyListeners(value){emit$1(`update:modelValue`,value),emit$1(`change`,value),emit$1(`valueChanged`,value)}return(_ctx,_cache)=>(openBlock(),createElementBlock(`span`,{class:normalizeClass([`bng-pill-checkbox`,{"show-icon":isChecked.value&&props.markedIcon}])},[createVNode(unref(bngPill_default),{marked:isChecked.value,onClick:onChecked,onKeyup:withKeys(onChecked,[`space`])},{default:withCtx(()=>[createBaseVNode(`span`,{class:normalizeClass({"pill-content":!0,"uses-mark":__props.markedIcon})},[renderSlot(_ctx.$slots,`default`,{},void 0,!0)],2),createVNode(unref(bngIcon_default),{class:`pill-mark-icon`,type:props.markedIcon===!0?unref(icons).checkmark:props.markedIcon||unref(icons).checkmark},null,8,[`type`])]),_:3},8,[`marked`])],2))}},bngPillCheckbox_default=__plugin_vue_export_helper_default(_sfc_main$354,[[`__scopeId`,`data-v-04487830`]]),_hoisted_1$309={class:`bng-pill-filters`,tabindex:`0`},_sfc_main$353={__name:`bngPillFilters`,props:{modelValue:Array,options:{type:Array,required:!0},selectOnFocus:Boolean,selectMany:Boolean,showCheckIcon:{type:Boolean,default:!0},required:Boolean},emits:[`update:modelValue`,`valueChanged`],setup(__props,{expose:__expose,emit:__emit}){let props=__props,emit$1=__emit;__expose({focusPrevious,focusNext,toggleFocusedPill,focusIndex});let scrollable=ref(null),pills=ref([]),currentPillIndex=ref(-1),defaultSelected=ref([]),selectedValues=computed({get:()=>props.modelValue?props.modelValue:defaultSelected.value,set:newValue=>{props.modelValue?(emit$1(`update:modelValue`,newValue),emit$1(`valueChanged`,newValue)):(defaultSelected.value=newValue,emit$1(`valueChanged`,newValue))}}),pillConfigs=computed(()=>toRaw(props.options).map(x=>({...x,selected:selectedValues.value&&selectedValues.value.length>0&&selectedValues.value.includes(x.value)})));function focusPrevious(){currentPillIndex.value=currentPillIndex.value>0?currentPillIndex.value-1:0,pills.value[currentPillIndex.value].querySelector(`.bng-pill`).focus(),console.log(`currentPillIndex.value`,currentPillIndex.value)}function focusNext(){currentPillIndex.value{scrollable.value.addEventListener(`wheel`,evt=>{evt.preventDefault(),scrollable.value.scrollLeft+=evt.deltaY}),currentPillIndex.value=selectedValues.value.length>0?pillConfigs.value.findIndex(x=>x.value===selectedValues.value[0]):-1,currentPillIndex.value>-1&&focusPill(currentPillIndex.value)});let onPillValueChanged=(key,value)=>{props.selectOnFocus||(console.log(`onPillValueChanged`,key,value),setPillValue(key,value))},onPillFocusIn=(key,index)=>{focusPill(index),props.selectOnFocus&&setPillValue(key,!(selectedValues.value.length>0&&selectedValues.value.includes(key)))};function setPillValue(key,checked){if(currentPillIndex.value=pillConfigs.value.findIndex(x=>x.value===key),props.required&&!checked&&selectedValues.value.includes(key)&&selectedValues.value.length==1){selectedValues.value=[key];return}if(!props.selectMany){selectedValues.value=checked?[key]:[];return}let isExisting=selectedValues.value.includes(key);checked&&!isExisting?selectedValues.value=[...selectedValues.value,key]:!checked&&isExisting&&(selectedValues.value=selectedValues.value.filter(x=>x!==key))}function focusPill(index){let pillEl=pills.value[index],scrollableRect=scrollable.value.getBoundingClientRect(),pillRect=pillEl.getBoundingClientRect();pillRect.left>=scrollableRect.left&&pillRect.right<=scrollableRect.right||window.requestAnimationFrame(()=>{scrollable.value.scrollBy({left:pillEl.getBoundingClientRect().right})})}return(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$309,[createBaseVNode(`div`,{class:`pills-wrapper`,ref_key:`scrollable`,ref:scrollable},[(openBlock(!0),createElementBlock(Fragment,null,renderList(pillConfigs.value,(pill,index)=>(openBlock(),createElementBlock(`div`,{key:pill.value,ref_for:!0,ref_key:`pills`,ref:pills,class:`pill-wrapper`},[createVNode(unref(bngPillCheckbox_default),{markedIcon:__props.showCheckIcon,modelValue:pill.selected,"onUpdate:modelValue":$event=>pill.selected=$event,onValueChanged:value=>onPillValueChanged(pill.value,value),onFocusin:$event=>onPillFocusIn(pill.value,index)},{default:withCtx(()=>[createTextVNode(toDisplayString(pill.label),1)]),_:2},1032,[`markedIcon`,`modelValue`,`onUpdate:modelValue`,`onValueChanged`,`onFocusin`])]))),128))],512)]))}},bngPillFilters_default=__plugin_vue_export_helper_default(_sfc_main$353,[[`__scopeId`,`data-v-580a9eac`]]),_sfc_main$352={__name:`bngPillFiltersContainer`,props:{options:{type:Array,required:!0},selectOnNavigation:{type:Boolean,default:!0},required:Boolean,selectMany:Boolean,hasCheckedIcon:{default:!0,type:Boolean}},emits:[`update:modelValue`,`valueChanged`],setup(__props,{expose:__expose,emit:__emit}){let emit$1=__emit,props=__props,selectedItems=ref([]),bngFiltersContainer=ref(null),filtersContainer=ref(null),bngPillFiltersRef=ref(null);__expose({selectPrevious:()=>bngPillFiltersRef.value.selectPrevious(),selectNext:()=>bngPillFiltersRef.value.selectNext(),selectCurrent:()=>bngPillFiltersRef.value.selectCurrent(),focusAndScrollToSelected:focusSelected});let selectedItemId=``;onMounted(()=>{filtersContainer.value.addEventListener(`wheel`,evt=>{evt.preventDefault(),filtersContainer.value.scrollLeft+=evt.deltaY})});function focusSelected(){props.selectMany||!props.selectOnNavigation||scrollToElement(selectedItemId)}function onContainerFocusOut($event){!($event.relatedTarget&&bngFiltersContainer.value.contains($event.relatedTarget))&&!props.selectMany&&selectedItemId&&scrollToElement(selectedItemId)}function onValueChanged(items$2,id){selectedItems.value=items$2,selectedItemId=id,emit$1(`valueChanged`,items$2,id)}function onPillItemFocusIn(id){scrollToElement(id)}function scrollToElement(id){let scrollableContainer=filtersContainer.value,el=scrollableContainer.querySelector(`#${id}`);if(el){let scrollableContainerRect=scrollableContainer.getBoundingClientRect(),itemRect=el.getBoundingClientRect();if(itemRect.left>=scrollableContainerRect.left&&itemRect.right<=scrollableContainerRect.right)return;window.requestAnimationFrame(()=>{let scrollValue=itemRect.left(openBlock(),createElementBlock(`div`,{class:`bng-filters-container`,ref_key:`bngFiltersContainer`,ref:bngFiltersContainer,tabindex:`0`,onFocusout:onContainerFocusOut},[_cache[0]||=createBaseVNode(`div`,{class:`fade-effect left-fade-effect`},null,-1),_cache[1]||=createBaseVNode(`div`,{class:`fade-effect right-fade-effect`},null,-1),createBaseVNode(`div`,{class:`scroll-container`,ref_key:`filtersContainer`,ref:filtersContainer},[createVNode(unref(bngPillFilters_default),{ref_key:`bngPillFiltersRef`,ref:bngPillFiltersRef,options:__props.options,"select-on-navigation":__props.selectOnNavigation,required:__props.required,"select-many":__props.selectMany,"show-checked-icon":__props.hasCheckedIcon,onValueChanged,onPillItemFocusIn},null,8,[`options`,`select-on-navigation`,`required`,`select-many`,`show-checked-icon`])],512)],544))}},bngPillFiltersContainer_default=__plugin_vue_export_helper_default(_sfc_main$352,[[`__scopeId`,`data-v-498af92b`]]),_hoisted_1$308=[`data-bng-popover-name`],containerSelector=`.popover-container`,_sfc_main$351={__name:`bngPopoverContent`,props:{name:String,offset:{type:Number,default:4},hideArrow:Boolean,placement:String,disabled:Boolean},emits:[`show`,`hide`,`placementChanged`],setup(__props,{expose:__expose,emit:__emit}){let props=__props,emit$1=__emit,popover=usePopover(),popoverName,popoverContent=ref(null),arrow$3=ref(null),show=ref(!1),unwatchShow,unwatchPlacement,teleportTargetExists=ref(!1),observer$2=null,scopeActivated=ref(!1),isRender=computed(()=>!props.disabled&&teleportTargetExists.value&&show.value),hide$2=()=>!props.disabled&&popover.hide(popoverName),expose={hide:hide$2,show:(el=void 0)=>!props.disabled&&popover.show(popoverName,el),toggle:(forceVal=void 0)=>popover.toggle(popoverName,!props.disabled&&forceVal),isShown:()=>popover.isShown(popoverName)};__expose(expose),watch(()=>show.value,value=>emit$1(value?`show`:`hide`,{name:props.name,...expose})),watch(()=>props.name,(newName,oldName)=>{oldName&&disposePopover(oldName),props.disabled||setupPopover()},{immediate:!0}),watch(()=>props.disabled,value=>{value?(popover.hide(popoverName),disposePopover(popoverName)):setupPopover()}),watch(isRender,async value=>{value&&(await nextTick(),checkSlotContent())});let onMenu=()=>{scopeActivated.value=!1};onBeforeUnmount(()=>{disposePopover(popoverName),observer$2&&=(observer$2.disconnect(),null)}),onMounted(async()=>{teleportTargetExists.value=!!document.querySelector(containerSelector),teleportTargetExists.value||(observer$2=new MutationObserver(()=>{!teleportTargetExists.value&&document.querySelector(containerSelector)&&(teleportTargetExists.value=!0,observer$2.disconnect(),observer$2=null)}),observer$2.observe(document.body,{childList:!0,subtree:!0})),isRender.value&&(await nextTick(),checkSlotContent())});function onScopeChanged(activated,event){scopeActivated.value=activated,!activated&&!event.detail.force&&popover.hide(popoverName)}function checkSlotContent(){let navigableElements=popoverContent.value.querySelectorAll(NAVIGABLE_ELEMENTS_SELECTOR);navigableElements&&navigableElements.length>0&&!scopeActivated.value&&(scopeActivated.value=!0)}function setupPopover(){popoverName=props.name||uniqueId(`bng-popover-content`);let res=popover.register(popoverName,popoverContent,props.placement,{arrow:props.hideArrow?void 0:arrow$3,offset:props.offset});res&&(unwatchShow=watch(res.show,value=>show.value=value),unwatchPlacement=watch(res.placement,placement=>emit$1(`placementChanged`,placement)))}function disposePopover(name){unwatchShow&&=(unwatchShow(),null),unwatchPlacement&&=(unwatchPlacement(),null),popover.unregister(name),show.value=!1,popoverName=null}return(_ctx,_cache)=>isRender.value?(openBlock(),createBlock(Teleport,{key:0,to:`.popover-container`},[withDirectives((openBlock(),createElementBlock(`div`,{ref_key:`popoverContent`,ref:popoverContent,"data-bng-popover-name":unref(popoverName),class:`bng-popover`,onActivate:_cache[0]||=$event=>onScopeChanged(!0,$event),onDeactivate:_cache[1]||=$event=>onScopeChanged(!1,$event)},[renderSlot(_ctx.$slots,`default`,{hide:hide$2},void 0,!0),__props.hideArrow?createCommentVNode(``,!0):(openBlock(),createElementBlock(`span`,{key:0,ref_key:`arrow`,ref:arrow$3,class:`bng-popover-arrow`},null,512))],40,_hoisted_1$308)),[[unref(BngScopedNav_default),{activated:scopeActivated.value,type:unref(SCOPED_NAV_TYPES).popover}],[unref(BngOnUiNav_default),onMenu,`menu`]])])):createCommentVNode(``,!0)}},bngPopoverContent_default=__plugin_vue_export_helper_default(_sfc_main$351,[[`__scopeId`,`data-v-4938e558`]]),_sfc_main$350=Object.assign({inheritAttrs:!1},{__name:`bngPopoverMenu`,props:{name:String,offset:{type:Number,default:4},hideArrow:Boolean,disabled:Boolean,focus:Boolean},emits:[`show`,`hide`,`placementChanged`],setup(__props,{expose:__expose,emit:__emit}){let popover=usePopover(),props=__props,emit$1=__emit,relay={show:(...args)=>emit$1(`show`,...args),hide:(...args)=>emit$1(`hide`,...args),placementChanged:(...args)=>emit$1(`placementChanged`,...args)},popoverContent=ref(null),popoverMenu=ref(null),hide$2=(...args)=>popoverContent.value.hide(...args);return __expose({hide:hide$2,show:(...args)=>popoverContent.value.show(...args),toggle:(...args)=>popoverContent.value.toggle(...args),isShown:(...args)=>popoverContent.value.isShown(...args),getElement:()=>popoverMenu.value}),watchEffect(()=>{if(props.name in popover.popovers){let pop=popover.popovers[props.name];!pop.show&&nextTick(()=>{pop.target&&document.activeElement===document.body&&setFocusExternal(pop.target,!0,!1)})}}),(_ctx,_cache)=>(openBlock(),createBlock(unref(bngPopoverContent_default),{ref_key:`popoverContent`,ref:popoverContent,name:__props.name,offset:__props.offset,"hide-arrow":__props.hideArrow,disabled:__props.disabled,onPlacementChanged:relay.placementChanged,onHide:hide$2},{default:withCtx(()=>[createBaseVNode(`div`,{ref_key:`popoverMenu`,ref:popoverMenu,class:`bng-popover-menu`},[renderSlot(_ctx.$slots,`default`,{hide:hide$2},void 0,!0)],512)]),_:3},8,[`name`,`offset`,`hide-arrow`,`disabled`,`onPlacementChanged`]))}}),bngPopoverMenu_default=__plugin_vue_export_helper_default(_sfc_main$350,[[`__scopeId`,`data-v-fe39553c`]]),_hoisted_1$307={class:`bng-progress-bar`},_hoisted_2$253={key:0,class:`header`},_hoisted_3$221={class:`header-left`},_hoisted_4$189={class:`header-right`},_hoisted_5$161={class:`progress-bar`},_hoisted_6$139=[`innerHTML`],_hoisted_7$121={key:1,class:`progress-fill-indeterminate`},_sfc_main$349={__name:`bngProgressBar`,props:{value:{type:Number,default:0},oldValue:{type:Number,default:0},min:{type:Number,default:0},max:{type:Number,required:!0},headerLeft:String,headerRight:String,showValueLabel:{type:Boolean,default:!0},valueLabelFormat:{type:[String,Function],default:`#value#`},valueColor:{type:String,default:`#ff6600`},oldValueColor:{type:String,default:`#ffffff`},indeterminate:Boolean,animateDifference:Boolean,gradient:Boolean},setup(__props,{expose:__expose}){useCssVars(_ctx=>({v5113e7b0:__props.valueColor,v14406f01:progressFillUnits.value,v6b373656:oldProgressFillUnits.value}));let props=__props;__expose({decreaseValueBy,increaseValueBy,setValue:value=>updateCurrentValue(value)});let currentValue=ref(null),valueHTML=computed(()=>{let res;return res=typeof props.valueLabelFormat==`function`?props.valueLabelFormat(props.value,{min:props.min,max:props.max}):props.valueLabelFormat.replace(/ +/g,` `).replace(`#value#`,`${currentValue.value}${props.max}`),res}),progressFillUnits=computed(()=>1-(currentValue.value-props.min)/(props.max-props.min)),oldProgressFillUnits=computed(()=>1-(props.oldValue-props.min)/(props.max-props.min));watch(()=>props.value,updateCurrentValue),onMounted(()=>{updateCurrentValue(props.min>props.value?props.min:props.value)});function decreaseValueBy(value){let newValue=currentValue.value-value;newValueprops.max&&(newValue=props.max),updateCurrentValue(newValue)}function updateCurrentValue(newValue){currentValue.value=newValue}return(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$307,[__props.headerLeft||__props.headerRight?(openBlock(),createElementBlock(`div`,_hoisted_2$253,[createBaseVNode(`span`,_hoisted_3$221,toDisplayString(__props.headerLeft),1),createBaseVNode(`span`,_hoisted_4$189,toDisplayString(__props.headerRight),1)])):createCommentVNode(``,!0),createBaseVNode(`div`,_hoisted_5$161,[__props.showValueLabel?(openBlock(),createElementBlock(`div`,{key:0,class:`info`,innerHTML:valueHTML.value},null,8,_hoisted_6$139)):createCommentVNode(``,!0),__props.indeterminate?(openBlock(),createElementBlock(`span`,_hoisted_7$121)):(openBlock(),createElementBlock(`span`,{key:2,class:normalizeClass({"progress-fill":!0,"progress-fill-gradient":__props.gradient,"animate-progress":__props.animateDifference&&__props.value>__props.oldValue}),style:normalizeStyle({backgroundColor:__props.valueColor,zIndex:__props.value<__props.oldValue?2:1})},null,6)),__props.oldValue?(openBlock(),createElementBlock(`span`,{key:3,class:normalizeClass({"second-progress-fill":!0,"progress-fill-gradient":__props.gradient,"animate-progress":__props.animateDifference&&__props.value<__props.oldValue}),style:normalizeStyle({backgroundColor:__props.oldValueColor,zIndex:__props.value<__props.oldValue?1:2})},null,6)):createCommentVNode(``,!0)])]))}},bngProgressBar_default=__plugin_vue_export_helper_default(_sfc_main$349,[[`__scopeId`,`data-v-1ca6aacd`]]);function shrinkNum(num,decimals=0){let units=[``,`K`,`M`,`B`,`T`,`Q`];if(!num)return`0`;if(isNaN(parseFloat(num))||!isFinite(+num))return`n/a`;let power$1=Math.floor(Math.log(Math.abs(+num))/Math.log(1e3));return power$1>=units.length&&(power$1=units.length-1),(num/1e3**power$1).toFixed(decimals).replace(/\.0+$/,``)+units[power$1]}var _hoisted_1$306={key:1,class:`key-label`},_hoisted_2$252={class:`value-label`},_sfc_main$348={__name:`bngPropVal`,props:{iconType:[String,Object],keyLabel:String,valueLabel:{required:!0},shrinkNum:Boolean,iconColor:{type:String,default:`#fff`},noGap:{type:Boolean,default:!1},noIcon:{type:Boolean,default:!1}},setup(__props){let props=__props,itemClass=computed(()=>({"info-item":!0,"with-icon":props.iconType,"no-key":!props.keyLabel,"no-gap":props.noGap})),value=computed(()=>{let i=props.valueLabel;return props.shrinkNum?shrinkNum(i,0):i});return(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,{class:normalizeClass(itemClass.value)},[__props.iconType&&!__props.noIcon?(openBlock(),createBlock(unref(bngIcon_default),{key:0,class:`icon`,type:__props.iconType,color:__props.iconColor},null,8,[`type`,`color`])):createCommentVNode(``,!0),__props.keyLabel?(openBlock(),createElementBlock(`span`,_hoisted_1$306,toDisplayString(__props.keyLabel),1)):createCommentVNode(``,!0),createBaseVNode(`span`,_hoisted_2$252,toDisplayString(value.value),1)],2))}},bngPropVal_default=__plugin_vue_export_helper_default(_sfc_main$348,[[`__scopeId`,`data-v-fa2e2062`]]),_hoisted_1$305={class:`header`},_sfc_main$347={__name:`bngScreenHeading`,props:{blurDelay:Number,preheadings:Array,divider:Boolean,type:{type:String,default:`line`,validator:v=>[`line`,`ribbon`].includes(v)||v===``}},setup(__props){let blurVal=ref(!1);onMounted(()=>window.setTimeout(()=>blurVal.value=!0,~~+props.blurDelay));let props=__props,preheadings=computed(()=>Array.isArray(props.preheadings)&&props.preheadings.length>0?props.preheadings:null);return(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,{class:normalizeClass([`bng-screen-heading`,{[`heading-style-${__props.type}`]:!0,prehead:preheadings.value}])},[preheadings.value?withDirectives((openBlock(),createElementBlock(`span`,{key:0,class:normalizeClass([`pre-header`,{"with-divider":__props.divider}])},[(openBlock(!0),createElementBlock(Fragment,null,renderList(preheadings.value,preheading=>(openBlock(),createElementBlock(`span`,{class:`location`,key:preheading},toDisplayString(preheading),1))),128))],2)),[[unref(BngBlur_default),blurVal.value]]):createCommentVNode(``,!0),withDirectives((openBlock(),createElementBlock(`h1`,_hoisted_1$305,[renderSlot(_ctx.$slots,`default`,{},void 0,!0)])),[[unref(BngBlur_default),blurVal.value]])],2))}},bngScreenHeading_default=__plugin_vue_export_helper_default(_sfc_main$347,[[`__scopeId`,`data-v-f6d9f077`]]),_hoisted_1$304={class:`header`},_hoisted_2$251={key:0,class:`decorator-item`,width:`100%`,height:`100%`,viewBox:`0 0 32 40`,preserveAspectRatio:`none`,fill:`none`,xmlns:`http://www.w3.org/2000/svg`},_hoisted_3$220={key:1,class:`decorator-item`,width:`100%`,height:`100%`,viewBox:`0 0 36 40`,preserveAspectRatio:`xMaxYMid slice`,fill:`none`,xmlns:`http://www.w3.org/2000/svg`},_hoisted_4$188={key:2,class:`decorator-item`,width:`100%`,height:`100%`,viewBox:`0 0 36 40`,preserveAspectRatio:`xMaxYMid slice`,fill:`none`,xmlns:`http://www.w3.org/2000/svg`},_sfc_main$346={__name:`bngScreenHeadingV2`,props:{blurDelay:Number,preheadings:Array,divider:Boolean,type:{type:String,default:`1`,validator:v=>[`1`,`2`,`3`].includes(v)||v===``},hintVisible:Boolean,hintLabel:String,hintIcon:String,hintAccent:String,hintBindingEvent:String},emits:[`hint`],setup(__props,{emit:__emit}){let blurVal=ref(!1);onMounted(()=>window.setTimeout(()=>blurVal.value=!0,~~+props.blurDelay));let props=__props,preheadings=computed(()=>Array.isArray(props.preheadings)&&props.preheadings.length>0?props.preheadings:null);return computed(()=>props.hintVisible??!1),computed(()=>props.hintLabel??``),computed(()=>props.hintIcon??icons.arrowLargeLeft),computed(()=>props.hintAccent??ACCENTS.outlined),(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,{class:normalizeClass([`bng-screen-heading`,{[`heading-style-${__props.type}`]:!0,prehead:preheadings.value}])},[renderSlot(_ctx.$slots,`preheadings`,{},void 0,!0),withDirectives((openBlock(),createElementBlock(`span`,_hoisted_1$304,[createBaseVNode(`div`,{class:normalizeClass(`decorator type${__props.type}`)},[__props.type===`1`?(openBlock(),createElementBlock(`svg`,_hoisted_2$251,[..._cache[0]||=[createBaseVNode(`path`,{d:`M16.6328 40H1.62891L14.0039 6H14.002L11.8174 0H26.8174L29.001 6H29.0078L16.6328 40Z`,fill:`var(--bng-orange-400)`},null,-1)]])):createCommentVNode(``,!0),__props.type===`2`?(openBlock(),createElementBlock(`svg`,_hoisted_3$220,[..._cache[1]||=[createBaseVNode(`path`,{d:`M18.6366 0H34.0094L26.73 20H11.3572L18.6366 0Z`,fill:`#DA5706`},null,-1),createBaseVNode(`path`,{d:`M19.4504 40H4.07812L11.3572 20L4.07812 0H19.4504L26.7295 20L19.4504 40Z`,fill:`var(--bng-orange-400)`},null,-1)]])):createCommentVNode(``,!0),__props.type===`3`?(openBlock(),createElementBlock(`svg`,_hoisted_4$188,[..._cache[2]||=[createBaseVNode(`path`,{d:`M18.6366 0H34.0094L26.73 20H11.3572L18.6366 0Z`,fill:`#DA5706`},null,-1),createBaseVNode(`path`,{d:`M19.4504 40H4.07812L11.3572 20L4.07812 0H19.4504L26.7295 20L19.4504 40Z`,fill:`var(--bng-orange-400)`},null,-1)]])):createCommentVNode(``,!0)],2),createBaseVNode(`h1`,null,[renderSlot(_ctx.$slots,`default`,{},void 0,!0)])])),[[unref(BngBlur_default),blurVal.value]])],2))}},bngScreenHeadingV2_default=__plugin_vue_export_helper_default(_sfc_main$346,[[`__scopeId`,`data-v-4854a8bd`]]),_hoisted_1$303={class:`label select`},_hoisted_2$250={class:`bng-select-indicator`},_sfc_main$345={__name:`bngSelect`,props:mergeModels({value:void 0,options:{type:Array,required:!0},config:{type:Object,default:()=>({value:opt=>opt,label:opt=>opt})},loop:Boolean,labelClickable:Boolean,labelPopover:String,disabled:Boolean,navLeftEvent:{type:String,default:`focus_l`},navRightEvent:{type:String,default:`focus_r`}},{modelValue:{type:[Object,Boolean,Number,String],default:void 0},modelModifiers:{}}),emits:mergeModels([`change`,`valueChanged`,`label-click`],[`update:modelValue`]),setup(__props,{expose:__expose,emit:__emit}){let leftBinding=ref(),rightBinding=ref(),vModel=useModel(__props,`modelValue`),props=__props,elContainer=ref(),elContent=ref(),findOptionValue=(valueToFind,opts)=>Math.max(0,opts.findIndex(opt=>props.config.value(opt)===valueToFind)),index=ref(getInitialValue()),current=computed(()=>({option:props.options[index.value],value:props.config.value(props.options[index.value]),label:props.config.label(props.options[index.value])})),leftIconClass=computed(()=>({"with-binding":leftBinding.value?.displayed})),rightIconClass=computed(()=>({"with-binding":rightBinding.value?.displayed})),isLeftDisabled=props.loop?!1:computed(()=>index.value==0),isRightDisabled=props.loop?!1:computed(()=>index.value==props.options.length-1),emit$1=__emit,goPrev=()=>{!props.disabled&&!isLeftDisabled.value&&changeIndex(-1)},goNext=()=>{!props.disabled&&!isRightDisabled.value&&changeIndex(1)};__expose({goNext,goPrev,getElement:()=>elContainer.value,getContentElement:()=>elContent.value}),watch(()=>props.value,()=>index.value=props.value!==null&&props.value!==void 0?findOptionValue(props.value,props.options):0),watch(vModel,val=>index.value=val==null?0:findOptionValue(val,props.options)),watch(()=>index.value,updateValue);function updateValue(){emit$1(`valueChanged`,current.value.value,current.value.label,current.value.option),emit$1(`change`,current.value.value,current.value.label,current.value.option),vModel.value=current.value.value}function changeIndex(offset$2){props.loop?index.value=(props.options.length+index.value+offset$2)%props.options.length:index.value=clamp(index.value+offset$2,0,props.options.length-1)}function getInitialValue(){return vModel.value!==null&&vModel.value!==void 0?findOptionValue(vModel.value,props.options):`value`in props?findOptionValue(props.value,props.options):0}return(_ctx,_cache)=>withDirectives((openBlock(),createElementBlock(`div`,{ref_key:`elContainer`,ref:elContainer,class:`bng-select`,"bng-nav-item":``},[renderSlot(_ctx.$slots,`previousButton`,{click:goPrev,disabled:unref(isLeftDisabled)},()=>[createVNode(unref(bngButton_default),{"bng-no-nav":`true`,disabled:__props.disabled||unref(isLeftDisabled),accent:unref(ACCENTS).text,mute:_ctx.$attrs.mute,"data-testid":`previous-btn`,onClick:goPrev},{default:withCtx(()=>[createVNode(unref(bngIcon_default),{type:leftBinding.value?.displayed?unref(icons).arrowSmallLeft:unref(icons).arrowLargeLeft,class:normalizeClass(leftIconClass.value)},null,8,[`type`,`class`]),__props.navLeftEvent&&__props.navLeftEvent!==`focus_l`?(openBlock(),createBlock(unref(bngBinding_default),{key:0,ref_key:`leftBinding`,ref:leftBinding,uiEvent:__props.navLeftEvent,controller:``},null,8,[`uiEvent`])):createCommentVNode(``,!0)]),_:1},8,[`disabled`,`accent`,`mute`])],!0),withDirectives((openBlock(),createElementBlock(`div`,{ref_key:`elContent`,ref:elContent,class:normalizeClass([`bng-select-content`,{"label-clickable":__props.labelClickable}]),onClick:_cache[0]||=withModifiers($event=>__props.labelClickable&&emit$1(`label-click`),[`stop`])},[renderSlot(_ctx.$slots,`display`,{label:current.value.label,value:current.value.value},()=>[createBaseVNode(`span`,_hoisted_1$303,toDisplayString(current.value.label),1),_cache[1]||=createBaseVNode(`label`,{flavour:``},null,-1)],!0)],2)),[[unref(BngSoundClass_default),!__props.disabled&&__props.labelClickable&&`bng_click_hover_generic`],[unref(BngPopover_default),__props.labelPopover,`bottom`,{click:!0}]]),renderSlot(_ctx.$slots,`nextButton`,{click:goNext,disabled:unref(isRightDisabled)},()=>[createVNode(unref(bngButton_default),{"bng-no-nav":`true`,disabled:__props.disabled||unref(isRightDisabled),accent:unref(ACCENTS).text,mute:_ctx.$attrs.mute,"data-testid":`next-btn`,onClick:goNext},{default:withCtx(()=>[__props.navRightEvent&&__props.navRightEvent!==`focus_r`?(openBlock(),createBlock(unref(bngBinding_default),{key:0,ref_key:`rightBinding`,ref:rightBinding,uiEvent:__props.navRightEvent,controller:``},null,8,[`uiEvent`])):createCommentVNode(``,!0),createVNode(unref(bngIcon_default),{type:rightBinding.value?.displayed?unref(icons).arrowSmallRight:unref(icons).arrowLargeRight,class:normalizeClass(rightIconClass.value)},null,8,[`type`,`class`])]),_:1},8,[`disabled`,`accent`,`mute`])],!0),createBaseVNode(`div`,_hoisted_2$250,[(openBlock(!0),createElementBlock(Fragment,null,renderList(__props.options.length,idx=>(openBlock(),createElementBlock(`div`,{key:idx,class:normalizeClass({active:idx-1===index.value})},null,2))),128))])])),[[unref(BngOnUiNav_default),goPrev,__props.navLeftEvent,{focusRequired:!0}],[unref(BngOnUiNav_default),goNext,__props.navRightEvent,{focusRequired:!0}],[unref(BngDisabled_default),__props.disabled]])}},bngSelect_default=__plugin_vue_export_helper_default(_sfc_main$345,[[`__scopeId`,`data-v-d1cacb72`]]),_hoisted_1$302={class:`bng-simple-graph`},_hoisted_2$249={key:0,class:`y-axis`},_hoisted_3$219={class:`y-values`},_hoisted_4$187={class:`max-value`},_hoisted_5$160={class:`axis-label`},_hoisted_6$138={key:0,class:`unit`},_hoisted_7$120={class:`min-value`},_hoisted_8$100={viewBox:`0 0 100 100`,preserveAspectRatio:`none`,class:`graph-svg`},_hoisted_9$90=[`width`,`height`],_hoisted_10$78=[`d`,`stroke`],_hoisted_11$70=[`d`,`stroke`],_hoisted_12$58=[`width`,`height`],_hoisted_13$50=[`d`,`stroke`],_hoisted_14$45=[`d`,`stroke`],_hoisted_15$43={key:0,width:`100`,height:`100`,fill:`url(#subgrid)`},_hoisted_16$40={class:`grid`},_hoisted_17$33=[`y1`,`y2`,`stroke`],_hoisted_18$30={class:`background-ranges`},_hoisted_19$25=[`x`,`width`,`fill`,`stroke`,`opacity`],_hoisted_20$21={class:`vertical-guides`},_hoisted_21$19=[`x1`,`x2`,`stroke`,`opacity`],_hoisted_22$17=[`x1`,`x2`],_hoisted_23$16=[`d`,`fill`,`opacity`],_hoisted_24$15=[`d`,`stroke`],_hoisted_25$14={key:2,class:`x-axis`},_hoisted_26$12={class:`x-values`},_hoisted_27$12={class:`min-value`},_hoisted_28$11={class:`axis-label`},_hoisted_29$11={key:0,class:`unit`},_hoisted_30$10={class:`max-value`},_sfc_main$344={__name:`bngSimpleGraph`,props:{config:{type:Object,default:()=>({showLabels:!1,xAxis:{key:`x`,label:`X Axis`,unit:``},yAxis:{key:`y`,label:`Y Axis`,unit:``}})},points:{type:Array,default:()=>[]},gridColor:{type:String,default:`var(--bng-ter-blue-gray-500)`},backgroundColor:{type:String,default:`rgba(0, 0, 0, 0.1)`},currentX:{type:Number,default:null},verticalGuides:{type:Array,default:()=>[]},ranges:{type:Array,default:()=>[]},gridDivisions:{type:Array,default:()=>[50,20]},subgridDivider:{type:Number,default:2},showSubgrid:{type:Boolean,default:!0},singleLabel:{type:Object,default:null}},setup(__props){useCssVars(_ctx=>({v194c2663:__props.config.showLabels?`2rem`:`0`,fdb9891e:__props.backgroundColor}));let props=__props,gridSizes=computed(()=>({x:100/props.gridDivisions[0],y:100/props.gridDivisions[1]})),xScale=computed(()=>{if(props.config?.xAxis?.min!==void 0&&props.config?.xAxis?.max!==void 0){let range$1=props.config.xAxis.max-props.config.xAxis.min;return{min:props.config.xAxis.min,max:props.config.xAxis.max,range:range$1===0?1:range$1}}if(!props.points.length)return{min:0,max:1,range:1};let xValues=[...props.points.flatMap(dataset=>(dataset.points||[]).map(point=>point&&point[0])),...(props.verticalGuides||[]).map(guide=>guide?.x),...(props.ranges||[]).map(range$1=>range$1?.start),...(props.ranges||[]).map(range$1=>range$1?.end)].filter(val=>val!=null&&isFinite(val));if(xValues.length===0)return{min:0,max:1,range:1};let min$1=Math.min(...xValues),max$1=Math.max(...xValues);if(!isFinite(min$1)||!isFinite(max$1))return{min:0,max:1,range:1};let range=max$1-min$1;return{min:min$1,max:max$1,range:range===0?1:range}}),getXPosition=value=>{if(value==null||!isFinite(value))return 0;let result=(value-xScale.value.min)/xScale.value.range*100;return isFinite(result)?result:0},datasetPaths=computed(()=>!props.points.length||!xScale.value?[]:props.points.map(dataset=>{if(!dataset.points||!Array.isArray(dataset.points)||dataset.points.length===0)return{datasetId:dataset.label||`unknown`,linePath:``,areaPath:``};let linePoints=dataset.points.map((point,index)=>{if(!point||point.length<2)return``;let x=getXPosition(point[0]),y=getYPosition(point[1]);return`${index===0?`M`:`L`} ${x} ${y}`}).filter(p$1=>p$1).join(` `),areaPoints=dataset.points.map(point=>!point||point.length<2?``:`L ${getXPosition(point[0])} ${getYPosition(point[1])}`).filter(p$1=>p$1).join(` `),areaPath=``;if(dataset.fill&&dataset.points.length>0){let firstPoint=dataset.points[0],lastPoint=dataset.points[dataset.points.length-1];firstPoint&&lastPoint&&firstPoint.length>=2&&lastPoint.length>=2&&(areaPath=`M -5 105 L -5 ${getYPosition(firstPoint[1])} ${areaPoints} L 105 ${getYPosition(lastPoint[1])} L 105 105 Z`)}return{datasetId:dataset.label||`unknown`,linePath:linePoints,areaPath}})),getLinePathForDataset=dataset=>{let path=datasetPaths.value.find(p$1=>p$1.datasetId===dataset.label);return path?path.linePath:``},getAreaPathForDataset=dataset=>{let path=datasetPaths.value.find(p$1=>p$1.datasetId===dataset.label);return path?path.areaPath:``},getYPosition=value=>{if(value==null||!isFinite(value))return 50;let yMin=yBounds.value.min,yMax=yBounds.value.max;if(yMin==null||yMax==null||!isFinite(yMin)||!isFinite(yMax)||yMin===yMax)return 50;if(yMin>=0||yMax<=0){let yRange$1=yMax-yMin;if(yRange$1===0)return 50;let result$1=97.5-(value-yMin)/yRange$1*95;return isFinite(result$1)?result$1:50}let yRange=Math.max(Math.abs(yMin),Math.abs(yMax));if(yRange===0)return 50;let totalRange=Math.abs(yMin)+Math.abs(yMax);if(totalRange===0)return 50;let zeroLinePosition=Math.abs(yMin)/totalRange*95+2.5,result;return result=value>=0?zeroLinePosition-value/yRange*(zeroLinePosition-2.5):zeroLinePosition+Math.abs(value)/yRange*(97.5-zeroLinePosition),isFinite(result)?result:50},formatNumber=num=>num==null||!isFinite(num)?`0`:Math.floor(num).toString(),yBounds=computed(()=>{if(props.config?.yAxis?.min!==void 0&&props.config?.yAxis?.max!==void 0)return{min:props.config.yAxis.min,max:props.config.yAxis.max};if(!props.points.length)return{min:0,max:0};let allYValues=props.points.flatMap(dataset=>(dataset.points||[]).map(point=>point&&point[1])).filter(val=>val!=null&&isFinite(val));if(allYValues.length===0)return{min:0,max:1};let min$1=Math.min(...allYValues),max$1=Math.max(...allYValues);return!isFinite(min$1)||!isFinite(max$1)?{min:0,max:1}:{min:min$1,max:max$1}}),xMinFormatted=computed(()=>formatNumber(xScale.value?.min||0)),xMaxFormatted=computed(()=>formatNumber(xScale.value?.max||0)),yMinFormatted=computed(()=>formatNumber(yBounds.value.min)),yMaxFormatted=computed(()=>formatNumber(yBounds.value.max)),hasNegativeValues=computed(()=>yBounds.value.min<0),getLabelPosition=()=>{if(!props.singleLabel)return{x:0,y:0,anchor:`start`};let labelX=props.singleLabel.x===void 0?95:getXPosition(props.singleLabel.x),labelY=props.singleLabel.y===void 0?50:getYPosition(props.singleLabel.y),adjustedY=labelY>=25?labelY+4:labelY-2,anchor=labelX>=80?`end`:`start`;return{x:anchor===`end`?Math.min(labelX,98):Math.max(labelX,2),y:adjustedY,anchor}},getLabelStyle=()=>{if(!props.singleLabel)return{};let basePos=getLabelPosition(),estimatedWidth=props.singleLabel.text.length*6.5+6,estimatedHeight=18,containerWidth=300,containerHeight=80,pixelX=basePos.x/100*300,pixelY=basePos.y/100*80,finalX=basePos.x,finalY=basePos.y,anchor=basePos.anchor,verticalAlign=`middle`;anchor===`start`?pixelX+estimatedWidth>290&&(anchor=`end`):pixelX-estimatedWidth<10&&(anchor=`start`);let minGapFromPoint=4,topBuffer=8,bottomBuffer=8,wouldOverflowTop=pixelY-18/2<8;if(pixelY+18/2>72)verticalAlign=`bottom`,finalY=Math.max(basePos.y-4,15);else if(wouldOverflowTop)verticalAlign=`top`,finalY=Math.min(basePos.y+4,85);else{let pointY=basePos.y;pointY>75?(verticalAlign=`bottom`,finalY=pointY-4):pointY<25?(verticalAlign=`top`,finalY=pointY+4):(verticalAlign=`bottom`,finalY=pointY-4)}let transformX=`translateX(0)`,transformY=`translateY(-50%)`;return anchor===`end`&&(transformX=`translateX(-100%)`),verticalAlign===`bottom`?transformY=`translateY(-100%)`:verticalAlign===`top`&&(transformY=`translateY(0)`),{position:`absolute`,left:`${finalX}%`,top:`${finalY}%`,transform:`${transformX} ${transformY}`,color:props.singleLabel.color||`var(--bng-orange)`,fontSize:`11px`,fontFamily:`sans-serif`,pointerEvents:`none`,whiteSpace:`nowrap`}};return(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$302,[__props.config.showLabels?(openBlock(),createElementBlock(`div`,_hoisted_2$249,[createBaseVNode(`div`,_hoisted_3$219,[createBaseVNode(`div`,_hoisted_4$187,toDisplayString(yMaxFormatted.value),1),createBaseVNode(`div`,_hoisted_5$160,[createTextVNode(toDisplayString(__props.config.yAxis.label)+` `,1),__props.config.yAxis.unit?(openBlock(),createElementBlock(`span`,_hoisted_6$138,`(`+toDisplayString(__props.config.yAxis.unit)+`)`,1)):createCommentVNode(``,!0)]),createBaseVNode(`div`,_hoisted_7$120,toDisplayString(yMinFormatted.value),1)])])):createCommentVNode(``,!0),(openBlock(),createElementBlock(`svg`,_hoisted_8$100,[createBaseVNode(`defs`,null,[createBaseVNode(`pattern`,{id:`grid`,width:gridSizes.value.x,height:gridSizes.value.y,patternUnits:`userSpaceOnUse`},[createBaseVNode(`path`,{d:`M ${gridSizes.value.x} 0 L ${gridSizes.value.x} ${gridSizes.value.y}`,stroke:__props.gridColor,"stroke-width":`1`,"vector-effect":`non-scaling-stroke`,opacity:`0.3`},null,8,_hoisted_10$78),createBaseVNode(`path`,{d:`M 0 ${gridSizes.value.y} L 100 ${gridSizes.value.y}`,stroke:__props.gridColor,"stroke-width":`1`,"vector-effect":`non-scaling-stroke`,opacity:`0.3`},null,8,_hoisted_11$70)],8,_hoisted_9$90),createBaseVNode(`pattern`,{id:`subgrid`,width:gridSizes.value.x,height:gridSizes.value.y,patternUnits:`userSpaceOnUse`},[createBaseVNode(`path`,{d:`M ${gridSizes.value.x/__props.subgridDivider} 0 L ${gridSizes.value.x/__props.subgridDivider} ${gridSizes.value.y}`,stroke:__props.gridColor,"stroke-width":`0.5`,"vector-effect":`non-scaling-stroke`,opacity:`0.15`},null,8,_hoisted_13$50),createBaseVNode(`path`,{d:`M 0 ${gridSizes.value.y/__props.subgridDivider} L 100 ${gridSizes.value.y/__props.subgridDivider}`,stroke:__props.gridColor,"stroke-width":`0.5`,"vector-effect":`non-scaling-stroke`,opacity:`0.15`},null,8,_hoisted_14$45)],8,_hoisted_12$58)]),__props.showSubgrid?(openBlock(),createElementBlock(`rect`,_hoisted_15$43)):createCommentVNode(``,!0),_cache[0]||=createBaseVNode(`rect`,{width:`100`,height:`100`,fill:`url(#grid)`},null,-1),createBaseVNode(`g`,_hoisted_16$40,[hasNegativeValues.value?(openBlock(),createElementBlock(`line`,{key:0,x1:`0`,y1:getYPosition(0),x2:`100`,y2:getYPosition(0),stroke:__props.gridColor,"stroke-width":`2`,"vector-effect":`non-scaling-stroke`,opacity:`0.75`},null,8,_hoisted_17$33)):createCommentVNode(``,!0)]),createBaseVNode(`g`,_hoisted_18$30,[(openBlock(!0),createElementBlock(Fragment,null,renderList(__props.ranges,range=>(openBlock(),createElementBlock(`rect`,{key:`range-${range.start}`,x:getXPosition(range.start),y:`-5`,width:getXPosition(range.end)-getXPosition(range.start),height:`110`,fill:range.fill,stroke:range.outline,"stroke-width":`2`,"vector-effect":`non-scaling-stroke`,opacity:range.opacity},null,8,_hoisted_19$25))),128))]),createBaseVNode(`g`,_hoisted_20$21,[(openBlock(!0),createElementBlock(Fragment,null,renderList(__props.verticalGuides,guide=>(openBlock(),createElementBlock(`line`,{key:`guide-${guide.x}`,x1:getXPosition(guide.x),y1:`0`,x2:getXPosition(guide.x),y2:`100`,stroke:guide.color,"stroke-width":`1`,"vector-effect":`non-scaling-stroke`,opacity:guide.opacity},null,8,_hoisted_21$19))),128))]),__props.currentX?(openBlock(),createElementBlock(`line`,{key:1,x1:getXPosition(__props.currentX),y1:`0`,x2:getXPosition(__props.currentX),y2:`100`,stroke:`white`,"stroke-width":`1`,"vector-effect":`non-scaling-stroke`,opacity:`0.8`},null,8,_hoisted_22$17)):createCommentVNode(``,!0),(openBlock(!0),createElementBlock(Fragment,null,renderList(__props.points,dataset=>(openBlock(),createElementBlock(`g`,{key:dataset.label},[dataset.fill?(openBlock(),createElementBlock(`path`,{key:0,d:getAreaPathForDataset(dataset),fill:dataset.color||`white`,opacity:dataset.fillOpacity??.5},null,8,_hoisted_23$16)):createCommentVNode(``,!0),createBaseVNode(`path`,{d:getLinePathForDataset(dataset),stroke:dataset.color||`white`,fill:`none`,"stroke-width":`1`,"vector-effect":`non-scaling-stroke`},null,8,_hoisted_24$15)]))),128))])),__props.singleLabel?(openBlock(),createElementBlock(`div`,{key:1,class:`single-label`,style:normalizeStyle(getLabelStyle())},toDisplayString(__props.singleLabel.text),5)):createCommentVNode(``,!0),__props.config.showLabels?(openBlock(),createElementBlock(`div`,_hoisted_25$14,[createBaseVNode(`div`,_hoisted_26$12,[createBaseVNode(`div`,_hoisted_27$12,toDisplayString(xMinFormatted.value),1),createBaseVNode(`div`,_hoisted_28$11,[createTextVNode(toDisplayString(__props.config.xAxis.label)+` `,1),__props.config.xAxis.unit?(openBlock(),createElementBlock(`span`,_hoisted_29$11,`(`+toDisplayString(__props.config.xAxis.unit)+`)`,1)):createCommentVNode(``,!0)]),createBaseVNode(`div`,_hoisted_30$10,toDisplayString(xMaxFormatted.value),1)])])):createCommentVNode(``,!0)]))}},bngSimpleGraph_default=__plugin_vue_export_helper_default(_sfc_main$344,[[`__scopeId`,`data-v-66d95af3`]]),_hoisted_1$301={class:`bng-slider-container`},_hoisted_2$248=[`disabled`,`min`,`max`,`step`],_sfc_main$343={__name:`bngSlider`,props:{modelValue:Number,origValue:{type:[Number,String],default:NaN},min:{type:[Number,String],default:0},max:{type:[Number,String],required:!0},step:{type:[Number,String],default:0},withReset:{type:Boolean,default:!1},withInput:{type:Boolean,default:!1},inputMultiplier:{type:Number,default:1},unit:{type:String,default:``},disabled:Boolean,uiNavFocus:{type:[Boolean,Object],default:{},validator:val=>typeof val==`boolean`&&!val||typeof val==`object`}},emits:[`change`,`valueChanged`,`update:modelValue`],setup(__props,{expose:__expose,emit:__emit}){let props=__props,emit$1=__emit,slider=ref(null),value=ref(props.modelValue);ref(!1);let uiNavFocusFunction=computed(()=>props.uiNavFocus?{callback:(dir,val)=>{value.value=val,notify()},value:()=>value.value,min:+props.min,max:+props.max,step:()=>+props.step,...props.uiNavFocus}:!1);watch(()=>props.modelValue,val=>{value.value=Number(val),updateSliderBackground()});let dirty=useDirty(value,null,updateSliderBackground),dirtyReset=useDirty(value,null,updateSliderBackground);__expose(dirty);let resetDisabled=computed(()=>props.disabled?!0:isNaN(dirtyReset.currentCleanValue.value)?!dirty.dirty.value:!dirtyReset.dirty.value);onMounted(()=>{updateSliderBackground(),inputProps.value=value.value*props.inputMultiplier});function notify(){emit$1(`update:modelValue`,value.value),emit$1(`valueChanged`,value.value),emit$1(`change`,value.value),updateSliderBackground()}function updateSliderBackground(){if(!slider.value)return;let current=(value.value-props.min)/(props.max-props.min)*100,init$3=[-100,-100],dirtyVal=dirtyReset.currentCleanValue.value;if((typeof dirtyVal!=`number`||isNaN(dirtyVal))&&(dirtyVal=dirty.currentCleanValue.value),typeof dirtyVal==`number`&&!isNaN(dirtyVal)){let initpos=(dirtyVal-props.min)/(props.max-props.min)*100;init$3[currentvalue.value,val=>{inputProps.value=val*props.inputMultiplier}),watch(()=>props.origValue,val=>{val=+val,isNaN(val)||dirtyReset.setCleanValue(val)},{immediate:!0}),watch(()=>inputProps.value,val=>{value.value=val/props.inputMultiplier});function onInputChange(num){num=Number(num);let norm=roundDecSample(num,inputProps.step);num!==norm&&(inputProps.value=norm),num=norm/props.inputMultiplier,num=roundDecSample(num,props.step),numprops.max&&(num=props.max),value.value=num,notify()}function resetValue(){let val=+props.origValue;isNaN(val)?dirty.resetValue():value.value=val,notify()}return(_ctx,_cache)=>withDirectives((openBlock(),createElementBlock(`div`,_hoisted_1$301,[withDirectives(createBaseVNode(`input`,{ref_key:`slider`,ref:slider,class:`bng-slider`,type:`range`,disabled:__props.disabled,"onUpdate:modelValue":_cache[0]||=$event=>value.value=$event,min:+__props.min,max:+__props.max,step:+__props.step,onInput:notify},null,40,_hoisted_2$248),[[vModelText,value.value,void 0,{number:!0}],[unref(BngOnUiNavFocus_default),uiNavFocusFunction.value,void 0,{repeat:!0}]]),__props.withInput?(openBlock(),createBlock(unref(bngInput_default),{key:0,class:`bng-slider-input`,disabled:__props.disabled,modelValue:inputProps.value,"onUpdate:modelValue":_cache[1]||=$event=>inputProps.value=$event,type:`number`,min:inputProps.min,max:inputProps.max,step:inputProps.step,suffix:__props.unit,onValueChanged:onInputChange},null,8,[`disabled`,`modelValue`,`min`,`max`,`step`,`suffix`])):createCommentVNode(``,!0),__props.withReset?(openBlock(),createBlock(unref(bngButton_default),{key:1,class:`bng-slider-reset`,accent:unref(ACCENTS).text,icon:unref(icons).undo,disabled:resetDisabled.value,onClick:resetValue},null,8,[`accent`,`icon`,`disabled`])):createCommentVNode(``,!0)])),[[unref(BngScopedNav_default),{bubbleWhitelistEvents:[`menu`]}],[unref(BngDisabled_default),__props.disabled]])}},bngSlider_default=__plugin_vue_export_helper_default(_sfc_main$343,[[`__scopeId`,`data-v-7d0150a1`]]),_sfc_main$342={__name:`bngSmartSelect`,props:mergeModels({items:{type:Array,required:!0},threshold:{type:Number,default:6},type:{type:String,default:``,validator(val){return[``,`select`,`dropdown`].includes(val)}},highlight:[String,Array,RegExp],disabled:Boolean},{modelValue:{},modelModifiers:{}}),emits:mergeModels([`change`],[`update:modelValue`]),setup(__props,{emit:__emit}){let props=__props,value=useModel(__props,`modelValue`),emit$1=__emit,elDropdown=ref(),elSelect=ref(),types={none:bngSelect_default,select:bngSelect_default,dropdown:bngDropdown_default},items$2=computed(()=>Array.isArray(props.items)?props.items:[]),type=computed(()=>props.type&&props.type in types?props.type:items$2.value.length===0?`none`:items$2.value.length<=props.threshold?`select`:`dropdown`),binds=computed(()=>{let res={disabled:props.disabled};switch(type.value){default:res.options=[`n/a`],res.disabled=!0;break;case`select`:res.loop=!0,res.labelClickable=!0,res.config={label:itm=>itm?.label||`n/a`,value:itm=>itm?.value},res.options=items$2.value.filter(itm=>!itm.disabled&&!itm.group),res.items=items$2.value,res.highlight=props.highlight,res.disabled||=res.options.length===0,res.popoverTarget=elSelect.value?.getElement?.(),res.focusTarget=elSelect.value?.getContentElement?.()||res.popoverTarget;break;case`dropdown`:res.items=items$2.value,res.highlight=props.highlight,res.showSearch=!0;break}return res});function openDropdown(){}function onSelectChanged(newValue){value.value!==newValue&&emit$1(`change`,newValue)}function onDropdownChanged(newValue){value.value!==newValue&&emit$1(`change`,newValue)}return(_ctx,_cache)=>(openBlock(),createElementBlock(Fragment,null,[type.value===`dropdown`?createCommentVNode(``,!0):(openBlock(),createBlock(unref(bngSelect_default),{key:0,ref_key:`elSelect`,ref:elSelect,class:`bng-smart-select`,modelValue:value.value,"onUpdate:modelValue":_cache[0]||=$event=>value.value=$event,options:binds.value.options,config:binds.value.config,disabled:binds.value.disabled,loop:``,"label-clickable":``,"label-popover":elDropdown.value?.popoverName,onLabelClick:openDropdown,onChange:onSelectChanged},null,8,[`modelValue`,`options`,`config`,`disabled`,`label-popover`])),binds.value.items?(openBlock(),createBlock(unref(bngDropdown_default),{key:1,ref_key:`elDropdown`,ref:elDropdown,class:normalizeClass(`bng-smart-${type.value}`),modelValue:value.value,"onUpdate:modelValue":_cache[1]||=$event=>value.value=$event,items:binds.value.items,highlight:binds.value.highlight,disabled:binds.value.disabled,headless:type.value===`select`,"show-search":binds.value.showSearch,"focus-target":binds.value.focusTarget,"popover-target":binds.value.popoverTarget,onValueChanged:onDropdownChanged},null,8,[`class`,`modelValue`,`items`,`highlight`,`disabled`,`headless`,`show-search`,`focus-target`,`popover-target`])):createCommentVNode(``,!0)],64))}},bngSmartSelect_default=__plugin_vue_export_helper_default(_sfc_main$342,[[`__scopeId`,`data-v-a288ad68`]]),_hoisted_1$300=[`xlink:href`],_sfc_main$341={__name:`bngSpriteIcon`,props:{atlasPath:{type:String,default:`sprites/svg-symbols.svg`},src:{type:String,required:!0},color:{type:String,default:`#fff`},deg:{type:Number,default:0}},setup(__props){let props=__props,atlasURL=computed(()=>`${getAssetURL$1(props.atlasPath)}#${props.src.toLowerCase()}`),getAssetURL$1=assetPath=>bngApi.isMock?`http://localhost:9000/${assetPath}`:`/ui/ui-vue/src/assets/${assetPath}`;return(_ctx,_cache)=>(openBlock(),createElementBlock(`svg`,{class:`atlasIcon`,style:normalizeStyle({fill:__props.color,pointerEvents:`none`,transform:`rotate(${__props.deg}deg)`}),version:`1.1`,xmlns:`http://www.w3.org/2000/svg`},[createBaseVNode(`use`,{"xlink:href":atlasURL.value},null,8,_hoisted_1$300)],4))}},bngSpriteIcon_default=__plugin_vue_export_helper_default(_sfc_main$341,[[`__scopeId`,`data-v-0ace1ddc`]]),_hoisted_1$299=[`tabindex`],_hoisted_2$247={key:0};const LABEL_ALIGNMENTS={START:`start`,END:`end`,CENTER:`center`};var _sfc_main$340={__name:`bngSwitch`,props:{modelValue:[Boolean,Number,String],checked:{type:Boolean,default:!1},label:String,labelBefore:Boolean,labelAlignment:{type:String,default:LABEL_ALIGNMENTS.END,validator:value=>Object.values(LABEL_ALIGNMENTS).includes(value)},inline:{type:Boolean,default:!0},alwaysTransparent:Boolean,disabled:Boolean,valueOn:{type:[Boolean,Number,String],default:void 0},valueOff:{type:[Boolean,Number,String],default:void 0}},emits:[`update:modelValue`,`change`,`valueChanged`],setup(__props,{emit:__emit}){let props=__props,emit$1=__emit,slots=useSlots(),bngSwitch=ref(null),valOn=computed(()=>props.valueOn===void 0?!0:props.valueOn),valOff=computed(()=>props.valueOff===void 0?!1:props.valueOff),isSwitchOn=computed(()=>props.modelValue==null?props.checked:props.modelValue===valOn.value);function onClicked(){if(props.disabled)return;let newValue=isSwitchOn.value?valOff.value:valOn.value;props.modelValue!=null&&emit$1(`update:modelValue`,newValue),emit$1(`valueChanged`,newValue),emit$1(`change`,newValue)}return onUpdated(()=>ensureFocus(bngSwitch.value)),(_ctx,_cache)=>withDirectives((openBlock(),createElementBlock(`div`,{ref_key:`bngSwitch`,ref:bngSwitch,"bng-nav-item":``,class:normalizeClass([`bng-switch`,{"bng-switch-on":isSwitchOn.value,"with-background":!__props.alwaysTransparent,"with-label":__props.label||unref(slots).default,"label-position-before":__props.labelBefore,"inline-switch":!__props.label&&!unref(slots).default||__props.inline}]),tabindex:__props.disabled?-1:0,onClick:onClicked},[_cache[0]||=createBaseVNode(`div`,{class:`bng-switch-control`},null,-1),unref(slots).default||__props.label?(openBlock(),createElementBlock(`div`,{key:0,class:normalizeClass([`bng-switch-label`,[`label-alignment-`+__props.labelAlignment]])},[renderSlot(_ctx.$slots,`default`,{},()=>[__props.label?(openBlock(),createElementBlock(`span`,_hoisted_2$247,toDisplayString(__props.label),1)):createCommentVNode(``,!0)],!0)],2)):createCommentVNode(``,!0)],10,_hoisted_1$299)),[[unref(BngOnUiNav_default),void 0,`ok`,{asMouse:!0,focusRequired:!0}],[unref(BngDisabled_default),__props.disabled]])}},bngSwitch_default=__plugin_vue_export_helper_default(_sfc_main$340,[[`__scopeId`,`data-v-8e1c4b05`]]),_hoisted_1$298={class:`bng-switch-label`},_hoisted_2$246={key:0},_sfc_main$339={__name:`bngSwitchOld`,props:{modelValue:Boolean,label:String,checked:Boolean,uncheckedWithBackground:Boolean,disabled:Boolean},emits:[`valueChanged`,`update:modelValue`],setup(__props,{emit:__emit}){let toggleValue=ref(!1),props=__props,emit$1=__emit,slots=useSlots();onBeforeMount(init$3),watch(()=>props.modelValue,init$3),watch(()=>props.checked,init$3),watch(()=>props.disabled,init$3);function init$3(){toggleValue.value=props.checked||props.modelValue}function onValueChanged(){props.disabled||(toggleValue.value=!toggleValue.value,emit$1(`update:modelValue`,toggleValue.value),emit$1(`valueChanged`,toggleValue.value))}return(_ctx,_cache)=>unref(slots).default||__props.label?withDirectives((openBlock(),createElementBlock(`div`,mergeProps({key:0,class:[`bng-labeled-switch`,{"switch-on":toggleValue.value,"with-background":__props.uncheckedWithBackground}]},{...!__props.disabled&&{"bng-nav-item":1}},{tabindex:`{{disabled ? 0 : 1}}`,onClick:onValueChanged,onKeyup:withKeys(onValueChanged,[`space`])}),[_cache[0]||=createBaseVNode(`div`,{class:`bng-switch-wrapper`},[createBaseVNode(`div`,{class:`bng-switch`})],-1),createBaseVNode(`div`,_hoisted_1$298,[renderSlot(_ctx.$slots,`default`,{},()=>[__props.label?(openBlock(),createElementBlock(`label`,_hoisted_2$246,toDisplayString(__props.label),1)):createCommentVNode(``,!0)],!0)])],16)),[[unref(BngDisabled_default),__props.disabled]]):withDirectives((openBlock(),createElementBlock(`div`,mergeProps({key:1},{...!__props.disabled&&{"bng-nav-item":1}},{tabindex:`{{disabled ? 0 : 1}}`,class:[`bng-switch-wrapper`,{"switch-on":toggleValue.value}],onClick:onValueChanged,onKeyup:withKeys(onValueChanged,[`space`])}),[..._cache[1]||=[createBaseVNode(`div`,{class:`bng-switch`},null,-1)]],16)),[[unref(BngDisabled_default),__props.disabled]])}},bngSwitchOld_default=__plugin_vue_export_helper_default(_sfc_main$339,[[`__scopeId`,`data-v-da8dc7b1`]]),_hoisted_1$297={"bng-nav-item":``,class:`bng-tile tile`},_hoisted_2$245={class:`content`},_hoisted_3$218={class:`label`},_sfc_main$338={__name:`bngTile`,props:{label:String,ratio:{type:String,default:`4:3`},backgroundImage:String,backgroundExternalImage:String,disabled:Boolean},setup(__props){return(_ctx,_cache)=>withDirectives((openBlock(),createElementBlock(`div`,_hoisted_1$297,[createVNode(unref(aspectRatio_default),{class:`content-container image`,ratio:__props.ratio,image:__props.backgroundImage,externalImage:__props.backgroundExternalImage,imageMode:`contain`},{default:withCtx(()=>[createBaseVNode(`div`,_hoisted_2$245,[renderSlot(_ctx.$slots,`default`,{},void 0,!0)])]),_:3},8,[`ratio`,`image`,`externalImage`]),renderSlot(_ctx.$slots,`label`,{},()=>[createBaseVNode(`div`,_hoisted_3$218,toDisplayString(__props.label),1)],!0)])),[[unref(BngDisabled_default),__props.disabled]])}},bngTile_default=__plugin_vue_export_helper_default(_sfc_main$338,[[`__scopeId`,`data-v-af5747cc`]]),_sfc_main$337={__name:`bngTooltip`,props:{text:{type:String,required:!0},position:{type:String,default:`top`}},setup(__props){return(_ctx,_cache)=>withDirectives((openBlock(),createElementBlock(`div`,null,[renderSlot(_ctx.$slots,`default`,{},void 0,!0)])),[[unref(BngTooltip_default),__props.text,__props.position]])}},bngTooltip_default=__plugin_vue_export_helper_default(_sfc_main$337,[[`__scopeId`,`data-v-53073c36`]]),toInt=v=>~~+v,_sfc_main$336={__name:`bngUnit`,props:{options:Object,formatter:[Function,String]},setup(__props){let{units}=useBridge(),knownUnits={money:{formatter:v=>units.beamBucks(v)},beamXP:{formatter:toInt},stars:{formatter:toInt},vouchers:{formatter:toInt},insuranceScore:{formatter:toInt},multiplier:{formatter:toInt,noGap:!0}},defaultColors={stars:`var(--bng-ter-yellow-200)`,vouchers:`var(--bng-add-blue-400)`},attrs=useAttrs(),unit=computed(()=>{for(let key of Object.keys(attrs))if(key in knownUnits)return{type:key,value:attrs[key],...knownUnits[key],...props.options};return{type:`unknown`}}),formattedValue=computed(()=>{if(props.formatter){if(typeof props.formatter==`function`)return props.formatter(unit.value.value);if(typeof props.formatter==`string`&&props.formatter in knownUnits)return knownUnits[props.formatter].formatter(unit.value.value)}return typeof unit.value.formatter==`function`?unit.value.formatter(unit.value.value):unit.value.value}),props=__props;return(_ctx,_cache)=>(openBlock(),createBlock(unref(slotSwitcher_default),mergeProps(unref(attrs),{slotId:unit.value.type}),{money:withCtx(props$1=>[createVNode(unref(bngPropVal_default),mergeProps({...props$1,...unit.value},{iconType:props$1.iconType||unref(icons).beamCurrency,valueLabel:formattedValue.value}),null,16,[`iconType`,`valueLabel`])]),beamXP:withCtx(props$1=>[createVNode(unref(bngPropVal_default),mergeProps({...props$1,...unit.value},{iconType:props$1.iconType||unref(icons).beamXPLo,valueLabel:formattedValue.value}),null,16,[`iconType`,`valueLabel`])]),stars:withCtx(props$1=>[createVNode(unref(bngPropVal_default),mergeProps({...props$1,...unit.value},{iconType:props$1.iconType||unref(icons).star,valueLabel:formattedValue.value,"icon-color":defaultColors.stars}),null,16,[`iconType`,`valueLabel`,`icon-color`])]),vouchers:withCtx(props$1=>[createVNode(unref(bngPropVal_default),mergeProps({...props$1,...unit.value},{iconType:props$1.iconType||unref(icons).voucherHorizontal3,valueLabel:formattedValue.value,"icon-color":defaultColors.vouchers}),null,16,[`iconType`,`valueLabel`,`icon-color`])]),insuranceScore:withCtx(props$1=>[createVNode(unref(bngPropVal_default),mergeProps({...props$1,...unit.value},{iconType:props$1.iconType||unref(icons).shieldCheckmarkProgressbar,valueLabel:formattedValue.value}),null,16,[`iconType`,`valueLabel`])]),multiplier:withCtx(props$1=>[createVNode(unref(bngPropVal_default),mergeProps({...props$1,...unit.value},{iconType:props$1.iconType||unref(icons).mathMultiply,valueLabel:formattedValue.value,"icon-color":defaultColors.multiplier}),null,16,[`iconType`,`valueLabel`,`icon-color`])]),unknown:withCtx(props$1=>[createBaseVNode(`span`,normalizeProps(guardReactiveProps(props$1)),`BngUnit: Unknown unit type or no type specified`,16)]),_:1},16,[`slotId`]))}},bngUnit_default=_sfc_main$336;const DEMOS={};var base_exports=__export({ACCENTS:()=>ACCENTS,BngActionDrawer:()=>bngActionDrawer_default,BngActionsDrawer:()=>bngActionsDrawer_default,BngActionsDrawerOne:()=>bngActionsDrawerOne_default,BngActionsList:()=>bngActionsList_default,BngBinding:()=>bngBinding_default,BngBreadcrumbs:()=>bngBreadcrumbs_default,BngButton:()=>bngButton_default,BngCard:()=>bngCard_default,BngCardHeading:()=>bngCardHeading_default,BngColorPicker:()=>bngColorPicker_default,BngColorSlider:()=>bngColorSlider_default,BngColorTile:()=>bngColorTile_default,BngCondition:()=>bngCondition_default,BngControllerHint:()=>bngControllerHint_default,BngDivider:()=>bngDivider_default,BngDrawer:()=>bngDrawer_default,BngDrawerOld:()=>bngDrawerOld_default,BngDropdown:()=>bngDropdown_default,BngDropdownContainer:()=>bngDropdownContainer_default,BngIcon:()=>bngIcon_default,BngIconMarker:()=>bngIconMarker_default,BngImage:()=>bngImage_default,BngImageAsset:()=>bngImageAsset_default,BngImageCarousel:()=>bngImageCarousel_default,BngImageTile:()=>bngImageTile_default,BngInput:()=>bngInput_default,BngInputNew:()=>bngInputNew_default,BngList:()=>bngList_default,BngMainStars:()=>bngMainStars_default,BngMultilineInput:()=>bngMultilineInput_default,BngOldIcon:()=>bngOldIcon_default,BngOverflowContainer:()=>bngOverflowContainer_default,BngPaintTile:()=>bngPaintTile_default,BngPill:()=>bngPill_default,BngPillCheckbox:()=>bngPillCheckbox_default,BngPillFilters:()=>bngPillFilters_default,BngPillFiltersContainer:()=>bngPillFiltersContainer_default,BngPopoverContent:()=>bngPopoverContent_default,BngPopoverMenu:()=>bngPopoverMenu_default,BngProgressBar:()=>bngProgressBar_default,BngPropVal:()=>bngPropVal_default,BngScreenHeading:()=>bngScreenHeading_default,BngScreenHeadingV2:()=>bngScreenHeadingV2_default,BngSelect:()=>bngSelect_default,BngSimpleGraph:()=>bngSimpleGraph_default,BngSlider:()=>bngSlider_default,BngSmartSelect:()=>bngSmartSelect_default,BngSpriteIcon:()=>bngSpriteIcon_default,BngSwitch:()=>bngSwitch_default,BngSwitchOld:()=>bngSwitchOld_default,BngTile:()=>bngTile_default,BngTooltip:()=>bngTooltip_default,BngUnit:()=>bngUnit_default,DEMOS:()=>DEMOS,LABEL_ALIGNMENTS:()=>LABEL_ALIGNMENTS,LIST_LAYOUTS:()=>LIST_LAYOUTS,STEP_ICON_TYPES:()=>STEP_ICON_TYPES,getIconsWithTags:()=>getIconsWithTags,icons:()=>icons,iconsBySize:()=>iconsBySize,iconsByTag:()=>iconsByTag});function getPopupWrapperDefaults(){return{fade:!1,blur:!0,style:[popupContainer.default]}}function getActivityWrapperDefaults(){return{fade:!1,blur:!1,style:[popupContainer.clickthrough]}}const popupContainer=Object.freeze({default:`default`,transparent:`transparent`,clickthrough:`clickthrough`}),popupPosition=Object.freeze({default:`center`,top:`top`,left:`left`,right:`right`,bottom:`bottom`,center:`center`,fullscreen:`fullscreen`});var _hoisted_1$296=[`bng-ui-scope`],_hoisted_2$244={class:`popup-content`},_hoisted_3$217={key:0,class:`popup-title`},_hoisted_4$186={key:1,class:`popup-body`},_hoisted_5$159=[`innerHTML`],_hoisted_6$137={class:`popup-buttons`},__default__$10={wrapper:{blur:!0,style:null},position:popupPosition.center,animated:!0},_sfc_main$335=Object.assign(__default__$10,{__name:`Confirmation`,props:{appearance:String,popupActive:Boolean,message:{type:[String,Object],required:!0},title:String,buttons:Array},emits:[`return`],setup(__props,{emit:__emit}){useUINavBlocker().allowNavigationOnly();let props=__props,emit$1=__emit,scopeName=usePopupUINavScopeName(`_confirmPopup`,props),defaultButtonIndex=props.buttons.findIndex(button=>button.extras&&button.extras.default);defaultButtonIndex===-1&&(defaultButtonIndex=0);let cancelButton=props.buttons.find(button=>button.extras&&button.extras.cancel),exclude=[`default`,`cancel`],buttonProps=computed(()=>{let bp=[];for(let{extras}of props.buttons)extras?bp.push(Object.keys(extras).reduce((ex,key)=>exclude.includes(key)?ex:{...ex,[key]:extras[key]},{})):bp.push({});return bp}),messageIsComponent=computed(()=>props.message&&typeof props.message==`object`&&props.message.component),handleCancelWithBack=()=>emit$1(`return`,cancelButton?cancelButton.value:null);return(_ctx,_cache)=>withDirectives((openBlock(),createElementBlock(`div`,{class:normalizeClass([`popup`,`popup-style-`+__props.appearance]),"bng-ui-scope":unref(scopeName)},[createBaseVNode(`div`,_hoisted_2$244,[__props.title?(openBlock(),createElementBlock(`div`,_hoisted_3$217,toDisplayString(__props.title),1)):createCommentVNode(``,!0),messageIsComponent.value?(openBlock(),createElementBlock(`div`,_hoisted_4$186,[(openBlock(),createBlock(resolveDynamicComponent(__props.message.component),normalizeProps(guardReactiveProps(__props.message.props)),null,16))])):(openBlock(),createElementBlock(`div`,{key:2,class:`popup-body`,innerHTML:__props.message},null,8,_hoisted_5$159)),createBaseVNode(`div`,_hoisted_6$137,[(openBlock(!0),createElementBlock(Fragment,null,renderList(__props.buttons,(button,index)=>withDirectives((openBlock(),createBlock(unref(bngButton_default),mergeProps({key:index},{ref_for:!0},buttonProps.value[index],{onClick:$event=>_ctx.$emit(`return`,button.value)}),{default:withCtx(()=>[createTextVNode(toDisplayString(button.label),1)]),_:2},1040,[`onClick`])),[[unref(BngUiNavFocus_default),index===unref(defaultButtonIndex)?1e3:void 0]])),128))])])],10,_hoisted_1$296)),[[unref(BngOnUiNav_default),handleCancelWithBack,`back,menu`]])}}),Confirmation_default=__plugin_vue_export_helper_default(_sfc_main$335,[[`__scopeId`,`data-v-ce4a758b`]]),_hoisted_1$295=[`bng-ui-scope`],_hoisted_2$243={key:0,class:`form-dialog-toolbar`},_hoisted_3$216={class:`toolbar-title`},_hoisted_4$185={key:0,class:`content-description`},_hoisted_5$158={class:`content-wrapper`},_hoisted_6$136={class:`form-actions-bar`},_sfc_main$334={__name:`FormDialog`,props:mergeModels({title:{type:String},description:{type:String},view:{type:[Object,String],required:!0},formValidator:{type:Function,default:formModel=>!0},buttons:{type:Array,required:!0},maxWidth:{type:String,default:`40rem`}},{formModel:{},formModelModifiers:{}}),emits:mergeModels([`return`],[`update:formModel`]),setup(__props,{emit:__emit}){useUINavBlocker().allowOnly([`focus_u`,`focus_d`,`focus_l`,`focus_r`,`back`,`menu`,`ok`]);let props=__props,emit$1=__emit,formModel=useModel(__props,`formModel`),scopeName=usePopupUINavScopeName(`_formdialog`,props),handleCancelWithBack=()=>{let cancelButton=props.buttons.find(x=>x.extras&&x.extras.cancel);cancelButton?onClick(cancelButton):emit$1(`return`)},onClick=button=>{let data={value:button.value};button.emitData&&(data.formData=formModel.value),emit$1(`return`,data)},formValid=ref(!1),message=ref(null);return watch(formModel,()=>{let res=props.formValidator(formModel.value);message.value=res.error?res.message:props.description,formValid.value=!res.error},{immediate:!0,deep:!0}),(_ctx,_cache)=>withDirectives((openBlock(),createElementBlock(`div`,{class:`form-dialog`,style:normalizeStyle({maxWidth:props.maxWidth}),"bng-ui-scope":unref(scopeName)},[__props.title?(openBlock(),createElementBlock(`div`,_hoisted_2$243,[createBaseVNode(`div`,_hoisted_3$216,toDisplayString(__props.title),1)])):createCommentVNode(``,!0),createBaseVNode(`div`,{class:normalizeClass([{"no-title":!__props.title},`form-dialog-content`])},[message.value?(openBlock(),createElementBlock(`div`,_hoisted_4$185,toDisplayString(message.value),1)):createCommentVNode(``,!0),createBaseVNode(`div`,_hoisted_5$158,[(openBlock(),createBlock(resolveDynamicComponent(__props.view),{modelValue:formModel.value,"onUpdate:modelValue":_cache[0]||=$event=>formModel.value=$event},null,8,[`modelValue`]))])],2),createBaseVNode(`div`,_hoisted_6$136,[(openBlock(!0),createElementBlock(Fragment,null,renderList(__props.buttons,(button,index)=>withDirectives((openBlock(),createBlock(unref(bngButton_default),mergeProps({key:index},{ref_for:!0},button.extras,{disabled:button.disableIfInvalid&&!formValid.value,onClick:$event=>onClick(button)}),{default:withCtx(()=>[createTextVNode(toDisplayString(button.label),1)]),_:2},1040,[`disabled`,`onClick`])),[[unref(BngUiNavFocus_default),__props.buttons.length-index],[unref(BngFocusIf_default),index===0]])),128))])],12,_hoisted_1$295)),[[unref(BngOnUiNav_default),handleCancelWithBack,`back,menu`]])}},FormDialog_default=__plugin_vue_export_helper_default(_sfc_main$334,[[`__scopeId`,`data-v-e78a3aa6`]]),_hoisted_1$294=[`bng-ui-scope`],_hoisted_2$242={class:`popup-content`},_hoisted_3$215={key:0,class:`popup-title`},_hoisted_4$184={class:`popup-body`},_hoisted_5$157={key:0,class:`popup-message`},_hoisted_6$135={class:`popup-buttons`},_sfc_main$333={__name:`Progress`,props:{title:String,message:String,buttons:Array,indeterminate:Boolean,min:{type:Number,default:0},max:{type:Number,default:100},initialValue:{type:Number,default:0},valueLabelFormat:{type:[String,Function],default:()=>val=>`${val}%`},timeout:{type:Number,default:0},cancellable:Boolean,tunnel:Object},emits:[`return`],setup(__props,{emit:__emit}){useUINavBlocker().allowOnly([`focus_u`,`focus_d`,`focus_l`,`focus_r`,`back`,`menu`,`ok`]);let emit$1=__emit,DEFAULT_BUTTON_ID=uniqueId(`___DEFAULT`,`_`),props=__props,defaultButtonIndex=props.buttons.findIndex(button=>button.extras&&button.extras.default),cancelButton=props.buttons.find(button=>button.extras&&button.extras.cancel);~defaultButtonIndex&&onMounted(()=>{document.querySelector(`#${DEFAULT_BUTTON_ID}`).focus()});let scopeName=usePopupUINavScopeName(`_progressPopup`,props),progressValue=ref(props.initialValue),msg=ref(props.message),handleCancelWithBack=e=>{props.cancellable&&close()},close=()=>emit$1(`return`,cancelButton?cancelButton.value:null);return props.tunnel.update=(value,message=void 0)=>{progressValue.value=+value,message!==void 0&&(msg.value=message)},props.tunnel.done=close,props.tunnel.ready=!0,props.timeout&&setTimeout(close,props.timeout*1e3),(_ctx,_cache)=>withDirectives((openBlock(),createElementBlock(`div`,{class:normalizeClass([`popup`]),"bng-ui-scope":unref(scopeName)},[createBaseVNode(`div`,_hoisted_2$242,[__props.title?(openBlock(),createElementBlock(`div`,_hoisted_3$215,toDisplayString(__props.title),1)):createCommentVNode(``,!0),createBaseVNode(`div`,_hoisted_4$184,[msg.value?(openBlock(),createElementBlock(`div`,_hoisted_5$157,toDisplayString(msg.value),1)):createCommentVNode(``,!0),createVNode(unref(bngProgressBar_default),{value:progressValue.value,min:__props.min,max:__props.max,indeterminate:__props.indeterminate,"show-value-label":!__props.indeterminate&&!!__props.valueLabelFormat,"value-label-format":__props.valueLabelFormat},null,8,[`value`,`min`,`max`,`indeterminate`,`show-value-label`,`value-label-format`])]),createBaseVNode(`div`,_hoisted_6$135,[__props.buttons&&__props.buttons.length?(openBlock(!0),createElementBlock(Fragment,{key:0},renderList(__props.buttons,(button,index)=>(openBlock(),createBlock(unref(bngButton_default),mergeProps({key:index},{ref_for:!0},{...index==unref(defaultButtonIndex)&&{id:unref(DEFAULT_BUTTON_ID)},...button.extras},{onClick:$event=>_ctx.$emit(`return`,typeof button.value==`function`?button.value(_ctx.text):button.value)}),{default:withCtx(()=>[createTextVNode(toDisplayString(button.label),1)]),_:2},1040,[`onClick`]))),128)):createCommentVNode(``,!0)])])],8,_hoisted_1$294)),[[unref(BngOnUiNav_default),handleCancelWithBack,`back,menu`]])}},Progress_default=__plugin_vue_export_helper_default(_sfc_main$333,[[`__scopeId`,`data-v-a3c03360`]]),_hoisted_1$293=[`bng-ui-scope`],_hoisted_2$241={class:`popup-content`},_hoisted_3$214={key:0,class:`popup-title`},_hoisted_4$183={class:`popup-body`},_hoisted_5$156={key:0,class:`popup-message`},_hoisted_6$134={class:`popup-buttons`},_sfc_main$332={__name:`Prompt`,props:{buttons:Array,message:String,title:String,maxLength:Number,defaultValue:void 0,validate:Function,errorMessage:String,disableWhenInvalid:Boolean},emits:[`return`],setup(__props,{emit:__emit}){let emit$1=__emit,DEFAULT_BUTTON_ID=uniqueId(`___DEFAULT`,`_`),INPUT_ID=uniqueId(`___INPUT`,`_`),props=__props,scopeName=usePopupUINavScopeName(`_promptPopup`,props),text=ref(props.defaultValue||``),defaultButtonIndex=props.buttons.findIndex(button=>button.extras&&button.extras.default),cancelButton=props.buttons.find(button=>button.extras&&button.extras.cancel),handleEnterButton=text$1=>{props.disableWhenInvalid&&props.validate&&!props.validate(text$1)||emit$1(`return`,text$1)},handleCancelWithBack=e=>{emit$1(`return`,cancelButton?cancelButton.value:null)};return onMounted(()=>{document.querySelector(`#${INPUT_ID} input`).focus()}),(_ctx,_cache)=>withDirectives((openBlock(),createElementBlock(`div`,{class:normalizeClass([`popup`]),"bng-ui-scope":unref(scopeName)},[createBaseVNode(`div`,_hoisted_2$241,[__props.title?(openBlock(),createElementBlock(`div`,_hoisted_3$214,toDisplayString(__props.title),1)):createCommentVNode(``,!0),createBaseVNode(`div`,_hoisted_4$183,[__props.message?(openBlock(),createElementBlock(`div`,_hoisted_5$156,toDisplayString(__props.message),1)):createCommentVNode(``,!0),createVNode(unref(bngInput_default),{id:unref(INPUT_ID),modelValue:text.value,"onUpdate:modelValue":_cache[0]||=$event=>text.value=$event,maxlength:__props.maxLength,onKeyup:_cache[1]||=withKeys($event=>handleEnterButton(text.value),[`enter`]),validate:__props.validate,"error-message":__props.errorMessage},null,8,[`id`,`modelValue`,`maxlength`,`validate`,`error-message`])]),createBaseVNode(`div`,_hoisted_6$134,[(openBlock(!0),createElementBlock(Fragment,null,renderList(__props.buttons,(button,index)=>(openBlock(),createBlock(unref(bngButton_default),mergeProps({key:index},{ref_for:!0},{...index==unref(defaultButtonIndex)&&{id:unref(DEFAULT_BUTTON_ID)},...button.extras},{disabled:__props.disableWhenInvalid&&index>0&&__props.validate&&!__props.validate(text.value),onClick:$event=>_ctx.$emit(`return`,typeof button.value==`function`?button.value(text.value):button.value)}),{default:withCtx(()=>[createTextVNode(toDisplayString(button.label),1)]),_:2},1040,[`disabled`,`onClick`]))),128))])])],8,_hoisted_1$293)),[[unref(BngOnUiNav_default),handleCancelWithBack,`back,menu`]])}},Prompt_default=__plugin_vue_export_helper_default(_sfc_main$332,[[`__scopeId`,`data-v-cce4437b`]]),__default__$9={position:popupPosition.left},_sfc_main$331=Object.assign(__default__$9,{__name:`ScreenOverlay`,props:{view:Object},emits:[`return`],setup(__props){return(_ctx,_cache)=>(openBlock(),createBlock(resolveDynamicComponent(__props.view),{onClose:_cache[0]||=$event=>_ctx.$emit(`return`,!0)},null,32))}}),ScreenOverlay_default=_sfc_main$331,popup_components_exports=__export({Confirmation:()=>Confirmation_default,FormDialog:()=>FormDialog_default,Progress:()=>Progress_default,Prompt:()=>Prompt_default,ScreenOverlay:()=>ScreenOverlay_default}),popupLimit=5,activityLimit=3,count=-1;const PopupTypes=Object.freeze({activity:10,normal:100,priority:1e3});var PopupTypesBack=Object.freeze(Object.keys(PopupTypes).reduce((res,key)=>({...res,[String(PopupTypes[key])]:key}),{})),PopupTypesPairs=Object.freeze(Object.keys(PopupTypes).map(key=>[PopupTypes[key],key]).sort((a$1,b)=>a$1[0]-b[0]));function getPopupTypeName(type=PopupTypes.normal){let strType=String(type);if(strType in PopupTypesBack)return PopupTypesBack[strType];for(let[ptype,pname]of PopupTypesPairs)if(typepopupsAll.filter(itm=>itm.type>=PopupTypes.normal)),activitiesFiltered=computed(()=>popupsAll.filter(itm=>itm.typepopupsFiltered.value.length>0?popupsFiltered.value.slice(-popupLimit):null),popupsWrapper:computed(()=>accumulateWrapper(popupsFiltered.value,getPopupWrapperDefaults())),activities:computed(()=>activitiesFiltered.value.length>0?activitiesFiltered.value.slice(-activityLimit):null),activitiesWrapper:computed(()=>accumulateWrapper(activitiesFiltered.value,getActivityWrapperDefaults()))});function accumulateWrapper(popups,wrapper){for(let popup of popups)wrapper.fade!==popup.wrapper.fade&&(wrapper.fade=popup.wrapper.fade),wrapper.blur!==popup.wrapper.blur&&(wrapper.blur=popup.wrapper.blur),popup.wrapper.style&&wrapper.style.push(...popup.wrapper.style);return wrapper}function addPopup(componentOrName,props={},type=PopupTypes.normal){let component=typeof componentOrName==`string`?popup_components_exports[componentOrName]:componentOrName;if(!component)throw Error(`There is no popup base component named "${componentOrName}".Available components: "${Object.keys(popup_components_exports).join(`", "`)}"`);let popup={id:++count,active:!1,type,typeName:getPopupTypeName(type),component:markRaw({ref:component}),componentName:component.__name,props:{__id:count,...props},position:[popupPosition.default],animated:!0,wrapper:type>=PopupTypes.normal?getPopupWrapperDefaults():getActivityWrapperDefaults()};component.position&&(popup.position=Array.isArray(component.position)?component.position:[component.position]),typeof component.animated==`boolean`&&(popup.animated=component.animated),`wrapper`in component&&(typeof component.wrapper.fade==`boolean`&&(popup.wrapper.fade=component.wrapper.fade),typeof component.wrapper.blur==`boolean`&&(popup.wrapper.blur=component.wrapper.blur),component.wrapper.style&&(popup.wrapper.style=Array.isArray(component.wrapper.style)?component.wrapper.style:[component.wrapper.style])),popup.promise=new Promise((resolve$1,reject)=>{popup._resolve=resolve$1,popup._reject=reject}),popup.return=result=>{for(let i=0;i0&&(popupsAll[popupsAll.length-1].active=!0),reportPopupState(popup,!1);break}result===void 0?popup._reject():popup._resolve(result)},popup.promise.close=popup.return;for(let i=0;itype)return popupsAll.splice(i,0,popup),reportPopupState(popup,!0),popup;return popupsAll.length>0&&(popupsAll[popupsAll.length-1].active=!1),popup.active=!0,popupsAll.push(popup),reportPopupState(popup,!0),popup}function closeLastPopups(count$1=1){popupsAll.slice(-count$1).forEach(popup=>popup.return())}const openMessage=(title,message)=>addPopup(`Confirmation`,{title,message,buttons:[{label:$translate.instant(`ui.common.okay`),value:!0,extras:{default:!0}}]}).promise,openConfirmation=(title,message,buttons=[{label:$translate.instant(`ui.common.okay`),value:!0,extras:{default:!0}},{label:$translate.instant(`ui.common.cancel`),value:!1,extras:{cancel:!0,accent:ACCENTS.secondary}}],appearance=``)=>addPopup(`Confirmation`,{title,message,buttons,appearance}).promise,openPrompt=(message=``,title=``,{buttons=[{label:$translate.instant(`ui.common.okay`),value:text=>text},{label:$translate.instant(`ui.common.cancel`),value:!1,extras:{cancel:!0,accent:ACCENTS.secondary}}],defaultValue,maxLength,validate,errorMessage,disableWhenInvalid}={})=>addPopup(`Prompt`,{message,title,buttons,defaultValue,maxLength,validate,errorMessage,disableWhenInvalid}).promise,openExperimental=(title,message,buttons=[{label:$translate.instant(`ui.common.yes`),value:!0},{label:$translate.instant(`ui.common.no`),value:!1}])=>addPopup(`Confirmation`,{title,message,buttons,appearance:`experimental`}).promise,openScreenOverlay=component=>addPopup(`ScreenOverlay`,{view:markRaw(component)},PopupTypes.activity).promise,openFormDialog=(component,formModel,formValidator,title,description,buttons=[{label:$translate.instant(`ui.common.okay`),value:!0,emitData:!0},{label:$translate.instant(`ui.common.cancel`),value:!1,extras:{cancel:!0,accent:ACCENTS.secondary}}],maxWidth)=>addPopup(`FormDialog`,{view:markRaw(component),formModel,formValidator,title,description,buttons,maxWidth},PopupTypes.normal).promise,openProgress=(message=``,title=``,{buttons=[],indeterminate,min:min$1,max:max$1,initialValue,valueLabelFormat,timeout,cancellable}={})=>{let popup=addPopup(`Progress`,{message,title,buttons,indeterminate,min:min$1,max:max$1,initialValue,valueLabelFormat,timeout,cancellable,tunnel:{}});return popup.progress=popup.props.tunnel,popup.progress.done=popup.return,popup},fixedDelayPopup=(seconds,{makeRemainingText=s=>s?Math.round(s)+`s remaining...`:`Done!`,title=``}={})=>{let popup=openProgress(makeRemainingText(seconds),title,{timeout:seconds+1}),remaining=seconds,endTime=Date.now()+remaining*1e3,countdown=()=>{let timeLeft=(endTime-Date.now())/1e3;timeLeft>0?(remaining=timeLeft,requestAnimationFrame(countdown)):remaining=0,popup.progress.update(~~((seconds-remaining)*100/seconds),makeRemainingText(remaining))};return requestAnimationFrame(countdown),popup};var _hoisted_1$292={class:`activity-selector`},_hoisted_2$240={class:`activities-container`},_hoisted_3$213=[`onClick`],_hoisted_4$182={class:`selector-display`},selectConfig={label:x=>x.label,value:x=>x.value},_sfc_main$330={__name:`ActivitySelector`,props:{activities:{type:Array,required:!0},value:{type:[String,Number]},navLeftEvent:{type:String},navRightEvent:{type:String}},emits:[`valueChanged`],setup(__props,{expose:__expose,emit:__emit}){let props=__props,selectComponent=ref(),emit$1=__emit,activityOptions=computed(()=>props.activities.map((x,index)=>({label:index+1,value:x.value})));computed(()=>(activityOptions.value?activityOptions.value.find(x=>x.value===selectedValue.value):null)||{label:`?`,value:selectedValue.value});let selectedValue=ref(1);watch(()=>props.value,val=>selectedValue.value=val||props.activities[0].value,{immediate:!0});let onValueChanged=value=>{selectedValue.value=value,console.log(`onValueChanged`,value),emit$1(`valueChanged`,value)};return __expose({goNext:()=>selectComponent.value.goNext(),goPrev:()=>selectComponent.value.goPrev()}),computed(()=>`url("${getAssetURL(`icons/temp_debug/map_poi_target.svg`)}")`),(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$292,[createBaseVNode(`div`,_hoisted_2$240,[(openBlock(!0),createElementBlock(Fragment,null,renderList(__props.activities,activity=>(openBlock(),createElementBlock(`div`,{key:activity,class:normalizeClass([`activity-icon`,{highlighted:activity.value===selectedValue.value}]),onClick:$event=>onValueChanged(activity.value)},[createVNode(unref(bngSpriteIcon_default),{src:`map_`+activity.icon,style:{width:`100%`,height:`100%`}},null,8,[`src`])],10,_hoisted_3$213))),128))]),createVNode(unref(bngSelect_default),{ref_key:`selectComponent`,ref:selectComponent,value:selectedValue.value,options:activityOptions.value,config:selectConfig,mute:``,loop:``,onChange:onValueChanged,navLeftEvent:__props.navLeftEvent,navRightEvent:__props.navRightEvent},{display:withCtx(({label})=>[createBaseVNode(`div`,_hoisted_4$182,[createBaseVNode(`span`,null,toDisplayString(label),1),createVNode(unref(bngDivider_default)),createBaseVNode(`span`,null,toDisplayString(__props.activities.length),1)])]),_:1},8,[`value`,`options`,`navLeftEvent`,`navRightEvent`])]))}},ActivitySelector_default=__plugin_vue_export_helper_default(_sfc_main$330,[[`__scopeId`,`data-v-53fb9327`]]),_hoisted_1$291={key:0,class:`activity-start`,"bng-ui-scope":`activityStart`},_hoisted_2$239={class:`activity-props`},_hoisted_3$212={class:`binding-spacer`},BNG_MAIN_STARS_TYPE=`BngMainStars`,_sfc_main$329={__name:`ActivityStart`,setup(__props){useUINavScope(`activityStart`);let activitySelector=ref(null),goNext=()=>activitySelector.value&&activitySelector.value.goNext(),goPrev=()=>activitySelector.value&&activitySelector.value.goPrev(),gameContextStore=useGameContextStore(),{activities}=storeToRefs(gameContextStore),{closeActivitiesPrompt}=gameContextStore,selectedActivityIndex=ref(0),availableActivities=ref([]),activityOptions=computed(()=>{let result=availableActivities.value?availableActivities.value.map((x,index)=>({id:index,value:index,icon:x.icon})):[];return doFiltering&&filterEvents(result.length>1),result}),selectedActivity=computed(()=>{if(selectedActivityIndex.value<0||!availableActivities.value||availableActivities.value.length===0)return null;let activity=availableActivities.value[selectedActivityIndex.value],labels=activity.props&&activity.props.length>0?activity.props.filter(x=>!x.type):[];return{heading:activity.heading,icon:activity.icon,preheadings:activity.preheadings,labels:labels.map(x=>({keyLabel:$translate.instant(x.keyLabel),valueLabel:$translate.instant(x.valueLabel),icon:icons[x.icon]})),stars:activity.props&&activity.props.length>0?activity.props.find(x=>x.type===BNG_MAIN_STARS_TYPE):null,startable:!0,buttonLabel:activity.buttonLabel,action:activity.action,missionInfoPerformActionIndex:activity.missionInfoPerformActionIndex}}),preheadings=computed(()=>selectedActivity.value&&selectedActivity.value.preheadings?selectedActivity.value.preheadings.map(x=>$translate.contextTranslate(x)):[]),invokeActivityAction=()=>{Lua_default.ui_missionInfo.performActivityAction(selectedActivity.value.missionInfoPerformActionIndex)};watch(selectedActivity,()=>{Lua_default.ui_missionInfo.setActivityIndexVisible(selectedActivityIndex.value)});let onActivitySelected=value=>{selectedActivityIndex.value=value},onCancel=()=>{closeActivitiesPrompt()},openPauseMenu=()=>{onCancel(),window.globalAngularRootScope&&window.globalAngularRootScope.$broadcast(`MenuToggle`)};onBeforeMount(()=>{availableActivities.value=activities.value}),onMounted(()=>{getUINavServiceInstance().activate()}),onUnmounted(()=>{doFiltering=!1,getUINavServiceInstance().setFilteredEventsAllExcept(UI_EVENTS.menu,UI_EVENTS.pause,UI_EVENTS.center_cam),Lua_default.ui_missionInfo.setActivityIndexVisible(-1)});let doFiltering=!0,filterEvents=withTabs=>getUINavServiceInstance().setFilteredEventsAllExcept(UI_EVENTS.back,UI_EVENTS.menu,UI_EVENTS.pause,UI_EVENTS.center_cam,...withTabs?[UI_EVENTS.tab_l,UI_EVENTS.tab_r]:[]);return(_ctx,_cache)=>selectedActivity.value?withDirectives((openBlock(),createElementBlock(`div`,_hoisted_1$291,[activityOptions.value&&activityOptions.value.length>1?(openBlock(),createBlock(ActivitySelector_default,{key:0,ref_key:`activitySelector`,ref:activitySelector,activities:activityOptions.value,value:selectedActivityIndex.value,onValueChanged:onActivitySelected,navLeftEvent:`tab_l`,navRightEvent:`tab_r`},null,8,[`activities`,`value`])):createCommentVNode(``,!0),selectedActivity.value.heading?(openBlock(),createBlock(unref(bngScreenHeading_default),{key:1,mute:``,divider:``,preheadings:preheadings.value,"blur-delay":400},{default:withCtx(()=>[createTextVNode(toDisplayString(_ctx.$ctx_t(selectedActivity.value.heading)),1),selectedActivity.value.description?(openBlock(),createElementBlock(Fragment,{key:0},[createTextVNode(`: `+toDisplayString(_ctx.$ctx_t(selectedActivity.value.description)),1)],64)):createCommentVNode(``,!0)]),_:1},8,[`preheadings`])):createCommentVNode(``,!0),createBaseVNode(`div`,_hoisted_2$239,[selectedActivity.value.stars&&selectedActivity.value.stars.defaultStarCount?(openBlock(),createBlock(unref(bngMainStars_default),{key:0,"unlocked-stars":selectedActivity.value.stars.defaultUnlockedStarCount,"total-stars":selectedActivity.value.stars.defaultStarCount,class:`main-stars`},null,8,[`unlocked-stars`,`total-stars`])):createCommentVNode(``,!0),selectedActivity.value.stars&&selectedActivity.value.stars.bonusStarCount?(openBlock(),createBlock(unref(bngMainStars_default),{key:1,"unlocked-stars":selectedActivity.value.stars.bonusStarsUnlockedCount,"total-stars":selectedActivity.value.stars.bonusStarCount,class:`bonus-stars`},null,8,[`unlocked-stars`,`total-stars`])):createCommentVNode(``,!0),(openBlock(!0),createElementBlock(Fragment,null,renderList(selectedActivity.value.labels,(label,index)=>(openBlock(),createBlock(unref(bngPropVal_default),{key:index,iconType:label.icon,keyLabel:label.keyLabel,valueLabel:label.valueLabel},null,8,[`iconType`,`keyLabel`,`valueLabel`]))),128))]),createBaseVNode(`div`,null,[withDirectives((openBlock(),createBlock(unref(bngButton_default),{accent:unref(ACCENTS).main,onClick:invokeActivityAction},{default:withCtx(()=>[createBaseVNode(`span`,_hoisted_3$212,[createVNode(unref(bngBinding_default),{action:`gameplay_interact`})]),selectedActivity.value.startable?(openBlock(),createElementBlock(Fragment,{key:0},[createTextVNode(toDisplayString(_ctx.$ctx_t(selectedActivity.value.buttonLabel)),1)],64)):(openBlock(),createElementBlock(Fragment,{key:1},[createTextVNode(toDisplayString(_ctx.$tt(`ui.mission.action.locked`)),1)],64))]),_:1},8,[`accent`])),[[unref(BngOnUiNav_default),void 0,`gameplay_interact`,{asMouse:!0}]]),withDirectives((openBlock(),createBlock(unref(bngButton_default),{accent:unref(ACCENTS).secondary,onClick:onCancel},{default:withCtx(()=>[createVNode(unref(bngBinding_default),{"ui-event":`back`,controller:``}),createTextVNode(` `+toDisplayString(_ctx.$tt(`ui.common.close`)),1)]),_:1},8,[`accent`])),[[unref(BngOnUiNav_default),void 0,`back`,{asMouse:!0}]])])])),[[unref(BngOnUiNav_default),goPrev,`tab_l`,{up:!0}],[unref(BngOnUiNav_default),goNext,`tab_r`,{up:!0}],[unref(BngOnUiNav_default),openPauseMenu,`menu`]]):createCommentVNode(``,!0)}},ActivityStart_default=__plugin_vue_export_helper_default(_sfc_main$329,[[`__scopeId`,`data-v-1f131cb6`]]),_hoisted_1$290={class:`recovery-wrapper`,"bng-ui-scope":`recoveryPrompt`},_hoisted_2$238={class:`content`},_hoisted_3$211={class:`label`},_hoisted_4$181={key:0,class:`more-options`},_hoisted_5$155={key:0,class:`notification`},__default__$8={wrapper:{fade:!0,blur:!0,style:popupContainer.transparent},position:[popupPosition.center,popupPosition.center]},_sfc_main$328=Object.assign(__default__$8,{__name:`Recovery`,emits:[`return`],setup(__props,{emit:__emit}){let{events:events$3}=useBridge();useUINavScope(`recoveryPrompt`);let emit$1=__emit,{closeRecoveryPrompt}=useGameContextStore(),popupData=ref({}),clickHandler=(index,button,fromController)=>{button.confirmationText||executeButtonAction(index,button)},executeButtonAction=(index,button)=>{Lua_default.core_recoveryPrompt.uiPopupButtonPressed(index+1),button.keepMenuOpen||(closeRecoveryPrompt(),emit$1(`return`,!0))},cancelClickHandler=()=>{Lua_default.core_recoveryPrompt.uiPopupCancelPressed(),popupData.value.cancelButton.keepMenuOpen||(closeRecoveryPrompt(),emit$1(`return`,!0))},updateRecoveryPopupData=()=>{Lua_default.core_recoveryPrompt.getUIData().then(value=>popupData.value=value)};return events$3.on(`updateRecoveryPopupData`,updateRecoveryPopupData),onMounted(()=>{getUINavServiceInstance().activate(),getUINavServiceInstance().clearFilteredEvents(),updateRecoveryPopupData()}),onUnmounted(()=>{events$3.off(`updateRecoveryPopupData`,updateRecoveryPopupData),window.bngVue.getCurrentRoute().name==`unknown`&&getUINavServiceInstance().setFilteredEventsAllExcept(UI_EVENTS.menu,UI_EVENTS.pause,UI_EVENTS.center_cam)}),(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$290,[createVNode(unref(bngCard_default),null,{buttons:withCtx(()=>[unref(popupData).cancelButton?withDirectives((openBlock(),createBlock(unref(bngButton_default),{key:0,label:unref(popupData).cancelButton.label,accent:unref(ACCENTS).attention,onClick:cancelClickHandler},null,8,[`label`,`accent`])),[[unref(BngOnUiNav_default),void 0,`back,menu`,{asMouse:!0}]]):createCommentVNode(``,!0)]),default:withCtx(()=>[createVNode(unref(bngCardHeading_default),{type:`ribbon`},{default:withCtx(()=>[createTextVNode(toDisplayString(unref(popupData).title),1)]),_:1}),createBaseVNode(`div`,_hoisted_2$238,[(openBlock(!0),createElementBlock(Fragment,null,renderList(unref(popupData).buttons,(button,index)=>withDirectives((openBlock(),createBlock(unref(bngButton_default),{"show-hold":!!button.confirmationText,"hold-vertical":``,accent:unref(ACCENTS).outlined,class:`recovery-option-button`},{default:withCtx(()=>[createVNode(unref(bngImageTile_default),{class:`recovery-option-tile`,icon:unref(icons)[button.icon]},{default:withCtx(()=>[createBaseVNode(`span`,_hoisted_3$211,toDisplayString(_ctx.$ctx_t(button.label)),1),button.price?(openBlock(),createBlock(unref(bngDivider_default),{key:0})):createCommentVNode(``,!0),button.price?(openBlock(),createBlock(unref(bngUnit_default),{key:1,class:`units`,money:button.price.money.amount,options:{formatter:x=>~~x}},null,8,[`money`,`options`])):createCommentVNode(``,!0)]),_:2},1032,[`icon`]),button.keepMenuOpen?(openBlock(),createElementBlock(`span`,_hoisted_4$181,`⇢`)):createCommentVNode(``,!0)]),_:2},1032,[`show-hold`,`accent`])),[[unref(BngDisabled_default),!button.enabled],[unref(BngFocusIf_default),!index||button.enabled&&!unref(popupData).buttons[0].enabled],[unref(BngOnUiNav_default),void 0,`ok`,{asMouse:!0,focusRequired:!0}],[unref(BngClick_default),{clickCallback:e=>clickHandler(index,button,e.fromController),holdCallback:button.confirmationText?()=>executeButtonAction(index,button):null,holdDelay:500,repeatInterval:0}]])),256)),unref(popupData).warningMessage?(openBlock(),createElementBlock(`div`,_hoisted_5$155,toDisplayString(unref(popupData).warningMessage),1)):createCommentVNode(``,!0)])]),_:1})]))}}),Recovery_default=__plugin_vue_export_helper_default(_sfc_main$328,[[`__scopeId`,`data-v-8495e64c`]]),_hoisted_1$289={class:`item-container`,navigable:``,tabindex:`0`},_hoisted_2$237={class:`item-content`},_hoisted_3$210={class:`item-container indented`,navigable:``,tabindex:`0`},_hoisted_4$180={class:`item-content`},_sfc_main$327={__name:`FavoriteSelectionItem`,props:{data:Object,level:{type:Number,default:0}},emits:[`addedFunction`,`removedFunction`],setup(__props,{emit:__emit}){let emit$1=__emit,expandedStates=ref({}),focusedItem=ref(null),toggleExpanded=(idx,value)=>{expandedStates.value[idx]=value},select=item=>{focusedItem.value=item},deselect=item=>{focusedItem.value===item&&(focusedItem.value=null)},isFocused=item=>focusedItem.value===item,addActionToQuickAccess=item=>{console.log(`addActionToQuickAccess`,item),item&&item.uniqueID&&emit$1(`addedFunction`,item)},removeFunction=()=>{emit$1(`removedFunction`)};return(_ctx,_cache)=>{let _component_FavoriteSelectionItem=resolveComponent(`FavoriteSelectionItem`,!0);return openBlock(),createBlock(unref(accordion_default),{class:`favorite-selection-item`,expanded:__props.data.expanded},{default:withCtx(()=>[(openBlock(!0),createElementBlock(Fragment,null,renderList(__props.data.items,(item,idx)=>(openBlock(),createElementBlock(`div`,{key:idx,class:`item-wrapper`},[item.items?(openBlock(),createBlock(unref(accordionItem_default),{key:0,navigable:``,static:!item.items,expanded:expandedStates.value[idx],onExpanded:$event=>toggleExpanded(idx,$event),"arrow-big":``,onMouseover:withModifiers($event=>select(item),[`stop`]),onMouseleave:withModifiers($event=>deselect(item),[`stop`]),onFocusin:withModifiers($event=>select(item),[`stop`]),onFocusout:withModifiers($event=>deselect(item),[`stop`]),"primary-action":()=>addActionToQuickAccess(item),"primary-label":`ui.inputActions.menu.menu_item_select.title`,"expand-hint-inline":``},{caption:withCtx(()=>[createBaseVNode(`div`,_hoisted_1$289,[createBaseVNode(`div`,_hoisted_2$237,[createVNode(unref(bngIcon_default),{type:unref(icons)[item.icon]},null,8,[`type`]),createTextVNode(` `+toDisplayString(item.title?unref($translate).instant(item.title):item.niceName),1)]),item.uniqueID&&isFocused(item)?(openBlock(),createBlock(unref(bngButton_default),{key:0,accent:`outlined`,class:`select-button`,onClick:$event=>addActionToQuickAccess(item),"bng-no-nav":``},{default:withCtx(()=>[createVNode(unref(bngBinding_default),{class:`input-icon`,"ui-event":`ok`,controller:``}),_cache[0]||=createTextVNode(` Select `,-1)]),_:1},8,[`onClick`])):createCommentVNode(``,!0)])]),default:withCtx(()=>[createVNode(_component_FavoriteSelectionItem,{data:item,level:__props.level+1,onAddedFunction:addActionToQuickAccess,onRemovedFunction:removeFunction},null,8,[`data`,`level`])]),_:2},1032,[`static`,`expanded`,`onExpanded`,`onMouseover`,`onMouseleave`,`onFocusin`,`onFocusout`,`primary-action`])):(openBlock(),createBlock(unref(accordionItem_default),{key:1,static:!0,navigable:``,onMouseover:withModifiers($event=>select(item),[`stop`]),onMouseleave:withModifiers($event=>deselect(item),[`stop`]),onFocusin:withModifiers($event=>select(item),[`stop`]),onFocusout:withModifiers($event=>deselect(item),[`stop`]),"primary-action":()=>addActionToQuickAccess(item),"primary-label":`ui.inputActions.menu.menu_item_select.title`},{caption:withCtx(()=>[createBaseVNode(`div`,_hoisted_3$210,[createBaseVNode(`div`,_hoisted_4$180,[item.icon?(openBlock(),createBlock(unref(bngIcon_default),{key:0,type:unref(icons)[item.icon]},null,8,[`type`])):createCommentVNode(``,!0),createTextVNode(` `+toDisplayString(unref($translate).instant(item.title)),1)]),item.uniqueID&&isFocused(item)?(openBlock(),createBlock(unref(bngButton_default),{key:0,class:`select-button`,onClick:$event=>addActionToQuickAccess(item),accent:`outlined`,"bng-no-nav":``},{default:withCtx(()=>[createVNode(unref(bngBinding_default),{class:`input-icon`,"ui-event":`ok`,controller:``}),_cache[1]||=createTextVNode(` Select `,-1)]),_:1},8,[`onClick`])):createCommentVNode(``,!0)])]),_:2},1032,[`onMouseover`,`onMouseleave`,`onFocusin`,`onFocusout`,`primary-action`]))]))),128))]),_:1},8,[`expanded`])}}},FavoriteSelectionItem_default=__plugin_vue_export_helper_default(_sfc_main$327,[[`__scopeId`,`data-v-dd594aec`]]),_hoisted_1$288={class:`backgroundContainer`},_hoisted_2$236={key:0,class:`recovery-wrapper`,"bng-ui-scope":`favoriteSelection`},_hoisted_3$209={class:`current-action-container`},_hoisted_4$179={key:0},_hoisted_5$154={key:1},_hoisted_6$133={key:2},_hoisted_7$119={key:0,class:`content`},__default__$7={wrapper:{fade:!0,blur:!0,style:popupContainer.transparent},position:[popupPosition.center,popupPosition.center]},_sfc_main$326=Object.assign(__default__$7,{__name:`FavoriteSelection`,emits:[`return`],setup(__props,{emit:__emit}){let{events:events$3}=useBridge();useUINavScope(`favoriteSelection`);let emit$1=__emit,{closeRecoveryPrompt}=useGameContextStore(),data=ref({}),updateFavoritePopupData=()=>{Lua_default.core_quickAccess.getDynamicSlotConfigurationData().then(value=>data.value=value)};events$3.on(`radialFavoriteSelectionPopupData`,updateFavoritePopupData);let addedFunction=item=>{let config={uniqueID:item.uniqueID,level:item.level,type:item.type,mode:item.mode||`uniqueAction`};console.log(`addedFunction`,config),Lua_default.core_quickAccess.setDynamicSlotConfiguration(data.value.dynamicSlotKey,config),emit$1(`return`,!0)},removeFunction=()=>{Lua_default.core_quickAccess.removeActionFromQuickAccess(data.value.slotIndex),emit$1(`return`,!0)},close=()=>{emit$1(`return`,!0)};return onMounted(()=>{updateFavoritePopupData()}),onUnmounted(()=>{events$3.off(`radialFavoriteSelectionPopupData`,updateFavoritePopupData),window.bngVue.getCurrentRoute().name==`unknown`&&getUINavServiceInstance().setFilteredEventsAllExcept(UI_EVENTS.menu,UI_EVENTS.pause,UI_EVENTS.center_cam)}),(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$288,[unref(data).dynamicSlotKey?(openBlock(),createElementBlock(`div`,_hoisted_2$236,[createVNode(unref(bngCard_default),null,{default:withCtx(()=>[createVNode(unref(bngCardHeading_default),{type:`ribbon`},{default:withCtx(()=>[createTextVNode(` Assign Action to: `+toDisplayString(unref(data).dynamicSlotData.breadcrumbs[0]),1)]),_:1}),createBaseVNode(`div`,_hoisted_3$209,[_cache[3]||=createBaseVNode(`div`,{class:`current-action-label`},`Currently Assigned Action:`,-1),unref(data).dynamicSlotData.mode===`uniqueAction`&&unref(data).uniqueAction?(openBlock(),createElementBlock(`div`,_hoisted_4$179,[unref(data).uniqueAction.icon?(openBlock(),createBlock(unref(bngIcon_default),{key:0,type:unref(icons)[unref(data).uniqueAction.icon]},null,8,[`type`])):createCommentVNode(``,!0),createTextVNode(` `+toDisplayString(unref(data).uniqueAction.title?unref($translate).instant(unref(data).uniqueAction.title):unref(data).uniqueAction.niceName),1)])):createCommentVNode(``,!0),unref(data).dynamicSlotData.mode===`recentActions`?(openBlock(),createElementBlock(`div`,_hoisted_5$154,[createVNode(unref(bngIcon_default),{type:unref(icons).timer},null,8,[`type`]),_cache[1]||=createTextVNode(` Most Recent Action `,-1)])):createCommentVNode(``,!0),unref(data).dynamicSlotData.mode===`empty`?(openBlock(),createElementBlock(`div`,_hoisted_6$133,[createVNode(unref(bngIcon_default),{type:unref(icons).circleSlashed},null,8,[`type`]),_cache[2]||=createTextVNode(` Empty `,-1)])):createCommentVNode(``,!0)]),_cache[5]||=createBaseVNode(`div`,{class:`divider`},null,-1),unref(data).items?(openBlock(),createElementBlock(`div`,_hoisted_7$119,[createVNode(FavoriteSelectionItem_default,{data:unref(data).items,onAddedFunction:addedFunction,onRemovedFunction:removeFunction},null,8,[`data`])])):createCommentVNode(``,!0),withDirectives((openBlock(),createBlock(unref(bngButton_default),{class:`cancel-button`,onClick:_cache[0]||=$event=>close(),accent:`attention`},{default:withCtx(()=>[createVNode(unref(bngBinding_default),{class:`input-icon`,"ui-event":`back`,controller:``}),_cache[4]||=createTextVNode(` Cancel `,-1)]),_:1})),[[unref(BngOnUiNav_default),void 0,`back,menu`,{asMouse:!0}]])]),_:1})])):createCommentVNode(``,!0)]))}}),FavoriteSelection_default=__plugin_vue_export_helper_default(_sfc_main$326,[[`__scopeId`,`data-v-88390882`]]);const useGameContextStore=defineStore(`gameContext`,()=>{let{events:events$3}=useBridge(),activities=ref([]),activityScreen=null,recoveryPrompt=null,radialFavoriteSelectionPrompt=null,deliveryEndScreen=null,simpleDelayPopup=null,startMission=missionId=>{let mission=activities.value.find(x=>x.id===missionId);mission||console.error(`Mission not found ${missionId}. cannot start`);let settings$1=mission.settings,userSettings=mission&&settings$1?settings$1.reduce((a$1,b)=>a$1[b.key]=b.value,a):{};Lua_default.gameplay_markerInteraction.startMissionById(mission.id,userSettings)},closeActivitiesPrompt=()=>{Lua_default.gameplay_markerInteraction.closeViewDetailPrompt(!0)};function openRecoveryPrompt(){recoveryPrompt=addPopup(Recovery_default).promise}function openDynamicSlotConfigurator(){radialFavoriteSelectionPrompt=addPopup(FavoriteSelection_default).promise}function openSimpleDelayPopup(data){simpleDelayPopup=fixedDelayPopup(data.timer,{title:data.heading})}let performActivityAction=activityActionIndex=>Lua_default.ui_missionInfo.performActivityAction(activityActionIndex);events$3.on(`ActivityAcceptUpdate`,onActivityAcceptUpdate),events$3.on(`ActivityAcceptClose`,closeActivitiesPopup),events$3.on(`MenuOpenModule`,closeActivitiesPopup),events$3.on(`ChangeState`,closeActivitiesPopup),events$3.on(`OpenRecoveryPrompt`,openRecoveryPrompt),events$3.on(`OpenDynamicSlotConfigurator`,openDynamicSlotConfigurator),events$3.on(`OpenSimpleDelayPopup`,openSimpleDelayPopup);let deliveryRewardData=ref(!1);function showDeliveryEndScreen(data){deliveryRewardData.value=data,window.bngVue.gotoGameState(`cargoDeliveryReward`)}events$3.on(`OpenDeliveryEndScreen`,showDeliveryEndScreen);function onActivityAcceptUpdate(data){activityScreen&&(activities.value||!data)&&closeActivitiesPopup(),window.location.hash===`#/play`&&(activities.value=data,activities.value&&activities.value.length>0&&(activityScreen=openScreenOverlay(ActivityStart_default)))}function closeActivitiesPopup(){activityScreen&&=(activityScreen.close(!0),null)}function closeRecoveryPrompt(){recoveryPrompt&&=(recoveryPrompt.close(!0),null)}function closeRadialFavoriteSelectionPrompt(){radialFavoriteSelectionPrompt&&=(radialFavoriteSelectionPrompt.close(!0),null)}function closeSimpleDelayPopup(){simpleDelayPopup&&=(simpleDelayPopup.progress.done(),null)}function closeDeliveryEndScreen(){deliveryEndScreen&&=(deliveryEndScreen.close(!0),null)}function dispose$2(){events$3.off(`ActivityAcceptUpdate`,onActivityAcceptUpdate),events$3.off(`ActivityAcceptClose`,closeActivitiesPopup)}return{activities,closeActivitiesPrompt,closeDeliveryEndScreen,closeRecoveryPrompt,closeRadialFavoriteSelectionPrompt,closeSimpleDelayPopup,deliveryRewardData,dispose:dispose$2,performActivityAction,startMission}});var PARSE_NESTED$1=`PARSE_NESTED`,bbcode_main_default=[[/\[url=https?:\/\/([^\s\]]+)\](.*?(?=\[\/url\]))\[\/url\]/gi,`$2`],[/\[url='https?:\/\/([^\s\]]+)'\](.*?(?=\[\/url\]))\[\/url\]/gi,`$2`],[/\[forumurl=https?:\/\/([^\s\]]+)\](\S*?(?=\[\/forumurl\]))\[\/forumurl\]/gi,`$2`],[/\[url\]https?:\/\/(.*?(?=\[\/url\]))\[\/url\]/gi,`$1`],[/\[url=([^\s\]]+)\](.*?(?=\[\/url\]))\[\/url\]/gi,`$2`],[/\[h(\d)\](.*?(?=\[\/h\d\]))\[\/h\d\]/gi,`$2`],[/\[img\]\s*?(\S*?(?=\[\/img\]))\[\/img\]/gi,``],[/\shttp(s|):\/\/(\S*)/gi,`http$1://$2`],[/\[list=\d+\](.*?(?=\[\/list\]))\[\/list\]/gi,`
      $1
    `],[/\[list\]/gi,`
      `],[/\[\/list\]/gi,`
    `],[/\[olist\]/gi,`
      `],[/\[\/olist\]/gi,`
    `],[/\[(\*|\+)\]\s*?((.|\s)*?(?=\[(\*|\+)\]|\<\/ul\>|\<\/ol\>|\n\n|$))/gim,`
  • $2
  • `],[PARSE_NESTED$1,/\[b\](.*?(?=\[\/b\]))\[\/b\]/gi,`$1`],[PARSE_NESTED$1,/\[u\](.*?(?=\[\/u\]))\[\/u\]/gi,`$1`],[PARSE_NESTED$1,/\[s\](.*?(?=\[\/s\]))\[\/s\]/gi,`$1`],[PARSE_NESTED$1,/\[i\](.*?(?=\[\/i\]))\[\/i\]/gi,`$1`],[/\[strike\](.*?(?=\[\/strike\]))\[\/strike\]/gi,`$1`],[/\[code\](.*?(?=\[\/code\]))\[\/code\]/gi,`$1`],[/\[br\]/gi,`
    `],[/\n\n/gi,`

    `],[/\n/gi,`
    `],[/\[attach=?f?u?l?l?\](.*?(?=\[\/attach\]))\[\/attach\]/gi,``],[/\[USER=([\d]+)\](.*?(?=\[\/USER\]))\[\/USER\]/gi,`$2`],[/\[MEDIA=youtube\](.*?(?=\[\/MEDIA\]))\[\/MEDIA\]/gi,`
    `],[/\[MEDIA=beamng\](.*?(?=\[\/MEDIA\]))\[\/MEDIA\]/gi,``],[PARSE_NESTED$1,/\[size=(\d+)\]([^[]*(?:\[(?!size=\d+\]|\/size\])[^[]*)*)\[\/size\]/gi,`$2`],[PARSE_NESTED$1,/\[COLOR=([a-z0-9\#\, \'\"\(\)]+)\]([^[]*(?:\[(?!COLOR=[a-z0-9#\(\)]+\]|\/COLOR\])[^[]*)*)\[\/COLOR\]/gi,`$2`],[PARSE_NESTED$1,/\[font=([^\]]+)\](.*?(?=\[\/font\]))\[\/font\]/gi,`$2`],[/\[hr\]\[\/hr\]/gi,`
    `],[/\[spoiler=([^\]]+)\](.*?(?=\[\/spoiler\]))\[\/spoiler\]/gi,`
    Spoiler: $1
    $2
    `],[/\[spoiler\](.*?(?=\[\/spoiler\]))\[\/spoiler\]/gi,`
    Spoiler
    $1
    `],[PARSE_NESTED$1,/\[left\](.*?(?=\[\/left\]))\[\/left\]/gi,`

    $1

    `],[PARSE_NESTED$1,/\[center\](.*?(?=\[\/center\]))\[\/center\]/gi,`

    $1

    `],[PARSE_NESTED$1,/\[right\](.*?(?=\[\/right\]))\[\/right\]/gi,`

    $1

    `],[PARSE_NESTED$1,/\*\*(.*?(?=\*\*))\*\*/gi,`$1`],[PARSE_NESTED$1,/\*(.*?(?=\*))\*/gi,`$1`],[PARSE_NESTED$1,/\[(.*?(?=\]\())\]\((https?:\/\/((.*?(?=\)))))\)/gi,`$1 ($2)`]],bbcode_vue_default=[[/\[ico=([^\s\]]+)\s*\](.*?(?=\[\/ico\]))\[\/ico\]/gi,`$2`],[/\[ico=([^\s\]]+)\s*\]/gi,``],[/\[action=(.*?)\]\[showunassigned=(.*?)\](.*?)/gi,``],[/\[action=(.*?)\](.*?)/gi,``],[/\[action=(.*?)\]/gi,``],[/\[(money|beamXP|stars|vouchers)=(.*?)\]/g,``]],bbcode_angular_default=[[/\[ico=([^\s\]]+)\s*\](.*?(?=\[\/ico\]))\[\/ico\]/gi,`$2`],[/\[ico=([^\s\]]+)\s*\]/gi,``],[/\[action=(.*?)\]\[showunassigned=(.*?)\](.*?)/gi,``],[/\[action=(.*?)\](.*?)/gi,``],[/\[action=(.*?)\]/gi,``]],bbcode_exports=__export({parse:()=>parse$1,useExtensions:()=>useExtensions}),PARSE_NESTED=`PARSE_NESTED`,_extensions=bbcode_vue_default;const useExtensions=exts=>_extensions=exts,parse$1=(txt,extensions$1=_extensions)=>{let text=``+txt;return[...bbcode_main_default,...extensions$1].forEach(replacement=>{let{nested,fromTo}=replacementDetails(replacement);text=nested?parseNested(text,...fromTo):text.replace(...fromTo)}),text};window.angularParseBBCode=txt=>parse$1(txt,bbcode_angular_default);var replacementDetails=replacement=>({nested:replacement.length==3&&replacement[0]===PARSE_NESTED,fromTo:replacement.slice(-2)}),parseNested=(text,regex,template)=>{for(;~text.search(regex);)text=text.replace(regex,template);return text},markdown_exports=__export({parse:()=>parse});function parse(src){let h$1=``;return src.replace(/^\s+|\r|\s+$/g,``).replace(/\t/g,` `).split(/\n\n+/).forEach(function(b,f,R){f=b[0],R={"*":[/\n\* /,`
    • `,`
    `],1:[/\n[1-9]\d*\.? /,`
    1. `,`
    `]," ":[/\n {4}/,`
    `,`
    `,` `],">":[/\n> /,`
    `,`
    `,`
    `,CHAR_LS=`\u2028`,CHAR_PS=`\u2029`;function createScanner(str){let _buf=str,_index=0,_line=1,_column=1,_peekOffset=0,isCRLF=index$1=>_buf[index$1]===CHAR_CR&&_buf[index$1+1]===CHAR_LF,isLF=index$1=>_buf[index$1]===CHAR_LF,isPS=index$1=>_buf[index$1]===CHAR_PS,isLS=index$1=>_buf[index$1]===CHAR_LS,isLineEnd=index$1=>isCRLF(index$1)||isLF(index$1)||isPS(index$1)||isLS(index$1),index=()=>_index,line=()=>_line,column=()=>_column,peekOffset=()=>_peekOffset,charAt=offset$2=>isCRLF(offset$2)||isPS(offset$2)||isLS(offset$2)?CHAR_LF:_buf[offset$2],currentChar=()=>charAt(_index),currentPeek=()=>charAt(_index+_peekOffset);function next(){return _peekOffset=0,isLineEnd(_index)&&(_line++,_column=0),isCRLF(_index)&&_index++,_index++,_column++,_buf[_index]}function peek(){return isCRLF(_index+_peekOffset)&&_peekOffset++,_peekOffset++,_buf[_index+_peekOffset]}function reset$1(){_index=0,_line=1,_column=1,_peekOffset=0}function resetPeek(offset$2=0){_peekOffset=offset$2}function skipToPeek(){let target=_index+_peekOffset;for(;target!==_index;)next();_peekOffset=0}return{index,line,column,peekOffset,charAt,currentChar,currentPeek,next,peek,reset:reset$1,resetPeek,skipToPeek}}var EOF=void 0,DOT=`.`,LITERAL_DELIMITER=`'`,ERROR_DOMAIN$3=`tokenizer`;function createTokenizer(source,options={}){let location$1=options.location!==!1,_scnr=createScanner(source),currentOffset=()=>_scnr.index(),currentPosition=()=>createPosition(_scnr.line(),_scnr.column(),_scnr.index()),_initLoc=currentPosition(),_initOffset=currentOffset(),_context={currentType:13,offset:_initOffset,startLoc:_initLoc,endLoc:_initLoc,lastType:13,lastOffset:_initOffset,lastStartLoc:_initLoc,lastEndLoc:_initLoc,braceNest:0,inLinked:!1,text:``},context=()=>_context,{onError}=options;function emitError$1(code,pos,offset$2,...args){let ctx=context();pos.column+=offset$2,pos.offset+=offset$2,onError&&onError(createCompileError(code,location$1?createLocation(ctx.startLoc,pos):null,{domain:ERROR_DOMAIN$3,args}))}function getToken(context$1,type,value){context$1.endLoc=currentPosition(),context$1.currentType=type;let token={type};return location$1&&(token.loc=createLocation(context$1.startLoc,context$1.endLoc)),value!=null&&(token.value=value),token}let getEndToken=context$1=>getToken(context$1,13);function eat(scnr,ch){return scnr.currentChar()===ch?(scnr.next(),ch):(emitError$1(CompileErrorCodes.EXPECTED_TOKEN,currentPosition(),0,ch),``)}function peekSpaces(scnr){let buf=``;for(;scnr.currentPeek()===CHAR_SP||scnr.currentPeek()===CHAR_LF;)buf+=scnr.currentPeek(),scnr.peek();return buf}function skipSpaces(scnr){let buf=peekSpaces(scnr);return scnr.skipToPeek(),buf}function isIdentifierStart(ch){if(ch===EOF)return!1;let cc=ch.charCodeAt(0);return cc>=97&&cc<=122||cc>=65&&cc<=90||cc===95}function isNumberStart(ch){if(ch===EOF)return!1;let cc=ch.charCodeAt(0);return cc>=48&&cc<=57}function isNamedIdentifierStart(scnr,context$1){let{currentType}=context$1;if(currentType!==2)return!1;peekSpaces(scnr);let ret=isIdentifierStart(scnr.currentPeek());return scnr.resetPeek(),ret}function isListIdentifierStart(scnr,context$1){let{currentType}=context$1;if(currentType!==2)return!1;peekSpaces(scnr);let ret=isNumberStart(scnr.currentPeek()===`-`?scnr.peek():scnr.currentPeek());return scnr.resetPeek(),ret}function isLiteralStart(scnr,context$1){let{currentType}=context$1;if(currentType!==2)return!1;peekSpaces(scnr);let ret=scnr.currentPeek()===LITERAL_DELIMITER;return scnr.resetPeek(),ret}function isLinkedDotStart(scnr,context$1){let{currentType}=context$1;if(currentType!==7)return!1;peekSpaces(scnr);let ret=scnr.currentPeek()===`.`;return scnr.resetPeek(),ret}function isLinkedModifierStart(scnr,context$1){let{currentType}=context$1;if(currentType!==8)return!1;peekSpaces(scnr);let ret=isIdentifierStart(scnr.currentPeek());return scnr.resetPeek(),ret}function isLinkedDelimiterStart(scnr,context$1){let{currentType}=context$1;if(!(currentType===7||currentType===11))return!1;peekSpaces(scnr);let ret=scnr.currentPeek()===`:`;return scnr.resetPeek(),ret}function isLinkedReferStart(scnr,context$1){let{currentType}=context$1;if(currentType!==9)return!1;let fn=()=>{let ch=scnr.currentPeek();return ch===`{`?isIdentifierStart(scnr.peek()):ch===`@`||ch===`|`||ch===`:`||ch===`.`||ch===CHAR_SP||!ch?!1:ch===CHAR_LF?(scnr.peek(),fn()):isTextStart(scnr,!1)},ret=fn();return scnr.resetPeek(),ret}function isPluralStart(scnr){peekSpaces(scnr);let ret=scnr.currentPeek()===`|`;return scnr.resetPeek(),ret}function isTextStart(scnr,reset$1=!0){let fn=(hasSpace=!1,prev=``)=>{let ch=scnr.currentPeek();return ch===`{`||ch===`@`||!ch?hasSpace:ch===`|`?!(prev===CHAR_SP||prev===CHAR_LF):ch===CHAR_SP?(scnr.peek(),fn(!0,CHAR_SP)):ch===CHAR_LF?(scnr.peek(),fn(!0,CHAR_LF)):!0},ret=fn();return reset$1&&scnr.resetPeek(),ret}function takeChar(scnr,fn){let ch=scnr.currentChar();return ch===EOF?EOF:fn(ch)?(scnr.next(),ch):null}function isIdentifier(ch){let cc=ch.charCodeAt(0);return cc>=97&&cc<=122||cc>=65&&cc<=90||cc>=48&&cc<=57||cc===95||cc===36}function takeIdentifierChar(scnr){return takeChar(scnr,isIdentifier)}function isNamedIdentifier(ch){let cc=ch.charCodeAt(0);return cc>=97&&cc<=122||cc>=65&&cc<=90||cc>=48&&cc<=57||cc===95||cc===36||cc===45}function takeNamedIdentifierChar(scnr){return takeChar(scnr,isNamedIdentifier)}function isDigit(ch){let cc=ch.charCodeAt(0);return cc>=48&&cc<=57}function takeDigit(scnr){return takeChar(scnr,isDigit)}function isHexDigit(ch){let cc=ch.charCodeAt(0);return cc>=48&&cc<=57||cc>=65&&cc<=70||cc>=97&&cc<=102}function takeHexDigit(scnr){return takeChar(scnr,isHexDigit)}function getDigits(scnr){let ch=``,num=``;for(;ch=takeDigit(scnr);)num+=ch;return num}function readText(scnr){let buf=``;for(;;){let ch=scnr.currentChar();if(ch===`{`||ch===`}`||ch===`@`||ch===`|`||!ch)break;if(ch===CHAR_SP||ch===CHAR_LF)if(isTextStart(scnr))buf+=ch,scnr.next();else if(isPluralStart(scnr))break;else buf+=ch,scnr.next();else buf+=ch,scnr.next()}return buf}function readNamedIdentifier(scnr){skipSpaces(scnr);let ch=``,name=``;for(;ch=takeNamedIdentifierChar(scnr);)name+=ch;let currentChar=scnr.currentChar();if(currentChar&¤tChar!==`}`&¤tChar!==EOF&¤tChar!==CHAR_SP&¤tChar!==CHAR_LF&¤tChar!==` `){let invalidPart=readInvalidIdentifier(scnr);return emitError$1(CompileErrorCodes.INVALID_TOKEN_IN_PLACEHOLDER,currentPosition(),0,name+invalidPart),name+invalidPart}return scnr.currentChar()===EOF&&emitError$1(CompileErrorCodes.UNTERMINATED_CLOSING_BRACE,currentPosition(),0),name}function readListIdentifier(scnr){skipSpaces(scnr);let value=``;return scnr.currentChar()===`-`?(scnr.next(),value+=`-${getDigits(scnr)}`):value+=getDigits(scnr),scnr.currentChar()===EOF&&emitError$1(CompileErrorCodes.UNTERMINATED_CLOSING_BRACE,currentPosition(),0),value}function isLiteral(ch){return ch!==LITERAL_DELIMITER&&ch!==CHAR_LF}function readLiteral(scnr){skipSpaces(scnr),eat(scnr,`'`);let ch=``,literal=``;for(;ch=takeChar(scnr,isLiteral);)ch===`\\`?literal+=readEscapeSequence(scnr):literal+=ch;let current=scnr.currentChar();return current===CHAR_LF||current===EOF?(emitError$1(CompileErrorCodes.UNTERMINATED_SINGLE_QUOTE_IN_PLACEHOLDER,currentPosition(),0),current===CHAR_LF&&(scnr.next(),eat(scnr,`'`)),literal):(eat(scnr,`'`),literal)}function readEscapeSequence(scnr){let ch=scnr.currentChar();switch(ch){case`\\`:case`'`:return scnr.next(),`\\${ch}`;case`u`:return readUnicodeEscapeSequence(scnr,ch,4);case`U`:return readUnicodeEscapeSequence(scnr,ch,6);default:return emitError$1(CompileErrorCodes.UNKNOWN_ESCAPE_SEQUENCE,currentPosition(),0,ch),``}}function readUnicodeEscapeSequence(scnr,unicode,digits){eat(scnr,unicode);let sequence=``;for(let i=0;i{let ch=scnr.currentChar();return ch===`{`||ch===`@`||ch===`|`||ch===`(`||ch===`)`||!ch||ch===CHAR_SP?buf:(buf+=ch,scnr.next(),fn(buf))};return fn(``)}function readPlural(scnr){skipSpaces(scnr);let plural=eat(scnr,`|`);return skipSpaces(scnr),plural}function readTokenInPlaceholder(scnr,context$1){let token=null;switch(scnr.currentChar()){case`{`:return context$1.braceNest>=1&&emitError$1(CompileErrorCodes.NOT_ALLOW_NEST_PLACEHOLDER,currentPosition(),0),scnr.next(),token=getToken(context$1,2,`{`),skipSpaces(scnr),context$1.braceNest++,token;case`}`:return context$1.braceNest>0&&context$1.currentType===2&&emitError$1(CompileErrorCodes.EMPTY_PLACEHOLDER,currentPosition(),0),scnr.next(),token=getToken(context$1,3,`}`),context$1.braceNest--,context$1.braceNest>0&&skipSpaces(scnr),context$1.inLinked&&context$1.braceNest===0&&(context$1.inLinked=!1),token;case`@`:return context$1.braceNest>0&&emitError$1(CompileErrorCodes.UNTERMINATED_CLOSING_BRACE,currentPosition(),0),token=readTokenInLinked(scnr,context$1)||getEndToken(context$1),context$1.braceNest=0,token;default:{let validNamedIdentifier=!0,validListIdentifier=!0,validLiteral=!0;if(isPluralStart(scnr))return context$1.braceNest>0&&emitError$1(CompileErrorCodes.UNTERMINATED_CLOSING_BRACE,currentPosition(),0),token=getToken(context$1,1,readPlural(scnr)),context$1.braceNest=0,context$1.inLinked=!1,token;if(context$1.braceNest>0&&(context$1.currentType===4||context$1.currentType===5||context$1.currentType===6))return emitError$1(CompileErrorCodes.UNTERMINATED_CLOSING_BRACE,currentPosition(),0),context$1.braceNest=0,readToken(scnr,context$1);if(validNamedIdentifier=isNamedIdentifierStart(scnr,context$1))return token=getToken(context$1,4,readNamedIdentifier(scnr)),skipSpaces(scnr),token;if(validListIdentifier=isListIdentifierStart(scnr,context$1))return token=getToken(context$1,5,readListIdentifier(scnr)),skipSpaces(scnr),token;if(validLiteral=isLiteralStart(scnr,context$1))return token=getToken(context$1,6,readLiteral(scnr)),skipSpaces(scnr),token;if(!validNamedIdentifier&&!validListIdentifier&&!validLiteral)return token=getToken(context$1,12,readInvalidIdentifier(scnr)),emitError$1(CompileErrorCodes.INVALID_TOKEN_IN_PLACEHOLDER,currentPosition(),0,token.value),skipSpaces(scnr),token;break}}return token}function readTokenInLinked(scnr,context$1){let{currentType}=context$1,token=null,ch=scnr.currentChar();switch((currentType===7||currentType===8||currentType===11||currentType===9)&&(ch===CHAR_LF||ch===CHAR_SP)&&emitError$1(CompileErrorCodes.INVALID_LINKED_FORMAT,currentPosition(),0),ch){case`@`:return scnr.next(),token=getToken(context$1,7,`@`),context$1.inLinked=!0,token;case`.`:return skipSpaces(scnr),scnr.next(),getToken(context$1,8,`.`);case`:`:return skipSpaces(scnr),scnr.next(),getToken(context$1,9,`:`);default:return isPluralStart(scnr)?(token=getToken(context$1,1,readPlural(scnr)),context$1.braceNest=0,context$1.inLinked=!1,token):isLinkedDotStart(scnr,context$1)||isLinkedDelimiterStart(scnr,context$1)?(skipSpaces(scnr),readTokenInLinked(scnr,context$1)):isLinkedModifierStart(scnr,context$1)?(skipSpaces(scnr),getToken(context$1,11,readLinkedModifier(scnr))):isLinkedReferStart(scnr,context$1)?(skipSpaces(scnr),ch===`{`?readTokenInPlaceholder(scnr,context$1)||token:getToken(context$1,10,readLinkedRefer(scnr))):(currentType===7&&emitError$1(CompileErrorCodes.INVALID_LINKED_FORMAT,currentPosition(),0),context$1.braceNest=0,context$1.inLinked=!1,readToken(scnr,context$1))}}function readToken(scnr,context$1){let token={type:13};if(context$1.braceNest>0)return readTokenInPlaceholder(scnr,context$1)||getEndToken(context$1);if(context$1.inLinked)return readTokenInLinked(scnr,context$1)||getEndToken(context$1);switch(scnr.currentChar()){case`{`:return readTokenInPlaceholder(scnr,context$1)||getEndToken(context$1);case`}`:return emitError$1(CompileErrorCodes.UNBALANCED_CLOSING_BRACE,currentPosition(),0),scnr.next(),getToken(context$1,3,`}`);case`@`:return readTokenInLinked(scnr,context$1)||getEndToken(context$1);default:if(isPluralStart(scnr))return token=getToken(context$1,1,readPlural(scnr)),context$1.braceNest=0,context$1.inLinked=!1,token;if(isTextStart(scnr))return getToken(context$1,0,readText(scnr));break}return token}function nextToken(){let{currentType,offset:offset$2,startLoc,endLoc}=_context;return _context.lastType=currentType,_context.lastOffset=offset$2,_context.lastStartLoc=startLoc,_context.lastEndLoc=endLoc,_context.offset=currentOffset(),_context.startLoc=currentPosition(),_scnr.currentChar()===EOF?getToken(_context,13):readToken(_scnr,_context)}return{nextToken,currentOffset,currentPosition,context}}var ERROR_DOMAIN$2=`parser`,KNOWN_ESCAPES=/(?:\\\\|\\'|\\u([0-9a-fA-F]{4})|\\U([0-9a-fA-F]{6}))/g;function fromEscapeSequence(match,codePoint4,codePoint6){switch(match){case`\\\\`:return`\\`;case`\\'`:return`'`;default:{let codePoint=parseInt(codePoint4||codePoint6,16);return codePoint<=55295||codePoint>=57344?String.fromCodePoint(codePoint):`�`}}}function createParser(options={}){let location$1=options.location!==!1,{onError}=options;function emitError$1(tokenzer,code,start,offset$2,...args){let end=tokenzer.currentPosition();end.offset+=offset$2,end.column+=offset$2,onError&&onError(createCompileError(code,location$1?createLocation(start,end):null,{domain:ERROR_DOMAIN$2,args}))}function startNode(type,offset$2,loc){let node={type};return location$1&&(node.start=offset$2,node.end=offset$2,node.loc={start:loc,end:loc}),node}function endNode(node,offset$2,pos,type){location$1&&(node.end=offset$2,node.loc&&(node.loc.end=pos))}function parseText$1(tokenizer$1,value){let context=tokenizer$1.context(),node=startNode(3,context.offset,context.startLoc);return node.value=value,endNode(node,tokenizer$1.currentOffset(),tokenizer$1.currentPosition()),node}function parseList(tokenizer$1,index){let{lastOffset:offset$2,lastStartLoc:loc}=tokenizer$1.context(),node=startNode(5,offset$2,loc);return node.index=parseInt(index,10),tokenizer$1.nextToken(),endNode(node,tokenizer$1.currentOffset(),tokenizer$1.currentPosition()),node}function parseNamed(tokenizer$1,key){let{lastOffset:offset$2,lastStartLoc:loc}=tokenizer$1.context(),node=startNode(4,offset$2,loc);return node.key=key,tokenizer$1.nextToken(),endNode(node,tokenizer$1.currentOffset(),tokenizer$1.currentPosition()),node}function parseLiteral(tokenizer$1,value){let{lastOffset:offset$2,lastStartLoc:loc}=tokenizer$1.context(),node=startNode(9,offset$2,loc);return node.value=value.replace(KNOWN_ESCAPES,fromEscapeSequence),tokenizer$1.nextToken(),endNode(node,tokenizer$1.currentOffset(),tokenizer$1.currentPosition()),node}function parseLinkedModifier(tokenizer$1){let token=tokenizer$1.nextToken(),context=tokenizer$1.context(),{lastOffset:offset$2,lastStartLoc:loc}=context,node=startNode(8,offset$2,loc);return token.type===11?(token.value??emitError$1(tokenizer$1,CompileErrorCodes.UNEXPECTED_LEXICAL_ANALYSIS,context.lastStartLoc,0,getTokenCaption(token)),node.value=token.value||``,endNode(node,tokenizer$1.currentOffset(),tokenizer$1.currentPosition()),{node}):(emitError$1(tokenizer$1,CompileErrorCodes.UNEXPECTED_EMPTY_LINKED_MODIFIER,context.lastStartLoc,0),node.value=``,endNode(node,offset$2,loc),{nextConsumeToken:token,node})}function parseLinkedKey(tokenizer$1,value){let context=tokenizer$1.context(),node=startNode(7,context.offset,context.startLoc);return node.value=value,endNode(node,tokenizer$1.currentOffset(),tokenizer$1.currentPosition()),node}function parseLinked(tokenizer$1){let context=tokenizer$1.context(),linkedNode=startNode(6,context.offset,context.startLoc),token=tokenizer$1.nextToken();if(token.type===8){let parsed=parseLinkedModifier(tokenizer$1);linkedNode.modifier=parsed.node,token=parsed.nextConsumeToken||tokenizer$1.nextToken()}switch(token.type!==9&&emitError$1(tokenizer$1,CompileErrorCodes.UNEXPECTED_LEXICAL_ANALYSIS,context.lastStartLoc,0,getTokenCaption(token)),token=tokenizer$1.nextToken(),token.type===2&&(token=tokenizer$1.nextToken()),token.type){case 10:token.value??emitError$1(tokenizer$1,CompileErrorCodes.UNEXPECTED_LEXICAL_ANALYSIS,context.lastStartLoc,0,getTokenCaption(token)),linkedNode.key=parseLinkedKey(tokenizer$1,token.value||``);break;case 4:token.value??emitError$1(tokenizer$1,CompileErrorCodes.UNEXPECTED_LEXICAL_ANALYSIS,context.lastStartLoc,0,getTokenCaption(token)),linkedNode.key=parseNamed(tokenizer$1,token.value||``);break;case 5:token.value??emitError$1(tokenizer$1,CompileErrorCodes.UNEXPECTED_LEXICAL_ANALYSIS,context.lastStartLoc,0,getTokenCaption(token)),linkedNode.key=parseList(tokenizer$1,token.value||``);break;case 6:token.value??emitError$1(tokenizer$1,CompileErrorCodes.UNEXPECTED_LEXICAL_ANALYSIS,context.lastStartLoc,0,getTokenCaption(token)),linkedNode.key=parseLiteral(tokenizer$1,token.value||``);break;default:{emitError$1(tokenizer$1,CompileErrorCodes.UNEXPECTED_EMPTY_LINKED_KEY,context.lastStartLoc,0);let nextContext=tokenizer$1.context(),emptyLinkedKeyNode=startNode(7,nextContext.offset,nextContext.startLoc);return emptyLinkedKeyNode.value=``,endNode(emptyLinkedKeyNode,nextContext.offset,nextContext.startLoc),linkedNode.key=emptyLinkedKeyNode,endNode(linkedNode,nextContext.offset,nextContext.startLoc),{nextConsumeToken:token,node:linkedNode}}}return endNode(linkedNode,tokenizer$1.currentOffset(),tokenizer$1.currentPosition()),{node:linkedNode}}function parseMessage(tokenizer$1){let context=tokenizer$1.context(),node=startNode(2,context.currentType===1?tokenizer$1.currentOffset():context.offset,context.currentType===1?context.endLoc:context.startLoc);node.items=[];let nextToken=null;do{let token=nextToken||tokenizer$1.nextToken();switch(nextToken=null,token.type){case 0:token.value??emitError$1(tokenizer$1,CompileErrorCodes.UNEXPECTED_LEXICAL_ANALYSIS,context.lastStartLoc,0,getTokenCaption(token)),node.items.push(parseText$1(tokenizer$1,token.value||``));break;case 5:token.value??emitError$1(tokenizer$1,CompileErrorCodes.UNEXPECTED_LEXICAL_ANALYSIS,context.lastStartLoc,0,getTokenCaption(token)),node.items.push(parseList(tokenizer$1,token.value||``));break;case 4:token.value??emitError$1(tokenizer$1,CompileErrorCodes.UNEXPECTED_LEXICAL_ANALYSIS,context.lastStartLoc,0,getTokenCaption(token)),node.items.push(parseNamed(tokenizer$1,token.value||``));break;case 6:token.value??emitError$1(tokenizer$1,CompileErrorCodes.UNEXPECTED_LEXICAL_ANALYSIS,context.lastStartLoc,0,getTokenCaption(token)),node.items.push(parseLiteral(tokenizer$1,token.value||``));break;case 7:{let parsed=parseLinked(tokenizer$1);node.items.push(parsed.node),nextToken=parsed.nextConsumeToken||null;break}}}while(context.currentType!==13&&context.currentType!==1);return endNode(node,context.currentType===1?context.lastOffset:tokenizer$1.currentOffset(),context.currentType===1?context.lastEndLoc:tokenizer$1.currentPosition()),node}function parsePlural(tokenizer$1,offset$2,loc,msgNode){let context=tokenizer$1.context(),hasEmptyMessage=msgNode.items.length===0,node=startNode(1,offset$2,loc);node.cases=[],node.cases.push(msgNode);do{let msg=parseMessage(tokenizer$1);hasEmptyMessage||=msg.items.length===0,node.cases.push(msg)}while(context.currentType!==13);return hasEmptyMessage&&emitError$1(tokenizer$1,CompileErrorCodes.MUST_HAVE_MESSAGES_IN_PLURAL,loc,0),endNode(node,tokenizer$1.currentOffset(),tokenizer$1.currentPosition()),node}function parseResource(tokenizer$1){let context=tokenizer$1.context(),{offset:offset$2,startLoc}=context,msgNode=parseMessage(tokenizer$1);return context.currentType===13?msgNode:parsePlural(tokenizer$1,offset$2,startLoc,msgNode)}function parse$2(source){let tokenizer$1=createTokenizer(source,assign$1({},options)),context=tokenizer$1.context(),node=startNode(0,context.offset,context.startLoc);return location$1&&node.loc&&(node.loc.source=source),node.body=parseResource(tokenizer$1),options.onCacheKey&&(node.cacheKey=options.onCacheKey(source)),context.currentType!==13&&emitError$1(tokenizer$1,CompileErrorCodes.UNEXPECTED_LEXICAL_ANALYSIS,context.lastStartLoc,0,source[context.offset]||``),endNode(node,tokenizer$1.currentOffset(),tokenizer$1.currentPosition()),node}return{parse:parse$2}}function getTokenCaption(token){if(token.type===13)return`EOF`;let name=(token.value||``).replace(/\r?\n/gu,`\\n`);return name.length>10?name.slice(0,9)+`…`:name}function createTransformer(ast,options={}){let _context={ast,helpers:new Set};return{context:()=>_context,helper:name=>(_context.helpers.add(name),name)}}function traverseNodes(nodes,transformer){for(let i=0;ioptimizeMessageNode(c)),ast}function optimizeMessageNode(message){if(message.items.length===1){let item=message.items[0];(item.type===3||item.type===9)&&(message.static=item.value,delete item.value)}else{let values=[];for(let i=0;i_context;function push(code,node){_context.code+=code}function _newline(n,withBreakLine=!0){let _breakLineCode=withBreakLine?breakLineCode:``;push(_needIndent?_breakLineCode+`  `.repeat(n):_breakLineCode)}function indent(withNewLine=!0){let level$1=++_context.indentLevel;withNewLine&&_newline(level$1)}function deindent(withNewLine=!0){let level$1=--_context.indentLevel;withNewLine&&_newline(level$1)}function newline(){_newline(_context.indentLevel)}return{context,push,indent,deindent,newline,helper:key=>`_${key}`,needIndent:()=>_context.needIndent}}function generateLinkedNode(generator,node){let{helper}=generator;generator.push(`${helper(`linked`)}(`),generateNode(generator,node.key),node.modifier?(generator.push(`, `),generateNode(generator,node.modifier),generator.push(`, _type`)):generator.push(`, undefined, _type`),generator.push(`)`)}function generateMessageNode(generator,node){let{helper,needIndent}=generator;generator.push(`${helper(`normalize`)}([`),generator.indent(needIndent());let length=node.items.length;for(let i=0;i1){generator.push(`${helper(`plural`)}([`),generator.indent(needIndent());let length=node.cases.length;for(let i=0;i{let mode=isString(options.mode)?options.mode:`normal`,filename=isString(options.filename)?options.filename:`message.intl`,sourceMap=!!options.sourceMap,breakLineCode=options.breakLineCode==null?mode===`arrow`?`;`:`
    `:options.breakLineCode,needIndent=options.needIndent?options.needIndent:mode!==`arrow`,helpers=ast.helpers||[],generator=createCodeGenerator(ast,{mode,filename,sourceMap,breakLineCode,needIndent});generator.push(mode===`normal`?`function __msg__ (ctx) {`:`(ctx) => {`),generator.indent(needIndent),helpers.length>0&&(generator.push(`const { ${join(helpers.map(s=>`${s}: _${s}`),`, `)} } = ctx`),generator.newline()),generator.push(`return `),generateNode(generator,ast),generator.deindent(needIndent),generator.push(`}`),delete ast.helpers;let{code,map}=generator.context();return{ast,code,map:map?map.toJSON():void 0}};function baseCompile(source,options={}){let assignedOptions=assign$1({},options),jit=!!assignedOptions.jit,enalbeMinify=!!assignedOptions.minify,enambeOptimize=assignedOptions.optimize==null?!0:assignedOptions.optimize,ast=createParser(assignedOptions).parse(source);return jit?(enambeOptimize&&optimize(ast),enalbeMinify&&minify(ast),{ast,code:``}):(transform(ast,assignedOptions),generate(ast,assignedOptions))}function initFeatureFlags$1(){typeof __INTLIFY_PROD_DEVTOOLS__!=`boolean`&&(getGlobalThis().__INTLIFY_PROD_DEVTOOLS__=!1),typeof __INTLIFY_DROP_MESSAGE_COMPILER__!=`boolean`&&(getGlobalThis().__INTLIFY_DROP_MESSAGE_COMPILER__=!1)}function isMessageAST(val){return isObject(val)&&resolveType(val)===0&&(hasOwn(val,`b`)||hasOwn(val,`body`))}var PROPS_BODY=[`b`,`body`];function resolveBody(node){return resolveProps(node,PROPS_BODY)}var PROPS_CASES=[`c`,`cases`];function resolveCases(node){return resolveProps(node,PROPS_CASES,[])}var PROPS_STATIC=[`s`,`static`];function resolveStatic(node){return resolveProps(node,PROPS_STATIC)}var PROPS_ITEMS=[`i`,`items`];function resolveItems(node){return resolveProps(node,PROPS_ITEMS,[])}var PROPS_TYPE=[`t`,`type`];function resolveType(node){return resolveProps(node,PROPS_TYPE)}var PROPS_VALUE=[`v`,`value`];function resolveValue$1(node,type){let resolved=resolveProps(node,PROPS_VALUE);if(resolved!=null)return resolved;throw createUnhandleNodeError(type)}var PROPS_MODIFIER=[`m`,`modifier`];function resolveLinkedModifier(node){return resolveProps(node,PROPS_MODIFIER)}var PROPS_KEY=[`k`,`key`];function resolveLinkedKey(node){let resolved=resolveProps(node,PROPS_KEY);if(resolved)return resolved;throw createUnhandleNodeError(6)}function resolveProps(node,props,defaultValue){for(let i=0;iformatParts(ctx,ast)}function formatParts(ctx,ast){let body=resolveBody(ast);if(body==null)throw createUnhandleNodeError(0);if(resolveType(body)===1){let cases=resolveCases(body);return ctx.plural(cases.reduce((messages,c)=>[...messages,formatMessageParts(ctx,c)],[]))}else return formatMessageParts(ctx,body)}function formatMessageParts(ctx,node){let static_=resolveStatic(node);if(static_!=null)return ctx.type===`text`?static_:ctx.normalize([static_]);{let messages=resolveItems(node).reduce((acm,c)=>[...acm,formatMessagePart(ctx,c)],[]);return ctx.normalize(messages)}}function formatMessagePart(ctx,node){let type=resolveType(node);switch(type){case 3:return resolveValue$1(node,type);case 9:return resolveValue$1(node,type);case 4:{let named=node;if(hasOwn(named,`k`)&&named.k)return ctx.interpolate(ctx.named(named.k));if(hasOwn(named,`key`)&&named.key)return ctx.interpolate(ctx.named(named.key));throw createUnhandleNodeError(type)}case 5:{let list=node;if(hasOwn(list,`i`)&&isNumber(list.i))return ctx.interpolate(ctx.list(list.i));if(hasOwn(list,`index`)&&isNumber(list.index))return ctx.interpolate(ctx.list(list.index));throw createUnhandleNodeError(type)}case 6:{let linked=node,modifier=resolveLinkedModifier(linked),key=resolveLinkedKey(linked);return ctx.linked(formatMessagePart(ctx,key),modifier?formatMessagePart(ctx,modifier):void 0,ctx.type)}case 7:return resolveValue$1(node,type);case 8:return resolveValue$1(node,type);default:throw Error(`unhandled node on format message part: ${type}`)}}var defaultOnCacheKey=message=>message,compileCache=create();function baseCompile$1(message,options={}){let detectError=!1,onError=options.onError||defaultOnError;return options.onError=err=>{detectError=!0,onError(err)},{...baseCompile(message,options),detectError}}function compile(message,context){if(!__INTLIFY_DROP_MESSAGE_COMPILER__&&isString(message)){isBoolean(context.warnHtmlMessage)&&context.warnHtmlMessage;let cacheKey=(context.onCacheKey||defaultOnCacheKey)(message),cached=compileCache[cacheKey];if(cached)return cached;let{ast,detectError}=baseCompile$1(message,{...context,location:!1,jit:!0}),msg=format$1(ast);return detectError?msg:compileCache[cacheKey]=msg}else{let cacheKey=message.cacheKey;return cacheKey?compileCache[cacheKey]||(compileCache[cacheKey]=format$1(message)):format$1(message)}}var devtools=null;function setDevToolsHook(hook){devtools=hook}function initI18nDevTools(i18n,version$2,meta){devtools&&devtools.emit(`i18n:init`,{timestamp:Date.now(),i18n,version:version$2,meta})}var translateDevTools=createDevToolsHook(`function:translate`);function createDevToolsHook(hook){return payloads=>devtools&&devtools.emit(hook,payloads)}var CoreErrorCodes={INVALID_ARGUMENT:17,INVALID_DATE_ARGUMENT:18,INVALID_ISO_DATE_ARGUMENT:19,NOT_SUPPORT_NON_STRING_MESSAGE:20,NOT_SUPPORT_LOCALE_PROMISE_VALUE:21,NOT_SUPPORT_LOCALE_ASYNC_FUNCTION:22,NOT_SUPPORT_LOCALE_TYPE:23},CORE_ERROR_CODES_EXTEND_POINT=24;function createCoreError(code){return createCompileError(code,null,void 0)}CoreErrorCodes.INVALID_ARGUMENT,CoreErrorCodes.INVALID_DATE_ARGUMENT,CoreErrorCodes.INVALID_ISO_DATE_ARGUMENT,CoreErrorCodes.NOT_SUPPORT_NON_STRING_MESSAGE,CoreErrorCodes.NOT_SUPPORT_LOCALE_PROMISE_VALUE,CoreErrorCodes.NOT_SUPPORT_LOCALE_ASYNC_FUNCTION,CoreErrorCodes.NOT_SUPPORT_LOCALE_TYPE;function getLocale(context,options){return options.locale==null?resolveLocale(context.locale):resolveLocale(options.locale)}var _resolveLocale;function resolveLocale(locale){if(isString(locale))return locale;if(isFunction(locale)){if(locale.resolvedOnce&&_resolveLocale!=null)return _resolveLocale;if(locale.constructor.name===`Function`){let resolve$1=locale();if(isPromise(resolve$1))throw createCoreError(CoreErrorCodes.NOT_SUPPORT_LOCALE_PROMISE_VALUE);return _resolveLocale=resolve$1}else throw createCoreError(CoreErrorCodes.NOT_SUPPORT_LOCALE_ASYNC_FUNCTION)}else throw createCoreError(CoreErrorCodes.NOT_SUPPORT_LOCALE_TYPE)}function fallbackWithSimple(ctx,fallback,start){return[...new Set([start,...isArray$1(fallback)?fallback:isObject(fallback)?Object.keys(fallback):isString(fallback)?[fallback]:[start]])]}var pathStateMachine=[];pathStateMachine[0]={w:[0],i:[3,0],"[":[4],o:[7]},pathStateMachine[1]={w:[1],".":[2],"[":[4],o:[7]},pathStateMachine[2]={w:[2],i:[3,0],0:[3,0]},pathStateMachine[3]={i:[3,0],0:[3,0],w:[1,1],".":[2,1],"[":[4,1],o:[7,1]},pathStateMachine[4]={"'":[5,0],'"':[6,0],"[":[4,2],"]":[1,3],o:8,l:[4,0]},pathStateMachine[5]={"'":[4,0],o:8,l:[5,0]},pathStateMachine[6]={'"':[4,0],o:8,l:[6,0]};function resolveWithKeyValue(obj,path){return isObject(obj)?obj[path]:null}var CoreWarnCodes={NOT_FOUND_KEY:1,FALLBACK_TO_TRANSLATE:2,CANNOT_FORMAT_NUMBER:3,FALLBACK_TO_NUMBER_FORMAT:4,CANNOT_FORMAT_DATE:5,FALLBACK_TO_DATE_FORMAT:6,EXPERIMENTAL_CUSTOM_MESSAGE_COMPILER:7},CORE_WARN_CODES_EXTEND_POINT=8,warnMessages={[CoreWarnCodes.NOT_FOUND_KEY]:`Not found '{key}' key in '{locale}' locale messages.`,[CoreWarnCodes.FALLBACK_TO_TRANSLATE]:`Fall back to translate '{key}' key with '{target}' locale.`,[CoreWarnCodes.CANNOT_FORMAT_NUMBER]:`Cannot format a number value due to not supported Intl.NumberFormat.`,[CoreWarnCodes.FALLBACK_TO_NUMBER_FORMAT]:`Fall back to number format '{key}' key with '{target}' locale.`,[CoreWarnCodes.CANNOT_FORMAT_DATE]:`Cannot format a date value due to not supported Intl.DateTimeFormat.`,[CoreWarnCodes.FALLBACK_TO_DATE_FORMAT]:`Fall back to datetime format '{key}' key with '{target}' locale.`,[CoreWarnCodes.EXPERIMENTAL_CUSTOM_MESSAGE_COMPILER]:`This project is using Custom Message Compiler, which is an experimental feature. It may receive breaking changes or be removed in the future.`},VERSION$1=`11.1.12`,NOT_REOSLVED=-1,DEFAULT_LOCALE=`en-US`,capitalize=str=>`${str.charAt(0).toLocaleUpperCase()}${str.substr(1)}`;function getDefaultLinkedModifiers(){return{upper:(val,type)=>type===`text`&&isString(val)?val.toUpperCase():type===`vnode`&&isObject(val)&&`__v_isVNode`in val?val.children.toUpperCase():val,lower:(val,type)=>type===`text`&&isString(val)?val.toLowerCase():type===`vnode`&&isObject(val)&&`__v_isVNode`in val?val.children.toLowerCase():val,capitalize:(val,type)=>type===`text`&&isString(val)?capitalize(val):type===`vnode`&&isObject(val)&&`__v_isVNode`in val?capitalize(val.children):val}}var _compiler;function registerMessageCompiler(compiler){_compiler=compiler}var _resolver,_fallbacker,_additionalMeta=null,setAdditionalMeta=meta=>{_additionalMeta=meta},getAdditionalMeta=()=>_additionalMeta,_fallbackContext=null,setFallbackContext=context=>{_fallbackContext=context},getFallbackContext=()=>_fallbackContext,_cid=0;function createCoreContext(options={}){let onWarn=isFunction(options.onWarn)?options.onWarn:warn,version$2=isString(options.version)?options.version:VERSION$1,locale=isString(options.locale)||isFunction(options.locale)?options.locale:DEFAULT_LOCALE,_locale=isFunction(locale)?DEFAULT_LOCALE:locale,fallbackLocale=isArray$1(options.fallbackLocale)||isPlainObject(options.fallbackLocale)||isString(options.fallbackLocale)||options.fallbackLocale===!1?options.fallbackLocale:_locale,messages=isPlainObject(options.messages)?options.messages:createResources(_locale),datetimeFormats=isPlainObject(options.datetimeFormats)?options.datetimeFormats:createResources(_locale),numberFormats=isPlainObject(options.numberFormats)?options.numberFormats:createResources(_locale),modifiers=assign$1(create(),options.modifiers,getDefaultLinkedModifiers()),pluralRules=options.pluralRules||create(),missing=isFunction(options.missing)?options.missing:null,missingWarn=isBoolean(options.missingWarn)||isRegExp(options.missingWarn)?options.missingWarn:!0,fallbackWarn=isBoolean(options.fallbackWarn)||isRegExp(options.fallbackWarn)?options.fallbackWarn:!0,fallbackFormat=!!options.fallbackFormat,unresolving=!!options.unresolving,postTranslation=isFunction(options.postTranslation)?options.postTranslation:null,processor=isPlainObject(options.processor)?options.processor:null,warnHtmlMessage=isBoolean(options.warnHtmlMessage)?options.warnHtmlMessage:!0,escapeParameter=!!options.escapeParameter,messageCompiler=isFunction(options.messageCompiler)?options.messageCompiler:_compiler,messageResolver=isFunction(options.messageResolver)?options.messageResolver:_resolver||resolveWithKeyValue,localeFallbacker=isFunction(options.localeFallbacker)?options.localeFallbacker:_fallbacker||fallbackWithSimple,fallbackContext=isObject(options.fallbackContext)?options.fallbackContext:void 0,internalOptions=options,__datetimeFormatters=isObject(internalOptions.__datetimeFormatters)?internalOptions.__datetimeFormatters:new Map,__numberFormatters=isObject(internalOptions.__numberFormatters)?internalOptions.__numberFormatters:new Map,__meta=isObject(internalOptions.__meta)?internalOptions.__meta:{};_cid++;let context={version:version$2,cid:_cid,locale,fallbackLocale,messages,modifiers,pluralRules,missing,missingWarn,fallbackWarn,fallbackFormat,unresolving,postTranslation,processor,warnHtmlMessage,escapeParameter,messageCompiler,messageResolver,localeFallbacker,fallbackContext,onWarn,__meta};return context.datetimeFormats=datetimeFormats,context.numberFormats=numberFormats,context.__datetimeFormatters=__datetimeFormatters,context.__numberFormatters=__numberFormatters,__INTLIFY_PROD_DEVTOOLS__&&initI18nDevTools(context,version$2,__meta),context}var createResources=locale=>({[locale]:create()});function handleMissing(context,key,locale,missingWarn,type){let{missing,onWarn}=context;if(missing!==null){let ret=missing(context,locale,key,type);return isString(ret)?ret:key}else return key}function updateFallbackLocale(ctx,locale,fallback){let context=ctx;context.__localeChainCache=new Map,ctx.localeFallbacker(ctx,fallback,locale)}function isAlmostSameLocale(locale,compareLocale){return locale===compareLocale?!1:locale.split(`-`)[0]===compareLocale.split(`-`)[0]}function isImplicitFallback(targetLocale,locales){let index=locales.indexOf(targetLocale);if(index===-1)return!1;for(let i=index+1;istr,DEFAULT_MESSAGE=ctx=>``,DEFAULT_MESSAGE_DATA_TYPE=`text`,DEFAULT_NORMALIZE=values=>values.length===0?``:join(values),DEFAULT_INTERPOLATE=toDisplayString$1;function pluralDefault(choice,choicesLength){return choice=Math.abs(choice),choicesLength===2?choice?choice>1?1:0:1:choice?Math.min(choice,2):0}function getPluralIndex(options){let index=isNumber(options.pluralIndex)?options.pluralIndex:-1;return options.named&&(isNumber(options.named.count)||isNumber(options.named.n))?isNumber(options.named.count)?options.named.count:isNumber(options.named.n)?options.named.n:index:index}function normalizeNamed(pluralIndex,props){props.count||=pluralIndex,props.n||=pluralIndex}function createMessageContext(options={}){let locale=options.locale,pluralIndex=getPluralIndex(options),pluralRule=isObject(options.pluralRules)&&isString(locale)&&isFunction(options.pluralRules[locale])?options.pluralRules[locale]:pluralDefault,orgPluralRule=isObject(options.pluralRules)&&isString(locale)&&isFunction(options.pluralRules[locale])?pluralDefault:void 0,plural=messages=>messages[pluralRule(pluralIndex,messages.length,orgPluralRule)],_list=options.list||[],list=index=>_list[index],_named=options.named||create();isNumber(options.pluralIndex)&&normalizeNamed(pluralIndex,_named);let named=key=>_named[key];function message(key,useLinked){return(isFunction(options.messages)?options.messages(key,!!useLinked):isObject(options.messages)?options.messages[key]:!1)||(options.parent?options.parent.message(key):DEFAULT_MESSAGE)}let _modifier=name=>options.modifiers?options.modifiers[name]:DEFAULT_MODIFIER,normalize=isPlainObject(options.processor)&&isFunction(options.processor.normalize)?options.processor.normalize:DEFAULT_NORMALIZE,interpolate=isPlainObject(options.processor)&&isFunction(options.processor.interpolate)?options.processor.interpolate:DEFAULT_INTERPOLATE,ctx={list,named,plural,linked:(key,...args)=>{let[arg1,arg2]=args,type$1=`text`,modifier=``;args.length===1?isObject(arg1)?(modifier=arg1.modifier||modifier,type$1=arg1.type||type$1):isString(arg1)&&(modifier=arg1||modifier):args.length===2&&(isString(arg1)&&(modifier=arg1||modifier),isString(arg2)&&(type$1=arg2||type$1));let ret=message(key,!0)(ctx),msg=type$1===`vnode`&&isArray$1(ret)&&modifier?ret[0]:ret;return modifier?_modifier(modifier)(msg,type$1):msg},message,type:isPlainObject(options.processor)&&isString(options.processor.type)?options.processor.type:DEFAULT_MESSAGE_DATA_TYPE,interpolate,normalize,values:assign$1(create(),_list,_named)};return ctx}var NOOP_MESSAGE_FUNCTION=()=>``,isMessageFunction=val=>isFunction(val);function translate$1(context,...args){let{fallbackFormat,postTranslation,unresolving,messageCompiler,fallbackLocale,messages}=context,[key,options]=parseTranslateArgs(...args),missingWarn=isBoolean(options.missingWarn)?options.missingWarn:context.missingWarn,fallbackWarn=isBoolean(options.fallbackWarn)?options.fallbackWarn:context.fallbackWarn,escapeParameter=isBoolean(options.escapeParameter)?options.escapeParameter:context.escapeParameter,resolvedMessage=!!options.resolvedMessage,defaultMsgOrKey=isString(options.default)||isBoolean(options.default)?isBoolean(options.default)?messageCompiler?key:()=>key:options.default:fallbackFormat?messageCompiler?key:()=>key:null,enableDefaultMsg=fallbackFormat||defaultMsgOrKey!=null&&(isString(defaultMsgOrKey)||isFunction(defaultMsgOrKey)),locale=getLocale(context,options);escapeParameter&&escapeParams(options);let[formatScope,targetLocale,message]=resolvedMessage?[key,locale,messages[locale]||create()]:resolveMessageFormat(context,key,locale,fallbackLocale,fallbackWarn,missingWarn),format$2=formatScope,cacheBaseKey=key;if(!resolvedMessage&&!(isString(format$2)||isMessageAST(format$2)||isMessageFunction(format$2))&&enableDefaultMsg&&(format$2=defaultMsgOrKey,cacheBaseKey=format$2),!resolvedMessage&&(!(isString(format$2)||isMessageAST(format$2)||isMessageFunction(format$2))||!isString(targetLocale)))return unresolving?-1:key;let occurred=!1,msg=isMessageFunction(format$2)?format$2:compileMessageFormat(context,key,targetLocale,format$2,cacheBaseKey,()=>{occurred=!0});if(occurred)return format$2;let messaged=evaluateMessage(context,msg,createMessageContext(getMessageContextOptions(context,targetLocale,message,options))),ret=postTranslation?postTranslation(messaged,key):messaged;if(escapeParameter&&isString(ret)&&(ret=sanitizeTranslatedHtml(ret)),__INTLIFY_PROD_DEVTOOLS__){let payloads={timestamp:Date.now(),key:isString(key)?key:isMessageFunction(format$2)?format$2.key:``,locale:targetLocale||(isMessageFunction(format$2)?format$2.locale:``),format:isString(format$2)?format$2:isMessageFunction(format$2)?format$2.source:``,message:ret};payloads.meta=assign$1({},context.__meta,getAdditionalMeta()||{}),translateDevTools(payloads)}return ret}function escapeParams(options){isArray$1(options.list)?options.list=options.list.map(item=>isString(item)?escapeHtml(item):item):isObject(options.named)&&Object.keys(options.named).forEach(key=>{isString(options.named[key])&&(options.named[key]=escapeHtml(options.named[key]))})}function resolveMessageFormat(context,key,locale,fallbackLocale,fallbackWarn,missingWarn){let{messages,onWarn,messageResolver:resolveValue,localeFallbacker}=context,locales=localeFallbacker(context,fallbackLocale,locale),message=create(),targetLocale,format$2=null,type=`translate`;for(let i=0;iformat$2);return msg$1.locale=targetLocale,msg$1.key=key,msg$1}let msg=messageCompiler(format$2,getCompileContext(context,targetLocale,cacheBaseKey,format$2,warnHtmlMessage,onError));return msg.locale=targetLocale,msg.key=key,msg.source=format$2,msg}function evaluateMessage(context,msg,msgCtx){return msg(msgCtx)}function parseTranslateArgs(...args){let[arg1,arg2,arg3]=args,options=create();if(!isString(arg1)&&!isNumber(arg1)&&!isMessageFunction(arg1)&&!isMessageAST(arg1))throw createCoreError(CoreErrorCodes.INVALID_ARGUMENT);let key=isNumber(arg1)?String(arg1):(isMessageFunction(arg1),arg1);return isNumber(arg2)?options.plural=arg2:isString(arg2)?options.default=arg2:isPlainObject(arg2)&&!isEmptyObject(arg2)?options.named=arg2:isArray$1(arg2)&&(options.list=arg2),isNumber(arg3)?options.plural=arg3:isString(arg3)?options.default=arg3:isPlainObject(arg3)&&assign$1(options,arg3),[key,options]}function getCompileContext(context,locale,key,source,warnHtmlMessage,onError){return{locale,key,warnHtmlMessage,onError:err=>{throw onError&&onError(err),err},onCacheKey:source$1=>generateFormatCacheKey(locale,key,source$1)}}function getMessageContextOptions(context,locale,message,options){let{modifiers,pluralRules,messageResolver:resolveValue,fallbackLocale,fallbackWarn,missingWarn,fallbackContext}=context,ctxOptions={locale,modifiers,pluralRules,messages:(key,useLinked)=>{let val=resolveValue(message,key);if(val==null&&(fallbackContext||useLinked)){let[,,message$1]=resolveMessageFormat(fallbackContext||context,key,locale,fallbackLocale,fallbackWarn,missingWarn);val=resolveValue(message$1,key)}if(isString(val)||isMessageAST(val)){let occurred=!1,msg=compileMessageFormat(context,key,locale,val,key,()=>{occurred=!0});return occurred?NOOP_MESSAGE_FUNCTION:msg}else if(isMessageFunction(val))return val;else return NOOP_MESSAGE_FUNCTION}};return context.processor&&(ctxOptions.processor=context.processor),options.list&&(ctxOptions.list=options.list),options.named&&(ctxOptions.named=options.named),isNumber(options.plural)&&(ctxOptions.pluralIndex=options.plural),ctxOptions}initFeatureFlags$1();var VERSION=`11.1.12`;function initFeatureFlags(){typeof __VUE_I18N_FULL_INSTALL__!=`boolean`&&(getGlobalThis().__VUE_I18N_FULL_INSTALL__=!0),typeof __VUE_I18N_LEGACY_API__!=`boolean`&&(getGlobalThis().__VUE_I18N_LEGACY_API__=!0),typeof __INTLIFY_DROP_MESSAGE_COMPILER__!=`boolean`&&(getGlobalThis().__INTLIFY_DROP_MESSAGE_COMPILER__=!1),typeof __INTLIFY_PROD_DEVTOOLS__!=`boolean`&&(getGlobalThis().__INTLIFY_PROD_DEVTOOLS__=!1)}var I18nErrorCodes={UNEXPECTED_RETURN_TYPE:24,INVALID_ARGUMENT:25,MUST_BE_CALL_SETUP_TOP:26,NOT_INSTALLED:27,REQUIRED_VALUE:28,INVALID_VALUE:29,CANNOT_SETUP_VUE_DEVTOOLS_PLUGIN:30,NOT_INSTALLED_WITH_PROVIDE:31,UNEXPECTED_ERROR:32,NOT_COMPATIBLE_LEGACY_VUE_I18N:33,NOT_AVAILABLE_COMPOSITION_IN_LEGACY:34};function createI18nError(code,...args){return createCompileError(code,null,void 0)}I18nErrorCodes.UNEXPECTED_RETURN_TYPE,I18nErrorCodes.INVALID_ARGUMENT,I18nErrorCodes.MUST_BE_CALL_SETUP_TOP,I18nErrorCodes.NOT_INSTALLED,I18nErrorCodes.UNEXPECTED_ERROR,I18nErrorCodes.REQUIRED_VALUE,I18nErrorCodes.INVALID_VALUE,I18nErrorCodes.CANNOT_SETUP_VUE_DEVTOOLS_PLUGIN,I18nErrorCodes.NOT_INSTALLED_WITH_PROVIDE,I18nErrorCodes.NOT_COMPATIBLE_LEGACY_VUE_I18N,I18nErrorCodes.NOT_AVAILABLE_COMPOSITION_IN_LEGACY;var SetPluralRulesSymbol=makeSymbol(`__setPluralRules`);makeSymbol(`__intlifyMeta`);var I18nWarnCodes={FALLBACK_TO_ROOT:8,NOT_FOUND_PARENT_SCOPE:9,IGNORE_OBJ_FLATTEN:10,DEPRECATE_LEGACY_MODE:11,DEPRECATE_TRANSLATE_CUSTOME_DIRECTIVE:12,DUPLICATE_USE_I18N_CALLING:13};I18nWarnCodes.FALLBACK_TO_ROOT,I18nWarnCodes.NOT_FOUND_PARENT_SCOPE,I18nWarnCodes.IGNORE_OBJ_FLATTEN,I18nWarnCodes.DEPRECATE_LEGACY_MODE,I18nWarnCodes.DEPRECATE_TRANSLATE_CUSTOME_DIRECTIVE,I18nWarnCodes.DUPLICATE_USE_I18N_CALLING;function handleFlatJson(obj){if(!isObject(obj)||isMessageAST(obj))return obj;for(let key in obj)if(hasOwn(obj,key))if(!key.includes(`.`))isObject(obj[key])&&handleFlatJson(obj[key]);else{let subKeys=key.split(`.`),lastIndex=subKeys.length-1,currentObj=obj,hasStringValue=!1;for(let i=0;i{if(`locale`in custom&&`resource`in custom){let{locale:locale$1,resource}=custom;locale$1?(ret[locale$1]=ret[locale$1]||create(),deepCopy(resource,ret[locale$1])):deepCopy(resource,ret)}else isString(custom)&&deepCopy(JSON.parse(custom),ret)}),messageResolver==null&&flatJson)for(let key in ret)hasOwn(ret,key)&&handleFlatJson(ret[key]);return ret}function getComponentOptions(instance$1){return instance$1.type}var DEVTOOLS_META=`__INTLIFY_META__`,composerID=0;function defineCoreMissingHandler(missing){return((ctx,locale,key,type)=>missing(locale,key,getCurrentInstance()||void 0,type))}var getMetaInfo=()=>{let instance$1=getCurrentInstance(),meta=null;return instance$1&&(meta=getComponentOptions(instance$1)[DEVTOOLS_META])?{[DEVTOOLS_META]:meta}:null};function createComposer(options={}){let{__root,__injectWithOption}=options,_isGlobal=__root===void 0,flatJson=options.flatJson,_ref=inBrowser?ref:shallowRef,_inheritLocale=isBoolean(options.inheritLocale)?options.inheritLocale:!0,_locale=_ref(__root&&_inheritLocale?__root.locale.value:isString(options.locale)?options.locale:DEFAULT_LOCALE),_fallbackLocale=_ref(__root&&_inheritLocale?__root.fallbackLocale.value:isString(options.fallbackLocale)||isArray$1(options.fallbackLocale)||isPlainObject(options.fallbackLocale)||options.fallbackLocale===!1?options.fallbackLocale:_locale.value),_messages=_ref(getLocaleMessages(_locale.value,options)),_missingWarn=__root?__root.missingWarn:isBoolean(options.missingWarn)||isRegExp(options.missingWarn)?options.missingWarn:!0,_fallbackWarn=__root?__root.fallbackWarn:isBoolean(options.fallbackWarn)||isRegExp(options.fallbackWarn)?options.fallbackWarn:!0,_fallbackRoot=__root?__root.fallbackRoot:isBoolean(options.fallbackRoot)?options.fallbackRoot:!0,_fallbackFormat=!!options.fallbackFormat,_missing=isFunction(options.missing)?options.missing:null,_runtimeMissing=isFunction(options.missing)?defineCoreMissingHandler(options.missing):null,_postTranslation=isFunction(options.postTranslation)?options.postTranslation:null,_warnHtmlMessage=__root?__root.warnHtmlMessage:isBoolean(options.warnHtmlMessage)?options.warnHtmlMessage:!0,_escapeParameter=!!options.escapeParameter,_modifiers=__root?__root.modifiers:isPlainObject(options.modifiers)?options.modifiers:{},_pluralRules=options.pluralRules||__root&&__root.pluralRules,_context;_context=(()=>{_isGlobal&&setFallbackContext(null);let ctx=createCoreContext({version:VERSION,locale:_locale.value,fallbackLocale:_fallbackLocale.value,messages:_messages.value,modifiers:_modifiers,pluralRules:_pluralRules,missing:_runtimeMissing===null?void 0:_runtimeMissing,missingWarn:_missingWarn,fallbackWarn:_fallbackWarn,fallbackFormat:_fallbackFormat,unresolving:!0,postTranslation:_postTranslation===null?void 0:_postTranslation,warnHtmlMessage:_warnHtmlMessage,escapeParameter:_escapeParameter,messageResolver:options.messageResolver,messageCompiler:options.messageCompiler,__meta:{framework:`vue`}});return _isGlobal&&setFallbackContext(ctx),ctx})(),updateFallbackLocale(_context,_locale.value,_fallbackLocale.value);function trackReactivityValues(){return[_locale.value,_fallbackLocale.value,_messages.value]}let locale=computed({get:()=>_locale.value,set:val=>{_context.locale=val,_locale.value=val}}),fallbackLocale=computed({get:()=>_fallbackLocale.value,set:val=>{_context.fallbackLocale=val,_fallbackLocale.value=val,updateFallbackLocale(_context,_locale.value,val)}}),messages=computed(()=>_messages.value);function getPostTranslationHandler(){return isFunction(_postTranslation)?_postTranslation:null}function setPostTranslationHandler(handler$1){_postTranslation=handler$1,_context.postTranslation=handler$1}function getMissingHandler(){return _missing}function setMissingHandler(handler$1){handler$1!==null&&(_runtimeMissing=defineCoreMissingHandler(handler$1)),_missing=handler$1,_context.missing=_runtimeMissing}let wrapWithDeps=(fn,argumentParser,warnType,fallbackSuccess,fallbackFail,successCondition)=>{trackReactivityValues();let ret;try{__INTLIFY_PROD_DEVTOOLS__,_isGlobal||(_context.fallbackContext=__root?getFallbackContext():void 0),ret=fn(_context)}finally{__INTLIFY_PROD_DEVTOOLS__,_isGlobal||(_context.fallbackContext=void 0)}if(isNumber(ret)&&ret===-1||warnType===`translate exists`){let[key,arg2]=argumentParser();return __root&&_fallbackRoot?fallbackSuccess(__root):fallbackFail(key)}else if(successCondition(ret))return ret;else throw createI18nError(I18nErrorCodes.UNEXPECTED_RETURN_TYPE)};function t(...args){return wrapWithDeps(context=>Reflect.apply(translate$1,null,[context,...args]),()=>parseTranslateArgs(...args),`translate`,root=>Reflect.apply(root.t,root,[...args]),key=>key,val=>isString(val))}function setPluralRules(rules){_pluralRules=rules,_context.pluralRules=_pluralRules}function getLocaleMessage(locale$1){return _messages.value[locale$1]||{}}function setLocaleMessage(locale$1,message){if(flatJson){let _message={[locale$1]:message};for(let key in _message)hasOwn(_message,key)&&handleFlatJson(_message[key]);message=_message[locale$1]}_messages.value[locale$1]=message,_context.messages=_messages.value}function mergeLocaleMessage(locale$1,message){_messages.value[locale$1]=_messages.value[locale$1]||{};let _message={[locale$1]:message};if(flatJson)for(let key in _message)hasOwn(_message,key)&&handleFlatJson(_message[key]);message=_message[locale$1],deepCopy(message,_messages.value[locale$1]),_context.messages=_messages.value}return composerID++,__root&&inBrowser&&(watch(__root.locale,val=>{_inheritLocale&&(_locale.value=val,_context.locale=val,updateFallbackLocale(_context,_locale.value,_fallbackLocale.value))}),watch(__root.fallbackLocale,val=>{_inheritLocale&&(_fallbackLocale.value=val,_context.fallbackLocale=val,updateFallbackLocale(_context,_locale.value,_fallbackLocale.value))})),{id:composerID,locale,fallbackLocale,get inheritLocale(){return _inheritLocale},set inheritLocale(val){_inheritLocale=val,val&&__root&&(_locale.value=__root.locale.value,_fallbackLocale.value=__root.fallbackLocale.value,updateFallbackLocale(_context,_locale.value,_fallbackLocale.value))},get availableLocales(){return Object.keys(_messages.value).sort()},messages,get modifiers(){return _modifiers},get pluralRules(){return _pluralRules||{}},get isGlobal(){return _isGlobal},get missingWarn(){return _missingWarn},set missingWarn(val){_missingWarn=val,_context.missingWarn=_missingWarn},get fallbackWarn(){return _fallbackWarn},set fallbackWarn(val){_fallbackWarn=val,_context.fallbackWarn=_fallbackWarn},get fallbackRoot(){return _fallbackRoot},set fallbackRoot(val){_fallbackRoot=val},get fallbackFormat(){return _fallbackFormat},set fallbackFormat(val){_fallbackFormat=val,_context.fallbackFormat=_fallbackFormat},get warnHtmlMessage(){return _warnHtmlMessage},set warnHtmlMessage(val){_warnHtmlMessage=val,_context.warnHtmlMessage=val},get escapeParameter(){return _escapeParameter},set escapeParameter(val){_escapeParameter=val,_context.escapeParameter=val},t,getLocaleMessage,setLocaleMessage,mergeLocaleMessage,getPostTranslationHandler,setPostTranslationHandler,getMissingHandler,setMissingHandler,[SetPluralRulesSymbol]:setPluralRules}}function createI18n(options={}){let __globalInjection=isBoolean(options.globalInjection)?options.globalInjection:!0,__instances=new Map,[globalScope,__global]=createGlobal(options),symbol=makeSymbol(``);function __getInstance(component){return __instances.get(component)||null}function __setInstance(component,instance$1){__instances.set(component,instance$1)}function __deleteInstance(component){__instances.delete(component)}let i18n={get mode(){return`composition`},async install(app$1,...options$1){if(app$1.__VUE_I18N_SYMBOL__=symbol,app$1.provide(app$1.__VUE_I18N_SYMBOL__,i18n),isPlainObject(options$1[0])){let opts=options$1[0];i18n.__composerExtend=opts.__composerExtend,i18n.__vueI18nExtend=opts.__vueI18nExtend}let globalReleaseHandler=null;__globalInjection&&(globalReleaseHandler=injectGlobalFields(app$1,i18n.global));let unmountApp=app$1.unmount;app$1.unmount=()=>{globalReleaseHandler&&globalReleaseHandler(),i18n.dispose(),unmountApp()}},get global(){return __global},dispose(){globalScope.stop()},__instances,__getInstance,__setInstance,__deleteInstance};return i18n}function createGlobal(options,legacyMode){let scope$1=effectScope(),obj=scope$1.run(()=>createComposer(options));if(obj==null)throw createI18nError(I18nErrorCodes.UNEXPECTED_ERROR);return[scope$1,obj]}var globalExportProps=[`locale`,`fallbackLocale`,`availableLocales`],globalExportMethods=[`t`];function injectGlobalFields(app$1,composer){let i18n=Object.create(null);return globalExportProps.forEach(prop=>{let desc=Object.getOwnPropertyDescriptor(composer,prop);if(!desc)throw createI18nError(I18nErrorCodes.UNEXPECTED_ERROR);let wrap=isRef(desc.value)?{get(){return desc.value.value},set(val){desc.value.value=val}}:{get(){return desc.get&&desc.get()}};Object.defineProperty(i18n,prop,wrap)}),app$1.config.globalProperties.$i18n=i18n,globalExportMethods.forEach(method=>{let desc=Object.getOwnPropertyDescriptor(composer,method);if(!desc||!desc.value)throw createI18nError(I18nErrorCodes.UNEXPECTED_ERROR);Object.defineProperty(app$1.config.globalProperties,`$${method}`,desc)}),()=>{delete app$1.config.globalProperties.$i18n,globalExportMethods.forEach(method=>{delete app$1.config.globalProperties[`$${method}`]})}}if(initFeatureFlags(),registerMessageCompiler(compile),__INTLIFY_PROD_DEVTOOLS__){let target=getGlobalThis();target.__INTLIFY__=!0,setDevToolsHook(target.__INTLIFY_DEVTOOLS_GLOBAL_HOOK__)}const emptyImage=`data:image/svg+xml,`;function getURL(path){return typeof path!=`string`||!path||path.includes(`://`)?path:(path.startsWith(`/`)&&(path=path.substring(1)),`/${path}`)}function getAssetURL(assetPath){let url=getURL(assetPath);return typeof url!=`string`||!url||url.startsWith(`/`)&&(url=`/ui/ui-vue/src/assets`+url),url}const getFile=(url,timeout=5)=>new Promise((resolve$1,reject)=>{try{let xhr=new XMLHttpRequest,tmr=timeout>0?setTimeout(()=>{xhr.abort(),reject(Error(`Timeout`))},timeout*1e3):null;xhr.open(`GET`,url,!0),xhr.onload=()=>{tmr&&clearTimeout(tmr),xhr.status===200?resolve$1(xhr.responseText):reject(Error(`Failed with code ${xhr.status}`))},xhr.send()}catch(err){reject(err)}}),ucaseFirst=str=>str[0].toUpperCase()+str.slice(1),defer=()=>{let noop$3=()=>{},resolve$1,reject,_notifyHandler=noop$3,promise=new Promise((res,rej)=>{[resolve$1,reject]=[res,rej]});return{promise:{then:(resolveHandler,rejectHandler=noop$3,notifyHandler=noop$3)=>(_notifyHandler=notifyHandler,promise.then(resolveHandler,rejectHandler))},resolve:resolve$1,reject,notify:val=>_notifyHandler(val)}},sleep=ms=>new Promise(resolve$1=>setTimeout(resolve$1,ms)),debounce=(func,wait,immediate)=>{let timeout;function call(...args){let context=this,later=()=>{timeout=null,immediate||func.apply(context,args)},callNow=immediate&&!timeout;timeout&&window.clearTimeout(timeout),timeout=window.setTimeout(later,wait),callNow&&func.apply(context,args)}return call.cancel=()=>timeout&&window.clearTimeout(timeout),call};var Settings=class{options=reactive({});values=reactive({});_previousValues={};_changedValues={};_watcher=null;_syncPending=!1;inited=!1;loaded=!1;_lua;constructor(eventBus$1=void 0,lua=void 0){eventBus$1&&lua&&this.init(eventBus$1,lua)}init(eventBus$1=void 0,lua=void 0){if(!(this.inited||this.loaded)){if(this.inited=!0,!eventBus$1||!lua){let bridge$4=useBridge();eventBus$1||=bridge$4.events,lua||=bridge$4.lua}eventBus$1.on(`SettingsChanged`,data=>{Object.assign(this.options,data.options),Object.assign(this.values,data.values),this._previousValues=this.clone(data.values),this._changedValues={},this._watcher||=watch(()=>this.values,()=>this._syncChanges(),{deep:!0,flush:`sync`}),this.loaded=!0}),this._syncChangesDebounced=debounce(this._syncChangesImmediate,100),this._lua=lua,this.update()}}async waitForData(){for(;!this.inited||!this.loaded;)await sleep(10)}async update(){if(this._lua)return await this._lua.settings.notifyUI()}clone(data){return JSON.parse(JSON.stringify(data))}getValue(field=null){if(this.loaded)return field&&!(field in this.values)?null:this.clone(field?this.values[field]:this.values)}get changesPending(){return this._syncChangesImmediate(),Object.keys(this._changedValues).length>0}get pendingChanges(){return this._syncChangesImmediate(),this.clone(this._changedValues)}_syncChanges(){this._syncPending=!0,this._syncChangesDebounced()}_syncChangesDebounced=()=>{};_syncChangesImmediate(){if(this._syncPending)for(let key in this._syncPending=!1,this.values)this._previousValues[key]===this.values[key]?key in this._changedValues&&delete this._changedValues[key]:this._changedValues[key]=this.values[key]}async apply(values=void 0){if(!this.loaded)return;let res;if(values)res=this.clone(values);else{if(!this.changesPending)return;res={...this._changedValues},this._changedValues={}}return Object.assign(this._previousValues,res),await this._lua.settings.setState(res)}},settings=new Settings;function useSettings(){return settings.init(),settings}async function useSettingsAsync(){return settings.init(),await settings.waitForData(),settings}var ANGULAR_TRANSLATE=[],_angularTranslateFunc,_i18n,i18nVariant=`petite`,defaultLocale=`en-US`,localeCheckId=`ui.common.okay`,checkLocale=()=>_i18n&&_i18n.global.t(localeCheckId)!==localeCheckId,translate=val=>val;const initTranslation=()=>{if(window.vueI18n?.__bng_i18n_variant!==i18nVariant){window.vueI18n&&console.warn(`Localisation library is already initialized, but its variant was not validated. Reloading...`);let creationArguments={locale:defaultLocale,fallbackLocale:defaultLocale,silentTranslationWarn:!0,fallbackWarn:!1,missingWarn:!1,warnHtmlMessage:!1};window.beamng&&!window.beamng.shipping&&(creationArguments.fallbackLocale=[defaultLocale,`not-shipping.internal`]),window.vueI18n=createI18n(creationArguments),window.vueI18n.__bng_i18n_variant=i18nVariant}return _i18n=window.vueI18n,{i18n:_i18n,plugin:translationPlugin}},loadLocale=async(locale,force=!1)=>{if(!(_i18n.global.availableLocales.includes(locale)&&!force))try{let url=getURL(`/locales/${locale}.json`),resp;try{resp=await getFile(url,5)}catch(err){if(err.message!==`Timeout`)throw err;console.warn(`Locale ${locale} load timed out, retrying with a bigger timeout...`),resp=await getFile(url,10)}_i18n.global.setLocaleMessage(locale,preprocessLocaleJSON(JSON.parse(resp)))}catch(err){console.error(`Failed to load ${locale} locale`,err)}};var setupUserLanguage=async()=>{let settings$1=await useSettingsAsync();watch(()=>settings$1.values.uiLanguage,async lang=>{lang&&lang!==defaultLocale&&await loadLocale(lang),_i18n.global.locale.value=_i18n.global.availableLocales.includes(lang)?lang:defaultLocale,lang!==defaultLocale&&!checkLocale()&&console.warn(`Locale ${lang} is not behaving properly`)},{immediate:!0})};const translationPlugin=()=>({install(app$1,options){return _i18n.global.locale.value=defaultLocale,loadLocale(defaultLocale,!0).then(async()=>{checkLocale()||(console.warn(`Failed to load default locale, retrying...`),await loadLocale(defaultLocale,!0),checkLocale()||console.error(`Failed to load default locale!`)),await setupUserLanguage()}),contextTranslatePlugin().install(app$1,options)}}),contextTranslatePlugin=()=>({install(app$1,options){translate=_wrapTranslate(app$1.config.globalProperties.$t||_i18n.global.t),app$1.config.globalProperties.$t=_i18n.global.t,app$1.config.globalProperties.$ctx_t=(val,translateContext=!0)=>contextTranslate(val,translateContext),app$1.config.globalProperties.$mctx_t=multiContextTranslate,app$1.config.globalProperties.$tt=translate}});var contextTranslate=(val,translateContext=!1)=>{let type=typeof val;if(type===`undefined`||val===null)return``;if(type===`object`)if(val.txt&&val.context){let context=val.context;if(translateContext)for(let key in context={...context},context)context[key]=contextTranslate(context[key],!0);return getTranslation(val.txt,context)}else val=val.txt||``;return getTranslation(``+val)},multiContextTranslate=val=>{if(val.txt)return contextTranslate(val);let description=``;for(let i of val)description+=contextTranslate(i);return description},getAngularTranslationFunc=()=>_angularTranslateFunc||(window.angular$translate&&(_angularTranslateFunc=window.angular$translate.instant.bind(window.angular$translate)),_angularTranslateFunc||translate),getTranslation=(...vals)=>(ANGULAR_TRANSLATE.includes(vals[0])?getAngularTranslationFunc():translate)(...vals);const $translate={instant:val=>val===void 0?``:translate(val),contextTranslate,multiContextTranslate};var rgxAngular=/{{.+}}/,rgxAngularTranslation=/([^ ]?){{ *(?::: *)?'([^ |}]+)' *\| *translate *}}([^\w]?)/gi;function translateAngularToVue(text){let vueText=text.replace(rgxAngularTranslation,(_,q1,s,q2)=>(q1?`${q1} `:``)+`@:${s}`+(q2?` ${q2}`:``));return vueText=vueText.replace(/{{ *([a-z\d_.]+) *}}/gi,`{$1}`),vueText===text||rgxAngular.test(vueText)?null:vueText}const preprocessLocaleJSON=obj=>{let messages={};for(let key in obj){if(ANGULAR_TRANSLATE.includes(key))continue;let text=obj[key];if(rgxAngular.test(text)){let vueText=translateAngularToVue(text);vueText?messages[key]=vueText:ANGULAR_TRANSLATE.includes(key)||ANGULAR_TRANSLATE.push(key)}else messages[key]=text}return messages};var rgxLinkedTranslation=/@:([a-zA-Z0-9_][a-zA-Z0-9_.-]+[a-zA-Z0-9_])/g,linkedNamespace=`__linked_custom`;function _linkedTranslation(msg){if(!msg.includes(`@:`)||!rgxLinkedTranslation.test(msg))return msg;let locale=_i18n.global.locale.value,messages=_i18n.global.messages.value[locale];msg=msg.replace(rgxLinkedTranslation,(_,id)=>`@:`+id);let uniqueId$1=``,match;for(rgxLinkedTranslation.lastIndex=0;(match=rgxLinkedTranslation.exec(msg))!==null;)uniqueId$1+=match[1].replace(/\./g,`_`)+`__`;let fullId,messageId,counter$1=0;for(;counter$1<100;){messageId=uniqueId$1+ ++counter$1,fullId=linkedNamespace+`.`+messageId;let existingMessage=messages[fullId];if(!existingMessage){_i18n.global.mergeLocaleMessage(locale,{[fullId]:msg});break}if(existingMessage===msg)break}return fullId}function _wrapTranslate(f){function translate$2(...args){let key=args[0];return key?typeof key!=`string`||(key=_linkedTranslation(key),key.includes(` `))?key:f.apply(this,[key,...args.slice(1)]):``}return Object.defineProperty(translate$2,`name`,{value:f.name}),translate$2}const UI_NAV_ACTION_GROUP=`UINavActions`,GAME_UI_NAVIGATION_EVENT=`UINavigation`,GAME_UI_NAV_MAP_ENABLED_EVENT=`MenuActionMapEnabled`,DOM_UI_NAVIGATION_EVENT=`ui_nav`,ACTIONS_BY_UI_EVENT={focus_u:`menu_item_up`,focus_r:`menu_item_right`,focus_d:`menu_item_down`,focus_l:`menu_item_left`,menu:`toggleMenues`,back:`menu_item_back`,details:`cui_details`,advanced:`cui_advanced`,camera:`cui_camera`,logs:`cui_logs`,tab_l:`menu_tab_left`,tab_r:`menu_tab_right`,modifier:`cui_modifier`,action_4:`cui_action_4`,focus_ud:`menu_item_focus_ud`,focus_lr:`menu_item_focus_lr`,rotate_h_cam:`menu_item_radial_right_x`,rotate_v_cam:`menu_item_radial_right_y`,ok:`menu_item_select`,cancel:`cui_cancel`,action_2:`cui_action_2`,action_3:`cui_action_3`,context:`cui_context`,gameplay_interact:`cui_gameplay_interact`},UI_EVENTS_BY_ACTION=Object.assign({},...Object.entries(ACTIONS_BY_UI_EVENT).map(([k,v])=>({[v]:k}))),UI_EVENTS={focus_u:`focus_u`,focus_r:`focus_r`,focus_d:`focus_d`,focus_l:`focus_l`,pause:`pause`,menu:`menu`,back:`back`,details:`details`,advanced:`advanced`,camera:`camera`,logs:`logs`,tab_l:`tab_l`,tab_r:`tab_r`,modifier:`modifier`,zoom_out:`zoom_out`,zoom_in:`zoom_in`,subtab_l:`subtab_l`,subtab_r:`subtab_r`,center_cam:`center_cam`,action_4:`action_4`,move_ud:`move_ud`,move_lr:`move_lr`,focus_ud:`focus_ud`,focus_lr:`focus_lr`,rotate_h_cam:`rotate_h_cam`,rotate_v_cam:`rotate_v_cam`,ok:`ok`,cancel:`cancel`,action_2:`action_2`,action_3:`action_3`,context:`context`,gameplay_interact:`gameplay_interact`},UI_EVENT_GROUPS={focusMove:[UI_EVENTS.focus_u,UI_EVENTS.focus_d,UI_EVENTS.focus_l,UI_EVENTS.focus_r],focusMoveScalar:[UI_EVENTS.focus_ud,UI_EVENTS.focus_lr],moveScalar:[UI_EVENTS.move_ud,UI_EVENTS.move_lr],navigation:[UI_EVENTS.focus_u,UI_EVENTS.focus_d,UI_EVENTS.focus_l,UI_EVENTS.focus_r,UI_EVENTS.focus_ud,UI_EVENTS.focus_lr,UI_EVENTS.move_ud,UI_EVENTS.move_lr],allEvents:Object.keys(ACTIONS_BY_UI_EVENT)},NAV_ACTIONS=[`focus_u`,`focus_d`,`focus_l`,`focus_r`],VALUE_BASED_EVENTS=[`zoom_out`,`zoom_in`,`subtab_l`,`subtab_r`,`move_ud`,`move_lr`,`focus_ud`,`focus_lr`,`rotate_h_cam`,`rotate_v_cam`],UI_SCOPE_ATTR$2=`bng-ui-scope`,UI_EVENT_ATTR=`ui-nav-event`;var UINavEventProcessor=class{constructor(){this.isModified=!1}processEvent(name,value=void 0,extras=[],context={}){return!this.isValidGameContext()||context.isEventBlocked&&context.isEventBlocked(name)?null:(this.handleModifierState(name,value),this.shouldHandleWithAngular(name,value)?(this.handleAngularIntegration(),null):this.createEventData(name,value,extras))}isValidGameContext(){return window.beamng?.ingame}handleModifierState(name,value){name===`modifier`&&(this.isModified=value===1)}shouldHandleWithAngular(name,value){return window.globalAngularRootScope&&window.bngIntroShown&&(name===`menu`||name===`back`)&&value===1}handleAngularIntegration(){window.globalAngularRootScope.$broadcast(`MenuToggle`)}createEventData(name,value,extras){let activeElement=document.activeElement,targetScope=null;if(activeElement&&activeElement!==document.body){let scopeElement=activeElement.closest(`[${UI_SCOPE_ATTR$2}]`);scopeElement&&(targetScope=scopeElement.getAttribute(UI_SCOPE_ATTR$2))}return{name,value,modified:name!==`modifier`&&this.isModified,extras,boundAction:ACTIONS_BY_UI_EVENT[name],sendToCrossfire:!0,targetScope}}getEventBroadcastElement(activeScope){let activeElement=document.activeElement;if(activeElement&&activeElement!==document.body)return activeElement;if(activeScope){let scopeElement=document.querySelector(`[${UI_SCOPE_ATTR$2}="${activeScope}"]`);if(scopeElement)return scopeElement}return document.body}},UINavActionHandlers=class{constructor(eventBus$1=null){this._useCrossfire=!0,this.eventBus=eventBus$1}setUseCrossfire(enabled){this._useCrossfire=enabled}get useCrossfire(){return this._useCrossfire}setEventBus(eventBus$1){this.eventBus=eventBus$1}handleGlobalEvent=event=>{let eventData=event.detail;eventData.value===1&&(this.handleMenuActions(eventData)||this.handleNavigationActions(eventData)||this.handleGameActions(eventData))||(this.useCrossfire&&eventData.sendToCrossfire&&handleUINavEvent(event),event.defaultPrevented||(this.handleTabNavigation(eventData),this.handleCameraRotation(eventData),this.handleContextActions(eventData)))};handleMenuActions=eventData=>{if(eventData.name===`menu`||eventData.name===`back`){let globalAngularRootScope=window.globalAngularRootScope;return globalAngularRootScope?(globalAngularRootScope.$broadcast(`MenuToggle`),!1):!0}return!1};handleNavigationActions(eventData){if(NAV_ACTIONS.includes(eventData.name)){Lua_default.extensions.hook(`onMenuItemNavigation`);return}return!1}handleGameActions(eventData){switch(eventData.name){case`pause`:return Lua_default.simTimeAuthority.togglePause(),!0;case`center_cam`:return runRaw(`if core_camera then core_camera.resetCamera(${eventData.extras.player}) end`,!1),!0;default:return!1}}handleTabNavigation(eventData){if(eventData.value===1)switch(eventData.name){case`tab_l`:this.eventBus.emit(`ui_topBar_selectPrevious`);break;case`tab_r`:this.eventBus.emit(`ui_topBar_selectNext`);break}}handleCameraRotation(eventData){if(eventData.name===`rotate_h_cam`||eventData.name===`rotate_v_cam`){let camDir=eventData.name===`rotate_v_cam`?`pitch`:`yaw`,[filterType]=eventData.extras||[0];runRaw(`if core_camera then core_camera.rotate_${camDir}(${eventData.value}, ${filterType}) end`,!1)}}handleContextActions(eventData){[`context`,`details`,`camera`].includes(eventData.name)&&eventData.value===1&&this.isBigMapContext()&&runRaw(`if freeroam_bigMapMode then freeroam_bigMapMode.toggleBigMap() end`,!1)}isBigMapContext(){return[`#/bigmap`,`#/menu.bigmap`,`#/play`,`#/menu/bigmap`].includes(window.location.hash)}},UINavService=class{constructor(eventBus$1){this._eventBus=eventBus$1,this._eventsActive=!1,this._globalEventsHooked=!1,this._activeScope=void 0,this._blockedEvents=[],this.eventProcessor=new UINavEventProcessor,this.actionHandlers=new UINavActionHandlers(eventBus$1),this.useCrossfire=!0}initialize(){this.attachEventListeners(),this.hookGlobalEvents()}handleGameEvent=(name,value,...extras)=>{let context={activeScope:this.activeScope,isEventBlocked:eventName=>this.isEventBlocked(eventName)},eventData=this.eventProcessor.processEvent(name,value,extras,context);eventData&&this.dispatchDOMEvent(eventData)};blockEvents(...events$3){let eventsToAdd=events$3.flat().filter(event=>!this._blockedEvents.includes(event));this._blockedEvents.push(...eventsToAdd)}unblockEvents(...events$3){let eventsToRemove=events$3.flat();this._blockedEvents=this._blockedEvents.filter(event=>!eventsToRemove.includes(event))}setBlockedEvents(events$3=[]){this._blockedEvents=[...events$3]}clearBlockedEvents(){this._blockedEvents=[]}isEventBlocked(eventName){return this._blockedEvents.includes(eventName)}getBlockedEvents(){return[...this._blockedEvents]}handleEnabledChange=state=>{this.eventsActive=state};dispatchDOMEvent=eventData=>{let event=new CustomEvent(DOM_UI_NAVIGATION_EVENT,{detail:eventData,cancelable:!0,bubbles:!0});this.eventProcessor.getEventBroadcastElement(this.activeScope).dispatchEvent(event)};fireEvent(uiEvent,value){this._eventBus&&(value instanceof PointerEvent?(this._eventBus.emit(GAME_UI_NAVIGATION_EVENT,uiEvent,1),this._eventBus.emit(GAME_UI_NAVIGATION_EVENT,uiEvent,0)):this._eventBus.emit(GAME_UI_NAVIGATION_EVENT,uiEvent,typeof value==`number`?value:value?1:0))}setActiveScope(scopeId){this._activeScope=scopeId}get activeScope(){return this._activeScope}activate(state=!0){this.attachEventListeners(state),this.eventsActive=state}hookGlobalEvents(state=!0){let listenerAction=document.body[state?`addEventListener`:`removeEventListener`];listenerAction(DOM_UI_NAVIGATION_EVENT,this.actionHandlers.handleGlobalEvent),this.globalEventsHooked=state}attachEventListeners(state=!0){this._eventBus&&(this._eventBus.off(GAME_UI_NAVIGATION_EVENT),this._eventBus.off(GAME_UI_NAV_MAP_ENABLED_EVENT),state&&(this._eventBus.on(GAME_UI_NAVIGATION_EVENT,this.handleGameEvent),this._eventBus.on(GAME_UI_NAV_MAP_ENABLED_EVENT,this.handleEnabledChange)))}setFilteredEvents(...events$3){this.clearFilteredEvents();let actionsToFilter=[...new Set(events$3.flat(1/0))].map(event=>ACTIONS_BY_UI_EVENT[event]);Lua_default.extensions.core_input_actionFilter.setGroup(UI_NAV_ACTION_GROUP,actionsToFilter),Lua_default.extensions.core_input_actionFilter.addAction(0,UI_NAV_ACTION_GROUP,!0)}setFilteredEventsAllExcept(...events$3){let eventsToNotFilter=[...new Set(events$3.flat(1/0))],eventsToFilter=Object.keys(ACTIONS_BY_UI_EVENT).filter(ev=>!eventsToNotFilter.includes(ev));this.setFilteredEvents(eventsToFilter)}clearFilteredEvents(){Lua_default.extensions.core_input_actionFilter.addAction(0,UI_NAV_ACTION_GROUP,!1),Lua_default.extensions.core_input_actionFilter.setGroup(UI_NAV_ACTION_GROUP,[])}set eventsActive(value){this._eventsActive=value}get eventsActive(){return this._eventsActive}set globalEventsHooked(value){this._globalEventsHooked=value}get globalEventsHooked(){return this._globalEventsHooked}get useCrossfire(){return this.actionHandlers.useCrossfire}set useCrossfire(value){this.actionHandlers.setUseCrossfire(value)}get eventBus(){return this._eventBus}},instance=null;const setUINavServiceInstance=serviceInstance=>{instance=serviceInstance},getUINavServiceInstance=()=>{if(!instance)throw Error(`UINavService not initialized.`);return instance},SCOPED_NAV_ATTR=`bng-scoped-nav`,SCOPED_NAV_PROPERTY_NAME=`_bngScopedNav`,UI_SCOPE_ATTR$1=`bng-ui-scope`,BNG_ON_UI_NAV_ATTR$1=`__BngOnUiNav`,ATTR_NAME$1=`bng-scoped-nav`,PASSTHROUGH_EXCLUDED_EVENTS=[UI_EVENTS.ok,UI_EVENTS.back,UI_EVENT_GROUPS.focusMove,UI_EVENT_GROUPS.focusMoveScalar],SCOPED_NAV_STATES={active:`full`,partial:`partial`,suspended:`suspended`,inactive:`inactive`},SCOPED_NAV_EVENTS={activate:`scopednav:activate`,deactivate:`scopednav:deactivate`,suspend:`scopednav:suspend`,resume:`scopednav:resume`},SCOPED_NAV_TYPES={normal:`normal`,container:`container`,nonav:`nonav`,popover:`popover`};var ScopeRegistry=class{constructor(){this.scopeRegistries=new WeakMap,this.depthCache=new WeakMap,this.cleanupTimers=new Map}clearDepthCache(scopeElement){this.depthCache.delete(scopeElement)}getCachedDepth(element,scopeElement){let scopeDepthCache=this.depthCache.get(scopeElement);if(scopeDepthCache||(scopeDepthCache=new Map,this.depthCache.set(scopeElement,scopeDepthCache)),!scopeDepthCache.has(element)){let depth=this._getElementDepth(element,scopeElement);scopeDepthCache.set(element,depth)}return scopeDepthCache.get(element)}register(scopeElement,handlerDescriptor){let scopeRegistry=this.scopeRegistries.get(scopeElement);scopeRegistry||(scopeRegistry={handlers:[],scopeHandler:null,initialized:!1},this.scopeRegistries.set(scopeElement,scopeRegistry));let existingIndex=scopeRegistry.handlers.findIndex(h$1=>h$1.element===handlerDescriptor.element&&this.descriptorsMatch(h$1.eventDescriptor,handlerDescriptor.eventDescriptor));return existingIndex===-1?scopeRegistry.handlers.push(handlerDescriptor):scopeRegistry.handlers[existingIndex]=handlerDescriptor,scopeRegistry.initialized||this.initializeScopeHandler(scopeElement,scopeRegistry),this.clearDepthCache(scopeElement),handlerDescriptor.handler}descriptorsMatch(desc1,desc2){return desc1.name===desc2.name&&desc1.modified===desc2.modified&&desc1.focusRequired===desc2.focusRequired}unregister(element,handlerController){let scopeElement=element.closest(`[${UI_SCOPE_ATTR$2}]`);if(!scopeElement)return;let scopeRegistry=this.scopeRegistries.get(scopeElement);if(!scopeRegistry)return;let handlerIndex=scopeRegistry.handlers.findIndex(h$1=>h$1.element===element&&h$1.handler===handlerController);handlerIndex!==-1&&(scopeRegistry.handlers.splice(handlerIndex,1),this.clearDepthCache(scopeElement)),this.scheduleCleanup(scopeElement,scopeRegistry)}scheduleCleanup(scopeElement,scopeRegistry){this.cleanupTimers.has(scopeElement)&&clearTimeout(this.cleanupTimers.get(scopeElement));let timerId=setTimeout(()=>{this.performCleanup(scopeElement,scopeRegistry),this.cleanupTimers.delete(scopeElement)},100);this.cleanupTimers.set(scopeElement,timerId)}performCleanup(scopeElement,scopeRegistry){scopeRegistry.handlers.length===0&&(scopeElement.removeEventListener(DOM_UI_NAVIGATION_EVENT,scopeRegistry.scopeHandler),this.scopeRegistries.delete(scopeElement),this.clearDepthCache(scopeElement))}destroy(){this.cleanupTimers.forEach(timer=>clearTimeout(timer)),this.cleanupTimers.clear(),this.depthCache=new WeakMap}initializeScopeHandler(scopeElement,scopeRegistry){let scopeHandler=event=>{let scopeId=scopeElement.getAttribute(UI_SCOPE_ATTR$2),uiNavService=getUINavServiceInstance(),targetScope=event.detail?.targetScope||uiNavService.activeScope;if(targetScope&&targetScope!==scopeId&&!this._isTargetScopeNested(targetScope,scopeElement)){console.warn(`UINav: Event target scope is not the intended scope. Ignoring event for this scope(${scopeId})`,{targetScope,scopeId});return}if(scopeElement._bngScopedNav&&scopeElement._bngScopedNav.canIgnoreEvent&&scopeElement._bngScopedNav.canIgnoreEvent(event)){event.stopPropagation();return}let isTargetActiveScope=targetScope===scopeId&&scopeId===uiNavService.activeScope,canPassthrough=isTargetActiveScope&&this._allowsPassthrough(scopeElement,event.detail),monitoredEvents=[...MONITORED_UI_NAV_EVENTS,UI_EVENTS.back];if(!(!isTargetActiveScope&&!canPassthrough&&!monitoredEvents.includes(event.detail.name))){if(!isTargetActiveScope&&!canPassthrough&&monitoredEvents.includes(event.detail.name)){this._executeScopedNavHandler(scopeElement,event,scopeRegistry.handlers)||event.stopPropagation();return}(!this._executeScopedBubbling(scopeElement,event,scopeRegistry.handlers)||!this._checkScopeBubbling(scopeElement,event))&&event.stopPropagation()}};scopeElement.addEventListener(DOM_UI_NAVIGATION_EVENT,scopeHandler),scopeRegistry.scopeHandler=scopeHandler,scopeRegistry.initialized=!0}_isTargetScopeNested(targetScopeId,currentScopeElement){let targetScopeElement=document.querySelector(`[${UI_SCOPE_ATTR$2}="${targetScopeId}"]`);return targetScopeElement?currentScopeElement.contains(targetScopeElement)&&targetScopeElement!==currentScopeElement:!1}_executeScopedNavHandler(scopeElement,event,handlers$1){let matchingHandlers=handlers$1.filter(h$1=>!h$1.disabled&&this._eventMatchesDescriptor(event.detail,h$1.eventDescriptor)&&h$1.element===scopeElement);if(matchingHandlers.length===0)return!0;let results=[];for(let handler$1 of matchingHandlers)try{let result=handler$1.handler(event);results.push(result)}catch(error){console.error(`Error in UINav scope handler:`,error,{element:handler$1.element,event:event.detail.name}),results.push(!1)}return results.some(result=>result===!0)}_executeScopedBubbling(scopeElement,event,handlers$1){let eventData=event.detail,matchingHandlers=handlers$1&&handlers$1.length>0?handlers$1.filter(h$1=>!h$1.disabled&&this._eventMatchesDescriptor(eventData,h$1.eventDescriptor)):[];if(matchingHandlers.length===0)return!0;let activeElement=document.activeElement,startElement=event.target;startElement=activeElement&&scopeElement.contains(activeElement)&&matchingHandlers.some(h$1=>h$1.element===activeElement)?activeElement:this._findDeepestHandlerElement(scopeElement,matchingHandlers);let bubblingPath=this._buildBubblingPath(startElement,scopeElement,matchingHandlers);return bubblingPath.length===0?(console.warn(`UINav: No bubbling path found.`,{scopeElement,event,handlers:handlers$1}),!0):this._executeHandlersAlongPath(bubblingPath,event)}_findDeepestHandlerElement(scopeElement,handlers$1){return[...new Set(handlers$1.map(h$1=>h$1.element))].filter(el=>this.getCachedDepth(el,scopeElement)<0?!1:!this._isElementInNestedScope(el,scopeElement)).sort((a$1,b)=>{let depthA=this.getCachedDepth(a$1,scopeElement);return this.getCachedDepth(b,scopeElement)-depthA})[0]||null}_isElementInNestedScope(element,currentScopeElement){let current=element;for(;current&¤t!==currentScopeElement;){if(current.hasAttribute(`bng-ui-scope`)&¤t!==currentScopeElement)return!0;current=current.parentElement}return!1}_buildBubblingPath(startElement,scopeElement,handlers$1){if(!scopeElement.contains(startElement))return console.warn(`UINav: Start element is outside scope boundary`,startElement,scopeElement),[];let path=[],current=startElement;for(;current&&scopeElement.contains(current);){let elementHandlers=handlers$1.filter(h$1=>h$1.element===current);if(elementHandlers.length>0&&path.push({element:current,handlers:elementHandlers}),current===scopeElement)break;current=current.parentElement}return path}_executeHandlersAlongPath(bubblingPath,event){for(let pathItem of bubblingPath){let results=[];for(let handlerDescriptor of pathItem.handlers)try{let result=handlerDescriptor.handler(event);results.push(result)}catch(error){console.error(`Error in UINav scope handler:`,error,{element:pathItem.element,event:event.detail.name}),results.push(!1)}if(!results.some(result=>result===!0))return!1}return!0}_checkScopeBubbling(scopeElement,event){let scopedNavProps=scopeElement._bngScopedNav;return scopedNavProps?scopedNavProps.shouldBubbleEvent&&typeof scopedNavProps.shouldBubbleEvent==`function`?scopedNavProps.shouldBubbleEvent(event):!1:!0}_getElementDepth(element,parent){let depth=0,current=element;for(;current&¤t!==parent;)depth++,current=current.parentElement;return current===parent?depth:-1}_allowsPassthrough(scopeElement,eventData){let domScopedNavProps=scopeElement.hasAttribute(`bng-scoped-nav`)?scopeElement[SCOPED_NAV_PROPERTY_NAME]:{};return domScopedNavProps.passthroughActive&&domScopedNavProps.passthroughEnabled&&domScopedNavProps.passthroughEvents.includes(eventData.name)}_eventMatchesDescriptor(eventData,descriptor){for(let[item,value]of Object.entries(descriptor))if(value!==void 0)if(item===`focusRequired`){if(value&&!value.contains(document.activeElement))return!1}else{if(!(item in eventData))return!1;if(typeof value==`function`){if(!value(eventData[item]))return!1}else if(eventData[item]!=value)return!1}return!0}};const isOnOffEvent=eventName=>!VALUE_BASED_EVENTS.includes(eventName),checkOn=value=>value,normalizeEventDescriptor=eventDescriptor=>({string:{name:eventDescriptor,value:isOnOffEvent(eventDescriptor)?checkOn:void 0,modified:!1,extras:void 0},object:{...eventDescriptor,value:`value`in eventDescriptor?eventDescriptor.value:isOnOffEvent(eventDescriptor.name)?checkOn:void 0}})[typeof eventDescriptor]||!1,eventMatchesDescriptor=(eventData,descriptor)=>{for(let[item,value]of Object.entries(descriptor))if(value!==void 0)if(item===`focusRequired`){if(value&&!value.contains(document.activeElement))return!1}else{if(!(item in eventData))return!1;if(typeof value==`function`){if(!value(eventData[item]))return!1}else if(eventData[item]!=value)return!1}return!0},getDescriptorEventNameText=descriptor=>descriptor.name?typeof descriptor.name==`function`?descriptor.name.name:descriptor.name:`ALL`;var HandlerFactory=class{static createHandler(eventDescriptor,userHandler){let descriptor=normalizeEventDescriptor(eventDescriptor);if(!descriptor)throw Error(`Invalid event descriptor when trying to create a UINav handler. Expecting a String or an Object.`);let handlerFuncName=userHandler?.name||`uiNav_${getDescriptorEventNameText(descriptor)}_handler`,disabled=!1;function wrapper(event){let eventData=event?.detail||{};return disabled||!eventMatchesDescriptor(eventData,descriptor)?!0:userHandler(event)}return Object.defineProperty(wrapper,`name`,{value:handlerFuncName}),Object.defineProperty(wrapper,`disabled`,{configurable:!1,get:()=>disabled,set:state=>{disabled=state}}),wrapper}static normalizeEventDescriptor(eventDescriptor){return{string:{name:eventDescriptor,value:isOnOffEvent(eventDescriptor)?checkOn:void 0,modified:!1,extras:void 0},object:{...eventDescriptor,value:`value`in eventDescriptor?eventDescriptor.value:isOnOffEvent(eventDescriptor.name)?checkOn:void 0}}[typeof eventDescriptor]||!1}},UINavHandlers=class{constructor(){this.scopeRegistry=new ScopeRegistry}add(domElement,uiNavHandlerOrDescriptor,handler$1=void 0){let scopeElement=domElement.closest(`[${UI_SCOPE_ATTR$2}]`);return scopeElement?this.addWithScope(domElement,uiNavHandlerOrDescriptor,handler$1,scopeElement):this.addIndividual(domElement,uiNavHandlerOrDescriptor,handler$1)}remove(domElement,uiNavHandler){domElement.closest(`[bng-ui-scope]`)?this.scopeRegistry.unregister(domElement,uiNavHandler):this.removeIndividual(domElement,uiNavHandler)}addWithScope(domElement,uiNavHandlerOrDescriptor,handler$1,scopeElement){let targetElement=domElement;if(!scopeElement.contains(targetElement))return console.error(`UINav: Attempting to register handler for element outside scope`,{targetElement,scopeElement,scopeId:scopeElement.getAttribute(UI_SCOPE_ATTR$2)}),this.addIndividual(domElement,uiNavHandlerOrDescriptor,handler$1);let wrapperHandler=handler$1?HandlerFactory.createHandler(uiNavHandlerOrDescriptor,handler$1):uiNavHandlerOrDescriptor,handlerDescriptor={element:domElement,eventDescriptor:HandlerFactory.normalizeEventDescriptor(uiNavHandlerOrDescriptor),handler:wrapperHandler,disabled:!1};return this.scopeRegistry.register(scopeElement,handlerDescriptor)}addIndividual(domElement,uiNavHandlerOrDescriptor,handler$1){let uiNavHandler=handler$1?HandlerFactory.createHandler(uiNavHandlerOrDescriptor,handler$1):uiNavHandlerOrDescriptor;return domElement.addEventListener(DOM_UI_NAVIGATION_EVENT,uiNavHandler),uiNavHandler}removeIndividual(domElement,uiNavHandler){domElement.removeEventListener(DOM_UI_NAVIGATION_EVENT,uiNavHandler)}},handlers_default=new UINavHandlers;function usePopupUINavScopeName(baseName,props){let attrs=useAttrs(),scopeName=baseName+`__`+attrs.__id;return useUINavScope(scopeName),watch(()=>props.popupActive,()=>props.popupActive&&useUINavScope(scopeName)),scopeName}function useUINavScope(scope$1=void 0,restoreScopeOnUnmount=!0){let currentScope=ref(scope$1),oldScope,scopeChanged=!1,setScope=newScope=>{scopeChanged=!0,currentScope.value=newScope,getUINavServiceInstance().setActiveScope(newScope)},restoreOldScope=()=>{getUINavServiceInstance().setActiveScope(oldScope)};return onMounted(()=>{oldScope=getUINavServiceInstance().activeScope,currentScope.value?setScope(currentScope.value):currentScope.value=oldScope}),onUnmounted(()=>{scopeChanged&&restoreScopeOnUnmount&&restoreOldScope()}),{current:computed(()=>currentScope.value),set:setScope,get oldScope(){return oldScope}}}function watchUINavEventChange(domElementRef,handler$1){return watch(()=>{if(!domElementRef.value)return{};let eventName=domElementRef.value.getAttribute(UI_EVENT_ATTR);return{eventName,action:ACTIONS_BY_UI_EVENT[eventName]}},handler$1)}const eventFirer=uiEvent=>value=>getUINavServiceInstance().fireEvent(uiEvent,value);var counter=0;const uniqueNum=()=>++counter%1e5+Math.random(),uniqueId=(name=``,separator=`.`)=>{let str=`${name?name+separator:``}${uniqueNum().toString(16)}`;return separator===`.`?str:str.replace(`.`,separator)},uniqueSafeId=()=>uniqueId(``,`_`);var DEFAULT_NAVIGATION=[...MONITORED_UI_NAV_EVENTS,`back`],ALWAYS_ACTIVE=[`ok`,`menu`,`back`],BLOCKER=Symbol(`uiNavBlocker`);const useUINavTracker=defineStore(`uiNavTracker`,()=>{let{lua,events:events$3}=useBridge(),showErrors=window.beamng&&!window.beamng.shipping,initialised=!1,trackedEvents=ref([]),trackedInstances={},ignoredEvents=ref([]),ignoredInstances={},blockedEvents$1=ref([]),blockedInstances={},unblockedEvents=ref([]),unblockedInstances={},activeEvents=ref([]),labelRegistry=useUiNavLabel();function updateBlocklist(){let uiNavService=getUINavServiceInstance(),eventsToBlock=blockedEvents$1.value.filter(name=>!unblockedEvents.value.includes(name));uiNavService.setBlockedEvents(eventsToBlock)}let raf;function update$6(eventName){cancelAnimationFrame(raf),raf=requestAnimationFrame(()=>{activeEvents.value=trackedEvents.value.filter(e=>!ignoredEvents.value.includes(e.name)&&(unblockedEvents.value.includes(e.name)||!blockedEvents$1.value.includes(e.name))).map(e=>({...e,nogroup:!!trackedInstances[e.name]?.at(-1)?.nogroup}))})}let ownerIdCheck=ownerId$1=>{if(typeof ownerId$1!=`string`||!ownerId$1)throw Error(`ownerId is required and must be a string`)},eventNameCheck=(eventName,quiet=!1)=>{let ok=!0;return typeof eventName!=`string`||!eventName?(showErrors&&logger_default.error(`eventName is required`),ok=!1):eventName in ACTIONS_BY_UI_EVENT||(showErrors&&!quiet&&logger_default.error(`eventName ${eventName} does not exist`),ok=!1),ok},getRecentInstance=eventName=>trackedInstances[eventName].findLast(inst=>inst.element!==BLOCKER),parseActive=(active,eventName)=>typeof active==`boolean`?active:ALWAYS_ACTIVE.includes(eventName);function addEvent(eventName,ownerId$1,element=null,options={}){if(initialised||rebind(),!eventNameCheck(eventName))return;ownerIdCheck(ownerId$1),trackedInstances[eventName]||(trackedInstances[eventName]=[]),element||=window.document.body;let instance$1=trackedInstances[eventName].find(instance$2=>instance$2.ownerId===ownerId$1);if(instance$1){instance$1.element=element,instance$1.nogroup=!!options?.nogroup,instance$1.active=parseActive(options?.active,eventName),update$6(eventName);return}if(trackedInstances[eventName].push({ownerId:ownerId$1,element,nogroup:!!options?.nogroup,active:parseActive(options?.active,eventName)}),trackedInstances[eventName].length===1){let event={name:eventName,label:computed(()=>{let instance$2=getRecentInstance(eventName);return labelRegistry.getLabel(eventName,instance$2?.element)||null}),action:computed(()=>getRecentInstance(eventName)?.active?eventFirer(eventName):null)};trackedEvents.value.push(event),actionSwitch(!0,eventName)}update$6(eventName)}function updateEvent(eventName,ownerId$1,element,options={}){if(ownerIdCheck(ownerId$1),!eventNameCheck(eventName))return;element||=window.document.body;let instance$1=trackedInstances[eventName]?.find(instance$2=>instance$2.ownerId===ownerId$1);if(!instance$1){addEvent(eventName,ownerId$1,element,!1,options);return}instance$1.element=element,instance$1.nogroup=!!options?.nogroup,instance$1.active=parseActive(options?.active,eventName),update$6(eventName)}function removeEvent(eventName,ownerId$1,element=null){if(ownerIdCheck(ownerId$1),!eventNameCheck(eventName)||!trackedInstances[eventName])return;element||=window.document.body;let idx=trackedInstances[eventName].findIndex(instance$1=>instance$1.ownerId===ownerId$1);if(idx!==-1&&(trackedInstances[eventName].splice(idx,1),update$6(eventName),trackedInstances[eventName].length===0)){delete trackedInstances[eventName];let idx$1=trackedEvents.value.findIndex(h$1=>h$1.name===eventName);idx$1>-1&&(trackedEvents.value.splice(idx$1,1),actionSwitch(!1,eventName))}}function addHelper(eventList,instanceList,eventName,ownerId$1,func,quiet=!1){ownerIdCheck(ownerId$1),eventNameCheck(eventName,quiet)&&(eventList.value.includes(eventName)||(eventList.value.push(eventName),func&&func(),instanceList[eventName]||(instanceList[eventName]=[])),instanceList[eventName].push(ownerId$1))}function removeHelper(eventList,instanceList,eventName,ownerId$1,func,quiet=!1){if(ownerIdCheck(ownerId$1),!eventNameCheck(eventName,quiet)||!(eventName in instanceList))return;let instIdx=instanceList[eventName].indexOf(ownerId$1);if(instIdx!==-1&&(instanceList[eventName].splice(instIdx,1),instanceList[eventName].length===0)){let idx=eventList.value.indexOf(eventName);idx>-1&&(eventList.value.splice(idx,1),func&&func())}}function addIgnore(eventName,ownerId$1){addHelper(ignoredEvents,ignoredInstances,eventName,ownerId$1,null,!0)}function removeIgnore(eventName,ownerId$1){removeHelper(ignoredEvents,ignoredInstances,eventName,ownerId$1,null,!0)}function addBlocker(eventName,ownerId$1){addHelper(blockedEvents$1,blockedInstances,eventName,ownerId$1,()=>{addEvent(eventName,ownerId$1,BLOCKER),updateBlocklist()})}function removeBlocker(eventName,ownerId$1){removeHelper(blockedEvents$1,blockedInstances,eventName,ownerId$1,()=>{removeEvent(eventName,ownerId$1,BLOCKER),updateBlocklist()})}function addForceUnblock(eventName,ownerId$1){addHelper(unblockedEvents,unblockedInstances,eventName,ownerId$1,()=>{update$6(eventName),updateBlocklist()})}function removeForceUnblock(eventName,ownerId$1){removeHelper(unblockedEvents,unblockedInstances,eventName,ownerId$1,()=>{update$6(eventName),updateBlocklist()})}let actionSwitch=async(enabled,eventName)=>{eventName!==`menu`&&(!enabled&&blockedEvents$1.value.includes(eventName)||await lua.extensions.core_input_bindings.setMenuActionEnabled(enabled,ACTIONS_BY_UI_EVENT[eventName]))};function rebind(){initialised||(initialised=!0,getUINavServiceInstance().clearBlockedEvents(),DEFAULT_NAVIGATION.forEach(name=>addEvent(name,`__uiNavTracker_default`))),Object.keys(ACTIONS_BY_UI_EVENT).filter(name=>!DEFAULT_NAVIGATION.includes(name)&&!trackedEvents.value.find(e=>e.name===name)).forEach(name=>actionSwitch(!1,name))}return lua.extensions.core_input_bindings.getMenuActionMapEnabled().then(enabled=>enabled&&rebind()),events$3.on(`MenuActionMapEnabled`,enabled=>enabled&&rebind()),{activeEvents,blockedEvents:blockedEvents$1,unblockedEvents,addEvent,updateEvent,removeEvent,addIgnore,removeIgnore,addBlocker,removeBlocker,addForceUnblock,removeForceUnblock}});function useUINavBlocker(){let id=uniqueId(`uiNavBlocker`),tracker=useUINavTracker(),allEventNames=Object.keys(ACTIONS_BY_UI_EVENT),defaultEvents=Object.freeze(Object.fromEntries(DEFAULT_NAVIGATION.map(name=>[name,name]))),allEvents=Object.freeze(UI_EVENTS),blockedEvents$1=[],unblockedEvents=[],filterEvents=events$3=>{if(!events$3)return[];if(typeof events$3==`string`)events$3=[events$3];else if(events$3.length===0)return[];return events$3.reduce((res,name)=>allEventNames.includes(name)&&!res.includes(name)?[...res,name]:res,[])};function allowOnly(events$3=[]){events$3=filterEvents(events$3),blockOnly(allEventNames.filter(name=>!events$3.includes(name)))}function allowNavigationOnly(enforce=!0){if(!enforce)return blockOnly();let events$3=[...DEFAULT_NAVIGATION,`menu`];blockOnly(allEventNames.filter(name=>!events$3.includes(name)))}function blockOnly(events$3=[]){events$3=filterEvents(events$3),blockedEvents$1.filter(name=>!events$3.includes(name)).forEach(name=>tracker.removeBlocker(name,id)),blockedEvents$1.splice(0),blockedEvents$1.push(...events$3),blockedEvents$1.forEach(name=>tracker.addBlocker(name,id))}function ensureNoBlock(events$3=[]){events$3=filterEvents(events$3),unblockedEvents.filter(name=>!events$3.includes(name)).forEach(name=>tracker.removeForceUnblock(name,id)),unblockedEvents.splice(0),unblockedEvents.push(...events$3),events$3.forEach(name=>tracker.addForceUnblock(name,id))}function isBlocked(eventName){return tracker.unblockedEvents.includes(eventName)?!1:tracker.blockedEvents.includes(eventName)}let clear=()=>blockOnly();return onUnmounted(clear),{allEvents,defaultEvents,allowOnly,allowNavigationOnly,blockOnly,clear,ensureNoBlock,isBlocked}}const useUiNavLabel=defineStore(`uiNavLabeler`,()=>{let elementLabels=reactive(new WeakMap),eventElements=reactive({});function registerLabel(element,eventNames,label){elementLabels.has(element)||elementLabels.set(element,{});let elementEvents=elementLabels.get(element);Array.isArray(eventNames)||(eventNames=[eventNames]);for(let eventName of eventNames)elementEvents[eventName]=label,eventElements[eventName]||(eventElements[eventName]=new Set),eventElements[eventName].add(element)}function clearLabels(element,eventNames=null){if(!elementLabels.has(element))return;let elementEvents=elementLabels.get(element);if(eventNames===null){for(let eventName of Object.keys(elementEvents))eventElements[eventName]&&eventElements[eventName].delete(element);elementLabels.delete(element)}else{for(let eventName of eventNames)delete elementEvents[eventName],eventElements[eventName]&&eventElements[eventName].delete(element);Object.keys(elementEvents).length===0&&elementLabels.delete(element)}}function getLabel(eventName,element=null){if(element&&elementLabels.has(element)&&elementLabels.get(element)[eventName])return elementLabels.get(element)[eventName];if(eventElements[eventName])for(let el of eventElements[eventName]){let label=elementLabels.get(el)?.[eventName];if(label)return label}return null}function getElementEvents(element){return elementLabels.has(element)?Object.keys(elementLabels.get(element)):[]}return{registerLabel,clearLabels,getLabel,getElementEvents}});var LUA_EXTENSION_NAME=`ui_topBar`;const useTopBar=defineStore(`topBar`,()=>{let{events:events$3}=useBridge(),setupComplete=!1,_items=ref({}),_activeItem=ref(null),visible=ref(!1),hiddenItems=ref([]),gameState$1=reactive({isInGame:void 0,gameState:void 0,uiState:void 0,isCareerActive:void 0,isGarageActive:void 0,isMissionActive:void 0,isScenarioActive:void 0}),sortItems=(a$1,b)=>(a$1.order??0)-(b.order??0),items$2=computed(()=>Object.values(_items.value).filter(item=>!hiddenItems.value||!hiddenItems.value.includes(item.id)).sort(sortItems)),activeItem=computed({get:()=>_activeItem.value,set:value=>{value!==_activeItem.value&&(_activeItem.value=value,Lua_default.ui_topBar.setActiveItem(value))}}),updateTopBarVisibility=()=>{if(!(!gameState$1.uiState||gameState$1.isInGame===void 0)){if(gameState$1.uiState.startsWith(`menu.mainmenu`)&&!gameState$1.isInGame&&(visible.value=!1),!visible.value||gameState$1.uiState===`unknown`){activeItem.value=null;return}if(gameState$1.uiState){let updatedActiveItem=Object.values(_items.value).find(item=>item.targetState===gameState$1.uiState);updatedActiveItem||=Object.values(_items.value).find(item=>item.substate&&gameState$1.uiState.startsWith(item.substate)),activeItem.value=updatedActiveItem?updatedActiveItem.id:null}updateHiddenItems()}};watch(()=>gameState$1.uiState,()=>nextTick(updateTopBarVisibility)),watch(()=>gameState$1.isInGame,()=>nextTick(updateTopBarVisibility));let selectPrevious=()=>{if(!visible.value)return;let len=items$2.value.length;if(len===0)return;let previousIndex=(items$2.value.findIndex(item=>item.id===activeItem.value)-1+len)%len;selectEntry(items$2.value[previousIndex].id)},selectNext=()=>{if(!visible.value)return;let len=items$2.value.length;if(len===0)return;let nextIndex=(items$2.value.findIndex(item=>item.id===activeItem.value)+1)%len;selectEntry(items$2.value[nextIndex].id)},selectEntry=itemId=>{visible.value&&(activeItem.value=itemId,Lua_default.ui_topBar.selectItem(itemId))},show=()=>{visible.value=!0},hide$2=()=>{visible.value=!1};function updateHiddenItems(){hiddenItems.value=Object.values(_items.value).filter(shouldHideItem).map(item=>item.id)}function shouldHideItem(item){if(!item.flags||item.flags.length===0)return!1;for(let flag of item.flags)if(flag===`inGameOnly`&&!gameState$1.isInGame||flag===`careerOnly`&&!gameState$1.isCareerActive||flag===`noCareer`&&gameState$1.isCareerActive||flag===`missionOnly`&&!gameState$1.isMissionActive||flag===`noMission`&&gameState$1.isMissionActive&&!gameState$1.isScenarioUnrestricted||flag===`garageOnly`&&!gameState$1.isGarageActive||flag===`noGarage`&&gameState$1.isGarageActive||flag===`scenarioOnly`&&!gameState$1.isScenarioActive||flag===`noScenario`&&gameState$1.isScenarioActive&&!gameState$1.isScenarioUnrestricted||flag===`careerGarageOnly`&&(!gameState$1.isCareerActive||!gameState$1.isGarageActive)||flag===`noCareerGarage`&&gameState$1.isCareerActive&&gameState$1.isGarageActive)return!0;return!1}function onCareerStateChanged(data){gameState$1.isCareerActive=data.isActive}function onGarageStateChanged(data){gameState$1.isGarageActive=data.isActive}function onMissionStateChanged(data){gameState$1.isMissionActive=data.isActive}function onScenarioStateChanged(data){gameState$1.isScenarioActive=data.isActive}function onDataRequested(data){let{isInGame,items:dataItems}=data;_items.value=dataItems,gameState$1.isInGame=isInGame,hiddenItems.value=[]}function onGameStateChanged(data){gameState$1.isInGame=data.isInGame,gameState$1.isCareerActive=data.isCareerActive,gameState$1.isGarageActive=data.isGarageActive,gameState$1.isMissionActive=data.isMissionActive,gameState$1.isScenarioActive=data.isScenarioActive,gameState$1.isScenarioUnrestricted=data.isScenarioUnrestricted,nextTick(()=>updateHiddenItems())}function onEntriesChanged(data){_items.value=data}function onVisibleItemsChanged(data){hiddenItems.value=data}function onShow(){visible.value=!0}function onHide(){visible.value=!1}let debouncedStateChange=debounce(data=>{gameState$1.uiState=(data.fullPath||data.name||`unknown`).replace(/^\//,``)},100);function onUIStateChanged(data){debouncedStateChange(data)}let eventHandlerMap={selectPrevious,selectNext,OnCareerActive:onCareerStateChanged,garageStateChanged:onGarageStateChanged,missionStateChanged:onMissionStateChanged,scenarioStateChanged:onScenarioStateChanged,dataRequested:onDataRequested,gameStateChanged:onGameStateChanged,entriesChanged:onEntriesChanged,visibleItemsChanged:onVisibleItemsChanged,show:onShow,hide:onHide};function addListeners(){for(let eventName of Object.keys(eventHandlerMap))events$3.on(`${LUA_EXTENSION_NAME}_${eventName}`,eventHandlerMap[eventName])}function removeListeners$1(){for(let eventName of Object.keys(eventHandlerMap))events$3.off(`${LUA_EXTENSION_NAME}_${eventName}`,eventHandlerMap[eventName])}return(async()=>{setupComplete||=(await Lua_default.extensions.isExtensionLoaded(LUA_EXTENSION_NAME)||await Lua_default.extensions.load(LUA_EXTENSION_NAME),addListeners(),await Lua_default.ui_topBar.requestData(),!0)})(),{activeItem,items:items$2,visible,gameState:gameState$1,show,hide:hide$2,selectEntry,selectPrevious,selectNext,onUIStateChanged,dispose:()=>{removeListeners$1(),Lua_default.extensions.unload(LUA_EXTENSION_NAME)}}});var events$2,beamNG,serviceProviders=ref(),online=ref(!1),videoAdapter=ref(``),modCounts=ref({total:0,active:0}),gameState=ref(),mainMenuBackgroundRequired=ref(),mainMenuFirstTime=ref(!0),serviceProvidersOnline=computed(()=>{let provs=serviceProviders.value,gotInfo=!!provs,ret={eos:gotInfo&&provs.eos&&provs.eos.loggedin,steam:gotInfo&&provs.steam&&provs.steam.loggedin&&provs.steam.working};return ret.any=Object.values(ret).some(v=>v),ret}),version,versionSimple,buildInfo,init$2=()=>{let api$1;({api:api$1,events:events$2,beamNG}=useBridge()),beamNG||=FAKE_BEAMNG_OBJ,api$1.serializeToLuaCheck(`English: hello`),api$1.serializeToLuaCheck(`Spanish: güeñes`),api$1.serializeToLuaCheck(`French: bâguéttè, garçon`),api$1.serializeToLuaCheck(`Czech: Kl�vesnice`),api$1.serializeToLuaCheck(`Korean: \r��\v��\v��`),api$1.serializeToLuaCheck(`Chinese Sim: 欢迎来到简体中文版的`),api$1.serializeToLuaCheck(`Chinese Tr: 歡迎來到`),api$1.serializeToLuaCheck(`Japanese: 』日本語版にようこそ`),api$1.serializeToLuaCheck(`Polish: źćłąóę`),api$1.serializeToLuaCheck(`Russian: абвгеёьъ`),events$2.on(`ServiceProviderInfo`,info=>serviceProviders.value=info),events$2.on(`OnlineStateChanged`,state=>online.value=state),events$2.on(`ModManagerModsChanged`,_processModData),events$2.on(`ShowEntertainingBackground`,state=>mainMenuBackgroundRequired.value=state),events$2.on(`GameStateUpdate`,state=>gameState.value=state.state),version=beamNG.version,versionSimple=_toSimpleVersion(beamNG.version),buildInfo=beamNG.buildinfo,refresh()},refresh=()=>{_requestServiceProviders(),_requestOnlineState(),_refreshVideoAdapter(),_refreshModData()},_refreshVideoAdapter=()=>Lua_default.Engine.Render.getAdapterType().then(adapter=>videoAdapter.value=adapter),_requestServiceProviders=()=>beamNG.requestServiceProviderInfo(),_requestOnlineState=()=>Lua_default.core_online.requestState(),_refreshModData=()=>Lua_default.core_modmanager.requestState(),sysInfo_default={init:init$2,refresh,serviceProviders,serviceProvidersOnline,online,videoAdapter,modCounts,gameState,mainMenuBackgroundRequired,mainMenuFirstTime,get version(){return version},get versionSimple(){return versionSimple},get buildInfo(){return buildInfo}},_toSimpleVersion=versionStr=>{let bits=versionStr.split(`.`);return bits.length==5&&bits.pop(),bits.join(`.`).replace(/(\.0)+$/,``)},_processModData=data=>{let mods=Object.values(data).filter(mod=>mod.modname!=`translations`);modCounts.value.total=mods.length,modCounts.value.active=mods.filter(({active})=>active).length},FAKE_BEAMNG_OBJ={version:`0.12.3.4.FAKE12345`,buildInfo:`Sample Fake BuildInfo - running outside of game`,requestServiceProviderInfo(){events$2.emit(`ServiceProviderInfo`,{steam:{loggedin:!0,accountID:`12345678901234567`,playerName:`fakeplayer`,branch:`qa_latest`,language:`english`,useSteam:!0,working:!0}})}};const useLibStore=defineStore(`lib`,{});var bridge$2,stateStack=[];function add(stateName){rem(stateName),stateStack.push(stateName)}function rem(stateName){let idx=stateStack.lastIndexOf(stateName);idx>-1&&stateStack.splice(idx,1)}var luaStringify=any=>JSON.stringify(any).replace(/^\[(.*)\]$/,`{$1}`),luaReport=(stateName,opened)=>bridge$2.api.engineLua(`extensions.hook("onUIStateTriggered", ${luaStringify(stateName)}, ${luaStringify(!!opened)}, ${luaStringify(stateStack)})`);function reportState(stateName,opened,prevName=null){bridge$2||=useBridge(),prevName&&(rem(prevName),luaReport(prevName,!1)),opened?add(stateName):rem(stateName),luaReport(stateName,opened)}function reportPopupState(popup,opened){reportState(`/popup/${popup.componentName}/${popup.wrapper.blur?`fullscreen`:`aside`}`,opened)}function scroll(el,binding){let direction$1=binding.arg;el.scrollHeight<=el.clientHeight||(direction$1===`top`?el.scrollTop>0&&(el.scrollTop=0):direction$1===`bottom`&&el.scrollTop{let id,blurAmount=1,blurUpdateWrapper=debounce(updateBlur,50),resizeObserver,removePositionObserver;function observe(){resizeObserver||(resizeObserver=new ResizeObserver(blurUpdateWrapper),resizeObserver.observe(el)),removePositionObserver||=observePosition(el,blurUpdateWrapper)}function unobserve(){resizeObserver&&resizeObserver.disconnect(),removePositionObserver&&removePositionObserver(),resizeObserver=null,removePositionObserver=null}elemBlurs.set(el,{blurUpdateWrapper,processBlurVal,observe,unobserve}),processBlurVal(binding.value),window.addEventListener(`resize`,blurUpdateWrapper);function processBlurVal(val){switch(typeof val){case`undefined`:val=1;break;case`boolean`:val=val?1:0;break;case`number`:(val<0||val>1)&&(logger_default.error(`Attempted to use v-bng-blur with a number out of range 0..1: ${val}\nSee stack:`,logger_default.STACK_TRACE),val=1);break;default:logger_default.error(`Attempted to use v-bng-blur with a non-number, non-boolean value: ${val}\nSee stack:`,logger_default.STACK_TRACE),val=0}blurAmount=val,blurUpdateWrapper()}function calcBlur(){let rect=el.getBoundingClientRect();return rect.width>0&&rect.height>0&&rect.bottom>0&&rect.top0&&rect.left{let elemBlur=elemBlurs.get(el);elemBlur&&binding.value!=binding.oldValue&&elemBlur.processBlurVal(binding.value)},unmounted:(el,binding)=>{let elemBlur=elemBlurs.get(el);elemBlur&&(elemBlur.unobserve(),elemBlur.processBlurVal(0),window.removeEventListener(`resize`,elemBlur.blurUpdateWrapper),elemBlurs.delete(el))}},DEFAULT_HOLD_DELAY=400,DEFAULT_REPEAT_INTERVAL=100,HOLD_CSS_TIME_VAR=`--hold-time`,HOLD_START_CSS_CLASS=`hold-start`,HOLD_ACTIVE_CSS_CLASS=`hold-active`,HOLD_COMPLETED_CSS_CLASS=`hold-completed`,EVENT_CLICK=`click`,EVENT_HOLD=`hold`,ELEMENT_ID=`__BNG_CLICK_ID`,curId=0,datas={};function update$5(element,binding){let id=element[ELEMENT_ID]||(element[ELEMENT_ID]=++curId),data=datas[id]||(datas[id]={id,element,events:{},binding:{}});if(typeof binding.value==`object`)data.binding=binding.value;else if(typeof binding.value==`function`){let cbName=binding.modifiers?.hold?`holdCallback`:`clickCallback`;data.binding[cbName]=binding.value}return data.controllerOnly=!!binding.modifiers?.controller,data.hasClick=typeof data.binding.clickCallback==`function`,data.hasHold=typeof data.binding.holdCallback==`function`,typeof data.binding.holdDelay!=`number`&&(data.binding.holdDelay=DEFAULT_HOLD_DELAY),typeof data.binding.repeatInterval!=`number`&&(data.binding.repeatInterval=DEFAULT_REPEAT_INTERVAL),data}function remove(element){let id=element[ELEMENT_ID];if(!id)return;let data=datas[id];data&&(`mouseleave`in data.events&&data.events.mouseleave(),updateEvents(id),delete datas[id],delete element[ELEMENT_ID])}function updateEvents(id,events$3={}){let data=datas[id];if(data){for(let event in data.events)data.element.removeEventListener(event,data.events[event]);for(let event in events$3)data.element.addEventListener(event,events$3[event]);data.events=events$3}}var BngClick_default={mounted:(el,binding)=>{let data=update$5(el,binding),approveEvent=evt=>data.controllerOnly?!!evt.fromController:evt.button===0||evt.fromController,tmrHoldActive;updateEvents(data.id,{mousedown:e=>{approveEvent(e)&&(el.style.setProperty(HOLD_CSS_TIME_VAR,`${data.binding.holdDelay}ms`),el.classList.toggle(HOLD_START_CSS_CLASS,!0),clearTimeout(tmrHoldActive),tmrHoldActive=setTimeout(()=>el.classList.toggle(HOLD_ACTIVE_CSS_CLASS,!0),0),el.classList.toggle(HOLD_COMPLETED_CSS_CLASS,!1),canInvokeEventType(EVENT_CLICK)&&(detectedEventType=EVENT_CLICK),canInvokeEventType(EVENT_HOLD)&&startHoldDelayTimer(e))},mouseup:e=>{if(approveEvent(e)){switch(el.style.removeProperty(HOLD_CSS_TIME_VAR),el.classList.toggle(HOLD_START_CSS_CLASS,!1),el.classList.toggle(HOLD_ACTIVE_CSS_CLASS,!1),clearTimeout(tmrHoldActive),stopHoldDelayTimer(),detectedEventType){case EVENT_CLICK:doAction(EVENT_CLICK,e);break;case EVENT_HOLD:stopHoldTimer();break}detectedEventType=null}},mouseleave:()=>{switch(el.style.removeProperty(HOLD_CSS_TIME_VAR),el.classList.toggle(HOLD_START_CSS_CLASS,!1),el.classList.toggle(HOLD_ACTIVE_CSS_CLASS,!1),clearTimeout(tmrHoldActive),stopHoldDelayTimer(),detectedEventType){case EVENT_HOLD:stopHoldTimer();break}detectedEventType=null},blur:()=>data.events.mouseleave()});let detectedEventType,holdDelayTimer,holdTimer;function startHoldDelayTimer(e){stopHoldTimer(),stopHoldDelayTimer(),holdDelayTimer=setTimeout(()=>{el.classList.toggle(HOLD_COMPLETED_CSS_CLASS,!0),detectedEventType=EVENT_HOLD,startHoldTimer(e)},data.binding.holdDelay)}function stopHoldDelayTimer(){holdDelayTimer&&=(clearTimeout(holdDelayTimer),null)}function startHoldTimer(e){doAction(EVENT_HOLD,e),data.binding.repeatInterval&&(stopHoldTimer(),holdTimer=setInterval(()=>{doAction(EVENT_HOLD,e)},data.binding.repeatInterval))}function stopHoldTimer(){holdTimer&&=(clearInterval(holdTimer),null)}function doAction(eventType,originalEvent){let callback=getCallback(eventType);callback&&(eventType==EVENT_HOLD?setTimeout(()=>callback(originalEvent),100):callback(originalEvent))}function getCallback(arg){switch(arg){case EVENT_CLICK:return data.binding.clickCallback;case EVENT_HOLD:return data.binding.holdCallback}return null}function canInvokeEventType(eventType){switch(eventType){case EVENT_CLICK:return data.hasClick;case EVENT_HOLD:return data.hasHold}return!1}},updated:update$5,beforeUnmount:remove},BngDisabled_default=(el,{value})=>{let has$1={disabled:el.hasAttribute(`disabled`),tabindex:el.hasAttribute(`tabindex`)};!has$1.disabled&&value?(el.setAttribute(`disabled`,`disabled`),has$1.tabindex&&(el._BNG_TABINDEX=el.getAttribute(`tabindex`),el.setAttribute(`tabindex`,`-1`))):has$1.disabled&&!value&&(el.removeAttribute(`disabled`),has$1.tabindex&&`_BNG_TABINDEX`in el&&el.getAttribute(`tabindex`)!==el._BNG_TABINDEX&&(el.setAttribute(`tabindex`,el._BNG_TABINDEX),delete el._BNG_TABINDEX))},DELAY=300,EVENTS_IN=[`uinav-focus`,`focus`,`focusin`],EVENTS_OUT=[`uinav-blur`,`blur`,`focusout`],elems$1=new Map,globInit=!1;function initGlobals(){globInit=!0;let running=!1,targets={in:[],out:[]};function preventer(){for(let[part,list]of Object.entries(targets))if(list.length!==0){for(let target of list)for(let[uid$2,data]of elems$1)if(!(!data.capture||!data.timer||!data.element)){if(part===`in`){if(data.element===target||data.element.contains(target))continue}else if(data.element!==target&&!data.element.contains(target))continue;clearTimeout(data.timer),data.timer=null;break}list.splice(0)}}function handler$1(evt,eventIn){if(elems$1.size===0)return;let target=evt.detail?.target||evt.target;if(!target)return;let part=eventIn?`in`:`out`;targets[part].includes(target)||targets[part].push(target),!running&&(running=!0,window.requestAnimationFrame(()=>{preventer(),running=!1}))}EVENTS_IN.forEach(evt=>document.addEventListener(evt,evt$1=>handler$1(evt$1,!0),!0)),EVENTS_OUT.forEach(evt=>document.addEventListener(evt,evt$1=>handler$1(evt$1,!1),!0))}function createHandler(data){return data.capture?evt=>{evt.detail?.doubleToSingle||(evt.preventDefault(),evt.stopImmediatePropagation(),data.timer?(clearTimeout(data.timer),data.timer=null,data.callback?.()):data.timer=setTimeout(()=>{data.timer=null;let click$1=new CustomEvent(`click`,{...evt,bubbles:!0,cancelable:!0,detail:{doubleToSingle:!0}});data.element.dispatchEvent(click$1)},DELAY))}:()=>{data.timer&&=(clearTimeout(data.timer),null);let now$1=Date.now();if(data.time&&now$1-data.time<=DELAY){data.time=0,data.callback?.();return}data.time=now$1}}function update$4(vnode,callback=void 0,mod={}){!globInit&&initGlobals();let el=vnode?.el;if(!el)return;let uid$2=vnode?.component?.uid||vnode?.key||el,capture=!!mod.capture,data=elems$1.get(uid$2)||{};data.handler&&data.element===el&&callback&&`callback`in data&&data.callback===callback&&data.capture===capture||(`element`in data||(data.element=el,data.callback=callback,data.capture=capture),data.handler&&(!callback||data.capture!==capture||data.element!==el)&&(delete data.callback,el.removeEventListener(`click`,data.handler,{capture:data.capture}),elems$1.delete(uid$2)),callback&&(data.handler?data.callback=callback:(data.capture=capture,data.handler=createHandler(data),el.addEventListener(`click`,data.handler,{capture}),elems$1.set(uid$2,data))))}var BngDoubleClick_default={mounted:(el,{value,modifiers,arg}={},vnode)=>update$4(vnode||{el},value,{capture:arg===`capture`,...modifiers}),updated:(el,{value,modifiers,arg}={},vnode)=>update$4(vnode||{el},value,{capture:arg===`capture`,...modifiers}),unmounted:(el,vnode)=>update$4(vnode||{el})},DRAG_START_EVENT_NAME=`bngDragStart`,DRAG_OVER_EVENT_NAME=`bngDragOver`,DRAG_END_EVENT_NAME=`bngDragEnd`;const DRAG_EVENTS=Object.freeze({dragStart:DRAG_START_EVENT_NAME,dragOver:DRAG_OVER_EVENT_NAME,dragEnd:DRAG_END_EVENT_NAME});var STORE_NAME=`controls`,store,DEVICE_ICONS={key:`keyboard`,mou:`mouseLMB`,vin:`smartphone2`,whe:`steeringWheelCommon`,gam:`gamepadOld`,xin:`gamepadOld`,default:`gamepad`};const CONTROL_LABELS={escape:`ESC`,enter:`⏎`,tab:`⭾`,capslock:`⇪`,backspace:`⌫`,delete:`Del`,insert:`Ins`,home:`Home`,end:`End`,pageup:`PG↑`,pagedown:`PG↓`,lshift:`L⇧`,rshift:`R⇧`,shift:`⇧`,lcontrol:`L Ctrl`,rcontrol:`R Ctrl`,lalt:`L Alt`,ralt:`R Alt`,left:`←`,right:`→`,up:`↑`,down:`↓`,space:`␣`,grave:`~`,backslash:`\\`,"/":`/`,comma:`,`,period:`.`,";":`;`,apostrophe:`'`,"[":`[`,"]":`]`,minus:`-`,"+":`NP+`,"*":`NP*`,numpaddivide:`NP/`,numpad0:`NP0`,numpad1:`NP1`,numpad2:`NP2`,numpad3:`NP3`,numpad4:`NP4`,numpad5:`NP5`,numpad6:`NP6`,numpad7:`NP7`,numpad8:`NP8`,numpad9:`NP9`,numpaddecimal:`NP.`,numpadenter:`NP⏎`,xaxis:`X Axis`,yaxis:`Y Axis`,zaxis:`Z Axis`,rzaxis:`R Z Axis`,thumblx:`L Thumb X`,thumbly:`L Thumb Y`,thumbrx:`R Thumb X`,thumbry:`R Thumb Y`};var controlLabel=control=>control.toLowerCase().split(/[ -]+/).map(ctl=>CONTROL_LABELS[ctl]||(ctl.startsWith(`button`)?`BTN`+ctl.substring(6):ctl)).join(` + `),CONTROL_ICONS={pc_mouse:{button0:`mouseLMB`,button1:`mouseRMB`,button2:`mouseMMB`,xaxis:`mouseXAxis`,yaxis:`mouseYAxis`,zaxis:`mouseWheel`},xbox:{btn_a:`xboxA`,btn_b:`xboxB`,btn_x:`xboxX`,btn_y:`xboxY`,btn_back:`xboxView`,btn_start:`xboxMenu`,btn_l:`xboxLB`,triggerl:`xboxLT`,btn_r:`xboxRB`,triggerr:`xboxRT`,dpov:`xboxDDown`,lpov:`xboxDLeft`,rpov:`xboxDRight`,upov:`xboxDUp`,thumblx:`xboxXAxis`,thumbly:`xboxYAxis`,thumbrx:`xboxXRot`,thumbry:`xboxYRot`,btn_lt:`xboxLSButton`,btn_rt:`xboxRSButton`},ps:{button1:`psCross`,button3:`psTriangle`,button0:`psSquare`,button2:`psCircle`,button8:`psCreate2`,button9:`psMenu2`,button4:`psL1`,button6:`psL2`,button5:`psR1`,button7:`psR2`,dpov:`psDDown`,lpov:`psDLeft`,rpov:`psDRight`,upov:`psDUp`,xaxis:`psLSX`,yaxis:`psLSY`,zaxis:`psRSX`,rzaxis:`psRSY`,rxaxis:`psL2`,ryaxis:`psR2`,button10:`psL3Button`,button11:`psR3Button`,button13:`psTrackpadPressCenter`}};const DEVICE_CONTROLS={pc_mouse:Object.keys(CONTROL_ICONS.pc_mouse),xbox:Object.keys(CONTROL_ICONS.xbox),ps:Object.keys(CONTROL_ICONS.ps)};var extendControlGroupNames=groups=>groups.reduce((res,group)=>(res.push(group),res.push({...group,controls:group.controls.map(ctl=>CONTROL_LABELS[ctl])}),res),[]),GROUPED_CONTROLS={pc_keyboard:extendControlGroupNames([{label:`↑↓←→`,controls:[`left`,`right`,`up`,`down`]},{label:`NP 8↑ 2↓ 4← 6→`,controls:[`numpad2`,`numpad4`,`numpad6`,`numpad8`]}]),xbox:extendControlGroupNames([{icon:`xboxDDefaultSolid`,controls:[`upov`,`dpov`,`lpov`,`rpov`]},{icon:`xboxThumbL`,controls:[`thumblx`,`thumbly`]},{icon:`xboxThumbR`,controls:[`thumbrx`,`thumbry`]}]),ps:extendControlGroupNames([{icon:`psDDefaultSolid`,controls:[`upov`,`dpov`,`lpov`,`rpov`]},{icon:`psLS`,controls:[`xaxis`,`yaxis`]},{icon:`psRS`,controls:[`zaxis`,`rzaxis`]}])},DEVICE_FAMILY={mouse:`pc_mouse`,keyboard:`pc_keyboard`,xinput:`xbox`,ps5:`ps`},CONTROL_ICON_KEYS=Object.keys(DEVICE_FAMILY),getViewerOverrides=(devName=void 0,imagePack=void 0)=>{let family;return imagePack&&(imagePack in DEVICE_FAMILY?family=DEVICE_FAMILY[imagePack]:imagePack in CONTROL_ICONS&&(family=imagePack)),!family&&devName&&(devName=CONTROL_ICON_KEYS.find(key=>devName.startsWith(key))||devName,devName in DEVICE_FAMILY?family=DEVICE_FAMILY[devName]:devName in CONTROL_ICONS&&(family=devName)),family?{family,icons:CONTROL_ICONS[family]||{},groups:GROUPED_CONTROLS[family]||[]}:null},DEVICE_ORDER=[`wheel`,`joystick`,`xinput`,`gamepad`,`mouse`,`keyboard`],makeStore=defineStore(STORE_NAME,()=>{let{events:events$3}=useBridge(),devNamesOrder=DEVICE_ORDER.map(devType=>devType+`0`),actions=ref([]),categories=ref({}),categoriesList=ref([]),bindings=ref([]),bindingsPerDevice=computed(()=>Object.fromEntries(bindings.value.map(b=>[b.devname,b]))),bindingTemplate=ref({}),controllers=ref({}),players=ref({}),lastDeviceOrder=ref([...devNamesOrder]),lastDevice=computed(()=>isKbm(lastDeviceOrder.value[0])?kbmDevNames:lastDeviceOrder.value[0]),lastControllers=computed(()=>lastDeviceOrder.value.filter(devName=>!isKbm(devName))),lastControllersSignature=computed(()=>lastControllers.value.sort().join(`::`)),isControllerUsed=computed(()=>!isKbm(lastDeviceOrder.value[0])),isControllerAvailable=computed(()=>lastDeviceOrder.value.some(devName=>!isKbm(devName))),lastDeviceSimple=computed(()=>isControllerUsed.value?lastDevice.value:null),getDevType=devName=>devName?devName.replace(/\d+$/,``):``,deviceSorter=(a$1,b)=>DEVICE_ORDER.indexOf(getDevType(a$1))-DEVICE_ORDER.indexOf(getDevType(b)),kbmDevNames=[`keyboard0`,`mouse0`].sort(deviceSorter),kbmShortNames=kbmDevNames.map(devName=>devName.slice(0,3)),isKbm=devName=>devName&&kbmShortNames.includes(devName.slice(0,3)),_receiveControlsData=data=>(controllers.value=data,_updateDeviceNotes()),_receivePlayersData=data=>players.value=data,_receiveBindingsData=_processBindingsData,_getBindingsData=()=>Lua_default.extensions.core_input_bindings.notifyUI(`Vue controls service needs the data`),connect=(state=!0)=>{let method=state?`on`:`off`;events$3[method](`ControllersChanged`,_receiveControlsData),events$3[method](`AssignedPlayersChanged`,_receivePlayersData),events$3[method](`InputBindingsChanged`,_receiveBindingsData),events$3[method](`RecentDevicesChanged`,_requestRecentDevices)},disconnect=()=>connect(!1),deviceIcon=deviceName=>DEVICE_ICONS[(deviceName||``).slice(0,3)]||DEVICE_ICONS.default;async function _requestRecentDevices(devNames=void 0){devNames||=await Lua_default.extensions.core_input_bindings.getRecentDevices(),!Array.isArray(devNames)||devNames.length===0?devNames=devNamesOrder:isKbm(devNames[0])&&(devNames=[...kbmDevNames,...devNames.filter(devName=>!isKbm(devName))]),lastDeviceOrder.value.splice(0,lastDeviceOrder.value.length,...devNames)}function*getBindingsIter(devFilter=[],useLastDeviceOrder=!1){if(!useLastDeviceOrder||devFilter.length>0)yield*bindings.value;else for(let devName of lastDeviceOrder.value){let binding=bindingsPerDevice.value[devName];binding&&(yield binding)}}let findBindingForAction=(action,devName=void 0,useLastDeviceOrder=!1)=>{let devFilter=devName?Array.isArray(devName)?devName:[devName]:[],bindingsIter=getBindingsIter(devFilter,useLastDeviceOrder);for(let binding of bindingsIter){if(devFilter.length>0&&!devFilter.includes(binding.devname))continue;let found=binding.contents.bindings.find(b=>b.action===action);if(found){let help=getBindingDetails(binding.devname,found.control,action);if(help)return help.devName=binding.devname,help.imagePack=binding.contents.imagePack,help}}},findAllBindingsForAction=(action,devName=void 0,allDevices=!1,useLastDeviceOrder=!1)=>{let res=[],devFilter=devName?Array.isArray(devName)?devName:[devName]:[],bindingsIter=getBindingsIter(devFilter,useLastDeviceOrder);for(let binding of bindingsIter){if(devFilter.length>0&&!devFilter.includes(binding.devname))continue;let matches$1=binding.contents.bindings.filter(b=>b.action===action);if(matches$1.length>0)for(let match of matches$1){let help=getBindingDetails(binding.devname,match.control,action);help&&(!allDevices&&devFilter.length===0&&devFilter.push(binding.devname),help.devName=binding.devname,help.imagePack=binding.contents.imagePack,res.push(help))}}return res},defaultBindingEntry=(action,control)=>({...bindingTemplate.value,action,control}),isAxis=(device,control)=>{let c=controllers.value[device].controls[control];return c&&c.control_type==`axis`},bindingConflicts=(device,control,action)=>bindings.value.find(b=>b.devname==device).contents.bindings.filter(b=>b.control==control).filter(b=>b.action!=action).map(b=>({...b,...getBindingDetails(device,control,b.action),resolved:!1})),captureBinding=(modifiersAllowed=!0)=>{let controlCaptured=!1,eventsRegister={},d=defer(),capturingBinding=!0;function _listener(data){if(!capturingBinding||controlCaptured)return;let devName=data.devName;eventsRegister[devName]||(eventsRegister[devName]={axis:{},key:[null,null]});let eventData=eventsRegister[devName];d.notify(eventsRegister);let valid=!1,key0,key1,key0Parts,key1Parts,genericModifierKeys=[`lalt`,`lcontrol`,`lshift`,`ralt`,`rcontrol`,`rshift`];switch(data.controlType){case`axis`:if(!eventData.axis[data.control])eventData.axis[data.control]={first:data.value,last:data.value,accumulated:0};else{let detectionThreshold=devName.startsWith(`mouse`)?1:.5;eventData.axis[data.control].accumulated+=Math.abs(eventData.axis[data.control].last-data.value)/detectionThreshold,eventData.axis[data.control].last=data.value}valid=eventData.axis[data.control].accumulated>=1;break;case`button`:case`pov`:case`key`:if(eventData.key=[eventData.key.at(-1),data.control],key0=eventData.key[0],key1=eventData.key[1],key0&&key1){let validSet=!1;key0Parts=key0.split(` `),key1Parts=key1.split(` `),key0Parts.length===1&&key1Parts.length===2&&key1Parts[1]===key0Parts[0]&&(eventData.key[1]=key0,key1=key0,data.control=key0,modifiersAllowed||(valid=!1,validSet=!0)),validSet||(valid=key0===key1,!modifiersAllowed&&(key0Parts.length===2||genericModifierKeys.includes(data.control))&&(valid=!1)),data.value===0&&(eventData.key=[null,null])}break;default:console.error(`Unrecognised raw input controlType: `+JSON.stringify(data))}valid&&data.devName.startsWith(`mouse`)&&data.control===`button1`&&(valid=!1),valid&&(controlCaptured=!0,capturingBinding=!1,data.direction=data.controlType===`axis`?Math.sign(eventData.axis[data.control].last-eventData.axis[data.control].first):0,d.resolve(data),_captureHelper.stopListening())}return Lua_default.ActionMap.enableBindingCapturing(!0),Lua_default.setCEFTyping(!0),_captureHelper.stopListening=()=>{Lua_default.ActionMap.enableBindingCapturing(!1),Lua_default.WinInput.setForwardRawEvents(!1),Lua_default.setCEFTyping(!1),events$3.off(`RawInputChanged`,_listener)},events$3.on(`RawInputChanged`,_listener),Lua_default.WinInput.setForwardRawEvents(!0),d.promise},removeBinding=(device,control,action,mockSave)=>{let deviceContents={...bindings.value.find(b=>b.devname==device).contents};deviceContents.bindings=[...deviceContents.bindings];let entryIndex=deviceContents.bindings.findIndex(b=>b.control==control&&b.action==action)||null;if(entryIndex)if(deviceContents.bindings.splice(entryIndex,1),mockSave){let deviceIndex=bindings.value.findIndex(b=>b.devname==device);bindings.value[deviceIndex].contents=deviceContents}else serializeCheck(deviceContents.name),Lua_default.extensions.core_input_bindings.saveBindingsToDisk(deviceContents)},addBinding=(device,bindingData,replace,mockSave)=>{let deviceContents={...bindings.value.find(b=>b.devname==device).contents};if(deviceContents.bindings=[...deviceContents.bindings],replace){let deprecatedIndex=deviceContents.bindings.findIndex(b=>b.control==bindingData.details.control&&b.action==bindingData.details.action);deviceContents[deprecatedIndex]=bindingData}else serializeCheck(deviceContents.name),Lua_default.extensions.core_input_bindings.saveBindingsToDisk(deviceContents)},isFFBBound=()=>{for(let i=0;i{let ffbCapable=()=>Object.values(controllers.value).some(controller=>controller.ffbAxes&&Object.keys(controller.ffbAxes).length>0);return asRef?computed(()=>ffbCapable()):ffbCapable},getIsControllerAvailable=(asRef=!1)=>asRef?isControllerAvailable:isControllerAvailable.value,isWheelFound=vendorId=>{for(let b of bindings.value)if(b.devname.slice(0,3)===`whe`&&b.contents.vidpid.slice(4,8)==vendorId)return!0;return!1};function isFFBEnabled(asRef=!1){let filter=()=>bindings.value.filter(b=>b.devname.slice(0,3)!==`xin`).some(b=>b.contents.bindings.some(binding=>binding.action===`steering`&&binding.isForceEnabled));return asRef?computed(()=>filter()):filter()}function isPidVidFound(desiredVid,desiredPid,asRef=!1){let filter=()=>bindings.value.some(b=>{let vid=desiredVid===void 0?desiredVid:b.contents.vidpid.slice(4,8),pid$1=desiredPid===void 0?desiredPid:b.contents.vidpid.slice(0,4);return vid==desiredVid&&pid$1==desiredPid});return asRef?computed(()=>filter()):filter()}function getBindingDetails(device,control,action){let actionDetails=getActionDetails(action);if(!actionDetails){console.warn(`Action details not found: `,action);return}let deviceBindings=bindings.value.find(b=>b.devname===device).contents.bindings,common={icon:deviceIcon(device),title:actionDetails.title,desc:actionDetails.desc},details=deviceBindings.find(b=>b.control===control&&b.action===action)||defaultBindingEntry(action,control),isBindingAxis=isAxis(device,control);return{...bindingTemplate.value,...details,...common,isAxis:isBindingAxis,action:actionDetails.action,actionName:actionDetails.actionName}}function getActionDetails(action){let actionDetails=actions.value[action];if(actionDetails)return{...actionDetails,action:actionDetails.actionName}}function addNewBinding(bindingData){let{devname,control,action}=bindingData,device=bindings.value.find(b=>b.devname==devname);if(!device){console.warn(`Device not found: `,devname);return}let deviceContents=device.contents;deviceContents.bindings.push({...bindingTemplate.value,...bindingData,control,action}),serializeCheck(deviceContents.name),Lua_default.extensions.core_input_bindings.saveBindingsToDisk(deviceContents)}function updateBinding(bindingData){let{devname,control,action}=bindingData,oldDevname=bindingData.oldDevname||devname,oldControl=bindingData.oldControl||control,device=bindings.value.find(b=>b.devname==oldDevname);if(!device){console.warn(`Device not found: `,oldDevname);return}let deviceContents=device.contents,deprecatedIndex=deviceContents.bindings.findIndex(b=>b.control==oldControl&&b.action==action);if(deprecatedIndex===-1){console.warn(`Binding not found: `,oldDevname,oldControl,action);return}if(devname===oldDevname)delete bindingData.oldDevname,delete bindingData.oldControl,deviceContents.bindings[deprecatedIndex]={...bindingData};else{deviceContents.bindings.splice(deprecatedIndex,1);let newDeviceContents=bindings.value.find(b=>b.devname===devname).contents;newDeviceContents.bindings.push({...bindingData,bindingTemplate:bindingTemplate.value}),serializeCheck(newDeviceContents.name),Lua_default.extensions.core_input_bindings.saveBindingsToDisk(newDeviceContents)}serializeCheck(deviceContents.name),Lua_default.extensions.core_input_bindings.saveBindingsToDisk(deviceContents)}function deleteBindings(bindingsData){let bindingsByDevname=bindingsData.reduce((acc,b)=>(acc[b.devname]=acc[b.devname]||[],acc[b.devname].push(b),acc),{});for(let devname in bindingsByDevname){let device=bindings.value.find(b=>b.devname==devname);if(!device){console.warn(`Device not found: `,devname);continue}let deviceContents=device.contents;bindingsByDevname[devname].forEach(b=>{let index=deviceContents.bindings.findIndex(binding=>binding.control==b.control&&binding.action==b.action);index!==-1&&deviceContents.bindings.splice(index,1)}),serializeCheck(deviceContents.name),Lua_default.extensions.core_input_bindings.saveBindingsToDisk(deviceContents)}}function deleteBinding({devname,control,action}){let device=bindings.value.find(b=>b.devname==devname);if(!device){console.warn(`Device not found: `,devname);return}let deviceContents=device.contents,index=deviceContents.bindings.findIndex(b=>b.control==control&&b.action==action);if(index===-1){console.warn(`Binding not found: Skipping...`,devname,control,action);return}deviceContents.bindings.splice(index,1),serializeCheck(deviceContents.name),Lua_default.extensions.core_input_bindings.saveBindingsToDisk(deviceContents)}function getAllBindingsForAction(action,devName,asRef=!1){let filteredBindings=()=>bindings.value.filter(b=>(!devName||b.devname==devName)&&b.contents.bindings.find(a$1=>a$1.action===action)).flatMap(b=>b.contents.bindings.filter(x=>x.action===action).map(x=>({...x,...getBindingDetails(b.devname,x.control,x.action),devname:b.devname,action,actionName:action})));return asRef?computed(()=>filteredBindings()):filteredBindings()}let _captureHelper={devName:null,stopListening:null};function _updateDeviceNotes(){Object.values(bindings.value).forEach(({contents:bindingContents})=>{for(let id in controllers.value){let controller=controllers.value[id];if(bindingContents.vidpid==controller.vidpid){controller.notes=bindingContents.notes;break}}})}let lastBindingsData=null;function _processBindingsData(data){let newBindingsData=JSON.stringify(data);if(lastBindingsData===newBindingsData)return;if(lastBindingsData=newBindingsData,Array.isArray(data.bindings)||(data.bindings=[]),data.bindings.forEach(device=>{Array.isArray(device.contents.bindings)||(device.contents.bindings=Object.values(device.contents.bindings))}),bindingTemplate.value=data.bindingTemplate,bindings.value=data.bindings,!data.actionCategories||!data.bindingTemplate||data.bindings.length===0){logger_default.debug(`Did not receive bindings data. Timing issue?`);return}bindings.value.sort((a$1,b)=>deviceSorter(a$1.devname,b.devname)),devNamesOrder.splice(0),kbmDevNames.splice(0);for(let binding of data.bindings){let devName=binding.devname;devNamesOrder.includes(devName)||devNamesOrder.push(devName),isKbm(devName)&&kbmDevNames.push(devName),binding.icon=deviceIcon(devName)}_requestRecentDevices();let acts={};for(let act in data.actions)acts[act]={actionName:act,...data.actions[act]};for(let cat in actions.value=acts,categories.value=data.actionCategories,categories.value)typeof categories.value[cat]==`object`&&(categories.value[cat].actions=[]);for(let act in actions.value){let obj={key:act,...actions.value[act]};actions.value[act].cat in categories.value||(categories.value[actions.value[act].cat]={order:99,icon:`symbol_exclamation`,title:`UNDEFINED CATEGORY: `+actions.value[act].cat,desc:``,actions:[]}),categories.value[actions.value[act].cat].actions.push(obj)}for(let x in categoriesList.value=[],Object.entries(categories.value).forEach(([catName,cat])=>categoriesList.value.push({key:catName,...cat})),categoriesList.value)for(let y in categoriesList.value[x].actions)for(let z in categoriesList.value[x].actions[y].titleTranslated=$translate.instant(categoriesList.value[x].actions[y].title),categoriesList.value[x].actions[y].descTranslated=$translate.instant(categoriesList.value[x].actions[y].desc),categoriesList.value[x].actions[y].tags)categoriesList.value[x].actions[y].tagsTranslated||(categoriesList.value[x].actions[y].tagsTranslated=[]),categoriesList.value[x].actions[y].tagsTranslated[z]=$translate.instant(categoriesList.value[x].actions[y].tags[z]);_updateDeviceNotes()}function makeViewerObj({deviceKey,device,action,uiEvent,imagePack,controller=!1,actionVariants=!1,useLastDevice=!1}){let viewerObj,multiDevice=!1;if(device&&Array.isArray(device)&&device.length===0&&(device=void 0),Array.isArray(device)&&(device.length===0?device=void 0:device.length===1?device=device[0]:multiDevice=!0),!device&&controller&&(device=lastControllers.value,device.length===0?device=void 0:device.length===1?device=device[0]:multiDevice=!0),uiEvent&&(action=ACTIONS_BY_UI_EVENT[uiEvent]),action?actionVariants?(viewerObj=_buildViewerObjVariants(findAllBindingsForAction(action,device,!1,useLastDevice)),actionVariants=!!viewerObj?.variants,actionVariants&&viewerObj.variants.sort((a$1,b)=>a$1.isInverted-b.isInverted)):viewerObj=findBindingForAction(action,device,useLastDevice):actionVariants=!1,deviceKey){let devName=viewerObj?.devName||(multiDevice?device[0]:device);viewerObj={icon:deviceIcon(devName),control:deviceKey,devName,imagePack:viewerObj?.imagePack||imagePack}}return viewerObj&&(_parseViewerObj(viewerObj,imagePack,actionVariants),viewerObj.variants&&viewerObj.variants.forEach(obj=>_parseViewerObj(obj,imagePack,actionVariants,device))),viewerObj}function _buildViewerObjVariants(viewerObjs){let len=viewerObjs?.length||0;if(len!==0)return len===1?viewerObjs[0]:{...viewerObjs[0],variants:viewerObjs}}let rgxCombo=/modifier(?\d+)[ -]+|[ -]*(?.+)/gi;function _parseViewerObj(viewerObj,imagePack=void 0,actionVariants=!1,devNames=void 0){let devName=viewerObj.devName;if(imagePack=viewerObj.imagePack||imagePack,!imagePack){let binding=bindings.value?.find(b=>b.devname===devName);binding?.contents?.imagePack&&(imagePack=binding.contents.imagePack),!imagePack&&devName&&(imagePack=CONTROL_ICON_KEYS.find(key=>devName.startsWith(key))),viewerObj.imagePack=imagePack}if(viewerObj.control.startsWith(`modifier`)){let matches$1=[...viewerObj.control.matchAll(rgxCombo)].map(m=>m.groups);if(matches$1.length>0){viewerObj.multiControls=[];for(let match of matches$1)if(match.mod){let modName=`customModifier`+match.mod,mod=actionVariants?_buildViewerObjVariants(findAllBindingsForAction(modName,devName,!1,!1)):findBindingForAction(modName,devName);mod||=actionVariants?_buildViewerObjVariants(findAllBindingsForAction(modName,devNames,!1,!1)):findBindingForAction(modName,devNames),mod&&viewerObj.multiControls.push(mod)}else viewerObj.multiControls.push({devName,control:match.key,icon:viewerObj.icon,imagePack})}}_addCustomInfo(viewerObj),viewerObj.multiControls&&viewerObj.multiControls.forEach(_addCustomInfo)}function _addCustomInfo(viewerObj){let devOverrides=getViewerOverrides(viewerObj.devName,viewerObj.imagePack);viewerObj.family=devOverrides?.family;let ownIcon=devOverrides?.icons[viewerObj.control];viewerObj.special=!!ownIcon,viewerObj.ownGroups=devOverrides?.groups,viewerObj.special?viewerObj.ownIcon=ownIcon:viewerObj.control=controlLabel(viewerObj.control)}return connect(),_getBindingsData(),{categories:computed(()=>categories.value),categoriesList:computed(()=>categoriesList.value),controllers:computed(()=>controllers.value),players:computed(()=>players.value),bindingTemplate:computed(()=>bindingTemplate.value),lastDevice:lastDeviceSimple,lastDevices:lastDeviceOrder,lastControllers,lastControllersSignature,isControllerAvailable,isControllerUsed,showIfController:isControllerUsed,focusIfController:isControllerAvailable,addNewBinding,connect,deleteBinding,deleteBindings,disconnect,deviceIcon,findBindingForAction,findAllBindingsForAction,getActionDetails,getBindingDetails,getAllBindingsForAction,defaultBindingEntry,isAxis,bindingConflicts,captureBinding,removeBinding,addBinding,isFFBBound,isFFBEnabled,isFFBCapable,isGamepadAvailable:getIsControllerAvailable,isWheelFound,isPidVidFound,makeViewerObj,updateBinding}}),useStore=()=>store||=makeStore(),controls_default=useStore,direction=`right`,focusClass=`focus-visible`,isController$1={value:!1},now=()=>new Date().getTime(),inited=!1,gamepadInited=!1,elms$3=[];function setFocus(elm,enable=!0){if(enable){if(elm.classList.add(focusClass),elm===document.activeElement)return}else if(elm.classList.remove(focusClass),elm!==document.activeElement)return;try{enable&&focusOnElement(elm)}catch{}}function setFocusExternal(elm,enable=!0,attemptScroll=!0){return elm?(!gamepadInited&&gamepadInit(),enable&&!isController$1.value?(attemptScroll&&isOccluded(elm,!0)&&scrollFix({dom:elm,rect:elm.getBoundingClientRect()},`down`),!1):(setFocus(elm,enable),!0)):!1}function ensureFocus(elm,onNextTick=!0){elm&&(!gamepadInited&&gamepadInit(),isController$1.value&&document.activeElement===elm&&!elm.classList.contains(focusClass)&&(onNextTick?nextTick(()=>elm&&setFocus(elm)):setFocus(elm)))}function gamepadInit(){gamepadInited||(gamepadInited=!0,isController$1=storeToRefs(controls_default()).focusIfController)}function init$1(){inited||(inited=!0,gamepadInit(),watch(isController$1,val=>{let active=document.activeElement;if(isNavigable$1(active)){let focused$1=active.classList.contains(focusClass);val&&!focused$1?setFocus(active,!0):!val&&focused$1&&setFocus(active,!1);return}if(val){if(priorityFocus())return;navigate(collectRects(direction),direction)&&window.requestAnimationFrame(()=>setFocus(document.activeElement,!0))}}))}function priorityFocus(){collectRects(direction);for(let{elm}of elms$3)if(isNavigable$1(elm))return setFocus(elm,!0),!0;return!1}function wantsFocus(elm,priority){inited||init$1();let dat=elms$3.find(itm=>itm.element===elm)||{elm,time:now()},isNew=!(`priority`in dat);if(typeof priority!=`number`||isNaN(priority)){if(!isNew){let idx=elms$3.findIndex(itm=>itm.elm===elm);idx>-1&&elms$3.splice(idx,1)}return}dat.priority=priority,isNew&&elms$3.push(dat),elms$3.sort((a$1,b)=>b.priority-a$1.priority||b.time-a$1.time),collectRects(direction,elm.parentNode),isNew&&isController$1.value&&!isNavigable$1(document.activeElement)&&priorityFocus()}function unwantsFocus(elm){let idx=elms$3.findIndex(itm=>itm.elm===elm);idx!==-1&&(elms$3.splice(idx,1),isController$1.value&&!isNavigable$1(document.activeElement)&&priorityFocus())}function initFocusVisible(){let raf=window.requestAnimationFrame,curFocused=null,holdFocus=!1;function notify(type,target,relatedTarget){let evt=new CustomEvent(`uinav-`+type,{bubbles:!0,cancelable:!0,detail:{target,relatedTarget}});document.dispatchEvent(evt)}function procFocus(target,relatedTarget){if(!(target&&target===curFocused)&&(relatedTarget===target&&(relatedTarget=void 0),relatedTarget&&doBlur(relatedTarget),curFocused&&=((!relatedTarget||relatedTarget!==curFocused)&&(relatedTarget=curFocused),doBlur(curFocused),null),target))try{if(target.disabled)return;if(`tabIndex`in target){if(typeof target.tabIndex==`string`&&target.tabIndex===`-1`||typeof target.tabIndex==`number`&&target.tabIndex===-1||target.tabIndex===``)return}else if(`contentEditable`in target){if(typeof target.contentEditable==`string`&&target.contentEditable!==`true`||typeof target.contentEditable==`boolean`&&!target.contentEditable)return}else return;let style=window.getComputedStyle(target);if(style.display===`none`||style.visibility===`hidden`||style.pointerEvents===`none`)return;if(isController$1.value&&target.classList.add(focusClass),curFocused=target,focusRegistry.includes(target)||focusRegistry.push(target),document.activeElement!==curFocused){holdFocus=!0;let holdFocusCounter=0;raf(function check(){!curFocused||holdFocusCounter>10||document.activeElement===curFocused?(holdFocus=!1,!curFocused||target!==curFocused?doBlur(target):notify(`focus`,curFocused,relatedTarget)):(holdFocusCounter++,curFocused.focus(),raf(check))})}else notify(`focus`,target,relatedTarget)}catch{}}function doBlur(target){if(target&&!(holdFocus&&target===curFocused))try{target.classList.remove(focusClass),target===curFocused&&(curFocused=null);let idx=focusRegistry.indexOf(target);idx!==-1&&(focusRegistry.splice(idx,1),notify(`blur`,target))}catch{}}document.addEventListener(`focusin`,evt=>procFocus(evt.target,evt.relatedTarget),!0),document.addEventListener(`focusout`,evt=>doBlur(evt.target),!0);let focusRegistry=[],originalFocus=HTMLElement.prototype.focus.__original__||HTMLElement.prototype.focus,originalBlur=HTMLElement.prototype.blur.__original__||HTMLElement.prototype.blur;HTMLElement.prototype.focus=function(...args){let target=this,prevFocused=document.activeElement;prevFocused.classList.contains(focusClass)||(focusRegistry.length>0?focusRegistry.forEach(elm=>elm!==target&&elm.blur()):document.querySelectorAll(`.`+focusClass).forEach(elm=>elm!==target&&doBlur(elm))),originalFocus.apply(target,args),procFocus(target,prevFocused)},HTMLElement.prototype.blur=function(...args){doBlur(this),originalBlur.apply(this,args)},HTMLElement.prototype.focus.__original__=originalFocus,HTMLElement.prototype.blur.__original__=originalBlur}var EVENT_CALLS=Object.entries({focus:[`uinav-focus`,`focus`,`focusin`,`click`],hide:[`mouseenter`],show:[`uinav-blur`,`blur`,`focusout`,`mouseleave`]}).reduce((res,[name,events$3])=>(events$3.forEach(event=>res[event]=name),res),{}),ID$1=`__bngFocusCapture`,elms$2={},isController;function setupController(){isController||(isController=storeToRefs(controls_default()).isControllerUsed,watch(isController,val=>{for(let data of Object.values(elms$2))val?data.show():data.hide()}))}function getClosestNavigable(elm){let target=collectRects(`down`,elm).down[0]?.dom;return target&&isNavigable$1(target)?target:null}function update$3(data,value,firstTime=!1){if(typeof value==`function`?(data.handler=()=>{let elm=value(data.parent);return elm?.$el||elm},delete data.disabled):typeof value==`boolean`&&!value?data.disabled=!0:delete data.disabled,data.disabled){if(data.hide(),!firstTime)for(let event in data.capture.remove(),EVENT_CALLS)data.parent.removeEventListener(event,data[EVENT_CALLS[event]])}else for(let event in data.parent.appendChild(data.capture),data.show(),EVENT_CALLS)data.parent.addEventListener(event,data[EVENT_CALLS[event]])}var BngFocusCapture_default={mounted(elm,{arg,value}){setupController();let id=uniqueId(ID$1),parent=elm,capture=document.createElement(`div`),data={id,shown:!0,parent,capture,handler:()=>getClosestNavigable(data.parent)};elms$2[id]=data,parent[ID$1]=id,capture.className=`bng-focus-capture`,capture.style.setProperty(`position`,`absolute`,`important`),capture.style.setProperty(`display`,`block`,`important`),capture.style.setProperty(`top`,`0%`,`important`),capture.style.setProperty(`left`,`0%`,`important`),capture.style.setProperty(`width`,`100%`,`important`),capture.style.setProperty(`height`,`100%`,`important`),capture.style.setProperty(`z-index`,arg&&/^\d+$/.test(arg)?arg:`1000`,`important`),capture.style.setProperty(`pointer-events`,`all`,`important`),capture.setAttribute(`bng-nav-item`,``),capture.setAttribute(`tabindex`,`0`),data.focus=()=>{if(data.hide(),!isController.value)return;let active=document.activeElement;if(!(active!==data.capture&&data.parent.contains(active))&&data.handler){let elm$1=data.handler(data.parent);elm$1&&nextTick(()=>setFocusExternal(elm$1))}},data.hide=()=>{data.shown&&(data.shown=!1,capture.style.setProperty(`pointer-events`,`none`,`important`))},data.show=evt=>{if(data.shown||(data.shown=!0,data.disabled||!isController.value))return;let active=document.activeElement;if(data.parent.contains(active))return;let target=evt?.relatedTarget||evt?.target||active;data.parent.contains(target)||capture.style.setProperty(`pointer-events`,`all`,`important`)},update$3(data,value,!0)},updated(elm,{arg,value}){let id=elm[ID$1];if(!id)return;let data=elms$2[id];data&&update$3(data,value)},unmounted(elm){let id=elm[ID$1];if(!id)return;delete elm[ID$1];let data=elms$2[id];if(data){for(let event in data.capture.remove(),EVENT_CALLS)data.parent.removeEventListener(event,data[EVENT_CALLS[event]]);delete elms$2[id]}}},BngFocusIf_default=(el,{value})=>value&&nextTick(()=>{let shouldFocus=typeof value==`object`?value.value:value,findNavItem=typeof value==`object`?value.findNavItem:!1;if(!el||!shouldFocus)return;let targetEl=el;if(findNavItem){let navItems=el.querySelectorAll(`[is-bng-panel], [bng-nav-item], [ng-click], [href], [bng-all-clicks], [bng-all-clicks-no-nav], [ui-sref], input, textarea, button, md-option, md-slider, md-select, md-checkbox`);navItems&&navItems.length>0&&(targetEl=navItems[0])}targetEl.focus();let blur$1=()=>{targetEl.classList.remove(`focus-visible`),targetEl.removeEventListener(`blur`,blur$1)};targetEl.addEventListener(`blur`,blur$1),targetEl.classList.add(`focus-visible`)}),elems=new WeakMap,curHorizontal=0,curVertical=0;function updateGE(horizontal=0,vertical=0){curHorizontal=horizontal,curVertical=vertical,bngApi.engineLua(`scenetree.OnlyGui:setFrustumCameraCenterOffset(Point2F(${horizontal}, ${vertical}))`)}var moveSpeed=1,smoothingUpdate;function updateGEsmooth(horizontal=0,vertical=0){if(smoothingUpdate){smoothingUpdate(horizontal,vertical);return}let dirH=1,dirV=1;function setDir(){dirH=horizontal>=curHorizontal?1:-1,dirV=vertical>=curVertical?1:-1}setDir(),smoothingUpdate=(h$1=0,v=0)=>{horizontal=h$1,vertical=v,setDir()},window.requestAnimationFrame(function(ms){let speed=moveSpeed/1e3,movH=curHorizontal,movV=curVertical,lastTime=ms,smoother=0;window.requestAnimationFrame(function step(ms$1){if(curHorizontal===horizontal&&curVertical===vertical){smoothingUpdate=null;return}smoother+=(ms$1-lastTime-smoother)*.02,lastTime=ms$1;let moveDelta=smoother*speed;movH+=moveDelta*dirH,movV+=moveDelta*dirV,(dirH>0&&movH>horizontal||dirH<0&&movH0&&movV>vertical||dirV<0&&movV{let updateDebounce=debounce(updateFrustum,50),updateWrapper=()=>updateDebounce(),resizeObserver=new ResizeObserver(updateWrapper);resizeObserver.observe(el),elems.set(el,{updateFrustum:updateDebounce,destroy:()=>{resizeObserver.disconnect(),window.removeEventListener(`resize`,updateWrapper),elems.delete(el),updateDebounce(0,0)}}),window.addEventListener(`resize`,updateWrapper);let curDirection=binding.arg||`left`,curSmooth=binding.modifiers.smooth,curState=binding.value===void 0?!0:!!binding.value;function updateFrustum(direction$1,enabled,smooth){direction$1||=curDirection,[`left`,`right`,`up`,`down`].includes(direction$1)?curDirection=direction$1:(console.error(`Frustum mover only supports left/right/up/down directions`),enabled=!1),typeof enabled!=`boolean`&&(enabled=curState),curState=enabled,typeof smooth!=`boolean`&&(smooth=curSmooth),curSmooth=smooth;let updater=smooth?updateGEsmooth:updateGE;if(!enabled){updater();return}let side=direction$1===`left`||direction$1===`right`?`width`:`height`,screenSize=window.screen[side],movePower=el.getBoundingClientRect()[side]/screenSize*power;movePower<.001?movePower=0:(direction$1===`left`||direction$1===`down`)&&(movePower=-movePower),updater(direction$1===`left`||direction$1===`right`?movePower:0,direction$1===`up`||direction$1===`down`?movePower:0)}},updated:(el,binding)=>{let itm=elems.get(el);itm&&itm.updateFrustum(binding.arg,!!binding.value,!!binding.modifiers.smooth)},unmounted:(el,binding)=>{let itm=elems.get(el);itm&&itm.destroy()}},highlighter=[``,``],rgxSanitize=str=>str.replace(/[\\[]\?:.\*\+\-]/g,`\\$1`),BngHighlighter_default=(el,binding,vnode,prevVnode)=>{if(vnode.children.length!==1||vnode.children[0].type.toString()!==`Symbol(v-txt)`){el.__highlightwarned||(el.__highlightwarned=!0,console.warn(`Only a single inner text v-node supported`,el));return}let res=vnode.children[0].children.replace(//g,`>`),highlight=binding.value;if(highlight){let rgx;if(highlight instanceof RegExp)highlight.test(res)&&(rgx=highlight);else{let searchCase=str=>binding.modifiers.case?str:str.toLowerCase(),searchSource=searchCase(res),checkString=str=>searchSource.indexOf(str)>-1,buildRegexp=str=>RegExp(`(${str})`,`gm`+(binding.modifiers.case?``:`i`));if(typeof highlight==`object`&&Array.isArray(highlight)){let found=[];for(let str of highlight)str&&(str=searchCase(String(str)),checkString(str)&&found.push(str));found.length>0&&(rgx=buildRegexp(found.map(str=>rgxSanitize(str)).join(`|`)))}else{let str=searchCase(String(highlight));checkString(str)&&(rgx=buildRegexp(rgxSanitize(str)))}}rgx&&(res=res.replace(rgx,`${highlighter[0]}$1${highlighter[1]}`))}el.innerHTML!==res&&(el.innerHTML=res)},ExecQueue=class{resolution={rejectThis:`rejectThis`,rejectOthers:`rejectOthers`,resolveThis:`resolveThis`,resolveOthers:`resolveOthers`,replaceWithReject:`replaceWithReject`,replaceWithResolve:`replaceWithResolve`,merge:`merge`};_queue=[];_processing=!1;_tick=0;_tickFunc=nextTick;_runningCount=0;_concurrency=1;constructor(tick=0,concurrency=1){this.tick=tick,this.concurrency=concurrency}get tick(){return this._tick}set tick(val){typeof val!=`number`&&(val=0),this._tick=val,this._tickFunc=val===0?func=>nextTick(func.bind(this)):func=>setTimeout(func.bind(this),this._tick)}get concurrency(){return this._concurrency}set concurrency(val){(typeof val!=`number`||val<1)&&(val=1),this._concurrency=val}shuffle(){this._shuffle=!0}async process(){if(!(this._processing||this._queue.length===0))for(this._processing=!0,this._shuffle&&=(this._queue=this._queue.sort(()=>Math.random()-.5),!1);this._runningCount0;){let item=this._queue.shift();if(!item)break;item.running=!0,this._runningCount++,this._processItem(item)}}async _processItem(item){try{let result=await item.func(...item.args);item.resolves?.forEach(resolve$1=>resolve$1?.(result))}catch(err){item.rejects.length>0?item.rejects?.forEach(reject=>reject?.(err)):console.error(err)}finally{this._runningCount--,this._tickFunc(()=>{this._processing=!1,this.process()})}}enqueue(name,func,args=[],conflicts={},resolve$1=null,reject=null){if(typeof conflicts==`object`&&Object.keys(conflicts).length>0)for(let i=this._queue.length-1;i>=0;i--){let item=this._queue[i];if(item.name in conflicts)switch(conflicts[item.name]){case this.resolution.merge:resolve$1&&item.resolves.push(resolve$1),reject&&item.rejects.push(reject);return;default:case this.resolution.rejectThis:reject?.(Error(`Function ${item.name} is rejected due to conflict`));return;case this.resolution.resolveThis:resolve$1?.();return;case this.resolution.rejectOthers:item.running||(item.rejects?.forEach(reject$1=>reject$1?.(Error(`Function ${item.name} is rejected due to conflict`))),this._queue.splice(i,1));break;case this.resolution.resolveOthers:case this.resolution.replaceWithResolve:item.running||(item.resolves?.forEach(resolve$2=>resolve$2?.()),this._queue.splice(i,1));break;case this.resolution.replaceWithReject:item.rejects?.forEach(reject$1=>reject$1?.(Error(`Function ${item.name} is replaced`))),this._queue.splice(i,1);break}}this._queue.push({name,func,args,resolves:[resolve$1],rejects:[reject]}),this._processing||(this._processing=!0,this._tickFunc(()=>{this._processing=!1,this.process()}))}promise(name,func,args=[],conflicts={}){return new Promise((resolve$1,reject)=>this.enqueue(name,func,args,conflicts,resolve$1,reject))}wrap(name,func,conflicts={}){return async(...args)=>await this.promise(name,func,args,conflicts)}},MAX_SIZE=500,OVERSIZE_LIMIT=100,CONCURRENCY_LIMIT=20,QUEUE_INTERVAL$1=0,OBS_ID=`__bngLazyImage`,cache=new Map,queue=new ExecQueue(QUEUE_INTERVAL$1,CONCURRENCY_LIMIT),observer$1=new IntersectionObserver(entries=>{for(let entry of entries)if(entry.isIntersecting){observer$1.unobserve(entry.target);let data=entry.target[OBS_ID];data.observed&&(data.observed=!1,queue.shuffle(),process(entry.target,data))}}),loadImage=url=>new Promise((resolve$1,reject)=>{let img=new Image;img.onload=async()=>{try{if(cache.sizeMAX_SIZE||img.height>MAX_SIZE)){let ratio=img.width/img.height,width$1,height$1;img.width>img.height?(width$1=MAX_SIZE,height$1=MAX_SIZE/ratio):(height$1=MAX_SIZE,width$1=MAX_SIZE*ratio);let cvs=new OffscreenCanvas(width$1,height$1);cvs.getContext(`2d`).drawImage(img,0,0,width$1,height$1);let bmp=await createImageBitmap(cvs);cache.set(img.src,{url,bmp})}}catch(err){reject(err)}resolve$1({url})},img.onerror=()=>reject(Error(`Failed to load image`)),img.src=url});function process(el,data){let{url,callback}=data,apply$1=imgData=>callback(el,imgData.url,imgData.bmp);if(cache.has(url)){apply$1(cache.get(url));return}apply$1(emptyImage),queue.enqueue(url,loadImage,[url],{url:queue.resolution.merge},data$1=>{apply$1(data$1)},err=>{logger_default.error(err),apply$1(url)})}function update$2(el,{arg,value}){let data={url:void 0,target:`src`,callback:void 0};if(typeof value==`string`)data.url=value;else if(typeof value==`object`&&!Array.isArray(value)&&value.url){if(data.url=value.url,data.target=value.target,data.callback=typeof value.callback==`function`?value.callback:void 0,!data.url||!data.target&&!data.callback)return}else return;if(el[OBS_ID]){let old=el[OBS_ID];if(old.observed&&observer$1.unobserve(el),old.url===data.url&&old.target===data.target&&old.callback===data.callback)return}el[OBS_ID]=data,arg===`observe`?(data.observed=!0,observer$1.observe(el)):process(el,data)}var BngLazyImage_default={mounted:update$2,updated:update$2,unmounted(el){el[OBS_ID]&&(el[OBS_ID].observed&&observer$1.unobserve(el),delete el[OBS_ID])}},elms$1=new Map,observer=new ResizeObserver(observed$1);function observed$1(entries){for(let entry of entries)elms$1.has(entry.target)?update$1(entry.target):observer.unobserve(entry.target)}function update$1(elm,data=void 0){if(data||=elms$1.get(elm),data)if(isVisibleFast(elm)){let screen$1={width:window.innerWidth,height:window.innerHeight,scrollX:window.scrollX,scrollY:window.scrollY},rect=elm.getBoundingClientRect(),metrics={x:rect.left+screen$1.scrollX,y:rect.top+screen$1.scrollY,width:rect.width,height:rect.height};data.set(data.id,metrics.x/screen$1.width,metrics.y/screen$1.height,metrics.width/screen$1.width,metrics.height/screen$1.height)}else data.reset(data.id)}var UINAV_PROP=`__BngOnUiNav`,_handlerToElement=handler$1=>{let element;switch(typeof handler$1){case`string`:element=document.querySelectorAll(handler$1)[0];break;case`object`:element=handler$1;break}return element instanceof HTMLElement&&element},_generateSignature=(vnode,eventNames,modifiers)=>`${UINAV_PROP}[${vnode.ctx.uid}]:`+(typeof eventNames==`string`?eventNames.split(`,`):eventNames).sort().join(`,`)+[``,...Object.keys(modifiers)].sort().join(`.`),_normalizedEvents=eventNames=>eventNames===`*`?[]:eventNames.split(`,`),_getDirData=(element,signature)=>element[UINAV_PROP]?.find(dir=>dir.signature===signature);function setup$2(data,element,vnode){if(data.modifiers.asMouse){if(data.eventNames.find(name=>!isOnOffEvent(name))){window.BNG_Logger&&window.BNG_Logger.error(`UINav directive asMouse modifier is only supported for on/off type events`,element);return}setupAsMouse(data,vnode)}typeof data.handler==`function`&&(applyUiNav(data,element),applyTracker(data,element))}function setupAsMouse(data,vnode){let handlerElement=_handlerToElement(data.handler);handlerElement&&(vnode={el:handlerElement});let eventFirer$1=vnode.ctx?.exposed?.fireEvent||eventDispatcherForElement(vnode.el),checkElementDisabled=vnode.ctx?.exposed?.getDisabledState||(()=>vnode.el.hasAttribute(`disabled`));delete data.modifiers.down,delete data.modifiers.up,data.mousedownActive=!1,data.handler=({detail})=>{if(checkElementDisabled())return;let fromControllerMarker={fromController:detail};return detail.value?(eventFirer$1(`mousedown`,fromControllerMarker),data.mousedownActive=!0):(eventFirer$1(`mouseup`,fromControllerMarker),data.mousedownActive&&(data.mousedownActive=!1,eventFirer$1(`click`,fromControllerMarker))),!!data.modifiers.bubble}}function applyTracker(data,element){let uiNavTracker=useUINavTracker();data.modifiers.focusRequired?(element.addEventListener(`focusin`,evt=>{let prevDirs=evt.relatedTarget?.[UINAV_PROP];if(prevDirs)for(let dir of prevDirs)dir.modifiers.focusRequired&&(dir.tracked.forEach(name=>uiNavTracker.removeEvent(name,dir.signature,evt.relatedTarget)),dir.tracked=[]);let cur=_getDirData(element,data.signature);cur&&(cur.tracked.lengthuiNavTracker.updateEvent(name,cur.signature,element,{active:cur.modifiers.active,nogroup:cur.modifiers.nogroup})),cur.tracked=[...cur.eventNames]))}),element.addEventListener(`focusout`,evt=>{let cur=_getDirData(element,data.signature);if(!cur||cur.tracked.length>0)return;let nextDirs=evt.relatedTarget?.[UINAV_PROP];(!nextDirs||!nextDirs.some(directive=>directive.modifiers.focusRequired))&&(cur.tracked.forEach(name=>uiNavTracker.removeEvent(name,cur.signature,element)),cur.tracked=[])})):(data.eventNames.forEach(name=>uiNavTracker.updateEvent(name,data.signature,element,{active:data.modifiers.active,nogroup:data.modifiers.nogroup})),data.tracked=[...data.eventNames])}function applyUiNav(data,element){let valueChecker;data.modifiers.down?valueChecker=checkOn:data.modifiers.up?valueChecker=0:!data.modifiers.asMouse&&!data.eventNames.find(name=>!isOnOffEvent(name))&&(valueChecker=checkOn),data.uiNavHandler=handlers_default.add(element,{name:name=>data.eventNames.includes(name),value:valueChecker,modified:data.modifiers.modified||!1,focusRequired:data.modifiers.focusRequired?element:void 0},data.handler),element.setAttribute(UI_EVENT_ATTR,``)}function mounted$1(element,{arg:eventNames,value:handler$1,modifiers},vnode){modifiers||={};let storage=element[UINAV_PROP]||(element[UINAV_PROP]=[]),signature=_generateSignature(vnode,eventNames,modifiers),data=storage.find(dir=>dir.signature===signature);data?window.BNG_Logger&&window.BNG_Logger.error(`Conflicting vBngOnUiNav directive on element`,element):(data={signature,eventNames:_normalizedEvents(eventNames),modifiers,handler:handler$1,uiNavHandler:null,mousedownActive:!1,tracked:[]},storage.push(data)),setup$2(data,element,vnode)}function updated$1(element,{arg:eventNames,value:handler$1,modifiers},vnode){modifiers||={};let data=_getDirData(element,_generateSignature(vnode,eventNames,modifiers));if(!data)return;typeof data.uiNavHandler==`function`&&handlers_default.remove(element,data.uiNavHandler);let normalizedEvents=_normalizedEvents(eventNames),oldEvents=data.tracked.filter(name=>!normalizedEvents.includes(name));if(oldEvents.length>0){let uiNavTracker=useUINavTracker();oldEvents.forEach(name=>uiNavTracker.removeEvent(name,data.signature,element)),data.tracked=data.tracked.filter(name=>normalizedEvents.includes(name))}data.eventNames=normalizedEvents,data.modifiers=modifiers,data.handler=handler$1,data.uiNavHandler=null,setup$2(data,element,vnode)}function dispose$1(element){let storage=element[UINAV_PROP];if(!storage)return;let uiNavTracker=useUINavTracker();storage.forEach(directive=>{directive.tracked.length>0&&directive.tracked.forEach(name=>uiNavTracker.removeEvent(name,directive.signature,element)),directive.uiNavHandler&&handlers_default.remove(element,directive.uiNavHandler)}),element.removeAttribute(UI_EVENT_ATTR),delete element[UINAV_PROP]}var BngOnUiNav_default={mounted:mounted$1,updated:updated$1,beforeUnmount:dispose$1},DIRECTIONS={horizontal:{[UI_EVENTS.focus_l]:-1,[UI_EVENTS.focus_r]:1},vertical:{[UI_EVENTS.focus_d]:-1,[UI_EVENTS.focus_u]:1}},HOLD_DELAY=400,REPEAT_INTERVAL=100,ELEMENT_FLAG=`__BNG_ONUINAVFOCUS`,BngOnUiNavFocus_default={mounted:(element,binding,vnode)=>{if(!binding.value)return;let opts={direction:binding.arg||`horizontal`,repeat:!!binding.modifiers.repeat,holdDelay:HOLD_DELAY,repeatInterval:REPEAT_INTERVAL,min:-1/0,max:1/0,step:1,value:null,callback:null,...typeof binding.value==`object`?binding.value:typeof binding.value==`function`?{callback:binding.value}:{}};!opts.events&&(opts.events=DIRECTIONS[opts.direction]);function process$1(evt){let detail=evt.fromController||evt.detail;if(!detail||!(detail.name in opts.events))return;let dir=opts.events[detail.name],val;if(typeof opts.value==`function`){let cur=opts.value(),res=cur+(typeof opts.step==`function`?opts.step():opts.step)*dir;dir<0&&res0&&res>opts.max&&(res=opts.max);let precision=10**(opts.step+`.`).split(/[.,]/)[1].length;res=precision>0?Math.round(res*precision)/precision:Math.round(res),cur===res?dir=0:val=res}dir&&opts.callback&&opts.callback(dir,val)}let dirUINav={arg:Object.keys(opts.events).join(`,`),modifiers:{focusRequired:!0,asMouse:!0}},dirClick={value:{clickCallback:process$1,holdCallback:opts.repeat?process$1:void 0,holdDelay:HOLD_DELAY,repeatInterval:REPEAT_INTERVAL}};BngOnUiNav_default.mounted(element,dirUINav,vnode),BngClick_default.mounted(element,dirClick,vnode),element[ELEMENT_FLAG]=!0},beforeUnmount:element=>{element[ELEMENT_FLAG]&&(BngClick_default.beforeUnmount(element),BngOnUiNav_default.beforeUnmount(element))}},DEFAULT_OPTS={intiallyOpen:!1,navEventToOpen:UI_EVENTS.ok,navEventToClose:UI_EVENTS.back},min=Math.min,max=Math.max,round$1=Math.round,floor=Math.floor,createCoords=v=>({x:v,y:v}),oppositeSideMap={left:`right`,right:`left`,bottom:`top`,top:`bottom`},oppositeAlignmentMap={start:`end`,end:`start`};function clamp$1(start,value,end){return max(start,min(value,end))}function evaluate(value,param){return typeof value==`function`?value(param):value}function getSide(placement){return placement.split(`-`)[0]}function getAlignment(placement){return placement.split(`-`)[1]}function getOppositeAxis(axis){return axis===`x`?`y`:`x`}function getAxisLength(axis){return axis===`y`?`height`:`width`}var yAxisSides=new Set([`top`,`bottom`]);function getSideAxis(placement){return yAxisSides.has(getSide(placement))?`y`:`x`}function getAlignmentAxis(placement){return getOppositeAxis(getSideAxis(placement))}function getAlignmentSides(placement,rects,rtl){rtl===void 0&&(rtl=!1);let alignment=getAlignment(placement),alignmentAxis=getAlignmentAxis(placement),length=getAxisLength(alignmentAxis),mainAlignmentSide=alignmentAxis===`x`?alignment===(rtl?`end`:`start`)?`right`:`left`:alignment===`start`?`bottom`:`top`;return rects.reference[length]>rects.floating[length]&&(mainAlignmentSide=getOppositePlacement(mainAlignmentSide)),[mainAlignmentSide,getOppositePlacement(mainAlignmentSide)]}function getExpandedPlacements(placement){let oppositePlacement=getOppositePlacement(placement);return[getOppositeAlignmentPlacement(placement),oppositePlacement,getOppositeAlignmentPlacement(oppositePlacement)]}function getOppositeAlignmentPlacement(placement){return placement.replace(/start|end/g,alignment=>oppositeAlignmentMap[alignment])}var lrPlacement=[`left`,`right`],rlPlacement=[`right`,`left`],tbPlacement=[`top`,`bottom`],btPlacement=[`bottom`,`top`];function getSideList(side,isStart,rtl){switch(side){case`top`:case`bottom`:return rtl?isStart?rlPlacement:lrPlacement:isStart?lrPlacement:rlPlacement;case`left`:case`right`:return isStart?tbPlacement:btPlacement;default:return[]}}function getOppositeAxisPlacements(placement,flipAlignment,direction$1,rtl){let alignment=getAlignment(placement),list=getSideList(getSide(placement),direction$1===`start`,rtl);return alignment&&(list=list.map(side=>side+`-`+alignment),flipAlignment&&(list=list.concat(list.map(getOppositeAlignmentPlacement)))),list}function getOppositePlacement(placement){return placement.replace(/left|right|bottom|top/g,side=>oppositeSideMap[side])}function expandPaddingObject(padding){return{top:0,right:0,bottom:0,left:0,...padding}}function getPaddingObject(padding){return typeof padding==`number`?{top:padding,right:padding,bottom:padding,left:padding}:expandPaddingObject(padding)}function rectToClientRect(rect){let{x,y,width:width$1,height:height$1}=rect;return{width:width$1,height:height$1,top:y,left:x,right:x+width$1,bottom:y+height$1,x,y}}function computeCoordsFromPlacement(_ref,placement,rtl){let{reference,floating}=_ref,sideAxis=getSideAxis(placement),alignmentAxis=getAlignmentAxis(placement),alignLength=getAxisLength(alignmentAxis),side=getSide(placement),isVertical=sideAxis===`y`,commonX=reference.x+reference.width/2-floating.width/2,commonY=reference.y+reference.height/2-floating.height/2,commonAlign=reference[alignLength]/2-floating[alignLength]/2,coords;switch(side){case`top`:coords={x:commonX,y:reference.y-floating.height};break;case`bottom`:coords={x:commonX,y:reference.y+reference.height};break;case`right`:coords={x:reference.x+reference.width,y:commonY};break;case`left`:coords={x:reference.x-floating.width,y:commonY};break;default:coords={x:reference.x,y:reference.y}}switch(getAlignment(placement)){case`start`:coords[alignmentAxis]-=commonAlign*(rtl&&isVertical?-1:1);break;case`end`:coords[alignmentAxis]+=commonAlign*(rtl&&isVertical?-1:1);break}return coords}var computePosition$1=async(reference,floating,config)=>{let{placement=`bottom`,strategy=`absolute`,middleware=[],platform:platform$1}=config,validMiddleware=middleware.filter(Boolean),rtl=await(platform$1.isRTL==null?void 0:platform$1.isRTL(floating)),rects=await platform$1.getElementRects({reference,floating,strategy}),{x,y}=computeCoordsFromPlacement(rects,placement,rtl),statefulPlacement=placement,middlewareData={},resetCount=0;for(let i=0;i({name:`arrow`,options,async fn(state){let{x,y,placement,rects,platform:platform$1,elements,middlewareData}=state,{element,padding=0}=evaluate(options,state)||{};if(element==null)return{};let paddingObject=getPaddingObject(padding),coords={x,y},axis=getAlignmentAxis(placement),length=getAxisLength(axis),arrowDimensions=await platform$1.getDimensions(element),isYAxis=axis===`y`,minProp=isYAxis?`top`:`left`,maxProp=isYAxis?`bottom`:`right`,clientProp=isYAxis?`clientHeight`:`clientWidth`,endDiff=rects.reference[length]+rects.reference[axis]-coords[axis]-rects.floating[length],startDiff=coords[axis]-rects.reference[axis],arrowOffsetParent=await(platform$1.getOffsetParent==null?void 0:platform$1.getOffsetParent(element)),clientSize=arrowOffsetParent?arrowOffsetParent[clientProp]:0;(!clientSize||!await(platform$1.isElement==null?void 0:platform$1.isElement(arrowOffsetParent)))&&(clientSize=elements.floating[clientProp]||rects.floating[length]);let centerToReference=endDiff/2-startDiff/2,largestPossiblePadding=clientSize/2-arrowDimensions[length]/2-1,minPadding=min(paddingObject[minProp],largestPossiblePadding),maxPadding=min(paddingObject[maxProp],largestPossiblePadding),min$1=minPadding,max$1=clientSize-arrowDimensions[length]-maxPadding,center=clientSize/2-arrowDimensions[length]/2+centerToReference,offset$2=clamp$1(min$1,center,max$1),shouldAddOffset=!middlewareData.arrow&&getAlignment(placement)!=null&¢er!==offset$2&&rects.reference[length]/2-(centerside$1<=0)){var _middlewareData$flip2,_overflowsData$filter;let nextIndex=(middlewareData.flip?.index||0)+1,nextPlacement=placements$1[nextIndex];if(nextPlacement&&(!(checkCrossAxis===`alignment`&&initialSideAxis!==getSideAxis(nextPlacement))||overflowsData.every(d=>getSideAxis(d.placement)===initialSideAxis?d.overflows[0]>0:!0)))return{data:{index:nextIndex,overflows:overflowsData},reset:{placement:nextPlacement}};let resetPlacement=overflowsData.filter(d=>d.overflows[0]<=0).sort((a$1,b)=>a$1.overflows[1]-b.overflows[1])[0]?.placement;if(!resetPlacement)switch(fallbackStrategy){case`bestFit`:{var _overflowsData$filter2;let placement$1=overflowsData.filter(d=>{if(hasFallbackAxisSideDirection){let currentSideAxis=getSideAxis(d.placement);return currentSideAxis===initialSideAxis||currentSideAxis===`y`}return!0}).map(d=>[d.placement,d.overflows.filter(overflow$1=>overflow$1>0).reduce((acc,overflow$1)=>acc+overflow$1,0)]).sort((a$1,b)=>a$1[1]-b[1])[0]?.[0];placement$1&&(resetPlacement=placement$1);break}case`initialPlacement`:resetPlacement=initialPlacement;break}if(placement!==resetPlacement)return{reset:{placement:resetPlacement}}}return{}}}},originSides=new Set([`left`,`top`]);async function convertValueToCoords(state,options){let{placement,platform:platform$1,elements}=state,rtl=await(platform$1.isRTL==null?void 0:platform$1.isRTL(elements.floating)),side=getSide(placement),alignment=getAlignment(placement),isVertical=getSideAxis(placement)===`y`,mainAxisMulti=originSides.has(side)?-1:1,crossAxisMulti=rtl&&isVertical?-1:1,rawValue=evaluate(options,state),{mainAxis,crossAxis,alignmentAxis}=typeof rawValue==`number`?{mainAxis:rawValue,crossAxis:0,alignmentAxis:null}:{mainAxis:rawValue.mainAxis||0,crossAxis:rawValue.crossAxis||0,alignmentAxis:rawValue.alignmentAxis};return alignment&&typeof alignmentAxis==`number`&&(crossAxis=alignment===`end`?alignmentAxis*-1:alignmentAxis),isVertical?{x:crossAxis*crossAxisMulti,y:mainAxis*mainAxisMulti}:{x:mainAxis*mainAxisMulti,y:crossAxis*crossAxisMulti}}var offset$1=function(options){return options===void 0&&(options=0),{name:`offset`,options,async fn(state){var _middlewareData$offse,_middlewareData$arrow;let{x,y,placement,middlewareData}=state,diffCoords=await convertValueToCoords(state,options);return placement===middlewareData.offset?.placement&&(_middlewareData$arrow=middlewareData.arrow)!=null&&_middlewareData$arrow.alignmentOffset?{}:{x:x+diffCoords.x,y:y+diffCoords.y,data:{...diffCoords,placement}}}}},shift$1=function(options){return options===void 0&&(options={}),{name:`shift`,options,async fn(state){let{x,y,placement}=state,{mainAxis:checkMainAxis=!0,crossAxis:checkCrossAxis=!1,limiter={fn:_ref=>{let{x:x$1,y:y$1}=_ref;return{x:x$1,y:y$1}}},...detectOverflowOptions}=evaluate(options,state),coords={x,y},overflow=await detectOverflow$1(state,detectOverflowOptions),crossAxis=getSideAxis(getSide(placement)),mainAxis=getOppositeAxis(crossAxis),mainAxisCoord=coords[mainAxis],crossAxisCoord=coords[crossAxis];if(checkMainAxis){let minSide=mainAxis===`y`?`top`:`left`,maxSide=mainAxis===`y`?`bottom`:`right`,min$1=mainAxisCoord+overflow[minSide],max$1=mainAxisCoord-overflow[maxSide];mainAxisCoord=clamp$1(min$1,mainAxisCoord,max$1)}if(checkCrossAxis){let minSide=crossAxis===`y`?`top`:`left`,maxSide=crossAxis===`y`?`bottom`:`right`,min$1=crossAxisCoord+overflow[minSide],max$1=crossAxisCoord-overflow[maxSide];crossAxisCoord=clamp$1(min$1,crossAxisCoord,max$1)}let limitedCoords=limiter.fn({...state,[mainAxis]:mainAxisCoord,[crossAxis]:crossAxisCoord});return{...limitedCoords,data:{x:limitedCoords.x-x,y:limitedCoords.y-y,enabled:{[mainAxis]:checkMainAxis,[crossAxis]:checkCrossAxis}}}}}};function hasWindow(){return typeof window<`u`}function getNodeName(node){return isNode(node)?(node.nodeName||``).toLowerCase():`#document`}function getWindow(node){var _node$ownerDocument;return(node==null||(_node$ownerDocument=node.ownerDocument)==null?void 0:_node$ownerDocument.defaultView)||window}function getDocumentElement(node){var _ref;return((isNode(node)?node.ownerDocument:node.document)||window.document)?.documentElement}function isNode(value){return hasWindow()?value instanceof Node||value instanceof getWindow(value).Node:!1}function isElement(value){return hasWindow()?value instanceof Element||value instanceof getWindow(value).Element:!1}function isHTMLElement(value){return hasWindow()?value instanceof HTMLElement||value instanceof getWindow(value).HTMLElement:!1}function isShadowRoot(value){return!hasWindow()||typeof ShadowRoot>`u`?!1:value instanceof ShadowRoot||value instanceof getWindow(value).ShadowRoot}var invalidOverflowDisplayValues=new Set([`inline`,`contents`]);function isOverflowElement(element){let{overflow,overflowX,overflowY,display}=getComputedStyle$1(element);return/auto|scroll|overlay|hidden|clip/.test(overflow+overflowY+overflowX)&&!invalidOverflowDisplayValues.has(display)}var tableElements=new Set([`table`,`td`,`th`]);function isTableElement(element){return tableElements.has(getNodeName(element))}var topLayerSelectors=[`:popover-open`,`:modal`];function isTopLayer(element){return topLayerSelectors.some(selector=>{try{return element.matches(selector)}catch{return!1}})}var transformProperties=[`transform`,`translate`,`scale`,`rotate`,`perspective`],willChangeValues=[`transform`,`translate`,`scale`,`rotate`,`perspective`,`filter`],containValues=[`paint`,`layout`,`strict`,`content`];function isContainingBlock(elementOrCss){let webkit=isWebKit(),css=isElement(elementOrCss)?getComputedStyle$1(elementOrCss):elementOrCss;return transformProperties.some(value=>css[value]?css[value]!==`none`:!1)||(css.containerType?css.containerType!==`normal`:!1)||!webkit&&(css.backdropFilter?css.backdropFilter!==`none`:!1)||!webkit&&(css.filter?css.filter!==`none`:!1)||willChangeValues.some(value=>(css.willChange||``).includes(value))||containValues.some(value=>(css.contain||``).includes(value))}function getContainingBlock(element){let currentNode=getParentNode(element);for(;isHTMLElement(currentNode)&&!isLastTraversableNode(currentNode);){if(isContainingBlock(currentNode))return currentNode;if(isTopLayer(currentNode))return null;currentNode=getParentNode(currentNode)}return null}function isWebKit(){return typeof CSS>`u`||!CSS.supports?!1:CSS.supports(`-webkit-backdrop-filter`,`none`)}var lastTraversableNodeNames=new Set([`html`,`body`,`#document`]);function isLastTraversableNode(node){return lastTraversableNodeNames.has(getNodeName(node))}function getComputedStyle$1(element){return getWindow(element).getComputedStyle(element)}function getNodeScroll(element){return isElement(element)?{scrollLeft:element.scrollLeft,scrollTop:element.scrollTop}:{scrollLeft:element.scrollX,scrollTop:element.scrollY}}function getParentNode(node){if(getNodeName(node)===`html`)return node;let result=node.assignedSlot||node.parentNode||isShadowRoot(node)&&node.host||getDocumentElement(node);return isShadowRoot(result)?result.host:result}function getNearestOverflowAncestor(node){let parentNode=getParentNode(node);return isLastTraversableNode(parentNode)?node.ownerDocument?node.ownerDocument.body:node.body:isHTMLElement(parentNode)&&isOverflowElement(parentNode)?parentNode:getNearestOverflowAncestor(parentNode)}function getOverflowAncestors(node,list,traverseIframes){var _node$ownerDocument2;list===void 0&&(list=[]),traverseIframes===void 0&&(traverseIframes=!0);let scrollableAncestor=getNearestOverflowAncestor(node),isBody=scrollableAncestor===node.ownerDocument?.body,win=getWindow(scrollableAncestor);if(isBody){let frameElement=getFrameElement(win);return list.concat(win,win.visualViewport||[],isOverflowElement(scrollableAncestor)?scrollableAncestor:[],frameElement&&traverseIframes?getOverflowAncestors(frameElement):[])}return list.concat(scrollableAncestor,getOverflowAncestors(scrollableAncestor,[],traverseIframes))}function getFrameElement(win){return win.parent&&Object.getPrototypeOf(win.parent)?win.frameElement:null}function getCssDimensions(element){let css=getComputedStyle$1(element),width$1=parseFloat(css.width)||0,height$1=parseFloat(css.height)||0,hasOffset=isHTMLElement(element),offsetWidth=hasOffset?element.offsetWidth:width$1,offsetHeight=hasOffset?element.offsetHeight:height$1,shouldFallback=round$1(width$1)!==offsetWidth||round$1(height$1)!==offsetHeight;return shouldFallback&&(width$1=offsetWidth,height$1=offsetHeight),{width:width$1,height:height$1,$:shouldFallback}}function unwrapElement$1(element){return isElement(element)?element:element.contextElement}function getScale(element){let domElement=unwrapElement$1(element);if(!isHTMLElement(domElement))return createCoords(1);let rect=domElement.getBoundingClientRect(),{width:width$1,height:height$1,$}=getCssDimensions(domElement),x=($?round$1(rect.width):rect.width)/width$1,y=($?round$1(rect.height):rect.height)/height$1;return(!x||!Number.isFinite(x))&&(x=1),(!y||!Number.isFinite(y))&&(y=1),{x,y}}var noOffsets=createCoords(0);function getVisualOffsets(element){let win=getWindow(element);return!isWebKit()||!win.visualViewport?noOffsets:{x:win.visualViewport.offsetLeft,y:win.visualViewport.offsetTop}}function shouldAddVisualOffsets(element,isFixed,floatingOffsetParent){return isFixed===void 0&&(isFixed=!1),!floatingOffsetParent||isFixed&&floatingOffsetParent!==getWindow(element)?!1:isFixed}function getBoundingClientRect(element,includeScale,isFixedStrategy,offsetParent){includeScale===void 0&&(includeScale=!1),isFixedStrategy===void 0&&(isFixedStrategy=!1);let clientRect=element.getBoundingClientRect(),domElement=unwrapElement$1(element),scale=createCoords(1);includeScale&&(offsetParent?isElement(offsetParent)&&(scale=getScale(offsetParent)):scale=getScale(element));let visualOffsets=shouldAddVisualOffsets(domElement,isFixedStrategy,offsetParent)?getVisualOffsets(domElement):createCoords(0),x=(clientRect.left+visualOffsets.x)/scale.x,y=(clientRect.top+visualOffsets.y)/scale.y,width$1=clientRect.width/scale.x,height$1=clientRect.height/scale.y;if(domElement){let win=getWindow(domElement),offsetWin=offsetParent&&isElement(offsetParent)?getWindow(offsetParent):offsetParent,currentWin=win,currentIFrame=getFrameElement(currentWin);for(;currentIFrame&&offsetParent&&offsetWin!==currentWin;){let iframeScale=getScale(currentIFrame),iframeRect=currentIFrame.getBoundingClientRect(),css=getComputedStyle$1(currentIFrame),left=iframeRect.left+(currentIFrame.clientLeft+parseFloat(css.paddingLeft))*iframeScale.x,top=iframeRect.top+(currentIFrame.clientTop+parseFloat(css.paddingTop))*iframeScale.y;x*=iframeScale.x,y*=iframeScale.y,width$1*=iframeScale.x,height$1*=iframeScale.y,x+=left,y+=top,currentWin=getWindow(currentIFrame),currentIFrame=getFrameElement(currentWin)}}return rectToClientRect({width:width$1,height:height$1,x,y})}function getWindowScrollBarX(element,rect){let leftScroll=getNodeScroll(element).scrollLeft;return rect?rect.left+leftScroll:getBoundingClientRect(getDocumentElement(element)).left+leftScroll}function getHTMLOffset(documentElement,scroll$1){let htmlRect=documentElement.getBoundingClientRect();return{x:htmlRect.left+scroll$1.scrollLeft-getWindowScrollBarX(documentElement,htmlRect),y:htmlRect.top+scroll$1.scrollTop}}function convertOffsetParentRelativeRectToViewportRelativeRect(_ref){let{elements,rect,offsetParent,strategy}=_ref,isFixed=strategy===`fixed`,documentElement=getDocumentElement(offsetParent),topLayer=elements?isTopLayer(elements.floating):!1;if(offsetParent===documentElement||topLayer&&isFixed)return rect;let scroll$1={scrollLeft:0,scrollTop:0},scale=createCoords(1),offsets=createCoords(0),isOffsetParentAnElement=isHTMLElement(offsetParent);if((isOffsetParentAnElement||!isOffsetParentAnElement&&!isFixed)&&((getNodeName(offsetParent)!==`body`||isOverflowElement(documentElement))&&(scroll$1=getNodeScroll(offsetParent)),isHTMLElement(offsetParent))){let offsetRect=getBoundingClientRect(offsetParent);scale=getScale(offsetParent),offsets.x=offsetRect.x+offsetParent.clientLeft,offsets.y=offsetRect.y+offsetParent.clientTop}let htmlOffset=documentElement&&!isOffsetParentAnElement&&!isFixed?getHTMLOffset(documentElement,scroll$1):createCoords(0);return{width:rect.width*scale.x,height:rect.height*scale.y,x:rect.x*scale.x-scroll$1.scrollLeft*scale.x+offsets.x+htmlOffset.x,y:rect.y*scale.y-scroll$1.scrollTop*scale.y+offsets.y+htmlOffset.y}}function getClientRects(element){return Array.from(element.getClientRects())}function getDocumentRect(element){let html=getDocumentElement(element),scroll$1=getNodeScroll(element),body=element.ownerDocument.body,width$1=max(html.scrollWidth,html.clientWidth,body.scrollWidth,body.clientWidth),height$1=max(html.scrollHeight,html.clientHeight,body.scrollHeight,body.clientHeight),x=-scroll$1.scrollLeft+getWindowScrollBarX(element),y=-scroll$1.scrollTop;return getComputedStyle$1(body).direction===`rtl`&&(x+=max(html.clientWidth,body.clientWidth)-width$1),{width:width$1,height:height$1,x,y}}var SCROLLBAR_MAX=25;function getViewportRect(element,strategy){let win=getWindow(element),html=getDocumentElement(element),visualViewport=win.visualViewport,width$1=html.clientWidth,height$1=html.clientHeight,x=0,y=0;if(visualViewport){width$1=visualViewport.width,height$1=visualViewport.height;let visualViewportBased=isWebKit();(!visualViewportBased||visualViewportBased&&strategy===`fixed`)&&(x=visualViewport.offsetLeft,y=visualViewport.offsetTop)}let windowScrollbarX=getWindowScrollBarX(html);if(windowScrollbarX<=0){let doc$1=html.ownerDocument,body=doc$1.body,bodyStyles=getComputedStyle(body),bodyMarginInline=doc$1.compatMode===`CSS1Compat`&&parseFloat(bodyStyles.marginLeft)+parseFloat(bodyStyles.marginRight)||0,clippingStableScrollbarWidth=Math.abs(html.clientWidth-body.clientWidth-bodyMarginInline);clippingStableScrollbarWidth<=SCROLLBAR_MAX&&(width$1-=clippingStableScrollbarWidth)}else windowScrollbarX<=SCROLLBAR_MAX&&(width$1+=windowScrollbarX);return{width:width$1,height:height$1,x,y}}var absoluteOrFixed=new Set([`absolute`,`fixed`]);function getInnerBoundingClientRect(element,strategy){let clientRect=getBoundingClientRect(element,!0,strategy===`fixed`),top=clientRect.top+element.clientTop,left=clientRect.left+element.clientLeft,scale=isHTMLElement(element)?getScale(element):createCoords(1);return{width:element.clientWidth*scale.x,height:element.clientHeight*scale.y,x:left*scale.x,y:top*scale.y}}function getClientRectFromClippingAncestor(element,clippingAncestor,strategy){let rect;if(clippingAncestor===`viewport`)rect=getViewportRect(element,strategy);else if(clippingAncestor===`document`)rect=getDocumentRect(getDocumentElement(element));else if(isElement(clippingAncestor))rect=getInnerBoundingClientRect(clippingAncestor,strategy);else{let visualOffsets=getVisualOffsets(element);rect={x:clippingAncestor.x-visualOffsets.x,y:clippingAncestor.y-visualOffsets.y,width:clippingAncestor.width,height:clippingAncestor.height}}return rectToClientRect(rect)}function hasFixedPositionAncestor(element,stopNode){let parentNode=getParentNode(element);return parentNode===stopNode||!isElement(parentNode)||isLastTraversableNode(parentNode)?!1:getComputedStyle$1(parentNode).position===`fixed`||hasFixedPositionAncestor(parentNode,stopNode)}function getClippingElementAncestors(element,cache$1){let cachedResult=cache$1.get(element);if(cachedResult)return cachedResult;let result=getOverflowAncestors(element,[],!1).filter(el=>isElement(el)&&getNodeName(el)!==`body`),currentContainingBlockComputedStyle=null,elementIsFixed=getComputedStyle$1(element).position===`fixed`,currentNode=elementIsFixed?getParentNode(element):element;for(;isElement(currentNode)&&!isLastTraversableNode(currentNode);){let computedStyle=getComputedStyle$1(currentNode),currentNodeIsContaining=isContainingBlock(currentNode);!currentNodeIsContaining&&computedStyle.position===`fixed`&&(currentContainingBlockComputedStyle=null),(elementIsFixed?!currentNodeIsContaining&&!currentContainingBlockComputedStyle:!currentNodeIsContaining&&computedStyle.position===`static`&¤tContainingBlockComputedStyle&&absoluteOrFixed.has(currentContainingBlockComputedStyle.position)||isOverflowElement(currentNode)&&!currentNodeIsContaining&&hasFixedPositionAncestor(element,currentNode))?result=result.filter(ancestor=>ancestor!==currentNode):currentContainingBlockComputedStyle=computedStyle,currentNode=getParentNode(currentNode)}return cache$1.set(element,result),result}function getClippingRect(_ref){let{element,boundary,rootBoundary,strategy}=_ref,clippingAncestors=[...boundary===`clippingAncestors`?isTopLayer(element)?[]:getClippingElementAncestors(element,this._c):[].concat(boundary),rootBoundary],firstClippingAncestor=clippingAncestors[0],clippingRect=clippingAncestors.reduce((accRect,clippingAncestor)=>{let rect=getClientRectFromClippingAncestor(element,clippingAncestor,strategy);return accRect.top=max(rect.top,accRect.top),accRect.right=min(rect.right,accRect.right),accRect.bottom=min(rect.bottom,accRect.bottom),accRect.left=max(rect.left,accRect.left),accRect},getClientRectFromClippingAncestor(element,firstClippingAncestor,strategy));return{width:clippingRect.right-clippingRect.left,height:clippingRect.bottom-clippingRect.top,x:clippingRect.left,y:clippingRect.top}}function getDimensions(element){let{width:width$1,height:height$1}=getCssDimensions(element);return{width:width$1,height:height$1}}function getRectRelativeToOffsetParent(element,offsetParent,strategy){let isOffsetParentAnElement=isHTMLElement(offsetParent),documentElement=getDocumentElement(offsetParent),isFixed=strategy===`fixed`,rect=getBoundingClientRect(element,!0,isFixed,offsetParent),scroll$1={scrollLeft:0,scrollTop:0},offsets=createCoords(0);function setLeftRTLScrollbarOffset(){offsets.x=getWindowScrollBarX(documentElement)}if(isOffsetParentAnElement||!isOffsetParentAnElement&&!isFixed)if((getNodeName(offsetParent)!==`body`||isOverflowElement(documentElement))&&(scroll$1=getNodeScroll(offsetParent)),isOffsetParentAnElement){let offsetRect=getBoundingClientRect(offsetParent,!0,isFixed,offsetParent);offsets.x=offsetRect.x+offsetParent.clientLeft,offsets.y=offsetRect.y+offsetParent.clientTop}else documentElement&&setLeftRTLScrollbarOffset();isFixed&&!isOffsetParentAnElement&&documentElement&&setLeftRTLScrollbarOffset();let htmlOffset=documentElement&&!isOffsetParentAnElement&&!isFixed?getHTMLOffset(documentElement,scroll$1):createCoords(0);return{x:rect.left+scroll$1.scrollLeft-offsets.x-htmlOffset.x,y:rect.top+scroll$1.scrollTop-offsets.y-htmlOffset.y,width:rect.width,height:rect.height}}function isStaticPositioned(element){return getComputedStyle$1(element).position===`static`}function getTrueOffsetParent(element,polyfill){if(!isHTMLElement(element)||getComputedStyle$1(element).position===`fixed`)return null;if(polyfill)return polyfill(element);let rawOffsetParent=element.offsetParent;return getDocumentElement(element)===rawOffsetParent&&(rawOffsetParent=rawOffsetParent.ownerDocument.body),rawOffsetParent}function getOffsetParent(element,polyfill){let win=getWindow(element);if(isTopLayer(element))return win;if(!isHTMLElement(element)){let svgOffsetParent=getParentNode(element);for(;svgOffsetParent&&!isLastTraversableNode(svgOffsetParent);){if(isElement(svgOffsetParent)&&!isStaticPositioned(svgOffsetParent))return svgOffsetParent;svgOffsetParent=getParentNode(svgOffsetParent)}return win}let offsetParent=getTrueOffsetParent(element,polyfill);for(;offsetParent&&isTableElement(offsetParent)&&isStaticPositioned(offsetParent);)offsetParent=getTrueOffsetParent(offsetParent,polyfill);return offsetParent&&isLastTraversableNode(offsetParent)&&isStaticPositioned(offsetParent)&&!isContainingBlock(offsetParent)?win:offsetParent||getContainingBlock(element)||win}var getElementRects=async function(data){let getOffsetParentFn=this.getOffsetParent||getOffsetParent,getDimensionsFn=this.getDimensions,floatingDimensions=await getDimensionsFn(data.floating);return{reference:getRectRelativeToOffsetParent(data.reference,await getOffsetParentFn(data.floating),data.strategy),floating:{x:0,y:0,width:floatingDimensions.width,height:floatingDimensions.height}}};function isRTL(element){return getComputedStyle$1(element).direction===`rtl`}var platform={convertOffsetParentRelativeRectToViewportRelativeRect,getDocumentElement,getClippingRect,getOffsetParent,getElementRects,getClientRects,getDimensions,getScale,isElement,isRTL};function rectsAreEqual(a$1,b){return a$1.x===b.x&&a$1.y===b.y&&a$1.width===b.width&&a$1.height===b.height}function observeMove(element,onMove){let io=null,timeoutId,root=getDocumentElement(element);function cleanup(){var _io;clearTimeout(timeoutId),(_io=io)==null||_io.disconnect(),io=null}function refresh$1(skip,threshold){skip===void 0&&(skip=!1),threshold===void 0&&(threshold=1),cleanup();let elementRectForRootMargin=element.getBoundingClientRect(),{left,top,width:width$1,height:height$1}=elementRectForRootMargin;if(skip||onMove(),!width$1||!height$1)return;let insetTop=floor(top),insetRight=floor(root.clientWidth-(left+width$1)),insetBottom=floor(root.clientHeight-(top+height$1)),insetLeft=floor(left),options={rootMargin:-insetTop+`px `+-insetRight+`px `+-insetBottom+`px `+-insetLeft+`px`,threshold:max(0,min(1,threshold))||1},isFirstUpdate=!0;function handleObserve(entries){let ratio=entries[0].intersectionRatio;if(ratio!==threshold){if(!isFirstUpdate)return refresh$1();ratio?refresh$1(!1,ratio):timeoutId=setTimeout(()=>{refresh$1(!1,1e-7)},1e3)}ratio===1&&!rectsAreEqual(elementRectForRootMargin,element.getBoundingClientRect())&&refresh$1(),isFirstUpdate=!1}try{io=new IntersectionObserver(handleObserve,{...options,root:root.ownerDocument})}catch{io=new IntersectionObserver(handleObserve,options)}io.observe(element)}return refresh$1(!0),cleanup}function autoUpdate(reference,floating,update$6,options){options===void 0&&(options={});let{ancestorScroll=!0,ancestorResize=!0,elementResize=typeof ResizeObserver==`function`,layoutShift=typeof IntersectionObserver==`function`,animationFrame=!1}=options,referenceEl=unwrapElement$1(reference),ancestors=ancestorScroll||ancestorResize?[...referenceEl?getOverflowAncestors(referenceEl):[],...getOverflowAncestors(floating)]:[];ancestors.forEach(ancestor=>{ancestorScroll&&ancestor.addEventListener(`scroll`,update$6,{passive:!0}),ancestorResize&&ancestor.addEventListener(`resize`,update$6)});let cleanupIo=referenceEl&&layoutShift?observeMove(referenceEl,update$6):null,reobserveFrame=-1,resizeObserver=null;elementResize&&(resizeObserver=new ResizeObserver(_ref=>{let[firstEntry]=_ref;firstEntry&&firstEntry.target===referenceEl&&resizeObserver&&(resizeObserver.unobserve(floating),cancelAnimationFrame(reobserveFrame),reobserveFrame=requestAnimationFrame(()=>{var _resizeObserver;(_resizeObserver=resizeObserver)==null||_resizeObserver.observe(floating)})),update$6()}),referenceEl&&!animationFrame&&resizeObserver.observe(referenceEl),resizeObserver.observe(floating));let frameId,prevRefRect=animationFrame?getBoundingClientRect(reference):null;animationFrame&&frameLoop();function frameLoop(){let nextRefRect=getBoundingClientRect(reference);prevRefRect&&!rectsAreEqual(prevRefRect,nextRefRect)&&update$6(),prevRefRect=nextRefRect,frameId=requestAnimationFrame(frameLoop)}return update$6(),()=>{var _resizeObserver2;ancestors.forEach(ancestor=>{ancestorScroll&&ancestor.removeEventListener(`scroll`,update$6),ancestorResize&&ancestor.removeEventListener(`resize`,update$6)}),cleanupIo?.(),(_resizeObserver2=resizeObserver)==null||_resizeObserver2.disconnect(),resizeObserver=null,animationFrame&&cancelAnimationFrame(frameId)}}var offset=offset$1,shift=shift$1,flip=flip$1,arrow$1=arrow$2,computePosition=(reference,floating,options)=>{let cache$1=new Map,mergedOptions={platform,...options},platformWithCache={...mergedOptions.platform,_c:cache$1};return computePosition$1(reference,floating,{...mergedOptions,platform:platformWithCache})};function isComponentPublicInstance(target){return typeof target==`object`&&!!target&&`$el`in target}function unwrapElement(target){if(isComponentPublicInstance(target)){let element=target.$el;return isNode(element)&&getNodeName(element)===`#comment`?null:element}return target}function toValue(source){return typeof source==`function`?source():unref(source)}function arrow(options){return{name:`arrow`,options,fn(args){let element=unwrapElement(toValue(options.element));return element==null?{}:arrow$1({element,padding:options.padding}).fn(args)}}}function getDPR(element){return typeof window>`u`?1:(element.ownerDocument.defaultView||window).devicePixelRatio||1}function roundByDPR(element,value){let dpr=getDPR(element);return Math.round(value*dpr)/dpr}function useFloating(reference,floating,options){options===void 0&&(options={});let whileElementsMountedOption=options.whileElementsMounted,openOption=computed(()=>{var _toValue;return toValue(options.open)??!0}),middlewareOption=computed(()=>toValue(options.middleware)),placementOption=computed(()=>{var _toValue2;return toValue(options.placement)??`bottom`}),strategyOption=computed(()=>{var _toValue3;return toValue(options.strategy)??`absolute`}),transformOption=computed(()=>{var _toValue4;return toValue(options.transform)??!0}),referenceElement=computed(()=>unwrapElement(reference.value)),floatingElement=computed(()=>unwrapElement(floating.value)),x=ref(0),y=ref(0),strategy=ref(strategyOption.value),placement=ref(placementOption.value),middlewareData=shallowRef({}),isPositioned=ref(!1),floatingStyles=computed(()=>{let initialStyles={position:strategy.value,left:`0`,top:`0`};if(!floatingElement.value)return initialStyles;let xVal=roundByDPR(floatingElement.value,x.value),yVal=roundByDPR(floatingElement.value,y.value);return transformOption.value?{...initialStyles,transform:`translate(`+xVal+`px, `+yVal+`px)`,...getDPR(floatingElement.value)>=1.5&&{willChange:`transform`}}:{position:strategy.value,left:xVal+`px`,top:yVal+`px`}}),whileElementsMountedCleanup;function update$6(){if(referenceElement.value==null||floatingElement.value==null)return;let open$1=openOption.value;computePosition(referenceElement.value,floatingElement.value,{middleware:middlewareOption.value,placement:placementOption.value,strategy:strategyOption.value}).then(position=>{x.value=position.x,y.value=position.y,strategy.value=position.strategy,placement.value=position.placement,middlewareData.value=position.middlewareData,isPositioned.value=open$1!==!1})}function cleanup(){typeof whileElementsMountedCleanup==`function`&&(whileElementsMountedCleanup(),whileElementsMountedCleanup=void 0)}function attach(){if(cleanup(),whileElementsMountedOption===void 0){update$6();return}if(referenceElement.value!=null&&floatingElement.value!=null){whileElementsMountedCleanup=whileElementsMountedOption(referenceElement.value,floatingElement.value,update$6);return}}function reset$1(){openOption.value||(isPositioned.value=!1)}return watch([middlewareOption,placementOption,strategyOption,openOption],update$6,{flush:`sync`}),watch([referenceElement,floatingElement],attach,{flush:`sync`}),watch(openOption,reset$1,{flush:`sync`}),getCurrentScope()&&onScopeDispose(cleanup),{x:shallowReadonly(x),y:shallowReadonly(y),strategy:shallowReadonly(strategy),placement:shallowReadonly(placement),middlewareData:shallowReadonly(middlewareData),isPositioned:shallowReadonly(isPositioned),floatingStyles,update:update$6}}var ARROW_POSITION={top:`bottom`,right:`left`,bottom:`top`,left:`right`};const usePopover=defineStore(`popover`,()=>{let _counter=ref(0),_currentPopover=ref(null),popovers=ref({}),currentPopover=computed(()=>_currentPopover.value),register=(name,popover,popoverPlacement=void 0,options={})=>{if(popovers.value[name])return;popovers.value[name]={element:popover,target:null,placement:popoverPlacement||`bottom`,show:!1};let popoverInstance=buildPopover(popover,toRef(popovers.value[name],`target`),toRef(popovers.value[name],`placement`),options),scope$1=effectScope(),show$1;scope$1.run(()=>{show$1=computed(()=>popovers.value[name].show)});let dispose$2=()=>{scope$1.stop(),popoverInstance.dispose()};return popovers.value[name].dispose=dispose$2,_counter.value++,{show:show$1,update:popoverInstance.update,placement:popoverInstance.placement}},bind=(popoverName,el,options)=>{let scope$1=effectScope(),hidden,isBound,popoverElement;scope$1.run(()=>{hidden=computed(()=>popovers.value[popoverName]?!popovers.value[popoverName].show:void 0),isBound=computed(()=>popovers.value[popoverName]?popovers.value[popoverName].target===el:void 0),popoverElement=computed(()=>popovers.value[popoverName]?popovers.value[popoverName].element:void 0)});let show$1=()=>{isBound.value||(popovers.value[popoverName].target=el,popovers.value[popoverName].placement=options.placement),popovers.value[popoverName].show=!0},hide$3=()=>{isBound.value&&(popovers.value[popoverName].show=!1)};return{popoverElement,hidden,isBound,show:show$1,hide:hide$3,toggle:(forceValue=void 0)=>{let doShow=forceValue;typeof doShow!=`boolean`&&(doShow=!isBound.value||!popovers.value[popoverName].show),doShow?show$1():hide$3()},isShown:()=>!!popovers.value[popoverName].show,unbind:()=>{scope$1.stop()}}},unregister=name=>{popovers.value[name]&&(popovers.value[name].dispose(),delete popovers.value[name])},isShown=name=>name in popovers.value?popovers.value[name].show:!1,show=(name,target)=>{name in popovers.value&&(popovers.value[name].show=!0,target&&(popovers.value[name].target=target),_currentPopover.value=popovers.value[name])},hide$2=name=>{name in popovers.value&&(popovers.value[name].show=!1,_currentPopover.value=null)};return{popovers,currentPopover,bind,register,unregister,isShown,show,hide:hide$2,toggle:(name,forceValue=void 0)=>{name in popovers.value&&(popovers.value[name].show=typeof forceValue==`boolean`?forceValue:!popovers.value[name].show,_currentPopover.value=popovers.value[name].show?popovers.value[name]:null)},hideAll:(startsWith=void 0)=>{let keys=Object.keys(popovers.value);startsWith&&(keys=keys.filter(name=>name.startsWith(startsWith))),keys.forEach(name=>popovers.value[name].show&&hide$2(name))},getPopover:name=>popovers.value[name],counter:computed(()=>_counter.value)}});function buildPopover(popover,reference,placementArg,options){let{floatingStyles,middlewareData,update:update$6,placement}=useFloating(reference,popover,{placement:placementArg,middleware:buildMiddleware(popover,options),whileElementsMounted:autoUpdate}),watchers$1=[];return watchers$1.push(watch(floatingStyles,async styles=>{popover.value&&await nextTick(()=>{Object.keys(styles).forEach(styleName=>popover.value.style[styleName]=styles[styleName])})})),options.arrow&&watchers$1.push(watch(middlewareData,async middlewareData$1=>{let left=middlewareData$1.arrow&&middlewareData$1.arrow.x!=null?`${middlewareData$1.arrow.x}px`:``,top=middlewareData$1.arrow&&middlewareData$1.arrow.y!=null?`${middlewareData$1.arrow.y}px`:``,arrowSide=ARROW_POSITION[middlewareData$1.offset.placement.split(`-`)[0]];await nextTick(()=>{applyStyles(options.arrow.value,{left,top,right:``,bottom:``,[arrowSide]:`-${options.arrow.value.offsetWidth/2}px`})})})),{placement,update:update$6,dispose:()=>{watchers$1.forEach(unwatch=>unwatch())}}}var arrowOffset=options=>({name:`arrowOffset`,options,fn({...state}){let arrOffset=Math.sqrt(2*options.element.value.offsetWidth**2)/2,side=state.placement.startsWith(`left`)||state.placement.startsWith(`top`)?-1:1;if(state.placement.startsWith(`left`)||state.placement.startsWith(`right`))return{x:state.x+side*arrOffset};if(state.placement.startsWith(`top`)||state.placement.startsWith(`bottom`))return{y:state.y+side*arrOffset}}});function buildMiddleware(popover,options){let middleware=[flip(),shift()],offsetValue=options.offset||0;return middleware.push(offset(offsetValue)),options.arrow&&(middleware.push(arrowOffset({element:options.arrow})),middleware.push(arrow({element:options.arrow}))),middleware}function applyStyles(el,styles){Object.keys(styles).forEach(styleName=>el.style[styleName]=styles[styleName])}var HOVER_SHOW_EVENTS=[`mouseover`,`focus`],HOVER_HIDE_EVENTS=[`mouseleave`,`blur`],TOGGLE_EVENTS=[`click`],BngPopover_default={mounted:setup$1,updated:setup$1,onBeforeUnmount:dispose};function setup$1(el,binding){dispose(el),binding.value&&(setPopoverProperties(el,binding),bindPopover(el),attachListeners(el,binding.modifiers))}function dispose(el){el.__popover&&(el.__popover.unregister&&el.__popover.unbind(),removeListeners(el))}function attachListeners(el,modifiers){el.__popover.showHandler=event=>{el.contains(event.target)&&el.__popover.show()},el.__popover.hideHandler=event=>{el.contains(event.relatedTarget)||el.__popover.hide()},el.__popover.toggleHandler=event=>{el.contains(event.target)&&el.__popover.toggle()},el.__popover.clickOutside=event=>{!el.contains(event.target)&&(!el.__popover.element.value||!el.__popover.element.value.contains(event.target))&&el.__popover.hide()},modifiers.click?(TOGGLE_EVENTS.forEach(eventName=>{el.addEventListener(eventName,el.__popover.toggleHandler)}),TOGGLE_EVENTS.forEach(eventName=>{window.addEventListener(eventName,el.__popover.clickOutside)})):(HOVER_SHOW_EVENTS.forEach(eventName=>el.addEventListener(eventName,el.__popover.showHandler)),HOVER_HIDE_EVENTS.forEach(eventName=>el.addEventListener(eventName,el.__popover.hideHandler)))}function removeListeners(el){el.__popover.toggleHandler&&(TOGGLE_EVENTS.forEach(eventName=>{el.removeEventListener(eventName,el.__popover.toggleHandler)}),TOGGLE_EVENTS.forEach(eventName=>{window.removeEventListener(eventName,el.__popover.clickOutside)})),el.__popover.showHandler&&HOVER_SHOW_EVENTS.forEach(eventName=>el.removeEventListener(eventName,el.__popover.showHandler)),el.__popover.hideHandler&&HOVER_SHOW_EVENTS.forEach(eventName=>el.removeEventListener(eventName,el.__popover.hideHandler))}function bindPopover(el){let popoverBind=usePopover().bind(el.__popover.name,el,getOptions$1(el));Object.assign(el.__popover,{toggle:popoverBind.toggle,show:popoverBind.show,isShown:popoverBind.isShown,hide:popoverBind.hide,toggle:popoverBind.toggle,hidden:popoverBind.hidden,element:popoverBind.popoverElement,unbind:popoverBind.unbind})}function setPopoverProperties(el,binding){el.__popover={name:getPopoverName(binding),placement:getPlacement(binding)}}var getOptions$1=el=>({placement:el.__popover.placement}),getPlacement=binding=>binding.arg?binding.arg:binding.placement?binding.placement:`left`,getPopoverName=binding=>typeof binding.value==`string`?binding.value:binding.value.name,TIMESPAN_TRANSLATE_ID_PREFIX=`ui.timespan.`,$t=i=>$translate.instant(TIMESPAN_TRANSLATE_ID_PREFIX+i),SECONDS_IN={year:3600*24*365,month:3600*24*30,week:3600*24*7,day:3600*24,hour:3600,minute:60,second:1},MINIMUM_SPAN=Object.entries(SECONDS_IN).slice(-1)[0][1],dateToEpoch=date=>date?typeof date==`string`?/^\d+$/.test(date)?+date:~~(new Date(date).getTime()/1e3):typeof date==`number`?date:0:0;const timeSpan=(date1,date2=null,length=2,useRelativeDescription=!1)=>{let res=`-`;if(date1=dateToEpoch(date1),!date1)return res;if(date2){if(date2=dateToEpoch(date2),!date2)return res}else date2=~~(new Date().getTime()/1e3);let diff,isFuture;return date1>=date2?(diff=date1-date2,isFuture=!0):(diff=date2-date1,isFuture=!1),res=formatTime(diff,length,useRelativeDescription,isFuture),res},formatTime=(seconds,length=2,useRelativeDescription=!1,future=!1)=>{let res=`-`;if(seconds20&&abs%10==1?abs+` `+$t(spanName+`.plural_1_pastfuture`):abs<=4||useRelativeDescription&&abs>20&&abs%10<=4?abs+` `+$t(spanName+`.plural_234`):abs+` `+$t(spanName+`.plural`),cur&&resArr.push(cur),length===1)break;length--,seconds%=spanSeconds}res=``;let resArrLen=resArr.length;return resArr.forEach((bit,i)=>{bit=bit.replace(` `,`\xA0`),i?(i===resArrLen-1?res+=` `+$t(`and`)+` `:res+=$t(`separator`)+` `,res+=bit):res+=ucaseFirst(bit)}),useRelativeDescription&&(res+=` `+$t(future?`future`:`past`)),res};var update=(element,{value})=>{let desc=timeSpan(value,null,1,!0);desc!==`-`&&(element.innerHTML=desc)},BngRelativeTime_default=update;const getScopeProperties=el=>{if(!(!el||!el.hasAttribute(`bng-ui-scope`)))return{scopeId:el.getAttribute(UI_SCOPE_ATTR$1),isScopedNav:el.hasAttribute(SCOPED_NAV_ATTR)}},findParentScope=(el,scopedNavOnly=!1)=>{let parent=el.parentElement;for(;parent;){let scopedNavId=parent.getAttribute(SCOPED_NAV_ATTR);if(scopedNavId)return{scopeId:scopedNavId,element:parent,isScopedNav:!0};if(!scopedNavOnly){let uiScopeId=parent.getAttribute(UI_SCOPE_ATTR$1);if(uiScopeId)return{scopeId:uiScopeId,element:parent,isScopedNav:!1}}parent=parent.parentElement}return null},isNavigable=el=>(!el.hasAttribute(`bng-no-nav`)||el.getAttribute(`bng-no-nav`)===`false`)&&(!el.hasAttribute(`disabled`)||el.getAttribute(`disabled`)===`false`),isDirectChild=(el,child)=>child.parentElement.closest(`[bng-scoped-nav]`)===el,getNavItems=(el,navigableOnly=!0)=>{let matches$1=el.querySelectorAll(NAVIGABLE_ELEMENTS_SELECTOR);return Array.from(matches$1).filter(child=>!isNavigable(child)&&navigableOnly?!1:isDirectChild(el,child))},getPassthroughEvents=el=>{let navItems=getNavItems(el,!1);if(navItems.length===0)return!1;let boundEvents=[];for(let elem of navItems){let uiNavEvents=elem.__BngOnUiNav?Object.values(elem.__BngOnUiNav).map(x=>x.eventNames).flat().filter(name=>!PASSTHROUGH_EXCLUDED_EVENTS.includes(name)):[],isDuplicate=uiNavEvents.some(event=>boundEvents.includes(event));if(uiNavEvents.length===0||isDuplicate){boundEvents=[];break}uiNavEvents.forEach(event=>{boundEvents.includes(event)||boundEvents.push(event)})}return boundEvents};var SCOPED_NAV_OBSERVER_EVENTS={onBeforeScopeActivated:`onBeforeScopeActivated`,onScopeActivated:`onScopeActivated`,onBeforeScopeDeactivated:`onBeforeScopeDeactivated`,onScopeDeactivated:`onScopeDeactivated`,onBeforeScopeSuspended:`onBeforeScopeSuspended`,onScopeSuspended:`onScopeSuspended`,onBeforeScopeResumed:`onBeforeScopeResumed`,onScopeResumed:`onScopeResumed`},scopedNavObservers={};function registerScopedNavObserver(id,observer$2){scopedNavObservers[id]=observer$2}function notifyScopedNavObservers(event,detail){Object.keys(scopedNavObservers).forEach(observerId=>{let callback=scopedNavObservers[observerId][event];if(callback&&typeof callback==`function`)try{callback(detail)}catch(error){logger_default.error(`Error in scoped nav observer ${observerId} for event ${event}`,error)}})}const useScopedNav=defineStore(`scopedNav2`,()=>{let scopeStack=ref([]),activateScope=(scopeId,element,options={activationType:SCOPED_NAV_STATES.active,suspendParentScopes:!1})=>{notifyScopedNavObservers(SCOPED_NAV_OBSERVER_EVENTS.onBeforeScopeActivated,{scopeId,element,options});let scopeIndex=scopeStack.value.findIndex(s=>s.scopeId===scopeId),existingScope=scopeIndex===-1?void 0:scopeStack.value[scopeIndex];if(existingScope&&existingScope.activationType===options.activationType){logger_default.warn(`Scope ${scopeId} already active. Ignoring...`),notifyScopedNavObservers(SCOPED_NAV_OBSERVER_EVENTS.onScopeActivated,{scopeId,element,options});return}existingScope?existingScope.activationType=options.activationType:(scopeStack.value.push({scopeId,element,...options}),scopeIndex=scopeStack.value.length-1),notifyScopedNavObservers(SCOPED_NAV_OBSERVER_EVENTS.onScopeActivated,{scopeId,element,options});let scopeData={scopeId,...options},{type}=element[SCOPED_NAV_PROPERTY_NAME];if(type===SCOPED_NAV_TYPES.popover||options.suspendParentScopes){let referenceElement=element;if(type===SCOPED_NAV_TYPES.popover){let popover=usePopover(),popoverName=element.getAttribute(`data-bng-popover-name`),pop=popover.getPopover(popoverName);pop&&pop.target&&(referenceElement=pop.target)}if(!referenceElement){logger_default.warn(`Unable to find popover's target element. Skipping suspending parent scopes...`);return}let parentScopes=scopeStack.value.slice(0,scopeIndex);for(let i=parentScopes.length-1;i>=0;i--){let scope$1=parentScopes[i];referenceElement&&scope$1.element.contains(referenceElement)?suspendScope(scope$1.scopeId,scopeData):referenceElement&&!scope$1.element.contains(referenceElement)&&deactivateScope(scope$1.scopeId)}}return getUINavServiceInstance().setActiveScope(scopeId),element.dispatchEvent(new CustomEvent(SCOPED_NAV_EVENTS.activate,{detail:scopeData})),scopeData},deactivateScope=(scopeId,settings$1={resumePrevious:!1})=>{let scopeIndex=scopeStack.value.findIndex(s=>s.scopeId===scopeId);if(scopeIndex===-1){logger_default.warn(`Scope ${scopeId} not found. Ignoring...`);return}notifyScopedNavObservers(SCOPED_NAV_OBSERVER_EVENTS.onBeforeScopeDeactivated,{scopeId,settings:settings$1});let scopeData=scopeStack.value[scopeIndex],element=scopeData.element,{type}=element[SCOPED_NAV_PROPERTY_NAME];if(scopeStack.value=scopeStack.value.slice(0,scopeIndex),element.dispatchEvent(new CustomEvent(SCOPED_NAV_EVENTS.deactivate,{detail:{scopeId,settings:settings$1,...scopeData}})),notifyScopedNavObservers(SCOPED_NAV_OBSERVER_EVENTS.onScopeDeactivated,{scopeId,settings:settings$1}),!settings$1.resumePrevious){getUINavServiceInstance().setActiveScope(null);return}let parentScope;if(type===SCOPED_NAV_TYPES.popover){let popover=usePopover(),popoverName=element.getAttribute(`data-bng-popover-name`),pop=popover.getPopover(popoverName);pop?parentScope=findParentScope(pop.target,!0):logger_default.warn(`Unable to find popover's target element. Skipping resume...`)}else parentScope=findParentScope(element,!0);parentScope?getScopeById(parentScope.scopeId)?resumeScope(parentScope.scopeId):activateScope(parentScope.scopeId,parentScope.element):getUINavServiceInstance().setActiveScope(null)},resumeScope=scopeId=>{let scopeIndex=scopeStack.value.findIndex(s=>s.scopeId===scopeId);if(scopeIndex===-1){logger_default.warn(`Scope ${scopeId} not found. Ignoring...`);return}notifyScopedNavObservers(SCOPED_NAV_OBSERVER_EVENTS.onBeforeScopeResumed,{scopeId});for(let i=scopeStack.value.length-1;i>scopeIndex;i--){let scope$1=scopeStack.value[i];deactivateScope(scope$1.scopeId)}let scopeData=scopeStack.value[scopeIndex];return scopeData.activationType=SCOPED_NAV_STATES.active,getUINavServiceInstance().setActiveScope(scopeData.scopeId),scopeData.element.dispatchEvent(new CustomEvent(SCOPED_NAV_EVENTS.resume,{detail:scopeData})),notifyScopedNavObservers(SCOPED_NAV_OBSERVER_EVENTS.onScopeResumed,{scopeId}),scopeData},suspendScope=(scopeId,newScope)=>{let scopeIndex=scopeStack.value.findIndex(s=>s.scopeId===scopeId);if(scopeIndex===-1){logger_default.warn(`Scope ${scopeId} not found. Ignoring...`);return}notifyScopedNavObservers(SCOPED_NAV_OBSERVER_EVENTS.onBeforeScopeSuspended,{scopeId,newScope});let scopeData=scopeStack.value[scopeIndex];if(scopeData.activationType===SCOPED_NAV_STATES.suspended){logger_default.warn(`Scope ${scopeId} already suspended. Ignoring...`);return}scopeData.activationType=SCOPED_NAV_STATES.suspended;let element=scopeData.element,payload={scopeId,newScope,...scopeData};return element.dispatchEvent(new CustomEvent(SCOPED_NAV_EVENTS.suspend,{detail:payload})),notifyScopedNavObservers(SCOPED_NAV_OBSERVER_EVENTS.onScopeSuspended,{scopeId,newScope}),scopeData},currentScope=()=>scopeStack.value[scopeStack.value.length-1],getScopeById=scopeId=>scopeStack.value.find(s=>s.scopeId===scopeId);return{activateScope,deactivateScope,resumeScope,suspendScope,getScopeById,currentScope,isCurrentScope:scopeId=>{let scope$1=currentScope();return scope$1&&scope$1.scopeId===scopeId},isActiveScope:scopeId=>{let current=currentScope();if(!current)return!1;if(current.scopeId===scopeId)return!0;if(current.activationType===SCOPED_NAV_STATES.partial&&scopeStack.value.length>2){let parentScope=scopeStack.value[scopeStack.value.length-2];if(parentScope.scopeId===scopeId&&parentScope.activationType===SCOPED_NAV_STATES.active)return!0}return!1},getScopes:()=>scopeStack.value}});var focusDebounceTimer=null,pendingFocusAction=null,focusListenersInitialized=!1,isActivatingScope=!1,isDeactivatingScope=!1,FOCUS_DEBOUNCE_TIME=200,focusManagerId=`focusManager`,clearFocusDebounce=()=>{focusDebounceTimer&&=(clearTimeout(focusDebounceTimer),null),pendingFocusAction=null},debouncedFocusAction=action=>{clearFocusDebounce(),pendingFocusAction=action,focusDebounceTimer=setTimeout(()=>{pendingFocusAction&&=(pendingFocusAction(),null),focusDebounceTimer=null},FOCUS_DEBOUNCE_TIME)};function useFocusManager(){let scopedNav=useScopedNav(),onUINavFocus=e=>{let{target,relatedTarget}=e.detail;if(isWithinDashmenu(target)||isWithinPopup(target))return;let targetScope=findParentScope(target,!0),scopeElement=targetScope&&targetScope.isScopedNav?targetScope.element:null,scopedNavProps=scopeElement&&scopeElement._bngScopedNav?scopeElement[SCOPED_NAV_PROPERTY_NAME]:null;if(scopedNavProps&&(scopeElement[SCOPED_NAV_PROPERTY_NAME].lastActiveElement=target),isActivatingScope||isDeactivatingScope||shouldSkipFocusHandling(scopedNavProps)){clearFocusDebounce();return}debouncedFocusAction(()=>handleFocusAction(target,targetScope,scopeElement,scopedNav))},onUINavBlur=e=>{let{target}=e.detail,scopeProperties=getScopeProperties(target);shouldHandleBlur(scopeProperties,scopedNav.currentScope())&&(target[SCOPED_NAV_PROPERTY_NAME].passthroughActive=!1,scopedNav.deactivateScope(scopeProperties.scopeId,{resumePrevious:!0}))};function addFocusListeners(){focusListenersInitialized||=(document.addEventListener(`uinav-focus`,onUINavFocus),document.addEventListener(`uinav-blur`,onUINavBlur),registerScopedNavObserver(focusManagerId,{onBeforeScopeActivated:()=>{clearFocusDebounce(),isActivatingScope=!0},onScopeActivated:()=>{clearFocusDebounce(),isActivatingScope=!1},onBeforeScopeDeactivated:()=>{clearFocusDebounce(),isDeactivatingScope=!0},onScopeDeactivated:()=>{clearFocusDebounce(),isDeactivatingScope=!1}}),!0)}function removeFocusListeners(){focusListenersInitialized&&=(document.removeEventListener(`uinav-focus`,onUINavFocus),document.removeEventListener(`uinav-blur`,onUINavBlur),!1)}function setup$3(){addFocusListeners()}function dispose$2(){removeFocusListeners()}return onMounted(()=>{setup$3()}),onBeforeUnmount(()=>{dispose$2()}),{setup:setup$3,dispose:dispose$2}}function isWithinDashmenu(target){return document.getElementById(`dashmenu`)?.contains(target)}function isWithinPopup(target){return!!target.closest(`dialog`)}function shouldSkipFocusHandling(scopedNavProps){return scopedNavProps?.type===SCOPED_NAV_TYPES.popover}function shouldHandleBlur(scopeProperties,currScope){return scopeProperties?.isScopedNav&&currScope?.scopeId===scopeProperties.scopeId&&currScope?.activationType===SCOPED_NAV_STATES.partial}function handleFocusAction(target,targetScope,scopeElement,scopedNavStore){if(!document.contains(target)&&!document.contains(scopeElement))return;let activeScope=scopedNavStore.currentScope();if(activeScope?.element===target)return;let existingScope,scopes=scopedNavStore.getScopes();for(let i=scopes.length-1;i>=0;i--){let scope$1=scopes[i];if(scope$1.element===scopeElement){existingScope=scope$1;break}}if(existingScope&&activeScope&&existingScope.scopeId!==activeScope.scopeId){scopedNavStore.resumeScope(existingScope.scopeId);return}scopes=scopedNavStore.getScopes();for(let i=scopes.length-1;i>=0;i--){let scope$1=scopes[i];if(scope$1.element===target||scope$1.element.contains(target)||scopeElement===scope$1.element||scope$1.element.contains(scopeElement))break;scopedNavStore.deactivateScope(scope$1.scopeId)}if(scopes=scopedNavStore.getScopes(),targetScope&&targetScope.isScopedNav){let lastScope=scopes.length>0?scopes[scopes.length-1]:null;lastScope&&activeScope&&activeScope.scopeId===lastScope.scopeId&&targetScope.scopeId!==lastScope.scopeId&&lastScope.activationType!==SCOPED_NAV_STATES.suspended&&scopedNavStore.suspendScope(lastScope.scopeId,{scopeId:targetScope.scopeId,scopeElement}),(!activeScope||activeScope.scopeId!==targetScope.scopeId)&&scopeElement._bngScopedNav.canActivate()&&scopedNavStore.activateScope(targetScope.scopeId,scopeElement)}if(target.hasAttribute(`bng-scoped-nav`)){let allowPartialActivation=target[SCOPED_NAV_PROPERTY_NAME].passthroughEnabled,canActivate=target[SCOPED_NAV_PROPERTY_NAME].canActivate();if(target[SCOPED_NAV_PROPERTY_NAME].passthroughActive=!0,allowPartialActivation&&canActivate){let partialScope=getScopeProperties(target);scopedNavStore.activateScope(partialScope.scopeId,target,{activationType:SCOPED_NAV_STATES.partial})}}}var PROPERTY_NAME=`_bngScopedNav`,ATTR_NAME=`bng-scoped-nav`,AUTOFOCUS_ATTR=`bng-scoped-nav-autofocus`,UI_SCOPE_ATTR=`bng-ui-scope`,NAV_ITEM_ATTR=`bng-nav-item`,BNG_ON_UI_NAV_ATTR=`__BngOnUiNav`,DEFAULT_AUTO_FOCUS_DELAY=100,EVENTS_UINAV_MAP={activate:[UI_EVENTS.ok],deactivate:[UI_EVENTS.back],navigation:[...UI_EVENT_GROUPS.focusMove,...UI_EVENT_GROUPS.focusMoveScalar]},NAV_EVENTS={activate:`activate`,deactivate:`deactivate`,suspend:`suspend`,resume:`resume`};const ACTIONS_ON_SUSPEND={allowNavigationLastNavItem:`allowNavigationLastNavItem`,allowNavigationByAttribute:`allowNavigationByAttribute`,disableNavigation:`disableNavigation`};var BngScopedNav_default={beforeMount,mounted,updated,beforeUnmount,unmounted},getDefaultOptions=()=>({type:SCOPED_NAV_TYPES.normal,activateOnMount:!1,actionsOnSuspend:[ACTIONS_ON_SUSPEND.disableNavigation],bubbleWhitelistEvents:[],bubbleBlacklistEvents:[],forcePassthroughEvents:[],canActivate:()=>!0,canDeactivate:()=>!0,autoFocusDelay:DEFAULT_AUTO_FOCUS_DELAY}),canBubbleEventInternal=(el,e)=>{let{bubbleWhitelistEvents,canBubbleEvent}=el[PROPERTY_NAME];return canBubbleEvent&&typeof canBubbleEvent==`function`?canBubbleEvent(e):bubbleWhitelistEvents&&Array.isArray(bubbleWhitelistEvents)&&bubbleWhitelistEvents.length>0?bubbleWhitelistEvents.includes(e.detail.name):!1},shouldBubbleToNextScope=(el,e)=>{let currentScope=useScopedNav().currentScope(),{scopeId,type}=el[PROPERTY_NAME],isActive=currentScope&¤tScope.scopeId===scopeId,isPartial=isActive&¤tScope.activationType===SCOPED_NAV_STATES.partial,isContainer=type===SCOPED_NAV_TYPES.container,isInactiveAndFocused=document.activeElement===el&&!isActive;return!currentScope||isInactiveAndFocused||canBubbleEventInternal(el,e)||isPartial||isContainer},getOptions=(el,binding,vnode)=>{let options={...getDefaultOptions(),...binding.value};if(!Object.values(SCOPED_NAV_TYPES).includes(options.type)){console.error(`Invalid scoped nav type: ${options.type}`);return}return options},applyOptions=(el,options)=>{let attributes={};switch(options.type){case SCOPED_NAV_TYPES.normal:attributes[NAV_ITEM_ATTR]=``,attributes[NO_CHILD_NAV_ATTR]=`true`;break;case SCOPED_NAV_TYPES.nonav:attributes[NO_NAV_ATTR]=`true`,attributes[NO_CHILD_NAV_ATTR]=`true`;break}Object.keys(attributes).forEach(attr=>el.setAttribute(attr,attributes[attr]))},findAutoFocusItem=navItems=>navItems.find(item=>item.hasAttribute(AUTOFOCUS_ATTR)&&item.getAttribute(AUTOFOCUS_ATTR)!==`false`),getAutoFocusItem=el=>findAutoFocusItem(getNavItems(el)),getFirstOrDefaultNavItem=el=>{let navItems,isAutoFocusItem=!1,getNavItems$1=()=>navItems||=getNavItems(el),getLastActive=()=>{let elm=el[PROPERTY_NAME].lastActiveElement;return elm&&!document.contains(elm)?null:elm},getAutoFocus=()=>{let elm=findAutoFocusItem(getNavItems$1());return elm&&!isNavigable(elm)?null:(isAutoFocusItem=!!elm,elm)},getFirst=()=>getNavItems$1()[0],sequence=[getLastActive,getAutoFocus];el[PROPERTY_NAME].preferAutoFocus&&sequence.reverse(),sequence.push(getFirst);for(let func of sequence){let elm=func();if(elm)return{focusItem:elm,isAutoFocusItem}}return{focusItem:null,isAutoFocusItem:!1}},setEnabledNavigation=(el,enabled,settings$1={applyToChildItems:!1,filterElements:void 0})=>{let{type}=el[PROPERTY_NAME];if(type===SCOPED_NAV_TYPES.nonav){logger_default.warn(`Cannot toggle navigation settings for nonav type`,el,enabled,type);return}settings$1.applyToChildItems?getNavItems(el,!1).forEach(item=>{if(!(settings$1.filterElements&&settings$1.filterElements.includes(item))){if(!item[PROPERTY_NAME]){let currentValue=item.hasAttribute(`bng-no-nav`)?item.getAttribute(NO_NAV_ATTR):void 0;item[PROPERTY_NAME]={originalNoNav:currentValue,hadOriginalNoNav:currentValue!==void 0}}enabled?(item[PROPERTY_NAME].hadOriginalNoNav?item.setAttribute(NO_NAV_ATTR,item[PROPERTY_NAME].originalNoNav):item.removeAttribute(NO_NAV_ATTR),item[PROPERTY_NAME].noNavSetByDirective=!1):(!item[PROPERTY_NAME].hadOriginalNoNav||item[PROPERTY_NAME].originalNoNav!==`true`)&&(item.setAttribute(NO_NAV_ATTR,`true`),item[PROPERTY_NAME].noNavSetByDirective=!0)}}):enabled?(el.removeAttribute(NO_CHILD_NAV_ATTR),type===SCOPED_NAV_TYPES.normal&&el.setAttribute(NO_NAV_ATTR,`true`)):(el.setAttribute(NO_CHILD_NAV_ATTR,`true`),type===SCOPED_NAV_TYPES.normal&&el.removeAttribute(NO_NAV_ATTR))},focusFirstOrDefaultNavItem=el=>{let{autoFocusDelay}=el[PROPERTY_NAME];nextTick(()=>{setTimeout(()=>{let{focusItem,isAutoFocusItem}=getFirstOrDefaultNavItem(el);focusItem&&setFocusExternal(focusItem,!0,isAutoFocusItem)},autoFocusDelay)})},ensureFocusOrFocusDefault=el=>{document.activeElement&&isDirectChild(el,document.activeElement)?ensureFocus(document.activeElement,!0):focusFirstOrDefaultNavItem(el)};function beforeMount(el,binding,vnode){let options=getOptions(el,binding,vnode);if(!options)return;let scopeId=options.scopeId||uniqueId(`scoped-nav`);el[PROPERTY_NAME]={scopeId,...options},el[PROPERTY_NAME].shouldBubbleEvent=e=>shouldBubbleToNextScope(el,e),el.setAttribute(ATTR_NAME,scopeId),el.setAttribute(UI_SCOPE_ATTR,scopeId),applyOptions(el,options)}function mounted(el,binding,vnode){addUINavEventListeners(el,binding,vnode),addScopedNavEventListeners(el);let scopedNav=useScopedNav(),options=getOptions(el,binding,vnode);options.type===SCOPED_NAV_TYPES.normal?configurePartialActivation(el):options.type===SCOPED_NAV_TYPES.container&&configureContainer(el,!1),options.activateOnMount&&nextTick(()=>scopedNav.activateScope(el[PROPERTY_NAME].scopeId,el))}var handleDefaultUpdate=(el,binding,vnode)=>{let activeScope=useScopedNav().currentScope(),{scopeId,type}=el[PROPERTY_NAME];!activeScope||activeScope.scopeId!==scopeId||activeScope.activationType!==SCOPED_NAV_STATES.active||ensureFocusOrFocusDefault(el)};function updated(el,binding,vnode){let options=getOptions(el,binding,vnode),{scopeId}=el[PROPERTY_NAME],scopedNav=useScopedNav();if(options.activated===!0&&!scopedNav.isActiveScope(scopeId))if(scopedNav.getScopeById(scopeId)){let popover=usePopover();if(Object.values(popover.popovers).filter(x=>x.show===!0).length>0)return;scopedNav.resumeScope(scopeId,el)}else scopedNav.activateScope(scopeId,el,{activationType:SCOPED_NAV_STATES.active,suspendParentScopes:!0});else options.activated===!1&&scopedNav.isActiveScope(scopeId)?scopedNav.deactivateScope(scopeId,{resumePrevious:!0}):!scopedNav.isActiveScope(scopeId)&&options.type===SCOPED_NAV_TYPES.container&&configureContainer(el,!1);nextTick(()=>{let activeScope=scopedNav.currentScope();activeScope&&activeScope.scopeId===scopeId&&handleDefaultUpdate(el,binding,vnode)})}function beforeUnmount(el,binding,vnode){removeScopedNavEventListeners(el);let scopedNav=useScopedNav();if(scopedNav.getScopeById(el[PROPERTY_NAME].scopeId)){let{type}=el[PROPERTY_NAME];scopedNav.deactivateScope(el[PROPERTY_NAME].scopeId,{resumePrevious:type===SCOPED_NAV_TYPES.popover}),el.dispatchEvent(new CustomEvent(NAV_EVENTS.deactivate,{detail:{force:!0,reason:`unmounted`}}))}}function unmounted(el,binding,vnode){}var handlePartialActivation=(el,event)=>{el[PROPERTY_NAME].forceBubble=!0},handleNormalActivation=(el,event)=>{el[PROPERTY_NAME].forceBubble=!1,nextTick(()=>{setEnabledNavigation(el,!0),(!document.activeElement||el===document.activeElement||!el.contains(document.activeElement))&&focusFirstOrDefaultNavItem(el)})},configurePartialActivation=el=>{let passthroughEvents=getPassthroughEvents(el);el[PROPERTY_NAME].passthroughEnabled=passthroughEvents.length>0,el[PROPERTY_NAME].passthroughEvents=passthroughEvents},configureContainer=(el,activated)=>{el[PROPERTY_NAME].containerSetup&&el[PROPERTY_NAME].containerSetup.cancel(),el[PROPERTY_NAME].containerSetup=debounce(()=>{let autoFocusItem=getAutoFocusItem(el);autoFocusItem&&setEnabledNavigation(el,activated,{applyToChildItems:!0,filterElements:[autoFocusItem]})},100),el[PROPERTY_NAME].containerSetup()},handleContainerActivation=(el,event)=>{configureContainer(el,!0)},handleNoNavActivation=(el,event)=>{},onActivate=(el,event)=>{let{type}=el[PROPERTY_NAME],{activationType}=event.detail;activationType===SCOPED_NAV_STATES.partial?handlePartialActivation(el,event):type===SCOPED_NAV_TYPES.normal?handleNormalActivation(el,event):type===SCOPED_NAV_TYPES.container?handleContainerActivation(el,event):SCOPED_NAV_TYPES.nonav,el.dispatchEvent(new CustomEvent(NAV_EVENTS.activate,{detail:event.detail}))},onDeactivate=(el,event)=>{let{type}=el[PROPERTY_NAME];type===SCOPED_NAV_TYPES.normal&&event.detail.activationType===SCOPED_NAV_STATES.active?setEnabledNavigation(el,!1):type===SCOPED_NAV_TYPES.container&&configureContainer(el,!1),el[PROPERTY_NAME].forceBubble=!1,el.dispatchEvent(new CustomEvent(NAV_EVENTS.deactivate,{detail:event.detail}))},onSuspend=(el,event)=>{let{actionsOnSuspend,type}=el[PROPERTY_NAME],filterElements=[];if(actionsOnSuspend.includes(ACTIONS_ON_SUSPEND.allowNavigationLastNavItem)){let lastActiveElement=el[PROPERTY_NAME].lastActiveElement;lastActiveElement&&document.contains(lastActiveElement)&&filterElements.push(lastActiveElement)}setEnabledNavigation(el,!1,{applyToChildItems:!0,filterElements})},onResume=(el,event)=>{let{actionsOnSuspend,type}=el[PROPERTY_NAME],filterElements=[];if(actionsOnSuspend.includes(ACTIONS_ON_SUSPEND.allowNavigationLastNavItem)){let lastActiveElement=el[PROPERTY_NAME].lastActiveElement;lastActiveElement&&document.contains(lastActiveElement)&&filterElements.push(lastActiveElement)}setEnabledNavigation(el,!0,{applyToChildItems:!0,filterElements}),ensureFocusOrFocusDefault(el)};function addScopedNavEventListeners(el){let eventHandlers={[SCOPED_NAV_EVENTS.activate]:event=>onActivate(el,event),[SCOPED_NAV_EVENTS.deactivate]:event=>onDeactivate(el,event),[SCOPED_NAV_EVENTS.suspend]:event=>onSuspend(el,event),[SCOPED_NAV_EVENTS.resume]:event=>onResume(el,event)};Object.keys(eventHandlers).forEach(eventName=>{el[PROPERTY_NAME].scopedNavListeners||(el[PROPERTY_NAME].scopedNavListeners={}),el.addEventListener(eventName,eventHandlers[eventName]),el[PROPERTY_NAME].scopedNavListeners[eventName]=eventHandlers[eventName]})}function removeScopedNavEventListeners(el){!el||!el[PROPERTY_NAME]||!el[PROPERTY_NAME].scopedNavListeners||Object.keys(el[PROPERTY_NAME].scopedNavListeners).forEach(eventName=>{el.removeEventListener(eventName,el[PROPERTY_NAME].scopedNavListeners[eventName]),delete el[PROPERTY_NAME].scopedNavListeners[eventName]})}var allowsNavigation=el=>{let{type}=el[PROPERTY_NAME];return[SCOPED_NAV_TYPES.normal,SCOPED_NAV_TYPES.container,SCOPED_NAV_TYPES.popover].includes(type)},processNavigationEvent=(el,e)=>{let currentScope=useScopedNav().currentScope(),{scopeId}=el[PROPERTY_NAME];if(!allowsNavigation(el))return!1;document.activeElement===el&¤tScope.scopeId===scopeId?focusFirstOrDefaultNavItem(el):handleUINavEvent(e,el)},isNavigationEvent=e=>UI_EVENT_GROUPS.navigation.includes(e.detail.name),getUINavEventsByEl=el=>{let uiNavEvents=el[BNG_ON_UI_NAV_ATTR]?Object.values(el[BNG_ON_UI_NAV_ATTR]).map(x=>x.eventNames).flat():[],boundEvents=[];return uiNavEvents.forEach(ev=>{boundEvents.includes(ev)||boundEvents.push(ev)}),boundEvents},hasBoundEvent=(el,eventName)=>{let boundEvents=getUINavEventsByEl(el);return boundEvents&&boundEvents.length>0&&boundEvents.includes(eventName)},isUINavEventBoundToChild=(el,e)=>{let{scopeId}=el[PROPERTY_NAME],currentScope=useScopedNav().currentScope();return currentScope&¤tScope.scopeId===scopeId&&e.target!==el&&el.contains(e.target)&&e.target===document.activeElement&&hasBoundEvent(e.target,e.detail.name)},generalHandler=(el,e)=>{let shouldBubble=!1;return isUINavEventBoundToChild(el,e)&&!e.target.hasAttribute(ATTR_NAME)||(shouldBubbleToNextScope(el,e)?shouldBubble=!0:isNavigationEvent(e)&&processNavigationEvent(el,e)),shouldBubble},processOkChildHandler=(el,e)=>{isUINavEventBoundToChild(el,e)||(handleUINavEvent(e,e.target),e.detail.sendToCrossfire=!1)},okHandler=(el,e)=>{if(e.detail.value!==1)return shouldBubbleToNextScope(el,e);let scopedNav=useScopedNav(),scopeId=el[PROPERTY_NAME].scopeId,currentScope=scopedNav.currentScope();return currentScope&¤tScope.scopeId===scopeId&¤tScope.activationType===SCOPED_NAV_STATES.active&&(document.activeElement&&isDirectChild(el,document.activeElement)||e.target&&isDirectChild(el,e.target))?processOkChildHandler(el,e):el[PROPERTY_NAME].canActivate()&&el[PROPERTY_NAME].type===SCOPED_NAV_TYPES.normal&&document.activeElement===el&&scopedNav.activateScope(scopeId,el),shouldBubbleToNextScope(el,e)},backHandler=(el,e)=>{if(e.detail.value!==1)return;let scopedNav=useScopedNav(),{scopeId,type,canDeactivate}=el[PROPERTY_NAME],currentScope=scopedNav.currentScope();if(currentScope&¤tScope.scopeId===scopeId&¤tScope.activationType===SCOPED_NAV_STATES.active)canDeactivate()&&(scopedNav.deactivateScope(scopeId,{resumePrevious:!0,executingScope:scopeId}),type===SCOPED_NAV_TYPES.normal&&nextTick(()=>setFocusExternal(el)));else if(e.target!==el&&isDirectChild(el,e.target))return!1;else return!0},uiNavEventsHandler=(el,e)=>{let uiNavEvent=e.detail.name;return EVENTS_UINAV_MAP.activate.includes(uiNavEvent)?okHandler(el,e):EVENTS_UINAV_MAP.deactivate.includes(uiNavEvent)?backHandler(el,e):generalHandler(el,e)};function addUINavEventListeners(el,binding,vnode){let{bubbleWhitelistEvents}=el[PROPERTY_NAME],generalUINavBinding={arg:[...EVENTS_UINAV_MAP.activate,...EVENTS_UINAV_MAP.deactivate,...EVENTS_UINAV_MAP.navigation].join(`,`),value:e=>uiNavEventsHandler(el,e)};BngOnUiNav_default.mounted(el,generalUINavBinding,vnode)}var ID=`__bngSound`,ID_STOP=`__bngSoundStop`,events$1={click:`click`,dblclick:`dblclick`,focus:`focus`,mouseenter:`mouseenter`};function handler(ev){let el=ev.currentTarget;if(el&&(el[ID]&&events$1[ev.type]&&Lua_default.ui_audio.playEventSound(el[ID],events$1[ev.type]),el[ID_STOP]))for(let event in delete el[ID_STOP],delete el[ID],events$1)el.removeEventListener(event,handler)}var BngSoundClass_default={mounted:(el,binding)=>{delete el[ID_STOP],el[ID]=binding.value,nextTick(()=>{for(let event in events$1)el.addEventListener(event,handler)})},updated:(el,binding)=>{el[ID]=binding.value},unmounted:el=>{el[ID_STOP]=!0}},marker=`__BNG_SD_INPUT`,inputTypes={singleLine:0,multiLine:1};function bindToInputs(elements){let inputs=Array.isArray(elements)?elements:[elements];for(let input of inputs){if(marker in input)continue;input[marker]=!0;let type,tag=input.tagName.toLowerCase();if(tag===`textarea`)type=inputTypes.multiLine;else if(tag===`input`&&[`text`,`number`,`password`,`search`].includes(input.type.toLowerCase()))type=inputTypes.singleLine;else continue;input.addEventListener(`focus`,()=>{let rect=input.getBoundingClientRect();console.log(`SteamDeck input focus:`,type,rect),Lua_default.Steam.showFloatingGamepadTextInput(type,rect.left,rect.top,rect.width,rect.height)})}}async function useSteamDeckInput(inputs){if(!inputs)throw Error(`inputs must be specified (ref, refs, element, elements)`);(await useSettingsAsync()).values.runningOnSteamDeck&&(isRef(inputs)?watch(inputs,bindToInputs,{immediate:!0}):bindToInputs(inputs))}var bridge$1,focused=!1,elms={},elmid=`__BNG_TEXT_INPUT`,focus=id=>async()=>{elms[id].active=!0,focused||=(await bridge$1.lua.setCEFTyping(!0),!0)},blur=id=>async()=>{elms[id].active=!1,focused&&(focused=Object.values(elms).some(e=>e.active),focused||await bridge$1.lua.setCEFTyping(!1))},BngTextInput_default={mounted(el){bridge$1||(bridge$1=useBridge(),bridge$1.events.on(`CEFTypingLostFocus`,()=>focused&&document.activeElement.blur()));let id=el[elmid]||(el[elmid]=uniqueId());elms[id]={el,active:!1,onFocus:focus(id),onBlur:blur(id)},el.addEventListener(`focus`,elms[id].onFocus),el.addEventListener(`blur`,elms[id].onBlur),useSteamDeckInput(el)},beforeUnmount(el){let id=el[elmid];elms[id]&&(el.removeEventListener(`focus`,elms[id].onFocus),el.removeEventListener(`blur`,elms[id].onBlur),elms[id].onBlur(),delete elms[id])}},DEFAULT_POSITION=`left`,TOOLTIP_ATTR_NAME=`data-bng-tooltip`,CONTENT_ATTR_NAME=`data-bng-tooltip-content`,ARROW_ATTR_NAME=`data-bng-tooltip-arrow`,SHOW_TOOLTIP_EVENTS=[`mouseover`,`focusin`],HIDE_TOOLTIP_EVENTS=[`mouseout`,`focusout`],DATA_PROP=`__bngTooltip`,POPOVER_CONTAINER=`.popover-container`,BngTooltip_default={beforeMount(el){initTooltipData(el)},mounted(el,binding,vnode){setupBindings(el,binding),setupTooltip(el),setListeners(el)},beforeUpdate(el,binding){setupBindings(el,binding),el[DATA_PROP].text===void 0?removeTooltip(el):updateTooltipElement(el)},updated(el){let data=el[DATA_PROP];data.update&&requestAnimationFrame(()=>data.update())},beforeUnmount(el){SHOW_TOOLTIP_EVENTS.forEach(eventName=>el.removeEventListener(eventName,el.__showTooltip)),HIDE_TOOLTIP_EVENTS.forEach(eventName=>el.removeEventListener(eventName,el.__hideTooltip));let data=el[DATA_PROP];data.dispose&&data.dispose(),removeTooltip(el)}};function setListeners(el){let data=el[DATA_PROP];data.showTooltip||(data.showTooltip=event=>{data.hideDelay&&=(clearTimeout(data.hideDelay),null),data.tooltipAnimationFrame&&=(cancelAnimationFrame(data.tooltipAnimationFrame),null),el.contains(event.target)&&!data.tooltipElRef.value&&queueTooltipUpdate(el,!0)},SHOW_TOOLTIP_EVENTS.forEach(eventName=>el.addEventListener(eventName,data.showTooltip,!0))),data.hideTooltip||(data.hideTooltip=event=>{data.tooltipAnimationFrame&&=(cancelAnimationFrame(data.tooltipAnimationFrame),null),!el.contains(event.relatedTarget)&&data.tooltipElRef.value&&queueTooltipUpdate(el,!1)},HIDE_TOOLTIP_EVENTS.forEach(eventName=>el.addEventListener(eventName,data.hideTooltip,!0)))}function setupBindings(el,binding){if(binding.value){let bindingValues=getBindings(binding);el[DATA_PROP].text=bindingValues.text,el[DATA_PROP].hideDelayTime=bindingValues.hideDelay,el[DATA_PROP].position=bindingValues.position,el[DATA_PROP].isBBCode=bindingValues.isBBCode,el[DATA_PROP].style=bindingValues.style}else resetTooltipData(el)}function queueTooltipUpdate(el,shouldShow){let data=el[DATA_PROP];data.tooltipAnimationFrame&&cancelAnimationFrame(data.tooltipAnimationFrame),data.pendingTooltipState=shouldShow,data.tooltipAnimationFrame=requestAnimationFrame(()=>{data.pendingTooltipState?showTooltip(el):hideTooltip(el),data.tooltipAnimationFrame=null,data.pendingTooltipState=null})}function showTooltip(el){let data=el[DATA_PROP];data.text&&(addTooltip(el),usePopover().show(data.popoverName,el))}function hideTooltip(el){let data=el[DATA_PROP],hideFn=()=>{removeTooltip(el)};data.hideDelayTime&&typeof data.hideDelayTime==`number`&&data.hideDelayTime>0?data.hideDelay=setTimeout(()=>{hideFn(),data.hideDelay=null},data.hideDelayTime):hideFn()}function setupTooltip(el){let data=el[DATA_PROP],popover=usePopover(),popoverInstance=popover.register(data.popoverName,data.tooltipElRef,data.position,{arrow:data.arrowElRef,offset:4});if(!popoverInstance){console.error(`Failed to register tooltip`);return}el[DATA_PROP].update=popoverInstance.update,el[DATA_PROP].dispose=()=>popover.unregister(data.popoverName),popover.bind(data.popoverName,el,{placement:data.position})}function updateTooltipElement(el){if(el[DATA_PROP].tooltipElRef.value&&el[DATA_PROP].tooltipElRef.value){let updatedContent=parseText(el[DATA_PROP].text,el[DATA_PROP].isBBCode),spanEl=el[DATA_PROP].tooltipElRef.value.querySelector(`span`);spanEl.innerHTML=updatedContent}}function addTooltip(el){let data=el[DATA_PROP];data.tooltipElRef.value=createTooltip(data);let popoverContainer=document.querySelector(POPOVER_CONTAINER);popoverContainer||=(console.warn(`Popover container not found, using parent element`),el.parentElement),el[DATA_PROP].arrowElRef.value=createArrow(),data.tooltipElRef.value.appendChild(el[DATA_PROP].arrowElRef.value),popoverContainer.appendChild(data.tooltipElRef.value)}function removeTooltip(el){let data=el[DATA_PROP];usePopover().hide(data.popoverName),data.tooltipElRef.value&&(data.tooltipElRef.value.remove(),data.tooltipElRef.value=null),data.update&&data.update()}function createTooltip(data){let container=document.createElement(`div`);return data.style&&Object.keys(data.style).forEach(key=>container.style.setProperty(key,data.style[key])),container.setAttribute(TOOLTIP_ATTR_NAME,``),container.appendChild(createContent(data.text,data.isBBCode)),container}function createContent(text,isBBCode){let content=document.createElement(`span`);return Object.assign(content.style,{}),content.innerHTML=parseText(text,isBBCode),content.setAttribute(CONTENT_ATTR_NAME,``),content}function createArrow(){let arrow$3=document.createElement(`span`);return Object.assign(arrow$3.style,{}),arrow$3.setAttribute(ARROW_ATTR_NAME,``),arrow$3}function parseText(text,isBBCode){return isBBCode?parse$1(text):text}var getBindings=binding=>{let position=binding.arg?binding.arg:DEFAULT_POSITION,hideDelay,text,isBBCode=!1,style={};return typeof binding.value==`object`?(hideDelay=binding.value?.hideDelay||0,text=binding.value?.text||void 0,isBBCode=binding.value?.isBBCode||!1,style=binding.value?.style||{}):text=binding.value,{text,position,hideDelay,isBBCode,style}};function initTooltipData(el){el[DATA_PROP]={popoverName:uniqueId(`bng-tooltip`),tooltipElRef:ref(null),arrowElRef:ref(null)},resetTooltipData(el)}function resetTooltipData(el){el[DATA_PROP].text=void 0,el[DATA_PROP].style={},el[DATA_PROP].isBBCode=!1,el[DATA_PROP].hideDelayTime=void 0,el[DATA_PROP].position=void 0,el[DATA_PROP].hideDelay=null,el[DATA_PROP].tooltipAnimationFrame=null}var reg=(elm,{value})=>nextTick(()=>elm&&wantsFocus(elm,value)),BngUiNavFocus_default={mounted:reg,updated:reg,beforeUnmount:unwantsFocus},registry,procEventNames=eventNames=>eventNames.split(`,`).map(name=>name.trim()).filter(Boolean),BngUiNavLabel_default={mounted(el,{arg:eventNames,value:label}){if(!eventNames){console.warn(`Usage: v-bng-ui-nav-label:back,menu="'Back'"`);return}registry||=useUiNavLabel(),label&&(eventNames=procEventNames(eventNames),registry.registerLabel(el,eventNames,label))},updated(el,{arg:eventNames,value:label}){eventNames&&(eventNames=procEventNames(eventNames),label?registry.registerLabel(el,eventNames,label):registry.clearLabels(el,eventNames))},beforeUnmount(el){let events$3=registry.getElementEvents(el);events$3.length>0&®istry.clearLabels(el,events$3)}},SCROLL_PROP=`__bngUiNavScroll`;function enableScroll(id,el){let tracker=useUINavTracker();tracker.addEvent(SCROLL_EVENT_H,id,el),tracker.addEvent(SCROLL_EVENT_V,id,el),tracker.addForceUnblock(SCROLL_EVENT_H,id),tracker.addForceUnblock(SCROLL_EVENT_V,id)}function disableScroll(id,el){let tracker=useUINavTracker();tracker.removeEvent(SCROLL_EVENT_H,id,el),tracker.removeEvent(SCROLL_EVENT_V,id,el),tracker.removeForceUnblock(SCROLL_EVENT_H,id),tracker.removeForceUnblock(SCROLL_EVENT_V,id)}var BngUiNavScroll_default={mounted(element,{arg,value,modifiers}){let prev=element[SCROLL_PROP]||{},dir={id:prev.id||uniqueId(SCROLL_PROP),forced:modifiers.force,enable:()=>enableScroll(dir.id,element),disable:()=>disableScroll(dir.id,element)};if(element[SCROLL_PROP]=dir,prev.forced&&(element.removeEventListener(`focusin`,prev.enable),element.removeEventListener(`focusout`,prev.disable)),typeof value==`boolean`&&!value){prev.id&&prev.disable(),dir.forced=!1;return}dir.forced?(element.setAttribute(SCROLL_FORCE_ATTR,``),dir.enable()):(element.setAttribute(SCROLL_ATTR,``),element.addEventListener(`focusin`,dir.enable),element.addEventListener(`focusout`,dir.disable))},beforeUnmount(element){let dir=element[SCROLL_PROP];dir&&(dir.forced||(element.removeEventListener(`focusin`,dir.enable),element.removeEventListener(`focusout`,dir.disable)),dir.disable(),delete element[SCROLL_PROP])}},observed=new WeakMap;function createObserver(root=null,rootMargin=`0px`){return new IntersectionObserver(entries=>{for(let entry of entries){let data=observed.get(entry.target);if(!data){entry.target.observer?.unobserve(entry.target);return}if(data.onChange)data.onChange(entry.isIntersecting);else{let displayValue=entry.isIntersecting?[`display`,``,``]:[`display`,`none`,`important`];entry.target.style.setProperty(...displayValue),entry.target.querySelectorAll(`*`).forEach(child=>{child.style.setProperty(...displayValue)})}}},{root,rootMargin,threshold:0})}var defaultObserver=createObserver(),_sfc_main$404={__name:`bngActionDrawer`,props:{actions:{type:Object,default:{allowOpenDrawer:!1}},skeletonItems:{type:Number,default:5},usePath:Boolean,alwaysShowBack:Boolean,itemWidth:Number,itemHeight:Number,itemMargin:Number,big:Boolean,position:String,blur:Boolean},emits:[`select`],setup(__props,{expose:__expose,emit:__emit}){let props=__props,emit$1=__emit;__expose({goBack:onBack});let expanded=ref(!1),current=ref(props.actions),lazyItem={label:`…`,icon:icons.stopwatchSectionOutlinedStart};function onSelect(item){(`items`in item||item.lazyLoadItems)&&(current.value&&addBack(current.value),current.value=item),emit$1(`select`,item)}let backState=computed(()=>{let disable=back.value.length===0||!(`items`in current.value);return{show:!disable||props.alwaysShowBack,disable}}),back=ref([]);function onBack(){current.value=null,onSelect(back.value.pop().data)}function addBack(prevItem){let backItem={index:back.value.length,label:prevItem.label,data:prevItem};props.usePath&&prevItem.items&&(backItem.items=prevItem.items.reduce((res,itm)=>[...res,{index:backItem.index+1,label:itm.label,data:itm}],[])),back.value.push(backItem)}let path=computed(()=>props.usePath?[...back.value,{current:!0,label:current.value.label,data:current.value}]:void 0);function onPath(item){item.current||(back.value.splice(item.index),current.value=null,onSelect(item.data))}return watch(()=>props.actions,val=>{back.value.splice(0),current.value=val}),(_ctx,_cache)=>(openBlock(),createBlock(unref(bngDrawer_default),{modelValue:expanded.value,"onUpdate:modelValue":_cache[0]||=$event=>expanded.value=$event,expandable:current.value.allowOpenDrawer,position:__props.position,blur:__props.blur},createSlots({"header-controls":withCtx(()=>[__props.usePath?(openBlock(),createBlock(unref(bngBreadcrumbs_default),{key:0,items:path.value,limit:`5`,onClick:onPath},null,8,[`items`])):backState.value.show?(openBlock(),createBlock(unref(bngButton_default),{key:1,accent:unref(ACCENTS).outlined,disabled:backState.value.disable,onClick:onBack},{default:withCtx(()=>[..._cache[1]||=[createTextVNode(`Back`,-1)]]),_:1},8,[`accent`,`disabled`])):createCommentVNode(``,!0),renderSlot(_ctx.$slots,`controls`)]),content:withCtx(()=>[withDirectives((openBlock(),createBlock(unref(bngList_default),{layout:expanded.value?unref(LIST_LAYOUTS).TILES:unref(LIST_LAYOUTS).RIBBON,big:__props.big,"target-width":__props.itemWidth,"target-height":__props.itemHeight,"target-margin":__props.itemMargin,"no-background":``},{default:withCtx(()=>[`items`in current.value?(openBlock(!0),createElementBlock(Fragment,{key:0},renderList(current.value.items,(item,index)=>renderSlot(_ctx.$slots,`action`,{item,select:onSelect,isLoading:!1,order:index})),256)):(openBlock(!0),createElementBlock(Fragment,{key:1},renderList(__props.skeletonItems,idx=>renderSlot(_ctx.$slots,`action`,{item:lazyItem,select:()=>{},isLoading:!0})),256))]),_:3},8,[`layout`,`big`,`target-width`,`target-height`,`target-margin`])),[[unref(BngDisabled_default),!(`items`in current.value)]])]),_:2},[__props.usePath?void 0:{name:`header`,fn:withCtx(()=>[createTextVNode(toDisplayString(current.value.label),1)]),key:`0`}]),1032,[`modelValue`,`expandable`,`position`,`blur`]))}},bngActionDrawer_default=_sfc_main$404,__plugin_vue_export_helper_default=(sfc,props)=>{let target=sfc.__vccOpts||sfc;for(let[key,val]of props)target[key]=val;return target},_hoisted_1$347={class:`bng-accordion-container`},_sfc_main$403={__name:`accordion`,props:{singular:Boolean,expanded:Boolean,disabled:Boolean,animated:Boolean,selectable:[Boolean,Object],selected:Boolean,provideParent:Boolean},emits:[`selected`],setup(__props,{emit:__emit}){let props=__props,counter$1=0,items$2=[],selopts=null,emit$1=__emit;watch(()=>props.singular,val=>val&&toggle(items$2.find(itm=>itm.expanded),!0)),watch(()=>props.expanded,val=>toggle(null,val)),watch(()=>props.animated,val=>{for(let itm of items$2)itm.animated=val},{immediate:!0}),watch(()=>props.disabled,val=>{for(let itm of items$2)itm.disabled=val},{immediate:!0}),watch(()=>props.selectable,val=>{val?(selopts={multi:!1},typeof val==`object`&&(selopts={selopts,...val})):selopts=null;for(let itm of items$2)itm.selectable=selopts},{immediate:!0}),watch(()=>props.selected,val=>select(null,val));function toggle(item=null,expanded=null){if(props.singular&&!item&&expanded){if(items$2.length===0)return;item=items$2[0]}for(let itm of items$2){let exp=!itm.expandedActual;item&&itm.id!==item.id?exp=props.singular?!1:itm.expandedActual:typeof expanded==`boolean`&&(exp=expanded),itm.expandedActual=exp}}provide(`accordion-item-toggle`,toggle);function select(item=null,selected=null){let state=[];for(let itm of items$2){let sel;sel=item&&itm.id!==item.id?selopts.multi?itm.selected:!1:typeof selected==`boolean`?selected:selopts.multi?!itm.selected:!0,itm.selected!==sel&&(itm.selected=sel,state.push(itm))}state.length>0&&emit$1(`selected`,state)}provide(`accordion-item-select`,select),props.provideParent&&inject(`accordion-item-childSelect`)(select);let waitForOptions=cb=>selopts?cb():setTimeout(()=>waitForOptions(cb),50);return provide(`accordion-item-register`,item=>{item.id=counter$1++,props.expanded&&(item.expanded=props.expanded),props.disabled&&(item.disabled=props.disabled),props.selectable&&(item.selectable=props.selectable),items$2.push(item),waitForOptions(()=>{props.singular&&item.expanded&&toggle(item,!0),item.selected&&select(item,!0)})}),provide(`accordion-item-unregister`,item=>{let idx=items$2.findIndex(itm=>itm.id===item.id);idx>-1&&items$2.splice(idx,1)}),(_ctx,_cache)=>withDirectives((openBlock(),createElementBlock(`div`,_hoisted_1$347,[renderSlot(_ctx.$slots,`default`,{},void 0,!0)])),[[unref(BngDisabled_default),__props.disabled]])}},accordion_default=__plugin_vue_export_helper_default(_sfc_main$403,[[`__scopeId`,`data-v-fcd1832d`]]),_hoisted_1$346={key:0,class:`bng-accitem-content`},_sfc_main$402={__name:`accordionItem`,props:{static:Boolean,expanded:Boolean,disabled:Boolean,animated:Boolean,selectable:{type:[Boolean,Object],default:!1},selected:Boolean,data:{},navigable:{type:[Boolean,Object],default:!1},arrowBig:Boolean,primaryAction:Function,secondaryAction:Function,primaryLabel:String,secondaryLabel:String,primaryHintInline:Boolean,secondaryHintInline:Boolean,expandHintInline:Boolean},emits:[`focus`,`unfocus`,`expanded`,`selected`],setup(__props,{expose:__expose,emit:__emit}){let{showIfController}=storeToRefs(controls_default()),navBlocker=useUINavBlocker(),props=__props,elCaption=ref(),elCaptionContent=ref(),elCaptionControls=ref(),hasFocus=ref(!1),icon=computed(()=>props.arrowBig?icons.arrowLargeRight:icons.arrowSmallRight),popTip=ref();watch([()=>hasFocus.value,()=>showIfController.value],()=>{hasFocus.value&&showIfController.value&&(props.primaryHintInline&&props.primaryAction||props.secondaryHintInline&&props.secondaryAction)?popTip.value.show(elCaption.value):popTip.value.isShown()&&popTip.value.hide()});let reg$1=inject(`accordion-item-register`),unreg=inject(`accordion-item-unregister`),toggle=inject(`accordion-item-toggle`),select=inject(`accordion-item-select`),opts=reactive({id:-1,captionClick:evt=>{props.primaryAction&&evt.fromController?props.primaryAction():opts.selectable?select(opts):opts.expandClick()},expandClick:()=>!props.static&&toggle(opts),static:props.static,expandedActual:props.expanded,disabled:props.disabled,animated:props.animated,selected:props.selected,selectable:props.selectable,navigable:{enabled:!1},data:props.data}),emit$1=__emit;__expose({captionClick:opts.captionClick,focus:()=>setFocusExternal(elCaption.value,!0,!1),captionElement:computed(()=>elCaption.value)}),watch(()=>props.static,val=>opts.static=val),watch(()=>props.expanded,val=>!opts.static&&toggle(opts,val)),watch(()=>props.disabled,val=>opts.disabled=val),watch(()=>opts.disabled,val=>!val&&props.disabled&&(opts.disabled=props.disabled)),watch(()=>props.animated,val=>opts.animated=val),watch(()=>props.selectable,val=>opts.selectable=val),watch(()=>props.selected,val=>opts.selected=val),watch(()=>opts.expandedActual,val=>{emit$1(`expanded`,!opts.static&&!opts.disabled&&val)}),watch(()=>props.data,val=>opts.data=val),watch(()=>props.navigable,val=>{if(typeof val!=`object`&&typeof val==`boolean`&&!val){opts.navigable={enabled:!1};return}opts.navigable={enabled:!0,scope:null,...typeof val==`object`?val:{}}},{immediate:!0}),opts.navigable.scope&&useUINavScope(opts.navigable.scope);let onFocus=evt=>{hasFocus.value=!0,navBlocker.blockOnly(opts.static?[`context`]:[]),emit$1(`focus`,evt)},onLoseFocus=evt=>{hasFocus.value=!1,navBlocker.clear(),emit$1(`unfocus`,evt)};return provide(`accordion-item-childSelect`,select$1=>(item,value)=>opts.selectable&&opts.selectable.multi&&select$1(item,value)),provide(`accordion-item-parent`,opts),onMounted(()=>reg$1(opts)),onBeforeUnmount(()=>{popTip.value.isShown()&&popTip.value.hide(),unreg(opts)}),(_ctx,_cache)=>withDirectives((openBlock(),createElementBlock(`div`,{class:normalizeClass({"bng-accitem":!0,"bng-accitem-normal":!opts.static&&!opts.selectable,"bng-accitem-static":opts.static,"bng-accitem-expandable":!opts.static,"bng-accitem-selectable":opts.selectable,"bng-accitem-expanded":!opts.static&&opts.expandedActual&&!opts.disabled,"bng-accitem-selected":opts.selected})},[withDirectives((openBlock(),createElementBlock(`div`,mergeProps({ref_key:`elCaption`,ref:elCaption,class:`bng-accitem-caption`,onClick:_cache[1]||=(...args)=>opts.captionClick&&opts.captionClick(...args),onFocus,onBlur:onLoseFocus},{"bng-nav-item":opts.navigable.enabled?!0:void 0,"bng-ui-scope":opts.navigable.scope||void 0}),[opts.static?createCommentVNode(``,!0):(openBlock(),createBlock(unref(bngIcon_default),{key:0,class:normalizeClass({"bng-accitem-caption-expander":!0,"bng-accitem-caption-expander-big":__props.arrowBig}),type:icon.value,onClick:withModifiers(opts.expandClick,[`stop`])},null,8,[`class`,`type`,`onClick`])),__props.expandHintInline&&!opts.static&&hasFocus.value&&unref(showIfController)?(openBlock(),createBlock(unref(bngBinding_default),{key:1,style:{"padding-right":`0.2em`},uiEvent:`context`,controller:``})):createCommentVNode(``,!0),createBaseVNode(`span`,{ref_key:`elCaptionContent`,ref:elCaptionContent,class:`bng-accitem-caption-content`},[renderSlot(_ctx.$slots,`caption`,{},()=>[_cache[2]||=createTextVNode(`Unnamed item`,-1)],!0)],512),_ctx.$slots.controls?(openBlock(),createElementBlock(`div`,{key:2,ref_key:`elCaptionControls`,ref:elCaptionControls,class:`bng-accitem-caption-controls`,onClick:_cache[0]||=withModifiers(()=>{},[`stop`])},[renderSlot(_ctx.$slots,`controls`,{},void 0,!0)],512)):createCommentVNode(``,!0),createVNode(unref(bngPopoverContent_default),{ref_key:`popTip`,ref:popTip,placement:`right`},{default:withCtx(()=>[__props.primaryHintInline&&__props.primaryAction?(openBlock(),createBlock(unref(bngBinding_default),{key:0,uiEvent:`ok`,controller:``})):createCommentVNode(``,!0),__props.secondaryHintInline&&__props.secondaryAction?(openBlock(),createBlock(unref(bngBinding_default),{key:1,uiEvent:`action_2`,controller:``})):createCommentVNode(``,!0)]),_:1},512)],16)),[[unref(BngOnUiNav_default),void 0,`ok`,{asMouse:!0,focusRequired:!0}],[unref(BngOnUiNav_default),__props.secondaryAction?__props.secondaryAction:void 0,`action_2`,{focusRequired:!0}],[unref(BngOnUiNav_default),!opts.static&&opts.navigable.enabled?opts.expandClick:void 0,`context`,{focusRequired:!0}],[unref(BngUiNavLabel_default),__props.primaryLabel||`ui.inputActions.menu.menu_item_select.title`,`ok`],[unref(BngUiNavLabel_default),__props.secondaryLabel,`action_2`],[unref(BngUiNavLabel_default),_ctx.$tt(`ui.common.expand`)+`/`+_ctx.$tt(`ui.common.collapse`),`context`]]),createVNode(Transition,{name:opts.animated?`bng-acc-trans`:null},{default:withCtx(()=>[!opts.static&&opts.expandedActual&&!opts.disabled?(openBlock(),createElementBlock(`div`,_hoisted_1$346,[renderSlot(_ctx.$slots,`default`,{},()=>[_cache[3]||=createTextVNode(`Empty`,-1)],!0)])):createCommentVNode(``,!0)]),_:3},8,[`name`])],2)),[[unref(BngDisabled_default),opts.disabled]])}},accordionItem_default=__plugin_vue_export_helper_default(_sfc_main$402,[[`__scopeId`,`data-v-dd6087ee`]]),_sfc_main$401={__name:`accordionTree`,props:{data:[Array,Object],dataField:{type:String,required:!0},propsField:String,contentField:String,selectable:{type:[Boolean,Object],default:!1},selectedField:String,isTreeElement:Boolean},emits:[`selected`],setup(__props,{emit:__emit}){let props=__props,dataView=computed(()=>props.data&&(props.data[props.dataField]||props.data)||[]),emit$1=__emit;props.isTreeElement||(watch(()=>dataView.value,refreshSelected),watch(()=>props.selectedField&&props.selectable&&props.selectable.multi,refreshSelected),refreshSelected());let prevState=[];function refreshSelected(){if(!props.selectedField||!props.selectable||!props.selectable.multi)return;let state=[];function deepScan(arr){for(let itm of arr){let data=itm.data||itm;data[props.selectedField]&&state.push({data,selected:!0}),data[props.dataField]&&deepScan(data[props.dataField])}}deepScan(dataView.value),selected(state)}function selected(state){if(!props.isTreeElement){if(!props.selectable.multi){prevState=prevState.filter(itm=>itm.selected);for(let itm of prevState)itm.selected&&(itm.item.selected=!1,props.selectedField&&(itm.item.data[props.selectedField]=!1),state.includes(itm.item)||state.push(itm.item));prevState=state.map(item=>({selected:!!item.selected,item}))}if(props.selectedField){function deepSet(arr,value=void 0){for(let itm of arr){let val=typeof value==`boolean`?value:itm.selected,data=itm.data||itm;data[props.selectedField]=val,data[props.dataField]&&deepSet(data[props.dataField])}}deepSet(state)}}emit$1(`selected`,state)}function branchSelected(state){props.isTreeElement?emit$1(`selected`,state):selected(state)}return(_ctx,_cache)=>dataView.value.length>0?(openBlock(),createBlock(unref(accordion_default),{key:0,class:`acctree`,selectable:__props.selectable,"provide-parent":__props.isTreeElement,onSelected:selected},{default:withCtx(()=>[(openBlock(!0),createElementBlock(Fragment,null,renderList(dataView.value,entry=>(openBlock(),createBlock(unref(accordionItem_default),mergeProps({ref_for:!0},__props.propsField?entry[__props.propsField]:void 0,{selected:__props.selectedField?entry[__props.selectedField]:void 0,static:(!entry[__props.dataField]||entry[__props.dataField].length===0)&&(!__props.contentField||!entry[__props.contentField]),data:entry}),{caption:withCtx(()=>[renderSlot(_ctx.$slots,`caption`,{entry},void 0,!0)]),controls:withCtx(()=>[renderSlot(_ctx.$slots,`controls`,{entry},void 0,!0)]),default:withCtx(()=>[__props.contentField&&entry[__props.contentField]?renderSlot(_ctx.$slots,`default`,{key:0,entry},void 0,!0):createCommentVNode(``,!0),entry[__props.dataField]&&entry[__props.dataField].length>0?(openBlock(),createBlock(unref(accordionTree_default),mergeProps({key:1,ref_for:!0},props,{data:entry,"is-tree-element":!0,onSelected:branchSelected}),{caption:withCtx(({entry:entry$1})=>[renderSlot(_ctx.$slots,`caption`,{entry:entry$1},void 0,!0)]),controls:withCtx(({entry:entry$1})=>[renderSlot(_ctx.$slots,`controls`,{entry:entry$1},void 0,!0)]),_:2},1040,[`data`])):createCommentVNode(``,!0)]),_:2},1040,[`selected`,`static`,`data`]))),256))]),_:3},8,[`selectable`,`provide-parent`])):createCommentVNode(``,!0)}},accordionTree_default=__plugin_vue_export_helper_default(_sfc_main$401,[[`__scopeId`,`data-v-2ad1085d`]]),_hoisted_1$345={class:`slotted`},_sfc_main$400={__name:`aspectRatio`,props:{ratio:{type:String,default:`16:9`},imageMode:{type:String,default:`cover`,validator:value=>[`cover`,`contain`].includes(value)},image:{type:String,default:null},externalImage:{type:String,default:null}},setup(__props){useCssVars(_ctx=>({v711986eb:__props.imageMode}));let placeholderImageURL=getAssetURL(`images/noimage.png`),slots=useSlots(),props=__props,padding=computed(()=>{if(!props.ratio)return`56.25%`;let[width$1,height$1]=props.ratio.split(`:`).map(Number);return`${height$1/width$1*100}%`}),backgroundStyle=computed(()=>!props.image&&!props.externalImage?{"--padding":padding.value,backgroundImage:`none`}:props.image||props.externalImage?{"--padding":padding.value,backgroundImage:`url("${props.externalImage?props.externalImage:getAssetURL(props.image)}")`}:slots.default?{"--padding":padding.value,backgroundImage:`url("${placeholderImageURL}")`}:{});return(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,{class:`aspect-ratio`,style:normalizeStyle(backgroundStyle.value)},[createBaseVNode(`div`,_hoisted_1$345,[renderSlot(_ctx.$slots,`default`,{},void 0,!0)])],4))}},aspectRatio_default=__plugin_vue_export_helper_default(_sfc_main$400,[[`__scopeId`,`data-v-83698898`]]),_hoisted_1$344=[`data-carousel-item`],_sfc_main$399={__name:`carouselItem`,props:{value:{type:[String,Number],required:!0}},setup(__props){return(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,{class:`bng-carousel-item`,"data-carousel-item":__props.value},[renderSlot(_ctx.$slots,`default`,{},void 0,!0)],8,_hoisted_1$344))}},carouselItem_default=__plugin_vue_export_helper_default(_sfc_main$399,[[`__scopeId`,`data-v-babc74fb`]]),_hoisted_1$343={key:0,class:`navigation`},_hoisted_2$271=[`onClick`],TRANSITION_TYPES=[`fade`],_sfc_main$398={__name:`carousel`,props:{items:{type:Array,required:!0},current:{type:[String,Number],default:0},vertical:Boolean,loop:{type:Boolean,default:!0},transition:Boolean,transitionType:{type:String,default:`fade`,validator:value=>TRANSITION_TYPES.includes(value)},transitionTime:{type:Number,default:3e3},showNav:{type:Boolean,default:!0},parent:Object},setup(__props,{expose:__expose}){let props=__props,transitionTimer,carouselRoot=ref(null),carousel=ref(null),currentIndex=ref(props.current);computed(()=>``);let navState=reactive({selected:null}),showSlide=value=>{let slideIndex=parseInt(value);currentIndex.value=slideIndex,navState.selected=slideIndex,setTransition()},navShown=computed(()=>props.showNav&&!props.parent),children=[],childIndex=child=>children.findIndex(itm=>itm.element===child.element),addChild=child=>{childIndex(child)===-1&&children.push(child)},remChild=child=>{let idx=childIndex(child);idx>-1&&children.splice(idx,1)},tryParent=(_retry=0)=>{if(props.parent.addChild)props.parent.addChild(exposed);else if(_retry<100){let unwatch=watch(()=>props.parent.addChild,()=>{unwatch(),tryParent(++_retry)})}};watch(()=>props.parent,tryParent),watch(()=>navState.selected,sel=>{for(let child of children)child.showSlide&&child.showSlide(sel)}),onMounted(()=>{setTransition(),props.parent&&tryParent()}),onBeforeUnmount(()=>{transitionTimer&&=(clearInterval(transitionTimer),null),props.parent&&props.parent.remChild&&props.parent.remChild(exposed)});function showPrevious(){if(props.parent)return;let prev;currentIndex.value===0&&props.loop?prev=props.items.length-1:currentIndex.value>0&&(prev=currentIndex.value-1),prev!==void 0&&(navState.selected=prev,currentIndex.value=prev,setTransition())}function showNext(){if(props.parent)return;let next=getNext();next>-1&&(navState.selected=next,currentIndex.value=next,setTransition())}function setTransition(){transitionTimer&&clearInterval(transitionTimer),transitionTimer=setInterval(()=>{let next=getNext();next>-1&&(currentIndex.value=next)},props.transitionTime)}function getNext(){return currentIndex.value===props.items.length-1&&props.loop?0:currentIndex.value(openBlock(),createElementBlock(`div`,{ref_key:`carouselRoot`,ref:carouselRoot,class:normalizeClass({"bng-carousel":!0,"carousel-vertical":__props.vertical,[`transition-${__props.transitionType}`]:!0})},[createBaseVNode(`div`,{ref_key:`carousel`,ref:carousel,class:`carousel-content`},[createVNode(Transition,{name:__props.transitionType},{default:withCtx(()=>[(openBlock(),createBlock(carouselItem_default,{key:currentIndex.value,class:`carousel-slide`,value:currentIndex.value},{default:withCtx(()=>[renderSlot(_ctx.$slots,`item`,{item:__props.items[currentIndex.value],index:currentIndex.value},()=>[createTextVNode(toDisplayString(__props.items[currentIndex.value]),1)],!0)]),_:3},8,[`value`]))]),_:3},8,[`name`])],512),renderSlot(_ctx.$slots,`navigation`,{},()=>[navShown.value&&__props.items&&__props.items.length>1?(openBlock(),createElementBlock(`div`,_hoisted_1$343,[(openBlock(!0),createElementBlock(Fragment,null,renderList(__props.items,(item,index)=>(openBlock(),createElementBlock(`div`,{class:normalizeClass([`navigation-item`,{active:index===currentIndex.value}]),key:item.value,onClick:$event=>showSlide(index)},null,10,_hoisted_2$271))),128))])):createCommentVNode(``,!0)],!0)],2))}},carousel_default=__plugin_vue_export_helper_default(_sfc_main$398,[[`__scopeId`,`data-v-f54192e0`]]),_hoisted_1$342={key:0,class:`drawer-header`},_hoisted_2$270={key:1,class:`drawer-content`},_hoisted_3$236={key:2,class:`drawer-header`};const DRAWER_POSITION={bottom:`bottom`,top:`top`,left:`left`,right:`right`};var _sfc_main$397={__name:`drawer`,props:mergeModels({blur:Boolean,position:{type:String,default:DRAWER_POSITION.bottom,validator:val=>Object.values(DRAWER_POSITION).includes(val)}},{modelValue:{type:Boolean},modelModifiers:{}}),emits:mergeModels([`change`],[`update:modelValue`]),setup(__props,{emit:__emit}){let emit$1=__emit,expanded=useModel(__props,`modelValue`);watch(()=>expanded.value,val=>emit$1(`change`,val));let slots=useSlots(),expandedContent=computed(()=>expanded.value&&`expanded-content`in slots),hasAnyContent=computed(()=>expandedContent.value||`content`in slots);return(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,{class:normalizeClass({"bng-drawer":!0,[`drawer-pos-${__props.position}`]:!0,"drawer-expanded":expanded.value})},[__props.position===`bottom`||__props.position===`right`?withDirectives((openBlock(),createElementBlock(`div`,_hoisted_1$342,[renderSlot(_ctx.$slots,`header`,{},void 0,!0)])),[[unref(BngBlur_default),__props.blur]]):createCommentVNode(``,!0),hasAnyContent.value?withDirectives((openBlock(),createElementBlock(`div`,_hoisted_2$270,[expandedContent.value?renderSlot(_ctx.$slots,`expanded-content`,{key:0},void 0,!0):renderSlot(_ctx.$slots,`content`,{key:1},void 0,!0)])),[[unref(BngBlur_default),__props.blur]]):createCommentVNode(``,!0),__props.position===`top`||__props.position===`left`?withDirectives((openBlock(),createElementBlock(`div`,_hoisted_3$236,[renderSlot(_ctx.$slots,`header`,{},void 0,!0)])),[[unref(BngBlur_default),__props.blur]]):createCommentVNode(``,!0)],2))}},drawer_default=__plugin_vue_export_helper_default(_sfc_main$397,[[`__scopeId`,`data-v-8023232b`]]),_sfc_main$396={__name:`dynamicComponent`,props:{template:String,translateId:String,translateContext:Boolean,bbcode:Boolean,useComponents:{type:Boolean,default:!0},extraComponents:{type:Object,default:()=>({})}},setup(__props){let ALL_COMPONENTS=Object.fromEntries(Object.entries({...base_exports,...utility_exports}).filter(([name])=>name!==`DEMOS`)),attrs=useAttrs(),props=__props,template=computed(()=>{let res=props.template;return props.translateId&&(res=props.translateContext?$translate.contextTranslate(props.translateId,!0):$translate.instant(props.translateId)),res&&props.bbcode&&(res=parse$1(res)),res||``}),makeComponent=computed(()=>defineComponent({template:template.value,components:{...props.useComponents&&ALL_COMPONENTS,...props.extraComponents},data(){return attrs}}));return(_ctx,_cache)=>template.value&&makeComponent.value?(openBlock(),createBlock(resolveDynamicComponent(makeComponent.value),{key:0})):createCommentVNode(``,!0)}},dynamicComponent_default=_sfc_main$396,_hoisted_1$341={class:`shelf-wrapper`},_hoisted_2$269=[`disabled`],_hoisted_3$235=[`disabled`],storageKey=`bngshelf`,_sfc_main$395={__name:`shelf`,props:mergeModels({saveName:{type:String,default:null},limit:{type:Number,default:5,validator:val=>val>2&&val%2==1},fade:{type:Boolean,default:!1},showExtra:{type:Boolean,default:!0},neighborsFlatten:{type:Boolean,default:!1},neighborsScale:{type:Number,default:1},keepNeighborsAspectRatio:{type:Boolean,default:!1},noLoop:{type:Boolean,default:!1},navShown:{type:Boolean,default:!1},inward:{type:Number,default:0,validator:val=>val>=0&&val<=1}},{modelValue:{type:Number,default:0},modelModifiers:{}}),emits:mergeModels([`change`,`click`],[`update:modelValue`]),setup(__props,{expose:__expose,emit:__emit}){let selectedIndex=useModel(__props,`modelValue`),props=__props,emit$1=__emit,ready=ref(!1),slots=useSlots(),containerRef=ref(null),shelfItems=ref([]),displayItems=ref([]),isAnimating=ref(!1),itemIdCounter=0,lastValidIndex=0,isReverting=!1,isPrevDisabled=computed(()=>isAnimating.value||props.noLoop&&selectedIndex.value===0),isNextDisabled=computed(()=>isAnimating.value||props.noLoop&&selectedIndex.value===shelfItems.value.length-1);watch(selectedIndex,index=>{if(!isReverting){if(index=parseInt(index,10),isNaN(index)||index<0||shelfItems.value.length>0&&index>=shelfItems.value.length){isReverting=!0,selectedIndex.value=lastValidIndex,isReverting=!1;return}lastValidIndex=index,ready.value&&buildDisplayItems()}},{immediate:!0});let timings={single:400,multiStart:200,multiMiddle:200,multiEnd:200};watch(()=>slots.default?.(),update$6,{immediate:!0});function update$6(vnodes){if(ready.value){if(vnodes===void 0&&(vnodes=slots.default?.()),Array.isArray(vnodes)||(vnodes=[]),shelfItems.value=vnodes.reduce((res,vnode)=>typeof vnode.type==`symbol`&&vnode.type.toString()===`Symbol(v-fgt)`?(res.push(...vnode.children),res):(res.push(vnode),res),[]),props.saveName){let val=localStorage.getItem(`${storageKey}-${props.saveName}`);if(val!==null){let idx=parseInt(val,10);!isNaN(idx)&&idx>=0&&idxhalfLimit)continue;let itemIndex=selectedIndex.value+offset$2;if(props.noLoop){if(itemIndex<0||itemIndex>=shelfItems.value.length)continue}else itemIndex<0?itemIndex=shelfItems.value.length+itemIndex:itemIndex>=shelfItems.value.length&&(itemIndex-=shelfItems.value.length);items$2.push({vnode:shelfItems.value[itemIndex],originalIndex:itemIndex,position:offset$2,id:++itemIdCounter,style:getItemStyle(offset$2,`normal`)})}displayItems.value=items$2}function getItemStyle(position,state=`normal`){let absPosition=Math.abs(position),halfLimit=~~(props.limit/2),isExtraItem=absPosition>halfLimit,factor=halfLimit>0?absPosition/halfLimit:1,leftPercentage;if(leftPercentage=isExtraItem?(position<0?0:props.limit-1)/(props.limit-1)*100:(position+halfLimit)/(props.limit-1)*100,position!==0&&props.inward>0){let pullToCenter=(50-leftPercentage)*props.inward*factor;leftPercentage+=pullToCenter}let rotateY=factor*-30*Math.sign(position),translateZ=0,scaleX=1,scaleY=1,brightness=1;if(position!==0){if(translateZ=-100*factor,props.keepNeighborsAspectRatio){let scale=Math.max(.6,1-factor*.4)*props.neighborsScale;scaleX=scale,scaleY=scale}else scaleX=Math.max(.4,1-factor*.6)*props.neighborsScale,scaleY=Math.max(.6,1-factor*.4)*props.neighborsScale;brightness=Math.max(.5,1-factor*.5),props.neighborsFlatten&&(rotateY=0)}let opacity=1;return state===`entering`||state===`exiting`?(opacity=.1,translateZ=-100*(absPosition/halfLimit),leftPercentage+=2*Math.sign(position)):isExtraItem?opacity=.2:props.fade&&position!==0&&(opacity=Math.max(.4,1-absPosition*.3)),{left:`${leftPercentage}%`,transform:`translateX(-50%) translateY(-50%) translateZ(${translateZ}px) rotateY(${rotateY}deg) scale(${scaleX}, ${scaleY})`,filter:`brightness(${brightness})`,transition:`all 400ms cubic-bezier(0.25, 0.8, 0.25, 1)`,opacity,zIndex:isExtraItem?10-absPosition:100-absPosition}}let abortAnimation=!1;async function toIndex(targetIndex){if(!ready.value||selectedIndex.value===targetIndex||typeof targetIndex!=`number`||targetIndex<0||targetIndex>=shelfItems.value.length)return;if(isAnimating.value)for(abortAnimation=!0;abortAnimation;)await sleep(20);let prevIndex=selectedIndex.value,steps=calculateSteps(selectedIndex.value,targetIndex);if(steps.length!==0){isAnimating.value=!0;try{let stepTimings=calculateStepTimings(steps.length);for(let i=0;i{selectedIndex.value===targetIndex&&setFocusExternal(containerRef.value.querySelector(`[data-shelf-index="${targetIndex}"]`))})}finally{abortAnimation=!1,isAnimating.value=!1}props.saveName&&localStorage.setItem(`${storageKey}-${props.saveName}`,targetIndex.toString()),emit$1(`change`,targetIndex,prevIndex)}}let onFocus=index=>selectedIndex.value!==index&&toIndex(index);function onClick(index,event){selectedIndex.value===index?emit$1(`click`,event,index):toIndex(index)}function calculateStepTimings(stepCount){return stepCount===1?[timings.single]:Array.from({length:stepCount},(_,i)=>i===0?timings.multiStart:i===stepCount-1?timings.multiEnd:timings.multiMiddle)}function calculateSteps(fromIndex,toIndex$1){let targetItemIndex=displayItems.value.findIndex(item=>item.originalIndex===toIndex$1),steps=[];if(targetItemIndex===-1){let current=fromIndex;for(;current!==toIndex$1;){let totalItems=shelfItems.value.length;props.noLoop?toIndex$1>current?current+=1:--current:current=(toIndex$1-current+totalItems)%totalItems<=(current-toIndex$1+totalItems)%totalItems?(current+1)%totalItems:(current-1+totalItems)%totalItems,steps.push(current)}}else{let targetPosition=displayItems.value[targetItemIndex].position;if(targetPosition!==0){let direction$1=targetPosition>0?1:-1,stepsNeeded=Math.abs(targetPosition),current=fromIndex;for(let i=0;i0?current+=1:--current:current=direction$1>0?(current+1)%shelfItems.value.length:(current-1+shelfItems.value.length)%shelfItems.value.length,steps.push(current)}}return steps}async function animateToStep(stepIndex,stepTiming){let halfLimit=Math.floor(props.limit/2),currentIndex=selectedIndex.value,actualDirection=0;if(props.noLoop)actualDirection=stepIndex>currentIndex?1:-1;else{let totalItems=shelfItems.value.length;actualDirection=(stepIndex-currentIndex+totalItems)%totalItems<=(currentIndex-stepIndex+totalItems)%totalItems?1:-1}let newItems=[];if(actualDirection>0){for(let i=0;i=shelfItems.value.length?rightmostIndex-shelfItems.value.length:rightmostIndex),wrappedIndex>=0&&wrappedIndex=0&&wrappedIndexhalfLimit;newItems.push({...currentItem,position:newPosition,style:getItemStyle(newPosition,isExiting?`exiting`:`normal`)})}}displayItems.value=newItems;let delay=stepTiming/2;await sleep(delay),displayItems.value=displayItems.value.map(item=>item.style.opacity===.1&&(item.position===halfLimit||item.position===-halfLimit)?{...item,style:getItemStyle(item.position,`normal`)}:item),await new Promise(resolve$1=>setTimeout(resolve$1,delay))}function navigateNext$1(){isAnimating.value||props.noLoop&&selectedIndex.value===shelfItems.value.length-1||toIndex((selectedIndex.value+1)%shelfItems.value.length)}function navigatePrev(){isAnimating.value||props.noLoop&&selectedIndex.value===0||toIndex(selectedIndex.value===0?shelfItems.value.length-1:selectedIndex.value-1)}__expose({toIndex,next:navigateNext$1,prev:navigatePrev,isSelected:evt=>{let elm=evt.target.closest(`[data-shelf-index]`);if(!elm)return!1;let idx=parseInt(elm.getAttribute(`data-shelf-index`),10);return!isNaN(idx)&&selectedIndex.value===idx}}),onMounted(()=>{ready.value=!0,nextTick(update$6)});function getActiveItem(){let active=document.activeElement;return String(active.dataset.shelfIndex)===String(selectedIndex.value)?null:containerRef.value.querySelector(`[data-shelf-index="${selectedIndex.value}"]`)}return(_ctx,_cache)=>withDirectives((openBlock(),createElementBlock(`div`,_hoisted_1$341,[withDirectives((openBlock(),createElementBlock(`div`,{ref_key:`containerRef`,ref:containerRef,class:`shelf-container`},[(openBlock(!0),createElementBlock(Fragment,null,renderList(displayItems.value,item=>(openBlock(),createElementBlock(`div`,{key:`item-${item.originalIndex}-${item.id}`,class:`shelf-item`,style:normalizeStyle(item.style)},[(openBlock(),createBlock(resolveDynamicComponent(item.vnode),{"data-shelf-index":item.originalIndex,onClick:$event=>onClick(item.originalIndex,$event),onFocus:$event=>onFocus(item.originalIndex),onUinavFocus:$event=>onFocus(item.originalIndex)},null,40,[`data-shelf-index`,`onClick`,`onFocus`,`onUinavFocus`]))],4))),128))])),[[unref(BngFocusCapture_default),getActiveItem,`101`]]),__props.navShown?(openBlock(),createElementBlock(`button`,{key:0,class:`shelf-nav shelf-nav-prev`,onClick:navigatePrev,disabled:isPrevDisabled.value},[createVNode(unref(bngIcon_default),{type:unref(icons).arrowLargeLeft},null,8,[`type`])],8,_hoisted_2$269)):createCommentVNode(``,!0),__props.navShown?(openBlock(),createElementBlock(`button`,{key:1,class:`shelf-nav shelf-nav-next`,onClick:navigateNext$1,disabled:isNextDisabled.value},[createVNode(unref(bngIcon_default),{type:unref(icons).arrowLargeRight},null,8,[`type`])],8,_hoisted_3$235)):createCommentVNode(``,!0)],512)),[[vShow,displayItems.value.length>0]])}},shelf_default=__plugin_vue_export_helper_default(_sfc_main$395,[[`__scopeId`,`data-v-0109573f`]]),_sfc_main$394={__name:`slotSwitcher`,props:{slotId:{type:String,default:`default`}},setup(__props){return(_ctx,_cache)=>renderSlot(_ctx.$slots,__props.slotId,normalizeProps(guardReactiveProps(_ctx.$attrs)))}},slotSwitcher_default=_sfc_main$394,_sfc_main$393={__name:`tab`,props:{heading:String,selected:Boolean},setup(__props){return(_ctx,_cache)=>renderSlot(_ctx.$slots,`default`,{tabHeading:__props.heading,tabSelected:__props.selected})}},tab_default=_sfc_main$393,_hoisted_1$340={class:`tab-list`},_sfc_main$392={__name:`tabList`,setup(__props){let tabs=inject(`tabs`),selectTab=inject(`selectTab`),tabHeaderClasses=tab=>({"tab-item":!0,"tab-active-tab":tab.active,"no-hover":tab.active});function handleTabSelect(index,event){let buttonElement=event.currentTarget,hasFocusVisible=document.activeElement&&document.activeElement.classList.contains(`focus-visible`);selectTab(index),hasFocusVisible&&nextTick(()=>{setFocusExternal(buttonElement)})}return(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$340,[(openBlock(!0),createElementBlock(Fragment,null,renderList(unref(tabs),(tab,i)=>(openBlock(),createBlock(unref(bngButton_default),{key:i,accent:(tab.active,`ghost`),class:normalizeClass(tabHeaderClasses(tab)),tabindex:`0`,"bng-nav-item":``,onClick:$event=>handleTabSelect(tab.index,$event)},{default:withCtx(()=>[createTextVNode(toDisplayString(tab.heading),1)]),_:2},1032,[`accent`,`class`,`onClick`]))),128))]))}},tabList_default=__plugin_vue_export_helper_default(_sfc_main$392,[[`__scopeId`,`data-v-5c322d77`]]),_hoisted_1$339={class:`tab-container`},_sfc_main$391={__name:`tabs`,props:{selectedIndex:{type:Number,default:-1}},emits:[`change`],setup(__props,{expose:__expose,emit:__emit}){let emit$1=__emit,props=__props,ready=ref(!1),slots=useSlots(),tabListStart=shallowRef(),tabListEnd=shallowRef(),tabsList=ref(),tabsContent=ref([]),selectedIndex=ref(-1),isTabList=vnode=>typeof vnode.type==`object`&&vnode.type.__name===tabList_default.__name;provide(`tabs`,tabsList),watch(()=>slots.default?.(),update$6,{immediate:!0}),watch(()=>props.selectedIndex,index=>selectTab(index));function update$6(vnodes){if(!ready.value)return;vnodes===void 0&&(vnodes=slots.default?.()),Array.isArray(vnodes)||(vnodes=[]);let tabListIndex=vnodes.findIndex(vn=>isTabList(vn));tabListStart.value=tabListIndex===0?vnodes[tabListIndex]:tabList_default,tabListEnd.value=tabListIndex===vnodes.length-1?vnodes[tabListIndex]:null,tabsContent.value=vnodes.filter(vn=>!isTabList(vn)).reduce((res,vnode)=>typeof vnode.type==`symbol`&&vnode.type.toString()===`Symbol(v-fgt)`?(res.push(...vnode.children),res):(res.push(vnode),res),[]),tabsList.value=tabsContent.value.map((tab,index)=>({index,heading:tab.props?.[`tab-heading`]||tab.props?.tabHeading||`Tab ${index+1}`,active:selectedIndex.value===-1?props.selectedIndex===index||!!tab.props?.[`tab-selected`]||!!tab.props?.tabSelected:selectedIndex.value===index}));let activeIndex=tabsList.value.findIndex(tab=>tab.active);selectTab(activeIndex>-1?activeIndex:0)}function selectTab(index){if(!ready.value||typeof index!=`number`||index<0||index>=tabsList.value.length||selectedIndex.value===index)return;let prevTab=tabsList.value[selectedIndex.value];tabsList.value.forEach(tab=>{tab.active=tab.index===index}),selectedIndex.value=index,emit$1(`change`,tabsList.value[index],prevTab)}return provide(`selectTab`,selectTab),__expose({goNext:()=>selectTab((selectedIndex.value+1)%tabsList.value.length),goPrev:()=>selectTab(Math.abs(selectedIndex.value-1)%tabsList.value.length),selectTab}),onMounted(()=>{ready.value=!0,nextTick(update$6)}),(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$339,[tabListStart.value?(openBlock(),createBlock(resolveDynamicComponent(tabListStart.value),{key:0})):createCommentVNode(``,!0),tabsContent.value[selectedIndex.value]?(openBlock(),createBlock(resolveDynamicComponent(tabsContent.value[selectedIndex.value]),{key:1,class:`tab-content`})):createCommentVNode(``,!0),tabListEnd.value?(openBlock(),createBlock(resolveDynamicComponent(tabListEnd.value),{key:2})):createCommentVNode(``,!0)]))}},tabs_default=__plugin_vue_export_helper_default(_sfc_main$391,[[`__scopeId`,`data-v-2ff63a4f`]]),_sfc_main$390={__name:`textScroller`,props:{scrollSpeed:{type:Number,default:3},initialPause:{type:Number,default:1},endingPause:{type:Number,default:1},fadeDuration:{type:Number,default:.2},watchContent:{type:Boolean,default:!1}},setup(__props){let props=__props,slots=useSlots(),events$3={start:[`uinav-focus`,`focus`,`mouseenter`],stop:[`uinav-blur`,`blur`,`mouseleave`]},elContainer=ref(null),elText=ref(null),scrollDistance=ref(0),translateX=ref(0),opacity=ref(1),isActive=ref(!1),isScrolling$1=ref(!1),styleOverrides={"button-icon":`.bng-button.l-icon, .bng-button.r-icon`},overrideClasses=ref([]),parentElement=null,fontSize=ref(16),scrollSpeed=computed(()=>props.scrollSpeed*fontSize.value),animTimer=null,animTimeout=(func,ms)=>(animTimer&&=(clearTimeout(animTimer),null),typeof func==`function`?(animTimer=setTimeout(()=>{animTimer=null,isScrolling$1.value&&func()},ms),animTimer):null),scrollStyles=computed(()=>({transform:`translateX(${translateX.value}px)`,opacity:opacity.value,transition:`opacity ${props.fadeDuration}s linear`+(isScrolling$1.value&&opacity.value>0?`, transform ${scrollDistance.value/scrollSpeed.value}s linear`:``)}));function animLoop(){isScrollable()&&(scrollDistance.value=getSize(),!(scrollDistance.value<=0)&&(opacity.value=1,animTimeout(()=>{translateX.value=-scrollDistance.value,animTimeout(()=>{opacity.value=0,animTimeout(()=>{translateX.value=0,nextTick(animLoop)},props.fadeDuration*1e3)},scrollDistance.value/scrollSpeed.value*1e3+props.endingPause*1e3)},Math.max(props.initialPause,props.fadeDuration)*1e3)))}function isScrollable(){if(!elContainer.value||!elText.value)return!1;let containerWidth=elContainer.value.clientWidth;return elText.value.scrollWidth>containerWidth}function getSize(){if(!elContainer.value||!elText.value)return 0;let containerWidth=elContainer.value.clientWidth,textWidth=elText.value.scrollWidth;return Math.max(0,textWidth-containerWidth)}function animStart(){isActive.value=!0,isScrollable()&&(isScrolling$1.value=!0,translateX.value=0,opacity.value=1,animLoop())}function animStop(restartAnim=!1){isActive.value=!1,isScrolling$1.value=!1,animTimeout(),nextTick(()=>{translateX.value=0,opacity.value=1,typeof restartAnim==`boolean`&&restartAnim&&nextTick(animStart)})}return props.watchContent&&watch(()=>slots.default?.(),()=>animStop(isActive.value),{deep:!0}),watch([()=>scrollSpeed.value,()=>props.initialPause,()=>props.endingPause,()=>props.fadeDuration],()=>animStop(isActive.value)),watch(()=>elContainer.value,()=>{if(!elContainer.value)return;for(parentElement=elContainer.value.parentElement;parentElement&&!parentElement.matches(`[is-bng-panel], [bng-nav-item], [ng-click], [href], [bng-all-clicks], [bng-all-clicks-no-nav], [ui-sref], input, textarea, button, md-option, md-slider, md-select, md-checkbox`);)if(parentElement=parentElement.parentElement,parentElement===document.body){parentElement=null;break}if(!parentElement)return;overrideClasses.value=[];for(let[key,selectors]of Object.entries(styleOverrides))parentElement.matches(selectors)&&overrideClasses.value.push(`bng-text-override--${key}`);let fSize=window.getComputedStyle(elContainer.value,null).fontSize;fontSize.value=+fSize.substring(0,fSize.length-2),events$3.start.forEach(event=>parentElement.addEventListener(event,animStart)),events$3.stop.forEach(event=>parentElement.addEventListener(event,animStop))},{immediate:!0}),onUnmounted(()=>{animTimeout(),parentElement&&(events$3.start.forEach(event=>parentElement.removeEventListener(event,animStart)),events$3.stop.forEach(event=>parentElement.removeEventListener(event,animStop)))}),(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,{ref_key:`elContainer`,ref:elContainer,class:normalizeClass([`bng-text-scroller`,[{"is-scrolling":isScrolling$1.value},...overrideClasses.value]])},[createBaseVNode(`div`,{ref_key:`elText`,ref:elText,class:`scroller-text`,style:normalizeStyle(scrollStyles.value)},[renderSlot(_ctx.$slots,`default`,{},void 0,!0)],4)],2))}},textScroller_default=__plugin_vue_export_helper_default(_sfc_main$390,[[`__scopeId`,`data-v-4f311fae`]]),_hoisted_1$338=[`data-tree-node-key`,`data-tree-node-expanded`,`data-tree-node-selected`,`data-tree-node-parent-path`,`data-tree-node-path`],_hoisted_2$268={key:1,class:`node`},_hoisted_3$234=[`disabled`],_hoisted_4$199={key:2,"data-tree-node-children":``},_sfc_main$389={__name:`treeNode`,props:{node:{type:Object,required:!0},keyName:{type:String,required:!0},parentNode:Object,selectMode:String,expandMode:String,expandedKeys:Array,selectedKeys:Array,parentPath:Array},setup(__props){let props=__props,$templates=inject(`$templates`),_expandFn=inject(`expandFn`),_selectFn=inject(`selectFn`),expanded=computed(()=>props.expandMode===`prop`?props.node.expanded:props.expandedKeys&&props.expandedKeys.includes(props.node[props.keyName])),expandable=computed(()=>!props.node.disabled&&props.node.children&&props.node.children.length>0),selected=computed(()=>props.selectMode?props.selectMode===`prop`?props.node.selected:props.selectedKeys&&props.selectedKeys.includes(props.node[props.keyName]):!1),selectable=computed(()=>!props.node.disabled&&props.selectMode&&props.node.selectable!==!1),path=computed(()=>props.parentPath?props.parentPath.concat(props.node[props.keyName]):[props.node[props.keyName]]),parentPathString=computed(()=>props.parentPath?props.parentPath.join(`/`):null),pathString=computed(()=>path.value.join(`/`)),nodeProps=computed(()=>({path:path.value,parentPath:props.parentPath}));return(_ctx,_cache)=>{let _component_TreeNode=resolveComponent(`TreeNode`,!0);return openBlock(),createElementBlock(`li`,{"data-tree-node-key":__props.node[__props.keyName],"data-tree-node-expanded":expanded.value,"data-tree-node-selected":selected.value,"data-tree-node-parent-path":parentPathString.value,"data-tree-node-path":pathString.value,"data-tree-node":``},[unref($templates).node?(openBlock(),createBlock(resolveDynamicComponent(unref($templates).node),{key:0,node:__props.node,parentNode:__props.parentNode,expanded:expanded.value,selected:selected.value,expand:()=>expandable.value?unref(_expandFn)(__props.node,nodeProps.value):{},select:()=>selectable.value?unref(_selectFn)(__props.node,nodeProps.value):{}},null,8,[`node`,`parentNode`,`expanded`,`selected`,`expand`,`select`])):(openBlock(),createElementBlock(`div`,_hoisted_2$268,[__props.node.children&&unref($templates).toggle?(openBlock(),createBlock(resolveDynamicComponent(unref($templates).toggle),{key:0,node:__props.node,parentNode:__props.parentNode,expanded:expanded.value,selected:selected.value,expand:()=>expandable.value?unref(_expandFn)(__props.node,nodeProps.value):{}},null,8,[`node`,`parentNode`,`expanded`,`selected`,`expand`])):(openBlock(),createElementBlock(`span`,{key:1,class:`node-toggle`,onClick:_cache[0]||=()=>expandable.value?unref(_expandFn)(__props.node,nodeProps.value):{},disabled:__props.node.disabled},[__props.node.children?(openBlock(),createBlock(unref(bngIcon_default),{key:0,"bng-nav-item":``,type:expanded.value?unref(icons).arrowSmallDown:unref(icons).arrowSmallRight},null,8,[`type`])):createCommentVNode(``,!0)],8,_hoisted_3$234)),unref($templates).content?(openBlock(),createBlock(resolveDynamicComponent(unref($templates).content),{key:2,node:__props.node,parentNode:__props.parentNode,expanded:expanded.value,selected:selected.value,expand:()=>expandable.value?unref(_expandFn)(__props.node,nodeProps.value):{},select:()=>selectable.value?unref(_selectFn)(__props.node,nodeProps.value):{}},null,8,[`node`,`parentNode`,`expanded`,`selected`,`expand`,`select`])):(openBlock(),createElementBlock(`span`,{key:3,"bng-nav-item":``,class:`node-content`,onClick:_cache[1]||=()=>selectable.value?unref(_selectFn)(__props.node,nodeProps.value):{}},toDisplayString(__props.node.label),1))])),expanded.value&&__props.node.children?(openBlock(),createElementBlock(`ul`,_hoisted_4$199,[(openBlock(!0),createElementBlock(Fragment,null,renderList(__props.node.children,childNode=>(openBlock(),createBlock(_component_TreeNode,{key:childNode[__props.keyName],node:childNode,parentNode:__props.node,keyName:__props.keyName,selectMode:__props.selectMode,expandMode:__props.expandMode,expandedKeys:__props.expandedKeys,selectedKeys:__props.selectedKeys,parentPath:path.value},null,8,[`node`,`parentNode`,`keyName`,`selectMode`,`expandMode`,`expandedKeys`,`selectedKeys`,`parentPath`]))),128))])):createCommentVNode(``,!0)],8,_hoisted_1$338)}}},treeNode_default=__plugin_vue_export_helper_default(_sfc_main$389,[[`__scopeId`,`data-v-aeb14cdb`]]),_hoisted_1$337={class:`tree`},SELECT_SINGLE=`single`,SELECT_MULTIPLE=`multi`,SELECT_PROP=`prop`,SELECT_MODES=[SELECT_SINGLE,SELECT_MULTIPLE,SELECT_PROP],EXPAND_MODEL=`model`,EXPAND_PROP=`prop`,EXPAND_MODES=[EXPAND_MODEL,EXPAND_PROP],_sfc_main$388={__name:`tree`,props:mergeModels({nodes:{type:Array,required:!0},keyName:{type:String,default:`key`},expandMode:{type:String,default:EXPAND_MODEL,validator(value){return EXPAND_MODES.includes(value)}},selectMode:{type:String,validator(value){return SELECT_MODES.includes(value)}}},{expandedKeys:{},expandedKeysModifiers:{},selectedKeys:{},selectedKeysModifiers:{}}),emits:mergeModels([`update:expandedKeys`,`node-expanded`,`node-collapsed`,`expanded-keys-changed`,`node-selected`,`node-unselected`,`selected-keys-changed`],[`update:expandedKeys`,`update:selectedKeys`]),setup(__props,{emit:__emit}){let props=__props,expandedKeys=useModel(__props,`expandedKeys`),selectedKeys=useModel(__props,`selectedKeys`),emit$1=__emit;onBeforeMount(()=>{provide(`$templates`,useSlots()),provide(`expandFn`,expand),provide(`selectFn`,select)});function expand(node,nodeProps){let nodeKey=node[props.keyName];if(props.expandMode===EXPAND_PROP)node.expanded?emit$1(`node-collapsed`,node,nodeProps):emit$1(`node-expanded`,node,nodeProps);else{if(!expandedKeys.value)throw Error(`v-model:expandedKeys must be set`);let expanded=expandedKeys.value.includes(nodeKey),updatedExpandedKeys;expanded?(updatedExpandedKeys=expandedKeys.value.filter(x=>x!==nodeKey),emit$1(`node-collapsed`,node,nodeProps)):(updatedExpandedKeys=[...expandedKeys.value,nodeKey],emit$1(`node-expanded`,node,nodeProps)),expandedKeys.value=updatedExpandedKeys,emit$1(`expanded-keys-changed`,updatedExpandedKeys)}}function select(node,nodeProps){console.log(`select`,node);let nodeKey=node[props.keyName];if(props.selectMode===SELECT_PROP)node.selected?emit$1(`node-selected`,node,nodeProps):emit$1(`node-unselected`,node,nodeProps);else{if(!selectedKeys.value)throw Error(`v-model:selectedKeys must be set`);let selected=selectedKeys.value.includes(nodeKey),updatedSelectedKeys;selected?(updatedSelectedKeys=selectedKeys.value.filter(x=>x!==nodeKey),emit$1(`node-unselected`,node,nodeProps)):props.selectMode===`single`?(updatedSelectedKeys=[nodeKey],emit$1(`node-selected`,node,nodeProps)):props.selectMode===`multi`&&(updatedSelectedKeys=[...selectedKeys.value,nodeKey],emit$1(`node-selected`,node,nodeProps)),selectedKeys.value=updatedSelectedKeys,emit$1(`selected-keys-changed`,updatedSelectedKeys)}}return(_ctx,_cache)=>(openBlock(),createElementBlock(`ul`,_hoisted_1$337,[(openBlock(!0),createElementBlock(Fragment,null,renderList(__props.nodes,node=>(openBlock(),createBlock(treeNode_default,{key:node[__props.keyName],node,keyName:__props.keyName,selectMode:__props.selectMode,expandMode:__props.expandMode,expandedKeys:expandedKeys.value,selectedKeys:selectedKeys.value},null,8,[`node`,`keyName`,`selectMode`,`expandMode`,`expandedKeys`,`selectedKeys`]))),128))]))}},tree_default=__plugin_vue_export_helper_default(_sfc_main$388,[[`__scopeId`,`data-v-7363528a`]]);const DEMOS$1={};var utility_exports=__export({Accordion:()=>accordion_default,AccordionItem:()=>accordionItem_default,AccordionTree:()=>accordionTree_default,AspectRatio:()=>aspectRatio_default,Carousel:()=>carousel_default,CarouselItem:()=>carouselItem_default,DEMOS:()=>DEMOS$1,DRAWER_POSITION:()=>DRAWER_POSITION,Drawer:()=>drawer_default,DynamicComponent:()=>dynamicComponent_default,Shelf:()=>shelf_default,SlotSwitcher:()=>slotSwitcher_default,Tab:()=>tab_default,TabList:()=>tabList_default,Tabs:()=>tabs_default,TextScroller:()=>textScroller_default,Tree:()=>tree_default,TreeNode:()=>treeNode_default}),_hoisted_1$336={class:`actions-drawer`},_sfc_main$387={__name:`bngActionsDrawer`,props:{header:{type:String,required:!0},headerActions:Array,showHeaderActions:{type:Boolean,default:!0},grouped:Boolean,actions:{type:[Array,Object],required:!0},selected:{type:[String,Number]},expanded:Boolean},emits:[`actionClick`,`headerActionClicked`,`categoryChanged`],setup(__props,{emit:__emit}){let emit$1=__emit,onActionClicked=action=>emit$1(`actionClick`,action);return(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$336,[createVNode(unref(bngDrawerOld_default),null,createSlots({header:withCtx(()=>[createTextVNode(toDisplayString(__props.header),1)]),content:withCtx(()=>[__props.grouped?(openBlock(),createBlock(unref(tabs_default),{key:0,class:`categories-tab bng-tabs`},{default:withCtx(()=>[(openBlock(!0),createElementBlock(Fragment,null,renderList(__props.actions,category=>(openBlock(),createBlock(unref(tab_default),{key:category.category,heading:category.category},{default:withCtx(()=>[(openBlock(),createBlock(unref(bngActionsList_default),{key:category.category,actions:category.items,selected:__props.selected,class:normalizeClass({expanded:__props.expanded}),onActionClick:_cache[0]||=value=>onActionClicked(value)},null,8,[`actions`,`selected`,`class`]))]),_:2},1032,[`heading`]))),128))]),_:1})):(openBlock(),createBlock(unref(bngActionsList_default),{key:1,actions:__props.actions,selected:__props.selected,class:normalizeClass({expanded:__props.expanded}),onActionClick:_cache[1]||=value=>onActionClicked(value)},null,8,[`actions`,`selected`,`class`]))]),_:2},[__props.showHeaderActions&&__props.headerActions?{name:`headerOptions`,fn:withCtx(()=>[(openBlock(!0),createElementBlock(Fragment,null,renderList(__props.headerActions,action=>(openBlock(),createBlock(unref(bngButton_default),{key:action.value,tabindex:`1`,accent:action.accent,onClick:$event=>_ctx.$emit(`headerActionClicked`,action.value)},{default:withCtx(()=>[createTextVNode(toDisplayString(action.label),1)]),_:2},1032,[`accent`,`onClick`]))),128))]),key:`0`}:void 0]),1024)]))}},bngActionsDrawer_default=__plugin_vue_export_helper_default(_sfc_main$387,[[`__scopeId`,`data-v-b433a352`]]),_hoisted_1$335={class:`header-wrapper`},_hoisted_2$267={class:`drawer-content`},_hoisted_3$233={key:0,class:`filters-wrapper`},_hoisted_4$198={class:`drawer-actions-wrapper`},_hoisted_5$168={key:0,class:`action-divider`},_hoisted_6$143={key:1,class:`progress-indicator`},_sfc_main$386={__name:`bngActionsDrawerOne`,props:{value:{type:Object,required:!0},flattenChildren:Boolean,allowOpenDrawer:Boolean,openDrawerLabel:String,closeDrawerLabel:String,loading:Boolean,header:String,blur:Boolean},emits:[`update:currentActionPath`,`update:loading`,`actionClicked`,`actionItemChanged`,`drawerOpened`],setup(__props,{emit:__emit}){let props=__props,emit$1=__emit,drawerState=reactive({isOpenCatalog:!1,currentPath:[],drawerFilters:[]}),currentActionPath=computed({get:()=>drawerState.currentPath,set:newValue=>{drawerState.currentPath=newValue}}),parentAction=computed(()=>{if(!currentActionPath.value||currentActionPath.value.length===0)return null;let currentAction$1=props.value;for(let key of currentActionPath.value.slice(0,-1))currentAction$1=currentAction$1.items.find(x=>x.value===key);return currentAction$1}),currentAction=computed(()=>{let currentAction$1=props.value;for(let key of currentActionPath.value)currentAction$1=currentAction$1.items.find(x=>x.value===key);return currentAction$1}),isDrawerOpen=computed({get:()=>drawerState.isOpenCatalog,set:newValue=>{drawerState.isOpenCatalog=newValue,emit$1(`drawerOpened`,newValue)}}),loading=computed({get:()=>props.loading,set:newValue=>emit$1(`update:loading`,newValue)}),canViewCatalogDisplayMode=computed(()=>(console.log(`canViewCatalogDisplayMode`),loading.value===!0||currentAction.value.allowOpenDrawer===!1?!1:(console.log(`currentAction`,currentAction.value),currentAction.value.items.every(x=>x.lazyLoadItems===!0||x.items)))),drawerFilterValue=computed({get:()=>drawerState.drawerFilters&&drawerState.drawerFilters.length>0?drawerState.drawerFilters[0]:null,set:newValue=>{drawerState.drawerFilters=newValue?[newValue]:[]}}),catalogFilters=computed(()=>{let activeAction=isDrawerOpen.value?parentAction.value:currentAction.value;return activeAction.items.every(x=>x.items&&x.items.length>0||x.lazyLoadItems)?activeAction.items.map(x=>({label:x.label,value:x.value})):[]}),showBackButton=computed(()=>currentActionPath.value.length>0);watch(drawerFilterValue,(newValue,oldValue)=>{console.log(`drawerFilterValue`,newValue,oldValue),newValue&&!oldValue?currentActionPath.value=[...currentActionPath.value,newValue]:newValue&&oldValue?currentActionPath.value=[...currentActionPath.value.slice(0,-1),newValue]:!newValue&&oldValue&&(currentActionPath.value=[...currentActionPath.value].slice(0,-1))}),watch(currentActionPath,()=>{emit$1(`actionItemChanged`,currentAction.value,currentActionPath.value)});let selectAction=actionItem=>{(actionItem.items&&actionItem.items.length>0||actionItem.lazyLoadItems===!0)&&(isDrawerOpen.value&&=!1,currentActionPath.value=[...currentActionPath.value,actionItem.value]),emit$1(`actionClicked`,actionItem)},toggleOpenCatalog=()=>{isDrawerOpen.value?closeDrawer():openDrawer()},goBack=()=>{isDrawerOpen.value?closeDrawer():currentActionPath.value=[...currentActionPath.value].slice(0,-1)};function openDrawer(){drawerFilterValue.value=catalogFilters.value[0].value,isDrawerOpen.value=!0}function closeDrawer(){drawerFilterValue.value=null,isDrawerOpen.value=!1}return(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,{class:normalizeClass([`bng-actions-drawer`,{expanded:isDrawerOpen.value}])},[createVNode(unref(bngDrawerOld_default),{blur:__props.blur,class:`bng-drawer`},{header:withCtx(()=>[renderSlot(_ctx.$slots,`header`,{actionItem:currentAction.value,canGoBack:showBackButton.value,goBack},()=>[createBaseVNode(`div`,_hoisted_1$335,[showBackButton.value?(openBlock(),createBlock(unref(bngButton_default),{key:0,icon:unref(icons).arrowLargeLeft,accent:unref(ACCENTS).secondary,class:`back-btn`,onClick:goBack},{default:withCtx(()=>[..._cache[1]||=[createTextVNode(`Back`,-1)]]),_:1},8,[`icon`,`accent`])):createCommentVNode(``,!0),createTextVNode(` `+toDisplayString(currentAction.value.label),1)])],!0)]),content:withCtx(()=>[createBaseVNode(`div`,_hoisted_2$267,[drawerState.isOpenCatalog&&catalogFilters.value.length>0?(openBlock(),createElementBlock(`div`,_hoisted_3$233,[createVNode(unref(bngPillFilters_default),{modelValue:drawerState.drawerFilters,"onUpdate:modelValue":_cache[0]||=$event=>drawerState.drawerFilters=$event,options:catalogFilters.value},null,8,[`modelValue`,`options`])])):createCommentVNode(``,!0),createBaseVNode(`div`,_hoisted_4$198,[createBaseVNode(`div`,{class:normalizeClass([`drawer-actions`,{expanded:drawerState.isOpenCatalog}])},[loading.value?(openBlock(),createElementBlock(`div`,_hoisted_6$143,[..._cache[2]||=[createBaseVNode(`div`,{class:`loader`},null,-1)]])):(openBlock(!0),createElementBlock(Fragment,{key:0},renderList(currentAction.value.items,action=>(openBlock(),createElementBlock(Fragment,{key:action.value},[action.type===`actionDivider`?(openBlock(),createElementBlock(`div`,_hoisted_5$168,toDisplayString(action.label),1)):renderSlot(_ctx.$slots,`item`,{key:1,actionItem:action,onClick:()=>selectAction(action)},()=>[createVNode(unref(bngImageTile_default),{label:action.label,icon:action.icon,onClick:$event=>selectAction(action)},null,8,[`label`,`icon`,`onClick`])],!0)],64))),128))],2)]),canViewCatalogDisplayMode.value?renderSlot(_ctx.$slots,`footer`,{key:1},()=>[createVNode(unref(bngButton_default),{class:`catalog-btn`,accent:unref(ACCENTS).outlined,onClick:toggleOpenCatalog},{default:withCtx(()=>[drawerState.isOpenCatalog?(openBlock(),createElementBlock(Fragment,{key:0},[createTextVNode(toDisplayString(__props.closeDrawerLabel?__props.closeDrawerLabel:`Collapse catalog`),1)],64)):(openBlock(),createElementBlock(Fragment,{key:1},[createTextVNode(toDisplayString(__props.openDrawerLabel?__props.openDrawerLabel:`Open full catalog`),1)],64))]),_:1},8,[`accent`])],!0):createCommentVNode(``,!0)])]),_:3},8,[`blur`])],2))}},bngActionsDrawerOne_default=__plugin_vue_export_helper_default(_sfc_main$386,[[`__scopeId`,`data-v-529c2a59`]]),_hoisted_1$334={class:`actions`},_sfc_main$385={__name:`bngActionsList`,props:{actions:{type:Array,required:!0},selected:{type:[String,Number],required:!1}},emits:[`actionClick`],setup(__props,{emit:__emit}){let emit$1=__emit;return(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$334,[(openBlock(!0),createElementBlock(Fragment,null,renderList(__props.actions,action=>(openBlock(),createBlock(unref(bngImageTile_default),mergeProps({class:`action-tile`,tabindex:`0`,key:action.value},{ref_for:!0},action,{"bng-nav-item":``,onClick:$event=>emit$1(`actionClick`,action.value)}),null,16,[`onClick`]))),128))]))}},bngActionsList_default=__plugin_vue_export_helper_default(_sfc_main$385,[[`__scopeId`,`data-v-8790d45d`]]),_hoisted_1$333=[`ui-event`],_hoisted_2$266={key:0},_hoisted_3$232={key:3,class:`combo-separator`},MULTI_ID=`[PLUS]`,MULTI_LABEL=`+`,_sfc_main$384={__name:`bngBinding`,props:{action:String,showUnassigned:Boolean,device:[String,Array],deviceKey:String,dark:Boolean,deviceMask:[String,Function],controller:Boolean,uiEvent:String,trackIgnore:Boolean,unassignedText:{default:`[N/A]`,type:String},viewerObj:Object,imagePack:String,actionVariants:Boolean,useLastDevice:{type:Boolean,default:!0},vertical:Boolean},setup(__props,{expose:__expose}){let $simplemenu=inject(`$simplemenu`),Controls=controls_default(),{showIfController,lastControllersSignature}=storeToRefs(Controls),props=__props,iconColors={dark:`var(--bng-off-black)`,light:`var(--bng-off-white)`},iconColor=computed(()=>iconColors[props.dark?`dark`:`light`]);computed(()=>iconColors[props.dark?`light`:`dark`]);let controllerOnly=computed(()=>props.controller||$simplemenu.value),LABELS_BIG=[`enter`,`tab`,`capslock`,`backspace`,`lshift`,`rshift`,`left`,`right`,`up`,`down`,`space`,`grave`,`comma`,`period`].map(c=>CONTROL_LABELS[c]||c),LABELS_OFFSET=[`space`].map(c=>CONTROL_LABELS[c]||c),rgxSanitize$1=s=>s.replace(/[-.+*$^?:|[\](){}]/g,`\\$&`),LABELS_RGX=RegExp(`(`+[MULTI_ID,...LABELS_BIG,...LABELS_OFFSET].map(rgxSanitize$1).join(`|`)+`)`,`g`),viewerObj=computed(()=>{if(props.viewerObj)return props.viewerObj;if(controllerOnly.value&&showIfController.value){let opts={...props};return opts.controller=!0,opts._controllerSignature=lastControllersSignature.value,Controls.makeViewerObj(opts)}return Controls.makeViewerObj(props)}),viewerVariants=computed(()=>{if(!viewerObj.value)return[];let variants=viewerObj.value.variants||[viewerObj.value];variants=variants.map(obj=>obj.multiControls||[obj]);for(let objs of variants)for(let obj of objs)if(obj&&(!obj.special||obj.ownLabel)&&!obj.controlSegments){let control=obj.ownLabel||obj.control;control=control.replace(/ \+ /g,MULTI_ID),obj.controlSegments=String(control).split(LABELS_RGX).filter(Boolean).map(segment=>({value:segment===MULTI_ID?MULTI_LABEL:segment,class:(LABELS_BIG.includes(segment)?`label-bigger `:``)+(LABELS_OFFSET.includes(segment)?`label-offset `:``)+(segment===MULTI_ID?`label-multi `:``)}))}return variants}),display=computed(()=>{let res=!!viewerObj.value;if(viewerObj.value)if(props.deviceMask){let dev=viewerObj.value.devName;res=typeof props.deviceMask==`function`?props.deviceMask(dev):dev.startsWith(props.deviceMask)}else controllerOnly.value&&(res=showIfController.value);return res||props.showUnassigned});__expose({displayed:display});let eventName=computed(()=>props.action?props.action:props.uiEvent?props.uiEvent:null),uiNavTracker=useUINavTracker(),ownerId$1=uniqueId(`bngBinding`),trackedEvent=``,track$1=(eventName$1=null)=>{if(trackedEvent&&=(uiNavTracker.removeIgnore(trackedEvent,ownerId$1),``),!(props.trackIgnore||!display.value)&&eventName$1){if(trackedEvent===eventName$1)return;trackedEvent=eventName$1,uiNavTracker.addIgnore(trackedEvent,ownerId$1)}};return watch(()=>props.trackIgnore,val=>track$1(val?null:eventName.value)),watch(display,()=>track$1(eventName.value)),watch(eventName,(val,prev)=>{prev&&track$1(),val&&track$1(val)}),onMounted(()=>track$1(eventName.value)),onUnmounted(()=>track$1()),(_ctx,_cache)=>display.value?(openBlock(),createElementBlock(`span`,{key:0,class:normalizeClass([`binding-wrapper`,{"binding-theme-dark":__props.dark,"binding-theme-light":!__props.dark,"with-variants":viewerVariants.value.length>1,vertical:__props.vertical}]),"ui-event":__props.uiEvent},[(openBlock(!0),createElementBlock(Fragment,null,renderList(viewerVariants.value,(viewerObjs,index)=>(openBlock(),createElementBlock(`span`,{key:index,class:normalizeClass([`binding-container`,{"combo-binding":viewerObjs.length>1}])},[(openBlock(!0),createElementBlock(Fragment,null,renderList(viewerObjs,(viewerObj$1,index$1)=>(openBlock(),createElementBlock(Fragment,{key:index$1},[viewerObj$1&&viewerObj$1.controlSegments?(openBlock(),createElementBlock(`kbd`,_hoisted_2$266,[(openBlock(!0),createElementBlock(Fragment,null,renderList(viewerObj$1.controlSegments,(seg,i)=>(openBlock(),createElementBlock(`span`,{key:i,class:normalizeClass(seg.class)},toDisplayString(seg.value),3))),128))])):viewerObj$1&&viewerObj$1.special?(openBlock(),createBlock(unref(bngIcon_default),{key:1,class:`bng-binding-icon`,type:unref(icons)[viewerObj$1.ownIcon],color:iconColor.value},null,8,[`type`,`color`])):!viewerObj$1&&__props.showUnassigned?(openBlock(),createBlock(unref(bngIcon_default),{key:2,class:`bng-binding-icon n-a`,type:unref(icons).NA,color:iconColor.value},null,8,[`type`,`color`])):createCommentVNode(``,!0),index$1Number(val)>0},simple:Boolean,blur:Boolean,disableLastItem:Boolean,showBackButton:Boolean,showBackBinding:{type:Boolean,default:!0},navigable:{type:Boolean,default:!0}},emits:[`click`,`back`],setup(__props,{emit:__emit}){let bid=uniqueId(`bng-path`),emit$1=__emit,props=__props,pathView=computed(()=>{if(!Array.isArray(props.items))return[];let mapItem=itm=>({label:itm.label,items:itm.items,data:itm,dividerType:itm.dividerType}),items$2=props.items.map(mapItem),res=props.limit?items$2.slice(-props.limit):items$2;if(!props.simple){let looseCmp=(a$1,b)=>a$1.label===b.label&&a$1.value===b.value,len=res.length;for(let i=1;ilooseCmp(itm,res[idx])),items:items$3.map(mapItem)})}}return props.limit&&items$2.length>props.limit&&res.unshift({label:`…`,data:items$2[items$2.length-props.limit-1]}),res.length>0&&(res[0].first=!0,res.at(-1).last=!0),res});function onClick(item,index){(!props.disableLastItem||index(openBlock(),createElementBlock(`div`,{class:`bng-path`,"bng-no-child-nav":!__props.navigable},[__props.showBackButton?(openBlock(),createBlock(unref(bngButton_default),{key:0,class:`back-button`,accent:unref(ACCENTS).custom,onClick:_cache[0]||=$event=>emit$1(`back`),tabindex:`1`},{default:withCtx(()=>[createVNode(unref(bngIcon_default),{type:unref(icons).arrowSmallLeft,class:`back-icon`},null,8,[`type`]),__props.showBackBinding?(openBlock(),createBlock(unref(bngBinding_default),{key:0,"ui-event":`back`,controller:``,"track-ignore":``})):createCommentVNode(``,!0),createTextVNode(` `+toDisplayString(_ctx.$tt(`ui.common.back`)),1)]),_:1},8,[`accent`])):createCommentVNode(``,!0),(openBlock(!0),createElementBlock(Fragment,null,renderList(pathView.value,(item,index)=>(openBlock(),createElementBlock(Fragment,{key:index},[item.dropdown?(openBlock(),createElementBlock(Fragment,{key:1},[withDirectives(createVNode(unref(bngButton_default),{class:`bng-path-item bng-path-has-dropdown`,accent:unref(ACCENTS).text,icon:unref(icons).arrowSmallRight},null,8,[`accent`,`icon`]),[[unref(BngBlur_default),__props.blur],[unref(BngPopover_default),item.dropdown,`bottom-start`,{click:!0}]]),createVNode(unref(bngPopoverMenu_default),{name:item.dropdown,focus:``},{default:withCtx(({hide:hide$2})=>[(openBlock(!0),createElementBlock(Fragment,null,renderList(item.items,(subitem,idx)=>withDirectives((openBlock(),createBlock(unref(bngButton_default),{key:idx,class:normalizeClass({selected:idx===item.selected}),accent:unref(ACCENTS).menu,onClick:$event=>onMenuClick(subitem,hide$2)},{default:withCtx(()=>[createTextVNode(toDisplayString(subitem.label),1)]),_:2},1032,[`class`,`accent`,`onClick`])),[[unref(BngOnUiNav_default),void 0,`ok`,{focusRequired:!0,asMouse:!0}]])),128))]),_:2},1032,[`name`])],64)):(openBlock(),createElementBlock(Fragment,{key:0},[withDirectives((openBlock(),createBlock(unref(bngButton_default),{class:normalizeClass([`bng-path-item`,{"bng-path-simple":__props.simple,"bng-path-disabled":__props.disableLastItem&&item.last,"bng-path-first":item.first,"bng-path-last":item.last}]),accent:unref(ACCENTS).text,onClick:$event=>onClick(item,index)},{default:withCtx(()=>[createTextVNode(toDisplayString(item.label),1)]),_:2},1032,[`class`,`accent`,`onClick`])),[[unref(BngBlur_default),__props.blur]]),__props.simple&&!item.last?(openBlock(),createElementBlock(`div`,_hoisted_2$265,[withDirectives(createVNode(unref(bngIcon_default),{type:item.dividerType||unref(icons).slashRight},null,8,[`type`]),[[unref(BngBlur_default),__props.blur]])])):createCommentVNode(``,!0)],64))],64))),128))],8,_hoisted_1$332))}},bngBreadcrumbs_default=__plugin_vue_export_helper_default(_sfc_main$383,[[`__scopeId`,`data-v-4a2e18d5`]]),_hoisted_1$331=[`accent`,`disabled`],_hoisted_2$264={key:0,class:`hold-arrow`,xmlns:`http://www.w3.org/2000/svg`,viewBox:`0 0 16 12`,preserveAspectRatio:`xMidYMid`},_hoisted_3$231={key:3,class:`label`},_hoisted_4$197={key:5,class:`label`},_hoisted_5$167={key:6};const ACCENTS={main:`main`,secondary:`secondary`,outlined:`outlined`,text:`text`,attention:`attention`,attentionghost:`attentionghost`,attentionoutlined:`attentionoutlined`,ghost:`ghost`,menu:`menu`,custom:`custom`};var _sfc_main$382={__name:`bngButton`,props:{accent:{type:String,default:`main`,validator:v=>Object.values(ACCENTS).includes(v)||v===``},iconLeft:[Object,String],iconRight:[Object,String],label:String,icon:[Object,String],externalIcon:String,showHold:Boolean,holdVertical:Boolean,disabled:Boolean,noSound:Boolean},setup(__props,{expose:__expose}){let slots=useSlots(),uiNavEvent=ref(),btnDOMElRef=ref(),attrs=useAttrs(),useOldIcons=computed(()=>`oldIcons`in attrs);watchUINavEventChange(btnDOMElRef,({eventName,action})=>{}),__expose({getElement(){return btnDOMElRef.value}});let isPlainTextSlot=ref(!1);function checkIfPlainText(){let slotContent=slots.default?slots.default():[];isPlainTextSlot.value=slotContent.length===1&&typeof slotContent[0].type==`symbol`&&String(slotContent[0].type).indexOf(`v-txt`)>-1&&slotContent[0].children.trim().length>0}watch(()=>slots.default,checkIfPlainText),checkIfPlainText();let props=__props,needsFallbackHoldOffset=ref(!0);return watchEffect(()=>{btnDOMElRef.value&&props.accent===`custom`&&window.getComputedStyle(btnDOMElRef.value).getPropertyValue(`--bng-button-custom-hold-offset`).trim()&&(needsFallbackHoldOffset.value=!1)}),(_ctx,_cache)=>withDirectives((openBlock(),createElementBlock(`button`,{ref_key:`btnDOMElRef`,ref:btnDOMElRef,accent:__props.accent,class:normalizeClass({"show-hold":__props.showHold,"hold-vertical":__props.holdVertical,"bng-button":!0,empty:!unref(slots).default&&!__props.label,"l-icon":__props.iconLeft||__props.icon,"r-icon":__props.iconRight,"external-icon":__props.externalIcon,"fallback-hold-offset":props.accent===`custom`&&needsFallbackHoldOffset.value}),disabled:__props.disabled},[__props.showHold?(openBlock(),createElementBlock(`svg`,_hoisted_2$264,[..._cache[0]||=[createBaseVNode(`path`,{d:`M1,1 L8,2 L16,1 L8,11 z`},null,-1)]])):createCommentVNode(``,!0),useOldIcons.value&&(__props.iconLeft||__props.icon)?(openBlock(),createBlock(unref(bngOldIcon_default),{key:1,type:__props.iconLeft||__props.icon},null,8,[`type`])):!useOldIcons.value&&(__props.iconLeft||__props.icon||__props.externalIcon)?(openBlock(),createBlock(unref(bngIcon_default),{key:2,class:`icon`,type:__props.iconLeft||__props.icon,externalImage:__props.externalIcon},null,8,[`type`,`externalImage`])):createCommentVNode(``,!0),isPlainTextSlot.value?(openBlock(),createElementBlock(`span`,_hoisted_3$231,[renderSlot(_ctx.$slots,`default`,{},void 0,!0)])):isPlainTextSlot.value?createCommentVNode(``,!0):renderSlot(_ctx.$slots,`default`,{key:4},void 0,!0),__props.label&&!isPlainTextSlot.value?(openBlock(),createElementBlock(`span`,_hoisted_4$197,toDisplayString(__props.label),1)):createCommentVNode(``,!0),uiNavEvent.value?(openBlock(),createElementBlock(`span`,_hoisted_5$167,toDisplayString(uiNavEvent.value),1)):createCommentVNode(``,!0),useOldIcons.value&&__props.iconRight?(openBlock(),createBlock(unref(bngOldIcon_default),{key:7,span:``,type:__props.iconRight},null,8,[`type`])):!useOldIcons.value&&__props.iconRight?(openBlock(),createBlock(unref(bngIcon_default),{key:8,class:`icon`,type:__props.iconRight},null,8,[`type`])):createCommentVNode(``,!0),_cache[1]||=createBaseVNode(`div`,{class:`background`},null,-1)],10,_hoisted_1$331)),[[unref(BngSoundClass_default),!__props.disabled&&!__props.noSound&&`bng_click_hover_generic`]])}},bngButton_default=__plugin_vue_export_helper_default(_sfc_main$382,[[`__scopeId`,`data-v-8b356414`]]),_hoisted_1$330={class:`card-cnt`},ANIMATION_TYPES=[`fade`,`slide`],_sfc_main$381={__name:`bngCard`,props:{backgroundImage:String,footerStyles:Object,hideFooter:Boolean,animateFooter:Boolean,animateFooterType:{type:String,default:`fade`,validator:value=>ANIMATION_TYPES.includes(value)}},setup(__props,{expose:__expose}){useCssVars(_ctx=>({v3c03b7b2:backgroundImageStyle.value}));let props=__props,slots=useSlots(),hasFooter=computed(()=>(slots.footer||slots.buttons)&&!props.hideFooter),buttonsContainer=ref(),backgroundImageStyle=computed(()=>props.backgroundImage?`url('${props.backgroundImage}')`:``);return __expose({buttonsContainer}),(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,{class:normalizeClass([`bng-card bng-card-wrapper`,{"with-background-image":backgroundImageStyle.value}])},[createBaseVNode(`div`,_hoisted_1$330,[renderSlot(_ctx.$slots,`default`,{},()=>[_cache[0]||=createTextVNode(`BNG Card`,-1)],!0)]),createVNode(Transition,{name:__props.animateFooter?__props.animateFooterType:``},{default:withCtx(()=>[hasFooter.value?(openBlock(),createElementBlock(`div`,{key:0,ref_key:`buttonsContainer`,ref:buttonsContainer,class:`footer-container`,style:normalizeStyle(__props.footerStyles)},[renderSlot(_ctx.$slots,`buttons`,{},void 0,!0),renderSlot(_ctx.$slots,`footer`,{},void 0,!0)],4)):createCommentVNode(``,!0)]),_:3},8,[`name`])],2))}},bngCard_default=__plugin_vue_export_helper_default(_sfc_main$381,[[`__scopeId`,`data-v-32edaae4`]]),_sfc_main$380={__name:`bngCardHeading`,props:{type:{type:String,default:`line`,validator:v=>[`line`,`ribbon`,`none`].includes(v)||v===``},outline:{type:Boolean,default:!1}},setup(__props){return(_ctx,_cache)=>(openBlock(),createElementBlock(`h2`,{class:normalizeClass({"card-heading":!0,[`heading-style-${__props.type}`]:!0,outline:__props.outline})},[renderSlot(_ctx.$slots,`default`,{},()=>[_cache[0]||=createTextVNode(`BNG Card Heading`,-1)],!0)],2))}},bngCardHeading_default=__plugin_vue_export_helper_default(_sfc_main$380,[[`__scopeId`,`data-v-fc76db37`]]),_hoisted_1$329={key:0,class:`colour-picker-switch`};const VIEWS={simple:{slider:!0,picker:!1,saturation:!1,luminosity:!1},compact_saturation:{slider:!0,picker:!0,saturation:!0,luminosity:!1,compact:!0},compact_luminosity:{slider:!0,picker:!0,saturation:!1,luminosity:!0,compact:!0},saturation:{slider:!1,picker:!0,saturation:!0,luminosity:!1},luminosity:{slider:!1,picker:!0,saturation:!1,luminosity:!0},full_saturation:{slider:!0,picker:!0,saturation:!0,luminosity:!1},full_luminosity:{slider:!0,picker:!0,saturation:!1,luminosity:!0}};var valuesDef={hue:.5,saturation:1,luminosity:.5},_sfc_main$379={__name:`bngColorPicker`,props:{modelValue:{type:Object,default:{...valuesDef}},view:{type:[String,Object],default:`full_luminosity`,validator:val=>typeof val==`string`||val in VIEWS},showText:{type:Boolean,default:!0},step:{type:Number,default:.001},disabled:Boolean},emits:[`update:modelValue`,`change`],setup(__props,{emit:__emit}){let $simplemenu=inject(`$simplemenu`),props=__props,sliderIndicator=`popout`,pickerMode=ref(`luminosity`),opts=ref({}),values=reactive({...valuesDef}),colorDot=ref({x:0,y:0});watch([()=>props.view,$simplemenu],()=>{if(typeof props.view==`string`)for(let key in VIEWS[props.view])opts.value[key]=VIEWS[props.view][key];else opts.value={...VIEWS[props.view]};$simplemenu.value?(opts.value.picker=!1,opts.value.compact&&(opts.value.slider=!0)):opts.value.compact&&loadCompactMode(),opts.value.picker&&setColorDot()},{immediate:!0});function updColour(){for(let key in values)values[key]=props.modelValue[key];opts.value.picker&&setColorDot()}watch(()=>props.modelValue,updColour),watch(()=>props.modelValue.hue,updColour),watch(()=>props.modelValue.saturation,updColour),watch(()=>props.modelValue.luminosity,updColour);let current=computed(()=>({hue:~~(values.hue*360),saturation:~~(values.saturation*100),luminosity:~~(values.luminosity*100)})),emitter=__emit;function notify(){for(let key in values)props.modelValue[key]=values[key];emitter(`change`,props.modelValue),emitter(`update:modelValue`,props.modelValue)}let hueLoop=[...Array(7)].map((_,i)=>i/6*360),gradients=reactive({hueStatic:hueLoop.map(hue=>`hsl(${hue}, 100%, 50%)`),hue:computed(()=>hueLoop.map(hue=>`hsl(${hue}, 100%, 50%)`)),overlaySaturation:[`hsla(0, 0%,  0%, 0)`,`hsla(0, 0%, 50%, 1)`],overlayLuminosity:[`hsla(0, 0%, 100%, 1)`,`hsla(0, 0%, 100%, 0) 50%`,`hsla(0, 0%,   0%, 0) 50%`,`hsla(0, 0%,   0%, 1)`],pickerOverlay:computed(()=>opts.value.saturation?gradients.overlaySaturation:gradients.overlayLuminosity),saturation:computed(()=>[`hsl(${current.value.hue},   0%, ${current.value.luminosity}%)`,`hsl(${current.value.hue}, 100%, ${current.value.luminosity}%)`]),luminosity:computed(()=>[`hsl(${current.value.hue}, ${current.value.saturation}%,   0%)`,`hsl(${current.value.hue}, ${current.value.saturation}%,  50%)`,`hsl(${current.value.hue}, ${current.value.saturation}%, 100%)`])}),isMousedown=!1;function onMousedown(){isMousedown=!0}function onMousemove(evt){updateColor(evt)}function onMouseupLeave(evt){updateColor(evt,!0)}function getPosition(evt){let rect=evt.target.getBoundingClientRect();return rect.width<20?colorDot.value:{x:(evt.x-rect.left)/rect.width*100,y:(evt.y-rect.top)/rect.height*100}}function updateColor(evt,mouseLeave=!1){if(!isMousedown)return;mouseLeave&&(isMousedown=!1);let pos=getPosition(evt);values.hue=Math.max(0,Math.min(pos.x,100))/100;let secondary=1-Math.max(0,Math.min(pos.y,100))/100;opts.value.saturation?values.saturation=secondary:values.luminosity=secondary,setColorDot(),nextTick(notify)}function setColorDot(){colorDot.value={x:values.hue*100,y:(1-(opts.value.saturation?values.saturation:values.luminosity))*100}}function toggleCompactMode(){opts.value.slider=!opts.value.slider,opts.value.picker=!opts.value.picker,saveCompactMode()}function togglePickerMode(){pickerMode.value=pickerMode.value===`luminosity`?`saturation`:`luminosity`,opts.value.luminosity=pickerMode.value===`luminosity`,opts.value.saturation=pickerMode.value===`saturation`,saveCompactMode()}function loadCompactMode(){let readOption=(name,val=null)=>JSON.parse(localStorage.getItem(name)||JSON.stringify(val));opts.value.picker=readOption(`bngColorPicker-picker`,!0),opts.value.slider=readOption(`bngColorPicker-slider`,!1),pickerMode.value=readOption(`bngColorPicker-picker-mode`,`luminosity`),opts.value.luminosity=pickerMode.value===`luminosity`,opts.value.saturation=pickerMode.value===`saturation`,!opts.value.luminosity&&!opts.value.saturation&&(opts.value.luminosity=!0)}function saveCompactMode(){let saveOption=(name,val)=>localStorage.setItem(name,JSON.stringify(val));saveOption(`bngColorPicker-picker`,opts.value.picker),saveOption(`bngColorPicker-slider`,opts.value.slider),saveOption(`bngColorPicker-picker-mode`,pickerMode.value)}return onMounted(()=>{updColour(),!$simplemenu.value&&opts.value.compact&&loadCompactMode()}),(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,{class:normalizeClass({"colour-picker-container":!0,"colour-picker-mode-picker":opts.value.picker,"colour-picker-mode-slider":opts.value.slider,"colour-picker-mode-compact":opts.value.compact})},[opts.value.compact?(openBlock(),createElementBlock(`div`,_hoisted_1$329,[_cache[3]||=createBaseVNode(`span`,null,`Custom color`,-1),!unref($simplemenu)&&opts.value.picker?withDirectives((openBlock(),createBlock(unref(bngButton_default),{key:0,accent:unref(ACCENTS).text,icon:unref(icons).materialTransparency01,onClick:togglePickerMode},null,8,[`accent`,`icon`])),[[unref(BngTooltip_default),`Toggle vertical axis mode to ${pickerMode.value===`luminosity`?`saturation`:`brightness`}`,`top`]]):createCommentVNode(``,!0),unref($simplemenu)?createCommentVNode(``,!0):withDirectives((openBlock(),createBlock(unref(bngButton_default),{key:1,accent:opts.value.picker?unref(ACCENTS).outlined:unref(ACCENTS).text,icon:opts.value.picker?unref(icons).materialGlossy:unref(icons).listSmall,onClick:toggleCompactMode},null,8,[`accent`,`icon`])),[[unref(BngTooltip_default),`Toggle picker/slider mode`,`top`]])])):createCommentVNode(``,!0),opts.value.picker?withDirectives((openBlock(),createElementBlock(`div`,{key:1,class:`colour-picker`,onMousemove,onMousedown,onMouseup:onMouseupLeave,onMouseleave:onMouseupLeave,style:normalizeStyle({"--colour-picker-x":`linear-gradient(90deg, ${gradients.hueStatic.join(`, `)})`,"--colour-picker-y":`linear-gradient(180deg, ${gradients.pickerOverlay.join(`, `)})`})},[createBaseVNode(`div`,{class:`colour-picker-dot`,style:normalizeStyle({left:`${colorDot.value.x}%`,top:`${colorDot.value.y}%`,"--colour-picker-dot-fill":`hsl(${current.value.hue}, ${opts.value.saturation?current.value.saturation:100}%, ${opts.value.luminosity?current.value.luminosity:50}%)`})},null,4)],36)),[[unref(BngDisabled_default),__props.disabled]]):createCommentVNode(``,!0),opts.value.slider||opts.value.hue?(openBlock(),createBlock(unref(bngColorSlider_default),{key:2,modelValue:values.hue,"onUpdate:modelValue":_cache[0]||=$event=>values.hue=$event,modelModifiers:{number:!0},onChange:notify,fill:gradients.hue,current:`hsl(${current.value.hue}, 100%, 50%)`,indicator:sliderIndicator,step:__props.step,disabled:__props.disabled},{default:withCtx(()=>[createTextVNode(toDisplayString(__props.showText?_ctx.$t(`ui.color.hue`):null),1)]),_:1},8,[`modelValue`,`fill`,`current`,`step`,`disabled`])):createCommentVNode(``,!0),opts.value.slider||opts.value.luminosity?(openBlock(),createBlock(unref(bngColorSlider_default),{key:3,"X:vertical":`opts.picker`,modelValue:values.saturation,"onUpdate:modelValue":_cache[1]||=$event=>values.saturation=$event,modelModifiers:{number:!0},onChange:notify,fill:gradients.saturation,current:`hsl(${current.value.hue}, ${current.value.saturation}%, ${current.value.luminosity}%)`,indicator:sliderIndicator,step:__props.step,disabled:__props.disabled},{default:withCtx(()=>[createTextVNode(toDisplayString(__props.showText?`${_ctx.$t(`ui.color.saturation`)} (${current.value.saturation}%)`:null),1)]),_:1},8,[`modelValue`,`fill`,`current`,`step`,`disabled`])):createCommentVNode(``,!0),opts.value.slider||opts.value.saturation?(openBlock(),createBlock(unref(bngColorSlider_default),{key:4,"X:vertical":`opts.picker`,modelValue:values.luminosity,"onUpdate:modelValue":_cache[2]||=$event=>values.luminosity=$event,modelModifiers:{number:!0},onChange:notify,fill:gradients.luminosity,current:`hsl(${current.value.hue}, ${current.value.saturation}%, ${current.value.luminosity}%)`,indicator:sliderIndicator,step:__props.step,disabled:__props.disabled},{default:withCtx(()=>[createTextVNode(toDisplayString(__props.showText?`${_ctx.$t(`ui.color.brightness`)} (${current.value.luminosity}%)`:null),1)]),_:1},8,[`modelValue`,`fill`,`current`,`step`,`disabled`])):createCommentVNode(``,!0)],2))}},bngColorPicker_default=__plugin_vue_export_helper_default(_sfc_main$379,[[`__scopeId`,`data-v-f4241405`]]),_hoisted_1$328={key:0},_hoisted_2$263=[`min`,`max`,`step`,`tabindex`,`orient`],_hoisted_3$230={key:0,class:`colour-slider-indicator-container`},_sfc_main$378={__name:`bngColorSlider`,props:{modelValue:{type:[Number,String],default:0},min:{type:Number,default:0},max:{type:Number,default:1},step:{type:Number,default:.001},fill:{type:Array,default:[`rgb(0,0,0)`,`rgb(255,255,255)`]},current:{type:String,default:null},vertical:Boolean,disabled:Boolean,indicator:{type:String,default:`inner`,validator:val=>[`inner`,`popout`].includes(val)},uiNavFocus:{type:[Boolean,Object],default:{},validator:val=>typeof val==`boolean`&&!val||typeof val==`object`}},emits:[`update:modelValue`,`change`],setup(__props,{emit:__emit}){let props=__props,elSlider=ref(),elIndicator=ref(),tabIndex=computed(()=>props.disabled?-1:0),value=ref(props.modelValue);watch(()=>props.modelValue,val=>value.value=Number(val));let indicatorPos=computed(()=>props.indicator===`popout`?(value.value-props.min)/(props.max-props.min):0),indicatorRot=computed(()=>{if(props.indicator!==`popout`||!elSlider.value||!elIndicator.value||!elSlider.value.getBoundingClientRect||!elIndicator.value.firstChild||!elIndicator.value.firstChild.getBoundingClientRect)return 0;let tilt=40,rot=0,srect=elSlider.value.getBoundingClientRect(),irect=elIndicator.value.firstChild.getBoundingClientRect(),abspos=indicatorPos.value*srect.width,iwidth=irect.width/2;return absposwithDirectives((openBlock(),createElementBlock(`div`,{ref_key:`elSlider`,ref:elSlider,class:`colour-slider`,style:normalizeStyle({"--colour-slider-track-fill":__props.fill&&__props.fill.length>0?`linear-gradient(90deg, ${__props.fill.join(`, `)})`:`transparent`,"--colour-slider-thumb-fill":__props.indicator===`inner`&&__props.current?__props.current:`#000`,"--colour-slider-thumb-size":__props.indicator===`inner`&&__props.current?`1em`:`0.25em`,"--colour-slider-indicator-x":`${indicatorPos.value*100}%`,"--colour-slider-indicator-r":`${indicatorRot.value}deg`})},[_ctx.$slots.default&&!__props.vertical?(openBlock(),createElementBlock(`span`,_hoisted_1$328,[renderSlot(_ctx.$slots,`default`,{},void 0,!0)])):createCommentVNode(``,!0),createBaseVNode(`div`,null,[withDirectives(createBaseVNode(`input`,{type:`range`,min:__props.min,max:__props.max,step:__props.step,"onUpdate:modelValue":_cache[0]||=$event=>value.value=$event,onInput:notify,onChange:notify,tabindex:tabIndex.value,class:normalizeClass({"colour-slider-vertical":__props.vertical}),orient:__props.vertical?`vertical`:`horizontal`},null,42,_hoisted_2$263),[[vModelText,value.value,void 0,{number:!0}],[unref(BngOnUiNavFocus_default),__props.uiNavFocus?{callback:(dir,val)=>{value.value=val,notify()},value:()=>value.value,min:__props.min,max:__props.max,step:()=>+__props.step,...__props.uiNavFocus}:!1,void 0,{repeat:!0}]]),__props.indicator===`popout`?(openBlock(),createElementBlock(`div`,_hoisted_3$230,[createBaseVNode(`div`,{ref_key:`elIndicator`,ref:elIndicator,class:`colour-slider-indicator`},[createVNode(unref(bngIconMarker_default),{marker:`circlePin`,color:[`#fff`,__props.current],class:`colour-slider-indicator-marker`},null,8,[`color`])],512)])):createCommentVNode(``,!0)])],4)),[[unref(BngDisabled_default),__props.disabled]])}},bngColorSlider_default=__plugin_vue_export_helper_default(_sfc_main$378,[[`__scopeId`,`data-v-346533a2`]]),_hoisted_1$327={class:`bng-color-tile`},_sfc_main$377={__name:`bngColorTile`,props:{red:{type:Number},blue:{type:Number},green:{type:Number},alpha:{type:Number,default:1}},setup(__props){useCssVars(_ctx=>({cef4bc4e:backgroundColor.value}));let props=__props,backgroundColor=computed(()=>`rgba(${props.red}, ${props.green}, ${props.blue}, ${props.alpha})`);return(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$327))}},bngColorTile_default=__plugin_vue_export_helper_default(_sfc_main$377,[[`__scopeId`,`data-v-32089404`]]),_sfc_main$376={__name:`bngCondition`,props:{integrity:{type:Number,default:1},integrityWarning:Boolean,color:{type:[String,Array],default:`#000`},showTooltip:Boolean},setup(__props){let props=__props,integrity=computed(()=>typeof props.integrity==`number`?Math.min(Math.max(props.integrity,0),1):1),tooltip=computed(()=>{if(!props.showTooltip)return;let tip=`${$translate.instant(`ui.condition.integrity`)}: ${~~(integrity.value*100)}%`;return props.integrityWarning&&(tip+=`\n${$translate.instant(`ui.condition.needsRepair`)}`),tip}),cssColour=computed(()=>{let clr=props.color;return Array.isArray(clr)?(clr=[...clr],clr.length>3&&(clr.splice(3),clr.some(c=>c>1)||(clr=clr.map(c=>c*255))),`rgb(${clr.join(`,`)})`):clr}),cssClipPoly=computed(()=>{let val=integrity.value,corners=[`100% 0%`,`100% 100%`,`0% 100%`,`0% 0%`],poly=`0% 0%`;if(val===1)poly=corners.join(`, `);else if(val>0){let deg=(1-val)*360,x=50+50*Math.sin(deg*Math.PI/180),y=50-50*Math.cos(deg*Math.PI/180);poly=`50% 0%, 50% 50%, ${~~x}% ${~~y}%, `+corners.slice(-Math.ceil((360-deg)/90)).join(`, `)}return poly});return(_ctx,_cache)=>withDirectives((openBlock(),createElementBlock(`div`,{class:normalizeClass({"bng-condition":!0,"cond-warn":__props.integrityWarning}),style:normalizeStyle({backgroundColor:cssColour.value,"--bng-condition-clip-path":`polygon(${cssClipPoly.value})`})},null,6)),[[unref(BngTooltip_default),tooltip.value]])}},bngCondition_default=__plugin_vue_export_helper_default(_sfc_main$376,[[`__scopeId`,`data-v-686a3067`]]),SCOPED_CHANGED_EVENT_NAME=`scopeChanged`,EVENT_CROSSFIRE_MAP={ok:`select`,back:`back`,tab_l:`tabLeft`,tab_r:`tabRight`};const CROSSFIRE_HINTS={select:{id:`select`,content:{type:`binding`,props:{uiEvent:`ok`},label:`Select`}},back:{id:`back`,content:{type:`binding`,props:{uiEvent:`back`},label:`Back`}},tabLeft:{id:`tabLeft`,content:{type:`binding`,props:{uiEvent:`tab_l`},label:`Tab left`}},tabRight:{id:`tabRight`,content:{type:`binding`,props:{uiEvent:`tab_r`},label:`Tab right`}}},CROSSFIRE_HINTS_ALL=Object.values(CROSSFIRE_HINTS),DEFAULT_LABELS={focus_u:`ui.inputActions.controllerui.focus_u.title`,focus_r:`ui.inputActions.controllerui.focus_r.title`,focus_d:`ui.inputActions.controllerui.focus_d.title`,focus_l:`ui.inputActions.controllerui.focus_l.title`,pause:`ui.inputActions.general.pause.title`,menu:`ui.inputActions.controllerui.menu.title`,back:`ui.inputActions.controllerui.back.title`,details:`ui.inputActions.controllerui.details.title`,advanced:`ui.inputActions.controllerui.advanced.title`,camera:`ui.inputActions.controllerui.camera.title`,logs:`ui.inputActions.controllerui.logs.title`,tab_l:`ui.inputActions.controllerui.tab_l.title`,tab_r:`ui.inputActions.controllerui.tab_r.title`,modifier:`ui.inputActions.controllerui.modifier.title`,zoom_out:`ui.inputActions.controllerui.zoom_out.title`,zoom_in:`ui.inputActions.controllerui.zoom_in.title`,subtab_l:`ui.inputActions.controllerui.subtab_l.title`,subtab_r:`ui.inputActions.controllerui.subtab_r.title`,center_cam:`ui.inputActions.controllerui.center_cam.title`,action_4:`ui.inputActions.controllerui.action_4.title`,move_ud:`ui.inputActions.controllerui.move_ud.title`,move_lr:`ui.inputActions.controllerui.move_lr.title`,focus_ud:`ui.inputActions.controllerui.focus_ud.title`,focus_lr:`ui.inputActions.controllerui.focus_lr.title`,rotate_h_cam:`ui.inputActions.controllerui.rotate_h_cam.title`,rotate_v_cam:`ui.inputActions.controllerui.rotate_v_cam.title`,ok:`ui.inputActions.controllerui.ok.title`,cancel:`ui.inputActions.controllerui.cancel.title`,action_2:`ui.inputActions.controllerui.action_2.title`,action_3:`ui.inputActions.controllerui.action_3.title`,context:`ui.inputActions.controllerui.context.title`};var HINT_GROUPS=()=>[{names:[`back`,`menu`],label:`ui.inputActions.controllerui.back.title`},{names:[`focus_u`,`focus_d`,`focus_r`,`focus_l`,`focus_lr`,`focus_ud`],label:`ui.mainmenu.navbar.navigate`,controllerOnly:!0},{names:[`focus_u`,`focus_d`,`focus_r`,`focus_l`],label:`ui.mainmenu.navbar.navigate`},{names:[`focus_lr`,`focus_ud`],label:`ui.mainmenu.navbar.navigate`,controllerOnly:!0},{names:[SCROLL_EVENT_H,SCROLL_EVENT_V],label:`ui.mainmenu.navbar.scroll_label`,controllerOnly:!0},{names:[`tab_r`,`tab_l`],label:`ui.mainmenu.navbar.navigate`,controllerOnly:!0}],AUTOID=`__auto`,AUTOIDS={binding:`${AUTOID}_binding`,group:`${AUTOID}_group`,labelGroup:`${AUTOID}_label_group`},DISPLAY_ACTION_VARIANTS=!1;const useInfoBar=defineStore(`infoBar`,()=>{let{events:events$3}=useBridge(),Controls=controls_default(),{isControllerUsed,lastDevice}=storeToRefs(Controls),hintGroups=HINT_GROUPS(),visible=ref(!1),showSysInfo=ref(!1),withAngular=ref(!1),hintsList=ref([]),hints=ref([]);watch([isControllerUsed,lastDevice],()=>_groupHints());let getControlGroup=(uiEvents,groupLabel)=>{try{let actions=uiEvents.map(event=>ACTIONS_BY_UI_EVENT[event]).filter(Boolean);if(actions.length!==uiEvents.length)return null;let viewerObjs=actions.map(action=>Controls.makeViewerObj({action,actionVariants:DISPLAY_ACTION_VARIANTS,useLastDevice:!0})).flatMap(vo=>vo?.variants?vo.variants:vo?[vo]:[]),matchingItems=[],devNames=viewerObjs.reduce((res,obj)=>obj&&!res.includes(obj.devName)?[...res,obj.devName]:res,[]);for(let devName of devNames){if(!devName)continue;let devViewerObjs=viewerObjs.filter(obj=>obj&&obj.devName===devName&&obj.ownGroups);if(devViewerObjs.length===0)continue;let groups=devViewerObjs[0].ownGroups,controls$1=devViewerObjs.map(obj=>obj.control);for(let group of groups){if(!group.controls.every(control=>controls$1.includes(control)))continue;controls$1=controls$1.filter(control=>!group.controls.includes(control));let item;item=group.label?{type:`binding`,props:{viewerObj:{icon:devViewerObjs[0].icon,ownLabel:group.label}},label:groupLabel}:{type:`icon`,props:{type:icons[group.icon]},label:groupLabel},matchingItems.push(item)}}return matchingItems.length===0?null:matchingItems.length===1?matchingItems[0]:matchingItems}catch(err){return logger_default.error(`Error in checkForControlGroup:`,err),null}},_groupHints=()=>{let res=[],groupCandidates={},labelGroups={},isCustomLabel=content=>content&&!content.autoLabel&&content?.props?.uiEvent&&content.label!==DEFAULT_LABELS[content?.props?.uiEvent];for(let hint of hintsList.value){let normalizedHint=hint.content?hint:{content:hint},{content}=normalizedHint;if(!content?.props?.uiEvent||!content.label){res.push(normalizedHint);continue}let labelKey=content.label;labelGroups[labelKey]?labelGroups[labelKey].hints.push(normalizedHint):labelGroups[labelKey]={hints:[normalizedHint],position:res.length}}let selectMatchingGroup=matchingGroups=>matchingGroups.length<1||isControllerUsed.value?matchingGroups[0]:matchingGroups.find(group=>!group.controllerOnly)||matchingGroups.at(-1);for(let[label,group]of Object.entries(labelGroups)){let action=group.hints[0].action;if(group.hints.length>1){let events$4=group.hints.map(h$1=>h$1.content.props.uiEvent),matchingGroup=selectMatchingGroup(hintGroups.filter(g=>g.content&&g.names.every(name=>events$4.includes(name))&&events$4.filter(e=>g.names.includes(e)).length===g.names.length));if(matchingGroup){if(matchingGroup.controllerOnly&&!isControllerUsed.value)continue;let groupContent=Array.isArray(matchingGroup.content)?matchingGroup.content[0]:matchingGroup.content,groupLabel=matchingGroup.label||groupContent?.label||group.hints[0]?.content?.label,groupEvents=group.hints.map(h$1=>h$1.content.props.uiEvent),labeledBindings=group.hints.map(h$1=>{let newContent={id:h$1.id,type:h$1.content.type,props:{...h$1.content.props}};return newContent.label=isCustomLabel(h$1.content)?h$1.content.label:groupLabel,newContent}),controlGroup=getControlGroup(groupEvents,groupLabel);if(controlGroup){let content=Array.isArray(controlGroup)?controlGroup.map(item=>({...item})):[{...controlGroup}],customLabelItem=group.hints.find(h$1=>isCustomLabel(h$1.content));customLabelItem&&content.forEach(item=>{item.label=customLabelItem.content.label}),res.splice(group.position,0,{id:`${AUTOIDS.labelGroup}_${label}`,content,action})}else res.splice(group.position,0,{id:`${AUTOIDS.labelGroup}_${label}`,content:labeledBindings,action})}else res.splice(group.position,0,{id:`${AUTOIDS.labelGroup}_${label}`,content:group.hints.map(h$1=>h$1.content),action})}else{let hint=group.hints[0],uiEvent=hint.content?.props?.uiEvent,isNoGroup=uiEvent$1=>uiNavTracker.activeEvents.find(e=>e.name===uiEvent$1)?.nogroup;if(isNoGroup(uiEvent)){res.push(hint);continue}let matchingGroup=selectMatchingGroup(hintGroups.filter(group$1=>group$1.names.includes(uiEvent)));if(!matchingGroup){res.push(hint);continue}let groupId=matchingGroup.names.join(`,`);groupId in groupCandidates||(groupCandidates[groupId]={hints:[],content:[],position:res.length});let groupCandidate=groupCandidates[groupId];if(groupCandidate.hints.push(hint),groupCandidate.content.push(hint.content),groupCandidate.hints.length===matchingGroup.names.length){if(matchingGroup.controllerOnly&&!isControllerUsed.value){delete groupCandidates[groupId];continue}if(groupCandidate.hints.some(h$1=>isNoGroup(h$1.content?.props?.uiEvent)))res.splice(groupCandidate.position,0,...groupCandidate.hints);else{let groupContent=Array.isArray(matchingGroup.content)?matchingGroup.content[0]:matchingGroup.content,groupLabel=matchingGroup.label||groupContent?.label||groupCandidate.hints[0]?.content?.label,labeledContent=groupCandidate.content.map(item=>{let newContent={id:item.id,type:item.type,props:{...item.props}};return isCustomLabel(item)?newContent.label=item.label:newContent.label=groupLabel,newContent}),controlGroup=getControlGroup(groupCandidate.hints.map(h$1=>h$1.content.props.uiEvent),groupLabel);if(controlGroup){let content=Array.isArray(controlGroup)?controlGroup.map(icon=>({...icon})):[{...controlGroup}],customLabelItem=groupCandidate.content.find(item=>isCustomLabel(item));customLabelItem&&content.forEach(icon=>icon.label=customLabelItem.label),res.splice(groupCandidate.position,0,{id:`${AUTOIDS.group}_${groupId}`,content,action})}else res.splice(groupCandidate.position,0,{id:`${AUTOIDS.group}_${groupId}`,content:labeledContent,action})}delete groupCandidates[groupId]}}}for(let group of Object.values(groupCandidates))res.splice(group.position,0,...group.hints);hints.value=res},uiNavTracker=useUINavTracker(),clearHints=()=>{hintsList.value=[],_addTrackedEvents()},addHints=(hintOrHints,idOrPos=void 0,before=!1)=>{if(hintOrHints===CROSSFIRE_HINTS_ALL){logger_default.warn(`Approach with CROSSFIRE_HINTS_ALL is deprecated and crossfire hints are added by default.`);return}let toAdd=[hintOrHints].flat().map(hint=>{if(typeof hint!=`object`)return hint;let content=hint.content||hint,uiEvent=content?.props?.uiEvent;return uiEvent&&(content.label||(content.autoLabel=!0,uiEvent in DEFAULT_LABELS?content.label=DEFAULT_LABELS[uiEvent]:content.label=uiEvent.replaceAll(`_`,` `).toUpperCase())),hint});if(idOrPos===void 0)hintsList.value=hintsList.value.concat(toAdd);else if(typeof idOrPos==`number`)hintsList.value.splice(idOrPos,0,...toAdd);else if(typeof idOrPos==`string`){let foundIndex=_findHintIndex(idOrPos);foundIndex>-1&&hintsList.value.splice(foundIndex+(before?0:1),0,...toAdd)}_groupHints()},updateHint=(idOrPos,updatedHint)=>{if(typeof idOrPos==`number`)hintsList.value[idOrPos]=updatedHint;else{let foundIndex=_findHintIndex(idOrPos);hintsList.value[foundIndex]=updatedHint}_groupHints()},removeHints=(...ids)=>{ids.forEach(id=>{let foundIndex=_findHintIndex(id);foundIndex>-1&&hintsList.value.splice(foundIndex,1)}),_groupHints()},flashHints=(...ids)=>{_setFlash(!1,ids),setTimeout(()=>_setFlash(!0,ids),0)},_setFlash=(state,ids)=>ids.forEach(id=>{let foundIndex=_findHintIndex(id);foundIndex>-1&&(hintsList.value[foundIndex].flash=state)}),highlightHints=(state,...ids)=>{},_findHintIndex=id=>hintsList.value.findIndex(h$1=>h$1.id===id);events$3.on(SCOPED_CHANGED_EVENT_NAME,data=>{logger_default.debug(`[infoBar] received data`,data),data&&(clearHints(),data.forEach(ev=>{let content;content=ev.label?{content:{type:`binding`,props:{uiEvent:ev.event},label:ev.label}}:CROSSFIRE_HINTS[EVENT_CROSSFIRE_MAP[ev.event]],addHints(content)}))});function _addTrackedEvents(){let activeEvents=uiNavTracker.activeEvents;hintsList.value=hintsList.value.filter(hint=>!hint.id?.startsWith(AUTOID)&&activeEvents.some(e=>e.name===hint.content.props.uiEvent));let currentBindings=hintsList.value.filter(hint=>hint.content?.type===`binding`).map(hint=>hint.content.props.uiEvent);addHints(activeEvents.filter(({name})=>!currentBindings.includes(name)).map(({name,label,nogroup,action})=>({id:`${AUTOIDS.binding}_${name}`,content:{type:`binding`,props:{uiEvent:name},label,autoLabel:!label||label===DEFAULT_LABELS[name]},nogroup,action})))}return watch(()=>uiNavTracker.activeEvents,_addTrackedEvents,{deep:!0}),{visible,hintsList,hints,showSysInfo,withAngular,clearHints,addHints,updateHint,removeHints,flashHints,highlightHints}});var _hoisted_1$326={key:0,xmlns:`http://www.w3.org/2000/svg`,viewBox:`20 140 460 220`},_hoisted_2$262={class:`bng-controller-hint-labels`},_hoisted_3$229={x:`120`,y:`165`,"text-anchor":`middle`},_hoisted_4$196={x:`120`,y:`335`,"text-anchor":`middle`},_hoisted_5$166={x:`45`,y:`255`,"text-anchor":`end`},_hoisted_6$142={x:`175`,y:`255`,"text-anchor":`start`},_hoisted_7$124={x:`219`,y:`315`,"text-anchor":`middle`},_hoisted_8$102={x:`249`,y:`315`,"text-anchor":`middle`},_hoisted_9$92={x:`340`,y:`175`,"text-anchor":`middle`},_hoisted_10$80={x:`380`,y:`335`,"text-anchor":`middle`},_sfc_main$375={__name:`bngControllerHint`,props:{device:String,actions:[Array,String],dark:Boolean},setup(__props,{expose:__expose}){let Controls=controls_default(),props=__props,available=[`xbox`],devName=computed(()=>{if(!props.device)return Controls.lastDevice;let devName$1=props.device;return/\d$/.test(devName$1)||(devName$1=Controls.lastDevices.find(dev=>dev.startsWith(devName$1)),devName$1||=props.device+`0`),devName$1}),devFamily=computed(()=>{let family=Controls.makeViewerObj({device:devName.value,uiEvent:`back`})?.family;return!family||!available.includes(family)?null:family});__expose({displayed:computed(()=>!!devFamily.value)});let actions=computed(()=>{let actions$1=props.actions;if(!actions$1||!devFamily.value)return{};if(typeof actions$1==`string`)actions$1=[actions$1];else if(!Array.isArray(actions$1)||actions$1.length===0)return{};let bindings={},allEvents=Object.keys(ACTIONS_BY_UI_EVENT),allActions=Object.values(ACTIONS_BY_UI_EVENT);for(let action of actions$1){if(!action)continue;let item=action;if(typeof item==`string`)item={action:item};else if(!item.action&&!item.event)continue;else item={...item};let actIdx=allEvents.indexOf(item.event||item.action);if(actIdx>-1&&(item.event=allEvents[actIdx],item.action=allActions[actIdx]),!allActions.includes(item.action))continue;let binding=Controls.findBindingForAction(item.action,devName.value);if(binding){if(!item.event||item.event===item.action){let idx=allActions.indexOf(item.action);idx>-1&&(item.event=allEvents[idx])}item.label||=DEFAULT_LABELS[item.event]||item.event||item.action,item.shown=!0,item.class={flash:item.flash},bindings[binding.control.toLowerCase()]=item}}logger_default.debug(`resolved actions:`,bindings);for(let keyName of DEVICE_CONTROLS[devFamily.value]){let key=keyName.toLowerCase();key in bindings||(bindings[key]={class:{inactive:!0}})}return bindings});return(_ctx,_cache)=>devFamily.value?(openBlock(),createElementBlock(`div`,{key:0,class:normalizeClass([`bng-controller-hint`,{"bng-controller-hint-dark":__props.dark}])},[devFamily.value===`xbox`?(openBlock(),createElementBlock(`svg`,_hoisted_1$326,[_cache[8]||=createBaseVNode(`rect`,{x:`60`,y:`180`,width:`380`,height:`140`,rx:`20`,fill:`#bcbcbc`,stroke:`#333`,"stroke-width":`8`},null,-1),_cache[9]||=createBaseVNode(`circle`,{cx:`120`,cy:`250`,r:`28`,fill:`#222`},null,-1),createBaseVNode(`rect`,{class:normalizeClass(actions.value.upov.class),x:`114`,y:`222`,width:`12`,height:`20`,rx:`3`,fill:`#444`},null,2),createBaseVNode(`rect`,{class:normalizeClass(actions.value.dpov.class),x:`114`,y:`258`,width:`12`,height:`20`,rx:`3`,fill:`#444`},null,2),createBaseVNode(`rect`,{class:normalizeClass(actions.value.lpov.class),x:`98`,y:`242`,width:`20`,height:`12`,rx:`3`,fill:`#444`},null,2),createBaseVNode(`rect`,{class:normalizeClass(actions.value.rpov.class),x:`122`,y:`242`,width:`20`,height:`12`,rx:`3`,fill:`#444`},null,2),createBaseVNode(`rect`,{class:normalizeClass(actions.value.btn_start.class),x:`210`,y:`240`,width:`18`,height:`10`,rx:`3`,fill:`#888`},null,2),createBaseVNode(`rect`,{class:normalizeClass(actions.value.btn_back.class),x:`240`,y:`240`,width:`18`,height:`10`,rx:`3`,fill:`#888`},null,2),createBaseVNode(`circle`,{class:normalizeClass(actions.value.btn_a.class),cx:`340`,cy:`230`,r:`18`,fill:`#22a`},null,2),createBaseVNode(`circle`,{class:normalizeClass(actions.value.btn_b.class),cx:`380`,cy:`270`,r:`18`,fill:`#22a`},null,2),createBaseVNode(`g`,_hoisted_2$262,[actions.value.upov?.shown?(openBlock(),createElementBlock(Fragment,{key:0},[_cache[0]||=createBaseVNode(`line`,{x1:`120`,y1:`202`,x2:`120`,y2:`170`,stroke:`#666`,"stroke-width":`2`},null,-1),createBaseVNode(`text`,_hoisted_3$229,toDisplayString(_ctx.$tt(actions.value.upov?.label)),1)],64)):createCommentVNode(``,!0),actions.value.dpov?.shown?(openBlock(),createElementBlock(Fragment,{key:1},[_cache[1]||=createBaseVNode(`line`,{x1:`120`,y1:`298`,x2:`120`,y2:`320`,stroke:`#666`,"stroke-width":`2`},null,-1),createBaseVNode(`text`,_hoisted_4$196,toDisplayString(_ctx.$tt(actions.value.dpov?.label)),1)],64)):createCommentVNode(``,!0),actions.value.lpov?.shown?(openBlock(),createElementBlock(Fragment,{key:2},[_cache[2]||=createBaseVNode(`line`,{x1:`78`,y1:`250`,x2:`50`,y2:`250`,stroke:`#666`,"stroke-width":`2`},null,-1),createBaseVNode(`text`,_hoisted_5$166,toDisplayString(_ctx.$tt(actions.value.lpov?.label)),1)],64)):createCommentVNode(``,!0),actions.value.rpov?.shown?(openBlock(),createElementBlock(Fragment,{key:3},[_cache[3]||=createBaseVNode(`line`,{x1:`142`,y1:`250`,x2:`170`,y2:`250`,stroke:`#666`,"stroke-width":`2`},null,-1),createBaseVNode(`text`,_hoisted_6$142,toDisplayString(_ctx.$tt(actions.value.rpov?.label)),1)],64)):createCommentVNode(``,!0),actions.value.btn_start?.shown?(openBlock(),createElementBlock(Fragment,{key:4},[_cache[4]||=createBaseVNode(`line`,{x1:`219`,y1:`270`,x2:`219`,y2:`300`,stroke:`#666`,"stroke-width":`2`},null,-1),createBaseVNode(`text`,_hoisted_7$124,toDisplayString(_ctx.$tt(actions.value.btn_start?.label)),1)],64)):createCommentVNode(``,!0),actions.value.btn_back?.shown?(openBlock(),createElementBlock(Fragment,{key:5},[_cache[5]||=createBaseVNode(`line`,{x1:`249`,y1:`270`,x2:`249`,y2:`300`,stroke:`#666`,"stroke-width":`2`},null,-1),createBaseVNode(`text`,_hoisted_8$102,toDisplayString(_ctx.$tt(actions.value.btn_back?.label)),1)],64)):createCommentVNode(``,!0),actions.value.btn_a?.shown?(openBlock(),createElementBlock(Fragment,{key:6},[_cache[6]||=createBaseVNode(`line`,{x1:`340`,y1:`212`,x2:`340`,y2:`180`,stroke:`#666`,"stroke-width":`2`},null,-1),createBaseVNode(`text`,_hoisted_9$92,toDisplayString(_ctx.$tt(actions.value.btn_a?.label)),1)],64)):createCommentVNode(``,!0),actions.value.btn_b?.shown?(openBlock(),createElementBlock(Fragment,{key:7},[_cache[7]||=createBaseVNode(`line`,{x1:`380`,y1:`288`,x2:`380`,y2:`320`,stroke:`#666`,"stroke-width":`2`},null,-1),createBaseVNode(`text`,_hoisted_10$80,toDisplayString(_ctx.$tt(actions.value.btn_b?.label)),1)],64)):createCommentVNode(``,!0)])])):createCommentVNode(``,!0)],2)):createCommentVNode(``,!0)}},bngControllerHint_default=__plugin_vue_export_helper_default(_sfc_main$375,[[`__scopeId`,`data-v-bb01f791`]]),_sfc_main$374={},_hoisted_1$325={class:`divider vertical-divider`};function _sfc_render$6(_ctx,_cache){return openBlock(),createElementBlock(`div`,_hoisted_1$325)}var bngDivider_default=__plugin_vue_export_helper_default(_sfc_main$374,[[`render`,_sfc_render$6],[`__scopeId`,`data-v-c3fbf7df`]]),_sfc_main$373={__name:`bngDrawer`,props:mergeModels({header:String,blur:Boolean,expandable:{type:Boolean,default:!0},position:String},{modelValue:{type:Boolean},modelModifiers:{}}),emits:mergeModels([`change`],[`update:modelValue`]),setup(__props,{emit:__emit}){let props=__props,emit$1=__emit,slots=useSlots(),arrows=computed(()=>{switch(props.position){default:case DRAWER_POSITION.bottom:case DRAWER_POSITION.right:return{expand:icons.arrowLargeUp,collapse:icons.arrowLargeDown};case DRAWER_POSITION.top:case DRAWER_POSITION.left:return{expand:icons.arrowLargeDown,collapse:icons.arrowLargeUp}}}),expanded=useModel(__props,`modelValue`);return watch(()=>expanded.value,val=>emit$1(`change`,val)),watch([()=>props.expandable,()=>expanded.value],()=>!props.expandable&&expanded.value&&(expanded.value=!1),{immediate:!0}),(_ctx,_cache)=>(openBlock(),createBlock(unref(drawer_default),{modelValue:expanded.value,"onUpdate:modelValue":_cache[1]||=$event=>expanded.value=$event,blur:__props.blur,position:__props.position},createSlots({header:withCtx(()=>[createVNode(unref(bngCardHeading_default),{class:`header`,type:`ribbon`,style:normalizeStyle({marginRight:!__props.header&&!unref(slots).header?`0`:void 0})},{default:withCtx(()=>[__props.header?(openBlock(),createElementBlock(Fragment,{key:0},[createTextVNode(toDisplayString(__props.header),1)],64)):renderSlot(_ctx.$slots,`header`,{key:1},()=>[_cache[2]||=createBaseVNode(`span`,null,null,-1)],!0)]),_:3},8,[`style`]),renderSlot(_ctx.$slots,`header-controls`,{},void 0,!0),__props.expandable?(openBlock(),createBlock(unref(bngButton_default),{key:0,accent:`text`,icon:expanded.value?arrows.value.collapse:arrows.value.expand,onClick:_cache[0]||=$event=>expanded.value=!expanded.value},null,8,[`icon`])):createCommentVNode(``,!0)]),_:2},[`content`in unref(slots)?{name:`content`,fn:withCtx(()=>[renderSlot(_ctx.$slots,`content`,{},void 0,!0)]),key:`0`}:void 0,`expanded-content`in unref(slots)?{name:`expanded-content`,fn:withCtx(()=>[renderSlot(_ctx.$slots,`expanded-content`,{},void 0,!0)]),key:`1`}:`default`in unref(slots)?{name:`expanded-content`,fn:withCtx(()=>[renderSlot(_ctx.$slots,`default`,{},void 0,!0)]),key:`2`}:void 0]),1032,[`modelValue`,`blur`,`position`]))}},bngDrawer_default=__plugin_vue_export_helper_default(_sfc_main$373,[[`__scopeId`,`data-v-30948d98`]]),_hoisted_1$324={class:`bng-drawer`},_hoisted_2$261={class:`header-wrapper`},_hoisted_3$228={class:`content`},_sfc_main$372={__name:`bngDrawerOld`,props:{header:{type:String},blur:{type:Boolean,default:!1}},setup(__props){return(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$324,[withDirectives((openBlock(),createElementBlock(`div`,_hoisted_2$261,[createVNode(unref(bngCardHeading_default),{class:`header`,type:`ribbon`},{default:withCtx(()=>[__props.header?(openBlock(),createElementBlock(Fragment,{key:0},[createTextVNode(toDisplayString(__props.header),1)],64)):renderSlot(_ctx.$slots,`header`,{key:1},void 0,!0)]),_:3}),renderSlot(_ctx.$slots,`headerOptions`,{},void 0,!0)])),[[unref(BngBlur_default),__props.blur]]),withDirectives((openBlock(),createBlock(unref(bngCard_default),null,{default:withCtx(()=>[createBaseVNode(`div`,_hoisted_3$228,[renderSlot(_ctx.$slots,`content`,{},void 0,!0)])]),_:3})),[[unref(BngBlur_default),__props.blur]])]))}},bngDrawerOld_default=__plugin_vue_export_helper_default(_sfc_main$372,[[`__scopeId`,`data-v-9e5c32b1`]]),_hoisted_1$323={class:`dropdown-display`},_hoisted_2$260={key:0,class:`dropdown-search`},_hoisted_3$227={key:1},_hoisted_4$195={key:0,class:`dropdown-group-header`},_hoisted_5$165=[`bng-nav-item`,`tabindex`,`bng-scoped-nav-autofocus`,`onClick`,`onKeyup`],_sfc_main$371={__name:`bngDropdown`,props:{modelValue:{type:[Number,String,Boolean,Object]},items:{type:Array,required:!0},showSearch:Boolean,highlight:{type:[String,Array,RegExp]},disabled:Boolean,longNames:{type:String,default:`oneline`,validator:val=>[`oneline`,`wrap`,`cut`].includes(val)},searchGroupName:Boolean,headless:Boolean,focusTarget:Object,popoverTarget:Object},emits:[`update:modelValue`,`valueChanged`,`open`,`close`],setup(__props,{expose:__expose,emit:__emit}){let attrs=useAttrs(),binds=computed(()=>props.headless?void 0:attrs),props=__props,emit$1=__emit,elContainer=ref(null),opened=ref(!1),searching=ref(!1),search$1=ref(``),searchTerm=computed(()=>search$1.value.toLowerCase());watch(opened,val=>!val&&(search$1.value=``)),__expose({opened,open:()=>opened.value=!0,close:()=>opened.value=!1,toggle:()=>opened.value=!opened.value,get popoverName(){return elContainer.value?.popoverName}});let groupedItems=computed(()=>{let hasGrouping=props.items.some(item=>item.group||item.grouped),searchActive=!!searchTerm.value;if(!hasGrouping)return[{header:null,items:searchActive?props.items.filter(item=>item.label.toLowerCase().includes(searchTerm.value)):props.items}];let groups=[],currentGroup=null;return props.items.forEach(item=>{item.group?(currentGroup={header:item,allItems:[],_headerMatches:item.label.toLowerCase().includes(searchTerm.value)},groups.push(currentGroup)):item.grouped?currentGroup?currentGroup.allItems.push(item):groups.push({header:null,allItems:[item]}):(groups.push({header:null,allItems:[item]}),currentGroup=null)}),groups.map(group=>{if(searchActive)if(group.header){if(props.searchGroupName&&group._headerMatches)return{header:group.header,items:group.allItems,headerMatches:!0};{let filteredItems=group.allItems.filter(item=>item.label.toLowerCase().includes(searchTerm.value));return{header:group.header,items:filteredItems,headerMatches:!1}}}else return{header:null,items:group.allItems.filter(item=>item.label.toLowerCase().includes(searchTerm.value))};else return{header:group.header||null,items:group.allItems}}).filter(group=>group.header&&props.searchGroupName&&group.headerMatches||group.items.length>0)}),highlighter$1=computed(()=>search$1.value||props.highlight),selectedValue=computed({get:()=>props.modelValue,set:newValue=>{emit$1(`update:modelValue`,newValue),emit$1(`valueChanged`,newValue)}}),selectedItem=computed(()=>props.items.find(x=>x.value===selectedValue.value)),headerText=computed(()=>selectedItem.value&&selectedItem.value.value!==null&&selectedItem.value.value!==void 0?selectedItem.value.label:`Select`),tabIndexValue=computed(()=>props.disabled?-1:0),select=item=>{item.disabled||(opened.value=!1,selectedValue.value!==item.value&&(selectedValue.value=item.value),elContainer.value?.focusContainer())};return(_ctx,_cache)=>(openBlock(),createBlock(unref(bngDropdownContainer_default),mergeProps({ref_key:`elContainer`,ref:elContainer},binds.value,{opened:opened.value,"onUpdate:opened":_cache[3]||=$event=>opened.value=$event,disabled:__props.disabled,headless:__props.headless,"focus-target":__props.focusTarget,"popover-target":__props.popoverTarget,class:{"with-search":__props.showSearch,[`dropdown-longnames-${__props.longNames}`]:!0},onShow:_cache[4]||=$event=>emit$1(`open`),onHide:_cache[5]||=$event=>emit$1(`close`)}),createSlots({default:withCtx(()=>[__props.showSearch?(openBlock(),createElementBlock(`div`,_hoisted_2$260,[createVNode(unref(bngInput_default),{modelValue:search$1.value,"onUpdate:modelValue":_cache[0]||=$event=>search$1.value=$event,modelModifiers:{trim:!0},"floating-label":`Search`,onFocus:_cache[1]||=$event=>searching.value=!0,onBlur:_cache[2]||=$event=>searching.value=!1},null,8,[`modelValue`])])):createCommentVNode(``,!0),search$1.value&&groupedItems.value.every(group=>group.items.length===0)?(openBlock(),createElementBlock(`div`,_hoisted_3$227,toDisplayString(_ctx.$t(`ui.common.search.noResults`)),1)):(openBlock(!0),createElementBlock(Fragment,{key:2},renderList(groupedItems.value,(group,groupIndex)=>(openBlock(),createElementBlock(Fragment,{key:groupIndex},[group.header?(openBlock(),createElementBlock(`div`,_hoisted_4$195,toDisplayString(group.header.label),1)):createCommentVNode(``,!0),(openBlock(!0),createElementBlock(Fragment,null,renderList(group.items,(item,idx)=>withDirectives((openBlock(),createElementBlock(`div`,{key:item.value,class:normalizeClass([`dropdown-option`,{selected:selectedItem.value&&selectedItem.value.value===item.value,"grouped-item":group.header,disabled:item.disabled}]),"bng-nav-item":!item.disabled||item.focusable,tabindex:item.disabled?-1:tabIndexValue.value,"bng-scoped-nav-autofocus":!item.disabled&&!searching.value&&(selectedItem.value&&selectedItem.value.value===item.value||!selectedItem.value&&groupIndex===0&&idx===0),onClick:$event=>select(item),onKeyup:withKeys($event=>select(item),[`enter`])},[createTextVNode(toDisplayString(item.label),1)],42,_hoisted_5$165)),[[unref(BngOnUiNav_default),void 0,`ok`,{asMouse:!0,focusRequired:!0}],[unref(BngUiNavLabel_default),`ui.inputActions.menu.menu_item_select.title`,`ok`],[unref(BngTooltip_default),item.tooltip??void 0],[unref(BngHighlighter_default),highlighter$1.value]])),128))],64))),128))]),_:2},[__props.headless?void 0:{name:`display`,fn:withCtx(()=>[renderSlot(_ctx.$slots,`display`,{},()=>[withDirectives((openBlock(),createElementBlock(`span`,_hoisted_1$323,[createTextVNode(toDisplayString(headerText.value),1)])),[[unref(BngHighlighter_default),highlighter$1.value]])],!0)]),key:`0`}]),1040,[`opened`,`disabled`,`headless`,`focus-target`,`popover-target`,`class`]))}},bngDropdown_default=__plugin_vue_export_helper_default(_sfc_main$371,[[`__scopeId`,`data-v-96e56708`]]),popoverBaseName=`bng-dropdown-content`,_sfc_main$370=Object.assign({inheritAttrs:!1},{__name:`bngDropdownContainer`,props:mergeModels({disabled:Boolean,class:[String,Array,Object],headless:Boolean,focusTarget:Object,popoverTarget:Object},{opened:{},openedModifiers:{}}),emits:mergeModels([`provideFocus`,`show`,`hide`],[`update:opened`]),setup(__props,{expose:__expose,emit:__emit}){let navBlocker=useUINavBlocker(),props=__props,attrs=useAttrs(),binds=computed(()=>({...attrs,tabindex:props.headless?-1:0,"bng-nav-item":props.headless?void 0:``})),opened=useModel(__props,`opened`);function open$1(val){opened.value=val,val?(navBlocker.allowOnly([`focus_u`,`focus_d`,`focus_ud`,`back`,`menu`,`ok`]),emit$1(`show`)):(navBlocker.clear(),emit$1(`hide`),focusTarget.value&&setFocusExternal(focusTarget.value,!0,!1))}let emit$1=__emit,popover=usePopover(),popoverName=uniqueId(popoverBaseName),container=ref(null),content=ref(null),focusTarget=computed(()=>props.focusTarget||container.value),popoverTarget=computed(()=>props.popoverTarget||container.value),placement=ref(`bottom-start`),openedTop=computed(()=>placement.value.startsWith(`top`));return watch(()=>opened.value,value=>{value?(Object.keys(popover.popovers).filter(name=>popover.popovers[name].show&&name!==popoverName&&!popover.popovers[name].element.contains(popover.popovers[popoverName].target)).forEach(name=>popover.hide(name)),!popover.popovers[popoverName].show&&popoverTarget.value&&popover.show(popoverName,popoverTarget.value)):popover.hide(popoverName)}),__expose({opened,open:()=>opened.value=!0,close:()=>opened.value=!1,toggle:()=>opened.value=!opened.value,focusContainer:()=>focusTarget.value&&setFocusExternal(focusTarget.value),popoverName}),(_ctx,_cache)=>(openBlock(),createElementBlock(Fragment,null,[__props.headless?createCommentVNode(``,!0):withDirectives((openBlock(),createElementBlock(`div`,mergeProps({key:0,ref_key:`container`,ref:container},binds.value,{class:[`bng-dropdown`,props.class]}),[createVNode(unref(bngIcon_default),{type:unref(icons).arrowSmallRight,class:normalizeClass({"dropdown-arrow":!0,"dropdown-arrow-top":openedTop.value,opened:opened.value})},null,8,[`type`,`class`]),renderSlot(_ctx.$slots,`display`,{},()=>[_cache[8]||=createTextVNode(`Select`,-1)],!0)],16)),[[unref(BngDisabled_default),__props.disabled],[unref(BngOnUiNav_default),void 0,`ok`,{asMouse:!0,focusRequired:!0}],[unref(BngPopover_default),unref(popoverName),`bottom-start`,{click:!0}]]),createVNode(unref(bngPopoverContent_default),{name:unref(popoverName),onShow:_cache[5]||=$event=>open$1(!0),onHide:_cache[6]||=$event=>open$1(!1),"hide-arrow":``,onPlacementChanged:_cache[7]||=value=>placement.value=value},{default:withCtx(()=>[withDirectives((openBlock(),createElementBlock(`div`,{ref_key:`content`,ref:content,class:normalizeClass([`bng-dropdown-content`,__props.class]),"bng-nav-scroll":``,onClick:_cache[0]||=withModifiers(()=>{},[`stop`]),onMouseover:_cache[1]||=withModifiers(()=>{},[`stop`]),onMouseenter:_cache[2]||=withModifiers(()=>{},[`stop`]),onMousedown:_cache[3]||=withModifiers(()=>{},[`stop`]),onMouseup:_cache[4]||=withModifiers(()=>{},[`stop`])},[opened.value?renderSlot(_ctx.$slots,`default`,{key:0},void 0,!0):createCommentVNode(``,!0)],34)),[[unref(BngAutoScroll_default),void 0,`top`],[unref(BngUiNavLabel_default),`ui.common.close`,`back,menu`],[unref(BngUiNavLabel_default),`ui.mainmenu.navbar.navigate`,`focus_u,focus_d`],[unref(BngUiNavScroll_default)],[unref(BngOnUiNav_default),()=>open$1(!1),`menu`]])]),_:3},8,[`name`])],64))}}),bngDropdownContainer_default=__plugin_vue_export_helper_default(_sfc_main$370,[[`__scopeId`,`data-v-840dc960`]]),icons$2=Object.freeze({"4WD":{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/4WD.svg`},"9dividedby10":{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/9dividedby10.svg`},abandon:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/abandon.svg`},ABSIndicator:{glyph:``,size:24,tags:[`vehicle`,`features`,`warning`,`internals`],fileSvg:`svg/ABSIndicator.svg`},addItemPolygon:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`,`road tools`],fileSvg:`svg/addItemPolygon.svg`},addListItem:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`,`road tools`],fileSvg:`svg/addListItem.svg`},addPolygonVertex:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`,`road tools`],fileSvg:`svg/addPolygonVertex.svg`},adjust:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/adjust.svg`},AIMicrochip:{glyph:``,size:24,tags:[`generic`,`ai`,`microchip`],fileSvg:`svg/AIMicrochip.svg`},AIRace:{glyph:``,size:24,tags:[`poi`],fileSvg:`svg/AIRace.svg`},aperture:{glyph:``,size:24,tags:[`generic`,`camera`,`optical`,`sensor`],fileSvg:`svg/aperture.svg`},arrowLargeDown:{glyph:``,size:24,tags:[`arrow`,`large`,`simple`,`outlined`],fileSvg:`svg/arrowLargeDown.svg`},arrowLargeLeft:{glyph:``,size:24,tags:[`arrow`,`large`,`simple`,`outlined`],fileSvg:`svg/arrowLargeLeft.svg`},arrowLargeRight:{glyph:``,size:24,tags:[`arrow`,`large`,`simple`,`outlined`],fileSvg:`svg/arrowLargeRight.svg`},arrowLargeUp:{glyph:``,size:24,tags:[`arrow`,`large`,`simple`,`outlined`],fileSvg:`svg/arrowLargeUp.svg`},arrowSmallDown:{glyph:``,size:24,tags:[`arrow`,`small`,`simple`,`outlined`],fileSvg:`svg/arrowSmallDown.svg`},arrowSmallLeft:{glyph:``,size:24,tags:[`arrow`,`small`,`simple`,`outlined`],fileSvg:`svg/arrowSmallLeft.svg`},arrowSmallRight:{glyph:``,size:24,tags:[`arrow`,`small`,`simple`,`outlined`],fileSvg:`svg/arrowSmallRight.svg`},arrowSmallUp:{glyph:``,size:24,tags:[`arrow`,`small`,`simple`,`outlined`],fileSvg:`svg/arrowSmallUp.svg`},arrowSolidLeft:{glyph:``,size:24,tags:[`arrow`,`large`,`solid`,`detailed`],fileSvg:`svg/arrowSolidLeft.svg`},arrowSolidRight:{glyph:``,size:24,tags:[`arrow`,`large`,`solid`,`detailed`],fileSvg:`svg/arrowSolidRight.svg`},autobahn:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/autobahn.svg`},AWD:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/AWD.svg`},axleLift:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/axleLift.svg`},axleCenter:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/axleCenter.svg`},axleFront:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/axleFront.svg`},axleRear:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/axleRear.svg`},bSpline:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`,`road tools`],fileSvg:`svg/bSpline.svg`},banknotes:{glyph:``,size:24,tags:[`career`,`currencies`],fileSvg:`svg/banknotes.svg`},barrelKnocker01:{glyph:``,size:24,tags:[`poi`],fileSvg:`svg/barrelKnocker01.svg`},barrelKnocker02:{glyph:``,size:24,tags:[`poi`],fileSvg:`svg/barrelKnocker02.svg`},beamCrashBarrier1:{glyph:``,size:24,tags:[`generic`,`world editor`,`we`,`road tools`],fileSvg:`svg/beamCrashBarrier1.svg`},beamCrashBarrier2:{glyph:``,size:24,tags:[`generic`,`world editor`,`we`,`road tools`],fileSvg:`svg/beamCrashBarrier2.svg`},beamCrashBarrier3:{glyph:``,size:24,tags:[`generic`,`world editor`,`we`,`road tools`],fileSvg:`svg/beamCrashBarrier3.svg`},beamCurrency:{glyph:``,size:24,tags:[`career`,`currencies`],fileSvg:`svg/beamCurrency.svg`},beamNG:{glyph:``,size:24,tags:[`brand`,`beamng`,`generic`],fileSvg:`svg/beamNG.svg`},beamXPFull:{glyph:``,size:24,tags:[`career`,`currencies`],fileSvg:`svg/beamXPFull.svg`},beamXPLo:{glyph:``,size:24,tags:[`career`,`currencies`],fileSvg:`svg/beamXPLo.svg`},bezierPath1:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`,`road tools`],fileSvg:`svg/bezierPath1.svg`},bezierPath2:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`,`road tools`],fileSvg:`svg/bezierPath2.svg`},bicycle1:{glyph:``,size:24,tags:[`generic`,`world editor`,`we`,`road tools`],fileSvg:`svg/bicycle1.svg`},bicycle2:{glyph:``,size:24,tags:[`generic`,`world editor`,`we`,`road tools`],fileSvg:`svg/bicycle2.svg`},BNGFolder:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/BNGFolder.svg`},BNGMicrochip:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/BNGMicrochip.svg`},bollard:{glyph:``,size:24,tags:[`generic`,`world editor`,`we`,`road tools`],fileSvg:`svg/bollard.svg`},bookmark:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/bookmark.svg`},booleanIntersect:{glyph:``,size:24,tags:[`decals`,`generic`],fileSvg:`svg/booleanIntersect.svg`},boxDropOff01:{glyph:``,size:24,tags:[`poi`,`delivery`],fileSvg:`svg/boxDropOff01.svg`},boxDropOff02:{glyph:``,size:24,tags:[`poi`,`delivery`],fileSvg:`svg/boxDropOff02.svg`},boxDropOff03:{glyph:``,size:24,tags:[`poi`,`delivery`],fileSvg:`svg/boxDropOff03.svg`},boxPickUp01:{glyph:``,size:24,tags:[`poi`,`delivery`],fileSvg:`svg/boxPickUp01.svg`},boxPickUp02:{glyph:``,size:24,tags:[`poi`,`delivery`],fileSvg:`svg/boxPickUp02.svg`},boxPickUp03:{glyph:``,size:24,tags:[`poi`,`delivery`],fileSvg:`svg/boxPickUp03.svg`},boxPickUpDropOff01:{glyph:``,size:24,tags:[`poi`,`delivery`],fileSvg:`svg/boxPickUpDropOff01.svg`},boxPickUpDropOff02:{glyph:``,size:24,tags:[`poi`,`delivery`],fileSvg:`svg/boxPickUpDropOff02.svg`},boxTruck:{glyph:``,size:24,tags:[`cargo`,`delivery`,`vehicle`],fileSvg:`svg/boxTruck.svg`},broom:{glyph:``,size:24,tags:[`generic`,`sound`],fileSvg:`svg/broom.svg`},bucketAdd:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/bucketAdd.svg`},bucketSubtract:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/bucketSubtract.svg`},bug:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/bug.svg`},bulldozer:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`,`road tools`],fileSvg:`svg/bulldozer.svg`},bus:{glyph:``,size:24,tags:[`poi`,`vehicle`],fileSvg:`svg/bus.svg`},camera3Fourth1:{glyph:``,size:24,tags:[`camera`],fileSvg:`svg/camera3Fourth1.svg`},cameraBack1:{glyph:``,size:24,tags:[`camera`],fileSvg:`svg/cameraBack1.svg`},cameraFocusOnPath:{glyph:``,size:24,tags:[`camera`],fileSvg:`svg/cameraFocusOnPath.svg`},cameraFocusOnVehicle1:{glyph:``,size:24,tags:[`camera`],fileSvg:`svg/cameraFocusOnVehicle1.svg`},cameraFocusOnVehicle2:{glyph:``,size:24,tags:[`camera`,`decals`],fileSvg:`svg/cameraFocusOnVehicle2.svg`},cameraFocusTopDown:{glyph:``,size:24,tags:[`camera`],fileSvg:`svg/cameraFocusTopDown.svg`},cameraFront1:{glyph:``,size:24,tags:[`camera`],fileSvg:`svg/cameraFront1.svg`},cameraSideLeft:{glyph:``,size:24,tags:[`camera`],fileSvg:`svg/cameraSideLeft.svg`},cameraSideLeft2:{glyph:``,size:24,tags:[`camera`],fileSvg:`svg/cameraSideLeft2.svg`},cameraSideRight:{glyph:``,size:24,tags:[`camera`],fileSvg:`svg/cameraSideRight.svg`},cameraSideRight2:{glyph:``,size:24,tags:[`camera`],fileSvg:`svg/cameraSideRight2.svg`},cameraTop1:{glyph:``,size:24,tags:[`camera`],fileSvg:`svg/cameraTop1.svg`},cannon:{glyph:``,size:24,tags:[`poi`],fileSvg:`svg/cannon.svg`},carChase01:{glyph:``,size:24,tags:[`generic`,`police`,`vehicle`],fileSvg:`svg/carChase01.svg`},carCoin:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/carCoin.svg`},carCoins:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/carCoins.svg`},carCrash:{glyph:``,size:24,tags:[`generic`,`vehicle`],fileSvg:`svg/carCrash.svg`},carDealer:{glyph:``,size:24,tags:[`career`,`garage`,`features`],fileSvg:`svg/carDealer.svg`},carOffroadOutlineRear:{glyph:``,size:24,tags:[`generic`,`vehicle`],fileSvg:`svg/carOffroadOutlineRear.svg`},carOffroadOutlineSide:{glyph:``,size:24,tags:[`generic`,`vehicle`],fileSvg:`svg/carOffroadOutlineSide.svg`},carOffroadRear:{glyph:``,size:24,tags:[`generic`,`vehicle`],fileSvg:`svg/carOffroadRear.svg`},carOffroadSide:{glyph:``,size:24,tags:[`generic`,`vehicle`],fileSvg:`svg/carOffroadSide.svg`},carSensors:{glyph:``,size:24,tags:[`generic`,`vehicle`,`sensors`],fileSvg:`svg/carSensors.svg`},carStarred:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/carStarred.svg`},carToWheels:{glyph:``,size:24,tags:[`generic`,`vehicle`],fileSvg:`svg/carToWheels.svg`},carUp:{glyph:``,size:24,tags:[`generic`,`vehicle`],fileSvg:`svg/carUp.svg`},carWithLidar:{glyph:``,size:24,tags:[`generic`,`vehicle`,`tech`,`sensors`],fileSvg:`svg/carWithLidar.svg`},car:{glyph:``,size:24,tags:[`generic`,`vehicle`],fileSvg:`svg/car.svg`},cardboardBox:{glyph:``,size:24,tags:[`generic`,`delivery`],fileSvg:`svg/cardboardBox.svg`},carsChase02:{glyph:``,size:24,tags:[`generic`,`police`,`vehicle`],fileSvg:`svg/carsChase02.svg`},cars:{glyph:``,size:24,tags:[`generic`,`vehicle`],fileSvg:`svg/cars.svg`},catalog01:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/catalog01.svg`},catalog02:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/catalog02.svg`},catalog03:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/catalog03.svg`},centrifugalClutchLocked03:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/centrifugalClutchLocked03.svg`},centrifugalClutchUnlocked03:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/centrifugalClutchUnlocked03.svg`},charge:{glyph:``,size:24,tags:[`fuel`,`electricity`,`ev`],fileSvg:`svg/charge.svg`},charging:{glyph:``,size:24,tags:[`fuel`,`electricity`,`ev`],fileSvg:`svg/charging.svg`},chartBars:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/chartBars.svg`},checkboxOff:{glyph:``,size:24,tags:[`checkbox`,`selection`,`box`],fileSvg:`svg/checkboxOff.svg`},checkboxOn:{glyph:``,size:24,tags:[`checkbox`,`selection`,`box`],fileSvg:`svg/checkboxOn.svg`},checkmarkBold:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/checkmarkBold.svg`},checkmark:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/checkmark.svg`},circuitMicrochip:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/circuitMicrochip.svg`},circuit:{glyph:``,size:24,tags:[`poi`],fileSvg:`svg/circuit.svg`},clapperboard:{glyph:``,size:24,tags:[`generic`,`movie`,`scenery`],fileSvg:`svg/clapperboard.svg`},code:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/code.svg`},cogDamaged:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/cogDamaged.svg`},cogsDamaged:{glyph:``,size:24,tags:[`vehicle`,`features`,`powertrain`,`drivetrain`],fileSvg:`svg/cogsDamaged.svg`},cogs:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/cogs.svg`},concreteRoadBlock:{glyph:``,size:24,tags:[`generic`,`world editor`,`we`,`road tools`],fileSvg:`svg/concreteRoadBlock.svg`},coolantTemp:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/coolantTemp.svg`},copy:{glyph:``,size:24,tags:[`decals`,`generic`],fileSvg:`svg/copy.svg`},crossroads1:{glyph:``,size:24,tags:[`generic`,`world editor`,`we`,`road tools`],fileSvg:`svg/crossroads1.svg`},crossroads2:{glyph:``,size:24,tags:[`generic`,`world editor`,`we`,`road tools`],fileSvg:`svg/crossroads2.svg`},cruiseDisable:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/cruiseDisable.svg`},cruiseEnable:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/cruiseEnable.svg`},cup:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/cup.svg`},dataExchange:{glyph:``,size:24,tags:[`generic`,`data`,`signal`],fileSvg:`svg/dataExchange.svg`},day:{glyph:``,size:24,tags:[`environment`],fileSvg:`svg/day.svg`},DCBattery:{glyph:``,size:24,tags:[`vehicle`,`features`,`warning`,`internals`],fileSvg:`svg/DCBattery.svg`},decalRoad:{glyph:``,size:24,tags:[`generic`,`world editor`,`we`,`road tools`],fileSvg:`svg/decalRoad.svg`},decal:{glyph:``,size:24,tags:[`decals`,`generic`],fileSvg:`svg/decal.svg`},deform:{glyph:``,size:24,tags:[`decals`,`generic`],fileSvg:`svg/deform.svg`},deliveryTruckArrows:{glyph:``,size:24,tags:[`poi`,`delivery`,`vehicle`],fileSvg:`svg/deliveryTruckArrows.svg`},deliveryTruck:{glyph:``,size:24,tags:[`poi`,`delivery`,`vehicle`],fileSvg:`svg/deliveryTruck.svg`},differentialFrontDefault:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/differentialFrontDefault.svg`},differentialFrontLocked:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/differentialFrontLocked.svg`},differentialMiddleDefault:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/differentialMiddleDefault.svg`},differentialMiddleLocked:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/differentialMiddleLocked.svg`},differentialRearDefault:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/differentialRearDefault.svg`},differentialRearLocked:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/differentialRearLocked.svg`},doorHandle:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/doorHandle.svg`},doorIn:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/doorIn.svg`},drag01:{glyph:``,size:24,tags:[`poi`],fileSvg:`svg/drag01.svg`},drag02:{glyph:``,size:24,tags:[`poi`],fileSvg:`svg/drag02.svg`},drift01:{glyph:``,size:24,tags:[`poi`,`vehicle`],fileSvg:`svg/drift01.svg`},drift02:{glyph:``,size:24,tags:[`poi`,`vehicle`],fileSvg:`svg/drift02.svg`},drivetrainGeneric:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/drivetrainGeneric.svg`},drivetrainSpecial:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/drivetrainSpecial.svg`},editCheckmark:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/editCheckmark.svg`},edit:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/edit.svg`},engine:{glyph:``,size:24,tags:[`vehicle`,`part`,`features`],fileSvg:`svg/engine.svg`},ESCOff:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/ESCOff.svg`},ESCOn:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/ESCOn.svg`},ESC:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/ESC.svg`},evade:{glyph:``,size:24,tags:[`poi`,`mission`,`police`],fileSvg:`svg/evade.svg`},exhaustValve:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/exhaustValve.svg`},exit:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/exit.svg`},export:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/export.svg`},eyeOutlineClosed:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/eyeOutlineClosed.svg`},eyeOutlineOpened:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/eyeOutlineOpened.svg`},eyeSolidClosed:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/eyeSolidClosed.svg`},eyeSolidOpened:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/eyeSolidOpened.svg`},eyeWaves:{glyph:``,size:24,tags:[`generic`,`data`,`signal`,`sensor`],fileSvg:`svg/eyeWaves.svg`},facility02:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/facility02.svg`},fastBackward:{glyph:``,size:24,tags:[`playback`],fileSvg:`svg/fastBackward.svg`},fastForward:{glyph:``,size:24,tags:[`playback`],fileSvg:`svg/fastForward.svg`},fastTravel:{glyph:``,size:24,tags:[`poi`],fileSvg:`svg/fastTravel.svg`},filter:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/filter.svg`},flagNew:{glyph:``,size:24,tags:[`poi`],fileSvg:`svg/flagNew.svg`},flag:{glyph:``,size:24,tags:[`poi`],fileSvg:`svg/flag.svg`},flatBulbBeam:{glyph:``,size:24,tags:[`generic`,`world editor`,`we`,`sensor`],fileSvg:`svg/flatBulbBeam.svg`},flatbedTruck:{glyph:``,size:24,tags:[`cargo`,`delivery`,`vehicle`,`truck`],fileSvg:`svg/flatbedTruck.svg`},floppyDisk:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/floppyDisk.svg`},fogLight:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/fogLight.svg`},folder:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/folder.svg`},forklift:{glyph:``,size:24,tags:[`delivery`,`stencil`,`cargo`,`vehicle`],fileSvg:`svg/forklift.svg`},FPS:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/FPS.svg`},fragile:{glyph:``,size:24,tags:[`delivery`,`stencil`,`cargo`],fileSvg:`svg/fragile.svg`},frontAxleMidpoint:{glyph:``,size:24,tags:[`generic`,`world editor`,`we`,`placement`,`sensor`],fileSvg:`svg/frontAxleMidpoint.svg`},frontBumperMidpoint:{glyph:``,size:24,tags:[`generic`,`world editor`,`we`,`placement`,`sensor`],fileSvg:`svg/frontBumperMidpoint.svg`},fuelPumpFilling:{glyph:``,size:24,tags:[`fuel`],fileSvg:`svg/fuelPumpFilling.svg`},fuelPump:{glyph:``,size:24,tags:[`fuel`],fileSvg:`svg/fuelPump.svg`},FWD:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/FWD.svg`},gamepadOld:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/gamepadOld.svg`},gamepad:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/gamepad.svg`},garage01:{glyph:``,size:24,tags:[`career`,`garage`,`features`],fileSvg:`svg/garage01.svg`},garage02:{glyph:``,size:24,tags:[`career`,`garage`,`features`],fileSvg:`svg/garage02.svg`},garage03:{glyph:``,size:24,tags:[`career`,`garage`,`features`],fileSvg:`svg/garage03.svg`},gaugeEmpty:{glyph:``,size:24,tags:[`poi`],fileSvg:`svg/gaugeEmpty.svg`},globe:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/globe.svg`},GPSMark:{glyph:``,size:24,tags:[`generic`,`gps`,`position`,`map`,`sensor`],fileSvg:`svg/GPSMark.svg`},GPSSolid:{glyph:``,size:24,tags:[`generic`,`gps`,`position`,`map`,`sensor`],fileSvg:`svg/GPSSolid.svg`},group:{glyph:``,size:24,tags:[`decals`,`generic`],fileSvg:`svg/group.svg`},gyroscopeMicrochip:{glyph:``,size:24,tags:[`generic`,`data`,`signal`,`sensor`],fileSvg:`svg/gyroscopeMicrochip.svg`},gyroscope:{glyph:``,size:24,tags:[`generic`,`data`,`signal`,`sensor`],fileSvg:`svg/gyroscope.svg`},hazardLights:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/hazardLights.svg`},helmets:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/helmets.svg`},help:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/help.svg`},highBeam:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/highBeam.svg`},HUD:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/HUD.svg`},hydroPump1:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/hydroPump1.svg`},hydroPump2:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/hydroPump2.svg`},hydroPump3:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/hydroPump3.svg`},hydroPump4:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/hydroPump4.svg`},hydroPump5:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/hydroPump5.svg`},hydroPump6:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/hydroPump6.svg`},hydroPump7:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/hydroPump7.svg`},hypermiling:{glyph:``,size:24,tags:[`poi`],fileSvg:`svg/hypermiling.svg`},import:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/import.svg`},infinity:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/infinity.svg`},info:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/info.svg`},jointLocked:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/jointLocked.svg`},jointUnlocked:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/jointUnlocked.svg`},jump:{glyph:``,size:24,tags:[`poi`],fileSvg:`svg/jump.svg`},keyboard:{glyph:``,size:24,tags:[`keyboard`,`input`],fileSvg:`svg/keyboard.svg`},keys1:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/keys1.svg`},keys2:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/keys2.svg`},lampPost1:{glyph:``,size:24,tags:[`generic`,`world editor`,`we`,`road tools`],fileSvg:`svg/lampPost1.svg`},lampPost2:{glyph:``,size:24,tags:[`generic`,`world editor`,`we`,`road tools`],fileSvg:`svg/lampPost2.svg`},lampPost3:{glyph:``,size:24,tags:[`generic`,`world editor`,`we`,`road tools`],fileSvg:`svg/lampPost3.svg`},laneProperties:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`,`road tools`],fileSvg:`svg/laneProperties.svg`},language:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/language.svg`},laptop:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/laptop.svg`},lidarPatternFullArcHighFreq:{glyph:``,size:24,tags:[`generic`,`world editor`,`we`,`sensor`],fileSvg:`svg/lidarPatternFullArcHighFreq.svg`},lidarPatternFullArcMidFreq:{glyph:``,size:24,tags:[`generic`,`world editor`,`we`,`sensor`],fileSvg:`svg/lidarPatternFullArcMidFreq.svg`},lidarPatternNarrowArc:{glyph:``,size:24,tags:[`generic`,`world editor`,`we`,`sensor`],fileSvg:`svg/lidarPatternNarrowArc.svg`},lidar:{glyph:``,size:24,tags:[`generic`,`data`,`signal`,`sensor`],fileSvg:`svg/lidar.svg`},lightGarageG11:{glyph:``,size:24,tags:[`career`,`garage`,`lights`],fileSvg:`svg/lightGarageG11.svg`},lightGarageG12:{glyph:``,size:24,tags:[`career`,`garage`,`lights`],fileSvg:`svg/lightGarageG12.svg`},lightGarageG13:{glyph:``,size:24,tags:[`career`,`garage`,`lights`],fileSvg:`svg/lightGarageG13.svg`},lightGarageG14:{glyph:``,size:24,tags:[`career`,`garage`,`lights`],fileSvg:`svg/lightGarageG14.svg`},lightGarageG21:{glyph:``,size:24,tags:[`career`,`garage`,`lights`],fileSvg:`svg/lightGarageG21.svg`},lightGarageG22:{glyph:``,size:24,tags:[`career`,`garage`,`lights`],fileSvg:`svg/lightGarageG22.svg`},lightGarageG23:{glyph:``,size:24,tags:[`career`,`garage`,`lights`],fileSvg:`svg/lightGarageG23.svg`},lightGarageG24:{glyph:``,size:24,tags:[`career`,`garage`,`lights`],fileSvg:`svg/lightGarageG24.svg`},lightGarageG31:{glyph:``,size:24,tags:[`career`,`garage`,`lights`],fileSvg:`svg/lightGarageG31.svg`},lightGarageG32:{glyph:``,size:24,tags:[`career`,`garage`,`lights`],fileSvg:`svg/lightGarageG32.svg`},lightGarageG33:{glyph:``,size:24,tags:[`career`,`garage`,`lights`],fileSvg:`svg/lightGarageG33.svg`},lightGarageG34:{glyph:``,size:24,tags:[`career`,`garage`,`lights`],fileSvg:`svg/lightGarageG34.svg`},lightrunner:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/lightrunner.svg`},limiterEnable:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/limiterEnable.svg`},lineToTerrain:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`,`road tools`],fileSvg:`svg/lineToTerrain.svg`},link2:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/link2.svg`},link:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/link.svg`},listBig:{glyph:``,size:24,tags:[`generic`,`catalog`,`selector`,`view`],fileSvg:`svg/listBig.svg`},listIndented:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/listIndented.svg`},listSmall:{glyph:``,size:24,tags:[`generic`,`catalog`,`selector`,`view`],fileSvg:`svg/listSmall.svg`},location1:{glyph:``,size:24,tags:[`generic`,`gps`,`position`,`map`,`sensor`],fileSvg:`svg/location1.svg`},location2:{glyph:``,size:24,tags:[`generic`,`gps`,`position`,`map`,`sensor`],fileSvg:`svg/location2.svg`},lockClosed:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/lockClosed.svg`},lockOpened:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/lockOpened.svg`},longRangeBeam1:{glyph:``,size:24,tags:[`generic`,`world editor`,`we`,`sensor`],fileSvg:`svg/longRangeBeam1.svg`},longRangeBeam2:{glyph:``,size:24,tags:[`generic`,`world editor`,`we`,`sensor`],fileSvg:`svg/longRangeBeam2.svg`},lowBeam:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/lowBeam.svg`},magnetOnSurface:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`,`road tools`],fileSvg:`svg/magnetOnSurface.svg`},mapWithEmitter:{glyph:``,size:24,tags:[`generic`,`tech`,`sensors`],fileSvg:`svg/mapWithEmitter.svg`},mapPoint:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/mapPoint.svg`},material:{glyph:``,size:24,tags:[`decals`,`generic`],fileSvg:`svg/material.svg`},mathDivide:{glyph:``,size:24,tags:[`generic`,`math`,`operands`,`small`],fileSvg:`svg/mathDivide.svg`},mathGreaterOrEqualThan:{glyph:``,size:24,tags:[`generic`,`math`,`operands`,`small`],fileSvg:`svg/mathGreaterOrEqualThan.svg`},mathGreaterThan:{glyph:``,size:24,tags:[`generic`,`math`,`operands`,`small`],fileSvg:`svg/mathGreaterThan.svg`},mathLessOrEqualThan:{glyph:``,size:24,tags:[`generic`,`math`,`operands`,`small`],fileSvg:`svg/mathLessOrEqualThan.svg`},mathLessThan:{glyph:``,size:24,tags:[`generic`,`math`,`operands`,`small`],fileSvg:`svg/mathLessThan.svg`},mathMinus:{glyph:``,size:24,tags:[`generic`,`math`,`operands`,`small`],fileSvg:`svg/mathMinus.svg`},mathMultiply:{glyph:``,size:24,tags:[`generic`,`math`,`operands`,`small`],fileSvg:`svg/mathMultiply.svg`},mathPlus:{glyph:``,size:24,tags:[`generic`,`math`,`operands`,`small`],fileSvg:`svg/mathPlus.svg`},medal:{glyph:``,size:24,tags:[`generic`,`reward`,`achievment`],fileSvg:`svg/medal.svg`},mesh4Cells:{glyph:``,size:24,tags:[`tech`,`mesh`,`beams`,`nodes`,`surface`],fileSvg:`svg/mesh4Cells.svg`},mesh9Cells:{glyph:``,size:24,tags:[`tech`,`mesh`,`beams`,`nodes`,`surface`],fileSvg:`svg/mesh9Cells.svg`},meshFence:{glyph:``,size:24,tags:[`generic`,`world editor`,`we`,`road tools`],fileSvg:`svg/meshFence.svg`},meshRoad:{glyph:``,size:24,tags:[`generic`,`world editor`,`we`,`road tools`],fileSvg:`svg/meshRoad.svg`},midRangeBeam1:{glyph:``,size:24,tags:[`generic`,`world editor`,`we`,`sensor`],fileSvg:`svg/midRangeBeam1.svg`},midRangeBeam2:{glyph:``,size:24,tags:[`generic`,`world editor`,`we`,`sensor`],fileSvg:`svg/midRangeBeam2.svg`},minusRes:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/minusRes.svg`},minus:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/minus.svg`},mirrorInteriorMiddle:{glyph:``,size:24,tags:[`vehicle`,`features`,`mirror`,`rearview`],fileSvg:`svg/mirrorInteriorMiddle.svg`},mirrorLeftBigBottomWideAngle:{glyph:``,size:24,tags:[`vehicle`,`features`,`mirror`,`rearview`],fileSvg:`svg/mirrorLeftBigBottomWideAngle.svg`},mirrorLeftBigTop:{glyph:``,size:24,tags:[`vehicle`,`features`,`mirror`,`rearview`],fileSvg:`svg/mirrorLeftBigTop.svg`},mirrorLeftBig:{glyph:``,size:24,tags:[`vehicle`,`features`,`mirror`,`rearview`],fileSvg:`svg/mirrorLeftBig.svg`},mirrorLeftBonnet:{glyph:``,size:24,tags:[`vehicle`,`features`,`mirror`,`rearview`],fileSvg:`svg/mirrorLeftBonnet.svg`},mirrorLeftDefault:{glyph:``,size:24,tags:[`vehicle`,`features`,`mirror`,`rearview`],fileSvg:`svg/mirrorLeftDefault.svg`},mirrorRightBigBottomWideAngle:{glyph:``,size:24,tags:[`vehicle`,`features`,`mirror`,`rearview`],fileSvg:`svg/mirrorRightBigBottomWideAngle.svg`},mirrorRightBigTop:{glyph:``,size:24,tags:[`vehicle`,`features`,`mirror`,`rearview`],fileSvg:`svg/mirrorRightBigTop.svg`},mirrorRightBig:{glyph:``,size:24,tags:[`vehicle`,`features`,`mirror`,`rearview`],fileSvg:`svg/mirrorRightBig.svg`},mirrorRightBonnet:{glyph:``,size:24,tags:[`vehicle`,`features`,`mirror`,`rearview`],fileSvg:`svg/mirrorRightBonnet.svg`},mirrorRightDefault:{glyph:``,size:24,tags:[`vehicle`,`features`,`mirror`,`rearview`],fileSvg:`svg/mirrorRightDefault.svg`},mirrorRoundWideAngle:{glyph:``,size:24,tags:[`vehicle`,`features`,`mirror`,`rearview`],fileSvg:`svg/mirrorRoundWideAngle.svg`},mirrorTopWideAngle:{glyph:``,size:24,tags:[`vehicle`,`features`,`mirror`,`rearview`],fileSvg:`svg/mirrorTopWideAngle.svg`},missionCheckboxCross:{glyph:``,size:24,tags:[`checkbox`,`selection`,`box`],fileSvg:`svg/missionCheckboxCross.svg`},mouseLMB:{glyph:``,size:24,tags:[`mouse`,`input`],fileSvg:`svg/mouseLMB.svg`},mouseMMB:{glyph:``,size:24,tags:[`mouse`,`input`],fileSvg:`svg/mouseMMB.svg`},mouseRMB:{glyph:``,size:24,tags:[`mouse`,`input`],fileSvg:`svg/mouseRMB.svg`},mouseWheel:{glyph:``,size:24,tags:[`mouse`,`input`],fileSvg:`svg/mouseWheel.svg`},mouseXAxis:{glyph:``,size:24,tags:[`mouse`,`input`],fileSvg:`svg/mouseXAxis.svg`},mouseXYAxis:{glyph:``,size:24,tags:[`mouse`,`input`],fileSvg:`svg/mouseXYAxis.svg`},mouseYAxis:{glyph:``,size:24,tags:[`mouse`,`input`],fileSvg:`svg/mouseYAxis.svg`},mouse:{glyph:``,size:24,tags:[`mouse`,`input`],fileSvg:`svg/mouse.svg`},move02:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/move02.svg`},move:{glyph:``,size:24,tags:[`decals`,`generic`],fileSvg:`svg/move.svg`},movieCamera:{glyph:``,size:24,tags:[`camera`],fileSvg:`svg/movieCamera.svg`},music:{glyph:``,size:24,tags:[`playback`],fileSvg:`svg/music.svg`},N2OButton:{glyph:``,size:24,tags:[`fuel`],fileSvg:`svg/N2OButton.svg`},N2OHoriz:{glyph:``,size:24,tags:[`fuel`],fileSvg:`svg/N2OHoriz.svg`},N2OVert:{glyph:``,size:24,tags:[`fuel`],fileSvg:`svg/N2OVert.svg`},nextTrack:{glyph:``,size:24,tags:[`playback`],fileSvg:`svg/nextTrack.svg`},night:{glyph:``,size:24,tags:[`environment`],fileSvg:`svg/night.svg`},noNameControllerButton:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/noNameControllerButton.svg`},nodeAddFirst01:{glyph:``,size:24,tags:[`generic`,`path`,`node`],fileSvg:`svg/nodeAddFirst01.svg`},nodeAddFirst02:{glyph:``,size:24,tags:[`generic`,`path`,`node`],fileSvg:`svg/nodeAddFirst02.svg`},nodeAddLast02:{glyph:``,size:24,tags:[`generic`,`path`,`node`],fileSvg:`svg/nodeAddLast02.svg`},nodeAddMiddle01:{glyph:``,size:24,tags:[`generic`,`path`,`node`],fileSvg:`svg/nodeAddMiddle01.svg`},nodeAddMiddle02:{glyph:``,size:24,tags:[`generic`,`path`,`node`],fileSvg:`svg/nodeAddMiddle02.svg`},nodeAdd:{glyph:``,size:24,tags:[`generic`,`path`,`node`],fileSvg:`svg/nodeAdd.svg`},nodeLast01:{glyph:``,size:24,tags:[`generic`,`path`,`node`],fileSvg:`svg/nodeLast01.svg`},nodeRemove:{glyph:``,size:24,tags:[`generic`,`path`,`node`],fileSvg:`svg/nodeRemove.svg`},odometerKM:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/odometerKM.svg`},odometerMI:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/odometerMI.svg`},odometer:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/odometer.svg`},oilPressureIndicator:{glyph:``,size:24,tags:[`vehicle`,`features`,`warning`,`internals`],fileSvg:`svg/oilPressureIndicator.svg`},order:{glyph:``,size:24,tags:[`decals`,`generic`],fileSvg:`svg/order.svg`},organization:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/organization.svg`},palmCrossed:{glyph:``,size:24,tags:[`touch`,`input`],fileSvg:`svg/palmCrossed.svg`},paperKnife:{glyph:``,size:24,tags:[`decals`,`generic`],fileSvg:`svg/paperKnife.svg`},parkingIndicator:{glyph:``,size:24,tags:[`vehicle`,`features`,`warning`,`internals`],fileSvg:`svg/parkingIndicator.svg`},parking:{glyph:``,size:24,tags:[`poi`],fileSvg:`svg/parking.svg`},pathArc:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`,`road tools`],fileSvg:`svg/pathArc.svg`},pathAroundObstacle:{glyph:``,size:24,tags:[`camera`],fileSvg:`svg/pathAroundObstacle.svg`},pathLine:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`,`road tools`],fileSvg:`svg/pathLine.svg`},pathSpiral:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`,`road tools`],fileSvg:`svg/pathSpiral.svg`},pauseRound:{glyph:``,size:24,tags:[`playback`],fileSvg:`svg/pauseRound.svg`},pause:{glyph:``,size:24,tags:[`playback`],fileSvg:`svg/pause.svg`},personSolid:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/personSolid.svg`},person:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/person.svg`},photo:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/photo.svg`},placeholder:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/placeholder.svg`},playRound:{glyph:``,size:24,tags:[`playback`],fileSvg:`svg/playRound.svg`},play:{glyph:``,size:24,tags:[`playback`],fileSvg:`svg/play.svg`},playlist:{glyph:``,size:24,tags:[`playback`],fileSvg:`svg/playlist.svg`},plusGarage1:{glyph:``,size:24,tags:[`career`,`garage`,`features`],fileSvg:`svg/plusGarage1.svg`},plusGarage2:{glyph:``,size:24,tags:[`career`,`garage`,`features`],fileSvg:`svg/plusGarage2.svg`},plusGarage3:{glyph:``,size:24,tags:[`career`,`garage`,`features`],fileSvg:`svg/plusGarage3.svg`},plusGarage4:{glyph:``,size:24,tags:[`career`,`garage`,`features`],fileSvg:`svg/plusGarage4.svg`},plusSet:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/plusSet.svg`},plus:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/plus.svg`},positionLights:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/positionLights.svg`},powerGauge01:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/powerGauge01.svg`},powerGauge02:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/powerGauge02.svg`},powerGauge03:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/powerGauge03.svg`},powerGauge04:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/powerGauge04.svg`},powerGauge05:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/powerGauge05.svg`},powerOnOff:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/powerOnOff.svg`},prevTrack:{glyph:``,size:24,tags:[`playback`],fileSvg:`svg/prevTrack.svg`},publisher:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/publisher.svg`},puzzleModule:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/puzzleModule.svg`},raceFlag:{glyph:``,size:24,tags:[`poi`],fileSvg:`svg/raceFlag.svg`},radarIdeal:{glyph:``,size:24,tags:[`generic`,`data`,`signal`,`sensor`],fileSvg:`svg/radarIdeal.svg`},radarRoundIdeal:{glyph:``,size:24,tags:[`generic`,`data`,`signal`,`sensor`],fileSvg:`svg/radarRoundIdeal.svg`},radarRound:{glyph:``,size:24,tags:[`generic`,`data`,`signal`,`sensor`],fileSvg:`svg/radarRound.svg`},radar:{glyph:``,size:24,tags:[`generic`,`data`,`signal`,`sensor`],fileSvg:`svg/radar.svg`},rangeboxHi2:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/rangeboxHi2.svg`},rangeboxHi4:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/rangeboxHi4.svg`},rangeboxHiA:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/rangeboxHiA.svg`},rangeboxLo2:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/rangeboxLo2.svg`},rangeboxLo4:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/rangeboxLo4.svg`},rangeboxLoA:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/rangeboxLoA.svg`},rearAxleMidpoint:{glyph:``,size:24,tags:[`generic`,`world editor`,`we`,`placement`,`sensor`],fileSvg:`svg/rearAxleMidpoint.svg`},rearBumperMidpoint:{glyph:``,size:24,tags:[`generic`,`world editor`,`we`,`placement`,`sensor`],fileSvg:`svg/rearBumperMidpoint.svg`},reconfigure:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/reconfigure.svg`},redo:{glyph:``,size:24,tags:[`decals`,`generic`],fileSvg:`svg/redo.svg`},reflectNot:{glyph:``,size:24,tags:[`decals`,`generic`],fileSvg:`svg/reflectNot.svg`},reflect:{glyph:``,size:24,tags:[`decals`,`generic`],fileSvg:`svg/reflect.svg`},rename:{glyph:``,size:24,tags:[`decals`,`generic`],fileSvg:`svg/rename.svg`},replay:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/replay.svg`},restart:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/restart.svg`},roadDividerLinesDecal:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`,`road tools`],fileSvg:`svg/roadDividerLinesDecal.svg`},roadEdgeLineDecal:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`,`road tools`],fileSvg:`svg/roadEdgeLineDecal.svg`},roadEndLineDecal:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`,`road tools`],fileSvg:`svg/roadEndLineDecal.svg`},roadFace:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`,`road tools`],fileSvg:`svg/roadFace.svg`},roadInfo:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/roadInfo.svg`},roadMarkingOutline:{glyph:``,size:24,tags:[`generic`,`world editor`,`we`,`outlined`],fileSvg:`svg/roadMarkingOutline.svg`},roadMarkingSolid:{glyph:``,size:24,tags:[`generic`,`world editor`,`we`,`road tools`],fileSvg:`svg/roadMarkingSolid.svg`},roadOutline:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`,`road tools`],fileSvg:`svg/roadOutline.svg`},roadRefPathDecal:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`,`road tools`],fileSvg:`svg/roadRefPathDecal.svg`},roadRefPath:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`,`road tools`],fileSvg:`svg/roadRefPath.svg`},roadStartLineDecal:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`,`road tools`],fileSvg:`svg/roadStartLineDecal.svg`},road:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/road.svg`},rockCrawling01:{glyph:``,size:24,tags:[`poi`,`vehicle`],fileSvg:`svg/rockCrawling01.svg`},rockCrawling02:{glyph:``,size:24,tags:[`poi`],fileSvg:`svg/rockCrawling02.svg`},routeAdd:{glyph:``,size:24,tags:[`route`,`traffic`],fileSvg:`svg/routeAdd.svg`},routeComplex:{glyph:``,size:24,tags:[`route`,`traffic`],fileSvg:`svg/routeComplex.svg`},routeSimple:{glyph:``,size:24,tags:[`route`,`traffic`],fileSvg:`svg/routeSimple.svg`},runScript:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/runScript.svg`},RWD:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/RWD.svg`},saveAs1:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/saveAs1.svg`},scan:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/scan.svg`},search:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/search.svg`},semiTrailer:{glyph:``,size:24,tags:[`cargo`,`delivery`,`trailer`,`vehicle`],fileSvg:`svg/semiTrailer.svg`},semiTruckCabover:{glyph:``,size:24,tags:[`cargo`,`delivery`,`vehicle`,`truck`],fileSvg:`svg/semiTruckCabover.svg`},semiTruckUS:{glyph:``,size:24,tags:[`cargo`,`delivery`,`vehicle`,`truck`],fileSvg:`svg/semiTruckUS.svg`},semiTruck:{glyph:``,size:24,tags:[`cargo`,`delivery`,`truck`,`trailer`,`vehicle`],fileSvg:`svg/semiTruck.svg`},shortRangeBeam1:{glyph:``,size:24,tags:[`generic`,`world editor`,`we`,`sensor`],fileSvg:`svg/shortRangeBeam1.svg`},shortRangeBeam2:{glyph:``,size:24,tags:[`generic`,`world editor`,`we`,`sensor`],fileSvg:`svg/shortRangeBeam2.svg`},signal01a:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/signal01a.svg`},signal02a:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/signal02a.svg`},signal03a:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/signal03a.svg`},signal04a:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/signal04a.svg`},signal05a:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/signal05a.svg`},slashLeft:{glyph:``,size:24,tags:[`generic`,`math`,`operands`,`small`],fileSvg:`svg/slashLeft.svg`},slashRight:{glyph:``,size:24,tags:[`generic`,`math`,`operands`,`small`],fileSvg:`svg/slashRight.svg`},smallTrailer:{glyph:``,size:24,tags:[`cargo`,`delivery`,`trailer`,`vehicle`],fileSvg:`svg/smallTrailer.svg`},smartphone1:{glyph:``,size:24,tags:[`touch`,`input`],fileSvg:`svg/smartphone1.svg`},smartphone2:{glyph:``,size:24,tags:[`touch`,`input`],fileSvg:`svg/smartphone2.svg`},snowflake:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/snowflake.svg`},soundFadeOut:{glyph:``,size:24,tags:[`generic`,`sound`],fileSvg:`svg/soundFadeOut.svg`},soundLimit:{glyph:``,size:24,tags:[`generic`,`sound`],fileSvg:`svg/soundLimit.svg`},soundLoud:{glyph:``,size:24,tags:[`generic`,`sound`],fileSvg:`svg/soundLoud.svg`},soundMonoL:{glyph:``,size:24,tags:[`generic`,`sound`],fileSvg:`svg/soundMonoL.svg`},soundMonoR:{glyph:``,size:24,tags:[`generic`,`sound`],fileSvg:`svg/soundMonoR.svg`},soundOff:{glyph:``,size:24,tags:[`generic`,`sound`],fileSvg:`svg/soundOff.svg`},soundQuiet:{glyph:``,size:24,tags:[`generic`,`sound`],fileSvg:`svg/soundQuiet.svg`},soundStereo:{glyph:``,size:24,tags:[`generic`,`sound`],fileSvg:`svg/soundStereo.svg`},soundWave01:{glyph:``,size:24,tags:[`generic`,`sound`],fileSvg:`svg/soundWave01.svg`},soundWave02:{glyph:``,size:24,tags:[`generic`,`sound`],fileSvg:`svg/soundWave02.svg`},sphereOnPathNumber:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`,`road tools`],fileSvg:`svg/sphereOnPathNumber.svg`},sphereOnPath:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`,`road tools`],fileSvg:`svg/sphereOnPath.svg`},sphericalBeam:{glyph:``,size:24,tags:[`generic`,`world editor`,`we`,`sensor`],fileSvg:`svg/sphericalBeam.svg`},spoilerLift:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/spoilerLift.svg`},sprayCan:{glyph:``,size:24,tags:[`decals`,`generic`],fileSvg:`svg/sprayCan.svg`},stack3:{glyph:``,size:24,tags:[`delivery`,`stencil`,`cargo`],fileSvg:`svg/stack3.svg`},star:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/star.svg`},starSecondary:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/starSecondary.svg`},steeringWheelCommon:{glyph:``,size:24,tags:[`steering`,`controller`,`input`],fileSvg:`svg/steeringWheelCommon.svg`},steeringWheelSporty:{glyph:``,size:24,tags:[`steering`,`controller`,`input`],fileSvg:`svg/steeringWheelSporty.svg`},stopwatchArrows01:{glyph:``,size:24,tags:[`generic`,`time`,`fast`],fileSvg:`svg/stopwatchArrows01.svg`},stopwatchArrows02:{glyph:``,size:24,tags:[`generic`,`time`,`fast`],fileSvg:`svg/stopwatchArrows02.svg`},stopwatchSectionOutlinedEnd:{glyph:``,size:24,tags:[`generic`,`time`,`fast`],fileSvg:`svg/stopwatchSectionOutlinedEnd.svg`},stopwatchSectionOutlinedStart:{glyph:``,size:24,tags:[`generic`,`time`,`fast`],fileSvg:`svg/stopwatchSectionOutlinedStart.svg`},stopwatchSectionSolidEnd:{glyph:``,size:24,tags:[`generic`,`time`,`fast`],fileSvg:`svg/stopwatchSectionSolidEnd.svg`},stopwatchSectionSolidStart:{glyph:``,size:24,tags:[`generic`,`time`,`fast`],fileSvg:`svg/stopwatchSectionSolidStart.svg`},strobeLights:{glyph:``,size:24,tags:[`vehicle`,`features`,`police`,`emergency`],fileSvg:`svg/strobeLights.svg`},sunRise:{glyph:``,size:24,tags:[`environment`],fileSvg:`svg/sunRise.svg`},survellianceCamera:{glyph:``,size:24,tags:[`generic`,`camera`,`optical`,`sensor`],fileSvg:`svg/survellianceCamera.svg`},suspension01:{glyph:``,size:24,tags:[`vehicle`,`features`,`part`],fileSvg:`svg/suspension01.svg`},suspension02:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/suspension02.svg`},switchBlock:{glyph:``,size:24,tags:[`generic`,`circuit`,`electronics`,`switch`],fileSvg:`svg/switchBlock.svg`},switchOutline:{glyph:``,size:24,tags:[`generic`,`circuit`,`electronics`,`switch`],fileSvg:`svg/switchOutline.svg`},sync:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/sync.svg`},synchro01:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/synchro01.svg`},synchro02:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/synchro02.svg`},tankerTrailer:{glyph:``,size:24,tags:[`cargo`,`delivery`,`tank`,`tanker`,`trailer`,`vehicle`],fileSvg:`svg/tankerTrailer.svg`},targetJump:{glyph:``,size:24,tags:[`poi`],fileSvg:`svg/targetJump.svg`},taxiCar1:{glyph:``,size:24,tags:[`taxi`,`generic`,`vehicle`],fileSvg:`svg/taxiCar1.svg`},taxiCar3:{glyph:``,size:24,tags:[`taxi`,`generic`,`vehicle`],fileSvg:`svg/taxiCar3.svg`},taxiCarT:{glyph:``,size:24,tags:[`taxi`,`generic`,`vehicle`],fileSvg:`svg/taxiCarT.svg`},taxiCheckerLamp:{glyph:``,size:24,tags:[`taxi`,`generic`,`vehicle`],fileSvg:`svg/taxiCheckerLamp.svg`},terrainToLine:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`,`road tools`],fileSvg:`svg/terrainToLine.svg`},terrain:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/terrain.svg`},thinBulbBeam:{glyph:``,size:24,tags:[`generic`,`world editor`,`we`,`sensor`],fileSvg:`svg/thinBulbBeam.svg`},thinnerBulbBeam:{glyph:``,size:24,tags:[`generic`,`world editor`,`we`,`sensor`],fileSvg:`svg/thinnerBulbBeam.svg`},thisSideUp:{glyph:``,size:24,tags:[`delivery`,`stencil`,`cargo`],fileSvg:`svg/thisSideUp.svg`},tiles:{glyph:``,size:24,tags:[`generic`,`catalog`,`selector`,`view`],fileSvg:`svg/tiles.svg`},timer:{glyph:``,size:24,tags:[`generic`,`time`,`fast`],fileSvg:`svg/timer.svg`},tireDirection3Fourth2:{glyph:``,size:24,tags:[`tire`],fileSvg:`svg/tireDirection3Fourth2.svg`},tireDirection3Fourth3:{glyph:``,size:24,tags:[`tire`],fileSvg:`svg/tireDirection3Fourth3.svg`},tireDirectionFront2:{glyph:``,size:24,tags:[`tire`],fileSvg:`svg/tireDirectionFront2.svg`},tireDirectionSide2:{glyph:``,size:24,tags:[`tire`],fileSvg:`svg/tireDirectionSide2.svg`},tireDirectionTop2:{glyph:``,size:24,tags:[`tire`],fileSvg:`svg/tireDirectionTop2.svg`},tirePressureDecrease01:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/tirePressureDecrease01.svg`},tirePressureDecrease02:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/tirePressureDecrease02.svg`},tirePressureGaugeAlt01:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/tirePressureGaugeAlt01.svg`},tirePressureGaugeAlt02:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/tirePressureGaugeAlt02.svg`},tirePressureGaugeAlt03:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/tirePressureGaugeAlt03.svg`},tirePressureGaugeOutlined01:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/tirePressureGaugeOutlined01.svg`},tirePressureGaugeOutlined02:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/tirePressureGaugeOutlined02.svg`},tirePressureGaugeOutlined03:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/tirePressureGaugeOutlined03.svg`},tirePressureGaugeSolid01:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/tirePressureGaugeSolid01.svg`},tirePressureGaugeSolid02:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/tirePressureGaugeSolid02.svg`},tirePressureGaugeSolid03:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/tirePressureGaugeSolid03.svg`},tirePressureIncrease01:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/tirePressureIncrease01.svg`},tirePressureIncrease02:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/tirePressureIncrease02.svg`},tirePressureStopLine:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/tirePressureStopLine.svg`},tirePressureStopOctoLine:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/tirePressureStopOctoLine.svg`},tirePressureStopOctoSolid:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/tirePressureStopOctoSolid.svg`},tirePressureStopSolid:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/tirePressureStopSolid.svg`},toCOMWithWheels:{glyph:``,size:24,tags:[`generic`,`world editor`,`we`,`placement`,`sensor`],fileSvg:`svg/toCOMWithWheels.svg`},toCOM:{glyph:``,size:24,tags:[`generic`,`world editor`,`we`,`placement`,`sensor`],fileSvg:`svg/toCOM.svg`},toGarage:{glyph:``,size:24,tags:[`poi`],fileSvg:`svg/toGarage.svg`},touch:{glyph:``,size:24,tags:[`touch`,`input`],fileSvg:`svg/touch.svg`},tow:{glyph:``,size:24,tags:[`generic`,`vehicle`],fileSvg:`svg/tow.svg`},tractionControl:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/tractionControl.svg`},trafficCone:{glyph:``,size:24,tags:[`route`,`traffic`],fileSvg:`svg/trafficCone.svg`},transform:{glyph:``,size:24,tags:[`decals`,`generic`],fileSvg:`svg/transform.svg`},transmissionA:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/transmissionA.svg`},transmissionM:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/transmissionM.svg`},transparencyMask:{glyph:``,size:24,tags:[`decals`,`generic`],fileSvg:`svg/transparencyMask.svg`},trashBin1:{glyph:``,size:24,tags:[`poi`],fileSvg:`svg/trashBin1.svg`},trashBin2:{glyph:``,size:24,tags:[`decals`,`generic`],fileSvg:`svg/trashBin2.svg`},triangleBeam:{glyph:``,size:24,tags:[`generic`,`world editor`,`we`,`sensor`],fileSvg:`svg/triangleBeam.svg`},trim:{glyph:``,size:24,tags:[`generic`,`sound`],fileSvg:`svg/trim.svg`},tulipBeam:{glyph:``,size:24,tags:[`generic`,`world editor`,`we`,`sensor`],fileSvg:`svg/tulipBeam.svg`},tunnel:{glyph:``,size:24,tags:[`generic`,`world editor`,`we`,`road tools`],fileSvg:`svg/tunnel.svg`},turbine:{glyph:``,size:24,tags:[`vehicle`,`part`,`features`],fileSvg:`svg/turbine.svg`},twoRoadsAdd:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`,`road tools`],fileSvg:`svg/twoRoadsAdd.svg`},twoRoadsCrossAdd:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`,`road tools`],fileSvg:`svg/twoRoadsCrossAdd.svg`},twoRoadsLink:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`,`road tools`],fileSvg:`svg/twoRoadsLink.svg`},twoUnicyclesOnly:{glyph:``,size:24,tags:[`delivery`,`stencil`,`cargo`],fileSvg:`svg/twoUnicyclesOnly.svg`},undo:{glyph:``,size:24,tags:[`decals`,`generic`],fileSvg:`svg/undo.svg`},ungroup:{glyph:``,size:24,tags:[`decals`,`generic`],fileSvg:`svg/ungroup.svg`},unlink:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/unlink.svg`},vehicleDoorsClose:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/vehicleDoorsClose.svg`},vehicleDoorsOpen:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/vehicleDoorsOpen.svg`},vehicleDoors:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/vehicleDoors.svg`},vehicleFeatures01:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/vehicleFeatures01.svg`},vehicleFeatures02:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/vehicleFeatures02.svg`},vehicleFeatures03:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/vehicleFeatures03.svg`},vehicleHood:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/vehicleHood.svg`},vehicleTrunk:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/vehicleTrunk.svg`},view:{glyph:``,size:24,tags:[`decals`,`generic`],fileSvg:`svg/view.svg`},voucherDiagonal1:{glyph:``,size:24,tags:[`generic`,`currency`,`reward`,`career`],fileSvg:`svg/voucherDiagonal1.svg`},voucherDiagonal2:{glyph:``,size:24,tags:[`generic`,`currency`,`reward`,`career`],fileSvg:`svg/voucherDiagonal2.svg`},voucherDiagonal3:{glyph:``,size:24,tags:[`generic`,`currency`,`reward`,`career`],fileSvg:`svg/voucherDiagonal3.svg`},voucherHorizontal1:{glyph:``,size:24,tags:[`generic`,`currency`,`reward`,`career`],fileSvg:`svg/voucherHorizontal1.svg`},voucherHorizontal2:{glyph:``,size:24,tags:[`generic`,`currency`,`reward`,`career`],fileSvg:`svg/voucherHorizontal2.svg`},voucherHorizontal3:{glyph:``,size:24,tags:[`generic`,`currency`,`reward`,`career`],fileSvg:`svg/voucherHorizontal3.svg`},wavesSignalReceived:{glyph:``,size:24,tags:[`generic`,`data`,`signal`,`sensor`],fileSvg:`svg/wavesSignalReceived.svg`},wavesSignalSentLeft:{glyph:``,size:24,tags:[`generic`,`data`,`signal`,`sensor`],fileSvg:`svg/wavesSignalSentLeft.svg`},wavesSignalSentRight:{glyph:``,size:24,tags:[`generic`,`data`,`signal`,`sensor`],fileSvg:`svg/wavesSignalSentRight.svg`},weather:{glyph:``,size:24,tags:[`environment`],fileSvg:`svg/weather.svg`},weight:{glyph:``,size:24,tags:[`decals`,`generic`],fileSvg:`svg/weight.svg`},wheelHubLocked01:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/wheelHubLocked01.svg`},wheelHubUnlocked01:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/wheelHubUnlocked01.svg`},wigwags:{glyph:``,size:24,tags:[`vehicle`,`features`,`police`,`emergency`],fileSvg:`svg/wigwags.svg`},wrench:{glyph:``,size:24,tags:[`generic`,`vehicle`,`features`],fileSvg:`svg/wrench.svg`},xboxA:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/xboxA.svg`},xboxB:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/xboxB.svg`},xboxDDefaultOutline:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/xboxDDefaultOutline.svg`},xboxDDefaultSolid:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/xboxDDefaultSolid.svg`},xboxDDown:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/xboxDDown.svg`},xboxDLeft:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/xboxDLeft.svg`},xboxDRight:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/xboxDRight.svg`},xboxDUp:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/xboxDUp.svg`},xboxLB:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/xboxLB.svg`},xboxLSButton:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/xboxLSButton.svg`},xboxLT:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/xboxLT.svg`},xboxMenu:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/xboxMenu.svg`},xboxRB:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/xboxRB.svg`},xboxRSButton:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/xboxRSButton.svg`},xboxRT:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/xboxRT.svg`},xboxThumbL:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/xboxThumbL.svg`},xboxThumbR:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/xboxThumbR.svg`},xboxView:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/xboxView.svg`},xboxXAxis:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/xboxXAxis.svg`},xboxXRot:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/xboxXRot.svg`},xboxX:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/xboxX.svg`},xboxYAxis:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/xboxYAxis.svg`},xboxYRot:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/xboxYRot.svg`},xboxY:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/xboxY.svg`},AIL:{glyph:``,size:48,tags:[`extra`],fileSvg:`svg/AIL.svg`},arrowLeftOutline:{glyph:``,size:48,tags:[`web`,`outlined`,`large`,`secondary`],fileSvg:`svg/arrowLeftOutline.svg`},arrowRightOutline:{glyph:``,size:48,tags:[`web`,`outlined`,`large`,`secondary`],fileSvg:`svg/arrowRightOutline.svg`},automaticTransmissionL:{glyph:``,size:48,tags:[`extra`],fileSvg:`svg/automaticTransmissionL.svg`},beamsNodesMessageOutline:{glyph:``,size:48,tags:[`web`,`outlined`,`large`,`secondary`],fileSvg:`svg/beamsNodesMessageOutline.svg`},beamsNodesOutline:{glyph:``,size:48,tags:[`web`,`outlined`,`large`,`secondary`],fileSvg:`svg/beamsNodesOutline.svg`},beamsNodesPlugOutline:{glyph:``,size:48,tags:[`web`,`outlined`,`large`,`secondary`],fileSvg:`svg/beamsNodesPlugOutline.svg`},BNGEcosystemOutline:{glyph:``,size:48,tags:[`web`,`outlined`,`large`,`secondary`],fileSvg:`svg/BNGEcosystemOutline.svg`},carFrontRouteOutline:{glyph:``,size:48,tags:[`web`,`outlined`,`large`,`secondary`],fileSvg:`svg/carFrontRouteOutline.svg`},carSensorsOutline:{glyph:``,size:48,tags:[`web`,`outlined`,`large`,`secondary`],fileSvg:`svg/carSensorsOutline.svg`},carSideRouteOutline:{glyph:``,size:48,tags:[`web`,`outlined`,`large`,`secondary`],fileSvg:`svg/carSideRouteOutline.svg`},chargeLL:{glyph:``,size:48,tags:[`extra`],fileSvg:`svg/chargeLL.svg`},cityOutline:{glyph:``,size:48,tags:[`web`,`outlined`,`large`,`secondary`],fileSvg:`svg/cityOutline.svg`},clutchL:{glyph:``,size:48,tags:[`extra`],fileSvg:`svg/clutchL.svg`},couplerL:{glyph:``,size:48,tags:[`extra`],fileSvg:`svg/couplerL.svg`},dialogOutline:{glyph:``,size:48,tags:[`web`,`outlined`,`large`,`secondary`],fileSvg:`svg/dialogOutline.svg`},documentSmileOutline:{glyph:``,size:48,tags:[`web`,`outlined`,`large`,`secondary`],fileSvg:`svg/documentSmileOutline.svg`},drivetrainOutline:{glyph:``,size:48,tags:[`web`,`outlined`,`large`,`secondary`],fileSvg:`svg/drivetrainOutline.svg`},electronicSchemeOutline:{glyph:``,size:48,tags:[`web`,`outlined`,`large`,`secondary`],fileSvg:`svg/electronicSchemeOutline.svg`},engineL:{glyph:``,size:48,tags:[`extra`],fileSvg:`svg/engineL.svg`},engineOutline:{glyph:``,size:48,tags:[`web`,`outlined`,`large`,`secondary`],fileSvg:`svg/engineOutline.svg`},gearTuningOutline:{glyph:``,size:48,tags:[`web`,`outlined`,`large`,`secondary`],fileSvg:`svg/gearTuningOutline.svg`},giftBoxOutline:{glyph:``,size:48,tags:[`web`,`outlined`,`large`,`secondary`],fileSvg:`svg/giftBoxOutline.svg`},lidarOutline:{glyph:``,size:48,tags:[`web`,`outlined`,`large`,`secondary`],fileSvg:`svg/lidarOutline.svg`},medalStarOutline:{glyph:``,size:48,tags:[`web`,`outlined`,`large`,`secondary`],fileSvg:`svg/medalStarOutline.svg`},megaphoneOutline:{glyph:``,size:48,tags:[`web`,`outlined`,`large`,`secondary`],fileSvg:`svg/megaphoneOutline.svg`},multiseatL:{glyph:``,size:48,tags:[`extra`],fileSvg:`svg/multiseatL.svg`},peopleOutline:{glyph:``,size:48,tags:[`web`,`outlined`,`large`,`secondary`],fileSvg:`svg/peopleOutline.svg`},personOutline:{glyph:``,size:48,tags:[`web`,`outlined`,`large`,`secondary`],fileSvg:`svg/personOutline.svg`},physicsOutline:{glyph:``,size:48,tags:[`web`,`outlined`,`large`,`secondary`],fileSvg:`svg/physicsOutline.svg`},playChainOutline:{glyph:``,size:48,tags:[`web`,`outlined`,`large`,`secondary`],fileSvg:`svg/playChainOutline.svg`},POITimeL:{glyph:``,size:48,tags:[`extra`],fileSvg:`svg/POITimeL.svg`},proximitySensorsOutline:{glyph:``,size:48,tags:[`web`,`outlined`,`large`,`secondary`],fileSvg:`svg/proximitySensorsOutline.svg`},qualityBadgeStarOutline:{glyph:``,size:48,tags:[`web`,`outlined`,`large`,`secondary`],fileSvg:`svg/qualityBadgeStarOutline.svg`},qualityBadgeVOutline:{glyph:``,size:48,tags:[`web`,`outlined`,`large`,`secondary`],fileSvg:`svg/qualityBadgeVOutline.svg`},replayL:{glyph:``,size:48,tags:[`extra`],fileSvg:`svg/replayL.svg`},roadblockL:{glyph:``,size:48,tags:[`extra`],fileSvg:`svg/roadblockL.svg`},rotationL:{glyph:``,size:48,tags:[`extra`],fileSvg:`svg/rotationL.svg`},sensorsL:{glyph:``,size:48,tags:[`extra`],fileSvg:`svg/sensorsL.svg`},simRigOutline:{glyph:``,size:48,tags:[`web`,`outlined`,`large`,`secondary`],fileSvg:`svg/simRigOutline.svg`},suspensionOutline:{glyph:``,size:48,tags:[`web`,`outlined`,`large`,`secondary`],fileSvg:`svg/suspensionOutline.svg`},teamOutline:{glyph:``,size:48,tags:[`web`,`outlined`,`large`,`secondary`],fileSvg:`svg/teamOutline.svg`},techLightBulbOutline01:{glyph:``,size:48,tags:[`web`,`outlined`,`large`,`secondary`],fileSvg:`svg/techLightBulbOutline01.svg`},techLightBulbOutline02:{glyph:``,size:48,tags:[`web`,`outlined`,`large`,`secondary`],fileSvg:`svg/techLightBulbOutline02.svg`},temperatureL:{glyph:``,size:48,tags:[`extra`],fileSvg:`svg/temperatureL.svg`},timeUnlockOutline:{glyph:``,size:48,tags:[`web`,`outlined`,`large`,`secondary`],fileSvg:`svg/timeUnlockOutline.svg`},timedLockOutline:{glyph:``,size:48,tags:[`web`,`outlined`,`large`,`secondary`],fileSvg:`svg/timedLockOutline.svg`},trafficOutline:{glyph:``,size:48,tags:[`web`,`outlined`,`large`,`secondary`],fileSvg:`svg/trafficOutline.svg`},tuningL:{glyph:``,size:48,tags:[`extra`],fileSvg:`svg/tuningL.svg`},turbineL:{glyph:``,size:48,tags:[`extra`],fileSvg:`svg/turbineL.svg`},voucherOutline:{glyph:``,size:48,tags:[`web`,`outlined`,`large`,`secondary`],fileSvg:`svg/voucherOutline.svg`},wheelBeamsNodesOutline:{glyph:``,size:48,tags:[`web`,`outlined`,`large`,`secondary`],fileSvg:`svg/wheelBeamsNodesOutline.svg`},wheelOutline:{glyph:``,size:48,tags:[`web`,`outlined`,`large`,`secondary`],fileSvg:`svg/wheelOutline.svg`},circlePinBack:{glyph:``,size:56,tags:[`poi`],fileSvg:`svg/circlePinBack.svg`},circlePinFront:{glyph:``,size:56,tags:[`poi`],fileSvg:`svg/circlePinFront.svg`},markerRectanglePinBack:{glyph:``,size:56,tags:[`poi`],fileSvg:`svg/markerRectanglePinBack.svg`},markerRectanglePinFront:{glyph:``,size:56,tags:[`poi`],fileSvg:`svg/markerRectanglePinFront.svg`},markerTriangleBack:{glyph:``,size:56,tags:[`poi`],fileSvg:`svg/markerTriangleBack.svg`},markerTriangleFront:{glyph:``,size:56,tags:[`poi`],fileSvg:`svg/markerTriangleFront.svg`},danger:{glyph:``,size:24,tags:[`generic`,`hazard`],fileSvg:`svg/danger.svg`},droplet:{glyph:``,size:24,tags:[`generic`,`drop`,`liquid`],fileSvg:`svg/droplet.svg`},envelope:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/envelope.svg`},fireDiamond:{glyph:``,size:24,tags:[`generic`,`hazard`,`nfpa704`],fileSvg:`svg/fireDiamond.svg`},rocks:{glyph:``,size:24,tags:[`dry cargo`,`dry`],fileSvg:`svg/rocks.svg`},xmark:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/xmark.svg`},scale:{glyph:``,size:24,tags:[`decals`,`editor`,`generic`],fileSvg:`svg/scale.svg`},arrowsUp:{glyph:``,size:16,tags:[`marker`,`ribbon`,`content-props`],fileSvg:`svg/arrowsUp.svg`},bigDot:{glyph:``,size:16,tags:[`marker`,`ribbon`,`content-props`],fileSvg:`svg/bigDot.svg`},connectorBold:{glyph:``,size:16,tags:[`marker`,`ribbon`,`content-props`],fileSvg:`svg/connectorBold.svg`},cornerTopRight:{glyph:``,size:16,tags:[`marker`,`ribbon`,`content-props`],fileSvg:`svg/cornerTopRight.svg`},plusBold:{glyph:``,size:16,tags:[`marker`,`ribbon`,`content-props`],fileSvg:`svg/plusBold.svg`},puzzlePieceBold:{glyph:``,size:16,tags:[`marker`,`ribbon`,`content-props`],fileSvg:`svg/puzzlePieceBold.svg`},locationDestination:{glyph:``,size:24,tags:[`generic`,`location`,`route`,`path`,`node`],fileSvg:`svg/locationDestination.svg`},locationSource:{glyph:``,size:24,tags:[`generic`,`location`,`route`,`path`,`node`],fileSvg:`svg/locationSource.svg`},accelerationKPH:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/accelerationKPH.svg`},accelerationMPH:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/accelerationMPH.svg`},boxTruckFast:{glyph:``,size:24,tags:[`cargo`,`delivery`,`vehicle`],fileSvg:`svg/boxTruckFast.svg`},colorBrightnessSun:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/colorBrightnessSun.svg`},colorCirclePalette:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/colorCirclePalette.svg`},colorPalette:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/colorPalette.svg`},colorSaturation:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/colorSaturation.svg`},sortAscDown02:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/sortAscDown02.svg`},sortAscDown:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/sortAscDown.svg`},sortAscUp02:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/sortAscUp02.svg`},sortAscUp:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/sortAscUp.svg`},sortDescDown02:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/sortDescDown02.svg`},sortDescDown:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/sortDescDown.svg`},sortDescUp02:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/sortDescUp02.svg`},sortDescUp:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/sortDescUp.svg`},cardboardBoxCoins:{glyph:``,size:24,tags:[`generic`,`delivery`],fileSvg:`svg/cardboardBoxCoins.svg`},lasso:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`],fileSvg:`svg/lasso.svg`},materialGlossy:{glyph:``,size:24,tags:[`decals`,`generic`],fileSvg:`svg/materialGlossy.svg`},materialMetal:{glyph:``,size:24,tags:[`decals`,`generic`],fileSvg:`svg/materialMetal.svg`},materialRoughness:{glyph:``,size:24,tags:[`decals`,`generic`],fileSvg:`svg/materialRoughness.svg`},materialTransparency01:{glyph:``,size:24,tags:[`decals`,`generic`],fileSvg:`svg/materialTransparency01.svg`},materialTransparency02:{glyph:``,size:24,tags:[`decals`,`generic`],fileSvg:`svg/materialTransparency02.svg`},metal01:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/metal01.svg`},removeItemPolygon:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`,`road tools`],fileSvg:`svg/removeItemPolygon.svg`},removeListItem:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`,`road tools`],fileSvg:`svg/removeListItem.svg`},sortAsc:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/sortAsc.svg`},sortDesc:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/sortDesc.svg`},surfaceRoughness02:{glyph:``,size:24,tags:[`decals`,`generic`],fileSvg:`svg/surfaceRoughness02.svg`},shieldCheckmark:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/shieldCheckmark.svg`},shieldHandCheckmark:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/shieldHandCheckmark.svg`},shieldHandPlus:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/shieldHandPlus.svg`},doorFrontCoins:{glyph:``,size:24,tags:[`vehicle`,`part`,`features`],fileSvg:`svg/doorFrontCoins.svg`},doorFront:{glyph:``,size:24,tags:[`vehicle`,`part`,`features`],fileSvg:`svg/doorFront.svg`},engineCoins:{glyph:``,size:24,tags:[`vehicle`,`part`,`features`],fileSvg:`svg/engineCoins.svg`},exhaustMufflerCoins:{glyph:``,size:24,tags:[`vehicle`,`part`,`features`],fileSvg:`svg/exhaustMufflerCoins.svg`},exhaustMuffler:{glyph:``,size:24,tags:[`vehicle`,`part`,`features`],fileSvg:`svg/exhaustMuffler.svg`},headlightCoins:{glyph:``,size:24,tags:[`vehicle`,`part`,`features`],fileSvg:`svg/headlightCoins.svg`},headlight:{glyph:``,size:24,tags:[`vehicle`,`part`,`features`],fileSvg:`svg/headlight.svg`},tire3FourthCoins:{glyph:``,size:24,tags:[`vehicle`,`part`,`features`,`tire`],fileSvg:`svg/tire3FourthCoins.svg`},tire3Fourth:{glyph:``,size:24,tags:[`vehicle`,`part`,`features`,`tire`],fileSvg:`svg/tire3Fourth.svg`},turbineCoins:{glyph:``,size:24,tags:[`vehicle`,`part`,`features`],fileSvg:`svg/turbineCoins.svg`},wheelDiscCoins:{glyph:``,size:24,tags:[`vehicle`,`part`,`features`],fileSvg:`svg/wheelDiscCoins.svg`},wheelDisc:{glyph:``,size:24,tags:[`vehicle`,`part`,`features`],fileSvg:`svg/wheelDisc.svg`},bridgeWithRiver:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`,`road tools`],fileSvg:`svg/bridgeWithRiver.svg`},gizmosOutline:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`,`road tools`],fileSvg:`svg/gizmosOutline.svg`},gizmosSolid:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`,`road tools`],fileSvg:`svg/gizmosSolid.svg`},highwayRoad3To2Merge01:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`,`road tools`],fileSvg:`svg/highwayRoad3To2Merge01.svg`},highwayRoad3To2Merge02:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`,`road tools`],fileSvg:`svg/highwayRoad3To2Merge02.svg`},highwayToUrbanRoadTransition01:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`,`road tools`],fileSvg:`svg/highwayToUrbanRoadTransition01.svg`},highwayToUrbanRoadTransition02:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`,`road tools`],fileSvg:`svg/highwayToUrbanRoadTransition02.svg`},pedestrianCrossing01:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`,`road tools`],fileSvg:`svg/pedestrianCrossing01.svg`},polygonalCube:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`,`road tools`],fileSvg:`svg/polygonalCube.svg`},roadEditOutline:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`,`road tools`],fileSvg:`svg/roadEditOutline.svg`},roadEditSolid:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`,`road tools`],fileSvg:`svg/roadEditSolid.svg`},roadFolderPlus:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`,`road tools`],fileSvg:`svg/roadFolderPlus.svg`},roadFolder:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`,`road tools`],fileSvg:`svg/roadFolder.svg`},roadGuideArrowOutline:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`,`road tools`],fileSvg:`svg/roadGuideArrowOutline.svg`},roadGuideArrowSolid:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`,`road tools`],fileSvg:`svg/roadGuideArrowSolid.svg`},roadOutlineMesh:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`,`road tools`],fileSvg:`svg/roadOutlineMesh.svg`},roadPedestrianCrossing02:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`,`road tools`],fileSvg:`svg/roadPedestrianCrossing02.svg`},roadProfileWithCheckmark:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`,`road tools`],fileSvg:`svg/roadProfileWithCheckmark.svg`},roadProfile:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`,`road tools`],fileSvg:`svg/roadProfile.svg`},roadRoundaboutJunction:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`,`road tools`],fileSvg:`svg/roadRoundaboutJunction.svg`},roadSidewalkTransition:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`,`road tools`],fileSvg:`svg/roadSidewalkTransition.svg`},roadStackPlus:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`,`road tools`],fileSvg:`svg/roadStackPlus.svg`},roadStack:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`,`road tools`],fileSvg:`svg/roadStack.svg`},roadTJunction:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`,`road tools`],fileSvg:`svg/roadTJunction.svg`},roadXJunction:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`,`road tools`],fileSvg:`svg/roadXJunction.svg`},roadYJunction:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`,`road tools`],fileSvg:`svg/roadYJunction.svg`},shoppingCart:{glyph:``,size:24,tags:[`generic`,`shop`,`purchase`],fileSvg:`svg/shoppingCart.svg`},singleLineToTerrain:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`,`road tools`],fileSvg:`svg/singleLineToTerrain.svg`},sphereOnMesh:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`,`road tools`],fileSvg:`svg/sphereOnMesh.svg`},twoLinesToTerrain:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`,`road tools`],fileSvg:`svg/twoLinesToTerrain.svg`},urbanRoad3To2Merge01:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`,`road tools`],fileSvg:`svg/urbanRoad3To2Merge01.svg`},urbanRoad3To2Merge02:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`,`road tools`],fileSvg:`svg/urbanRoad3To2Merge02.svg`},urbanRoadToHighwayTransition01:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`,`road tools`],fileSvg:`svg/urbanRoadToHighwayTransition01.svg`},urbanRoadToHighwayTransition02:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`,`road tools`],fileSvg:`svg/urbanRoadToHighwayTransition02.svg`},floppyDiskPlus:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/floppyDiskPlus.svg`},highwayMerge:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`,`road tools`],fileSvg:`svg/highwayMerge.svg`},highwaySeparate:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`,`road tools`],fileSvg:`svg/highwaySeparate.svg`},highwayShoulderMerge:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`,`road tools`],fileSvg:`svg/highwayShoulderMerge.svg`},terrainToSingleLine:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`,`road tools`],fileSvg:`svg/terrainToSingleLine.svg`},terrainToTwoLines:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`,`road tools`],fileSvg:`svg/terrainToTwoLines.svg`},urbanRoadMerge:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`,`road tools`],fileSvg:`svg/urbanRoadMerge.svg`},urbanRoadSeparate:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`,`road tools`],fileSvg:`svg/urbanRoadSeparate.svg`},urbanShoulderMerge:{glyph:``,size:24,tags:[`generic`,`we`,`world editor`,`road tools`],fileSvg:`svg/urbanShoulderMerge.svg`},discharging:{glyph:``,size:24,tags:[`fuel`,`electricity`,`ev`],fileSvg:`svg/discharging.svg`},BNGChat:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/BNGChat.svg`},chatBubble:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/chatBubble.svg`},busTilted:{glyph:``,size:24,tags:[`poi`,`vehicle`,`bus`],fileSvg:`svg/busTilted.svg`},cameraFarClip:{glyph:``,size:24,tags:[`decals`,`generic`],fileSvg:`svg/cameraFarClip.svg`},cameraNearClip:{glyph:``,size:24,tags:[`decals`,`generic`],fileSvg:`svg/cameraNearClip.svg`},explosion:{glyph:``,size:24,tags:[`generic`,`destruction`],fileSvg:`svg/explosion.svg`},fireExtinguisher:{glyph:``,size:24,tags:[`generic`,`destruction`],fileSvg:`svg/fireExtinguisher.svg`},fire:{glyph:``,size:24,tags:[`generic`,`destruction`],fileSvg:`svg/fire.svg`},jointLockedMultiple:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/jointLockedMultiple.svg`},jointUnlockedMultiple:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/jointUnlockedMultiple.svg`},toggleOff:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/toggleOff.svg`},toggleOn:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/toggleOn.svg`},viewFarClip:{glyph:``,size:24,tags:[`decals`,`generic`],fileSvg:`svg/viewFarClip.svg`},viewNearClip:{glyph:``,size:24,tags:[`decals`,`generic`],fileSvg:`svg/viewNearClip.svg`},twoArrowsHorizontal:{glyph:``,size:24,tags:[`arrow`,`large`,`solid`,`turn signals`],fileSvg:`svg/twoArrowsHorizontal.svg`},twoArrowsVertical:{glyph:``,size:24,tags:[`arrow`,`large`,`solid`,`turn signals`],fileSvg:`svg/twoArrowsVertical.svg`},bridge:{glyph:``,size:48,tags:[`rally`,`pace notes`,`directions`,`surface`,`features`],fileSvg:`svg/bridge.svg`},bump:{glyph:``,size:48,tags:[`rally`,`pace notes`,`directions`,`surface`,`features`],fileSvg:`svg/bump.svg`},bumps:{glyph:``,size:48,tags:[`rally`,`pace notes`,`directions`,`surface`,`features`],fileSvg:`svg/bumps.svg`},caution:{glyph:``,size:48,tags:[`rally`,`pace notes`,`directions`,`surface`,`features`],fileSvg:`svg/caution.svg`},crest:{glyph:``,size:48,tags:[`rally`,`pace notes`,`directions`,`surface`,`features`],fileSvg:`svg/crest.svg`},doubleCaution:{glyph:``,size:48,tags:[`rally`,`pace notes`,`directions`,`surface`,`features`],fileSvg:`svg/doubleCaution.svg`},finish:{glyph:``,size:48,tags:[`rally`,`pace notes`,`directions`,`surface`,`features`],fileSvg:`svg/finish.svg`},jumpOverBump:{glyph:``,size:48,tags:[`rally`,`pace notes`,`directions`,`surface`,`features`],fileSvg:`svg/jumpOverBump.svg`},narrows:{glyph:``,size:48,tags:[`rally`,`pace notes`,`directions`,`surface`,`features`],fileSvg:`svg/narrows.svg`},pothole:{glyph:``,size:48,tags:[`rally`,`pace notes`,`directions`,`surface`,`features`],fileSvg:`svg/pothole.svg`},turn1:{glyph:``,size:48,tags:[`rally`,`pace notes`,`directions`,`surface`,`features`],fileSvg:`svg/turn1.svg`},turn2:{glyph:``,size:48,tags:[`rally`,`pace notes`,`directions`,`surface`,`features`],fileSvg:`svg/turn2.svg`},turn3:{glyph:``,size:48,tags:[`rally`,`pace notes`,`directions`,`surface`,`features`],fileSvg:`svg/turn3.svg`},turn4:{glyph:``,size:48,tags:[`rally`,`pace notes`,`directions`,`surface`,`features`],fileSvg:`svg/turn4.svg`},turn5:{glyph:``,size:48,tags:[`rally`,`pace notes`,`directions`,`surface`,`features`],fileSvg:`svg/turn5.svg`},turn6:{glyph:``,size:48,tags:[`rally`,`pace notes`,`directions`,`surface`,`features`],fileSvg:`svg/turn6.svg`},turnHp:{glyph:``,size:48,tags:[`rally`,`pace notes`,`directions`,`surface`,`features`],fileSvg:`svg/turnHp.svg`},turnSq:{glyph:``,size:48,tags:[`rally`,`pace notes`,`directions`,`surface`,`features`],fileSvg:`svg/turnSq.svg`},water:{glyph:``,size:48,tags:[`rally`,`pace notes`,`directions`,`surface`,`features`],fileSvg:`svg/water.svg`},circleSlashed:{glyph:``,size:24,tags:[`generic`,`do not cut`,`no entry`],fileSvg:`svg/circleSlashed.svg`},scissorsSlashed:{glyph:``,size:24,tags:[`generic`,`do not cut`],fileSvg:`svg/scissorsSlashed.svg`},scissors:{glyph:``,size:24,tags:[`generic`,`cut`],fileSvg:`svg/scissors.svg`},airPuffRight1:{glyph:``,size:24,tags:[`generic`,`vehicle`,`car`],fileSvg:`svg/airPuffRight1.svg`},airPuffUp1:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/airPuffUp1.svg`},arrowsReplace:{glyph:``,size:24,tags:[`generic`,`arrow`],fileSvg:`svg/arrowsReplace.svg`},arrowsShuffle:{glyph:``,size:24,tags:[`generic`,`arrow`],fileSvg:`svg/arrowsShuffle.svg`},arrowsSwitch:{glyph:``,size:24,tags:[`generic`,`arrow`],fileSvg:`svg/arrowsSwitch.svg`},carClock:{glyph:``,size:24,tags:[`generic`,`vehicle`],fileSvg:`svg/carClock.svg`},carFast:{glyph:``,size:24,tags:[`vehicle`],fileSvg:`svg/carFast.svg`},carNumber1:{glyph:``,size:24,tags:[`generic`,`vehicle`],fileSvg:`svg/carNumber1.svg`},carNumber2:{glyph:``,size:24,tags:[`generic`,`vehicle`],fileSvg:`svg/carNumber2.svg`},carNumber3:{glyph:``,size:24,tags:[`generic`,`vehicle`],fileSvg:`svg/carNumber3.svg`},carNumber4:{glyph:``,size:24,tags:[`generic`,`vehicle`],fileSvg:`svg/carNumber4.svg`},carNumber5:{glyph:``,size:24,tags:[`generic`,`vehicle`],fileSvg:`svg/carNumber5.svg`},carNumber6:{glyph:``,size:24,tags:[`generic`,`vehicle`],fileSvg:`svg/carNumber6.svg`},carNumber7:{glyph:``,size:24,tags:[`generic`,`vehicle`],fileSvg:`svg/carNumber7.svg`},carNumber8:{glyph:``,size:24,tags:[`generic`,`vehicle`],fileSvg:`svg/carNumber8.svg`},carNumber9:{glyph:``,size:24,tags:[`generic`,`vehicle`],fileSvg:`svg/carNumber9.svg`},carPlus:{glyph:``,size:24,tags:[`generic`,`vehicle`],fileSvg:`svg/carPlus.svg`},carsChange:{glyph:``,size:24,tags:[`vehicle`,`select`],fileSvg:`svg/carsChange.svg`},carsFollow:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/carsFollow.svg`},doorFrontDetached:{glyph:``,size:24,tags:[`vehicle`,`part`,`features`],fileSvg:`svg/doorFrontDetached.svg`},forceFieldPull1:{glyph:``,size:24,tags:[`physics`,`field`,`force`],fileSvg:`svg/forceFieldPull1.svg`},forceFieldPull2:{glyph:``,size:24,tags:[`physics`,`field`,`force`],fileSvg:`svg/forceFieldPull2.svg`},forceFieldPull3:{glyph:``,size:24,tags:[`physics`,`field`,`force`],fileSvg:`svg/forceFieldPull3.svg`},forceFieldPush1:{glyph:``,size:24,tags:[`physics`,`field`,`force`],fileSvg:`svg/forceFieldPush1.svg`},forceFieldPush2:{glyph:``,size:24,tags:[`physics`,`field`,`force`],fileSvg:`svg/forceFieldPush2.svg`},forceFieldPush3:{glyph:``,size:24,tags:[`physics`,`field`,`force`],fileSvg:`svg/forceFieldPush3.svg`},garageNumber1:{glyph:``,size:24,tags:[`career`,`garage number`,`features`],fileSvg:`svg/garageNumber1.svg`},garageNumber2:{glyph:``,size:24,tags:[`career`,`garage number`,`features`],fileSvg:`svg/garageNumber2.svg`},garageNumber3:{glyph:``,size:24,tags:[`career`,`garage number`,`features`],fileSvg:`svg/garageNumber3.svg`},garageNumber4:{glyph:``,size:24,tags:[`career`,`garage number`,`features`],fileSvg:`svg/garageNumber4.svg`},garageNumber5:{glyph:``,size:24,tags:[`career`,`garage number`,`features`],fileSvg:`svg/garageNumber5.svg`},garageNumber6:{glyph:``,size:24,tags:[`career`,`garage number`,`features`],fileSvg:`svg/garageNumber6.svg`},garageNumber7:{glyph:``,size:24,tags:[`career`,`garage number`,`features`],fileSvg:`svg/garageNumber7.svg`},garageNumber8:{glyph:``,size:24,tags:[`career`,`garage number`,`features`],fileSvg:`svg/garageNumber8.svg`},garageNumber9:{glyph:``,size:24,tags:[`career`,`garage number`,`features`],fileSvg:`svg/garageNumber9.svg`},hingeBroken:{glyph:``,size:24,tags:[`vehicle`,`part`,`features`],fileSvg:`svg/hingeBroken.svg`},loadMesh:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/loadMesh.svg`},octagonBrick:{glyph:``,size:24,tags:[`generic`,`vehicle`,`car`],fileSvg:`svg/octagonBrick.svg`},octagon:{glyph:``,size:24,tags:[`generic`,`vehicle`,`car`],fileSvg:`svg/octagon.svg`},pushUp:{glyph:``,size:24,tags:[`physics`,`force`],fileSvg:`svg/pushUp.svg`},saveMesh:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/saveMesh.svg`},square:{glyph:``,size:24,tags:[`playback`,`stop`],fileSvg:`svg/square.svg`},tireAirPuff:{glyph:``,size:24,tags:[`vehicle`,`car`],fileSvg:`svg/tireAirPuff.svg`},tireDeflated:{glyph:``,size:24,tags:[`vehicle`,`car`],fileSvg:`svg/tireDeflated.svg`},trafficLight:{glyph:``,size:24,tags:[`generic`,`traffic`,`roads`],fileSvg:`svg/trafficLight.svg`},enter:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/enter.svg`},pedestrianRunning:{glyph:``,size:24,tags:[`generic`,`sign`,`pedestrian`,`traffic`],fileSvg:`svg/pedestrianRunning.svg`},pedestrianStanding:{glyph:``,size:24,tags:[`generic`,`sign`,`pedestrian`,`traffic`],fileSvg:`svg/pedestrianStanding.svg`},seatArrowIn:{glyph:``,size:24,tags:[`generic`,`arrow`,`actions`],fileSvg:`svg/seatArrowIn.svg`},seatArrowOut:{glyph:``,size:24,tags:[`generic`,`arrow`,`actions`],fileSvg:`svg/seatArrowOut.svg`},seatVArrowIn:{glyph:``,size:24,tags:[`generic`,`arrow`,`actions`],fileSvg:`svg/seatVArrowIn.svg`},seatVArrowOut:{glyph:``,size:24,tags:[`generic`,`arrow`,`actions`],fileSvg:`svg/seatVArrowOut.svg`},vehicleArrowIn:{glyph:``,size:24,tags:[`generic`,`arrow`,`actions`],fileSvg:`svg/vehicleArrowIn.svg`},vehicleArrowOut:{glyph:``,size:24,tags:[`generic`,`arrow`,`actions`],fileSvg:`svg/vehicleArrowOut.svg`},leverFrontOperate:{glyph:``,size:24,tags:[`generic`,`actions`],fileSvg:`svg/leverFrontOperate.svg`},leverSideDown:{glyph:``,size:24,tags:[`generic`,`actions`],fileSvg:`svg/leverSideDown.svg`},leverSideOperate:{glyph:``,size:24,tags:[`generic`,`actions`],fileSvg:`svg/leverSideOperate.svg`},leverSideUp:{glyph:``,size:24,tags:[`generic`,`actions`],fileSvg:`svg/leverSideUp.svg`},medalEmpty:{glyph:``,size:24,tags:[`generic`,`reward`,`achievment`],fileSvg:`svg/medalEmpty.svg`},medalStar:{glyph:``,size:24,tags:[`generic`,`reward`,`achievment`],fileSvg:`svg/medalStar.svg`},seatArrowInLeft:{glyph:``,size:24,tags:[`generic`,`arrow`,`actions`],fileSvg:`svg/seatArrowInLeft.svg`},seatArrowOutLeft:{glyph:``,size:24,tags:[`generic`,`arrow`,`actions`],fileSvg:`svg/seatArrowOutLeft.svg`},seatVArrowInLeft:{glyph:``,size:24,tags:[`generic`,`arrow`,`actions`],fileSvg:`svg/seatVArrowInLeft.svg`},seatVArrowOutLeft:{glyph:``,size:24,tags:[`generic`,`arrow`,`actions`],fileSvg:`svg/seatVArrowOutLeft.svg`},badgeRoundEmpty:{glyph:``,size:24,tags:[`generic`,`reward`,`achievment`],fileSvg:`svg/badgeRoundEmpty.svg`},badgeRoundStar:{glyph:``,size:24,tags:[`generic`,`reward`,`achievment`],fileSvg:`svg/badgeRoundStar.svg`},badgeRound:{glyph:``,size:24,tags:[`generic`,`reward`,`achievment`],fileSvg:`svg/badgeRound.svg`},badge:{glyph:``,size:24,tags:[`generic`,`reward`,`achievment`],fileSvg:`svg/badge.svg`},beamCurrencyOutlineLarge:{glyph:``,size:48,tags:[`outline`,`generic`,`currency`],fileSvg:`svg/beamCurrencyOutlineLarge.svg`},carSideOutlineLarge:{glyph:``,size:48,tags:[`generic`,`vehicle`],fileSvg:`svg/carSideOutlineLarge.svg`},flagOutlineLarge:{glyph:``,size:48,tags:[`generic`,`mission`,`scenario`],fileSvg:`svg/flagOutlineLarge.svg`},terrainOutlineLarge:{glyph:``,size:48,tags:[`generic`],fileSvg:`svg/terrainOutlineLarge.svg`},houseWrenchRoof:{glyph:``,size:24,tags:[`career`,`garage`,`features`,`house`],fileSvg:`svg/houseWrenchRoof.svg`},houseWrench:{glyph:``,size:24,tags:[`career`,`garage`,`features`,`house`],fileSvg:`svg/houseWrench.svg`},eject:{glyph:``,size:24,tags:[`playback`],fileSvg:`svg/eject.svg`},rallyHelmet3To4:{glyph:``,size:24,tags:[`helmet`,`rally`,`generic`,`racing`,`game mode`],fileSvg:`svg/rallyHelmet3To4.svg`},rallyHelmet:{glyph:``,size:24,tags:[`helmet`,`rally`,`generic`,`racing`,`game mode`],fileSvg:`svg/rallyHelmet.svg`},test:{glyph:``,size:24,tags:[`generic`,`hazard`],fileSvg:`svg/test.svg`},tripleCaution:{glyph:``,size:48,tags:[`rally`,`pace notes`,`directions`,`surface`,`features`],fileSvg:`svg/tripleCaution.svg`},globeSimpleNotSign:{glyph:``,size:24,tags:[`generic`,`offline`],fileSvg:`svg/globeSimpleNotSign.svg`},globeSimplified:{glyph:``,size:24,tags:[`generic`,`online`],fileSvg:`svg/globeSimplified.svg`},radialMenu:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/radialMenu.svg`},branch:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/branch.svg`},NA:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/NA.svg`},psCircleOutline:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/psCircleOutline.svg`},psCircle:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/psCircle.svg`},psCreate2:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/psCreate2.svg`},psCreate:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/psCreate.svg`},psCrossOutline:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/psCrossOutline.svg`},psCross:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/psCross.svg`},psDDefaultOutline:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/psDDefaultOutline.svg`},psDDefaultSolid:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/psDDefaultSolid.svg`},psDDown:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/psDDown.svg`},psDLeft:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/psDLeft.svg`},psDRight:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/psDRight.svg`},psDUp:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/psDUp.svg`},psL1:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/psL1.svg`},psL2:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/psL2.svg`},psL3ButtonArrowDown:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/psL3ButtonArrowDown.svg`},psL3Button:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/psL3Button.svg`},psLSXLeft:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/psLSXLeft.svg`},psLSXRight:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/psLSXRight.svg`},psLSX:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/psLSX.svg`},psLSYDown:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/psLSYDown.svg`},psLSYUp:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/psLSYUp.svg`},psLSY:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/psLSY.svg`},psLS:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/psLS.svg`},psMenu2:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/psMenu2.svg`},psMenu:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/psMenu.svg`},psR1:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/psR1.svg`},psR2:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/psR2.svg`},psR3ButtonArrowDown:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/psR3ButtonArrowDown.svg`},psR3Button:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/psR3Button.svg`},psRSXLeft:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/psRSXLeft.svg`},psRSXRight:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/psRSXRight.svg`},psRSX:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/psRSX.svg`},psRSYDown:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/psRSYDown.svg`},psRSYUp:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/psRSYUp.svg`},psRSY:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/psRSY.svg`},psRS:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/psRS.svg`},psSquareOutline:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/psSquareOutline.svg`},psSquare:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/psSquare.svg`},psTrackpadNavigate:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/psTrackpadNavigate.svg`},psTrackpadPressCenter:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/psTrackpadPressCenter.svg`},psTrackpadPressLeft:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/psTrackpadPressLeft.svg`},psTrackpadPressRight:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/psTrackpadPressRight.svg`},psTrackpadSwipeDown:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/psTrackpadSwipeDown.svg`},psTrackpadSwipeLeft:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/psTrackpadSwipeLeft.svg`},psTrackpadSwipeRight:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/psTrackpadSwipeRight.svg`},psTrackpadSwipeUp:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/psTrackpadSwipeUp.svg`},psTriangleOutline:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/psTriangleOutline.svg`},psTriangle:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/psTriangle.svg`},xboxAOutline:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/xboxAOutline.svg`},xboxBOutline:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/xboxBOutline.svg`},xboxLSButtonArrowDown:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/xboxLSButtonArrowDown.svg`},xboxRSButtonArrowDown:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/xboxRSButtonArrowDown.svg`},xboxXAxisLeft:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/xboxXAxisLeft.svg`},xboxXAxisRight:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/xboxXAxisRight.svg`},xboxXOutline:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/xboxXOutline.svg`},xboxXRotLeft:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/xboxXRotLeft.svg`},xboxXRotRight:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/xboxXRotRight.svg`},xboxYAxisDown:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/xboxYAxisDown.svg`},xboxYAxisUp:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/xboxYAxisUp.svg`},xboxYOutline:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/xboxYOutline.svg`},xboxYRotDown:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/xboxYRotDown.svg`},xboxYRotUp:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/xboxYRotUp.svg`},cableSection:{glyph:``,size:24,tags:[`material`,`beam`,`strap`],fileSvg:`svg/cableSection.svg`},strapHook:{glyph:``,size:24,tags:[`material`,`strap`],fileSvg:`svg/strapHook.svg`},strapRatchet:{glyph:``,size:24,tags:[`material`,`strap`],fileSvg:`svg/strapRatchet.svg`},carFastReverse:{glyph:``,size:24,tags:[`vehicle`],fileSvg:`svg/carFastReverse.svg`},carsChase:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/carsChase.svg`},carsFlee:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/carsFlee.svg`},gaugeFull:{glyph:``,size:24,tags:[`poi`],fileSvg:`svg/gaugeFull.svg`},hammerParticles:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/hammerParticles.svg`},kbArrowsDown:{glyph:``,size:24,tags:[`keyboard`,`controls`],fileSvg:`svg/kbArrowsDown.svg`},kbArrowsLeftRight:{glyph:``,size:24,tags:[`keyboard`,`controls`],fileSvg:`svg/kbArrowsLeftRight.svg`},kbArrowsLeft:{glyph:``,size:24,tags:[`keyboard`,`controls`],fileSvg:`svg/kbArrowsLeft.svg`},kbArrowsOutline:{glyph:``,size:24,tags:[`keyboard`,`controls`],fileSvg:`svg/kbArrowsOutline.svg`},kbArrowsRight:{glyph:``,size:24,tags:[`keyboard`,`controls`],fileSvg:`svg/kbArrowsRight.svg`},kbArrowsSolid:{glyph:``,size:24,tags:[`keyboard`,`controls`],fileSvg:`svg/kbArrowsSolid.svg`},kbArrowsUpDown:{glyph:``,size:24,tags:[`keyboard`,`controls`],fileSvg:`svg/kbArrowsUpDown.svg`},kbArrowsUp:{glyph:``,size:24,tags:[`keyboard`,`controls`],fileSvg:`svg/kbArrowsUp.svg`},magicWand:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/magicWand.svg`},psDLeftRight:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/psDLeftRight.svg`},psDUpDown:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/psDUpDown.svg`},pushBackward:{glyph:``,size:24,tags:[`physics`,`force`],fileSvg:`svg/pushBackward.svg`},pushDown:{glyph:``,size:24,tags:[`physics`,`force`],fileSvg:`svg/pushDown.svg`},pushForward:{glyph:``,size:24,tags:[`physics`,`force`],fileSvg:`svg/pushForward.svg`},rangeboxHi:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/rangeboxHi.svg`},rangeboxLo:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/rangeboxLo.svg`},routeSimpleFlag:{glyph:``,size:24,tags:[`route`,`traffic`],fileSvg:`svg/routeSimpleFlag.svg`},xboxDLeftRight:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/xboxDLeftRight.svg`},xboxDUpDown:{glyph:``,size:24,tags:[`gamepad`,`controller`,`input`],fileSvg:`svg/xboxDUpDown.svg`},carsWrench:{glyph:``,size:24,tags:[`vehicle`,`select`],fileSvg:`svg/carsWrench.svg`},jointCycleMultiple:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/jointCycleMultiple.svg`},jointCycle:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/jointCycle.svg`},dice24:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/dice24.svg`},diceD6:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/diceD6.svg`},pathDice:{glyph:``,size:24,tags:[`camera`],fileSvg:`svg/pathDice.svg`},sunDown:{glyph:``,size:24,tags:[`environment`],fileSvg:`svg/sunDown.svg`},xmarkBold:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/xmarkBold.svg`},intakeTrumpets:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/intakeTrumpets.svg`},transmissionCvt:{glyph:``,size:24,tags:[`vehicle`,`features`],fileSvg:`svg/transmissionCvt.svg`},house:{glyph:``,size:24,tags:[`career`,`generic`,`garage`,`features`,`house`],fileSvg:`svg/house.svg`},playPause:{glyph:``,size:24,tags:[`playback`],fileSvg:`svg/playPause.svg`},picture:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/picture.svg`},auxUpDown:{glyph:``,size:24,tags:[`vehicle`,`features`,`equipment`],fileSvg:`svg/auxUpDown.svg`},bucketArmUpDown:{glyph:``,size:24,tags:[`vehicle`,`features`,`equipment`],fileSvg:`svg/bucketArmUpDown.svg`},bucketTilt:{glyph:``,size:24,tags:[`vehicle`,`features`,`equipment`],fileSvg:`svg/bucketTilt.svg`},bucketArmDown:{glyph:``,size:24,tags:[`vehicle`,`features`,`equipment`],fileSvg:`svg/bucketArmDown.svg`},bucketArmLevel:{glyph:``,size:24,tags:[`vehicle`,`features`,`equipment`],fileSvg:`svg/bucketArmLevel.svg`},bucketArmUp:{glyph:``,size:24,tags:[`vehicle`,`features`,`equipment`],fileSvg:`svg/bucketArmUp.svg`},bucketTiltDown:{glyph:``,size:24,tags:[`vehicle`,`features`,`equipment`],fileSvg:`svg/bucketTiltDown.svg`},bucketTiltLevel:{glyph:``,size:24,tags:[`vehicle`,`features`,`equipment`],fileSvg:`svg/bucketTiltLevel.svg`},bucketTiltUp:{glyph:``,size:24,tags:[`vehicle`,`features`,`equipment`],fileSvg:`svg/bucketTiltUp.svg`},dumpBedDown:{glyph:``,size:24,tags:[`vehicle`,`features`,`equipment`],fileSvg:`svg/dumpBedDown.svg`},dumpBedUpDown:{glyph:``,size:24,tags:[`vehicle`,`features`,`equipment`],fileSvg:`svg/dumpBedUpDown.svg`},dumpBedUp:{glyph:``,size:24,tags:[`vehicle`,`features`,`equipment`],fileSvg:`svg/dumpBedUp.svg`},beamCurrencyThin:{glyph:``,size:24,tags:[`career`,`currencies`],fileSvg:`svg/beamCurrencyThin.svg`},shieldCheckmarkProgressbar:{glyph:``,size:24,tags:[`generic`],fileSvg:`svg/shieldCheckmarkProgressbar.svg`}}),iconsBySize=Object.freeze({16:{arrowsUp:icons$2.arrowsUp,bigDot:icons$2.bigDot,connectorBold:icons$2.connectorBold,cornerTopRight:icons$2.cornerTopRight,plusBold:icons$2.plusBold,puzzlePieceBold:icons$2.puzzlePieceBold},24:{"4WD":icons$2[`4WD`],"9dividedby10":icons$2[`9dividedby10`],abandon:icons$2.abandon,ABSIndicator:icons$2.ABSIndicator,addItemPolygon:icons$2.addItemPolygon,addListItem:icons$2.addListItem,addPolygonVertex:icons$2.addPolygonVertex,adjust:icons$2.adjust,AIMicrochip:icons$2.AIMicrochip,AIRace:icons$2.AIRace,aperture:icons$2.aperture,arrowLargeDown:icons$2.arrowLargeDown,arrowLargeLeft:icons$2.arrowLargeLeft,arrowLargeRight:icons$2.arrowLargeRight,arrowLargeUp:icons$2.arrowLargeUp,arrowSmallDown:icons$2.arrowSmallDown,arrowSmallLeft:icons$2.arrowSmallLeft,arrowSmallRight:icons$2.arrowSmallRight,arrowSmallUp:icons$2.arrowSmallUp,arrowSolidLeft:icons$2.arrowSolidLeft,arrowSolidRight:icons$2.arrowSolidRight,autobahn:icons$2.autobahn,AWD:icons$2.AWD,axleLift:icons$2.axleLift,axleCenter:icons$2.axleCenter,axleFront:icons$2.axleFront,axleRear:icons$2.axleRear,bSpline:icons$2.bSpline,banknotes:icons$2.banknotes,barrelKnocker01:icons$2.barrelKnocker01,barrelKnocker02:icons$2.barrelKnocker02,beamCrashBarrier1:icons$2.beamCrashBarrier1,beamCrashBarrier2:icons$2.beamCrashBarrier2,beamCrashBarrier3:icons$2.beamCrashBarrier3,beamCurrency:icons$2.beamCurrency,beamNG:icons$2.beamNG,beamXPFull:icons$2.beamXPFull,beamXPLo:icons$2.beamXPLo,bezierPath1:icons$2.bezierPath1,bezierPath2:icons$2.bezierPath2,bicycle1:icons$2.bicycle1,bicycle2:icons$2.bicycle2,BNGFolder:icons$2.BNGFolder,BNGMicrochip:icons$2.BNGMicrochip,bollard:icons$2.bollard,bookmark:icons$2.bookmark,booleanIntersect:icons$2.booleanIntersect,boxDropOff01:icons$2.boxDropOff01,boxDropOff02:icons$2.boxDropOff02,boxDropOff03:icons$2.boxDropOff03,boxPickUp01:icons$2.boxPickUp01,boxPickUp02:icons$2.boxPickUp02,boxPickUp03:icons$2.boxPickUp03,boxPickUpDropOff01:icons$2.boxPickUpDropOff01,boxPickUpDropOff02:icons$2.boxPickUpDropOff02,boxTruck:icons$2.boxTruck,broom:icons$2.broom,bucketAdd:icons$2.bucketAdd,bucketSubtract:icons$2.bucketSubtract,bug:icons$2.bug,bulldozer:icons$2.bulldozer,bus:icons$2.bus,camera3Fourth1:icons$2.camera3Fourth1,cameraBack1:icons$2.cameraBack1,cameraFocusOnPath:icons$2.cameraFocusOnPath,cameraFocusOnVehicle1:icons$2.cameraFocusOnVehicle1,cameraFocusOnVehicle2:icons$2.cameraFocusOnVehicle2,cameraFocusTopDown:icons$2.cameraFocusTopDown,cameraFront1:icons$2.cameraFront1,cameraSideLeft:icons$2.cameraSideLeft,cameraSideLeft2:icons$2.cameraSideLeft2,cameraSideRight:icons$2.cameraSideRight,cameraSideRight2:icons$2.cameraSideRight2,cameraTop1:icons$2.cameraTop1,cannon:icons$2.cannon,carChase01:icons$2.carChase01,carCoin:icons$2.carCoin,carCoins:icons$2.carCoins,carCrash:icons$2.carCrash,carDealer:icons$2.carDealer,carOffroadOutlineRear:icons$2.carOffroadOutlineRear,carOffroadOutlineSide:icons$2.carOffroadOutlineSide,carOffroadRear:icons$2.carOffroadRear,carOffroadSide:icons$2.carOffroadSide,carSensors:icons$2.carSensors,carStarred:icons$2.carStarred,carToWheels:icons$2.carToWheels,carUp:icons$2.carUp,carWithLidar:icons$2.carWithLidar,car:icons$2.car,cardboardBox:icons$2.cardboardBox,carsChase02:icons$2.carsChase02,cars:icons$2.cars,catalog01:icons$2.catalog01,catalog02:icons$2.catalog02,catalog03:icons$2.catalog03,centrifugalClutchLocked03:icons$2.centrifugalClutchLocked03,centrifugalClutchUnlocked03:icons$2.centrifugalClutchUnlocked03,charge:icons$2.charge,charging:icons$2.charging,chartBars:icons$2.chartBars,checkboxOff:icons$2.checkboxOff,checkboxOn:icons$2.checkboxOn,checkmarkBold:icons$2.checkmarkBold,checkmark:icons$2.checkmark,circuitMicrochip:icons$2.circuitMicrochip,circuit:icons$2.circuit,clapperboard:icons$2.clapperboard,code:icons$2.code,cogDamaged:icons$2.cogDamaged,cogsDamaged:icons$2.cogsDamaged,cogs:icons$2.cogs,concreteRoadBlock:icons$2.concreteRoadBlock,coolantTemp:icons$2.coolantTemp,copy:icons$2.copy,crossroads1:icons$2.crossroads1,crossroads2:icons$2.crossroads2,cruiseDisable:icons$2.cruiseDisable,cruiseEnable:icons$2.cruiseEnable,cup:icons$2.cup,dataExchange:icons$2.dataExchange,day:icons$2.day,DCBattery:icons$2.DCBattery,decalRoad:icons$2.decalRoad,decal:icons$2.decal,deform:icons$2.deform,deliveryTruckArrows:icons$2.deliveryTruckArrows,deliveryTruck:icons$2.deliveryTruck,differentialFrontDefault:icons$2.differentialFrontDefault,differentialFrontLocked:icons$2.differentialFrontLocked,differentialMiddleDefault:icons$2.differentialMiddleDefault,differentialMiddleLocked:icons$2.differentialMiddleLocked,differentialRearDefault:icons$2.differentialRearDefault,differentialRearLocked:icons$2.differentialRearLocked,doorHandle:icons$2.doorHandle,doorIn:icons$2.doorIn,drag01:icons$2.drag01,drag02:icons$2.drag02,drift01:icons$2.drift01,drift02:icons$2.drift02,drivetrainGeneric:icons$2.drivetrainGeneric,drivetrainSpecial:icons$2.drivetrainSpecial,editCheckmark:icons$2.editCheckmark,edit:icons$2.edit,engine:icons$2.engine,ESCOff:icons$2.ESCOff,ESCOn:icons$2.ESCOn,ESC:icons$2.ESC,evade:icons$2.evade,exhaustValve:icons$2.exhaustValve,exit:icons$2.exit,export:icons$2.export,eyeOutlineClosed:icons$2.eyeOutlineClosed,eyeOutlineOpened:icons$2.eyeOutlineOpened,eyeSolidClosed:icons$2.eyeSolidClosed,eyeSolidOpened:icons$2.eyeSolidOpened,eyeWaves:icons$2.eyeWaves,facility02:icons$2.facility02,fastBackward:icons$2.fastBackward,fastForward:icons$2.fastForward,fastTravel:icons$2.fastTravel,filter:icons$2.filter,flagNew:icons$2.flagNew,flag:icons$2.flag,flatBulbBeam:icons$2.flatBulbBeam,flatbedTruck:icons$2.flatbedTruck,floppyDisk:icons$2.floppyDisk,fogLight:icons$2.fogLight,folder:icons$2.folder,forklift:icons$2.forklift,FPS:icons$2.FPS,fragile:icons$2.fragile,frontAxleMidpoint:icons$2.frontAxleMidpoint,frontBumperMidpoint:icons$2.frontBumperMidpoint,fuelPumpFilling:icons$2.fuelPumpFilling,fuelPump:icons$2.fuelPump,FWD:icons$2.FWD,gamepadOld:icons$2.gamepadOld,gamepad:icons$2.gamepad,garage01:icons$2.garage01,garage02:icons$2.garage02,garage03:icons$2.garage03,gaugeEmpty:icons$2.gaugeEmpty,globe:icons$2.globe,GPSMark:icons$2.GPSMark,GPSSolid:icons$2.GPSSolid,group:icons$2.group,gyroscopeMicrochip:icons$2.gyroscopeMicrochip,gyroscope:icons$2.gyroscope,hazardLights:icons$2.hazardLights,helmets:icons$2.helmets,help:icons$2.help,highBeam:icons$2.highBeam,HUD:icons$2.HUD,hydroPump1:icons$2.hydroPump1,hydroPump2:icons$2.hydroPump2,hydroPump3:icons$2.hydroPump3,hydroPump4:icons$2.hydroPump4,hydroPump5:icons$2.hydroPump5,hydroPump6:icons$2.hydroPump6,hydroPump7:icons$2.hydroPump7,hypermiling:icons$2.hypermiling,import:icons$2.import,infinity:icons$2.infinity,info:icons$2.info,jointLocked:icons$2.jointLocked,jointUnlocked:icons$2.jointUnlocked,jump:icons$2.jump,keyboard:icons$2.keyboard,keys1:icons$2.keys1,keys2:icons$2.keys2,lampPost1:icons$2.lampPost1,lampPost2:icons$2.lampPost2,lampPost3:icons$2.lampPost3,laneProperties:icons$2.laneProperties,language:icons$2.language,laptop:icons$2.laptop,lidarPatternFullArcHighFreq:icons$2.lidarPatternFullArcHighFreq,lidarPatternFullArcMidFreq:icons$2.lidarPatternFullArcMidFreq,lidarPatternNarrowArc:icons$2.lidarPatternNarrowArc,lidar:icons$2.lidar,lightGarageG11:icons$2.lightGarageG11,lightGarageG12:icons$2.lightGarageG12,lightGarageG13:icons$2.lightGarageG13,lightGarageG14:icons$2.lightGarageG14,lightGarageG21:icons$2.lightGarageG21,lightGarageG22:icons$2.lightGarageG22,lightGarageG23:icons$2.lightGarageG23,lightGarageG24:icons$2.lightGarageG24,lightGarageG31:icons$2.lightGarageG31,lightGarageG32:icons$2.lightGarageG32,lightGarageG33:icons$2.lightGarageG33,lightGarageG34:icons$2.lightGarageG34,lightrunner:icons$2.lightrunner,limiterEnable:icons$2.limiterEnable,lineToTerrain:icons$2.lineToTerrain,link2:icons$2.link2,link:icons$2.link,listBig:icons$2.listBig,listIndented:icons$2.listIndented,listSmall:icons$2.listSmall,location1:icons$2.location1,location2:icons$2.location2,lockClosed:icons$2.lockClosed,lockOpened:icons$2.lockOpened,longRangeBeam1:icons$2.longRangeBeam1,longRangeBeam2:icons$2.longRangeBeam2,lowBeam:icons$2.lowBeam,magnetOnSurface:icons$2.magnetOnSurface,mapWithEmitter:icons$2.mapWithEmitter,mapPoint:icons$2.mapPoint,material:icons$2.material,mathDivide:icons$2.mathDivide,mathGreaterOrEqualThan:icons$2.mathGreaterOrEqualThan,mathGreaterThan:icons$2.mathGreaterThan,mathLessOrEqualThan:icons$2.mathLessOrEqualThan,mathLessThan:icons$2.mathLessThan,mathMinus:icons$2.mathMinus,mathMultiply:icons$2.mathMultiply,mathPlus:icons$2.mathPlus,medal:icons$2.medal,mesh4Cells:icons$2.mesh4Cells,mesh9Cells:icons$2.mesh9Cells,meshFence:icons$2.meshFence,meshRoad:icons$2.meshRoad,midRangeBeam1:icons$2.midRangeBeam1,midRangeBeam2:icons$2.midRangeBeam2,minusRes:icons$2.minusRes,minus:icons$2.minus,mirrorInteriorMiddle:icons$2.mirrorInteriorMiddle,mirrorLeftBigBottomWideAngle:icons$2.mirrorLeftBigBottomWideAngle,mirrorLeftBigTop:icons$2.mirrorLeftBigTop,mirrorLeftBig:icons$2.mirrorLeftBig,mirrorLeftBonnet:icons$2.mirrorLeftBonnet,mirrorLeftDefault:icons$2.mirrorLeftDefault,mirrorRightBigBottomWideAngle:icons$2.mirrorRightBigBottomWideAngle,mirrorRightBigTop:icons$2.mirrorRightBigTop,mirrorRightBig:icons$2.mirrorRightBig,mirrorRightBonnet:icons$2.mirrorRightBonnet,mirrorRightDefault:icons$2.mirrorRightDefault,mirrorRoundWideAngle:icons$2.mirrorRoundWideAngle,mirrorTopWideAngle:icons$2.mirrorTopWideAngle,missionCheckboxCross:icons$2.missionCheckboxCross,mouseLMB:icons$2.mouseLMB,mouseMMB:icons$2.mouseMMB,mouseRMB:icons$2.mouseRMB,mouseWheel:icons$2.mouseWheel,mouseXAxis:icons$2.mouseXAxis,mouseXYAxis:icons$2.mouseXYAxis,mouseYAxis:icons$2.mouseYAxis,mouse:icons$2.mouse,move02:icons$2.move02,move:icons$2.move,movieCamera:icons$2.movieCamera,music:icons$2.music,N2OButton:icons$2.N2OButton,N2OHoriz:icons$2.N2OHoriz,N2OVert:icons$2.N2OVert,nextTrack:icons$2.nextTrack,night:icons$2.night,noNameControllerButton:icons$2.noNameControllerButton,nodeAddFirst01:icons$2.nodeAddFirst01,nodeAddFirst02:icons$2.nodeAddFirst02,nodeAddLast02:icons$2.nodeAddLast02,nodeAddMiddle01:icons$2.nodeAddMiddle01,nodeAddMiddle02:icons$2.nodeAddMiddle02,nodeAdd:icons$2.nodeAdd,nodeLast01:icons$2.nodeLast01,nodeRemove:icons$2.nodeRemove,odometerKM:icons$2.odometerKM,odometerMI:icons$2.odometerMI,odometer:icons$2.odometer,oilPressureIndicator:icons$2.oilPressureIndicator,order:icons$2.order,organization:icons$2.organization,palmCrossed:icons$2.palmCrossed,paperKnife:icons$2.paperKnife,parkingIndicator:icons$2.parkingIndicator,parking:icons$2.parking,pathArc:icons$2.pathArc,pathAroundObstacle:icons$2.pathAroundObstacle,pathLine:icons$2.pathLine,pathSpiral:icons$2.pathSpiral,pauseRound:icons$2.pauseRound,pause:icons$2.pause,personSolid:icons$2.personSolid,person:icons$2.person,photo:icons$2.photo,placeholder:icons$2.placeholder,playRound:icons$2.playRound,play:icons$2.play,playlist:icons$2.playlist,plusGarage1:icons$2.plusGarage1,plusGarage2:icons$2.plusGarage2,plusGarage3:icons$2.plusGarage3,plusGarage4:icons$2.plusGarage4,plusSet:icons$2.plusSet,plus:icons$2.plus,positionLights:icons$2.positionLights,powerGauge01:icons$2.powerGauge01,powerGauge02:icons$2.powerGauge02,powerGauge03:icons$2.powerGauge03,powerGauge04:icons$2.powerGauge04,powerGauge05:icons$2.powerGauge05,powerOnOff:icons$2.powerOnOff,prevTrack:icons$2.prevTrack,publisher:icons$2.publisher,puzzleModule:icons$2.puzzleModule,raceFlag:icons$2.raceFlag,radarIdeal:icons$2.radarIdeal,radarRoundIdeal:icons$2.radarRoundIdeal,radarRound:icons$2.radarRound,radar:icons$2.radar,rangeboxHi2:icons$2.rangeboxHi2,rangeboxHi4:icons$2.rangeboxHi4,rangeboxHiA:icons$2.rangeboxHiA,rangeboxLo2:icons$2.rangeboxLo2,rangeboxLo4:icons$2.rangeboxLo4,rangeboxLoA:icons$2.rangeboxLoA,rearAxleMidpoint:icons$2.rearAxleMidpoint,rearBumperMidpoint:icons$2.rearBumperMidpoint,reconfigure:icons$2.reconfigure,redo:icons$2.redo,reflectNot:icons$2.reflectNot,reflect:icons$2.reflect,rename:icons$2.rename,replay:icons$2.replay,restart:icons$2.restart,roadDividerLinesDecal:icons$2.roadDividerLinesDecal,roadEdgeLineDecal:icons$2.roadEdgeLineDecal,roadEndLineDecal:icons$2.roadEndLineDecal,roadFace:icons$2.roadFace,roadInfo:icons$2.roadInfo,roadMarkingOutline:icons$2.roadMarkingOutline,roadMarkingSolid:icons$2.roadMarkingSolid,roadOutline:icons$2.roadOutline,roadRefPathDecal:icons$2.roadRefPathDecal,roadRefPath:icons$2.roadRefPath,roadStartLineDecal:icons$2.roadStartLineDecal,road:icons$2.road,rockCrawling01:icons$2.rockCrawling01,rockCrawling02:icons$2.rockCrawling02,routeAdd:icons$2.routeAdd,routeComplex:icons$2.routeComplex,routeSimple:icons$2.routeSimple,runScript:icons$2.runScript,RWD:icons$2.RWD,saveAs1:icons$2.saveAs1,scan:icons$2.scan,search:icons$2.search,semiTrailer:icons$2.semiTrailer,semiTruckCabover:icons$2.semiTruckCabover,semiTruckUS:icons$2.semiTruckUS,semiTruck:icons$2.semiTruck,shortRangeBeam1:icons$2.shortRangeBeam1,shortRangeBeam2:icons$2.shortRangeBeam2,signal01a:icons$2.signal01a,signal02a:icons$2.signal02a,signal03a:icons$2.signal03a,signal04a:icons$2.signal04a,signal05a:icons$2.signal05a,slashLeft:icons$2.slashLeft,slashRight:icons$2.slashRight,smallTrailer:icons$2.smallTrailer,smartphone1:icons$2.smartphone1,smartphone2:icons$2.smartphone2,snowflake:icons$2.snowflake,soundFadeOut:icons$2.soundFadeOut,soundLimit:icons$2.soundLimit,soundLoud:icons$2.soundLoud,soundMonoL:icons$2.soundMonoL,soundMonoR:icons$2.soundMonoR,soundOff:icons$2.soundOff,soundQuiet:icons$2.soundQuiet,soundStereo:icons$2.soundStereo,soundWave01:icons$2.soundWave01,soundWave02:icons$2.soundWave02,sphereOnPathNumber:icons$2.sphereOnPathNumber,sphereOnPath:icons$2.sphereOnPath,sphericalBeam:icons$2.sphericalBeam,spoilerLift:icons$2.spoilerLift,sprayCan:icons$2.sprayCan,stack3:icons$2.stack3,star:icons$2.star,starSecondary:icons$2.starSecondary,steeringWheelCommon:icons$2.steeringWheelCommon,steeringWheelSporty:icons$2.steeringWheelSporty,stopwatchArrows01:icons$2.stopwatchArrows01,stopwatchArrows02:icons$2.stopwatchArrows02,stopwatchSectionOutlinedEnd:icons$2.stopwatchSectionOutlinedEnd,stopwatchSectionOutlinedStart:icons$2.stopwatchSectionOutlinedStart,stopwatchSectionSolidEnd:icons$2.stopwatchSectionSolidEnd,stopwatchSectionSolidStart:icons$2.stopwatchSectionSolidStart,strobeLights:icons$2.strobeLights,sunRise:icons$2.sunRise,survellianceCamera:icons$2.survellianceCamera,suspension01:icons$2.suspension01,suspension02:icons$2.suspension02,switchBlock:icons$2.switchBlock,switchOutline:icons$2.switchOutline,sync:icons$2.sync,synchro01:icons$2.synchro01,synchro02:icons$2.synchro02,tankerTrailer:icons$2.tankerTrailer,targetJump:icons$2.targetJump,taxiCar1:icons$2.taxiCar1,taxiCar3:icons$2.taxiCar3,taxiCarT:icons$2.taxiCarT,taxiCheckerLamp:icons$2.taxiCheckerLamp,terrainToLine:icons$2.terrainToLine,terrain:icons$2.terrain,thinBulbBeam:icons$2.thinBulbBeam,thinnerBulbBeam:icons$2.thinnerBulbBeam,thisSideUp:icons$2.thisSideUp,tiles:icons$2.tiles,timer:icons$2.timer,tireDirection3Fourth2:icons$2.tireDirection3Fourth2,tireDirection3Fourth3:icons$2.tireDirection3Fourth3,tireDirectionFront2:icons$2.tireDirectionFront2,tireDirectionSide2:icons$2.tireDirectionSide2,tireDirectionTop2:icons$2.tireDirectionTop2,tirePressureDecrease01:icons$2.tirePressureDecrease01,tirePressureDecrease02:icons$2.tirePressureDecrease02,tirePressureGaugeAlt01:icons$2.tirePressureGaugeAlt01,tirePressureGaugeAlt02:icons$2.tirePressureGaugeAlt02,tirePressureGaugeAlt03:icons$2.tirePressureGaugeAlt03,tirePressureGaugeOutlined01:icons$2.tirePressureGaugeOutlined01,tirePressureGaugeOutlined02:icons$2.tirePressureGaugeOutlined02,tirePressureGaugeOutlined03:icons$2.tirePressureGaugeOutlined03,tirePressureGaugeSolid01:icons$2.tirePressureGaugeSolid01,tirePressureGaugeSolid02:icons$2.tirePressureGaugeSolid02,tirePressureGaugeSolid03:icons$2.tirePressureGaugeSolid03,tirePressureIncrease01:icons$2.tirePressureIncrease01,tirePressureIncrease02:icons$2.tirePressureIncrease02,tirePressureStopLine:icons$2.tirePressureStopLine,tirePressureStopOctoLine:icons$2.tirePressureStopOctoLine,tirePressureStopOctoSolid:icons$2.tirePressureStopOctoSolid,tirePressureStopSolid:icons$2.tirePressureStopSolid,toCOMWithWheels:icons$2.toCOMWithWheels,toCOM:icons$2.toCOM,toGarage:icons$2.toGarage,touch:icons$2.touch,tow:icons$2.tow,tractionControl:icons$2.tractionControl,trafficCone:icons$2.trafficCone,transform:icons$2.transform,transmissionA:icons$2.transmissionA,transmissionM:icons$2.transmissionM,transparencyMask:icons$2.transparencyMask,trashBin1:icons$2.trashBin1,trashBin2:icons$2.trashBin2,triangleBeam:icons$2.triangleBeam,trim:icons$2.trim,tulipBeam:icons$2.tulipBeam,tunnel:icons$2.tunnel,turbine:icons$2.turbine,twoRoadsAdd:icons$2.twoRoadsAdd,twoRoadsCrossAdd:icons$2.twoRoadsCrossAdd,twoRoadsLink:icons$2.twoRoadsLink,twoUnicyclesOnly:icons$2.twoUnicyclesOnly,undo:icons$2.undo,ungroup:icons$2.ungroup,unlink:icons$2.unlink,vehicleDoorsClose:icons$2.vehicleDoorsClose,vehicleDoorsOpen:icons$2.vehicleDoorsOpen,vehicleDoors:icons$2.vehicleDoors,vehicleFeatures01:icons$2.vehicleFeatures01,vehicleFeatures02:icons$2.vehicleFeatures02,vehicleFeatures03:icons$2.vehicleFeatures03,vehicleHood:icons$2.vehicleHood,vehicleTrunk:icons$2.vehicleTrunk,view:icons$2.view,voucherDiagonal1:icons$2.voucherDiagonal1,voucherDiagonal2:icons$2.voucherDiagonal2,voucherDiagonal3:icons$2.voucherDiagonal3,voucherHorizontal1:icons$2.voucherHorizontal1,voucherHorizontal2:icons$2.voucherHorizontal2,voucherHorizontal3:icons$2.voucherHorizontal3,wavesSignalReceived:icons$2.wavesSignalReceived,wavesSignalSentLeft:icons$2.wavesSignalSentLeft,wavesSignalSentRight:icons$2.wavesSignalSentRight,weather:icons$2.weather,weight:icons$2.weight,wheelHubLocked01:icons$2.wheelHubLocked01,wheelHubUnlocked01:icons$2.wheelHubUnlocked01,wigwags:icons$2.wigwags,wrench:icons$2.wrench,xboxA:icons$2.xboxA,xboxB:icons$2.xboxB,xboxDDefaultOutline:icons$2.xboxDDefaultOutline,xboxDDefaultSolid:icons$2.xboxDDefaultSolid,xboxDDown:icons$2.xboxDDown,xboxDLeft:icons$2.xboxDLeft,xboxDRight:icons$2.xboxDRight,xboxDUp:icons$2.xboxDUp,xboxLB:icons$2.xboxLB,xboxLSButton:icons$2.xboxLSButton,xboxLT:icons$2.xboxLT,xboxMenu:icons$2.xboxMenu,xboxRB:icons$2.xboxRB,xboxRSButton:icons$2.xboxRSButton,xboxRT:icons$2.xboxRT,xboxThumbL:icons$2.xboxThumbL,xboxThumbR:icons$2.xboxThumbR,xboxView:icons$2.xboxView,xboxXAxis:icons$2.xboxXAxis,xboxXRot:icons$2.xboxXRot,xboxX:icons$2.xboxX,xboxYAxis:icons$2.xboxYAxis,xboxYRot:icons$2.xboxYRot,xboxY:icons$2.xboxY,danger:icons$2.danger,droplet:icons$2.droplet,envelope:icons$2.envelope,fireDiamond:icons$2.fireDiamond,rocks:icons$2.rocks,xmark:icons$2.xmark,scale:icons$2.scale,locationDestination:icons$2.locationDestination,locationSource:icons$2.locationSource,accelerationKPH:icons$2.accelerationKPH,accelerationMPH:icons$2.accelerationMPH,boxTruckFast:icons$2.boxTruckFast,colorBrightnessSun:icons$2.colorBrightnessSun,colorCirclePalette:icons$2.colorCirclePalette,colorPalette:icons$2.colorPalette,colorSaturation:icons$2.colorSaturation,sortAscDown02:icons$2.sortAscDown02,sortAscDown:icons$2.sortAscDown,sortAscUp02:icons$2.sortAscUp02,sortAscUp:icons$2.sortAscUp,sortDescDown02:icons$2.sortDescDown02,sortDescDown:icons$2.sortDescDown,sortDescUp02:icons$2.sortDescUp02,sortDescUp:icons$2.sortDescUp,cardboardBoxCoins:icons$2.cardboardBoxCoins,lasso:icons$2.lasso,materialGlossy:icons$2.materialGlossy,materialMetal:icons$2.materialMetal,materialRoughness:icons$2.materialRoughness,materialTransparency01:icons$2.materialTransparency01,materialTransparency02:icons$2.materialTransparency02,metal01:icons$2.metal01,removeItemPolygon:icons$2.removeItemPolygon,removeListItem:icons$2.removeListItem,sortAsc:icons$2.sortAsc,sortDesc:icons$2.sortDesc,surfaceRoughness02:icons$2.surfaceRoughness02,shieldCheckmark:icons$2.shieldCheckmark,shieldHandCheckmark:icons$2.shieldHandCheckmark,shieldHandPlus:icons$2.shieldHandPlus,doorFrontCoins:icons$2.doorFrontCoins,doorFront:icons$2.doorFront,engineCoins:icons$2.engineCoins,exhaustMufflerCoins:icons$2.exhaustMufflerCoins,exhaustMuffler:icons$2.exhaustMuffler,headlightCoins:icons$2.headlightCoins,headlight:icons$2.headlight,tire3FourthCoins:icons$2.tire3FourthCoins,tire3Fourth:icons$2.tire3Fourth,turbineCoins:icons$2.turbineCoins,wheelDiscCoins:icons$2.wheelDiscCoins,wheelDisc:icons$2.wheelDisc,bridgeWithRiver:icons$2.bridgeWithRiver,gizmosOutline:icons$2.gizmosOutline,gizmosSolid:icons$2.gizmosSolid,highwayRoad3To2Merge01:icons$2.highwayRoad3To2Merge01,highwayRoad3To2Merge02:icons$2.highwayRoad3To2Merge02,highwayToUrbanRoadTransition01:icons$2.highwayToUrbanRoadTransition01,highwayToUrbanRoadTransition02:icons$2.highwayToUrbanRoadTransition02,pedestrianCrossing01:icons$2.pedestrianCrossing01,polygonalCube:icons$2.polygonalCube,roadEditOutline:icons$2.roadEditOutline,roadEditSolid:icons$2.roadEditSolid,roadFolderPlus:icons$2.roadFolderPlus,roadFolder:icons$2.roadFolder,roadGuideArrowOutline:icons$2.roadGuideArrowOutline,roadGuideArrowSolid:icons$2.roadGuideArrowSolid,roadOutlineMesh:icons$2.roadOutlineMesh,roadPedestrianCrossing02:icons$2.roadPedestrianCrossing02,roadProfileWithCheckmark:icons$2.roadProfileWithCheckmark,roadProfile:icons$2.roadProfile,roadRoundaboutJunction:icons$2.roadRoundaboutJunction,roadSidewalkTransition:icons$2.roadSidewalkTransition,roadStackPlus:icons$2.roadStackPlus,roadStack:icons$2.roadStack,roadTJunction:icons$2.roadTJunction,roadXJunction:icons$2.roadXJunction,roadYJunction:icons$2.roadYJunction,shoppingCart:icons$2.shoppingCart,singleLineToTerrain:icons$2.singleLineToTerrain,sphereOnMesh:icons$2.sphereOnMesh,twoLinesToTerrain:icons$2.twoLinesToTerrain,urbanRoad3To2Merge01:icons$2.urbanRoad3To2Merge01,urbanRoad3To2Merge02:icons$2.urbanRoad3To2Merge02,urbanRoadToHighwayTransition01:icons$2.urbanRoadToHighwayTransition01,urbanRoadToHighwayTransition02:icons$2.urbanRoadToHighwayTransition02,floppyDiskPlus:icons$2.floppyDiskPlus,highwayMerge:icons$2.highwayMerge,highwaySeparate:icons$2.highwaySeparate,highwayShoulderMerge:icons$2.highwayShoulderMerge,terrainToSingleLine:icons$2.terrainToSingleLine,terrainToTwoLines:icons$2.terrainToTwoLines,urbanRoadMerge:icons$2.urbanRoadMerge,urbanRoadSeparate:icons$2.urbanRoadSeparate,urbanShoulderMerge:icons$2.urbanShoulderMerge,discharging:icons$2.discharging,BNGChat:icons$2.BNGChat,chatBubble:icons$2.chatBubble,busTilted:icons$2.busTilted,cameraFarClip:icons$2.cameraFarClip,cameraNearClip:icons$2.cameraNearClip,explosion:icons$2.explosion,fireExtinguisher:icons$2.fireExtinguisher,fire:icons$2.fire,jointLockedMultiple:icons$2.jointLockedMultiple,jointUnlockedMultiple:icons$2.jointUnlockedMultiple,toggleOff:icons$2.toggleOff,toggleOn:icons$2.toggleOn,viewFarClip:icons$2.viewFarClip,viewNearClip:icons$2.viewNearClip,twoArrowsHorizontal:icons$2.twoArrowsHorizontal,twoArrowsVertical:icons$2.twoArrowsVertical,circleSlashed:icons$2.circleSlashed,scissorsSlashed:icons$2.scissorsSlashed,scissors:icons$2.scissors,airPuffRight1:icons$2.airPuffRight1,airPuffUp1:icons$2.airPuffUp1,arrowsReplace:icons$2.arrowsReplace,arrowsShuffle:icons$2.arrowsShuffle,arrowsSwitch:icons$2.arrowsSwitch,carClock:icons$2.carClock,carFast:icons$2.carFast,carNumber1:icons$2.carNumber1,carNumber2:icons$2.carNumber2,carNumber3:icons$2.carNumber3,carNumber4:icons$2.carNumber4,carNumber5:icons$2.carNumber5,carNumber6:icons$2.carNumber6,carNumber7:icons$2.carNumber7,carNumber8:icons$2.carNumber8,carNumber9:icons$2.carNumber9,carPlus:icons$2.carPlus,carsChange:icons$2.carsChange,carsFollow:icons$2.carsFollow,doorFrontDetached:icons$2.doorFrontDetached,forceFieldPull1:icons$2.forceFieldPull1,forceFieldPull2:icons$2.forceFieldPull2,forceFieldPull3:icons$2.forceFieldPull3,forceFieldPush1:icons$2.forceFieldPush1,forceFieldPush2:icons$2.forceFieldPush2,forceFieldPush3:icons$2.forceFieldPush3,garageNumber1:icons$2.garageNumber1,garageNumber2:icons$2.garageNumber2,garageNumber3:icons$2.garageNumber3,garageNumber4:icons$2.garageNumber4,garageNumber5:icons$2.garageNumber5,garageNumber6:icons$2.garageNumber6,garageNumber7:icons$2.garageNumber7,garageNumber8:icons$2.garageNumber8,garageNumber9:icons$2.garageNumber9,hingeBroken:icons$2.hingeBroken,loadMesh:icons$2.loadMesh,octagonBrick:icons$2.octagonBrick,octagon:icons$2.octagon,pushUp:icons$2.pushUp,saveMesh:icons$2.saveMesh,square:icons$2.square,tireAirPuff:icons$2.tireAirPuff,tireDeflated:icons$2.tireDeflated,trafficLight:icons$2.trafficLight,enter:icons$2.enter,pedestrianRunning:icons$2.pedestrianRunning,pedestrianStanding:icons$2.pedestrianStanding,seatArrowIn:icons$2.seatArrowIn,seatArrowOut:icons$2.seatArrowOut,seatVArrowIn:icons$2.seatVArrowIn,seatVArrowOut:icons$2.seatVArrowOut,vehicleArrowIn:icons$2.vehicleArrowIn,vehicleArrowOut:icons$2.vehicleArrowOut,leverFrontOperate:icons$2.leverFrontOperate,leverSideDown:icons$2.leverSideDown,leverSideOperate:icons$2.leverSideOperate,leverSideUp:icons$2.leverSideUp,medalEmpty:icons$2.medalEmpty,medalStar:icons$2.medalStar,seatArrowInLeft:icons$2.seatArrowInLeft,seatArrowOutLeft:icons$2.seatArrowOutLeft,seatVArrowInLeft:icons$2.seatVArrowInLeft,seatVArrowOutLeft:icons$2.seatVArrowOutLeft,badgeRoundEmpty:icons$2.badgeRoundEmpty,badgeRoundStar:icons$2.badgeRoundStar,badgeRound:icons$2.badgeRound,badge:icons$2.badge,houseWrenchRoof:icons$2.houseWrenchRoof,houseWrench:icons$2.houseWrench,eject:icons$2.eject,rallyHelmet3To4:icons$2.rallyHelmet3To4,rallyHelmet:icons$2.rallyHelmet,test:icons$2.test,globeSimpleNotSign:icons$2.globeSimpleNotSign,globeSimplified:icons$2.globeSimplified,radialMenu:icons$2.radialMenu,branch:icons$2.branch,NA:icons$2.NA,psCircleOutline:icons$2.psCircleOutline,psCircle:icons$2.psCircle,psCreate2:icons$2.psCreate2,psCreate:icons$2.psCreate,psCrossOutline:icons$2.psCrossOutline,psCross:icons$2.psCross,psDDefaultOutline:icons$2.psDDefaultOutline,psDDefaultSolid:icons$2.psDDefaultSolid,psDDown:icons$2.psDDown,psDLeft:icons$2.psDLeft,psDRight:icons$2.psDRight,psDUp:icons$2.psDUp,psL1:icons$2.psL1,psL2:icons$2.psL2,psL3ButtonArrowDown:icons$2.psL3ButtonArrowDown,psL3Button:icons$2.psL3Button,psLSXLeft:icons$2.psLSXLeft,psLSXRight:icons$2.psLSXRight,psLSX:icons$2.psLSX,psLSYDown:icons$2.psLSYDown,psLSYUp:icons$2.psLSYUp,psLSY:icons$2.psLSY,psLS:icons$2.psLS,psMenu2:icons$2.psMenu2,psMenu:icons$2.psMenu,psR1:icons$2.psR1,psR2:icons$2.psR2,psR3ButtonArrowDown:icons$2.psR3ButtonArrowDown,psR3Button:icons$2.psR3Button,psRSXLeft:icons$2.psRSXLeft,psRSXRight:icons$2.psRSXRight,psRSX:icons$2.psRSX,psRSYDown:icons$2.psRSYDown,psRSYUp:icons$2.psRSYUp,psRSY:icons$2.psRSY,psRS:icons$2.psRS,psSquareOutline:icons$2.psSquareOutline,psSquare:icons$2.psSquare,psTrackpadNavigate:icons$2.psTrackpadNavigate,psTrackpadPressCenter:icons$2.psTrackpadPressCenter,psTrackpadPressLeft:icons$2.psTrackpadPressLeft,psTrackpadPressRight:icons$2.psTrackpadPressRight,psTrackpadSwipeDown:icons$2.psTrackpadSwipeDown,psTrackpadSwipeLeft:icons$2.psTrackpadSwipeLeft,psTrackpadSwipeRight:icons$2.psTrackpadSwipeRight,psTrackpadSwipeUp:icons$2.psTrackpadSwipeUp,psTriangleOutline:icons$2.psTriangleOutline,psTriangle:icons$2.psTriangle,xboxAOutline:icons$2.xboxAOutline,xboxBOutline:icons$2.xboxBOutline,xboxLSButtonArrowDown:icons$2.xboxLSButtonArrowDown,xboxRSButtonArrowDown:icons$2.xboxRSButtonArrowDown,xboxXAxisLeft:icons$2.xboxXAxisLeft,xboxXAxisRight:icons$2.xboxXAxisRight,xboxXOutline:icons$2.xboxXOutline,xboxXRotLeft:icons$2.xboxXRotLeft,xboxXRotRight:icons$2.xboxXRotRight,xboxYAxisDown:icons$2.xboxYAxisDown,xboxYAxisUp:icons$2.xboxYAxisUp,xboxYOutline:icons$2.xboxYOutline,xboxYRotDown:icons$2.xboxYRotDown,xboxYRotUp:icons$2.xboxYRotUp,cableSection:icons$2.cableSection,strapHook:icons$2.strapHook,strapRatchet:icons$2.strapRatchet,carFastReverse:icons$2.carFastReverse,carsChase:icons$2.carsChase,carsFlee:icons$2.carsFlee,gaugeFull:icons$2.gaugeFull,hammerParticles:icons$2.hammerParticles,kbArrowsDown:icons$2.kbArrowsDown,kbArrowsLeftRight:icons$2.kbArrowsLeftRight,kbArrowsLeft:icons$2.kbArrowsLeft,kbArrowsOutline:icons$2.kbArrowsOutline,kbArrowsRight:icons$2.kbArrowsRight,kbArrowsSolid:icons$2.kbArrowsSolid,kbArrowsUpDown:icons$2.kbArrowsUpDown,kbArrowsUp:icons$2.kbArrowsUp,magicWand:icons$2.magicWand,psDLeftRight:icons$2.psDLeftRight,psDUpDown:icons$2.psDUpDown,pushBackward:icons$2.pushBackward,pushDown:icons$2.pushDown,pushForward:icons$2.pushForward,rangeboxHi:icons$2.rangeboxHi,rangeboxLo:icons$2.rangeboxLo,routeSimpleFlag:icons$2.routeSimpleFlag,xboxDLeftRight:icons$2.xboxDLeftRight,xboxDUpDown:icons$2.xboxDUpDown,carsWrench:icons$2.carsWrench,jointCycleMultiple:icons$2.jointCycleMultiple,jointCycle:icons$2.jointCycle,dice24:icons$2.dice24,diceD6:icons$2.diceD6,pathDice:icons$2.pathDice,sunDown:icons$2.sunDown,xmarkBold:icons$2.xmarkBold,intakeTrumpets:icons$2.intakeTrumpets,transmissionCvt:icons$2.transmissionCvt,house:icons$2.house,playPause:icons$2.playPause,picture:icons$2.picture,auxUpDown:icons$2.auxUpDown,bucketArmUpDown:icons$2.bucketArmUpDown,bucketTilt:icons$2.bucketTilt,bucketArmDown:icons$2.bucketArmDown,bucketArmLevel:icons$2.bucketArmLevel,bucketArmUp:icons$2.bucketArmUp,bucketTiltDown:icons$2.bucketTiltDown,bucketTiltLevel:icons$2.bucketTiltLevel,bucketTiltUp:icons$2.bucketTiltUp,dumpBedDown:icons$2.dumpBedDown,dumpBedUpDown:icons$2.dumpBedUpDown,dumpBedUp:icons$2.dumpBedUp,beamCurrencyThin:icons$2.beamCurrencyThin,shieldCheckmarkProgressbar:icons$2.shieldCheckmarkProgressbar},48:{AIL:icons$2.AIL,arrowLeftOutline:icons$2.arrowLeftOutline,arrowRightOutline:icons$2.arrowRightOutline,automaticTransmissionL:icons$2.automaticTransmissionL,beamsNodesMessageOutline:icons$2.beamsNodesMessageOutline,beamsNodesOutline:icons$2.beamsNodesOutline,beamsNodesPlugOutline:icons$2.beamsNodesPlugOutline,BNGEcosystemOutline:icons$2.BNGEcosystemOutline,carFrontRouteOutline:icons$2.carFrontRouteOutline,carSensorsOutline:icons$2.carSensorsOutline,carSideRouteOutline:icons$2.carSideRouteOutline,chargeLL:icons$2.chargeLL,cityOutline:icons$2.cityOutline,clutchL:icons$2.clutchL,couplerL:icons$2.couplerL,dialogOutline:icons$2.dialogOutline,documentSmileOutline:icons$2.documentSmileOutline,drivetrainOutline:icons$2.drivetrainOutline,electronicSchemeOutline:icons$2.electronicSchemeOutline,engineL:icons$2.engineL,engineOutline:icons$2.engineOutline,gearTuningOutline:icons$2.gearTuningOutline,giftBoxOutline:icons$2.giftBoxOutline,lidarOutline:icons$2.lidarOutline,medalStarOutline:icons$2.medalStarOutline,megaphoneOutline:icons$2.megaphoneOutline,multiseatL:icons$2.multiseatL,peopleOutline:icons$2.peopleOutline,personOutline:icons$2.personOutline,physicsOutline:icons$2.physicsOutline,playChainOutline:icons$2.playChainOutline,POITimeL:icons$2.POITimeL,proximitySensorsOutline:icons$2.proximitySensorsOutline,qualityBadgeStarOutline:icons$2.qualityBadgeStarOutline,qualityBadgeVOutline:icons$2.qualityBadgeVOutline,replayL:icons$2.replayL,roadblockL:icons$2.roadblockL,rotationL:icons$2.rotationL,sensorsL:icons$2.sensorsL,simRigOutline:icons$2.simRigOutline,suspensionOutline:icons$2.suspensionOutline,teamOutline:icons$2.teamOutline,techLightBulbOutline01:icons$2.techLightBulbOutline01,techLightBulbOutline02:icons$2.techLightBulbOutline02,temperatureL:icons$2.temperatureL,timeUnlockOutline:icons$2.timeUnlockOutline,timedLockOutline:icons$2.timedLockOutline,trafficOutline:icons$2.trafficOutline,tuningL:icons$2.tuningL,turbineL:icons$2.turbineL,voucherOutline:icons$2.voucherOutline,wheelBeamsNodesOutline:icons$2.wheelBeamsNodesOutline,wheelOutline:icons$2.wheelOutline,bridge:icons$2.bridge,bump:icons$2.bump,bumps:icons$2.bumps,caution:icons$2.caution,crest:icons$2.crest,doubleCaution:icons$2.doubleCaution,finish:icons$2.finish,jumpOverBump:icons$2.jumpOverBump,narrows:icons$2.narrows,pothole:icons$2.pothole,turn1:icons$2.turn1,turn2:icons$2.turn2,turn3:icons$2.turn3,turn4:icons$2.turn4,turn5:icons$2.turn5,turn6:icons$2.turn6,turnHp:icons$2.turnHp,turnSq:icons$2.turnSq,water:icons$2.water,beamCurrencyOutlineLarge:icons$2.beamCurrencyOutlineLarge,carSideOutlineLarge:icons$2.carSideOutlineLarge,flagOutlineLarge:icons$2.flagOutlineLarge,terrainOutlineLarge:icons$2.terrainOutlineLarge,tripleCaution:icons$2.tripleCaution},56:{circlePinBack:icons$2.circlePinBack,circlePinFront:icons$2.circlePinFront,markerRectanglePinBack:icons$2.markerRectanglePinBack,markerRectanglePinFront:icons$2.markerRectanglePinFront,markerTriangleBack:icons$2.markerTriangleBack,markerTriangleFront:icons$2.markerTriangleFront}}),iconsByTag=Object.freeze({vehicle:{"4WD":icons$2[`4WD`],ABSIndicator:icons$2.ABSIndicator,AWD:icons$2.AWD,axleLift:icons$2.axleLift,axleCenter:icons$2.axleCenter,axleFront:icons$2.axleFront,axleRear:icons$2.axleRear,boxTruck:icons$2.boxTruck,bus:icons$2.bus,carChase01:icons$2.carChase01,carCoin:icons$2.carCoin,carCoins:icons$2.carCoins,carCrash:icons$2.carCrash,carOffroadOutlineRear:icons$2.carOffroadOutlineRear,carOffroadOutlineSide:icons$2.carOffroadOutlineSide,carOffroadRear:icons$2.carOffroadRear,carOffroadSide:icons$2.carOffroadSide,carSensors:icons$2.carSensors,carStarred:icons$2.carStarred,carToWheels:icons$2.carToWheels,carUp:icons$2.carUp,carWithLidar:icons$2.carWithLidar,car:icons$2.car,carsChase02:icons$2.carsChase02,cars:icons$2.cars,centrifugalClutchLocked03:icons$2.centrifugalClutchLocked03,centrifugalClutchUnlocked03:icons$2.centrifugalClutchUnlocked03,cogDamaged:icons$2.cogDamaged,cogsDamaged:icons$2.cogsDamaged,cogs:icons$2.cogs,coolantTemp:icons$2.coolantTemp,cruiseDisable:icons$2.cruiseDisable,cruiseEnable:icons$2.cruiseEnable,DCBattery:icons$2.DCBattery,deliveryTruckArrows:icons$2.deliveryTruckArrows,deliveryTruck:icons$2.deliveryTruck,differentialFrontDefault:icons$2.differentialFrontDefault,differentialFrontLocked:icons$2.differentialFrontLocked,differentialMiddleDefault:icons$2.differentialMiddleDefault,differentialMiddleLocked:icons$2.differentialMiddleLocked,differentialRearDefault:icons$2.differentialRearDefault,differentialRearLocked:icons$2.differentialRearLocked,doorHandle:icons$2.doorHandle,drift01:icons$2.drift01,drift02:icons$2.drift02,drivetrainGeneric:icons$2.drivetrainGeneric,drivetrainSpecial:icons$2.drivetrainSpecial,engine:icons$2.engine,ESCOff:icons$2.ESCOff,ESCOn:icons$2.ESCOn,ESC:icons$2.ESC,exhaustValve:icons$2.exhaustValve,flatbedTruck:icons$2.flatbedTruck,fogLight:icons$2.fogLight,forklift:icons$2.forklift,FWD:icons$2.FWD,hazardLights:icons$2.hazardLights,highBeam:icons$2.highBeam,hydroPump1:icons$2.hydroPump1,hydroPump2:icons$2.hydroPump2,hydroPump3:icons$2.hydroPump3,hydroPump4:icons$2.hydroPump4,hydroPump5:icons$2.hydroPump5,hydroPump6:icons$2.hydroPump6,hydroPump7:icons$2.hydroPump7,jointLocked:icons$2.jointLocked,jointUnlocked:icons$2.jointUnlocked,keys1:icons$2.keys1,keys2:icons$2.keys2,limiterEnable:icons$2.limiterEnable,lowBeam:icons$2.lowBeam,minusRes:icons$2.minusRes,mirrorInteriorMiddle:icons$2.mirrorInteriorMiddle,mirrorLeftBigBottomWideAngle:icons$2.mirrorLeftBigBottomWideAngle,mirrorLeftBigTop:icons$2.mirrorLeftBigTop,mirrorLeftBig:icons$2.mirrorLeftBig,mirrorLeftBonnet:icons$2.mirrorLeftBonnet,mirrorLeftDefault:icons$2.mirrorLeftDefault,mirrorRightBigBottomWideAngle:icons$2.mirrorRightBigBottomWideAngle,mirrorRightBigTop:icons$2.mirrorRightBigTop,mirrorRightBig:icons$2.mirrorRightBig,mirrorRightBonnet:icons$2.mirrorRightBonnet,mirrorRightDefault:icons$2.mirrorRightDefault,mirrorRoundWideAngle:icons$2.mirrorRoundWideAngle,mirrorTopWideAngle:icons$2.mirrorTopWideAngle,odometerKM:icons$2.odometerKM,odometerMI:icons$2.odometerMI,odometer:icons$2.odometer,oilPressureIndicator:icons$2.oilPressureIndicator,parkingIndicator:icons$2.parkingIndicator,plusSet:icons$2.plusSet,positionLights:icons$2.positionLights,powerGauge01:icons$2.powerGauge01,powerGauge02:icons$2.powerGauge02,powerGauge03:icons$2.powerGauge03,powerGauge04:icons$2.powerGauge04,powerGauge05:icons$2.powerGauge05,rangeboxHi2:icons$2.rangeboxHi2,rangeboxHi4:icons$2.rangeboxHi4,rangeboxHiA:icons$2.rangeboxHiA,rangeboxLo2:icons$2.rangeboxLo2,rangeboxLo4:icons$2.rangeboxLo4,rangeboxLoA:icons$2.rangeboxLoA,rockCrawling01:icons$2.rockCrawling01,RWD:icons$2.RWD,semiTrailer:icons$2.semiTrailer,semiTruckCabover:icons$2.semiTruckCabover,semiTruckUS:icons$2.semiTruckUS,semiTruck:icons$2.semiTruck,smallTrailer:icons$2.smallTrailer,spoilerLift:icons$2.spoilerLift,strobeLights:icons$2.strobeLights,suspension01:icons$2.suspension01,suspension02:icons$2.suspension02,synchro01:icons$2.synchro01,synchro02:icons$2.synchro02,tankerTrailer:icons$2.tankerTrailer,taxiCar1:icons$2.taxiCar1,taxiCar3:icons$2.taxiCar3,taxiCarT:icons$2.taxiCarT,taxiCheckerLamp:icons$2.taxiCheckerLamp,tirePressureDecrease01:icons$2.tirePressureDecrease01,tirePressureDecrease02:icons$2.tirePressureDecrease02,tirePressureGaugeAlt01:icons$2.tirePressureGaugeAlt01,tirePressureGaugeAlt02:icons$2.tirePressureGaugeAlt02,tirePressureGaugeAlt03:icons$2.tirePressureGaugeAlt03,tirePressureGaugeOutlined01:icons$2.tirePressureGaugeOutlined01,tirePressureGaugeOutlined02:icons$2.tirePressureGaugeOutlined02,tirePressureGaugeOutlined03:icons$2.tirePressureGaugeOutlined03,tirePressureGaugeSolid01:icons$2.tirePressureGaugeSolid01,tirePressureGaugeSolid02:icons$2.tirePressureGaugeSolid02,tirePressureGaugeSolid03:icons$2.tirePressureGaugeSolid03,tirePressureIncrease01:icons$2.tirePressureIncrease01,tirePressureIncrease02:icons$2.tirePressureIncrease02,tirePressureStopLine:icons$2.tirePressureStopLine,tirePressureStopOctoLine:icons$2.tirePressureStopOctoLine,tirePressureStopOctoSolid:icons$2.tirePressureStopOctoSolid,tirePressureStopSolid:icons$2.tirePressureStopSolid,tow:icons$2.tow,tractionControl:icons$2.tractionControl,transmissionA:icons$2.transmissionA,transmissionM:icons$2.transmissionM,turbine:icons$2.turbine,vehicleDoorsClose:icons$2.vehicleDoorsClose,vehicleDoorsOpen:icons$2.vehicleDoorsOpen,vehicleDoors:icons$2.vehicleDoors,vehicleFeatures01:icons$2.vehicleFeatures01,vehicleFeatures02:icons$2.vehicleFeatures02,vehicleFeatures03:icons$2.vehicleFeatures03,vehicleHood:icons$2.vehicleHood,vehicleTrunk:icons$2.vehicleTrunk,wheelHubLocked01:icons$2.wheelHubLocked01,wheelHubUnlocked01:icons$2.wheelHubUnlocked01,wigwags:icons$2.wigwags,wrench:icons$2.wrench,accelerationKPH:icons$2.accelerationKPH,accelerationMPH:icons$2.accelerationMPH,boxTruckFast:icons$2.boxTruckFast,doorFrontCoins:icons$2.doorFrontCoins,doorFront:icons$2.doorFront,engineCoins:icons$2.engineCoins,exhaustMufflerCoins:icons$2.exhaustMufflerCoins,exhaustMuffler:icons$2.exhaustMuffler,headlightCoins:icons$2.headlightCoins,headlight:icons$2.headlight,tire3FourthCoins:icons$2.tire3FourthCoins,tire3Fourth:icons$2.tire3Fourth,turbineCoins:icons$2.turbineCoins,wheelDiscCoins:icons$2.wheelDiscCoins,wheelDisc:icons$2.wheelDisc,busTilted:icons$2.busTilted,jointLockedMultiple:icons$2.jointLockedMultiple,jointUnlockedMultiple:icons$2.jointUnlockedMultiple,airPuffRight1:icons$2.airPuffRight1,carClock:icons$2.carClock,carFast:icons$2.carFast,carNumber1:icons$2.carNumber1,carNumber2:icons$2.carNumber2,carNumber3:icons$2.carNumber3,carNumber4:icons$2.carNumber4,carNumber5:icons$2.carNumber5,carNumber6:icons$2.carNumber6,carNumber7:icons$2.carNumber7,carNumber8:icons$2.carNumber8,carNumber9:icons$2.carNumber9,carPlus:icons$2.carPlus,carsChange:icons$2.carsChange,carsFollow:icons$2.carsFollow,doorFrontDetached:icons$2.doorFrontDetached,hingeBroken:icons$2.hingeBroken,octagonBrick:icons$2.octagonBrick,octagon:icons$2.octagon,tireAirPuff:icons$2.tireAirPuff,tireDeflated:icons$2.tireDeflated,carSideOutlineLarge:icons$2.carSideOutlineLarge,carFastReverse:icons$2.carFastReverse,carsChase:icons$2.carsChase,carsFlee:icons$2.carsFlee,hammerParticles:icons$2.hammerParticles,rangeboxHi:icons$2.rangeboxHi,rangeboxLo:icons$2.rangeboxLo,carsWrench:icons$2.carsWrench,jointCycleMultiple:icons$2.jointCycleMultiple,jointCycle:icons$2.jointCycle,intakeTrumpets:icons$2.intakeTrumpets,transmissionCvt:icons$2.transmissionCvt,auxUpDown:icons$2.auxUpDown,bucketArmUpDown:icons$2.bucketArmUpDown,bucketTilt:icons$2.bucketTilt,bucketArmDown:icons$2.bucketArmDown,bucketArmLevel:icons$2.bucketArmLevel,bucketArmUp:icons$2.bucketArmUp,bucketTiltDown:icons$2.bucketTiltDown,bucketTiltLevel:icons$2.bucketTiltLevel,bucketTiltUp:icons$2.bucketTiltUp,dumpBedDown:icons$2.dumpBedDown,dumpBedUpDown:icons$2.dumpBedUpDown,dumpBedUp:icons$2.dumpBedUp},features:{"4WD":icons$2[`4WD`],ABSIndicator:icons$2.ABSIndicator,AWD:icons$2.AWD,axleLift:icons$2.axleLift,axleCenter:icons$2.axleCenter,axleFront:icons$2.axleFront,axleRear:icons$2.axleRear,carCoin:icons$2.carCoin,carCoins:icons$2.carCoins,carDealer:icons$2.carDealer,carStarred:icons$2.carStarred,centrifugalClutchLocked03:icons$2.centrifugalClutchLocked03,centrifugalClutchUnlocked03:icons$2.centrifugalClutchUnlocked03,cogDamaged:icons$2.cogDamaged,cogsDamaged:icons$2.cogsDamaged,cogs:icons$2.cogs,coolantTemp:icons$2.coolantTemp,cruiseDisable:icons$2.cruiseDisable,cruiseEnable:icons$2.cruiseEnable,DCBattery:icons$2.DCBattery,differentialFrontDefault:icons$2.differentialFrontDefault,differentialFrontLocked:icons$2.differentialFrontLocked,differentialMiddleDefault:icons$2.differentialMiddleDefault,differentialMiddleLocked:icons$2.differentialMiddleLocked,differentialRearDefault:icons$2.differentialRearDefault,differentialRearLocked:icons$2.differentialRearLocked,doorHandle:icons$2.doorHandle,drivetrainGeneric:icons$2.drivetrainGeneric,drivetrainSpecial:icons$2.drivetrainSpecial,engine:icons$2.engine,ESCOff:icons$2.ESCOff,ESCOn:icons$2.ESCOn,ESC:icons$2.ESC,exhaustValve:icons$2.exhaustValve,fogLight:icons$2.fogLight,FWD:icons$2.FWD,garage01:icons$2.garage01,garage02:icons$2.garage02,garage03:icons$2.garage03,hazardLights:icons$2.hazardLights,highBeam:icons$2.highBeam,hydroPump1:icons$2.hydroPump1,hydroPump2:icons$2.hydroPump2,hydroPump3:icons$2.hydroPump3,hydroPump4:icons$2.hydroPump4,hydroPump5:icons$2.hydroPump5,hydroPump6:icons$2.hydroPump6,hydroPump7:icons$2.hydroPump7,jointLocked:icons$2.jointLocked,jointUnlocked:icons$2.jointUnlocked,keys1:icons$2.keys1,keys2:icons$2.keys2,limiterEnable:icons$2.limiterEnable,lowBeam:icons$2.lowBeam,minusRes:icons$2.minusRes,mirrorInteriorMiddle:icons$2.mirrorInteriorMiddle,mirrorLeftBigBottomWideAngle:icons$2.mirrorLeftBigBottomWideAngle,mirrorLeftBigTop:icons$2.mirrorLeftBigTop,mirrorLeftBig:icons$2.mirrorLeftBig,mirrorLeftBonnet:icons$2.mirrorLeftBonnet,mirrorLeftDefault:icons$2.mirrorLeftDefault,mirrorRightBigBottomWideAngle:icons$2.mirrorRightBigBottomWideAngle,mirrorRightBigTop:icons$2.mirrorRightBigTop,mirrorRightBig:icons$2.mirrorRightBig,mirrorRightBonnet:icons$2.mirrorRightBonnet,mirrorRightDefault:icons$2.mirrorRightDefault,mirrorRoundWideAngle:icons$2.mirrorRoundWideAngle,mirrorTopWideAngle:icons$2.mirrorTopWideAngle,odometerKM:icons$2.odometerKM,odometerMI:icons$2.odometerMI,odometer:icons$2.odometer,oilPressureIndicator:icons$2.oilPressureIndicator,parkingIndicator:icons$2.parkingIndicator,plusGarage1:icons$2.plusGarage1,plusGarage2:icons$2.plusGarage2,plusGarage3:icons$2.plusGarage3,plusGarage4:icons$2.plusGarage4,plusSet:icons$2.plusSet,positionLights:icons$2.positionLights,powerGauge01:icons$2.powerGauge01,powerGauge02:icons$2.powerGauge02,powerGauge03:icons$2.powerGauge03,powerGauge04:icons$2.powerGauge04,powerGauge05:icons$2.powerGauge05,rangeboxHi2:icons$2.rangeboxHi2,rangeboxHi4:icons$2.rangeboxHi4,rangeboxHiA:icons$2.rangeboxHiA,rangeboxLo2:icons$2.rangeboxLo2,rangeboxLo4:icons$2.rangeboxLo4,rangeboxLoA:icons$2.rangeboxLoA,RWD:icons$2.RWD,spoilerLift:icons$2.spoilerLift,strobeLights:icons$2.strobeLights,suspension01:icons$2.suspension01,suspension02:icons$2.suspension02,synchro01:icons$2.synchro01,synchro02:icons$2.synchro02,tirePressureDecrease01:icons$2.tirePressureDecrease01,tirePressureDecrease02:icons$2.tirePressureDecrease02,tirePressureGaugeAlt01:icons$2.tirePressureGaugeAlt01,tirePressureGaugeAlt02:icons$2.tirePressureGaugeAlt02,tirePressureGaugeAlt03:icons$2.tirePressureGaugeAlt03,tirePressureGaugeOutlined01:icons$2.tirePressureGaugeOutlined01,tirePressureGaugeOutlined02:icons$2.tirePressureGaugeOutlined02,tirePressureGaugeOutlined03:icons$2.tirePressureGaugeOutlined03,tirePressureGaugeSolid01:icons$2.tirePressureGaugeSolid01,tirePressureGaugeSolid02:icons$2.tirePressureGaugeSolid02,tirePressureGaugeSolid03:icons$2.tirePressureGaugeSolid03,tirePressureIncrease01:icons$2.tirePressureIncrease01,tirePressureIncrease02:icons$2.tirePressureIncrease02,tirePressureStopLine:icons$2.tirePressureStopLine,tirePressureStopOctoLine:icons$2.tirePressureStopOctoLine,tirePressureStopOctoSolid:icons$2.tirePressureStopOctoSolid,tirePressureStopSolid:icons$2.tirePressureStopSolid,tractionControl:icons$2.tractionControl,transmissionA:icons$2.transmissionA,transmissionM:icons$2.transmissionM,turbine:icons$2.turbine,vehicleDoorsClose:icons$2.vehicleDoorsClose,vehicleDoorsOpen:icons$2.vehicleDoorsOpen,vehicleDoors:icons$2.vehicleDoors,vehicleFeatures01:icons$2.vehicleFeatures01,vehicleFeatures02:icons$2.vehicleFeatures02,vehicleFeatures03:icons$2.vehicleFeatures03,vehicleHood:icons$2.vehicleHood,vehicleTrunk:icons$2.vehicleTrunk,wheelHubLocked01:icons$2.wheelHubLocked01,wheelHubUnlocked01:icons$2.wheelHubUnlocked01,wigwags:icons$2.wigwags,wrench:icons$2.wrench,accelerationKPH:icons$2.accelerationKPH,accelerationMPH:icons$2.accelerationMPH,doorFrontCoins:icons$2.doorFrontCoins,doorFront:icons$2.doorFront,engineCoins:icons$2.engineCoins,exhaustMufflerCoins:icons$2.exhaustMufflerCoins,exhaustMuffler:icons$2.exhaustMuffler,headlightCoins:icons$2.headlightCoins,headlight:icons$2.headlight,tire3FourthCoins:icons$2.tire3FourthCoins,tire3Fourth:icons$2.tire3Fourth,turbineCoins:icons$2.turbineCoins,wheelDiscCoins:icons$2.wheelDiscCoins,wheelDisc:icons$2.wheelDisc,jointLockedMultiple:icons$2.jointLockedMultiple,jointUnlockedMultiple:icons$2.jointUnlockedMultiple,bridge:icons$2.bridge,bump:icons$2.bump,bumps:icons$2.bumps,caution:icons$2.caution,crest:icons$2.crest,doubleCaution:icons$2.doubleCaution,finish:icons$2.finish,jumpOverBump:icons$2.jumpOverBump,narrows:icons$2.narrows,pothole:icons$2.pothole,turn1:icons$2.turn1,turn2:icons$2.turn2,turn3:icons$2.turn3,turn4:icons$2.turn4,turn5:icons$2.turn5,turn6:icons$2.turn6,turnHp:icons$2.turnHp,turnSq:icons$2.turnSq,water:icons$2.water,carsFollow:icons$2.carsFollow,doorFrontDetached:icons$2.doorFrontDetached,garageNumber1:icons$2.garageNumber1,garageNumber2:icons$2.garageNumber2,garageNumber3:icons$2.garageNumber3,garageNumber4:icons$2.garageNumber4,garageNumber5:icons$2.garageNumber5,garageNumber6:icons$2.garageNumber6,garageNumber7:icons$2.garageNumber7,garageNumber8:icons$2.garageNumber8,garageNumber9:icons$2.garageNumber9,hingeBroken:icons$2.hingeBroken,houseWrenchRoof:icons$2.houseWrenchRoof,houseWrench:icons$2.houseWrench,tripleCaution:icons$2.tripleCaution,carsChase:icons$2.carsChase,carsFlee:icons$2.carsFlee,hammerParticles:icons$2.hammerParticles,rangeboxHi:icons$2.rangeboxHi,rangeboxLo:icons$2.rangeboxLo,jointCycleMultiple:icons$2.jointCycleMultiple,jointCycle:icons$2.jointCycle,intakeTrumpets:icons$2.intakeTrumpets,transmissionCvt:icons$2.transmissionCvt,house:icons$2.house,auxUpDown:icons$2.auxUpDown,bucketArmUpDown:icons$2.bucketArmUpDown,bucketTilt:icons$2.bucketTilt,bucketArmDown:icons$2.bucketArmDown,bucketArmLevel:icons$2.bucketArmLevel,bucketArmUp:icons$2.bucketArmUp,bucketTiltDown:icons$2.bucketTiltDown,bucketTiltLevel:icons$2.bucketTiltLevel,bucketTiltUp:icons$2.bucketTiltUp,dumpBedDown:icons$2.dumpBedDown,dumpBedUpDown:icons$2.dumpBedUpDown,dumpBedUp:icons$2.dumpBedUp},generic:{"9dividedby10":icons$2[`9dividedby10`],abandon:icons$2.abandon,addItemPolygon:icons$2.addItemPolygon,addListItem:icons$2.addListItem,addPolygonVertex:icons$2.addPolygonVertex,adjust:icons$2.adjust,AIMicrochip:icons$2.AIMicrochip,aperture:icons$2.aperture,autobahn:icons$2.autobahn,bSpline:icons$2.bSpline,beamCrashBarrier1:icons$2.beamCrashBarrier1,beamCrashBarrier2:icons$2.beamCrashBarrier2,beamCrashBarrier3:icons$2.beamCrashBarrier3,beamNG:icons$2.beamNG,bezierPath1:icons$2.bezierPath1,bezierPath2:icons$2.bezierPath2,bicycle1:icons$2.bicycle1,bicycle2:icons$2.bicycle2,BNGFolder:icons$2.BNGFolder,BNGMicrochip:icons$2.BNGMicrochip,bollard:icons$2.bollard,bookmark:icons$2.bookmark,booleanIntersect:icons$2.booleanIntersect,broom:icons$2.broom,bucketAdd:icons$2.bucketAdd,bucketSubtract:icons$2.bucketSubtract,bug:icons$2.bug,bulldozer:icons$2.bulldozer,carChase01:icons$2.carChase01,carCrash:icons$2.carCrash,carOffroadOutlineRear:icons$2.carOffroadOutlineRear,carOffroadOutlineSide:icons$2.carOffroadOutlineSide,carOffroadRear:icons$2.carOffroadRear,carOffroadSide:icons$2.carOffroadSide,carSensors:icons$2.carSensors,carToWheels:icons$2.carToWheels,carUp:icons$2.carUp,carWithLidar:icons$2.carWithLidar,car:icons$2.car,cardboardBox:icons$2.cardboardBox,carsChase02:icons$2.carsChase02,cars:icons$2.cars,catalog01:icons$2.catalog01,catalog02:icons$2.catalog02,catalog03:icons$2.catalog03,chartBars:icons$2.chartBars,checkmarkBold:icons$2.checkmarkBold,checkmark:icons$2.checkmark,circuitMicrochip:icons$2.circuitMicrochip,clapperboard:icons$2.clapperboard,code:icons$2.code,concreteRoadBlock:icons$2.concreteRoadBlock,copy:icons$2.copy,crossroads1:icons$2.crossroads1,crossroads2:icons$2.crossroads2,cup:icons$2.cup,dataExchange:icons$2.dataExchange,decalRoad:icons$2.decalRoad,decal:icons$2.decal,deform:icons$2.deform,doorIn:icons$2.doorIn,editCheckmark:icons$2.editCheckmark,edit:icons$2.edit,exit:icons$2.exit,export:icons$2.export,eyeOutlineClosed:icons$2.eyeOutlineClosed,eyeOutlineOpened:icons$2.eyeOutlineOpened,eyeSolidClosed:icons$2.eyeSolidClosed,eyeSolidOpened:icons$2.eyeSolidOpened,eyeWaves:icons$2.eyeWaves,facility02:icons$2.facility02,filter:icons$2.filter,flatBulbBeam:icons$2.flatBulbBeam,floppyDisk:icons$2.floppyDisk,folder:icons$2.folder,FPS:icons$2.FPS,frontAxleMidpoint:icons$2.frontAxleMidpoint,frontBumperMidpoint:icons$2.frontBumperMidpoint,globe:icons$2.globe,GPSMark:icons$2.GPSMark,GPSSolid:icons$2.GPSSolid,group:icons$2.group,gyroscopeMicrochip:icons$2.gyroscopeMicrochip,gyroscope:icons$2.gyroscope,helmets:icons$2.helmets,help:icons$2.help,HUD:icons$2.HUD,import:icons$2.import,infinity:icons$2.infinity,info:icons$2.info,lampPost1:icons$2.lampPost1,lampPost2:icons$2.lampPost2,lampPost3:icons$2.lampPost3,laneProperties:icons$2.laneProperties,language:icons$2.language,laptop:icons$2.laptop,lidarPatternFullArcHighFreq:icons$2.lidarPatternFullArcHighFreq,lidarPatternFullArcMidFreq:icons$2.lidarPatternFullArcMidFreq,lidarPatternNarrowArc:icons$2.lidarPatternNarrowArc,lidar:icons$2.lidar,lightrunner:icons$2.lightrunner,lineToTerrain:icons$2.lineToTerrain,link2:icons$2.link2,link:icons$2.link,listBig:icons$2.listBig,listIndented:icons$2.listIndented,listSmall:icons$2.listSmall,location1:icons$2.location1,location2:icons$2.location2,lockClosed:icons$2.lockClosed,lockOpened:icons$2.lockOpened,longRangeBeam1:icons$2.longRangeBeam1,longRangeBeam2:icons$2.longRangeBeam2,magnetOnSurface:icons$2.magnetOnSurface,mapWithEmitter:icons$2.mapWithEmitter,mapPoint:icons$2.mapPoint,material:icons$2.material,mathDivide:icons$2.mathDivide,mathGreaterOrEqualThan:icons$2.mathGreaterOrEqualThan,mathGreaterThan:icons$2.mathGreaterThan,mathLessOrEqualThan:icons$2.mathLessOrEqualThan,mathLessThan:icons$2.mathLessThan,mathMinus:icons$2.mathMinus,mathMultiply:icons$2.mathMultiply,mathPlus:icons$2.mathPlus,medal:icons$2.medal,meshFence:icons$2.meshFence,meshRoad:icons$2.meshRoad,midRangeBeam1:icons$2.midRangeBeam1,midRangeBeam2:icons$2.midRangeBeam2,minus:icons$2.minus,move02:icons$2.move02,move:icons$2.move,nodeAddFirst01:icons$2.nodeAddFirst01,nodeAddFirst02:icons$2.nodeAddFirst02,nodeAddLast02:icons$2.nodeAddLast02,nodeAddMiddle01:icons$2.nodeAddMiddle01,nodeAddMiddle02:icons$2.nodeAddMiddle02,nodeAdd:icons$2.nodeAdd,nodeLast01:icons$2.nodeLast01,nodeRemove:icons$2.nodeRemove,order:icons$2.order,organization:icons$2.organization,paperKnife:icons$2.paperKnife,pathArc:icons$2.pathArc,pathLine:icons$2.pathLine,pathSpiral:icons$2.pathSpiral,personSolid:icons$2.personSolid,person:icons$2.person,photo:icons$2.photo,placeholder:icons$2.placeholder,plus:icons$2.plus,powerOnOff:icons$2.powerOnOff,publisher:icons$2.publisher,puzzleModule:icons$2.puzzleModule,radarIdeal:icons$2.radarIdeal,radarRoundIdeal:icons$2.radarRoundIdeal,radarRound:icons$2.radarRound,radar:icons$2.radar,rearAxleMidpoint:icons$2.rearAxleMidpoint,rearBumperMidpoint:icons$2.rearBumperMidpoint,reconfigure:icons$2.reconfigure,redo:icons$2.redo,reflectNot:icons$2.reflectNot,reflect:icons$2.reflect,rename:icons$2.rename,replay:icons$2.replay,restart:icons$2.restart,roadDividerLinesDecal:icons$2.roadDividerLinesDecal,roadEdgeLineDecal:icons$2.roadEdgeLineDecal,roadEndLineDecal:icons$2.roadEndLineDecal,roadFace:icons$2.roadFace,roadInfo:icons$2.roadInfo,roadMarkingOutline:icons$2.roadMarkingOutline,roadMarkingSolid:icons$2.roadMarkingSolid,roadOutline:icons$2.roadOutline,roadRefPathDecal:icons$2.roadRefPathDecal,roadRefPath:icons$2.roadRefPath,roadStartLineDecal:icons$2.roadStartLineDecal,road:icons$2.road,runScript:icons$2.runScript,saveAs1:icons$2.saveAs1,scan:icons$2.scan,search:icons$2.search,shortRangeBeam1:icons$2.shortRangeBeam1,shortRangeBeam2:icons$2.shortRangeBeam2,signal01a:icons$2.signal01a,signal02a:icons$2.signal02a,signal03a:icons$2.signal03a,signal04a:icons$2.signal04a,signal05a:icons$2.signal05a,slashLeft:icons$2.slashLeft,slashRight:icons$2.slashRight,snowflake:icons$2.snowflake,soundFadeOut:icons$2.soundFadeOut,soundLimit:icons$2.soundLimit,soundLoud:icons$2.soundLoud,soundMonoL:icons$2.soundMonoL,soundMonoR:icons$2.soundMonoR,soundOff:icons$2.soundOff,soundQuiet:icons$2.soundQuiet,soundStereo:icons$2.soundStereo,soundWave01:icons$2.soundWave01,soundWave02:icons$2.soundWave02,sphereOnPathNumber:icons$2.sphereOnPathNumber,sphereOnPath:icons$2.sphereOnPath,sphericalBeam:icons$2.sphericalBeam,sprayCan:icons$2.sprayCan,star:icons$2.star,starSecondary:icons$2.starSecondary,stopwatchArrows01:icons$2.stopwatchArrows01,stopwatchArrows02:icons$2.stopwatchArrows02,stopwatchSectionOutlinedEnd:icons$2.stopwatchSectionOutlinedEnd,stopwatchSectionOutlinedStart:icons$2.stopwatchSectionOutlinedStart,stopwatchSectionSolidEnd:icons$2.stopwatchSectionSolidEnd,stopwatchSectionSolidStart:icons$2.stopwatchSectionSolidStart,survellianceCamera:icons$2.survellianceCamera,switchBlock:icons$2.switchBlock,switchOutline:icons$2.switchOutline,sync:icons$2.sync,taxiCar1:icons$2.taxiCar1,taxiCar3:icons$2.taxiCar3,taxiCarT:icons$2.taxiCarT,taxiCheckerLamp:icons$2.taxiCheckerLamp,terrainToLine:icons$2.terrainToLine,terrain:icons$2.terrain,thinBulbBeam:icons$2.thinBulbBeam,thinnerBulbBeam:icons$2.thinnerBulbBeam,tiles:icons$2.tiles,timer:icons$2.timer,toCOMWithWheels:icons$2.toCOMWithWheels,toCOM:icons$2.toCOM,tow:icons$2.tow,transform:icons$2.transform,transparencyMask:icons$2.transparencyMask,trashBin2:icons$2.trashBin2,triangleBeam:icons$2.triangleBeam,trim:icons$2.trim,tulipBeam:icons$2.tulipBeam,tunnel:icons$2.tunnel,twoRoadsAdd:icons$2.twoRoadsAdd,twoRoadsCrossAdd:icons$2.twoRoadsCrossAdd,twoRoadsLink:icons$2.twoRoadsLink,undo:icons$2.undo,ungroup:icons$2.ungroup,unlink:icons$2.unlink,view:icons$2.view,voucherDiagonal1:icons$2.voucherDiagonal1,voucherDiagonal2:icons$2.voucherDiagonal2,voucherDiagonal3:icons$2.voucherDiagonal3,voucherHorizontal1:icons$2.voucherHorizontal1,voucherHorizontal2:icons$2.voucherHorizontal2,voucherHorizontal3:icons$2.voucherHorizontal3,wavesSignalReceived:icons$2.wavesSignalReceived,wavesSignalSentLeft:icons$2.wavesSignalSentLeft,wavesSignalSentRight:icons$2.wavesSignalSentRight,weight:icons$2.weight,wrench:icons$2.wrench,danger:icons$2.danger,droplet:icons$2.droplet,envelope:icons$2.envelope,fireDiamond:icons$2.fireDiamond,xmark:icons$2.xmark,scale:icons$2.scale,locationDestination:icons$2.locationDestination,locationSource:icons$2.locationSource,colorBrightnessSun:icons$2.colorBrightnessSun,colorCirclePalette:icons$2.colorCirclePalette,colorPalette:icons$2.colorPalette,colorSaturation:icons$2.colorSaturation,sortAscDown02:icons$2.sortAscDown02,sortAscDown:icons$2.sortAscDown,sortAscUp02:icons$2.sortAscUp02,sortAscUp:icons$2.sortAscUp,sortDescDown02:icons$2.sortDescDown02,sortDescDown:icons$2.sortDescDown,sortDescUp02:icons$2.sortDescUp02,sortDescUp:icons$2.sortDescUp,cardboardBoxCoins:icons$2.cardboardBoxCoins,lasso:icons$2.lasso,materialGlossy:icons$2.materialGlossy,materialMetal:icons$2.materialMetal,materialRoughness:icons$2.materialRoughness,materialTransparency01:icons$2.materialTransparency01,materialTransparency02:icons$2.materialTransparency02,metal01:icons$2.metal01,removeItemPolygon:icons$2.removeItemPolygon,removeListItem:icons$2.removeListItem,sortAsc:icons$2.sortAsc,sortDesc:icons$2.sortDesc,surfaceRoughness02:icons$2.surfaceRoughness02,shieldCheckmark:icons$2.shieldCheckmark,shieldHandCheckmark:icons$2.shieldHandCheckmark,shieldHandPlus:icons$2.shieldHandPlus,bridgeWithRiver:icons$2.bridgeWithRiver,gizmosOutline:icons$2.gizmosOutline,gizmosSolid:icons$2.gizmosSolid,highwayRoad3To2Merge01:icons$2.highwayRoad3To2Merge01,highwayRoad3To2Merge02:icons$2.highwayRoad3To2Merge02,highwayToUrbanRoadTransition01:icons$2.highwayToUrbanRoadTransition01,highwayToUrbanRoadTransition02:icons$2.highwayToUrbanRoadTransition02,pedestrianCrossing01:icons$2.pedestrianCrossing01,polygonalCube:icons$2.polygonalCube,roadEditOutline:icons$2.roadEditOutline,roadEditSolid:icons$2.roadEditSolid,roadFolderPlus:icons$2.roadFolderPlus,roadFolder:icons$2.roadFolder,roadGuideArrowOutline:icons$2.roadGuideArrowOutline,roadGuideArrowSolid:icons$2.roadGuideArrowSolid,roadOutlineMesh:icons$2.roadOutlineMesh,roadPedestrianCrossing02:icons$2.roadPedestrianCrossing02,roadProfileWithCheckmark:icons$2.roadProfileWithCheckmark,roadProfile:icons$2.roadProfile,roadRoundaboutJunction:icons$2.roadRoundaboutJunction,roadSidewalkTransition:icons$2.roadSidewalkTransition,roadStackPlus:icons$2.roadStackPlus,roadStack:icons$2.roadStack,roadTJunction:icons$2.roadTJunction,roadXJunction:icons$2.roadXJunction,roadYJunction:icons$2.roadYJunction,shoppingCart:icons$2.shoppingCart,singleLineToTerrain:icons$2.singleLineToTerrain,sphereOnMesh:icons$2.sphereOnMesh,twoLinesToTerrain:icons$2.twoLinesToTerrain,urbanRoad3To2Merge01:icons$2.urbanRoad3To2Merge01,urbanRoad3To2Merge02:icons$2.urbanRoad3To2Merge02,urbanRoadToHighwayTransition01:icons$2.urbanRoadToHighwayTransition01,urbanRoadToHighwayTransition02:icons$2.urbanRoadToHighwayTransition02,floppyDiskPlus:icons$2.floppyDiskPlus,highwayMerge:icons$2.highwayMerge,highwaySeparate:icons$2.highwaySeparate,highwayShoulderMerge:icons$2.highwayShoulderMerge,terrainToSingleLine:icons$2.terrainToSingleLine,terrainToTwoLines:icons$2.terrainToTwoLines,urbanRoadMerge:icons$2.urbanRoadMerge,urbanRoadSeparate:icons$2.urbanRoadSeparate,urbanShoulderMerge:icons$2.urbanShoulderMerge,BNGChat:icons$2.BNGChat,chatBubble:icons$2.chatBubble,cameraFarClip:icons$2.cameraFarClip,cameraNearClip:icons$2.cameraNearClip,explosion:icons$2.explosion,fireExtinguisher:icons$2.fireExtinguisher,fire:icons$2.fire,toggleOff:icons$2.toggleOff,toggleOn:icons$2.toggleOn,viewFarClip:icons$2.viewFarClip,viewNearClip:icons$2.viewNearClip,circleSlashed:icons$2.circleSlashed,scissorsSlashed:icons$2.scissorsSlashed,scissors:icons$2.scissors,airPuffRight1:icons$2.airPuffRight1,airPuffUp1:icons$2.airPuffUp1,arrowsReplace:icons$2.arrowsReplace,arrowsShuffle:icons$2.arrowsShuffle,arrowsSwitch:icons$2.arrowsSwitch,carClock:icons$2.carClock,carNumber1:icons$2.carNumber1,carNumber2:icons$2.carNumber2,carNumber3:icons$2.carNumber3,carNumber4:icons$2.carNumber4,carNumber5:icons$2.carNumber5,carNumber6:icons$2.carNumber6,carNumber7:icons$2.carNumber7,carNumber8:icons$2.carNumber8,carNumber9:icons$2.carNumber9,carPlus:icons$2.carPlus,loadMesh:icons$2.loadMesh,octagonBrick:icons$2.octagonBrick,octagon:icons$2.octagon,saveMesh:icons$2.saveMesh,trafficLight:icons$2.trafficLight,enter:icons$2.enter,pedestrianRunning:icons$2.pedestrianRunning,pedestrianStanding:icons$2.pedestrianStanding,seatArrowIn:icons$2.seatArrowIn,seatArrowOut:icons$2.seatArrowOut,seatVArrowIn:icons$2.seatVArrowIn,seatVArrowOut:icons$2.seatVArrowOut,vehicleArrowIn:icons$2.vehicleArrowIn,vehicleArrowOut:icons$2.vehicleArrowOut,leverFrontOperate:icons$2.leverFrontOperate,leverSideDown:icons$2.leverSideDown,leverSideOperate:icons$2.leverSideOperate,leverSideUp:icons$2.leverSideUp,medalEmpty:icons$2.medalEmpty,medalStar:icons$2.medalStar,seatArrowInLeft:icons$2.seatArrowInLeft,seatArrowOutLeft:icons$2.seatArrowOutLeft,seatVArrowInLeft:icons$2.seatVArrowInLeft,seatVArrowOutLeft:icons$2.seatVArrowOutLeft,badgeRoundEmpty:icons$2.badgeRoundEmpty,badgeRoundStar:icons$2.badgeRoundStar,badgeRound:icons$2.badgeRound,badge:icons$2.badge,beamCurrencyOutlineLarge:icons$2.beamCurrencyOutlineLarge,carSideOutlineLarge:icons$2.carSideOutlineLarge,flagOutlineLarge:icons$2.flagOutlineLarge,terrainOutlineLarge:icons$2.terrainOutlineLarge,rallyHelmet3To4:icons$2.rallyHelmet3To4,rallyHelmet:icons$2.rallyHelmet,test:icons$2.test,globeSimpleNotSign:icons$2.globeSimpleNotSign,globeSimplified:icons$2.globeSimplified,radialMenu:icons$2.radialMenu,branch:icons$2.branch,NA:icons$2.NA,magicWand:icons$2.magicWand,dice24:icons$2.dice24,diceD6:icons$2.diceD6,xmarkBold:icons$2.xmarkBold,house:icons$2.house,picture:icons$2.picture,shieldCheckmarkProgressbar:icons$2.shieldCheckmarkProgressbar},warning:{ABSIndicator:icons$2.ABSIndicator,DCBattery:icons$2.DCBattery,oilPressureIndicator:icons$2.oilPressureIndicator,parkingIndicator:icons$2.parkingIndicator},internals:{ABSIndicator:icons$2.ABSIndicator,DCBattery:icons$2.DCBattery,oilPressureIndicator:icons$2.oilPressureIndicator,parkingIndicator:icons$2.parkingIndicator},we:{addItemPolygon:icons$2.addItemPolygon,addListItem:icons$2.addListItem,addPolygonVertex:icons$2.addPolygonVertex,bSpline:icons$2.bSpline,beamCrashBarrier1:icons$2.beamCrashBarrier1,beamCrashBarrier2:icons$2.beamCrashBarrier2,beamCrashBarrier3:icons$2.beamCrashBarrier3,bezierPath1:icons$2.bezierPath1,bezierPath2:icons$2.bezierPath2,bicycle1:icons$2.bicycle1,bicycle2:icons$2.bicycle2,bollard:icons$2.bollard,bulldozer:icons$2.bulldozer,concreteRoadBlock:icons$2.concreteRoadBlock,crossroads1:icons$2.crossroads1,crossroads2:icons$2.crossroads2,decalRoad:icons$2.decalRoad,flatBulbBeam:icons$2.flatBulbBeam,frontAxleMidpoint:icons$2.frontAxleMidpoint,frontBumperMidpoint:icons$2.frontBumperMidpoint,lampPost1:icons$2.lampPost1,lampPost2:icons$2.lampPost2,lampPost3:icons$2.lampPost3,laneProperties:icons$2.laneProperties,lidarPatternFullArcHighFreq:icons$2.lidarPatternFullArcHighFreq,lidarPatternFullArcMidFreq:icons$2.lidarPatternFullArcMidFreq,lidarPatternNarrowArc:icons$2.lidarPatternNarrowArc,lineToTerrain:icons$2.lineToTerrain,longRangeBeam1:icons$2.longRangeBeam1,longRangeBeam2:icons$2.longRangeBeam2,magnetOnSurface:icons$2.magnetOnSurface,meshFence:icons$2.meshFence,meshRoad:icons$2.meshRoad,midRangeBeam1:icons$2.midRangeBeam1,midRangeBeam2:icons$2.midRangeBeam2,pathArc:icons$2.pathArc,pathLine:icons$2.pathLine,pathSpiral:icons$2.pathSpiral,rearAxleMidpoint:icons$2.rearAxleMidpoint,rearBumperMidpoint:icons$2.rearBumperMidpoint,roadDividerLinesDecal:icons$2.roadDividerLinesDecal,roadEdgeLineDecal:icons$2.roadEdgeLineDecal,roadEndLineDecal:icons$2.roadEndLineDecal,roadFace:icons$2.roadFace,roadMarkingOutline:icons$2.roadMarkingOutline,roadMarkingSolid:icons$2.roadMarkingSolid,roadOutline:icons$2.roadOutline,roadRefPathDecal:icons$2.roadRefPathDecal,roadRefPath:icons$2.roadRefPath,roadStartLineDecal:icons$2.roadStartLineDecal,shortRangeBeam1:icons$2.shortRangeBeam1,shortRangeBeam2:icons$2.shortRangeBeam2,sphereOnPathNumber:icons$2.sphereOnPathNumber,sphereOnPath:icons$2.sphereOnPath,sphericalBeam:icons$2.sphericalBeam,terrainToLine:icons$2.terrainToLine,thinBulbBeam:icons$2.thinBulbBeam,thinnerBulbBeam:icons$2.thinnerBulbBeam,toCOMWithWheels:icons$2.toCOMWithWheels,toCOM:icons$2.toCOM,triangleBeam:icons$2.triangleBeam,tulipBeam:icons$2.tulipBeam,tunnel:icons$2.tunnel,twoRoadsAdd:icons$2.twoRoadsAdd,twoRoadsCrossAdd:icons$2.twoRoadsCrossAdd,twoRoadsLink:icons$2.twoRoadsLink,lasso:icons$2.lasso,removeItemPolygon:icons$2.removeItemPolygon,removeListItem:icons$2.removeListItem,bridgeWithRiver:icons$2.bridgeWithRiver,gizmosOutline:icons$2.gizmosOutline,gizmosSolid:icons$2.gizmosSolid,highwayRoad3To2Merge01:icons$2.highwayRoad3To2Merge01,highwayRoad3To2Merge02:icons$2.highwayRoad3To2Merge02,highwayToUrbanRoadTransition01:icons$2.highwayToUrbanRoadTransition01,highwayToUrbanRoadTransition02:icons$2.highwayToUrbanRoadTransition02,pedestrianCrossing01:icons$2.pedestrianCrossing01,polygonalCube:icons$2.polygonalCube,roadEditOutline:icons$2.roadEditOutline,roadEditSolid:icons$2.roadEditSolid,roadFolderPlus:icons$2.roadFolderPlus,roadFolder:icons$2.roadFolder,roadGuideArrowOutline:icons$2.roadGuideArrowOutline,roadGuideArrowSolid:icons$2.roadGuideArrowSolid,roadOutlineMesh:icons$2.roadOutlineMesh,roadPedestrianCrossing02:icons$2.roadPedestrianCrossing02,roadProfileWithCheckmark:icons$2.roadProfileWithCheckmark,roadProfile:icons$2.roadProfile,roadRoundaboutJunction:icons$2.roadRoundaboutJunction,roadSidewalkTransition:icons$2.roadSidewalkTransition,roadStackPlus:icons$2.roadStackPlus,roadStack:icons$2.roadStack,roadTJunction:icons$2.roadTJunction,roadXJunction:icons$2.roadXJunction,roadYJunction:icons$2.roadYJunction,singleLineToTerrain:icons$2.singleLineToTerrain,sphereOnMesh:icons$2.sphereOnMesh,twoLinesToTerrain:icons$2.twoLinesToTerrain,urbanRoad3To2Merge01:icons$2.urbanRoad3To2Merge01,urbanRoad3To2Merge02:icons$2.urbanRoad3To2Merge02,urbanRoadToHighwayTransition01:icons$2.urbanRoadToHighwayTransition01,urbanRoadToHighwayTransition02:icons$2.urbanRoadToHighwayTransition02,highwayMerge:icons$2.highwayMerge,highwaySeparate:icons$2.highwaySeparate,highwayShoulderMerge:icons$2.highwayShoulderMerge,terrainToSingleLine:icons$2.terrainToSingleLine,terrainToTwoLines:icons$2.terrainToTwoLines,urbanRoadMerge:icons$2.urbanRoadMerge,urbanRoadSeparate:icons$2.urbanRoadSeparate,urbanShoulderMerge:icons$2.urbanShoulderMerge},"world editor":{addItemPolygon:icons$2.addItemPolygon,addListItem:icons$2.addListItem,addPolygonVertex:icons$2.addPolygonVertex,bSpline:icons$2.bSpline,beamCrashBarrier1:icons$2.beamCrashBarrier1,beamCrashBarrier2:icons$2.beamCrashBarrier2,beamCrashBarrier3:icons$2.beamCrashBarrier3,bezierPath1:icons$2.bezierPath1,bezierPath2:icons$2.bezierPath2,bicycle1:icons$2.bicycle1,bicycle2:icons$2.bicycle2,bollard:icons$2.bollard,bulldozer:icons$2.bulldozer,concreteRoadBlock:icons$2.concreteRoadBlock,crossroads1:icons$2.crossroads1,crossroads2:icons$2.crossroads2,decalRoad:icons$2.decalRoad,flatBulbBeam:icons$2.flatBulbBeam,frontAxleMidpoint:icons$2.frontAxleMidpoint,frontBumperMidpoint:icons$2.frontBumperMidpoint,lampPost1:icons$2.lampPost1,lampPost2:icons$2.lampPost2,lampPost3:icons$2.lampPost3,laneProperties:icons$2.laneProperties,lidarPatternFullArcHighFreq:icons$2.lidarPatternFullArcHighFreq,lidarPatternFullArcMidFreq:icons$2.lidarPatternFullArcMidFreq,lidarPatternNarrowArc:icons$2.lidarPatternNarrowArc,lineToTerrain:icons$2.lineToTerrain,longRangeBeam1:icons$2.longRangeBeam1,longRangeBeam2:icons$2.longRangeBeam2,magnetOnSurface:icons$2.magnetOnSurface,meshFence:icons$2.meshFence,meshRoad:icons$2.meshRoad,midRangeBeam1:icons$2.midRangeBeam1,midRangeBeam2:icons$2.midRangeBeam2,pathArc:icons$2.pathArc,pathLine:icons$2.pathLine,pathSpiral:icons$2.pathSpiral,rearAxleMidpoint:icons$2.rearAxleMidpoint,rearBumperMidpoint:icons$2.rearBumperMidpoint,roadDividerLinesDecal:icons$2.roadDividerLinesDecal,roadEdgeLineDecal:icons$2.roadEdgeLineDecal,roadEndLineDecal:icons$2.roadEndLineDecal,roadFace:icons$2.roadFace,roadMarkingOutline:icons$2.roadMarkingOutline,roadMarkingSolid:icons$2.roadMarkingSolid,roadOutline:icons$2.roadOutline,roadRefPathDecal:icons$2.roadRefPathDecal,roadRefPath:icons$2.roadRefPath,roadStartLineDecal:icons$2.roadStartLineDecal,shortRangeBeam1:icons$2.shortRangeBeam1,shortRangeBeam2:icons$2.shortRangeBeam2,sphereOnPathNumber:icons$2.sphereOnPathNumber,sphereOnPath:icons$2.sphereOnPath,sphericalBeam:icons$2.sphericalBeam,terrainToLine:icons$2.terrainToLine,thinBulbBeam:icons$2.thinBulbBeam,thinnerBulbBeam:icons$2.thinnerBulbBeam,toCOMWithWheels:icons$2.toCOMWithWheels,toCOM:icons$2.toCOM,triangleBeam:icons$2.triangleBeam,tulipBeam:icons$2.tulipBeam,tunnel:icons$2.tunnel,twoRoadsAdd:icons$2.twoRoadsAdd,twoRoadsCrossAdd:icons$2.twoRoadsCrossAdd,twoRoadsLink:icons$2.twoRoadsLink,lasso:icons$2.lasso,removeItemPolygon:icons$2.removeItemPolygon,removeListItem:icons$2.removeListItem,bridgeWithRiver:icons$2.bridgeWithRiver,gizmosOutline:icons$2.gizmosOutline,gizmosSolid:icons$2.gizmosSolid,highwayRoad3To2Merge01:icons$2.highwayRoad3To2Merge01,highwayRoad3To2Merge02:icons$2.highwayRoad3To2Merge02,highwayToUrbanRoadTransition01:icons$2.highwayToUrbanRoadTransition01,highwayToUrbanRoadTransition02:icons$2.highwayToUrbanRoadTransition02,pedestrianCrossing01:icons$2.pedestrianCrossing01,polygonalCube:icons$2.polygonalCube,roadEditOutline:icons$2.roadEditOutline,roadEditSolid:icons$2.roadEditSolid,roadFolderPlus:icons$2.roadFolderPlus,roadFolder:icons$2.roadFolder,roadGuideArrowOutline:icons$2.roadGuideArrowOutline,roadGuideArrowSolid:icons$2.roadGuideArrowSolid,roadOutlineMesh:icons$2.roadOutlineMesh,roadPedestrianCrossing02:icons$2.roadPedestrianCrossing02,roadProfileWithCheckmark:icons$2.roadProfileWithCheckmark,roadProfile:icons$2.roadProfile,roadRoundaboutJunction:icons$2.roadRoundaboutJunction,roadSidewalkTransition:icons$2.roadSidewalkTransition,roadStackPlus:icons$2.roadStackPlus,roadStack:icons$2.roadStack,roadTJunction:icons$2.roadTJunction,roadXJunction:icons$2.roadXJunction,roadYJunction:icons$2.roadYJunction,singleLineToTerrain:icons$2.singleLineToTerrain,sphereOnMesh:icons$2.sphereOnMesh,twoLinesToTerrain:icons$2.twoLinesToTerrain,urbanRoad3To2Merge01:icons$2.urbanRoad3To2Merge01,urbanRoad3To2Merge02:icons$2.urbanRoad3To2Merge02,urbanRoadToHighwayTransition01:icons$2.urbanRoadToHighwayTransition01,urbanRoadToHighwayTransition02:icons$2.urbanRoadToHighwayTransition02,highwayMerge:icons$2.highwayMerge,highwaySeparate:icons$2.highwaySeparate,highwayShoulderMerge:icons$2.highwayShoulderMerge,terrainToSingleLine:icons$2.terrainToSingleLine,terrainToTwoLines:icons$2.terrainToTwoLines,urbanRoadMerge:icons$2.urbanRoadMerge,urbanRoadSeparate:icons$2.urbanRoadSeparate,urbanShoulderMerge:icons$2.urbanShoulderMerge},"road tools":{addItemPolygon:icons$2.addItemPolygon,addListItem:icons$2.addListItem,addPolygonVertex:icons$2.addPolygonVertex,bSpline:icons$2.bSpline,beamCrashBarrier1:icons$2.beamCrashBarrier1,beamCrashBarrier2:icons$2.beamCrashBarrier2,beamCrashBarrier3:icons$2.beamCrashBarrier3,bezierPath1:icons$2.bezierPath1,bezierPath2:icons$2.bezierPath2,bicycle1:icons$2.bicycle1,bicycle2:icons$2.bicycle2,bollard:icons$2.bollard,bulldozer:icons$2.bulldozer,concreteRoadBlock:icons$2.concreteRoadBlock,crossroads1:icons$2.crossroads1,crossroads2:icons$2.crossroads2,decalRoad:icons$2.decalRoad,lampPost1:icons$2.lampPost1,lampPost2:icons$2.lampPost2,lampPost3:icons$2.lampPost3,laneProperties:icons$2.laneProperties,lineToTerrain:icons$2.lineToTerrain,magnetOnSurface:icons$2.magnetOnSurface,meshFence:icons$2.meshFence,meshRoad:icons$2.meshRoad,pathArc:icons$2.pathArc,pathLine:icons$2.pathLine,pathSpiral:icons$2.pathSpiral,roadDividerLinesDecal:icons$2.roadDividerLinesDecal,roadEdgeLineDecal:icons$2.roadEdgeLineDecal,roadEndLineDecal:icons$2.roadEndLineDecal,roadFace:icons$2.roadFace,roadMarkingSolid:icons$2.roadMarkingSolid,roadOutline:icons$2.roadOutline,roadRefPathDecal:icons$2.roadRefPathDecal,roadRefPath:icons$2.roadRefPath,roadStartLineDecal:icons$2.roadStartLineDecal,sphereOnPathNumber:icons$2.sphereOnPathNumber,sphereOnPath:icons$2.sphereOnPath,terrainToLine:icons$2.terrainToLine,tunnel:icons$2.tunnel,twoRoadsAdd:icons$2.twoRoadsAdd,twoRoadsCrossAdd:icons$2.twoRoadsCrossAdd,twoRoadsLink:icons$2.twoRoadsLink,removeItemPolygon:icons$2.removeItemPolygon,removeListItem:icons$2.removeListItem,bridgeWithRiver:icons$2.bridgeWithRiver,gizmosOutline:icons$2.gizmosOutline,gizmosSolid:icons$2.gizmosSolid,highwayRoad3To2Merge01:icons$2.highwayRoad3To2Merge01,highwayRoad3To2Merge02:icons$2.highwayRoad3To2Merge02,highwayToUrbanRoadTransition01:icons$2.highwayToUrbanRoadTransition01,highwayToUrbanRoadTransition02:icons$2.highwayToUrbanRoadTransition02,pedestrianCrossing01:icons$2.pedestrianCrossing01,polygonalCube:icons$2.polygonalCube,roadEditOutline:icons$2.roadEditOutline,roadEditSolid:icons$2.roadEditSolid,roadFolderPlus:icons$2.roadFolderPlus,roadFolder:icons$2.roadFolder,roadGuideArrowOutline:icons$2.roadGuideArrowOutline,roadGuideArrowSolid:icons$2.roadGuideArrowSolid,roadOutlineMesh:icons$2.roadOutlineMesh,roadPedestrianCrossing02:icons$2.roadPedestrianCrossing02,roadProfileWithCheckmark:icons$2.roadProfileWithCheckmark,roadProfile:icons$2.roadProfile,roadRoundaboutJunction:icons$2.roadRoundaboutJunction,roadSidewalkTransition:icons$2.roadSidewalkTransition,roadStackPlus:icons$2.roadStackPlus,roadStack:icons$2.roadStack,roadTJunction:icons$2.roadTJunction,roadXJunction:icons$2.roadXJunction,roadYJunction:icons$2.roadYJunction,singleLineToTerrain:icons$2.singleLineToTerrain,sphereOnMesh:icons$2.sphereOnMesh,twoLinesToTerrain:icons$2.twoLinesToTerrain,urbanRoad3To2Merge01:icons$2.urbanRoad3To2Merge01,urbanRoad3To2Merge02:icons$2.urbanRoad3To2Merge02,urbanRoadToHighwayTransition01:icons$2.urbanRoadToHighwayTransition01,urbanRoadToHighwayTransition02:icons$2.urbanRoadToHighwayTransition02,highwayMerge:icons$2.highwayMerge,highwaySeparate:icons$2.highwaySeparate,highwayShoulderMerge:icons$2.highwayShoulderMerge,terrainToSingleLine:icons$2.terrainToSingleLine,terrainToTwoLines:icons$2.terrainToTwoLines,urbanRoadMerge:icons$2.urbanRoadMerge,urbanRoadSeparate:icons$2.urbanRoadSeparate,urbanShoulderMerge:icons$2.urbanShoulderMerge},ai:{AIMicrochip:icons$2.AIMicrochip},microchip:{AIMicrochip:icons$2.AIMicrochip},poi:{AIRace:icons$2.AIRace,barrelKnocker01:icons$2.barrelKnocker01,barrelKnocker02:icons$2.barrelKnocker02,boxDropOff01:icons$2.boxDropOff01,boxDropOff02:icons$2.boxDropOff02,boxDropOff03:icons$2.boxDropOff03,boxPickUp01:icons$2.boxPickUp01,boxPickUp02:icons$2.boxPickUp02,boxPickUp03:icons$2.boxPickUp03,boxPickUpDropOff01:icons$2.boxPickUpDropOff01,boxPickUpDropOff02:icons$2.boxPickUpDropOff02,bus:icons$2.bus,cannon:icons$2.cannon,circuit:icons$2.circuit,deliveryTruckArrows:icons$2.deliveryTruckArrows,deliveryTruck:icons$2.deliveryTruck,drag01:icons$2.drag01,drag02:icons$2.drag02,drift01:icons$2.drift01,drift02:icons$2.drift02,evade:icons$2.evade,fastTravel:icons$2.fastTravel,flagNew:icons$2.flagNew,flag:icons$2.flag,gaugeEmpty:icons$2.gaugeEmpty,hypermiling:icons$2.hypermiling,jump:icons$2.jump,parking:icons$2.parking,raceFlag:icons$2.raceFlag,rockCrawling01:icons$2.rockCrawling01,rockCrawling02:icons$2.rockCrawling02,targetJump:icons$2.targetJump,toGarage:icons$2.toGarage,trashBin1:icons$2.trashBin1,circlePinBack:icons$2.circlePinBack,circlePinFront:icons$2.circlePinFront,markerRectanglePinBack:icons$2.markerRectanglePinBack,markerRectanglePinFront:icons$2.markerRectanglePinFront,markerTriangleBack:icons$2.markerTriangleBack,markerTriangleFront:icons$2.markerTriangleFront,busTilted:icons$2.busTilted,gaugeFull:icons$2.gaugeFull},camera:{aperture:icons$2.aperture,camera3Fourth1:icons$2.camera3Fourth1,cameraBack1:icons$2.cameraBack1,cameraFocusOnPath:icons$2.cameraFocusOnPath,cameraFocusOnVehicle1:icons$2.cameraFocusOnVehicle1,cameraFocusOnVehicle2:icons$2.cameraFocusOnVehicle2,cameraFocusTopDown:icons$2.cameraFocusTopDown,cameraFront1:icons$2.cameraFront1,cameraSideLeft:icons$2.cameraSideLeft,cameraSideLeft2:icons$2.cameraSideLeft2,cameraSideRight:icons$2.cameraSideRight,cameraSideRight2:icons$2.cameraSideRight2,cameraTop1:icons$2.cameraTop1,movieCamera:icons$2.movieCamera,pathAroundObstacle:icons$2.pathAroundObstacle,survellianceCamera:icons$2.survellianceCamera,pathDice:icons$2.pathDice},optical:{aperture:icons$2.aperture,survellianceCamera:icons$2.survellianceCamera},sensor:{aperture:icons$2.aperture,eyeWaves:icons$2.eyeWaves,flatBulbBeam:icons$2.flatBulbBeam,frontAxleMidpoint:icons$2.frontAxleMidpoint,frontBumperMidpoint:icons$2.frontBumperMidpoint,GPSMark:icons$2.GPSMark,GPSSolid:icons$2.GPSSolid,gyroscopeMicrochip:icons$2.gyroscopeMicrochip,gyroscope:icons$2.gyroscope,lidarPatternFullArcHighFreq:icons$2.lidarPatternFullArcHighFreq,lidarPatternFullArcMidFreq:icons$2.lidarPatternFullArcMidFreq,lidarPatternNarrowArc:icons$2.lidarPatternNarrowArc,lidar:icons$2.lidar,location1:icons$2.location1,location2:icons$2.location2,longRangeBeam1:icons$2.longRangeBeam1,longRangeBeam2:icons$2.longRangeBeam2,midRangeBeam1:icons$2.midRangeBeam1,midRangeBeam2:icons$2.midRangeBeam2,radarIdeal:icons$2.radarIdeal,radarRoundIdeal:icons$2.radarRoundIdeal,radarRound:icons$2.radarRound,radar:icons$2.radar,rearAxleMidpoint:icons$2.rearAxleMidpoint,rearBumperMidpoint:icons$2.rearBumperMidpoint,shortRangeBeam1:icons$2.shortRangeBeam1,shortRangeBeam2:icons$2.shortRangeBeam2,sphericalBeam:icons$2.sphericalBeam,survellianceCamera:icons$2.survellianceCamera,thinBulbBeam:icons$2.thinBulbBeam,thinnerBulbBeam:icons$2.thinnerBulbBeam,toCOMWithWheels:icons$2.toCOMWithWheels,toCOM:icons$2.toCOM,triangleBeam:icons$2.triangleBeam,tulipBeam:icons$2.tulipBeam,wavesSignalReceived:icons$2.wavesSignalReceived,wavesSignalSentLeft:icons$2.wavesSignalSentLeft,wavesSignalSentRight:icons$2.wavesSignalSentRight},arrow:{arrowLargeDown:icons$2.arrowLargeDown,arrowLargeLeft:icons$2.arrowLargeLeft,arrowLargeRight:icons$2.arrowLargeRight,arrowLargeUp:icons$2.arrowLargeUp,arrowSmallDown:icons$2.arrowSmallDown,arrowSmallLeft:icons$2.arrowSmallLeft,arrowSmallRight:icons$2.arrowSmallRight,arrowSmallUp:icons$2.arrowSmallUp,arrowSolidLeft:icons$2.arrowSolidLeft,arrowSolidRight:icons$2.arrowSolidRight,twoArrowsHorizontal:icons$2.twoArrowsHorizontal,twoArrowsVertical:icons$2.twoArrowsVertical,arrowsReplace:icons$2.arrowsReplace,arrowsShuffle:icons$2.arrowsShuffle,arrowsSwitch:icons$2.arrowsSwitch,seatArrowIn:icons$2.seatArrowIn,seatArrowOut:icons$2.seatArrowOut,seatVArrowIn:icons$2.seatVArrowIn,seatVArrowOut:icons$2.seatVArrowOut,vehicleArrowIn:icons$2.vehicleArrowIn,vehicleArrowOut:icons$2.vehicleArrowOut,seatArrowInLeft:icons$2.seatArrowInLeft,seatArrowOutLeft:icons$2.seatArrowOutLeft,seatVArrowInLeft:icons$2.seatVArrowInLeft,seatVArrowOutLeft:icons$2.seatVArrowOutLeft},large:{arrowLargeDown:icons$2.arrowLargeDown,arrowLargeLeft:icons$2.arrowLargeLeft,arrowLargeRight:icons$2.arrowLargeRight,arrowLargeUp:icons$2.arrowLargeUp,arrowSolidLeft:icons$2.arrowSolidLeft,arrowSolidRight:icons$2.arrowSolidRight,arrowLeftOutline:icons$2.arrowLeftOutline,arrowRightOutline:icons$2.arrowRightOutline,beamsNodesMessageOutline:icons$2.beamsNodesMessageOutline,beamsNodesOutline:icons$2.beamsNodesOutline,beamsNodesPlugOutline:icons$2.beamsNodesPlugOutline,BNGEcosystemOutline:icons$2.BNGEcosystemOutline,carFrontRouteOutline:icons$2.carFrontRouteOutline,carSensorsOutline:icons$2.carSensorsOutline,carSideRouteOutline:icons$2.carSideRouteOutline,cityOutline:icons$2.cityOutline,dialogOutline:icons$2.dialogOutline,documentSmileOutline:icons$2.documentSmileOutline,drivetrainOutline:icons$2.drivetrainOutline,electronicSchemeOutline:icons$2.electronicSchemeOutline,engineOutline:icons$2.engineOutline,gearTuningOutline:icons$2.gearTuningOutline,giftBoxOutline:icons$2.giftBoxOutline,lidarOutline:icons$2.lidarOutline,medalStarOutline:icons$2.medalStarOutline,megaphoneOutline:icons$2.megaphoneOutline,peopleOutline:icons$2.peopleOutline,personOutline:icons$2.personOutline,physicsOutline:icons$2.physicsOutline,playChainOutline:icons$2.playChainOutline,proximitySensorsOutline:icons$2.proximitySensorsOutline,qualityBadgeStarOutline:icons$2.qualityBadgeStarOutline,qualityBadgeVOutline:icons$2.qualityBadgeVOutline,simRigOutline:icons$2.simRigOutline,suspensionOutline:icons$2.suspensionOutline,teamOutline:icons$2.teamOutline,techLightBulbOutline01:icons$2.techLightBulbOutline01,techLightBulbOutline02:icons$2.techLightBulbOutline02,timeUnlockOutline:icons$2.timeUnlockOutline,timedLockOutline:icons$2.timedLockOutline,trafficOutline:icons$2.trafficOutline,voucherOutline:icons$2.voucherOutline,wheelBeamsNodesOutline:icons$2.wheelBeamsNodesOutline,wheelOutline:icons$2.wheelOutline,twoArrowsHorizontal:icons$2.twoArrowsHorizontal,twoArrowsVertical:icons$2.twoArrowsVertical},simple:{arrowLargeDown:icons$2.arrowLargeDown,arrowLargeLeft:icons$2.arrowLargeLeft,arrowLargeRight:icons$2.arrowLargeRight,arrowLargeUp:icons$2.arrowLargeUp,arrowSmallDown:icons$2.arrowSmallDown,arrowSmallLeft:icons$2.arrowSmallLeft,arrowSmallRight:icons$2.arrowSmallRight,arrowSmallUp:icons$2.arrowSmallUp},outlined:{arrowLargeDown:icons$2.arrowLargeDown,arrowLargeLeft:icons$2.arrowLargeLeft,arrowLargeRight:icons$2.arrowLargeRight,arrowLargeUp:icons$2.arrowLargeUp,arrowSmallDown:icons$2.arrowSmallDown,arrowSmallLeft:icons$2.arrowSmallLeft,arrowSmallRight:icons$2.arrowSmallRight,arrowSmallUp:icons$2.arrowSmallUp,roadMarkingOutline:icons$2.roadMarkingOutline,arrowLeftOutline:icons$2.arrowLeftOutline,arrowRightOutline:icons$2.arrowRightOutline,beamsNodesMessageOutline:icons$2.beamsNodesMessageOutline,beamsNodesOutline:icons$2.beamsNodesOutline,beamsNodesPlugOutline:icons$2.beamsNodesPlugOutline,BNGEcosystemOutline:icons$2.BNGEcosystemOutline,carFrontRouteOutline:icons$2.carFrontRouteOutline,carSensorsOutline:icons$2.carSensorsOutline,carSideRouteOutline:icons$2.carSideRouteOutline,cityOutline:icons$2.cityOutline,dialogOutline:icons$2.dialogOutline,documentSmileOutline:icons$2.documentSmileOutline,drivetrainOutline:icons$2.drivetrainOutline,electronicSchemeOutline:icons$2.electronicSchemeOutline,engineOutline:icons$2.engineOutline,gearTuningOutline:icons$2.gearTuningOutline,giftBoxOutline:icons$2.giftBoxOutline,lidarOutline:icons$2.lidarOutline,medalStarOutline:icons$2.medalStarOutline,megaphoneOutline:icons$2.megaphoneOutline,peopleOutline:icons$2.peopleOutline,personOutline:icons$2.personOutline,physicsOutline:icons$2.physicsOutline,playChainOutline:icons$2.playChainOutline,proximitySensorsOutline:icons$2.proximitySensorsOutline,qualityBadgeStarOutline:icons$2.qualityBadgeStarOutline,qualityBadgeVOutline:icons$2.qualityBadgeVOutline,simRigOutline:icons$2.simRigOutline,suspensionOutline:icons$2.suspensionOutline,teamOutline:icons$2.teamOutline,techLightBulbOutline01:icons$2.techLightBulbOutline01,techLightBulbOutline02:icons$2.techLightBulbOutline02,timeUnlockOutline:icons$2.timeUnlockOutline,timedLockOutline:icons$2.timedLockOutline,trafficOutline:icons$2.trafficOutline,voucherOutline:icons$2.voucherOutline,wheelBeamsNodesOutline:icons$2.wheelBeamsNodesOutline,wheelOutline:icons$2.wheelOutline},small:{arrowSmallDown:icons$2.arrowSmallDown,arrowSmallLeft:icons$2.arrowSmallLeft,arrowSmallRight:icons$2.arrowSmallRight,arrowSmallUp:icons$2.arrowSmallUp,mathDivide:icons$2.mathDivide,mathGreaterOrEqualThan:icons$2.mathGreaterOrEqualThan,mathGreaterThan:icons$2.mathGreaterThan,mathLessOrEqualThan:icons$2.mathLessOrEqualThan,mathLessThan:icons$2.mathLessThan,mathMinus:icons$2.mathMinus,mathMultiply:icons$2.mathMultiply,mathPlus:icons$2.mathPlus,slashLeft:icons$2.slashLeft,slashRight:icons$2.slashRight},solid:{arrowSolidLeft:icons$2.arrowSolidLeft,arrowSolidRight:icons$2.arrowSolidRight,twoArrowsHorizontal:icons$2.twoArrowsHorizontal,twoArrowsVertical:icons$2.twoArrowsVertical},detailed:{arrowSolidLeft:icons$2.arrowSolidLeft,arrowSolidRight:icons$2.arrowSolidRight},career:{banknotes:icons$2.banknotes,beamCurrency:icons$2.beamCurrency,beamXPFull:icons$2.beamXPFull,beamXPLo:icons$2.beamXPLo,carDealer:icons$2.carDealer,garage01:icons$2.garage01,garage02:icons$2.garage02,garage03:icons$2.garage03,lightGarageG11:icons$2.lightGarageG11,lightGarageG12:icons$2.lightGarageG12,lightGarageG13:icons$2.lightGarageG13,lightGarageG14:icons$2.lightGarageG14,lightGarageG21:icons$2.lightGarageG21,lightGarageG22:icons$2.lightGarageG22,lightGarageG23:icons$2.lightGarageG23,lightGarageG24:icons$2.lightGarageG24,lightGarageG31:icons$2.lightGarageG31,lightGarageG32:icons$2.lightGarageG32,lightGarageG33:icons$2.lightGarageG33,lightGarageG34:icons$2.lightGarageG34,plusGarage1:icons$2.plusGarage1,plusGarage2:icons$2.plusGarage2,plusGarage3:icons$2.plusGarage3,plusGarage4:icons$2.plusGarage4,voucherDiagonal1:icons$2.voucherDiagonal1,voucherDiagonal2:icons$2.voucherDiagonal2,voucherDiagonal3:icons$2.voucherDiagonal3,voucherHorizontal1:icons$2.voucherHorizontal1,voucherHorizontal2:icons$2.voucherHorizontal2,voucherHorizontal3:icons$2.voucherHorizontal3,garageNumber1:icons$2.garageNumber1,garageNumber2:icons$2.garageNumber2,garageNumber3:icons$2.garageNumber3,garageNumber4:icons$2.garageNumber4,garageNumber5:icons$2.garageNumber5,garageNumber6:icons$2.garageNumber6,garageNumber7:icons$2.garageNumber7,garageNumber8:icons$2.garageNumber8,garageNumber9:icons$2.garageNumber9,houseWrenchRoof:icons$2.houseWrenchRoof,houseWrench:icons$2.houseWrench,house:icons$2.house,beamCurrencyThin:icons$2.beamCurrencyThin},currencies:{banknotes:icons$2.banknotes,beamCurrency:icons$2.beamCurrency,beamXPFull:icons$2.beamXPFull,beamXPLo:icons$2.beamXPLo,beamCurrencyThin:icons$2.beamCurrencyThin},brand:{beamNG:icons$2.beamNG},beamng:{beamNG:icons$2.beamNG},decals:{booleanIntersect:icons$2.booleanIntersect,cameraFocusOnVehicle2:icons$2.cameraFocusOnVehicle2,copy:icons$2.copy,decal:icons$2.decal,deform:icons$2.deform,group:icons$2.group,material:icons$2.material,move:icons$2.move,order:icons$2.order,paperKnife:icons$2.paperKnife,redo:icons$2.redo,reflectNot:icons$2.reflectNot,reflect:icons$2.reflect,rename:icons$2.rename,sprayCan:icons$2.sprayCan,transform:icons$2.transform,transparencyMask:icons$2.transparencyMask,trashBin2:icons$2.trashBin2,undo:icons$2.undo,ungroup:icons$2.ungroup,view:icons$2.view,weight:icons$2.weight,scale:icons$2.scale,materialGlossy:icons$2.materialGlossy,materialMetal:icons$2.materialMetal,materialRoughness:icons$2.materialRoughness,materialTransparency01:icons$2.materialTransparency01,materialTransparency02:icons$2.materialTransparency02,surfaceRoughness02:icons$2.surfaceRoughness02,cameraFarClip:icons$2.cameraFarClip,cameraNearClip:icons$2.cameraNearClip,viewFarClip:icons$2.viewFarClip,viewNearClip:icons$2.viewNearClip},delivery:{boxDropOff01:icons$2.boxDropOff01,boxDropOff02:icons$2.boxDropOff02,boxDropOff03:icons$2.boxDropOff03,boxPickUp01:icons$2.boxPickUp01,boxPickUp02:icons$2.boxPickUp02,boxPickUp03:icons$2.boxPickUp03,boxPickUpDropOff01:icons$2.boxPickUpDropOff01,boxPickUpDropOff02:icons$2.boxPickUpDropOff02,boxTruck:icons$2.boxTruck,cardboardBox:icons$2.cardboardBox,deliveryTruckArrows:icons$2.deliveryTruckArrows,deliveryTruck:icons$2.deliveryTruck,flatbedTruck:icons$2.flatbedTruck,forklift:icons$2.forklift,fragile:icons$2.fragile,semiTrailer:icons$2.semiTrailer,semiTruckCabover:icons$2.semiTruckCabover,semiTruckUS:icons$2.semiTruckUS,semiTruck:icons$2.semiTruck,smallTrailer:icons$2.smallTrailer,stack3:icons$2.stack3,tankerTrailer:icons$2.tankerTrailer,thisSideUp:icons$2.thisSideUp,twoUnicyclesOnly:icons$2.twoUnicyclesOnly,boxTruckFast:icons$2.boxTruckFast,cardboardBoxCoins:icons$2.cardboardBoxCoins},cargo:{boxTruck:icons$2.boxTruck,flatbedTruck:icons$2.flatbedTruck,forklift:icons$2.forklift,fragile:icons$2.fragile,semiTrailer:icons$2.semiTrailer,semiTruckCabover:icons$2.semiTruckCabover,semiTruckUS:icons$2.semiTruckUS,semiTruck:icons$2.semiTruck,smallTrailer:icons$2.smallTrailer,stack3:icons$2.stack3,tankerTrailer:icons$2.tankerTrailer,thisSideUp:icons$2.thisSideUp,twoUnicyclesOnly:icons$2.twoUnicyclesOnly,boxTruckFast:icons$2.boxTruckFast},sound:{broom:icons$2.broom,soundFadeOut:icons$2.soundFadeOut,soundLimit:icons$2.soundLimit,soundLoud:icons$2.soundLoud,soundMonoL:icons$2.soundMonoL,soundMonoR:icons$2.soundMonoR,soundOff:icons$2.soundOff,soundQuiet:icons$2.soundQuiet,soundStereo:icons$2.soundStereo,soundWave01:icons$2.soundWave01,soundWave02:icons$2.soundWave02,trim:icons$2.trim},police:{carChase01:icons$2.carChase01,carsChase02:icons$2.carsChase02,evade:icons$2.evade,strobeLights:icons$2.strobeLights,wigwags:icons$2.wigwags},garage:{carDealer:icons$2.carDealer,garage01:icons$2.garage01,garage02:icons$2.garage02,garage03:icons$2.garage03,lightGarageG11:icons$2.lightGarageG11,lightGarageG12:icons$2.lightGarageG12,lightGarageG13:icons$2.lightGarageG13,lightGarageG14:icons$2.lightGarageG14,lightGarageG21:icons$2.lightGarageG21,lightGarageG22:icons$2.lightGarageG22,lightGarageG23:icons$2.lightGarageG23,lightGarageG24:icons$2.lightGarageG24,lightGarageG31:icons$2.lightGarageG31,lightGarageG32:icons$2.lightGarageG32,lightGarageG33:icons$2.lightGarageG33,lightGarageG34:icons$2.lightGarageG34,plusGarage1:icons$2.plusGarage1,plusGarage2:icons$2.plusGarage2,plusGarage3:icons$2.plusGarage3,plusGarage4:icons$2.plusGarage4,houseWrenchRoof:icons$2.houseWrenchRoof,houseWrench:icons$2.houseWrench,house:icons$2.house},sensors:{carSensors:icons$2.carSensors,carWithLidar:icons$2.carWithLidar,mapWithEmitter:icons$2.mapWithEmitter},tech:{carWithLidar:icons$2.carWithLidar,mapWithEmitter:icons$2.mapWithEmitter,mesh4Cells:icons$2.mesh4Cells,mesh9Cells:icons$2.mesh9Cells},fuel:{charge:icons$2.charge,charging:icons$2.charging,fuelPumpFilling:icons$2.fuelPumpFilling,fuelPump:icons$2.fuelPump,N2OButton:icons$2.N2OButton,N2OHoriz:icons$2.N2OHoriz,N2OVert:icons$2.N2OVert,discharging:icons$2.discharging},electricity:{charge:icons$2.charge,charging:icons$2.charging,discharging:icons$2.discharging},ev:{charge:icons$2.charge,charging:icons$2.charging,discharging:icons$2.discharging},checkbox:{checkboxOff:icons$2.checkboxOff,checkboxOn:icons$2.checkboxOn,missionCheckboxCross:icons$2.missionCheckboxCross},selection:{checkboxOff:icons$2.checkboxOff,checkboxOn:icons$2.checkboxOn,missionCheckboxCross:icons$2.missionCheckboxCross},box:{checkboxOff:icons$2.checkboxOff,checkboxOn:icons$2.checkboxOn,missionCheckboxCross:icons$2.missionCheckboxCross},movie:{clapperboard:icons$2.clapperboard},scenery:{clapperboard:icons$2.clapperboard},powertrain:{cogsDamaged:icons$2.cogsDamaged},drivetrain:{cogsDamaged:icons$2.cogsDamaged},data:{dataExchange:icons$2.dataExchange,eyeWaves:icons$2.eyeWaves,gyroscopeMicrochip:icons$2.gyroscopeMicrochip,gyroscope:icons$2.gyroscope,lidar:icons$2.lidar,radarIdeal:icons$2.radarIdeal,radarRoundIdeal:icons$2.radarRoundIdeal,radarRound:icons$2.radarRound,radar:icons$2.radar,wavesSignalReceived:icons$2.wavesSignalReceived,wavesSignalSentLeft:icons$2.wavesSignalSentLeft,wavesSignalSentRight:icons$2.wavesSignalSentRight},signal:{dataExchange:icons$2.dataExchange,eyeWaves:icons$2.eyeWaves,gyroscopeMicrochip:icons$2.gyroscopeMicrochip,gyroscope:icons$2.gyroscope,lidar:icons$2.lidar,radarIdeal:icons$2.radarIdeal,radarRoundIdeal:icons$2.radarRoundIdeal,radarRound:icons$2.radarRound,radar:icons$2.radar,wavesSignalReceived:icons$2.wavesSignalReceived,wavesSignalSentLeft:icons$2.wavesSignalSentLeft,wavesSignalSentRight:icons$2.wavesSignalSentRight},environment:{day:icons$2.day,night:icons$2.night,sunRise:icons$2.sunRise,weather:icons$2.weather,sunDown:icons$2.sunDown},part:{engine:icons$2.engine,suspension01:icons$2.suspension01,turbine:icons$2.turbine,doorFrontCoins:icons$2.doorFrontCoins,doorFront:icons$2.doorFront,engineCoins:icons$2.engineCoins,exhaustMufflerCoins:icons$2.exhaustMufflerCoins,exhaustMuffler:icons$2.exhaustMuffler,headlightCoins:icons$2.headlightCoins,headlight:icons$2.headlight,tire3FourthCoins:icons$2.tire3FourthCoins,tire3Fourth:icons$2.tire3Fourth,turbineCoins:icons$2.turbineCoins,wheelDiscCoins:icons$2.wheelDiscCoins,wheelDisc:icons$2.wheelDisc,doorFrontDetached:icons$2.doorFrontDetached,hingeBroken:icons$2.hingeBroken},mission:{evade:icons$2.evade,flagOutlineLarge:icons$2.flagOutlineLarge},playback:{fastBackward:icons$2.fastBackward,fastForward:icons$2.fastForward,music:icons$2.music,nextTrack:icons$2.nextTrack,pauseRound:icons$2.pauseRound,pause:icons$2.pause,playRound:icons$2.playRound,play:icons$2.play,playlist:icons$2.playlist,prevTrack:icons$2.prevTrack,square:icons$2.square,eject:icons$2.eject,playPause:icons$2.playPause},truck:{flatbedTruck:icons$2.flatbedTruck,semiTruckCabover:icons$2.semiTruckCabover,semiTruckUS:icons$2.semiTruckUS,semiTruck:icons$2.semiTruck},stencil:{forklift:icons$2.forklift,fragile:icons$2.fragile,stack3:icons$2.stack3,thisSideUp:icons$2.thisSideUp,twoUnicyclesOnly:icons$2.twoUnicyclesOnly},placement:{frontAxleMidpoint:icons$2.frontAxleMidpoint,frontBumperMidpoint:icons$2.frontBumperMidpoint,rearAxleMidpoint:icons$2.rearAxleMidpoint,rearBumperMidpoint:icons$2.rearBumperMidpoint,toCOMWithWheels:icons$2.toCOMWithWheels,toCOM:icons$2.toCOM},gamepad:{gamepadOld:icons$2.gamepadOld,gamepad:icons$2.gamepad,noNameControllerButton:icons$2.noNameControllerButton,xboxA:icons$2.xboxA,xboxB:icons$2.xboxB,xboxDDefaultOutline:icons$2.xboxDDefaultOutline,xboxDDefaultSolid:icons$2.xboxDDefaultSolid,xboxDDown:icons$2.xboxDDown,xboxDLeft:icons$2.xboxDLeft,xboxDRight:icons$2.xboxDRight,xboxDUp:icons$2.xboxDUp,xboxLB:icons$2.xboxLB,xboxLSButton:icons$2.xboxLSButton,xboxLT:icons$2.xboxLT,xboxMenu:icons$2.xboxMenu,xboxRB:icons$2.xboxRB,xboxRSButton:icons$2.xboxRSButton,xboxRT:icons$2.xboxRT,xboxThumbL:icons$2.xboxThumbL,xboxThumbR:icons$2.xboxThumbR,xboxView:icons$2.xboxView,xboxXAxis:icons$2.xboxXAxis,xboxXRot:icons$2.xboxXRot,xboxX:icons$2.xboxX,xboxYAxis:icons$2.xboxYAxis,xboxYRot:icons$2.xboxYRot,xboxY:icons$2.xboxY,psCircleOutline:icons$2.psCircleOutline,psCircle:icons$2.psCircle,psCreate2:icons$2.psCreate2,psCreate:icons$2.psCreate,psCrossOutline:icons$2.psCrossOutline,psCross:icons$2.psCross,psDDefaultOutline:icons$2.psDDefaultOutline,psDDefaultSolid:icons$2.psDDefaultSolid,psDDown:icons$2.psDDown,psDLeft:icons$2.psDLeft,psDRight:icons$2.psDRight,psDUp:icons$2.psDUp,psL1:icons$2.psL1,psL2:icons$2.psL2,psL3ButtonArrowDown:icons$2.psL3ButtonArrowDown,psL3Button:icons$2.psL3Button,psLSXLeft:icons$2.psLSXLeft,psLSXRight:icons$2.psLSXRight,psLSX:icons$2.psLSX,psLSYDown:icons$2.psLSYDown,psLSYUp:icons$2.psLSYUp,psLSY:icons$2.psLSY,psLS:icons$2.psLS,psMenu2:icons$2.psMenu2,psMenu:icons$2.psMenu,psR1:icons$2.psR1,psR2:icons$2.psR2,psR3ButtonArrowDown:icons$2.psR3ButtonArrowDown,psR3Button:icons$2.psR3Button,psRSXLeft:icons$2.psRSXLeft,psRSXRight:icons$2.psRSXRight,psRSX:icons$2.psRSX,psRSYDown:icons$2.psRSYDown,psRSYUp:icons$2.psRSYUp,psRSY:icons$2.psRSY,psRS:icons$2.psRS,psSquareOutline:icons$2.psSquareOutline,psSquare:icons$2.psSquare,psTrackpadNavigate:icons$2.psTrackpadNavigate,psTrackpadPressCenter:icons$2.psTrackpadPressCenter,psTrackpadPressLeft:icons$2.psTrackpadPressLeft,psTrackpadPressRight:icons$2.psTrackpadPressRight,psTrackpadSwipeDown:icons$2.psTrackpadSwipeDown,psTrackpadSwipeLeft:icons$2.psTrackpadSwipeLeft,psTrackpadSwipeRight:icons$2.psTrackpadSwipeRight,psTrackpadSwipeUp:icons$2.psTrackpadSwipeUp,psTriangleOutline:icons$2.psTriangleOutline,psTriangle:icons$2.psTriangle,xboxAOutline:icons$2.xboxAOutline,xboxBOutline:icons$2.xboxBOutline,xboxLSButtonArrowDown:icons$2.xboxLSButtonArrowDown,xboxRSButtonArrowDown:icons$2.xboxRSButtonArrowDown,xboxXAxisLeft:icons$2.xboxXAxisLeft,xboxXAxisRight:icons$2.xboxXAxisRight,xboxXOutline:icons$2.xboxXOutline,xboxXRotLeft:icons$2.xboxXRotLeft,xboxXRotRight:icons$2.xboxXRotRight,xboxYAxisDown:icons$2.xboxYAxisDown,xboxYAxisUp:icons$2.xboxYAxisUp,xboxYOutline:icons$2.xboxYOutline,xboxYRotDown:icons$2.xboxYRotDown,xboxYRotUp:icons$2.xboxYRotUp,psDLeftRight:icons$2.psDLeftRight,psDUpDown:icons$2.psDUpDown,xboxDLeftRight:icons$2.xboxDLeftRight,xboxDUpDown:icons$2.xboxDUpDown},controller:{gamepadOld:icons$2.gamepadOld,gamepad:icons$2.gamepad,noNameControllerButton:icons$2.noNameControllerButton,steeringWheelCommon:icons$2.steeringWheelCommon,steeringWheelSporty:icons$2.steeringWheelSporty,xboxA:icons$2.xboxA,xboxB:icons$2.xboxB,xboxDDefaultOutline:icons$2.xboxDDefaultOutline,xboxDDefaultSolid:icons$2.xboxDDefaultSolid,xboxDDown:icons$2.xboxDDown,xboxDLeft:icons$2.xboxDLeft,xboxDRight:icons$2.xboxDRight,xboxDUp:icons$2.xboxDUp,xboxLB:icons$2.xboxLB,xboxLSButton:icons$2.xboxLSButton,xboxLT:icons$2.xboxLT,xboxMenu:icons$2.xboxMenu,xboxRB:icons$2.xboxRB,xboxRSButton:icons$2.xboxRSButton,xboxRT:icons$2.xboxRT,xboxThumbL:icons$2.xboxThumbL,xboxThumbR:icons$2.xboxThumbR,xboxView:icons$2.xboxView,xboxXAxis:icons$2.xboxXAxis,xboxXRot:icons$2.xboxXRot,xboxX:icons$2.xboxX,xboxYAxis:icons$2.xboxYAxis,xboxYRot:icons$2.xboxYRot,xboxY:icons$2.xboxY,psCircleOutline:icons$2.psCircleOutline,psCircle:icons$2.psCircle,psCreate2:icons$2.psCreate2,psCreate:icons$2.psCreate,psCrossOutline:icons$2.psCrossOutline,psCross:icons$2.psCross,psDDefaultOutline:icons$2.psDDefaultOutline,psDDefaultSolid:icons$2.psDDefaultSolid,psDDown:icons$2.psDDown,psDLeft:icons$2.psDLeft,psDRight:icons$2.psDRight,psDUp:icons$2.psDUp,psL1:icons$2.psL1,psL2:icons$2.psL2,psL3ButtonArrowDown:icons$2.psL3ButtonArrowDown,psL3Button:icons$2.psL3Button,psLSXLeft:icons$2.psLSXLeft,psLSXRight:icons$2.psLSXRight,psLSX:icons$2.psLSX,psLSYDown:icons$2.psLSYDown,psLSYUp:icons$2.psLSYUp,psLSY:icons$2.psLSY,psLS:icons$2.psLS,psMenu2:icons$2.psMenu2,psMenu:icons$2.psMenu,psR1:icons$2.psR1,psR2:icons$2.psR2,psR3ButtonArrowDown:icons$2.psR3ButtonArrowDown,psR3Button:icons$2.psR3Button,psRSXLeft:icons$2.psRSXLeft,psRSXRight:icons$2.psRSXRight,psRSX:icons$2.psRSX,psRSYDown:icons$2.psRSYDown,psRSYUp:icons$2.psRSYUp,psRSY:icons$2.psRSY,psRS:icons$2.psRS,psSquareOutline:icons$2.psSquareOutline,psSquare:icons$2.psSquare,psTrackpadNavigate:icons$2.psTrackpadNavigate,psTrackpadPressCenter:icons$2.psTrackpadPressCenter,psTrackpadPressLeft:icons$2.psTrackpadPressLeft,psTrackpadPressRight:icons$2.psTrackpadPressRight,psTrackpadSwipeDown:icons$2.psTrackpadSwipeDown,psTrackpadSwipeLeft:icons$2.psTrackpadSwipeLeft,psTrackpadSwipeRight:icons$2.psTrackpadSwipeRight,psTrackpadSwipeUp:icons$2.psTrackpadSwipeUp,psTriangleOutline:icons$2.psTriangleOutline,psTriangle:icons$2.psTriangle,xboxAOutline:icons$2.xboxAOutline,xboxBOutline:icons$2.xboxBOutline,xboxLSButtonArrowDown:icons$2.xboxLSButtonArrowDown,xboxRSButtonArrowDown:icons$2.xboxRSButtonArrowDown,xboxXAxisLeft:icons$2.xboxXAxisLeft,xboxXAxisRight:icons$2.xboxXAxisRight,xboxXOutline:icons$2.xboxXOutline,xboxXRotLeft:icons$2.xboxXRotLeft,xboxXRotRight:icons$2.xboxXRotRight,xboxYAxisDown:icons$2.xboxYAxisDown,xboxYAxisUp:icons$2.xboxYAxisUp,xboxYOutline:icons$2.xboxYOutline,xboxYRotDown:icons$2.xboxYRotDown,xboxYRotUp:icons$2.xboxYRotUp,psDLeftRight:icons$2.psDLeftRight,psDUpDown:icons$2.psDUpDown,xboxDLeftRight:icons$2.xboxDLeftRight,xboxDUpDown:icons$2.xboxDUpDown},input:{gamepadOld:icons$2.gamepadOld,gamepad:icons$2.gamepad,keyboard:icons$2.keyboard,mouseLMB:icons$2.mouseLMB,mouseMMB:icons$2.mouseMMB,mouseRMB:icons$2.mouseRMB,mouseWheel:icons$2.mouseWheel,mouseXAxis:icons$2.mouseXAxis,mouseXYAxis:icons$2.mouseXYAxis,mouseYAxis:icons$2.mouseYAxis,mouse:icons$2.mouse,noNameControllerButton:icons$2.noNameControllerButton,palmCrossed:icons$2.palmCrossed,smartphone1:icons$2.smartphone1,smartphone2:icons$2.smartphone2,steeringWheelCommon:icons$2.steeringWheelCommon,steeringWheelSporty:icons$2.steeringWheelSporty,touch:icons$2.touch,xboxA:icons$2.xboxA,xboxB:icons$2.xboxB,xboxDDefaultOutline:icons$2.xboxDDefaultOutline,xboxDDefaultSolid:icons$2.xboxDDefaultSolid,xboxDDown:icons$2.xboxDDown,xboxDLeft:icons$2.xboxDLeft,xboxDRight:icons$2.xboxDRight,xboxDUp:icons$2.xboxDUp,xboxLB:icons$2.xboxLB,xboxLSButton:icons$2.xboxLSButton,xboxLT:icons$2.xboxLT,xboxMenu:icons$2.xboxMenu,xboxRB:icons$2.xboxRB,xboxRSButton:icons$2.xboxRSButton,xboxRT:icons$2.xboxRT,xboxThumbL:icons$2.xboxThumbL,xboxThumbR:icons$2.xboxThumbR,xboxView:icons$2.xboxView,xboxXAxis:icons$2.xboxXAxis,xboxXRot:icons$2.xboxXRot,xboxX:icons$2.xboxX,xboxYAxis:icons$2.xboxYAxis,xboxYRot:icons$2.xboxYRot,xboxY:icons$2.xboxY,psCircleOutline:icons$2.psCircleOutline,psCircle:icons$2.psCircle,psCreate2:icons$2.psCreate2,psCreate:icons$2.psCreate,psCrossOutline:icons$2.psCrossOutline,psCross:icons$2.psCross,psDDefaultOutline:icons$2.psDDefaultOutline,psDDefaultSolid:icons$2.psDDefaultSolid,psDDown:icons$2.psDDown,psDLeft:icons$2.psDLeft,psDRight:icons$2.psDRight,psDUp:icons$2.psDUp,psL1:icons$2.psL1,psL2:icons$2.psL2,psL3ButtonArrowDown:icons$2.psL3ButtonArrowDown,psL3Button:icons$2.psL3Button,psLSXLeft:icons$2.psLSXLeft,psLSXRight:icons$2.psLSXRight,psLSX:icons$2.psLSX,psLSYDown:icons$2.psLSYDown,psLSYUp:icons$2.psLSYUp,psLSY:icons$2.psLSY,psLS:icons$2.psLS,psMenu2:icons$2.psMenu2,psMenu:icons$2.psMenu,psR1:icons$2.psR1,psR2:icons$2.psR2,psR3ButtonArrowDown:icons$2.psR3ButtonArrowDown,psR3Button:icons$2.psR3Button,psRSXLeft:icons$2.psRSXLeft,psRSXRight:icons$2.psRSXRight,psRSX:icons$2.psRSX,psRSYDown:icons$2.psRSYDown,psRSYUp:icons$2.psRSYUp,psRSY:icons$2.psRSY,psRS:icons$2.psRS,psSquareOutline:icons$2.psSquareOutline,psSquare:icons$2.psSquare,psTrackpadNavigate:icons$2.psTrackpadNavigate,psTrackpadPressCenter:icons$2.psTrackpadPressCenter,psTrackpadPressLeft:icons$2.psTrackpadPressLeft,psTrackpadPressRight:icons$2.psTrackpadPressRight,psTrackpadSwipeDown:icons$2.psTrackpadSwipeDown,psTrackpadSwipeLeft:icons$2.psTrackpadSwipeLeft,psTrackpadSwipeRight:icons$2.psTrackpadSwipeRight,psTrackpadSwipeUp:icons$2.psTrackpadSwipeUp,psTriangleOutline:icons$2.psTriangleOutline,psTriangle:icons$2.psTriangle,xboxAOutline:icons$2.xboxAOutline,xboxBOutline:icons$2.xboxBOutline,xboxLSButtonArrowDown:icons$2.xboxLSButtonArrowDown,xboxRSButtonArrowDown:icons$2.xboxRSButtonArrowDown,xboxXAxisLeft:icons$2.xboxXAxisLeft,xboxXAxisRight:icons$2.xboxXAxisRight,xboxXOutline:icons$2.xboxXOutline,xboxXRotLeft:icons$2.xboxXRotLeft,xboxXRotRight:icons$2.xboxXRotRight,xboxYAxisDown:icons$2.xboxYAxisDown,xboxYAxisUp:icons$2.xboxYAxisUp,xboxYOutline:icons$2.xboxYOutline,xboxYRotDown:icons$2.xboxYRotDown,xboxYRotUp:icons$2.xboxYRotUp,psDLeftRight:icons$2.psDLeftRight,psDUpDown:icons$2.psDUpDown,xboxDLeftRight:icons$2.xboxDLeftRight,xboxDUpDown:icons$2.xboxDUpDown},gps:{GPSMark:icons$2.GPSMark,GPSSolid:icons$2.GPSSolid,location1:icons$2.location1,location2:icons$2.location2},position:{GPSMark:icons$2.GPSMark,GPSSolid:icons$2.GPSSolid,location1:icons$2.location1,location2:icons$2.location2},map:{GPSMark:icons$2.GPSMark,GPSSolid:icons$2.GPSSolid,location1:icons$2.location1,location2:icons$2.location2},keyboard:{keyboard:icons$2.keyboard,kbArrowsDown:icons$2.kbArrowsDown,kbArrowsLeftRight:icons$2.kbArrowsLeftRight,kbArrowsLeft:icons$2.kbArrowsLeft,kbArrowsOutline:icons$2.kbArrowsOutline,kbArrowsRight:icons$2.kbArrowsRight,kbArrowsSolid:icons$2.kbArrowsSolid,kbArrowsUpDown:icons$2.kbArrowsUpDown,kbArrowsUp:icons$2.kbArrowsUp},lights:{lightGarageG11:icons$2.lightGarageG11,lightGarageG12:icons$2.lightGarageG12,lightGarageG13:icons$2.lightGarageG13,lightGarageG14:icons$2.lightGarageG14,lightGarageG21:icons$2.lightGarageG21,lightGarageG22:icons$2.lightGarageG22,lightGarageG23:icons$2.lightGarageG23,lightGarageG24:icons$2.lightGarageG24,lightGarageG31:icons$2.lightGarageG31,lightGarageG32:icons$2.lightGarageG32,lightGarageG33:icons$2.lightGarageG33,lightGarageG34:icons$2.lightGarageG34},catalog:{listBig:icons$2.listBig,listSmall:icons$2.listSmall,tiles:icons$2.tiles},selector:{listBig:icons$2.listBig,listSmall:icons$2.listSmall,tiles:icons$2.tiles},view:{listBig:icons$2.listBig,listSmall:icons$2.listSmall,tiles:icons$2.tiles},math:{mathDivide:icons$2.mathDivide,mathGreaterOrEqualThan:icons$2.mathGreaterOrEqualThan,mathGreaterThan:icons$2.mathGreaterThan,mathLessOrEqualThan:icons$2.mathLessOrEqualThan,mathLessThan:icons$2.mathLessThan,mathMinus:icons$2.mathMinus,mathMultiply:icons$2.mathMultiply,mathPlus:icons$2.mathPlus,slashLeft:icons$2.slashLeft,slashRight:icons$2.slashRight},operands:{mathDivide:icons$2.mathDivide,mathGreaterOrEqualThan:icons$2.mathGreaterOrEqualThan,mathGreaterThan:icons$2.mathGreaterThan,mathLessOrEqualThan:icons$2.mathLessOrEqualThan,mathLessThan:icons$2.mathLessThan,mathMinus:icons$2.mathMinus,mathMultiply:icons$2.mathMultiply,mathPlus:icons$2.mathPlus,slashLeft:icons$2.slashLeft,slashRight:icons$2.slashRight},reward:{medal:icons$2.medal,voucherDiagonal1:icons$2.voucherDiagonal1,voucherDiagonal2:icons$2.voucherDiagonal2,voucherDiagonal3:icons$2.voucherDiagonal3,voucherHorizontal1:icons$2.voucherHorizontal1,voucherHorizontal2:icons$2.voucherHorizontal2,voucherHorizontal3:icons$2.voucherHorizontal3,medalEmpty:icons$2.medalEmpty,medalStar:icons$2.medalStar,badgeRoundEmpty:icons$2.badgeRoundEmpty,badgeRoundStar:icons$2.badgeRoundStar,badgeRound:icons$2.badgeRound,badge:icons$2.badge},achievment:{medal:icons$2.medal,medalEmpty:icons$2.medalEmpty,medalStar:icons$2.medalStar,badgeRoundEmpty:icons$2.badgeRoundEmpty,badgeRoundStar:icons$2.badgeRoundStar,badgeRound:icons$2.badgeRound,badge:icons$2.badge},mesh:{mesh4Cells:icons$2.mesh4Cells,mesh9Cells:icons$2.mesh9Cells},beams:{mesh4Cells:icons$2.mesh4Cells,mesh9Cells:icons$2.mesh9Cells},nodes:{mesh4Cells:icons$2.mesh4Cells,mesh9Cells:icons$2.mesh9Cells},surface:{mesh4Cells:icons$2.mesh4Cells,mesh9Cells:icons$2.mesh9Cells,bridge:icons$2.bridge,bump:icons$2.bump,bumps:icons$2.bumps,caution:icons$2.caution,crest:icons$2.crest,doubleCaution:icons$2.doubleCaution,finish:icons$2.finish,jumpOverBump:icons$2.jumpOverBump,narrows:icons$2.narrows,pothole:icons$2.pothole,turn1:icons$2.turn1,turn2:icons$2.turn2,turn3:icons$2.turn3,turn4:icons$2.turn4,turn5:icons$2.turn5,turn6:icons$2.turn6,turnHp:icons$2.turnHp,turnSq:icons$2.turnSq,water:icons$2.water,tripleCaution:icons$2.tripleCaution},mirror:{mirrorInteriorMiddle:icons$2.mirrorInteriorMiddle,mirrorLeftBigBottomWideAngle:icons$2.mirrorLeftBigBottomWideAngle,mirrorLeftBigTop:icons$2.mirrorLeftBigTop,mirrorLeftBig:icons$2.mirrorLeftBig,mirrorLeftBonnet:icons$2.mirrorLeftBonnet,mirrorLeftDefault:icons$2.mirrorLeftDefault,mirrorRightBigBottomWideAngle:icons$2.mirrorRightBigBottomWideAngle,mirrorRightBigTop:icons$2.mirrorRightBigTop,mirrorRightBig:icons$2.mirrorRightBig,mirrorRightBonnet:icons$2.mirrorRightBonnet,mirrorRightDefault:icons$2.mirrorRightDefault,mirrorRoundWideAngle:icons$2.mirrorRoundWideAngle,mirrorTopWideAngle:icons$2.mirrorTopWideAngle},rearview:{mirrorInteriorMiddle:icons$2.mirrorInteriorMiddle,mirrorLeftBigBottomWideAngle:icons$2.mirrorLeftBigBottomWideAngle,mirrorLeftBigTop:icons$2.mirrorLeftBigTop,mirrorLeftBig:icons$2.mirrorLeftBig,mirrorLeftBonnet:icons$2.mirrorLeftBonnet,mirrorLeftDefault:icons$2.mirrorLeftDefault,mirrorRightBigBottomWideAngle:icons$2.mirrorRightBigBottomWideAngle,mirrorRightBigTop:icons$2.mirrorRightBigTop,mirrorRightBig:icons$2.mirrorRightBig,mirrorRightBonnet:icons$2.mirrorRightBonnet,mirrorRightDefault:icons$2.mirrorRightDefault,mirrorRoundWideAngle:icons$2.mirrorRoundWideAngle,mirrorTopWideAngle:icons$2.mirrorTopWideAngle},mouse:{mouseLMB:icons$2.mouseLMB,mouseMMB:icons$2.mouseMMB,mouseRMB:icons$2.mouseRMB,mouseWheel:icons$2.mouseWheel,mouseXAxis:icons$2.mouseXAxis,mouseXYAxis:icons$2.mouseXYAxis,mouseYAxis:icons$2.mouseYAxis,mouse:icons$2.mouse},path:{nodeAddFirst01:icons$2.nodeAddFirst01,nodeAddFirst02:icons$2.nodeAddFirst02,nodeAddLast02:icons$2.nodeAddLast02,nodeAddMiddle01:icons$2.nodeAddMiddle01,nodeAddMiddle02:icons$2.nodeAddMiddle02,nodeAdd:icons$2.nodeAdd,nodeLast01:icons$2.nodeLast01,nodeRemove:icons$2.nodeRemove,locationDestination:icons$2.locationDestination,locationSource:icons$2.locationSource},node:{nodeAddFirst01:icons$2.nodeAddFirst01,nodeAddFirst02:icons$2.nodeAddFirst02,nodeAddLast02:icons$2.nodeAddLast02,nodeAddMiddle01:icons$2.nodeAddMiddle01,nodeAddMiddle02:icons$2.nodeAddMiddle02,nodeAdd:icons$2.nodeAdd,nodeLast01:icons$2.nodeLast01,nodeRemove:icons$2.nodeRemove,locationDestination:icons$2.locationDestination,locationSource:icons$2.locationSource},touch:{palmCrossed:icons$2.palmCrossed,smartphone1:icons$2.smartphone1,smartphone2:icons$2.smartphone2,touch:icons$2.touch},route:{routeAdd:icons$2.routeAdd,routeComplex:icons$2.routeComplex,routeSimple:icons$2.routeSimple,trafficCone:icons$2.trafficCone,locationDestination:icons$2.locationDestination,locationSource:icons$2.locationSource,routeSimpleFlag:icons$2.routeSimpleFlag},traffic:{routeAdd:icons$2.routeAdd,routeComplex:icons$2.routeComplex,routeSimple:icons$2.routeSimple,trafficCone:icons$2.trafficCone,trafficLight:icons$2.trafficLight,pedestrianRunning:icons$2.pedestrianRunning,pedestrianStanding:icons$2.pedestrianStanding,routeSimpleFlag:icons$2.routeSimpleFlag},trailer:{semiTrailer:icons$2.semiTrailer,semiTruck:icons$2.semiTruck,smallTrailer:icons$2.smallTrailer,tankerTrailer:icons$2.tankerTrailer},steering:{steeringWheelCommon:icons$2.steeringWheelCommon,steeringWheelSporty:icons$2.steeringWheelSporty},time:{stopwatchArrows01:icons$2.stopwatchArrows01,stopwatchArrows02:icons$2.stopwatchArrows02,stopwatchSectionOutlinedEnd:icons$2.stopwatchSectionOutlinedEnd,stopwatchSectionOutlinedStart:icons$2.stopwatchSectionOutlinedStart,stopwatchSectionSolidEnd:icons$2.stopwatchSectionSolidEnd,stopwatchSectionSolidStart:icons$2.stopwatchSectionSolidStart,timer:icons$2.timer},fast:{stopwatchArrows01:icons$2.stopwatchArrows01,stopwatchArrows02:icons$2.stopwatchArrows02,stopwatchSectionOutlinedEnd:icons$2.stopwatchSectionOutlinedEnd,stopwatchSectionOutlinedStart:icons$2.stopwatchSectionOutlinedStart,stopwatchSectionSolidEnd:icons$2.stopwatchSectionSolidEnd,stopwatchSectionSolidStart:icons$2.stopwatchSectionSolidStart,timer:icons$2.timer},emergency:{strobeLights:icons$2.strobeLights,wigwags:icons$2.wigwags},circuit:{switchBlock:icons$2.switchBlock,switchOutline:icons$2.switchOutline},electronics:{switchBlock:icons$2.switchBlock,switchOutline:icons$2.switchOutline},switch:{switchBlock:icons$2.switchBlock,switchOutline:icons$2.switchOutline},tank:{tankerTrailer:icons$2.tankerTrailer},tanker:{tankerTrailer:icons$2.tankerTrailer},taxi:{taxiCar1:icons$2.taxiCar1,taxiCar3:icons$2.taxiCar3,taxiCarT:icons$2.taxiCarT,taxiCheckerLamp:icons$2.taxiCheckerLamp},tire:{tireDirection3Fourth2:icons$2.tireDirection3Fourth2,tireDirection3Fourth3:icons$2.tireDirection3Fourth3,tireDirectionFront2:icons$2.tireDirectionFront2,tireDirectionSide2:icons$2.tireDirectionSide2,tireDirectionTop2:icons$2.tireDirectionTop2,tire3FourthCoins:icons$2.tire3FourthCoins,tire3Fourth:icons$2.tire3Fourth},currency:{voucherDiagonal1:icons$2.voucherDiagonal1,voucherDiagonal2:icons$2.voucherDiagonal2,voucherDiagonal3:icons$2.voucherDiagonal3,voucherHorizontal1:icons$2.voucherHorizontal1,voucherHorizontal2:icons$2.voucherHorizontal2,voucherHorizontal3:icons$2.voucherHorizontal3,beamCurrencyOutlineLarge:icons$2.beamCurrencyOutlineLarge},extra:{AIL:icons$2.AIL,automaticTransmissionL:icons$2.automaticTransmissionL,chargeLL:icons$2.chargeLL,clutchL:icons$2.clutchL,couplerL:icons$2.couplerL,engineL:icons$2.engineL,multiseatL:icons$2.multiseatL,POITimeL:icons$2.POITimeL,replayL:icons$2.replayL,roadblockL:icons$2.roadblockL,rotationL:icons$2.rotationL,sensorsL:icons$2.sensorsL,temperatureL:icons$2.temperatureL,tuningL:icons$2.tuningL,turbineL:icons$2.turbineL},web:{arrowLeftOutline:icons$2.arrowLeftOutline,arrowRightOutline:icons$2.arrowRightOutline,beamsNodesMessageOutline:icons$2.beamsNodesMessageOutline,beamsNodesOutline:icons$2.beamsNodesOutline,beamsNodesPlugOutline:icons$2.beamsNodesPlugOutline,BNGEcosystemOutline:icons$2.BNGEcosystemOutline,carFrontRouteOutline:icons$2.carFrontRouteOutline,carSensorsOutline:icons$2.carSensorsOutline,carSideRouteOutline:icons$2.carSideRouteOutline,cityOutline:icons$2.cityOutline,dialogOutline:icons$2.dialogOutline,documentSmileOutline:icons$2.documentSmileOutline,drivetrainOutline:icons$2.drivetrainOutline,electronicSchemeOutline:icons$2.electronicSchemeOutline,engineOutline:icons$2.engineOutline,gearTuningOutline:icons$2.gearTuningOutline,giftBoxOutline:icons$2.giftBoxOutline,lidarOutline:icons$2.lidarOutline,medalStarOutline:icons$2.medalStarOutline,megaphoneOutline:icons$2.megaphoneOutline,peopleOutline:icons$2.peopleOutline,personOutline:icons$2.personOutline,physicsOutline:icons$2.physicsOutline,playChainOutline:icons$2.playChainOutline,proximitySensorsOutline:icons$2.proximitySensorsOutline,qualityBadgeStarOutline:icons$2.qualityBadgeStarOutline,qualityBadgeVOutline:icons$2.qualityBadgeVOutline,simRigOutline:icons$2.simRigOutline,suspensionOutline:icons$2.suspensionOutline,teamOutline:icons$2.teamOutline,techLightBulbOutline01:icons$2.techLightBulbOutline01,techLightBulbOutline02:icons$2.techLightBulbOutline02,timeUnlockOutline:icons$2.timeUnlockOutline,timedLockOutline:icons$2.timedLockOutline,trafficOutline:icons$2.trafficOutline,voucherOutline:icons$2.voucherOutline,wheelBeamsNodesOutline:icons$2.wheelBeamsNodesOutline,wheelOutline:icons$2.wheelOutline},secondary:{arrowLeftOutline:icons$2.arrowLeftOutline,arrowRightOutline:icons$2.arrowRightOutline,beamsNodesMessageOutline:icons$2.beamsNodesMessageOutline,beamsNodesOutline:icons$2.beamsNodesOutline,beamsNodesPlugOutline:icons$2.beamsNodesPlugOutline,BNGEcosystemOutline:icons$2.BNGEcosystemOutline,carFrontRouteOutline:icons$2.carFrontRouteOutline,carSensorsOutline:icons$2.carSensorsOutline,carSideRouteOutline:icons$2.carSideRouteOutline,cityOutline:icons$2.cityOutline,dialogOutline:icons$2.dialogOutline,documentSmileOutline:icons$2.documentSmileOutline,drivetrainOutline:icons$2.drivetrainOutline,electronicSchemeOutline:icons$2.electronicSchemeOutline,engineOutline:icons$2.engineOutline,gearTuningOutline:icons$2.gearTuningOutline,giftBoxOutline:icons$2.giftBoxOutline,lidarOutline:icons$2.lidarOutline,medalStarOutline:icons$2.medalStarOutline,megaphoneOutline:icons$2.megaphoneOutline,peopleOutline:icons$2.peopleOutline,personOutline:icons$2.personOutline,physicsOutline:icons$2.physicsOutline,playChainOutline:icons$2.playChainOutline,proximitySensorsOutline:icons$2.proximitySensorsOutline,qualityBadgeStarOutline:icons$2.qualityBadgeStarOutline,qualityBadgeVOutline:icons$2.qualityBadgeVOutline,simRigOutline:icons$2.simRigOutline,suspensionOutline:icons$2.suspensionOutline,teamOutline:icons$2.teamOutline,techLightBulbOutline01:icons$2.techLightBulbOutline01,techLightBulbOutline02:icons$2.techLightBulbOutline02,timeUnlockOutline:icons$2.timeUnlockOutline,timedLockOutline:icons$2.timedLockOutline,trafficOutline:icons$2.trafficOutline,voucherOutline:icons$2.voucherOutline,wheelBeamsNodesOutline:icons$2.wheelBeamsNodesOutline,wheelOutline:icons$2.wheelOutline},hazard:{danger:icons$2.danger,fireDiamond:icons$2.fireDiamond,test:icons$2.test},drop:{droplet:icons$2.droplet},liquid:{droplet:icons$2.droplet},nfpa704:{fireDiamond:icons$2.fireDiamond},"dry cargo":{rocks:icons$2.rocks},dry:{rocks:icons$2.rocks},editor:{scale:icons$2.scale},marker:{arrowsUp:icons$2.arrowsUp,bigDot:icons$2.bigDot,connectorBold:icons$2.connectorBold,cornerTopRight:icons$2.cornerTopRight,plusBold:icons$2.plusBold,puzzlePieceBold:icons$2.puzzlePieceBold},ribbon:{arrowsUp:icons$2.arrowsUp,bigDot:icons$2.bigDot,connectorBold:icons$2.connectorBold,cornerTopRight:icons$2.cornerTopRight,plusBold:icons$2.plusBold,puzzlePieceBold:icons$2.puzzlePieceBold},"content-props":{arrowsUp:icons$2.arrowsUp,bigDot:icons$2.bigDot,connectorBold:icons$2.connectorBold,cornerTopRight:icons$2.cornerTopRight,plusBold:icons$2.plusBold,puzzlePieceBold:icons$2.puzzlePieceBold},location:{locationDestination:icons$2.locationDestination,locationSource:icons$2.locationSource},shop:{shoppingCart:icons$2.shoppingCart},purchase:{shoppingCart:icons$2.shoppingCart},bus:{busTilted:icons$2.busTilted},destruction:{explosion:icons$2.explosion,fireExtinguisher:icons$2.fireExtinguisher,fire:icons$2.fire},"turn signals":{twoArrowsHorizontal:icons$2.twoArrowsHorizontal,twoArrowsVertical:icons$2.twoArrowsVertical},rally:{bridge:icons$2.bridge,bump:icons$2.bump,bumps:icons$2.bumps,caution:icons$2.caution,crest:icons$2.crest,doubleCaution:icons$2.doubleCaution,finish:icons$2.finish,jumpOverBump:icons$2.jumpOverBump,narrows:icons$2.narrows,pothole:icons$2.pothole,turn1:icons$2.turn1,turn2:icons$2.turn2,turn3:icons$2.turn3,turn4:icons$2.turn4,turn5:icons$2.turn5,turn6:icons$2.turn6,turnHp:icons$2.turnHp,turnSq:icons$2.turnSq,water:icons$2.water,rallyHelmet3To4:icons$2.rallyHelmet3To4,rallyHelmet:icons$2.rallyHelmet,tripleCaution:icons$2.tripleCaution},"pace notes":{bridge:icons$2.bridge,bump:icons$2.bump,bumps:icons$2.bumps,caution:icons$2.caution,crest:icons$2.crest,doubleCaution:icons$2.doubleCaution,finish:icons$2.finish,jumpOverBump:icons$2.jumpOverBump,narrows:icons$2.narrows,pothole:icons$2.pothole,turn1:icons$2.turn1,turn2:icons$2.turn2,turn3:icons$2.turn3,turn4:icons$2.turn4,turn5:icons$2.turn5,turn6:icons$2.turn6,turnHp:icons$2.turnHp,turnSq:icons$2.turnSq,water:icons$2.water,tripleCaution:icons$2.tripleCaution},directions:{bridge:icons$2.bridge,bump:icons$2.bump,bumps:icons$2.bumps,caution:icons$2.caution,crest:icons$2.crest,doubleCaution:icons$2.doubleCaution,finish:icons$2.finish,jumpOverBump:icons$2.jumpOverBump,narrows:icons$2.narrows,pothole:icons$2.pothole,turn1:icons$2.turn1,turn2:icons$2.turn2,turn3:icons$2.turn3,turn4:icons$2.turn4,turn5:icons$2.turn5,turn6:icons$2.turn6,turnHp:icons$2.turnHp,turnSq:icons$2.turnSq,water:icons$2.water,tripleCaution:icons$2.tripleCaution},"do not cut":{circleSlashed:icons$2.circleSlashed,scissorsSlashed:icons$2.scissorsSlashed},"no entry":{circleSlashed:icons$2.circleSlashed},cut:{scissors:icons$2.scissors},car:{airPuffRight1:icons$2.airPuffRight1,octagonBrick:icons$2.octagonBrick,octagon:icons$2.octagon,tireAirPuff:icons$2.tireAirPuff,tireDeflated:icons$2.tireDeflated},select:{carsChange:icons$2.carsChange,carsWrench:icons$2.carsWrench},physics:{forceFieldPull1:icons$2.forceFieldPull1,forceFieldPull2:icons$2.forceFieldPull2,forceFieldPull3:icons$2.forceFieldPull3,forceFieldPush1:icons$2.forceFieldPush1,forceFieldPush2:icons$2.forceFieldPush2,forceFieldPush3:icons$2.forceFieldPush3,pushUp:icons$2.pushUp,pushBackward:icons$2.pushBackward,pushDown:icons$2.pushDown,pushForward:icons$2.pushForward},field:{forceFieldPull1:icons$2.forceFieldPull1,forceFieldPull2:icons$2.forceFieldPull2,forceFieldPull3:icons$2.forceFieldPull3,forceFieldPush1:icons$2.forceFieldPush1,forceFieldPush2:icons$2.forceFieldPush2,forceFieldPush3:icons$2.forceFieldPush3},force:{forceFieldPull1:icons$2.forceFieldPull1,forceFieldPull2:icons$2.forceFieldPull2,forceFieldPull3:icons$2.forceFieldPull3,forceFieldPush1:icons$2.forceFieldPush1,forceFieldPush2:icons$2.forceFieldPush2,forceFieldPush3:icons$2.forceFieldPush3,pushUp:icons$2.pushUp,pushBackward:icons$2.pushBackward,pushDown:icons$2.pushDown,pushForward:icons$2.pushForward},"garage number":{garageNumber1:icons$2.garageNumber1,garageNumber2:icons$2.garageNumber2,garageNumber3:icons$2.garageNumber3,garageNumber4:icons$2.garageNumber4,garageNumber5:icons$2.garageNumber5,garageNumber6:icons$2.garageNumber6,garageNumber7:icons$2.garageNumber7,garageNumber8:icons$2.garageNumber8,garageNumber9:icons$2.garageNumber9},stop:{square:icons$2.square},roads:{trafficLight:icons$2.trafficLight},sign:{pedestrianRunning:icons$2.pedestrianRunning,pedestrianStanding:icons$2.pedestrianStanding},pedestrian:{pedestrianRunning:icons$2.pedestrianRunning,pedestrianStanding:icons$2.pedestrianStanding},actions:{seatArrowIn:icons$2.seatArrowIn,seatArrowOut:icons$2.seatArrowOut,seatVArrowIn:icons$2.seatVArrowIn,seatVArrowOut:icons$2.seatVArrowOut,vehicleArrowIn:icons$2.vehicleArrowIn,vehicleArrowOut:icons$2.vehicleArrowOut,leverFrontOperate:icons$2.leverFrontOperate,leverSideDown:icons$2.leverSideDown,leverSideOperate:icons$2.leverSideOperate,leverSideUp:icons$2.leverSideUp,seatArrowInLeft:icons$2.seatArrowInLeft,seatArrowOutLeft:icons$2.seatArrowOutLeft,seatVArrowInLeft:icons$2.seatVArrowInLeft,seatVArrowOutLeft:icons$2.seatVArrowOutLeft},outline:{beamCurrencyOutlineLarge:icons$2.beamCurrencyOutlineLarge},scenario:{flagOutlineLarge:icons$2.flagOutlineLarge},house:{houseWrenchRoof:icons$2.houseWrenchRoof,houseWrench:icons$2.houseWrench,house:icons$2.house},helmet:{rallyHelmet3To4:icons$2.rallyHelmet3To4,rallyHelmet:icons$2.rallyHelmet},racing:{rallyHelmet3To4:icons$2.rallyHelmet3To4,rallyHelmet:icons$2.rallyHelmet},"game mode":{rallyHelmet3To4:icons$2.rallyHelmet3To4,rallyHelmet:icons$2.rallyHelmet},offline:{globeSimpleNotSign:icons$2.globeSimpleNotSign},online:{globeSimplified:icons$2.globeSimplified},material:{cableSection:icons$2.cableSection,strapHook:icons$2.strapHook,strapRatchet:icons$2.strapRatchet},beam:{cableSection:icons$2.cableSection},strap:{cableSection:icons$2.cableSection,strapHook:icons$2.strapHook,strapRatchet:icons$2.strapRatchet},controls:{kbArrowsDown:icons$2.kbArrowsDown,kbArrowsLeftRight:icons$2.kbArrowsLeftRight,kbArrowsLeft:icons$2.kbArrowsLeft,kbArrowsOutline:icons$2.kbArrowsOutline,kbArrowsRight:icons$2.kbArrowsRight,kbArrowsSolid:icons$2.kbArrowsSolid,kbArrowsUpDown:icons$2.kbArrowsUpDown,kbArrowsUp:icons$2.kbArrowsUp},equipment:{auxUpDown:icons$2.auxUpDown,bucketArmUpDown:icons$2.bucketArmUpDown,bucketTilt:icons$2.bucketTilt,bucketArmDown:icons$2.bucketArmDown,bucketArmLevel:icons$2.bucketArmLevel,bucketArmUp:icons$2.bucketArmUp,bucketTiltDown:icons$2.bucketTiltDown,bucketTiltLevel:icons$2.bucketTiltLevel,bucketTiltUp:icons$2.bucketTiltUp,dumpBedDown:icons$2.dumpBedDown,dumpBedUpDown:icons$2.dumpBedUpDown,dumpBedUp:icons$2.dumpBedUp}}),getIconsWithTags=(...tagsToFind)=>Object.fromEntries(Object.entries(icons$2).filter(([name,{tags}])=>{for(let t of tagsToFind)if(!tags.includes(t))return!1;return!0})),icons=Object.freeze({...icons$2,_empty:{...icons$2.minus,invisible:!0}}),_sfc_main$369={__name:`bngIcon`,props:{type:{type:[String,Object],default:``},fallbackType:{type:String,default:`placeholder`},color:{type:String,default:`#fff`},asImage:{},image:String,externalImage:String},setup(__props){useCssVars(_ctx=>({v9bdaf084:__props.color}));let props=__props,hasImageSource=computed(()=>!!props.image||!!props.externalImage),imageSrcKey=computed(()=>props.image||props.externalImage||``),errorSrcKey=ref(``),isCurrentSrcErrored=computed(()=>!!imageSrcKey.value&&errorSrcKey.value===imageSrcKey.value),isGlyph=computed(()=>!!(!hasImageSource.value||isCurrentSrcErrored.value)),icon=computed(()=>{let res;switch(typeof props.type){case`object`:props.type.glyph&&(res=props.type);break;case`string`:props.type in icons&&(res=icons[props.type]);break}return res}),displayIcon=computed(()=>{let fallback=typeof props.fallbackType==`string`&&props.fallbackType in icons?icons[props.fallbackType]:icons.placeholder;return isCurrentSrcErrored.value||!icon.value&&!hasImageSource.value?fallback:icon.value}),iconGlyph=computed(()=>displayIcon.value?displayIcon.value.glyph:icons.placeholder.glyph),OFF_VALUES=[null,void 0,!1,`false`,0,`0`],asImage=computed(()=>OFF_VALUES.includes(props.asImage)?!1:props.asImage||!0),imageProps=computed(()=>{let res={bgColor:props.color,mask:[`mask`,`span`].includes(asImage.value)};return icon.value||(res.bgColor=`#f00`),asImage.value||(props.image?res.src=props.image:props.externalImage&&(res.externalSrc=props.externalImage)),res});function onImageError(){errorSrcKey.value=imageSrcKey.value}return(_ctx,_cache)=>isGlyph.value?(openBlock(),createElementBlock(`span`,{key:0,class:normalizeClass([`icon-base`,{"icon-not-found":displayIcon.value===unref(icons).placeholder,"icon-invisible":displayIcon.value&&displayIcon.value.invisible}])},toDisplayString(iconGlyph.value),3)):(openBlock(),createBlock(unref(bngImageAsset_default),mergeProps({key:1,class:`icon-img`},imageProps.value,{onError:onImageError}),null,16))}},bngIcon_default=__plugin_vue_export_helper_default(_sfc_main$369,[[`__scopeId`,`data-v-978d1732`]]),markerValidate=name=>name.endsWith(`Back`)&&Object.keys(iconsBySize[56]).includes(name.replace(/Back$/,`Front`))||name.endsWith(`Front`)&&Object.keys(iconsBySize[56]).includes(name.replace(/Front$/,`Back`)),markersList=Object.keys(iconsBySize[56]).filter(markerValidate).map(name=>name.replace(/Back$|Front$/,``)).sort((a$1,b)=>a$1.toLowerCase().localeCompare(b.toLowerCase())).reduce((res,name)=>res.includes(name)?res:[...res,name],[]);const markers=Object.fromEntries(markersList.map(i=>[i,i])),MARKER_POINTS={up:`up`,down:`down`,left:`left`,right:`right`};var _sfc_main$368={__name:`bngIconMarker`,props:{marker:{type:String,default:`circlePin`,validator:val=>!!markers[val]},type:[String,Object],color:[String,Array],point:{type:String,default:`down`,validator:val=>MARKER_POINTS[val]}},setup(__props){let props=__props,icon=computed(()=>({back:iconsBySize[56][props.marker+`Back`],front:iconsBySize[56][props.marker+`Front`]})),iconColour=computed(()=>({back:(Array.isArray(props.color)?props.color[0]:props.color)||`#fff`,front:(Array.isArray(props.color)?props.color[1]:null)||`#000`,icon:(Array.isArray(props.color)?props.color[2]||props.color[0]:props.color)||`#fff`}));return(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,{class:normalizeClass([`icon-marker`,`icon-point-${__props.point}`,`icon-type-${__props.marker}`])},[createVNode(unref(bngIcon_default),{class:`icon-back`,type:icon.value.back,color:iconColour.value.back},null,8,[`type`,`color`]),createVNode(unref(bngIcon_default),{class:`icon-front`,type:icon.value.front,color:iconColour.value.front},null,8,[`type`,`color`]),__props.type?(openBlock(),createBlock(unref(bngIcon_default),{key:0,class:`icon-inner`,type:__props.type,color:iconColour.value.icon},null,8,[`type`,`color`])):createCommentVNode(``,!0)],2))}},bngIconMarker_default=__plugin_vue_export_helper_default(_sfc_main$368,[[`__scopeId`,`data-v-1089accc`]]),_hoisted_1$322=[`src`],_sfc_main$367=Object.assign({inheritAttrs:!1},{__name:`bngImage`,props:{src:String,observe:Boolean},setup(__props){let props=__props,attrs=useAttrs(),observe=computed(()=>props.observe?`observe`:void 0),imgAttrs=computed(()=>showCanvas.value?{}:attrs),cvsAttrs=computed(()=>showCanvas.value?attrs:{}),elImg=ref(null),elCanvas=ref(null),showCanvas=ref(!1),imgSrc=ref(emptyImage),parentDataAttrs={};function setImage(elm,url,bmp){bmp?(showCanvas.value=!0,imgSrc.value=emptyImage,elCanvas.value.width=bmp.width,elCanvas.value.height=bmp.height,elCanvas.value.getContext(`2d`).drawImage(bmp,0,0),Object.entries(parentDataAttrs).forEach(([attr,value])=>{elCanvas.value.setAttribute(attr,value)})):(showCanvas.value=!1,imgSrc.value=url||`data:image/svg+xml,`)}return watch(()=>props.src,()=>{elImg.value&&(showCanvas.value=!1,imgSrc.value=emptyImage)}),watch(elImg,elm=>{if(elm){parentDataAttrs={};for(let attr of elm.parentElement.getAttributeNames())attr.startsWith(`data-v-`)&&(parentDataAttrs[attr]=elm.parentElement.getAttribute(attr));Object.entries(parentDataAttrs).forEach(([attr,value])=>{elm.setAttribute(attr,value),elCanvas.value&&elCanvas.value.setAttribute(attr,value)}),elm.__setImage=setImage}},{immediate:!0}),(_ctx,_cache)=>(openBlock(),createElementBlock(Fragment,null,[withDirectives(createBaseVNode(`img`,mergeProps({ref_key:`elImg`,ref:elImg},imgAttrs.value,{src:imgSrc.value,alt:``}),null,16,_hoisted_1$322),[[vShow,!showCanvas.value],[unref(BngLazyImage_default),{url:__props.src,callback:setImage},observe.value]]),withDirectives(createBaseVNode(`canvas`,mergeProps({ref_key:`elCanvas`,ref:elCanvas},cvsAttrs.value),null,16),[[vShow,showCanvas.value]])],64))}}),bngImage_default=_sfc_main$367,_hoisted_1$321=[`src`],_sfc_main$366={__name:`bngImageAsset`,props:{src:String,externalSrc:String,span:Boolean,mask:Boolean,bgColor:{type:String,default:`transparent`}},emits:[`error`,`load`],setup(__props,{emit:__emit}){useCssVars(_ctx=>({v0d0b2c1c:__props.bgColor}));let emit$1=__emit,props=__props,assetURL=computed(()=>props.src?getAssetURL(props.src):props.externalSrc);return(_ctx,_cache)=>__props.span||__props.mask?(openBlock(),createElementBlock(`span`,{key:0,class:`bng-image-asset`,style:normalizeStyle({[__props.mask?`maskImage`:`backgroundImage`]:`url(${assetURL.value})`})},[renderSlot(_ctx.$slots,`default`,{},void 0,!0)],4)):(openBlock(),createElementBlock(`img`,{key:1,class:`bng-image-asset`,src:assetURL.value,alt:``,onError:_cache[0]||=$event=>emit$1(`error`,$event),onLoad:_cache[1]||=$event=>emit$1(`load`,$event)},null,40,_hoisted_1$321))}},bngImageAsset_default=__plugin_vue_export_helper_default(_sfc_main$366,[[`__scopeId`,`data-v-27bf5bcc`]]),_hoisted_1$320={class:`bng-image-carousel`},_sfc_main$365={__name:`bngImageCarousel`,props:{images:{type:Array,required:!0},external:Boolean,current:[String,Number],transition:Boolean,transitionType:{type:String,default:`fade`},transitionTime:{type:Number,default:3e3},loop:{type:Boolean,default:!0},showNav:{type:Boolean,default:!0},parent:Object},setup(__props,{expose:__expose}){let props=__props,carousel=ref();__expose({carousel});let imageAssets=computed(()=>props.external?props.images.map(x=>`/`+x):props.images.map(getAssetURL)),carouselSettings=computed(()=>props.parent&&props.parent.carousel!==carousel?{parent:props.parent.carousel,transition:!1,transitionType:props.transitionType,loop:!1,transitionTime:props.transitionTime}:{current:props.current,transition:props.transition,transitionType:props.transitionType,transitionTime:props.transitionTime,loop:props.loop,showNav:props.showNav});return(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$320,[createVNode(unref(carousel_default),mergeProps({items:imageAssets.value,ref_key:`carousel`,ref:carousel},carouselSettings.value),{item:withCtx(({item})=>[createBaseVNode(`div`,{class:`image-slide`,style:normalizeStyle({"background-image":`url(${item})`})},null,4)]),_:1},16,[`items`])]))}},bngImageCarousel_default=__plugin_vue_export_helper_default(_sfc_main$365,[[`__scopeId`,`data-v-6b0c2d6b`]]),_hoisted_1$319=[`src`],_sfc_main$364={__name:`bngImageTile`,props:{oldIcon:String,src:String,externalSrc:String,label:String,image:String,externalImage:String,icon:[Object,String],ratio:{type:String,default:`4:3`}},setup(__props){let props=__props,slots=useSlots(),assetURL=computed(()=>props.externalSrc?props.externalSrc:getAssetURL(props.src));return(_ctx,_cache)=>(openBlock(),createBlock(unref(bngTile_default),{label:__props.label,backgroundImage:__props.image,backgroundExternalImage:__props.externalImage,ratio:__props.ratio},createSlots({default:withCtx(()=>[__props.oldIcon?(openBlock(),createBlock(unref(bngOldIcon_default),{key:0,class:`icon`,type:__props.oldIcon,span:``},null,8,[`type`])):createCommentVNode(``,!0),__props.icon?(openBlock(),createBlock(unref(bngIcon_default),{key:1,class:`glyph`,type:__props.icon},null,8,[`type`])):__props.src||__props.externalSrc?(openBlock(),createElementBlock(`img`,{key:2,class:`icon`,src:assetURL.value},null,8,_hoisted_1$319)):createCommentVNode(``,!0)]),_:2},[unref(slots).default?{name:`label`,fn:withCtx(()=>[renderSlot(_ctx.$slots,`default`,{},void 0,!0)]),key:`0`}:void 0]),1032,[`label`,`backgroundImage`,`backgroundExternalImage`,`ratio`]))}},bngImageTile_default=__plugin_vue_export_helper_default(_sfc_main$364,[[`__scopeId`,`data-v-d74a4ec4`]]),UNIQUE_CLEAN_VALUE=Symbol(`Unique 'clean' value from Dirty service code`);function useDirty(valueRef,emitter=void 0,setCallback=void 0){if(!valueRef)throw Error(`valueRef must be specified`);let hasInitValue=!1,initialValue=ref();function init$3(val){let type=typeof val;type===`undefined`||type===`number`&&isNaN(val)||(hasInitValue=!0,initialValue.value=val)}if(init$3(valueRef.value),!hasInitValue){let unwatch=watch(valueRef,newVal=>{init$3(newVal),hasInitValue&&unwatch()});onUnmounted(()=>!hasInitValue&&unwatch())}let dirty=computed(()=>{let isDirty$1=valueRef.value!==initialValue.value;return isDirty$1&&hasInitValue&&emitter&&emitter(`dirtied`,valueRef.value,initialValue.value),isDirty$1}),setDirty=state=>{let oldVal=initialValue.value,newVal=state?UNIQUE_CLEAN_VALUE:valueRef.value;initialValue.value=newVal,typeof setCallback==`function`&&setCallback(newVal,oldVal)};return{dirty,currentCleanValue:computed(()=>initialValue.value),setCleanValue:val=>initialValue.value=val,resetValue:()=>valueRef.value=initialValue.value,setDirty,markClean:()=>setDirty(!1)}}var _hoisted_1$318={class:`bng-input-wrapper`},_hoisted_2$259={class:`icons-input-wrapper`},_hoisted_3$226={class:`bng-input-container`},_hoisted_4$194={key:0,class:`prefix-suffix-container`},_hoisted_5$164={"data-testid":`prefix`},_hoisted_6$141={class:`bng-input-group`},_hoisted_7$123=[`value`,`type`,`min`,`max`,`step`,`maxlength`,`placeholder`,`disabled`,`readonly`],_hoisted_8$101={key:0,class:`number-actions`},_hoisted_9$91={key:1,class:`floating-label`,"data-testid":`floating-label`},_hoisted_10$79={key:2,class:`error-message`},_hoisted_11$71={key:1,class:`prefix-suffix-container`},_hoisted_12$59={"data-testid":`suffix`},_hoisted_13$51={key:2,class:`trailing-icon`},_sfc_main$363={__name:`bngInput`,props:{modelValue:[String,Number],type:{type:String,default:`text`,validator(value){return[`text`,`number`].includes(value)}},min:[Number,String],max:[Number,String],step:{type:[Number,String],default:1},decimals:Number,maxlength:[Number,String],readonly:Boolean,floatingLabel:String,externalLabel:String,placeholder:String,initialValue:String,leadingIcon:Object,prefix:String,suffix:String,trailingIcon:Object,trailingIconOutside:Boolean,disabled:Boolean,validate:Function,errorMessage:String},emits:[`update:modelValue`,`valueChanged`,`change`,`focus`,`blur`],setup(__props,{expose:__expose,emit:__emit}){let props=__props,emitter=__emit,input=ref(),value=ref(props.initialValue||props.modelValue),isInputFieldFocused=ref(!1),numMin=computed(()=>props.type===`number`?+props.min:null),numMax=computed(()=>props.type===`number`?+props.max:null),numStep=computed(()=>props.type===`number`?roundDec(+props.step,15):null),numDecimals=computed(()=>props.type===`number`?props.decimals:null),charMax=computed(()=>props.type===`text`?props.maxlength:null),hasValue=computed(()=>value.value!==``&&value.value!==void 0&&value.value!==null),hasError=computed(()=>typeof props.validate==`function`?!props.validate(value.value):!1);if(props.type===`number`){let type=typeof value.value;type===`string`&&/^\d+(?:\.?\d+)?$/.test(value.value)?value.value=+value.value:type!==`number`&&(value.value=0),numMin.value>numMax.value&&console.error(`BngInput: min cannot be greater than max`)}__expose(useDirty(value));let lastNotify;function notify(val){props.readonly||lastNotify===val||(lastNotify=val,emitter(`update:modelValue`,val),emitter(`valueChanged`,val),emitter(`change`,val))}watch(()=>props.modelValue,newVal=>{props.type===`number`&&(newVal=numClamp(newVal)),value.value=newVal,lastNotify=newVal},{immediate:!0});function numClamp(val){return isNaN(val)&&(val=0),typeof numDecimals.value==`number`&&!isNaN(numDecimals.value)?val=roundDec(val,numDecimals.value):typeof numStep.value==`number`&&!isNaN(numStep.value)&&(val=roundDecSample(val,numStep.value)),typeof numMin.value==`number`&&!isNaN(numMin.value)&&valnumMax.value&&(val=numMax.value),val}function increment(by){let val=numClamp(+value.value+by);value.value!==val&&(value.value=val,input.value=val,notify(val))}let onArrowUpClicked=()=>increment(numStep.value),onArrowDownClicked=()=>increment(-numStep.value);function onValueChanged($event){let val=$event.target.value;if(props.type===`number`){val=+val;let prev=val;val=numClamp(val),val!==prev&&(input.value=val)}value.value=val,notify(val)}function onInputFieldFocusIn(){isInputFieldFocused.value=!0,emitter(`focus`)}function onInputFieldFocusOut(){isInputFieldFocused.value=!1,emitter(`blur`),notify(value.value)}return(_ctx,_cache)=>withDirectives((openBlock(),createElementBlock(`div`,_hoisted_1$318,[__props.externalLabel?(openBlock(),createElementBlock(`span`,{key:0,class:`external-label`,style:normalizeStyle([__props.leadingIcon?{"margin-left":`3em`}:{}]),"data-testid":`external-label`},toDisplayString(__props.externalLabel),5)):createCommentVNode(``,!0),createBaseVNode(`div`,_hoisted_2$259,[__props.leadingIcon?(openBlock(),createBlock(unref(bngIcon_default),{key:0,class:`outside-icon`,type:__props.leadingIcon,"data-testid":`leading-icon`},null,8,[`type`])):createCommentVNode(``,!0),createBaseVNode(`div`,{tabindex:`disabled ? -1 : 0`,class:normalizeClass([`bng-highlight-container`,{"bng-input-focused":isInputFieldFocused.value,"has-error":hasError.value}]),onKeydown:withKeys(onInputFieldFocusOut,[`enter`])},[createBaseVNode(`div`,_hoisted_3$226,[__props.prefix?(openBlock(),createElementBlock(`span`,_hoisted_4$194,[createBaseVNode(`span`,_hoisted_5$164,toDisplayString(__props.prefix),1)])):createCommentVNode(``,!0),createBaseVNode(`div`,_hoisted_6$141,[withDirectives(createBaseVNode(`input`,{ref_key:`input`,ref:input,class:normalizeClass([`bng-input`,{"bng-input-empty":!hasValue.value,"bng-input-error":hasError.value}]),"data-testid":`input`,value:value.value,type:__props.type,min:numMin.value,max:numMax.value,step:numStep.value,maxlength:charMax.value,onInput:onValueChanged,onFocusin:onInputFieldFocusIn,onFocusout:onInputFieldFocusOut,placeholder:__props.placeholder,disabled:__props.disabled,readonly:__props.readonly},null,42,_hoisted_7$123),[[unref(BngTextInput_default)]]),__props.type===`number`?(openBlock(),createElementBlock(`div`,_hoisted_8$101,[withDirectives(createVNode(unref(bngIcon_default),{type:unref(iconsByTag).arrow.arrowLargeUp,class:normalizeClass([{"number-action-disabled":__props.readonly},`number-action up-action`])},null,8,[`type`,`class`]),[[unref(BngClick_default),{clickCallback:onArrowUpClicked,holdCallback:onArrowUpClicked}]]),withDirectives(createVNode(unref(bngIcon_default),{type:unref(iconsByTag).arrow.arrowLargeDown,class:normalizeClass([`number-action down-action`,{"number-action-disabled":__props.readonly}])},null,8,[`type`,`class`]),[[unref(BngClick_default),{clickCallback:onArrowDownClicked,holdCallback:onArrowDownClicked}]])])):createCommentVNode(``,!0),__props.floatingLabel?(openBlock(),createElementBlock(`span`,_hoisted_9$91,toDisplayString(__props.floatingLabel),1)):createCommentVNode(``,!0),hasError.value&&__props.errorMessage?(openBlock(),createElementBlock(`span`,_hoisted_10$79,toDisplayString(__props.errorMessage),1)):createCommentVNode(``,!0),_cache[0]||=createBaseVNode(`span`,{class:`input-border`},null,-1)]),__props.suffix?(openBlock(),createElementBlock(`span`,_hoisted_11$71,[createBaseVNode(`span`,_hoisted_12$59,toDisplayString(__props.suffix),1)])):createCommentVNode(``,!0),__props.trailingIcon&&!__props.trailingIconOutside?(openBlock(),createElementBlock(`span`,_hoisted_13$51,[createVNode(unref(bngIcon_default),{type:__props.trailingIcon,class:`input-icon`,"data-testid":`trailing-icon`},null,8,[`type`])])):createCommentVNode(``,!0)])],34),__props.trailingIcon&&__props.trailingIconOutside?(openBlock(),createBlock(unref(bngIcon_default),{key:1,type:__props.trailingIcon,class:`outside-icon`,"data-testid":`external-trailing-icon`},null,8,[`type`])):createCommentVNode(``,!0)])])),[[unref(BngDisabled_default),__props.disabled]])}},bngInput_default=__plugin_vue_export_helper_default(_sfc_main$363,[[`__scopeId`,`data-v-d6c70b5c`]]),_hoisted_1$317=[`readonly`,`disabled`,`placeholder`,`maxlength`],_hoisted_2$258={key:0,class:`floating-label`},_hoisted_3$225={key:7,class:`external-button`},_hoisted_4$193={key:8,class:`error-message`};const INPUT_TYPES={text:`text`,number:`number`},STEP_ICON_TYPES={arrowUpDown:`arrowUpDown`,arrowLeftRight:`arrowLeftRight`,plusMinus:`plusMinus`};var STEP_ICON_TYPES_MAP={[STEP_ICON_TYPES.arrowUpDown]:{up:`arrowSmallUp`,down:`arrowSmallDown`},[STEP_ICON_TYPES.arrowLeftRight]:{up:`arrowSmallRight`,down:`arrowSmallLeft`},[STEP_ICON_TYPES.plusMinus]:{up:`plus`,down:`minus`}},NUMBER_PATTERN=/^\d+(\.d+)?$/,NUMBER_INPUT_KEYS=/^[0-9\.\-]$/,ERROR_TYPES={invalidformat:`invalidformat`,outofrange:`outofrange`,required:`required`,custom:`custom`},ERROR_MESSAGES={[ERROR_TYPES.invalidformat]:`Invalid format`,[ERROR_TYPES.outofrange]:`Value must be between {min} and {max}`,[`${ERROR_TYPES.outofrange}-min`]:`Value must be greater than {min}`,[`${ERROR_TYPES.outofrange}-max`]:`Value must be less than {max}`,[ERROR_TYPES.required]:`Value is required`},ALLOW_DEFAULT_BEHAVIOR_KEYS=[`ArrowLeft`,`ArrowRight`,`ArrowUp`,`ArrowDown`,`Backspace`,`Delete`],NUMBER_INPUT_MODES={spinner:`spinner`,arrowKeys:`arrowKeys`,uinav:`uinav`},_sfc_main$362={__name:`bngInputNew`,props:{modelValue:{type:[Number,String],default:void 0},value:{type:[Number,String],default:void 0},type:{type:String,default:INPUT_TYPES.text,validator(value){return Object.keys(INPUT_TYPES).includes(value)}},showExternalButton:{type:Boolean,default:!0},floatingLabel:[Boolean,String],externalButtonFn:Function,externalLabel:String,label:String,prefix:String,suffix:String,leadingIcon:Object,trailingIcon:Object,maxLength:{type:[Number,String],default:null,validator(value){return value===null?!0:typeof parseInt(value)==`number`&&parseInt(value)>=0}},readonly:Boolean,disabled:Boolean,required:Boolean,placeholder:String,validate:Function,errorMessage:String,min:{type:Number,default:void 0},max:{type:Number,default:void 0},step:{type:Number,default:1},stepIconType:{type:String,default:STEP_ICON_TYPES.arrowUpDown,validator(value){return Object.keys(STEP_ICON_TYPES).includes(value)}},noStepBindings:Boolean},emits:[`update:modelValue`,`change`,`error`,`blur`,`focus`,`valueChanged`],setup(__props,{expose:__expose,emit:__emit}){let props=__props,emit$1=__emit,slots=useSlots(),{showIfController}=storeToRefs(controls_default()),input=ref(null),scopeActivated=ref(!1),rawValue=ref(null),validationState=ref(null),isProgrammaticChange=ref(!1),numberInputState=reactive({inputType:null,isUpActive:!1,isDownActive:!1}),value=computed({get:()=>props.modelValue,set:emitChange}),isEmptyRawValue=computed(()=>isEmpty(rawValue.value)),inputStyle=computed(()=>({"max-width":props.maxLength?`${props.maxLength}ch`:`initial`})),stepIcons=computed(()=>STEP_ICON_TYPES_MAP[props.stepIconType]),exposed=useDirty(value);exposed.scopeActivated=scopeActivated,__expose(exposed),watch(()=>rawValue.value,newValue=>{if(isProgrammaticChange.value){isProgrammaticChange.value=!1;return}let res=validate(newValue);validationState.value=res,rawValue.value!=props.modelValue&&(res.valid||res.error!==ERROR_TYPES.invalidformat)&&(value.value=res.value)}),watch(()=>props.modelValue,modelValue=>{modelValue!=rawValue.value&&(isProgrammaticChange.value=!0,rawValue.value=isEmpty(modelValue)?null:String(modelValue))},{immediate:!0}),watch(()=>props.value,()=>{props.modelValue===void 0&&props.value!=rawValue.value&&(isProgrammaticChange.value=!0,rawValue.value=props.value)},{immediate:!0}),onUnmounted(()=>{resetInputState.cancel()});let activateInput=()=>{props.disabled||props.readonly||nextTick(()=>input.value.focus())},canActivateScope=()=>!props.readonly&&!props.disabled,externalButtonFn=()=>{props.externalButtonFn?props.externalButtonFn():props.type===INPUT_TYPES.number?rawValue.value=props.min||0:rawValue.value=null,activateInput()};function onScopeActivated(event){scopeActivated.value=!0}function onScopeDeactivated(event){scopeActivated.value=!1,nextTick(()=>cleanValue())}let resetInputState=debounce(()=>{numberInputState.inputType=null,numberInputState.isUpActive=!1,numberInputState.isDownActive=!1},150);function onUINavChangeValue(dir){numberInputState.inputType&&numberInputState.inputType!==NUMBER_INPUT_MODES.uinav||(numberInputState.inputType=NUMBER_INPUT_MODES.uinav,updateNumValue(dir),resetInputState())}function onArrowKeysChangeValue(dir){numberInputState.inputType&&numberInputState.inputType!==NUMBER_INPUT_MODES.arrowKeys||(numberInputState.inputType=NUMBER_INPUT_MODES.arrowKeys,updateNumValue(dir),resetInputState())}function onSpinnerChangeValue(dir){numberInputState.inputType&&numberInputState.inputType!==NUMBER_INPUT_MODES.spinner||(numberInputState.inputType=NUMBER_INPUT_MODES.spinner,updateNumValue(dir),resetInputState())}function updateNumValue(dir){props.type!==INPUT_TYPES.number||props.disabled||props.readonly||(dir===1?(numberInputState.isUpActive=!0,changeNumValue(props.step)):(numberInputState.isDownActive=!0,changeNumValue(-props.step)))}function onEnterDown(event){event.preventDefault(),scopeActivated.value=!1}function onKeyDown(event){if(ALLOW_DEFAULT_BEHAVIOR_KEYS.includes(event.key))return;event.key===`Enter`&&event.preventDefault();let rawValueString=typeof rawValue.value!=`string`&&!isNullOrUndefined(rawValue.value)?rawValue.value.toString():rawValue.value;props.type===INPUT_TYPES.number&&(!NUMBER_INPUT_KEYS.test(event.key)||event.key===`.`&&(isNullOrUndefined(rawValueString)||rawValueString.includes(`.`))||event.key===`.`&&!NUMBER_PATTERN.test(rawValueString))&&event.preventDefault()}function changeNumValue(diff){if(props.type!==INPUT_TYPES.number)return;if(isEmpty(rawValue.value)){diff<0?rawValue.value=isNullOrUndefined(props.max)?0:props.max:rawValue.value=isNullOrUndefined(props.min)?0:props.min;return}let{valid,value:validatedValue,error}=validate(rawValue.value);if(!valid&&error!==ERROR_TYPES.outofrange){rawValue.value=0;return}let decimalTokens=props.step.toString().split(`.`),stepDecimalPlaces=decimalTokens.length>1?decimalTokens[1].length:0,newValue=Number((validatedValue+diff).toFixed(stepDecimalPlaces)),{valid:isValidRange}=validateRange(newValue);(isValidRange||diff<0&&newValue>=props.max||diff>0&&newValue<=props.min)&&(rawValue.value=newValue)}function cleanValue(){if(!isNullOrUndefined(rawValue.value)&&props.type===INPUT_TYPES.number){let rawValueString=typeof rawValue.value==`string`?rawValue.value:rawValue.value.toString();rawValueString.endsWith(`.`)&&(rawValue.value=rawValueString.slice(0,-1))}}function validate(value$1){let valid=!0,newValue=value$1,errorMessage=null;if(isEmpty(value$1)&&props.required)return{valid:!1,error:ERROR_TYPES.required};if(isEmpty(value$1)&&props.type===INPUT_TYPES.number)return{valid:!0,value:void 0};if(props.type===INPUT_TYPES.number&&typeof value$1==`string`&&(newValue=value$1.includes(`.`)?parseFloat(value$1):parseInt(value$1),isNaN(newValue)))return{valid:!1,error:ERROR_TYPES.invalidformat};if(props.type===INPUT_TYPES.number)return{...validateRange(newValue),value:newValue};if(props.validate){let res=props.validate(value$1);typeof res==`boolean`?(valid=res,errorMessage=props.errorMessage):typeof res==`object`&&(`valid`in res&&console.warn("`validate` function must return a boolean `valid` property. Ignoring validation result..."),valid=res.valid||!0,valid||(errorMessage=`errorMessage`in res?res.errorMessage:props.errorMessage))}return{valid,value:newValue,errorMessage}}function validateRange(value$1){let lessThanMin=props.min&&value$1props.max,valid=!0,errorMessage=null;return!isNullOrUndefined(props.min)&&!isNullOrUndefined(props.max)&&(lessThanMin||greaterThanMax)?(errorMessage=ERROR_MESSAGES[ERROR_TYPES.outofrange].replace(`{min}`,props.min).replace(`{max}`,props.max),valid=!1):lessThanMin?(errorMessage=ERROR_MESSAGES[`${ERROR_TYPES.outofrange}-min`].replace(`{min}`,props.min),valid=!1):greaterThanMax&&(errorMessage=ERROR_MESSAGES[`${ERROR_TYPES.outofrange}-max`].replace(`{max}`,props.max),valid=!1),{valid,error:valid?null:ERROR_TYPES.outofrange,errorMessage}}function isEmpty(val){return val==null||val===``}function isNullOrUndefined(val){return val==null}function emitChange(value$1){emit$1(`update:modelValue`,value$1),emit$1(`change`,value$1),emit$1(`valueChanged`,value$1)}return(_ctx,_cache)=>withDirectives((openBlock(),createElementBlock(`div`,{class:normalizeClass([{"has-value":!isEmptyRawValue.value,"bng-input-readonly":__props.readonly,"bng-input-invalid":validationState.value&&!validationState.value.valid},`bng-input`]),onActivate:onScopeActivated,onDeactivate:onScopeDeactivated},[(__props.label||__props.externalLabel||unref(slots).label)&&!__props.floatingLabel?(openBlock(),createElementBlock(`label`,{key:0,class:`external-label`,onClick:activateInput,onMousedown:_cache[0]||=withModifiers(()=>{},[`prevent`])},[renderSlot(_ctx.$slots,`label`,{},()=>[createTextVNode(toDisplayString(__props.label||__props.externalLabel),1)],!0)],32)):createCommentVNode(``,!0),__props.leadingIcon||unref(slots).leadingIcon?(openBlock(),createElementBlock(`span`,{key:1,class:`leading-icon`,onClick:activateInput,onMousedown:_cache[1]||=withModifiers(()=>{},[`prevent`])},[renderSlot(_ctx.$slots,`leading-icon`,{},()=>[createVNode(unref(bngIcon_default),{type:__props.leadingIcon},null,8,[`type`])],!0)],32)):createCommentVNode(``,!0),__props.type===INPUT_TYPES.number&&!__props.readonly&&!__props.disabled?(openBlock(),createElementBlock(`span`,{key:2,class:normalizeClass([{"spinner-active":numberInputState.isDownActive},`input-spinner input-spinner-down`]),onMousedown:_cache[2]||=withModifiers(()=>{},[`prevent`])},[renderSlot(_ctx.$slots,`spinner-down`,{changeValue:()=>onSpinnerChangeValue(-1)},()=>[withDirectives((openBlock(),createBlock(unref(bngButton_default),{"bng-no-nav":`true`,accent:`text`},{default:withCtx(()=>[__props.noStepBindings?createCommentVNode(``,!0):(openBlock(),createBlock(unref(bngBinding_default),{key:0,controller:``,uiEvent:`focus_d`})),!unref(showIfController)||__props.noStepBindings?(openBlock(),createBlock(unref(bngIcon_default),{key:1,type:stepIcons.value.down},null,8,[`type`])):createCommentVNode(``,!0)]),_:1})),[[unref(BngClick_default),{clickCallback:()=>onSpinnerChangeValue(-1),holdCallback:()=>onSpinnerChangeValue(-1)}]])],!0)],34)):createCommentVNode(``,!0),__props.prefix||unref(slots).prefix?(openBlock(),createElementBlock(`span`,{key:3,class:`prefix`,onClick:activateInput,onMousedown:_cache[3]||=withModifiers(()=>{},[`prevent`])},[renderSlot(_ctx.$slots,`prefix`,{},()=>[createTextVNode(toDisplayString(__props.prefix),1)],!0)],32)):createCommentVNode(``,!0),createBaseVNode(`div`,{class:`input-container`,style:normalizeStyle(inputStyle.value)},[withDirectives(createBaseVNode(`input`,{ref_key:`input`,ref:input,"onUpdate:modelValue":_cache[4]||=$event=>rawValue.value=$event,readonly:__props.readonly,disabled:__props.disabled,placeholder:__props.placeholder,maxlength:__props.maxLength,type:`text`,onFocusin:_cache[5]||=$event=>_ctx.$emit(`focus`),onFocusout:_cache[6]||=$event=>_ctx.$emit(`blur`),onKeydown:[_cache[7]||=withKeys($event=>onArrowKeysChangeValue(1),[`arrow-up`]),_cache[8]||=withKeys($event=>onArrowKeysChangeValue(-1),[`arrow-down`]),withKeys(onEnterDown,[`enter`]),onKeyDown]},null,40,_hoisted_1$317),[[unref(BngTextInput_default)],[unref(BngOnUiNavFocus_default),dir=>onUINavChangeValue(dir),`vertical`,{repeat:!0}],[vModelText,rawValue.value]]),__props.label&&__props.floatingLabel||typeof __props.floatingLabel==`string`||unref(slots).label?(openBlock(),createElementBlock(`label`,_hoisted_2$258,[renderSlot(_ctx.$slots,`label`,{},()=>[createTextVNode(toDisplayString(__props.label||__props.floatingLabel),1)],!0)])):createCommentVNode(``,!0)],4),__props.suffix||unref(slots).suffix?(openBlock(),createElementBlock(`span`,{key:4,class:`suffix`,onClick:activateInput,onMousedown:_cache[9]||=withModifiers(()=>{},[`prevent`])},[renderSlot(_ctx.$slots,`suffix`,{},()=>[createTextVNode(toDisplayString(__props.suffix),1)],!0)],32)):createCommentVNode(``,!0),__props.trailingIcon||unref(slots).trailingIcon?(openBlock(),createElementBlock(`span`,{key:5,class:`trailing-icon`,onClick:activateInput,onMousedown:_cache[10]||=withModifiers(()=>{},[`prevent`])},[renderSlot(_ctx.$slots,`trailing-icon`,{},()=>[createVNode(unref(bngIcon_default),{type:__props.trailingIcon},null,8,[`type`])],!0)],32)):createCommentVNode(``,!0),__props.type===INPUT_TYPES.number&&!__props.readonly&&!__props.disabled?(openBlock(),createElementBlock(`span`,{key:6,class:normalizeClass([{"spinner-active":numberInputState.isUpActive},`input-spinner input-spinner-up`]),onMousedown:_cache[11]||=withModifiers(()=>{},[`prevent`])},[renderSlot(_ctx.$slots,`spinner-up`,{changeValue:()=>onSpinnerChangeValue(1)},()=>[withDirectives((openBlock(),createBlock(unref(bngButton_default),{"bng-no-nav":`true`,accent:`text`},{default:withCtx(()=>[__props.noStepBindings?createCommentVNode(``,!0):(openBlock(),createBlock(unref(bngBinding_default),{key:0,controller:``,uiEvent:`focus_u`})),!unref(showIfController)||__props.noStepBindings?(openBlock(),createBlock(unref(bngIcon_default),{key:1,type:stepIcons.value.up},null,8,[`type`])):createCommentVNode(``,!0)]),_:1})),[[unref(BngClick_default),{clickCallback:()=>onSpinnerChangeValue(1),holdCallback:()=>onSpinnerChangeValue(1)}]])],!0)],34)):createCommentVNode(``,!0),__props.showExternalButton?(openBlock(),createElementBlock(`span`,_hoisted_3$225,[renderSlot(_ctx.$slots,`external-button`,{externalButtonFn},()=>[__props.readonly?createCommentVNode(``,!0):withDirectives((openBlock(),createBlock(unref(bngButton_default),{key:0,icon:unref(icons).mathMultiply,disabled:__props.disabled,accent:`attention`,onClick:externalButtonFn,onMousedown:_cache[12]||=withModifiers(()=>{},[`prevent`])},null,8,[`icon`,`disabled`])),[[unref(BngOnUiNav_default),void 0,`ok`,{asMouse:!0,focusRequired:!0}],[unref(BngDisabled_default),isEmptyRawValue.value]])],!0)])):createCommentVNode(``,!0),validationState.value&&!validationState.value.valid&&validationState.value.errorMessage||unref(slots).errorMessage?(openBlock(),createElementBlock(`span`,_hoisted_4$193,[renderSlot(_ctx.$slots,`error-message`,{},()=>[createTextVNode(toDisplayString(validationState.value.errorMessage),1)],!0)])):createCommentVNode(``,!0)],34)),[[unref(BngDisabled_default),__props.disabled],[unref(BngScopedNav_default),{activated:scopeActivated.value,canActivate:canActivateScope}]])}},bngInputNew_default=__plugin_vue_export_helper_default(_sfc_main$362,[[`__scopeId`,`data-v-bb1297d5`]]),_hoisted_1$316={class:`list-container`},_hoisted_2$257={key:0,class:`list-toolbar`},_hoisted_3$224={key:1},_hoisted_4$192={class:`list-layout-toggle`};const LIST_LAYOUTS={DEFAULT:`tiles`,TILES:`tiles`,LIST:`list`,RIBBON:`ribbon`};var _sfc_main$361={__name:`bngList`,props:{path:Array,pathLimit:{type:[Number,String],default:3},pathTarget:Object,layoutSelector:Boolean,layoutSelectorTarget:Object,layout:{type:String,default:LIST_LAYOUTS.DEFAULT,validator:val=>Object.values(LIST_LAYOUTS).includes(val)},big:Boolean,immediate:Boolean,keepAlive:[Boolean,Number],tileSizeCalc:Function,tileWidth:Number,tileHeight:Number,tileMargin:Number,targetWidth:Number,targetHeight:Number,targetMargin:Number,titleWidth:Number,titleHeight:Number,titleMargin:Number,targetTitleWidth:Number,targetTitleHeight:Number,targetTitleMargin:Number,noBackground:Boolean},emits:[`layoutChange`,`pathClick`],setup(__props,{expose:__expose,emit:__emit}){let emit$1=__emit,props=__props,elPath=ref();__expose({navBack(){elPath.value&&elPath.value.navBack()},navTo(item){elPath.value&&elPath.value.navTo(item)},async scrollToIndex(index=0){if(!bigmode.enabled){let hasPosObserver=(elCont.value.children||[])[0]?.classList.contains(`bng-pos-observer`),elm=(elCont.value.children||[])[index+(hasPosObserver?1:0)];return elm&&elm.scrollIntoView(),elm}let big=await getBigProps(void 0,index);if(!big)return null;let horizontal=layoutSelected.value===LIST_LAYOUTS.RIBBON,containerSize=horizontal?contWidth:contHeight,rowIndex=layoutCache.itemToRow.get(index),itemRowPos=layoutCache.rows[rowIndex]?.pos||big.position,itemRowSize=layoutCache.rows[rowIndex]?.size||(horizontal?tileWidth.value:tileHeight.value),centeredPos=itemRowPos-containerSize/2+itemRowSize/2;scrollPos.value=Math.max(0,centeredPos),horizontal?elCont.value.scrollLeft=scrollPos.value:elCont.value.scrollTop=scrollPos.value,await updSkeleton();let itm=items$2.value[index];return itm?itm.getElement?.()||itm.el||itm:null},refresh(){tileWidth.value=0,tileHeight.value=0,titleWidth.value=0,titleHeight.value=0,tileProps=getItemProps(items$2.value,!1),titleProps=getItemProps(items$2.value,!0),tileProps&&(tileMargin.value=validNum(tileProps.margin)?tileProps.margin:defTileMargin*fontSize,calcTiles()),titleProps&&(titleMargin.value=validNum(titleProps.margin)?titleProps.margin:defTitleMargin*fontSize,calcTitles()),invalidateLayoutCache(),nextTick(()=>{bigmode.enabled&&contWidth>0&&contHeight>0&&(buildLayoutCache(),calcBig(),updSkeleton())})}});let defFontSize=16,defTileWidth=10,defTileHeight=5,defTileMargin=.2,defTitleWidth=10,defTitleHeight=2.5,defTitleMargin=.2,layoutSelected=ref(props.layout);watch(()=>props.layout,()=>layoutSelected.value=props.layout||LIST_LAYOUTS.DEFAULT),watch(()=>layoutSelected.value,val=>{emit$1(`layoutChange`,val),invalidateLayoutCache(),updSize()});let toolbar=computed(()=>{let res={path:props.path&&props.path.length>0,layout:props.layoutSelector};return res.enabled=res.path||res.layout,res.show=res.enabled&&(res.path&&!props.pathTarget||res.layout&&!props.layoutSelectorTarget),res}),slots=useSlots(),elCont=ref(),elSize=ref(),elSkeleton=ref(),tileWidth=ref(0),tileHeight=ref(0),tileMargin=ref(0),titleWidth=ref(0),titleHeight=ref(0),titleMargin=ref(0),scrollPos=ref(0),skeletonItems=ref([]),processing=computed(()=>bigmode.enabled&&(bigmode.initial||layoutCache.building)),contWidth=0,contHeight=0,fontSize=16,skeletonShown=!1,warnShown=!1,listItemsStyle=computed(()=>bigmode.enabled?{transform:`translate${layoutSelected.value===LIST_LAYOUTS.RIBBON?`X`:`Y`}(${bigmode.position}px)`}:void 0),tileProps=null,titleProps=null,bigmode=reactive({enabled:!1,initial:!0,debounce:500,skeleton:!0,layouts:[],getPos:{[LIST_LAYOUTS.TILES]:()=>elCont.value?.scrollTop||0,[LIST_LAYOUTS.LIST]:()=>elCont.value?.scrollTop||0,[LIST_LAYOUTS.RIBBON]:()=>elCont.value?.scrollLeft||0},overflow:2,skeletonOverflow:2,first:0,last:0,perRow:1,items:[],position:0,full:0,size:0});bigmode.layouts=Object.keys(bigmode.getPos);let layoutCache=reactive({version:0,building:!1,valid:!1,itemCount:0,totalSize:0,rows:[],itemToRow:new Map,rowPositions:[]}),items$2=ref([]),itemsView=ref([]),itemsShown=ref(new Set);watch(()=>props.immediate,val=>{val?(bigmode._skeleton=bigmode.skeleton,bigmode._debounce=bigmode.debounce,bigmode.skeleton=!1,bigmode.debounce=0):(bigmode._skeleton&&(bigmode.skeleton=bigmode._skeleton),bigmode._debounce&&(bigmode.debounce=bigmode._debounce))},{immediate:!0}),watch([()=>slots.default?.(),()=>props.big,()=>layoutSelected.value],()=>{let res=slots.default?slots.default():[];bigmode.enabled=props.big&&bigmode.layouts.includes(layoutSelected.value),bigmode.enabled&&(bigmode.initial=!0,res=getItems(res)),res=res.map((item,key)=>({...item,key})),items$2.value=res,bigmode.enabled||(itemsView.value=res),itemsShown.value.clear(),nextTick(()=>{tileProps=getItemProps(res,!1),titleProps=getItemProps(res,!0),invalidateLayoutCache(),updSize(),updSkeleton()})},{immediate:!0});function getItems(vnodes,_level=0){let res=[];for(let vnode of vnodes)switch(typeof vnode.type){case`object`:{let isTitle=vnode.props&&`bng-list-title`in vnode.props,item={...vnode};isTitle&&(item.isBngListTitle=!0),res.push(item);break}case`symbol`:if(_level===20)return logger_default.debug(`BngList reached max level of nested Vue fragments`),[];res.push(...getItems(vnode.children,_level+1));break}return res}function findItem(vnode,_level=0){let res=null;switch(typeof vnode.type){case`object`:res={el:vnode.el,width:vnode.type.width,height:vnode.type.height,margin:vnode.type.margin};break;case`string`:vnode.el instanceof HTMLElement&&(res={el:vnode.el});break;case`symbol`:if(vnode.children.length>0){if(_level===20)return null;res=findItem(vnode.children[0],++_level)}break}return res}function getItemProps(vnodes,title=!1){if(vnodes.length===0)return null;let sampleItem=vnodes.find(vnode=>title&&vnode.isBngListTitle||!title&&!vnode.isBngListTitle);if(!sampleItem)return null;let res=findItem(sampleItem);if(!res)return null;let valid={width:validNum(res.width),height:validNum(res.height),margin:validNum(res.margin)},fontSize$1,targetWidth=0,targetHeight=0,targetMargin=0;if(!title&&props.tileSizeCalc)try{fontSize$1||=getFontSize();let size$3=props.tileSizeCalc({contWidth,contHeight,fontSize:fontSize$1,layout:layoutSelected.value});if(size$3&&typeof size$3==`object`){let isPx=size$3.unit===`px`;targetWidth=isPx?size$3.width/fontSize$1:size$3.width,targetHeight=isPx?size$3.height/fontSize$1:size$3.height,targetMargin=isPx?size$3.margin/fontSize$1:size$3.margin}}catch(err){logger_default.warn(`BngList: tileSizeCalc function error:`,err)}targetWidth||=title?props.titleWidth||props.targetTitleWidth:props.tileWidth||props.targetWidth,targetHeight||=title?props.titleHeight||props.targetTitleHeight:props.tileHeight||props.targetHeight,targetMargin||=title?props.titleMargin||props.targetTitleMargin:props.tileMargin||props.targetMargin,validNum(targetWidth)&&(res.width=targetWidth,valid.width=!0),validNum(targetHeight)&&(res.height=targetHeight,valid.height=!0),validNum(targetMargin)&&(res.margin=targetMargin,valid.margin=!0);let em2px=em=>(fontSize$1||=getFontSize(),em*fontSize$1);if(valid.width&&res.width&&(res.width=em2px(res.width)),valid.height&&res.height&&(res.height=em2px(res.height)),valid.margin&&res.margin&&(res.margin=em2px(res.margin)),!valid.width||bigmode.enabled&&!valid.height||!valid.margin){if(res.el instanceof HTMLElement){let style=window.getComputedStyle(res.el,null);valid.width||(res.width=+style.width.substring(0,style.width.length-2)),valid.height||(res.height=+style.height.substring(0,style.height.length-2)),valid.margin||(res.margin=[style.marginTop,style.marginRight,style.marginBottom,style.marginLeft].map(m=>+m.substring(0,m.length-2)).sort((a$1,b)=>b-a$1)[0])}else logger_default.warn(`BngList cannot access ${title?`title`:`tile`} element for size auto-detection!`);warnShown||(warnShown=!0,logger_default.debug(`BigList was not provided with ${title?`title`:`target`} sizes (from props or from ${title?`title`:`tile`} component export) and attempted to auto-detect them. This may lead to some size micro-adjustments visible to user or invalid sizes. Please specify ${title?`title`:`target`} sizes manually.`),(res.width<1||res.height<1)&&logger_default.debug(`BigList noticed a detected ${title?`title`:``} size being too low: width = ${res.width}, height = ${res.height}`))}return res}let validNum=num=>typeof num==`number`&&!isNaN(num),getFontSize=()=>{if(!elCont.value)return 16;let size$3=window.getComputedStyle(elCont.value,null).fontSize;return+size$3.substring(0,size$3.length-2)||16},resizeObserver=new ResizeObserver(updSize);onMounted(()=>nextTick(()=>{resizeObserver.observe(elSize.value)})),onBeforeUnmount(()=>{elSize.value&&resizeObserver.unobserve(elSize.value),resizeObserver.disconnect()});let scrolling=ref(!1),scrollTmr,scrollTick=!1,onScrollDebounce=async()=>{scrollPos.value=bigmode.getPos[layoutSelected.value](),await updSkeleton()};watch(scrollPos,async pos=>{if(bigmode.enabled)if(bigmode.debounce>0)clearTimeout(scrollTmr),scrolling.value=!0,scrollTmr=setTimeout(async()=>{scrolling.value=!1,await calcBig(pos),await updSkeleton()},bigmode.debounce);else{if(scrollTick)return;scrollTick=!0,requestAnimationFrame(async()=>{scrollTick=!1,await calcBig(pos),await updSkeleton()})}});function vScroll(evt){evt.deltaY!==0&&elCont.value.scrollBy({left:evt.deltaY,behavior:`instant`})}function updSize(entries=[]){let oldContWidth=contWidth,oldContHeight=contHeight;tileWidth.value=0,tileHeight.value=0,titleWidth.value=0,titleHeight.value=0,tileProps?(tileMargin.value=validNum(tileProps.margin)?tileProps.margin:defTileMargin*fontSize,calcTiles(entries)):tileMargin.value=0,titleProps?(titleMargin.value=validNum(titleProps.margin)?titleProps.margin:defTitleMargin*fontSize,calcTitles(entries)):titleMargin.value=0,(Math.abs(oldContWidth-contWidth)>1||Math.abs(oldContHeight-contHeight)>1)&&invalidateLayoutCache(),bigmode.enabled&&!layoutCache.valid&&contWidth>0&&contHeight>0&&(!titleProps||titleWidth.value>0&&titleHeight.value>0)&&buildLayoutCache(),bigmode.enabled&&bigmode.initial&&(tileProps||titleProps)&&nextTick(async()=>{await calcBig(),await updSkeleton(),setTimeout(async()=>{await calcBig(),await updSkeleton()},50)}),elCont.value.removeEventListener(`mousewheel`,vScroll),layoutSelected.value===LIST_LAYOUTS.RIBBON&&elCont.value.addEventListener(`mousewheel`,vScroll)}function calcSizes(entries=[]){if(contWidth=0,contHeight=0,!elSize.value||!bigmode.enabled&&layoutSelected.value!==LIST_LAYOUTS.TILES)return!1;let baseMargin=tileMargin.value,rect=entries[0]?.contentRect||elSize.value.getBoundingClientRect();if(fontSize=getFontSize(),contWidth=rect.width,layoutSelected.value===LIST_LAYOUTS.RIBBON){let tileHeight$1=(tileProps?.height||5*fontSize)+baseMargin,titleHeight$1=titleProps?(titleProps.height||defTitleHeight*fontSize)+(titleProps.margin||defTitleMargin*fontSize):0;contHeight=Math.max(tileHeight$1,titleHeight$1)}else contHeight=rect.height-baseMargin;return!0}function calcTiles(entries=[]){if(!calcSizes(entries))return;let wantsWidth=layoutSelected.value===LIST_LAYOUTS.TILES||bigmode.enabled&&layoutSelected.value===LIST_LAYOUTS.RIBBON,wantsHeight=bigmode.enabled;if(!wantsWidth&&!wantsHeight)return;let baseMargin=tileMargin.value;if(wantsWidth){let baseWidth=tileProps.width||10*fontSize;if(contWidth>0&&layoutSelected.value===LIST_LAYOUTS.TILES){let prepWidth=baseWidth+baseMargin,amount=contWidth/prepWidth;amount<2?tileWidth.value=contWidth-baseMargin:tileWidth.value=(contWidth-baseMargin)/~~amount-baseMargin}else tileWidth.value=baseWidth}wantsHeight&&(tileHeight.value=tileProps.height||5*fontSize),bigmode.enabled&&bigmode.initial&&((!wantsWidth||contWidth>0)&&(!wantsHeight||contHeight>0)?(bigmode.initial=!1,calcBig(),updSkeleton()):window.requestAnimationFrame(()=>calcTiles()))}function calcTitles(){if(bigmode.enabled&&(fontSize=getFontSize()),!titleProps)return;let baseMargin=titleMargin.value,baseHeight=titleProps.height||defTitleHeight*fontSize;layoutSelected.value===LIST_LAYOUTS.RIBBON?titleWidth.value=titleProps.width||10*fontSize:titleWidth.value=contWidth-baseMargin;let oldTitleHeight=titleHeight.value;titleHeight.value=baseHeight,bigmode.enabled&&oldTitleHeight===0&&titleHeight.value>0&&contWidth>0&&contHeight>0&&(invalidateLayoutCache(),buildLayoutCache())}function clearLayoutCache(){layoutCache.totalSize=0,layoutCache.rows=[],layoutCache.itemToRow.clear(),layoutCache.rowPositions=[],layoutCache.valid=!0,layoutCache.building=!1,bigmode.enabled&&(bigmode.initial=!1,bigmode.full=0,bigmode.position=0,itemsView.value=[])}async function buildLayoutCache(){if(layoutCache.building){for(;layoutCache.building;)await sleep(10);return}if(items$2.value.length===0){clearLayoutCache();return}if(!tileProps&&!titleProps||contWidth<=0||contHeight<=0)return;if(layoutCache.building=!0,layoutCache.version=Date.now(),layoutCache.itemCount=items$2.value.length,await sleep(0),layoutCache.rows=[],layoutCache.itemToRow.clear(),layoutCache.rowPositions=[],layoutCache.itemCount!==items$2.value.length&&(layoutCache.itemCount=0),layoutCache.itemCount===0){clearLayoutCache(),items$2.value.length>0&&buildLayoutCache();return}let baseTileMargin=tileProps?.margin||defTileMargin*fontSize,baseTitleMargin=titleProps?.margin||defTitleMargin*fontSize,horizontal=layoutSelected.value===LIST_LAYOUTS.RIBBON,tilesPerRow=layoutSelected.value===LIST_LAYOUTS.TILES?~~(contWidth/tileWidth.value):1,pos=0,first=0,curItems=0;function completeRow(i){let tileSize=horizontal?tileWidth.value:tileHeight.value,size$3=tileSize+baseTileMargin,row={pos,size:size$3,first,last:i-1};layoutCache.rows.push(row),layoutCache.rowPositions.push(pos);for(let j=first;j0&&(completeRow(i),curItems=0);let titleSize=horizontal?titleWidth.value:titleHeight.value,rowSize=titleSize+baseTitleMargin,row={pos,size:rowSize,first:i,last:i,isTitle:!0};layoutCache.rows.push(row),layoutCache.rowPositions.push(pos),layoutCache.itemToRow.set(i,layoutCache.rows.length-1);let nextMargin=items$2.value[i+1]?.isBngListTitle?baseTitleMargin:baseTileMargin;pos+=titleSize+nextMargin,first=i+1,curItems=0}else if(curItems++,curItems===1&&(first=i),curItems>=tilesPerRow){let tileSize=horizontal?tileWidth.value:tileHeight.value,size$3=tileSize+baseTileMargin,row={pos,size:size$3,first,last:i};layoutCache.rows.push(row),layoutCache.rowPositions.push(pos);for(let j=first;j<=i;j++)layoutCache.itemToRow.set(j,layoutCache.rows.length-1);let nextMargin=items$2.value[i+1]?.isBngListTitle?baseTitleMargin:baseTileMargin;pos+=tileSize+nextMargin,curItems=0,first=i+1}curItems>0&&completeRow(layoutCache.itemCount),pos+=items$2.value[layoutCache.itemCount-1]?.isBngListTitle?baseTitleMargin:baseTileMargin,layoutCache.totalSize=pos,layoutCache.valid=!0,layoutCache.building=!1}function invalidateLayoutCache(){layoutCache.valid=!1,layoutCache.version++}function layoutCacheSearch(arr,target){let left=0,right=arr.length-1;for(;left<=right;){let mid=~~((left+right)/2);arr[mid]<=target?left=mid+1:right=mid-1}return Math.max(0,right)}async function getBigProps(pos=void 0,index=void 0,overflow=void 0){let count$1=items$2.value.length;if(count$1===0)return;if((!layoutCache.valid||layoutCache.itemCount!==count$1)&&(await buildLayoutCache(),!layoutCache.valid))return null;(typeof index!=`number`||index<0)&&(index=void 0,typeof pos!=`number`&&(pos=bigmode.getPos[layoutSelected.value]()));let contSize=layoutSelected.value===LIST_LAYOUTS.RIBBON?contWidth:contHeight;typeof overflow!=`number`&&(overflow=bigmode.overflow);let overflowBefore=Math.ceil(overflow/2),overflowAfter=Math.floor(overflow/2),firstRow=0,currentPos=0;if(typeof index==`number`&&index>=0){let rowIndex=layoutCache.itemToRow.get(index);rowIndex!==void 0&&(firstRow=rowIndex,currentPos=layoutCache.rows[rowIndex].pos,pos=currentPos)}else firstRow=layoutCacheSearch(layoutCache.rowPositions,pos),currentPos=layoutCache.rows[firstRow]?.pos||0;let extendedFirstRow=firstRow,backwardCount=0;for(let i=firstRow-1;i>=0&&backwardCount=contSize));i++);let overflowCount=0;for(let i=lastRow+1;iprops.keepAlive){let center=big.first+(big.last-big.first)/2,farthest=Array.from(itemsShown.value).sort((a$1,b)=>Math.abs(b-center)-Math.abs(a$1-center)).slice(0,itemsShown.value.size-props.keepAlive);for(let idx of farthest)itemsShown.value.delete(idx)}big.items=Array.from(itemsShown.value).sort((a$1,b)=>a$1-b).map(idx=>{let item=items$2.value[idx];return idx>=big.first&&idx<=big.last?item:{...item,keepAliveStyle:`display: none !important;`}})}else itemsShown.value.size>0&&itemsShown.value.clear();bigmode.items=big.items,itemsView.value=big.items}}function showSkeleton(show=!0){skeletonShown!==show&&(show?elSkeleton.value.style.removeProperty(`display`):(skeletonItems.value=[],elSkeleton.value.style.setProperty(`display`,`none`,`important`)),skeletonShown=show)}async function updSkeleton(){if(!elSkeleton.value||!bigmode.enabled||!bigmode.skeleton||!scrolling.value||items$2.value.length===0||!layoutCache.valid){showSkeleton(!1);return}if(bigmode.first===0&&bigmode.last===items$2.value.length-1){showSkeleton(!1);return}let horizontal=layoutSelected.value===LIST_LAYOUTS.RIBBON,contSize=horizontal?contWidth:contHeight,pos=scrollPos.value,start,end;if(pos=bigmode.position||(end=i,visibleSize+=row.size,visibleSize>=contSize))break}let overflowCount=0;for(let i=end+1;i=bigmode.position);i++)end=i,overflowCount++;let neededSize=contSize+bigmode.skeletonOverflow*(horizontal?tileWidth.value:tileHeight.value),backwardSize=visibleSize;for(;start>0&&backwardSize=contSize));i++);let overflowCount=0;for(let i=end+1;i(openBlock(),createElementBlock(`div`,_hoisted_1$316,[toolbar.value.enabled?withDirectives((openBlock(),createElementBlock(`div`,_hoisted_2$257,[toolbar.value.path?(openBlock(),createBlock(Teleport,{key:0,disabled:!__props.pathTarget,to:__props.pathTarget},[createVNode(unref(bngBreadcrumbs_default),{ref_key:`elPath`,ref:elPath,items:__props.path,limit:__props.pathLimit,blur:!__props.noBackground,onClick:_cache[0]||=itm=>emit$1(`pathClick`,itm)},null,8,[`items`,`limit`,`blur`])],8,[`disabled`,`to`])):(openBlock(),createElementBlock(`div`,_hoisted_3$224)),toolbar.value.layout?(openBlock(),createBlock(Teleport,{key:2,disabled:!__props.layoutSelectorTarget,to:__props.layoutSelectorTarget},[createBaseVNode(`div`,_hoisted_4$192,[createVNode(unref(bngButton_default),{accent:layoutSelected.value===LIST_LAYOUTS.TILES?unref(ACCENTS).outlined:unref(ACCENTS).text,icon:unref(icons).tiles,onClick:_cache[1]||=$event=>layoutSelected.value=LIST_LAYOUTS.TILES},null,8,[`accent`,`icon`]),createVNode(unref(bngButton_default),{accent:layoutSelected.value===LIST_LAYOUTS.LIST?unref(ACCENTS).outlined:unref(ACCENTS).text,icon:unref(icons).listSmall,onClick:_cache[2]||=$event=>layoutSelected.value=LIST_LAYOUTS.LIST},null,8,[`accent`,`icon`])])],8,[`disabled`,`to`])):createCommentVNode(``,!0)],512)),[[vShow,toolbar.value.show]]):createCommentVNode(``,!0),withDirectives((openBlock(),createElementBlock(`div`,{ref_key:`elCont`,ref:elCont,class:normalizeClass({"list-content":!0,"list-with-background":!__props.noBackground,[`list-layout-${layoutSelected.value}`]:!0,"list-item-width":!!tileWidth.value,"list-item-height":!!tileHeight.value,"list-item-margin":!!tileMargin.value,"list-title-width":!!titleWidth.value,"list-title-height":!!titleHeight.value,"list-title-margin":!!titleMargin.value,"list-big":bigmode.enabled,"list-scrolling":scrolling.value||bigmode.debounce===0,"list-processing":processing.value}),style:normalizeStyle({"--list-item-width":`${tileWidth.value}px`,"--list-item-height":`${tileHeight.value}px`,"--list-item-margin":`${tileMargin.value}px`,"--list-title-width":`${titleWidth.value}px`,"--list-title-height":`${titleHeight.value}px`,"--list-title-margin":`${titleMargin.value}px`,"--list-big-full":`${bigmode.full}px`}),onScroll:onScrollDebounce},[createBaseVNode(`div`,{ref_key:`elSize`,ref:elSize,class:`list-content-size-observer`},null,512),bigmode.enabled&&bigmode.skeleton?(openBlock(),createElementBlock(`div`,{key:0,ref_key:`elSkeleton`,ref:elSkeleton,class:`list-skeleton`},[(openBlock(!0),createElementBlock(Fragment,null,renderList(skeletonItems.value,(isTitle,i)=>(openBlock(),createElementBlock(`div`,{key:`skeleton-${i}`,class:normalizeClass({"skeleton-item":!0,"skeleton-title":isTitle})},null,2))),128))],512)):createCommentVNode(``,!0),createBaseVNode(`div`,{class:`list-items`,style:normalizeStyle(listItemsStyle.value)},[(openBlock(!0),createElementBlock(Fragment,null,renderList(itemsView.value,vnode=>(openBlock(),createBlock(resolveDynamicComponent(vnode),{key:vnode.key,style:normalizeStyle(vnode.keepAliveStyle)},null,8,[`style`]))),128))],4)],38)),[[unref(BngBlur_default),!__props.noBackground]])]))}},bngList_default=__plugin_vue_export_helper_default(_sfc_main$361,[[`__scopeId`,`data-v-5af5eff2`]]),_hoisted_1$315={class:`bng-stars`},_hoisted_2$256={key:0,class:`stars`},_hoisted_3$223=[`innerHTML`],_hoisted_4$191=[`innerHTML`],_hoisted_5$163={key:1,class:`stars`},_hoisted_6$140={class:`stars-label`},_hoisted_7$122=[`innerHTML`],_sfc_main$360={__name:`bngMainStars`,props:{unlockedStars:{type:Number,default:0,validator:val=>val>=0},totalStars:{type:Number,default:1},scale:{type:Number,default:1},individualStars:{type:Object,default:null,validator:val=>val===null||Array.isArray(val)},numerical:{type:Boolean,default:!1}},setup(__props){useCssVars(_ctx=>({v3c930dd6:fontSize.value}));let props=__props,fontSize=computed(()=>`${props.scale}rem`),starsTotal=computed(()=>props.individualStars?props.individualStars.length:props.totalStars),starsFilled=computed(()=>props.individualStars?props.individualStars.filter(Boolean).length:props.unlockedStars),starsUnfilled=computed(()=>starsTotal.value-starsFilled.value),glyphsFilled=computed(()=>starsFilled.value>0?icons.star.glyph.repeat(starsFilled.value):``),glyphsUnfilled=computed(()=>starsUnfilled.value>0?icons.star.glyph.repeat(starsUnfilled.value):``);return(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$315,[!__props.numerical&&__props.individualStars&&__props.individualStars.length?(openBlock(),createElementBlock(`div`,_hoisted_2$256,[starsFilled.value?(openBlock(),createElementBlock(`span`,{key:0,class:`star star-filled`,innerHTML:glyphsFilled.value},null,8,_hoisted_3$223)):createCommentVNode(``,!0),starsUnfilled.value?(openBlock(),createElementBlock(`span`,{key:1,class:`star star-unfilled`,innerHTML:glyphsUnfilled.value},null,8,_hoisted_4$191)):createCommentVNode(``,!0)])):(openBlock(),createElementBlock(`div`,_hoisted_5$163,[createBaseVNode(`div`,_hoisted_6$140,toDisplayString(starsFilled.value)+` / `+toDisplayString(starsTotal.value),1),createBaseVNode(`span`,{class:`star star-filled`,innerHTML:unref(icons).star.glyph},null,8,_hoisted_7$122)]))]))}},bngMainStars_default=__plugin_vue_export_helper_default(_sfc_main$360,[[`__scopeId`,`data-v-4ba4c794`]]),_hoisted_1$314=[`rows`,`placeholder`,`disabled`],_hoisted_2$255={key:0,class:`floating-label`},_sfc_main$359={__name:`bngMultilineInput`,props:{floatingLabel:String,externalLabel:String,placeholder:String,initialValue:String,leadingIcon:Object,trailingIcon:Object,scalable:Boolean,hasError:Boolean,errorMessage:String,lines:{type:Number,default:1},disabled:{type:Boolean,default:!1}},setup(__props){useCssVars(_ctx=>({v26daab40:bngScalableInputMaxWidth.value}));let props=__props,inputContainer=ref(null),bngMultilineInput=ref(null),focusHighlight=ref(null),leadingIconContainer=ref(null),trailingIconContainer=ref(null),value=ref(``),isInputFieldFocused=ref(!1),hasValue=computed(()=>value.value!==``&&value.value!==void 0),bngScalableInputMaxWidth=computed(()=>`${(leadingIconContainer.value?leadingIconContainer.value.offsetWidth:0)+(trailingIconContainer.value?trailingIconContainer.value.offsetWidth:0)}px`),resizeObserver;onBeforeMount(()=>{value.value=props.initialValue,resizeObserver=new ResizeObserver(onInputResize)}),onMounted(()=>{resizeObserver.observe(bngMultilineInput.value)}),onDeactivated(()=>{resizeObserver.disconnect()});function onInputFieldFocusIn(){isInputFieldFocused.value=!0}function onInputFieldFocusOut(){isInputFieldFocused.value=!1}function onInputResize(){inputContainer.value&&window.requestAnimationFrame(()=>{let focusRight=inputContainer.value.offsetWidth-inputContainer.value.offsetWidth;focusHighlight.value.style.right=`${focusRight-2}px`})}return(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,{class:normalizeClass([`input-icon-wrapper`,{scalable:__props.scalable}])},[__props.leadingIcon?(openBlock(),createElementBlock(`span`,{key:0,ref_key:`leadingIconContainer`,ref:leadingIconContainer,class:`input-icon`},[createVNode(unref(bngIcon_default),{type:__props.leadingIcon},null,8,[`type`])],512)):createCommentVNode(``,!0),createBaseVNode(`div`,{ref_key:`inputContainer`,ref:inputContainer,class:normalizeClass([`bng-multiline-input`,{"input-focused":isInputFieldFocused.value,"has-error":__props.hasError}]),tabindex:`0`},[withDirectives(createBaseVNode(`textarea`,{"onUpdate:modelValue":_cache[0]||=$event=>value.value=$event,ref_key:`bngMultilineInput`,ref:bngMultilineInput,class:normalizeClass([`input-field`,{empty:!hasValue.value,"has-value":hasValue.value,"has-error":__props.hasError,disabled:__props.disabled}]),rows:__props.lines,placeholder:__props.floatingLabel,disabled:__props.disabled,onFocusin:onInputFieldFocusIn,onFocusout:onInputFieldFocusOut},null,42,_hoisted_1$314),[[vModelText,value.value],[unref(BngTextInput_default)]]),__props.floatingLabel?(openBlock(),createElementBlock(`span`,_hoisted_2$255,toDisplayString(__props.floatingLabel),1)):createCommentVNode(``,!0),createBaseVNode(`span`,{ref_key:`focusHighlight`,ref:focusHighlight,class:`focus-highlight`},null,512)],2),__props.trailingIcon?(openBlock(),createElementBlock(`span`,{key:1,ref_key:`trailingIconContainer`,ref:trailingIconContainer,class:`input-icon`},[createVNode(unref(bngIcon_default),{type:__props.trailingIcon},null,8,[`type`])],512)):createCommentVNode(``,!0)],2))}},bngMultilineInput_default=__plugin_vue_export_helper_default(_sfc_main$359,[[`__scopeId`,`data-v-6c6cfdb8`]]);const icons$1={undefined:`undefined`,arrow:{large:{up:`arrow/large_up`,down:`arrow/large_down`,left:`arrow/large_left`,right:`arrow/large_right`},small:{up:`arrow/arrowSmallUp`,down:`arrow/arrowSmallDown`,left:`arrow/arrowSmallLeft`,right:`arrow/arrowSmallRight`}},drive:{autobahn:`drive/autobahn`,busroutes:`drive/busroutes`,campaigns:`drive/campaigns`,career:`drive/career`,freeroam:`drive/freeroam`,garage:`drive/garage`,infinity:`drive/infinity`,lightrunner:`drive/lightrunner`,m_a:`drive/m_a`,m_b:`drive/m_b`,m_c:`drive/m_c`,play:`drive/play`,quit:`drive/quit`,scenarios:`drive/scenarios`,timetrials:`drive/timetrials`},general:{offbtn:`general/offbtn`,unknown:`general/unknown`,check:`general/check`,recharge:`general/recharge`,refuel:`general/refuel`,beambuck:`general/beambuck`,money:`general/beambuck`,beamXP:`general/beamXP`,arrow_small_left:`general/arrow_small-left`,arrow_small_right:`general/arrow_small-right`,fuel_nozzle:`general/fuel-nozzle`,recharge_connector:`general/recharge-connector`,star:`general/star`,star_outlined:`general/star-secondary`,vehicle:`general/vehicle`,awd:`general/awd`,"4wd":`general/4wd`,fwd:`general/fwd`,rwd:`general/rwd`,drivetrain_special:`general/drivetrain-special`,drivetrain_generic:`general/drivetrain-generic`,charge:`general/charge`,fuel:`general/fuel`,odometer:`general/odometer`,power_gauge_01:`general/power-gauge-01c`,power_gauge_02:`general/power-gauge-02c`,power_gauge_03:`general/power-gauge-03c`,power_gauge_04:`general/power-gauge-04c`,power_gauge_05:`general/power-gauge-05c`,weight:`general/weight`,transmission_a:`general/transmission-a`,transmission_m:`general/transmission-m`},device:{keyboard:`device/keyboard`,phone_android:`device/phone_android`,wheel:`device/wheel`,gamepad:`device/gamepad`,videogame_asset:`device/videogame_asset`,mouse:{button0:`device/mouse/button0`,button1:`device/mouse/button1`,button2:`device/mouse/button2`,xaxis:`device/mouse/xaxis`,yaxis:`device/mouse/yaxis`,zaxis:`device/mouse/zaxis`},xbox:{btn_a:`device/xbox/btn_a`,btn_b:`device/xbox/btn_b`,btn_back:`device/xbox/btn_back`,btn_lb:`device/xbox/btn_lb`,btn_lt:`device/xbox/btn_lt`,btn_rb:`device/xbox/btn_rb`,btn_rt:`device/xbox/btn_rt`,btn_start:`device/xbox/btn_start`,btn_x:`device/xbox/btn_x`,btn_y:`device/xbox/btn_y`,btn_dpad_default_filled:`device/xbox/btn_dpad_default_filled`,btn_dpad_default_outline:`device/xbox/btn_dpad_default_outline`,btn_dpad_down:`device/xbox/btn_dpad_down`,btn_dpad_left:`device/xbox/btn_dpad_left`,btn_dpad_right:`device/xbox/btn_dpad_right`,btn_dpad_up:`device/xbox/btn_dpad_up`,btn_thumb_left:`device/xbox/btn_thumb_left`,btn_thumb_left_x:`device/xbox/btn_thumb_left_x`,btn_thumb_left_y:`device/xbox/btn_thumb_left_y`,btn_thumb_right:`device/xbox/btn_thumb_right`,btn_thumb_right_x:`device/xbox/btn_thumb_right_x`,btn_thumb_right_y:`device/xbox/btn_thumb_right_y`}},decals:{camera:{back:`decals/camera/back`,freecam:`decals/camera/freecam`,front:`decals/camera/front`,left:`decals/camera/left`,right:`decals/camera/right`,top:`decals/camera/top`},general:{change_order:`decals/general/change_order`,deform:`decals/general/deform`,delete:`decals/general/delete`,duplicate:`decals/general/duplicate`,hide:`decals/general/hide`,lock:`decals/general/lock`,mirror:`decals/general/mirror`,options:`decals/general/options`,redo:`decals/general/redo`,rename:`decals/general/rename`,save:`decals/general/save`,transform:`decals/general/transform`,undo:`decals/general/undo`,unlock:`decals/general/unlock`,use_mask:`decals/general/mask`},group:{group:`decals/group/group`,ungroup:`decals/group/ungroup`},layer:{decal:`decals/layer/decal`,material:`decals/layer/material`},mirror:{copy_mirrored:`decals/mirror/copy_mirrored`,copy_straight:`decals/mirror/copy_straight`}}},iconTypesList=makeIconTypesList(icons$1);function makeIconTypesList(dict){let key,all=[];for(key in dict)all=all.concat(typeof dict[key]==`string`?dict[key]:makeIconTypesList(dict[key]));return all}var _hoisted_1$313=[`src`],_sfc_main$358={__name:`bngOldIcon`,props:{type:{type:String,validator:v=>iconTypesList.includes(v)},span:{type:Boolean,default:!0},mask:{type:Boolean,default:!0},color:String},setup(__props){let props=__props,iconImageURL=computed(()=>getAssetURL(`icons/${props.type}.svg`)),spanStyle=computed(()=>({[props.mask?`maskImage`:`backgroundImage`]:`url(${iconImageURL.value})`,backgroundColor:props.color||`#fff`}));return(_ctx,_cache)=>__props.span?(openBlock(),createElementBlock(`span`,{key:0,class:`bngicon`,style:normalizeStyle(spanStyle.value)},[renderSlot(_ctx.$slots,`default`,{},void 0,!0)],4)):(openBlock(),createElementBlock(`img`,{key:1,class:`bngicon`,src:iconImageURL.value,alt:``},null,8,_hoisted_1$313))}},bngOldIcon_default=__plugin_vue_export_helper_default(_sfc_main$358,[[`__scopeId`,`data-v-da0e0a74`]]),_hoisted_1$312=[`bng-no-child-nav`],scrollBuildupTime=3e3,scrollMaxSpeedModifier=4,CLICKID=`__bngOverflowContainer`,_sfc_main$357={__name:`bngOverflowContainer`,props:{scrollSpeed:{type:Number,default:5},initialIndex:{type:Number,default:-1},useBindings:[Boolean,Array],useBindingsOnly:[Boolean,Array],showBindings:{type:Boolean,default:!0},showArrows:{type:Boolean,default:!1},noWheel:{type:Boolean,default:!1}},setup(__props,{expose:__expose}){let slots=useSlots(),props=__props,useBindings=props.useBindings||props.useBindingsOnly,useBindingsOnly=props.useBindingsOnly;watch([()=>props.useBindings,()=>props.useBindingsOnly],()=>console.warn(`useBindings and useBindingsOnly can only be set at component mount time`));let uinavBound=!1,focusNav=useBindings&&Array.isArray(useBindings)?useBindings:[`tab_l`,`tab_r`],elBindPrev=ref(null),elBindNext=ref(null),elCont=ref(null),scrollContainer=ref(null),showLeftFade=ref(!1),showRightFade=ref(!1),resizeObserver=new ResizeObserver(updateFadeVisibility),scrollInterval=null,scrollTime=0,lastActive=null,fixingActive=!1;function setActive(elm){clearActive(),elm instanceof Element&&(elm.setAttribute(`active`,`true`),lastActive=elm)}function clearActive(evt){lastActive&&(evt&&(evt.detail?.target||evt.target)===lastActive||(lastActive.removeAttribute(`active`),lastActive=null))}function fixActive(evt){if(fixingActive||useBindings&&evt.type===`focusin`)return;let active=evt.detail?.target||evt.target||document.activeElement;if(active.matches(`[is-bng-panel], [bng-nav-item], [ng-click], [href], [bng-all-clicks], [bng-all-clicks-no-nav], [ui-sref], input, textarea, button, md-option, md-slider, md-select, md-checkbox`)||(active=active.closest(NAVIGABLE_ELEMENTS_SELECTOR)),scrollContainer.value.contains(active)&&!(lastActive&&(lastActive===active||lastActive.contains(active)))){if(useBindingsOnly){fixingActive=!0;let prev=evt.detail.relatedTarget||evt.relatedTarget;prev&&scrollContainer.value.contains(prev)&&(prev=null),prev?setFocusExternal(prev,!0):setFocusExternal(active,!1)}nextTick(()=>{setActive(active),fixingActive=!1})}}let firstTime=!0;function updateContents(){if(!scrollContainer.value)return;let elFirst;for(let elm of scrollContainer.value.children)firstTime&&!elFirst&&(elFirst=elm),!elm[CLICKID]&&(elm[CLICKID]=!0,elm.addEventListener(`click`,fixActive));firstTime&&elFirst&&props.initialIndex>-1&&(firstTime=!1,elFirst.matches(`[is-bng-panel], [bng-nav-item], [ng-click], [href], [bng-all-clicks], [bng-all-clicks-no-nav], [ui-sref], input, textarea, button, md-option, md-slider, md-select, md-checkbox`)||(elFirst=elFirst.querySelector(NAVIGABLE_ELEMENTS_SELECTOR)),elFirst&&activate(elFirst))}watch([()=>slots.default?.(),()=>scrollContainer.value],()=>nextTick(updateContents),{immediate:!0});function navContents(dir,fireClick=!1){let links=collectRects(dir,scrollContainer.value,useBindingsOnly),prev=lastActive;clearActive();let res;if(useBindingsOnly){let idx=links[dir].findIndex(link=>link.dom===prev);idx>-1?res=links[dir][dir===`right`?idx+1:idx-1]:idx===0&&dir===`left`?res=links[dir][links[dir].length-1]:idx===links[dir].length-1&&dir===`right`&&(res=links[dir][0]),res&&(setActive(res.dom),scrollFix(res,dir))}else prev&&(res=navigate(links,dir,prev),res&&setActive(res));res?fireClick&&(res.dom&&(res=res.dom),nextTick(()=>res?.dispatchEvent(new Event(`click`)))):(scrollContainer.value.scrollTo({left:dir===`right`?0:scrollContainer.value.clientWidth,behavior:`instant`}),nextTick(()=>{let elms$4=collectRects(`right`,scrollContainer.value,!0).right;dir===`left`&&elms$4.reverse(),res=elms$4[0],res&&(setActive(res.dom),useBindingsOnly?scrollFix(res,dir):setFocusExternal(res.dom),fireClick&&res.dom.dispatchEvent(new Event(`click`)))}))}let activatePrev=()=>navContents(`left`,!0),activateNext=()=>navContents(`right`,!0);function activate(indexOrElement){let elm;if(typeof indexOrElement==`number`){let elms$4=scrollContainer.value.querySelectorAll(NAVIGABLE_ELEMENTS_SELECTOR);indexOrElement<0&&(indexOrElement=elms$4.length+indexOrElement),elm=elms$4[indexOrElement]}else if(indexOrElement instanceof Element)elm=indexOrElement;else throw Error(`Invalid argument`);if(!elm)throw Error(`Element not found`);scrollFix({dom:elm,rect:elm.getBoundingClientRect()},`right`),setActive(elm),!useBindingsOnly&&setFocusExternal(elm)}if(__expose({scrollBy:amount=>scrollContainer.value?.scrollBy({left:amount,behavior:`smooth`}),activatePrev,activateNext,activate,deactivate:()=>{let active=document.activeElement,activeCorrect=active&&active===lastActive;clearActive(),activeCorrect&&(useBindingsOnly&&setFocusExternal(active,!1),active.blur?.())},refresh:(withActivation=!1)=>{withActivation&&(firstTime=!0),updateContents()}}),useBindings){let instance$1=getCurrentInstance(),contUnwatch=watch(()=>elCont.value,elm=>{elm&&(contUnwatch(),nextTick(()=>{uinavBound=!0;let vnode={ctx:instance$1,el:elm};BngOnUiNav_default.mounted(elm,{arg:focusNav[0],modifiers:{},value:activatePrev},vnode),BngOnUiNav_default.mounted(elm,{arg:focusNav[1],modifiers:{},value:activateNext},vnode),elm.addEventListener(`focusin`,fixActive)}))},{immediate:!0})}watch(scrollContainer,elm=>{elm&&(updateFadeVisibility(),resizeObserver.observe(elm))},{immediate:!0});function updateFadeVisibility(){if(!scrollContainer.value)return;let{scrollLeft,scrollWidth,clientWidth}=scrollContainer.value;showLeftFade.value=scrollLeft>0,showRightFade.value=scrollLeft{let speedModifier=Math.min(1+(scrollMaxSpeedModifier-1)*(scrollTime/scrollBuildupTime),scrollMaxSpeedModifier),scrollAmount=(direction$1===`left`?-props.scrollSpeed:props.scrollSpeed)*speedModifier;scrollContainer.value.scrollLeft+=scrollAmount,updateFadeVisibility(),scrollTime+=1e3/30},1e3/30)}function stopScrolling(){scrollInterval&&=(clearInterval(scrollInterval),null),scrollTime=0}function onWheel(evt){props.noWheel||(evt.preventDefault(),scrollContainer.value.scrollLeft+=evt.deltaY,updateFadeVisibility())}function onScroll(){updateFadeVisibility()}return onBeforeUnmount(()=>{resizeObserver.disconnect(),stopScrolling(),uinavBound&&(BngOnUiNav_default.beforeUnmount(elCont.value),elCont.value.removeEventListener(`focusin`,fixActive))}),(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,{ref_key:`elCont`,ref:elCont,class:normalizeClass([`bng-overflow-container`,{"with-bindings":unref(useBindings)&&(elBindPrev.value?.displayed||elBindNext.value?.displayed),"with-arrows":__props.showArrows&&!(elBindPrev.value?.displayed||elBindNext.value?.displayed),"hide-bindings":!__props.showBindings}]),onWheel},[withDirectives(createBaseVNode(`div`,{class:`fade-left`,onMouseenter:_cache[0]||=$event=>startScrolling(`left`),onMouseleave:stopScrolling},null,544),[[vShow,showLeftFade.value]]),withDirectives(createBaseVNode(`div`,{class:`fade-right`,onMouseenter:_cache[1]||=$event=>startScrolling(`right`),onMouseleave:stopScrolling},null,544),[[vShow,showRightFade.value]]),__props.showArrows&&!elBindPrev.value?.displayed?(openBlock(),createBlock(unref(bngIcon_default),{key:0,type:unref(icons).arrowLargeLeft,class:`hint-prev`},null,8,[`type`])):createCommentVNode(``,!0),__props.showArrows&&!elBindNext.value?.displayed?(openBlock(),createBlock(unref(bngIcon_default),{key:1,type:unref(icons).arrowLargeRight,class:`hint-next`},null,8,[`type`])):createCommentVNode(``,!0),unref(useBindings)?(openBlock(),createBlock(unref(bngBinding_default),{key:2,ref_key:`elBindPrev`,ref:elBindPrev,class:`hint-prev`,"ui-event":unref(focusNav)[0],controller:``},null,8,[`ui-event`])):createCommentVNode(``,!0),unref(useBindings)?(openBlock(),createBlock(unref(bngBinding_default),{key:3,ref_key:`elBindNext`,ref:elBindNext,class:`hint-next`,"ui-event":unref(focusNav)[1],controller:``},null,8,[`ui-event`])):createCommentVNode(``,!0),createBaseVNode(`div`,{ref_key:`scrollContainer`,ref:scrollContainer,class:`scroll-container`,"bng-no-child-nav":unref(useBindingsOnly),onScroll},[renderSlot(_ctx.$slots,`default`,{},void 0,!0)],40,_hoisted_1$312)],34))}},bngOverflowContainer_default=__plugin_vue_export_helper_default(_sfc_main$357,[[`__scopeId`,`data-v-24544cbf`]]);const rainbow=(numOfSteps,step)=>{let r,g,b,h$1=step/numOfSteps,i=~~(h$1*6),f=h$1*6-i,q=1-f;switch(i%6){case 0:[r,g,b]=[1,f,0];break;case 1:[r,g,b]=[q,1,0];break;case 2:[r,g,b]=[0,1,f];break;case 3:[r,g,b]=[0,q,1];break;case 4:[r,g,b]=[f,0,1];break;case 5:[r,g,b]=[1,0,q];break}return[r,g,b]},hueToRGB=(p$1,q,t)=>(t<0&&(t+=1),t>1&&--t,t<1/6?p$1+(q-p$1)*6*t:t<1/2?q:t<2/3?p$1+(q-p$1)*(2/3-t)*6:p$1),HSLToRGB=(h$1,s,l)=>{let r,g,b;if(s===0)r=g=b=l;else{let q=l<.5?l*(1+s):l+s-l*s,p$1=2*l-q;r=hueToRGB(p$1,q,h$1+1/3),g=hueToRGB(p$1,q,h$1),b=hueToRGB(p$1,q,h$1-1/3)}return[r,g,b]},RGBToHSL=(r,g,b)=>{let vmax=Math.max(r,g,b),vmin=Math.min(r,g,b),h$1,s,l=(vmax+vmin)/2;if(vmax===vmin)return[0,0,l];let d=vmax-vmin;return s=l>.5?d/(2-vmax-vmin):d/(vmax+vmin),vmax===r&&(h$1=(g-b)/d+(gnum;else if(val<=15){let prec=10**val;this._precision=num=>~~(num*prec)/prec}else throw TypeError(`Precision can't go higher than 15`)}_sync({hsl=!1,rgb=!1}={}){if(hsl&&rgb)throw Error(`Cannot set both HSL and RGB changes at once`);this._dirty.hsl&&!hsl?this._rgb=HSLToRGB(...this._hsl):this._dirty.rgb&&!rgb&&(this._hsl=RGBToHSL(...this._rgb)),this._dirty.hsl=hsl,this._dirty.rgb=rgb}_parse(val){let res;if(isProxy(val)&&(val=toRaw(val)),typeof val==`string`&&(val=val.split(` `)),typeof val==`object`&&Array.isArray(val)){if(val.length<3)throw Error(`Invalid colour array length`);val.length===3&&(val=[...val,1]),val=val.map(Number);for(let num of val)if(isNaN(num))throw Error(`Values must be numbers`);res=val}if(!res)throw Error(`Color must be either an array or a string`);return res}get hslString(){return this.hsl.join(` `)}get hslaString(){return this.hsla.join(` `)}get rgbString(){return this.rgb.join(` `)}get rgbaString(){return this.rgba.join(` `)}get saturationPercent(){return Math.round(this.saturation*100)}get luminosityPercent(){return Math.round(this.luminosity*100)}get alphaPercent(){return Math.round(this._alpha*50)}get metallicPercent(){return Math.round(this._metallic*100)}get roughnessPercent(){return Math.round(this._roughness*100)}get clearcoatPercent(){return Math.round(this._clearcoat*100)}get clearcoatRoughnessPercent(){return Math.round(this._clearcoatRoughness*100)}get paint(){return[...this._legacy?this.rgba:this.rgb,this.metallic,this.roughness,this.clearcoat,this.clearcoatRoughness].map(this._precision)}get paintString(){return this.paint.join(` `)}get paintObject(){return this._paintObjectNames.reduce((res,name)=>({...res,[name]:this[name]}),{})}set paint(val){let data;if(isProxy(val)&&(val=toRaw(val)),typeof val==`object`){if(!Array.isArray(val)){data={...val};let names=this._paintObjectNames;for(let name of names){if(name===`baseColor`){this.baseColor=name in data?data[name]:[1,1,1,1];continue}let num=0;name in data&&(num=Number(data[name]),isNaN(num)&&(num=0)),this[name]=num}return}data=val}else if(typeof val==`string`)data=val.split(` `);else throw TypeError(`Invalid data type`);if(data.length===8)this.rgba=data.slice(0,4);else if(data.length===7)this.rgb=data.slice(0,3);else throw TypeError(`Invalid data value`);[this._metallic,this._roughness,this._clearcoat,this._clearcoatRoughness]=data.slice(-4)}get metallic(){return this._precision(this._metallic)}set metallic(val){this._metallic=Number(val)}get roughness(){return this._precision(this._roughness)}set roughness(val){this._roughness=Number(val)}get clearcoat(){return this._precision(this._clearcoat)}set clearcoat(val){this._clearcoat=Number(val)}get clearcoatRoughness(){return this._precision(this._clearcoatRoughness)}set clearcoatRoughness(val){this._clearcoatRoughness=Number(val)}get alpha(){return this._precision(this._alpha)}set alpha(val){let type=typeof val;type!==`undefined`&&(type===`number`?this._alpha=val:this._alpha=Number(val))}get hsl(){return this._sync(),this._hsl.map(this._precision)}set hsl(val){let arr=this._parse(val);this._sync({hsl:!0}),this._hsl=arr.slice(0,3),this.alpha=arr[3]}get rgb(){return this._sync(),this._rgb.map(this._precision)}get rgb255(){return this.rgb.map(val=>Math.round(val*255))}set rgb(val){let arr=this._parse(val);this._sync({rgb:!0}),this._rgb=arr.slice(0,3),this.alpha=arr[3]}set rgb255(val){let arr=this._parse(val);this.rgb=[...arr.slice(0,3).map(val$1=>val$1/255),arr[3]]}get hsla(){return[...this.hsl,this.alpha]}set hsla(val){this.hsl=val}get rgba(){return[...this.rgb,this.alpha]}set rgba(val){this.rgb=val}get baseColor(){return this.rgba}set baseColor(val){this.rgba=val}get hue(){return this.hsl[0]}get hue360(){return this.hsl[0]*360}set hue(val){this._sync({hsl:!0}),this._hsl[0]=Number(val)}set hue360(val){this.hue=Number(val)/360}get saturation(){return this.hsl[1]}set saturation(val){this._sync({hsl:!0}),this._hsl[1]=Number(val)}get luminosity(){return this.hsl[2]}set luminosity(val){this._sync({hsl:!0}),this._hsl[2]=Number(val)}get red(){return this.rgb[0]}get red255(){return this.rgb[0]*255}set red(val){this._sync({rgb:!0}),this._rgb[0]=Number(val)}set red255(val){this.red=Number(val)/255}get green(){return this.rgb[1]}get green255(){return this.rgb[1]*255}set green(val){this._sync({rgb:!0}),this._rgb[1]=Number(val)}set green255(val){this.green=Number(val)/255}get blue(){return this.rgb[2]}get blue255(){return this.rgb[2]*255}set blue(val){this._sync({rgb:!0}),this._rgb[2]=Number(val)}set blue255(val){this.blue=Number(val)/255}static anyToArray(val,legacy=!1){if(Array.isArray(val)){let checks=[val$1=>val$1 instanceof Paint,val$1=>typeof val$1==`object`&&Array.isArray(val$1.baseColor),val$1=>typeof val$1==`string`&&val$1.split(` `).length>=7,val$1=>Array.isArray(val$1)&&val$1.length>=7];if(val.some(item=>checks.some(check=>check(item))))return val.map(item=>Paint.anyToArray(item,legacy))}let precision=val$1=>{let num=Number(val$1);return isNaN(num)?val$1:~~(num*1e4)/1e4};return Array.isArray(val)?val.map(precision):typeof val==`string`?val.split(` `).map(precision):val instanceof Paint?val.paint:typeof val==`object`&&val.baseColor?[...legacy?val.baseColor:val.baseColor.slice(0,3),val.metallic,val.roughness,val.clearcoat,val.clearcoatRoughness].map(precision):val}static hslCssStr(arr){return`${Math.round(arr[0]*360)}, ${Math.round(arr[1]*100)}%, ${Math.round(arr[2]*100)}%`}static rgbToHsl(rgb){return RGBToHSL(...rgb)}static hslToRgb(hsl){return HSLToRGB(...hsl)}},CACHE_LIMIT=200,TILE_SIZE=64,MULTI_ANGLE=23,MAX_CONCURRENT_RENDERS=20,QUEUE_INTERVAL=10,reflectionImageUrl=`/ui/ui-vue/src/assets/images/paint-reflection.jpg`,reflectionImage=null,reflectionImageDone=!1,renderCancelledError=Error(`Render cancelled`),cacheCleanedError=Error(`Cache cleared`);function hashPaintData(paintData){return paintData?(paintData=Paint.anyToArray(paintData,!1),Array.isArray(paintData)?Array.isArray(paintData[0])?paintData.map(paint=>Array.isArray(paint)?paint.join(`,`):``).join(`|`):paintData.join(`,`):JSON.stringify(paintData)):``}var checkMultipaint=paintData=>Array.isArray(paintData)&&paintData.length>0&&paintData.some(item=>Array.isArray(item)&&item.length>=7);const usePaintPreviews=defineStore(`paint-previews`,()=>{let previews=ref(new Map),pendingRenders=ref(new Map),renderQueue=ref([]),activeRenders=ref(0),cacheListeners=new Set,pendingBlobCleanup=new Set,queueProcessor=null,blobCleanupTimeout=null;{let img=new Image;img.onload=()=>{reflectionImage=img,reflectionImageDone=!0},img.onerror=()=>{console.warn(`Failed to load metallic reflection image`),reflectionImageDone=!0},img.src=reflectionImageUrl}function startQueue(eager=!1){if(queueProcessor||renderQueue.value.length===0)return;let run$1=()=>{renderQueue.value.length===0?stopQueue():activeRenders.value0||activeRenders.value>0)return!1;for(let entry of previews.value.values())if(entry.blobGenerating)return!1;return!0}function blobCleanup(){blobCleanupTimeout&&clearTimeout(blobCleanupTimeout),blobCleanupTimeout=setTimeout(()=>{if(blobCleanupTimeout=null,isSystemIdle()&&pendingBlobCleanup.size>0){for(let blobUrl of pendingBlobCleanup)URL.revokeObjectURL(blobUrl);pendingBlobCleanup.clear()}},1e3)}async function processQueue({key,paintData,opts,resolve:resolve$1,reject,aborter}){activeRenders.value++;try{let checkAborted=()=>{if(aborter.signal.aborted)throw renderCancelledError};checkAborted();let width$1=opts.width||TILE_SIZE,height$1=opts.height||TILE_SIZE,areas=calculatePaintAreas(paintData,width$1,height$1),cvs=await renderPaint(paintData,width$1,height$1,opts.radialLight||!1,areas,aborter);checkAborted();let bmp=await createImageBitmap(cvs);if(previews.value.size>=CACHE_LIMIT){let oldestKey=previews.value.keys().next().value;cleanupCacheEntry(previews.value.get(oldestKey)),previews.value.delete(oldestKey)}checkAborted(),previews.value.set(key,{bitmap:bmp,paintData,paintHash:hashPaintData(paintData),areas}),resolve$1(bmp)}catch(err){err!==renderCancelledError&&reject(err)}finally{pendingRenders.value.has(key)&&pendingRenders.value.get(key).aborter===aborter&&pendingRenders.value.delete(key),activeRenders.value--}}function getCacheKey({paintId,vehicleName,paintName,width:width$1=TILE_SIZE,height:height$1=TILE_SIZE,radialLight=!1}){if(paintId)return`paint#${paintId}@${width$1}x${height$1}${radialLight?`R`:`L`}`;if(vehicleName&&paintName)return`vehicle:${vehicleName}:${paintName}@${width$1}x${height$1}${radialLight?`R`:`L`}`;throw Error(`Either paintId or vehicleName+paintName must be provided`)}function isCached(opts,paintData){try{let key=getCacheKey(opts),data=previews.value.get(key);return data?!paintData||data.paintHash===hashPaintData(paintData):!1}catch{return!1}}function getCachedPreview(opts,paintData){try{let key=getCacheKey(opts),data=previews.value.get(key);return data?data.paintHash===hashPaintData(paintData)?data.bitmap:(cleanupCacheEntry(data),previews.value.delete(key),null):null}catch{return null}}async function generatePreview(paintData,opts){let key=getCacheKey(opts),paintHash=hashPaintData(paintData);if(pendingRenders.value.has(key)){let existing=pendingRenders.value.get(key);if(existing.paintHash===paintHash)return new Promise((resolve$1,reject)=>existing.others.push({resolve:resolve$1,reject}));{existing.aborter.abort(),renderQueue.value=renderQueue.value.filter(item=>!(item.key===key&&item.aborter===existing.aborter));let aborter$1=new AbortController,others$1=[...existing.others];return pendingRenders.value.set(key,{paintHash,others:others$1,aborter:aborter$1}),new Promise((resolve$1,reject)=>{others$1.push({resolve:resolve$1,reject}),renderQueue.value.unshift({key,paintData:Paint.anyToArray(paintData),opts,resolve:result=>others$1.forEach(p$1=>p$1.resolve(result)),reject:error=>others$1.forEach(p$1=>p$1.reject(error)),aborter:aborter$1}),startQueue(!0)})}}let aborter=new AbortController,others=[];return pendingRenders.value.set(key,{paintHash,others,aborter}),new Promise((resolve$1,reject)=>{others.push({resolve:resolve$1,reject}),renderQueue.value.push({key,paintData:Paint.anyToArray(paintData),opts,resolve:result=>{others.forEach(p$1=>p$1.resolve(result))},reject:error=>{others.forEach(p$1=>p$1.reject(error))},aborter}),startQueue()})}function cleanupCacheEntry(data){data&&(data.bitmap?.close?.(),data.blobUrl&&pendingBlobCleanup.add(data.blobUrl))}function onCacheClear(callback){return cacheListeners.add(callback),()=>cacheListeners.delete(callback)}function notifyCacheCleared(type=`all`,key=null){cacheListeners.forEach(callback=>{try{callback(type,key)}catch(error){console.warn(`Cache clear listener error:`,error)}})}function clearCache(opts=void 0){if(opts)try{let key=getCacheKey(opts);if(cleanupCacheEntry(previews.value.get(key)),previews.value.delete(key),pendingRenders.value.has(key)){let req=pendingRenders.value.get(key);req.aborter.abort(),req.others.forEach(p$1=>p$1.reject(cacheCleanedError)),pendingRenders.value.delete(key)}notifyCacheCleared(`single`,key)}catch{}else stopQueue(),pendingRenders.value.forEach(req=>{req.aborter.abort(),req.others.forEach(p$1=>p$1.reject(cacheCleanedError))}),pendingRenders.value.clear(),previews.value.forEach(cleanupCacheEntry),previews.value.clear(),renderQueue.value.splice(0),activeRenders.value=0,notifyCacheCleared(`all`),startQueue();blobCleanup()}async function getPreview(paintData,opts){return getCachedPreview(opts,paintData)||await generatePreview(paintData,opts)}async function getBlobPreview(paintData,opts){let paintHash=hashPaintData(paintData),key=getCacheKey(opts),bmp=await getPreview(paintData,opts),data=previews.value.get(key);if(!data)return null;if(data.blobUrl&&data.paintHash===paintHash)return data.blobUrl;for(;data.blobGenerating;)await sleep(10);if(data.blobUrl&&data.paintHash===paintHash)return data.blobUrl;data.blobGenerating=!0;let canvas=new OffscreenCanvas(opts.width||TILE_SIZE,opts.height||TILE_SIZE);canvas.getContext(`2d`).drawImage(bmp,0,0);let blobUrl=URL.createObjectURL(await canvas.convertToBlob()),oldBlobUrl=data.blobUrl;return data.blobUrl=blobUrl,delete data.blobGenerating,oldBlobUrl&&pendingBlobCleanup.add(oldBlobUrl),previews.value.has(key)?(blobCleanup(),blobUrl):(pendingBlobCleanup.add(blobUrl),blobCleanup(),null)}function getAreas(opts){let data=previews.value.get(getCacheKey(opts));return data?data.areas:[]}return{cache:previews.value,cacheSize:computed(()=>previews.value.size),isRenderingAny:computed(()=>activeRenders.value>0||renderQueue.value.length>0),queueLength:computed(()=>renderQueue.value.length),activeRenders,isCached,clearCache,onCacheClear,getCacheKey,getPreview,getBlobPreview,getAreas,checkMultipaint,toArray:Paint.anyToArray}});async function renderPaint(paintData,width$1=TILE_SIZE,height$1=TILE_SIZE,radialLight=!1,areas=null,aborter=null){if(paintData=Paint.anyToArray(paintData),!paintData)return renderEmpty(width$1,height$1,aborter);if(checkMultipaint(paintData)){let clipData=areas||calculatePaintAreas(paintData,width$1,height$1);return renderMultipaint(paintData,width$1,height$1,clipData,radialLight,aborter)}else return paintData=Array.isArray(paintData[0])?paintData[0]:paintData,renderSinglePaint(paintData,width$1,height$1,radialLight,aborter)}function createPaint(paintData){let paint={_isEmpty:!0};if(!paintData)return paint;try{paint=new Paint({paint:paintData})}catch{}return paint}function applyAntialiasing(ctx){ctx.imageSmoothingEnabled=!0,ctx.imageSmoothingQuality=`high`,ctx.antialias=!0}function calculatePaintAreas(paintData,width$1,height$1){if(!paintData||!checkMultipaint(paintData))return[[0,0,width$1,height$1]];let paintCount=paintData.length,angle=Math.tan(MULTI_ANGLE*Math.PI/180),stripeWidth=(width$1+height$1*angle)/paintCount,overlap=.5,areas=[];for(let i=0;i0?overlap:0),topRight=startX+stripeWidth+(icoords.map((coord,i)=>coord*(i%2==0?scaleX:scaleY)));for(let i=0;igrad.addColorStop(...args))}else grad=ctx.createLinearGradient(0,0,0,height$1*.65),gradStops.forEach(args=>grad.addColorStop(...args));ctx.fillStyle=grad,ctx.fillRect(0,0,width$1,height$1),ctx.restore()}async function renderPaintLayers(ctx,paint,width$1,height$1,radialLight=!1,aborter=null){if(applyAntialiasing(ctx),ctx.fillStyle=`rgb(${(paint.rgb255||[255,255,255]).join(`, `)})`,ctx.fillRect(0,0,width$1,height$1),aborter?.signal.aborted)return;let grad=ctx.createLinearGradient(0,0,0,height$1);if(grad.addColorStop(0,`rgba(0, 0, 0, 0)`),grad.addColorStop(.65,`rgba(0, 0, 0, 0)`),grad.addColorStop(.8,`rgba(0, 0, 0, 0.15)`),grad.addColorStop(1,`rgba(0, 0, 0, 0.55)`),ctx.fillStyle=grad,ctx.fillRect(0,0,width$1,height$1),aborter?.signal.aborted)return;let metallic=Math.max(0,paint.metallic-paint.roughness/.5);if(metallic>.01){for(;!reflectionImageDone;){if(aborter?.signal.aborted)return;await sleep(10)}if(aborter?.signal.aborted)return;if(ctx.globalCompositeOperation=`multiply`,ctx.globalAlpha=metallic,reflectionImage){let scale=1,imageAspect=reflectionImage.width/reflectionImage.height,canvasAspect=width$1/height$1,drawWidth,drawHeight,offsetX=0,offsetY=0;imageAspect>canvasAspect?(drawHeight=height$1*1,drawWidth=height$1*imageAspect*1):(drawHeight=width$1/imageAspect*1,drawWidth=width$1*1),ctx.drawImage(reflectionImage,0,0,drawWidth,drawHeight)}else{ctx.strokeStyle=`rgba(255, 255, 255, 0.5)`,ctx.lineWidth=1;for(let x=-height$1;x({v889f200a:tileWidth.value,bee2d4dc:tileHeight.value}));let popover=usePopover(),props=__props,emit$1=__emit,mapId=uniqueId(`paint-tile-map`),menuId=uniqueId(`paint-tile-menu`),popMenu=ref(null),elCont=ref(null),elCanvas=ref(null),isLoading=ref(!1),isEmpty=ref(!1),hasRenderedOnce=ref(!1),paintPreviews=usePaintPreviews(),width$1=computed(()=>props.size||props.width),height$1=computed(()=>props.size||props.height),tileWidth=computed(()=>`${width$1.value}px`),tileHeight=computed(()=>`${height$1.value}px`),paints=computed(()=>props.paint?paintPreviews.toArray(props.paint):[]),isMultipaint=computed(()=>paintPreviews.checkMultipaint(paints.value)),paintNames=computed(()=>{let len=props.paint?.length||0;if(len===0)return[];let res=Array.from({length:len}).map((_,idx)=>({tooltip:[`ui.color.paint.unnamed`,{index:idx+1}],menu:[`ui.color.paint.selectOne`,{index:idx+1}],menuAdd:null}));if(props.paintNames?.length>0)for(let i=0;ihoveredPaintIndex.value=idx,tooltip=computed(()=>{let res={name:props.tooltip||props.paintName};return hoveredPaintIndex.value>-1&&paintNames.value[hoveredPaintIndex.value]&&(res.subname=paintNames.value[hoveredPaintIndex.value].tooltip),res}),customMenu=computed(()=>!props.customMenu||props.customMenu.length===0?null:props.customMenu.reduce((res,item,idx)=>item?[...res,{label:item.label||item,click:evt=>{popMenu.value?.hide?.(),nextTick(()=>{item.action?item.action(props.paint,evt):emit$1(`menu-click`,item.value||idx,props.paint,evt)})}}]:res,[])),withMenu=computed(()=>props.withMenu&&(paintAreas.value.length>1||customMenu.value)),opts=computed(()=>({paintId:props.paintId,vehicleName:props.vehicleName,paintName:props.paintName,width:width$1.value,height:height$1.value,radialLight:props.radialLight})),cacheKey=computed(()=>{try{return paintPreviews.getCacheKey(opts.value)}catch{return null}}),paintAreas=computed(()=>{if(!props.paint||isEmpty.value)return[];try{return paintPreviews.getAreas(opts.value)}catch{return[]}}),onContClick=evt=>onClick(-1,evt),onContRMB=()=>withMenu.value&&openMenu();function onClick(idx,evt){popMenu.value?.hide?.(),!props.disabled&&emit$1(`click`,idx,props.paint,evt)}function openMenu(){!elCont.value||!popMenu.value||(popover.hideAll(`paint-tile-menu`),!props.disabled&&popMenu.value.show(elCont.value))}async function renderPreview(){if(!cacheKey.value||!props.paint){isEmpty.value=!0,hasRenderedOnce.value=!1;return}isLoading.value=!0,isEmpty.value=!1;try{let bmp=await paintPreviews.getPreview(paints.value,opts.value);if(elCanvas.value&&bmp){let ctx=elCanvas.value.getContext(`2d`);ctx.clearRect(0,0,width$1.value,height$1.value),ctx.drawImage(bmp,0,0,width$1.value,height$1.value),hasRenderedOnce.value=!0}}catch(error){console.error(`Failed to render preview`,error),isEmpty.value=!0,hasRenderedOnce.value=!1}finally{isLoading.value=!1}}function checkEmpty(){if(!props.paint)return isEmpty.value=!0,hasRenderedOnce.value=!1,!0;if(isMultipaint.value){let allEmpty=paints.value.every(paintArray=>!paintArray||paintArray.length===0);return isEmpty.value=allEmpty,allEmpty&&(hasRenderedOnce.value=!1),allEmpty}return Array.isArray(paints.value)&&paints.value.length===0?(isEmpty.value=!0,hasRenderedOnce.value=!1,!0):(isEmpty.value=!1,!1)}watch(()=>[paints.value,props.paintId,props.vehicleName,props.paintName,width$1.value,height$1.value,props.radialLight],()=>{checkEmpty()?isLoading.value=!1:renderPreview()},{immediate:!0,deep:!0}),watch(()=>props.withAreas,val=>{val||(hoveredPaintIndex.value=-1)});let unsubscribeFromCacheClear=null,outEvents=[`click`,`contextmenu`,`uinav-focus`],listeningOutEvents=!1;function outOfMenu(evt){if(!popMenu.value||!popMenu.value.isShown())return;let el=popMenu.value.getElement();el&&el.contains(evt.detail?.target||evt.target)||nextTick(()=>popMenu.value.hide?.())}return watch(()=>popover.popovers[menuId]?.show,val=>{val?listeningOutEvents||(listeningOutEvents=!0,outEvents.forEach(evt=>document.addEventListener(evt,outOfMenu))):listeningOutEvents&&(listeningOutEvents=!1,outEvents.forEach(evt=>document.removeEventListener(evt,outOfMenu)))}),onMounted(()=>{!checkEmpty()&&renderPreview(),unsubscribeFromCacheClear=paintPreviews.onCacheClear((type,key)=>{(type===`all`||type===`single`&&key===cacheKey.value)&&!checkEmpty()&&hasRenderedOnce.value&&renderPreview()})}),onUnmounted(()=>{unsubscribeFromCacheClear?.(),listeningOutEvents&&outEvents.forEach(evt=>document.removeEventListener(evt,outOfMenu))}),(_ctx,_cache)=>withDirectives((openBlock(),createElementBlock(`div`,{ref_key:`elCont`,ref:elCont,class:normalizeClass([`bng-paint-tile`,{loading:isLoading.value&&!hasRenderedOnce.value,empty:isEmpty.value}]),tabindex:`0`,"bng-nav-item":``,onClick:withModifiers(onContClick,[`stop`]),onContextmenu:withModifiers(onContRMB,[`stop`])},[createBaseVNode(`canvas`,{ref_key:`elCanvas`,ref:elCanvas,width:width$1.value,height:height$1.value},null,8,_hoisted_1$311),__props.withAreas&&paintAreas.value.length>1?(openBlock(),createElementBlock(Fragment,{key:0},[createBaseVNode(`img`,{usemap:`#${unref(mapId)}`,src:unref(emptyImage),alt:``},null,8,_hoisted_2$254),createBaseVNode(`map`,{name:unref(mapId)},[(openBlock(!0),createElementBlock(Fragment,null,renderList(paintAreas.value,(area,index)=>(openBlock(),createElementBlock(`area`,{key:index,shape:`poly`,coords:area.join(`,`),onMouseover:$event=>onMouseOver(index),onMouseleave:_cache[0]||=$event=>onMouseOver(-1),onClick:withModifiers($event=>onClick(index,$event),[`stop`])},null,40,_hoisted_4$190))),128))],8,_hoisted_3$222)],64)):createCommentVNode(``,!0),isEmpty.value||isLoading.value&&!hasRenderedOnce.value?(openBlock(),createElementBlock(`div`,_hoisted_5$162)):createCommentVNode(``,!0),withMenu.value?(openBlock(),createBlock(unref(bngPopoverMenu_default),{key:2,ref_key:`popMenu`,ref:popMenu,name:unref(menuId),focus:``},{default:withCtx(()=>[paintNames.value.length>1?(openBlock(),createElementBlock(Fragment,{key:0},[withDirectives((openBlock(),createBlock(unref(bngButton_default),{accent:unref(ACCENTS).menu,onClick:_cache[1]||=$event=>onClick(-1,$event)},{default:withCtx(()=>[createTextVNode(toDisplayString(_ctx.$tt(`ui.color.paint.selectAll`)),1)]),_:1},8,[`accent`])),[[unref(BngOnUiNav_default),void 0,`ok`,{focusRequired:!0,asMouse:!0}]]),(openBlock(!0),createElementBlock(Fragment,null,renderList(paintNames.value,(paint,index)=>withDirectives((openBlock(),createBlock(unref(bngButton_default),{key:index,accent:unref(ACCENTS).menu,onClick:$event=>onClick(index,$event)},{default:withCtx(()=>[createTextVNode(toDisplayString(_ctx.$tt(...paintNames.value[index].menu))+toDisplayString(paintNames.value[index].menuAdd?`: `+paintNames.value[index].menuAdd:``),1)]),_:2},1032,[`accent`,`onClick`])),[[unref(BngOnUiNav_default),void 0,`ok`,{focusRequired:!0,asMouse:!0}]])),128))],64)):withDirectives((openBlock(),createBlock(unref(bngButton_default),{key:1,accent:unref(ACCENTS).menu,onClick:_cache[2]||=$event=>onClick(0,$event)},{default:withCtx(()=>[createTextVNode(toDisplayString(_ctx.$tt(`ui.color.paint.select`)),1)]),_:1},8,[`accent`])),[[unref(BngOnUiNav_default),void 0,`ok`,{focusRequired:!0,asMouse:!0}]]),customMenu.value?.length>0?(openBlock(!0),createElementBlock(Fragment,{key:2},renderList(customMenu.value,(item,index)=>withDirectives((openBlock(),createBlock(unref(bngButton_default),{key:index,accent:unref(ACCENTS).menu,onClick:$event=>item.click($event)},{default:withCtx(()=>[createTextVNode(toDisplayString(_ctx.$tt(item.label)),1)]),_:2},1032,[`accent`,`onClick`])),[[unref(BngOnUiNav_default),void 0,`ok`,{focusRequired:!0,asMouse:!0}]])),128)):createCommentVNode(``,!0)]),_:1},8,[`name`])):createCommentVNode(``,!0)],34)),[[unref(BngTooltip_default),_ctx.$tt(tooltip.value.name)+(tooltip.value.subname?` - `+_ctx.$tt(...tooltip.value.subname):``),__props.tooltipPosition],[unref(BngOnUiNav_default),void 0,`ok`,{asMouse:!0,focusRequired:!0}]])}},bngPaintTile_default=__plugin_vue_export_helper_default(_sfc_main$356,[[`__scopeId`,`data-v-25bf2552`]]),_hoisted_1$310=[`tabindex`],_sfc_main$355={__name:`bngPill`,props:{marked:{type:Boolean,default:!1}},setup(__props){let props=__props,attrs=useAttrs(),hasClickEvent=computed(()=>attrs&&attrs.onClick),isMarked=ref(props.marked);return watch(()=>props.marked,newValue=>isMarked.value=newValue),(_ctx,_cache)=>(openBlock(),createElementBlock(`span`,{"bng-nav-item":``,class:normalizeClass([`bng-pill`,{"pill-marked":isMarked.value,"pill-clickable":hasClickEvent.value}]),tabindex:hasClickEvent.value?0:-1},[renderSlot(_ctx.$slots,`default`,{},void 0,!0)],10,_hoisted_1$310))}},bngPill_default=__plugin_vue_export_helper_default(_sfc_main$355,[[`__scopeId`,`data-v-2d28d1ed`]]),_sfc_main$354={__name:`bngPillCheckbox`,props:{modelValue:{type:Boolean,default:null},markedIcon:{type:[Boolean,Object],default:!0}},emits:[`update:modelValue`,`valueChanged`,`change`],setup(__props,{emit:__emit}){let props=__props,emit$1=__emit,defaultValue=ref(!1),isChecked=computed({get:()=>props.modelValue!==void 0&&props.modelValue!==null?props.modelValue:defaultValue.value,set:newValue=>{props.modelValue!==void 0&&props.modelValue!==null?notifyListeners(newValue):(defaultValue.value=newValue,emit$1(`valueChanged`,newValue),emit$1(`change`,newValue))}}),onChecked=()=>isChecked.value=!isChecked.value;function notifyListeners(value){emit$1(`update:modelValue`,value),emit$1(`change`,value),emit$1(`valueChanged`,value)}return(_ctx,_cache)=>(openBlock(),createElementBlock(`span`,{class:normalizeClass([`bng-pill-checkbox`,{"show-icon":isChecked.value&&props.markedIcon}])},[createVNode(unref(bngPill_default),{marked:isChecked.value,onClick:onChecked,onKeyup:withKeys(onChecked,[`space`])},{default:withCtx(()=>[createBaseVNode(`span`,{class:normalizeClass({"pill-content":!0,"uses-mark":__props.markedIcon})},[renderSlot(_ctx.$slots,`default`,{},void 0,!0)],2),createVNode(unref(bngIcon_default),{class:`pill-mark-icon`,type:props.markedIcon===!0?unref(icons).checkmark:props.markedIcon||unref(icons).checkmark},null,8,[`type`])]),_:3},8,[`marked`])],2))}},bngPillCheckbox_default=__plugin_vue_export_helper_default(_sfc_main$354,[[`__scopeId`,`data-v-04487830`]]),_hoisted_1$309={class:`bng-pill-filters`,tabindex:`0`},_sfc_main$353={__name:`bngPillFilters`,props:{modelValue:Array,options:{type:Array,required:!0},selectOnFocus:Boolean,selectMany:Boolean,showCheckIcon:{type:Boolean,default:!0},required:Boolean},emits:[`update:modelValue`,`valueChanged`],setup(__props,{expose:__expose,emit:__emit}){let props=__props,emit$1=__emit;__expose({focusPrevious,focusNext,toggleFocusedPill,focusIndex});let scrollable=ref(null),pills=ref([]),currentPillIndex=ref(-1),defaultSelected=ref([]),selectedValues=computed({get:()=>props.modelValue?props.modelValue:defaultSelected.value,set:newValue=>{props.modelValue?(emit$1(`update:modelValue`,newValue),emit$1(`valueChanged`,newValue)):(defaultSelected.value=newValue,emit$1(`valueChanged`,newValue))}}),pillConfigs=computed(()=>toRaw(props.options).map(x=>({...x,selected:selectedValues.value&&selectedValues.value.length>0&&selectedValues.value.includes(x.value)})));function focusPrevious(){currentPillIndex.value=currentPillIndex.value>0?currentPillIndex.value-1:0,pills.value[currentPillIndex.value].querySelector(`.bng-pill`).focus(),console.log(`currentPillIndex.value`,currentPillIndex.value)}function focusNext(){currentPillIndex.value{scrollable.value.addEventListener(`wheel`,evt=>{evt.preventDefault(),scrollable.value.scrollLeft+=evt.deltaY}),currentPillIndex.value=selectedValues.value.length>0?pillConfigs.value.findIndex(x=>x.value===selectedValues.value[0]):-1,currentPillIndex.value>-1&&focusPill(currentPillIndex.value)});let onPillValueChanged=(key,value)=>{props.selectOnFocus||(console.log(`onPillValueChanged`,key,value),setPillValue(key,value))},onPillFocusIn=(key,index)=>{focusPill(index),props.selectOnFocus&&setPillValue(key,!(selectedValues.value.length>0&&selectedValues.value.includes(key)))};function setPillValue(key,checked){if(currentPillIndex.value=pillConfigs.value.findIndex(x=>x.value===key),props.required&&!checked&&selectedValues.value.includes(key)&&selectedValues.value.length==1){selectedValues.value=[key];return}if(!props.selectMany){selectedValues.value=checked?[key]:[];return}let isExisting=selectedValues.value.includes(key);checked&&!isExisting?selectedValues.value=[...selectedValues.value,key]:!checked&&isExisting&&(selectedValues.value=selectedValues.value.filter(x=>x!==key))}function focusPill(index){let pillEl=pills.value[index],scrollableRect=scrollable.value.getBoundingClientRect(),pillRect=pillEl.getBoundingClientRect();pillRect.left>=scrollableRect.left&&pillRect.right<=scrollableRect.right||window.requestAnimationFrame(()=>{scrollable.value.scrollBy({left:pillEl.getBoundingClientRect().right})})}return(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$309,[createBaseVNode(`div`,{class:`pills-wrapper`,ref_key:`scrollable`,ref:scrollable},[(openBlock(!0),createElementBlock(Fragment,null,renderList(pillConfigs.value,(pill,index)=>(openBlock(),createElementBlock(`div`,{key:pill.value,ref_for:!0,ref_key:`pills`,ref:pills,class:`pill-wrapper`},[createVNode(unref(bngPillCheckbox_default),{markedIcon:__props.showCheckIcon,modelValue:pill.selected,"onUpdate:modelValue":$event=>pill.selected=$event,onValueChanged:value=>onPillValueChanged(pill.value,value),onFocusin:$event=>onPillFocusIn(pill.value,index)},{default:withCtx(()=>[createTextVNode(toDisplayString(pill.label),1)]),_:2},1032,[`markedIcon`,`modelValue`,`onUpdate:modelValue`,`onValueChanged`,`onFocusin`])]))),128))],512)]))}},bngPillFilters_default=__plugin_vue_export_helper_default(_sfc_main$353,[[`__scopeId`,`data-v-580a9eac`]]),_sfc_main$352={__name:`bngPillFiltersContainer`,props:{options:{type:Array,required:!0},selectOnNavigation:{type:Boolean,default:!0},required:Boolean,selectMany:Boolean,hasCheckedIcon:{default:!0,type:Boolean}},emits:[`update:modelValue`,`valueChanged`],setup(__props,{expose:__expose,emit:__emit}){let emit$1=__emit,props=__props,selectedItems=ref([]),bngFiltersContainer=ref(null),filtersContainer=ref(null),bngPillFiltersRef=ref(null);__expose({selectPrevious:()=>bngPillFiltersRef.value.selectPrevious(),selectNext:()=>bngPillFiltersRef.value.selectNext(),selectCurrent:()=>bngPillFiltersRef.value.selectCurrent(),focusAndScrollToSelected:focusSelected});let selectedItemId=``;onMounted(()=>{filtersContainer.value.addEventListener(`wheel`,evt=>{evt.preventDefault(),filtersContainer.value.scrollLeft+=evt.deltaY})});function focusSelected(){props.selectMany||!props.selectOnNavigation||scrollToElement(selectedItemId)}function onContainerFocusOut($event){!($event.relatedTarget&&bngFiltersContainer.value.contains($event.relatedTarget))&&!props.selectMany&&selectedItemId&&scrollToElement(selectedItemId)}function onValueChanged(items$2,id){selectedItems.value=items$2,selectedItemId=id,emit$1(`valueChanged`,items$2,id)}function onPillItemFocusIn(id){scrollToElement(id)}function scrollToElement(id){let scrollableContainer=filtersContainer.value,el=scrollableContainer.querySelector(`#${id}`);if(el){let scrollableContainerRect=scrollableContainer.getBoundingClientRect(),itemRect=el.getBoundingClientRect();if(itemRect.left>=scrollableContainerRect.left&&itemRect.right<=scrollableContainerRect.right)return;window.requestAnimationFrame(()=>{let scrollValue=itemRect.left(openBlock(),createElementBlock(`div`,{class:`bng-filters-container`,ref_key:`bngFiltersContainer`,ref:bngFiltersContainer,tabindex:`0`,onFocusout:onContainerFocusOut},[_cache[0]||=createBaseVNode(`div`,{class:`fade-effect left-fade-effect`},null,-1),_cache[1]||=createBaseVNode(`div`,{class:`fade-effect right-fade-effect`},null,-1),createBaseVNode(`div`,{class:`scroll-container`,ref_key:`filtersContainer`,ref:filtersContainer},[createVNode(unref(bngPillFilters_default),{ref_key:`bngPillFiltersRef`,ref:bngPillFiltersRef,options:__props.options,"select-on-navigation":__props.selectOnNavigation,required:__props.required,"select-many":__props.selectMany,"show-checked-icon":__props.hasCheckedIcon,onValueChanged,onPillItemFocusIn},null,8,[`options`,`select-on-navigation`,`required`,`select-many`,`show-checked-icon`])],512)],544))}},bngPillFiltersContainer_default=__plugin_vue_export_helper_default(_sfc_main$352,[[`__scopeId`,`data-v-498af92b`]]),_hoisted_1$308=[`data-bng-popover-name`],containerSelector=`.popover-container`,_sfc_main$351={__name:`bngPopoverContent`,props:{name:String,offset:{type:Number,default:4},hideArrow:Boolean,placement:String,disabled:Boolean},emits:[`show`,`hide`,`placementChanged`],setup(__props,{expose:__expose,emit:__emit}){let props=__props,emit$1=__emit,popover=usePopover(),popoverName,popoverContent=ref(null),arrow$3=ref(null),show=ref(!1),unwatchShow,unwatchPlacement,teleportTargetExists=ref(!1),observer$2=null,scopeActivated=ref(!1),isRender=computed(()=>!props.disabled&&teleportTargetExists.value&&show.value),hide$2=()=>!props.disabled&&popover.hide(popoverName),expose={hide:hide$2,show:(el=void 0)=>!props.disabled&&popover.show(popoverName,el),toggle:(forceVal=void 0)=>popover.toggle(popoverName,!props.disabled&&forceVal),isShown:()=>popover.isShown(popoverName)};__expose(expose),watch(()=>show.value,value=>emit$1(value?`show`:`hide`,{name:props.name,...expose})),watch(()=>props.name,(newName,oldName)=>{oldName&&disposePopover(oldName),props.disabled||setupPopover()},{immediate:!0}),watch(()=>props.disabled,value=>{value?(popover.hide(popoverName),disposePopover(popoverName)):setupPopover()}),watch(isRender,async value=>{value&&(await nextTick(),checkSlotContent())});let onMenu=()=>{scopeActivated.value=!1};onBeforeUnmount(()=>{disposePopover(popoverName),observer$2&&=(observer$2.disconnect(),null)}),onMounted(async()=>{teleportTargetExists.value=!!document.querySelector(containerSelector),teleportTargetExists.value||(observer$2=new MutationObserver(()=>{!teleportTargetExists.value&&document.querySelector(containerSelector)&&(teleportTargetExists.value=!0,observer$2.disconnect(),observer$2=null)}),observer$2.observe(document.body,{childList:!0,subtree:!0})),isRender.value&&(await nextTick(),checkSlotContent())});function onScopeChanged(activated,event){scopeActivated.value=activated,!activated&&!event.detail.force&&popover.hide(popoverName)}function checkSlotContent(){let navigableElements=popoverContent.value.querySelectorAll(NAVIGABLE_ELEMENTS_SELECTOR);navigableElements&&navigableElements.length>0&&!scopeActivated.value&&(scopeActivated.value=!0)}function setupPopover(){popoverName=props.name||uniqueId(`bng-popover-content`);let res=popover.register(popoverName,popoverContent,props.placement,{arrow:props.hideArrow?void 0:arrow$3,offset:props.offset});res&&(unwatchShow=watch(res.show,value=>show.value=value),unwatchPlacement=watch(res.placement,placement=>emit$1(`placementChanged`,placement)))}function disposePopover(name){unwatchShow&&=(unwatchShow(),null),unwatchPlacement&&=(unwatchPlacement(),null),popover.unregister(name),show.value=!1,popoverName=null}return(_ctx,_cache)=>isRender.value?(openBlock(),createBlock(Teleport,{key:0,to:`.popover-container`},[withDirectives((openBlock(),createElementBlock(`div`,{ref_key:`popoverContent`,ref:popoverContent,"data-bng-popover-name":unref(popoverName),class:`bng-popover`,onActivate:_cache[0]||=$event=>onScopeChanged(!0,$event),onDeactivate:_cache[1]||=$event=>onScopeChanged(!1,$event)},[renderSlot(_ctx.$slots,`default`,{hide:hide$2},void 0,!0),__props.hideArrow?createCommentVNode(``,!0):(openBlock(),createElementBlock(`span`,{key:0,ref_key:`arrow`,ref:arrow$3,class:`bng-popover-arrow`},null,512))],40,_hoisted_1$308)),[[unref(BngScopedNav_default),{activated:scopeActivated.value,type:unref(SCOPED_NAV_TYPES).popover}],[unref(BngOnUiNav_default),onMenu,`menu`]])])):createCommentVNode(``,!0)}},bngPopoverContent_default=__plugin_vue_export_helper_default(_sfc_main$351,[[`__scopeId`,`data-v-4938e558`]]),_sfc_main$350=Object.assign({inheritAttrs:!1},{__name:`bngPopoverMenu`,props:{name:String,offset:{type:Number,default:4},hideArrow:Boolean,disabled:Boolean,focus:Boolean},emits:[`show`,`hide`,`placementChanged`],setup(__props,{expose:__expose,emit:__emit}){let popover=usePopover(),props=__props,emit$1=__emit,relay={show:(...args)=>emit$1(`show`,...args),hide:(...args)=>emit$1(`hide`,...args),placementChanged:(...args)=>emit$1(`placementChanged`,...args)},popoverContent=ref(null),popoverMenu=ref(null),hide$2=(...args)=>popoverContent.value.hide(...args);return __expose({hide:hide$2,show:(...args)=>popoverContent.value.show(...args),toggle:(...args)=>popoverContent.value.toggle(...args),isShown:(...args)=>popoverContent.value.isShown(...args),getElement:()=>popoverMenu.value}),watchEffect(()=>{if(props.name in popover.popovers){let pop=popover.popovers[props.name];!pop.show&&nextTick(()=>{pop.target&&document.activeElement===document.body&&setFocusExternal(pop.target,!0,!1)})}}),(_ctx,_cache)=>(openBlock(),createBlock(unref(bngPopoverContent_default),{ref_key:`popoverContent`,ref:popoverContent,name:__props.name,offset:__props.offset,"hide-arrow":__props.hideArrow,disabled:__props.disabled,onPlacementChanged:relay.placementChanged,onHide:hide$2},{default:withCtx(()=>[createBaseVNode(`div`,{ref_key:`popoverMenu`,ref:popoverMenu,class:`bng-popover-menu`},[renderSlot(_ctx.$slots,`default`,{hide:hide$2},void 0,!0)],512)]),_:3},8,[`name`,`offset`,`hide-arrow`,`disabled`,`onPlacementChanged`]))}}),bngPopoverMenu_default=__plugin_vue_export_helper_default(_sfc_main$350,[[`__scopeId`,`data-v-fe39553c`]]),_hoisted_1$307={class:`bng-progress-bar`},_hoisted_2$253={key:0,class:`header`},_hoisted_3$221={class:`header-left`},_hoisted_4$189={class:`header-right`},_hoisted_5$161={class:`progress-bar`},_hoisted_6$139=[`innerHTML`],_hoisted_7$121={key:1,class:`progress-fill-indeterminate`},_sfc_main$349={__name:`bngProgressBar`,props:{value:{type:Number,default:0},oldValue:{type:Number,default:0},min:{type:Number,default:0},max:{type:Number,required:!0},headerLeft:String,headerRight:String,showValueLabel:{type:Boolean,default:!0},valueLabelFormat:{type:[String,Function],default:`#value#`},valueColor:{type:String,default:`#ff6600`},oldValueColor:{type:String,default:`#ffffff`},indeterminate:Boolean,animateDifference:Boolean,gradient:Boolean},setup(__props,{expose:__expose}){useCssVars(_ctx=>({v5113e7b0:__props.valueColor,v14406f01:progressFillUnits.value,v6b373656:oldProgressFillUnits.value}));let props=__props;__expose({decreaseValueBy,increaseValueBy,setValue:value=>updateCurrentValue(value)});let currentValue=ref(null),valueHTML=computed(()=>{let res;return res=typeof props.valueLabelFormat==`function`?props.valueLabelFormat(props.value,{min:props.min,max:props.max}):props.valueLabelFormat.replace(/ +/g,` `).replace(`#value#`,`${currentValue.value}${props.max}`),res}),progressFillUnits=computed(()=>1-(currentValue.value-props.min)/(props.max-props.min)),oldProgressFillUnits=computed(()=>1-(props.oldValue-props.min)/(props.max-props.min));watch(()=>props.value,updateCurrentValue),onMounted(()=>{updateCurrentValue(props.min>props.value?props.min:props.value)});function decreaseValueBy(value){let newValue=currentValue.value-value;newValueprops.max&&(newValue=props.max),updateCurrentValue(newValue)}function updateCurrentValue(newValue){currentValue.value=newValue}return(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$307,[__props.headerLeft||__props.headerRight?(openBlock(),createElementBlock(`div`,_hoisted_2$253,[createBaseVNode(`span`,_hoisted_3$221,toDisplayString(__props.headerLeft),1),createBaseVNode(`span`,_hoisted_4$189,toDisplayString(__props.headerRight),1)])):createCommentVNode(``,!0),createBaseVNode(`div`,_hoisted_5$161,[__props.showValueLabel?(openBlock(),createElementBlock(`div`,{key:0,class:`info`,innerHTML:valueHTML.value},null,8,_hoisted_6$139)):createCommentVNode(``,!0),__props.indeterminate?(openBlock(),createElementBlock(`span`,_hoisted_7$121)):(openBlock(),createElementBlock(`span`,{key:2,class:normalizeClass({"progress-fill":!0,"progress-fill-gradient":__props.gradient,"animate-progress":__props.animateDifference&&__props.value>__props.oldValue}),style:normalizeStyle({backgroundColor:__props.valueColor,zIndex:__props.value<__props.oldValue?2:1})},null,6)),__props.oldValue?(openBlock(),createElementBlock(`span`,{key:3,class:normalizeClass({"second-progress-fill":!0,"progress-fill-gradient":__props.gradient,"animate-progress":__props.animateDifference&&__props.value<__props.oldValue}),style:normalizeStyle({backgroundColor:__props.oldValueColor,zIndex:__props.value<__props.oldValue?1:2})},null,6)):createCommentVNode(``,!0)])]))}},bngProgressBar_default=__plugin_vue_export_helper_default(_sfc_main$349,[[`__scopeId`,`data-v-1ca6aacd`]]);function shrinkNum(num,decimals=0){let units=[``,`K`,`M`,`B`,`T`,`Q`];if(!num)return`0`;if(isNaN(parseFloat(num))||!isFinite(+num))return`n/a`;let power$1=Math.floor(Math.log(Math.abs(+num))/Math.log(1e3));return power$1>=units.length&&(power$1=units.length-1),(num/1e3**power$1).toFixed(decimals).replace(/\.0+$/,``)+units[power$1]}var _hoisted_1$306={key:1,class:`key-label`},_hoisted_2$252={class:`value-label`},_sfc_main$348={__name:`bngPropVal`,props:{iconType:[String,Object],keyLabel:String,valueLabel:{required:!0},shrinkNum:Boolean,iconColor:{type:String,default:`#fff`},noGap:{type:Boolean,default:!1},noIcon:{type:Boolean,default:!1}},setup(__props){let props=__props,itemClass=computed(()=>({"info-item":!0,"with-icon":props.iconType,"no-key":!props.keyLabel,"no-gap":props.noGap})),value=computed(()=>{let i=props.valueLabel;return props.shrinkNum?shrinkNum(i,0):i});return(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,{class:normalizeClass(itemClass.value)},[__props.iconType&&!__props.noIcon?(openBlock(),createBlock(unref(bngIcon_default),{key:0,class:`icon`,type:__props.iconType,color:__props.iconColor},null,8,[`type`,`color`])):createCommentVNode(``,!0),__props.keyLabel?(openBlock(),createElementBlock(`span`,_hoisted_1$306,toDisplayString(__props.keyLabel),1)):createCommentVNode(``,!0),createBaseVNode(`span`,_hoisted_2$252,toDisplayString(value.value),1)],2))}},bngPropVal_default=__plugin_vue_export_helper_default(_sfc_main$348,[[`__scopeId`,`data-v-fa2e2062`]]),_hoisted_1$305={class:`header`},_sfc_main$347={__name:`bngScreenHeading`,props:{blurDelay:Number,preheadings:Array,divider:Boolean,type:{type:String,default:`line`,validator:v=>[`line`,`ribbon`].includes(v)||v===``}},setup(__props){let blurVal=ref(!1);onMounted(()=>window.setTimeout(()=>blurVal.value=!0,~~+props.blurDelay));let props=__props,preheadings=computed(()=>Array.isArray(props.preheadings)&&props.preheadings.length>0?props.preheadings:null);return(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,{class:normalizeClass([`bng-screen-heading`,{[`heading-style-${__props.type}`]:!0,prehead:preheadings.value}])},[preheadings.value?withDirectives((openBlock(),createElementBlock(`span`,{key:0,class:normalizeClass([`pre-header`,{"with-divider":__props.divider}])},[(openBlock(!0),createElementBlock(Fragment,null,renderList(preheadings.value,preheading=>(openBlock(),createElementBlock(`span`,{class:`location`,key:preheading},toDisplayString(preheading),1))),128))],2)),[[unref(BngBlur_default),blurVal.value]]):createCommentVNode(``,!0),withDirectives((openBlock(),createElementBlock(`h1`,_hoisted_1$305,[renderSlot(_ctx.$slots,`default`,{},void 0,!0)])),[[unref(BngBlur_default),blurVal.value]])],2))}},bngScreenHeading_default=__plugin_vue_export_helper_default(_sfc_main$347,[[`__scopeId`,`data-v-f6d9f077`]]),_hoisted_1$304={class:`header`},_hoisted_2$251={key:0,class:`decorator-item`,width:`100%`,height:`100%`,viewBox:`0 0 32 40`,preserveAspectRatio:`none`,fill:`none`,xmlns:`http://www.w3.org/2000/svg`},_hoisted_3$220={key:1,class:`decorator-item`,width:`100%`,height:`100%`,viewBox:`0 0 36 40`,preserveAspectRatio:`xMaxYMid slice`,fill:`none`,xmlns:`http://www.w3.org/2000/svg`},_hoisted_4$188={key:2,class:`decorator-item`,width:`100%`,height:`100%`,viewBox:`0 0 36 40`,preserveAspectRatio:`xMaxYMid slice`,fill:`none`,xmlns:`http://www.w3.org/2000/svg`},_sfc_main$346={__name:`bngScreenHeadingV2`,props:{blurDelay:Number,preheadings:Array,divider:Boolean,type:{type:String,default:`1`,validator:v=>[`1`,`2`,`3`].includes(v)||v===``},hintVisible:Boolean,hintLabel:String,hintIcon:String,hintAccent:String,hintBindingEvent:String},emits:[`hint`],setup(__props,{emit:__emit}){let blurVal=ref(!1);onMounted(()=>window.setTimeout(()=>blurVal.value=!0,~~+props.blurDelay));let props=__props,preheadings=computed(()=>Array.isArray(props.preheadings)&&props.preheadings.length>0?props.preheadings:null);return computed(()=>props.hintVisible??!1),computed(()=>props.hintLabel??``),computed(()=>props.hintIcon??icons.arrowLargeLeft),computed(()=>props.hintAccent??ACCENTS.outlined),(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,{class:normalizeClass([`bng-screen-heading`,{[`heading-style-${__props.type}`]:!0,prehead:preheadings.value}])},[renderSlot(_ctx.$slots,`preheadings`,{},void 0,!0),withDirectives((openBlock(),createElementBlock(`span`,_hoisted_1$304,[createBaseVNode(`div`,{class:normalizeClass(`decorator type${__props.type}`)},[__props.type===`1`?(openBlock(),createElementBlock(`svg`,_hoisted_2$251,[..._cache[0]||=[createBaseVNode(`path`,{d:`M16.6328 40H1.62891L14.0039 6H14.002L11.8174 0H26.8174L29.001 6H29.0078L16.6328 40Z`,fill:`var(--bng-orange-400)`},null,-1)]])):createCommentVNode(``,!0),__props.type===`2`?(openBlock(),createElementBlock(`svg`,_hoisted_3$220,[..._cache[1]||=[createBaseVNode(`path`,{d:`M18.6366 0H34.0094L26.73 20H11.3572L18.6366 0Z`,fill:`#DA5706`},null,-1),createBaseVNode(`path`,{d:`M19.4504 40H4.07812L11.3572 20L4.07812 0H19.4504L26.7295 20L19.4504 40Z`,fill:`var(--bng-orange-400)`},null,-1)]])):createCommentVNode(``,!0),__props.type===`3`?(openBlock(),createElementBlock(`svg`,_hoisted_4$188,[..._cache[2]||=[createBaseVNode(`path`,{d:`M18.6366 0H34.0094L26.73 20H11.3572L18.6366 0Z`,fill:`#DA5706`},null,-1),createBaseVNode(`path`,{d:`M19.4504 40H4.07812L11.3572 20L4.07812 0H19.4504L26.7295 20L19.4504 40Z`,fill:`var(--bng-orange-400)`},null,-1)]])):createCommentVNode(``,!0)],2),createBaseVNode(`h1`,null,[renderSlot(_ctx.$slots,`default`,{},void 0,!0)])])),[[unref(BngBlur_default),blurVal.value]])],2))}},bngScreenHeadingV2_default=__plugin_vue_export_helper_default(_sfc_main$346,[[`__scopeId`,`data-v-4854a8bd`]]),_hoisted_1$303={class:`label select`},_hoisted_2$250={class:`bng-select-indicator`},_sfc_main$345={__name:`bngSelect`,props:mergeModels({value:void 0,options:{type:Array,required:!0},config:{type:Object,default:()=>({value:opt=>opt,label:opt=>opt})},loop:Boolean,labelClickable:Boolean,labelPopover:String,disabled:Boolean,navLeftEvent:{type:String,default:`focus_l`},navRightEvent:{type:String,default:`focus_r`}},{modelValue:{type:[Object,Boolean,Number,String],default:void 0},modelModifiers:{}}),emits:mergeModels([`change`,`valueChanged`,`label-click`],[`update:modelValue`]),setup(__props,{expose:__expose,emit:__emit}){let leftBinding=ref(),rightBinding=ref(),vModel=useModel(__props,`modelValue`),props=__props,elContainer=ref(),elContent=ref(),findOptionValue=(valueToFind,opts)=>Math.max(0,opts.findIndex(opt=>props.config.value(opt)===valueToFind)),index=ref(getInitialValue()),current=computed(()=>({option:props.options[index.value],value:props.config.value(props.options[index.value]),label:props.config.label(props.options[index.value])})),leftIconClass=computed(()=>({"with-binding":leftBinding.value?.displayed})),rightIconClass=computed(()=>({"with-binding":rightBinding.value?.displayed})),isLeftDisabled=props.loop?!1:computed(()=>index.value==0),isRightDisabled=props.loop?!1:computed(()=>index.value==props.options.length-1),emit$1=__emit,goPrev=()=>{!props.disabled&&!isLeftDisabled.value&&changeIndex(-1)},goNext=()=>{!props.disabled&&!isRightDisabled.value&&changeIndex(1)};__expose({goNext,goPrev,getElement:()=>elContainer.value,getContentElement:()=>elContent.value}),watch(()=>props.value,()=>index.value=props.value!==null&&props.value!==void 0?findOptionValue(props.value,props.options):0),watch(vModel,val=>index.value=val==null?0:findOptionValue(val,props.options)),watch(()=>index.value,updateValue);function updateValue(){emit$1(`valueChanged`,current.value.value,current.value.label,current.value.option),emit$1(`change`,current.value.value,current.value.label,current.value.option),vModel.value=current.value.value}function changeIndex(offset$2){props.loop?index.value=(props.options.length+index.value+offset$2)%props.options.length:index.value=clamp(index.value+offset$2,0,props.options.length-1)}function getInitialValue(){return vModel.value!==null&&vModel.value!==void 0?findOptionValue(vModel.value,props.options):`value`in props?findOptionValue(props.value,props.options):0}return(_ctx,_cache)=>withDirectives((openBlock(),createElementBlock(`div`,{ref_key:`elContainer`,ref:elContainer,class:`bng-select`,"bng-nav-item":``},[renderSlot(_ctx.$slots,`previousButton`,{click:goPrev,disabled:unref(isLeftDisabled)},()=>[createVNode(unref(bngButton_default),{"bng-no-nav":`true`,disabled:__props.disabled||unref(isLeftDisabled),accent:unref(ACCENTS).text,mute:_ctx.$attrs.mute,"data-testid":`previous-btn`,onClick:goPrev},{default:withCtx(()=>[createVNode(unref(bngIcon_default),{type:leftBinding.value?.displayed?unref(icons).arrowSmallLeft:unref(icons).arrowLargeLeft,class:normalizeClass(leftIconClass.value)},null,8,[`type`,`class`]),__props.navLeftEvent&&__props.navLeftEvent!==`focus_l`?(openBlock(),createBlock(unref(bngBinding_default),{key:0,ref_key:`leftBinding`,ref:leftBinding,uiEvent:__props.navLeftEvent,controller:``},null,8,[`uiEvent`])):createCommentVNode(``,!0)]),_:1},8,[`disabled`,`accent`,`mute`])],!0),withDirectives((openBlock(),createElementBlock(`div`,{ref_key:`elContent`,ref:elContent,class:normalizeClass([`bng-select-content`,{"label-clickable":__props.labelClickable}]),onClick:_cache[0]||=withModifiers($event=>__props.labelClickable&&emit$1(`label-click`),[`stop`])},[renderSlot(_ctx.$slots,`display`,{label:current.value.label,value:current.value.value},()=>[createBaseVNode(`span`,_hoisted_1$303,toDisplayString(current.value.label),1),_cache[1]||=createBaseVNode(`label`,{flavour:``},null,-1)],!0)],2)),[[unref(BngSoundClass_default),!__props.disabled&&__props.labelClickable&&`bng_click_hover_generic`],[unref(BngPopover_default),__props.labelPopover,`bottom`,{click:!0}]]),renderSlot(_ctx.$slots,`nextButton`,{click:goNext,disabled:unref(isRightDisabled)},()=>[createVNode(unref(bngButton_default),{"bng-no-nav":`true`,disabled:__props.disabled||unref(isRightDisabled),accent:unref(ACCENTS).text,mute:_ctx.$attrs.mute,"data-testid":`next-btn`,onClick:goNext},{default:withCtx(()=>[__props.navRightEvent&&__props.navRightEvent!==`focus_r`?(openBlock(),createBlock(unref(bngBinding_default),{key:0,ref_key:`rightBinding`,ref:rightBinding,uiEvent:__props.navRightEvent,controller:``},null,8,[`uiEvent`])):createCommentVNode(``,!0),createVNode(unref(bngIcon_default),{type:rightBinding.value?.displayed?unref(icons).arrowSmallRight:unref(icons).arrowLargeRight,class:normalizeClass(rightIconClass.value)},null,8,[`type`,`class`])]),_:1},8,[`disabled`,`accent`,`mute`])],!0),createBaseVNode(`div`,_hoisted_2$250,[(openBlock(!0),createElementBlock(Fragment,null,renderList(__props.options.length,idx=>(openBlock(),createElementBlock(`div`,{key:idx,class:normalizeClass({active:idx-1===index.value})},null,2))),128))])])),[[unref(BngOnUiNav_default),goPrev,__props.navLeftEvent,{focusRequired:!0}],[unref(BngOnUiNav_default),goNext,__props.navRightEvent,{focusRequired:!0}],[unref(BngDisabled_default),__props.disabled]])}},bngSelect_default=__plugin_vue_export_helper_default(_sfc_main$345,[[`__scopeId`,`data-v-d1cacb72`]]),_hoisted_1$302={class:`bng-simple-graph`},_hoisted_2$249={key:0,class:`y-axis`},_hoisted_3$219={class:`y-values`},_hoisted_4$187={class:`max-value`},_hoisted_5$160={class:`axis-label`},_hoisted_6$138={key:0,class:`unit`},_hoisted_7$120={class:`min-value`},_hoisted_8$100={viewBox:`0 0 100 100`,preserveAspectRatio:`none`,class:`graph-svg`},_hoisted_9$90=[`width`,`height`],_hoisted_10$78=[`d`,`stroke`],_hoisted_11$70=[`d`,`stroke`],_hoisted_12$58=[`width`,`height`],_hoisted_13$50=[`d`,`stroke`],_hoisted_14$45=[`d`,`stroke`],_hoisted_15$43={key:0,width:`100`,height:`100`,fill:`url(#subgrid)`},_hoisted_16$40={class:`grid`},_hoisted_17$33=[`y1`,`y2`,`stroke`],_hoisted_18$30={class:`background-ranges`},_hoisted_19$25=[`x`,`width`,`fill`,`stroke`,`opacity`],_hoisted_20$21={class:`vertical-guides`},_hoisted_21$19=[`x1`,`x2`,`stroke`,`opacity`],_hoisted_22$17=[`x1`,`x2`],_hoisted_23$16=[`d`,`fill`,`opacity`],_hoisted_24$15=[`d`,`stroke`],_hoisted_25$14={key:2,class:`x-axis`},_hoisted_26$12={class:`x-values`},_hoisted_27$12={class:`min-value`},_hoisted_28$11={class:`axis-label`},_hoisted_29$11={key:0,class:`unit`},_hoisted_30$10={class:`max-value`},_sfc_main$344={__name:`bngSimpleGraph`,props:{config:{type:Object,default:()=>({showLabels:!1,xAxis:{key:`x`,label:`X Axis`,unit:``},yAxis:{key:`y`,label:`Y Axis`,unit:``}})},points:{type:Array,default:()=>[]},gridColor:{type:String,default:`var(--bng-ter-blue-gray-500)`},backgroundColor:{type:String,default:`rgba(0, 0, 0, 0.1)`},currentX:{type:Number,default:null},verticalGuides:{type:Array,default:()=>[]},ranges:{type:Array,default:()=>[]},gridDivisions:{type:Array,default:()=>[50,20]},subgridDivider:{type:Number,default:2},showSubgrid:{type:Boolean,default:!0},singleLabel:{type:Object,default:null}},setup(__props){useCssVars(_ctx=>({v194c2663:__props.config.showLabels?`2rem`:`0`,fdb9891e:__props.backgroundColor}));let props=__props,gridSizes=computed(()=>({x:100/props.gridDivisions[0],y:100/props.gridDivisions[1]})),xScale=computed(()=>{if(props.config?.xAxis?.min!==void 0&&props.config?.xAxis?.max!==void 0){let range$1=props.config.xAxis.max-props.config.xAxis.min;return{min:props.config.xAxis.min,max:props.config.xAxis.max,range:range$1===0?1:range$1}}if(!props.points.length)return{min:0,max:1,range:1};let xValues=[...props.points.flatMap(dataset=>(dataset.points||[]).map(point=>point&&point[0])),...(props.verticalGuides||[]).map(guide=>guide?.x),...(props.ranges||[]).map(range$1=>range$1?.start),...(props.ranges||[]).map(range$1=>range$1?.end)].filter(val=>val!=null&&isFinite(val));if(xValues.length===0)return{min:0,max:1,range:1};let min$1=Math.min(...xValues),max$1=Math.max(...xValues);if(!isFinite(min$1)||!isFinite(max$1))return{min:0,max:1,range:1};let range=max$1-min$1;return{min:min$1,max:max$1,range:range===0?1:range}}),getXPosition=value=>{if(value==null||!isFinite(value))return 0;let result=(value-xScale.value.min)/xScale.value.range*100;return isFinite(result)?result:0},datasetPaths=computed(()=>!props.points.length||!xScale.value?[]:props.points.map(dataset=>{if(!dataset.points||!Array.isArray(dataset.points)||dataset.points.length===0)return{datasetId:dataset.label||`unknown`,linePath:``,areaPath:``};let linePoints=dataset.points.map((point,index)=>{if(!point||point.length<2)return``;let x=getXPosition(point[0]),y=getYPosition(point[1]);return`${index===0?`M`:`L`} ${x} ${y}`}).filter(p$1=>p$1).join(` `),areaPoints=dataset.points.map(point=>!point||point.length<2?``:`L ${getXPosition(point[0])} ${getYPosition(point[1])}`).filter(p$1=>p$1).join(` `),areaPath=``;if(dataset.fill&&dataset.points.length>0){let firstPoint=dataset.points[0],lastPoint=dataset.points[dataset.points.length-1];firstPoint&&lastPoint&&firstPoint.length>=2&&lastPoint.length>=2&&(areaPath=`M -5 105 L -5 ${getYPosition(firstPoint[1])} ${areaPoints} L 105 ${getYPosition(lastPoint[1])} L 105 105 Z`)}return{datasetId:dataset.label||`unknown`,linePath:linePoints,areaPath}})),getLinePathForDataset=dataset=>{let path=datasetPaths.value.find(p$1=>p$1.datasetId===dataset.label);return path?path.linePath:``},getAreaPathForDataset=dataset=>{let path=datasetPaths.value.find(p$1=>p$1.datasetId===dataset.label);return path?path.areaPath:``},getYPosition=value=>{if(value==null||!isFinite(value))return 50;let yMin=yBounds.value.min,yMax=yBounds.value.max;if(yMin==null||yMax==null||!isFinite(yMin)||!isFinite(yMax)||yMin===yMax)return 50;if(yMin>=0||yMax<=0){let yRange$1=yMax-yMin;if(yRange$1===0)return 50;let result$1=97.5-(value-yMin)/yRange$1*95;return isFinite(result$1)?result$1:50}let yRange=Math.max(Math.abs(yMin),Math.abs(yMax));if(yRange===0)return 50;let totalRange=Math.abs(yMin)+Math.abs(yMax);if(totalRange===0)return 50;let zeroLinePosition=Math.abs(yMin)/totalRange*95+2.5,result;return result=value>=0?zeroLinePosition-value/yRange*(zeroLinePosition-2.5):zeroLinePosition+Math.abs(value)/yRange*(97.5-zeroLinePosition),isFinite(result)?result:50},formatNumber=num=>num==null||!isFinite(num)?`0`:Math.floor(num).toString(),yBounds=computed(()=>{if(props.config?.yAxis?.min!==void 0&&props.config?.yAxis?.max!==void 0)return{min:props.config.yAxis.min,max:props.config.yAxis.max};if(!props.points.length)return{min:0,max:0};let allYValues=props.points.flatMap(dataset=>(dataset.points||[]).map(point=>point&&point[1])).filter(val=>val!=null&&isFinite(val));if(allYValues.length===0)return{min:0,max:1};let min$1=Math.min(...allYValues),max$1=Math.max(...allYValues);return!isFinite(min$1)||!isFinite(max$1)?{min:0,max:1}:{min:min$1,max:max$1}}),xMinFormatted=computed(()=>formatNumber(xScale.value?.min||0)),xMaxFormatted=computed(()=>formatNumber(xScale.value?.max||0)),yMinFormatted=computed(()=>formatNumber(yBounds.value.min)),yMaxFormatted=computed(()=>formatNumber(yBounds.value.max)),hasNegativeValues=computed(()=>yBounds.value.min<0),getLabelPosition=()=>{if(!props.singleLabel)return{x:0,y:0,anchor:`start`};let labelX=props.singleLabel.x===void 0?95:getXPosition(props.singleLabel.x),labelY=props.singleLabel.y===void 0?50:getYPosition(props.singleLabel.y),adjustedY=labelY>=25?labelY+4:labelY-2,anchor=labelX>=80?`end`:`start`;return{x:anchor===`end`?Math.min(labelX,98):Math.max(labelX,2),y:adjustedY,anchor}},getLabelStyle=()=>{if(!props.singleLabel)return{};let basePos=getLabelPosition(),estimatedWidth=props.singleLabel.text.length*6.5+6,estimatedHeight=18,containerWidth=300,containerHeight=80,pixelX=basePos.x/100*300,pixelY=basePos.y/100*80,finalX=basePos.x,finalY=basePos.y,anchor=basePos.anchor,verticalAlign=`middle`;anchor===`start`?pixelX+estimatedWidth>290&&(anchor=`end`):pixelX-estimatedWidth<10&&(anchor=`start`);let minGapFromPoint=4,topBuffer=8,bottomBuffer=8,wouldOverflowTop=pixelY-18/2<8;if(pixelY+18/2>72)verticalAlign=`bottom`,finalY=Math.max(basePos.y-4,15);else if(wouldOverflowTop)verticalAlign=`top`,finalY=Math.min(basePos.y+4,85);else{let pointY=basePos.y;pointY>75?(verticalAlign=`bottom`,finalY=pointY-4):pointY<25?(verticalAlign=`top`,finalY=pointY+4):(verticalAlign=`bottom`,finalY=pointY-4)}let transformX=`translateX(0)`,transformY=`translateY(-50%)`;return anchor===`end`&&(transformX=`translateX(-100%)`),verticalAlign===`bottom`?transformY=`translateY(-100%)`:verticalAlign===`top`&&(transformY=`translateY(0)`),{position:`absolute`,left:`${finalX}%`,top:`${finalY}%`,transform:`${transformX} ${transformY}`,color:props.singleLabel.color||`var(--bng-orange)`,fontSize:`11px`,fontFamily:`sans-serif`,pointerEvents:`none`,whiteSpace:`nowrap`}};return(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$302,[__props.config.showLabels?(openBlock(),createElementBlock(`div`,_hoisted_2$249,[createBaseVNode(`div`,_hoisted_3$219,[createBaseVNode(`div`,_hoisted_4$187,toDisplayString(yMaxFormatted.value),1),createBaseVNode(`div`,_hoisted_5$160,[createTextVNode(toDisplayString(__props.config.yAxis.label)+` `,1),__props.config.yAxis.unit?(openBlock(),createElementBlock(`span`,_hoisted_6$138,`(`+toDisplayString(__props.config.yAxis.unit)+`)`,1)):createCommentVNode(``,!0)]),createBaseVNode(`div`,_hoisted_7$120,toDisplayString(yMinFormatted.value),1)])])):createCommentVNode(``,!0),(openBlock(),createElementBlock(`svg`,_hoisted_8$100,[createBaseVNode(`defs`,null,[createBaseVNode(`pattern`,{id:`grid`,width:gridSizes.value.x,height:gridSizes.value.y,patternUnits:`userSpaceOnUse`},[createBaseVNode(`path`,{d:`M ${gridSizes.value.x} 0 L ${gridSizes.value.x} ${gridSizes.value.y}`,stroke:__props.gridColor,"stroke-width":`1`,"vector-effect":`non-scaling-stroke`,opacity:`0.3`},null,8,_hoisted_10$78),createBaseVNode(`path`,{d:`M 0 ${gridSizes.value.y} L 100 ${gridSizes.value.y}`,stroke:__props.gridColor,"stroke-width":`1`,"vector-effect":`non-scaling-stroke`,opacity:`0.3`},null,8,_hoisted_11$70)],8,_hoisted_9$90),createBaseVNode(`pattern`,{id:`subgrid`,width:gridSizes.value.x,height:gridSizes.value.y,patternUnits:`userSpaceOnUse`},[createBaseVNode(`path`,{d:`M ${gridSizes.value.x/__props.subgridDivider} 0 L ${gridSizes.value.x/__props.subgridDivider} ${gridSizes.value.y}`,stroke:__props.gridColor,"stroke-width":`0.5`,"vector-effect":`non-scaling-stroke`,opacity:`0.15`},null,8,_hoisted_13$50),createBaseVNode(`path`,{d:`M 0 ${gridSizes.value.y/__props.subgridDivider} L 100 ${gridSizes.value.y/__props.subgridDivider}`,stroke:__props.gridColor,"stroke-width":`0.5`,"vector-effect":`non-scaling-stroke`,opacity:`0.15`},null,8,_hoisted_14$45)],8,_hoisted_12$58)]),__props.showSubgrid?(openBlock(),createElementBlock(`rect`,_hoisted_15$43)):createCommentVNode(``,!0),_cache[0]||=createBaseVNode(`rect`,{width:`100`,height:`100`,fill:`url(#grid)`},null,-1),createBaseVNode(`g`,_hoisted_16$40,[hasNegativeValues.value?(openBlock(),createElementBlock(`line`,{key:0,x1:`0`,y1:getYPosition(0),x2:`100`,y2:getYPosition(0),stroke:__props.gridColor,"stroke-width":`2`,"vector-effect":`non-scaling-stroke`,opacity:`0.75`},null,8,_hoisted_17$33)):createCommentVNode(``,!0)]),createBaseVNode(`g`,_hoisted_18$30,[(openBlock(!0),createElementBlock(Fragment,null,renderList(__props.ranges,range=>(openBlock(),createElementBlock(`rect`,{key:`range-${range.start}`,x:getXPosition(range.start),y:`-5`,width:getXPosition(range.end)-getXPosition(range.start),height:`110`,fill:range.fill,stroke:range.outline,"stroke-width":`2`,"vector-effect":`non-scaling-stroke`,opacity:range.opacity},null,8,_hoisted_19$25))),128))]),createBaseVNode(`g`,_hoisted_20$21,[(openBlock(!0),createElementBlock(Fragment,null,renderList(__props.verticalGuides,guide=>(openBlock(),createElementBlock(`line`,{key:`guide-${guide.x}`,x1:getXPosition(guide.x),y1:`0`,x2:getXPosition(guide.x),y2:`100`,stroke:guide.color,"stroke-width":`1`,"vector-effect":`non-scaling-stroke`,opacity:guide.opacity},null,8,_hoisted_21$19))),128))]),__props.currentX?(openBlock(),createElementBlock(`line`,{key:1,x1:getXPosition(__props.currentX),y1:`0`,x2:getXPosition(__props.currentX),y2:`100`,stroke:`white`,"stroke-width":`1`,"vector-effect":`non-scaling-stroke`,opacity:`0.8`},null,8,_hoisted_22$17)):createCommentVNode(``,!0),(openBlock(!0),createElementBlock(Fragment,null,renderList(__props.points,dataset=>(openBlock(),createElementBlock(`g`,{key:dataset.label},[dataset.fill?(openBlock(),createElementBlock(`path`,{key:0,d:getAreaPathForDataset(dataset),fill:dataset.color||`white`,opacity:dataset.fillOpacity??.5},null,8,_hoisted_23$16)):createCommentVNode(``,!0),createBaseVNode(`path`,{d:getLinePathForDataset(dataset),stroke:dataset.color||`white`,fill:`none`,"stroke-width":`1`,"vector-effect":`non-scaling-stroke`},null,8,_hoisted_24$15)]))),128))])),__props.singleLabel?(openBlock(),createElementBlock(`div`,{key:1,class:`single-label`,style:normalizeStyle(getLabelStyle())},toDisplayString(__props.singleLabel.text),5)):createCommentVNode(``,!0),__props.config.showLabels?(openBlock(),createElementBlock(`div`,_hoisted_25$14,[createBaseVNode(`div`,_hoisted_26$12,[createBaseVNode(`div`,_hoisted_27$12,toDisplayString(xMinFormatted.value),1),createBaseVNode(`div`,_hoisted_28$11,[createTextVNode(toDisplayString(__props.config.xAxis.label)+` `,1),__props.config.xAxis.unit?(openBlock(),createElementBlock(`span`,_hoisted_29$11,`(`+toDisplayString(__props.config.xAxis.unit)+`)`,1)):createCommentVNode(``,!0)]),createBaseVNode(`div`,_hoisted_30$10,toDisplayString(xMaxFormatted.value),1)])])):createCommentVNode(``,!0)]))}},bngSimpleGraph_default=__plugin_vue_export_helper_default(_sfc_main$344,[[`__scopeId`,`data-v-66d95af3`]]),_hoisted_1$301={class:`bng-slider-container`},_hoisted_2$248=[`disabled`,`min`,`max`,`step`],_sfc_main$343={__name:`bngSlider`,props:{modelValue:Number,origValue:{type:[Number,String],default:NaN},min:{type:[Number,String],default:0},max:{type:[Number,String],required:!0},step:{type:[Number,String],default:0},withReset:{type:Boolean,default:!1},withInput:{type:Boolean,default:!1},inputMultiplier:{type:Number,default:1},unit:{type:String,default:``},disabled:Boolean,uiNavFocus:{type:[Boolean,Object],default:{},validator:val=>typeof val==`boolean`&&!val||typeof val==`object`}},emits:[`change`,`valueChanged`,`update:modelValue`],setup(__props,{expose:__expose,emit:__emit}){let props=__props,emit$1=__emit,slider=ref(null),value=ref(props.modelValue);ref(!1);let uiNavFocusFunction=computed(()=>props.uiNavFocus?{callback:(dir,val)=>{value.value=val,notify()},value:()=>value.value,min:+props.min,max:+props.max,step:()=>+props.step,...props.uiNavFocus}:!1);watch(()=>props.modelValue,val=>{value.value=Number(val),updateSliderBackground()});let dirty=useDirty(value,null,updateSliderBackground),dirtyReset=useDirty(value,null,updateSliderBackground);__expose(dirty);let resetDisabled=computed(()=>props.disabled?!0:isNaN(dirtyReset.currentCleanValue.value)?!dirty.dirty.value:!dirtyReset.dirty.value);onMounted(()=>{updateSliderBackground(),inputProps.value=value.value*props.inputMultiplier});function notify(){emit$1(`update:modelValue`,value.value),emit$1(`valueChanged`,value.value),emit$1(`change`,value.value),updateSliderBackground()}function updateSliderBackground(){if(!slider.value)return;let current=(value.value-props.min)/(props.max-props.min)*100,init$3=[-100,-100],dirtyVal=dirtyReset.currentCleanValue.value;if((typeof dirtyVal!=`number`||isNaN(dirtyVal))&&(dirtyVal=dirty.currentCleanValue.value),typeof dirtyVal==`number`&&!isNaN(dirtyVal)){let initpos=(dirtyVal-props.min)/(props.max-props.min)*100;init$3[currentvalue.value,val=>{inputProps.value=val*props.inputMultiplier}),watch(()=>props.origValue,val=>{val=+val,isNaN(val)||dirtyReset.setCleanValue(val)},{immediate:!0}),watch(()=>inputProps.value,val=>{value.value=val/props.inputMultiplier});function onInputChange(num){num=Number(num);let norm=roundDecSample(num,inputProps.step);num!==norm&&(inputProps.value=norm),num=norm/props.inputMultiplier,num=roundDecSample(num,props.step),numprops.max&&(num=props.max),value.value=num,notify()}function resetValue(){let val=+props.origValue;isNaN(val)?dirty.resetValue():value.value=val,notify()}return(_ctx,_cache)=>withDirectives((openBlock(),createElementBlock(`div`,_hoisted_1$301,[withDirectives(createBaseVNode(`input`,{ref_key:`slider`,ref:slider,class:`bng-slider`,type:`range`,disabled:__props.disabled,"onUpdate:modelValue":_cache[0]||=$event=>value.value=$event,min:+__props.min,max:+__props.max,step:+__props.step,onInput:notify},null,40,_hoisted_2$248),[[vModelText,value.value,void 0,{number:!0}],[unref(BngOnUiNavFocus_default),uiNavFocusFunction.value,void 0,{repeat:!0}]]),__props.withInput?(openBlock(),createBlock(unref(bngInput_default),{key:0,class:`bng-slider-input`,disabled:__props.disabled,modelValue:inputProps.value,"onUpdate:modelValue":_cache[1]||=$event=>inputProps.value=$event,type:`number`,min:inputProps.min,max:inputProps.max,step:inputProps.step,suffix:__props.unit,onValueChanged:onInputChange},null,8,[`disabled`,`modelValue`,`min`,`max`,`step`,`suffix`])):createCommentVNode(``,!0),__props.withReset?(openBlock(),createBlock(unref(bngButton_default),{key:1,class:`bng-slider-reset`,accent:unref(ACCENTS).text,icon:unref(icons).undo,disabled:resetDisabled.value,onClick:resetValue},null,8,[`accent`,`icon`,`disabled`])):createCommentVNode(``,!0)])),[[unref(BngScopedNav_default),{bubbleWhitelistEvents:[`menu`]}],[unref(BngDisabled_default),__props.disabled]])}},bngSlider_default=__plugin_vue_export_helper_default(_sfc_main$343,[[`__scopeId`,`data-v-7d0150a1`]]),_sfc_main$342={__name:`bngSmartSelect`,props:mergeModels({items:{type:Array,required:!0},threshold:{type:Number,default:6},type:{type:String,default:``,validator(val){return[``,`select`,`dropdown`].includes(val)}},highlight:[String,Array,RegExp],disabled:Boolean},{modelValue:{},modelModifiers:{}}),emits:mergeModels([`change`],[`update:modelValue`]),setup(__props,{emit:__emit}){let props=__props,value=useModel(__props,`modelValue`),emit$1=__emit,elDropdown=ref(),elSelect=ref(),types={none:bngSelect_default,select:bngSelect_default,dropdown:bngDropdown_default},items$2=computed(()=>Array.isArray(props.items)?props.items:[]),type=computed(()=>props.type&&props.type in types?props.type:items$2.value.length===0?`none`:items$2.value.length<=props.threshold?`select`:`dropdown`),binds=computed(()=>{let res={disabled:props.disabled};switch(type.value){default:res.options=[`n/a`],res.disabled=!0;break;case`select`:res.loop=!0,res.labelClickable=!0,res.config={label:itm=>itm?.label||`n/a`,value:itm=>itm?.value},res.options=items$2.value.filter(itm=>!itm.disabled&&!itm.group),res.items=items$2.value,res.highlight=props.highlight,res.disabled||=res.options.length===0,res.popoverTarget=elSelect.value?.getElement?.(),res.focusTarget=elSelect.value?.getContentElement?.()||res.popoverTarget;break;case`dropdown`:res.items=items$2.value,res.highlight=props.highlight,res.showSearch=!0;break}return res});function openDropdown(){}function onSelectChanged(newValue){value.value!==newValue&&emit$1(`change`,newValue)}function onDropdownChanged(newValue){value.value!==newValue&&emit$1(`change`,newValue)}return(_ctx,_cache)=>(openBlock(),createElementBlock(Fragment,null,[type.value===`dropdown`?createCommentVNode(``,!0):(openBlock(),createBlock(unref(bngSelect_default),{key:0,ref_key:`elSelect`,ref:elSelect,class:`bng-smart-select`,modelValue:value.value,"onUpdate:modelValue":_cache[0]||=$event=>value.value=$event,options:binds.value.options,config:binds.value.config,disabled:binds.value.disabled,loop:``,"label-clickable":``,"label-popover":elDropdown.value?.popoverName,onLabelClick:openDropdown,onChange:onSelectChanged},null,8,[`modelValue`,`options`,`config`,`disabled`,`label-popover`])),binds.value.items?(openBlock(),createBlock(unref(bngDropdown_default),{key:1,ref_key:`elDropdown`,ref:elDropdown,class:normalizeClass(`bng-smart-${type.value}`),modelValue:value.value,"onUpdate:modelValue":_cache[1]||=$event=>value.value=$event,items:binds.value.items,highlight:binds.value.highlight,disabled:binds.value.disabled,headless:type.value===`select`,"show-search":binds.value.showSearch,"focus-target":binds.value.focusTarget,"popover-target":binds.value.popoverTarget,onValueChanged:onDropdownChanged},null,8,[`class`,`modelValue`,`items`,`highlight`,`disabled`,`headless`,`show-search`,`focus-target`,`popover-target`])):createCommentVNode(``,!0)],64))}},bngSmartSelect_default=__plugin_vue_export_helper_default(_sfc_main$342,[[`__scopeId`,`data-v-a288ad68`]]),_hoisted_1$300=[`xlink:href`],_sfc_main$341={__name:`bngSpriteIcon`,props:{atlasPath:{type:String,default:`sprites/svg-symbols.svg`},src:{type:String,required:!0},color:{type:String,default:`#fff`},deg:{type:Number,default:0}},setup(__props){let props=__props,atlasURL=computed(()=>`${getAssetURL$1(props.atlasPath)}#${props.src.toLowerCase()}`),getAssetURL$1=assetPath=>bngApi.isMock?`http://localhost:9000/${assetPath}`:`/ui/ui-vue/src/assets/${assetPath}`;return(_ctx,_cache)=>(openBlock(),createElementBlock(`svg`,{class:`atlasIcon`,style:normalizeStyle({fill:__props.color,pointerEvents:`none`,transform:`rotate(${__props.deg}deg)`}),version:`1.1`,xmlns:`http://www.w3.org/2000/svg`},[createBaseVNode(`use`,{"xlink:href":atlasURL.value},null,8,_hoisted_1$300)],4))}},bngSpriteIcon_default=__plugin_vue_export_helper_default(_sfc_main$341,[[`__scopeId`,`data-v-0ace1ddc`]]),_hoisted_1$299=[`tabindex`],_hoisted_2$247={key:0};const LABEL_ALIGNMENTS={START:`start`,END:`end`,CENTER:`center`};var _sfc_main$340={__name:`bngSwitch`,props:{modelValue:[Boolean,Number,String],checked:{type:Boolean,default:!1},label:String,labelBefore:Boolean,labelAlignment:{type:String,default:LABEL_ALIGNMENTS.END,validator:value=>Object.values(LABEL_ALIGNMENTS).includes(value)},inline:{type:Boolean,default:!0},alwaysTransparent:Boolean,disabled:Boolean,valueOn:{type:[Boolean,Number,String],default:void 0},valueOff:{type:[Boolean,Number,String],default:void 0}},emits:[`update:modelValue`,`change`,`valueChanged`],setup(__props,{emit:__emit}){let props=__props,emit$1=__emit,slots=useSlots(),bngSwitch=ref(null),valOn=computed(()=>props.valueOn===void 0?!0:props.valueOn),valOff=computed(()=>props.valueOff===void 0?!1:props.valueOff),isSwitchOn=computed(()=>props.modelValue==null?props.checked:props.modelValue===valOn.value);function onClicked(){if(props.disabled)return;let newValue=isSwitchOn.value?valOff.value:valOn.value;props.modelValue!=null&&emit$1(`update:modelValue`,newValue),emit$1(`valueChanged`,newValue),emit$1(`change`,newValue)}return onUpdated(()=>ensureFocus(bngSwitch.value)),(_ctx,_cache)=>withDirectives((openBlock(),createElementBlock(`div`,{ref_key:`bngSwitch`,ref:bngSwitch,"bng-nav-item":``,class:normalizeClass([`bng-switch`,{"bng-switch-on":isSwitchOn.value,"with-background":!__props.alwaysTransparent,"with-label":__props.label||unref(slots).default,"label-position-before":__props.labelBefore,"inline-switch":!__props.label&&!unref(slots).default||__props.inline}]),tabindex:__props.disabled?-1:0,onClick:onClicked},[_cache[0]||=createBaseVNode(`div`,{class:`bng-switch-control`},null,-1),unref(slots).default||__props.label?(openBlock(),createElementBlock(`div`,{key:0,class:normalizeClass([`bng-switch-label`,[`label-alignment-`+__props.labelAlignment]])},[renderSlot(_ctx.$slots,`default`,{},()=>[__props.label?(openBlock(),createElementBlock(`span`,_hoisted_2$247,toDisplayString(__props.label),1)):createCommentVNode(``,!0)],!0)],2)):createCommentVNode(``,!0)],10,_hoisted_1$299)),[[unref(BngOnUiNav_default),void 0,`ok`,{asMouse:!0,focusRequired:!0}],[unref(BngDisabled_default),__props.disabled]])}},bngSwitch_default=__plugin_vue_export_helper_default(_sfc_main$340,[[`__scopeId`,`data-v-8e1c4b05`]]),_hoisted_1$298={class:`bng-switch-label`},_hoisted_2$246={key:0},_sfc_main$339={__name:`bngSwitchOld`,props:{modelValue:Boolean,label:String,checked:Boolean,uncheckedWithBackground:Boolean,disabled:Boolean},emits:[`valueChanged`,`update:modelValue`],setup(__props,{emit:__emit}){let toggleValue=ref(!1),props=__props,emit$1=__emit,slots=useSlots();onBeforeMount(init$3),watch(()=>props.modelValue,init$3),watch(()=>props.checked,init$3),watch(()=>props.disabled,init$3);function init$3(){toggleValue.value=props.checked||props.modelValue}function onValueChanged(){props.disabled||(toggleValue.value=!toggleValue.value,emit$1(`update:modelValue`,toggleValue.value),emit$1(`valueChanged`,toggleValue.value))}return(_ctx,_cache)=>unref(slots).default||__props.label?withDirectives((openBlock(),createElementBlock(`div`,mergeProps({key:0,class:[`bng-labeled-switch`,{"switch-on":toggleValue.value,"with-background":__props.uncheckedWithBackground}]},{...!__props.disabled&&{"bng-nav-item":1}},{tabindex:`{{disabled ? 0 : 1}}`,onClick:onValueChanged,onKeyup:withKeys(onValueChanged,[`space`])}),[_cache[0]||=createBaseVNode(`div`,{class:`bng-switch-wrapper`},[createBaseVNode(`div`,{class:`bng-switch`})],-1),createBaseVNode(`div`,_hoisted_1$298,[renderSlot(_ctx.$slots,`default`,{},()=>[__props.label?(openBlock(),createElementBlock(`label`,_hoisted_2$246,toDisplayString(__props.label),1)):createCommentVNode(``,!0)],!0)])],16)),[[unref(BngDisabled_default),__props.disabled]]):withDirectives((openBlock(),createElementBlock(`div`,mergeProps({key:1},{...!__props.disabled&&{"bng-nav-item":1}},{tabindex:`{{disabled ? 0 : 1}}`,class:[`bng-switch-wrapper`,{"switch-on":toggleValue.value}],onClick:onValueChanged,onKeyup:withKeys(onValueChanged,[`space`])}),[..._cache[1]||=[createBaseVNode(`div`,{class:`bng-switch`},null,-1)]],16)),[[unref(BngDisabled_default),__props.disabled]])}},bngSwitchOld_default=__plugin_vue_export_helper_default(_sfc_main$339,[[`__scopeId`,`data-v-da8dc7b1`]]),_hoisted_1$297={"bng-nav-item":``,class:`bng-tile tile`},_hoisted_2$245={class:`content`},_hoisted_3$218={class:`label`},_sfc_main$338={__name:`bngTile`,props:{label:String,ratio:{type:String,default:`4:3`},backgroundImage:String,backgroundExternalImage:String,disabled:Boolean},setup(__props){return(_ctx,_cache)=>withDirectives((openBlock(),createElementBlock(`div`,_hoisted_1$297,[createVNode(unref(aspectRatio_default),{class:`content-container image`,ratio:__props.ratio,image:__props.backgroundImage,externalImage:__props.backgroundExternalImage,imageMode:`contain`},{default:withCtx(()=>[createBaseVNode(`div`,_hoisted_2$245,[renderSlot(_ctx.$slots,`default`,{},void 0,!0)])]),_:3},8,[`ratio`,`image`,`externalImage`]),renderSlot(_ctx.$slots,`label`,{},()=>[createBaseVNode(`div`,_hoisted_3$218,toDisplayString(__props.label),1)],!0)])),[[unref(BngDisabled_default),__props.disabled]])}},bngTile_default=__plugin_vue_export_helper_default(_sfc_main$338,[[`__scopeId`,`data-v-af5747cc`]]),_sfc_main$337={__name:`bngTooltip`,props:{text:{type:String,required:!0},position:{type:String,default:`top`}},setup(__props){return(_ctx,_cache)=>withDirectives((openBlock(),createElementBlock(`div`,null,[renderSlot(_ctx.$slots,`default`,{},void 0,!0)])),[[unref(BngTooltip_default),__props.text,__props.position]])}},bngTooltip_default=__plugin_vue_export_helper_default(_sfc_main$337,[[`__scopeId`,`data-v-53073c36`]]),toInt=v=>~~+v,_sfc_main$336={__name:`bngUnit`,props:{options:Object,formatter:[Function,String]},setup(__props){let{units}=useBridge(),knownUnits={money:{formatter:v=>units.beamBucks(v)},beamXP:{formatter:toInt},stars:{formatter:toInt},vouchers:{formatter:toInt},insuranceScore:{formatter:toInt},multiplier:{formatter:toInt,noGap:!0}},defaultColors={stars:`var(--bng-ter-yellow-200)`,vouchers:`var(--bng-add-blue-400)`},attrs=useAttrs(),unit=computed(()=>{for(let key of Object.keys(attrs))if(key in knownUnits)return{type:key,value:attrs[key],...knownUnits[key],...props.options};return{type:`unknown`}}),formattedValue=computed(()=>{if(props.formatter){if(typeof props.formatter==`function`)return props.formatter(unit.value.value);if(typeof props.formatter==`string`&&props.formatter in knownUnits)return knownUnits[props.formatter].formatter(unit.value.value)}return typeof unit.value.formatter==`function`?unit.value.formatter(unit.value.value):unit.value.value}),props=__props;return(_ctx,_cache)=>(openBlock(),createBlock(unref(slotSwitcher_default),mergeProps(unref(attrs),{slotId:unit.value.type}),{money:withCtx(props$1=>[createVNode(unref(bngPropVal_default),mergeProps({...props$1,...unit.value},{iconType:props$1.iconType||unref(icons).beamCurrency,valueLabel:formattedValue.value}),null,16,[`iconType`,`valueLabel`])]),beamXP:withCtx(props$1=>[createVNode(unref(bngPropVal_default),mergeProps({...props$1,...unit.value},{iconType:props$1.iconType||unref(icons).beamXPLo,valueLabel:formattedValue.value}),null,16,[`iconType`,`valueLabel`])]),stars:withCtx(props$1=>[createVNode(unref(bngPropVal_default),mergeProps({...props$1,...unit.value},{iconType:props$1.iconType||unref(icons).star,valueLabel:formattedValue.value,"icon-color":defaultColors.stars}),null,16,[`iconType`,`valueLabel`,`icon-color`])]),vouchers:withCtx(props$1=>[createVNode(unref(bngPropVal_default),mergeProps({...props$1,...unit.value},{iconType:props$1.iconType||unref(icons).voucherHorizontal3,valueLabel:formattedValue.value,"icon-color":defaultColors.vouchers}),null,16,[`iconType`,`valueLabel`,`icon-color`])]),insuranceScore:withCtx(props$1=>[createVNode(unref(bngPropVal_default),mergeProps({...props$1,...unit.value},{iconType:props$1.iconType||unref(icons).shieldCheckmarkProgressbar,valueLabel:formattedValue.value}),null,16,[`iconType`,`valueLabel`])]),multiplier:withCtx(props$1=>[createVNode(unref(bngPropVal_default),mergeProps({...props$1,...unit.value},{iconType:props$1.iconType||unref(icons).mathMultiply,valueLabel:formattedValue.value,"icon-color":defaultColors.multiplier}),null,16,[`iconType`,`valueLabel`,`icon-color`])]),unknown:withCtx(props$1=>[createBaseVNode(`span`,normalizeProps(guardReactiveProps(props$1)),`BngUnit: Unknown unit type or no type specified`,16)]),_:1},16,[`slotId`]))}},bngUnit_default=_sfc_main$336;const DEMOS={};var base_exports=__export({ACCENTS:()=>ACCENTS,BngActionDrawer:()=>bngActionDrawer_default,BngActionsDrawer:()=>bngActionsDrawer_default,BngActionsDrawerOne:()=>bngActionsDrawerOne_default,BngActionsList:()=>bngActionsList_default,BngBinding:()=>bngBinding_default,BngBreadcrumbs:()=>bngBreadcrumbs_default,BngButton:()=>bngButton_default,BngCard:()=>bngCard_default,BngCardHeading:()=>bngCardHeading_default,BngColorPicker:()=>bngColorPicker_default,BngColorSlider:()=>bngColorSlider_default,BngColorTile:()=>bngColorTile_default,BngCondition:()=>bngCondition_default,BngControllerHint:()=>bngControllerHint_default,BngDivider:()=>bngDivider_default,BngDrawer:()=>bngDrawer_default,BngDrawerOld:()=>bngDrawerOld_default,BngDropdown:()=>bngDropdown_default,BngDropdownContainer:()=>bngDropdownContainer_default,BngIcon:()=>bngIcon_default,BngIconMarker:()=>bngIconMarker_default,BngImage:()=>bngImage_default,BngImageAsset:()=>bngImageAsset_default,BngImageCarousel:()=>bngImageCarousel_default,BngImageTile:()=>bngImageTile_default,BngInput:()=>bngInput_default,BngInputNew:()=>bngInputNew_default,BngList:()=>bngList_default,BngMainStars:()=>bngMainStars_default,BngMultilineInput:()=>bngMultilineInput_default,BngOldIcon:()=>bngOldIcon_default,BngOverflowContainer:()=>bngOverflowContainer_default,BngPaintTile:()=>bngPaintTile_default,BngPill:()=>bngPill_default,BngPillCheckbox:()=>bngPillCheckbox_default,BngPillFilters:()=>bngPillFilters_default,BngPillFiltersContainer:()=>bngPillFiltersContainer_default,BngPopoverContent:()=>bngPopoverContent_default,BngPopoverMenu:()=>bngPopoverMenu_default,BngProgressBar:()=>bngProgressBar_default,BngPropVal:()=>bngPropVal_default,BngScreenHeading:()=>bngScreenHeading_default,BngScreenHeadingV2:()=>bngScreenHeadingV2_default,BngSelect:()=>bngSelect_default,BngSimpleGraph:()=>bngSimpleGraph_default,BngSlider:()=>bngSlider_default,BngSmartSelect:()=>bngSmartSelect_default,BngSpriteIcon:()=>bngSpriteIcon_default,BngSwitch:()=>bngSwitch_default,BngSwitchOld:()=>bngSwitchOld_default,BngTile:()=>bngTile_default,BngTooltip:()=>bngTooltip_default,BngUnit:()=>bngUnit_default,DEMOS:()=>DEMOS,LABEL_ALIGNMENTS:()=>LABEL_ALIGNMENTS,LIST_LAYOUTS:()=>LIST_LAYOUTS,STEP_ICON_TYPES:()=>STEP_ICON_TYPES,getIconsWithTags:()=>getIconsWithTags,icons:()=>icons,iconsBySize:()=>iconsBySize,iconsByTag:()=>iconsByTag});function getPopupWrapperDefaults(){return{fade:!1,blur:!0,style:[popupContainer.default]}}function getActivityWrapperDefaults(){return{fade:!1,blur:!1,style:[popupContainer.clickthrough]}}const popupContainer=Object.freeze({default:`default`,transparent:`transparent`,clickthrough:`clickthrough`}),popupPosition=Object.freeze({default:`center`,top:`top`,left:`left`,right:`right`,bottom:`bottom`,center:`center`,fullscreen:`fullscreen`});var _hoisted_1$296=[`bng-ui-scope`],_hoisted_2$244={class:`popup-content`},_hoisted_3$217={key:0,class:`popup-title`},_hoisted_4$186={key:1,class:`popup-body`},_hoisted_5$159=[`innerHTML`],_hoisted_6$137={class:`popup-buttons`},__default__$10={wrapper:{blur:!0,style:null},position:popupPosition.center,animated:!0},_sfc_main$335=Object.assign(__default__$10,{__name:`Confirmation`,props:{appearance:String,popupActive:Boolean,message:{type:[String,Object],required:!0},title:String,buttons:Array},emits:[`return`],setup(__props,{emit:__emit}){useUINavBlocker().allowNavigationOnly();let props=__props,emit$1=__emit,scopeName=usePopupUINavScopeName(`_confirmPopup`,props),defaultButtonIndex=props.buttons.findIndex(button=>button.extras&&button.extras.default);defaultButtonIndex===-1&&(defaultButtonIndex=0);let cancelButton=props.buttons.find(button=>button.extras&&button.extras.cancel),exclude=[`default`,`cancel`],buttonProps=computed(()=>{let bp=[];for(let{extras}of props.buttons)extras?bp.push(Object.keys(extras).reduce((ex,key)=>exclude.includes(key)?ex:{...ex,[key]:extras[key]},{})):bp.push({});return bp}),messageIsComponent=computed(()=>props.message&&typeof props.message==`object`&&props.message.component),handleCancelWithBack=()=>emit$1(`return`,cancelButton?cancelButton.value:null);return(_ctx,_cache)=>withDirectives((openBlock(),createElementBlock(`div`,{class:normalizeClass([`popup`,`popup-style-`+__props.appearance]),"bng-ui-scope":unref(scopeName)},[createBaseVNode(`div`,_hoisted_2$244,[__props.title?(openBlock(),createElementBlock(`div`,_hoisted_3$217,toDisplayString(__props.title),1)):createCommentVNode(``,!0),messageIsComponent.value?(openBlock(),createElementBlock(`div`,_hoisted_4$186,[(openBlock(),createBlock(resolveDynamicComponent(__props.message.component),normalizeProps(guardReactiveProps(__props.message.props)),null,16))])):(openBlock(),createElementBlock(`div`,{key:2,class:`popup-body`,innerHTML:__props.message},null,8,_hoisted_5$159)),createBaseVNode(`div`,_hoisted_6$137,[(openBlock(!0),createElementBlock(Fragment,null,renderList(__props.buttons,(button,index)=>withDirectives((openBlock(),createBlock(unref(bngButton_default),mergeProps({key:index},{ref_for:!0},buttonProps.value[index],{onClick:$event=>_ctx.$emit(`return`,button.value)}),{default:withCtx(()=>[createTextVNode(toDisplayString(button.label),1)]),_:2},1040,[`onClick`])),[[unref(BngUiNavFocus_default),index===unref(defaultButtonIndex)?1e3:void 0]])),128))])])],10,_hoisted_1$296)),[[unref(BngOnUiNav_default),handleCancelWithBack,`back,menu`]])}}),Confirmation_default=__plugin_vue_export_helper_default(_sfc_main$335,[[`__scopeId`,`data-v-ce4a758b`]]),_hoisted_1$295=[`bng-ui-scope`],_hoisted_2$243={key:0,class:`form-dialog-toolbar`},_hoisted_3$216={class:`toolbar-title`},_hoisted_4$185={key:0,class:`content-description`},_hoisted_5$158={class:`content-wrapper`},_hoisted_6$136={class:`form-actions-bar`},_sfc_main$334={__name:`FormDialog`,props:mergeModels({title:{type:String},description:{type:String},view:{type:[Object,String],required:!0},formValidator:{type:Function,default:formModel=>!0},buttons:{type:Array,required:!0},maxWidth:{type:String,default:`40rem`}},{formModel:{},formModelModifiers:{}}),emits:mergeModels([`return`],[`update:formModel`]),setup(__props,{emit:__emit}){useUINavBlocker().allowOnly([`focus_u`,`focus_d`,`focus_l`,`focus_r`,`back`,`menu`,`ok`]);let props=__props,emit$1=__emit,formModel=useModel(__props,`formModel`),scopeName=usePopupUINavScopeName(`_formdialog`,props),handleCancelWithBack=()=>{let cancelButton=props.buttons.find(x=>x.extras&&x.extras.cancel);cancelButton?onClick(cancelButton):emit$1(`return`)},onClick=button=>{let data={value:button.value};button.emitData&&(data.formData=formModel.value),emit$1(`return`,data)},formValid=ref(!1),message=ref(null);return watch(formModel,()=>{let res=props.formValidator(formModel.value);message.value=res.error?res.message:props.description,formValid.value=!res.error},{immediate:!0,deep:!0}),(_ctx,_cache)=>withDirectives((openBlock(),createElementBlock(`div`,{class:`form-dialog`,style:normalizeStyle({maxWidth:props.maxWidth}),"bng-ui-scope":unref(scopeName)},[__props.title?(openBlock(),createElementBlock(`div`,_hoisted_2$243,[createBaseVNode(`div`,_hoisted_3$216,toDisplayString(__props.title),1)])):createCommentVNode(``,!0),createBaseVNode(`div`,{class:normalizeClass([{"no-title":!__props.title},`form-dialog-content`])},[message.value?(openBlock(),createElementBlock(`div`,_hoisted_4$185,toDisplayString(message.value),1)):createCommentVNode(``,!0),createBaseVNode(`div`,_hoisted_5$158,[(openBlock(),createBlock(resolveDynamicComponent(__props.view),{modelValue:formModel.value,"onUpdate:modelValue":_cache[0]||=$event=>formModel.value=$event},null,8,[`modelValue`]))])],2),createBaseVNode(`div`,_hoisted_6$136,[(openBlock(!0),createElementBlock(Fragment,null,renderList(__props.buttons,(button,index)=>withDirectives((openBlock(),createBlock(unref(bngButton_default),mergeProps({key:index},{ref_for:!0},button.extras,{disabled:button.disableIfInvalid&&!formValid.value,onClick:$event=>onClick(button)}),{default:withCtx(()=>[createTextVNode(toDisplayString(button.label),1)]),_:2},1040,[`disabled`,`onClick`])),[[unref(BngUiNavFocus_default),__props.buttons.length-index],[unref(BngFocusIf_default),index===0]])),128))])],12,_hoisted_1$295)),[[unref(BngOnUiNav_default),handleCancelWithBack,`back,menu`]])}},FormDialog_default=__plugin_vue_export_helper_default(_sfc_main$334,[[`__scopeId`,`data-v-e78a3aa6`]]),_hoisted_1$294=[`bng-ui-scope`],_hoisted_2$242={class:`popup-content`},_hoisted_3$215={key:0,class:`popup-title`},_hoisted_4$184={class:`popup-body`},_hoisted_5$157={key:0,class:`popup-message`},_hoisted_6$135={class:`popup-buttons`},_sfc_main$333={__name:`Progress`,props:{title:String,message:String,buttons:Array,indeterminate:Boolean,min:{type:Number,default:0},max:{type:Number,default:100},initialValue:{type:Number,default:0},valueLabelFormat:{type:[String,Function],default:()=>val=>`${val}%`},timeout:{type:Number,default:0},cancellable:Boolean,tunnel:Object},emits:[`return`],setup(__props,{emit:__emit}){useUINavBlocker().allowOnly([`focus_u`,`focus_d`,`focus_l`,`focus_r`,`back`,`menu`,`ok`]);let emit$1=__emit,DEFAULT_BUTTON_ID=uniqueId(`___DEFAULT`,`_`),props=__props,defaultButtonIndex=props.buttons.findIndex(button=>button.extras&&button.extras.default),cancelButton=props.buttons.find(button=>button.extras&&button.extras.cancel);~defaultButtonIndex&&onMounted(()=>{document.querySelector(`#${DEFAULT_BUTTON_ID}`).focus()});let scopeName=usePopupUINavScopeName(`_progressPopup`,props),progressValue=ref(props.initialValue),msg=ref(props.message),handleCancelWithBack=e=>{props.cancellable&&close()},close=()=>emit$1(`return`,cancelButton?cancelButton.value:null);return props.tunnel.update=(value,message=void 0)=>{progressValue.value=+value,message!==void 0&&(msg.value=message)},props.tunnel.done=close,props.tunnel.ready=!0,props.timeout&&setTimeout(close,props.timeout*1e3),(_ctx,_cache)=>withDirectives((openBlock(),createElementBlock(`div`,{class:normalizeClass([`popup`]),"bng-ui-scope":unref(scopeName)},[createBaseVNode(`div`,_hoisted_2$242,[__props.title?(openBlock(),createElementBlock(`div`,_hoisted_3$215,toDisplayString(__props.title),1)):createCommentVNode(``,!0),createBaseVNode(`div`,_hoisted_4$184,[msg.value?(openBlock(),createElementBlock(`div`,_hoisted_5$157,toDisplayString(msg.value),1)):createCommentVNode(``,!0),createVNode(unref(bngProgressBar_default),{value:progressValue.value,min:__props.min,max:__props.max,indeterminate:__props.indeterminate,"show-value-label":!__props.indeterminate&&!!__props.valueLabelFormat,"value-label-format":__props.valueLabelFormat},null,8,[`value`,`min`,`max`,`indeterminate`,`show-value-label`,`value-label-format`])]),createBaseVNode(`div`,_hoisted_6$135,[__props.buttons&&__props.buttons.length?(openBlock(!0),createElementBlock(Fragment,{key:0},renderList(__props.buttons,(button,index)=>(openBlock(),createBlock(unref(bngButton_default),mergeProps({key:index},{ref_for:!0},{...index==unref(defaultButtonIndex)&&{id:unref(DEFAULT_BUTTON_ID)},...button.extras},{onClick:$event=>_ctx.$emit(`return`,typeof button.value==`function`?button.value(_ctx.text):button.value)}),{default:withCtx(()=>[createTextVNode(toDisplayString(button.label),1)]),_:2},1040,[`onClick`]))),128)):createCommentVNode(``,!0)])])],8,_hoisted_1$294)),[[unref(BngOnUiNav_default),handleCancelWithBack,`back,menu`]])}},Progress_default=__plugin_vue_export_helper_default(_sfc_main$333,[[`__scopeId`,`data-v-a3c03360`]]),_hoisted_1$293=[`bng-ui-scope`],_hoisted_2$241={class:`popup-content`},_hoisted_3$214={key:0,class:`popup-title`},_hoisted_4$183={class:`popup-body`},_hoisted_5$156={key:0,class:`popup-message`},_hoisted_6$134={class:`popup-buttons`},_sfc_main$332={__name:`Prompt`,props:{buttons:Array,message:String,title:String,maxLength:Number,defaultValue:void 0,validate:Function,errorMessage:String,disableWhenInvalid:Boolean},emits:[`return`],setup(__props,{emit:__emit}){let emit$1=__emit,DEFAULT_BUTTON_ID=uniqueId(`___DEFAULT`,`_`),INPUT_ID=uniqueId(`___INPUT`,`_`),props=__props,scopeName=usePopupUINavScopeName(`_promptPopup`,props),text=ref(props.defaultValue||``),defaultButtonIndex=props.buttons.findIndex(button=>button.extras&&button.extras.default),cancelButton=props.buttons.find(button=>button.extras&&button.extras.cancel),handleEnterButton=text$1=>{props.disableWhenInvalid&&props.validate&&!props.validate(text$1)||emit$1(`return`,text$1)},handleCancelWithBack=e=>{emit$1(`return`,cancelButton?cancelButton.value:null)};return onMounted(()=>{document.querySelector(`#${INPUT_ID} input`).focus()}),(_ctx,_cache)=>withDirectives((openBlock(),createElementBlock(`div`,{class:normalizeClass([`popup`]),"bng-ui-scope":unref(scopeName)},[createBaseVNode(`div`,_hoisted_2$241,[__props.title?(openBlock(),createElementBlock(`div`,_hoisted_3$214,toDisplayString(__props.title),1)):createCommentVNode(``,!0),createBaseVNode(`div`,_hoisted_4$183,[__props.message?(openBlock(),createElementBlock(`div`,_hoisted_5$156,toDisplayString(__props.message),1)):createCommentVNode(``,!0),createVNode(unref(bngInput_default),{id:unref(INPUT_ID),modelValue:text.value,"onUpdate:modelValue":_cache[0]||=$event=>text.value=$event,maxlength:__props.maxLength,onKeyup:_cache[1]||=withKeys($event=>handleEnterButton(text.value),[`enter`]),validate:__props.validate,"error-message":__props.errorMessage},null,8,[`id`,`modelValue`,`maxlength`,`validate`,`error-message`])]),createBaseVNode(`div`,_hoisted_6$134,[(openBlock(!0),createElementBlock(Fragment,null,renderList(__props.buttons,(button,index)=>(openBlock(),createBlock(unref(bngButton_default),mergeProps({key:index},{ref_for:!0},{...index==unref(defaultButtonIndex)&&{id:unref(DEFAULT_BUTTON_ID)},...button.extras},{disabled:__props.disableWhenInvalid&&index>0&&__props.validate&&!__props.validate(text.value),onClick:$event=>_ctx.$emit(`return`,typeof button.value==`function`?button.value(text.value):button.value)}),{default:withCtx(()=>[createTextVNode(toDisplayString(button.label),1)]),_:2},1040,[`disabled`,`onClick`]))),128))])])],8,_hoisted_1$293)),[[unref(BngOnUiNav_default),handleCancelWithBack,`back,menu`]])}},Prompt_default=__plugin_vue_export_helper_default(_sfc_main$332,[[`__scopeId`,`data-v-cce4437b`]]),__default__$9={position:popupPosition.left},_sfc_main$331=Object.assign(__default__$9,{__name:`ScreenOverlay`,props:{view:Object},emits:[`return`],setup(__props){return(_ctx,_cache)=>(openBlock(),createBlock(resolveDynamicComponent(__props.view),{onClose:_cache[0]||=$event=>_ctx.$emit(`return`,!0)},null,32))}}),ScreenOverlay_default=_sfc_main$331,popup_components_exports=__export({Confirmation:()=>Confirmation_default,FormDialog:()=>FormDialog_default,Progress:()=>Progress_default,Prompt:()=>Prompt_default,ScreenOverlay:()=>ScreenOverlay_default}),popupLimit=5,activityLimit=3,count=-1;const PopupTypes=Object.freeze({activity:10,normal:100,priority:1e3});var PopupTypesBack=Object.freeze(Object.keys(PopupTypes).reduce((res,key)=>({...res,[String(PopupTypes[key])]:key}),{})),PopupTypesPairs=Object.freeze(Object.keys(PopupTypes).map(key=>[PopupTypes[key],key]).sort((a$1,b)=>a$1[0]-b[0]));function getPopupTypeName(type=PopupTypes.normal){let strType=String(type);if(strType in PopupTypesBack)return PopupTypesBack[strType];for(let[ptype,pname]of PopupTypesPairs)if(typepopupsAll.filter(itm=>itm.type>=PopupTypes.normal)),activitiesFiltered=computed(()=>popupsAll.filter(itm=>itm.typepopupsFiltered.value.length>0?popupsFiltered.value.slice(-popupLimit):null),popupsWrapper:computed(()=>accumulateWrapper(popupsFiltered.value,getPopupWrapperDefaults())),activities:computed(()=>activitiesFiltered.value.length>0?activitiesFiltered.value.slice(-activityLimit):null),activitiesWrapper:computed(()=>accumulateWrapper(activitiesFiltered.value,getActivityWrapperDefaults()))});function accumulateWrapper(popups,wrapper){for(let popup of popups)wrapper.fade!==popup.wrapper.fade&&(wrapper.fade=popup.wrapper.fade),wrapper.blur!==popup.wrapper.blur&&(wrapper.blur=popup.wrapper.blur),popup.wrapper.style&&wrapper.style.push(...popup.wrapper.style);return wrapper}function addPopup(componentOrName,props={},type=PopupTypes.normal){let component=typeof componentOrName==`string`?popup_components_exports[componentOrName]:componentOrName;if(!component)throw Error(`There is no popup base component named "${componentOrName}".Available components: "${Object.keys(popup_components_exports).join(`", "`)}"`);let popup={id:++count,active:!1,type,typeName:getPopupTypeName(type),component:markRaw({ref:component}),componentName:component.__name,props:{__id:count,...props},position:[popupPosition.default],animated:!0,wrapper:type>=PopupTypes.normal?getPopupWrapperDefaults():getActivityWrapperDefaults()};component.position&&(popup.position=Array.isArray(component.position)?component.position:[component.position]),typeof component.animated==`boolean`&&(popup.animated=component.animated),`wrapper`in component&&(typeof component.wrapper.fade==`boolean`&&(popup.wrapper.fade=component.wrapper.fade),typeof component.wrapper.blur==`boolean`&&(popup.wrapper.blur=component.wrapper.blur),component.wrapper.style&&(popup.wrapper.style=Array.isArray(component.wrapper.style)?component.wrapper.style:[component.wrapper.style])),popup.promise=new Promise((resolve$1,reject)=>{popup._resolve=resolve$1,popup._reject=reject}),popup.return=result=>{for(let i=0;i0&&(popupsAll[popupsAll.length-1].active=!0),reportPopupState(popup,!1);break}result===void 0?popup._reject():popup._resolve(result)},popup.promise.close=popup.return;for(let i=0;itype)return popupsAll.splice(i,0,popup),reportPopupState(popup,!0),popup;return popupsAll.length>0&&(popupsAll[popupsAll.length-1].active=!1),popup.active=!0,popupsAll.push(popup),reportPopupState(popup,!0),popup}function closeLastPopups(count$1=1){popupsAll.slice(-count$1).forEach(popup=>popup.return())}const openMessage=(title,message)=>addPopup(`Confirmation`,{title,message,buttons:[{label:$translate.instant(`ui.common.okay`),value:!0,extras:{default:!0}}]}).promise,openConfirmation=(title,message,buttons=[{label:$translate.instant(`ui.common.okay`),value:!0,extras:{default:!0}},{label:$translate.instant(`ui.common.cancel`),value:!1,extras:{cancel:!0,accent:ACCENTS.secondary}}],appearance=``)=>addPopup(`Confirmation`,{title,message,buttons,appearance}).promise,openPrompt=(message=``,title=``,{buttons=[{label:$translate.instant(`ui.common.okay`),value:text=>text},{label:$translate.instant(`ui.common.cancel`),value:!1,extras:{cancel:!0,accent:ACCENTS.secondary}}],defaultValue,maxLength,validate,errorMessage,disableWhenInvalid}={})=>addPopup(`Prompt`,{message,title,buttons,defaultValue,maxLength,validate,errorMessage,disableWhenInvalid}).promise,openExperimental=(title,message,buttons=[{label:$translate.instant(`ui.common.yes`),value:!0},{label:$translate.instant(`ui.common.no`),value:!1}])=>addPopup(`Confirmation`,{title,message,buttons,appearance:`experimental`}).promise,openScreenOverlay=component=>addPopup(`ScreenOverlay`,{view:markRaw(component)},PopupTypes.activity).promise,openFormDialog=(component,formModel,formValidator,title,description,buttons=[{label:$translate.instant(`ui.common.okay`),value:!0,emitData:!0},{label:$translate.instant(`ui.common.cancel`),value:!1,extras:{cancel:!0,accent:ACCENTS.secondary}}],maxWidth)=>addPopup(`FormDialog`,{view:markRaw(component),formModel,formValidator,title,description,buttons,maxWidth},PopupTypes.normal).promise,openProgress=(message=``,title=``,{buttons=[],indeterminate,min:min$1,max:max$1,initialValue,valueLabelFormat,timeout,cancellable}={})=>{let popup=addPopup(`Progress`,{message,title,buttons,indeterminate,min:min$1,max:max$1,initialValue,valueLabelFormat,timeout,cancellable,tunnel:{}});return popup.progress=popup.props.tunnel,popup.progress.done=popup.return,popup},fixedDelayPopup=(seconds,{makeRemainingText=s=>s?Math.round(s)+`s remaining...`:`Done!`,title=``}={})=>{let popup=openProgress(makeRemainingText(seconds),title,{timeout:seconds+1}),remaining=seconds,endTime=Date.now()+remaining*1e3,countdown=()=>{let timeLeft=(endTime-Date.now())/1e3;timeLeft>0?(remaining=timeLeft,requestAnimationFrame(countdown)):remaining=0,popup.progress.update(~~((seconds-remaining)*100/seconds),makeRemainingText(remaining))};return requestAnimationFrame(countdown),popup};var _hoisted_1$292={class:`activity-selector`},_hoisted_2$240={class:`activities-container`},_hoisted_3$213=[`onClick`],_hoisted_4$182={class:`selector-display`},selectConfig={label:x=>x.label,value:x=>x.value},_sfc_main$330={__name:`ActivitySelector`,props:{activities:{type:Array,required:!0},value:{type:[String,Number]},navLeftEvent:{type:String},navRightEvent:{type:String}},emits:[`valueChanged`],setup(__props,{expose:__expose,emit:__emit}){let props=__props,selectComponent=ref(),emit$1=__emit,activityOptions=computed(()=>props.activities.map((x,index)=>({label:index+1,value:x.value})));computed(()=>(activityOptions.value?activityOptions.value.find(x=>x.value===selectedValue.value):null)||{label:`?`,value:selectedValue.value});let selectedValue=ref(1);watch(()=>props.value,val=>selectedValue.value=val||props.activities[0].value,{immediate:!0});let onValueChanged=value=>{selectedValue.value=value,console.log(`onValueChanged`,value),emit$1(`valueChanged`,value)};return __expose({goNext:()=>selectComponent.value.goNext(),goPrev:()=>selectComponent.value.goPrev()}),computed(()=>`url("${getAssetURL(`icons/temp_debug/map_poi_target.svg`)}")`),(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$292,[createBaseVNode(`div`,_hoisted_2$240,[(openBlock(!0),createElementBlock(Fragment,null,renderList(__props.activities,activity=>(openBlock(),createElementBlock(`div`,{key:activity,class:normalizeClass([`activity-icon`,{highlighted:activity.value===selectedValue.value}]),onClick:$event=>onValueChanged(activity.value)},[createVNode(unref(bngSpriteIcon_default),{src:`map_`+activity.icon,style:{width:`100%`,height:`100%`}},null,8,[`src`])],10,_hoisted_3$213))),128))]),createVNode(unref(bngSelect_default),{ref_key:`selectComponent`,ref:selectComponent,value:selectedValue.value,options:activityOptions.value,config:selectConfig,mute:``,loop:``,onChange:onValueChanged,navLeftEvent:__props.navLeftEvent,navRightEvent:__props.navRightEvent},{display:withCtx(({label})=>[createBaseVNode(`div`,_hoisted_4$182,[createBaseVNode(`span`,null,toDisplayString(label),1),createVNode(unref(bngDivider_default)),createBaseVNode(`span`,null,toDisplayString(__props.activities.length),1)])]),_:1},8,[`value`,`options`,`navLeftEvent`,`navRightEvent`])]))}},ActivitySelector_default=__plugin_vue_export_helper_default(_sfc_main$330,[[`__scopeId`,`data-v-53fb9327`]]),_hoisted_1$291={key:0,class:`activity-start`,"bng-ui-scope":`activityStart`},_hoisted_2$239={class:`activity-props`},_hoisted_3$212={class:`binding-spacer`},BNG_MAIN_STARS_TYPE=`BngMainStars`,_sfc_main$329={__name:`ActivityStart`,setup(__props){useUINavScope(`activityStart`);let activitySelector=ref(null),goNext=()=>activitySelector.value&&activitySelector.value.goNext(),goPrev=()=>activitySelector.value&&activitySelector.value.goPrev(),gameContextStore=useGameContextStore(),{activities}=storeToRefs(gameContextStore),{closeActivitiesPrompt}=gameContextStore,selectedActivityIndex=ref(0),availableActivities=ref([]),activityOptions=computed(()=>{let result=availableActivities.value?availableActivities.value.map((x,index)=>({id:index,value:index,icon:x.icon})):[];return doFiltering&&filterEvents(result.length>1),result}),selectedActivity=computed(()=>{if(selectedActivityIndex.value<0||!availableActivities.value||availableActivities.value.length===0)return null;let activity=availableActivities.value[selectedActivityIndex.value],labels=activity.props&&activity.props.length>0?activity.props.filter(x=>!x.type):[];return{heading:activity.heading,icon:activity.icon,preheadings:activity.preheadings,labels:labels.map(x=>({keyLabel:$translate.instant(x.keyLabel),valueLabel:$translate.instant(x.valueLabel),icon:icons[x.icon]})),stars:activity.props&&activity.props.length>0?activity.props.find(x=>x.type===BNG_MAIN_STARS_TYPE):null,startable:!0,buttonLabel:activity.buttonLabel,action:activity.action,missionInfoPerformActionIndex:activity.missionInfoPerformActionIndex}}),preheadings=computed(()=>selectedActivity.value&&selectedActivity.value.preheadings?selectedActivity.value.preheadings.map(x=>$translate.contextTranslate(x)):[]),invokeActivityAction=()=>{Lua_default.ui_missionInfo.performActivityAction(selectedActivity.value.missionInfoPerformActionIndex)};watch(selectedActivity,()=>{Lua_default.ui_missionInfo.setActivityIndexVisible(selectedActivityIndex.value)});let onActivitySelected=value=>{selectedActivityIndex.value=value},onCancel=()=>{closeActivitiesPrompt()},openPauseMenu=()=>{onCancel(),window.globalAngularRootScope&&window.globalAngularRootScope.$broadcast(`MenuToggle`)};onBeforeMount(()=>{availableActivities.value=activities.value}),onMounted(()=>{getUINavServiceInstance().activate()}),onUnmounted(()=>{doFiltering=!1,getUINavServiceInstance().setFilteredEventsAllExcept(UI_EVENTS.menu,UI_EVENTS.pause,UI_EVENTS.center_cam),Lua_default.ui_missionInfo.setActivityIndexVisible(-1)});let doFiltering=!0,filterEvents=withTabs=>getUINavServiceInstance().setFilteredEventsAllExcept(UI_EVENTS.back,UI_EVENTS.menu,UI_EVENTS.pause,UI_EVENTS.center_cam,...withTabs?[UI_EVENTS.tab_l,UI_EVENTS.tab_r]:[]);return(_ctx,_cache)=>selectedActivity.value?withDirectives((openBlock(),createElementBlock(`div`,_hoisted_1$291,[activityOptions.value&&activityOptions.value.length>1?(openBlock(),createBlock(ActivitySelector_default,{key:0,ref_key:`activitySelector`,ref:activitySelector,activities:activityOptions.value,value:selectedActivityIndex.value,onValueChanged:onActivitySelected,navLeftEvent:`tab_l`,navRightEvent:`tab_r`},null,8,[`activities`,`value`])):createCommentVNode(``,!0),selectedActivity.value.heading?(openBlock(),createBlock(unref(bngScreenHeading_default),{key:1,mute:``,divider:``,preheadings:preheadings.value,"blur-delay":400},{default:withCtx(()=>[createTextVNode(toDisplayString(_ctx.$ctx_t(selectedActivity.value.heading)),1),selectedActivity.value.description?(openBlock(),createElementBlock(Fragment,{key:0},[createTextVNode(`: `+toDisplayString(_ctx.$ctx_t(selectedActivity.value.description)),1)],64)):createCommentVNode(``,!0)]),_:1},8,[`preheadings`])):createCommentVNode(``,!0),createBaseVNode(`div`,_hoisted_2$239,[selectedActivity.value.stars&&selectedActivity.value.stars.defaultStarCount?(openBlock(),createBlock(unref(bngMainStars_default),{key:0,"unlocked-stars":selectedActivity.value.stars.defaultUnlockedStarCount,"total-stars":selectedActivity.value.stars.defaultStarCount,class:`main-stars`},null,8,[`unlocked-stars`,`total-stars`])):createCommentVNode(``,!0),selectedActivity.value.stars&&selectedActivity.value.stars.bonusStarCount?(openBlock(),createBlock(unref(bngMainStars_default),{key:1,"unlocked-stars":selectedActivity.value.stars.bonusStarsUnlockedCount,"total-stars":selectedActivity.value.stars.bonusStarCount,class:`bonus-stars`},null,8,[`unlocked-stars`,`total-stars`])):createCommentVNode(``,!0),(openBlock(!0),createElementBlock(Fragment,null,renderList(selectedActivity.value.labels,(label,index)=>(openBlock(),createBlock(unref(bngPropVal_default),{key:index,iconType:label.icon,keyLabel:label.keyLabel,valueLabel:label.valueLabel},null,8,[`iconType`,`keyLabel`,`valueLabel`]))),128))]),createBaseVNode(`div`,null,[withDirectives((openBlock(),createBlock(unref(bngButton_default),{accent:unref(ACCENTS).main,onClick:invokeActivityAction},{default:withCtx(()=>[createBaseVNode(`span`,_hoisted_3$212,[createVNode(unref(bngBinding_default),{action:`gameplay_interact`})]),selectedActivity.value.startable?(openBlock(),createElementBlock(Fragment,{key:0},[createTextVNode(toDisplayString(_ctx.$ctx_t(selectedActivity.value.buttonLabel)),1)],64)):(openBlock(),createElementBlock(Fragment,{key:1},[createTextVNode(toDisplayString(_ctx.$tt(`ui.mission.action.locked`)),1)],64))]),_:1},8,[`accent`])),[[unref(BngOnUiNav_default),void 0,`gameplay_interact`,{asMouse:!0}]]),withDirectives((openBlock(),createBlock(unref(bngButton_default),{accent:unref(ACCENTS).secondary,onClick:onCancel},{default:withCtx(()=>[createVNode(unref(bngBinding_default),{"ui-event":`back`,controller:``}),createTextVNode(` `+toDisplayString(_ctx.$tt(`ui.common.close`)),1)]),_:1},8,[`accent`])),[[unref(BngOnUiNav_default),void 0,`back`,{asMouse:!0}]])])])),[[unref(BngOnUiNav_default),goPrev,`tab_l`,{up:!0}],[unref(BngOnUiNav_default),goNext,`tab_r`,{up:!0}],[unref(BngOnUiNav_default),openPauseMenu,`menu`]]):createCommentVNode(``,!0)}},ActivityStart_default=__plugin_vue_export_helper_default(_sfc_main$329,[[`__scopeId`,`data-v-1f131cb6`]]),_hoisted_1$290={class:`recovery-wrapper`,"bng-ui-scope":`recoveryPrompt`},_hoisted_2$238={class:`content`},_hoisted_3$211={class:`label`},_hoisted_4$181={key:0,class:`more-options`},_hoisted_5$155={key:0,class:`notification`},__default__$8={wrapper:{fade:!0,blur:!0,style:popupContainer.transparent},position:[popupPosition.center,popupPosition.center]},_sfc_main$328=Object.assign(__default__$8,{__name:`Recovery`,emits:[`return`],setup(__props,{emit:__emit}){let{events:events$3}=useBridge();useUINavScope(`recoveryPrompt`);let emit$1=__emit,{closeRecoveryPrompt}=useGameContextStore(),popupData=ref({}),clickHandler=(index,button,fromController)=>{button.confirmationText||executeButtonAction(index,button)},executeButtonAction=(index,button)=>{Lua_default.core_recoveryPrompt.uiPopupButtonPressed(index+1),button.keepMenuOpen||(closeRecoveryPrompt(),emit$1(`return`,!0))},cancelClickHandler=()=>{Lua_default.core_recoveryPrompt.uiPopupCancelPressed(),popupData.value.cancelButton.keepMenuOpen||(closeRecoveryPrompt(),emit$1(`return`,!0))},updateRecoveryPopupData=()=>{Lua_default.core_recoveryPrompt.getUIData().then(value=>popupData.value=value)};return events$3.on(`updateRecoveryPopupData`,updateRecoveryPopupData),onMounted(()=>{getUINavServiceInstance().activate(),getUINavServiceInstance().clearFilteredEvents(),updateRecoveryPopupData()}),onUnmounted(()=>{events$3.off(`updateRecoveryPopupData`,updateRecoveryPopupData),window.bngVue.getCurrentRoute().name==`unknown`&&getUINavServiceInstance().setFilteredEventsAllExcept(UI_EVENTS.menu,UI_EVENTS.pause,UI_EVENTS.center_cam)}),(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$290,[createVNode(unref(bngCard_default),null,{buttons:withCtx(()=>[unref(popupData).cancelButton?withDirectives((openBlock(),createBlock(unref(bngButton_default),{key:0,label:unref(popupData).cancelButton.label,accent:unref(ACCENTS).attention,onClick:cancelClickHandler},null,8,[`label`,`accent`])),[[unref(BngOnUiNav_default),void 0,`back,menu`,{asMouse:!0}]]):createCommentVNode(``,!0)]),default:withCtx(()=>[createVNode(unref(bngCardHeading_default),{type:`ribbon`},{default:withCtx(()=>[createTextVNode(toDisplayString(unref(popupData).title),1)]),_:1}),createBaseVNode(`div`,_hoisted_2$238,[(openBlock(!0),createElementBlock(Fragment,null,renderList(unref(popupData).buttons,(button,index)=>withDirectives((openBlock(),createBlock(unref(bngButton_default),{"show-hold":!!button.confirmationText,"hold-vertical":``,accent:unref(ACCENTS).outlined,class:`recovery-option-button`},{default:withCtx(()=>[createVNode(unref(bngImageTile_default),{class:`recovery-option-tile`,icon:unref(icons)[button.icon]},{default:withCtx(()=>[createBaseVNode(`span`,_hoisted_3$211,toDisplayString(_ctx.$ctx_t(button.label)),1),button.price?(openBlock(),createBlock(unref(bngDivider_default),{key:0})):createCommentVNode(``,!0),button.price?(openBlock(),createBlock(unref(bngUnit_default),{key:1,class:`units`,money:button.price.money.amount,options:{formatter:x=>~~x}},null,8,[`money`,`options`])):createCommentVNode(``,!0)]),_:2},1032,[`icon`]),button.keepMenuOpen?(openBlock(),createElementBlock(`span`,_hoisted_4$181,`⇢`)):createCommentVNode(``,!0)]),_:2},1032,[`show-hold`,`accent`])),[[unref(BngDisabled_default),!button.enabled],[unref(BngFocusIf_default),!index||button.enabled&&!unref(popupData).buttons[0].enabled],[unref(BngOnUiNav_default),void 0,`ok`,{asMouse:!0,focusRequired:!0}],[unref(BngClick_default),{clickCallback:e=>clickHandler(index,button,e.fromController),holdCallback:button.confirmationText?()=>executeButtonAction(index,button):null,holdDelay:500,repeatInterval:0}]])),256)),unref(popupData).warningMessage?(openBlock(),createElementBlock(`div`,_hoisted_5$155,toDisplayString(unref(popupData).warningMessage),1)):createCommentVNode(``,!0)])]),_:1})]))}}),Recovery_default=__plugin_vue_export_helper_default(_sfc_main$328,[[`__scopeId`,`data-v-8495e64c`]]),_hoisted_1$289={class:`item-container`,navigable:``,tabindex:`0`},_hoisted_2$237={class:`item-content`},_hoisted_3$210={class:`item-container indented`,navigable:``,tabindex:`0`},_hoisted_4$180={class:`item-content`},_sfc_main$327={__name:`FavoriteSelectionItem`,props:{data:Object,level:{type:Number,default:0}},emits:[`addedFunction`,`removedFunction`],setup(__props,{emit:__emit}){let emit$1=__emit,expandedStates=ref({}),focusedItem=ref(null),toggleExpanded=(idx,value)=>{expandedStates.value[idx]=value},select=item=>{focusedItem.value=item},deselect=item=>{focusedItem.value===item&&(focusedItem.value=null)},isFocused=item=>focusedItem.value===item,addActionToQuickAccess=item=>{console.log(`addActionToQuickAccess`,item),item&&item.uniqueID&&emit$1(`addedFunction`,item)},removeFunction=()=>{emit$1(`removedFunction`)};return(_ctx,_cache)=>{let _component_FavoriteSelectionItem=resolveComponent(`FavoriteSelectionItem`,!0);return openBlock(),createBlock(unref(accordion_default),{class:`favorite-selection-item`,expanded:__props.data.expanded},{default:withCtx(()=>[(openBlock(!0),createElementBlock(Fragment,null,renderList(__props.data.items,(item,idx)=>(openBlock(),createElementBlock(`div`,{key:idx,class:`item-wrapper`},[item.items?(openBlock(),createBlock(unref(accordionItem_default),{key:0,navigable:``,static:!item.items,expanded:expandedStates.value[idx],onExpanded:$event=>toggleExpanded(idx,$event),"arrow-big":``,onMouseover:withModifiers($event=>select(item),[`stop`]),onMouseleave:withModifiers($event=>deselect(item),[`stop`]),onFocusin:withModifiers($event=>select(item),[`stop`]),onFocusout:withModifiers($event=>deselect(item),[`stop`]),"primary-action":()=>addActionToQuickAccess(item),"primary-label":`ui.inputActions.menu.menu_item_select.title`,"expand-hint-inline":``},{caption:withCtx(()=>[createBaseVNode(`div`,_hoisted_1$289,[createBaseVNode(`div`,_hoisted_2$237,[createVNode(unref(bngIcon_default),{type:unref(icons)[item.icon]},null,8,[`type`]),createTextVNode(` `+toDisplayString(item.title?unref($translate).instant(item.title):item.niceName),1)]),item.uniqueID&&isFocused(item)?(openBlock(),createBlock(unref(bngButton_default),{key:0,accent:`outlined`,class:`select-button`,onClick:$event=>addActionToQuickAccess(item),"bng-no-nav":``},{default:withCtx(()=>[createVNode(unref(bngBinding_default),{class:`input-icon`,"ui-event":`ok`,controller:``}),_cache[0]||=createTextVNode(` Select `,-1)]),_:1},8,[`onClick`])):createCommentVNode(``,!0)])]),default:withCtx(()=>[createVNode(_component_FavoriteSelectionItem,{data:item,level:__props.level+1,onAddedFunction:addActionToQuickAccess,onRemovedFunction:removeFunction},null,8,[`data`,`level`])]),_:2},1032,[`static`,`expanded`,`onExpanded`,`onMouseover`,`onMouseleave`,`onFocusin`,`onFocusout`,`primary-action`])):(openBlock(),createBlock(unref(accordionItem_default),{key:1,static:!0,navigable:``,onMouseover:withModifiers($event=>select(item),[`stop`]),onMouseleave:withModifiers($event=>deselect(item),[`stop`]),onFocusin:withModifiers($event=>select(item),[`stop`]),onFocusout:withModifiers($event=>deselect(item),[`stop`]),"primary-action":()=>addActionToQuickAccess(item),"primary-label":`ui.inputActions.menu.menu_item_select.title`},{caption:withCtx(()=>[createBaseVNode(`div`,_hoisted_3$210,[createBaseVNode(`div`,_hoisted_4$180,[item.icon?(openBlock(),createBlock(unref(bngIcon_default),{key:0,type:unref(icons)[item.icon]},null,8,[`type`])):createCommentVNode(``,!0),createTextVNode(` `+toDisplayString(unref($translate).instant(item.title)),1)]),item.uniqueID&&isFocused(item)?(openBlock(),createBlock(unref(bngButton_default),{key:0,class:`select-button`,onClick:$event=>addActionToQuickAccess(item),accent:`outlined`,"bng-no-nav":``},{default:withCtx(()=>[createVNode(unref(bngBinding_default),{class:`input-icon`,"ui-event":`ok`,controller:``}),_cache[1]||=createTextVNode(` Select `,-1)]),_:1},8,[`onClick`])):createCommentVNode(``,!0)])]),_:2},1032,[`onMouseover`,`onMouseleave`,`onFocusin`,`onFocusout`,`primary-action`]))]))),128))]),_:1},8,[`expanded`])}}},FavoriteSelectionItem_default=__plugin_vue_export_helper_default(_sfc_main$327,[[`__scopeId`,`data-v-dd594aec`]]),_hoisted_1$288={class:`backgroundContainer`},_hoisted_2$236={key:0,class:`recovery-wrapper`,"bng-ui-scope":`favoriteSelection`},_hoisted_3$209={class:`current-action-container`},_hoisted_4$179={key:0},_hoisted_5$154={key:1},_hoisted_6$133={key:2},_hoisted_7$119={key:0,class:`content`},__default__$7={wrapper:{fade:!0,blur:!0,style:popupContainer.transparent},position:[popupPosition.center,popupPosition.center]},_sfc_main$326=Object.assign(__default__$7,{__name:`FavoriteSelection`,emits:[`return`],setup(__props,{emit:__emit}){let{events:events$3}=useBridge();useUINavScope(`favoriteSelection`);let emit$1=__emit,{closeRecoveryPrompt}=useGameContextStore(),data=ref({}),updateFavoritePopupData=()=>{Lua_default.core_quickAccess.getDynamicSlotConfigurationData().then(value=>data.value=value)};events$3.on(`radialFavoriteSelectionPopupData`,updateFavoritePopupData);let addedFunction=item=>{let config={uniqueID:item.uniqueID,level:item.level,type:item.type,mode:item.mode||`uniqueAction`};console.log(`addedFunction`,config),Lua_default.core_quickAccess.setDynamicSlotConfiguration(data.value.dynamicSlotKey,config),emit$1(`return`,!0)},removeFunction=()=>{Lua_default.core_quickAccess.removeActionFromQuickAccess(data.value.slotIndex),emit$1(`return`,!0)},close=()=>{emit$1(`return`,!0)};return onMounted(()=>{updateFavoritePopupData()}),onUnmounted(()=>{events$3.off(`radialFavoriteSelectionPopupData`,updateFavoritePopupData),window.bngVue.getCurrentRoute().name==`unknown`&&getUINavServiceInstance().setFilteredEventsAllExcept(UI_EVENTS.menu,UI_EVENTS.pause,UI_EVENTS.center_cam)}),(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$288,[unref(data).dynamicSlotKey?(openBlock(),createElementBlock(`div`,_hoisted_2$236,[createVNode(unref(bngCard_default),null,{default:withCtx(()=>[createVNode(unref(bngCardHeading_default),{type:`ribbon`},{default:withCtx(()=>[createTextVNode(` Assign Action to: `+toDisplayString(unref(data).dynamicSlotData.breadcrumbs[0]),1)]),_:1}),createBaseVNode(`div`,_hoisted_3$209,[_cache[3]||=createBaseVNode(`div`,{class:`current-action-label`},`Currently Assigned Action:`,-1),unref(data).dynamicSlotData.mode===`uniqueAction`&&unref(data).uniqueAction?(openBlock(),createElementBlock(`div`,_hoisted_4$179,[unref(data).uniqueAction.icon?(openBlock(),createBlock(unref(bngIcon_default),{key:0,type:unref(icons)[unref(data).uniqueAction.icon]},null,8,[`type`])):createCommentVNode(``,!0),createTextVNode(` `+toDisplayString(unref(data).uniqueAction.title?unref($translate).instant(unref(data).uniqueAction.title):unref(data).uniqueAction.niceName),1)])):createCommentVNode(``,!0),unref(data).dynamicSlotData.mode===`recentActions`?(openBlock(),createElementBlock(`div`,_hoisted_5$154,[createVNode(unref(bngIcon_default),{type:unref(icons).timer},null,8,[`type`]),_cache[1]||=createTextVNode(` Most Recent Action `,-1)])):createCommentVNode(``,!0),unref(data).dynamicSlotData.mode===`empty`?(openBlock(),createElementBlock(`div`,_hoisted_6$133,[createVNode(unref(bngIcon_default),{type:unref(icons).circleSlashed},null,8,[`type`]),_cache[2]||=createTextVNode(` Empty `,-1)])):createCommentVNode(``,!0)]),_cache[5]||=createBaseVNode(`div`,{class:`divider`},null,-1),unref(data).items?(openBlock(),createElementBlock(`div`,_hoisted_7$119,[createVNode(FavoriteSelectionItem_default,{data:unref(data).items,onAddedFunction:addedFunction,onRemovedFunction:removeFunction},null,8,[`data`])])):createCommentVNode(``,!0),withDirectives((openBlock(),createBlock(unref(bngButton_default),{class:`cancel-button`,onClick:_cache[0]||=$event=>close(),accent:`attention`},{default:withCtx(()=>[createVNode(unref(bngBinding_default),{class:`input-icon`,"ui-event":`back`,controller:``}),_cache[4]||=createTextVNode(` Cancel `,-1)]),_:1})),[[unref(BngOnUiNav_default),void 0,`back,menu`,{asMouse:!0}]])]),_:1})])):createCommentVNode(``,!0)]))}}),FavoriteSelection_default=__plugin_vue_export_helper_default(_sfc_main$326,[[`__scopeId`,`data-v-88390882`]]);const useGameContextStore=defineStore(`gameContext`,()=>{let{events:events$3}=useBridge(),activities=ref([]),activityScreen=null,recoveryPrompt=null,radialFavoriteSelectionPrompt=null,deliveryEndScreen=null,simpleDelayPopup=null,startMission=missionId=>{let mission=activities.value.find(x=>x.id===missionId);mission||console.error(`Mission not found ${missionId}. cannot start`);let settings$1=mission.settings,userSettings=mission&&settings$1?settings$1.reduce((a$1,b)=>a$1[b.key]=b.value,a):{};Lua_default.gameplay_markerInteraction.startMissionById(mission.id,userSettings)},closeActivitiesPrompt=()=>{Lua_default.gameplay_markerInteraction.closeViewDetailPrompt(!0)};function openRecoveryPrompt(){recoveryPrompt=addPopup(Recovery_default).promise}function openDynamicSlotConfigurator(){radialFavoriteSelectionPrompt=addPopup(FavoriteSelection_default).promise}function openSimpleDelayPopup(data){simpleDelayPopup=fixedDelayPopup(data.timer,{title:data.heading})}let performActivityAction=activityActionIndex=>Lua_default.ui_missionInfo.performActivityAction(activityActionIndex);events$3.on(`ActivityAcceptUpdate`,onActivityAcceptUpdate),events$3.on(`ActivityAcceptClose`,closeActivitiesPopup),events$3.on(`MenuOpenModule`,closeActivitiesPopup),events$3.on(`ChangeState`,closeActivitiesPopup),events$3.on(`OpenRecoveryPrompt`,openRecoveryPrompt),events$3.on(`OpenDynamicSlotConfigurator`,openDynamicSlotConfigurator),events$3.on(`OpenSimpleDelayPopup`,openSimpleDelayPopup);let deliveryRewardData=ref(!1);function showDeliveryEndScreen(data){deliveryRewardData.value=data,window.bngVue.gotoGameState(`cargoDeliveryReward`)}events$3.on(`OpenDeliveryEndScreen`,showDeliveryEndScreen);function onActivityAcceptUpdate(data){activityScreen&&(activities.value||!data)&&closeActivitiesPopup(),window.location.hash===`#/play`&&(activities.value=data,activities.value&&activities.value.length>0&&(activityScreen=openScreenOverlay(ActivityStart_default)))}function closeActivitiesPopup(){activityScreen&&=(activityScreen.close(!0),null)}function closeRecoveryPrompt(){recoveryPrompt&&=(recoveryPrompt.close(!0),null)}function closeRadialFavoriteSelectionPrompt(){radialFavoriteSelectionPrompt&&=(radialFavoriteSelectionPrompt.close(!0),null)}function closeSimpleDelayPopup(){simpleDelayPopup&&=(simpleDelayPopup.progress.done(),null)}function closeDeliveryEndScreen(){deliveryEndScreen&&=(deliveryEndScreen.close(!0),null)}function dispose$2(){events$3.off(`ActivityAcceptUpdate`,onActivityAcceptUpdate),events$3.off(`ActivityAcceptClose`,closeActivitiesPopup)}return{activities,closeActivitiesPrompt,closeDeliveryEndScreen,closeRecoveryPrompt,closeRadialFavoriteSelectionPrompt,closeSimpleDelayPopup,deliveryRewardData,dispose:dispose$2,performActivityAction,startMission}});var PARSE_NESTED$1=`PARSE_NESTED`,bbcode_main_default=[[/\[url=https?:\/\/([^\s\]]+)\](.*?(?=\[\/url\]))\[\/url\]/gi,`$2`],[/\[url='https?:\/\/([^\s\]]+)'\](.*?(?=\[\/url\]))\[\/url\]/gi,`$2`],[/\[forumurl=https?:\/\/([^\s\]]+)\](\S*?(?=\[\/forumurl\]))\[\/forumurl\]/gi,`$2`],[/\[url\]https?:\/\/(.*?(?=\[\/url\]))\[\/url\]/gi,`$1`],[/\[url=([^\s\]]+)\](.*?(?=\[\/url\]))\[\/url\]/gi,`$2`],[/\[h(\d)\](.*?(?=\[\/h\d\]))\[\/h\d\]/gi,`$2`],[/\[img\]\s*?(\S*?(?=\[\/img\]))\[\/img\]/gi,``],[/\shttp(s|):\/\/(\S*)/gi,`http$1://$2`],[/\[list=\d+\](.*?(?=\[\/list\]))\[\/list\]/gi,`
      $1
    `],[/\[list\]/gi,`
      `],[/\[\/list\]/gi,`
    `],[/\[olist\]/gi,`
      `],[/\[\/olist\]/gi,`
    `],[/\[(\*|\+)\]\s*?((.|\s)*?(?=\[(\*|\+)\]|\<\/ul\>|\<\/ol\>|\n\n|$))/gim,`
  • $2
  • `],[PARSE_NESTED$1,/\[b\](.*?(?=\[\/b\]))\[\/b\]/gi,`$1`],[PARSE_NESTED$1,/\[u\](.*?(?=\[\/u\]))\[\/u\]/gi,`$1`],[PARSE_NESTED$1,/\[s\](.*?(?=\[\/s\]))\[\/s\]/gi,`$1`],[PARSE_NESTED$1,/\[i\](.*?(?=\[\/i\]))\[\/i\]/gi,`$1`],[/\[strike\](.*?(?=\[\/strike\]))\[\/strike\]/gi,`$1`],[/\[code\](.*?(?=\[\/code\]))\[\/code\]/gi,`$1`],[/\[br\]/gi,`
    `],[/\n\n/gi,`

    `],[/\n/gi,`
    `],[/\[attach=?f?u?l?l?\](.*?(?=\[\/attach\]))\[\/attach\]/gi,``],[/\[USER=([\d]+)\](.*?(?=\[\/USER\]))\[\/USER\]/gi,`$2`],[/\[MEDIA=youtube\](.*?(?=\[\/MEDIA\]))\[\/MEDIA\]/gi,`
    `],[/\[MEDIA=beamng\](.*?(?=\[\/MEDIA\]))\[\/MEDIA\]/gi,``],[PARSE_NESTED$1,/\[size=(\d+)\]([^[]*(?:\[(?!size=\d+\]|\/size\])[^[]*)*)\[\/size\]/gi,`$2`],[PARSE_NESTED$1,/\[COLOR=([a-z0-9\#\, \'\"\(\)]+)\]([^[]*(?:\[(?!COLOR=[a-z0-9#\(\)]+\]|\/COLOR\])[^[]*)*)\[\/COLOR\]/gi,`$2`],[PARSE_NESTED$1,/\[font=([^\]]+)\](.*?(?=\[\/font\]))\[\/font\]/gi,`$2`],[/\[hr\]\[\/hr\]/gi,`
    `],[/\[spoiler=([^\]]+)\](.*?(?=\[\/spoiler\]))\[\/spoiler\]/gi,`
    Spoiler: $1
    $2
    `],[/\[spoiler\](.*?(?=\[\/spoiler\]))\[\/spoiler\]/gi,`
    Spoiler
    $1
    `],[PARSE_NESTED$1,/\[left\](.*?(?=\[\/left\]))\[\/left\]/gi,`

    $1

    `],[PARSE_NESTED$1,/\[center\](.*?(?=\[\/center\]))\[\/center\]/gi,`

    $1

    `],[PARSE_NESTED$1,/\[right\](.*?(?=\[\/right\]))\[\/right\]/gi,`

    $1

    `],[PARSE_NESTED$1,/\*\*(.*?(?=\*\*))\*\*/gi,`$1`],[PARSE_NESTED$1,/\*(.*?(?=\*))\*/gi,`$1`],[PARSE_NESTED$1,/\[(.*?(?=\]\())\]\((https?:\/\/((.*?(?=\)))))\)/gi,`$1 ($2)`]],bbcode_vue_default=[[/\[ico=([^\s\]]+)\s*\](.*?(?=\[\/ico\]))\[\/ico\]/gi,`$2`],[/\[ico=([^\s\]]+)\s*\]/gi,``],[/\[action=(.*?)\]\[showunassigned=(.*?)\](.*?)/gi,``],[/\[action=(.*?)\](.*?)/gi,``],[/\[action=(.*?)\]/gi,``],[/\[(money|beamXP|stars|vouchers)=(.*?)\]/g,``]],bbcode_angular_default=[[/\[ico=([^\s\]]+)\s*\](.*?(?=\[\/ico\]))\[\/ico\]/gi,`$2`],[/\[ico=([^\s\]]+)\s*\]/gi,``],[/\[action=(.*?)\]\[showunassigned=(.*?)\](.*?)/gi,``],[/\[action=(.*?)\](.*?)/gi,``],[/\[action=(.*?)\]/gi,``]],bbcode_exports=__export({parse:()=>parse$1,useExtensions:()=>useExtensions}),PARSE_NESTED=`PARSE_NESTED`,_extensions=bbcode_vue_default;const useExtensions=exts=>_extensions=exts,parse$1=(txt,extensions$1=_extensions)=>{let text=``+txt;return[...bbcode_main_default,...extensions$1].forEach(replacement=>{let{nested,fromTo}=replacementDetails(replacement);text=nested?parseNested(text,...fromTo):text.replace(...fromTo)}),text};window.angularParseBBCode=txt=>parse$1(txt,bbcode_angular_default);var replacementDetails=replacement=>({nested:replacement.length==3&&replacement[0]===PARSE_NESTED,fromTo:replacement.slice(-2)}),parseNested=(text,regex,template)=>{for(;~text.search(regex);)text=text.replace(regex,template);return text},markdown_exports=__export({parse:()=>parse});function parse(src){let h$1=``;return src.replace(/^\s+|\r|\s+$/g,``).replace(/\t/g,` `).split(/\n\n+/).forEach(function(b,f,R){f=b[0],R={"*":[/\n\* /,`
    • `,`
    `],1:[/\n[1-9]\d*\.? /,`
    1. `,`
    `]," ":[/\n {4}/,`
    `,`
    `,` `],">":[/\n> /,`
    `,`
    `,`
    `+b).split(R[0]).slice(1).map(R[3]?escape:inlineEscape).join(R[3]||`
    
  • `)+R[2]:f===`#`?``+inlineEscape(b.slice(f+1))+``:f===`<`?b:`

    `+inlineEscape(b)+`

    `}),h$1}function escape(t){return new Option(t).innerHTML}function inlineEscape(s){return escape(s).replace(/\\_/g,`⋿`).replace(/!\[([^\]]*)]\(([^(]+)\)/g,`$1`).replace(/\[([^\]]+)]\(([^(]+?)\)/g,`$1`.link(`$2`)).replace(/`([^`]+)`/g,`$1`).replace(/(\*\*|__)(?=\S)([^\r]*?\S[*_]*)\1/g,`$2`).replace(/(\*| _)(?=\S)([^\r]*?\S)\1/g,`$2`).replace(/⋿/g,`_`)}var content_exports=__export({bbcode:()=>bbcode_exports,markdown:()=>markdown_exports});const screenLocked=computed(()=>screenLockedState.value),loadingScreen=reactive({active:!1,visible:!1,fading:!1,shown:!1});var screenLockedState=ref(!1),loadingScreenStateWatcher=null,events;function screenLock(lock=!1){lock=!!lock,screenLockedState.value=lock;let body=document.body;body&&body.classList.toggle(`screen-locked`,lock)}async function startLoading$1(func){screenLock(!0),events||=useBridge().events,events.emit(`LoadingScreen`,{active:!0}),await nextTick(),setTimeout(()=>func(),500)}function linkLoadingScreenState(state){loadingScreenStateWatcher?.(),loadingScreenStateWatcher=watch([()=>state.active,()=>state.visible,()=>state.fading,()=>state.shown],([active,visible,fading,shown])=>{loadingScreen.active=active,loadingScreen.visible=visible,loadingScreen.fading=fading,loadingScreen.shown=shown,screenLock(active)})}function waitForLoadingScreenFadeIn$1(timeout=4e3){if(loadingScreen.visible&&!loadingScreen.fading)return;let fadeInPromise=new Promise(resolve$1=>{let unwatch=watch([()=>loadingScreen.visible,()=>loadingScreen.fading],([visible,fading])=>{visible&&!fading&&(unwatch(),resolve$1())},{immediate:!0})});return Promise.race([fadeInPromise,sleep(timeout)])}var bngNavigator=class{opts={root:null,container:null,bootscreen:null,north:null,clock:null,backgroundRgb:[50,50,50],roadColors:[`#FFFFFFFF`,`#A6A678FF`,`#A67854FF`],routeColor:`#3388EEFF`,markerColor:`#2C5CFF`,routes:!1,markers:!1,vehicles:!1,vehicleMarker:null,cameraColor:`#FD6A00`,vehicleColor:`#A3D39C`,rotate:!0,scale:1,pitch:0,offsetX:128,offsetY:64,resolution:4096,speedZoom:!1,speedOffset:0,speedPitch:!0,speedZoomIncrements:1,speedZoomMultiplier:2,speedZoomMax:200,speedZoomEffect:.15,hideBootscreen:!1};elms={root:document};mapScale=1;startup=!0;startupFallback=!0;layers={};layersLoadOrder=[bngNavLayerMap,bngNavLayerRoute,bngNavLayerMarkers,bngNavLayerVehicles,bngNavLayerElements,bngNavLayerBootscreen];setOptions(options){if(!(typeof options!=`object`||Array.isArray(options))){for(let key in this.opts)key in options&&(this.opts[key]=options[key]);for(let name in this.layers){let layer=this.layers[name];typeof layer.setOptions==`function`&&layer.setOptions(this.opts)}}}constructor(options){this.setOptions(options);for(let key of[`root`,`container`,`clock`,`north`,`bootscreen`]){let elm;typeof this.opts[key]==`string`?elm=this.elms.root.querySelector(this.opts[key]):this.opts[key]&&(elm=this.opts[key]),elm&&(elm instanceof HTMLElement||elm instanceof SVGElement)&&(this.elms[key]=elm)}if(!this.elms.root)throw Error(`Cannot find map root element`);if(!this.elms.container)throw Error(`Cannot find map container element`);this.elms.svg=new bngNavSVG(this.elms.container.children[0]);for(let cls of this.layersLoadOrder){let elms$4=cls.name===`map`?this.elms:{...this.elms,cvs:this.layers.map.cvs,routes:[this.layers.map.rwrapper,this.layers.map.rcanvas,this.layers.map.rcanvasCtx]};if(cls.canInit(elms$4,this.opts)){let dim=cls.name===`map`?this.mapScale:this.layers.map.dimensions,layer=new cls(elms$4,this.opts,dim);layer&&layer.name&&(this.layers[layer.name]=layer)}}this.layersLoadOrder=null;let expose=(layer,method,name=null)=>{this[name||method]=layer?layer[method].bind(layer):()=>{}};expose(this.layers.map,`setRotation`),expose(this.layers.map,`setLocation`),expose(this.layers.map,`setZoom`),expose(this.layers.map,`setScale`),expose(this.layers.map,`setSpeed`),expose(this.layers.map,`setOpacity`),expose(this.layers.route,`update`,`setRoute`),expose(this.layers.markers,`update`,`setMarkers`),expose(this.layers.bootscreen,`setImage`,`setBootscreenImage`)}update(data){data&&this.setup(data),this.layers.map.update(),this.layers.elements&&this.layers.elements.update(this.layers.map.state),this.layers.map.render()}setup(data){typeof data.terrainTiles==`object`&&!Array.isArray(data.terrainTiles)&&(data.terrainTiles=[]),this.layers.map.setMapSize(data)&&this.startupFallback?(this.startupFallback=!1,this.startup=!0):this.startup||(this.startupFallback=!0),this.startup&&(this.startup=!1,this.layers.map.applyMapSize(),this.layers.map.renderMap(data))}setData(data){if(!data||Object.keys(data).length===0){console.log(`Received empty map data`);return}this.layers.vehicles&&this.layers.vehicles.update(data),this.update(data),this.opts.hideBootscreen&&this.layers.bootscreen&&this.layers.bootscreen.hide()}updateData(data){typeof data==`object`&&(`x`in data&&`y`in data&&this.layers.map.setLocation(data.x,data.y,!1),`rotation`in data&&this.layers.map.setRotation(data.rotation,!1),`speed`in data&&this.layers.map.setSpeed(data.speed,!1),`ignitionLevel`in data&&this.layers.bootscreen&&this.layers.bootscreen.toggle(data.ignitionLevel<2),this.update())}},bngNavUtils=class{static truncDec(num,dec=2){let d=10**dec;return~~(num*d)/d}static setStyle(node,style){for(let name in style)node.style[name]=style[name]}},bngNavSVG=class{ns={svg:`http://www.w3.org/2000/svg`,xlink:`http://www.w3.org/1999/xlink`};root;constructor(root){if(!root||!root.tagName||root.tagName.toLowerCase()!==`svg`)throw Error(`Cannot access svg in a container`);this.root=root}setViewBox(viewBox){this.root.setAttributeNS(null,`viewBox`,viewBox)}createNode(tag,...args){let[attrs,parent]=args;parent||(attrs&&attrs instanceof SVGElement?(parent=attrs,attrs=null):parent=this.root);let node=document.createElementNS(this.ns.svg,tag);return attrs&&this.setAttrs(node,attrs),parent.appendChild(node),node}removeNode(node){node&&node.parentNode&&node.parentNode.removeChild(node)}setAttrs(node,attrs){for(let name in attrs){let ns=name.startsWith(`xlink:`)?this.ns.xlink:null;node.setAttributeNS(ns,name,attrs[name])}}clearNode(node){let elm;for(;elm=node.children[0];)node.removeChild(elm)}setStyle=bngNavUtils.setStyle;createCanvas(resolution){let fo=this.createNode(`foreignObject`);this.setStyle(fo,{position:`absolute`,x:`0`,y:`0`,width:`100%`,height:`100%`});let cvs=document.createElement(`canvas`);return cvs.width=resolution,cvs.height=resolution,fo.appendChild(cvs),[fo,cvs,cvs.getContext(`2d`)]}},bngNavLayerMap=class{static name=`map`;dimensions={ver:0,offset:512,scale:1,centerX:1024,centerY:1024,width:2048,height:2048,resScale:1};state={x:0,y:0,speed:0,scale:1,zoom:1,speedZoom:0,rotation:0,focusX:0,focusY:0,offsetX:0,offsetY:0};container;svg;wrapper;canvas;canvasCtx;rwrapper;rcanvas;rcanvasCtx;cvs;renders=[];rendered={terrainCvs:null,terrainCtx:null,roadsCvs:null,roadsCtx:null};terrainOpacity=1;gridGap=50;gridColour=`#cccccccc`;roadColors;resolution=2048;offsetX;offsetY;rotate;scale;pitch;speedPitch;speedOffset;speedZoom;speedZoomIncrements;speedZoomMultiplier;speedZoomMax;speedZoomEffect;static canInit(elms$4,opts){return!0}constructor({container,svg},opts,mapScale){this.name=this.constructor.name,this.container=container,this.svg=svg,[this.wrapper,this.canvas,this.canvasCtx]=svg.createCanvas(opts.resolution),[this.rwrapper,this.rcanvas,this.rcanvasCtx]=svg.createCanvas(opts.resolution);let that=this;this.rendered.terrainCvs=window.OffscreenCanvas?new window.OffscreenCanvas(1,1):document.createElement(`canvas`),this.rendered.terrainCtx=this.rendered.terrainCvs.getContext(`2d`),this.addRenderSource({passive:!0,source:this.rendered.terrainCvs,get alpha(){return that.terrainOpacity}}),this.rendered.roadsCvs=window.OffscreenCanvas?new window.OffscreenCanvas(1,1):document.createElement(`canvas`),this.rendered.roadsCtx=this.rendered.roadsCvs.getContext(`2d`),this.addRenderSource({passive:!0,source:this.rendered.roadsCvs}),this.dimensions.scale=mapScale,this.setOptions(opts),this.setOpacity(1)}setOptions(opts){this.bgRgb=opts.backgroundRgb.join(`, `),this.roadColors=opts.roadColors,this.resolution=opts.resolution,this.offsetX=opts.offsetX,this.offsetY=opts.offsetY,this.rotate=opts.rotate,this.scale=opts.scale,this.state.scale=this.scale*this.state.zoom,this.pitch=opts.pitch,this.speedPitch=opts.speedPitch,this.speedOffset=opts.speedOffset,this.speedZoom=opts.speedZoom,this.speedZoomIncrements=opts.speedZoomIncrements,this.speedZoomMultiplier=opts.speedZoomMultiplier,this.speedZoomMax=opts.speedZoomMax,this.speedZoomEffect=opts.speedZoomEffect}setLocation(x,y,doupdate=!0){this.state.x=-x,this.state.y=y,this.state.focusX=~~(this.state.x/this.dimensions.scale*this.dimensions.resScale),this.state.focusY=~~(this.state.y/this.dimensions.scale*this.dimensions.resScale),this.state.offsetX=this.dimensions.centerX-this.state.focusX,this.state.offsetY=this.dimensions.centerY-this.state.focusY,this.container.style.transformOrigin=`${this.state.offsetX}px ${this.state.offsetY}px`}setRotation(rotation,doupdate=!0){this.state.rotation=bngNavUtils.truncDec(rotation,3)%360,doupdate&&this.update()}setZoom(zoom,doupdate=!0){let fixed=(zoom-150)*2;this.setSpeed(fixed)}setScale(zoom,doupdate=!0){this.state.zoom=zoom,this.state.scale=this.scale*zoom}setSpeed(speed){this.state.speed=bngNavUtils.truncDec(speed,3),this.state.speed===0?this.state.speedZoom=0:this.state.speedZoom=bngNavUtils.truncDec(Math.min(1+this.state.speed*3.6*1.5,this.speedZoomMax)/this.speedZoomIncrements*this.speedZoomIncrements/this.speedZoomMax,3)}setOpacity(opacity){this.canvas.style.backgroundColor=`rgba(${this.bgRgb}, ${opacity})`,this.terrainOpacity=opacity}setMapSize(data){let res;return data.terrainTiles&&data.terrainTiles[0]&&data.terrainTiles[0].size?(this.setMapDimensions(data),res=!0):this.dimensions.ver===0&&(this.setMapDimensions(data),res=!1),res}setMapDimensions(data){let poss=[],tiles=data.terrainTiles||[];for(let tile of tiles)poss.push([tile.offset[0],-tile.offset[1]],[tile.offset[0]+tile.size[0],-tile.offset[1]+tile.size[1]]);for(let key in data.nodes)poss.push([data.nodes[key].pos[0],-data.nodes[key].pos[1]]);let minX=1/0,maxX=-1/0,minY=1/0,maxY=-1/0;for(let pos of poss)pos[0]/=this.dimensions.scale,pos[1]/=this.dimensions.scale,pos[0]maxX&&(maxX=pos[0]),pos[1]maxY&&(maxY=pos[1]);let dim={centerX:-minX,centerY:-minY,width:-minX+maxX,height:-minY+maxY};if((dim.centerX<0||dim.centerY<0)&&((isFinite(dim.centerX)||isFinite(dim.centerY))&&console.error(`Navigator: Invalid center point detected.`),dim.centerX=this.resolution/2,dim.centerY=this.resolution/2,dim.width=this.resolution,dim.height=this.resolution),this.dimensions.offset>0){let off=this.dimensions.offset;dim.centerX+=off,dim.width+=off*2,dim.centerY+=off,dim.height+=off*2}for(let key in dim.width>this.resolution||dim.height>this.resolution?(dim.resScale=this.resolution/(dim.width>dim.height?dim.width:dim.height),dim.width*=dim.resScale,dim.height*=dim.resScale,dim.centerX*=dim.resScale,dim.centerY*=dim.resScale,dim.offset=dim.offset>0?dim.offset/dim.resScale:0):dim.resScale=1,dim)key!==`resScale`&&(dim[key]=Math.round(dim[key]));let changed=!1;for(let key in dim)this.dimensions[key]!==dim[key]&&(this.dimensions[key]=dim[key],changed=!0);changed&&this.dimensions.ver++}applyMapSize(){this.container.style.width=this.dimensions.width+`px`,this.container.style.height=this.dimensions.height+`px`,this.svg.setViewBox(`0 0 ${this.dimensions.width} ${this.dimensions.height}`);let width$1=this.dimensions.width,height$1=this.dimensions.height;this.canvas.style.width=this.wrapper.style.width=width$1+`px`,this.canvas.style.height=this.wrapper.style.height=height$1+`px`,this.canvas.width=width$1,this.canvas.height=height$1,this.rendered.terrainCtx.clearRect(0,0,this.rendered.terrainCvs.width,this.rendered.terrainCvs.height),this.rendered.terrainCvs.width=width$1,this.rendered.terrainCvs.height=height$1,this.rendered.roadsCtx.clearRect(0,0,this.rendered.roadsCvs.width,this.rendered.roadsCvs.height),this.rendered.roadsCvs.width=width$1,this.rendered.roadsCvs.height=height$1}addRenderSource(source){if(typeof source!=`object`&&!(`source`in source))return console.error(`Navigator: Render source is invalid`);this.renders.push(source)}render(passive=!1){if(!passive)return;let ctx=this.canvasCtx,full=[0,0,this.dimensions.width,this.dimensions.height];ctx.clearRect(...full);for(let src of this.renders){if(!!src.passive!==passive||src.source.width===0||src.source.height===0)continue;let region=src.region;if(src.render){let res=src.render();typeof res==`object`&&`empty`in res&&(region={full:res,fullArray:[res.x1,res.y1,res.x2-res.x1,res.y2-res.y1]})}let pos=src.pos;pos||=(pos=region&&!region.full.empty?region.fullArray:full,[...pos,...pos]),src.alpha&&(ctx.globalAlpha=src.alpha),ctx.drawImage(src.source,...pos),ctx.globalAlpha=1}}renderMap(data){for(let key in this.drawTerrain(data,this.rendered.terrainCtx),data.nodes){let el=data.nodes[key];if(el.links)for(let key2 in el.links)el.links[key2].drivability=Math.round(el.links[key2].drivability*10)/10}this.drawRoads(data.nodes,0,.1,this.roadColors[2],this.rendered.roadsCtx),this.drawRoads(data.nodes,.1,.9,this.roadColors[1],this.rendered.roadsCtx),this.drawRoads(data.nodes,.9,1,this.roadColors[0],this.rendered.roadsCtx),this.render(!0)}drawTerrain(data,ctx){for(let x=this.gridGap;x{ctx.clearRect(...dest),ctx.drawImage(img,0,0,img.width,img.height,...dest),loading--,loading===0&&this.render(!0)}),img.addEventListener(`error`,()=>{console.error(`Navigator: Unable to load tile "${tile.file}"`),loading--,loading===0&&this.render(!0)}),img.src=tile.file}}createLine(ctx,p1,p2,color){Math.abs(p1.radius-p2.radius)>.2?this.varLine(ctx,p1.x,p1.y,p2.x,p2.y,p1.radius,p2.radius,color):(ctx.beginPath(),ctx.lineWidth=Math.max(p1.radius,p2.radius),ctx.lineCap=`round`,ctx.strokeStyle=color,ctx.moveTo(p1.x,p1.y),ctx.lineTo(p2.x,p2.y),ctx.stroke())}varLine(ctx,x1,y1,x2,y2,w1,w2,color){let dx=x2-x1,dy=y2-y1,length=dx*dx+dy*dy;if(length==0)return;length=Math.sqrt(length),w1*=.5,w2*=.5,dx/=length,dy/=length;let shiftx=-dy*w1,shifty=dx*w1;ctx.beginPath(),ctx.fillStyle=color,ctx.moveTo(x1+shiftx,y1+shifty),ctx.lineTo(x1-shiftx,y1-shifty),shiftx=-dy*w2,shifty=dx*w2,ctx.lineTo(x2-shiftx,y2-shifty),ctx.lineTo(x2+shiftx,y2+shifty),ctx.closePath(),ctx.arc(x1,y1,w1,0,2*Math.PI),ctx.arc(x2,y2,w2,0,2*Math.PI),ctx.fill()}drawRoads(nodes,drivabilityMin,drivabilityMax,colour,ctx){for(let key in nodes){let el=nodes[key];if(el.links)for(let key2 in el.links){let drivability=el.links[key2].drivability;if(drivabilitydrivabilityMax)continue;let el2=nodes[key2];this.createLine(ctx,{x:el.pos[0]/this.dimensions.scale*this.dimensions.resScale+this.dimensions.centerX,y:-el.pos[1]/this.dimensions.scale*this.dimensions.resScale+this.dimensions.centerY,radius:Math.min(Math.max(el.radius,0),5)*3*this.dimensions.resScale},{x:el2.pos[0]/this.dimensions.scale*this.dimensions.resScale+this.dimensions.centerX,y:-el2.pos[1]/this.dimensions.scale*this.dimensions.resScale+this.dimensions.centerY,radius:Math.min(Math.max(el2.radius,0),5)*3*this.dimensions.resScale},colour)}}}update(){let pos={x:-this.state.offsetX+this.offsetX,y:-this.state.offsetY+this.offsetY},rot={x:0,z:0};this.speedOffset>0&&(pos.y+=this.state.speedZoom*this.speedOffset),this.rotate&&(rot.x=this.pitch,this.speedPitch>0&&(rot.x+=this.speedPitch*this.state.speedZoom),rot.z=this.state.rotation);let scale=this.state.scale/this.dimensions.resScale;this.speedZoom&&(scale-=this.state.speedZoom*.1/this.dimensions.resScale),this.container.style.transform=`translate3d(${pos.x}px, ${pos.y}px, 0px) rotateX(${rot.x}deg) rotateZ(${rot.z}deg) scale(${scale})`}},bngNavLayerRoute=class{static name=`route`;dimensions;scale=1/3;lineWidth=10;color;wrapper;canvas;canvasCtx;current=null;static canInit(elms$4,opts){return!!opts.routes}constructor({routes,svg},opts,dimensions){this.name=this.constructor.name,[this.wrapper,this.canvas,this.canvasCtx]=routes||svg.createCanvas(opts.resolution),this.dimensions=dimensions,this.setOptions(opts)}setOptions(opts){this.color=opts.routeColor}update(data){if(this.dimver!==this.dimensions.ver){this.dimver=this.dimensions.ver;let width$1=this.dimensions.width,height$1=this.dimensions.height;this.canvas.style.width=this.wrapper.style.width=width$1+`px`,this.canvas.style.height=this.wrapper.style.height=height$1+`px`,this.canvas.width=this.canvasCtx.width=width$1*this.scale,this.canvas.height=this.canvasCtx.height=height$1*this.scale}if(!data||!data.markers){this.clear();return}this.current?this.optimiseAndDrawRoute(data,this.current):(this.clear(),data&&this.drawFreshRoute(data)),this.current=data.markers}clear(){this.current=null,this.canvasCtx.clearRect(0,0,this.canvas.width,this.canvas.height),this.canvasCtx.stroke()}drawFreshRoute(data){this.drawRoute({color:data.color,lineWidth:this.lineWidth,lineCap:`butt`,markers:data.markers,startIndex:0,drawFromIndex:2,drawToIndex:data.markers.length})}optimiseAndDrawRoute(data,prevMarkers){let markers$1=data.markers,ci=markers$1.length-2,pi=prevMarkers.length-2;for(;pi>=0&&ci>=0&&!(markers$1[ci]!==prevMarkers[pi]||markers$1[ci+1]!==prevMarkers[pi+1]);)ci-=2,pi-=2;(ci>=0||pi>=0)&&(this.canvasCtx.globalCompositeOperation=`destination-out`,this.drawRoute({color:data.color,lineWidth:this.lineWidth+2,markers:prevMarkers,drawToIndex:Math.min(pi+4,prevMarkers.length)}),this.canvasCtx.globalCompositeOperation=`source-over`,this.drawRoute({color:data.color,lineWidth:this.lineWidth,markers:data.markers,drawToIndex:Math.min(ci+6,data.markers.length)}))}drawRoute({color,lineWidth,lineCap=`round`,markers:markers$1,startIndex=0,drawFromIndex=0,drawToIndex}){let mapFac=this.scale/this.dimensions.scale,cx=this.dimensions.centerX*mapFac,cy=this.dimensions.centerY*mapFac;this.canvasCtx.beginPath(),this.canvasCtx.strokeStyle=color||this.color,this.canvasCtx.lineWidth=lineWidth*this.scale*this.dimensions.resScale,this.canvasCtx.lineCap=lineCap,this.canvasCtx.moveTo(markers$1[startIndex]*this.dimensions.resScale*mapFac+cx,-markers$1[startIndex+1]*this.dimensions.resScale*mapFac+cy);for(let i=drawFromIndex;iargs.map(arg=>typeof arg==`string`?arg:`[object]`)},createElementNS:{base:Document,getArgs:(...args)=>args.map(arg=>typeof arg==`string`?arg:`[object]`)},cloneNode:{base:Node,getArgs:deep=>[deep]},importNode:{base:Document,getArgs:(node,deep)=>[`[node]`,deep]},insertAdjacentHTML:{base:Element,getArgs:(position,text)=>[position,`[HTML:${text.length}chars]`]},innerHTML:{isSetter:!0,bases:[Element,HTMLElement],getArgs:value=>[`[HTML:${typeof value==`string`?value.length:0}chars]`]},outerHTML:{isSetter:!0,bases:[Element,HTMLElement],getArgs:value=>[`[HTML:${typeof value==`string`?value.length:0}chars]`]},appendChild:{base:Node,stats:`append`,getArgs:child=>[`[${child?.tagName||child?.nodeName||`node`}]`]},insertBefore:{base:Node,stats:`append`,getArgs:(newNode,referenceNode)=>[`[${newNode?.tagName||newNode?.nodeName||`node`}]`,`[${referenceNode?.tagName||referenceNode?.nodeName||`ref`}]`]},replaceChild:{base:Node,stats:`append`,getArgs:(newChild,oldChild)=>[`[${newChild?.tagName||newChild?.nodeName||`new`}]`,`[${oldChild?.tagName||oldChild?.nodeName||`old`}]`]},append:{base:Element,stats:`append`,getArgs:(...nodes)=>nodes.map(node=>`[${node?.tagName||node?.nodeName||typeof node==`string`?`text`:`node`}]`)},prepend:{base:Element,stats:`append`,getArgs:(...nodes)=>nodes.map(node=>`[${node?.tagName||node?.nodeName||typeof node==`string`?`text`:`node`}]`)},before:{base:Element,stats:`append`,getArgs:(...nodes)=>nodes.map(node=>`[${node?.tagName||node?.nodeName||typeof node==`string`?`text`:`node`}]`)},after:{base:Element,stats:`append`,getArgs:(...nodes)=>nodes.map(node=>`[${node?.tagName||node?.nodeName||typeof node==`string`?`text`:`node`}]`)}};function setupInterceptor(type){let interceptor=interceptors[type];if(interceptor.isSetter){let descriptor;if(interceptor.bases){for(let base of interceptor.bases)if(descriptor=Object.getOwnPropertyDescriptor(base.prototype,type),descriptor){interceptor.base=base;break}}descriptor&&(interceptor.original=descriptor)}else interceptor.original=interceptor.base.prototype[type];if(!interceptor.original){logger_default.warn(`No original for ${type}`);return}interceptor.call=(self$1,...args)=>{let stackTrace=captureStackTrace();if(stackTrace&&(includeAnonymousCalls||!stackTrace.hasAnonymous||stackTrace.filePaths.length>0)){let callData={type,timestamp:Date.now(),args:interceptor.getArgs(...args),stackTrace};if(interceptor.stats===`append`&&self$1)try{let mainContainer=self$1.closest?self$1.closest(`#mainContainer_apps`):null;if(mainContainer){let directChildDiv=self$1;for(;directChildDiv&&directChildDiv.parentNode&&directChildDiv.parentNode!==mainContainer;)directChildDiv=directChildDiv.parentNode;directChildDiv&&directChildDiv.parentNode===mainContainer&&directChildDiv.tagName===`DIV`&&(callData.uiAppInsertion={targetElement:directChildDiv})}}catch{}callQueue.push(callData)}if(interceptor.isSetter)interceptor.original.set.call(self$1,args[0]);else return interceptor.original.apply(self$1,args)},interceptor.isSetter?Object.defineProperty(interceptor.base.prototype,type,{get:interceptor.original.get,set:function(value){interceptor.call(this,value)},configurable:!0,enumerable:!0}):interceptor.base.prototype[type]=function(...args){return interceptor.call(this,...args)},interceptor.restore=()=>{interceptor.isSetter?Object.defineProperty(interceptor.base.prototype,type,{get:interceptor.original.get,set:interceptor.original.set,configurable:!0,enumerable:!0}):interceptor.base.prototype[type]=interceptor.original}}function captureStackTrace(){let stack$2=Error().stack;if(!stack$2)return null;let relevantLines=stack$2.split(` `).slice(STACK_TRACE_SKIP_LINES),filePaths=[],hasAnonymous=!1;for(let line of relevantLines){let match=line.match(STACK_TRACE_REGEX_FULL),functionName,filePath,lineNum,column;if(match)functionName=match[1],filePath=match[2],lineNum=match[3],column=match[4];else if(match=line.match(STACK_TRACE_REGEX),match)functionName=`anonymous`,filePath=match[1],lineNum=match[2],column=match[3];else continue;let isAnonymous=functionName?.includes(`anonymous`)||functionName?.includes(``)||!functionName||functionName.trim()===``;isAnonymous&&(hasAnonymous=!0,!includeAnonymousCalls)||filePaths.push({functionName,filePath,line:lineNum,column,isAnonymous})}return{filePaths,fullStack:stack$2,hasAnonymous}}async function processCallQueue(){if(statsProcessor.lastProcessTime=Date.now(),!(statsProcessor.isProcessing||callQueue.length===0)){statsProcessor.isProcessing=!0;try{let batch$1=callQueue.splice(0,Math.max(statsProcessor.batchSize,callQueue.length/5));statsProcessor.totalProcessed+=batch$1.length;for(let i=0;i{try{processCallQueue()}catch(error){logger_default.error(`Fatal error in DOM watchdog processing:`,error),destroy()}},statsProcessor.processInterval)}function getStats(){return{files:Object.fromEntries(statsProcessor.files),types:Object.fromEntries(statsProcessor.types),append:Object.fromEntries(statsProcessor.append)}}function clearStats(){statsProcessor.files.clear(),statsProcessor.types.clear(),statsProcessor.append.clear(),statsProcessor.uiApps.clear(),callQueue.length=0,statsProcessor.totalProcessed=0,statsProcessor.lastProcessTime=0,overlayActive&&updateOverlayDivs()}function restartTimer(){isInitialized&&startStatsProcessor()}function setIncludeAnonymousCalls(include){includeAnonymousCalls=include}var exposedFunctions=()=>({watchdogRecentCalls:getRecentCalls,watchdogCallChainStats:getCallChainStats,watchdogClearStats:clearStats,watchdogSetIncludeAnonymousCalls:setIncludeAnonymousCalls,watchdogDestroy:destroy,watchdogRestartTimer:restartTimer,watchdogUIAppsStats:getUIAppsStats,watchdogRefreshOverlay:refreshOverlay,watchdogStats:()=>{let stats=getStats(),format$2=obj=>Object.entries(obj).sort((a$1,b)=>b[1]-a$1[1]).map(([key,value])=>`${key}: ${value}`.replace(`\\`,`\\\\`)).join(`
  • `+b).split(R[0]).slice(1).map(R[3]?escape:inlineEscape).join(R[3]||`
    
  • `)+R[2]:f===`#`?``+inlineEscape(b.slice(f+1))+``:f===`<`?b:`

    `+inlineEscape(b)+`

    `}),h$1}function escape(t){return new Option(t).innerHTML}function inlineEscape(s){return escape(s).replace(/\\_/g,`⋿`).replace(/!\[([^\]]*)]\(([^(]+)\)/g,`$1`).replace(/\[([^\]]+)]\(([^(]+?)\)/g,`$1`.link(`$2`)).replace(/`([^`]+)`/g,`$1`).replace(/(\*\*|__)(?=\S)([^\r]*?\S[*_]*)\1/g,`$2`).replace(/(\*| _)(?=\S)([^\r]*?\S)\1/g,`$2`).replace(/⋿/g,`_`)}var content_exports=__export({bbcode:()=>bbcode_exports,markdown:()=>markdown_exports});const screenLocked=computed(()=>screenLockedState.value),loadingScreen=reactive({active:!1,visible:!1,fading:!1,shown:!1});var screenLockedState=ref(!1),loadingScreenStateWatcher=null,events;function screenLock(lock=!1){lock=!!lock,screenLockedState.value=lock;let body=document.body;body&&body.classList.toggle(`screen-locked`,lock)}async function startLoading$1(func){screenLock(!0),events||=useBridge().events,events.emit(`LoadingScreen`,{active:!0}),await nextTick(),setTimeout(()=>func(),500)}function linkLoadingScreenState(state){loadingScreenStateWatcher?.(),loadingScreenStateWatcher=watch([()=>state.active,()=>state.visible,()=>state.fading,()=>state.shown],([active,visible,fading,shown])=>{loadingScreen.active=active,loadingScreen.visible=visible,loadingScreen.fading=fading,loadingScreen.shown=shown,screenLock(active)})}function waitForLoadingScreenFadeIn$1(timeout=4e3){if(loadingScreen.visible&&!loadingScreen.fading)return;let fadeInPromise=new Promise(resolve$1=>{let unwatch=watch([()=>loadingScreen.visible,()=>loadingScreen.fading],([visible,fading])=>{visible&&!fading&&(unwatch(),resolve$1())},{immediate:!0})});return Promise.race([fadeInPromise,sleep(timeout)])}var bngNavigator=class{opts={root:null,container:null,bootscreen:null,north:null,clock:null,backgroundRgb:[50,50,50],roadColors:[`#FFFFFFFF`,`#A6A678FF`,`#A67854FF`],routeColor:`#3388EEFF`,markerColor:`#2C5CFF`,routes:!1,markers:!1,vehicles:!1,vehicleMarker:null,cameraColor:`#FD6A00`,vehicleColor:`#A3D39C`,rotate:!0,scale:1,pitch:0,offsetX:128,offsetY:64,resolution:4096,speedZoom:!1,speedOffset:0,speedPitch:!0,speedZoomIncrements:1,speedZoomMultiplier:2,speedZoomMax:200,speedZoomEffect:.15,hideBootscreen:!1};elms={root:document};mapScale=1;startup=!0;startupFallback=!0;layers={};layersLoadOrder=[bngNavLayerMap,bngNavLayerRoute,bngNavLayerMarkers,bngNavLayerVehicles,bngNavLayerElements,bngNavLayerBootscreen];setOptions(options){if(!(typeof options!=`object`||Array.isArray(options))){for(let key in this.opts)key in options&&(this.opts[key]=options[key]);for(let name in this.layers){let layer=this.layers[name];typeof layer.setOptions==`function`&&layer.setOptions(this.opts)}}}constructor(options){this.setOptions(options);for(let key of[`root`,`container`,`clock`,`north`,`bootscreen`]){let elm;typeof this.opts[key]==`string`?elm=this.elms.root.querySelector(this.opts[key]):this.opts[key]&&(elm=this.opts[key]),elm&&(elm instanceof HTMLElement||elm instanceof SVGElement)&&(this.elms[key]=elm)}if(!this.elms.root)throw Error(`Cannot find map root element`);if(!this.elms.container)throw Error(`Cannot find map container element`);this.elms.svg=new bngNavSVG(this.elms.container.children[0]);for(let cls of this.layersLoadOrder){let elms$4=cls.name===`map`?this.elms:{...this.elms,cvs:this.layers.map.cvs,routes:[this.layers.map.rwrapper,this.layers.map.rcanvas,this.layers.map.rcanvasCtx]};if(cls.canInit(elms$4,this.opts)){let dim=cls.name===`map`?this.mapScale:this.layers.map.dimensions,layer=new cls(elms$4,this.opts,dim);layer&&layer.name&&(this.layers[layer.name]=layer)}}this.layersLoadOrder=null;let expose=(layer,method,name=null)=>{this[name||method]=layer?layer[method].bind(layer):()=>{}};expose(this.layers.map,`setRotation`),expose(this.layers.map,`setLocation`),expose(this.layers.map,`setZoom`),expose(this.layers.map,`setScale`),expose(this.layers.map,`setSpeed`),expose(this.layers.map,`setOpacity`),expose(this.layers.route,`update`,`setRoute`),expose(this.layers.markers,`update`,`setMarkers`),expose(this.layers.bootscreen,`setImage`,`setBootscreenImage`)}update(data){data&&this.setup(data),this.layers.map.update(),this.layers.elements&&this.layers.elements.update(this.layers.map.state),this.layers.map.render()}setup(data){typeof data.terrainTiles==`object`&&!Array.isArray(data.terrainTiles)&&(data.terrainTiles=[]),this.layers.map.setMapSize(data)&&this.startupFallback?(this.startupFallback=!1,this.startup=!0):this.startup||(this.startupFallback=!0),this.startup&&(this.startup=!1,this.layers.map.applyMapSize(),this.layers.map.renderMap(data))}setData(data){if(!data||Object.keys(data).length===0){console.log(`Received empty map data`);return}this.layers.vehicles&&this.layers.vehicles.update(data),this.update(data),this.opts.hideBootscreen&&this.layers.bootscreen&&this.layers.bootscreen.hide()}updateData(data){typeof data==`object`&&(`x`in data&&`y`in data&&this.layers.map.setLocation(data.x,data.y,!1),`rotation`in data&&this.layers.map.setRotation(data.rotation,!1),`speed`in data&&this.layers.map.setSpeed(data.speed,!1),`ignitionLevel`in data&&this.layers.bootscreen&&this.layers.bootscreen.toggle(data.ignitionLevel<2),this.update())}},bngNavUtils=class{static truncDec(num,dec=2){let d=10**dec;return~~(num*d)/d}static setStyle(node,style){for(let name in style)node.style[name]=style[name]}},bngNavSVG=class{ns={svg:`http://www.w3.org/2000/svg`,xlink:`http://www.w3.org/1999/xlink`};root;constructor(root){if(!root||!root.tagName||root.tagName.toLowerCase()!==`svg`)throw Error(`Cannot access svg in a container`);this.root=root}setViewBox(viewBox){this.root.setAttributeNS(null,`viewBox`,viewBox)}createNode(tag,...args){let[attrs,parent]=args;parent||(attrs&&attrs instanceof SVGElement?(parent=attrs,attrs=null):parent=this.root);let node=document.createElementNS(this.ns.svg,tag);return attrs&&this.setAttrs(node,attrs),parent.appendChild(node),node}removeNode(node){node&&node.parentNode&&node.parentNode.removeChild(node)}setAttrs(node,attrs){for(let name in attrs){let ns=name.startsWith(`xlink:`)?this.ns.xlink:null;node.setAttributeNS(ns,name,attrs[name])}}clearNode(node){let elm;for(;elm=node.children[0];)node.removeChild(elm)}setStyle=bngNavUtils.setStyle;createCanvas(resolution){let fo=this.createNode(`foreignObject`);this.setStyle(fo,{position:`absolute`,x:`0`,y:`0`,width:`100%`,height:`100%`});let cvs=document.createElement(`canvas`);return cvs.width=resolution,cvs.height=resolution,fo.appendChild(cvs),[fo,cvs,cvs.getContext(`2d`)]}},bngNavLayerMap=class{static name=`map`;dimensions={ver:0,offset:512,scale:1,centerX:1024,centerY:1024,width:2048,height:2048,resScale:1};state={x:0,y:0,speed:0,scale:1,zoom:1,speedZoom:0,rotation:0,focusX:0,focusY:0,offsetX:0,offsetY:0};container;svg;wrapper;canvas;canvasCtx;rwrapper;rcanvas;rcanvasCtx;cvs;renders=[];rendered={terrainCvs:null,terrainCtx:null,roadsCvs:null,roadsCtx:null};terrainOpacity=1;gridGap=50;gridColour=`#cccccccc`;roadColors;resolution=2048;offsetX;offsetY;rotate;scale;pitch;speedPitch;speedOffset;speedZoom;speedZoomIncrements;speedZoomMultiplier;speedZoomMax;speedZoomEffect;static canInit(elms$4,opts){return!0}constructor({container,svg},opts,mapScale){this.name=this.constructor.name,this.container=container,this.svg=svg,[this.wrapper,this.canvas,this.canvasCtx]=svg.createCanvas(opts.resolution),[this.rwrapper,this.rcanvas,this.rcanvasCtx]=svg.createCanvas(opts.resolution);let that=this;this.rendered.terrainCvs=window.OffscreenCanvas?new window.OffscreenCanvas(1,1):document.createElement(`canvas`),this.rendered.terrainCtx=this.rendered.terrainCvs.getContext(`2d`),this.addRenderSource({passive:!0,source:this.rendered.terrainCvs,get alpha(){return that.terrainOpacity}}),this.rendered.roadsCvs=window.OffscreenCanvas?new window.OffscreenCanvas(1,1):document.createElement(`canvas`),this.rendered.roadsCtx=this.rendered.roadsCvs.getContext(`2d`),this.addRenderSource({passive:!0,source:this.rendered.roadsCvs}),this.dimensions.scale=mapScale,this.setOptions(opts),this.setOpacity(1)}setOptions(opts){this.bgRgb=opts.backgroundRgb.join(`, `),this.roadColors=opts.roadColors,this.resolution=opts.resolution,this.offsetX=opts.offsetX,this.offsetY=opts.offsetY,this.rotate=opts.rotate,this.scale=opts.scale,this.state.scale=this.scale*this.state.zoom,this.pitch=opts.pitch,this.speedPitch=opts.speedPitch,this.speedOffset=opts.speedOffset,this.speedZoom=opts.speedZoom,this.speedZoomIncrements=opts.speedZoomIncrements,this.speedZoomMultiplier=opts.speedZoomMultiplier,this.speedZoomMax=opts.speedZoomMax,this.speedZoomEffect=opts.speedZoomEffect}setLocation(x,y,doupdate=!0){this.state.x=-x,this.state.y=y,this.state.focusX=~~(this.state.x/this.dimensions.scale*this.dimensions.resScale),this.state.focusY=~~(this.state.y/this.dimensions.scale*this.dimensions.resScale),this.state.offsetX=this.dimensions.centerX-this.state.focusX,this.state.offsetY=this.dimensions.centerY-this.state.focusY,this.container.style.transformOrigin=`${this.state.offsetX}px ${this.state.offsetY}px`}setRotation(rotation,doupdate=!0){this.state.rotation=bngNavUtils.truncDec(rotation,3)%360,doupdate&&this.update()}setZoom(zoom,doupdate=!0){let fixed=(zoom-150)*2;this.setSpeed(fixed)}setScale(zoom,doupdate=!0){this.state.zoom=zoom,this.state.scale=this.scale*zoom}setSpeed(speed){this.state.speed=bngNavUtils.truncDec(speed,3),this.state.speed===0?this.state.speedZoom=0:this.state.speedZoom=bngNavUtils.truncDec(Math.min(1+this.state.speed*3.6*1.5,this.speedZoomMax)/this.speedZoomIncrements*this.speedZoomIncrements/this.speedZoomMax,3)}setOpacity(opacity){this.canvas.style.backgroundColor=`rgba(${this.bgRgb}, ${opacity})`,this.terrainOpacity=opacity}setMapSize(data){let res;return data.terrainTiles&&data.terrainTiles[0]&&data.terrainTiles[0].size?(this.setMapDimensions(data),res=!0):this.dimensions.ver===0&&(this.setMapDimensions(data),res=!1),res}setMapDimensions(data){let poss=[],tiles=data.terrainTiles||[];for(let tile of tiles)poss.push([tile.offset[0],-tile.offset[1]],[tile.offset[0]+tile.size[0],-tile.offset[1]+tile.size[1]]);for(let key in data.nodes)poss.push([data.nodes[key].pos[0],-data.nodes[key].pos[1]]);let minX=1/0,maxX=-1/0,minY=1/0,maxY=-1/0;for(let pos of poss)pos[0]/=this.dimensions.scale,pos[1]/=this.dimensions.scale,pos[0]maxX&&(maxX=pos[0]),pos[1]maxY&&(maxY=pos[1]);let dim={centerX:-minX,centerY:-minY,width:-minX+maxX,height:-minY+maxY};if((dim.centerX<0||dim.centerY<0)&&((isFinite(dim.centerX)||isFinite(dim.centerY))&&console.error(`Navigator: Invalid center point detected.`),dim.centerX=this.resolution/2,dim.centerY=this.resolution/2,dim.width=this.resolution,dim.height=this.resolution),this.dimensions.offset>0){let off=this.dimensions.offset;dim.centerX+=off,dim.width+=off*2,dim.centerY+=off,dim.height+=off*2}for(let key in dim.width>this.resolution||dim.height>this.resolution?(dim.resScale=this.resolution/(dim.width>dim.height?dim.width:dim.height),dim.width*=dim.resScale,dim.height*=dim.resScale,dim.centerX*=dim.resScale,dim.centerY*=dim.resScale,dim.offset=dim.offset>0?dim.offset/dim.resScale:0):dim.resScale=1,dim)key!==`resScale`&&(dim[key]=Math.round(dim[key]));let changed=!1;for(let key in dim)this.dimensions[key]!==dim[key]&&(this.dimensions[key]=dim[key],changed=!0);changed&&this.dimensions.ver++}applyMapSize(){this.container.style.width=this.dimensions.width+`px`,this.container.style.height=this.dimensions.height+`px`,this.svg.setViewBox(`0 0 ${this.dimensions.width} ${this.dimensions.height}`);let width$1=this.dimensions.width,height$1=this.dimensions.height;this.canvas.style.width=this.wrapper.style.width=width$1+`px`,this.canvas.style.height=this.wrapper.style.height=height$1+`px`,this.canvas.width=width$1,this.canvas.height=height$1,this.rendered.terrainCtx.clearRect(0,0,this.rendered.terrainCvs.width,this.rendered.terrainCvs.height),this.rendered.terrainCvs.width=width$1,this.rendered.terrainCvs.height=height$1,this.rendered.roadsCtx.clearRect(0,0,this.rendered.roadsCvs.width,this.rendered.roadsCvs.height),this.rendered.roadsCvs.width=width$1,this.rendered.roadsCvs.height=height$1}addRenderSource(source){if(typeof source!=`object`&&!(`source`in source))return console.error(`Navigator: Render source is invalid`);this.renders.push(source)}render(passive=!1){if(!passive)return;let ctx=this.canvasCtx,full=[0,0,this.dimensions.width,this.dimensions.height];ctx.clearRect(...full);for(let src of this.renders){if(!!src.passive!==passive||src.source.width===0||src.source.height===0)continue;let region=src.region;if(src.render){let res=src.render();typeof res==`object`&&`empty`in res&&(region={full:res,fullArray:[res.x1,res.y1,res.x2-res.x1,res.y2-res.y1]})}let pos=src.pos;pos||=(pos=region&&!region.full.empty?region.fullArray:full,[...pos,...pos]),src.alpha&&(ctx.globalAlpha=src.alpha),ctx.drawImage(src.source,...pos),ctx.globalAlpha=1}}renderMap(data){for(let key in this.drawTerrain(data,this.rendered.terrainCtx),data.nodes){let el=data.nodes[key];if(el.links)for(let key2 in el.links)el.links[key2].drivability=Math.round(el.links[key2].drivability*10)/10}this.drawRoads(data.nodes,0,.1,this.roadColors[2],this.rendered.roadsCtx),this.drawRoads(data.nodes,.1,.9,this.roadColors[1],this.rendered.roadsCtx),this.drawRoads(data.nodes,.9,1,this.roadColors[0],this.rendered.roadsCtx),this.render(!0)}drawTerrain(data,ctx){for(let x=this.gridGap;x{ctx.clearRect(...dest),ctx.drawImage(img,0,0,img.width,img.height,...dest),loading--,loading===0&&this.render(!0)}),img.addEventListener(`error`,()=>{console.error(`Navigator: Unable to load tile "${tile.file}"`),loading--,loading===0&&this.render(!0)}),img.src=tile.file}}createLine(ctx,p1,p2,color){Math.abs(p1.radius-p2.radius)>.2?this.varLine(ctx,p1.x,p1.y,p2.x,p2.y,p1.radius,p2.radius,color):(ctx.beginPath(),ctx.lineWidth=Math.max(p1.radius,p2.radius),ctx.lineCap=`round`,ctx.strokeStyle=color,ctx.moveTo(p1.x,p1.y),ctx.lineTo(p2.x,p2.y),ctx.stroke())}varLine(ctx,x1,y1,x2,y2,w1,w2,color){let dx=x2-x1,dy=y2-y1,length=dx*dx+dy*dy;if(length==0)return;length=Math.sqrt(length),w1*=.5,w2*=.5,dx/=length,dy/=length;let shiftx=-dy*w1,shifty=dx*w1;ctx.beginPath(),ctx.fillStyle=color,ctx.moveTo(x1+shiftx,y1+shifty),ctx.lineTo(x1-shiftx,y1-shifty),shiftx=-dy*w2,shifty=dx*w2,ctx.lineTo(x2-shiftx,y2-shifty),ctx.lineTo(x2+shiftx,y2+shifty),ctx.closePath(),ctx.arc(x1,y1,w1,0,2*Math.PI),ctx.arc(x2,y2,w2,0,2*Math.PI),ctx.fill()}drawRoads(nodes,drivabilityMin,drivabilityMax,colour,ctx){for(let key in nodes){let el=nodes[key];if(el.links)for(let key2 in el.links){let drivability=el.links[key2].drivability;if(drivabilitydrivabilityMax)continue;let el2=nodes[key2];this.createLine(ctx,{x:el.pos[0]/this.dimensions.scale*this.dimensions.resScale+this.dimensions.centerX,y:-el.pos[1]/this.dimensions.scale*this.dimensions.resScale+this.dimensions.centerY,radius:Math.min(Math.max(el.radius,0),5)*3*this.dimensions.resScale},{x:el2.pos[0]/this.dimensions.scale*this.dimensions.resScale+this.dimensions.centerX,y:-el2.pos[1]/this.dimensions.scale*this.dimensions.resScale+this.dimensions.centerY,radius:Math.min(Math.max(el2.radius,0),5)*3*this.dimensions.resScale},colour)}}}update(){let pos={x:-this.state.offsetX+this.offsetX,y:-this.state.offsetY+this.offsetY},rot={x:0,z:0};this.speedOffset>0&&(pos.y+=this.state.speedZoom*this.speedOffset),this.rotate&&(rot.x=this.pitch,this.speedPitch>0&&(rot.x+=this.speedPitch*this.state.speedZoom),rot.z=this.state.rotation);let scale=this.state.scale/this.dimensions.resScale;this.speedZoom&&(scale-=this.state.speedZoom*.1/this.dimensions.resScale),this.container.style.transform=`translate3d(${pos.x}px, ${pos.y}px, 0px) rotateX(${rot.x}deg) rotateZ(${rot.z}deg) scale(${scale})`}},bngNavLayerRoute=class{static name=`route`;dimensions;scale=1/3;lineWidth=10;color;wrapper;canvas;canvasCtx;current=null;static canInit(elms$4,opts){return!!opts.routes}constructor({routes,svg},opts,dimensions){this.name=this.constructor.name,[this.wrapper,this.canvas,this.canvasCtx]=routes||svg.createCanvas(opts.resolution),this.dimensions=dimensions,this.setOptions(opts)}setOptions(opts){this.color=opts.routeColor}update(data){if(this.dimver!==this.dimensions.ver){this.dimver=this.dimensions.ver;let width$1=this.dimensions.width,height$1=this.dimensions.height;this.canvas.style.width=this.wrapper.style.width=width$1+`px`,this.canvas.style.height=this.wrapper.style.height=height$1+`px`,this.canvas.width=this.canvasCtx.width=width$1*this.scale,this.canvas.height=this.canvasCtx.height=height$1*this.scale}if(!data||!data.markers){this.clear();return}this.current?this.optimiseAndDrawRoute(data,this.current):(this.clear(),data&&this.drawFreshRoute(data)),this.current=data.markers}clear(){this.current=null,this.canvasCtx.clearRect(0,0,this.canvas.width,this.canvas.height),this.canvasCtx.stroke()}drawFreshRoute(data){this.drawRoute({color:data.color,lineWidth:this.lineWidth,lineCap:`butt`,markers:data.markers,startIndex:0,drawFromIndex:2,drawToIndex:data.markers.length})}optimiseAndDrawRoute(data,prevMarkers){let markers$1=data.markers,ci=markers$1.length-2,pi=prevMarkers.length-2;for(;pi>=0&&ci>=0&&!(markers$1[ci]!==prevMarkers[pi]||markers$1[ci+1]!==prevMarkers[pi+1]);)ci-=2,pi-=2;(ci>=0||pi>=0)&&(this.canvasCtx.globalCompositeOperation=`destination-out`,this.drawRoute({color:data.color,lineWidth:this.lineWidth+2,markers:prevMarkers,drawToIndex:Math.min(pi+4,prevMarkers.length)}),this.canvasCtx.globalCompositeOperation=`source-over`,this.drawRoute({color:data.color,lineWidth:this.lineWidth,markers:data.markers,drawToIndex:Math.min(ci+6,data.markers.length)}))}drawRoute({color,lineWidth,lineCap=`round`,markers:markers$1,startIndex=0,drawFromIndex=0,drawToIndex}){let mapFac=this.scale/this.dimensions.scale,cx=this.dimensions.centerX*mapFac,cy=this.dimensions.centerY*mapFac;this.canvasCtx.beginPath(),this.canvasCtx.strokeStyle=color||this.color,this.canvasCtx.lineWidth=lineWidth*this.scale*this.dimensions.resScale,this.canvasCtx.lineCap=lineCap,this.canvasCtx.moveTo(markers$1[startIndex]*this.dimensions.resScale*mapFac+cx,-markers$1[startIndex+1]*this.dimensions.resScale*mapFac+cy);for(let i=drawFromIndex;iargs.map(arg=>typeof arg==`string`?arg:`[object]`)},createElementNS:{base:Document,getArgs:(...args)=>args.map(arg=>typeof arg==`string`?arg:`[object]`)},cloneNode:{base:Node,getArgs:deep=>[deep]},importNode:{base:Document,getArgs:(node,deep)=>[`[node]`,deep]},insertAdjacentHTML:{base:Element,getArgs:(position,text)=>[position,`[HTML:${text.length}chars]`]},innerHTML:{isSetter:!0,bases:[Element,HTMLElement],getArgs:value=>[`[HTML:${typeof value==`string`?value.length:0}chars]`]},outerHTML:{isSetter:!0,bases:[Element,HTMLElement],getArgs:value=>[`[HTML:${typeof value==`string`?value.length:0}chars]`]},appendChild:{base:Node,stats:`append`,getArgs:child=>[`[${child?.tagName||child?.nodeName||`node`}]`]},insertBefore:{base:Node,stats:`append`,getArgs:(newNode,referenceNode)=>[`[${newNode?.tagName||newNode?.nodeName||`node`}]`,`[${referenceNode?.tagName||referenceNode?.nodeName||`ref`}]`]},replaceChild:{base:Node,stats:`append`,getArgs:(newChild,oldChild)=>[`[${newChild?.tagName||newChild?.nodeName||`new`}]`,`[${oldChild?.tagName||oldChild?.nodeName||`old`}]`]},append:{base:Element,stats:`append`,getArgs:(...nodes)=>nodes.map(node=>`[${node?.tagName||node?.nodeName||typeof node==`string`?`text`:`node`}]`)},prepend:{base:Element,stats:`append`,getArgs:(...nodes)=>nodes.map(node=>`[${node?.tagName||node?.nodeName||typeof node==`string`?`text`:`node`}]`)},before:{base:Element,stats:`append`,getArgs:(...nodes)=>nodes.map(node=>`[${node?.tagName||node?.nodeName||typeof node==`string`?`text`:`node`}]`)},after:{base:Element,stats:`append`,getArgs:(...nodes)=>nodes.map(node=>`[${node?.tagName||node?.nodeName||typeof node==`string`?`text`:`node`}]`)}};function setupInterceptor(type){let interceptor=interceptors[type];if(interceptor.isSetter){let descriptor;if(interceptor.bases){for(let base of interceptor.bases)if(descriptor=Object.getOwnPropertyDescriptor(base.prototype,type),descriptor){interceptor.base=base;break}}descriptor&&(interceptor.original=descriptor)}else interceptor.original=interceptor.base.prototype[type];if(!interceptor.original){logger_default.warn(`No original for ${type}`);return}interceptor.call=(self$1,...args)=>{let stackTrace=captureStackTrace();if(stackTrace&&(includeAnonymousCalls||!stackTrace.hasAnonymous||stackTrace.filePaths.length>0)){let callData={type,timestamp:Date.now(),args:interceptor.getArgs(...args),stackTrace};if(interceptor.stats===`append`&&self$1)try{let mainContainer=self$1.closest?self$1.closest(`#mainContainer_apps`):null;if(mainContainer){let directChildDiv=self$1;for(;directChildDiv&&directChildDiv.parentNode&&directChildDiv.parentNode!==mainContainer;)directChildDiv=directChildDiv.parentNode;directChildDiv&&directChildDiv.parentNode===mainContainer&&directChildDiv.tagName===`DIV`&&(callData.uiAppInsertion={targetElement:directChildDiv})}}catch{}callQueue.push(callData)}if(interceptor.isSetter)interceptor.original.set.call(self$1,args[0]);else return interceptor.original.apply(self$1,args)},interceptor.isSetter?Object.defineProperty(interceptor.base.prototype,type,{get:interceptor.original.get,set:function(value){interceptor.call(this,value)},configurable:!0,enumerable:!0}):interceptor.base.prototype[type]=function(...args){return interceptor.call(this,...args)},interceptor.restore=()=>{interceptor.isSetter?Object.defineProperty(interceptor.base.prototype,type,{get:interceptor.original.get,set:interceptor.original.set,configurable:!0,enumerable:!0}):interceptor.base.prototype[type]=interceptor.original}}function captureStackTrace(){let stack$2=Error().stack;if(!stack$2)return null;let relevantLines=stack$2.split(` `).slice(STACK_TRACE_SKIP_LINES),filePaths=[],hasAnonymous=!1;for(let line of relevantLines){let match=line.match(STACK_TRACE_REGEX_FULL),functionName,filePath,lineNum,column;if(match)functionName=match[1],filePath=match[2],lineNum=match[3],column=match[4];else if(match=line.match(STACK_TRACE_REGEX),match)functionName=`anonymous`,filePath=match[1],lineNum=match[2],column=match[3];else continue;let isAnonymous=functionName?.includes(`anonymous`)||functionName?.includes(``)||!functionName||functionName.trim()===``;isAnonymous&&(hasAnonymous=!0,!includeAnonymousCalls)||filePaths.push({functionName,filePath,line:lineNum,column,isAnonymous})}return{filePaths,fullStack:stack$2,hasAnonymous}}async function processCallQueue(){if(statsProcessor.lastProcessTime=Date.now(),!(statsProcessor.isProcessing||callQueue.length===0)){statsProcessor.isProcessing=!0;try{let batch$1=callQueue.splice(0,Math.max(statsProcessor.batchSize,callQueue.length/5));statsProcessor.totalProcessed+=batch$1.length;for(let i=0;i{try{processCallQueue()}catch(error){logger_default.error(`Fatal error in DOM watchdog processing:`,error),destroy()}},statsProcessor.processInterval)}function getStats(){return{files:Object.fromEntries(statsProcessor.files),types:Object.fromEntries(statsProcessor.types),append:Object.fromEntries(statsProcessor.append)}}function clearStats(){statsProcessor.files.clear(),statsProcessor.types.clear(),statsProcessor.append.clear(),statsProcessor.uiApps.clear(),callQueue.length=0,statsProcessor.totalProcessed=0,statsProcessor.lastProcessTime=0,overlayActive&&updateOverlayDivs()}function restartTimer(){isInitialized&&startStatsProcessor()}function setIncludeAnonymousCalls(include){includeAnonymousCalls=include}var exposedFunctions=()=>({watchdogRecentCalls:getRecentCalls,watchdogCallChainStats:getCallChainStats,watchdogClearStats:clearStats,watchdogSetIncludeAnonymousCalls:setIncludeAnonymousCalls,watchdogDestroy:destroy,watchdogRestartTimer:restartTimer,watchdogUIAppsStats:getUIAppsStats,watchdogRefreshOverlay:refreshOverlay,watchdogStats:()=>{let stats=getStats(),format$2=obj=>Object.entries(obj).sort((a$1,b)=>b[1]-a$1[1]).map(([key,value])=>`${key}: ${value}`.replace(`\\`,`\\\\`)).join(`
  • `+b).split(R[0]).slice(1).map(R[3]?escape:inlineEscape).join(R[3]||`
    
  • `)+R[2]:f===`#`?``+inlineEscape(b.slice(f+1))+``:f===`<`?b:`

    `+inlineEscape(b)+`

    `}),h$1}function escape(t){return new Option(t).innerHTML}function inlineEscape(s){return escape(s).replace(/\\_/g,`⋿`).replace(/!\[([^\]]*)]\(([^(]+)\)/g,`$1`).replace(/\[([^\]]+)]\(([^(]+?)\)/g,`$1`.link(`$2`)).replace(/`([^`]+)`/g,`$1`).replace(/(\*\*|__)(?=\S)([^\r]*?\S[*_]*)\1/g,`$2`).replace(/(\*| _)(?=\S)([^\r]*?\S)\1/g,`$2`).replace(/⋿/g,`_`)}var content_exports=__export({bbcode:()=>bbcode_exports,markdown:()=>markdown_exports});const screenLocked=computed(()=>screenLockedState.value),loadingScreen=reactive({active:!1,visible:!1,fading:!1,shown:!1});var screenLockedState=ref(!1),loadingScreenStateWatcher=null,events;function screenLock(lock=!1){lock=!!lock,screenLockedState.value=lock;let body=document.body;body&&body.classList.toggle(`screen-locked`,lock)}async function startLoading$1(func){screenLock(!0),events||=useBridge().events,events.emit(`LoadingScreen`,{active:!0}),await nextTick(),setTimeout(()=>func(),500)}function linkLoadingScreenState(state){loadingScreenStateWatcher?.(),loadingScreenStateWatcher=watch([()=>state.active,()=>state.visible,()=>state.fading,()=>state.shown],([active,visible,fading,shown])=>{loadingScreen.active=active,loadingScreen.visible=visible,loadingScreen.fading=fading,loadingScreen.shown=shown,screenLock(active)})}function waitForLoadingScreenFadeIn$1(timeout=4e3){if(loadingScreen.visible&&!loadingScreen.fading)return;let fadeInPromise=new Promise(resolve$1=>{let unwatch=watch([()=>loadingScreen.visible,()=>loadingScreen.fading],([visible,fading])=>{visible&&!fading&&(unwatch(),resolve$1())},{immediate:!0})});return Promise.race([fadeInPromise,sleep(timeout)])}var bngNavigator=class{opts={root:null,container:null,bootscreen:null,north:null,clock:null,backgroundRgb:[50,50,50],roadColors:[`#FFFFFFFF`,`#A6A678FF`,`#A67854FF`],routeColor:`#3388EEFF`,markerColor:`#2C5CFF`,routes:!1,markers:!1,vehicles:!1,vehicleMarker:null,cameraColor:`#FD6A00`,vehicleColor:`#A3D39C`,rotate:!0,scale:1,pitch:0,offsetX:128,offsetY:64,resolution:4096,speedZoom:!1,speedOffset:0,speedPitch:!0,speedZoomIncrements:1,speedZoomMultiplier:2,speedZoomMax:200,speedZoomEffect:.15,hideBootscreen:!1};elms={root:document};mapScale=1;startup=!0;startupFallback=!0;layers={};layersLoadOrder=[bngNavLayerMap,bngNavLayerRoute,bngNavLayerMarkers,bngNavLayerVehicles,bngNavLayerElements,bngNavLayerBootscreen];setOptions(options){if(!(typeof options!=`object`||Array.isArray(options))){for(let key in this.opts)key in options&&(this.opts[key]=options[key]);for(let name in this.layers){let layer=this.layers[name];typeof layer.setOptions==`function`&&layer.setOptions(this.opts)}}}constructor(options){this.setOptions(options);for(let key of[`root`,`container`,`clock`,`north`,`bootscreen`]){let elm;typeof this.opts[key]==`string`?elm=this.elms.root.querySelector(this.opts[key]):this.opts[key]&&(elm=this.opts[key]),elm&&(elm instanceof HTMLElement||elm instanceof SVGElement)&&(this.elms[key]=elm)}if(!this.elms.root)throw Error(`Cannot find map root element`);if(!this.elms.container)throw Error(`Cannot find map container element`);this.elms.svg=new bngNavSVG(this.elms.container.children[0]);for(let cls of this.layersLoadOrder){let elms$4=cls.name===`map`?this.elms:{...this.elms,cvs:this.layers.map.cvs,routes:[this.layers.map.rwrapper,this.layers.map.rcanvas,this.layers.map.rcanvasCtx]};if(cls.canInit(elms$4,this.opts)){let dim=cls.name===`map`?this.mapScale:this.layers.map.dimensions,layer=new cls(elms$4,this.opts,dim);layer&&layer.name&&(this.layers[layer.name]=layer)}}this.layersLoadOrder=null;let expose=(layer,method,name=null)=>{this[name||method]=layer?layer[method].bind(layer):()=>{}};expose(this.layers.map,`setRotation`),expose(this.layers.map,`setLocation`),expose(this.layers.map,`setZoom`),expose(this.layers.map,`setScale`),expose(this.layers.map,`setSpeed`),expose(this.layers.map,`setOpacity`),expose(this.layers.route,`update`,`setRoute`),expose(this.layers.markers,`update`,`setMarkers`),expose(this.layers.bootscreen,`setImage`,`setBootscreenImage`)}update(data){data&&this.setup(data),this.layers.map.update(),this.layers.elements&&this.layers.elements.update(this.layers.map.state),this.layers.map.render()}setup(data){typeof data.terrainTiles==`object`&&!Array.isArray(data.terrainTiles)&&(data.terrainTiles=[]),this.layers.map.setMapSize(data)&&this.startupFallback?(this.startupFallback=!1,this.startup=!0):this.startup||(this.startupFallback=!0),this.startup&&(this.startup=!1,this.layers.map.applyMapSize(),this.layers.map.renderMap(data))}setData(data){if(!data||Object.keys(data).length===0){console.log(`Received empty map data`);return}this.layers.vehicles&&this.layers.vehicles.update(data),this.update(data),this.opts.hideBootscreen&&this.layers.bootscreen&&this.layers.bootscreen.hide()}updateData(data){typeof data==`object`&&(`x`in data&&`y`in data&&this.layers.map.setLocation(data.x,data.y,!1),`rotation`in data&&this.layers.map.setRotation(data.rotation,!1),`speed`in data&&this.layers.map.setSpeed(data.speed,!1),`ignitionLevel`in data&&this.layers.bootscreen&&this.layers.bootscreen.toggle(data.ignitionLevel<2),this.update())}},bngNavUtils=class{static truncDec(num,dec=2){let d=10**dec;return~~(num*d)/d}static setStyle(node,style){for(let name in style)node.style[name]=style[name]}},bngNavSVG=class{ns={svg:`http://www.w3.org/2000/svg`,xlink:`http://www.w3.org/1999/xlink`};root;constructor(root){if(!root||!root.tagName||root.tagName.toLowerCase()!==`svg`)throw Error(`Cannot access svg in a container`);this.root=root}setViewBox(viewBox){this.root.setAttributeNS(null,`viewBox`,viewBox)}createNode(tag,...args){let[attrs,parent]=args;parent||(attrs&&attrs instanceof SVGElement?(parent=attrs,attrs=null):parent=this.root);let node=document.createElementNS(this.ns.svg,tag);return attrs&&this.setAttrs(node,attrs),parent.appendChild(node),node}removeNode(node){node&&node.parentNode&&node.parentNode.removeChild(node)}setAttrs(node,attrs){for(let name in attrs){let ns=name.startsWith(`xlink:`)?this.ns.xlink:null;node.setAttributeNS(ns,name,attrs[name])}}clearNode(node){let elm;for(;elm=node.children[0];)node.removeChild(elm)}setStyle=bngNavUtils.setStyle;createCanvas(resolution){let fo=this.createNode(`foreignObject`);this.setStyle(fo,{position:`absolute`,x:`0`,y:`0`,width:`100%`,height:`100%`});let cvs=document.createElement(`canvas`);return cvs.width=resolution,cvs.height=resolution,fo.appendChild(cvs),[fo,cvs,cvs.getContext(`2d`)]}},bngNavLayerMap=class{static name=`map`;dimensions={ver:0,offset:512,scale:1,centerX:1024,centerY:1024,width:2048,height:2048,resScale:1};state={x:0,y:0,speed:0,scale:1,zoom:1,speedZoom:0,rotation:0,focusX:0,focusY:0,offsetX:0,offsetY:0};container;svg;wrapper;canvas;canvasCtx;rwrapper;rcanvas;rcanvasCtx;cvs;renders=[];rendered={terrainCvs:null,terrainCtx:null,roadsCvs:null,roadsCtx:null};terrainOpacity=1;gridGap=50;gridColour=`#cccccccc`;roadColors;resolution=2048;offsetX;offsetY;rotate;scale;pitch;speedPitch;speedOffset;speedZoom;speedZoomIncrements;speedZoomMultiplier;speedZoomMax;speedZoomEffect;static canInit(elms$4,opts){return!0}constructor({container,svg},opts,mapScale){this.name=this.constructor.name,this.container=container,this.svg=svg,[this.wrapper,this.canvas,this.canvasCtx]=svg.createCanvas(opts.resolution),[this.rwrapper,this.rcanvas,this.rcanvasCtx]=svg.createCanvas(opts.resolution);let that=this;this.rendered.terrainCvs=window.OffscreenCanvas?new window.OffscreenCanvas(1,1):document.createElement(`canvas`),this.rendered.terrainCtx=this.rendered.terrainCvs.getContext(`2d`),this.addRenderSource({passive:!0,source:this.rendered.terrainCvs,get alpha(){return that.terrainOpacity}}),this.rendered.roadsCvs=window.OffscreenCanvas?new window.OffscreenCanvas(1,1):document.createElement(`canvas`),this.rendered.roadsCtx=this.rendered.roadsCvs.getContext(`2d`),this.addRenderSource({passive:!0,source:this.rendered.roadsCvs}),this.dimensions.scale=mapScale,this.setOptions(opts),this.setOpacity(1)}setOptions(opts){this.bgRgb=opts.backgroundRgb.join(`, `),this.roadColors=opts.roadColors,this.resolution=opts.resolution,this.offsetX=opts.offsetX,this.offsetY=opts.offsetY,this.rotate=opts.rotate,this.scale=opts.scale,this.state.scale=this.scale*this.state.zoom,this.pitch=opts.pitch,this.speedPitch=opts.speedPitch,this.speedOffset=opts.speedOffset,this.speedZoom=opts.speedZoom,this.speedZoomIncrements=opts.speedZoomIncrements,this.speedZoomMultiplier=opts.speedZoomMultiplier,this.speedZoomMax=opts.speedZoomMax,this.speedZoomEffect=opts.speedZoomEffect}setLocation(x,y,doupdate=!0){this.state.x=-x,this.state.y=y,this.state.focusX=~~(this.state.x/this.dimensions.scale*this.dimensions.resScale),this.state.focusY=~~(this.state.y/this.dimensions.scale*this.dimensions.resScale),this.state.offsetX=this.dimensions.centerX-this.state.focusX,this.state.offsetY=this.dimensions.centerY-this.state.focusY,this.container.style.transformOrigin=`${this.state.offsetX}px ${this.state.offsetY}px`}setRotation(rotation,doupdate=!0){this.state.rotation=bngNavUtils.truncDec(rotation,3)%360,doupdate&&this.update()}setZoom(zoom,doupdate=!0){let fixed=(zoom-150)*2;this.setSpeed(fixed)}setScale(zoom,doupdate=!0){this.state.zoom=zoom,this.state.scale=this.scale*zoom}setSpeed(speed){this.state.speed=bngNavUtils.truncDec(speed,3),this.state.speed===0?this.state.speedZoom=0:this.state.speedZoom=bngNavUtils.truncDec(Math.min(1+this.state.speed*3.6*1.5,this.speedZoomMax)/this.speedZoomIncrements*this.speedZoomIncrements/this.speedZoomMax,3)}setOpacity(opacity){this.canvas.style.backgroundColor=`rgba(${this.bgRgb}, ${opacity})`,this.terrainOpacity=opacity}setMapSize(data){let res;return data.terrainTiles&&data.terrainTiles[0]&&data.terrainTiles[0].size?(this.setMapDimensions(data),res=!0):this.dimensions.ver===0&&(this.setMapDimensions(data),res=!1),res}setMapDimensions(data){let poss=[],tiles=data.terrainTiles||[];for(let tile of tiles)poss.push([tile.offset[0],-tile.offset[1]],[tile.offset[0]+tile.size[0],-tile.offset[1]+tile.size[1]]);for(let key in data.nodes)poss.push([data.nodes[key].pos[0],-data.nodes[key].pos[1]]);let minX=1/0,maxX=-1/0,minY=1/0,maxY=-1/0;for(let pos of poss)pos[0]/=this.dimensions.scale,pos[1]/=this.dimensions.scale,pos[0]maxX&&(maxX=pos[0]),pos[1]maxY&&(maxY=pos[1]);let dim={centerX:-minX,centerY:-minY,width:-minX+maxX,height:-minY+maxY};if((dim.centerX<0||dim.centerY<0)&&((isFinite(dim.centerX)||isFinite(dim.centerY))&&console.error(`Navigator: Invalid center point detected.`),dim.centerX=this.resolution/2,dim.centerY=this.resolution/2,dim.width=this.resolution,dim.height=this.resolution),this.dimensions.offset>0){let off=this.dimensions.offset;dim.centerX+=off,dim.width+=off*2,dim.centerY+=off,dim.height+=off*2}for(let key in dim.width>this.resolution||dim.height>this.resolution?(dim.resScale=this.resolution/(dim.width>dim.height?dim.width:dim.height),dim.width*=dim.resScale,dim.height*=dim.resScale,dim.centerX*=dim.resScale,dim.centerY*=dim.resScale,dim.offset=dim.offset>0?dim.offset/dim.resScale:0):dim.resScale=1,dim)key!==`resScale`&&(dim[key]=Math.round(dim[key]));let changed=!1;for(let key in dim)this.dimensions[key]!==dim[key]&&(this.dimensions[key]=dim[key],changed=!0);changed&&this.dimensions.ver++}applyMapSize(){this.container.style.width=this.dimensions.width+`px`,this.container.style.height=this.dimensions.height+`px`,this.svg.setViewBox(`0 0 ${this.dimensions.width} ${this.dimensions.height}`);let width$1=this.dimensions.width,height$1=this.dimensions.height;this.canvas.style.width=this.wrapper.style.width=width$1+`px`,this.canvas.style.height=this.wrapper.style.height=height$1+`px`,this.canvas.width=width$1,this.canvas.height=height$1,this.rendered.terrainCtx.clearRect(0,0,this.rendered.terrainCvs.width,this.rendered.terrainCvs.height),this.rendered.terrainCvs.width=width$1,this.rendered.terrainCvs.height=height$1,this.rendered.roadsCtx.clearRect(0,0,this.rendered.roadsCvs.width,this.rendered.roadsCvs.height),this.rendered.roadsCvs.width=width$1,this.rendered.roadsCvs.height=height$1}addRenderSource(source){if(typeof source!=`object`&&!(`source`in source))return console.error(`Navigator: Render source is invalid`);this.renders.push(source)}render(passive=!1){if(!passive)return;let ctx=this.canvasCtx,full=[0,0,this.dimensions.width,this.dimensions.height];ctx.clearRect(...full);for(let src of this.renders){if(!!src.passive!==passive||src.source.width===0||src.source.height===0)continue;let region=src.region;if(src.render){let res=src.render();typeof res==`object`&&`empty`in res&&(region={full:res,fullArray:[res.x1,res.y1,res.x2-res.x1,res.y2-res.y1]})}let pos=src.pos;pos||=(pos=region&&!region.full.empty?region.fullArray:full,[...pos,...pos]),src.alpha&&(ctx.globalAlpha=src.alpha),ctx.drawImage(src.source,...pos),ctx.globalAlpha=1}}renderMap(data){for(let key in this.drawTerrain(data,this.rendered.terrainCtx),data.nodes){let el=data.nodes[key];if(el.links)for(let key2 in el.links)el.links[key2].drivability=Math.round(el.links[key2].drivability*10)/10}this.drawRoads(data.nodes,0,.1,this.roadColors[2],this.rendered.roadsCtx),this.drawRoads(data.nodes,.1,.9,this.roadColors[1],this.rendered.roadsCtx),this.drawRoads(data.nodes,.9,1,this.roadColors[0],this.rendered.roadsCtx),this.render(!0)}drawTerrain(data,ctx){for(let x=this.gridGap;x{ctx.clearRect(...dest),ctx.drawImage(img,0,0,img.width,img.height,...dest),loading--,loading===0&&this.render(!0)}),img.addEventListener(`error`,()=>{console.error(`Navigator: Unable to load tile "${tile.file}"`),loading--,loading===0&&this.render(!0)}),img.src=tile.file}}createLine(ctx,p1,p2,color){Math.abs(p1.radius-p2.radius)>.2?this.varLine(ctx,p1.x,p1.y,p2.x,p2.y,p1.radius,p2.radius,color):(ctx.beginPath(),ctx.lineWidth=Math.max(p1.radius,p2.radius),ctx.lineCap=`round`,ctx.strokeStyle=color,ctx.moveTo(p1.x,p1.y),ctx.lineTo(p2.x,p2.y),ctx.stroke())}varLine(ctx,x1,y1,x2,y2,w1,w2,color){let dx=x2-x1,dy=y2-y1,length=dx*dx+dy*dy;if(length==0)return;length=Math.sqrt(length),w1*=.5,w2*=.5,dx/=length,dy/=length;let shiftx=-dy*w1,shifty=dx*w1;ctx.beginPath(),ctx.fillStyle=color,ctx.moveTo(x1+shiftx,y1+shifty),ctx.lineTo(x1-shiftx,y1-shifty),shiftx=-dy*w2,shifty=dx*w2,ctx.lineTo(x2-shiftx,y2-shifty),ctx.lineTo(x2+shiftx,y2+shifty),ctx.closePath(),ctx.arc(x1,y1,w1,0,2*Math.PI),ctx.arc(x2,y2,w2,0,2*Math.PI),ctx.fill()}drawRoads(nodes,drivabilityMin,drivabilityMax,colour,ctx){for(let key in nodes){let el=nodes[key];if(el.links)for(let key2 in el.links){let drivability=el.links[key2].drivability;if(drivabilitydrivabilityMax)continue;let el2=nodes[key2];this.createLine(ctx,{x:el.pos[0]/this.dimensions.scale*this.dimensions.resScale+this.dimensions.centerX,y:-el.pos[1]/this.dimensions.scale*this.dimensions.resScale+this.dimensions.centerY,radius:Math.min(Math.max(el.radius,0),5)*3*this.dimensions.resScale},{x:el2.pos[0]/this.dimensions.scale*this.dimensions.resScale+this.dimensions.centerX,y:-el2.pos[1]/this.dimensions.scale*this.dimensions.resScale+this.dimensions.centerY,radius:Math.min(Math.max(el2.radius,0),5)*3*this.dimensions.resScale},colour)}}}update(){let pos={x:-this.state.offsetX+this.offsetX,y:-this.state.offsetY+this.offsetY},rot={x:0,z:0};this.speedOffset>0&&(pos.y+=this.state.speedZoom*this.speedOffset),this.rotate&&(rot.x=this.pitch,this.speedPitch>0&&(rot.x+=this.speedPitch*this.state.speedZoom),rot.z=this.state.rotation);let scale=this.state.scale/this.dimensions.resScale;this.speedZoom&&(scale-=this.state.speedZoom*.1/this.dimensions.resScale),this.container.style.transform=`translate3d(${pos.x}px, ${pos.y}px, 0px) rotateX(${rot.x}deg) rotateZ(${rot.z}deg) scale(${scale})`}},bngNavLayerRoute=class{static name=`route`;dimensions;scale=1/3;lineWidth=10;color;wrapper;canvas;canvasCtx;current=null;static canInit(elms$4,opts){return!!opts.routes}constructor({routes,svg},opts,dimensions){this.name=this.constructor.name,[this.wrapper,this.canvas,this.canvasCtx]=routes||svg.createCanvas(opts.resolution),this.dimensions=dimensions,this.setOptions(opts)}setOptions(opts){this.color=opts.routeColor}update(data){if(this.dimver!==this.dimensions.ver){this.dimver=this.dimensions.ver;let width$1=this.dimensions.width,height$1=this.dimensions.height;this.canvas.style.width=this.wrapper.style.width=width$1+`px`,this.canvas.style.height=this.wrapper.style.height=height$1+`px`,this.canvas.width=this.canvasCtx.width=width$1*this.scale,this.canvas.height=this.canvasCtx.height=height$1*this.scale}if(!data||!data.markers){this.clear();return}this.current?this.optimiseAndDrawRoute(data,this.current):(this.clear(),data&&this.drawFreshRoute(data)),this.current=data.markers}clear(){this.current=null,this.canvasCtx.clearRect(0,0,this.canvas.width,this.canvas.height),this.canvasCtx.stroke()}drawFreshRoute(data){this.drawRoute({color:data.color,lineWidth:this.lineWidth,lineCap:`butt`,markers:data.markers,startIndex:0,drawFromIndex:2,drawToIndex:data.markers.length})}optimiseAndDrawRoute(data,prevMarkers){let markers$1=data.markers,ci=markers$1.length-2,pi=prevMarkers.length-2;for(;pi>=0&&ci>=0&&!(markers$1[ci]!==prevMarkers[pi]||markers$1[ci+1]!==prevMarkers[pi+1]);)ci-=2,pi-=2;(ci>=0||pi>=0)&&(this.canvasCtx.globalCompositeOperation=`destination-out`,this.drawRoute({color:data.color,lineWidth:this.lineWidth+2,markers:prevMarkers,drawToIndex:Math.min(pi+4,prevMarkers.length)}),this.canvasCtx.globalCompositeOperation=`source-over`,this.drawRoute({color:data.color,lineWidth:this.lineWidth,markers:data.markers,drawToIndex:Math.min(ci+6,data.markers.length)}))}drawRoute({color,lineWidth,lineCap=`round`,markers:markers$1,startIndex=0,drawFromIndex=0,drawToIndex}){let mapFac=this.scale/this.dimensions.scale,cx=this.dimensions.centerX*mapFac,cy=this.dimensions.centerY*mapFac;this.canvasCtx.beginPath(),this.canvasCtx.strokeStyle=color||this.color,this.canvasCtx.lineWidth=lineWidth*this.scale*this.dimensions.resScale,this.canvasCtx.lineCap=lineCap,this.canvasCtx.moveTo(markers$1[startIndex]*this.dimensions.resScale*mapFac+cx,-markers$1[startIndex+1]*this.dimensions.resScale*mapFac+cy);for(let i=drawFromIndex;iargs.map(arg=>typeof arg==`string`?arg:`[object]`)},createElementNS:{base:Document,getArgs:(...args)=>args.map(arg=>typeof arg==`string`?arg:`[object]`)},cloneNode:{base:Node,getArgs:deep=>[deep]},importNode:{base:Document,getArgs:(node,deep)=>[`[node]`,deep]},insertAdjacentHTML:{base:Element,getArgs:(position,text)=>[position,`[HTML:${text.length}chars]`]},innerHTML:{isSetter:!0,bases:[Element,HTMLElement],getArgs:value=>[`[HTML:${typeof value==`string`?value.length:0}chars]`]},outerHTML:{isSetter:!0,bases:[Element,HTMLElement],getArgs:value=>[`[HTML:${typeof value==`string`?value.length:0}chars]`]},appendChild:{base:Node,stats:`append`,getArgs:child=>[`[${child?.tagName||child?.nodeName||`node`}]`]},insertBefore:{base:Node,stats:`append`,getArgs:(newNode,referenceNode)=>[`[${newNode?.tagName||newNode?.nodeName||`node`}]`,`[${referenceNode?.tagName||referenceNode?.nodeName||`ref`}]`]},replaceChild:{base:Node,stats:`append`,getArgs:(newChild,oldChild)=>[`[${newChild?.tagName||newChild?.nodeName||`new`}]`,`[${oldChild?.tagName||oldChild?.nodeName||`old`}]`]},append:{base:Element,stats:`append`,getArgs:(...nodes)=>nodes.map(node=>`[${node?.tagName||node?.nodeName||typeof node==`string`?`text`:`node`}]`)},prepend:{base:Element,stats:`append`,getArgs:(...nodes)=>nodes.map(node=>`[${node?.tagName||node?.nodeName||typeof node==`string`?`text`:`node`}]`)},before:{base:Element,stats:`append`,getArgs:(...nodes)=>nodes.map(node=>`[${node?.tagName||node?.nodeName||typeof node==`string`?`text`:`node`}]`)},after:{base:Element,stats:`append`,getArgs:(...nodes)=>nodes.map(node=>`[${node?.tagName||node?.nodeName||typeof node==`string`?`text`:`node`}]`)}};function setupInterceptor(type){let interceptor=interceptors[type];if(interceptor.isSetter){let descriptor;if(interceptor.bases){for(let base of interceptor.bases)if(descriptor=Object.getOwnPropertyDescriptor(base.prototype,type),descriptor){interceptor.base=base;break}}descriptor&&(interceptor.original=descriptor)}else interceptor.original=interceptor.base.prototype[type];if(!interceptor.original){logger_default.warn(`No original for ${type}`);return}interceptor.call=(self$1,...args)=>{let stackTrace=captureStackTrace();if(stackTrace&&(includeAnonymousCalls||!stackTrace.hasAnonymous||stackTrace.filePaths.length>0)){let callData={type,timestamp:Date.now(),args:interceptor.getArgs(...args),stackTrace};if(interceptor.stats===`append`&&self$1)try{let mainContainer=self$1.closest?self$1.closest(`#mainContainer_apps`):null;if(mainContainer){let directChildDiv=self$1;for(;directChildDiv&&directChildDiv.parentNode&&directChildDiv.parentNode!==mainContainer;)directChildDiv=directChildDiv.parentNode;directChildDiv&&directChildDiv.parentNode===mainContainer&&directChildDiv.tagName===`DIV`&&(callData.uiAppInsertion={targetElement:directChildDiv})}}catch{}callQueue.push(callData)}if(interceptor.isSetter)interceptor.original.set.call(self$1,args[0]);else return interceptor.original.apply(self$1,args)},interceptor.isSetter?Object.defineProperty(interceptor.base.prototype,type,{get:interceptor.original.get,set:function(value){interceptor.call(this,value)},configurable:!0,enumerable:!0}):interceptor.base.prototype[type]=function(...args){return interceptor.call(this,...args)},interceptor.restore=()=>{interceptor.isSetter?Object.defineProperty(interceptor.base.prototype,type,{get:interceptor.original.get,set:interceptor.original.set,configurable:!0,enumerable:!0}):interceptor.base.prototype[type]=interceptor.original}}function captureStackTrace(){let stack$2=Error().stack;if(!stack$2)return null;let relevantLines=stack$2.split(` `).slice(STACK_TRACE_SKIP_LINES),filePaths=[],hasAnonymous=!1;for(let line of relevantLines){let match=line.match(STACK_TRACE_REGEX_FULL),functionName,filePath,lineNum,column;if(match)functionName=match[1],filePath=match[2],lineNum=match[3],column=match[4];else if(match=line.match(STACK_TRACE_REGEX),match)functionName=`anonymous`,filePath=match[1],lineNum=match[2],column=match[3];else continue;let isAnonymous=functionName?.includes(`anonymous`)||functionName?.includes(``)||!functionName||functionName.trim()===``;isAnonymous&&(hasAnonymous=!0,!includeAnonymousCalls)||filePaths.push({functionName,filePath,line:lineNum,column,isAnonymous})}return{filePaths,fullStack:stack$2,hasAnonymous}}async function processCallQueue(){if(statsProcessor.lastProcessTime=Date.now(),!(statsProcessor.isProcessing||callQueue.length===0)){statsProcessor.isProcessing=!0;try{let batch$1=callQueue.splice(0,Math.max(statsProcessor.batchSize,callQueue.length/5));statsProcessor.totalProcessed+=batch$1.length;for(let i=0;i{try{processCallQueue()}catch(error){logger_default.error(`Fatal error in DOM watchdog processing:`,error),destroy()}},statsProcessor.processInterval)}function getStats(){return{files:Object.fromEntries(statsProcessor.files),types:Object.fromEntries(statsProcessor.types),append:Object.fromEntries(statsProcessor.append)}}function clearStats(){statsProcessor.files.clear(),statsProcessor.types.clear(),statsProcessor.append.clear(),statsProcessor.uiApps.clear(),callQueue.length=0,statsProcessor.totalProcessed=0,statsProcessor.lastProcessTime=0,overlayActive&&updateOverlayDivs()}function restartTimer(){isInitialized&&startStatsProcessor()}function setIncludeAnonymousCalls(include){includeAnonymousCalls=include}var exposedFunctions=()=>({watchdogRecentCalls:getRecentCalls,watchdogCallChainStats:getCallChainStats,watchdogClearStats:clearStats,watchdogSetIncludeAnonymousCalls:setIncludeAnonymousCalls,watchdogDestroy:destroy,watchdogRestartTimer:restartTimer,watchdogUIAppsStats:getUIAppsStats,watchdogRefreshOverlay:refreshOverlay,watchdogStats:()=>{let stats=getStats(),format$2=obj=>Object.entries(obj).sort((a$1,b)=>b[1]-a$1[1]).map(([key,value])=>`${key}: ${value}`.replace(`\\`,`\\\\`)).join(`
  • `+b).split(R[0]).slice(1).map(R[3]?escape:inlineEscape).join(R[3]||`
    
  • `)+R[2]:f===`#`?``+inlineEscape(b.slice(f+1))+``:f===`<`?b:`

    `+inlineEscape(b)+`

    `}),h$1}function escape(t){return new Option(t).innerHTML}function inlineEscape(s){return escape(s).replace(/\\_/g,`⋿`).replace(/!\[([^\]]*)]\(([^(]+)\)/g,`$1`).replace(/\[([^\]]+)]\(([^(]+?)\)/g,`$1`.link(`$2`)).replace(/`([^`]+)`/g,`$1`).replace(/(\*\*|__)(?=\S)([^\r]*?\S[*_]*)\1/g,`$2`).replace(/(\*| _)(?=\S)([^\r]*?\S)\1/g,`$2`).replace(/⋿/g,`_`)}var content_exports=__export({bbcode:()=>bbcode_exports,markdown:()=>markdown_exports});const screenLocked=computed(()=>screenLockedState.value),loadingScreen=reactive({active:!1,visible:!1,fading:!1,shown:!1});var screenLockedState=ref(!1),loadingScreenStateWatcher=null,events;function screenLock(lock=!1){lock=!!lock,screenLockedState.value=lock;let body=document.body;body&&body.classList.toggle(`screen-locked`,lock)}async function startLoading$1(func){screenLock(!0),events||=useBridge().events,events.emit(`LoadingScreen`,{active:!0}),await nextTick(),setTimeout(()=>func(),500)}function linkLoadingScreenState(state){loadingScreenStateWatcher?.(),loadingScreenStateWatcher=watch([()=>state.active,()=>state.visible,()=>state.fading,()=>state.shown],([active,visible,fading,shown])=>{loadingScreen.active=active,loadingScreen.visible=visible,loadingScreen.fading=fading,loadingScreen.shown=shown,screenLock(active)})}function waitForLoadingScreenFadeIn$1(timeout=4e3){if(loadingScreen.visible&&!loadingScreen.fading)return;let fadeInPromise=new Promise(resolve$1=>{let unwatch=watch([()=>loadingScreen.visible,()=>loadingScreen.fading],([visible,fading])=>{visible&&!fading&&(unwatch(),resolve$1())},{immediate:!0})});return Promise.race([fadeInPromise,sleep(timeout)])}var bngNavigator=class{opts={root:null,container:null,bootscreen:null,north:null,clock:null,backgroundRgb:[50,50,50],roadColors:[`#FFFFFFFF`,`#A6A678FF`,`#A67854FF`],routeColor:`#3388EEFF`,markerColor:`#2C5CFF`,routes:!1,markers:!1,vehicles:!1,vehicleMarker:null,cameraColor:`#FD6A00`,vehicleColor:`#A3D39C`,rotate:!0,scale:1,pitch:0,offsetX:128,offsetY:64,resolution:4096,speedZoom:!1,speedOffset:0,speedPitch:!0,speedZoomIncrements:1,speedZoomMultiplier:2,speedZoomMax:200,speedZoomEffect:.15,hideBootscreen:!1};elms={root:document};mapScale=1;startup=!0;startupFallback=!0;layers={};layersLoadOrder=[bngNavLayerMap,bngNavLayerRoute,bngNavLayerMarkers,bngNavLayerVehicles,bngNavLayerElements,bngNavLayerBootscreen];setOptions(options){if(!(typeof options!=`object`||Array.isArray(options))){for(let key in this.opts)key in options&&(this.opts[key]=options[key]);for(let name in this.layers){let layer=this.layers[name];typeof layer.setOptions==`function`&&layer.setOptions(this.opts)}}}constructor(options){this.setOptions(options);for(let key of[`root`,`container`,`clock`,`north`,`bootscreen`]){let elm;typeof this.opts[key]==`string`?elm=this.elms.root.querySelector(this.opts[key]):this.opts[key]&&(elm=this.opts[key]),elm&&(elm instanceof HTMLElement||elm instanceof SVGElement)&&(this.elms[key]=elm)}if(!this.elms.root)throw Error(`Cannot find map root element`);if(!this.elms.container)throw Error(`Cannot find map container element`);this.elms.svg=new bngNavSVG(this.elms.container.children[0]);for(let cls of this.layersLoadOrder){let elms$4=cls.name===`map`?this.elms:{...this.elms,cvs:this.layers.map.cvs,routes:[this.layers.map.rwrapper,this.layers.map.rcanvas,this.layers.map.rcanvasCtx]};if(cls.canInit(elms$4,this.opts)){let dim=cls.name===`map`?this.mapScale:this.layers.map.dimensions,layer=new cls(elms$4,this.opts,dim);layer&&layer.name&&(this.layers[layer.name]=layer)}}this.layersLoadOrder=null;let expose=(layer,method,name=null)=>{this[name||method]=layer?layer[method].bind(layer):()=>{}};expose(this.layers.map,`setRotation`),expose(this.layers.map,`setLocation`),expose(this.layers.map,`setZoom`),expose(this.layers.map,`setScale`),expose(this.layers.map,`setSpeed`),expose(this.layers.map,`setOpacity`),expose(this.layers.route,`update`,`setRoute`),expose(this.layers.markers,`update`,`setMarkers`),expose(this.layers.bootscreen,`setImage`,`setBootscreenImage`)}update(data){data&&this.setup(data),this.layers.map.update(),this.layers.elements&&this.layers.elements.update(this.layers.map.state),this.layers.map.render()}setup(data){typeof data.terrainTiles==`object`&&!Array.isArray(data.terrainTiles)&&(data.terrainTiles=[]),this.layers.map.setMapSize(data)&&this.startupFallback?(this.startupFallback=!1,this.startup=!0):this.startup||(this.startupFallback=!0),this.startup&&(this.startup=!1,this.layers.map.applyMapSize(),this.layers.map.renderMap(data))}setData(data){if(!data||Object.keys(data).length===0){console.log(`Received empty map data`);return}this.layers.vehicles&&this.layers.vehicles.update(data),this.update(data),this.opts.hideBootscreen&&this.layers.bootscreen&&this.layers.bootscreen.hide()}updateData(data){typeof data==`object`&&(`x`in data&&`y`in data&&this.layers.map.setLocation(data.x,data.y,!1),`rotation`in data&&this.layers.map.setRotation(data.rotation,!1),`speed`in data&&this.layers.map.setSpeed(data.speed,!1),`ignitionLevel`in data&&this.layers.bootscreen&&this.layers.bootscreen.toggle(data.ignitionLevel<2),this.update())}},bngNavUtils=class{static truncDec(num,dec=2){let d=10**dec;return~~(num*d)/d}static setStyle(node,style){for(let name in style)node.style[name]=style[name]}},bngNavSVG=class{ns={svg:`http://www.w3.org/2000/svg`,xlink:`http://www.w3.org/1999/xlink`};root;constructor(root){if(!root||!root.tagName||root.tagName.toLowerCase()!==`svg`)throw Error(`Cannot access svg in a container`);this.root=root}setViewBox(viewBox){this.root.setAttributeNS(null,`viewBox`,viewBox)}createNode(tag,...args){let[attrs,parent]=args;parent||(attrs&&attrs instanceof SVGElement?(parent=attrs,attrs=null):parent=this.root);let node=document.createElementNS(this.ns.svg,tag);return attrs&&this.setAttrs(node,attrs),parent.appendChild(node),node}removeNode(node){node&&node.parentNode&&node.parentNode.removeChild(node)}setAttrs(node,attrs){for(let name in attrs){let ns=name.startsWith(`xlink:`)?this.ns.xlink:null;node.setAttributeNS(ns,name,attrs[name])}}clearNode(node){let elm;for(;elm=node.children[0];)node.removeChild(elm)}setStyle=bngNavUtils.setStyle;createCanvas(resolution){let fo=this.createNode(`foreignObject`);this.setStyle(fo,{position:`absolute`,x:`0`,y:`0`,width:`100%`,height:`100%`});let cvs=document.createElement(`canvas`);return cvs.width=resolution,cvs.height=resolution,fo.appendChild(cvs),[fo,cvs,cvs.getContext(`2d`)]}},bngNavLayerMap=class{static name=`map`;dimensions={ver:0,offset:512,scale:1,centerX:1024,centerY:1024,width:2048,height:2048,resScale:1};state={x:0,y:0,speed:0,scale:1,zoom:1,speedZoom:0,rotation:0,focusX:0,focusY:0,offsetX:0,offsetY:0};container;svg;wrapper;canvas;canvasCtx;rwrapper;rcanvas;rcanvasCtx;cvs;renders=[];rendered={terrainCvs:null,terrainCtx:null,roadsCvs:null,roadsCtx:null};terrainOpacity=1;gridGap=50;gridColour=`#cccccccc`;roadColors;resolution=2048;offsetX;offsetY;rotate;scale;pitch;speedPitch;speedOffset;speedZoom;speedZoomIncrements;speedZoomMultiplier;speedZoomMax;speedZoomEffect;static canInit(elms$4,opts){return!0}constructor({container,svg},opts,mapScale){this.name=this.constructor.name,this.container=container,this.svg=svg,[this.wrapper,this.canvas,this.canvasCtx]=svg.createCanvas(opts.resolution),[this.rwrapper,this.rcanvas,this.rcanvasCtx]=svg.createCanvas(opts.resolution);let that=this;this.rendered.terrainCvs=window.OffscreenCanvas?new window.OffscreenCanvas(1,1):document.createElement(`canvas`),this.rendered.terrainCtx=this.rendered.terrainCvs.getContext(`2d`),this.addRenderSource({passive:!0,source:this.rendered.terrainCvs,get alpha(){return that.terrainOpacity}}),this.rendered.roadsCvs=window.OffscreenCanvas?new window.OffscreenCanvas(1,1):document.createElement(`canvas`),this.rendered.roadsCtx=this.rendered.roadsCvs.getContext(`2d`),this.addRenderSource({passive:!0,source:this.rendered.roadsCvs}),this.dimensions.scale=mapScale,this.setOptions(opts),this.setOpacity(1)}setOptions(opts){this.bgRgb=opts.backgroundRgb.join(`, `),this.roadColors=opts.roadColors,this.resolution=opts.resolution,this.offsetX=opts.offsetX,this.offsetY=opts.offsetY,this.rotate=opts.rotate,this.scale=opts.scale,this.state.scale=this.scale*this.state.zoom,this.pitch=opts.pitch,this.speedPitch=opts.speedPitch,this.speedOffset=opts.speedOffset,this.speedZoom=opts.speedZoom,this.speedZoomIncrements=opts.speedZoomIncrements,this.speedZoomMultiplier=opts.speedZoomMultiplier,this.speedZoomMax=opts.speedZoomMax,this.speedZoomEffect=opts.speedZoomEffect}setLocation(x,y,doupdate=!0){this.state.x=-x,this.state.y=y,this.state.focusX=~~(this.state.x/this.dimensions.scale*this.dimensions.resScale),this.state.focusY=~~(this.state.y/this.dimensions.scale*this.dimensions.resScale),this.state.offsetX=this.dimensions.centerX-this.state.focusX,this.state.offsetY=this.dimensions.centerY-this.state.focusY,this.container.style.transformOrigin=`${this.state.offsetX}px ${this.state.offsetY}px`}setRotation(rotation,doupdate=!0){this.state.rotation=bngNavUtils.truncDec(rotation,3)%360,doupdate&&this.update()}setZoom(zoom,doupdate=!0){let fixed=(zoom-150)*2;this.setSpeed(fixed)}setScale(zoom,doupdate=!0){this.state.zoom=zoom,this.state.scale=this.scale*zoom}setSpeed(speed){this.state.speed=bngNavUtils.truncDec(speed,3),this.state.speed===0?this.state.speedZoom=0:this.state.speedZoom=bngNavUtils.truncDec(Math.min(1+this.state.speed*3.6*1.5,this.speedZoomMax)/this.speedZoomIncrements*this.speedZoomIncrements/this.speedZoomMax,3)}setOpacity(opacity){this.canvas.style.backgroundColor=`rgba(${this.bgRgb}, ${opacity})`,this.terrainOpacity=opacity}setMapSize(data){let res;return data.terrainTiles&&data.terrainTiles[0]&&data.terrainTiles[0].size?(this.setMapDimensions(data),res=!0):this.dimensions.ver===0&&(this.setMapDimensions(data),res=!1),res}setMapDimensions(data){let poss=[],tiles=data.terrainTiles||[];for(let tile of tiles)poss.push([tile.offset[0],-tile.offset[1]],[tile.offset[0]+tile.size[0],-tile.offset[1]+tile.size[1]]);for(let key in data.nodes)poss.push([data.nodes[key].pos[0],-data.nodes[key].pos[1]]);let minX=1/0,maxX=-1/0,minY=1/0,maxY=-1/0;for(let pos of poss)pos[0]/=this.dimensions.scale,pos[1]/=this.dimensions.scale,pos[0]maxX&&(maxX=pos[0]),pos[1]maxY&&(maxY=pos[1]);let dim={centerX:-minX,centerY:-minY,width:-minX+maxX,height:-minY+maxY};if((dim.centerX<0||dim.centerY<0)&&((isFinite(dim.centerX)||isFinite(dim.centerY))&&console.error(`Navigator: Invalid center point detected.`),dim.centerX=this.resolution/2,dim.centerY=this.resolution/2,dim.width=this.resolution,dim.height=this.resolution),this.dimensions.offset>0){let off=this.dimensions.offset;dim.centerX+=off,dim.width+=off*2,dim.centerY+=off,dim.height+=off*2}for(let key in dim.width>this.resolution||dim.height>this.resolution?(dim.resScale=this.resolution/(dim.width>dim.height?dim.width:dim.height),dim.width*=dim.resScale,dim.height*=dim.resScale,dim.centerX*=dim.resScale,dim.centerY*=dim.resScale,dim.offset=dim.offset>0?dim.offset/dim.resScale:0):dim.resScale=1,dim)key!==`resScale`&&(dim[key]=Math.round(dim[key]));let changed=!1;for(let key in dim)this.dimensions[key]!==dim[key]&&(this.dimensions[key]=dim[key],changed=!0);changed&&this.dimensions.ver++}applyMapSize(){this.container.style.width=this.dimensions.width+`px`,this.container.style.height=this.dimensions.height+`px`,this.svg.setViewBox(`0 0 ${this.dimensions.width} ${this.dimensions.height}`);let width$1=this.dimensions.width,height$1=this.dimensions.height;this.canvas.style.width=this.wrapper.style.width=width$1+`px`,this.canvas.style.height=this.wrapper.style.height=height$1+`px`,this.canvas.width=width$1,this.canvas.height=height$1,this.rendered.terrainCtx.clearRect(0,0,this.rendered.terrainCvs.width,this.rendered.terrainCvs.height),this.rendered.terrainCvs.width=width$1,this.rendered.terrainCvs.height=height$1,this.rendered.roadsCtx.clearRect(0,0,this.rendered.roadsCvs.width,this.rendered.roadsCvs.height),this.rendered.roadsCvs.width=width$1,this.rendered.roadsCvs.height=height$1}addRenderSource(source){if(typeof source!=`object`&&!(`source`in source))return console.error(`Navigator: Render source is invalid`);this.renders.push(source)}render(passive=!1){if(!passive)return;let ctx=this.canvasCtx,full=[0,0,this.dimensions.width,this.dimensions.height];ctx.clearRect(...full);for(let src of this.renders){if(!!src.passive!==passive||src.source.width===0||src.source.height===0)continue;let region=src.region;if(src.render){let res=src.render();typeof res==`object`&&`empty`in res&&(region={full:res,fullArray:[res.x1,res.y1,res.x2-res.x1,res.y2-res.y1]})}let pos=src.pos;pos||=(pos=region&&!region.full.empty?region.fullArray:full,[...pos,...pos]),src.alpha&&(ctx.globalAlpha=src.alpha),ctx.drawImage(src.source,...pos),ctx.globalAlpha=1}}renderMap(data){for(let key in this.drawTerrain(data,this.rendered.terrainCtx),data.nodes){let el=data.nodes[key];if(el.links)for(let key2 in el.links)el.links[key2].drivability=Math.round(el.links[key2].drivability*10)/10}this.drawRoads(data.nodes,0,.1,this.roadColors[2],this.rendered.roadsCtx),this.drawRoads(data.nodes,.1,.9,this.roadColors[1],this.rendered.roadsCtx),this.drawRoads(data.nodes,.9,1,this.roadColors[0],this.rendered.roadsCtx),this.render(!0)}drawTerrain(data,ctx){for(let x=this.gridGap;x{ctx.clearRect(...dest),ctx.drawImage(img,0,0,img.width,img.height,...dest),loading--,loading===0&&this.render(!0)}),img.addEventListener(`error`,()=>{console.error(`Navigator: Unable to load tile "${tile.file}"`),loading--,loading===0&&this.render(!0)}),img.src=tile.file}}createLine(ctx,p1,p2,color){Math.abs(p1.radius-p2.radius)>.2?this.varLine(ctx,p1.x,p1.y,p2.x,p2.y,p1.radius,p2.radius,color):(ctx.beginPath(),ctx.lineWidth=Math.max(p1.radius,p2.radius),ctx.lineCap=`round`,ctx.strokeStyle=color,ctx.moveTo(p1.x,p1.y),ctx.lineTo(p2.x,p2.y),ctx.stroke())}varLine(ctx,x1,y1,x2,y2,w1,w2,color){let dx=x2-x1,dy=y2-y1,length=dx*dx+dy*dy;if(length==0)return;length=Math.sqrt(length),w1*=.5,w2*=.5,dx/=length,dy/=length;let shiftx=-dy*w1,shifty=dx*w1;ctx.beginPath(),ctx.fillStyle=color,ctx.moveTo(x1+shiftx,y1+shifty),ctx.lineTo(x1-shiftx,y1-shifty),shiftx=-dy*w2,shifty=dx*w2,ctx.lineTo(x2-shiftx,y2-shifty),ctx.lineTo(x2+shiftx,y2+shifty),ctx.closePath(),ctx.arc(x1,y1,w1,0,2*Math.PI),ctx.arc(x2,y2,w2,0,2*Math.PI),ctx.fill()}drawRoads(nodes,drivabilityMin,drivabilityMax,colour,ctx){for(let key in nodes){let el=nodes[key];if(el.links)for(let key2 in el.links){let drivability=el.links[key2].drivability;if(drivabilitydrivabilityMax)continue;let el2=nodes[key2];this.createLine(ctx,{x:el.pos[0]/this.dimensions.scale*this.dimensions.resScale+this.dimensions.centerX,y:-el.pos[1]/this.dimensions.scale*this.dimensions.resScale+this.dimensions.centerY,radius:Math.min(Math.max(el.radius,0),5)*3*this.dimensions.resScale},{x:el2.pos[0]/this.dimensions.scale*this.dimensions.resScale+this.dimensions.centerX,y:-el2.pos[1]/this.dimensions.scale*this.dimensions.resScale+this.dimensions.centerY,radius:Math.min(Math.max(el2.radius,0),5)*3*this.dimensions.resScale},colour)}}}update(){let pos={x:-this.state.offsetX+this.offsetX,y:-this.state.offsetY+this.offsetY},rot={x:0,z:0};this.speedOffset>0&&(pos.y+=this.state.speedZoom*this.speedOffset),this.rotate&&(rot.x=this.pitch,this.speedPitch>0&&(rot.x+=this.speedPitch*this.state.speedZoom),rot.z=this.state.rotation);let scale=this.state.scale/this.dimensions.resScale;this.speedZoom&&(scale-=this.state.speedZoom*.1/this.dimensions.resScale),this.container.style.transform=`translate3d(${pos.x}px, ${pos.y}px, 0px) rotateX(${rot.x}deg) rotateZ(${rot.z}deg) scale(${scale})`}},bngNavLayerRoute=class{static name=`route`;dimensions;scale=1/3;lineWidth=10;color;wrapper;canvas;canvasCtx;current=null;static canInit(elms$4,opts){return!!opts.routes}constructor({routes,svg},opts,dimensions){this.name=this.constructor.name,[this.wrapper,this.canvas,this.canvasCtx]=routes||svg.createCanvas(opts.resolution),this.dimensions=dimensions,this.setOptions(opts)}setOptions(opts){this.color=opts.routeColor}update(data){if(this.dimver!==this.dimensions.ver){this.dimver=this.dimensions.ver;let width$1=this.dimensions.width,height$1=this.dimensions.height;this.canvas.style.width=this.wrapper.style.width=width$1+`px`,this.canvas.style.height=this.wrapper.style.height=height$1+`px`,this.canvas.width=this.canvasCtx.width=width$1*this.scale,this.canvas.height=this.canvasCtx.height=height$1*this.scale}if(!data||!data.markers){this.clear();return}this.current?this.optimiseAndDrawRoute(data,this.current):(this.clear(),data&&this.drawFreshRoute(data)),this.current=data.markers}clear(){this.current=null,this.canvasCtx.clearRect(0,0,this.canvas.width,this.canvas.height),this.canvasCtx.stroke()}drawFreshRoute(data){this.drawRoute({color:data.color,lineWidth:this.lineWidth,lineCap:`butt`,markers:data.markers,startIndex:0,drawFromIndex:2,drawToIndex:data.markers.length})}optimiseAndDrawRoute(data,prevMarkers){let markers$1=data.markers,ci=markers$1.length-2,pi=prevMarkers.length-2;for(;pi>=0&&ci>=0&&!(markers$1[ci]!==prevMarkers[pi]||markers$1[ci+1]!==prevMarkers[pi+1]);)ci-=2,pi-=2;(ci>=0||pi>=0)&&(this.canvasCtx.globalCompositeOperation=`destination-out`,this.drawRoute({color:data.color,lineWidth:this.lineWidth+2,markers:prevMarkers,drawToIndex:Math.min(pi+4,prevMarkers.length)}),this.canvasCtx.globalCompositeOperation=`source-over`,this.drawRoute({color:data.color,lineWidth:this.lineWidth,markers:data.markers,drawToIndex:Math.min(ci+6,data.markers.length)}))}drawRoute({color,lineWidth,lineCap=`round`,markers:markers$1,startIndex=0,drawFromIndex=0,drawToIndex}){let mapFac=this.scale/this.dimensions.scale,cx=this.dimensions.centerX*mapFac,cy=this.dimensions.centerY*mapFac;this.canvasCtx.beginPath(),this.canvasCtx.strokeStyle=color||this.color,this.canvasCtx.lineWidth=lineWidth*this.scale*this.dimensions.resScale,this.canvasCtx.lineCap=lineCap,this.canvasCtx.moveTo(markers$1[startIndex]*this.dimensions.resScale*mapFac+cx,-markers$1[startIndex+1]*this.dimensions.resScale*mapFac+cy);for(let i=drawFromIndex;iargs.map(arg=>typeof arg==`string`?arg:`[object]`)},createElementNS:{base:Document,getArgs:(...args)=>args.map(arg=>typeof arg==`string`?arg:`[object]`)},cloneNode:{base:Node,getArgs:deep=>[deep]},importNode:{base:Document,getArgs:(node,deep)=>[`[node]`,deep]},insertAdjacentHTML:{base:Element,getArgs:(position,text)=>[position,`[HTML:${text.length}chars]`]},innerHTML:{isSetter:!0,bases:[Element,HTMLElement],getArgs:value=>[`[HTML:${typeof value==`string`?value.length:0}chars]`]},outerHTML:{isSetter:!0,bases:[Element,HTMLElement],getArgs:value=>[`[HTML:${typeof value==`string`?value.length:0}chars]`]},appendChild:{base:Node,stats:`append`,getArgs:child=>[`[${child?.tagName||child?.nodeName||`node`}]`]},insertBefore:{base:Node,stats:`append`,getArgs:(newNode,referenceNode)=>[`[${newNode?.tagName||newNode?.nodeName||`node`}]`,`[${referenceNode?.tagName||referenceNode?.nodeName||`ref`}]`]},replaceChild:{base:Node,stats:`append`,getArgs:(newChild,oldChild)=>[`[${newChild?.tagName||newChild?.nodeName||`new`}]`,`[${oldChild?.tagName||oldChild?.nodeName||`old`}]`]},append:{base:Element,stats:`append`,getArgs:(...nodes)=>nodes.map(node=>`[${node?.tagName||node?.nodeName||typeof node==`string`?`text`:`node`}]`)},prepend:{base:Element,stats:`append`,getArgs:(...nodes)=>nodes.map(node=>`[${node?.tagName||node?.nodeName||typeof node==`string`?`text`:`node`}]`)},before:{base:Element,stats:`append`,getArgs:(...nodes)=>nodes.map(node=>`[${node?.tagName||node?.nodeName||typeof node==`string`?`text`:`node`}]`)},after:{base:Element,stats:`append`,getArgs:(...nodes)=>nodes.map(node=>`[${node?.tagName||node?.nodeName||typeof node==`string`?`text`:`node`}]`)}};function setupInterceptor(type){let interceptor=interceptors[type];if(interceptor.isSetter){let descriptor;if(interceptor.bases){for(let base of interceptor.bases)if(descriptor=Object.getOwnPropertyDescriptor(base.prototype,type),descriptor){interceptor.base=base;break}}descriptor&&(interceptor.original=descriptor)}else interceptor.original=interceptor.base.prototype[type];if(!interceptor.original){logger_default.warn(`No original for ${type}`);return}interceptor.call=(self$1,...args)=>{let stackTrace=captureStackTrace();if(stackTrace&&(includeAnonymousCalls||!stackTrace.hasAnonymous||stackTrace.filePaths.length>0)){let callData={type,timestamp:Date.now(),args:interceptor.getArgs(...args),stackTrace};if(interceptor.stats===`append`&&self$1)try{let mainContainer=self$1.closest?self$1.closest(`#mainContainer_apps`):null;if(mainContainer){let directChildDiv=self$1;for(;directChildDiv&&directChildDiv.parentNode&&directChildDiv.parentNode!==mainContainer;)directChildDiv=directChildDiv.parentNode;directChildDiv&&directChildDiv.parentNode===mainContainer&&directChildDiv.tagName===`DIV`&&(callData.uiAppInsertion={targetElement:directChildDiv})}}catch{}callQueue.push(callData)}if(interceptor.isSetter)interceptor.original.set.call(self$1,args[0]);else return interceptor.original.apply(self$1,args)},interceptor.isSetter?Object.defineProperty(interceptor.base.prototype,type,{get:interceptor.original.get,set:function(value){interceptor.call(this,value)},configurable:!0,enumerable:!0}):interceptor.base.prototype[type]=function(...args){return interceptor.call(this,...args)},interceptor.restore=()=>{interceptor.isSetter?Object.defineProperty(interceptor.base.prototype,type,{get:interceptor.original.get,set:interceptor.original.set,configurable:!0,enumerable:!0}):interceptor.base.prototype[type]=interceptor.original}}function captureStackTrace(){let stack$2=Error().stack;if(!stack$2)return null;let relevantLines=stack$2.split(` `).slice(STACK_TRACE_SKIP_LINES),filePaths=[],hasAnonymous=!1;for(let line of relevantLines){let match=line.match(STACK_TRACE_REGEX_FULL),functionName,filePath,lineNum,column;if(match)functionName=match[1],filePath=match[2],lineNum=match[3],column=match[4];else if(match=line.match(STACK_TRACE_REGEX),match)functionName=`anonymous`,filePath=match[1],lineNum=match[2],column=match[3];else continue;let isAnonymous=functionName?.includes(`anonymous`)||functionName?.includes(``)||!functionName||functionName.trim()===``;isAnonymous&&(hasAnonymous=!0,!includeAnonymousCalls)||filePaths.push({functionName,filePath,line:lineNum,column,isAnonymous})}return{filePaths,fullStack:stack$2,hasAnonymous}}async function processCallQueue(){if(statsProcessor.lastProcessTime=Date.now(),!(statsProcessor.isProcessing||callQueue.length===0)){statsProcessor.isProcessing=!0;try{let batch$1=callQueue.splice(0,Math.max(statsProcessor.batchSize,callQueue.length/5));statsProcessor.totalProcessed+=batch$1.length;for(let i=0;i{try{processCallQueue()}catch(error){logger_default.error(`Fatal error in DOM watchdog processing:`,error),destroy()}},statsProcessor.processInterval)}function getStats(){return{files:Object.fromEntries(statsProcessor.files),types:Object.fromEntries(statsProcessor.types),append:Object.fromEntries(statsProcessor.append)}}function clearStats(){statsProcessor.files.clear(),statsProcessor.types.clear(),statsProcessor.append.clear(),statsProcessor.uiApps.clear(),callQueue.length=0,statsProcessor.totalProcessed=0,statsProcessor.lastProcessTime=0,overlayActive&&updateOverlayDivs()}function restartTimer(){isInitialized&&startStatsProcessor()}function setIncludeAnonymousCalls(include){includeAnonymousCalls=include}var exposedFunctions=()=>({watchdogRecentCalls:getRecentCalls,watchdogCallChainStats:getCallChainStats,watchdogClearStats:clearStats,watchdogSetIncludeAnonymousCalls:setIncludeAnonymousCalls,watchdogDestroy:destroy,watchdogRestartTimer:restartTimer,watchdogUIAppsStats:getUIAppsStats,watchdogRefreshOverlay:refreshOverlay,watchdogStats:()=>{let stats=getStats(),format$2=obj=>Object.entries(obj).sort((a$1,b)=>b[1]-a$1[1]).map(([key,value])=>`${key}: ${value}`.replace(`\\`,`\\\\`)).join(`
  • `+b).split(R[0]).slice(1).map(R[3]?escape:inlineEscape).join(R[3]||`
    
  • `)+R[2]:f===`#`?``+inlineEscape(b.slice(f+1))+``:f===`<`?b:`

    `+inlineEscape(b)+`

    `}),h$1}function escape(t){return new Option(t).innerHTML}function inlineEscape(s){return escape(s).replace(/\\_/g,`⋿`).replace(/!\[([^\]]*)]\(([^(]+)\)/g,`$1`).replace(/\[([^\]]+)]\(([^(]+?)\)/g,`$1`.link(`$2`)).replace(/`([^`]+)`/g,`$1`).replace(/(\*\*|__)(?=\S)([^\r]*?\S[*_]*)\1/g,`$2`).replace(/(\*| _)(?=\S)([^\r]*?\S)\1/g,`$2`).replace(/⋿/g,`_`)}var content_exports=__export({bbcode:()=>bbcode_exports,markdown:()=>markdown_exports});const screenLocked=computed(()=>screenLockedState.value),loadingScreen=reactive({active:!1,visible:!1,fading:!1,shown:!1});var screenLockedState=ref(!1),loadingScreenStateWatcher=null,events;function screenLock(lock=!1){lock=!!lock,screenLockedState.value=lock;let body=document.body;body&&body.classList.toggle(`screen-locked`,lock)}async function startLoading$1(func){screenLock(!0),events||=useBridge().events,events.emit(`LoadingScreen`,{active:!0}),await nextTick(),setTimeout(()=>func(),500)}function linkLoadingScreenState(state){loadingScreenStateWatcher?.(),loadingScreenStateWatcher=watch([()=>state.active,()=>state.visible,()=>state.fading,()=>state.shown],([active,visible,fading,shown])=>{loadingScreen.active=active,loadingScreen.visible=visible,loadingScreen.fading=fading,loadingScreen.shown=shown,screenLock(active)})}function waitForLoadingScreenFadeIn$1(timeout=4e3){if(loadingScreen.visible&&!loadingScreen.fading)return;let fadeInPromise=new Promise(resolve$1=>{let unwatch=watch([()=>loadingScreen.visible,()=>loadingScreen.fading],([visible,fading])=>{visible&&!fading&&(unwatch(),resolve$1())},{immediate:!0})});return Promise.race([fadeInPromise,sleep(timeout)])}var bngNavigator=class{opts={root:null,container:null,bootscreen:null,north:null,clock:null,backgroundRgb:[50,50,50],roadColors:[`#FFFFFFFF`,`#A6A678FF`,`#A67854FF`],routeColor:`#3388EEFF`,markerColor:`#2C5CFF`,routes:!1,markers:!1,vehicles:!1,vehicleMarker:null,cameraColor:`#FD6A00`,vehicleColor:`#A3D39C`,rotate:!0,scale:1,pitch:0,offsetX:128,offsetY:64,resolution:4096,speedZoom:!1,speedOffset:0,speedPitch:!0,speedZoomIncrements:1,speedZoomMultiplier:2,speedZoomMax:200,speedZoomEffect:.15,hideBootscreen:!1};elms={root:document};mapScale=1;startup=!0;startupFallback=!0;layers={};layersLoadOrder=[bngNavLayerMap,bngNavLayerRoute,bngNavLayerMarkers,bngNavLayerVehicles,bngNavLayerElements,bngNavLayerBootscreen];setOptions(options){if(!(typeof options!=`object`||Array.isArray(options))){for(let key in this.opts)key in options&&(this.opts[key]=options[key]);for(let name in this.layers){let layer=this.layers[name];typeof layer.setOptions==`function`&&layer.setOptions(this.opts)}}}constructor(options){this.setOptions(options);for(let key of[`root`,`container`,`clock`,`north`,`bootscreen`]){let elm;typeof this.opts[key]==`string`?elm=this.elms.root.querySelector(this.opts[key]):this.opts[key]&&(elm=this.opts[key]),elm&&(elm instanceof HTMLElement||elm instanceof SVGElement)&&(this.elms[key]=elm)}if(!this.elms.root)throw Error(`Cannot find map root element`);if(!this.elms.container)throw Error(`Cannot find map container element`);this.elms.svg=new bngNavSVG(this.elms.container.children[0]);for(let cls of this.layersLoadOrder){let elms$4=cls.name===`map`?this.elms:{...this.elms,cvs:this.layers.map.cvs,routes:[this.layers.map.rwrapper,this.layers.map.rcanvas,this.layers.map.rcanvasCtx]};if(cls.canInit(elms$4,this.opts)){let dim=cls.name===`map`?this.mapScale:this.layers.map.dimensions,layer=new cls(elms$4,this.opts,dim);layer&&layer.name&&(this.layers[layer.name]=layer)}}this.layersLoadOrder=null;let expose=(layer,method,name=null)=>{this[name||method]=layer?layer[method].bind(layer):()=>{}};expose(this.layers.map,`setRotation`),expose(this.layers.map,`setLocation`),expose(this.layers.map,`setZoom`),expose(this.layers.map,`setScale`),expose(this.layers.map,`setSpeed`),expose(this.layers.map,`setOpacity`),expose(this.layers.route,`update`,`setRoute`),expose(this.layers.markers,`update`,`setMarkers`),expose(this.layers.bootscreen,`setImage`,`setBootscreenImage`)}update(data){data&&this.setup(data),this.layers.map.update(),this.layers.elements&&this.layers.elements.update(this.layers.map.state),this.layers.map.render()}setup(data){typeof data.terrainTiles==`object`&&!Array.isArray(data.terrainTiles)&&(data.terrainTiles=[]),this.layers.map.setMapSize(data)&&this.startupFallback?(this.startupFallback=!1,this.startup=!0):this.startup||(this.startupFallback=!0),this.startup&&(this.startup=!1,this.layers.map.applyMapSize(),this.layers.map.renderMap(data))}setData(data){if(!data||Object.keys(data).length===0){console.log(`Received empty map data`);return}this.layers.vehicles&&this.layers.vehicles.update(data),this.update(data),this.opts.hideBootscreen&&this.layers.bootscreen&&this.layers.bootscreen.hide()}updateData(data){typeof data==`object`&&(`x`in data&&`y`in data&&this.layers.map.setLocation(data.x,data.y,!1),`rotation`in data&&this.layers.map.setRotation(data.rotation,!1),`speed`in data&&this.layers.map.setSpeed(data.speed,!1),`ignitionLevel`in data&&this.layers.bootscreen&&this.layers.bootscreen.toggle(data.ignitionLevel<2),this.update())}},bngNavUtils=class{static truncDec(num,dec=2){let d=10**dec;return~~(num*d)/d}static setStyle(node,style){for(let name in style)node.style[name]=style[name]}},bngNavSVG=class{ns={svg:`http://www.w3.org/2000/svg`,xlink:`http://www.w3.org/1999/xlink`};root;constructor(root){if(!root||!root.tagName||root.tagName.toLowerCase()!==`svg`)throw Error(`Cannot access svg in a container`);this.root=root}setViewBox(viewBox){this.root.setAttributeNS(null,`viewBox`,viewBox)}createNode(tag,...args){let[attrs,parent]=args;parent||(attrs&&attrs instanceof SVGElement?(parent=attrs,attrs=null):parent=this.root);let node=document.createElementNS(this.ns.svg,tag);return attrs&&this.setAttrs(node,attrs),parent.appendChild(node),node}removeNode(node){node&&node.parentNode&&node.parentNode.removeChild(node)}setAttrs(node,attrs){for(let name in attrs){let ns=name.startsWith(`xlink:`)?this.ns.xlink:null;node.setAttributeNS(ns,name,attrs[name])}}clearNode(node){let elm;for(;elm=node.children[0];)node.removeChild(elm)}setStyle=bngNavUtils.setStyle;createCanvas(resolution){let fo=this.createNode(`foreignObject`);this.setStyle(fo,{position:`absolute`,x:`0`,y:`0`,width:`100%`,height:`100%`});let cvs=document.createElement(`canvas`);return cvs.width=resolution,cvs.height=resolution,fo.appendChild(cvs),[fo,cvs,cvs.getContext(`2d`)]}},bngNavLayerMap=class{static name=`map`;dimensions={ver:0,offset:512,scale:1,centerX:1024,centerY:1024,width:2048,height:2048,resScale:1};state={x:0,y:0,speed:0,scale:1,zoom:1,speedZoom:0,rotation:0,focusX:0,focusY:0,offsetX:0,offsetY:0};container;svg;wrapper;canvas;canvasCtx;rwrapper;rcanvas;rcanvasCtx;cvs;renders=[];rendered={terrainCvs:null,terrainCtx:null,roadsCvs:null,roadsCtx:null};terrainOpacity=1;gridGap=50;gridColour=`#cccccccc`;roadColors;resolution=2048;offsetX;offsetY;rotate;scale;pitch;speedPitch;speedOffset;speedZoom;speedZoomIncrements;speedZoomMultiplier;speedZoomMax;speedZoomEffect;static canInit(elms$4,opts){return!0}constructor({container,svg},opts,mapScale){this.name=this.constructor.name,this.container=container,this.svg=svg,[this.wrapper,this.canvas,this.canvasCtx]=svg.createCanvas(opts.resolution),[this.rwrapper,this.rcanvas,this.rcanvasCtx]=svg.createCanvas(opts.resolution);let that=this;this.rendered.terrainCvs=window.OffscreenCanvas?new window.OffscreenCanvas(1,1):document.createElement(`canvas`),this.rendered.terrainCtx=this.rendered.terrainCvs.getContext(`2d`),this.addRenderSource({passive:!0,source:this.rendered.terrainCvs,get alpha(){return that.terrainOpacity}}),this.rendered.roadsCvs=window.OffscreenCanvas?new window.OffscreenCanvas(1,1):document.createElement(`canvas`),this.rendered.roadsCtx=this.rendered.roadsCvs.getContext(`2d`),this.addRenderSource({passive:!0,source:this.rendered.roadsCvs}),this.dimensions.scale=mapScale,this.setOptions(opts),this.setOpacity(1)}setOptions(opts){this.bgRgb=opts.backgroundRgb.join(`, `),this.roadColors=opts.roadColors,this.resolution=opts.resolution,this.offsetX=opts.offsetX,this.offsetY=opts.offsetY,this.rotate=opts.rotate,this.scale=opts.scale,this.state.scale=this.scale*this.state.zoom,this.pitch=opts.pitch,this.speedPitch=opts.speedPitch,this.speedOffset=opts.speedOffset,this.speedZoom=opts.speedZoom,this.speedZoomIncrements=opts.speedZoomIncrements,this.speedZoomMultiplier=opts.speedZoomMultiplier,this.speedZoomMax=opts.speedZoomMax,this.speedZoomEffect=opts.speedZoomEffect}setLocation(x,y,doupdate=!0){this.state.x=-x,this.state.y=y,this.state.focusX=~~(this.state.x/this.dimensions.scale*this.dimensions.resScale),this.state.focusY=~~(this.state.y/this.dimensions.scale*this.dimensions.resScale),this.state.offsetX=this.dimensions.centerX-this.state.focusX,this.state.offsetY=this.dimensions.centerY-this.state.focusY,this.container.style.transformOrigin=`${this.state.offsetX}px ${this.state.offsetY}px`}setRotation(rotation,doupdate=!0){this.state.rotation=bngNavUtils.truncDec(rotation,3)%360,doupdate&&this.update()}setZoom(zoom,doupdate=!0){let fixed=(zoom-150)*2;this.setSpeed(fixed)}setScale(zoom,doupdate=!0){this.state.zoom=zoom,this.state.scale=this.scale*zoom}setSpeed(speed){this.state.speed=bngNavUtils.truncDec(speed,3),this.state.speed===0?this.state.speedZoom=0:this.state.speedZoom=bngNavUtils.truncDec(Math.min(1+this.state.speed*3.6*1.5,this.speedZoomMax)/this.speedZoomIncrements*this.speedZoomIncrements/this.speedZoomMax,3)}setOpacity(opacity){this.canvas.style.backgroundColor=`rgba(${this.bgRgb}, ${opacity})`,this.terrainOpacity=opacity}setMapSize(data){let res;return data.terrainTiles&&data.terrainTiles[0]&&data.terrainTiles[0].size?(this.setMapDimensions(data),res=!0):this.dimensions.ver===0&&(this.setMapDimensions(data),res=!1),res}setMapDimensions(data){let poss=[],tiles=data.terrainTiles||[];for(let tile of tiles)poss.push([tile.offset[0],-tile.offset[1]],[tile.offset[0]+tile.size[0],-tile.offset[1]+tile.size[1]]);for(let key in data.nodes)poss.push([data.nodes[key].pos[0],-data.nodes[key].pos[1]]);let minX=1/0,maxX=-1/0,minY=1/0,maxY=-1/0;for(let pos of poss)pos[0]/=this.dimensions.scale,pos[1]/=this.dimensions.scale,pos[0]maxX&&(maxX=pos[0]),pos[1]maxY&&(maxY=pos[1]);let dim={centerX:-minX,centerY:-minY,width:-minX+maxX,height:-minY+maxY};if((dim.centerX<0||dim.centerY<0)&&((isFinite(dim.centerX)||isFinite(dim.centerY))&&console.error(`Navigator: Invalid center point detected.`),dim.centerX=this.resolution/2,dim.centerY=this.resolution/2,dim.width=this.resolution,dim.height=this.resolution),this.dimensions.offset>0){let off=this.dimensions.offset;dim.centerX+=off,dim.width+=off*2,dim.centerY+=off,dim.height+=off*2}for(let key in dim.width>this.resolution||dim.height>this.resolution?(dim.resScale=this.resolution/(dim.width>dim.height?dim.width:dim.height),dim.width*=dim.resScale,dim.height*=dim.resScale,dim.centerX*=dim.resScale,dim.centerY*=dim.resScale,dim.offset=dim.offset>0?dim.offset/dim.resScale:0):dim.resScale=1,dim)key!==`resScale`&&(dim[key]=Math.round(dim[key]));let changed=!1;for(let key in dim)this.dimensions[key]!==dim[key]&&(this.dimensions[key]=dim[key],changed=!0);changed&&this.dimensions.ver++}applyMapSize(){this.container.style.width=this.dimensions.width+`px`,this.container.style.height=this.dimensions.height+`px`,this.svg.setViewBox(`0 0 ${this.dimensions.width} ${this.dimensions.height}`);let width$1=this.dimensions.width,height$1=this.dimensions.height;this.canvas.style.width=this.wrapper.style.width=width$1+`px`,this.canvas.style.height=this.wrapper.style.height=height$1+`px`,this.canvas.width=width$1,this.canvas.height=height$1,this.rendered.terrainCtx.clearRect(0,0,this.rendered.terrainCvs.width,this.rendered.terrainCvs.height),this.rendered.terrainCvs.width=width$1,this.rendered.terrainCvs.height=height$1,this.rendered.roadsCtx.clearRect(0,0,this.rendered.roadsCvs.width,this.rendered.roadsCvs.height),this.rendered.roadsCvs.width=width$1,this.rendered.roadsCvs.height=height$1}addRenderSource(source){if(typeof source!=`object`&&!(`source`in source))return console.error(`Navigator: Render source is invalid`);this.renders.push(source)}render(passive=!1){if(!passive)return;let ctx=this.canvasCtx,full=[0,0,this.dimensions.width,this.dimensions.height];ctx.clearRect(...full);for(let src of this.renders){if(!!src.passive!==passive||src.source.width===0||src.source.height===0)continue;let region=src.region;if(src.render){let res=src.render();typeof res==`object`&&`empty`in res&&(region={full:res,fullArray:[res.x1,res.y1,res.x2-res.x1,res.y2-res.y1]})}let pos=src.pos;pos||=(pos=region&&!region.full.empty?region.fullArray:full,[...pos,...pos]),src.alpha&&(ctx.globalAlpha=src.alpha),ctx.drawImage(src.source,...pos),ctx.globalAlpha=1}}renderMap(data){for(let key in this.drawTerrain(data,this.rendered.terrainCtx),data.nodes){let el=data.nodes[key];if(el.links)for(let key2 in el.links)el.links[key2].drivability=Math.round(el.links[key2].drivability*10)/10}this.drawRoads(data.nodes,0,.1,this.roadColors[2],this.rendered.roadsCtx),this.drawRoads(data.nodes,.1,.9,this.roadColors[1],this.rendered.roadsCtx),this.drawRoads(data.nodes,.9,1,this.roadColors[0],this.rendered.roadsCtx),this.render(!0)}drawTerrain(data,ctx){for(let x=this.gridGap;x{ctx.clearRect(...dest),ctx.drawImage(img,0,0,img.width,img.height,...dest),loading--,loading===0&&this.render(!0)}),img.addEventListener(`error`,()=>{console.error(`Navigator: Unable to load tile "${tile.file}"`),loading--,loading===0&&this.render(!0)}),img.src=tile.file}}createLine(ctx,p1,p2,color){Math.abs(p1.radius-p2.radius)>.2?this.varLine(ctx,p1.x,p1.y,p2.x,p2.y,p1.radius,p2.radius,color):(ctx.beginPath(),ctx.lineWidth=Math.max(p1.radius,p2.radius),ctx.lineCap=`round`,ctx.strokeStyle=color,ctx.moveTo(p1.x,p1.y),ctx.lineTo(p2.x,p2.y),ctx.stroke())}varLine(ctx,x1,y1,x2,y2,w1,w2,color){let dx=x2-x1,dy=y2-y1,length=dx*dx+dy*dy;if(length==0)return;length=Math.sqrt(length),w1*=.5,w2*=.5,dx/=length,dy/=length;let shiftx=-dy*w1,shifty=dx*w1;ctx.beginPath(),ctx.fillStyle=color,ctx.moveTo(x1+shiftx,y1+shifty),ctx.lineTo(x1-shiftx,y1-shifty),shiftx=-dy*w2,shifty=dx*w2,ctx.lineTo(x2-shiftx,y2-shifty),ctx.lineTo(x2+shiftx,y2+shifty),ctx.closePath(),ctx.arc(x1,y1,w1,0,2*Math.PI),ctx.arc(x2,y2,w2,0,2*Math.PI),ctx.fill()}drawRoads(nodes,drivabilityMin,drivabilityMax,colour,ctx){for(let key in nodes){let el=nodes[key];if(el.links)for(let key2 in el.links){let drivability=el.links[key2].drivability;if(drivabilitydrivabilityMax)continue;let el2=nodes[key2];this.createLine(ctx,{x:el.pos[0]/this.dimensions.scale*this.dimensions.resScale+this.dimensions.centerX,y:-el.pos[1]/this.dimensions.scale*this.dimensions.resScale+this.dimensions.centerY,radius:Math.min(Math.max(el.radius,0),5)*3*this.dimensions.resScale},{x:el2.pos[0]/this.dimensions.scale*this.dimensions.resScale+this.dimensions.centerX,y:-el2.pos[1]/this.dimensions.scale*this.dimensions.resScale+this.dimensions.centerY,radius:Math.min(Math.max(el2.radius,0),5)*3*this.dimensions.resScale},colour)}}}update(){let pos={x:-this.state.offsetX+this.offsetX,y:-this.state.offsetY+this.offsetY},rot={x:0,z:0};this.speedOffset>0&&(pos.y+=this.state.speedZoom*this.speedOffset),this.rotate&&(rot.x=this.pitch,this.speedPitch>0&&(rot.x+=this.speedPitch*this.state.speedZoom),rot.z=this.state.rotation);let scale=this.state.scale/this.dimensions.resScale;this.speedZoom&&(scale-=this.state.speedZoom*.1/this.dimensions.resScale),this.container.style.transform=`translate3d(${pos.x}px, ${pos.y}px, 0px) rotateX(${rot.x}deg) rotateZ(${rot.z}deg) scale(${scale})`}},bngNavLayerRoute=class{static name=`route`;dimensions;scale=1/3;lineWidth=10;color;wrapper;canvas;canvasCtx;current=null;static canInit(elms$4,opts){return!!opts.routes}constructor({routes,svg},opts,dimensions){this.name=this.constructor.name,[this.wrapper,this.canvas,this.canvasCtx]=routes||svg.createCanvas(opts.resolution),this.dimensions=dimensions,this.setOptions(opts)}setOptions(opts){this.color=opts.routeColor}update(data){if(this.dimver!==this.dimensions.ver){this.dimver=this.dimensions.ver;let width$1=this.dimensions.width,height$1=this.dimensions.height;this.canvas.style.width=this.wrapper.style.width=width$1+`px`,this.canvas.style.height=this.wrapper.style.height=height$1+`px`,this.canvas.width=this.canvasCtx.width=width$1*this.scale,this.canvas.height=this.canvasCtx.height=height$1*this.scale}if(!data||!data.markers){this.clear();return}this.current?this.optimiseAndDrawRoute(data,this.current):(this.clear(),data&&this.drawFreshRoute(data)),this.current=data.markers}clear(){this.current=null,this.canvasCtx.clearRect(0,0,this.canvas.width,this.canvas.height),this.canvasCtx.stroke()}drawFreshRoute(data){this.drawRoute({color:data.color,lineWidth:this.lineWidth,lineCap:`butt`,markers:data.markers,startIndex:0,drawFromIndex:2,drawToIndex:data.markers.length})}optimiseAndDrawRoute(data,prevMarkers){let markers$1=data.markers,ci=markers$1.length-2,pi=prevMarkers.length-2;for(;pi>=0&&ci>=0&&!(markers$1[ci]!==prevMarkers[pi]||markers$1[ci+1]!==prevMarkers[pi+1]);)ci-=2,pi-=2;(ci>=0||pi>=0)&&(this.canvasCtx.globalCompositeOperation=`destination-out`,this.drawRoute({color:data.color,lineWidth:this.lineWidth+2,markers:prevMarkers,drawToIndex:Math.min(pi+4,prevMarkers.length)}),this.canvasCtx.globalCompositeOperation=`source-over`,this.drawRoute({color:data.color,lineWidth:this.lineWidth,markers:data.markers,drawToIndex:Math.min(ci+6,data.markers.length)}))}drawRoute({color,lineWidth,lineCap=`round`,markers:markers$1,startIndex=0,drawFromIndex=0,drawToIndex}){let mapFac=this.scale/this.dimensions.scale,cx=this.dimensions.centerX*mapFac,cy=this.dimensions.centerY*mapFac;this.canvasCtx.beginPath(),this.canvasCtx.strokeStyle=color||this.color,this.canvasCtx.lineWidth=lineWidth*this.scale*this.dimensions.resScale,this.canvasCtx.lineCap=lineCap,this.canvasCtx.moveTo(markers$1[startIndex]*this.dimensions.resScale*mapFac+cx,-markers$1[startIndex+1]*this.dimensions.resScale*mapFac+cy);for(let i=drawFromIndex;iargs.map(arg=>typeof arg==`string`?arg:`[object]`)},createElementNS:{base:Document,getArgs:(...args)=>args.map(arg=>typeof arg==`string`?arg:`[object]`)},cloneNode:{base:Node,getArgs:deep=>[deep]},importNode:{base:Document,getArgs:(node,deep)=>[`[node]`,deep]},insertAdjacentHTML:{base:Element,getArgs:(position,text)=>[position,`[HTML:${text.length}chars]`]},innerHTML:{isSetter:!0,bases:[Element,HTMLElement],getArgs:value=>[`[HTML:${typeof value==`string`?value.length:0}chars]`]},outerHTML:{isSetter:!0,bases:[Element,HTMLElement],getArgs:value=>[`[HTML:${typeof value==`string`?value.length:0}chars]`]},appendChild:{base:Node,stats:`append`,getArgs:child=>[`[${child?.tagName||child?.nodeName||`node`}]`]},insertBefore:{base:Node,stats:`append`,getArgs:(newNode,referenceNode)=>[`[${newNode?.tagName||newNode?.nodeName||`node`}]`,`[${referenceNode?.tagName||referenceNode?.nodeName||`ref`}]`]},replaceChild:{base:Node,stats:`append`,getArgs:(newChild,oldChild)=>[`[${newChild?.tagName||newChild?.nodeName||`new`}]`,`[${oldChild?.tagName||oldChild?.nodeName||`old`}]`]},append:{base:Element,stats:`append`,getArgs:(...nodes)=>nodes.map(node=>`[${node?.tagName||node?.nodeName||typeof node==`string`?`text`:`node`}]`)},prepend:{base:Element,stats:`append`,getArgs:(...nodes)=>nodes.map(node=>`[${node?.tagName||node?.nodeName||typeof node==`string`?`text`:`node`}]`)},before:{base:Element,stats:`append`,getArgs:(...nodes)=>nodes.map(node=>`[${node?.tagName||node?.nodeName||typeof node==`string`?`text`:`node`}]`)},after:{base:Element,stats:`append`,getArgs:(...nodes)=>nodes.map(node=>`[${node?.tagName||node?.nodeName||typeof node==`string`?`text`:`node`}]`)}};function setupInterceptor(type){let interceptor=interceptors[type];if(interceptor.isSetter){let descriptor;if(interceptor.bases){for(let base of interceptor.bases)if(descriptor=Object.getOwnPropertyDescriptor(base.prototype,type),descriptor){interceptor.base=base;break}}descriptor&&(interceptor.original=descriptor)}else interceptor.original=interceptor.base.prototype[type];if(!interceptor.original){logger_default.warn(`No original for ${type}`);return}interceptor.call=(self$1,...args)=>{let stackTrace=captureStackTrace();if(stackTrace&&(includeAnonymousCalls||!stackTrace.hasAnonymous||stackTrace.filePaths.length>0)){let callData={type,timestamp:Date.now(),args:interceptor.getArgs(...args),stackTrace};if(interceptor.stats===`append`&&self$1)try{let mainContainer=self$1.closest?self$1.closest(`#mainContainer_apps`):null;if(mainContainer){let directChildDiv=self$1;for(;directChildDiv&&directChildDiv.parentNode&&directChildDiv.parentNode!==mainContainer;)directChildDiv=directChildDiv.parentNode;directChildDiv&&directChildDiv.parentNode===mainContainer&&directChildDiv.tagName===`DIV`&&(callData.uiAppInsertion={targetElement:directChildDiv})}}catch{}callQueue.push(callData)}if(interceptor.isSetter)interceptor.original.set.call(self$1,args[0]);else return interceptor.original.apply(self$1,args)},interceptor.isSetter?Object.defineProperty(interceptor.base.prototype,type,{get:interceptor.original.get,set:function(value){interceptor.call(this,value)},configurable:!0,enumerable:!0}):interceptor.base.prototype[type]=function(...args){return interceptor.call(this,...args)},interceptor.restore=()=>{interceptor.isSetter?Object.defineProperty(interceptor.base.prototype,type,{get:interceptor.original.get,set:interceptor.original.set,configurable:!0,enumerable:!0}):interceptor.base.prototype[type]=interceptor.original}}function captureStackTrace(){let stack$2=Error().stack;if(!stack$2)return null;let relevantLines=stack$2.split(` `).slice(STACK_TRACE_SKIP_LINES),filePaths=[],hasAnonymous=!1;for(let line of relevantLines){let match=line.match(STACK_TRACE_REGEX_FULL),functionName,filePath,lineNum,column;if(match)functionName=match[1],filePath=match[2],lineNum=match[3],column=match[4];else if(match=line.match(STACK_TRACE_REGEX),match)functionName=`anonymous`,filePath=match[1],lineNum=match[2],column=match[3];else continue;let isAnonymous=functionName?.includes(`anonymous`)||functionName?.includes(``)||!functionName||functionName.trim()===``;isAnonymous&&(hasAnonymous=!0,!includeAnonymousCalls)||filePaths.push({functionName,filePath,line:lineNum,column,isAnonymous})}return{filePaths,fullStack:stack$2,hasAnonymous}}async function processCallQueue(){if(statsProcessor.lastProcessTime=Date.now(),!(statsProcessor.isProcessing||callQueue.length===0)){statsProcessor.isProcessing=!0;try{let batch$1=callQueue.splice(0,Math.max(statsProcessor.batchSize,callQueue.length/5));statsProcessor.totalProcessed+=batch$1.length;for(let i=0;i{try{processCallQueue()}catch(error){logger_default.error(`Fatal error in DOM watchdog processing:`,error),destroy()}},statsProcessor.processInterval)}function getStats(){return{files:Object.fromEntries(statsProcessor.files),types:Object.fromEntries(statsProcessor.types),append:Object.fromEntries(statsProcessor.append)}}function clearStats(){statsProcessor.files.clear(),statsProcessor.types.clear(),statsProcessor.append.clear(),statsProcessor.uiApps.clear(),callQueue.length=0,statsProcessor.totalProcessed=0,statsProcessor.lastProcessTime=0,overlayActive&&updateOverlayDivs()}function restartTimer(){isInitialized&&startStatsProcessor()}function setIncludeAnonymousCalls(include){includeAnonymousCalls=include}var exposedFunctions=()=>({watchdogRecentCalls:getRecentCalls,watchdogCallChainStats:getCallChainStats,watchdogClearStats:clearStats,watchdogSetIncludeAnonymousCalls:setIncludeAnonymousCalls,watchdogDestroy:destroy,watchdogRestartTimer:restartTimer,watchdogUIAppsStats:getUIAppsStats,watchdogRefreshOverlay:refreshOverlay,watchdogStats:()=>{let stats=getStats(),format$2=obj=>Object.entries(obj).sort((a$1,b)=>b[1]-a$1[1]).map(([key,value])=>`${key}: ${value}`.replace(`\\`,`\\\\`)).join(`
  • `+b).split(R[0]).slice(1).map(R[3]?escape:inlineEscape).join(R[3]||`
    
  • `)+R[2]:f===`#`?``+inlineEscape(b.slice(f+1))+``:f===`<`?b:`

    `+inlineEscape(b)+`

    `}),h$1}function escape(t){return new Option(t).innerHTML}function inlineEscape(s){return escape(s).replace(/\\_/g,`⋿`).replace(/!\[([^\]]*)]\(([^(]+)\)/g,`$1`).replace(/\[([^\]]+)]\(([^(]+?)\)/g,`$1`.link(`$2`)).replace(/`([^`]+)`/g,`$1`).replace(/(\*\*|__)(?=\S)([^\r]*?\S[*_]*)\1/g,`$2`).replace(/(\*| _)(?=\S)([^\r]*?\S)\1/g,`$2`).replace(/⋿/g,`_`)}var content_exports=__export({bbcode:()=>bbcode_exports,markdown:()=>markdown_exports});const screenLocked=computed(()=>screenLockedState.value),loadingScreen=reactive({active:!1,visible:!1,fading:!1,shown:!1});var screenLockedState=ref(!1),loadingScreenStateWatcher=null,events;function screenLock(lock=!1){lock=!!lock,screenLockedState.value=lock;let body=document.body;body&&body.classList.toggle(`screen-locked`,lock)}async function startLoading$1(func){screenLock(!0),events||=useBridge().events,events.emit(`LoadingScreen`,{active:!0}),await nextTick(),setTimeout(()=>func(),500)}function linkLoadingScreenState(state){loadingScreenStateWatcher?.(),loadingScreenStateWatcher=watch([()=>state.active,()=>state.visible,()=>state.fading,()=>state.shown],([active,visible,fading,shown])=>{loadingScreen.active=active,loadingScreen.visible=visible,loadingScreen.fading=fading,loadingScreen.shown=shown,screenLock(active)})}function waitForLoadingScreenFadeIn$1(timeout=4e3){if(loadingScreen.visible&&!loadingScreen.fading)return;let fadeInPromise=new Promise(resolve$1=>{let unwatch=watch([()=>loadingScreen.visible,()=>loadingScreen.fading],([visible,fading])=>{visible&&!fading&&(unwatch(),resolve$1())},{immediate:!0})});return Promise.race([fadeInPromise,sleep(timeout)])}var bngNavigator=class{opts={root:null,container:null,bootscreen:null,north:null,clock:null,backgroundRgb:[50,50,50],roadColors:[`#FFFFFFFF`,`#A6A678FF`,`#A67854FF`],routeColor:`#3388EEFF`,markerColor:`#2C5CFF`,routes:!1,markers:!1,vehicles:!1,vehicleMarker:null,cameraColor:`#FD6A00`,vehicleColor:`#A3D39C`,rotate:!0,scale:1,pitch:0,offsetX:128,offsetY:64,resolution:4096,speedZoom:!1,speedOffset:0,speedPitch:!0,speedZoomIncrements:1,speedZoomMultiplier:2,speedZoomMax:200,speedZoomEffect:.15,hideBootscreen:!1};elms={root:document};mapScale=1;startup=!0;startupFallback=!0;layers={};layersLoadOrder=[bngNavLayerMap,bngNavLayerRoute,bngNavLayerMarkers,bngNavLayerVehicles,bngNavLayerElements,bngNavLayerBootscreen];setOptions(options){if(!(typeof options!=`object`||Array.isArray(options))){for(let key in this.opts)key in options&&(this.opts[key]=options[key]);for(let name in this.layers){let layer=this.layers[name];typeof layer.setOptions==`function`&&layer.setOptions(this.opts)}}}constructor(options){this.setOptions(options);for(let key of[`root`,`container`,`clock`,`north`,`bootscreen`]){let elm;typeof this.opts[key]==`string`?elm=this.elms.root.querySelector(this.opts[key]):this.opts[key]&&(elm=this.opts[key]),elm&&(elm instanceof HTMLElement||elm instanceof SVGElement)&&(this.elms[key]=elm)}if(!this.elms.root)throw Error(`Cannot find map root element`);if(!this.elms.container)throw Error(`Cannot find map container element`);this.elms.svg=new bngNavSVG(this.elms.container.children[0]);for(let cls of this.layersLoadOrder){let elms$4=cls.name===`map`?this.elms:{...this.elms,cvs:this.layers.map.cvs,routes:[this.layers.map.rwrapper,this.layers.map.rcanvas,this.layers.map.rcanvasCtx]};if(cls.canInit(elms$4,this.opts)){let dim=cls.name===`map`?this.mapScale:this.layers.map.dimensions,layer=new cls(elms$4,this.opts,dim);layer&&layer.name&&(this.layers[layer.name]=layer)}}this.layersLoadOrder=null;let expose=(layer,method,name=null)=>{this[name||method]=layer?layer[method].bind(layer):()=>{}};expose(this.layers.map,`setRotation`),expose(this.layers.map,`setLocation`),expose(this.layers.map,`setZoom`),expose(this.layers.map,`setScale`),expose(this.layers.map,`setSpeed`),expose(this.layers.map,`setOpacity`),expose(this.layers.route,`update`,`setRoute`),expose(this.layers.markers,`update`,`setMarkers`),expose(this.layers.bootscreen,`setImage`,`setBootscreenImage`)}update(data){data&&this.setup(data),this.layers.map.update(),this.layers.elements&&this.layers.elements.update(this.layers.map.state),this.layers.map.render()}setup(data){typeof data.terrainTiles==`object`&&!Array.isArray(data.terrainTiles)&&(data.terrainTiles=[]),this.layers.map.setMapSize(data)&&this.startupFallback?(this.startupFallback=!1,this.startup=!0):this.startup||(this.startupFallback=!0),this.startup&&(this.startup=!1,this.layers.map.applyMapSize(),this.layers.map.renderMap(data))}setData(data){if(!data||Object.keys(data).length===0){console.log(`Received empty map data`);return}this.layers.vehicles&&this.layers.vehicles.update(data),this.update(data),this.opts.hideBootscreen&&this.layers.bootscreen&&this.layers.bootscreen.hide()}updateData(data){typeof data==`object`&&(`x`in data&&`y`in data&&this.layers.map.setLocation(data.x,data.y,!1),`rotation`in data&&this.layers.map.setRotation(data.rotation,!1),`speed`in data&&this.layers.map.setSpeed(data.speed,!1),`ignitionLevel`in data&&this.layers.bootscreen&&this.layers.bootscreen.toggle(data.ignitionLevel<2),this.update())}},bngNavUtils=class{static truncDec(num,dec=2){let d=10**dec;return~~(num*d)/d}static setStyle(node,style){for(let name in style)node.style[name]=style[name]}},bngNavSVG=class{ns={svg:`http://www.w3.org/2000/svg`,xlink:`http://www.w3.org/1999/xlink`};root;constructor(root){if(!root||!root.tagName||root.tagName.toLowerCase()!==`svg`)throw Error(`Cannot access svg in a container`);this.root=root}setViewBox(viewBox){this.root.setAttributeNS(null,`viewBox`,viewBox)}createNode(tag,...args){let[attrs,parent]=args;parent||(attrs&&attrs instanceof SVGElement?(parent=attrs,attrs=null):parent=this.root);let node=document.createElementNS(this.ns.svg,tag);return attrs&&this.setAttrs(node,attrs),parent.appendChild(node),node}removeNode(node){node&&node.parentNode&&node.parentNode.removeChild(node)}setAttrs(node,attrs){for(let name in attrs){let ns=name.startsWith(`xlink:`)?this.ns.xlink:null;node.setAttributeNS(ns,name,attrs[name])}}clearNode(node){let elm;for(;elm=node.children[0];)node.removeChild(elm)}setStyle=bngNavUtils.setStyle;createCanvas(resolution){let fo=this.createNode(`foreignObject`);this.setStyle(fo,{position:`absolute`,x:`0`,y:`0`,width:`100%`,height:`100%`});let cvs=document.createElement(`canvas`);return cvs.width=resolution,cvs.height=resolution,fo.appendChild(cvs),[fo,cvs,cvs.getContext(`2d`)]}},bngNavLayerMap=class{static name=`map`;dimensions={ver:0,offset:512,scale:1,centerX:1024,centerY:1024,width:2048,height:2048,resScale:1};state={x:0,y:0,speed:0,scale:1,zoom:1,speedZoom:0,rotation:0,focusX:0,focusY:0,offsetX:0,offsetY:0};container;svg;wrapper;canvas;canvasCtx;rwrapper;rcanvas;rcanvasCtx;cvs;renders=[];rendered={terrainCvs:null,terrainCtx:null,roadsCvs:null,roadsCtx:null};terrainOpacity=1;gridGap=50;gridColour=`#cccccccc`;roadColors;resolution=2048;offsetX;offsetY;rotate;scale;pitch;speedPitch;speedOffset;speedZoom;speedZoomIncrements;speedZoomMultiplier;speedZoomMax;speedZoomEffect;static canInit(elms$4,opts){return!0}constructor({container,svg},opts,mapScale){this.name=this.constructor.name,this.container=container,this.svg=svg,[this.wrapper,this.canvas,this.canvasCtx]=svg.createCanvas(opts.resolution),[this.rwrapper,this.rcanvas,this.rcanvasCtx]=svg.createCanvas(opts.resolution);let that=this;this.rendered.terrainCvs=window.OffscreenCanvas?new window.OffscreenCanvas(1,1):document.createElement(`canvas`),this.rendered.terrainCtx=this.rendered.terrainCvs.getContext(`2d`),this.addRenderSource({passive:!0,source:this.rendered.terrainCvs,get alpha(){return that.terrainOpacity}}),this.rendered.roadsCvs=window.OffscreenCanvas?new window.OffscreenCanvas(1,1):document.createElement(`canvas`),this.rendered.roadsCtx=this.rendered.roadsCvs.getContext(`2d`),this.addRenderSource({passive:!0,source:this.rendered.roadsCvs}),this.dimensions.scale=mapScale,this.setOptions(opts),this.setOpacity(1)}setOptions(opts){this.bgRgb=opts.backgroundRgb.join(`, `),this.roadColors=opts.roadColors,this.resolution=opts.resolution,this.offsetX=opts.offsetX,this.offsetY=opts.offsetY,this.rotate=opts.rotate,this.scale=opts.scale,this.state.scale=this.scale*this.state.zoom,this.pitch=opts.pitch,this.speedPitch=opts.speedPitch,this.speedOffset=opts.speedOffset,this.speedZoom=opts.speedZoom,this.speedZoomIncrements=opts.speedZoomIncrements,this.speedZoomMultiplier=opts.speedZoomMultiplier,this.speedZoomMax=opts.speedZoomMax,this.speedZoomEffect=opts.speedZoomEffect}setLocation(x,y,doupdate=!0){this.state.x=-x,this.state.y=y,this.state.focusX=~~(this.state.x/this.dimensions.scale*this.dimensions.resScale),this.state.focusY=~~(this.state.y/this.dimensions.scale*this.dimensions.resScale),this.state.offsetX=this.dimensions.centerX-this.state.focusX,this.state.offsetY=this.dimensions.centerY-this.state.focusY,this.container.style.transformOrigin=`${this.state.offsetX}px ${this.state.offsetY}px`}setRotation(rotation,doupdate=!0){this.state.rotation=bngNavUtils.truncDec(rotation,3)%360,doupdate&&this.update()}setZoom(zoom,doupdate=!0){let fixed=(zoom-150)*2;this.setSpeed(fixed)}setScale(zoom,doupdate=!0){this.state.zoom=zoom,this.state.scale=this.scale*zoom}setSpeed(speed){this.state.speed=bngNavUtils.truncDec(speed,3),this.state.speed===0?this.state.speedZoom=0:this.state.speedZoom=bngNavUtils.truncDec(Math.min(1+this.state.speed*3.6*1.5,this.speedZoomMax)/this.speedZoomIncrements*this.speedZoomIncrements/this.speedZoomMax,3)}setOpacity(opacity){this.canvas.style.backgroundColor=`rgba(${this.bgRgb}, ${opacity})`,this.terrainOpacity=opacity}setMapSize(data){let res;return data.terrainTiles&&data.terrainTiles[0]&&data.terrainTiles[0].size?(this.setMapDimensions(data),res=!0):this.dimensions.ver===0&&(this.setMapDimensions(data),res=!1),res}setMapDimensions(data){let poss=[],tiles=data.terrainTiles||[];for(let tile of tiles)poss.push([tile.offset[0],-tile.offset[1]],[tile.offset[0]+tile.size[0],-tile.offset[1]+tile.size[1]]);for(let key in data.nodes)poss.push([data.nodes[key].pos[0],-data.nodes[key].pos[1]]);let minX=1/0,maxX=-1/0,minY=1/0,maxY=-1/0;for(let pos of poss)pos[0]/=this.dimensions.scale,pos[1]/=this.dimensions.scale,pos[0]maxX&&(maxX=pos[0]),pos[1]maxY&&(maxY=pos[1]);let dim={centerX:-minX,centerY:-minY,width:-minX+maxX,height:-minY+maxY};if((dim.centerX<0||dim.centerY<0)&&((isFinite(dim.centerX)||isFinite(dim.centerY))&&console.error(`Navigator: Invalid center point detected.`),dim.centerX=this.resolution/2,dim.centerY=this.resolution/2,dim.width=this.resolution,dim.height=this.resolution),this.dimensions.offset>0){let off=this.dimensions.offset;dim.centerX+=off,dim.width+=off*2,dim.centerY+=off,dim.height+=off*2}for(let key in dim.width>this.resolution||dim.height>this.resolution?(dim.resScale=this.resolution/(dim.width>dim.height?dim.width:dim.height),dim.width*=dim.resScale,dim.height*=dim.resScale,dim.centerX*=dim.resScale,dim.centerY*=dim.resScale,dim.offset=dim.offset>0?dim.offset/dim.resScale:0):dim.resScale=1,dim)key!==`resScale`&&(dim[key]=Math.round(dim[key]));let changed=!1;for(let key in dim)this.dimensions[key]!==dim[key]&&(this.dimensions[key]=dim[key],changed=!0);changed&&this.dimensions.ver++}applyMapSize(){this.container.style.width=this.dimensions.width+`px`,this.container.style.height=this.dimensions.height+`px`,this.svg.setViewBox(`0 0 ${this.dimensions.width} ${this.dimensions.height}`);let width$1=this.dimensions.width,height$1=this.dimensions.height;this.canvas.style.width=this.wrapper.style.width=width$1+`px`,this.canvas.style.height=this.wrapper.style.height=height$1+`px`,this.canvas.width=width$1,this.canvas.height=height$1,this.rendered.terrainCtx.clearRect(0,0,this.rendered.terrainCvs.width,this.rendered.terrainCvs.height),this.rendered.terrainCvs.width=width$1,this.rendered.terrainCvs.height=height$1,this.rendered.roadsCtx.clearRect(0,0,this.rendered.roadsCvs.width,this.rendered.roadsCvs.height),this.rendered.roadsCvs.width=width$1,this.rendered.roadsCvs.height=height$1}addRenderSource(source){if(typeof source!=`object`&&!(`source`in source))return console.error(`Navigator: Render source is invalid`);this.renders.push(source)}render(passive=!1){if(!passive)return;let ctx=this.canvasCtx,full=[0,0,this.dimensions.width,this.dimensions.height];ctx.clearRect(...full);for(let src of this.renders){if(!!src.passive!==passive||src.source.width===0||src.source.height===0)continue;let region=src.region;if(src.render){let res=src.render();typeof res==`object`&&`empty`in res&&(region={full:res,fullArray:[res.x1,res.y1,res.x2-res.x1,res.y2-res.y1]})}let pos=src.pos;pos||=(pos=region&&!region.full.empty?region.fullArray:full,[...pos,...pos]),src.alpha&&(ctx.globalAlpha=src.alpha),ctx.drawImage(src.source,...pos),ctx.globalAlpha=1}}renderMap(data){for(let key in this.drawTerrain(data,this.rendered.terrainCtx),data.nodes){let el=data.nodes[key];if(el.links)for(let key2 in el.links)el.links[key2].drivability=Math.round(el.links[key2].drivability*10)/10}this.drawRoads(data.nodes,0,.1,this.roadColors[2],this.rendered.roadsCtx),this.drawRoads(data.nodes,.1,.9,this.roadColors[1],this.rendered.roadsCtx),this.drawRoads(data.nodes,.9,1,this.roadColors[0],this.rendered.roadsCtx),this.render(!0)}drawTerrain(data,ctx){for(let x=this.gridGap;x{ctx.clearRect(...dest),ctx.drawImage(img,0,0,img.width,img.height,...dest),loading--,loading===0&&this.render(!0)}),img.addEventListener(`error`,()=>{console.error(`Navigator: Unable to load tile "${tile.file}"`),loading--,loading===0&&this.render(!0)}),img.src=tile.file}}createLine(ctx,p1,p2,color){Math.abs(p1.radius-p2.radius)>.2?this.varLine(ctx,p1.x,p1.y,p2.x,p2.y,p1.radius,p2.radius,color):(ctx.beginPath(),ctx.lineWidth=Math.max(p1.radius,p2.radius),ctx.lineCap=`round`,ctx.strokeStyle=color,ctx.moveTo(p1.x,p1.y),ctx.lineTo(p2.x,p2.y),ctx.stroke())}varLine(ctx,x1,y1,x2,y2,w1,w2,color){let dx=x2-x1,dy=y2-y1,length=dx*dx+dy*dy;if(length==0)return;length=Math.sqrt(length),w1*=.5,w2*=.5,dx/=length,dy/=length;let shiftx=-dy*w1,shifty=dx*w1;ctx.beginPath(),ctx.fillStyle=color,ctx.moveTo(x1+shiftx,y1+shifty),ctx.lineTo(x1-shiftx,y1-shifty),shiftx=-dy*w2,shifty=dx*w2,ctx.lineTo(x2-shiftx,y2-shifty),ctx.lineTo(x2+shiftx,y2+shifty),ctx.closePath(),ctx.arc(x1,y1,w1,0,2*Math.PI),ctx.arc(x2,y2,w2,0,2*Math.PI),ctx.fill()}drawRoads(nodes,drivabilityMin,drivabilityMax,colour,ctx){for(let key in nodes){let el=nodes[key];if(el.links)for(let key2 in el.links){let drivability=el.links[key2].drivability;if(drivabilitydrivabilityMax)continue;let el2=nodes[key2];this.createLine(ctx,{x:el.pos[0]/this.dimensions.scale*this.dimensions.resScale+this.dimensions.centerX,y:-el.pos[1]/this.dimensions.scale*this.dimensions.resScale+this.dimensions.centerY,radius:Math.min(Math.max(el.radius,0),5)*3*this.dimensions.resScale},{x:el2.pos[0]/this.dimensions.scale*this.dimensions.resScale+this.dimensions.centerX,y:-el2.pos[1]/this.dimensions.scale*this.dimensions.resScale+this.dimensions.centerY,radius:Math.min(Math.max(el2.radius,0),5)*3*this.dimensions.resScale},colour)}}}update(){let pos={x:-this.state.offsetX+this.offsetX,y:-this.state.offsetY+this.offsetY},rot={x:0,z:0};this.speedOffset>0&&(pos.y+=this.state.speedZoom*this.speedOffset),this.rotate&&(rot.x=this.pitch,this.speedPitch>0&&(rot.x+=this.speedPitch*this.state.speedZoom),rot.z=this.state.rotation);let scale=this.state.scale/this.dimensions.resScale;this.speedZoom&&(scale-=this.state.speedZoom*.1/this.dimensions.resScale),this.container.style.transform=`translate3d(${pos.x}px, ${pos.y}px, 0px) rotateX(${rot.x}deg) rotateZ(${rot.z}deg) scale(${scale})`}},bngNavLayerRoute=class{static name=`route`;dimensions;scale=1/3;lineWidth=10;color;wrapper;canvas;canvasCtx;current=null;static canInit(elms$4,opts){return!!opts.routes}constructor({routes,svg},opts,dimensions){this.name=this.constructor.name,[this.wrapper,this.canvas,this.canvasCtx]=routes||svg.createCanvas(opts.resolution),this.dimensions=dimensions,this.setOptions(opts)}setOptions(opts){this.color=opts.routeColor}update(data){if(this.dimver!==this.dimensions.ver){this.dimver=this.dimensions.ver;let width$1=this.dimensions.width,height$1=this.dimensions.height;this.canvas.style.width=this.wrapper.style.width=width$1+`px`,this.canvas.style.height=this.wrapper.style.height=height$1+`px`,this.canvas.width=this.canvasCtx.width=width$1*this.scale,this.canvas.height=this.canvasCtx.height=height$1*this.scale}if(!data||!data.markers){this.clear();return}this.current?this.optimiseAndDrawRoute(data,this.current):(this.clear(),data&&this.drawFreshRoute(data)),this.current=data.markers}clear(){this.current=null,this.canvasCtx.clearRect(0,0,this.canvas.width,this.canvas.height),this.canvasCtx.stroke()}drawFreshRoute(data){this.drawRoute({color:data.color,lineWidth:this.lineWidth,lineCap:`butt`,markers:data.markers,startIndex:0,drawFromIndex:2,drawToIndex:data.markers.length})}optimiseAndDrawRoute(data,prevMarkers){let markers$1=data.markers,ci=markers$1.length-2,pi=prevMarkers.length-2;for(;pi>=0&&ci>=0&&!(markers$1[ci]!==prevMarkers[pi]||markers$1[ci+1]!==prevMarkers[pi+1]);)ci-=2,pi-=2;(ci>=0||pi>=0)&&(this.canvasCtx.globalCompositeOperation=`destination-out`,this.drawRoute({color:data.color,lineWidth:this.lineWidth+2,markers:prevMarkers,drawToIndex:Math.min(pi+4,prevMarkers.length)}),this.canvasCtx.globalCompositeOperation=`source-over`,this.drawRoute({color:data.color,lineWidth:this.lineWidth,markers:data.markers,drawToIndex:Math.min(ci+6,data.markers.length)}))}drawRoute({color,lineWidth,lineCap=`round`,markers:markers$1,startIndex=0,drawFromIndex=0,drawToIndex}){let mapFac=this.scale/this.dimensions.scale,cx=this.dimensions.centerX*mapFac,cy=this.dimensions.centerY*mapFac;this.canvasCtx.beginPath(),this.canvasCtx.strokeStyle=color||this.color,this.canvasCtx.lineWidth=lineWidth*this.scale*this.dimensions.resScale,this.canvasCtx.lineCap=lineCap,this.canvasCtx.moveTo(markers$1[startIndex]*this.dimensions.resScale*mapFac+cx,-markers$1[startIndex+1]*this.dimensions.resScale*mapFac+cy);for(let i=drawFromIndex;iargs.map(arg=>typeof arg==`string`?arg:`[object]`)},createElementNS:{base:Document,getArgs:(...args)=>args.map(arg=>typeof arg==`string`?arg:`[object]`)},cloneNode:{base:Node,getArgs:deep=>[deep]},importNode:{base:Document,getArgs:(node,deep)=>[`[node]`,deep]},insertAdjacentHTML:{base:Element,getArgs:(position,text)=>[position,`[HTML:${text.length}chars]`]},innerHTML:{isSetter:!0,bases:[Element,HTMLElement],getArgs:value=>[`[HTML:${typeof value==`string`?value.length:0}chars]`]},outerHTML:{isSetter:!0,bases:[Element,HTMLElement],getArgs:value=>[`[HTML:${typeof value==`string`?value.length:0}chars]`]},appendChild:{base:Node,stats:`append`,getArgs:child=>[`[${child?.tagName||child?.nodeName||`node`}]`]},insertBefore:{base:Node,stats:`append`,getArgs:(newNode,referenceNode)=>[`[${newNode?.tagName||newNode?.nodeName||`node`}]`,`[${referenceNode?.tagName||referenceNode?.nodeName||`ref`}]`]},replaceChild:{base:Node,stats:`append`,getArgs:(newChild,oldChild)=>[`[${newChild?.tagName||newChild?.nodeName||`new`}]`,`[${oldChild?.tagName||oldChild?.nodeName||`old`}]`]},append:{base:Element,stats:`append`,getArgs:(...nodes)=>nodes.map(node=>`[${node?.tagName||node?.nodeName||typeof node==`string`?`text`:`node`}]`)},prepend:{base:Element,stats:`append`,getArgs:(...nodes)=>nodes.map(node=>`[${node?.tagName||node?.nodeName||typeof node==`string`?`text`:`node`}]`)},before:{base:Element,stats:`append`,getArgs:(...nodes)=>nodes.map(node=>`[${node?.tagName||node?.nodeName||typeof node==`string`?`text`:`node`}]`)},after:{base:Element,stats:`append`,getArgs:(...nodes)=>nodes.map(node=>`[${node?.tagName||node?.nodeName||typeof node==`string`?`text`:`node`}]`)}};function setupInterceptor(type){let interceptor=interceptors[type];if(interceptor.isSetter){let descriptor;if(interceptor.bases){for(let base of interceptor.bases)if(descriptor=Object.getOwnPropertyDescriptor(base.prototype,type),descriptor){interceptor.base=base;break}}descriptor&&(interceptor.original=descriptor)}else interceptor.original=interceptor.base.prototype[type];if(!interceptor.original){logger_default.warn(`No original for ${type}`);return}interceptor.call=(self$1,...args)=>{let stackTrace=captureStackTrace();if(stackTrace&&(includeAnonymousCalls||!stackTrace.hasAnonymous||stackTrace.filePaths.length>0)){let callData={type,timestamp:Date.now(),args:interceptor.getArgs(...args),stackTrace};if(interceptor.stats===`append`&&self$1)try{let mainContainer=self$1.closest?self$1.closest(`#mainContainer_apps`):null;if(mainContainer){let directChildDiv=self$1;for(;directChildDiv&&directChildDiv.parentNode&&directChildDiv.parentNode!==mainContainer;)directChildDiv=directChildDiv.parentNode;directChildDiv&&directChildDiv.parentNode===mainContainer&&directChildDiv.tagName===`DIV`&&(callData.uiAppInsertion={targetElement:directChildDiv})}}catch{}callQueue.push(callData)}if(interceptor.isSetter)interceptor.original.set.call(self$1,args[0]);else return interceptor.original.apply(self$1,args)},interceptor.isSetter?Object.defineProperty(interceptor.base.prototype,type,{get:interceptor.original.get,set:function(value){interceptor.call(this,value)},configurable:!0,enumerable:!0}):interceptor.base.prototype[type]=function(...args){return interceptor.call(this,...args)},interceptor.restore=()=>{interceptor.isSetter?Object.defineProperty(interceptor.base.prototype,type,{get:interceptor.original.get,set:interceptor.original.set,configurable:!0,enumerable:!0}):interceptor.base.prototype[type]=interceptor.original}}function captureStackTrace(){let stack$2=Error().stack;if(!stack$2)return null;let relevantLines=stack$2.split(` `).slice(STACK_TRACE_SKIP_LINES),filePaths=[],hasAnonymous=!1;for(let line of relevantLines){let match=line.match(STACK_TRACE_REGEX_FULL),functionName,filePath,lineNum,column;if(match)functionName=match[1],filePath=match[2],lineNum=match[3],column=match[4];else if(match=line.match(STACK_TRACE_REGEX),match)functionName=`anonymous`,filePath=match[1],lineNum=match[2],column=match[3];else continue;let isAnonymous=functionName?.includes(`anonymous`)||functionName?.includes(``)||!functionName||functionName.trim()===``;isAnonymous&&(hasAnonymous=!0,!includeAnonymousCalls)||filePaths.push({functionName,filePath,line:lineNum,column,isAnonymous})}return{filePaths,fullStack:stack$2,hasAnonymous}}async function processCallQueue(){if(statsProcessor.lastProcessTime=Date.now(),!(statsProcessor.isProcessing||callQueue.length===0)){statsProcessor.isProcessing=!0;try{let batch$1=callQueue.splice(0,Math.max(statsProcessor.batchSize,callQueue.length/5));statsProcessor.totalProcessed+=batch$1.length;for(let i=0;i{try{processCallQueue()}catch(error){logger_default.error(`Fatal error in DOM watchdog processing:`,error),destroy()}},statsProcessor.processInterval)}function getStats(){return{files:Object.fromEntries(statsProcessor.files),types:Object.fromEntries(statsProcessor.types),append:Object.fromEntries(statsProcessor.append)}}function clearStats(){statsProcessor.files.clear(),statsProcessor.types.clear(),statsProcessor.append.clear(),statsProcessor.uiApps.clear(),callQueue.length=0,statsProcessor.totalProcessed=0,statsProcessor.lastProcessTime=0,overlayActive&&updateOverlayDivs()}function restartTimer(){isInitialized&&startStatsProcessor()}function setIncludeAnonymousCalls(include){includeAnonymousCalls=include}var exposedFunctions=()=>({watchdogRecentCalls:getRecentCalls,watchdogCallChainStats:getCallChainStats,watchdogClearStats:clearStats,watchdogSetIncludeAnonymousCalls:setIncludeAnonymousCalls,watchdogDestroy:destroy,watchdogRestartTimer:restartTimer,watchdogUIAppsStats:getUIAppsStats,watchdogRefreshOverlay:refreshOverlay,watchdogStats:()=>{let stats=getStats(),format$2=obj=>Object.entries(obj).sort((a$1,b)=>b[1]-a$1[1]).map(([key,value])=>`${key}: ${value}`.replace(`\\`,`\\\\`)).join(`
  • `+b).split(R[0]).slice(1).map(R[3]?escape:inlineEscape).join(R[3]||`
    
  • `)+R[2]:f===`#`?``+inlineEscape(b.slice(f+1))+``:f===`<`?b:`

    `+inlineEscape(b)+`

    `}),h$1}function escape(t){return new Option(t).innerHTML}function inlineEscape(s){return escape(s).replace(/\\_/g,`⋿`).replace(/!\[([^\]]*)]\(([^(]+)\)/g,`$1`).replace(/\[([^\]]+)]\(([^(]+?)\)/g,`$1`.link(`$2`)).replace(/`([^`]+)`/g,`$1`).replace(/(\*\*|__)(?=\S)([^\r]*?\S[*_]*)\1/g,`$2`).replace(/(\*| _)(?=\S)([^\r]*?\S)\1/g,`$2`).replace(/⋿/g,`_`)}var content_exports=__export({bbcode:()=>bbcode_exports,markdown:()=>markdown_exports});const screenLocked=computed(()=>screenLockedState.value),loadingScreen=reactive({active:!1,visible:!1,fading:!1,shown:!1});var screenLockedState=ref(!1),loadingScreenStateWatcher=null,events;function screenLock(lock=!1){lock=!!lock,screenLockedState.value=lock;let body=document.body;body&&body.classList.toggle(`screen-locked`,lock)}async function startLoading$1(func){screenLock(!0),events||=useBridge().events,events.emit(`LoadingScreen`,{active:!0}),await nextTick(),setTimeout(()=>func(),500)}function linkLoadingScreenState(state){loadingScreenStateWatcher?.(),loadingScreenStateWatcher=watch([()=>state.active,()=>state.visible,()=>state.fading,()=>state.shown],([active,visible,fading,shown])=>{loadingScreen.active=active,loadingScreen.visible=visible,loadingScreen.fading=fading,loadingScreen.shown=shown,screenLock(active)})}function waitForLoadingScreenFadeIn$1(timeout=4e3){if(loadingScreen.visible&&!loadingScreen.fading)return;let fadeInPromise=new Promise(resolve$1=>{let unwatch=watch([()=>loadingScreen.visible,()=>loadingScreen.fading],([visible,fading])=>{visible&&!fading&&(unwatch(),resolve$1())},{immediate:!0})});return Promise.race([fadeInPromise,sleep(timeout)])}var bngNavigator=class{opts={root:null,container:null,bootscreen:null,north:null,clock:null,backgroundRgb:[50,50,50],roadColors:[`#FFFFFFFF`,`#A6A678FF`,`#A67854FF`],routeColor:`#3388EEFF`,markerColor:`#2C5CFF`,routes:!1,markers:!1,vehicles:!1,vehicleMarker:null,cameraColor:`#FD6A00`,vehicleColor:`#A3D39C`,rotate:!0,scale:1,pitch:0,offsetX:128,offsetY:64,resolution:4096,speedZoom:!1,speedOffset:0,speedPitch:!0,speedZoomIncrements:1,speedZoomMultiplier:2,speedZoomMax:200,speedZoomEffect:.15,hideBootscreen:!1};elms={root:document};mapScale=1;startup=!0;startupFallback=!0;layers={};layersLoadOrder=[bngNavLayerMap,bngNavLayerRoute,bngNavLayerMarkers,bngNavLayerVehicles,bngNavLayerElements,bngNavLayerBootscreen];setOptions(options){if(!(typeof options!=`object`||Array.isArray(options))){for(let key in this.opts)key in options&&(this.opts[key]=options[key]);for(let name in this.layers){let layer=this.layers[name];typeof layer.setOptions==`function`&&layer.setOptions(this.opts)}}}constructor(options){this.setOptions(options);for(let key of[`root`,`container`,`clock`,`north`,`bootscreen`]){let elm;typeof this.opts[key]==`string`?elm=this.elms.root.querySelector(this.opts[key]):this.opts[key]&&(elm=this.opts[key]),elm&&(elm instanceof HTMLElement||elm instanceof SVGElement)&&(this.elms[key]=elm)}if(!this.elms.root)throw Error(`Cannot find map root element`);if(!this.elms.container)throw Error(`Cannot find map container element`);this.elms.svg=new bngNavSVG(this.elms.container.children[0]);for(let cls of this.layersLoadOrder){let elms$4=cls.name===`map`?this.elms:{...this.elms,cvs:this.layers.map.cvs,routes:[this.layers.map.rwrapper,this.layers.map.rcanvas,this.layers.map.rcanvasCtx]};if(cls.canInit(elms$4,this.opts)){let dim=cls.name===`map`?this.mapScale:this.layers.map.dimensions,layer=new cls(elms$4,this.opts,dim);layer&&layer.name&&(this.layers[layer.name]=layer)}}this.layersLoadOrder=null;let expose=(layer,method,name=null)=>{this[name||method]=layer?layer[method].bind(layer):()=>{}};expose(this.layers.map,`setRotation`),expose(this.layers.map,`setLocation`),expose(this.layers.map,`setZoom`),expose(this.layers.map,`setScale`),expose(this.layers.map,`setSpeed`),expose(this.layers.map,`setOpacity`),expose(this.layers.route,`update`,`setRoute`),expose(this.layers.markers,`update`,`setMarkers`),expose(this.layers.bootscreen,`setImage`,`setBootscreenImage`)}update(data){data&&this.setup(data),this.layers.map.update(),this.layers.elements&&this.layers.elements.update(this.layers.map.state),this.layers.map.render()}setup(data){typeof data.terrainTiles==`object`&&!Array.isArray(data.terrainTiles)&&(data.terrainTiles=[]),this.layers.map.setMapSize(data)&&this.startupFallback?(this.startupFallback=!1,this.startup=!0):this.startup||(this.startupFallback=!0),this.startup&&(this.startup=!1,this.layers.map.applyMapSize(),this.layers.map.renderMap(data))}setData(data){if(!data||Object.keys(data).length===0){console.log(`Received empty map data`);return}this.layers.vehicles&&this.layers.vehicles.update(data),this.update(data),this.opts.hideBootscreen&&this.layers.bootscreen&&this.layers.bootscreen.hide()}updateData(data){typeof data==`object`&&(`x`in data&&`y`in data&&this.layers.map.setLocation(data.x,data.y,!1),`rotation`in data&&this.layers.map.setRotation(data.rotation,!1),`speed`in data&&this.layers.map.setSpeed(data.speed,!1),`ignitionLevel`in data&&this.layers.bootscreen&&this.layers.bootscreen.toggle(data.ignitionLevel<2),this.update())}},bngNavUtils=class{static truncDec(num,dec=2){let d=10**dec;return~~(num*d)/d}static setStyle(node,style){for(let name in style)node.style[name]=style[name]}},bngNavSVG=class{ns={svg:`http://www.w3.org/2000/svg`,xlink:`http://www.w3.org/1999/xlink`};root;constructor(root){if(!root||!root.tagName||root.tagName.toLowerCase()!==`svg`)throw Error(`Cannot access svg in a container`);this.root=root}setViewBox(viewBox){this.root.setAttributeNS(null,`viewBox`,viewBox)}createNode(tag,...args){let[attrs,parent]=args;parent||(attrs&&attrs instanceof SVGElement?(parent=attrs,attrs=null):parent=this.root);let node=document.createElementNS(this.ns.svg,tag);return attrs&&this.setAttrs(node,attrs),parent.appendChild(node),node}removeNode(node){node&&node.parentNode&&node.parentNode.removeChild(node)}setAttrs(node,attrs){for(let name in attrs){let ns=name.startsWith(`xlink:`)?this.ns.xlink:null;node.setAttributeNS(ns,name,attrs[name])}}clearNode(node){let elm;for(;elm=node.children[0];)node.removeChild(elm)}setStyle=bngNavUtils.setStyle;createCanvas(resolution){let fo=this.createNode(`foreignObject`);this.setStyle(fo,{position:`absolute`,x:`0`,y:`0`,width:`100%`,height:`100%`});let cvs=document.createElement(`canvas`);return cvs.width=resolution,cvs.height=resolution,fo.appendChild(cvs),[fo,cvs,cvs.getContext(`2d`)]}},bngNavLayerMap=class{static name=`map`;dimensions={ver:0,offset:512,scale:1,centerX:1024,centerY:1024,width:2048,height:2048,resScale:1};state={x:0,y:0,speed:0,scale:1,zoom:1,speedZoom:0,rotation:0,focusX:0,focusY:0,offsetX:0,offsetY:0};container;svg;wrapper;canvas;canvasCtx;rwrapper;rcanvas;rcanvasCtx;cvs;renders=[];rendered={terrainCvs:null,terrainCtx:null,roadsCvs:null,roadsCtx:null};terrainOpacity=1;gridGap=50;gridColour=`#cccccccc`;roadColors;resolution=2048;offsetX;offsetY;rotate;scale;pitch;speedPitch;speedOffset;speedZoom;speedZoomIncrements;speedZoomMultiplier;speedZoomMax;speedZoomEffect;static canInit(elms$4,opts){return!0}constructor({container,svg},opts,mapScale){this.name=this.constructor.name,this.container=container,this.svg=svg,[this.wrapper,this.canvas,this.canvasCtx]=svg.createCanvas(opts.resolution),[this.rwrapper,this.rcanvas,this.rcanvasCtx]=svg.createCanvas(opts.resolution);let that=this;this.rendered.terrainCvs=window.OffscreenCanvas?new window.OffscreenCanvas(1,1):document.createElement(`canvas`),this.rendered.terrainCtx=this.rendered.terrainCvs.getContext(`2d`),this.addRenderSource({passive:!0,source:this.rendered.terrainCvs,get alpha(){return that.terrainOpacity}}),this.rendered.roadsCvs=window.OffscreenCanvas?new window.OffscreenCanvas(1,1):document.createElement(`canvas`),this.rendered.roadsCtx=this.rendered.roadsCvs.getContext(`2d`),this.addRenderSource({passive:!0,source:this.rendered.roadsCvs}),this.dimensions.scale=mapScale,this.setOptions(opts),this.setOpacity(1)}setOptions(opts){this.bgRgb=opts.backgroundRgb.join(`, `),this.roadColors=opts.roadColors,this.resolution=opts.resolution,this.offsetX=opts.offsetX,this.offsetY=opts.offsetY,this.rotate=opts.rotate,this.scale=opts.scale,this.state.scale=this.scale*this.state.zoom,this.pitch=opts.pitch,this.speedPitch=opts.speedPitch,this.speedOffset=opts.speedOffset,this.speedZoom=opts.speedZoom,this.speedZoomIncrements=opts.speedZoomIncrements,this.speedZoomMultiplier=opts.speedZoomMultiplier,this.speedZoomMax=opts.speedZoomMax,this.speedZoomEffect=opts.speedZoomEffect}setLocation(x,y,doupdate=!0){this.state.x=-x,this.state.y=y,this.state.focusX=~~(this.state.x/this.dimensions.scale*this.dimensions.resScale),this.state.focusY=~~(this.state.y/this.dimensions.scale*this.dimensions.resScale),this.state.offsetX=this.dimensions.centerX-this.state.focusX,this.state.offsetY=this.dimensions.centerY-this.state.focusY,this.container.style.transformOrigin=`${this.state.offsetX}px ${this.state.offsetY}px`}setRotation(rotation,doupdate=!0){this.state.rotation=bngNavUtils.truncDec(rotation,3)%360,doupdate&&this.update()}setZoom(zoom,doupdate=!0){let fixed=(zoom-150)*2;this.setSpeed(fixed)}setScale(zoom,doupdate=!0){this.state.zoom=zoom,this.state.scale=this.scale*zoom}setSpeed(speed){this.state.speed=bngNavUtils.truncDec(speed,3),this.state.speed===0?this.state.speedZoom=0:this.state.speedZoom=bngNavUtils.truncDec(Math.min(1+this.state.speed*3.6*1.5,this.speedZoomMax)/this.speedZoomIncrements*this.speedZoomIncrements/this.speedZoomMax,3)}setOpacity(opacity){this.canvas.style.backgroundColor=`rgba(${this.bgRgb}, ${opacity})`,this.terrainOpacity=opacity}setMapSize(data){let res;return data.terrainTiles&&data.terrainTiles[0]&&data.terrainTiles[0].size?(this.setMapDimensions(data),res=!0):this.dimensions.ver===0&&(this.setMapDimensions(data),res=!1),res}setMapDimensions(data){let poss=[],tiles=data.terrainTiles||[];for(let tile of tiles)poss.push([tile.offset[0],-tile.offset[1]],[tile.offset[0]+tile.size[0],-tile.offset[1]+tile.size[1]]);for(let key in data.nodes)poss.push([data.nodes[key].pos[0],-data.nodes[key].pos[1]]);let minX=1/0,maxX=-1/0,minY=1/0,maxY=-1/0;for(let pos of poss)pos[0]/=this.dimensions.scale,pos[1]/=this.dimensions.scale,pos[0]maxX&&(maxX=pos[0]),pos[1]maxY&&(maxY=pos[1]);let dim={centerX:-minX,centerY:-minY,width:-minX+maxX,height:-minY+maxY};if((dim.centerX<0||dim.centerY<0)&&((isFinite(dim.centerX)||isFinite(dim.centerY))&&console.error(`Navigator: Invalid center point detected.`),dim.centerX=this.resolution/2,dim.centerY=this.resolution/2,dim.width=this.resolution,dim.height=this.resolution),this.dimensions.offset>0){let off=this.dimensions.offset;dim.centerX+=off,dim.width+=off*2,dim.centerY+=off,dim.height+=off*2}for(let key in dim.width>this.resolution||dim.height>this.resolution?(dim.resScale=this.resolution/(dim.width>dim.height?dim.width:dim.height),dim.width*=dim.resScale,dim.height*=dim.resScale,dim.centerX*=dim.resScale,dim.centerY*=dim.resScale,dim.offset=dim.offset>0?dim.offset/dim.resScale:0):dim.resScale=1,dim)key!==`resScale`&&(dim[key]=Math.round(dim[key]));let changed=!1;for(let key in dim)this.dimensions[key]!==dim[key]&&(this.dimensions[key]=dim[key],changed=!0);changed&&this.dimensions.ver++}applyMapSize(){this.container.style.width=this.dimensions.width+`px`,this.container.style.height=this.dimensions.height+`px`,this.svg.setViewBox(`0 0 ${this.dimensions.width} ${this.dimensions.height}`);let width$1=this.dimensions.width,height$1=this.dimensions.height;this.canvas.style.width=this.wrapper.style.width=width$1+`px`,this.canvas.style.height=this.wrapper.style.height=height$1+`px`,this.canvas.width=width$1,this.canvas.height=height$1,this.rendered.terrainCtx.clearRect(0,0,this.rendered.terrainCvs.width,this.rendered.terrainCvs.height),this.rendered.terrainCvs.width=width$1,this.rendered.terrainCvs.height=height$1,this.rendered.roadsCtx.clearRect(0,0,this.rendered.roadsCvs.width,this.rendered.roadsCvs.height),this.rendered.roadsCvs.width=width$1,this.rendered.roadsCvs.height=height$1}addRenderSource(source){if(typeof source!=`object`&&!(`source`in source))return console.error(`Navigator: Render source is invalid`);this.renders.push(source)}render(passive=!1){if(!passive)return;let ctx=this.canvasCtx,full=[0,0,this.dimensions.width,this.dimensions.height];ctx.clearRect(...full);for(let src of this.renders){if(!!src.passive!==passive||src.source.width===0||src.source.height===0)continue;let region=src.region;if(src.render){let res=src.render();typeof res==`object`&&`empty`in res&&(region={full:res,fullArray:[res.x1,res.y1,res.x2-res.x1,res.y2-res.y1]})}let pos=src.pos;pos||=(pos=region&&!region.full.empty?region.fullArray:full,[...pos,...pos]),src.alpha&&(ctx.globalAlpha=src.alpha),ctx.drawImage(src.source,...pos),ctx.globalAlpha=1}}renderMap(data){for(let key in this.drawTerrain(data,this.rendered.terrainCtx),data.nodes){let el=data.nodes[key];if(el.links)for(let key2 in el.links)el.links[key2].drivability=Math.round(el.links[key2].drivability*10)/10}this.drawRoads(data.nodes,0,.1,this.roadColors[2],this.rendered.roadsCtx),this.drawRoads(data.nodes,.1,.9,this.roadColors[1],this.rendered.roadsCtx),this.drawRoads(data.nodes,.9,1,this.roadColors[0],this.rendered.roadsCtx),this.render(!0)}drawTerrain(data,ctx){for(let x=this.gridGap;x{ctx.clearRect(...dest),ctx.drawImage(img,0,0,img.width,img.height,...dest),loading--,loading===0&&this.render(!0)}),img.addEventListener(`error`,()=>{console.error(`Navigator: Unable to load tile "${tile.file}"`),loading--,loading===0&&this.render(!0)}),img.src=tile.file}}createLine(ctx,p1,p2,color){Math.abs(p1.radius-p2.radius)>.2?this.varLine(ctx,p1.x,p1.y,p2.x,p2.y,p1.radius,p2.radius,color):(ctx.beginPath(),ctx.lineWidth=Math.max(p1.radius,p2.radius),ctx.lineCap=`round`,ctx.strokeStyle=color,ctx.moveTo(p1.x,p1.y),ctx.lineTo(p2.x,p2.y),ctx.stroke())}varLine(ctx,x1,y1,x2,y2,w1,w2,color){let dx=x2-x1,dy=y2-y1,length=dx*dx+dy*dy;if(length==0)return;length=Math.sqrt(length),w1*=.5,w2*=.5,dx/=length,dy/=length;let shiftx=-dy*w1,shifty=dx*w1;ctx.beginPath(),ctx.fillStyle=color,ctx.moveTo(x1+shiftx,y1+shifty),ctx.lineTo(x1-shiftx,y1-shifty),shiftx=-dy*w2,shifty=dx*w2,ctx.lineTo(x2-shiftx,y2-shifty),ctx.lineTo(x2+shiftx,y2+shifty),ctx.closePath(),ctx.arc(x1,y1,w1,0,2*Math.PI),ctx.arc(x2,y2,w2,0,2*Math.PI),ctx.fill()}drawRoads(nodes,drivabilityMin,drivabilityMax,colour,ctx){for(let key in nodes){let el=nodes[key];if(el.links)for(let key2 in el.links){let drivability=el.links[key2].drivability;if(drivabilitydrivabilityMax)continue;let el2=nodes[key2];this.createLine(ctx,{x:el.pos[0]/this.dimensions.scale*this.dimensions.resScale+this.dimensions.centerX,y:-el.pos[1]/this.dimensions.scale*this.dimensions.resScale+this.dimensions.centerY,radius:Math.min(Math.max(el.radius,0),5)*3*this.dimensions.resScale},{x:el2.pos[0]/this.dimensions.scale*this.dimensions.resScale+this.dimensions.centerX,y:-el2.pos[1]/this.dimensions.scale*this.dimensions.resScale+this.dimensions.centerY,radius:Math.min(Math.max(el2.radius,0),5)*3*this.dimensions.resScale},colour)}}}update(){let pos={x:-this.state.offsetX+this.offsetX,y:-this.state.offsetY+this.offsetY},rot={x:0,z:0};this.speedOffset>0&&(pos.y+=this.state.speedZoom*this.speedOffset),this.rotate&&(rot.x=this.pitch,this.speedPitch>0&&(rot.x+=this.speedPitch*this.state.speedZoom),rot.z=this.state.rotation);let scale=this.state.scale/this.dimensions.resScale;this.speedZoom&&(scale-=this.state.speedZoom*.1/this.dimensions.resScale),this.container.style.transform=`translate3d(${pos.x}px, ${pos.y}px, 0px) rotateX(${rot.x}deg) rotateZ(${rot.z}deg) scale(${scale})`}},bngNavLayerRoute=class{static name=`route`;dimensions;scale=1/3;lineWidth=10;color;wrapper;canvas;canvasCtx;current=null;static canInit(elms$4,opts){return!!opts.routes}constructor({routes,svg},opts,dimensions){this.name=this.constructor.name,[this.wrapper,this.canvas,this.canvasCtx]=routes||svg.createCanvas(opts.resolution),this.dimensions=dimensions,this.setOptions(opts)}setOptions(opts){this.color=opts.routeColor}update(data){if(this.dimver!==this.dimensions.ver){this.dimver=this.dimensions.ver;let width$1=this.dimensions.width,height$1=this.dimensions.height;this.canvas.style.width=this.wrapper.style.width=width$1+`px`,this.canvas.style.height=this.wrapper.style.height=height$1+`px`,this.canvas.width=this.canvasCtx.width=width$1*this.scale,this.canvas.height=this.canvasCtx.height=height$1*this.scale}if(!data||!data.markers){this.clear();return}this.current?this.optimiseAndDrawRoute(data,this.current):(this.clear(),data&&this.drawFreshRoute(data)),this.current=data.markers}clear(){this.current=null,this.canvasCtx.clearRect(0,0,this.canvas.width,this.canvas.height),this.canvasCtx.stroke()}drawFreshRoute(data){this.drawRoute({color:data.color,lineWidth:this.lineWidth,lineCap:`butt`,markers:data.markers,startIndex:0,drawFromIndex:2,drawToIndex:data.markers.length})}optimiseAndDrawRoute(data,prevMarkers){let markers$1=data.markers,ci=markers$1.length-2,pi=prevMarkers.length-2;for(;pi>=0&&ci>=0&&!(markers$1[ci]!==prevMarkers[pi]||markers$1[ci+1]!==prevMarkers[pi+1]);)ci-=2,pi-=2;(ci>=0||pi>=0)&&(this.canvasCtx.globalCompositeOperation=`destination-out`,this.drawRoute({color:data.color,lineWidth:this.lineWidth+2,markers:prevMarkers,drawToIndex:Math.min(pi+4,prevMarkers.length)}),this.canvasCtx.globalCompositeOperation=`source-over`,this.drawRoute({color:data.color,lineWidth:this.lineWidth,markers:data.markers,drawToIndex:Math.min(ci+6,data.markers.length)}))}drawRoute({color,lineWidth,lineCap=`round`,markers:markers$1,startIndex=0,drawFromIndex=0,drawToIndex}){let mapFac=this.scale/this.dimensions.scale,cx=this.dimensions.centerX*mapFac,cy=this.dimensions.centerY*mapFac;this.canvasCtx.beginPath(),this.canvasCtx.strokeStyle=color||this.color,this.canvasCtx.lineWidth=lineWidth*this.scale*this.dimensions.resScale,this.canvasCtx.lineCap=lineCap,this.canvasCtx.moveTo(markers$1[startIndex]*this.dimensions.resScale*mapFac+cx,-markers$1[startIndex+1]*this.dimensions.resScale*mapFac+cy);for(let i=drawFromIndex;iargs.map(arg=>typeof arg==`string`?arg:`[object]`)},createElementNS:{base:Document,getArgs:(...args)=>args.map(arg=>typeof arg==`string`?arg:`[object]`)},cloneNode:{base:Node,getArgs:deep=>[deep]},importNode:{base:Document,getArgs:(node,deep)=>[`[node]`,deep]},insertAdjacentHTML:{base:Element,getArgs:(position,text)=>[position,`[HTML:${text.length}chars]`]},innerHTML:{isSetter:!0,bases:[Element,HTMLElement],getArgs:value=>[`[HTML:${typeof value==`string`?value.length:0}chars]`]},outerHTML:{isSetter:!0,bases:[Element,HTMLElement],getArgs:value=>[`[HTML:${typeof value==`string`?value.length:0}chars]`]},appendChild:{base:Node,stats:`append`,getArgs:child=>[`[${child?.tagName||child?.nodeName||`node`}]`]},insertBefore:{base:Node,stats:`append`,getArgs:(newNode,referenceNode)=>[`[${newNode?.tagName||newNode?.nodeName||`node`}]`,`[${referenceNode?.tagName||referenceNode?.nodeName||`ref`}]`]},replaceChild:{base:Node,stats:`append`,getArgs:(newChild,oldChild)=>[`[${newChild?.tagName||newChild?.nodeName||`new`}]`,`[${oldChild?.tagName||oldChild?.nodeName||`old`}]`]},append:{base:Element,stats:`append`,getArgs:(...nodes)=>nodes.map(node=>`[${node?.tagName||node?.nodeName||typeof node==`string`?`text`:`node`}]`)},prepend:{base:Element,stats:`append`,getArgs:(...nodes)=>nodes.map(node=>`[${node?.tagName||node?.nodeName||typeof node==`string`?`text`:`node`}]`)},before:{base:Element,stats:`append`,getArgs:(...nodes)=>nodes.map(node=>`[${node?.tagName||node?.nodeName||typeof node==`string`?`text`:`node`}]`)},after:{base:Element,stats:`append`,getArgs:(...nodes)=>nodes.map(node=>`[${node?.tagName||node?.nodeName||typeof node==`string`?`text`:`node`}]`)}};function setupInterceptor(type){let interceptor=interceptors[type];if(interceptor.isSetter){let descriptor;if(interceptor.bases){for(let base of interceptor.bases)if(descriptor=Object.getOwnPropertyDescriptor(base.prototype,type),descriptor){interceptor.base=base;break}}descriptor&&(interceptor.original=descriptor)}else interceptor.original=interceptor.base.prototype[type];if(!interceptor.original){logger_default.warn(`No original for ${type}`);return}interceptor.call=(self$1,...args)=>{let stackTrace=captureStackTrace();if(stackTrace&&(includeAnonymousCalls||!stackTrace.hasAnonymous||stackTrace.filePaths.length>0)){let callData={type,timestamp:Date.now(),args:interceptor.getArgs(...args),stackTrace};if(interceptor.stats===`append`&&self$1)try{let mainContainer=self$1.closest?self$1.closest(`#mainContainer_apps`):null;if(mainContainer){let directChildDiv=self$1;for(;directChildDiv&&directChildDiv.parentNode&&directChildDiv.parentNode!==mainContainer;)directChildDiv=directChildDiv.parentNode;directChildDiv&&directChildDiv.parentNode===mainContainer&&directChildDiv.tagName===`DIV`&&(callData.uiAppInsertion={targetElement:directChildDiv})}}catch{}callQueue.push(callData)}if(interceptor.isSetter)interceptor.original.set.call(self$1,args[0]);else return interceptor.original.apply(self$1,args)},interceptor.isSetter?Object.defineProperty(interceptor.base.prototype,type,{get:interceptor.original.get,set:function(value){interceptor.call(this,value)},configurable:!0,enumerable:!0}):interceptor.base.prototype[type]=function(...args){return interceptor.call(this,...args)},interceptor.restore=()=>{interceptor.isSetter?Object.defineProperty(interceptor.base.prototype,type,{get:interceptor.original.get,set:interceptor.original.set,configurable:!0,enumerable:!0}):interceptor.base.prototype[type]=interceptor.original}}function captureStackTrace(){let stack$2=Error().stack;if(!stack$2)return null;let relevantLines=stack$2.split(` `).slice(STACK_TRACE_SKIP_LINES),filePaths=[],hasAnonymous=!1;for(let line of relevantLines){let match=line.match(STACK_TRACE_REGEX_FULL),functionName,filePath,lineNum,column;if(match)functionName=match[1],filePath=match[2],lineNum=match[3],column=match[4];else if(match=line.match(STACK_TRACE_REGEX),match)functionName=`anonymous`,filePath=match[1],lineNum=match[2],column=match[3];else continue;let isAnonymous=functionName?.includes(`anonymous`)||functionName?.includes(``)||!functionName||functionName.trim()===``;isAnonymous&&(hasAnonymous=!0,!includeAnonymousCalls)||filePaths.push({functionName,filePath,line:lineNum,column,isAnonymous})}return{filePaths,fullStack:stack$2,hasAnonymous}}async function processCallQueue(){if(statsProcessor.lastProcessTime=Date.now(),!(statsProcessor.isProcessing||callQueue.length===0)){statsProcessor.isProcessing=!0;try{let batch$1=callQueue.splice(0,Math.max(statsProcessor.batchSize,callQueue.length/5));statsProcessor.totalProcessed+=batch$1.length;for(let i=0;i{try{processCallQueue()}catch(error){logger_default.error(`Fatal error in DOM watchdog processing:`,error),destroy()}},statsProcessor.processInterval)}function getStats(){return{files:Object.fromEntries(statsProcessor.files),types:Object.fromEntries(statsProcessor.types),append:Object.fromEntries(statsProcessor.append)}}function clearStats(){statsProcessor.files.clear(),statsProcessor.types.clear(),statsProcessor.append.clear(),statsProcessor.uiApps.clear(),callQueue.length=0,statsProcessor.totalProcessed=0,statsProcessor.lastProcessTime=0,overlayActive&&updateOverlayDivs()}function restartTimer(){isInitialized&&startStatsProcessor()}function setIncludeAnonymousCalls(include){includeAnonymousCalls=include}var exposedFunctions=()=>({watchdogRecentCalls:getRecentCalls,watchdogCallChainStats:getCallChainStats,watchdogClearStats:clearStats,watchdogSetIncludeAnonymousCalls:setIncludeAnonymousCalls,watchdogDestroy:destroy,watchdogRestartTimer:restartTimer,watchdogUIAppsStats:getUIAppsStats,watchdogRefreshOverlay:refreshOverlay,watchdogStats:()=>{let stats=getStats(),format$2=obj=>Object.entries(obj).sort((a$1,b)=>b[1]-a$1[1]).map(([key,value])=>`${key}: ${value}`.replace(`\\`,`\\\\`)).join(`
  • `+b).split(R[0]).slice(1).map(R[3]?escape:inlineEscape).join(R[3]||`
    
  • `)+R[2]:f===`#`?``+inlineEscape(b.slice(f+1))+``:f===`<`?b:`

    `+inlineEscape(b)+`

    `}),h$1}function escape(t){return new Option(t).innerHTML}function inlineEscape(s){return escape(s).replace(/\\_/g,`⋿`).replace(/!\[([^\]]*)]\(([^(]+)\)/g,`$1`).replace(/\[([^\]]+)]\(([^(]+?)\)/g,`$1`.link(`$2`)).replace(/`([^`]+)`/g,`$1`).replace(/(\*\*|__)(?=\S)([^\r]*?\S[*_]*)\1/g,`$2`).replace(/(\*| _)(?=\S)([^\r]*?\S)\1/g,`$2`).replace(/⋿/g,`_`)}var content_exports=__export({bbcode:()=>bbcode_exports,markdown:()=>markdown_exports});const screenLocked=computed(()=>screenLockedState.value),loadingScreen=reactive({active:!1,visible:!1,fading:!1,shown:!1});var screenLockedState=ref(!1),loadingScreenStateWatcher=null,events;function screenLock(lock=!1){lock=!!lock,screenLockedState.value=lock;let body=document.body;body&&body.classList.toggle(`screen-locked`,lock)}async function startLoading$1(func){screenLock(!0),events||=useBridge().events,events.emit(`LoadingScreen`,{active:!0}),await nextTick(),setTimeout(()=>func(),500)}function linkLoadingScreenState(state){loadingScreenStateWatcher?.(),loadingScreenStateWatcher=watch([()=>state.active,()=>state.visible,()=>state.fading,()=>state.shown],([active,visible,fading,shown])=>{loadingScreen.active=active,loadingScreen.visible=visible,loadingScreen.fading=fading,loadingScreen.shown=shown,screenLock(active)})}function waitForLoadingScreenFadeIn$1(timeout=4e3){if(loadingScreen.visible&&!loadingScreen.fading)return;let fadeInPromise=new Promise(resolve$1=>{let unwatch=watch([()=>loadingScreen.visible,()=>loadingScreen.fading],([visible,fading])=>{visible&&!fading&&(unwatch(),resolve$1())},{immediate:!0})});return Promise.race([fadeInPromise,sleep(timeout)])}var bngNavigator=class{opts={root:null,container:null,bootscreen:null,north:null,clock:null,backgroundRgb:[50,50,50],roadColors:[`#FFFFFFFF`,`#A6A678FF`,`#A67854FF`],routeColor:`#3388EEFF`,markerColor:`#2C5CFF`,routes:!1,markers:!1,vehicles:!1,vehicleMarker:null,cameraColor:`#FD6A00`,vehicleColor:`#A3D39C`,rotate:!0,scale:1,pitch:0,offsetX:128,offsetY:64,resolution:4096,speedZoom:!1,speedOffset:0,speedPitch:!0,speedZoomIncrements:1,speedZoomMultiplier:2,speedZoomMax:200,speedZoomEffect:.15,hideBootscreen:!1};elms={root:document};mapScale=1;startup=!0;startupFallback=!0;layers={};layersLoadOrder=[bngNavLayerMap,bngNavLayerRoute,bngNavLayerMarkers,bngNavLayerVehicles,bngNavLayerElements,bngNavLayerBootscreen];setOptions(options){if(!(typeof options!=`object`||Array.isArray(options))){for(let key in this.opts)key in options&&(this.opts[key]=options[key]);for(let name in this.layers){let layer=this.layers[name];typeof layer.setOptions==`function`&&layer.setOptions(this.opts)}}}constructor(options){this.setOptions(options);for(let key of[`root`,`container`,`clock`,`north`,`bootscreen`]){let elm;typeof this.opts[key]==`string`?elm=this.elms.root.querySelector(this.opts[key]):this.opts[key]&&(elm=this.opts[key]),elm&&(elm instanceof HTMLElement||elm instanceof SVGElement)&&(this.elms[key]=elm)}if(!this.elms.root)throw Error(`Cannot find map root element`);if(!this.elms.container)throw Error(`Cannot find map container element`);this.elms.svg=new bngNavSVG(this.elms.container.children[0]);for(let cls of this.layersLoadOrder){let elms$4=cls.name===`map`?this.elms:{...this.elms,cvs:this.layers.map.cvs,routes:[this.layers.map.rwrapper,this.layers.map.rcanvas,this.layers.map.rcanvasCtx]};if(cls.canInit(elms$4,this.opts)){let dim=cls.name===`map`?this.mapScale:this.layers.map.dimensions,layer=new cls(elms$4,this.opts,dim);layer&&layer.name&&(this.layers[layer.name]=layer)}}this.layersLoadOrder=null;let expose=(layer,method,name=null)=>{this[name||method]=layer?layer[method].bind(layer):()=>{}};expose(this.layers.map,`setRotation`),expose(this.layers.map,`setLocation`),expose(this.layers.map,`setZoom`),expose(this.layers.map,`setScale`),expose(this.layers.map,`setSpeed`),expose(this.layers.map,`setOpacity`),expose(this.layers.route,`update`,`setRoute`),expose(this.layers.markers,`update`,`setMarkers`),expose(this.layers.bootscreen,`setImage`,`setBootscreenImage`)}update(data){data&&this.setup(data),this.layers.map.update(),this.layers.elements&&this.layers.elements.update(this.layers.map.state),this.layers.map.render()}setup(data){typeof data.terrainTiles==`object`&&!Array.isArray(data.terrainTiles)&&(data.terrainTiles=[]),this.layers.map.setMapSize(data)&&this.startupFallback?(this.startupFallback=!1,this.startup=!0):this.startup||(this.startupFallback=!0),this.startup&&(this.startup=!1,this.layers.map.applyMapSize(),this.layers.map.renderMap(data))}setData(data){if(!data||Object.keys(data).length===0){console.log(`Received empty map data`);return}this.layers.vehicles&&this.layers.vehicles.update(data),this.update(data),this.opts.hideBootscreen&&this.layers.bootscreen&&this.layers.bootscreen.hide()}updateData(data){typeof data==`object`&&(`x`in data&&`y`in data&&this.layers.map.setLocation(data.x,data.y,!1),`rotation`in data&&this.layers.map.setRotation(data.rotation,!1),`speed`in data&&this.layers.map.setSpeed(data.speed,!1),`ignitionLevel`in data&&this.layers.bootscreen&&this.layers.bootscreen.toggle(data.ignitionLevel<2),this.update())}},bngNavUtils=class{static truncDec(num,dec=2){let d=10**dec;return~~(num*d)/d}static setStyle(node,style){for(let name in style)node.style[name]=style[name]}},bngNavSVG=class{ns={svg:`http://www.w3.org/2000/svg`,xlink:`http://www.w3.org/1999/xlink`};root;constructor(root){if(!root||!root.tagName||root.tagName.toLowerCase()!==`svg`)throw Error(`Cannot access svg in a container`);this.root=root}setViewBox(viewBox){this.root.setAttributeNS(null,`viewBox`,viewBox)}createNode(tag,...args){let[attrs,parent]=args;parent||(attrs&&attrs instanceof SVGElement?(parent=attrs,attrs=null):parent=this.root);let node=document.createElementNS(this.ns.svg,tag);return attrs&&this.setAttrs(node,attrs),parent.appendChild(node),node}removeNode(node){node&&node.parentNode&&node.parentNode.removeChild(node)}setAttrs(node,attrs){for(let name in attrs){let ns=name.startsWith(`xlink:`)?this.ns.xlink:null;node.setAttributeNS(ns,name,attrs[name])}}clearNode(node){let elm;for(;elm=node.children[0];)node.removeChild(elm)}setStyle=bngNavUtils.setStyle;createCanvas(resolution){let fo=this.createNode(`foreignObject`);this.setStyle(fo,{position:`absolute`,x:`0`,y:`0`,width:`100%`,height:`100%`});let cvs=document.createElement(`canvas`);return cvs.width=resolution,cvs.height=resolution,fo.appendChild(cvs),[fo,cvs,cvs.getContext(`2d`)]}},bngNavLayerMap=class{static name=`map`;dimensions={ver:0,offset:512,scale:1,centerX:1024,centerY:1024,width:2048,height:2048,resScale:1};state={x:0,y:0,speed:0,scale:1,zoom:1,speedZoom:0,rotation:0,focusX:0,focusY:0,offsetX:0,offsetY:0};container;svg;wrapper;canvas;canvasCtx;rwrapper;rcanvas;rcanvasCtx;cvs;renders=[];rendered={terrainCvs:null,terrainCtx:null,roadsCvs:null,roadsCtx:null};terrainOpacity=1;gridGap=50;gridColour=`#cccccccc`;roadColors;resolution=2048;offsetX;offsetY;rotate;scale;pitch;speedPitch;speedOffset;speedZoom;speedZoomIncrements;speedZoomMultiplier;speedZoomMax;speedZoomEffect;static canInit(elms$4,opts){return!0}constructor({container,svg},opts,mapScale){this.name=this.constructor.name,this.container=container,this.svg=svg,[this.wrapper,this.canvas,this.canvasCtx]=svg.createCanvas(opts.resolution),[this.rwrapper,this.rcanvas,this.rcanvasCtx]=svg.createCanvas(opts.resolution);let that=this;this.rendered.terrainCvs=window.OffscreenCanvas?new window.OffscreenCanvas(1,1):document.createElement(`canvas`),this.rendered.terrainCtx=this.rendered.terrainCvs.getContext(`2d`),this.addRenderSource({passive:!0,source:this.rendered.terrainCvs,get alpha(){return that.terrainOpacity}}),this.rendered.roadsCvs=window.OffscreenCanvas?new window.OffscreenCanvas(1,1):document.createElement(`canvas`),this.rendered.roadsCtx=this.rendered.roadsCvs.getContext(`2d`),this.addRenderSource({passive:!0,source:this.rendered.roadsCvs}),this.dimensions.scale=mapScale,this.setOptions(opts),this.setOpacity(1)}setOptions(opts){this.bgRgb=opts.backgroundRgb.join(`, `),this.roadColors=opts.roadColors,this.resolution=opts.resolution,this.offsetX=opts.offsetX,this.offsetY=opts.offsetY,this.rotate=opts.rotate,this.scale=opts.scale,this.state.scale=this.scale*this.state.zoom,this.pitch=opts.pitch,this.speedPitch=opts.speedPitch,this.speedOffset=opts.speedOffset,this.speedZoom=opts.speedZoom,this.speedZoomIncrements=opts.speedZoomIncrements,this.speedZoomMultiplier=opts.speedZoomMultiplier,this.speedZoomMax=opts.speedZoomMax,this.speedZoomEffect=opts.speedZoomEffect}setLocation(x,y,doupdate=!0){this.state.x=-x,this.state.y=y,this.state.focusX=~~(this.state.x/this.dimensions.scale*this.dimensions.resScale),this.state.focusY=~~(this.state.y/this.dimensions.scale*this.dimensions.resScale),this.state.offsetX=this.dimensions.centerX-this.state.focusX,this.state.offsetY=this.dimensions.centerY-this.state.focusY,this.container.style.transformOrigin=`${this.state.offsetX}px ${this.state.offsetY}px`}setRotation(rotation,doupdate=!0){this.state.rotation=bngNavUtils.truncDec(rotation,3)%360,doupdate&&this.update()}setZoom(zoom,doupdate=!0){let fixed=(zoom-150)*2;this.setSpeed(fixed)}setScale(zoom,doupdate=!0){this.state.zoom=zoom,this.state.scale=this.scale*zoom}setSpeed(speed){this.state.speed=bngNavUtils.truncDec(speed,3),this.state.speed===0?this.state.speedZoom=0:this.state.speedZoom=bngNavUtils.truncDec(Math.min(1+this.state.speed*3.6*1.5,this.speedZoomMax)/this.speedZoomIncrements*this.speedZoomIncrements/this.speedZoomMax,3)}setOpacity(opacity){this.canvas.style.backgroundColor=`rgba(${this.bgRgb}, ${opacity})`,this.terrainOpacity=opacity}setMapSize(data){let res;return data.terrainTiles&&data.terrainTiles[0]&&data.terrainTiles[0].size?(this.setMapDimensions(data),res=!0):this.dimensions.ver===0&&(this.setMapDimensions(data),res=!1),res}setMapDimensions(data){let poss=[],tiles=data.terrainTiles||[];for(let tile of tiles)poss.push([tile.offset[0],-tile.offset[1]],[tile.offset[0]+tile.size[0],-tile.offset[1]+tile.size[1]]);for(let key in data.nodes)poss.push([data.nodes[key].pos[0],-data.nodes[key].pos[1]]);let minX=1/0,maxX=-1/0,minY=1/0,maxY=-1/0;for(let pos of poss)pos[0]/=this.dimensions.scale,pos[1]/=this.dimensions.scale,pos[0]maxX&&(maxX=pos[0]),pos[1]maxY&&(maxY=pos[1]);let dim={centerX:-minX,centerY:-minY,width:-minX+maxX,height:-minY+maxY};if((dim.centerX<0||dim.centerY<0)&&((isFinite(dim.centerX)||isFinite(dim.centerY))&&console.error(`Navigator: Invalid center point detected.`),dim.centerX=this.resolution/2,dim.centerY=this.resolution/2,dim.width=this.resolution,dim.height=this.resolution),this.dimensions.offset>0){let off=this.dimensions.offset;dim.centerX+=off,dim.width+=off*2,dim.centerY+=off,dim.height+=off*2}for(let key in dim.width>this.resolution||dim.height>this.resolution?(dim.resScale=this.resolution/(dim.width>dim.height?dim.width:dim.height),dim.width*=dim.resScale,dim.height*=dim.resScale,dim.centerX*=dim.resScale,dim.centerY*=dim.resScale,dim.offset=dim.offset>0?dim.offset/dim.resScale:0):dim.resScale=1,dim)key!==`resScale`&&(dim[key]=Math.round(dim[key]));let changed=!1;for(let key in dim)this.dimensions[key]!==dim[key]&&(this.dimensions[key]=dim[key],changed=!0);changed&&this.dimensions.ver++}applyMapSize(){this.container.style.width=this.dimensions.width+`px`,this.container.style.height=this.dimensions.height+`px`,this.svg.setViewBox(`0 0 ${this.dimensions.width} ${this.dimensions.height}`);let width$1=this.dimensions.width,height$1=this.dimensions.height;this.canvas.style.width=this.wrapper.style.width=width$1+`px`,this.canvas.style.height=this.wrapper.style.height=height$1+`px`,this.canvas.width=width$1,this.canvas.height=height$1,this.rendered.terrainCtx.clearRect(0,0,this.rendered.terrainCvs.width,this.rendered.terrainCvs.height),this.rendered.terrainCvs.width=width$1,this.rendered.terrainCvs.height=height$1,this.rendered.roadsCtx.clearRect(0,0,this.rendered.roadsCvs.width,this.rendered.roadsCvs.height),this.rendered.roadsCvs.width=width$1,this.rendered.roadsCvs.height=height$1}addRenderSource(source){if(typeof source!=`object`&&!(`source`in source))return console.error(`Navigator: Render source is invalid`);this.renders.push(source)}render(passive=!1){if(!passive)return;let ctx=this.canvasCtx,full=[0,0,this.dimensions.width,this.dimensions.height];ctx.clearRect(...full);for(let src of this.renders){if(!!src.passive!==passive||src.source.width===0||src.source.height===0)continue;let region=src.region;if(src.render){let res=src.render();typeof res==`object`&&`empty`in res&&(region={full:res,fullArray:[res.x1,res.y1,res.x2-res.x1,res.y2-res.y1]})}let pos=src.pos;pos||=(pos=region&&!region.full.empty?region.fullArray:full,[...pos,...pos]),src.alpha&&(ctx.globalAlpha=src.alpha),ctx.drawImage(src.source,...pos),ctx.globalAlpha=1}}renderMap(data){for(let key in this.drawTerrain(data,this.rendered.terrainCtx),data.nodes){let el=data.nodes[key];if(el.links)for(let key2 in el.links)el.links[key2].drivability=Math.round(el.links[key2].drivability*10)/10}this.drawRoads(data.nodes,0,.1,this.roadColors[2],this.rendered.roadsCtx),this.drawRoads(data.nodes,.1,.9,this.roadColors[1],this.rendered.roadsCtx),this.drawRoads(data.nodes,.9,1,this.roadColors[0],this.rendered.roadsCtx),this.render(!0)}drawTerrain(data,ctx){for(let x=this.gridGap;x{ctx.clearRect(...dest),ctx.drawImage(img,0,0,img.width,img.height,...dest),loading--,loading===0&&this.render(!0)}),img.addEventListener(`error`,()=>{console.error(`Navigator: Unable to load tile "${tile.file}"`),loading--,loading===0&&this.render(!0)}),img.src=tile.file}}createLine(ctx,p1,p2,color){Math.abs(p1.radius-p2.radius)>.2?this.varLine(ctx,p1.x,p1.y,p2.x,p2.y,p1.radius,p2.radius,color):(ctx.beginPath(),ctx.lineWidth=Math.max(p1.radius,p2.radius),ctx.lineCap=`round`,ctx.strokeStyle=color,ctx.moveTo(p1.x,p1.y),ctx.lineTo(p2.x,p2.y),ctx.stroke())}varLine(ctx,x1,y1,x2,y2,w1,w2,color){let dx=x2-x1,dy=y2-y1,length=dx*dx+dy*dy;if(length==0)return;length=Math.sqrt(length),w1*=.5,w2*=.5,dx/=length,dy/=length;let shiftx=-dy*w1,shifty=dx*w1;ctx.beginPath(),ctx.fillStyle=color,ctx.moveTo(x1+shiftx,y1+shifty),ctx.lineTo(x1-shiftx,y1-shifty),shiftx=-dy*w2,shifty=dx*w2,ctx.lineTo(x2-shiftx,y2-shifty),ctx.lineTo(x2+shiftx,y2+shifty),ctx.closePath(),ctx.arc(x1,y1,w1,0,2*Math.PI),ctx.arc(x2,y2,w2,0,2*Math.PI),ctx.fill()}drawRoads(nodes,drivabilityMin,drivabilityMax,colour,ctx){for(let key in nodes){let el=nodes[key];if(el.links)for(let key2 in el.links){let drivability=el.links[key2].drivability;if(drivabilitydrivabilityMax)continue;let el2=nodes[key2];this.createLine(ctx,{x:el.pos[0]/this.dimensions.scale*this.dimensions.resScale+this.dimensions.centerX,y:-el.pos[1]/this.dimensions.scale*this.dimensions.resScale+this.dimensions.centerY,radius:Math.min(Math.max(el.radius,0),5)*3*this.dimensions.resScale},{x:el2.pos[0]/this.dimensions.scale*this.dimensions.resScale+this.dimensions.centerX,y:-el2.pos[1]/this.dimensions.scale*this.dimensions.resScale+this.dimensions.centerY,radius:Math.min(Math.max(el2.radius,0),5)*3*this.dimensions.resScale},colour)}}}update(){let pos={x:-this.state.offsetX+this.offsetX,y:-this.state.offsetY+this.offsetY},rot={x:0,z:0};this.speedOffset>0&&(pos.y+=this.state.speedZoom*this.speedOffset),this.rotate&&(rot.x=this.pitch,this.speedPitch>0&&(rot.x+=this.speedPitch*this.state.speedZoom),rot.z=this.state.rotation);let scale=this.state.scale/this.dimensions.resScale;this.speedZoom&&(scale-=this.state.speedZoom*.1/this.dimensions.resScale),this.container.style.transform=`translate3d(${pos.x}px, ${pos.y}px, 0px) rotateX(${rot.x}deg) rotateZ(${rot.z}deg) scale(${scale})`}},bngNavLayerRoute=class{static name=`route`;dimensions;scale=1/3;lineWidth=10;color;wrapper;canvas;canvasCtx;current=null;static canInit(elms$4,opts){return!!opts.routes}constructor({routes,svg},opts,dimensions){this.name=this.constructor.name,[this.wrapper,this.canvas,this.canvasCtx]=routes||svg.createCanvas(opts.resolution),this.dimensions=dimensions,this.setOptions(opts)}setOptions(opts){this.color=opts.routeColor}update(data){if(this.dimver!==this.dimensions.ver){this.dimver=this.dimensions.ver;let width$1=this.dimensions.width,height$1=this.dimensions.height;this.canvas.style.width=this.wrapper.style.width=width$1+`px`,this.canvas.style.height=this.wrapper.style.height=height$1+`px`,this.canvas.width=this.canvasCtx.width=width$1*this.scale,this.canvas.height=this.canvasCtx.height=height$1*this.scale}if(!data||!data.markers){this.clear();return}this.current?this.optimiseAndDrawRoute(data,this.current):(this.clear(),data&&this.drawFreshRoute(data)),this.current=data.markers}clear(){this.current=null,this.canvasCtx.clearRect(0,0,this.canvas.width,this.canvas.height),this.canvasCtx.stroke()}drawFreshRoute(data){this.drawRoute({color:data.color,lineWidth:this.lineWidth,lineCap:`butt`,markers:data.markers,startIndex:0,drawFromIndex:2,drawToIndex:data.markers.length})}optimiseAndDrawRoute(data,prevMarkers){let markers$1=data.markers,ci=markers$1.length-2,pi=prevMarkers.length-2;for(;pi>=0&&ci>=0&&!(markers$1[ci]!==prevMarkers[pi]||markers$1[ci+1]!==prevMarkers[pi+1]);)ci-=2,pi-=2;(ci>=0||pi>=0)&&(this.canvasCtx.globalCompositeOperation=`destination-out`,this.drawRoute({color:data.color,lineWidth:this.lineWidth+2,markers:prevMarkers,drawToIndex:Math.min(pi+4,prevMarkers.length)}),this.canvasCtx.globalCompositeOperation=`source-over`,this.drawRoute({color:data.color,lineWidth:this.lineWidth,markers:data.markers,drawToIndex:Math.min(ci+6,data.markers.length)}))}drawRoute({color,lineWidth,lineCap=`round`,markers:markers$1,startIndex=0,drawFromIndex=0,drawToIndex}){let mapFac=this.scale/this.dimensions.scale,cx=this.dimensions.centerX*mapFac,cy=this.dimensions.centerY*mapFac;this.canvasCtx.beginPath(),this.canvasCtx.strokeStyle=color||this.color,this.canvasCtx.lineWidth=lineWidth*this.scale*this.dimensions.resScale,this.canvasCtx.lineCap=lineCap,this.canvasCtx.moveTo(markers$1[startIndex]*this.dimensions.resScale*mapFac+cx,-markers$1[startIndex+1]*this.dimensions.resScale*mapFac+cy);for(let i=drawFromIndex;iargs.map(arg=>typeof arg==`string`?arg:`[object]`)},createElementNS:{base:Document,getArgs:(...args)=>args.map(arg=>typeof arg==`string`?arg:`[object]`)},cloneNode:{base:Node,getArgs:deep=>[deep]},importNode:{base:Document,getArgs:(node,deep)=>[`[node]`,deep]},insertAdjacentHTML:{base:Element,getArgs:(position,text)=>[position,`[HTML:${text.length}chars]`]},innerHTML:{isSetter:!0,bases:[Element,HTMLElement],getArgs:value=>[`[HTML:${typeof value==`string`?value.length:0}chars]`]},outerHTML:{isSetter:!0,bases:[Element,HTMLElement],getArgs:value=>[`[HTML:${typeof value==`string`?value.length:0}chars]`]},appendChild:{base:Node,stats:`append`,getArgs:child=>[`[${child?.tagName||child?.nodeName||`node`}]`]},insertBefore:{base:Node,stats:`append`,getArgs:(newNode,referenceNode)=>[`[${newNode?.tagName||newNode?.nodeName||`node`}]`,`[${referenceNode?.tagName||referenceNode?.nodeName||`ref`}]`]},replaceChild:{base:Node,stats:`append`,getArgs:(newChild,oldChild)=>[`[${newChild?.tagName||newChild?.nodeName||`new`}]`,`[${oldChild?.tagName||oldChild?.nodeName||`old`}]`]},append:{base:Element,stats:`append`,getArgs:(...nodes)=>nodes.map(node=>`[${node?.tagName||node?.nodeName||typeof node==`string`?`text`:`node`}]`)},prepend:{base:Element,stats:`append`,getArgs:(...nodes)=>nodes.map(node=>`[${node?.tagName||node?.nodeName||typeof node==`string`?`text`:`node`}]`)},before:{base:Element,stats:`append`,getArgs:(...nodes)=>nodes.map(node=>`[${node?.tagName||node?.nodeName||typeof node==`string`?`text`:`node`}]`)},after:{base:Element,stats:`append`,getArgs:(...nodes)=>nodes.map(node=>`[${node?.tagName||node?.nodeName||typeof node==`string`?`text`:`node`}]`)}};function setupInterceptor(type){let interceptor=interceptors[type];if(interceptor.isSetter){let descriptor;if(interceptor.bases){for(let base of interceptor.bases)if(descriptor=Object.getOwnPropertyDescriptor(base.prototype,type),descriptor){interceptor.base=base;break}}descriptor&&(interceptor.original=descriptor)}else interceptor.original=interceptor.base.prototype[type];if(!interceptor.original){logger_default.warn(`No original for ${type}`);return}interceptor.call=(self$1,...args)=>{let stackTrace=captureStackTrace();if(stackTrace&&(includeAnonymousCalls||!stackTrace.hasAnonymous||stackTrace.filePaths.length>0)){let callData={type,timestamp:Date.now(),args:interceptor.getArgs(...args),stackTrace};if(interceptor.stats===`append`&&self$1)try{let mainContainer=self$1.closest?self$1.closest(`#mainContainer_apps`):null;if(mainContainer){let directChildDiv=self$1;for(;directChildDiv&&directChildDiv.parentNode&&directChildDiv.parentNode!==mainContainer;)directChildDiv=directChildDiv.parentNode;directChildDiv&&directChildDiv.parentNode===mainContainer&&directChildDiv.tagName===`DIV`&&(callData.uiAppInsertion={targetElement:directChildDiv})}}catch{}callQueue.push(callData)}if(interceptor.isSetter)interceptor.original.set.call(self$1,args[0]);else return interceptor.original.apply(self$1,args)},interceptor.isSetter?Object.defineProperty(interceptor.base.prototype,type,{get:interceptor.original.get,set:function(value){interceptor.call(this,value)},configurable:!0,enumerable:!0}):interceptor.base.prototype[type]=function(...args){return interceptor.call(this,...args)},interceptor.restore=()=>{interceptor.isSetter?Object.defineProperty(interceptor.base.prototype,type,{get:interceptor.original.get,set:interceptor.original.set,configurable:!0,enumerable:!0}):interceptor.base.prototype[type]=interceptor.original}}function captureStackTrace(){let stack$2=Error().stack;if(!stack$2)return null;let relevantLines=stack$2.split(` `).slice(STACK_TRACE_SKIP_LINES),filePaths=[],hasAnonymous=!1;for(let line of relevantLines){let match=line.match(STACK_TRACE_REGEX_FULL),functionName,filePath,lineNum,column;if(match)functionName=match[1],filePath=match[2],lineNum=match[3],column=match[4];else if(match=line.match(STACK_TRACE_REGEX),match)functionName=`anonymous`,filePath=match[1],lineNum=match[2],column=match[3];else continue;let isAnonymous=functionName?.includes(`anonymous`)||functionName?.includes(``)||!functionName||functionName.trim()===``;isAnonymous&&(hasAnonymous=!0,!includeAnonymousCalls)||filePaths.push({functionName,filePath,line:lineNum,column,isAnonymous})}return{filePaths,fullStack:stack$2,hasAnonymous}}async function processCallQueue(){if(statsProcessor.lastProcessTime=Date.now(),!(statsProcessor.isProcessing||callQueue.length===0)){statsProcessor.isProcessing=!0;try{let batch$1=callQueue.splice(0,Math.max(statsProcessor.batchSize,callQueue.length/5));statsProcessor.totalProcessed+=batch$1.length;for(let i=0;i{try{processCallQueue()}catch(error){logger_default.error(`Fatal error in DOM watchdog processing:`,error),destroy()}},statsProcessor.processInterval)}function getStats(){return{files:Object.fromEntries(statsProcessor.files),types:Object.fromEntries(statsProcessor.types),append:Object.fromEntries(statsProcessor.append)}}function clearStats(){statsProcessor.files.clear(),statsProcessor.types.clear(),statsProcessor.append.clear(),statsProcessor.uiApps.clear(),callQueue.length=0,statsProcessor.totalProcessed=0,statsProcessor.lastProcessTime=0,overlayActive&&updateOverlayDivs()}function restartTimer(){isInitialized&&startStatsProcessor()}function setIncludeAnonymousCalls(include){includeAnonymousCalls=include}var exposedFunctions=()=>({watchdogRecentCalls:getRecentCalls,watchdogCallChainStats:getCallChainStats,watchdogClearStats:clearStats,watchdogSetIncludeAnonymousCalls:setIncludeAnonymousCalls,watchdogDestroy:destroy,watchdogRestartTimer:restartTimer,watchdogUIAppsStats:getUIAppsStats,watchdogRefreshOverlay:refreshOverlay,watchdogStats:()=>{let stats=getStats(),format$2=obj=>Object.entries(obj).sort((a$1,b)=>b[1]-a$1[1]).map(([key,value])=>`${key}: ${value}`.replace(`\\`,`\\\\`)).join(`
  • `+b).split(R[0]).slice(1).map(R[3]?escape:inlineEscape).join(R[3]||`
    
  • `)+R[2]:f===`#`?``+inlineEscape(b.slice(f+1))+``:f===`<`?b:`

    `+inlineEscape(b)+`

    `}),h$1}function escape(t){return new Option(t).innerHTML}function inlineEscape(s){return escape(s).replace(/\\_/g,`⋿`).replace(/!\[([^\]]*)]\(([^(]+)\)/g,`$1`).replace(/\[([^\]]+)]\(([^(]+?)\)/g,`$1`.link(`$2`)).replace(/`([^`]+)`/g,`$1`).replace(/(\*\*|__)(?=\S)([^\r]*?\S[*_]*)\1/g,`$2`).replace(/(\*| _)(?=\S)([^\r]*?\S)\1/g,`$2`).replace(/⋿/g,`_`)}var content_exports=__export({bbcode:()=>bbcode_exports,markdown:()=>markdown_exports});const screenLocked=computed(()=>screenLockedState.value),loadingScreen=reactive({active:!1,visible:!1,fading:!1,shown:!1});var screenLockedState=ref(!1),loadingScreenStateWatcher=null,events;function screenLock(lock=!1){lock=!!lock,screenLockedState.value=lock;let body=document.body;body&&body.classList.toggle(`screen-locked`,lock)}async function startLoading$1(func){screenLock(!0),events||=useBridge().events,events.emit(`LoadingScreen`,{active:!0}),await nextTick(),setTimeout(()=>func(),500)}function linkLoadingScreenState(state){loadingScreenStateWatcher?.(),loadingScreenStateWatcher=watch([()=>state.active,()=>state.visible,()=>state.fading,()=>state.shown],([active,visible,fading,shown])=>{loadingScreen.active=active,loadingScreen.visible=visible,loadingScreen.fading=fading,loadingScreen.shown=shown,screenLock(active)})}function waitForLoadingScreenFadeIn$1(timeout=4e3){if(loadingScreen.visible&&!loadingScreen.fading)return;let fadeInPromise=new Promise(resolve$1=>{let unwatch=watch([()=>loadingScreen.visible,()=>loadingScreen.fading],([visible,fading])=>{visible&&!fading&&(unwatch(),resolve$1())},{immediate:!0})});return Promise.race([fadeInPromise,sleep(timeout)])}var bngNavigator=class{opts={root:null,container:null,bootscreen:null,north:null,clock:null,backgroundRgb:[50,50,50],roadColors:[`#FFFFFFFF`,`#A6A678FF`,`#A67854FF`],routeColor:`#3388EEFF`,markerColor:`#2C5CFF`,routes:!1,markers:!1,vehicles:!1,vehicleMarker:null,cameraColor:`#FD6A00`,vehicleColor:`#A3D39C`,rotate:!0,scale:1,pitch:0,offsetX:128,offsetY:64,resolution:4096,speedZoom:!1,speedOffset:0,speedPitch:!0,speedZoomIncrements:1,speedZoomMultiplier:2,speedZoomMax:200,speedZoomEffect:.15,hideBootscreen:!1};elms={root:document};mapScale=1;startup=!0;startupFallback=!0;layers={};layersLoadOrder=[bngNavLayerMap,bngNavLayerRoute,bngNavLayerMarkers,bngNavLayerVehicles,bngNavLayerElements,bngNavLayerBootscreen];setOptions(options){if(!(typeof options!=`object`||Array.isArray(options))){for(let key in this.opts)key in options&&(this.opts[key]=options[key]);for(let name in this.layers){let layer=this.layers[name];typeof layer.setOptions==`function`&&layer.setOptions(this.opts)}}}constructor(options){this.setOptions(options);for(let key of[`root`,`container`,`clock`,`north`,`bootscreen`]){let elm;typeof this.opts[key]==`string`?elm=this.elms.root.querySelector(this.opts[key]):this.opts[key]&&(elm=this.opts[key]),elm&&(elm instanceof HTMLElement||elm instanceof SVGElement)&&(this.elms[key]=elm)}if(!this.elms.root)throw Error(`Cannot find map root element`);if(!this.elms.container)throw Error(`Cannot find map container element`);this.elms.svg=new bngNavSVG(this.elms.container.children[0]);for(let cls of this.layersLoadOrder){let elms$4=cls.name===`map`?this.elms:{...this.elms,cvs:this.layers.map.cvs,routes:[this.layers.map.rwrapper,this.layers.map.rcanvas,this.layers.map.rcanvasCtx]};if(cls.canInit(elms$4,this.opts)){let dim=cls.name===`map`?this.mapScale:this.layers.map.dimensions,layer=new cls(elms$4,this.opts,dim);layer&&layer.name&&(this.layers[layer.name]=layer)}}this.layersLoadOrder=null;let expose=(layer,method,name=null)=>{this[name||method]=layer?layer[method].bind(layer):()=>{}};expose(this.layers.map,`setRotation`),expose(this.layers.map,`setLocation`),expose(this.layers.map,`setZoom`),expose(this.layers.map,`setScale`),expose(this.layers.map,`setSpeed`),expose(this.layers.map,`setOpacity`),expose(this.layers.route,`update`,`setRoute`),expose(this.layers.markers,`update`,`setMarkers`),expose(this.layers.bootscreen,`setImage`,`setBootscreenImage`)}update(data){data&&this.setup(data),this.layers.map.update(),this.layers.elements&&this.layers.elements.update(this.layers.map.state),this.layers.map.render()}setup(data){typeof data.terrainTiles==`object`&&!Array.isArray(data.terrainTiles)&&(data.terrainTiles=[]),this.layers.map.setMapSize(data)&&this.startupFallback?(this.startupFallback=!1,this.startup=!0):this.startup||(this.startupFallback=!0),this.startup&&(this.startup=!1,this.layers.map.applyMapSize(),this.layers.map.renderMap(data))}setData(data){if(!data||Object.keys(data).length===0){console.log(`Received empty map data`);return}this.layers.vehicles&&this.layers.vehicles.update(data),this.update(data),this.opts.hideBootscreen&&this.layers.bootscreen&&this.layers.bootscreen.hide()}updateData(data){typeof data==`object`&&(`x`in data&&`y`in data&&this.layers.map.setLocation(data.x,data.y,!1),`rotation`in data&&this.layers.map.setRotation(data.rotation,!1),`speed`in data&&this.layers.map.setSpeed(data.speed,!1),`ignitionLevel`in data&&this.layers.bootscreen&&this.layers.bootscreen.toggle(data.ignitionLevel<2),this.update())}},bngNavUtils=class{static truncDec(num,dec=2){let d=10**dec;return~~(num*d)/d}static setStyle(node,style){for(let name in style)node.style[name]=style[name]}},bngNavSVG=class{ns={svg:`http://www.w3.org/2000/svg`,xlink:`http://www.w3.org/1999/xlink`};root;constructor(root){if(!root||!root.tagName||root.tagName.toLowerCase()!==`svg`)throw Error(`Cannot access svg in a container`);this.root=root}setViewBox(viewBox){this.root.setAttributeNS(null,`viewBox`,viewBox)}createNode(tag,...args){let[attrs,parent]=args;parent||(attrs&&attrs instanceof SVGElement?(parent=attrs,attrs=null):parent=this.root);let node=document.createElementNS(this.ns.svg,tag);return attrs&&this.setAttrs(node,attrs),parent.appendChild(node),node}removeNode(node){node&&node.parentNode&&node.parentNode.removeChild(node)}setAttrs(node,attrs){for(let name in attrs){let ns=name.startsWith(`xlink:`)?this.ns.xlink:null;node.setAttributeNS(ns,name,attrs[name])}}clearNode(node){let elm;for(;elm=node.children[0];)node.removeChild(elm)}setStyle=bngNavUtils.setStyle;createCanvas(resolution){let fo=this.createNode(`foreignObject`);this.setStyle(fo,{position:`absolute`,x:`0`,y:`0`,width:`100%`,height:`100%`});let cvs=document.createElement(`canvas`);return cvs.width=resolution,cvs.height=resolution,fo.appendChild(cvs),[fo,cvs,cvs.getContext(`2d`)]}},bngNavLayerMap=class{static name=`map`;dimensions={ver:0,offset:512,scale:1,centerX:1024,centerY:1024,width:2048,height:2048,resScale:1};state={x:0,y:0,speed:0,scale:1,zoom:1,speedZoom:0,rotation:0,focusX:0,focusY:0,offsetX:0,offsetY:0};container;svg;wrapper;canvas;canvasCtx;rwrapper;rcanvas;rcanvasCtx;cvs;renders=[];rendered={terrainCvs:null,terrainCtx:null,roadsCvs:null,roadsCtx:null};terrainOpacity=1;gridGap=50;gridColour=`#cccccccc`;roadColors;resolution=2048;offsetX;offsetY;rotate;scale;pitch;speedPitch;speedOffset;speedZoom;speedZoomIncrements;speedZoomMultiplier;speedZoomMax;speedZoomEffect;static canInit(elms$4,opts){return!0}constructor({container,svg},opts,mapScale){this.name=this.constructor.name,this.container=container,this.svg=svg,[this.wrapper,this.canvas,this.canvasCtx]=svg.createCanvas(opts.resolution),[this.rwrapper,this.rcanvas,this.rcanvasCtx]=svg.createCanvas(opts.resolution);let that=this;this.rendered.terrainCvs=window.OffscreenCanvas?new window.OffscreenCanvas(1,1):document.createElement(`canvas`),this.rendered.terrainCtx=this.rendered.terrainCvs.getContext(`2d`),this.addRenderSource({passive:!0,source:this.rendered.terrainCvs,get alpha(){return that.terrainOpacity}}),this.rendered.roadsCvs=window.OffscreenCanvas?new window.OffscreenCanvas(1,1):document.createElement(`canvas`),this.rendered.roadsCtx=this.rendered.roadsCvs.getContext(`2d`),this.addRenderSource({passive:!0,source:this.rendered.roadsCvs}),this.dimensions.scale=mapScale,this.setOptions(opts),this.setOpacity(1)}setOptions(opts){this.bgRgb=opts.backgroundRgb.join(`, `),this.roadColors=opts.roadColors,this.resolution=opts.resolution,this.offsetX=opts.offsetX,this.offsetY=opts.offsetY,this.rotate=opts.rotate,this.scale=opts.scale,this.state.scale=this.scale*this.state.zoom,this.pitch=opts.pitch,this.speedPitch=opts.speedPitch,this.speedOffset=opts.speedOffset,this.speedZoom=opts.speedZoom,this.speedZoomIncrements=opts.speedZoomIncrements,this.speedZoomMultiplier=opts.speedZoomMultiplier,this.speedZoomMax=opts.speedZoomMax,this.speedZoomEffect=opts.speedZoomEffect}setLocation(x,y,doupdate=!0){this.state.x=-x,this.state.y=y,this.state.focusX=~~(this.state.x/this.dimensions.scale*this.dimensions.resScale),this.state.focusY=~~(this.state.y/this.dimensions.scale*this.dimensions.resScale),this.state.offsetX=this.dimensions.centerX-this.state.focusX,this.state.offsetY=this.dimensions.centerY-this.state.focusY,this.container.style.transformOrigin=`${this.state.offsetX}px ${this.state.offsetY}px`}setRotation(rotation,doupdate=!0){this.state.rotation=bngNavUtils.truncDec(rotation,3)%360,doupdate&&this.update()}setZoom(zoom,doupdate=!0){let fixed=(zoom-150)*2;this.setSpeed(fixed)}setScale(zoom,doupdate=!0){this.state.zoom=zoom,this.state.scale=this.scale*zoom}setSpeed(speed){this.state.speed=bngNavUtils.truncDec(speed,3),this.state.speed===0?this.state.speedZoom=0:this.state.speedZoom=bngNavUtils.truncDec(Math.min(1+this.state.speed*3.6*1.5,this.speedZoomMax)/this.speedZoomIncrements*this.speedZoomIncrements/this.speedZoomMax,3)}setOpacity(opacity){this.canvas.style.backgroundColor=`rgba(${this.bgRgb}, ${opacity})`,this.terrainOpacity=opacity}setMapSize(data){let res;return data.terrainTiles&&data.terrainTiles[0]&&data.terrainTiles[0].size?(this.setMapDimensions(data),res=!0):this.dimensions.ver===0&&(this.setMapDimensions(data),res=!1),res}setMapDimensions(data){let poss=[],tiles=data.terrainTiles||[];for(let tile of tiles)poss.push([tile.offset[0],-tile.offset[1]],[tile.offset[0]+tile.size[0],-tile.offset[1]+tile.size[1]]);for(let key in data.nodes)poss.push([data.nodes[key].pos[0],-data.nodes[key].pos[1]]);let minX=1/0,maxX=-1/0,minY=1/0,maxY=-1/0;for(let pos of poss)pos[0]/=this.dimensions.scale,pos[1]/=this.dimensions.scale,pos[0]maxX&&(maxX=pos[0]),pos[1]maxY&&(maxY=pos[1]);let dim={centerX:-minX,centerY:-minY,width:-minX+maxX,height:-minY+maxY};if((dim.centerX<0||dim.centerY<0)&&((isFinite(dim.centerX)||isFinite(dim.centerY))&&console.error(`Navigator: Invalid center point detected.`),dim.centerX=this.resolution/2,dim.centerY=this.resolution/2,dim.width=this.resolution,dim.height=this.resolution),this.dimensions.offset>0){let off=this.dimensions.offset;dim.centerX+=off,dim.width+=off*2,dim.centerY+=off,dim.height+=off*2}for(let key in dim.width>this.resolution||dim.height>this.resolution?(dim.resScale=this.resolution/(dim.width>dim.height?dim.width:dim.height),dim.width*=dim.resScale,dim.height*=dim.resScale,dim.centerX*=dim.resScale,dim.centerY*=dim.resScale,dim.offset=dim.offset>0?dim.offset/dim.resScale:0):dim.resScale=1,dim)key!==`resScale`&&(dim[key]=Math.round(dim[key]));let changed=!1;for(let key in dim)this.dimensions[key]!==dim[key]&&(this.dimensions[key]=dim[key],changed=!0);changed&&this.dimensions.ver++}applyMapSize(){this.container.style.width=this.dimensions.width+`px`,this.container.style.height=this.dimensions.height+`px`,this.svg.setViewBox(`0 0 ${this.dimensions.width} ${this.dimensions.height}`);let width$1=this.dimensions.width,height$1=this.dimensions.height;this.canvas.style.width=this.wrapper.style.width=width$1+`px`,this.canvas.style.height=this.wrapper.style.height=height$1+`px`,this.canvas.width=width$1,this.canvas.height=height$1,this.rendered.terrainCtx.clearRect(0,0,this.rendered.terrainCvs.width,this.rendered.terrainCvs.height),this.rendered.terrainCvs.width=width$1,this.rendered.terrainCvs.height=height$1,this.rendered.roadsCtx.clearRect(0,0,this.rendered.roadsCvs.width,this.rendered.roadsCvs.height),this.rendered.roadsCvs.width=width$1,this.rendered.roadsCvs.height=height$1}addRenderSource(source){if(typeof source!=`object`&&!(`source`in source))return console.error(`Navigator: Render source is invalid`);this.renders.push(source)}render(passive=!1){if(!passive)return;let ctx=this.canvasCtx,full=[0,0,this.dimensions.width,this.dimensions.height];ctx.clearRect(...full);for(let src of this.renders){if(!!src.passive!==passive||src.source.width===0||src.source.height===0)continue;let region=src.region;if(src.render){let res=src.render();typeof res==`object`&&`empty`in res&&(region={full:res,fullArray:[res.x1,res.y1,res.x2-res.x1,res.y2-res.y1]})}let pos=src.pos;pos||=(pos=region&&!region.full.empty?region.fullArray:full,[...pos,...pos]),src.alpha&&(ctx.globalAlpha=src.alpha),ctx.drawImage(src.source,...pos),ctx.globalAlpha=1}}renderMap(data){for(let key in this.drawTerrain(data,this.rendered.terrainCtx),data.nodes){let el=data.nodes[key];if(el.links)for(let key2 in el.links)el.links[key2].drivability=Math.round(el.links[key2].drivability*10)/10}this.drawRoads(data.nodes,0,.1,this.roadColors[2],this.rendered.roadsCtx),this.drawRoads(data.nodes,.1,.9,this.roadColors[1],this.rendered.roadsCtx),this.drawRoads(data.nodes,.9,1,this.roadColors[0],this.rendered.roadsCtx),this.render(!0)}drawTerrain(data,ctx){for(let x=this.gridGap;x{ctx.clearRect(...dest),ctx.drawImage(img,0,0,img.width,img.height,...dest),loading--,loading===0&&this.render(!0)}),img.addEventListener(`error`,()=>{console.error(`Navigator: Unable to load tile "${tile.file}"`),loading--,loading===0&&this.render(!0)}),img.src=tile.file}}createLine(ctx,p1,p2,color){Math.abs(p1.radius-p2.radius)>.2?this.varLine(ctx,p1.x,p1.y,p2.x,p2.y,p1.radius,p2.radius,color):(ctx.beginPath(),ctx.lineWidth=Math.max(p1.radius,p2.radius),ctx.lineCap=`round`,ctx.strokeStyle=color,ctx.moveTo(p1.x,p1.y),ctx.lineTo(p2.x,p2.y),ctx.stroke())}varLine(ctx,x1,y1,x2,y2,w1,w2,color){let dx=x2-x1,dy=y2-y1,length=dx*dx+dy*dy;if(length==0)return;length=Math.sqrt(length),w1*=.5,w2*=.5,dx/=length,dy/=length;let shiftx=-dy*w1,shifty=dx*w1;ctx.beginPath(),ctx.fillStyle=color,ctx.moveTo(x1+shiftx,y1+shifty),ctx.lineTo(x1-shiftx,y1-shifty),shiftx=-dy*w2,shifty=dx*w2,ctx.lineTo(x2-shiftx,y2-shifty),ctx.lineTo(x2+shiftx,y2+shifty),ctx.closePath(),ctx.arc(x1,y1,w1,0,2*Math.PI),ctx.arc(x2,y2,w2,0,2*Math.PI),ctx.fill()}drawRoads(nodes,drivabilityMin,drivabilityMax,colour,ctx){for(let key in nodes){let el=nodes[key];if(el.links)for(let key2 in el.links){let drivability=el.links[key2].drivability;if(drivabilitydrivabilityMax)continue;let el2=nodes[key2];this.createLine(ctx,{x:el.pos[0]/this.dimensions.scale*this.dimensions.resScale+this.dimensions.centerX,y:-el.pos[1]/this.dimensions.scale*this.dimensions.resScale+this.dimensions.centerY,radius:Math.min(Math.max(el.radius,0),5)*3*this.dimensions.resScale},{x:el2.pos[0]/this.dimensions.scale*this.dimensions.resScale+this.dimensions.centerX,y:-el2.pos[1]/this.dimensions.scale*this.dimensions.resScale+this.dimensions.centerY,radius:Math.min(Math.max(el2.radius,0),5)*3*this.dimensions.resScale},colour)}}}update(){let pos={x:-this.state.offsetX+this.offsetX,y:-this.state.offsetY+this.offsetY},rot={x:0,z:0};this.speedOffset>0&&(pos.y+=this.state.speedZoom*this.speedOffset),this.rotate&&(rot.x=this.pitch,this.speedPitch>0&&(rot.x+=this.speedPitch*this.state.speedZoom),rot.z=this.state.rotation);let scale=this.state.scale/this.dimensions.resScale;this.speedZoom&&(scale-=this.state.speedZoom*.1/this.dimensions.resScale),this.container.style.transform=`translate3d(${pos.x}px, ${pos.y}px, 0px) rotateX(${rot.x}deg) rotateZ(${rot.z}deg) scale(${scale})`}},bngNavLayerRoute=class{static name=`route`;dimensions;scale=1/3;lineWidth=10;color;wrapper;canvas;canvasCtx;current=null;static canInit(elms$4,opts){return!!opts.routes}constructor({routes,svg},opts,dimensions){this.name=this.constructor.name,[this.wrapper,this.canvas,this.canvasCtx]=routes||svg.createCanvas(opts.resolution),this.dimensions=dimensions,this.setOptions(opts)}setOptions(opts){this.color=opts.routeColor}update(data){if(this.dimver!==this.dimensions.ver){this.dimver=this.dimensions.ver;let width$1=this.dimensions.width,height$1=this.dimensions.height;this.canvas.style.width=this.wrapper.style.width=width$1+`px`,this.canvas.style.height=this.wrapper.style.height=height$1+`px`,this.canvas.width=this.canvasCtx.width=width$1*this.scale,this.canvas.height=this.canvasCtx.height=height$1*this.scale}if(!data||!data.markers){this.clear();return}this.current?this.optimiseAndDrawRoute(data,this.current):(this.clear(),data&&this.drawFreshRoute(data)),this.current=data.markers}clear(){this.current=null,this.canvasCtx.clearRect(0,0,this.canvas.width,this.canvas.height),this.canvasCtx.stroke()}drawFreshRoute(data){this.drawRoute({color:data.color,lineWidth:this.lineWidth,lineCap:`butt`,markers:data.markers,startIndex:0,drawFromIndex:2,drawToIndex:data.markers.length})}optimiseAndDrawRoute(data,prevMarkers){let markers$1=data.markers,ci=markers$1.length-2,pi=prevMarkers.length-2;for(;pi>=0&&ci>=0&&!(markers$1[ci]!==prevMarkers[pi]||markers$1[ci+1]!==prevMarkers[pi+1]);)ci-=2,pi-=2;(ci>=0||pi>=0)&&(this.canvasCtx.globalCompositeOperation=`destination-out`,this.drawRoute({color:data.color,lineWidth:this.lineWidth+2,markers:prevMarkers,drawToIndex:Math.min(pi+4,prevMarkers.length)}),this.canvasCtx.globalCompositeOperation=`source-over`,this.drawRoute({color:data.color,lineWidth:this.lineWidth,markers:data.markers,drawToIndex:Math.min(ci+6,data.markers.length)}))}drawRoute({color,lineWidth,lineCap=`round`,markers:markers$1,startIndex=0,drawFromIndex=0,drawToIndex}){let mapFac=this.scale/this.dimensions.scale,cx=this.dimensions.centerX*mapFac,cy=this.dimensions.centerY*mapFac;this.canvasCtx.beginPath(),this.canvasCtx.strokeStyle=color||this.color,this.canvasCtx.lineWidth=lineWidth*this.scale*this.dimensions.resScale,this.canvasCtx.lineCap=lineCap,this.canvasCtx.moveTo(markers$1[startIndex]*this.dimensions.resScale*mapFac+cx,-markers$1[startIndex+1]*this.dimensions.resScale*mapFac+cy);for(let i=drawFromIndex;iargs.map(arg=>typeof arg==`string`?arg:`[object]`)},createElementNS:{base:Document,getArgs:(...args)=>args.map(arg=>typeof arg==`string`?arg:`[object]`)},cloneNode:{base:Node,getArgs:deep=>[deep]},importNode:{base:Document,getArgs:(node,deep)=>[`[node]`,deep]},insertAdjacentHTML:{base:Element,getArgs:(position,text)=>[position,`[HTML:${text.length}chars]`]},innerHTML:{isSetter:!0,bases:[Element,HTMLElement],getArgs:value=>[`[HTML:${typeof value==`string`?value.length:0}chars]`]},outerHTML:{isSetter:!0,bases:[Element,HTMLElement],getArgs:value=>[`[HTML:${typeof value==`string`?value.length:0}chars]`]},appendChild:{base:Node,stats:`append`,getArgs:child=>[`[${child?.tagName||child?.nodeName||`node`}]`]},insertBefore:{base:Node,stats:`append`,getArgs:(newNode,referenceNode)=>[`[${newNode?.tagName||newNode?.nodeName||`node`}]`,`[${referenceNode?.tagName||referenceNode?.nodeName||`ref`}]`]},replaceChild:{base:Node,stats:`append`,getArgs:(newChild,oldChild)=>[`[${newChild?.tagName||newChild?.nodeName||`new`}]`,`[${oldChild?.tagName||oldChild?.nodeName||`old`}]`]},append:{base:Element,stats:`append`,getArgs:(...nodes)=>nodes.map(node=>`[${node?.tagName||node?.nodeName||typeof node==`string`?`text`:`node`}]`)},prepend:{base:Element,stats:`append`,getArgs:(...nodes)=>nodes.map(node=>`[${node?.tagName||node?.nodeName||typeof node==`string`?`text`:`node`}]`)},before:{base:Element,stats:`append`,getArgs:(...nodes)=>nodes.map(node=>`[${node?.tagName||node?.nodeName||typeof node==`string`?`text`:`node`}]`)},after:{base:Element,stats:`append`,getArgs:(...nodes)=>nodes.map(node=>`[${node?.tagName||node?.nodeName||typeof node==`string`?`text`:`node`}]`)}};function setupInterceptor(type){let interceptor=interceptors[type];if(interceptor.isSetter){let descriptor;if(interceptor.bases){for(let base of interceptor.bases)if(descriptor=Object.getOwnPropertyDescriptor(base.prototype,type),descriptor){interceptor.base=base;break}}descriptor&&(interceptor.original=descriptor)}else interceptor.original=interceptor.base.prototype[type];if(!interceptor.original){logger_default.warn(`No original for ${type}`);return}interceptor.call=(self$1,...args)=>{let stackTrace=captureStackTrace();if(stackTrace&&(includeAnonymousCalls||!stackTrace.hasAnonymous||stackTrace.filePaths.length>0)){let callData={type,timestamp:Date.now(),args:interceptor.getArgs(...args),stackTrace};if(interceptor.stats===`append`&&self$1)try{let mainContainer=self$1.closest?self$1.closest(`#mainContainer_apps`):null;if(mainContainer){let directChildDiv=self$1;for(;directChildDiv&&directChildDiv.parentNode&&directChildDiv.parentNode!==mainContainer;)directChildDiv=directChildDiv.parentNode;directChildDiv&&directChildDiv.parentNode===mainContainer&&directChildDiv.tagName===`DIV`&&(callData.uiAppInsertion={targetElement:directChildDiv})}}catch{}callQueue.push(callData)}if(interceptor.isSetter)interceptor.original.set.call(self$1,args[0]);else return interceptor.original.apply(self$1,args)},interceptor.isSetter?Object.defineProperty(interceptor.base.prototype,type,{get:interceptor.original.get,set:function(value){interceptor.call(this,value)},configurable:!0,enumerable:!0}):interceptor.base.prototype[type]=function(...args){return interceptor.call(this,...args)},interceptor.restore=()=>{interceptor.isSetter?Object.defineProperty(interceptor.base.prototype,type,{get:interceptor.original.get,set:interceptor.original.set,configurable:!0,enumerable:!0}):interceptor.base.prototype[type]=interceptor.original}}function captureStackTrace(){let stack$2=Error().stack;if(!stack$2)return null;let relevantLines=stack$2.split(` `).slice(STACK_TRACE_SKIP_LINES),filePaths=[],hasAnonymous=!1;for(let line of relevantLines){let match=line.match(STACK_TRACE_REGEX_FULL),functionName,filePath,lineNum,column;if(match)functionName=match[1],filePath=match[2],lineNum=match[3],column=match[4];else if(match=line.match(STACK_TRACE_REGEX),match)functionName=`anonymous`,filePath=match[1],lineNum=match[2],column=match[3];else continue;let isAnonymous=functionName?.includes(`anonymous`)||functionName?.includes(``)||!functionName||functionName.trim()===``;isAnonymous&&(hasAnonymous=!0,!includeAnonymousCalls)||filePaths.push({functionName,filePath,line:lineNum,column,isAnonymous})}return{filePaths,fullStack:stack$2,hasAnonymous}}async function processCallQueue(){if(statsProcessor.lastProcessTime=Date.now(),!(statsProcessor.isProcessing||callQueue.length===0)){statsProcessor.isProcessing=!0;try{let batch$1=callQueue.splice(0,Math.max(statsProcessor.batchSize,callQueue.length/5));statsProcessor.totalProcessed+=batch$1.length;for(let i=0;i{try{processCallQueue()}catch(error){logger_default.error(`Fatal error in DOM watchdog processing:`,error),destroy()}},statsProcessor.processInterval)}function getStats(){return{files:Object.fromEntries(statsProcessor.files),types:Object.fromEntries(statsProcessor.types),append:Object.fromEntries(statsProcessor.append)}}function clearStats(){statsProcessor.files.clear(),statsProcessor.types.clear(),statsProcessor.append.clear(),statsProcessor.uiApps.clear(),callQueue.length=0,statsProcessor.totalProcessed=0,statsProcessor.lastProcessTime=0,overlayActive&&updateOverlayDivs()}function restartTimer(){isInitialized&&startStatsProcessor()}function setIncludeAnonymousCalls(include){includeAnonymousCalls=include}var exposedFunctions=()=>({watchdogRecentCalls:getRecentCalls,watchdogCallChainStats:getCallChainStats,watchdogClearStats:clearStats,watchdogSetIncludeAnonymousCalls:setIncludeAnonymousCalls,watchdogDestroy:destroy,watchdogRestartTimer:restartTimer,watchdogUIAppsStats:getUIAppsStats,watchdogRefreshOverlay:refreshOverlay,watchdogStats:()=>{let stats=getStats(),format$2=obj=>Object.entries(obj).sort((a$1,b)=>b[1]-a$1[1]).map(([key,value])=>`${key}: ${value}`.replace(`\\`,`\\\\`)).join(`
  • `+b).split(R[0]).slice(1).map(R[3]?escape:inlineEscape).join(R[3]||`
    
  • `)+R[2]:f===`#`?``+inlineEscape(b.slice(f+1))+``:f===`<`?b:`

    `+inlineEscape(b)+`

    `}),h$1}function escape(t){return new Option(t).innerHTML}function inlineEscape(s){return escape(s).replace(/\\_/g,`⋿`).replace(/!\[([^\]]*)]\(([^(]+)\)/g,`$1`).replace(/\[([^\]]+)]\(([^(]+?)\)/g,`$1`.link(`$2`)).replace(/`([^`]+)`/g,`$1`).replace(/(\*\*|__)(?=\S)([^\r]*?\S[*_]*)\1/g,`$2`).replace(/(\*| _)(?=\S)([^\r]*?\S)\1/g,`$2`).replace(/⋿/g,`_`)}var content_exports=__export({bbcode:()=>bbcode_exports,markdown:()=>markdown_exports});const screenLocked=computed(()=>screenLockedState.value),loadingScreen=reactive({active:!1,visible:!1,fading:!1,shown:!1});var screenLockedState=ref(!1),loadingScreenStateWatcher=null,events;function screenLock(lock=!1){lock=!!lock,screenLockedState.value=lock;let body=document.body;body&&body.classList.toggle(`screen-locked`,lock)}async function startLoading$1(func){screenLock(!0),events||=useBridge().events,events.emit(`LoadingScreen`,{active:!0}),await nextTick(),setTimeout(()=>func(),500)}function linkLoadingScreenState(state){loadingScreenStateWatcher?.(),loadingScreenStateWatcher=watch([()=>state.active,()=>state.visible,()=>state.fading,()=>state.shown],([active,visible,fading,shown])=>{loadingScreen.active=active,loadingScreen.visible=visible,loadingScreen.fading=fading,loadingScreen.shown=shown,screenLock(active)})}function waitForLoadingScreenFadeIn$1(timeout=4e3){if(loadingScreen.visible&&!loadingScreen.fading)return;let fadeInPromise=new Promise(resolve$1=>{let unwatch=watch([()=>loadingScreen.visible,()=>loadingScreen.fading],([visible,fading])=>{visible&&!fading&&(unwatch(),resolve$1())},{immediate:!0})});return Promise.race([fadeInPromise,sleep(timeout)])}var bngNavigator=class{opts={root:null,container:null,bootscreen:null,north:null,clock:null,backgroundRgb:[50,50,50],roadColors:[`#FFFFFFFF`,`#A6A678FF`,`#A67854FF`],routeColor:`#3388EEFF`,markerColor:`#2C5CFF`,routes:!1,markers:!1,vehicles:!1,vehicleMarker:null,cameraColor:`#FD6A00`,vehicleColor:`#A3D39C`,rotate:!0,scale:1,pitch:0,offsetX:128,offsetY:64,resolution:4096,speedZoom:!1,speedOffset:0,speedPitch:!0,speedZoomIncrements:1,speedZoomMultiplier:2,speedZoomMax:200,speedZoomEffect:.15,hideBootscreen:!1};elms={root:document};mapScale=1;startup=!0;startupFallback=!0;layers={};layersLoadOrder=[bngNavLayerMap,bngNavLayerRoute,bngNavLayerMarkers,bngNavLayerVehicles,bngNavLayerElements,bngNavLayerBootscreen];setOptions(options){if(!(typeof options!=`object`||Array.isArray(options))){for(let key in this.opts)key in options&&(this.opts[key]=options[key]);for(let name in this.layers){let layer=this.layers[name];typeof layer.setOptions==`function`&&layer.setOptions(this.opts)}}}constructor(options){this.setOptions(options);for(let key of[`root`,`container`,`clock`,`north`,`bootscreen`]){let elm;typeof this.opts[key]==`string`?elm=this.elms.root.querySelector(this.opts[key]):this.opts[key]&&(elm=this.opts[key]),elm&&(elm instanceof HTMLElement||elm instanceof SVGElement)&&(this.elms[key]=elm)}if(!this.elms.root)throw Error(`Cannot find map root element`);if(!this.elms.container)throw Error(`Cannot find map container element`);this.elms.svg=new bngNavSVG(this.elms.container.children[0]);for(let cls of this.layersLoadOrder){let elms$4=cls.name===`map`?this.elms:{...this.elms,cvs:this.layers.map.cvs,routes:[this.layers.map.rwrapper,this.layers.map.rcanvas,this.layers.map.rcanvasCtx]};if(cls.canInit(elms$4,this.opts)){let dim=cls.name===`map`?this.mapScale:this.layers.map.dimensions,layer=new cls(elms$4,this.opts,dim);layer&&layer.name&&(this.layers[layer.name]=layer)}}this.layersLoadOrder=null;let expose=(layer,method,name=null)=>{this[name||method]=layer?layer[method].bind(layer):()=>{}};expose(this.layers.map,`setRotation`),expose(this.layers.map,`setLocation`),expose(this.layers.map,`setZoom`),expose(this.layers.map,`setScale`),expose(this.layers.map,`setSpeed`),expose(this.layers.map,`setOpacity`),expose(this.layers.route,`update`,`setRoute`),expose(this.layers.markers,`update`,`setMarkers`),expose(this.layers.bootscreen,`setImage`,`setBootscreenImage`)}update(data){data&&this.setup(data),this.layers.map.update(),this.layers.elements&&this.layers.elements.update(this.layers.map.state),this.layers.map.render()}setup(data){typeof data.terrainTiles==`object`&&!Array.isArray(data.terrainTiles)&&(data.terrainTiles=[]),this.layers.map.setMapSize(data)&&this.startupFallback?(this.startupFallback=!1,this.startup=!0):this.startup||(this.startupFallback=!0),this.startup&&(this.startup=!1,this.layers.map.applyMapSize(),this.layers.map.renderMap(data))}setData(data){if(!data||Object.keys(data).length===0){console.log(`Received empty map data`);return}this.layers.vehicles&&this.layers.vehicles.update(data),this.update(data),this.opts.hideBootscreen&&this.layers.bootscreen&&this.layers.bootscreen.hide()}updateData(data){typeof data==`object`&&(`x`in data&&`y`in data&&this.layers.map.setLocation(data.x,data.y,!1),`rotation`in data&&this.layers.map.setRotation(data.rotation,!1),`speed`in data&&this.layers.map.setSpeed(data.speed,!1),`ignitionLevel`in data&&this.layers.bootscreen&&this.layers.bootscreen.toggle(data.ignitionLevel<2),this.update())}},bngNavUtils=class{static truncDec(num,dec=2){let d=10**dec;return~~(num*d)/d}static setStyle(node,style){for(let name in style)node.style[name]=style[name]}},bngNavSVG=class{ns={svg:`http://www.w3.org/2000/svg`,xlink:`http://www.w3.org/1999/xlink`};root;constructor(root){if(!root||!root.tagName||root.tagName.toLowerCase()!==`svg`)throw Error(`Cannot access svg in a container`);this.root=root}setViewBox(viewBox){this.root.setAttributeNS(null,`viewBox`,viewBox)}createNode(tag,...args){let[attrs,parent]=args;parent||(attrs&&attrs instanceof SVGElement?(parent=attrs,attrs=null):parent=this.root);let node=document.createElementNS(this.ns.svg,tag);return attrs&&this.setAttrs(node,attrs),parent.appendChild(node),node}removeNode(node){node&&node.parentNode&&node.parentNode.removeChild(node)}setAttrs(node,attrs){for(let name in attrs){let ns=name.startsWith(`xlink:`)?this.ns.xlink:null;node.setAttributeNS(ns,name,attrs[name])}}clearNode(node){let elm;for(;elm=node.children[0];)node.removeChild(elm)}setStyle=bngNavUtils.setStyle;createCanvas(resolution){let fo=this.createNode(`foreignObject`);this.setStyle(fo,{position:`absolute`,x:`0`,y:`0`,width:`100%`,height:`100%`});let cvs=document.createElement(`canvas`);return cvs.width=resolution,cvs.height=resolution,fo.appendChild(cvs),[fo,cvs,cvs.getContext(`2d`)]}},bngNavLayerMap=class{static name=`map`;dimensions={ver:0,offset:512,scale:1,centerX:1024,centerY:1024,width:2048,height:2048,resScale:1};state={x:0,y:0,speed:0,scale:1,zoom:1,speedZoom:0,rotation:0,focusX:0,focusY:0,offsetX:0,offsetY:0};container;svg;wrapper;canvas;canvasCtx;rwrapper;rcanvas;rcanvasCtx;cvs;renders=[];rendered={terrainCvs:null,terrainCtx:null,roadsCvs:null,roadsCtx:null};terrainOpacity=1;gridGap=50;gridColour=`#cccccccc`;roadColors;resolution=2048;offsetX;offsetY;rotate;scale;pitch;speedPitch;speedOffset;speedZoom;speedZoomIncrements;speedZoomMultiplier;speedZoomMax;speedZoomEffect;static canInit(elms$4,opts){return!0}constructor({container,svg},opts,mapScale){this.name=this.constructor.name,this.container=container,this.svg=svg,[this.wrapper,this.canvas,this.canvasCtx]=svg.createCanvas(opts.resolution),[this.rwrapper,this.rcanvas,this.rcanvasCtx]=svg.createCanvas(opts.resolution);let that=this;this.rendered.terrainCvs=window.OffscreenCanvas?new window.OffscreenCanvas(1,1):document.createElement(`canvas`),this.rendered.terrainCtx=this.rendered.terrainCvs.getContext(`2d`),this.addRenderSource({passive:!0,source:this.rendered.terrainCvs,get alpha(){return that.terrainOpacity}}),this.rendered.roadsCvs=window.OffscreenCanvas?new window.OffscreenCanvas(1,1):document.createElement(`canvas`),this.rendered.roadsCtx=this.rendered.roadsCvs.getContext(`2d`),this.addRenderSource({passive:!0,source:this.rendered.roadsCvs}),this.dimensions.scale=mapScale,this.setOptions(opts),this.setOpacity(1)}setOptions(opts){this.bgRgb=opts.backgroundRgb.join(`, `),this.roadColors=opts.roadColors,this.resolution=opts.resolution,this.offsetX=opts.offsetX,this.offsetY=opts.offsetY,this.rotate=opts.rotate,this.scale=opts.scale,this.state.scale=this.scale*this.state.zoom,this.pitch=opts.pitch,this.speedPitch=opts.speedPitch,this.speedOffset=opts.speedOffset,this.speedZoom=opts.speedZoom,this.speedZoomIncrements=opts.speedZoomIncrements,this.speedZoomMultiplier=opts.speedZoomMultiplier,this.speedZoomMax=opts.speedZoomMax,this.speedZoomEffect=opts.speedZoomEffect}setLocation(x,y,doupdate=!0){this.state.x=-x,this.state.y=y,this.state.focusX=~~(this.state.x/this.dimensions.scale*this.dimensions.resScale),this.state.focusY=~~(this.state.y/this.dimensions.scale*this.dimensions.resScale),this.state.offsetX=this.dimensions.centerX-this.state.focusX,this.state.offsetY=this.dimensions.centerY-this.state.focusY,this.container.style.transformOrigin=`${this.state.offsetX}px ${this.state.offsetY}px`}setRotation(rotation,doupdate=!0){this.state.rotation=bngNavUtils.truncDec(rotation,3)%360,doupdate&&this.update()}setZoom(zoom,doupdate=!0){let fixed=(zoom-150)*2;this.setSpeed(fixed)}setScale(zoom,doupdate=!0){this.state.zoom=zoom,this.state.scale=this.scale*zoom}setSpeed(speed){this.state.speed=bngNavUtils.truncDec(speed,3),this.state.speed===0?this.state.speedZoom=0:this.state.speedZoom=bngNavUtils.truncDec(Math.min(1+this.state.speed*3.6*1.5,this.speedZoomMax)/this.speedZoomIncrements*this.speedZoomIncrements/this.speedZoomMax,3)}setOpacity(opacity){this.canvas.style.backgroundColor=`rgba(${this.bgRgb}, ${opacity})`,this.terrainOpacity=opacity}setMapSize(data){let res;return data.terrainTiles&&data.terrainTiles[0]&&data.terrainTiles[0].size?(this.setMapDimensions(data),res=!0):this.dimensions.ver===0&&(this.setMapDimensions(data),res=!1),res}setMapDimensions(data){let poss=[],tiles=data.terrainTiles||[];for(let tile of tiles)poss.push([tile.offset[0],-tile.offset[1]],[tile.offset[0]+tile.size[0],-tile.offset[1]+tile.size[1]]);for(let key in data.nodes)poss.push([data.nodes[key].pos[0],-data.nodes[key].pos[1]]);let minX=1/0,maxX=-1/0,minY=1/0,maxY=-1/0;for(let pos of poss)pos[0]/=this.dimensions.scale,pos[1]/=this.dimensions.scale,pos[0]maxX&&(maxX=pos[0]),pos[1]maxY&&(maxY=pos[1]);let dim={centerX:-minX,centerY:-minY,width:-minX+maxX,height:-minY+maxY};if((dim.centerX<0||dim.centerY<0)&&((isFinite(dim.centerX)||isFinite(dim.centerY))&&console.error(`Navigator: Invalid center point detected.`),dim.centerX=this.resolution/2,dim.centerY=this.resolution/2,dim.width=this.resolution,dim.height=this.resolution),this.dimensions.offset>0){let off=this.dimensions.offset;dim.centerX+=off,dim.width+=off*2,dim.centerY+=off,dim.height+=off*2}for(let key in dim.width>this.resolution||dim.height>this.resolution?(dim.resScale=this.resolution/(dim.width>dim.height?dim.width:dim.height),dim.width*=dim.resScale,dim.height*=dim.resScale,dim.centerX*=dim.resScale,dim.centerY*=dim.resScale,dim.offset=dim.offset>0?dim.offset/dim.resScale:0):dim.resScale=1,dim)key!==`resScale`&&(dim[key]=Math.round(dim[key]));let changed=!1;for(let key in dim)this.dimensions[key]!==dim[key]&&(this.dimensions[key]=dim[key],changed=!0);changed&&this.dimensions.ver++}applyMapSize(){this.container.style.width=this.dimensions.width+`px`,this.container.style.height=this.dimensions.height+`px`,this.svg.setViewBox(`0 0 ${this.dimensions.width} ${this.dimensions.height}`);let width$1=this.dimensions.width,height$1=this.dimensions.height;this.canvas.style.width=this.wrapper.style.width=width$1+`px`,this.canvas.style.height=this.wrapper.style.height=height$1+`px`,this.canvas.width=width$1,this.canvas.height=height$1,this.rendered.terrainCtx.clearRect(0,0,this.rendered.terrainCvs.width,this.rendered.terrainCvs.height),this.rendered.terrainCvs.width=width$1,this.rendered.terrainCvs.height=height$1,this.rendered.roadsCtx.clearRect(0,0,this.rendered.roadsCvs.width,this.rendered.roadsCvs.height),this.rendered.roadsCvs.width=width$1,this.rendered.roadsCvs.height=height$1}addRenderSource(source){if(typeof source!=`object`&&!(`source`in source))return console.error(`Navigator: Render source is invalid`);this.renders.push(source)}render(passive=!1){if(!passive)return;let ctx=this.canvasCtx,full=[0,0,this.dimensions.width,this.dimensions.height];ctx.clearRect(...full);for(let src of this.renders){if(!!src.passive!==passive||src.source.width===0||src.source.height===0)continue;let region=src.region;if(src.render){let res=src.render();typeof res==`object`&&`empty`in res&&(region={full:res,fullArray:[res.x1,res.y1,res.x2-res.x1,res.y2-res.y1]})}let pos=src.pos;pos||=(pos=region&&!region.full.empty?region.fullArray:full,[...pos,...pos]),src.alpha&&(ctx.globalAlpha=src.alpha),ctx.drawImage(src.source,...pos),ctx.globalAlpha=1}}renderMap(data){for(let key in this.drawTerrain(data,this.rendered.terrainCtx),data.nodes){let el=data.nodes[key];if(el.links)for(let key2 in el.links)el.links[key2].drivability=Math.round(el.links[key2].drivability*10)/10}this.drawRoads(data.nodes,0,.1,this.roadColors[2],this.rendered.roadsCtx),this.drawRoads(data.nodes,.1,.9,this.roadColors[1],this.rendered.roadsCtx),this.drawRoads(data.nodes,.9,1,this.roadColors[0],this.rendered.roadsCtx),this.render(!0)}drawTerrain(data,ctx){for(let x=this.gridGap;x{ctx.clearRect(...dest),ctx.drawImage(img,0,0,img.width,img.height,...dest),loading--,loading===0&&this.render(!0)}),img.addEventListener(`error`,()=>{console.error(`Navigator: Unable to load tile "${tile.file}"`),loading--,loading===0&&this.render(!0)}),img.src=tile.file}}createLine(ctx,p1,p2,color){Math.abs(p1.radius-p2.radius)>.2?this.varLine(ctx,p1.x,p1.y,p2.x,p2.y,p1.radius,p2.radius,color):(ctx.beginPath(),ctx.lineWidth=Math.max(p1.radius,p2.radius),ctx.lineCap=`round`,ctx.strokeStyle=color,ctx.moveTo(p1.x,p1.y),ctx.lineTo(p2.x,p2.y),ctx.stroke())}varLine(ctx,x1,y1,x2,y2,w1,w2,color){let dx=x2-x1,dy=y2-y1,length=dx*dx+dy*dy;if(length==0)return;length=Math.sqrt(length),w1*=.5,w2*=.5,dx/=length,dy/=length;let shiftx=-dy*w1,shifty=dx*w1;ctx.beginPath(),ctx.fillStyle=color,ctx.moveTo(x1+shiftx,y1+shifty),ctx.lineTo(x1-shiftx,y1-shifty),shiftx=-dy*w2,shifty=dx*w2,ctx.lineTo(x2-shiftx,y2-shifty),ctx.lineTo(x2+shiftx,y2+shifty),ctx.closePath(),ctx.arc(x1,y1,w1,0,2*Math.PI),ctx.arc(x2,y2,w2,0,2*Math.PI),ctx.fill()}drawRoads(nodes,drivabilityMin,drivabilityMax,colour,ctx){for(let key in nodes){let el=nodes[key];if(el.links)for(let key2 in el.links){let drivability=el.links[key2].drivability;if(drivabilitydrivabilityMax)continue;let el2=nodes[key2];this.createLine(ctx,{x:el.pos[0]/this.dimensions.scale*this.dimensions.resScale+this.dimensions.centerX,y:-el.pos[1]/this.dimensions.scale*this.dimensions.resScale+this.dimensions.centerY,radius:Math.min(Math.max(el.radius,0),5)*3*this.dimensions.resScale},{x:el2.pos[0]/this.dimensions.scale*this.dimensions.resScale+this.dimensions.centerX,y:-el2.pos[1]/this.dimensions.scale*this.dimensions.resScale+this.dimensions.centerY,radius:Math.min(Math.max(el2.radius,0),5)*3*this.dimensions.resScale},colour)}}}update(){let pos={x:-this.state.offsetX+this.offsetX,y:-this.state.offsetY+this.offsetY},rot={x:0,z:0};this.speedOffset>0&&(pos.y+=this.state.speedZoom*this.speedOffset),this.rotate&&(rot.x=this.pitch,this.speedPitch>0&&(rot.x+=this.speedPitch*this.state.speedZoom),rot.z=this.state.rotation);let scale=this.state.scale/this.dimensions.resScale;this.speedZoom&&(scale-=this.state.speedZoom*.1/this.dimensions.resScale),this.container.style.transform=`translate3d(${pos.x}px, ${pos.y}px, 0px) rotateX(${rot.x}deg) rotateZ(${rot.z}deg) scale(${scale})`}},bngNavLayerRoute=class{static name=`route`;dimensions;scale=1/3;lineWidth=10;color;wrapper;canvas;canvasCtx;current=null;static canInit(elms$4,opts){return!!opts.routes}constructor({routes,svg},opts,dimensions){this.name=this.constructor.name,[this.wrapper,this.canvas,this.canvasCtx]=routes||svg.createCanvas(opts.resolution),this.dimensions=dimensions,this.setOptions(opts)}setOptions(opts){this.color=opts.routeColor}update(data){if(this.dimver!==this.dimensions.ver){this.dimver=this.dimensions.ver;let width$1=this.dimensions.width,height$1=this.dimensions.height;this.canvas.style.width=this.wrapper.style.width=width$1+`px`,this.canvas.style.height=this.wrapper.style.height=height$1+`px`,this.canvas.width=this.canvasCtx.width=width$1*this.scale,this.canvas.height=this.canvasCtx.height=height$1*this.scale}if(!data||!data.markers){this.clear();return}this.current?this.optimiseAndDrawRoute(data,this.current):(this.clear(),data&&this.drawFreshRoute(data)),this.current=data.markers}clear(){this.current=null,this.canvasCtx.clearRect(0,0,this.canvas.width,this.canvas.height),this.canvasCtx.stroke()}drawFreshRoute(data){this.drawRoute({color:data.color,lineWidth:this.lineWidth,lineCap:`butt`,markers:data.markers,startIndex:0,drawFromIndex:2,drawToIndex:data.markers.length})}optimiseAndDrawRoute(data,prevMarkers){let markers$1=data.markers,ci=markers$1.length-2,pi=prevMarkers.length-2;for(;pi>=0&&ci>=0&&!(markers$1[ci]!==prevMarkers[pi]||markers$1[ci+1]!==prevMarkers[pi+1]);)ci-=2,pi-=2;(ci>=0||pi>=0)&&(this.canvasCtx.globalCompositeOperation=`destination-out`,this.drawRoute({color:data.color,lineWidth:this.lineWidth+2,markers:prevMarkers,drawToIndex:Math.min(pi+4,prevMarkers.length)}),this.canvasCtx.globalCompositeOperation=`source-over`,this.drawRoute({color:data.color,lineWidth:this.lineWidth,markers:data.markers,drawToIndex:Math.min(ci+6,data.markers.length)}))}drawRoute({color,lineWidth,lineCap=`round`,markers:markers$1,startIndex=0,drawFromIndex=0,drawToIndex}){let mapFac=this.scale/this.dimensions.scale,cx=this.dimensions.centerX*mapFac,cy=this.dimensions.centerY*mapFac;this.canvasCtx.beginPath(),this.canvasCtx.strokeStyle=color||this.color,this.canvasCtx.lineWidth=lineWidth*this.scale*this.dimensions.resScale,this.canvasCtx.lineCap=lineCap,this.canvasCtx.moveTo(markers$1[startIndex]*this.dimensions.resScale*mapFac+cx,-markers$1[startIndex+1]*this.dimensions.resScale*mapFac+cy);for(let i=drawFromIndex;iargs.map(arg=>typeof arg==`string`?arg:`[object]`)},createElementNS:{base:Document,getArgs:(...args)=>args.map(arg=>typeof arg==`string`?arg:`[object]`)},cloneNode:{base:Node,getArgs:deep=>[deep]},importNode:{base:Document,getArgs:(node,deep)=>[`[node]`,deep]},insertAdjacentHTML:{base:Element,getArgs:(position,text)=>[position,`[HTML:${text.length}chars]`]},innerHTML:{isSetter:!0,bases:[Element,HTMLElement],getArgs:value=>[`[HTML:${typeof value==`string`?value.length:0}chars]`]},outerHTML:{isSetter:!0,bases:[Element,HTMLElement],getArgs:value=>[`[HTML:${typeof value==`string`?value.length:0}chars]`]},appendChild:{base:Node,stats:`append`,getArgs:child=>[`[${child?.tagName||child?.nodeName||`node`}]`]},insertBefore:{base:Node,stats:`append`,getArgs:(newNode,referenceNode)=>[`[${newNode?.tagName||newNode?.nodeName||`node`}]`,`[${referenceNode?.tagName||referenceNode?.nodeName||`ref`}]`]},replaceChild:{base:Node,stats:`append`,getArgs:(newChild,oldChild)=>[`[${newChild?.tagName||newChild?.nodeName||`new`}]`,`[${oldChild?.tagName||oldChild?.nodeName||`old`}]`]},append:{base:Element,stats:`append`,getArgs:(...nodes)=>nodes.map(node=>`[${node?.tagName||node?.nodeName||typeof node==`string`?`text`:`node`}]`)},prepend:{base:Element,stats:`append`,getArgs:(...nodes)=>nodes.map(node=>`[${node?.tagName||node?.nodeName||typeof node==`string`?`text`:`node`}]`)},before:{base:Element,stats:`append`,getArgs:(...nodes)=>nodes.map(node=>`[${node?.tagName||node?.nodeName||typeof node==`string`?`text`:`node`}]`)},after:{base:Element,stats:`append`,getArgs:(...nodes)=>nodes.map(node=>`[${node?.tagName||node?.nodeName||typeof node==`string`?`text`:`node`}]`)}};function setupInterceptor(type){let interceptor=interceptors[type];if(interceptor.isSetter){let descriptor;if(interceptor.bases){for(let base of interceptor.bases)if(descriptor=Object.getOwnPropertyDescriptor(base.prototype,type),descriptor){interceptor.base=base;break}}descriptor&&(interceptor.original=descriptor)}else interceptor.original=interceptor.base.prototype[type];if(!interceptor.original){logger_default.warn(`No original for ${type}`);return}interceptor.call=(self$1,...args)=>{let stackTrace=captureStackTrace();if(stackTrace&&(includeAnonymousCalls||!stackTrace.hasAnonymous||stackTrace.filePaths.length>0)){let callData={type,timestamp:Date.now(),args:interceptor.getArgs(...args),stackTrace};if(interceptor.stats===`append`&&self$1)try{let mainContainer=self$1.closest?self$1.closest(`#mainContainer_apps`):null;if(mainContainer){let directChildDiv=self$1;for(;directChildDiv&&directChildDiv.parentNode&&directChildDiv.parentNode!==mainContainer;)directChildDiv=directChildDiv.parentNode;directChildDiv&&directChildDiv.parentNode===mainContainer&&directChildDiv.tagName===`DIV`&&(callData.uiAppInsertion={targetElement:directChildDiv})}}catch{}callQueue.push(callData)}if(interceptor.isSetter)interceptor.original.set.call(self$1,args[0]);else return interceptor.original.apply(self$1,args)},interceptor.isSetter?Object.defineProperty(interceptor.base.prototype,type,{get:interceptor.original.get,set:function(value){interceptor.call(this,value)},configurable:!0,enumerable:!0}):interceptor.base.prototype[type]=function(...args){return interceptor.call(this,...args)},interceptor.restore=()=>{interceptor.isSetter?Object.defineProperty(interceptor.base.prototype,type,{get:interceptor.original.get,set:interceptor.original.set,configurable:!0,enumerable:!0}):interceptor.base.prototype[type]=interceptor.original}}function captureStackTrace(){let stack$2=Error().stack;if(!stack$2)return null;let relevantLines=stack$2.split(` `).slice(STACK_TRACE_SKIP_LINES),filePaths=[],hasAnonymous=!1;for(let line of relevantLines){let match=line.match(STACK_TRACE_REGEX_FULL),functionName,filePath,lineNum,column;if(match)functionName=match[1],filePath=match[2],lineNum=match[3],column=match[4];else if(match=line.match(STACK_TRACE_REGEX),match)functionName=`anonymous`,filePath=match[1],lineNum=match[2],column=match[3];else continue;let isAnonymous=functionName?.includes(`anonymous`)||functionName?.includes(``)||!functionName||functionName.trim()===``;isAnonymous&&(hasAnonymous=!0,!includeAnonymousCalls)||filePaths.push({functionName,filePath,line:lineNum,column,isAnonymous})}return{filePaths,fullStack:stack$2,hasAnonymous}}async function processCallQueue(){if(statsProcessor.lastProcessTime=Date.now(),!(statsProcessor.isProcessing||callQueue.length===0)){statsProcessor.isProcessing=!0;try{let batch$1=callQueue.splice(0,Math.max(statsProcessor.batchSize,callQueue.length/5));statsProcessor.totalProcessed+=batch$1.length;for(let i=0;i{try{processCallQueue()}catch(error){logger_default.error(`Fatal error in DOM watchdog processing:`,error),destroy()}},statsProcessor.processInterval)}function getStats(){return{files:Object.fromEntries(statsProcessor.files),types:Object.fromEntries(statsProcessor.types),append:Object.fromEntries(statsProcessor.append)}}function clearStats(){statsProcessor.files.clear(),statsProcessor.types.clear(),statsProcessor.append.clear(),statsProcessor.uiApps.clear(),callQueue.length=0,statsProcessor.totalProcessed=0,statsProcessor.lastProcessTime=0,overlayActive&&updateOverlayDivs()}function restartTimer(){isInitialized&&startStatsProcessor()}function setIncludeAnonymousCalls(include){includeAnonymousCalls=include}var exposedFunctions=()=>({watchdogRecentCalls:getRecentCalls,watchdogCallChainStats:getCallChainStats,watchdogClearStats:clearStats,watchdogSetIncludeAnonymousCalls:setIncludeAnonymousCalls,watchdogDestroy:destroy,watchdogRestartTimer:restartTimer,watchdogUIAppsStats:getUIAppsStats,watchdogRefreshOverlay:refreshOverlay,watchdogStats:()=>{let stats=getStats(),format$2=obj=>Object.entries(obj).sort((a$1,b)=>b[1]-a$1[1]).map(([key,value])=>`${key}: ${value}`.replace(`\\`,`\\\\`)).join(`
  • `+b).split(R[0]).slice(1).map(R[3]?escape:inlineEscape).join(R[3]||`
    
  • `)+R[2]:f===`#`?``+inlineEscape(b.slice(f+1))+``:f===`<`?b:`

    `+inlineEscape(b)+`

    `}),h$1}function escape(t){return new Option(t).innerHTML}function inlineEscape(s){return escape(s).replace(/\\_/g,`⋿`).replace(/!\[([^\]]*)]\(([^(]+)\)/g,`$1`).replace(/\[([^\]]+)]\(([^(]+?)\)/g,`$1`.link(`$2`)).replace(/`([^`]+)`/g,`$1`).replace(/(\*\*|__)(?=\S)([^\r]*?\S[*_]*)\1/g,`$2`).replace(/(\*| _)(?=\S)([^\r]*?\S)\1/g,`$2`).replace(/⋿/g,`_`)}var content_exports=__export({bbcode:()=>bbcode_exports,markdown:()=>markdown_exports});const screenLocked=computed(()=>screenLockedState.value),loadingScreen=reactive({active:!1,visible:!1,fading:!1,shown:!1});var screenLockedState=ref(!1),loadingScreenStateWatcher=null,events;function screenLock(lock=!1){lock=!!lock,screenLockedState.value=lock;let body=document.body;body&&body.classList.toggle(`screen-locked`,lock)}async function startLoading$1(func){screenLock(!0),events||=useBridge().events,events.emit(`LoadingScreen`,{active:!0}),await nextTick(),setTimeout(()=>func(),500)}function linkLoadingScreenState(state){loadingScreenStateWatcher?.(),loadingScreenStateWatcher=watch([()=>state.active,()=>state.visible,()=>state.fading,()=>state.shown],([active,visible,fading,shown])=>{loadingScreen.active=active,loadingScreen.visible=visible,loadingScreen.fading=fading,loadingScreen.shown=shown,screenLock(active)})}function waitForLoadingScreenFadeIn$1(timeout=4e3){if(loadingScreen.visible&&!loadingScreen.fading)return;let fadeInPromise=new Promise(resolve$1=>{let unwatch=watch([()=>loadingScreen.visible,()=>loadingScreen.fading],([visible,fading])=>{visible&&!fading&&(unwatch(),resolve$1())},{immediate:!0})});return Promise.race([fadeInPromise,sleep(timeout)])}var bngNavigator=class{opts={root:null,container:null,bootscreen:null,north:null,clock:null,backgroundRgb:[50,50,50],roadColors:[`#FFFFFFFF`,`#A6A678FF`,`#A67854FF`],routeColor:`#3388EEFF`,markerColor:`#2C5CFF`,routes:!1,markers:!1,vehicles:!1,vehicleMarker:null,cameraColor:`#FD6A00`,vehicleColor:`#A3D39C`,rotate:!0,scale:1,pitch:0,offsetX:128,offsetY:64,resolution:4096,speedZoom:!1,speedOffset:0,speedPitch:!0,speedZoomIncrements:1,speedZoomMultiplier:2,speedZoomMax:200,speedZoomEffect:.15,hideBootscreen:!1};elms={root:document};mapScale=1;startup=!0;startupFallback=!0;layers={};layersLoadOrder=[bngNavLayerMap,bngNavLayerRoute,bngNavLayerMarkers,bngNavLayerVehicles,bngNavLayerElements,bngNavLayerBootscreen];setOptions(options){if(!(typeof options!=`object`||Array.isArray(options))){for(let key in this.opts)key in options&&(this.opts[key]=options[key]);for(let name in this.layers){let layer=this.layers[name];typeof layer.setOptions==`function`&&layer.setOptions(this.opts)}}}constructor(options){this.setOptions(options);for(let key of[`root`,`container`,`clock`,`north`,`bootscreen`]){let elm;typeof this.opts[key]==`string`?elm=this.elms.root.querySelector(this.opts[key]):this.opts[key]&&(elm=this.opts[key]),elm&&(elm instanceof HTMLElement||elm instanceof SVGElement)&&(this.elms[key]=elm)}if(!this.elms.root)throw Error(`Cannot find map root element`);if(!this.elms.container)throw Error(`Cannot find map container element`);this.elms.svg=new bngNavSVG(this.elms.container.children[0]);for(let cls of this.layersLoadOrder){let elms$4=cls.name===`map`?this.elms:{...this.elms,cvs:this.layers.map.cvs,routes:[this.layers.map.rwrapper,this.layers.map.rcanvas,this.layers.map.rcanvasCtx]};if(cls.canInit(elms$4,this.opts)){let dim=cls.name===`map`?this.mapScale:this.layers.map.dimensions,layer=new cls(elms$4,this.opts,dim);layer&&layer.name&&(this.layers[layer.name]=layer)}}this.layersLoadOrder=null;let expose=(layer,method,name=null)=>{this[name||method]=layer?layer[method].bind(layer):()=>{}};expose(this.layers.map,`setRotation`),expose(this.layers.map,`setLocation`),expose(this.layers.map,`setZoom`),expose(this.layers.map,`setScale`),expose(this.layers.map,`setSpeed`),expose(this.layers.map,`setOpacity`),expose(this.layers.route,`update`,`setRoute`),expose(this.layers.markers,`update`,`setMarkers`),expose(this.layers.bootscreen,`setImage`,`setBootscreenImage`)}update(data){data&&this.setup(data),this.layers.map.update(),this.layers.elements&&this.layers.elements.update(this.layers.map.state),this.layers.map.render()}setup(data){typeof data.terrainTiles==`object`&&!Array.isArray(data.terrainTiles)&&(data.terrainTiles=[]),this.layers.map.setMapSize(data)&&this.startupFallback?(this.startupFallback=!1,this.startup=!0):this.startup||(this.startupFallback=!0),this.startup&&(this.startup=!1,this.layers.map.applyMapSize(),this.layers.map.renderMap(data))}setData(data){if(!data||Object.keys(data).length===0){console.log(`Received empty map data`);return}this.layers.vehicles&&this.layers.vehicles.update(data),this.update(data),this.opts.hideBootscreen&&this.layers.bootscreen&&this.layers.bootscreen.hide()}updateData(data){typeof data==`object`&&(`x`in data&&`y`in data&&this.layers.map.setLocation(data.x,data.y,!1),`rotation`in data&&this.layers.map.setRotation(data.rotation,!1),`speed`in data&&this.layers.map.setSpeed(data.speed,!1),`ignitionLevel`in data&&this.layers.bootscreen&&this.layers.bootscreen.toggle(data.ignitionLevel<2),this.update())}},bngNavUtils=class{static truncDec(num,dec=2){let d=10**dec;return~~(num*d)/d}static setStyle(node,style){for(let name in style)node.style[name]=style[name]}},bngNavSVG=class{ns={svg:`http://www.w3.org/2000/svg`,xlink:`http://www.w3.org/1999/xlink`};root;constructor(root){if(!root||!root.tagName||root.tagName.toLowerCase()!==`svg`)throw Error(`Cannot access svg in a container`);this.root=root}setViewBox(viewBox){this.root.setAttributeNS(null,`viewBox`,viewBox)}createNode(tag,...args){let[attrs,parent]=args;parent||(attrs&&attrs instanceof SVGElement?(parent=attrs,attrs=null):parent=this.root);let node=document.createElementNS(this.ns.svg,tag);return attrs&&this.setAttrs(node,attrs),parent.appendChild(node),node}removeNode(node){node&&node.parentNode&&node.parentNode.removeChild(node)}setAttrs(node,attrs){for(let name in attrs){let ns=name.startsWith(`xlink:`)?this.ns.xlink:null;node.setAttributeNS(ns,name,attrs[name])}}clearNode(node){let elm;for(;elm=node.children[0];)node.removeChild(elm)}setStyle=bngNavUtils.setStyle;createCanvas(resolution){let fo=this.createNode(`foreignObject`);this.setStyle(fo,{position:`absolute`,x:`0`,y:`0`,width:`100%`,height:`100%`});let cvs=document.createElement(`canvas`);return cvs.width=resolution,cvs.height=resolution,fo.appendChild(cvs),[fo,cvs,cvs.getContext(`2d`)]}},bngNavLayerMap=class{static name=`map`;dimensions={ver:0,offset:512,scale:1,centerX:1024,centerY:1024,width:2048,height:2048,resScale:1};state={x:0,y:0,speed:0,scale:1,zoom:1,speedZoom:0,rotation:0,focusX:0,focusY:0,offsetX:0,offsetY:0};container;svg;wrapper;canvas;canvasCtx;rwrapper;rcanvas;rcanvasCtx;cvs;renders=[];rendered={terrainCvs:null,terrainCtx:null,roadsCvs:null,roadsCtx:null};terrainOpacity=1;gridGap=50;gridColour=`#cccccccc`;roadColors;resolution=2048;offsetX;offsetY;rotate;scale;pitch;speedPitch;speedOffset;speedZoom;speedZoomIncrements;speedZoomMultiplier;speedZoomMax;speedZoomEffect;static canInit(elms$4,opts){return!0}constructor({container,svg},opts,mapScale){this.name=this.constructor.name,this.container=container,this.svg=svg,[this.wrapper,this.canvas,this.canvasCtx]=svg.createCanvas(opts.resolution),[this.rwrapper,this.rcanvas,this.rcanvasCtx]=svg.createCanvas(opts.resolution);let that=this;this.rendered.terrainCvs=window.OffscreenCanvas?new window.OffscreenCanvas(1,1):document.createElement(`canvas`),this.rendered.terrainCtx=this.rendered.terrainCvs.getContext(`2d`),this.addRenderSource({passive:!0,source:this.rendered.terrainCvs,get alpha(){return that.terrainOpacity}}),this.rendered.roadsCvs=window.OffscreenCanvas?new window.OffscreenCanvas(1,1):document.createElement(`canvas`),this.rendered.roadsCtx=this.rendered.roadsCvs.getContext(`2d`),this.addRenderSource({passive:!0,source:this.rendered.roadsCvs}),this.dimensions.scale=mapScale,this.setOptions(opts),this.setOpacity(1)}setOptions(opts){this.bgRgb=opts.backgroundRgb.join(`, `),this.roadColors=opts.roadColors,this.resolution=opts.resolution,this.offsetX=opts.offsetX,this.offsetY=opts.offsetY,this.rotate=opts.rotate,this.scale=opts.scale,this.state.scale=this.scale*this.state.zoom,this.pitch=opts.pitch,this.speedPitch=opts.speedPitch,this.speedOffset=opts.speedOffset,this.speedZoom=opts.speedZoom,this.speedZoomIncrements=opts.speedZoomIncrements,this.speedZoomMultiplier=opts.speedZoomMultiplier,this.speedZoomMax=opts.speedZoomMax,this.speedZoomEffect=opts.speedZoomEffect}setLocation(x,y,doupdate=!0){this.state.x=-x,this.state.y=y,this.state.focusX=~~(this.state.x/this.dimensions.scale*this.dimensions.resScale),this.state.focusY=~~(this.state.y/this.dimensions.scale*this.dimensions.resScale),this.state.offsetX=this.dimensions.centerX-this.state.focusX,this.state.offsetY=this.dimensions.centerY-this.state.focusY,this.container.style.transformOrigin=`${this.state.offsetX}px ${this.state.offsetY}px`}setRotation(rotation,doupdate=!0){this.state.rotation=bngNavUtils.truncDec(rotation,3)%360,doupdate&&this.update()}setZoom(zoom,doupdate=!0){let fixed=(zoom-150)*2;this.setSpeed(fixed)}setScale(zoom,doupdate=!0){this.state.zoom=zoom,this.state.scale=this.scale*zoom}setSpeed(speed){this.state.speed=bngNavUtils.truncDec(speed,3),this.state.speed===0?this.state.speedZoom=0:this.state.speedZoom=bngNavUtils.truncDec(Math.min(1+this.state.speed*3.6*1.5,this.speedZoomMax)/this.speedZoomIncrements*this.speedZoomIncrements/this.speedZoomMax,3)}setOpacity(opacity){this.canvas.style.backgroundColor=`rgba(${this.bgRgb}, ${opacity})`,this.terrainOpacity=opacity}setMapSize(data){let res;return data.terrainTiles&&data.terrainTiles[0]&&data.terrainTiles[0].size?(this.setMapDimensions(data),res=!0):this.dimensions.ver===0&&(this.setMapDimensions(data),res=!1),res}setMapDimensions(data){let poss=[],tiles=data.terrainTiles||[];for(let tile of tiles)poss.push([tile.offset[0],-tile.offset[1]],[tile.offset[0]+tile.size[0],-tile.offset[1]+tile.size[1]]);for(let key in data.nodes)poss.push([data.nodes[key].pos[0],-data.nodes[key].pos[1]]);let minX=1/0,maxX=-1/0,minY=1/0,maxY=-1/0;for(let pos of poss)pos[0]/=this.dimensions.scale,pos[1]/=this.dimensions.scale,pos[0]maxX&&(maxX=pos[0]),pos[1]maxY&&(maxY=pos[1]);let dim={centerX:-minX,centerY:-minY,width:-minX+maxX,height:-minY+maxY};if((dim.centerX<0||dim.centerY<0)&&((isFinite(dim.centerX)||isFinite(dim.centerY))&&console.error(`Navigator: Invalid center point detected.`),dim.centerX=this.resolution/2,dim.centerY=this.resolution/2,dim.width=this.resolution,dim.height=this.resolution),this.dimensions.offset>0){let off=this.dimensions.offset;dim.centerX+=off,dim.width+=off*2,dim.centerY+=off,dim.height+=off*2}for(let key in dim.width>this.resolution||dim.height>this.resolution?(dim.resScale=this.resolution/(dim.width>dim.height?dim.width:dim.height),dim.width*=dim.resScale,dim.height*=dim.resScale,dim.centerX*=dim.resScale,dim.centerY*=dim.resScale,dim.offset=dim.offset>0?dim.offset/dim.resScale:0):dim.resScale=1,dim)key!==`resScale`&&(dim[key]=Math.round(dim[key]));let changed=!1;for(let key in dim)this.dimensions[key]!==dim[key]&&(this.dimensions[key]=dim[key],changed=!0);changed&&this.dimensions.ver++}applyMapSize(){this.container.style.width=this.dimensions.width+`px`,this.container.style.height=this.dimensions.height+`px`,this.svg.setViewBox(`0 0 ${this.dimensions.width} ${this.dimensions.height}`);let width$1=this.dimensions.width,height$1=this.dimensions.height;this.canvas.style.width=this.wrapper.style.width=width$1+`px`,this.canvas.style.height=this.wrapper.style.height=height$1+`px`,this.canvas.width=width$1,this.canvas.height=height$1,this.rendered.terrainCtx.clearRect(0,0,this.rendered.terrainCvs.width,this.rendered.terrainCvs.height),this.rendered.terrainCvs.width=width$1,this.rendered.terrainCvs.height=height$1,this.rendered.roadsCtx.clearRect(0,0,this.rendered.roadsCvs.width,this.rendered.roadsCvs.height),this.rendered.roadsCvs.width=width$1,this.rendered.roadsCvs.height=height$1}addRenderSource(source){if(typeof source!=`object`&&!(`source`in source))return console.error(`Navigator: Render source is invalid`);this.renders.push(source)}render(passive=!1){if(!passive)return;let ctx=this.canvasCtx,full=[0,0,this.dimensions.width,this.dimensions.height];ctx.clearRect(...full);for(let src of this.renders){if(!!src.passive!==passive||src.source.width===0||src.source.height===0)continue;let region=src.region;if(src.render){let res=src.render();typeof res==`object`&&`empty`in res&&(region={full:res,fullArray:[res.x1,res.y1,res.x2-res.x1,res.y2-res.y1]})}let pos=src.pos;pos||=(pos=region&&!region.full.empty?region.fullArray:full,[...pos,...pos]),src.alpha&&(ctx.globalAlpha=src.alpha),ctx.drawImage(src.source,...pos),ctx.globalAlpha=1}}renderMap(data){for(let key in this.drawTerrain(data,this.rendered.terrainCtx),data.nodes){let el=data.nodes[key];if(el.links)for(let key2 in el.links)el.links[key2].drivability=Math.round(el.links[key2].drivability*10)/10}this.drawRoads(data.nodes,0,.1,this.roadColors[2],this.rendered.roadsCtx),this.drawRoads(data.nodes,.1,.9,this.roadColors[1],this.rendered.roadsCtx),this.drawRoads(data.nodes,.9,1,this.roadColors[0],this.rendered.roadsCtx),this.render(!0)}drawTerrain(data,ctx){for(let x=this.gridGap;x{ctx.clearRect(...dest),ctx.drawImage(img,0,0,img.width,img.height,...dest),loading--,loading===0&&this.render(!0)}),img.addEventListener(`error`,()=>{console.error(`Navigator: Unable to load tile "${tile.file}"`),loading--,loading===0&&this.render(!0)}),img.src=tile.file}}createLine(ctx,p1,p2,color){Math.abs(p1.radius-p2.radius)>.2?this.varLine(ctx,p1.x,p1.y,p2.x,p2.y,p1.radius,p2.radius,color):(ctx.beginPath(),ctx.lineWidth=Math.max(p1.radius,p2.radius),ctx.lineCap=`round`,ctx.strokeStyle=color,ctx.moveTo(p1.x,p1.y),ctx.lineTo(p2.x,p2.y),ctx.stroke())}varLine(ctx,x1,y1,x2,y2,w1,w2,color){let dx=x2-x1,dy=y2-y1,length=dx*dx+dy*dy;if(length==0)return;length=Math.sqrt(length),w1*=.5,w2*=.5,dx/=length,dy/=length;let shiftx=-dy*w1,shifty=dx*w1;ctx.beginPath(),ctx.fillStyle=color,ctx.moveTo(x1+shiftx,y1+shifty),ctx.lineTo(x1-shiftx,y1-shifty),shiftx=-dy*w2,shifty=dx*w2,ctx.lineTo(x2-shiftx,y2-shifty),ctx.lineTo(x2+shiftx,y2+shifty),ctx.closePath(),ctx.arc(x1,y1,w1,0,2*Math.PI),ctx.arc(x2,y2,w2,0,2*Math.PI),ctx.fill()}drawRoads(nodes,drivabilityMin,drivabilityMax,colour,ctx){for(let key in nodes){let el=nodes[key];if(el.links)for(let key2 in el.links){let drivability=el.links[key2].drivability;if(drivabilitydrivabilityMax)continue;let el2=nodes[key2];this.createLine(ctx,{x:el.pos[0]/this.dimensions.scale*this.dimensions.resScale+this.dimensions.centerX,y:-el.pos[1]/this.dimensions.scale*this.dimensions.resScale+this.dimensions.centerY,radius:Math.min(Math.max(el.radius,0),5)*3*this.dimensions.resScale},{x:el2.pos[0]/this.dimensions.scale*this.dimensions.resScale+this.dimensions.centerX,y:-el2.pos[1]/this.dimensions.scale*this.dimensions.resScale+this.dimensions.centerY,radius:Math.min(Math.max(el2.radius,0),5)*3*this.dimensions.resScale},colour)}}}update(){let pos={x:-this.state.offsetX+this.offsetX,y:-this.state.offsetY+this.offsetY},rot={x:0,z:0};this.speedOffset>0&&(pos.y+=this.state.speedZoom*this.speedOffset),this.rotate&&(rot.x=this.pitch,this.speedPitch>0&&(rot.x+=this.speedPitch*this.state.speedZoom),rot.z=this.state.rotation);let scale=this.state.scale/this.dimensions.resScale;this.speedZoom&&(scale-=this.state.speedZoom*.1/this.dimensions.resScale),this.container.style.transform=`translate3d(${pos.x}px, ${pos.y}px, 0px) rotateX(${rot.x}deg) rotateZ(${rot.z}deg) scale(${scale})`}},bngNavLayerRoute=class{static name=`route`;dimensions;scale=1/3;lineWidth=10;color;wrapper;canvas;canvasCtx;current=null;static canInit(elms$4,opts){return!!opts.routes}constructor({routes,svg},opts,dimensions){this.name=this.constructor.name,[this.wrapper,this.canvas,this.canvasCtx]=routes||svg.createCanvas(opts.resolution),this.dimensions=dimensions,this.setOptions(opts)}setOptions(opts){this.color=opts.routeColor}update(data){if(this.dimver!==this.dimensions.ver){this.dimver=this.dimensions.ver;let width$1=this.dimensions.width,height$1=this.dimensions.height;this.canvas.style.width=this.wrapper.style.width=width$1+`px`,this.canvas.style.height=this.wrapper.style.height=height$1+`px`,this.canvas.width=this.canvasCtx.width=width$1*this.scale,this.canvas.height=this.canvasCtx.height=height$1*this.scale}if(!data||!data.markers){this.clear();return}this.current?this.optimiseAndDrawRoute(data,this.current):(this.clear(),data&&this.drawFreshRoute(data)),this.current=data.markers}clear(){this.current=null,this.canvasCtx.clearRect(0,0,this.canvas.width,this.canvas.height),this.canvasCtx.stroke()}drawFreshRoute(data){this.drawRoute({color:data.color,lineWidth:this.lineWidth,lineCap:`butt`,markers:data.markers,startIndex:0,drawFromIndex:2,drawToIndex:data.markers.length})}optimiseAndDrawRoute(data,prevMarkers){let markers$1=data.markers,ci=markers$1.length-2,pi=prevMarkers.length-2;for(;pi>=0&&ci>=0&&!(markers$1[ci]!==prevMarkers[pi]||markers$1[ci+1]!==prevMarkers[pi+1]);)ci-=2,pi-=2;(ci>=0||pi>=0)&&(this.canvasCtx.globalCompositeOperation=`destination-out`,this.drawRoute({color:data.color,lineWidth:this.lineWidth+2,markers:prevMarkers,drawToIndex:Math.min(pi+4,prevMarkers.length)}),this.canvasCtx.globalCompositeOperation=`source-over`,this.drawRoute({color:data.color,lineWidth:this.lineWidth,markers:data.markers,drawToIndex:Math.min(ci+6,data.markers.length)}))}drawRoute({color,lineWidth,lineCap=`round`,markers:markers$1,startIndex=0,drawFromIndex=0,drawToIndex}){let mapFac=this.scale/this.dimensions.scale,cx=this.dimensions.centerX*mapFac,cy=this.dimensions.centerY*mapFac;this.canvasCtx.beginPath(),this.canvasCtx.strokeStyle=color||this.color,this.canvasCtx.lineWidth=lineWidth*this.scale*this.dimensions.resScale,this.canvasCtx.lineCap=lineCap,this.canvasCtx.moveTo(markers$1[startIndex]*this.dimensions.resScale*mapFac+cx,-markers$1[startIndex+1]*this.dimensions.resScale*mapFac+cy);for(let i=drawFromIndex;iargs.map(arg=>typeof arg==`string`?arg:`[object]`)},createElementNS:{base:Document,getArgs:(...args)=>args.map(arg=>typeof arg==`string`?arg:`[object]`)},cloneNode:{base:Node,getArgs:deep=>[deep]},importNode:{base:Document,getArgs:(node,deep)=>[`[node]`,deep]},insertAdjacentHTML:{base:Element,getArgs:(position,text)=>[position,`[HTML:${text.length}chars]`]},innerHTML:{isSetter:!0,bases:[Element,HTMLElement],getArgs:value=>[`[HTML:${typeof value==`string`?value.length:0}chars]`]},outerHTML:{isSetter:!0,bases:[Element,HTMLElement],getArgs:value=>[`[HTML:${typeof value==`string`?value.length:0}chars]`]},appendChild:{base:Node,stats:`append`,getArgs:child=>[`[${child?.tagName||child?.nodeName||`node`}]`]},insertBefore:{base:Node,stats:`append`,getArgs:(newNode,referenceNode)=>[`[${newNode?.tagName||newNode?.nodeName||`node`}]`,`[${referenceNode?.tagName||referenceNode?.nodeName||`ref`}]`]},replaceChild:{base:Node,stats:`append`,getArgs:(newChild,oldChild)=>[`[${newChild?.tagName||newChild?.nodeName||`new`}]`,`[${oldChild?.tagName||oldChild?.nodeName||`old`}]`]},append:{base:Element,stats:`append`,getArgs:(...nodes)=>nodes.map(node=>`[${node?.tagName||node?.nodeName||typeof node==`string`?`text`:`node`}]`)},prepend:{base:Element,stats:`append`,getArgs:(...nodes)=>nodes.map(node=>`[${node?.tagName||node?.nodeName||typeof node==`string`?`text`:`node`}]`)},before:{base:Element,stats:`append`,getArgs:(...nodes)=>nodes.map(node=>`[${node?.tagName||node?.nodeName||typeof node==`string`?`text`:`node`}]`)},after:{base:Element,stats:`append`,getArgs:(...nodes)=>nodes.map(node=>`[${node?.tagName||node?.nodeName||typeof node==`string`?`text`:`node`}]`)}};function setupInterceptor(type){let interceptor=interceptors[type];if(interceptor.isSetter){let descriptor;if(interceptor.bases){for(let base of interceptor.bases)if(descriptor=Object.getOwnPropertyDescriptor(base.prototype,type),descriptor){interceptor.base=base;break}}descriptor&&(interceptor.original=descriptor)}else interceptor.original=interceptor.base.prototype[type];if(!interceptor.original){logger_default.warn(`No original for ${type}`);return}interceptor.call=(self$1,...args)=>{let stackTrace=captureStackTrace();if(stackTrace&&(includeAnonymousCalls||!stackTrace.hasAnonymous||stackTrace.filePaths.length>0)){let callData={type,timestamp:Date.now(),args:interceptor.getArgs(...args),stackTrace};if(interceptor.stats===`append`&&self$1)try{let mainContainer=self$1.closest?self$1.closest(`#mainContainer_apps`):null;if(mainContainer){let directChildDiv=self$1;for(;directChildDiv&&directChildDiv.parentNode&&directChildDiv.parentNode!==mainContainer;)directChildDiv=directChildDiv.parentNode;directChildDiv&&directChildDiv.parentNode===mainContainer&&directChildDiv.tagName===`DIV`&&(callData.uiAppInsertion={targetElement:directChildDiv})}}catch{}callQueue.push(callData)}if(interceptor.isSetter)interceptor.original.set.call(self$1,args[0]);else return interceptor.original.apply(self$1,args)},interceptor.isSetter?Object.defineProperty(interceptor.base.prototype,type,{get:interceptor.original.get,set:function(value){interceptor.call(this,value)},configurable:!0,enumerable:!0}):interceptor.base.prototype[type]=function(...args){return interceptor.call(this,...args)},interceptor.restore=()=>{interceptor.isSetter?Object.defineProperty(interceptor.base.prototype,type,{get:interceptor.original.get,set:interceptor.original.set,configurable:!0,enumerable:!0}):interceptor.base.prototype[type]=interceptor.original}}function captureStackTrace(){let stack$2=Error().stack;if(!stack$2)return null;let relevantLines=stack$2.split(` `).slice(STACK_TRACE_SKIP_LINES),filePaths=[],hasAnonymous=!1;for(let line of relevantLines){let match=line.match(STACK_TRACE_REGEX_FULL),functionName,filePath,lineNum,column;if(match)functionName=match[1],filePath=match[2],lineNum=match[3],column=match[4];else if(match=line.match(STACK_TRACE_REGEX),match)functionName=`anonymous`,filePath=match[1],lineNum=match[2],column=match[3];else continue;let isAnonymous=functionName?.includes(`anonymous`)||functionName?.includes(``)||!functionName||functionName.trim()===``;isAnonymous&&(hasAnonymous=!0,!includeAnonymousCalls)||filePaths.push({functionName,filePath,line:lineNum,column,isAnonymous})}return{filePaths,fullStack:stack$2,hasAnonymous}}async function processCallQueue(){if(statsProcessor.lastProcessTime=Date.now(),!(statsProcessor.isProcessing||callQueue.length===0)){statsProcessor.isProcessing=!0;try{let batch$1=callQueue.splice(0,Math.max(statsProcessor.batchSize,callQueue.length/5));statsProcessor.totalProcessed+=batch$1.length;for(let i=0;i{try{processCallQueue()}catch(error){logger_default.error(`Fatal error in DOM watchdog processing:`,error),destroy()}},statsProcessor.processInterval)}function getStats(){return{files:Object.fromEntries(statsProcessor.files),types:Object.fromEntries(statsProcessor.types),append:Object.fromEntries(statsProcessor.append)}}function clearStats(){statsProcessor.files.clear(),statsProcessor.types.clear(),statsProcessor.append.clear(),statsProcessor.uiApps.clear(),callQueue.length=0,statsProcessor.totalProcessed=0,statsProcessor.lastProcessTime=0,overlayActive&&updateOverlayDivs()}function restartTimer(){isInitialized&&startStatsProcessor()}function setIncludeAnonymousCalls(include){includeAnonymousCalls=include}var exposedFunctions=()=>({watchdogRecentCalls:getRecentCalls,watchdogCallChainStats:getCallChainStats,watchdogClearStats:clearStats,watchdogSetIncludeAnonymousCalls:setIncludeAnonymousCalls,watchdogDestroy:destroy,watchdogRestartTimer:restartTimer,watchdogUIAppsStats:getUIAppsStats,watchdogRefreshOverlay:refreshOverlay,watchdogStats:()=>{let stats=getStats(),format$2=obj=>Object.entries(obj).sort((a$1,b)=>b[1]-a$1[1]).map(([key,value])=>`${key}: ${value}`.replace(`\\`,`\\\\`)).join(`
  • `+b).split(R[0]).slice(1).map(R[3]?escape:inlineEscape).join(R[3]||`
    
  • `)+R[2]:f===`#`?``+inlineEscape(b.slice(f+1))+``:f===`<`?b:`

    `+inlineEscape(b)+`

    `}),h$1}function escape(t){return new Option(t).innerHTML}function inlineEscape(s){return escape(s).replace(/\\_/g,`⋿`).replace(/!\[([^\]]*)]\(([^(]+)\)/g,`$1`).replace(/\[([^\]]+)]\(([^(]+?)\)/g,`$1`.link(`$2`)).replace(/`([^`]+)`/g,`$1`).replace(/(\*\*|__)(?=\S)([^\r]*?\S[*_]*)\1/g,`$2`).replace(/(\*| _)(?=\S)([^\r]*?\S)\1/g,`$2`).replace(/⋿/g,`_`)}var content_exports=__export({bbcode:()=>bbcode_exports,markdown:()=>markdown_exports});const screenLocked=computed(()=>screenLockedState.value),loadingScreen=reactive({active:!1,visible:!1,fading:!1,shown:!1});var screenLockedState=ref(!1),loadingScreenStateWatcher=null,events;function screenLock(lock=!1){lock=!!lock,screenLockedState.value=lock;let body=document.body;body&&body.classList.toggle(`screen-locked`,lock)}async function startLoading$1(func){screenLock(!0),events||=useBridge().events,events.emit(`LoadingScreen`,{active:!0}),await nextTick(),setTimeout(()=>func(),500)}function linkLoadingScreenState(state){loadingScreenStateWatcher?.(),loadingScreenStateWatcher=watch([()=>state.active,()=>state.visible,()=>state.fading,()=>state.shown],([active,visible,fading,shown])=>{loadingScreen.active=active,loadingScreen.visible=visible,loadingScreen.fading=fading,loadingScreen.shown=shown,screenLock(active)})}function waitForLoadingScreenFadeIn$1(timeout=4e3){if(loadingScreen.visible&&!loadingScreen.fading)return;let fadeInPromise=new Promise(resolve$1=>{let unwatch=watch([()=>loadingScreen.visible,()=>loadingScreen.fading],([visible,fading])=>{visible&&!fading&&(unwatch(),resolve$1())},{immediate:!0})});return Promise.race([fadeInPromise,sleep(timeout)])}var bngNavigator=class{opts={root:null,container:null,bootscreen:null,north:null,clock:null,backgroundRgb:[50,50,50],roadColors:[`#FFFFFFFF`,`#A6A678FF`,`#A67854FF`],routeColor:`#3388EEFF`,markerColor:`#2C5CFF`,routes:!1,markers:!1,vehicles:!1,vehicleMarker:null,cameraColor:`#FD6A00`,vehicleColor:`#A3D39C`,rotate:!0,scale:1,pitch:0,offsetX:128,offsetY:64,resolution:4096,speedZoom:!1,speedOffset:0,speedPitch:!0,speedZoomIncrements:1,speedZoomMultiplier:2,speedZoomMax:200,speedZoomEffect:.15,hideBootscreen:!1};elms={root:document};mapScale=1;startup=!0;startupFallback=!0;layers={};layersLoadOrder=[bngNavLayerMap,bngNavLayerRoute,bngNavLayerMarkers,bngNavLayerVehicles,bngNavLayerElements,bngNavLayerBootscreen];setOptions(options){if(!(typeof options!=`object`||Array.isArray(options))){for(let key in this.opts)key in options&&(this.opts[key]=options[key]);for(let name in this.layers){let layer=this.layers[name];typeof layer.setOptions==`function`&&layer.setOptions(this.opts)}}}constructor(options){this.setOptions(options);for(let key of[`root`,`container`,`clock`,`north`,`bootscreen`]){let elm;typeof this.opts[key]==`string`?elm=this.elms.root.querySelector(this.opts[key]):this.opts[key]&&(elm=this.opts[key]),elm&&(elm instanceof HTMLElement||elm instanceof SVGElement)&&(this.elms[key]=elm)}if(!this.elms.root)throw Error(`Cannot find map root element`);if(!this.elms.container)throw Error(`Cannot find map container element`);this.elms.svg=new bngNavSVG(this.elms.container.children[0]);for(let cls of this.layersLoadOrder){let elms$4=cls.name===`map`?this.elms:{...this.elms,cvs:this.layers.map.cvs,routes:[this.layers.map.rwrapper,this.layers.map.rcanvas,this.layers.map.rcanvasCtx]};if(cls.canInit(elms$4,this.opts)){let dim=cls.name===`map`?this.mapScale:this.layers.map.dimensions,layer=new cls(elms$4,this.opts,dim);layer&&layer.name&&(this.layers[layer.name]=layer)}}this.layersLoadOrder=null;let expose=(layer,method,name=null)=>{this[name||method]=layer?layer[method].bind(layer):()=>{}};expose(this.layers.map,`setRotation`),expose(this.layers.map,`setLocation`),expose(this.layers.map,`setZoom`),expose(this.layers.map,`setScale`),expose(this.layers.map,`setSpeed`),expose(this.layers.map,`setOpacity`),expose(this.layers.route,`update`,`setRoute`),expose(this.layers.markers,`update`,`setMarkers`),expose(this.layers.bootscreen,`setImage`,`setBootscreenImage`)}update(data){data&&this.setup(data),this.layers.map.update(),this.layers.elements&&this.layers.elements.update(this.layers.map.state),this.layers.map.render()}setup(data){typeof data.terrainTiles==`object`&&!Array.isArray(data.terrainTiles)&&(data.terrainTiles=[]),this.layers.map.setMapSize(data)&&this.startupFallback?(this.startupFallback=!1,this.startup=!0):this.startup||(this.startupFallback=!0),this.startup&&(this.startup=!1,this.layers.map.applyMapSize(),this.layers.map.renderMap(data))}setData(data){if(!data||Object.keys(data).length===0){console.log(`Received empty map data`);return}this.layers.vehicles&&this.layers.vehicles.update(data),this.update(data),this.opts.hideBootscreen&&this.layers.bootscreen&&this.layers.bootscreen.hide()}updateData(data){typeof data==`object`&&(`x`in data&&`y`in data&&this.layers.map.setLocation(data.x,data.y,!1),`rotation`in data&&this.layers.map.setRotation(data.rotation,!1),`speed`in data&&this.layers.map.setSpeed(data.speed,!1),`ignitionLevel`in data&&this.layers.bootscreen&&this.layers.bootscreen.toggle(data.ignitionLevel<2),this.update())}},bngNavUtils=class{static truncDec(num,dec=2){let d=10**dec;return~~(num*d)/d}static setStyle(node,style){for(let name in style)node.style[name]=style[name]}},bngNavSVG=class{ns={svg:`http://www.w3.org/2000/svg`,xlink:`http://www.w3.org/1999/xlink`};root;constructor(root){if(!root||!root.tagName||root.tagName.toLowerCase()!==`svg`)throw Error(`Cannot access svg in a container`);this.root=root}setViewBox(viewBox){this.root.setAttributeNS(null,`viewBox`,viewBox)}createNode(tag,...args){let[attrs,parent]=args;parent||(attrs&&attrs instanceof SVGElement?(parent=attrs,attrs=null):parent=this.root);let node=document.createElementNS(this.ns.svg,tag);return attrs&&this.setAttrs(node,attrs),parent.appendChild(node),node}removeNode(node){node&&node.parentNode&&node.parentNode.removeChild(node)}setAttrs(node,attrs){for(let name in attrs){let ns=name.startsWith(`xlink:`)?this.ns.xlink:null;node.setAttributeNS(ns,name,attrs[name])}}clearNode(node){let elm;for(;elm=node.children[0];)node.removeChild(elm)}setStyle=bngNavUtils.setStyle;createCanvas(resolution){let fo=this.createNode(`foreignObject`);this.setStyle(fo,{position:`absolute`,x:`0`,y:`0`,width:`100%`,height:`100%`});let cvs=document.createElement(`canvas`);return cvs.width=resolution,cvs.height=resolution,fo.appendChild(cvs),[fo,cvs,cvs.getContext(`2d`)]}},bngNavLayerMap=class{static name=`map`;dimensions={ver:0,offset:512,scale:1,centerX:1024,centerY:1024,width:2048,height:2048,resScale:1};state={x:0,y:0,speed:0,scale:1,zoom:1,speedZoom:0,rotation:0,focusX:0,focusY:0,offsetX:0,offsetY:0};container;svg;wrapper;canvas;canvasCtx;rwrapper;rcanvas;rcanvasCtx;cvs;renders=[];rendered={terrainCvs:null,terrainCtx:null,roadsCvs:null,roadsCtx:null};terrainOpacity=1;gridGap=50;gridColour=`#cccccccc`;roadColors;resolution=2048;offsetX;offsetY;rotate;scale;pitch;speedPitch;speedOffset;speedZoom;speedZoomIncrements;speedZoomMultiplier;speedZoomMax;speedZoomEffect;static canInit(elms$4,opts){return!0}constructor({container,svg},opts,mapScale){this.name=this.constructor.name,this.container=container,this.svg=svg,[this.wrapper,this.canvas,this.canvasCtx]=svg.createCanvas(opts.resolution),[this.rwrapper,this.rcanvas,this.rcanvasCtx]=svg.createCanvas(opts.resolution);let that=this;this.rendered.terrainCvs=window.OffscreenCanvas?new window.OffscreenCanvas(1,1):document.createElement(`canvas`),this.rendered.terrainCtx=this.rendered.terrainCvs.getContext(`2d`),this.addRenderSource({passive:!0,source:this.rendered.terrainCvs,get alpha(){return that.terrainOpacity}}),this.rendered.roadsCvs=window.OffscreenCanvas?new window.OffscreenCanvas(1,1):document.createElement(`canvas`),this.rendered.roadsCtx=this.rendered.roadsCvs.getContext(`2d`),this.addRenderSource({passive:!0,source:this.rendered.roadsCvs}),this.dimensions.scale=mapScale,this.setOptions(opts),this.setOpacity(1)}setOptions(opts){this.bgRgb=opts.backgroundRgb.join(`, `),this.roadColors=opts.roadColors,this.resolution=opts.resolution,this.offsetX=opts.offsetX,this.offsetY=opts.offsetY,this.rotate=opts.rotate,this.scale=opts.scale,this.state.scale=this.scale*this.state.zoom,this.pitch=opts.pitch,this.speedPitch=opts.speedPitch,this.speedOffset=opts.speedOffset,this.speedZoom=opts.speedZoom,this.speedZoomIncrements=opts.speedZoomIncrements,this.speedZoomMultiplier=opts.speedZoomMultiplier,this.speedZoomMax=opts.speedZoomMax,this.speedZoomEffect=opts.speedZoomEffect}setLocation(x,y,doupdate=!0){this.state.x=-x,this.state.y=y,this.state.focusX=~~(this.state.x/this.dimensions.scale*this.dimensions.resScale),this.state.focusY=~~(this.state.y/this.dimensions.scale*this.dimensions.resScale),this.state.offsetX=this.dimensions.centerX-this.state.focusX,this.state.offsetY=this.dimensions.centerY-this.state.focusY,this.container.style.transformOrigin=`${this.state.offsetX}px ${this.state.offsetY}px`}setRotation(rotation,doupdate=!0){this.state.rotation=bngNavUtils.truncDec(rotation,3)%360,doupdate&&this.update()}setZoom(zoom,doupdate=!0){let fixed=(zoom-150)*2;this.setSpeed(fixed)}setScale(zoom,doupdate=!0){this.state.zoom=zoom,this.state.scale=this.scale*zoom}setSpeed(speed){this.state.speed=bngNavUtils.truncDec(speed,3),this.state.speed===0?this.state.speedZoom=0:this.state.speedZoom=bngNavUtils.truncDec(Math.min(1+this.state.speed*3.6*1.5,this.speedZoomMax)/this.speedZoomIncrements*this.speedZoomIncrements/this.speedZoomMax,3)}setOpacity(opacity){this.canvas.style.backgroundColor=`rgba(${this.bgRgb}, ${opacity})`,this.terrainOpacity=opacity}setMapSize(data){let res;return data.terrainTiles&&data.terrainTiles[0]&&data.terrainTiles[0].size?(this.setMapDimensions(data),res=!0):this.dimensions.ver===0&&(this.setMapDimensions(data),res=!1),res}setMapDimensions(data){let poss=[],tiles=data.terrainTiles||[];for(let tile of tiles)poss.push([tile.offset[0],-tile.offset[1]],[tile.offset[0]+tile.size[0],-tile.offset[1]+tile.size[1]]);for(let key in data.nodes)poss.push([data.nodes[key].pos[0],-data.nodes[key].pos[1]]);let minX=1/0,maxX=-1/0,minY=1/0,maxY=-1/0;for(let pos of poss)pos[0]/=this.dimensions.scale,pos[1]/=this.dimensions.scale,pos[0]maxX&&(maxX=pos[0]),pos[1]maxY&&(maxY=pos[1]);let dim={centerX:-minX,centerY:-minY,width:-minX+maxX,height:-minY+maxY};if((dim.centerX<0||dim.centerY<0)&&((isFinite(dim.centerX)||isFinite(dim.centerY))&&console.error(`Navigator: Invalid center point detected.`),dim.centerX=this.resolution/2,dim.centerY=this.resolution/2,dim.width=this.resolution,dim.height=this.resolution),this.dimensions.offset>0){let off=this.dimensions.offset;dim.centerX+=off,dim.width+=off*2,dim.centerY+=off,dim.height+=off*2}for(let key in dim.width>this.resolution||dim.height>this.resolution?(dim.resScale=this.resolution/(dim.width>dim.height?dim.width:dim.height),dim.width*=dim.resScale,dim.height*=dim.resScale,dim.centerX*=dim.resScale,dim.centerY*=dim.resScale,dim.offset=dim.offset>0?dim.offset/dim.resScale:0):dim.resScale=1,dim)key!==`resScale`&&(dim[key]=Math.round(dim[key]));let changed=!1;for(let key in dim)this.dimensions[key]!==dim[key]&&(this.dimensions[key]=dim[key],changed=!0);changed&&this.dimensions.ver++}applyMapSize(){this.container.style.width=this.dimensions.width+`px`,this.container.style.height=this.dimensions.height+`px`,this.svg.setViewBox(`0 0 ${this.dimensions.width} ${this.dimensions.height}`);let width$1=this.dimensions.width,height$1=this.dimensions.height;this.canvas.style.width=this.wrapper.style.width=width$1+`px`,this.canvas.style.height=this.wrapper.style.height=height$1+`px`,this.canvas.width=width$1,this.canvas.height=height$1,this.rendered.terrainCtx.clearRect(0,0,this.rendered.terrainCvs.width,this.rendered.terrainCvs.height),this.rendered.terrainCvs.width=width$1,this.rendered.terrainCvs.height=height$1,this.rendered.roadsCtx.clearRect(0,0,this.rendered.roadsCvs.width,this.rendered.roadsCvs.height),this.rendered.roadsCvs.width=width$1,this.rendered.roadsCvs.height=height$1}addRenderSource(source){if(typeof source!=`object`&&!(`source`in source))return console.error(`Navigator: Render source is invalid`);this.renders.push(source)}render(passive=!1){if(!passive)return;let ctx=this.canvasCtx,full=[0,0,this.dimensions.width,this.dimensions.height];ctx.clearRect(...full);for(let src of this.renders){if(!!src.passive!==passive||src.source.width===0||src.source.height===0)continue;let region=src.region;if(src.render){let res=src.render();typeof res==`object`&&`empty`in res&&(region={full:res,fullArray:[res.x1,res.y1,res.x2-res.x1,res.y2-res.y1]})}let pos=src.pos;pos||=(pos=region&&!region.full.empty?region.fullArray:full,[...pos,...pos]),src.alpha&&(ctx.globalAlpha=src.alpha),ctx.drawImage(src.source,...pos),ctx.globalAlpha=1}}renderMap(data){for(let key in this.drawTerrain(data,this.rendered.terrainCtx),data.nodes){let el=data.nodes[key];if(el.links)for(let key2 in el.links)el.links[key2].drivability=Math.round(el.links[key2].drivability*10)/10}this.drawRoads(data.nodes,0,.1,this.roadColors[2],this.rendered.roadsCtx),this.drawRoads(data.nodes,.1,.9,this.roadColors[1],this.rendered.roadsCtx),this.drawRoads(data.nodes,.9,1,this.roadColors[0],this.rendered.roadsCtx),this.render(!0)}drawTerrain(data,ctx){for(let x=this.gridGap;x{ctx.clearRect(...dest),ctx.drawImage(img,0,0,img.width,img.height,...dest),loading--,loading===0&&this.render(!0)}),img.addEventListener(`error`,()=>{console.error(`Navigator: Unable to load tile "${tile.file}"`),loading--,loading===0&&this.render(!0)}),img.src=tile.file}}createLine(ctx,p1,p2,color){Math.abs(p1.radius-p2.radius)>.2?this.varLine(ctx,p1.x,p1.y,p2.x,p2.y,p1.radius,p2.radius,color):(ctx.beginPath(),ctx.lineWidth=Math.max(p1.radius,p2.radius),ctx.lineCap=`round`,ctx.strokeStyle=color,ctx.moveTo(p1.x,p1.y),ctx.lineTo(p2.x,p2.y),ctx.stroke())}varLine(ctx,x1,y1,x2,y2,w1,w2,color){let dx=x2-x1,dy=y2-y1,length=dx*dx+dy*dy;if(length==0)return;length=Math.sqrt(length),w1*=.5,w2*=.5,dx/=length,dy/=length;let shiftx=-dy*w1,shifty=dx*w1;ctx.beginPath(),ctx.fillStyle=color,ctx.moveTo(x1+shiftx,y1+shifty),ctx.lineTo(x1-shiftx,y1-shifty),shiftx=-dy*w2,shifty=dx*w2,ctx.lineTo(x2-shiftx,y2-shifty),ctx.lineTo(x2+shiftx,y2+shifty),ctx.closePath(),ctx.arc(x1,y1,w1,0,2*Math.PI),ctx.arc(x2,y2,w2,0,2*Math.PI),ctx.fill()}drawRoads(nodes,drivabilityMin,drivabilityMax,colour,ctx){for(let key in nodes){let el=nodes[key];if(el.links)for(let key2 in el.links){let drivability=el.links[key2].drivability;if(drivabilitydrivabilityMax)continue;let el2=nodes[key2];this.createLine(ctx,{x:el.pos[0]/this.dimensions.scale*this.dimensions.resScale+this.dimensions.centerX,y:-el.pos[1]/this.dimensions.scale*this.dimensions.resScale+this.dimensions.centerY,radius:Math.min(Math.max(el.radius,0),5)*3*this.dimensions.resScale},{x:el2.pos[0]/this.dimensions.scale*this.dimensions.resScale+this.dimensions.centerX,y:-el2.pos[1]/this.dimensions.scale*this.dimensions.resScale+this.dimensions.centerY,radius:Math.min(Math.max(el2.radius,0),5)*3*this.dimensions.resScale},colour)}}}update(){let pos={x:-this.state.offsetX+this.offsetX,y:-this.state.offsetY+this.offsetY},rot={x:0,z:0};this.speedOffset>0&&(pos.y+=this.state.speedZoom*this.speedOffset),this.rotate&&(rot.x=this.pitch,this.speedPitch>0&&(rot.x+=this.speedPitch*this.state.speedZoom),rot.z=this.state.rotation);let scale=this.state.scale/this.dimensions.resScale;this.speedZoom&&(scale-=this.state.speedZoom*.1/this.dimensions.resScale),this.container.style.transform=`translate3d(${pos.x}px, ${pos.y}px, 0px) rotateX(${rot.x}deg) rotateZ(${rot.z}deg) scale(${scale})`}},bngNavLayerRoute=class{static name=`route`;dimensions;scale=1/3;lineWidth=10;color;wrapper;canvas;canvasCtx;current=null;static canInit(elms$4,opts){return!!opts.routes}constructor({routes,svg},opts,dimensions){this.name=this.constructor.name,[this.wrapper,this.canvas,this.canvasCtx]=routes||svg.createCanvas(opts.resolution),this.dimensions=dimensions,this.setOptions(opts)}setOptions(opts){this.color=opts.routeColor}update(data){if(this.dimver!==this.dimensions.ver){this.dimver=this.dimensions.ver;let width$1=this.dimensions.width,height$1=this.dimensions.height;this.canvas.style.width=this.wrapper.style.width=width$1+`px`,this.canvas.style.height=this.wrapper.style.height=height$1+`px`,this.canvas.width=this.canvasCtx.width=width$1*this.scale,this.canvas.height=this.canvasCtx.height=height$1*this.scale}if(!data||!data.markers){this.clear();return}this.current?this.optimiseAndDrawRoute(data,this.current):(this.clear(),data&&this.drawFreshRoute(data)),this.current=data.markers}clear(){this.current=null,this.canvasCtx.clearRect(0,0,this.canvas.width,this.canvas.height),this.canvasCtx.stroke()}drawFreshRoute(data){this.drawRoute({color:data.color,lineWidth:this.lineWidth,lineCap:`butt`,markers:data.markers,startIndex:0,drawFromIndex:2,drawToIndex:data.markers.length})}optimiseAndDrawRoute(data,prevMarkers){let markers$1=data.markers,ci=markers$1.length-2,pi=prevMarkers.length-2;for(;pi>=0&&ci>=0&&!(markers$1[ci]!==prevMarkers[pi]||markers$1[ci+1]!==prevMarkers[pi+1]);)ci-=2,pi-=2;(ci>=0||pi>=0)&&(this.canvasCtx.globalCompositeOperation=`destination-out`,this.drawRoute({color:data.color,lineWidth:this.lineWidth+2,markers:prevMarkers,drawToIndex:Math.min(pi+4,prevMarkers.length)}),this.canvasCtx.globalCompositeOperation=`source-over`,this.drawRoute({color:data.color,lineWidth:this.lineWidth,markers:data.markers,drawToIndex:Math.min(ci+6,data.markers.length)}))}drawRoute({color,lineWidth,lineCap=`round`,markers:markers$1,startIndex=0,drawFromIndex=0,drawToIndex}){let mapFac=this.scale/this.dimensions.scale,cx=this.dimensions.centerX*mapFac,cy=this.dimensions.centerY*mapFac;this.canvasCtx.beginPath(),this.canvasCtx.strokeStyle=color||this.color,this.canvasCtx.lineWidth=lineWidth*this.scale*this.dimensions.resScale,this.canvasCtx.lineCap=lineCap,this.canvasCtx.moveTo(markers$1[startIndex]*this.dimensions.resScale*mapFac+cx,-markers$1[startIndex+1]*this.dimensions.resScale*mapFac+cy);for(let i=drawFromIndex;iargs.map(arg=>typeof arg==`string`?arg:`[object]`)},createElementNS:{base:Document,getArgs:(...args)=>args.map(arg=>typeof arg==`string`?arg:`[object]`)},cloneNode:{base:Node,getArgs:deep=>[deep]},importNode:{base:Document,getArgs:(node,deep)=>[`[node]`,deep]},insertAdjacentHTML:{base:Element,getArgs:(position,text)=>[position,`[HTML:${text.length}chars]`]},innerHTML:{isSetter:!0,bases:[Element,HTMLElement],getArgs:value=>[`[HTML:${typeof value==`string`?value.length:0}chars]`]},outerHTML:{isSetter:!0,bases:[Element,HTMLElement],getArgs:value=>[`[HTML:${typeof value==`string`?value.length:0}chars]`]},appendChild:{base:Node,stats:`append`,getArgs:child=>[`[${child?.tagName||child?.nodeName||`node`}]`]},insertBefore:{base:Node,stats:`append`,getArgs:(newNode,referenceNode)=>[`[${newNode?.tagName||newNode?.nodeName||`node`}]`,`[${referenceNode?.tagName||referenceNode?.nodeName||`ref`}]`]},replaceChild:{base:Node,stats:`append`,getArgs:(newChild,oldChild)=>[`[${newChild?.tagName||newChild?.nodeName||`new`}]`,`[${oldChild?.tagName||oldChild?.nodeName||`old`}]`]},append:{base:Element,stats:`append`,getArgs:(...nodes)=>nodes.map(node=>`[${node?.tagName||node?.nodeName||typeof node==`string`?`text`:`node`}]`)},prepend:{base:Element,stats:`append`,getArgs:(...nodes)=>nodes.map(node=>`[${node?.tagName||node?.nodeName||typeof node==`string`?`text`:`node`}]`)},before:{base:Element,stats:`append`,getArgs:(...nodes)=>nodes.map(node=>`[${node?.tagName||node?.nodeName||typeof node==`string`?`text`:`node`}]`)},after:{base:Element,stats:`append`,getArgs:(...nodes)=>nodes.map(node=>`[${node?.tagName||node?.nodeName||typeof node==`string`?`text`:`node`}]`)}};function setupInterceptor(type){let interceptor=interceptors[type];if(interceptor.isSetter){let descriptor;if(interceptor.bases){for(let base of interceptor.bases)if(descriptor=Object.getOwnPropertyDescriptor(base.prototype,type),descriptor){interceptor.base=base;break}}descriptor&&(interceptor.original=descriptor)}else interceptor.original=interceptor.base.prototype[type];if(!interceptor.original){logger_default.warn(`No original for ${type}`);return}interceptor.call=(self$1,...args)=>{let stackTrace=captureStackTrace();if(stackTrace&&(includeAnonymousCalls||!stackTrace.hasAnonymous||stackTrace.filePaths.length>0)){let callData={type,timestamp:Date.now(),args:interceptor.getArgs(...args),stackTrace};if(interceptor.stats===`append`&&self$1)try{let mainContainer=self$1.closest?self$1.closest(`#mainContainer_apps`):null;if(mainContainer){let directChildDiv=self$1;for(;directChildDiv&&directChildDiv.parentNode&&directChildDiv.parentNode!==mainContainer;)directChildDiv=directChildDiv.parentNode;directChildDiv&&directChildDiv.parentNode===mainContainer&&directChildDiv.tagName===`DIV`&&(callData.uiAppInsertion={targetElement:directChildDiv})}}catch{}callQueue.push(callData)}if(interceptor.isSetter)interceptor.original.set.call(self$1,args[0]);else return interceptor.original.apply(self$1,args)},interceptor.isSetter?Object.defineProperty(interceptor.base.prototype,type,{get:interceptor.original.get,set:function(value){interceptor.call(this,value)},configurable:!0,enumerable:!0}):interceptor.base.prototype[type]=function(...args){return interceptor.call(this,...args)},interceptor.restore=()=>{interceptor.isSetter?Object.defineProperty(interceptor.base.prototype,type,{get:interceptor.original.get,set:interceptor.original.set,configurable:!0,enumerable:!0}):interceptor.base.prototype[type]=interceptor.original}}function captureStackTrace(){let stack$2=Error().stack;if(!stack$2)return null;let relevantLines=stack$2.split(` `).slice(STACK_TRACE_SKIP_LINES),filePaths=[],hasAnonymous=!1;for(let line of relevantLines){let match=line.match(STACK_TRACE_REGEX_FULL),functionName,filePath,lineNum,column;if(match)functionName=match[1],filePath=match[2],lineNum=match[3],column=match[4];else if(match=line.match(STACK_TRACE_REGEX),match)functionName=`anonymous`,filePath=match[1],lineNum=match[2],column=match[3];else continue;let isAnonymous=functionName?.includes(`anonymous`)||functionName?.includes(``)||!functionName||functionName.trim()===``;isAnonymous&&(hasAnonymous=!0,!includeAnonymousCalls)||filePaths.push({functionName,filePath,line:lineNum,column,isAnonymous})}return{filePaths,fullStack:stack$2,hasAnonymous}}async function processCallQueue(){if(statsProcessor.lastProcessTime=Date.now(),!(statsProcessor.isProcessing||callQueue.length===0)){statsProcessor.isProcessing=!0;try{let batch$1=callQueue.splice(0,Math.max(statsProcessor.batchSize,callQueue.length/5));statsProcessor.totalProcessed+=batch$1.length;for(let i=0;i{try{processCallQueue()}catch(error){logger_default.error(`Fatal error in DOM watchdog processing:`,error),destroy()}},statsProcessor.processInterval)}function getStats(){return{files:Object.fromEntries(statsProcessor.files),types:Object.fromEntries(statsProcessor.types),append:Object.fromEntries(statsProcessor.append)}}function clearStats(){statsProcessor.files.clear(),statsProcessor.types.clear(),statsProcessor.append.clear(),statsProcessor.uiApps.clear(),callQueue.length=0,statsProcessor.totalProcessed=0,statsProcessor.lastProcessTime=0,overlayActive&&updateOverlayDivs()}function restartTimer(){isInitialized&&startStatsProcessor()}function setIncludeAnonymousCalls(include){includeAnonymousCalls=include}var exposedFunctions=()=>({watchdogRecentCalls:getRecentCalls,watchdogCallChainStats:getCallChainStats,watchdogClearStats:clearStats,watchdogSetIncludeAnonymousCalls:setIncludeAnonymousCalls,watchdogDestroy:destroy,watchdogRestartTimer:restartTimer,watchdogUIAppsStats:getUIAppsStats,watchdogRefreshOverlay:refreshOverlay,watchdogStats:()=>{let stats=getStats(),format$2=obj=>Object.entries(obj).sort((a$1,b)=>b[1]-a$1[1]).map(([key,value])=>`${key}: ${value}`.replace(`\\`,`\\\\`)).join(`
  •         text-shadow: 1px 1px 2px #000a;
          `,overlayDiv.textContent=count$1.toString(),overlayElement.appendChild(overlayDiv),overlayDivs.set(element,overlayDiv)}catch{}}function updateOverlayText(){if(!overlayActive||overlayDivs.size===0)return;let appsStats=getUIAppsStats(),counts=appsStats.sortedList.map(item=>item.count),maxCount=Math.max(...counts,1),minCount=Math.min(...counts,0);for(let{element,count:count$1}of appsStats.sortedList){let overlayDiv=overlayDivs.get(element);overlayDiv&&(overlayDiv.textContent=count$1.toString(),overlayDiv.style.opacity=getOverlayOpacity(count$1,minCount,maxCount))}}function destroyOverlay(){overlayUpdateTimer&&=(clearInterval(overlayUpdateTimer),null),overlayDivs.forEach(overlayDiv=>overlayDiv.remove()),overlayDivs.clear(),overlayElement&&=(overlayElement.remove(),null),overlayActive=!1}function toggleOverlay(){return overlayActive?(destroyOverlay(),!1):(overlayActive=!0,createOverlay(),updateOverlayDivs(),overlayUpdateTimer=setInterval(updateOverlayText,500),!0)}function refreshOverlay(){overlayActive&&updateOverlayDivs()}var isBrowser=typeof document<`u`;function isRouteComponent(component){return typeof component==`object`||`displayName`in component||`props`in component||`__vccOpts`in component}function isESModule(obj){return obj.__esModule||obj[Symbol.toStringTag]===`Module`||obj.default&&isRouteComponent(obj.default)}var assign=Object.assign;function applyToParams(fn,params){let newParams={};for(let key in params){let value=params[key];newParams[key]=isArray(value)?value.map(fn):fn(value)}return newParams}var noop$1=()=>{},isArray=Array.isArray;function mergeOptions(defaults,partialOptions){let options={};for(let key in defaults)options[key]=key in partialOptions?partialOptions[key]:defaults[key];return options}var HASH_RE=/#/g,AMPERSAND_RE=/&/g,SLASH_RE=/\//g,EQUAL_RE=/=/g,IM_RE=/\?/g,PLUS_RE=/\+/g,ENC_BRACKET_OPEN_RE=/%5B/g,ENC_BRACKET_CLOSE_RE=/%5D/g,ENC_CARET_RE=/%5E/g,ENC_BACKTICK_RE=/%60/g,ENC_CURLY_OPEN_RE=/%7B/g,ENC_PIPE_RE=/%7C/g,ENC_CURLY_CLOSE_RE=/%7D/g,ENC_SPACE_RE=/%20/g;function commonEncode(text){return text==null?``:encodeURI(``+text).replace(ENC_PIPE_RE,`|`).replace(ENC_BRACKET_OPEN_RE,`[`).replace(ENC_BRACKET_CLOSE_RE,`]`)}function encodeHash(text){return commonEncode(text).replace(ENC_CURLY_OPEN_RE,`{`).replace(ENC_CURLY_CLOSE_RE,`}`).replace(ENC_CARET_RE,`^`)}function encodeQueryValue(text){return commonEncode(text).replace(PLUS_RE,`%2B`).replace(ENC_SPACE_RE,`+`).replace(HASH_RE,`%23`).replace(AMPERSAND_RE,`%26`).replace(ENC_BACKTICK_RE,"`").replace(ENC_CURLY_OPEN_RE,`{`).replace(ENC_CURLY_CLOSE_RE,`}`).replace(ENC_CARET_RE,`^`)}function encodeQueryKey(text){return encodeQueryValue(text).replace(EQUAL_RE,`%3D`)}function encodePath(text){return commonEncode(text).replace(HASH_RE,`%23`).replace(IM_RE,`%3F`)}function encodeParam(text){return encodePath(text).replace(SLASH_RE,`%2F`)}function decode(text){if(text==null)return null;try{return decodeURIComponent(``+text)}catch{}return``+text}var TRAILING_SLASH_RE=/\/$/,removeTrailingSlash=path=>path.replace(TRAILING_SLASH_RE,``);function parseURL(parseQuery$1,location$1,currentLocation=`/`){let path,query={},searchString=``,hash=``,hashPos=location$1.indexOf(`#`),searchPos=location$1.indexOf(`?`);return searchPos=hashPos>=0&&searchPos>hashPos?-1:searchPos,searchPos>=0&&(path=location$1.slice(0,searchPos),searchString=location$1.slice(searchPos,hashPos>0?hashPos:location$1.length),query=parseQuery$1(searchString.slice(1))),hashPos>=0&&(path||=location$1.slice(0,hashPos),hash=location$1.slice(hashPos,location$1.length)),path=resolveRelativePath(path??location$1,currentLocation),{fullPath:path+searchString+hash,path,query,hash:decode(hash)}}function stringifyURL(stringifyQuery$1,location$1){let query=location$1.query?stringifyQuery$1(location$1.query):``;return location$1.path+(query&&`?`)+query+(location$1.hash||``)}function stripBase(pathname,base){return!base||!pathname.toLowerCase().startsWith(base.toLowerCase())?pathname:pathname.slice(base.length)||`/`}function isSameRouteLocation(stringifyQuery$1,a$1,b){let aLastIndex=a$1.matched.length-1,bLastIndex=b.matched.length-1;return aLastIndex>-1&&aLastIndex===bLastIndex&&isSameRouteRecord(a$1.matched[aLastIndex],b.matched[bLastIndex])&&isSameRouteLocationParams(a$1.params,b.params)&&stringifyQuery$1(a$1.query)===stringifyQuery$1(b.query)&&a$1.hash===b.hash}function isSameRouteRecord(a$1,b){return(a$1.aliasOf||a$1)===(b.aliasOf||b)}function isSameRouteLocationParams(a$1,b){if(Object.keys(a$1).length!==Object.keys(b).length)return!1;for(let key in a$1)if(!isSameRouteLocationParamsValue(a$1[key],b[key]))return!1;return!0}function isSameRouteLocationParamsValue(a$1,b){return isArray(a$1)?isEquivalentArray(a$1,b):isArray(b)?isEquivalentArray(b,a$1):a$1===b}function isEquivalentArray(a$1,b){return isArray(b)?a$1.length===b.length&&a$1.every((value,i)=>value===b[i]):a$1.length===1&&a$1[0]===b}function resolveRelativePath(to,from){if(to.startsWith(`/`))return to;if(!to)return from;let fromSegments=from.split(`/`),toSegments=to.split(`/`),lastToSegment=toSegments[toSegments.length-1];(lastToSegment===`..`||lastToSegment===`.`)&&toSegments.push(``);let position=fromSegments.length-1,toPosition,segment;for(toPosition=0;toPosition1&&position--;else break;return fromSegments.slice(0,position).join(`/`)+`/`+toSegments.slice(toPosition).join(`/`)}var START_LOCATION_NORMALIZED={path:`/`,name:void 0,params:{},query:{},hash:``,fullPath:`/`,matched:[],meta:{},redirectedFrom:void 0},NavigationType=function(NavigationType$1){return NavigationType$1.pop=`pop`,NavigationType$1.push=`push`,NavigationType$1}({}),NavigationDirection=function(NavigationDirection$1){return NavigationDirection$1.back=`back`,NavigationDirection$1.forward=`forward`,NavigationDirection$1.unknown=``,NavigationDirection$1}({});function normalizeBase(base){if(!base)if(isBrowser){let baseEl=document.querySelector(`base`);base=baseEl&&baseEl.getAttribute(`href`)||`/`,base=base.replace(/^\w+:\/\/[^\/]+/,``)}else base=`/`;return base[0]!==`/`&&base[0]!==`#`&&(base=`/`+base),removeTrailingSlash(base)}var BEFORE_HASH_RE=/^[^#]+#/;function createHref(base,location$1){return base.replace(BEFORE_HASH_RE,`#`)+location$1}function getElementPosition(el,offset$2){let docRect=document.documentElement.getBoundingClientRect(),elRect=el.getBoundingClientRect();return{behavior:offset$2.behavior,left:elRect.left-docRect.left-(offset$2.left||0),top:elRect.top-docRect.top-(offset$2.top||0)}}var computeScrollPosition=()=>({left:window.scrollX,top:window.scrollY});function scrollToPosition(position){let scrollToOptions;if(`el`in position){let positionEl=position.el,isIdSelector=typeof positionEl==`string`&&positionEl.startsWith(`#`),el=typeof positionEl==`string`?isIdSelector?document.getElementById(positionEl.slice(1)):document.querySelector(positionEl):positionEl;if(!el)return;scrollToOptions=getElementPosition(el,position)}else scrollToOptions=position;`scrollBehavior`in document.documentElement.style?window.scrollTo(scrollToOptions):window.scrollTo(scrollToOptions.left==null?window.scrollX:scrollToOptions.left,scrollToOptions.top==null?window.scrollY:scrollToOptions.top)}function getScrollKey(path,delta){return(history.state?history.state.position-delta:-1)+path}var scrollPositions=new Map;function saveScrollPosition(key,scrollPosition){scrollPositions.set(key,scrollPosition)}function getSavedScrollPosition(key){let scroll$1=scrollPositions.get(key);return scrollPositions.delete(key),scroll$1}function isRouteLocation(route){return typeof route==`string`||route&&typeof route==`object`}function isRouteName(name){return typeof name==`string`||typeof name==`symbol`}var ErrorTypes=function(ErrorTypes$1){return ErrorTypes$1[ErrorTypes$1.MATCHER_NOT_FOUND=1]=`MATCHER_NOT_FOUND`,ErrorTypes$1[ErrorTypes$1.NAVIGATION_GUARD_REDIRECT=2]=`NAVIGATION_GUARD_REDIRECT`,ErrorTypes$1[ErrorTypes$1.NAVIGATION_ABORTED=4]=`NAVIGATION_ABORTED`,ErrorTypes$1[ErrorTypes$1.NAVIGATION_CANCELLED=8]=`NAVIGATION_CANCELLED`,ErrorTypes$1[ErrorTypes$1.NAVIGATION_DUPLICATED=16]=`NAVIGATION_DUPLICATED`,ErrorTypes$1}({}),NavigationFailureSymbol=Symbol(``);ErrorTypes.MATCHER_NOT_FOUND,ErrorTypes.NAVIGATION_GUARD_REDIRECT,ErrorTypes.NAVIGATION_ABORTED,ErrorTypes.NAVIGATION_CANCELLED,ErrorTypes.NAVIGATION_DUPLICATED;function createRouterError(type,params){return assign(Error(),{type,[NavigationFailureSymbol]:!0},params)}function isNavigationFailure(error,type){return error instanceof Error&&NavigationFailureSymbol in error&&(type==null||!!(error.type&type))}function parseQuery(search$1){let query={};if(search$1===``||search$1===`?`)return query;let searchParams=(search$1[0]===`?`?search$1.slice(1):search$1).split(`&`);for(let i=0;iv&&encodeQueryValue(v)):[value&&encodeQueryValue(value)]).forEach(value$1=>{value$1!==void 0&&(search$1+=(search$1.length?`&`:``)+key,value$1!=null&&(search$1+=`=`+value$1))})}return search$1}function normalizeQuery(query){let normalizedQuery={};for(let key in query){let value=query[key];value!==void 0&&(normalizedQuery[key]=isArray(value)?value.map(v=>v==null?null:``+v):value==null?value:``+value)}return normalizedQuery}var matchedRouteKey=Symbol(``),viewDepthKey=Symbol(``),routerKey=Symbol(``),routeLocationKey=Symbol(``),routerViewLocationKey=Symbol(``);function useCallbacks(){let handlers$1=[];function add$2(handler$1){return handlers$1.push(handler$1),()=>{let i=handlers$1.indexOf(handler$1);i>-1&&handlers$1.splice(i,1)}}function reset$1(){handlers$1=[]}return{add:add$2,list:()=>handlers$1.slice(),reset:reset$1}}function guardToPromiseFn(guard,to,from,record,name,runWithContext=fn=>fn()){let enterCallbackArray=record&&(record.enterCallbacks[name]=record.enterCallbacks[name]||[]);return()=>new Promise((resolve$1,reject)=>{let next=valid=>{valid===!1?reject(createRouterError(ErrorTypes.NAVIGATION_ABORTED,{from,to})):valid instanceof Error?reject(valid):isRouteLocation(valid)?reject(createRouterError(ErrorTypes.NAVIGATION_GUARD_REDIRECT,{from:to,to:valid})):(enterCallbackArray&&record.enterCallbacks[name]===enterCallbackArray&&typeof valid==`function`&&enterCallbackArray.push(valid),resolve$1())},guardReturn=runWithContext(()=>guard.call(record&&record.instances[name],to,from,next)),guardCall=Promise.resolve(guardReturn);guard.length<3&&(guardCall=guardCall.then(next)),guardCall.catch(err=>reject(err))})}function extractComponentsGuards(matched,guardType,to,from,runWithContext=fn=>fn()){let guards=[];for(let record of matched)for(let name in record.components){let rawComponent=record.components[name];if(!(guardType!==`beforeRouteEnter`&&!record.instances[name]))if(isRouteComponent(rawComponent)){let guard=(rawComponent.__vccOpts||rawComponent)[guardType];guard&&guards.push(guardToPromiseFn(guard,to,from,record,name,runWithContext))}else{let componentPromise=rawComponent();guards.push(()=>componentPromise.then(resolved=>{if(!resolved)throw Error(`Couldn't resolve component "${name}" at "${record.path}"`);let resolvedComponent=isESModule(resolved)?resolved.default:resolved;record.mods[name]=resolved,record.components[name]=resolvedComponent;let guard=(resolvedComponent.__vccOpts||resolvedComponent)[guardType];return guard&&guardToPromiseFn(guard,to,from,record,name,runWithContext)()}))}}return guards}function extractChangingRecords(to,from){let leavingRecords=[],updatingRecords=[],enteringRecords=[],len=Math.max(from.matched.length,to.matched.length);for(let i=0;iisSameRouteRecord(record,recordFrom))?updatingRecords.push(recordFrom):leavingRecords.push(recordFrom));let recordTo=to.matched[i];recordTo&&(from.matched.find(record=>isSameRouteRecord(record,recordTo))||enteringRecords.push(recordTo))}return[leavingRecords,updatingRecords,enteringRecords]}var createBaseLocation=()=>location.protocol+`//`+location.host;function createCurrentLocation(base,location$1){let{pathname,search:search$1,hash}=location$1,hashPos=base.indexOf(`#`);if(hashPos>-1){let slicePos=hash.includes(base.slice(hashPos))?base.slice(hashPos).length:1,pathFromHash=hash.slice(slicePos);return pathFromHash[0]!==`/`&&(pathFromHash=`/`+pathFromHash),stripBase(pathFromHash,``)}return stripBase(pathname,base)+search$1+hash}function useHistoryListeners(base,historyState,currentLocation,replace){let listeners=[],teardowns=[],pauseState=null,popStateHandler=({state})=>{let to=createCurrentLocation(base,location),from=currentLocation.value,fromState=historyState.value,delta=0;if(state){if(currentLocation.value=to,historyState.value=state,pauseState&&pauseState===from){pauseState=null;return}delta=fromState?state.position-fromState.position:0}else replace(to);listeners.forEach(listener=>{listener(currentLocation.value,from,{delta,type:NavigationType.pop,direction:delta?delta>0?NavigationDirection.forward:NavigationDirection.back:NavigationDirection.unknown})})};function pauseListeners(){pauseState=currentLocation.value}function listen(callback){listeners.push(callback);let teardown=()=>{let index=listeners.indexOf(callback);index>-1&&listeners.splice(index,1)};return teardowns.push(teardown),teardown}function beforeUnloadListener(){if(document.visibilityState===`hidden`){let{history:history$1}=window;if(!history$1.state)return;history$1.replaceState(assign({},history$1.state,{scroll:computeScrollPosition()}),``)}}function destroy$1(){for(let teardown of teardowns)teardown();teardowns=[],window.removeEventListener(`popstate`,popStateHandler),window.removeEventListener(`pagehide`,beforeUnloadListener),document.removeEventListener(`visibilitychange`,beforeUnloadListener)}return window.addEventListener(`popstate`,popStateHandler),window.addEventListener(`pagehide`,beforeUnloadListener),document.addEventListener(`visibilitychange`,beforeUnloadListener),{pauseListeners,listen,destroy:destroy$1}}function buildState(back,current,forward,replaced=!1,computeScroll=!1){return{back,current,forward,replaced,position:window.history.length,scroll:computeScroll?computeScrollPosition():null}}function useHistoryStateNavigation(base){let{history:history$1,location:location$1}=window,currentLocation={value:createCurrentLocation(base,location$1)},historyState={value:history$1.state};historyState.value||changeLocation(currentLocation.value,{back:null,current:currentLocation.value,forward:null,position:history$1.length-1,replaced:!0,scroll:null},!0);function changeLocation(to,state,replace$1){let hashIndex=base.indexOf(`#`),url=hashIndex>-1?(location$1.host&&document.querySelector(`base`)?base:base.slice(hashIndex))+to:createBaseLocation()+base+to;try{history$1[replace$1?`replaceState`:`pushState`](state,``,url),historyState.value=state}catch(err){console.error(err),location$1[replace$1?`replace`:`assign`](url)}}function replace(to,data){changeLocation(to,assign({},history$1.state,buildState(historyState.value.back,to,historyState.value.forward,!0),data,{position:historyState.value.position}),!0),currentLocation.value=to}function push(to,data){let currentState=assign({},historyState.value,history$1.state,{forward:to,scroll:computeScrollPosition()});changeLocation(currentState.current,currentState,!0),changeLocation(to,assign({},buildState(currentLocation.value,to,null),{position:currentState.position+1},data),!1),currentLocation.value=to}return{location:currentLocation,state:historyState,push,replace}}function createWebHistory(base){base=normalizeBase(base);let historyNavigation=useHistoryStateNavigation(base),historyListeners=useHistoryListeners(base,historyNavigation.state,historyNavigation.location,historyNavigation.replace);function go(delta,triggerListeners=!0){triggerListeners||historyListeners.pauseListeners(),history.go(delta)}let routerHistory=assign({location:``,base,go,createHref:createHref.bind(null,base)},historyNavigation,historyListeners);return Object.defineProperty(routerHistory,`location`,{enumerable:!0,get:()=>historyNavigation.location.value}),Object.defineProperty(routerHistory,`state`,{enumerable:!0,get:()=>historyNavigation.state.value}),routerHistory}function createWebHashHistory(base){return base=location.host?base||location.pathname+location.search:``,base.includes(`#`)||(base+=`#`),createWebHistory(base)}var TokenType=function(TokenType$1){return TokenType$1[TokenType$1.Static=0]=`Static`,TokenType$1[TokenType$1.Param=1]=`Param`,TokenType$1[TokenType$1.Group=2]=`Group`,TokenType$1}({}),TokenizerState=function(TokenizerState$1){return TokenizerState$1[TokenizerState$1.Static=0]=`Static`,TokenizerState$1[TokenizerState$1.Param=1]=`Param`,TokenizerState$1[TokenizerState$1.ParamRegExp=2]=`ParamRegExp`,TokenizerState$1[TokenizerState$1.ParamRegExpEnd=3]=`ParamRegExpEnd`,TokenizerState$1[TokenizerState$1.EscapeNext=4]=`EscapeNext`,TokenizerState$1}(TokenizerState||{}),ROOT_TOKEN={type:TokenType.Static,value:``},VALID_PARAM_RE=/[a-zA-Z0-9_]/;function tokenizePath(path){if(!path)return[[]];if(path===`/`)return[[ROOT_TOKEN]];if(!path.startsWith(`/`))throw Error(`Invalid path "${path}"`);function crash(message){throw Error(`ERR (${state})/"${buffer$1}": ${message}`)}let state=TokenizerState.Static,previousState=state,tokens=[],segment;function finalizeSegment(){segment&&tokens.push(segment),segment=[]}let i=0,char,buffer$1=``,customRe=``;function consumeBuffer(){buffer$1&&=(state===TokenizerState.Static?segment.push({type:TokenType.Static,value:buffer$1}):state===TokenizerState.Param||state===TokenizerState.ParamRegExp||state===TokenizerState.ParamRegExpEnd?(segment.length>1&&(char===`*`||char===`+`)&&crash(`A repeatable param (${buffer$1}) must be alone in its segment. eg: '/:ids+.`),segment.push({type:TokenType.Param,value:buffer$1,regexp:customRe,repeatable:char===`*`||char===`+`,optional:char===`*`||char===`?`})):crash(`Invalid state to consume buffer`),``)}function addCharToBuffer(){buffer$1+=char}for(;ib.length?b.length===1&&b[0]===PathScore.Static+PathScore.Segment?1:-1:0}function comparePathParserScore(a$1,b){let i=0,aScore=a$1.score,bScore=b.score;for(;i0&&last[last.length-1]<0}var PATH_PARSER_OPTIONS_DEFAULTS={strict:!1,end:!0,sensitive:!1};function createRouteRecordMatcher(record,parent,options){let matcher=assign(tokensToParser(tokenizePath(record.path),options),{record,parent,children:[],alias:[]});return parent&&!matcher.record.aliasOf==!parent.record.aliasOf&&parent.children.push(matcher),matcher}function createRouterMatcher(routes,globalOptions){let matchers=[],matcherMap=new Map;globalOptions=mergeOptions(PATH_PARSER_OPTIONS_DEFAULTS,globalOptions);function getRecordMatcher(name){return matcherMap.get(name)}function addRoute(record,parent,originalRecord){let isRootAdd=!originalRecord,mainNormalizedRecord=normalizeRouteRecord(record);mainNormalizedRecord.aliasOf=originalRecord&&originalRecord.record;let options=mergeOptions(globalOptions,record),normalizedRecords=[mainNormalizedRecord];if(`alias`in record){let aliases=typeof record.alias==`string`?[record.alias]:record.alias;for(let alias of aliases)normalizedRecords.push(normalizeRouteRecord(assign({},mainNormalizedRecord,{components:originalRecord?originalRecord.record.components:mainNormalizedRecord.components,path:alias,aliasOf:originalRecord?originalRecord.record:mainNormalizedRecord})))}let matcher,originalMatcher;for(let normalizedRecord of normalizedRecords){let{path}=normalizedRecord;if(parent&&path[0]!==`/`){let parentPath=parent.record.path,connectingSlash=parentPath[parentPath.length-1]===`/`?``:`/`;normalizedRecord.path=parent.record.path+(path&&connectingSlash+path)}if(matcher=createRouteRecordMatcher(normalizedRecord,parent,options),originalRecord?originalRecord.alias.push(matcher):(originalMatcher||=matcher,originalMatcher!==matcher&&originalMatcher.alias.push(matcher),isRootAdd&&record.name&&!isAliasRecord(matcher)&&removeRoute(record.name)),isMatchable(matcher)&&insertMatcher(matcher),mainNormalizedRecord.children){let children=mainNormalizedRecord.children;for(let i=0;i{removeRoute(originalMatcher)}:noop$1}function removeRoute(matcherRef){if(isRouteName(matcherRef)){let matcher=matcherMap.get(matcherRef);matcher&&(matcherMap.delete(matcherRef),matchers.splice(matchers.indexOf(matcher),1),matcher.children.forEach(removeRoute),matcher.alias.forEach(removeRoute))}else{let index=matchers.indexOf(matcherRef);index>-1&&(matchers.splice(index,1),matcherRef.record.name&&matcherMap.delete(matcherRef.record.name),matcherRef.children.forEach(removeRoute),matcherRef.alias.forEach(removeRoute))}}function getRoutes(){return matchers}function insertMatcher(matcher){let index=findInsertionIndex(matcher,matchers);matchers.splice(index,0,matcher),matcher.record.name&&!isAliasRecord(matcher)&&matcherMap.set(matcher.record.name,matcher)}function resolve$1(location$1,currentLocation){let matcher,params={},path,name;if(`name`in location$1&&location$1.name){if(matcher=matcherMap.get(location$1.name),!matcher)throw createRouterError(ErrorTypes.MATCHER_NOT_FOUND,{location:location$1});name=matcher.record.name,params=assign(pickParams(currentLocation.params,matcher.keys.filter(k=>!k.optional).concat(matcher.parent?matcher.parent.keys.filter(k=>k.optional):[]).map(k=>k.name)),location$1.params&&pickParams(location$1.params,matcher.keys.map(k=>k.name))),path=matcher.stringify(params)}else if(location$1.path!=null)path=location$1.path,matcher=matchers.find(m=>m.re.test(path)),matcher&&(params=matcher.parse(path),name=matcher.record.name);else{if(matcher=currentLocation.name?matcherMap.get(currentLocation.name):matchers.find(m=>m.re.test(currentLocation.path)),!matcher)throw createRouterError(ErrorTypes.MATCHER_NOT_FOUND,{location:location$1,currentLocation});name=matcher.record.name,params=assign({},currentLocation.params,location$1.params),path=matcher.stringify(params)}let matched=[],parentMatcher=matcher;for(;parentMatcher;)matched.unshift(parentMatcher.record),parentMatcher=parentMatcher.parent;return{name,path,params,matched,meta:mergeMetaFields(matched)}}routes.forEach(route=>addRoute(route));function clearRoutes(){matchers.length=0,matcherMap.clear()}return{addRoute,resolve:resolve$1,removeRoute,clearRoutes,getRoutes,getRecordMatcher}}function pickParams(params,keys){let newParams={};for(let key of keys)key in params&&(newParams[key]=params[key]);return newParams}function normalizeRouteRecord(record){let normalized={path:record.path,redirect:record.redirect,name:record.name,meta:record.meta||{},aliasOf:record.aliasOf,beforeEnter:record.beforeEnter,props:normalizeRecordProps(record),children:record.children||[],instances:{},leaveGuards:new Set,updateGuards:new Set,enterCallbacks:{},components:`components`in record?record.components||null:record.component&&{default:record.component}};return Object.defineProperty(normalized,`mods`,{value:{}}),normalized}function normalizeRecordProps(record){let propsObject={},props=record.props||!1;if(`component`in record)propsObject.default=props;else for(let name in record.components)propsObject[name]=typeof props==`object`?props[name]:props;return propsObject}function isAliasRecord(record){for(;record;){if(record.record.aliasOf)return!0;record=record.parent}return!1}function mergeMetaFields(matched){return matched.reduce((meta,record)=>assign(meta,record.meta),{})}function findInsertionIndex(matcher,matchers){let lower=0,upper=matchers.length;for(;lower!==upper;){let mid=lower+upper>>1;comparePathParserScore(matcher,matchers[mid])<0?upper=mid:lower=mid+1}let insertionAncestor=getInsertionAncestor(matcher);return insertionAncestor&&(upper=matchers.lastIndexOf(insertionAncestor,upper-1)),upper}function getInsertionAncestor(matcher){let ancestor=matcher;for(;ancestor=ancestor.parent;)if(isMatchable(ancestor)&&comparePathParserScore(matcher,ancestor)===0)return ancestor}function isMatchable({record}){return!!(record.name||record.components&&Object.keys(record.components).length||record.redirect)}function useLink(props){let router$1=inject(routerKey),currentRoute=inject(routeLocationKey),route=computed(()=>{let to=unref(props.to);return router$1.resolve(to)}),activeRecordIndex=computed(()=>{let{matched}=route.value,{length}=matched,routeMatched=matched[length-1],currentMatched=currentRoute.matched;if(!routeMatched||!currentMatched.length)return-1;let index=currentMatched.findIndex(isSameRouteRecord.bind(null,routeMatched));if(index>-1)return index;let parentRecordPath=getOriginalPath(matched[length-2]);return length>1&&getOriginalPath(routeMatched)===parentRecordPath&¤tMatched[currentMatched.length-1].path!==parentRecordPath?currentMatched.findIndex(isSameRouteRecord.bind(null,matched[length-2])):index}),isActive=computed(()=>activeRecordIndex.value>-1&&includesParams(currentRoute.params,route.value.params)),isExactActive=computed(()=>activeRecordIndex.value>-1&&activeRecordIndex.value===currentRoute.matched.length-1&&isSameRouteLocationParams(currentRoute.params,route.value.params));function navigate$1(e={}){if(guardEvent(e)){let p$1=router$1[unref(props.replace)?`replace`:`push`](unref(props.to)).catch(noop$1);return props.viewTransition&&typeof document<`u`&&`startViewTransition`in document&&document.startViewTransition(()=>p$1),p$1}return Promise.resolve()}return{route,href:computed(()=>route.value.href),isActive,isExactActive,navigate:navigate$1}}function preferSingleVNode(vnodes){return vnodes.length===1?vnodes[0]:vnodes}var RouterLink=defineComponent({name:`RouterLink`,compatConfig:{MODE:3},props:{to:{type:[String,Object],required:!0},replace:Boolean,activeClass:String,exactActiveClass:String,custom:Boolean,ariaCurrentValue:{type:String,default:`page`},viewTransition:Boolean},useLink,setup(props,{slots}){let link=reactive(useLink(props)),{options}=inject(routerKey),elClass=computed(()=>({[getLinkClass(props.activeClass,options.linkActiveClass,`router-link-active`)]:link.isActive,[getLinkClass(props.exactActiveClass,options.linkExactActiveClass,`router-link-exact-active`)]:link.isExactActive}));return()=>{let children=slots.default&&preferSingleVNode(slots.default(link));return props.custom?children:h(`a`,{"aria-current":link.isExactActive?props.ariaCurrentValue:null,href:link.href,onClick:link.navigate,class:elClass.value},children)}}});function guardEvent(e){if(!(e.metaKey||e.altKey||e.ctrlKey||e.shiftKey)&&!e.defaultPrevented&&!(e.button!==void 0&&e.button!==0)){if(e.currentTarget&&e.currentTarget.getAttribute){let target=e.currentTarget.getAttribute(`target`);if(/\b_blank\b/i.test(target))return}return e.preventDefault&&e.preventDefault(),!0}}function includesParams(outer,inner){for(let key in inner){let innerValue=inner[key],outerValue=outer[key];if(typeof innerValue==`string`){if(innerValue!==outerValue)return!1}else if(!isArray(outerValue)||outerValue.length!==innerValue.length||innerValue.some((value,i)=>value!==outerValue[i]))return!1}return!0}function getOriginalPath(record){return record?record.aliasOf?record.aliasOf.path:record.path:``}var getLinkClass=(propClass,globalClass,defaultClass)=>propClass??globalClass??defaultClass,RouterViewImpl=defineComponent({name:`RouterView`,inheritAttrs:!1,props:{name:{type:String,default:`default`},route:Object},compatConfig:{MODE:3},setup(props,{attrs,slots}){let injectedRoute=inject(routerViewLocationKey),routeToDisplay=computed(()=>props.route||injectedRoute.value),injectedDepth=inject(viewDepthKey,0),depth=computed(()=>{let initialDepth=unref(injectedDepth),{matched}=routeToDisplay.value,matchedRoute;for(;(matchedRoute=matched[initialDepth])&&!matchedRoute.components;)initialDepth++;return initialDepth}),matchedRouteRef=computed(()=>routeToDisplay.value.matched[depth.value]);provide(viewDepthKey,computed(()=>depth.value+1)),provide(matchedRouteKey,matchedRouteRef),provide(routerViewLocationKey,routeToDisplay);let viewRef=ref();return watch(()=>[viewRef.value,matchedRouteRef.value,props.name],([instance$1,to,name],[oldInstance,from,oldName])=>{to&&(to.instances[name]=instance$1,from&&from!==to&&instance$1&&instance$1===oldInstance&&(to.leaveGuards.size||(to.leaveGuards=from.leaveGuards),to.updateGuards.size||(to.updateGuards=from.updateGuards))),instance$1&&to&&(!from||!isSameRouteRecord(to,from)||!oldInstance)&&(to.enterCallbacks[name]||[]).forEach(callback=>callback(instance$1))},{flush:`post`}),()=>{let route=routeToDisplay.value,currentName=props.name,matchedRoute=matchedRouteRef.value,ViewComponent=matchedRoute&&matchedRoute.components[currentName];if(!ViewComponent)return normalizeSlot(slots.default,{Component:ViewComponent,route});let routePropsOption=matchedRoute.props[currentName],component=h(ViewComponent,assign({},routePropsOption?routePropsOption===!0?route.params:typeof routePropsOption==`function`?routePropsOption(route):routePropsOption:null,attrs,{onVnodeUnmounted:vnode=>{vnode.component.isUnmounted&&(matchedRoute.instances[currentName]=null)},ref:viewRef}));return normalizeSlot(slots.default,{Component:component,route})||component}}});function normalizeSlot(slot,data){if(!slot)return null;let slotContent=slot(data);return slotContent.length===1?slotContent[0]:slotContent}var RouterView=RouterViewImpl;function createRouter(options){let matcher=createRouterMatcher(options.routes,options),parseQuery$1=options.parseQuery||parseQuery,stringifyQuery$1=options.stringifyQuery||stringifyQuery,routerHistory=options.history,beforeGuards=useCallbacks(),beforeResolveGuards=useCallbacks(),afterGuards=useCallbacks(),currentRoute=shallowRef(START_LOCATION_NORMALIZED),pendingLocation=START_LOCATION_NORMALIZED;isBrowser&&options.scrollBehavior&&`scrollRestoration`in history&&(history.scrollRestoration=`manual`);let normalizeParams=applyToParams.bind(null,paramValue=>``+paramValue),encodeParams=applyToParams.bind(null,encodeParam),decodeParams=applyToParams.bind(null,decode);function addRoute(parentOrRoute,route){let parent,record;return isRouteName(parentOrRoute)?(parent=matcher.getRecordMatcher(parentOrRoute),record=route):record=parentOrRoute,matcher.addRoute(record,parent)}function removeRoute(name){let recordMatcher=matcher.getRecordMatcher(name);recordMatcher&&matcher.removeRoute(recordMatcher)}function getRoutes(){return matcher.getRoutes().map(routeMatcher=>routeMatcher.record)}function hasRoute(name){return!!matcher.getRecordMatcher(name)}function resolve$1(rawLocation,currentLocation){if(currentLocation=assign({},currentLocation||currentRoute.value),typeof rawLocation==`string`){let locationNormalized=parseURL(parseQuery$1,rawLocation,currentLocation.path),matchedRoute$1=matcher.resolve({path:locationNormalized.path},currentLocation),href$1=routerHistory.createHref(locationNormalized.fullPath);return assign(locationNormalized,matchedRoute$1,{params:decodeParams(matchedRoute$1.params),hash:decode(locationNormalized.hash),redirectedFrom:void 0,href:href$1})}let matcherLocation;if(rawLocation.path!=null)matcherLocation=assign({},rawLocation,{path:parseURL(parseQuery$1,rawLocation.path,currentLocation.path).path});else{let targetParams=assign({},rawLocation.params);for(let key in targetParams)targetParams[key]??delete targetParams[key];matcherLocation=assign({},rawLocation,{params:encodeParams(targetParams)}),currentLocation.params=encodeParams(currentLocation.params)}let matchedRoute=matcher.resolve(matcherLocation,currentLocation),hash=rawLocation.hash||``;matchedRoute.params=normalizeParams(decodeParams(matchedRoute.params));let fullPath=stringifyURL(stringifyQuery$1,assign({},rawLocation,{hash:encodeHash(hash),path:matchedRoute.path})),href=routerHistory.createHref(fullPath);return assign({fullPath,hash,query:stringifyQuery$1===stringifyQuery?normalizeQuery(rawLocation.query):rawLocation.query||{}},matchedRoute,{redirectedFrom:void 0,href})}function locationAsObject(to){return typeof to==`string`?parseURL(parseQuery$1,to,currentRoute.value.path):assign({},to)}function checkCanceledNavigation(to,from){if(pendingLocation!==to)return createRouterError(ErrorTypes.NAVIGATION_CANCELLED,{from,to})}function push(to){return pushWithRedirect(to)}function replace(to){return push(assign(locationAsObject(to),{replace:!0}))}function handleRedirectRecord(to,from){let lastMatched=to.matched[to.matched.length-1];if(lastMatched&&lastMatched.redirect){let{redirect}=lastMatched,newTargetLocation=typeof redirect==`function`?redirect(to,from):redirect;return typeof newTargetLocation==`string`&&(newTargetLocation=newTargetLocation.includes(`?`)||newTargetLocation.includes(`#`)?newTargetLocation=locationAsObject(newTargetLocation):{path:newTargetLocation},newTargetLocation.params={}),assign({query:to.query,hash:to.hash,params:newTargetLocation.path==null?to.params:{}},newTargetLocation)}}function pushWithRedirect(to,redirectedFrom){let targetLocation=pendingLocation=resolve$1(to),from=currentRoute.value,data=to.state,force=to.force,replace$1=to.replace===!0,shouldRedirect=handleRedirectRecord(targetLocation,from);if(shouldRedirect)return pushWithRedirect(assign(locationAsObject(shouldRedirect),{state:typeof shouldRedirect==`object`?assign({},data,shouldRedirect.state):data,force,replace:replace$1}),redirectedFrom||targetLocation);let toLocation=targetLocation;toLocation.redirectedFrom=redirectedFrom;let failure;return!force&&isSameRouteLocation(stringifyQuery$1,from,targetLocation)&&(failure=createRouterError(ErrorTypes.NAVIGATION_DUPLICATED,{to:toLocation,from}),handleScroll(from,from,!0,!1)),(failure?Promise.resolve(failure):navigate$1(toLocation,from)).catch(error=>isNavigationFailure(error)?isNavigationFailure(error,ErrorTypes.NAVIGATION_GUARD_REDIRECT)?error:markAsReady(error):triggerError(error,toLocation,from)).then(failure$1=>{if(failure$1){if(isNavigationFailure(failure$1,ErrorTypes.NAVIGATION_GUARD_REDIRECT))return pushWithRedirect(assign({replace:replace$1},locationAsObject(failure$1.to),{state:typeof failure$1.to==`object`?assign({},data,failure$1.to.state):data,force}),redirectedFrom||toLocation)}else failure$1=finalizeNavigation(toLocation,from,!0,replace$1,data);return triggerAfterEach(toLocation,from,failure$1),failure$1})}function checkCanceledNavigationAndReject(to,from){let error=checkCanceledNavigation(to,from);return error?Promise.reject(error):Promise.resolve()}function runWithContext(fn){let app$1=installedApps.values().next().value;return app$1&&typeof app$1.runWithContext==`function`?app$1.runWithContext(fn):fn()}function navigate$1(to,from){let guards,[leavingRecords,updatingRecords,enteringRecords]=extractChangingRecords(to,from);guards=extractComponentsGuards(leavingRecords.reverse(),`beforeRouteLeave`,to,from);for(let record of leavingRecords)record.leaveGuards.forEach(guard=>{guards.push(guardToPromiseFn(guard,to,from))});let canceledNavigationCheck=checkCanceledNavigationAndReject.bind(null,to,from);return guards.push(canceledNavigationCheck),runGuardQueue(guards).then(()=>{guards=[];for(let guard of beforeGuards.list())guards.push(guardToPromiseFn(guard,to,from));return guards.push(canceledNavigationCheck),runGuardQueue(guards)}).then(()=>{guards=extractComponentsGuards(updatingRecords,`beforeRouteUpdate`,to,from);for(let record of updatingRecords)record.updateGuards.forEach(guard=>{guards.push(guardToPromiseFn(guard,to,from))});return guards.push(canceledNavigationCheck),runGuardQueue(guards)}).then(()=>{guards=[];for(let record of enteringRecords)if(record.beforeEnter)if(isArray(record.beforeEnter))for(let beforeEnter of record.beforeEnter)guards.push(guardToPromiseFn(beforeEnter,to,from));else guards.push(guardToPromiseFn(record.beforeEnter,to,from));return guards.push(canceledNavigationCheck),runGuardQueue(guards)}).then(()=>(to.matched.forEach(record=>record.enterCallbacks={}),guards=extractComponentsGuards(enteringRecords,`beforeRouteEnter`,to,from,runWithContext),guards.push(canceledNavigationCheck),runGuardQueue(guards))).then(()=>{guards=[];for(let guard of beforeResolveGuards.list())guards.push(guardToPromiseFn(guard,to,from));return guards.push(canceledNavigationCheck),runGuardQueue(guards)}).catch(err=>isNavigationFailure(err,ErrorTypes.NAVIGATION_CANCELLED)?err:Promise.reject(err))}function triggerAfterEach(to,from,failure){afterGuards.list().forEach(guard=>runWithContext(()=>guard(to,from,failure)))}function finalizeNavigation(toLocation,from,isPush,replace$1,data){let error=checkCanceledNavigation(toLocation,from);if(error)return error;let isFirstNavigation=from===START_LOCATION_NORMALIZED,state=isBrowser?history.state:{};isPush&&(replace$1||isFirstNavigation?routerHistory.replace(toLocation.fullPath,assign({scroll:isFirstNavigation&&state&&state.scroll},data)):routerHistory.push(toLocation.fullPath,data)),currentRoute.value=toLocation,handleScroll(toLocation,from,isPush,isFirstNavigation),markAsReady()}let removeHistoryListener;function setupListeners(){removeHistoryListener||=routerHistory.listen((to,_from,info)=>{if(!router$1.listening)return;let toLocation=resolve$1(to),shouldRedirect=handleRedirectRecord(toLocation,router$1.currentRoute.value);if(shouldRedirect){pushWithRedirect(assign(shouldRedirect,{replace:!0,force:!0}),toLocation).catch(noop$1);return}pendingLocation=toLocation;let from=currentRoute.value;isBrowser&&saveScrollPosition(getScrollKey(from.fullPath,info.delta),computeScrollPosition()),navigate$1(toLocation,from).catch(error=>isNavigationFailure(error,ErrorTypes.NAVIGATION_ABORTED|ErrorTypes.NAVIGATION_CANCELLED)?error:isNavigationFailure(error,ErrorTypes.NAVIGATION_GUARD_REDIRECT)?(pushWithRedirect(assign(locationAsObject(error.to),{force:!0}),toLocation).then(failure=>{isNavigationFailure(failure,ErrorTypes.NAVIGATION_ABORTED|ErrorTypes.NAVIGATION_DUPLICATED)&&!info.delta&&info.type===NavigationType.pop&&routerHistory.go(-1,!1)}).catch(noop$1),Promise.reject()):(info.delta&&routerHistory.go(-info.delta,!1),triggerError(error,toLocation,from))).then(failure=>{failure||=finalizeNavigation(toLocation,from,!1),failure&&(info.delta&&!isNavigationFailure(failure,ErrorTypes.NAVIGATION_CANCELLED)?routerHistory.go(-info.delta,!1):info.type===NavigationType.pop&&isNavigationFailure(failure,ErrorTypes.NAVIGATION_ABORTED|ErrorTypes.NAVIGATION_DUPLICATED)&&routerHistory.go(-1,!1)),triggerAfterEach(toLocation,from,failure)}).catch(noop$1)})}let readyHandlers=useCallbacks(),errorListeners=useCallbacks(),ready;function triggerError(error,to,from){markAsReady(error);let list=errorListeners.list();return list.length?list.forEach(handler$1=>handler$1(error,to,from)):console.error(error),Promise.reject(error)}function isReady(){return ready&¤tRoute.value!==START_LOCATION_NORMALIZED?Promise.resolve():new Promise((resolve$1$1,reject)=>{readyHandlers.add([resolve$1$1,reject])})}function markAsReady(err){return ready||(ready=!err,setupListeners(),readyHandlers.list().forEach(([resolve$1$1,reject])=>err?reject(err):resolve$1$1()),readyHandlers.reset()),err}function handleScroll(to,from,isPush,isFirstNavigation){let{scrollBehavior}=options;if(!isBrowser||!scrollBehavior)return Promise.resolve();let scrollPosition=!isPush&&getSavedScrollPosition(getScrollKey(to.fullPath,0))||(isFirstNavigation||!isPush)&&history.state&&history.state.scroll||null;return nextTick().then(()=>scrollBehavior(to,from,scrollPosition)).then(position=>position&&scrollToPosition(position)).catch(err=>triggerError(err,to,from))}let go=delta=>routerHistory.go(delta),started,installedApps=new Set,router$1={currentRoute,listening:!0,addRoute,removeRoute,clearRoutes:matcher.clearRoutes,hasRoute,getRoutes,resolve:resolve$1,options,push,replace,go,back:()=>go(-1),forward:()=>go(1),beforeEach:beforeGuards.add,beforeResolve:beforeResolveGuards.add,afterEach:afterGuards.add,onError:errorListeners.add,isReady,install(app$1){app$1.component(`RouterLink`,RouterLink),app$1.component(`RouterView`,RouterView),app$1.config.globalProperties.$router=router$1,Object.defineProperty(app$1.config.globalProperties,`$route`,{enumerable:!0,get:()=>unref(currentRoute)}),isBrowser&&!started&¤tRoute.value===START_LOCATION_NORMALIZED&&(started=!0,push(routerHistory.location).catch(err=>{}));let reactiveRoute={};for(let key in START_LOCATION_NORMALIZED)Object.defineProperty(reactiveRoute,key,{get:()=>currentRoute.value[key],enumerable:!0});app$1.provide(routerKey,router$1),app$1.provide(routeLocationKey,shallowReactive(reactiveRoute)),app$1.provide(routerViewLocationKey,currentRoute);let unmountApp=app$1.unmount;installedApps.add(app$1),app$1.unmount=function(){installedApps.delete(app$1),installedApps.size<1&&(pendingLocation=START_LOCATION_NORMALIZED,removeHistoryListener&&removeHistoryListener(),removeHistoryListener=null,currentRoute.value=START_LOCATION_NORMALIZED,started=!1,ready=!1),unmountApp()}}};function runGuardQueue(guards){return guards.reduce((promise,guard)=>promise.then(()=>runWithContext(guard)),Promise.resolve())}return router$1}function useRouter(){return inject(routerKey)}function useRoute(_name){return inject(routeLocationKey)}function spawnUiApp(appName,appId,params,apps){let props=params?params.props:null,appKey=`${appName}${appId}`;apps.push({name:appName,appId,appKey,comp:appName,props,teleport:`#${appName+appId}`})}function destroyUiApp(appName,apps){let index=apps.findIndex(x=>x.name===appName);index>-1&&apps.splice(index,1)}function registerApps(app$1,componentsMap){Object.keys(componentsMap).forEach(key=>app$1.component(key,componentsMap[key]))}var _sfc_main$325={};function _sfc_render$5(_ctx,_cache){return null}var layoutEmpty_default=__plugin_vue_export_helper_default(_sfc_main$325,[[`render`,_sfc_render$5]]);const LAYOUT_ALIGNMENTS={left:`flex-start`,right:`flex-end`,center:`center`};var _sfc_main$324={},_hoisted_1$287={class:`layout-wrapper layout-safezones`},_hoisted_2$235={class:`layout-content`};function _sfc_render$4(_ctx,_cache,$props,$setup,$data,$options){return openBlock(),createElementBlock(`div`,_hoisted_1$287,[createBaseVNode(`div`,_hoisted_2$235,[renderSlot(_ctx.$slots,`default`,{},()=>[_cache[0]||=createTextVNode(`Content here`,-1)])])])}var layoutSingle_default=__plugin_vue_export_helper_default(_sfc_main$324,[[`render`,_sfc_render$4]]);const useEvents=(onDispose=onBeforeUnmount)=>{let bridge$4=useBridge(),events$3={_on:{},_once:{},on(name,func){name in events$3._on||(events$3._on[name]=[]),events$3._on[name].indexOf(func)===-1&&(bridge$4.events.on(name,func),events$3._on[name].push(func))},once(name,func){name in events$3._once||(events$3._once[name]=[]),events$3._once[name].indexOf(func)===-1&&(bridge$4.events.once(name,()=>{let idx=events$3._once[name].indexOf(func);idx>-1&&events$3._once[name].splice(idx,1)}),bridge$4.events.once(name,func),events$3._once[name].push(func))},off(name=void 0,func=void 0){if(!name){for(let name$1 in events$3._on){for(let func$1 of events$3._on[name$1])bridge$4.events.off(name$1,func$1);delete events$3._on[name$1]}return}if(name in events$3._on)if(func){let idx=events$3._on[name].indexOf(func);idx>-1&&(bridge$4.events.off(name,func),events$3._on[name].splice(idx,1)),events$3._on[name].length===0&&delete events$3._on[name]}else{for(let func$1 of events$3._on[name])bridge$4.events.off(name,func$1);delete events$3._on[name]}},emit(name,...values){bridge$4.events.emit(name,...values)}};return onDispose(()=>{for(let type of[`_on`,`_once`])for(let name in events$3[type]){for(let func of events$3[type][name])bridge$4.events.off(name,func);delete events$3[type][name]}}),events$3},useStreams=(names,callback,onDispose=onBeforeUnmount)=>{let bridge$4=useBridge(),enabled=!1,streams={on(){enabled||(enabled=!0,bridge$4.streams.add(names),bridge$4.events.on(`onStreamsUpdate`,callback))},off(){enabled&&(enabled=!1,bridge$4.streams.remove(names),bridge$4.events.off(`onStreamsUpdate`,callback))}};return streams.on(),onDispose(streams.off),streams};var hints_default=`ui.hints.quickSteerResponse,ui.hints.raceBrakesEffectiveness,ui.hints.quickCameraMovement,ui.hints.grabVehicleParts,ui.hints.funStabilityControl,ui.hints.recoverVehicle,ui.hints.oldCarsBurn,ui.hints.smokingWheels,ui.hints.carsBurnFuel,ui.hints.delicateCars,ui.hints.stabilityControlPresent,ui.hints.absWasOptional,ui.hints.installRollCage,ui.hints.spatialNavigation,ui.hints.repairHood,ui.hints.slowMotionPhysics,ui.hints.removeRearSeats,ui.hints.tuning,ui.hints.customLicensePlate,ui.hints.driveAtNight,ui.hints.moonGravity,ui.hints.unlockExtraFunctionality,ui.hints.playMultiseat,ui.hints.increaseGroundClearance,ui.hints.tiresBurstOnBumps,ui.hints.blueSmokeIsPistonDamage,ui.hints.keepTheEngineUpright,ui.hints.thermalDebugApp,ui.hints.rollPitchApps,ui.hints.cruiseControlApp,ui.hints.driveTheCanon,ui.hints.vehicleSkins,ui.hints.toggleMods,ui.hints.importveFramerate,ui.hints.photoModeMenu,ui.hints.publishScreenshots,ui.hints.towTrailer,ui.hints.brakesAndSteeringVary,ui.hints.countersteerEarly,ui.hints.startSlow,ui.hints.parkingbrakeForTurning,ui.hints.carefulWithOldSportsCars,ui.hints.corneringWithKeyboard,ui.hints.adaptToBadRoads,ui.hints.notAllCarsCanRace,ui.hints.changeBrakePads,ui.hints.useTurnSignals,ui.hints.showStandalonePcs,ui.hints.tweakFOV,ui.hints.driveWithMouse,ui.hints.liftOffOversteer,ui.hints.snapOversteer,ui.hints.slideBackWithParkingBrake,ui.hints.customizeSpecializedBindings,ui.hints.toggleFogLights,ui.hints.toggleLightBars,ui.hints.TrackIRSupported,ui.hints.chooseShiftingMode,ui.hints.saveRestoreVehicleHome,ui.hints.switchVehicle,ui.hints.coolantVaporizes,ui.hints.dontRunIntoTheCar`.split(`,`),_hoisted_1$286={key:0,class:`progress-box`},_hoisted_2$234={class:`progress-icon-group`},_hoisted_3$208={class:`progress-bar-container`},_hoisted_4$178={class:`progress-status`},_hoisted_5$153={class:`progress-history`},_hoisted_6$132={class:`custom-left-container`},_hoisted_7$118={key:0,class:`custom-text-panel`},_hoisted_8$99={key:1,class:`text`},_hoisted_9$89={key:1,class:`custom-indeterminate-panel`},_hoisted_10$77={class:`custom-right-container`},_hoisted_11$69={key:2,class:`tips-bar`},_hoisted_12$57={class:`tips-bar-title`},_hoisted_13$49={class:`tips-bar-tip`},_hoisted_14$44={key:0,class:`loading-cache`},_hoisted_15$42=[`src`],imagesAmount=18,activeRepeatTime=1e4,fadeInDefault=1e3,fadeOutDefault=2e3,_sfc_main$323={__name:`LoadingScreen`,setup(__props){useCssVars(_ctx=>({v79c091d8:fadeInTimeVar.value,v07559aed:fadeOutTimeVar.value}));let events$3=useEvents(),{lua}=useBridge(),navBlocker=useUINavBlocker(),lastImageNum=-1,repeatTimer=null,customTimer=null,iconsList=[{id:`terrain`,icon:icons.terrain},{id:`environment`,icon:icons.water},{id:`forest`,icon:icons.trafficCone},{id:`meshes`,icon:icons.garage01},{id:`roads`,icon:icons.road},{id:`beamng`,icon:icons.beamNG}],state=reactive({active:!1,visible:!1,fading:!1,shown:!1,autoActivate:!0,highSeas:!1,mode:`progress`,image:null,iconState:{},currentEntries:[],historyEntriesDisplay:[],customContent:null,fadeInTime:fadeInDefault,fadeOutTime:fadeOutDefault,customPause:-1});function resetState(){state.mode=`progress`,state.customContent=null,state.iconState={},state.currentEntries=[],state.historyEntriesDisplay=[],state.fadeInTime=fadeInDefault,state.fadeOutTime=fadeOutDefault,state.customPause=-1}let tip=ref(``),setTip=(txt=void 0,_retrying=!1)=>{let idx=~~(Math.random()*hints_default.length);tip.value=txt||hints_default[idx],(!tip.value||tip.value===`undefined`)&&(logger_default.debug(`Loading Screen tip is undefined!\nARG: ${JSON.stringify(txt)} TIP: ${JSON.stringify(tip.value)} IDX: ${idx}/${hints_default.length}`),_retrying?tip.value=``:setTip(void 0,!0))},fadeInTimeVar=computed(()=>state.fadeInTime+`ms`),fadeOutTimeVar=computed(()=>state.fadeOutTime+`ms`),progressValue=computed(()=>state.currentEntries[0]?.progress||0),currentStatus=computed(()=>state.currentEntries[0]?.message||``);events$3.on(`LoadingScreen`,data=>{if(window.beamng?.ingame){if((!data||typeof data!=`object`)&&(data={}),state.autoActivate=!1,state.active=!!data.active,data.custom&&(state.mode=`custom`,state.fadeInTime=data.custom.fadeIn>0?data.custom.fadeIn*1e3:state.fadeInTime||0,state.fadeOutTime=data.custom.fadeOut>0?data.custom.fadeOut*1e3:state.fadeOutTime||0),state.active)data.custom?(state.customPause=data.custom.pause?data.custom.pause*1e3:-1,state.customContent=data.custom.data,state.customContent?.image&&(state.image=state.customContent.image)):(resetState(),window.bngVue.gotoAngularState(`blank`)),setTip(state.customContent?.tips);else if(state.mode===`progress`&&`gotoMainMenu`in data){let args=[];data.gotoMainMenu?args.push(`menu.mainmenu`):args.push(`menu`,[`loading`]),window.globalAngularRootScope?.$broadcast(`ChangeState`,...args),window.vueEventBus?.emit(`onChangeState`,...args)}}}),events$3.on(`UpdateLoadingProgressV2`,data=>{if(!window.beamng?.ingame||!state.autoActivate&&!state.active)return;let{currentEntries,historyEntries}=data;(!currentEntries||!Array.isArray(currentEntries))&&(currentEntries=[]),(!historyEntries||!Array.isArray(historyEntries))&&(historyEntries=[]),state.currentEntries=currentEntries,state.historyEntriesDisplay=historyEntries.slice(Math.max(historyEntries.length-3,1)),state.iconState={};for(let{name,progress}of currentEntries)state.iconState[name.toLowerCase()]=progress;for(let{name}of historyEntries)state.iconState[name.toLowerCase()]=100;state.autoActivate&&(state.active=currentEntries.length>0||historyEntries.length>0)});let onFadeIn=()=>{state.fading=!1,state.mode===`progress`?(lua.core_gamestate.loadingScreenActive(),repeatTimer=setTimeout(()=>{lua.core_gamestate.loadingScreenActive()},activeRepeatTime)):state.mode===`custom`&&(lua.extensions.ui_fadeScreen.onScreenFadeStateDelayed(1),state.customPause!==-1&&(customTimer=setTimeout(()=>{lua.extensions.ui_fadeScreen.onScreenFadeStateDelayed(2)},state.customPause*1e3)))},onFadeOut=()=>{state.fading=!1,state.shown=!1,state.mode===`custom`&&lua.extensions.ui_fadeScreen.onScreenFadeStateDelayed(3),resetState(),loadNextImage()};watch(()=>state.active,(newActive,oldActive)=>{window.beamng?.ingame&&(newActive&&!oldActive?activateLoading():!newActive&&oldActive&&deactivateLoading())});let activateLoading=()=>{state.active&&(deactivateLoading.cancel(),navBlocker.allowOnly([]),nextTick(()=>{state.visible=!0,state.fading=!0,state.shown=!0}))},deactivateLoading=debounce(()=>{state.active||(clearTimers(),navBlocker.clear(),nextTick(()=>{state.visible=!1,state.fading=!0}))},100),getRandomImageNum=()=>{let rnd=~~(Math.random()*imagesAmount)+1;return rnd===lastImageNum?getRandomImageNum():(lastImageNum=rnd,rnd)},getNextImageUrl=()=>{let url;return url=state.highSeas?`images/mainmenu/unofficial_version.jpg`:`images/loading/drive/${getRandomImageNum()}.jpg`,getAssetURL(url)},loadNextImage=async()=>{let url=getNextImageUrl();state.image!==url&&(await loadImage$1(url),state.image=url)},loadImage$1=url=>new Promise((resolve$1,reject)=>{let img=new Image;img.onload=()=>resolve$1(url),img.onerror=()=>reject(url),img.src=url}),clearTimers=()=>{repeatTimer&&=(clearTimeout(repeatTimer),null),customTimer&&=(clearTimeout(customTimer),null)},initLoadingScreen=()=>bngApi.engineLua(`sailingTheHighSeas`,async ahoy=>{state.highSeas=ahoy===!0,await loadNextImage(),setTip(),lua.core_gamestate.loadingScreenActive(),window.loadingTest=active=>{events$3.emit(`LoadingScreen`,{active})}});return onMounted(()=>{linkLoadingScreenState(state),initLoadingScreen()}),onUnmounted(()=>clearTimers()),(_ctx,_cache)=>(openBlock(),createElementBlock(Fragment,null,[createVNode(Transition,{name:`loading-fade`,onAfterEnter:onFadeIn,onAfterLeave:onFadeOut},{default:withCtx(()=>[state.visible?(openBlock(),createElementBlock(`dialog`,{key:0,open:``,class:normalizeClass([`loading-screen`,`loading-screen-${state.mode}`])},[createBaseVNode(`div`,{class:`loading-background`,style:normalizeStyle({backgroundImage:state.image?`url('${state.image}')`:`none`})},null,4),state.mode===`progress`?(openBlock(),createElementBlock(`div`,_hoisted_1$286,[createBaseVNode(`div`,_hoisted_2$234,[(openBlock(),createElementBlock(Fragment,null,renderList(iconsList,iconInfo=>createBaseVNode(`div`,{key:iconInfo.id,class:`progress-icon-box`,style:normalizeStyle({backgroundPosition:`0 ${state.iconState[iconInfo.id]||0}%`})},[createVNode(unref(bngIcon_default),{type:iconInfo.icon,color:`#fff`,class:`progress-icon`},null,8,[`type`])],4)),64))]),createBaseVNode(`div`,_hoisted_3$208,[createVNode(unref(bngProgressBar_default),{class:`progress-bar`,gradient:``,"show-value-label":!1,min:0,max:100,value:progressValue.value},null,8,[`value`])]),createBaseVNode(`div`,_hoisted_4$178,toDisplayString(currentStatus.value||_ctx.$tt(`ui.common.loading`)),1),createBaseVNode(`div`,_hoisted_5$153,[(openBlock(!0),createElementBlock(Fragment,null,renderList(state.historyEntriesDisplay,(item,idx)=>(openBlock(),createElementBlock(`div`,{key:idx},toDisplayString(item.message),1))),128))])])):createCommentVNode(``,!0),state.mode===`custom`?(openBlock(),createElementBlock(`div`,{key:1,class:normalizeClass([`custom-box`,{"custom-with-tips":state.customContent?.tips}])},[createBaseVNode(`div`,_hoisted_6$132,[state.customContent&&(state.customContent.title||state.customContent.text)?(openBlock(),createElementBlock(`div`,_hoisted_7$118,[state.customContent.title?(openBlock(),createBlock(unref(bngScreenHeading_default),{key:0,preheadings:[_ctx.$tt(state.customContent.subtitle)]},{default:withCtx(()=>[createTextVNode(toDisplayString(_ctx.$tt(state.customContent.title)),1)]),_:1},8,[`preheadings`])):createCommentVNode(``,!0),state.customContent.text?(openBlock(),createElementBlock(`p`,_hoisted_8$99,[createVNode(unref(dynamicComponent_default),{"translate-id":state.customContent.text,bbcode:``,"translate-context":``},null,8,[`translate-id`])])):createCommentVNode(``,!0)])):(openBlock(),createElementBlock(`div`,_hoisted_9$89,[createVNode(unref(bngScreenHeading_default),null,{default:withCtx(()=>[createTextVNode(toDisplayString(_ctx.$tt(`ui.common.loading.short`)),1)]),_:1}),createVNode(unref(bngProgressBar_default),{class:`progress-bar`,gradient:``,"show-value-label":!1,min:0,max:100,indeterminate:``})]))]),createBaseVNode(`div`,_hoisted_10$77,[state.customContent&&state.customContent.image?(openBlock(),createElementBlock(`div`,{key:0,class:`custom-image-panel`,style:normalizeStyle({backgroundImage:`url('${state.customContent.image}')`})},null,4)):createCommentVNode(``,!0)])],2)):createCommentVNode(``,!0),state.mode===`progress`||state.customContent?.tips?(openBlock(),createElementBlock(`div`,_hoisted_11$69,[createBaseVNode(`div`,_hoisted_12$57,toDisplayString(_ctx.$tt(`ui.loadingScreen.tips`))+`:`,1),createBaseVNode(`div`,_hoisted_13$49,[createVNode(unref(dynamicComponent_default),{"translate-id":tip.value,bbcode:``},null,8,[`translate-id`])])])):createCommentVNode(``,!0)],2)):createCommentVNode(``,!0)]),_:1}),state.image?(openBlock(),createElementBlock(`div`,_hoisted_14$44,[createBaseVNode(`img`,{src:state.image,alt:``},null,8,_hoisted_15$42)])):createCommentVNode(``,!0)],64))}},LoadingScreen_default=__plugin_vue_export_helper_default(_sfc_main$323,[[`__scopeId`,`data-v-2f135df0`]]),_hoisted_1$285={class:`pause-button-wrapper`},_sfc_main$322={__name:`pauseButton`,props:{teleportTo:[String,Object]},setup(__props){let route=useRoute(),events$3=useEvents(),gameContext=useGameContextStore(),isGamePaused=ref(!1),physicsMaybePaused=ref(!1),replayActive=ref(!1),replayPaused=ref(!1);events$3.on(`physicsStateChanged`,state=>{physicsMaybePaused.value=!state}),events$3.on(`replayStateChanged`,core_replay=>{replayActive.value=core_replay.state===`playback`,replayPaused.value=replayActive.value&&core_replay.paused}),events$3.on(`simTimeAuthority.pauseStateChanged`,data=>{isGamePaused.value=data.paused});let isInMenu=computed(()=>route.name?.startsWith(`menu`)&&!gameContext.activities?.length&&sysInfo_default.gameState.value!==void 0&&sysInfo_default.gameState.value!==`loading`),isPhysicsPaused=computed(()=>physicsMaybePaused.value),isReplayPaused=computed(()=>replayActive.value&&replayPaused.value),showPauseButton=computed(()=>isInMenu.value||isPhysicsPaused.value||isReplayPaused.value),isPaused=computed(()=>isGamePaused.value||isPhysicsPaused.value||isReplayPaused.value),buttonState=computed(()=>isInMenu.value&&isPaused.value?`menu-paused`:isInMenu.value?`menu`:isPaused.value?`paused`:`default`),togglePause=()=>{Lua_default.simTimeAuthority.togglePause()};return(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$285,[(openBlock(),createBlock(Teleport,{disabled:!__props.teleportTo,to:__props.teleportTo},[withDirectives((openBlock(),createBlock(unref(bngButton_default),{class:normalizeClass([`pause-button`,buttonState.value]),accent:unref(ACCENTS).custom,"no-sound":``,onClick:togglePause,"bng-no-nav":``},{default:withCtx(()=>[createVNode(unref(bngBinding_default),{class:`pause-button-binding-bg`,action:`pause`}),createVNode(unref(bngIcon_default),{class:`pause-button-icon`,type:isPaused.value?unref(icons).pause:unref(icons).play},null,8,[`type`])]),_:1},8,[`class`,`accent`])),[[vShow,showPauseButton.value],[unref(BngTooltip_default),_ctx.$tt(`ui.inputActions.general.pause.title`),void 0,{bottom:!0}]])],8,[`disabled`,`to`]))]))}},pauseButton_default=__plugin_vue_export_helper_default(_sfc_main$322,[[`__scopeId`,`data-v-ea9a26b4`]]),UIAppStorage,setupDone;const useUIApps=()=>(setupDone||setup(),service);var setup=()=>{UIAppStorage||=window.UIAppStorage,setupDone=!!UIAppStorage},setLayout=layoutName=>{layoutName==`blank`?_broadcast(`appContainer:clear`):_broadcast(`appContainer:loadLayoutByType`,layoutName)},setVisible=state=>{_broadcast(`ShowApps`,!!state)},service={setLayout,setVisible,get currentLayout(){return UIAppStorage.currentLayout}},_broadcast=(...params)=>{window.globalAngularRootScope&&window.globalAngularRootScope.$broadcast(...params)},_sfc_main$321={};function _sfc_render$3(_ctx,_cache){return openBlock(),createElementBlock(`span`)}var NotFound_default=__plugin_vue_export_helper_default(_sfc_main$321,[[`render`,_sfc_render$3]]);function useGridSelector(backendName=`gridSelector`,defaultPath={keys:[`missions`]},defaultDetailsMode=`detail`){let currentPath=ref(defaultPath),previousPath=ref(null),groups=ref([]),filterList=ref([]),filterByProp=ref([]),commonFilters=ref([]),lockedFiltersByProp=ref([]),activeFilters=ref([]),onlyCommonFilters=ref(!0),detailsMode=ref(defaultDetailsMode),selectedItem=ref(null),selectedItemDetails=ref(null),prevSelectedItem=ref(null),previewItem=ref(null),previewItemDetails=ref(null),managementDetails=ref(null),autoFocusKey=ref(null),showScreenHeader=ref(!0),screenHeaderTitle=ref(`Grid Selector`),screenHeaderPath=ref([{text:`Menu`,gotoAngularState:`menu`}]),{events:events$3}=useBridge(),backFromDetailsCallback=null,refreshAllHandler=backendName$1=>{backendName$1===backendName$1&&(logger_default.debug(`gridSelectorRefreshAll`),loadTiles(),loadFilters(),loadManagementDetails())},refreshCurrentItemDetailsHandler=backendName$1=>{backendName$1===backendName$1&&(logger_default.debug(`gridSelectorRefreshCurrentItemDetails`),setSelectedItem(selectedItem.value))};events$3.on(`gridSelectorRefreshAll`,refreshAllHandler),events$3.on(`gridSelectorRefreshCurrentItemDetails`,refreshCurrentItemDetailsHandler);let log=(...args)=>{},displayData=ref([]),searchText$1=ref(``);async function getSearchText(){try{let data=await Lua_default.ui_gridSelector.getSearchText(backendName);return searchText$1.value=data||``,data||``}catch(error){return logger_default.error(`Failed to get search text:`,error),``}}async function setSearchText(value){try{await Lua_default.ui_gridSelector.setSearchText(backendName,value),searchText$1.value=value||``,await loadTiles(),await loadFilters(),await updateScreenHeaderData()}catch(error){logger_default.error(`Failed to set search text:`,error)}}let isInitializing=ref(!1),safeArray=arr=>Array.isArray(arr)?arr:[];async function setCurrentPath(path){currentPath.value=path,await loadTiles()}async function loadTiles(){currentPath.value;try{let data=await Lua_default.ui_gridSelector.getTiles(backendName,currentPath.value,previousPath.value!==currentPath.value);if(Lua_default.ui_gridSelector.profilerFinish(backendName,`received lua data on UI`),groups.value=safeArray(data),groups.value,!selectedItem.value&&(detailsMode.value===`advanced`||detailsMode.value===`detail`)&&previousPath.value!==currentPath.value)for(let group of groups.value)for(let tile of group.tiles)tile.isDefaultSelected&&(autoFocusKey.value=tile.key,tile.name,tile.forceAutoFocus&&backFromDetailsCallback());previousPath.value=currentPath.value,Lua_default.ui_gridSelector.profilerFinish(backendName,`loaded tiles into reactive state`)}catch(error){logger_default.error(`Failed to load tiles:`,error)}}async function loadFilters(){try{let data=await Lua_default.ui_gridSelector.getFilters(backendName);filterList.value=safeArray(data.filterList),filterByProp.value=data.filterByProp,commonFilters.value=safeArray(data.commonFilters)||[],lockedFiltersByProp.value=data.lockedFiltersByProp||[],activeFilters.value=safeArray(data.activeFilters),onlyCommonFilters.value=data.onlyCommonFilters,filterList.value,filterByProp.value,activeFilters.value,onlyCommonFilters.value}catch(error){logger_default.error(`Failed to load filters:`,error)}}async function loadManagementDetails(){try{managementDetails.value=await Lua_default.ui_gridSelector.getManagementDetails(backendName),managementDetails.value}catch(error){logger_default.error(`Failed to load management details:`,error)}}async function toggleFilter(propName,option){try{await Lua_default.ui_gridSelector.toggleFilter(backendName,propName,option),await loadFilters(),await loadTiles(),await updateScreenHeaderData()}catch(error){logger_default.error(`Failed to toggle filter:`,error)}}async function updateRangeFilter(propName,min$1,max$1){try{await Lua_default.ui_gridSelector.updateRangeFilter(backendName,propName,min$1,max$1),await loadFilters(),await loadTiles(),await updateScreenHeaderData()}catch(error){logger_default.error(`Failed to update range filter:`,error)}}async function resetRangeFilter(propName){console.log(`Resetting range filter:`,propName);try{await Lua_default.ui_gridSelector.resetRangeFilter(backendName,propName),await loadFilters(),await loadTiles(),await updateScreenHeaderData()}catch(error){logger_default.error(`Failed to reset range filter:`,error)}}async function resetSetFilter(propName){try{await Lua_default.ui_gridSelector.resetSetFilter(backendName,propName),await loadFilters(),await loadTiles(),await updateScreenHeaderData()}catch(error){logger_default.error(`Failed to reset set filter:`,error)}}async function loadDisplayData(){try{displayData.value=safeArray(await Lua_default.ui_gridSelector.getDisplayDataOptions(backendName));let searchOption=displayData.value.find(option=>option.key===`searchText`);searchOption&&(searchText$1.value=searchOption.value||``),displayData.value}catch(error){logger_default.error(`Failed to load display data:`,error)}}async function updateDisplayData(key,value){try{await Lua_default.ui_gridSelector.setDisplayDataOption(backendName,key,value),await loadDisplayData(),await loadTiles(),await updateScreenHeaderData()}catch(error){logger_default.error(`Failed to update display data:`,error)}}async function resetDisplayDataToDefaults(){try{await Lua_default.ui_gridSelector.resetDisplayDataToDefaults(backendName),await loadDisplayData(),await loadTiles(),await updateScreenHeaderData()}catch(error){logger_default.error(`Failed to reset display data to defaults:`,error)}}function setDetailsMode(mode){detailsMode.value=mode}async function setSelectedItem(item){if(!item||!item.showDetails){autoFocusKey.value=null,selectedItem.value=null,selectedItemDetails.value=null,await loadManagementDetails();return}try{item.showDetails;let details=await Lua_default.ui_gridSelector.getDetails(backendName,item.showDetails);autoFocusKey.value=item.key,selectedItem.value=item,selectedItemDetails.value=details,details?.paintData&&details?.paints&&selectedItemDetails.value?.paints&&(selectedItemDetails.value.paints.multiPaintSetups=safeArray(selectedItemDetails.value.paints.multiPaintSetups),selectedItemDetails.value.paints.factoryPaints=safeArray(selectedItemDetails.value.paints.factoryPaints)),setDetailsMode(`detail`)}catch(error){logger_default.error(`Failed to get item details:`,error),autoFocusKey.value=null,selectedItem.value=item,selectedItemDetails.value=null}}async function clearSelectedItem(){selectedItem.value=null,selectedItemDetails.value=null,await loadManagementDetails()}async function setPreviewItem(item){if(!item||!item.showDetails){previewItem.value=null,previewItemDetails.value=null;return}try{let details=await Lua_default.ui_gridSelector.getDetails(backendName,item.showDetails);previewItem.value=item,previewItemDetails.value=details,setDetailsMode(`detail`)}catch{previewItem.value=item,previewItemDetails.value=null}}function clearPreviewItem(){previewItem.value=null,previewItemDetails.value=null}let activeItem=computed(()=>selectedItem.value||previewItem.value),activeItemDetails=computed(()=>selectedItem.value?selectedItemDetails.value:previewItemDetails.value);async function executeButton(buttonId,additionalData){try{if(additionalData?.waitForLoadingScreen)window.vueEventBus?.emit(`LoadingScreen`,{active:!0}),await startLoading(async()=>{await waitForLoadingScreenFadeIn();let data=await Lua_default.ui_gridSelector.executeButton(backendName,buttonId,additionalData);data&&data.gotoPath&&setCurrentPath(data.gotoPath)});else{let data=await Lua_default.ui_gridSelector.executeButton(backendName,buttonId,additionalData);data&&data.gotoPath&&setCurrentPath(data.gotoPath)}}catch(error){logger_default.error(`Failed to execute button:`,error)}}let executeButtonHandler=(backendName$1,buttonId,additionalData)=>{backendName$1===backendName$1&&executeButton(buttonId,additionalData)};events$3.on(`gridSelectorExecuteButton`,executeButtonHandler);async function toggleFavourite(item){await Lua_default.ui_gridSelector.toggleFavourite(backendName,item.showDetails);let details=await Lua_default.ui_gridSelector.getDetails(backendName,item.showDetails);selectedItem.value=item,selectedItemDetails.value=details,await loadTiles()}function clearSearch(){setSearchText(``)}function updateSearch(newSearchText){setSearchText(newSearchText||``)}function commitSearch(){setSearchText(searchText$1.value||``)}function isFilterLocked(propName,option=null){return lockedFiltersByProp.value[propName]?option?lockedFiltersByProp.value[propName][option]!==void 0:Object.keys(lockedFiltersByProp.value[propName]).length>0:!1}async function updateScreenHeaderData(){try{let headerData=await Lua_default.ui_gridSelector.getScreenHeaderTitleAndPath(backendName,currentPath.value);screenHeaderTitle.value=headerData.title||`Grid Selector`,screenHeaderPath.value=headerData.pathSegments}catch(error){logger_default.error(`Failed to update screen header title:`,error),screenHeaderTitle.value=`Grid Selector`,screenHeaderPath.value=[{text:`Menu`,gotoAngularState:`menu`}]}}function isFilterOptionLocked(propName,option){return isFilterLocked(propName,option)}function isRangeFilterLocked(propName){return isFilterLocked(propName)}watch(currentPath,()=>{clearSelectedItem(),clearPreviewItem(),updateScreenHeaderData()}),watch([filterByProp,activeFilters],()=>{clearSelectedItem(),clearPreviewItem(),updateScreenHeaderData()}),watch(displayData,()=>{updateScreenHeaderData()},{deep:!0});function notifyUIReady(tag){Lua_default.ui_gridSelector.profilerFinish(backendName,tag)}function setOnBackFromDetailsCallback(callback){backFromDetailsCallback=callback}async function initialize(){if(!isInitializing.value)try{isInitializing.value=!0,await Promise.all([loadFilters(),loadDisplayData(),loadManagementDetails(),getSearchText()])}catch(error){logger_default.error(`Failed to initialize GridSelector composable:`,error)}finally{isInitializing.value=!1}}return onUnmounted(()=>{logger_default.debug(`GridSelector composable unmounting`),events$3.off(`gridSelectorRefreshAll`,refreshAllHandler),events$3.off(`gridSelectorRefreshCurrentItemDetails`,refreshCurrentItemDetailsHandler),events$3.off(`gridSelectorExecuteButton`,executeButtonHandler)}),{groups,filterList,filterByProp,lockedFiltersByProp,commonFilters,activeFilters,onlyCommonFilters,displayData,currentPath,detailsMode,selectedItem,selectedItemDetails,prevSelectedItem,previewItem,previewItemDetails,activeItem,activeItemDetails,managementDetails,isInitializing,searchText:searchText$1,getSearchText,setSearchText,autoFocusKey,showScreenHeader,screenHeaderTitle,screenHeaderPath,initialize,setCurrentPath,loadTiles,loadFilters,loadManagementDetails,toggleFilter,updateRangeFilter,resetRangeFilter,resetSetFilter,loadDisplayData,updateDisplayData,resetDisplayDataToDefaults,setDetailsMode,setSelectedItem,clearSelectedItem,setPreviewItem,clearPreviewItem,executeButton,notifyUIReady,isFilterLocked,isFilterOptionLocked,isRangeFilterLocked,toggleFavourite,clearSearch,updateSearch,commitSearch,updateScreenHeaderData,exploreFolder:function(path){Lua_default.ui_gridSelector.exploreFolder(backendName,path)},goToMod:function(modId){Lua_default.ui_gridSelector.goToMod(backendName,modId)},setOnBackFromDetailsCallback}}var _hoisted_1$284=[`bng-scoped-nav-autofocus`],_hoisted_2$233={class:`image-container`},_hoisted_3$207={key:0,class:`sub-element-count-badge`},_hoisted_4$177={class:`item-label`},_hoisted_5$152={class:`item-name`},_hoisted_6$131={class:`icons-container`},_hoisted_7$117=[`src`],_hoisted_8$98={key:0,class:`sub-element-count-badge`},_hoisted_9$88={key:1},sizes={tiny:{width:7.5,margin:.5,fontSize:.8},small:{width:9.5,margin:.5,fontSize:1},medium:{width:12,margin:.5,fontSize:1},large:{width:16,margin:.5,fontSize:1},huge:{width:20,margin:.5,fontSize:1.5},list:{width:22,height:3,margin:.5,fontSize:.9}},thumbAspectRatio=16/9.5,captionHeightEm=2,getSizeCalc=displaySize=>ctx=>{let size$3=sizes[displaySize]||sizes.medium;if(displaySize===`list`)return{width:size$3.width,height:size$3.height,margin:size$3.margin};let height$1=size$3.width/thumbAspectRatio+size$3.fontSize*captionHeightEm-size$3.margin*2;return{width:size$3.width,height:height$1,margin:size$3.margin}},__default__$6={getSizeCalc},_sfc_main$320=Object.assign(__default__$6,{__name:`Tile`,props:{tile:{type:Object,required:!0},isFavourite:Boolean,isConfig:Boolean,displaySize:String,tileImagesTopAligned:{type:Boolean,default:!1}},emits:[`focus`,`blur`,`click`,`dblclick`],setup(__props,{expose:__expose,emit:__emit}){let{showIfController}=storeToRefs(controls_default()),props=__props,gridSelectionState=inject(`gridSelectionState`,null),state=computed(()=>{let res={selected:!1,dimmed:!1,isAutoFocused:!1};return gridSelectionState&&gridSelectionState.value&&(res.selected=gridSelectionState.value.inDetails&&gridSelectionState.value.activeItemKey===props.tile.key,res.dimmed=showIfController.value&&gridSelectionState.value.inDetails&&gridSelectionState.value.activeItemKey!==props.tile.key,res.isAutoFocused=gridSelectionState.value.autoFocusKey===props.tile.key),res}),emit$1=__emit,elTile=ref(null);__expose({getElement:()=>elTile.value});let isListItem=computed(()=>props.displaySize===`list`);function onClick(){emit$1(`click`)}function onFocus(){emit$1(`focus`)}function onBlur(){emit$1(`blur`)}return(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,{class:normalizeClass([`tile-wrapper`,`tile-size-${__props.displaySize}`]),style:normalizeStyle({"--tile-font-size":sizes[__props.displaySize].fontSize+`em`})},[_cache[0]||=createBaseVNode(`div`,{class:`tile-bg`},null,-1),withDirectives((openBlock(),createElementBlock(`div`,{ref_key:`elTile`,ref:elTile,"bng-scoped-nav-autofocus":state.value.isAutoFocused,class:normalizeClass({tile:!0,selected:state.value.selected,dimmed:state.value.dimmed,auxiliary:__props.tile.isAuxiliary,"is-career-only":__props.tile.isCareerOnly}),onClick:withModifiers(onClick,[`stop`]),onFocus,onBlur,"bng-nav-item":``},[createBaseVNode(`div`,_hoisted_2$233,[createVNode(unref(bngImage_default),{class:normalizeClass([`item-image`,{"top-aligned":__props.tileImagesTopAligned}]),src:__props.tile.preview},null,8,[`class`,`src`]),isListItem.value?createCommentVNode(``,!0):(openBlock(),createElementBlock(Fragment,{key:0},[!__props.isConfig&&__props.tile.subElementCount>=1?(openBlock(),createElementBlock(`div`,_hoisted_3$207,toDisplayString(__props.tile.subElementCount),1)):createCommentVNode(``,!0),__props.isFavourite||__props.tile.showFavouriteIconPercent>=1?(openBlock(),createBlock(unref(bngIcon_default),{key:1,class:`favorite-indicator`,type:`star`})):createCommentVNode(``,!0)],64))]),createBaseVNode(`div`,_hoisted_4$177,[createBaseVNode(`span`,_hoisted_5$152,toDisplayString(__props.tile.name),1),createBaseVNode(`div`,_hoisted_6$131,[__props.tile.sourceIcons?(openBlock(!0),createElementBlock(Fragment,{key:0},renderList(__props.tile.sourceIcons,sourceIcon=>(openBlock(),createElementBlock(Fragment,{key:sourceIcon},[sourceIcon.icon?(openBlock(),createBlock(unref(bngIcon_default),{key:0,type:sourceIcon.icon,class:`source-icon`,color:`var(--bng-cool-gray-100)`},null,8,[`type`])):createCommentVNode(``,!0),sourceIcon.svg?(openBlock(),createElementBlock(`img`,{key:1,class:`svg-icon`,src:sourceIcon.svg,alt:``},null,8,_hoisted_7$117)):createCommentVNode(``,!0)],64))),128)):createCommentVNode(``,!0),isListItem.value&&__props.tile.showFavouriteIconPercent>0?(openBlock(),createBlock(unref(bngIcon_default),{key:1,class:`favorite-indicator`,type:__props.tile.showFavouriteIconPercent>=1?`star`:`starSecondary`},null,8,[`type`])):createCommentVNode(``,!0)]),isListItem.value&&!__props.isConfig&&__props.tile.subElementCount>=1?(openBlock(),createElementBlock(`span`,_hoisted_8$98,toDisplayString(__props.tile.subElementCount),1)):isListItem.value?(openBlock(),createElementBlock(`span`,_hoisted_9$88)):createCommentVNode(``,!0)])],42,_hoisted_1$284)),[[unref(BngOnUiNav_default),void 0,`ok`,{focusRequired:!0,asMouse:!0,bubble:!0}],[unref(BngSoundClass_default),`bng_click_hover_generic`],[unref(BngDoubleClick_default),__props.tile.doubleClickDetails?()=>emit$1(`dblclick`):null,__props.tile.doubleClickMode]])],6))}}),Tile_default=__plugin_vue_export_helper_default(_sfc_main$320,[[`__scopeId`,`data-v-51fd3377`]]),_hoisted_1$283={class:`group-header`,"bng-list-title":``},_sfc_main$319={__name:`GroupHeader`,props:{label:{type:String,required:!0}},setup(__props){return(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$283,[createVNode(bngCardHeading_default,{class:`header-label`},{default:withCtx(()=>[createTextVNode(toDisplayString(__props.label),1)]),_:1}),_cache[0]||=createBaseVNode(`div`,{class:`header-line`},null,-1)]))}},GroupHeader_default=__plugin_vue_export_helper_default(_sfc_main$319,[[`__scopeId`,`data-v-28596ef8`]]),_sfc_main$318={__name:`Grid`,props:{autoFocusKey:{type:String,default:null},activeItem:{type:Object,default:null},groups:{type:Array,required:!0},isConfig:{type:Boolean,default:!1},displaySize:{type:String,default:`medium`,validator:value=>[`tiny`,`small`,`medium`,`large`,`huge`,`list`].includes(value)},inDetails:{type:Boolean,default:!1},backendName:{type:String,default:`gridSelector`},tileImagesTopAligned:{type:Boolean,default:!1},doubleClickOverride:{type:Function,default:null}},emits:[`select-item`,`deselect-item`,`focus-item`],setup(__props,{emit:__emit}){let{showIfController}=storeToRefs(controls_default()),props=__props,emit$1=__emit,gridListRef=ref(),containerWidth=ref(0),baseFontSize=ref(16),tileSizeCalc=ctx=>Tile_default.getSizeCalc(props.displaySize)(ctx),maxTilesPerRow=computed(()=>{if(!containerWidth.value)return 1/0;let size$3=Tile_default.getSizeCalc(props.displaySize)({}),tileWidthPx=(size$3.width+size$3.margin)*baseFontSize.value;return(Math.floor(containerWidth.value/tileWidthPx)||1)*(props.displaySize===`list`?2:1)}),limitedGroups=computed(()=>props.groups.map(group=>({...group,tiles:group.isRecentGroup?group.tiles.slice(0,maxTilesPerRow.value):group.tiles}))),updateContainerWidth=()=>{gridListRef.value?.$el&&(containerWidth.value=gridListRef.value.$el.clientWidth,baseFontSize.value=parseFloat(getComputedStyle(document.documentElement).fontSize)||16)},resizeObserver;onMounted(()=>{updateContainerWidth(),gridListRef.value?.$el&&(resizeObserver=new ResizeObserver(debounce(updateContainerWidth,100)),resizeObserver.observe(gridListRef.value.$el))}),onUnmounted(()=>{resizeObserver&&resizeObserver.disconnect()}),provide(`gridSelectionState`,computed(()=>({inDetails:props.inDetails,activeItemKey:props.activeItem?.key||null,autoFocusKey:props.autoFocusKey})));let focusItem=tile=>{props.inDetails||(showIfController.value&&preselectItem(tile),emit$1(`focus-item`,tile))},selectItem=tile=>{preselectItem.cancel(),emit$1(`select-item`,tile)},preselectItem=debounce(tile=>emit$1(`select-item`,tile,!1),200),handleDoubleClick=async item=>{if(console.log(`handleDoubleClick`,item),item.doubleClickDetails)try{props.doubleClickOverride?props.doubleClickOverride(item):await Lua_default.ui_gridSelector.executeDoubleClick(props.backendName,item.doubleClickDetails)}catch(error){console.error(`Failed to execute double click:`,error)}};return(_ctx,_cache)=>(openBlock(),createBlock(unref(bngList_default),{ref_key:`gridListRef`,ref:gridListRef,class:`grid-list`,layout:unref(LIST_LAYOUTS).TILES,"no-background":``,big:``,immediate:``,"keep-alive":500,"title-width":20,"title-height":1.5,"title-margin":.5,"tile-size-calc":tileSizeCalc},{default:withCtx(()=>[(openBlock(!0),createElementBlock(Fragment,null,renderList(limitedGroups.value,group=>(openBlock(),createElementBlock(Fragment,{key:group.label},[group.label?(openBlock(),createBlock(GroupHeader_default,{key:0,label:group.label,"bng-list-title":``},null,8,[`label`])):createCommentVNode(``,!0),(openBlock(!0),createElementBlock(Fragment,null,renderList(group.tiles,tile=>(openBlock(),createBlock(Tile_default,{key:tile.key,tile,"is-config":__props.isConfig,"display-size":__props.displaySize,"is-favourite":group.label===`Favourites`,"tile-images-top-aligned":__props.tileImagesTopAligned,onFocus:$event=>focusItem(tile),onClick:$event=>selectItem(tile),onDblclick:$event=>handleDoubleClick(tile)},null,8,[`tile`,`is-config`,`display-size`,`is-favourite`,`tile-images-top-aligned`,`onFocus`,`onClick`,`onDblclick`]))),128))],64))),128))]),_:1},8,[`layout`]))}},Grid_default$1=__plugin_vue_export_helper_default(_sfc_main$318,[[`__scopeId`,`data-v-efa73a51`]]),_hoisted_1$282={class:`display-controls-container`},_hoisted_2$232={class:`control-group-label`},_hoisted_3$206={key:0,class:`reset-button-container`},_sfc_main$317={__name:`DisplayControls`,props:{displayData:{type:Array,required:!0},detailsMode:{type:String,required:!0},updateDisplayData:{type:Function,required:!0},resetDisplayDataToDefaults:{type:Function,required:!0},setDetailsMode:{type:Function,required:!0}},emits:[`focus-item`],setup(__props,{emit:__emit}){let props=__props,emit$1=__emit,booleanToStringByKey=computed(()=>{let valuesByKey={};for(let option of props.displayData)if(option.type===`checkbox`){valuesByKey[option.key]={};for(let checkboxOption of option.options)valuesByKey[option.key][checkboxOption.value]=checkboxOption.label||(checkboxOption.value?`Yes`:`No`)}return valuesByKey}),controls$1=computed(()=>props.displayData.filter(x=>x.showInModes?.[props.detailsMode]).map(x=>({...x,checkboxLabel:x.type===`checkbox`?booleanToStringByKey.value[x.key]?.[x.value]:void 0}))),onOptionChanged=(key,newValue)=>{props.updateDisplayData(key,newValue),emit$1(`focus-item`,key)},resetToDefaults=()=>{props.resetDisplayDataToDefaults()};return(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$282,[createBaseVNode(`div`,{class:normalizeClass([`display-controls`,{"display-controls-list":__props.detailsMode===`displayControls`||__props.detailsMode===`default`}])},[(openBlock(!0),createElementBlock(Fragment,null,renderList(controls$1.value,option=>(openBlock(),createElementBlock(`div`,{key:option.key,class:normalizeClass([`control-group`,{"force-full-width":__props.detailsMode===`default`}])},[createBaseVNode(`div`,_hoisted_2$232,toDisplayString(option.label),1),createVNode(bngTooltip_default,{text:option.description||`No description available`,position:`top`},{default:withCtx(()=>[option.type===`dropdown`?(openBlock(),createBlock(unref(bngSmartSelect_default),{key:0,modelValue:option.value,items:option.options||[],"onUpdate:modelValue":newValue=>onOptionChanged(option.key,newValue),threshold:8},null,8,[`modelValue`,`items`,`onUpdate:modelValue`])):option.type===`checkbox`?(openBlock(),createBlock(unref(bngSwitch_default),{key:1,class:normalizeClass([`full-width-checkbox`,{active:option.value}]),modelValue:option.value,"onUpdate:modelValue":newValue=>onOptionChanged(option.key,newValue),labelBefore:``,alwaysTransparent:``},{default:withCtx(()=>[createTextVNode(toDisplayString(option.checkboxLabel),1)]),_:2},1032,[`class`,`modelValue`,`onUpdate:modelValue`])):option.type===`number`?(openBlock(),createBlock(unref(bngInputNew_default),{key:2,modelValue:option.value,min:option.min,max:option.max,showExternalButton:!1,type:`number`,"onUpdate:modelValue":newValue=>onOptionChanged(option.key,newValue)},null,8,[`modelValue`,`min`,`max`,`onUpdate:modelValue`])):createCommentVNode(``,!0)]),_:2},1032,[`text`])],2))),128))],2),__props.detailsMode===`displayControls`?(openBlock(),createElementBlock(`div`,_hoisted_3$206,[createVNode(unref(bngButton_default),{onClick:resetToDefaults,accent:`attention`,iconLeft:`trashBin1`,class:`reset-button`},{default:withCtx(()=>[..._cache[0]||=[createTextVNode(` Reset to Defaults `,-1)]]),_:1})])):createCommentVNode(``,!0)]))}},DisplayControls_default=__plugin_vue_export_helper_default(_sfc_main$317,[[`__scopeId`,`data-v-863e411a`]]),_sfc_main$316={__name:`SearchBar`,props:{searchText:{type:String,required:!0},setSearchText:{type:Function,required:!0},placeholder:{type:String,default:`Search...`},fullWidth:{type:Boolean,default:!1},showClearAllButton:{type:Boolean,default:!1}},emits:[`focus-item`,`clear-all`],setup(__props,{emit:__emit}){let props=__props,emit$1=__emit,clearSearch=()=>{props.setSearchText(``),emit$1(`focus-item`,`search`)},commitSearch=()=>{},onSearchChanged=value=>{props.setSearchText(value),emit$1(`focus-item`,`search`)};return(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,{class:normalizeClass([`search-container`,{"full-width":__props.fullWidth}])},[createVNode(unref(bngInput_default),{class:`search-input`,modelValue:__props.searchText,placeholder:__props.placeholder,onValueChanged:onSearchChanged,onKeydown:withKeys(commitSearch,[`enter`]),onBlur:commitSearch,onFocus:_cache[0]||=$event=>emit$1(`focus-item`,`search`)},null,8,[`modelValue`,`placeholder`]),createBaseVNode(`div`,{class:normalizeClass([`search-icon-container`,{active:__props.searchText}]),onClick:clearSearch},[createVNode(unref(bngIcon_default),{type:unref(icons).search,class:`search-icon show-unhovered`},null,8,[`type`]),createVNode(unref(bngIcon_default),{type:unref(icons).trashBin2,class:`search-icon show-hovered`},null,8,[`type`])],2)],2))}},SearchBar_default=__plugin_vue_export_helper_default(_sfc_main$316,[[`__scopeId`,`data-v-67aff9c0`]]),_hoisted_1$281={class:`filters`},_hoisted_2$231={key:0,class:`search-section`},_hoisted_3$205={key:1,class:`filter-options-grid`},_hoisted_4$176={class:`option-label`},_hoisted_5$151={class:`option-icon`},_hoisted_6$130={key:2,class:`filters-container`},_hoisted_7$116={class:`filter-container`,navigable:``,tabindex:`0`},_hoisted_8$97={class:`filter-content`},_hoisted_9$87={key:0,class:`filter-options`},_hoisted_10$76={class:`filter-options-grid`},_hoisted_11$68={class:`option-label`},_hoisted_12$56={class:`option-icon`},_hoisted_13$48={key:1,class:`filter-options`},_hoisted_14$43={class:`range-bar-container`},_hoisted_15$41={class:`range-bar`},_hoisted_16$39={class:`range-inputs`},_hoisted_17$32={class:`range-input-group`},_hoisted_18$29={class:`range-input-group`},_sfc_main$315={__name:`DetailedFilters`,props:{filterList:{type:Array,required:!0},filterByProp:{type:Object,required:!0},searchText:{type:String,default:``},commonFilters:{type:Array,default:()=>[]},detailsMode:{type:String,required:!0},onlyCommonFilters:{type:Boolean,default:!0},isFilterLocked:{type:Function,required:!0},isFilterOptionLocked:{type:Function,required:!0},isRangeFilterLocked:{type:Function,required:!0},toggleFilter:{type:Function,required:!0},updateRangeFilter:{type:Function,required:!0},resetRangeFilter:{type:Function,required:!0},setSearchText:{type:Function,required:!0},setDetailsMode:{type:Function,required:!0}},emits:[`focus-item`],setup(__props,{emit:__emit}){let props=__props,emit$1=__emit,expandedAccordions=ref({}),pendingRangeUpdates=ref({}),debouncedUpdateFunctions=ref({}),getDebouncedUpdate=propName=>(debouncedUpdateFunctions.value[propName]||(debouncedUpdateFunctions.value[propName]=debounce(()=>{if(pendingRangeUpdates.value[propName]){let{min:min$1,max:max$1}=pendingRangeUpdates.value[propName];props.updateRangeFilter(propName,min$1,max$1),delete pendingRangeUpdates.value[propName]}},300)),debouncedUpdateFunctions.value[propName]);onUnmounted(()=>{Object.values(debouncedUpdateFunctions.value).forEach(debouncedFn=>{debouncedFn&&debouncedFn.cancel&&debouncedFn.cancel()}),debouncedUpdateFunctions.value={},pendingRangeUpdates.value={}});let formatFilterName=key=>key,getFilterOptionClass=(propName,option)=>{let filter=props.filterList.find(f=>f.propName===propName);if(!filter||!filter.options)return``;let allEnabled=filter.options.every(opt=>props.filterByProp[propName]?.[opt]===!0),currentOptionEnabled=props.filterByProp[propName]?.[option]===!0;return allEnabled?`filter-neutral`:currentOptionEnabled?`filter-active`:`filter-inactive`},hasActiveFilters=propName=>{if(!props.filterList)return!1;let filter=props.filterList.find(f=>f.propName===propName);if(!filter)return!1;if(filter.type===`range`){let filterData=props.filterByProp[propName];if(!filterData)return!1;let currentMin=filterData.min,currentMax=filterData.max,defaultMin=filter.min,defaultMax=filter.max;return currentMin>defaultMin||currentMaxprops.filterByProp[propName]?.[option]===!1)},toggleFilter=(propName,option,event)=>{if(props.isFilterOptionLocked(propName,option)){console.log(`Cannot toggle locked filter:`,propName,option);return}event&&(event.preventDefault(),event.stopPropagation()),emit$1(`focus-item`,`filters`),props.toggleFilter(propName,option)},onRangeFilterChanged=(propName,newValue,field)=>{if(props.isRangeFilterLocked(propName)){console.log(`Cannot update locked range filter:`,propName);return}let filter=props.filterList.find(f=>f.propName===propName);if(!filter||filter.type!==`range`)return;let filterData=props.filterByProp[propName];if(!filterData)return;let currentPending=pendingRangeUpdates.value[propName],min$1=currentPending?currentPending.min:filterData.min,max$1=currentPending?currentPending.max:filterData.max;field===`min`?min$1=newValue:field===`max`&&(max$1=newValue),min$1=Math.max(filter.min,Math.min(filter.max,min$1)),max$1=Math.max(filter.min,Math.min(filter.max,max$1)),min$1>max$1&&([min$1,max$1]=[max$1,min$1]),pendingRangeUpdates.value[propName]={min:min$1,max:max$1},getDebouncedUpdate(propName)(),emit$1(`focus-item`,propName)},isFilterActive=filter=>hasActiveFilters(filter.propName),getRangeBarStyle=propName=>{let filter=props.filterList.find(f=>f.propName===propName);if(!filter||filter.type!==`range`)return{};let filterData=props.filterByProp[propName];if(!filterData)return{};let currentMin=filterData.min,currentMax=filterData.max,totalRange=filter.max-filter.min,leftPosition=(currentMin-filter.min)/totalRange*100,width$1=(currentMax-currentMin)/totalRange*100;return{left:`${leftPosition}%`,width:`${width$1}%`,backgroundColor:`var(--bng-orange-500)`}};return onMounted(()=>{props.filterList&&props.filterList.forEach(filter=>{hasActiveFilters(filter.propName)&&(expandedAccordions.value[filter.propName]=!0)})}),(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$281,[__props.detailsMode===`filter`?(openBlock(),createElementBlock(`div`,_hoisted_2$231,[createVNode(SearchBar_default,{searchText:__props.searchText,setSearchText:__props.setSearchText,placeholder:`Search items...`,"full-width":!0,onFocusItem:_cache[0]||=$event=>emit$1(`focus-item`,$event)},null,8,[`searchText`,`setSearchText`])])):createCommentVNode(``,!0),__props.detailsMode===`filter`?createCommentVNode(``,!0):(openBlock(),createElementBlock(`div`,_hoisted_3$205,[(openBlock(!0),createElementBlock(Fragment,null,renderList(__props.commonFilters,(filter,index)=>(openBlock(),createBlock(unref(bngPill_default),{key:index,class:normalizeClass([[getFilterOptionClass(filter[0],filter[1]),{"filter-locked":props.isFilterOptionLocked(filter[0],filter[1])}],`filter-option-chip`]),style:normalizeStyle({cursor:props.isFilterOptionLocked(filter[0],filter[1])?`not-allowed`:`pointer`}),"bng-nav-item":``,onClick:$event=>toggleFilter(filter[0],filter[1])},{default:withCtx(()=>[createBaseVNode(`span`,_hoisted_4$176,toDisplayString(filter[1]),1),createBaseVNode(`span`,_hoisted_5$151,[__props.filterByProp&&__props.filterByProp[filter[0]]&&__props.filterByProp[filter[0]][filter[1]]?(openBlock(),createBlock(unref(bngIcon_default),{key:0,type:unref(icons).checkmark},null,8,[`type`])):(openBlock(),createBlock(unref(bngIcon_default),{key:1,type:unref(icons).xmark},null,8,[`type`])),props.isFilterOptionLocked(filter[0],filter[1])?(openBlock(),createBlock(unref(bngIcon_default),{key:2,type:unref(icons).lockClosed,class:`lock-icon`},null,8,[`type`])):createCommentVNode(``,!0)])]),_:2},1032,[`class`,`style`,`onClick`]))),128))])),__props.detailsMode===`filter`?(openBlock(),createElementBlock(`div`,_hoisted_6$130,[createVNode(unref(accordion_default),{class:`filters-accordion`},{default:withCtx(()=>[(openBlock(!0),createElementBlock(Fragment,null,renderList(__props.filterList,filter=>(openBlock(),createElementBlock(`div`,{key:filter.propName,class:`filter-wrapper`},[createVNode(unref(accordionItem_default),{navigable:``,static:!filter.options||filter.options.length===0,"arrow-big":``,"expand-hint-inline":``,expanded:expandedAccordions.value[filter.propName],class:normalizeClass({"has-active-filters":isFilterActive(filter)}),onFocus:$event=>emit$1(`focus-item`,filter.propName)},{caption:withCtx(()=>[createBaseVNode(`div`,_hoisted_7$116,[createBaseVNode(`div`,_hoisted_8$97,toDisplayString(formatFilterName(filter.propName)),1)])]),default:withCtx(()=>[filter.type===`set`&&filter.options?(openBlock(),createElementBlock(`div`,_hoisted_9$87,[createBaseVNode(`div`,_hoisted_10$76,[(openBlock(!0),createElementBlock(Fragment,null,renderList(filter.options,(option,index)=>(openBlock(),createBlock(unref(bngPill_default),{key:index,class:normalizeClass([[getFilterOptionClass(filter.propName,option),{"filter-locked":props.isFilterOptionLocked(filter.propName,option)}],`filter-option-chip`]),style:normalizeStyle({cursor:props.isFilterOptionLocked(filter.propName,option)?`not-allowed`:`pointer`}),onClick:$event=>toggleFilter(filter.propName,option)},{default:withCtx(()=>[createBaseVNode(`span`,_hoisted_11$68,toDisplayString(option),1),createBaseVNode(`span`,_hoisted_12$56,[__props.filterByProp[filter.propName][option]?(openBlock(),createBlock(unref(bngIcon_default),{key:0,type:unref(icons).checkmark},null,8,[`type`])):(openBlock(),createBlock(unref(bngIcon_default),{key:1,type:unref(icons).abandon},null,8,[`type`])),props.isFilterOptionLocked(filter.propName,option)?(openBlock(),createBlock(unref(bngIcon_default),{key:2,type:unref(icons).lockClosed,class:`lock-icon`},null,8,[`type`])):createCommentVNode(``,!0)])]),_:2},1032,[`class`,`style`,`onClick`]))),128))])])):createCommentVNode(``,!0),filter.type===`range`?(openBlock(),createElementBlock(`div`,_hoisted_13$48,[createBaseVNode(`div`,_hoisted_14$43,[createBaseVNode(`div`,_hoisted_15$41,[createBaseVNode(`div`,{class:`range-selection`,style:normalizeStyle(getRangeBarStyle(filter.propName))},null,4)])]),createBaseVNode(`div`,_hoisted_16$39,[createBaseVNode(`div`,_hoisted_17$32,[_cache[1]||=createBaseVNode(`label`,{class:`range-label`},`Min:`,-1),(openBlock(),createBlock(unref(bngInput_default),{key:filter.propName+`min`,modelValue:__props.filterByProp[filter.propName].min,type:`number`,min:filter.min,max:filter.max,step:filter.step||1,disabled:props.isRangeFilterLocked(filter.propName),onValueChanged:val=>onRangeFilterChanged(filter.propName,val,`min`)},null,8,[`modelValue`,`min`,`max`,`step`,`disabled`,`onValueChanged`]))]),createBaseVNode(`div`,_hoisted_18$29,[_cache[2]||=createBaseVNode(`label`,{class:`range-label`},`Max:`,-1),(openBlock(),createBlock(unref(bngInput_default),{key:filter.propName+`max`,modelValue:__props.filterByProp[filter.propName].max,type:`number`,min:filter.min,max:filter.max,step:filter.step||1,disabled:props.isRangeFilterLocked(filter.propName),onValueChanged:val=>onRangeFilterChanged(filter.propName,val,`max`)},null,8,[`modelValue`,`min`,`max`,`step`,`disabled`,`onValueChanged`]))])])])):createCommentVNode(``,!0)]),_:2},1032,[`static`,`expanded`,`class`,`onFocus`])]))),128))]),_:1})])):createCommentVNode(``,!0)]))}},DetailedFilters_default=__plugin_vue_export_helper_default(_sfc_main$315,[[`__scopeId`,`data-v-a4758924`]]),_hoisted_1$280={key:1},_hoisted_2$230={key:1},_hoisted_3$204={key:1},_hoisted_4$175={key:1},_sfc_main$314={__name:`HeaderButtons`,props:{canSwitchDetails:{type:Boolean,default:!1},hiddenTabs:{type:Array,default:()=>[]},detailsMode:{type:String,required:!0},slim:{type:Boolean,default:!1}},emits:[`switch-details-mode`],setup(__props){return(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,{class:normalizeClass([`header-buttons`,{slim:__props.slim}])},[withDirectives(createVNode(unref(bngBinding_default),{class:`header-buttons-binding`,"ui-event":`context`,controller:``,"track-ignore":``},null,512),[[vShow,__props.canSwitchDetails]]),__props.hiddenTabs.includes(`detail`)?createCommentVNode(``,!0):withDirectives((openBlock(),createBlock(unref(bngButton_default),{key:0,class:normalizeClass([`header-button`,{selected:__props.detailsMode===`detail`}]),accent:unref(ACCENTS).text,onClick:_cache[0]||=$event=>_ctx.$emit(`switch-details-mode`,`detail`)},{default:withCtx(()=>[__props.slim?(openBlock(),createBlock(unref(bngIcon_default),{key:0,type:unref(icons).info},null,8,[`type`])):(openBlock(),createElementBlock(`span`,_hoisted_1$280,`Details`))]),_:1},8,[`class`,`accent`])),[[unref(BngTooltip_default),`Details`,`top`]]),__props.hiddenTabs.includes(`advanced`)?createCommentVNode(``,!0):withDirectives((openBlock(),createBlock(unref(bngButton_default),{key:1,class:normalizeClass([`header-button`,{selected:__props.detailsMode===`advanced`}]),accent:unref(ACCENTS).text,onClick:_cache[1]||=$event=>_ctx.$emit(`switch-details-mode`,`advanced`)},{default:withCtx(()=>[__props.slim?(openBlock(),createBlock(unref(bngIcon_default),{key:0,type:unref(icons).laneProperties},null,8,[`type`])):(openBlock(),createElementBlock(`span`,_hoisted_2$230,`Advanced`))]),_:1},8,[`class`,`accent`])),[[unref(BngTooltip_default),`Advanced`,`top`]]),__props.hiddenTabs.includes(`filter`)?createCommentVNode(``,!0):withDirectives((openBlock(),createBlock(unref(bngButton_default),{key:2,class:normalizeClass([`header-button`,{selected:__props.detailsMode===`filter`}]),accent:unref(ACCENTS).text,onClick:_cache[2]||=$event=>_ctx.$emit(`switch-details-mode`,`filter`)},{default:withCtx(()=>[__props.slim?(openBlock(),createBlock(unref(bngIcon_default),{key:0,type:unref(icons).filter},null,8,[`type`])):(openBlock(),createElementBlock(`span`,_hoisted_3$204,`Filters`))]),_:1},8,[`class`,`accent`])),[[unref(BngTooltip_default),`Filters`,`top`]]),__props.hiddenTabs.includes(`displayControls`)?createCommentVNode(``,!0):withDirectives((openBlock(),createBlock(unref(bngButton_default),{key:3,class:normalizeClass([`header-button`,{selected:__props.detailsMode===`displayControls`}]),accent:unref(ACCENTS).text,onClick:_cache[3]||=$event=>_ctx.$emit(`switch-details-mode`,`displayControls`)},{default:withCtx(()=>[__props.slim?(openBlock(),createBlock(unref(bngIcon_default),{key:0,type:unref(icons).adjust},null,8,[`type`])):(openBlock(),createElementBlock(`span`,_hoisted_4$175,`Display`))]),_:1},8,[`class`,`accent`])),[[unref(BngTooltip_default),`Display`,`top`]])],2))}},HeaderButtons_default=__plugin_vue_export_helper_default(_sfc_main$314,[[`__scopeId`,`data-v-157cdc63`]]),_sfc_main$313={__name:`Slideshow`,props:{images:Array,transition:Boolean,delay:{type:Number,default:1e4},parent:Object,shuffle:Boolean},setup(__props,{expose:__expose}){useCssVars(_ctx=>({v095d52f4:imgPrev.value,v095f8174:imgNext.value}));let props=__props,anim=ref(!1),imgPrev=ref(``),imgNext=ref(``),imgIndex=ref(-1),sequence=[],sequenceIndex=-1,tmrMain,tmrAnim,wImages,wParent;__expose({imgIndex,nextImage,carousel:{showNext:nextImage}}),onUnmounted(stopTimers);function stopTimers(){tmrMain&&=(clearTimeout(tmrMain),null),tmrAnim&&=(clearTimeout(tmrAnim),null)}watch(()=>props.parent,parent=>{wImages&&=(wImages(),null),wParent&&=(wParent(),null),parent?wParent=watch([()=>props.images,()=>parent.imgIndex],([images,index])=>{images&&(imgIndex.value=index,images.length>0&&nextTick(nextImage))},{immediate:!0}):wImages=watch([()=>props.images,()=>props.shuffle],([images,shuffle])=>{images&&(imgIndex.value=-1,images.length>0&&(shuffle&&(sequenceIndex=-1,sequence=Array.from(images).map((_,i)=>i).sort(()=>Math.random()-.5)),nextTick(nextImage)))},{immediate:!0})},{immediate:!0});function nextImage(){stopTimers(),props.parent||(props.shuffle&&sequence.length>0?(sequenceIndex=++sequenceIndex%props.images.length,imgIndex.value=sequence[sequenceIndex]):imgIndex.value=++imgIndex.value%props.images.length);let img=`url("${getAssetURL(props.images[imgIndex.value])}")`;props.transition?(imgNext.value=img,anim.value=!0,tmrAnim=setTimeout(()=>{tmrAnim=null,anim.value=!1,imgPrev.value=imgNext.value,imgNext.value=``},1e3)):imgPrev.value=img,!props.parent&&props.images.length>1&&(tmrMain=setTimeout(nextImage,props.delay))}return(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,{class:normalizeClass({anim:anim.value})},null,2))}},Slideshow_default=__plugin_vue_export_helper_default(_sfc_main$313,[[`__scopeId`,`data-v-f788946d`]]),_hoisted_1$279={key:0,class:`blur-wrap`},_sfc_main$312={__name:`BlurBackground`,setup(__props){let parentCarousel=inject(`mainBackground`),backgroundsBlur=inject(`mainBackgroundBlur`),bgRequired=sysInfo_default.mainMenuBackgroundRequired;return(_ctx,_cache)=>unref(bgRequired)?(openBlock(),createElementBlock(`div`,_hoisted_1$279,[createVNode(Slideshow_default,{class:`blur-carousel`,images:unref(backgroundsBlur),parent:unref(parentCarousel),transition:``},null,8,[`images`,`parent`])])):createCommentVNode(``,!0)}},BlurBackground_default=__plugin_vue_export_helper_default(_sfc_main$312,[[`__scopeId`,`data-v-cc1c4815`]]),_hoisted_1$278={class:`header-container`},_hoisted_2$229={key:1},_hoisted_3$203={class:`content-container`},_hoisted_4$174={class:`header-back-button`},_hoisted_5$150={key:0,class:`header-title-container`},_hoisted_6$129={class:`header-back-button`},_hoisted_7$115={class:`header-back-button`},_hoisted_8$96={key:0,class:`scrollable-content`},_hoisted_9$86={class:`details-mode-buttons`},_hoisted_10$75={key:1,class:`scrollable-content`},_hoisted_11$67={key:0,class:`details-content`},_hoisted_12$55={key:1,class:`scrollable-content`},_sfc_main$311={__name:`GridSelector`,props:{backendName:{type:String,default:`gridSelector`},routePath:{type:String,default:`/grid-selector`},defaultPath:{type:Object,default:()=>({keys:[`allModels`]})},defaultDetailsMode:{type:String,default:`detail`},hiddenTabs:{type:Array,default:()=>[]},tileImagesTopAligned:{type:Boolean,default:!1},doubleClickOverride:{type:Function,default:null},noBreadcrumbs:{type:Boolean,default:!1},overrideBackFromGrid:{type:Function,default:null},inlineHeaderContainer:{type:Boolean,default:!0},selectCallback:{type:Function,default:null},bubbleEvents:{type:Array,default:()=>[]}},setup(__props,{expose:__expose}){let props=__props,{showIfController}=storeToRefs(controls_default()),store$1=useGridSelector(props.backendName,props.defaultPath,props.defaultDetailsMode),{groups,displayData,detailsMode,selectedItem,showScreenHeader,screenHeaderTitle,screenHeaderPath,activeItemDetails,activeItem,activeFilters}=store$1,route=useRoute(),router$1=useRouter(),detailsModeTitles={detail:`Details`,advanced:`Advanced`,filter:`Filters`,displayControls:`Display`},detailsModeBackTo={filter:`advanced`,displayControls:`advanced`};watch(()=>[props.backendName,props.defaultPath,props.defaultDetailsMode],([newBackendName,newDefaultPath,newDefaultDetailsMode],[oldBackendName,oldDefaultPath,oldDefaultDetailsMode])=>{newBackendName!==oldBackendName&&newDefaultPath&&newDefaultPath.keys&&store$1.setCurrentPath(newDefaultPath),newDefaultDetailsMode!==oldDefaultDetailsMode&&store$1.setDetailsMode(newDefaultDetailsMode)},{deep:!0});let scopedNavState=reactive({isGridActive:!1,isDetailsActive:!1}),setBack=inject(`setBack`),showTopbarTabBindings=inject(`showTopbarTabBindings`),showTopbarBackBinding=inject(`showTopbarBackBinding`),showBreadcrumbsBack=ref(!1),canUseTopbar=ref(!0);watch(()=>scopedNavState.isDetailsActive,val=>{canUseTopbar.value=!val,showTopbarTabBindings(canUseTopbar.value)}),watch(screenHeaderPath,val=>{showBreadcrumbsBack.value=val&&val.length>2,showTopbarBackBinding(!showBreadcrumbsBack.value)});let switchSeq=computed(()=>[`detail`,`advanced`,`displayControls`].filter(tab=>!props.hiddenTabs.includes(tab))),getNextSwitchSeq=mode=>{mode||=detailsMode.value,mode===`filter`&&(mode=`advanced`);let seq=switchSeq.value;if(seq.length===0)return`detail`;let currentIndex=seq.indexOf(mode);return currentIndex===-1?seq[0]:seq[(currentIndex+1)%seq.length]},canSeeDetails=ref(!0),hasSelectedItem=computed(()=>!!store$1.selectedItem.value),canSwitchDetails=computed(()=>activeSectionScope.value!==`default`||detailsMode.value===`advanced`);function switchDetailsMode(mode){console.log(`switchDetailsMode`,mode),typeof mode!=`string`&&(mode=getNextSwitchSeq(mode)),mode===`detail`&&!canSeeDetails.value&&(mode=getNextSwitchSeq(mode)),console.log(`switchDetailsMode`,mode),store$1.setDetailsMode(mode),switchScope(`details`)}function onToggleSectionScope(){activeSectionScope.value===`grid`?switchScope(`details`):switchDetailsMode()}let activeSectionScope=ref(`grid`);function switchScope(name,force=!1){name||=activeSectionScope.value===`grid`?`details`:`grid`,name===`details`?(scopedNavState.isGridActive=!1,force&&(scopedNavState.isDetailsActive=!1),nextTick(()=>{activeSectionScope.value=name,scopedNavState.isDetailsActive=!0})):(scopedNavState.isDetailsActive=!1,force&&(scopedNavState.isGridActive=!1),nextTick(()=>{activeSectionScope.value=name,scopedNavState.isGridActive=!0}))}let onGridActivate=()=>{scopedNavState.isGridActive=!0},onGridDeactivate=event=>{scopedNavState.isGridActive=!1},onDetailsActivate=()=>{scopedNavState.isDetailsActive=!0},onDetailsDeactivate=event=>{scopedNavState.isDetailsActive=!1},setDetailsScope=info=>{switchScope(`details`)},canBubbleGridEvent=event=>!!(event.detail.name===`rotate_v_cam`||event.detail.name===`menu`||canUseTopbar.value&&(event.detail.name===`tab_l`||event.detail.name===`tab_r`)||props.bubbleEvents.includes(event.detail.name)),canBubbleDetailsEvent=event=>!!(event.detail.name===`rotate_v_cam`||props.bubbleEvents.includes(event.detail.name)),canDeactivateGrid=()=>screenHeaderPath.value.length<=1,onBackFromDetails=()=>{if(detailsMode.value===`displayControls`||detailsMode.value===`filter`){toggleDetailsMode(`advanced`);return}switchScope(`grid`)},onToggleFavorite=()=>{store$1.toggleFavourite(activeItem.value)},gridContentRef=ref(null),scrollPositions$1=ref(new Map),scrollTimeout=null,displaySize=computed(()=>{let option=displayData.value.find(option$1=>option$1.key===`displaySize`);return option?option.value:`medium`});store$1.initialize(),store$1.setOnBackFromDetailsCallback(()=>{onBackFromDetails()}),props.defaultPath.keys;let currentPathSegments=computed(()=>{let pathMatch=route.params.pathMatch;if(!pathMatch)return props.defaultPath?.keys||(Array.isArray(props.defaultPath)?props.defaultPath:[]);let segments=Array.isArray(pathMatch)?pathMatch.map(segment=>decodeURIComponent(segment)):[decodeURIComponent(pathMatch)];if(route.params.itemDetails){let itemDetails=Array.isArray(route.params.itemDetails)?route.params.itemDetails.map(segment=>decodeURIComponent(segment)):[decodeURIComponent(route.params.itemDetails)];segments.push(...itemDetails)}return segments}),saveScrollPosition$1=()=>{if(!gridContentRef.value)return;let pathKey=currentPathSegments.value.join(`/`),scrollTop=gridContentRef.value.scrollTop;scrollPositions$1.value.set(pathKey,scrollTop)},debouncedSaveScrollPosition=()=>{scrollTimeout&&clearTimeout(scrollTimeout),scrollTimeout=setTimeout(()=>{saveScrollPosition$1()},100)},restoreScrollPosition=()=>{if(!gridContentRef.value)return;let pathKey=currentPathSegments.value.join(`/`),savedPosition=scrollPositions$1.value.get(pathKey);savedPosition!==void 0&&nextTick(()=>{gridContentRef.value.scrollTop=savedPosition})};watch(groups,async newGroups=>{newGroups&&(await nextTick(),await nextTick(),store$1.notifyUIReady(),restoreScrollPosition())},{immediate:!0}),watch([currentPathSegments],async([segments],[oldSegments])=>{if(oldSegments&&gridContentRef.value){let oldPathKey=oldSegments.join(`/`),currentScrollTop=gridContentRef.value.scrollTop;scrollPositions$1.value.set(oldPathKey,currentScrollTop)}let path={keys:segments};await store$1.setCurrentPath(path)},{immediate:!0}),watch(gridContentRef,newElement=>{if(newElement){let handleScroll=()=>{debouncedSaveScrollPosition()};newElement.addEventListener(`scroll`,handleScroll),newElement._scrollHandler=handleScroll}},{immediate:!0}),onBeforeMount(()=>{Lua_default.simTimeAuthority.pushPauseRequest(`gridSelector`)}),onMounted(()=>{setBack(props.backendName,onBackFromGrid),nextTick(()=>{scopedNavState.isGridActive=!0})}),onUnmounted(()=>{setBack(props.backendName),gridContentRef.value&&gridContentRef.value._scrollHandler&&gridContentRef.value.removeEventListener(`scroll`,gridContentRef.value._scrollHandler),scrollTimeout&&clearTimeout(scrollTimeout),Lua_default.ui_gridSelector.closedFromUI(props.backendName),Lua_default.simTimeAuthority.popPauseRequest(`gridSelector`)});let onItemFocus=item=>{item&&item.showDetails&&store$1.setPreviewItem(item)},onItemSelect=async(item,doNavigation=!0)=>{if(item.gotoPath&&Array.isArray(item.gotoPath))store$1.prevSelectedItem.value=item.key,doNavigation&&routeNav(item),store$1.clearSelectedItem(),doNavigation&&switchScope(`grid`),props.selectCallback&&await props.selectCallback(item,doNavigation);else if(item.showDetails){item.key,selectedItem.value?.key;let consumed=!1;props.selectCallback&&(consumed=await props.selectCallback(item,doNavigation)),consumed||(await store$1.setSelectedItem(item),doNavigation&&switchScope(`details`))}},onGridWrapperClick=event=>{store$1.clearSelectedItem(),switchScope(`grid`,!0)},onDetailsWrapperClick=event=>{switchScope(`details`,!0)},onItemDeselect=()=>{store$1.clearSelectedItem()},toggleDetailsMode=mode=>{store$1.setDetailsMode(mode)};function routeNav(item){if(item.gotoAngularState)return;let encodedPath=item.gotoPath.map(segment=>encodeURIComponent(segment)).join(`/`);router$1.push(`${props.routePath}/${encodedPath}`)}let onBackFromGrid=()=>{if(console.log(`onBackFromGrid`,screenHeaderPath.value),props.overrideBackFromGrid&&screenHeaderPath.value.length<=2)return props.overrideBackFromGrid();if(screenHeaderPath.value.length>1){let item=screenHeaderPath.value[screenHeaderPath.value.length-2];return store$1.prevSelectedItem.value&&(store$1.autoFocusKey.value=store$1.prevSelectedItem.value),gotoHeaderItem(item),!1}return!0},onBreadBack=()=>nextTick(onBackFromGrid),clearSearch=()=>{store$1.setSearchText(``)},clearFilters=()=>{console.log(`clearFilters`,activeFilters.value);for(let filter of activeFilters.value)console.log(`clearFilter`,filter),filter&&filter.type===`range`?store$1.resetRangeFilter(filter.propName):store$1.resetSetFilter(filter.propName)},setCurrentPath=path=>{store$1.setCurrentPath(path)},gotoHeaderItem=item=>{console.log(`gotoHeaderItem`,item),item.gotoAngularState?window.bngVue.gotoAngularState(item.gotoAngularState):item.gotoPath&&(item.clearSearch&&clearSearch(),item.clearFilters&&clearFilters(),setCurrentPath({keys:item.gotoPath}),routeNav(item),switchScope(`grid`))};return __expose({screenHeaderPath,clearSearch,clearFilters,setCurrentPath}),(_ctx,_cache)=>withDirectives((openBlock(),createBlock(unref(layoutSingle_default),{class:`grid-selector`},{default:withCtx(()=>[createBaseVNode(`div`,_hoisted_1$278,[__props.noBreadcrumbs?(openBlock(),createElementBlock(`div`,_hoisted_2$229)):(openBlock(),createBlock(unref(bngBreadcrumbs_default),{key:0,class:`header-breadcrumbs`,items:unref(screenHeaderPath),limit:`5`,simple:``,"disable-last-item":``,"show-back-button":showBreadcrumbsBack.value,onClick:gotoHeaderItem,onBack:onBreadBack},null,8,[`items`,`show-back-button`])),__props.inlineHeaderContainer?createCommentVNode(``,!0):(openBlock(),createBlock(HeaderButtons_default,{key:2,"can-switch-details":canSwitchDetails.value,"hidden-tabs":props.hiddenTabs,"details-mode":unref(detailsMode),onSwitchDetailsMode:switchDetailsMode},null,8,[`can-switch-details`,`hidden-tabs`,`details-mode`]))]),createBaseVNode(`div`,_hoisted_3$203,[createBaseVNode(`div`,{class:normalizeClass([`grid-wrapper`,{active:activeSectionScope.value===`grid`}])},[createVNode(BlurBackground_default),unref(showScreenHeader)?(openBlock(),createElementBlock(`div`,{key:0,class:normalizeClass([`header-row`,{active:activeSectionScope.value===`grid`&&unref(showIfController),"no-controller":!unref(showIfController)}])},[createVNode(unref(bngScreenHeadingV2_default),{type:`2`,class:`header-title-v2`},{default:withCtx(()=>[createTextVNode(toDisplayString(unref(screenHeaderTitle)),1)]),_:1}),withDirectives(createBaseVNode(`div`,_hoisted_4$174,[createVNode(unref(bngBinding_default),{"ui-event":`back`,controller:``}),createVNode(unref(bngIcon_default),{type:unref(icons).undo},null,8,[`type`])],512),[[vShow,activeSectionScope.value===`grid`&&unref(showIfController)&¤tPathSegments.value.length>1]])],2)):createCommentVNode(``,!0),withDirectives((openBlock(),createElementBlock(`div`,{class:`grid-content`,ref_key:`gridContentRef`,ref:gridContentRef,"bng-nav-scroll":``,"bng-no-nav":`true`,tabindex:`-1`,onActivate:onGridActivate,onDeactivate:onGridDeactivate,onClick:onGridWrapperClick},[createVNode(Grid_default$1,{"in-details":activeSectionScope.value===`details`&&unref(detailsMode)===`detail`,"display-size":displaySize.value,"backend-name":props.backendName,"auto-focus-key":unref(store$1).autoFocusKey.value,"active-item":unref(store$1).activeItem.value,groups:unref(groups),"tile-images-top-aligned":__props.tileImagesTopAligned,onFocusItem:onItemFocus,onSelectItem:onItemSelect,onDeselectItem:onItemDeselect,"double-click-override":__props.doubleClickOverride},null,8,[`in-details`,`display-size`,`backend-name`,`auto-focus-key`,`active-item`,`groups`,`tile-images-top-aligned`,`double-click-override`])],32)),[[unref(BngScopedNav_default),{activated:scopedNavState.isGridActive,canBubbleEvent:canBubbleGridEvent,canDeactivate:canDeactivateGrid,preferAutoFocus:!0,autoFocusDelay:400}],[unref(BngOnUiNav_default),onToggleSectionScope,`context`],[unref(BngUiNavLabel_default),`Filters and more`,`context`],[unref(BngOnUiNav_default),onBackFromGrid,`back`],[unref(BngUiNavScroll_default)]])],2),withDirectives((openBlock(),createElementBlock(`div`,{class:normalizeClass([`details-wrapper wide`,{active:activeSectionScope.value===`details`,"no-controller":!unref(showIfController)}]),tabindex:`-1`,"bng-no-nav":`true`,onActivate:onDetailsActivate,onDeactivate:onDetailsDeactivate,onClick:onDetailsWrapperClick},[createVNode(BlurBackground_default),createBaseVNode(`div`,{class:normalizeClass([`header-row`,{active:activeSectionScope.value===`details`&&unref(showIfController),"no-controller":!unref(showIfController)}]),"bng-no-child-nav":`true`},[createVNode(HeaderButtons_default,{slim:``,"can-switch-details":canSwitchDetails.value,"hidden-tabs":props.hiddenTabs,"details-mode":unref(detailsMode),onSwitchDetailsMode:switchDetailsMode},null,8,[`can-switch-details`,`hidden-tabs`,`details-mode`]),__props.inlineHeaderContainer?createCommentVNode(``,!0):(openBlock(),createElementBlock(`div`,_hoisted_5$150,[createVNode(unref(bngCardHeading_default),{type:`ribbon`,class:`header-title`},{default:withCtx(()=>[createTextVNode(toDisplayString(detailsModeTitles[unref(detailsMode)]),1)]),_:1}),detailsModeBackTo[unref(detailsMode)]?(openBlock(),createBlock(unref(bngButton_default),{key:0,"bng-no-nav":`true`,onClick:_cache[0]||=$event=>toggleDetailsMode(detailsModeBackTo[unref(detailsMode)]),accent:unref(ACCENTS).outlined,iconRight:`undo`},{default:withCtx(()=>[createVNode(unref(bngBinding_default),{"ui-event":`back`,controller:``})]),_:1},8,[`accent`])):createCommentVNode(``,!0),withDirectives(createBaseVNode(`div`,_hoisted_6$129,[createVNode(unref(bngIcon_default),{type:unref(icons).adjust},null,8,[`type`]),createVNode(unref(bngBinding_default),{"ui-event":`context`,controller:``})],512),[[vShow,activeSectionScope.value===`grid`||!unref(showIfController)]]),withDirectives(createBaseVNode(`div`,_hoisted_7$115,[createVNode(unref(bngBinding_default),{"ui-event":`back`,controller:``}),createVNode(unref(bngIcon_default),{type:unref(icons).undo},null,8,[`type`])],512),[[vShow,activeSectionScope.value===`details`&&unref(showIfController)]])]))],2),unref(detailsMode)===`advanced`?(openBlock(),createElementBlock(`div`,_hoisted_8$96,[createVNode(SearchBar_default,{searchText:unref(store$1).searchText.value,setSearchText:unref(store$1).setSearchText},null,8,[`searchText`,`setSearchText`]),createVNode(DetailedFilters_default,{filterList:unref(store$1).filterList.value,filterByProp:unref(store$1).filterByProp.value,searchText:unref(store$1).searchText.value,commonFilters:unref(store$1).commonFilters.value,detailsMode:unref(store$1).detailsMode.value,onlyCommonFilters:unref(store$1).onlyCommonFilters.value,isFilterLocked:unref(store$1).isFilterLocked,isFilterOptionLocked:unref(store$1).isFilterOptionLocked,isRangeFilterLocked:unref(store$1).isRangeFilterLocked,toggleFilter:unref(store$1).toggleFilter,updateRangeFilter:unref(store$1).updateRangeFilter,resetRangeFilter:unref(store$1).resetRangeFilter,setSearchText:unref(store$1).setSearchText,setDetailsMode:unref(store$1).setDetailsMode},null,8,[`filterList`,`filterByProp`,`searchText`,`commonFilters`,`detailsMode`,`onlyCommonFilters`,`isFilterLocked`,`isFilterOptionLocked`,`isRangeFilterLocked`,`toggleFilter`,`updateRangeFilter`,`resetRangeFilter`,`setSearchText`,`setDetailsMode`]),createVNode(DisplayControls_default,{displayData:unref(store$1).displayData.value,detailsMode:unref(store$1).detailsMode.value,updateDisplayData:unref(store$1).updateDisplayData,resetDisplayDataToDefaults:unref(store$1).resetDisplayDataToDefaults,setDetailsMode:unref(store$1).setDetailsMode},null,8,[`displayData`,`detailsMode`,`updateDisplayData`,`resetDisplayDataToDefaults`,`setDetailsMode`]),createBaseVNode(`div`,_hoisted_9$86,[createVNode(unref(bngButton_default),{onClick:_cache[1]||=$event=>toggleDetailsMode(`filter`),accent:unref(ACCENTS).secondary,iconLeft:`filter`},{default:withCtx(()=>[..._cache[3]||=[createTextVNode(` More filters... `,-1)]]),_:1},8,[`accent`]),createVNode(unref(bngButton_default),{onClick:_cache[2]||=$event=>toggleDetailsMode(`displayControls`),accent:unref(ACCENTS).secondary,iconLeft:`adjust`},{default:withCtx(()=>[..._cache[4]||=[createTextVNode(` Display Options `,-1)]]),_:1},8,[`accent`])]),createVNode(unref(bngCardHeading_default),{type:`line`,class:`heading`},{default:withCtx(()=>[..._cache[5]||=[createTextVNode(`Management`,-1)]]),_:1}),renderSlot(_ctx.$slots,`management-details`,{managementDetails:unref(store$1).managementDetails.value,executeButton:unref(store$1).executeButton},void 0,!0)])):unref(detailsMode)===`filter`?(openBlock(),createElementBlock(`div`,_hoisted_10$75,[createVNode(DetailedFilters_default,{filterList:unref(store$1).filterList.value,filterByProp:unref(store$1).filterByProp.value,searchText:unref(store$1).searchText.value,commonFilters:unref(store$1).commonFilters.value,detailsMode:unref(store$1).detailsMode.value,onlyCommonFilters:unref(store$1).onlyCommonFilters.value,isFilterLocked:unref(store$1).isFilterLocked,isFilterOptionLocked:unref(store$1).isFilterOptionLocked,isRangeFilterLocked:unref(store$1).isRangeFilterLocked,toggleFilter:unref(store$1).toggleFilter,updateRangeFilter:unref(store$1).updateRangeFilter,resetRangeFilter:unref(store$1).resetRangeFilter,setSearchText:unref(store$1).setSearchText,setDetailsMode:unref(store$1).setDetailsMode},null,8,[`filterList`,`filterByProp`,`searchText`,`commonFilters`,`detailsMode`,`onlyCommonFilters`,`isFilterLocked`,`isFilterOptionLocked`,`isRangeFilterLocked`,`toggleFilter`,`updateRangeFilter`,`resetRangeFilter`,`setSearchText`,`setDetailsMode`])])):unref(detailsMode)===`displayControls`?(openBlock(),createBlock(DisplayControls_default,{key:2,class:`scrollable-content`,displayData:unref(store$1).displayData.value,detailsMode:unref(store$1).detailsMode.value,updateDisplayData:unref(store$1).updateDisplayData,resetDisplayDataToDefaults:unref(store$1).resetDisplayDataToDefaults,setDetailsMode:unref(store$1).setDetailsMode},null,8,[`displayData`,`detailsMode`,`updateDisplayData`,`resetDisplayDataToDefaults`,`setDetailsMode`])):unref(detailsMode)===`detail`?(openBlock(),createElementBlock(Fragment,{key:3},[hasSelectedItem.value?(openBlock(),createElementBlock(`div`,_hoisted_11$67,[renderSlot(_ctx.$slots,`item-details`,{activeItem:unref(store$1).activeItem.value,activeItemDetails:unref(store$1).activeItemDetails.value,executeButton:unref(store$1).executeButton,toggleFavourite:unref(store$1).toggleFavourite,exploreFolder:unref(store$1).exploreFolder,goToMod:unref(store$1).goToMod,onFocusItem:setDetailsScope},void 0,!0)])):(openBlock(),createElementBlock(`div`,_hoisted_12$55,[createVNode(SearchBar_default,{searchText:unref(store$1).searchText.value,setSearchText:unref(store$1).setSearchText},null,8,[`searchText`,`setSearchText`]),createVNode(DetailedFilters_default,{filterList:unref(store$1).filterList.value,filterByProp:unref(store$1).filterByProp.value,searchText:unref(store$1).searchText.value,commonFilters:unref(store$1).commonFilters.value,detailsMode:unref(store$1).detailsMode.value,onlyCommonFilters:unref(store$1).onlyCommonFilters.value,isFilterLocked:unref(store$1).isFilterLocked,isFilterOptionLocked:unref(store$1).isFilterOptionLocked,isRangeFilterLocked:unref(store$1).isRangeFilterLocked,toggleFilter:unref(store$1).toggleFilter,updateRangeFilter:unref(store$1).updateRangeFilter,resetRangeFilter:unref(store$1).resetRangeFilter,setSearchText:unref(store$1).setSearchText,setDetailsMode:unref(store$1).setDetailsMode},null,8,[`filterList`,`filterByProp`,`searchText`,`commonFilters`,`detailsMode`,`onlyCommonFilters`,`isFilterLocked`,`isFilterOptionLocked`,`isRangeFilterLocked`,`toggleFilter`,`updateRangeFilter`,`resetRangeFilter`,`setSearchText`,`setDetailsMode`]),createVNode(DisplayControls_default,{displayData:unref(store$1).displayData.value,detailsMode:unref(store$1).detailsMode.value,updateDisplayData:unref(store$1).updateDisplayData,resetDisplayDataToDefaults:unref(store$1).resetDisplayDataToDefaults,setDetailsMode:unref(store$1).setDetailsMode},null,8,[`displayData`,`detailsMode`,`updateDisplayData`,`resetDisplayDataToDefaults`,`setDetailsMode`]),createVNode(unref(bngCardHeading_default),{type:`line`,class:`heading`},{default:withCtx(()=>[..._cache[6]||=[createTextVNode(`Info`,-1)]]),_:1}),_cache[7]||=createBaseVNode(`div`,{class:`scrollable-content`},` Please select an item to see details. `,-1)]))],64)):createCommentVNode(``,!0)],34)),[[unref(BngScopedNav_default),{activated:scopedNavState.isDetailsActive,canDeactivate:()=>!1,canBubbleEvent:canBubbleDetailsEvent,bubbleWhitelistEvents:[`menu`]}],[unref(BngOnUiNav_default),onToggleSectionScope,`context`],[unref(BngUiNavLabel_default),`Filters and more`,`context`],[unref(BngOnUiNav_default),onToggleFavorite,`action_2`],[unref(BngUiNavLabel_default),`Toggle favorite`,`action_2`],[unref(BngOnUiNav_default),onBackFromDetails,`back`,{focusRequired:!0}]])])]),_:3})),[[unref(BngBlur_default)],[unref(BngOnUiNav_default),()=>{},`rotate_h_cam,rotate_v_cam`]])}},GridSelector_default=__plugin_vue_export_helper_default(_sfc_main$311,[[`__scopeId`,`data-v-d340d12f`]]),_hoisted_1$277={class:`details`,"bng-nav-scroll":``},_hoisted_2$228={key:0,class:`preview`},_hoisted_3$202={key:1,class:`content-header`},_hoisted_4$173={key:0,class:`description`},_hoisted_5$149={key:0,class:`specs-grid`},_hoisted_6$128={class:`specs-grid-container`},_hoisted_7$114={class:`spec-content`},_hoisted_8$95={class:`spec-label`},_hoisted_9$85={class:`spec-value`},_hoisted_10$74={key:2,class:`buttons-section`},_sfc_main$310={__name:`AppDetails`,props:{activeItem:{type:Object,default:null},activeItemDetails:{type:Object,default:null},executeButton:{type:Function,required:!0},toggleFavourite:{type:Function,required:!0}},setup(__props){let props=__props,handleButtonClick=buttonId=>{props.executeButton(buttonId)};return(_ctx,_cache)=>withDirectives((openBlock(),createElementBlock(`div`,_hoisted_1$277,[__props.activeItemDetails?.preview?(openBlock(),createElementBlock(`div`,_hoisted_2$228,[createVNode(unref(aspectRatio_default),{class:`preview-image`,ratio:`16:8`,"external-image":__props.activeItemDetails.preview},null,8,[`external-image`])])):createCommentVNode(``,!0),__props.activeItemDetails?.headerTitle?(openBlock(),createElementBlock(`div`,_hoisted_3$202,[__props.activeItemDetails?.description?(openBlock(),createElementBlock(`div`,_hoisted_4$173,toDisplayString(__props.activeItemDetails.description),1)):createCommentVNode(``,!0)])):createCommentVNode(``,!0),(openBlock(!0),createElementBlock(Fragment,null,renderList(__props.activeItemDetails?.specifications,(specList,specListIndex)=>(openBlock(),createElementBlock(Fragment,{key:specListIndex},[specList.length>0?(openBlock(),createElementBlock(`div`,_hoisted_5$149,[createBaseVNode(`div`,_hoisted_6$128,[(openBlock(!0),createElementBlock(Fragment,null,renderList(specList,specification=>(openBlock(),createElementBlock(`div`,{key:specification.key,class:`spec-cell`},[specification.icon?(openBlock(),createBlock(unref(bngIcon_default),{key:0,type:specification.icon,class:`spec-icon`},null,8,[`type`])):createCommentVNode(``,!0),createBaseVNode(`div`,_hoisted_7$114,[createBaseVNode(`div`,_hoisted_8$95,toDisplayString(specification.label)+`:`,1),createBaseVNode(`div`,_hoisted_9$85,[createBaseVNode(`span`,null,toDisplayString(specification.value),1)])])]))),128))])])):createCommentVNode(``,!0)],64))),128)),__props.activeItemDetails?.buttonInfo?.length>0?(openBlock(),createElementBlock(`div`,_hoisted_10$74,[(openBlock(!0),createElementBlock(Fragment,null,renderList(__props.activeItemDetails.buttonInfo,button=>(openBlock(),createBlock(unref(bngButton_default),{key:button.buttonId,"bng-scoped-nav-autofocus":button.primary,accent:button.primary?`main`:`secondary`,label:button.label,icon:button.icon,onClick:$event=>handleButtonClick(button.buttonId)},null,8,[`bng-scoped-nav-autofocus`,`accent`,`label`,`icon`,`onClick`]))),128))])):createCommentVNode(``,!0)])),[[unref(BngUiNavScroll_default),void 0,void 0,{force:!0}]])}},AppDetails_default=__plugin_vue_export_helper_default(_sfc_main$310,[[`__scopeId`,`data-v-c8fb13f2`]]),_sfc_main$309={__name:`AppSelector`,setup(__props){return(_ctx,_cache)=>(openBlock(),createBlock(GridSelector_default,{backendName:`appSelector`,routePath:`/app-selector`,defaultPath:{keys:[`allApps`]},defaultDetailsMode:`advanced`},{"item-details":withCtx(({activeItem,activeItemDetails,executeButton,toggleFavourite})=>[createVNode(AppDetails_default,{activeItem,activeItemDetails,executeButton,toggleFavourite},null,8,[`activeItem`,`activeItemDetails`,`executeButton`,`toggleFavourite`])]),_:1}))}},AppSelector_default=_sfc_main$309,routes_default=[{name:`menu.appselector`,path:`/app-selector/:pathMatch(.*)*`,component:AppSelector_default,props:!0,meta:{clickThrough:!1,infoBar:{visible:!0,showSysInfo:!1},uiApps:{shown:!1},topBar:{visible:!0}}},{name:`menu.appedit`,path:`/app-edit/`,component:NotFound_default,meta:{clickThrough:!0,infoBar:{visible:!0,showSysInfo:!1},uiApps:{shown:!0},topBar:{visible:!0}}}],_hoisted_1$276={class:`main-info`},_hoisted_2$227={class:`heading`},_hoisted_3$201={key:0,class:`stars`},_hoisted_4$172={key:1,class:`aggregate-primary`},_hoisted_5$148={class:`label`},_hoisted_6$127={class:`value`},_hoisted_7$113={key:2,class:`empty-gap`},_sfc_main$308={__name:`PoiCard`,props:{poi:{type:Object,required:!0},shown:{type:Boolean,default:!0}},emits:[`select`,`hover`],setup(__props,{emit:__emit}){let debugLog$1=(message,data)=>{},props=__props,emit$1=__emit,onSelect=()=>{props.poi.id,props.poi.name,emit$1(`select`,props.poi.id)},thumbLoaded=props.shown&&!!props.poi?.thumbnail,thumbShown=ref(thumbLoaded),thumb=ref(thumbLoaded?`url("${props.poi?.thumbnail}")`:`none`),lastThumb=thumbLoaded?props.poi?.thumbnail:void 0;return watch([()=>props.shown,()=>props.poi],()=>{if(props.shown&&props.poi?.thumbnail){let url=props.poi.thumbnail;if(lastThumb!==url){lastThumb=url,thumbLoaded=!1;let img=new Image;img.src=url,img.onload=()=>{lastThumb===url&&(thumbLoaded=!0,thumb.value=`url("${url}")`,thumbShown.value=!0)}}}else props.poi?.thumbnail||(lastThumb=void 0,thumbLoaded=!1,thumb.value=`none`,thumbShown.value=!1)},{immediate:!0}),(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,{class:normalizeClass([`poi-item`,{highlighted:__props.poi.isSelected}]),onClick:onSelect,"bng-nav-item":``},[createBaseVNode(`div`,{class:normalizeClass([`card-info`,{"content-shown":__props.shown,"thumb-show":thumbShown.value&&!!thumb.value}]),style:normalizeStyle({"--poi-image":thumb.value})},[__props.poi.icon?(openBlock(),createBlock(unref(bngIcon_default),{key:0,class:`mission-icon`,type:__props.poi.icon,color:`white`},null,8,[`type`])):createCommentVNode(``,!0),createBaseVNode(`div`,_hoisted_1$276,[createBaseVNode(`div`,_hoisted_2$227,toDisplayString(__props.poi.name),1),__props.poi.formattedProgress?(openBlock(),createElementBlock(`div`,_hoisted_3$201,[__props.poi.formattedProgress.unlockedStars?(openBlock(),createBlock(unref(bngMainStars_default),{key:0,"individual-stars":__props.poi.formattedProgress.unlockedStars.defaults,class:`main-stars`,scale:.6,reverse:``},null,8,[`individual-stars`])):createCommentVNode(``,!0),__props.poi.formattedProgress.unlockedStars&&__props.poi.formattedProgress.unlockedStars.totalBonusStarCount>0?(openBlock(),createBlock(unref(bngMainStars_default),{key:1,"individual-stars":__props.poi.formattedProgress.unlockedStars.bonus,class:`bonus-stars`,scale:.6},null,8,[`individual-stars`])):createCommentVNode(``,!0)])):__props.poi.aggregatePrimary?(openBlock(),createElementBlock(`div`,_hoisted_4$172,[createBaseVNode(`span`,_hoisted_5$148,toDisplayString(__props.poi.aggregatePrimary.label)+`:`,1),createBaseVNode(`span`,_hoisted_6$127,toDisplayString(__props.poi.aggregatePrimary.value),1)])):(openBlock(),createElementBlock(`div`,_hoisted_7$113))]),createVNode(unref(bngBinding_default),{class:`input-icon`,"ui-event":`ok`,controller:``})],6)],2))}},PoiCard_default=__plugin_vue_export_helper_default(_sfc_main$308,[[`__scopeId`,`data-v-cd49bd11`]]),_hoisted_1$275={class:`poi-list`},_hoisted_2$226={class:`filter-header`},_hoisted_3$200={class:`poi-list-items`},_sfc_main$307={__name:`PoiList`,props:{store:{type:Object,required:!0}},setup(__props){let props=__props,poiListContainer=ref(null),shownCards=ref(new Set),{groupData,poiData,selectedPoi,selectPoi,onHover,debugLog:debugLog$1}=props.store,processedPoiData=computed(()=>{let processed={};if(!poiData.value)return processed;for(let[poiId,poi]of Object.entries(poiData.value))poi&&(processed[poiId]={id:poi.id||poiId,name:poi.name?$translate.instant(poi.name):``,icon:poi.icon?icons[poi.icon]:icons._empty,thumbnail:poi.thumbnailFile,formattedProgress:poi.formattedProgress,aggregatePrimary:poi.aggregatePrimary?.label&&poi.aggregatePrimary?.value?{label:$translate.instant(poi.aggregatePrimary.label),value:$translate.instant(poi.aggregatePrimary.value)}:null,isSelected:selectedPoi.value?.id===poi.id});return processed});debugLog$1(`PoiList`,`Component initialized`,{groupDataCount:groupData.value?.length||0,poiDataCount:Object.keys(poiData.value||{}).length,processedPoiCount:Object.keys(processedPoiData.value).length});let observer$2=new IntersectionObserver(entries=>{for(let entry of entries){let poiId=entry.target.getAttribute(`data-poi-id`);poiId&&entry.isIntersecting?shownCards.value.add(poiId):shownCards.value.delete(poiId)}},{threshold:.1,rootMargin:`10px`}),setupObserver=()=>{if(!poiListContainer.value)return;let elms$4=poiListContainer.value.querySelectorAll(`[data-poi-id]`),ids=[];for(let elm of elms$4){let poiId=elm.getAttribute(`data-poi-id`);poiId&&(ids.push(poiId),observer$2.observe(elm))}for(let id of shownCards.value)ids.includes(id)||shownCards.value.delete(id)};return watch(poiListContainer,cont=>cont&&nextTick(setupObserver),{immediate:!0}),watch([groupData,processedPoiData],()=>{nextTick(()=>{observer$2.disconnect(),setupObserver()})},{immediate:!1}),onUnmounted(()=>{shownCards.value.clear(),observer$2.disconnect()}),(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$275,[createBaseVNode(`div`,{class:`poi-list-content`,ref_key:`poiListContainer`,ref:poiListContainer},[(openBlock(!0),createElementBlock(Fragment,null,renderList(unref(groupData),section=>(openBlock(),createElementBlock(`div`,{key:section.key,class:`filter-section`},[createBaseVNode(`div`,_hoisted_2$226,[createVNode(unref(bngIcon_default),{type:section.icon},null,8,[`type`]),createBaseVNode(`span`,null,toDisplayString(section.title?_ctx.$tt(section.title):``),1)]),(openBlock(!0),createElementBlock(Fragment,null,renderList(section.groups,group=>(openBlock(),createElementBlock(`div`,{key:group.key,class:`mission-group`},[createVNode(unref(bngCardHeading_default),{class:`mission-group-header`,type:`ribbon`,outline:``},{default:withCtx(()=>[createTextVNode(toDisplayString(_ctx.$t(group.label)),1)]),_:2},1024),createBaseVNode(`div`,_hoisted_3$200,[(openBlock(!0),createElementBlock(Fragment,null,renderList(group.elementIds,poiId=>(openBlock(),createBlock(PoiCard_default,{key:poiId,"data-poi-id":poiId,shown:shownCards.value.has(poiId),poi:processedPoiData.value[poiId],onSelect:unref(selectPoi),onHover:unref(onHover)},null,8,[`data-poi-id`,`shown`,`poi`,`onSelect`,`onHover`]))),128))])]))),128))]))),128))],512)]))}},PoiList_default=__plugin_vue_export_helper_default(_sfc_main$307,[[`__scopeId`,`data-v-0ccba230`]]),_hoisted_1$274={class:`header`},_sfc_main$306={__name:`bngAdvCardHeading`,props:{blurDelay:Number,preheadings:Array,divider:Boolean,icon:String,type:{type:String,default:`line`,validator:v=>[`line`,`ribbon`].includes(v)||v===``}},setup(__props){let blurVal=ref(!1);onMounted(()=>window.setTimeout(()=>blurVal.value=!0,~~+props.blurDelay));let props=__props;return(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,{class:normalizeClass([`bng-screen-header`,{[`heading-style-${__props.type}`]:!0,prehead:__props.preheadings}])},[_cache[0]||=createBaseVNode(`div`,{class:`decorator`},null,-1),__props.preheadings?(openBlock(),createElementBlock(`span`,{key:0,class:normalizeClass([`pre-header`,{"with-divider":__props.divider}])},[__props.icon?(openBlock(),createBlock(unref(bngIcon_default),{key:0,type:__props.icon,class:`pre-header-icon`},null,8,[`type`])):createCommentVNode(``,!0),(openBlock(!0),createElementBlock(Fragment,null,renderList(__props.preheadings,preheading=>(openBlock(),createElementBlock(`span`,{class:`location`,key:preheading},toDisplayString(preheading),1))),128))],2)):createCommentVNode(``,!0),createBaseVNode(`h1`,_hoisted_1$274,[renderSlot(_ctx.$slots,`default`,{},void 0,!0)])],2))}},bngAdvCardHeading_default=__plugin_vue_export_helper_default(_sfc_main$306,[[`__scopeId`,`data-v-16619e8d`]]),_hoisted_1$273={key:0,class:`poi-icons`},_hoisted_2$225=[`onClick`],_hoisted_3$199={key:1,class:`poi-details`},_hoisted_4$171={class:`poi-content`},_hoisted_5$147={class:`poi-scrollable`},_hoisted_6$126={key:0,class:`poi-aggregate-display`},_hoisted_7$112={key:0,class:`poi-stars`},_hoisted_8$94={class:`stars`},_hoisted_9$84={key:1,class:`aggregate-primary`},_hoisted_10$73={class:`label`},_hoisted_11$66={class:`value`},_hoisted_12$54={key:1,class:`poi-description`},_hoisted_13$47={class:`poi-actions`},_sfc_main$305={__name:`PoiDetails`,props:{store:{type:Object,required:!0}},emits:[`setRoute`,`teleport`],setup(__props,{emit:__emit}){let props=__props,{selectedPoi,selectedPoiIds,poiData,debugLog:debugLog$1}=props.store;debugLog$1(`PoiDetails`,`Component initialized`,{selectedPoiId:selectedPoi.value?.id,selectedPoiIdsCount:selectedPoiIds.value?.length||0});let selectedPoisList=computed(()=>{if(!selectedPoiIds.value||selectedPoiIds.value.length===0)return selectedPoi.value?[selectedPoi.value]:[];let pois=[];for(let poiId of selectedPoiIds.value){let poi=poiData.value[poiId];poi&&pois.push(poi)}return debugLog$1(`PoiDetails`,`Final pois list`,pois),pois}),currentPoiIndex=computed(()=>{if(selectedPoisList.value.length<=1)return 0;let index=selectedPoisList.value.findIndex(poi=>poi.id===selectedPoi.value?.id);return index>=0?index:0}),selectPoi=index=>{index>=0&&index{let headings=[];return selectedPoi.value?.label&&headings.push($translate.instant(selectedPoi.value.label)),headings}),preview=computed(()=>selectedPoi.value?.previewFiles?.length>0?selectedPoi.value.previewFiles[0]:selectedPoi.value?.thumbnailFile||null),safeTranslate=key=>{if(!key)return``;try{return typeof key==`string`?$translate.instant(key):(typeof key==`object`&&key.txt,$translate.contextTranslate(key))}catch(e){return console.warn(`Translation failed for key:`,key,e),typeof key==`string`?key:key?.txt||``}},aggregatePrimary=computed(()=>{let poi=selectedPoi.value;return poi?.aggregatePrimary?.label&&poi?.aggregatePrimary?.value?poi.aggregatePrimary:null}),onAction=action=>{props.store.executePoiAction(action.actionId)};return(_ctx,_cache)=>(openBlock(),createElementBlock(Fragment,null,[selectedPoisList.value.length>=1?withDirectives((openBlock(),createElementBlock(`div`,_hoisted_1$273,[(openBlock(!0),createElementBlock(Fragment,null,renderList(selectedPoisList.value,(poi,index)=>(openBlock(),createElementBlock(`div`,{key:poi.id||index,class:normalizeClass([`poi-icon`,{active:index===currentPoiIndex.value}]),onClick:$event=>selectPoi(index)},[createVNode(unref(bngSpriteIcon_default),{src:`map_`+poi.spriteIcon,style:{width:`100%`,height:`100%`}},null,8,[`src`])],10,_hoisted_2$225))),128))])),[[unref(BngBlur_default),!0]]):createCommentVNode(``,!0),unref(selectedPoi)?withDirectives((openBlock(),createElementBlock(`div`,_hoisted_3$199,[createBaseVNode(`div`,_hoisted_4$171,[createVNode(bngAdvCardHeading_default,{class:`poi-details-header`,type:`line`,preheadings:preheadings.value},{default:withCtx(()=>[createTextVNode(toDisplayString(safeTranslate(unref(selectedPoi).name)),1)]),_:1},8,[`preheadings`]),createBaseVNode(`div`,_hoisted_5$147,[preview.value?(openBlock(),createBlock(aspectRatio_default,{key:0,class:`poi-thumbnail`,ratio:`16:9`,externalImage:preview.value,imageMode:`cover`},{default:withCtx(()=>[aggregatePrimary.value||unref(selectedPoi).formattedProgress?(openBlock(),createElementBlock(`div`,_hoisted_6$126,[unref(selectedPoi).formattedProgress?(openBlock(),createElementBlock(`div`,_hoisted_7$112,[createBaseVNode(`div`,_hoisted_8$94,[unref(selectedPoi).formattedProgress.unlockedStars?(openBlock(),createBlock(unref(bngMainStars_default),{key:0,individualStars:unref(selectedPoi).formattedProgress.unlockedStars.defaults,class:`main-stars`,scale:.8,reverse:``},null,8,[`individualStars`])):createCommentVNode(``,!0),unref(selectedPoi).formattedProgress.unlockedStars&&unref(selectedPoi).formattedProgress.unlockedStars.totalBonusStarCount>0?(openBlock(),createBlock(unref(bngMainStars_default),{key:1,individualStars:unref(selectedPoi).formattedProgress.unlockedStars.bonus,class:`bonus-stars`,scale:.8},null,8,[`individualStars`])):createCommentVNode(``,!0)])])):aggregatePrimary.value?(openBlock(),createElementBlock(`div`,_hoisted_9$84,[createBaseVNode(`span`,_hoisted_10$73,toDisplayString(_ctx.$t(aggregatePrimary.value.label))+`:`,1),createBaseVNode(`span`,_hoisted_11$66,toDisplayString(_ctx.$t(aggregatePrimary.value.value)),1)])):createCommentVNode(``,!0)])):createCommentVNode(``,!0)]),_:1},8,[`externalImage`])):createCommentVNode(``,!0),unref(selectedPoi).description?(openBlock(),createElementBlock(`div`,_hoisted_12$54,toDisplayString(safeTranslate(unref(selectedPoi).description)),1)):createCommentVNode(``,!0)]),createBaseVNode(`div`,_hoisted_13$47,[(openBlock(!0),createElementBlock(Fragment,null,renderList(unref(selectedPoi).actions,action=>(openBlock(),createBlock(unref(bngButton_default),{key:action.id,accent:unref(ACCENTS).secondary,"icon-right":action.icon,label:action.label,onClick:$event=>onAction(action)},null,8,[`accent`,`icon-right`,`label`,`onClick`]))),128))])])])),[[unref(BngBlur_default),!0]]):createCommentVNode(``,!0)],64))}},PoiDetails_default=__plugin_vue_export_helper_default(_sfc_main$305,[[`__scopeId`,`data-v-35e47e7e`]]),_hoisted_1$272={class:`poi-filters`},_hoisted_2$224={key:0,class:`filter-row`},_hoisted_3$198=[`onClick`],_hoisted_4$170=[`onClick`],_sfc_main$304={__name:`PoiFilters`,props:{store:{type:Object,required:!0}},setup(__props){let props=__props,{filterData,debugLog:debugLog$1}=props.store;debugLog$1(`PoiFilters`,`Component initialized`,{filterDataCount:filterData.value?.length||0});let getGroupVisualState=(filter,group)=>{if(!filter||!group||!filter.groups||!Array.isArray(filter.groups))return`inactive`;let visibleGroups=0,totalGroups=0;for(let filterGroup of filter.groups)filterGroup&&filterGroup.elementCount>0&&(totalGroups++,filterGroup.visible&&visibleGroups++);let isAllGroupsActive=visibleGroups===totalGroups,isGroupActive=group.visible;return isAllGroupsActive?`neutral`:isGroupActive?`active`:`inactive`},getGroupColor=(filter,group)=>{switch(getGroupVisualState(filter,group)){case`neutral`:return`var(--bng-off-white)`;case`active`:return`var(--bng-add-green-100)`;case`inactive`:default:return`var(--bng-add-red-300)`}},hasActiveFilters=filter=>{if(!filter||!filter.groups||!Array.isArray(filter.groups))return!1;let visibleGroups=0,totalGroups=0;for(let group of filter.groups)group&&group.elementCount>0&&(totalGroups++,group.visible&&visibleGroups++);return visibleGroups{debugLog$1(`PoiFilters`,`Toggling group visibility`,groupKey),props.store.toggleGroupVisibility(groupKey)},toggleFilterSectionVisibility=filterKey=>{debugLog$1(`PoiFilters`,`Toggling filter section visibility`,filterKey),props.store.toggleFilterSectionVisibility(filterKey)};return(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$272,[(openBlock(!0),createElementBlock(Fragment,null,renderList(unref(filterData),filterSection=>(openBlock(),createElementBlock(Fragment,{key:filterSection.key},[filterSection&&filterSection.groups?withDirectives((openBlock(),createElementBlock(`div`,_hoisted_2$224,[createBaseVNode(`div`,{class:normalizeClass([`filter-icon`,{"has-active-filters":hasActiveFilters(filterSection)}]),onClick:$event=>toggleFilterSectionVisibility(filterSection.key)},[createVNode(bngTooltip_default,{text:_ctx.$tt(filterSection.title)},{default:withCtx(()=>[createVNode(unref(bngIcon_default),{type:filterSection.icon},null,8,[`type`])]),_:2},1032,[`text`])],10,_hoisted_3$198),_cache[0]||=createBaseVNode(`div`,{class:`filter-separator`},null,-1),(openBlock(!0),createElementBlock(Fragment,null,renderList(filterSection.groups,group=>(openBlock(),createElementBlock(Fragment,{key:group.key},[group&&group.elementCount>0?(openBlock(),createElementBlock(`div`,{key:0,class:normalizeClass([`filter-group`,{inactive:!group.visible}]),onClick:$event=>toggleGroupVisibility(group.key)},[createVNode(bngTooltip_default,{text:_ctx.$tt(group.label)+` ×`+group.elementCount},{default:withCtx(()=>[createVNode(unref(bngIcon_default),{type:group.icon||`info`,color:getGroupColor(filterSection,group)},null,8,[`type`,`color`])]),_:2},1032,[`text`])],10,_hoisted_4$170)):createCommentVNode(``,!0)],64))),128))])),[[unref(BngBlur_default),!0]]):createCommentVNode(``,!0)],64))),128))]))}},PoiFilters_default=__plugin_vue_export_helper_default(_sfc_main$304,[[`__scopeId`,`data-v-43aa27ac`]]);const debugLog=(component,message,data)=>{};function useBigMap(){let selectedPoi=ref(null),selectedPoiIds=ref([]),filterData=ref([]),groupData=ref([]),poiData=ref({}),gameMode=ref(``),levelData=ref({title:``}),isPoiListVisible=ref(!1),isDetailsVisible=ref(!1),{events:events$3}=useBridge(),translatedPreheadings=computed(()=>{let preheadings=[];return gameMode.value&&preheadings.push($translate.instant(`ui.playmodes.${gameMode.value}`)),levelData.value?.title&&preheadings.push($translate.instant(levelData.value.title)),preheadings}),currentFilterTitle=computed(()=>$translate.instant(`bigMap.sideMenu.pois`)),getStaticDataFromLua=async()=>{try{poiData.value=await Lua_default.freeroam_vueBigMap.getPoiData()||{};let gameStateResult=await Lua_default.freeroam_vueBigMap.getGameStateInfo();gameStateResult&&(gameMode.value=gameStateResult.gameMode||``,levelData.value=gameStateResult.levelData||{title:``}),poiData.value,gameMode.value}catch(error){console.error(`Error getting static data from Lua:`,error)}},getDynamicDataFromLua=async()=>{try{filterData.value=await Lua_default.freeroam_vueBigMap.getFilters()||[],groupData.value=await Lua_default.freeroam_vueBigMap.getGroups()||[],filterData.value,groupData.value}catch(error){console.error(`Error getting dynamic data from Lua:`,error)}},handleShowPoiDetails=data=>{let poiIds=data?.poiIds||[];if(selectedPoiIds.value=poiIds,poiIds.length===0){selectedPoi.value=null,isDetailsVisible.value=!1;return}let selectedPoiId=poiIds[0];selectedPoiId&&poiData.value[selectedPoiId]?(selectedPoi.value=poiData.value[selectedPoiId],isDetailsVisible.value=!0):(selectedPoi.value=null,isDetailsVisible.value=!1)},toggleGroupVisibility=async groupKey=>{try{let filterIds=[groupKey];await Lua_default.freeroam_vueBigMap.toggleFiltersByIds(filterIds),await getDynamicDataFromLua()}catch(error){console.error(`Error toggling group visibility:`,error)}},toggleFilterSectionVisibility=async filterKey=>{try{await Lua_default.freeroam_vueBigMap.toggleFilterSectionById(filterKey),await getDynamicDataFromLua()}catch(error){console.error(`Error toggling filter visibility:`,error)}},selectPoi=async poiId=>{try{let result=await Lua_default.freeroam_vueBigMap.selectPoiFromList(poiId);result===`success`?poiId?(selectedPoi.value=poiData.value[poiId],isDetailsVisible.value=!0):(selectedPoi.value=null,isDetailsVisible.value=!1):console.error(`Failed to select POI:`,result)}catch(error){console.error(`Error selecting POI:`,error)}};return{selectedPoi,selectedPoiIds,filterData,groupData,poiData,gameMode,levelData,isPoiListVisible,isDetailsVisible,translatedPreheadings,currentFilterTitle,initialize:async()=>{try{await Lua_default.freeroam_vueBigMap.enterBigMap(),await getStaticDataFromLua(),await getDynamicDataFromLua(),events$3.on(`showPoiDetails`,handleShowPoiDetails)}catch(error){console.error(`Error initializing bigmap:`,error)}},cleanup:async()=>{try{await Lua_default.freeroam_vueBigMap.exitBigMap(),events$3.off(`showPoiDetails`)}catch(error){console.error(`Error cleaning up bigmap:`,error)}},selectPoi,showPoiList:()=>{isPoiListVisible.value=!0},hidePoiList:()=>{isPoiListVisible.value=!1,selectedPoi.value&&selectPoi(null)},onHover:async(poiId,active)=>{try{await Lua_default.freeroam_vueBigMap.hoverPoiFromList(poiId,active)}catch(error){console.error(`Error hovering POI:`,error)}},executePoiAction:async actionId=>{try{await Lua_default.freeroam_vueBigMap.executePoiAction(actionId)}catch(error){console.error(`Error executing POI action:`,error)}},toggleGroupVisibility,toggleFilterSectionVisibility,debugLog}}var _hoisted_1$271={class:`bigmap-container`},_hoisted_2$223={class:`bigmap-content`},_hoisted_3$197={class:`bigmap-left-content`},_hoisted_4$169={class:`bigmap-poilist-outline`},_hoisted_5$146={key:0,class:`bigmap-details-outline`},_sfc_main$303={__name:`BigMap`,setup(__props){let store$1=useBigMap(),{isPoiListVisible,isDetailsVisible,translatedPreheadings,currentFilterTitle,onSetRoute,onTeleport,toggleGroupVisibility,initialize,cleanup,debugLog:debugLog$1}=store$1,handleToggleGroupVisibility=groupKey=>{debugLog$1(`BigMap`,`Toggle group visibility`,groupKey),toggleGroupVisibility(groupKey)};return onMounted(()=>{debugLog$1(`BigMap`,`Component mounted, initializing bigmap`),initialize()}),onUnmounted(()=>{debugLog$1(`BigMap`,`Component unmounted, cleaning up bigmap`),cleanup()}),(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$271,[createVNode(unref(bngScreenHeading_default),{class:`bigmap-heading`,preheadings:unref(translatedPreheadings),divider:!0,type:`line`},{default:withCtx(()=>[createTextVNode(toDisplayString(unref(currentFilterTitle)),1)]),_:1},8,[`preheadings`]),createBaseVNode(`div`,_hoisted_2$223,[createBaseVNode(`div`,_hoisted_3$197,[createVNode(PoiFilters_default,{store:unref(store$1),onToggleGroupVisibility:handleToggleGroupVisibility},null,8,[`store`]),createBaseVNode(`div`,_hoisted_4$169,[createVNode(unref(bngDrawer_default),{modelValue:unref(isPoiListVisible),"onUpdate:modelValue":_cache[0]||=$event=>isRef(isPoiListVisible)?isPoiListVisible.value=$event:null,position:`left`,blur:``,header:_ctx.$tt(`bigMap.sideMenu.pois`)},{default:withCtx(()=>[createVNode(PoiList_default,{class:`bigmap-poilist`,store:unref(store$1)},null,8,[`store`])]),_:1},8,[`modelValue`,`header`])])]),_cache[1]||=createBaseVNode(`div`,{class:`bigmap-center-outline`},null,-1),unref(isDetailsVisible)?(openBlock(),createElementBlock(`div`,_hoisted_5$146,[createVNode(PoiDetails_default,{store:unref(store$1),onSetRoute:unref(onSetRoute),onTeleport:unref(onTeleport)},null,8,[`store`,`onSetRoute`,`onTeleport`])])):createCommentVNode(``,!0)])]))}},BigMap_default=__plugin_vue_export_helper_default(_sfc_main$303,[[`__scopeId`,`data-v-e6716bb0`]]),_hoisted_1$270={class:`bigmap-view`},_sfc_main$302={__name:`BigMapView`,setup(__props){return(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$270,[createVNode(BigMap_default)]))}},BigMapView_default=__plugin_vue_export_helper_default(_sfc_main$302,[[`__scopeId`,`data-v-044f4742`]]),routes_default$1=[{path:`/bigmap`,name:`bigmap`,component:BigMapView_default,meta:{uiApps:{shown:!1},infoBar:{visible:!0,showSysInfo:!0}}}],_hoisted_1$269={class:`progress-steps`},_hoisted_2$222={class:`step-container`},_hoisted_3$196={class:`step-header`},_hoisted_4$168={class:`step-number`},_hoisted_5$145={class:`step-icon`},_hoisted_6$125={class:`step-label`},_sfc_main$301={__name:`ProgressSteps`,props:{steps:{type:Array,required:!0,validator:steps=>steps.every(step=>step.label&&typeof step.label==`string`||step.title&&typeof step.title==`string`)},currentStep:{type:Number,required:!0,validator:step=>step>=0}},setup(__props){let props=__props,styles={answeredYes:{class:`answered-yes`,icon:`checkboxOn`},answeredNo:{class:`answered-no`,icon:`missionCheckboxCross`},current:{class:`not-answered current`,icon:`arrowLargeRight`},next:{class:`not-answered`,icon:`checkboxOff`}},steps=computed(()=>props.steps.map((step,idx)=>{let answer=step.isAnswered?step.answerType||`yes`:null,status=`next`;return idx(openBlock(),createElementBlock(`div`,_hoisted_1$269,[createBaseVNode(`div`,_hoisted_2$222,[(openBlock(!0),createElementBlock(Fragment,null,renderList(steps.value,(step,index)=>(openBlock(),createElementBlock(`div`,{key:index,class:normalizeClass([`step`,step.class])},[createBaseVNode(`div`,_hoisted_3$196,[createBaseVNode(`div`,_hoisted_4$168,toDisplayString(index+1),1),step.isLastStep?createCommentVNode(``,!0):(openBlock(),createElementBlock(Fragment,{key:0},[_cache[0]||=createBaseVNode(`div`,{class:`step-connector`},null,-1),createBaseVNode(`div`,_hoisted_5$145,[createVNode(unref(bngIcon_default),{type:step.icon},null,8,[`type`])])],64))]),createBaseVNode(`div`,_hoisted_6$125,toDisplayString(_ctx.$tt(step.label)),1)],2))),128))])]))}},ProgressSteps_default=__plugin_vue_export_helper_default(_sfc_main$301,[[`__scopeId`,`data-v-d5d29cd2`]]);function useWizard(options={}){let{allowSkip=!1,validateSteps=!0}=options,stepRegistry=ref(new Map),currentStepIndex=ref(0),completedSteps=ref(new Set),isFinished=ref(!1),steps=computed(()=>{if(stepRegistry.value.size===0)return[];let res=Array.from(stepRegistry.value.values());for(let step of res)if(!(!step.enabledWhen||step.enabledWhen.length===0)){for(let condition of step.enabledWhen)if(condition.step){let dependencyStep=res.find(s=>s.id===condition.step);if(!dependencyStep)continue;dependencyStep.requiredFor||=[],dependencyStep.requiredFor.includes(step.id)||dependencyStep.requiredFor.push(step.id)}}return res}),registerStep=stepConfig=>stepRegistry.value.set(stepConfig.id,stepConfig),unregisterStep=stepId=>stepRegistry.value.delete(stepId);provide(`registerWizardStep`,registerStep),provide(`unregisterWizardStep`,unregisterStep);let currentStep=computed(()=>steps.value[currentStepIndex.value]||null),isFirstStep=computed(()=>currentStepIndex.value===0),isLastStep=computed(()=>currentStepIndex.value===steps.value.length-1),canGoNext=computed(()=>{if(!validateSteps)return!0;let step=currentStep.value;return!step||!isStepEnabled(step)||step.advanceDisabled?!1:typeof step.validate==`function`?step.validate(step.modelValue||{}):step.type===`choice`&&step.required!==!1?step.modelValue?.choice!==void 0:(step.type,!0)}),isStepEnabled=step=>!step.enabledWhen||step.enabledWhen.length===0?!0:step.enabledWhen.every(condition=>{if(condition.step){let dependencyStepData=steps.value.find(s=>s.id===condition.step)?.modelValue||{};if(condition.value!==void 0)return dependencyStepData?.choice===condition.value||dependencyStepData?.[Object.keys(dependencyStepData)[0]]===condition.value;if(typeof condition.condition==`function`)return condition.condition(dependencyStepData)}return typeof condition.condition==`function`?condition.condition():!0}),canGoBack=computed(()=>!isFirstStep.value),canFinish=computed(()=>validateSteps?isLastStep.value&&canGoNext.value:isLastStep.value),goToStep=index=>{index<=0&&(currentStepIndex.value=0),index>=steps.value.length&&(currentStepIndex.value=steps.value.length-1),currentStepIndex.value=index},nextStep=async()=>{if(await nextTick(),!canGoNext.value)return!1;if(currentStep.value&&completedSteps.value.add(currentStepIndex.value),isLastStep.value)return!0;for(currentStepIndex.value++;currentStepIndex.value=steps.value.length&&(currentStepIndex.value=steps.value.length-1),!0};return{currentStepIndex,currentStep,completedSteps,isFinished,steps,stepRegistry,isFirstStep,isLastStep,canGoNext,canGoBack,canFinish,progress:computed(()=>steps.value.length===0?0:Math.round((currentStepIndex.value+1)/steps.value.length*100)),stepProgress:computed(()=>steps.value.map((step,index)=>{let data=step.modelValue||{},choiceAnalysis=null;if(step.type===`choice`&&step.choices&&data.choice!==void 0){let selectedChoice=step.choices.find(c=>c.value===data.choice),yesChoice=step.choices.find(c=>c.isYes),noChoice=step.choices.find(c=>c.isNo),answerType=null;selectedChoice&&(answerType=selectedChoice.isYes||yesChoice&&selectedChoice.value===yesChoice.value?`yes`:selectedChoice.isNo||noChoice&&selectedChoice.value===noChoice.value?`no`:!yesChoice&&!noChoice?`yes`:step.choices.length===2&&!selectedChoice.isYes&&!selectedChoice.isNo?`no`:`yes`),choiceAnalysis={selectedValue:data.choice,selectedChoice,answerType,hasYesFlag:!!yesChoice,hasNoFlag:!!noChoice}}return{...step,index,isCompleted:completedSteps.value.has(index),isCurrent:index===currentStepIndex.value,isAccessible:index<=currentStepIndex.value,isEnabled:isStepEnabled(step),data,hasData:Object.keys(data).length>0,isAnswered:step.type===`choice`?data.choice!==void 0:Object.keys(data).length>0,answerType:choiceAnalysis?.answerType||null,choiceAnalysis}})),goToStep,nextStep,previousStep:async()=>{if(await nextTick(),!canGoBack.value)return!1;for(currentStepIndex.value--;currentStepIndex.value>=0;){let targetStep=steps.value[currentStepIndex.value];if(isStepEnabled(targetStep)||targetStep.autoSkip===!1)break;currentStepIndex.value--}return currentStepIndex.value<0&&(currentStepIndex.value=0),!0},finish:()=>canFinish.value?(isFinished.value=!0,{success:!0,completedSteps:Array.from(completedSteps.value)}):{success:!1},reset:()=>{currentStepIndex.value=0,completedSteps.value.clear(),isFinished.value=!1},skip:()=>allowSkip?nextStep():!1,isStepEnabled,registerStep,unregisterStep}}var _hoisted_1$268={class:`wizard-container`},_hoisted_2$221={class:`wizard-content`},_hoisted_3$195={class:`wizard-step-content`},_hoisted_4$167={key:0,class:`wizard-validation`},_hoisted_5$144={class:`validation-message`},_hoisted_6$124={class:`wizard-navigation`},_hoisted_7$111={key:2,class:`switch-buttons`};const wizardProps={wizardOptions:{type:Object,default:()=>({})},title:String,preheadings:Array,showDivider:{type:Boolean,default:!0},showProgress:{type:Boolean,default:!0},showBackButton:{type:Boolean,default:!0},allowSkip:{type:Boolean,default:!1},backButtonText:{type:String,default:`ui.common.back`},nextButtonText:{type:String,default:`ui.common.next`},finishButtonText:{type:String,default:`ui.common.finish`},skipButtonText:{type:String,default:`ui.common.skip`},validationMessage:String};var _sfc_main$300={__name:`Wizard`,props:mergeModels(wizardProps,{modelValue:{default:()=>({})},modelModifiers:{}}),emits:mergeModels([`step-change`,`step-complete`,`wizard-finish`,`validation-error`],[`update:modelValue`]),setup(__props,{expose:__expose,emit:__emit}){let props=__props,modelValue=useModel(__props,`modelValue`),emit$1=__emit,{currentStepIndex,currentStep,isFirstStep,isLastStep,canGoNext,canGoBack,canFinish,progress,stepProgress,nextStep:wizardNextStep,previousStep:wizardPreviousStep,skip:wizardSkip,steps,registerStep:originalRegisterStep}=useWizard({...props.wizardOptions,allowSkip:props.allowSkip}),instance$1=getCurrentInstance(),hasCentralizedModel=computed(()=>!!(instance$1&&instance$1.attrs&&`onUpdate:modelValue`in instance$1.attrs));provide(`currentWizardStep`,currentStep),provide(`wizardNext`,()=>nextStep()),provide(`wizardSteps`,steps),provide(`registerWizardStep`,stepConfig=>hasCentralizedModel.value?originalRegisterStep({...stepConfig,get modelValue(){return modelValue.value?.[stepConfig.id]||{}},updateModelValue:newValue=>{modelValue.value={...modelValue.value,[stepConfig.id]:newValue}}}):originalRegisterStep(stepConfig)),provide(`unregisterWizardStep`,stepId=>{if(hasCentralizedModel.value&&props.modelValue[stepId]){let updatedData={...props.modelValue};delete updatedData[stepId],emit$1(`update:modelValue`,updatedData)}});let currentStepChoices=computed(()=>currentStep.value?.choices||[]),getChoiceButtonClass=(choiceValue,selectedChoice)=>selectedChoice?selectedChoice===choiceValue?`answered-selected`:`answered-not-selected`:`unanswered`,handleChoiceClick=choice=>{currentStep.value?.updateModelValue&&(currentStep.value.updateModelValue({...currentStep.value.modelValue,choice:choice.value}),nextTick(()=>!currentStep.value?.advanceDisabled&&nextStep()))},nextStep=()=>{let stepId=currentStep.value?.id,currentData=currentStep.value?.modelValue||{};emit$1(`step-complete`,{stepId,stepIndex:currentStepIndex.value,step:currentStep.value,data:currentData}),wizardNextStep()&&emit$1(`step-change`,{from:currentStepIndex.value-1,to:currentStepIndex.value,step:currentStep.value})},previousStep=()=>{let prevIndex=currentStepIndex.value;wizardPreviousStep()&&emit$1(`step-change`,{from:prevIndex,to:currentStepIndex.value,step:currentStep.value})},skip=()=>{wizardSkip()&&emit$1(`step-complete`,{stepId:currentStep.value?.id,stepIndex:currentStepIndex.value-1,skipped:!0,data:currentStep.value?.modelValue||{}})},handleFinish=()=>{let allStepData={};steps.value.forEach(step=>{step.modelValue&&Object.keys(step.modelValue).length>0&&(allStepData[step.id]=step.modelValue)}),canFinish.value?emit$1(`wizard-finish`,{success:!0,data:allStepData,completedSteps:Array.from({length:steps.value.length},(_,i)=>i)}):emit$1(`validation-error`,{step:currentStep.value,message:`Cannot finish wizard - validation failed`})};return __expose({currentStepIndex,currentStep,progress,stepProgress,nextStep,previousStep,finish:handleFinish,skip,steps}),(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$268,[createBaseVNode(`div`,_hoisted_2$221,[_ctx.title?(openBlock(),createBlock(unref(bngScreenHeading_default),{key:0,preheadings:_ctx.preheadings,"show-divider":_ctx.showDivider},{default:withCtx(()=>[createTextVNode(toDisplayString(_ctx.$tt(_ctx.title)),1)]),_:1},8,[`preheadings`,`show-divider`])):createCommentVNode(``,!0),_ctx.showProgress?(openBlock(),createBlock(unref(bngCard_default),{key:1,class:`wizard-progress-card`},{default:withCtx(()=>[createVNode(ProgressSteps_default,{steps:unref(stepProgress),"current-step":unref(currentStepIndex)},null,8,[`steps`,`current-step`])]),_:1})):createCommentVNode(``,!0),createVNode(unref(bngCard_default),{class:`wizard-main-card`},{buttons:withCtx(()=>[createBaseVNode(`div`,_hoisted_6$124,[_ctx.showBackButton&&!unref(isFirstStep)?(openBlock(),createBlock(unref(bngButton_default),{key:0,disabled:!unref(canGoBack),accent:unref(ACCENTS).secondary,onClick:previousStep},{default:withCtx(()=>[createTextVNode(toDisplayString(_ctx.$tt(_ctx.backButtonText)),1)]),_:1},8,[`disabled`,`accent`])):createCommentVNode(``,!0),_ctx.allowSkip&&!unref(isLastStep)&&unref(currentStep)?.type!==`choice`?(openBlock(),createBlock(unref(bngButton_default),{key:1,accent:unref(ACCENTS).secondary,onClick:skip},{default:withCtx(()=>[createTextVNode(toDisplayString(_ctx.$tt(_ctx.skipButtonText)),1)]),_:1},8,[`accent`])):createCommentVNode(``,!0),_cache[0]||=createBaseVNode(`div`,{class:`spacer`},null,-1),unref(currentStep)?.type===`choice`?(openBlock(),createElementBlock(`div`,_hoisted_7$111,[(openBlock(!0),createElementBlock(Fragment,null,renderList(currentStepChoices.value,choice=>(openBlock(),createBlock(unref(bngButton_default),{key:choice.value,class:normalizeClass(getChoiceButtonClass(choice.value,unref(currentStep)?.modelValue?.choice||null)),accent:unref(ACCENTS).custom,icon:unref(currentStep)?.modelValue?.choice===choice.value?unref(icons).checkmark:null,disabled:unref(currentStep)?.advanceDisabled,onClick:$event=>handleChoiceClick(choice)},{default:withCtx(()=>[createTextVNode(toDisplayString(_ctx.$tt(choice.label)),1)]),_:2},1032,[`class`,`accent`,`icon`,`disabled`,`onClick`]))),128))])):createCommentVNode(``,!0),!unref(isLastStep)&&unref(currentStep)?.type!==`choice`?(openBlock(),createBlock(unref(bngButton_default),{key:3,disabled:!unref(canGoNext),accent:unref(ACCENTS).primary,onClick:nextStep},{default:withCtx(()=>[createTextVNode(toDisplayString(_ctx.$tt(_ctx.nextButtonText)),1)]),_:1},8,[`disabled`,`accent`])):unref(isLastStep)?(openBlock(),createBlock(unref(bngButton_default),{key:4,disabled:!unref(canFinish),accent:unref(ACCENTS).primary,onClick:handleFinish},{default:withCtx(()=>[createTextVNode(toDisplayString(_ctx.$tt(_ctx.finishButtonText)),1)]),_:1},8,[`disabled`,`accent`])):createCommentVNode(``,!0)])]),default:withCtx(()=>[unref(currentStep)?.title?(openBlock(),createBlock(unref(bngCardHeading_default),{key:0,type:`ribbon`},{default:withCtx(()=>[renderSlot(_ctx.$slots,`step-title`,{step:unref(currentStep)},()=>[createTextVNode(toDisplayString(_ctx.$tt(unref(currentStep).title)),1)],!0)]),_:3})):createCommentVNode(``,!0),withDirectives((openBlock(),createElementBlock(`div`,_hoisted_3$195,[renderSlot(_ctx.$slots,`step`,{step:unref(currentStep),stepData:unref(currentStep)?.modelValue,updateStepData:unref(currentStep)?.updateModelValue,stepIndex:unref(currentStepIndex),isFirst:unref(isFirstStep),isLast:unref(isLastStep)},()=>[renderSlot(_ctx.$slots,`default`,{},void 0,!0)],!0),_ctx.validationMessage?(openBlock(),createElementBlock(`div`,_hoisted_4$167,[createBaseVNode(`div`,_hoisted_5$144,toDisplayString(_ctx.validationMessage),1)])):createCommentVNode(``,!0)])),[[unref(BngUiNavScroll_default)]])]),_:3})])]))}},Wizard_default=__plugin_vue_export_helper_default(_sfc_main$300,[[`__scopeId`,`data-v-69c7b9c4`]]),_sfc_main$299={__name:`WizardView`,props:mergeModels({...wizardProps},{modelValue:{},modelModifiers:{}}),emits:mergeModels([`step-change`,`step-complete`,`wizard-finish`,`validation-error`],[`update:modelValue`]),setup(__props,{expose:__expose}){let props=__props,slots=useSlots(),wizardRef=ref(),wizardModel=useModel(__props,`modelValue`);return __expose({wizard:wizardRef,get currentStepIndex(){return wizardRef.value?.currentStepIndex},get currentStep(){return wizardRef.value?.currentStep},get progress(){return wizardRef.value?.progress},get stepProgress(){return wizardRef.value?.stepProgress},get steps(){return wizardRef.value?.steps},nextStep:()=>wizardRef.value?.nextStep(),previousStep:()=>wizardRef.value?.previousStep(),finish:()=>wizardRef.value?.finish(),skip:()=>wizardRef.value?.skip()}),(_ctx,_cache)=>withDirectives((openBlock(),createBlock(unref(layoutSingle_default),{class:`layout-content-full content-center layout-paddings wizard-view`},{default:withCtx(()=>[createVNode(Wizard_default,mergeProps({ref_key:`wizardRef`,ref:wizardRef},props,{modelValue:wizardModel.value,"onUpdate:modelValue":_cache[0]||=$event=>wizardModel.value=$event,onStepChange:_cache[1]||=$event=>_ctx.$emit(`step-change`,$event),onStepComplete:_cache[2]||=$event=>_ctx.$emit(`step-complete`,$event),onWizardFinish:_cache[3]||=$event=>_ctx.$emit(`wizard-finish`,$event),onValidationError:_cache[4]||=$event=>_ctx.$emit(`validation-error`,$event)}),createSlots({_:2},[renderList(unref(slots),(slot,name)=>({name,fn:withCtx(props$1=>[renderSlot(_ctx.$slots,name,normalizeProps(guardReactiveProps(props$1)),void 0,!0)])}))]),1040,[`modelValue`])]),_:3})),[[unref(BngBlur_default)]])}},WizardView_default=__plugin_vue_export_helper_default(_sfc_main$299,[[`__scopeId`,`data-v-e47281c4`]]),_hoisted_1$267={key:0,class:`wizard-summary`},_sfc_main$298={__name:`WizardSummary`,props:{custom:{type:Array,default:()=>[],validator:items$2=>items$2.every(item=>item.label&&item.value!==void 0)},replace:{type:Boolean,default:!1}},setup(__props){let props=__props,steps=inject(`wizardSteps`,ref([])),summaryItems=computed(()=>{let customItems=props.custom.map(item=>({stepId:uniqueId(),title:item.label,selectedLabel:item.value,hasSelection:!item.disabled}));if(props.replace)return customItems;let stepsList=steps.value||[],automaticItems=[];return Array.isArray(stepsList)&&(automaticItems=stepsList.filter(step=>step.type===`choice`&&step.choices&&step.choices.length>0).map(step=>{let selectedChoice=step.modelValue?.choice,choiceOption=step.choices.find(choice=>choice.value===selectedChoice);return{stepId:step.id,title:step.title,selectedLabel:choiceOption?.label||null,hasSelection:!!selectedChoice}}).filter(item=>item.hasSelection)),[...automaticItems,...customItems]});return(_ctx,_cache)=>summaryItems.value.length>0?(openBlock(),createElementBlock(`div`,_hoisted_1$267,[(openBlock(!0),createElementBlock(Fragment,null,renderList(summaryItems.value,item=>(openBlock(),createElementBlock(`div`,{key:item.stepId,class:`summary-item`},[createBaseVNode(`strong`,null,toDisplayString(_ctx.$tt(item.title))+`:`,1),createBaseVNode(`span`,{class:normalizeClass({enabled:item.hasSelection,disabled:!item.hasSelection})},toDisplayString(_ctx.$tt(item.selectedLabel||`ui.common.unknown`)),3)]))),128))])):createCommentVNode(``,!0)}},WizardSummary_default=__plugin_vue_export_helper_default(_sfc_main$298,[[`__scopeId`,`data-v-69c45791`]]),_hoisted_1$266={key:0,class:`wizard-step-container`},_hoisted_2$220={key:0,class:`step-description`},_hoisted_3$194=[`innerHTML`],_hoisted_4$166={class:`step-content`},_hoisted_5$143={key:0,class:`wizard-choice-step`},_hoisted_6$123={key:1,class:`wizard-form-step`},_hoisted_7$110={key:2,class:`wizard-confirmation-step`},_hoisted_8$93={key:3,class:`wizard-custom-step`},_hoisted_9$83={class:`custom-placeholder`},_sfc_main$297={__name:`WizardStep`,props:mergeModels({id:{type:String,required:!0},title:String,description:String,type:{type:String,default:`custom`,validator:value=>[`choice`,`form`,`confirmation`,`custom`].includes(value)},autoSkip:{type:Boolean,default:!0},advanceDisabled:{type:Boolean,default:!1},advanceDelay:{type:Number,default:300},required:{type:Boolean,default:!0},validator:{type:Function,default:null},enabledWhen:{type:Array,default:()=>[]},choices:{type:Array,default:()=>[]},component:{type:[String,Object],default:null},componentProps:{type:Object,default:()=>({})}},{modelValue:{default:()=>({})},modelModifiers:{}}),emits:[`update:modelValue`],setup(__props,{expose:__expose}){let props=__props,modelValue=useModel(__props,`modelValue`),registerStep=inject(`registerWizardStep`,null),unregisterStep=inject(`unregisterWizardStep`,null),currentStep=inject(`currentWizardStep`,null),slots=useSlots(),stepContext={stepId:props.id,stepType:props.type};provide(`wizardStepContext`,stepContext),__expose({stepId:props.id,stepContext});let isCurrentStep=computed(()=>currentStep?.value?.id===props.id);return onMounted(()=>{registerStep?.({id:props.id,title:props.title,description:props.description,type:props.type,autoSkip:props.autoSkip,get advanceDisabled(){return props.advanceDisabled},advanceDelay:props.advanceDelay,required:props.required,enabledWhen:props.enabledWhen,validate:props.validator,component:props.component,componentProps:props.componentProps,choices:props.choices,get modelValue(){return modelValue.value},updateModelValue:value=>{modelValue.value=value},hasDefaultSlot:!!slots.default,hasDescriptionSlot:!!slots.description})}),onUnmounted(()=>{unregisterStep?.(props.id)}),(_ctx,_cache)=>isCurrentStep.value?(openBlock(),createElementBlock(`div`,_hoisted_1$266,[__props.description||_ctx.$slots.description?(openBlock(),createElementBlock(`div`,_hoisted_2$220,[renderSlot(_ctx.$slots,`description`,{},()=>[__props.description?(openBlock(),createElementBlock(`div`,{key:0,innerHTML:__props.description},null,8,_hoisted_3$194)):createCommentVNode(``,!0)],!0)])):createCommentVNode(``,!0),createBaseVNode(`div`,_hoisted_4$166,[__props.type===`choice`?(openBlock(),createElementBlock(`div`,_hoisted_5$143,[renderSlot(_ctx.$slots,`default`,{},void 0,!0)])):__props.type===`form`?(openBlock(),createElementBlock(`div`,_hoisted_6$123,[renderSlot(_ctx.$slots,`default`,{},()=>[_cache[0]||=createBaseVNode(`div`,{class:`form-placeholder`},[createBaseVNode(`p`,null,`Add your form content here using BngInput, BngDropdown, etc.`),createBaseVNode(`p`,{class:`form-note`},`Use v-model bindings to connect to step data.`)],-1)],!0)])):__props.type===`confirmation`?(openBlock(),createElementBlock(`div`,_hoisted_7$110,[renderSlot(_ctx.$slots,`default`,{},()=>[createVNode(WizardSummary_default)],!0)])):(openBlock(),createElementBlock(`div`,_hoisted_8$93,[renderSlot(_ctx.$slots,`default`,{},()=>[createBaseVNode(`div`,_hoisted_9$83,[createBaseVNode(`p`,null,`Custom step content for: `+toDisplayString(__props.title),1),_cache[1]||=createBaseVNode(`p`,{class:`custom-note`},`Add your custom content in the WizardStep default slot`,-1)])],!0)]))])])):createCommentVNode(``,!0)}},WizardStep_default=__plugin_vue_export_helper_default(_sfc_main$297,[[`__scopeId`,`data-v-ede4abc3`]]),_hoisted_1$265={class:`description`},_hoisted_2$219={class:`image-section`},_hoisted_3$193={class:`image-row`},_hoisted_4$165=[`src`],_hoisted_5$142=[`src`],_sfc_main$296={__name:`ButtonLayoutView`,setup(__props){let settings$1=useSettings(),handleFinish=async()=>{await settings$1.apply({showedInputLayoutPopupV37:!0}),window.bngVue.gotoGameState(`menu.mainmenu`)},goToControls=async()=>{await settings$1.apply({showedInputLayoutPopupV37:!0}),window.bngVue.gotoGameState(`menu.options.controls.bindings`)};return onMounted(async()=>{await settings$1.waitForData()}),(_ctx,_cache)=>(openBlock(),createBlock(unref(WizardView_default),{title:`Input Changes`,class:`wizard-view`,"show-progress":!1,"finish-button-text":`ui.common.continue`,onWizardFinish:handleFinish},{default:withCtx(()=>[createVNode(unref(WizardStep_default),{id:`buttonLayout`,title:`Extended Modifier Buttons`,type:`confirmation`},{default:withCtx(()=>[withDirectives((openBlock(),createElementBlock(`div`,_hoisted_1$265,[_cache[1]||=createBaseVNode(`p`,null,` We updated the default button layout for Xbox and Playstation controllers using modifier buttons. Below you see the new default layout. `,-1),_cache[2]||=createBaseVNode(`p`,null,[createBaseVNode(`strong`,{class:`warning-text`},`If you made any changes to the default layout on Xbox or Playstation, we suggest you review your current layout and then either edit it or reset to the default if needed.`)],-1),createVNode(unref(bngButton_default),{accent:unref(ACCENTS).primary,onClick:goToControls},{default:withCtx(()=>[..._cache[0]||=[createTextVNode(` Go to Controls `,-1)]]),_:1},8,[`accent`])])),[[unref(BngUiNavScroll_default)]]),createBaseVNode(`div`,_hoisted_2$219,[_cache[3]||=createBaseVNode(`h4`,null,`New Button Layout`,-1),createBaseVNode(`div`,_hoisted_3$193,[createBaseVNode(`img`,{src:unref(getAssetURL)(`images/buttonLayout1.jpg`),alt:`Button Layout`,class:`button-layout-image`},null,8,_hoisted_4$165),createBaseVNode(`img`,{src:unref(getAssetURL)(`images/buttonLayout2.jpg`),alt:`Button Layout`,class:`button-layout-image`},null,8,_hoisted_5$142)])])]),_:1})]),_:1}))}},ButtonLayoutView_default=__plugin_vue_export_helper_default(_sfc_main$296,[[`__scopeId`,`data-v-ff98d0e0`]]),routes_default$2=[{path:`/buttonLayout`,name:`buttonLayout`,component:ButtonLayoutView_default,meta:{infoBar:{visible:!0,showSysInfo:!0},uiApps:{shown:!1}}}],_hoisted_1$264={class:`left`},_hoisted_2$218={class:`branch-icon-assembly`},_hoisted_3$192=[`innerHTML`],_hoisted_4$164=[`innerHTML`],_sfc_main$295={__name:`BranchSkillProgressBar`,props:{skill:Object,mode:{type:String,default:`long`,validator:value=>[`long`,`short`,`simple`,`with-value-label`].includes(value)},showLevel:{type:Boolean,default:!1},showLockedIcon:{type:Boolean,default:!1},isMainProgress:{type:Boolean,default:!1}},setup(__props){let props=__props,headerLeft=computed(()=>props.skill.name),headerRightLevelOrStars=computed(()=>props.skill.isInDevelopment?``:props.skill.unlocked?(props.showLevel&&props.skill.unlocked,props.skill.showProgressAsStars?$translate.contextTranslate({txt:`ui.career.slashStars`,context:{cur:props.skill.value,max:props.skill.max}}):props.skill.levelLabel?props.skill.levelLabel:props.skill.level?$translate.contextTranslate({txt:`ui.career.lvlLabel`,context:{lvl:props.skill.level}}):`Level ${props.skill.level}`):$translate.contextTranslate(`ui.career.locked`)),value=computed(()=>props.skill.max===-1?1:props.skill.value-props.skill.min),max$1=computed(()=>props.skill.max===-1?1:props.skill.max-props.skill.min),valueLabelFormat=computed(()=>{if(props.skill.isInDevelopment)return $translate.contextTranslate(`ui.career.inDevelopment`);if(!props.skill.unlocked)return $translate.contextTranslate(`ui.career.locked`);if(props.mode===`simple`)return props.skill.showProgressAsStars?$translate.contextTranslate({txt:`ui.career.slashStars`,context:{cur:value.value,max:max$1.value}}):$translate.contextTranslate({txt:`ui.career.lvlLabel`,context:{lvl:props.skill.level}});let unit=props.skill.showProgressAsStars?`Stars`:`XP`;return props.skill.max===-1?$translate.contextTranslate({txt:`ui.career.just`+unit,context:{cur:value.value}}):$translate.contextTranslate({txt:`ui.career.slashXP`,context:{cur:value.value,max:max$1.value}})}),skillIcon=computed(()=>props.skill.isInDevelopment?icons.roadblockL:props.skill.unlocked?props.skill.icon||`info`:`lockClosed`),belowValueLabelFormat=computed(()=>{if(!props.skill.unlocked&&props.skill.lockedReason)return $translate.contextTranslate(props.skill.lockedReason?.label||`ui.career.locked`);if(props.skill.isInDevelopment)return $translate.contextTranslate(`ui.career.inDevelopment`);if(props.skill.isMaxLevel)return`​`;if(!props.skill.showProgressAsStars)return $translate.contextTranslate({txt:`ui.career.justXP`,context:{cur:props.skill.value}})}),branchBackgroundStyle=computed(()=>{let color=props.skill.accentColor;return color?color.startsWith(`--`)?{"background-color":`var(${color})`}:color.startsWith(`#`)?{"background-color":color}:{"background-color":`rgb(${color})`}:{"background-color":`#555555`}});return(_ctx,_cache)=>__props.mode===`simple`?(openBlock(),createElementBlock(`div`,{key:0,class:normalizeClass([`simple-progress`,{"is-locked":!props.skill.unlocked}])},[createBaseVNode(`div`,_hoisted_1$264,[createBaseVNode(`div`,_hoisted_2$218,[!__props.skill.isSkill&&!__props.skill.isBranch?(openBlock(),createElementBlock(`div`,{key:0,class:`branch-background`,style:normalizeStyle(branchBackgroundStyle.value)},null,4)):createCommentVNode(``,!0),createVNode(unref(bngIcon_default),{type:skillIcon.value,class:`assembly-icon`},null,8,[`type`])]),createTextVNode(` `+toDisplayString(_ctx.$ctx_t(headerLeft.value)),1)]),createBaseVNode(`div`,{class:`right`,innerHTML:valueLabelFormat.value},null,8,_hoisted_3$192)],2)):(openBlock(),createElementBlock(`div`,{key:1,class:normalizeClass([`flex-column`,{"is-locked":!props.skill.unlocked}])},[createVNode(unref(bngProgressBar_default),{class:normalizeClass([`stat-progress-bar`,{short:__props.mode===`short`,isMainProgress:__props.isMainProgress}]),headerLeft:_ctx.$ctx_t(headerLeft.value),headerRight:_ctx.$ctx_t(headerRightLevelOrStars.value),value:value.value,max:max$1.value+.001,showValueLabel:!0,valueLabelFormat:``,valueColor:`#eeeeee`},null,8,[`class`,`headerLeft`,`headerRight`,`value`,`max`]),!props.skill.unlocked&&__props.mode===`with-value-label`&&props.showLockedIcon?(openBlock(),createElementBlock(Fragment,{key:0},[],64)):createCommentVNode(``,!0),__props.mode===`with-value-label`?(openBlock(),createElementBlock(`div`,{key:1,class:`below-progress-bar`,innerHTML:belowValueLabelFormat.value},null,8,_hoisted_4$164)):createCommentVNode(``,!0)],2))}},BranchSkillProgressBar_default=__plugin_vue_export_helper_default(_sfc_main$295,[[`__scopeId`,`data-v-2f641a65`]]);function hexToRgb(hex){hex=hex.replace(/^#/,``);let bigint=parseInt(hex,16);return`${bigint>>16&255}, ${bigint>>8&255}, ${bigint&255}`}function getBranchColorStyle({color,accentColor}){let style={};color&&(color.startsWith(`#`)?style[`--branch-color`]=hexToRgb(color):color.startsWith(`var(--`)&&(style[`--branch-color`]=color));let accent=accentColor||color;return accent&&(accent.startsWith(`#`)?style[`--branch-accent-color`]=hexToRgb(accent):accent.startsWith(`var(--`)&&(style[`--branch-accent-color`]=accent)),style}function getIconBackgroundStyle(color){return color?color.startsWith(`--`)?{"background-color":`var(${color})`}:color.startsWith(`#`)?{"background-color":color}:{"background-color":`rgb(${color})`}:{"background-color":`#555555`}}var _hoisted_1$263={class:`branch-details`},_hoisted_2$217={class:`backdrop`},_hoisted_3$191={class:`skill-levels-wrapper`},_hoisted_4$163={key:0,class:`branch-name-container`},_hoisted_5$141={key:2,class:`branch-footer`},_hoisted_6$122={key:0,class:`branch-description`},_hoisted_7$109={key:0,class:`branch-description`},_hoisted_8$92={class:`branch-footer-content`},_hoisted_9$82={class:`certification-text`},_hoisted_10$72={class:`status`},_hoisted_11$65={class:`unlock-info-row`},_hoisted_12$53={class:`icon-box`},_hoisted_13$46={class:`certification-text`},_sfc_main$294={__name:`BranchSkillCard`,props:{branchKey:String,displayMode:{type:String,default:`card`}},emits:[`openBranchPage`],setup(__props,{emit:__emit}){let props=__props,emit$1=__emit,branchData=ref();computed(()=>branchData.value&&`url(${getAssetURL(branchData.value.icon)})`);let branchColor=computed(()=>{let color=branchData.value&&branchData.value.color;return color?color.startsWith(`#`)?hexToRgb(color):color.startsWith(`var(--`)?`${color}`:`transparent`:``}),branchAccentColor=computed(()=>{let color=branchData.value&&(branchData.value.accentColor||branchData.value.color);return color?color.startsWith(`#`)?hexToRgb(color):color.startsWith(`var(--`)?`${color}`:`transparent`:``}),branchIconType=computed(()=>branchData.value&&branchData.value.isInDevelopment?icons.roadblockL:branchData.value&&branchData.value.unlocked?icons[branchData.value.glyphIcon]:icons.lockClosed),isHalf=computed(()=>{if(!branchData.value)return!1;let hasSkills=branchData.value.skills&&branchData.value.skills.length>0,hasDescription=branchData.value.shortDescription;return!hasSkills&&!hasDescription}),safeArray=arr=>Array.isArray(arr)?arr:[],openBranchPage=branchKey=>emit$1(`openBranchPage`,branchKey);function setup$3(data){branchData.value=data,branchData.value.skills=safeArray(data.skills)}let formatColor=color=>color?color.startsWith(`#`)?hexToRgb(color):color.startsWith(`var(--`)?`${color}`:`rgb(255, 255, 255)`:``;return onMounted(async()=>{setup$3(await Lua_default.career_modules_branches_landing.getBranchSkillCardData(props.branchKey))}),(_ctx,_cache)=>branchData.value?(openBlock(),createBlock(unref(bngCard_default),{key:0,class:normalizeClass([`branch-skill-card`,{"row-mode":__props.displayMode===`row`,locked:!branchData.value.unlocked,half:isHalf.value}]),onClick:_cache[0]||=$event=>openBranchPage(__props.branchKey),style:normalizeStyle({"--branch-color":branchColor.value,"--branch-accent-color":branchAccentColor.value})},{default:withCtx(()=>[createBaseVNode(`div`,_hoisted_1$263,[_cache[2]||=createBaseVNode(`div`,{class:`indicator left`},null,-1),_cache[3]||=createBaseVNode(`div`,{class:`indicator right`},null,-1),branchData.value.isDomain?createCommentVNode(``,!0):(openBlock(),createElementBlock(`div`,{key:0,class:normalizeClass([`branch-progress`,{"in-development":branchData.value.isInDevelopment}])},[branchData.value.isDomain?createCommentVNode(``,!0):(openBlock(),createElementBlock(`div`,{key:0,class:normalizeClass([`badge`,{"row-badge":__props.displayMode===`row`}])},[createBaseVNode(`div`,_hoisted_2$217,toDisplayString(branchData.value.value.color),1),createVNode(unref(bngIcon_default),{class:`icon-branch`,type:branchIconType.value},null,8,[`type`])],2))],2)),branchData.value.isDomain?(openBlock(),createBlock(unref(aspectRatio_default),{key:1,"external-image":branchData.value.cover,ratio:`16:9`,class:`image-container aspect-ratio`},null,8,[`external-image`])):createCommentVNode(``,!0),createBaseVNode(`div`,_hoisted_3$191,[__props.displayMode===`row`?(openBlock(),createElementBlock(`div`,_hoisted_4$163,[branchData.value?(openBlock(),createBlock(BranchSkillProgressBar_default,{key:0,class:`main-stat-progress-bar`,skill:branchData.value,showLevel:!0,mode:(branchData.value.isInDevelopment&&isHalf.value,``)},null,8,[`skill`,`mode`])):createCommentVNode(``,!0)])):createCommentVNode(``,!0)]),isHalf.value?createCommentVNode(``,!0):(openBlock(),createElementBlock(`div`,_hoisted_5$141,[branchData.value.isInDevelopment?(openBlock(),createElementBlock(`div`,_hoisted_6$122,toDisplayString(_ctx.$ctx_t(`ui.career.inDevelopment`)),1)):(openBlock(),createElementBlock(Fragment,{key:1},[branchData.value.shortDescription?(openBlock(),createElementBlock(`div`,_hoisted_7$109,toDisplayString(_ctx.$ctx_t(branchData.value.shortDescription)),1)):createCommentVNode(``,!0),createBaseVNode(`div`,_hoisted_8$92,[branchData.value.skills?(openBlock(!0),createElementBlock(Fragment,{key:0},renderList(branchData.value.skills,skill=>(openBlock(),createElementBlock(`div`,null,[branchData.value?(openBlock(),createBlock(BranchSkillProgressBar_default,{key:0,skill,mode:`simple`},null,8,[`skill`])):createCommentVNode(``,!0)]))),256)):createCommentVNode(``,!0),(openBlock(!0),createElementBlock(Fragment,null,renderList(branchData.value.certifications,certification=>(openBlock(),createElementBlock(`div`,{class:normalizeClass([`certification-container`,certification.status])},[createVNode(unref(bngIcon_default),{type:unref(icons).badgeRoundStar,style:normalizeStyle({color:certification.status===`completed`?`white`:certification.status===`available`?`rgba(255, 255, 255, 0.6)`:`rgba(255, 255, 255, 0.5)`})},null,8,[`type`,`style`]),createBaseVNode(`div`,_hoisted_9$82,[createTextVNode(toDisplayString(_ctx.$ctx_t(`ui.career.certification.name`))+` `,1),createBaseVNode(`span`,_hoisted_10$72,toDisplayString(_ctx.$ctx_t(certification.statusLabel)),1)])],2))),256)),branchData.value.unlockInfos?(openBlock(),createElementBlock(Fragment,{key:1},[_cache[1]||=createBaseVNode(`div`,{class:`unlock-info-title`},`Required Certifications:`,-1),createBaseVNode(`div`,_hoisted_11$65,[(openBlock(!0),createElementBlock(Fragment,null,renderList(branchData.value.unlockInfos,unlockInfo=>(openBlock(),createElementBlock(`div`,{class:normalizeClass([`unlock-info-item`,unlockInfo.status]),style:normalizeStyle({"--unlock-color":formatColor(unlockInfo.color?unlockInfo.color:`var(--bng-cool-gray-500-rgb)`)})},[createBaseVNode(`div`,_hoisted_12$53,[createVNode(unref(bngIcon_default),{type:unref(icons).badgeRoundStar,class:`certification-icon`},null,8,[`type`])]),createBaseVNode(`div`,_hoisted_13$46,toDisplayString(_ctx.$ctx_t(unlockInfo.label)),1)],6))),256))])],64)):createCommentVNode(``,!0)])],64))]))])]),_:1},8,[`class`,`style`])):createCommentVNode(``,!0)}},BranchSkillCard_default=__plugin_vue_export_helper_default(_sfc_main$294,[[`__scopeId`,`data-v-4321db2f`]]),_hoisted_1$262={class:`condensed`},_hoisted_2$216={key:3,class:`dev-icon-container`},_hoisted_3$190={class:`main-info`},_hoisted_4$162={key:1,class:`stars`},_sfc_main$293={__name:`MissionCard`,props:{mission:Object,isSkeleton:Boolean,showStartableIcons:Boolean},emits:[`clicked`],setup(__props,{emit:__emit}){let props=__props,emit$1=__emit,clicked=()=>emit$1(`clicked`,props.mission),backgroundImageStyle=computed(()=>({backgroundImage:`url(${props.mission.thumbnail})`,maskImage:`linear-gradient(to left, rgba(0, 0, 0, ${props.mission.startable?.75:.2}) 50%, rgba(0, 0, 0, 0.1) 100%)`,filter:props.mission.startable?`none`:`grayscale(100%)`})),iconType$1=computed(()=>props.isSkeleton?icons.medal:icons[props.mission.icon]||icons.medal),iconColor=computed(()=>props.isSkeleton||!props.mission.startable?`var(--bng-cool-gray-600)`:`#fff`),showStartableIcons=computed(()=>!props.isSkeleton&&props.showStartableIcons);return(_ctx,_cache)=>(openBlock(),createBlock(unref(bngCard_default),{"bng-nav-item":``,onClick:clicked,class:normalizeClass({"card-wrapper":!0,"click-startable":__props.mission&&__props.mission.startable})},{default:withCtx(()=>[createBaseVNode(`div`,_hoisted_1$262,[__props.isSkeleton?createCommentVNode(``,!0):(openBlock(),createBlock(unref(aspectRatio_default),{key:0,class:`image`,style:normalizeStyle(backgroundImageStyle.value)},null,8,[`style`])),!__props.isSkeleton&&!__props.mission.startable?(openBlock(),createBlock(unref(bngIcon_default),{key:1,class:`locked-icon`,type:unref(icons).lockClosed,color:iconColor.value},null,8,[`type`,`color`])):createCommentVNode(``,!0),!__props.isSkeleton&&showStartableIcons.value?(openBlock(),createElementBlock(Fragment,{key:2},[__props.mission.canStartFromProgressScreen&&__props.mission.startable?(openBlock(),createBlock(unref(bngIcon_default),{key:0,class:`locked-icon`,type:unref(icons).play,color:iconColor.value},null,8,[`type`,`color`])):createCommentVNode(``,!0),!__props.mission.canStartFromProgressScreen&&__props.mission.startable?(openBlock(),createBlock(unref(bngIcon_default),{key:1,class:`locked-icon`,type:unref(icons).mapPoint,color:iconColor.value},null,8,[`type`,`color`])):createCommentVNode(``,!0)],64)):createCommentVNode(``,!0),!__props.isSkeleton&&__props.mission.devMission?(openBlock(),createElementBlock(`div`,_hoisted_2$216,[createVNode(unref(bngIcon_default),{class:`dev-icon`,type:unref(icons).bug,color:`white`},null,8,[`type`]),_cache[0]||=createBaseVNode(`div`,{class:`dev-text`},` DEV MISSION `,-1)])):createCommentVNode(``,!0),_cache[1]||=createBaseVNode(`div`,{class:`highlight-marker`},null,-1),createVNode(unref(bngIcon_default),{class:`mission-icon`,type:iconType$1.value,color:iconColor.value},null,8,[`type`,`color`]),createVNode(unref(bngBinding_default),{class:`input-icon`,"ui-event":`ok`,controller:``}),createBaseVNode(`div`,_hoisted_3$190,[__props.isSkeleton?createCommentVNode(``,!0):(openBlock(),createElementBlock(`div`,{key:0,class:normalizeClass([`heading`,{locked:!__props.mission.startable}])},toDisplayString(_ctx.$tt(__props.mission.label)),3)),!__props.isSkeleton&&__props.mission.startable&&__props.mission.formattedProgress?(openBlock(),createElementBlock(`div`,_hoisted_4$162,[__props.mission.formattedProgress.unlockedStars&&__props.mission.formattedProgress.unlockedStars.totalDefaultStarCount?(openBlock(),createBlock(unref(bngMainStars_default),{key:0,individualStars:__props.mission.formattedProgress.unlockedStars.defaults,class:`main-stars`,scale:.6},null,8,[`individualStars`])):createCommentVNode(``,!0),__props.mission.formattedProgress.unlockedStars&&__props.mission.formattedProgress.unlockedStars.totalBonusStarCount>0?(openBlock(),createBlock(unref(bngMainStars_default),{key:1,individualStars:__props.mission.formattedProgress.unlockedStars.bonus,class:`bonus-stars`,scale:.6},null,8,[`individualStars`])):createCommentVNode(``,!0)])):createCommentVNode(``,!0)])])]),_:1},8,[`class`]))}},MissionCard_default=__plugin_vue_export_helper_default(_sfc_main$293,[[`__scopeId`,`data-v-52ea67db`]]),_hoisted_1$261={class:`rewards-pills-container`},_sfc_main$292={__name:`RewardPill`,props:{icon:String,attributeKey:String,rewardAmount:Number,highlight:Boolean,hideNumbers:Boolean,backgroundColor:{type:String,default:`rgba(var(--bng-cool-gray-900-rgb), 0.5)`}},setup(__props){return(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$261,[createBaseVNode(`div`,{class:`pill`,style:normalizeStyle({backgroundColor:__props.backgroundColor,filter:__props.highlight?`brightness(350%)`:``})},[createVNode(unref(bngUnit_default),mergeProps({[__props.icon?`beamXP`:__props.attributeKey]:__props.rewardAmount},{options:__props.hideNumbers?{formatter:x=>null}:null,iconType:__props.icon?unref(icons)[__props.icon]:null,formatter:__props.attributeKey}),null,16,[`options`,`iconType`,`formatter`])],4)]))}},RewardPill_default=__plugin_vue_export_helper_default(_sfc_main$292,[[`__scopeId`,`data-v-7719e2fc`]]),_hoisted_1$260={class:`rewards-pills-container`},_sfc_main$291={__name:`RewardsPills`,props:{rewards:Object,hideNumbers:Boolean,negativeBackground:{type:Boolean,default:!0}},setup(__props){return(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$260,[(openBlock(!0),createElementBlock(Fragment,null,renderList(__props.rewards,reward=>(openBlock(),createBlock(RewardPill_default,{icon:reward.icon,hideNumbers:__props.hideNumbers,attributeKey:reward.attributeKey,rewardAmount:reward.rewardAmount,highlight:reward.highlight,backgroundColor:__props.negativeBackground&&reward.rewardAmount<0?`rgba(var(--bng-add-red-700-rgb), 0.5)`:void 0},null,8,[`icon`,`hideNumbers`,`attributeKey`,`rewardAmount`,`highlight`,`backgroundColor`]))),256))]))}},RewardsPills_default=__plugin_vue_export_helper_default(_sfc_main$291,[[`__scopeId`,`data-v-40e5103d`]]),_hoisted_1$259={key:0,class:`animated-border claimable`},_hoisted_2$215={key:1,class:`complete`},_hoisted_3$189={key:0,class:`complete`},_hoisted_4$161={key:1,class:`complete-badge`},_hoisted_5$140={key:2,class:`step`},_hoisted_6$121={key:3,class:`step`},_hoisted_7$108={class:`content`},_hoisted_8$91={class:`heading`},_hoisted_9$81={key:0,class:`middle-content`},_hoisted_10$71={key:1,class:`middle-content`},_hoisted_11$64={key:3,class:`progress`},_sfc_main$290={__name:`MilestoneCard`,props:{milestone:Object,isCondensed:Boolean},emits:[`claim`],setup(__props,{emit:__emit}){let props=__props,emit$1=__emit,claimMilestone=()=>{console.log(`claimMilestone`,props.milestone),props.milestone.claimable&&(emit$1(`claim`,props.milestone),console.log(props.milestone))},milestoneColor=computed(()=>{let color=props.milestone.color;return color?color.startsWith(`#`)?hexToRgb$1(color):color.startsWith(`var(--`)?`${color}`:`transparent`:``});function hexToRgb$1(hex){return`${parseInt(hex.slice(1,3),16)}, ${parseInt(hex.slice(3,5),16)}, ${parseInt(hex.slice(5,7),16)}`}return(_ctx,_cache)=>withDirectives((openBlock(),createElementBlock(`div`,{"bng-nav-item":``,onClick:claimMilestone,class:`condensed`},[__props.milestone.claimable?(openBlock(),createElementBlock(`div`,_hoisted_1$259)):createCommentVNode(``,!0),__props.milestone.completed?(openBlock(),createElementBlock(`div`,_hoisted_2$215)):createCommentVNode(``,!0),createVNode(unref(aspectRatio_default),{class:`image`,style:normalizeStyle({backgroundColor:`rgb(`+milestoneColor.value+`)`}),ratio:`21:9`},{default:withCtx(()=>[__props.milestone.completed?(openBlock(),createElementBlock(`div`,_hoisted_3$189)):createCommentVNode(``,!0),__props.milestone.completed?(openBlock(),createElementBlock(`div`,_hoisted_4$161,[createVNode(unref(bngIcon_default),{class:`glyph small`,type:unref(icons).checkmark},null,8,[`type`])])):createCommentVNode(``,!0),createVNode(unref(bngIcon_default),{class:`glyph`,type:unref(icons)[__props.milestone.icon]},null,8,[`type`]),__props.milestone.step!==void 0&&__props.milestone.maxStep!==void 0?(openBlock(),createElementBlock(`div`,_hoisted_5$140,toDisplayString(__props.milestone.step)+`/`+toDisplayString(__props.milestone.maxStep),1)):createCommentVNode(``,!0),__props.milestone.step!==void 0&&__props.milestone.maxStep===void 0?(openBlock(),createElementBlock(`div`,_hoisted_6$121,toDisplayString(__props.milestone.step),1)):createCommentVNode(``,!0)]),_:1},8,[`style`]),createBaseVNode(`div`,_hoisted_7$108,[createBaseVNode(`div`,_hoisted_8$91,toDisplayString(_ctx.$ctx_t(__props.milestone.label)),1),__props.milestone.description?(openBlock(),createElementBlock(`div`,_hoisted_9$81,toDisplayString(_ctx.$ctx_t(__props.milestone.description)),1)):createCommentVNode(``,!0),__props.milestone.rewards?(openBlock(),createElementBlock(`div`,_hoisted_10$71,[createVNode(RewardsPills_default,{rewards:__props.milestone.rewards},null,8,[`rewards`])])):createCommentVNode(``,!0),__props.milestone.completed?(openBlock(),createBlock(unref(bngProgressBar_default),{key:2,value:1,max:1,min:0,valueLabelFormat:`Complete!`,class:`progress`})):createCommentVNode(``,!0),__props.milestone.progress?(openBlock(),createElementBlock(`div`,_hoisted_11$64,[(openBlock(!0),createElementBlock(Fragment,null,renderList(__props.milestone.progress,prog=>(openBlock(),createBlock(unref(bngProgressBar_default),{class:normalizeClass({claimProgressBar:__props.milestone.claimable}),value:prog.currValue,max:prog.maxValue,min:prog.minValue,valueLabelFormat:__props.milestone.claimable?`Click to claim!`:_ctx.$ctx_t(prog.label)},null,8,[`class`,`value`,`max`,`min`,`valueLabelFormat`]))),256))])):createCommentVNode(``,!0)])])),[[unref(BngOnUiNav_default),void 0,`ok`,{focusRequired:!0,asMouse:!0}]])}},MilestoneCard_default=__plugin_vue_export_helper_default(_sfc_main$290,[[`__scopeId`,`data-v-8fc3424a`]]),_hoisted_1$258={class:`progress-track`},_hoisted_2$214={key:0,class:`progress-fill`,style:{height:`100%`}},_hoisted_3$188={class:`header`},_hoisted_4$160={class:`name`},_hoisted_5$139={key:0,class:`stars`},_hoisted_6$120={key:1,class:`stars`},_hoisted_7$107={class:`info`},_hoisted_8$90={class:`unlock-condition`},_hoisted_9$80={class:`info`},_hoisted_10$70={class:`label`},_hoisted_11$63={class:`description`},_hoisted_12$52={key:0,class:`cards-container`},_hoisted_13$45={class:`basic-card locked coming-soon`},_hoisted_14$42={class:`label`},_hoisted_15$40={key:1,class:`right`},_sfc_main$289={__name:`LeagueRow`,props:{league:Object,leagueMissionClicked:Function,condensed:Boolean,vertical:Boolean,nowUnlocked:Boolean},setup(__props){let props=__props;function hexToRgb$1(hex){hex=hex.replace(/^#/,``);let bigint=parseInt(hex,16);return`${bigint>>16&255}, ${bigint>>8&255}, ${bigint&255}`}let leagueStyle=computed(()=>{if(!props.league.accentColor)return{};let style={};return props.league.accentColor.startsWith(`#`)?style[`--league-accent-color`]=hexToRgb$1(props.league.accentColor):props.league.accentColor.startsWith(`var(--`)&&(style[`--league-accent-color`]=props.league.accentColor),style});return(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,{class:normalizeClass([`league-row`,{locked:!__props.league._unlocked,condensed:__props.condensed}]),style:normalizeStyle(leagueStyle.value)},[createBaseVNode(`div`,_hoisted_1$258,[__props.league._unlocked?(openBlock(),createElementBlock(`div`,_hoisted_2$214)):createCommentVNode(``,!0)]),createBaseVNode(`div`,_hoisted_3$188,[createBaseVNode(`div`,_hoisted_4$160,[createVNode(unref(bngIcon_default),{type:unref(icons)[__props.league.icon],class:`skill-icon`,color:__props.league._unlocked?`white`:`gray`},null,8,[`type`,`color`]),createTextVNode(` `+toDisplayString(_ctx.$ctx_t(__props.league.name)),1)]),__props.nowUnlocked?(openBlock(),createElementBlock(`div`,_hoisted_6$120,[createVNode(unref(bngIcon_default),{type:unref(icons).lockOpened},null,8,[`type`])])):(openBlock(),createElementBlock(`div`,_hoisted_5$139,[__props.league._unlocked?(openBlock(),createBlock(unref(bngMainStars_default),{key:0,"unlocked-stars":__props.league.totalStarsObtained,"total-stars":__props.league.totalStarsAvailable,class:`main-stars`,scale:.8,reverse:``,numerical:``},null,8,[`unlocked-stars`,`total-stars`])):createCommentVNode(``,!0)]))]),createBaseVNode(`div`,{class:normalizeClass([`content-row`,{vertical:__props.vertical}])},[createBaseVNode(`div`,_hoisted_7$107,[(openBlock(!0),createElementBlock(Fragment,null,renderList(__props.league.unlock,cond=>(openBlock(),createElementBlock(Fragment,null,[cond.hidden?createCommentVNode(``,!0):(openBlock(),createBlock(unref(bngCard_default),{key:0},{default:withCtx(()=>[createBaseVNode(`div`,_hoisted_8$90,[createBaseVNode(`div`,_hoisted_9$80,[createVNode(unref(bngIcon_default),{class:`icon`,type:cond.met?unref(icons).lockOpened:unref(icons).lockClosed,color:cond.met?`white`:`gray`},null,8,[`type`,`color`]),createBaseVNode(`div`,_hoisted_10$70,toDisplayString(cond.label),1)]),cond.progress?(openBlock(),createBlock(unref(bngProgressBar_default),{key:0,value:cond.progress.cur,min:cond.progress.min,max:cond.progress.max,valueLabelFormat:``,class:`progress`},null,8,[`value`,`min`,`max`])):createCommentVNode(``,!0)])]),_:2},1024))],64))),256)),createBaseVNode(`div`,_hoisted_11$63,toDisplayString(_ctx.$ctx_t(__props.league.description)),1)]),__props.condensed?(openBlock(),createElementBlock(`div`,_hoisted_15$40,toDisplayString(__props.league.missions.length)+` Challenges `,1)):(openBlock(),createElementBlock(`div`,_hoisted_12$52,[(openBlock(!0),createElementBlock(Fragment,null,renderList(__props.league.missions,mission=>(openBlock(),createBlock(MissionCard_default,{class:`clickable-card`,key:mission.id,mission,onClicked:__props.leagueMissionClicked,showStartableIcons:!0},null,8,[`mission`,`onClicked`]))),128)),(openBlock(!0),createElementBlock(Fragment,null,renderList(__props.league.driftSpots,driftSpot=>(openBlock(),createBlock(MissionCard_default,{class:`clickable-card`,key:driftSpot.id,mission:driftSpot,onClicked:__props.leagueMissionClicked},null,8,[`mission`,`onClicked`]))),128)),__props.league.comingSoon?(openBlock(!0),createElementBlock(Fragment,{key:0},renderList(__props.league.comingSoon,info=>(openBlock(),createBlock(unref(bngCard_default),{class:`card-height`},{default:withCtx(()=>[createBaseVNode(`div`,_hoisted_13$45,[createVNode(unref(bngIcon_default),{class:`icon`,type:unref(icons)[info.icon],color:`gray`},null,8,[`type`]),createBaseVNode(`div`,_hoisted_14$42,toDisplayString(info.label),1)])]),_:2},1024))),256)):createCommentVNode(``,!0)]))],2)],6))}},LeagueRow_default=__plugin_vue_export_helper_default(_sfc_main$289,[[`__scopeId`,`data-v-f92a650f`]]),_hoisted_1$257={class:`label`},_hoisted_2$213={class:`text`},_hoisted_3$187={class:`description`},_sfc_main$288={__name:`TaskGoal`,props:{label:[String,Object],description:[String,Object],complete:Boolean,success:Boolean,settings:{type:Object,default:{animate:!1,animateOnMount:!1,successCallback:Function}}},setup(__props){let props=__props,slots=useSlots(),animationSettings=inject(`animationSettings`,props.settings),animate=ref(!1),labelParsed=computed(()=>parse$1($translate.contextTranslate(props.label,!0))),descriptionParsed=computed(()=>parse$1($translate.contextTranslate(props.description,!0))),checkboxSvgs=computed(()=>({"--checkbox-empty":`url(${getAssetURL(`icons/general/checkbox-empty.svg`)})`,"--checkbox-ok":`url(${getAssetURL(`icons/general/checkbox-ok.svg`)})`,"--checkbox-nope":`url(${getAssetURL(`icons/general/checkbox-nope.svg`)})`}));return watch(()=>[props.complete,props.success],(newValues,oldValues)=>{let isComplete=newValues[0],isSuccess=newValues[1];animate.value=animationSettings.animate&&isComplete,isSuccess&&animationSettings.successCallback()}),onBeforeMount(()=>{animate.value=props.settings.animate&&props.settings.animateOnMount}),(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,{class:normalizeClass([`task-goal`,{success:__props.complete&&__props.success,fail:__props.complete&&!__props.success,animate:animate.value}])},[createBaseVNode(`div`,_hoisted_1$257,[createBaseVNode(`span`,{class:`checkbox`,style:normalizeStyle(checkboxSvgs.value)},null,4),createBaseVNode(`span`,_hoisted_2$213,[unref(slots).label?renderSlot(_ctx.$slots,`label`,{key:0},void 0,!0):__props.label?(openBlock(),createBlock(unref(dynamicComponent_default),{key:1,template:labelParsed.value},null,8,[`template`])):createCommentVNode(``,!0)])]),createBaseVNode(`span`,_hoisted_3$187,[unref(slots).description?renderSlot(_ctx.$slots,`description`,{key:0},void 0,!0):__props.description?(openBlock(),createBlock(unref(dynamicComponent_default),{key:1,template:descriptionParsed.value},null,8,[`template`])):createCommentVNode(``,!0)])],2))}},TaskGoal_default=__plugin_vue_export_helper_default(_sfc_main$288,[[`__scopeId`,`data-v-5a381682`]]),_hoisted_1$256={key:0,class:`wrapper`},_hoisted_2$212={class:`heading`},_hoisted_3$186={class:`description`},_hoisted_4$159={key:1,class:`tasklist wrapper`},_hoisted_5$138={class:`task-content`},_hoisted_6$119={class:`heading`},_hoisted_7$106={class:`description`},_sfc_main$287={__name:`UnlockCard`,props:{data:Object},setup(__props){return(_ctx,_cache)=>(openBlock(),createElementBlock(Fragment,null,[__props.data.type==`tasklist`?createCommentVNode(``,!0):(openBlock(),createElementBlock(`div`,_hoisted_1$256,[createVNode(unref(bngIcon_default),{class:`icon`,type:unref(icons)[__props.data.icon]},null,8,[`type`]),createBaseVNode(`div`,_hoisted_2$212,toDisplayString(__props.data.heading),1),createBaseVNode(`div`,_hoisted_3$186,toDisplayString(__props.data.description),1)])),__props.data.type==`tasklist`?(openBlock(),createElementBlock(`div`,_hoisted_4$159,[(openBlock(!0),createElementBlock(Fragment,null,renderList(__props.data.tasklistData.tasks,task=>(openBlock(),createElementBlock(`div`,{class:`task`,key:task.label},[createVNode(unref(bngIcon_default),{class:`icon`,type:unref(icons)[task.done?`checkboxOn`:`checkboxOff`]},null,8,[`type`]),createBaseVNode(`div`,_hoisted_5$138,[createBaseVNode(`div`,_hoisted_6$119,toDisplayString(task.label),1),createBaseVNode(`div`,_hoisted_7$106,toDisplayString(task.description),1)])]))),128))])):createCommentVNode(``,!0)],64))}},UnlockCard_default=__plugin_vue_export_helper_default(_sfc_main$287,[[`__scopeId`,`data-v-c5fa6ca1`]]),_hoisted_1$255={class:`unlock-rows`},_hoisted_2$211={class:`rows-container`},_hoisted_3$185={class:`progress-track`},_hoisted_4$158={key:0,class:`progress-fill`,style:{height:`100%`}},_hoisted_5$137={class:`header`},_hoisted_6$118={class:`level-name-and-heading`},_hoisted_7$105={class:`level-label`},_hoisted_8$89={key:0,class:`description-heading`},_hoisted_9$79={class:`content-row`},_hoisted_10$69={class:`description-column`},_hoisted_11$62={class:`unlock-condition`},_hoisted_12$51={class:`info`},_hoisted_13$44={class:`label`},_hoisted_14$41={key:1,class:`description-text`},_hoisted_15$39={class:`unlocks-column`},_hoisted_16$38={key:0,class:`unlocks-list`},_sfc_main$286={__name:`UnlockRows`,props:{value:{type:Number,default:0},min:{type:Number,default:0},max:{type:Number,required:!0},maxRequiredValue:{type:Number,required:!1},tiers:Array,currentTier:Number,unlocked:Boolean,progressFillColor:{type:String,default:`#ff6600`}},setup(__props){useCssVars(_ctx=>({v1b3c87f1:props.progressFillColor.startsWith(`var(--`)&&props.progressFillColor.endsWith(`-rgb)`)?`rgb(${props.progressFillColor})`:props.progressFillColor}));let props=__props;function hexToRgb$1(hex){hex=hex.replace(/^#/,``);let bigint=parseInt(hex,16);return`${bigint>>16&255}, ${bigint>>8&255}, ${bigint&255}`}let progressStyle=computed(()=>{if(!props.progressFillColor)return{};let style={};return props.progressFillColor.startsWith(`#`)?style[`--progress-fill-color`]=hexToRgb$1(props.progressFillColor):props.progressFillColor.startsWith(`var(--`)&&(style[`--progress-fill-color`]=props.progressFillColor),style});return(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$255,[createBaseVNode(`div`,_hoisted_2$211,[(openBlock(!0),createElementBlock(Fragment,null,renderList(__props.tiers,(tier,idx)=>(openBlock(),createElementBlock(`div`,{key:tier.index,class:normalizeClass({"tier-row":!0,"grayed-out":__props.currentTier<=tier.index-1,completed:__props.currentTier+1>tier.index,"in-development":tier.isInDevelopment,"first-tier":idx===0,"last-tier":idx===__props.tiers.length-1})},[createBaseVNode(`div`,_hoisted_3$185,[__props.currentTier+1>tier.index?(openBlock(),createElementBlock(`div`,_hoisted_4$158)):createCommentVNode(``,!0)]),createBaseVNode(`div`,_hoisted_5$137,[createBaseVNode(`div`,_hoisted_6$118,[createBaseVNode(`span`,_hoisted_7$105,`Level `+toDisplayString(tier.label?tier.label:tier.index),1),tier.description&&tier.description.heading?(openBlock(),createElementBlock(`span`,_hoisted_8$89,`: `+toDisplayString(tier.description.heading),1)):createCommentVNode(``,!0)])]),createBaseVNode(`div`,_hoisted_9$79,[createBaseVNode(`div`,_hoisted_10$69,[tier.isInDevelopment||__props.currentTier+1<=tier.index||!__props.unlocked?(openBlock(),createBlock(unref(bngCard_default),{key:0,class:`unlock-condition-card`,style:normalizeStyle(progressStyle.value)},{default:withCtx(()=>[createBaseVNode(`div`,_hoisted_11$62,[createBaseVNode(`div`,_hoisted_12$51,[createVNode(unref(bngIcon_default),{class:`icon`,type:tier.isInDevelopment?unref(icons).roadblockL:unref(icons).lockClosed,color:`gray`},null,8,[`type`]),createBaseVNode(`div`,_hoisted_13$44,[tier.isInDevelopment?(openBlock(),createElementBlock(Fragment,{key:0},[createTextVNode(` Coming Soon! `)],64)):(openBlock(),createElementBlock(Fragment,{key:1},[createTextVNode(toDisplayString(tier.xpCurrent)+` / `+toDisplayString(tier.xpRequired)+` XP `,1)],64))])]),!tier.isInDevelopment&&tier.currentValue&&tier.requiredValue?(openBlock(),createBlock(unref(bngProgressBar_default),{key:0,value:tier.xpCurrent,min:0,max:tier.xpRequired,valueLabelFormat:``,class:`progress`},null,8,[`value`,`max`])):createCommentVNode(``,!0)])]),_:2},1032,[`style`])):createCommentVNode(``,!0),tier.description&&tier.description.description?(openBlock(),createElementBlock(`div`,_hoisted_14$41,toDisplayString(tier.description.description),1)):createCommentVNode(``,!0)]),createBaseVNode(`div`,_hoisted_15$39,[tier.list&&tier.list.length>0?(openBlock(),createElementBlock(`div`,_hoisted_16$38,[(openBlock(!0),createElementBlock(Fragment,null,renderList(tier.list,(item,idx$1)=>(openBlock(),createBlock(UnlockCard_default,{key:idx$1,class:`unlock-item`,data:item},null,8,[`data`]))),128))])):createCommentVNode(``,!0)])])],2))),128))])]))}},UnlockRows_default=__plugin_vue_export_helper_default(_sfc_main$286,[[`__scopeId`,`data-v-ec31f890`]]),_hoisted_1$254={class:`flex-row`},_hoisted_2$210={class:`player-content`},_hoisted_3$184={class:`stats-row`},_hoisted_4$157={class:`stat-content`},_sfc_main$285={__name:`careerSimpleStats`,setup(__props,{expose:__expose}){let careerStatsData=ref({}),handleCareerSimpleStats=data=>{data.branches.forEach(entry=>{entry.hasOwnProperty(`levelLabel`)&&(entry.name=$translate.contextTranslate(entry.name,!0),entry.levelLabel=$translate.contextTranslate(entry.levelLabel,!0))}),careerStatsData.value=data},updateDisplay=()=>{Lua_default.career_modules_uiUtils.getCareerSimpleStats().then(handleCareerSimpleStats)};return onMounted(()=>{updateDisplay()}),__expose({updateDisplay}),(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$254,[createBaseVNode(`div`,_hoisted_2$210,toDisplayString(careerStatsData.value.saveSlotName),1),createBaseVNode(`div`,_hoisted_3$184,[(openBlock(!0),createElementBlock(Fragment,null,renderList(careerStatsData.value.branches,branch=>(openBlock(),createElementBlock(`div`,_hoisted_4$157,[createVNode(unref(bngProgressBar_default),{class:`stat-progress-bar`,headerLeft:branch.name,headerRight:branch.levelLabel,min:branch.min,value:branch.value,max:branch.max},null,8,[`headerLeft`,`headerRight`,`min`,`value`,`max`])]))),256))])]))}},careerSimpleStats_default=__plugin_vue_export_helper_default(_sfc_main$285,[[`__scopeId`,`data-v-94a9390d`]]),_sfc_main$284={__name:`careerStatus`,props:{slim:{type:Boolean,default:!1}},setup(__props,{expose:__expose}){let careerStatusData=ref({}),handleCareerStatusData=data=>careerStatusData.value=data,updateDisplay=()=>Lua_default.career_modules_uiUtils.getCareerStatusData().then(handleCareerStatusData);return onMounted(updateDisplay),__expose({updateDisplay}),(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,null,[createBaseVNode(`div`,{class:normalizeClass([`career-status-progress`,{slim:__props.slim}])},[createVNode(unref(bngUnit_default),{class:`career-status-value`,insuranceScore:careerStatusData.value.insuranceScore},null,8,[`insuranceScore`]),createVNode(unref(bngDivider_default)),createVNode(unref(bngUnit_default),{class:`career-status-value`,vouchers:careerStatusData.value.vouchers},null,8,[`vouchers`]),createVNode(unref(bngDivider_default)),createVNode(unref(bngUnit_default),{class:`career-status-value`,money:careerStatusData.value.money},null,8,[`money`])],2)]))}},careerStatus_default=__plugin_vue_export_helper_default(_sfc_main$284,[[`__scopeId`,`data-v-0446c53b`]]),_hoisted_1$253={key:0},_sfc_main$283={__name:`TutorialButton`,props:{text:{type:String,default:``},icon:{type:Object,default:()=>icons.questionmark},pages:{type:Object,default:[]}},setup(__props){let props=__props,buttonRef=ref(null),seen$3=ref(!0);function clickHandler(){for(let key of props.pages)Lua_default.career_modules_linearTutorial.introPopup(key,!0);seen$3.value=!0}return onMounted(()=>{}),onUnmounted(()=>{}),(_ctx,_cache)=>withDirectives((openBlock(),createBlock(unref(bngButton_default),{ref_key:`buttonRef`,ref:buttonRef,class:normalizeClass([`tut-btn`,{blink:!seen$3.value}]),icon:__props.icon,onClick:withModifiers(clickHandler,[`stop`])},{default:withCtx(()=>[__props.text?(openBlock(),createElementBlock(`span`,_hoisted_1$253,toDisplayString(__props.text),1)):createCommentVNode(``,!0)]),_:1},8,[`icon`,`class`])),[[unref(BngTooltip_default),__props.text?void 0:`View tutorial for this section`]])}},TutorialButton_default=__plugin_vue_export_helper_default(_sfc_main$283,[[`__scopeId`,`data-v-3e539b42`]]),_hoisted_1$252={class:`content`},_hoisted_2$209={class:`insurance-perks-div`},_hoisted_3$183={key:0,class:`leaving-insurance-wrapper`},_hoisted_4$156={class:`breakdown-items-wrapper`},_hoisted_5$136={class:`breakdown-item`},_hoisted_6$117={class:`orange-price`},_hoisted_7$104={class:`breakdown-item`},_hoisted_8$88={class:`red-price`},_hoisted_9$78={class:`breakdown-item total`},_hoisted_10$68={class:`breakdown-item-value-total green-price`},_hoisted_11$61={key:1,class:`no-insurance-wrapper`},_hoisted_12$50={key:2,class:`group-discount-wrapper`},_hoisted_13$43={class:`group-discount-icon-wrapper`},_hoisted_14$40={class:`group-discount-main-text`},_hoisted_15$38={class:`tier-text`},_hoisted_16$37={class:`tier-text`},_hoisted_17$31={class:`discount-text`},_hoisted_18$28={class:`grey-small-text`},_hoisted_19$24={key:3,class:`price-details-wrapper`},_hoisted_20$20={class:`price-tile`},_hoisted_21$18={key:0,class:`old-price-wrapper`},_hoisted_22$16={class:`old-price`},_hoisted_23$15={class:`price-tile-value-wrapper`},_hoisted_24$14={key:1,class:`deductible-discount`},_hoisted_25$13={class:`price-tile`},_hoisted_26$11={class:`price-tile-title`},_hoisted_27$11={class:`price-tile-value-wrapper`},_hoisted_28$10={class:`premium-extra-info`},_hoisted_29$10={class:`renewal-distance`},_sfc_main$282={__name:`insuranceCard`,props:{insuranceData:Object,isSelected:Boolean,isCurrentProvider:{type:Boolean,default:!1}},emits:[`select`],setup(__props,{emit:__emit}){let props=__props,{units}=useBridge(),emit$1=__emit,hasNoInsurance=computed(()=>props.insuranceData?.id===-1),pillText=computed(()=>{if(props.isCurrentProvider)return`CURRENT PROVIDER`;if(props.insuranceData.groupDiscountData){if(props.insuranceData.groupDiscountData?.willHaveGroupDiscountForTheFirstTime)return`MULTI-VEHICLE DISCOUNT AVAILABLE`;if(props.insuranceData.groupDiscountData?.willBumpTheirDiscount)return`BIGGER DISCOUNT AVAILABLE`;if(props.insuranceData.groupDiscountData?.currentTierData&&props.insuranceData.groupDiscountData?.currentTierData.id>0)return`MULTI-VEHICLE DISCOUNT ACTIVE`}return null}),renewsInFormatted=computed(()=>props.insuranceData?.renewsIn?units.buildString(`length`,props.insuranceData.renewsIn*1e3,0):``),leavingInsuranceRenewsInFormatted=computed(()=>props.insuranceData?.leavingInsuranceInfo?.renewsIn?units.buildString(`length`,props.insuranceData.leavingInsuranceInfo.renewsIn*1e3,0):``),selectCard=()=>{emit$1(`select`,props.insuranceData.id)},cardStyles=computed(()=>{let styles={};return!hasNoInsurance.value&&props.insuranceData.color&&(styles[`--insurance-card-rgb`]=hexToRgb(props.insuranceData.color)),styles});return(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,{class:normalizeClass([`insurance-card-container`,{selected:__props.isSelected,"no-insurance-card":hasNoInsurance.value,"current-provider":__props.isCurrentProvider}]),style:normalizeStyle(cardStyles.value),onClick:selectCard,"bng-nav-item":``},[pillText.value===null?createCommentVNode(``,!0):(openBlock(),createElementBlock(`div`,{key:0,class:normalizeClass([`top-pill`,{"no-insurance":hasNoInsurance.value,"orange-pill":__props.insuranceData.groupDiscountData?.willHaveGroupDiscountForTheFirstTime,"current-provider-pill":__props.isCurrentProvider}])},[createBaseVNode(`div`,null,toDisplayString(pillText.value),1)],2)),createBaseVNode(`div`,_hoisted_1$252,[createVNode(unref(insuranceIdentity_default),{class:`insurance-identity`,insuranceData:__props.insuranceData},null,8,[`insuranceData`]),_cache[13]||=createBaseVNode(`div`,{class:`separator`},null,-1),createBaseVNode(`div`,_hoisted_2$209,[hasNoInsurance.value?(openBlock(),createElementBlock(`div`,{key:0,class:normalizeClass([`perks-header`,{"no-insurance":hasNoInsurance.value}])},toDisplayString(hasNoInsurance.value?`Consequences`:`Included Benefits`),3)):createCommentVNode(``,!0),createVNode(unref(insurancePerks_default),{insuranceData:__props.insuranceData},null,8,[`insuranceData`])]),_cache[14]||=createBaseVNode(`div`,{class:`separator`},null,-1),hasNoInsurance.value&&__props.insuranceData.leavingInsuranceInfo&&!__props.isCurrentProvider?(openBlock(),createElementBlock(`div`,_hoisted_3$183,[_cache[4]||=createBaseVNode(`div`,{class:`leaving-insurance-title`},`Cancellation Refund`,-1),createBaseVNode(`div`,_hoisted_4$156,[createBaseVNode(`div`,_hoisted_5$136,[createBaseVNode(`span`,null,` Unused coverage (`+toDisplayString(leavingInsuranceRenewsInFormatted.value)+`) `,1),createBaseVNode(`span`,_hoisted_6$117,[_cache[0]||=createTextVNode(` + `,-1),createVNode(unref(bngUnit_default),{money:__props.insuranceData.leavingInsuranceInfo.coverageRefundPrice},null,8,[`money`])])]),createBaseVNode(`div`,_hoisted_7$104,[_cache[2]||=createBaseVNode(`span`,null,` Early Cancellation Fee (25%) `,-1),createBaseVNode(`span`,_hoisted_8$88,[_cache[1]||=createTextVNode(` - `,-1),createVNode(unref(bngUnit_default),{money:__props.insuranceData.leavingInsuranceInfo.earlyTerminationPenalty},null,8,[`money`])])]),createBaseVNode(`div`,_hoisted_9$78,[_cache[3]||=createBaseVNode(`span`,{class:`breakdown-item-label-total`},` You'll receive `,-1),createBaseVNode(`span`,_hoisted_10$68,[createVNode(unref(bngUnit_default),{money:__props.insuranceData.leavingInsuranceInfo.netRefundPrice},null,8,[`money`])])])])])):createCommentVNode(``,!0),hasNoInsurance.value?(openBlock(),createElementBlock(`div`,_hoisted_11$61,[..._cache[5]||=[createBaseVNode(`span`,{class:`no-insurance-warning`},` You will pay full repair costs `,-1),createBaseVNode(`span`,null,` No coverage or benefits included `,-1)]])):createCommentVNode(``,!0),!hasNoInsurance.value&&__props.insuranceData.groupDiscountData?.mainText?(openBlock(),createElementBlock(`div`,_hoisted_12$50,[createBaseVNode(`div`,null,[createBaseVNode(`span`,_hoisted_13$43,[createVNode(unref(bngIcon_default),{type:unref(icons).checkmark},null,8,[`type`])]),createBaseVNode(`span`,_hoisted_14$40,toDisplayString(__props.insuranceData.groupDiscountData?.mainText),1)]),createBaseVNode(`div`,null,[_cache[7]||=createBaseVNode(`span`,{class:`grey-small-text`},` Currently Insured : `,-1),createBaseVNode(`span`,null,[createVNode(unref(bngIcon_default),{class:`vehicles-icon`,type:unref(icons).car},null,8,[`type`])]),createBaseVNode(`span`,_hoisted_15$38,toDisplayString(__props.insuranceData.carsInsuredCount),1),__props.insuranceData.groupDiscountData?.currentTierData?.id>0?(openBlock(),createElementBlock(Fragment,{key:0},[_cache[6]||=createBaseVNode(`span`,{class:`vertical-separator`},` | `,-1),createBaseVNode(`span`,_hoisted_16$37,` Tier `+toDisplayString(__props.insuranceData.groupDiscountData?.currentTierData?.id),1),createBaseVNode(`span`,_hoisted_17$31,` - `+toDisplayString(__props.insuranceData.groupDiscountData?.currentTierData?.discount*100)+`% off `,1)],64)):createCommentVNode(``,!0)]),createBaseVNode(`div`,_hoisted_18$28,toDisplayString(__props.insuranceData.groupDiscountData?.secondaryText),1)])):createCommentVNode(``,!0),hasNoInsurance.value?createCommentVNode(``,!0):(openBlock(),createElementBlock(`div`,_hoisted_19$24,[createBaseVNode(`div`,_hoisted_20$20,[_cache[9]||=createBaseVNode(`span`,{class:`price-tile-title`},`Deductible`,-1),__props.insuranceData.baseDeductibledData?.oldPrice?(openBlock(),createElementBlock(`div`,_hoisted_21$18,[createBaseVNode(`div`,_hoisted_22$16,[createVNode(unref(bngUnit_default),{money:__props.insuranceData.baseDeductibledData.oldPrice},null,8,[`money`]),_cache[8]||=createBaseVNode(`div`,{class:`strike`},null,-1)])])):createCommentVNode(``,!0),createBaseVNode(`div`,_hoisted_23$15,[createVNode(unref(bngUnit_default),{money:__props.insuranceData.baseDeductibledData.price,class:normalizeClass(__props.insuranceData.baseDeductibledData.oldPrice?`green-price`:`orange-price`)},null,8,[`money`,`class`])]),_cache[10]||=createBaseVNode(`div`,{class:`deductible-tips`},[createBaseVNode(`div`,null,` - You pay your deductible for each crash repair `),createBaseVNode(`div`,null,` - Customize this value after purchase `)],-1),__props.insuranceData.baseDeductibledData.perkData?(openBlock(),createElementBlock(`div`,_hoisted_24$14,toDisplayString(__props.insuranceData.baseDeductibledData.perkData.discount*100)+`% discount applied `,1)):createCommentVNode(``,!0)]),createBaseVNode(`div`,_hoisted_25$13,[createBaseVNode(`span`,_hoisted_26$11,toDisplayString(__props.insuranceData.amountDue>0?`Amount Due`:`Credit Received`),1),createBaseVNode(`div`,_hoisted_27$11,[createVNode(unref(bngUnit_default),{money:Math.abs(__props.insuranceData.amountDue),class:`green-price`},null,8,[`money`])]),createBaseVNode(`div`,_hoisted_28$10,[createBaseVNode(`div`,null,[_cache[11]||=createTextVNode(` Total policy : `,-1),createVNode(unref(bngUnit_default),{money:__props.insuranceData.futurePremiumDetails.totalPriceWithDriverScore},null,8,[`money`])]),createBaseVNode(`div`,null,[_cache[12]||=createBaseVNode(`span`,null,`Renews in : `,-1),createBaseVNode(`span`,_hoisted_29$10,toDisplayString(renewsInFormatted.value),1)])])])]))]),createBaseVNode(`div`,{class:normalizeClass([`background`,{"no-insurance":hasNoInsurance.value}])},null,2)],6))}},insuranceCard_default=__plugin_vue_export_helper_default(_sfc_main$282,[[`__scopeId`,`data-v-e481fbef`]]),_hoisted_1$251={class:`premium-wrapper`},_hoisted_2$208={class:`breakdown-item`},_hoisted_3$182={class:`breakdown-item-value`},_hoisted_4$155={class:`premium-value-wrapper`},_hoisted_5$135={class:`breakdown-item`},_hoisted_6$116={class:`breakdown-item-value`},_hoisted_7$103={class:`breakdown-item`},_hoisted_8$87={class:`breakdown-item-value`},_hoisted_9$77={class:`breakdown-item`},_hoisted_10$67={class:`breakdown-item-value orange-text`},_hoisted_11$60={class:`perks`},_hoisted_12$49={key:0,class:`grey-text`},_hoisted_13$42={key:1,class:`grey-text`},_hoisted_14$39={class:`group-discount-savings`},_hoisted_15$37={class:`breakdown-item`},_hoisted_16$36={key:0,class:`grey-text`},_hoisted_17$30={key:1,class:`grey-text`},_hoisted_18$27={class:`buttons`},_sfc_main$281={__name:`smallInsuranceCard`,props:{insuranceData:{type:Object,required:!0},driverScoreData:{type:Object,required:!0}},setup(__props){let{units}=useBridge(),props=__props,renewsEveryFormatted=computed(()=>units.buildString(`length`,props.insuranceData.renewsEvery*1e3,0)),renewsInFormatted=computed(()=>units.buildString(`length`,props.insuranceData.renewsIn*1e3,0)),buttonsDisabled=computed(()=>props.insuranceData.carsInsuredCount===0),openVehicleList=()=>{addPopup(vehicleInsuranceList_default,{insuranceData:props.insuranceData,driverScoreData:props.driverScoreData})},openEditPolicy=()=>{addPopup(editPolicy_default,{insuranceData:props.insuranceData,driverScoreData:props.driverScoreData})},tierToDisplay=computed(()=>props.insuranceData.groupDiscountData.currentTierData.id>0?props.insuranceData.groupDiscountData.currentTierData:props.insuranceData.groupDiscountData.groupDiscountTiers[0]);return(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,{class:normalizeClass([`small-insurance-card`,{"no-vehicles":buttonsDisabled.value}]),style:normalizeStyle({"border-top":`0.7rem solid ${props.insuranceData.color}`,background:`linear-gradient(180deg, ${props.insuranceData.color}80 0%, ${props.insuranceData.color}30 10%, ${props.insuranceData.color}10 35%, var(--bng-cool-gray-800) 50%, var(--blue-shade-100) 100%)`})},[createVNode(unref(insuranceIdentity_default),{class:`insurance-identity`,insuranceData:props.insuranceData},null,8,[`insuranceData`]),createBaseVNode(`div`,_hoisted_1$251,[createBaseVNode(`div`,_hoisted_2$208,[createBaseVNode(`span`,null,`Premium / `+toDisplayString(renewsEveryFormatted.value),1),createBaseVNode(`span`,_hoisted_3$182,[createBaseVNode(`div`,_hoisted_4$155,[createVNode(unref(bngUnit_default),{money:props.insuranceData.currentPremiumDetails.totalPriceWithDriverScore},null,8,[`money`])])])]),createBaseVNode(`div`,_hoisted_5$135,[_cache[0]||=createBaseVNode(`span`,null,`Renews in `,-1),createBaseVNode(`span`,_hoisted_6$116,[props.insuranceData.carsInsuredCount===0?(openBlock(),createElementBlock(Fragment,{key:0},[createTextVNode(` - `)],64)):(openBlock(),createElementBlock(Fragment,{key:1},[createTextVNode(toDisplayString(renewsInFormatted.value),1)],64))])]),createBaseVNode(`div`,_hoisted_7$103,[_cache[1]||=createBaseVNode(`span`,null,`Vehicle Coverage`,-1),createBaseVNode(`span`,_hoisted_8$87,[createVNode(unref(bngUnit_default),{money:props.insuranceData.totalInsuranceVehsValue},null,8,[`money`])])]),createBaseVNode(`div`,_hoisted_9$77,[_cache[2]||=createBaseVNode(`span`,null,`Vehicles`,-1),createBaseVNode(`span`,_hoisted_10$67,toDisplayString(props.insuranceData.carsInsuredCount),1)])]),createBaseVNode(`div`,_hoisted_11$60,[createVNode(unref(insurancePerks_default),{insuranceData:props.insuranceData,noDescription:!0},null,8,[`insuranceData`])]),createBaseVNode(`div`,{class:normalizeClass([`group-discount-wrapper`,{disabled:props.insuranceData.groupDiscountData.currentTierData.id===-1}])},[props.insuranceData.carsInsuredCount===0?(openBlock(),createElementBlock(`div`,_hoisted_12$49,` No vehicles insured under this policy `)):props.insuranceData.carsInsuredCount===1?(openBlock(),createElementBlock(`div`,_hoisted_13$42,` Add a second vehicle to unlock Tier 1 (`+toDisplayString(props.insuranceData.groupDiscountData.groupDiscountTiers[0].discount*100)+`%) coverage savings. `,1)):(openBlock(),createElementBlock(Fragment,{key:2},[_cache[4]||=createBaseVNode(`div`,{class:`group-discount`},` MULTI-VEHICLE DISCOUNT `,-1),createBaseVNode(`div`,_hoisted_14$39,[_cache[3]||=createTextVNode(` Savings :`,-1),createVNode(unref(bngUnit_default),{money:props.insuranceData.currentPremiumDetails.groupDiscountSavings},null,8,[`money`])]),createBaseVNode(`div`,_hoisted_15$37,[tierToDisplay.value.max?(openBlock(),createElementBlock(`span`,_hoisted_16$36,` Your coverage falls in the `+toDisplayString(tierToDisplay.value.min/1e3)+`k - `+toDisplayString(tierToDisplay.value.max/1e3)+`k range `,1)):(openBlock(),createElementBlock(`span`,_hoisted_17$30,` Your coverage falls in the `+toDisplayString(tierToDisplay.value.min/1e3)+`k+ range `,1))]),createBaseVNode(`div`,null,[createVNode(unref(insuranceTiers_default),{showTier:!0,tiers:props.insuranceData.groupDiscountData.groupDiscountTiers},null,8,[`tiers`])])],64))],2),createBaseVNode(`div`,_hoisted_18$27,[createVNode(unref(bngButton_default),{class:`edit-policy-button bigger-button`,accent:`custom`,onClick:openEditPolicy,disabled:buttonsDisabled.value},{default:withCtx(()=>[createVNode(unref(bngIcon_default),{class:normalizeClass([`button-icon`,{disabled:buttonsDisabled.value}]),type:unref(icons).adjust},null,8,[`type`,`class`]),createBaseVNode(`span`,{class:normalizeClass([`button-text`,{disabled:buttonsDisabled.value}])},`Edit Policy`,2)]),_:1},8,[`disabled`]),createVNode(unref(bngButton_default),{class:`see-vehicles-button bigger-button`,accent:`custom`,onClick:openVehicleList,disabled:buttonsDisabled.value},{default:withCtx(()=>[createVNode(unref(bngIcon_default),{class:normalizeClass([`button-icon`,{disabled:buttonsDisabled.value}]),type:unref(icons).car},null,8,[`type`,`class`]),createBaseVNode(`span`,{class:normalizeClass([`button-text`,{disabled:buttonsDisabled.value}])},`See Vehicles`,2)]),_:1},8,[`disabled`])])],6))}},smallInsuranceCard_default=__plugin_vue_export_helper_default(_sfc_main$281,[[`__scopeId`,`data-v-38392c0c`]]),_hoisted_1$250={class:`insurance-details-wrapper`,"bng-ui-scope":`insuranceDetailsPopup`},_hoisted_2$207={class:`card-content`},_hoisted_3$181={class:`header`},_hoisted_4$154={class:`header-left`},_hoisted_5$134={class:`insurance-identity`},_hoisted_6$115={class:`insurance-name`},_hoisted_7$102={class:`insurance-slogan`},_hoisted_8$86={class:`covers-renew-info`},_hoisted_9$76={class:`header-right`},_hoisted_10$66={class:`vehicle-name`},_hoisted_11$59={class:`vehicle-value blue-price`},_hoisted_12$48={key:0,class:`group-discount-wrapper`},_hoisted_13$41={class:`group-discount-header`},_hoisted_14$38={class:`group-discount-icon-wrapper`},_hoisted_15$36={class:`group-discount-text-wrapper`},_hoisted_16$35={class:`group-discount-main-text`},_hoisted_17$29={class:`tiers-wrapper`},_hoisted_18$26={class:`textual-tiers-wrapper`},_hoisted_19$23={class:`tier-number`},_hoisted_20$19={class:`money-bracket`},_hoisted_21$17={key:0},_hoisted_22$15={key:1},_hoisted_23$14={class:`current-after-discount-price`},_hoisted_24$13={class:`tier-discount-price`},_hoisted_25$12={class:`policy-value`},_hoisted_26$10={class:`policy-tier`},_hoisted_27$10={class:`tier-discount-price isFutureTier`},_hoisted_28$9={class:`policy-value`},_hoisted_29$9={class:`policy-tier isFuture`},_hoisted_30$9={class:`price-breakdown-wrapper`},_hoisted_31$9={class:`prices-breakdown-header`},_hoisted_32$9={class:`breakdown-item`},_hoisted_33$9={class:`breakdown-details`},_hoisted_34$9={class:`breakdown-item-value`},_hoisted_35$8={class:`breakdown-value`},_hoisted_36$8={class:`breakdown-item-value orange`},_hoisted_37$7={class:`breakdown-value`},_hoisted_38$6={key:0,class:`breakdown-item-value orange`},_hoisted_39$6={class:`breakdown-label`},_hoisted_40$5={class:`breakdown-value`},_hoisted_41$5={class:`breakdown-item-value result`},_hoisted_42$4={class:`breakdown-value result`},_hoisted_43$4={class:`breakdown-item`},_hoisted_44$4={class:`breakdown-details`},_hoisted_45$4={key:0,class:`breakdown-item-value`},_hoisted_46$2={key:0,class:`strikethrough-line`},_hoisted_47$2={key:1,class:`breakdown-item-value`},_hoisted_48$2={class:`breakdown-label`},_hoisted_49$2={class:`tier-discount-badge`},_hoisted_50$2={class:`breakdown-value green-price`},_hoisted_51$2={key:0,class:`breakdown-item-value`},_hoisted_52$2={class:`breakdown-label`},_hoisted_53$2={class:`breakdown-value`},_hoisted_54$2={class:`breakdown-item-value subtotal`},_hoisted_55$2={class:`breakdown-value`},_hoisted_56$2={class:`breakdown-item-value`},_hoisted_57$1={class:`breakdown-item-value result`},_hoisted_58$1={class:`breakdown-value`},_hoisted_59$1={class:`sum-to-pay`},_hoisted_60$1={class:`sum-to-pay-value`},_hoisted_61$1={class:`closeButton`},__default__$5={wrapper:{fade:!0,blur:!0,style:popupContainer.default},position:[popupPosition.center,popupPosition.center]},_sfc_main$280=Object.assign(__default__$5,{__name:`purchaseInsuranceDetails`,props:{insuranceData:Object,vehicleInfo:Object,driverScoreData:Object},emits:[`return`],setup(__props,{emit:__emit}){let{units}=useBridge();useUINavScope(`insuranceDetailsPopup`);let props=__props,emit$1=__emit,closePopup=()=>{emit$1(`return`,!0)},driverScoreAdjustmentText=computed(()=>{let multiplier=props.driverScoreData.tier.multiplier;return multiplier<1?`↓${((1-multiplier)*100).toFixed(0)}%`:multiplier>1?`↑${((multiplier-1)*100).toFixed(0)}%`:`0%`}),driverScoreClass=computed(()=>{let multiplier=props.driverScoreData.tier.multiplier;return multiplier<1?`driver-score-discount`:multiplier>1?`driver-score-penalty`:``}),groupDiscountText=computed(()=>{if(props.insuranceData.groupDiscountData){if(props.insuranceData.groupDiscountData.willHaveGroupDiscountForTheFirstTime)return`Multi-vehicle discount available`;if(props.insuranceData.groupDiscountData.willBumpTheirDiscount)return`Bigger discount available`;if(props.insuranceData.groupDiscountData.currentTierData&&props.insuranceData.groupDiscountData.currentTierData.id>0)return`Multi-vehicle discount active`}return null}),renewsEveryFormatted=computed(()=>props.insuranceData?.renewsEvery?units.buildString(`length`,props.insuranceData.renewsEvery*1e3,0):``);return(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$250,[createBaseVNode(`div`,_hoisted_2$207,[createBaseVNode(`div`,_hoisted_3$181,[createBaseVNode(`div`,_hoisted_4$154,[_cache[2]||=createBaseVNode(`div`,{class:`policy-details`},` Policy details `,-1),createBaseVNode(`div`,_hoisted_5$134,[createBaseVNode(`span`,_hoisted_6$115,toDisplayString(props.insuranceData.name),1),_cache[0]||=createBaseVNode(`span`,{class:`name-slogan-seperator`},null,-1),createBaseVNode(`span`,_hoisted_7$102,toDisplayString(props.insuranceData.slogan),1)]),createBaseVNode(`div`,_hoisted_8$86,[createBaseVNode(`span`,null,`Covers `+toDisplayString(props.insuranceData.carsInsuredCount)+` Vehicles`,1),_cache[1]||=createBaseVNode(`span`,{class:`covers-renew-seperator`},null,-1),createBaseVNode(`span`,null,`Renews every `+toDisplayString(renewsEveryFormatted.value),1)])]),createBaseVNode(`div`,_hoisted_9$76,[_cache[4]||=createBaseVNode(`div`,{class:`action-type`},`Adding vehicle`,-1),createBaseVNode(`div`,_hoisted_10$66,toDisplayString(props.vehicleInfo.Name),1),createBaseVNode(`div`,_hoisted_11$59,[_cache[3]||=createTextVNode(`Value : `,-1),createVNode(unref(bngUnit_default),{money:props.vehicleInfo.Value},null,8,[`money`])])])]),props.insuranceData.groupDiscountData.willHaveGroupDiscountForTheFirstTime||props.insuranceData.groupDiscountData.willBumpTheirDiscount||props.insuranceData.groupDiscountData.currentTierData.id>0?(openBlock(),createElementBlock(`div`,_hoisted_12$48,[createBaseVNode(`div`,_hoisted_13$41,[createBaseVNode(`div`,_hoisted_14$38,[createVNode(unref(bngIcon_default),{type:unref(icons).checkmark},null,8,[`type`])]),createBaseVNode(`div`,_hoisted_15$36,[createBaseVNode(`div`,_hoisted_16$35,toDisplayString(groupDiscountText.value),1),_cache[5]||=createBaseVNode(`div`,{class:`group-discount-secondary-text`},` Insurance discounts are based on the total value of your fleet. `,-1)])]),createBaseVNode(`div`,_hoisted_17$29,[createBaseVNode(`div`,_hoisted_18$26,[(openBlock(!0),createElementBlock(Fragment,null,renderList(props.insuranceData.groupDiscountData.groupDiscountTiers,tier=>(openBlock(),createElementBlock(`div`,{class:`tier`,key:tier.id},[createBaseVNode(`div`,_hoisted_19$23,` Tier `+toDisplayString(tier.id),1),createBaseVNode(`div`,_hoisted_20$19,[createBaseVNode(`span`,null,toDisplayString(tier.min/1e3)+`k`,1),tier.max?(openBlock(),createElementBlock(`span`,_hoisted_21$17,`-`+toDisplayString(tier.max/1e3)+`k`,1)):(openBlock(),createElementBlock(`span`,_hoisted_22$15,`+`))])]))),128))]),createVNode(unref(insuranceTiers_default),{tiers:props.insuranceData.groupDiscountData.groupDiscountTiers},null,8,[`tiers`])]),createBaseVNode(`div`,_hoisted_23$14,[createBaseVNode(`div`,_hoisted_24$13,[_cache[7]||=createBaseVNode(`div`,{class:`section-label deactivated`},` Current Tier `,-1),createBaseVNode(`div`,_hoisted_25$12,[_cache[6]||=createTextVNode(` Policy Value : `,-1),createVNode(unref(bngUnit_default),{money:props.insuranceData.totalInsuranceVehsValue},null,8,[`money`])]),createBaseVNode(`div`,_hoisted_26$10,` Tier `+toDisplayString(Math.max(props.insuranceData.groupDiscountData.currentTierData.id,0))+` - `+toDisplayString(props.insuranceData.groupDiscountData.currentTierData.discount*100)+`% off `,1)]),createBaseVNode(`div`,_hoisted_27$10,[_cache[9]||=createBaseVNode(`div`,{class:`section-label`},` After Purchase `,-1),createBaseVNode(`div`,_hoisted_28$9,[_cache[8]||=createTextVNode(` Policy Value : `,-1),createVNode(unref(bngUnit_default),{money:props.insuranceData.totalInsuranceVehsValue+props.insuranceData.vehicleValue},null,8,[`money`])]),createBaseVNode(`div`,_hoisted_29$9,` Tier `+toDisplayString(props.insuranceData.groupDiscountData.futureTierData.id)+` - `+toDisplayString(props.insuranceData.groupDiscountData.futureTierData.discount*100)+`% off `,1)])])])):createCommentVNode(``,!0),createBaseVNode(`div`,_hoisted_30$9,[createBaseVNode(`div`,_hoisted_31$9,[createBaseVNode(`div`,_hoisted_32$9,[_cache[13]||=createBaseVNode(`div`,{class:`section-label`},` Vehicle `,-1),createBaseVNode(`div`,_hoisted_33$9,[createBaseVNode(`div`,_hoisted_34$9,[_cache[10]||=createBaseVNode(`span`,{class:`breakdown-label`},` Coverage Cost `,-1),createBaseVNode(`span`,_hoisted_35$8,[createVNode(unref(bngUnit_default),{money:props.insuranceData.nonProRatedVehiclePremium},null,8,[`money`])])]),createBaseVNode(`div`,_hoisted_36$8,[_cache[11]||=createBaseVNode(`span`,{class:`breakdown-label`},` Pro-rated Renewal `,-1),createBaseVNode(`span`,_hoisted_37$7,` × `+toDisplayString(props.insuranceData.proRatedPercentage)+`% `,1)]),props.insuranceData.groupDiscountData?.currentTierData.id>0?(openBlock(),createElementBlock(`div`,_hoisted_38$6,[createBaseVNode(`span`,_hoisted_39$6,` Tier `+toDisplayString(props.insuranceData.groupDiscountData?.currentTierData.id)+` discount `,1),createBaseVNode(`span`,_hoisted_40$5,` - `+toDisplayString(props.insuranceData.groupDiscountData?.currentTierData.discount*100)+`% `,1)])):createCommentVNode(``,!0),createBaseVNode(`div`,_hoisted_41$5,[_cache[12]||=createBaseVNode(`span`,{class:`breakdown-label`},` Policy Add-On Cost `,-1),createBaseVNode(`span`,_hoisted_42$4,[createVNode(unref(bngUnit_default),{money:props.insuranceData.proRatedVehiclePremium},null,8,[`money`])])])])]),createBaseVNode(`div`,_hoisted_43$4,[_cache[18]||=createBaseVNode(`div`,{class:`section-label`},` New Premium `,-1),createBaseVNode(`div`,_hoisted_44$4,[props.insuranceData.futurePremiumDetails.items.vehsCoverage?(openBlock(),createElementBlock(`div`,_hoisted_45$4,[_cache[14]||=createBaseVNode(`div`,{class:`breakdown-label`},` Vehicles Coverage `,-1),createBaseVNode(`div`,{class:normalizeClass([`breakdown-value strikethrough-container`,{"strikethrough-grey":props.insuranceData.futurePremiumDetails.groupDiscountSavings>0}])},[createVNode(unref(bngUnit_default),{money:props.insuranceData.futurePremiumDetails.items.vehsCoverage.priceWithoutGroupDiscount},null,8,[`money`]),props.insuranceData.futurePremiumDetails.groupDiscountSavings>0?(openBlock(),createElementBlock(`div`,_hoisted_46$2)):createCommentVNode(``,!0)],2)])):createCommentVNode(``,!0),props.insuranceData.futurePremiumDetails.items.vehsCoverage&&props.insuranceData.futurePremiumDetails.groupDiscountSavings>0?(openBlock(),createElementBlock(`div`,_hoisted_47$2,[createBaseVNode(`div`,_hoisted_48$2,[createTextVNode(toDisplayString(props.insuranceData.futurePremiumDetails.items.vehsCoverage.name)+` `,1),createBaseVNode(`span`,null,[createTextVNode(`: Tier `+toDisplayString(props.insuranceData.groupDiscountData.currentTierData.id)+` `,1),createBaseVNode(`span`,_hoisted_49$2,`(`+toDisplayString(props.insuranceData.groupDiscountData.currentTierData.discount*100)+`% off)`,1)])]),createBaseVNode(`div`,_hoisted_50$2,[createVNode(unref(bngUnit_default),{money:props.insuranceData.futurePremiumDetails.items.vehsCoverage.price},null,8,[`money`])])])):createCommentVNode(``,!0),(openBlock(!0),createElementBlock(Fragment,null,renderList(props.insuranceData.futurePremiumDetails.items,(item,key)=>(openBlock(),createElementBlock(Fragment,{key},[key===`vehsCoverage`?createCommentVNode(``,!0):(openBlock(),createElementBlock(`div`,_hoisted_51$2,[createBaseVNode(`div`,_hoisted_52$2,toDisplayString(item.name),1),createBaseVNode(`div`,_hoisted_53$2,[createVNode(unref(bngUnit_default),{money:item.price},null,8,[`money`])])]))],64))),128)),createBaseVNode(`div`,_hoisted_54$2,[_cache[15]||=createBaseVNode(`div`,{class:`breakdown-label`},` Subtotal `,-1),createBaseVNode(`div`,_hoisted_55$2,[createVNode(unref(bngUnit_default),{money:props.insuranceData.futurePremiumDetails.totalPrice},null,8,[`money`])])]),createBaseVNode(`div`,_hoisted_56$2,[_cache[16]||=createBaseVNode(`div`,{class:`breakdown-label`},` Driver Score Adjustment `,-1),createBaseVNode(`div`,{class:normalizeClass([`breakdown-value`,driverScoreClass.value])},toDisplayString(driverScoreAdjustmentText.value),3)]),createBaseVNode(`div`,_hoisted_57$1,[_cache[17]||=createBaseVNode(`div`,{class:`breakdown-label`},` Total Premium `,-1),createBaseVNode(`div`,_hoisted_58$1,[createVNode(unref(bngUnit_default),{money:props.insuranceData.futurePremiumDetails.totalPriceWithDriverScore},null,8,[`money`])])])])])]),createBaseVNode(`div`,_hoisted_59$1,[_cache[19]||=createBaseVNode(`span`,null,`Amount due today`,-1),createBaseVNode(`span`,_hoisted_60$1,[createVNode(unref(bngUnit_default),{class:`green-price`,money:props.insuranceData.addVehiclePrice},null,8,[`money`])])])]),createBaseVNode(`div`,_hoisted_61$1,[createVNode(unref(bngButton_default),{accent:unref(ACCENTS).primary,onClick:closePopup},{default:withCtx(()=>[..._cache[20]||=[createTextVNode(` Close `,-1)]]),_:1},8,[`accent`])])])]))}}),purchaseInsuranceDetails_default=__plugin_vue_export_helper_default(_sfc_main$280,[[`__scopeId`,`data-v-9f20c127`]]),_hoisted_1$249={class:`content`},_hoisted_2$206={class:`top-banner`},_hoisted_3$180={class:`top-banner-left`},_hoisted_4$153={class:`insurance-details`},_hoisted_5$133={class:`insurance-name`},_hoisted_6$114={class:`insurance-slogan`},_hoisted_7$101={class:`small-grey-text`},_hoisted_8$85={class:`small-grey-text`},_hoisted_9$75={class:`top-banner-right`},_hoisted_10$65={class:`information-wrapper`},_hoisted_11$58={class:`information-value`},_hoisted_12$47={class:`driver-score-tier`},_hoisted_13$40={class:`premium-effect`},_hoisted_14$37={class:`switching-details-wrapper`},_hoisted_15$35={class:`three-columns-grid`},_hoisted_16$34={class:`switching-column column-leaving`},_hoisted_17$28={class:`column-header`},_hoisted_18$25={class:`column-details`},_hoisted_19$22={class:`detail-item`},_hoisted_20$18={class:`detail-value`},_hoisted_21$16={class:`detail-item`},_hoisted_22$14={class:`detail-item divider-above`},_hoisted_23$13={class:`detail-value-positive`},_hoisted_24$12={class:`detail-item`},_hoisted_25$11={class:`detail-value-negative`},_hoisted_26$9={class:`detail-item divider-above`},_hoisted_27$9={class:`detail-value-positive-bold`},_hoisted_28$8={class:`detail-note`},_hoisted_29$8={class:`switching-column column-vehicle`},_hoisted_30$8={class:`vehicle-display-box`},_hoisted_31$8=[`src`],_hoisted_32$8={class:`column-details`},_hoisted_33$8={class:`detail-item`},_hoisted_34$8={class:`detail-value-bold`},_hoisted_35$7={class:`detail-item`},_hoisted_36$7={class:`detail-value-bold`},_hoisted_37$6={class:`detail-item divider-above`},_hoisted_38$5={class:`detail-value-highlight`},_hoisted_39$5={class:`detail-note`},_hoisted_40$4={class:`switching-column column-joining`},_hoisted_41$4={class:`column-header`},_hoisted_42$3={class:`column-details`},_hoisted_43$3={class:`detail-item`},_hoisted_44$3={class:`detail-value`},_hoisted_45$3={class:`detail-item`},_hoisted_46$1={class:`detail-item divider-above`},_hoisted_47$1={class:`detail-value-negative`},_hoisted_48$1={class:`detail-item divider-above`},_hoisted_49$1={class:`detail-item divider-above`},_hoisted_50$1={class:`detail-value-bold`},_hoisted_51$1={class:`detail-note`},_hoisted_52$1={class:`final-amount-content-row`},_hoisted_53$1={class:`final-amount-label`},_hoisted_54$1={class:`final-amount-breakdown`},_hoisted_55$1={class:`buttons`},_hoisted_56$1={key:0},_sfc_main$279={__name:`changeInsuranceDetails`,props:{insuranceData:{type:Object,required:!0},vehicleInfo:{type:Object,default:()=>({})},driverScoreData:{type:Object,default:()=>({})}},emits:[`return`,`switch`],setup(__props,{emit:__emit}){let{units}=useBridge(),props=__props,emit$1=__emit,premiumSavingPercent=computed(()=>(1-(props.driverScoreData?.tier?.multiplier||1))*100),leavingInfo=computed(()=>props.insuranceData.leavingInsuranceInfo||null),leavingInsuranceName=computed(()=>leavingInfo.value?.currentInsuranceName||`Current Insurance`),tierDropped=computed(()=>leavingInfo.value?leavingInfo.value.discountTierData?.id>leavingInfo.value.newDiscountTierData?.id:!1),tierIncreased=computed(()=>{let current=props.insuranceData.groupDiscountData?.currentTierData?.id||0;return(props.insuranceData.groupDiscountData?.futureTierData?.id||current)>current}),currentTierId=computed(()=>props.insuranceData.groupDiscountData?.currentTierData?.id||0),futureTierId=computed(()=>props.insuranceData.groupDiscountData?.futureTierData?.id||props.insuranceData.groupDiscountData?.currentTierData?.id||0),proRatedPercentage=computed(()=>Math.round(props.insuranceData.proRatedPercentage||100)),driverScoreImpactPercent=computed(()=>(1-(props.driverScoreData?.tier?.multiplier||1))*100),driverScoreImpactClass=computed(()=>driverScoreImpactPercent.value>0?`saving`:driverScoreImpactPercent.value<0?`increase`:`neutral`),driverScoreImpactText=computed(()=>driverScoreImpactPercent.value>0?`↓${driverScoreImpactPercent.value.toFixed(0)}%`:driverScoreImpactPercent.value<0?`↑${Math.abs(driverScoreImpactPercent.value).toFixed(0)}%`:`0%`),renewsEveryFormatted=computed(()=>props.insuranceData?.renewsEvery?units.buildString(`length`,props.insuranceData.renewsEvery*1e3,0):``),renewsInFormatted=computed(()=>props.insuranceData?.renewsIn?units.buildString(`length`,props.insuranceData.renewsIn*1e3,0):``),leavingRenewsInFormatted=computed(()=>leavingInfo.value?.renewsIn?units.buildString(`length`,leavingInfo.value.renewsIn*1e3,0):``),closePopup=()=>{emit$1(`return`,!0)},onSwitchClick=()=>{Lua_default.career_modules_insurance_insurance.changeInvVehInsurance(props.vehicleInfo.invVehId,props.insuranceData.id),emit$1(`return`,!0)};return(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$249,[createBaseVNode(`div`,_hoisted_2$206,[createBaseVNode(`div`,_hoisted_3$180,[_cache[2]||=createBaseVNode(`div`,{class:`title`},` Change Insurance `,-1),createBaseVNode(`div`,_hoisted_4$153,[createBaseVNode(`span`,_hoisted_5$133,toDisplayString(props.insuranceData.name),1),_cache[0]||=createBaseVNode(`span`,{class:`name-slogan-seperator`},null,-1),createBaseVNode(`span`,_hoisted_6$114,` "`+toDisplayString(props.insuranceData.slogan)+`" `,1)]),createBaseVNode(`div`,null,[createBaseVNode(`span`,_hoisted_7$101,` Covers `+toDisplayString(props.insuranceData.carsInsuredCount)+` Vehicles `,1),_cache[1]||=createBaseVNode(`span`,{class:`dot-seperator`},null,-1),createBaseVNode(`span`,_hoisted_8$85,` Renews every `+toDisplayString(renewsEveryFormatted.value),1)])]),createBaseVNode(`div`,_hoisted_9$75,[createBaseVNode(`div`,_hoisted_10$65,[_cache[4]||=createBaseVNode(`div`,{class:`small-grey-text`},` Driver Score `,-1),createBaseVNode(`div`,_hoisted_11$58,toDisplayString(props.driverScoreData.score)+`: `+toDisplayString(props.driverScoreData.tier.risk),1),createBaseVNode(`div`,_hoisted_12$47,toDisplayString(props.driverScoreData.tier.name),1),createBaseVNode(`div`,_hoisted_13$40,[_cache[3]||=createBaseVNode(`span`,{class:`small-grey-text`},` Premium Effect : `,-1),createBaseVNode(`span`,{class:normalizeClass([`premium-effect-value`,{saving:premiumSavingPercent.value>0,increase:premiumSavingPercent.value<0}])},toDisplayString(premiumSavingPercent.value>0?`${premiumSavingPercent.value.toFixed(0)}% saving`:premiumSavingPercent.value<0?`${Math.abs(premiumSavingPercent.value).toFixed(0)}% increase`:`No change`),3)])])])]),createBaseVNode(`div`,_hoisted_14$37,[createBaseVNode(`div`,_hoisted_15$35,[createBaseVNode(`div`,_hoisted_16$34,[createBaseVNode(`div`,_hoisted_17$28,[_cache[5]||=createBaseVNode(`span`,null,`←`,-1),createTextVNode(` Leaving `+toDisplayString(leavingInsuranceName.value),1)]),createBaseVNode(`div`,_hoisted_18$25,[createBaseVNode(`div`,_hoisted_19$22,[_cache[6]||=createBaseVNode(`span`,{class:`detail-label`},`Vehicles:`,-1),createBaseVNode(`span`,_hoisted_20$18,toDisplayString(leavingInfo.value.vehicleCount)+` → `+toDisplayString(leavingInfo.value.newVehicleCount),1)]),createBaseVNode(`div`,_hoisted_21$16,[_cache[7]||=createBaseVNode(`span`,{class:`detail-label`},`Discount Tier:`,-1),createBaseVNode(`span`,{class:normalizeClass([`detail-value`,{"tier-change-down":tierDropped.value}])},toDisplayString(leavingInfo.value.discountTierData.id)+` → `+toDisplayString(leavingInfo.value.newDiscountTierData.id),3)]),createBaseVNode(`div`,_hoisted_22$14,[_cache[9]||=createBaseVNode(`span`,{class:`detail-label`},`Coverage refund:`,-1),createBaseVNode(`span`,_hoisted_23$13,[_cache[8]||=createTextVNode(`+`,-1),createVNode(unref(bngUnit_default),{money:leavingInfo.value.coverageRefundPrice},null,8,[`money`])])]),createBaseVNode(`div`,_hoisted_24$12,[_cache[11]||=createBaseVNode(`span`,{class:`detail-label`},`Cancellation fee (25%):`,-1),createBaseVNode(`span`,_hoisted_25$11,[_cache[10]||=createTextVNode(`-`,-1),createVNode(unref(bngUnit_default),{money:leavingInfo.value.earlyTerminationPenalty},null,8,[`money`])])]),createBaseVNode(`div`,_hoisted_26$9,[_cache[12]||=createBaseVNode(`span`,{class:`detail-label-bold`},`Net Refund:`,-1),createBaseVNode(`span`,_hoisted_27$9,[createVNode(unref(bngUnit_default),{money:leavingInfo.value.netRefundPrice},null,8,[`money`])])]),createBaseVNode(`div`,_hoisted_28$8,toDisplayString(leavingRenewsInFormatted.value)+` unused `,1)])]),createBaseVNode(`div`,_hoisted_29$8,[_cache[16]||=createBaseVNode(`div`,{class:`column-header column-header-center`},`Moving Vehicle`,-1),createBaseVNode(`div`,_hoisted_30$8,[createBaseVNode(`img`,{src:props.vehicleInfo?.thumbnail,alt:``,class:`vehicle-thumbnail`},null,8,_hoisted_31$8)]),createBaseVNode(`div`,_hoisted_32$8,[createBaseVNode(`div`,_hoisted_33$8,[_cache[13]||=createBaseVNode(`span`,{class:`detail-label`},`Vehicle:`,-1),createBaseVNode(`span`,_hoisted_34$8,toDisplayString(props.vehicleInfo.Name),1)]),createBaseVNode(`div`,_hoisted_35$7,[_cache[14]||=createBaseVNode(`span`,{class:`detail-label`},`Value:`,-1),createBaseVNode(`span`,_hoisted_36$7,[createVNode(unref(bngUnit_default),{money:props.vehicleInfo.Value},null,8,[`money`])])]),createBaseVNode(`div`,_hoisted_37$6,[_cache[15]||=createBaseVNode(`span`,{class:`detail-label`},`Joining mid-cycle:`,-1),createBaseVNode(`span`,_hoisted_38$5,`× `+toDisplayString(proRatedPercentage.value)+`%`,1)]),createBaseVNode(`div`,_hoisted_39$5,toDisplayString(renewsInFormatted.value)+` remaining in cycle `,1)])]),createBaseVNode(`div`,_hoisted_40$4,[createBaseVNode(`div`,_hoisted_41$4,[createTextVNode(` Joining `+toDisplayString(props.insuranceData.name)+` `,1),_cache[17]||=createBaseVNode(`span`,null,`→`,-1)]),createBaseVNode(`div`,_hoisted_42$3,[createBaseVNode(`div`,_hoisted_43$3,[_cache[18]||=createBaseVNode(`span`,{class:`detail-label`},`Vehicles:`,-1),createBaseVNode(`span`,_hoisted_44$3,toDisplayString(props.insuranceData.carsInsuredCount)+` → `+toDisplayString(props.insuranceData.carsInsuredCount+1),1)]),createBaseVNode(`div`,_hoisted_45$3,[_cache[19]||=createBaseVNode(`span`,{class:`detail-label`},`Discount Tier:`,-1),createBaseVNode(`span`,{class:normalizeClass([`detail-value`,{"tier-change-up":tierIncreased.value}])},toDisplayString(currentTierId.value)+` → `+toDisplayString(futureTierId.value),3)]),createBaseVNode(`div`,_hoisted_46$1,[_cache[21]||=createBaseVNode(`span`,{class:`detail-label`},`Add vehicle cost:`,-1),createBaseVNode(`span`,_hoisted_47$1,[_cache[20]||=createTextVNode(`+`,-1),createVNode(unref(bngUnit_default),{money:props.insuranceData.addVehiclePrice},null,8,[`money`])])]),createBaseVNode(`div`,_hoisted_48$1,[_cache[22]||=createBaseVNode(`span`,{class:`detail-label`},`Driver Score Impact:`,-1),createBaseVNode(`span`,{class:normalizeClass([`detail-value-impact`,driverScoreImpactClass.value])},toDisplayString(driverScoreImpactText.value),3)]),createBaseVNode(`div`,_hoisted_49$1,[_cache[23]||=createBaseVNode(`span`,{class:`detail-label-bold`},`New Policy Premium:`,-1),createBaseVNode(`span`,_hoisted_50$1,[createVNode(unref(bngUnit_default),{money:props.insuranceData.futurePremiumDetails.totalPriceWithDriverScore},null,8,[`money`])])]),createBaseVNode(`div`,_hoisted_51$1,toDisplayString(renewsInFormatted.value)+` until renewal `,1)])])]),createBaseVNode(`div`,{class:normalizeClass([`final-amount-box`,props.insuranceData.netSwitchingCost>0?`amount-credit`:`amount-payment`])},[createBaseVNode(`div`,_hoisted_52$1,[createBaseVNode(`div`,null,[createBaseVNode(`div`,_hoisted_53$1,toDisplayString(props.insuranceData.netSwitchingCost>0?`Credit Received Today`:`Amount Due Today`),1),createBaseVNode(`div`,_hoisted_54$1,[createVNode(unref(bngUnit_default),{money:leavingInfo.value.netRefundPrice},null,8,[`money`]),_cache[24]||=createTextVNode(` refund - `,-1),createVNode(unref(bngUnit_default),{money:props.insuranceData.addVehiclePrice},null,8,[`money`]),_cache[25]||=createTextVNode(` new cost `,-1)])]),createBaseVNode(`div`,{class:normalizeClass([`final-amount-total`,props.insuranceData.netSwitchingCost<0?`negative`:`positive`])},[createVNode(unref(bngUnit_default),{money:Math.abs(props.insuranceData.netSwitchingCost)},null,8,[`money`])],2)])],2)]),createBaseVNode(`div`,_hoisted_55$1,[createVNode(unref(bngButton_default),{class:`gray-button bigger-button`,accent:`custom`,onClick:closePopup},{default:withCtx(()=>[..._cache[26]||=[createTextVNode(` Cancel `,-1)]]),_:1}),createVNode(unref(bngButton_default),{class:`save-button bigger-button`,accent:`custom`,onClick:onSwitchClick},{default:withCtx(()=>[_cache[27]||=createTextVNode(` Switch for `,-1),props.insuranceData.netSwitchingCost<0?(openBlock(),createElementBlock(`div`,_hoisted_56$1,[createVNode(unref(bngUnit_default),{money:Math.abs(props.insuranceData.netSwitchingCost)},null,8,[`money`])])):createCommentVNode(``,!0)]),_:1})])]))}},changeInsuranceDetails_default=__plugin_vue_export_helper_default(_sfc_main$279,[[`__scopeId`,`data-v-9624a106`]]),_hoisted_1$248={class:`insurance-tiers`},_hoisted_2$205={key:0},_sfc_main$278={__name:`insuranceTiers`,props:{tiers:{type:Array,required:!0},showTier:{type:Boolean,default:!1}},setup(__props){let props=__props;return(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$248,[(openBlock(!0),createElementBlock(Fragment,null,renderList(props.tiers,tier=>(openBlock(),createElementBlock(`div`,{class:`tier`,key:tier.id},[createBaseVNode(`div`,{class:normalizeClass([`tier-discount`,{isCurrent:tier.isCurrent}])},[props.showTier?(openBlock(),createElementBlock(`div`,_hoisted_2$205,` Tier `+toDisplayString(tier.id),1)):createCommentVNode(``,!0),createBaseVNode(`div`,null,toDisplayString(tier.discount*100)+`% `,1)],2)]))),128))]))}},insuranceTiers_default=__plugin_vue_export_helper_default(_sfc_main$278,[[`__scopeId`,`data-v-ccd1e875`]]),_hoisted_1$247={class:`popup-content`},_hoisted_2$204={class:`top-banner`},_hoisted_3$179={class:`top-info`},_hoisted_4$152={class:`top-info-title`},_hoisted_5$132={class:`top-info-policy-name`},_hoisted_6$113={class:`customize-coverage section`},_hoisted_7$100={class:`premium-details section`},_hoisted_8$84={class:`premium-details-content`},_hoisted_9$74={class:`premium-details-left`},_hoisted_10$64={class:`premium-details-label`},_hoisted_11$57={class:`premium-details-right`},_hoisted_12$46={key:0,class:`price-diff-container`},_hoisted_13$39={class:`premium-details-total premium-details-item`},_hoisted_14$36={class:`premium-details-left`},_hoisted_15$34={class:`driver-score-details-wrapper`},_hoisted_16$33={class:`driver-score-details`},_hoisted_17$27={class:`premium-details-right`},_hoisted_18$24={key:0,class:`price-diff-container`},_hoisted_19$21={class:`buttons`},_sfc_main$277={__name:`editPolicy`,props:{insuranceData:{type:Object,required:!0},driverScoreData:{type:Object,required:!0}},emits:[`return`],setup(__props,{emit:__emit}){let props=__props,changedCoverageOptions=ref({}),newPremiumDetails=ref({}),computedNewPremiumDiffs=computed(()=>{if(!newPremiumDetails.value?.items)return{};let diffs={};for(let key in newPremiumDetails.value.items){let newPrice=newPremiumDetails.value.items[key]?.price||0,oldPrice=props.insuranceData.currentPremiumDetails.items[key]?.price||0;diffs[key]={priceDiff:newPrice-oldPrice,newPrice,oldPrice}}return diffs}),computedTotalPriceDiff=computed(()=>newPremiumDetails.value?.totalPrice?newPremiumDetails.value.totalPrice-props.insuranceData.currentPremiumDetails.totalPrice:0),driverScoreColorClass=computed(()=>{let multiplier=props.driverScoreData?.tier?.multiplier;return multiplier?multiplier<1?`driver-score-good`:multiplier>1?`driver-score-bad`:``:``}),hasChangedCoverageOptions=computed(()=>props.insuranceData?.coverageOptionsData?props.insuranceData.coverageOptionsData.some(option=>changedCoverageOptions.value[option.key]!==option.currentValueId):!1);onMounted(()=>{props.insuranceData?.coverageOptionsData&&props.insuranceData.coverageOptionsData.forEach(option=>{changedCoverageOptions.value[option.key]=option.currentValueId})});let emit$1=__emit,closePopup=()=>{emit$1(`return`,!0)},openVehicleList=()=>{addPopup(vehicleInsuranceList_default,{insuranceData:props.insuranceData,driverScoreData:props.driverScoreData}),closePopup()},onSaveClick=()=>{Lua_default.career_modules_insurance_insurance.saveNewInsuranceCoverageOptions(props.insuranceData.id,changedCoverageOptions.value),emit$1(`return`,!0)},updatePremiumDetails=async()=>{newPremiumDetails.value=await Lua_default.career_modules_insurance_insurance.calculateInsurancePremium(props.insuranceData.id,changedCoverageOptions.value,null)},onToggleChange=(coverageOption,newValue)=>{let targetChoiceIndex=coverageOption.choices.findIndex(choice=>choice.value===newValue);targetChoiceIndex!==-1&&(changedCoverageOptions.value[coverageOption.key]=targetChoiceIndex+1,updatePremiumDetails())},onChoiceClick=(coverageOption,choice)=>{changedCoverageOptions.value[coverageOption.key]=choice.id,updatePremiumDetails()};return(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$247,[createBaseVNode(`div`,_hoisted_2$204,[createBaseVNode(`div`,_hoisted_3$179,[createBaseVNode(`div`,_hoisted_4$152,[_cache[0]||=createTextVNode(` Edit Policy: `,-1),createBaseVNode(`span`,_hoisted_5$132,toDisplayString(props.insuranceData.name),1)]),_cache[1]||=createBaseVNode(`div`,{class:`top-info-description`},` These settings apply to all vehicles under this policy. Set deductibles per vehicle by clicking "Edit Vehicles" `,-1)]),createVNode(unref(bngButton_default),{class:`edit-vehicles-button`,accent:`custom`,onClick:openVehicleList},{default:withCtx(()=>[..._cache[2]||=[createTextVNode(` Edit Vehicles `,-1)]]),_:1})]),createBaseVNode(`div`,_hoisted_6$113,[(openBlock(!0),createElementBlock(Fragment,null,renderList(props.insuranceData.coverageOptionsData,coverageOption=>(openBlock(),createBlock(unref(coverageOption_default),{key:coverageOption.name,coverageOption,changedCoverageOptions:changedCoverageOptions.value,onChoiceClick,onToggleChange},null,8,[`coverageOption`,`changedCoverageOptions`]))),128))]),createBaseVNode(`div`,_hoisted_7$100,[_cache[5]||=createBaseVNode(`div`,{class:`premium-details-header`},` Premium Breakdown `,-1),createBaseVNode(`div`,_hoisted_8$84,[(openBlock(!0),createElementBlock(Fragment,null,renderList(props.insuranceData.currentPremiumDetails.items,(detail,key)=>(openBlock(),createElementBlock(`div`,{class:`premium-details-item`,key},[createBaseVNode(`div`,_hoisted_9$74,[createBaseVNode(`div`,_hoisted_10$64,toDisplayString(detail.name),1)]),createBaseVNode(`div`,_hoisted_11$57,[computedNewPremiumDiffs.value[key]&&computedNewPremiumDiffs.value[key].priceDiff!==0?(openBlock(),createElementBlock(`div`,_hoisted_12$46,[createBaseVNode(`span`,{class:normalizeClass([`arrow`,{"green-price":computedNewPremiumDiffs.value[key].priceDiff<0,"red-price":computedNewPremiumDiffs.value[key].priceDiff>0}])},toDisplayString(computedNewPremiumDiffs.value[key].priceDiff>0?`↑`:`↓`),3),createVNode(unref(bngUnit_default),{class:normalizeClass([`price-diff`,{"green-price":computedNewPremiumDiffs.value[key].priceDiff<0,"red-price":computedNewPremiumDiffs.value[key].priceDiff>0}]),money:computedNewPremiumDiffs.value[key].priceDiff},null,8,[`class`,`money`])])):createCommentVNode(``,!0),createVNode(unref(bngUnit_default),{money:newPremiumDetails.value?.items?.[key]?.price||detail.price},null,8,[`money`])])]))),128)),createBaseVNode(`div`,_hoisted_13$39,[createBaseVNode(`div`,_hoisted_14$36,[_cache[4]||=createBaseVNode(`div`,null,` Final Premium `,-1),createBaseVNode(`div`,_hoisted_15$34,[createBaseVNode(`span`,_hoisted_16$33,[_cache[3]||=createTextVNode(` Base Premium : `,-1),createVNode(unref(bngUnit_default),{money:props.insuranceData.currentPremiumDetails.totalPrice},null,8,[`money`]),createTextVNode(` × Driver Score `+toDisplayString(props.driverScoreData.score)+` @ `,1)]),createBaseVNode(`span`,{class:normalizeClass([`driver-score`,driverScoreColorClass.value])},toDisplayString(Math.round(props.driverScoreData.tier.multiplier*100))+`% `,3)])]),createBaseVNode(`div`,_hoisted_17$27,[computedTotalPriceDiff.value===0?createCommentVNode(``,!0):(openBlock(),createElementBlock(`div`,_hoisted_18$24,[createBaseVNode(`span`,{class:normalizeClass([`arrow`,{"green-price":computedTotalPriceDiff.value<0,"red-price":computedTotalPriceDiff.value>0}])},toDisplayString(computedTotalPriceDiff.value>0?`↑`:`↓`),3),createVNode(unref(bngUnit_default),{class:normalizeClass([`price-diff`,{"green-price":computedTotalPriceDiff.value<0,"red-price":computedTotalPriceDiff.value>0}]),money:computedTotalPriceDiff.value},null,8,[`class`,`money`])])),createVNode(unref(bngUnit_default),{money:newPremiumDetails.value?.totalPriceWithDriverScore||props.insuranceData.currentPremiumDetails.totalPriceWithDriverScore},null,8,[`money`])])])])]),createBaseVNode(`div`,_hoisted_19$21,[createVNode(unref(bngButton_default),{class:`cancel-button bigger-button`,accent:`custom`,onClick:closePopup},{default:withCtx(()=>[..._cache[6]||=[createTextVNode(` Cancel `,-1)]]),_:1}),createVNode(unref(bngButton_default),{class:`save-button bigger-button`,accent:`custom`,onClick:onSaveClick,disabled:!props.insuranceData.canPayPaperworkFees||!hasChangedCoverageOptions.value},{default:withCtx(()=>[props.insuranceData.canPayPaperworkFees?(openBlock(),createElementBlock(Fragment,{key:1},[_cache[7]||=createTextVNode(` Apply for `,-1),createVNode(unref(bngUnit_default),{money:props.insuranceData.paperworkFees},null,8,[`money`])],64)):(openBlock(),createElementBlock(Fragment,{key:0},[createTextVNode(` Insufficient funds `)],64))]),_:1},8,[`disabled`])])]))}},editPolicy_default=__plugin_vue_export_helper_default(_sfc_main$277,[[`__scopeId`,`data-v-081fecf3`]]),_sfc_main$276={__name:`insurancePerkIcon`,props:{perkIconData:{type:Object,required:!0}},setup(__props){let props=__props,computedColor=computed(()=>props.perkIconData.isSignaturePerk===void 0?props.perkIconData.color:props.perkIconData.isSignaturePerk?`green`:`blue`);return(_ctx,_cache)=>withDirectives((openBlock(),createElementBlock(`div`,{class:normalizeClass({"insurance-perk-icon":!__props.perkIconData.iconOnly,[computedColor.value]:computedColor.value})},[createVNode(unref(bngIcon_default),{type:unref(icons).shieldCheckmark,class:normalizeClass({"glowing-icon":!0,[computedColor.value]:computedColor.value})},null,8,[`type`,`class`]),__props.perkIconData.iconOnly?createCommentVNode(``,!0):(openBlock(),createElementBlock(`span`,{key:0,class:normalizeClass({"small-text":!0,[computedColor.value]:computedColor.value})},toDisplayString(__props.perkIconData.smallText),3))],2)),[[unref(BngTooltip_default),__props.perkIconData.iconOnly?null:__props.perkIconData.tooltipText,`top`]])}},insurancePerkIcon_default=__plugin_vue_export_helper_default(_sfc_main$276,[[`__scopeId`,`data-v-d2b025b6`]]),_hoisted_1$246={class:`insurance-perks-container`},_hoisted_2$203={class:`left`},_hoisted_3$178={class:`insurance-perk-icon-wrapper`},_hoisted_4$151={key:1},_hoisted_5$131={class:`insurance-perk-texts`},_hoisted_6$112={class:`insurance-perk-intro`},_hoisted_7$99={key:0,class:`insurance-perk-description`},_hoisted_8$83={key:0,class:`signature-perk-wrapper`},_sfc_main$275={__name:`insurancePerks`,props:{insuranceData:Object,noDescription:Boolean},setup(__props){let props=__props,sortedPerks=computed(()=>props.insuranceData.perks?[...Array.isArray(props.insuranceData.perks)?props.insuranceData.perks:Object.values(props.insuranceData.perks)].sort((a$1,b)=>Number(b.isSignaturePerk||!1)-Number(a$1.isSignaturePerk||!1)):[]);return(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$246,[(openBlock(!0),createElementBlock(Fragment,null,renderList(sortedPerks.value,perk=>(openBlock(),createElementBlock(`div`,{key:perk.id,class:normalizeClass([`insurance-perk`,{highlighted:perk.isSignaturePerk,"no-insurance":__props.insuranceData.id===-1}])},[createBaseVNode(`div`,_hoisted_2$203,[createBaseVNode(`div`,_hoisted_3$178,[__props.insuranceData.id===-1?(openBlock(),createElementBlock(`span`,_hoisted_4$151,`-`)):(openBlock(),createBlock(insurancePerkIcon_default,{key:0,perkIconData:{iconOnly:!0,isSignaturePerk:perk.isSignaturePerk&&perk.isSignaturePerk||!1}},null,8,[`perkIconData`]))]),createBaseVNode(`div`,_hoisted_5$131,[createBaseVNode(`div`,_hoisted_6$112,toDisplayString(perk.intro),1),__props.noDescription?createCommentVNode(``,!0):(openBlock(),createElementBlock(`div`,_hoisted_7$99,toDisplayString(perk.description),1))])]),perk.isSignaturePerk?(openBlock(),createElementBlock(`div`,_hoisted_8$83,[..._cache[0]||=[createBaseVNode(`div`,{class:`signature-perk`},` SIGNATURE PERK `,-1)]])):createCommentVNode(``,!0)],2))),128))]))}},insurancePerks_default=__plugin_vue_export_helper_default(_sfc_main$275,[[`__scopeId`,`data-v-75e74910`]]),_hoisted_1$245={class:`insurance-perk-notice`},_sfc_main$274={__name:`insurancePerkNotice`,props:{perkText:{type:String,required:!0}},setup(__props){let props=__props;return(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$245,[createVNode(insurancePerkIcon_default,{perkIconData:{iconOnly:!0}}),createTextVNode(` `+toDisplayString(props.perkText),1)]))}},insurancePerkNotice_default=__plugin_vue_export_helper_default(_sfc_main$274,[[`__scopeId`,`data-v-a98b3238`]]),_hoisted_1$244={class:`popup-content`},_hoisted_2$202={class:`top-info`},_hoisted_3$177={class:`top-info-title`},_hoisted_4$150={class:`top-info-veh-name`},_hoisted_5$130={class:`top-info-value-and-insurance`},_hoisted_6$111={class:`section`},_hoisted_7$98={class:`section`},_hoisted_8$82={class:`contribution-wrapper`},_hoisted_9$73={class:`contribution-item-value`},_hoisted_10$63={key:0,class:`price-diff-container`},_hoisted_11$56={class:`contribution-item-value`},_hoisted_12$45={key:0,class:`price-diff-container`},_hoisted_13$38={class:`buttons`},_sfc_main$273={__name:`editVehicleCoverage`,props:{insuranceData:{type:Object,required:!0},vehicleData:{type:Object,required:!0}},emits:[`return`],setup(__props,{emit:__emit}){let props=__props,newPremiumPrice=ref(0),newInsurancePremiumDetails=ref({totalPriceWithDriverScore:0}),computedNewPremiumDiff=computed(()=>newPremiumPrice.value-props.vehicleData.insuranceData.currentPremiumPrice),computedNewInsurancePremiumDiff=computed(()=>newInsurancePremiumDetails.value.totalPriceWithDriverScore-props.insuranceData.currentPremiumDetails.totalPriceWithDriverScore),hasChangedCoverageOptions=computed(()=>props.vehicleData?.insuranceData?.coverageOptionsData?.currentCoverageOptionsSanitized?props.vehicleData.insuranceData.coverageOptionsData.currentCoverageOptionsSanitized.some(option=>changedCoverageOptions.value[option.key]!==option.currentValueId):!1),emit$1=__emit,closePopup=()=>{emit$1(`return`,!0)},changedCoverageOptions=ref({}),updatePremiumPrice=async()=>{newPremiumPrice.value=(await Lua_default.career_modules_insurance_insurance.calculateVehiclePremium(props.vehicleData.id,null,changedCoverageOptions.value)).cost,newInsurancePremiumDetails.value=await Lua_default.career_modules_insurance_insurance.calculateInsurancePremium(props.insuranceData.id,null,{[props.vehicleData.id]:changedCoverageOptions.value})},onChoiceClick=(coverageOption,choice)=>{changedCoverageOptions.value[coverageOption.key]=choice.id,updatePremiumPrice()},onToggleChange=(coverageOption,newValue)=>{let targetChoiceIndex=coverageOption.choices.findIndex(choice=>choice.value===newValue);targetChoiceIndex!==-1&&(changedCoverageOptions.value[coverageOption.key]=targetChoiceIndex+1),updatePremiumPrice()},onSaveClick=()=>{Lua_default.career_modules_insurance_insurance.saveNewVehicleCoverageOptions(props.vehicleData.id,changedCoverageOptions.value),emit$1(`return`,!0)},openSwitchProvider=()=>{addPopup(ChooseInsuranceMain_default,{menuMode:`change`,params:{vehicleId:props.vehicleData.id}})};return onMounted(()=>{props.vehicleData.insuranceData.coverageOptionsData.currentCoverageOptionsSanitized.forEach(option=>{changedCoverageOptions.value[option.key]=option.currentValueId}),updatePremiumPrice()}),(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$244,[createBaseVNode(`div`,_hoisted_2$202,[createBaseVNode(`div`,_hoisted_3$177,[_cache[0]||=createTextVNode(` Select Deductible: `,-1),createBaseVNode(`span`,_hoisted_4$150,toDisplayString(props.vehicleData.name),1)]),createBaseVNode(`div`,_hoisted_5$130,[_cache[1]||=createTextVNode(` Value: `,-1),createVNode(unref(bngUnit_default),{money:props.vehicleData.initialValue},null,8,[`money`]),createTextVNode(` • Policy: `+toDisplayString(props.insuranceData.name),1)]),_cache[2]||=createBaseVNode(`div`,{class:`top-info-description`},` Choose how much you'll pay out-of-pocket when repairing this vehicle. Lower deductibles cost more per km. `,-1)]),createBaseVNode(`div`,_hoisted_6$111,[_cache[3]||=createBaseVNode(`div`,null,[createBaseVNode(`div`,{class:`header title`},` Choose Your Deductible `),createBaseVNode(`div`,{class:`under-title`},` You pay this amount per repair. `)],-1),createBaseVNode(`div`,null,[(openBlock(!0),createElementBlock(Fragment,null,renderList(props.vehicleData.insuranceData.coverageOptionsData.currentCoverageOptionsSanitized,coverageOption=>(openBlock(),createBlock(unref(coverageOption_default),{class:`coverage-option`,key:coverageOption.name,coverageOption,onlyShowMainText:!0,changedCoverageOptions:changedCoverageOptions.value,dontShowName:!0,onChoiceClick,onToggleChange},null,8,[`coverageOption`,`changedCoverageOptions`]))),128))])]),createBaseVNode(`div`,_hoisted_7$98,[_cache[6]||=createBaseVNode(`div`,{class:`title`},` Policy Impact `,-1),createBaseVNode(`div`,_hoisted_8$82,[createBaseVNode(`div`,{class:normalizeClass([`contribution-item`,{green:computedNewInsurancePremiumDiff.value<0,red:computedNewInsurancePremiumDiff.value>0}])},[_cache[4]||=createBaseVNode(`div`,{class:`contribution-item-title`},` Insurance Premium `,-1),createBaseVNode(`div`,_hoisted_9$73,[createVNode(unref(bngUnit_default),{money:props.insuranceData.currentPremiumDetails.totalPriceWithDriverScore},null,8,[`money`]),computedNewInsurancePremiumDiff.value!==0&&!isNaN(computedNewInsurancePremiumDiff.value)?(openBlock(),createElementBlock(`div`,_hoisted_10$63,` → `)):createCommentVNode(``,!0),computedNewInsurancePremiumDiff.value!==0&&!isNaN(computedNewInsurancePremiumDiff.value)?(openBlock(),createBlock(unref(bngUnit_default),{key:1,money:newInsurancePremiumDetails.value.totalPriceWithDriverScore},null,8,[`money`])):createCommentVNode(``,!0)])],2),createBaseVNode(`div`,{class:normalizeClass([`contribution-item`,{green:computedNewInsurancePremiumDiff.value<0,red:computedNewInsurancePremiumDiff.value>0}])},[_cache[5]||=createBaseVNode(`div`,{class:`contribution-item-title`},` Vehicle Contribution `,-1),createBaseVNode(`div`,_hoisted_11$56,[createVNode(unref(bngUnit_default),{money:props.vehicleData.insuranceData.currentPremiumPrice},null,8,[`money`]),computedNewPremiumDiff.value!==0&&!isNaN(computedNewPremiumDiff.value)?(openBlock(),createElementBlock(`div`,_hoisted_12$45,` → `)):createCommentVNode(``,!0),computedNewPremiumDiff.value!==0&&!isNaN(computedNewPremiumDiff.value)?(openBlock(),createBlock(unref(bngUnit_default),{key:1,money:newPremiumPrice.value},null,8,[`money`])):createCommentVNode(``,!0)])],2)])]),createBaseVNode(`div`,_hoisted_13$38,[createVNode(unref(bngButton_default),{class:`gray-button bigger-button`,accent:`custom`,onClick:closePopup},{default:withCtx(()=>[..._cache[7]||=[createTextVNode(` Cancel `,-1)]]),_:1}),createVNode(unref(bngButton_default),{class:`save-button bigger-button`,accent:`custom`,onClick:onSaveClick,disabled:!props.insuranceData.canPayPaperworkFees||!hasChangedCoverageOptions.value},{default:withCtx(()=>[props.insuranceData.canPayPaperworkFees?(openBlock(),createElementBlock(Fragment,{key:1},[_cache[8]||=createTextVNode(` Apply for `,-1),createVNode(unref(bngUnit_default),{money:props.insuranceData.paperworkFees},null,8,[`money`])],64)):(openBlock(),createElementBlock(Fragment,{key:0},[createTextVNode(` Insufficient funds `)],64))]),_:1},8,[`disabled`]),createVNode(unref(bngButton_default),{class:`gray-button bigger-button`,accent:`custom`,onClick:openSwitchProvider},{default:withCtx(()=>[..._cache[9]||=[createTextVNode(` Switch Provider `,-1)]]),_:1})])]))}},editVehicleCoverage_default=__plugin_vue_export_helper_default(_sfc_main$273,[[`__scopeId`,`data-v-9f014d2d`]]),_hoisted_1$243=[`innerHTML`],_hoisted_2$201={key:2,class:`insurance-icon`},_hoisted_3$176={class:`insurance-name`},_hoisted_4$149={key:3,class:`insurance-slogan`},_sfc_main$272={__name:`insuranceIdentity`,props:{insuranceData:{type:Object,required:!0}},setup(__props){let props=__props,hasInsurance=computed(()=>svgContent.value||props.insuranceData.image),hasNoInsurance=computed(()=>props.insuranceData?.id===-1),svgContent=ref(null);return watch(()=>props.insuranceData.image,async newPath=>{if(newPath&&newPath.endsWith(`.svg`))try{let rawSvg=await getFile(`/${newPath}`);rawSvg?svgContent.value=rawSvg.replace(/]*>([\s\S]*?)<\/script>/gim,``).replace(/ on\w+="[^"]*"/g,``):svgContent.value=null}catch(e){console.warn(`Failed to load SVG inline:`,newPath,e),svgContent.value=null}else svgContent.value=null},{immediate:!0}),(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,{class:normalizeClass([`insurance-identity`,{"no-insurance":!hasInsurance.value}])},[svgContent.value?(openBlock(),createElementBlock(`div`,{key:0,class:`insurance-icon`,innerHTML:svgContent.value},null,8,_hoisted_1$243)):props.insuranceData.image?(openBlock(),createBlock(unref(bngImage_default),{key:1,class:`insurance-icon`,src:`/${props.insuranceData.image}`,alt:props.insuranceData.name},null,8,[`src`,`alt`])):(openBlock(),createElementBlock(`div`,_hoisted_2$201,[createBaseVNode(`div`,_hoisted_3$176,[createVNode(unref(bngIcon_default),{class:`insurance-no-icon`,type:unref(icons).danger},null,8,[`type`]),createTextVNode(` `+toDisplayString(hasNoInsurance.value?_ctx.$t(`ui.career.insurance.noInsurance`):props.insuranceData.name),1)])])),hasNoInsurance.value?createCommentVNode(``,!0):(openBlock(),createElementBlock(`div`,_hoisted_4$149,` "`+toDisplayString(props.insuranceData.slogan)+`" `,1))],2))}},insuranceIdentity_default=__plugin_vue_export_helper_default(_sfc_main$272,[[`__scopeId`,`data-v-689b89ea`]]),_hoisted_1$242={key:1,class:`coverage-option-name`},_hoisted_2$200={key:2,class:`choices`},_hoisted_3$175=[`onClick`],_hoisted_4$148={class:`choice-label`},_hoisted_5$129={key:0},_hoisted_6$110={key:0,class:`choice-secondary-text`},_hoisted_7$97={key:1,class:`choice-price`},_hoisted_8$81={key:3,class:`toggle-container`},_hoisted_9$72={class:`toggle-price`},_sfc_main$271={__name:`coverageOption`,props:{coverageOption:{type:Object,required:!0},changedCoverageOptions:{type:Object,required:!1,default:()=>({})},onlyShowMainText:{type:Boolean,default:!1},simpleSelect:{type:Boolean},modelValue:{type:Number,required:!1},showPerkMode:{type:String,default:`deportedLabel`},dontShowName:{type:Boolean,default:!1}},emits:[`choiceClick`,`toggleChange`,`update:modelValue`],setup(__props,{emit:__emit}){let props=__props,emit$1=__emit;watch(()=>props.coverageOption?.choices,newChoices=>{if(props.modelValue!==void 0&&props.modelValue!==null&&newChoices){let maxValidId=newChoices.length;props.modelValue>maxValidId&&emit$1(`update:modelValue`,1)}},{immediate:!0});let getSelectedValueId=()=>props.modelValue!==void 0&&props.modelValue!==null?Math.min(props.modelValue,props.coverageOption.choices.length):props.changedCoverageOptions[props.coverageOption.key],getToggleValue=coverageOption=>(props.changedCoverageOptions[coverageOption.key]??coverageOption.currentValueId)===coverageOption.choices.findIndex(choice=>choice.value===!0)+1,getTogglePrice=coverageOption=>{let selectedValueId=props.changedCoverageOptions[coverageOption.key]??coverageOption.currentValueId;return coverageOption.choices[selectedValueId-1]?.premiumInfluence||0},onToggleChange=(coverageOption,newValue)=>{emit$1(`toggleChange`,coverageOption,newValue)},onChoiceClick=(coverageOption,choice)=>{choice.disabled||(props.simpleSelect&&(coverageOption.currentValueId=choice.id),props.modelValue!==void 0&&props.modelValue!==null&&emit$1(`update:modelValue`,choice.id),emit$1(`choiceClick`,coverageOption,choice))};return(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,{class:normalizeClass([`coverage-options`,{"in-row":__props.coverageOption.choiceType===`toggle`}])},[__props.coverageOption.perkText&&__props.showPerkMode===`deportedLabel`?(openBlock(),createBlock(unref(insurancePerkNotice_default),{key:0,perkText:__props.coverageOption.perkText},null,8,[`perkText`])):createCommentVNode(``,!0),__props.dontShowName?createCommentVNode(``,!0):(openBlock(),createElementBlock(`div`,_hoisted_1$242,toDisplayString(__props.coverageOption.name),1)),__props.coverageOption.choiceType===`multiple`?(openBlock(),createElementBlock(`div`,_hoisted_2$200,[(openBlock(!0),createElementBlock(Fragment,null,renderList(__props.coverageOption.choices,choice=>(openBlock(),createElementBlock(`div`,{class:normalizeClass([`choice`,{selected:choice.id===__props.changedCoverageOptions[__props.coverageOption.key],current:choice.id===getSelectedValueId(),disabled:choice.disabled}]),key:choice,onClick:()=>onChoiceClick(__props.coverageOption,choice)},[createBaseVNode(`div`,_hoisted_4$148,toDisplayString(choice.choiceText),1),__props.onlyShowMainText?createCommentVNode(``,!0):(openBlock(),createElementBlock(`div`,_hoisted_5$129,[choice.secondaryText?(openBlock(),createElementBlock(`div`,_hoisted_6$110,toDisplayString(choice.secondaryText),1)):(openBlock(),createElementBlock(`div`,_hoisted_7$97,[createVNode(unref(bngUnit_default),{money:choice.premiumInfluence},null,8,[`money`])]))]))],10,_hoisted_3$175))),128))])):__props.coverageOption.choiceType===`toggle`?(openBlock(),createElementBlock(`div`,_hoisted_8$81,[createVNode(unref(bngSwitch_default),{class:`toggle-switch`,"model-value":getToggleValue(__props.coverageOption),onChange:_cache[0]||=newValue=>onToggleChange(__props.coverageOption,newValue)},null,8,[`model-value`]),createBaseVNode(`div`,_hoisted_9$72,[createVNode(unref(bngUnit_default),{money:getTogglePrice(__props.coverageOption)},null,8,[`money`])])])):createCommentVNode(``,!0)],2))}},coverageOption_default=__plugin_vue_export_helper_default(_sfc_main$271,[[`__scopeId`,`data-v-4921f4f0`]]),_hoisted_1$241={class:`popup-content`},_hoisted_2$199={class:`popup-header`},_hoisted_3$174={class:`top-info`},_hoisted_4$147={class:`top-info-title`},_hoisted_5$128={class:`top-info-policy-name`},_hoisted_6$109={class:`top-info-description`},_hoisted_7$96={class:`vehicle-list`},_hoisted_8$80={class:`closeButton`},_sfc_main$270={__name:`vehicleInsuranceList`,props:{insuranceData:{type:Object,required:!0},driverScoreData:{type:Object,required:!0}},emits:[`return`],setup(__props,{emit:__emit}){let props=__props,emit$1=__emit,closePopup=()=>{emit$1(`return`,!0)},openEditVehicleCoverage=vehicle=>{addPopup(editVehicleCoverage_default,{insuranceData:props.insuranceData,vehicleData:vehicle})},openEditPolicy=()=>{addPopup(editPolicy_default,{insuranceData:props.insuranceData,driverScoreData:props.driverScoreData}),closePopup()};return(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$241,[createBaseVNode(`div`,_hoisted_2$199,[createBaseVNode(`div`,_hoisted_3$174,[createBaseVNode(`div`,_hoisted_4$147,[_cache[0]||=createTextVNode(` Vehicles Insured By `,-1),createBaseVNode(`span`,_hoisted_5$128,toDisplayString(props.insuranceData.name),1)]),createBaseVNode(`div`,_hoisted_6$109,[_cache[1]||=createTextVNode(` Click any vehicle to adjust its deductible • Total Value: `,-1),createVNode(unref(bngUnit_default),{money:props.insuranceData.totalInsuranceVehsValue},null,8,[`money`])])]),createVNode(unref(bngButton_default),{class:`policy-coverage-button`,accent:`custom`,onClick:openEditPolicy},{default:withCtx(()=>[..._cache[2]||=[createTextVNode(` Policy Coverage `,-1)]]),_:1})]),createBaseVNode(`div`,_hoisted_7$96,[(openBlock(!0),createElementBlock(Fragment,null,renderList(props.insuranceData.carsInsured,(vehicle,index)=>(openBlock(),createBlock(unref(insuranceVehTile_default),{key:index,vehicle},{rightContent:withCtx(()=>[createVNode(unref(bngButton_default),{class:`edit-coverage-button bigger-button`,accent:`custom`,disabled:vehicle.needsRepair,onClick:$event=>!vehicle.needsRepair&&openEditVehicleCoverage(vehicle)},{default:withCtx(()=>[createTextVNode(toDisplayString(vehicle.needsRepair?`Edit Coverage (Needs repair)`:`Edit Coverage`),1)]),_:2},1032,[`disabled`,`onClick`])]),_:2},1032,[`vehicle`]))),128))]),createBaseVNode(`div`,_hoisted_8$80,[createVNode(unref(bngButton_default),{class:`close-button`,accent:`custom`,onClick:closePopup},{default:withCtx(()=>[..._cache[3]||=[createTextVNode(` Cancel `,-1)]]),_:1})])]))}},vehicleInsuranceList_default=__plugin_vue_export_helper_default(_sfc_main$270,[[`__scopeId`,`data-v-2bd92225`]]),_hoisted_1$240={class:`vehicle-item`},_hoisted_2$198={class:`left`},_hoisted_3$173={class:`vehicle-thumbnail-wrapper`},_hoisted_4$146=[`src`],_hoisted_5$127={class:`name-value-wrapper`},_hoisted_6$108={class:`vehicle-name`},_hoisted_7$95={class:`vehicle-value`},_hoisted_8$79={class:`right`},_sfc_main$269={__name:`insuranceVehTile`,props:{vehicle:{type:Object,required:!0}},setup(__props){return(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$240,[createBaseVNode(`div`,_hoisted_2$198,[createBaseVNode(`div`,_hoisted_3$173,[createBaseVNode(`img`,{src:__props.vehicle.thumbnail,alt:``,class:`vehicle-thumbnail`},null,8,_hoisted_4$146)]),createBaseVNode(`div`,_hoisted_5$127,[createBaseVNode(`div`,_hoisted_6$108,toDisplayString(__props.vehicle.name),1),createBaseVNode(`div`,_hoisted_7$95,[_cache[0]||=createTextVNode(`Value : `,-1),createVNode(unref(bngUnit_default),{money:__props.vehicle.initialValue},null,8,[`money`])]),renderSlot(_ctx.$slots,`extra-info`,{},void 0,!0)])]),createBaseVNode(`div`,_hoisted_8$79,[renderSlot(_ctx.$slots,`rightContent`,{},void 0,!0)])]))}},insuranceVehTile_default=__plugin_vue_export_helper_default(_sfc_main$269,[[`__scopeId`,`data-v-b4076016`]]),_hoisted_1$239={class:`popup-content`},_hoisted_2$197={key:0,class:`vehicle-list`},_hoisted_3$172={key:1,class:`no-vehicles-wrapper`},_hoisted_4$145={class:`closeButton`},_sfc_main$268={__name:`uninsuredVehicles`,props:{uninsuredData:{type:Object,required:!0}},emits:[`return`],setup(__props,{emit:__emit}){let props=__props,emit$1=__emit,closePopup=()=>{emit$1(`return`,!0)},openAddCoverage=vehicle=>{addPopup(ChooseInsuranceMain_default,{menuMode:`change`,params:{vehicleId:vehicle.id}})};return(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$239,[_cache[5]||=createBaseVNode(`div`,{class:`popup-header`},[createBaseVNode(`span`,{class:`header-title`},`Uninsured Vehicles`)],-1),_cache[6]||=createBaseVNode(`div`,{class:`warning-message`},` These vehicles have no insurance coverage. Add coverage to protect against repair costs. `,-1),props.uninsuredData.carsUninsured&&props.uninsuredData.carsUninsured.length>0?(openBlock(),createElementBlock(`div`,_hoisted_2$197,[(openBlock(!0),createElementBlock(Fragment,null,renderList(props.uninsuredData.carsUninsured,(vehicle,index)=>(openBlock(),createBlock(unref(insuranceVehTile_default),{key:index,vehicle,class:`uninsured-vehicle-item`},{"extra-info":withCtx(()=>[..._cache[0]||=[createBaseVNode(`div`,{class:`no-coverage-warning`},` No coverage - you pay full repair costs `,-1)]]),rightContent:withCtx(()=>[createVNode(unref(bngButton_default),{class:`add-coverage-button bigger-button`,accent:`custom`,onClick:$event=>openAddCoverage(vehicle)},{default:withCtx(()=>[createVNode(unref(bngIcon_default),{class:`button-icon`,type:unref(icons).shieldCheckmark},null,8,[`type`]),_cache[1]||=createTextVNode(` Add Coverage `,-1)]),_:1},8,[`onClick`])]),_:2},1032,[`vehicle`]))),128))])):(openBlock(),createElementBlock(`div`,_hoisted_3$172,[createVNode(unref(bngIcon_default),{class:`success-icon`,type:unref(icons).checkmark},null,8,[`type`]),_cache[2]||=createBaseVNode(`div`,{class:`success-title`},`All Vehicles Insured`,-1),_cache[3]||=createBaseVNode(`div`,{class:`success-message`},`You don't have any uninsured vehicles.`,-1)])),createBaseVNode(`div`,_hoisted_4$145,[createVNode(unref(bngButton_default),{class:`close-button`,accent:`custom`,onClick:closePopup},{default:withCtx(()=>[..._cache[4]||=[createTextVNode(` Back `,-1)]]),_:1})])]))}},uninsuredVehicles_default=__plugin_vue_export_helper_default(_sfc_main$268,[[`__scopeId`,`data-v-f51ead8e`]]),sharedMode=ref(null),sharedContext=ref(null);function useChooseInsurance(){let{events:events$3}=useBridge(),insurancesData=ref([]),purchaseData=ref({}),vehicleInfo=ref({}),defaultInsuranceId=ref(null),firstSelectedInsuranceId=ref(null),driverScoreData=ref({}),currentInsuranceId=ref(null),handleChooseInsuranceData=data=>{insurancesData.value=data.applicableInsurancesData,purchaseData.value=data.purchaseData,vehicleInfo.value=data.vehicleInfo,driverScoreData.value=data.driverScoreData,defaultInsuranceId.value=data.defaultInsuranceId,firstSelectedInsuranceId.value=data.defaultInsuranceId,currentInsuranceId.value=data.currentInsuranceId};function openChooseInsuranceMenu(menuMode,params){sharedMode.value=menuMode,sharedContext.value=params,Lua_default.career_modules_insurance_insurance.openChooseInsuranceScreen()}function requestDataForCurrentContext(){sharedMode.value===`purchase`&&sharedContext.value?Lua_default.career_modules_insurance_insurance.sendChooseInsuranceDataToTheUI(sharedContext.value.purchaseType,sharedContext.value.shopId,sharedContext.value.insuranceId):sharedMode.value===`change`&&sharedContext.value&&Lua_default.career_modules_insurance_insurance.sendChangeInsuranceDataToTheUI(sharedContext.value.vehicleId)}return events$3.on(`chooseInsuranceData`,handleChooseInsuranceData),onUnmounted(()=>{events$3.off(`chooseInsuranceData`,handleChooseInsuranceData)}),{openChooseInsuranceMenu,requestDataForCurrentContext,insurancesData,purchaseData,vehicleInfo,defaultInsuranceId,firstSelectedInsuranceId,driverScoreData,currentInsuranceId,mode:sharedMode,context:sharedContext}}var _hoisted_1$238={class:`popup-content`},_hoisted_2$196={class:`popup-header`},_hoisted_3$171={class:`content-wrapper`},_hoisted_4$144={class:`buttons-wrapper`},_hoisted_5$126={class:`button-container`},_sfc_main$267={__name:`ChooseInsuranceMain`,props:{menuMode:{type:String,required:!0},params:{type:Object,required:!0}},emits:[`return`],setup(__props,{emit:__emit}){useUINavBlocker().ensureNoBlock([`tab_l`,`tab_r`]);let overflowRef=ref(null),onTabNav=evt=>{evt.detail.value===1&&(console.log(`onTabNav`,evt.detail),console.log(`overflowRef`,overflowRef.value),evt.detail.name===`tab_l`&&overflowRef.value?.activatePrev(),evt.detail.name===`tab_r`&&overflowRef.value?.activateNext())},props=__props,emit$1=__emit,{units}=useBridge(),selectedInsuranceId=ref(null),selectedShelfIndex=ref(0),{insurancesData,purchaseData,defaultInsuranceId,firstSelectedInsuranceId,vehicleInfo,requestDataForCurrentContext,mode,context,driverScoreData,currentInsuranceId}=useChooseInsurance();onMounted(()=>{window.addEventListener(DOM_UI_NAVIGATION_EVENT,onTabNav),mode.value=props.menuMode,context.value=props.params,props.menuMode===`purchase`&&props.params?Lua_default.career_modules_insurance_insurance.sendChooseInsuranceDataToTheUI(props.params.purchaseType,props.params.shopId,props.params.insuranceId):props.menuMode===`change`&&props.params&&Lua_default.career_modules_insurance_insurance.sendChangeInsuranceDataToTheUI(props.params.vehicleId)}),watch(selectedShelfIndex,newIndex=>{insurancesData.value[newIndex]&&(selectedInsuranceId.value=insurancesData.value[newIndex].id)}),watch(defaultInsuranceId,defaultId=>{if(defaultId!==null){selectedInsuranceId.value=defaultId;let index=insurancesData.value.findIndex(ins=>ins.id===defaultId);index!==-1&&(selectedShelfIndex.value=index)}},{immediate:!0});let onShelfClick=(insuranceId,index)=>{selectedInsuranceId.value=insuranceId,selectedShelfIndex.value=index},buttonText=computed(()=>mode.value===`change`?selectedInsuranceId.value===-1?`Remove Coverage`:selectedInsuranceId.value===currentInsuranceId.value?`Current Provider`:`Move vehicle here`:`Select this option`),viewCostBreakdown=()=>{mode.value===`purchase`?addPopup(purchaseInsuranceDetails_default,{insuranceData:insurancesData.value[selectedShelfIndex.value],vehicleInfo:vehicleInfo.value,driverScoreData:driverScoreData.value}):addPopup(changeInsuranceDetails_default,{insuranceData:insurancesData.value[selectedShelfIndex.value],vehicleInfo:vehicleInfo.value,driverScoreData:driverScoreData.value})},continueWithInsurance=()=>{mode.value===`purchase`?(selectedInsuranceId.value!==null&&selectedInsuranceId.value!==void 0&&Lua_default.career_modules_vehicleShopping.updateInsuranceSelection(selectedInsuranceId.value),emit$1(`return`,!0)):mode.value===`change`&&(selectedInsuranceId.value&&context.value?.vehicleId&&Lua_default.career_modules_insurance_insurance.changeInvVehInsurance(context.value.vehicleId,selectedInsuranceId.value),closeLastPopups(3))},cancel=()=>{emit$1(`return`,!0)};return onUnmounted(()=>{window.removeEventListener(DOM_UI_NAVIGATION_EVENT,onTabNav),mode.value=null,context.value=null}),(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$238,[createBaseVNode(`div`,_hoisted_2$196,[createVNode(unref(bngCardHeading_default),{type:`ribbon`},{default:withCtx(()=>[createTextVNode(toDisplayString(unref(mode)===`purchase`?`Insure your `:`Switch insurance for your `)+` `+toDisplayString(unref(vehicleInfo).Name),1)]),_:1})]),createBaseVNode(`div`,_hoisted_3$171,[createVNode(unref(bngOverflowContainer_default),{ref_key:`overflowRef`,ref:overflowRef,class:`insurance-shelf`,"scroll-speed":10,"initial-index":selectedShelfIndex.value,"use-bindings-only":``,"show-arrows":``,"no-wheel":``},{default:withCtx(()=>[(openBlock(!0),createElementBlock(Fragment,null,renderList(unref(insurancesData),(insurance,index)=>(openBlock(),createBlock(unref(insuranceCard_default),{key:insurance.id,insuranceData:insurance,isSelected:selectedInsuranceId.value===insurance.id,vehicleInfo:unref(vehicleInfo),isCurrentProvider:unref(mode)===`change`&&unref(currentInsuranceId)===insurance.id,class:`insurance-card`,onClick:$event=>onShelfClick(insurance.id,index)},null,8,[`insuranceData`,`isSelected`,`vehicleInfo`,`isCurrentProvider`,`onClick`]))),128))]),_:1},8,[`initial-index`])]),createBaseVNode(`div`,_hoisted_4$144,[createBaseVNode(`div`,_hoisted_5$126,[createVNode(unref(bngButton_default),{onClick:cancel,accent:unref(ACCENTS).attention},{default:withCtx(()=>[..._cache[0]||=[createTextVNode(`Cancel`,-1)]]),_:1},8,[`accent`]),createVNode(unref(bngButton_default),{onClick:viewCostBreakdown,disabled:selectedShelfIndex.value===0||unref(mode)===`change`&&selectedInsuranceId.value===unref(currentInsuranceId),accent:unref(ACCENTS).secondary},{default:withCtx(()=>[..._cache[1]||=[createTextVNode(`View Cost Breakdown`,-1)]]),_:1},8,[`disabled`,`accent`]),createVNode(unref(bngButton_default),{disabled:!selectedInsuranceId.value||unref(mode)===`change`&&selectedInsuranceId.value===unref(currentInsuranceId),onClick:continueWithInsurance},{default:withCtx(()=>[createTextVNode(toDisplayString(buttonText.value),1)]),_:1},8,[`disabled`])])])]))}},ChooseInsuranceMain_default=__plugin_vue_export_helper_default(_sfc_main$267,[[`__scopeId`,`data-v-7bb3e442`]]),_hoisted_1$237={class:`progress-view-actions`},_hoisted_2$195={class:`progress-view-page`},_hoisted_3$170={class:`progress-view-header`},_hoisted_4$143={class:`branch-icon-assembly large`},_hoisted_5$125={key:0,class:`reward-multiplier`},_hoisted_6$107={class:`reward-multiplier-label`},_hoisted_7$94={class:`reward-multiplier-value`},_hoisted_8$78={class:`progress-view-contents`},_hoisted_9$71={class:`progress-view-description`},_hoisted_10$62={class:`progress-view-scrollable`},_sfc_main$266={__name:`ProgressView`,props:{skillInfo:{type:Object,default:null},headingText:{type:String,default:``},breadcrumbItems:{type:Array,required:!0},branchStyle:{type:Object,required:!0},showBackButton:{type:Boolean,default:!0}},emits:[`breadcrumb-click`,`breadcrumb-back`,`exit`,`skill-click`],setup(__props,{emit:__emit}){let emit$1=__emit,handleBreadcrumbClick=item=>{emit$1(`breadcrumb-click`,item)},handleBreadcrumbBack=()=>{emit$1(`breadcrumb-back`)},handleExit=()=>{emit$1(`exit`)};return(_ctx,_cache)=>withDirectives((openBlock(),createBlock(unref(layoutSingle_default),{class:`progress-view-layout`},{default:withCtx(()=>[withDirectives((openBlock(),createElementBlock(`div`,{class:`progress-view-wrapper`,style:normalizeStyle(__props.branchStyle),"bng-ui-scope":`progressView`},[createBaseVNode(`div`,_hoisted_1$237,[createVNode(unref(bngBreadcrumbs_default),{class:`progress-view-breadcrumbs`,items:__props.breadcrumbItems,limit:`5`,simple:``,"disable-last-item":``,"show-back-button":__props.showBackButton,onClick:handleBreadcrumbClick,onBack:handleBreadcrumbBack},null,8,[`items`,`show-back-button`]),createVNode(unref(careerStatus_default),{class:`progress-view-career-status`,slim:``})]),createBaseVNode(`div`,_hoisted_2$195,[createBaseVNode(`div`,_hoisted_3$170,[__props.skillInfo?(openBlock(),createElementBlock(Fragment,{key:0},[createBaseVNode(`div`,{class:normalizeClass([`header-skill`,{"is-locked":!__props.skillInfo.unlocked}]),onClick:_cache[0]||=$event=>_ctx.$emit(`skill-click`,__props.skillInfo.id)},[createBaseVNode(`div`,_hoisted_4$143,[createBaseVNode(`div`,{class:`branch-background`,style:normalizeStyle(unref(getIconBackgroundStyle)(__props.skillInfo.color))},null,4),createVNode(unref(bngIcon_default),{type:unref(icons)[__props.skillInfo.unlocked?__props.skillInfo.icon:`lockClosed`],class:`assembly-icon large`},null,8,[`type`])]),createVNode(BranchSkillProgressBar_default,{class:`main-stat-progress-bar skill-progress-bar`,skill:__props.skillInfo,showLevel:!1,mode:`with-value-label`,showLockedIcon:!0,isMainProgress:!0},null,8,[`skill`])],2),__props.skillInfo.rewardMultiplier?(openBlock(),createElementBlock(`div`,_hoisted_5$125,[createBaseVNode(`div`,_hoisted_6$107,[createVNode(unref(bngIcon_default),{type:__props.skillInfo.rewardMultiplierSourceIcon},null,8,[`type`]),_cache[1]||=createTextVNode(` Reward Multiplier: `,-1)]),createBaseVNode(`div`,_hoisted_7$94,[createVNode(unref(bngIcon_default),{type:unref(icons).beamCurrency},null,8,[`type`]),createTextVNode(` ×`+toDisplayString(__props.skillInfo.rewardMultiplier.toFixed(2)),1)])])):createCommentVNode(``,!0)],64)):(openBlock(),createBlock(unref(bngScreenHeadingV2_default),{key:1,type:`2`,class:`header-title-v2`},{default:withCtx(()=>[createTextVNode(toDisplayString(__props.headingText),1)]),_:1}))]),createBaseVNode(`div`,_hoisted_8$78,[createBaseVNode(`div`,_hoisted_9$71,[renderSlot(_ctx.$slots,`description`,{},void 0,!0)]),_cache[2]||=createBaseVNode(`div`,{class:`progress-view-divider`},null,-1),createBaseVNode(`div`,_hoisted_10$62,[renderSlot(_ctx.$slots,`default`,{},void 0,!0)])])])],4)),[[unref(BngOnUiNav_default),handleExit,`back,menu`]])]),_:3})),[[unref(BngOnUiNav_default),handleExit,`back,menu`],[unref(BngBlur_default)]])}},ProgressView_default=__plugin_vue_export_helper_default(_sfc_main$266,[[`__scopeId`,`data-v-3fa921dc`]]),_hoisted_1$236={class:`description-text`},_hoisted_2$194={key:0,class:`cards-container grid-view`},_hoisted_3$169={key:1,class:`page-progress`},_hoisted_4$142={key:2,class:`facility-rows`},_hoisted_5$124={key:3,class:`buttons-container`},_hoisted_6$106={class:`content`},_hoisted_7$93={key:0,class:`indicator`},_sfc_main$265={__name:`ProgressLanding`,props:{pathId:String,comesFromBigMap:{type:Boolean,default:!1}},setup(__props){let props=__props,landingData=ref({heading:`ui.career.landingPage.name`,description:`ui.career.landingPage.description`,branches:[],showMilestones:!0,showOrganizations:!0}),leagues=ref([]),fetchLandingData=async()=>{landingData.value={heading:`ui.career.landingPage.name`,description:`ui.career.landingPage.description`,branches:[],showMilestones:!0,showOrganizations:!0};let data=await Lua_default.career_modules_branches_landing.getLandingPageData(props.pathId);landingData.value=data,leagues.value=data.leagues||[],console.log(`data`,data),data.breadcrumbs&&(screenHeaderPath.value=data.breadcrumbs,console.log(`screenHeaderPath`,screenHeaderPath.value))},hasUnclaimedMilestones=ref(!1);onMounted(async()=>{await fetchLandingData(),Lua_default.career_modules_milestones_milestones.unclaimedMilestonesCount().then(c=>hasUnclaimedMilestones.value=c)}),onBeforeMount(()=>{Lua_default.simTimeAuthority.pushPauseRequest(`progressLanding`)}),onUnmounted(()=>{Lua_default.simTimeAuthority.popPauseRequest(`progressLanding`)}),watch(()=>props.pathId,async(newPathId,oldPathId)=>{newPathId!==oldPathId&&(await fetchLandingData(),Lua_default.career_modules_milestones_milestones.unclaimedMilestonesCount().then(c=>hasUnclaimedMilestones.value=c))});let leagueMissionClicked=mission=>{mission.canStartFromProgressScreen?(Lua_default.extensions.gameplay_missions_missionScreen.setPreselectedMissionId(mission.id),Lua_default.extensions.gameplay_missions_missionScreen.openAPMChallenges(props.pathId,mission.skill[0])):Lua_default.extensions.gameplay_missions_missionScreen.navigateToMission(mission.id)},branchStyle=computed(()=>landingData.value.skillInfo?getBranchColorStyle({color:landingData.value.skillInfo.color,accentColor:landingData.value.skillInfo.accentColor}):{"--branch-accent-color":`var(--bng-cool-gray-500-rgb)`,"--branch-color":`var(--bng-cool-gray-500-rgb)`}),pageHeading=computed(()=>landingData.value.branchHeading||landingData.value.heading),currentDescription=ref(null),pageDescription=computed(()=>currentDescription.value||landingData.value.description),BRANCHES=computed(()=>landingData.value.branches),openBranchPage=branchKey=>{let target=landingData.value.branches.find(b=>b.id===branchKey).target;console.log(`openBranchPage`,branchKey),window.bngVue.gotoGameState(`progressLanding`,{params:{pathId:branchKey}})},exit=()=>{props.pathId&&!props.comesFromBigMap?router_default.back():window.bngVue.gotoAngularState(`menu.careerPause`)},openMilestonesScreen=()=>window.bngVue.gotoGameState(`milestones`),onBranchFocus=branch=>{currentDescription.value=branch.description},onBranchBlur=()=>{currentDescription.value=null},isHalfBranch=branch=>{let hasSkills=branch.skills&&branch.skills.length>0,hasDescription=branch.shortDescription;return!hasSkills&&!hasDescription},currentSkillToShow=computed(()=>landingData.value.skillInfo||null),screenHeaderPath=ref([{label:`Career`,path:`/career`},{label:landingData.value.heading,path:`/career/${landingData.value.id}`}]),gotoHeaderItem=item=>{item.gotoPath&&(window.bngVue.gotoGameState(item.gotoPath.path,{params:item.gotoPath.props}),console.log(`gotoPath`,item.gotoPath)),item.gotoAngularState&&window.bngVue.gotoAngularState(item.gotoAngularState)},onBreadBack=()=>{gotoHeaderItem(screenHeaderPath.value[screenHeaderPath.value.length-2])};return(_ctx,_cache)=>(openBlock(),createBlock(ProgressView_default,{"skill-info":landingData.value.skillInfo,"heading-text":_ctx.$t(pageHeading.value),"breadcrumb-items":screenHeaderPath.value,"branch-style":branchStyle.value,"show-back-button":!0,onBreadcrumbClick:gotoHeaderItem,onBreadcrumbBack:onBreadBack,onExit:exit},{description:withCtx(()=>[createBaseVNode(`div`,_hoisted_1$236,toDisplayString(_ctx.$t(pageDescription.value)),1)]),default:withCtx(()=>[BRANCHES.value.length>0?(openBlock(),createElementBlock(`div`,_hoisted_2$194,[(openBlock(!0),createElementBlock(Fragment,null,renderList(BRANCHES.value,branch=>withDirectives((openBlock(),createBlock(BranchSkillCard_default,{tabindex:`1`,branchKey:branch.id,onOpenBranchPage:openBranchPage,onMouseenter:$event=>onBranchFocus(branch),onMouseleave:onBranchBlur,onFocus:$event=>onBranchFocus(branch),onBlur:onBranchBlur,"bng-nav-item":``,"display-mode":`row`,class:normalizeClass({"full-width":!isHalfBranch(branch)})},null,8,[`branchKey`,`onMouseenter`,`onFocus`,`class`])),[[unref(BngSoundClass_default),`bng_click_hover_generic`]])),256))])):createCommentVNode(``,!0),currentSkillToShow.value&¤tSkillToShow.value.hasLevels&¤tSkillToShow.value.unlockInfo&¤tSkillToShow.value.unlockInfo.length?(openBlock(),createElementBlock(`div`,_hoisted_3$169,[currentSkillToShow.value.hasUnlocks?(openBlock(),createBlock(UnlockRows_default,{key:0,class:`stat-progress-bar bng-progress-bar progress-bar`,headerLeft:_ctx.$ctx_t(currentSkillToShow.value.name),headerRight:_ctx.$ctx_t(currentSkillToShow.value.levelLabel),value:currentSkillToShow.value.value,max:currentSkillToShow.value.max,min:currentSkillToShow.value.min,maxRequiredValue:currentSkillToShow.value.maxRequiredValue,tiers:currentSkillToShow.value.unlockInfo,currentTier:currentSkillToShow.value.unlocked?currentSkillToShow.value.level:-1,unlocked:currentSkillToShow.value.unlocked,progressFillColor:currentSkillToShow.value.accentColor},null,8,[`headerLeft`,`headerRight`,`value`,`max`,`min`,`maxRequiredValue`,`tiers`,`currentTier`,`unlocked`,`progressFillColor`])):createCommentVNode(``,!0)])):createCommentVNode(``,!0),leagues.value&&leagues.value.length>0?(openBlock(),createElementBlock(`div`,_hoisted_4$142,[(openBlock(!0),createElementBlock(Fragment,null,renderList(leagues.value,league=>(openBlock(),createBlock(LeagueRow_default,{key:league.id,league,leagueMissionClicked},null,8,[`league`]))),128))])):createCommentVNode(``,!0),landingData.value.showMilestones?(openBlock(),createElementBlock(`div`,_hoisted_5$124,[withDirectives((openBlock(),createBlock(unref(bngCard_default),{"bng-nav-item":``,class:`button milestone-button`,onClick:openMilestonesScreen},{default:withCtx(()=>[createBaseVNode(`div`,_hoisted_6$106,[createVNode(unref(bngIcon_default),{class:`icon`,type:unref(icons).checkboxOn},null,8,[`type`]),_cache[0]||=createBaseVNode(`div`,{class:`label`},` Milestones `,-1),hasUnclaimedMilestones.value>0?(openBlock(),createElementBlock(`div`,_hoisted_7$93)):createCommentVNode(``,!0)])]),_:1})),[[unref(BngSoundClass_default),`bng_click_hover_generic`]])])):createCommentVNode(``,!0)]),_:1},8,[`skill-info`,`heading-text`,`breadcrumb-items`,`branch-style`]))}},ProgressLanding_default=__plugin_vue_export_helper_default(_sfc_main$265,[[`__scopeId`,`data-v-cbe0bb9d`]]),_hoisted_1$235={class:`reward-wrapper`},_hoisted_2$193={class:`card-content`},_hoisted_3$168={class:`rewards-breakdown-container padding-bottom`},_hoisted_4$141={class:`grid-wrapper`},_hoisted_5$123={class:`grid-row grid`},_hoisted_6$105={class:`label primary`},_hoisted_7$92={class:`rewards primary`},_hoisted_8$77={class:`grid-wrapper wide`},_hoisted_9$70={class:`grid`},_hoisted_10$61={class:`label secondary`},_hoisted_11$55={class:`rewards secondary`},_hoisted_12$44={class:`grid-row grid`},_hoisted_13$37={class:`rewards primary`},_hoisted_14$35={class:`padding-bottom`},_hoisted_15$33={key:0,class:`unlocks-wrapper`},__default__$4={wrapper:{fade:!0,blur:!0,style:popupContainer.transparent},position:[popupPosition.center,popupPosition.center]},_sfc_main$264=Object.assign(__default__$4,{__name:`CargoDeliveryReward`,emits:[`return`],setup(__props,{emit:__emit}){useCssVars(_ctx=>({v4c61e8a8:ANIM_DURATION_CSS})),useUINavScope(`deliveryReward`);let ANIMATION_START_DELAY=1e3,ANIMATION_DURATION=2e3,ANIM_DURATION_CSS=ANIMATION_DURATION+`ms`,showBarAnimations=ref(!1),data=storeToRefs(useGameContextStore()).deliveryRewardData,exit=()=>{window.bngVue.gotoGameState(`play`)};function stopAnimations(){showBarAnimations.value=!1}function startProgressBarAnimation(){if(data.value){showBarAnimations.value=!0;for(let[key,value]of Object.entries(data.value.summary.rewards))value.branchInfo&&(value.branchInfo.animValue=value.branchInfo.value);setTimeout(stopAnimations,ANIMATION_DURATION)}}return onBeforeMount(()=>{Lua_default.simTimeAuthority.pushPauseRequest(`cargoDeliveryReward`)}),onMounted(()=>{getUINavServiceInstance().activate(),getUINavServiceInstance().clearFilteredEvents(),showBarAnimations.value=!1,setTimeout(startProgressBarAnimation,1e3)}),onUnmounted(()=>{Lua_default.career_modules_delivery_cargoScreen.unloadCargoPopupClosed(),Lua_default.simTimeAuthority.popPauseRequest(`cargoDeliveryReward`)}),(_ctx,_cache)=>unref(data)?withDirectives((openBlock(),createBlock(unref(layoutSingle_default),{key:0,class:`layout-content-full flex-column layout-paddings layout-align-center`,"bng-ui-scope":`deliveryReward`},{default:withCtx(()=>[createBaseVNode(`div`,_hoisted_1$235,[createVNode(unref(bngCard_default),null,{buttons:withCtx(()=>[createVNode(unref(bngButton_default),{onClick:exit},{default:withCtx(()=>[createVNode(unref(bngBinding_default),{"ui-event":`ok`,deviceMask:`xinput`}),_cache[5]||=createBaseVNode(`span`,null,`Continue`,-1)]),_:1})]),default:withCtx(()=>[createVNode(unref(careerStatus_default),{class:`career-status`}),createVNode(unref(bngCardHeading_default),{type:`ribbon`},{default:withCtx(()=>[..._cache[0]||=[createTextVNode(` Delivery Complete! `,-1)]]),_:1}),createBaseVNode(`div`,_hoisted_2$193,[createBaseVNode(`div`,_hoisted_3$168,[_cache[3]||=createBaseVNode(`span`,{class:`span2-heading`},` Reward Breakdown `,-1),createBaseVNode(`div`,_hoisted_4$141,[_cache[2]||=createBaseVNode(`div`,{class:`grid-row grid`},[createBaseVNode(`div`,{class:`label primary`},`Item`),createBaseVNode(`div`,{class:`rewards primary`},`Rewards`)],-1),(openBlock(!0),createElementBlock(Fragment,null,renderList(unref(data).sortedResults,result=>(openBlock(),createElementBlock(`div`,_hoisted_5$123,[createBaseVNode(`div`,_hoisted_6$105,toDisplayString(result.label),1),createBaseVNode(`div`,_hoisted_7$92,[createVNode(RewardsPills_default,{rewards:result.rewards},null,8,[`rewards`])]),createBaseVNode(`div`,_hoisted_8$77,[(openBlock(!0),createElementBlock(Fragment,null,renderList(result.breakdown,breakdown=>(openBlock(),createElementBlock(`div`,_hoisted_9$70,[createBaseVNode(`div`,_hoisted_10$61,toDisplayString(breakdown.label),1),createBaseVNode(`div`,_hoisted_11$55,[createVNode(RewardsPills_default,{rewards:breakdown.rewards},null,8,[`rewards`])])]))),256))])]))),256)),createVNode(unref(bngDivider_default)),createBaseVNode(`div`,_hoisted_12$44,[_cache[1]||=createBaseVNode(`div`,{class:`label primary`},`Summary`,-1),createBaseVNode(`div`,_hoisted_13$37,[createVNode(RewardsPills_default,{rewards:unref(data).summary.rewards},null,8,[`rewards`])])])])]),createBaseVNode(`div`,_hoisted_14$35,[(openBlock(!0),createElementBlock(Fragment,null,renderList(unref(data).summary.rewards,reward=>(openBlock(),createElementBlock(`div`,null,[reward.branchInfo?(openBlock(),createBlock(unref(bngProgressBar_default),{key:0,class:normalizeClass({"stat-progress-bar":!0,"animate-progress":showBarAnimations.value}),headerLeft:_ctx.$ctx_t(reward.branchInfo.name),headerRight:_ctx.$ctx_t(reward.branchInfo.level),min:reward.branchInfo.max==-1?0:reward.branchInfo.min,value:reward.branchInfo.max==-1?1:reward.branchInfo.animValue,max:reward.branchInfo.max==-1?1:reward.branchInfo.max,"value-label-format":reward.branchInfo.max==-1?`Max Level Reached`:void 0},null,8,[`class`,`headerLeft`,`headerRight`,`min`,`value`,`max`,`value-label-format`])):createCommentVNode(``,!0)]))),256))]),unref(data).summary.unlocks.length?(openBlock(),createElementBlock(`div`,_hoisted_15$33,[_cache[4]||=createBaseVNode(`span`,{class:`span2-heading`},` Unlocks`,-1),(openBlock(!0),createElementBlock(Fragment,null,renderList(unref(data).summary.unlocks,unlock=>(openBlock(),createBlock(UnlockCard_default,{class:`unlock-item`,data:unlock},null,8,[`data`]))),256))])):createCommentVNode(``,!0)])]),_:1})])]),_:1})),[[unref(BngBlur_default)],[unref(BngOnUiNav_default),exit,`back,menu,ok`]]):createCommentVNode(``,!0)}}),CargoDeliveryReward_default=__plugin_vue_export_helper_default(_sfc_main$264,[[`__scopeId`,`data-v-e964374f`]]),_hoisted_1$234={key:0,class:`context`},_hoisted_2$192={key:0,class:`card-label`},_hoisted_3$167={key:1,class:`card-label`},_hoisted_4$140={class:`simple-props-wrapper`},_hoisted_5$122={key:1,class:`to-load`},_hoisted_6$104={class:`chevron-arrow`},_hoisted_7$91={class:`chevron-outer`,width:`100%`,height:`100%`,xmlns:`http://www.w3.org/2000/svg`},_hoisted_8$76={class:`chevron-inner`,viewBox:`4 2 12 60`,preserveAspectRatio:`xMaxYMid slice`},_hoisted_9$69={key:0,d:`M-11 -2H1L14 32L1 66H-11V-2Z`,fill:`rgb(var(--chevron-color))`,"fill-opacity":`var(--chevron-alpha)`,stroke:`rgb(var(--chevron-color))`,"stroke-width":`3`,"vector-effect":`non-scaling-stroke`},_hoisted_10$60={key:1,d:`M-11 -2H1L14 32L1 66H-11V-2Z`,fill:`rgb(var(--chevron-color))`,"fill-opacity":`var(--chevron-alpha)`,stroke:`var(--bng-orange-500)`,"stroke-width":`3`,"vector-effect":`non-scaling-stroke`},_hoisted_11$54={key:2},_hoisted_12$43={key:0,class:`modifiers`},_hoisted_13$36={key:1,class:`timer-value`},_hoisted_14$34={key:0,class:`orange`},_sfc_main$263={__name:`CargoCard`,props:{card:{type:Object,required:!1},hideProps:Boolean,hideModsAndTimer:Boolean,focus:String,detailed:Boolean,showButtons:{type:Boolean,default:!0},alwaysShowLoadingWrapper:Boolean,ribbon:{type:Boolean,default:!0}},emits:[`cargoHovered`,`onAmountSelectorChanged`],setup(__props,{emit:__emit}){let emit$1=__emit;function onAmountSelectorChanged(value){emit$1(`onAmountSelectorChanged`,value)}let props=__props,cargoOverviewStore=useCargoOverviewStore(),{units}=useBridge(),getCargoCardClass=card=>({cardRow:!0,"bg-available":card.isFacilityCard&&card.enabled,"bg-available-selected":card.isFacilityCard&&card.enabled&&cargoOverviewStore.selectedCargo===card,"bg-assigned":card.transientMove,"bg-assigned-selected":card.transientMove&&cargoOverviewStore.selectedCargo===card,"bg-locked":card.isFacilityCard&&!card.enabled,"bg-locked-selected":card.isFacilityCard&&!card.enabled&&cargoOverviewStore.selectedCargo===card,"bg-loaded":card.isPlayerCard&&!card.transientMove,"bg-loaded-selected":card.isPlayerCard&&!card.transientMove&&cargoOverviewStore.selectedCargo===card,"highlight-poi-selected":!!(!props.detailed&&cargoOverviewStore.highlightedCards[card.cardId]),"card-disabled":!card.enabled,"with-thumbnail":card.thumbnail}),rewardMoney=computed(()=>props.card.rewardMoney||props.card.rewardMoneyPerLiter||(props.card.loanerCut?-(props.card.loanerCut.value*100-props.card.loanerCut.value*100%1)+`%`:void 0)),hasIds=computed(()=>props.card.rewardMoney&&props.card.ids&&props.card.ids.length>0&&!props.card.materialType),isPerLiter=computed(()=>props.card.rewardMoneyPerLiter),isLoadingFacilityCard=computed(()=>props.card.transientMoveCounts>0||props.card.spawnWhenCommitingCargo||props.card._transientMaterialMoveAmount>0),context=computed(()=>props.card.enabled?props.card.isFacilityCard?`Available`:props.card.transientMoveCounts>0||props.card.spawnWhenCommitingCargo||props.card._transientMaterialMoveAmount?`Assigned`:`Loaded`:`Locked`),isMoving=computed(()=>cargoOverviewStore.cargoData.player.isMoving),chevronProp=computed(()=>{let card=props.card;if(!card.isPlayerCard){if(card.cardType===`parcelGroup`)return card.materialType?card.transientMoveCounts>0||props.alwaysShowLoadingWrapper?{class:card.transientMoveCounts==0?`amount-load no-load`:`amount-load`,valueLabel:card.slots+`L`}:void 0:card.transientMoveCounts>0||props.alwaysShowLoadingWrapper?{class:card.transientMoveCounts==0?`amount-load no-load`:`amount-load`,valueLabel:card.transientMoveCounts+` / `+card.ids.length}:void 0;if(card.cardType===`vehicleOffer`)return card.spawnWhenCommitingCargo?{class:`amount-load`,valueLabel:`Accepted`,iconType:icons.fastTravel}:void 0;if(card.cardType===`storage`)return card._transientMaterialMoveAmount>0||props.alwaysShowLoadingWrapper?{class:card._transientMaterialMoveAmount==0?`amount-load no-load`:`amount-load`,valueLabel:card._transientMaterialMoveAmount+`L / `+card.storage.storedVolume+`L`}:void 0}}),propIcons=computed(()=>{let res=[],card=props.card;if(props.detailed)return res;if(card.enabled&&card.modifiers&&card.modifiers.length)for(let mod of card.modifiers)mod.important&&res.push({type:icons[mod.icon],color:`var(--bng-orange-300)`});return card.disableReason&&card.disableReason.type===`locked`&&res.push({type:icons.lockClosed,color:`var(--bng-add-red-300)`}),res}),cargoProps=computed(()=>{let res=[],card=props.card,detailed=props.detailed,focus$1=props.focus,$tt=$translate.instant,$ctx_t=$translate.contextTranslate,hideProps=props.hideProps;if(card.isFacilityCard&&!card.enabled&&(!card.transientMoveCounts||card.transientMoveCounts<=0)&&(card.disableReason?(card.disableReason.type===`noSpace`&&res.push({iconType:icons.info,keyLabel:detailed?`No Space`:``,valueLabel:detailed?card.disableReason.label?card.disableReason.label:`Not enough space to load this.`:`No Space`,class:`full-width red`,iconColor:`var(--bng-add-red-300)`}),card.disableReason.type===`expired`&&res.push({iconType:icons.info,keyLabel:detailed?`Expired`:``,valueLabel:detailed?card.disableReason.label?card.disableReason.label:`This offer is already expired.`:`Expired`,class:`full-width `}),card.disableReason.type===`limit`&&res.push({iconType:icons.info,keyLabel:detailed?`Limit reached`:``,valueLabel:detailed?card.disableReason.label?card.disableReason.label:`You cannot deliver more cars at the same time.`:`Limit reached`,class:`full-width red`,iconColor:`var(--bng-add-red-300)`})):res.push({iconType:icons.lockClosed,keyLabel:detailed?`Locked..?`:``,valueLabel:detailed?`Not enabled but no disablereason given!`:`Locked..?`,class:`full-width`,iconColor:`var(--bng-add-red-300)`})),card.unlockInfo){let locked=card.disableReason&&card.disableReason.type==`locked`;(detailed||locked)&&res.push({iconType:icons[card.unlockInfo.icon],valueLabel:detailed?$ctx_t(card.unlockInfo.longLabel):``,keyLabel:detailed?locked?`Locked`:``:$ctx_t(card.unlockInfo.shortLabel),class:`full-width `+(locked?`red`:``),iconColor:locked?`var(--bng-add-red-300)`:``})}if(hideProps)return res;if(card.nextTasks&&card.nextTasks.length>0&&(!focus$1||focus$1===`nextTasks`||detailed))for(let task of card.nextTasks)res.push({iconType:icons[task.checked?`checkboxOn`:`checkboxOff`],keyLabel:detailed?`Next Task`:``,valueLabel:task.label,class:`full-width`});if(card.locationName&&(!focus$1||focus$1===`location`||detailed)&&res.push({iconType:icons.locationSource,keyLabel:detailed?`Location`:``,valueLabel:detailed?card.locationNameLong:card.locationName,class:`full-width`}),card.destinationName&&(!focus$1||focus$1===`destination`||detailed)&&res.push({iconType:icons.locationDestination,keyLabel:detailed?`Destination`:``,valueLabel:detailed?card.destinationNameLong:card.destinationName,class:`full-width`}),card.locations&&(!focus$1||focus$1===`destination`)&&!detailed&&res.push({iconType:icons.mapPoint,valueLabel:card.locations.length+` possible Destinations`,class:`full-width`}),card.locations&&detailed)if(card.locations.length==1)res.push({iconType:icons.locationDestination,keyLabel:`Destination`,valueLabel:card.locations[0].name,class:`full-width`});else{res.push({iconType:icons.location2,keyLabel:`Multiple Destinations`,valueLabel:`Deliver this cargo to any of the possible destinations.`,class:`full-width`});let destinationsList=[];for(let location$1 of card.locations)destinationsList.push($tt(location$1.name));destinationsList=destinationsList.map(str=>str.replace(/ /g,` `)),res.push({iconType:icons.mapPoint,keyLabel:`Possible Destinations`,valueLabel:destinationsList.join(`, `),class:`full-width`})}if(card.distance&&(!focus$1||focus$1===`distance`||detailed)&&res.push({iconType:icons.routeSimple,keyLabel:detailed?`Distance`:``,valueLabel:units.buildString(`distance`,card.distance,1),class:``}),card.vehMileage&&(!focus$1||focus$1===`vehMileage`||detailed)&&res.push({iconType:icons.odometer,keyLabel:detailed?`Mileage`:``,valueLabel:units.buildString(`distance`,card.vehMileage,1),class:``}),card.weight&&(!focus$1||focus$1===`weight`||detailed)&&res.push({iconType:icons.weight,keyLabel:detailed?`Weight`:``,valueLabel:units.buildString(`weight`,card.weight,1),class:``}),card.density&&(!focus$1||focus$1===`density`||detailed)&&res.push({iconType:icons.weight,keyLabel:detailed?`Density`:``,valueLabel:units.buildString(`weight`,card.density,2),class:``}),card.storage&&(!focus$1||focus$1===`storage`||detailed)&&res.push({iconType:icons.boxDropOff01,keyLabel:detailed?`Available Volume`:``,valueLabel:(card.storage.storedVolume+(detailed?` / `+card.storage.capacity:``)).replace(/ /g,` `),class:``}),card.slots&&(!focus$1||focus$1===`slots`||detailed)&&res.push({iconType:icons.boxDropOff01,keyLabel:detailed?`Slots`:``,valueLabel:card.slots,class:``}),card.task&&(!focus$1||focus$1===`task`||detailed)&&res.push({iconType:icons.checkboxOff,keyLabel:detailed?`Task`:``,valueLabel:card.task,class:`full-width`}),card.cardType==`loaner`&&(!focus$1||detailed)&&res.push({iconType:icons.steeringWheelSporty,keyLabel:detailed?`Loaner`:``,valueLabel:detailed?card.isFacilityCard?`This vehicle can be loaned for delivery.`:`This vehicle can be used for delivery.`:`Loaner`,class:`full-width`}),card.cardType==`loaner`&&card.loanerCut&&!focus$1&&detailed&&res.push({iconType:icons.carCoins,keyLabel:detailed?`Loaner Cut`:``,valueLabel:detailed?`Organization takes `+(card.loanerCut.value*100-card.loanerCut.value*100%1)+`% of rewards earned with this loaner.`:card.loanerCut.value*100-card.loanerCut.value*100%1+`%`,class:`full-width`}),card.organizationName&&(!focus$1||detailed)&&res.push({iconType:icons.peopleOutline,keyLabel:detailed?`Organization`:``,valueLabel:$tt(card.organizationName),class:``}),card.capacity&&card.capacity.length)for(let cap of card.capacity)res.push({iconType:icons[cap.icon],keyLabel:detailed?`Capacity`:``,valueLabel:detailed?cap.labelLong:cap.labelShort,class:``});if(detailed&&card.modifiers&&card.modifiers.length>0)for(let mod of card.modifiers)res.push({iconType:icons[mod.icon],keyLabel:mod.label,valueLabel:mod.description,class:`full-width`+(mod.important?` orange`:``),iconColor:mod.important?`var(--bng-orange-300)`:``});return res});return(_ctx,_cache)=>(openBlock(),createBlock(unref(bngCard_default),mergeProps({class:[`card-item`,getCargoCardClass(__props.card)]},!__props.detailed&&{"bng-nav-item":!0,tabindex:1},{onClick:_cache[15]||=withModifiers(()=>{},[`stop`])}),{default:withCtx(()=>[!__props.detailed&&__props.card.thumbnail?(openBlock(),createBlock(unref(aspectRatio_default),{key:0,class:`image`,ratio:`4:3`,"external-image":__props.card.thumbnail},{default:withCtx(()=>[!__props.card.enabled&&__props.card.disableReason.type==`locked`?(openBlock(),createBlock(unref(bngIcon_default),{key:0,type:unref(icons).lockClosed,class:`icon`},null,8,[`type`])):createCommentVNode(``,!0)]),_:1},8,[`external-image`])):createCommentVNode(``,!0),createBaseVNode(`div`,{class:normalizeClass({"card-content-flex":!0,"with-actions":!__props.detailed})},[createBaseVNode(`div`,{class:normalizeClass([`heading-wrapper`,{"heading-detailed":__props.detailed}])},[__props.detailed?(openBlock(),createBlock(unref(bngCardHeading_default),{key:0,type:__props.ribbon?`ribbon`:`none`,class:`card-heading`},{default:withCtx(()=>[context.value===``?createCommentVNode(``,!0):(openBlock(),createElementBlock(`span`,_hoisted_1$234,toDisplayString(context.value),1)),createBaseVNode(`div`,null,[__props.card.vehName?(openBlock(),createElementBlock(Fragment,{key:1},[createTextVNode(toDisplayString(__props.card.vehName),1)],64)):(openBlock(),createElementBlock(Fragment,{key:0},[createTextVNode(toDisplayString(__props.card.name),1)],64))])]),_:1},8,[`type`])):(openBlock(),createElementBlock(Fragment,{key:1},[__props.card.vehName?(openBlock(),createElementBlock(`div`,_hoisted_3$167,toDisplayString(__props.card.vehName),1)):(openBlock(),createElementBlock(`div`,_hoisted_2$192,toDisplayString(__props.card.name),1))],64)),createBaseVNode(`div`,{class:normalizeClass([`pill pill-blue`,{"pill-orange":isLoadingFacilityCard.value}])},[typeof rewardMoney.value==`number`?(openBlock(),createBlock(unref(bngUnit_default),{key:0,class:`reward-money`,money:rewardMoney.value},null,8,[`money`])):(openBlock(),createBlock(unref(bngPropVal_default),{key:1,class:`reward-money`,iconType:unref(icons).beamCurrency,valueLabel:rewardMoney.value},null,8,[`iconType`,`valueLabel`])),hasIds.value&&!__props.card.transientMove?(openBlock(),createBlock(unref(bngPropVal_default),{key:2,class:`amount-avail`,valueLabel:`×`+__props.card.ids.length},null,8,[`valueLabel`])):createCommentVNode(``,!0),hasIds.value&&__props.card.transientMove?(openBlock(),createBlock(unref(bngPropVal_default),{key:3,class:`amount-avail`,valueLabel:`×`+__props.card.transientMoveCounts},null,8,[`valueLabel`])):createCommentVNode(``,!0),isPerLiter.value?(openBlock(),createBlock(unref(bngPropVal_default),{key:4,class:`amount-avail`,valueLabel:`/L`})):createCommentVNode(``,!0),__props.card.materialType?(openBlock(),createBlock(unref(bngPropVal_default),{key:5,class:`amount-avail`,valueLabel:__props.card.slots+` L`},null,8,[`valueLabel`])):createCommentVNode(``,!0)],2)],2),!__props.card.showAmountSelector&&cargoProps.value.length>0&&__props.detailed?(openBlock(),createElementBlock(`div`,{key:0,class:normalizeClass({"body-grid":__props.detailed,"body-list-wrapped":!__props.detailed,"content-detailed":__props.detailed})},[(openBlock(!0),createElementBlock(Fragment,null,renderList(cargoProps.value,props$1=>(openBlock(),createBlock(unref(bngPropVal_default),mergeProps({ref_for:!0},props$1),null,16))),256))],2)):createCommentVNode(``,!0),__props.detailed&&isMoving.value?(openBlock(),createElementBlock(`div`,{key:1,class:normalizeClass([`buttons-disabled-reason`,{"disabled-load-actions":!__props.card.enabled||!__props.showButtons,"footer-detailed":__props.detailed}])},[createVNode(unref(bngPropVal_default),{class:`prop`,iconType:unref(icons).info,keyLabel:``,valueLabel:`Cannot modify cargo while any vehicle is moving.`},null,8,[`iconType`])],2)):createCommentVNode(``,!0),createBaseVNode(`div`,{class:normalizeClass([`load-actions-wrapper`,{"disabled-load-actions":!__props.card.enabled||!__props.showButtons,"footer-detailed":__props.detailed,"chevrons-bg":__props.card.transientMoveCounts>0||__props.card.spawnWhenCommitingCargo||__props.card._transientMaterialMoveAmount>0}])},[createBaseVNode(`div`,_hoisted_4$140,[__props.detailed?createCommentVNode(``,!0):(openBlock(),createElementBlock(Fragment,{key:0},[(openBlock(!0),createElementBlock(Fragment,null,renderList(propIcons.value,icon=>(openBlock(),createBlock(unref(bngIcon_default),mergeProps({class:`icon`},{ref_for:!0},icon),null,16))),256)),(openBlock(!0),createElementBlock(Fragment,null,renderList(cargoProps.value,props$1=>(openBlock(),createBlock(unref(bngPropVal_default),mergeProps({class:`prop`},{ref_for:!0},props$1),null,16))),256))],64))]),__props.card.enabled&&__props.showButtons?(openBlock(),createElementBlock(`div`,{key:0,class:normalizeClass([`load-actions-buttons`,{undetailed:!__props.detailed}])},[__props.card.cardType==`parcelGroup`?(openBlock(),createElementBlock(Fragment,{key:0},[__props.card.isFacilityCard?(openBlock(),createElementBlock(Fragment,{key:0},[__props.card.transientMoveCounts==0?createCommentVNode(``,!0):(openBlock(),createBlock(unref(bngButton_default),{key:0,class:normalizeClass(__props.detailed?``:`button-load`),accent:unref(ACCENTS).secondary,"icon-right":unref(icons).undo,label:__props.detailed?`Clear load`:``,onClick:_cache[0]||=$event=>unref(cargoOverviewStore).clearLoad(__props.card),disabled:isMoving.value,tabindex:`0`},null,8,[`class`,`accent`,`icon-right`,`label`,`disabled`])),__props.card.autoLoadLocations&&__props.card.autoLoadLocations.length==0?createCommentVNode(``,!0):(openBlock(),createBlock(unref(bngButton_default),{key:1,class:normalizeClass(__props.detailed?``:`button-load`),accent:unref(ACCENTS).secondary,"icon-right":unref(icons).wrench,label:__props.detailed?`Custom load`:``,onClick:_cache[1]||=$event=>unref(cargoOverviewStore).loadCargoCustom(__props.card),disabled:isMoving.value,tabindex:`0`},null,8,[`class`,`accent`,`icon-right`,`label`,`disabled`])),__props.card.transientMoveCounts==__props.card.ids.length||__props.card.autoLoadLocations.length==0||!__props.card.autoLoadLocations.length?createCommentVNode(``,!0):(openBlock(),createBlock(unref(bngButton_default),{key:2,class:normalizeClass(__props.detailed?``:`button-load`),accent:unref(ACCENTS).main,"icon-right":unref(icons).arrowLargeRight,label:__props.detailed?`Load all`:``,onClick:_cache[2]||=$event=>unref(cargoOverviewStore).loadCargoAuto(__props.card),disabled:isMoving.value,tabindex:`0`},null,8,[`class`,`accent`,`icon-right`,`label`,`disabled`]))],64)):(openBlock(),createElementBlock(Fragment,{key:1},[__props.card.transientMoveCounts>0?(openBlock(),createBlock(unref(bngButton_default),{key:0,class:normalizeClass(__props.detailed?``:`button-load`),accent:unref(ACCENTS).attention,"icon-right":unref(icons).undo,label:__props.detailed?`Clear Load`:``,onClick:_cache[3]||=$event=>unref(cargoOverviewStore).clearLoad(__props.card),disabled:isMoving.value,tabindex:`0`},null,8,[`class`,`accent`,`icon-right`,`label`,`disabled`])):(openBlock(),createBlock(unref(bngButton_default),{key:1,class:normalizeClass(__props.detailed?``:`button-load`),accent:unref(ACCENTS).attention,"icon-right":unref(icons).trashBin1,label:__props.detailed?`Throw Away`:``,onClick:_cache[4]||=$event=>unref(cargoOverviewStore).throwAway(__props.card),disabled:isMoving.value,tabindex:`0`},null,8,[`class`,`accent`,`icon-right`,`label`,`disabled`])),__props.card.materialType===void 0?(openBlock(),createBlock(unref(bngButton_default),{key:2,class:normalizeClass(__props.detailed?``:`button-load`),accent:unref(ACCENTS).primary,"icon-right":unref(icons).wrench,label:__props.detailed?`Custom load`:``,onClick:_cache[5]||=$event=>unref(cargoOverviewStore).loadCargoCustom(__props.card),disabled:isMoving.value,tabindex:`0`},null,8,[`class`,`accent`,`icon-right`,`label`,`disabled`])):createCommentVNode(``,!0),__props.card.materialType!==void 0&&__props.card.transientMove?(openBlock(),createBlock(unref(bngButton_default),{key:3,class:normalizeClass(__props.detailed?``:`button-load`),accent:unref(ACCENTS).primary,"icon-right":unref(icons).wrench,label:__props.detailed?`Custom Load`:``,onClick:_cache[6]||=$event=>unref(cargoOverviewStore).modifyMaterialLoad(__props.card),disabled:isMoving.value,tabindex:`0`},null,8,[`class`,`accent`,`icon-right`,`label`,`disabled`])):createCommentVNode(``,!0)],64))],64)):createCommentVNode(``,!0),__props.card.isFacilityCard?(openBlock(),createElementBlock(Fragment,{key:1},[__props.card.cardType==`storage`?(openBlock(),createBlock(unref(bngButton_default),{key:0,class:normalizeClass(__props.detailed?``:`button-load`),accent:unref(ACCENTS).main,icon:unref(icons).wrench,label:__props.detailed?`Custom load`:``,onClick:_cache[7]||=$event=>unref(cargoOverviewStore).loadStorageCustom(__props.card),disabled:isMoving.value,tabindex:`0`},null,8,[`class`,`accent`,`icon`,`label`,`disabled`])):createCommentVNode(``,!0),__props.card.cardType==`vehicleOffer`&&!__props.card.spawnWhenCommitingCargo?(openBlock(),createBlock(unref(bngButton_default),{key:1,class:normalizeClass(__props.detailed?``:`button-load`),accent:unref(ACCENTS).main,icon:unref(icons).keys1,label:__props.detailed?`Accept Job`:``,onClick:_cache[8]||=$event=>unref(cargoOverviewStore).loadOffer(__props.card),disabled:isMoving.value,tabindex:`0`},null,8,[`class`,`accent`,`icon`,`label`,`disabled`])):createCommentVNode(``,!0),__props.card.cardType==`vehicleOffer`&&__props.card.spawnWhenCommitingCargo?(openBlock(),createBlock(unref(bngButton_default),{key:2,class:normalizeClass(__props.detailed?``:`button-load`),accent:unref(ACCENTS).attention,icon:unref(icons).undo,label:__props.detailed?`Decline Job`:``,onClick:_cache[9]||=$event=>unref(cargoOverviewStore).loadOffer(__props.card),disabled:isMoving.value,tabindex:`0`},null,8,[`class`,`accent`,`icon`,`label`,`disabled`])):createCommentVNode(``,!0),__props.card.cardType==`loaner`&&!__props.card.spawnWhenCommitingCargo?(openBlock(),createBlock(unref(bngButton_default),{key:3,class:normalizeClass(__props.detailed?``:`button-load`),accent:unref(ACCENTS).main,icon:unref(icons).keys1,label:__props.detailed?`Accept Loaner`:``,onClick:_cache[10]||=$event=>unref(cargoOverviewStore).loadLoaner(__props.card),disabled:isMoving.value,tabindex:`0`},null,8,[`class`,`accent`,`icon`,`label`,`disabled`])):createCommentVNode(``,!0),__props.card.cardType==`loaner`&&__props.card.spawnWhenCommitingCargo?(openBlock(),createBlock(unref(bngButton_default),{key:4,class:normalizeClass(__props.detailed?``:`button-load`),accent:unref(ACCENTS).attention,icon:unref(icons).undo,label:__props.detailed?`Decline Loaner`:``,onClick:_cache[11]||=$event=>unref(cargoOverviewStore).loadLoaner(__props.card),disabled:isMoving.value,tabindex:`0`},null,8,[`class`,`accent`,`icon`,`label`,`disabled`])):createCommentVNode(``,!0)],64)):(openBlock(),createElementBlock(Fragment,{key:2},[__props.card.cardType==`vehicleOffer`&&!__props.card.spawnWhenCommitingCargo?(openBlock(),createBlock(unref(bngButton_default),{key:0,class:normalizeClass(__props.detailed?``:`button-load`),accent:unref(ACCENTS).attention,icon:unref(icons).trashBin1,label:__props.detailed?`Abandon Job`:``,onClick:_cache[12]||=$event=>unref(cargoOverviewStore).abandonOffer(__props.card),disabled:isMoving.value,tabindex:`0`},null,8,[`class`,`accent`,`icon`,`label`,`disabled`])):createCommentVNode(``,!0),__props.card.cardType==`loaner`&&__props.card.isSpawnedLoaner?(openBlock(),createBlock(unref(bngButton_default),{key:1,class:normalizeClass(__props.detailed?``:`button-load`),accent:unref(ACCENTS).attention,icon:unref(icons).trashBin1,label:__props.detailed?`Return Loaner`:``,onClick:_cache[13]||=$event=>unref(cargoOverviewStore).returnLoaner(__props.card.id),disabled:isMoving.value,tabindex:`0`},null,8,[`class`,`accent`,`icon`,`label`,`disabled`])):createCommentVNode(``,!0)],64))],2)):createCommentVNode(``,!0),chevronProp.value?(openBlock(),createElementBlock(`div`,_hoisted_5$122,[createVNode(unref(bngPropVal_default),mergeProps({class:`amount-load`},chevronProp.value),null,16),createBaseVNode(`div`,_hoisted_6$104,[(openBlock(),createElementBlock(`svg`,_hoisted_7$91,[(openBlock(),createElementBlock(`svg`,_hoisted_8$76,[__props.card.transientMoveCounts===0?(openBlock(),createElementBlock(`path`,_hoisted_9$69)):(openBlock(),createElementBlock(`path`,_hoisted_10$60))]))]))])])):createCommentVNode(``,!0)],2),__props.card.showAmountSelector?(openBlock(),createElementBlock(`div`,_hoisted_11$54,[createTextVNode(` Selected Amount: `+toDisplayString(__props.card.amountSelector)+` `,1),createVNode(unref(bngSlider_default),{class:`slider`,min:0,max:__props.card.maxCount,step:1,modelValue:__props.card.amountSelector,"onUpdate:modelValue":_cache[14]||=$event=>__props.card.amountSelector=$event,onValueChanged:onAmountSelectorChanged},null,8,[`max`,`modelValue`])])):createCommentVNode(``,!0),createBaseVNode(`div`,{class:normalizeClass([`footer-grid`,{"footer-detailed":__props.detailed}])},[__props.detailed?(openBlock(),createElementBlock(Fragment,{key:0},[(__props.focus===`none`||!__props.focus)&&!__props.hideModsAndTimer?(openBlock(),createElementBlock(`div`,_hoisted_12$43,[__props.detailed?createCommentVNode(``,!0):(openBlock(!0),createElementBlock(Fragment,{key:0},renderList(__props.card.modifiers,mod=>(openBlock(),createBlock(unref(bngIcon_default),{type:unref(icons)[mod.icon]},null,8,[`type`]))),256))])):createCommentVNode(``,!0),__props.card.remainingTime&&(__props.focus===`none`||!__props.focus)&&!__props.hideModsAndTimer?(openBlock(),createElementBlock(`div`,_hoisted_13$36,[__props.card.remainingTime.type===`preLoad`?(openBlock(),createElementBlock(`div`,_hoisted_14$34,`Time for delivery: `+toDisplayString(unref(formatTime)(__props.card.remainingTime.time,2)),1)):createCommentVNode(``,!0),__props.card.remainingTime.type===`untilDelayed`?(openBlock(),createElementBlock(Fragment,{key:1},[createTextVNode(` Time until delivery is Delayed: `+toDisplayString(unref(formatTime)(__props.card.remainingTime.time,2)),1)],64)):createCommentVNode(``,!0),__props.card.remainingTime.type===`untilLate`?(openBlock(),createElementBlock(Fragment,{key:2},[createTextVNode(` Time until delivery is Late: `+toDisplayString(unref(formatTime)(__props.card.remainingTime.time,2)),1)],64)):createCommentVNode(``,!0),__props.card.remainingTime.type===`late`?(openBlock(),createElementBlock(Fragment,{key:3},[createTextVNode(` Delivery is late `)],64)):createCommentVNode(``,!0)])):createCommentVNode(``,!0)],64)):createCommentVNode(``,!0),__props.card.remainingTime&&__props.card.remainingTime.percent&&__props.card.isPlayerCard?(openBlock(),createElementBlock(`div`,{key:1,class:normalizeClass([`timer-progress-bar`,{slim:!__props.detailed}])},[createBaseVNode(`div`,{class:`progress-bar-fill`,style:normalizeStyle({width:__props.card.remainingTime.percent*100+`%`})},null,4)],2)):createCommentVNode(``,!0)],2)],2)]),_:1},16,[`class`]))}},CargoCard_default=__plugin_vue_export_helper_default(_sfc_main$263,[[`__scopeId`,`data-v-bafe8e5e`]]),_hoisted_1$233={class:`info-container`},_hoisted_2$191={key:0,class:`header`},_hoisted_3$166={key:0,class:`label`},_hoisted_4$139={class:`props`},_hoisted_5$121={key:4,class:`prop pill`},_sfc_main$262={__name:`CargoInfo`,props:{label:String,fillInfo:Object,meta:Object},setup(__props){let{units}=useBridge(),props=__props;return(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$233,[__props.meta.type===`hidden`?createCommentVNode(``,!0):(openBlock(),createElementBlock(`div`,_hoisted_2$191,[__props.label?(openBlock(),createElementBlock(`div`,_hoisted_3$166,[__props.meta.type==`task`?(openBlock(),createBlock(unref(bngIcon_default),{key:0,class:`icon`,type:unref(icons).checkboxOff},null,8,[`type`])):createCommentVNode(``,!0),__props.label?(openBlock(),createElementBlock(Fragment,{key:1},[createTextVNode(toDisplayString(_ctx.$tt(__props.label)),1)],64)):createCommentVNode(``,!0)])):createCommentVNode(``,!0),createBaseVNode(`div`,_hoisted_4$139,[__props.meta.type==`container`||__props.meta.type==`totalStorage`?(openBlock(),createBlock(unref(bngPropVal_default),{key:0,iconType:unref(icons)[__props.meta.icon],valueLabel:__props.meta.usedCargoSlots+` / `+__props.meta.totalCargoSlots},null,8,[`iconType`,`valueLabel`])):createCommentVNode(``,!0),__props.meta.type==`location`?(openBlock(),createBlock(unref(bngPropVal_default),{key:1,iconType:unref(icons).mapPoint,valueLabel:unref(units).buildString(`distance`,__props.meta.distance,1),style:{"--icon-size":`1.25em`}},null,8,[`iconType`,`valueLabel`])):createCommentVNode(``,!0),__props.meta.type==`trash`?(openBlock(),createBlock(unref(bngIcon_default),{key:2,class:`icon`,type:unref(icons).trashBin1},null,8,[`type`])):createCommentVNode(``,!0),props&&props.length?(openBlock(!0),createElementBlock(Fragment,{key:3},renderList(props,prop=>(openBlock(),createBlock(unref(bngPropVal_default),{iconType:unref(icons)[prop.icon],valueLabel:prop.label},null,8,[`iconType`,`valueLabel`]))),256)):createCommentVNode(``,!0),__props.fillInfo?(openBlock(),createElementBlock(`div`,_hoisted_5$121,[createVNode(unref(bngPropVal_default),{iconType:unref(icons)[__props.fillInfo.icon],valueLabel:__props.fillInfo.usedSlots+` / `+__props.fillInfo.availableSlots},null,8,[`iconType`,`valueLabel`])])):createCommentVNode(``,!0)]),__props.meta.fillPercent||__props.meta.fillPercent==0?(openBlock(),createElementBlock(`div`,{key:1,class:normalizeClass([`progress-bar`,{trash:__props.meta.type==`trash`}])},[__props.meta.fillPercentHighlight>0?(openBlock(),createElementBlock(`div`,{key:0,class:`progress-bar-fill highlight`,style:normalizeStyle({width:`${__props.meta.fillPercentHighlight*100}%`})},null,4)):createCommentVNode(``,!0),createBaseVNode(`div`,{class:`progress-bar-fill`,style:normalizeStyle({width:`${__props.meta.fillPercent*100}%`})},null,4)],2)):createCommentVNode(``,!0)]))]))}},CargoInfo_default=__plugin_vue_export_helper_default(_sfc_main$262,[[`__scopeId`,`data-v-ba3be877`]]),_hoisted_1$232={class:`group`},_hoisted_2$190={class:`cards`},_sfc_main$261={__name:`CardGroup`,props:{label:String,fillInfo:Object,meta:Object},setup(__props){return(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$232,[createVNode(CargoInfo_default,{label:__props.label,"fill-info":__props.fillInfo,meta:__props.meta},null,8,[`label`,`fill-info`,`meta`]),createBaseVNode(`div`,_hoisted_2$190,[renderSlot(_ctx.$slots,`default`,{},void 0,!0)])]))}},CardGroup_default=__plugin_vue_export_helper_default(_sfc_main$261,[[`__scopeId`,`data-v-f21d8701`]]),_hoisted_1$231={class:`customload-wrapper`,"bng-ui-scope":`cargoLoadPopup`},_hoisted_2$189={class:`card-container`},_hoisted_3$165={class:`content target-grid`},_hoisted_4$138={key:0,class:`target-tile`},_hoisted_5$120={class:`loading-controls amount-load`},_hoisted_6$103={class:`amount`},_hoisted_7$90={class:`chevron-arrow`},_hoisted_8$75={class:`chevron-outer`,width:`100%`,height:`100%`,xmlns:`http://www.w3.org/2000/svg`},_hoisted_9$68={class:`chevron-inner`,viewBox:`4 2 12 60`,preserveAspectRatio:`xMaxYMid slice`},_hoisted_10$59={key:0,d:`M-11 -2H1L14 32L1 66H-11V-2Z`,fill:`rgb(var(--chevron-color))`,"fill-opacity":`var(--chevron-alpha)`,stroke:`rgb(var(--chevron-color))`,"stroke-width":`3`,"vector-effect":`non-scaling-stroke`},_hoisted_11$53={key:1,d:`M-11 -2H1L14 32L1 66H-11V-2Z`,fill:`rgb(var(--chevron-color))`,"fill-opacity":`var(--chevron-alpha)`,stroke:`var(--bng-orange-500)`,"stroke-width":`3`,"vector-effect":`non-scaling-stroke`},_hoisted_12$42={key:1,class:`target-tile trash`},_hoisted_13$35={class:`loading-controls amount-load`},_hoisted_14$33={class:`amount`},_hoisted_15$32={class:`chevron-arrow`},_hoisted_16$32={class:`chevron-outer`,width:`100%`,height:`100%`,xmlns:`http://www.w3.org/2000/svg`},_hoisted_17$26={class:`chevron-inner`,viewBox:`4 2 12 60`,preserveAspectRatio:`xMaxYMid slice`},_hoisted_18$23={key:0,d:`M-11 -2H1L14 32L1 66H-11V-2Z`,fill:`rgb(var(--chevron-color))`,"fill-opacity":`var(--chevron-alpha)`,stroke:`rgb(var(--chevron-color))`,"stroke-width":`3`,"vector-effect":`non-scaling-stroke`},_hoisted_19$20={key:1,d:`M-11 -2H1L14 32L1 66H-11V-2Z`,fill:`rgb(var(--chevron-color))`,"fill-opacity":`var(--chevron-alpha)`,stroke:`var(--bng-add-red-500)`,"stroke-width":`3`,"vector-effect":`non-scaling-stroke`},_hoisted_20$17={class:`buttons content`},__default__$3={wrapper:{fade:!0,blur:!0,style:popupContainer.default},position:[popupPosition.center,popupPosition.center]},_sfc_main$260=Object.assign(__default__$3,{__name:`CargoLoadPopup`,props:{cargo:Object,storageData:Object,throwAway:Boolean},emits:[`return`],setup(__props,{emit:__emit}){let cargoOverviewStore=useCargoOverviewStore(),{events:events$3}=useBridge(),{units}=useBridge();useUINavScope(`cargoLoadPopup`);let emit$1=__emit,props=__props,isFacilityCard=ref(!1),vehicleFilterModel=ref([]),vehicleFilterOptions=ref([]),vehicleFilterChanged=function(filter){for(let target of targetLocations.value)target.hidden=target.containerVehicleInfo&&!filter.includes(target.containerVehicleInfo.vehId)},originalTransientMoveCounts=0,original_transientMaterialMoveAmount=0,card=ref({});ref(0);let throwAwayValue=ref(0),trashMeta=ref({}),loadingName=ref(``),slotsPerItem=ref(0),weightPerItem=ref(0),moneyRewardPerItem=ref(0),targetLocations=ref({}),less=function(target){target?(target.loadSliderValue=Math.max(0,target.loadSliderValue-1),updateSliderAmounts(target)):(throwAwayValue.value=Math.max(0,throwAwayValue.value-1),updateThrowAwayAmount())},more=function(target){target?(target.loadSliderValue=Math.min(target.loadSliderMax,target.loadSliderValue+1),updateSliderAmounts(target)):(throwAwayValue.value=Math.min(totalAvailableAmount.value,throwAwayValue.value+1),updateThrowAwayAmount())},acceptClickHandler=()=>{let loadIdx=0;if(props.cargo)for(let id of props.cargo.ids)Lua_default.career_modules_delivery_cargoScreen.clearTransientMoveForCargo(id);if(props.storageData&&Lua_default.career_modules_delivery_cargoScreen.clearTransientMovesForStorage(props.storageData.material.id),!props.throwAway)for(let target of targetLocations.value){if(props.cargo)for(let i=0;i{isFacilityCard.value&&(card.value.transientMoveCounts=originalTransientMoveCounts,card.value._transientMaterialMoveAmount=0),emit$1(`return`,!0)},totalAvailableAmount=ref(0),loadedAmount=ref(0),updateSliderAmounts=changedItem=>{loadedAmount.value=0;for(let target of targetLocations.value)target.maxAmount&&(loadedAmount.value+=target.loadSliderValue);let tooMuch=loadedAmount.value-totalAvailableAmount.value;if(tooMuch>0){for(let target of targetLocations.value)if(target.maxAmount&&target!==changedItem){let before=target.loadSliderValue;target.loadSliderValue=Math.max(0,target.loadSliderValue-tooMuch);let diff=target.loadSliderValue-before;tooMuch+=diff}loadedAmount.value=totalAvailableAmount.value}for(let target of targetLocations.value)target.meta.usedCargoSlots=target.usedCargoSlots+target.loadSliderValue*slotsPerItem.value,target.meta.fillPercentHighlight=target.meta.usedCargoSlots/target.meta.totalCargoSlots;isFacilityCard.value&&(throwAwayValue.value=totalAvailableAmount.value-loadedAmount.value,card.value.transientMoveCounts=loadedAmount.value,card.value._transientMaterialMoveAmount=loadedAmount.value,trashMeta.value.fillPercent=throwAwayValue.value/totalAvailableAmount.value)},updateThrowAwayAmount=()=>{loadedAmount.value=0;for(let target of targetLocations.value)target.maxAmount&&(loadedAmount.value+=target.loadSliderValue);let tooMuch=loadedAmount.value-totalAvailableAmount.value+throwAwayValue.value;for(let target of targetLocations.value){if(target.maxAmount){let before=target.loadSliderValue;target.loadSliderValue=Math.min(target.loadSliderMax,Math.max(0,target.loadSliderValue-tooMuch));let diff=target.loadSliderValue-before;tooMuch+=diff}loadedAmount.value=totalAvailableAmount.value}updateSliderAmounts()},splittable=ref(!1);return onMounted(()=>{if(getUINavServiceInstance().activate(),getUINavServiceInstance().clearFilteredEvents(),props.cargo){if(loadingName.value=props.cargo.name,slotsPerItem.value=props.cargo.slots,weightPerItem.value=props.cargo.weight,moneyRewardPerItem.value=props.cargo.rewardMoney,targetLocations.value=props.cargo.targetLocations,totalAvailableAmount.value=props.cargo.ids.length,props.cargo.splittable){splittable.value=!0,totalAvailableAmount.value=props.cargo.slots,slotsPerItem.value=1;for(let target of targetLocations.value)target.maxAmount=target.totalCargoSlots-target.usedCargoSlots}card.value=props.cargo,isFacilityCard.value=card.value.isFacilityCard,originalTransientMoveCounts=card.value.transientMoveCounts}props.storageData&&(console.log(props.storageData),loadingName.value=props.storageData.material.name,slotsPerItem.value=1,weightPerItem.value=props.storageData.material.density,moneyRewardPerItem.value=1,targetLocations.value=props.storageData.targetLocations,totalAvailableAmount.value=props.storageData.storage.storedVolume,card.value=props.storageData,isFacilityCard.value=card.value.isFacilityCard),targetLocations.value.length||(targetLocations.value=[]);for(let target of targetLocations.value)target.loadSliderValue=ref(target.selectedAmount),target.loadSliderMax=ref(Math.min(target.maxAmount,totalAvailableAmount.value)),target.meta={type:`container`,usedCargoSlots:target.usedCargoSlots,totalCargoSlots:target.totalCargoSlots,icon:`cardboardBox`,fillPercent:target.usedCargoSlots/target.totalCargoSlots};updateSliderAmounts();let vehicles={};for(let target of targetLocations.value)target.containerVehicleInfo&&(vehicles[target.containerVehicleInfo.vehId]=target.containerVehicleInfo);for(let vehId in vehicleFilterOptions.value=[],vehicles){let veh=vehicles[vehId];vehicleFilterOptions.value.push({value:veh.vehId,label:veh.vehName})}for(let vehId in vehicleFilterOptions.value.sort((a$1,b)=>a$1.name{window.bngVue.getCurrentRoute().name==`unknown`&&getUINavServiceInstance().setFilteredEventsAllExcept(UI_EVENTS.menu,UI_EVENTS.pause,UI_EVENTS.center_cam)}),(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$231,[createVNode(unref(bngCard_default),null,{default:withCtx(()=>[__props.throwAway?(openBlock(),createBlock(unref(bngCardHeading_default),{key:1,type:`ribbon`},{default:withCtx(()=>[createTextVNode(` Throwing away `+toDisplayString(loadingName.value),1)]),_:1})):(openBlock(),createBlock(unref(bngCardHeading_default),{key:0,type:`ribbon`},{default:withCtx(()=>[..._cache[4]||=[createTextVNode(`Custom Loading`,-1)]]),_:1})),createBaseVNode(`div`,_hoisted_2$189,[createVNode(CargoCard_default,{ribbon:!1,card:card.value,hideProps:!1,hideModsAndTimer:!0,showButtons:!1,detailed:!0,alwaysShowLoadingWrapper:isFacilityCard.value},null,8,[`card`,`alwaysShowLoadingWrapper`])]),_ctx.vehicles&&_ctx.vehicles.length>1?(openBlock(),createElementBlock(Fragment,{key:2},[_cache[5]||=createBaseVNode(`span`,null,`Vehicles`,-1),__props.throwAway?createCommentVNode(``,!0):(openBlock(),createBlock(unref(bngPillFilters_default),{key:0,modelValue:vehicleFilterModel.value,"onUpdate:modelValue":_cache[0]||=$event=>vehicleFilterModel.value=$event,selectMany:``,options:vehicleFilterOptions.value,showCheckIcon:!1,onValueChanged:vehicleFilterChanged},null,8,[`modelValue`,`options`]))],64)):createCommentVNode(``,!0),createBaseVNode(`div`,_hoisted_3$165,[targetLocations.value&&!__props.throwAway?(openBlock(!0),createElementBlock(Fragment,{key:0},renderList(targetLocations.value,(target,targetIndex)=>(openBlock(),createElementBlock(Fragment,null,[target.hidden?createCommentVNode(``,!0):(openBlock(),createElementBlock(`div`,_hoisted_4$138,[createVNode(CardGroup_default,{label:target.label,meta:target.meta},{default:withCtx(()=>[createBaseVNode(`div`,{class:normalizeClass([`to-load`,{"none-assigned":target.loadSliderValue==0}])},[createBaseVNode(`div`,_hoisted_5$120,[createVNode(unref(bngButton_default),{class:`less`,iconLeft:unref(icons).minus,accent:`text`,onClick:$event=>less(target)},null,8,[`iconLeft`,`onClick`]),createVNode(unref(bngSlider_default),{"bng-no-nav":``,class:`slider`,min:0,max:target.loadSliderMax,step:1,modelValue:target.loadSliderValue,"onUpdate:modelValue":$event=>target.loadSliderValue=$event,onValueChanged:$event=>updateSliderAmounts(target)},null,8,[`max`,`modelValue`,`onUpdate:modelValue`,`onValueChanged`]),createVNode(unref(bngButton_default),{class:`more`,iconLeft:unref(icons).plus,accent:`text`,onClick:$event=>more(target)},null,8,[`iconLeft`,`onClick`]),createBaseVNode(`div`,_hoisted_6$103,`×`+toDisplayString(target.loadSliderValue),1)]),createBaseVNode(`div`,_hoisted_7$90,[(openBlock(),createElementBlock(`svg`,_hoisted_8$75,[(openBlock(),createElementBlock(`svg`,_hoisted_9$68,[target.loadSliderValue===0?(openBlock(),createElementBlock(`path`,_hoisted_10$59)):(openBlock(),createElementBlock(`path`,_hoisted_11$53))]))]))])],2)]),_:2},1032,[`label`,`meta`])]))],64))),256)):createCommentVNode(``,!0),__props.cargo&&__props.cargo.throwAwayInfo&&unref(totalAvailableAmount)?(openBlock(),createElementBlock(`div`,_hoisted_12$42,[createVNode(CardGroup_default,{label:`Trash`,meta:trashMeta.value},{default:withCtx(()=>[createBaseVNode(`div`,{class:normalizeClass([`to-load`,{"none-assigned":throwAwayValue.value==0}])},[createBaseVNode(`div`,_hoisted_13$35,[createVNode(unref(bngButton_default),{class:`less`,iconLeft:unref(icons).minus,accent:`text`,onClick:_cache[1]||=$event=>less()},null,8,[`iconLeft`]),createVNode(unref(bngSlider_default),{"bng-no-nav":``,class:`slider`,min:0,max:unref(totalAvailableAmount),step:1,modelValue:throwAwayValue.value,"onUpdate:modelValue":_cache[2]||=$event=>throwAwayValue.value=$event,onValueChanged:updateThrowAwayAmount},null,8,[`max`,`modelValue`]),createVNode(unref(bngButton_default),{class:`more`,iconLeft:unref(icons).plus,accent:`text`,onClick:_cache[3]||=$event=>more()},null,8,[`iconLeft`]),createBaseVNode(`div`,_hoisted_14$33,`×`+toDisplayString(throwAwayValue.value),1)]),createBaseVNode(`div`,_hoisted_15$32,[(openBlock(),createElementBlock(`svg`,_hoisted_16$32,[(openBlock(),createElementBlock(`svg`,_hoisted_17$26,[throwAwayValue.value===0?(openBlock(),createElementBlock(`path`,_hoisted_18$23)):(openBlock(),createElementBlock(`path`,_hoisted_19$20))]))]))])],2)]),_:1},8,[`meta`])])):createCommentVNode(``,!0)]),createBaseVNode(`div`,_hoisted_20$17,[withDirectives(createVNode(unref(bngButton_default),{class:`button`,label:`Cancel`,accent:`secondary`,onClick:cancelClickHandler},null,512),[[unref(BngOnUiNav_default),void 0,`back,menu`,{asMouse:!0}]]),__props.cargo&&__props.cargo.throwAwayInfo&&throwAwayValue.value>0?withDirectives((openBlock(),createBlock(unref(bngButton_default),{key:0,class:`button`,accent:`attention`,onClick:acceptClickHandler},{default:withCtx(()=>[createTextVNode(toDisplayString(__props.throwAway?`Throw Away`:`Accept`)+` (`,1),createVNode(unref(bngUnit_default),{money:-__props.cargo.throwAwayInfo.penalty*throwAwayValue.value},null,8,[`money`]),_cache[6]||=createTextVNode(`) `,-1)]),_:1})),[[unref(BngFocusIf_default),!0],[unref(BngOnUiNav_default),void 0,`back,menu`,{asMouse:!0}]]):withDirectives((openBlock(),createBlock(unref(bngButton_default),{key:1,class:`button`,label:`Accept`,accent:`main`,onClick:acceptClickHandler},null,512)),[[unref(BngFocusIf_default),!0],[unref(BngOnUiNav_default),void 0,`back,menu`,{asMouse:!0}]])])]),_:1})]))}}),CargoLoadPopup_default=__plugin_vue_export_helper_default(_sfc_main$260,[[`__scopeId`,`data-v-0d30652e`]]),_hoisted_1$230={class:`settings-wrapper`,"bng-ui-scope":`cargoScreenSettings`},_hoisted_2$188={class:`cardContent`},_hoisted_3$164={class:`content`},_hoisted_4$137={class:`acceptButton`},__default__$2={wrapper:{fade:!0,blur:!0,style:popupContainer.default},position:[popupPosition.center,popupPosition.center]},_sfc_main$259=Object.assign(__default__$2,{__name:`CargoScreenSettings`,emits:[`return`],setup(__props,{emit:__emit}){useUINavScope(`cargoScreenSettings`);let emit$1=__emit,cargoOverviewStore=useCargoOverviewStore();ref();let facilityGroupingItems=[{label:`Item one`,value:1},{label:`Item two`,value:2},{label:`Item three`,value:3},{label:`Item four`,value:4},{label:`Item five`,value:5},{label:`Item six`,value:6},{label:`Item seven`,value:7},{label:`Item eight`,value:8},{label:`Item nine`,value:9},{label:`Item ten`,value:10},{label:`Item eleven`,value:11},{label:`Item twelve`,value:12},{label:`Item thirteen`,value:13},{label:`Item fourteen`,value:14},{label:`Item fifteen`,value:15},{label:`Item sixteen`,value:16},{label:`Item seventeen`,value:17},{label:`Item eighteen`,value:18},{label:`Item nineteen`,value:19},{label:`Item twenty`,value:20}];ref(),ref(),ref();let setFacilityGroupKey=key=>{cargoOverviewStore.facilityGroupingKey=key},setFacilitySortKey=key=>{cargoOverviewStore.facilitySortingKey=key},setPlayerGroupKey=key=>{cargoOverviewStore.playerGroupingKey=key},setPlayerSortKey=key=>{cargoOverviewStore.playerSortingKey=key};onMounted(()=>{console.log(facilityGroupingItems)});let acceptClickHandler=()=>{emit$1(`return`,!0)};return(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$230,[createVNode(unref(bngCard_default),null,{default:withCtx(()=>[createVNode(unref(bngCardHeading_default),{type:`ribbon`},{default:withCtx(()=>[..._cache[1]||=[createTextVNode(`Settings`,-1)]]),_:1}),createVNode(unref(bngCardHeading_default),null,{default:withCtx(()=>[..._cache[2]||=[createTextVNode(`Facility Display`,-1)]]),_:1}),createBaseVNode(`div`,_hoisted_2$188,[createBaseVNode(`div`,null,[_cache[3]||=createTextVNode(` Group By: `,-1),(openBlock(!0),createElementBlock(Fragment,null,renderList(unref(cargoOverviewStore).selectedFilter.groupings,gKey=>(openBlock(),createBlock(unref(bngButton_default),{onClick:$event=>setFacilityGroupKey(gKey)},{default:withCtx(()=>[createTextVNode(toDisplayString(unref(cargoOverviewStore).cargoData.facilityCardGroupSets[gKey].label),1)]),_:2},1032,[`onClick`]))),256))]),createBaseVNode(`div`,null,[_cache[4]||=createTextVNode(` Sorting: `,-1),(openBlock(!0),createElementBlock(Fragment,null,renderList(unref(cargoOverviewStore).cargoData.facilityCardGroupSets[unref(cargoOverviewStore).facilityGroupingKey].sortings,sKey=>(openBlock(),createBlock(unref(bngButton_default),{onClick:$event=>setFacilitySortKey(sKey)},{default:withCtx(()=>[createTextVNode(toDisplayString(unref(cargoOverviewStore).cargoData.sortingSets[sKey].label),1)]),_:2},1032,[`onClick`]))),256))])]),createBaseVNode(`div`,_hoisted_3$164,[createVNode(unref(bngCardHeading_default),null,{default:withCtx(()=>[..._cache[5]||=[createTextVNode(`My Cargo Display`,-1)]]),_:1}),createVNode(unref(bngSwitch_default),{modelValue:unref(cargoOverviewStore).automaticRoute,"onUpdate:modelValue":_cache[0]||=$event=>unref(cargoOverviewStore).automaticRoute=$event},{default:withCtx(()=>[..._cache[6]||=[createTextVNode(` Automatic route `,-1)]]),_:1},8,[`modelValue`]),createBaseVNode(`div`,null,[_cache[7]||=createTextVNode(` Group By: `,-1),(openBlock(!0),createElementBlock(Fragment,null,renderList(unref(cargoOverviewStore).playerGroupings,gKey=>(openBlock(),createBlock(unref(bngButton_default),{onClick:$event=>setPlayerGroupKey(gKey)},{default:withCtx(()=>[createTextVNode(toDisplayString(unref(cargoOverviewStore).cargoData.playerCardGroupSets[gKey].label),1)]),_:2},1032,[`onClick`]))),256))]),createBaseVNode(`div`,null,[_cache[8]||=createTextVNode(` Sorting: `,-1),(openBlock(!0),createElementBlock(Fragment,null,renderList(unref(cargoOverviewStore).cargoData.playerCardGroupSets[unref(cargoOverviewStore).facilityGroupingKey].sortings,sKey=>(openBlock(),createBlock(unref(bngButton_default),{onClick:$event=>setPlayerSortKey(sKey)},{default:withCtx(()=>[createTextVNode(toDisplayString(unref(cargoOverviewStore).cargoData.sortingSets[sKey].label),1)]),_:2},1032,[`onClick`]))),256))]),createBaseVNode(`div`,_hoisted_4$137,[withDirectives(createVNode(unref(bngButton_default),{label:`Continue`,accent:unref(ACCENTS).primary,onClick:acceptClickHandler},null,8,[`accent`]),[[unref(BngOnUiNav_default),void 0,`back,menu`,{asMouse:!0}]])])])]),_:1})]))}}),CargoScreenSettings_default=__plugin_vue_export_helper_default(_sfc_main$259,[[`__scopeId`,`data-v-9dd4f12f`]]),_forEach=(arr,func)=>Array.isArray(arr)&&arr.length>0&&arr.forEach(func);const useCargoOverviewStore=defineStore(`cargoOverview`,()=>{let{events:events$3}=useBridge(),cargoData=ref(),dropDownData=ref({}),newCargoAvailable=ref(!1),cargoHighlighted=ref(!1),automaticRoute=ref(!1),detailedDropOff=ref(!1),tutorialInfo=ref(),facilityGroupingKey=ref(`destinations`),facilitySortingKey=ref(`rewardMoney`),playerGroupings=[`containers`,`tasklist`,`ungrouped`],playerGroupingKey=ref(`tasklist`),playerSortingKey=ref(`cardId`),facilityId,parkingSpotPath,facilityFilter={value:`facility-info`,label:`Facility Info`,showInFilterTabs:!0,isFacilityPage:!0},filterSets=ref({}),filterSetsByValue=ref({}),selectedFilterRef=ref(),selectedFilter=ref(facilityFilter),selectFilter=f=>{Lua_default.career_modules_delivery_general.setSetting(`selectedFilterKey`,f),Lua_default.career_modules_delivery_cargoScreen.setCargoScreenTab(f);for(let filter of filterSets.value)if(filter.value==f[0]){let prevGrouping=facilityGroupingKey.value,prevSorting=facilitySortingKey.value;if(selectedFilter.value=filter,!filter.isFacilityPage&&(filter.groupings.includes(prevGrouping)||(facilityGroupingKey.value=filter.groupings[0]),cargoData.value.facilityCardGroupSets[facilityGroupingKey.value].sortings.includes(prevSorting)||(facilitySortingKey.value=cargoData.value.facilityCardGroupSets[facilityGroupingKey.value].sortings[0]),selectedCargo.value&&selectedCargo.value.isFacilityCard)){let contained=selectedCargo.value.filterTags[filter.value];if(contained)for(let groupKey of filter.groupings)for(let group of cargoData.value.facilityCardGroupSets[groupKey].groups)contained||=group.cardIdsUnsorted.includes(selectedCargo.value.cardId);contained||(selectedCargo.value=void 0)}}},facilityGroupings=computed(()=>selectedFilter.value?selectedFilter.value.groupings:[]),nextFacilityGrouping=()=>{let groups=facilityGroupings.value;facilityGroupingKey.value=groups[(groups.indexOf(facilityGroupingKey.value)+1)%groups.length]},facilitySortings=computed(()=>cargoData.value&&facilityGroupingKey.value&&cargoData.value.facilityCardGroupSets&&cargoData.value.facilityCardGroupSets[facilityGroupingKey.value]?cargoData.value.facilityCardGroupSets[facilityGroupingKey.value].sortings:[]),nextFacilitySorting=()=>{let group=facilitySortings.value;facilitySortingKey.value=group[(group.indexOf(facilitySortingKey.value)+1)%group.length]},nextPlayerGrouping=()=>{let groups=playerGroupings;playerGroupingKey.value=groups[(groups.indexOf(playerGroupingKey.value)+1)%groups.length]},playerSortings=computed(()=>cargoData.value&&facilityGroupingKey.value&&cargoData.value.playerCardGroupSets&&cargoData.value.playerCardGroupSets[facilityGroupingKey.value]?cargoData.value.playerCardGroupSets[facilityGroupingKey.value].sortings:[]),nextPlayerSorting=()=>{let group=cargoData.value.playerCardGroupSets[facilityGroupingKey.value];playerSortingKey.value=group[(group.indexOf(playerSortingKey.value)+1)%group.length]},currentFilterTutorialInfo=computed(()=>{if(!tutorialInfo.value||!selectedFilter.value)return null;let info=tutorialInfo.value[selectedFilter.value.value];return!info||!info.unlocked||!info.isActive?null:info}),openCargoScreenSettings=()=>{addPopup(CargoScreenSettings_default)},sortedParcelOffersByCargoType=computed(()=>{if(!cargoData.value||!cargoData.value.facility||!cargoData.value.facility.outgoingCargo)return{};let sorted={};for(let cargoType in _forEach(cargoData.value.facility.outgoingCargo,cargo=>{sorted[cargo.type]||(sorted[cargo.type]=[]),sorted[cargo.type].push(cargo)}),sorted)sorted[cargoType]=sortByProperty(sorted[cargoType]);return sorted}),sortedVehicleOffers=computed(()=>!cargoData.value||!cargoData.value.facility?[]:sortByProperty(cargoData.value.facility.vehicleOffers)),sortedTrailerOffers=computed(()=>!cargoData.value||!cargoData.value.facility?[]:sortByProperty(cargoData.value.facility.trailerOffers)),sortedAcceptedOffers=computed(()=>cargoData.value?sortByProperty(cargoData.value.player.acceptedOffers):[]),loanerOffers=computed(()=>{if(!cargoData.value||!cargoData.value.facility||!cargoData.value.facility.loanableVehicles)return[];let result=[];return result=result.concat(cargoData.value.facility.loanableVehicles),result}),menuClosed=()=>{cargoData.value=void 0,dropDownData.value={},selectedFilter.value=facilityFilter,selectedCargo.value=void 0,Lua_default.career_modules_delivery_cargoScreen.showCargoRoutePreview(void 0),loadingPrompt&&loadingPrompt.close(null)},requestCargoData=(_facilityId,_parkingSpotPath,updateMaxTimeStamp)=>{facilityId=_facilityId,parkingSpotPath=_parkingSpotPath,Lua_default.career_modules_delivery_cargoScreen.requestCargoDataForUi(facilityId,parkingSpotPath,updateMaxTimeStamp),updateMaxTimeStamp!=0&&(newCargoAvailable.value=!1)},requestCargoDataSimple=()=>{requestCargoData(facilityId,parkingSpotPath,!1)},moveCargoToLocation=(cargoId,targetLocation,skipRequest)=>{Lua_default.career_modules_delivery_cargoScreen.moveCargoFromUi(cargoId,targetLocation),skipRequest||requestCargoData(facilityId,parkingSpotPath,!1)},requestMoveCargoToLocation=(cargoId,moveData,skipRequest)=>{moveData.extraData?openThrowAwayPopup(cargoId,moveData.location,`Throw this cargo away with a `+moveData.extraData.penalty.toFixed(2)+` penalty?`):moveCargoToLocation(cargoId,moveData.location,skipRequest)};async function openThrowAwayPopup(cargoId,targetLocation,message){await openConfirmation(null,message)?moveCargoToLocation(cargoId,targetLocation):setCargoData()}let setCargoData=data=>{let previousCardId;if(selectedCargo.value&&(previousCardId=selectedCargo.value.cardId),data&&(cargoData.value=data),dropDownData.value={},cargoData.value.player&&cargoData.value.player.vehicles){getAutomaticRoute(data.settings.automaticRoute),getDetailedDropOff(data.settings.detailedDropOff),automaticRoute.value&&setAutomaticRoute(automaticRoute.value),filterSets.value=data.filterSets,filterSets.value.unshift(facilityFilter);for(let filter of filterSets.value)filterSetsByValue.value[filter.value]=filter;selectedFilter.value||=filterSets.value[0],previousCardId&&onCargoSelected(cargoData.value.cardsById[previousCardId]),tutorialInfo.value=data.tutorialInfo}},highlightedCards=ref({}),highlightCardIds=highlightedIdMap=>{highlightedCards.value=highlightedIdMap},focusedCargo=ref();ref();let selectedCargo=ref(),onCargoHovered=cargo=>{focusedCargo.value=cargo,highlightRoute(focusedCargo.value)},onCargoSelected=cargo=>{selectedCargo.value=cargo},highlightRoute=card=>{card?Lua_default.career_modules_delivery_cargoScreen.showRoutePreview(card.route):Lua_default.career_modules_delivery_cargoScreen.showRoutePreview(void 0)},setAutomaticRoute=(newValue,oldValue)=>{newValue!=oldValue&&Lua_default.career_modules_delivery_general.setAutomaticRoute(newValue)};watch(()=>automaticRoute.value,setAutomaticRoute);let getAutomaticRoute=enabled=>{automaticRoute.value=enabled};watch(()=>detailedDropOff.value,(newValue,oldValue)=>{newValue!=oldValue&&Lua_default.career_modules_delivery_general.setDetailedDropOff(newValue)});let getDetailedDropOff=enabled=>{detailedDropOff.value=enabled},setGroupingAndSorting=()=>{},cardClicked=card=>{switch(card.cardType){case`parcelGroup`:loadCargoAuto(card);break;case`vehicleOffer`:loadOffer(card);break;case`storage`:loadStorageCustom(card);break}},cardDeselect=()=>onCargoSelected(),cardHovered=card=>{onCargoHovered(card)},clearLoad=cargo=>{for(let id of cargo.ids)Lua_default.career_modules_delivery_cargoScreen.clearTransientMoveForCargo(id);requestCargoDataSimple()},throwAway=card=>{loadingPrompt=addPopup(CargoLoadPopup_default,{cargo:card,throwAway:!0}).promise},changeDistribution=cargo=>{for(let[id,card]of Object.entries(cargoData.value.cardsById))if(card.isFacilityCard&&card.cardType==`parcelGroup`&&card.ids.includes(cargo.ids[0])){loadCargoCustom(card);return}},modifyMaterialLoad=cargo=>{for(let[id,card]of Object.entries(cargoData.value.cardsById))if(card.isFacilityCard&&card.cardType==`storage`&&card.storage.materialType==cargo.materialType){loadStorageCustom(card);return}},loadCargoAuto=cargo=>{for(let id of cargo.ids)Lua_default.career_modules_delivery_cargoScreen.clearTransientMoveForCargo(id);let idx=0;for(let loc of cargo.autoLoadLocations)Lua_default.career_modules_delivery_cargoScreen.moveCargoFromUi(cargo.ids[idx],loc),idx++;requestCargoDataSimple()},loadingPrompt=null,loadCargoCustom=card=>{if(card.transientMove){let cargoId=card.ids[0];for(let[id,otherCard]of Object.entries(cargoData.value.cardsById))if(otherCard.isFacilityCard&&otherCard.cardType==`parcelGroup`&&otherCard.ids.includes(cargoId)){loadingPrompt=addPopup(CargoLoadPopup_default,{cargo:otherCard}).promise;return}}else loadingPrompt=addPopup(CargoLoadPopup_default,{cargo:card}).promise},loadStorageCustom=storageData=>{loadingPrompt=addPopup(CargoLoadPopup_default,{storageData}).promise},loadOffer=offer=>{Lua_default.career_modules_delivery_cargoScreen.toggleOfferForSpawning(offer.id),requestCargoDataSimple()},loadLoaner=offer=>{Lua_default.career_modules_loanerVehicles.markForSpawning(offer),requestCargoDataSimple()},returnLoaner=vehId=>{Lua_default.career_modules_loanerVehicles.returnVehicle(vehId).then(()=>{requestCargoDataSimple()})};async function abandonOffer(card){await openConfirmation(null,`Abandon `+card.name+`? There is a `+card.abandonInfo.penaltyMoney+`$ penalty.`)&&(Lua_default.career_modules_delivery_cargoScreen.abandonAcceptedOffer(card.abandonInfo.vehId),requestCargoDataSimple())}return events$3.on(`automaticRouteSet`,getAutomaticRoute),events$3.on(`cargoDataForUiReady`,setCargoData),events$3.on(`newCargoAvailable`,()=>newCargoAvailable.value=!0),events$3.on(`sendHighlightedCardIds`,highlightCardIds),events$3.on(`requestCargoDataSimple`,requestCargoDataSimple),{cargoData,tutorialInfo,sortedParcelOffersByCargoType,sortedVehicleOffers,sortedTrailerOffers,sortedAcceptedOffers,onCargoHovered,onCargoSelected,loanerOffers,dropDownData,newCargoAvailable,cargoHighlighted,automaticRoute,detailedDropOff,setGroupingAndSorting,requestCargoData,requestCargoDataSimple,requestMoveCargoToLocation,menuClosed,dispose:()=>{events$3.off(`cargoDataForUiReady`),events$3.off(`newCargoAvailable`),events$3.off(`sendHighlightedCardIds`),events$3.on(`requestCargoDataSimple`)},focusedCargo,selectedCargo,cardClicked,cardHovered,cardDeselect,clearLoad,changeDistribution,loadCargoAuto,loadCargoCustom,throwAway,loadStorageCustom,loadOffer,abandonOffer,loadLoaner,returnLoaner,modifyMaterialLoad,filterSets,filterSetsByValue,selectedFilterRef,selectedFilter,selectFilter,highlightedCards,openCargoScreenSettings,nextFacilityGrouping,nextFacilitySorting,nextPlayerGrouping,nextPlayerSorting,facilityGroupingKey,facilitySortingKey,playerGroupingKey,playerSortingKey,facilityGroupings,facilitySortings,playerGroupings,playerSortings,currentFilterTutorialInfo}});var _hoisted_1$229={class:`fill-panel`},_hoisted_2$187={key:1,class:`groupGrid`},_sfc_main$258={__name:`ProvidedOrdersPanel`,props:{groupSets:Object,groupIdx:[Number,String],sortingSets:Object,sortIdx:[Number,String],sortAsc:{type:Boolean,default:!0},ignoreFilter:Boolean},setup(__props){let cargoOverviewStore=useCargoOverviewStore(),props=__props;computed(()=>props.groupSets&&props.groupSets[props.groupIdx]&&props.groupSets[props.groupIdx].groups?props.groupSets[props.groupIdx].groups:[]);let sortedGroups=computed(()=>{let groupSet=props.groupSets[props.groupIdx];if(!cargoOverviewStore.cargoData||!cargoOverviewStore.cargoData.cardsById||!groupSet.groups||!groupSet.groups.length)return[];let groups=groupSet.groups,sortKey=props.sortingSets[props.sortIdx].key;function getHighestSortValue(group){let maxSortValue=-1/0;return group.cardIdsUnsorted&&group.cardIdsUnsorted.length&&group.cardIdsUnsorted.forEach(cardId=>{let card=cargoOverviewStore.cargoData.cardsById[cardId];if(card.filterTags[cargoOverviewStore.selectedFilter.value]||group.ignoreFilter||props.ignoreFilter){let sortValue=card.sortValues&&card.sortValues[sortKey]!==void 0?card.sortValues[sortKey]:1/0;sortValue>maxSortValue&&(maxSortValue=sortValue)}}),maxSortValue}return groups.sort((a$1,b)=>{let minValueA=getHighestSortValue(a$1),minValueB=getHighestSortValue(b);return props.sortAsc?minValueA-minValueB:minValueB-minValueA}),groups}),getSortedCardIds=group=>{if(!cargoOverviewStore.cargoData||!cargoOverviewStore.cargoData.cardsById||!group.cardIdsUnsorted)return[];let cardsById=cargoOverviewStore.cargoData.cardsById,sortKey=props.sortingSets[props.sortIdx].key;return group.cardIdsUnsorted&&group.cardIdsUnsorted.length?group.cardIdsUnsorted.slice().sort((a$1,b)=>{let cardA=cardsById[a$1],cardB=cardsById[b],valueA=cardA&&cardA.sortValues&&cardA.sortValues[sortKey]!==void 0?cardA.sortValues[sortKey]:0,valueB=cardB&&cardB.sortValues&&cardB.sortValues[sortKey]!==void 0?cardB.sortValues[sortKey]:0;return props.sortAsc?valueA-valueB:valueB-valueA}):[]};return(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$229,[unref(cargoOverviewStore).cargoData?unref(cargoOverviewStore).cargoData.cardsById?(openBlock(),createElementBlock(`div`,_hoisted_2$187,[(openBlock(!0),createElementBlock(Fragment,null,renderList(sortedGroups.value,group=>(openBlock(),createElementBlock(Fragment,{key:group.label},[(group.cardIdsUnsorted.length>0||group.showEmpty)&&(group.filterTags[unref(cargoOverviewStore).selectedFilter.value]||group.ignoreFilter||__props.ignoreFilter)?(openBlock(),createBlock(CardGroup_default,{key:0,label:group.label,meta:group.meta},{default:withCtx(()=>[(openBlock(!0),createElementBlock(Fragment,null,renderList(getSortedCardIds(group),cardId=>(openBlock(),createElementBlock(Fragment,{key:cardId},[unref(cargoOverviewStore).cargoData.cardsById[cardId].filterTags[unref(cargoOverviewStore).selectedFilter.value]||group.ignoreFilter||__props.ignoreFilter?(openBlock(),createBlock(CargoCard_default,{key:0,card:unref(cargoOverviewStore).cargoData.cardsById[cardId],onClick:withModifiers($event=>unref(cargoOverviewStore).onCargoSelected(unref(cargoOverviewStore).cargoData.cardsById[cardId]),[`stop`]),onMouseover:$event=>unref(cargoOverviewStore).onCargoHovered(unref(cargoOverviewStore).cargoData.cardsById[cardId]),onMouseleave:_cache[0]||=$event=>unref(cargoOverviewStore).onCargoHovered(),hideProps:__props.groupSets[__props.groupIdx].hideProps,hideModsAndTimer:__props.groupSets[__props.groupIdx].hideModsAndTimer},null,8,[`card`,`onClick`,`onMouseover`,`hideProps`,`hideModsAndTimer`])):createCommentVNode(``,!0)],64))),128))]),_:2},1032,[`label`,`meta`])):createCommentVNode(``,!0)],64))),128))])):createCommentVNode(``,!0):(openBlock(),createElementBlock(Fragment,{key:0},[createTextVNode(` No data yet... `)],64))]))}},ProvidedOrdersPanel_default=__plugin_vue_export_helper_default(_sfc_main$258,[[`__scopeId`,`data-v-877d97e8`]]),_hoisted_1$228={class:`header-text`},_hoisted_2$186={key:0,class:`disabled-reason noOffers`},_sfc_main$257={__name:`FilterCard`,props:{filter:Object},setup(__props){let props=__props,cargoOverviewStore=useCargoOverviewStore(),disabled=computed(()=>{if(props.filter){if(!props.filter.hasAvailableOffers)return{disabled:!0};if(props.filter.unavailableAtThisFacility)return{disabled:!0,reason:`Unavailable`};if(props.filter.lockedInfo)return{disabled:!0,reason:props.filter.lockedInfo.shortLabel}}return{disabled:!1}});return onMounted(()=>{}),(_ctx,_cache)=>(openBlock(),createBlock(unref(bngCard_default),{class:normalizeClass([`filterCard`,{disabled:disabled.value.disabled}]),onClick:_cache[0]||=withModifiers($event=>unref(cargoOverviewStore).selectFilter([__props.filter.value]),[`stop`])},{default:withCtx(()=>[createVNode(unref(bngCardHeading_default),{class:`card-heading`},{default:withCtx(()=>[createBaseVNode(`span`,_hoisted_1$228,toDisplayString(__props.filter.label),1)]),_:1}),createVNode(unref(aspectRatio_default),{class:`image`,ratio:`8:3`},{default:withCtx(()=>[createVNode(unref(bngIcon_default),{class:`glyph`,type:unref(icons)[__props.filter.icon]},null,8,[`type`]),createBaseVNode(`div`,{class:normalizeClass([`step`,{none:__props.filter.facilityCards===0}])},[createVNode(unref(bngPropVal_default),{class:`amount-avail`,valueLabel:`× `+__props.filter.facilityCards},null,8,[`valueLabel`])],2)]),_:1}),disabled.value.reason?(openBlock(),createElementBlock(`div`,_hoisted_2$186,[createVNode(unref(bngPropVal_default),{class:`amount-avail`,iconType:unref(icons).lockClosed,valueLabel:disabled.value.reason},null,8,[`iconType`,`valueLabel`])])):createCommentVNode(``,!0)]),_:1},8,[`class`]))}},FilterCard_default=__plugin_vue_export_helper_default(_sfc_main$257,[[`__scopeId`,`data-v-85dcf2d5`]]),_hoisted_1$227={key:0,class:`heading-container`},_hoisted_2$185={class:`status-add`},_hoisted_3$163={class:`controls-row`},_hoisted_4$136={key:1,class:`content-container`},_hoisted_5$119={class:`header-container`},_hoisted_6$102={class:`info-line`},_hoisted_7$89={class:`header-flex padding`},_hoisted_8$74={class:`groupSortButtons`},_hoisted_9$67={class:`scroll-panel`},_hoisted_10$58={key:0,class:`tasklist`},_hoisted_11$52={class:`tasklist-header`},_hoisted_12$41={class:`task-content`},_hoisted_13$34={class:`heading`},_hoisted_14$32={class:`description`},_hoisted_15$31={key:1,class:`empty-cargo-card`},_hoisted_16$31={class:`header-container`},_hoisted_17$25={class:`header-flex`},_hoisted_18$22={key:0,class:`map-overlay`},_hoisted_19$19={key:1,class:`empty-cargo-card`},_hoisted_20$16={class:`header-container`},_hoisted_21$15={class:`info-line`},_hoisted_22$13={class:`header-flex wrap padding`},_hoisted_23$12={class:`groupSortButtons`},_hoisted_24$11={class:`cargohold-info`},_hoisted_25$10={class:`scroll-panel padding`},_hoisted_26$8={class:`content`},_hoisted_27$8={key:0,class:`buttons-wrapper`},_hoisted_28$7={class:`content flex-container`},_hoisted_29$7={key:1,class:`header-flex progress-bar-padding`},_hoisted_30$7={key:0,class:`progress-bar-wrapper wide`},_hoisted_31$7=[`innerHTML`],_hoisted_32$7={class:`info-right`},_hoisted_33$7={key:0},_hoisted_34$7={key:0,class:`header-flex progress-bar-padding`},_hoisted_35$6={class:`progress-bar-wrapper wide`},_hoisted_36$6={class:`content`},_hoisted_37$5={class:`filterSelectGrid`},_sfc_main$256={__name:`CargoOverviewMain`,props:{facilityId:String,parkingSpotPath:String},setup(__props){let tabPills=ref();useUINavScope(`delivery`);let props=__props,cargoOverviewStore=useCargoOverviewStore();async function openDiscardPopup(){await openConfirmation(null,`Discard Changes?`)&&(Lua_default.career_modules_delivery_cargoScreen.cancelDeliveryConfiguration(),Lua_default.career_modules_delivery_cargoScreen.exitCargoOverviewScreen(),window.bngVue.gotoGameState(`play`))}let close=()=>{cargoOverviewStore.cargoData.confirmButtonInfo.itemCount>0&&props.facilityId?openDiscardPopup():(Lua_default.career_modules_delivery_cargoScreen.exitCargoOverviewScreen(),window.bngVue.gotoGameState(`play`))},acceptLoad=()=>{Lua_default.career_modules_delivery_cargoScreen.commitDeliveryConfiguration(),Lua_default.career_modules_delivery_cargoScreen.exitCargoOverviewScreen(),window.bngVue.gotoGameState(`play`)};async function openExitModePopup(){await openConfirmation(null,`Throw away all cargo and exit delivery mode?`)&&(Lua_default.career_modules_delivery_cargoScreen.exitDeliveryMode(),Lua_default.career_modules_delivery_cargoScreen.exitCargoOverviewScreen(),window.bngVue.gotoGameState(`play`))}let exitMode=()=>{openExitModePopup()};async function gotoSkillProgress(panel){cargoOverviewStore.cargoData.confirmButtonInfo.itemCount>0||window.bngVue.gotoGameState(`branchPage`,{params:{branchKey:panel.branchId,skillKey:panel.skillId}})}async function gotoOrganizations(id){cargoOverviewStore.cargoData.confirmButtonInfo.itemCount>0||window.bngVue.gotoGameState(`organizations`,{params:{orgId:id}})}let facilitySortAsc=ref(!1),playerSortAsc=ref(!0),activePopovers={},popShown=pop=>nextTick(()=>activePopovers[pop.name]=pop),popHidden=pop=>nextTick(()=>delete activePopovers[pop.name]);function popHideAll(){for(let pop of Object.values(activePopovers))pop.hide()}let screenCover=ref(),mapPanel=ref(null),observer$2,mapClipChanged;function resizer(){let elScreen=screenCover.value?.$el||screenCover.value;if(!mapPanel.value||!elScreen){mapClipChanged&&(mapClipChanged=!1,screenCover.value.style.setProperty(`--map-clip`,`unset`));return}let pad=3,{width:width$1,height:height$1}=elScreen.getBoundingClientRect(),rect=mapPanel.value.getBoundingClientRect(),percentile=[(rect.x+3)/width$1,(rect.y+3)/height$1,(rect.x+rect.width-3)/width$1,(rect.y+rect.height-3)/height$1].map(n=>`${n*100}%`);elScreen.style.setProperty(`--map-clip`,`polygon(0% 0%, 100% 0%, 100% 100%, 0% 100%, 0% 0%, ${percentile[0]} ${percentile[1]}, ${percentile[0]} ${percentile[3]}, ${percentile[2]} ${percentile[3]}, ${percentile[2]} ${percentile[1]}, ${percentile[0]} ${percentile[1]})`),mapClipChanged=!0,Lua_default.freeroam_bigMapMode.setBigmapScreenBounds({width:width$1,height:height$1},rect)}watch(()=>mapPanel.value,(elm,prev)=>{prev&&observer$2.unobserve(prev),elm&&observer$2.observe(elm)},{immediate:!0}),watch(()=>cargoOverviewStore.selectedFilter?.isFacilityPage,()=>nextTick(resizer));let selectedFilters=ref([]);return watch(()=>cargoOverviewStore.selectedFilter,filter=>{selectedFilters.value=[filter.value],cargoOverviewStore.focusedCargo=null}),onMounted(()=>{observer$2=new ResizeObserver(resizer),resizer(),cargoOverviewStore.requestCargoData(props.facilityId,props.parkingSpotPath),selectedFilters.value=[cargoOverviewStore.selectedFilter.value]}),onBeforeUnmount(()=>{observer$2?.disconnect()}),onUnmounted(()=>{Lua_default.career_modules_delivery_cargoScreen.exitCargoOverviewScreen(),cargoOverviewStore.menuClosed()}),(_ctx,_cache)=>(openBlock(),createBlock(unref(layoutSingle_default),{class:`cargo-overview-main-layout`,"bng-ui-scope":`delivery`,ref_key:`screenCover`,ref:screenCover},{default:withCtx(()=>[createBaseVNode(`div`,{class:`screen`,onClick:_cache[10]||=$event=>unref(cargoOverviewStore).cardDeselect(),onClickCapture:popHideAll},[unref(cargoOverviewStore).cargoData?(openBlock(),createElementBlock(`div`,_hoisted_1$227,[createVNode(unref(bngScreenHeading_default),{preheadings:[`Delivery Mode`],divider:``},{default:withCtx(()=>[createTextVNode(toDisplayString(unref(cargoOverviewStore).cargoData.facility?unref(cargoOverviewStore).cargoData.facility.name:`My Cargo`),1)]),_:1}),createVNode(unref(bngCard_default),{class:`status-container`},{default:withCtx(()=>[createVNode(unref(careerStatus_default)),createBaseVNode(`div`,_hoisted_2$185,[(openBlock(!0),createElementBlock(Fragment,null,renderList(unref(cargoOverviewStore).cargoData.skillLevels,(skill,index)=>(openBlock(),createBlock(unref(bngPropVal_default),{key:index,iconType:unref(icons)[skill.icon],valueLabel:_ctx.$ctx_t(skill.levelLabel)},null,8,[`iconType`,`valueLabel`]))),128)),unref(cargoOverviewStore).cargoData.facility&&unref(cargoOverviewStore).cargoData.facility.organization?(openBlock(),createBlock(unref(bngPropVal_default),{key:0,iconType:unref(icons).peopleOutline,valueLabel:_ctx.$ctx_t(unref(cargoOverviewStore).cargoData.facility.organization.reputation.label)},null,8,[`iconType`,`valueLabel`])):createCommentVNode(``,!0)])]),_:1})])):createCommentVNode(``,!0),createBaseVNode(`div`,_hoisted_3$163,[withDirectives((openBlock(),createBlock(unref(bngButton_default),{class:`back-button`,accent:unref(ACCENTS).attention,onClick:close},{default:withCtx(()=>[createVNode(unref(bngBinding_default),{"ui-event":`back`,deviceMask:`xinput`}),createTextVNode(` `+toDisplayString(_ctx.$t(`ui.common.close`)),1)]),_:1},8,[`accent`])),[[unref(BngOnUiNav_default),void 0,`back,menu`,{asMouse:!0}]]),unref(cargoOverviewStore).cargoData&&unref(cargoOverviewStore).filterSets&&__props.facilityId?(openBlock(),createBlock(unref(bngPillFilters_default),{key:0,ref_key:`tabPills`,ref:tabPills,required:``,modelValue:selectedFilters.value,"onUpdate:modelValue":_cache[0]||=$event=>selectedFilters.value=$event,options:unref(cargoOverviewStore).filterSets,onValueChanged:unref(cargoOverviewStore).selectFilter},null,8,[`modelValue`,`options`,`onValueChanged`])):createCommentVNode(``,!0),!__props.facilityId&&unref(cargoOverviewStore).cargoData&&unref(cargoOverviewStore).cargoData.player.penaltyForAbandon.money<0?(openBlock(),createBlock(unref(bngButton_default),{key:1,accent:`attention`,iconLeft:unref(icons).trashBin1,onClick:exitMode,class:`right-button`},{default:withCtx(()=>[..._cache[11]||=[createTextVNode(` Abandon all deliveries `,-1)]]),_:1},8,[`iconLeft`])):createCommentVNode(``,!0)]),unref(cargoOverviewStore).cargoData?(openBlock(),createElementBlock(`div`,_hoisted_4$136,[!unref(cargoOverviewStore).selectedFilter.isFacilityPage||!__props.facilityId?(openBlock(),createElementBlock(`div`,{key:0,class:normalizeClass([`panel-flex`,{reverse:!__props.facilityId}])},[__props.facilityId?(openBlock(),createBlock(unref(bngCard_default),{key:0,class:`content-row provided-orders-panel`},{default:withCtx(()=>[createBaseVNode(`div`,_hoisted_5$119,[unref(cargoOverviewStore).selectedFilter?(openBlock(),createBlock(unref(bngCardHeading_default),{key:0,type:`ribbon`,class:`cardHeadingFlex wide`},{default:withCtx(()=>[createBaseVNode(`span`,null,toDisplayString(unref(cargoOverviewStore).selectedFilter.label),1),unref(cargoOverviewStore).selectedFilter.howTo?(openBlock(),createBlock(TutorialButton_default,{key:0,class:`howto-button right`,accent:`secondary`,icon:unref(icons).help,pages:unref(cargoOverviewStore).selectedFilter.howTo.pages},null,8,[`icon`,`pages`])):createCommentVNode(``,!0)]),_:1})):createCommentVNode(``,!0),createBaseVNode(`div`,_hoisted_6$102,[createVNode(unref(bngIcon_default),{type:unref(icons).info},null,8,[`type`]),createBaseVNode(`span`,null,toDisplayString(unref(cargoOverviewStore).selectedFilter.shortDescription),1)]),createBaseVNode(`div`,_hoisted_7$89,[withDirectives((openBlock(),createBlock(unref(bngButton_default),{class:`groupSortButton`,accent:unref(ACCENTS).text,icon:unref(icons).group,onClick:_cache[1]||=withModifiers(()=>{},[`stop`])},{default:withCtx(()=>[createTextVNode(` Grouping: `+toDisplayString(unref(cargoOverviewStore).cargoData.facilityCardGroupSets[unref(cargoOverviewStore).facilityGroupingKey].label),1)]),_:1},8,[`accent`,`icon`])),[[unref(BngPopover_default),`facility-grouping`,`bottom`,{click:!0}]]),createVNode(unref(bngPopoverMenu_default),{name:`facility-grouping`,focus:``,onShow:popShown,onHide:popHidden},{default:withCtx(({hide:hide$2})=>[(openBlock(!0),createElementBlock(Fragment,null,renderList(unref(cargoOverviewStore).facilityGroupings,key=>withDirectives((openBlock(),createBlock(unref(bngButton_default),{key,accent:unref(ACCENTS).menu,class:normalizeClass({selected:unref(cargoOverviewStore).facilityGroupingKey===key}),onClick:withModifiers(()=>{unref(cargoOverviewStore).facilityGroupingKey=key,hide$2()},[`stop`])},{default:withCtx(()=>[createTextVNode(toDisplayString(unref(cargoOverviewStore).cargoData.facilityCardGroupSets[key].label),1)]),_:2},1032,[`accent`,`class`,`onClick`])),[[unref(BngOnUiNav_default),void 0,`ok`,{focusRequired:!0,asMouse:!0}]])),128))]),_:1}),createBaseVNode(`div`,_hoisted_8$74,[withDirectives((openBlock(),createBlock(unref(bngButton_default),{class:`groupSortButton`,accent:unref(ACCENTS).text,icon:unref(icons).order,onClick:_cache[2]||=withModifiers(()=>{},[`stop`])},{default:withCtx(()=>[createTextVNode(` Sorting: `+toDisplayString(unref(cargoOverviewStore).cargoData.sortingSets[unref(cargoOverviewStore).facilitySortingKey].label),1)]),_:1},8,[`accent`,`icon`])),[[unref(BngPopover_default),`facility-sorting`,`bottom`,{click:!0}]]),withDirectives(createVNode(unref(bngButton_default),{class:`groupSortButtonSmall`,accent:unref(ACCENTS).text,icon:facilitySortAsc.value?unref(icons).sortAsc:unref(icons).sortDesc,onClick:_cache[3]||=withModifiers($event=>facilitySortAsc.value=!facilitySortAsc.value,[`stop`])},null,8,[`accent`,`icon`]),[[unref(BngTooltip_default),facilitySortAsc.value?`Ascending order`:`Descending order`,`top`]])]),createVNode(unref(bngPopoverMenu_default),{name:`facility-sorting`,focus:``,onShow:popShown,onHide:popHidden},{default:withCtx(({hide:hide$2})=>[(openBlock(!0),createElementBlock(Fragment,null,renderList(unref(cargoOverviewStore).facilitySortings,key=>withDirectives((openBlock(),createBlock(unref(bngButton_default),{key,accent:unref(ACCENTS).menu,class:normalizeClass({selected:unref(cargoOverviewStore).facilitySortingKey===key}),onClick:()=>{unref(cargoOverviewStore).facilitySortingKey=key,hide$2()}},{default:withCtx(()=>[createTextVNode(toDisplayString(unref(cargoOverviewStore).cargoData.sortingSets[key].label),1)]),_:2},1032,[`accent`,`class`,`onClick`])),[[unref(BngOnUiNav_default),void 0,`ok`,{focusRequired:!0,asMouse:!0}]])),128))]),_:1})])]),_cache[12]||=createBaseVNode(`div`,{class:`separator`},null,-1),createBaseVNode(`div`,_hoisted_9$67,[unref(cargoOverviewStore).currentFilterTutorialInfo?.tasks?(openBlock(),createElementBlock(`div`,_hoisted_10$58,[createBaseVNode(`div`,_hoisted_11$52,toDisplayString(unref(cargoOverviewStore).selectedFilter.label)+` Tutorial `,1),(openBlock(!0),createElementBlock(Fragment,null,renderList(unref(cargoOverviewStore).currentFilterTutorialInfo.tasks,task=>(openBlock(),createElementBlock(`div`,{class:`task`,key:task.label},[createVNode(unref(bngIcon_default),{class:`icon`,type:unref(icons)[task.done?`checkboxOn`:`checkboxOff`]},null,8,[`type`]),createBaseVNode(`div`,_hoisted_12$41,[createBaseVNode(`div`,_hoisted_13$34,toDisplayString(task.label),1),createBaseVNode(`div`,_hoisted_14$32,toDisplayString(task.description),1)])]))),128))])):createCommentVNode(``,!0),createVNode(ProvidedOrdersPanel_default,{groupSets:unref(cargoOverviewStore).cargoData.facilityCardGroupSets,groupIdx:unref(cargoOverviewStore).facilityGroupingKey,sortingSets:unref(cargoOverviewStore).cargoData.sortingSets,sortIdx:unref(cargoOverviewStore).facilitySortingKey,sortAsc:facilitySortAsc.value,onCardHovered:unref(cargoOverviewStore).cardHovered,onCardClicked:unref(cargoOverviewStore).cardClicked},null,8,[`groupSets`,`groupIdx`,`sortingSets`,`sortIdx`,`sortAsc`,`onCardHovered`,`onCardClicked`])])]),_:1})):createCommentVNode(``,!0),createBaseVNode(`div`,{class:normalizeClass([`content-row selected-and-map-panel`,{wide:!__props.facilityId}])},[__props.facilityId?(openBlock(),createBlock(unref(bngCard_default),{key:0,class:`cargo-detail`},{default:withCtx(()=>[unref(cargoOverviewStore).focusedCargo||unref(cargoOverviewStore).selectedCargo?(openBlock(),createBlock(CargoCard_default,{key:0,card:unref(cargoOverviewStore).focusedCargo||unref(cargoOverviewStore).selectedCargo,detailed:``,"show-buttons":!unref(cargoOverviewStore).focusedCargo&&unref(cargoOverviewStore).selectedCargo||unref(cargoOverviewStore).focusedCargo===unref(cargoOverviewStore).selectedCargo},null,8,[`card`,`show-buttons`])):(openBlock(),createElementBlock(`div`,_hoisted_15$31,`Select a card to view details.`))]),_:1})):createCommentVNode(``,!0),createBaseVNode(`div`,{class:`map`,ref_key:`mapPanel`,ref:mapPanel},[createBaseVNode(`div`,_hoisted_16$31,[createBaseVNode(`div`,_hoisted_17$25,[createVNode(unref(bngCardHeading_default),{type:`ribbon`,class:`cardHeading wide`},{default:withCtx(()=>[createTextVNode(toDisplayString(_ctx.$t(unref(cargoOverviewStore).cargoData.levelInfo.name)),1)]),_:1}),createVNode(unref(bngSwitch_default),{modelValue:unref(cargoOverviewStore).automaticRoute,"onUpdate:modelValue":_cache[4]||=$event=>unref(cargoOverviewStore).automaticRoute=$event,onClick:_cache[5]||=withModifiers(()=>{},[`stop`])},{default:withCtx(()=>[..._cache[13]||=[createTextVNode(` Automatic route `,-1)]]),_:1},8,[`modelValue`])])]),__props.facilityId?createCommentVNode(``,!0):(openBlock(),createElementBlock(`div`,_hoisted_18$22,[createVNode(unref(bngCard_default),{class:`cargo-detail`},{default:withCtx(()=>[unref(cargoOverviewStore).focusedCargo||unref(cargoOverviewStore).selectedCargo?(openBlock(),createBlock(CargoCard_default,{key:0,card:unref(cargoOverviewStore).focusedCargo||unref(cargoOverviewStore).selectedCargo,detailed:``,"show-buttons":!unref(cargoOverviewStore).focusedCargo&&unref(cargoOverviewStore).selectedCargo||unref(cargoOverviewStore).focusedCargo===unref(cargoOverviewStore).selectedCargo},null,8,[`card`,`show-buttons`])):(openBlock(),createElementBlock(`div`,_hoisted_19$19,` Select a card to view details. `))]),_:1})]))],512)],2),createVNode(unref(bngCard_default),{class:`content-row my-cargo-panel`},{default:withCtx(()=>[createBaseVNode(`div`,_hoisted_20$16,[createVNode(unref(bngCardHeading_default),{type:`ribbon`,class:`cardHeadingFlex wide`},{default:withCtx(()=>[_cache[14]||=createBaseVNode(`span`,null,`My Cargo`,-1),createVNode(TutorialButton_default,{class:`howto-button right`,accent:`secondary`,icon:unref(icons).help,pages:[`delivery/myCargo`,`delivery/parcelDelivery`]},null,8,[`icon`])]),_:1}),createBaseVNode(`div`,_hoisted_21$15,[createVNode(unref(bngIcon_default),{type:unref(icons).info},null,8,[`type`]),_cache[15]||=createBaseVNode(`span`,null,`Check your loaded cargo and other delivery-related tasks.`,-1)]),createBaseVNode(`div`,_hoisted_22$13,[withDirectives((openBlock(),createBlock(unref(bngButton_default),{class:`groupSortButton`,accent:unref(ACCENTS).text,icon:unref(icons).group,onClick:_cache[6]||=withModifiers(()=>{},[`stop`])},{default:withCtx(()=>[createTextVNode(` Grouping: `+toDisplayString(unref(cargoOverviewStore).cargoData.playerCardGroupSets[unref(cargoOverviewStore).playerGroupingKey].label),1)]),_:1},8,[`accent`,`icon`])),[[unref(BngPopover_default),`player-grouping`,`bottom`,{click:!0}]]),createVNode(unref(bngPopoverMenu_default),{name:`player-grouping`,focus:``,onShow:popShown,onHide:popHidden},{default:withCtx(({hide:hide$2})=>[(openBlock(!0),createElementBlock(Fragment,null,renderList(unref(cargoOverviewStore).playerGroupings,key=>withDirectives((openBlock(),createBlock(unref(bngButton_default),{key,accent:unref(ACCENTS).menu,class:normalizeClass({selected:unref(cargoOverviewStore).playerGroupingKey===key}),onClick:()=>{unref(cargoOverviewStore).playerGroupingKey=key,hide$2()}},{default:withCtx(()=>[createTextVNode(toDisplayString(unref(cargoOverviewStore).cargoData.playerCardGroupSets[key].label),1)]),_:2},1032,[`accent`,`class`,`onClick`])),[[unref(BngOnUiNav_default),void 0,`ok`,{focusRequired:!0,asMouse:!0}]])),128))]),_:1}),createBaseVNode(`div`,_hoisted_23$12,[withDirectives((openBlock(),createBlock(unref(bngButton_default),{class:`groupSortButton`,accent:unref(ACCENTS).text,icon:unref(icons).order,onClick:_cache[7]||=withModifiers(()=>{},[`stop`])},{default:withCtx(()=>[createTextVNode(` Sorting: `+toDisplayString(unref(cargoOverviewStore).cargoData.sortingSets[unref(cargoOverviewStore).playerSortingKey].label),1)]),_:1},8,[`accent`,`icon`])),[[unref(BngPopover_default),`player-sorting`,`bottom`,{click:!0}]]),withDirectives(createVNode(unref(bngButton_default),{class:`groupSortButtonSmall`,accent:unref(ACCENTS).text,icon:playerSortAsc.value?unref(icons).sortAsc:unref(icons).sortDesc,onClick:_cache[8]||=withModifiers($event=>playerSortAsc.value=!playerSortAsc.value,[`stop`])},null,8,[`accent`,`icon`]),[[unref(BngTooltip_default),playerSortAsc.value?`Ascending order`:`Descending order`,`top`]])]),createVNode(unref(bngPopoverMenu_default),{name:`player-sorting`,focus:``,onShow:popShown,onHide:popHidden},{default:withCtx(({hide:hide$2})=>[(openBlock(!0),createElementBlock(Fragment,null,renderList(unref(cargoOverviewStore).playerSortings,key=>withDirectives((openBlock(),createBlock(unref(bngButton_default),{key,accent:unref(ACCENTS).menu,class:normalizeClass({selected:unref(cargoOverviewStore).playerSortingKey===key}),onClick:withModifiers(()=>{unref(cargoOverviewStore).playerSortingKey=key,hide$2()},[`stop`])},{default:withCtx(()=>[createTextVNode(toDisplayString(unref(cargoOverviewStore).cargoData.sortingSets[key].label),1)]),_:2},1032,[`accent`,`class`,`onClick`])),[[unref(BngOnUiNav_default),void 0,`ok`,{focusRequired:!0,asMouse:!0}]])),128))]),_:1}),createBaseVNode(`div`,_hoisted_24$11,[(openBlock(!0),createElementBlock(Fragment,null,renderList(unref(cargoOverviewStore).cargoData.playerCardGroupSets.totalStorages.groups,(group,index)=>(openBlock(),createElementBlock(Fragment,{key:index},[group.meta.totalCargoSlots?(openBlock(),createBlock(CargoInfo_default,{key:0,class:`info-with-gradient`,meta:group.meta},null,8,[`meta`])):createCommentVNode(``,!0)],64))),128))])])]),_cache[17]||=createBaseVNode(`div`,{class:`separator`},null,-1),createBaseVNode(`div`,_hoisted_25$10,[unref(cargoOverviewStore).selectedFilter.noContainers?(openBlock(),createBlock(unref(bngCard_default),{key:0,class:`no-container-card`},{default:withCtx(()=>[createBaseVNode(`div`,_hoisted_26$8,[createBaseVNode(`span`,null,[createVNode(unref(bngIcon_default),{type:unref(icons).info},null,8,[`type`]),_cache[16]||=createTextVNode(` You do not have any containers installed that can load this type of cargo. `,-1)]),createVNode(TutorialButton_default,{class:`button`,accent:`secondary`,icon:unref(icons).help,pages:[`delivery/cargoContainerHowTo`],text:`How do I install cargo containers?`},null,8,[`icon`])])]),_:1})):createCommentVNode(``,!0),createVNode(ProvidedOrdersPanel_default,{groupSets:unref(cargoOverviewStore).cargoData.playerCardGroupSets,groupIdx:unref(cargoOverviewStore).playerGroupingKey,sortingSets:unref(cargoOverviewStore).cargoData.sortingSets,sortIdx:unref(cargoOverviewStore).playerSortingKey,sortAsc:playerSortAsc.value,ignoreFilter:!0,onCardHovered:unref(cargoOverviewStore).cardHovered,onCardClicked:unref(cargoOverviewStore).cardClicked},null,8,[`groupSets`,`groupIdx`,`sortingSets`,`sortIdx`,`sortAsc`,`onCardHovered`,`onCardClicked`])]),unref(cargoOverviewStore).cargoData&&__props.facilityId?(openBlock(),createElementBlock(`div`,_hoisted_27$8,[unref(cargoOverviewStore).cargoData.confirmButtonInfo.itemCount>0?(openBlock(),createBlock(unref(bngButton_default),{key:0,class:`accept-button`,icon:unref(icons).checkmark,onClick:withModifiers(acceptLoad,[`stop`])},{default:withCtx(()=>[createTextVNode(` Continue (`+toDisplayString(unref(cargoOverviewStore).cargoData.confirmButtonInfo.itemCount)+` items) `,1)]),_:1},8,[`icon`])):createCommentVNode(``,!0)])):createCommentVNode(``,!0)]),_:1})],2)):(openBlock(),createBlock(unref(bngCard_default),{key:1,class:`detailedFilterSelector`},{default:withCtx(()=>[createBaseVNode(`div`,_hoisted_28$7,[createVNode(unref(bngCard_default),{class:`info-left`},{default:withCtx(()=>[unref(cargoOverviewStore).cargoData.facility.organization?(openBlock(),createBlock(unref(bngCardHeading_default),{key:0,type:`ribbon`,class:`cardHeadingFlex`},{default:withCtx(()=>[createBaseVNode(`span`,null,[_cache[18]||=createBaseVNode(`span`,null,`Reputation:\xA0`,-1),createBaseVNode(`span`,null,toDisplayString(unref(cargoOverviewStore).cargoData.facility.organization.reputation.label+` (lvl `+unref(cargoOverviewStore).cargoData.facility.organization.reputation.level+`)`),1)]),createVNode(unref(bngButton_default),{icon:unref(icons).signal05a,accent:`secondary`,onClick:_cache[9]||=$event=>gotoOrganizations(unref(cargoOverviewStore).cargoData.facility.organization.id)},{default:withCtx(()=>[..._cache[19]||=[createTextVNode(`Progress`,-1)]]),_:1},8,[`icon`])]),_:1})):createCommentVNode(``,!0),unref(cargoOverviewStore).cargoData.facility.organization?(openBlock(),createElementBlock(`div`,_hoisted_29$7,[createVNode(unref(bngIcon_default),{class:`progress-icon`,type:unref(icons).peopleOutline},null,8,[`type`]),unref(cargoOverviewStore).cargoData.facility.organization?(openBlock(),createElementBlock(`div`,_hoisted_30$7,[createVNode(unref(bngProgressBar_default),{class:`bar`,gradient:``,value:unref(cargoOverviewStore).cargoData.facility.organization.reputation.value,max:unref(cargoOverviewStore).cargoData.facility.organization.reputation.nextThreshold,min:unref(cargoOverviewStore).cargoData.facility.organization.prevThreshold,showValueLabel:!1},null,8,[`value`,`max`,`min`])])):createCommentVNode(``,!0)])):createCommentVNode(``,!0),createVNode(unref(aspectRatio_default),{class:`image`,ratio:`5:3`,"external-image":unref(cargoOverviewStore).cargoData.facility.preview},null,8,[`external-image`]),createVNode(unref(bngCardHeading_default),{type:`ribbon`,class:`cardHeading`},{default:withCtx(()=>[..._cache[20]||=[createTextVNode(` Facility Information `,-1)]]),_:1}),createBaseVNode(`div`,{class:`content text-justify`,innerHTML:unref(content_exports).bbcode.parse(unref(cargoOverviewStore).cargoData.facility.longDescription)},null,8,_hoisted_31$7)]),_:1}),createBaseVNode(`div`,_hoisted_32$7,[(openBlock(!0),createElementBlock(Fragment,null,renderList(unref(cargoOverviewStore).cargoData.facilityPanels,(panel,index)=>(openBlock(),createBlock(unref(bngCard_default),{key:index,class:`panel`},{default:withCtx(()=>[createVNode(unref(bngCardHeading_default),{type:`ribbon`,class:`cardHeadingFlex`},{default:withCtx(()=>[createBaseVNode(`span`,null,[createBaseVNode(`span`,null,toDisplayString(panel.heading)+`:\xA0`,1),panel.skillInfo?(openBlock(),createElementBlock(`span`,_hoisted_33$7,toDisplayString(panel.skillInfo.unlocked?_ctx.$ctx_t(panel.skillInfo.levelLabel):``),1)):createCommentVNode(``,!0)]),panel.skillInfo?(openBlock(),createBlock(unref(bngButton_default),{key:0,icon:unref(icons).signal05a,accent:`secondary`,onClick:$event=>gotoSkillProgress(panel)},{default:withCtx(()=>[..._cache[21]||=[createTextVNode(`Progress`,-1)]]),_:1},8,[`icon`,`onClick`])):createCommentVNode(``,!0)]),_:2},1024),panel.skillInfo?(openBlock(),createElementBlock(`div`,_hoisted_34$7,[createVNode(unref(bngIcon_default),{class:`progress-icon`,type:unref(icons)[panel.skillInfo.icon]},null,8,[`type`]),createBaseVNode(`div`,_hoisted_35$6,[createVNode(unref(bngProgressBar_default),{class:`bar`,gradient:``,value:panel.skillInfo.max==-1?1:panel.skillInfo.value-panel.skillInfo.min,max:panel.skillInfo.max==-1?1:panel.skillInfo.max-panel.skillInfo.min,showValueLabel:!0,valueLabelFormat:panel.skillInfo.max===-1?`Max`:panel.skillInfo.value+` XP`},null,8,[`value`,`max`,`valueLabelFormat`])])])):createCommentVNode(``,!0),createBaseVNode(`div`,_hoisted_36$6,[createBaseVNode(`span`,null,[createVNode(unref(bngIcon_default),{type:unref(icons).info},null,8,[`type`]),createTextVNode(` `+toDisplayString(panel.description),1)]),createBaseVNode(`div`,_hoisted_37$5,[(openBlock(!0),createElementBlock(Fragment,null,renderList(panel.filterValueButtons,filterKey=>(openBlock(),createBlock(FilterCard_default,{key:filterKey,filter:unref(cargoOverviewStore).filterSetsByValue[filterKey]},null,8,[`filter`]))),128))])])]),_:2},1024))),128))])])]),_:1}))])):createCommentVNode(``,!0)],32)]),_:1},512))}},CargoOverviewMain_default=__plugin_vue_export_helper_default(_sfc_main$256,[[`__scopeId`,`data-v-719883ab`]]),_hoisted_1$226={class:`unlock-wrapper`,"bng-ui-scope":`cargoUnlockPopup`},_hoisted_2$184={class:`cardContent`},_hoisted_3$162={class:`acceptButton`},__default__$1={wrapper:{fade:!0,blur:!0,style:popupContainer.default},position:[popupPosition.center,popupPosition.center]},_sfc_main$255=Object.assign(__default__$1,{__name:`UnlockPopup`,props:{reward:Object},emits:[`return`],setup(__props,{emit:__emit}){useUINavScope(`cargoUnlockPopup`);let emit$1=__emit,acceptClickHandler=()=>{emit$1(`return`,!0)};return(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$226,[createVNode(unref(bngCard_default),null,{default:withCtx(()=>[createVNode(unref(bngCardHeading_default),{type:`ribbon`},{default:withCtx(()=>[..._cache[0]||=[createTextVNode(` Level Up! `,-1)]]),_:1}),createBaseVNode(`div`,_hoisted_2$184,[createBaseVNode(`h3`,null,toDisplayString(__props.reward.unlockPopupHeader),1),_cache[2]||=createTextVNode(` Unlocks: `,-1),(openBlock(!0),createElementBlock(Fragment,null,renderList(__props.reward.branchLevels[__props.reward.animationData.level-1].unlocks,item=>(openBlock(),createBlock(UnlockCard_default,{class:`tier-unlocks-item`,data:item},null,8,[`data`]))),256)),createBaseVNode(`div`,_hoisted_3$162,[withDirectives((openBlock(),createBlock(unref(bngButton_default),{accent:unref(ACCENTS).primary,onClick:acceptClickHandler},{default:withCtx(()=>[createVNode(unref(bngBinding_default),{"ui-event":`ok`,deviceMask:`xinput`}),_cache[1]||=createBaseVNode(`span`,null,`Continue`,-1)]),_:1},8,[`accent`])),[[unref(BngOnUiNav_default),acceptClickHandler,`ok`]])])])]),_:1})]))}}),UnlockPopup_default=__plugin_vue_export_helper_default(_sfc_main$255,[[`__scopeId`,`data-v-127ed650`]]),_hoisted_1$225={class:`reward-wrapper`},_hoisted_2$183={class:`card-content`},_hoisted_3$161={class:`scroll-wrapper`},_hoisted_4$135={key:0},_hoisted_5$118={class:`cargo-wrapper`},_hoisted_6$101={class:`header`},_hoisted_7$88={class:`amount-controls`},_hoisted_8$73={class:`amount`},_hoisted_9$66={class:`card-content`},_hoisted_10$57={style:{display:`flex`}},_hoisted_11$51={style:{float:`left`}},_hoisted_12$40={key:0,class:`rewards-breakdown-container padding-bottom`},_hoisted_13$33={class:`grid-wrapper`},_hoisted_14$31={class:`grid-row grid`},_hoisted_15$30={class:`label primary`},_hoisted_16$30={class:`rewards primary`},_hoisted_17$24={class:`grid-wrapper wide`},_hoisted_18$21={class:`grid`},_hoisted_19$18={class:`label secondary`},_hoisted_20$15={class:`rewards secondary`},_hoisted_21$14={class:`grid-row grid`},_hoisted_22$12={class:`rewards primary`},_hoisted_23$11={key:1,class:`rewards-breakdown-container padding-bottom`},_hoisted_24$10={class:`grid-wrapper`},_hoisted_25$9={key:0,class:`grid-row grid`},_hoisted_26$7={class:`rewards primary`},_hoisted_27$7={key:1,class:`grid-row grid`},_hoisted_28$6={class:`rewards primary`},_hoisted_29$6={key:2,class:`grid-row grid`},_hoisted_30$6={class:`rewards primary`},_hoisted_31$6={key:3,class:`grid-row grid`},_hoisted_32$6={class:`rewards primary`},_hoisted_33$6={class:`grid-row grid`},_hoisted_34$6={class:`rewards primary`},_hoisted_35$5={style:{float:`left`}},_hoisted_36$5={key:0,style:{float:`left`}},_hoisted_37$4={key:0,class:`numberReward`},_hoisted_38$4={key:1,class:`numberReward`},_hoisted_39$4={key:2},_hoisted_40$3={key:1,style:{float:`left`,width:`100%`,padding:`0.2em`}},_hoisted_41$3={key:2},__default__={wrapper:{fade:!0,blur:!0,style:popupContainer.transparent},position:[popupPosition.center,popupPosition.center]},_sfc_main$254=Object.assign(__default__,{__name:`CargoDropOff`,props:{facilityId:String,parkingSpotPath:String},setup(__props){let ANIMATION_START_DELAY=400,ANIMATION_DURATION=3e3,ANIMATION_UPDATE_RATE=30,BAR_COLOR_DEFAULT=`#ff6600`,BAR_COLOR_ADDITION=`#ff6600`,BAR_COLOR_SUBTRACTION=`#c00000`,MODES={wait:`wait`,cargoSelection:`cargoSelection`,results:`results`},cargoOverviewStore=useCargoOverviewStore();useUINavScope(`cargoDropOff`);let props=__props,{events:events$3}=useBridge(),mode=ref(MODES.wait),data=ref({}),summary=ref([]),showConfirmDelay=ref(!1),confirmButtonEnabled=ref(!1),confirmButtonTimer=ref(0),confirmButtonTimerId=0,rewardAnimationIndex=ref(-1),animationSkipped=!1,showUnloadingDelay=!0,getLevelFromValue=(value,reward)=>{let branchLevels=reward.branchLevels,levelIndex=-1;for(let i=0;i=levelData.requiredValue&&(levelIndex=i)}let maxLevel=!(branchLevels[levelIndex+1]&&branchLevels[levelIndex+1].requiredValue!=null),displayValue=value-branchLevels[levelIndex].requiredValue;return{min:0,max:maxLevel?displayValue:branchLevels[levelIndex+1].requiredValue-branchLevels[levelIndex].requiredValue,displayValue,levelLabel:reward.type==`reputation`?branchLevels[levelIndex].label+` (Level `+(levelIndex-1)+`)`:branchLevels[levelIndex].levelLabel,level:levelIndex+1,maxLevel}},confirm=()=>{rewardAnimationIndex.value<0?confirmButtonEnabled.value&&confirmDropOff():skipAnimations()},getDeliveryList=()=>summary.value.detailledList.map(delivery=>delivery.label).join(`, `),getNiceTime=()=>confirmButtonTimer.value>0?confirmButtonTimer.value.toFixed(1)+`s remaining...`:`Done!`,exit=()=>{window.bngVue.gotoGameState(`play`)};function updateDisplayValue(reward){if(reward.branchLevels&&reward.branchLevels.length){let displayData=getLevelFromValue(reward.animationData.smoothedValue,reward);reward.animationData.max=displayData.max,reward.animationData.displayValue=displayData.displayValue,reward.animationData.levelLabel=displayData.levelLabel,reward.animationData.level=displayData.level,reward.animationData.maxLevel=displayData.maxLevel;let displayDataBefore=getLevelFromValue(reward.animationData.value-reward.rewardAmount,reward);displayData.level==displayDataBefore.level?(reward.animationData.displayValueBefore=displayDataBefore.displayValue,displayData.displayValue>=displayDataBefore.displayValue?(reward.valueColor=BAR_COLOR_ADDITION,reward.valueBeforeColor=BAR_COLOR_DEFAULT):(reward.valueBeforeColor=BAR_COLOR_SUBTRACTION,reward.valueColor=BAR_COLOR_DEFAULT)):displayData.level>displayDataBefore.level?(reward.animationData.displayValueBefore=0,reward.valueColor=BAR_COLOR_ADDITION,reward.valueBeforeColor=BAR_COLOR_DEFAULT):(reward.animationData.displayValueBefore=displayData.max,reward.valueColor=BAR_COLOR_DEFAULT,reward.valueBeforeColor=BAR_COLOR_SUBTRACTION)}}let startSmoothingValue=(reward,duration)=>{reward.animationData.numStep=(reward.animationData.value-reward.animationData.smoothedValue)/duration*30,clearInterval(reward.animationData.numTimer),reward.animationData.numTimer=setInterval(()=>{reward.animationData.smoothedValue+=reward.animationData.numStep,(reward.animationData.numStep>0?reward.animationData.smoothedValue>=reward.animationData.value:reward.animationData.smoothedValue<=reward.animationData.value)&&(Lua_default.career_modules_delivery_progress.activateSound(``,!1),reward.animationData.smoothedValue=reward.animationData.value,reward.animationData.numStep=0,clearInterval(reward.animationData.numTimer)),reward.highlight=reward.animationData.numStep!=0,updateDisplayValue(reward)},30)};async function openNewLevelPopup(reward){Lua_default.Engine.Audio.playOnce(`AudioGui`,`event:>UI>Career>Progress_LevelUp`),await addPopup(UnlockPopup_default,{reward}).promise,startProgressBarAnimation()}function didPlayerLevelUp(reward){let levelBefore=0,levelAfter=0;return reward.branchLevels&&reward.branchLevels.length&&(levelBefore=getLevelFromValue(reward.animationData.value-reward.rewardAmount,reward).level,levelAfter=getLevelFromValue(reward.animationData.value,reward).level),levelBeforeopenNewLevelPopup(reward),duration):setTimeout(startProgressBarAnimation,duration+400);return}rewardAnimationIndex.value=-1}}let start=()=>{getUINavServiceInstance().activate(),getUINavServiceInstance().clearFilteredEvents(),Lua_default.career_modules_delivery_general.setDeliveryTimePaused(!0),Lua_default.career_modules_delivery_cargoScreen.requestDropOffData(props.facilityId,props.parkingSpotPath)},kill=()=>{Lua_default.career_modules_delivery_general.setDeliveryTimePaused(!1),events$3.off(`SetDeliveryDropOffCargoSelection`),events$3.off(`SetDeliveryDropOffRewardResult`),clearInterval(confirmButtonTimerId),Lua_default.career_modules_delivery_cargoScreen.dropOffPopupClosed(mode.value)},confirmSelection=()=>{let confirmedCargoIds=[];data.value.customAmountPerMaterialType.forEach(info=>{info.items.forEach(item=>{item.amountSelector>0&&confirmedCargoIds.push({id:item.ids[0],amount:item.amountSelector})})});let confirmedDropOffs={confirmedCargoIds,confirmedOfferIds:[]};console.log(confirmedDropOffs),Lua_default.career_modules_delivery_cargoScreen.confirmDropOffData(confirmedDropOffs,props.facilityId,props.parkingSpotPath)},confirmDropOff=()=>{exit()},branchInfo;function rewardMapToRewardList(rewards){let newRewards=[];for(let key in rewards){let rewardInfo={attributeKey:key,rewardAmount:rewards[key],order:branchInfo[key].order,animationData:branchInfo[key].animationData,branchLevels:branchInfo[key].branchLevels,showLevelUpPopup:branchInfo[key].showLevelUpPopup,unlockPopupHeader:branchInfo[key].unlockPopupHeader,type:branchInfo[key].type};branchInfo[key].icon&&(rewardInfo.icon=branchInfo[key].icon),newRewards.push(rewardInfo)}return newRewards.sort((a$1,b)=>a$1.order-b.order),newRewards}let cargoBySummaryId=[],calculateSummary=()=>{let simpleBreakdownRewardsByType={base:[],bonus:[],loaner:[],branch:[]};summary.value={detailledList:[],total:{label:`Total`,rewards:{}}};let totalRewards={};for(let id in cargoBySummaryId){let group=cargoBySummaryId[id],first=group.list[0],totalCount=0;for(let cargo of group.list)totalCount+=1;let sum={label:first.name,rewards:rewardMapToRewardList(first.originalRewards),breakdown:[]};for(let i=0;i0&&summary.value.detailledList.push(sum)}if(data.value.rewardOffers.length)for(let veh of data.value.rewardOffers){let sum={label:veh.offer.name,rewards:rewardMapToRewardList(veh.originalRewards),breakdown:[]};if(simpleBreakdownRewardsByType.base.push(veh.originalRewards),veh.breakdown.length)for(let bd of veh.breakdown)sum.breakdown.push({label:bd.label,rewards:rewardMapToRewardList(bd.rewards)}),bd.simpleBreakdownType&&(simpleBreakdownRewardsByType[bd.simpleBreakdownType]||(simpleBreakdownRewardsByType[bd.simpleBreakdownType]=[]),simpleBreakdownRewardsByType[bd.simpleBreakdownType].push(bd.rewards));summary.value.detailledList.push(sum)}for(let type in simpleBreakdownRewardsByType){let sum={};for(let elem of simpleBreakdownRewardsByType[type])for(let attKey in elem)sum[attKey]||(sum[attKey]=0),sum[attKey]+=elem[attKey];simpleBreakdownRewardsByType[type]=rewardMapToRewardList(sum)}summary.value.simpleBreakdown=simpleBreakdownRewardsByType;for(let row of summary.value.detailledList){for(let elem of row.rewards)totalRewards[elem.attributeKey]||(totalRewards[elem.attributeKey]=0),totalRewards[elem.attributeKey]+=elem.rewardAmount;for(let bd of row.breakdown)for(let elem of bd.rewards)totalRewards[elem.attributeKey]||(totalRewards[elem.attributeKey]=0),totalRewards[elem.attributeKey]+=elem.rewardAmount}summary.value.total.rewards=rewardMapToRewardList(totalRewards);let counter$1=0;for(let reward of summary.value.total.rewards)reward.animationData.id!=`missing`&&(reward.animationOrderIndex=counter$1,reward.animationData.smoothedValue=reward.animationData.value-reward.rewardAmount,reward.animationData.numStep=0,reward.highlight=!1,updateDisplayValue(reward),counter$1++);rewardAnimationIndex.value=-1,animationSkipped=!1};events$3.on(`SetDeliveryDropOffCargoSelection`,dd=>{data.value=dd,mode.value=MODES.cargoSelection,branchInfo=dd.branchInfo,showUnloadingDelay=dd.unloadingDelay>.1,data.value.playerVehicleData.length&&data.value.customAmountPerMaterialType.forEach(info=>{let remainingFreeAmount=info.storage.capacity-info.storage.storedVolume;info.items.sort((a$1,b)=>a$1.slots-b.slots),info.items.forEach(item=>{item.amountSelectorPerSlot=item.type===`fluid`||item.type===`dryBulk`,item.maxCount=item.ids.length,item.amountSelectorPerSlot&&(item.maxCount=item.slots),item.amountSelector=ref(Math.max(0,Math.min(item.maxCount,remainingFreeAmount))),remainingFreeAmount-=item.amountSelector,item.showAmountSelector=!0,item.loadSliderMax=Math.min(item.maxCount,info.storage.capacity-info.storage.storedVolume)}),info.meta={type:`container`,usedCargoSlots:info.storage.storedVolume,totalCargoSlots:info.storage.capacity,fillPercent:info.storage.storedVolume/info.storage.capacity,icon:info.material.icon},info.meta.usedCargoSlots=info.storage.storedVolume,info.items.forEach(item=>{info.meta.usedCargoSlots+=item.amountSelector}),info.meta.fillPercentHighlight=info.meta.usedCargoSlots/info.storage.capacity,info.storage.capacity<=info.storage.storedVolume&&(info.isFull=!0)})});let updateSliderAmounts=(info,changedItem)=>{info.meta.usedCargoSlots=info.storage.storedVolume,info.items.forEach(item=>{info.meta.usedCargoSlots+=item.amountSelector});let tooMuch=info.meta.usedCargoSlots-info.meta.totalCargoSlots;tooMuch>0&&(info.items.reverse(),info.items.forEach(item=>{if(item!==changedItem){let before=item.amountSelector;item.amountSelector=Math.max(0,item.amountSelector-tooMuch);let diff=item.amountSelector-before;tooMuch+=diff}}),info.items.reverse()),info.meta.usedCargoSlots=info.storage.storedVolume,info.items.forEach(item=>{info.meta.usedCargoSlots+=item.amountSelector}),info.meta.fillPercentHighlight=info.meta.usedCargoSlots/info.storage.capacity};return events$3.on(`SetDeliveryDropOffRewardResult`,dd=>{if(console.log(`setDropOffRewardResult`,dd),data.value=dd,branchInfo=dd.branchInfo,mode.value=MODES.results,confirmButtonEnabled.value=!0,showConfirmDelay.value=!1,dd.unloadingDelay>.1){confirmButtonEnabled.value=!1,confirmButtonTimer.value=dd.unloadingDelay,showConfirmDelay.value=!0;let endTime=Date.now()+confirmButtonTimer.value*1e3,countdown=()=>{let timeLeft=(endTime-Date.now())/1e3;timeLeft>0?(confirmButtonTimer.value=timeLeft,confirmButtonTimerId=requestAnimationFrame(countdown)):(confirmButtonTimer.value=0,confirmButtonEnabled.value=!0)};confirmButtonTimerId=requestAnimationFrame(countdown),showUnloadingDelay=!0}else showUnloadingDelay=!1;if(dd.rewardParcels.length)for(let cargo of dd.rewardParcels)cargoBySummaryId[cargo.summaryId]||(cargoBySummaryId[cargo.summaryId]={list:[],display:{}}),cargoBySummaryId[cargo.summaryId].list.push(cargo);calculateSummary(),setTimeout(startProgressBarAnimation,400)}),onMounted(start),onUnmounted(kill),(_ctx,_cache)=>mode.value===MODES.wait?createCommentVNode(``,!0):withDirectives((openBlock(),createBlock(unref(layoutSingle_default),{key:0,class:`cargo-drop-off-wrapper`,"bng-ui-scope":`cargoDropOff`},{default:withCtx(()=>[createBaseVNode(`div`,_hoisted_1$225,[mode.value===MODES.cargoSelection?(openBlock(),createBlock(unref(bngCard_default),{key:0},{buttons:withCtx(()=>[createVNode(unref(bngButton_default),{onClick:confirmSelection},{default:withCtx(()=>[createVNode(unref(bngBinding_default),{"ui-event":`ok`,deviceMask:`xinput`}),_cache[4]||=createBaseVNode(`span`,null,`Confirm Selection`,-1)]),_:1})]),default:withCtx(()=>[createVNode(unref(careerStatus_default),{class:`career-status`}),createVNode(unref(bngCardHeading_default),{type:`ribbon`},{default:withCtx(()=>[..._cache[3]||=[createTextVNode(`Dropping off...`,-1)]]),_:1}),createBaseVNode(`div`,_hoisted_2$183,[createVNode(unref(bngPropVal_default),{class:`limited-capacity-info`,valueLabel:`This facility has limited capacity for cargo.`,iconType:unref(icons).info},null,8,[`iconType`]),createBaseVNode(`div`,_hoisted_3$161,[(openBlock(!0),createElementBlock(Fragment,null,renderList(data.value.customAmountPerMaterialType,info=>(openBlock(),createBlock(CardGroup_default,{class:`fullwidth-group`,label:info.material.name,meta:info.meta},{default:withCtx(()=>[info.isFull?(openBlock(),createElementBlock(`div`,_hoisted_4$135,[createVNode(unref(bngPropVal_default),{valueLabel:`The storage for this material is completely filled. Come back later.`,iconType:unref(icons).abandon},null,8,[`iconType`])])):createCommentVNode(``,!0),(openBlock(!0),createElementBlock(Fragment,null,renderList(info.items,item=>(openBlock(),createElementBlock(`div`,_hoisted_5$118,[createBaseVNode(`div`,_hoisted_6$101,[createVNode(unref(bngPropVal_default),{valueLabel:item.originName,keyLabel:`Origin`,iconType:unref(icons).locationSource},null,8,[`valueLabel`,`iconType`]),createVNode(unref(bngPropVal_default),{valueLabel:item.containerName,keyLabel:`Container`,iconType:unref(icons).cardboardBox},null,8,[`valueLabel`,`iconType`])]),createBaseVNode(`div`,_hoisted_7$88,[createVNode(unref(bngButton_default),{disabled:info.isFull,class:`less`,iconLeft:unref(icons).minus,accent:`text`,onClick:_cache[0]||=$event=>_ctx.less(_ctx.target)},null,8,[`disabled`,`iconLeft`]),createVNode(unref(bngSlider_default),{disabled:info.isFull,class:`slider`,min:0,max:item.loadSliderMax,modelValue:item.amountSelector,"onUpdate:modelValue":$event=>item.amountSelector=$event,step:1,onChange:$event=>updateSliderAmounts(info,item)},null,8,[`disabled`,`max`,`modelValue`,`onUpdate:modelValue`,`onChange`]),createVNode(unref(bngButton_default),{disabled:info.isFull,class:`more`,iconLeft:unref(icons).plus,accent:`text`,onClick:_cache[1]||=$event=>_ctx.more(_ctx.target)},null,8,[`disabled`,`iconLeft`]),createBaseVNode(`div`,_hoisted_8$73,toDisplayString(item.amountSelector)+` / `+toDisplayString(item.slots),1)])]))),256))]),_:2},1032,[`label`,`meta`]))),256))])])]),_:1})):createCommentVNode(``,!0),mode.value===MODES.results?(openBlock(),createBlock(unref(bngCard_default),{key:1},{buttons:withCtx(()=>[withDirectives((openBlock(),createBlock(unref(bngButton_default),{disabled:rewardAnimationIndex.value<0&&!confirmButtonEnabled.value,onClick:confirm},{default:withCtx(()=>[createVNode(unref(bngBinding_default),{deviceMask:`xinput`}),createBaseVNode(`span`,null,toDisplayString(rewardAnimationIndex.value<0?`Continue`:`Skip`),1)]),_:1},8,[`disabled`])),[[unref(BngFocusIf_default),rewardAnimationIndex.value==0]])]),default:withCtx(()=>[createVNode(unref(bngCardHeading_default),{type:`ribbon`},{default:withCtx(()=>[..._cache[5]||=[createTextVNode(`Delivery Complete!`,-1)]]),_:1}),createBaseVNode(`div`,_hoisted_9$66,[createBaseVNode(`div`,_hoisted_10$57,[createBaseVNode(`h3`,_hoisted_11$51,`Delivered: `+toDisplayString(getDeliveryList()),1),summary.value.detailledList.length>1?(openBlock(),createBlock(unref(bngSwitch_default),{key:0,style:{float:`right`},modelValue:unref(cargoOverviewStore).detailedDropOff,"onUpdate:modelValue":_cache[2]||=$event=>unref(cargoOverviewStore).detailedDropOff=$event},{default:withCtx(()=>[..._cache[6]||=[createTextVNode(`Detailed`,-1)]]),_:1},8,[`modelValue`])):createCommentVNode(``,!0)]),summary.value.detailledList.length<=1||unref(cargoOverviewStore).detailedDropOff?(openBlock(),createElementBlock(`div`,_hoisted_12$40,[createBaseVNode(`div`,_hoisted_13$33,[(openBlock(!0),createElementBlock(Fragment,null,renderList(summary.value.detailledList,result=>(openBlock(),createElementBlock(`div`,_hoisted_14$31,[createBaseVNode(`div`,_hoisted_15$30,toDisplayString(result.label),1),createBaseVNode(`div`,_hoisted_16$30,[createVNode(RewardsPills_default,{rewards:result.rewards},null,8,[`rewards`])]),createBaseVNode(`div`,_hoisted_17$24,[(openBlock(!0),createElementBlock(Fragment,null,renderList(result.breakdown,breakdown=>(openBlock(),createElementBlock(`div`,_hoisted_18$21,[createBaseVNode(`div`,_hoisted_19$18,toDisplayString(breakdown.label),1),createBaseVNode(`div`,_hoisted_20$15,[createVNode(RewardsPills_default,{rewards:breakdown.rewards},null,8,[`rewards`])])]))),256))])]))),256)),createVNode(unref(bngDivider_default)),createBaseVNode(`div`,_hoisted_21$14,[_cache[7]||=createBaseVNode(`div`,{class:`label primary`},`Summary`,-1),createBaseVNode(`div`,_hoisted_22$12,[createVNode(RewardsPills_default,{rewards:summary.value.total.rewards},null,8,[`rewards`])])])])])):(openBlock(),createElementBlock(`div`,_hoisted_23$11,[createBaseVNode(`div`,_hoisted_24$10,[summary.value.simpleBreakdown.base.length?(openBlock(),createElementBlock(`div`,_hoisted_25$9,[_cache[8]||=createBaseVNode(`div`,{class:`label primary`},`Base Rewards`,-1),createBaseVNode(`div`,_hoisted_26$7,[createVNode(RewardsPills_default,{rewards:summary.value.simpleBreakdown.base},null,8,[`rewards`])])])):createCommentVNode(``,!0),summary.value.simpleBreakdown.bonus.length?(openBlock(),createElementBlock(`div`,_hoisted_27$7,[_cache[9]||=createBaseVNode(`div`,{class:`label primary`},`Bonuses`,-1),createBaseVNode(`div`,_hoisted_28$6,[createVNode(RewardsPills_default,{rewards:summary.value.simpleBreakdown.bonus},null,8,[`rewards`])])])):createCommentVNode(``,!0),summary.value.simpleBreakdown.loaner.length?(openBlock(),createElementBlock(`div`,_hoisted_29$6,[_cache[10]||=createBaseVNode(`div`,{class:`label primary`},`Loaner Cuts`,-1),createBaseVNode(`div`,_hoisted_30$6,[createVNode(RewardsPills_default,{rewards:summary.value.simpleBreakdown.loaner},null,8,[`rewards`])])])):createCommentVNode(``,!0),summary.value.simpleBreakdown.branch.length?(openBlock(),createElementBlock(`div`,_hoisted_31$6,[_cache[11]||=createBaseVNode(`div`,{class:`label primary`},`Logistics Level Multiplier`,-1),createBaseVNode(`div`,_hoisted_32$6,[createVNode(RewardsPills_default,{rewards:summary.value.simpleBreakdown.branch},null,8,[`rewards`])])])):createCommentVNode(``,!0),createVNode(unref(bngDivider_default)),createBaseVNode(`div`,_hoisted_33$6,[_cache[12]||=createBaseVNode(`div`,{class:`label primary`},`Summary`,-1),createBaseVNode(`div`,_hoisted_34$6,[createVNode(RewardsPills_default,{rewards:summary.value.total.rewards},null,8,[`rewards`])])])])])),(openBlock(!0),createElementBlock(Fragment,null,renderList(summary.value.total.rewards,reward=>(openBlock(),createElementBlock(`div`,null,[reward.animationData.id==`missing`?createCommentVNode(``,!0):(openBlock(),createElementBlock(`div`,{key:0,class:normalizeClass(reward.animationData.numStep==0?``:`animate-progress-background`),style:{display:`flex`,"padding-bottom":`0.5em`,"padding-left":`0.2em`,"padding-right":`0.2em`}},[createBaseVNode(`div`,_hoisted_35$5,[reward.icon?(openBlock(),createBlock(unref(bngIcon_default),{key:0,style:{"padding-top":`0.5em`,"padding-right":`0.3em`},type:unref(icons)[reward.icon]},null,8,[`type`])):createCommentVNode(``,!0)]),reward.animationData.type==`number`?(openBlock(),createElementBlock(`div`,_hoisted_36$5,[reward.attributeKey==`money`?(openBlock(),createElementBlock(`div`,_hoisted_37$4,[createVNode(unref(bngUnit_default),{money:reward.animationData.smoothedValue,"no-icon":``},null,8,[`money`])])):reward.attributeKey==`beamXP`?(openBlock(),createElementBlock(`div`,_hoisted_38$4,[createVNode(unref(bngUnit_default),{beamXP:reward.animationData.smoothedValue,"no-icon":``},null,8,[`beamXP`])])):(openBlock(),createElementBlock(`div`,_hoisted_39$4,toDisplayString(reward.animationData.smoothedValue.toFixed(2)),1))])):(openBlock(),createElementBlock(`div`,_hoisted_40$3,[createVNode(unref(bngProgressBar_default),{headerLeft:_ctx.$t(reward.animationData.name),headerRight:reward.animationData.levelLabel,value:~~reward.animationData.displayValue,"old-value":~~reward.animationData.displayValueBefore,max:reward.animationData.max,showValueLabel:!0,valueColor:reward.valueColor,oldValueColor:reward.valueBeforeColor,valueLabelFormat:reward.animationData.maxLevel?~~reward.animationData.displayValue+`\xA0XP`:`#value#\xA0XP`,"animate-difference":!0},null,8,[`headerLeft`,`headerRight`,`value`,`old-value`,`max`,`valueColor`,`oldValueColor`,`valueLabelFormat`])]))],2))]))),256)),unref(showUnloadingDelay)?(openBlock(),createElementBlock(`div`,_hoisted_41$3,[createVNode(unref(bngDivider_default)),_cache[13]||=createTextVNode(` Unloading Delay `,-1),createVNode(unref(bngProgressBar_default),{class:`timer`,value:data.value.unloadingDelay-confirmButtonTimer.value,max:data.value.unloadingDelay,min:0,valueLabelFormat:getNiceTime()},null,8,[`value`,`max`,`valueLabelFormat`])])):createCommentVNode(``,!0)])]),_:1})):createCommentVNode(``,!0)])]),_:1})),[[unref(BngBlur_default)],[unref(BngOnUiNav_default),confirm,`back,menu`]])}}),CargoDropOff_default=__plugin_vue_export_helper_default(_sfc_main$254,[[`__scopeId`,`data-v-698d9552`]]);const useComputerStore=defineStore(`computer`,()=>{let computerData=ref({}),activeVehicleIndex=ref(0),activeInventoryId=computed(()=>computerData.value.vehicles&&computerData.value.vehicles[activeVehicleIndex.value]?computerData.value.vehicles[activeVehicleIndex.value].inventoryId:`0`),generalComputerFunctions=computed(()=>{if(!computerData.value.computerFunctions)return[];let result=[];return result=Object.values(computerData.value.computerFunctions.general),result.sort((a$1,b)=>a$1.order!=null&&b.order!=null?a$1.order{if(!computerData.value.computerFunctions)return{};let result={};for(let[inventoryId,computerFunctions]of Object.entries(computerData.value.computerFunctions.vehicleSpecific)){let sortedFunctions=Object.values(computerFunctions);sortedFunctions.sort((a$1,b)=>a$1.order!=null&&b.order!=null?a$1.order{computerData.value=data,(computerData.value.vehicles&&computerData.value.vehicles.length<=activeVehicleIndex.value||computerData.value.resetActiveVehicleIndex)&&(activeVehicleIndex.value=0)};return{activeVehicleIndex,activeInventoryId,computerData,generalComputerFunctions,vehicleSpecificComputerFunctions,requestComputerData:()=>{Lua_default.career_modules_computer.getComputerUIData().then(setComputerData)},computerButtonCallback:async(computerFunctionId,inventoryId)=>{await Lua_default.career_modules_computer.computerButtonCallback(computerFunctionId,inventoryId?Number(inventoryId):void 0)},switchActiveVehicle:offset$2=>{activeVehicleIndex.value=(activeVehicleIndex.value+offset$2+computerData.value.vehicles.length)%computerData.value.vehicles.length},onMenuClosed:()=>{Lua_default.career_modules_computer.onMenuClosed()}}});var _hoisted_1$224={class:`task-header`},_hoisted_2$182={class:`description`},_sfc_main$253={__name:`TaskHeader`,props:{title:[String,Object],description:[String,Object]},setup(__props){let props=__props,slots=useSlots(),titleParsed=computed(()=>parse$1($translate.contextTranslate(props.title,!0))),descriptionParsed=computed(()=>parse$1($translate.contextTranslate(props.description)));return(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$224,[createBaseVNode(`div`,null,[unref(slots).title?renderSlot(_ctx.$slots,`title`,{key:0},void 0,!0):__props.title?(openBlock(),createBlock(unref(dynamicComponent_default),{key:1,template:titleParsed.value},null,8,[`template`])):createCommentVNode(``,!0)]),createBaseVNode(`div`,_hoisted_2$182,[unref(slots).description?renderSlot(_ctx.$slots,`description`,{key:0},void 0,!0):__props.description?(openBlock(),createBlock(unref(dynamicComponent_default),{key:1,template:descriptionParsed.value},null,8,[`template`])):createCommentVNode(``,!0)])]))}},TaskHeader_default=__plugin_vue_export_helper_default(_sfc_main$253,[[`__scopeId`,`data-v-ae9fa7fe`]]),_hoisted_1$223={class:`task-message`},_hoisted_2$181={class:`label`},_hoisted_3$160={class:`description`},_sfc_main$252={__name:`TaskMessage`,props:{label:String,description:String},setup(__props){let props=__props,slots=useSlots(),labelParsed=computed(()=>parse$1($translate.contextTranslate(props.label,!0))),descriptionParsed=computed(()=>parse$1($translate.contextTranslate(props.description)));return(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$223,[createBaseVNode(`div`,_hoisted_2$181,[unref(slots).label?renderSlot(_ctx.$slots,`label`,{key:0},void 0,!0):__props.label?(openBlock(),createBlock(unref(dynamicComponent_default),{key:1,template:labelParsed.value},null,8,[`template`])):createCommentVNode(``,!0)]),createBaseVNode(`div`,_hoisted_3$160,[unref(slots).description?renderSlot(_ctx.$slots,`description`,{key:0},void 0,!0):__props.description?(openBlock(),createBlock(unref(dynamicComponent_default),{key:1,template:descriptionParsed.value},null,8,[`template`])):createCommentVNode(``,!0)])]))}},TaskMessage_default=__plugin_vue_export_helper_default(_sfc_main$252,[[`__scopeId`,`data-v-657447b0`]]),_hoisted_1$222=[`data-id`],_sfc_main$251={__name:`TaskList`,props:{header:Object,tasks:Array,settings:{type:Object,default:{animate:!1,animateOnMount:!1,animateOnMountIntervalDelay:.2,animateOnEmpty:!1,animateOnEmptyIntervalDelay:.2,animateNextTask:!1,taskCompleteCallback:{type:Function,required:!1}}}},setup(__props){let props=__props,animationSettings=inject(`animationSettings`,props.settings),previousTasks=ref(null),internalTasks=ref(null),tasksScroller=ref(null),canAnimate=computed(()=>!(!animationSettings.animate||previousTasks.value===null&&!animationSettings.animateOnMount)),nextTask=computed(()=>internalTasks.value.find(x=>x.type===`goal`&&!x.complete&&x.attention)),onBeforeHeaderLeave=el=>{el.style.animationDelay=`0s`},onBeforeLeave=(el,done)=>{el.style.animationDelay=`0s`},onBeforeEnterTask=el=>{let dataId=el.getAttribute(`data-id`),offset$2=props.header?1:0,delay=previousTasks.value===null||previousTasks.value.length===0?animationSettings.animateOnMountIntervalDelay*(Number(dataId)+offset$2):0;el.style.animationDelay=delay+`s`,requestAnimationFrame(()=>{tasksScroller.value&&(tasksScroller.value.scrollTop=tasksScroller.value.scrollHeight)})};onBeforeMount(()=>{(!internalTasks.value||internalTasks.value.length===0)&&(internalTasks.value=unwrapProxy(props.tasks))}),watch(()=>props.tasks,async(newValue,oldValue)=>{internalTasks.value!==null&&(previousTasks.value=internalTasks.value&&internalTasks.value.length>0?unwrapProxy([...internalTasks.value]):[]),internalTasks.value=unwrapProxy(props.tasks)},{deep:!0});function unwrapProxy(reactiveList){return reactiveList.map(x=>Object.assign({},x))}return(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,{class:normalizeClass([`tasks-container`,{animate:unref(animationSettings).animate}])},[createVNode(Transition,{"enter-active-class":`show`,"leave-active-class":`remove`,css:unref(animationSettings).animate,onBeforeLeave:onBeforeHeaderLeave},{default:withCtx(()=>[__props.header?(openBlock(),createElementBlock(`div`,{key:0,class:normalizeClass([`header-wrapper`,{"show-animate":canAnimate.value}])},[createVNode(TaskHeader_default,mergeProps(__props.header,{class:`header`}),null,16)],2)):createCommentVNode(``,!0)]),_:1},8,[`css`]),createBaseVNode(`div`,{class:`tasks-content`,ref_key:`tasksScroller`,ref:tasksScroller},[createVNode(TransitionGroup,{"enter-active-class":`show`,"leave-active-class":`remove`,css:unref(animationSettings).animate,onBeforeLeave,onBeforeEnter:onBeforeEnterTask},{default:withCtx(()=>[(openBlock(!0),createElementBlock(Fragment,null,renderList(internalTasks.value,(task,index)=>(openBlock(),createElementBlock(`div`,{key:task.id,class:normalizeClass([`task-wrapper`,{"show-animate":canAnimate.value,"remove-animate":canAnimate.value}]),"data-id":index},[task.type===`message`?(openBlock(),createBlock(TaskMessage_default,mergeProps({key:0,ref_for:!0},task,{class:`task-card`}),null,16)):task.type===`goal`?(openBlock(),createBlock(TaskGoal_default,mergeProps({key:1,ref_for:!0},task,{class:[`task-card`,{glow:unref(animationSettings).animateNextTask&&nextTask.value&&nextTask.value.id===task.id}]}),null,16,[`class`])):createCommentVNode(``,!0)],10,_hoisted_1$222))),128))]),_:1},8,[`css`])],512)],2))}},TaskList_default=__plugin_vue_export_helper_default(_sfc_main$251,[[`__scopeId`,`data-v-5118e548`]]);const useTasksStore=defineStore(`tasks`,()=>{let header=ref(null),tasks=ref([]),{$game}=useLibStore();$game.events.on(`SetTasklistHeader`,setTasklistHeader),$game.events.on(`SetTasklistTask`,setTasklistTask),$game.events.on(`UpdateTasklistItem`,updateTasklistItem),$game.events.on(`SortTasklistItems`,sortTasklistItems),$game.events.on(`CompleteTasklistGoal`,id=>updateTasklistItem(id,{complete:!0,success:!0})),$game.events.on(`FailTasklistGoal`,id=>updateTasklistItem(id,{complete:!0,success:!1})),$game.events.on(`DiscardTasklistItem`,discardTasklistItem),$game.events.on(`HighlightTasklistItem`,highlightTasklistItem),$game.events.on(`HideCareerTasklist`,hideCareerTasklist),$game.events.on(`ClearTasklist`,clearTasklist);function setTasklistHeader(data){data==null||data==``?header.value=null:header.value={title:data.label,description:data.subtext}}function setTasklistTask(data){let id=data.id===null||data.id===void 0?`default`:data.id,index=tasks.value.findIndex(x=>x.id===id);if(index===-1&&data.clear)return;if(data.clear){tasks.value.splice(index,1);return}let isComplete=data.done!==void 0&&data.done||data.fail!==void 0&&data.fail,isSuccess=data.done!==void 0&&data.done||data.fail!==void 0&&!data.fail,description=data.subtext===0?``:data.subtext;index===-1?tasks.value.push({id:data.id,label:data.label,description,type:data.type,attention:data.attention,complete:isComplete,success:isSuccess}):(tasks.value[index].attention=data.attention,tasks.value[index].complete=isComplete,tasks.value[index].success=isSuccess,data.subtext!==void 0&&(tasks.value[index].description=description),data.label!==void 0&&(tasks.value[index].label=data.label),data.type!==void 0&&(tasks.value[index].type=data.type))}function updateTasklistItem(id,data){let index=tasks.value.findIndex(task=>task.id===id);index!==-1&&Object.keys(data).forEach(key=>{tasks.value[index][key]!==void 0&&(tasks.value[index][key]=data[key])})}function sortTasklistItems(order){let inOrderTasks=[],notInOrderTasks=[];tasks.value.forEach(task=>{order.includes(task.id)?inOrderTasks.push(task):notInOrderTasks.push(task)}),inOrderTasks.sort((a$1,b)=>order.indexOf(a$1.id)-order.indexOf(b.id)),tasks.value=[...inOrderTasks,...notInOrderTasks]}function discardTasklistItem(id,delay){delay!==void 0&&delay>0?setTimeout(()=>{setTasklistTask({id,clear:!0})},delay*1e3):setTasklistTask({id,clear:!0})}function highlightTasklistItem(id,duration){setTasklistTask({id,attention:!0}),duration!==void 0&&duration>0&&setTimeout(()=>{setTasklistTask({id,attention:!1})},duration*1e3)}function hideCareerTasklist(){}function clearTasklist(){header.value=null,tasks.value=[]}return{header,tasks,hasItems:computed(()=>tasks.value.length>0||header.value!==null)}});var _hoisted_1$221={class:`heading-container`},_hoisted_2$180={key:0,class:`status-add`},_hoisted_3$159={class:`content-container`},_hoisted_4$134={class:`main-content`},_hoisted_5$117={class:`main-content-slotted`},_hoisted_6$100={class:`side-content-slotted`},_sfc_main$250={__name:`ComputerWrapper`,props:{title:{type:String,default:`My Computer`},path:Array,wallpaperFull:Boolean,wallpaperHalf:Boolean,back:Boolean,close:Boolean},emits:[`back`,`close`],setup(__props,{expose:__expose,emit:__emit}){useUINavScope(`computer`);let{$game}=useLibStore(),computerStore=useComputerStore(),props=__props,breadcrumbItems=computed(()=>[{label:`Career`,closeAllMenus:!0},{label:computerStore.computerData.facilityName},...(props.path||[]).map(path=>({label:path}))]),elStatus=ref(),store$1=useTasksStore();provide(`animationSettings`,{animate:!0,animateOnMount:!1,animateOnMountIntervalDelay:.2,animateOnEmptyIntervalDelay:.1,animateOnEmpty:!0,animateNextTask:!0,successCallback:playAudio});function playAudio(){$game.lua.Engine.Audio.playOnce(`AudioGui`,`event:>UI>Career>Checkbox`)}__expose({statusUpdate:()=>elStatus.value.updateDisplay()});function breadcrumbClick(item){item.closeAllMenus&&$game.lua.career_career.closeAllMenus()}let emit$1=__emit;return(_ctx,_cache)=>withDirectives((openBlock(),createBlock(unref(layoutSingle_default),{"bng-ui-scope":`computer`,class:`computer-wrapper-layout`},{default:withCtx(()=>[createBaseVNode(`div`,_hoisted_1$221,[createVNode(unref(bngScreenHeadingV2_default),{type:`2`},{preheadings:withCtx(()=>[createVNode(bngBreadcrumbs_default,{class:`breadcrumbs`,simple:``,"disable-last-item":``,"show-back-button":``,navigable:!1,onClick:breadcrumbClick,onBack:_cache[0]||=$event=>emit$1(`back`),items:breadcrumbItems.value},null,8,[`items`])]),default:withCtx(()=>[renderSlot(_ctx.$slots,`title`,{},()=>[createTextVNode(toDisplayString(__props.title),1)],!0)]),_:3}),withDirectives((openBlock(),createBlock(unref(bngCard_default),{class:`status-container`},{default:withCtx(()=>[createVNode(unref(careerStatus_default),{ref_key:`elStatus`,ref:elStatus},null,512),_ctx.$slots.status?(openBlock(),createElementBlock(`div`,_hoisted_2$180,[renderSlot(_ctx.$slots,`status`,{},void 0,!0)])):createCommentVNode(``,!0)]),_:3})),[[unref(BngBlur_default),!0]])]),createBaseVNode(`div`,_hoisted_3$159,[createBaseVNode(`div`,_hoisted_4$134,[createBaseVNode(`div`,_hoisted_5$117,[renderSlot(_ctx.$slots,`default`,{},void 0,!0)]),createBaseVNode(`div`,_hoisted_6$100,[createVNode(unref(TaskList_default),{class:`task-list`,header:unref(store$1).header,tasks:unref(store$1).tasks},null,8,[`header`,`tasks`]),renderSlot(_ctx.$slots,`side`,{},void 0,!0)])])])]),_:3})),[[unref(BngOnUiNav_default),()=>emit$1(`back`),`back`]])}},ComputerWrapper_default=__plugin_vue_export_helper_default(_sfc_main$250,[[`__scopeId`,`data-v-b7460ee1`]]),_hoisted_1$220={class:`indicators-overlay`},_hoisted_2$179={class:`performance-index`},_hoisted_3$158={key:0,class:`lock-reason`},_hoisted_4$133={key:1,class:`lock-time`},_hoisted_5$116={key:1,class:`valueReduced`},_hoisted_6$99={key:0,class:`content`},_hoisted_7$87={class:`header`},_hoisted_8$72={class:`title-section`},_hoisted_9$65={class:`name`},_hoisted_10$56={class:`details`},_hoisted_11$50={class:`location-section`},_hoisted_12$39={class:`location-value`},_hoisted_13$32={key:0,class:`value-section`},_hoisted_14$30={key:0,class:`value-label reduced`},_hoisted_15$29={key:1,class:`value-label`},_hoisted_16$29={key:2,class:`total-value`},_hoisted_17$23={class:`insurance-section`},_hoisted_18$20={class:`insurance-value`},_hoisted_19$17={key:0,class:`warn`},_sfc_main$249=Object.assign({width:100,margin:.25},{__name:`VehicleTileRow`,props:{data:Object,isTutorial:Boolean,selected:Boolean,enableHover:{type:Boolean,default:!0},small:Boolean},setup(__props){let{units}=useBridge(),props=__props,partConditionAvg=computed(()=>{if(!props.data)return 1;if(props.data.partConditions){let conds=Object.values(props.data.partConditions);return conds.reduce((i,c)=>i+c.integrityValue,0)/conds.length}return 1}),colour=computed(()=>props.data?.config?.paints?.[0]?.baseColor??`#ccc`),thumbUrl=computed(()=>props.data.thumbnail?`${props.data.thumbnail}?${props.data.dirtyDate}`:null),location$1=computed(()=>{let res;return res=locked.value&&!locked.value.location?locked.value.reason:props.data.inGarage?`In garage`:props.data.distance?`${units.buildString(`length`,props.data.distance,0)} away`:`Storage`,res}),locked=computed(()=>{let res;if(props.data._message)res={reason:props.data._message};else if(props.data.missingFile)res={reason:`Missing File!`};else if(props.data.timeToAccess){let eta=`${~~(props.data.timeToAccess/60)}:${String(~~props.data.timeToAccess%60).padStart(2,`0`)}`;res=props.data.delayReason===`bought`?{reason:`Out for delivery`,eta}:props.data.delayReason===`repair`?{reason:`Being repaired`,eta}:{reason:`Available in`,eta}}else props.data.needsRepair&&(res={reason:`Needs repair`,location:!0});return res});return(_ctx,_cache)=>__props.data?withDirectives((openBlock(),createElementBlock(`div`,{key:0,class:normalizeClass({"vehicle-tile-row":!0,selected:__props.selected,"hover-enabled":__props.enableHover}),role:`button`},[createBaseVNode(`div`,{class:normalizeClass({preview:!0,locked:locked.value,small:__props.small})},[thumbUrl.value?(openBlock(),createBlock(unref(aspectRatio_default),{key:0,ratio:`16:9`,"external-image":thumbUrl.value,class:`preview-image`},{default:withCtx(()=>[createBaseVNode(`div`,_hoisted_1$220,[__props.data.favorite?withDirectives((openBlock(),createBlock(unref(bngIcon_default),{key:0,type:unref(icons).star,color:`#fd0`},null,8,[`type`])),[[unref(BngTooltip_default),`Favourite`]]):createCommentVNode(``,!0),__props.data.delayReason===`repair`?(openBlock(),createBlock(unref(bngIcon_default),{key:1,type:unref(icons).wrench,color:`#fff`},null,8,[`type`])):(openBlock(),createBlock(unref(bngCondition_default),{key:2,integrity:partConditionAvg.value,"integrity-warning":__props.data.needsRepair,color:colour.value,"show-tooltip":``},null,8,[`integrity`,`integrity-warning`,`color`])),createBaseVNode(`div`,_hoisted_2$179,toDisplayString(__props.data.certificationData&&__props.data.certificationData.vehicleClass?__props.data.certificationData.vehicleClass.performanceIndex.toFixed(0):`N/A`),1)]),locked.value?(openBlock(),createElementBlock(`span`,_hoisted_3$158,toDisplayString(locked.value.reason),1)):createCommentVNode(``,!0),locked.value&&locked.value.eta?(openBlock(),createElementBlock(`span`,_hoisted_4$133,toDisplayString(locked.value.eta),1)):createCommentVNode(``,!0)]),_:1},8,[`external-image`])):createCommentVNode(``,!0),!(__props.data.returnLoanerPermission&&__props.data.returnLoanerPermission.allow)&&__props.data.partConditionAvg<1?(openBlock(),createElementBlock(`span`,_hoisted_5$116,`Value reduced!`)):createCommentVNode(``,!0),__props.data.isInsured?createCommentVNode(``,!0):(openBlock(),createBlock(insurancePerkIcon_default,{key:2,class:`not-insured-overlay`,perkIconData:{iconOnly:__props.data.isInsured,color:`red`,smallText:`Not insured`}},null,8,[`perkIconData`]))],2),__props.data._message?createCommentVNode(``,!0):(openBlock(),createElementBlock(`div`,_hoisted_6$99,[createBaseVNode(`div`,_hoisted_7$87,[createBaseVNode(`div`,_hoisted_8$72,[createBaseVNode(`div`,_hoisted_9$65,toDisplayString(__props.data.niceName),1)])]),createBaseVNode(`div`,_hoisted_10$56,[createBaseVNode(`div`,_hoisted_11$50,[_cache[0]||=createBaseVNode(`span`,{class:`location-label`},`Location:`,-1),createBaseVNode(`span`,_hoisted_12$39,toDisplayString(location$1.value),1)]),__props.data.returnLoanerPermission?.allow?createCommentVNode(``,!0):(openBlock(),createElementBlock(`div`,_hoisted_13$32,[partConditionAvg.value<1?(openBlock(),createElementBlock(`span`,_hoisted_14$30,`Current Value:`)):(openBlock(),createElementBlock(`span`,_hoisted_15$29,`Value:`)),createVNode(unref(bngUnit_default),{money:__props.data.value},null,8,[`money`]),partConditionAvg.value<1?(openBlock(),createElementBlock(`div`,_hoisted_16$29,[_cache[1]||=createTextVNode(` Total Value: `,-1),createVNode(unref(bngUnit_default),{money:__props.data.valueRepaired},null,8,[`money`])])):createCommentVNode(``,!0)])),createBaseVNode(`div`,_hoisted_17$23,[_cache[2]||=createBaseVNode(`span`,{class:`insurance-label`},`Insurance:`,-1),createBaseVNode(`span`,_hoisted_18$20,toDisplayString(__props.data.insuranceInfo?__props.data.insuranceInfo.name:`n/a`),1),__props.data.isInsured?createCommentVNode(``,!0):(openBlock(),createElementBlock(`div`,_hoisted_19$17,`Not Insured!`))])])]))],2)),[[unref(BngDisabled_default),__props.data.disabled]]):createCommentVNode(``,!0)}}),VehicleTileRow_default=__plugin_vue_export_helper_default(_sfc_main$249,[[`__scopeId`,`data-v-777a3003`]]),_hoisted_1$219={key:1,class:`computer-actions`},_hoisted_2$178={key:0,class:`vehicle-select-container`},_hoisted_3$157={class:`vehicle-select`},_hoisted_4$132={key:0,class:`actions-list`},_hoisted_5$115=[`onClick`,`onMouseover`,`onFocus`],_hoisted_6$98={class:`label`},_hoisted_7$86={key:1,class:`no-vehicle-container`},_hoisted_8$71={key:2,class:`action-header`},_hoisted_9$64={key:3,class:`general-functions-container`},_hoisted_10$55={class:`actions-list`},_hoisted_11$49=[`onClick`,`onMouseover`,`onFocus`],_hoisted_12$38={class:`label`},_hoisted_13$31={key:0,class:`disable-reason`},_hoisted_14$29=[`innerHTML`],_hoisted_15$28={key:1,class:`disable-reason`},_hoisted_16$28=[`innerHTML`],_sfc_main$248={__name:`ComputerMain`,setup(__props){let computerStore=useComputerStore(),currentVehicleData=ref(null);watch(()=>computerStore.activeInventoryId,newId=>{Number(newId)&&Lua_default.career_modules_inventory.getVehicleUiData(newId).then(data=>{currentVehicleData.value=data})});let showVehicleSelectorButtons=computed(()=>computerStore.computerData.vehicles&&computerStore.computerData.vehicles.length>1),hasVehicles=computed(()=>computerStore.computerData.vehicles&&computerStore.computerData.vehicles.length);computed(()=>hasVehicles.value?computerStore.computerData.vehicles[computerStore.activeVehicleIndex].vehicleName:``),computed(()=>hasVehicles.value?computerStore.computerData.vehicles[computerStore.activeVehicleIndex].thumbnail:``),computed(()=>hasVehicles.value?computerStore.computerData.vehicles[computerStore.activeVehicleIndex].needsRepair?`Assess Performance (Repair Required)`:`Assess Performance`:``);let slowFunctions=[`vehicleShop`,`partInventory`],computerLoading=ref(!1),computerButtonCallback=(computerFunction,inventoryId=void 0)=>{computerFunction.disabled||(slowFunctions.includes(computerFunction.id)?(computerLoading.value=!0,setTimeout(()=>computerStore.computerButtonCallback(computerFunction.id,inventoryId),100)):computerStore.computerButtonCallback(computerFunction.id,inventoryId))},switchActiveVehicle=computerStore.switchActiveVehicle,iconById={painting:icons.sprayCan,partShop:icons.doorFrontCoins,repair:icons.wrench,tuning:icons.cogs,insurances:icons.shieldHandCheckmark,playerAbstract:icons.personSolid,vehicleInventory:icons.keys1,partInventory:icons.engine,vehicleShop:icons.carCoins,performanceIndex:icons.raceFlag},infoById=computed(()=>[...computerStore.generalComputerFunctions,...(computerStore.activeInventoryId?computerStore.vehicleSpecificComputerFunctions[computerStore.activeInventoryId]:void 0)||[]].reduce((res,func)=>(res[func.id]={icon:iconById[func.id]||icons.bug,label:func.label,reason:void 0},func.reason&&(res[func.id].label+=` *`,res[func.id].reason=func.reason.label),res),{})),isTutorialActive=ref(!1),disableReason=ref([null,null]),setReason=(idx,reason=null)=>{disableReason.value[idx]=reason,disableReason.value[(idx+1)%2]=null},close=()=>{computerLoading.value||Lua_default.career_career.closeAllMenus()};return onMounted(async()=>{getUINavServiceInstance().setFilteredEvents(UI_EVENT_GROUPS.focusMoveScalar),computerStore.requestComputerData(),Number(computerStore.activeInventoryId)&&Lua_default.career_modules_inventory.getVehicleUiData(computerStore.activeInventoryId).then(data=>{currentVehicleData.value=data}),Lua_default.career_modules_linearTutorial.isLinearTutorialActive().then(data=>{isTutorialActive.value=data})}),onUnmounted(()=>{computerStore.onMenuClosed(),getUINavServiceInstance().clearFilteredEvents(),computerStore.$dispose()}),(_ctx,_cache)=>(openBlock(),createBlock(ComputerWrapper_default,{title:unref(computerStore).computerData.facilityName+` - Home screen`,close:``,onBack:close},{default:withCtx(()=>[withDirectives((openBlock(),createBlock(unref(bngCard_default),{class:`card-content`},{default:withCtx(()=>[computerLoading.value?(openBlock(),createBlock(unref(bngCardHeading_default),{key:0},{default:withCtx(()=>[..._cache[6]||=[createTextVNode(` Loading... `,-1)]]),_:1})):createCommentVNode(``,!0),computerLoading.value?createCommentVNode(``,!0):(openBlock(),createElementBlock(`div`,_hoisted_1$219,[_cache[9]||=createBaseVNode(`div`,{class:`action-header`},[createBaseVNode(`div`,{class:`line left`}),createBaseVNode(`div`,{class:`title`},`Vehicle Management`),createBaseVNode(`div`,{class:`line right`})],-1),hasVehicles.value?(openBlock(),createElementBlock(`div`,_hoisted_2$178,[createBaseVNode(`div`,_hoisted_3$157,[showVehicleSelectorButtons.value?withDirectives((openBlock(),createBlock(unref(bngButton_default),{key:0,style:{height:`3em`},accent:unref(ACCENTS).ghost,onClick:_cache[0]||=$event=>unref(switchActiveVehicle)(-1),icon:unref(icons).arrowLargeLeft},{default:withCtx(()=>[createVNode(unref(bngBinding_default),{"ui-event":`tab_l`,deviceMask:`xinput`})]),_:1},8,[`accent`,`icon`])),[[unref(BngOnUiNav_default),void 0,`tab_l`,{asMouse:!0}]]):createCommentVNode(``,!0),createVNode(VehicleTileRow_default,{class:normalizeClass([`vehicle-tile-row`,{hasButtons:showVehicleSelectorButtons.value}]),data:currentVehicleData.value,enableHover:!1,small:!0},null,8,[`class`,`data`]),showVehicleSelectorButtons.value?withDirectives((openBlock(),createBlock(unref(bngButton_default),{key:1,style:{height:`3em`},accent:unref(ACCENTS).ghost,onClick:_cache[1]||=$event=>unref(switchActiveVehicle)(1),icon:unref(icons).arrowLargeRight},{default:withCtx(()=>[createVNode(unref(bngBinding_default),{"ui-event":`tab_r`,deviceMask:`xinput`})]),_:1},8,[`accent`,`icon`])),[[unref(BngOnUiNav_default),void 0,`tab_r`,{asMouse:!0}]]):createCommentVNode(``,!0)]),unref(computerStore).activeInventoryId&&unref(computerStore).vehicleSpecificComputerFunctions[unref(computerStore).activeInventoryId]?(openBlock(),createElementBlock(`div`,_hoisted_4$132,[(openBlock(!0),createElementBlock(Fragment,null,renderList(unref(computerStore).vehicleSpecificComputerFunctions[unref(computerStore).activeInventoryId],(computerFunction,index)=>withDirectives((openBlock(),createElementBlock(`div`,{class:normalizeClass([`computer-function-tile`,{"action-disabled":computerFunction.disabled}]),key:computerFunction.id,tabindex:`0`,"bng-nav-item":``,onClick:$event=>computerButtonCallback(computerFunction,unref(computerStore).activeInventoryId),onMouseover:$event=>setReason(0,infoById.value[computerFunction.id].reason),onFocus:$event=>setReason(0,infoById.value[computerFunction.id].reason),onMouseleave:_cache[2]||=$event=>setReason(0),onBlur:_cache[3]||=$event=>setReason(0)},[createVNode(unref(bngIcon_default),{class:`icon`,type:infoById.value[computerFunction.id].icon},null,8,[`type`]),createBaseVNode(`span`,_hoisted_6$98,toDisplayString(infoById.value[computerFunction.id].label),1)],42,_hoisted_5$115)),[[unref(BngOnUiNav_default),void 0,`ok`,{asMouse:!0,focusRequired:!0}],[unref(BngUiNavFocus_default),index==0?0:void 0]])),128))])):createCommentVNode(``,!0)])):(openBlock(),createElementBlock(`div`,_hoisted_7$86,[..._cache[7]||=[createBaseVNode(`span`,null,`No vehicles in garage.`,-1),createBaseVNode(`p`,null,` Place a vehicle in your garage to access modify and manage it.`,-1)]])),unref(computerStore).generalComputerFunctions?(openBlock(),createElementBlock(`div`,_hoisted_8$71,[..._cache[8]||=[createBaseVNode(`div`,{class:`line left`},null,-1),createBaseVNode(`div`,{class:`title`},`General Computer Functions`,-1),createBaseVNode(`div`,{class:`line right`},null,-1)]])):createCommentVNode(``,!0),unref(computerStore).generalComputerFunctions?(openBlock(),createElementBlock(`div`,_hoisted_9$64,[createBaseVNode(`div`,_hoisted_10$55,[(openBlock(!0),createElementBlock(Fragment,null,renderList(unref(computerStore).generalComputerFunctions,(computerFunction,index)=>(openBlock(),createElementBlock(Fragment,{key:computerFunction.id},[computerFunction.type?createCommentVNode(``,!0):withDirectives((openBlock(),createElementBlock(`div`,{key:0,class:normalizeClass([`computer-function-tile`,{"action-disabled":computerFunction.disabled}]),tabindex:`0`,"bng-nav-item":``,onClick:$event=>computerButtonCallback(computerFunction),onMouseover:$event=>setReason(1,infoById.value[computerFunction.id].reason),onFocus:$event=>setReason(1,infoById.value[computerFunction.id].reason),onMouseleave:_cache[4]||=$event=>setReason(1),onBlur:_cache[5]||=$event=>setReason(1)},[createVNode(unref(bngIcon_default),{class:`icon`,type:infoById.value[computerFunction.id].icon},null,8,[`type`]),createBaseVNode(`span`,_hoisted_12$38,toDisplayString(infoById.value[computerFunction.id].label),1)],42,_hoisted_11$49)),[[unref(BngOnUiNav_default),void 0,`ok`,{asMouse:!0,focusRequired:!0}],[unref(BngUiNavFocus_default),!hasVehicles.value&&index==0?0:void 0]])],64))),128))]),disableReason.value[0]?(openBlock(),createElementBlock(`div`,_hoisted_13$31,[withDirectives(createVNode(unref(bngIcon_default),{class:`disable-icon`,type:unref(icons).info},null,8,[`type`]),[[vShow,disableReason.value[0]]]),createBaseVNode(`span`,{innerHTML:disableReason.value[0]||`\xA0`},null,8,_hoisted_14$29)])):createCommentVNode(``,!0),disableReason.value[1]?(openBlock(),createElementBlock(`div`,_hoisted_15$28,[createVNode(unref(bngIcon_default),{class:`disable-icon`,type:unref(icons).info},null,8,[`type`]),createBaseVNode(`span`,{innerHTML:disableReason.value[1]||`\xA0`},null,8,_hoisted_16$28)])):createCommentVNode(``,!0)])):createCommentVNode(``,!0)]))]),_:1})),[[unref(BngBlur_default),1]])]),_:1},8,[`title`]))}},ComputerMain_default=__plugin_vue_export_helper_default(_sfc_main$248,[[`__scopeId`,`data-v-10a4ce58`]]);const useInsurancesStore=defineStore(`insurances`,()=>{let{events:events$3}=useBridge(),invVehsInsurancesData=ref({}),plClassesData=ref({}),uninsuredVehsData=ref({}),driverScoreData=ref({});function requestInitialData(){Lua_default.career_modules_insurance_insurance.sendUIData()}return events$3.on(`insurancesData`,data=>{invVehsInsurancesData.value=data.invVehsInsurancesData,plClassesData.value=data.plClassesData,uninsuredVehsData.value=data.uninsuredVehsData,driverScoreData.value=data.driverScoreData}),{dispose:()=>{events$3.off(`insurancesData`)},requestInitialData,closeMenu:Lua_default.career_modules_insurance_insurance.closeMenu,invVehsInsurancesData,plClassesData,uninsuredVehsData,driverScoreData}});var _hoisted_1$218={key:0,class:`cards-wrapper blue-background`},_hoisted_2$177={class:`insurance-tiers-wrapper`},_hoisted_3$156=[`onClick`],_hoisted_4$131={class:`insurance-tier-card-name`},_hoisted_5$114={class:`insurance-tier-card-description`},_hoisted_6$97={class:`insurance-tier-card-cars-insured`},_hoisted_7$85={class:`left-no-insurance`},_hoisted_8$70={class:`no-insurance-text-wrapper`},_hoisted_9$63={class:`no-insurance-title`},_hoisted_10$54={class:`no-insurance-description`},_hoisted_11$48={class:`uninsured-count`},_hoisted_12$37={key:1,class:`small-insurance-cards-wrapper blue-background`},_sfc_main$247={__name:`InsurancesMain`,setup(__props){useComputerStore();let insurancesStore=useInsurancesStore(),selectedInsuranceClassId=ref(null),selectInsuranceClass=classId=>{selectedInsuranceClassId.value=classId},sortedInsuranceClasses=computed(()=>{let classes=insurancesStore.plClassesData;return classes?Object.entries(classes).map(([classId,classData])=>({classId,classData})).sort((a$1,b)=>a$1.classData.priority-b.classData.priority):[]});onBeforeMount(()=>{insurancesStore.requestInitialData()}),onUnmounted(()=>{Lua_default.extensions.hook(`onExitInsurancesComputerScreen`),insurancesStore.$dispose()});let close=()=>{selectedInsuranceClassId.value?selectedInsuranceClassId.value=null:insurancesStore.closeMenu()},openUninsuredVehicles=()=>{addPopup(uninsuredVehicles_default,{uninsuredData:insurancesStore.uninsuredVehsData})};return(_ctx,_cache)=>(openBlock(),createBlock(ComputerWrapper_default,{ref:`wrapper`,path:[`Insurance`],title:`Insurance`,back:``,onBack:close},{default:withCtx(()=>[createVNode(unref(bngCard_default),{class:`insurances-card blue-background`},{default:withCtx(()=>[selectedInsuranceClassId.value?createCommentVNode(``,!0):(openBlock(),createElementBlock(`div`,_hoisted_1$218,[createBaseVNode(`div`,_hoisted_2$177,[(openBlock(!0),createElementBlock(Fragment,null,renderList(sortedInsuranceClasses.value,({classId,classData})=>(openBlock(),createElementBlock(`div`,{class:`insurance-tier-card`,key:classId,onClick:$event=>selectInsuranceClass(classId)},[createVNode(unref(bngIcon_default),{class:`insurance-icon`,type:unref(icons)[classData.icon]},null,8,[`type`]),createBaseVNode(`div`,_hoisted_4$131,toDisplayString(classData.name),1),createBaseVNode(`div`,_hoisted_5$114,toDisplayString(classData.description),1),createBaseVNode(`div`,_hoisted_6$97,toDisplayString(classData.carsInsured)+` VEHICLES INSURED `,1)],8,_hoisted_3$156))),128))]),createBaseVNode(`div`,{class:`no-insurance-card`,onClick:openUninsuredVehicles},[createBaseVNode(`div`,_hoisted_7$85,[createVNode(unref(bngIcon_default),{class:`no-insurance-icon`,type:unref(icons).checkmark},null,8,[`type`]),createBaseVNode(`div`,_hoisted_8$70,[createBaseVNode(`div`,_hoisted_9$63,toDisplayString(unref(insurancesStore).uninsuredVehsData.title),1),createBaseVNode(`div`,_hoisted_10$54,toDisplayString(unref(insurancesStore).uninsuredVehsData.description),1)])]),createBaseVNode(`div`,_hoisted_11$48,toDisplayString(unref(insurancesStore).uninsuredVehsData.carsUninsuredCount)+` vehicles `,1)])])),selectedInsuranceClassId.value?(openBlock(),createElementBlock(`div`,_hoisted_12$37,[(openBlock(!0),createElementBlock(Fragment,null,renderList(unref(insurancesStore).plClassesData[selectedInsuranceClassId.value].insurances,insurance=>(openBlock(),createBlock(unref(smallInsuranceCard_default),{key:insurance.id,insuranceData:insurance,driverScoreData:unref(insurancesStore).driverScoreData},null,8,[`insuranceData`,`driverScoreData`]))),128))])):createCommentVNode(``,!0)]),_:1})]),_:1},512))}},InsurancesMain_default=__plugin_vue_export_helper_default(_sfc_main$247,[[`__scopeId`,`data-v-a9e49ad5`]]),_hoisted_1$217={key:0,class:`content`},_hoisted_2$176={class:`stats-grid-3`},_hoisted_3$155={class:`score-header`},_hoisted_4$130={class:`score-content`},_hoisted_5$113={class:`score-info`},_hoisted_6$96={class:`score-description`},_hoisted_7$84={class:`stat-card`},_hoisted_8$69={class:`stat-value blue`},_hoisted_9$62={class:`stat-card`},_hoisted_10$53={class:`stats-grid-2`},_hoisted_11$47={class:`info-card`},_hoisted_12$36={class:`info-rows`},_hoisted_13$30={class:`info-row`},_hoisted_14$28={class:`info-value orange`},_hoisted_15$27={class:`info-row`},_hoisted_16$27={class:`info-value green`},_hoisted_17$22={class:`info-row total`},_hoisted_18$19={class:`info-value`},_hoisted_19$16={class:`info-card`},_hoisted_20$14={class:`info-rows`},_hoisted_21$13={class:`info-row bottom-border`},_hoisted_22$11={class:`info-value blue`},_hoisted_23$10={class:`info-row`},_hoisted_24$9={class:`info-value red`},_hoisted_25$8={class:`info-row`},_hoisted_26$6={class:`info-value orange`},_hoisted_27$6={class:`info-row`},_hoisted_28$5={class:`info-value yellow`},_hoisted_29$5={class:`info-row total`},_hoisted_30$5={class:`info-value`},_hoisted_31$5={class:`info-summary`},_hoisted_32$5={class:`info-row small`},_hoisted_33$5={class:`info-value green bold`},_hoisted_34$5={class:`reset-card`},_hoisted_35$4={class:`reset-content`},_hoisted_36$4={class:`reset-description`},_hoisted_37$3={class:`highlight`},_hoisted_38$3={class:`reset-details`},_hoisted_39$3={class:`reset-row`},_hoisted_40$2={class:`reset-row`},_hoisted_41$2={class:`reset-value green`},_hoisted_42$2={class:`reset-row cost`},_hoisted_43$2={class:`reset-value yellow large`},_hoisted_44$2={key:0,class:`reset-payback`},_hoisted_45$2=[`disabled`],_sfc_main$246={__name:`DriverAbstract`,setup(__props){let{units}=useBridge(),abstractData=ref(null),driverTier=computed(()=>abstractData.value?.driverScoreTier),totalDistanceFormatted=computed(()=>abstractData.value?units.buildString(`length`,abstractData.value.totalDistanceDriven,0):``),premiumEffectClass=computed(()=>{if(!driverTier.value)return``;let multiplier=driverTier.value.multiplier;return multiplier<1?`green`:multiplier>1?`red`:`neutral`}),premiumEffectText=computed(()=>{if(!driverTier.value)return`Standard Rate`;let multiplier=driverTier.value.multiplier;return multiplier<1?`${Math.round((1-multiplier)*100)}% Savings`:multiplier>1?`${Math.round((multiplier-1)*100)}% Penalty`:`Standard Rate`}),canResetScore=computed(()=>abstractData.value?abstractData.value.driverScore{if(!driverTier.value)return`green`;let multiplier=driverTier.value.multiplier;return multiplier<1?`blue`:multiplier<1.1?`green`:multiplier<1.3?`yellow`:multiplier<1.5?`orange`:`red`},getDriverColor=()=>({blue:`var(--blue-200)`,green:`var(--green-300)`,yellow:`var(--yellow-400)`,orange:`var(--orange-shade-10)`,red:`var(--red-400)`})[getDriverColorClass()]||`var(--green-300)`,loadData=async()=>{try{abstractData.value=await Lua_default.career_modules_playerAbstract.getPlayerAbstractData()}catch(error){console.error(`Failed to load driver abstract data:`,error)}},resetDriverScore=async()=>{try{await Lua_default.career_modules_insurance_insurance.resetDriverScore(),await loadData()}catch(error){console.error(`Failed to reset driver score:`,error)}},close=()=>{Lua_default.career_modules_playerAbstract.closePlayerAbstractMenu()};return onBeforeMount(loadData),(_ctx,_cache)=>(openBlock(),createBlock(ComputerWrapper_default,{ref:`wrapper`,path:[`Driver's Abstract`],title:`Driver's Abstract`,back:``,onBack:close},{default:withCtx(()=>[createVNode(unref(bngCard_default),{class:`driver-abstract-card`},{default:withCtx(()=>[abstractData.value?(openBlock(),createElementBlock(`div`,_hoisted_1$217,[createBaseVNode(`div`,_hoisted_2$176,[createBaseVNode(`div`,{class:`score-card`,style:normalizeStyle({borderColor:getDriverColor()})},[createBaseVNode(`div`,_hoisted_3$155,[_cache[0]||=createBaseVNode(`div`,{class:`section-title`},`Driver Score: Out of 100`,-1),createVNode(unref(TutorialButton_default),{icon:unref(icons).help,pages:[`driverScore`]},null,8,[`icon`])]),createBaseVNode(`div`,_hoisted_4$130,[createBaseVNode(`div`,{class:normalizeClass([`score-value`,getDriverColorClass()])},toDisplayString(abstractData.value.driverScore),3),createBaseVNode(`div`,_hoisted_5$113,[createBaseVNode(`div`,{class:normalizeClass([`score-risk`,getDriverColorClass()])},toDisplayString(abstractData.value.driverScoreTier.risk),3),createBaseVNode(`div`,_hoisted_6$96,toDisplayString(abstractData.value.driverScoreTier.description),1)])])],4),createBaseVNode(`div`,_hoisted_7$84,[_cache[1]||=createBaseVNode(`div`,{class:`section-title`},`Total Distance Driven`,-1),createBaseVNode(`div`,_hoisted_8$69,toDisplayString(totalDistanceFormatted.value),1)]),createBaseVNode(`div`,_hoisted_9$62,[_cache[2]||=createBaseVNode(`div`,{class:`section-title`},`Premium Effect`,-1),createBaseVNode(`div`,{class:normalizeClass([`stat-value`,premiumEffectClass.value])},toDisplayString(premiumEffectText.value),3),_cache[3]||=createBaseVNode(`div`,{class:`stat-note`},` Applies to every insurance provider when premiums renew `,-1)])]),createBaseVNode(`div`,_hoisted_10$53,[createBaseVNode(`div`,_hoisted_11$47,[_cache[7]||=createBaseVNode(`div`,{class:`section-title`},`Repair History`,-1),createBaseVNode(`div`,_hoisted_12$36,[createBaseVNode(`div`,_hoisted_13$30,[_cache[4]||=createBaseVNode(`span`,{class:`info-label`},`Insurance Claims:`,-1),createBaseVNode(`span`,_hoisted_14$28,toDisplayString(abstractData.value.repairHistory.insuranceRepairs),1)]),createBaseVNode(`div`,_hoisted_15$27,[_cache[5]||=createBaseVNode(`span`,{class:`info-label`},`Private Repairs:`,-1),createBaseVNode(`span`,_hoisted_16$27,toDisplayString(abstractData.value.repairHistory.privateRepairs),1)]),createBaseVNode(`div`,_hoisted_17$22,[_cache[6]||=createBaseVNode(`span`,{class:`info-label`},`Total Repairs:`,-1),createBaseVNode(`span`,_hoisted_18$19,toDisplayString(abstractData.value.repairHistory.insuranceRepairs+abstractData.value.repairHistory.privateRepairs),1)])]),_cache[8]||=createBaseVNode(`div`,{class:`info-tip`},` Private repairs don't affect your record `,-1)]),createBaseVNode(`div`,_hoisted_19$16,[_cache[16]||=createBaseVNode(`div`,{class:`section-title`},`Financial Summary`,-1),createBaseVNode(`div`,_hoisted_20$14,[createBaseVNode(`div`,_hoisted_21$13,[_cache[9]||=createBaseVNode(`span`,{class:`info-label`},`Vehicles Currently Insured:`,-1),createBaseVNode(`span`,_hoisted_22$11,toDisplayString(abstractData.value.financialSummary.vehiclesInsuredCount),1)]),createBaseVNode(`div`,_hoisted_23$10,[_cache[10]||=createBaseVNode(`span`,{class:`info-label`},`Premiums Paid:`,-1),createBaseVNode(`span`,_hoisted_24$9,[createVNode(unref(bngUnit_default),{class:`no-margin`,money:abstractData.value.financialSummary.totalPremiumPaid},null,8,[`money`])])]),createBaseVNode(`div`,_hoisted_25$8,[_cache[11]||=createBaseVNode(`span`,{class:`info-label`},`Deductibles Paid:`,-1),createBaseVNode(`span`,_hoisted_26$6,[createVNode(unref(bngUnit_default),{class:`no-margin`,money:abstractData.value.financialSummary.totalDeductiblePaid},null,8,[`money`])])]),createBaseVNode(`div`,_hoisted_27$6,[_cache[12]||=createBaseVNode(`span`,{class:`info-label`},`Private Repairs:`,-1),createBaseVNode(`span`,_hoisted_28$5,[createVNode(unref(bngUnit_default),{class:`no-margin`,money:abstractData.value.financialSummary.totalPrivateRepairsPaid},null,8,[`money`])])]),createBaseVNode(`div`,_hoisted_29$5,[_cache[13]||=createBaseVNode(`span`,{class:`info-label`},`Total Spent:`,-1),createBaseVNode(`span`,_hoisted_30$5,[createVNode(unref(bngUnit_default),{class:`no-margin`,money:abstractData.value.financialSummary.totalPaid},null,8,[`money`])])])]),createBaseVNode(`div`,_hoisted_31$5,[createBaseVNode(`div`,_hoisted_32$5,[_cache[14]||=createBaseVNode(`span`,{class:`info-label`},`Damage Covered by Insurance:`,-1),createBaseVNode(`span`,_hoisted_33$5,[createVNode(unref(bngUnit_default),{class:`no-margin`,money:abstractData.value.financialSummary.damageCoveredByInsurance},null,8,[`money`])])]),_cache[15]||=createBaseVNode(`div`,{class:`info-tip blue italic`},` Insurance saved you from paying full repair costs `,-1)])])]),createBaseVNode(`div`,_hoisted_34$5,[_cache[22]||=createBaseVNode(`div`,{class:`section-title`},`Driver Score Reset`,-1),createBaseVNode(`div`,_hoisted_35$4,[createBaseVNode(`p`,_hoisted_36$4,[_cache[17]||=createTextVNode(` Reset your driver score to `,-1),createBaseVNode(`span`,_hoisted_37$3,toDisplayString(abstractData.value.driverScoreReset.resetTo),1),_cache[18]||=createTextVNode(` to remove premium penalties. `,-1)]),createBaseVNode(`div`,_hoisted_38$3,[createBaseVNode(`div`,_hoisted_39$3,[_cache[19]||=createBaseVNode(`span`,{class:`reset-label`},`Current Score:`,-1),createBaseVNode(`span`,{class:normalizeClass([`reset-value`,canResetScore.value?`red`:`green`])},toDisplayString(abstractData.value.driverScore),3)]),createBaseVNode(`div`,_hoisted_40$2,[_cache[20]||=createBaseVNode(`span`,{class:`reset-label`},`Reset To:`,-1),createBaseVNode(`span`,_hoisted_41$2,toDisplayString(abstractData.value.driverScoreReset.resetTo),1)]),createBaseVNode(`div`,_hoisted_42$2,[_cache[21]||=createBaseVNode(`span`,{class:`reset-label`},`Reset Cost:`,-1),createBaseVNode(`span`,_hoisted_43$2,[createVNode(unref(bngUnit_default),{class:`no-margin`,money:abstractData.value.driverScoreReset.resetCost},null,8,[`money`])])]),canResetScore.value&&_ctx.resetSavingsPer100km>0?(openBlock(),createElementBlock(`div`,_hoisted_44$2,` Pays for itself after xxx km `)):createCommentVNode(``,!0)]),createBaseVNode(`button`,{onClick:resetDriverScore,disabled:!canResetScore.value,class:normalizeClass([`reset-button`,{disabled:!canResetScore.value}])},toDisplayString(canResetScore.value?`Reset Score`:`Not Available (Score Already at or Higher than `+abstractData.value.driverScoreReset.resetTo+`)`),11,_hoisted_45$2)])])])):createCommentVNode(``,!0)]),_:1})]),_:1},512))}},DriverAbstract_default=__plugin_vue_export_helper_default(_sfc_main$246,[[`__scopeId`,`data-v-8041df87`]]),_hoisted_1$216={"bng-ui-scope":`logbook`,class:`career-logbook-wrapper`},_hoisted_2$175={class:`career-logbook-container`},_hoisted_3$154={class:`career-logbook-list`},_hoisted_4$129={class:`logbook-list-wrapper`},_hoisted_5$112=[`onClick`],_hoisted_6$95={class:`career-logbook-item-content`},_hoisted_7$83={class:`career-logbook-meta`},_hoisted_8$68={class:`career-logbook-newmark`},_hoisted_9$61={class:`career-logbook-item-label`},_hoisted_10$52={class:`career-logbook-details`},_hoisted_11$46={class:`career-logbook-title-newmark`},_hoisted_12$35={class:`career-logbook-meta`},_hoisted_13$29={key:0},_hoisted_14$27={class:`logbook-description`},_hoisted_15$26={key:1,class:`logbook-description logbook-table`},_hoisted_16$26={key:2},_hoisted_17$21={key:3,class:`logbook-description quest-status`},_hoisted_18$18={class:`quest-stats-wrapper`},_hoisted_19$15={class:`quest-labels`},_hoisted_20$13={class:`progress-label`},_hoisted_21$12={key:0,class:`progressbar-background`},_hoisted_22$10={class:`rewards-wrapper flex-row`},_hoisted_23$9={class:`label`},_hoisted_24$8={class:`rewards-section flex-row`},_hoisted_25$7={class:`flex-row`},_sfc_main$245={__name:`Logbook`,props:{id:String},setup(__props){useUINavScope(`logbook`);let rewardUnitTypes={money:`beambucks`,beamXP:`xp`},props=__props,sectionTabs=ref(),entryId=computed(()=>props.id===void 0?void 0:(``+props.id).replace(/%/g,`/`)),logbookTabs=ref([{id:`info`,name:`Info`,entries:[],filter:i=>i.type===`info`},{id:`history`,name:`History`,entries:[],filter:i=>i.type===`progress`}]),checkForNewLogEntries=()=>logbookTabs.value.forEach(tab=>tab.hasNew=!!tab.entries.some(i=>i.isNew));function setup$3(data){if(data.forEach(entry=>{Object.hasOwn(entry,`text`)&&(entry.text=parse$1($translate.contextTranslate(entry.text,!0)),entry._ready=!0)}),logbookTabs.value.forEach(tab=>tab.entries=data.filter(tab.filter)),checkForNewLogEntries(),entryId.value){for(let tab of logbookTabs.value)for(let entry of tab.entries)if(``+entry.entryId===entryId.value){toggleExpand(entry),tab.isPreselected=!0;return}}logbookTabs.value[0].entries.length&&toggleExpand(logbookTabs.value[0].entries[0])}ref({});let selectedEntry=ref({});ref({});let readTimer,toggleExpand=entry=>setTimeout(()=>{readTimer&&clearTimeout(readTimer),selectedEntry.value=entry,readTimer=window.setTimeout(()=>{selectedEntry.value.isNew=!1,checkForNewLogEntries(),entry.type===`quest`?Lua_default.career_modules_questManager.setQuestAsNotNew(entry.questId):Lua_default.career_modules_logbook.setLogbookEntryRead(entry.entryId,!0)},1e3)},0),tabChange=newTab=>{if(entryId.value){entryId.value=void 0;return}let tab=logbookTabs.value[newTab.id];!tab||!tab.entries||tab.entries.length===0||toggleExpand(tab.entries[0])},claimRewards=entry=>{Lua_default.career_modules_questManager.claimRewardsById(entry.questId),entry.claimable=!1,entry.claimed=!0},exit=()=>setTimeout(()=>window.bngVue.gotoAngularState(`menu.careerPause`),0);return onBeforeMount(()=>{Lua_default.simTimeAuthority.pushPauseRequest(`logbook`)}),onMounted(()=>{Lua_default.career_modules_logbook.getLogbook().then(setup$3)}),onUnmounted(()=>{Lua_default.simTimeAuthority.popPauseRequest(`logbook`)}),(_ctx,_cache)=>withDirectives((openBlock(),createBlock(unref(layoutSingle_default),{class:`logbook-layout`},{default:withCtx(()=>[createVNode(unref(bngScreenHeading_default),null,{default:withCtx(()=>[createTextVNode(toDisplayString(_ctx.$t(`ui.career.logbook.subHeading`)),1)]),_:1}),withDirectives((openBlock(),createElementBlock(`div`,_hoisted_1$216,[createBaseVNode(`div`,_hoisted_2$175,[createBaseVNode(`div`,_hoisted_3$154,[createVNode(unref(tabs_default),{ref_key:`sectionTabs`,ref:sectionTabs,onChange:tabChange,class:`bng-tabs`,"make-tab-header-classes":tabDetails=>({flagged:tabDetails.data.hasNew})},{default:withCtx(()=>[(openBlock(!0),createElementBlock(Fragment,null,renderList(logbookTabs.value,tabDetail=>(openBlock(),createBlock(unref(tab_default),{key:tabDetail.id,heading:_ctx.$t(tabDetail.name),active:tabDetail.isPreselected,data:tabDetail},{default:withCtx(()=>[withDirectives((openBlock(),createElementBlock(`div`,_hoisted_4$129,[(openBlock(!0),createElementBlock(Fragment,null,renderList(tabDetail.entries,(entry,index)=>withDirectives((openBlock(),createElementBlock(`div`,{key:entry.entryId,"bng-nav-item":``,class:normalizeClass([`career-logbook-item`,{selected:selectedEntry.value!==void 0&&selectedEntry.value.entryId==entry.entryId}]),onClick:$event=>toggleExpand(entry)},[createBaseVNode(`div`,_hoisted_6$95,[createBaseVNode(`div`,_hoisted_7$83,[createBaseVNode(`div`,null,toDisplayString(_ctx.$ctx_t(entry.cardTypeLabel)),1),createVNode(unref(bngDivider_default),{class:`vertical-divider`}),withDirectives(createBaseVNode(`div`,null,null,512),[[unref(BngRelativeTime_default),entry.time]]),withDirectives(createBaseVNode(`div`,_hoisted_8$68,null,512),[[vShow,entry.isNew]])]),createBaseVNode(`div`,_hoisted_9$61,toDisplayString(_ctx.$ctx_t(entry.title)),1)])],10,_hoisted_5$112)),[[unref(BngUiNavFocus_default),tabDetail.entries.length-index],[unref(BngSoundClass_default),`bng_click_generic_small`]])),128))])),[[unref(BngUiNavScroll_default)]])]),_:2},1032,[`heading`,`active`,`data`]))),128))]),_:1},8,[`make-tab-header-classes`])]),createBaseVNode(`div`,_hoisted_10$52,[withDirectives(createVNode(unref(bngCard_default),{class:`career-logbook-content-card`},createSlots({default:withCtx(()=>[createVNode(unref(bngCardHeading_default),{class:`logbook-entry-heading`,type:`ribbon`},{default:withCtx(()=>[createTextVNode(toDisplayString(selectedEntry.value&&_ctx.$ctx_t(selectedEntry.value.title))+` `,1),withDirectives(createBaseVNode(`div`,_hoisted_11$46,null,512),[[vShow,selectedEntry.value.isNew]]),withDirectives((openBlock(),createBlock(unref(bngButton_default),{class:`exitButton`,onClick:exit,accent:unref(ACCENTS).attention},{default:withCtx(()=>[createVNode(unref(bngBinding_default),{"ui-event":`back`,deviceMask:`xinput`}),_cache[1]||=createTextVNode(`Back`,-1)]),_:1},8,[`accent`])),[[unref(BngSoundClass_default),`bng_back_generic`]])]),_:1}),createBaseVNode(`div`,_hoisted_12$35,[createBaseVNode(`div`,null,toDisplayString(_ctx.$ctx_t(selectedEntry.value.cardTypeLabel)),1),createVNode(unref(bngDivider_default),{class:`vertical-divider`}),withDirectives(createBaseVNode(`div`,null,null,512),[[unref(BngRelativeTime_default),selectedEntry.value.time]])]),createBaseVNode(`div`,{class:normalizeClass({"card-body":!0,"with-rewards":selectedEntry.value.type===`quest`&&selectedEntry.value.rewards.length})},[selectedEntry.value.cover?(openBlock(),createElementBlock(`div`,{key:0,class:`logbook-cover-image`,style:normalizeStyle({backgroundImage:`url(${selectedEntry.value.cover})`})},[selectedEntry.value.coverText?(openBlock(),createElementBlock(`h1`,_hoisted_13$29,toDisplayString(selectedEntry.value.coverText),1)):createCommentVNode(``,!0)],4)):createCommentVNode(``,!0),createBaseVNode(`div`,_hoisted_14$27,[selectedEntry.value._ready?(openBlock(),createBlock(unref(dynamicComponent_default),{key:0,template:_ctx.$ctx_t(selectedEntry.value.text)},null,8,[`template`])):createCommentVNode(``,!0)]),selectedEntry.value.tables?(openBlock(),createElementBlock(`div`,_hoisted_15$26,[(openBlock(!0),createElementBlock(Fragment,null,renderList(selectedEntry.value.tables,(table,keyT)=>(openBlock(),createElementBlock(`table`,{key:keyT},[createBaseVNode(`tbody`,null,[createBaseVNode(`tr`,null,[(openBlock(!0),createElementBlock(Fragment,null,renderList(table.headers,(header,keyH)=>(openBlock(),createElementBlock(`th`,{key:keyH},toDisplayString(header),1))),128))]),(openBlock(!0),createElementBlock(Fragment,null,renderList(table.rows,(row,keyR)=>(openBlock(),createElementBlock(`tr`,{key:keyR},[(openBlock(!0),createElementBlock(Fragment,null,renderList(row,(data,keyD)=>(openBlock(),createElementBlock(`td`,{key:keyD},[typeof data==`object`&&data&&data.hasOwnProperty(`type`)&&data.type===`rewards`?(openBlock(),createBlock(RewardsPills_default,{key:0,rewards:data.rewards,hideNumbers:!1},null,8,[`rewards`])):(openBlock(),createBlock(unref(dynamicComponent_default),{key:1,template:_ctx.$ctx_t(data)},null,8,[`template`]))]))),128))]))),128))])]))),128))])):createCommentVNode(``,!0),selectedEntry.value.type===`quest`?(openBlock(),createElementBlock(`hr`,_hoisted_16$26)):createCommentVNode(``,!0),selectedEntry.value.type===`quest`?(openBlock(),createElementBlock(`div`,_hoisted_17$21,[_cache[2]||=createBaseVNode(`h4`,null,`Milestone Status`,-1),(openBlock(!0),createElementBlock(Fragment,null,renderList(selectedEntry.value.progress,prog=>(openBlock(),createElementBlock(`div`,null,[createBaseVNode(`div`,_hoisted_18$18,[createBaseVNode(`div`,_hoisted_19$15,[prog.done?(openBlock(),createBlock(unref(bngIcon_default),{key:0,class:`check-icon`,type:prog.failed?unref(icons).missionCheckboxCross:prog.done?unref(icons).checkboxOn:unref(icons).checkboxOff},null,8,[`type`])):createCommentVNode(``,!0),createBaseVNode(`div`,_hoisted_20$13,toDisplayString(_ctx.$ctx_t(prog.label)),1)]),prog.type===`progressBar`?(openBlock(),createElementBlock(`div`,_hoisted_21$12,[createBaseVNode(`div`,{class:`progressbar-fill`,style:normalizeStyle({width:(prog.currValue>0?prog.currValue/(prog.maxValue-prog.minValue)*100:0)+`%`})},null,4)])):createCommentVNode(``,!0)])]))),256))])):createCommentVNode(``,!0)],2)]),_:2},[selectedEntry.value.type===`quest`&&selectedEntry.value.rewards.length?{name:`footer`,fn:withCtx(()=>[createBaseVNode(`div`,_hoisted_22$10,[createBaseVNode(`div`,_hoisted_23$9,toDisplayString(_ctx.$t(`ui.career.logbook.rewards`))+`:`,1),createBaseVNode(`div`,_hoisted_24$8,[(openBlock(!0),createElementBlock(Fragment,null,renderList(selectedEntry.value.rewards,reward=>(openBlock(),createElementBlock(`div`,_hoisted_25$7,[createVNode(unref(bngUnit_default),mergeProps({class:`reward-icon`},{ref_for:!0},{[rewardUnitTypes[reward.attributeKey]]:reward.rewardAmount},{options:{formatter:x=>~~x}}),null,16,[`options`])]))),256))]),withDirectives((openBlock(),createBlock(unref(bngButton_default),{onClick:_cache[0]||=$event=>claimRewards(selectedEntry.value),disabled:!selectedEntry.value.claimable},{default:withCtx(()=>[createTextVNode(toDisplayString(_ctx.$t(`ui.career.logbook.claimRewards`)),1)]),_:1},8,[`disabled`])),[[vShow,!selectedEntry.value.claimed],[unref(BngSoundClass_default),`bng_click_generic`]]),withDirectives(createVNode(unref(bngButton_default),{disabled:!0},{default:withCtx(()=>[createTextVNode(toDisplayString(_ctx.$t(`ui.career.logbook.rewardsClaimed`)),1)]),_:1},512),[[vShow,selectedEntry.value.claimed]])])]),key:`0`}:void 0]),1536),[[vShow,selectedEntry.value!==void 0]])])])])),[[unref(BngOnUiNav_default),exit,`back,menu`],[unref(BngOnUiNav_default),sectionTabs.value&§ionTabs.value.goPrev,`tab_l`],[unref(BngOnUiNav_default),sectionTabs.value&§ionTabs.value.goNext,`tab_r`]])]),_:1})),[[unref(BngBlur_default)]])}},Logbook_default=__plugin_vue_export_helper_default(_sfc_main$245,[[`__scopeId`,`data-v-e8139034`]]),_hoisted_1$215={class:`milestones-wrapper`},_hoisted_2$174={"bng-ui-scope":`milestones`,class:`career-milestones-card`},_hoisted_3$153={class:`career-milestones-container`},_hoisted_4$128={class:`actions`},_hoisted_5$111={class:`filters`},_hoisted_6$94={class:`scrollable-container`,"bng-nav-scroll-force":``},_hoisted_7$82={class:`cards-container`},_sfc_main$244={__name:`Milestones`,props:{id:String},setup(__props){useUINavScope(`milestones`);let careerStatusRef=ref(),allEntries=[],entries=ref([]),selectOneFilters=ref(),selectedFilters=ref([`general`]),FILTER_OPTIONS=[{value:`general`,label:`General`},{value:`all`,label:`All`},{value:`mission`,label:`Challenges`},{value:`branch`,label:`Branches`},{value:`delivery`,label:`Delivery`},{value:`money`,label:`Money`},{value:`speedTrap`,label:`Speed Traps`},{value:`insurance`,label:`Insurance`}];function sortMilestones(){entries.value.sort(function(a$1,b){return a$1.claimable&&!b.claimable?-1:b.claimable&&!a$1.claimable?1:!a$1.completed&&b.completed?-1:a$1.completed&&!b.completed?1:a$1.claimId!0):entries.value=allEntries.filter(e=>e.filter[currentFilter]),sortMilestones()}function filterChanged(filterList){filterList&&(currentFilter=filterList[0]),filterEntries()}function setup$3(data){allEntries=data.list;let hasClaimable=!1;data.list.forEach(x=>{x.claimable&&(hasClaimable=!0)}),hasClaimable&&(selectedFilters.value=[`all`],filterChanged(selectedFilters.value)),filterEntries()}Lua_default.career_modules_milestones_milestones.getMilestones().then(setup$3);let claimMilestone=entry=>{Lua_default.career_modules_milestones_milestones.claim(entry.claimId).then(replacementEntry=>{careerStatusRef.value.updateDisplay();let replacementId=allEntries.findIndex(item=>item.claimId===entry.claimId);if(replacementEntry!=null&&replacementId!==-1){allEntries[replacementId]=replacementEntry,filterEntries();return}allEntries[replacementId].claimable=!1,filterEntries()})},exit=()=>{window.bngVue.gotoGameState(`progressLanding`)};return onUnmounted(()=>{Lua_default.simTimeAuthority.popPauseRequest(`milestones`)}),onBeforeMount(()=>{Lua_default.simTimeAuthority.pushPauseRequest(`milestones`)}),(_ctx,_cache)=>withDirectives((openBlock(),createBlock(unref(layoutSingle_default),{class:`milestones-layout`},{default:withCtx(()=>[createBaseVNode(`div`,_hoisted_1$215,[createVNode(unref(bngScreenHeading_default),null,{default:withCtx(()=>[..._cache[1]||=[createTextVNode(`Milestones`,-1)]]),_:1}),withDirectives((openBlock(),createElementBlock(`div`,_hoisted_2$174,[createBaseVNode(`div`,_hoisted_3$153,[createBaseVNode(`div`,_hoisted_4$128,[createVNode(unref(bngButton_default),{class:`exitButton`,onClick:exit,accent:unref(ACCENTS).attention},{default:withCtx(()=>[createVNode(unref(bngBinding_default),{tabindex:`1`,"ui-event":`back`,deviceMask:`xinput`}),_cache[2]||=createTextVNode(`Back`,-1)]),_:1},8,[`accent`]),createVNode(unref(careerStatus_default),{class:`career-page-status`,ref_key:`careerStatusRef`,ref:careerStatusRef},null,512)]),createBaseVNode(`div`,_hoisted_5$111,[createVNode(unref(bngIcon_default),{class:`career-filter-icon`,type:unref(icons).filter},null,8,[`type`]),createVNode(unref(bngPillFilters_default),{required:``,ref_key:`selectOneFilters`,ref:selectOneFilters,modelValue:selectedFilters.value,"onUpdate:modelValue":_cache[0]||=$event=>selectedFilters.value=$event,options:FILTER_OPTIONS,onValueChanged:filterChanged},null,8,[`modelValue`])]),createBaseVNode(`div`,_hoisted_6$94,[createBaseVNode(`div`,_hoisted_7$82,[(openBlock(!0),createElementBlock(Fragment,null,renderList(entries.value,entry=>withDirectives((openBlock(),createBlock(MilestoneCard_default,{tabindex:`1`,milestone:entry,isCondensed:!1,onClaim:claimMilestone},null,8,[`milestone`])),[[unref(BngSoundClass_default),entry.claimable?`bng_click_hover_generic`:`bng_hover_generic`]])),256))])])])])),[[unref(BngOnUiNav_default),exit,`back,menu`],[unref(BngOnUiNav_default),selectOneFilters.value&&selectOneFilters.value.focusPrevious,`tab_l`],[unref(BngOnUiNav_default),selectOneFilters.value&&selectOneFilters.value.focusNext,`tab_r`]])])]),_:1})),[[unref(BngOnUiNav_default),exit,`back,menu`],[unref(BngBlur_default)]])}},Milestones_default=__plugin_vue_export_helper_default(_sfc_main$244,[[`__scopeId`,`data-v-798d8c2a`]]),_hoisted_1$214={class:`panel-flex`},_hoisted_2$173={style:{"overflow-y":`scroll`}},_hoisted_3$152={class:`content-row selected-and-map-panel`},_hoisted_4$127={key:0,class:`content`},TAB_HEADINGS={parcels:`Parcels`,smallFluids:`Fluid Orders`,largeFluids:`Fluid Custom`,smallDryBulk:`Dry Bulk Orders`,largeDryBulk:`Dry Bulk Custom`,vehicles:`Vehicles`,trailers:`Trailers`,loaners:`Loaners`},_sfc_main$243={__name:`MyCargo`,props:{facilityId:String,parkingSpotPath:String},setup(__props){ref(3),ref(1);let{events:events$3}=useBridge();useUINavScope(`myCargo`);let props=__props;ref(null),ref(),ref(TAB_HEADINGS.parcels),ref(),ref();let cargoOverviewStore=useCargoOverviewStore(),updateCargoDataAll=()=>{cargoOverviewStore.requestCargoData(props.facilityId,props.parkingSpotPath)},close=()=>{Lua_default.career_modules_delivery_cargoScreen.exitCargoOverviewScreen()};return events$3.on(`updateCargoData`,updateCargoDataAll),onMounted(()=>{Lua_default.career_modules_delivery_cargoScreen.setCargoScreenTab(`all`),updateCargoDataAll()}),onUnmounted(()=>{cargoOverviewStore.menuClosed(),events$3.off(`updateCargoData`,updateCargoDataAll)}),(_ctx,_cache)=>(openBlock(),createElementBlock(Fragment,null,[_cache[22]||=createBaseVNode(`div`,{style:{color:`white`}},`#Hello`,-1),unref(cargoOverviewStore).cargoData?(openBlock(),createBlock(ComputerWrapper_default,{key:0,path:[`My Cargo`],title:`My Cargo 2`,back:``,onBack:close},{status:withCtx(()=>[..._cache[10]||=[createTextVNode(` Delivery Lvl 2 | Car Jockey Lvl 3 | Facility Reputation: Good `,-1)]]),top:withCtx(()=>[..._cache[11]||=[createBaseVNode(`div`,{style:{width:`100%`,padding:`0.3em`,background:`#8888ff`}},` FILTERTABS `,-1)]]),default:withCtx(()=>[createBaseVNode(`div`,_hoisted_1$214,[createVNode(unref(bngCard_default),{class:`content-row provided-orders-panel`},{default:withCtx(()=>[createVNode(unref(bngCardHeading_default),{type:`ribbon`,class:`cardHeading`},{default:withCtx(()=>[..._cache[12]||=[createTextVNode(` My Cargo `,-1)]]),_:1}),createVNode(unref(bngSwitch_default),{modelValue:unref(cargoOverviewStore).automaticRoute,"onUpdate:modelValue":_cache[0]||=$event=>unref(cargoOverviewStore).automaticRoute=$event},{default:withCtx(()=>[..._cache[13]||=[createTextVNode(` Automatic route `,-1)]]),_:1},8,[`modelValue`]),createVNode(unref(bngSlider_default),{min:0,max:unref(cargoOverviewStore).cargoData.playerCardGroupSets.length-1,step:1,modelValue:unref(cargoOverviewStore).playerGroupingIdx,"onUpdate:modelValue":_cache[1]||=$event=>unref(cargoOverviewStore).playerGroupingIdx=$event,onChange:unref(cargoOverviewStore).setGroupingAndSorting},null,8,[`max`,`modelValue`,`onChange`]),createVNode(unref(bngSlider_default),{min:0,max:unref(cargoOverviewStore).cargoData.sortingSets.length-1,step:1,modelValue:unref(cargoOverviewStore).playerSortingIdx,"onUpdate:modelValue":_cache[2]||=$event=>unref(cargoOverviewStore).playerSortingIdx=$event,onChange:unref(cargoOverviewStore).setGroupingAndSorting},null,8,[`max`,`modelValue`,`onChange`]),createVNode(unref(bngCardHeading_default),{type:`ribbon`,class:`cardHeading`},{default:withCtx(()=>[createTextVNode(` Grouped `+toDisplayString(unref(cargoOverviewStore).cargoData.playerCardGroupSets[unref(cargoOverviewStore).playerGroupingIdx].label)+`, Sorted `+toDisplayString(unref(cargoOverviewStore).cargoData.sortingSets[unref(cargoOverviewStore).playerSortingIdx].label),1)]),_:1}),createBaseVNode(`div`,_hoisted_2$173,[createVNode(ProvidedOrdersPanel_default,{groupSets:unref(cargoOverviewStore).cargoData.playerCardGroupSets,groupIdx:unref(cargoOverviewStore).playerGroupingIdx,sortingSets:unref(cargoOverviewStore).cargoData.sortingSets,sortIdx:unref(cargoOverviewStore).playerSortingIdx,onCardHovered:unref(cargoOverviewStore).cardHovered,onCardClicked:unref(cargoOverviewStore).cardClicked},null,8,[`groupSets`,`groupIdx`,`sortingSets`,`sortIdx`,`onCardHovered`,`onCardClicked`])])]),_:1}),createBaseVNode(`div`,_hoisted_3$152,[createVNode(unref(bngCard_default),{class:`cargo-detail`},createSlots({default:withCtx(()=>[createVNode(unref(bngCardHeading_default),{type:`ribbon`,class:`cardHeading`},{default:withCtx(()=>[..._cache[14]||=[createTextVNode(` Details View `,-1)]]),_:1}),unref(cargoOverviewStore).focusedCargo?(openBlock(),createElementBlock(`div`,_hoisted_4$127,[createVNode(CargoCard_default,{card:unref(cargoOverviewStore).focusedCargo,detailed:``},null,8,[`card`])])):createCommentVNode(``,!0)]),_:2},[unref(cargoOverviewStore).focusedCargo?{name:`buttons`,fn:withCtx(()=>[unref(cargoOverviewStore).focusedCargo.cardType==`parcelGroup`?(openBlock(),createElementBlock(Fragment,{key:0},[unref(cargoOverviewStore).focusedCargo.isFacilityCard?(openBlock(),createElementBlock(Fragment,{key:0},[createVNode(unref(bngButton_default),{disabled:!unref(cargoOverviewStore).focusedCargo.enabled||unref(cargoOverviewStore).focusedCargo.transientMoveCounts==0,accent:`text`,onClick:_cache[3]||=$event=>unref(cargoOverviewStore).clearLoad(unref(cargoOverviewStore).focusedCargo)},{default:withCtx(()=>[..._cache[15]||=[createTextVNode(` Clear Load `,-1)]]),_:1},8,[`disabled`]),createVNode(unref(bngButton_default),{disabled:!unref(cargoOverviewStore).focusedCargo.enabled||unref(cargoOverviewStore).focusedCargo.autoLoadLocations&&unref(cargoOverviewStore).focusedCargo.autoLoadLocations.length==0,accent:`text`,onClick:_cache[4]||=$event=>unref(cargoOverviewStore).loadCargoCustom(unref(cargoOverviewStore).focusedCargo)},{default:withCtx(()=>[..._cache[16]||=[createTextVNode(` Custom Load `,-1)]]),_:1},8,[`disabled`]),createVNode(unref(bngButton_default),{disabled:!unref(cargoOverviewStore).focusedCargo.enabled||unref(cargoOverviewStore).focusedCargo.autoLoadLocations&&unref(cargoOverviewStore).focusedCargo.autoLoadLocations.length<=unref(cargoOverviewStore).focusedCargo.transientMoveCounts,onClick:_cache[5]||=$event=>unref(cargoOverviewStore).loadCargoAuto(unref(cargoOverviewStore).focusedCargo)},{default:withCtx(()=>[..._cache[17]||=[createTextVNode(` Auto Load `,-1)]]),_:1},8,[`disabled`])],64)):createCommentVNode(``,!0),unref(cargoOverviewStore).focusedCargo.isPlayerCard?(openBlock(),createElementBlock(Fragment,{key:1},[createVNode(unref(bngButton_default),{accent:`text`,disabled:unref(cargoOverviewStore).focusedCargo.transientCargo,onClick:_cache[6]||=$event=>unref(cargoOverviewStore).changeDistribution(unref(cargoOverviewStore).focusedCargo)},{default:withCtx(()=>[..._cache[18]||=[createTextVNode(` Change Distribution `,-1)]]),_:1},8,[`disabled`]),createVNode(unref(bngButton_default),{disabled:unref(cargoOverviewStore).focusedCargo.transientCargo,onClick:_cache[7]||=$event=>unref(cargoOverviewStore).clearLoad(unref(cargoOverviewStore).focusedCargo)},{default:withCtx(()=>[..._cache[19]||=[createTextVNode(` Clear Load `,-1)]]),_:1},8,[`disabled`])],64)):createCommentVNode(``,!0)],64)):createCommentVNode(``,!0),unref(cargoOverviewStore).focusedCargo.cardType==`storage`?(openBlock(),createElementBlock(Fragment,{key:1},[unref(cargoOverviewStore).focusedCargo.isFacilityCard?(openBlock(),createBlock(unref(bngButton_default),{key:0,disabled:!unref(cargoOverviewStore).focusedCargo.enabled,onClick:_cache[8]||=$event=>unref(cargoOverviewStore).loadStorageCustom(unref(cargoOverviewStore).focusedCargo)},{default:withCtx(()=>[..._cache[20]||=[createTextVNode(` Load Custom `,-1)]]),_:1},8,[`disabled`])):createCommentVNode(``,!0)],64)):createCommentVNode(``,!0),unref(cargoOverviewStore).focusedCargo.cardType==`vehicleOffer`?(openBlock(),createBlock(unref(bngButton_default),{key:2,disabled:!unref(cargoOverviewStore).focusedCargo.enabled,onClick:_cache[9]||=$event=>unref(cargoOverviewStore).loadOffer(unref(cargoOverviewStore).focusedCargo)},{default:withCtx(()=>[createTextVNode(toDisplayString(unref(cargoOverviewStore).focusedCargo.spawnWhenCommitingCargo?`Don't bring out`:`Bring Out`),1)]),_:1},8,[`disabled`])):createCommentVNode(``,!0)]),key:`0`}:void 0]),1024),createVNode(unref(bngCard_default),{class:`map`},{default:withCtx(()=>[..._cache[21]||=[createTextVNode(` Map Screen `,-1)]]),_:1})])])]),_:1})):createCommentVNode(``,!0)],64))}},MyCargo_default=__plugin_vue_export_helper_default(_sfc_main$243,[[`__scopeId`,`data-v-9a756c16`]]),_hoisted_1$213={class:`paint-presets`},_hoisted_2$172={class:`paint-presets-group`},_hoisted_3$151={class:`paint-presets-name`},_hoisted_4$126={class:`presets-items`},_sfc_main$242={__name:`PaintPresets`,props:{presets:{type:Object,required:!0},showText:{type:Boolean,default:!1},editable:{type:Boolean,default:!1},current:{type:Object}},emits:[`apply`],setup(__props,{emit:__emit}){let settings$1=useSettings(),props=__props,emit$1=__emit,factoryPresets=computed(()=>{let presets=props.presets,factoryRes={},customRes={};if(typeof presets==`object`&&!Array.isArray(presets)){let paint=new Paint;for(let name in presets)try{paint.paint=presets[name];let paintObject=paint.paintObject;presets[name]&&typeof presets[name]==`object`&&presets[name].class===`custom`?customRes[name]=paintObject:factoryRes[name]=paintObject}catch{}}return{factory:factoryRes,custom:customRes}}),userPresets=ref({}),presetGroups=computed(()=>{let res=[];Object.keys(factoryPresets.value.factory).length&&res.push({name:`factory`,showTooltip:!0,editable:!1,presets:factoryPresets.value.factory}),Object.keys(factoryPresets.value.custom).length&&res.push({name:`custom`,showTooltip:!0,editable:!1,presets:factoryPresets.value.custom}),props.editable&&res.push({name:`user`,showTooltip:!1,editable:!0,presets:userPresets.value||{}});for(let group of res){let presets=Object.keys(group.presets).map(colname=>({name:colname,...group.presets[colname],css:`rgb(${group.presets[colname].baseColor.slice(0,3).map(val=>val*255)})`}));group.name!==`user`&&(presets=sortColors(presets)),group.presets=presets}return res});function average(arr){return arr.reduce((a$1,b)=>a$1+b)/arr.length}function valComparable(col,thres=.05){let bool=!0,av=average(col);for(let i=0;i=col[i];return bool&&=av>.8||av<.2,bool}function colorHigherHelper(itm){let av=average(itm.orig.baseColor.slice(0,3)),al=itm.orig.baseColor[3]/2,res=Math.abs(av-1)*al;return res===0?(av+al)/2:res+1}function colorHigher(a$1,b){let aColor=valComparable(a$1.orig.baseColor.slice(0,3)),bColor=valComparable(b.orig.baseColor.slice(0,3));if(aColor&&bColor)return colorHigherHelper(b)-colorHigherHelper(a$1);if(aColor&&!bColor)return 1;if(!aColor&&bColor)return-1;for(let i=0;i<3;i++)if(a$1.val[i]!==b.val[i])return a$1.val[i]-b.val[i];return 0}function colorValue(arr){let repitions=8,rgb=[];for(let i=0;i<3;i++)rgb[i]=(1-arr[3]/2)*arr[i]+arr[3]/2*arr[i];let lum=Math.sqrt(.241*rgb[0]+.691*rgb[1]+.068*rgb[2]),hsl=Paint.rgbToHsl(rgb),out=[hsl[0],lum,hsl[1]].map(elem=>elem*8);return out[0]%2==1&&(out[1]=8-out[1],out[2]=8-out[2]),out.push(arr[3]),out}function sortColors(list){return list.map(elem=>({val:colorValue(elem.baseColor),orig:elem})).sort(colorHigher).map(elem=>elem.orig)}function addPreset(){if(!props.current)return;let colour={...props.current,baseColor:toRaw(props.current.baseColor)},idx=1;for(;`Custom ${idx}`in userPresets.value;)idx++;let presetName=`Custom ${idx}`;userPresets.value[presetName]=colour,savePresets(),nextTick(()=>{let presetElements=document.querySelectorAll(`.paint-presets-item`),newPreset=Array.from(presetElements).find(el=>el.getAttribute(`data-preset-name`)===presetName);newPreset&&setFocusExternal(newPreset)})}function removePreset(name){let presetElements=document.querySelectorAll(`.paint-presets-item`),currentIndex=Array.from(presetElements).findIndex(el=>el.getAttribute(`data-preset-name`)===name);delete userPresets.value[name],savePresets(),nextTick(()=>{let group=presetGroups.value.find(g=>g.name===`user`);if(group)if(group.presets.length>0){let newPresetElements=document.querySelectorAll(`.paint-presets-item`);setFocusExternal(newPresetElements[Math.min(currentIndex,newPresetElements.length-1)])}else{let addButton=document.querySelector(`.presets-empty`);addButton&&setFocusExternal(addButton)}})}function savePresets(){settings$1.apply({userPaintPresets:JSON.stringify(Object.values(userPresets.value))})}return onMounted(async()=>{await settings$1.waitForData();let paints={};if(settings$1.values.userPaintPresets&&(paints=JSON.parse(settings$1.values.userPaintPresets.replace(/'/g,`"`)),typeof paints==`object`)){Array.isArray(paints)&&(paints=paints.reduce((res,paint,idx)=>({...res,[`Custom ${idx}`]:paint}),{}));let test=new Paint;for(let name in paints)try{test.paint=paints[name],paints[name]=test.paintObject}catch{delete paints[name]}}userPresets.value=paints}),(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$213,[(openBlock(!0),createElementBlock(Fragment,null,renderList(presetGroups.value,group=>(openBlock(),createElementBlock(`div`,_hoisted_2$172,[createBaseVNode(`span`,_hoisted_3$151,toDisplayString(_ctx.$t(`ui.color.${group.name}`))+`: `,1),createBaseVNode(`div`,_hoisted_4$126,[(openBlock(!0),createElementBlock(Fragment,null,renderList(group.presets,(preset,index)=>(openBlock(),createBlock(unref(bngPaintTile_default),{key:`${index}#${preset.name}`,size:24,paint:preset,"vehicle-name":`factory`,"paint-name":preset.name,"tooltip-position":`top`,class:`paint-presets-item`,"data-preset-name":preset.name,"with-menu":__props.editable&&group.editable,"custom-menu":[{label:`ui.common.delete`,action:()=>removePreset(preset.name)}],onClick:$event=>emit$1(`apply`,preset)},null,8,[`paint`,`paint-name`,`data-preset-name`,`with-menu`,`custom-menu`,`onClick`]))),128)),!group.presets||Object.keys(group.presets).length===0?withDirectives((openBlock(),createBlock(unref(bngButton_default),{key:0,class:`presets-empty`,accent:unref(ACCENTS).text,onClick:addPreset,"bng-nav-item":``},{default:withCtx(()=>[createTextVNode(toDisplayString(_ctx.$t(`ui.colorpicker.noPresets`)),1)]),_:1},8,[`accent`])),[[unref(BngOnUiNav_default),void 0,`ok`,{asMouse:!0,focusRequired:!0}]]):createCommentVNode(``,!0),group.presets&&Object.keys(group.presets).length>0&&__props.editable&&group.editable?withDirectives((openBlock(),createBlock(unref(bngButton_default),{key:1,class:`paint-presets-button`,accent:unref(ACCENTS).text,onClick:addPreset,icon:unref(icons).mathPlus,"bng-nav-item":``},null,8,[`accent`,`icon`])),[[unref(BngTooltip_default),_ctx.$t(`ui.colorpicker.colToPre`),`top`],[unref(BngOnUiNav_default),void 0,`ok`,{asMouse:!0,focusRequired:!0}]]):createCommentVNode(``,!0)])]))),256))]))}},PaintPresets_default=__plugin_vue_export_helper_default(_sfc_main$242,[[`__scopeId`,`data-v-469b2f89`]]),_hoisted_1$212={class:`paint-picker`},_hoisted_2$171={key:0,class:`paint-flex`},_hoisted_3$150={key:0,class:`paint-preview`,xmlns:`http://www.w3.org/2000/svg`,viewBox:`0 0 1 1`,preserveAspectRatio:`xMidYMid meet`},_hoisted_4$125={id:`light`,cy:`0.28`,cx:`0.35`,r:`0.3`,spreadMethod:`pad`},_hoisted_5$110=[`offset`],_hoisted_6$93=[`offset`],_hoisted_7$81={id:`colPreview`,x:`0`,y:`0`,width:`1`,height:`1`,patternUnits:`userSpaceOnUse`},_hoisted_8$67=[`fill`],_hoisted_9$60={key:1},_hoisted_10$51={key:0},_hoisted_11$45={key:2},_hoisted_12$34={key:0},_sfc_main$241={__name:`PaintPicker`,props:{modelValue:{type:[String,Object]},legacy:{type:Boolean,default:!1},presets:{type:Object,default:{}},presetsEditable:{type:Boolean,default:!1},showPresets:{type:Boolean,default:!0},showMain:{type:Boolean,default:!0},pickerMode:{type:String,default:`full_luminosity`},showText:{type:Boolean,default:!0},showPreview:{type:Boolean,default:!1},advancedOpen:{type:Boolean,default:!1},showAdvancedSwitch:{type:Boolean,default:!0}},emits:[`update:modelValue`,`change`],setup(__props,{expose:__expose,emit:__emit}){let props=__props;__expose({paintUpdated,setAdvancedVisible}),watch(()=>props.modelValue,init$3);let emitter=__emit,advanced=ref(props.advancedOpen),paint=reactive(new Paint({legacy:props.legacy}));watch(()=>props.legacy,val=>paint.legacy=val);let paintPicker=ref(paint),isPaintObject=!1,factoryPresets=computed(()=>props.presets||{}),hslColour=computed(()=>Paint.hslCssStr(paint.hsl));function init$3(){let defPaint=[1,1,1,1,0,1,1,0];if(!props.modelValue){paint.paint=defPaint;return}if(isPaintObject=props.modelValue instanceof Paint,isPaintObject){paint.paint=props.modelValue.paintObject;return}let newpaint=new Paint({legacy:props.legacy});try{newpaint.paint=props.modelValue}catch{newpaint.paint=defPaint}newpaint.paintString!==paint.paintString&&(paint.paint=newpaint.paintObject)}function returnPaint(){let res;isPaintObject?(res=props.modelValue,res.paint=paint.paintObject):res=paint.paintString,emitter(`change`,res),emitter(`update:modelValue`,res)}function paintUpdated(){init$3(),returnPaint()}function setAdvancedVisible(visible){advanced.value=visible}function applyPreset(preset){paint.paint=preset,returnPaint()}return init$3(),(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$212,[__props.showPreview||__props.showPresets?(openBlock(),createElementBlock(`div`,_hoisted_2$171,[__props.showPreview?(openBlock(),createElementBlock(`svg`,_hoisted_3$150,[createBaseVNode(`defs`,null,[createBaseVNode(`radialGradient`,_hoisted_4$125,[createBaseVNode(`stop`,mergeProps({offset:.1+.2*(1-paint.roughness)},{"stop-opacity":.4+.2*paint.roughness},{"stop-color":`#fff`}),null,16,_hoisted_5$110),createBaseVNode(`stop`,{offset:1-paint.roughness*.5,"stop-opacity":`0.0`,"stop-color":`#fff`},null,8,_hoisted_6$93)]),_cache[16]||=createBaseVNode(`radialGradient`,{id:`shadow`,cy:`0.43`,cx:`0.45`,r:`0.55`,spreadMethod:`pad`},[createBaseVNode(`stop`,{offset:`0.7`,"stop-opacity":`0.0`,"stop-color":`#000`}),createBaseVNode(`stop`,{offset:`0.85`,"stop-opacity":`0.2`,"stop-color":`#000`}),createBaseVNode(`stop`,{offset:`1.0`,"stop-opacity":`0.5`,"stop-color":`#000`})],-1),createBaseVNode(`pattern`,_hoisted_7$81,[_cache[13]||=createBaseVNode(`image`,{x:`0`,y:`0`,height:`1`,width:`1`,"xlink:href":`/ui/lib/int/colorpicker/color-chrome.png`},null,-1),createBaseVNode(`rect`,mergeProps({y:`0`,x:`0`,width:`1`,height:`1`,fill:`hsl(${hslColour.value})`},{"fill-opacity":paint.alpha/2},{stroke:`transparent`}),null,16,_hoisted_8$67),_cache[14]||=createBaseVNode(`rect`,{y:`0`,x:`0`,width:`1`,height:`1`,fill:`url(#light)`,stroke:`transparent`},null,-1),_cache[15]||=createBaseVNode(`rect`,{y:`0`,x:`0`,width:`1`,height:`1`,fill:`url(#shadow)`,stroke:`transparent`},null,-1)])]),_cache[17]||=createBaseVNode(`circle`,{cy:`0.5`,cx:`0.5`,r:`0.5`,fill:`url(#colPreview)`,stroke:`transparent`},null,-1)])):createCommentVNode(``,!0),__props.showPresets?(openBlock(),createBlock(PaintPresets_default,{key:1,presets:factoryPresets.value,"show-text":__props.showText,editable:__props.presetsEditable,current:paint.paintObject,onApply:applyPreset},null,8,[`presets`,`show-text`,`editable`,`current`])):createCommentVNode(``,!0)])):createCommentVNode(``,!0),__props.showMain?(openBlock(),createElementBlock(`div`,_hoisted_9$60,[__props.showText&&_ctx.$slots.default?(openBlock(),createElementBlock(`span`,_hoisted_10$51,[renderSlot(_ctx.$slots,`default`,{},void 0,!0)])):createCommentVNode(``,!0),createVNode(unref(bngColorPicker_default),{modelValue:paintPicker.value,"onUpdate:modelValue":_cache[0]||=$event=>paintPicker.value=$event,onChange:_cache[1]||=$event=>returnPaint(),view:__props.pickerMode,"show-text":__props.showText},null,8,[`modelValue`,`view`,`show-text`])])):createCommentVNode(``,!0),__props.showMain?(openBlock(),createElementBlock(`div`,_hoisted_11$45,[__props.showAdvancedSwitch?(openBlock(),createElementBlock(`h3`,_hoisted_12$34,[createVNode(unref(bngSwitch_default),{modelValue:advanced.value,"onUpdate:modelValue":_cache[2]||=$event=>advanced.value=$event},{default:withCtx(()=>[createTextVNode(toDisplayString(_ctx.$t(`ui.color.configurations`)),1)]),_:1},8,[`modelValue`])])):createCommentVNode(``,!0),advanced.value?(openBlock(),createElementBlock(`div`,{key:1,class:normalizeClass([`paint-slider-group`,{"paint-slider-group-fullrow":_ctx.$simplemenu.value}])},[__props.legacy?(openBlock(),createBlock(unref(bngColorSlider_default),{key:0,modelValue:paint.alpha,"onUpdate:modelValue":_cache[3]||=$event=>paint.alpha=$event,max:2,onChange:_cache[4]||=$event=>returnPaint(),fill:[`hsla(${hslColour.value}, 0)`,`hsla(${hslColour.value}, 2)`]},{default:withCtx(()=>[createTextVNode(toDisplayString(__props.showText?`${_ctx.$t(`ui.color.chrominess`)} (${paint.alphaPercent}%)`:null),1)]),_:1},8,[`modelValue`,`fill`])):createCommentVNode(``,!0),createVNode(unref(bngColorSlider_default),{modelValue:paint.metallic,"onUpdate:modelValue":_cache[5]||=$event=>paint.metallic=$event,onChange:_cache[6]||=$event=>returnPaint()},{default:withCtx(()=>[createTextVNode(toDisplayString(__props.showText?`${_ctx.$t(`ui.color.metallic`)} (${paint.metallicPercent}%)`:null),1)]),_:1},8,[`modelValue`]),createVNode(unref(bngColorSlider_default),{modelValue:paint.roughness,"onUpdate:modelValue":_cache[7]||=$event=>paint.roughness=$event,onChange:_cache[8]||=$event=>returnPaint()},{default:withCtx(()=>[createTextVNode(toDisplayString(__props.showText?`${_ctx.$t(`ui.color.roughness`)} (${paint.roughnessPercent}%)`:null),1)]),_:1},8,[`modelValue`]),createVNode(unref(bngColorSlider_default),{modelValue:paint.clearcoat,"onUpdate:modelValue":_cache[9]||=$event=>paint.clearcoat=$event,onChange:_cache[10]||=$event=>returnPaint()},{default:withCtx(()=>[createTextVNode(toDisplayString(__props.showText?`${_ctx.$t(`ui.color.clearCoat`)} (${paint.clearcoatPercent}%)`:null),1)]),_:1},8,[`modelValue`]),createVNode(unref(bngColorSlider_default),{modelValue:paint.clearcoatRoughness,"onUpdate:modelValue":_cache[11]||=$event=>paint.clearcoatRoughness=$event,onChange:_cache[12]||=$event=>returnPaint()},{default:withCtx(()=>[createTextVNode(toDisplayString(__props.showText?`${_ctx.$t(`ui.color.clearCoatRoughness`)} (${paint.clearcoatRoughnessPercent}%)`:null),1)]),_:1},8,[`modelValue`])],2)):createCommentVNode(``,!0)])):createCommentVNode(``,!0)]))}},PaintPicker_default=__plugin_vue_export_helper_default(_sfc_main$241,[[`__scopeId`,`data-v-2d18c0ad`]]),_hoisted_1$211={class:`paintingWrapper`},_hoisted_2$170={style:{overflow:`auto`}},_hoisted_3$149=[`tab-heading`],_hoisted_4$124={class:`paintPicker`},_hoisted_5$109={key:0,class:`clearCoatSection`},_hoisted_6$92={key:0,class:`innerShoppingCart`},_hoisted_7$80={class:`shoppingCartTable`},_hoisted_8$66={class:`price`},_hoisted_9$59={class:`price--total`},_hoisted_10$50={class:`purchase-button-container`},_sfc_main$240={__name:`Painting`,props:{noHeader:Boolean},setup(__props,{expose:__expose}){let{units,events:events$3}=useBridge(),presets=ref({});Lua_default.career_modules_painting.getFactoryPaint().then(data=>presets.value=data);let colorClass=ref(`factory`),paintIndex=ref(0),chosenPackage=ref([{},{},{}]),changedPaint=ref(!1),totalPrice=ref(0),clearCoatActive=ref(!1),clearCoatPolish=ref(0),paints=ref([]),originalPaints=ref([]),prices=ref({}),colorClassData=ref({}),canPay=ref(!1),paintPicker=ref(null),paintClassTabInfo=[{title:`Factory`},{title:`Gloss`,paintClasses:[{id:`matte`,title:`Matte`},{id:`semiGloss`,title:`Semi Gloss`},{id:`gloss`,title:`Full Gloss`}]},{title:`Metallic`,paintClasses:[{id:`semiMetallic`,title:`Semi Metallic`},{id:`metallic`,title:`Metallic`},{id:`chrome`,title:`Chrome`}]},{title:`Custom`}],clearCoatUpdateCallback=newValue=>{clearCoatPolish.value=0,changeClearCoatPolish(0),enableClearCoat(newValue)},enableClearCoat=enabled=>{paints.value[paintIndex.value]._clearcoat=enabled?1:0,paintPicker.value.paintUpdated()},changeClearCoatPolish=value=>{paints.value[paintIndex.value]._clearcoatRoughness=-.13*value+.13,paintPicker.value.paintUpdated()},getShoppingCartTable=()=>{let res=[];for(let[index,paintOptions]of chosenPackage.value.entries())Object.keys(paintOptions).length&&(res.push({name:`Paint `+(index+1)+`: `+getNicePaintClassName(paintOptions.paintClass),price:prices.value.basePrices[paintOptions.paintClass].money.amount,topLevel:!0,index}),paintOptions.clearCoat&&(res.push({name:`Clearcoat`,price:prices.value.clearcoatBase.money.amount}),res.push({name:`Extra Clearcoat Polish`,price:prices.value.clearcoatPolishFactor.money.amount*paintOptions.clearCoatPolish})));return res};events$3.on(`sendPaintingShoppingCartData`,data=>{canPay.value=data.canPay,totalPrice.value=data.totalPrice.money.amount}),Lua_default.career_modules_painting.getPaintData().then(data=>{if(prices.value=data.prices,!data||!Array.isArray(data.colors)){paints.value=[];return}paints.value=data.colors.map(val=>new Paint({paint:val})),originalPaints.value=data.colors.map(val=>new Paint({paint:val})),colorClassData.value=data.colorClassData});let getPickerShowPresets=()=>colorClass.value==`factory`,getPickerPresetsEditable=()=>colorClass.value==`custom`,showPickerMain=()=>colorClass.value!=`factory`,showClearCoatOption=()=>colorClass.value!=`factory`&&colorClass.value!=`custom`,setCurrentColorClass=()=>{paintPicker.value.setAdvancedVisible(!1),paints.value[paintIndex.value]._metallic=colorClassData.value[colorClass.value].metallic,paints.value[paintIndex.value]._roughness=colorClassData.value[colorClass.value].roughness,clearCoatActive.value=!1,enableClearCoat(!1)},changedPaintIndexTab=tab=>{paintIndex.value=tab.index,colorClass.value=chosenPackage.value[paintIndex.value].paintClass||`factory`,paintPicker.value.setAdvancedVisible(colorClass.value==`custom`),clearCoatActive.value=chosenPackage.value[paintIndex.value].clearCoat,clearCoatPolish.value=chosenPackage.value[paintIndex.value].clearCoatPolish},changedTopLevelPaintClassTab=tab=>{let classTab={Factory:`factory`,Custom:`custom`,Gloss:`semiGloss`,Metallic:`metallic`}[tab.heading];classTab&&changedPaintClassTab(classTab)},changedPaintClassTab=paintClass=>{if(paintClass==`factory`){colorClass.value=`factory`;return}if(paintClass==`custom`){colorClass.value=`custom`,paintPicker.value.setAdvancedVisible(!0),clearCoatActive.value=!1;return}colorClass.value=paintClass,setCurrentColorClass()};function resetPaint(index){chosenPackage.value[index]={},Object.assign(paints.value[index],originalPaints.value[index]);let chosenPackageEmpty=!0;for(let[index$1,color]of Object.entries(chosenPackage.value))Object.keys(color).length!==0&&(chosenPackageEmpty=!1);chosenPackageEmpty&&(changedPaint.value=!1),Lua_default.career_modules_painting.setPaints(paints.value.map(paint=>paint.paintObject),chosenPackage.value)}function onChange(){colorClass.value==`factory`&&(clearCoatActive.value=!1),chosenPackage.value[paintIndex.value].paintClass=colorClass.value,chosenPackage.value[paintIndex.value].clearCoat=clearCoatActive.value,chosenPackage.value[paintIndex.value].clearCoatPolish=clearCoatPolish.value,changedPaint.value=!0,Lua_default.career_modules_painting.setPaints(paints.value.map(paint=>paint.paintObject),chosenPackage.value)}let NICE_PAINT_CLASS_NAMES={factory:`Factory`,semiGloss:`Semi Gloss`,gloss:`Gloss`,semiMetallic:`Semi Metallic`,metallic:`Metallic`,matte:`Matte`,chrome:`Chrome`,custom:`Custom`},getNicePaintClassName=paintClass=>NICE_PAINT_CLASS_NAMES[paintClass];function headerClass(tab){return{"painting-tab":!0,[`painting-tab-${tab.index}`]:!0}}let headerVars=computed(()=>paints.value.reduce((res,paint,idx)=>({...res,[`--painting-dot-${idx}`]:`hsl(${Paint.hslCssStr(paint.hsl)})`}),{})),apply$1=()=>Lua_default.career_modules_painting.apply(),close=()=>Lua_default.career_modules_painting.close();return onMounted(()=>{Lua_default.career_modules_painting.onUIOpened()}),onUnmounted(close),__expose({apply:apply$1,close}),(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$211,[withDirectives((openBlock(),createBlock(unref(bngCard_default),{class:`paintingPage`},{default:withCtx(()=>[createBaseVNode(`div`,_hoisted_2$170,[__props.noHeader?createCommentVNode(``,!0):(openBlock(),createBlock(unref(bngCardHeading_default),{key:0},{default:withCtx(()=>[..._cache[3]||=[createTextVNode(` Painting `,-1)]]),_:1})),createVNode(unref(tabs_default),{class:`bng-tabs`,"selected-index":0,"make-tab-header-classes":headerClass,style:normalizeStyle(headerVars.value),onChange:changedPaintIndexTab},{default:withCtx(()=>[(openBlock(!0),createElementBlock(Fragment,null,renderList(paints.value,(paint,idx)=>(openBlock(),createBlock(unref(tabs_default),{key:idx,"tab-heading":_ctx.$t(`ui.trackBuilder.matEditor.paint`)+` `+(idx+1),class:`bng-tabs`,"selected-index":0,onChange:changedTopLevelPaintClassTab},{default:withCtx(()=>[(openBlock(),createElementBlock(Fragment,null,renderList(paintClassTabInfo,(paintClassTab,idx$1)=>createBaseVNode(`div`,{key:idx$1,"tab-heading":paintClassTab.title,style:{margin:`0.3em`,"background-color":`#00000000`}},[(openBlock(!0),createElementBlock(Fragment,null,renderList(paintClassTab.paintClasses,(paintClass,idx$2)=>(openBlock(),createBlock(unref(bngButton_default),{key:idx$2,onClick:$event=>changedPaintClassTab(paintClass.id),accent:colorClass.value==paintClass.id?void 0:unref(ACCENTS).secondary,class:`paint-class-button`},{default:withCtx(()=>[createTextVNode(toDisplayString(paintClass.title),1)]),_:2},1032,[`onClick`,`accent`]))),128))],8,_hoisted_3$149)),64))]),_:2},1032,[`tab-heading`]))),128))]),_:1},8,[`style`]),createVNode(unref(bngCard_default),null,{default:withCtx(()=>[createBaseVNode(`div`,_hoisted_4$124,[createVNode(PaintPicker_default,{ref_key:`paintPicker`,ref:paintPicker,modelValue:paints.value[paintIndex.value],"onUpdate:modelValue":_cache[0]||=$event=>paints.value[paintIndex.value]=$event,"show-main":showPickerMain(),presets:getPickerShowPresets()?presets.value:void 0,"presets-editable":getPickerPresetsEditable(),"advanced-open":!1,"show-advanced-switch":!1,onChange},null,8,[`modelValue`,`show-main`,`presets`,`presets-editable`]),showClearCoatOption()?(openBlock(),createElementBlock(`div`,_hoisted_5$109,[createVNode(unref(bngSwitch_default),{modelValue:clearCoatActive.value,"onUpdate:modelValue":_cache[1]||=$event=>clearCoatActive.value=$event,onValueChanged:clearCoatUpdateCallback},{default:withCtx(()=>[createTextVNode(` Add Clear Coat (Baseprice: `+toDisplayString(unref(units).beamBucks(prices.value.clearcoatBase.money.amount))+`) `,1)]),_:1},8,[`modelValue`]),clearCoatActive.value?(openBlock(),createBlock(unref(bngColorSlider_default),{key:0,style:{"margin-top":`0.7em`},modelValue:clearCoatPolish.value,"onUpdate:modelValue":_cache[2]||=$event=>clearCoatPolish.value=$event,onChange:changeClearCoatPolish},{default:withCtx(()=>[..._cache[4]||=[createTextVNode(` Clear Coat Polish `,-1)]]),_:1},8,[`modelValue`])):createCommentVNode(``,!0)])):createCommentVNode(``,!0)])]),_:1})])]),_:1})),[[unref(BngBlur_default),1]]),createVNode(unref(bngCard_default),{class:`shoppingCart`},{default:withCtx(()=>[createVNode(unref(bngCardHeading_default),null,{default:withCtx(()=>[..._cache[5]||=[createTextVNode(`Shopping Cart`,-1)]]),_:1}),changedPaint.value?(openBlock(),createElementBlock(`div`,_hoisted_6$92,[createBaseVNode(`table`,_hoisted_7$80,[_cache[9]||=createBaseVNode(`thead`,null,[createBaseVNode(`tr`,null,[createBaseVNode(`th`),createBaseVNode(`th`,{class:`article`},`Option`),createBaseVNode(`th`,{class:`price`},`Price`)])],-1),createBaseVNode(`tbody`,null,[(openBlock(!0),createElementBlock(Fragment,null,renderList(getShoppingCartTable(),(date,idx)=>(openBlock(),createElementBlock(`tr`,null,[createBaseVNode(`th`,null,[date.topLevel?(openBlock(),createBlock(unref(bngButton_default),{key:0,onClick:$event=>resetPaint(date.index)},{default:withCtx(()=>[..._cache[6]||=[createTextVNode(`remove`,-1)]]),_:1},8,[`onClick`])):createCommentVNode(``,!0)]),createBaseVNode(`th`,{class:normalizeClass(date.topLevel?`article`:`article--subLevel`)},toDisplayString(date.name),3),createBaseVNode(`th`,_hoisted_8$66,toDisplayString(unref(units).beamBucks(date.price)),1)]))),256)),createBaseVNode(`tr`,null,[_cache[7]||=createBaseVNode(`th`,null,null,-1),_cache[8]||=createBaseVNode(`th`,{class:`article--total`},`Total`,-1),createBaseVNode(`th`,_hoisted_9$59,toDisplayString(unref(units).beamBucks(totalPrice.value)),1)])])])])):createCommentVNode(``,!0),createBaseVNode(`div`,_hoisted_10$50,[withDirectives((openBlock(),createBlock(unref(bngButton_default),{class:`purchase-button`,disabled:!canPay.value||!changedPaint.value,"show-hold":``},{default:withCtx(()=>[..._cache[10]||=[createTextVNode(` Purchase and Apply `,-1)]]),_:1},8,[`disabled`])),[[unref(BngOnUiNav_default),void 0,`ok`,{asMouse:!0,focusRequired:!0}],[unref(BngClick_default),{holdCallback:()=>apply$1(),holdDelay:1e3,repeatInterval:0}]])])]),_:1})]))}},Painting_default=__plugin_vue_export_helper_default(_sfc_main$240,[[`__scopeId`,`data-v-9dc00fbe`]]),_sfc_main$239={__name:`PaintingMain`,setup(__props){useComputerStore();let elPainting=ref(),close=()=>elPainting.value.close();return(_ctx,_cache)=>(openBlock(),createBlock(ComputerWrapper_default,{path:[`Painting`],title:`Painting`,back:``,onBack:close},{default:withCtx(()=>[createVNode(Painting_default,{ref_key:`elPainting`,ref:elPainting,"no-header":``},null,512)]),_:1}))}},PaintingMain_default=_sfc_main$239;const usePartInventoryStore=defineStore(`partInventory`,()=>{let{events:events$3}=useBridge(),partInventoryData=ref({}),newPartsPopupOpen=ref(!1),newParts=ref([]),searchString=ref(``);function requestInitialData(){Lua_default.career_modules_partInventory.sendUIData()}function closeNewPartsPopup(){newPartsPopupOpen.value=!1}function closeMenu(){searchString.value=``,Lua_default.career_modules_partInventory.closeMenu()}function partInventoryClosed(){Lua_default.career_modules_partInventory.partInventoryClosed()}function dispose$2(){events$3.off(`partInventoryData`)}function openNewPartsPopup(newPartIds){newPartsPopupOpen.value=!0,newParts.value=[];for(let i=0;ipart.description.description.toLowerCase().includes(searchString.value.toLowerCase())||part.name.toLowerCase().includes(searchString.value.toLowerCase()),searchValueChanged=()=>{partInventoryData.value.partList.filter?partInventoryData.value.filteredPartList=partInventoryData.value.partList.filter(doesPartPassFilter):partInventoryData.value.filteredPartList={}};return watch(()=>searchString.value,searchValueChanged),events$3.on(`partInventoryData`,data=>{partInventoryData.value=data,searchValueChanged()}),{closeMenu,closeNewPartsPopup,dispose:dispose$2,newParts,newPartsPopupOpen,openNewPartsPopup,partInventoryClosed,partInventoryData,requestInitialData,searchString}});var _hoisted_1$210={style:{padding:`1em`}},_hoisted_2$169={class:`selectButtons`},_hoisted_3$148={class:`part-info-row`},_hoisted_4$123={class:`partList`},_hoisted_5$108=[`onClick`],_hoisted_6$91={class:`part-info-col`},_hoisted_7$79={class:`part-name`},_hoisted_8$65={class:`part-info-row`},_hoisted_9$58={class:`right`},_hoisted_10$49={class:`right`},_hoisted_11$44={class:`center`},_hoisted_12$33={class:`popup-buttons`},_sfc_main$238={__name:`PartSellingPopup`,props:{parts:{type:Array,default:[]}},emits:[`return`],setup(__props,{emit:__emit}){useUINavScope(`partSelling`);let{units}=useBridge(),partsChecked=ref([]),emit$1=__emit,props=__props,saleData=computed(()=>{let total=0,numberOfSelected=0;for(let[index,isChecked]of Object.entries(partsChecked.value))if(isChecked){let part=props.parts[index];total+=part.data.finalValue,numberOfSelected+=1}return{price:total,numberOfSelected}}),buildRefList=()=>{for(let i=0;i{for(let i=0;i{let partIds=[];for(let[index,isChecked]of Object.entries(partsChecked.value))if(isChecked){let part=props.parts[index];partIds.push(part.data.id)}Lua_default.career_modules_partInventory.sellParts(partIds),close()},close=()=>{emit$1(`return`,!0)};return onMounted(buildRefList),(_ctx,_cache)=>withDirectives((openBlock(),createBlock(unref(bngCard_default),{"bng-ui-scope":`partSelling`,class:`sellingCard`},{default:withCtx(()=>[createVNode(unref(bngCardHeading_default),null,{default:withCtx(()=>[..._cache[2]||=[createTextVNode(`Sell Parts`,-1)]]),_:1}),createBaseVNode(`div`,_hoisted_1$210,[createBaseVNode(`div`,_hoisted_2$169,[_cache[5]||=createTextVNode(` Select: `,-1),createBaseVNode(`div`,_hoisted_3$148,[createVNode(unref(bngButton_default),{accent:unref(ACCENTS).secondary,onClick:_cache[0]||=$event=>selectAll(!0)},{default:withCtx(()=>[..._cache[3]||=[createTextVNode(` All `,-1)]]),_:1},8,[`accent`]),createVNode(unref(bngButton_default),{accent:unref(ACCENTS).secondary,onClick:_cache[1]||=$event=>selectAll(!1)},{default:withCtx(()=>[..._cache[4]||=[createTextVNode(` None `,-1)]]),_:1},8,[`accent`])])]),createBaseVNode(`div`,_hoisted_4$123,[(openBlock(!0),createElementBlock(Fragment,null,renderList(__props.parts,(part,index)=>(openBlock(),createElementBlock(`div`,{class:normalizeClass([`part-item`,partsChecked.value[index]?`partSelected`:``]),"bng-nav-item":``,onClick:$event=>partsChecked.value[index]=!partsChecked.value[index]},[createVNode(unref(bngIcon_default),{class:`selectionCheckbox`,type:partsChecked.value[index]?unref(icons).checkboxOn:unref(icons).checkboxOff},null,8,[`type`]),createBaseVNode(`div`,_hoisted_6$91,[createBaseVNode(`div`,null,[createBaseVNode(`span`,_hoisted_7$79,toDisplayString(part.name),1)]),createBaseVNode(`div`,_hoisted_8$65,[createBaseVNode(`span`,_hoisted_9$58,toDisplayString(part.mileage),1),createBaseVNode(`span`,_hoisted_10$49,[createVNode(unref(bngPropVal_default),{iconType:unref(icons).beamCurrency,valueLabel:part.valueFormatted},null,8,[`iconType`,`valueLabel`])]),createBaseVNode(`span`,_hoisted_11$44,toDisplayString(part.model),1)])])],10,_hoisted_5$108))),256))]),createBaseVNode(`div`,_hoisted_12$33,[withDirectives((openBlock(),createBlock(unref(bngButton_default),{disabled:saleData.value.numberOfSelected<=0,"show-hold":``},{default:withCtx(()=>[createTextVNode(` Sell `+toDisplayString(saleData.value.numberOfSelected)+` parts for `,1),createVNode(unref(bngUnit_default),{money:saleData.value.price},null,8,[`money`])]),_:1},8,[`disabled`])),[[unref(BngClick_default),{holdCallback:sellSelectedParts,holdDelay:1e3,repeatInterval:0}]]),createVNode(unref(bngButton_default),{accent:unref(ACCENTS).attention,onClick:close},{default:withCtx(()=>[..._cache[6]||=[createTextVNode(` Cancel `,-1)]]),_:1},8,[`accent`])])])]),_:1})),[[unref(BngOnUiNav_default),close,`back,menu`]])}},PartSellingPopup_default=__plugin_vue_export_helper_default(_sfc_main$238,[[`__scopeId`,`data-v-c325ab7a`]]),_hoisted_1$209={style:{height:`100%`,color:`white`}},_hoisted_2$168={key:0},_hoisted_3$147={class:`veh-part-caption`},_hoisted_4$122={class:`veh-name`},_hoisted_5$107={class:`veh-name-count`},_hoisted_6$90={class:`part-item`,"bng-ui-scope":`veh-part-inv`},_hoisted_7$78={key:0,class:`part-info-col`},_hoisted_8$64={class:`part-name`},_hoisted_9$57={class:`part-info-row`},_hoisted_10$48={class:`right`},_hoisted_11$43={class:`right`},_hoisted_12$32={key:0,class:`center`},_hoisted_13$28={key:1,class:`center`},_hoisted_14$26={class:`center`},_hoisted_15$25={key:0},_hoisted_16$25={class:`center`},_hoisted_17$20={key:0},immediateLimit=15,_sfc_main$237={__name:`PartList`,emits:[`partSold`],setup(__props,{emit:__emit}){let{units}=useBridge(),emit$1=__emit,partInventoryStore=usePartInventoryStore(),groupBy=ref(`location`),groups=ref([]),accordionItems=ref([]),disableInstallButtons=ref(!1),addExpandedFuncToGroup=group=>{group.onExpanded=state=>{let grp=groups.value.find(g=>g.id===group.id);if(grp.expanded=state,!state){delete grp.ready;let elm=document.querySelector(`[data-groupid="${group.id}"] > .bng-accitem-caption`);elm&&elm.focus();return}`ready`in grp||(grp.ready=!1,setTimeout(()=>{let grp$1=groups.value.find(g=>g.id===group.id);grp$1&&typeof grp$1.ready==`boolean`&&(grp$1.ready=!0)},100))}},openSellPopup=async()=>{await addPopup(PartSellingPopup_default,{parts:groups.value[0].parts}).promise&&emit$1(`partSold`)};watchEffect(()=>{if(disableInstallButtons.value=!1,!partInventoryStore||!Array.isArray(partInventoryStore.partInventoryData.partList)||partInventoryStore.partInventoryData.partList.length===0)return[];let res=[];if(groupBy.value==`location`){let group={id:0,name:` Inventory`,parts:[],expanded:!1,icon:icons.BNGFolder};addExpandedFuncToGroup(group),res.push(group);for(let[vehId,vehicle]of Object.entries(partInventoryStore.partInventoryData.vehicles)){let group$1={id:vehId,name:vehicle.niceName,parts:[],expanded:!1,thumbnail:partInventoryStore.partInventoryData.vehicles[vehId].thumbnail};addExpandedFuncToGroup(group$1),res.push(group$1)}}for(let part of partInventoryStore.partInventoryData.filteredPartList){let item={name:part.missingFile?`Missing File`:part.description.description,model:part.vehicleModel,mileage:units.buildString(`length`,part.partCondition.odometer,0),valueFormatted:units.beamBucks(part.finalValue),location:part.location,locationName:part.location===0?` Inventory`:partInventoryStore.partInventoryData.vehicles[part.location].niceName,functions:{install:!1,uninstall:!1,sell:!1},data:part};!part.missingFile&&part.accessible&&(item.functions.install=part.fitsCurrentVehicle&&part.location!==partInventoryStore.partInventoryData.currentVehicle&&(part.location===0||!partInventoryStore.partInventoryData.brokenVehicleInventoryIds[part.location])&&!partInventoryStore.partInventoryData.brokenVehicleInventoryIds[partInventoryStore.partInventoryData.currentVehicle],item.functions.uninstall=part.location!==0&&!part.isInCoreSlot&&!partInventoryStore.partInventoryData.brokenVehicleInventoryIds[part.location],item.functions.sell=part.location===0);let groupId=item[groupBy.value],group=res.find(g=>g.id==groupId);group||(group={id:groupId,name:item[`${groupBy.value}Name`]||item[groupBy.value],parts:[],expanded:!1},part.location>0?group.thumbnail=partInventoryStore.partInventoryData.vehicles[part.location].thumbnail:group.icon=icons.BNGFolder,addExpandedFuncToGroup(group),res.push(group)),group.parts.push(item)}if(res.length>0){let sorter=(a$1,b)=>a$1.name.localeCompare(b.name);res.sort(sorter);for(let group of res)group.parts.sort(sorter)}for(let group of groups.value)if(group.ready){let grp=res.find(g=>g.name===group.name);grp&&(grp.expanded=!0,grp.ready=!0)}groups.value=res});let confirmSellPart=async partToSell=>{await openConfirmation(partToSell.description.description,`Do you want to sell this part for ${units.beamBucks(partToSell.finalValue)}?`,[{label:$translate.instant(`ui.common.yes`),value:!0,extras:{default:!0}},{label:$translate.instant(`ui.common.no`),value:!1,extras:{accent:ACCENTS.secondary}}])&&sellPart(partToSell)},sellPart=part=>{Lua_default.career_modules_partInventory.sellParts([part.id]),emit$1(`partSold`)};return(_ctx,_cache)=>withDirectives((openBlock(),createElementBlock(`div`,_hoisted_1$209,[createVNode(unref(bngInput_default),{class:`searchField`,"floating-label":`Search`,"leading-icon":unref(icons).search,modelValue:unref(partInventoryStore).searchString,"onUpdate:modelValue":_cache[0]||=$event=>unref(partInventoryStore).searchString=$event,modelModifiers:{trim:!0}},null,8,[`leading-icon`,`modelValue`]),withDirectives((openBlock(),createBlock(unref(bngCard_default),{style:{"max-height":`90%`}},{default:withCtx(()=>[unref(partInventoryStore)?(openBlock(),createBlock(unref(accordion_default),{key:1,class:`part-groups`,singular:``},{default:withCtx(()=>[(openBlock(!0),createElementBlock(Fragment,null,renderList(groups.value,(group,index)=>(openBlock(),createBlock(unref(accordionItem_default),{key:group.id,"data-groupid":group.id,ref_for:!0,ref_key:`accordionItems`,ref:accordionItems,navigable:``,onExpanded:group.onExpanded,onSelected:$event=>accordionItems.value[index]?accordionItems.value[index].captionClick():void 0},{caption:withCtx(()=>[createBaseVNode(`div`,_hoisted_3$147,[group.icon?(openBlock(),createBlock(unref(bngIcon_default),{key:0,class:`veh-icon`,type:group.icon},null,8,[`type`])):createCommentVNode(``,!0),group.thumbnail?(openBlock(),createElementBlock(`div`,{key:1,class:`veh-preview`,style:normalizeStyle({backgroundImage:`url('${group.thumbnail}')`})},null,4)):createCommentVNode(``,!0),createBaseVNode(`span`,_hoisted_4$122,[createTextVNode(toDisplayString(group.name)+` `,1),createBaseVNode(`span`,_hoisted_5$107,`(`+toDisplayString(group.parts.length)+`)`,1)])])]),default:withCtx(()=>[group.name==` Inventory`?(openBlock(),createBlock(unref(bngButton_default),{key:0,accent:unref(ACCENTS).outlined,onClick:_cache[1]||=$event=>openSellPopup()},{default:withCtx(()=>[..._cache[2]||=[createTextVNode(` Sell Parts `,-1)]]),_:1},8,[`accent`])):createCommentVNode(``,!0),(openBlock(!0),createElementBlock(Fragment,null,renderList(group.parts,(part,index$1)=>withDirectives((openBlock(),createElementBlock(`div`,_hoisted_6$90,[group.ready||index$1confirmSellPart(part.data)},{default:withCtx(()=>[..._cache[3]||=[createTextVNode(` Sell `,-1)]]),_:1},8,[`accent`,`onClick`])):createCommentVNode(``,!0)])),[[unref(BngOnUiNav_default),()=>group.onExpanded(!1),`back`]])),256))]),_:2},1032,[`data-groupid`,`onExpanded`,`onSelected`]))),128))]),_:1})):(openBlock(),createElementBlock(`div`,_hoisted_2$168,` Please wait... `))]),_:1})),[[unref(BngDisabled_default),!unref(partInventoryStore)]])])),[[unref(BngBlur_default)]])}},PartList_default=__plugin_vue_export_helper_default(_sfc_main$237,[[`__scopeId`,`data-v-7c222f4e`]]),_hoisted_1$208={style:{width:`100%`}},_sfc_main$236={__name:`PartInventoryAddedParts`,props:{parts:{type:Object,default:{}}},setup(__props){let{units}=useBridge(),getLocationName=part=>part.location?`Vehicle No. `+part.location+` (`+part.vehicleModel+`)`:`Inventory`;return(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,null,[_cache[1]||=createTextVNode(` The following additional parts have been added to the vehicle from your inventory to fill the core slots: `,-1),createBaseVNode(`table`,_hoisted_1$208,[_cache[0]||=createBaseVNode(`thead`,null,[createBaseVNode(`tr`,null,[createBaseVNode(`th`,null,`id`),createBaseVNode(`th`,null,`Description`),createBaseVNode(`th`,null,`Location`),createBaseVNode(`th`,null,`Mileage`),createBaseVNode(`th`,null,`Part Value`)])],-1),createBaseVNode(`tbody`,null,[(openBlock(!0),createElementBlock(Fragment,null,renderList(__props.parts,(part,key)=>(openBlock(),createElementBlock(`tr`,{key},[createBaseVNode(`td`,null,toDisplayString(part.id),1),createBaseVNode(`td`,null,toDisplayString(part.description.description),1),createBaseVNode(`td`,null,toDisplayString(getLocationName(part)),1),createBaseVNode(`td`,null,toDisplayString(unref(units).buildString(`length`,part.partCondition.odometer,0)),1),createBaseVNode(`td`,null,toDisplayString(unref(units).beamBucks(part.finalValue)),1)]))),128))])])]))}},PartInventoryAddedParts_default=__plugin_vue_export_helper_default(_sfc_main$236,[[`__scopeId`,`data-v-8dbd3a82`]]),_sfc_main$235={__name:`PartInventoryMain`,setup(__props){useComputerStore();let wrapper=ref(),partInventoryStore=usePartInventoryStore();watch(()=>partInventoryStore.newPartsPopupOpen,(newVal,oldVal)=>newVal&&confirmAddedParts());let confirmAddedParts=async vehicle=>{await openMessage(``,{component:markRaw(PartInventoryAddedParts_default),props:{parts:partInventoryStore.newParts}}),closeNewPartsPopup()},updateCareerStatus=()=>{wrapper.value.statusUpdate()};onBeforeMount(()=>{partInventoryStore.requestInitialData()}),onUnmounted(()=>{partInventoryStore.partInventoryClosed(),partInventoryStore.$dispose()});let close=()=>{partInventoryStore.closeMenu()},closeNewPartsPopup=()=>{partInventoryStore.closeNewPartsPopup()};return(_ctx,_cache)=>(openBlock(),createBlock(ComputerWrapper_default,{ref_key:`wrapper`,ref:wrapper,path:[`Part Inventory`],title:`Part Inventory`,back:``,onBack:close},{default:withCtx(()=>[createVNode(PartList_default,{class:`part-inventory`,onPartSold:updateCareerStatus})]),_:1},512))}},PartInventoryMain_default=__plugin_vue_export_helper_default(_sfc_main$235,[[`__scopeId`,`data-v-54c60dea`]]);const usePartShoppingStore=defineStore(`partShopping`,()=>{let{events:events$3}=useBridge(),partShoppingData=ref({}),filteredSlots=ref([]),path=ref(``),filteredParts=ref([]),category=ref(``),expandedSlots=ref({}),searchString=``,slotToScrollTo=ref(),backAction=()=>{},slotsDict={},partFilter;function doesNameContainString(name,searchStrings){for(let searchString$1 of searchStrings)if(name.includes(searchString$1))return!0;return!1}function filterParts(){if(filteredParts.value=[],slotsDict={},partShoppingData.value.partsInShop){for(let[_,part]of Object.entries(partShoppingData.value.partsInShop)){if(!part.slot)continue;partFilter?doesNameContainString(part.name,partFilter)&&filteredParts.value.push(part):part.containingSlot===path.value&&filteredParts.value.push(part);let niceName=partShoppingData.value.slotsNiceName[part.slot];niceName==null?slotsDict[part.slot]=part.slot:slotsDict[part.slot]=niceName}filteredParts.value.sort((a$1,b)=>a$1.emptyPlaceholder?-1:b.emptyPlaceholder?1:a$1.partId&&!b.partId?-1:!a$1.partId&&b.partId?1:a$1.description.description0?(filteredSlotsDict=getSlotsFromSearchString(),filteredSlots.value=partShoppingData.value.searchSlotList.filter(doesSlotPassFilter)):filteredSlots.value=[]}function setSlotExpanded(path$1,expanded){expandedSlots.value[path$1]=expanded}function setSlot(_slot){_slot==``&&(slotToScrollTo.value=path.value),path.value=_slot,partFilter=void 0,filterParts()}function setCategory(_category){category.value=_category,filterSlots(),category.value==`everything`||category.value==``?setSlot(``):category.value==`cargo`&&(path.value=`Blablabla`,partFilter=[`cargo_load`],filterParts())}let requestInitialData=()=>{Lua_default.career_modules_partShopping.sendShoppingDataToUI()},cancelShopping=()=>{expandedSlots.value={},Lua_default.career_modules_partShopping.cancelShopping(),setCategory(``)};function fixSlots(slot){if(`children`in slot){Array.isArray(slot.children)||(slot.children=Object.values(slot.children).filter(Boolean)),slot.children.sort((a$1,b)=>(a$1.slotNiceName||a$1.slot)<(b.slotNiceName||b.slot)?-1:1);for(let childSlot of slot.children)fixSlots(childSlot)}}let handleShoppingData=data=>{data.partTree&&fixSlots(data.partTree),partShoppingData.value=data,filterParts(),filterSlots()},searchValueChanged=_searchString=>{searchString=_searchString,filterSlots()},listen=state=>{events$3[state?`on`:`off`](`partShoppingData`,handleShoppingData)};listen(!0);function dispose$2(){listen(!1)}return{partShoppingData,slot:path,filteredSlots,filteredParts,category,expandedSlots,slotToScrollTo,searchValueChanged,setSlot,setCategory,requestInitialData,cancelShopping,dispose:dispose$2,setSlotExpanded,set backAction(actionFunc){backAction=actionFunc},get backAction(){return backAction}}});var _hoisted_1$207={class:`cart-main`},_hoisted_2$167={class:`cart-list`,"bng-nav-scroll":``},_hoisted_3$146={key:0,class:`extra-info-text`},_hoisted_4$121={key:0},_hoisted_5$106={key:1},_hoisted_6$89={class:`cart-row cart-subtotal`},_hoisted_7$77={class:`cart-row cart-tax`},_hoisted_8$63={class:`cart-row cart-total`},_sfc_main$234={__name:`ShoppingCart`,props:{cartData:Object,playerMoney:Number,apply:Function,cancel:Function,confirmButtonText:String},setup(__props){let props=__props,{units}=useBridge(),expanded=ref(!1),subtotal=computed(()=>props.cartData&&props.cartData.total&&props.cartData.taxes?props.cartData.total-props.cartData.taxes:0),salesTax=computed(()=>props.cartData&&props.cartData.taxes?props.cartData.taxes:0);return(_ctx,_cache)=>(openBlock(),createBlock(unref(bngCard_default),{class:normalizeClass([`cart`,{expanded:expanded.value}])},{buttons:withCtx(()=>[withDirectives((openBlock(),createBlock(unref(bngButton_default),{"show-hold":``,disabled:!__props.apply||!__props.cartData||__props.cartData.items.length===0||__props.cartData.total>0&&__props.cartData.total>__props.playerMoney},{default:withCtx(()=>[createTextVNode(toDisplayString(__props.confirmButtonText||`Purchase`),1)]),_:1},8,[`disabled`])),[[unref(BngOnUiNav_default),void 0,`ok`,{asMouse:!0,focusRequired:!0}],[unref(BngClick_default),{holdCallback:__props.apply,holdDelay:1e3,repeatInterval:0}]]),createVNode(unref(bngButton_default),{disabled:!__props.cancel,onClick:_cache[1]||=$event=>props.cancel(),accent:unref(ACCENTS).secondary},{default:withCtx(()=>[..._cache[10]||=[createTextVNode(` Cancel `,-1)]]),_:1},8,[`disabled`,`accent`])]),default:withCtx(()=>[createVNode(unref(bngCardHeading_default),null,{default:withCtx(()=>[..._cache[2]||=[createTextVNode(` Shopping Cart `,-1)]]),_:1}),createVNode(unref(bngButton_default),{class:`cart-expand`,accent:unref(ACCENTS).outlined,icon:expanded.value?unref(icons).arrowLargeDown:unref(icons).arrowLargeUp,onClick:_cache[0]||=$event=>expanded.value=!expanded.value},null,8,[`accent`,`icon`]),createBaseVNode(`div`,_hoisted_1$207,[_cache[9]||=createBaseVNode(`div`,{class:`cart-row cart-header`},[createBaseVNode(`div`),createBaseVNode(`div`,null,`Part`),createBaseVNode(`div`,null,`Price`)],-1),createBaseVNode(`div`,_hoisted_2$167,[__props.cartData?(openBlock(!0),createElementBlock(Fragment,{key:0},renderList(__props.cartData.items,item=>(openBlock(),createElementBlock(`div`,{class:normalizeClass([`cart-row`,item.type?[`type-${item.type}`]:null])},[createBaseVNode(`div`,null,[item.removeShow?(openBlock(),createBlock(unref(bngButton_default),{key:0,accent:`attention`,icon:unref(icons).abandon,disabled:item.removeDisabled,onClick:$event=>item.remove()},null,8,[`icon`,`disabled`,`onClick`])):createCommentVNode(``,!0)]),createBaseVNode(`div`,{style:normalizeStyle({paddingLeft:item.level?`${item.level-1}em`:void 0})},[createTextVNode(toDisplayString(item.name)+` `,1),item.extraInfo?(openBlock(),createElementBlock(`div`,_hoisted_3$146,toDisplayString(item.extraInfo),1)):createCommentVNode(``,!0)],4),item.priceHide?(openBlock(),createElementBlock(`div`,_hoisted_5$106)):(openBlock(),createElementBlock(`div`,_hoisted_4$121,toDisplayString(unref(units).beamBucks(item.price)),1))],2))),256)):createCommentVNode(``,!0),createBaseVNode(`div`,_hoisted_6$89,[_cache[3]||=createBaseVNode(`div`,null,null,-1),_cache[4]||=createBaseVNode(`div`,null,`Subtotal`,-1),createBaseVNode(`div`,null,toDisplayString(unref(units).beamBucks(subtotal.value)),1)]),createBaseVNode(`div`,_hoisted_7$77,[_cache[5]||=createBaseVNode(`div`,null,null,-1),_cache[6]||=createBaseVNode(`div`,null,`Sales Tax (7%)`,-1),createBaseVNode(`div`,null,toDisplayString(unref(units).beamBucks(salesTax.value)),1)])]),createBaseVNode(`div`,_hoisted_8$63,[_cache[7]||=createBaseVNode(`div`,null,null,-1),_cache[8]||=createBaseVNode(`div`,null,`Total`,-1),createBaseVNode(`div`,null,[createVNode(unref(bngUnit_default),{money:__props.cartData?__props.cartData.total:0},null,8,[`money`])])])])]),_:1},8,[`class`]))}},ShoppingCart_default=__plugin_vue_export_helper_default(_sfc_main$234,[[`__scopeId`,`data-v-e9392f36`]]),_hoisted_1$206={class:`parts-wrapper`},_hoisted_2$166={key:2,class:`parts-list`},_hoisted_3$145={class:`part-info-col`},_hoisted_4$120={class:`part-name`},_hoisted_5$105={key:0},_hoisted_6$88={key:1},_hoisted_7$76={key:2},_hoisted_8$62={class:`part-info-row`},_hoisted_9$56={key:0,class:`mileage-text`},_hoisted_10$47={key:1},_hoisted_11$42={key:2,class:`disabled-reason`},_hoisted_12$31={key:3,class:`right`},_hoisted_13$27={key:0},_sfc_main$233={__name:`PartsList`,setup(__props){let partShoppingStore=usePartShoppingStore(),{units}=useBridge(),oldBack,isPartInShoppingCart=part=>{if(!partShoppingStore.partShoppingData||!partShoppingStore.partShoppingData.shoppingCart)return!1;let partList=partShoppingStore.partShoppingData.shoppingCart.partsInList;for(let i=0;i{oldBack=partShoppingStore.backAction,partShoppingStore.backAction=()=>partShoppingStore.setSlot(``)}),onUnmounted(()=>{partShoppingStore.backAction=oldBack}),(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$206,[unref(partShoppingStore).category===`cargo`?(openBlock(),createBlock(unref(bngCardHeading_default),{key:0},{default:withCtx(()=>[..._cache[0]||=[createTextVNode(` Cargo `,-1)]]),_:1})):unref(partShoppingStore).filteredParts[0]?(openBlock(),createBlock(unref(bngCardHeading_default),{key:1},{default:withCtx(()=>[createTextVNode(toDisplayString(unref(partShoppingStore).partShoppingData.slotsNiceName[unref(partShoppingStore).filteredParts[0].containingSlot]),1)]),_:1})):createCommentVNode(``,!0),unref(partShoppingStore).filteredParts?(openBlock(),createElementBlock(`div`,_hoisted_2$166,[(openBlock(!0),createElementBlock(Fragment,null,renderList(unref(partShoppingStore).filteredParts,part=>(openBlock(),createElementBlock(`div`,{class:normalizeClass([`part-item`,{"part-installed":unref(partShoppingStore).partShoppingData.vehicleSlotToPartMap[part.containingSlot]&&unref(partShoppingStore).partShoppingData.vehicleSlotToPartMap[part.containingSlot].description.description===part.description.description,disabled:part.disabled}])},[createBaseVNode(`div`,_hoisted_3$145,[createBaseVNode(`div`,null,[createBaseVNode(`span`,_hoisted_4$120,[part.partId?(openBlock(),createElementBlock(`div`,_hoisted_5$105,toDisplayString(part.description.description)+` (Inventory) `,1)):part.emptyPlaceholder?(openBlock(),createElementBlock(`div`,_hoisted_6$88,` Remove current part `)):(openBlock(),createElementBlock(`div`,_hoisted_7$76,toDisplayString(part.description.description),1))])]),createBaseVNode(`div`,_hoisted_8$62,[part.partId?(openBlock(),createElementBlock(`span`,_hoisted_9$56,` Mileage: `+toDisplayString(unref(units).buildString(`length`,part.partCondition.odometer,0)),1)):createCommentVNode(``,!0),unref(partShoppingStore).category===`cargo`?(openBlock(),createElementBlock(`span`,_hoisted_10$47,toDisplayString(unref(partShoppingStore).partShoppingData.slotsNiceName[part.containingSlot]),1)):createCommentVNode(``,!0),part.disabled&&part.disabledReason?(openBlock(),createElementBlock(`span`,_hoisted_11$42,toDisplayString(part.disabledReason),1)):createCommentVNode(``,!0),!part.partId&&!part.emptyPlaceholder?(openBlock(),createElementBlock(`span`,_hoisted_12$31,[createVNode(unref(bngPropVal_default),{iconType:unref(icons).beamCurrency,valueLabel:unref(units).beamBucks(part.finalValue)},null,8,[`iconType`,`valueLabel`])])):createCommentVNode(``,!0)])]),createVNode(unref(bngButton_default),{accent:isPartInShoppingCart(part)?unref(ACCENTS).attention:unref(ACCENTS).outlined,class:`part-button`,disabled:part.disabled||unref(partShoppingStore).partShoppingData.tutorialPartNames!==void 0&&(!unref(partShoppingStore).partShoppingData.tutorialPartNames[part.name]||isPartInShoppingCart(part)),onClick:$event=>isPartInShoppingCart(part)?unref(Lua_default).career_modules_partShopping.removePartBySlot(part.containingSlot):unref(Lua_default).career_modules_partShopping.installPartByPartShopId(part.partShopId),icon:isPartInShoppingCart(part)?unref(icons).undo:``},{default:withCtx(()=>[isPartInShoppingCart(part)?createCommentVNode(``,!0):(openBlock(),createElementBlock(`div`,_hoisted_13$27,toDisplayString(part.emptyPlaceholder?`Remove`:`Install`),1))]),_:2},1032,[`accent`,`disabled`,`onClick`,`icon`])],2))),256))])):createCommentVNode(``,!0)]))}},PartsList_default=__plugin_vue_export_helper_default(_sfc_main$233,[[`__scopeId`,`data-v-c224fcea`]]),_hoisted_1$205={key:0,class:`highlighted`},_hoisted_2$165={key:1,class:`slot-path`},_hoisted_3$144={class:`buy-button-label`},_sfc_main$232={__name:`SlotItem`,props:{static:Boolean,expanded:Boolean,path:String,nicePath:String,slotNiceName:String,partNiceName:String},setup(__props){let slotItem=ref(),focused$1=ref(!1),props=__props;onMounted(()=>{partShoppingStore.slotToScrollTo&&props.path===partShoppingStore.slotToScrollTo&&slotItem.value.scrollIntoView({block:`center`})});let partShoppingStore=usePartShoppingStore(),itemExpanded=val=>{partShoppingStore.setSlotExpanded(props.path,val)},onFocus=val=>{focused$1.value=!0},onUnfocus=val=>{focused$1.value=!1},selectSlot=val=>{partShoppingStore.setSlot(props.path)};return(_ctx,_cache)=>(openBlock(),createBlock(unref(accordionItem_default),{static:__props.static,expanded:__props.expanded,onExpanded:itemExpanded,onFocus,onUnfocus,onSelected:selectSlot,navigable:``,"primary-action":()=>unref(partShoppingStore).setSlot(__props.path),"expand-hint-inline":``,"primary-hint-inline":``},{caption:withCtx(()=>[unref(partShoppingStore).slotToScrollTo===__props.path?(openBlock(),createElementBlock(`div`,_hoisted_1$205)):createCommentVNode(``,!0),__props.nicePath?(openBlock(),createElementBlock(`span`,_hoisted_2$165,toDisplayString(__props.nicePath),1)):createCommentVNode(``,!0),createBaseVNode(`span`,{ref_key:`slotItem`,ref:slotItem,class:`slot-name`},toDisplayString(__props.slotNiceName),513)]),controls:withCtx(()=>[withDirectives((openBlock(),createBlock(unref(bngButton_default),{"bng-no-nav":`true`,class:`buy-button`,accent:unref(ACCENTS).outlined,onClick:_cache[0]||=$event=>unref(partShoppingStore).setSlot(__props.path),style:normalizeStyle({backgroundColor:unref(partShoppingStore).slotToScrollTo&&unref(partShoppingStore).slotToScrollTo==__props.path?`rgba(75,75,75,0.8)`:``})},{default:withCtx(()=>[createBaseVNode(`span`,_hoisted_3$144,toDisplayString(__props.partNiceName?__props.partNiceName:`-`),1)]),_:1},8,[`accent`,`style`])),[[unref(BngTooltip_default),__props.partNiceName,`top`]])]),default:withCtx(()=>[renderSlot(_ctx.$slots,`default`,{},void 0,!0)]),_:3},8,[`static`,`expanded`,`primary-action`]))}},SlotItem_default=__plugin_vue_export_helper_default(_sfc_main$232,[[`__scopeId`,`data-v-3223c56d`]]),_sfc_main$231={__name:`PartSubTree`,props:{children:Object},setup(__props){let slotItemRefs=ref([]),partShoppingStore=usePartShoppingStore();return(_ctx,_cache)=>(openBlock(),createBlock(unref(accordion_default),null,{default:withCtx(()=>[(openBlock(!0),createElementBlock(Fragment,null,renderList(__props.children,childSlot=>(openBlock(),createBlock(SlotItem_default,{ref_for:!0,ref_key:`slotItemRefs`,ref:slotItemRefs,static:!childSlot.chosenPartName||!childSlot.children||Object.keys(childSlot.children).length===0,expanded:unref(partShoppingStore).expandedSlots[childSlot.path],path:childSlot.path,slotNiceName:childSlot.slotNiceName,partNiceName:childSlot.chosenPartNiceName},{default:withCtx(()=>[childSlot.children&&Object.keys(childSlot.children).length>0?(openBlock(),createBlock(PartSubTree_default,{key:0,children:childSlot.children},null,8,[`children`])):createCommentVNode(``,!0)]),_:2},1032,[`static`,`expanded`,`path`,`slotNiceName`,`partNiceName`]))),256))]),_:1}))}},PartSubTree_default=_sfc_main$231,_hoisted_1$204={class:`innerList`},_sfc_main$230={__name:`SlotList`,props:{cancel:Function},setup(__props){let partShoppingStore=usePartShoppingStore(),props=__props,searchValue=ref(``),searchValueChanged=()=>{partShoppingStore.searchValueChanged(searchValue.value)};return onMounted(()=>{partShoppingStore.backAction,partShoppingStore.backAction=()=>partShoppingStore.setCategory(``)}),onUnmounted(()=>{partShoppingStore.backAction=()=>props.cancel()}),(_ctx,_cache)=>unref(partShoppingStore).slot===``?(openBlock(),createElementBlock(Fragment,{key:1},[createVNode(unref(bngInput_default),{"floating-label":`Search`,"leading-icon":unref(icons).search,modelValue:searchValue.value,"onUpdate:modelValue":_cache[0]||=$event=>searchValue.value=$event,modelModifiers:{trim:!0},onValueChanged:searchValueChanged},null,8,[`leading-icon`,`modelValue`]),createBaseVNode(`div`,_hoisted_1$204,[searchValue.value.length>0?(openBlock(),createBlock(unref(accordion_default),{key:0,class:`slot-flat-view`},{default:withCtx(()=>[(openBlock(!0),createElementBlock(Fragment,null,renderList(unref(partShoppingStore).filteredSlots,slotInfo=>(openBlock(),createBlock(SlotItem_default,{static:!0,path:slotInfo.path,nicePath:slotInfo.nicePath,slotNiceName:slotInfo.slotNiceName,partNiceName:slotInfo.partNiceName?slotInfo.partNiceName:null},null,8,[`path`,`nicePath`,`slotNiceName`,`partNiceName`]))),256))]),_:1})):unref(partShoppingStore).partShoppingData.partTree.children?(openBlock(),createBlock(PartSubTree_default,{key:1,class:`slot-tree-view`,children:unref(partShoppingStore).partShoppingData.partTree.children},null,8,[`children`])):createCommentVNode(``,!0)])],64)):(openBlock(),createBlock(PartsList_default,{key:0}))}},SlotList_default=__plugin_vue_export_helper_default(_sfc_main$230,[[`__scopeId`,`data-v-f602b7c1`]]),_hoisted_1$203={key:0,class:`mainCategories`},_hoisted_2$164=[`disabled`],_sfc_main$229={__name:`Categories`,props:{cancel:Function},setup(__props){let partShoppingStore=usePartShoppingStore(),props=__props;return onMounted(()=>{partShoppingStore.backAction=()=>props.cancel()}),(_ctx,_cache)=>(openBlock(),createBlock(unref(bngCard_default),{class:`categoryList`},{default:withCtx(()=>[unref(partShoppingStore).category===``?(openBlock(),createElementBlock(`div`,_hoisted_1$203,[withDirectives((openBlock(),createElementBlock(`div`,{class:`computer-function-tile`,"bng-nav-item":``,tabindex:`0`,disabled:unref(partShoppingStore).partShoppingData.tutorialPartNames===void 0?void 0:!0,onClick:_cache[0]||=$event=>unref(partShoppingStore).partShoppingData.tutorialPartNames===void 0?unref(partShoppingStore).setCategory(`everything`):void 0},[createVNode(unref(bngIcon_default),{class:`icon`,type:unref(icons).doorFrontCoins},null,8,[`type`]),_cache[2]||=createBaseVNode(`span`,{class:`label`},`All Parts`,-1)],8,_hoisted_2$164)),[[unref(BngFocusIf_default),!0]]),createBaseVNode(`div`,{class:`computer-function-tile`,"bng-nav-item":``,tabindex:`0`,onClick:_cache[1]||=$event=>unref(partShoppingStore).setCategory(`cargo`)},[createVNode(unref(bngIcon_default),{class:`icon`,type:unref(icons).boxPickUp03},null,8,[`type`]),_cache[3]||=createBaseVNode(`span`,{class:`label`},`Cargo Parts`,-1)])])):(openBlock(),createBlock(SlotList_default,{key:1,cancel:props.cancel},null,8,[`cancel`]))]),_:1}))}},Categories_default=__plugin_vue_export_helper_default(_sfc_main$229,[[`__scopeId`,`data-v-70c591df`]]),CANCEL_MESSAGE$1=`Are you sure you want to cancel?
    All changes to your vehicle will be reversed`,_sfc_main$228={__name:`PartShoppingMain`,setup(__props){let{$game}=useLibStore();useComputerStore();let partShoppingStore=usePartShoppingStore(),CONFIRM_BUTTONS=[{label:$translate.instant(`ui.common.yes`),value:!0},{label:$translate.instant(`ui.common.no`),value:!1,extras:{accent:ACCENTS.secondary}}],confirmCancel=async()=>{(!partShoppingStore.partShoppingData.shoppingCart.partsInList.length||await openConfirmation(null,CANCEL_MESSAGE$1,CONFIRM_BUTTONS))&&cancelShopping()},getPartName=item=>item.description.description+(item.partId?` (Inventory)`:``),cartData=computed(()=>{let cart=partShoppingStore.partShoppingData?partShoppingStore.partShoppingData.shoppingCart:null,res={total:0,taxes:0,items:[]};return cart&&(res.total=cart.total,res.taxes=cart.taxes,Array.isArray(cart.partsInList)&&(res.items=cart.partsInList.map(item=>({name:getPartName(item),price:item.finalValue,extraInfo:item.partCondition?.odometer?`Mileage: `+$game.units.buildString(`length`,item.partCondition.odometer,0):void 0,removeShow:!!item.sourcePart,removeDisabled:!!partShoppingStore.partShoppingData.tutorialPartNames,remove:()=>Lua_default.career_modules_partShopping.removePartBySlot(item.containingSlot)})))),res}),applyShopping=()=>Lua_default.career_modules_partShopping.applyShopping(),cancelShopping=()=>Lua_default.career_modules_partShopping.cancelShopping(),start=()=>{partShoppingStore.setSlot(``),partShoppingStore.requestInitialData(),getUINavServiceInstance().setFilteredEvents(UI_EVENT_GROUPS.focusMoveScalar)},kill=()=>{partShoppingStore.cancelShopping(),getUINavServiceInstance().clearFilteredEvents(),partShoppingStore.$dispose()},close=()=>{partShoppingStore.backAction()};return onBeforeMount(start),onUnmounted(kill),(_ctx,_cache)=>(openBlock(),createBlock(ComputerWrapper_default,{path:[`Part Customization`],title:`Parts`,back:``,onBack:close},{side:withCtx(()=>[createVNode(ShoppingCart_default,{partShoppingData:unref(partShoppingStore).partShoppingData,"cart-data":cartData.value,"player-money":unref(partShoppingStore).partShoppingData.playerMoney,apply:applyShopping,cancel:confirmCancel,"confirm-button-text":`Confirm`},null,8,[`partShoppingData`,`cart-data`,`player-money`])]),default:withCtx(()=>[withDirectives(createVNode(Categories_default,{cancel:confirmCancel},null,512),[[unref(BngBlur_default),1]])]),_:1}))}},PartShoppingMain_default=__plugin_vue_export_helper_default(_sfc_main$228,[[`__scopeId`,`data-v-871a3a9f`]]),_hoisted_1$202={class:`profile-status`},_hoisted_2$163={class:`profile-status-progress`},_hoisted_3$143={class:`status-progress-item`},_hoisted_4$119={class:`status-progress-item`},_hoisted_5$104={class:`status-progress-item`},_hoisted_6$87={key:0,class:`profile-status-levels`},_hoisted_7$75={class:`profile-status-level`},_hoisted_8$61={class:`branch-icon-assembly`},_hoisted_9$55={class:`level-content-wrapper`},_sfc_main$227={__name:`ProfileStatus`,props:{beamXP:{type:Object,required:!0},vouchers:{type:Object,required:!0},money:{type:Object,required:!0},insuranceScore:{type:Object,required:!0},branches:{type:Array,required:!0},expanded:Boolean},setup(__props){let props=__props,formatterFn=num=>shrinkNum(num,1),moneyFormatter=computed(()=>props.money&&props.money>1e5?formatterFn:void 0);computed(()=>props.beamXP&&props.beamXP>1e5?formatterFn:void 0);let vouchersFormatter=computed(()=>props.vouchers&&props.vouchers>1e5?formatterFn:void 0);function getBranchStyle(color){return getIconBackgroundStyle(color)}return(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$202,[createBaseVNode(`div`,_hoisted_2$163,[createBaseVNode(`div`,_hoisted_3$143,[createVNode(unref(bngUnit_default),{insuranceScore:__props.insuranceScore?.value||0},null,8,[`insuranceScore`])]),createVNode(unref(bngDivider_default)),createBaseVNode(`div`,_hoisted_4$119,[createVNode(unref(bngUnit_default),{vouchers:__props.vouchers?.value||0,formatter:vouchersFormatter.value},null,8,[`vouchers`,`formatter`])]),createVNode(unref(bngDivider_default)),createBaseVNode(`div`,_hoisted_5$104,[createVNode(unref(bngUnit_default),{money:__props.money?.value||0,formatter:moneyFormatter.value},null,8,[`money`,`formatter`])])]),createVNode(Transition,{name:`expand-height`},{default:withCtx(()=>[__props.branches?withDirectives((openBlock(),createElementBlock(`div`,_hoisted_6$87,[(openBlock(!0),createElementBlock(Fragment,null,renderList(__props.branches,branch=>(openBlock(),createElementBlock(`div`,_hoisted_7$75,[createBaseVNode(`div`,_hoisted_8$61,[createBaseVNode(`div`,{class:`branch-background`,style:normalizeStyle(getBranchStyle(branch.color))},null,4),createVNode(unref(bngIcon_default),{type:branch.icon,class:`assembly-icon`},null,8,[`type`])]),createBaseVNode(`div`,_hoisted_9$55,[createVNode(unref(bngProgressBar_default),{class:`slim`,value:branch.curLvlProgress,min:0,max:branch.neededForNext,headerLeft:_ctx.$ctx_t(branch.label),headerRight:`${_ctx.$ctx_t(branch.levelLabel)} `,valueColor:`white`,showValueLabel:!1},null,8,[`value`,`max`,`headerLeft`,`headerRight`])])]))),256))],512)),[[vShow,__props.expanded]]):createCommentVNode(``,!0)]),_:1})]))}},ProfileStatus_default=__plugin_vue_export_helper_default(_sfc_main$227,[[`__scopeId`,`data-v-26c35504`]]),_hoisted_1$201={style:{position:`absolute`,left:`0`,right:`0`,top:`0`,bottom:`0`,background:`rgba(0,0,0,0.5)`}},_sfc_main$226={__name:`PauseMapPreview`,setup(__props){let levelTitle=ref(``),levelImage=ref(``);function setup$3(data){levelTitle.value=$translate.contextTranslate(data.title,!0),levelImage.value=data.previews[0]}let start=()=>{Lua_default.career_modules_uiUtils.getCareerCurrentLevelName().then(setup$3)};function goToBigMap(){Lua_default.freeroam_bigMapMode.enterBigMap()}return onMounted(start),(_ctx,_cache)=>{let _directive_bng_sound_class=resolveDirective(`bng-sound-class`);return withDirectives((openBlock(),createBlock(unref(aspectRatio_default),{"external-image":`/levels/west_coast_usa/spawns_quarry.jpg`,ratio:`4:3`,onClick:_cache[1]||=$event=>goToBigMap()},{default:withCtx(()=>[createBaseVNode(`div`,_hoisted_1$201,[createVNode(unref(bngCardHeading_default),{style:{color:`white`},type:`ribbon`},{default:withCtx(()=>[createTextVNode(toDisplayString(levelTitle.value),1)]),_:1}),createVNode(unref(bngButton_default),{style:{position:`absolute`,bottom:`1em`,right:`1em`},tabindex:`1`,accent:unref(ACCENTS).text,onClick:_cache[0]||=$event=>goToBigMap()},{default:withCtx(()=>[..._cache[2]||=[createTextVNode(`Open Map`,-1)]]),_:1},8,[`accent`])])]),_:1})),[[_directive_bng_sound_class,`bng_click_generic`]])}}},PauseMapPreview_default=__plugin_vue_export_helper_default(_sfc_main$226,[[`__scopeId`,`data-v-5a91faef`]]),_hoisted_1$200={class:`content-wrapper`},_hoisted_2$162={class:`cards-container`},_sfc_main$225={__name:`PauseMilestonesPreview`,setup(__props){let milestones=ref([]);function setup$3(data){milestones.value=data.list}let start=()=>{Lua_default.career_modules_milestones_milestones.getMilestones().then(setup$3)};function goToMilestones(){window.bngVue.gotoGameState(`milestones`)}return onMounted(start),(_ctx,_cache)=>{let _directive_bng_sound_class=resolveDirective(`bng-sound-class`);return withDirectives((openBlock(),createBlock(unref(aspectRatio_default),{onClick:_cache[1]||=$event=>goToMilestones(),ratio:`4:3`},{default:withCtx(()=>[createBaseVNode(`div`,_hoisted_1$200,[createVNode(unref(bngCardHeading_default),{style:{color:`white`},type:`ribbon`},{default:withCtx(()=>[..._cache[2]||=[createTextVNode(`Recent Milestones`,-1)]]),_:1}),createBaseVNode(`div`,_hoisted_2$162,[(openBlock(!0),createElementBlock(Fragment,null,renderList(milestones.value.slice(0,5),entry=>(openBlock(),createBlock(MilestoneCard_default,{milestone:entry,isCondensed:!0},null,8,[`milestone`]))),256))]),createVNode(unref(bngButton_default),{style:{position:`absolute`,bottom:`1em`,right:`1em`},tabindex:`1`,accent:unref(ACCENTS).text,onClick:_cache[0]||=$event=>goToMilestones()},{default:withCtx(()=>[..._cache[3]||=[createTextVNode(`Go to Milestones`,-1)]]),_:1},8,[`accent`])])]),_:1})),[[_directive_bng_sound_class,`bng_click_generic`]])}}},PauseMilestonesPreview_default=__plugin_vue_export_helper_default(_sfc_main$225,[[`__scopeId`,`data-v-7fcfd236`]]),_hoisted_1$199={class:`pause-body-wrapper`},_hoisted_2$161={class:`heading-container`},_hoisted_3$142={class:`buttons-and-status`},_hoisted_4$118={key:0,class:`indicator`},_hoisted_5$103={class:`save-load-row`},_hoisted_6$86={class:`status-container`},_hoisted_7$74={key:2,class:`vehicle-name`},_sfc_main$224={__name:`Pause`,setup(__props){useUINavScope(`pause`),ref({value:0,label:`Map`,type:`Map`}.type),ref(null),ref(.5);let contextButtons=ref({});function setupContextButtons(data){contextButtons.value=data.buttons}Lua_default.career_modules_uiUtils.getCareerPauseContextButtons().then(setupContextButtons);function onContextButtonClicked(btn){Lua_default.career_modules_uiUtils.callCareerPauseContextButtons(btn.functionId)}function onSaveButtonClicked(){Lua_default.career_saveSystem.saveCurrent(),exit()}async function onLoadButtonClicked(){await openConfirmation(`Load Profile`,`Are you sure you want to load a different profile? Any unsaved progress will be lost.`)&&window.bngVue.gotoGameState(`profiles`)}let exit=()=>window.bngVue.gotoGameState(`play`),saveSlotData=ref(null),currentVehicleName=ref(``);function makeVehicleName(data){return!data||data.key===`unicycle`?`Walking`:data.niceName}return onMounted(async()=>{let data=await Lua_default.career_career.sendCurrentSaveSlotData();saveSlotData.value=data,currentVehicleName.value=makeVehicleName(data.currentVehicle)}),onBeforeMount(()=>{Lua_default.simTimeAuthority.pushPauseRequest(`careerPause`)}),onUnmounted(()=>{Lua_default.simTimeAuthority.popPauseRequest(`careerPause`)}),(_ctx,_cache)=>withDirectives((openBlock(),createBlock(unref(layoutSingle_default),{class:`career-pause-layout`,"bng-ui-scope":`pause`},{default:withCtx(()=>[createBaseVNode(`div`,_hoisted_1$199,[createBaseVNode(`div`,_hoisted_2$161,[createVNode(unref(bngCardHeading_default),{class:`pause-heading`,type:`ribbon`},{default:withCtx(()=>[..._cache[0]||=[createTextVNode(`Career: Paused`,-1)]]),_:1})]),createBaseVNode(`div`,_hoisted_3$142,[createVNode(unref(bngCard_default),{class:`system-buttons`},{default:withCtx(()=>[createVNode(unref(bngButton_default),{class:`button`,tabindex:`1`,accent:unref(ACCENTS).text,onClick:exit},{default:withCtx(()=>[..._cache[1]||=[createTextVNode(`Resume`,-1)]]),_:1},8,[`accent`]),contextButtons.value.length>0?(openBlock(!0),createElementBlock(Fragment,{key:0},renderList(contextButtons.value,btn=>(openBlock(),createBlock(unref(bngButton_default),{class:`button`,tabindex:`1`,accent:unref(ACCENTS).text,onClick:$event=>onContextButtonClicked(btn)},{default:withCtx(()=>[createTextVNode(toDisplayString(_ctx.$ctx_t(btn.label))+` `,1),btn.showIndicator?(openBlock(),createElementBlock(`div`,_hoisted_4$118)):createCommentVNode(``,!0)]),_:2},1032,[`accent`,`onClick`]))),256)):createCommentVNode(``,!0),createBaseVNode(`div`,_hoisted_5$103,[createVNode(unref(bngButton_default),{class:`button`,tabindex:`1`,accent:unref(ACCENTS).text,onClick:onSaveButtonClicked},{default:withCtx(()=>[..._cache[2]||=[createTextVNode(`Save`,-1)]]),_:1},8,[`accent`]),createVNode(unref(bngButton_default),{class:`button`,tabindex:`1`,accent:unref(ACCENTS).text,onClick:onLoadButtonClicked},{default:withCtx(()=>[..._cache[3]||=[createTextVNode(`Load`,-1)]]),_:1},8,[`accent`])])]),_:1}),createBaseVNode(`div`,_hoisted_6$86,[saveSlotData.value?(openBlock(),createBlock(unref(bngCardHeading_default),{key:0,class:`profile-name`,type:`ribbon`},{default:withCtx(()=>[createTextVNode(toDisplayString(saveSlotData.value.id),1)]),_:1})):createCommentVNode(``,!0),saveSlotData.value?(openBlock(),createBlock(ProfileStatus_default,{key:1,class:`pause-profile-status`,expanded:!0,beamXP:saveSlotData.value.beamXP,vouchers:saveSlotData.value.vouchers,money:saveSlotData.value.money,insuranceScore:saveSlotData.value.insuranceScore,branches:saveSlotData.value.branches},null,8,[`beamXP`,`vouchers`,`money`,`insuranceScore`,`branches`])):createCommentVNode(``,!0),saveSlotData.value?(openBlock(),createElementBlock(`div`,_hoisted_7$74,[createVNode(unref(bngIcon_default),{type:unref(icons).car},null,8,[`type`]),createTextVNode(` `+toDisplayString(currentVehicleName.value),1)])):createCommentVNode(``,!0)])])])]),_:1})),[[unref(BngOnUiNav_default),exit,`menu,back`],[unref(BngBlur_default),!0]])}},Pause_default=__plugin_vue_export_helper_default(_sfc_main$224,[[`__scopeId`,`data-v-c6f22d14`]]),_hoisted_1$198={class:`career-pause-wrapper`},_hoisted_2$160={class:`layout-center-wrapper`},_hoisted_3$141={class:`pause-body-wrapper`},_hoisted_4$117={class:`left-content`},_hoisted_5$102={class:`tabs-group`},_hoisted_6$85={class:`tab-content`},_hoisted_7$73={style:{position:`absolute`,left:`0`,right:`0`,top:`0`,bottom:`0`,background:`rgba(0, 0, 0, 0.5)`}},_hoisted_8$60={class:`right-content`},_hoisted_9$54={class:`bottom-content`},ICON_RATIO=`2.25:1`,_sfc_main$223={__name:`PauseBigMiddlePanel`,setup(__props){useUINavScope(`pause`);let MIDDLE_PILL_OPTIONS=[{value:0,label:`Map`,type:`Map`},{value:1,label:`Milestones`,type:`Milestones`},{value:2,label:`Engine`},{value:3,label:`Transmission`},{value:4,label:`Suspension`},{value:5,label:`Electrics`},{value:6,label:`Electrics1`},{value:7,label:`Electrics2`},{value:8,label:`Electrics3`}],currentPillTypeSelected=ref(MIDDLE_PILL_OPTIONS[0].type),middlePillsContainerRef=ref(null);function onMiddlePillsSelectPrevious(){middlePillsContainerRef.value.selectPrevious()}function onMiddlePillsSelectNext(){middlePillsContainerRef.value.selectNext()}function middlePillsValueChanged(selectedValues){let pillId=selectedValues[0],selectedPill=MIDDLE_PILL_OPTIONS.find(pill=>pill.value===pillId);console.log(selectedPill),currentPillTypeSelected.value=selectedPill.type}let todSliderValue=ref(.5),onTODChanged=v=>{console.log(v)},contextButtons=ref({});function setupContextButtons(data){console.log(data),contextButtons.value=data.buttons}Lua_default.career_modules_uiUtils.getCareerPauseContextButtons().then(setupContextButtons);function onContextButtonClicked(btn){console.log(btn),Lua_default.career_modules_uiUtils.callCareerPauseContextButtons(btn.functionId)}function onExitCareerButtonClicked(){console.log(`onExitCareerButtonClicked`)}function onSaveButtonClicked(){career_saveSystem.saveCurrent()}function onLoadButtonClicked(){console.log(`onLoadButtonClicked`)}function onSettingsButtonClicked(){console.log(`onSettingsButtonClicked`)}return(_ctx,_cache)=>withDirectives((openBlock(),createElementBlock(`div`,_hoisted_1$198,[createVNode(unref(careerSimpleStats_default)),createBaseVNode(`div`,_hoisted_2$160,[createBaseVNode(`div`,_hoisted_3$141,[createVNode(unref(careerStatus_default),{class:`pause-profile-status`}),createBaseVNode(`div`,_hoisted_4$117,[createVNode(unref(bngImageTile_default),{label:`Exit Career`,icon:unref(icons).abandon,onClick:onExitCareerButtonClicked,ratio:ICON_RATIO},null,8,[`icon`]),createVNode(unref(bngCard_default),{class:`system-buttons`},{default:withCtx(()=>[createVNode(unref(bngButton_default),{tabindex:`1`,accent:unref(ACCENTS).text,onClick:onSaveButtonClicked},{default:withCtx(()=>[..._cache[1]||=[createTextVNode(`Save`,-1)]]),_:1},8,[`accent`]),createVNode(unref(bngButton_default),{tabindex:`1`,accent:unref(ACCENTS).text,onClick:onLoadButtonClicked},{default:withCtx(()=>[..._cache[2]||=[createTextVNode(`Load`,-1)]]),_:1},8,[`accent`]),createVNode(unref(bngButton_default),{tabindex:`1`,accent:unref(ACCENTS).text,onClick:onSettingsButtonClicked},{default:withCtx(()=>[..._cache[3]||=[createTextVNode(`Settings`,-1)]]),_:1},8,[`accent`])]),_:1})]),createVNode(unref(bngCard_default),{class:`main-content grid`},{default:withCtx(()=>[createBaseVNode(`div`,_hoisted_5$102,[createVNode(unref(bngButton_default),{class:`button prev-button`,onClick:onMiddlePillsSelectPrevious,tabindex:`0`,accent:unref(ACCENTS).text},{default:withCtx(()=>[..._cache[4]||=[createTextVNode(`Previous`,-1)]]),_:1},8,[`accent`]),createVNode(unref(bngPillFiltersContainer_default),{class:`tabs-track`,ref_key:`middlePillsContainerRef`,ref:middlePillsContainerRef,"html-id":`middle-pills-container-ref`,options:MIDDLE_PILL_OPTIONS,"select-on-navigation":!1,onValueChanged:middlePillsValueChanged,required:!0,"has-checked-icon":!1},null,512),createVNode(unref(bngButton_default),{class:`button next-button`,onClick:onMiddlePillsSelectNext,tabindex:`0`,accent:unref(ACCENTS).text},{default:withCtx(()=>[..._cache[5]||=[createTextVNode(`Next`,-1)]]),_:1},8,[`accent`])]),createBaseVNode(`div`,_hoisted_6$85,[currentPillTypeSelected.value==`Map`?(openBlock(),createBlock(PauseMapPreview_default,{key:0})):createCommentVNode(``,!0),currentPillTypeSelected.value==`Milestones`?(openBlock(),createBlock(PauseMilestonesPreview_default,{key:1})):createCommentVNode(``,!0),currentPillTypeSelected.value===void 0?withDirectives((openBlock(),createBlock(unref(aspectRatio_default),{key:2,style:{background:`red`},ratio:`4:3`},{default:withCtx(()=>[createBaseVNode(`div`,_hoisted_7$73,[createVNode(unref(bngCardHeading_default),{style:{color:`white`},type:`ribbon`},{default:withCtx(()=>[..._cache[6]||=[createTextVNode(`Undefined Pill Type!`,-1)]]),_:1})])]),_:1})),[[unref(BngSoundClass_default),`bng_click_generic`]]):createCommentVNode(``,!0)])]),_:1}),createBaseVNode(`div`,_hoisted_8$60,[(openBlock(!0),createElementBlock(Fragment,null,renderList(contextButtons.value,btn=>(openBlock(),createBlock(unref(bngImageTile_default),{label:btn.label,icon:unref(icons)[btn.icon],onClick:$event=>onContextButtonClicked(btn),ratio:ICON_RATIO},null,8,[`label`,`icon`,`onClick`]))),256))]),createBaseVNode(`div`,_hoisted_9$54,[createVNode(unref(bngImageTile_default),{class:`photo-mode`,label:`Photo Mode`,icon:unref(icons).photo,ratio:ICON_RATIO},null,8,[`icon`]),createVNode(unref(bngCard_default),{class:`tod`},{default:withCtx(()=>[_cache[7]||=createBaseVNode(`div`,{class:`icon-box`},`I'm an icon box!`,-1),createVNode(unref(bngSlider_default),{ref:`iptChanged`,min:0,max:1,step:.1,modelValue:todSliderValue.value,"onUpdate:modelValue":_cache[0]||=$event=>todSliderValue.value=$event,onValueChanged:onTODChanged},null,8,[`modelValue`]),createVNode(unref(bngInput_default),{class:`tod-value`})]),_:1})])])]),_cache[8]||=createBaseVNode(`div`,{style:{background:`green`,height:`5em`}},`FOOTER`,-1)])),[[unref(BngBlur_default)]])}},PauseBigMiddlePanel_default=__plugin_vue_export_helper_default(_sfc_main$223,[[`__scopeId`,`data-v-7b3f120b`]]),_hoisted_1$197={class:`back-text`},_sfc_main$222={__name:`BackAside`,emits:[`click`],setup(__props,{emit:__emit}){let emit$1=__emit;return(_ctx,_cache)=>withDirectives((openBlock(),createElementBlock(`div`,{class:`back-aside`,onClick:_cache[0]||=$event=>emit$1(`click`)},[createVNode(unref(bngIcon_default),{class:`back-arrow`,type:unref(icons).arrowLargeLeft},null,8,[`type`]),createBaseVNode(`span`,_hoisted_1$197,[createVNode(unref(bngBinding_default),{class:`back-binding`,"ui-event":`back`,controller:``,"track-ignore":``}),createTextVNode(` `+toDisplayString(_ctx.$tt(`ui.common.back`)),1)])])),[[unref(BngSoundClass_default),`bng_click_hover_generic`]])}},BackAside_default=__plugin_vue_export_helper_default(_sfc_main$222,[[`__scopeId`,`data-v-2fa47f3c`]]);const PROFILE_NAME_MAX_LENGTH=100,useProfilesStore=defineStore(`profiles`,()=>{async function loadProfile(profileName,tutorialEnabled,isAdd=!1){if(console.log(`profileStore.loadProfile`,profileName,tutorialEnabled,isAdd),!profileName)return console.warn(`profileStore.loadProfile: profileName is required. Not loading profile.`),!1;if(profileName.length>100&&isAdd)return console.warn(`profileStore.loadProfile: profileName is too long. Not loading profile.`),!1;console.log(`profileStore.loadProfile: creating or loading career and starting`,profileName),/^ +| +$/.test(profileName)&&(profileName=profileName.replace(/^ +| +$/g,``));let createOrLoadCareerAndStartResult=await Lua_default.career_career.createOrLoadCareerAndStart(profileName,null,tutorialEnabled);console.log(`profileStore.loadProfile: createOrLoadCareerAndStartResult`,createOrLoadCareerAndStartResult);let toastrMessage=isAdd?`added`:`loaded`;window.globalAngularRootScope.$broadcast(`toastrMsg`,{type:`info`,msg:$translate.contextTranslate(`ui.career.notification.${toastrMessage}`),config:{positionClass:`toast-top-right`,toastClass:`beamng-message-toast`,timeOut:5e3,extendedTimeOut:1e3}})}return{loadProfile}});var _hoisted_1$196={class:`profile-card-cover`},_hoisted_2$159={class:`profile-card-container`},_hoisted_3$140={class:`profile-card-title`},_hoisted_4$116={key:0,class:`profile-card-date`},_hoisted_5$101={key:0},_hoisted_6$84={key:1},_hoisted_7$72={class:`profile-card-content`},_hoisted_8$59={key:0,class:`profile-manage`},_hoisted_9$53={key:0,class:`profile-manage-rename`},_hoisted_10$46={key:1,class:`profile-manage-delete`},_hoisted_11$41={key:2,class:`profile-manage-main`},MENU_ITEMS$3={RENAME:`rename`,DELETE:`delete`},_sfc_main$221={__name:`ProfileCard`,props:{id:{type:String,required:!0},date:{type:String,required:!0},creationDate:{type:String,required:!0},incompatibleVersion:Boolean,outdatedVersion:{type:Boolean,required:!0},preview:{type:String,default:`/ui/modules/career/profilePreview_WCUSA.jpg`},beamXP:Object,vouchers:Object,vehicleCount:Number,money:Object,insuranceScore:Object,active:Boolean,branches:Array,disabled:Boolean},emits:[`card:activate`,`load`,`rename`],setup(__props,{emit:__emit}){let props=__props,emit$1=__emit,isActivated=ref(!1),isManage=ref(!1),currentMenu=ref(null),expanded=ref(!1),internalDisabled=ref(!1),cardStates=reactive({focused:!1,hovered:!1}),validateName=inject(`validateName`),nameError=ref(null),lastPlayedDescription=computed(()=>timeSpan(props.date));watch(()=>props.disabled,value=>{nextTick(()=>{internalDisabled.value=value,value&&(expanded.value=!1)})});let onScopeChanged=value=>{isActivated.value=value},cardFooterStyles$1={"background-color":`hsla(217, 22%, 12%, 1)`},validateFn=name=>{let res=validateName(name);return name===props.id&&(res=null),res?nameError.value=res:nameError.value=null,!res},canDeactivate=()=>!isManage.value,canBubbleEvent=e=>e.detail.name===`menu`&&!isManage.value;function onFocused(focused$1){cardStates.focused=focused$1,updatedExpanded()}function onHover(hover){cardStates.hovered=hover,updatedExpanded()}function updatedExpanded(){let enable=cardStates.focused||cardStates.hovered;!enable&&(isActivated.value||isManage.value)||(expanded.value=enable)}function enableManage(enable=!0){nextTick(()=>isManage.value=enable),enable&&!isActivated.value&&(isActivated.value=!0),emit$1(`card:activate`,enable)}function goBack(){if(saveName.value=props.id,currentMenu.value)currentMenu.value=null;else if(isManage.value)enableManage(!1);else return!0}let saveName=ref(props.id),deleteProfile=()=>{Lua_default.career_saveSystem.removeSaveSlot(props.id),Lua_default.career_career.sendAllCareerSaveSlotsData()},updateProfileName=()=>emit$1(`rename`,saveName.value);return(_ctx,_cache)=>withDirectives((openBlock(),createBlock(unref(bngCard_default),{backgroundImage:__props.preview,footerStyles:cardFooterStyles$1,hideFooter:!expanded.value&&!isManage.value,class:normalizeClass([{"profile-card-active":__props.active,"manage-active":isManage.value,"profile-outdated":__props.incompatibleVersion},`profile-card`]),animateFooterDelay:expanded.value?`0s`:`0.1s`,animateFooterType:`slide`,onActivate:_cache[5]||=$event=>onScopeChanged(!0),onDeactivate:_cache[6]||=$event=>onScopeChanged(!1),onFocusin:_cache[7]||=withModifiers($event=>onFocused(!0),[`self`]),onFocusout:_cache[8]||=withModifiers($event=>onFocused(!1),[`self`]),onMouseover:_cache[9]||=$event=>onHover(!0),onMouseleave:_cache[10]||=$event=>onHover(!1)},{buttons:withCtx(()=>[isManage.value?(openBlock(),createElementBlock(Fragment,{key:0},[currentMenu.value===MENU_ITEMS$3.RENAME?withDirectives((openBlock(),createBlock(unref(bngButton_default),{key:0,disabled:nameError.value!==null||saveName.value===props.id,onClick:updateProfileName},{default:withCtx(()=>[..._cache[11]||=[createTextVNode(` Save `,-1)]]),_:1},8,[`disabled`])),[[unref(BngOnUiNav_default),void 0,`ok`,{asMouse:!0,focusRequired:!0}],[unref(BngSoundClass_default),`bng_click_generic`]]):createCommentVNode(``,!0),withDirectives((openBlock(),createBlock(unref(bngButton_default),{accent:`outlined`,onClick:goBack},{default:withCtx(()=>[..._cache[12]||=[createTextVNode(` Back `,-1)]]),_:1})),[[unref(BngOnUiNav_default),void 0,`ok`,{asMouse:!0,focusRequired:!0}],[unref(BngSoundClass_default),`bng_cancel_generic`]])],64)):(openBlock(),createElementBlock(Fragment,{key:1},[withDirectives((openBlock(),createBlock(unref(bngButton_default),{accent:`outlined`,onClick:enableManage},{default:withCtx(()=>[..._cache[13]||=[createTextVNode(`Manage `,-1)]]),_:1})),[[unref(BngOnUiNav_default),void 0,`ok`,{asMouse:!0,focusRequired:!0}],[unref(BngSoundClass_default),`bng_click_generic`]]),withDirectives((openBlock(),createBlock(unref(bngButton_default),{onClick:_cache[4]||=$event=>_ctx.$emit(`load`,__props.id),disabled:__props.active||__props.incompatibleVersion},{default:withCtx(()=>[..._cache[14]||=[createTextVNode(`Load `,-1)]]),_:1},8,[`disabled`])),[[unref(BngOnUiNav_default),void 0,`ok`,{asMouse:!0,focusRequired:!0}],[unref(BngSoundClass_default),`bng_click_generic`]])],64))]),default:withCtx(()=>[createBaseVNode(`div`,_hoisted_1$196,[createBaseVNode(`div`,_hoisted_2$159,[createBaseVNode(`div`,_hoisted_3$140,toDisplayString(_ctx.$ctx_t(__props.id)),1),isManage.value?createCommentVNode(``,!0):(openBlock(),createElementBlock(`div`,_hoisted_4$116,[__props.active?(openBlock(),createElementBlock(`span`,_hoisted_5$101,toDisplayString(_ctx.$ctx_t(`ui.career.nowplaying`)),1)):(openBlock(),createElementBlock(`span`,_hoisted_6$84,toDisplayString(_ctx.$ctx_t(`ui.career.lastplayed`))+` `+toDisplayString(lastPlayedDescription.value),1))]))])]),withDirectives((openBlock(),createElementBlock(`div`,_hoisted_7$72,[isManage.value?(openBlock(),createElementBlock(`div`,_hoisted_8$59,[currentMenu.value===MENU_ITEMS$3.RENAME?(openBlock(),createElementBlock(`div`,_hoisted_9$53,[createVNode(unref(bngInput_default),{modelValue:saveName.value,"onUpdate:modelValue":_cache[0]||=$event=>saveName.value=$event,maxlength:unref(100),validate:validateFn,errorMessage:nameError.value,externalLabel:`Save Name`,onKeydown:_cache[1]||=withKeys(withModifiers(()=>{},[`prevent`]),[`enter`])},null,8,[`modelValue`,`maxlength`,`errorMessage`])])):currentMenu.value===MENU_ITEMS$3.DELETE?(openBlock(),createElementBlock(`div`,_hoisted_10$46,[createBaseVNode(`span`,null,toDisplayString(_ctx.$ctx_t(`ui.career.deletePrompt`)),1),withDirectives(createVNode(unref(bngButton_default),{label:_ctx.$ctx_t(`ui.common.yes`),accent:`attention`,onClick:deleteProfile},null,8,[`label`]),[[unref(BngOnUiNav_default),void 0,`ok`,{asMouse:!0,focusRequired:!0}],[unref(BngSoundClass_default),`bng_click_generic`]]),withDirectives(createVNode(unref(bngButton_default),{label:_ctx.$ctx_t(`ui.common.no`),accent:`secondary`,onClick:goBack},null,8,[`label`]),[[unref(BngOnUiNav_default),void 0,`ok`,{asMouse:!0,focusRequired:!0}],[unref(BngSoundClass_default),`bng_cancel_generic`]])])):(openBlock(),createElementBlock(`div`,_hoisted_11$41,[withDirectives(createVNode(unref(bngButton_default),{accent:`secondary`,label:_ctx.$ctx_t(`ui.career.rename`),disabled:__props.active,onClick:_cache[2]||=()=>currentMenu.value=MENU_ITEMS$3.RENAME},null,8,[`label`,`disabled`]),[[unref(BngOnUiNav_default),void 0,`ok`,{asMouse:!0,focusRequired:!0}],[unref(BngSoundClass_default),`bng_click_generic`]]),withDirectives(createVNode(unref(bngButton_default),{accent:`secondary`,label:_ctx.$ctx_t(`ui.career.delete`),disabled:__props.active,onClick:_cache[3]||=()=>currentMenu.value=MENU_ITEMS$3.DELETE},null,8,[`label`,`disabled`]),[[unref(BngOnUiNav_default),void 0,`ok`,{asMouse:!0,focusRequired:!0}],[unref(BngSoundClass_default),`bng_click_generic`]]),createVNode(unref(bngButton_default),{label:_ctx.$ctx_t(`ui.career.mods`),accent:`secondary`,disabled:``},null,8,[`label`]),createVNode(unref(bngButton_default),{label:_ctx.$ctx_t(`ui.career.backup`),accent:`secondary`,disabled:``},null,8,[`label`])]))])):(openBlock(),createBlock(ProfileStatus_default,{key:1,branches:__props.branches,beamXP:__props.beamXP,vouchers:__props.vouchers,vehicleCount:__props.vehicleCount,money:__props.money,insuranceScore:__props.insuranceScore},null,8,[`branches`,`beamXP`,`vouchers`,`vehicleCount`,`money`,`insuranceScore`]))])),[[unref(BngOnUiNav_default),goBack,`menu,back`]])]),_:1},8,[`backgroundImage`,`hideFooter`,`class`,`animateFooterDelay`])),[[unref(BngScopedNav_default),{canDeactivate,canBubbleEvent}],[unref(BngSoundClass_default),`bng_hover_generic`],[unref(BngDisabled_default),internalDisabled.value]])}},ProfileCard_default=__plugin_vue_export_helper_default(_sfc_main$221,[[`__scopeId`,`data-v-16215408`]]),cardFooterStyles={"background-color":`hsla(217, 22%, 12%, 1)`},_sfc_main$220={__name:`ProfileCreateCard`,props:{profileName:{required:!0},profileNameModifiers:{}},emits:mergeModels([`card:activate`,`load`],[`update:profileName`]),setup(__props,{emit:__emit}){let emit$1=__emit,profileName=useModel(__props,`profileName`),tutorialChecked=ref(!0),isActive=ref(!1),validateName=inject(`validateName`),nameError=ref(null),startButton=ref(null),cancelButton=ref(null),validateFn=name=>{let res=validateName(name);return res?nameError.value=res:nameError.value=null,!res},load=()=>emit$1(`load`,profileName.value,tutorialChecked.value);function setActive(value){isActive.value=value,emit$1(`card:activate`,value)}function onCancel(event){setTimeout(()=>{isActive.value=!1,emit$1(`card:activate`,!1)},200)}function onEnter(event){event.preventDefault();let focusButton=nameError.value?cancelButton:startButton;focusButton.value&&nextTick(()=>setFocusExternal(focusButton.value.$el))}function onMenu(){setActive(!1)}return(_ctx,_cache)=>withDirectives((openBlock(),createBlock(unref(bngCard_default),{hideFooter:!isActive.value,footerStyles:cardFooterStyles,class:`profile-create-card`,onActivate:_cache[3]||=()=>setActive(!0),onDeactivate:_cache[4]||=()=>setActive(!1)},{buttons:withCtx(()=>[withDirectives((openBlock(),createBlock(unref(bngButton_default),{ref_key:`startButton`,ref:startButton,disabled:nameError.value!==null,onClick:withModifiers(load,[`stop`])},{default:withCtx(()=>[..._cache[6]||=[createTextVNode(`Start`,-1)]]),_:1},8,[`disabled`])),[[unref(BngOnUiNav_default),void 0,`ok`,{asMouse:!0,focusRequired:!0}]]),withDirectives((openBlock(),createBlock(unref(bngButton_default),{ref_key:`cancelButton`,ref:cancelButton,accent:`outlined`,onClick:withModifiers(onCancel,[`stop`])},{default:withCtx(()=>[..._cache[7]||=[createTextVNode(`Cancel`,-1)]]),_:1})),[[unref(BngOnUiNav_default),void 0,`ok`,{asMouse:!0,focusRequired:!0}]])]),default:withCtx(()=>[withDirectives((openBlock(),createElementBlock(`div`,{class:normalizeClass([{"create-active":isActive.value},`create-content-container`])},[isActive.value?(openBlock(),createElementBlock(Fragment,{key:0},[createVNode(unref(bngInput_default),{modelValue:profileName.value,"onUpdate:modelValue":_cache[0]||=$event=>profileName.value=$event,maxlength:unref(100),validate:validateFn,errorMessage:nameError.value,externalLabel:`Save Name`,onKeydown:withKeys(onEnter,[`enter`])},null,8,[`modelValue`,`maxlength`,`errorMessage`]),createVNode(unref(bngSwitch_default),{modelValue:tutorialChecked.value,"onUpdate:modelValue":_cache[1]||=$event=>tutorialChecked.value=$event,"label-before":``,inline:!1,"label-alignment":unref(LABEL_ALIGNMENTS).START},{default:withCtx(()=>[createTextVNode(toDisplayString(_ctx.$ctx_t(`ui.career.tutorialCheckDesc`)),1)]),_:1},8,[`modelValue`,`label-alignment`]),createBaseVNode(`span`,{class:normalizeClass([`tutorial-desc`,{checked:tutorialChecked.value}])},toDisplayString(_ctx.$ctx_t(`ui.career.tutorialOnDesc`)),3)],64)):(openBlock(),createElementBlock(`div`,{key:1,"bng-nav-item":``,class:`create-content-cover`,onClick:_cache[2]||=withModifiers($event=>setActive(!0),[`stop`])},[..._cache[5]||=[createBaseVNode(`div`,{class:`cover-plus-container`},[createBaseVNode(`div`,{class:`cover-plus-button`},`+`)],-1)]]))],2)),[[unref(BngOnUiNav_default),onMenu,`menu`]])]),_:1},8,[`hideFooter`])),[[unref(BngScopedNav_default),{activated:isActive.value}],[unref(BngBlur_default)],[unref(BngSoundClass_default),`bng_hover_generic`]])}},ProfileCreateCard_default=__plugin_vue_export_helper_default(_sfc_main$220,[[`__scopeId`,`data-v-1524a2bb`]]),_sfc_main$219={__name:`Profiles`,setup(__props){let store$1=useProfilesStore(),{events:events$3}=useBridge(),profiles=ref([]),activeProfileId=ref(null),selectedCard=ref(null),newProfileName=ref(null),onLoad=async id=>{await store$1.loadProfile(id)},onRename=async(profile,newName)=>{await Lua_default.career_saveSystem.renameSaveSlot(profile.id,newName)&&(profile.id=newName)},onCreateSave=async(profileName,tutorialChecked)=>{await store$1.loadProfile(profileName,tutorialChecked,!0)};function onCardActivated(active,index){active?(selectedCard.value=index,index===-1&&(newProfileName.value=getNewName())):selectedCard.value=null}onMounted(()=>{events$3.on(`allCareerSaveSlots`,onProfilesReceived),Lua_default.career_career.sendAllCareerSaveSlotsData()}),onBeforeUnmount(()=>{events$3.off(`allCareerSaveSlots`,onProfilesReceived)}),provide(`validateName`,validateName);let navigateToMainMenu=e=>{activeProfileId.value?window.bngVue.gotoAngularState(`menu.careerPause`):window.bngVue.gotoGameState(`menu.mainmenu`)};function onDeactivate$1(event){event.detail.force||navigateToMainMenu()}async function onProfilesReceived(data){selectedCard.value=null,activeProfileId.value=null,profiles.value=[],!(!data||!Array.isArray(data)||data.length===0)&&(profiles.value=(await updateActiveProfile(data)).map(p$1=>({id:p$1.id,date:p$1.date,creationDate:p$1.creationDate,incompatibleVersion:p$1.incompatibleVersion,outdatedVersion:p$1.outdatedVersion,preview:p$1.preview,beamXP:p$1.beamXP,vouchers:p$1.vouchers,vehicleCount:p$1.vehicleCount,money:p$1.money,insuranceScore:p$1.insuranceScore,branches:p$1.branches})))}async function updateActiveProfile(data){let currentSave=await Lua_default.career_career.sendCurrentSaveSlotData();if(data.sort((a$1,b)=>new Date(b.date)-new Date(a$1.date)),currentSave){activeProfileId.value=currentSave.id;let current=data.find(x=>x.id===currentSave.id);current||=currentSave,data=data.filter(x=>x.id!==currentSave.id),data.splice(0,0,current)}return data}function validateName(newName){return newName?newName.length>100?`Save name cannot be longer than 100 characters`:/[<>:"/\\|?*]/.test(newName)?`Save name cannot contain invalid characters`:profiles.value&&profiles.value.find(profile=>profile.id.toLowerCase()===newName.toLowerCase())?`Save name already exists`:null:`Save name cannot be empty`}function getNewName(){let prefix$1=$translate.contextTranslate(`ui.career.profile`),id;for(let i=1;i<1e3&&(id=`${prefix$1} ${i}`,!(!profiles.value||!profiles.value.find(profile=>profile.id===id)));i++);return id}return onBeforeMount(()=>{Lua_default.simTimeAuthority.pushPauseRequest(`profiles`)}),onUnmounted(()=>{Lua_default.simTimeAuthority.popPauseRequest(`profiles`)}),(_ctx,_cache)=>(openBlock(),createElementBlock(Fragment,null,[withDirectives((openBlock(),createElementBlock(`div`,{class:`profiles-container`,onDeactivate:onDeactivate$1},[createVNode(unref(bngScreenHeading_default),{class:`profiles-title`,preheadings:[_ctx.$ctx_t(`ui.playmodes.career`)]},{default:withCtx(()=>[createTextVNode(toDisplayString(_ctx.$ctx_t(`ui.career.savedProgress`)),1)]),_:1},8,[`preheadings`]),withDirectives(createVNode(BackAside_default,{class:`profiles-back`,onClick:navigateToMainMenu},null,512),[[unref(BngOnUiNav_default),navigateToMainMenu,`back,menu`]]),createVNode(unref(bngList_default),{layout:unref(LIST_LAYOUTS).RIBBON,"target-width":22,"target-height":28,"target-margin":1,"no-background":``},{default:withCtx(()=>[createVNode(ProfileCreateCard_default,{profileName:newProfileName.value,"onUpdate:profileName":_cache[0]||=$event=>newProfileName.value=$event,class:`profile-card`,"onCard:activate":_cache[1]||=value=>onCardActivated(value,-1),onLoad:onCreateSave},null,8,[`profileName`]),(openBlock(!0),createElementBlock(Fragment,null,renderList(profiles.value,(profile,index)=>withDirectives((openBlock(),createBlock(ProfileCard_default,{key:index,id:profile.id,date:profile.date,creationDate:profile.creationDate,incompatibleVersion:profile.incompatibleVersion,outdatedVersion:profile.outdatedVersion,preview:profile.preview,beamXP:profile.beamXP,vouchers:profile.vouchers,vehicleCount:profile.vehicleCount,money:profile.money,insuranceScore:profile.insuranceScore,branches:profile.branches,active:activeProfileId.value===profile.id,disabled:selectedCard.value!==null&&selectedCard.value!==index,class:`profile-card`,"onCard:activate":value=>onCardActivated(value,index),onLoad,onRename:newName=>onRename(profile,newName)},null,8,[`id`,`date`,`creationDate`,`incompatibleVersion`,`outdatedVersion`,`preview`,`beamXP`,`vouchers`,`vehicleCount`,`money`,`insuranceScore`,`branches`,`active`,`disabled`,`onCard:activate`,`onRename`])),[[unref(BngPopover_default),profile.incompatibleVersion?`tooltip-outdated-message`:null,`top`]])),128))]),_:1},8,[`layout`])],32)),[[unref(BngScopedNav_default),{activateOnMount:!0}]]),createVNode(unref(bngPopoverContent_default),{name:`tooltip-outdated-message`},{default:withCtx(()=>[..._cache[2]||=[createBaseVNode(`div`,{class:`tooltip-outdated-message`},`This profile was saved with an old version of the game. It can no longer be loaded.`,-1)]]),_:1})],64))}},Profiles_default=__plugin_vue_export_helper_default(_sfc_main$219,[[`__scopeId`,`data-v-6aef0f62`]]);const useRepairStore=defineStore(`repair`,()=>{let repairOptions=ref({}),vehicleData=ref({}),playerAttributes=ref({}),driverScoreTierData=ref({}),futureDriverScore=ref(0),driverScore=ref(0),resetStore=()=>{repairOptions.value={},vehicleData.value={},playerAttributes.value={},driverScoreTierData.value={},futureDriverScore.value=0,driverScore.value=0};return{repairOptions,vehicleData,playerAttributes,getRepairData:()=>{resetStore(),Lua_default.career_modules_insurance_repairScreen.getRepairData().then(data=>{repairOptions.value=data.repairOptions,vehicleData.value=data.vehicleData,playerAttributes.value=data.playerAttributes,driverScoreTierData.value=data.driverScoreTierData,futureDriverScore.value=data.futureDriverScore,driverScore.value=data.driverScore})},driverScoreTierData,futureDriverScore,driverScore,resetStore}});var _hoisted_1$195={class:`content blue-background`},_hoisted_2$158={class:`vehicle-info`},_hoisted_3$139={class:`right-info-wrapper`},_hoisted_4$115={class:`damage-estimate-wrapper`},_hoisted_5$100={class:`damage-estimate-value`},_hoisted_6$83={key:0},_hoisted_7$71={class:`repair-options`},_hoisted_8$58=[`onClick`],_hoisted_9$52={class:`icon-wrapper`},_hoisted_10$45={key:0,class:`option-text-wrapper`},_hoisted_11$40={class:`smaller-text`},_hoisted_12$30={class:`bigger-text`,style:{"margin-top":`-5px`}},_hoisted_13$26={key:1,class:`option-text-wrapper`},_hoisted_14$25={key:0},_hoisted_15$24={class:`details-wrapper`},_hoisted_16$24={class:`detail-wrapper`},_hoisted_17$19={class:`item`},_hoisted_18$17={key:0,class:`accident-forgivenesses-text`},_hoisted_19$14={key:0,class:`item`},_hoisted_20$12={class:`item-value`},_hoisted_21$11={key:1,class:`renews-in-wrapper`},_hoisted_22$9={class:`renews-in-name`},_hoisted_23$8={class:`renews-in-value`},_hoisted_24$7={class:`detail-wrapper`},_hoisted_25$6={class:`item`},_hoisted_26$5={class:`item-value`},_hoisted_27$5={class:`item`},_hoisted_28$4={class:`item-value`},_hoisted_29$4={key:0,class:`item`},_hoisted_30$4={class:`item-value`},_hoisted_31$4={key:1,class:`item`},_hoisted_32$4={class:`item-value`},_hoisted_33$4={class:`item total-cost`},_hoisted_34$4={class:`item-value`},_hoisted_35$3={key:0},_hoisted_36$3={key:1},_hoisted_37$2={class:`confirm-repair-money-wrapper`},_hoisted_38$2={key:2},_hoisted_39$2={class:`confirm-repair-money-wrapper`},_sfc_main$218={__name:`RepairMain`,setup(__props){let{units}=useBridge();useComputerStore();let repairStore=useRepairStore(),selectedRepairOptionKey=ref(null),selectedRepairTimeOptionIndex=ref(1),currentRepairOption=computed(()=>!selectedRepairOptionKey.value||!repairStore.repairOptions?null:repairStore.repairOptions[selectedRepairOptionKey.value]),accidentForgivenessesText=computed(()=>!repairStore.repairOptions.insuranceRepairData.accidentForgivenesses>0?`(No Accident Forgivenesses left)`:`(`+repairStore.repairOptions.insuranceRepairData.accidentForgivenesses+` Accident Forgivenesses left)`),selectedRepairTimeOption=computed(()=>currentRepairOption.value?.repairTimeOptions?.choices?currentRepairOption.value.repairTimeOptions.choices.find(choice=>choice.id===selectedRepairTimeOptionIndex.value):null),renewsInFormatted=computed(()=>currentRepairOption.value?.renewsIn?units.buildString(`length`,currentRepairOption.value.renewsIn*1e3,0):``);watch(()=>repairStore.repairOptions,newOptions=>{if(newOptions&&Object.keys(newOptions).length>0&&!selectedRepairOptionKey.value){let selectedKey=Object.keys(newOptions).find(key=>newOptions[key].useInsurance)||Object.keys(newOptions)[0];selectedRepairOptionKey.value=selectedKey,newOptions[selectedKey]?.repairTimeOptions?.currentValueId&&(selectedRepairTimeOptionIndex.value=newOptions[selectedKey].repairTimeOptions.currentValueId)}},{immediate:!0}),watch(()=>selectedRepairOptionKey.value,newKey=>{newKey&&repairStore.repairOptions[newKey]?.repairTimeOptions?.currentValueId?selectedRepairTimeOptionIndex.value=repairStore.repairOptions[newKey].repairTimeOptions.currentValueId:selectedRepairTimeOptionIndex.value=1});let onRepairOptionClick=key=>{selectedRepairOptionKey.value=key},close=()=>{Lua_default.career_modules_insurance_repairScreen.closeMenu()},startRepair=(repairOptionKey,repairTimeOptionIndex)=>{selectedRepairTimeOption.value&&Lua_default.career_modules_insurance_repairScreen.startRepairInGarage(repairStore.vehicleData.invVehId,{repairTime:selectedRepairTimeOption.value.value,isInsuranceRepair:currentRepairOption.value.useInsurance,cost:{repairTimeCost:selectedRepairTimeOption.value.premiumInfluence,deductible:currentRepairOption.value.useInsurance?repairStore.repairOptions.insuranceRepairData.deductible:repairStore.vehicleData.damageCost}})};return onMounted(()=>{repairStore.getRepairData()}),onUnmounted(()=>{repairStore.resetStore()}),(_ctx,_cache)=>(openBlock(),createBlock(ComputerWrapper_default,{path:[`Repair`],title:`Repair ${unref(repairStore).vehicleData.name}`,back:``,onBack:close},{default:withCtx(()=>[unref(repairStore).vehicleData.name?(openBlock(),createBlock(unref(bngCard_default),{key:0,class:`repairMain blue-background`},{default:withCtx(()=>[createBaseVNode(`div`,_hoisted_1$195,[_cache[23]||=createBaseVNode(`div`,{class:`title`},`Vehicle Repair`,-1),createBaseVNode(`div`,_hoisted_2$158,[createVNode(unref(insuranceVehTile_default),{class:`vehicle-tile`,vehicle:unref(repairStore).vehicleData},{rightContent:withCtx(()=>[createBaseVNode(`div`,_hoisted_3$139,[createBaseVNode(`div`,_hoisted_4$115,[_cache[2]||=createBaseVNode(`span`,{class:`damage-estimate-text`},` Damage Estimate: `,-1),createBaseVNode(`span`,_hoisted_5$100,[createVNode(unref(bngUnit_default),{class:`red-price`,money:unref(repairStore).vehicleData.damageCost},null,8,[`money`])])]),unref(repairStore).vehicleData.isInsured?createCommentVNode(``,!0):(openBlock(),createElementBlock(`div`,_hoisted_6$83,[..._cache[3]||=[createBaseVNode(`span`,{class:`not-insured-text`},` Not Insured! `,-1)]]))])]),_:1},8,[`vehicle`])]),createBaseVNode(`div`,null,[_cache[7]||=createBaseVNode(`div`,{class:`repair-options-title`},`Repair Options`,-1),createBaseVNode(`div`,_hoisted_7$71,[(openBlock(!0),createElementBlock(Fragment,null,renderList(unref(repairStore).repairOptions,(repairOption,key)=>(openBlock(),createElementBlock(`div`,{key,class:normalizeClass([`repair-option`,{selected:selectedRepairOptionKey.value===key}]),onClick:$event=>onRepairOptionClick(key)},[createBaseVNode(`div`,_hoisted_9$52,[createVNode(unref(bngIcon_default),{type:repairOption.useInsurance?unref(icons).shieldCheckmark:unref(icons).wrench},null,8,[`type`])]),createBaseVNode(`div`,null,[repairOption.useInsurance?(openBlock(),createElementBlock(`div`,_hoisted_10$45,[_cache[5]||=createBaseVNode(`div`,{class:`bigger-text`},` Insurance Claim `,-1),createBaseVNode(`div`,_hoisted_11$40,toDisplayString(repairOption.insuranceName),1),createBaseVNode(`div`,_hoisted_12$30,[_cache[4]||=createTextVNode(` Deductible : `,-1),createVNode(unref(bngUnit_default),{class:`unit-no-padding`,money:unref(repairStore).repairOptions.insuranceRepairData.deductible},null,8,[`money`])])])):(openBlock(),createElementBlock(`div`,_hoisted_13$26,[..._cache[6]||=[createBaseVNode(`div`,{class:`bigger-text`},` Private Repair `,-1),createBaseVNode(`div`,{class:`smaller-text`},` No Policy Impact `,-1),createBaseVNode(`div`,{class:`bigger-text`},` Full Damage Cost `,-1)]]))])],10,_hoisted_8$58))),128))])]),currentRepairOption.value?(openBlock(),createElementBlock(`div`,_hoisted_14$25,[(openBlock(),createBlock(unref(coverageOption_default),{coverageOption:currentRepairOption.value.repairTimeOptions,key:`repairTime-${selectedRepairOptionKey.value}`,modelValue:selectedRepairTimeOptionIndex.value,"onUpdate:modelValue":_cache[0]||=$event=>selectedRepairTimeOptionIndex.value=$event,simpleSelect:!0,showPerkMode:`none`},null,8,[`coverageOption`,`modelValue`]))])):createCommentVNode(``,!0),createBaseVNode(`div`,_hoisted_15$24,[createBaseVNode(`div`,_hoisted_16$24,[_cache[13]||=createBaseVNode(`h3`,null,`Insurance Impact`,-1),createBaseVNode(`div`,_hoisted_17$19,[createBaseVNode(`span`,null,[_cache[8]||=createBaseVNode(`div`,{class:`item-label`},`Driver Score Change`,-1),currentRepairOption.value.useInsurance?(openBlock(),createElementBlock(`div`,_hoisted_18$17,toDisplayString(accidentForgivenessesText.value),1)):createCommentVNode(``,!0)]),createBaseVNode(`span`,{class:normalizeClass([`item-value`,{"red-text":currentRepairOption.value.useInsurance&&unref(repairStore).futureDriverScorestartRepair(selectedRepairOptionKey.value,selectedRepairTimeOptionIndex.value)},{default:withCtx(()=>[unref(repairStore).vehicleData.needsRepair?selectedRepairTimeOption.value?.canPay?(openBlock(),createElementBlock(`div`,_hoisted_38$2,[_cache[22]||=createTextVNode(` Confirm Repair `,-1),createBaseVNode(`div`,_hoisted_39$2,[createVNode(unref(bngUnit_default),{money:selectedRepairTimeOption.value?.totalPrice},null,8,[`money`])])])):(openBlock(),createElementBlock(`div`,_hoisted_36$3,[_cache[21]||=createTextVNode(` Insufficient funds `,-1),createBaseVNode(`div`,_hoisted_37$2,[createVNode(unref(bngUnit_default),{money:selectedRepairTimeOption.value?.totalPrice},null,8,[`money`])])])):(openBlock(),createElementBlock(`div`,_hoisted_35$3,` Vehicle doesn't need repair `))]),_:1},8,[`disabled`])])]),_:1})):createCommentVNode(``,!0)]),_:1},8,[`title`]))}},RepairMain_default=__plugin_vue_export_helper_default(_sfc_main$218,[[`__scopeId`,`data-v-19ad91be`]]),_hoisted_1$194={class:`awd-container bng-app`},_hoisted_2$157={key:0,class:`awd-table`},_hoisted_3$138={class:`data-name`},_sfc_main$217={__name:`app`,setup(__props,{expose:__expose}){let{$game}=useLibStore(),streamList=[`advancedWheelDebugData`],data=ref([]),hasData=computed(()=>Array.isArray(data.value)&&data.value.length>0),orderedData=computed(()=>Array.isArray(data.value)?data.value.sort((a$1,b)=>a$1.name.toLowerCase().localeCompare(b.name.toLowerCase())):[]);__expose({hasData}),onMounted(()=>{$game.streams.add(streamList),register()}),onUnmounted(()=>{$game.streams.remove(streamList),$game.api.activeObjectLua(`extensions.advancedwheeldebug.registerDebugUser("advancedWheelDebugApp", false)`)});let register=()=>$game.api.activeObjectLua(`extensions.advancedwheeldebug.registerDebugUser("advancedWheelDebugApp", true)`),format$2=value=>value?parseFloat(value).toFixed(3):``;return $game.events.on(`onStreamsUpdate`,streams=>data.value=streams.advancedWheelDebugData),$game.events.on(`VehicleReset`,register),$game.events.on(`VehicleChange`,register),(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$194,[orderedData.value&&orderedData.value.length>0?(openBlock(),createElementBlock(`table`,_hoisted_2$157,[_cache[0]||=createBaseVNode(`thead`,null,[createBaseVNode(`tr`,null,[createBaseVNode(`th`,null,`Name`),createBaseVNode(`th`,null,`Camber`),createBaseVNode(`th`,null,`Toe`),createBaseVNode(`th`,null,`Caster`),createBaseVNode(`th`,null,`SAI`)])],-1),(openBlock(!0),createElementBlock(Fragment,null,renderList(orderedData.value,w=>(openBlock(),createElementBlock(`tr`,null,[createBaseVNode(`td`,_hoisted_3$138,toDisplayString(w.name),1),createBaseVNode(`td`,null,toDisplayString(format$2(w.camber)),1),createBaseVNode(`td`,null,toDisplayString(format$2(w.toe)),1),createBaseVNode(`td`,null,toDisplayString(format$2(w.caster)),1),createBaseVNode(`td`,null,toDisplayString(format$2(w.sai)),1)]))),256))])):createCommentVNode(``,!0)]))}},app_default$2=__plugin_vue_export_helper_default(_sfc_main$217,[[`__scopeId`,`data-v-5eb5aaaa`]]),_hoisted_1$193={class:`legends-container`},TAG=`[beamng.apps:brakeTorqueGraph]`,_sfc_main$216={__name:`app`,setup(__props){let{$game}=useLibStore(),app$1=ref(null),canvas=ref(null),graphList=ref([]),streamsList$1=[`wheelInfo`,`electrics`],colors=[],chart=new SmoothieChart({minValue:0,millisPerPixel:20,interpolation:`linear`,grid:{fillStyle:`rgba(250, 250, 250, 0.8)`,strokeStyle:`rgba(0,0,0,0.3)`,verticalSections:6,millisPerLine:1e3,sharpLines:!0},labels:{fillStyle:`black`}}),speedGraph=new TimeSeries,appResizeObserver=new ResizeObserver(entries=>{let entry=entries[0];canvas.value.width=entry.target.offsetWidth,canvas.value.height=entry.target.offsetHeight}),graphs={},globalMax=2e3;onMounted(()=>{initColors(),initChart(),appResizeObserver.observe(app$1.value),graphList.value=[{title:`ui.apps.brake_torque_graph.speed`,color:colors[0]}],$game.streams.add(streamsList$1),$game.events.on(`onStreamsUpdate`,onStreamsUpdate),$game.events.on(`VehicleReset`,onVehicleReset),$game.events.on(`VehicleChange`,onVehicleChange)}),onBeforeUnmount(()=>{appResizeObserver.unobserve(app$1.value)}),onUnmounted(()=>{$game.events.off(`onStreamsUpdate`,onStreamsUpdate),$game.events.off(`VehicleReset`,onVehicleReset),$game.events.off(`VehicleChange`,onVehicleChange),$game.streams.remove(streamsList$1)});function onStreamsUpdate(streams){for(let stream of streamsList$1)if(!streams[stream])return;globalMax=Math.max(globalMax,streams.electrics.airspeed*15);let xPoint=new Date;for(let w in speedGraph.append(xPoint,streams.electrics.airspeed*15),streams.wheelInfo){let wheelName=streams.wheelInfo[w][0];if(!graphs.hasOwnProperty(wheelName)){graphs[wheelName]=new TimeSeries,logger_default.debug(`${TAG} adding graph for ${wheelName}`);let wheelColor=colors[graphList.value.length%colors.length];graphList.value.push({title:wheelName,color:wheelColor}),chart.addTimeSeries(graphs[wheelName],{strokeStyle:wheelColor,lineWidth:2});return}graphs[wheelName].append(xPoint,streams.wheelInfo[w][8]),globalMax=Math.max(globalMax,streams.wheelInfo[w][8])}chart.options.maxValue=globalMax}function onVehicleReset(data){graphs={},graphList.value=[{title:`Speed`,color:colors[0]}]}function onVehicleChange(data){graphs={},graphList.value=[{title:`Speed`,color:colors[0]}]}function initChart(){chart.addTimeSeries(speedGraph,{strokeStyle:colors[0],lineWidth:2}),chart.streamTo(canvas.value,40)}function initColors(){for(let i=15;i>0;i--){let c=rainbow(15,i);colors.push(`rgb(${Math.round(255*c[0])}, ${Math.round(255*c[1])}, ${Math.round(255*c[2])})`)}}return(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,{class:`btg-app`,ref_key:`app`,ref:app$1},[createBaseVNode(`div`,_hoisted_1$193,[(openBlock(!0),createElementBlock(Fragment,null,renderList(graphList.value,graph=>(openBlock(),createElementBlock(`small`,{class:`legend`,style:normalizeStyle({color:graph.color})},toDisplayString(_ctx.$t(graph.title)),5))),256))]),createBaseVNode(`canvas`,{ref_key:`canvas`,ref:canvas},null,512)],512))}},app_default$3=__plugin_vue_export_helper_default(_sfc_main$216,[[`__scopeId`,`data-v-642d2338`]]),_hoisted_1$192={class:`bus-line bng-app`},_hoisted_2$156={class:`header`},_hoisted_3$137={class:`time`},_hoisted_4$114={class:`logo`},_hoisted_5$99=[`src`],_hoisted_6$82={class:`route-id`},_hoisted_7$70={class:`text`},_hoisted_8$57={class:`destination`},_hoisted_9$51={key:0,class:`display-stops`},_hoisted_10$44={class:`title`},_hoisted_11$39={key:1,class:`next-stop`},_hoisted_12$29={class:`title`},defaultRouteId=`00`,defaultDestination=`Not in service`,defaultRouteColor=`#FFA200`,totalRoutesDisplayed=4,_sfc_main$215={__name:`app`,setup(__props){let{$game}=useLibStore(),timerInterval,navDisplay=reactive({time:``,stopRequested:!1}),localBusRoute=ref(null),routeId=computed(()=>localBusRoute.value&&localBusRoute.value.routeId?localBusRoute.value.routeId.substring(0,3):defaultRouteId),destination=computed(()=>localBusRoute.value&&localBusRoute.value.destination?localBusRoute.value.destination.substring(0,20):defaultDestination),routeColor=computed(()=>localBusRoute.value&&localBusRoute.value.routeColor?localBusRoute.value.routeColor:defaultRouteColor),stops=computed(()=>{if(!localBusRoute.value||!localBusRoute.value.stops)return null;let data=localBusRoute.value.stops.slice(0,-1);return data.length>totalRoutesDisplayed&&(data=data.slice(1).slice(0,totalRoutesDisplayed)),data.reverse()}),nextStop=computed(()=>localBusRoute.value&&localBusRoute.value.stops&&localBusRoute.value.stops.length-1>totalRoutesDisplayed?localBusRoute.value.stops[0]:null);onBeforeMount(()=>{updateTime(),timerInterval=setInterval(()=>{updateTime()},1e3)}),onMounted(()=>{$game.events.on(`BusDisplayUpdate`,onBusDisplayUpdate),$game.events.on(`SetStopRequest`,onSetStopRequest),$game.api.engineLua(`if scenario_busdriver then scenario_busdriver.requestState() end`)}),onUnmounted(()=>{clearInterval(timerInterval),$game.events.off(`BusDisplayUpdate`,onBusDisplayUpdate),$game.events.off(`SetStopRequest`,onSetStopRequest)});function onBusDisplayUpdate(data){console.log(`onBusDisplayUpdate`,data),localBusRoute.value?(localBusRoute.value.routeId=data.routeId,localBusRoute.value.stops=localBusRoute.value.stops.filter(x=>data.tasklist.find(y=>y[0]===x.id))):localBusRoute.value=parseBusData(data)}function onSetStopRequest(data){console.log(`onSetStopRequest`,data),data&&data.stopRequested!==null&&(navDisplay.stopRequested=data.stopRequested)}function updateTime(){let date=new Date;navDisplay.time=`${date.getHours()}:${date.getMinutes()<10?`0`+date.getMinutes():date.getMinutes()}`}function parseBusData(data){return{destination:data.direction,routeId:data.routeId,routeColor:data.routeColor,stops:data.tasklist.map(x=>({id:x[0],name:x[1]}))}}return(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$192,[createBaseVNode(`div`,{class:`content`,style:normalizeStyle({"--routeColor":routeColor.value})},[createBaseVNode(`div`,_hoisted_2$156,[createBaseVNode(`div`,_hoisted_3$137,toDisplayString(navDisplay.time),1),createBaseVNode(`div`,_hoisted_4$114,[createBaseVNode(`img`,{src:unref(getAssetURL)(`images/beamng_logo_50x50.png`)},null,8,_hoisted_5$99)])]),createBaseVNode(`div`,{class:normalizeClass([`route`,{highlight:!stops.value||stops.value.length===0}])},[createBaseVNode(`div`,_hoisted_6$82,[createBaseVNode(`span`,_hoisted_7$70,toDisplayString(routeId.value),1),_cache[0]||=createBaseVNode(`span`,{class:`chevron`},null,-1)]),createBaseVNode(`div`,_hoisted_8$57,toDisplayString(destination.value),1)],2),stops.value?(openBlock(),createElementBlock(`div`,_hoisted_9$51,[(openBlock(!0),createElementBlock(Fragment,null,renderList(stops.value,stop$1=>(openBlock(),createElementBlock(`div`,{class:`stop`,key:stop$1.id},[_cache[1]||=createBaseVNode(`div`,{class:`chevron`},null,-1),createBaseVNode(`div`,_hoisted_10$44,toDisplayString(stop$1.name),1)]))),128))])):createCommentVNode(``,!0),nextStop.value?(openBlock(),createElementBlock(`div`,_hoisted_11$39,[_cache[2]||=createBaseVNode(`div`,{class:`chevron`},null,-1),createBaseVNode(`div`,_hoisted_12$29,toDisplayString(nextStop.value.name),1)])):createCommentVNode(``,!0)],4),createBaseVNode(`div`,{class:normalizeClass([`stop-request`,{requested:navDisplay.stopRequested}])},[createBaseVNode(`div`,{class:normalizeClass([`text`,{glow:navDisplay.stopRequested}])},toDisplayString(_ctx.$t(`ui.busRoute.stopRequested`)),3)],2)]))}},app_default$4=__plugin_vue_export_helper_default(_sfc_main$215,[[`__scopeId`,`data-v-7731db49`]]),_hoisted_1$191={class:`bng-app cd-container`,layout:`column`,"layout-align":`center center`},_sfc_main$214={__name:`app`,setup(__props){let{$game}=useLibStore(),cameraDistance=ref(null);return onMounted(()=>{$game.api.engineLua(`extensions.load("ui_cameraDistanceApp")`)}),onUnmounted(()=>{$game.api.engineLua(`extensions.unload("ui_cameraDistanceApp")`)}),$game.events.on(`cameraDistance`,function(distance,errMsg){distance<0?cameraDistance.value=errMsg:cameraDistance.value=$game.units.buildString(`length`,distance,2)}),(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$191,[createBaseVNode(`span`,null,toDisplayString(cameraDistance.value),1)]))}},app_default$5=__plugin_vue_export_helper_default(_sfc_main$214,[[`__scopeId`,`data-v-d72a4879`]]),_hoisted_1$190={key:0,class:`bng-app thermal-clutch-debug`},_hoisted_2$155={class:`set-name`},_sfc_main$213={__name:`app`,setup(__props){let{$game}=useLibStore(),streamsList$1=[`clutchThermalData`],data=ref([]);onMounted(()=>{$game.streams.add(streamsList$1)}),onUnmounted(()=>{$game.streams.remove(streamsList$1)}),$game.events.on(`onStreamsUpdate`,streams=>{streams.clutchThermalData?data.value=parseData(streams.clutchThermalData):data.value=null});function parseData(data$1){return[{str:$game.units.buildString(`temperature`,data$1.clutchTemperature,0),name:`Clutch temperature`,warn:data$1.clutchTemperature>data$1.maxSafeTemp&&data$1.clutchTemperature<=data$1.efficiencyScaleEnd,error:data$1.clutchTemperature>data$1.efficiencyScaleEnd},{str:$game.units.buildString(`temperature`,data$1.maxSafeTemp,0),name:`Max safe temperature`},{str:$game.units.buildString(`temperature`,data$1.efficiencyScaleEnd,0),name:`Efficiency scale end`},{str:data$1.thermalEfficiency.toFixed(3),name:`Clutch efficiency`,warn:data$1.thermalEfficiency<1&&data$1.thermalEfficiency>=.5,error:data$1.thermalEfficiency<.5},{str:$game.units.buildString(`energy`,data$1.energyToClutch,0),name:`Q to clutch`},{str:$game.units.buildString(`energy`,data$1.energyClutchToBellHousing,0),name:`Q clutch to bell housing`}]}return(_ctx,_cache)=>data.value?(openBlock(),createElementBlock(`div`,_hoisted_1$190,[(openBlock(!0),createElementBlock(Fragment,null,renderList(data.value,(set,index)=>(openBlock(),createElementBlock(`div`,{key:index,class:`set`},[createBaseVNode(`div`,_hoisted_2$155,toDisplayString(set.name),1),createBaseVNode(`div`,{class:normalizeClass([`set-value`,{"thermal-warning":set.warn,"thermal-error":set.error}])},toDisplayString(set.str),3)]))),128))])):createCommentVNode(``,!0)}},app_default$6=__plugin_vue_export_helper_default(_sfc_main$213,[[`__scopeId`,`data-v-c0f00383`]]),_hoisted_1$189={width:`100%`,height:`100%`,viewBox:`0 0 244 244`},_hoisted_2$154=[`transform`],_sfc_main$212={__name:`app`,setup(__props){let streamsList$1=[`sensors`],{$game}=useLibStore(),arrow$3=ref(null),circle=ref(null),yawDegrees=ref(0),bbox=computed(()=>arrow$3.value?arrow$3.value.getBBox():null),rotateOrigin=computed(()=>bbox.value?`${yawDegrees.value} ${bbox.value.x+bbox.value.width/2} ${bbox.value.y+bbox.value.height/2}`:0);onMounted(()=>{$game.events.on(`onStreamsUpdate`,onStreamsUpdate),$game.streams.add(streamsList$1)}),onUnmounted(()=>{$game.events.off(`onStreamsUpdate`,onStreamsUpdate),$game.streams.remove(streamsList$1)});function onStreamsUpdate(streams){for(let stream of streamsList$1)if(!streams[stream])return;yawDegrees.value=streams.sensors.yaw*180/Math.PI+180}return(_ctx,_cache)=>(openBlock(),createElementBlock(`svg`,_hoisted_1$189,[createBaseVNode(`g`,{ref_key:`circle`,ref:circle,transform:`rotate(${rotateOrigin.value})`},[..._cache[0]||=[createStaticVNode(`NESW`,5)]],8,_hoisted_2$154),createBaseVNode(`path`,{d:`M122 90 L105 154 L139 154 Z`,ref_key:`arrow`,ref:arrow$3,class:`arrow`},null,512)]))}},app_default$7=__plugin_vue_export_helper_default(_sfc_main$212,[[`__scopeId`,`data-v-4a5918e7`]]),compassWidth=2e3,_sfc_main$211={__name:`app`,setup(__props){let streamsList$1=[`sensors`],{$game}=useLibStore(),app$1=ref(null),canvas=ref(null),osCanvas=ref(null),widthLess=computed(()=>(compassWidth-canvas.value.width)/2),appResizeObserver=new ResizeObserver(entries=>{let entry=entries[0];canvas.value.width=entry.target.offsetWidth,canvas.value.height=entry.target.offsetHeight});onMounted(()=>{initOsCanvas(),appResizeObserver.observe(app$1.value),$game.events.on(`onStreamsUpdate`,onStreamsUpdate),$game.streams.add(streamsList$1)}),onBeforeUnmount(()=>{appResizeObserver.unobserve(app$1.value)}),onUnmounted(()=>{$game.events.off(`onStreamsUpdate`,onStreamsUpdate),$game.streams.remove(streamsList$1)});function onStreamsUpdate(streams){for(let stream of streamsList$1)if(!streams[stream])return;let canvasCtx=canvas.value.getContext(`2d`);canvasCtx.clearRect(0,0,canvas.value.width,canvas.value.height),canvasCtx.fillStyle=`rgba(255,255,255,0.8)`,canvasCtx.strokeStyle=`rgba(255,255,255,0.6)`;let heading=streams.sensors.yaw,posX=heading*compassWidth/(2*Math.PI)-widthLess.value;canvasCtx.drawImage(osCanvas.value,posX,0),heading*compassWidth/(2*Math.PI)-widthLess.value>0?canvasCtx.drawImage(osCanvas.value,posX-compassWidth,0):posX+compassWidth(openBlock(),createElementBlock(`div`,{class:`container`,ref_key:`app`,ref:app$1},[createBaseVNode(`canvas`,{ref_key:`canvas`,ref:canvas,width:`280`,height:`56`},null,512),createBaseVNode(`canvas`,{ref_key:`osCanvas`,ref:osCanvas,class:`os-canvas`},null,512)],512))}},app_default$8=__plugin_vue_export_helper_default(_sfc_main$211,[[`__scopeId`,`data-v-e608df6a`]]),_hoisted_1$188={transform:`translate(-13.701535,-283.48656)`,style:{display:`inline`},id:`carGroup`},_hoisted_2$153={y:`255.49614`,x:`142.73175`,style:{"font-style":`normal`,"font-variant":`normal`,"font-weight":`normal`,"font-stretch":`normal`,"font-size":`18.66665649px`,"line-height":`1.25`,"font-family":`roboto`,"-inkscape-font-specification":`roboto`,"letter-spacing":`0px`,"word-spacing":`0px`,fill:`#ffffff`},"xml:space":`preserve`},componentDamageMap={body:{FL:{svgId:`bodyFL`,priority:2,tempDamage:!1},FR:{svgId:`bodyFR`,priority:2,tempDamage:!1},ML:{svgId:`bodyML`,priority:2,tempDamage:!1},MR:{svgId:`bodyMR`,priority:2,tempDamage:!1},RL:{svgId:`bodyRL`,priority:2,tempDamage:!1},RR:{svgId:`bodyRR`,priority:2,tempDamage:!1}},engine:{oilStarvation:{svgId:`engine`,priority:0,damageText:`Oil Starvation`,tempDamage:!0},coolantHot:{svgId:`engine`,priority:0,damageText:`Coolant Overheating`,tempDamage:!1},oilHot:{svgId:`engine`,priority:0,damageText:`Oil Overheating`,tempDamage:!1},pistonRingsDamaged:{svgId:`engine`,priority:0,damageText:`Piston Rings Damaged`,tempDamage:!1},rodBearingsDamaged:{svgId:`engine`,priority:0,damageText:`Rod Bearings Damaged`,tempDamage:!1},headGasketDamaged:{svgId:`engine`,priority:0,damageText:`Head Gasket Damaged`,tempDamage:!1},turbochargerHot:{svgId:`engine`,priority:0,damageText:`Turbocharger Overheating`,tempDamage:!1},engineIsHydrolocking:{svgId:`engine`,priority:0,damageText:`Engine is Hydrolocking`,tempDamage:!1},engineReducedTorque:{svgId:`engine`,priority:0,damageText:`Engine Torque Reduced`,tempDamage:!1},mildOverrevDamage:{svgId:`engine`,priority:0,damageText:`Mild Over Rev Damage`,tempDamage:!1},overRevDanger:{svgId:`engine`,priority:0,damageText:`Over Rev Risk`,tempDamage:!1},overTorqueDanger:{svgId:`engine`,priority:0,damageText:`Over Torque Risk`,tempDamage:!1},engineHydrolocked:{svgId:`engine`,priority:1,damageText:`Engine is Hydrolocked`,tempDamage:!1},engineDisabled:{svgId:`engine`,priority:1,damageText:`Engine Disabled`,tempDamage:!1},blockMelted:{svgId:`engine`,priority:1,damageText:`Block Melted`,tempDamage:!1},engineLockedUp:{svgId:`engine`,priority:1,damageText:`Engine Locked Up`,tempDamage:!1},radiatorLeak:{svgId:`radiator`,priority:1,damageText:`Radiator Leaking`,tempDamage:!1}},powertrain:{wheelaxleFL:{svgId:`wheelaxleFL`,priority:1,damageText:`Front Left Axle Broken`,tempDamage:!1},wheelaxleFR:{svgId:`wheelaxleFR`,priority:1,damageText:`Front Right Axle Broken`,tempDamage:!1},wheelaxleRL:{svgId:`wheelaxleRL`,priority:1,damageText:`Rear Left Axle Broken`,tempDamage:!1},wheelaxleRR:{svgId:`wheelaxleRR`,priority:1,damageText:`Rear Right Axle Broken`,tempDamage:!1},driveshaft:{svgId:`driveshaft`,priority:1,damageText:`Driveshaft Broken`,tempDamage:!1},driveshaft_F:{svgId:`driveshaft`,priority:1,damageText:`Front Driveshaft Broken`,tempDamage:!1},mainEngine:{svgId:`engine`,priority:1,damageText:`Engine Broken`,tempDamage:!1}},energyStorage:{mainTank:{svgId:`fueltank`,priority:1,damageText:`Fuel Tank Damaged`,tempDamage:!1}},wheels:{tireFL:{svgId:`tireFL`,priority:0,damageText:`Front Left Tire Burst`,tempDamage:!1},tireFR:{svgId:`tireFR`,priority:0,damageText:`Front Right Tire Burst`,tempDamage:!1},tireRL:{svgId:`tireRL`,priority:0,damageText:`Rear Left Tire Burst`,tempDamage:!1},tireRR:{svgId:`tireRR`,priority:0,damageText:`Rear Right Tire Burst`,tempDamage:!1},brakeFL:{svgId:`brakeFL`,priority:1,damageText:`FL Brake Damaged`,tempDamage:!1},brakeFR:{svgId:`brakeFR`,priority:1,damageText:`FR Brake Damaged`,tempDamage:!1},brakeRL:{svgId:`brakeRL`,priority:1,damageText:`RL Brake Damaged`,tempDamage:!1},brakeRR:{svgId:`brakeRR`,priority:1,damageText:`RR Brake Damaged`,tempDamage:!1},brakeOverHeatFL:{svgId:`brakeFL`,priority:0,damageText:`FL Brake Fading`,tempDamage:!0},brakeOverHeatFR:{svgId:`brakeFR`,priority:0,damageText:`FR Brake Fading`,tempDamage:!0},brakeOverHeatRL:{svgId:`brakeRL`,priority:0,damageText:`RL Brake Fading`,tempDamage:!0},brakeOverHeatRR:{svgId:`brakeRR`,priority:0,damageText:`RR Brake Fading`,tempDamage:!0},FL:{svgId:`tireFL`,priority:1,damageText:`Front Left Tire Broken`,tempDamage:!1},FR:{svgId:`tireFR`,priority:1,damageText:`Front Right Tire Broken`,tempDamage:!1},RL:{svgId:`tireRL`,priority:1,damageText:`Rear Left Tire Broken`,tempDamage:!1},RR:{svgId:`tireRR`,priority:1,damageText:`Rear Right Tire Broken`,tempDamage:!1}}},textDisplayTime=2e3,orangeColor=`rgba(255, 132, 0, 0.6)`,redColor=`rgba(255, 0, 0, 0.6)`,noDataColor=`rgba(0, 0, 0, 0 )`,streamsList=[`wheelThermalData`,`engineInfo`],_sfc_main$210={__name:`app`,setup(__props){let{$game}=useLibStore(),svg=ref(null),tireFL=ref(null),tireFR=ref(null),tireRL=ref(null),tireRR=ref(null),bodyFL=ref(null),bodyML=ref(null),bodyMR=ref(null),driveShaft=ref(null),engine=ref(null),fueltank=ref(null),radiator=ref(null),wheelaxleFL=ref(null),wheelaxleFR=ref(null),brakeFL=ref(null),brakeFR=ref(null),bodyFR=ref(null),bodyRL=ref(null),bodyRR=ref(null),brakeRL=ref(null),brakeRR=ref(null),wheelaxleRL=ref(null),wheelaxleRR=ref(null),damageContainer=ref(null),damageBox=ref(null),damageText=ref(null),appState=reactive({isAppDisplayed:!1,hasDamage:!1,permanentDamagedParts:0,isProcessingMessages:!1}),damageTextQueue=ref([]),componentDamage=ref({body:{FL:{damageDisplayed:!1,reference:bodyFL},FR:{damageDisplayed:!1,reference:bodyFR},ML:{damageDisplayed:!1,reference:bodyML},MR:{damageDisplayed:!1,reference:bodyMR},RL:{damageDisplayed:!1,reference:bodyRL},RR:{damageDisplayed:!1,reference:bodyRR}},engine:{oilStarvation:{damageDisplayed:!1,reference:engine},coolantHot:{damageDisplayed:!1,reference:engine},oilHot:{damageDisplayed:!1,reference:engine},pistonRingsDamaged:{damageDisplayed:!1,reference:engine},rodBearingsDamaged:{damageDisplayed:!1,reference:engine},headGasketDamaged:{damageDisplayed:!1,reference:engine},turbochargerHot:{damageDisplayed:!1,reference:engine},engineIsHydrolocking:{damageDisplayed:!1,reference:engine},engineReducedTorque:{damageDisplayed:!1,reference:engine},mildOverrevDamage:{damageDisplayed:!1,reference:engine},overRevDanger:{damageDisplayed:!1,reference:engine},overTorqueDanger:{damageDisplayed:!1,reference:engine},engineHydrolocked:{damageDisplayed:!1,reference:engine},engineDisabled:{damageDisplayed:!1,reference:engine},blockMelted:{damageDisplayed:!1,reference:engine},engineLockedUp:{damageDisplayed:!1,reference:engine},radiatorLeak:{damageDisplayed:!1,reference:radiator}},powertrain:{wheelaxleFL:{damageDisplayed:!1,reference:wheelaxleFL},wheelaxleFR:{damageDisplayed:!1,reference:wheelaxleFR},wheelaxleRL:{damageDisplayed:!1,reference:wheelaxleRL},wheelaxleRR:{damageDisplayed:!1,reference:wheelaxleRR},driveshaft:{damageDisplayed:!1,reference:driveShaft},driveshaft_F:{damageDisplayed:!1,reference:driveShaft},mainEngine:{damageDisplayed:!1,reference:engine}},energyStorage:{mainTank:{damageDisplayed:!1,reference:fueltank}},wheels:{tireFL:{damageDisplayed:!1,reference:tireFL},tireFR:{damageDisplayed:!1,reference:tireFR},tireRL:{damageDisplayed:!1,reference:tireRL},tireRR:{damageDisplayed:!1,reference:tireRR},brakeFL:{damageDisplayed:!1,reference:brakeFL},brakeFR:{damageDisplayed:!1,reference:brakeFR},brakeRL:{damageDisplayed:!1,reference:brakeRL},brakeRR:{damageDisplayed:!1,reference:brakeRR},brakeOverHeatFL:{damageDisplayed:!1,reference:brakeFL},brakeOverHeatFR:{damageDisplayed:!1,reference:brakeFR},brakeOverHeatRL:{damageDisplayed:!1,reference:brakeRL},brakeOverHeatRR:{damageDisplayed:!1,reference:brakeRR},FL:{damageDisplayed:!1,reference:tireFL},FR:{damageDisplayed:!1,reference:tireFR},RL:{damageDisplayed:!1,reference:tireRL},RR:{damageDisplayed:!1,reference:tireRR}}}),damageTimeout=ref(null),animTimeout=ref(null);onMounted(()=>{$game.events.on(`DamageData`,onDamageData),$game.events.on(`VehicleReset`,onReset),$game.events.on(`VehicleChange`,onReset),$game.events.on(`VehicleFocusChanged`,onVehicleFocusChanged),$game.streams.add(streamsList)}),onUnmounted(()=>{$game.events.off(`DamageData`,onDamageData),$game.events.off(`VehicleReset`,onReset),$game.events.off(`VehicleChange`,onReset),$game.events.off(`VehicleFocusChanged`,onVehicleFocusChanged),$game.streams.remove(streamsList)});function onDamageData(data){for(let type in data)for(let component in data[type]){if(componentDamageMap[type]===void 0||componentDamageMap[type][component]===void 0)continue;let damagedComponent=componentDamage.value[type][component],damageComponentProps=componentDamageMap[type][component];if(!damagedComponent.damageDisplayed&&(data[type][component]===!0||data[type][component]>0)){if(damageComponentProps.priority===1)appState.permanentDamagedParts+=1,clearTimeout(damageTimeout.value),setComponentDamageStyles(damagedComponent.reference,redColor,`flashAnim`);else if(damageComponentProps.priority===0)appState.permanentDamagedParts+=1,clearTimeout(damageTimeout.value),setComponentDamageStyles(damagedComponent.reference,orangeColor,`flashAnim`);else if(damageComponentProps.priority===2){let damageAmount=Math.round(data[type][component]*1e3),bodyColor=`rgba(${150+damageAmount}, ${150-damageAmount}, 0, 0.6)`;setComponentDamageStyles(damagedComponent.reference,bodyColor,``)}appState.hasDamage=!0,damageComponentProps.damageText!==void 0&&(damageTextQueue.value.push(damageComponentProps.damageText),damagedComponent.damageDisplayed=!0)}else damageComponentProps.tempDamage&&(data[type][component]===!0||data[type][component]>0?setComponentDamageStyles(damagedComponent.reference,orangeColor,`flashAnim`):(damagedComponent.damageDisplayed=!1,appState.permanentDamagedParts=-1,setComponentDamageStyles(damagedComponent.reference,noDataColor,``)))}!appState.isAppDisplayed&&appState.hasDamage&&(appState.isAppDisplayed=!0,processDamageText(),appState.permanentDamagedParts===0?showAppTimed():clearTimeout(damageTimeout.value))}function processDamageText(){damageTextQueue.value&&damageTextQueue.value.length>0?(damageContainer.value.style.opacity=1,damageText.value.textContent=damageTextQueue.value[0],damageTextQueue.value.splice(0,1),animTimeout.value=setTimeout(processDamageText,textDisplayTime)):(damageContainer.value.style.opacity=0,damageText.value.textContent=``,clearTimeout(animTimeout.value))}function onReset(){for(let type in componentDamage.value)for(let component in componentDamage.value[type])componentDamage.value[type][component].reference.style.fill=noDataColor;appState.isAppDisplayed=!1,appState.hasDamage=!1,appState.permanentDamagedParts=0,damageTextQueue.value=[],showAppTimed()}function onVehicleFocusChanged(data){data.mode===!0&&onReset()}function showAppTimed(){damageTimeout.value&&clearTimeout(damageTimeout.value),appState.isAppDisplayed=!0,damageTimeout.value=setTimeout(function(){appState.isAppDisplayed=!1},2700)}function setComponentDamageStyles(componentRef,color,anim){componentRef.style.fill=color,anim===``?componentRef.classList=[]:componentRef.classList.add(anim)}return(_ctx,_cache)=>(openBlock(),createElementBlock(`svg`,{ref_key:`svg`,ref:svg,class:`svg-app`,viewBox:`-20 -50 300 527`,style:normalizeStyle({opacity:appState.isAppDisplayed?1:0})},[createBaseVNode(`g`,_hoisted_1$188,[createBaseVNode(`path`,{ref_key:`tireFL`,ref:tireFL,d:`m 40.219516,385.93366 0.0893,-35.49107 c 0,0 0.44642,-5.22322 5.08928,-5.22322 4.64286,0 22.41072,-0.13394 22.41072,-0.13394 0,0 5.44643,-10e-6 5.49107,5.22321 0.0534,6.25041 -0.0447,34.64286 -0.0447,34.64286 l 0.0893,36.25 c 0,0 -0.0446,5.35714 -5.53571,5.44643 -3.12586,0.0508 -21.47322,-10e-6 -21.47322,-10e-6 0,0 -5.98214,10e-6 -6.02678,-5.3125 -0.0375,-4.46412 -0.0893,-35.40178 -0.0893,-35.40178 z`,style:{fill:`none`,"fill-rule":`evenodd`,stroke:`#000000`,"stroke-width":`1px`,"stroke-linecap":`butt`,"stroke-linejoin":`miter`,"stroke-opacity":`1`}},null,512),createBaseVNode(`path`,{style:{fill:`none`,"fill-rule":`evenodd`,stroke:`#000000`,"stroke-width":`1px`,"stroke-linecap":`butt`,"stroke-linejoin":`miter`,"stroke-opacity":`1`},d:`m 212.19799,385.43366 0.0893,-35.49107 c 0,0 0.44642,-5.22322 5.08928,-5.22322 4.64286,0 22.41072,-0.13394 22.41072,-0.13394 0,0 5.44643,-10e-6 5.49107,5.22321 0.0534,6.25041 -0.0447,34.64286 -0.0447,34.64286 l 0.0893,36.25 c 0,0 -0.0446,5.35714 -5.53571,5.44643 -3.12586,0.0508 -21.47322,-10e-6 -21.47322,-10e-6 0,0 -5.98214,10e-6 -6.02678,-5.3125 -0.0375,-4.46412 -0.0893,-35.40178 -0.0893,-35.40178 z`,ref_key:`tireFR`,ref:tireFR},null,512),createBaseVNode(`path`,{ref_key:`tireRR`,ref:tireRR,d:`m 212.19799,654.14795 0.0893,-35.49107 c 0,0 0.44642,-5.22322 5.08928,-5.22322 4.64286,0 22.41072,-0.13394 22.41072,-0.13394 0,0 5.44643,-10e-6 5.49107,5.22321 0.0534,6.25041 -0.0447,34.64286 -0.0447,34.64286 l 0.0893,36.25 c 0,0 -0.0446,5.35714 -5.53571,5.44643 -3.12586,0.0508 -21.47322,-10e-6 -21.47322,-10e-6 0,0 -5.98214,10e-6 -6.02678,-5.3125 -0.0375,-4.46412 -0.0893,-35.40178 -0.0893,-35.40178 z`,style:{fill:`none`,"fill-rule":`evenodd`,stroke:`#000000`,"stroke-width":`1px`,"stroke-linecap":`butt`,"stroke-linejoin":`miter`,"stroke-opacity":`1`}},null,512),createBaseVNode(`path`,{style:{fill:`none`,"fill-rule":`evenodd`,stroke:`#000000`,"stroke-width":`1px`,"stroke-linecap":`butt`,"stroke-linejoin":`miter`,"stroke-opacity":`1`},d:`m 40.219516,654.14795 0.0893,-35.49107 c 0,0 0.44642,-5.22322 5.08928,-5.22322 4.64286,0 22.41072,-0.13394 22.41072,-0.13394 0,0 5.44643,-10e-6 5.49107,5.22321 0.0534,6.25041 -0.0447,34.64286 -0.0447,34.64286 l 0.0893,36.25 c 0,0 -0.0446,5.35714 -5.53571,5.44643 -3.12586,0.0508 -21.47322,-10e-6 -21.47322,-10e-6 0,0 -5.98214,10e-6 -6.02678,-5.3125 -0.0375,-4.46412 -0.0893,-35.40178 -0.0893,-35.40178 z`,ref_key:`tireRL`,ref:tireRL},null,512),createBaseVNode(`path`,{ref_key:`bodyFL`,ref:bodyFL,d:`m 139.30351,268.73244 c 0,0 -20.06962,-0.0115 -32.7295,1.35397 -11.849388,1.27802 -23.33457,5.11217 -35.698872,11.89174 -11.963689,6.55991 -22.259598,16.59274 -27.506842,31.58729 -3.060137,8.74465 -3.902495,25.39725 -3.902495,25.39725 l 9.609942,-0.14814 c 0,0 1.636978,-16.52695 5.208997,-24.93149 3.978738,-9.3615 11.635356,-19.52025 21.213285,-24.53523 10.627835,-5.56471 18.689453,-8.01564 32.759185,-10.2291 11.61143,-1.82671 31.13813,-1.14019 31.13813,-1.14019 z`,style:{fill:`none`,"fill-rule":`evenodd`,stroke:`#000000`,"stroke-width":`1px`,"stroke-linecap":`butt`,"stroke-linejoin":`miter`,"stroke-opacity":`1`}},null,512),createBaseVNode(`path`,{ref_key:`bodyML`,ref:bodyML,d:`m 46.365238,434.85859 c 0,0 -4.37766,0.0905 -6.56641,0.125 -0.0234,2.215 -0.08,17.90873 -0.125,26.86328 0,0 -20.45068,7.80958 -22.22461,10.85938 -1.79329,3.0831 -4.63644,8.09161 -2.46289,8.46094 0,0 25.14091,-3.55661 25.60352,-3.40821 0.0618,2.25563 -0.62153,126.52252 -0.59375,127.77539 1.21285,-0.002 9.6289,0.0312 9.6289,0.0312 l -0.01,-170.70703 z`,style:{fill:`none`,"fill-rule":`evenodd`,stroke:`#000000`,"stroke-width":`1px`,"stroke-linecap":`butt`,"stroke-linejoin":`miter`,"stroke-opacity":`1`}},null,512),createBaseVNode(`path`,{ref_key:`bodyMR`,ref:bodyMR,d:`m 236.6054,434.90159 -0.0117,170.70899 c 0,0 7.91605,-0.0352 9.1289,-0.0332 0.0278,-1.25287 -0.65555,-125.51976 -0.59375,-127.77539 0.46261,-0.1484 25.60352,3.40821 25.60352,3.40821 2.17355,-0.36933 -0.6696,-5.37589 -2.46289,-8.45899 -1.77393,-3.0498 -22.22266,-10.85937 -22.22266,-10.85937 -0.045,-8.95456 -0.10355,-24.64828 -0.12695,-26.86328 -2.18875,-0.0345 -9.31447,-0.12697 -9.31447,-0.12697 z`,style:{fill:`none`,"fill-rule":`evenodd`,stroke:`#000000`,"stroke-width":`1px`,"stroke-linecap":`butt`,"stroke-linejoin":`miter`,"stroke-opacity":`1`}},null,512),createBaseVNode(`path`,{ref_key:`driveShaft`,ref:driveShaft,d:`m 146.88019,519.13977 0.34682,-126.1992 c 0,0 14.81582,-18.06715 -4.26439,-17.94569 -19.92,0.12681 -4.95719,17.95354 -4.95719,17.95354 l 0.0408,126.25385 c -0.48292,33.8145 0.52349,126.53492 0.52349,126.53492 -3.70809,6.93305 -6.96405,16.59296 4.6368,16.4848 11.45601,-0.10682 8.66714,-8.10662 4.65438,-16.55312 -1.97544,-4.15814 -0.98066,-126.5291 -0.98066,-126.5291 z`,style:{fill:`none`,"fill-rule":`evenodd`,stroke:`#000000`,"stroke-width":`0.99999976`,"stroke-linecap":`butt`,"stroke-linejoin":`miter`,"stroke-miterlimit":`4`,"stroke-dasharray":`none`,"stroke-opacity":`1`}},null,512),createBaseVNode(`path`,{ref_key:`engine`,ref:engine,d:`m 122.07373,314.95322 h 33.63152 v 5.9272 h -13.25677 v 5.34505 h 12.93926 l 6.08594,9.31416 h 5.37155 v 4.97461 h 6.00656 v -5.05399 h 8.22927 c 0,0 2.66605,2.98563 3.2282,4.8423 1.71505,5.66443 1.56492,12.04739 0,17.75512 -0.61276,2.23494 -3.54572,5.98011 -3.54572,5.98011 h -7.93821 v -5.39797 h -6.29763 v 11.32517 h -34.98103 l -6.50934,-7.93822 H 113.0771 v -16.51145 h -5.98011 v 15.87643 h -5.1863 v -28.89508 h 4.97462 v 7.62066 h 6.29764 v -7.72651 h 8.99664 v -5.98013 h 14.12999 v -6.19179 h -14.23585 z`,style:{display:`inline`,fill:`none`,"fill-rule":`evenodd`,stroke:`#000000`,"stroke-width":`1.00000012`,"stroke-linecap":`butt`,"stroke-linejoin":`miter`,"stroke-miterlimit":`4`,"stroke-dasharray":`none`,"stroke-opacity":`1`}},null,512),createBaseVNode(`path`,{d:`m 117.17264,721.33809 -7.7414,-9.05075 c 0,0 -1.6874,1.50785 -2.481,2.29715 -0.685,0.6814 -1.3051,1.5911 0.2757,3.6525 0.5444,0.7098 3.2227,3.9338 3.7903,4.5024 1.6325,1.6355 2.5754,1.6201 3.3309,1.0108 0.9517,-0.7675 2.8255,-2.4121 2.8255,-2.4121 z m -5.4902,-9.02777 c -0.2639,-0.33031 -0.3782,-0.42184 0.023,-0.78103 0.2875,-0.31046 1.9506,-1.87788 2.2512,-2.13637 0.2218,-0.19078 0.3561,-0.42492 0.1149,-0.7236 -0.2412,-0.33308 -2.1908,-2.68012 -2.4982,-3.06097 -0.2198,-0.27232 -0.2732,-0.32108 -0.2732,-0.50554 0,-0.75917 0.011,-34.43177 0.015,-35.00437 0,-0.2149 0.056,-0.3086 0.5162,-0.3086 h 51.67845 c 2.0683,0 3.0251,0.3486 4.3679,1.4435 1.1871,0.9678 2.1659,2.0917 2.17,4.6095 0,0 0.065,37.07605 0.065,38.41705 0,1.2398 -0.1967,4.1364 -1.6325,5.5294 -1.0614,1.0299 -3.8532,1.8924 -4.9438,1.8924 -1.5414,0 -37.80368,-0.016 -38.25553,-0.016 -0.32906,0 -0.70707,-0.079 -0.93514,-0.3163 -0.27185,-0.2826 -2.9151,-3.0777 -3.22317,-3.371 -0.15862,-0.151 -0.25989,-0.4548 -0.64972,-0.097 -0.3899,0.3574 -1.73649,1.4573 -2.04669,1.7218 -0.1403,0.1197 -0.2841,0.2357 -0.5523,-0.032 -0.4136,-0.4769 -5.8261,-6.80285 -6.191,-7.25968 z m 20.26835,-10.96158 c -0.003,-4.55255 -0.0326,-8.19817 0,-12.74562 0,-0.7695 -0.32724,-0.97794 -1.30987,-1.85445 -0.76302,-0.68063 -1.41614,-1.23286 -1.90915,-1.69336 -0.36587,-0.34178 -0.85706,-0.80537 -0.84008,-1.1791 0.0258,-0.56967 0.59396,-1.0422 0.93428,-1.21472 0.54578,-0.27667 0.94727,-0.0528 1.23375,0.23366 0.30382,0.30381 1.84818,1.77993 2.58906,2.39496 0.44759,0.37156 0.58562,0.67733 1.67741,0.67733 5.46749,-0.0217 12.23023,-0.18415 18.32732,0 1.09189,0 1.22992,-0.30577 1.67737,-0.67733 0.74089,-0.61503 2.28521,-2.09115 2.58911,-2.39496 0.2865,-0.28643 0.688,-0.51033 1.2338,-0.23366 0.3404,0.17252 0.9085,0.64505 0.9344,1.21472 0.017,0.37373 -0.4743,0.83732 -0.8402,1.1791 -0.493,0.4605 -1.1461,1.01273 -1.909,1.69336 -0.98279,0.87651 -1.30997,1.08495 -1.30997,1.85445 0,4.55255 0.0323,8.19817 0,12.74562 0,0.76951 0.32718,0.97793 1.30997,1.85447 0.7629,0.68062 1.416,1.23285 1.909,1.69335 0.3659,0.34177 0.857,0.80537 0.8402,1.1791 -0.026,0.56967 -0.594,1.04219 -0.9344,1.21472 -0.5458,0.27667 -0.9473,0.0528 -1.2338,-0.23366 -0.3039,-0.30382 -1.84822,-1.77992 -2.58911,-2.39497 -0.44745,-0.37154 -0.58548,-0.67731 -1.67737,-0.67731 -6.55155,0.019 -11.82218,0.18501 -18.32732,0 -1.09179,0 -1.22982,0.30577 -1.67741,0.67731 -0.74088,0.61505 -2.28524,2.09115 -2.58906,2.39497 -0.28648,0.28644 -0.68797,0.51033 -1.23375,0.23366 -0.34032,-0.17253 -0.90842,-0.64505 -0.93428,-1.21472 -0.017,-0.37373 0.47421,-0.83733 0.84008,-1.1791 0.49301,-0.4605 1.14613,-1.01273 1.90915,-1.69335 0.98263,-0.87654 1.30987,-1.08496 1.30987,-1.85447 z m 2.56799,-10.35082 c 0,2.40538 0,5.36454 0,8.01339 0,0.63296 -0.0236,1.4238 0.45482,1.90048 0.45132,0.44967 1.08277,0.42233 1.81926,0.42233 h 13.2426 c 0.7365,0 1.36798,0.0273 1.81926,-0.42233 0.47837,-0.47668 0.45477,-1.26752 0.45477,-1.90048 v -3.94714 c 0,-1.35542 0,-2.71084 0,-4.06625 0,-0.63296 0.0233,-1.42381 -0.45477,-1.90047 -0.45128,-0.44969 -1.08276,-0.42234 -1.81926,-0.42234 h -13.2426 c -0.73649,0 -1.36794,-0.0273 -1.81926,0.42234 -0.47842,0.47666 -0.45482,1.26751 -0.45482,1.90047 z`,style:{fill:`none`,"fill-opacity":`1`,"fill-rule":`evenodd`,stroke:`#000000`,"stroke-width":`1.00000012`,"stroke-linecap":`butt`,"stroke-linejoin":`miter`,"stroke-miterlimit":`4`,"stroke-dasharray":`none`,"stroke-opacity":`1`},ref_key:`fueltank`,ref:fueltank},null,512),createBaseVNode(`path`,{d:`m 162.19586,303.74311 v 1.62868 c 0,0 -0.0239,0.60243 0.40384,0.86252 0.36641,0.22282 3.17759,0.31545 3.59707,-0.042 0.34847,-0.29691 0.34658,-0.78069 0.34658,-0.78069 v -4.32093 c 0,0 -0.004,-0.63642 -0.53018,-0.91858 -0.27049,-0.14492 -2.81926,2.15048 -3.22871,2.49847 -0.49791,0.42318 -0.5886,0.94557 -0.5886,0.94557 z m -8.74296,-2.37979 v 4.00847 c 0,0 -0.0239,0.60243 0.40383,0.86252 0.36641,0.22282 3.17759,0.31545 3.59708,-0.042 0.34846,-0.29691 0.34657,-0.78069 0.34657,-0.78069 v -3.43014 c 0,0 -0.004,-0.63642 -0.53018,-0.91857 -0.27049,-0.14493 -2.94617,-0.75348 -3.2287,-0.64521 -0.61019,0.23381 -0.5886,0.94557 -0.5886,0.94557 z m -8.57375,1.15667 v 2.8518 c 0,0 -0.0239,0.60243 0.40383,0.86252 0.36641,0.22282 3.17759,0.31545 3.59708,-0.042 0.34846,-0.29691 0.34657,-0.78069 0.34657,-0.78069 v -3.78911 c 0,0 -0.002,-0.37799 -0.24416,-0.68051 -0.072,-0.09 -0.16527,-0.17335 -0.28602,-0.23806 -0.27049,-0.14492 -2.94617,0.76217 -3.2287,0.87043 -0.61019,0.23381 -0.5886,0.94557 -0.5886,0.94557 z m -8.63016,2.23357 v 0.61823 c 0,0 -0.0239,0.60243 0.40383,0.86252 0.36642,0.22282 3.17759,0.31545 3.59707,-0.042 0.34847,-0.29691 0.34658,-0.78069 0.34658,-0.78069 v -1.35611 c 0,0 -0.004,-0.63641 -0.53017,-0.91857 -0.2705,-0.14492 -2.94617,0.56274 -3.22871,0.671 -0.61019,0.23381 -0.5886,0.94557 -0.5886,0.94557 z m -8.50835,1.48075 c 0.36641,0.22282 3.17758,0.31545 3.59707,-0.042 0.34847,-0.29691 0.34658,-0.50066 0.34658,-0.50066 0,0 -0.004,-1.03528 -0.53018,-1.31744 -0.27049,-0.14492 -2.94617,-0.0851 -3.22871,0.0232 -0.61018,0.23381 -0.5886,1.10014 -0.5886,1.10014 0,0 -0.0239,0.47668 0.40384,0.73676 z m -9.0904,-2.1588 v 1.29628 c 0,0 -0.0239,0.60243 0.40383,0.86252 0.36642,0.22282 3.17759,0.31545 3.59707,-0.042 0.34847,-0.29691 0.34658,-0.78069 0.34658,-0.78069 v -0.5584 c 0,0 -0.004,-0.63642 -0.53017,-0.91858 -0.2705,-0.14492 -2.94617,-0.91301 -3.22871,-0.80474 -0.61019,0.23381 -0.5886,0.94556 -0.5886,0.94556 z m 52.345,1.37742 v -16.61221 c 0,0 -0.0239,-0.60242 0.40383,-0.86252 0.36642,-0.22281 3.17759,-0.31544 3.59707,0.042 0.34847,0.29692 0.34658,0.78069 0.34658,0.78069 v 16.63216 c 0,0 -0.004,0.63642 -0.53017,0.91857 -0.2705,0.14493 -2.94617,0.1552 -3.22871,0.0469 -0.61019,-0.23381 -0.5886,-0.94556 -0.5886,-0.94556 z m -8.79938,-16.61221 c 0,0 -0.0239,-0.60242 0.40384,-0.86252 0.36641,-0.22281 3.17759,-0.31544 3.59707,0.042 0.34847,0.29692 0.34658,0.78069 0.34658,0.78069 v 3.32029 c 0,0 -0.004,0.63641 -0.53018,0.91857 -0.27049,0.14492 -2.60773,-2.10106 -3.22871,-2.63237 -0.4965,-0.42482 -0.5886,-0.97378 -0.5886,-0.97378 z m -8.74296,0 c 0,0 -0.0239,-0.60242 0.40383,-0.86252 0.36641,-0.22281 3.17759,-0.31544 3.59708,0.042 0.34846,0.29692 0.34657,0.78069 0.34657,0.78069 v 1.74529 c 0,0 -0.004,0.63642 -0.53018,0.91857 -0.27049,0.14493 -2.94617,-0.12683 -3.2287,-0.2351 -0.61019,-0.23381 -0.5886,-0.77636 -0.5886,-0.77636 z m -8.57375,0 c 0,0 -0.0239,-0.60242 0.40383,-0.86252 0.36641,-0.22281 3.17759,-0.31544 3.59708,0.042 0.34846,0.29692 0.34657,0.78069 0.34657,0.78069 v 1.80688 c 0,0 -0.002,0.378 -0.24416,0.68052 -0.072,0.09 -0.16527,0.17335 -0.28602,0.23805 -0.27049,0.14493 -2.94617,1.1141 -3.2287,1.00584 -0.61019,-0.23381 -0.5886,-0.81866 -0.5886,-0.81866 z m -8.63016,0 c 0,0 -0.0239,-0.60242 0.40383,-0.86252 0.36642,-0.22281 3.17759,-0.31544 3.59707,0.042 0.34847,0.29692 0.34658,0.78069 0.34658,0.78069 v 4.46516 c 0,0 -0.004,0.63641 -0.53017,0.91857 -0.2705,0.14493 -2.94617,0.97309 -3.22871,0.86482 -0.61019,-0.23381 -0.6027,-0.81866 -0.6027,-0.81866 z m -8.91219,0 c 0,0 -0.0239,-0.60242 0.40384,-0.86252 0.36641,-0.22281 3.17758,-0.31544 3.59707,0.042 0.34847,0.29692 0.34658,0.78069 0.34658,0.78069 v 6.04004 c 0,0 -0.004,0.63641 -0.53018,0.91857 -0.27049,0.14493 -2.94617,-0.0986 -3.22871,-0.2069 -0.61018,-0.23381 -0.5886,-0.90327 -0.5886,-0.90327 z m -8.68656,4.20791 v -4.20791 c 0,0 -0.0239,-0.60242 0.40383,-0.86252 0.36642,-0.22281 3.17759,-0.31544 3.59707,0.042 0.34847,0.29692 0.34658,0.78069 0.34658,0.78069 v 4.90473 c 0,0 -0.004,0.63641 -0.53017,0.91857 -0.2705,0.14492 -2.94617,-0.52168 -3.22871,-0.62994 -0.61019,-0.23382 -0.5886,-0.94557 -0.5886,-0.94557 z m 0.0383,3.38266 0.0424,3.80682 c 4.76147,1.58463 12.44208,1.37115 18.62715,0.76876 4.9084,-0.47805 9.46499,-3.13968 14.38678,-3.45098 2.56844,-0.16246 7.67481,0.84058 7.67481,0.84058 l 0.018,4.52569 c 0,0 4.30181,-3.85868 6.85434,-6.08209 0.23182,-0.21672 0.26026,-0.28202 -0.0588,-0.61036 -2.4793,-2.37833 -6.8878,-6.08125 -6.8878,-6.08125 l 0.0141,4.90206 c 0,0 -5.19129,-1.89571 -12.24908,-0.16859 -3.96245,1.32729 -6.76872,2.21825 -10.27188,2.769 -2.7191,0.42749 -5.4997,0.55723 -8.24775,0.4009 -3.33921,-0.18995 -6.69491,-0.50286 -9.90211,-1.62054 z m -15.25121,10.1713 c 0,0.39543 -0.18036,1.62226 1.45209,3.25472 1.40638,1.19302 2.9727,1.1712 3.41028,1.1712 23.19944,0.0992 44.97243,0.0226 68.7019,0 0.43758,0 2.0039,0.0218 3.41029,-1.1712 1.63245,-1.63246 1.45208,-2.85929 1.45208,-3.25472 0.12422,-16.06162 0.0264,-3.05893 0,-19.25937 0,-0.39543 0.18037,-1.62225 -1.45208,-3.25471 -1.40639,-1.19302 -2.97271,-1.1712 -3.41029,-1.1712 -23.19944,-0.0992 -44.97243,-0.0226 -68.7019,0 -0.43758,0 -2.0039,-0.0218 -3.41028,1.1712 -1.63245,1.63246 -1.45209,2.85928 -1.45209,3.25471 -0.11802,17.21566 -0.0338,3.97954 0,19.25937 z m 1.90997,-17.51991 c 0,-0.36657 -0.12323,-2.09175 1.14118,-3.35617 1.05214,-0.89259 3.06543,-0.74668 3.48144,-0.74668 22.55947,-0.021 43.30609,-0.0919 65.36168,0 1.3185,0 2.52269,-0.19776 3.66518,0.74727 1.05732,1.05732 0.95743,2.19932 0.95743,3.35558 0.0252,15.01782 0.11812,0.8913 0,15.78046 0,1.5229 -0.0428,2.46913 -0.90102,3.32738 -1.06456,0.88061 -2.31847,0.77547 -3.72159,0.77547 -22.55947,0.021 -43.30609,0.0919 -65.36168,0 -1.7721,0 -2.45712,0.11664 -3.44156,-0.68686 -1.36393,-1.36393 -1.18106,-1.95258 -1.18106,-3.41599 0.12429,-15.20955 -0.092,-2.68107 0,-15.78046 z m 4.56001,16.37025 v -16.61221 c 0,0 -0.0239,-0.60242 0.40383,-0.86252 0.36641,-0.22281 3.1776,-0.31544 3.59708,0.042 0.34846,0.29692 0.34658,0.78069 0.34658,0.78069 v 16.63216 c 0,0 -0.004,0.63642 -0.53019,0.91857 -0.27048,0.14493 -2.94617,0.1552 -3.2287,0.0469 -0.61019,-0.23381 -0.5886,-0.94556 -0.5886,-0.94556 z`,style:{display:`inline`,fill:`none`,"fill-opacity":`1`,"fill-rule":`evenodd`,stroke:`#000000`,"stroke-width":`0.75000012`,"stroke-linecap":`butt`,"stroke-linejoin":`miter`,"stroke-miterlimit":`4`,"stroke-dasharray":`none`,"stroke-opacity":`1`},ref_key:`radiator`,ref:radiator},null,512),createBaseVNode(`path`,{ref_key:`wheelaxleFL`,ref:wheelaxleFL,d:`m 91.691145,389.0121 c 0,0 -2.43068,0.29676 -2.43068,-4.28053 0,-4.0406 2.22866,-4.30576 2.22866,-4.30576 9.222155,-0.11908 21.694875,-0.0585 30.917405,-0.0594 3.70837,-9.1e-4 6.85841,-0.28274 8.24298,0.90893 0.51207,0.44072 0.75871,1.92799 1.01166,3.17533 0.35371,1.74427 0.74974,2.96105 0.32477,3.71154 -0.50969,0.90009 -2.57006,0.96141 -2.57006,0.96141 -11.49186,0.003 -26.23329,-0.0229 -37.724735,-0.11152 z`,style:{display:`inline`,opacity:`1`,fill:`none`,"fill-rule":`evenodd`,stroke:`#000000`,"stroke-width":`1px`,"stroke-linecap":`butt`,"stroke-linejoin":`miter`,"stroke-opacity":`1`}},null,512),createBaseVNode(`path`,{style:{display:`inline`,opacity:`1`,fill:`none`,"fill-rule":`evenodd`,stroke:`#000000`,"stroke-width":`1px`,"stroke-linecap":`butt`,"stroke-linejoin":`miter`,"stroke-opacity":`1`},d:`m 193.49174,389.0121 c 0,0 2.43068,0.29676 2.43068,-4.28053 0,-4.0406 -2.22865,-4.30576 -2.22865,-4.30576 -9.22216,-0.11908 -21.44488,-0.0585 -30.66742,-0.0594 -3.70837,-9.1e-4 -6.85841,-0.28274 -8.24298,0.90893 -0.51207,0.44072 -0.75871,1.92799 -1.01166,3.17533 -0.35371,1.74427 -0.74974,2.96105 -0.32477,3.71154 0.50969,0.90009 2.57006,0.96141 2.57006,0.96141 11.49186,0.003 25.98329,-0.0229 37.47474,-0.11152 z`,ref_key:`wheelaxleFR`,ref:wheelaxleFR},null,512),createBaseVNode(`path`,{ref_key:`brakeFR`,ref:brakeFR,d:`m 210.35279,373.43366 h -5.22322 l -0.0446,-11.25 c 0,0 -0.0446,-1.02679 -1.51786,-1.16071 -0.91518,-0.15626 -3.83928,-0.067 -3.83928,-0.067 0,0 -2.04238,-0.11866 -2.0759,1.22768 -0.0626,2.51339 -0.0446,47.43304 -0.0446,47.43304 0,0 -0.0431,1.36663 1.7634,1.40625 1.21935,0.0262 3.83928,0.005 3.83928,0.005 0,0 1.86958,0.12132 1.96428,-1.61256 0.073,-1.33729 -0.0207,-10.46221 -0.0207,-10.46221 l 5.24395,-0.12581 z`,style:{display:`inline`,opacity:`1`,fill:`none`,"fill-opacity":`1`,"fill-rule":`evenodd`,stroke:`#000000`,"stroke-width":`1px`,"stroke-linecap":`butt`,"stroke-linejoin":`miter`,"stroke-opacity":`1`}},null,512),createBaseVNode(`path`,{ref_key:`brakeFL`,ref:brakeFL,d:`m 74.826658,373.43366 h 5.22322 l 0.0446,-11.25 c 0,0 0.0446,-1.02679 1.51786,-1.16071 0.91518,-0.15626 3.83928,-0.067 3.83928,-0.067 0,0 2.04238,-0.11866 2.0759,1.22768 0.0626,2.51339 0.0446,47.43304 0.0446,47.43304 0,0 0.0431,1.36663 -1.7634,1.40625 -1.21935,0.0262 -3.83928,0.005 -3.83928,0.005 0,0 -1.86958,0.12132 -1.96428,-1.61256 -0.073,-1.33729 0.0207,-10.46221 0.0207,-10.46221 l -5.24395,-0.12581 z`,style:{display:`inline`,opacity:`1`,fill:`none`,"fill-opacity":`1`,"fill-rule":`evenodd`,stroke:`#000000`,"stroke-width":`1px`,"stroke-linecap":`butt`,"stroke-linejoin":`miter`,"stroke-opacity":`1`}},null,512),createBaseVNode(`path`,{style:{fill:`none`,"fill-rule":`evenodd`,stroke:`#000000`,"stroke-width":`1px`,"stroke-linecap":`butt`,"stroke-linejoin":`miter`,"stroke-opacity":`1`},d:`m 145.98404,268.73244 c 0,0 19.06962,-0.0115 31.7295,1.35397 11.84939,1.27802 23.33457,5.11217 35.69887,11.89174 11.96369,6.55991 22.2596,16.59274 27.50684,31.58729 3.06014,8.74465 3.9025,25.39725 3.9025,25.39725 l -9.60995,-0.14814 c 0,0 -1.63697,-16.52695 -5.20899,-24.93149 -3.97874,-9.3615 -11.63536,-19.52025 -21.21329,-24.53523 -10.62783,-5.56471 -18.68945,-8.01564 -32.75918,-10.2291 -11.61143,-1.82671 -30.13813,-1.14019 -30.13813,-1.14019 z`,ref_key:`bodyFR`,ref:bodyFR},null,512),createBaseVNode(`path`,{style:{fill:`none`,"fill-rule":`evenodd`,stroke:`#000000`,"stroke-width":`1.00000012`,"stroke-linecap":`butt`,"stroke-linejoin":`miter`,"stroke-miterlimit":`4`,"stroke-dasharray":`none`,"stroke-opacity":`1`},d:`m 139.36946,758.05809 c 0,0 -20.14699,0.01 -32.81319,-1.1024 -11.855294,-1.0405 -23.346203,-4.162 -35.716671,-9.6818 -11.969654,-5.3407 -20.679708,-11.5646 -25.929569,-23.7724 -3.061663,-7.1197 -5.495432,-24.34913 -5.495432,-24.34913 l 9.614735,0.12066 c 0,0 1.637794,15.18257 5.211595,22.02527 3.980722,7.6218 11.817934,15.0086 21.40064,19.0916 10.633134,4.5306 18.345219,5.9957 32.421962,7.798 11.61723,1.487 31.39781,0.9282 31.39781,0.9282 z`,ref_key:`bodyRL`,ref:bodyRL},null,512),createBaseVNode(`path`,{ref_key:`bodyRR`,ref:bodyRR,d:`m 145.99795,758.05809 c 0,0 19.59077,0.01 32.25697,-1.1024 11.8553,-1.0405 23.34621,-4.162 35.71668,-9.6818 11.96965,-5.3407 20.67971,-11.5646 25.92957,-23.7724 3.06166,-7.1197 5.49543,-24.34913 5.49543,-24.34913 l -9.61473,0.12066 c 0,0 -1.6378,15.18257 -5.2116,22.02527 -3.98072,7.6218 -11.81793,15.0086 -21.40064,19.0916 -10.63314,4.5306 -18.34522,5.9957 -32.42197,7.798 -11.61723,1.487 -30.84159,0.9282 -30.84159,0.9282 z`,style:{fill:`none`,"fill-rule":`evenodd`,stroke:`#000000`,"stroke-width":`1.00000012`,"stroke-linecap":`butt`,"stroke-linejoin":`miter`,"stroke-miterlimit":`4`,"stroke-dasharray":`none`,"stroke-opacity":`1`}},null,512),createBaseVNode(`path`,{style:{display:`inline`,opacity:`1`,fill:`none`,"fill-rule":`evenodd`,stroke:`#000000`,"stroke-width":`1.00000012`,"stroke-linecap":`butt`,"stroke-linejoin":`miter`,"stroke-miterlimit":`4`,"stroke-dasharray":`none`,"stroke-opacity":`1`},d:`m 75.326658,641.12409 h 5.22322 l 0.0446,-11.25 c 0,0 0.0446,-1.02679 1.51786,-1.16071 0.91518,-0.15626 3.83928,-0.067 3.83928,-0.067 0,0 2.04238,-0.11866 2.0759,1.22768 0.0626,2.51339 0.0446,47.43304 0.0446,47.43304 0,0 0.0431,1.36663 -1.7634,1.40625 -1.21935,0.0262 -3.83928,0.005 -3.83928,0.005 0,0 -1.86958,0.12132 -1.96428,-1.61256 -0.073,-1.33729 0.0207,-10.46221 0.0207,-10.46221 l -5.24395,-0.12581 z`,ref_key:`brakeRL`,ref:brakeRL},null,512),createBaseVNode(`path`,{ref_key:`brakeRR`,ref:brakeRR,d:`m 209.87792,642.37917 h -5.22322 l -0.0446,-11.25 c 0,0 -0.0446,-1.02679 -1.51786,-1.16071 -0.91518,-0.15626 -3.83928,-0.067 -3.83928,-0.067 0,0 -2.04238,-0.11866 -2.0759,1.22768 -0.0626,2.51339 -0.0446,47.43304 -0.0446,47.43304 0,0 -0.0431,1.36663 1.7634,1.40625 1.21935,0.0262 3.83928,0.005 3.83928,0.005 0,0 1.86958,0.12132 1.96428,-1.61256 0.073,-1.33729 -0.0207,-10.46221 -0.0207,-10.46221 l 5.24395,-0.12581 z`,style:{display:`inline`,opacity:`1`,fill:`none`,"fill-rule":`evenodd`,stroke:`#000000`,"stroke-width":`1.00000012`,"stroke-linecap":`butt`,"stroke-linejoin":`miter`,"stroke-miterlimit":`4`,"stroke-dasharray":`none`,"stroke-opacity":`1`}},null,512),createBaseVNode(`path`,{style:{display:`inline`,opacity:`1`,fill:`none`,"fill-rule":`evenodd`,stroke:`#000000`,"stroke-width":`1.00000012`,"stroke-linecap":`butt`,"stroke-linejoin":`miter`,"stroke-miterlimit":`4`,"stroke-dasharray":`none`,"stroke-opacity":`1`},d:`m 92.206308,649.46453 c 0,0 -2.43068,-0.29676 -2.43068,4.28053 0,4.0406 2.22866,4.30576 2.22866,4.30576 9.222162,0.11908 21.444882,0.0585 30.667412,0.0594 3.70837,9.1e-4 8.80295,0.28274 10.18752,-0.90893 0.51207,-0.44072 0.6941,-2.38196 0.90117,-3.66147 0.26289,-1.62435 0.42635,-2.41047 0.26953,-3.25855 -0.21138,-1.14316 -2.40433,-0.92826 -2.40433,-0.92826 -12.14004,-6.2e-4 -27.27967,0.0179 -39.419282,0.11152 z`,ref_key:`wheelaxleRL`,ref:wheelaxleRL},null,512),createBaseVNode(`path`,{ref_key:`wheelaxleRR`,ref:wheelaxleRR,d:`m 192.84519,649.46453 c 0,0 2.43068,-0.29676 2.43068,4.28053 0,4.0406 -2.22866,4.30576 -2.22866,4.30576 -9.22216,0.11908 -20.31988,0.0585 -29.54242,0.0594 -3.70837,9.1e-4 -8.80295,0.28274 -10.18752,-0.90893 -0.51207,-0.44072 -0.6941,-2.38196 -0.90117,-3.66147 -0.26289,-1.62435 -0.42635,-2.41047 -0.26953,-3.25855 0.21138,-1.14316 2.40433,-0.92826 2.40433,-0.92826 12.14004,-6.2e-4 26.15468,0.0179 38.29429,0.11152 z`,style:{display:`inline`,opacity:`1`,fill:`none`,"fill-rule":`evenodd`,stroke:`#000000`,"stroke-width":`1.00000012`,"stroke-linecap":`butt`,"stroke-linejoin":`miter`,"stroke-miterlimit":`4`,"stroke-dasharray":`none`,"stroke-opacity":`1`}},null,512),createBaseVNode(`g`,{style:{opacity:`0`},ref_key:`damageContainer`,ref:damageContainer},[createBaseVNode(`rect`,{style:{opacity:`0.77399998`,fill:`#3e3e3e`,"stroke-width":`1.99999893`,"stroke-miterlimit":`4`,"stroke-dasharray":`none`,"stroke-dashoffset":`0`},ref_key:`damageBox`,ref:damageBox,width:`206.75557`,height:`28.991379`,x:`39.481575`,y:`234.25491`},null,512),_cache[0]||=createBaseVNode(`path`,{style:{opacity:`1`,fill:`none`,stroke:`#ffffff`,"stroke-width":`1.99999893`,"stroke-linecap":`butt`,"stroke-linejoin":`miter`,"stroke-miterlimit":`4`,"stroke-dasharray":`none`,"stroke-opacity":`1`},d:`m 39.48159,263.2463 206.75556,-2e-5`},null,-1),createBaseVNode(`text`,_hoisted_2$153,[createBaseVNode(`tspan`,{ref_key:`damageText`,ref:damageText,style:{"text-align":`center`,"text-anchor":`middle`,fill:`#ffffff`},y:`255.49614`,x:`142.73175`},` Driveshaft Broken `,512)])],512)])],4))}},app_default$9=__plugin_vue_export_helper_default(_sfc_main$210,[[`__scopeId`,`data-v-f6aa177d`]]),_hoisted_1$187={class:`timeslip`,id:`slip`},_hoisted_2$152={class:`paper`},_hoisted_3$136={class:`header`},_hoisted_4$113={class:`table-wrapper`},_hoisted_5$98={class:`custom-table`},_hoisted_6$81={class:`left-align`},_hoisted_7$69={class:`right-align`},_hoisted_8$56={class:`right-align`},_hoisted_9$50={key:0},_hoisted_10$43={class:`right-align`},_hoisted_11$38={class:`right-align`},_hoisted_12$28={class:`header`},_hoisted_13$25={class:`left`},_hoisted_14$24={class:`right`},_hoisted_15$23={class:`name`},_hoisted_16$23={key:0,class:`rewards`},_hoisted_17$18={class:`reward`},_hoisted_18$16={class:`header`},_hoisted_19$13={key:0},_sfc_main$209={__name:`Timeslip`,props:{slip:Object},setup(__props){let{units}=useBridge(),props=__props,TIMER_ROWS_INFO=[{key:`laneName`,label:`Lane`},{key:null,label:``},{key:`dial`,label:`DIAL`},{key:`reactionTime`,label:`R/T`},{key:`time_60`,label:`60'`},{key:`time_330`,label:`330'`},{key:`time_1_8`,label:`1/8`},{key:`velAt_1_8_kmh`,label:`KM/H`},{key:`velAt_1_8_mph`,label:`MPH`},{key:`time_1000`,label:`1000'`},{key:`time_1_4`,label:`1/4`},{key:`velAt_1_4_kmh`,label:`KM/H`},{key:`velAt_1_4_mph`,label:`MPH`},{key:`dialDiff`,label:`DIFF`}],getRacerByLane=laneNum=>props.slip.racerInfos.find(racer=>racer.laneNum===laneNum),getTimerValue=(laneNum,timerKey)=>{let racer=getRacerByLane(laneNum);if(!racer)return`-`;if(timerKey===null)return``;if(timerKey===`laneName`)return racer.lane||`-`;if(timerKey===`dial`){if(props.slip.dragType!==`bracketRace`)return`-`;let racer$1=getRacerByLane(laneNum);if(!racer$1)return`-`;let value=racer$1.timers.dial;if(value==null)return`-`;let num=parseFloat(value);return isNaN(num)?`-`:num.toFixed(3)}if(timerKey===`dialDiff`){if(props.slip.dragType!==`bracketRace`)return`-`;let racer$1=getRacerByLane(laneNum);if(!racer$1)return`-`;let value=racer$1.dialDiff;return value==null?`-`:formatDialDiff(value)}if(timerKey.includes(`velAt_`)){if(timerKey.includes(`_kmh`)){let baseKey=timerKey.replace(`_kmh`,``);return racer.velocities[baseKey+`_km/h`]||`-`}else if(timerKey.includes(`_mph`)){let baseKey=timerKey.replace(`_mph`,``);return racer.velocities[baseKey+`_mph`]||`-`}}return racer.timers[timerKey]||`-`},formatDialDiff=value=>{if(value===`-`)return`-`;let num=parseFloat(value);return isNaN(num)?`-`:(num>0?`+`:``)+num.toFixed(3)},getWinnerResult=laneNum=>{let racer=getRacerByLane(laneNum);if(!racer)return`-`;if(racer.disqualification)return`DQ`;if(props.slip.racerInfos.length===1)return`-`;let otherRacer=getRacerByLane(laneNum===1?2:1);if(!otherRacer)return`-`;if(otherRacer.disqualification)return`WINNER`;if(props.slip.dragType===`bracketRace`){let thisDiff=parseFloat(racer.dialDiff),otherDiff=parseFloat(otherRacer.dialDiff);return thisDiff===otherDiff?`TIE`:thisDiff>0&&otherDiff>0?thisDiffotherDiff?`WINNER`:`Break Out`}else{let thisTime=parseFloat(racer.finalTime),otherTime=parseFloat(otherRacer.finalTime);return thisTime>otherTime?`+${(thisTime-otherTime).toFixed(3)}`:`WINNER`}};return(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$187,[_cache[3]||=createBaseVNode(`div`,{class:`rip reverse top`},null,-1),createBaseVNode(`div`,_hoisted_2$152,[createBaseVNode(`div`,_hoisted_3$136,[(openBlock(!0),createElementBlock(Fragment,null,renderList(__props.slip.stripInfo,info=>(openBlock(),createElementBlock(`div`,{key:info},toDisplayString(_ctx.$tt(info)),1))),128))]),createBaseVNode(`div`,_hoisted_4$113,[createBaseVNode(`table`,_hoisted_5$98,[createBaseVNode(`tbody`,null,[(openBlock(),createElementBlock(Fragment,null,renderList(TIMER_ROWS_INFO,(rowInfo,rowIndex)=>createBaseVNode(`tr`,{key:`timer-`+rowIndex,class:normalizeClass({"quarter-mile-row":rowInfo.key===`time_1_4`})},[createBaseVNode(`td`,_hoisted_6$81,toDisplayString(rowInfo.label),1),createBaseVNode(`td`,_hoisted_7$69,toDisplayString(getTimerValue(2,rowInfo.key)),1),createBaseVNode(`td`,_hoisted_8$56,toDisplayString(getTimerValue(1,rowInfo.key)),1)],2)),64)),__props.slip.racerInfos.length>1?(openBlock(),createElementBlock(`tr`,_hoisted_9$50,[_cache[0]||=createBaseVNode(`td`,{class:`left-align`},null,-1),createBaseVNode(`td`,_hoisted_10$43,toDisplayString(getWinnerResult(2)),1),createBaseVNode(`td`,_hoisted_11$38,toDisplayString(getWinnerResult(1)),1)])):createCommentVNode(``,!0)])])]),(openBlock(!0),createElementBlock(Fragment,null,renderList(__props.slip.racerInfos,racer=>(openBlock(),createElementBlock(`div`,{key:racer.name,class:`racer`},[createBaseVNode(`div`,_hoisted_12$28,[createBaseVNode(`div`,_hoisted_13$25,toDisplayString(racer.lane),1),createBaseVNode(`div`,_hoisted_14$24,toDisplayString(racer.licenseText),1)]),createBaseVNode(`div`,_hoisted_15$23,toDisplayString(racer.name),1),Object.keys(racer.rewards).length===0?createCommentVNode(``,!0):(openBlock(),createElementBlock(`div`,_hoisted_16$23,[_cache[1]||=createTextVNode(` Rewards... `,-1),(openBlock(!0),createElementBlock(Fragment,null,renderList(racer.rewards,reward=>(openBlock(),createElementBlock(`div`,_hoisted_17$18,[createTextVNode(toDisplayString(reward)+` BMRA-XP `,1),createVNode(unref(bngIcon_default),{class:`reward-icon`,type:unref(icons).wheelOutline,color:`black`},null,8,[`type`])]))),256)),_cache[2]||=createBaseVNode(`template`,null,[createTextVNode(` ... `)],-1)]))]))),128)),createBaseVNode(`div`,_hoisted_18$16,[createBaseVNode(`div`,null,toDisplayString(unref(units).buildString(`temperature`,__props.slip.env.tempC,1,`c`))+` / `+toDisplayString(unref(units).buildString(`temperature`,__props.slip.env.tempC,1,`f`)),1),__props.slip.env.customGrav?(openBlock(),createElementBlock(`div`,_hoisted_19$13,toDisplayString(_ctx.$tt(`ui.environment.gravity`))+`: `+toDisplayString(__props.slip.env.gravity),1)):createCommentVNode(``,!0)])]),_cache[4]||=createBaseVNode(`div`,{class:`rip bottom`},null,-1)]))}},Timeslip_default=__plugin_vue_export_helper_default(_sfc_main$209,[[`__scopeId`,`data-v-4b627404`]]),_hoisted_1$186={key:0,class:`bng-app`,id:`container`},_hoisted_2$151={class:`slide`},_sfc_main$208={__name:`app`,setup(__props){let{$game}=useLibStore(),slip=ref({});onMounted(()=>{$game.events.on(`onDragRaceTimeslipData`,onDragRaceTimeslipData)}),onUnmounted(()=>{$game.events.off(`onDragRaceTimeslipData`,onDragRaceTimeslipData)});function onDragRaceTimeslipData(rawData){slip.value=rawData,rawData&&(console.log(rawData),Lua_default.Engine.Audio.playOnce(`AudioGui`,`event:>UI>Missions>Timeslip`))}let screenshot=function(){Lua_default.gameplay_drag_dragBridge.screenshotTimeslip()},clear=function(){slip.value=null};return(_ctx,_cache)=>slip.value&&slip.value.stripInfo?(openBlock(),createElementBlock(`div`,_hoisted_1$186,[createBaseVNode(`div`,_hoisted_2$151,[createVNode(Timeslip_default,{slip:slip.value,save:``,clear:``},null,8,[`slip`]),createVNode(unref(bngIcon_default),{class:`clear`,type:unref(icons).trashBin1,onClick:clear},null,8,[`type`]),createVNode(unref(bngIcon_default),{class:`save`,type:unref(icons).floppyDisk,onClick:screenshot},null,8,[`type`])])])):createCommentVNode(``,!0)}},app_default$10=__plugin_vue_export_helper_default(_sfc_main$208,[[`__scopeId`,`data-v-84d60911`]]),_hoisted_1$185={key:0},_hoisted_2$150={class:`lights-container`},_hoisted_3$135={class:`circles-wrapper`},_hoisted_4$112={class:`stage-circle`},_hoisted_5$97={class:`stage-top`},_hoisted_6$80={class:`stage-middle`},_hoisted_7$68={class:`stage-bottom`},_hoisted_8$55={class:`circles-wrapper`},_hoisted_9$49={class:`circles-wrapper`},_hoisted_10$42={class:`circles-wrapper`},_hoisted_11$37={class:`circles-wrapper`},_sfc_main$207={__name:`Treelights`,setup(__props){let events$3=useEvents(),isStaging=ref(!1),stageLights=ref([{stageLights:{prestageLight:!1,stageLight:!1},countDownLights:{amberLight1:!1,amberLight2:!1,amberLight3:!1,greenLight:!1,redLight:!1},globalLights:{blueLight:!1}}]),updateLights=changes=>{changes.stageLights&&(stageLights.value[0].stageLights={...stageLights.value[0].stageLights,...changes.stageLights}),changes.countDownLights&&(stageLights.value[0].countDownLights={...stageLights.value[0].countDownLights,...changes.countDownLights},(changes.countDownLights.greenLight||changes.countDownLights.redLight)&&setTimeout(()=>{isStaging.value=!1},2e3))},updateStaging=isNearby=>{isStaging.value=isNearby};return onMounted(()=>{events$3.on(`updateTreeLightApp`,updateLights),events$3.on(`updateTreeLightStaging`,updateStaging)}),onUnmounted(()=>{events$3.off(`updateTreeLightApp`,updateLights),events$3.off(`updateTreeLightStaging`,updateStaging)}),(_ctx,_cache)=>isStaging.value.valueOf==0?createCommentVNode(``,!0):(openBlock(),createElementBlock(`div`,_hoisted_1$185,[createBaseVNode(`div`,_hoisted_2$150,[createBaseVNode(`div`,_hoisted_3$135,[createBaseVNode(`div`,{class:normalizeClass([`light-circle black`,{blue:stageLights.value[0].globalLights.blueLight,red:stageLights.value[0].countDownLights.redLight}])},[withDirectives(createBaseVNode(`div`,_hoisted_4$112,[withDirectives(createBaseVNode(`div`,_hoisted_5$97,[..._cache[0]||=[createStaticVNode(``,1)]],512),[[vShow,stageLights.value[0].stageLights.prestageLight]]),withDirectives(createBaseVNode(`div`,_hoisted_6$80,[..._cache[1]||=[createStaticVNode(``,1)]],512),[[vShow,stageLights.value[0].stageLights.prestageLight&&stageLights.value[0].stageLights.stageLight]]),withDirectives(createBaseVNode(`div`,_hoisted_7$68,[..._cache[2]||=[createStaticVNode(``,1)]],512),[[vShow,stageLights.value[0].stageLights.stageLight]])],512),[[vShow,!stageLights.value[0].countDownLights.redLight]])],2)]),createBaseVNode(`div`,_hoisted_8$55,[createBaseVNode(`div`,{class:normalizeClass([`light-circle black`,{amber:stageLights.value[0].countDownLights.amberLight1,red:stageLights.value[0].countDownLights.redLight}])},null,2)]),createBaseVNode(`div`,_hoisted_9$49,[createBaseVNode(`div`,{class:normalizeClass([`light-circle black`,{amber:stageLights.value[0].countDownLights.amberLight2,red:stageLights.value[0].countDownLights.redLight}])},null,2)]),createBaseVNode(`div`,_hoisted_10$42,[createBaseVNode(`div`,{class:normalizeClass([`light-circle black`,{amber:stageLights.value[0].countDownLights.amberLight3,red:stageLights.value[0].countDownLights.redLight}])},null,2)]),createBaseVNode(`div`,_hoisted_11$37,[createBaseVNode(`div`,{class:normalizeClass([`light-circle black go`,{green:stageLights.value[0].countDownLights.greenLight,red:stageLights.value[0].countDownLights.redLight}])},null,2)])])]))}},Treelights_default=__plugin_vue_export_helper_default(_sfc_main$207,[[`__scopeId`,`data-v-c2ff1007`]]),_sfc_main$206={__name:`bngModifierTiles`,props:{modifierActionInfos:{type:Object,required:!0}},setup(__props){let{isControllerUsed}=storeToRefs(controls_default()),props=__props,controllerActions=computed(()=>{let mod1Active=props.modifierActionInfos.customModifier1?.active,mod2Active=props.modifierActionInfos.customModifier2?.active,mod1Disabled=props.modifierActionInfos.customModifier1?.disabled,mod2Disabled=props.modifierActionInfos.customModifier2?.disabled,mod1modifier2Disabled=props.modifierActionInfos.modifier1modifier2?.disabled;return[{actions:[{actionName:`customModifier2`}],active:!mod2Disabled&&mod2Active&&!mod1Active,disabled:mod2Disabled},{actions:[{actionName:`customModifier2`},{actionName:`customModifier1`}],active:!mod1modifier2Disabled&&mod1Active&&mod2Active,disabled:mod1modifier2Disabled},{actions:[{actionName:`customModifier1`}],active:!mod1Disabled&&mod1Active&&!mod2Active,disabled:mod1Disabled}]}),kbmActions=computed(()=>{props.modifierActionInfos.shift?.active;let ctrlActive=props.modifierActionInfos.ctrl?.active!==void 0,altActive=props.modifierActionInfos.alt?.active!==void 0;return[{active:ctrlActive,actions:[{actionName:`kbmModifier1`,device:`keyboard0`,deviceKey:`ctrl`}]},{active:altActive,actions:[{actionName:`kbmModifier3`,device:`keyboard0`,deviceKey:`alt`}]}]}),entries=computed(()=>isControllerUsed.value?controllerActions.value:kbmActions.value),getModifierClass=entry=>{let cls=`modifier-tile`;return entry.active&&(cls+=` active`),entry.disabled&&(cls+=` disabled`),cls};return(_ctx,_cache)=>(openBlock(!0),createElementBlock(Fragment,null,renderList(entries.value,entry=>(openBlock(),createElementBlock(`div`,{class:normalizeClass(getModifierClass(entry))},[(openBlock(!0),createElementBlock(Fragment,null,renderList(entry.actions,(action,actionIdx)=>(openBlock(),createElementBlock(`div`,{key:actionIdx},[actionIdx>0?(openBlock(),createBlock(unref(bngIcon_default),{key:0,type:`mathPlus`})):createCommentVNode(``,!0),createVNode(unref(bngBinding_default),{action:action.actionName,device:action.device,"device-key":action.deviceKey,"show-unassigned":!1},null,8,[`action`,`device`,`device-key`])]))),128))],2))),256))}},bngModifierTiles_default=__plugin_vue_export_helper_default(_sfc_main$206,[[`__scopeId`,`data-v-ea01b9d8`]]),_hoisted_1$184={key:0,class:`bng-app-binding-display`},_hoisted_2$149={key:0,class:`modifier-bindings`},_hoisted_3$134={class:`label-column`},_hoisted_4$111={key:0,class:`label-text`},_hoisted_5$96={class:`binding-column`},_hoisted_6$79={class:`flexible-area`},_hoisted_7$67={class:`label-column`},_hoisted_8$54={key:0,class:`label-text`},_hoisted_9$48={class:`binding-column`},_hoisted_10$41={key:0,class:`tile-flex`},_hoisted_11$36={key:1,class:`bottom-left-group`},_sfc_main$205={__name:`bngAppBindingDisplay`,setup(__props){let events$3=useEvents(),actions=shallowRef([]),tileActions=shallowRef([]),constantActions=shallowRef([]),modifierActionInfos=shallowRef([]),additionalData=shallowRef({}),isFaded=ref(!1),isHovered=ref(!1),mouseDownAction=ref(``),actionOpacity=ref(1),fadeOutTimeout=null,isFadingOut=ref(!1),showApp=ref(!0),tileRefs=ref([]),isWide=ref([]),narrowSpan=ref(4),setActions=data=>{let newActions=Array.isArray(data.actions)?data.actions:[];showApp.value=data.showApp,constantActions.value=Array.isArray(data.constantActions)?data.constantActions:[],modifierActionInfos.value=data.modifierActionInfos?{...data.modifierActionInfos}:{},additionalData.value=data.additionalData?{...data.additionalData}:{},fadeOutTimeout&&(clearTimeout(fadeOutTimeout),fadeOutTimeout=null,isFadingOut.value=!1),actions.value.length>0&&newActions.length===0?(isFadingOut.value=!0,actionOpacity.value=0,fadeOutTimeout=setTimeout(()=>{actions.value=newActions,actionOpacity.value=1,isFadingOut.value=!1,fadeOutTimeout=null},0)):newActions.length>0&&actions.value.length===0?(actions.value=newActions,actionOpacity.value=0,nextTick(()=>{actionOpacity.value=1})):(actions.value=newActions,actionOpacity.value=1),tileActions.value=actions.value.filter(action=>action.icon),actions.value=actions.value.filter(action=>!action.icon)},getActionClass=(action,isConstant)=>{let cls=`binding-row`;return isConstant?cls+=` is-constant`:isFadingOut.value&&(cls+=` is-fading-out`),!action.onClick&&!action.inputActionOnClick&&(cls+=` no-hover`),action.highlighted&&(cls+=` highlighted`),cls},onActionClickDown=action=>{action.onClick?runRaw(action.onClick):action.inputActionOnClick&&(mouseDownAction.value=action.action,Lua_default.ui_bindingsLegend.triggerInputAction(action.action,1))},onMouseEnter=()=>{isHovered.value=!0},onMouseLeave=()=>{isHovered.value=!1},onGlobalMouseUp=event=>{mouseDownAction.value&&=(Lua_default.ui_bindingsLegend.triggerInputAction(mouseDownAction.value,0),``)};onMounted(()=>{events$3.on(`setActionsForLegend`,setActions),events$3.on(`setBindingsLegendFade`,value=>{isFaded.value=!!value}),Lua_default.ui_bindingsLegend.sendDataToUI(!0),listenFilteredInputEvents(!0),document.addEventListener(`mouseup`,onGlobalMouseUp)}),onBeforeUnmount(()=>{document.removeEventListener(`mouseup`,onGlobalMouseUp),fadeOutTimeout&&=(clearTimeout(fadeOutTimeout),null),actionOpacity.value=1,listenFilteredInputEvents(!1)});function listenFilteredInputEvents(listen){events$3[listen?`on`:`off`](`FilteredInputChanged`,onFilteredInputChanged),Lua_default.WinInput.setForwardFilteredEvents(listen)}function onFilteredInputChanged(data){let updated$2=!1;for(let action of tileActions.value)action.action===data.bindingAction&&(action.value=data.value,updated$2=!0);updated$2&&triggerRef(tileActions)}function setTileRef(i,compOrEl){tileRefs.value[i]=compOrEl&&compOrEl.$el?compOrEl.$el:compOrEl}function classifyTiles(){isWide.value=tileRefs.value.map(el=>!!el?.querySelector?.(`.combo-binding`))}function pickNarrowSpanByCount(n){let options=[{cols:4,span:3},{cols:3,span:4},{cols:2,span:6}],best=options[0],bestR=n%best.cols;for(let opt of options){let r=n%opt.cols;r{await nextTick(),tileRefs.value.length=tileActions.value.length,classifyTiles(),recomputeLayout()}),onMounted(async()=>{await nextTick(),classifyTiles(),recomputeLayout()}),(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,{class:normalizeClass([`bng-app-binding-display-wrapper`,{"is-faded":isFaded.value&&!isHovered.value}]),onMouseenter:onMouseEnter,onMouseleave:onMouseLeave},[showApp.value?(openBlock(),createElementBlock(`div`,_hoisted_1$184,[modifierActionInfos.value&&additionalData.value.vehicleSpecificStatus!==`enabled`?(openBlock(),createElementBlock(`div`,_hoisted_2$149,[createVNode(bngModifierTiles_default,{"modifier-action-infos":modifierActionInfos.value},null,8,[`modifier-action-infos`])])):createCommentVNode(``,!0),(openBlock(!0),createElementBlock(Fragment,null,renderList(constantActions.value,action=>(openBlock(),createBlock(unref(bngButton_default),{accent:unref(ACCENTS).custom,onMousedown:$event=>onActionClickDown(action),tabindex:`-1`,class:normalizeClass(getActionClass(action,!0))},{default:withCtx(()=>[createBaseVNode(`div`,_hoisted_3$134,[action.label?(openBlock(),createElementBlock(`span`,_hoisted_4$111,toDisplayString(_ctx.$t(action.label)),1)):createCommentVNode(``,!0)]),createBaseVNode(`div`,_hoisted_5$96,[action.bindings?(openBlock(!0),createElementBlock(Fragment,{key:0},renderList(action.bindings,binding=>(openBlock(),createBlock(unref(bngBinding_default),{key:binding.device+`:`+binding.control,action:action.action,device:binding.device,"device-key":binding.control,"show-unassigned":``,"action-variants":``},null,8,[`action`,`device`,`device-key`]))),128)):(openBlock(),createBlock(unref(bngBinding_default),{key:1,action:action.action,"show-unassigned":``,"action-variants":``},null,8,[`action`]))])]),_:2},1032,[`accent`,`onMousedown`,`class`]))),256)),createBaseVNode(`div`,_hoisted_6$79,[(openBlock(!0),createElementBlock(Fragment,null,renderList(actions.value,(action,index)=>(openBlock(),createBlock(unref(bngButton_default),{key:action.action||action.label,accent:unref(ACCENTS).custom,onMousedown:$event=>onActionClickDown(action),tabindex:`-1`,ref_for:!0,ref:index===0?`actionButton`:void 0,class:normalizeClass(getActionClass(action,!1))},{default:withCtx(()=>[createBaseVNode(`div`,_hoisted_7$67,[action.label?(openBlock(),createElementBlock(`span`,_hoisted_8$54,toDisplayString(_ctx.$t(action.label)),1)):createCommentVNode(``,!0)]),createBaseVNode(`div`,_hoisted_9$48,[action.bindings?(openBlock(!0),createElementBlock(Fragment,{key:0},renderList(action.bindings,binding=>(openBlock(),createBlock(unref(bngBinding_default),{key:binding.device+`:`+binding.control,action:action.action,device:binding.device,"device-key":binding.control,"show-unassigned":``,"action-variants":``},null,8,[`action`,`device`,`device-key`]))),128)):(openBlock(),createBlock(unref(bngBinding_default),{key:1,action:action.action,"show-unassigned":``,"action-variants":``},null,8,[`action`]))])]),_:2},1032,[`accent`,`onMousedown`,`class`]))),128)),tileActions.value.length>0?(openBlock(),createElementBlock(`div`,_hoisted_10$41,[(openBlock(!0),createElementBlock(Fragment,null,renderList(tileActions.value,(action,i)=>(openBlock(),createBlock(unref(bngBindingTileButton_default),{class:normalizeClass([`tile-grid-item`,{highlighted:action.highlighted}]),action,icon:action.icon,label:_ctx.$t(action.label),layout:action.direction,showValueBar:action.direction!==void 0,isBidirectional:action.isCentered,value:action.value,style:{"--tile-span":4},ref_for:!0,ref:el=>setTileRef(i,el),"show-unassigned":``,"action-variants":``,"bng-no-nav":``,tabindex:`-1`},{default:withCtx(()=>[action.bindings?(openBlock(!0),createElementBlock(Fragment,{key:0},renderList(action.bindings,binding=>(openBlock(),createBlock(unref(bngBinding_default),{key:binding.device+`:`+binding.control,action:action.action,device:binding.device,"device-key":binding.control,"show-unassigned":``,"action-variants":``},null,8,[`action`,`device`,`device-key`]))),128)):(openBlock(),createBlock(unref(bngBinding_default),{key:1,action:action.action,"show-unassigned":``,"action-variants":``},null,8,[`action`]))]),_:2},1032,[`class`,`action`,`icon`,`label`,`layout`,`showValueBar`,`isBidirectional`,`value`]))),256))])):createCommentVNode(``,!0)])])):createCommentVNode(``,!0),showApp.value?(openBlock(),createElementBlock(`div`,_hoisted_11$36,[withDirectives((openBlock(),createBlock(unref(bngButton_default),{class:`bottom-left-button`,disabled:additionalData.value.vehicleSpecificStatus===`inactive`,accent:additionalData.value.vehicleSpecificStatus===`enabled`||additionalData.value.vehicleSpecificStatus===`fleeting`?unref(ACCENTS).main:unref(ACCENTS).text,onClick:_cache[0]||=$event=>unref(Lua_default).ui_bindingsLegend.toggleShowVehicleSpecificActions(),"bng-no-nav":``,tabindex:`-1`},{default:withCtx(()=>[createVNode(unref(bngIcon_default),{type:unref(icons).car},null,8,[`type`]),additionalData.value.vehicleSpecificStatus===`enabled`?(openBlock(),createBlock(unref(bngIcon_default),{key:0,class:`bottom-left-lock`,type:unref(icons).lockClosed},null,8,[`type`])):createCommentVNode(``,!0)]),_:1},8,[`disabled`,`accent`])),[[unref(BngTooltip_default),`Press to show/hide vehicle specific actions`,`right`]])])):createCommentVNode(``,!0),createVNode(unref(bngButton_default),{class:`bottom-left-button`,accent:unref(ACCENTS).text,icon:unref(icons).eyeSolidOpened,onClick:_cache[1]||=$event=>unref(Lua_default).ui_bindingsLegend.toggleShowApp(),"bng-no-nav":``,tabindex:`-1`},null,8,[`accent`,`icon`])],34))}},bngAppBindingDisplay_default=__plugin_vue_export_helper_default(_sfc_main$205,[[`__scopeId`,`data-v-cf4052e5`]]),_hoisted_1$183={class:`action`},_hoisted_2$148={key:0,class:`indicators`},_hoisted_3$133={class:`icon-wrapper`},_hoisted_4$110={key:2,class:`tile-fallback-label`},_hoisted_5$95={key:0,class:`value-bar`},_hoisted_6$78={class:`bindings-wrapper`},_sfc_main$204={__name:`bngBindingTileButton`,props:{label:String,icon:[Object,String],showIndicators:{type:Boolean,default:!1},layout:{type:String,default:`horizontal`,validator:v=>[`horizontal`,`vertical`].includes(v)},dark:Boolean,disabled:Boolean,action:{type:Object,required:!0},bindings:{type:Array,default:()=>void 0},actionVariants:Boolean,showValueBar:{type:Boolean,default:!0},value:{type:Number,default:0},targetValue:{type:Number,default:0},isBidirectional:{type:Boolean,default:!1}},emits:[`click`],setup(__props,{expose:__expose}){let props=__props,layoutClass=computed(()=>props.layout===`vertical`?`layout-vertical`:`layout-horizontal`);__expose({icons});let isLikelyImagePath=val=>typeof val==`string`&&(val.includes(`/`)||val.startsWith(`.`)||val.includes(`\\`)),candidateIcon=computed(()=>props.icon??null),useGlyphIcon=computed(()=>{let c=candidateIcon.value;return c?typeof c==`object`?!!c.glyph:typeof c==`string`?!isLikelyImagePath(c)&&c in icons:!1:!1}),resolvedGlyphType=computed(()=>useGlyphIcon.value?candidateIcon.value:null),resolvedImagePath=computed(()=>{let c=candidateIcon.value;return typeof c==`string`&&isLikelyImagePath(c)?c:null});return(_ctx,_cache)=>(openBlock(),createBlock(unref(bngButton_default),{class:`bng-binding-tile-button`,accent:unref(ACCENTS).custom,disabled:__props.disabled,onClick:_cache[0]||=$event=>_ctx.$emit(`click`)},{default:withCtx(()=>[createBaseVNode(`div`,{class:normalizeClass([`content`,layoutClass.value])},[createBaseVNode(`div`,_hoisted_1$183,[__props.showIndicators?(openBlock(),createElementBlock(`div`,_hoisted_2$148,[(openBlock(),createElementBlock(Fragment,null,renderList(5,i=>createBaseVNode(`div`,{class:normalizeClass([`indicator`,{active:i===2}]),key:i},null,2)),64))])):createCommentVNode(``,!0),createBaseVNode(`div`,_hoisted_3$133,[useGlyphIcon.value?(openBlock(),createBlock(unref(bngIcon_default),{key:0,class:`icon-glyph`,type:resolvedGlyphType.value},null,8,[`type`])):resolvedImagePath.value?(openBlock(),createBlock(unref(bngImageAsset_default),{key:1,externalSrc:resolvedImagePath.value,class:`icon-img`,mask:``},null,8,[`externalSrc`])):__props.label?(openBlock(),createElementBlock(`div`,_hoisted_4$110,toDisplayString(__props.label),1)):createCommentVNode(``,!0)])]),__props.showValueBar?(openBlock(),createElementBlock(`div`,_hoisted_5$95,[createVNode(unref(bngInputBar_default),{value:__props.value,"target-value":__props.targetValue,"is-bidirectional":__props.isBidirectional,vertical:__props.layout==`vertical`},null,8,[`value`,`target-value`,`is-bidirectional`,`vertical`])])):createCommentVNode(``,!0),createBaseVNode(`div`,_hoisted_6$78,[renderSlot(_ctx.$slots,`binding`,{},()=>[__props.action&&__props.action.bindings?(openBlock(!0),createElementBlock(Fragment,{key:0},renderList(__props.action.bindings,binding=>(openBlock(),createBlock(unref(bngBinding_default),{key:binding.device+`:`+binding.control,action:__props.action.action,device:binding.device,"device-key":binding.control,dark:__props.dark,"show-unassigned":``,"action-variants":__props.actionVariants,vertical:__props.layout===`vertical`},null,8,[`action`,`device`,`device-key`,`dark`,`action-variants`,`vertical`]))),128)):(openBlock(),createBlock(unref(bngBinding_default),{key:1,vertical:__props.layout===`vertical`,action:__props.action&&__props.action.action,dark:__props.dark,"show-unassigned":``,"action-variants":__props.actionVariants},null,8,[`vertical`,`action`,`dark`,`action-variants`]))],!0)])],2)]),_:3},8,[`accent`,`disabled`]))}},bngBindingTileButton_default=__plugin_vue_export_helper_default(_sfc_main$204,[[`__scopeId`,`data-v-db243a30`]]),_hoisted_1$182={class:`message-container`},_sfc_main$203={__name:`bngFlashMessage`,props:{messageSource:{type:String,default:`ScenarioFlashMessage`}},setup(__props){let props=__props,events$3=useEvents(),{api:api$1}=useBridge(),txt=ref(``),messageQueue=ref([]),stepTimeout=ref(null),animationClass=ref(``),fontSizeClass=ref(`font-small`),paused=ref(!1);onMounted(()=>{events$3.on(props.messageSource,data=>{if(Array.isArray(data))data.forEach(item=>{let messageObject={msg:item[0],ttl:item[1],luaCall:item[2]&&typeof item[2]==`string`?item[2]:void 0,jsCallback:item[2]&&typeof item[2]==`function`?item[2]:void 0,big:item[3]===void 0?!1:item[3]};messageQueue.value.push(messageObject)}),messageQueue.value.length>0&&!stepTimeout.value&&playMessagesAnimation();else if(typeof data==`object`){let messageObject={msg:data.msg,ttl:data.ttl,luaCall:data.luaCall||void 0,jsCallback:data.jsCallback||void 0,big:data.big===void 0?!1:data.big};messageQueue.value.push(messageObject),stepTimeout.value||playMessagesAnimation()}else console.warn(`Unexpected data format received for FlashMessage`)}),events$3.on(`physicsStateChanged`,state=>{paused.value=!state,paused.value?stepTimeout.value&&=(clearTimeout(stepTimeout.value),null):state&&playMessagesAnimation()})}),onUnmounted(()=>{stepTimeout.value&&=(clearTimeout(stepTimeout.value),null)});function playMessagesAnimation(){if(messageQueue.value.length===0){resetCountdown();return}animationClass.value=`fade-in`,setTimeout(()=>{animationClass.value=``},200);let msg=messageQueue.value[0];txt.value=msg.msg,fontSizeClass.value=msg.big?`font-large`:`font-small`,msg.luaCall&&typeof msg.luaCall==`string`&&api$1.engineLua(msg.luaCall),msg.jsCallback&&typeof msg.jsCallback==`function`&&msg.jsCallback(),messageQueue.value.shift(),setTimeout(()=>{animationClass.value=`fade-out`},msg.ttl*1e3-200),stepTimeout.value=setTimeout(()=>{playMessagesAnimation()},msg.ttl*1e3)}function resetCountdown(){stepTimeout.value&&clearTimeout(stepTimeout.value),messageQueue.value=[],txt.value=``,stepTimeout.value=null}return(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$182,[createBaseVNode(`div`,{class:normalizeClass([`message`,[`message`,animationClass.value,fontSizeClass.value]])},toDisplayString(txt.value),3)]))}},bngFlashMessage_default=__plugin_vue_export_helper_default(_sfc_main$203,[[`__scopeId`,`data-v-02941c3f`]]),_hoisted_1$181={class:`track`},_sfc_main$202={__name:`bngInputBar`,props:{value:{type:Number,default:0},targetValue:{type:Number,default:0},isBidirectional:{type:Boolean,default:!1},vertical:{type:Boolean,default:!1}},setup(__props){let props=__props,isVertical=computed(()=>props.vertical),clamp$2=(v,min$1,max$1)=>Math.min(max$1,Math.max(min$1,v)),toUnits=(v,bidir)=>{let vv=clamp$2(v,bidir?-1:0,1);return bidir?(vv+1)/2:vv},zeroUnits=computed(()=>props.isBidirectional?.5:0),actualUnits=computed(()=>toUnits(props.value,props.isBidirectional)),targetUnits=computed(()=>toUnits(props.targetValue,props.isBidirectional)),makeFillStyle=units=>{if(!isVertical.value){if(props.isBidirectional){let start=Math.min(units,zeroUnits.value),end=Math.max(units,zeroUnits.value);return{left:`${start*100}%`,right:`${(1-end)*100}%`}}return{left:`0%`,right:`${(1-units)*100}%`}}if(props.isBidirectional){let start=Math.min(units,zeroUnits.value),end=Math.max(units,zeroUnits.value);return{bottom:`${start*100}%`,top:`${(1-end)*100}%`}}return{bottom:`0%`,top:`${(1-units)*100}%`}},actualStyle=computed(()=>makeFillStyle(actualUnits.value)),targetStyle=computed(()=>makeFillStyle(targetUnits.value)),showTarget=computed(()=>props.targetValue!==void 0&&props.targetValue!==null),knobStyle=computed(()=>isVertical.value?{bottom:`calc(${actualUnits.value*100}% - 2px)`}:{left:`calc(${actualUnits.value*100}% - 2px)`});return(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,{class:normalizeClass([`bng-input-bar`,{bidirectional:__props.isBidirectional,vertical:isVertical.value}])},[createBaseVNode(`div`,_hoisted_1$181,[showTarget.value?(openBlock(),createElementBlock(`div`,{key:0,class:`fill target`,style:normalizeStyle(targetStyle.value)},null,4)):createCommentVNode(``,!0),createBaseVNode(`div`,{class:`fill actual`,style:normalizeStyle(actualStyle.value)},null,4)]),createBaseVNode(`div`,{class:`knob`,style:normalizeStyle(knobStyle.value)},null,4)],2))}},bngInputBar_default=__plugin_vue_export_helper_default(_sfc_main$202,[[`__scopeId`,`data-v-30b04794`]]),_hoisted_1$180={key:1,class:`data-label`},_hoisted_2$147={key:2,class:`data-value`},_hoisted_3$132={key:3,class:`time-container`},_hoisted_4$109={class:`time-seconds`},_hoisted_5$94={class:`time-milliseconds`},_hoisted_6$77={key:4,class:`data-value-extra`},_sfc_main$201={__name:`bngSimpleDataDisplay`,props:{label:{type:String,default:``},value:{type:[String,Number,Object,Array],default:``},icon:{type:String,default:``},minutes:{type:String},seconds:{type:String},milliseconds:{type:String}},setup(__props){let props=__props,iconType$1=computed(()=>props.icon);return(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,{class:normalizeClass([`simple-data-display`,{"with-icon":__props.icon}])},[__props.icon?(openBlock(),createBlock(unref(bngIcon_default),{key:0,type:iconType$1.value,class:`icon`},null,8,[`type`])):createCommentVNode(``,!0),__props.label&&!__props.icon?(openBlock(),createElementBlock(`div`,_hoisted_1$180,toDisplayString(__props.label),1)):createCommentVNode(``,!0),_ctx.$slots.default?createCommentVNode(``,!0):(openBlock(),createElementBlock(`div`,_hoisted_2$147,toDisplayString(__props.value),1)),props.minutes||props.seconds?(openBlock(),createElementBlock(`div`,_hoisted_3$132,[createBaseVNode(`span`,{class:normalizeClass({"time-minutes":!0,zero:__props.minutes===`00`})},toDisplayString(props.minutes),3),_cache[1]||=createTextVNode(` :`,-1),createBaseVNode(`span`,_hoisted_4$109,toDisplayString(props.seconds),1),props.milliseconds?(openBlock(),createElementBlock(Fragment,{key:0},[_cache[0]||=createTextVNode(` .`,-1),createBaseVNode(`span`,_hoisted_5$94,toDisplayString(props.milliseconds),1)],64)):createCommentVNode(``,!0)])):createCommentVNode(``,!0),_ctx.$slots.default?(openBlock(),createElementBlock(`div`,_hoisted_6$77,[renderSlot(_ctx.$slots,`default`,{},void 0,!0)])):createCommentVNode(``,!0)],2))}},bngSimpleDataDisplay_default=__plugin_vue_export_helper_default(_sfc_main$201,[[`__scopeId`,`data-v-f2b79846`]]),_sfc_main$200={__name:`app`,props:{showFlash:{type:Boolean,default:!0}},setup(__props){let props=__props;return(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,null,[createVNode(Treelights_default),props.showFlash?(openBlock(),createBlock(unref(bngFlashMessage_default),{key:0,"message-source":`DragRaceTreeFlashMessage`})):createCommentVNode(``,!0)]))}},app_default$11=_sfc_main$200,_hoisted_1$179={class:`stage-indicator-container`},_hoisted_2$146={class:`stage-bar`},_hoisted_3$131={key:0,class:`segment grey-segment top`},_hoisted_4$108={key:1,class:`segment grey-segment bottom`},_hoisted_5$93={class:`indicator-line`},THROTTLE_MS=1,HIDE_DELAY_MS=5e3,_sfc_main$199={__name:`app`,setup(__props){let events$3=useEvents(),stageDistance=ref(-100),isVisible$1=ref(!0),hideTimeout,isDetailedView=computed(()=>stageDistance.value>-1&&stageDistance.value<1),indicatorPosition=computed(()=>isDetailedView?70-(stageDistance.value+1)*20:stageDistance.value<-1?10-stageDistance.value:30-(stageDistance.value-1)*(30/3)),lastUpdate=0;function updateStageApp(distance){let now$1=performance.now();now$1-lastUpdate{isVisible$1.value=!1},HIDE_DELAY_MS))}return onMounted(()=>{events$3.on(`updateStageApp`,updateStageApp)}),onUnmounted(()=>{lastUpdate=0,clearTimeout(hideTimeout),events$3.off(`updateStageApp`,updateStageApp)}),(_ctx,_cache)=>(openBlock(),createElementBlock(Fragment,null,[createBaseVNode(`div`,null,toDisplayString(stageDistance.value),1),withDirectives(createBaseVNode(`div`,_hoisted_1$179,[createBaseVNode(`div`,_hoisted_2$146,[isDetailedView.value?(openBlock(),createElementBlock(`div`,_hoisted_3$131)):createCommentVNode(``,!0),createBaseVNode(`div`,{class:normalizeClass([`middle-section`,{"align-top":!isDetailedView.value&&stageDistance.value<-1,"align-bottom":!isDetailedView.value&&stageDistance.value>1}])},[isDetailedView.value?(openBlock(),createElementBlock(Fragment,{key:0},[_cache[0]||=createBaseVNode(`div`,{class:`segment deep-stage`,style:{height:`20px`}},null,-1),_cache[1]||=createBaseVNode(`div`,{class:`segment stage`,style:{height:`40px`}},null,-1),_cache[2]||=createBaseVNode(`div`,{class:`segment pre-stage`,style:{height:`40px`}},null,-1)],64)):(openBlock(),createElementBlock(`div`,{key:1,class:normalizeClass([`segment green-segment`,{top:stageDistance.value<-1,bottom:stageDistance.value>1}])},null,2))],2),stageDistance.value<=1?(openBlock(),createElementBlock(`div`,_hoisted_4$108)):createCommentVNode(``,!0)]),createBaseVNode(`div`,{class:`distance-indicator`,style:normalizeStyle({top:indicatorPosition.value+`%`})},[createBaseVNode(`div`,_hoisted_5$93,[createBaseVNode(`div`,{class:normalizeClass([`car-icon`,{"car-icon-detailed":isDetailedView.value}])},null,2)])],4)],512),[[vShow,isVisible$1.value&&stageDistance.value>=-4&&stageDistance.value<=4]])],64))}},app_default$12=__plugin_vue_export_helper_default(_sfc_main$199,[[`__scopeId`,`data-v-5245723d`]]),_hoisted_1$178={class:`main-container drift-app`},_hoisted_2$145={class:`cached-score-wrapper`},_hoisted_3$130={class:`added-score`},_hoisted_4$107={class:`cached-score`},_hoisted_5$92={class:`score-container`},_hoisted_6$76={class:`score`},_hoisted_7$66={class:`combo-wrapper`},_hoisted_8$53=[`id`],_hoisted_9$47=[`id`],_hoisted_10$40=[`stop-color`],_hoisted_11$35=[`stop-color`],_hoisted_12$27=[`id`],_hoisted_13$24={class:`multiplier`,x:`0`,y:`15.5`,fill:`#fff`,"dominant-baseline":`hanging`,"text-anchor":`start`,style:{fontSize:`1.9rem`}},_hoisted_14$23=[`mask`],_hoisted_15$22=[`fill`],_hoisted_16$22={class:`remaining-time`},_hoisted_17$17={class:`wrapper`},_hoisted_18$15={class:`drift-bar`},_hoisted_19$12={class:`drift-scale`},_hoisted_20$11={class:`drift-progress-bar`},FAIL_ANIMATION_DURATION=900,_sfc_main$198={__name:`app`,props:{showFlash:{type:Boolean,default:!0}},setup(__props){let props=__props,{lua}=useBridge(),bgId=uniqueId(``,`_`),events$3=useEvents(),realtimeScorePoints=ref(0),realtimeScoreCombo=ref(0),creep=ref(0),remainingComboTime=ref(0),centerIcon=ref(null),centerMessage=ref(null),centerFailMessage=ref(null),scoreToAdd=ref(0),countdownTimer=null,countdownStartTime=null,delayTimer=null,startTimer=null,centerMessageTimer=null,bonusDisplayAdd=null,bonusDisplayDispose=null,bonusQueue=ref([]),bonusDisplay=ref([]),realtimeAngle=ref(0),steppedPerformanceFactor=ref(1),isCenterMessageFading=ref(!1),isFailActive=ref(!1),isFailAnimating=ref(!1),failAnimationStartTime=null,failAnimationTimer=null,currentModifier=ref(null),isModifierFading=ref(!1),modifierTimer=null;onMounted(()=>{let rafScheduled=!1,buffered={points:0,combo:0,remaining:0,creep:0,angle:0},flushBuffered=()=>{realtimeScorePoints.value=buffered.points,realtimeScoreCombo.value=buffered.combo,remainingComboTime.value=buffered.remaining,creep.value=buffered.creep,realtimeAngle.value=buffered.angle,rafScheduled=!1},scheduleFlush=()=>{rafScheduled||(rafScheduled=!0,requestAnimationFrame(flushBuffered))},streamsList$1=[`drift`];useStreams(streamsList$1,streams=>{for(let stream of streamsList$1)if(!streams[stream])return;buffered.points=streams.drift.realtimeCachedScoreFloored,buffered.combo=streams.drift.realtimeCombo,buffered.points>0&&(centerMessage.value=null),buffered.remaining=streams.drift.realtimeRemainingComboTime,buffered.creep=streams.drift.realtimeCreep,buffered.angle=-streams.drift.realtimeAngle,steppedPerformanceFactor.value=streams.drift.realtimePerformanceFactor,scheduleFlush()}),events$3.on(`setDriftRealtimeFail`,(reason,icon)=>{cancelTimers(),isFailActive.value=!0,isFailAnimating.value=!0,isCenterMessageFading.value=!1,centerFailMessage.value=reason,centerIcon.value=icon||``,bonusDisplay.value=[],creep.value=0;let initialComboTime=remainingComboTime.value;failAnimationStartTime=performance.now();let animateFailBar=timestamp=>{let elapsed=timestamp-failAnimationStartTime,progress=Math.max(0,1-elapsed/FAIL_ANIMATION_DURATION);remainingComboTime.value=initialComboTime*progress,progress>0&&(failAnimationTimer=requestAnimationFrame(animateFailBar))};failAnimationTimer=requestAnimationFrame(animateFailBar),centerMessageTimer&&clearTimeout(centerMessageTimer),setTimeout(()=>{isFailActive.value=!1,isFailAnimating.value=!1,remainingComboTime.value=0,failAnimationTimer&&=(cancelAnimationFrame(failAnimationTimer),null)},FAIL_ANIMATION_DURATION),centerMessageTimer=setTimeout(()=>{isCenterMessageFading.value=!0},1e3),setTimeout(()=>{centerFailMessage.value=null,centerIcon.value=null,isCenterMessageFading.value=!1},1500)}),events$3.on(`setDriftPersistentDriftScored`,(final,score,combo)=>{centerMessage.value=`+ `,scoreToAdd.value=final,bonusDisplay.value=[],startCountdown()}),events$3.on(`displayDriftScoreModifier`,msg=>{modifierTimer&&clearTimeout(modifierTimer),isModifierFading.value=!1,currentModifier.value=msg,modifierTimer=setTimeout(()=>{isModifierFading.value=!0},1500)})}),onUnmounted(()=>{cancelTimers(),centerMessageTimer&&clearTimeout(centerMessageTimer),clearInterval(bonusDisplayAdd),clearInterval(bonusDisplayDispose),failAnimationTimer&&cancelAnimationFrame(failAnimationTimer),modifierTimer&&clearTimeout(modifierTimer),window.removeEventListener(`resize`,onResize)});let barClass=computed(()=>({"bar-good":!isFailAnimating.value&&steppedPerformanceFactor.value>=3,"bar-warn":!isFailAnimating.value&&steppedPerformanceFactor.value<3,"bar-fail":isFailAnimating.value})),barVarsStyle=computed(()=>({"--bar-scale":String(Math.max(0,Math.min(1,remainingComboTime.value))),"--bar-visible":remainingComboTime.value<=.01?`hidden`:`visible`})),driftProgressStyle=computed(()=>{let pos=Math.abs(calculatePosition(realtimeAngle.value,thresholds,positions))/100;return{left:`50%`,width:`50%`,transform:`scaleX(${((realtimeAngle.value>0?1:-1)>0?1:-1)*(pos/2)})`,opacity:Math.abs(realtimeAngle.value)<7?`0.65`:`1`}}),formattedCombo=computed(()=>parseFloat(realtimeScoreCombo.value).toFixed(1)),formattedRealtimeAngle=computed(()=>Math.abs(Math.round(realtimeAngle.value))),layoutVersion=ref(0),tickLefts=computed(()=>positions.map(p$1=>`${(p$1+100)/2}%`)),onResize=()=>{layoutVersion.value++};window.addEventListener(`resize`,onResize);function cancelTimers(){countdownTimer&&=(cancelAnimationFrame(countdownTimer),null),delayTimer&&=(clearTimeout(delayTimer),null),startTimer&&=(clearTimeout(startTimer),null),failAnimationTimer&&=(cancelAnimationFrame(failAnimationTimer),null)}function startCountdown(){cancelTimers(),startTimer=setTimeout(()=>{let initialScore=scoreToAdd.value,scoreDwindleAnimDuration=1e3;function countdown(timestamp){countdownStartTime||=timestamp;let elapsedTime=timestamp-countdownStartTime;elapsedTime>=scoreDwindleAnimDuration?(scoreToAdd.value=0,countdownStartTime=null,delayTimer=setTimeout(()=>{scoreToAdd.value=-1,centerMessage.value=null,realtimeScorePoints.value=0,realtimeScoreCombo.value=0,creep.value=0,delayTimer=null},1e3)):(scoreToAdd.value=Math.floor(initialScore*(1-elapsedTime/scoreDwindleAnimDuration)),countdownTimer=requestAnimationFrame(countdown))}countdownTimer=requestAnimationFrame(countdown)},1250)}let thresholds=[-110,-60,-20,0,20,60,110],positions=[-100,-70,-35,0,35,70,100],calculatePosition=(y,thresholds$1,positions$1)=>{let clampedY=Math.max(thresholds$1[0],Math.min(thresholds$1[thresholds$1.length-1],y));for(let i=0;i=thresholds$1[i]&&clampedY<=thresholds$1[i+1]){let t=(clampedY-thresholds$1[i])/(thresholds$1[i+1]-thresholds$1[i]);return positions$1[i]+t*(positions$1[i+1]-positions$1[i])}return 0},performanceBgClass=computed(()=>({"perf-good":steppedPerformanceFactor.value>=3,"perf-warn":steppedPerformanceFactor.value<3})),performanceTransformStyle=computed(()=>{let sRaw=Math.min(steppedPerformanceFactor.value/3,1);return{transform:`scale(${sRaw===0?.001:sRaw})`,transformOrigin:`center bottom`,opacity:sRaw===0?0:1}});function onModifierTransitionEnd(e){e.propertyName===`opacity`&&(isModifierFading.value&&=(currentModifier.value=null,!1))}let comboVarsStyle=computed(()=>({"--combo-glow-color":realtimeScoreCombo.value>=25?`210, 110, 0`:`255, 255, 0`,"--combo-glow-alpha":String(creep.value),"--combo-rect-translate":`${-creep.value*2}rem`}));function ensureBonusTimers(){!bonusDisplayAdd&&bonusQueue.value.length>0&&(bonusDisplayAdd=setInterval(()=>{if(bonusQueue.value.length===0)return;let item=bonusQueue.value.pop();bonusDisplay.value.unshift(item)},500)),!bonusDisplayDispose&&bonusDisplay.value.length>0&&(bonusDisplayDispose=setInterval(()=>{bonusDisplay.value.length>0&&bonusDisplay.value.pop()},1e4)),bonusQueue.value.length===0&&bonusDisplay.value.length===0&&(bonusDisplayAdd&&=(clearInterval(bonusDisplayAdd),null),bonusDisplayDispose&&=(clearInterval(bonusDisplayDispose),null))}return watch(bonusQueue,ensureBonusTimers,{deep:!0}),watch(bonusDisplay,ensureBonusTimers,{deep:!0}),onMounted(()=>{lua.extensions.gameplay_drift_general.onDriftAppMounted()}),onUnmounted(()=>{lua.extensions.gameplay_drift_general.onDriftAppUnmounted()}),(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$178,[createBaseVNode(`div`,_hoisted_2$145,[createBaseVNode(`div`,{class:normalizeClass([`fail-overlay`,{active:isFailActive.value}])},null,2),createBaseVNode(`div`,{class:normalizeClass([`performance-background`,performanceBgClass.value]),style:normalizeStyle(performanceTransformStyle.value)},null,6),centerFailMessage.value?(openBlock(),createElementBlock(`div`,{key:0,class:normalizeClass([`center`,{"fade-out":isCenterMessageFading.value}])},toDisplayString(centerFailMessage.value),3)):centerMessage.value?(openBlock(),createElementBlock(`div`,{key:1,class:normalizeClass([`center`,{"fade-out":isCenterMessageFading.value}])},[createTextVNode(toDisplayString(centerMessage.value)+` `,1),centerMessage.value&&scoreToAdd.value>=0?(openBlock(),createElementBlock(Fragment,{key:0},[createTextVNode(toDisplayString(scoreToAdd.value),1)],64)):createCommentVNode(``,!0)],2)):(openBlock(),createElementBlock(Fragment,{key:2},[createBaseVNode(`div`,_hoisted_3$130,[(openBlock(!0),createElementBlock(Fragment,null,renderList(bonusDisplay.value,(item,index)=>(openBlock(),createElementBlock(`div`,{key:index,class:`score-item`},` +`+toDisplayString(~~item.score),1))),128))]),createBaseVNode(`div`,_hoisted_4$107,[createBaseVNode(`div`,_hoisted_5$92,[(openBlock(),createElementBlock(`div`,{class:normalizeClass([`score-modifier`,{"fade-out":isModifierFading.value}]),key:currentModifier.value,onTransitionend:onModifierTransitionEnd},toDisplayString(currentModifier.value),35)),createBaseVNode(`div`,_hoisted_6$76,toDisplayString(realtimeScorePoints.value),1)]),createBaseVNode(`div`,_hoisted_7$66,[(openBlock(),createElementBlock(`svg`,{id:`svg_${unref(bgId)}`,class:`combo`,viewBox:`0 0 100 30`,style:normalizeStyle([{width:`100%`,height:`3rem`},comboVarsStyle.value]),preserveAspectRatio:`xMinYMid meet`},[createBaseVNode(`defs`,null,[createBaseVNode(`linearGradient`,{id:`grad_${unref(bgId)}`,x1:`0%`,y1:`0%`,x2:`0%`,y2:`100%`},[_cache[0]||=createBaseVNode(`stop`,{offset:`50%`,"stop-color":`var(--bng-ter-yellow-100)`},null,-1),createBaseVNode(`stop`,{offset:`51%`,"stop-color":realtimeScoreCombo.value>=25?`#ff8400`:`#fff`},null,8,_hoisted_10$40),createBaseVNode(`stop`,{offset:`75%`,"stop-color":realtimeScoreCombo.value>=25?`#ff8400`:`#fff`},null,8,_hoisted_11$35)],8,_hoisted_9$47),createBaseVNode(`mask`,{id:`mask_${unref(bgId)}`},[createBaseVNode(`text`,_hoisted_13$24,` ×`+toDisplayString(formattedCombo.value),1)],8,_hoisted_12$27)]),createBaseVNode(`g`,{mask:`url(#mask_${unref(bgId)})`},[createBaseVNode(`rect`,{width:`100%`,height:`4.2rem`,x:`0`,y:`15.5`,fill:`url(#grad_${unref(bgId)})`,class:`animated-rect`},null,8,_hoisted_15$22)],8,_hoisted_14$23)],12,_hoisted_8$53))])])],64))]),createBaseVNode(`div`,_hoisted_16$22,[createBaseVNode(`div`,_hoisted_17$17,[createBaseVNode(`div`,{class:normalizeClass([`bar`,barClass.value]),style:normalizeStyle(barVarsStyle.value)},null,6)])]),createBaseVNode(`div`,_hoisted_18$15,[createBaseVNode(`div`,_hoisted_19$12,[createBaseVNode(`div`,_hoisted_20$11,[createBaseVNode(`div`,{class:`progress-fill`,style:normalizeStyle(driftProgressStyle.value)},null,4)]),(openBlock(),createElementBlock(`div`,{class:`value-marks`,key:layoutVersion.value},[(openBlock(),createElementBlock(Fragment,null,renderList(thresholds,(threshold,index)=>createBaseVNode(`div`,{class:`line`,key:threshold,style:normalizeStyle({position:`absolute`,left:tickLefts.value[index],width:`0.125rem`,height:`0.24rem`,transform:threshold===0?`translateX(-50%)`:threshold>0?`translateX(-100%)`:`translateX(0%)`,backgroundColor:`white`})},null,4)),64))]))]),(openBlock(),createElementBlock(`div`,{class:`drift-labels`,key:layoutVersion.value},[(openBlock(),createElementBlock(Fragment,null,renderList(thresholds,(threshold,index)=>createBaseVNode(`span`,{key:threshold,style:normalizeStyle({position:`absolute`,left:tickLefts.value[index],transform:`translateX(-50%)`,textAlign:`center`})},toDisplayString(threshold===0?`${formattedRealtimeAngle.value}°`:`${Math.abs(threshold)}°`),5)),64))])),props.showFlash?(openBlock(),createBlock(unref(bngFlashMessage_default),{key:0,"message-source":`DriftFlashMessage`})):createCommentVNode(``,!0)])]))}},app_default$13=__plugin_vue_export_helper_default(_sfc_main$198,[[`__scopeId`,`data-v-aa80ede0`]]),_hoisted_1$177={class:`main-container-grid`},_hoisted_2$144={class:`scores-container`},_hoisted_3$129={class:`permanent`},_hoisted_4$106={class:`points-label`},_sfc_main$197={__name:`app`,setup(__props){let events$3=useEvents(),permanentScore=ref(0),potentialScore=ref(0),isAnimatingPotentialScore=ref(!1),dontUpdateScores=ref(!1),lastPotentialScore=ref(0);onMounted(()=>{events$3.on(`setDriftPersistentDriftScored`,(score,combo)=>{isAnimatingPotentialScore.value=!0,dontUpdateScores.value=!0,potentialScore.value=score,lastPotentialScore.value=potentialScore.value,setTimeout(()=>{isAnimatingPotentialScore.value=!1},1e3),setTimeout(()=>{dontUpdateScores.value=!1},900)})}),onUnmounted(()=>{events$3.off(`setDriftPersistentDriftScored`)});let streamsList$1=[`drift`];return useStreams(streamsList$1,streams=>{for(let stream of streamsList$1)if(!streams[stream])return;dontUpdateScores.value||(permanentScore.value=streams.drift.permanentScore,potentialScore.value=streams.drift.potentialScore)}),(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$177,[createBaseVNode(`div`,_hoisted_2$144,[createBaseVNode(`div`,_hoisted_3$129,[createBaseVNode(`span`,_hoisted_4$106,toDisplayString(unref($translate).instant(`missions.drift.general.pointsShort`))+`: `,1),createTextVNode(toDisplayString(permanentScore.value),1)]),createBaseVNode(`div`,{class:normalizeClass([`potential`,{"animate-potential-score":isAnimatingPotentialScore.value}])},` + `+toDisplayString(potentialScore.value),3)])]))}},app_default$14=__plugin_vue_export_helper_default(_sfc_main$197,[[`__scopeId`,`data-v-29f9fe6b`]]),_hoisted_1$176={class:`main-container-grid`},_sfc_main$196={__name:`app`,setup(__props){let{lua}=useBridge(),events$3=useEvents(),showButton=ref(!1),handleNextStep=()=>{lua.gameplay_crashTest_scenarioManager.nextStepFromUI(),showButton.value=!1};return onMounted(()=>{events$3.on(`onCrashTestStepFinished`,()=>{console.log(`onCrashTestStepFinished`),showButton.value=!0})}),onUnmounted(()=>{events$3.off(`onCrashTestStepFinished`)}),(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$176,[showButton.value?(openBlock(),createBlock(unref(bngButton_default),{key:0,onClick:handleNextStep,accent:unref(ACCENTS).text,icon:unref(icons).arrowSolidRight,class:normalizeClass({"next-step-button":!0})},{default:withCtx(()=>[createTextVNode(toDisplayString(unref($translate).instant(`missions.crashTest.general.nextStep`)),1)]),_:1},8,[`accent`,`icon`])):createCommentVNode(``,!0)]))}},app_default$15=__plugin_vue_export_helper_default(_sfc_main$196,[[`__scopeId`,`data-v-6d935866`]]),_hoisted_1$175={class:`bng-app`},_sfc_main$195={__name:`app`,setup(__props){let{$game}=useLibStore(),streamsList$1=[`engineInfo`],data=reactive({engineT:0,wheelT:0,rpm:0,gearText:``});onMounted(()=>$game.streams.add(streamsList$1)),onUnmounted(()=>$game.streams.remove(streamsList$1)),$game.events.on(`onStreamsUpdate`,streams=>{streams.engineInfo!==null&&(data.engineT=$game.units.buildString(`torque`,streams.engineInfo[8],0),data.wheelT=$game.units.buildString(`torque`,streams.engineInfo[19],0),data.rpm=streams.engineInfo[4].toFixed(),data.gearText=getGearText(streams.engineInfo[16],streams.engineInfo[6],streams.engineInfo[7]))});let getGearText=(gear,fGear,rGear)=>gear>0?`F `+gear+` / `+fGear:gear<0?`R `+Math.abs(gear)+` / `+rGear:`N`;return(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$175,[createTextVNode(toDisplayString(_ctx.$t(`ui.apps.engineinfo.rpm`))+`: `+toDisplayString(data.rpm),1),_cache[0]||=createBaseVNode(`br`,null,null,-1),createTextVNode(` `+toDisplayString(_ctx.$t(`ui.apps.engineinfo.gear`))+`: `+toDisplayString(data.gearText),1),_cache[1]||=createBaseVNode(`br`,null,null,-1),createTextVNode(` `+toDisplayString(_ctx.$t(`ui.apps.engineinfo.flywheelTorque`))+`: `+toDisplayString(data.engineT)+` `,1),_cache[2]||=createBaseVNode(`br`,null,null,-1),createTextVNode(` `+toDisplayString(_ctx.$t(`ui.apps.engineinfo.wheelTorque`))+`: `+toDisplayString(data.wheelT),1)]))}},app_default$16=_sfc_main$195,_hoisted_1$174={class:`legends`},_hoisted_2$143={class:`torque-flywheel`},_hoisted_3$128={class:`power-flywheel`},_hoisted_4$105={class:`power-wheels`},_hoisted_5$91={class:`rpm`},_hoisted_6$75={class:`content`},_hoisted_7$65={class:`power-label`},_hoisted_8$52={class:`label`},_hoisted_9$46={class:`canvas-container`},_hoisted_10$39={class:`torque-label`},_hoisted_11$34={class:`label`},tickLabels=21,torqueGraphColor=`#000000`,powerGraphColor=`#FF0000`,powerWheelGraphColor=`#FF4400`,rpmGraphColor=`#0000FF`,_sfc_main$194={__name:`app`,setup(__props){let{$game}=useLibStore(),streamsList$1=[`engineInfo`],app$1=ref(null),canvas=ref(null),globalMax=ref(0),torqueUnit=ref(null),powerUnit=ref(null),tickSpacing=ref(0),tickInterval=computed(()=>globalMax.value/10),appResizeObserver=new ResizeObserver(entries=>{let entry=entries[0];canvas.value.width=entry.target.offsetWidth-130,canvas.value.height=entry.target.offsetHeight-20,tickSpacing.value=canvas.value.height/10,console.log(`width`,entry.target.offsetWidth),console.log(`height`,entry.target.offsetHeight),console.log(`tickspacing`,tickSpacing.value),console.log(`canvas`,canvas.value.width,canvas.value.height)}),chart=new SmoothieChart({minValue:0,maxValue:1e3,millisPerPixel:20,interpolation:`bezier`,grid:{fillStyle:`rgba(250,250,250,0.2)`,strokeStyle:`grey`,verticalSections:20,millisPerLine:1e3,sharpLines:!0},labels:{disabled:!0}}),torqueGraph=new TimeSeries,powerGraph=new TimeSeries,powerWheelGraph=new TimeSeries,rpmGraph=new TimeSeries;onMounted(()=>{initChart(),appResizeObserver.observe(app$1.value),$game.events.on(`onStreamsUpdate`,onStreamsUpdate),$game.streams.add(streamsList$1)}),onBeforeUnmount(()=>{appResizeObserver.unobserve(app$1.value)}),onUnmounted(()=>{$game.events.off(`onStreamsUpdate`,onStreamsUpdate),$game.streams.remove(streamsList$1)});function onStreamsUpdate(streams){for(let stream of streamsList$1)if(!streams[stream])return;let xPoint=new Date,torque=$game.units.torque(streams.engineInfo[8]).val,power$1=$game.units.power(streams.engineInfo[4]*.104719755*streams.engineInfo[8]/1e3*1.34102).val,wheelPower=$game.units.power(streams.engineInfo[20]/1e3*1.34102).val,rpm=streams.engineInfo[4]/10;torqueUnit.value=$game.units.torque().unit,powerUnit.value=$game.units.power().unit,globalMax.value=Math.ceil(Math.max.apply(null,[globalMax.value,torque,power$1])/100)*100,chart.options.maxValue=globalMax.value,torqueGraph.append(xPoint,torque),powerGraph.append(xPoint,power$1),powerWheelGraph.append(xPoint,wheelPower),rpmGraph.append(xPoint,rpm)}function initChart(){chart.addTimeSeries(torqueGraph,{strokeStyle:torqueGraphColor,lineWidth:1.5}),chart.addTimeSeries(powerGraph,{strokeStyle:powerGraphColor,lineWidth:1.5}),chart.addTimeSeries(powerWheelGraph,{strokeStyle:powerWheelGraphColor,lineWidth:1.5}),chart.addTimeSeries(rpmGraph,{strokeStyle:rpmGraphColor,lineWidth:1.5}),chart.streamTo(canvas.value,40)}return(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,{ref_key:`app`,ref:app$1,class:`engine-dynamometer`},[createBaseVNode(`div`,_hoisted_1$174,[createBaseVNode(`small`,_hoisted_2$143,toDisplayString(_ctx.$t(`ui.apps.engine_dynamometer.torqueFlywheel`)),1),createBaseVNode(`small`,_hoisted_3$128,toDisplayString(_ctx.$t(`ui.apps.engine_dynamometer.powerFlywheel`)),1),createBaseVNode(`small`,_hoisted_4$105,toDisplayString(_ctx.$t(`ui.apps.engine_dynamometer.powerWheels`)),1),createBaseVNode(`small`,_hoisted_5$91,toDisplayString(_ctx.$t(`ui.apps.engine_dynamometer.rpm`)),1)]),createBaseVNode(`div`,_hoisted_6$75,[createBaseVNode(`div`,_hoisted_7$65,[createBaseVNode(`div`,_hoisted_8$52,toDisplayString(_ctx.$t(`ui.apps.engine_dynamometer.power`))+` (`+toDisplayString(powerUnit.value)+`) `,1),(openBlock(),createElementBlock(Fragment,null,renderList(tickLabels,(n,index)=>createBaseVNode(`div`,{class:`ruler`,style:normalizeStyle({top:index*tickSpacing.value+`px`})},toDisplayString((globalMax.value-index*tickInterval.value).toFixed(0)),5)),64))]),createBaseVNode(`div`,_hoisted_9$46,[createBaseVNode(`canvas`,{ref_key:`canvas`,ref:canvas,class:`canvas`},null,512)]),createBaseVNode(`div`,_hoisted_10$39,[createBaseVNode(`div`,_hoisted_11$34,toDisplayString(_ctx.$t(`ui.apps.engine_dynamometer.torque`))+` (`+toDisplayString(torqueUnit.value)+`) `,1),(openBlock(),createElementBlock(Fragment,null,renderList(tickLabels,(n,index)=>createBaseVNode(`div`,{class:`ruler`,style:normalizeStyle({top:index*tickSpacing.value+`px`})},toDisplayString((globalMax.value-index*tickInterval.value).toFixed(0)),5)),64))])])],512))}},app_default$17=__plugin_vue_export_helper_default(_sfc_main$194,[[`__scopeId`,`data-v-e025129d`]]),_hoisted_1$173={class:`legends`},_hoisted_2$142={class:`water`},_hoisted_3$127={class:`oil`},_hoisted_4$104={class:`block`},_hoisted_5$90={class:`exhaust`},coolantGraphColor=`#333676`,oilGraphColor=`#AA8C39`,blockGraphColor=`#378B2E`,exhaustGraphColor=`#A7383E`,_sfc_main$193={__name:`app`,setup(__props){let{$game}=useLibStore(),streamsList$1=[`engineThermalData`],app$1=ref(null),canvas=ref(null),isRunning=ref(!1),appResizeObserver=new ResizeObserver(entries=>{let entry=entries[0];canvas.value.width=entry.target.offsetWidth,canvas.value.height=entry.target.offsetHeight}),chart=new SmoothieChart({minValue:50,maxValue:150,millisPerPixel:40,interpolation:`bezier`,grid:{fillStyle:`rgba(250,250,250,0.8)`,strokeStyle:`black`,verticalSections:0,millisPerLine:0},labels:{fillStyle:`black`}}),coolantGraph=new TimeSeries,oilGraph=new TimeSeries,blockGraph=new TimeSeries,exhaustGraph=new TimeSeries;onMounted(()=>{initChart(),appResizeObserver.observe(app$1.value),$game.streams.add(streamsList$1),$game.events.on(`onStreamsUpdate`,onStreamsUpdate)}),onBeforeUnmount(()=>{appResizeObserver.unobserve(app$1.value)}),onUnmounted(()=>{$game.events.off(`onStreamsUpdate`,onStreamsUpdate),$game.streams.remove(streamsList$1)});function onStreamsUpdate(streams){if(streams.engineThermalData){isRunning.value||(isRunning.value=!0,chart.start());let xPoint=new Date;coolantGraph.append(xPoint,streams.engineThermalData.coolantTemperature),oilGraph.append(xPoint,streams.engineThermalData.oilTemperature),blockGraph.append(xPoint,streams.engineThermalData.engineBlockTemperature),exhaustGraph.append(xPoint,streams.engineThermalData.exhaustTemperature)}else isRunning.value&&(isRunning.value=!1,chart.stop())}function initChart(){chart.addTimeSeries(coolantGraph,{strokeStyle:coolantGraphColor,lineWidth:1}),chart.addTimeSeries(oilGraph,{strokeStyle:oilGraphColor,lineWidth:1}),chart.addTimeSeries(blockGraph,{strokeStyle:blockGraphColor,lineWidth:1}),chart.addTimeSeries(exhaustGraph,{strokeStyle:exhaustGraphColor,lineWidth:1}),chart.streamTo(canvas.value,40)}return(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,{ref_key:`app`,ref:app$1,class:`engine-hdg`},[createBaseVNode(`div`,_hoisted_1$173,[createBaseVNode(`small`,_hoisted_2$142,toDisplayString(_ctx.$t(`ui.apps.engine_heat_debug_graph.water`)),1),createBaseVNode(`small`,_hoisted_3$127,toDisplayString(_ctx.$t(`ui.apps.engine_heat_debug_graph.oil`)),1),createBaseVNode(`small`,_hoisted_4$104,toDisplayString(_ctx.$t(`ui.apps.engine_heat_debug_graph.block`)),1),createBaseVNode(`small`,_hoisted_5$90,toDisplayString(_ctx.$t(`ui.apps.engine_heat_debug_graph.exhaust`)),1)]),createBaseVNode(`canvas`,{ref_key:`canvas`,ref:canvas},null,512)],512))}},app_default$18=__plugin_vue_export_helper_default(_sfc_main$193,[[`__scopeId`,`data-v-ac69837e`]]),_hoisted_1$172={class:`bng-app thermal-clutch-debug`},_hoisted_2$141={class:`set-name`},_sfc_main$192={__name:`app`,setup(__props){let{$game}=useLibStore(),streamsList$1=[`engineThermalData`],data=ref(null);onMounted(()=>{$game.streams.add(streamsList$1)}),onUnmounted(()=>{$game.streams.remove(streamsList$1)}),$game.events.on(`onStreamsUpdate`,streams=>data.value=streams.engineThermalData?parseData(streams.engineThermalData):null);function parseData(data$1){return[{str:$game.units.buildString(`temperature`,data$1.coolantTemperature,0),name:`ui.apps.engine_thermal_debug.coolant`,warn:data$1.coolantTemperature>data$1.thermostatTemperature&&data$1.coolantTemperature<120&&data$1.thermostatStatus==1,error:data$1.coolantTemperature>120},{str:$game.units.buildString(`temperature`,data$1.oilTemperature,0),name:`ui.apps.engine_thermal_debug.oil`,warn:data$1.oilTemperature>140,error:data$1.oilTemperature>150},{str:$game.units.buildString(`temperature`,data$1.engineBlockTemperature,0),name:`ui.apps.engine_thermal_debug.block`},{str:$game.units.buildString(`temperature`,data$1.cylinderWallTemperature,0),name:`ui.apps.engine_thermal_debug.cylinderlWall`},{str:$game.units.buildString(`temperature`,data$1.exhaustTemperature,0),name:`ui.apps.engine_thermal_debug.exhaustManifold`},{str:data$1.thermostatStatus.toFixed(3),name:`ui.apps.engine_thermal_debug.coolantThermostat`,warn:data$1.thermostatStatus>.9},{str:data$1.airRegulatorStatus.toFixed(3),name:`ui.apps.engine_thermal_debug.airRegulator`,warn:data$1.airRegulatorStatus>.9},{str:$game.units.buildString(`speed`,data$1.radiatorAirSpeed,0),name:`ui.apps.engine_thermal_debug.radiatorAirSpeed`},{str:data$1.radiatorAirSpeedEfficiency.toFixed(4),name:`ui.apps.engine_thermal_debug.radiatorAirSpeedEfficiency`},{str:data$1.fanActive,name:`ui.apps.engine_thermal_debug.radiatorFanActive`},{str:data$1.coolantMass.toFixed(3),name:`ui.apps.engine_thermal_debug.coolantMass`},{str:data$1.coolantLeakRateOverpressure.toFixed(3),name:`ui.apps.engine_thermal_debug.coolantLeakRateOverpressure`,warn:data$1.coolantLeakRateOverpressure>0},{str:data$1.coolantLeakRateHeadGasket.toFixed(3),name:`ui.apps.engine_thermal_debug.coolantLeakRateHeadGasket`,warn:data$1.coolantLeakRateHeadGasket>0},{str:data$1.coolantLeakRateRadiator.toFixed(3),name:`ui.apps.engine_thermal_debug.coolantLeakRateRadiator`,warn:data$1.coolantLeakRateRadiator>0},{str:data$1.coolantLeakRateOverall.toFixed(3),name:`ui.apps.engine_thermal_debug.coolantLeakRateOverall`,warn:data$1.coolantLeakRateOverall>0},{str:data$1.coolantEfficiency.toFixed(3),name:`ui.apps.engine_thermal_debug.coolantEfficiency`,warn:data$1.coolantEfficiency<1,error:data$1.coolantEfficiency===0},{str:data$1.oilThermostatStatus.toFixed(3),name:`ui.apps.engine_thermal_debug.oilThermostat`,warn:data$1.oilThermostatStatus>.9},{str:data$1.oilMass.toFixed(3),name:`ui.apps.engine_thermal_debug.oilMass`,warn:data$1.oilMassdata$1.maximumSafeOilMass},{str:data$1.miniumSafeOilMass.toFixed(3),name:`ui.apps.engine_thermal_debug.miniumSafeOilMass`},{str:data$1.maximumSafeOilMass.toFixed(3),name:`ui.apps.engine_thermal_debug.maximumSafeOilMass`},{str:data$1.oilLeakRateOilpan.toFixed(3),name:`ui.apps.engine_thermal_debug.oilLeakRateOilpan`,warn:data$1.oilLeakRateOilpan>0},{str:data$1.oilLeakRateRadiator.toFixed(3),name:`ui.apps.engine_thermal_debug.oilLeakRateRadiator`,warn:data$1.oilLeakRateRadiator>0},{str:data$1.oilLeakRateGravity.toFixed(3),name:`ui.apps.engine_thermal_debug.oilLeakRateGravity`,warn:data$1.oilLeakRateGravity>0},{str:data$1.oilLeakRatePistonRingDamage.toFixed(3),name:`ui.apps.engine_thermal_debug.oilLeakRatePistonRingDamage`,warn:data$1.oilLeakRatePistonRingDamage>0},{str:data$1.oilLeakRateOverall.toFixed(3),name:`ui.apps.engine_thermal_debug.oilLeakRateOverall`,warn:data$1.oilLeakRateOverall>0},{str:data$1.oilStarvingSevernessXY.toFixed(3),name:`ui.apps.engine_thermal_debug.oilStarvingSevernessXY`,warn:data$1.oilStarvingSevernessXY>0},{str:data$1.oilStarvingSevernessZ.toFixed(3),name:`ui.apps.engine_thermal_debug.oilStarvingSevernessZ`,warn:data$1.oilStarvingSevernessZ>0},{str:data$1.maximumSafeG.toFixed(3),name:`ui.apps.engine_thermal_debug.maximumSafeG`},{str:data$1.oilLubricationCoef.toFixed(3),name:`ui.apps.engine_thermal_debug.oilLubricationCoef`,warn:data$1.oilLubricationCoef<1},{str:data$1.missingOilDamage.toFixed(3),name:`ui.apps.engine_thermal_debug.missingOilDamage`,warn:data$1.missingOilDamage>0},{str:data$1.engineEfficiency.toFixed(2),name:`ui.apps.engine_thermal_debug.engineEfficiency`},{str:$game.units.buildString(`energy`,data$1.energyToCylinderWall,0),name:`ui.apps.engine_thermal_debug.qtocylinderwall`},{str:$game.units.buildString(`energy`,data$1.energyCylinderWallToCoolant,0),name:`ui.apps.engine_thermal_debug.qcylinderwalltocoolant`},{str:$game.units.buildString(`energy`,data$1.energyCoolantToAir,0),name:`ui.apps.engine_thermal_debug.qcoolanttoair`},{str:$game.units.buildString(`energy`,data$1.energyCoolantToBlock,0),name:`ui.apps.engine_thermal_debug.qcoolanttoblock`},{str:$game.units.buildString(`energy`,data$1.energyCylinderWallToBlock,0),name:`ui.apps.engine_thermal_debug.qcylinderwalltoblock`},{str:$game.units.buildString(`energy`,data$1.energyBlockToAir,0),name:`ui.apps.engine_thermal_debug.qblocktoair`},{str:$game.units.buildString(`energy`,data$1.energyToOil,0),name:`ui.apps.engine_thermal_debug.qtooil`},{str:$game.units.buildString(`energy`,data$1.energyCylinderWallToOil,0),name:`ui.apps.engine_thermal_debug.qcylinderwalltooil`},{str:$game.units.buildString(`energy`,data$1.energyOilToAir,0),name:`ui.apps.engine_thermal_debug.qoilradiatortoair`},{str:$game.units.buildString(`energy`,data$1.energyOilSumpToAir,0),name:`ui.apps.engine_thermal_debug.qoilsumptoair`},{str:$game.units.buildString(`energy`,data$1.energyToExhaust,0),name:`ui.apps.engine_thermal_debug.qtoexhaust`},{str:$game.units.buildString(`energy`,data$1.energyExhaustToAir,0),name:`ui.apps.engine_thermal_debug.qexhausttoair`},{str:data$1.engineBlockOverheatDamage.toFixed(),name:`ui.apps.engine_thermal_debug.blockDamage`,warn:data$1.engineBlockOverheatDamage>0},{str:data$1.oilOverheatDamage.toFixed(),name:`ui.apps.engine_thermal_debug.oilDamage`,warn:data$1.oilOverheatDamage>0},{str:data$1.cylinderWallOverheatDamage.toFixed(),name:`ui.apps.engine_thermal_debug.cylinderwallDamage`,warn:data$1.cylinderWallOverheatDamage>0},{str:data$1.headGasketBlown,name:`ui.apps.engine_thermal_debug.headGasketBlown`,error:data$1.headGasketBlown},{str:data$1.pistonRingsDamaged,name:`ui.apps.engine_thermal_debug.pistonRingsDamaged`,error:data$1.pistonRingsDamaged},{str:data$1.connectingRodBearingsDamaged,name:`ui.apps.engine_thermal_debug.connectingRodBearingsDamaged`,error:data$1.connectingRodBearingsDamaged}]}return(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$172,[(openBlock(!0),createElementBlock(Fragment,null,renderList(data.value,(set,index)=>(openBlock(),createElementBlock(`div`,{key:index,class:`set`},[createBaseVNode(`div`,_hoisted_2$141,toDisplayString(_ctx.$t(set.name)),1),createBaseVNode(`div`,{class:normalizeClass([`set-value`,{"thermal-warning":set.warn,"thermal-error":set.error}])},toDisplayString(set.str),3)]))),128))]))}},app_default$19=__plugin_vue_export_helper_default(_sfc_main$192,[[`__scopeId`,`data-v-6de0b81a`]]),_hoisted_1$171={"xmlns:dc":`http://purl.org/dc/elements/1.1/`,"xmlns:cc":`http://creativecommons.org/ns#`,"xmlns:rdf":`http://www.w3.org/1999/02/22-rdf-syntax-ns#`,"xmlns:svg":`http://www.w3.org/2000/svg`,xmlns:`http://www.w3.org/2000/svg`,"xmlns:xlink":`http://www.w3.org/1999/xlink`,"xmlns:sodipodi":`http://sodipodi.sourceforge.net/DTD/sodipodi-0.dtd`,"xmlns:inkscape":`http://www.inkscape.org/namespaces/inkscape`,version:`1.1`,width:`100%`,height:`100%`,viewBox:`0 0 660 660`},_hoisted_2$140={"inkscape:groupmode":`layer`,id:`layer6`,class:`layer6`,"inkscape:label":`new`,style:{display:`inline`}},_hoisted_3$126={"xml:space":`preserve`,style:{"font-style":`normal`,"font-variant":`normal`,"font-weight":`normal`,"font-stretch":`normal`,"font-size":`159.64709473px`,"line-height":`125%`,"font-family":`'Squada One'`,"-inkscape-font-specification":`'Squada One'`,"text-align":`center`,"letter-spacing":`0px`,"word-spacing":`0px`,"writing-mode":`lr-tb`,"text-anchor":`middle`,display:`inline`,fill:`#ffffff`,"fill-opacity":`1`,stroke:`none`},x:`329.85437`,y:`328.48807`,id:`tspan4449-43`,"sodipodi:linespacing":`125%`,"inkscape:label":`#pressureText`},_hoisted_4$103={"xml:space":`preserve`,style:{"font-style":`normal`,"font-variant":`normal`,"font-weight":`normal`,"font-stretch":`normal`,"font-size":`65px`,"line-height":`125%`,"font-family":`'Squada One'`,"-inkscape-font-specification":`'Squada One'`,"text-align":`center`,"letter-spacing":`0px`,"word-spacing":`0px`,"writing-mode":`lr-tb`,"text-anchor":`middle`,display:`inline`,fill:`#ffffff`,"fill-opacity":`0.78835976`,stroke:`none`},x:`329.03198`,y:`413.62915`,id:`speed_units`,"sodipodi:linespacing":`125%`,"inkscape:label":`#speed_units`,"inkscape:transform-center-y":`-4.486084`},_hoisted_5$89=[`id`,`x`,`y`],_hoisted_6$74=[`id`,`x`,`y`],_hoisted_7$64={"inkscape:groupmode":`layer`,id:`layer3`,"inkscape:label":`FIX`,style:{display:`inline`}},_hoisted_8$51={id:`revcurvemask`,style:{display:`inline`}},_hoisted_9$45={"inkscape:groupmode":`layer`,id:`layer11`,"inkscape:label":`revs`,style:{display:`inline`}},_hoisted_10$38={"inkscape:groupmode":`layer`,id:`layer7`,"inkscape:label":`new2`,style:{display:`inline`}},width=660,height=660,dashSize=5,pressureTextSize=50,dashCount=5,PRESURE_MAX_CONST=150,PRESURE_MIN_CONST=-100,_sfc_main$191={__name:`forcedInduction`,setup(__props,{expose:__expose}){let initialized=ref(!1),pressureTextRef=ref(null),pressureCurveRef=ref(null),pressureCurveLen=computed(()=>pressureCurveRef.value.getTotalLength()),pressureCurveDashesRef=ref(null),pressureCurveDashesLen=computed(()=>pressureCurveDashesRef.value.getTotalLength()),redLineRef=ref(null),redLineLen=computed(()=>redLineRef.value.getTotalLength()),pressureTextGuideLineRef=ref(null),pressureTextGuideLineLen=computed(()=>pressureTextGuideLineRef.value.getTotalLength()),pressureTextRefs=ref([]),pressureTextAttrs=ref([{id:`pressuretext1`,x:197.49423,y:531.5639,text:1},{id:`pressuretext2`,x:124.71793,y:434.92328,text:2},{id:`pressuretext3`,x:110.04411,y:303.35791,text:3},{id:`pressuretext4`,x:165.89227,y:187.39682,text:4},{id:`pressuretext5`,x:284.48657,y:123.71478,text:5},{id:`pressuretext6`,x:419.43579,y:137.55835,text:6},{id:`pressuretext7`,x:520.0791,y:228.94992,text:7},{id:`pressuretext8`,x:520.0791,y:228.94992,text:8},{id:`pressuretext9`,x:520.0791,y:228.94992,text:9},{id:`pressuretext10`,x:520.0791,y:228.94992,text:10}]),pressureTSpanRefs=ref([]),pressureMax=ref(null),pressureMin=ref(null),pressureNeedleRef=ref(null),pressureUnitRef=ref(null),UiUnitscallback=ref(()=>null),roundDecCallback=ref(()=>0);onMounted(()=>{pressureTextRef.value.textContent=``,pressureCurveRef.value.style.strokeDasharray=pressureCurveLen.value+` `+pressureCurveLen.value,pressureTextGuideLineRef.value.style.display=`none`;for(let k=0;k10?0:1),rpSpan.style.visibility=`visible`}initialized.value=!0}applyData(streamData)}function reset$1(){initialized.value=!1;for(let k=0;k1&&(percPos=1),pressureNeedleRef.value.setAttribute(`transform`,`rotate(`+(percPos*270-135)+`,`+width/2+`,`+height/2+`)`),pressureCurveRef.value.style.strokeDashoffset=pressureCurveLen.value-pressureCurveLen.value*percPos}function UnitPressure(val){let convertedVal=UiUnitscallback.value(val,`pressure`);return pressureNeedleRef.value.textContent!==convertedVal.unit&&(pressureUnitRef.value.textContent=convertedVal.unit,initialized.value=!1),convertedVal.val}return(_ctx,_cache)=>(openBlock(),createElementBlock(`svg`,_hoisted_1$171,[_cache[4]||=createBaseVNode(`defs`,{id:`defs4`},[createBaseVNode(`linearGradient`,{id:`linearGradient3938`},[createBaseVNode(`stop`,{style:{"stop-color":`#ff0000`,"stop-opacity":`1`},offset:`0`,id:`stop3940`}),createBaseVNode(`stop`,{style:{"stop-color":`#00ff4b`,"stop-opacity":`1`},offset:`1`,id:`stop3942`})]),createBaseVNode(`linearGradient`,{id:`linearGradient4607`},[createBaseVNode(`stop`,{id:`stop4609`,offset:`0`,style:{"stop-color":`#e40000`,"stop-opacity":`1`}}),createBaseVNode(`stop`,{style:{"stop-color":`#e40000`,"stop-opacity":`1`},offset:`0.89960396`,id:`stop4611`}),createBaseVNode(`stop`,{id:`stop4613`,offset:`1`,style:{"stop-color":`#e40000`,"stop-opacity":`0`}}),createBaseVNode(`stop`,{id:`stop4615`,offset:`1`,style:{"stop-color":`#e40000`,"stop-opacity":`0`}})]),createBaseVNode(`linearGradient`,{id:`linearGradient4597`},[createBaseVNode(`stop`,{id:`stop4599`,offset:`0`,style:{"stop-color":`#e40000`,"stop-opacity":`1`}}),createBaseVNode(`stop`,{style:{"stop-color":`#e40000`,"stop-opacity":`1`},offset:`0.99812102`,id:`stop4601`}),createBaseVNode(`stop`,{id:`stop4603`,offset:`1`,style:{"stop-color":`#e40000`,"stop-opacity":`0`}}),createBaseVNode(`stop`,{id:`stop4605`,offset:`1`,style:{"stop-color":`#e40000`,"stop-opacity":`1`}})]),createBaseVNode(`linearGradient`,{id:`linearGradient4545`},[createBaseVNode(`stop`,{style:{"stop-color":`#e40000`,"stop-opacity":`1`},offset:`0`,id:`stop4547`}),createBaseVNode(`stop`,{id:`stop4553`,offset:`0.9861111`,style:{"stop-color":`#e40000`,"stop-opacity":`1`}}),createBaseVNode(`stop`,{style:{"stop-color":`#e40000`,"stop-opacity":`0`},offset:`1`,id:`stop4555`}),createBaseVNode(`stop`,{style:{"stop-color":`#e40000`,"stop-opacity":`0`},offset:`1`,id:`stop4549`})]),createBaseVNode(`linearGradient`,{"inkscape:collect":`always`,id:`linearGradient4256`},[createBaseVNode(`stop`,{style:{"stop-color":`#6d0000`,"stop-opacity":`1`},offset:`0`,id:`stop4258`}),createBaseVNode(`stop`,{style:{"stop-color":`#6d0000`,"stop-opacity":`0`},offset:`1`,id:`stop4260`})]),createBaseVNode(`linearGradient`,{id:`linearGradient4365`},[createBaseVNode(`stop`,{style:{"stop-color":`#000000`,"stop-opacity":`0.42857143`},offset:`0`,id:`stop4367`}),createBaseVNode(`stop`,{id:`stop4373`,offset:`0.5`,style:{"stop-color":`#000000`,"stop-opacity":`0.33035713`}}),createBaseVNode(`stop`,{style:{"stop-color":`#000000`,"stop-opacity":`0`},offset:`1`,id:`stop4369`})]),createBaseVNode(`linearGradient`,{id:`linearGradient4357`},[createBaseVNode(`stop`,{style:{"stop-color":`#000000`,"stop-opacity":`1`},offset:`0`,id:`stop4359`}),createBaseVNode(`stop`,{style:{"stop-color":`#000000`,"stop-opacity":`0.19642857`},offset:`1`,id:`stop4361`})]),createBaseVNode(`marker`,{style:{overflow:`visible`},id:`DistanceStart`,refX:`0`,refY:`0`,orient:`auto`,"inkscape:stockid":`DistanceStart`},[createBaseVNode(`g`,{id:`g2300`},[createBaseVNode(`path`,{style:{fill:`none`,stroke:`#ffffff`,"stroke-width":`1.14999998`,"stroke-linecap":`square`},d:`M 0,0 2,0`,id:`path2306`,"inkscape:connector-curvature":`0`}),createBaseVNode(`path`,{style:{fill:`#000000`,"fill-rule":`evenodd`,stroke:`none`},d:`M 0,0 13,4 9,0 13,-4 0,0 z`,id:`path2302`,"inkscape:connector-curvature":`0`}),createBaseVNode(`path`,{style:{fill:`none`,stroke:`#000000`,"stroke-width":`1`,"stroke-linecap":`square`},d:`M 0,-4 0,40`,id:`path2304`,"inkscape:connector-curvature":`0`})])]),createBaseVNode(`radialGradient`,{"inkscape:collect":`always`,"xlink:href":`#linearGradient4357`,id:`radialGradient4363`,cx:`480`,cy:`544`,fx:`480`,fy:`544`,r:`320`,gradientUnits:`userSpaceOnUse`,gradientTransform:`matrix(1.03125,0,0,1.03125,-15,-17)`}),createBaseVNode(`radialGradient`,{"inkscape:collect":`always`,"xlink:href":`#linearGradient4365`,id:`radialGradient4371`,cx:`480`,cy:`544`,fx:`480`,fy:`544`,r:`320`,gradientUnits:`userSpaceOnUse`}),createBaseVNode(`clipPath`,{clipPathUnits:`userSpaceOnUse`,id:`clipPath4407`},[createBaseVNode(`path`,{"inkscape:connector-curvature":`0`,id:`path4409`,d:`m 480,-103.33 c -357.5105,0 -647.33,289.8195 -647.33,647.33 0,357.5105 289.8195,647.33 647.33,647.33 357.5105,0 647.33,-289.8195 647.33,-647.33 0,-357.5105 -289.8195,-647.33 -647.33,-647.33 z m 0,453.131 c 107.25316,0 194.199,86.94584 194.199,194.199 0,107.25316 -86.94584,194.199 -194.199,194.199 -107.25316,0 -194.199,-86.94584 -194.199,-194.199 0,-107.25316 86.94584,-194.199 194.199,-194.199 z`,style:{color:`#000000`,fill:`#ffffff`,"fill-opacity":`0.61375661`,"fill-rule":`nonzero`,stroke:`none`,"stroke-width":`16`,marker:`none`,visibility:`visible`,display:`inline`,overflow:`visible`,"enable-background":`accumulate`}})]),createBaseVNode(`clipPath`,{clipPathUnits:`userSpaceOnUse`,id:`clipPath4321-9`},[createBaseVNode(`path`,{style:{color:`#000000`,fill:`#ffffff`,"fill-opacity":`1`,"fill-rule":`nonzero`,stroke:`none`,"stroke-width":`5`,marker:`none`,visibility:`visible`,display:`inline`,overflow:`visible`,"enable-background":`accumulate`},d:`m 480,224 c -20.28024,0 -40.11069,1.89279 -59.34375,5.5 l 12.0625,58.8125 C 448.05208,285.49499 463.85489,284 480,284 c 35.52728,0 69.40254,7.13112 100.25,20.03125 l 24.1875,-54.9375 C 566.18747,232.93508 524.13347,224 480,224 z m -69.0625,7.5 c -59.26533,13.0371 -112.35258,42.49901 -154.28125,83.375 l 42.53125,42.3125 c 24.37935,-23.60266 53.35266,-42.49216 85.46875,-55.15625 1.96795,-0.77601 3.94641,-1.52096 5.9375,-2.25 10.51172,-3.84886 21.33856,-7.01901 32.4375,-9.5 L 410.9375,231.5 z M 613.5,253.125 589.3125,308.03125 c 44.07702,20.45389 81.43119,52.91567 107.9375,93.15625 l 50.875,-31.875 C 715.25578,318.96815 668.59379,278.45303 613.5,253.125 z m -363.8125,68.75 c -41.23795,42.75016 -70.70543,96.92973 -83.125,157.34375 l 59.03125,11.0625 c 10.15322,-48.33557 33.70357,-91.7229 66.625,-126.09375 L 249.6875,321.875 z m 503.78125,55.8125 -50.90625,31.84375 C 726.31882,448.76688 740,494.78478 740,544 l 60,0 c 0,-60.90677 -16.99384,-117.84887 -46.53125,-166.3125 z m -588.75,111.25 C 161.61652,506.82573 160,525.2248 160,544 c 0,42.78463 8.42108,83.60181 23.65625,120.90625 L 238.84375,641.375 C 226.69144,611.30216 220,578.42944 220,544 c 0,-2.24366 0.0373,-4.48871 0.0937,-6.71875 0.3211,-12.67426 1.55282,-25.12039 3.625,-37.28125 l -59,-11.0625 z M 242.75,650.5 187.53125,674 c 23.4008,52.56805 60.5346,97.67196 106.875,130.71875 l 34.0625,-49.4375 C 291.42063,728.66516 261.6562,692.55546 242.75,650.5 z m 93.875,110.40625 -34.03125,49.40625 C 353.37348,844.20872 414.36502,864 480,864 l 0,-60 c -33.65485,0 -65.82451,-6.39115 -95.34375,-18.03125 -1.96795,-0.77601 -3.93088,-1.58396 -5.875,-2.40625 -14.80462,-6.26183 -28.90394,-13.88046 -42.15625,-22.65625 z`,id:`path4323-8`,"inkscape:connector-curvature":`0`})]),createBaseVNode(`radialGradient`,{"inkscape:collect":`always`,"xlink:href":`#linearGradient4357`,id:`radialGradient4363-9`,cx:`480`,cy:`544`,fx:`480`,fy:`544`,r:`320`,gradientUnits:`userSpaceOnUse`,gradientTransform:`matrix(1.03125,0,0,1.03125,-15,-17)`}),createBaseVNode(`clipPath`,{clipPathUnits:`userSpaceOnUse`,id:`clipPath4407-3`},[createBaseVNode(`path`,{"inkscape:connector-curvature":`0`,id:`path4409-5`,d:`m 480,-103.33 c -357.5105,0 -647.33,289.8195 -647.33,647.33 0,357.5105 289.8195,647.33 647.33,647.33 357.5105,0 647.33,-289.8195 647.33,-647.33 0,-357.5105 -289.8195,-647.33 -647.33,-647.33 z m 0,453.131 c 107.25316,0 194.199,86.94584 194.199,194.199 0,107.25316 -86.94584,194.199 -194.199,194.199 -107.25316,0 -194.199,-86.94584 -194.199,-194.199 0,-107.25316 86.94584,-194.199 194.199,-194.199 z`,style:{color:`#000000`,fill:`#ffffff`,"fill-opacity":`0.61375661`,"fill-rule":`nonzero`,stroke:`none`,"stroke-width":`16`,marker:`none`,visibility:`visible`,display:`inline`,overflow:`visible`,"enable-background":`accumulate`}})]),createBaseVNode(`radialGradient`,{gradientTransform:`matrix(0.37015162,0,0,0.37015162,685.90181,-270.76027)`,"inkscape:collect":`always`,"xlink:href":`#linearGradient4365`,id:`radialGradient4371-4`,cx:`480`,cy:`544`,fx:`480`,fy:`544`,r:`320`,gradientUnits:`userSpaceOnUse`}),createBaseVNode(`linearGradient`,{"inkscape:collect":`always`,"xlink:href":`#linearGradient4256`,id:`linearGradient4433`,gradientUnits:`userSpaceOnUse`,x1:`569.20557`,y1:`424.29861`,x2:`890.55139`,y2:`424.29861`}),createBaseVNode(`clipPath`,{clipPathUnits:`userSpaceOnUse`,id:`clipPath4321-4`},[createBaseVNode(`path`,{style:{color:`#000000`,fill:`#ffffff`,"fill-opacity":`1`,"fill-rule":`nonzero`,stroke:`none`,"stroke-width":`5`,marker:`none`,visibility:`visible`,display:`inline`,overflow:`visible`,"enable-background":`accumulate`},d:`m 480,224 c -20.28024,0 -40.11069,1.89279 -59.34375,5.5 l 12.0625,58.8125 C 448.05208,285.49499 463.85489,284 480,284 c 35.52728,0 69.40254,7.13112 100.25,20.03125 l 24.1875,-54.9375 C 566.18747,232.93508 524.13347,224 480,224 z m -69.0625,7.5 c -59.26533,13.0371 -112.35258,42.49901 -154.28125,83.375 l 42.53125,42.3125 c 24.37935,-23.60266 53.35266,-42.49216 85.46875,-55.15625 1.96795,-0.77601 3.94641,-1.52096 5.9375,-2.25 10.51172,-3.84886 21.33856,-7.01901 32.4375,-9.5 L 410.9375,231.5 z M 613.5,253.125 589.3125,308.03125 c 44.07702,20.45389 81.43119,52.91567 107.9375,93.15625 l 50.875,-31.875 C 715.25578,318.96815 668.59379,278.45303 613.5,253.125 z m -363.8125,68.75 c -41.23795,42.75016 -70.70543,96.92973 -83.125,157.34375 l 59.03125,11.0625 c 10.15322,-48.33557 33.70357,-91.7229 66.625,-126.09375 L 249.6875,321.875 z m 503.78125,55.8125 -50.90625,31.84375 C 726.31882,448.76688 740,494.78478 740,544 l 60,0 c 0,-60.90677 -16.99384,-117.84887 -46.53125,-166.3125 z m -588.75,111.25 C 161.61652,506.82573 160,525.2248 160,544 c 0,42.78463 8.42108,83.60181 23.65625,120.90625 L 238.84375,641.375 C 226.69144,611.30216 220,578.42944 220,544 c 0,-2.24366 0.0373,-4.48871 0.0937,-6.71875 0.3211,-12.67426 1.55282,-25.12039 3.625,-37.28125 l -59,-11.0625 z M 242.75,650.5 187.53125,674 c 23.4008,52.56805 60.5346,97.67196 106.875,130.71875 l 34.0625,-49.4375 C 291.42063,728.66516 261.6562,692.55546 242.75,650.5 z m 93.875,110.40625 -34.03125,49.40625 C 353.37348,844.20872 414.36502,864 480,864 l 0,-60 c -33.65485,0 -65.82451,-6.39115 -95.34375,-18.03125 -1.96795,-0.77601 -3.93088,-1.58396 -5.875,-2.40625 -14.80462,-6.26183 -28.90394,-13.88046 -42.15625,-22.65625 z`,id:`path4323-7`,"inkscape:connector-curvature":`0`})]),createBaseVNode(`radialGradient`,{"inkscape:collect":`always`,"xlink:href":`#linearGradient4357`,id:`radialGradient4363-5`,cx:`480`,cy:`544`,fx:`480`,fy:`544`,r:`320`,gradientUnits:`userSpaceOnUse`,gradientTransform:`matrix(1.03125,0,0,1.03125,-15,-17)`}),createBaseVNode(`clipPath`,{clipPathUnits:`userSpaceOnUse`,id:`clipPath4407-6`},[createBaseVNode(`path`,{"inkscape:connector-curvature":`0`,id:`path4409-1`,d:`m 480,-103.33 c -357.5105,0 -647.33,289.8195 -647.33,647.33 0,357.5105 289.8195,647.33 647.33,647.33 357.5105,0 647.33,-289.8195 647.33,-647.33 0,-357.5105 -289.8195,-647.33 -647.33,-647.33 z m 0,453.131 c 107.25316,0 194.199,86.94584 194.199,194.199 0,107.25316 -86.94584,194.199 -194.199,194.199 -107.25316,0 -194.199,-86.94584 -194.199,-194.199 0,-107.25316 86.94584,-194.199 194.199,-194.199 z`,style:{color:`#000000`,fill:`#ffffff`,"fill-opacity":`0.61375661`,"fill-rule":`nonzero`,stroke:`none`,"stroke-width":`16`,marker:`none`,visibility:`visible`,display:`inline`,overflow:`visible`,"enable-background":`accumulate`}})]),createBaseVNode(`radialGradient`,{gradientTransform:`matrix(0.36968813,0,0,0.36968813,1026.9451,-270.68256)`,"inkscape:collect":`always`,"xlink:href":`#linearGradient4365`,id:`radialGradient4371-49`,cx:`480`,cy:`544`,fx:`480`,fy:`544`,r:`320`,gradientUnits:`userSpaceOnUse`}),createBaseVNode(`linearGradient`,{"inkscape:collect":`always`,"xlink:href":`#linearGradient4256`,id:`linearGradient4746`,gradientUnits:`userSpaceOnUse`,x1:`569.20557`,y1:`424.29861`,x2:`890.55139`,y2:`424.29861`}),createBaseVNode(`clipPath`,{clipPathUnits:`userSpaceOnUse`,id:`clipPath3921`},[createBaseVNode(`path`,{"inkscape:connector-curvature":`0`,id:`path3923`,d:`m 480,224 c -20.95323,0 -41.43416,2.01857 -61.26367,5.86328 l 12.08008,58.80274 C 446.74495,285.61583 463.18224,284 480,284 c 36.22419,0 70.7135,7.41519 102.04492,20.79883 l 24.1836,-54.92188 C 567.49749,233.23259 524.82925,224 480,224 z m -67.13867,7.07812 c -60.69914,12.96113 -115.01734,43.12659 -157.60938,85.15821 l 42.54297,42.3125 c 34.42536,-33.82645 78.22177,-58.13556 127.14258,-68.68555 l -12.07617,-58.78516 z m 198.86328,21.20508 -24.1875,54.9336 c 45.44422,20.67199 83.88358,54.04459 110.80078,95.58008 l 50.87305,-31.84376 C 715.93577,319.29347 668.20331,277.82636 611.72461,252.2832 z m -360.70117,68.21094 c -42.37565,43.40627 -72.5223,98.80082 -84.8418,160.63281 l 58.99024,11.05664 c 10.06229,-49.7524 34.33605,-94.34359 68.39257,-129.3789 l -42.54101,-42.31055 z m 501.3789,55.54102 -50.86132,31.83398 C 725.92383,447.46544 740,494.08649 740,544 l 60,0 C 800,482.39079 782.57195,424.85952 752.40234,376.03516 z M 165.06055,487.02148 C 161.7373,505.51211 160,524.55271 160,544 c 0,43.47625 8.68492,84.91949 24.39062,122.71094 l 55.21485,-23.5293 C 226.98058,612.61583 220,579.12541 220,544 c 0,-15.6701 1.38639,-31.01527 4.04297,-45.92188 l -58.98242,-11.05664 z m 76.90039,161.67774 -55.20899,23.52734 c 23.61428,53.92719 61.65397,100.09134 109.25586,133.60352 l 34.03516,-49.41406 C 291.73258,729.3212 261.08736,692.12046 241.96094,648.69922 z m 93.01953,111.12695 -34.04102,49.42188 C 352.04051,843.81227 413.66249,864 480,864 l 0,-60 c -53.69777,0 -103.59151,-16.28243 -145.01953,-44.17383 z`,style:{color:`#000000`,fill:`#ffffff`,"fill-opacity":`1`,"fill-rule":`nonzero`,stroke:`none`,"stroke-width":`5`,marker:`none`,visibility:`visible`,display:`inline`,overflow:`visible`,"enable-background":`accumulate`}})]),createBaseVNode(`clipPath`,{clipPathUnits:`userSpaceOnUse`,id:`clipPath3925-1`},[createBaseVNode(`path`,{"inkscape:connector-curvature":`0`,id:`path3927-7`,d:`m 330,10 c -20.95323,0 -41.43416,2.01857 -61.26367,5.86328 l 12.08008,58.80274 C 296.74495,71.61583 313.18224,70 330,70 c 36.22419,0 70.7135,7.41519 102.04492,20.79883 l 24.1836,-54.92188 C 417.49749,19.23259 374.82925,10 330,10 z m -67.13867,7.07812 C 202.16219,30.03925 147.84399,60.20471 105.25195,102.23633 l 42.54297,42.3125 C 182.22028,110.72238 226.01669,86.41327 274.9375,75.86328 L 262.86133,17.07812 z m 198.86328,21.20508 -24.1875,54.9336 c 45.44422,20.67199 83.88358,54.04459 110.80078,95.58008 l 50.87305,-31.84376 C 565.93577,105.29347 518.20331,63.82636 461.72461,38.2832 z m -360.70117,68.21094 c -42.37565,43.40627 -72.5223,98.80082 -84.8418,160.63281 l 58.99024,11.05664 c 10.06229,-49.7524 34.33605,-94.34359 68.39257,-129.3789 l -42.54101,-42.31055 z m 501.3789,55.54102 -50.86132,31.83398 C 575.92383,233.46544 590,280.08649 590,330 l 60,0 C 650,268.39079 632.57195,210.85952 602.40234,162.03516 z M 15.06055,273.02148 C 11.7373,291.51211 10,310.55271 10,330 c 0,43.47625 8.68492,84.91949 24.39062,122.71094 l 55.21485,-23.5293 C 76.98058,398.61583 70,365.12541 70,330 c 0,-15.6701 1.38639,-31.01527 4.04297,-45.92188 L 15.06055,273.02148 z m 76.90039,161.67774 -55.20899,23.52734 c 23.61428,53.92719 61.65397,100.09134 109.25586,133.60352 l 34.03516,-49.41406 C 141.73258,515.3212 111.08736,478.12046 91.96094,434.69922 z m 93.01953,111.12695 -34.04102,49.42188 C 202.04051,629.81227 263.66249,650 330,650 l 0,-60 c -53.69777,0 -103.59151,-16.28243 -145.01953,-44.17383 z`,style:{color:`#000000`,fill:`#ffffff`,"fill-opacity":`1`,"fill-rule":`nonzero`,stroke:`none`,"stroke-width":`5`,marker:`none`,visibility:`visible`,display:`inline`,overflow:`visible`,"enable-background":`accumulate`}})]),createBaseVNode(`clipPath`,{clipPathUnits:`userSpaceOnUse`,id:`clipPath4036`},[createBaseVNode(`path`,{style:{color:`#000000`,fill:`#ffffff`,"fill-opacity":`1`,"fill-rule":`nonzero`,stroke:`none`,"stroke-width":`5`,marker:`none`,visibility:`visible`,display:`inline`,overflow:`visible`,"enable-background":`accumulate`},d:`m 480,224 c -20.95323,0 -41.43416,2.01857 -61.26367,5.86328 l 12.08008,58.80274 C 446.74495,285.61583 463.18224,284 480,284 c 36.22419,0 70.7135,7.41519 102.04492,20.79883 l 24.1836,-54.92188 C 567.49749,233.23259 524.82925,224 480,224 z m -67.13867,7.07812 c -60.69914,12.96113 -115.01734,43.12659 -157.60938,85.15821 l 42.54297,42.3125 c 34.42536,-33.82645 78.22177,-58.13556 127.14258,-68.68555 l -12.07617,-58.78516 z m 198.86328,21.20508 -24.1875,54.9336 c 45.44422,20.67199 83.88358,54.04459 110.80078,95.58008 l 50.87305,-31.84376 C 715.93577,319.29347 668.20331,277.82636 611.72461,252.2832 z m -360.70117,68.21094 c -42.37565,43.40627 -72.5223,98.80082 -84.8418,160.63281 l 58.99024,11.05664 c 10.06229,-49.7524 34.33605,-94.34359 68.39257,-129.3789 l -42.54101,-42.31055 z m 501.3789,55.54102 -50.86132,31.83398 C 725.92383,447.46544 740,494.08649 740,544 l 60,0 C 800,482.39079 782.57195,424.85952 752.40234,376.03516 z M 165.06055,487.02148 C 161.7373,505.51211 160,524.55271 160,544 c 0,43.47625 8.68492,84.91949 24.39062,122.71094 l 55.21485,-23.5293 C 226.98058,612.61583 220,579.12541 220,544 c 0,-15.6701 1.38639,-31.01527 4.04297,-45.92188 l -58.98242,-11.05664 z m 76.90039,161.67774 -55.20899,23.52734 c 23.61428,53.92719 61.65397,100.09134 109.25586,133.60352 l 34.03516,-49.41406 C 291.73258,729.3212 261.08736,692.12046 241.96094,648.69922 z m 93.01953,111.12695 -34.04102,49.42188 C 352.04051,843.81227 413.66249,864 480,864 l 0,-60 c -53.69777,0 -103.59151,-16.28243 -145.01953,-44.17383 z`,id:`path4038`,"inkscape:connector-curvature":`0`})]),createBaseVNode(`linearGradient`,{"inkscape:collect":`always`,"xlink:href":`#linearGradient4545`,id:`linearGradient4551`,x1:`480`,y1:`214`,x2:`480`,y2:`474`,gradientUnits:`userSpaceOnUse`}),createBaseVNode(`linearGradient`,{"inkscape:collect":`always`,"xlink:href":`#linearGradient4545-2`,id:`linearGradient4551-8`,x1:`480`,y1:`214`,x2:`480`,y2:`474`,gradientUnits:`userSpaceOnUse`}),createBaseVNode(`linearGradient`,{id:`linearGradient4545-2`},[createBaseVNode(`stop`,{style:{"stop-color":`#e40000`,"stop-opacity":`1`},offset:`0`,id:`stop4547-4`}),createBaseVNode(`stop`,{id:`stop4553-5`,offset:`0.99000001`,style:{"stop-color":`#e40000`,"stop-opacity":`0`}}),createBaseVNode(`stop`,{style:{"stop-color":`#000000`,"stop-opacity":`0`},offset:`1`,id:`stop4555-5`}),createBaseVNode(`stop`,{style:{"stop-color":`#000000`,"stop-opacity":`0`},offset:`1`,id:`stop4549-1`})]),createBaseVNode(`linearGradient`,{y2:`282.59341`,x2:`474.60886`,y1:`211.1199`,x1:`480`,gradientUnits:`userSpaceOnUse`,id:`linearGradient4574`,"xlink:href":`#linearGradient4607`,"inkscape:collect":`always`,gradientTransform:`matrix(1,0,0,0.9882541,0,10.359887)`}),createBaseVNode(`clipPath`,{clipPathUnits:`userSpaceOnUse`,id:`clipPath4036-1`},[createBaseVNode(`path`,{style:{color:`#000000`,fill:`#ffffff`,"fill-opacity":`1`,"fill-rule":`nonzero`,stroke:`none`,"stroke-width":`5`,marker:`none`,visibility:`visible`,display:`inline`,overflow:`visible`,"enable-background":`accumulate`},d:`m 480,224 c -20.95323,0 -41.43416,2.01857 -61.26367,5.86328 l 12.08008,58.80274 C 446.74495,285.61583 463.18224,284 480,284 c 36.22419,0 70.7135,7.41519 102.04492,20.79883 l 24.1836,-54.92188 C 567.49749,233.23259 524.82925,224 480,224 z m -67.13867,7.07812 c -60.69914,12.96113 -115.01734,43.12659 -157.60938,85.15821 l 42.54297,42.3125 c 34.42536,-33.82645 78.22177,-58.13556 127.14258,-68.68555 l -12.07617,-58.78516 z m 198.86328,21.20508 -24.1875,54.9336 c 45.44422,20.67199 83.88358,54.04459 110.80078,95.58008 l 50.87305,-31.84376 C 715.93577,319.29347 668.20331,277.82636 611.72461,252.2832 z m -360.70117,68.21094 c -42.37565,43.40627 -72.5223,98.80082 -84.8418,160.63281 l 58.99024,11.05664 c 10.06229,-49.7524 34.33605,-94.34359 68.39257,-129.3789 l -42.54101,-42.31055 z m 501.3789,55.54102 -50.86132,31.83398 C 725.92383,447.46544 740,494.08649 740,544 l 60,0 C 800,482.39079 782.57195,424.85952 752.40234,376.03516 z M 165.06055,487.02148 C 161.7373,505.51211 160,524.55271 160,544 c 0,43.47625 8.68492,84.91949 24.39062,122.71094 l 55.21485,-23.5293 C 226.98058,612.61583 220,579.12541 220,544 c 0,-15.6701 1.38639,-31.01527 4.04297,-45.92188 l -58.98242,-11.05664 z m 76.90039,161.67774 -55.20899,23.52734 c 23.61428,53.92719 61.65397,100.09134 109.25586,133.60352 l 34.03516,-49.41406 C 291.73258,729.3212 261.08736,692.12046 241.96094,648.69922 z m 93.01953,111.12695 -34.04102,49.42188 C 352.04051,843.81227 413.66249,864 480,864 l 0,-60 c -53.69777,0 -103.59151,-16.28243 -145.01953,-44.17383 z`,id:`path4038-7`,"inkscape:connector-curvature":`0`})]),createBaseVNode(`radialGradient`,{"inkscape:collect":`always`,"xlink:href":`#linearGradient4357-0`,id:`radialGradient4363-4`,cx:`480`,cy:`544`,fx:`480`,fy:`544`,r:`320`,gradientUnits:`userSpaceOnUse`,gradientTransform:`matrix(1.03125,0,0,1.03125,-15,-17)`}),createBaseVNode(`linearGradient`,{id:`linearGradient4357-0`},[createBaseVNode(`stop`,{style:{"stop-color":`#000000`,"stop-opacity":`0.65178573`},offset:`0`,id:`stop4359-9`}),createBaseVNode(`stop`,{style:{"stop-color":`#000000`,"stop-opacity":`0.24107143`},offset:`1`,id:`stop4361-4`})]),createBaseVNode(`radialGradient`,{"inkscape:collect":`always`,"xlink:href":`#linearGradient4365-4`,id:`radialGradient4371-2`,cx:`480`,cy:`544`,fx:`480`,fy:`544`,r:`320`,gradientUnits:`userSpaceOnUse`}),createBaseVNode(`linearGradient`,{id:`linearGradient4365-4`},[createBaseVNode(`stop`,{style:{"stop-color":`#000000`,"stop-opacity":`0.42857143`},offset:`0`,id:`stop4367-5`}),createBaseVNode(`stop`,{id:`stop4373-5`,offset:`0.5`,style:{"stop-color":`#000000`,"stop-opacity":`0.33035713`}}),createBaseVNode(`stop`,{style:{"stop-color":`#000000`,"stop-opacity":`0`},offset:`1`,id:`stop4369-1`})]),createBaseVNode(`radialGradient`,{r:`320`,fy:`544`,fx:`480`,cy:`544`,cx:`480`,gradientUnits:`userSpaceOnUse`,id:`radialGradient3997`,"xlink:href":`#linearGradient4365-4`,"inkscape:collect":`always`}),createBaseVNode(`radialGradient`,{"inkscape:collect":`always`,"xlink:href":`#linearGradient4357-0-7`,id:`radialGradient4363-4-1`,cx:`480`,cy:`544`,fx:`480`,fy:`544`,r:`320`,gradientUnits:`userSpaceOnUse`,gradientTransform:`matrix(1.03125,0,0,1.03125,-15,-17)`}),createBaseVNode(`linearGradient`,{id:`linearGradient4357-0-7`},[createBaseVNode(`stop`,{style:{"stop-color":`#000000`,"stop-opacity":`0.51785713`},offset:`0`,id:`stop4359-9-4`}),createBaseVNode(`stop`,{style:{"stop-color":`#000000`,"stop-opacity":`0.11607143`},offset:`1`,id:`stop4361-4-0`})]),createBaseVNode(`radialGradient`,{r:`320`,fy:`544`,fx:`480`,cy:`544`,cx:`480`,gradientTransform:`matrix(1.03125,0,0,1.03125,-15,-17)`,gradientUnits:`userSpaceOnUse`,id:`radialGradient4001`,"xlink:href":`#linearGradient4357-0-7`,"inkscape:collect":`always`}),createBaseVNode(`radialGradient`,{"inkscape:collect":`always`,"xlink:href":`#linearGradient4357-0-7`,id:`radialGradient4040`,gradientUnits:`userSpaceOnUse`,gradientTransform:`matrix(1.03125,0,0,1.03125,-885,-231)`,cx:`480`,cy:`544`,fx:`480`,fy:`544`,r:`320`}),createBaseVNode(`radialGradient`,{"inkscape:collect":`always`,"xlink:href":`#linearGradient4357-0-7`,id:`radialGradient4045`,gradientUnits:`userSpaceOnUse`,gradientTransform:`matrix(1.03125,0,0,1.03125,-885,-231)`,cx:`480`,cy:`544`,fx:`480`,fy:`544`,r:`320`}),createBaseVNode(`radialGradient`,{"inkscape:collect":`always`,"xlink:href":`#linearGradient4357-0-7-2`,id:`radialGradient4045-8`,gradientUnits:`userSpaceOnUse`,gradientTransform:`matrix(1.03125,0,0,1.03125,-885,-231)`,cx:`480`,cy:`544`,fx:`480`,fy:`544`,r:`320`}),createBaseVNode(`linearGradient`,{id:`linearGradient4357-0-7-2`},[createBaseVNode(`stop`,{style:{"stop-color":`#000000`,"stop-opacity":`0.51785713`},offset:`0`,id:`stop4359-9-4-4`}),createBaseVNode(`stop`,{style:{"stop-color":`#000000`,"stop-opacity":`0.11607143`},offset:`1`,id:`stop4361-4-0-5`})]),createBaseVNode(`radialGradient`,{r:`320`,fy:`544`,fx:`480`,cy:`544`,cx:`480`,gradientTransform:`matrix(1.03125,0,0,1.03125,-758.53125,-231)`,gradientUnits:`userSpaceOnUse`,id:`radialGradient4063`,"xlink:href":`#linearGradient4357-0-7-2`,"inkscape:collect":`always`}),createBaseVNode(`radialGradient`,{"inkscape:collect":`always`,"xlink:href":`#linearGradient4357-0-7`,id:`radialGradient4082`,gradientUnits:`userSpaceOnUse`,gradientTransform:`matrix(1.03125,0,0,1.03125,-885,-231)`,cx:`480`,cy:`544`,fx:`480`,fy:`544`,r:`320`}),createBaseVNode(`radialGradient`,{"inkscape:collect":`always`,"xlink:href":`#linearGradient4357-0-8`,id:`radialGradient4363-4-9`,cx:`480`,cy:`544`,fx:`480`,fy:`544`,r:`320`,gradientUnits:`userSpaceOnUse`,gradientTransform:`matrix(1.03125,0,0,1.03125,-15,-17)`}),createBaseVNode(`linearGradient`,{id:`linearGradient4357-0-8`},[createBaseVNode(`stop`,{style:{"stop-color":`#000000`,"stop-opacity":`0.51785713`},offset:`0`,id:`stop4359-9-40`}),createBaseVNode(`stop`,{style:{"stop-color":`#000000`,"stop-opacity":`0.11607143`},offset:`1`,id:`stop4361-4-7`})]),createBaseVNode(`radialGradient`,{r:`320`,fy:`544`,fx:`480`,cy:`544`,cx:`480`,gradientTransform:`matrix(1.03125,0,0,1.03125,-15,-17)`,gradientUnits:`userSpaceOnUse`,id:`radialGradient4031-1`,"xlink:href":`#linearGradient4357-0-8-5`,"inkscape:collect":`always`}),createBaseVNode(`linearGradient`,{id:`linearGradient4357-0-8-5`},[createBaseVNode(`stop`,{style:{"stop-color":`#000000`,"stop-opacity":`0.51785713`},offset:`0`,id:`stop4359-9-40-4`}),createBaseVNode(`stop`,{style:{"stop-color":`#000000`,"stop-opacity":`0.11607143`},offset:`1`,id:`stop4361-4-7-2`})]),createBaseVNode(`radialGradient`,{"inkscape:collect":`always`,"xlink:href":`#linearGradient4357-0-3`,id:`radialGradient4363-4-0`,cx:`480`,cy:`544`,fx:`480`,fy:`544`,r:`320`,gradientUnits:`userSpaceOnUse`,gradientTransform:`matrix(1.03125,0,0,1.03125,-15,-17)`}),createBaseVNode(`linearGradient`,{id:`linearGradient4357-0-3`},[createBaseVNode(`stop`,{style:{"stop-color":`#000000`,"stop-opacity":`0.65178573`},offset:`0`,id:`stop4359-9-8`}),createBaseVNode(`stop`,{style:{"stop-color":`#000000`,"stop-opacity":`0.24107143`},offset:`1`,id:`stop4361-4-01`})]),createBaseVNode(`clipPath`,{clipPathUnits:`userSpaceOnUse`,id:`clipPath4407-8-2`},[createBaseVNode(`path`,{"inkscape:connector-curvature":`0`,id:`path4409-8-5`,d:`m 480,-103.33 c -357.5105,0 -647.33,289.8195 -647.33,647.33 0,357.5105 289.8195,647.33 647.33,647.33 357.5105,0 647.33,-289.8195 647.33,-647.33 0,-357.5105 -289.8195,-647.33 -647.33,-647.33 z m 0,453.131 c 107.25316,0 194.199,86.94584 194.199,194.199 0,107.25316 -86.94584,194.199 -194.199,194.199 -107.25316,0 -194.199,-86.94584 -194.199,-194.199 0,-107.25316 86.94584,-194.199 194.199,-194.199 z`,style:{color:`#000000`,fill:`#ffffff`,"fill-opacity":`0.61375661`,"fill-rule":`nonzero`,stroke:`none`,"stroke-width":`16`,marker:`none`,visibility:`visible`,display:`inline`,overflow:`visible`,"enable-background":`accumulate`}})]),createBaseVNode(`radialGradient`,{r:`320`,fy:`544`,fx:`480`,cy:`544`,cx:`480`,gradientTransform:`matrix(1.03125,0,0,1.03125,-15,-17)`,gradientUnits:`userSpaceOnUse`,id:`radialGradient4401`,"xlink:href":`#linearGradient4357-0-3`,"inkscape:collect":`always`}),createBaseVNode(`radialGradient`,{r:`320`,fy:`544`,fx:`480`,cy:`544`,cx:`480`,gradientUnits:`userSpaceOnUse`,id:`radialGradient3997-4`,"xlink:href":`#linearGradient4365-4-7`,"inkscape:collect":`always`}),createBaseVNode(`linearGradient`,{id:`linearGradient4365-4-7`},[createBaseVNode(`stop`,{style:{"stop-color":`#000000`,"stop-opacity":`0.42857143`},offset:`0`,id:`stop4367-5-8`}),createBaseVNode(`stop`,{id:`stop4373-5-3`,offset:`0.5`,style:{"stop-color":`#000000`,"stop-opacity":`0.33035713`}}),createBaseVNode(`stop`,{style:{"stop-color":`#000000`,"stop-opacity":`0`},offset:`1`,id:`stop4369-1-5`})]),createBaseVNode(`radialGradient`,{r:`320`,fy:`544`,fx:`480`,cy:`544`,cx:`480`,gradientUnits:`userSpaceOnUse`,id:`radialGradient4458`,"xlink:href":`#linearGradient4365-4-7`,"inkscape:collect":`always`}),createBaseVNode(`clipPath`,{clipPathUnits:`userSpaceOnUse`,id:`clipPath3653`},[createBaseVNode(`path`,{style:{color:`#000000`,display:`inline`,overflow:`visible`,visibility:`visible`,fill:`#ffffff`,"fill-opacity":`0.61375661`,"fill-rule":`nonzero`,stroke:`none`,"stroke-width":`16`,marker:`none`,"enable-background":`accumulate`},d:`M 480,84 C 225.94901,84 20,289.94901 20,544 20,798.05099 225.94901,1004 480,1004 734.05099,1004 940,798.05099 940,544 940,289.94901 734.05099,84 480,84 Z m 0,322 c 76.21531,0 138,61.78469 138,138 0,76.21531 -61.78469,138 -138,138 -76.21531,0 -138,-61.78469 -138,-138 0,-76.21531 61.78469,-138 138,-138 z`,id:`path3655`,"inkscape:connector-curvature":`0`})]),createBaseVNode(`clipPath`,{clipPathUnits:`userSpaceOnUse`,id:`clipPath4490`},[createBaseVNode(`path`,{style:{color:`#000000`,"font-style":`normal`,"font-variant":`normal`,"font-weight":`normal`,"font-stretch":`normal`,"font-size":`medium`,"line-height":`normal`,"font-family":`sans-serif`,"text-indent":`0`,"text-align":`start`,"text-decoration":`none`,"text-decoration-line":`none`,"text-decoration-style":`solid`,"text-decoration-color":`#000000`,"letter-spacing":`normal`,"word-spacing":`normal`,"text-transform":`none`,direction:`ltr`,"block-progression":`tb`,"writing-mode":`lr-tb`,"baseline-shift":`baseline`,"text-anchor":`start`,"white-space":`normal`,"clip-rule":`nonzero`,display:`inline`,overflow:`visible`,visibility:`visible`,opacity:`1`,isolation:`auto`,"mix-blend-mode":`normal`,"color-interpolation":`sRGB`,"color-interpolation-filters":`linearRGB`,"solid-color":`#000000`,"solid-opacity":`1`,fill:`#000000`,"fill-opacity":`1`,"fill-rule":`evenodd`,stroke:`none`,"stroke-width":`96.91093445`,"stroke-linecap":`butt`,"stroke-linejoin":`miter`,"stroke-miterlimit":`4`,"stroke-dasharray":`none`,"stroke-dashoffset":`0`,"stroke-opacity":`1`,"color-rendering":`auto`,"image-rendering":`auto`,"shape-rendering":`auto`,"text-rendering":`auto`,"enable-background":`accumulate`},d:`m 330,10 c -176.15718,3e-6 -319.999997,143.84282 -320,320 0,88.07859 35.961054,168.07824 93.94141,226.05859 l 68.0957,-68.0957 C 131.73748,447.66326 106.91016,391.89131 106.91016,330 c 0,-123.78262 99.30722,-223.08984 223.08984,-223.08984 123.78262,0 223.08984,99.30722 223.08984,223.08984 0,61.89131 -24.82732,117.66326 -65.12695,157.96289 l 68.0957,68.0957 C 614.03895,498.07824 650,418.07859 650,330 650,153.84282 506.15718,10 330,10 Z`,id:`path4492`,"inkscape:connector-curvature":`0`})]),createBaseVNode(`clipPath`,{clipPathUnits:`userSpaceOnUse`,id:`clipPath4494`},[createBaseVNode(`path`,{style:{color:`#000000`,"font-style":`normal`,"font-variant":`normal`,"font-weight":`normal`,"font-stretch":`normal`,"font-size":`medium`,"line-height":`normal`,"font-family":`sans-serif`,"text-indent":`0`,"text-align":`start`,"text-decoration":`none`,"text-decoration-line":`none`,"text-decoration-style":`solid`,"text-decoration-color":`#000000`,"letter-spacing":`normal`,"word-spacing":`normal`,"text-transform":`none`,direction:`ltr`,"block-progression":`tb`,"writing-mode":`lr-tb`,"baseline-shift":`baseline`,"text-anchor":`start`,"white-space":`normal`,"clip-rule":`nonzero`,display:`inline`,overflow:`visible`,visibility:`visible`,opacity:`1`,isolation:`auto`,"mix-blend-mode":`normal`,"color-interpolation":`sRGB`,"color-interpolation-filters":`linearRGB`,"solid-color":`#000000`,"solid-opacity":`1`,fill:`#000000`,"fill-opacity":`1`,"fill-rule":`evenodd`,stroke:`none`,"stroke-width":`96.91093445`,"stroke-linecap":`butt`,"stroke-linejoin":`miter`,"stroke-miterlimit":`4`,"stroke-dasharray":`none`,"stroke-dashoffset":`0`,"stroke-opacity":`1`,"color-rendering":`auto`,"image-rendering":`auto`,"shape-rendering":`auto`,"text-rendering":`auto`,"enable-background":`accumulate`},d:`m 330,10 c -176.15718,3e-6 -319.999997,143.84282 -320,320 0,88.07859 35.961054,168.07824 93.94141,226.05859 l 68.0957,-68.0957 C 131.73748,447.66326 106.91016,391.89131 106.91016,330 c 0,-123.78262 99.30722,-223.08984 223.08984,-223.08984 123.78262,0 223.08984,99.30722 223.08984,223.08984 0,61.89131 -24.82732,117.66326 -65.12695,157.96289 l 68.0957,68.0957 C 614.03895,498.07824 650,418.07859 650,330 650,153.84282 506.15718,10 330,10 Z`,id:`path4496`,"inkscape:connector-curvature":`0`})]),createBaseVNode(`clipPath`,{clipPathUnits:`userSpaceOnUse`,id:`clipPath4498`},[createBaseVNode(`path`,{style:{color:`#000000`,"font-style":`normal`,"font-variant":`normal`,"font-weight":`normal`,"font-stretch":`normal`,"font-size":`medium`,"line-height":`normal`,"font-family":`sans-serif`,"text-indent":`0`,"text-align":`start`,"text-decoration":`none`,"text-decoration-line":`none`,"text-decoration-style":`solid`,"text-decoration-color":`#000000`,"letter-spacing":`normal`,"word-spacing":`normal`,"text-transform":`none`,direction:`ltr`,"block-progression":`tb`,"writing-mode":`lr-tb`,"baseline-shift":`baseline`,"text-anchor":`start`,"white-space":`normal`,"clip-rule":`nonzero`,display:`inline`,overflow:`visible`,visibility:`visible`,opacity:`1`,isolation:`auto`,"mix-blend-mode":`normal`,"color-interpolation":`sRGB`,"color-interpolation-filters":`linearRGB`,"solid-color":`#000000`,"solid-opacity":`1`,fill:`#000000`,"fill-opacity":`1`,"fill-rule":`evenodd`,stroke:`none`,"stroke-width":`96.91093445`,"stroke-linecap":`butt`,"stroke-linejoin":`miter`,"stroke-miterlimit":`4`,"stroke-dasharray":`none`,"stroke-dashoffset":`0`,"stroke-opacity":`1`,"color-rendering":`auto`,"image-rendering":`auto`,"shape-rendering":`auto`,"text-rendering":`auto`,"enable-background":`accumulate`},d:`m 240.41631,-226.27417 c -124.56194,124.56194 -124.56194,327.9864 0,452.54834 62.28096,62.28097 144.27756,93.42096 226.27417,93.42095 l 0,-96.30186 c -56.99229,0 -113.98458,-21.88116 -157.74834,-65.64492 -87.52753,-87.527531 -87.52753,-227.969149 0,-315.49668 87.52753,-87.52753 227.96915,-87.52753 315.49668,0 C 668.20258,-113.98457 690.08374,-56.992283 690.08374,0 l 96.30186,0 c 1e-5,-81.996605 -31.13998,-163.9932 -93.42095,-226.27417 -124.56194,-124.56194 -327.98641,-124.56194 -452.54834,0 z`,id:`path4500`,"inkscape:connector-curvature":`0`})])],-1),_cache[5]||=createBaseVNode(`g`,{"inkscape:label":`background`,"inkscape:groupmode":`layer`,id:`layer1`,transform:`translate(-150,-242.36218)`,style:{display:`none`,opacity:`1`}},[createBaseVNode(`rect`,{style:{fill:`#505050`,"fill-opacity":`1`,stroke:`none`},id:`rect4616`,width:`2175.3789`,height:`1458.4727`,x:`-727.47485`,y:`-115.47279`})],-1),createBaseVNode(`g`,_hoisted_2$140,[_cache[0]||=createBaseVNode(`circle`,{style:{color:`#000000`,display:`inline`,overflow:`visible`,visibility:`visible`,fill:`url(#radialGradient3997)`,"fill-opacity":`1`,"fill-rule":`nonzero`,stroke:`none`,"stroke-width":`16`,marker:`none`,"enable-background":`accumulate`},id:`path4281-5`,cx:`480`,cy:`544`,r:`320`,transform:`translate(-150,-214)`},null,-1),_cache[1]||=createBaseVNode(`path`,{style:{color:`#000000`,display:`inline`,overflow:`visible`,visibility:`visible`,fill:`url(#radialGradient4363-4)`,"fill-opacity":`1`,"fill-rule":`nonzero`,stroke:`none`,"stroke-width":`6`,marker:`none`,"enable-background":`accumulate`},d:`M 480,214 C 297.74603,214 150,361.74603 150,544 150,726.25397 297.74603,874 480,874 662.25397,874 810,726.25397 810,544 810,361.74603 662.25397,214 480,214 Z`,id:`path4281`,"inkscape:connector-curvature":`0`,"sodipodi:nodetypes":`sssss`,"clip-path":`url(#clipPath3653)`,transform:`translate(-150,-214)`},null,-1),createBaseVNode(`text`,_hoisted_3$126,[createBaseVNode(`tspan`,{ref_key:`pressureTextRef`,ref:pressureTextRef,"sodipodi:role":`line`,id:`pressureText`,x:`329.85437`,y:`328.48807`,style:{"font-style":`normal`,"font-variant":`normal`,"font-weight":`normal`,"font-stretch":`normal`,"font-size":`159.64709473px`,"line-height":`125%`,"font-family":`'Squada One'`,"-inkscape-font-specification":`'Squada One'`,"text-align":`center`,"writing-mode":`lr-tb`,"text-anchor":`middle`,fill:`#ffffff`,"fill-opacity":`1`}},` 0`,512)]),createBaseVNode(`text`,_hoisted_4$103,[createBaseVNode(`tspan`,{ref_key:`pressureUnitRef`,ref:pressureUnitRef,"sodipodi:role":`line`,id:`pressureunit`,x:`329.03198`,y:`413.62915`},`PSI`,512)]),(openBlock(!0),createElementBlock(Fragment,null,renderList(pressureTextAttrs.value,attrs=>(openBlock(),createElementBlock(`text`,{ref_for:!0,ref:el=>pressureTextRefs.value.push(el),"xml:space":`preserve`,class:`pressure-text`,id:attrs.id+`p`,x:attrs.x,y:attrs.y},[createBaseVNode(`tspan`,{ref_for:!0,ref:el2=>pressureTSpanRefs.value.push(el2),id:attrs.id,x:attrs.x,y:attrs.y},toDisplayString(attrs.text),9,_hoisted_6$74)],8,_hoisted_5$89))),256))]),createBaseVNode(`g`,_hoisted_7$64,[createBaseVNode(`g`,_hoisted_8$51,[_cache[2]||=createBaseVNode(`rect`,{style:{color:`#000000`,display:`inline`,overflow:`visible`,visibility:`visible`,fill:`#000000`,"fill-opacity":`0.37037036`,"fill-rule":`nonzero`,stroke:`none`,"stroke-width":`16`,marker:`none`,"enable-background":`accumulate`},id:`rect4001`,width:`683.79401`,height:`683.79401`,x:`127.97179`,y:`-340.09323`,transform:`matrix(0.70710678,0.70710678,-0.70710678,0.70710678,0,0)`,"clip-path":`url(#clipPath4498)`},null,-1),createBaseVNode(`path`,{ref_key:`pressureCurveRef`,ref:pressureCurveRef,style:{color:`#000000`,display:`inline`,overflow:`visible`,visibility:`visible`,fill:`none`,stroke:`#ffffff`,"stroke-width":`99.31034088`,"stroke-miterlimit":`4`,"stroke-dasharray":`2374.27468498, 2374.27468498`,"stroke-dashoffset":`0`,"stroke-opacity":`1`,marker:`none`,"enable-background":`accumulate`},d:`M 147.9957,528.59996 C 50,420 27.118653,298.1594 119.95323,156.00847 150,110 350,-30 532.60856,149.71493 c 74.5117,73.33098 97.08931,264.86379 -10.87668,369.15745`,id:`pressureCurve`,"clip-path":`url(#clipPath4494)`},null,512),createBaseVNode(`path`,{ref_key:`redLineRef`,ref:redLineRef,style:{color:`#000000`,overflow:`visible`,visibility:`visible`,fill:`none`,stroke:`#9c0000`,"stroke-width":`117.91827393`,"stroke-linecap":`butt`,"stroke-linejoin":`bevel`,"stroke-miterlimit":`4`,"stroke-dasharray":`none`,"stroke-dashoffset":`604.6484375`,"stroke-opacity":`0.66137564`,marker:`none`,"enable-background":`accumulate`},d:`M 147.99571,510.41274 C 33.434043,395.42128 59.279735,242.76116 138.14044,153.71911 230,50 387.77546,50.913502 485.67663,112.95746 c 165.77018,105.05531 132.03401,312.46382 37.32761,407.0596`,id:`pressure_redline`,"clip-path":`url(#clipPath4490)`},null,512)])]),createBaseVNode(`g`,_hoisted_9$45,[createBaseVNode(`path`,{ref_key:`pressureCurveDashesRef`,ref:pressureCurveDashesRef,style:{display:`inline`,fill:`none`,stroke:`#000000`,"stroke-width":`96.91100311`,"stroke-miterlimit":`0.40000001`,"stroke-dasharray":`48.4555, 48.4555`,"stroke-dashoffset":`0`,"stroke-opacity":`0.37566139`},d:`m 137.9887,522.0113 c -106.044908,-106.04491 -106.044903,-277.97769 1e-5,-384.0226 106.04491,-106.044917 277.97767,-106.044914 384.02259,0 106.04491,106.04491 106.04492,277.97769 10e-6,384.0226`,id:`pressureCurve_dashes`,"inkscape:connector-curvature":`0`,"sodipodi:nodetypes":`cssc`,"inkscape:label":`#path4531-4`},null,512),createBaseVNode(`path`,{ref_key:`pressureTextGuideLineRef`,ref:pressureTextGuideLineRef,style:{display:`inline`,fill:`none`,stroke:`#e90000`,"stroke-width":`2.86352348`,"stroke-miterlimit":`0.40000001`,"stroke-dasharray":`none`,"stroke-dashoffset":`0`,"stroke-opacity":`0.24404764`},d:`m 202.03513,457.96488 c -70.12576,-70.12575 -70.12576,-183.82209 0,-253.94784 70.12575,-70.12576 183.82208,-70.12576 253.94784,0 70.12575,70.12575 70.12575,183.82209 0,253.94784`,id:`pressuretextline`,"inkscape:connector-curvature":`0`,"sodipodi:nodetypes":`cssc`,"inkscape:label":`#path4531-4`},null,512)]),createBaseVNode(`g`,_hoisted_10$38,[createBaseVNode(`g`,{ref_key:`pressureNeedleRef`,ref:pressureNeedleRef,id:`pressure_needle_d`,"inkscape:label":`#g4147`,transform:`translate(-1.2852971e-6,1.993565e-6)`},[..._cache[3]||=[createBaseVNode(`rect`,{y:`7.0002151`,x:`322.0993`,height:`103.00317`,width:`12.038266`,id:`rect4625`,style:{color:`#000000`,display:`inline`,overflow:`visible`,visibility:`visible`,fill:`#d70000`,"fill-opacity":`1`,"fill-rule":`nonzero`,stroke:`none`,"stroke-width":`67.38899994`,marker:`none`,"enable-background":`accumulate`},transform:`matrix(1,0,0.00784004,0.99996927,0,0)`},null,-1),createBaseVNode(`rect`,{transform:`scale(1,-1)`,y:`-660`,x:`322.44037`,height:`660`,width:`15.11928`,id:`rect4625-1`,style:{color:`#000000`,display:`inline`,overflow:`visible`,visibility:`visible`,fill:`#008000`,"fill-opacity":`0`,"fill-rule":`nonzero`,stroke:`none`,"stroke-width":`67.38899994`,marker:`none`,"enable-background":`accumulate`}},null,-1)]],512)])]))}},forcedInduction_default=__plugin_vue_export_helper_default(_sfc_main$191,[[`__scopeId`,`data-v-a0f39cc4`]]),_sfc_main$190={__name:`app`,setup(__props){let{$game}=useLibStore(),forcedInductionRef=ref(null),fiContainerRef=ref(null),enabled=ref(!1);return onMounted(()=>{forcedInductionRef.value.wireThroughRoundDec(roundDec),forcedInductionRef.value.wireThroughUnitSystem((val,func)=>UiUnits[func](val)),$game.streams.add([`forcedInductionInfo`])}),onUnmounted(()=>{$game.streams.remove([`forcedInductionInfo`])}),$game.events.on(`VechicleChange`,()=>forcedInductionRef.value.reset()),$game.events.on(`VehicleFocusChanged`,data=>{data.mode==1&&forcedInductionRef.value!==null&&forcedInductionRef.value.reset()}),$game.events.on(`onStreamsUpdate`,streams=>{if(forcedInductionRef.value===null)return;let newEnabled=forcedInductionRef.value.isStreamValid(streams);newEnabled?(newEnabled&&!enabled.value&&(fiContainerRef.value.style.opacity=1),forcedInductionRef.value.update(streams)):!newEnabled&&enabled&&(fiContainerRef.value.style.opacity=0),enabled.value=newEnabled}),(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,{ref_key:`fiContainerRef`,ref:fiContainerRef,class:`fi-container`},[createVNode(forcedInduction_default,{ref_key:`forcedInductionRef`,ref:forcedInductionRef},null,512)],512))}},app_default$20=__plugin_vue_export_helper_default(_sfc_main$190,[[`__scopeId`,`data-v-3ea976f6`]]),_hoisted_1$170={class:`fi-debug`},_hoisted_2$139={class:`name`},_hoisted_3$125={class:`value`},_sfc_main$189={__name:`app`,setup(__props){let{$game}=useLibStore(),streamsList$1=[`forcedInductionInfo`],defaultMeasures=[{name:`RPM`,key:`rpm`},{name:`Boost`,key:`boost`,type:`pressure`},{name:`Power Coef`,key:`coef`},{name:`Pressure Pulses`,key:`pulses`},{name:`SC Loss`,key:`loss`},{name:`Exhaust Power`,key:`exhaustPower`},{name:`Friction`,key:`friction`},{name:`Backpressure`,key:`backpressure`},{name:`Wastegate Factor`,key:`wastegateFactor`},{name:`Turbo Temp`,key:`turboTemp`,type:`temperature`}],measures=ref([]),filteredMeasures=computed(()=>measures.value.filter(m=>m.val!==void 0));onMounted(()=>{$game.streams.add(streamsList$1),$game.events.on(`onStreamsUpdate`,onStreamsUpdate),$game.events.on(`VehicleReset`,init$3),$game.events.on(`VehicleFocusChanged`,init$3),init$3()}),onUnmounted(()=>{$game.streams.remove(streamsList$1),$game.events.off(`onStreamsUpdate`,onStreamsUpdate),$game.events.off(`VehicleReset`,init$3),$game.events.off(`VehicleFocusChanged`,init$3)});function onStreamsUpdate(streams){for(let stream of streamsList$1)if(!streams[stream])return;measures.value.forEach(x=>{let val=streams.forcedInductionInfo[x.key];val!==void 0&&(x.val=x.type===void 0?val.toFixed(2):$game.units.buildString(x.type,val,2))})}function init$3(){measures.value=defaultMeasures}return(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$170,[(openBlock(!0),createElementBlock(Fragment,null,renderList(filteredMeasures.value,m=>(openBlock(),createElementBlock(`div`,{class:`measure`,key:m.key},[createBaseVNode(`div`,_hoisted_2$139,toDisplayString(m.name),1),createBaseVNode(`div`,_hoisted_3$125,toDisplayString(m.val),1)]))),128))]))}},app_default$21=__plugin_vue_export_helper_default(_sfc_main$189,[[`__scopeId`,`data-v-8094d28b`]]),_sfc_main$188={},_hoisted_1$169={xmlns:`http://www.w3.org/2000/svg`,width:`60`,height:`100`,viewBox:`0 0 60 100`};function _sfc_render$2(_ctx,_cache){return openBlock(),createElementBlock(`svg`,_hoisted_1$169,[..._cache[0]||=[createBaseVNode(`rect`,{x:`4`,y:`4`,width:`52`,height:`92`,rx:`25`,ry:`25`,stroke:`black`,"stroke-width":`4`,fill:`none`},null,-1)]])}var accumulator_default=__plugin_vue_export_helper_default(_sfc_main$188,[[`render`,_sfc_render$2]]),_sfc_main$187={},_hoisted_1$168={xmlns:`http://www.w3.org/2000/svg`,width:`100`,height:`125`,viewBox:`0 0 100 125`,"stroke-width":`4`,stroke:`black`};function _sfc_render$1(_ctx,_cache){return openBlock(),createElementBlock(`svg`,_hoisted_1$168,[..._cache[0]||=[createBaseVNode(`circle`,{cx:`50`,cy:`32`,r:`30`,fill:`none`},null,-1),createBaseVNode(`path`,{d:`M50 6 L57 15 L43 15 Z`,fill:`black`},null,-1),createBaseVNode(`line`,{x1:`50`,y1:`61`,x2:`50`,y2:`90`,stroke:`black`},null,-1),createBaseVNode(`path`,{d:`M15 59 L15 115 L85 115 L85 59`,fill:`none`},null,-1)]])}var pump_default=__plugin_vue_export_helper_default(_sfc_main$187,[[`render`,_sfc_render$1]]),_sfc_main$186={},_hoisted_1$167={xmlns:`http://www.w3.org/2000/svg`,width:`100`,height:`130`,viewBox:`0 0 100 130`,"stroke-width":`4`,stroke:`black`};function _sfc_render(_ctx,_cache){return openBlock(),createElementBlock(`svg`,_hoisted_1$167,[..._cache[0]||=[createStaticVNode(``,6)]])}var reliefValve_default=__plugin_vue_export_helper_default(_sfc_main$186,[[`render`,_sfc_render]]),_hoisted_1$166={xmlns:`http://www.w3.org/2000/svg`,width:`100`,height:`210`,viewBox:`0 0 200 310`},_hoisted_2$138={transform:`translate(100, 0)`},_hoisted_3$124={transform:`translate(0, 110)`},_hoisted_4$102={transform:`translate(110, 190)`},_sfc_main$185={__name:`pumpAssembly`,setup(__props){return(_ctx,_cache)=>(openBlock(),createElementBlock(`svg`,_hoisted_1$166,[createBaseVNode(`g`,_hoisted_2$138,[createVNode(accumulator_default)]),createBaseVNode(`g`,_hoisted_3$124,[createVNode(reliefValve_default)]),createBaseVNode(`g`,_hoisted_4$102,[createVNode(pump_default)]),_cache[0]||=createBaseVNode(`path`,{d:`M56 122 L56 138 M54 120 L128 120 M130 122 L130 98 M130 120 L158 120 M160 118 L160 190`,stroke:`black`,"stroke-width":`4`},null,-1)]))}},pumpAssembly_default=_sfc_main$185,_hoisted_1$165={class:`hydraulics-debug`},_hoisted_2$137={width:`100%`,height:`100%`},_hoisted_3$123={id:`myGradient`,x1:`0%`,y1:`0%`,x2:`100%`,y2:`0%`},_hoisted_4$101=[`offset`],_hoisted_5$88={transform:`translate(0, 150)`,id:`pumpAssembly`},_hoisted_6$73=[`transform`],_hoisted_7$63=[`width`],_sfc_main$184={__name:`app`,setup(__props){let streamsList$1=[],{$game}=useLibStore(),offset$2=ref(0),offsetLeft=computed(()=>`${offset$2.value}%`),increase=()=>{offset$2.value<=100&&(offset$2.value+=10)},decrease=()=>{offset$2.value>0&&(offset$2.value-=10)},consumers=ref([{type:`hydraulicMotor`},{type:`cylinder`}]),addCylinder=function(){consumers.value.push({type:`cylinder`})},addhydraulicMotor=function(){consumers.value.push({type:`hydraulicMotor`})},removeConsumer=function(index=null){index===null?consumers.value.pop():consumers.value.splice(index,1)};onMounted(()=>{$game.events.on(`onStreamsUpdate`,onStreamsUpdate),$game.streams.add(streamsList$1)}),onUnmounted(()=>{$game.events.off(`onStreamsUpdate`,onStreamsUpdate),$game.streams.remove(streamsList$1)});function onStreamsUpdate(streams){for(let stream of streamsList$1)if(!streams[stream])return}return(_ctx,_cache)=>(openBlock(),createElementBlock(Fragment,null,[_cache[1]||=createBaseVNode(`h1`,null,`Hydraulics Debug`,-1),createBaseVNode(`button`,{onClick:decrease},`dec`),createBaseVNode(`button`,{onClick:increase},`inc`),createBaseVNode(`button`,{onClick:addhydraulicMotor},`motor`),createBaseVNode(`button`,{onClick:addCylinder},`cylinder`),createBaseVNode(`button`,{onClick:removeConsumer},`Remove Consumer`),createBaseVNode(`div`,null,` offset: `+toDisplayString(offset$2.value)+` left: `+toDisplayString(offsetLeft.value),1),createBaseVNode(`div`,_hoisted_1$165,[(openBlock(),createElementBlock(`svg`,_hoisted_2$137,[createBaseVNode(`defs`,null,[createBaseVNode(`linearGradient`,_hoisted_3$123,[createBaseVNode(`stop`,{offset:offsetLeft.value,"stop-color":`green`},null,8,_hoisted_4$101),_cache[0]||=createBaseVNode(`stop`,{offset:`0`,"stop-color":`black`},null,-1)])]),createBaseVNode(`g`,_hoisted_5$88,[createVNode(pumpAssembly_default)]),(openBlock(!0),createElementBlock(Fragment,null,renderList(consumers.value,(consumer,index)=>(openBlock(),createElementBlock(`g`,{transform:`translate(${(index+1)*100}, 95)`},[createVNode(consumer,{consumerType:consumer.type},null,8,[`consumerType`])],8,_hoisted_6$73))),256)),createBaseVNode(`rect`,{x:`80`,y:`236.5`,width:100*(consumers.value.length-1)+66,height:`2`,fill:`url(#myGradient)`},null,8,_hoisted_7$63)]))])],64))}},app_default$22=__plugin_vue_export_helper_default(_sfc_main$184,[[`__scopeId`,`data-v-a5aea534`]]),_hoisted_1$164={key:0,class:`bindings-app`},_hoisted_2$136={key:0,class:`toggle-icon`},_hoisted_3$122={key:1,class:`toggle-icon`},_hoisted_4$100={key:0,class:`players-binding`},_hoisted_5$87={key:0},_hoisted_6$72={key:1,class:`bindings-container`},_hoisted_7$62={class:`binding-item`},_sfc_main$183={__name:`app`,setup(__props){let{$game}=useLibStore(),bindings=ref([]),small=ref(!0),timeout=ref(null),show=ref(0),players=ref([]),forward=()=>{show.value=(show.value+1)%bindings.value.length},backward=()=>{show.value=show.value===0?bindings.value.length-1:show.value-1},toggleSmall=()=>{small.value=!small.value,clearTimeout(timeout)},goToBindings=(action,control)=>{$game.events.emit(`MenuHide`,!1),bngVue.gotoGameState(`menu.options.controls.bindings.edit`,{params:{action:action.actionName,oldBinding:{control:control.c,device:control.n}}})};onMounted(()=>{$game.events.on(`InputBindingsChanged`,onInputBindingsChanged),$game.events.on(`VehicleChange`,showBriefly),$game.events.on(`VehicleFocusChanged`,showBriefly),$game.api.engineLua(`extensions.core_input_bindings.notifyUI("keys app: link init")`),setTimeout(function(){$game.api.engineLua(`settings.notifyUI()`)},200)}),onUnmounted(()=>{$game.events.off(`InputBindingsChanged`,onInputBindingsChanged),$game.events.off(`VehicleChange`,showBriefly),$game.events.off(`VehicleFocusChanged`,showBriefly)});function showBriefly(){small.value&&(timeout.value=setTimeout(()=>small.value=!0,1e4)),small.value=!1}function onInputBindingsChanged(data){let specialKeys=[];players.value=[];for(let i=0;i=bindings.value.length&&(show.value=0)}function existsAt(arr,ac){return arr.map(function(elem,i){return elem.actionName===ac?i:-1}).filter(function(elem){return elem!==-1})}return(_ctx,_cache)=>players.value.length>1||bindings.value[show.value]&&bindings.value[show.value].length>0?(openBlock(),createElementBlock(`div`,_hoisted_1$164,[createBaseVNode(`div`,{onClick:_cache[0]||=$event=>toggleSmall(),class:`binding-show`},[small.value?(openBlock(),createElementBlock(`span`,_hoisted_2$136,[createVNode(unref(bngIcon_default),{class:`key-icon`,type:unref(icons).arrowSmallLeft},null,8,[`type`])])):(openBlock(),createElementBlock(`span`,_hoisted_3$122,[createVNode(unref(bngIcon_default),{class:`key-icon`,type:unref(icons).arrowSmallRight},null,8,[`type`])]))]),!small.value&&(players.value.length>1||bindings.value[show.value]&&bindings.value[show.value].length>0)?(openBlock(),createElementBlock(`div`,_hoisted_4$100,[!small.value&&players.value.length>1?(openBlock(),createElementBlock(`div`,_hoisted_5$87,[bindings.value.length>1?(openBlock(),createBlock(unref(bngButton_default),{key:0,onClick:_cache[1]||=$event=>backward()})):createCommentVNode(``,!0),createBaseVNode(`span`,null,`Player `+toDisplayString(show.value),1),bindings.value.length>1?(openBlock(),createBlock(unref(bngButton_default),{key:1,onClick:_cache[2]||=$event=>forward()})):createCommentVNode(``,!0)])):createCommentVNode(``,!0),bindings.value[show.value].length>0&&!small.value?(openBlock(),createElementBlock(`div`,_hoisted_6$72,[(openBlock(!0),createElementBlock(Fragment,null,renderList(bindings.value[show.value],entry=>(openBlock(),createElementBlock(`div`,_hoisted_7$62,[createBaseVNode(`div`,null,toDisplayString(_ctx.$t(entry.action)),1),createBaseVNode(`div`,null,[(openBlock(!0),createElementBlock(Fragment,null,renderList(entry.control,b=>(openBlock(),createBlock(unref(bngBinding_default),{deviceKey:b.c,device:b.d,"show-unassigned":!0,onClick:$event=>goToBindings(entry,b)},null,8,[`deviceKey`,`device`,`onClick`]))),256))])]))),256))])):createCommentVNode(``,!0)])):createCommentVNode(``,!0)])):createCommentVNode(``,!0)}},app_default$23=__plugin_vue_export_helper_default(_sfc_main$183,[[`__scopeId`,`data-v-b0d8eae9`]]),_hoisted_1$163={class:`bng-app log-vehicle-stats`},_hoisted_2$135={class:`update-period`},_hoisted_3$121={class:`settings-row`},_hoisted_4$99={class:`settings-row`},_hoisted_5$86={class:`settings-row`},_hoisted_6$71={class:`settings-row`},_hoisted_7$61={class:`log-btns`},_sfc_main$182={__name:`app`,setup(__props){const{$game}=useLibStore(),config=reactive({updateTime:5,moduleGeneral:!0,moduleWheels:!0,moduleEngine:!0,moduleInputs:!0,modulePowertrain:!0,outputFileName:`settings.json`,inputFileName:`settings.json`,outputDir:`VSL`}),configChanged=(configName,value)=>{switch(configName){case`moduleGeneral`:config.moduleGeneral=value;break;case`moduleWheels`:config.moduleWheels=value;break;case`moduleEngine`:config.moduleEngine=value;break;case`moduleInputs`:config.moduleInputs=value;break;case`modulePowertrain`:config.modulePowertrain=value;break}},applySettings=()=>{$game.api.activeObjectLua(`extensions.vehicleStatsLogger.updateTime = ${config.updateTime}`),$game.api.activeObjectLua(`extensions.vehicleStatsLogger.settings.useModule["General"] = ${config.moduleGeneral}`),$game.api.activeObjectLua(`extensions.vehicleStatsLogger.settings.useModule["Wheels"] = ${config.moduleWheels}`),$game.api.activeObjectLua(`extensions.vehicleStatsLogger.settings.useModule["Inputs"] = ${config.moduleInputs}`),$game.api.activeObjectLua(`extensions.vehicleStatsLogger.settings.useModule["Engine"] = ${config.moduleEngine}`),$game.api.activeObjectLua(`extensions.vehicleStatsLogger.settings.useModule["Powertrain"] = ${config.modulePowertrain}`)},useAsOutputDir=()=>{$game.api.activeObjectLua(`extensions.vehicleStatsLogger.settings.outputDir = "${config.outputDir}"`)},getNewOutputFilename=()=>{$game.api.activeObjectLua(`extensions.vehicleStatsLogger.suggestOutputFilename()`,function(data){config.outputFileName=data})},saveSettingsToJson=()=>{config.outputFileName!==``&&$game.api.activeObjectLua(`extensions.vehicleStatsLogger.writeSettingsToJSON("${config.outputFileName}")`)},importSettingsFromFile=()=>{scope.inputFileName!==``&&($game.api.activeObjectLua(`extensions.vehicleStatsLogger.applySettingsFromJSON("${config.inputFileName}")`),config.moduleGeneral=eval(`${extensions.vehicleStatsLogger.settings.useModule.General}`),config.moduleWheels=eval(`${extensions.vehicleStatsLogger.settings.useModule.Wheels}`),config.moduleInputs=eval(`${extensions.vehicleStatsLogger.settings.useModule.Inputs}`),config.moduleEngine=eval(`${extensions.vehicleStatsLogger.settings.useModule.Engine}`),config.modulePowertrain=eval(`${extensions.vehicleStatsLogger.settings.useModule.Powertrain}`))},startLogging=()=>{$game.api.activeObjectLua(`extensions.vehicleStatsLogger.startLogging()`)},stopLogging=()=>{$game.api.activeObjectLua(`extensions.vehicleStatsLogger.stopLogging()`)};return(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$163,[createBaseVNode(`div`,_hoisted_2$135,[_cache[20]||=createBaseVNode(`span`,{class:`label`},`Update Period:`,-1),createVNode(unref(bngInput_default),{type:`number`,min:1,max:360,step:1,modelValue:config.updateTime,"onUpdate:modelValue":_cache[0]||=$event=>config.updateTime=$event,suffix:`seconds`},null,8,[`modelValue`])]),createBaseVNode(`div`,null,[createVNode(unref(bngPillCheckbox_default),{modelValue:config.moduleGeneral,"onUpdate:modelValue":_cache[1]||=$event=>config.moduleGeneral=$event,onValueChanged:_cache[2]||=val=>configChanged(`moduleGeneral`,val)},{default:withCtx(()=>[..._cache[21]||=[createTextVNode(` General`,-1)]]),_:1},8,[`modelValue`]),createVNode(unref(bngPillCheckbox_default),{modelValue:config.moduleWheels,"onUpdate:modelValue":_cache[3]||=$event=>config.moduleWheels=$event,onValueChanged:_cache[4]||=val=>configChanged(`moduleWheels`,val)},{default:withCtx(()=>[..._cache[22]||=[createTextVNode(` Wheels`,-1)]]),_:1},8,[`modelValue`]),createVNode(unref(bngPillCheckbox_default),{modelValue:config.moduleEngine,"onUpdate:modelValue":_cache[5]||=$event=>config.moduleEngine=$event,onValueChanged:_cache[6]||=val=>configChanged(`moduleEngine`,val)},{default:withCtx(()=>[..._cache[23]||=[createTextVNode(` Engine`,-1)]]),_:1},8,[`modelValue`]),createVNode(unref(bngPillCheckbox_default),{modelValue:config.moduleInputs,"onUpdate:modelValue":_cache[7]||=$event=>config.moduleInputs=$event,onValueChanged:_cache[8]||=val=>configChanged(`moduleInputs`,val)},{default:withCtx(()=>[..._cache[24]||=[createTextVNode(` Inputs`,-1)]]),_:1},8,[`modelValue`]),createVNode(unref(bngPillCheckbox_default),{modelValue:config.modulePowertrain,"onUpdate:modelValue":_cache[9]||=$event=>config.modulePowertrain=$event,onValueChanged:_cache[10]||=val=>configChanged(`modulePowertrain`,val)},{default:withCtx(()=>[..._cache[25]||=[createTextVNode(`Powertrain`,-1)]]),_:1},8,[`modelValue`])]),createBaseVNode(`div`,_hoisted_3$121,[_cache[27]||=createBaseVNode(`label`,null,`Apply Settings:`,-1),createVNode(unref(bngButton_default),{class:`settings-btn`,onClick:_cache[11]||=$event=>applySettings()},{default:withCtx(()=>[..._cache[26]||=[createTextVNode(`Apply`,-1)]]),_:1})]),withDirectives((openBlock(),createElementBlock(`div`,_hoisted_4$99,[_cache[29]||=createBaseVNode(`label`,null,`Set Custom Output Directory:`,-1),createVNode(unref(bngInput_default),{modelValue:config.outputDir,"onUpdate:modelValue":_cache[12]||=$event=>config.outputDir=$event},null,8,[`modelValue`]),createVNode(unref(bngButton_default),{class:`settings-btn`,onClick:_cache[13]||=$event=>useAsOutputDir()},{default:withCtx(()=>[..._cache[28]||=[createTextVNode(`Use`,-1)]]),_:1})])),[[unref(BngTooltip_default),`Subdirectory of the BeamNG.drive/BeamNG.tech directory.`]]),withDirectives((openBlock(),createElementBlock(`div`,_hoisted_5$86,[_cache[31]||=createBaseVNode(`label`,null,`Settings Output Filename:`,-1),createVNode(unref(bngInput_default),{modelValue:config.outputFileName,"onUpdate:modelValue":_cache[14]||=$event=>config.outputFileName=$event},null,8,[`modelValue`]),createVNode(unref(bngButton_default),{class:`settings-btn`,onClick:_cache[15]||=$event=>saveSettingsToJson()},{default:withCtx(()=>[..._cache[30]||=[createTextVNode(`Write`,-1)]]),_:1})])),[[unref(BngTooltip_default),`Settings files are written to the BeamNG.drive/BeamNG.tech directory.`]]),withDirectives((openBlock(),createElementBlock(`div`,_hoisted_6$71,[_cache[33]||=createBaseVNode(`label`,null,`Settings Input Filename:`,-1),createVNode(unref(bngInput_default),{modelValue:config.inputFileName,"onUpdate:modelValue":_cache[16]||=$event=>config.inputFileName=$event},null,8,[`modelValue`]),createVNode(unref(bngButton_default),{class:`settings-btn`,onClick:_cache[17]||=$event=>importSettingsFromFile()},{default:withCtx(()=>[..._cache[32]||=[createTextVNode(`Load`,-1)]]),_:1})])),[[unref(BngTooltip_default),`Settings files are assumed to be in the BeamNG.drive/BeamNG.tech directory.`]]),createBaseVNode(`div`,_hoisted_7$61,[createVNode(unref(bngButton_default),{class:`start-btn`,onClick:_cache[18]||=$event=>startLogging()},{default:withCtx(()=>[..._cache[34]||=[createTextVNode(`Start Log`,-1)]]),_:1}),createVNode(unref(bngButton_default),{class:`stop-btn`,onClick:_cache[19]||=$event=>stopLogging()},{default:withCtx(()=>[..._cache[35]||=[createTextVNode(`Stop Log`,-1)]]),_:1})])]))}},app_default$24=__plugin_vue_export_helper_default(_sfc_main$182,[[`__scopeId`,`data-v-686c3ac5`]]),_hoisted_1$162={class:`replay-app-container`,ref:`appContainerRef`},_hoisted_2$134={class:`left-controls`},_hoisted_3$120={class:`filename-container`},_hoisted_4$98={key:1,class:`filename`},_hoisted_5$85={key:1,class:`filename`},_hoisted_6$70={class:`right-controls`},_hoisted_7$60={class:`replay-controls-container`},_hoisted_8$50={class:`play-controls`},_hoisted_9$44={key:0,class:`speed-controls`},_hoisted_10$37={class:`svg-time-container`},_hoisted_11$33={width:`100%`,height:`100%`,preserveAspectRatio:`xMidYMid meet`},_hoisted_12$26={viewBox:`0 0 200 50`,width:`100%`,height:`100%`,overflow:`visible`},_hoisted_13$23={transform:`translate(100, 25)`},_hoisted_14$22={"text-anchor":`middle`,"dominant-baseline":`middle`,class:`time-text`,"font-size":`40`,"line-height":`1`},_hoisted_15$21={class:`time-display-total`},_hoisted_16$21={class:`position-slider`},replayFolder=`replays/`,replayFileExtension=`.rpl`,_sfc_main$181={__name:`app`,props:{hideFileControls:{type:Boolean,default:!1}},setup(__props){let state=ref(`inactive`),speed=ref(1),paused=ref(!1),renaming=ref(!1),isSeeking=ref(!1),loadedFile=ref(``),positionSeconds=ref(0),totalSeconds=ref(0),positionPercent=ref(0),fpsRec=ref(0),fpsPlay=ref(0),originalFilename=``,lastSeek=0,events$3=useEvents(),resizeObserver=ref(null),replayControlsRef=ref(null),containerWidth=shallowRef(0),layoutState=computed(()=>{let width$1=containerWidth.value;return{isReplayControlsNarrow:width$1<301,isFileControlsNarrow:width$1<361}}),props=__props,formatTime$1=seconds=>new Date(seconds*1e3).toISOString().substr(14,8),debounce$1=(fn,delay)=>{let timer=null;return(...args)=>{timer&&clearTimeout(timer),timer=setTimeout(()=>{fn(...args),timer=null},delay)}},listRecordings=()=>{window.bngVue.gotoGameState(`menu.replay`)},startRenaming=()=>{renaming.value=!0,originalFilename=loadedFile.value},cancelRename=()=>{renaming.value=!1,loadedFile.value=originalFilename},acceptRename=()=>{if(loadedFile.value===originalFilename){cancelRename();return}renaming.value=!1,Lua_default.core_replay.acceptRename(replayFolder+originalFilename+replayFileExtension,replayFolder+loadedFile.value+replayFileExtension)},toggleSpeed=val=>{Lua_default.core_replay.toggleSpeed(val)},togglePlay=()=>{Lua_default.core_replay.togglePlay()},toggleRecording=()=>{Lua_default.core_replay.toggleRecording(!0)},cancelRecording=()=>{Lua_default.core_replay.cancelRecording()},stop$1=()=>{Lua_default.core_replay.stop()},seek=()=>{state.value===`playback`&&(lastSeek=Date.now(),Lua_default.core_replay.pause(!0),Lua_default.core_replay.seek(positionPercent.value))};watch(positionSeconds,(newVal,oldVal)=>{Date.now()-lastSeek>500&&totalSeconds.value>0&&(positionPercent.value=newVal/totalSeconds.value)});let setupResizeObserver=()=>{if(!replayControlsRef.value)return;let rafId=null,updateWidth=debounce$1(width$1=>{containerWidth.value=width$1},100);resizeObserver.value=new ResizeObserver(entries=>{rafId!==null&&cancelAnimationFrame(rafId),rafId=requestAnimationFrame(()=>{for(let entry of entries)updateWidth(entry.contentRect.width);rafId=null})}),resizeObserver.value.observe(replayControlsRef.value)};return onMounted(async()=>{try{Lua_default.core_replay.onInit()}catch(e){console.error(`Error initializing replay state:`,e)}events$3.on(`replayStateChanged`,val=>{renaming.value||(loadedFile.value=val.loadedFile.replace(replayFolder,``).replace(replayFileExtension,``)),positionSeconds.value=val.positionSeconds,totalSeconds.value=val.totalSeconds,speed.value=val.speed,paused.value=val.paused,fpsRec.value=val.fpsRec,fpsPlay.value=val.fpsPlay,state.value=val.state,isSeeking.value=val.jumpOffset!==0,Date.now()-lastSeek>500&&totalSeconds.value>0?positionPercent.value=positionSeconds.value/totalSeconds.value:isSeeking.value=!0}),await nextTick(),setupResizeObserver()}),onUnmounted(()=>{resizeObserver.value&&=(resizeObserver.value.disconnect(),null),events$3.off(`replayStateChanged`)}),(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$162,[props.hideFileControls?createCommentVNode(``,!0):(openBlock(),createElementBlock(`div`,{key:0,class:normalizeClass([`file-controls`,{narrow:layoutState.value.isFileControlsNarrow}])},[createBaseVNode(`div`,_hoisted_2$134,[createVNode(unref(bngButton_default),{class:`recordings-button`,onClick:listRecordings,icon:`folder`,tooltip:`Open recordings`,accent:unref(ACCENTS).text},null,8,[`accent`]),loadedFile.value&&state.value!==`recording`&&!renaming.value?(openBlock(),createBlock(unref(bngButton_default),{key:0,class:`recordings-button`,onClick:stop$1,icon:`xmark`,disabled:state.value!==`playback`,tooltip:`Close replay`,accent:unref(ACCENTS).text},null,8,[`disabled`,`accent`])):createCommentVNode(``,!0),state.value===`recording`?(openBlock(),createBlock(unref(bngButton_default),{key:1,class:`recordings-button`,onClick:cancelRecording,icon:`undo`,accent:unref(ACCENTS).attention,tooltip:`Cancel recording`},null,8,[`accent`])):createCommentVNode(``,!0)]),createBaseVNode(`div`,_hoisted_3$120,[loadedFile.value&&state.value!==`recording`?(openBlock(),createElementBlock(Fragment,{key:0},[renaming.value?(openBlock(),createElementBlock(Fragment,{key:0},[createVNode(unref(bngButton_default),{onClick:cancelRename,icon:`xmark`,accent:unref(ACCENTS).ghost,class:`cancel-rename-button`},null,8,[`accent`]),createVNode(unref(bngInput_default),{id:`replay-filename-input`,class:`filename-input`,prefix:replayFolder,suffix:replayFileExtension,modelValue:loadedFile.value,"onUpdate:modelValue":_cache[0]||=$event=>loadedFile.value=$event,placeholder:`(no file)`,disabled:state.value===`recording`||!loadedFile.value,onKeyup:withKeys(acceptRename,[`enter`])},null,8,[`modelValue`,`disabled`])],64)):(openBlock(),createElementBlock(`div`,_hoisted_4$98,toDisplayString(replayFolder)+toDisplayString(loadedFile.value)+toDisplayString(replayFileExtension),1)),createVNode(unref(bngButton_default),{onClick:_cache[1]||=$event=>renaming.value?acceptRename():startRenaming(),icon:renaming.value?`checkmark`:`edit`,accent:renaming.value?unref(ACCENTS).main:unref(ACCENTS).ghost},null,8,[`icon`,`accent`])],64)):(openBlock(),createElementBlock(`div`,_hoisted_5$85,` No File loaded `))]),createBaseVNode(`div`,_hoisted_6$70,[createVNode(unref(bngButton_default),{onClick:toggleRecording,icon:state.value===`recording`?`square`:`bigDot`,accent:unref(ACCENTS).text,disabled:state.value===`playback`,tooltip:state.value===`recording`?`Save recording`:`Record new replay`,class:`recordings-button record-button`},null,8,[`icon`,`accent`,`disabled`,`tooltip`])])],2)),createBaseVNode(`div`,_hoisted_7$60,[createBaseVNode(`div`,{class:normalizeClass([`replay-controls`,{narrow:layoutState.value.isReplayControlsNarrow}]),ref_key:`replayControlsRef`,ref:replayControlsRef},[createBaseVNode(`div`,_hoisted_8$50,[createVNode(unref(bngButton_default),{onClick:togglePlay,class:`play-button`,icon:state.value===`playback`&&!paused.value?`pause`:`play`,disabled:state.value===`recording`||!loadedFile.value,accent:unref(ACCENTS).ghost},null,8,[`icon`,`disabled`,`accent`]),state.value===`inactive`?createCommentVNode(``,!0):(openBlock(),createElementBlock(`div`,_hoisted_9$44,[createVNode(unref(bngButton_default),{class:`speed-button small`,onClick:_cache[2]||=$event=>toggleSpeed(-1),icon:`mathMinus`,disabled:!loadedFile.value,accent:unref(ACCENTS).text},null,8,[`disabled`,`accent`]),createBaseVNode(`div`,{class:normalizeClass([`playback-speed-display`,{disabled:!loadedFile.value}])},toDisplayString(speed.value.toFixed(2))+`x`,3),createVNode(unref(bngButton_default),{class:`speed-button small`,onClick:_cache[3]||=$event=>toggleSpeed(1),icon:`mathPlus`,disabled:!loadedFile.value,accent:unref(ACCENTS).text},null,8,[`disabled`,`accent`])]))]),createBaseVNode(`div`,{class:normalizeClass([`time-display`,{active:loadedFile.value,seeking:isSeeking.value}])},[createBaseVNode(`div`,_hoisted_10$37,[(openBlock(),createElementBlock(`svg`,_hoisted_11$33,[(openBlock(),createElementBlock(`svg`,_hoisted_12$26,[createBaseVNode(`g`,_hoisted_13$23,[createBaseVNode(`text`,_hoisted_14$22,toDisplayString(formatTime$1(positionSeconds.value)),1)])]))]))]),createBaseVNode(`span`,_hoisted_15$21,`(`+toDisplayString(formatTime$1(totalSeconds.value))+`)`,1)],2)],2),createBaseVNode(`div`,_hoisted_16$21,[createVNode(unref(bngSlider_default),{modelValue:positionPercent.value,"onUpdate:modelValue":_cache[4]||=$event=>positionPercent.value=$event,min:0,max:1,step:.001,onInput:seek,disabled:state.value!==`playback`||!loadedFile.value},null,8,[`modelValue`,`disabled`])])])],512))}},app_default$1=__plugin_vue_export_helper_default(_sfc_main$181,[[`__scopeId`,`data-v-bf84291a`]]),_hoisted_1$161={style:{width:`100%`,height:`100%`},class:`bng-app`,layout:`column`},_hoisted_2$133={style:{display:`flex`,"justify-content":`center`,"align-items":`baseline`}},_hoisted_3$119={style:{"font-size":`1.3em`,"font-weight":`bold`}},_hoisted_4$97={style:{color:`rgba(255, 255, 255, 0.8)`}},_hoisted_5$84={style:{"text-align":`center`,color:`rgba(255, 255, 255, 0.8)`,"font-size":`0.75em`}},_sfc_main$180={__name:`app`,setup(__props){let{$game}=useLibStore(),streamsList$1=[`engineInfo`];$game.streams.add(streamsList$1);let numToBig=ref(`1`);ref(NaN);let rpm=ref(0),leadingZeros=ref(null);onMounted(()=>{console.log(`simpleDigTacho mounted`),$game.events.on(`onStreamsUpdate`,onStreamsUpdate)}),onUnmounted(()=>{console.log(`simpleDigTacho unmounted`),$game.streams.remove(streamsList$1),$game.events.off(`onStreamsUpdate`,onStreamsUpdate)});function onStreamsUpdate(streams){for(let stream of streamsList$1)if(!streams[stream])return;if(rpm.value=Math.round(streams.engineInfo[4]),rpm.value.toString().length>4){let help=10**(rpm.value.toString().length-4);numToBig.value=help.toString(),rpm.value=Math.round(rpm.value/help)}else numToBig.value=`1`;rpm.value=rpm.value.toString().slice(-4),isNaN(rpm.value)||(leadingZeros.value=`0000`.slice(rpm.value.length))}return(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$161,[createBaseVNode(`div`,_hoisted_2$133,[createBaseVNode(`span`,_hoisted_3$119,[createBaseVNode(`span`,_hoisted_4$97,toDisplayString(leadingZeros.value),1),createBaseVNode(`span`,null,toDisplayString(rpm.value),1)]),_cache[0]||=createBaseVNode(`span`,{style:{"font-size":`0.9em`,"font-weight":`bold`,"margin-left":`2px`}},`RPM`,-1)]),createBaseVNode(`small`,_hoisted_5$84,[createTextVNode(toDisplayString(_ctx.$t(`ui.apps.digTacho.engine`))+` `,1),createBaseVNode(`span`,null,`(x`+toDisplayString(numToBig.value)+`)`,1)])]))}},app_default$25=_sfc_main$180,_hoisted_1$160={"xmlns:svg":`http://www.w3.org/2000/svg`,xmlns:`http://www.w3.org/2000/svg`,"xmlns:xlink":`http://www.w3.org/1999/xlink`,version:`1.1`,width:`100%`,height:`100%`,viewBox:`0 0 660 660`},_hoisted_2$132={"xml:space":`preserve`,class:`text1`,x:`329.88641`,y:`289.30463`,id:`tspan4449-43`},_hoisted_3$118={"xml:space":`preserve`,id:`speed_units`,class:`speed-units`,x:`330`,y:`348`},_hoisted_4$96={"xml:space":`preserve`,id:`tspan4449-4-3`,class:`tacho2-gear`,x:`386.67343`,y:`457.94861`,transform:`matrix(1,0,-0.13142611,1,0,0)`},_hoisted_5$83={"xml:space":`preserve`,x:`330.09229`,y:`498.18045`,id:`text4447-2-4`,class:`rpm-text-legend`},_hoisted_6$69={transform:`translate(-150,-214)`,id:`revcurvemask`,class:`revcurvemask`,"clip-path":`url(#clipPath4710)`},rpmTextSize=50,maxRpmTexts=13,tickMarkLength=64,tickInnerOffset=42,_sfc_main$179={__name:`tacho`,setup(__props,{expose:__expose}){let width$1=660,height$1=660,initialized=ref(!1),dashSize$1=5,computeGaugeFullRange=maxrpm=>Math.ceil((maxrpm||0)/1e3)*1e3+1e3,computeGaugeStep=maxrpm=>maxrpm<4e3?500:maxrpm>15e3?2e3:1e3,computeGaugeMarks=maxrpm=>{let fullRange=computeGaugeFullRange(maxrpm),step=computeGaugeStep(maxrpm);return Math.ceil(fullRange/step)+1},rpmTextRefs=ref([]),setRpmRef=(el,i)=>{el&&(rpmTextRefs.value[i]=el)},oilTempBarRef=ref(null),oilTempBarLen=computed(()=>oilTempBarRef.value.getTotalLength()),oilTempIcoOffRef=ref(null),oilTempIcoOnRef=ref(null),speedTextRef=ref(null),gearTextRef=ref(null),revcurveRef=ref(null),revCurveLen=computed(()=>revcurveRef.value.getTotalLength()),revcurveDashesRef=ref(null),revCurveDashesLen=computed(()=>revcurveDashesRef.value.getTotalLength()),fuelBarRef=ref(null),fuelBarLen=computed(()=>fuelBarRef.value.getTotalLength()),fuelWarnIcoOffRef=ref(null),fuelWarnIcoOnRef=ref(null),lastFuelLevel=0,shouldPlayFuelLowSound=!1,lowFuelSoundPlayed=!1,isCareer=!1,redLineRef=ref(null),redLineLen=computed(()=>redLineRef.value.getTotalLength()),rpmTextGuideLineRef=ref(null),rpmTextGuideLineLen=computed(()=>rpmTextGuideLineRef.value.getTotalLength()),tickMarkRefs=ref([]),setTickRef=(el,i)=>{el&&(tickMarkRefs.value[i]=el)},icoHandBrakeOffRef=ref(null),icoHandBrakeOnRef=ref(null),icoABSOffRef=ref(null),icoABSOnRef=ref(null),icoIndicatorLeftOffRef=ref(null),icoIndicatorLeftOnRef=ref(null),icoIndicatorRightOffRef=ref(null),icoIndicatorRightOnRef=ref(null),icoLightsOffRef=ref(null),icoLightsOnRef=ref(null),icoLightsHighRef=ref(null),layer3Ref=ref(null),layer4Ref=ref(null),layer6Ref=ref(null),layer7Ref=ref(null),layer10Ref=ref(null),layer11Ref=ref(null),layer12Ref=ref(null),tickLayerRef=ref(null),speedUnitTextRef=ref(null),rpm_max=ref(8e3),rpmLegendTextRef=ref(null),revNeedleRef=ref(null),displayMode=ref(2);onMounted(()=>{rpmLegendTextRef?.value&&(rpmLegendTextRef.value.textContent=`x1000 RPM`),oilTempBarRef.value.style.strokeDasharray=oilTempBarLen.value+` `+oilTempBarLen.value,speedTextRef.value.textContent=``,revcurveRef.value.style.strokeDasharray=revCurveLen.value+` `+revCurveLen.value,fuelBarRef.value.style.strokeDasharray=fuelBarLen.value+` `+fuelBarLen.value,rpmTextGuideLineRef.value.style.display=`none`;for(let k=0;kisCareer=isActive)});function applyData(data$1){speedTextRef.value.textContent=data$1.speedtext,(speedTextRef.value.textContent==`-Infinity`||speedTextRef.value.textContent==`Infinity`)&&(speedTextRef.value.textContent=`-`),gearTextRef.value.textContent=data$1.geartext,fuelBarRef.value.style[`stroke-dashoffset`]=(1-data$1.fuel)*fuelBarLen.value;let fuelLow=data$1.fuel<.1,fuelGoneLow=lastFuelLevel>=.1&&fuelLow;lastFuelLevel=data$1.fuel,fuelWarnIcoOffRef.value.style.visibility=fuelLow?`hidden`:`visible`,fuelWarnIcoOnRef.value.style.visibility=fuelLow?`visible`:`hidden`,data$1.ignition&&isCareer&&fuelGoneLow&&!shouldPlayFuelLowSound&&setTimeout(()=>shouldPlayFuelLowSound=!0,0),shouldPlayFuelLowSound&&!lowFuelSoundPlayed&&(lowFuelSoundPlayed=!0,Lua_default.ui_audio.playEventSound(`bng_career_fuel`,`low_fuel`)),icoHandBrakeOffRef.value.style.visibility=data$1.parkingBrake?`hidden`:`visible`,icoHandBrakeOnRef.value.style.visibility=data$1.parkingBrake?`visible`:`hidden`,icoABSOffRef.value.style.visibility=data$1.absWorking?`hidden`:`visible`,icoABSOnRef.value.style.visibility=data$1.absWorking?`visible`:`hidden`,icoIndicatorLeftOffRef.value.style.visibility=data$1.signalL?`hidden`:`visible`,icoIndicatorLeftOnRef.value.style.visibility=data$1.signalL?`visible`:`hidden`,icoIndicatorRightOffRef.value.style.visibility=data$1.signalR?`hidden`:`visible`,icoIndicatorRightOnRef.value.style.visibility=data$1.signalR?`visible`:`hidden`;let tempNormalized=Math.max(Math.min((data$1.waterTemp-50)/80,1),0);oilTempBarRef.value.style.strokeDashoffset=(1+tempNormalized)*oilTempBarLen.value;let oilTemp_warn=tempNormalized>.8125;if(oilTempIcoOffRef.value.style.visibility=oilTemp_warn?`hidden`:`visible`,oilTempIcoOnRef.value.style.visibility=oilTemp_warn?`visible`:`hidden`,data$1.lowBeam!==void 0&&data$1.highBeam!==void 0){let nb=!0,lb=data$1.lowBeam>.9,hb=data$1.highBeam>.9;lb&&(nb=!1),hb&&(nb=!1),icoLightsOffRef.value.style.visibility=nb?`visible`:`hidden`,icoLightsOnRef.value.style.visibility=lb?`visible`:`hidden`,icoLightsHighRef.value.style.visibility=hb?`visible`:`hidden`}else icoLightsOffRef.value.style.visibility=`hidden`,icoLightsOnRef.value.style.visibility=`hidden`,icoLightsHighRef.value.style.visibility=`hidden`;let rpm_rotation=data$1.rpm*270-180;rpm_rotation<-180&&(rpm_rotation=-180),rpm_rotation>90&&(rpm_rotation=90),revNeedleRef.value.setAttribute(`transform`,`rotate(`+rpm_rotation+`,330,330)`);let revCurveOffset=(1-data$1.rpm)*revCurveLen.value;revCurveOffset<0&&(revCurveOffset=0),revCurveOffset>revCurveLen.value&&(revCurveOffset=revCurveLen.value),revcurveRef.value.style.strokeDashoffset=revCurveOffset}let data=ref({}),layersVisible=!1;function setlayersVisible(v){if(layersVisible!=v){let val=v?`inline`:`none`;layer3Ref.value.style.display=val,layer4Ref.value.style.display=val,layer6Ref.value.style.display=val,layer7Ref.value.style.display=val,layer10Ref.value.style.display=val,layer11Ref.value.style.display=val,layer12Ref.value.style.display=val,tickLayerRef.value.style.display=val,layersVisible=v}}function reset$1(){setlayersVisible(!1),initialized.value=!1;for(let k=0;k=0?1:-1,inx=nx*sign,iny=ny*sign,x1=pt.x+inx*tickInnerOffset,y1=pt.y+iny*tickInnerOffset,x2=x1+inx*tickMarkLength,y2=y1+iny*tickMarkLength;line.setAttribute(`x1`,x1),line.setAttribute(`y1`,y1),line.setAttribute(`x2`,x2),line.setAttribute(`y2`,y2),line.style.visibility=`visible`}}for(let k=dashCount$1+1;k<=maxRpmTexts;k++){let rp=rpmTextRefs.value[k];rp&&(rp.style.visibility=`hidden`);let line=tickMarkRefs.value[k];line&&(line.style.visibility=`hidden`)}initialized.value=!0}if(!isStreamValid)return!1;if(setlayersVisible(!0),displayMode.value==2)streams.electrics.wheelspeed?(data.speedtext=UnitSpeed(streams.electrics.wheelspeed),streams.electrics.wheelspeed>9e3&&(speedUnitTextRef.value.textContent=`brrrr`)):streams.electrics.airspeed&&(data.speedtext=UnitSpeed(streams.electrics.airspeed)),(function(){if(streams.engineInfo[13]==`manual`){let gear=streams.engineInfo[5],gearStr=gear.toString();gear==0?gearStr=`N`:gear==-1?gearStr=`R`:-gear>1&&(gearStr=`R`+-gear),data.geartext=gearStr}else data.geartext=[`P`,`R`,`N`,`D`,`2`,`1`][Math.round(streams.electrics.gear_A*5)]})(),data.fuel=streams.engineInfo[11]/streams.engineInfo[12],data.parkingBrake=streams.electrics.parkingbrake,data.absWorking=streams.electrics.abs,data.signalL=streams.electrics.signal_L,data.signalR=streams.electrics.signal_R,data.waterTemp=streams.electrics.watertemp,data.lowBeam=streams.electrics.lowbeam,data.highBeam=streams.electrics.highbeam,data.rpm=(streams.electrics.rpmTacho||0)/rpm_max.value;else if(displayMode.value==0){testVar+=.04,testVar>1&&(testVar=1),data.speedtext=Math.round(testVar*100),data.geartext=Math.round(testVar*5),data.fuel=testVar;let boolTest=!0;data.parkingBrake=!0,data.absWorking=!0,data.signalL=!0,data.signalR=!0,data.oilTemp=testVar,data.lowBeam=!0,data.highBeam=!1,data.rpm=testVar,testVar>=1&&(testVar=0,displayMode.value=1)}else if(displayMode.value==1){streams.electrics.wheelspeed?data.speedtext=UnitSpeed(streams.electrics.wheelspeed):(data.speedtext=``,speedUnitTextRef.value.textContent=``),(function(){let gear=streams.engineInfo[5],gearStr=gear.toString();gear==0?gearStr=`N`:gear==-1&&(gearStr=`R`),data.geartext=gearStr})(),data.parkingBrake=streams.electrics.parkingbrake,data.absWorking=streams.electrics.abs,data.signalL=streams.electrics.signal_L,data.signalR=streams.electrics.signal_R,data.lowBeam=streams.electrics.lowbeam,data.highBeam=streams.electrics.highbeam;let oilok=Math.abs(data.oilTemp-streams.electrics.oiltemp)<.005;oilok||(data.oilTemp+=(streams.electrics.oiltemp-data.oilTemp)*.2);let rpmperc=streams.electrics.rpm/rpm_max.value,rpmok=Math.abs(data.rpm-rpmperc)<.005;rpmok||(data.rpm+=(rpmperc-data.rpm)*.2);let fuelperc=streams.engineInfo[11]/streams.engineInfo[12],fuelok=Math.abs(data.fuel-fuelperc)<.005;fuelok||(data.fuel+=(fuelperc-data.fuel)*.2),oilok&&rpmok&&fuelok&&(displayMode.value=2)}return data.engineRunning=streams.electrics.engineRunning,data.ignition=streams.electrics.ignition,applyData(data),!0}function vehicleChanged(){initialized.value=!1}let UiUnitscallback=ref(()=>null);function UnitSpeed(val){let convertedVal=UiUnitscallback.value(val,`speed`);return speedUnitTextRef.value.textContent=convertedVal.unit,Math.round(convertedVal.val)}function wireThroughUnitSystem(callback){UiUnitscallback.value=callback}return __expose({wireThroughUnitSystem,update:update$6,vehicleChanged}),(_ctx,_cache)=>(openBlock(),createElementBlock(`svg`,_hoisted_1$160,[_cache[17]||=createBaseVNode(`defs`,{id:`defs4`},[createBaseVNode(`linearGradient`,{id:`linearGradient3938`},[createBaseVNode(`stop`,{style:{"stop-color":`#ff0000`,"stop-opacity":`1`},offset:`0`,id:`stop3940`}),createBaseVNode(`stop`,{style:{"stop-color":`#00ff4b`,"stop-opacity":`1`},offset:`1`,id:`stop3942`})]),createBaseVNode(`linearGradient`,{id:`linearGradient4607`},[createBaseVNode(`stop`,{id:`stop4609`,offset:`0`,style:{"stop-color":`#e40000`,"stop-opacity":`1`}}),createBaseVNode(`stop`,{style:{"stop-color":`#e40000`,"stop-opacity":`1`},offset:`0.89960396`,id:`stop4611`}),createBaseVNode(`stop`,{id:`stop4613`,offset:`1`,style:{"stop-color":`#e40000`,"stop-opacity":`0`}}),createBaseVNode(`stop`,{id:`stop4615`,offset:`1`,style:{"stop-color":`#e40000`,"stop-opacity":`0`}})]),createBaseVNode(`linearGradient`,{id:`linearGradient4597`},[createBaseVNode(`stop`,{id:`stop4599`,offset:`0`,style:{"stop-color":`#e40000`,"stop-opacity":`1`}}),createBaseVNode(`stop`,{style:{"stop-color":`#e40000`,"stop-opacity":`1`},offset:`0.99812102`,id:`stop4601`}),createBaseVNode(`stop`,{id:`stop4603`,offset:`1`,style:{"stop-color":`#e40000`,"stop-opacity":`0`}}),createBaseVNode(`stop`,{id:`stop4605`,offset:`1`,style:{"stop-color":`#e40000`,"stop-opacity":`1`}})]),createBaseVNode(`linearGradient`,{id:`linearGradient4545`},[createBaseVNode(`stop`,{style:{"stop-color":`#e40000`,"stop-opacity":`1`},offset:`0`,id:`stop4547`}),createBaseVNode(`stop`,{id:`stop4553`,offset:`0.9861111`,style:{"stop-color":`#e40000`,"stop-opacity":`1`}}),createBaseVNode(`stop`,{style:{"stop-color":`#e40000`,"stop-opacity":`0`},offset:`1`,id:`stop4555`}),createBaseVNode(`stop`,{style:{"stop-color":`#e40000`,"stop-opacity":`0`},offset:`1`,id:`stop4549`})]),createBaseVNode(`linearGradient`,{id:`linearGradient4256`},[createBaseVNode(`stop`,{style:{"stop-color":`#6d0000`,"stop-opacity":`1`},offset:`0`,id:`stop4258`}),createBaseVNode(`stop`,{style:{"stop-color":`#6d0000`,"stop-opacity":`0`},offset:`1`,id:`stop4260`})]),createBaseVNode(`linearGradient`,{id:`linearGradient4365`},[createBaseVNode(`stop`,{style:{"stop-color":`#000000`,"stop-opacity":`0.42857143`},offset:`0`,id:`stop4367`}),createBaseVNode(`stop`,{id:`stop4373`,offset:`0.5`,style:{"stop-color":`#000000`,"stop-opacity":`0.33035713`}}),createBaseVNode(`stop`,{style:{"stop-color":`#000000`,"stop-opacity":`0`},offset:`1`,id:`stop4369`})]),createBaseVNode(`linearGradient`,{id:`linearGradient4357`},[createBaseVNode(`stop`,{style:{"stop-color":`#000000`,"stop-opacity":`1`},offset:`0`,id:`stop4359`}),createBaseVNode(`stop`,{style:{"stop-color":`#000000`,"stop-opacity":`0.19642857`},offset:`1`,id:`stop4361`})]),createBaseVNode(`marker`,{style:{overflow:`visible`},id:`DistanceStart`,refX:`0`,refY:`0`,orient:`auto`},[createBaseVNode(`g`,{id:`g2300`},[createBaseVNode(`path`,{style:{fill:`none`,stroke:`#ffffff`,"stroke-width":`1.14999998`,"stroke-linecap":`square`},d:`M 0,0 2,0`,id:`path2306`}),createBaseVNode(`path`,{style:{fill:`#000000`,"fill-rule":`evenodd`,stroke:`none`},d:`M 0,0 13,4 9,0 13,-4 0,0 z`,id:`path2302`}),createBaseVNode(`path`,{style:{fill:`none`,stroke:`#000000`,"stroke-width":`1`,"stroke-linecap":`square`},d:`M 0,-4 0,40`,id:`path2304`})])]),createBaseVNode(`radialGradient`,{"xlink:href":`#linearGradient4357`,id:`radialGradient4363`,cx:`480`,cy:`544`,fx:`480`,fy:`544`,r:`320`,gradientUnits:`userSpaceOnUse`,gradientTransform:`matrix(1.03125,0,0,1.03125,-15,-17)`}),createBaseVNode(`radialGradient`,{"xlink:href":`#linearGradient4365`,id:`radialGradient4371`,cx:`480`,cy:`544`,fx:`480`,fy:`544`,r:`320`,gradientUnits:`userSpaceOnUse`}),createBaseVNode(`clipPath`,{clipPathUnits:`userSpaceOnUse`,id:`clipPath4407`},[createBaseVNode(`path`,{id:`path4409`,d:`m 480,-103.33 c -357.5105,0 -647.33,289.8195 -647.33,647.33 0,357.5105 289.8195,647.33 647.33,647.33 357.5105,0 647.33,-289.8195 647.33,-647.33 0,-357.5105 -289.8195,-647.33 -647.33,-647.33 z m 0,453.131 c 107.25316,0 194.199,86.94584 194.199,194.199 0,107.25316 -86.94584,194.199 -194.199,194.199 -107.25316,0 -194.199,-86.94584 -194.199,-194.199 0,-107.25316 86.94584,-194.199 194.199,-194.199 z`,style:{color:`#000000`,fill:`#ffffff`,"fill-opacity":`0.61375661`,"fill-rule":`nonzero`,stroke:`none`,"stroke-width":`16`,marker:`none`,visibility:`visible`,display:`inline`,overflow:`visible`,"enable-background":`accumulate`}})]),createBaseVNode(`clipPath`,{clipPathUnits:`userSpaceOnUse`,id:`clipPath4321-9`},[createBaseVNode(`path`,{style:{color:`#000000`,fill:`#ffffff`,"fill-opacity":`1`,"fill-rule":`nonzero`,stroke:`none`,"stroke-width":`5`,marker:`none`,visibility:`visible`,display:`inline`,overflow:`visible`,"enable-background":`accumulate`},d:`m 480,224 c -20.28024,0 -40.11069,1.89279 -59.34375,5.5 l 12.0625,58.8125 C 448.05208,285.49499 463.85489,284 480,284 c 35.52728,0 69.40254,7.13112 100.25,20.03125 l 24.1875,-54.9375 C 566.18747,232.93508 524.13347,224 480,224 z m -69.0625,7.5 c -59.26533,13.0371 -112.35258,42.49901 -154.28125,83.375 l 42.53125,42.3125 c 24.37935,-23.60266 53.35266,-42.49216 85.46875,-55.15625 1.96795,-0.77601 3.94641,-1.52096 5.9375,-2.25 10.51172,-3.84886 21.33856,-7.01901 32.4375,-9.5 L 410.9375,231.5 z M 613.5,253.125 589.3125,308.03125 c 44.07702,20.45389 81.43119,52.91567 107.9375,93.15625 l 50.875,-31.875 C 715.25578,318.96815 668.59379,278.45303 613.5,253.125 z m -363.8125,68.75 c -41.23795,42.75016 -70.70543,96.92973 -83.125,157.34375 l 59.03125,11.0625 c 10.15322,-48.33557 33.70357,-91.7229 66.625,-126.09375 L 249.6875,321.875 z m 503.78125,55.8125 -50.90625,31.84375 C 726.31882,448.76688 740,494.78478 740,544 l 60,0 c 0,-60.90677 -16.99384,-117.84887 -46.53125,-166.3125 z m -588.75,111.25 C 161.61652,506.82573 160,525.2248 160,544 c 0,42.78463 8.42108,83.60181 23.65625,120.90625 L 238.84375,641.375 C 226.69144,611.30216 220,578.42944 220,544 c 0,-2.24366 0.0373,-4.48871 0.0937,-6.71875 0.3211,-12.67426 1.55282,-25.12039 3.625,-37.28125 l -59,-11.0625 z M 242.75,650.5 187.53125,674 c 23.4008,52.56805 60.5346,97.67196 106.875,130.71875 l 34.0625,-49.4375 C 291.42063,728.66516 261.6562,692.55546 242.75,650.5 z m 93.875,110.40625 -34.03125,49.40625 C 353.37348,844.20872 414.36502,864 480,864 l 0,-60 c -33.65485,0 -65.82451,-6.39115 -95.34375,-18.03125 -1.96795,-0.77601 -3.93088,-1.58396 -5.875,-2.40625 -14.80462,-6.26183 -28.90394,-13.88046 -42.15625,-22.65625 z`,id:`path4323-8`,"inkscape:connector-curvature":`0`})]),createBaseVNode(`radialGradient`,{"xlink:href":`#linearGradient4357`,id:`radialGradient4363-9`,cx:`480`,cy:`544`,fx:`480`,fy:`544`,r:`320`,gradientUnits:`userSpaceOnUse`,gradientTransform:`matrix(1.03125,0,0,1.03125,-15,-17)`}),createBaseVNode(`clipPath`,{clipPathUnits:`userSpaceOnUse`,id:`clipPath4407-3`},[createBaseVNode(`path`,{id:`path4409-5`,d:`m 480,-103.33 c -357.5105,0 -647.33,289.8195 -647.33,647.33 0,357.5105 289.8195,647.33 647.33,647.33 357.5105,0 647.33,-289.8195 647.33,-647.33 0,-357.5105 -289.8195,-647.33 -647.33,-647.33 z m 0,453.131 c 107.25316,0 194.199,86.94584 194.199,194.199 0,107.25316 -86.94584,194.199 -194.199,194.199 -107.25316,0 -194.199,-86.94584 -194.199,-194.199 0,-107.25316 86.94584,-194.199 194.199,-194.199 z`,style:{color:`#000000`,fill:`#ffffff`,"fill-opacity":`0.61375661`,"fill-rule":`nonzero`,stroke:`none`,"stroke-width":`16`,marker:`none`,visibility:`visible`,display:`inline`,overflow:`visible`,"enable-background":`accumulate`}})]),createBaseVNode(`radialGradient`,{gradientTransform:`matrix(0.37015162,0,0,0.37015162,685.90181,-270.76027)`,"xlink:href":`#linearGradient4365`,id:`radialGradient4371-4`,cx:`480`,cy:`544`,fx:`480`,fy:`544`,r:`320`,gradientUnits:`userSpaceOnUse`}),createBaseVNode(`linearGradient`,{"xlink:href":`#linearGradient4256`,id:`linearGradient4433`,gradientUnits:`userSpaceOnUse`,x1:`569.20557`,y1:`424.29861`,x2:`890.55139`,y2:`424.29861`}),createBaseVNode(`clipPath`,{clipPathUnits:`userSpaceOnUse`,id:`clipPath4321-4`},[createBaseVNode(`path`,{style:{color:`#000000`,fill:`#ffffff`,"fill-opacity":`1`,"fill-rule":`nonzero`,stroke:`none`,"stroke-width":`5`,marker:`none`,visibility:`visible`,display:`inline`,overflow:`visible`,"enable-background":`accumulate`},d:`m 480,224 c -20.28024,0 -40.11069,1.89279 -59.34375,5.5 l 12.0625,58.8125 C 448.05208,285.49499 463.85489,284 480,284 c 35.52728,0 69.40254,7.13112 100.25,20.03125 l 24.1875,-54.9375 C 566.18747,232.93508 524.13347,224 480,224 z m -69.0625,7.5 c -59.26533,13.0371 -112.35258,42.49901 -154.28125,83.375 l 42.53125,42.3125 c 24.37935,-23.60266 53.35266,-42.49216 85.46875,-55.15625 1.96795,-0.77601 3.94641,-1.52096 5.9375,-2.25 10.51172,-3.84886 21.33856,-7.01901 32.4375,-9.5 L 410.9375,231.5 z M 613.5,253.125 589.3125,308.03125 c 44.07702,20.45389 81.43119,52.91567 107.9375,93.15625 l 50.875,-31.875 C 715.25578,318.96815 668.59379,278.45303 613.5,253.125 z m -363.8125,68.75 c -41.23795,42.75016 -70.70543,96.92973 -83.125,157.34375 l 59.03125,11.0625 c 10.15322,-48.33557 33.70357,-91.7229 66.625,-126.09375 L 249.6875,321.875 z m 503.78125,55.8125 -50.90625,31.84375 C 726.31882,448.76688 740,494.78478 740,544 l 60,0 c 0,-60.90677 -16.99384,-117.84887 -46.53125,-166.3125 z m -588.75,111.25 C 161.61652,506.82573 160,525.2248 160,544 c 0,42.78463 8.42108,83.60181 23.65625,120.90625 L 238.84375,641.375 C 226.69144,611.30216 220,578.42944 220,544 c 0,-2.24366 0.0373,-4.48871 0.0937,-6.71875 0.3211,-12.67426 1.55282,-25.12039 3.625,-37.28125 l -59,-11.0625 z M 242.75,650.5 187.53125,674 c 23.4008,52.56805 60.5346,97.67196 106.875,130.71875 l 34.0625,-49.4375 C 291.42063,728.66516 261.6562,692.55546 242.75,650.5 z m 93.875,110.40625 -34.03125,49.40625 C 353.37348,844.20872 414.36502,864 480,864 l 0,-60 c -33.65485,0 -65.82451,-6.39115 -95.34375,-18.03125 -1.96795,-0.77601 -3.93088,-1.58396 -5.875,-2.40625 -14.80462,-6.26183 -28.90394,-13.88046 -42.15625,-22.65625 z`,id:`path4323-7`,"inkscape:connector-curvature":`0`})]),createBaseVNode(`radialGradient`,{"xlink:href":`#linearGradient4357`,id:`radialGradient4363-5`,cx:`480`,cy:`544`,fx:`480`,fy:`544`,r:`320`,gradientUnits:`userSpaceOnUse`,gradientTransform:`matrix(1.03125,0,0,1.03125,-15,-17)`}),createBaseVNode(`clipPath`,{clipPathUnits:`userSpaceOnUse`,id:`clipPath4407-6`},[createBaseVNode(`path`,{id:`path4409-1`,d:`m 480,-103.33 c -357.5105,0 -647.33,289.8195 -647.33,647.33 0,357.5105 289.8195,647.33 647.33,647.33 357.5105,0 647.33,-289.8195 647.33,-647.33 0,-357.5105 -289.8195,-647.33 -647.33,-647.33 z m 0,453.131 c 107.25316,0 194.199,86.94584 194.199,194.199 0,107.25316 -86.94584,194.199 -194.199,194.199 -107.25316,0 -194.199,-86.94584 -194.199,-194.199 0,-107.25316 86.94584,-194.199 194.199,-194.199 z`,style:{color:`#000000`,fill:`#ffffff`,"fill-opacity":`0.61375661`,"fill-rule":`nonzero`,stroke:`none`,"stroke-width":`16`,marker:`none`,visibility:`visible`,display:`inline`,overflow:`visible`,"enable-background":`accumulate`}})]),createBaseVNode(`radialGradient`,{gradientTransform:`matrix(0.36968813,0,0,0.36968813,1026.9451,-270.68256)`,"xlink:href":`#linearGradient4365`,id:`radialGradient4371-49`,cx:`480`,cy:`544`,fx:`480`,fy:`544`,r:`320`,gradientUnits:`userSpaceOnUse`}),createBaseVNode(`linearGradient`,{"xlink:href":`#linearGradient4256`,id:`linearGradient4746`,gradientUnits:`userSpaceOnUse`,x1:`569.20557`,y1:`424.29861`,x2:`890.55139`,y2:`424.29861`}),createBaseVNode(`clipPath`,{clipPathUnits:`userSpaceOnUse`,id:`clipPath3921`},[createBaseVNode(`path`,{"inkscape:connector-curvature":`0`,id:`path3923`,d:`m 480,224 c -20.95323,0 -41.43416,2.01857 -61.26367,5.86328 l 12.08008,58.80274 C 446.74495,285.61583 463.18224,284 480,284 c 36.22419,0 70.7135,7.41519 102.04492,20.79883 l 24.1836,-54.92188 C 567.49749,233.23259 524.82925,224 480,224 z m -67.13867,7.07812 c -60.69914,12.96113 -115.01734,43.12659 -157.60938,85.15821 l 42.54297,42.3125 c 34.42536,-33.82645 78.22177,-58.13556 127.14258,-68.68555 l -12.07617,-58.78516 z m 198.86328,21.20508 -24.1875,54.9336 c 45.44422,20.67199 83.88358,54.04459 110.80078,95.58008 l 50.87305,-31.84376 C 715.93577,319.29347 668.20331,277.82636 611.72461,252.2832 z m -360.70117,68.21094 c -42.37565,43.40627 -72.5223,98.80082 -84.8418,160.63281 l 58.99024,11.05664 c 10.06229,-49.7524 34.33605,-94.34359 68.39257,-129.3789 l -42.54101,-42.31055 z m 501.3789,55.54102 -50.86132,31.83398 C 725.92383,447.46544 740,494.08649 740,544 l 60,0 C 800,482.39079 782.57195,424.85952 752.40234,376.03516 z M 165.06055,487.02148 C 161.7373,505.51211 160,524.55271 160,544 c 0,43.47625 8.68492,84.91949 24.39062,122.71094 l 55.21485,-23.5293 C 226.98058,612.61583 220,579.12541 220,544 c 0,-15.6701 1.38639,-31.01527 4.04297,-45.92188 l -58.98242,-11.05664 z m 76.90039,161.67774 -55.20899,23.52734 c 23.61428,53.92719 61.65397,100.09134 109.25586,133.60352 l 34.03516,-49.41406 C 291.73258,729.3212 261.08736,692.12046 241.96094,648.69922 z m 93.01953,111.12695 -34.04102,49.42188 C 352.04051,843.81227 413.66249,864 480,864 l 0,-60 c -53.69777,0 -103.59151,-16.28243 -145.01953,-44.17383 z`,style:{color:`#000000`,fill:`#ffffff`,"fill-opacity":`1`,"fill-rule":`nonzero`,stroke:`none`,"stroke-width":`5`,marker:`none`,visibility:`visible`,display:`inline`,overflow:`visible`,"enable-background":`accumulate`}})]),createBaseVNode(`clipPath`,{clipPathUnits:`userSpaceOnUse`,id:`clipPath3925-1`},[createBaseVNode(`path`,{"inkscape:connector-curvature":`0`,id:`path3927-7`,d:`m 330,10 c -20.95323,0 -41.43416,2.01857 -61.26367,5.86328 l 12.08008,58.80274 C 296.74495,71.61583 313.18224,70 330,70 c 36.22419,0 70.7135,7.41519 102.04492,20.79883 l 24.1836,-54.92188 C 417.49749,19.23259 374.82925,10 330,10 z m -67.13867,7.07812 C 202.16219,30.03925 147.84399,60.20471 105.25195,102.23633 l 42.54297,42.3125 C 182.22028,110.72238 226.01669,86.41327 274.9375,75.86328 L 262.86133,17.07812 z m 198.86328,21.20508 -24.1875,54.9336 c 45.44422,20.67199 83.88358,54.04459 110.80078,95.58008 l 50.87305,-31.84376 C 565.93577,105.29347 518.20331,63.82636 461.72461,38.2832 z m -360.70117,68.21094 c -42.37565,43.40627 -72.5223,98.80082 -84.8418,160.63281 l 58.99024,11.05664 c 10.06229,-49.7524 34.33605,-94.34359 68.39257,-129.3789 l -42.54101,-42.31055 z m 501.3789,55.54102 -50.86132,31.83398 C 575.92383,233.46544 590,280.08649 590,330 l 60,0 C 650,268.39079 632.57195,210.85952 602.40234,162.03516 z M 15.06055,273.02148 C 11.7373,291.51211 10,310.55271 10,330 c 0,43.47625 8.68492,84.91949 24.39062,122.71094 l 55.21485,-23.5293 C 76.98058,398.61583 70,365.12541 70,330 c 0,-15.6701 1.38639,-31.01527 4.04297,-45.92188 L 15.06055,273.02148 z m 76.90039,161.67774 -55.20899,23.52734 c 23.61428,53.92719 61.65397,100.09134 109.25586,133.60352 l 34.03516,-49.41406 C 141.73258,515.3212 111.08736,478.12046 91.96094,434.69922 z m 93.01953,111.12695 -34.04102,49.42188 C 202.04051,629.81227 263.66249,650 330,650 l 0,-60 c -53.69777,0 -103.59151,-16.28243 -145.01953,-44.17383 z`,style:{color:`#000000`,fill:`#ffffff`,"fill-opacity":`1`,"fill-rule":`nonzero`,stroke:`none`,"stroke-width":`5`,marker:`none`,visibility:`visible`,display:`inline`,overflow:`visible`,"enable-background":`accumulate`}})]),createBaseVNode(`clipPath`,{clipPathUnits:`userSpaceOnUse`,id:`clipPath4036`},[createBaseVNode(`path`,{style:{color:`#000000`,fill:`#ffffff`,"fill-opacity":`1`,"fill-rule":`nonzero`,stroke:`none`,"stroke-width":`5`,marker:`none`,visibility:`visible`,display:`inline`,overflow:`visible`,"enable-background":`accumulate`},d:`m 480,224 c -20.95323,0 -41.43416,2.01857 -61.26367,5.86328 l 12.08008,58.80274 C 446.74495,285.61583 463.18224,284 480,284 c 36.22419,0 70.7135,7.41519 102.04492,20.79883 l 24.1836,-54.92188 C 567.49749,233.23259 524.82925,224 480,224 z m -67.13867,7.07812 c -60.69914,12.96113 -115.01734,43.12659 -157.60938,85.15821 l 42.54297,42.3125 c 34.42536,-33.82645 78.22177,-58.13556 127.14258,-68.68555 l -12.07617,-58.78516 z m 198.86328,21.20508 -24.1875,54.9336 c 45.44422,20.67199 83.88358,54.04459 110.80078,95.58008 l 50.87305,-31.84376 C 715.93577,319.29347 668.20331,277.82636 611.72461,252.2832 z m -360.70117,68.21094 c -42.37565,43.40627 -72.5223,98.80082 -84.8418,160.63281 l 58.99024,11.05664 c 10.06229,-49.7524 34.33605,-94.34359 68.39257,-129.3789 l -42.54101,-42.31055 z m 501.3789,55.54102 -50.86132,31.83398 C 725.92383,447.46544 740,494.08649 740,544 l 60,0 C 800,482.39079 782.57195,424.85952 752.40234,376.03516 z M 165.06055,487.02148 C 161.7373,505.51211 160,524.55271 160,544 c 0,43.47625 8.68492,84.91949 24.39062,122.71094 l 55.21485,-23.5293 C 226.98058,612.61583 220,579.12541 220,544 c 0,-15.6701 1.38639,-31.01527 4.04297,-45.92188 l -58.98242,-11.05664 z m 76.90039,161.67774 -55.20899,23.52734 c 23.61428,53.92719 61.65397,100.09134 109.25586,133.60352 l 34.03516,-49.41406 C 291.73258,729.3212 261.08736,692.12046 241.96094,648.69922 z m 93.01953,111.12695 -34.04102,49.42188 C 352.04051,843.81227 413.66249,864 480,864 l 0,-60 c -53.69777,0 -103.59151,-16.28243 -145.01953,-44.17383 z`,id:`path4038`,"inkscape:connector-curvature":`0`})]),createBaseVNode(`linearGradient`,{"inkscape:collect":`always`,"xlink:href":`#linearGradient4545`,id:`linearGradient4551`,x1:`480`,y1:`214`,x2:`480`,y2:`474`,gradientUnits:`userSpaceOnUse`}),createBaseVNode(`linearGradient`,{"inkscape:collect":`always`,"xlink:href":`#linearGradient4545-2`,id:`linearGradient4551-8`,x1:`480`,y1:`214`,x2:`480`,y2:`474`,gradientUnits:`userSpaceOnUse`}),createBaseVNode(`linearGradient`,{id:`linearGradient4545-2`},[createBaseVNode(`stop`,{style:{"stop-color":`#e40000`,"stop-opacity":`1`},offset:`0`,id:`stop4547-4`}),createBaseVNode(`stop`,{id:`stop4553-5`,offset:`0.99000001`,style:{"stop-color":`#e40000`,"stop-opacity":`0`}}),createBaseVNode(`stop`,{style:{"stop-color":`#000000`,"stop-opacity":`0`},offset:`1`,id:`stop4555-5`}),createBaseVNode(`stop`,{style:{"stop-color":`#000000`,"stop-opacity":`0`},offset:`1`,id:`stop4549-1`})]),createBaseVNode(`linearGradient`,{y2:`282.59341`,x2:`474.60886`,y1:`211.1199`,x1:`480`,gradientUnits:`userSpaceOnUse`,id:`linearGradient4574`,"xlink:href":`#linearGradient4607`,"inkscape:collect":`always`,gradientTransform:`matrix(1,0,0,0.9882541,0,10.359887)`}),createBaseVNode(`clipPath`,{clipPathUnits:`userSpaceOnUse`,id:`clipPath4036-1`},[createBaseVNode(`path`,{style:{color:`#000000`,fill:`#ffffff`,"fill-opacity":`1`,"fill-rule":`nonzero`,stroke:`none`,"stroke-width":`5`,marker:`none`,visibility:`visible`,display:`inline`,overflow:`visible`,"enable-background":`accumulate`},d:`m 480,224 c -20.95323,0 -41.43416,2.01857 -61.26367,5.86328 l 12.08008,58.80274 C 446.74495,285.61583 463.18224,284 480,284 c 36.22419,0 70.7135,7.41519 102.04492,20.79883 l 24.1836,-54.92188 C 567.49749,233.23259 524.82925,224 480,224 z m -67.13867,7.07812 c -60.69914,12.96113 -115.01734,43.12659 -157.60938,85.15821 l 42.54297,42.3125 c 34.42536,-33.82645 78.22177,-58.13556 127.14258,-68.68555 l -12.07617,-58.78516 z m 198.86328,21.20508 -24.1875,54.9336 c 45.44422,20.67199 83.88358,54.04459 110.80078,95.58008 l 50.87305,-31.84376 C 715.93577,319.29347 668.20331,277.82636 611.72461,252.2832 z m -360.70117,68.21094 c -42.37565,43.40627 -72.5223,98.80082 -84.8418,160.63281 l 58.99024,11.05664 c 10.06229,-49.7524 34.33605,-94.34359 68.39257,-129.3789 l -42.54101,-42.31055 z m 501.3789,55.54102 -50.86132,31.83398 C 725.92383,447.46544 740,494.08649 740,544 l 60,0 C 800,482.39079 782.57195,424.85952 752.40234,376.03516 z M 165.06055,487.02148 C 161.7373,505.51211 160,524.55271 160,544 c 0,43.47625 8.68492,84.91949 24.39062,122.71094 l 55.21485,-23.5293 C 226.98058,612.61583 220,579.12541 220,544 c 0,-15.6701 1.38639,-31.01527 4.04297,-45.92188 l -58.98242,-11.05664 z m 76.90039,161.67774 -55.20899,23.52734 c 23.61428,53.92719 61.65397,100.09134 109.25586,133.60352 l 34.03516,-49.41406 C 291.73258,729.3212 261.08736,692.12046 241.96094,648.69922 z m 93.01953,111.12695 -34.04102,49.42188 C 352.04051,843.81227 413.66249,864 480,864 l 0,-60 c -53.69777,0 -103.59151,-16.28243 -145.01953,-44.17383 z`,id:`path4038-7`,"inkscape:connector-curvature":`0`})]),createBaseVNode(`radialGradient`,{"xlink:href":`#linearGradient4357-0`,id:`radialGradient4363-4`,cx:`480`,cy:`544`,fx:`480`,fy:`544`,r:`320`,gradientUnits:`userSpaceOnUse`,gradientTransform:`matrix(1.03125,0,0,1.03125,-15,-17)`}),createBaseVNode(`linearGradient`,{id:`linearGradient4357-0`},[createBaseVNode(`stop`,{style:{"stop-color":`#000000`,"stop-opacity":`0.65178573`},offset:`0`,id:`stop4359-9`}),createBaseVNode(`stop`,{style:{"stop-color":`#000000`,"stop-opacity":`0.24107143`},offset:`1`,id:`stop4361-4`})]),createBaseVNode(`clipPath`,{clipPathUnits:`userSpaceOnUse`,id:`clipPath4407-8`},[createBaseVNode(`path`,{id:`path4409-8`,d:`m 480,-103.33 c -357.5105,0 -647.33,289.8195 -647.33,647.33 0,357.5105 289.8195,647.33 647.33,647.33 357.5105,0 647.33,-289.8195 647.33,-647.33 0,-357.5105 -289.8195,-647.33 -647.33,-647.33 z m 0,453.131 c 107.25316,0 194.199,86.94584 194.199,194.199 0,107.25316 -86.94584,194.199 -194.199,194.199 -107.25316,0 -194.199,-86.94584 -194.199,-194.199 0,-107.25316 86.94584,-194.199 194.199,-194.199 z`,style:{color:`#000000`,fill:`#ffffff`,"fill-opacity":`0.61375661`,"fill-rule":`nonzero`,stroke:`none`,"stroke-width":`16`,marker:`none`,visibility:`visible`,display:`inline`,overflow:`visible`,"enable-background":`accumulate`}})]),createBaseVNode(`radialGradient`,{"xlink:href":`#linearGradient4365-4`,id:`radialGradient4371-2`,cx:`480`,cy:`544`,fx:`480`,fy:`544`,r:`320`,gradientUnits:`userSpaceOnUse`}),createBaseVNode(`linearGradient`,{id:`linearGradient4365-4`},[createBaseVNode(`stop`,{style:{"stop-color":`#000000`,"stop-opacity":`0.42857143`},offset:`0`,id:`stop4367-5`}),createBaseVNode(`stop`,{id:`stop4373-5`,offset:`0.5`,style:{"stop-color":`#000000`,"stop-opacity":`0.33035713`}}),createBaseVNode(`stop`,{style:{"stop-color":`#000000`,"stop-opacity":`0`},offset:`1`,id:`stop4369-1`})]),createBaseVNode(`radialGradient`,{r:`320`,fy:`544`,fx:`480`,cy:`544`,cx:`480`,gradientUnits:`userSpaceOnUse`,id:`radialGradient3997`,"xlink:href":`#linearGradient4365-4`}),createBaseVNode(`radialGradient`,{"xlink:href":`#linearGradient4357-0-7`,id:`radialGradient4363-4-1`,cx:`480`,cy:`544`,fx:`480`,fy:`544`,r:`320`,gradientUnits:`userSpaceOnUse`,gradientTransform:`matrix(1.03125,0,0,1.03125,-15,-17)`}),createBaseVNode(`linearGradient`,{id:`linearGradient4357-0-7`},[createBaseVNode(`stop`,{style:{"stop-color":`#000000`,"stop-opacity":`0.51785713`},offset:`0`,id:`stop4359-9-4`}),createBaseVNode(`stop`,{style:{"stop-color":`#000000`,"stop-opacity":`0.11607143`},offset:`1`,id:`stop4361-4-0`})]),createBaseVNode(`radialGradient`,{r:`320`,fy:`544`,fx:`480`,cy:`544`,cx:`480`,gradientTransform:`matrix(1.03125,0,0,1.03125,-15,-17)`,gradientUnits:`userSpaceOnUse`,id:`radialGradient4001`,"xlink:href":`#linearGradient4357-0-7`}),createBaseVNode(`radialGradient`,{"xlink:href":`#linearGradient4357-0-7`,id:`radialGradient4040`,gradientUnits:`userSpaceOnUse`,gradientTransform:`matrix(1.03125,0,0,1.03125,-885,-231)`,cx:`480`,cy:`544`,fx:`480`,fy:`544`,r:`320`}),createBaseVNode(`radialGradient`,{"xlink:href":`#linearGradient4357-0-7`,id:`radialGradient4045`,gradientUnits:`userSpaceOnUse`,gradientTransform:`matrix(1.03125,0,0,1.03125,-885,-231)`,cx:`480`,cy:`544`,fx:`480`,fy:`544`,r:`320`}),createBaseVNode(`radialGradient`,{"inkscape:collect":`always`,"xlink:href":`#linearGradient4357-0-7-2`,id:`radialGradient4045-8`,gradientUnits:`userSpaceOnUse`,gradientTransform:`matrix(1.03125,0,0,1.03125,-885,-231)`,cx:`480`,cy:`544`,fx:`480`,fy:`544`,r:`320`}),createBaseVNode(`linearGradient`,{id:`linearGradient4357-0-7-2`},[createBaseVNode(`stop`,{style:{"stop-color":`#000000`,"stop-opacity":`0.51785713`},offset:`0`,id:`stop4359-9-4-4`}),createBaseVNode(`stop`,{style:{"stop-color":`#000000`,"stop-opacity":`0.11607143`},offset:`1`,id:`stop4361-4-0-5`})]),createBaseVNode(`radialGradient`,{r:`320`,fy:`544`,fx:`480`,cy:`544`,cx:`480`,gradientTransform:`matrix(1.03125,0,0,1.03125,-758.53125,-231)`,gradientUnits:`userSpaceOnUse`,id:`radialGradient4063`,"xlink:href":`#linearGradient4357-0-7-2`,"inkscape:collect":`always`}),createBaseVNode(`radialGradient`,{"inkscape:collect":`always`,"xlink:href":`#linearGradient4357-0-7`,id:`radialGradient4082`,gradientUnits:`userSpaceOnUse`,gradientTransform:`matrix(1.03125,0,0,1.03125,-885,-231)`,cx:`480`,cy:`544`,fx:`480`,fy:`544`,r:`320`}),createBaseVNode(`radialGradient`,{"inkscape:collect":`always`,"xlink:href":`#linearGradient4357-0-8`,id:`radialGradient4363-4-9`,cx:`480`,cy:`544`,fx:`480`,fy:`544`,r:`320`,gradientUnits:`userSpaceOnUse`,gradientTransform:`matrix(1.03125,0,0,1.03125,-15,-17)`}),createBaseVNode(`linearGradient`,{id:`linearGradient4357-0-8`},[createBaseVNode(`stop`,{style:{"stop-color":`#000000`,"stop-opacity":`0.51785713`},offset:`0`,id:`stop4359-9-40`}),createBaseVNode(`stop`,{style:{"stop-color":`#000000`,"stop-opacity":`0.11607143`},offset:`1`,id:`stop4361-4-7`})]),createBaseVNode(`radialGradient`,{r:`320`,fy:`544`,fx:`480`,cy:`544`,cx:`480`,gradientTransform:`matrix(1.03125,0,0,1.03125,-15,-17)`,gradientUnits:`userSpaceOnUse`,id:`radialGradient4031-1`,"xlink:href":`#linearGradient4357-0-8-5`,"inkscape:collect":`always`}),createBaseVNode(`linearGradient`,{id:`linearGradient4357-0-8-5`},[createBaseVNode(`stop`,{style:{"stop-color":`#000000`,"stop-opacity":`0.51785713`},offset:`0`,id:`stop4359-9-40-4`}),createBaseVNode(`stop`,{style:{"stop-color":`#000000`,"stop-opacity":`0.11607143`},offset:`1`,id:`stop4361-4-7-2`})]),createBaseVNode(`radialGradient`,{"inkscape:collect":`always`,"xlink:href":`#linearGradient4357-0-3`,id:`radialGradient4363-4-0`,cx:`480`,cy:`544`,fx:`480`,fy:`544`,r:`320`,gradientUnits:`userSpaceOnUse`,gradientTransform:`matrix(1.03125,0,0,1.03125,-15,-17)`}),createBaseVNode(`linearGradient`,{id:`linearGradient4357-0-3`},[createBaseVNode(`stop`,{style:{"stop-color":`#000000`,"stop-opacity":`0.65178573`},offset:`0`,id:`stop4359-9-8`}),createBaseVNode(`stop`,{style:{"stop-color":`#000000`,"stop-opacity":`0.24107143`},offset:`1`,id:`stop4361-4-01`})]),createBaseVNode(`clipPath`,{clipPathUnits:`userSpaceOnUse`,id:`clipPath4407-8-2`},[createBaseVNode(`path`,{"inkscape:connector-curvature":`0`,id:`path4409-8-5`,d:`m 480,-103.33 c -357.5105,0 -647.33,289.8195 -647.33,647.33 0,357.5105 289.8195,647.33 647.33,647.33 357.5105,0 647.33,-289.8195 647.33,-647.33 0,-357.5105 -289.8195,-647.33 -647.33,-647.33 z m 0,453.131 c 107.25316,0 194.199,86.94584 194.199,194.199 0,107.25316 -86.94584,194.199 -194.199,194.199 -107.25316,0 -194.199,-86.94584 -194.199,-194.199 0,-107.25316 86.94584,-194.199 194.199,-194.199 z`,style:{color:`#000000`,fill:`#ffffff`,"fill-opacity":`0.61375661`,"fill-rule":`nonzero`,stroke:`none`,"stroke-width":`16`,marker:`none`,visibility:`visible`,display:`inline`,overflow:`visible`,"enable-background":`accumulate`}})]),createBaseVNode(`radialGradient`,{r:`320`,fy:`544`,fx:`480`,cy:`544`,cx:`480`,gradientTransform:`matrix(1.03125,0,0,1.03125,-15,-17)`,gradientUnits:`userSpaceOnUse`,id:`radialGradient4401`,"xlink:href":`#linearGradient4357-0-3`,"inkscape:collect":`always`}),createBaseVNode(`radialGradient`,{r:`320`,fy:`544`,fx:`480`,cy:`544`,cx:`480`,gradientUnits:`userSpaceOnUse`,id:`radialGradient3997-4`,"xlink:href":`#linearGradient4365-4-7`,"inkscape:collect":`always`}),createBaseVNode(`linearGradient`,{id:`linearGradient4365-4-7`},[createBaseVNode(`stop`,{style:{"stop-color":`#000000`,"stop-opacity":`0.42857143`},offset:`0`,id:`stop4367-5-8`}),createBaseVNode(`stop`,{id:`stop4373-5-3`,offset:`0.5`,style:{"stop-color":`#000000`,"stop-opacity":`0.33035713`}}),createBaseVNode(`stop`,{style:{"stop-color":`#000000`,"stop-opacity":`0`},offset:`1`,id:`stop4369-1-5`})]),createBaseVNode(`radialGradient`,{r:`320`,fy:`544`,fx:`480`,cy:`544`,cx:`480`,gradientUnits:`userSpaceOnUse`,id:`radialGradient4458`,"xlink:href":`#linearGradient4365-4-7`,"inkscape:collect":`always`}),createBaseVNode(`clipPath`,{clipPathUnits:`userSpaceOnUse`,id:`clipPath4710`},[createBaseVNode(`path`,{style:{color:`#000000`,"font-style":`normal`,"font-variant":`normal`,"font-weight":`normal`,"font-stretch":`normal`,"font-size":`medium`,"line-height":`normal`,"font-family":`sans-serif`,"text-indent":`0`,"text-align":`start`,"text-decoration":`none`,"text-decoration-line":`none`,"text-decoration-style":`solid`,"text-decoration-color":`#000000`,"letter-spacing":`normal`,"word-spacing":`normal`,"text-transform":`none`,direction:`ltr`,"block-progression":`tb`,"writing-mode":`lr-tb`,"baseline-shift":`baseline`,"text-anchor":`start`,"white-space":`normal`,"clip-rule":`nonzero`,display:`inline`,overflow:`visible`,visibility:`visible`,opacity:`1`,isolation:`auto`,"mix-blend-mode":`normal`,"color-interpolation":`sRGB`,"color-interpolation-filters":`linearRGB`,"solid-color":`#000000`,"solid-opacity":`1`,fill:`#000000`,"fill-opacity":`1`,"fill-rule":`nonzero`,stroke:`none`,"stroke-width":`66.66205597`,"stroke-linecap":`butt`,"stroke-linejoin":`miter`,"stroke-miterlimit":`0.40000001`,"stroke-dasharray":`none`,"stroke-dashoffset":`0`,"stroke-opacity":`1`,"color-rendering":`auto`,"image-rendering":`auto`,"shape-rendering":`auto`,"text-rendering":`auto`,"enable-background":`accumulate`},d:`m 480,224 c -176.33633,0 -320,143.66367 -320,320 0,176.33633 143.66368,320 320,320 l 0,-66.66211 C 339.69052,797.33789 226.66211,684.30947 226.66211,544 226.66211,403.69051 339.69051,290.66211 480,290.66211 620.30948,290.66211 733.33789,403.69052 733.33789,544 L 800,544 C 800,367.66368 656.33632,224 480,224 Z`,id:`path4712`,"inkscape:connector-curvature":`0`})])],-1),createBaseVNode(`g`,{ref_key:`layer6Ref`,ref:layer6Ref,id:`layer6`,class:`layer6`},[_cache[1]||=createBaseVNode(`circle`,{transform:`translate(-150,-214)`,id:`path4281-5`,class:`circle1`,cx:`480`,cy:`544`,r:`320`,d:`M 800,544 C 800,720.73112 656.73112,864 480,864 303.26888,864 160,720.73112 160,544 160,367.26888 303.26888,224 480,224 c 176.73112,0 320,143.26888 320,320 z`},null,-1),_cache[2]||=createBaseVNode(`path`,{transform:`translate(-150,-214)`,id:`path4281`,class:`path1`,d:`M 480,214 C 297.74603,214 150,361.74603 150,544 150,726.25397 297.74603,874 480,874 662.25397,874 810,726.25397 810,544 810,361.74603 662.25397,214 480,214 z`,"clip-path":`url(#clipPath4407-8)`},null,-1),createBaseVNode(`text`,_hoisted_2$132,[createBaseVNode(`tspan`,{ref_key:`speedTextRef`,ref:speedTextRef,id:`tacho2speed`,class:`tacho2-speed`,x:`329.88641`,y:`289.30463`},`0`,512)]),createBaseVNode(`text`,_hoisted_3$118,[createBaseVNode(`tspan`,{ref_key:`speedUnitTextRef`,ref:speedUnitTextRef,id:`speedunit`,x:`330`,y:`348`},`mph`,512)]),createBaseVNode(`text`,_hoisted_4$96,[createBaseVNode(`tspan`,{ref_key:`gearTextRef`,ref:gearTextRef,id:`tacho2gear`,class:`text`,x:`386.67343`,y:`457.94861`},`4`,512)]),(openBlock(),createElementBlock(Fragment,null,renderList(maxRpmTexts,k=>createBaseVNode(`text`,{ref_for:!0,ref:el=>setRpmRef(el,k),"xml:space":`preserve`,x:`0`,y:`0`,class:`rpm-text`},[..._cache[0]||=[createBaseVNode(`tspan`,{x:`0`,y:`0`},null,-1)]],512)),64)),createBaseVNode(`text`,_hoisted_5$83,[createBaseVNode(`tspan`,{ref_key:`rpmLegendTextRef`,ref:rpmLegendTextRef,id:`tspan4449-3-1`,x:`330.09229`,y:`498.18045`},`x1000 RPM`,512)]),_cache[3]||=createBaseVNode(`path`,{"clip-path":`none`,id:`path4258`,class:`path-oil-fuel`,d:`M 462.44226,446.99523 C 489.99031,415.832 506.71155,374.86426 506.71155,330 c 0,-44.86426 -16.72124,-85.832 -44.26929,-116.99523 m -264.88452,0 C 170.00969,244.168 153.28845,285.13574 153.28845,330 c 0,44.86426 16.72124,85.832 44.26929,116.99523`},null,-1),createBaseVNode(`path`,{ref_key:`fuelBarRef`,ref:fuelBarRef,id:`fuel`,class:`fuel-bar`,d:`M 462.44226,446.99523 C 489.99031,415.832 506.71155,374.86426 506.71155,330 c 0,-44.86426 -16.72124,-85.832 -44.26929,-116.99523`},null,512),createBaseVNode(`path`,{ref_key:`oilTempBarRef`,ref:oilTempBarRef,id:`temp`,class:`oil-temp-bar`,d:`M 197.55774,213.00477 C 170.00969,244.168 153.28845,285.13574 153.28845,330 c 0,44.86426 16.72124,85.832 44.26929,116.99523`},null,512)],512),createBaseVNode(`g`,{ref_key:`layer3Ref`,ref:layer3Ref,id:`layer3`,class:`layer3`},[createBaseVNode(`g`,_hoisted_6$69,[_cache[4]||=createBaseVNode(`rect`,{y:`203.90677`,x:`141.28131`,height:`683.79401`,width:`683.79401`,id:`rect4001`,class:`layer3-rect`},null,-1),createBaseVNode(`path`,{ref_key:`revcurveRef`,ref:revcurveRef,class:`revcurve`,id:`revcurve`,"clip-path":`none`,d:`M 330,690 C 131.17749,690 -30,528.82251 -30,330 -30,131.17749 131.17749,-30 330,-30 c 198.82251,0 360,161.17749 360,360`,transform:`matrix(0.80555556,0,0,0.80555556,214.16667,278.16667)`},null,512),createBaseVNode(`path`,{ref_key:`redLineRef`,ref:redLineRef,class:`redline`,id:`rpm_redline`,d:`M 330,610 C 175.36027,610 50,484.63973 50,330 50,175.36027 175.36027,50 330,50 484.63973,50 610,175.36027 610,330`,transform:`matrix(1.038252,0,0,1.038252,137.37687,201.37687)`},null,512)])],512),createBaseVNode(`g`,{ref_key:`layer11Ref`,ref:layer11Ref,id:`layer11`,class:`layer11`},[createBaseVNode(`path`,{ref_key:`revcurveDashesRef`,ref:revcurveDashesRef,id:`revcurve_dashes`,class:`revcurve-dashes`,d:`M 330,616.66897 C 171.6771,616.66897 43.331027,488.3229 43.331027,330 43.331026,171.67709 171.67709,43.33103 330,43.331031 488.3229,43.331031 616.66897,171.6771 616.66897,330`},null,512),createBaseVNode(`path`,{ref_key:`rpmTextGuideLineRef`,ref:rpmTextGuideLineRef,id:`rpmtextline`,class:`rpm-textline`,d:`M 329,550 C 204.73594,550 104,449.26406 104,325 104,200.73593 204.73593,100 329,100 c 124.26406,0 225,100.73594 225,225`},null,512)],512),_cache[18]||=createBaseVNode(`g`,{id:`layer2`,style:{display:`none`}},[createBaseVNode(`g`,{style:{display:`inline`},id:`ico_handbrake_12343525ron`,transform:`translate(-4.2182737e-6,-2.0000051)`},[createBaseVNode(`path`,{transform:`matrix(0.43850147,2.6141077e-4,-2.6141077e-4,0.43850147,320.9902,18.916914)`,style:{display:`inline`,fill:`#ff7900`,"fill-opacity":`1`,stroke:`#ffffff`,"stroke-width":`12`,"stroke-miterlimit":`4`,"stroke-dasharray":`none`,"stroke-opacity":`1`},d:`m 631.44636,979.59082 a 65.760933,65.760933 0 0 1 -65.76094,65.76098 65.760933,65.760933 0 0 1 -65.76093,-65.76098 65.760933,65.760933 0 0 1 65.76093,-65.76093 65.760933,65.760933 0 0 1 65.76094,65.76093 z`,id:`path4551-2-7`}),createBaseVNode(`path`,{"sodipodi:nodetypes":`csc`,id:`path4551-7-7-3`,d:`m 546.9327,480.53664 c -10.16748,-6.97507 -16.83385,-18.68164 -16.82592,-31.94291 0.008,-13.00305 6.43054,-24.50375 16.27369,-31.51076`,style:{display:`inline`,fill:`none`,stroke:`#ffffff`,"stroke-width":`5.26201868`,"stroke-linecap":`round`,"stroke-linejoin":`round`,"stroke-miterlimit":`4`,"stroke-opacity":`1`}}),createBaseVNode(`path`,{"sodipodi:nodetypes":`csc`,id:`path4551-7-4-7-72`,d:`m 590.24076,480.56245 c 10.17587,-6.96293 16.8562,-18.66157 16.86414,-31.92282 0.008,-13.00303 -6.40141,-24.51142 -16.23624,-31.5301`,style:{display:`inline`,fill:`none`,stroke:`#ffffff`,"stroke-width":`5.26201868`,"stroke-linecap":`round`,"stroke-linejoin":`round`,"stroke-miterlimit":`4`,"stroke-opacity":`1`}}),createBaseVNode(`g`,{id:`flowRoot5902-7-4`,style:{"font-style":`normal`,"font-variant":`normal`,"font-weight":`bold`,"font-stretch":`normal`,"font-size":`55px`,"line-height":`125%`,"font-family":`'Open Sans'`,"-inkscape-font-specification":`'Open Sans Bold'`,"letter-spacing":`-3.45999861px`,"word-spacing":`0px`,display:`inline`,fill:`#ffffff`,"fill-opacity":`1`,stroke:`none`},transform:`matrix(0.43849858,-0.00161469,0.00161469,0.43849858,259.17408,95.334998)`},[createBaseVNode(`path`,{id:`path3978-3-5`,style:{"-inkscape-font-specification":`'Open Sans Bold'`},d:`m 548.35205,1001.1788 -2.84668,-9.34567 -14.31396,0 -2.84668,9.34567 -8.96973,0 13.85742,-39.4238 10.17822,0 13.91114,39.4238 z m -4.83398,-16.32809 c -2.63186,-8.4684 -4.11339,-13.25762 -4.44458,-14.36768 -0.33124,-1.10999 -0.56846,-1.98727 -0.71167,-2.63183 -0.59084,2.29169 -2.28274,7.95819 -5.07569,16.99951 z`}),createBaseVNode(`path`,{id:`path3980-3-4`,style:{"-inkscape-font-specification":`'Open Sans Bold'`},d:`m 558.77633,961.91614 12.21924,0 c 5.56801,4e-5 9.60975,0.79227 12.12524,2.37671 2.51543,1.5845 3.77316,4.10444 3.77319,7.55981 -3e-5,2.3454 -0.55056,4.27004 -1.65161,5.77393 -1.1011,1.50392 -2.56472,2.40806 -4.39087,2.7124 l 0,0.26855 c 2.48858,0.55504 4.28342,1.59345 5.38453,3.11524 1.10104,1.52182 1.65157,3.54493 1.65161,6.06933 -4e-5,3.58074 -1.29357,6.37371 -3.88062,8.37891 -2.5871,2.00518 -6.10069,3.00778 -10.54077,3.00778 l -14.68994,0 z m 8.32519,15.54931 4.83399,0 c 2.25584,3e-5 3.88954,-0.34909 4.90112,-1.04736 1.01153,-0.69822 1.51731,-1.853 1.51734,-3.46436 -3e-5,-1.50387 -0.55057,-2.58257 -1.65162,-3.23608 -1.10109,-0.65345 -2.84222,-0.98019 -5.22338,-0.98022 l -4.37745,0 z m 0,6.60645 0,10.23193 5.42481,0 c 2.29164,1e-5 3.98354,-0.43863 5.07568,-1.31592 1.0921,-0.87727 1.63816,-2.22004 1.63819,-4.02832 -3e-5,-3.25844 -2.3275,-4.88767 -6.98243,-4.88769 z`}),createBaseVNode(`path`,{id:`path3982-5-4`,style:{"-inkscape-font-specification":`'Open Sans Bold'`},d:`m 615.44572,990.27551 c -2e-5,3.54493 -1.27566,6.3379 -3.8269,8.37891 -2.55129,2.04098 -6.10069,3.06148 -10.64819,3.06148 -4.18947,0 -7.89552,-0.7877 -11.11817,-2.36324 l 0,-7.73437 c 2.64974,1.18164 4.89217,2.01416 6.7273,2.49755 1.83511,0.48341 3.51358,0.72511 5.0354,0.7251 1.82615,10e-6 3.22711,-0.34911 4.20288,-1.04736 0.97573,-0.69824 1.4636,-1.73665 1.46362,-3.11524 -2e-5,-0.76984 -0.21486,-1.45466 -0.64453,-2.05444 -0.42971,-0.59976 -1.06081,-1.17715 -1.89331,-1.73218 -0.83254,-0.555 -2.5289,-1.44123 -5.08911,-2.65869 -2.3991,-1.12791 -4.19841,-2.21108 -5.39795,-3.24951 -1.19955,-1.03839 -2.15739,-2.24689 -2.87354,-3.62549 -0.71614,-1.37855 -1.07422,-2.98988 -1.07421,-4.83398 -10e-6,-3.47328 1.17716,-6.20358 3.53149,-8.19092 2.35432,-1.98727 5.6083,-2.98092 9.76196,-2.98096 2.041,4e-5 3.98802,0.24174 5.84107,0.7251 1.853,0.48344 3.79107,1.16377 5.81421,2.04102 l -2.68555,6.47216 c -2.09475,-0.85934 -3.82693,-1.45911 -5.19653,-1.79931 -1.36965,-0.34014 -2.7169,-0.51022 -4.04175,-0.51026 -1.57554,4e-5 -2.78403,0.36706 -3.62549,1.10108 -0.84148,0.73408 -1.26222,1.69192 -1.26221,2.87353 -10e-6,0.73408 0.17008,1.37413 0.51026,1.92017 0.34015,0.54609 0.88174,1.07424 1.62475,1.58447 0.74299,0.51028 2.50202,1.42784 5.2771,2.75269 3.67023,1.75457 6.18569,3.51361 7.54639,5.2771 1.36065,1.76352 2.04099,3.92538 2.04101,6.48559 z`})]),createBaseVNode(`g`,{id:`flowRoot5902-7-5`,style:{"font-style":`normal`,"font-variant":`normal`,"font-weight":`bold`,"font-stretch":`normal`,"font-size":`55px`,"line-height":`125%`,"font-family":`'Open Sans'`,"-inkscape-font-specification":`'Open Sans Bold'`,"letter-spacing":`-3.45999861px`,"word-spacing":`0px`,display:`inline`,fill:`#ffffff`,"fill-opacity":`1`,stroke:`none`},transform:`matrix(0.43849858,-0.00161469,0.00161469,0.43849858,317.47869,20.439182)`},[createBaseVNode(`g`,{transform:`matrix(0.99999322,0.00368229,-0.00368229,0.99999322,0,0)`,style:{"font-style":`normal`,"font-weight":`normal`,"font-size":`94.63018036px`,"line-height":`125%`,"font-family":`sans-serif`,"letter-spacing":`0px`,"word-spacing":`0px`,fill:`#ffffff`,"fill-opacity":`1`,stroke:`none`,"stroke-width":`1px`,"stroke-linecap":`butt`,"stroke-linejoin":`miter`,"stroke-opacity":`1`},id:`text4455`},[createBaseVNode(`path`,{d:`m 607.02483,962.46092 q 0,4.62062 -1.61722,9.05641 -1.61721,4.38958 -4.62061,7.39298 -4.11235,4.06614 -9.19502,6.14542 -5.03647,2.07927 -12.56807,2.07927 l -11.04327,0 0,22.41 -17.74316,0 0,-68.80096 29.20228,0 q 6.56127,0 11.04327,1.15515 4.5282,1.10895 7.99366,3.37305 4.15856,2.72616 6.33024,6.97713 2.2179,4.25096 2.2179,10.21155 z m -18.34384,0.41586 q 0,-2.91099 -1.57101,-4.99026 -1.57101,-2.12549 -3.65028,-2.9572 -2.77237,-1.10895 -5.40612,-1.20136 -2.63375,-0.13862 -7.02334,-0.13862 l -3.0496,0 0,20.60794 5.08267,0 q 4.52821,0 7.43919,-0.55447 2.9572,-0.55447 4.94406,-2.21789 1.70963,-1.4786 2.44893,-3.51167 0.7855,-2.07928 0.7855,-5.03647 z`,style:{"font-style":`normal`,"font-variant":`normal`,"font-weight":`bold`,"font-stretch":`normal`,"font-size":`94.63018036px`,"line-height":`125%`,"font-family":`'Open Sans Extrabold'`,"-inkscape-font-specification":`'Open Sans Extrabold, Bold'`,"text-align":`start`,"writing-mode":`lr-tb`,"text-anchor":`start`,fill:`#ffffff`,"fill-opacity":`1`},id:`path4527`,"inkscape:connector-curvature":`0`})]),createBaseVNode(`path`,{transform:`matrix(0.99999322,0.00368229,-0.00368229,0.99999322,0,0)`,style:{fill:`none`,"fill-opacity":`1`,stroke:`#000000`,"stroke-width":`5.69782162`,"stroke-miterlimit":`4`,"stroke-dasharray":`none`,"stroke-opacity":`1`},d:`m 28.554777,1230.2663 c -137.847287,0 -270.048717,-54.7596 -367.521467,-152.2324 -97.47276,-97.47273 -152.23238,-229.67416 -152.23238,-367.52145 0,-137.84729 54.75963,-270.04871 152.23238,-367.52146 97.47275,-97.47276 229.67418,-152.23238 367.521467,-152.23238 137.847293,0 270.048713,54.75962 367.521463,152.23238 97.47275,97.47275 152.23238,229.67417 152.23238,367.52146 0,137.84729 -54.75962,270.04871 -152.23238,367.52145 -97.47275,97.4728 -229.67417,152.2324 -367.521463,152.2324`,id:`text_path`,"inkscape:connector-curvature":`0`,"sodipodi:nodetypes":`csssssssc`,"inkscape:label":`#path4459`})])])],-1),createBaseVNode(`g`,{ref_key:`layer7Ref`,ref:layer7Ref,"inkscape:groupmode":`layer`,id:`layer7`,class:`layer7`,"inkscape:label":`new2`},[createBaseVNode(`g`,{ref_key:`revNeedleRef`,ref:revNeedleRef,id:`revneedle`,"inkscape:label":`#g4147`},[..._cache[5]||=[createBaseVNode(`rect`,{y:`7`,x:`322.44037`,height:`72`,width:`12`,id:`rect4625`,class:`rev-needle-rect`},null,-1)]],512)],512),createBaseVNode(`g`,{ref_key:`layer4Ref`,ref:layer4Ref,"inkscape:groupmode":`layer`,id:`layer4`,class:`layer4`,"inkscape:label":`Icons bottom right`},[createBaseVNode(`path`,{ref_key:`icoIndicatorLeftOffRef`,ref:icoIndicatorLeftOffRef,id:`ico_indicatorl`,class:`ico-indicator-l`,d:`m 386.4512,577.16251 0.0556,17.08797 15.45962,0.24613 0,10.03868 0,10.03869 -15.45962,0.24608 -0.0556,17.08797 -35.33627,-27.37274 z`,"inkscape:connector-curvature":`0`,"sodipodi:nodetypes":`ccccccccc`,"inkscape:label":`#rect4655-9`},null,512),createBaseVNode(`path`,{ref_key:`icoIndicatorRightOffRef`,ref:icoIndicatorRightOffRef,id:`ico_indicatorr`,class:`ico-indicator-r`,d:`m 442.9256,554.57416 -0.0557,17.08798 -15.45965,0.24611 0,10.03869 0,10.03869 15.45965,0.24608 0.0557,17.08796 35.33627,-27.37273 z`,"inkscape:connector-curvature":`0`,"sodipodi:nodetypes":`ccccccccc`,"inkscape:label":`#rect4655-9-3`},null,512),createBaseVNode(`g`,{ref_key:`icoLightsOffRef`,ref:icoLightsOffRef,id:`ico_lights`,class:`ico-lights`,"inkscape:label":`#g4122`,transform:`translate(-12,-2)`},[..._cache[6]||=[createBaseVNode(`path`,{"inkscape:connector-curvature":`0`,id:`rect5824`,class:`light-source`,d:`m 611.67051,352.21188 19.61837,0 c 0,0 13.56687,7.61647 13.56687,22.35122 0,14.73475 -13.56687,21.08238 -13.56687,21.08238 l -19.61837,0 c 0,0 -1.90879,-4.49141 -1.95206,-21.08238 -0.0435,-16.59097 1.95206,-22.35122 1.95206,-22.35122 z`},null,-1),createBaseVNode(`path`,{class:`light-dash`,"inkscape:connector-curvature":`0`,d:`m 600.68152,355.88611 -13.21963,0`},null,-1),createBaseVNode(`path`,{class:`light-dash`,"inkscape:connector-curvature":`0`,d:`m 600.68152,365.4103 -13.21963,0`},null,-1),createBaseVNode(`path`,{class:`light-dash`,"inkscape:connector-curvature":`0`,d:`m 600.68152,374.58946 -13.21963,0`},null,-1),createBaseVNode(`path`,{class:`light-dash`,"inkscape:connector-curvature":`0`,d:`m 600.68152,384.11369 -13.21963,0`},null,-1),createBaseVNode(`path`,{class:`light-dash`,"inkscape:connector-curvature":`0`,d:`m 600.68152,393.43089 -13.21963,0`},null,-1)]],512),createBaseVNode(`g`,{ref_key:`icoABSOffRef`,ref:icoABSOffRef,id:`ico_abs`,class:`ico-abs-off`,"inkscape:label":`#g4111`},[..._cache[7]||=[createBaseVNode(`path`,{transform:`matrix(0.43849858,-0.00161469,0.00161469,0.43849858,260.26675,95.346428)`,id:`path4551dd`,class:`main`,d:`m 631.44636,979.59082 c 0,36.31878 -29.44217,65.76098 -65.76094,65.76098 -36.31876,0 -65.76093,-29.4422 -65.76093,-65.76098 0,-36.31876 29.44217,-65.76093 65.76093,-65.76093 36.31877,0 65.76094,29.44217 65.76094,65.76093 z`,"inkscape:connector-curvature":`0`},null,-1),createBaseVNode(`path`,{"inkscape:connector-curvature":`0`,id:`path4551-7`,class:`curve-l`,d:`m 488.18221,555.99526 c -10.19731,-6.9315 -16.91369,-18.60946 -16.96251,-31.87062 -0.0478,-13.00297 6.32573,-24.53106 16.1388,-31.5801`},null,-1),createBaseVNode(`path`,{"inkscape:connector-curvature":`0`,id:`path4551-7-4`,class:`curve-r`,d:`m 531.48996,555.83579 c 10.14597,-7.00643 16.77617,-18.73351 16.72734,-31.99467 -0.0478,-13.00299 -6.50623,-24.48382 -16.37094,-31.4604`},null,-1),createBaseVNode(`path`,{"inkscape:connector-curvature":`0`,id:`path3978`,class:`text-a`,d:`m 501.24227,531.46506 -1.26336,-4.09346 -6.27665,0.0231 -1.23317,4.10266 -3.93322,0.0145 6.01281,-17.30965 4.46313,-0.0164 6.16367,17.26482 z m -2.14606,-7.15204 c -1.16774,-3.70913 -1.82512,-5.8068 -1.97214,-6.29303 -0.14704,-0.48619 -0.25248,-0.87049 -0.31632,-1.1529 -0.25538,1.00586 -0.98812,3.49334 -2.19823,7.46246 z`},null,-1),createBaseVNode(`path`,{"inkscape:connector-curvature":`0`,id:`path3980`,class:`text-b`,d:`m 505.7499,514.23161 5.35812,-0.0197 c 2.44157,-0.009 4.21514,0.33189 5.32074,1.02261 1.10557,0.69074 1.66115,1.79369 1.66675,3.30887 0.004,1.02845 -0.23453,1.87329 -0.71491,2.53453 -0.4804,0.66124 -1.12074,1.06007 -1.92101,1.19647 l 4.3e-4,0.11776 c 1.09214,0.23936 1.88085,0.69181 2.36614,1.35733 0.48526,0.66554 0.72994,1.55178 0.73403,2.65873 0.006,1.57015 -0.55694,2.79695 -1.68812,3.6804 -1.1312,0.88345 -2.67028,1.32876 -4.61725,1.33593 l -6.44152,0.0237 z m 3.67569,6.80491 2.1197,-0.008 c 0.98919,-0.004 1.705,-0.15935 2.14745,-0.46718 0.44242,-0.3078 0.66234,-0.81498 0.65975,-1.52156 -0.002,-0.65945 -0.24559,-1.13157 -0.72946,-1.41635 -0.48388,-0.28476 -1.24789,-0.42523 -2.29202,-0.42139 l -1.91951,0.007 z m 0.0107,2.89692 0.0165,4.48668 2.37878,-0.009 c 1.00488,-0.004 1.74606,-0.19878 2.22355,-0.58523 0.47747,-0.38644 0.71474,-0.97613 0.71184,-1.76906 -0.005,-1.42882 -1.0285,-2.13948 -3.06968,-2.13197 z`},null,-1),createBaseVNode(`path`,{"inkscape:connector-curvature":`0`,id:`path3982`,class:`text-s`,d:`m 530.64514,526.57565 c 0.006,1.55445 -0.54914,2.78122 -1.66456,3.68032 -1.11544,0.89909 -2.6702,1.35231 -4.66427,1.35965 -1.83708,0.007 -3.46345,-0.33266 -4.87912,-1.01833 l -0.0125,-3.39151 c 1.16382,0.51387 2.14846,0.87531 2.95395,1.08431 0.80547,0.20901 1.54187,0.31229 2.20918,0.30983 0.80077,-0.003 1.41452,-0.1583 1.84127,-0.46605 0.42673,-0.30776 0.63898,-0.76389 0.63676,-1.3684 -10e-4,-0.33757 -0.0966,-0.63752 -0.28594,-0.89982 -0.18939,-0.2623 -0.46706,-0.51447 -0.83301,-0.75651 -0.36596,-0.24202 -1.11125,-0.62789 -2.23586,-1.15761 -1.05382,-0.49071 -1.84457,-0.96278 -2.37224,-1.41619 -0.52768,-0.4534 -0.94964,-0.98177 -1.2659,-1.58513 -0.31625,-0.60334 -0.47587,-1.30933 -0.47884,-2.11796 -0.006,-1.52303 0.50616,-2.72216 1.53533,-3.59741 1.02915,-0.87522 2.45441,-1.31619 4.27579,-1.32291 0.89497,-0.003 1.74913,0.0996 2.56247,0.30852 0.81332,0.209 1.66426,0.50419 2.55282,0.8856 l -1.16716,2.84237 c -0.91993,-0.37344 -1.68046,-0.63364 -2.28158,-0.7806 -0.60114,-0.14694 -1.19218,-0.21935 -1.77312,-0.21723 -0.69088,0.003 -1.2202,0.16545 -1.588,0.48868 -0.3678,0.32325 -0.55075,0.74394 -0.54884,1.26208 10e-4,0.32189 0.0768,0.60228 0.22685,0.84116 0.15004,0.23892 0.38838,0.46963 0.71501,0.69217 0.32663,0.22256 1.09944,0.62206 2.31845,1.19853 1.61222,0.76345 2.71809,1.53072 3.3176,2.30181 0.59949,0.77111 0.90131,1.71798 0.90545,2.84063 z`},null,-1)]],512),createBaseVNode(`g`,{ref_key:`icoHandBrakeOffRef`,ref:icoHandBrakeOffRef,class:`ico-handbrake-off`,id:`ico_handbrake`,"inkscape:label":`#g4115`,transform:`translate(-3.5925881e-6,-2.0000007)`},[..._cache[8]||=[createBaseVNode(`path`,{transform:`matrix(0.43850147,2.6141077e-4,-2.6141077e-4,0.43850147,320.9902,18.916914)`,id:`path4551-2-74-7`,class:`main`,d:`m 631.44636,979.59082 c 0,36.31878 -29.44217,65.76098 -65.76094,65.76098 -36.31876,0 -65.76093,-29.4422 -65.76093,-65.76098 0,-36.31876 29.44217,-65.76093 65.76093,-65.76093 36.31877,0 65.76094,29.44217 65.76094,65.76093 z`,"inkscape:connector-curvature":`0`},null,-1),createBaseVNode(`path`,{class:`curve-l`,id:`path4551-7-7-0-4`,"inkscape:connector-curvature":`0`,d:`m 546.9327,480.53664 c -10.16748,-6.97507 -16.83385,-18.68164 -16.82592,-31.94291 0.008,-13.00305 6.43054,-24.50375 16.27369,-31.51076`},null,-1),createBaseVNode(`path`,{"inkscape:connector-curvature":`0`,id:`path4551-7-4-7-9-0`,class:`curve-r`,d:`m 590.24076,480.56245 c 10.17587,-6.96293 16.8562,-18.66157 16.86414,-31.92282 0.008,-13.00303 -6.40141,-24.51142 -16.23624,-31.5301`},null,-1),createBaseVNode(`g`,{class:`text-p`,id:`text4055-4-9`},[createBaseVNode(`path`,{"inkscape:connector-curvature":`0`,id:`path3269-4`,d:`m 566.88168,447.27286 2.26429,0 c 2.11628,2e-5 3.6998,-0.41806 4.75057,-1.25424 1.05073,-0.83614 1.57611,-2.05338 1.57612,-3.65172 -10e-6,-1.6131 -0.44029,-2.80444 -1.32083,-3.57403 -0.88058,-0.76954 -2.26061,-1.15432 -4.1401,-1.15435 l -3.13005,0 z m 15.53925,-5.15015 c -3e-5,3.49265 -1.09147,6.16392 -3.27434,8.01381 -2.18292,1.84993 -5.28707,2.77488 -9.31245,2.77487 l -2.95246,0 0,11.54344 -6.88167,0 0,-32.45483 10.3669,0 c 3.93659,3e-5 6.92975,0.84729 8.97947,2.54177 2.04967,1.69455 3.07452,4.22153 3.07455,7.58094 z`})],-1)]],512),createBaseVNode(`g`,{ref_key:`oilTempIcoOffRef`,ref:oilTempIcoOffRef,style:{display:`inline`},id:`ico_temp`,class:`ico-temp`,transform:`matrix(0.82879177,0,0,0.82879177,40.706638,69.281349)`,"inkscape:label":`#g4374`},[..._cache[9]||=[createBaseVNode(`path`,{"inkscape:connector-curvature":`0`,id:`path4347`,class:`path1`,d:`m 199.61025,285.93078 2e-5,37.83129`},null,-1),createBaseVNode(`path`,{"inkscape:connector-curvature":`0`,id:`path4347-5`,class:`path2`,d:`m 208.85791,292.09588 -7.00577,0`},null,-1),createBaseVNode(`path`,{"inkscape:connector-curvature":`0`,id:`path4347-5-4`,class:`path3`,d:`m 208.8579,301.06329 -7.00578,0`},null,-1),createBaseVNode(`path`,{"inkscape:connector-curvature":`0`,id:`path4347-5-3`,class:`path4`,d:`m 208.85793,309.75049 -7.00583,-1e-5`},null,-1),createBaseVNode(`circle`,{transform:`matrix(0.72059621,0,0,0.72059621,-1146.435,-0.73321691)`,id:`path4392`,class:`path5`,cx:`1867.8225`,cy:`454.9176`,r:`14.849242`,d:`m 1882.6718,454.9176 c 0,8.20101 -6.6483,14.84924 -14.8493,14.84924 -8.201,0 -14.8492,-6.64823 -14.8492,-14.84924 0,-8.20101 6.6482,-14.84924 14.8492,-14.84924 8.201,0 14.8493,6.64823 14.8493,14.84924 z`},null,-1),createBaseVNode(`path`,{"inkscape:connector-curvature":`0`,id:`path4347-5-1-2`,class:`path6`,d:`m 183.69241,332.71741 -7.00578,0`},null,-1),createBaseVNode(`path`,{"inkscape:connector-curvature":`0`,id:`path4347-5-1-2-3`,class:`path7`,d:`m 223.32319,343.08941 -46.63658,-10e-6`},null,-1),createBaseVNode(`path`,{"inkscape:connector-curvature":`0`,id:`path4347-5-1-2-34`,class:`path8`,d:`m 222.33239,332.7174 -7.00578,0`},null,-1)]],512),createBaseVNode(`g`,{ref_key:`fuelWarnIcoOffRef`,ref:fuelWarnIcoOffRef,id:`ico_fuel`,class:`ico-fuel`,transform:`matrix(0.88747678,0,0,0.88747678,64.601263,56.302973)`,"inkscape:label":`#g4368`},[..._cache[10]||=[createBaseVNode(`rect`,{id:`rect4466`,class:`rect1`,y:`284.07593`,x:`420.99237`,height:`38.905876`,width:`22.650679`},null,-1),createBaseVNode(`rect`,{id:`rect4466-1`,class:`rect2`,y:`298.80991`,x:`420.99237`,height:`24.171896`,width:`22.650679`},null,-1),createBaseVNode(`path`,{"inkscape:connector-curvature":`0`,id:`path4347-5-1-2-3-3`,class:`path1`,d:`m 448.00445,330.93084 -30.96928,0`},null,-1),createBaseVNode(`path`,{"inkscape:connector-curvature":`0`,id:`path4347-5-1-2-3-3-8`,class:`path2`,d:`m 460.25266,299.90863 0.0166,18.02062 c 0,0 -0.41583,2.18743 -4.92393,2.16693 -4.50811,-0.0205 -4.80496,-2.16693 -4.80496,-2.16693 l 0.0579,-17.71243 -7.25174,-0.0941`},null,-1)]],512)],512),createBaseVNode(`g`,{ref_key:`layer10Ref`,ref:layer10Ref,"inkscape:groupmode":`layer`,id:`layer10`,class:`layer10`,"inkscape:label":`icons bottom right activated`},[createBaseVNode(`path`,{ref_key:`icoIndicatorLeftOnRef`,ref:icoIndicatorLeftOnRef,class:`ico-indicator-l-on`,d:`m 386.4512,577.16251 0.0556,17.08797 15.45962,0.24613 0,10.03868 0,10.03869 -15.45962,0.24608 -0.0556,17.08797 -35.33627,-27.37274 z`,id:`ico_indicatorl_on`,"inkscape:connector-curvature":`0`,"inkscape:label":`#rect4655-9`},null,512),createBaseVNode(`path`,{ref_key:`icoIndicatorRightOnRef`,ref:icoIndicatorRightOnRef,id:`ico_indicatorr_on`,class:`ico-indicator-r-on`,d:`m 442.9256,554.57416 -0.0557,17.08798 -15.45965,0.24611 0,10.03869 0,10.03869 15.45965,0.24608 0.0557,17.08796 35.33627,-27.37273 z`,"inkscape:connector-curvature":`0`,"inkscape:label":`#rect4655-9-3`},null,512),createBaseVNode(`g`,{ref_key:`icoLightsOnRef`,ref:icoLightsOnRef,id:`ico_lights_on`,class:`ico-lights-on`,"inkscape:label":`#g4122`,transform:`translate(-12,-2.0000028)`},[..._cache[11]||=[createBaseVNode(`path`,{"inkscape:connector-curvature":`0`,id:`rect5824-4`,class:`path1`,d:`m 611.67051,352.21188 19.61837,0 c 0,0 13.56687,7.61647 13.56687,22.35122 0,14.73475 -13.56687,21.08238 -13.56687,21.08238 l -19.61837,0 c 0,0 -1.90879,-4.49141 -1.95206,-21.08238 -0.0435,-16.59097 1.95206,-22.35122 1.95206,-22.35122 z`},null,-1),createBaseVNode(`path`,{"inkscape:connector-curvature":`0`,id:`path4347-5-1-2-3-1-1`,class:`path2`,d:`m 600.68152,355.88611 -13.21963,0`},null,-1),createBaseVNode(`path`,{"inkscape:connector-curvature":`0`,id:`path4347-5-1-2-3-1-9-20`,class:`path3`,d:`m 600.68152,365.4103 -13.21963,0`},null,-1),createBaseVNode(`path`,{"inkscape:connector-curvature":`0`,id:`path4347-5-1-2-3-1-8-0`,class:`path4`,d:`m 600.68152,374.58946 -13.21963,0`},null,-1),createBaseVNode(`path`,{"inkscape:connector-curvature":`0`,id:`path4347-5-1-2-3-1-9-6-1`,class:`path5`,d:`m 600.68152,384.11369 -13.21963,0`},null,-1),createBaseVNode(`path`,{"inkscape:connector-curvature":`0`,id:`path4347-5-1-2-3-1-9-6-5-4`,class:`path6`,d:`m 600.68152,393.43089 -13.21963,0`},null,-1)]],512),createBaseVNode(`g`,{ref_key:`icoABSOnRef`,ref:icoABSOnRef,transform:`translate(0,-2.8038025e-6)`,id:`ico_abs_on`,class:`ico-abs-on`,"inkscape:label":`#g4106`},[..._cache[12]||=[createBaseVNode(`path`,{id:`path4551-0`,class:`path1`,"inkscape:connector-curvature":`0`,transform:`matrix(0.43849858,-0.00161469,0.00161469,0.43849858,260.26675,95.34643)`,d:`m 631.44636,979.59082 c 0,36.31878 -29.44217,65.76098 -65.76094,65.76098 -36.31876,0 -65.76093,-29.4422 -65.76093,-65.76098 0,-36.31876 29.44217,-65.76093 65.76093,-65.76093 36.31877,0 65.76094,29.44217 65.76094,65.76093 z`},null,-1),createBaseVNode(`path`,{"inkscape:connector-curvature":`0`,id:`path4551-7-717`,class:`path2`,d:`m 488.18221,555.99526 c -10.19731,-6.9315 -16.91369,-18.60946 -16.96251,-31.87062 -0.0478,-13.00297 6.32573,-24.53106 16.1388,-31.5801`},null,-1),createBaseVNode(`path`,{"inkscape:connector-curvature":`0`,id:`path4551-7-4-77`,class:`path3`,d:`m 531.48996,555.83579 c 10.14597,-7.00643 16.77617,-18.73351 16.72734,-31.99467 -0.0478,-13.00299 -6.50623,-24.48382 -16.37094,-31.4604`},null,-1),createBaseVNode(`g`,{id:`flowRoot5902-7`,class:`text-path`,transform:`matrix(0.43849858,-0.00161469,0.00161469,0.43849858,259.17408,93.335)`},[createBaseVNode(`path`,{id:`path3978-3`,class:`text-path1`,"inkscape:connector-curvature":`0`,d:`m 548.35205,1001.1788 -2.84668,-9.34567 -14.31396,0 -2.84668,9.34567 -8.96973,0 13.85742,-39.4238 10.17822,0 13.91114,39.4238 z m -4.83398,-16.32809 c -2.63186,-8.4684 -4.11339,-13.25762 -4.44458,-14.36768 -0.33124,-1.10999 -0.56846,-1.98727 -0.71167,-2.63183 -0.59084,2.29169 -2.28274,7.95819 -5.07569,16.99951 z`}),createBaseVNode(`path`,{id:`path3980-3`,class:`text-path2`,"inkscape:connector-curvature":`0`,d:`m 558.77633,961.91614 12.21924,0 c 5.56801,4e-5 9.60975,0.79227 12.12524,2.37671 2.51543,1.5845 3.77316,4.10444 3.77319,7.55981 -3e-5,2.3454 -0.55056,4.27004 -1.65161,5.77393 -1.1011,1.50392 -2.56472,2.40806 -4.39087,2.7124 l 0,0.26855 c 2.48858,0.55504 4.28342,1.59345 5.38453,3.11524 1.10104,1.52182 1.65157,3.54493 1.65161,6.06933 -4e-5,3.58074 -1.29357,6.37371 -3.88062,8.37891 -2.5871,2.00518 -6.10069,3.00778 -10.54077,3.00778 l -14.68994,0 z m 8.32519,15.54931 4.83399,0 c 2.25584,3e-5 3.88954,-0.34909 4.90112,-1.04736 1.01153,-0.69822 1.51731,-1.853 1.51734,-3.46436 -3e-5,-1.50387 -0.55057,-2.58257 -1.65162,-3.23608 -1.10109,-0.65345 -2.84222,-0.98019 -5.22338,-0.98022 l -4.37745,0 z m 0,6.60645 0,10.23193 5.42481,0 c 2.29164,1e-5 3.98354,-0.43863 5.07568,-1.31592 1.0921,-0.87727 1.63816,-2.22004 1.63819,-4.02832 -3e-5,-3.25844 -2.3275,-4.88767 -6.98243,-4.88769 z`}),createBaseVNode(`path`,{id:`path3982-5`,class:`text-path3`,"inkscape:connector-curvature":`0`,d:`m 615.44572,990.27551 c -2e-5,3.54493 -1.27566,6.3379 -3.8269,8.37891 -2.55129,2.04098 -6.10069,3.06148 -10.64819,3.06148 -4.18947,0 -7.89552,-0.7877 -11.11817,-2.36324 l 0,-7.73437 c 2.64974,1.18164 4.89217,2.01416 6.7273,2.49755 1.83511,0.48341 3.51358,0.72511 5.0354,0.7251 1.82615,10e-6 3.22711,-0.34911 4.20288,-1.04736 0.97573,-0.69824 1.4636,-1.73665 1.46362,-3.11524 -2e-5,-0.76984 -0.21486,-1.45466 -0.64453,-2.05444 -0.42971,-0.59976 -1.06081,-1.17715 -1.89331,-1.73218 -0.83254,-0.555 -2.5289,-1.44123 -5.08911,-2.65869 -2.3991,-1.12791 -4.19841,-2.21108 -5.39795,-3.24951 -1.19955,-1.03839 -2.15739,-2.24689 -2.87354,-3.62549 -0.71614,-1.37855 -1.07422,-2.98988 -1.07421,-4.83398 -10e-6,-3.47328 1.17716,-6.20358 3.53149,-8.19092 2.35432,-1.98727 5.6083,-2.98092 9.76196,-2.98096 2.041,4e-5 3.98802,0.24174 5.84107,0.7251 1.853,0.48344 3.79107,1.16377 5.81421,2.04102 l -2.68555,6.47216 c -2.09475,-0.85934 -3.82693,-1.45911 -5.19653,-1.79931 -1.36965,-0.34014 -2.7169,-0.51022 -4.04175,-0.51026 -1.57554,4e-5 -2.78403,0.36706 -3.62549,1.10108 -0.84148,0.73408 -1.26222,1.69192 -1.26221,2.87353 -10e-6,0.73408 0.17008,1.37413 0.51026,1.92017 0.34015,0.54609 0.88174,1.07424 1.62475,1.58447 0.74299,0.51028 2.50202,1.42784 5.2771,2.75269 3.67023,1.75457 6.18569,3.51361 7.54639,5.2771 1.36065,1.76352 2.04099,3.92538 2.04101,6.48559 z`})],-1)]],512),createBaseVNode(`g`,{ref_key:`icoHandBrakeOnRef`,ref:icoHandBrakeOnRef,id:`ico_handbrake_on`,class:`ico-handbrake-on`,"inkscape:label":`#g4115`,transform:`translate(-3.5925881e-6,-2.0000007)`},[..._cache[13]||=[createBaseVNode(`path`,{id:`path4551-2-74`,class:`path1`,transform:`matrix(0.43850147,2.6141077e-4,-2.6141077e-4,0.43850147,320.9902,18.916914)`,d:`m 631.44636,979.59082 c 0,36.31878 -29.44217,65.76098 -65.76094,65.76098 -36.31876,0 -65.76093,-29.4422 -65.76093,-65.76098 0,-36.31876 29.44217,-65.76093 65.76093,-65.76093 36.31877,0 65.76094,29.44217 65.76094,65.76093 z`,"inkscape:connector-curvature":`0`},null,-1),createBaseVNode(`path`,{"inkscape:connector-curvature":`0`,id:`path4551-7-7-0`,class:`path2`,d:`m 546.9327,480.53664 c -10.16748,-6.97507 -16.83385,-18.68164 -16.82592,-31.94291 0.008,-13.00305 6.43054,-24.50375 16.27369,-31.51076`},null,-1),createBaseVNode(`path`,{"inkscape:connector-curvature":`0`,id:`path4551-7-4-7-9`,class:`path3`,d:`m 590.24076,480.56245 c 10.17587,-6.96293 16.8562,-18.66157 16.86414,-31.92282 0.008,-13.00303 -6.40141,-24.51142 -16.23624,-31.5301`},null,-1),createBaseVNode(`g`,{class:`text-p`,id:`text4055-4`},[createBaseVNode(`path`,{d:`m 566.88168,447.27286 2.26429,0 c 2.11628,2e-5 3.6998,-0.41806 4.75057,-1.25424 1.05073,-0.83614 1.57611,-2.05338 1.57612,-3.65172 -10e-6,-1.6131 -0.44029,-2.80444 -1.32083,-3.57403 -0.88058,-0.76954 -2.26061,-1.15432 -4.1401,-1.15435 l -3.13005,0 z m 15.53925,-5.15015 c -3e-5,3.49265 -1.09147,6.16392 -3.27434,8.01381 -2.18292,1.84993 -5.28707,2.77488 -9.31245,2.77487 l -2.95246,0 0,11.54344 -6.88167,0 0,-32.45483 10.3669,0 c 3.93659,3e-5 6.92975,0.84729 8.97947,2.54177 2.04967,1.69455 3.07452,4.22153 3.07455,7.58094 z`,id:`path3269`,"inkscape:connector-curvature":`0`})],-1)]],512),createBaseVNode(`g`,{ref_key:`oilTempIcoOnRef`,ref:oilTempIcoOnRef,id:`ico_temp_on`,class:`ico-temp-on`,transform:`matrix(0.82879177,0,0,0.82879177,40.706638,69.281349)`,"inkscape:label":`#g4374`},[..._cache[14]||=[createBaseVNode(`path`,{"inkscape:connector-curvature":`0`,id:`path4347-7`,class:`path1`,d:`m 199.61025,285.93078 2e-5,37.83129`},null,-1),createBaseVNode(`path`,{"inkscape:connector-curvature":`0`,id:`path4347-5-40`,class:`path2`,d:`m 208.85791,292.09588 -7.00577,0`},null,-1),createBaseVNode(`path`,{"inkscape:connector-curvature":`0`,id:`path4347-5-4-9`,class:`path3`,d:`m 208.8579,301.06329 -7.00578,0`},null,-1),createBaseVNode(`path`,{"inkscape:connector-curvature":`0`,id:`path4347-5-3-4`,class:`path4`,d:`m 208.85793,309.75049 -7.00583,-1e-5`},null,-1),createBaseVNode(`circle`,{id:`path4392-8`,class:`circle1`,transform:`matrix(0.72059621,0,0,0.72059621,-1146.435,-0.73321691)`,cx:`1867.8225`,cy:`454.9176`,r:`14.849242`,d:`m 1882.6718,454.9176 c 0,8.20101 -6.6483,14.84924 -14.8493,14.84924 -8.201,0 -14.8492,-6.64823 -14.8492,-14.84924 0,-8.20101 6.6482,-14.84924 14.8492,-14.84924 8.201,0 14.8493,6.64823 14.8493,14.84924 z`},null,-1),createBaseVNode(`path`,{"inkscape:connector-curvature":`0`,id:`path4347-5-1-2-8`,class:`path5`,d:`m 183.69241,332.71741 -7.00578,0`},null,-1),createBaseVNode(`path`,{"inkscape:connector-curvature":`0`,id:`path4347-5-1-2-3-2`,class:`path6`,d:`m 223.32319,343.08941 -46.63658,-10e-6`},null,-1),createBaseVNode(`path`,{"inkscape:connector-curvature":`0`,id:`path4347-5-1-2-34-4`,class:`path7`,d:`m 222.33239,332.7174 -7.00578,0`},null,-1)]],512),createBaseVNode(`g`,{ref_key:`fuelWarnIcoOnRef`,ref:fuelWarnIcoOnRef,id:`ico_fuel_on`,class:`ico-fuel-on`,transform:`matrix(0.88747678,0,0,0.88747678,64.601263,56.302973)`,"inkscape:label":`#g4368-5`},[..._cache[15]||=[createBaseVNode(`rect`,{id:`rect4466-5`,class:`rect1`,y:`284.07593`,x:`420.99237`,height:`38.905876`,width:`22.650679`},null,-1),createBaseVNode(`rect`,{id:`rect4466-1-1`,class:`rect2`,y:`298.80991`,x:`420.99237`,height:`24.171896`,width:`22.650679`},null,-1),createBaseVNode(`path`,{"inkscape:connector-curvature":`0`,id:`path4347-5-1-2-3-3-7`,class:`path1`,d:`m 448.00445,330.93084 -30.96928,0`},null,-1),createBaseVNode(`path`,{"inkscape:connector-curvature":`0`,id:`path4347-5-1-2-3-3-8-1`,class:`path2`,d:`m 460.25266,299.90863 0.0166,18.02062 c 0,0 -0.41583,2.18743 -4.92393,2.16693 -4.50811,-0.0205 -4.80496,-2.16693 -4.80496,-2.16693 l 0.0579,-17.71243 -7.25174,-0.0941`},null,-1)]],512)],512),createBaseVNode(`g`,{ref_key:`layer12Ref`,ref:layer12Ref,"inkscape:groupmode":`layer`,id:`layer12`,class:`layer12`,"inkscape:label":`icons bottom right 2`},[createBaseVNode(`g`,{ref_key:`icoLightsHighRef`,ref:icoLightsHighRef,id:`ico_lights_high`,class:`ico-lights-high`,"inkscape:label":`#g4122`,transform:`translate(-12.000003,-2.0000028)`},[..._cache[16]||=[createBaseVNode(`path`,{"inkscape:connector-curvature":`0`,id:`rect5824-4-9`,class:`path1`,d:`m 611.67051,352.21188 19.61837,0 c 0,0 13.56687,7.61647 13.56687,22.35122 0,14.73475 -13.56687,21.08238 -13.56687,21.08238 l -19.61837,0 c 0,0 -1.90879,-4.49141 -1.95206,-21.08238 -0.0435,-16.59097 1.95206,-22.35122 1.95206,-22.35122 z`},null,-1),createBaseVNode(`path`,{"inkscape:connector-curvature":`0`,id:`path4347-5-1-2-3-1-1-8`,class:`path2`,d:`m 600.68152,355.88611 -13.21963,0`},null,-1),createBaseVNode(`path`,{"inkscape:connector-curvature":`0`,id:`path4347-5-1-2-3-1-9-20-1`,class:`path3`,d:`m 600.68152,365.4103 -13.21963,0`},null,-1),createBaseVNode(`path`,{"inkscape:connector-curvature":`0`,id:`path4347-5-1-2-3-1-8-0-8`,class:`path4`,d:`m 600.68152,374.58946 -13.21963,0`},null,-1),createBaseVNode(`path`,{"inkscape:connector-curvature":`0`,id:`path4347-5-1-2-3-1-9-6-1-2`,class:`path5`,d:`m 600.68152,384.11369 -13.21963,0`},null,-1),createBaseVNode(`path`,{"inkscape:connector-curvature":`0`,id:`path4347-5-1-2-3-1-9-6-5-4-6`,class:`path6`,d:`m 600.68152,393.43089 -13.21963,0`},null,-1)]],512)],512),createBaseVNode(`g`,{ref_key:`tickLayerRef`,ref:tickLayerRef,id:`tickLayer`,class:`tick-layer`},[(openBlock(),createElementBlock(Fragment,null,renderList(maxRpmTexts,k=>createBaseVNode(`line`,{ref_for:!0,ref:el=>setTickRef(el,k),x1:`0`,y1:`0`,x2:`0`,y2:`0`,class:`tick-line`},null,512)),64))],512)]))}},tacho_default=__plugin_vue_export_helper_default(_sfc_main$179,[[`__scopeId`,`data-v-310c7a2d`]]),_hoisted_1$159={class:`tacho-container`},_sfc_main$178={__name:`app`,setup(__props){let{$game}=useLibStore(),tachoRef=ref(null),visible=ref(!1);ref(!1),onMounted(()=>{tachoRef.value.wireThroughUnitSystem((val,func)=>UiUnits[func](val)),$game.streams.add([`electrics`,`engineInfo`]),$game.events.on(`onStreamsUpdate`,onStreamsUpdate),$game.events.on(`VehicleChange`,onVehicleChange),$game.events.on(`VehicleFocusChanged`,onVehicleFocusChanged)}),onUnmounted(()=>{$game.streams.remove([`electrics`,`engineInfo`]),$game.events.off(`onStreamsUpdate`,onStreamsUpdate),$game.events.off(`VehicleChange`,onVehicleChange),$game.events.off(`VehicleFocusChanged`,onVehicleFocusChanged)});let _done=!1;function onStreamsUpdate(streams){tachoRef.value!==null&&(_done||=!0,tachoRef.value.update(streams)?visible.value||=!0:visible&&(visible.value=!1))}function onVehicleChange(){tachoRef.value!==null&&tachoRef.value.vehicleChanged()}function onVehicleFocusChanged(data){tachoRef.value!==null&&data.mode===!0&&tachoRef.value.vehicleChanged()}return(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$159,[createVNode(tacho_default,{ref_key:`tachoRef`,ref:tachoRef},null,512)]))}},app_default$26=__plugin_vue_export_helper_default(_sfc_main$178,[[`__scopeId`,`data-v-57c978c8`]]),_sfc_main$177={__name:`app`,setup(__props){let{$game}=useLibStore(),store$1=useTasksStore();provide(`animationSettings`,{animate:!0,animateOnMount:!1,animateOnMountIntervalDelay:.2,animateOnEmptyIntervalDelay:.1,animateOnEmpty:!0,animateNextTask:!0,successCallback:playAudio});function playAudio(){$game.lua.Engine.Audio.playOnce(`AudioGui`,`event:>UI>Career>Checkbox`)}return(_ctx,_cache)=>(openBlock(),createBlock(unref(TaskList_default),{header:unref(store$1).header,tasks:unref(store$1).tasks},null,8,[`header`,`tasks`]))}},app_default$27=_sfc_main$177,_hoisted_1$158={class:`pacenote`},_hoisted_2$131=[`id`],_hoisted_3$117=[`fill`,`stroke`],_hoisted_4$95=[`id`],_hoisted_5$82=[`fill`,`stroke`],_hoisted_6$68=[`fill`],_hoisted_7$59={class:`content`},_hoisted_8$49={class:`instruction`},_hoisted_9$43={key:0,class:`modifier`},_hoisted_10$36={key:1,class:`add-note`},_hoisted_11$32={key:0,class:`distance`},_sfc_main$176={__name:`PaceNote`,props:{note:{type:Object,required:!0,validator(value){return value.type===`empty`?!0:typeof value.type==`string`},default:()=>({type:`empty`,typeExt:null,turnModifier:null,background:{color:`var(--bng-cool-gray-600)`,strokeColor:`var(--bng-cool-gray-500)`,opacity:.6},isInto:!1,isLeft:!1,size:5,turnTypeValue:null,distance:null,additionalNote:{color:`#fff`,icon:null,text:null}})}},setup(__props){useCssVars(_ctx=>({v5d4f1806:props.note.size,v654d2548:backgroundColor.value,v7d5e0455:colorNoteIcon.value,v7d630d09:colorNoteText.value,v305678bf:colorDistance.value}));let bgId=uniqueId(``,`_`),props=__props,noteUrl=computed(()=>{if(props.note.typeExt)return props.note.typeExt;let assetPath=noteTypes[props.note.type];return assetPath?getAssetURL(assetPath):null}),backgroundColor=computed(()=>props.note.background&&props.note.background.color?props.note.background.color:`var(--bng-cool-gray-600)`),strokeColor=computed(()=>props.note.background&&props.note.background.strokeColor?props.note.background.strokeColor:`var(--bng-cool-gray-500)`),backgroundOpacity=computed(()=>props.note.background&&props.note.background.opacity?props.note.background.opacity:.6),colorNoteIcon=computed(()=>props.note.colorNoteIcon?props.note.colorNoteIcon:`#fff`),colorNoteText=computed(()=>props.note.colorNoteText?props.note.colorNoteText:`#fff`),intoColor=computed(()=>props.note.intoColor?props.note.intoColor:`#fff`),colorDistance=computed(()=>props.note.colorDistance?props.note.colorDistance:`#ececec`);return(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$158,[createBaseVNode(`div`,{class:`background`,style:normalizeStyle({opacity:backgroundOpacity.value})},[__props.note.isInto?(openBlock(),createElementBlock(`svg`,{key:1,id:`note_${unref(bgId)}`,style:{width:`var(--note-size)`,height:`var(--note-size)`},viewBox:`0 0 56 56`,fill:`none`,xmlns:`http://www.w3.org/2000/svg`},[createBaseVNode(`path`,{d:`M5 47.75H5.54967L5.71519 47.2258L11.3348 29.4304C11.6288 28.4994 11.6288 27.5006 11.3348 26.5696L5.95963 9.54823C5.82856 9.13317 5.7822 8.69601 5.8233 8.26269L6.25669 3.69314C6.41494 2.02457 7.81612 0.75 9.49217 0.75H51.4137C53.3423 0.75 54.8466 2.41974 54.6461 4.33788L49.631 52.3157C49.4572 53.9784 48.0504 55.238 46.3787 55.2278L4.46341 54.9706C2.52935 54.9587 1.03362 53.2707 1.25464 51.3493L1.66867 47.75H5Z`,fill:backgroundColor.value,stroke:strokeColor.value,"stroke-width":`1.5`},null,8,_hoisted_5$82),createBaseVNode(`path`,{d:`M4 11H1L6 28L1 45H4L9.5 28L4 11Z`,fill:intoColor.value},null,8,_hoisted_6$68)],8,_hoisted_4$95)):(openBlock(),createElementBlock(`svg`,{key:0,id:`note_${unref(bgId)}`,style:{width:`var(--note-size)`,height:`var(--note-size)`},viewBox:`0 0 56 56`,fill:`none`,xmlns:`http://www.w3.org/2000/svg`},[createBaseVNode(`path`,{d:`M9.45521 0.75H51.4137C53.3423 0.75 54.8466 2.41974 54.6461 4.33788L49.631 52.3157C49.4572 53.9784 48.0504 55.238 46.3787 55.2278L4.41965 54.9703C2.49833 54.9585 1.00656 53.2915 1.2074 51.3807L6.22301 3.66028C6.39689 2.00598 7.7918 0.75 9.45521 0.75Z`,fill:backgroundColor.value,stroke:strokeColor.value,"stroke-width":`1.5`},null,8,_hoisted_3$117)],8,_hoisted_2$131))],4),createBaseVNode(`div`,_hoisted_7$59,[createBaseVNode(`div`,_hoisted_8$49,[unref(icons)[__props.note.type]?(openBlock(),createBlock(unref(bngIcon_default),{key:0,class:normalizeClass([`note-icon`,{left:__props.note.isLeft}]),type:__props.note.type},null,8,[`type`,`class`])):__props.note.typeExt&¬eUrl.value?(openBlock(),createElementBlock(`div`,{key:1,class:normalizeClass([`note-icon svg-used`,[__props.note.type,{left:__props.note.isLeft}]]),style:normalizeStyle(noteUrl.value?{maskImage:`url(${noteUrl.value})`,WebkitMaskImage:`url(${noteUrl.value})`}:null)},null,6)):createCommentVNode(``,!0),__props.note.turnTypeValue?(openBlock(),createElementBlock(`div`,{key:2,class:normalizeClass([`turn-value`,{left:__props.note.isLeft,"is-into":__props.note.isInto,"text-2-chars":__props.note.turnTypeValue.length===2}])},toDisplayString(__props.note.turnTypeValue),3)):createCommentVNode(``,!0)]),__props.note.turnModifier?(openBlock(),createElementBlock(`div`,_hoisted_9$43,[createVNode(unref(bngIcon_default),{type:__props.note.turnModifier,class:`icon-small`,color:colorNoteIcon.value},null,8,[`type`,`color`])])):createCommentVNode(``,!0),__props.note.additionalNote&&(__props.note.additionalNote.icon||__props.note.additionalNote.text)?(openBlock(),createElementBlock(`div`,_hoisted_10$36,[__props.note.additionalNote.icon?(openBlock(),createBlock(unref(bngIcon_default),{key:0,type:__props.note.additionalNote.icon,color:__props.note.additionalNote.color,class:`icon-small`},null,8,[`type`,`color`])):__props.note.additionalNote.text?(openBlock(),createElementBlock(`span`,{key:1,class:`add-text`,style:normalizeStyle(__props.note.additionalNote.color?{color:__props.note.additionalNote.color}:null)},toDisplayString(__props.note.additionalNote.text),5)):createCommentVNode(``,!0)])):createCommentVNode(``,!0)]),__props.note.distance?(openBlock(),createElementBlock(`div`,_hoisted_11$32,toDisplayString(__props.note.distance),1)):createCommentVNode(``,!0)]))}},PaceNote_default=__plugin_vue_export_helper_default(_sfc_main$176,[[`__scopeId`,`data-v-8c4cf384`]]),_hoisted_1$157={class:`pacenotes-app`},_hoisted_2$130={class:`notes-container`},FADE_DURATION=250,TOTAL_SLOTS=4,DEFAULT_NOTE_SIZE=1.8,_sfc_main$175={__name:`app`,setup(__props){useCssVars(_ctx=>({v492216b0:noteSize.value}));let incomingQueue=ref([]),noteSize=ref(DEFAULT_NOTE_SIZE),events$3=useEvents(),{lua}=useBridge(),devEnv=reactive({env:window.beamng&&!window.beamng.shipping,vue:!1}),debugSlots=computed(()=>incomingQueue.value.map(slot=>slot?`id=${slot.note.id} pnId=${slot.pacenoteId} ts=${slot.serialNo} type=${slot.note.type} isFading=${slot.isFading} isCurrent=${slot.isCurrent}`:null)),firstFourFromQueue=computed(()=>{let result=[...incomingQueue.value.slice(0,TOTAL_SLOTS)];for(;result.length<4;)result.push({id:-1,type:`empty`});return result});function getNoteKey(slot,index){return!slot||!slot.note?`empty-${index}`:`${slot.note.id}-${index}`}function getNoteWithSize(slot){return!slot||!slot.note?{type:`empty`,size:noteSize.value}:{...slot.note,size:noteSize.value}}let mockNotes=[{id:`q1`,pnId:`1`,type:`turn3`,isLeft:!1,turnTypeValue:`3`,distance:`140`,background:{color:`var(--bng-ter-yellow-300)`,strokeColor:`var(--bng-ter-yellow-200)`,opacity:.8}},{id:`q2`,pnId:`2`,type:`turnHp`,isLeft:!0,isInto:!0,background:{color:`var(--bng-add-red-500)`,strokeColor:`var(--bng-add-red-400)`,opacity:.8},additionalNote:{icon:`scissorsSlashed`,color:`var(--bng-add-red-400)`}},{id:`q3`,pnId:`2`,type:`jumpOverBump`,isLeft:!1,turnModifier:`mathLessThan`,additionalNote:{icon:`circleSlashed`,color:`var(--bng-ter-yellow-100)`}},{id:`q4`,pnId:`3`,type:`turn6`,isLeft:!0,turnTypeValue:`6`,distance:`140`,background:{color:`var(--bng-ter-yellow-300)`,strokeColor:`var(--bng-ter-yellow-200)`,opacity:.8}},{id:`q5`,pnId:`3`,type:`rocks`,isLeft:!0,distance:`50`}];function updateCurrent(){if(incomingQueue.value.length===0||(incomingQueue.value=incomingQueue.value.filter(item=>item!==null),incomingQueue.value.length===0))return;let firstPacenoteId=incomingQueue.value[0].pacenoteId;incomingQueue.value.forEach(slot=>{slot&&!slot.isFading&&(slot.isCurrent=slot.pacenoteId===firstPacenoteId)})}function addToQueue(newItems,serialNo){try{(Array.isArray(newItems)?newItems:[newItems]).forEach(note=>{if(!note.id||!note.type){console.warn(`Invalid note format:`,JSON.stringify(note,null,2));return}let val={note,isVisible:!0,isFading:!1,isCurrent:!1,pacenoteId:note.pnId,serialNo};incomingQueue.value.push(val)}),updateCurrent()}catch(error){console.error(`Error adding to queue:`,error)}}onMounted(()=>{lua.pacenotes&&lua.pacenotes.onPaceNotesAppMounted&&lua.pacenotes.onPaceNotesAppMounted(),events$3.on(`showVisualPacenote2`,pacenoteEvent=>{let serialNo=pacenoteEvent.serialNo,notes=pacenoteEvent.visualPacenotes;addToQueue(notes,serialNo)}),events$3.on(`clearOneVisualPacenote`,serialNo=>{clearOne(serialNo)}),events$3.on(`clearAllVisualPacenotes`,()=>{clearAll()})}),onUnmounted(()=>{lua.pacenotes&&lua.pacenotes.onPaceNotesAppUnmounted&&lua.pacenotes.onPaceNotesAppUnmounted()});let testAddSequence=()=>{console.log(`Adding sequence...`);let fakeSerialNo=666,lastPnid=0;mockNotes.forEach(note=>{note.pnId!==lastPnid&&(fakeSerialNo++,lastPnid=note.pnId),addToQueue(note,fakeSerialNo)}),console.log(`Current queue:`,incomingQueue.value)},clearAll=()=>{incomingQueue.value=[]},clearOne=serialNo=>{let fadeCount=0,fadeExpected=0;incomingQueue.value.forEach((item,index)=>{item.serialNo<=serialNo&&(item.isFading=!0,item.isVisible=!1,item.isCurrent=!1,fadeExpected++),setTimeout(()=>{item&&item.isFading&&(incomingQueue.value[index]=null,fadeCount++,fadeCount===fadeExpected&&updateCurrent())},FADE_DURATION)})},testClearAll=()=>{clearAll()},testClearOne=()=>{let serialNo=incomingQueue.value[0].serialNo;clearOne(serialNo)};(devEnv.env||devEnv.vue)&&(window.testPaceNotes={addSequence:testAddSequence,clearAll:testClearAll,clearOne:testClearOne,getState:()=>({queue:incomingQueue.value,slots:debugSlots.value})});function onAnimationEnd(index){let slot=incomingQueue.value[index];slot&&slot.isVisible&&!slot.isFading&&(slot.hasAnimated=!0)}return ref(null),(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$157,[createBaseVNode(`div`,_hoisted_2$130,[_cache[1]||=createBaseVNode(`div`,{class:`spacer`},null,-1),(openBlock(!0),createElementBlock(Fragment,null,renderList(firstFourFromQueue.value,(slot,index)=>(openBlock(),createBlock(PaceNote_default,{key:getNoteKey(slot,index),class:normalizeClass({"pacenote-initial":!slot?.hasAnimated,[`position-${index}`]:!0,"fade-out":slot&&slot.isFading,"fade-in":slot&&slot.isVisible&&!slot.isFading&&!slot.hasAnimated,hidden:!slot||!slot.isVisible&&!slot.isFading,current:slot&&slot.isCurrent}),note:getNoteWithSize(slot),onAnimationend:$event=>onAnimationEnd(index)},null,8,[`class`,`note`,`onAnimationend`]))),128))]),createCommentVNode(``,!0)]))}},app_default$28=__plugin_vue_export_helper_default(_sfc_main$175,[[`__scopeId`,`data-v-13adc0e2`]]),_hoisted_1$156={class:`countdown-top`},_hoisted_2$129={key:0,class:`countdown-go`},_hoisted_3$116={class:`countdown-bottom`},_hoisted_4$94={class:`rally-loop-manager-text`},_hoisted_5$81={class:`time-main`},_hoisted_6$67={key:0,class:`time-period`},_sfc_main$174={__name:`CountdownWidget`,props:{rallyLoopManager:{type:String,default:`--:--:--`},period:{type:String,default:null},countdown:{type:Number,default:10}},setup(__props){let props=__props,stage=computed(()=>props.countdown<=0?6:props.countdown>5?0:6-props.countdown);return(_ctx,_cache)=>(openBlock(),createElementBlock(Fragment,null,[createBaseVNode(`div`,_hoisted_1$156,[stage.value===6?(openBlock(),createElementBlock(`div`,_hoisted_2$129)):(openBlock(),createElementBlock(Fragment,{key:1},[createBaseVNode(`div`,{class:normalizeClass([`countdown-square`,{visible:stage.value>=1}])},null,2),createBaseVNode(`div`,{class:normalizeClass([`countdown-square`,{visible:stage.value>=2}])},null,2),createBaseVNode(`div`,{class:normalizeClass([`countdown-square`,{visible:stage.value>=3}])},null,2),createBaseVNode(`div`,{class:normalizeClass([`countdown-square`,{visible:stage.value>=4}])},null,2),createBaseVNode(`div`,{class:normalizeClass([`countdown-square`,{visible:stage.value>=5}])},null,2)],64))]),createBaseVNode(`div`,_hoisted_3$116,[createBaseVNode(`div`,_hoisted_4$94,[createBaseVNode(`span`,_hoisted_5$81,toDisplayString(__props.rallyLoopManager),1),__props.period?(openBlock(),createElementBlock(`span`,_hoisted_6$67,toDisplayString(__props.period),1)):createCommentVNode(``,!0)])])],64))}},CountdownWidget_default=__plugin_vue_export_helper_default(_sfc_main$174,[[`__scopeId`,`data-v-a0ececba`]]),_hoisted_1$155={class:`vehicle-proximity`},_hoisted_2$128={class:`top-row`},_hoisted_3$115={class:`proximity-status`},_hoisted_4$93={key:2},_sfc_main$173={__name:`VehicleProximity`,props:{vehicleProximity:{type:Object,required:!0},stage:{type:String,required:!0},precision:{type:Number,default:0,validator:value=>value>=0&&value<=2},badgeText:{type:String,default:``},instruction:{type:Object,required:!1,default:()=>({text:``,type:`notice`}),validator:value=>value?typeof value.text==`string`&&[`alert`,`alert-sm`,`notice`].includes(value.type):!0},instruction2:{type:Object,required:!1,default:()=>({structuredText:null})}},setup(__props){let props=__props,distanceDimmed=computed(()=>props.stage===`stop`||props.stage===`staged`),hasLabel=computed(()=>props.stage===`approaching`&&props.badgeText),formattedDistance=computed(()=>{let dist=props.vehicleProximity.distance;if(Math.abs(dist)>200)return`${(dist/1e3).toFixed(2)}km`;if(dist<0){let multiplier=10**props.precision,flooredDist=Math.floor(dist*multiplier)/multiplier;return`${(flooredDist===0?0:flooredDist).toFixed(props.precision)}m`}return`${dist.toFixed(props.precision)}m`});return(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$155,[createBaseVNode(`div`,_hoisted_2$128,[createBaseVNode(`div`,_hoisted_3$115,[createBaseVNode(`div`,{class:normalizeClass([`proximity-status-badge`,[__props.stage,{"has-label":hasLabel.value}]])},[__props.stage===`stop`?(openBlock(),createElementBlock(Fragment,{key:0},[createTextVNode(`STOP`)],64)):__props.stage===`goback`?(openBlock(),createElementBlock(Fragment,{key:1},[createTextVNode(`BACK`)],64)):__props.stage===`slow`?(openBlock(),createElementBlock(Fragment,{key:2},[createTextVNode(`SLOW`)],64)):__props.stage===`staged`?(openBlock(),createElementBlock(Fragment,{key:3},[createTextVNode(`STAGED`)],64)):__props.stage===`approaching`?(openBlock(),createElementBlock(Fragment,{key:4},[createTextVNode(toDisplayString(__props.badgeText),1)],64)):createCommentVNode(``,!0)],2)]),createBaseVNode(`div`,{class:normalizeClass([`proximity-distance`,{dimmed:distanceDimmed.value}])},toDisplayString(formattedDistance.value),3)]),__props.instruction?.text?(openBlock(),createElementBlock(`div`,{key:0,class:normalizeClass([`instruction-row`,__props.instruction?.type||`notice`])},toDisplayString(__props.instruction?.text),3)):createCommentVNode(``,!0),__props.instruction2?.structuredText?(openBlock(),createElementBlock(`div`,{key:1,class:normalizeClass([`instruction-row`,[__props.instruction2?.type||`notice`,{flash:__props.instruction2?.flash}]])},[(openBlock(!0),createElementBlock(Fragment,null,renderList(__props.instruction2?.structuredText,item=>(openBlock(),createElementBlock(Fragment,{key:item.id},[item.type===`clock`?(openBlock(),createElementBlock(`span`,{key:0,class:normalizeClass(item.class)},toDisplayString(item.val),3)):item.type===`penalty`?(openBlock(),createElementBlock(`span`,{key:1,class:normalizeClass(item.class)},toDisplayString(item.val),3)):(openBlock(),createElementBlock(`span`,_hoisted_4$93,toDisplayString(item),1))],64))),128))],2)):createCommentVNode(``,!0)]))}},VehicleProximity_default=__plugin_vue_export_helper_default(_sfc_main$173,[[`__scopeId`,`data-v-871af6e6`]]),_hoisted_1$154={class:`rally-countdown-app-container`},_hoisted_2$127={class:`panel-countdown`},_hoisted_3$114={key:2,class:`section-interact-hint`},_sfc_main$172={__name:`appCountdown`,setup(__props){useCssVars(_ctx=>({v730cc8f6:themeColor.value}));let{lua}=useBridge(),devEnv=reactive({env:window.beamng&&!window.beamng.shipping,vue:!1}),showDebugInfo=ref(!1),ActiveState={INACTIVE:`inactive`,VEHICLE_PROXIMITY:`vehicleProximity`,STAGE_ACTIVE:`stageActive`,COUNTDOWN:`countdown`},rallyClockData=reactive({wallClockTime:null,day:null,totalTime:0,canSkipTimeControls:!1,isTimeControlSkipAvailable:!1,canSkipCountdown:!1,isNgrcMode:!1}),activeState=ref(ActiveState.INACTIVE),vehicleProximityData=reactive({isNear:!1,distance:0,distanceToPlane:0,isStopped:!1,isFrozen:!1,usingGroundMarkerDistance:!1}),scheduleData=reactive({label:null,eventType:null,ssLabel:null,eventWallClockStart:null,eventWallClockEnd:null,timeDiff:null,timeDiffWithEnd:null,lateness:null,penalty:0,hasPenalty:!1,canIncurLatePenalty:!1,speedLimit:null,speedLimitDisplay:null,speedUnit:`km/h`,isSpeeding:!1}),stageData=reactive({currentSSTime:null,isActive:!1,isComplete:!1,splits:[],label:null,completion:{distM:0,distPct:0}}),countdownData=reactive({countdown:null,state:null}),themeColor=computed(()=>`#07ff00`),canInteract=computed(()=>rallyClockData.canSkipTimeControls||rallyClockData.canSkipCountdown),interactLabel=computed(()=>rallyClockData.canSkipCountdown||rallyClockData.canSkipTimeControls?`[action=gameplay_interact]Skip Clock`:``),proximityStage=computed(()=>{scheduleData.eventType;let distance=vehicleProximityData.distance;return scheduleData.eventType===`ss_start`?vehicleProximityData.isNear&&vehicleProximityData.isStopped?`staged`:distance<0?`goback`:vehicleProximityData.isNear&&!vehicleProximityData.isStopped?`stop`:!vehicleProximityData.isNear&&distance>=0&&distance<=25?`slow`:`approaching`:distance<0?`goback`:vehicleProximityData.isNear?`stop`:!vehicleProximityData.isNear&&distance>=0&&distance<=25||scheduleData.eventType===`ss_stop`?`slow`:`approaching`}),distancePrecision=computed(()=>{let distAbs=Math.abs(vehicleProximityData.distance),closenessThreshold=5;if(scheduleData.eventType===`ss_start`){if(distAbs<5)return proximityStage.value===`stop`||proximityStage.value===`goback`||proximityStage.value===`staged`||proximityStage.value===`slow`?2:0}else if((scheduleData.eventType===`tc`||scheduleData.eventType===`ss_stop`)&&distAbs<5)return proximityStage.value===`stop`||proximityStage.value===`goback`?1:0;return 0}),badgeText=computed(()=>scheduleData.eventType===`ss_start`?`SS${scheduleData.ssLabel}`:scheduleData.eventType===`tc`?scheduleData.label:scheduleData.eventType===`ss_stop`?`SLOW`:scheduleData.eventType===`service_in`?`SERVICE`:``),proximityInstruction2=computed(()=>{let stage=proximityStage.value;if(scheduleData.eventType===`ss_start`)return{structuredText:[`Start in `,{type:`clock`,val:scheduleData.timeDiff,class:`clock-badge`}],flash:!1};if(stage===`approaching`){if(rallyClockData.isTimeControlSkipAvailable&&scheduleData.eventType===`tc`)return{structuredText:[`Slow Down for `,{type:`clock`,val:`Clock Skip`,class:`clock-badge`}],flash:!1};if(scheduleData.eventType===`service_in`||scheduleData.label===`TC0`||scheduleData.eventType===`tc`)return{structuredText:[`Limit `,{type:`penalty`,val:`${scheduleData.speedLimitDisplay}${scheduleData.speedUnit}`,class:`penalty-badge`}],flash:scheduleData.isSpeeding}}else return null}),proximityInstruction=computed(()=>{let stage=proximityStage.value,text=``,type=`notice`;return stage===`slow`?scheduleData.eventType===`ss_start`?text=`Stage vehicle at start line.`:scheduleData.eventType===`tc`||scheduleData.eventType:stage===`stop`?scheduleData.eventType:stage===`goback`||(stage===`staged`?vehicleProximityData.isFrozen:stage===`approaching`&&(scheduleData.eventType===`ss_start`?text=`Stage vehicle at start line.`:scheduleData.eventType===`tc`||scheduleData.eventType===`service_in`||scheduleData.eventType)),{text,type:`notice`}}),streamsList$1=[`rallyLoop`],streamBuffer={rallyLoop:null},rafId=null;function processStreamUpdates(){if(streamBuffer.rallyLoop){let data=streamBuffer.rallyLoop;activeState.value=data.activeState||ActiveState.INACTIVE,data.rallyClock&&Object.assign(rallyClockData,data.rallyClock),data.scheduleData&&Object.assign(scheduleData,data.scheduleData),data.stageData&&Object.assign(stageData,data.stageData),data.countdownData&&Object.assign(countdownData,data.countdownData),data.vehicleProximity&&Object.assign(vehicleProximityData,data.vehicleProximity),data.showDebugInfo!==void 0&&(showDebugInfo.value=data.showDebugInfo),streamBuffer.rallyLoop=null}rafId=requestAnimationFrame(processStreamUpdates)}rafId=requestAnimationFrame(processStreamUpdates),useStreams(streamsList$1,streams=>{streams.rallyLoop&&(streamBuffer.rallyLoop=streams.rallyLoop)}),onMounted(()=>{}),onUnmounted(()=>{rafId&&cancelAnimationFrame(rafId)});function isStageActive(){return activeState.value===ActiveState.STAGE_ACTIVE}return(devEnv.env||devEnv.vue)&&(window.rallyLoopApp={activeState,vehicleProximityData,rallyClockData,scheduleData,stageData,countdownData,proximityStage,distancePrecision,badgeText}),(_ctx,_cache)=>(openBlock(),createBlock(Transition,{name:`fade`},{default:withCtx(()=>[createBaseVNode(`div`,_hoisted_1$154,[isStageActive()?createCommentVNode(``,!0):(openBlock(),createElementBlock(`div`,{key:0,class:normalizeClass([`rally-countdown-app`,{"show-active-stage":isStageActive()}])},[activeState.value===ActiveState.VEHICLE_PROXIMITY?(openBlock(),createElementBlock(`div`,{key:0,class:normalizeClass([`section-vehicle-positioning`,{"has-interact-hint":canInteract.value}])},[createVNode(VehicleProximity_default,{"vehicle-proximity":vehicleProximityData,stage:proximityStage.value,precision:distancePrecision.value,"badge-text":badgeText.value,instruction:proximityInstruction.value,instruction2:proximityInstruction2.value},null,8,[`vehicle-proximity`,`stage`,`precision`,`badge-text`,`instruction`,`instruction2`])],2)):createCommentVNode(``,!0),activeState.value===ActiveState.COUNTDOWN?(openBlock(),createElementBlock(`div`,{key:1,class:normalizeClass([`section-vehicle-positioning`,{"has-interact-hint":canInteract.value}])},[createBaseVNode(`div`,_hoisted_2$127,[createVNode(CountdownWidget_default,{"rally-loop-manager":rallyClockData.wallClockTime?.time||`--:--:--`,period:rallyClockData.wallClockTime?.ampm||``,countdown:countdownData.countdown},null,8,[`rally-loop-manager`,`period`,`countdown`])])],2)):createCommentVNode(``,!0),canInteract.value?(openBlock(),createElementBlock(`div`,_hoisted_3$114,[createVNode(unref(dynamicComponent_default),{template:interactLabel.value,bbcode:``},null,8,[`template`])])):createCommentVNode(``,!0)],2))])]),_:1}))}},appCountdown_default=__plugin_vue_export_helper_default(_sfc_main$172,[[`__scopeId`,`data-v-bde5d1a7`]]),_hoisted_1$153={class:`rally-timecard-app-container`},_hoisted_2$126={key:0,class:`rally-timecard-app`},_hoisted_3$113={class:`interact-label-on-timecard`},_hoisted_4$92={class:`time-card`},_hoisted_5$80={class:`rally-card-header`},_hoisted_6$66={class:`header-top`},_hoisted_7$58=[`src`],_hoisted_8$48={key:0,class:`mission-name`},_hoisted_9$42={class:`rally-card-content`},_hoisted_10$35={key:0,class:`group-divider`},_hoisted_11$31={class:`col-label`},_hoisted_12$25={class:`event-label`},_hoisted_13$22={class:`event-data-container`},_hoisted_14$21={key:0,class:`time-widget`},_hoisted_15$20={class:`col-recorded-time time-widget-value time-taken-value`},_hoisted_16$20={key:0,class:`stage-time`},_hoisted_17$16={key:0,class:`ampm`},_hoisted_18$14={class:`time-widget time-widget-due`},_hoisted_19$11={class:`col-due-time time-widget-value`},_hoisted_20$10={key:0,class:`scheduled-time`},_hoisted_21$10={key:0,class:`ampm`},_hoisted_22$8={class:`time-widget-combined`},_hoisted_23$7={class:`time-widget`},_hoisted_24$6={class:`col-recorded-time time-widget-value actual-value`},_hoisted_25$5={key:0,class:`recorded-time`},_hoisted_26$4={key:0,class:`ampm`},_hoisted_27$4={class:`time-widget`},_hoisted_28$3={class:`col-status time-widget-value status-value`},_hoisted_29$3={key:0,class:`status-text early`},_hoisted_30$3={key:1,class:`status-text late`},_hoisted_31$3={key:2,class:`status-text ok`},_hoisted_32$3={key:0,class:`penalty-card`},_hoisted_33$3={class:`rally-card-header penalty-card-header`},_hoisted_34$3={class:`header-top`},_hoisted_35$2={class:`penalty-total-header`},_hoisted_36$2={class:`total-value`},_hoisted_37$1={class:`penalty-card-content`},_hoisted_38$1={class:`penalty-group-header`},_hoisted_39$1={class:`group-name`},_hoisted_40$1={class:`group-total`},_hoisted_41$1={class:`penalty-list`},_hoisted_42$1={class:`penalty-type`},_hoisted_43$1={class:`penalty-amount`},_hoisted_44$1={key:1,class:`interact-label`},_hoisted_45$1={class:`interact-label-text`},_sfc_main$171={__name:`appTimecard`,setup(__props){useCssVars(_ctx=>({a6aff4e0:themeColor.value}));let{lua}=useBridge(),events$3=useEvents(),penaltyData=ref({totalPenalty:0,groups:[]}),displayMode=ref(1);reactive({env:window.beamng&&!window.beamng.shipping,vue:!1}),events$3.on(`RallyGameplayInteract`,data=>{data&&data.forceShowTimecard?displayMode.value=1:displayMode.value===1?displayMode.value=0:displayMode.value=1});let toggleLabel=computed(()=>displayMode.value===1?`Hide`:`Show`),interactLabel=computed(()=>`[action=gameplay_interact]`),ActiveState={INACTIVE:`inactive`,VEHICLE_PROXIMITY:`vehicleProximity`,STAGE_ACTIVE:`stageActive`,COUNTDOWN:`countdown`},showDebugInfo=ref(!1),missionName=ref(``),activeState=ref(ActiveState.INACTIVE),timecardData=ref([]),rallyClockData=reactive({}),vehicleProximityData=reactive({}),scheduleData=reactive({}),stageData=reactive({}),countdownData=reactive({}),themeColor=computed(()=>`#07ff00`);function shouldShowApp(){return displayMode.value===1}function formatPenaltyType(type){return type?type.replace(/_/g,` `):``}let streamsList$1=[`rallyLoop`],streamBuffer={rallyLoop:null},rafId=null;function processStreamUpdates(){if(streamBuffer.rallyLoop){let data=streamBuffer.rallyLoop;activeState.value=data.activeState||ActiveState.INACTIVE,data.rallyClock&&Object.assign(rallyClockData,data.rallyClock),data.scheduleData&&Object.assign(scheduleData,data.scheduleData),data.timecardData&&(timecardData.value=data.timecardData),data.penaltyData&&(penaltyData.value=data.penaltyData),data.stageData&&Object.assign(stageData,data.stageData),data.countdownData&&Object.assign(countdownData,data.countdownData),data.vehicleProximity&&Object.assign(vehicleProximityData,data.vehicleProximity),data.showDebugInfo!==void 0&&(showDebugInfo.value=data.showDebugInfo),data.missionName!==void 0&&(missionName.value=data.missionName||``),streamBuffer.rallyLoop=null}rafId=requestAnimationFrame(processStreamUpdates)}return rafId=requestAnimationFrame(processStreamUpdates),useStreams(streamsList$1,streams=>{streams.rallyLoop&&(streamBuffer.rallyLoop=streams.rallyLoop)}),onMounted(()=>{}),onUnmounted(()=>{rafId&&cancelAnimationFrame(rafId)}),(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$153,[createVNode(Transition,{name:`slide`},{default:withCtx(()=>[shouldShowApp()?(openBlock(),createElementBlock(`div`,_hoisted_2$126,[createBaseVNode(`div`,null,[createBaseVNode(`div`,_hoisted_3$113,[createVNode(unref(dynamicComponent_default),{template:`[action=gameplay_interact]${toggleLabel.value} Time Card`,bbcode:``},null,8,[`template`])]),createBaseVNode(`div`,_hoisted_4$92,[createBaseVNode(`div`,_hoisted_5$80,[createBaseVNode(`div`,_hoisted_6$66,[_cache[0]||=createBaseVNode(`span`,{class:`rally-card-title`},`TIME CARD`,-1),createBaseVNode(`img`,{class:`header-beamng-logo`,src:unref(getAssetURL)(`images/beamng-logo-mono_189x174.png`)},null,8,_hoisted_7$58)]),missionName.value?(openBlock(),createElementBlock(`div`,_hoisted_8$48,`Event: `+toDisplayString(missionName.value),1)):createCommentVNode(``,!0)]),createBaseVNode(`div`,_hoisted_9$42,[(openBlock(!0),createElementBlock(Fragment,null,renderList(timecardData.value,(entry,idx)=>(openBlock(),createElementBlock(Fragment,{key:idx},[idx>0&&entry.group!==timecardData.value[idx-1].group?(openBlock(),createElementBlock(`div`,_hoisted_10$35)):createCommentVNode(``,!0),createBaseVNode(`div`,{class:normalizeClass([`checklist-row`,{completed:entry.recordedTime||entry.stageTime,"stage-entry":entry.isStageEntry,early:entry.status===`early`,late:entry.status===`late`,"on-time":entry.status===`on-time`,pending:!entry.recordedTime&&!entry.stageTime}])},[createBaseVNode(`div`,_hoisted_11$31,[_cache[1]||=createBaseVNode(`div`,{class:`event-label-top`},`\xA0`,-1),createBaseVNode(`div`,_hoisted_12$25,toDisplayString(entry.label),1)]),createBaseVNode(`div`,_hoisted_13$22,[entry.isStageEntry?(openBlock(),createElementBlock(`div`,_hoisted_14$21,[_cache[2]||=createBaseVNode(`div`,{class:`time-widget-label`},`Time Taken`,-1),createBaseVNode(`div`,_hoisted_15$20,[entry.stageTime?(openBlock(),createElementBlock(`div`,_hoisted_16$20,[createTextVNode(toDisplayString(entry.stageTime),1),entry.stageTime.ampm?(openBlock(),createElementBlock(`span`,_hoisted_17$16,toDisplayString(entry.stageTime.ampm),1)):createCommentVNode(``,!0)])):createCommentVNode(``,!0)])])):(openBlock(),createElementBlock(Fragment,{key:1},[createBaseVNode(`div`,_hoisted_18$14,[_cache[3]||=createBaseVNode(`div`,{class:`time-widget-label`},`Due`,-1),createBaseVNode(`div`,_hoisted_19$11,[entry.scheduledTime?(openBlock(),createElementBlock(`div`,_hoisted_20$10,[createTextVNode(toDisplayString(entry.scheduledTime.time),1),entry.scheduledTime.ampm?(openBlock(),createElementBlock(`span`,_hoisted_21$10,toDisplayString(entry.scheduledTime.ampm),1)):createCommentVNode(``,!0)])):createCommentVNode(``,!0)])]),createBaseVNode(`div`,_hoisted_22$8,[createBaseVNode(`div`,_hoisted_23$7,[_cache[4]||=createBaseVNode(`div`,{class:`time-widget-label`},`Actual`,-1),createBaseVNode(`div`,_hoisted_24$6,[entry.recordedTime?(openBlock(),createElementBlock(`div`,_hoisted_25$5,[createTextVNode(toDisplayString(entry.recordedTime.time),1),entry.recordedTime.ampm?(openBlock(),createElementBlock(`span`,_hoisted_26$4,toDisplayString(entry.recordedTime.ampm),1)):createCommentVNode(``,!0)])):createCommentVNode(``,!0)])]),createBaseVNode(`div`,_hoisted_27$4,[_cache[5]||=createBaseVNode(`div`,{class:`time-widget-label`},`Status`,-1),createBaseVNode(`div`,_hoisted_28$3,[entry.status===`early`?(openBlock(),createElementBlock(`span`,_hoisted_29$3,`EARLY`)):entry.status===`late`?(openBlock(),createElementBlock(`span`,_hoisted_30$3,`LATE`)):entry.recordedTime||entry.status===`on-time`?(openBlock(),createElementBlock(`span`,_hoisted_31$3,`OK`)):createCommentVNode(``,!0)])])])],64))])],2)],64))),128))])]),penaltyData.value&&penaltyData.value.totalPenalty>0?(openBlock(),createElementBlock(`div`,_hoisted_32$3,[createBaseVNode(`div`,_hoisted_33$3,[createBaseVNode(`div`,_hoisted_34$3,[_cache[7]||=createBaseVNode(`span`,{class:`rally-card-title`},`PENALTIES`,-1),createBaseVNode(`div`,_hoisted_35$2,[_cache[6]||=createBaseVNode(`span`,{class:`total-label`},`Total`,-1),createBaseVNode(`span`,_hoisted_36$2,toDisplayString(penaltyData.value.totalPenalty)+`s`,1)])])]),createBaseVNode(`div`,_hoisted_37$1,[(openBlock(!0),createElementBlock(Fragment,null,renderList(penaltyData.value.groups,(group,idx)=>withDirectives((openBlock(),createElementBlock(`div`,{key:idx,class:`penalty-group`},[createBaseVNode(`div`,_hoisted_38$1,[createBaseVNode(`span`,_hoisted_39$1,toDisplayString(group.eventGroup),1),_cache[8]||=createBaseVNode(`span`,{class:`group-mid`},null,-1),createBaseVNode(`span`,_hoisted_40$1,toDisplayString(group.totalPenalty)+`s`,1)]),createBaseVNode(`div`,_hoisted_41$1,[(openBlock(!0),createElementBlock(Fragment,null,renderList(group.penalties,(penalty,pidx)=>(openBlock(),createElementBlock(`div`,{key:pidx,class:`penalty-item`},[createBaseVNode(`span`,_hoisted_42$1,toDisplayString(formatPenaltyType(penalty.type)),1),createBaseVNode(`span`,_hoisted_43$1,toDisplayString(penalty.amount)+`s (x`+toDisplayString(penalty.count)+`)`,1)]))),128))])])),[[vShow,group.totalPenalty>0]])),128))])])):createCommentVNode(``,!0)])])):(openBlock(),createElementBlock(`div`,_hoisted_44$1,[createBaseVNode(`div`,null,[createVNode(unref(dynamicComponent_default),{template:interactLabel.value,bbcode:``},null,8,[`template`]),createBaseVNode(`div`,_hoisted_45$1,[createBaseVNode(`div`,null,toDisplayString(toggleLabel.value),1),_cache[9]||=createBaseVNode(`div`,null,`Time Card`,-1)])])]))]),_:1})]))}},appTimecard_default=__plugin_vue_export_helper_default(_sfc_main$171,[[`__scopeId`,`data-v-216504fd`]]),_hoisted_1$152={class:`rally-dashboard-app-container`},_hoisted_2$125={class:`dashboard-widget widget-rally-clock`},_hoisted_3$112={key:0,class:`period`},_hoisted_4$91={class:`dashboard-widget widget-rally-sstime`},_hoisted_5$79={class:`widget-value`},_hoisted_6$65={class:`dashboard-widget widget-rally-objective`},_hoisted_7$57={class:`widget-value`},_hoisted_8$47={key:2},_sfc_main$170={__name:`appDashboard`,setup(__props){let{lua}=useBridge(),events$3=useEvents(),recoverVehicleTemplate=computed(()=>` Press [action=reset_physics] to recover vehicle.`),ActiveState={INACTIVE:`inactive`,VEHICLE_PROXIMITY:`vehicleProximity`,STAGE_ACTIVE:`stageActive`,COUNTDOWN:`countdown`},rallyClockData=reactive({wallClockTime:null,day:null,totalTime:0,canSkipTimeControls:!1,canSkipCountdown:!1,isNgrcMode:!1}),activeState=ref(ActiveState.INACTIVE),clockFlash=ref(!1);events$3.on(`RallyClockSkipped`,()=>{clockFlash.value=!1,setTimeout(()=>{clockFlash.value=!0},0),setTimeout(()=>{clockFlash.value=!1},1e3)});let scheduleData=reactive({label:null,eventType:null,ssLabel:null,eventWallClockStart:null,eventWallClockEnd:null,timeDiff:null,timeDiffWithEnd:null,lateness:null,penalty:0,hasPenalty:!1,canIncurLatePenalty:!1,speedLimit:null,speedLimitDisplay:null,speedUnit:`km/h`}),formattedWallClock=computed(()=>rallyClockData.wallClockTime?{time:rallyClockData.wallClockTime.time||`--:--:--`,period:rallyClockData.wallClockTime.ampm||``}:{time:`--:--:--`,period:``}),objectiveText=computed(()=>{let obj=scheduleData;return!obj||!obj.eventType?[]:obj.eventType===`service_in`?[`Drive to your `,{type:`badge`,val:`service bay`,class:`tc-badge`},`.`]:obj.eventType===`tc`&&obj.label===`TC0`?[`Reverse out and reach `,{type:`badge`,val:obj.label,class:`tc-badge`},` between `,{type:`clock`,val:obj.eventWallClockStart,class:`clock-badge`},` - `,{type:`clock`,val:obj.eventWallClockEnd,class:`clock-badge`},`. Penalty for each minute early or late: `,{type:`badge`,val:`+10s`,class:`penalty-badge`},`.`]:obj.eventType===`tc`?[`Reach `,{type:`badge`,val:obj.label,class:`tc-badge`},` between `,{type:`clock`,val:obj.eventWallClockStart,class:`clock-badge`},` - `,{type:`clock`,val:obj.eventWallClockEnd,class:`clock-badge`},`. Penalty for each minute early or late: `,{type:`badge`,val:`10sec`,class:`penalty-badge`},`.`]:[]}),streamsList$1=[`rallyLoop`],streamBuffer={rallyLoop:null},rafId=null;function processStreamUpdates(){if(streamBuffer.rallyLoop){let data=streamBuffer.rallyLoop;activeState.value=data.activeState||ActiveState.INACTIVE,data.rallyClock&&Object.assign(rallyClockData,data.rallyClock),data.scheduleData&&Object.assign(scheduleData,data.scheduleData),streamBuffer.rallyLoop=null}rafId=requestAnimationFrame(processStreamUpdates)}rafId=requestAnimationFrame(processStreamUpdates),useStreams(streamsList$1,streams=>{streams.rallyLoop&&(streamBuffer.rallyLoop=streams.rallyLoop)}),onMounted(()=>{}),onUnmounted(()=>{rafId&&cancelAnimationFrame(rafId)});function isStageActive(){return activeState.value===ActiveState.STAGE_ACTIVE}return(_ctx,_cache)=>(openBlock(),createBlock(Transition,{name:`fade`},{default:withCtx(()=>[createBaseVNode(`div`,_hoisted_1$152,[isStageActive()?createCommentVNode(``,!0):(openBlock(),createElementBlock(`div`,{key:0,class:normalizeClass([`rally-dashboard-app`,{"show-active-stage":isStageActive()}])},[createBaseVNode(`div`,_hoisted_2$125,[_cache[0]||=createBaseVNode(`div`,{class:`widget-label`},`Event Clock`,-1),createBaseVNode(`div`,{class:normalizeClass([`widget-value clock-value`,{"flash-pink":clockFlash.value}])},[createTextVNode(toDisplayString(formattedWallClock.value.time),1),formattedWallClock.value.period?(openBlock(),createElementBlock(`span`,_hoisted_3$112,toDisplayString(formattedWallClock.value.period),1)):createCommentVNode(``,!0)],2)]),createBaseVNode(`div`,_hoisted_4$91,[_cache[1]||=createBaseVNode(`div`,{class:`widget-label`},`Your Time`,-1),createBaseVNode(`div`,_hoisted_5$79,toDisplayString(rallyClockData.totalTime),1)]),createBaseVNode(`div`,_hoisted_6$65,[_cache[2]||=createBaseVNode(`div`,{class:`widget-label`},`Instructions`,-1),createBaseVNode(`div`,_hoisted_7$57,[(openBlock(!0),createElementBlock(Fragment,null,renderList(objectiveText.value,item=>(openBlock(),createElementBlock(`span`,{key:item},[item.type===`badge`?(openBlock(),createElementBlock(`span`,{key:0,class:normalizeClass(item.class)},toDisplayString(item.val),3)):item.type===`clock`?(openBlock(),createElementBlock(`span`,{key:1,class:normalizeClass(item.class)},toDisplayString(item.val.time)+toDisplayString(item.val.period),3)):(openBlock(),createElementBlock(`span`,_hoisted_8$47,toDisplayString(item),1))]))),128)),createVNode(unref(dynamicComponent_default),{template:recoverVehicleTemplate.value,bbcode:``},null,8,[`template`])])])],2))])]),_:1}))}},appDashboard_default=__plugin_vue_export_helper_default(_sfc_main$170,[[`__scopeId`,`data-v-a3bb6c18`]]),_hoisted_1$151={class:`rally-debug-app-container`},_hoisted_2$124={key:0,class:`debug-info`},_sfc_main$169={__name:`appDebug`,setup(__props){let{lua}=useBridge(),ActiveState={INACTIVE:`inactive`,VEHICLE_PROXIMITY:`vehicleProximity`,STAGE_ACTIVE:`stageActive`,COUNTDOWN:`countdown`},showDebugInfo=ref(!0),activeState=ref(ActiveState.INACTIVE),timecardData=ref([]),penaltyData=ref({totalPenalty:0,groups:[]}),rallyClockData=reactive({}),vehicleProximityData=reactive({}),scheduleData=reactive({}),stageData=reactive({}),countdownData=reactive({}),streamsList$1=[`rallyLoop`],streamBuffer={rallyLoop:null},rafId=null;function processStreamUpdates(){if(streamBuffer.rallyLoop){let data=streamBuffer.rallyLoop;activeState.value=data.activeState||ActiveState.INACTIVE,data.rallyClock&&Object.assign(rallyClockData,data.rallyClock),data.scheduleData&&Object.assign(scheduleData,data.scheduleData),data.timecardData&&(timecardData.value=data.timecardData),data.penaltyData&&(penaltyData.value=data.penaltyData),data.stageData&&Object.assign(stageData,data.stageData),data.countdownData&&Object.assign(countdownData,data.countdownData),data.vehicleProximity&&Object.assign(vehicleProximityData,data.vehicleProximity),streamBuffer.rallyLoop=null}rafId=requestAnimationFrame(processStreamUpdates)}return rafId=requestAnimationFrame(processStreamUpdates),useStreams(streamsList$1,streams=>{streams.rallyLoop&&(streamBuffer.rallyLoop=streams.rallyLoop)}),onMounted(()=>{}),onUnmounted(()=>{rafId&&cancelAnimationFrame(rafId)}),(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$151,[showDebugInfo.value?(openBlock(),createElementBlock(`div`,_hoisted_2$124,[createBaseVNode(`div`,null,`activeState: "`+toDisplayString(activeState.value)+`"`,1),createBaseVNode(`div`,null,`rallyClock: `+toDisplayString(rallyClockData),1),createBaseVNode(`div`,null,`countdownData: `+toDisplayString(countdownData),1),createBaseVNode(`div`,null,`vehicleProximityData: `+toDisplayString(vehicleProximityData),1),createBaseVNode(`div`,null,`scheduleData: `+toDisplayString(scheduleData),1),createBaseVNode(`div`,null,`timecardData: `+toDisplayString(timecardData.value),1),createBaseVNode(`div`,null,`penaltyData: `+toDisplayString(penaltyData.value),1),createBaseVNode(`div`,null,`stageData: `+toDisplayString(stageData),1)])):createCommentVNode(``,!0)]))}},appDebug_default=__plugin_vue_export_helper_default(_sfc_main$169,[[`__scopeId`,`data-v-c2c6bfeb`]]),_hoisted_1$150={class:`distance-widget-svg`},_hoisted_2$123=[`x`,`y`,`height`],_hoisted_3$111=[`x`,`y`,`width`,`height`],_hoisted_4$90=[`x`,`y`,`width`,`height`],_hoisted_5$78=[`x`,`y`,`width`,`height`],_hoisted_6$64={x:0,y:`90%`,"text-anchor":`middle`},_hoisted_7$56={class:`tick-label`},_hoisted_8$46={class:`tick-label-unit`,dx:`2`},_hoisted_9$41=[`x`,`y`,`width`,`height`],_hoisted_10$34={x:0,y:`90%`,dx:`20`,"text-anchor":`end`},_hoisted_11$30={key:0,class:`tick-label-bold`},_hoisted_12$24={class:`tick-label-unit`,dx:`2`},_hoisted_13$21=[`x`,`y`,`width`,`height`],PAD_PX=20,PADRIGHT_PX=26,barHeightPct=8,barCenterY=50,tickStrokeWidth=2,tickSize=12,trackingRectSize=14,_sfc_main$168={__name:`DistanceWidgetSVGRect`,props:{distPct:{type:Number,required:!0},totalDistM:{type:Number,required:!0},splits:{type:Array,default:()=>[]},splitPrecision:{type:Number,default:1},themeColor:{type:String,required:!0},unit:{type:String,default:`km`}},setup(__props){useCssVars(_ctx=>({v94238812:__props.themeColor}));let props=__props,barStartX=PAD_PX,barY=barCenterY-barHeightPct/2;100-PADRIGHT_PX,computed(()=>PAD_PX+(100-PAD_PX-PADRIGHT_PX)*props.distPct);let currentX=computed(()=>`calc(${PAD_PX}px + (100% - ${PAD_PX+PADRIGHT_PX}px) * ${props.distPct})`),barWidth=`calc(100% - ${PAD_PX+PADRIGHT_PX}px)`,progressWidth=computed(()=>`calc((100% - ${PAD_PX+PADRIGHT_PX}px) * ${props.distPct})`),barEndX=`calc(100% - ${PADRIGHT_PX}px)`,splitMarkers=computed(()=>props.splits?props.splits.filter(s=>typeof s?.pathnodeType==`string`&&s.pathnodeType.startsWith(`split_`)).map((s,idx)=>{let pct=s.distPct||0,x=`calc(${PAD_PX}px + (100% - ${PAD_PX+PADRIGHT_PX}px) * ${pct})`;return{key:s.pathnodeId??idx,x,label:{val:s.splitLabel,unit:props.unit}}}):[]),finalSplitLabel=computed(()=>!props.splits||props.splits.length===0?{val:null,unit:null}:{val:props.splits[props.splits.length-1]?.splitLabel,unit:props.unit});return(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$150,[(openBlock(),createElementBlock(`svg`,null,[createBaseVNode(`rect`,{x:unref(barStartX)+`px`,y:barY+`%`,width:barWidth,height:barHeightPct+`%`,fill:`white`},null,8,_hoisted_2$123),createBaseVNode(`rect`,{x:unref(barStartX)+`px`,y:barY-1+`%`,width:progressWidth.value,height:barHeightPct+2+`%`,fill:`var(--theme-color)`},null,8,_hoisted_3$111),createBaseVNode(`rect`,{x:unref(barStartX)-tickSize/2+`px`,y:`calc(`+barCenterY+`% - `+tickSize/2+`px)`,width:tickSize+`px`,height:tickSize+`px`,fill:`var(--theme-color)`},null,8,_hoisted_4$90),(openBlock(!0),createElementBlock(Fragment,null,renderList(splitMarkers.value,split=>(openBlock(),createElementBlock(`g`,{key:split.key,style:normalizeStyle(`transform: translateX(${split.x})`)},[createBaseVNode(`rect`,{x:-(tickSize/2)+`px`,y:`calc(`+barCenterY+`% - `+tickSize/2+`px)`,width:tickSize+`px`,height:tickSize+`px`,"stroke-width":tickStrokeWidth,fill:`#202020`,stroke:`#ffffff`},null,8,_hoisted_5$78),createBaseVNode(`text`,_hoisted_6$64,[createBaseVNode(`tspan`,_hoisted_7$56,toDisplayString(split.label.val),1),createBaseVNode(`tspan`,_hoisted_8$46,toDisplayString(split.label.unit),1)])],4))),128)),createBaseVNode(`g`,{style:normalizeStyle(`transform: translateX(${barEndX})`)},[createBaseVNode(`rect`,{x:-(tickSize/2)+`px`,y:`calc(`+barCenterY+`% - `+tickSize/2+`px)`,width:tickSize+`px`,height:tickSize+`px`,"stroke-width":tickStrokeWidth,fill:`#202020`,stroke:`#ffffff`},null,8,_hoisted_9$41),createBaseVNode(`text`,_hoisted_10$34,[finalSplitLabel.value?(openBlock(),createElementBlock(`tspan`,_hoisted_11$30,toDisplayString(finalSplitLabel.value.val),1)):createCommentVNode(``,!0),createBaseVNode(`tspan`,_hoisted_12$24,toDisplayString(finalSplitLabel.value.unit),1)])],4),createBaseVNode(`g`,{style:normalizeStyle(`transform: translateX(${currentX.value})`)},[createBaseVNode(`rect`,{x:-(trackingRectSize/2)+`px`,y:`calc(`+barCenterY+`% - `+trackingRectSize/2+`px)`,width:trackingRectSize+`px`,height:trackingRectSize+`px`,fill:`var(--theme-color)`},null,8,_hoisted_13$21)],4)]))]))}},DistanceWidgetSVGRect_default=__plugin_vue_export_helper_default(_sfc_main$168,[[`__scopeId`,`data-v-9c6ef477`]]);function rallyStageThemeColor(withAlpha=null){return`#009a1a${withAlpha===!0?`a0`:``}`}var _hoisted_1$149={key:0,class:`rally-stage-timing-app`},_sfc_main$167={__name:`appStageProgress`,setup(__props){useCssVars(_ctx=>({v708a5eb2:themeColor.value}));let{lua}=useBridge();reactive({env:window.beamng&&!window.beamng.shipping,vue:!1});let ActiveState={INACTIVE:`inactive`,VEHICLE_PROXIMITY:`vehicleProximity`,STAGE_ACTIVE:`stageActive`,COUNTDOWN:`countdown`},rallyClockData=reactive({wallClockSecs:null,epochTime:null,day:null,totalPenalty:0,totalTime:0,use24hFormat:!0,canSkipTimeControls:!1,canSkipCountdown:!1,isNgrcMode:!1}),activeState=ref(ActiveState.INACTIVE),vehicleProximityData=reactive({isNear:!1,distance:0,distanceToPlane:0,isStopped:!1,isFrozen:!1,usingGroundMarkerDistance:!1}),scheduleData=reactive({label:null,eventType:null,ssLabel:null,eventWallClockStart:null,eventWallClockEnd:null,timeDiff:null,timeDiffWithEnd:null,lateness:null,penalty:0,hasPenalty:!1,canIncurLatePenalty:!1}),stageData=reactive({currentSSTime:null,isActive:!1,isComplete:!1,splits:[],label:null,completion:{distPct:0},unit:`km`}),themeColor=computed(()=>rallyStageThemeColor()),streamsList$1=[`rallyLoop`],streamBuffer={rallyLoop:null},rafId=null;function processStreamUpdates(){if(streamBuffer.rallyLoop){let data=streamBuffer.rallyLoop;activeState.value=data.activeState||ActiveState.INACTIVE,data.rallyClock&&Object.assign(rallyClockData,data.rallyClock),data.scheduleData&&Object.assign(scheduleData,data.scheduleData),data.stageData&&Object.assign(stageData,data.stageData),data.vehicleProximity&&Object.assign(vehicleProximityData,data.vehicleProximity),streamBuffer.rallyLoop=null}rafId=requestAnimationFrame(processStreamUpdates)}rafId=requestAnimationFrame(processStreamUpdates),useStreams(streamsList$1,streams=>{streams.rallyLoop&&(streamBuffer.rallyLoop=streams.rallyLoop)}),onMounted(()=>{}),onUnmounted(()=>{rafId&&cancelAnimationFrame(rafId)});function shouldShowApp(){return!0}return(_ctx,_cache)=>(openBlock(),createBlock(Transition,{name:`fade`},{default:withCtx(()=>[shouldShowApp()?(openBlock(),createElementBlock(`div`,_hoisted_1$149,[createVNode(DistanceWidgetSVGRect_default,{"dist-pct":stageData.completion.distPct,"total-dist-m":stageData.completion.totalDistM,splits:stageData.splits,"theme-color":themeColor.value,unit:stageData.unit},null,8,[`dist-pct`,`total-dist-m`,`splits`,`theme-color`,`unit`])])):createCommentVNode(``,!0)]),_:1}))}},appStageProgress_default=__plugin_vue_export_helper_default(_sfc_main$167,[[`__scopeId`,`data-v-a8eba296`]]);function formatSSTime(seconds,activeState){if(activeState===`inactive`)return`--:--:--`;let roundedSeconds=Math.round(seconds*10)/10,hours=Math.floor(roundedSeconds/3600),minutes=Math.floor(roundedSeconds%3600/60),secs=Math.floor(roundedSeconds%60),tenths=Math.round(roundedSeconds%1*10)%10;return hours>0?`${hours}:${String(minutes).padStart(2,`0`)}:${String(secs).padStart(2,`0`)}.${tenths}`:minutes>0?`${minutes}:${String(secs).padStart(2,`0`)}.${tenths}`:`${secs}.${tenths}`}var _hoisted_1$148={key:0,class:`rally-stage-timing-app`},_hoisted_2$122={class:`section-active-stage`},_hoisted_3$110={class:`stage-header`},_hoisted_4$89={class:`stage-time`},_hoisted_5$77={key:0,class:`splits-header`},_hoisted_6$63={key:1,class:`stage-splits`},_hoisted_7$55={class:`stage-split-label`},_hoisted_8$45={class:`stage-split-label-unit`},_hoisted_9$40={class:`stage-split-time`},_hoisted_10$33=[`src`],_sfc_main$166={__name:`appStageTiming`,setup(__props){let{lua}=useBridge(),ActiveState={INACTIVE:`inactive`,VEHICLE_PROXIMITY:`vehicleProximity`,STAGE_ACTIVE:`stageActive`,COUNTDOWN:`countdown`},rallyClockData=reactive({wallClockSecs:null,epochTime:null,day:null,totalPenalty:0,totalTime:0,use24hFormat:!0,canSkipTimeControls:!1,canSkipCountdown:!1,isNgrcMode:!1}),activeState=ref(ActiveState.INACTIVE),vehicleProximityData=reactive({isNear:!1,distance:0,distanceToPlane:0,isStopped:!1,isFrozen:!1,usingGroundMarkerDistance:!1}),scheduleData=reactive({label:null,eventType:null,ssLabel:null,eventWallClockStart:null,eventWallClockEnd:null,timeDiff:null,timeDiffWithEnd:null,lateness:null,penalty:0,hasPenalty:!1,canIncurLatePenalty:!1}),stageData=reactive({currentSSTime:null,isActive:!1,isComplete:!1,splits:[],label:null,completion:{distM:0,distPct:0}});computed(()=>rallyStageThemeColor(!0));let completedSplits=computed(()=>stageData.splits?.filter(split=>split.time!=null)||[]),splitUnit=computed(()=>`km`),streamsList$1=[`rallyLoop`],streamBuffer={rallyLoop:null},rafId=null;function processStreamUpdates(){if(streamBuffer.rallyLoop){let data=streamBuffer.rallyLoop;activeState.value=data.activeState||ActiveState.INACTIVE,data.rallyClock&&Object.assign(rallyClockData,data.rallyClock),data.scheduleData&&Object.assign(scheduleData,data.scheduleData),data.stageData&&Object.assign(stageData,data.stageData),data.vehicleProximity&&Object.assign(vehicleProximityData,data.vehicleProximity),streamBuffer.rallyLoop=null}rafId=requestAnimationFrame(processStreamUpdates)}rafId=requestAnimationFrame(processStreamUpdates),useStreams(streamsList$1,streams=>{streams.rallyLoop&&(streamBuffer.rallyLoop=streams.rallyLoop)}),onMounted(()=>{}),onUnmounted(()=>{rafId&&cancelAnimationFrame(rafId)});function shouldShowApp(){return!0}return(_ctx,_cache)=>(openBlock(),createBlock(Transition,{name:`fade`},{default:withCtx(()=>[shouldShowApp()?(openBlock(),createElementBlock(`div`,_hoisted_1$148,[createBaseVNode(`div`,_hoisted_2$122,[createBaseVNode(`div`,_hoisted_3$110,`STAGE `+toDisplayString(stageData.label)+` / `+toDisplayString(scheduleData.totalSSCount),1),createBaseVNode(`div`,_hoisted_4$89,toDisplayString(unref(formatSSTime)(stageData.currentSSTime,activeState.value)),1),completedSplits.value.length>0?(openBlock(),createElementBlock(`div`,_hoisted_5$77,`SPLITS`)):createCommentVNode(``,!0),completedSplits.value.length>0?(openBlock(),createElementBlock(`div`,_hoisted_6$63,[(openBlock(!0),createElementBlock(Fragment,null,renderList(completedSplits.value,split=>(openBlock(),createElementBlock(`div`,{class:`stage-split`,key:split.pathnodeId},[createBaseVNode(`div`,_hoisted_7$55,[createBaseVNode(`span`,null,toDisplayString(split.splitLabel),1),createBaseVNode(`span`,_hoisted_8$45,toDisplayString(splitUnit.value),1)]),createBaseVNode(`div`,_hoisted_9$40,toDisplayString(unref(formatSSTime)(split.time,activeState.value)),1)]))),128))])):createCommentVNode(``,!0),rallyClockData.isNgrcMode?(openBlock(),createElementBlock(`img`,{key:2,class:`stage-ngrc-badge`,src:unref(getAssetURL)(`images/ngrc_logo_dark_128x40.png`),alt:`NGRC`},null,8,_hoisted_10$33)):createCommentVNode(``,!0)])])):createCommentVNode(``,!0)]),_:1}))}},appStageTiming_default=__plugin_vue_export_helper_default(_sfc_main$166,[[`__scopeId`,`data-v-cea09957`]]),_hoisted_1$147={class:`gameplay-apps`},gameplayAppsFlashMessage=`GameplayAppsFlashMessage`,_sfc_main$165={__name:`gameplayApps`,setup(__props){let{lua}=useBridge(),events$3=useEvents(),isDrift=ref(!1),isDragStaging=ref(!1),isRally=ref(!1),isPointsBar=ref(!1),isFlashMessage=ref(!1),isCountdown=ref(!1),appStates={drift:isDrift,drag:isDragStaging,rally:isRally,pointsBar:isPointsBar,flashMessage:isFlashMessage,countdown:isCountdown},setAppVisibility=data=>{data.appId&&appStates[data.appId]&&(appStates[data.appId].value=data.visible),data.hideAll&&Object.values(appStates).forEach(state=>state.value=!1)},loadInitialVisibility=async()=>{try{let visibleApps=await lua.ui_gameplayAppContainers.getVisibleApps(`gameplayApps`);Object.values(appStates).forEach(state=>state.value=!1),Array.isArray(visibleApps)&&visibleApps.forEach(appId=>{appStates[appId]&&(appStates[appId].value=!0)})}catch{}};return onMounted(()=>{events$3.on(`setGameplayAppVisibility`,setAppVisibility),lua.ui_gameplayAppContainers.onGameplayAppContainerMounted(),loadInitialVisibility()}),onUnmounted(()=>{events$3.off(`setGameplayAppVisibility`,setAppVisibility),lua.ui_gameplayAppContainers.onGameplayAppContainerUnmounted()}),(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$147,[withDirectives((openBlock(),createBlock(resolveDynamicComponent(unref(app_default)),mergeProps({class:`app`},_ctx.$attrs),null,16)),[[vShow,isPointsBar.value]]),withDirectives((openBlock(),createBlock(resolveDynamicComponent(unref(app_default$28)),mergeProps({class:`app rally`},_ctx.$attrs),null,16)),[[vShow,isRally.value]]),withDirectives((openBlock(),createBlock(resolveDynamicComponent(unref(app_default$13)),mergeProps({class:`app`,showFlash:!1},_ctx.$attrs),null,16)),[[vShow,isDrift.value]]),withDirectives((openBlock(),createBlock(resolveDynamicComponent(unref(app_default$11)),mergeProps({class:`app`,showFlash:!1},_ctx.$attrs),null,16)),[[vShow,isDragStaging.value]]),withDirectives((openBlock(),createBlock(resolveDynamicComponent(unref(flashMessageApp_default)),mergeProps({class:`app flash-message`,"message-source":gameplayAppsFlashMessage},_ctx.$attrs),null,16)),[[vShow,isFlashMessage.value]]),withDirectives((openBlock(),createBlock(resolveDynamicComponent(unref(countdownApp_default)),mergeProps({class:`countdown`},_ctx.$attrs),null,16)),[[vShow,isCountdown.value]])]))}},gameplayApps_default=__plugin_vue_export_helper_default(_sfc_main$165,[[`__scopeId`,`data-v-8ac28a96`]]),_hoisted_1$146={class:`messages-tasks-apps`},_sfc_main$164={__name:`messagesTasksApps`,setup(__props){let{lua}=useBridge(),events$3=useEvents(),isMessages=ref(!1),isTasks=ref(!1),appStates={messages:isMessages,tasks:isTasks},setAppVisibility=data=>{data.appId&&appStates[data.appId]&&(appStates[data.appId].value=data.visible),data.hideAll&&Object.values(appStates).forEach(state=>{state.value=!1})},loadInitialVisibility=async()=>{try{let visibleApps=await lua.ui_messagesTasksAppContainers.getVisibleApps(`messagesTasksApps`);Object.values(appStates).forEach(state=>{state.value=!1}),Array.isArray(visibleApps)&&visibleApps.forEach(appId=>{appStates[appId]&&(appStates[appId].value=!0)})}catch{}};return onMounted(()=>{events$3.on(`setMessagesTasksAppVisibility`,setAppVisibility),lua.ui_messagesTasksAppContainers.onMessagesTasksAppContainerMounted(),loadInitialVisibility()}),onUnmounted(()=>{events$3.off(`setMessagesTasksAppVisibility`,setAppVisibility),lua.ui_messagesTasksAppContainers.onMessagesTasksAppContainerUnmounted()}),(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$146,[withDirectives((openBlock(),createBlock(resolveDynamicComponent(unref(app_default$27)),mergeProps({class:`app`},_ctx.$attrs),null,16)),[[vShow,isTasks.value]]),withDirectives((openBlock(),createBlock(resolveDynamicComponent(unref(app_default$32)),mergeProps({class:`app`},_ctx.$attrs),null,16)),[[vShow,isMessages.value]])]))}},messagesTasksApps_default=__plugin_vue_export_helper_default(_sfc_main$164,[[`__scopeId`,`data-v-0ac32403`]]),_sfc_main$163={__name:`countdownApp`,setup(__props){let events$3=useEvents();function convertLegacyMessage(data){return Array.isArray(data)?data.map(item=>({msg:typeof item[0]==`object`?item[0].txt:item[0],ttl:item[1],luaCall:typeof item[2]==`string`?item[2]:void 0,jsCallback:typeof item[2]==`function`?item[2]:void 0,big:item[3]??!1})):data}return onMounted(()=>{events$3.on(`ScenarioFlashMessage`,data=>{let convertedData=convertLegacyMessage(data);if(Array.isArray(convertedData)&&convertedData.length>0){let lastMessage=convertedData[convertedData.length-1];lastMessage.msg===`GO!`&&(lastMessage.jsCallback=()=>{events$3.emit(`CountdownEnded`)})}events$3.emit(`CountdownMessage`,convertedData)}),events$3.on(`ScenarioNotRunning`,()=>{events$3.emit(`CountdownMessage`,{msg:``,ttl:0})})}),(_ctx,_cache)=>(openBlock(),createBlock(bngFlashMessage_default,{"message-source":`CountdownMessage`}))}},countdownApp_default=__plugin_vue_export_helper_default(_sfc_main$163,[[`__scopeId`,`data-v-8ddc025c`]]),_sfc_main$162={__name:`flashMessageApp`,setup(__props){let events$3=useEvents();return onMounted(()=>{events$3.on(`ScenarioFlashMessage`,data=>{let convertedData=Array.isArray(data)?data.map(item=>({msg:typeof item[0]==`object`?item[0].txt:item[0],ttl:item[1],luaCall:typeof item[2]==`string`?item[2]:void 0,jsCallback:typeof item[2]==`function`?item[2]:void 0,big:item[3]??!1})):data;events$3.emit(`SimpleFlashMessage`,convertedData)}),events$3.on(`ScenarioNotRunning`,()=>{events$3.emit(`SimpleFlashMessage`,{msg:``,ttl:0})})}),(_ctx,_cache)=>(openBlock(),createBlock(bngFlashMessage_default,{"message-source":`SimpleFlashMessage`}))}},flashMessageApp_default=__plugin_vue_export_helper_default(_sfc_main$162,[[`__scopeId`,`data-v-48db34d3`]]),_hoisted_1$145={class:`generic-mission-data`},_sfc_main$161={__name:`bngGenericMissionData`,setup(__props){let events$3=useEvents(),{lua}=useBridge(),displayElements=ref([]),getElementValue=element=>element.minutes||element.seconds?``:typeof element.txt==`number`?element.txt:element.style===`text`||element.style===void 0?$translate.instant(element.txt):`Error: Unsupported style`,handleMissionDataChanged=data=>{if(data){for(;displayElements.value.length<=data.index;)displayElements.value.push(null);displayElements.value[data.index]=data.element}},handleMissionDataReset=()=>{displayElements.value=[]};return onMounted(()=>{events$3.on(`SetGenericMissionData`,handleMissionDataChanged),events$3.on(`SetGenericMissionDataResetAll`,handleMissionDataReset),lua.extensions.load(`ui_apps_genericMissionData`),lua.ui_apps_genericMissionData.sendAllData()}),(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$145,[(openBlock(!0),createElementBlock(Fragment,null,renderList(displayElements.value,(element,index)=>(openBlock(),createElementBlock(Fragment,{key:index},[element?(openBlock(),createBlock(bngSimpleDataDisplay_default,{key:0,label:_ctx.$tt(element.title),value:getElementValue(element),icon:element.icon,minutes:element.minutes,seconds:element.seconds,milliseconds:element.milliseconds,class:`mission-data-item`},null,8,[`label`,`value`,`icon`,`minutes`,`seconds`,`milliseconds`])):createCommentVNode(``,!0)],64))),128))]))}},bngGenericMissionData_default=__plugin_vue_export_helper_default(_sfc_main$161,[[`__scopeId`,`data-v-1cdb0dd5`]]),_hoisted_1$144={class:`controls-container`},_sfc_main$160={__name:`app`,setup(__props){let{$game}=useLibStore();return ref(!0),(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$144,[createVNode(unref(bngAppBindingDisplay_default))]))}},app_default$29=__plugin_vue_export_helper_default(_sfc_main$160,[[`__scopeId`,`data-v-66fafb5f`]]),_hoisted_1$143={class:`main-container-grid`},_hoisted_2$121={class:`points-display`},_hoisted_3$109={class:`star-wrapper`},_sfc_main$159={__name:`app`,setup(__props){let{lua}=useBridge(),fillPercent=ref(0),pointsLabel=ref(`0`),thresholdPercentages=ref([]),thresholdsReached=ref([]),thresholdCount=ref(0),thresholdIndices=computed(()=>Array.from({length:thresholdCount.value},(_,index)=>index));onMounted(()=>{lua.extensions.load(`ui_apps_pointsBar`),lua.ui_apps_pointsBar.requestAllData()}),onUnmounted(()=>{});let streamsList$1=[`pointsBar`];return useStreams(streamsList$1,streams=>{for(let stream of streamsList$1)if(!streams[stream])return;fillPercent.value=streams.pointsBar.fillPercent,pointsLabel.value=streams.pointsBar.pointsLabel,streams.pointsBar.thresholdPercentages&&Array.isArray(streams.pointsBar.thresholdPercentages)&&(thresholdPercentages.value=streams.pointsBar.thresholdPercentages),streams.pointsBar.thresholdsReached&&Array.isArray(streams.pointsBar.thresholdsReached)&&(thresholdsReached.value=streams.pointsBar.thresholdsReached),thresholdCount.value=streams.pointsBar.thresholdCount}),(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$143,[createBaseVNode(`div`,{class:`progress-bar-container`,style:normalizeStyle({"--threshold-percentage":thresholdPercentages.value[0]||0})},[createBaseVNode(`div`,_hoisted_2$121,toDisplayString(_ctx.$t(pointsLabel.value)),1),createBaseVNode(`div`,{class:`progress-bar`,style:normalizeStyle({width:`${fillPercent.value*100}%`})},null,4),(openBlock(!0),createElementBlock(Fragment,null,renderList(thresholdIndices.value,i=>(openBlock(),createElementBlock(`div`,{key:i,class:normalizeClass([`limit-marker`,{passed:thresholdsReached.value[i]}]),style:normalizeStyle({left:`${thresholdPercentages.value[i]}%`})},[createBaseVNode(`div`,_hoisted_3$109,[createVNode(unref(bngIcon_default),{type:thresholdsReached.value[i]?unref(icons).star:unref(icons).starSecondary,class:normalizeClass([`star-icon`,{passed:thresholdsReached.value[i]}])},null,8,[`type`,`class`])])],6))),128))],4)]))}},app_default=__plugin_vue_export_helper_default(_sfc_main$159,[[`__scopeId`,`data-v-4e2c4ac3`]]),_hoisted_1$142={key:0,class:`minimap-container-additional-info top`},_hoisted_2$120={key:0},_hoisted_3$108={key:1,class:`minimap-container-additional-info bottom`},_hoisted_4$88={key:2},_hoisted_5$76={key:0,class:`minimap-container-additional-info top round`},_hoisted_6$62={key:0},_hoisted_7$54={key:1,class:`minimap-container-additional-info bottom round`},_hoisted_8$44={key:2},transformUpdateAttempts=15,_sfc_main$158={__name:`app`,setup(__props){useCssVars(_ctx=>({v01db66c6:squareSize.value,v32146572:minimapSize.value}));let{lua}=useBridge(),events$3=useEvents(),route=useRoute(),$globalStore=inject(`$globalStore`),uiVisible=ref(!0),initialising=ref(!1),initialised=ref(!1),minimapMode=ref(`circle`),minimapContainerRef=ref(null),containerRef=ref(null);ref(null),ref(null);let resizeObserver=ref(null),mapMetrics=reactive({x:0,y:0,width:0,height:0,xRel:0,yRel:0,widthRel:0,heightRel:0}),allowedRoutes=[`/play`,``],showMinimap=computed(()=>uiVisible.value&&!loadingScreen.shown&&$globalStore.__uiAppsShown&&!$globalStore.__introPopupShown&&!popupsView.popups&&!popupsView.activities&&allowedRoutes.includes(route.path)),additionalInfo=reactive({distToTarget:null,locationName:null,policeMode:`disabled`}),hasTopInfo=computed(()=>!!additionalInfo.locationName),hasBottomInfo=computed(()=>!!(additionalInfo.distToTarget||additionalInfo.policeMode===`visibleToPolice`||additionalInfo.policeMode===`hiddenFromPolice`));watch(hasTopInfo,val=>{showMinimap.value&&requestAnimationFrame(updateDrawTransform)}),watch(hasBottomInfo,val=>{showMinimap.value&&requestAnimationFrame(updateDrawTransform)});let transformUpdateAttempt=0,minimapSize=ref(`100%`),minimapShift=ref(`0px`),squareSize=ref(`100%`);async function updateDrawTransform(){if(minimapMode.value===`circle`&&minimapContainerRef.value){let rect$1=minimapContainerRef.value.getBoundingClientRect(),size$3=Math.min(rect$1.width,rect$1.height),sizepx=size$3+`px`;minimapSize.value!==sizepx&&(minimapSize.value=sizepx,rect$1.width>rect$1.height?minimapShift.value=-(rect$1.width-size$3)/2+`px`:minimapShift.value=`0px`,await nextTick())}if(!initialised.value||!showMinimap.value||!containerRef.value)return;let screen$1={width:window.innerWidth,height:window.innerHeight,scrollX:window.scrollX,scrollY:window.scrollY},rect=containerRef.value.getBoundingClientRect();mapMetrics.x=rect.left+screen$1.scrollX,mapMetrics.y=rect.top+screen$1.scrollY,mapMetrics.width=rect.width,mapMetrics.height=rect.height,mapMetrics.xRel=mapMetrics.x/screen$1.width,mapMetrics.yRel=mapMetrics.y/screen$1.height,mapMetrics.widthRel=mapMetrics.width/screen$1.width,mapMetrics.heightRel=mapMetrics.height/screen$1.height;let keys=[`xRel`,`yRel`,`widthRel`,`heightRel`];if(keys.some(key=>mapMetrics[key]<0||mapMetrics[key]>1)||keys.every(key=>mapMetrics[key]===0)){transformUpdateAttempt++,transformUpdateAttempt{val?updateDrawTransform():initialised.value&&sendTransformToLua(!1)}),watch([initialised,containerRef],()=>{updateDrawTransform(),containerRef.value&&!resizeObserver.value&&(resizeObserver.value=new ResizeObserver(()=>{updateDrawTransform()}),resizeObserver.value.observe(containerRef.value))},{immediate:!0}),onMounted(()=>{window.addEventListener(`scroll`,updateDrawTransform),window.addEventListener(`resize`,updateDrawTransform),events$3.on(`onCefVisibilityChanged`,visible=>{uiVisible.value=visible,nextTick(updateDrawTransform)}),initMinimap()}),onUnmounted(()=>{let wasInitialised=initialised.value;initialised.value=!1,window.removeEventListener(`scroll`,updateDrawTransform),window.removeEventListener(`resize`,updateDrawTransform),resizeObserver.value&&=(resizeObserver.value.disconnect(),null),wasInitialised&&sendTransformToLua(!1)}),useStreams([`minimap`],streams=>{streams.minimap&&(additionalInfo.distToTarget=streams.minimap.distToTarget,additionalInfo.locationName=streams.minimap.locationName,additionalInfo.policeMode=streams.minimap.policeMode)}),(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,{ref_key:`minimapContainerRef`,ref:minimapContainerRef,class:normalizeClass([`minimap-container-wrapper`,{[`police-`+additionalInfo.policeMode]:minimapMode.value===`rect`,round:minimapMode.value===`circle`}]),onClick:updateDrawTransform},[minimapMode.value===`rect`?(openBlock(),createElementBlock(Fragment,{key:0},[hasTopInfo.value?(openBlock(),createElementBlock(`div`,_hoisted_1$142,[additionalInfo.locationName?(openBlock(),createElementBlock(`span`,_hoisted_2$120,toDisplayString(additionalInfo.locationName),1)):createCommentVNode(``,!0)])):createCommentVNode(``,!0),createBaseVNode(`div`,{class:normalizeClass([`minimap-container`,{"round-bottom":!hasBottomInfo.value,"round-top":!hasTopInfo.value}]),ref_key:`containerRef`,ref:containerRef},null,2),hasBottomInfo.value?(openBlock(),createElementBlock(`div`,_hoisted_3$108,[additionalInfo.policeMode===`visibleToPolice`?(openBlock(),createBlock(unref(bngIcon_default),{key:0,type:`eyeSolidOpened`})):createCommentVNode(``,!0),additionalInfo.policeMode===`hiddenFromPolice`?(openBlock(),createBlock(unref(bngIcon_default),{key:1,type:`eyeSolidClosed`})):createCommentVNode(``,!0),additionalInfo.distToTarget?(openBlock(),createElementBlock(`span`,_hoisted_4$88,toDisplayString(additionalInfo.distToTarget),1)):createCommentVNode(``,!0),additionalInfo.distToTarget?(openBlock(),createBlock(unref(bngIcon_default),{key:3,class:``,type:`mapPoint`})):createCommentVNode(``,!0)])):createCommentVNode(``,!0)],64)):minimapMode.value===`circle`?(openBlock(),createElementBlock(Fragment,{key:1},[hasTopInfo.value?(openBlock(),createElementBlock(`div`,_hoisted_5$76,[additionalInfo.locationName?(openBlock(),createElementBlock(`span`,_hoisted_6$62,toDisplayString(additionalInfo.locationName),1)):createCommentVNode(``,!0)])):createCommentVNode(``,!0),createBaseVNode(`div`,{class:normalizeClass([`minimap-container round`,{[`police-`+additionalInfo.policeMode]:!0}]),ref_key:`containerRef`,ref:containerRef},null,2),hasBottomInfo.value?(openBlock(),createElementBlock(`div`,_hoisted_7$54,[additionalInfo.policeMode===`visibleToPolice`?(openBlock(),createBlock(unref(bngIcon_default),{key:0,type:`eyeSolidOpened`})):createCommentVNode(``,!0),additionalInfo.policeMode===`hiddenFromPolice`?(openBlock(),createBlock(unref(bngIcon_default),{key:1,type:`eyeSolidClosed`})):createCommentVNode(``,!0),additionalInfo.distToTarget?(openBlock(),createElementBlock(`span`,_hoisted_8$44,toDisplayString(additionalInfo.distToTarget),1)):createCommentVNode(``,!0),additionalInfo.distToTarget?(openBlock(),createBlock(unref(bngIcon_default),{key:3,class:``,type:`mapPoint`})):createCommentVNode(``,!0)])):createCommentVNode(``,!0)],64)):createCommentVNode(``,!0)],2))}},app_default$30=__plugin_vue_export_helper_default(_sfc_main$158,[[`__scopeId`,`data-v-4d3d3a71`]]),_hoisted_1$141={class:`hotlapping-app`},_hoisted_2$119={class:`hotlapping-header`},_hoisted_3$107={class:`header-flex`},_hoisted_4$87={class:`hotlapping-content`},_hoisted_5$75={key:0,class:`grid-header`},_hoisted_6$61={class:`grid-item current-item`},_hoisted_7$53={class:`grid-item current-item`},_hoisted_8$43={class:`grid-item current-item`},_sfc_main$157={__name:`app`,setup(__props){useEvents();let fastData=ref({}),slowData=ref({}),staticData=ref({}),placementData=ref({}),displayMode=ref(`combined`);onMounted(()=>{useStreams([`lapTimes_fast`,`lapTimes_slow`,`lapTimes_static`,`lapTimes_placement`],streams=>{streams.lapTimes_fast&&(fastData.value=streams.lapTimes_fast),streams.lapTimes_slow&&(slowData.value=streams.lapTimes_slow),streams.lapTimes_static&&(staticData.value=streams.lapTimes_static),streams.lapTimes_placement&&(placementData.value=streams.lapTimes_placement)})}),onUnmounted(()=>{});let getLapValue=()=>`${slowData.value?.currentLap||0}/${staticData.value?.totalLaps||0}`,getSegmentValue=()=>`${slowData.value?.currentSegment||0}/${staticData.value?.totalSegments||0}`,getTotalRaceTime=()=>fastData.value?.currentTimeFormatted||`00:00.000`,parseTimeString=timeStr=>{if(!timeStr)return{minutes:`00`,seconds:`00`,milliseconds:`000`};let parts=timeStr.split(`:`);if(parts.length===2){let minutes=parts[0].padStart(2,`0`),secondsParts=parts[1].split(`.`);return{minutes,seconds:secondsParts[0].padStart(2,`0`),milliseconds:secondsParts[1]?secondsParts[1].padEnd(3,`0`):`000`}}else{let secondsParts=parts[0].split(`.`);return{minutes:`00`,seconds:secondsParts[0].padStart(2,`0`),milliseconds:secondsParts[1]?secondsParts[1].padEnd(3,`0`):`000`}}},getTotalRaceTimeMinutes=()=>parseTimeString(getTotalRaceTime()).minutes,getTotalRaceTimeSeconds=()=>parseTimeString(getTotalRaceTime()).seconds,getTotalRaceTimeMilliseconds=()=>parseTimeString(getTotalRaceTime()).milliseconds,isRacing=()=>slowData.value?.status===`started`||slowData.value?.status===`paused`,getCurrentLapDiffClass=()=>{let flavor=fastData.value?.currentLapDiffToBestFlavor;return flavor===`better`?`diff-better`:flavor===`worse`?`diff-worse`:`diff-neutral`},getDiffClass=(flavor,value)=>!value||value===``||value===`N/A`?`diff-neutral`:flavor===`better`?`diff-better`:flavor===`worse`?`diff-worse`:`diff-neutral`,shouldShowToggleIcon=()=>(staticData.value?.totalLaps||0)>1,shouldShowSegmentsByDefault=()=>(staticData.value?.totalLaps||0)<=1,cycleDisplayMode=()=>{if(shouldShowToggleIcon()){let modes=[`combined`,`laps`,`segments`];displayMode.value=modes[(modes.indexOf(displayMode.value)+1)%modes.length]}},getTableHeaderLabel=()=>displayMode.value===`combined`?`Combined`:displayMode.value===`segments`?`Split`:`Lap`,shouldHideVsPrevBest=()=>(staticData.value?.totalLaps||0)<=1,getCurrentTimeFormatted=()=>displayMode.value===`segments`||shouldShowSegmentsByDefault()&&displayMode.value===`combined`?fastData.value?.currentSegmentTimeFormatted:fastData.value?.currentLapTimeFormatted,getCurrentItemNumber=()=>displayMode.value===`segments`||shouldShowSegmentsByDefault()&&displayMode.value===`combined`?`${slowData.value?.currentLap||1}-${slowData.value?.currentSegment||1}`:slowData.value?.currentLap||1,getCurrentDiff=()=>displayMode.value===`segments`||shouldShowSegmentsByDefault()&&displayMode.value===`combined`?fastData.value?.currentSegmentDiffToBestFormatted||``:fastData.value?.currentLapDiffToBestFormatted||``,getCurrentTotalTime=()=>fastData.value?.currentTimeFormatted||``,getFilteredCombinedItems=()=>{if(!slowData.value||!slowData.value.combinedTimes||!Array.isArray(slowData.value.combinedTimes))return[];let filtered=[];return displayMode.value===`combined`?filtered=[...slowData.value.combinedTimes]:displayMode.value===`laps`?filtered=slowData.value.combinedTimes.filter(item=>item.type===`lap`):displayMode.value===`segments`&&(filtered=slowData.value.combinedTimes.filter(item=>item.type===`segment`)),filtered.reverse()},getItemKey=item=>`${item.type}-${item.identifier}`,getItemNumber=item=>item.identifier;return(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$141,[createBaseVNode(`div`,_hoisted_2$119,[createBaseVNode(`div`,_hoisted_3$107,[staticData.value.totalLaps>1?(openBlock(),createBlock(bngSimpleDataDisplay_default,{key:0,class:`header-cell`,label:`Lap`,value:getLapValue()},null,8,[`value`])):createCommentVNode(``,!0),staticData.value.totalSegments>1?(openBlock(),createBlock(bngSimpleDataDisplay_default,{key:1,class:`header-cell`,label:`Split`,value:getSegmentValue()},null,8,[`value`])):createCommentVNode(``,!0),createVNode(bngSimpleDataDisplay_default,{class:`header-cell`,label:`Race Clock`,minutes:getTotalRaceTimeMinutes(),seconds:getTotalRaceTimeSeconds(),milliseconds:getTotalRaceTimeMilliseconds()},null,8,[`minutes`,`seconds`,`milliseconds`])])]),createBaseVNode(`div`,_hoisted_4$87,[createBaseVNode(`div`,{class:normalizeClass([`times-grid`,{"single-lap":shouldHideVsPrevBest()}])},[createBaseVNode(`div`,{class:normalizeClass([`grid-header clickable-header`,{"has-toggle":shouldShowToggleIcon()}]),onClick:_cache[0]||=$event=>shouldShowToggleIcon()?cycleDisplayMode():null},toDisplayString(getTableHeaderLabel()),3),_cache[1]||=createBaseVNode(`div`,{class:`grid-header`},`Duration`,-1),shouldHideVsPrevBest()?createCommentVNode(``,!0):(openBlock(),createElementBlock(`div`,_hoisted_5$75,`Vs prev`)),_cache[2]||=createBaseVNode(`div`,{class:`grid-header`},`Total`,-1),isRacing()&&getCurrentTimeFormatted()?(openBlock(),createElementBlock(Fragment,{key:1},[createBaseVNode(`div`,_hoisted_6$61,toDisplayString(getCurrentItemNumber()),1),createBaseVNode(`div`,_hoisted_7$53,toDisplayString(getCurrentTimeFormatted()),1),shouldHideVsPrevBest()?createCommentVNode(``,!0):(openBlock(),createElementBlock(`div`,{key:0,class:normalizeClass([`grid-item current-item`,getCurrentLapDiffClass()])},toDisplayString(getCurrentDiff()),3)),createBaseVNode(`div`,_hoisted_8$43,toDisplayString(getCurrentTotalTime()),1)],64)):createCommentVNode(``,!0),(openBlock(!0),createElementBlock(Fragment,null,renderList(getFilteredCombinedItems(),item=>(openBlock(),createElementBlock(Fragment,{key:getItemKey(item)},[createBaseVNode(`div`,{class:normalizeClass([`grid-item`,{"best-item left-indicator":item.flavor===`best`,"is-lap":item.type===`lap`}])},toDisplayString(getItemNumber(item)),3),createBaseVNode(`div`,{class:normalizeClass([`grid-item`,{"best-item":item.flavor===`best`}])},toDisplayString(item.durationFormatted),3),shouldHideVsPrevBest()?createCommentVNode(``,!0):(openBlock(),createElementBlock(`div`,{key:0,class:normalizeClass([`grid-item`,[{"best-item":item.flavor===`best`},getDiffClass(item.diffToPreviousFlavor,item.diffToPreviousFormatted)]])},toDisplayString(item.diffToPreviousFormatted||``),3)),createBaseVNode(`div`,{class:normalizeClass([`grid-item`,{"best-item":item.flavor===`best`}])},toDisplayString(item.endTimeFormatted||``),3)],64))),128))],2)])]))}},app_default$31=__plugin_vue_export_helper_default(_sfc_main$157,[[`__scopeId`,`data-v-a9e5d83a`]]),_hoisted_1$140={class:`laptimes-section`},_hoisted_2$118={class:`collapse-icon`},_hoisted_3$106={class:`collapsible-content`},_hoisted_4$86={class:`laptimes-data-grid`},_hoisted_5$74={key:0,class:`data-item`},_hoisted_6$60={class:`value`},_hoisted_7$52={key:1,class:`data-item`},_hoisted_8$42={class:`data-item`},_hoisted_9$39={class:`value`},_hoisted_10$32={class:`data-item`},_hoisted_11$29={class:`value`},_hoisted_12$23={class:`data-item`},_hoisted_13$20={class:`value`},_hoisted_14$20={class:`data-item`},_hoisted_15$19={class:`value`},_hoisted_16$19={key:0,class:`laptimes-data-grid`,style:{"margin-top":`1rem`}},_hoisted_17$15={key:0,class:`data-item`},_hoisted_18$13={key:1,class:`data-item`},_hoisted_19$10={key:1,class:`laptimes-data-grid`,style:{"margin-top":`1rem`}},_hoisted_20$9={key:0,class:`data-item`},_hoisted_21$9={key:1,class:`data-item`},_sfc_main$156={__name:`BasicInfo`,props:{fastData:{type:Object,required:!0},staticData:{type:Object,required:!0},slowData:{type:Object,required:!0}},setup(__props){let isCollapsed=ref(!1),toggleCollapse=()=>{isCollapsed.value=!isCollapsed.value};return(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$140,[createBaseVNode(`h3`,{onClick:toggleCollapse,class:`collapsible-header`},[createBaseVNode(`span`,_hoisted_2$118,toDisplayString(isCollapsed.value?`▶`:`▼`),1),_cache[0]||=createTextVNode(` Race Info `,-1)]),withDirectives(createBaseVNode(`div`,_hoisted_3$106,[createBaseVNode(`div`,_hoisted_4$86,[__props.slowData.status===`started`||__props.slowData.status===`paused`?(openBlock(),createElementBlock(`div`,_hoisted_5$74,[_cache[1]||=createBaseVNode(`span`,{class:`label`},`Current Time:`,-1),createBaseVNode(`span`,_hoisted_6$60,toDisplayString(__props.fastData.currentTimeFormatted||`00:00.000`),1)])):(openBlock(),createElementBlock(`div`,_hoisted_7$52,[_cache[2]||=createBaseVNode(`span`,{class:`label`},`Status:`,-1),createBaseVNode(`span`,{class:normalizeClass([`value`,{active:__props.slowData.status===`started`,paused:__props.slowData.status===`paused`}])},toDisplayString(__props.slowData.status?.toUpperCase()||`STOPPED`),3)])),createBaseVNode(`div`,_hoisted_8$42,[_cache[3]||=createBaseVNode(`span`,{class:`label`},`Lap:`,-1),createBaseVNode(`span`,_hoisted_9$39,toDisplayString(__props.slowData.currentLap||0)+`/`+toDisplayString(__props.staticData.totalLaps||0),1)]),createBaseVNode(`div`,_hoisted_10$32,[_cache[4]||=createBaseVNode(`span`,{class:`label`},`Segment:`,-1),createBaseVNode(`span`,_hoisted_11$29,toDisplayString(__props.slowData.currentSegment||0)+`/`+toDisplayString(__props.staticData.totalSegments||0),1)]),createBaseVNode(`div`,_hoisted_12$23,[_cache[5]||=createBaseVNode(`span`,{class:`label`},`Current Lap Time:`,-1),createBaseVNode(`span`,_hoisted_13$20,toDisplayString(__props.fastData.currentLapTimeFormatted||`00:00.000`),1)]),createBaseVNode(`div`,_hoisted_14$20,[_cache[6]||=createBaseVNode(`span`,{class:`label`},`Current Segment Time:`,-1),createBaseVNode(`span`,_hoisted_15$19,toDisplayString(__props.fastData.currentSegmentTimeFormatted||`00:00.000`),1)])]),__props.fastData.currentLapDiffToBestFormatted||__props.fastData.currentLapDiffToPreviousFormatted?(openBlock(),createElementBlock(`div`,_hoisted_16$19,[__props.fastData.currentLapDiffToBestFormatted?(openBlock(),createElementBlock(`div`,_hoisted_17$15,[_cache[7]||=createBaseVNode(`span`,{class:`label`},`Lap Diff to Best:`,-1),createBaseVNode(`span`,{class:normalizeClass([`value`,`diff-`+(__props.fastData.currentLapDiffToBestFlavor||`default`)])},toDisplayString(__props.fastData.currentLapDiffToBestFormatted),3)])):createCommentVNode(``,!0),__props.fastData.currentLapDiffToPreviousFormatted?(openBlock(),createElementBlock(`div`,_hoisted_18$13,[_cache[8]||=createBaseVNode(`span`,{class:`label`},`Lap Diff to Previous:`,-1),createBaseVNode(`span`,{class:normalizeClass([`value`,`diff-`+(__props.fastData.currentLapDiffToPreviousFlavor||`default`)])},toDisplayString(__props.fastData.currentLapDiffToPreviousFormatted),3)])):createCommentVNode(``,!0)])):createCommentVNode(``,!0),__props.fastData.currentSegmentDiffToBestFormatted||__props.fastData.currentSegmentDiffToPreviousFormatted?(openBlock(),createElementBlock(`div`,_hoisted_19$10,[__props.fastData.currentSegmentDiffToBestFormatted?(openBlock(),createElementBlock(`div`,_hoisted_20$9,[_cache[9]||=createBaseVNode(`span`,{class:`label`},`Segment Diff to Best:`,-1),createBaseVNode(`span`,{class:normalizeClass([`value`,`diff-`+(__props.fastData.currentSegmentDiffToBestFlavor||`default`)])},toDisplayString(__props.fastData.currentSegmentDiffToBestFormatted),3)])):createCommentVNode(``,!0),__props.fastData.currentSegmentDiffToPreviousFormatted?(openBlock(),createElementBlock(`div`,_hoisted_21$9,[_cache[10]||=createBaseVNode(`span`,{class:`label`},`Segment Diff to Previous:`,-1),createBaseVNode(`span`,{class:normalizeClass([`value`,`diff-`+(__props.fastData.currentSegmentDiffToPreviousFlavor||`default`)])},toDisplayString(__props.fastData.currentSegmentDiffToPreviousFormatted),3)])):createCommentVNode(``,!0)])):createCommentVNode(``,!0)],512),[[vShow,!isCollapsed.value]])]))}},BasicInfo_default=__plugin_vue_export_helper_default(_sfc_main$156,[[`__scopeId`,`data-v-4329fa2c`]]),_hoisted_1$139={class:`laptimes-section`},_hoisted_2$117={class:`collapse-icon`},_hoisted_3$105={class:`collapsible-content`},_hoisted_4$85={class:`laptimes-data-grid`,style:{"margin-bottom":`1rem`}},_hoisted_5$73={class:`data-item`},_hoisted_6$59={class:`value`},_hoisted_7$51={key:0,class:`laptimes-data-grid`},_hoisted_8$41={class:`label`},_hoisted_9$38={class:`value`},_sfc_main$155={__name:`BestTimes`,props:{slowData:{type:Object,required:!0}},setup(__props){let props=__props,isCollapsed=ref(!1),toggleCollapse=()=>{isCollapsed.value=!isCollapsed.value},getBestLapDisplay=()=>{let bestTime=props.slowData.bestLapTimeFormatted||`N/A`,bestIndex=props.slowData.bestLapIndex===-1?null:props.slowData.bestLapIndex;return bestTime===`N/A`||bestIndex===null?`N/A`:`${bestTime} in Lap ${bestIndex}`},getBestSegmentDisplayFromData=segmentData=>{if(!segmentData||typeof segmentData!=`object`)return`N/A`;let time=segmentData.time||`N/A`,lap=segmentData.lap;return lap?`${time} in Lap ${lap}`:time};return(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$139,[createBaseVNode(`h3`,{onClick:toggleCollapse,class:`collapsible-header`},[createBaseVNode(`span`,_hoisted_2$117,toDisplayString(isCollapsed.value?`▶`:`▼`),1),_cache[0]||=createTextVNode(` Best Times `,-1)]),withDirectives(createBaseVNode(`div`,_hoisted_3$105,[createBaseVNode(`div`,_hoisted_4$85,[createBaseVNode(`div`,_hoisted_5$73,[_cache[1]||=createBaseVNode(`span`,{class:`label`},`Best Lap:`,-1),createBaseVNode(`span`,_hoisted_6$59,toDisplayString(getBestLapDisplay()),1)])]),__props.slowData.bestSegmentTimesFormatted&&Object.keys(__props.slowData.bestSegmentTimesFormatted).length>0?(openBlock(),createElementBlock(`div`,_hoisted_7$51,[(openBlock(!0),createElementBlock(Fragment,null,renderList(__props.slowData.bestSegmentTimesFormatted,(segmentData,segment)=>(openBlock(),createElementBlock(`div`,{class:`data-item`,key:segment},[createBaseVNode(`span`,_hoisted_8$41,`Best Segment `+toDisplayString(parseInt(segment)+1)+`:`,1),createBaseVNode(`span`,_hoisted_9$38,toDisplayString(getBestSegmentDisplayFromData(segmentData)),1)]))),128))])):createCommentVNode(``,!0)],512),[[vShow,!isCollapsed.value]])]))}},BestTimes_default=__plugin_vue_export_helper_default(_sfc_main$155,[[`__scopeId`,`data-v-3cd1750d`]]),_hoisted_1$138={class:`laptimes-section`},_hoisted_2$116={class:`collapse-icon`},_hoisted_3$104={class:`collapsible-content`},_hoisted_4$84={class:`table-header`},_hoisted_5$72={key:0},_hoisted_6$58={key:1},_hoisted_7$50={key:0,class:`table-row current-lap-row`},_sfc_main$154={__name:`LapTimes`,props:{fastData:{type:Object,required:!0},slowData:{type:Object,required:!0},staticData:{type:Object,required:!0}},setup(__props){let isCollapsed=ref(!1),toggleCollapse=()=>{isCollapsed.value=!isCollapsed.value},getDiffFlavorClass=flavor=>flavor?{"diff-better":flavor===`better`,"diff-worse":flavor===`worse`,"diff-same":flavor===`same`}:``;return(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$138,[createBaseVNode(`h3`,{onClick:toggleCollapse,class:`collapsible-header`},[createBaseVNode(`span`,_hoisted_2$116,toDisplayString(isCollapsed.value?`▶`:`▼`),1),_cache[0]||=createTextVNode(` Lap Times `,-1)]),withDirectives(createBaseVNode(`div`,_hoisted_3$104,[__props.slowData.lapTimes&&__props.slowData.lapTimes.length>0||__props.slowData.status===`started`||__props.slowData.status===`paused`?(openBlock(),createElementBlock(`div`,{key:0,class:normalizeClass([`laptimes-table`,{"single-lap":__props.staticData.totalLaps<=1}])},[createBaseVNode(`div`,_hoisted_4$84,[_cache[1]||=createBaseVNode(`span`,null,`Lap`,-1),_cache[2]||=createBaseVNode(`span`,null,`Time`,-1),_cache[3]||=createBaseVNode(`span`,null,`Duration`,-1),__props.staticData.totalLaps>1?(openBlock(),createElementBlock(`span`,_hoisted_5$72,`Diff to Best`)):createCommentVNode(``,!0),__props.staticData.totalLaps>1?(openBlock(),createElementBlock(`span`,_hoisted_6$58,`Diff to Prev`)):createCommentVNode(``,!0)]),(openBlock(!0),createElementBlock(Fragment,null,renderList(__props.slowData.lapTimes,lap=>(openBlock(),createElementBlock(`div`,{key:lap.lap,class:normalizeClass([`table-row`,{"best-lap":lap.lapFlavor===`best`,"current-lap":lap.isCurrent}])},[createBaseVNode(`span`,null,toDisplayString(lap.lap),1),createBaseVNode(`span`,null,toDisplayString(lap.timeFormatted||lap.endTimeFormatted||`N/A`),1),createBaseVNode(`span`,null,toDisplayString(lap.durationFormatted),1),__props.staticData.totalLaps>1?(openBlock(),createElementBlock(`span`,{key:0,class:normalizeClass(getDiffFlavorClass(lap.diffToBestFlavor))},toDisplayString(lap.diffToBestFormatted||`N/A`),3)):createCommentVNode(``,!0),__props.staticData.totalLaps>1?(openBlock(),createElementBlock(`span`,{key:1,class:normalizeClass(getDiffFlavorClass(lap.diffToPreviousFlavor))},toDisplayString(lap.diffToPreviousFormatted||`N/A`),3)):createCommentVNode(``,!0)],2))),128)),(__props.slowData.status===`started`||__props.slowData.status===`paused`)&&__props.fastData.currentLapTimeFormatted?(openBlock(),createElementBlock(`div`,_hoisted_7$50,[createBaseVNode(`span`,null,toDisplayString(__props.slowData.currentLap||1),1),createBaseVNode(`span`,null,toDisplayString(__props.fastData.currentTimeFormatted),1),createBaseVNode(`span`,null,toDisplayString(__props.fastData.currentLapTimeFormatted),1),__props.staticData.totalLaps>1?(openBlock(),createElementBlock(`span`,{key:0,class:normalizeClass(getDiffFlavorClass(__props.fastData.currentLapDiffToBestFlavor))},toDisplayString(__props.fastData.currentLapDiffToBestFormatted||`N/A`),3)):createCommentVNode(``,!0),__props.staticData.totalLaps>1?(openBlock(),createElementBlock(`span`,{key:1,class:normalizeClass(getDiffFlavorClass(__props.fastData.currentLapDiffToPreviousFlavor))},toDisplayString(__props.fastData.currentLapDiffToPreviousFormatted||`N/A`),3)):createCommentVNode(``,!0)])):createCommentVNode(``,!0)],2)):createCommentVNode(``,!0)],512),[[vShow,!isCollapsed.value]])]))}},LapTimes_default=__plugin_vue_export_helper_default(_sfc_main$154,[[`__scopeId`,`data-v-ed892fc5`]]),_hoisted_1$137={class:`laptimes-section`},_hoisted_2$115={class:`collapse-icon`},_hoisted_3$103={class:`collapsible-content`},_hoisted_4$83={class:`table-header`},_hoisted_5$71={key:0},_hoisted_6$57={key:1},_hoisted_7$49={key:0,class:`table-row current-segment-row`},_sfc_main$153={__name:`SegmentTimes`,props:{fastData:{type:Object,required:!0},slowData:{type:Object,required:!0},staticData:{type:Object,required:!0}},setup(__props){let isCollapsed=ref(!1),toggleCollapse=()=>{isCollapsed.value=!isCollapsed.value},getDiffFlavorClass=flavor=>flavor?{"diff-better":flavor===`better`,"diff-worse":flavor===`worse`,"diff-same":flavor===`same`}:``;return(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$137,[createBaseVNode(`h3`,{onClick:toggleCollapse,class:`collapsible-header`},[createBaseVNode(`span`,_hoisted_2$115,toDisplayString(isCollapsed.value?`▶`:`▼`),1),_cache[0]||=createTextVNode(` Segment Times `,-1)]),withDirectives(createBaseVNode(`div`,_hoisted_3$103,[__props.slowData.segmentTimes&&__props.slowData.segmentTimes.length>0||__props.slowData.status===`started`||__props.slowData.status===`paused`?(openBlock(),createElementBlock(`div`,{key:0,class:normalizeClass([`laptimes-table`,{"single-lap":__props.staticData.totalLaps<=1}])},[createBaseVNode(`div`,_hoisted_4$83,[_cache[1]||=createBaseVNode(`span`,null,`Segment`,-1),_cache[2]||=createBaseVNode(`span`,null,`Time`,-1),_cache[3]||=createBaseVNode(`span`,null,`Duration`,-1),__props.staticData.totalLaps>1?(openBlock(),createElementBlock(`span`,_hoisted_5$71,`Diff to Best`)):createCommentVNode(``,!0),__props.staticData.totalLaps>1?(openBlock(),createElementBlock(`span`,_hoisted_6$57,`Diff to Prev`)):createCommentVNode(``,!0)]),(openBlock(!0),createElementBlock(Fragment,null,renderList(__props.slowData.segmentTimes,segment=>(openBlock(),createElementBlock(`div`,{key:segment.segment,class:normalizeClass([`table-row`,{"best-segment":segment.segmentFlavor===`best`,"current-segment":segment.isCurrent}])},[createBaseVNode(`span`,null,toDisplayString(segment.segment),1),createBaseVNode(`span`,null,toDisplayString(segment.timeFormatted||segment.endTimeFormatted||`N/A`),1),createBaseVNode(`span`,null,toDisplayString(segment.durationFormatted),1),__props.staticData.totalLaps>1?(openBlock(),createElementBlock(`span`,{key:0,class:normalizeClass(getDiffFlavorClass(segment.diffToBestFlavor))},toDisplayString(segment.diffToBestFormatted||`N/A`),3)):createCommentVNode(``,!0),__props.staticData.totalLaps>1?(openBlock(),createElementBlock(`span`,{key:1,class:normalizeClass(getDiffFlavorClass(segment.diffToPreviousFlavor))},toDisplayString(segment.diffToPreviousFormatted||`N/A`),3)):createCommentVNode(``,!0)],2))),128)),(__props.slowData.status===`started`||__props.slowData.status===`paused`)&&__props.fastData.currentSegmentTimeFormatted?(openBlock(),createElementBlock(`div`,_hoisted_7$49,[createBaseVNode(`span`,null,toDisplayString(__props.slowData.currentLap||1)+`-`+toDisplayString(__props.slowData.currentSegment||1),1),createBaseVNode(`span`,null,toDisplayString(__props.fastData.currentTimeFormatted),1),createBaseVNode(`span`,null,toDisplayString(__props.fastData.currentSegmentTimeFormatted),1),__props.staticData.totalLaps>1?(openBlock(),createElementBlock(`span`,{key:0,class:normalizeClass(getDiffFlavorClass(__props.fastData.currentSegmentDiffToBestFlavor))},toDisplayString(__props.fastData.currentSegmentDiffToBestFormatted||`N/A`),3)):createCommentVNode(``,!0),__props.staticData.totalLaps>1?(openBlock(),createElementBlock(`span`,{key:1,class:normalizeClass(getDiffFlavorClass(__props.fastData.currentSegmentDiffToPreviousFlavor))},toDisplayString(__props.fastData.currentSegmentDiffToPreviousFormatted||`N/A`),3)):createCommentVNode(``,!0)])):createCommentVNode(``,!0)],2)):createCommentVNode(``,!0)],512),[[vShow,!isCollapsed.value]])]))}},SegmentTimes_default=__plugin_vue_export_helper_default(_sfc_main$153,[[`__scopeId`,`data-v-3801fbed`]]),_hoisted_1$136={key:0,class:`laptimes-section`},_hoisted_2$114={class:`collapse-icon`},_hoisted_3$102={class:`collapsible-content`},_hoisted_4$82={class:`laptimes-data-grid`,style:{"margin-bottom":`1rem`}},_hoisted_5$70={class:`data-item`},_hoisted_6$56={class:`value`},_hoisted_7$48={class:`data-item`},_hoisted_8$40={class:`value`},_hoisted_9$37={class:`laptimes-table`},_hoisted_10$31={class:`table-header`},_hoisted_11$28={key:0},_hoisted_12$22={key:1},_hoisted_13$19={key:0},_hoisted_14$19={key:1},_sfc_main$152={__name:`Placement`,props:{fastData:{type:Object,required:!0},slowData:{type:Object,required:!0},staticData:{type:Object,required:!0},placementData:{type:Object,required:!0}},setup(__props){let props=__props,isCollapsed=ref(!1),toggleCollapse=()=>{isCollapsed.value=!isCollapsed.value},playerVehicleId=computed(()=>{if(props.placementData.vehicleStates){let vehicleIds=Object.keys(props.placementData.vehicleStates);return vehicleIds.length>0?parseInt(vehicleIds[0]):null}return null}),playerPlacement=computed(()=>!playerVehicleId.value||!props.placementData.placements?null:props.placementData.placements[playerVehicleId.value]),totalRacers=computed(()=>props.placementData.placements?Object.keys(props.placementData.placements).length:0),shouldShowLapColumn=computed(()=>{if(!props.staticData.pathConfig)return!1;let pathConfig=props.staticData.pathConfig;return pathConfig.isClosed&&pathConfig.lapCount>1}),shouldShowSegmentColumn=computed(()=>{if(!props.staticData.pathConfig)return!1;let pathConfig=props.staticData.pathConfig;return!pathConfig.isClosed||pathConfig.isClosed&&pathConfig.lapCount>1}),sortedRacers=computed(()=>{if(!props.placementData.placements||!props.placementData.vehicleStates)return[];let racers=[];return Object.entries(props.placementData.placements).forEach(([vehicleId,placement])=>{let vehicleIdNum=parseInt(vehicleId),vehicleState=props.placementData.vehicleStates[vehicleId],timeDiffData=props.placementData.timeDifferencesToFirst?.[vehicleId],timeDiff=timeDiffData?.timeDifference||0;racers.push({vehicleId:vehicleIdNum,placement,currentLap:vehicleState?.currentLap||0,currentSegment:vehicleState?.currentSegment||0,isPlayer:vehicleIdNum===playerVehicleId.value,timeDiff,timeDiffFormatted:timeDiffData?.timeDifferenceFormatted||`0.000`})}),racers.sort((a$1,b)=>a$1.placement-b.placement)}),getTimeDiffClass=timeDiff=>timeDiff==null?``:{"diff-red":timeDiff>0,"diff-green":timeDiff<0,"diff-neutral":timeDiff===0};return(_ctx,_cache)=>__props.placementData.placements&&Object.keys(__props.placementData.placements).length>1?(openBlock(),createElementBlock(`div`,_hoisted_1$136,[createBaseVNode(`h3`,{onClick:toggleCollapse,class:`collapsible-header`},[createBaseVNode(`span`,_hoisted_2$114,toDisplayString(isCollapsed.value?`▶`:`▼`),1),_cache[0]||=createTextVNode(` Race Positions `,-1)]),withDirectives(createBaseVNode(`div`,_hoisted_3$102,[createBaseVNode(`div`,_hoisted_4$82,[createBaseVNode(`div`,_hoisted_5$70,[_cache[1]||=createBaseVNode(`span`,{class:`label`},`Your Position:`,-1),createBaseVNode(`span`,_hoisted_6$56,toDisplayString(playerPlacement.value||`N/A`),1)]),createBaseVNode(`div`,_hoisted_7$48,[_cache[2]||=createBaseVNode(`span`,{class:`label`},`Total Racers:`,-1),createBaseVNode(`span`,_hoisted_8$40,toDisplayString(totalRacers.value),1)])]),createBaseVNode(`div`,_hoisted_9$37,[createBaseVNode(`div`,_hoisted_10$31,[_cache[3]||=createBaseVNode(`span`,null,`Pos`,-1),_cache[4]||=createBaseVNode(`span`,null,`Vehicle`,-1),shouldShowLapColumn.value?(openBlock(),createElementBlock(`span`,_hoisted_11$28,`Lap`)):createCommentVNode(``,!0),shouldShowSegmentColumn.value?(openBlock(),createElementBlock(`span`,_hoisted_12$22,`Segment`)):createCommentVNode(``,!0),_cache[5]||=createBaseVNode(`span`,null,`Time Diff`,-1)]),(openBlock(!0),createElementBlock(Fragment,null,renderList(sortedRacers.value,(racer,index)=>(openBlock(),createElementBlock(`div`,{key:racer.vehicleId,class:normalizeClass([`table-row`,{"player-row":racer.isPlayer,"leader-row":index===0}])},[createBaseVNode(`span`,null,toDisplayString(racer.placement),1),createBaseVNode(`span`,null,toDisplayString(racer.vehicleId===playerVehicleId.value?`You`:`Vehicle ${racer.vehicleId}`),1),shouldShowLapColumn.value?(openBlock(),createElementBlock(`span`,_hoisted_13$19,toDisplayString(racer.currentLap||0),1)):createCommentVNode(``,!0),shouldShowSegmentColumn.value?(openBlock(),createElementBlock(`span`,_hoisted_14$19,toDisplayString(racer.currentSegment||0),1)):createCommentVNode(``,!0),createBaseVNode(`span`,{class:normalizeClass(getTimeDiffClass(racer.timeDiff))},toDisplayString(racer.timeDiffFormatted),3)],2))),128))])],512),[[vShow,!isCollapsed.value]])])):createCommentVNode(``,!0)}},Placement_default=__plugin_vue_export_helper_default(_sfc_main$152,[[`__scopeId`,`data-v-c2373a09`]]),_hoisted_1$135={class:`laptimes-section`},_hoisted_2$113={class:`collapse-icon`},_hoisted_3$101={class:`collapsible-content`},_hoisted_4$81={class:`raw-data-container`},_hoisted_5$69={key:0,class:`data-stream`},_hoisted_6$55={class:`data-content`},_hoisted_7$47={key:1,class:`data-stream`},_hoisted_8$39={class:`data-content`},_hoisted_9$36={key:2,class:`data-stream`},_hoisted_10$30={class:`data-content`},_hoisted_11$27={key:3,class:`data-stream`},_hoisted_12$21={class:`data-content`},_sfc_main$151={__name:`RawData`,props:{fastData:{type:Object,required:!0},slowData:{type:Object,required:!0},staticData:{type:Object,required:!0},placementData:{type:Object,required:!0}},setup(__props){let isCollapsed=ref(!0),toggleCollapse=()=>{isCollapsed.value=!isCollapsed.value};return(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$135,[createBaseVNode(`h3`,{onClick:toggleCollapse,class:`collapsible-header`},[createBaseVNode(`span`,_hoisted_2$113,toDisplayString(isCollapsed.value?`▶`:`▼`),1),_cache[0]||=createTextVNode(` Raw Stream Data `,-1)]),withDirectives(createBaseVNode(`div`,_hoisted_3$101,[createBaseVNode(`div`,_hoisted_4$81,[__props.fastData?(openBlock(),createElementBlock(`div`,_hoisted_5$69,[createBaseVNode(`h4`,null,`Fast Stream Data `+toDisplayString(__props.fastData.timestamp),1),createBaseVNode(`pre`,_hoisted_6$55,toDisplayString(JSON.stringify(__props.fastData,null,1)),1)])):createCommentVNode(``,!0),__props.slowData?(openBlock(),createElementBlock(`div`,_hoisted_7$47,[createBaseVNode(`h4`,null,`Slow Stream Data `+toDisplayString(__props.slowData.timestamp),1),createBaseVNode(`pre`,_hoisted_8$39,toDisplayString(JSON.stringify(__props.slowData,null,1)),1)])):createCommentVNode(``,!0),__props.staticData?(openBlock(),createElementBlock(`div`,_hoisted_9$36,[createBaseVNode(`h4`,null,`Static Stream Data `+toDisplayString(__props.staticData.timestamp),1),createBaseVNode(`pre`,_hoisted_10$30,toDisplayString(JSON.stringify(__props.staticData,null,1)),1)])):createCommentVNode(``,!0),__props.placementData?(openBlock(),createElementBlock(`div`,_hoisted_11$27,[createBaseVNode(`h4`,null,`Placement Stream Data `+toDisplayString(__props.placementData.timestamp),1),createBaseVNode(`pre`,_hoisted_12$21,toDisplayString(JSON.stringify(__props.placementData,null,1)),1)])):createCommentVNode(``,!0)])],512),[[vShow,!isCollapsed.value]])]))}},RawData_default=__plugin_vue_export_helper_default(_sfc_main$151,[[`__scopeId`,`data-v-7bc3ab60`]]),_hoisted_1$134={class:`laptimes-app`,style:{"overflow-y":`scroll`}},_sfc_main$150={__name:`appDebug`,setup(__props){useEvents();let fastData=ref({}),slowData=ref({}),staticData=ref({}),placementData=ref({});return onMounted(()=>{useStreams([`lapTimes_fast`,`lapTimes_slow`,`lapTimes_static`,`lapTimes_placement`],streams=>{streams.lapTimes_fast&&(fastData.value=streams.lapTimes_fast),streams.lapTimes_slow&&(slowData.value=streams.lapTimes_slow),streams.lapTimes_static&&(staticData.value=streams.lapTimes_static),streams.lapTimes_placement&&(placementData.value=streams.lapTimes_placement)})}),onUnmounted(()=>{}),(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$134,[_cache[0]||=createBaseVNode(`div`,{class:`laptimes-header`},[createBaseVNode(`h2`,null,`Lap Times Debug`)],-1),createVNode(BasicInfo_default,{fastData:fastData.value,slowData:slowData.value,staticData:staticData.value},null,8,[`fastData`,`slowData`,`staticData`]),createVNode(BestTimes_default,{slowData:slowData.value},null,8,[`slowData`]),createVNode(LapTimes_default,{fastData:fastData.value,slowData:slowData.value,staticData:staticData.value},null,8,[`fastData`,`slowData`,`staticData`]),createVNode(SegmentTimes_default,{fastData:fastData.value,slowData:slowData.value,staticData:staticData.value},null,8,[`fastData`,`slowData`,`staticData`]),createVNode(Placement_default,{fastData:fastData.value,slowData:slowData.value,staticData:staticData.value,placementData:placementData.value},null,8,[`fastData`,`slowData`,`staticData`,`placementData`]),createVNode(RawData_default,{fastData:fastData.value,slowData:slowData.value,staticData:staticData.value,placementData:placementData.value},null,8,[`fastData`,`slowData`,`staticData`,`placementData`])]))}},appDebug_default$1=__plugin_vue_export_helper_default(_sfc_main$150,[[`__scopeId`,`data-v-49102eaf`]]),_hoisted_1$133={class:`messages-app`},_hoisted_2$112={key:0,class:`icon-cell`},_hoisted_3$100={class:`text-cell`},_hoisted_4$80={key:0},timerIntervalMs=300,_sfc_main$149={__name:`app`,props:{maxMessages:{type:Number,default:void 0},dense:{type:Boolean,default:!1},wrap:{type:Boolean,default:!0},showIcons:{type:Boolean,default:!0}},setup(__props){let props=__props,events$3=useEvents(),messagesByCategory=reactive({}),bypassTtl=ref(!1),getIconProps=item=>{let icon=resolvedType(item.icon);if(icon)return{type:icon};let externalImage=resolvedExternalImage(item.icon);return externalImage?{externalImage}:{type:`info`}},timerId,isAssetPath=icon=>typeof icon==`string`&&icon.startsWith(`/`),resolvedType=icon=>typeof icon==`string`&&!isAssetPath(icon)?icon:void 0,resolvedExternalImage=icon=>typeof icon==`string`&&isAssetPath(icon)?icon:void 0,messagesList=computed(()=>{let list=Object.values(messagesByCategory);return typeof props.maxMessages==`number`&&props.maxMessages>0?list.slice(0,props.maxMessages):list});function resolveTranslation(val){return val==null?``:typeof val==`string`?$translate.instant(val):Array.isArray(val)?$translate.multiContextTranslate(val):typeof val==`object`?$translate.contextTranslate(val):String(val)}function htmlToPlainText(html){if(typeof html!=`string`)return String(html??``);let h$1=html.replace(//gi,` `),el=document.createElement(`div`);el.innerHTML=h$1;let text=el.textContent??el.innerText??h$1;return text=text.replace(/<[^>]*>/g,``),text}function sanitizeTextSegment(text){return text?htmlToPlainText(parse$1?parse$1(text):text):``}function getParts(item){let raw=resolveTranslation(item.text);if(typeof raw!=`string`)return[{t:`text`,v:sanitizeTextSegment(String(raw))}];let parts=[],rgx=/\[action=([^\]]+)\]/gi,lastIndex=0,match;for(;(match=rgx.exec(raw))!==null;){let head=raw.slice(lastIndex,match.index);head&&parts.push({t:`text`,v:sanitizeTextSegment(head)});let actionName=match[1].trim();parts.push({t:`binding`,action:actionName}),lastIndex=match.index+match[0].length}let tail=raw.slice(lastIndex);return tail&&parts.push({t:`text`,v:sanitizeTextSegment(tail)}),parts.length?parts:[{t:`text`,v:sanitizeTextSegment(raw)}]}function normalizePayload(args){let category=args?.category??`default`,clear=!!args?.clear,text=args&&`text`in args?args.text:args&&`msg`in args?args.msg:``,icon=typeof args?.icon==`string`?args.icon:void 0,ttlMs=typeof args?.ttlMs==`number`?args.ttlMs:typeof args?.ttl==`number`?args.ttl*1e3:void 0;return ttlMs??=5e3,{category,clear,text,icon,ttlMs}}let CATEGORY_ICONS=[{match:`vehicle.absBehavior`,icon:`ABSIndicator`},{match:`vehicle.brakingdistance`,icon:`carsFollow`},{prefix:`vehicle.compressionBrake.`,icon:`engine`},{prefix:`vehicle.damage.exhaust`,icon:`exhaustMuffler`},{prefix:`vehicle.damage.deflated.`,icon:`tireDeflated`},{prefix:`vehicle.beamstate.tireDeflated`,icon:`tireDeflated`},{match:`vehicle.damage.mildOverrev`,icon:`powerGauge05`},{match:`vehicle.damage.catastrophicOverrev`,icon:`powerGauge05`},{match:`vehicle.damage.catastrophicOverTorque`,icon:`cogDamaged`},{match:`vehicle.damage.flood`,icon:`water`},{match:`vehicle.engine.isStalling`,icon:`powerGauge01`},{match:`vehicle.ignition.ignitionLevel`,icon:`keys1`},{match:`vehicle.lightbar.mode`,icon:`wigwags`},{match:`vehicle.linelock.status`,icon:`wheelDisc`},{match:`vehicle.postCrashBrake.impact`,icon:`hazardLights`},{prefix:`vehicle.powertrain.diffmode.`,icon:`drivetrainGeneric`},{match:`vehicle.powertrain.nitrousOxideInjection`,icon:`N2OHoriz`},{match:`vehicle.shiftLogic.cannotShift`,icon:`cogsDamaged`},{match:`vehicle.shiftermode`,icon:`transmissionM`},{match:`vehicle.transbrake.status`,icon:`cogs`},{match:`vehicle.twoStep.status`,icon:`signal04a`},{match:`vehicle.tirePressureControl.inflateDeflate`,icon:`tirePressureGaugeOutlined03`},{prefix:`vehicle.wheels.tirePunctured.`,icon:`tireAirPuff`},{prefix:`vehicle.damage.device.`,icon:`cogDamaged`},{match:`vehicle.driveModes`,icon:`ESC`},{prefix:`vehicle.driveModes.`,icon:`ESC`},{match:`vehicle.engine.oilOverheating.true`,icon:`coolantTemp`},{match:`vehicle.engine.blockMelted.true`,icon:`coolantTemp`},{match:`vehicle.engine.headGasketDamaged.true`,icon:`coolantTemp`},{match:`vehicle.engine.coolantOverheating.true`,icon:`coolantTemp`},{match:`vehicle.engine.radiatorLeak.true`,icon:`coolantTemp`},{prefix:`vehicle.engine.`,icon:`engine`},{prefix:`vehicle.recovery.`,icon:`tow`},{match:`rally`,icon:`rallyHelmet`},{match:`fill`,icon:`import`},{match:`align`,icon:`flag`},{match:`delivery`,icon:`boxTruckFast`},{match:`refueling`,icon:`fuelPumpFilling`},{prefix:`refueling-`,icon:`fuelPumpFilling`},{prefix:`ui.camera.`,icon:`movieCamera`},{match:`input`,icon:`gamepad`},{prefix:`ui.apps.damage_app_vehicle_simple.component.`,icon:`cogsDamaged`},{match:`AI debug`,icon:`AIMicrochip`},{match:`debug`,icon:`code`},{match:`hydros`,icon:`steeringWheelCommon`},{match:`GLTFexport`,icon:`loadMesh`},{match:`bigmap.info.reachedTarget`,icon:`raceFlag`}];function deriveIconForCategory(category){if(!category)return`info`;console.debug(`[messages] deriveIconForCategory`,category);for(let{match,prefix:prefix$1,icon}of CATEGORY_ICONS){if(match&&category===match)return console.debug(` -> match:`,match,icon),icon;if(prefix$1&&category.startsWith(prefix$1))return console.debug(` -> prefix:`,prefix$1,icon),icon}return console.debug(` -> no match, fallback to info`),`info`}function onMessage(args){let{category,clear,text,icon,ttlMs}=normalizePayload(args),matched=[];try{let re=new RegExp(category);matched=Object.keys(messagesByCategory).filter(k=>re.test(k))}catch{}matched.length===0&&(matched=[category]);for(let cat of matched){if(clear||typeof text==`string`&&text===``){delete messagesByCategory[cat];continue}let offset$2=Object.keys(messagesByCategory).length*timerIntervalMs*2;messagesByCategory[cat]={_key:cat,text,icon:icon||deriveIconForCategory(cat),ttl:ttlMs+offset$2}}}function onClearAll(){for(let k in messagesByCategory)delete messagesByCategory[k]}function tick(){for(let k in messagesByCategory){let m=messagesByCategory[k];bypassTtl.value||(m.ttl-=timerIntervalMs),m.ttl<=0&&delete messagesByCategory[k]}}return onMounted(()=>{events$3.on(`Message`,onMessage),events$3.on(`ClearAllMessages`,onClearAll),events$3.on(`MessagesDebug`,data=>{data&&typeof data.bypassTtl==`boolean`&&(bypassTtl.value=!!data.bypassTtl)}),timerId=window.setInterval(tick,timerIntervalMs)}),onUnmounted(()=>{timerId&&window.clearInterval(timerId)}),(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$133,[(openBlock(!0),createElementBlock(Fragment,null,renderList(messagesList.value,item=>(openBlock(),createElementBlock(`div`,{key:item._key,class:`message-row`},[__props.showIcons&&item.icon?(openBlock(),createElementBlock(`div`,_hoisted_2$112,[createVNode(unref(bngIcon_default),mergeProps({class:`msg-icon`,fallbackType:`info`},{ref_for:!0},getIconProps(item)),null,16)])):createCommentVNode(``,!0),createBaseVNode(`div`,_hoisted_3$100,[(openBlock(!0),createElementBlock(Fragment,null,renderList(getParts(item),(part,i)=>(openBlock(),createElementBlock(Fragment,{key:i},[part.t===`text`?(openBlock(),createElementBlock(`span`,_hoisted_4$80,toDisplayString(part.v),1)):(openBlock(),createBlock(unref(bngBinding_default),{key:1,action:part.action,"show-unassigned":``},null,8,[`action`]))],64))),128))])]))),128))]))}},app_default$32=__plugin_vue_export_helper_default(_sfc_main$149,[[`__scopeId`,`data-v-ddfd9832`]]),apps_exports=__export({advancedWheelsDebug:()=>app_default$2,brakeTorqueGraph:()=>app_default$3,busLine:()=>app_default$4,cameraDistance:()=>app_default$5,clutchThermalDebug:()=>app_default$6,compass:()=>app_default$7,compassPrecise:()=>app_default$8,countdown:()=>countdownApp_default,crashTestNextStep:()=>app_default$15,damageApp:()=>app_default$9,dragRace:()=>app_default$10,dragRaceStage:()=>app_default$12,dragRaceTree:()=>app_default$11,driftCurrentDrift:()=>app_default$13,driftScores:()=>app_default$14,engineDebug:()=>app_default$16,engineDynamometer:()=>app_default$17,engineHeatDebugGraph:()=>app_default$18,engineThermalDebug:()=>app_default$19,forcedInduction:()=>app_default$20,forcedInductionDebug:()=>app_default$21,gameplayApps:()=>gameplayApps_default,genericMissionData:()=>bngGenericMissionData_default,hydraulicsDebug:()=>app_default$22,inputHints:()=>app_default$29,keyList:()=>app_default$23,lapTimes:()=>app_default$31,lapTimesDebug:()=>appDebug_default$1,logvehiclestats:()=>app_default$24,messages:()=>app_default$32,messagesTasksApps:()=>messagesTasksApps_default,navigation:()=>app_default$30,pointsBar:()=>app_default,rallyCountdown:()=>appCountdown_default,rallyDashboard:()=>appDashboard_default,rallyDebug:()=>appDebug_default,rallyStageProgress:()=>appStageProgress_default,rallyStageTiming:()=>appStageTiming_default,rallyTimecard:()=>appTimecard_default,rallyVisualPacenotes:()=>app_default$28,replayAppV2:()=>app_default$1,simpleDigTacho:()=>app_default$25,simpleFlashMessage:()=>flashMessageApp_default,tacho2:()=>app_default$26,tasklist:()=>app_default$27});const useTuningStore=defineStore(`tuning`,()=>{let{lua,events:events$3}=useBridge(),buckets=ref({}),tuningVariables=ref({}),editedTuningVars={},isCareer=!1,shoppingData=ref({}),noapi=()=>{throw Error(`Tuning store must be initialised first`)},api$1={request:noapi,apply:noapi,reset:noapi,close:()=>{},menuClose:()=>{}};async function init$3(){for(let name in editedTuningVars={},isCareer=await lua.career_career.isActive(),isCareer?(api$1.request=async()=>processTuningData(await lua.career_modules_tuning.getTuningData()),api$1.apply=(values,edited)=>{let res={};for(let[varName,_]of Object.entries(edited))res[varName]=valDisToVal(values[varName]);lua.career_modules_tuning.apply(res)},api$1.reset=()=>{},api$1.close=()=>{events$3.off(`sendTuningShoppingData`,setShoppingData),events$3.off(`updateTuningVariable`,updateTuningVariable),shoppingData.value={}},events$3.on(`sendTuningShoppingData`,setShoppingData),events$3.on(`updateTuningVariable`,updateTuningVariable)):(api$1.request=async()=>await lua.extensions.core_vehicle_partmgmt.sendDataToUI(),api$1.apply=(values,edited)=>{let res={};for(let varName in values)res[varName]=valDisToVal(values[varName]);lua.extensions.core_vehicle_partmgmt.setConfigVars(res)},api$1.reset=async()=>await lua.extensions.core_vehicle_partmgmt.resetVarsToLoadedConfig(),api$1.close=()=>{events$3.off(`VehicleFocusChanged`,api$1.request),events$3.off(`VehicleConfigChange`,processTuningData)},api$1.menuClose=api$1.close,events$3.on(`VehicleFocusChanged`,api$1.request),events$3.on(`VehicleConfigChange`,processTuningData)),api$1)api$1[name]===noapi&&(api$1[name]=()=>{})}function apply$1(){api$1.apply(tuningVariables.value,editedTuningVars),editedTuningVars={}}function setShoppingData(data){shoppingData.value=data}function updateTuningVariable(tuningVar){tuningVariables.value[tuningVar.name].valDis=Number(valToValDis(tuningVar))}let processTuningData=data=>{data.variables&&(data=data.variables),isCareer&&(delete data.$fuel,delete data.$fuel_R,delete data.$fuel_L),buckets.value=[],tuningVariables.value={};for(let varData of Object.values(data)){if(isCareer&&varData.category===`Cargo`||varData.hideInUI)continue;varData.category||=`Other`,varData.subCategory||=`Other`;let cat=(buckets.value.find(cat$1=>cat$1.name===varData.category)||buckets.value[buckets.value.push({name:varData.category,items:[]})-1]).items;(cat.find(sub=>sub.name===varData.subCategory)||cat[cat.push({name:varData.subCategory,items:[]})-1]).items.push(varData),tuningVariables.value[varData.name]={valDis:Number(valToValDis(varData)),minDis:varData.minDis,maxDis:varData.maxDis,min:varData.min,max:varData.max,default:Number(valToValDis(varData,!0))}}let sorter=(a$1,b)=>a$1.name.localeCompare(b.name);buckets.value.sort(sorter);for(let cat of buckets.value){cat.items.sort(sorter);for(let sub of cat.items)sub.items.sort(sorter)}};function countDecimals(num){return typeof num!=`number`||~~num===num?0:num.toString().split(`.`)[1].length||0}function valToValDis(varData,useDef=!1){return roundDec(round(((useDef?varData.default:varData.val)-varData.min)/(varData.max-varData.min)*(varData.maxDis-varData.minDis),varData.stepDis)+varData.minDis,countDecimals(varData.stepDis))}function valDisToVal(varData){return(varData.valDis-varData.minDis)/(varData.maxDis-varData.minDis)*(varData.max-varData.min)+varData.min}function tuningVarChanged(varName){editedTuningVars[varName]=!0}return{init:init$3,buckets,tuningVariables,shoppingData,apply:apply$1,requestInitialData:()=>api$1.request(),close:()=>api$1.close(),notifyOnMenuClosed:()=>api$1.menuClose(),tuningVarChanged,resetTuningData:()=>api$1.reset()}});var _hoisted_1$132={key:0,class:`tuning-form`},_hoisted_2$111={key:0,class:`extra-features`},_hoisted_3$99={class:`category-heading`},_hoisted_4$79={class:`category-name`},_hoisted_5$68={key:0,class:`subcategory-heading`},_hoisted_6$54={class:`subcategory-name`},_hoisted_7$46={class:`variable-title`},_hoisted_8$38={class:`variable-box`},_hoisted_9$35={class:`tuning-static`},_hoisted_10$29={class:`buttons`},_sfc_main$148={__name:`Tuning`,props:{withBackground:Boolean,buttonTarget:{type:Object},closeButton:Boolean},setup(__props,{expose:__expose}){useUINavBlocker().blockOnly([`context`]);let{lua}=useBridge(),tuningStore=useTuningStore(),awdApp=ref(),awdShow=ref(!1),apply$1=()=>{tuningStore.apply()},close=()=>{tuningStore.close()},mirrorsShown=ref(!0),mirrorsEnabled=ref(!1),mirrorsRoute=`menu.vehicleconfig.tuning.mirrors`,toMirrors=()=>{window.bngVue.gotoGameState(mirrorsRoute)},inputs=ref([]),isChanged=computed(()=>inputs.value.some(ipt=>ipt.dirty));__expose({apply:apply$1,close});let autoApply=ref(!1),applyDebounce=debounce(apply$1,1e3);function onChange(varName){tuningStore.tuningVarChanged(varName),autoApply.value&&applyDebounce()}let applySettingChanged=val=>localStorage.setItem(`applyTuningChangesAutomatically`,JSON.stringify(val));watch(()=>tuningStore.buckets,()=>nextTick(()=>{for(let ipt of inputs.value)ipt.markClean()}));async function resetVarsToLoadedConfig(){tuningStore.resetTuningData(),await tuningStore.requestInitialData(),await nextTick();for(let ipt of inputs.value)ipt.markClean()}onBeforeMount(async()=>{let optAutoApply=localStorage.getItem(`applyTuningChangesAutomatically`);if(optAutoApply)try{autoApply.value=!!JSON.parse(optAutoApply)}catch{}await lua.extensions.gameplay_garageMode.isActive()&&(mirrorsRoute=`menu.vehicleconfig.tuning.mirrors.in-garage`),await lua.career_career.isActive()?mirrorsShown.value=!1:mirrorsEnabled.value=(await useSettingsAsync()).values.GraphicDynMirrorsEnabled,await tuningStore.init(),await tuningStore.requestInitialData(),getUINavServiceInstance().setFilteredEvents(UI_EVENT_GROUPS.focusMoveScalar)});let extraFeatures=computed(()=>{let features=[];return mirrorsEnabled.value&&features.push({mirrorsEnabled:!0}),features});return onUnmounted(async()=>{await tuningStore.notifyOnMenuClosed(),tuningStore.close(),tuningStore.$dispose(),getUINavServiceInstance().clearFilteredEvents()}),(_ctx,_cache)=>withDirectives((openBlock(),createElementBlock(`div`,{class:normalizeClass({innerTuningCard:!0,"with-background":__props.withBackground})},[unref(tuningStore).buckets?(openBlock(),createElementBlock(`div`,_hoisted_1$132,[extraFeatures.value.length>0?(openBlock(),createElementBlock(`div`,_hoisted_2$111,[withDirectives((openBlock(),createBlock(unref(bngButton_default),{onClick:toMirrors,accent:`secondary`},{default:withCtx(()=>[createTextVNode(toDisplayString(_ctx.$t(`ui.mirrors.name`)),1)]),_:1})),[[unref(BngDisabled_default),!extraFeatures.value.find(f=>f.mirrorsEnabled)]])])):createCommentVNode(``,!0),(openBlock(!0),createElementBlock(Fragment,null,renderList(unref(tuningStore).buckets,category=>(openBlock(),createElementBlock(`div`,{class:`tuning-category`,key:category.name},[createBaseVNode(`h2`,_hoisted_3$99,[createBaseVNode(`span`,_hoisted_4$79,toDisplayString(category.name),1)]),(openBlock(!0),createElementBlock(Fragment,null,renderList(category.items,subCategory=>(openBlock(),createElementBlock(`div`,{class:`tuning-subcategory`,key:subCategory.name},[subCategory.name===`Other`?createCommentVNode(``,!0):(openBlock(),createElementBlock(`h3`,_hoisted_5$68,[createBaseVNode(`span`,_hoisted_6$54,toDisplayString(subCategory.name),1)])),(openBlock(!0),createElementBlock(Fragment,null,renderList(subCategory.items,varData=>withDirectives((openBlock(),createElementBlock(`div`,{key:category.name+subCategory.name+varData.name,class:normalizeClass({"input-container":!0,"variable-box":varData.type===`slider`})},[createBaseVNode(`div`,_hoisted_7$46,toDisplayString(varData.title),1),createBaseVNode(`div`,_hoisted_8$38,[createVNode(unref(bngSlider_default),{ref_for:!0,ref_key:`inputs`,ref:inputs,min:varData.minDis,max:varData.maxDis,step:varData.stepDis,unit:varData.unit,class:normalizeClass({"property-slider":!0}),"with-input":``,"with-reset":``,"orig-value":unref(tuningStore).tuningVariables[varData.name].default,modelValue:unref(tuningStore).tuningVariables[varData.name].valDis,"onUpdate:modelValue":$event=>unref(tuningStore).tuningVariables[varData.name].valDis=$event,onValueChanged:$event=>onChange(varData.name)},null,8,[`min`,`max`,`step`,`unit`,`orig-value`,`modelValue`,`onUpdate:modelValue`,`onValueChanged`])])],2)),[[unref(BngTooltip_default),varData.description,`top`]])),128))]))),128))]))),128))])):createCommentVNode(``,!0),createBaseVNode(`div`,_hoisted_9$35,[withDirectives(createVNode(unref(app_default$2),{class:normalizeClass({"awd-app":awdApp.value}),ref_key:`awdApp`,ref:awdApp},null,8,[`class`]),[[vShow,awdShow.value]]),awdApp.value&&awdApp.value.hasData?(openBlock(),createBlock(unref(bngSwitch_default),{key:0,modelValue:awdShow.value,"onUpdate:modelValue":_cache[0]||=$event=>awdShow.value=$event},{default:withCtx(()=>[createTextVNode(toDisplayString(_ctx.$t(`ui.garage.tune.advWheel`)),1)]),_:1},8,[`modelValue`])):createCommentVNode(``,!0),createVNode(unref(bngSwitch_default),{modelValue:autoApply.value,"onUpdate:modelValue":_cache[1]||=$event=>autoApply.value=$event,onValueChanged:applySettingChanged},{default:withCtx(()=>[createTextVNode(toDisplayString(_ctx.$t(`ui.garage.liveUpdates`)),1)]),_:1},8,[`modelValue`]),createBaseVNode(`div`,_hoisted_10$29,[withDirectives(createVNode(unref(bngButton_default),{"show-hold":``,icon:unref(icons).undo,accent:unref(ACCENTS).custom,class:`reset-button`},null,8,[`icon`,`accent`]),[[unref(BngOnUiNav_default),void 0,`ok`,{asMouse:!0,focusRequired:!0}],[unref(BngClick_default),{holdCallback:resetVarsToLoadedConfig,holdDelay:1e3,repeatInterval:0}],[unref(BngTooltip_default),`Reset to original config`]]),createVNode(unref(bngButton_default),{disabled:autoApply.value||!isChanged.value,onClick:apply$1},{default:withCtx(()=>[createTextVNode(toDisplayString(_ctx.$t(`ui.common.apply`)),1)]),_:1},8,[`disabled`]),__props.closeButton?(openBlock(),createBlock(unref(bngButton_default),{key:0,onClick:close,accent:unref(ACCENTS).attention},{default:withCtx(()=>[createVNode(unref(bngBinding_default),{"ui-event":`back`,deviceMask:`xinput`}),createTextVNode(toDisplayString(_ctx.$t(`ui.common.close`)),1)]),_:1},8,[`accent`])):createCommentVNode(``,!0)])])],2)),[[unref(BngBlur_default),__props.withBackground]])}},Tuning_default=__plugin_vue_export_helper_default(_sfc_main$148,[[`__scopeId`,`data-v-907bf291`]]),CANCEL_MESSAGE=`Are you sure you want to cancel?
    All changes to your vehicle will be reversed`,_sfc_main$147={__name:`TuningMain`,setup(__props){useComputerStore();let tuningStore=useTuningStore(),CONFIRM_BUTTONS=[{label:$translate.instant(`ui.common.yes`),value:!0},{label:$translate.instant(`ui.common.no`),value:!1,extras:{accent:ACCENTS.secondary}}],confirmCancel=async()=>{(!(tuningStore.shoppingData.shoppingCart&&tuningStore.shoppingData.shoppingCart.items.length)||await openConfirmation(null,CANCEL_MESSAGE,CONFIRM_BUTTONS))&&cancelShopping()},cartData=computed(()=>{let cart=tuningStore.shoppingData?tuningStore.shoppingData.shoppingCart:null,res={total:0,taxes:0,items:[]};return cart&&(res.total=cart.total,res.taxes=cart.taxes,Array.isArray(cart.items)&&(res.items=cart.items.map(item=>({type:item.type||item.level===1&&`item`,level:item.level,name:item.title,price:item.price,priceHide:!item.price,removeShow:!!item.varName,remove:()=>Lua_default.career_modules_tuning.removeVarFromShoppingCart(item.varName)})))),res}),elCard=ref(),applyShopping=()=>Lua_default.career_modules_tuning.applyShopping(),cancelShopping=()=>Lua_default.career_modules_tuning.cancelShopping();return(_ctx,_cache)=>(openBlock(),createBlock(ComputerWrapper_default,{path:[`Tuning`],title:`Tuning`,back:``,onBack:confirmCancel},{side:withCtx(()=>[createVNode(ShoppingCart_default,{"cart-data":cartData.value,"player-money":unref(tuningStore).shoppingData.playerMoney,"confirm-button-text":`Confirm`,apply:applyShopping,cancel:confirmCancel},null,8,[`cart-data`,`player-money`])]),default:withCtx(()=>[withDirectives((openBlock(),createBlock(unref(bngCard_default),{class:`tuningCard`,ref_key:`elCard`,ref:elCard},{buttons:withCtx(()=>[..._cache[0]||=[]]),default:withCtx(()=>[createVNode(Tuning_default,{"button-target":elCard.value&&elCard.value.buttonsContainer,"close-button":!1},null,8,[`button-target`])]),_:1})),[[unref(BngBlur_default),1]])]),_:1}))}},TuningMain_default=__plugin_vue_export_helper_default(_sfc_main$147,[[`__scopeId`,`data-v-60311783`]]);const useVehicleInventoryStore=defineStore(`vehicleInventory`,()=>{let{events:events$3}=useBridge(),vehicleInventoryData=ref({}),vehIdToChooseAfterRepairPopup=ref(0),filteredVehicles=computed(()=>{let data=vehicleInventoryData.value;return data.vehicles?Object.values(data.vehicles):[]}),menuOpen=!1;function requestInitialData(){Lua_default.career_modules_inventory.sendDataToUi()}function closeMenu(){Lua_default.career_modules_inventory.closeMenu()}let getExpediteRepairCost=vehicle=>Math.max(vehicle.quickRepairExtraPrice*(vehicle.timeToAccess/vehicle.initialRepairTime),50);function countDownVehicleDelays(){if(menuOpen){for(let vehicle of filteredVehicles.value)vehicle.timeToAccess&&(--vehicle.timeToAccess,vehicle.delayReason==`repair`&&(vehicle.expediteRepairCost=getExpediteRepairCost(vehicle)),vehicle.timeToAccess<=0&&Lua_default.career_modules_inventory.sendDataToUi());setTimeout(countDownVehicleDelays,1e3)}}events$3.on(`vehicleInventoryData`,data=>{Object.values(data.vehicles).forEach(vehicle=>{data.currentVehicleId===vehicle.id&&(vehicle.niceName+=` (Current Vehicle)`),vehicle.owned||(vehicle.niceName+=` (Not owned)`)}),vehicleInventoryData.value=data,vehIdToChooseAfterRepairPopup.value=0,menuOpen||(menuOpen=!0,countDownVehicleDelays())});function menuClosed(){menuOpen=!1}function repairPopupAccept(){Lua_default.career_modules_inventory.chooseVehicleFromMenu(vehIdToChooseAfterRepairPopup.value,1,!0),vehIdToChooseAfterRepairPopup.value=0}function repairPopupDecline(){Lua_default.career_modules_inventory.chooseVehicleFromMenu(vehIdToChooseAfterRepairPopup.value,1,!1),vehIdToChooseAfterRepairPopup.value=0}function chooseVehicle(vehId,buttonIndex){let showRepairPopup=!1,data=vehicleInventoryData.value;if(data.currentVehicleId!==void 0&&vehId!==data.currentVehicleId&&(showRepairPopup=data.vehicles[data.currentVehicleId].needsRepair),showRepairPopup){vehIdToChooseAfterRepairPopup.value=vehId;return}Lua_default.career_modules_inventory.chooseVehicleFromMenu(vehId,buttonIndex+1,!1)}function dispose$2(){events$3.off(`vehicleInventoryData`)}return{filteredVehicles,vehIdToChooseAfterRepairPopup,vehicleInventoryData,requestInitialData,chooseVehicle,repairPopupAccept,repairPopupDecline,menuClosed,closeMenu,dispose:dispose$2}});var _hoisted_1$131={class:`list-vehicle-dialog`},_hoisted_2$110={class:`vehicle-info`},_hoisted_3$98={class:`name`},_hoisted_4$78={key:0,class:`meta`},_hoisted_5$67={key:1,class:`meta`},_hoisted_6$53={class:`price-box`},_hoisted_7$45={class:`price-content`},_hoisted_8$37={class:`price-row`},_hoisted_9$34={class:`step-buttons-group`},_hoisted_10$28={class:`price`},_hoisted_11$26={class:`step-buttons-group`},_sfc_main$146={__name:`ListVehicleDialog`,props:{modelValue:{type:Object,required:!0}},emits:[`update:modelValue`],setup(__props,{emit:__emit}){let props=__props,emit$1=__emit,{units}=useBridge(),formModel=computed({get:()=>props.modelValue,set:newValue=>emit$1(`update:modelValue`,newValue)});function adjustPrice(amount){let price=Math.max(0,Math.round(((formModel.value.price||0)+amount)/50)*50);emit$1(`update:modelValue`,{...formModel.value,price})}let priceHint=computed(()=>{let mv=Number(formModel.value.marketValue||0),p$1=Number(formModel.value.price||0);if(!mv||!p$1)return{text:``,class:``};let diff=(p$1-mv)/mv,percent=Math.round(Math.abs(diff)*100);return percent<1?{text:`Fair market value`,class:`ok`}:diff>0?{text:`${percent}% above market value`,class:`high`}:{text:`${percent}% below market value`,class:`low`}}),offerHint=computed(()=>{let mv=Number(formModel.value.marketValue||0),p$1=Number(formModel.value.price||0);if(!mv||!p$1)return{text:`Regular offers expected`,class:`regular`};let ratio=p$1/mv;return ratio<=.9?{text:`More offers expected`,class:`more`}:ratio>=1.2?{text:`Fewer offers expected`,class:`fewer`}:{text:`Regular offers expected`,class:`regular`}}),formModelText=computed(()=>formModel.value.odometerKm?new Intl.NumberFormat().format(Math.round(formModel.value.odometerKm))+` km`:``);return(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$131,[createBaseVNode(`div`,_hoisted_2$110,[createBaseVNode(`div`,_hoisted_3$98,toDisplayString(formModel.value.vehicleName),1),formModelText.value?(openBlock(),createElementBlock(`div`,_hoisted_4$78,toDisplayString(formModelText.value)+` — Market Value: `+toDisplayString(unref(units).beamBucks(formModel.value.marketValue||0)),1)):(openBlock(),createElementBlock(`div`,_hoisted_5$67,` Market Value: `+toDisplayString(unref(units).beamBucks(formModel.value.marketValue||0)),1))]),createBaseVNode(`div`,_hoisted_6$53,[createBaseVNode(`div`,_hoisted_7$45,[_cache[12]||=createBaseVNode(`div`,{class:`label`},`Your Asking Price`,-1),createBaseVNode(`div`,_hoisted_8$37,[createBaseVNode(`div`,_hoisted_9$34,[createVNode(unref(bngButton_default),{class:`step step-large`,accent:unref(ACCENTS).secondary,onClick:_cache[0]||=$event=>adjustPrice(-5e3)},{default:withCtx(()=>[..._cache[6]||=[createTextVNode(`-5000`,-1)]]),_:1},8,[`accent`]),createVNode(unref(bngButton_default),{class:`step step-medium`,accent:unref(ACCENTS).secondary,onClick:_cache[1]||=$event=>adjustPrice(-500)},{default:withCtx(()=>[..._cache[7]||=[createTextVNode(`-500`,-1)]]),_:1},8,[`accent`]),createVNode(unref(bngButton_default),{class:`step`,accent:unref(ACCENTS).secondary,onClick:_cache[2]||=$event=>adjustPrice(-50)},{default:withCtx(()=>[..._cache[8]||=[createTextVNode(`-50`,-1)]]),_:1},8,[`accent`])]),createBaseVNode(`div`,_hoisted_10$28,toDisplayString(unref(units).beamBucks(formModel.value.price||0)),1),createBaseVNode(`div`,_hoisted_11$26,[createVNode(unref(bngButton_default),{class:`step`,accent:unref(ACCENTS).secondary,onClick:_cache[3]||=$event=>adjustPrice(50)},{default:withCtx(()=>[..._cache[9]||=[createTextVNode(`+50`,-1)]]),_:1},8,[`accent`]),createVNode(unref(bngButton_default),{class:`step step-medium`,accent:unref(ACCENTS).secondary,onClick:_cache[4]||=$event=>adjustPrice(500)},{default:withCtx(()=>[..._cache[10]||=[createTextVNode(`+500`,-1)]]),_:1},8,[`accent`]),createVNode(unref(bngButton_default),{class:`step step-large`,accent:unref(ACCENTS).secondary,onClick:_cache[5]||=$event=>adjustPrice(5e3)},{default:withCtx(()=>[..._cache[11]||=[createTextVNode(`+5000`,-1)]]),_:1},8,[`accent`])])]),createBaseVNode(`div`,{class:normalizeClass([`hint`,[priceHint.value.class]])},toDisplayString(priceHint.value.text),3),createBaseVNode(`div`,{class:normalizeClass([`offer-hint`,[offerHint.value.class]])},toDisplayString(offerHint.value.text),3)])])]))}},ListVehicleDialog_default=__plugin_vue_export_helper_default(_sfc_main$146,[[`__scopeId`,`data-v-87a25af5`]]),_hoisted_1$130={class:`vehicle-list-container`},_sfc_main$145={__name:`VehicleList`,setup(__props){let{units}=useBridge(),{$game}=useLibStore(),popover=usePopover(),popId=uniqueId(`veh_options`),popHide=()=>popover.hide(popId),licensePlateTextValid=ref(!0),vehicleNameValid=ref(!0),vehicleInventoryStore=useVehicleInventoryStore(),selectedVehId=ref(),vehSelected=computed(()=>{if(typeof selectedVehId.value==`number`)return listView.value.find(v=>v.id===selectedVehId.value)}),careerStatusData=ref({}),updateCareerStatusData=()=>Lua_default.career_modules_uiUtils.getCareerStatusData().then(data=>careerStatusData.value=data),cantPayLicensePlate=computed(()=>!careerStatusData.value.money||300>careerStatusData.value.money),listStatus=computed(()=>vehicleInventoryStore?!Array.isArray(vehicleInventoryStore.filteredVehicles)||vehicleInventoryStore.filteredVehicles.length===0?`You don't currently own any vehicles`:null:`Please wait...`),listView=computed(()=>{if(!vehicleInventoryStore||!Array.isArray(vehicleInventoryStore.filteredVehicles)||vehicleInventoryStore.filteredVehicles.length===0)return[];let res=vehicleInventoryStore.filteredVehicles;if(singleFunction.value)for(let veh of res)veh.disabled=!isFunctionAvailable(veh,singleFunction.value);return res.sort((a$1,b)=>a$1.favorite?-1:b.favorite?1:a$1.niceName.localeCompare(b.niceName)),res}),itemLayout=ref({TILE:`tile`,LIST:`row`}.TILE),singleFunction=computed(()=>{if(!vehicleInventoryStore||!vehicleInventoryStore.vehicleInventoryData)return null;let data=vehicleInventoryStore.vehicleInventoryData;return Object.values(data.buttonsActive).includes(!0)||!Array.isArray(data.chooseButtonsData)||data.chooseButtonsData.length!==1?null:data.chooseButtonsData[0]});function select(vehicle,evt){let show=vehicleInventoryStore&&vehicleInventoryStore.vehicleInventoryData&&(Object.values(vehicleInventoryStore.vehicleInventoryData.buttonsActive).includes(!0)||vehicleInventoryStore.vehicleInventoryData.chooseButtonsData.length>0)&&vehicle&&(!vehSelected.value||vehSelected.value.id!==vehicle.id),popover$1;if(evt&&evt.target){let cur=evt.target;for(;popover$1=cur.__popover,!(popover$1||(cur=cur.parentNode,cur===document.body)););}if(vehicle&&singleFunction.value){selectedVehId.value=null,popover$1&&popover$1.hide(),vehicleInventoryStore.chooseVehicle(vehicle.id,0);return}show&&popover$1&&popover$1.hide(),nextTick(()=>{show?(selectedVehId.value=vehicle.id,popover$1&&popover$1.show()):(popover$1&&popover$1.hide(),selectedVehId.value=null)})}let isFunctionAvailable=(vehicle,buttonData)=>!(vehicle.timeToAccess||vehicle.missingFile||buttonData.requiredVehicleNotInGarage&&vehicle.inGarage||buttonData.requiredOtherVehicleInGarage&&!vehicle.otherVehicleInGarage||buttonData.ownedRequired&&!vehicle.owned||buttonData.repairRequired&&vehicle.needsRepair||buttonData.notForSaleRequired&&vehicle.listedForSale),lookAtVehicleListing=()=>{Lua_default.career_modules_marketplace.openMenu(vehicleInventoryStore.vehicleInventoryData.originComputerId)},confirmReturnVehicle=async()=>{let vehicle=vehSelected.value;popHide(),await openConfirmation(``,`Do you want to return this loaned vehicle to the owner?`,[{label:$translate.instant(`ui.common.yes`),value:!0,extras:{default:!0}},{label:$translate.instant(`ui.common.no`),value:!1,extras:{accent:ACCENTS.secondary}}])&&Lua_default.career_modules_inventory.returnLoanedVehicleFromInventory(vehicle.id)},personalizeLicensePlate=async()=>{let vehicle=vehSelected.value;popHide(),updateCareerStatusData();let res=await openPrompt(`Enter your new license plate text:`,`Personalize License Plate`,{maxLength:10,defaultValue:vehicle.config.licenseName,buttons:[{label:$translate.instant(`ui.common.cancel`),value:!1,extras:{cancel:!0,accent:ACCENTS.secondary}},{label:$translate.instant(`ui.common.okay`)+` (Cost: ${units.beamBucks(300)})`,value:text=>text,extras:{disabled:cantPayLicensePlate,accent:ACCENTS.primary}}],validate:text=>(Lua_default.career_modules_inventory.isLicensePlateValid(text).then(valid=>{licensePlateTextValid.value=valid}),licensePlateTextValid.value),errorMessage:`Invalid character in license plate text`,disableWhenInvalid:!0});res!=0&&(Lua_default.career_modules_inventory.purchaseLicensePlateText(vehicle.id,res,300),vehicle.config.licenseName=res)},confirmExpediteRepair=async()=>{let vehicle=vehSelected.value;popHide();let price=vehicle.expediteRepairCost;await openConfirmation(``,`Do you want to expedite the repair for ${units.beamBucks(price)}?`,[{label:$translate.instant(`ui.common.yes`),value:!0,extras:{default:!0}},{label:$translate.instant(`ui.common.no`),value:!1,extras:{accent:ACCENTS.secondary}}])&&Lua_default.career_modules_inventory.expediteRepairFromInventory(vehicle.id,price)},openRepairMenu=()=>{let vehicle=vehSelected.value;popHide(),Lua_default.career_modules_insurance_repairScreen.openRepairMenu(vehicle,vehicleInventoryStore.vehicleInventoryData.originComputerId)},setFavoriteVehicle=()=>{let vehicle=vehSelected.value;popHide(),Lua_default.career_modules_inventory.setFavoriteVehicle(vehicle.id),Lua_default.career_modules_inventory.sendDataToUi()},storeVehicle=()=>{let vehicle=vehSelected.value;popHide(),Lua_default.career_modules_inventory.removeVehicleObject(vehicle.id),Lua_default.career_modules_inventory.sendDataToUi()},renameVehicle=async()=>{let vehicle=vehSelected.value;popHide();let res=await openPrompt(`Enter new vehicle name:`,`Rename Vehicle`,{maxLength:30,defaultValue:vehicle.niceName,buttons:[{label:$translate.instant(`ui.common.cancel`),value:!1,extras:{cancel:!0,accent:ACCENTS.secondary}},{label:$translate.instant(`ui.common.okay`),value:text=>text,extras:{accent:ACCENTS.primary}}],validate:text=>(Lua_default.career_modules_inventory.isVehicleNameValid(text).then(valid=>{vehicleNameValid.value=valid}),vehicleNameValid.value),errorMessage:`Invalid characters in vehicle name`,disableWhenInvalid:!0});res!=0&&(Lua_default.career_modules_inventory.renameVehicle(vehicle.id,res),vehicle.niceName=res)},listVehicleForSale=async vehicle=>{popHide();let res=await openFormDialog(ListVehicleDialog_default,{vehicleName:vehicle.niceName,odometer:vehicle.odometer,marketValue:vehicle.value,price:Math.max(50,Math.round((vehicle.value||0)/50)*50)},model=>!Number.isFinite(model.price)||model.price<=0?{error:!0,message:`Enter a valid positive price`}:{error:!1},`List a Vehicle for Sale`,void 0,void 0,`90rem`);!res||!res.value||await Lua_default.career_modules_marketplace.listVehicles([{inventoryId:vehicle.id,value:res.formData.price}])},listVehicleForSaleFromContextMenu=async()=>{let vehicle=vehSelected.value;await listVehicleForSale(vehicle),Lua_default.career_modules_marketplace.openMenu(vehicleInventoryStore.vehicleInventoryData.originComputerId)},listVehicleForSaleFromMarketplaceMenu=async vehicle=>{await listVehicleForSale(vehicle),router_default.back()};return $game.events.on(`addListing`,data=>{listVehicleForSaleFromMarketplaceMenu(listView.value.find(v=>v.id===data.inventoryId))}),onUnmounted(()=>{$game.events.off(`addListing`)}),(_ctx,_cache)=>withDirectives((openBlock(),createElementBlock(`div`,_hoisted_1$130,[listStatus.value?withDirectives((openBlock(),createBlock(VehicleTileRow_default,{key:0,class:`vehicle-list-item`,data:{_message:listStatus.value},layout:itemLayout.value},null,8,[`data`,`layout`])),[[unref(BngDisabled_default)]]):(openBlock(!0),createElementBlock(Fragment,{key:1},renderList(listView.value,vehicle=>withDirectives((openBlock(),createBlock(VehicleTileRow_default,{class:`vehicle-list-item`,key:vehicle.id,data:vehicle,layout:itemLayout.value,selected:vehSelected.value&&vehSelected.value.id===vehicle.id,"is-tutorial":unref(vehicleInventoryStore)&&unref(vehicleInventoryStore).vehicleInventoryData.tutorialActive,money:unref(vehicleInventoryStore)?unref(vehicleInventoryStore).vehicleInventoryData.playerMoney:0,tabindex:`0`,"bng-nav-item":``,onClick:$event=>!vehicle.disabled&&select(vehicle,$event)},null,8,[`data`,`layout`,`selected`,`is-tutorial`,`money`,`onClick`])),[[unref(BngDisabled_default),vehicle.disabled],[unref(BngOnUiNav_default),void 0,`ok`,{asMouse:!0,focusRequired:!0}],[unref(BngPopover_default),unref(popId),`right-start`,{click:!0}]])),128)),createVNode(unref(bngPopoverMenu_default),{name:unref(popId),focus:``,onHide:_cache[9]||=$event=>selectedVehId.value=null},{default:withCtx(()=>[(openBlock(!0),createElementBlock(Fragment,null,renderList(unref(vehicleInventoryStore).vehicleInventoryData.chooseButtonsData,(buttonData,index)=>(openBlock(),createElementBlock(Fragment,{key:index},[buttonData.repairRequired&&vehSelected.value&&vehSelected.value.needsRepair&&!unref(vehicleInventoryStore).vehicleInventoryData.tutorialActive?(openBlock(),createBlock(unref(bngButton_default),{key:0,accent:unref(ACCENTS).menu,disabled:``},{default:withCtx(()=>[createTextVNode(toDisplayString(buttonData.buttonText)+` (Needs repair) `,1)]),_:2},1032,[`accent`])):vehSelected.value&&isFunctionAvailable(vehSelected.value,buttonData)?withDirectives((openBlock(),createBlock(unref(bngButton_default),{key:1,accent:unref(ACCENTS).menu,onClick:$event=>unref(vehicleInventoryStore).chooseVehicle(vehSelected.value.id,index)},{default:withCtx(()=>[createTextVNode(toDisplayString(buttonData.buttonText),1)]),_:2},1032,[`accent`,`onClick`])),[[unref(BngOnUiNav_default),void 0,`ok`,{focusRequired:!0,asMouse:!0}]]):createCommentVNode(``,!0)],64))),128)),vehSelected.value&&unref(vehicleInventoryStore).vehicleInventoryData.buttonsActive.returnLoanerEnabled&&vehSelected.value.returnLoanerPermission.allow?withDirectives((openBlock(),createBlock(unref(bngButton_default),{key:0,accent:unref(ACCENTS).menu,onClick:_cache[0]||=$event=>confirmReturnVehicle()},{default:withCtx(()=>[..._cache[10]||=[createTextVNode(` Return loaned vehicle `,-1)]]),_:1},8,[`accent`])),[[unref(BngOnUiNav_default),void 0,`ok`,{focusRequired:!0,asMouse:!0}]]):createCommentVNode(``,!0),vehSelected.value&&vehSelected.value.delayReason===`repair`?withDirectives((openBlock(),createBlock(unref(bngButton_default),{key:1,accent:unref(ACCENTS).menu,disabled:vehSelected.value.expediteRepairCost>unref(vehicleInventoryStore).vehicleInventoryData.playerMoney,onClick:_cache[1]||=$event=>confirmExpediteRepair(vehSelected.value)},{default:withCtx(()=>[_cache[11]||=createTextVNode(` Expedite Repair `,-1),createVNode(unref(bngUnit_default),{money:vehSelected.value.expediteRepairCost},null,8,[`money`])]),_:1},8,[`accent`,`disabled`])),[[unref(BngOnUiNav_default),void 0,`ok`,{focusRequired:!0,asMouse:!0}]]):createCommentVNode(``,!0),vehSelected.value&&vehSelected.value.delayReason!==`repair`&&unref(vehicleInventoryStore).vehicleInventoryData.buttonsActive.repairEnabled?withDirectives((openBlock(),createBlock(unref(bngButton_default),{key:2,accent:unref(ACCENTS).menu,disabled:!vehSelected.value.repairPermission.allow,onClick:_cache[2]||=$event=>openRepairMenu()},{default:withCtx(()=>[..._cache[12]||=[createTextVNode(` Repair `,-1)]]),_:1},8,[`accent`,`disabled`])),[[unref(BngOnUiNav_default),void 0,`ok`,{focusRequired:!0,asMouse:!0}]]):createCommentVNode(``,!0),vehSelected.value&&unref(vehicleInventoryStore).vehicleInventoryData.buttonsActive.storingEnabled&&!vehSelected.value.inStorage?withDirectives((openBlock(),createBlock(unref(bngButton_default),{key:3,accent:unref(ACCENTS).menu,disabled:!vehSelected.value.storePermission.allow,onClick:_cache[3]||=$event=>storeVehicle()},{default:withCtx(()=>[..._cache[13]||=[createTextVNode(` Put in storage `,-1)]]),_:1},8,[`accent`,`disabled`])),[[unref(BngOnUiNav_default),void 0,`ok`,{focusRequired:!0,asMouse:!0}]]):createCommentVNode(``,!0),vehSelected.value&&unref(vehicleInventoryStore).vehicleInventoryData.buttonsActive.favoriteEnabled?withDirectives((openBlock(),createBlock(unref(bngButton_default),{key:4,accent:unref(ACCENTS).menu,disabled:!vehSelected.value.favoritePermission.allow||vehSelected.value.favorite,onClick:_cache[4]||=$event=>setFavoriteVehicle()},{default:withCtx(()=>[..._cache[14]||=[createTextVNode(` Set as Favorite `,-1)]]),_:1},8,[`accent`,`disabled`])),[[unref(BngOnUiNav_default),void 0,`ok`,{focusRequired:!0,asMouse:!0}]]):createCommentVNode(``,!0),vehSelected.value?withDirectives((openBlock(),createBlock(unref(bngButton_default),{key:5,accent:unref(ACCENTS).menu,disabled:!vehSelected.value.licensePlateChangePermission.allow,onClick:_cache[5]||=$event=>personalizeLicensePlate(vehSelected.value)},{default:withCtx(()=>[..._cache[15]||=[createTextVNode(` Personalize license plate `,-1)]]),_:1},8,[`accent`,`disabled`])),[[unref(BngOnUiNav_default),void 0,`ok`,{focusRequired:!0,asMouse:!0}]]):createCommentVNode(``,!0),vehSelected.value?withDirectives((openBlock(),createBlock(unref(bngButton_default),{key:6,accent:unref(ACCENTS).menu,onClick:_cache[6]||=$event=>renameVehicle()},{default:withCtx(()=>[..._cache[16]||=[createTextVNode(` Rename vehicle `,-1)]]),_:1},8,[`accent`])),[[unref(BngOnUiNav_default),void 0,`ok`,{focusRequired:!0,asMouse:!0}]]):createCommentVNode(``,!0),vehSelected.value&&unref(vehicleInventoryStore).vehicleInventoryData.buttonsActive.sellEnabled&&!vehSelected.value.listedForSale?withDirectives((openBlock(),createBlock(unref(bngButton_default),{key:7,accent:unref(ACCENTS).menu,disabled:!vehSelected.value.sellPermission.allow,onClick:_cache[7]||=$event=>listVehicleForSaleFromContextMenu()},{default:withCtx(()=>[..._cache[17]||=[createTextVNode(` List vehicle for sale `,-1)]]),_:1},8,[`accent`,`disabled`])),[[unref(BngOnUiNav_default),void 0,`ok`,{focusRequired:!0,asMouse:!0}]]):createCommentVNode(``,!0),vehSelected.value&&unref(vehicleInventoryStore).vehicleInventoryData.buttonsActive.sellEnabled&&vehSelected.value.listedForSale?withDirectives((openBlock(),createBlock(unref(bngButton_default),{key:8,accent:unref(ACCENTS).menu,disabled:!vehSelected.value.sellPermission.allow,onClick:_cache[8]||=$event=>lookAtVehicleListing()},{default:withCtx(()=>[..._cache[18]||=[createTextVNode(` Go to vehicle listing `,-1)]]),_:1},8,[`accent`,`disabled`])),[[unref(BngOnUiNav_default),void 0,`ok`,{focusRequired:!0,asMouse:!0}]]):createCommentVNode(``,!0)]),_:1},8,[`name`])])),[[unref(BngDisabled_default),!unref(vehicleInventoryStore)]])}},VehicleList_default$1=__plugin_vue_export_helper_default(_sfc_main$145,[[`__scopeId`,`data-v-5a84a046`]]),_sfc_main$144=Object.assign({inheritAttrs:!1},{__name:`VehicleInventory`,setup(__props,{expose:__expose}){let vehicleInventoryStore=useVehicleInventoryStore(),attrs=useAttrs();return __expose({closeMenu:vehicleInventoryStore.closeMenu}),onBeforeMount(()=>{vehicleInventoryStore.requestInitialData()}),onUnmounted(()=>{Lua_default.extensions.hook(`onExitVehicleInventory`),vehicleInventoryStore.menuClosed(),vehicleInventoryStore.$dispose()}),(_ctx,_cache)=>(openBlock(),createBlock(VehicleList_default$1,normalizeProps(guardReactiveProps(unref(attrs))),null,16))}}),VehicleInventory_default=_sfc_main$144,_sfc_main$143={__name:`VehicleInventoryMain`,setup(__props){let vehicleInventoryStore=useVehicleInventoryStore(),router$1=useRouter(),title=computed(()=>vehicleInventoryStore.vehicleInventoryData.header||`My vehicles`);watch(()=>vehicleInventoryStore.vehIdToChooseAfterRepairPopup,(newId,oldId)=>{!oldId&&newId&&confirmRepair()});let confirmRepair=async vehicle=>{await openConfirmation(``,`Do you want to repair your previous vehicle?`,[{label:$translate.instant(`ui.common.yes`),value:!0,extras:{default:!0}},{label:$translate.instant(`ui.common.no`),value:!1,extras:{accent:ACCENTS.secondary}}])?vehicleInventoryStore.repairPopupAccept():vehicleInventoryStore.repairPopupDecline()},elInventory=ref(),close=()=>router$1.back();return onUnmounted(()=>{vehicleInventoryStore.$dispose()}),(_ctx,_cache)=>(openBlock(),createBlock(ComputerWrapper_default,{ref:`wrapper`,title:title.value,back:``,onBack:close},{default:withCtx(()=>[createVNode(VehicleInventory_default,{ref_key:`elInventory`,ref:elInventory,class:`vehicle-inventory`},null,512)]),_:1},8,[`title`]))}},VehicleInventoryMain_default=__plugin_vue_export_helper_default(_sfc_main$143,[[`__scopeId`,`data-v-88176408`]]);const useVehiclePurchaseStore=defineStore(`vehiclePurchase`,()=>{let{events:events$3}=useBridge(),purchaseType=ref(``),vehicleInfo=ref({}),playerMoney=ref(0),alreadyDidTestDrive=ref(!1),inventoryHasFreeSlot=ref(!1),tradeInVehicleInfo=ref({}),tradeInEnabled=ref(!1),forceTradeIn=ref(!1),locationSelectionEnabled=ref(!1),forceNoDelivery=ref(!1),makeDelivery=ref(!1),buyCustomLicensePlate=ref(!1),customLicensePlateText=ref(``),prices=ref({}),insuranceOptions=ref({}),finalPackagePrice=computed(()=>{let price=prices.value.finalPrice;return buyCustomLicensePlate.value&&(price+=prices.value.customLicensePlate),insuranceOptions.value.insuranceId>0&&(price+=insuranceOptions.value.priceMoney),price}),handlePurchaseData=data=>{vehicleInfo.value=data.vehicleInfo,playerMoney.value=data.playerMoney,inventoryHasFreeSlot.value=data.inventoryHasFreeSlot,purchaseType.value=data.purchaseType,tradeInEnabled.value=data.tradeInEnabled,locationSelectionEnabled.value=data.locationSelectionEnabled,forceNoDelivery.value=data.forceNoDelivery,prices.value=data.prices,makeDelivery.value=!1,buyCustomLicensePlate.value=!1,customLicensePlateText.value=``,alreadyDidTestDrive.value=data.alreadyDidTestDrive,forceTradeIn.value=data.forceTradeIn,insuranceOptions.value=data.insuranceOptions,data.tradeInVehicleInfo===void 0?tradeInVehicleInfo.value={}:tradeInVehicleInfo.value=data.tradeInVehicleInfo};function requestPurchaseData(){Lua_default.career_modules_vehicleShopping.sendPurchaseDataToUi()}function buyVehicle(makeDelivery$1){let options={makeDelivery:makeDelivery$1,insuranceId:insuranceOptions.value.insuranceId};buyCustomLicensePlate.value&&(options.licensePlateText=customLicensePlateText.value),Lua_default.career_modules_vehicleShopping.buyFromPurchaseMenu(purchaseType.value,options)}function inventoryIsEmpty(){return Lua_default.career_modules_inventory.isEmpty()}function chooseTradeInVehicle(){Lua_default.career_modules_vehicleShopping.openInventoryMenuForTradeIn()}function removeTradeInVehicle(){Lua_default.career_modules_vehicleShopping.removeTradeInVehicle()}function cancel(){Lua_default.career_modules_vehicleShopping.cancelPurchase(purchaseType.value)}function startTestDrive(){Lua_default.career_modules_inspectVehicle.startTestDrive()}function dispose$2(){listen(!1)}let listen=state=>{events$3[state?`on`:`off`](`vehiclePurchaseData`,handlePurchaseData)};return listen(!0),{buyVehicle,cancel,chooseTradeInVehicle,purchaseType,startTestDrive,dispose:dispose$2,forceNoDelivery,forceTradeIn,inventoryIsEmpty,inventoryHasFreeSlot,locationSelectionEnabled,makeDelivery,playerMoney,prices,finalPackagePrice,removeTradeInVehicle,requestPurchaseData,tradeInEnabled,tradeInVehicleInfo,vehicleInfo,buyCustomLicensePlate,customLicensePlateText,alreadyDidTestDrive,insuranceOptions}});var _hoisted_1$129={class:`header-row`},_hoisted_2$109={class:`header-seller-info`},_hoisted_3$97={class:`purchase-list`},_hoisted_4$77={class:`purchase-row`},_hoisted_5$66={class:`label`},_hoisted_6$52={class:`sub-info`},_hoisted_7$44={class:`price`},_hoisted_8$36={class:`current-price-line`},_hoisted_9$33={key:0,class:`old-price`},_hoisted_10$27={class:`sub-info`},_hoisted_11$25={key:0,class:`purchase-row thin light-blue`},_hoisted_12$20={class:`label category`},_hoisted_13$18={class:`price category`},_hoisted_14$18={class:`purchase-row thin light-blue`},_hoisted_15$18={class:`price`},_hoisted_16$18={key:1,class:`purchase-divider`},_hoisted_17$14={key:2,class:`purchase-row thin green`},_hoisted_18$12={class:`label`},_hoisted_19$9={class:`price`},_hoisted_20$8={class:`purchase-row`},_hoisted_21$8={class:`price`},_hoisted_22$7={class:`purchase-row thin yellow`},_hoisted_23$6={class:`price`},_hoisted_24$5={key:3,class:`purchase-row thin`},_hoisted_25$4={class:`price`},_hoisted_26$3={class:`purchase-row`},_hoisted_27$3={class:`price highlight-category`},_hoisted_28$2={key:4,class:`purchase-row money-warning red`},_hoisted_29$2={class:`label`},_hoisted_30$2={class:`price`},_hoisted_31$2={class:`purchase-customization-group`},_hoisted_32$2={class:`button-group`},_hoisted_33$2={key:0},_hoisted_34$2={key:1},_hoisted_35$1={key:2},_hoisted_36$1={class:`right-side`},_sfc_main$142={__name:`VehiclePurchaseMain`,setup(__props){useUINavScope(`vehiclePurchase`);let{showIfController}=storeToRefs(controls_default()),{units}=useBridge(),router$1=useRouter(),hasVehicle=ref(!1),licensePlateTextValid=ref(!0),vehiclePurchaseStore=useVehiclePurchaseStore(),store$1=useTasksStore(),tradeInButtonMessage=computed(()=>vehiclePurchaseStore.tradeInEnabled?hasVehicle.value?void 0:`You don't own any vehicles`:`Trade in only possible in person at a dealership`),testDriveButtonMessage=computed(()=>{if(vehiclePurchaseStore.purchaseType!==`inspect`)return`Test drive only available for inspect purchases`;if(vehiclePurchaseStore.alreadyDidTestDrive)return`You have already done a test drive`}),vehicleFitsInventory=computed(()=>vehiclePurchaseStore.vehicleInfo.takesNoInventorySpace?!0:vehiclePurchaseStore.inventoryHasFreeSlot||vehiclePurchaseStore.tradeInVehicleInfo.niceName&&!vehiclePurchaseStore.tradeInVehicleInfo.takesNoInventorySpace);vehiclePurchaseStore.inventoryIsEmpty().then(empty=>{hasVehicle.value=!empty});let buy=()=>buyVehicle(!vehiclePurchaseStore.locationSelectionEnabled||vehiclePurchaseStore.makeDelivery),cancel=()=>{router$1.back()},startTestDrive=()=>{vehiclePurchaseStore.startTestDrive()},chooseTradeInVehicle=()=>{vehiclePurchaseStore.chooseTradeInVehicle()},chooseInsurance=()=>{addPopup(ChooseInsuranceMain_default,{menuMode:`purchase`,params:{purchaseType:vehiclePurchaseStore.purchaseType,shopId:vehiclePurchaseStore.vehicleInfo.shopId,insuranceId:vehiclePurchaseStore.insuranceOptions.insuranceId}})},negotiatePrice=()=>{Lua_default.career_modules_marketplace.startNegotiateSellingOffer(vehiclePurchaseStore.vehicleInfo.shopId)},removeTradeInVehicle=()=>{vehiclePurchaseStore.removeTradeInVehicle()},buyVehicle=_makeDelivery=>{vehiclePurchaseStore.buyVehicle(_makeDelivery)};return onMounted(()=>{vehiclePurchaseStore.requestPurchaseData()}),onUnmounted(async()=>{await Lua_default.career_modules_inspectVehicle.onPurchaseMenuClosed(),vehiclePurchaseStore.$dispose()}),(_ctx,_cache)=>(openBlock(),createBlock(unref(layoutSingle_default),{class:`purchase-layout`},{default:withCtx(()=>[unref(vehiclePurchaseStore).vehicleInfo.niceName?withDirectives((openBlock(),createBlock(unref(bngCard_default),{key:0,"bng-ui-scope":`vehiclePurchase`,class:`purchase-screen`},{buttons:withCtx(()=>[createBaseVNode(`div`,_hoisted_32$2,[withDirectives((openBlock(),createBlock(unref(bngButton_default),{disabled:unref(vehiclePurchaseStore).purchaseType!==`inspect`||unref(vehiclePurchaseStore).alreadyDidTestDrive,onClick:startTestDrive,accent:unref(ACCENTS).secondary},{default:withCtx(()=>[..._cache[16]||=[createTextVNode(`Test Drive`,-1)]]),_:1},8,[`disabled`,`accent`])),[[unref(BngTooltip_default),testDriveButtonMessage.value,`top`]]),withDirectives((openBlock(),createBlock(unref(bngButton_default),{disabled:unref(vehiclePurchaseStore).finalPackagePrice>unref(vehiclePurchaseStore).playerMoney||!vehicleFitsInventory.value||unref(vehiclePurchaseStore).forceTradeIn&&!unref(vehiclePurchaseStore).tradeInVehicleInfo.niceName||unref(vehiclePurchaseStore).buyCustomLicensePlate&&!licensePlateTextValid.value,"show-hold":``},{default:withCtx(()=>[unref(vehiclePurchaseStore).finalPackagePrice>unref(vehiclePurchaseStore).playerMoney?(openBlock(),createElementBlock(`div`,_hoisted_33$2,`Insufficient Funds`)):vehicleFitsInventory.value?(openBlock(),createElementBlock(`div`,_hoisted_35$1,`Purchase`)):(openBlock(),createElementBlock(`div`,_hoisted_34$2,`No free inventory slots`))]),_:1},8,[`disabled`])),[[unref(BngOnUiNav_default),void 0,`ok`,{asMouse:!0,focusRequired:!0}],[unref(BngClick_default),{holdCallback:buy,holdDelay:1e3,repeatInterval:0}]])])]),default:withCtx(()=>[createBaseVNode(`div`,_hoisted_1$129,[createVNode(unref(bngCardHeading_default),{type:`ribbon`},{default:withCtx(()=>[_cache[0]||=createTextVNode(` Purchase Information `,-1),createBaseVNode(`div`,_hoisted_2$109,` Purchasing from: `+toDisplayString(unref(vehiclePurchaseStore).vehicleInfo.sellerName),1)]),_:1}),createVNode(unref(bngButton_default),{class:`close-button`,onClick:cancel,accent:unref(ACCENTS).attention,"bng-no-nav":`true`,tabindex:`-1`},{default:withCtx(()=>[createVNode(unref(bngBinding_default),{"ui-event":`menu`,controller:``}),createVNode(unref(bngIcon_default),{type:`xmarkBold`,color:`var(--bng-cool-gray-100)`})]),_:1},8,[`accent`])]),createBaseVNode(`div`,_hoisted_3$97,[createBaseVNode(`div`,_hoisted_4$77,[createBaseVNode(`div`,_hoisted_5$66,[createBaseVNode(`div`,null,toDisplayString(unref(vehiclePurchaseStore).vehicleInfo.year)+` `+toDisplayString(unref(vehiclePurchaseStore).vehicleInfo.niceName),1),createBaseVNode(`div`,_hoisted_6$52,`(`+toDisplayString(unref(units).buildString(`length`,unref(vehiclePurchaseStore).vehicleInfo.Mileage,0))+`)`,1)]),createBaseVNode(`div`,_hoisted_7$44,[createBaseVNode(`div`,_hoisted_8$36,[unref(vehiclePurchaseStore).vehicleInfo.originalSellValue?(openBlock(),createElementBlock(`span`,_hoisted_9$33,[createVNode(unref(bngUnit_default),{money:unref(vehiclePurchaseStore).vehicleInfo.originalSellValue},null,8,[`money`])])):createCommentVNode(``,!0),createVNode(unref(bngUnit_default),{class:`money`,money:unref(vehiclePurchaseStore).vehicleInfo.Value},null,8,[`money`])]),createBaseVNode(`div`,_hoisted_10$27,[createBaseVNode(`div`,null,[_cache[1]||=createTextVNode(` Est. Market: `,-1),createVNode(unref(bngUnit_default),{class:`money`,money:unref(vehiclePurchaseStore).vehicleInfo.marketValue},null,8,[`money`])])])])]),_cache[13]||=createBaseVNode(`div`,{class:`purchase-divider`},null,-1),unref(vehiclePurchaseStore).insuranceOptions.insuranceId>0?(openBlock(),createElementBlock(`div`,_hoisted_11$25,[createBaseVNode(`div`,_hoisted_12$20,toDisplayString(unref(vehiclePurchaseStore).insuranceOptions.spendingReason),1),createBaseVNode(`div`,_hoisted_13$18,[createVNode(unref(bngUnit_default),{class:`money`,money:unref(vehiclePurchaseStore).insuranceOptions.priceMoney},null,8,[`money`])])])):createCommentVNode(``,!0),createBaseVNode(`div`,_hoisted_14$18,[_cache[2]||=createBaseVNode(`div`,{class:`label`},`Dealership Fees`,-1),createBaseVNode(`div`,_hoisted_15$18,[createVNode(unref(bngUnit_default),{class:`money`,money:unref(vehiclePurchaseStore).vehicleInfo.fees},null,8,[`money`])])]),unref(vehiclePurchaseStore).tradeInVehicleInfo?.niceName?(openBlock(),createElementBlock(`div`,_hoisted_16$18)):createCommentVNode(``,!0),unref(vehiclePurchaseStore).tradeInVehicleInfo.niceName?(openBlock(),createElementBlock(`div`,_hoisted_17$14,[createBaseVNode(`div`,_hoisted_18$12,`Trade-in: `+toDisplayString(unref(vehiclePurchaseStore).tradeInVehicleInfo.niceName),1),createBaseVNode(`div`,_hoisted_19$9,[createVNode(unref(bngUnit_default),{class:`money`,money:-unref(vehiclePurchaseStore).tradeInVehicleInfo.Value},null,8,[`money`])])])):createCommentVNode(``,!0),_cache[14]||=createBaseVNode(`div`,{class:`purchase-divider`},null,-1),createBaseVNode(`div`,_hoisted_20$8,[_cache[3]||=createBaseVNode(`div`,{class:`label`},`Subtotal`,-1),createBaseVNode(`div`,_hoisted_21$8,[createVNode(unref(bngUnit_default),{class:`money`,money:unref(vehiclePurchaseStore).finalPackagePrice-unref(vehiclePurchaseStore).prices.taxes-(unref(vehiclePurchaseStore).buyCustomLicensePlate?unref(vehiclePurchaseStore).prices.customLicensePlate:0)},null,8,[`money`])])]),createBaseVNode(`div`,_hoisted_22$7,[_cache[4]||=createBaseVNode(`div`,{class:`label`},`Sales Tax (7%)`,-1),createBaseVNode(`div`,_hoisted_23$6,[createVNode(unref(bngUnit_default),{class:`money`,money:unref(vehiclePurchaseStore).prices.taxes},null,8,[`money`])])]),unref(vehiclePurchaseStore).buyCustomLicensePlate?(openBlock(),createElementBlock(`div`,_hoisted_24$5,[_cache[5]||=createBaseVNode(`div`,{class:`label`},`Custom License Plate`,-1),createBaseVNode(`div`,_hoisted_25$4,[createVNode(unref(bngUnit_default),{class:`money`,money:unref(vehiclePurchaseStore).prices.customLicensePlate},null,8,[`money`])])])):createCommentVNode(``,!0),_cache[15]||=createBaseVNode(`div`,{class:`purchase-divider`},null,-1),createBaseVNode(`div`,_hoisted_26$3,[_cache[6]||=createBaseVNode(`div`,{class:`label highlight-category`},`Total`,-1),createBaseVNode(`div`,_hoisted_27$3,[createVNode(unref(bngUnit_default),{class:`money`,money:unref(vehiclePurchaseStore).finalPackagePrice},null,8,[`money`])])]),unref(vehiclePurchaseStore).finalPackagePrice>unref(vehiclePurchaseStore).playerMoney?(openBlock(),createElementBlock(`div`,_hoisted_28$2,[createBaseVNode(`div`,_hoisted_29$2,[createVNode(unref(bngIcon_default),{type:`danger`}),_cache[7]||=createTextVNode(` Additional funds required`,-1)]),createBaseVNode(`div`,_hoisted_30$2,[createVNode(unref(bngUnit_default),{class:`money`,money:unref(vehiclePurchaseStore).finalPackagePrice-unref(vehiclePurchaseStore).playerMoney},null,8,[`money`])])])):createCommentVNode(``,!0),createBaseVNode(`div`,_hoisted_31$2,[_cache[12]||=createBaseVNode(`h4`,null,`Purchase Options`,-1),createVNode(unref(bngButton_default),{disabled:!unref(vehiclePurchaseStore).vehicleInfo.negotiationPossible,accent:`secondary`,onClick:negotiatePrice},{default:withCtx(()=>[..._cache[8]||=[createTextVNode(` Negotiate Price `,-1)]]),_:1},8,[`disabled`]),withDirectives((openBlock(),createBlock(unref(bngButton_default),{disabled:!unref(vehiclePurchaseStore).tradeInEnabled||!hasVehicle.value,accent:`secondary`,onClick:chooseTradeInVehicle},{default:withCtx(()=>[..._cache[9]||=[createTextVNode(`Choose Trade-In`,-1)]]),_:1},8,[`disabled`])),[[unref(BngTooltip_default),tradeInButtonMessage.value,`top`]]),unref(vehiclePurchaseStore).tradeInEnabled&&unref(vehiclePurchaseStore).tradeInVehicleInfo.niceName?(openBlock(),createBlock(unref(bngButton_default),{key:0,onClick:removeTradeInVehicle,accent:unref(ACCENTS).attention},{default:withCtx(()=>[..._cache[10]||=[createTextVNode(`Remove Trade-In`,-1)]]),_:1},8,[`accent`])):createCommentVNode(``,!0),createVNode(unref(bngButton_default),{onClick:chooseInsurance,accent:unref(ACCENTS).secondary},{default:withCtx(()=>[..._cache[11]||=[createTextVNode(`Choose Insurance`,-1)]]),_:1},8,[`accent`])])])]),_:1})),[[unref(BngBlur_default),1]]):createCommentVNode(``,!0),createBaseVNode(`div`,_hoisted_36$1,[createVNode(unref(bngCard_default),{class:`status-container`},{default:withCtx(()=>[createVNode(unref(careerStatus_default),{class:`profile-status`})]),_:1}),createVNode(TaskList_default,{class:`task-list`,header:unref(store$1).header,tasks:unref(store$1).tasks},null,8,[`header`,`tasks`])])]),_:1}))}},VehiclePurchaseMain_default=__plugin_vue_export_helper_default(_sfc_main$142,[[`__scopeId`,`data-v-b2028538`]]);const useVehicleShoppingStore=defineStore(`vehicleShopping`,()=>{let selectedSellerId=ref(``),currentSeller=ref({}),vehicleShoppingData=ref({}),filteredVehicles=ref([]),filteredSoldVehicles=ref([]),buildFilteredListByKey=(data,key)=>{if(!data||!data[key])return[];let filteredList=Object.keys(data[key]).reduce((result,itemKey)=>{let item=data[key][itemKey];return selectedSellerId.value?item.sellerId===selectedSellerId.value&&result.push(item):result.push(item),result},[]);return filteredList.length&&filteredList.sort((a$1,b)=>a$1.Value-b.Value),filteredList},updateListsFromData=()=>{filteredVehicles.value=buildFilteredListByKey(vehicleShoppingData.value,`vehiclesInShop`),filteredSoldVehicles.value=buildFilteredListByKey(vehicleShoppingData.value,`soldVehicles`)};return{vehicleShoppingData,filteredVehicles,filteredSoldVehicles,currentSeller,requestVehicleShoppingData:async()=>{vehicleShoppingData.value=await Lua_default.career_modules_vehicleShopping.getShoppingData(),updateListsFromData()},setSelectedSellerId:sellerId=>{selectedSellerId.value=sellerId,updateListsFromData(),currentSeller.value=vehicleShoppingData.value.uiDealershipsData.find(dealership=>dealership.id===sellerId)}}});var _hoisted_1$128={class:`cover-container`},_hoisted_2$108={key:0,class:`sold-overlay`},_hoisted_3$96={class:`car-details`},_hoisted_4$76={class:`car-value`},_hoisted_5$65={class:`name`},_hoisted_6$51={class:`brand`},_hoisted_7$43={class:`main-data`},_hoisted_8$35={key:0,class:`price`},_hoisted_9$32={class:`was`},_hoisted_10$26={class:`sold`},_hoisted_11$24={key:0,class:`market`},_hoisted_12$19={key:1,class:`price`},_hoisted_13$17={key:0},_hoisted_14$17={key:1,style:{color:`rgb(245, 29, 29)`}},_hoisted_15$17={key:2,class:`market`},_hoisted_16$17={class:`car-data`},_hoisted_17$13={style:{width:`100%`}},_hoisted_18$11={key:0,style:{flex:`1 0 auto`,"justify-content":`flex-end`,padding:`0.5em 0.75em`,"font-weight":`400`,"font-family":`var(--fnt-defs)`}},DRIVE_TRAIN_ICONS={AWD:icons.AWD,"4WD":icons[`4WD`],FWD:icons.FWD,RWD:icons.RWD,drivetrain_special:icons.drivetrainSpecial,drivetrain_generic:icons.drivetrainGeneric,defaultMissing:icons.drivetrainGeneric,defaultUnknown:icons.drivetrainGeneric},FUEL_TYPE_ICONS={Battery:icons.charge,Gasoline:icons.fuelPump,Diesel:icons.fuelPump,defaultMissing:icons.fuelPump,defaultUnknown:icons.fuelPump},TRANSMISSION_ICONS={Automatic:icons.transmissionA,Manual:icons.transmissionM,defaultMissing:icons.transmissionM,defaultUnknown:icons.transmissionM},_sfc_main$141={__name:`VehicleCard`,props:{vehicleShoppingData:Object,vehicle:Object},setup(__props){let{units}=useBridge(),props=__props,soldPercent=computed(()=>{let asking=props.vehicle?.Value,sold=props.vehicle?.soldFor;return!asking||!sold?0:(sold-asking)/asking*100}),soldDeltaPrefix=computed(()=>soldPercent.value>=0?`+`:``),soldDeltaClass=computed(()=>soldPercent.value>0?`up`:soldPercent.value<0?`down`:`flat`),confirmTaxi=async vehicle=>{await openConfirmation(``,`Do you want to taxi to this vehicle for ${units.beamBucks(vehicle.quickTravelPrice)}?`,[{label:$translate.instant(`ui.common.yes`),value:!0,extras:{default:!0}},{label:$translate.instant(`ui.common.no`),value:!1,extras:{accent:ACCENTS.secondary}}])&&quickTravelToVehicle(vehicle)},showVehicle=shopId=>{Lua_default.career_modules_vehicleShopping.showVehicle(shopId)},quickTravelToVehicle=vehicle=>{Lua_default.career_modules_vehicleShopping.quickTravelToVehicle(vehicle.shopId)},openPurchaseMenu=(purchaseType,shopId)=>{Lua_default.career_modules_vehicleShopping.openPurchaseMenu(purchaseType,shopId)},getAttributeIcon=(vehicle,attribute)=>{let iconDict;return attribute==`Drivetrain`?iconDict=DRIVE_TRAIN_ICONS:attribute==`Fuel Type`?iconDict=FUEL_TYPE_ICONS:attribute==`Transmission`&&(iconDict=TRANSMISSION_ICONS),vehicle[attribute]?iconDict[vehicle[attribute]]||iconDict.defaultUnknown:iconDict.defaultMissing};return(_ctx,_cache)=>(openBlock(),createBlock(unref(bngCard_default),{class:normalizeClass(`vehicle-card row`)},{buttons:withCtx(()=>[createBaseVNode(`div`,_hoisted_17$13,[__props.vehicleShoppingData.currentSeller?createCommentVNode(``,!0):(openBlock(),createBlock(unref(bngPropVal_default),{key:0,style:{float:`left`},keyLabel:`Seller:`,valueLabel:__props.vehicle.sellerName},null,8,[`valueLabel`])),__props.vehicleShoppingData.currentSeller?createCommentVNode(``,!0):(openBlock(),createBlock(unref(bngPropVal_default),{key:1,style:{float:`left`},keyLabel:`Distance:`,valueLabel:unref(units).buildString(`length`,__props.vehicle.distance,1)},null,8,[`valueLabel`])),createVNode(unref(bngPropVal_default),{style:{float:`left`},keyLabel:`Insurance Class:`,valueLabel:__props.vehicle.insuranceClass?.name??`Unknown`},null,8,[`valueLabel`])]),__props.vehicleShoppingData.disableShopping?(openBlock(),createElementBlock(`span`,_hoisted_18$11,toDisplayString(__props.vehicleShoppingData.disableShoppingReason),1)):createCommentVNode(``,!0),__props.vehicle.sellerId===__props.vehicleShoppingData.currentSeller?(openBlock(),createBlock(unref(bngButton_default),{key:1,onClick:_cache[0]||=$event=>showVehicle(__props.vehicle.shopId),accent:unref(ACCENTS).secondary,disabled:__props.vehicleShoppingData.disableShopping||!!__props.vehicle.soldViewCounter},{default:withCtx(()=>[..._cache[10]||=[createTextVNode(`Inspect Vehicle`,-1)]]),_:1},8,[`accent`,`disabled`])):(openBlock(),createBlock(unref(bngButton_default),{key:2,onClick:_cache[1]||=$event=>showVehicle(__props.vehicle.shopId),accent:unref(ACCENTS).secondary,disabled:__props.vehicleShoppingData.disableShopping||!!__props.vehicle.soldViewCounter},{default:withCtx(()=>[..._cache[11]||=[createTextVNode(`Set Route`,-1)]]),_:1},8,[`accent`,`disabled`])),__props.vehicleShoppingData.currentSeller?createCommentVNode(``,!0):(openBlock(),createBlock(unref(bngButton_default),{key:3,disabled:__props.vehicleShoppingData.playerAttributes.money.value<__props.vehicle.quickTravelPrice||__props.vehicleShoppingData.disableShopping||!!__props.vehicle.soldViewCounter,onClick:_cache[2]||=$event=>confirmTaxi(__props.vehicle),accent:__props.vehicle.sellerId===`private`?unref(ACCENTS).main:unref(ACCENTS).secondary},{default:withCtx(()=>[..._cache[12]||=[createBaseVNode(`span`,{style:{flex:`1 0 auto`}},`Take Taxi`,-1)]]),_:1},8,[`disabled`,`accent`])),__props.vehicle.sellerId===`private`?createCommentVNode(``,!0):(openBlock(),createBlock(unref(bngButton_default),{key:4,disabled:__props.vehicleShoppingData.tutorialPurchase||__props.vehicleShoppingData.disableShopping||!!__props.vehicle.soldViewCounter,onClick:_cache[3]||=$event=>openPurchaseMenu(`instant`,__props.vehicle.shopId)},{default:withCtx(()=>[..._cache[13]||=[createTextVNode(`Purchase`,-1)]]),_:1},8,[`disabled`]))]),default:withCtx(()=>[createBaseVNode(`div`,_hoisted_1$128,[createVNode(unref(aspectRatio_default),{class:`cover`,ratio:`16:9`,"external-image":__props.vehicle.preview},null,8,[`external-image`]),__props.vehicle.soldViewCounter>0?(openBlock(),createElementBlock(`div`,_hoisted_2$108,`SOLD`)):createCommentVNode(``,!0)]),createBaseVNode(`div`,_hoisted_3$96,[createBaseVNode(`div`,_hoisted_4$76,[createBaseVNode(`div`,{class:normalizeClass([`car-name`,{sold:__props.vehicle.soldViewCounter>0}])},[createBaseVNode(`h3`,_hoisted_5$65,toDisplayString(__props.vehicle.year)+` `+toDisplayString(__props.vehicle.Name)+` `+toDisplayString(__props.vehicle.soldViewCounter>0?` (Sold)`:``),1),createBaseVNode(`div`,_hoisted_6$51,toDisplayString(__props.vehicle.Brand),1)],2),createBaseVNode(`div`,_hoisted_7$43,[createVNode(unref(bngPropVal_default),{class:`prop-small`,iconColor:`var(--bng-cool-gray-300)`,iconType:unref(icons).bus,valueLabel:unref(units).buildString(`length`,__props.vehicle.Mileage,0)},null,8,[`iconType`,`valueLabel`]),createVNode(unref(bngPropVal_default),{class:`prop-small`,style:{flex:`1 0 auto`},iconColor:`var(--bng-cool-gray-300)`,iconType:unref(icons).bus,valueLabel:__props.vehicle.Drivetrain},null,8,[`iconType`,`valueLabel`]),__props.vehicle.soldFor?(openBlock(),createElementBlock(`div`,_hoisted_8$35,[createBaseVNode(`div`,_hoisted_9$32,[_cache[4]||=createTextVNode(`Was: `,-1),createVNode(unref(bngUnit_default),{money:__props.vehicle.Value},null,8,[`money`])]),createBaseVNode(`div`,_hoisted_10$26,[_cache[5]||=createTextVNode(`Sold for: `,-1),createVNode(unref(bngUnit_default),{class:`car-price`,money:__props.vehicle.soldFor},null,8,[`money`])]),createBaseVNode(`div`,{class:normalizeClass([`delta`,soldDeltaClass.value])},toDisplayString(soldDeltaPrefix.value)+toDisplayString(soldPercent.value.toFixed(1))+`% from asking`,3),__props.vehicle.marketValue?(openBlock(),createElementBlock(`div`,_hoisted_11$24,[_cache[6]||=createTextVNode(`Market: `,-1),createVNode(unref(bngUnit_default),{money:__props.vehicle.marketValue},null,8,[`money`])])):createCommentVNode(``,!0)])):(openBlock(),createElementBlock(`div`,_hoisted_12$19,[__props.vehicle.Value<=__props.vehicleShoppingData.playerAttributes.money.value?(openBlock(),createElementBlock(`div`,_hoisted_13$17,[createVNode(unref(bngUnit_default),{class:`car-price`,money:__props.vehicle.Value},null,8,[`money`]),_cache[7]||=createTextVNode(`*`,-1)])):(openBlock(),createElementBlock(`div`,_hoisted_14$17,[createVNode(unref(bngUnit_default),{class:`car-price`,money:__props.vehicle.Value},null,8,[`money`]),_cache[8]||=createTextVNode(`* Insufficient Funds`,-1)])),__props.vehicle.marketValue?(openBlock(),createElementBlock(`div`,_hoisted_15$17,[_cache[9]||=createTextVNode(`Market: `,-1),createVNode(unref(bngUnit_default),{money:__props.vehicle.marketValue},null,8,[`money`])])):createCommentVNode(``,!0)]))])]),createBaseVNode(`div`,_hoisted_16$17,[__props.vehicle.Power==null?createCommentVNode(``,!0):(openBlock(),createBlock(unref(bngPropVal_default),{key:0,iconType:unref(icons).powerGauge04,keyLabel:`Power:`,valueLabel:unref(units).buildString(`power`,__props.vehicle.Power,0)},null,8,[`iconType`,`valueLabel`])),__props.vehicle.Mileage==null?createCommentVNode(``,!0):(openBlock(),createBlock(unref(bngPropVal_default),{key:1,iconType:unref(icons).odometer,keyLabel:`Mileage:`,valueLabel:unref(units).buildString(`length`,__props.vehicle.Mileage,0)},null,8,[`iconType`,`valueLabel`])),__props.vehicle.Transmission==null?createCommentVNode(``,!0):(openBlock(),createBlock(unref(bngPropVal_default),{key:2,iconType:getAttributeIcon(__props.vehicle,`Transmission`),keyLabel:`Transmission:`,valueLabel:__props.vehicle.Transmission},null,8,[`iconType`,`valueLabel`])),__props.vehicle[`Fuel Type`]==null?createCommentVNode(``,!0):(openBlock(),createBlock(unref(bngPropVal_default),{key:3,iconType:getAttributeIcon(__props.vehicle,`Fuel Type`),keyLabel:`Fuel type:`,valueLabel:__props.vehicle[`Fuel Type`]},null,8,[`iconType`,`valueLabel`])),__props.vehicle.Drivetrain==null?createCommentVNode(``,!0):(openBlock(),createBlock(unref(bngPropVal_default),{key:4,iconType:getAttributeIcon(__props.vehicle,`Drivetrain`),keyLabel:`Drivetrain:`,valueLabel:__props.vehicle.Drivetrain},null,8,[`iconType`,`valueLabel`])),__props.vehicle.Weight==null?createCommentVNode(``,!0):(openBlock(),createBlock(unref(bngPropVal_default),{key:5,iconType:unref(icons).weight,keyLabel:`Weight:`,valueLabel:unref(units).buildString(`weight`,__props.vehicle.Weight,0)},null,8,[`iconType`,`valueLabel`]))])])]),_:1}))}},VehicleCard_default=__plugin_vue_export_helper_default(_sfc_main$141,[[`__scopeId`,`data-v-dea06661`]]),_hoisted_1$127={class:`site-body`,"bng-nav-scroll":``,"bng-nav-scroll-force":``},_hoisted_2$107={class:`heading`},_hoisted_3$95={class:`header-text`},_hoisted_4$75={key:0,class:`vehicle-list`},_hoisted_5$64={key:1,class:`vehicle-list sold-list`},_hoisted_6$50={class:`list-section-title`},_sfc_main$140={__name:`VehicleList`,setup(__props){useUINavScope(`vehicleList`);let vehicleShoppingStore=useVehicleShoppingStore(),getHeaderText=()=>vehicleShoppingStore?.currentSeller?.name||`BeamCar24`;return reactive([{name:`switch`,selected:!0,class:``},{name:`me`,selected:!1,class:``},{name:`please`,selected:!1,class:``}]),(_ctx,_cache)=>withDirectives((openBlock(),createBlock(unref(bngCard_default),{class:`vehicle-shop-wrapper`,"bng-ui-scope":`vehicleList`},{default:withCtx(()=>[createBaseVNode(`div`,_hoisted_1$127,[createBaseVNode(`div`,_hoisted_2$107,[createBaseVNode(`span`,_hoisted_3$95,toDisplayString(getHeaderText()),1),_cache[0]||=createBaseVNode(`span`,{class:`price-notice`},[createBaseVNode(`span`,null,`*\xA0`),createBaseVNode(`span`,null,`Additional taxes and fees are applicable`)],-1)]),unref(vehicleShoppingStore)?(openBlock(),createElementBlock(`div`,_hoisted_4$75,[(openBlock(!0),createElementBlock(Fragment,null,renderList(unref(vehicleShoppingStore).filteredVehicles,(vehicle,key)=>(openBlock(),createBlock(VehicleCard_default,{key,vehicleShoppingData:unref(vehicleShoppingStore).vehicleShoppingData,vehicle},null,8,[`vehicleShoppingData`,`vehicle`]))),128))])):createCommentVNode(``,!0),unref(vehicleShoppingStore)&&unref(vehicleShoppingStore).filteredSoldVehicles&&unref(vehicleShoppingStore).filteredSoldVehicles.length>0?(openBlock(),createElementBlock(`div`,_hoisted_5$64,[createBaseVNode(`div`,_hoisted_6$50,`Recently Sold Vehicles You Viewed (`+toDisplayString(unref(vehicleShoppingStore).filteredSoldVehicles.length)+`)`,1),(openBlock(!0),createElementBlock(Fragment,null,renderList(unref(vehicleShoppingStore).filteredSoldVehicles,(vehicle,key)=>(openBlock(),createBlock(VehicleCard_default,{key,vehicleShoppingData:unref(vehicleShoppingStore).vehicleShoppingData,vehicle},null,8,[`vehicleShoppingData`,`vehicle`]))),128))])):createCommentVNode(``,!0)])]),_:1})),[[unref(BngBlur_default)]])}},VehicleList_default=__plugin_vue_export_helper_default(_sfc_main$140,[[`__scopeId`,`data-v-5045aa89`]]),_hoisted_1$126={class:`veh-part-caption`},_hoisted_2$106={class:`veh-name`},_hoisted_3$94={class:`veh-name-count`},_hoisted_4$74={class:`veh-price`},_hoisted_5$63={class:`veh-remove`},_hoisted_6$49={key:0,class:`offer-card red`},_hoisted_7$42=[`onMouseover`,`onMouseleave`,`onActivate`,`onDeactivate`],_hoisted_8$34={class:`offer-info`},_hoisted_9$31={class:`offer-header`},_hoisted_10$25={class:`buyer-name`},_hoisted_11$23={key:0,class:`expired-badge`},_hoisted_12$18={class:`offer-details`},_hoisted_13$16={class:`detail-row`},_hoisted_14$16={class:`detail-row`},_hoisted_15$16={class:`spec-actions`},_hoisted_16$16={key:1,class:`offer-card`},_sfc_main$139={__name:`VehicleMarketplace`,setup(__props){useComputerStore();let listings=ref([]),confirmRemoveListingScreen=async listingId=>{await openConfirmation(``,`Do you want to remove this listing?`,[{label:$translate.instant(`ui.common.yes`),value:!0,extras:{default:!0}},{label:$translate.instant(`ui.common.no`),value:!1,extras:{accent:ACCENTS.secondary}}])&&removeVehicleListing(listingId)},onActivated$1=offer=>{offer.active=!0},onDeactivated$1=offer=>{offer.active=!1},onOfferHovered=offer=>{offer.hovered=!0},onOfferUnhovered=offer=>{offer.hovered=!1},handleListings=data=>{listings.value=data},getNewData=()=>{Lua_default.career_modules_marketplace.getListings().then(handleListings)},acceptOffer=(inventoryId,offerIndex)=>{Lua_default.career_modules_marketplace.acceptOffer(inventoryId,offerIndex+1).then(getNewData)},declineOffer=(inventoryId,offerIndex)=>{Lua_default.career_modules_marketplace.declineOffer(inventoryId,offerIndex+1).then(getNewData)},startNegotiateBuyingOffer=(inventoryId,offerIndex)=>{Lua_default.career_modules_marketplace.startNegotiateBuyingOffer(inventoryId,offerIndex+1).then(getNewData)},removeVehicleListing=inventoryId=>{Lua_default.career_modules_marketplace.removeVehicleListing(inventoryId).then(getNewData)},listVehicle=()=>{Lua_default.career_modules_inventory.openInventoryMenuForChoosingListing()};return onMounted(()=>{Lua_default.career_modules_marketplace.menuOpened(!0),getNewData()}),onUnmounted(()=>{Lua_default.career_modules_marketplace.menuOpened(!1)}),(_ctx,_cache)=>(openBlock(),createElementBlock(Fragment,null,[createVNode(unref(accordion_default),{class:`part-groups`,items:listings.value},{default:withCtx(()=>[(openBlock(!0),createElementBlock(Fragment,null,renderList(listings.value,listing=>(openBlock(),createBlock(unref(accordionItem_default),{key:listing.id,expanded:!0,class:normalizeClass([`marketplace-listing`,{disabled:listing.disabled}])},{caption:withCtx(()=>[createBaseVNode(`div`,_hoisted_1$126,[listing.thumbnail?(openBlock(),createElementBlock(`div`,{key:0,class:`veh-preview`,style:normalizeStyle({backgroundImage:`url('${listing.thumbnail}')`})},null,4)):createCommentVNode(``,!0),createBaseVNode(`span`,_hoisted_2$106,[createTextVNode(toDisplayString(listing.niceName)+` `,1),createBaseVNode(`span`,_hoisted_3$94,`(`+toDisplayString(listing.offers.length||0)+`)`,1)]),createBaseVNode(`span`,_hoisted_4$74,[createBaseVNode(`div`,null,[_cache[0]||=createTextVNode(` Asking Price: `,-1),createVNode(unref(bngUnit_default),{money:listing.value},null,8,[`money`])]),createBaseVNode(`div`,null,[_cache[1]||=createTextVNode(` Estimated Market Value: `,-1),createVNode(unref(bngUnit_default),{money:listing.marketValue},null,8,[`money`])])]),createBaseVNode(`span`,_hoisted_5$63,[createVNode(unref(bngButton_default),{onClick:withModifiers($event=>confirmRemoveListingScreen(listing.id),[`stop`]),icon:unref(icons).trashBin1,accent:unref(ACCENTS).attentionghost},null,8,[`onClick`,`icon`,`accent`])])])]),default:withCtx(()=>[listing.disabled?(openBlock(),createElementBlock(`div`,_hoisted_6$49,toDisplayString(listing.disableReason),1)):createCommentVNode(``,!0),(openBlock(!0),createElementBlock(Fragment,null,renderList(listing.offers,(offer,index)=>withDirectives((openBlock(),createElementBlock(`div`,{class:normalizeClass([`offer-card`,{expired:offer.expiredViewCounter==1}]),onMouseover:$event=>onOfferHovered(offer),onMouseleave:$event=>onOfferUnhovered(offer),onActivate:$event=>onActivated$1(offer),onDeactivate:$event=>onDeactivated$1(offer)},[createBaseVNode(`div`,_hoisted_8$34,[createBaseVNode(`div`,_hoisted_9$31,[createBaseVNode(`span`,_hoisted_10$25,toDisplayString(offer.buyerPersonality.name),1),offer.expiredViewCounter?(openBlock(),createElementBlock(`span`,_hoisted_11$23,`EXPIRED`)):createCommentVNode(``,!0)]),createBaseVNode(`div`,_hoisted_12$18,[createBaseVNode(`div`,_hoisted_13$16,[_cache[3]||=createBaseVNode(`span`,{class:`detail-label`},`Offer:`,-1),createVNode(unref(bngUnit_default),{money:offer.value},null,8,[`money`]),createBaseVNode(`span`,{class:normalizeClass([`delta`,{up:offer.value>listing.value,down:offer.valuelisting.value?`+`:`-`),1),createVNode(unref(bngUnit_default),{money:Math.abs(offer.value-listing.value)},null,8,[`money`]),_cache[2]||=createTextVNode(`) `,-1)],2)]),createBaseVNode(`div`,_hoisted_14$16,[_cache[4]||=createBaseVNode(`span`,{class:`detail-label`},`Vehicle:`,-1),createBaseVNode(`span`,null,toDisplayString(listing.niceName),1)])])]),createBaseVNode(`div`,_hoisted_15$16,[createVNode(unref(bngButton_default),{class:`part-button`,onClick:$event=>declineOffer(listing.id,index),accent:unref(ACCENTS).attention},{default:withCtx(()=>[createTextVNode(toDisplayString(offer.expiredViewCounter?`Discard`:`Deny`),1)]),_:2},1032,[`onClick`,`accent`]),offer.expiredViewCounter?createCommentVNode(``,!0):(openBlock(),createBlock(unref(bngButton_default),{key:0,class:`part-button negotiate-button`,onClick:$event=>startNegotiateBuyingOffer(listing.id,index),accent:unref(ACCENTS).secondary,disabled:!offer.negotiationPossible||offer.value>=listing.value||listing.disabled},{default:withCtx(()=>[..._cache[5]||=[createTextVNode(` Negotiate `,-1)]]),_:1},8,[`onClick`,`accent`,`disabled`])),offer.expiredViewCounter?createCommentVNode(``,!0):(openBlock(),createBlock(unref(bngButton_default),{key:1,class:`part-button`,onClick:$event=>acceptOffer(listing.id,index),disabled:listing.disabled||offer.disabled,accent:unref(ACCENTS).main},{default:withCtx(()=>[..._cache[6]||=[createTextVNode(` Accept Offer `,-1)]]),_:1},8,[`onClick`,`disabled`,`accent`]))])],42,_hoisted_7$42)),[[unref(BngScopedNav_default)]])),256)),Object.keys(listing.offers||{}).length===0?(openBlock(),createElementBlock(`div`,_hoisted_16$16,toDisplayString(unref($translate).instant(`ui.career.vehicleMarketplace.noOffers`)),1)):createCommentVNode(``,!0)]),_:2},1032,[`class`]))),128))]),_:1},8,[`items`]),createVNode(unref(bngButton_default),{class:`add-listing-button`,onClick:listVehicle,accent:unref(ACCENTS).custom},{default:withCtx(()=>[..._cache[7]||=[createBaseVNode(`span`,{class:`add-listing-button-icon`},`+`,-1),createTextVNode(` Add Listing `,-1)]]),_:1},8,[`accent`])],64))}},VehicleMarketplace_default=__plugin_vue_export_helper_default(_sfc_main$139,[[`__scopeId`,`data-v-468e550d`]]),_hoisted_1$125={class:`flex-container`},_hoisted_2$105={class:`content`},_hoisted_3$93={key:0},_hoisted_4$73={class:`seller-grid`},_hoisted_5$62={class:`seller-card__label`},_hoisted_6$48={class:`seller-card__header`},_hoisted_7$41={class:`seller-card__title`},_hoisted_8$33={key:0,class:`seller-card__subtitle`},_hoisted_9$30={class:`seller-card__vehicle-thumbnails`},_hoisted_10$24={class:`seller-card__vehicle-thumbnail`},_hoisted_11$22={key:0,class:`more-label`},_hoisted_12$17={key:1},buyVehicleTitle=`Buy Vehicles`,sellVehicleTitle=`Sell Vehicles`,_sfc_main$138={__name:`VehicleShoppingMain`,props:{screenTag:{type:String,default:``},buyingAvailable:{type:String,default:`true`},marketplaceAvailable:{type:String,default:`true`},selectedSellerId:{type:String,default:``}},setup(__props){useUINavScope(`vehicleShopping`),useComputerStore();let vehicleShoppingStore=useVehicleShoppingStore(),selectedTab=ref(0),selectedSellerId=ref(``),router$1=useRouter(),loaded=ref(!1),selectSeller=sellerId=>{setSelectedSellerId(sellerId),updateRouteScreenTag()},tabs=computed(()=>{let tabs$1=[];return props.buyingAvailable===`true`&&tabs$1.push(buyVehicleTitle),props.marketplaceAvailable===`true`&&tabs$1.push(sellVehicleTitle),tabs$1}),props=__props,processTabInput=event=>{event.detail.name===`tab_l`?selectedTab.value=(selectedTab.value-1+tabs.value.length)%tabs.value.length:event.detail.name===`tab_r`&&(selectedTab.value=(selectedTab.value+1)%tabs.value.length)},onTabsChange=(tab,old)=>{let idx=tabs.value.indexOf(tab&&tab.heading?tab.heading:``);idx!==-1&&(selectedTab.value=idx),selectedTab.value===tabs.value.indexOf(buyVehicleTitle)&&(selectedSellerId.value=``)},headerTitle=computed(()=>{switch(tabs.value[selectedTab.value]){case buyVehicleTitle:return`Buy Vehicles`;case sellVehicleTitle:return`Sell Vehicles`;default:return`Available Vehicles`}}),updateRouteScreenTag=()=>{let screenTag=selectedTab.value===tabs.value.indexOf(sellVehicleTitle)?`marketplace`:`buying`;router$1.replace({name:`vehicleShopping`,params:{screenTag,buyingAvailable:props.buyingAvailable,marketplaceAvailable:props.marketplaceAvailable,selectedSellerId:selectedSellerId.value}})};watch(selectedTab,()=>{updateRouteScreenTag()});let setSelectedSellerId=sellerId=>{selectedSellerId.value=sellerId,vehicleShoppingStore.setSelectedSellerId(selectedSellerId.value)},dealershipVehiclesMap=computed(()=>{let map=new Map;return vehicleShoppingStore.vehicleShoppingData.vehiclesInShop&&vehicleShoppingStore.vehicleShoppingData.vehiclesInShop.filter(vehicle=>vehicle.preview).forEach(vehicle=>{map.has(vehicle.sellerId)||map.set(vehicle.sellerId,[]),map.get(vehicle.sellerId).push(vehicle)}),map}),getDealershipVehicles=dealershipId=>dealershipVehiclesMap.value.get(dealershipId)||[],start=()=>{nextTick(async()=>{await vehicleShoppingStore.requestVehicleShoppingData(),loaded.value=!0,vehicleShoppingStore.vehicleShoppingData.currentSeller?setSelectedSellerId(vehicleShoppingStore.vehicleShoppingData.currentSeller):setSelectedSellerId(props.selectedSellerId),props.screenTag==`buying`?selectedTab.value=tabs.value.indexOf(buyVehicleTitle):props.screenTag==`marketplace`?selectedTab.value=tabs.value.indexOf(sellVehicleTitle):selectedTab.value=0,updateRouteScreenTag()})},kill=async()=>{await Lua_default.career_modules_vehicleShopping.onShoppingMenuClosed(),vehicleShoppingStore.$dispose()},close=()=>{!vehicleShoppingStore.vehicleShoppingData.currentSeller&&selectedTab.value===tabs.value.indexOf(buyVehicleTitle)&&selectedSellerId.value?selectedSellerId.value=``:router$1.back()};return onMounted(start),onUnmounted(kill),(_ctx,_cache)=>withDirectives((openBlock(),createBlock(ComputerWrapper_default,{path:[unref(vehicleShoppingStore).vehicleShoppingData.currentSellerNiceName||`Vehicle Marketplace`],title:headerTitle.value,"bng-ui-scope":`vehicleShopping`,back:``,onBack:close},{status:withCtx(()=>[createTextVNode(` Free Inventory Slots: `+toDisplayString(unref(vehicleShoppingStore)?unref(vehicleShoppingStore).vehicleShoppingData.numberOfFreeSlots:0),1)]),default:withCtx(()=>[createBaseVNode(`div`,_hoisted_1$125,[withDirectives((openBlock(),createElementBlock(`div`,_hoisted_2$105,[createVNode(unref(tabs_default),{class:normalizeClass([`bng-tabs`,{"single-tab":tabs.value.length===1}]),selectedIndex:selectedTab.value,onChange:onTabsChange},{default:withCtx(()=>[createVNode(unref(tabList_default)),props.buyingAvailable===`true`?(openBlock(),createElementBlock(`div`,{key:0,"tab-heading":buyVehicleTitle,class:`buying-tab-content`},[loaded.value&&!selectedSellerId.value?(openBlock(),createBlock(unref(bngCard_default),{key:0,class:`buying-card`},{default:withCtx(()=>[unref(vehicleShoppingStore).vehicleShoppingData.uiDealershipsData&&Object.keys(unref(vehicleShoppingStore).vehicleShoppingData.uiDealershipsData).length?(openBlock(),createElementBlock(`div`,_hoisted_3$93,[createBaseVNode(`div`,_hoisted_4$73,[(openBlock(!0),createElementBlock(Fragment,null,renderList(unref(vehicleShoppingStore).vehicleShoppingData.uiDealershipsData,dealership=>(openBlock(),createBlock(unref(bngTile_default),{key:dealership.id,class:`seller-card`,style:normalizeStyle({backgroundImage:`linear-gradient(180deg, rgba(0,0,0,0.9), rgba(0,0,0,0)), url(`+(dealership.preview&&dealership.preview[0]===`/`?dealership.preview:`/`+dealership.preview)+`)`}),onClick:$event=>dealership.vehicleCount&&selectSeller(dealership.id)},{label:withCtx(()=>[createBaseVNode(`div`,_hoisted_5$62,[createBaseVNode(`div`,_hoisted_6$48,[createBaseVNode(`div`,_hoisted_7$41,[createVNode(unref(bngIcon_default),{type:dealership.icon},null,8,[`type`]),createTextVNode(toDisplayString(dealership.name),1)]),dealership.description?(openBlock(),createElementBlock(`div`,_hoisted_8$33,toDisplayString(dealership.description),1)):createCommentVNode(``,!0)]),createBaseVNode(`div`,_hoisted_9$30,[(openBlock(!0),createElementBlock(Fragment,null,renderList(getDealershipVehicles(dealership.id).slice(0,5),(vehicle,index)=>(openBlock(),createElementBlock(`div`,_hoisted_10$24,[createVNode(unref(aspectRatio_default),{ratio:`16:9`,class:`seller-card__vehicle-thumbnail-image`,"external-image":vehicle.preview},{default:withCtx(()=>[index==0&&getDealershipVehicles(dealership.id).length>5?(openBlock(),createElementBlock(`div`,_hoisted_11$22,` +`+toDisplayString(getDealershipVehicles(dealership.id).length-4),1)):createCommentVNode(``,!0)]),_:2},1032,[`external-image`])]))),256))])])]),_:2},1032,[`style`,`onClick`]))),128))])])):(openBlock(),createElementBlock(`div`,_hoisted_12$17,[..._cache[0]||=[createBaseVNode(`span`,null,`No sellers available.`,-1)]]))]),_:1})):loaded.value?(openBlock(),createBlock(VehicleList_default,{key:1})):(openBlock(),createBlock(unref(bngCard_default),{key:2},{default:withCtx(()=>[createVNode(unref(bngCardHeading_default),{style:{color:`#fff`}},{default:withCtx(()=>[..._cache[1]||=[createTextVNode(`Please wait...`,-1)]]),_:1})]),_:1}))])):createCommentVNode(``,!0),props.marketplaceAvailable===`true`?(openBlock(),createElementBlock(`div`,{key:1,"tab-heading":sellVehicleTitle,class:`marketplace-tab-content`},[createVNode(VehicleMarketplace_default)])):createCommentVNode(``,!0)]),_:1},8,[`class`,`selectedIndex`])])),[[unref(BngBlur_default),1]])])]),_:1},8,[`path`,`title`])),[[unref(BngOnUiNav_default),processTabInput,`tab_l,tab_r`]])}},VehicleShoppingMain_default=__plugin_vue_export_helper_default(_sfc_main$138,[[`__scopeId`,`data-v-83009aa9`]]),_hoisted_1$124={style:{padding:`1em`,overflow:`auto`}},_hoisted_2$104={class:`performance-class-container`},_hoisted_3$92={key:0,class:`performance-class-wrapper`},_hoisted_4$72={class:`class-badge`},_hoisted_5$61={class:`certification-container`},_hoisted_6$47={class:`specs-section`},_hoisted_7$40={key:0},_hoisted_8$32={key:1,class:`specs-grid`},_hoisted_9$29={class:`spec-row`},_hoisted_10$23={class:`spec-label`},_hoisted_11$21={class:`spec-value`},_hoisted_12$16={class:`spec-row`},_hoisted_13$15={class:`spec-value`},_hoisted_14$15={class:`spec-row`},_hoisted_15$15={class:`spec-label`},_hoisted_16$15={class:`spec-value`},_hoisted_17$12={class:`spec-row`},_hoisted_18$10={class:`spec-label`},_hoisted_19$8={class:`spec-value`},_hoisted_20$7={class:`spec-row`},_hoisted_21$7={class:`spec-label`},_hoisted_22$6={class:`spec-value`},_hoisted_23$5={class:`spec-row`},_hoisted_24$4={class:`spec-value`},_hoisted_25$3={class:`spec-row`},_hoisted_26$2={class:`spec-value`},_hoisted_27$2={class:`specs-section`},_hoisted_28$1={key:0,class:`metrics-grid`},_hoisted_29$1={key:3,class:`performance-index-container`},_hoisted_30$1={class:`progress-wrapper`},_hoisted_31$1={class:`class-markers`},_hoisted_32$1={class:`marker-label`},_hoisted_33$1={class:`history-dropdown-container`},_hoisted_34$1={class:`dropdown`},_sfc_main$137={__name:`VehiclePerformanceTile`,props:{vehicleData:Object},setup(__props){let{units}=useBridge(),props=__props;computed(()=>props.vehicleData.niceName||`No Name`);let startTestTitle=computed(()=>props.vehicleData.needsRepair?`Assess Performance (Repair Required)`:`Assess Performance Now`),startTest=function(){Lua_default.career_modules_vehiclePerformance.startDragTest(props.vehicleData.id)},getColorForValue=(value,min$1=0,max$1=1)=>{let normalizedValue=(value-min$1)/(max$1-min$1),adjustedValue=Math.max(0,normalizedValue-.1)*(1/.9),red,green;return adjustedValue<.5?(red=200,green=Math.round(200*(adjustedValue*2))):(red=Math.round(200*(2-adjustedValue*2)),green=200),`rgb(${red}, ${green}, 0)`},selectedHistoryIndex=ref(0),allCertificationData=computed(()=>[props.vehicleData.certificationData||{noPerformanceData:!0},...props.vehicleData.performanceHistory||[]]),historyOptions=computed(()=>allCertificationData.value.length?allCertificationData.value.map((item,index)=>({value:index,label:index===0?item.noPerformanceData?`Current Test Results: No data`:`Current Test Results - `+new Date(item.timeStamp).toLocaleString():`Previous Test Results - ${new Date(item.timeStamp).toLocaleString()}`})):[]),selectedCertificationData=computed(()=>allCertificationData.value[selectedHistoryIndex.value]);return watch(()=>props.vehicleData,newVal=>{},{immediate:!0}),(_ctx,_cache)=>withDirectives((openBlock(),createBlock(unref(bngCard_default),{class:`card`},{footer:withCtx(()=>[createBaseVNode(`div`,_hoisted_33$1,[createBaseVNode(`div`,_hoisted_34$1,[_cache[8]||=createBaseVNode(`div`,{class:`dropdown-label`},`Previous Assessments`,-1),createVNode(unref(bngDropdown_default),{modelValue:selectedHistoryIndex.value,"onUpdate:modelValue":_cache[0]||=$event=>selectedHistoryIndex.value=$event,items:historyOptions.value,class:`history-select`},{default:withCtx(()=>[createTextVNode(toDisplayString(historyOptions.value[selectedHistoryIndex.value].text),1)]),_:1},8,[`modelValue`,`items`])]),createVNode(unref(bngButton_default),{onClick:_cache[1]||=$event=>startTest(),disabled:__props.vehicleData.needsRepair||!__props.vehicleData.owned},{default:withCtx(()=>[createTextVNode(toDisplayString(startTestTitle.value),1)]),_:1},8,[`disabled`])])]),default:withCtx(()=>[createBaseVNode(`div`,_hoisted_1$124,[createBaseVNode(`div`,null,[createVNode(VehicleTileRow_default,{class:`vehicle-tile-row`,data:__props.vehicleData,enableHover:!1,small:!0},null,8,[`data`]),createBaseVNode(`div`,_hoisted_2$104,[selectedCertificationData.value&&selectedCertificationData.value.vehicleClass?(openBlock(),createElementBlock(`div`,_hoisted_3$92,[createBaseVNode(`span`,_hoisted_4$72,` Class `+toDisplayString(selectedCertificationData.value.vehicleClass.class.name)+` | PI `+toDisplayString(selectedCertificationData.value.vehicleClass.performanceIndex.toFixed(0)),1)])):createCommentVNode(``,!0)])]),createBaseVNode(`div`,_hoisted_5$61,[createBaseVNode(`div`,_hoisted_6$47,[_cache[5]||=createBaseVNode(`div`,{class:`section-header`},[createBaseVNode(`h2`,null,`Technical Specifications`)],-1),selectedCertificationData.value.vehicleClass?(openBlock(),createElementBlock(`div`,_hoisted_8$32,[createBaseVNode(`div`,_hoisted_9$29,[createBaseVNode(`div`,_hoisted_10$23,toDisplayString(_ctx.$t(`ui.options.units.weight`)),1),createBaseVNode(`div`,_hoisted_11$21,toDisplayString(_ctx.$game.units.buildString(`weight`,selectedCertificationData.value.weight,0)),1)]),createBaseVNode(`div`,_hoisted_12$16,[_cache[2]||=createBaseVNode(`div`,{class:`spec-label`},`Power/Weight`,-1),createBaseVNode(`div`,_hoisted_13$15,toDisplayString(selectedCertificationData.value.powerPerTon.toFixed(0))+`hp/1000kg`,1)]),createBaseVNode(`div`,_hoisted_14$15,[createBaseVNode(`div`,_hoisted_15$15,toDisplayString(_ctx.$t(`vehicle.info.Drivetrain`)),1),createBaseVNode(`div`,_hoisted_16$15,toDisplayString(selectedCertificationData.value.drivetrain),1)]),createBaseVNode(`div`,_hoisted_17$12,[createBaseVNode(`div`,_hoisted_18$10,toDisplayString(_ctx.$t(`vehicle.info.Fuel Type`)),1),createBaseVNode(`div`,_hoisted_19$8,toDisplayString(selectedCertificationData.value.fuelType),1)]),createBaseVNode(`div`,_hoisted_20$7,[createBaseVNode(`div`,_hoisted_21$7,toDisplayString(_ctx.$t(`vehicle.info.Induction Type`)),1),createBaseVNode(`div`,_hoisted_22$6,toDisplayString(selectedCertificationData.value.inductionType),1)]),createBaseVNode(`div`,_hoisted_23$5,[_cache[3]||=createBaseVNode(`div`,{class:`spec-label`},`Mileage`,-1),createBaseVNode(`div`,_hoisted_24$4,toDisplayString(unref(units).buildString(`length`,selectedCertificationData.value.mileage,0)),1)]),createBaseVNode(`div`,_hoisted_25$3,[_cache[4]||=createBaseVNode(`div`,{class:`spec-label`},`Lateral G-Force`,-1),createBaseVNode(`div`,_hoisted_26$2,toDisplayString(selectedCertificationData.value.lateralGForce.toFixed(2))+` G`,1)])])):(openBlock(),createElementBlock(`div`,_hoisted_7$40,` Vehicle has not been assessed yet. `))]),createBaseVNode(`div`,_hoisted_27$2,[_cache[7]||=createBaseVNode(`div`,{class:`section-header`},[createBaseVNode(`h2`,null,`Metrics`)],-1),selectedCertificationData.value.vehicleClass?(openBlock(),createElementBlock(`div`,_hoisted_28$1,[selectedCertificationData.value.power?(openBlock(),createBlock(unref(bngProgressBar_default),{key:0,headerLeft:`Power Output`,headerRight:_ctx.$game.units.buildString(`power`,selectedCertificationData.value.power,0),value:selectedCertificationData.value.power,min:0,max:1e3,showValueLabel:!1,valueColor:getColorForValue(selectedCertificationData.value.power,0,1e3),class:`score-progress`},null,8,[`headerRight`,`value`,`valueColor`])):createCommentVNode(``,!0),createVNode(unref(bngProgressBar_default),{headerLeft:`0-60 mph time (prepped surface)`,headerRight:selectedCertificationData.value.time_0_60?selectedCertificationData.value.time_0_60.toFixed(2)+` s`:`N/A`,value:selectedCertificationData.value.time_0_60?-selectedCertificationData.value.time_0_60:-25,min:-25,max:-2,showValueLabel:!1,valueColor:getColorForValue(selectedCertificationData.value.time_0_60?-selectedCertificationData.value.time_0_60:-25,-25,-2),class:`score-progress`},null,8,[`headerRight`,`value`,`valueColor`]),selectedCertificationData.value.time_1_4?(openBlock(),createBlock(unref(bngProgressBar_default),{key:1,headerLeft:`Quarter Mile`,headerRight:selectedCertificationData.value.time_1_4.toFixed(2)+` s @ `+_ctx.$game.units.buildString(`speed`,selectedCertificationData.value.velAt_1_4,0),value:selectedCertificationData.value.time_1_4?-selectedCertificationData.value.time_1_4:-35,min:-35,max:-8.1,showValueLabel:!1,valueColor:getColorForValue(selectedCertificationData.value.time_1_4?-selectedCertificationData.value.time_1_4:-35,-35,-8.1),class:`score-progress`},null,8,[`headerRight`,`value`,`valueColor`])):createCommentVNode(``,!0),selectedCertificationData.value.performanceAggregateScores.brakingGForceScore?(openBlock(),createBlock(unref(bngProgressBar_default),{key:2,headerLeft:`Braking Force`,headerRight:selectedCertificationData.value.brakingG?selectedCertificationData.value.brakingG.toFixed(2)+` G`:`N/A`,value:selectedCertificationData.value.brakingG||0,min:.5,max:1.9,showValueLabel:!1,valueColor:getColorForValue(selectedCertificationData.value.brakingG||0,.5,1.9),class:`score-progress`},null,8,[`headerRight`,`value`,`valueColor`])):createCommentVNode(``,!0),selectedCertificationData.value&&selectedCertificationData.value.vehicleClass?(openBlock(),createElementBlock(`div`,_hoisted_29$1,[createBaseVNode(`div`,_hoisted_30$1,[createVNode(unref(bngProgressBar_default),{headerLeft:`Performance Index`,headerRight:`Class: `+selectedCertificationData.value.vehicleClass.class.name,value:selectedCertificationData.value.vehicleClass.performanceIndex,min:0,max:110,showValueLabel:!1,valueColor:getColorForValue(selectedCertificationData.value.vehicleClass.performanceIndex/110),class:`score-progress performance-index`},null,8,[`headerRight`,`value`,`valueColor`]),createBaseVNode(`div`,_hoisted_31$1,[(openBlock(),createElementBlock(Fragment,null,renderList([{pi:101,name:`X`},{pi:86,name:`S`},{pi:66,name:`A`},{pi:41,name:`B`},{pi:21,name:`C`}],(classInfo,index)=>createBaseVNode(`div`,{key:index,class:`class-marker`,style:normalizeStyle({left:`${classInfo.pi/110*100}%`})},[_cache[6]||=createBaseVNode(`div`,{class:`marker-line`},null,-1),createBaseVNode(`div`,_hoisted_32$1,toDisplayString(classInfo.name),1)],4)),64))])])])):createCommentVNode(``,!0)])):createCommentVNode(``,!0)])])])]),_:1})),[[unref(BngBlur_default),!0]])}},VehiclePerformanceTile_default=__plugin_vue_export_helper_default(_sfc_main$137,[[`__scopeId`,`data-v-ca2efe1a`]]),_hoisted_1$123={key:0,class:`certification-test-in-progress`},_hoisted_2$103={class:`certification-content`},_hoisted_3$91={class:`certification-icon`},_hoisted_4$71={class:`cancelButton`},_hoisted_5$60={key:1},_sfc_main$136={__name:`VehiclePerformanceMain`,props:{inventoryId:String},setup(__props){let router$1=useRouter(),vehicleData=ref({}),assessmentProgressMessage=ref(`Performance Assessment in progress...`),cancellingTest=ref(!1),testInProgress=ref(!1),{$game}=useLibStore(),title=computed(()=>vehicleData.value.niceName?`Performance Index: `+vehicleData.value.niceName:`Performance Index`),props=__props;$game.events.on(`PerformanceTestMessage`,data=>{assessmentProgressMessage.value=data.message,cancellingTest.value=!0}),$game.events.on(`PerformanceTestStarted`,data=>{testInProgress.value=data.testInProgress,getVehicleData()});let close=()=>{router$1.back()},kill=()=>{$game.events.off(`PerformanceTestMessage`),$game.events.off(`PerformanceTestStarted`)},getVehicleData=()=>{Lua_default.career_modules_inventory.getVehicleUiData(Number(props.inventoryId)).then(data=>{vehicleData.value=data})},start=()=>{getVehicleData()},cancelTest=()=>{Lua_default.career_modules_vehiclePerformance.cancelTest()};return onUnmounted(kill),onMounted(start),(_ctx,_cache)=>testInProgress.value?(openBlock(),createElementBlock(`div`,_hoisted_1$123,[createVNode(unref(bngCard_default),{class:`certification-card`},{default:withCtx(()=>[createBaseVNode(`div`,_hoisted_2$103,[createBaseVNode(`div`,null,[createBaseVNode(`div`,{class:normalizeClass([`certificationTestText`,{cancelling:cancellingTest.value}])},toDisplayString(assessmentProgressMessage.value),3)]),createBaseVNode(`div`,_hoisted_3$91,[createVNode(unref(bngIcon_default),{type:unref(icons).timeUnlockOutline},null,8,[`type`])])]),createBaseVNode(`div`,_hoisted_4$71,[withDirectives((openBlock(),createBlock(unref(bngButton_default),{accent:unref(ACCENTS).RED,onClick:cancelTest,tabindex:`0`},{default:withCtx(()=>[..._cache[0]||=[createTextVNode(` Cancel Test `,-1)]]),_:1},8,[`accent`])),[[unref(BngOnUiNav_default),void 0,`back,menu`,{asMouse:!0}]])])]),_:1})])):(openBlock(),createElementBlock(`div`,_hoisted_5$60,[createVNode(ComputerWrapper_default,{ref:`wrapper`,path:[`Performance Index`],title:title.value,back:``,onBack:close},{default:withCtx(()=>[createVNode(VehiclePerformanceTile_default,{"vehicle-data":vehicleData.value},null,8,[`vehicle-data`])]),_:1},8,[`title`])]))}},VehiclePerformanceMain_default=__plugin_vue_export_helper_default(_sfc_main$136,[[`__scopeId`,`data-v-ea737c56`]]),_hoisted_1$122={class:`offer-chat-container-wrapper`},_hoisted_2$102={key:0,class:`above`},_hoisted_3$90={key:1,class:`red`},_hoisted_4$70={key:2,class:`green`},_hoisted_5$59={key:3,class:`above`},_hoisted_6$46={key:4,class:`above`},_hoisted_7$39={key:5,class:`price`},_sfc_main$135={__name:`NegotiationChat`,props:{offerHistory:{type:Array,default:()=>[]},negotiationStatus:{type:String,default:``},startingPrice:{type:Number,default:0},amISelling:{type:Boolean,default:!1}},setup(__props,{expose:__expose}){let props=__props,offerChatContainer=ref(null),statusTextFromStatus=status=>{switch(String(status||``)){case`counterOffer`:return`Counter offer`;case`counterOfferLastChance`:return`Last chance counter offer`;case`accepted`:return`Accepted`;case`failed`:return`Negotiation failed`;case`refused`:return`Offer refused`;case`initial`:return props.amISelling?`Initial offer`:`Asking Price`;case`thinking`:return`Thinking`;default:return``}},fillInOfferHistory=history$1=>{if(!history$1||!Array.isArray(history$1))return[];let hasSeenMyOffer=!1,isFirstInitialOffer=!0;return history$1.map(item=>{let isMyOffer=item.myOffer!=null,isTheirOffer=item.theirOffer!=null,currentOffer=isMyOffer?item.myOffer:item.theirOffer,difference=null;isTheirOffer&&isFirstInitialOffer?isFirstInitialOffer=!1:difference=currentOffer-props.startingPrice;let offerStatus=null;return isMyOffer&&(hasSeenMyOffer?offerStatus=`counterOffer`:(offerStatus=`initial`,hasSeenMyOffer=!0)),isMyOffer?item.myOffer:isTheirOffer&&item.theirOffer,{theirOffer:item.theirOffer,myOffer:item.myOffer,negotiationStatus:item.negotiationStatus,messageClass:isMyOffer?`sent-message`:`received-message`,difference,offerStatus}})},typingMessageId=ref(null),previousOfferHistoryLength=ref(0);watch(()=>props.negotiationStatus,newStatus=>{newStatus===`typing`&&typingMessageId.value===null&&(typingMessageId.value=`typing-${Date.now()}`)});let processedOfferHistory=computed(()=>{let history$1=fillInOfferHistory(props.offerHistory),currentHistoryLength=(props.offerHistory||[]).length;if(currentHistoryLength>previousOfferHistoryLength.value&&typingMessageId.value!==null){let responseId=typingMessageId.value,responseData=history$1[history$1.length-1],result=[...history$1];return result[result.length-1]={...responseData,typingId:responseId,isTyping:!1},typingMessageId.value=null,previousOfferHistoryLength.value=currentHistoryLength,result}return currentHistoryLength!==previousOfferHistoryLength.value&&(previousOfferHistoryLength.value=currentHistoryLength),props.negotiationStatus===`typing`&&typingMessageId.value!==null?[...history$1,{theirOffer:null,myOffer:null,negotiationStatus:`typing`,messageClass:`received-message`,difference:null,isTyping:!0,typingId:typingMessageId.value}]:history$1});watch(processedOfferHistory,()=>{nextTick(()=>{if(offerChatContainer.value){let container=offerChatContainer.value;container.scrollHeight-container.scrollTop-container.clientHeight<100&&(container.scrollTop=container.scrollHeight)}})},{deep:!0});let scrollToBottom=()=>{nextTick(()=>{offerChatContainer.value&&(offerChatContainer.value.scrollTop=offerChatContainer.value.scrollHeight)})},reset$1=()=>{typingMessageId.value=null,previousOfferHistoryLength.value=(props.offerHistory||[]).length};return onMounted(()=>{reset$1(),scrollToBottom()}),__expose({scrollToBottom,reset:reset$1}),(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$122,[createBaseVNode(`div`,{ref_key:`offerChatContainer`,ref:offerChatContainer,class:`offer-chat-container`},[createVNode(TransitionGroup,{name:`message`,tag:`div`},{default:withCtx(()=>[(openBlock(!0),createElementBlock(Fragment,null,renderList(processedOfferHistory.value,(item,index)=>(openBlock(),createElementBlock(`div`,{key:item.typingId||`${item.myOffer||item.theirOffer||`message`}-${index}`,class:normalizeClass([`message`,item.messageClass])},[item.isTyping?(openBlock(),createElementBlock(`div`,_hoisted_2$102,[..._cache[0]||=[createBaseVNode(`span`,{class:`spinner`,"aria-label":`Typing`},null,-1),createTextVNode(` Typing... `,-1)]])):item.negotiationStatus===`failed`?(openBlock(),createElementBlock(`div`,_hoisted_3$90,[createVNode(unref(bngIcon_default),{type:`abandon`}),_cache[1]||=createTextVNode(` Negotiation failed! `,-1)])):item.negotiationStatus===`accepted`?(openBlock(),createElementBlock(`div`,_hoisted_4$70,[createVNode(unref(bngIcon_default),{type:`checkmark`,color:`var(--bng-add-green-400)`}),_cache[2]||=createTextVNode(` Accepted! `,-1)])):item.offerStatus?(openBlock(),createElementBlock(`div`,_hoisted_5$59,[item.offerStatus===`initial`?(openBlock(),createElementBlock(Fragment,{key:0},[createTextVNode(toDisplayString(props.amISelling?`Asking Price`:`Initial offer`),1)],64)):(openBlock(),createElementBlock(Fragment,{key:1},[createTextVNode(` Counter offer `)],64))])):item.negotiationStatus?(openBlock(),createElementBlock(`div`,_hoisted_6$46,toDisplayString(statusTextFromStatus(item.negotiationStatus)),1)):createCommentVNode(``,!0),!item.isTyping&&item.negotiationStatus!==`failed`&&item.negotiationStatus!==`accepted`?(openBlock(),createElementBlock(`div`,_hoisted_7$39,[createVNode(unref(bngUnit_default),{class:`money`,money:item.myOffer||item.theirOffer||0},null,8,[`money`])])):createCommentVNode(``,!0)],2))),128))]),_:1})],512)]))}},NegotiationChat_default=__plugin_vue_export_helper_default(_sfc_main$135,[[`__scopeId`,`data-v-c4558f29`]]),_hoisted_1$121={class:`price-finder-label right`},_hoisted_2$101={class:`price-finder-track`},_hoisted_3$89={key:0,class:`tick-label`},_hoisted_4$69={class:`price-finder-label left`},_sfc_main$134={__name:`PriceFinder`,props:{offerHistory:{type:Array,default:()=>[]},negotiationStatus:{type:String,default:``},startingPrice:{type:Number,default:0},offerPreview:{type:Number,default:0},actualVehicleValue:{type:Number,default:null},amISelling:{type:Boolean,default:!1}},setup(__props){let{units}=useBridge(),props=__props,priceFinderData=computed(()=>{let history$1=props.offerHistory||[];if(history$1.length===0)return null;let initialTheirOffer=null,initialMyOffer=null;for(let item of history$1)if(initialTheirOffer===null&&item.theirOffer!=null&&(initialTheirOffer=item.theirOffer),initialMyOffer===null&&item.myOffer!=null&&(initialMyOffer=item.myOffer),initialTheirOffer!==null&&initialMyOffer!==null)break;let hasBothInitialOffers=initialTheirOffer!==null&&initialMyOffer!==null;initialTheirOffer===null&&(initialTheirOffer=props.startingPrice),initialMyOffer===null&&(initialMyOffer=props.offerPreview||props.startingPrice);let offers=[],offerIndex=0,lastMyOfferIndex=-1,lastTheirOfferIndex=-1;for(let item of history$1)item.myOffer==null?item.theirOffer!=null&&(offers.push({price:item.theirOffer,isMyOffer:!1,index:offerIndex++,isUnsent:!1}),lastTheirOfferIndex=offers.length-1):(offers.push({price:item.myOffer,isMyOffer:!0,index:offerIndex++,isUnsent:!1}),lastMyOfferIndex=offers.length-1);props.negotiationStatus!==`failed`&&props.negotiationStatus!==`accepted`&&props.offerPreview>0&&(offers.push({price:props.offerPreview,isMyOffer:!0,index:offerIndex++,isUnsent:!0}),lastMyOfferIndex=offers.length-1);let leftPrice=Math.min(initialTheirOffer,initialMyOffer),rightPrice=Math.max(initialTheirOffer,initialMyOffer),topIsTheir=props.amISelling,range=rightPrice-leftPrice||1,{majorTicks,minorTicks}=((min$1,max$1,priceRange)=>{let niceNumbers=[1,2,5,10,20,50,100,200,500,1e3,2e3,5e3,1e4],tickRange=max$1-min$1;if(tickRange===0)return{majorTicks:[],minorTicks:[]};let roughStep=tickRange/4,magnitude=10**Math.floor(Math.log10(roughStep)),normalizedStep=roughStep/magnitude,closestNice=niceNumbers[0],minDiff=Math.abs(normalizedStep-closestNice);for(let nice of niceNumbers){let diff=Math.abs(normalizedStep-nice);diff=min$1&&price<=max$1){let position=(price-leftPrice)/priceRange*100;majorTicks$1.push({price,position:Math.max(0,Math.min(100,position))})}let minorStep=step/5,minorTicks$1=[];for(let price=niceMin;price<=niceMax;price+=minorStep)if(price>=min$1&&price<=max$1&&Math.abs(price%step)>.01){let position=(price-leftPrice)/priceRange*100;minorTicks$1.push({price,position:Math.max(0,Math.min(100,position))})}return{majorTicks:majorTicks$1,minorTicks:minorTicks$1}})(leftPrice,rightPrice,range),hasVisibleTicks=range>0&&majorTicks.length>0,offerPositions=offers.map((offer,index)=>{let position=(offer.price-leftPrice)/range*100,isMostRecent=offer.isMyOffer&&index===lastMyOfferIndex||!offer.isMyOffer&&index===lastTheirOfferIndex;return{...offer,position:Math.max(0,Math.min(100,position)),isMostRecent}}),marketValuePosition=null;if(hasVisibleTicks&&props.actualVehicleValue!=null&&props.actualVehicleValue>0&&props.actualVehicleValue>=leftPrice&&props.actualVehicleValue<=rightPrice){let position=(props.actualVehicleValue-leftPrice)/range*100;marketValuePosition=Math.max(0,Math.min(100,position))}let initialMarkers=[];if(hasVisibleTicks){let theirPosition=initialTheirOffer===leftPrice?0:100;initialMarkers.push({price:initialTheirOffer,isMyOffer:!1,position:theirPosition,isInitial:!0});let myPosition=initialMyOffer===leftPrice?0:100;initialMarkers.push({price:initialMyOffer,isMyOffer:!0,position:myPosition,isInitial:!0})}return{initialTheirOffer,initialMyOffer,leftPrice,rightPrice,topIsTheir,hasBothInitialOffers,majorTicks,minorTicks,offers:offerPositions,marketValuePosition,initialMarkers}});return(_ctx,_cache)=>priceFinderData.value?(openBlock(),createElementBlock(`div`,{key:0,class:normalizeClass([`price-finder-container`,{selling:__props.amISelling,buying:!__props.amISelling}])},[createBaseVNode(`div`,_hoisted_1$121,[createTextVNode(toDisplayString(priceFinderData.value.topIsTheir?`Your`:`Their`)+` Asking Price: `,1),createVNode(unref(bngUnit_default),{class:`money`,money:priceFinderData.value.rightPrice},null,8,[`money`])]),createBaseVNode(`div`,_hoisted_2$101,[(openBlock(!0),createElementBlock(Fragment,null,renderList(priceFinderData.value.minorTicks,(tick,index)=>(openBlock(),createElementBlock(`div`,{key:`minor-`+index,class:`price-finder-tick minor`,style:normalizeStyle({top:100-tick.position+`%`})},null,4))),128)),(openBlock(!0),createElementBlock(Fragment,null,renderList(priceFinderData.value.majorTicks,(tick,index)=>(openBlock(),createElementBlock(`div`,{key:`major-`+index,class:`price-finder-tick major`,style:normalizeStyle({top:100-tick.position+`%`})},[tick.position>5&&tick.position<95?(openBlock(),createElementBlock(`div`,_hoisted_3$89,toDisplayString(unref(units).beamBucks(tick.price)),1)):createCommentVNode(``,!0)],4))),128)),priceFinderData.value.hasBothInitialOffers?(openBlock(!0),createElementBlock(Fragment,{key:0},renderList(priceFinderData.value.offers,(offer,index)=>(openBlock(),createElementBlock(`div`,{key:index,class:normalizeClass([`price-finder-marker`,{"my-offer":offer.isMyOffer,"their-offer":!offer.isMyOffer,"most-recent":offer.isMostRecent,unsent:offer.isUnsent}]),style:normalizeStyle({top:100-offer.position+`%`})},[..._cache[0]||=[createBaseVNode(`div`,{class:`marker-triangle`},null,-1)]],6))),128)):createCommentVNode(``,!0),priceFinderData.value.marketValuePosition===null?createCommentVNode(``,!0):(openBlock(),createElementBlock(`div`,{key:1,class:`price-finder-marker market-value`,style:normalizeStyle({top:100-priceFinderData.value.marketValuePosition+`%`,bottom:`0`})},[..._cache[1]||=[createBaseVNode(`div`,{class:`marker-dot`},null,-1)]],4)),(openBlock(!0),createElementBlock(Fragment,null,renderList(priceFinderData.value.initialMarkers,(marker$1,index)=>(openBlock(),createElementBlock(`div`,{key:`initial-`+index,class:normalizeClass([`price-finder-marker`,{"my-offer":marker$1.isMyOffer,"their-offer":!marker$1.isMyOffer,initial:!0}]),style:normalizeStyle({top:100-marker$1.position+`%`})},[..._cache[2]||=[createBaseVNode(`div`,{class:`marker-triangle`},null,-1)]],6))),128))]),createBaseVNode(`div`,_hoisted_4$69,[createTextVNode(toDisplayString(priceFinderData.value.topIsTheir?`Their`:`Your`)+` initial offer: `,1),createVNode(unref(bngUnit_default),{class:`money`,money:priceFinderData.value.leftPrice},null,8,[`money`])])],2)):createCommentVNode(``,!0)}},PriceFinder_default=__plugin_vue_export_helper_default(_sfc_main$134,[[`__scopeId`,`data-v-ba044f86`]]),_hoisted_1$120={class:`center-wrap`},_hoisted_2$100={class:`header-row`},_hoisted_3$88={key:0,class:`header-seller-info`},_hoisted_4$68={class:`main-content`},_hoisted_5$58={class:`summary`},_hoisted_6$45={key:0,class:`vehicle-info`},_hoisted_7$38={class:`purchase-row`},_hoisted_8$31={class:`label`},_hoisted_9$28={class:`sub-info`},_hoisted_10$22={class:`price`},_hoisted_11$20={class:`offer-container`},_hoisted_12$15={class:`patience`},_hoisted_13$14={class:`label-row`},_hoisted_14$14={class:`offer-controls`},_hoisted_15$14={key:0,class:`offer-controls-row`},_hoisted_16$14={class:`step-buttons-group`},_hoisted_17$11={class:`resolved-negotiation-message`},_hoisted_18$9={class:`price-column`},_hoisted_19$7={key:0,class:`price`},_hoisted_20$6={key:1,class:`price`},_hoisted_21$6={class:`action-buttons wide`},_sfc_main$133={__name:`VehicleNegotiationMain`,setup(__props){useUINavScope(`vehicleNegotiation`);let{units}=useBridge(),events$3=useEvents(),router$1=useRouter(),state=ref({active:!1,startingPrice:0,patience:0,myOffer:null,theirOffer:0,thinking:!1,status:``,negotiationStatus:``,opponentName:``,vehicleNiceName:``,vehicleThumbnail:``,amISelling:!1}),opponent=computed(()=>state.value.amISelling?`Buyer`:`Seller`),biggerIsBetter=computed(()=>!!state.value.amISelling),increaseOfferDisabled=computed(()=>state.value.amISelling?state.value.myOffer!=null&&offerPreview.value>=state.value.myOffer:offerPreview.value>=state.value.theirOffer),decreaseOfferDisabled=computed(()=>state.value.amISelling?(console.log(`decreaseOfferDisabled`,offerPreview.value,state.value.theirOffer),offerPreview.value<=state.value.theirOffer):state.value.myOffer!=null&&offerPreview.value<=state.value.myOffer),offerPreview=ref(0);computed(()=>{let baseStep=state.value.startingPrice/500;return Math.round(baseStep/5)*5}),computed(()=>{let diff=(offerPreview.value-state.value.startingPrice)/state.value.startingPrice*100;return Math.round(diff)});let diffOfferPreviewToStarting=computed(()=>offerPreview.value-state.value.startingPrice),isDiffOfferPreviewToStartingGood=computed(()=>biggerIsBetter.value?diffOfferPreviewToStarting.value>=0:diffOfferPreviewToStarting.value<=0),diffPercentOfferPreviewToMarket=computed(()=>{if(!state.value.actualVehicleValue||state.value.actualVehicleValue===0)return null;let diff=(offerPreview.value-state.value.actualVehicleValue)/state.value.actualVehicleValue*100;return Math.round(diff)}),isDiffPercentOfferPreviewToMarketGood=computed(()=>diffPercentOfferPreviewToMarket.value===null?null:biggerIsBetter.value?diffPercentOfferPreviewToMarket.value>=0:diffPercentOfferPreviewToMarket.value<=0),diffTheirOfferToStarting=computed(()=>state.value.theirOffer-state.value.startingPrice);computed(()=>biggerIsBetter.value?diffTheirOfferToStarting.value>=0:diffTheirOfferToStarting.value<=0);let nudgeOffer=delta=>{let roundedOfferPreview=Math.max(0,Math.round((offerPreview.value+delta)/50)*50),min$1=0,max$1=1/0;state.value.amISelling?(min$1=state.value.theirOffer,state.value.myOffer!=null&&(max$1=state.value.myOffer)):(max$1=state.value.theirOffer,state.value.myOffer!=null&&(min$1=state.value.myOffer)),offerPreview.value=Math.min(max$1,Math.max(min$1,roundedOfferPreview))},offerDisabled=computed(()=>state.value.negotiationStatus===`thinking`||state.value.negotiationStatus===`typing`||state.value.negotiationStatus===`accepted`||state.value.negotiationStatus===`failed`),patienceClass=computed(()=>{let m=state.value.patience??0;return m>.66?`patience-good`:m>.33?`patience-mid`:`patience-bad`}),noDeal=computed(()=>state.value.negotiationStatus===`failed`&&state.value.amISelling);computed(()=>state.value.negotiationStatus===`failed`),computed(()=>{switch(String(state.value.negotiationStatus||``)){case`counterOffer`:return`Counter offer`;case`counterOfferLastChance`:return`Last chance counter offer`;case`accepted`:return`Accepted`;case`failed`:return`Negotiation failed`;case`refused`:return`Offer refused`;case`initial`:return`Initial offer`;case`thinking`:return`Thinking`;case`typing`:return`Typing...`;default:return``}});let resolvedStatusText=computed(()=>state.value.negotiationStatus===`failed`?state.value.amISelling?`The other party ran out of patience and does not want to buy this vehicle.`:`The other party ran out of patience. You can still buy the vehicle at the starting price: `:state.value.negotiationStatus===`accepted`?`Congratulations! You've successfully negotiatied a deal with `+state.value.opponentName+`.`:``),negotiationChat=ref(null),refresh$1=async()=>{state.value=await Lua_default.career_modules_marketplace.getNegotiationState()||state.value;let base=state.value.myOffer==null?state.value.startingPrice:state.value.myOffer;Number.isNaN(Number(base))||(offerPreview.value=Number(base)),state.value.negotiationStatus===`failed`&&(offerPreview.value=state.value.startingPrice)},submitOffer=async()=>{let price=Number(offerPreview.value);Number.isFinite(price)&&await Lua_default.career_modules_marketplace.makeNegotiationOffer(price)},takeOffer=async()=>{await Lua_default.career_modules_marketplace.takeTheirOffer(),state.value.negotiationStatus=`accepted`,state.value.status=`accepted`,offerPreview.value=state.value.theirOffer,state.value.iAccepted=!0,state.value.offerHistory.push({myOffer:state.value.theirOffer,negotiationStatus:`accepted`})},cancel=async()=>{state.value.negotiationStatus!==`accepted`&&await Lua_default.career_modules_marketplace.cancelNegotiation()},goBack=event=>{router$1.back(),state.value.negotiationStatus===`accepted`&&!state.value.iAccepted&&Lua_default.career_modules_marketplace.takeTheirOffer(),cancel(),event&&event.stopPropagation&&event.stopPropagation()};return events$3.on(`negotiationData`,data=>{refresh$1()}),onMounted(async()=>{await refresh$1(),nextTick(()=>{negotiationChat.value&&(negotiationChat.value.reset(),negotiationChat.value.scrollToBottom())})}),onUnmounted(async()=>{events$3.off(`negotiationData`)}),(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$120,[withDirectives((openBlock(),createBlock(unref(bngCard_default),{"bng-ui-scope":`vehicleNegotiation`,class:`negotiation-screen`},{buttons:withCtx(()=>[createBaseVNode(`div`,_hoisted_21$6,[state.value.negotiationStatus!==`accepted`&&state.value.negotiationStatus!==`failed`?(openBlock(),createBlock(unref(bngButton_default),{key:0,class:`submit-offer`,disabled:state.value.negotiationStatus===`counterOfferLastChance`||offerPreview.value==state.value.theirOffer||offerPreview.value==state.value.myOffer||offerDisabled.value,onClick:_cache[6]||=$event=>submitOffer(),accent:unref(ACCENTS).secondary},{default:withCtx(()=>[..._cache[16]||=[createTextVNode(` Submit This Offer `,-1)]]),_:1},8,[`disabled`,`accent`])):createCommentVNode(``,!0),state.value.negotiationStatus!==`accepted`&&state.value.negotiationStatus!==`failed`?withDirectives((openBlock(),createBlock(unref(bngButton_default),{key:1,class:`submit-offer`,disabled:state.value.negotiationStatus===`counterOfferLastChance`||offerDisabled.value,"show-hold":``},{default:withCtx(()=>[..._cache[17]||=[createTextVNode(` Agree to their Price `,-1)]]),_:1},8,[`disabled`])),[[unref(BngClick_default),{holdCallback:takeOffer,holdDelay:1e3,repeatInterval:0}]]):createCommentVNode(``,!0),state.value.negotiationStatus===`failed`||state.value.negotiationStatus===`accepted`?(openBlock(),createBlock(unref(bngButton_default),{key:2,class:`go-back`,accent:unref(ACCENTS).primary,onClick:goBack},{default:withCtx(()=>[createTextVNode(toDisplayString(state.value.amISelling?`Continue`:`Go to Purchase Screen`),1)]),_:1},8,[`accent`])):createCommentVNode(``,!0)])]),default:withCtx(()=>[createBaseVNode(`div`,_hoisted_2$100,[createVNode(unref(bngCardHeading_default),{type:`ribbon`},{default:withCtx(()=>[createTextVNode(` Negotiation with `+toDisplayString(state.value.opponentName||opponent.value)+` `,1),state.value.opponentQuote?(openBlock(),createElementBlock(`div`,_hoisted_3$88,` "`+toDisplayString(state.value.opponentQuote)+`" `,1)):createCommentVNode(``,!0)]),_:1}),createVNode(unref(bngButton_default),{class:`close-button`,onClick:goBack,accent:unref(ACCENTS).attention,"bng-no-nav":`true`,tabindex:`-1`},{default:withCtx(()=>[createVNode(unref(bngBinding_default),{"ui-event":`menu`,controller:``}),createVNode(unref(bngIcon_default),{type:`xmarkBold`,color:`var(--bng-cool-gray-100)`})]),_:1},8,[`accent`])]),createBaseVNode(`div`,_hoisted_4$68,[createBaseVNode(`div`,_hoisted_5$58,[state.value.vehicleNiceName||state.value.vehicleThumbnail?(openBlock(),createElementBlock(`div`,_hoisted_6$45,[createBaseVNode(`div`,_hoisted_7$38,[createBaseVNode(`div`,_hoisted_8$31,[createBaseVNode(`div`,null,toDisplayString(state.value.vehicleNiceName||`Vehicle`),1),createBaseVNode(`div`,_hoisted_9$28,toDisplayString(unref(units).buildString(`length`,state.value.vehicleMileage,0)),1)]),createBaseVNode(`div`,_hoisted_10$22,[_cache[7]||=createTextVNode(` Est. Market: `,-1),createBaseVNode(`div`,null,[createVNode(unref(bngUnit_default),{class:`money`,money:state.value.actualVehicleValue||0},null,8,[`money`])])])])])):createCommentVNode(``,!0)]),createBaseVNode(`div`,_hoisted_11$20,[createVNode(NegotiationChat_default,{ref_key:`negotiationChat`,ref:negotiationChat,"offer-history":state.value.offerHistory||[],"negotiation-status":state.value.negotiationStatus,"starting-price":state.value.startingPrice||0,"am-i-selling":state.value.amISelling},null,8,[`offer-history`,`negotiation-status`,`starting-price`,`am-i-selling`]),createVNode(PriceFinder_default,{"offer-history":state.value.offerHistory||[],"negotiation-status":state.value.negotiationStatus,"starting-price":state.value.startingPrice||0,"offer-preview":offerPreview.value||0,"actual-vehicle-value":state.value.actualVehicleValue,"am-i-selling":state.value.amISelling},null,8,[`offer-history`,`negotiation-status`,`starting-price`,`offer-preview`,`actual-vehicle-value`,`am-i-selling`])]),createBaseVNode(`div`,_hoisted_12$15,[createBaseVNode(`div`,{class:normalizeClass([`bar`,patienceClass.value])},[_cache[8]||=createBaseVNode(`div`,{class:`separator`,style:{left:`33.0%`}},null,-1),_cache[9]||=createBaseVNode(`div`,{class:`separator`,style:{left:`66.0%`}},null,-1),createBaseVNode(`div`,{class:normalizeClass([`fill`,patienceClass.value]),style:normalizeStyle({width:Math.max(0,Math.min(1,state.value.patience||0))*100+`%`})},null,6)],2),createBaseVNode(`div`,_hoisted_13$14,[createBaseVNode(`span`,null,toDisplayString(opponent.value)+`'s Patience`,1)])]),createBaseVNode(`div`,_hoisted_14$14,[state.value.negotiationStatus!==`failed`&&state.value.negotiationStatus!==`accepted`?(openBlock(),createElementBlock(`div`,_hoisted_15$14,[createBaseVNode(`div`,_hoisted_16$14,[createVNode(unref(bngButton_default),{class:`step step-large`,disabled:offerDisabled.value||decreaseOfferDisabled.value,onClick:_cache[0]||=$event=>nudgeOffer(-5e3)},{default:withCtx(()=>[..._cache[10]||=[createTextVNode(`-5000`,-1)]]),_:1},8,[`disabled`]),createVNode(unref(bngButton_default),{class:`step step-medium`,disabled:offerDisabled.value||decreaseOfferDisabled.value,onClick:_cache[1]||=$event=>nudgeOffer(-500)},{default:withCtx(()=>[..._cache[11]||=[createTextVNode(`-500`,-1)]]),_:1},8,[`disabled`]),createVNode(unref(bngButton_default),{class:`step`,disabled:offerDisabled.value||decreaseOfferDisabled.value,onClick:_cache[2]||=$event=>nudgeOffer(-50)},{default:withCtx(()=>[..._cache[12]||=[createTextVNode(`-50`,-1)]]),_:1},8,[`disabled`]),createVNode(unref(bngButton_default),{class:`step`,disabled:offerDisabled.value||increaseOfferDisabled.value,onClick:_cache[3]||=$event=>nudgeOffer(50)},{default:withCtx(()=>[..._cache[13]||=[createTextVNode(`+50`,-1)]]),_:1},8,[`disabled`]),createVNode(unref(bngButton_default),{class:`step step-medium`,disabled:offerDisabled.value||increaseOfferDisabled.value,onClick:_cache[4]||=$event=>nudgeOffer(500)},{default:withCtx(()=>[..._cache[14]||=[createTextVNode(`+500`,-1)]]),_:1},8,[`disabled`]),createVNode(unref(bngButton_default),{class:`step step-large`,disabled:offerDisabled.value||increaseOfferDisabled.value,onClick:_cache[5]||=$event=>nudgeOffer(5e3)},{default:withCtx(()=>[..._cache[15]||=[createTextVNode(`+5000`,-1)]]),_:1},8,[`disabled`])])])):createCommentVNode(``,!0),state.value.negotiationStatus===`failed`||state.value.negotiationStatus===`accepted`?(openBlock(),createElementBlock(`div`,{key:1,class:normalizeClass([`offer-controls-row`,{accepted:state.value.negotiationStatus===`accepted`,failed:state.value.negotiationStatus===`failed`}])},[createVNode(unref(bngIcon_default),{type:state.value.negotiationStatus===`accepted`?`checkmark`:`abandon`,class:`resolved-negotiation-icon`},null,8,[`type`]),createBaseVNode(`div`,_hoisted_17$11,toDisplayString(resolvedStatusText.value),1)],2)):createCommentVNode(``,!0),createBaseVNode(`div`,_hoisted_18$9,[noDeal.value?(openBlock(),createElementBlock(`div`,_hoisted_19$7,` NO DEAL `)):(openBlock(),createElementBlock(`div`,_hoisted_20$6,toDisplayString(unref(units).beamBucks(offerPreview.value||0)),1)),diffOfferPreviewToStarting.value===null?createCommentVNode(``,!0):(openBlock(),createElementBlock(`div`,{key:2,class:normalizeClass([`diff-percent-offer-preview-to-starting`,{positive:isDiffOfferPreviewToStartingGood.value&&diffOfferPreviewToStarting.value!==0,negative:!isDiffOfferPreviewToStartingGood.value&&diffOfferPreviewToStarting.value!==0,zero:diffOfferPreviewToStarting.value===0,hidden:noDeal.value}])},[diffOfferPreviewToStarting.value===0?createCommentVNode(``,!0):(openBlock(),createBlock(unref(bngUnit_default),{key:0,class:`money`,money:Math.abs(diffOfferPreviewToStarting.value)},null,8,[`money`])),createTextVNode(` `+toDisplayString(diffOfferPreviewToStarting.value<0?`under`:diffOfferPreviewToStarting.value>0?`over`:`Same as`)+` starting price `,1)],2)),diffPercentOfferPreviewToMarket.value===null?createCommentVNode(``,!0):(openBlock(),createElementBlock(`div`,{key:3,class:normalizeClass([`diff-percent-offer-preview-to-market`,{positive:isDiffPercentOfferPreviewToMarketGood.value,negative:!isDiffPercentOfferPreviewToMarketGood.value,hidden:noDeal.value}])},toDisplayString(Math.abs(diffPercentOfferPreviewToMarket.value))+`% `+toDisplayString(diffPercentOfferPreviewToMarket.value<0?`under`:`over`)+` Est. Market value `,3))])])])]),_:1})),[[unref(BngBlur_default),1]])]))}},VehicleNegotiationMain_default=__plugin_vue_export_helper_default(_sfc_main$133,[[`__scopeId`,`data-v-29ff8ba1`]]),routes_default$3=[{path:`/menu.careerPause`,name:`menu.careerPause`,component:Pause_default,props:!0,meta:{clickThrough:!0,infoBar:{withAngular:!0,visible:!0,showSysInfo:!0},uiApps:{shown:!1},topBar:{visible:!0}}},{path:`/career`,children:[{path:`chooseInsurance`,name:`chooseInsurance`,component:ChooseInsuranceMain_default},{path:`pauseBigMiddlePanel`,name:`pauseBigMiddlePanel`,component:PauseBigMiddlePanel_default,props:!0},{path:`logbook/:id(\\*?.*?)?`,name:`logbook`,component:Logbook_default,meta:{uiApps:{shown:!1}},props:!0},{path:`milestones/:id(\\*?.*?)?`,name:`milestones`,component:Milestones_default,props:!0,meta:{uiApps:{shown:!1}}},{path:`computer`,name:`computer`,component:ComputerMain_default,props:!0,meta:{uiApps:{shown:!1}}},{path:`vehicleInventory`,name:`vehicleInventory`,component:VehicleInventoryMain_default},{path:`vehiclePerformance/:inventoryId?`,name:`vehiclePerformance`,component:VehiclePerformanceMain_default,props:!0},{path:`tuning`,name:`tuning`,component:TuningMain_default},{path:`painting`,name:`painting`,component:PaintingMain_default},{path:`repair/:header?`,name:`repair`,component:RepairMain_default,props:!0},{path:`partShopping`,name:`partShopping`,component:PartShoppingMain_default,meta:{uiApps:{shown:!1}}},{path:`partInventory`,name:`partInventory`,component:PartInventoryMain_default},{path:`vehiclePurchase/:vehicleInfo?/:playerMoney?/:inventoryHasFreeSlot?/:lastVehicleInfo?`,name:`vehiclePurchase`,component:VehiclePurchaseMain_default,props:!0,meta:{uiApps:{shown:!1}}},{path:`negotiation`,name:`negotiation`,component:VehicleNegotiationMain_default},{path:`vehicleShopping/:screenTag?/:buyingAvailable?/:marketplaceAvailable?/:selectedSellerId?`,name:`vehicleShopping`,component:VehicleShoppingMain_default,props:!0,meta:{uiApps:{shown:!1}}},{path:`insurances`,name:`insurances`,component:InsurancesMain_default},{path:`playerAbstract`,name:`playerAbstract`,component:DriverAbstract_default},{path:`cargoDeliveryReward`,name:`cargoDeliveryReward`,component:CargoDeliveryReward_default,props:!0},{path:`cargoDropOff/:facilityId?/:parkingSpotPath(\\*?.*?)?`,name:`cargoDropOff`,component:CargoDropOff_default,props:!0},{path:`cargoOverview/:facilityId?/:parkingSpotPath(\\*?.*?)?`,name:`cargoOverview`,component:CargoOverviewMain_default,props:!0,meta:{uiApps:{shown:!1}}},{path:`myCargo`,name:`myCargo`,component:MyCargo_default,props:!0,meta:{uiApps:{shown:!1}}},{path:`progressLanding/:pathId?/:comesFromBigMap?`,name:`progressLanding`,component:ProgressLanding_default,props:route=>({pathId:route.params.pathId,comesFromBigMap:route.params.comesFromBigMap===`true`||route.params.comesFromBigMap===!0}),meta:{uiApps:{shown:!1},infoBar:{visible:!0}}},{path:`domainSelection`,name:`domainSelection`,component:ProgressLanding_default,props:!0,meta:{uiApps:{shown:!1},infoBar:{visible:!0}}},{path:`profiles`,name:`profiles`,component:Profiles_default,meta:{uiApps:{shown:!1},infoBar:{visible:!0,showSysInfo:!0}}}]}],data_default=[{translateId:`ui.credits.programmers`,members:[{first:`Thomas`,last:`Fischer`,aka:`tdev`,title:`CEO`},{first:`Lefteris`,last:`Stamatogiannakis`,aka:`estama`,title:`CTO / Physics / Sound / AI`},{first:`Luis`,last:`Anton Rebollo`,aka:`Souga`,title:`Lead Render Developer`},{first:`Alex`,last:`Spodheim`,aka:`CrankyCleric`,title:`Developer`},{first:`Ananda Neelam`,last:`Thathayya`,aka:`Nadeox1`,title:`Technical Artist`},{first:`Andrew`,last:`Kabakwu`,aka:``,title:`Developer`},{first:`Bruno`,last:`Gonzalez Campo`,aka:`stenyak`,title:`Lead Game Engine Developer`},{first:`Cosmin`,last:`Traian`,aka:``,title:`Developer`},{first:`Emre`,last:`Kut`,aka:``,title:`Developer`},{first:`Felix`,last:`Unger`,aka:``,title:`Developer`},{first:`George`,last:`Troulitakis`,aka:`AtmanB`,title:`Developer`},{first:`Guillem`,last:`Ortega`,aka:``,title:`Developer`},{first:`Logane`,last:`Ramez`,aka:`Gadoy`,title:`Developer`},{first:`Lorenzo`,last:`Bartali`,aka:``,title:`AI Developer`},{first:`Ludger`,last:`Meyer-Wülfing`,aka:`meywue`,title:`Developer`},{first:`Nicusor`,last:`Nedelcu`,aka:``,title:`Tools Developer`},{first:`Panos`,last:`Karabelas`,aka:``,title:`Developer`},{first:`Patrick `,last:`Schrangl`,aka:``,title:`Simulation Software Engineer`},{first:`Petros`,last:`Kondylis`,aka:``,title:`AI Developer`},{first:`Ronny`,last:`Nowak`,aka:``,title:`Developer`},{first:`Thomas`,last:`Portassau`,aka:`thomatoes50`,title:`Developer`},{first:`Thomas`,last:`Wilczynski`,aka:`Gamergull`,title:`Developer`},{first:`Timo`,last:`Stabbert`,aka:``,title:`Gameplay Dev Lead`},{first:`Valery`,last:`Dolotin`,aka:``,title:`AI Developer`},{first:`Daniel`,last:`Wakefield`,aka:``,title:`Developer`}]},{translateId:`ui.credits.vehiclePhysics`,members:[{first:`Fabian`,last:`Enkler`,aka:`Diamondback`,title:`Vehicle Systems Lead`},{first:`Angelo`,last:`Matteo`,aka:`angelo234`,title:`Tools Developer`},{first:`Aubrey`,last:`Percival`,aka:``,title:`Vehicle Physics Engineer`},{first:`Bobby`,last:`Villeneuve`,aka:`Binkey`,title:`Vehicle Physics Engineer`},{first:`Brian`,last:`Rickets`,aka:``,title:`Vehicle Systems Engineer`},{first:`Corey`,last:`Bergerud`,aka:`Goosah`,title:`Vehicle Physics Engineer`},{first:`Davide`,last:`Serpi`,aka:``,title:`Vehicle Dynamics Control Intern`},{first:`Efe Can`,last:`Kiraz`,aka:`RenAzuma66`,title:`Vehicle Physics Engineer`},{first:`Grzegorz`,last:`Węgrzyn`,aka:`AiTorror`,title:`Vehicle Physics Engineer / QA`},{first:`Jack`,last:`Jermany`,aka:``,title:`Vehicle Physics Engineer / QA`},{first:`Oliver`,last:`Čajka`,aka:`MRcrash`,title:`Vehicle Physics Engineer`},{first:`Piotr`,last:`Gajek`,aka:`Agent_Y`,title:`Vehicle Physics Engineer / QA`},{first:`Toma Ioan`,last:` Turcu`,aka:``,title:`Vehicle Physics Engineer`},{first:`Quinn`,last:`Howling`,aka:`SpeedHero`,title:`Vehicle Physics Designer`}]},{translateId:`ui.credits.vehicleArt`,members:[{first:`Gabriel`,last:`Fink`,aka:`gabester`,title:`Vehicle Art Director`},{first:`Jared`,last:`Samuelson`,aka:``,title:`Vehicle Team Lead / Subaru Expert`},{first:`Alexandr`,last:`Shesternin`,aka:``,title:`3D Vehicle Artist`},{first:`Andreas`,last:`Focht`,aka:``,title:`Vehicle Concept Artist`},{first:`Daniel`,last:`Russo`,aka:`A3DR`,title:`3D Vehicle Artist`},{first:`Dennis`,last:`Mateja`,aka:`NinetyNine`,title:`Vehicle Designer`},{first:`Manish`,last:`Rawat`,aka:``,title:`3D Vehicle Artist`}]},{translateId:`ui.credits.environmentArtists`,members:[{first:`Sam`,last:`Hutchinson`,aka:`LJFHutch`,title:`Environment Art Director`},{first:`Luca`,last:`Brighi`,aka:``,title:`Lead 3D Environment Artist`},{first:`Huiqin`,last:`Li`,aka:``,title:`3D Environment Artist`},{first:`Sebastien`,last:`Pelletier`,aka:`DoullPepper`,title:`3D Environment Artist`}]},{translateId:`ui.credits.conceptArtists`,members:[{first:`Mary Jane`,last:`Pajaron`,aka:``,title:`2D Concept Artist`}]},{translateId:`ui.credits.gameDesigners`,members:[{first:`James`,last:`Heslop`,aka:`Krallopian`,title:`Game Design Lead`},{first:`Alex`,last:`Bird`,aka:``,title:`Gameplay Developer`},{first:`Rob`,last:`Herridge`,aka:`HighDef`,title:`Gameplay Developer / QA`}]},{translateId:`ui.credits.ui`,members:[{first:`Pavel`,last:`Tiunov`,aka:`Dizboosta`,title:`UI Lead`},{first:`Destiny`,last:`Abellana`,aka:``,title:`Developer`},{first:`Stani`,last:`Tolmacheva`,aka:`Snowly`,title:`Developer`}]},{translateId:`ui.credits.sound`,members:[{first:`Mark`,last:`Knight`,aka:`TDK`,title:`Audio Designer`},{first:`Sebastian`,last:`Emling`,aka:``,title:`Audio Designer`},{first:`Jethro`,last:`Dunn`,aka:``,title:`Audio Outsourcer`},{first:`Max`,last:`Schumann`,aka:``,title:`Audio Outsourcer`}]},{translateId:`ui.credits.qa`,members:[{first:`Colin`,last:`Wenz`,aka:`synsol`,title:`QA Lead`},{first:`Przemysław`,last:`Wolny`,aka:`Car_Killer`,title:`QA / Mod Support`}]},{translateId:`ui.credits.production`,members:[{first:`Ryan`,last:`Dunne`,aka:``,title:`Producer`}]},{translateId:`ui.credits.sysops`,members:[{first:`Charalampos`,last:`Tsipizidis`,aka:``,title:`System Administrator`},{first:`Dimitrios`,last:`Folias`,aka:``,title:`System Administrator`}]},{translateId:`ui.credits.comms`,members:[{first:`Nataliia`,last:`Dmytriievska`,aka:`Leeloo`,title:`Communications & Marketing Lead`},{first:`Bernice`,last:`Mills`,aka:`Bee`,title:`Community Support & Marketing Specialist`},{first:`Mariia`,last:`Gumarova`,aka:`Fluffy Panda`,title:`Customer Support & Marketing Specialist`},{first:`Slawomir`,last:`Niemczyk`,aka:`Sedricoo`,title:`Community Coordinator`},{first:`Vincent`,last:`Liu`,aka:``,title:`Community & Marketing Specialist (APAC)`}]},{translateId:`ui.credits.research`,members:[{first:`Chrysanthi`,last:`Papamichail`,aka:``,title:`Lead Research Software Engineer`},{first:`Abdulrahman`,last:`Saeed`,aka:``,title:`Research Software Engineer`},{first:`Adam`,last:`Ivora`,aka:``,title:`Research Software Engineer`},{first:`David`,last:`Stark`,aka:``,title:`Research Software Engineer`},{first:`Florian`,last:`Faistauer`,aka:``,title:`Vehicle Simulation Expert`},{first:`Gabriel Puretas`,last:`Moral`,aka:``,title:`UX Intern`},{first:`Sayali`,last:`Rajhans`,aka:``,title:`Research Software Engineer`},{first:`Iskren`,last:`Rusimov`,aka:``,title:`Research Software Engineer Intern`}]},{translateId:`ui.credits.organization`,members:[{first:`Christoforos`,last:`Lambrianidis`,aka:``,title:`CFO`},{first:`Joseph`,last:`Inba Raj`,aka:``,title:`HR & Talent Acquisition Lead`},{first:`Cecilia`,last:`Sari`,aka:``,title:`Recruitment Specialist`},{first:`Dimitra`,last:`Litsardou`,aka:`Thamy`,title:`EU / Co-funding Advisory Specialist`},{first:`Eva`,last:`Pigova`,aka:``,title:`Senior Program Manager`},{first:`Maria`,last:`Kosmachevskaya`,aka:``,title:`Business Development Intern`},{first:`Özge`,last:`Altinkaya Erkok`,aka:``,title:`Communication Consultant`},{first:`Renars`,last:`Skesteris`,aka:``,title:`Business Development Intern`},{first:`Sabrina`,last:`Wee`,aka:``,title:`Business Development Manager`},{first:`Sandra`,last:`Campos`,aka:``,title:`Accounting Assistant`},{first:`Ulrike`,last:`Lentz`,aka:``,title:`Executive Assistant`}]},{translateId:`ui.credits.additionalVehiclePhysics`,members:[{first:`Will`,last:`Leader`,aka:``,title:`Off-road Suspension Development and Vehicle Dynamics`}]},{translateId:`ui.credits.additionalVehicleArt`,members:[{first:`Ashish`,last:`Singh`,aka:``,title:`Freelance 3D Vehicle Artist`},{first:`Juan Manuel`,last:`Orcellet`,aka:``,title:`Freelance 3D Vehicle Artist`},{first:`M. Yusuf`,last:`Bolukbasi`,aka:``,title:`Freelance Vehicle Artist`},{first:`Naman`,last:`Deep`,aka:``,title:`Freelance 3D Vehicle Artist`}]},{translateId:`ui.credits.externalContributors`,members:[{first:`Da`,last:`Li`,aka:``,title:``},{first:`Ruhmit`,last:`Sahu `,aka:``,title:``}]},{translateId:`ui.credits.formerEmployee`,members:[{first:`Aaron`,last:`Sutcliffe`,aka:``,title:`Developer / Vehicle Creation`},{first:`Alex`,last:`Raskin`,aka:``,title:`DevOps Engineer`},{first:`Artem`,last:`Arbatskii`,aka:``,title:`Developer`},{first:`Arturo`,last:`Campos`,aka:``,title:`Developer`},{first:`Ben`,last:`Payne`,aka:``,title:`Developer`},{first:`Boluwatife`,last:`Falaye`,aka:``,title:`Developer`},{first:`Clément`,last:`Roche`,aka:``,title:`Developer`},{first:`Edelmar`,last:`Schneider`,aka:``,title:`Developer`},{first:`Eike`,last:`Externest`,aka:``,title:`Developer`},{first:`Jali`,last:`Hautala`,aka:`Jalkku`,title:`Developer`},{first:`Jeremy`,last:`Lu`,aka:``,title:`Developer`},{first:`John`,last:`Beinecke`,aka:``,title:`Developer`},{first:`Juan`,last:`Mendez`,aka:``,title:`Developer`},{first:`Leander`,last:`Beernaert`,aka:``,title:`Game Engine Developer`},{first:`Marc`,last:`Müller`,aka:``,title:`Developer`},{first:`Mark`,last:`Vince`,aka:``,title:`Developer`},{first:`Matti`,last:`Yrjänheikki`,aka:`Masa`,title:`Developer`},{first:`Max`,last:`Razer`,aka:``,title:`Developer`},{first:`Mayowa David`,last:`Abogunrin`,aka:``,title:`Developer`},{first:`Moncef`,last:`Slimane`,aka:``,title:`Developer`},{first:`Nourelhoda`,last:`Mohamed`,aka:``,title:`Developer`},{first:`Pascale`,last:`Maul`,aka:``,title:`Developer`},{first:`Paul`,last:`De Almeida`,aka:``,title:`AI Developer`},{first:`Paul`,last:`Görs`,aka:``,title:`Developer`},{first:`Peter`,last:`Landwehr`,aka:``,title:`Developer`},{first:`Petteri`,last:`Koivumäki`,aka:``,title:`Developer`},{first:`Vasilis`,last:`Douvaras`,aka:``,title:`Developer`},{first:`Vatroslav `,last:`Bodrozic`,aka:``,title:`Developer`},{first:`Waldemar`,last:`Zeitler`,aka:``,title:`Developer`},{first:`Xiaoyi`,last:`Wang`,aka:``,title:`Developer`},{first:``,last:``,aka:``,title:``},{first:`Adrian`,last:`Baboi`,aka:``,title:`Vehicle Creation`},{first:`Brandon`,last:`Proulx`,aka:`Hondune`,title:`Vehicle Creation`},{first:`Carlos`,last:`Bergillos Varela`,aka:`CarlosAir`,title:`Content Creation`},{first:`David`,last:`Thurlbeck`,aka:``,title:`Vehicle Creation`},{first:`Janne`,last:`Nummela`,aka:``,title:`Vehicle Creation`},{first:`Jukka`,last:`Muikkula`,aka:`Miura`,title:`Vehicle Creation`},{first:`Karol`,last:`Miklas`,aka:``,title:`Freelance 3D Vehicle Artist`},{first:`Mardem`,last:`Pires das Dores`,aka:``,title:`Vehicle Creation`},{first:`Mikko`,last:`Lesonen`,aka:``,title:`Vehicle Creation`},{first:`Renju`,last:`Therakathu`,aka:``,title:`Vehicle Creation`},{first:`Sam`,last:`Millington`,aka:`DrowsySam`,title:`Vehicle Creation / Support`},{first:`Sebastian`,last:`Wessel`,aka:``,title:`Vehicle Creation`},{first:`Virtual Mechanix`,last:``,aka:``,title:`Vehicle Creation - Outsourcing Agency`},{first:`Winston`,last:`Broderick`,aka:``,title:`Vehicle Creation`},{first:`Mitchell`,last:`Sahl`,aka:`B25Mitch`,title:`3D Vehicle / Environment Artist`},{first:``,last:``,aka:``,title:``},{first:`Christin`,last:`Walther`,aka:``,title:`Lead 3D Artist`},{first:`Justin`,last:`Roczniak`,aka:`Donoteat`,title:`Environment Artist`},{first:`Lisa`,last:`Steinberg`,aka:``,title:`2D Artist`},{first:`Moses`,last:`Mulinge`,aka:``,title:`2D Artist`},{first:``,last:``,aka:``,title:``},{first:`Barend`,last:`van der Meulen`,aka:``,title:`Content Creator`},{first:`Matthias`,last:`Niebergall`,aka:``,title:`Game Designer`},{first:`SanityCheckMyGame`,last:``,aka:``,title:`Additional Design`},{first:``,last:``,aka:``,title:``},{first:`Georgios`,last:`Siantikos`,aka:`gntikos`,title:`User Interface`},{first:`Jonathan`,last:`Randy`,aka:``,title:`Lead Developer`},{first:`Mirco`,last:`Weigel`,aka:`theshark`,title:`User Interface`},{first:`Svetlozar`,last:`Valchev`,aka:``,title:`User Interface`},{first:`Theodoros`,last:`Manouilidis`,aka:``,title:`User Interface`},{first:`Yale`,last:`Hartmann`,aka:``,title:`User Interface`},{first:``,last:``,aka:``,title:``},{first:`Arend`,last:`Stührmann`,aka:``,title:`Producer`},{first:`Marie Cécile`,last:`Jacq`,aka:``,title:`Producer`},{first:`Nhung Van`,last:`Ho`,aka:``,title:`Project Management`},{first:``,last:``,aka:``,title:``},{first:`Bhavinkumar Babulal`,last:`Arya`,aka:``,title:`Research Software Engineer`},{first:`Carol`,last:`Halim`,aka:`Carotte`,title:`Research Software Engineer`},{first:`Elmar`,last:`Berghöfer`,aka:``,title:`Research`},{first:`Mattia`,last:`Vicari`,aka:``,title:`Research Software Engineer`},{first:``,last:``,aka:``,title:``},{first:`Camila`,last:`Navia`,aka:``,title:`Operations Assistant`},{first:`Danish`,last:`Abbasi`,aka:``,title:`Business Development Intern`},{first:`Lucien`,last:`Frei`,aka:``,title:`Business Development Intern`},{first:`Weiwei`,last:`Kong`,aka:``,title:`Business Development Intern`},{first:`Özgen`,last:`Saatçilar`,aka:``,title:`Communications Consultant`},{first:`Saskia`,last:`Opitz`,aka:``,title:`Administration`},{first:``,last:``,aka:``,title:``},{first:`Hala`,last:`Mahmoud`,aka:``,title:`Quality Assurance`},{first:`Jan Niklas`,last:`Hasse`,aka:``,title:`Quality Assurance`},{first:`Kamil`,last:`Kozak`,aka:``,title:`Quality Assurance`},{first:`Kemisola`,last:`Adeniyi`,aka:``,title:`Quality Assurance`},{first:`Kaja`,last:`Jambrek`,aka:``,title:`Quality Assurance`},{first:`Rajinder`,last:`Rajinder`,aka:``,title:`Quality Assurance`},{first:`Safdar`,last:`Mahmood`,aka:``,title:`Quality Assurance`},{first:`Uros`,last:`Sakic`,aka:`Uki`,title:`QA / Mod Support / Tools QA`},{first:``,last:``,aka:``,title:``},{first:`Konstantinos`,last:`Stamou`,aka:``,title:`System Administrator`},{first:``,last:``,aka:``,title:``},{first:`Erik`,last:`Heldt`,aka:``,title:`Documentation`},{first:`Maxime`,last:`Desharnais`,aka:``,title:`Documentation`},{first:`Harm`,last:`Schulz`,aka:``,title:`Student Assistant`},{first:`Annisa`,last:`Utami`,aka:``,title:`Student Assistant`},{first:`Brandon`,last:`Lynch`,aka:`Chuck_Norris_`,title:`Community Coordinator`},{first:`Monica`,last:`Huang`,aka:``,title:`Community Coordinator`}]},{translateId:`ui.credits.ourAwesomeCommunity`,members:[{first:`Daniel`,last:`Jones`,aka:`daniel_j`},{first:`Dennis`,last:`Wrekenhorst`,aka:`Dennis-W`},{first:`Dustin`,last:`Kutchara`,aka:`dkutch`},{first:`Kristian`,last:`Fagerland`,aka:``},{first:`Richard`,last:`Sixsmith`,aka:`Metalmuncher`},{first:`Sergy`,last:`Karpowicz`,aka:`0xsergy`},{first:`Sven`,last:`Nabeck`,aka:`sputnik_1`},{first:`Tom`,last:`Verhoeve`,aka:`Mythbuster`},{first:`Yannis`,last:`Vaiopoulos`,aka:`JohnV`},{first:``,last:``,aka:`Fufsgfen`}]},{translateId:`ui.credits.specialThanksTo`,members:[{first:`Luis`,last:`Placid`,aka:``,title:`VFX Developer`},{first:`Pierre-Michel`,last:`Ricordel`,aka:`pricorde`}]},{translateId:`ui.credits.soundtrack`,members:[{first:`Gabriel "gabester" Fink`,last:`Copyright 2014`,aka:`Lonle`},{first:`Mark "TDK" Knight`,last:`Copyright 2018`,aka:`Element No. 10`},{first:`Mark "TDK" Knight`,last:`Copyright 2018`,aka:`Getting Away`},{first:`Mark "TDK" Knight`,last:`Copyright 2018`,aka:`Juno Rocks`},{first:`Mark "TDK" Knight`,last:`Copyright 2018`,aka:`Neon Night Racer`},{first:`Mark "TDK" Knight`,last:`Copyright 2018`,aka:`Night Driver`}]},{translateId:`ui.credits.madePossibleWith`,members:[{first:`FMOD Studio by Firelight Technologies Pty Ltd.`,last:``,aka:``},{first:`LuaJIT`,last:``,aka:``},{first:`lua-intf, LuaBridge`,last:``,aka:``},{first:`Chromium Embedded Framework`,last:``,aka:``},{first:`AngularJS`,last:``,aka:``},{first:`Vue.js`,last:``,aka:``},{first:`Material Design`,last:``,aka:``},{first:`LuaSocket`,last:``,aka:``},{first:`Dear ImGui`,last:``,aka:``},{first:`Blender ®`,last:`www.blender.org`,aka:``}]},{translateId:``,members:[{first:`“DUALSHOCK” and “DualSense” are registered trademarks or trademarks of Sony Interactive Entertainment Inc. Library programs for DUALSHOCK®4 and DualSense™ wireless controllers © 2022 Sony Interactive Entertainment Inc.`,last:``,aka:``}]}],_hoisted_1$119={class:`bng-credits-content`},_hoisted_2$99=[`src`],_hoisted_3$87={class:`category`},_hoisted_4$67={class:`credits-table`},_hoisted_5$57={class:`member-cell member-name`},_hoisted_6$44={key:0,class:`aka`},_hoisted_7$37={key:1},_hoisted_8$30={key:0,class:`member-cell member-dot`},_hoisted_9$27={key:1},_hoisted_10$21={key:2,class:`member-cell member-role`},_hoisted_11$19={key:3},_sfc_main$132={__name:`CreditsScroller`,setup(__props){useUINavScope(`credits`);let imageURL=getAssetURL(`images/logos.svg#bng-drive-white`),wrapper=ref(),running=!0,exit=()=>{running=!1,Lua_default.extensions.unload(`ui_credits`),Lua_default.scenetree[`maincef:setMaxFPSLimit`](30),window.bngVue.gotoAngularState(`menu.mainmenu`)};onMounted(()=>{Lua_default.extensions.load(`ui_credits`),Lua_default.scenetree[`maincef:setMaxFPSLimit`](60),wrapper.value.focus(),scrollContainer(wrapper.value,65,exit)}),onUnmounted(()=>{exit()});function scrollContainer(container,pxPerSecond){let scrollSpeed=pxPerSecond/1e3,currentPos=0,lastTime=0,smoother=0;window.requestAnimationFrame(function step(timestamp){let delta=Math.min(150,Math.max(0,timestamp-lastTime));smoother+=(delta-smoother)*.02;let moveDelta=smoother*scrollSpeed;lastTime=timestamp,currentPos+=moveDelta;let targetPos=container.scrollHeight-container.clientHeight;running&¤tPoswithDirectives((openBlock(),createElementBlock(`div`,{ref_key:`wrapper`,ref:wrapper,class:`bng-credits-wrapper`,tabindex:`0`,onKeypress:exit,"bng-ui-scope":`credits`},[createBaseVNode(`div`,_hoisted_1$119,[createBaseVNode(`img`,{class:`logo`,src:unref(imageURL),alt:``},null,8,_hoisted_2$99),(openBlock(!0),createElementBlock(Fragment,null,renderList(unref(data_default),(category,cIndex)=>(openBlock(),createElementBlock(`div`,{key:cIndex},[createBaseVNode(`div`,_hoisted_3$87,[createBaseVNode(`span`,null,toDisplayString(_ctx.$t(category.translateId)),1)]),createBaseVNode(`div`,_hoisted_4$67,[(openBlock(!0),createElementBlock(Fragment,null,renderList(category.members,(member,mIndex)=>(openBlock(),createElementBlock(`div`,{class:`member-row`,key:mIndex},[createBaseVNode(`span`,_hoisted_5$57,[createTextVNode(toDisplayString(member.first)+` `,1),member.aka?(openBlock(),createElementBlock(`span`,_hoisted_6$44,toDisplayString(`<`+member.aka+`>`),1)):(openBlock(),createElementBlock(`span`,_hoisted_7$37,`\xA0`)),createTextVNode(` `+toDisplayString(member.last),1)]),member.title?(openBlock(),createElementBlock(`span`,_hoisted_8$30,` . `)):(openBlock(),createElementBlock(`span`,_hoisted_9$27,`\xA0`)),member.title?(openBlock(),createElementBlock(`span`,_hoisted_10$21,toDisplayString(_ctx.$t(member.title)),1)):(openBlock(),createElementBlock(`span`,_hoisted_11$19,`\xA0`))]))),128))])]))),128)),_cache[0]||=createBaseVNode(`div`,{style:{"padding-top":`70vh`}},null,-1)])],32)),[[unref(BngOnUiNav_default),exit,`menu,back`]])}},CreditsScroller_default=__plugin_vue_export_helper_default(_sfc_main$132,[[`__scopeId`,`data-v-9c2fdcd3`]]),routes_default$4=[{path:`/credits`,name:`credits`,component:CreditsScroller_default}],_hoisted_1$118={class:`details`,"bng-nav-scroll":``},_hoisted_2$98={key:0,class:`header-content`},_hoisted_3$86={key:1,class:`preview`},_hoisted_4$66={key:2,class:`tags-section`},_hoisted_5$56={class:`tags-container`},_hoisted_6$43=[`onClick`],_hoisted_7$36=[`src`],_hoisted_8$29={key:3,class:`description`},_hoisted_9$26={key:0,class:`specs-grid`},_hoisted_10$20={class:`specs-grid-container`},_hoisted_11$18={class:`spec-content`},_hoisted_12$14={class:`spec-label`},_hoisted_13$13={class:`spec-value`},_hoisted_14$13={key:0,class:`bottom-section`},_hoisted_15$13={class:`buttons-section`},_hoisted_16$13={key:1,class:`button-container`},_sfc_main$131={__name:`GameplayDetails`,props:{activeItem:{type:Object,default:null},activeItemDetails:{type:Object,default:null},executeButton:{type:Function,default:()=>{}},toggleFavourite:{type:Function,default:()=>{}},exploreFolder:{type:Function,default:()=>{}},goToMod:{type:Function,default:()=>{}},showHeaderTitle:{type:Boolean,default:!0},inline:{type:Boolean,default:!1},buttonOverride:{type:Object,default:null}},setup(__props){let props=__props,handleButtonClick=buttonId=>{props.executeButton(buttonId)};return(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,{class:normalizeClass([`gameplay-details`,{inline:__props.inline}])},[withDirectives((openBlock(),createElementBlock(`div`,_hoisted_1$118,[__props.activeItemDetails?.headerTitle?(openBlock(),createElementBlock(`div`,_hoisted_2$98,[__props.showHeaderTitle?(openBlock(),createBlock(unref(bngCardHeading_default),{key:0,type:`none`,class:`header-title`},{default:withCtx(()=>[createTextVNode(toDisplayString(__props.activeItemDetails.headerTitle),1)]),_:1})):createCommentVNode(``,!0),__props.activeItemDetails?.preview?(openBlock(),createElementBlock(`div`,_hoisted_3$86,[createVNode(unref(aspectRatio_default),{class:normalizeClass([`preview-image`,{"has-header-title":__props.showHeaderTitle}]),ratio:`16:8`,"external-image":__props.activeItemDetails.preview},{default:withCtx(()=>[__props.inline?createCommentVNode(``,!0):(openBlock(),createBlock(unref(bngIcon_default),{key:0,class:`favourite-icon`,type:__props.activeItemDetails?.isFavourite?`star`:`starSecondary`,onClick:_cache[0]||=$event=>__props.toggleFavourite(__props.activeItem),color:__props.activeItemDetails?.isFavourite?`var(--bng-ter-yellow-50)`:`var(--bng-cool-gray-100)`},null,8,[`type`,`color`]))]),_:1},8,[`external-image`,`class`])])):createCommentVNode(``,!0),__props.activeItemDetails?.tags?.length>0?(openBlock(),createElementBlock(`div`,_hoisted_4$66,[createBaseVNode(`div`,_hoisted_5$56,[(openBlock(!0),createElementBlock(Fragment,null,renderList(__props.activeItemDetails.tags,tag=>(openBlock(),createElementBlock(`div`,{key:tag.key||tag.label,class:normalizeClass([`tag-item`,{clickable:tag.goToMod}]),onClick:$event=>tag.goToMod?__props.goToMod(tag.goToMod):null},[tag.icon?(openBlock(),createBlock(unref(bngIcon_default),{key:0,type:tag.icon},null,8,[`type`])):createCommentVNode(``,!0),tag.svg?(openBlock(),createElementBlock(`img`,{key:1,class:`svg-icon`,src:tag.svg},null,8,_hoisted_7$36)):createCommentVNode(``,!0),createTextVNode(` `+toDisplayString(tag.label),1)],10,_hoisted_6$43))),128))])])):createCommentVNode(``,!0),__props.activeItemDetails?.description?(openBlock(),createElementBlock(`div`,_hoisted_8$29,toDisplayString(__props.activeItemDetails.description),1)):createCommentVNode(``,!0)])):createCommentVNode(``,!0),__props.activeItemDetails?.buttonInfo?.length>0||__props.activeItemDetails?.bottomTags?.length>0?(openBlock(!0),createElementBlock(Fragment,{key:1},renderList(__props.activeItemDetails?.specifications,(specList,specListIndex)=>(openBlock(),createElementBlock(Fragment,{key:specListIndex},[specList.length>0?(openBlock(),createElementBlock(`div`,_hoisted_9$26,[createBaseVNode(`div`,_hoisted_10$20,[(openBlock(!0),createElementBlock(Fragment,null,renderList(specList,specification=>(openBlock(),createElementBlock(`div`,{key:specification.key,class:`spec-cell`},[specification.icon?(openBlock(),createBlock(unref(bngIcon_default),{key:0,type:specification.icon,class:`spec-icon`},null,8,[`type`])):createCommentVNode(``,!0),createBaseVNode(`div`,_hoisted_11$18,[createBaseVNode(`div`,_hoisted_12$14,toDisplayString(specification.label)+`:`,1),createBaseVNode(`div`,_hoisted_13$13,[createBaseVNode(`span`,null,toDisplayString(specification.value),1)])])]))),128))])])):createCommentVNode(``,!0)],64))),128)):createCommentVNode(``,!0)])),[[unref(BngUiNavScroll_default),void 0,void 0,{force:!0}]]),__props.activeItemDetails?.buttonInfo?.length>0||__props.buttonOverride?(openBlock(),createElementBlock(`div`,_hoisted_14$13,[createBaseVNode(`div`,_hoisted_15$13,[__props.buttonOverride?createCommentVNode(``,!0):(openBlock(!0),createElementBlock(Fragment,{key:0},renderList(__props.activeItemDetails.buttonInfo,button=>(openBlock(),createElementBlock(`div`,{key:button.buttonId,class:`button-container`},[createVNode(unref(bngButton_default),{"bng-scoped-nav-autofocus":button.primary,accent:button.primary?`main`:`secondary`,label:button.label,icon:button.icon,onClick:$event=>handleButtonClick(button.buttonId)},null,8,[`bng-scoped-nav-autofocus`,`accent`,`label`,`icon`,`onClick`])]))),128)),__props.buttonOverride?(openBlock(),createElementBlock(`div`,_hoisted_16$13,[createVNode(unref(bngButton_default),{"bng-scoped-nav-autofocus":!0,accent:`main`,label:__props.buttonOverride.label,icon:__props.buttonOverride.icon,onClick:_cache[1]||=$event=>__props.buttonOverride.click(__props.activeItem)},null,8,[`label`,`icon`])])):createCommentVNode(``,!0)])])):createCommentVNode(``,!0)],2))}},GameplayDetails_default=__plugin_vue_export_helper_default(_sfc_main$131,[[`__scopeId`,`data-v-7baeb809`]]),_hoisted_1$117=[`bng-ui-scope`],_hoisted_2$97={class:`popup-content`},_hoisted_3$85={class:`modal-header`},_hoisted_4$65={class:`vehicle-selector-section`},_hoisted_5$55={class:`vehicle-tile-wrapper`},_hoisted_6$42={class:`modal-content`},_hoisted_7$35={class:`spawnpoint-section`},_hoisted_8$28={class:`spawnpoint-info`},_hoisted_9$25={key:0,class:`spawnpoint-preview`},_hoisted_10$19=[`src`],_hoisted_11$17={class:`spawnpoint-name`},_hoisted_12$13={key:0,class:`config-section`},_hoisted_13$12={class:`group-title`},_hoisted_14$12={key:0},_hoisted_15$12={class:`always-show-section`},_hoisted_16$12={key:0,class:`modal-footer`},_sfc_main$130={__name:`LevelConfigurationModal`,props:{levelData:{type:Object,required:!0}},emits:[`return`],setup(__props,{emit:__emit}){useUINavBlocker().allowNavigationOnly();let{lua,events:events$3}=useBridge(),props=__props,emit$1=__emit,scopeName=usePopupUINavScopeName(`_levelConfigPopup`,props);provide(`gridSelectionState`,ref(null));let spawningOptions=ref([]),config=reactive({}),alwaysShowDialogue=ref(!1),vehicleTile=ref({}),loadSpawningOptions=async()=>{try{let levelName=props.levelData?.levelName,backendName=props.levelData?.backendName,result=await lua.ui_gameplaySelector_tileGenerators_levelTiles.getSpawningOptions(levelName,backendName);if(result){let options=result.options||[];spawningOptions.value=options,alwaysShowDialogue.value=result.alwaysShowDialogue||!1,result.vehicleTile?vehicleTile.value={key:`vehicle-selector`,name:result.vehicleTile.name||`Select Vehicle`,preview:result.vehicleTile.preview||`/ui/modules/vehicleSelector/placeholder.png`,sourceIcons:result.vehicleTile.sourceIcons||[]}:vehicleTile.value={key:`vehicle-selector`,name:`Select Vehicle`,preview:`/ui/modules/vehicleSelector/placeholder.png`,sourceIcons:[]},options.forEach(group=>{group.options&&Array.isArray(group.options)&&group.options.forEach(option=>{option.key&&option.value!==void 0&&(config[option.key]=option.value)})})}}catch(error){console.error(`Failed to load spawning options:`,error)}},handleOptionChange=async(key,newValue)=>{try{await lua.ui_gameplaySelector_tileGenerators_levelTiles.changeSpawningOption(key,newValue),events$3.emit(`gridSelectorRefreshCurrentItemDetails`,`freeroamSelector`)}catch(error){console.error(`Failed to update ${key} option:`,error)}},handleAlwaysShowDialogueChange=async newValue=>{try{let backendName=props.levelData?.backendName;await lua.ui_gameplaySelector_tileGenerators_levelTiles.setAlwaysShowDialogue(backendName,newValue),events$3.emit(`gridSelectorRefreshCurrentItemDetails`,`freeroamSelector`)}catch(error){console.error(`Failed to save default action preference:`,error)}},openVehicleSelector=async()=>{try{await lua.ui_vehicleSelector_general.openVehicleSelectorForFreeroamModal(),emit$1(`return`,!0)}catch(e){console.error(`Failed to open vehicle selector:`,e)}};onMounted(()=>{loadSpawningOptions()});let closeModal=()=>{emit$1(`return`,!1)},handleButtonClick=buttonId=>{closeModal(),events$3.emit(`gridSelectorExecuteButton`,`freeroamSelector`,buttonId)},handleCancelWithBack=()=>{closeModal()};return(_ctx,_cache)=>withDirectives((openBlock(),createElementBlock(`div`,{class:`level-configuration-modal popup`,"bng-ui-scope":unref(scopeName)},[createBaseVNode(`div`,_hoisted_2$97,[createBaseVNode(`div`,_hoisted_3$85,[_cache[1]||=createBaseVNode(`h2`,null,`Freeroam Spawning Options`,-1),createVNode(unref(bngIcon_default),{type:`xmarkBold`,class:`close-button`,onClick:closeModal,color:`var(--bng-cool-gray-100)`})]),createBaseVNode(`div`,_hoisted_4$65,[_cache[2]||=createBaseVNode(`h3`,{class:`group-title`},`Vehicle`,-1),createBaseVNode(`div`,_hoisted_5$55,[createTextVNode(toDisplayString(vehicleTile.value)+` `,1),createVNode(Tile_default,{tile:vehicleTile.value,displaySize:`small`,isConfig:!0,onClick:openVehicleSelector},null,8,[`tile`])])]),createBaseVNode(`div`,_hoisted_6$42,[createBaseVNode(`div`,_hoisted_7$35,[_cache[3]||=createBaseVNode(`h3`,null,`Selected Spawnpoint`,-1),createBaseVNode(`div`,_hoisted_8$28,[__props.levelData?.spawnPoint?.previews?.[0]?(openBlock(),createElementBlock(`div`,_hoisted_9$25,[createBaseVNode(`img`,{src:__props.levelData.spawnPoint.previews[0],alt:`Spawnpoint preview`},null,8,_hoisted_10$19)])):createCommentVNode(``,!0),createBaseVNode(`div`,_hoisted_11$17,toDisplayString(_ctx.$tt(__props.levelData?.spawnPoint?.translationId||`No Name?`)),1)])]),spawningOptions.value.length>0?(openBlock(),createElementBlock(`div`,_hoisted_12$13,[(openBlock(!0),createElementBlock(Fragment,null,renderList(spawningOptions.value,group=>(openBlock(),createElementBlock(`div`,{class:`config-group`,key:group.name},[createBaseVNode(`h3`,_hoisted_13$12,toDisplayString(group.name),1),(openBlock(!0),createElementBlock(Fragment,null,renderList(group.options,option=>(openBlock(),createElementBlock(`div`,{class:`config-item`,key:option.key},[option.label?(openBlock(),createElementBlock(`label`,_hoisted_14$12,[option.icon?(openBlock(),createBlock(unref(bngIcon_default),{key:0,type:option.icon,class:`option-icon`},null,8,[`type`])):createCommentVNode(``,!0),createTextVNode(` `+toDisplayString(option.label)+`: `,1)])):createCommentVNode(``,!0),createVNode(unref(bngSelect_default),{modelValue:config[option.key],"onUpdate:modelValue":[$event=>config[option.key]=$event,newValue=>handleOptionChange(option.key,newValue)],options:option.options,loop:``,config:{value:opt=>opt.value,label:opt=>opt.label}},null,8,[`modelValue`,`onUpdate:modelValue`,`options`,`config`])]))),128))]))),128))])):createCommentVNode(``,!0)]),createBaseVNode(`div`,_hoisted_15$12,[createVNode(unref(bngSwitch_default),{modelValue:alwaysShowDialogue.value,"onUpdate:modelValue":[_cache[0]||=$event=>alwaysShowDialogue.value=$event,handleAlwaysShowDialogueChange],label:`Always show this dialogue`,labelBefore:``},null,8,[`modelValue`])]),spawningOptions.value.length>0||__props.levelData?.buttonInfo&&__props.levelData.buttonInfo.length>0?(openBlock(),createElementBlock(`div`,_hoisted_16$12,[__props.levelData?.buttonInfo&&__props.levelData.buttonInfo.length>0?(openBlock(!0),createElementBlock(Fragment,{key:0},renderList(__props.levelData.buttonInfo,button=>(openBlock(),createBlock(unref(bngButton_default),{key:button.buttonId,label:button.label,icon:button.icon,accent:button.primary?`main`:`secondary`,onClick:$event=>handleButtonClick(button.buttonId)},null,8,[`label`,`icon`,`accent`,`onClick`]))),128)):createCommentVNode(``,!0)])):createCommentVNode(``,!0)])],8,_hoisted_1$117)),[[unref(BngOnUiNav_default),handleCancelWithBack,`back,menu`]])}},LevelConfigurationModal_default=__plugin_vue_export_helper_default(_sfc_main$130,[[`__scopeId`,`data-v-ec35f32c`]]),_sfc_main$129={__name:`FreeroamSelector`,setup(__props){let{events:events$3}=useBridge(),handleOpenLevelConfigPopup=data=>{addPopup(LevelConfigurationModal_default,{levelData:data}).promise};return onMounted(()=>{events$3.on(`openLevelConfigurationPopup`,handleOpenLevelConfigPopup)}),onUnmounted(()=>{events$3.off(`openLevelConfigurationPopup`,handleOpenLevelConfigPopup)}),(_ctx,_cache)=>(openBlock(),createBlock(GridSelector_default,{backendName:`freeroamSelector`,routePath:`/freeroam-selector`,defaultPath:{keys:[`allFreeroam`]},defaultDetailsMode:`detail`,hiddenTabs:[`filter`]},{"item-details":withCtx(({activeItem,activeItemDetails,executeButton,toggleFavourite,exploreFolder,goToMod})=>[createVNode(GameplayDetails_default,{activeItem,activeItemDetails,executeButton,toggleFavourite,exploreFolder,goToMod},null,8,[`activeItem`,`activeItemDetails`,`executeButton`,`toggleFavourite`,`exploreFolder`,`goToMod`])]),_:1}))}},FreeroamSelector_default=_sfc_main$129,_hoisted_1$116={class:`preview`},_hoisted_2$96={key:0,class:`general-tags`},_hoisted_3$84={key:1,class:`icon-text-tag`},_hoisted_4$64={class:`vehicle-text-header`},_hoisted_5$54={key:0,class:`general-specs`},_hoisted_6$41={key:1,class:`divider`},_hoisted_7$34={class:`vehicle-tags`},_hoisted_8$27=[`onClick`],_hoisted_9$24=[`src`],_hoisted_10$18={key:0,class:`source-icon-container`},_hoisted_11$16={key:1,class:`source-icon-container`},_hoisted_12$12={key:2,class:`source-icon-container auxiliary-icon`},_hoisted_13$11={key:2,class:`vehicle-description`},_hoisted_14$11={class:`specs-grid-container`},_hoisted_15$11={key:0,class:`spec-label`},_hoisted_16$11={class:`spec-value`},_hoisted_17$10={key:1,class:`spec-value`},_hoisted_18$8={key:0,class:`bottom-section`},_hoisted_19$6={class:`paint-list expanded`},_sfc_main$128={__name:`VehicleDetails`,props:{activeItem:{type:Object,default:null},activeItemDetails:{type:Object,default:null},executeButton:{type:Function,default:()=>{}},toggleFavourite:{type:Function,default:()=>{}},exploreFolder:{type:Function,default:()=>{}},goToMod:{type:Function,default:()=>{}},showHeaderTitle:{type:Boolean,default:!0},hideDetailsAndButtons:{type:Boolean,default:!1},inline:{type:Boolean,default:!1},buttonOverride:{type:Object,default:null}},emits:[`focus-item`],setup(__props,{emit:__emit}){let{showIfController}=storeToRefs(controls_default()),props=__props,emit$1=__emit,handleButtonClick=buttonId=>{let additionalData={};selectedMultiPaint.value&&(additionalData.paint=selectedMultiPaint.value.paintNames[0],additionalData.paint2=selectedMultiPaint.value.paintNames[1],additionalData.paint3=selectedMultiPaint.value.paintNames[2]),selectedPaint.value&&(additionalData.paint=selectedPaint.value.name),props.executeButton(buttonId,additionalData),emit$1(`button-click`,buttonId)},toggleFavourite=()=>{props.activeItem&&props.toggleFavourite(props.activeItem)},openFolder=path=>{props.exploreFolder(path)},goToMod=modId=>{props.goToMod(modId)},sortedFactoryPaints=computed(()=>{let factoryPaints=props.activeItemDetails?.paints?.factoryPaints;return Array.isArray(factoryPaints)?sortColors(factoryPaints).filter(paint=>paint&&paint.name):[]}),multiPaints=computed(()=>{let res=[],multiPaintSetups=props.activeItemDetails?.paints?.multiPaintSetups,factoryPaints=props.activeItemDetails?.paints?.factoryPaints;if(!Array.isArray(multiPaintSetups)||!Array.isArray(factoryPaints))return res;for(let i=0;iname&&factoryPaints.find(paint=>paint.name===name)||null).filter(paint=>paint!==null);paints.length>0&&res.push({id:paintNames.join(`|`),name:setup$3.name,paintNames,paints,applyAll:()=>applyMultipaint(setup$3)})}return res}),hasPaintData=computed(()=>props.activeItemDetails?.additionalData?.paint&&props.activeItemDetails?.paints?.factoryPaints),paintData=computed(()=>{if(!hasPaintData.value)return null;let additionalData=props.activeItemDetails.additionalData,factoryPaints=props.activeItemDetails.paints.factoryPaints,paintNames=[additionalData.paint,additionalData.paint2,additionalData.paint3].filter(name=>name),paints=paintNames.map(name=>{let paint=factoryPaints.find(p$1=>p$1.name===name);return paint?convertPaintToTileFormat(paint):null}).filter(paint=>paint!==null);return paints.length===0?null:{paint:paintNames[0],paintNames,paints}});function applyMultipaint(setup$3){selectedMultiPaint.value=setup$3,selectedPaint.value=null}let selectedMultiPaint=ref(null),selectedPaint=ref(null);ref(!1);let handleMultiPaintClick=(multiPaint,focus$1=!0)=>{selectedMultiPaint.value=multiPaints.value.find(mp=>mp.name===multiPaint.name),selectedPaint.value=null,focus$1&&emit$1(`focus-item`,`multiPaints`)},handlePaintClick=paint=>{selectedPaint.value=paint,selectedMultiPaint.value=null,emit$1(`focus-item`,`paints`)},convertPaintToTileFormat=paint=>{if(!paint)return null;if(paint.baseColor&&paint.paintString)return paint;try{let paintObj=new Paint;return paintObj.paint=paint,paintObj.paintObject}catch(error){return console.warn(`Failed to convert paint:`,paint,error),null}},selectDefaultMultiPaint=()=>{if(!props.activeItemDetails?.paints)return;let multiPaintSetups=props.activeItemDetails?.paints.multiPaintSetups;if(Array.isArray(multiPaintSetups)&&multiPaintSetups.length>0){let defaultMultiPaintSetup=multiPaintSetups.find(setup$3=>setup$3.isDefault);if(defaultMultiPaintSetup){let multiPaintsObj=multiPaints.value.find(mp=>mp.name===defaultMultiPaintSetup.name);if(multiPaintsObj){handleMultiPaintClick(multiPaintsObj,!1);return}}}};watch(()=>props.activeItemDetails,()=>{selectDefaultMultiPaint()}),onMounted(()=>{selectDefaultMultiPaint()});function average(arr){return arr.reduce((a$1,b)=>a$1+b)/arr.length}function valComparable(col,thres=.05){let bool=!0,av=average(col);for(let i=0;i=col[i];return bool&&=av>.8||av<.2,bool}function colorHigherHelper(itm){if(!itm||!itm.orig||!itm.orig.baseColor||!Array.isArray(itm.orig.baseColor)||itm.orig.baseColor.length<4)return 0;let av=average(itm.orig.baseColor.slice(0,3)),al=itm.orig.baseColor[3]/2,res=Math.abs(av-1)*al;return res===0?(av+al)/2:res+1}function colorHigher(a$1,b){if(!a$1||!b||!a$1.orig||!b.orig||!a$1.orig.baseColor||!b.orig.baseColor)return 0;let aColor=valComparable(a$1.orig.baseColor.slice(0,3)),bColor=valComparable(b.orig.baseColor.slice(0,3));if(aColor&&bColor)return colorHigherHelper(b)-colorHigherHelper(a$1);if(aColor&&!bColor)return 1;if(!aColor&&bColor)return-1;for(let i=0;i<3;i++)if(a$1.val[i]!==b.val[i])return a$1.val[i]-b.val[i];return 0}function colorValue(arr){if(!Array.isArray(arr)||arr.length<4)return[0,0,0,0];let repitions=8,rgb=[];for(let i=0;i<3;i++)rgb[i]=(1-arr[3]/2)*arr[i]+arr[3]/2*arr[i];let lum=Math.sqrt(.241*rgb[0]+.691*rgb[1]+.068*rgb[2]),hsl=Paint.rgbToHsl(rgb),out=[hsl[0],lum,hsl[1]].map(elem=>elem*8);return out[0]%2==1&&(out[1]=8-out[1],out[2]=8-out[2]),out.push(arr[3]),out}function sortColors(list){return Array.isArray(list)?list.filter(elem=>elem&&elem.baseColor&&Array.isArray(elem.baseColor)&&elem.baseColor.length>=4).map(elem=>({val:colorValue(elem.baseColor),orig:elem})).sort(colorHigher).map(elem=>elem.orig):[]}return(_ctx,_cache)=>(openBlock(),createElementBlock(Fragment,null,[withDirectives((openBlock(),createElementBlock(`div`,{class:normalizeClass([`details`,{inline:__props.inline}]),"bng-nav-scroll":``},[createBaseVNode(`div`,_hoisted_1$116,[__props.showHeaderTitle?(openBlock(),createBlock(bngCardHeading_default,{key:0,type:`none`,class:`header-title`},{default:withCtx(()=>[createTextVNode(toDisplayString(__props.activeItemDetails.headerTitle),1)]),_:1})):createCommentVNode(``,!0),createBaseVNode(`div`,{class:normalizeClass([`tags-and-preview`,{"has-header-title":__props.showHeaderTitle}])},[__props.activeItemDetails?.iconTags?.length>0?(openBlock(),createElementBlock(`div`,_hoisted_2$96,[(openBlock(!0),createElementBlock(Fragment,null,renderList(__props.activeItemDetails?.iconTags,icon=>(openBlock(),createBlock(bngTooltip_default,{key:icon.icon,text:icon.label,position:`left`},{default:withCtx(()=>[icon.icon?(openBlock(),createBlock(unref(bngIcon_default),{key:0,type:icon.icon,label:icon.label,onClick:$event=>goToMod(icon.goToMod),class:normalizeClass({"favourite-icon":icon.goToMod})},null,8,[`type`,`label`,`onClick`,`class`])):createCommentVNode(``,!0),icon.iconText?(openBlock(),createElementBlock(`span`,_hoisted_3$84,toDisplayString(icon.iconText),1)):createCommentVNode(``,!0)]),_:2},1032,[`text`]))),128))])):createCommentVNode(``,!0),createVNode(unref(aspectRatio_default),{class:normalizeClass([`preview-image`,{"has-header-title":__props.showHeaderTitle}]),ratio:`16:8`,"external-image":__props.activeItemDetails?.preview},{default:withCtx(()=>[__props.inline?createCommentVNode(``,!0):(openBlock(),createBlock(unref(bngIcon_default),{key:0,class:`favourite-icon`,type:__props.activeItemDetails?.isFavourite?`star`:`starSecondary`,onClick:toggleFavourite,color:__props.activeItemDetails?.isFavourite?`var(--bng-ter-yellow-50)`:`var(--bng-cool-gray-100)`},null,8,[`type`,`color`])),hasPaintData.value?(openBlock(),createBlock(unref(bngPaintTile_default),{key:1,"paint-id":`${__props.activeItem?.id||`vehicle`}:${paintData.value.paint}`,paint:paintData.value.paints,"paint-name":paintData.value.paintNames.join(`, `),width:56,height:24,class:`preview-paint-tile`,"bng-no-nav":`true`,tabindex:`-1`},null,8,[`paint-id`,`paint`,`paint-name`])):createCommentVNode(``,!0)]),_:1},8,[`class`,`external-image`])],2)]),createBaseVNode(`div`,_hoisted_4$64,[__props.activeItemDetails?.generalSpecs?.length>0?(openBlock(),createElementBlock(`div`,_hoisted_5$54,[(openBlock(!0),createElementBlock(Fragment,null,renderList(__props.activeItemDetails?.generalSpecs,spec=>(openBlock(),createElementBlock(`div`,{class:`spec-value`,key:spec.key},[Array.isArray(spec.value)?(openBlock(),createElementBlock(Fragment,{key:0},[createTextVNode(toDisplayString(_ctx.$tt(spec.value[0].text)),1)],64)):(openBlock(),createElementBlock(Fragment,{key:1},[createTextVNode(toDisplayString(spec.value),1)],64))]))),128))])):createCommentVNode(``,!0),__props.activeItemDetails?.generalSpecs.length>0?(openBlock(),createElementBlock(`div`,_hoisted_6$41)):createCommentVNode(``,!0),createBaseVNode(`div`,_hoisted_7$34,[(openBlock(!0),createElementBlock(Fragment,null,renderList(__props.activeItemDetails?.tags,tag=>(openBlock(),createElementBlock(`div`,{key:tag.key,class:normalizeClass([`source-icon-container`,{"auxiliary-icon":tag.auxiliary}]),onClick:$event=>_ctx.tagClicked(tag)},[tag.icon?(openBlock(),createBlock(unref(bngIcon_default),{key:0,type:tag.icon},null,8,[`type`])):createCommentVNode(``,!0),tag.svg?(openBlock(),createElementBlock(`img`,{key:1,class:`svg-icon`,src:tag.svg},null,8,_hoisted_9$24)):createCommentVNode(``,!0),createTextVNode(` `+toDisplayString(tag.label),1)],10,_hoisted_8$27))),128)),__props.activeItemDetails?.sourceIcon?(openBlock(),createElementBlock(`div`,_hoisted_10$18,[createVNode(unref(bngIcon_default),{type:__props.activeItemDetails?.sourceIcon.icon,onClick:_cache[0]||=$event=>goToMod(__props.activeItemDetails?.sourceIcon.goToMod)},null,8,[`type`]),createTextVNode(` `+toDisplayString(__props.activeItemDetails?.sourceIcon.label),1)])):createCommentVNode(``,!0),__props.activeItemDetails?.isFavourite?(openBlock(),createElementBlock(`div`,_hoisted_11$16,[createVNode(unref(bngIcon_default),{type:`star`,onClick:toggleFavourite}),_cache[2]||=createTextVNode(` Favourite`,-1)])):createCommentVNode(``,!0),__props.activeItemDetails?.configDetails.isAuxiliary?(openBlock(),createElementBlock(`div`,_hoisted_12$12,[createVNode(unref(bngIcon_default),{type:`bug`}),_cache[3]||=createTextVNode(` Auxiliary`,-1)])):createCommentVNode(``,!0)]),__props.activeItemDetails?.configDetails?.Description?(openBlock(),createElementBlock(`div`,_hoisted_13$11,toDisplayString(__props.activeItemDetails?.configDetails?.Description),1)):createCommentVNode(``,!0)]),__props.activeItemDetails?.configDetails&&!__props.hideDetailsAndButtons?(openBlock(!0),createElementBlock(Fragment,{key:0},renderList(__props.activeItemDetails?.specificationsList,(value,key)=>(openBlock(),createElementBlock(`div`,{key,class:`specs-grid`},[createBaseVNode(`div`,_hoisted_14$11,[(openBlock(!0),createElementBlock(Fragment,null,renderList(value.specifications,specification=>(openBlock(),createElementBlock(`div`,{key:specification.key,class:normalizeClass([`spec-cell`,{"full-width":!specification.key}])},[specification.key?(openBlock(),createElementBlock(`div`,_hoisted_15$11,toDisplayString(specification.key)+`:`,1)):createCommentVNode(``,!0),createBaseVNode(`div`,_hoisted_16$11,[Array.isArray(specification.value)?(openBlock(!0),createElementBlock(Fragment,{key:0},renderList(specification.value,(item,index)=>(openBlock(),createElementBlock(`div`,{key:index,class:normalizeClass([`spec-value-item`,{italic:item.italic}])},[createBaseVNode(`span`,null,toDisplayString(item.text),1),specification.postIcon?(openBlock(),createBlock(unref(bngIcon_default),{key:0,class:`spec-post-icon`,type:specification.postIcon},null,8,[`type`])):createCommentVNode(``,!0),specification.openFolder?(openBlock(),createBlock(unref(bngIcon_default),{key:1,class:`spec-post-icon`,type:`folder`,onClick:$event=>openFolder(specification.value)},null,8,[`onClick`])):createCommentVNode(``,!0)],2))),128)):(openBlock(),createElementBlock(`div`,_hoisted_17$10,[createBaseVNode(`span`,null,toDisplayString(specification.value),1),specification.postIcon?(openBlock(),createBlock(unref(bngIcon_default),{key:0,class:`spec-post-icon`,type:specification.postIcon},null,8,[`type`])):createCommentVNode(``,!0),specification.openFolder?(openBlock(),createBlock(unref(bngIcon_default),{key:1,class:`spec-post-icon`,type:`folder`,onClick:$event=>openFolder(specification.value)},null,8,[`onClick`])):createCommentVNode(``,!0)]))])],2))),128))])]))),128)):createCommentVNode(``,!0)],2)),[[unref(BngUiNavScroll_default),void 0,void 0,{force:!0}]]),__props.hideDetailsAndButtons?createCommentVNode(``,!0):(openBlock(),createElementBlock(`div`,_hoisted_18$8,[createBaseVNode(`div`,_hoisted_19$6,[(openBlock(!0),createElementBlock(Fragment,null,renderList(multiPaints.value,multiPaint=>(openBlock(),createBlock(unref(bngPaintTile_default),{key:multiPaint.name,"paint-id":`${__props.activeItem?.id||`vehicle`}:${multiPaint.name}`,paint:multiPaint.paints,"paint-name":multiPaint.name,"paint-names":multiPaint.paintNames,width:56,height:24,class:normalizeClass([`multi-paint-item`,{selected:selectedMultiPaint.value?.name===multiPaint.name}]),onClick:$event=>handleMultiPaintClick(multiPaint)},null,8,[`paint-id`,`paint`,`paint-name`,`paint-names`,`class`,`onClick`]))),128)),(openBlock(!0),createElementBlock(Fragment,null,renderList(sortedFactoryPaints.value,paint=>(openBlock(),createElementBlock(Fragment,{key:paint.name},[paint&&paint.class===`factory`&&paint.name?(openBlock(),createBlock(unref(bngPaintTile_default),{key:0,"paint-id":`${__props.activeItem?.id||`vehicle`}:${paint.name}`,paint:convertPaintToTileFormat(paint),"vehicle-name":`factory`,"paint-name":paint.name,width:24,height:24,class:normalizeClass([`paint-item`,{selected:selectedPaint.value===paint}]),onClick:$event=>handlePaintClick(paint)},null,8,[`paint-id`,`paint`,`paint-name`,`class`,`onClick`])):createCommentVNode(``,!0)],64))),128))]),__props.activeItemDetails?.buttonInfo&&!__props.buttonOverride?(openBlock(!0),createElementBlock(Fragment,{key:0},renderList(__props.activeItemDetails?.buttonInfo,button=>(openBlock(),createBlock(unref(bngButton_default),{key:button.buttonId,"bng-scoped-nav-autofocus":button.primary,accent:button.primary?`main`:`secondary`,label:button.label,icon:button.icon,onClick:$event=>handleButtonClick(button.buttonId)},null,8,[`bng-scoped-nav-autofocus`,`accent`,`label`,`icon`,`onClick`]))),128)):createCommentVNode(``,!0),__props.buttonOverride?(openBlock(),createBlock(unref(bngButton_default),{key:1,"bng-scoped-nav-autofocus":!0,accent:`main`,label:__props.buttonOverride.label,icon:__props.buttonOverride.icon,onClick:_cache[1]||=$event=>__props.buttonOverride.click(__props.activeItem,selectedPaint.value,selectedMultiPaint.value)},null,8,[`label`,`icon`])):createCommentVNode(``,!0)]))],64))}},VehicleDetails_default=__plugin_vue_export_helper_default(_sfc_main$128,[[`__scopeId`,`data-v-58d013e3`]]);function useFreeroamConfigurator(){let{events:events$3}=useBridge(),configData=ref(null),button=ref(null),error=ref(null),isInitializing=ref(!1),refreshConfigHandler=()=>{logger_default.debug(`freeroamConfiguratorRefreshConfig`),loadConfiguration()},refreshButtonHandler=()=>{logger_default.debug(`freeroamConfiguratorRefreshButton`),loadButtons()};events$3.on(`freeroamConfiguratorRefreshConfig`,refreshConfigHandler),events$3.on(`freeroamConfiguratorRefreshButton`,refreshButtonHandler);let loadButtons=async()=>{try{let buttonData=await Lua_default.freeroam_freeroamConfigurator.getButtons();button.value=buttonData||null,logger_default.debug(`Loaded button:`,buttonData)}catch(err){logger_default.error(`Failed to load button:`,err),error.value=err}},loadConfiguration=async()=>{try{error.value=null;let data=await Lua_default.freeroam_freeroamConfigurator.getConfiguration();data?.options&&processOptionsTree(data.options),configData.value=data,logger_default.debug(`Loaded configuration:`,data),await loadButtons()}catch(err){logger_default.error(`Failed to load freeroam configuration:`,err),error.value=err}},processOptionsTree=options=>{!options||!Array.isArray(options)||options.forEach(group=>{group.key&&(group.onChange=val=>{group.value=val,handleOptionChange(group.key,val)}),Object.defineProperty(group,`enabled`,{get(){return!this.key||!!this.value},enumerable:!0,configurable:!0}),group.options&&Array.isArray(group.options)&&group.options.forEach(option=>{option.key&&(option.onChange=val=>{option.value=val,handleOptionChange(option.key,val)})})})},onSpawnPointTileClick=async()=>{try{await Lua_default.freeroam_freeroamConfigurator.onSpawnPointTileClick(),logger_default.debug(`Spawn point tile clicked`)}catch(err){logger_default.error(`Failed to handle spawnpoint tile click:`,err),error.value=err}},onVehicleTileClick=async()=>{try{await Lua_default.freeroam_freeroamConfigurator.onVehicleTileClick(),logger_default.debug(`Vehicle tile clicked`)}catch(err){logger_default.error(`Failed to handle vehicle tile click:`,err),error.value=err}},updateOption=async(key,value)=>{try{await Lua_default.freeroam_freeroamConfigurator.updateOption(key,value),logger_default.debug(`Updated option ${key}:`,value)}catch(err){logger_default.error(`Failed to update option ${key}:`,err),error.value=err}},handleOptionChange=async(key,newValue)=>{try{await Lua_default.freeroam_freeroamConfigurator.updateOption(key,newValue),await loadButtons(),logger_default.debug(`Handled option change ${key}:`,newValue)}catch(err){logger_default.error(`Failed to update ${key} option:`,err),error.value=err}},handleButtonClick=async buttonId=>{try{await Lua_default.freeroam_freeroamConfigurator.triggerButton(buttonId),logger_default.debug(`Button clicked:`,buttonId)}catch(err){logger_default.error(`Failed to trigger button:`,err),error.value=err}},selectSpawnPoint=async(levelName,spawnPointObjectName,key)=>{try{if(!levelName)throw logger_default.error(`selectSpawnPoint: levelName is required`),Error(`levelName is required`);return await Lua_default.freeroam_freeroamConfigurator.setSpawnPoint(levelName,spawnPointObjectName,key),configData.value.currentSpawnPoint=await Lua_default.freeroam_freeroamConfigurator.getCurrentSpawnPointTile(),logger_default.debug(`Selected spawn point:`,{levelName,spawnPointObjectName}),!0}catch(err){return logger_default.error(`Failed to select spawn point:`,err),error.value=err,!1}},selectVehicle=async(model,config,additionalData,key)=>{try{if(!model||!config)throw logger_default.error(`selectVehicle: model and config are required`),Error(`model and config are required`);return await Lua_default.freeroam_freeroamConfigurator.setVehicle(model,config,additionalData||{},key),configData.value.currentVehicle=await Lua_default.freeroam_freeroamConfigurator.getCurrentVehicleTile(),logger_default.debug(`Selected vehicle:`,{model,config,additionalData}),!0}catch(err){return logger_default.error(`Failed to select vehicle:`,err),error.value=err,!1}},gotoHeaderItem=item=>{item.gotoPath&&(window.bngVue.gotoGameState(item.gotoPath.path,{params:item.gotoPath.props}),logger_default.debug(`Navigated to path:`,item.gotoPath)),item.gotoAngularState&&(window.bngVue.gotoAngularState(item.gotoAngularState),logger_default.debug(`Navigated to angular state:`,item.gotoAngularState)),item.click&&(item.click(),logger_default.debug(`Navigated to click:`,item.click))},goBack=()=>{logger_default.debug(`goBack called`),gotoHeaderItem({gotoAngularState:`menu.mainmenu`})},hasOptions=computed(()=>configData.value?.options&&configData.value.options.length>0),hasSpawnPoint=computed(()=>!!configData.value?.currentSpawnPoint),hasVehicle=computed(()=>!!configData.value?.currentVehicle),canConfigureOptions=computed(()=>hasSpawnPoint.value&&hasVehicle.value),isGroupEnabled=group=>!group.key||!!group.value,initialize=async()=>{if(isInitializing.value){logger_default.debug(`Already initializing, skipping...`);return}try{isInitializing.value=!0,logger_default.debug(`Initializing FreeroamConfigurator composable...`),await loadConfiguration(),logger_default.debug(`FreeroamConfigurator composable initialized successfully`)}catch(err){logger_default.error(`Failed to initialize FreeroamConfigurator composable:`,err),error.value=err}finally{isInitializing.value=!1}},cleanup=()=>{logger_default.debug(`FreeroamConfigurator composable cleanup`),events$3.off(`freeroamConfiguratorRefreshConfig`,refreshConfigHandler),events$3.off(`freeroamConfiguratorRefreshButton`,refreshButtonHandler)};return onUnmounted(()=>{cleanup()}),{configData,config:configData,button,error,isInitializing,hasOptions,hasSpawnPoint,hasVehicle,canConfigureOptions,initialize,loadConfiguration,loadButtons,onSpawnPointTileClick,onVehicleTileClick,updateOption,handleOptionChange,handleButtonClick,selectSpawnPoint,selectVehicle,gotoHeaderItem,goBack,isGroupEnabled}}var _hoisted_1$115={class:`configurator-content`},_hoisted_2$95={key:0,class:`error-state`},_hoisted_3$83={class:`error-content`},_hoisted_4$63={key:1,class:`configurator-sections`,"bng-nav-item":``},_hoisted_5$53={class:`three-column-layout`},_hoisted_6$40={class:`config-section`,"bng-nav-item":``},_hoisted_7$33={class:`section-header`},_hoisted_8$26={class:`section-title-value`},_hoisted_9$23={class:`section-content`},_hoisted_10$17={key:0,class:`clickable`},_hoisted_11$15={key:1,class:`placeholder-content`},_hoisted_12$11={class:`config-section`,"bng-nav-item":``},_hoisted_13$10={class:`section-header`},_hoisted_14$10={class:`section-title-value`},_hoisted_15$10={class:`section-content`},_hoisted_16$10={key:0,class:`clickable`},_hoisted_17$9={key:1,class:`placeholder-content`},_hoisted_18$7={class:`config-section`,"bng-nav-item":``},_hoisted_19$5={class:`section-header`},_hoisted_20$5={key:0,class:`options-scope`},_hoisted_21$5={key:0,class:`section-header`},_hoisted_22$5=[`bng-scoped-nav-autofocus`],_hoisted_23$4={class:`option-label`},_hoisted_24$3={key:1,class:`placeholder-content`},_hoisted_25$2={class:`action-button-container`},_hoisted_26$1={class:`button-content`},_hoisted_27$1={key:1,class:`placeholder-content row`},_sfc_main$127={__name:`FreeroamConfigurator`,setup(__props){let{lua}=useBridge(),{configData,config,button,error,hasOptions,hasSpawnPoint,hasVehicle,canConfigureOptions,initialize,onSpawnPointTileClick,onVehicleTileClick,handleOptionChange,handleButtonClick,gotoHeaderItem,goBack,isGroupEnabled}=useFreeroamConfigurator();return onBeforeMount(()=>{lua.simTimeAuthority.pushPauseRequest(`freeroamConfigurator`)}),onMounted(()=>{initialize()}),onUnmounted(()=>{lua.simTimeAuthority.popPauseRequest(`freeroamConfigurator`)}),(_ctx,_cache)=>withDirectives((openBlock(),createBlock(unref(layoutSingle_default),{class:`freeroam-configurator`},{default:withCtx(()=>[createBaseVNode(`div`,_hoisted_1$115,[createVNode(unref(bngScreenHeadingV2_default),{class:`configurator-heading`},{preheadings:withCtx(()=>[createVNode(unref(bngBreadcrumbs_default),{"show-back-button":!0,simple:``,"disable-last-item":``,class:`configurator-breadcrumbs`,onBack:unref(goBack),onClick:unref(gotoHeaderItem),items:[{label:`Menu`,gotoAngularState:`menu.mainmenu`},{label:`Freeroam Configurator`}]},null,8,[`onBack`,`onClick`])]),default:withCtx(()=>[_cache[3]||=createTextVNode(` Freeroam `,-1)]),_:1}),unref(error)?(openBlock(),createElementBlock(`div`,_hoisted_2$95,[createVNode(BlurBackground_default),createBaseVNode(`div`,_hoisted_3$83,[createVNode(unref(bngIcon_default),{type:`warning`,class:`error-icon`}),_cache[5]||=createBaseVNode(`p`,null,`Failed to load configuration`,-1),createVNode(unref(bngButton_default),{onClick:unref(initialize),accent:unref(ACCENTS).secondary},{default:withCtx(()=>[..._cache[4]||=[createTextVNode(`Retry`,-1)]]),_:1},8,[`onClick`,`accent`])])])):withDirectives((openBlock(),createElementBlock(`div`,_hoisted_4$63,[createBaseVNode(`div`,_hoisted_5$53,[withDirectives((openBlock(),createElementBlock(`div`,_hoisted_6$40,[createVNode(BlurBackground_default),createBaseVNode(`div`,_hoisted_7$33,[createVNode(unref(bngCardHeading_default),{type:`ribbon`,class:`section-title`},{default:withCtx(()=>[_cache[6]||=createBaseVNode(`span`,{class:`section-title-label`},`Location:`,-1),createBaseVNode(`span`,_hoisted_8$26,toDisplayString(unref(configData)?.currentSpawnPoint?.headerTitle||`Select location...`),1)]),_:1})]),createBaseVNode(`div`,_hoisted_9$23,[createBaseVNode(`div`,{class:`selectable-component`,onClick:_cache[0]||=()=>unref(onSpawnPointTileClick)()},[unref(configData)?.currentSpawnPoint?(openBlock(),createElementBlock(`div`,_hoisted_10$17,[createVNode(GameplayDetails_default,{"active-item":{levelName:unref(configData).currentSpawnPoint.levelName,spawnPointObjectName:unref(configData).currentSpawnPoint.spawnPointObjectName},"active-item-details":unref(configData).currentSpawnPoint,inline:``},null,8,[`active-item`,`active-item-details`])])):(openBlock(),createElementBlock(`div`,_hoisted_11$15,[createVNode(unref(bngIcon_default),{type:`road`,class:`placeholder-icon`}),_cache[7]||=createBaseVNode(`p`,{class:`placeholder-text`},`Click to select location`,-1)]))])])])),[[unref(BngBlur_default)],[unref(BngOnUiNav_default),()=>unref(onSpawnPointTileClick)(),`ok`,{focusRequired:!0}]]),withDirectives((openBlock(),createElementBlock(`div`,_hoisted_12$11,[createVNode(BlurBackground_default),createBaseVNode(`div`,_hoisted_13$10,[createVNode(unref(bngCardHeading_default),{type:`ribbon`,class:`section-title`},{default:withCtx(()=>[_cache[8]||=createBaseVNode(`span`,{class:`section-title-label`},`Vehicle:`,-1),createBaseVNode(`span`,_hoisted_14$10,toDisplayString(unref(configData)?.currentVehicle?.headerTitle||`Select vehicle...`),1)]),_:1})]),createBaseVNode(`div`,_hoisted_15$10,[createBaseVNode(`div`,{class:`selectable-component`,onClick:_cache[1]||=()=>unref(onVehicleTileClick)()},[unref(configData)?.currentVehicle?(openBlock(),createElementBlock(`div`,_hoisted_16$10,[createVNode(VehicleDetails_default,{"active-item":{model:unref(configData).currentVehicle.model,config:unref(configData).currentVehicle.config},"active-item-details":unref(configData).currentVehicle,"hide-details-and-buttons":``,inline:``},null,8,[`active-item`,`active-item-details`])])):(openBlock(),createElementBlock(`div`,_hoisted_17$9,[createVNode(unref(bngIcon_default),{type:`car`,class:`placeholder-icon`}),_cache[9]||=createBaseVNode(`p`,{class:`placeholder-text`},`Click to select vehicle`,-1)]))])])])),[[unref(BngBlur_default)],[unref(BngOnUiNav_default),()=>unref(onVehicleTileClick)(),`ok`,{focusRequired:!0}]]),withDirectives((openBlock(),createElementBlock(`div`,_hoisted_18$7,[createVNode(BlurBackground_default),createBaseVNode(`div`,_hoisted_19$5,[createVNode(unref(bngCardHeading_default),{type:`ribbon`,class:`section-title`},{default:withCtx(()=>[..._cache[10]||=[createTextVNode(`Options`,-1)]]),_:1})]),createBaseVNode(`div`,{class:normalizeClass([`section-content`,{disabled:!unref(canConfigureOptions)}])},[unref(hasOptions)?(openBlock(),createElementBlock(`div`,_hoisted_20$5,[(openBlock(!0),createElementBlock(Fragment,null,renderList(unref(configData).options,group=>(openBlock(),createElementBlock(`div`,{class:`config-group`,key:group.name},[group.name?(openBlock(),createElementBlock(`div`,_hoisted_21$5,[createVNode(unref(bngCardHeading_default),{outline:!unref(isGroupEnabled)(group),type:`ribbon`,class:`section-title`},{default:withCtx(()=>[group.type===`switch`?(openBlock(),createBlock(unref(bngSwitch_default),{key:0,class:`group-switch`,modelValue:unref(config)[group.key],"onUpdate:modelValue":[$event=>unref(config)[group.key]=$event,newValue=>unref(handleOptionChange)(group.key,newValue)],label:group.name,labelBefore:``,inline:``,alwaysTransparent:``},null,8,[`modelValue`,`onUpdate:modelValue`,`label`])):createCommentVNode(``,!0)]),_:2},1032,[`outline`])])):createCommentVNode(``,!0),unref(isGroupEnabled)(group)?(openBlock(!0),createElementBlock(Fragment,{key:1},renderList(group.options,(option,optionIndex)=>(openBlock(),createElementBlock(`div`,{class:`config-item`,key:option.key,"bng-scoped-nav-autofocus":optionIndex===0},[createBaseVNode(`div`,{class:normalizeClass([`option-row`,{disabled:option.disabled}])},[createBaseVNode(`label`,_hoisted_23$4,[option.icon?(openBlock(),createBlock(unref(bngIcon_default),{key:0,type:option.icon,class:`option-icon`},null,8,[`type`])):createCommentVNode(``,!0),createTextVNode(` `+toDisplayString(option.label),1)]),option.type===`select`?(openBlock(),createBlock(unref(bngSmartSelect_default),{key:0,modelValue:unref(config)[option.key],items:option.options||[],threshold:80,"onUpdate:modelValue":newValue=>unref(handleOptionChange)(option.key,newValue)},null,8,[`modelValue`,`items`,`onUpdate:modelValue`])):option.type===`switch`?(openBlock(),createBlock(unref(bngSwitch_default),{key:1,modelValue:unref(config)[option.key],"onUpdate:modelValue":[$event=>unref(config)[option.key]=$event,newValue=>unref(handleOptionChange)(option.key,newValue)],label:option.label,labelBefore:``},null,8,[`modelValue`,`onUpdate:modelValue`,`label`])):option.type===`string`?(openBlock(),createBlock(unref(bngInput_default),{key:2,modelValue:unref(config)[option.key],"onUpdate:modelValue":$event=>unref(config)[option.key]=$event,placeholder:option.placeholder,"char-max":option.maxLength,onValueChanged:newValue=>unref(handleOptionChange)(option.key,newValue)},null,8,[`modelValue`,`onUpdate:modelValue`,`placeholder`,`char-max`,`onValueChanged`])):option.type===`number`?(openBlock(),createBlock(unref(bngInput_default),{key:3,modelValue:unref(config)[option.key],"onUpdate:modelValue":$event=>unref(config)[option.key]=$event,type:`number`,"num-min":option.min,"num-max":option.max,"num-step":option.step,onValueChanged:newValue=>unref(handleOptionChange)(option.key,newValue)},null,8,[`modelValue`,`onUpdate:modelValue`,`num-min`,`num-max`,`num-step`,`onValueChanged`])):createCommentVNode(``,!0)],2)],8,_hoisted_22$5))),128)):createCommentVNode(``,!0)]))),128))])):(openBlock(),createElementBlock(`div`,_hoisted_24$3,[createVNode(unref(bngIcon_default),{type:`adjust`,class:`placeholder-icon`}),_cache[11]||=createBaseVNode(`p`,{class:`placeholder-text`},`No options available`,-1)]))],2)])),[[unref(BngBlur_default)],[unref(BngScopedNav_default),{type:unref(SCOPED_NAV_TYPES).normal}]])]),createBaseVNode(`div`,_hoisted_25$2,[createVNode(BlurBackground_default),unref(button)?withDirectives((openBlock(),createBlock(unref(bngButton_default),{key:0,class:`action-button`,accent:unref(ACCENTS).custom,onClick:_cache[2]||=()=>unref(handleButtonClick)(unref(button).meta.buttonId),"bng-scoped-nav-autofocus":``},{default:withCtx(()=>[createBaseVNode(`div`,_hoisted_26$1,[unref(button).meta.icon?(openBlock(),createBlock(unref(bngIcon_default),{key:0,type:unref(button).meta.icon,class:`button-icon`},null,8,[`type`])):createCommentVNode(``,!0),createTextVNode(` `+toDisplayString(unref(button).meta.label),1)])]),_:1},8,[`accent`])),[[unref(BngBlur_default)]]):(openBlock(),createElementBlock(`div`,_hoisted_27$1,[createVNode(unref(bngIcon_default),{type:`play`,class:`placeholder-icon`}),_cache[12]||=createBaseVNode(`p`,{class:`placeholder-text`},`Select location and vehicle to start`,-1)]))])])),[[unref(BngScopedNav_default),{canDeactivate:()=>!1,activateOnMount:!0}],[unref(BngOnUiNav_default),unref(goBack),`back,menu`]])])]),_:1})),[[unref(BngOnUiNav_default),unref(goBack),`back,menu`]])}},FreeroamConfigurator_default=__plugin_vue_export_helper_default(_sfc_main$127,[[`__scopeId`,`data-v-14f15b24`]]),_hoisted_1$114={class:`options-panel-content`},_hoisted_2$94={class:`header-row`},_hoisted_3$82={key:0,class:`options-scope`},_hoisted_4$62={key:0,class:`section-header`},_hoisted_5$52={class:`option-label`},_hoisted_6$39={key:1,class:`placeholder-content`},_sfc_main$126={__name:`OptionsPanel`,props:{options:{type:Array,default:()=>[]},hasOptions:{type:Boolean,default:!1},canConfigureOptions:{type:Boolean,default:!0}},setup(__props){return(_ctx,_cache)=>withDirectives((openBlock(),createElementBlock(`div`,_hoisted_1$114,[createVNode(BlurBackground_default),createBaseVNode(`div`,_hoisted_2$94,[createVNode(unref(bngScreenHeadingV2_default),{type:`2`,class:`header-title-v2`},{default:withCtx(()=>[..._cache[0]||=[createTextVNode(` Options `,-1)]]),_:1})]),createBaseVNode(`div`,{class:normalizeClass([`section-content`,{disabled:!__props.canConfigureOptions}])},[__props.hasOptions?(openBlock(),createElementBlock(`div`,_hoisted_3$82,[(openBlock(!0),createElementBlock(Fragment,null,renderList(__props.options,group=>(openBlock(),createElementBlock(`div`,{class:`config-group`,key:group.name},[group.name?(openBlock(),createElementBlock(`div`,_hoisted_4$62,[createVNode(unref(bngCardHeading_default),{outline:!group.enabled,type:`ribbon`,class:`section-title`},{default:withCtx(()=>[group.type===`switch`?(openBlock(),createBlock(unref(bngSwitch_default),{key:0,class:`group-switch`,modelValue:group.value,"onUpdate:modelValue":[$event=>group.value=$event,group.onChange],label:group.name,labelBefore:``,inline:``,alwaysTransparent:``},null,8,[`modelValue`,`onUpdate:modelValue`,`label`])):createCommentVNode(``,!0)]),_:2},1032,[`outline`])])):createCommentVNode(``,!0),group.enabled?(openBlock(!0),createElementBlock(Fragment,{key:1},renderList(group.options,(option,optionIndex)=>(openBlock(),createElementBlock(`div`,{class:`config-item`,key:option.key},[createBaseVNode(`div`,{class:normalizeClass([`option-row`,{disabled:option.disabled}])},[createBaseVNode(`label`,_hoisted_5$52,[option.icon?(openBlock(),createBlock(unref(bngIcon_default),{key:0,type:option.icon,class:`option-icon`},null,8,[`type`])):createCommentVNode(``,!0),createTextVNode(` `+toDisplayString(option.label),1)]),option.type===`select`?(openBlock(),createBlock(unref(bngSmartSelect_default),{key:0,modelValue:option.value,"onUpdate:modelValue":[$event=>option.value=$event,option.onChange],items:option.options||[],threshold:80},null,8,[`modelValue`,`onUpdate:modelValue`,`items`])):option.type===`switch`?(openBlock(),createBlock(unref(bngSwitch_default),{key:1,modelValue:option.value,"onUpdate:modelValue":[$event=>option.value=$event,option.onChange],label:option.label,labelBefore:``},null,8,[`modelValue`,`onUpdate:modelValue`,`label`])):option.type===`string`?(openBlock(),createBlock(unref(bngInput_default),{key:2,modelValue:option.value,"onUpdate:modelValue":$event=>option.value=$event,placeholder:option.placeholder,"char-max":option.maxLength,onValueChanged:option.onChange},null,8,[`modelValue`,`onUpdate:modelValue`,`placeholder`,`char-max`,`onValueChanged`])):option.type===`number`?(openBlock(),createBlock(unref(bngInput_default),{key:3,modelValue:option.value,"onUpdate:modelValue":$event=>option.value=$event,type:`number`,"num-min":option.min,"num-max":option.max,"num-step":option.step,onValueChanged:option.onChange},null,8,[`modelValue`,`onUpdate:modelValue`,`num-min`,`num-max`,`num-step`,`onValueChanged`])):createCommentVNode(``,!0)],2)]))),128)):createCommentVNode(``,!0)]))),128))])):(openBlock(),createElementBlock(`div`,_hoisted_6$39,[createVNode(unref(bngIcon_default),{type:`adjust`,class:`placeholder-icon`}),_cache[1]||=createBaseVNode(`p`,{class:`placeholder-text`},`No options available`,-1)]))],2),renderSlot(_ctx.$slots,`buttons`,{},void 0,!0)])),[[unref(BngBlur_default)]])}},OptionsPanel_default=__plugin_vue_export_helper_default(_sfc_main$126,[[`__scopeId`,`data-v-c933da42`]]),_hoisted_1$113={class:`icon-wrapper`},_sfc_main$125={__name:`wizardStepButton`,props:{first:{type:Boolean,default:!1},title:{type:String,required:!0},tooltip:{type:String},active:{type:Boolean,default:!1},completed:{type:Boolean,default:!1},preview:{type:String,default:``},icon:{type:String,default:``},ratio:{type:String,default:`2:1`},showPaintTile:{type:Boolean,default:!1},paintId:{type:String,default:``},paints:{type:Array,default:()=>[]},paintName:{type:String,default:``},paintWidth:{type:Number,default:45},paintHeight:{type:Number,default:20}},emits:[`activate`],setup(__props,{emit:__emit}){let emit$1=__emit;function handleActivate(){emit$1(`activate`)}return(_ctx,_cache)=>withDirectives((openBlock(),createElementBlock(`div`,{class:normalizeClass([`step-tab`,{"first-tab":__props.first,"active-tab":__props.active,"completed-tab":__props.completed,"no-thumbnail":!__props.preview}]),onClick:handleActivate},[createBaseVNode(`div`,_hoisted_1$113,[createVNode(unref(bngIcon_default),{class:`step-icon`,type:__props.icon},null,8,[`type`])]),__props.preview?(openBlock(),createBlock(unref(aspectRatio_default),{key:0,class:`thumbnail-image`,ratio:__props.ratio,"external-image":__props.preview},{default:withCtx(()=>[renderSlot(_ctx.$slots,`overlay`,{},void 0,!0),__props.showPaintTile&&__props.paints&&__props.paints.length>0?(openBlock(),createBlock(unref(bngPaintTile_default),{key:0,"paint-id":__props.paintId,paint:__props.paints,"paint-name":__props.paintName,width:__props.paintWidth,height:__props.paintHeight,onClick:handleActivate,class:`preview-paint-tile`,"bng-no-nav":`true`,tabindex:`-1`},null,8,[`paint-id`,`paint`,`paint-name`,`width`,`height`])):createCommentVNode(``,!0)]),_:3},8,[`ratio`,`external-image`])):createCommentVNode(``,!0)],2)),[[unref(BngOnUiNav_default),handleActivate,`ok`,{focusRequired:!0}],[unref(BngTooltip_default),__props.tooltip,`bottom`]])}},wizardStepButton_default=__plugin_vue_export_helper_default(_sfc_main$125,[[`__scopeId`,`data-v-475a9f52`]]),_hoisted_1$112={class:`configurator-heading`},_hoisted_2$93={class:`configurator-body`},_hoisted_3$81={key:0,class:`grid-section`},_hoisted_4$61={key:1,class:`option-summary-panel`},_hoisted_5$51={class:`section-header`},_hoisted_6$38={class:`section-title-value`},_hoisted_7$32={class:`section-content`},_hoisted_8$25={key:0,class:`clickable`},_hoisted_9$22={key:1,class:`placeholder-content`},_hoisted_10$16={class:`section-header`},_hoisted_11$14={class:`section-title-value`},_hoisted_12$10={class:`section-content`},_hoisted_13$9={key:0,class:`clickable`},_hoisted_14$9={key:1,class:`placeholder-content`},_hoisted_15$9={class:`configurator-heading`},_hoisted_16$9={key:0,class:`error-state`},_hoisted_17$8={class:`error-content`},_hoisted_18$6={key:1,class:`configurator-sections`},_hoisted_19$4={class:`steps-container`},_hoisted_20$4={class:`background-bar`},_hoisted_21$4={class:`label`},_hoisted_22$4={class:`hold-binding`},WIZARD_SCOPE_ID=`freeroam-wizard`,_sfc_main$124={__name:`FreeroamWizard`,props:{step:{type:String,default:``},pathMatch:{type:[String,Array],default:``},itemDetails:{type:[String,Array],default:``}},setup(__props){let{lua,events:events$3}=useBridge(),router$1=useRouter(),scopedNav=useScopedNav(),steps={level:{title:`Location`,backendName:`freeroamSelector`,path:`/freeroam-wizard/level`,defaultPath:{keys:[`allFreeroam`]},defaultDetailsMode:`detail`,hiddenTabs:[`filter`,`advanced`]},vehicle:{title:`Vehicle`,backendName:`vehicleSelector`,path:`/freeroam-wizard/vehicle`,defaultPath:{keys:[`allModels`]},defaultDetailsMode:`detail`,hiddenTabs:[`advanced`]},options:{title:`Options`,path:`/freeroam-wizard/options`}},stepCompleted=computed(()=>({level:props.step===`vehicle`||props.step===`options`,vehicle:props.step===`options`,options:!1})),gridSelectorProps=computed(()=>{let stepConfig=steps[props.step];return stepConfig&&stepConfig.backendName&&stepConfig.path?{backendName:stepConfig.backendName,routePath:stepConfig.path,defaultPath:stepConfig.defaultPath||{keys:[]},defaultDetailsMode:stepConfig.defaultDetailsMode||`detail`,hiddenTabs:stepConfig.hiddenTabs||[]}:null}),props=__props,gridSelectorRef=ref(null),holdBindingRef=ref(null),isLoading=ref(!1),breadcrumbItems=computed(()=>{let items$2=[{label:`Menu`,gotoAngularState:`menu.mainmenu`},{label:`Freeroam Configurator`,dividerType:`arrowSmallRight`}];props.step===`level`?items$2.push({label:`Location`,click:()=>{onSpawnPointTileClick(!0)}}):props.step===`vehicle`?items$2.push({label:`Vehicle`,click:()=>{onVehicleTileClick(!0)}}):props.step===`options`&&items$2.push({label:`Options`,click:onOptionsTileClick});let screenHeaderPath=gridSelectorRef.value?.screenHeaderPath,pathValue=screenHeaderPath?.value||screenHeaderPath;return pathValue&&Array.isArray(pathValue)&&pathValue.length>2&&(pathValue.length>3?(items$2.push({label:pathValue[2].label,click:()=>{gridSelectorRef.value.setCurrentPath({keys:pathValue[2].gotoPath}),onSpawnPointTileClick()}}),items$2.push(pathValue[3])):items$2.push(pathValue[2])),items$2}),{configData,button,error,hasOptions,hasSpawnPoint,hasVehicle,canConfigureOptions,initialize,handleButtonClick,selectSpawnPoint,selectVehicle,gotoHeaderItem,loadConfiguration}=useFreeroamConfigurator();watch(()=>props.step,step=>{step===`options`&&(loadConfiguration(),scopedNav.resumeScope(WIZARD_SCOPE_ID))});let overrideSelectItem=async(step,...args)=>{if(props.step===`level`){let item=args[0];if(!item?.showDetails?.levelName)return logger_default.error(`overrideSelectItem: Invalid item data for level selection`),null;await selectSpawnPoint(item.showDetails.levelName,item.showDetails.spawnPointObjectName,item.key)&&router$1.push(steps.vehicle.path)}else if(props.step===`vehicle`){let item=args[0];if(!item?.showDetails?.model||!item?.showDetails?.config)return logger_default.error(`overrideSelectItem: Invalid item data for vehicle selection`),null;let selectedPaint=args[1],selectedMultiPaint=args[2],additionalData={};selectedMultiPaint?.paintNames?(additionalData.paint=selectedMultiPaint.paintNames[0],additionalData.paint2=selectedMultiPaint.paintNames[1],additionalData.paint3=selectedMultiPaint.paintNames[2]):selectedPaint?.name&&(additionalData.paint=selectedPaint.name),await selectVehicle(item.showDetails.model,item.showDetails.config,additionalData,item.key)&&router$1.push(steps.options.path)}return null},onSelectCallback=async(item,doNavigation)=>{if(doNavigation){if(props.step===`level`){if(!item?.doubleClickDetails?.levelName)return logger_default.error(`overrideSelectItem: Invalid item data for level selection`),null;await selectSpawnPoint(item.doubleClickDetails.levelName,item.doubleClickDetails.spawnPointObjectName,item.key)}else if(props.step===`vehicle`){if(!item?.doubleClickDetails?.model||!item?.doubleClickDetails?.config)return logger_default.error(`overrideSelectItem: Invalid item data for vehicle selection`),null;await selectVehicle(item.doubleClickDetails.model,item.doubleClickDetails.config,{},item.key)}}return null},doubleClickOverride=async item=>{if(!item?.doubleClickDetails){logger_default.error(`doubleClickOverride: Invalid item data`);return}let details=item.doubleClickDetails;details.levelName?await selectSpawnPoint(details.levelName,details.spawnPointObjectName,item.key)&&router$1.push(steps.vehicle.path):details.model&&details.config&&await selectVehicle(details.model,details.config,{},item.key)&&router$1.push(steps.options.path)},goBack=()=>{logger_default.debug(`goBack called`);let gridSelectorPath=gridSelectorRef.value?.screenHeaderPath;props.step===`level`?gridSelectorPath&&gridSelectorPath.length>2?onSpawnPointTileClick():window.bngVue.gotoAngularState(`menu.mainmenu`):props.step===`vehicle`?gridSelectorPath&&gridSelectorPath.length>2?onVehicleTileClick():onSpawnPointTileClick():props.step===`options`&&onVehicleTileClick()},onSpawnPointTileClick=async()=>{router$1.replace(steps.level.path)},onVehicleTileClick=async(clearSearch=!1)=>{clearSearch&&gridSelectorRef.value&&(gridSelectorRef.value.clearSearch(),gridSelectorRef.value.clearFilters()),router$1.replace(steps.vehicle.path)},onOptionsTileClick=async()=>{router$1.replace(steps.options.path)},onStartButtonClick=async buttonId=>{isLoading.value=!0,events$3.emit(`LoadingScreen`,{active:!0}),await startLoading$1(async()=>{await waitForLoadingScreenFadeIn$1(),await handleButtonClick(buttonId)})};function convertPaintToTileFormat(paint){if(!paint)return null;if(paint.baseColor&&paint.paintString)return paint;try{let paintObj=new Paint;return paintObj.paint=paint,paintObj.paintObject}catch(error$1){return console.warn(`Failed to convert paint:`,paint,error$1),null}}let vehiclePaintData=computed(()=>{let vehicle=configData.value?.currentVehicle;if(!vehicle?.additionalData?.paint||!vehicle?.paints?.factoryPaints)return null;let additionalData=vehicle.additionalData,factoryPaints=vehicle.paints.factoryPaints,paintNames=[additionalData.paint,additionalData.paint2,additionalData.paint3].filter(name=>name),paints=paintNames.map(name=>{let paint=factoryPaints.find(p$1=>p$1.name===name);return paint?convertPaintToTileFormat(paint):null}).filter(paint=>paint!==null);return paints.length===0?null:{paint:paintNames[0],paintNames,paints}});return onBeforeMount(()=>{lua.simTimeAuthority.pushPauseRequest(`freeroamConfigurator`)}),onMounted(()=>{initialize()}),onUnmounted(()=>{lua.simTimeAuthority.popPauseRequest(`freeroamConfigurator`)}),(_ctx,_cache)=>(openBlock(),createBlock(unref(layoutSingle_default),{class:`freeroam-configurator`},{default:withCtx(()=>[withDirectives((openBlock(),createElementBlock(`div`,{class:normalizeClass([`configurator-content`,{"options-step":__props.step===`options`}])},[createBaseVNode(`div`,_hoisted_1$112,[withDirectives(createVNode(unref(bngBreadcrumbs_default),{class:`configurator-breadcrumbs`,simple:``,"show-back-button":``,"disable-last-item":``,onBack:goBack,onClick:unref(gotoHeaderItem),limit:`15`,items:breadcrumbItems.value},null,8,[`onClick`,`items`]),[[unref(BngBlur_default)]])]),createBaseVNode(`div`,_hoisted_2$93,[__props.step!==`options`&&gridSelectorProps.value?(openBlock(),createElementBlock(`div`,_hoisted_3$81,[(openBlock(),createBlock(GridSelector_default,{ref_key:`gridSelectorRef`,ref:gridSelectorRef,key:`grid-selector-${__props.step}`,"backend-name":gridSelectorProps.value.backendName,"route-path":gridSelectorProps.value.routePath,"default-path":gridSelectorProps.value.defaultPath,"default-details-mode":gridSelectorProps.value.defaultDetailsMode,"hidden-tabs":gridSelectorProps.value.hiddenTabs,"no-breadcrumbs":``,"select-callback":onSelectCallback,"double-click-override":doubleClickOverride,"override-back-from-grid":goBack,"inline-header-container":``,"bubble-events":[`ok`]},{"item-details":withCtx(({activeItem,activeItemDetails,executeButton,toggleFavourite,exploreFolder,goToMod})=>[__props.step===`level`?(openBlock(),createBlock(GameplayDetails_default,{key:0,activeItem,activeItemDetails,toggleFavourite,exploreFolder,goToMod,buttonOverride:{icon:`fastTravel`,label:`Next Step`,click:(...args)=>overrideSelectItem(`level`,...args)},showHeaderTitle:!0},null,8,[`activeItem`,`activeItemDetails`,`toggleFavourite`,`exploreFolder`,`goToMod`,`buttonOverride`])):createCommentVNode(``,!0),__props.step===`vehicle`?(openBlock(),createBlock(VehicleDetails_default,{key:1,activeItem,activeItemDetails,toggleFavourite,exploreFolder,goToMod,buttonOverride:{icon:`fastTravel`,label:`Next Step`,click:(...args)=>overrideSelectItem(`vehicle`,...args)},showHeaderTitle:!0},null,8,[`activeItem`,`activeItemDetails`,`toggleFavourite`,`exploreFolder`,`goToMod`,`buttonOverride`])):createCommentVNode(``,!0)]),_:1},8,[`backend-name`,`route-path`,`default-path`,`default-details-mode`,`hidden-tabs`]))])):createCommentVNode(``,!0),__props.step===`options`&&unref(configData)?(openBlock(),createElementBlock(`div`,_hoisted_4$61,[withDirectives((openBlock(),createElementBlock(`div`,{class:`config-section selectable-component`,onClick:onSpawnPointTileClick},[createVNode(BlurBackground_default),createBaseVNode(`div`,_hoisted_5$51,[createVNode(unref(bngCardHeading_default),{type:`ribbon`,class:`section-title`},{default:withCtx(()=>[_cache[1]||=createBaseVNode(`span`,{class:`section-title-label`},`Location:`,-1),createBaseVNode(`span`,_hoisted_6$38,toDisplayString(unref(configData)?.currentSpawnPoint?.headerTitle||`Select location...`),1)]),_:1})]),createBaseVNode(`div`,_hoisted_7$32,[createBaseVNode(`div`,null,[unref(configData)?.currentSpawnPoint?(openBlock(),createElementBlock(`div`,_hoisted_8$25,[createVNode(GameplayDetails_default,{"active-item":{levelName:unref(configData).currentSpawnPoint.levelName,spawnPointObjectName:unref(configData).currentSpawnPoint.spawnPointObjectName},"active-item-details":unref(configData).currentSpawnPoint,inline:``,"show-header-title":!1},null,8,[`active-item`,`active-item-details`])])):(openBlock(),createElementBlock(`div`,_hoisted_9$22,[createVNode(unref(bngIcon_default),{type:`road`,class:`placeholder-icon`}),_cache[2]||=createBaseVNode(`p`,{class:`placeholder-text`},`Click to select location`,-1)]))])])])),[[unref(BngBlur_default)]]),withDirectives((openBlock(),createElementBlock(`div`,{class:`config-section selectable-component`,onClick:onVehicleTileClick},[createVNode(BlurBackground_default),createBaseVNode(`div`,_hoisted_10$16,[createVNode(unref(bngCardHeading_default),{type:`ribbon`,class:`section-title`},{default:withCtx(()=>[_cache[3]||=createBaseVNode(`span`,{class:`section-title-label`},`Vehicle:`,-1),createBaseVNode(`span`,_hoisted_11$14,toDisplayString(unref(configData)?.currentVehicle?.headerTitle||`Select vehicle...`),1)]),_:1})]),createBaseVNode(`div`,_hoisted_12$10,[createBaseVNode(`div`,null,[unref(configData)?.currentVehicle?(openBlock(),createElementBlock(`div`,_hoisted_13$9,[createVNode(VehicleDetails_default,{"active-item":{model:unref(configData).currentVehicle.model,config:unref(configData).currentVehicle.config},"active-item-details":unref(configData).currentVehicle,"hide-details-and-buttons":``,inline:``,"show-header-title":!1},null,8,[`active-item`,`active-item-details`])])):(openBlock(),createElementBlock(`div`,_hoisted_14$9,[createVNode(unref(bngIcon_default),{type:`car`,class:`placeholder-icon`}),_cache[4]||=createBaseVNode(`p`,{class:`placeholder-text`},`Click to select vehicle`,-1)]))])])])),[[unref(BngBlur_default)]]),withDirectives(createVNode(OptionsPanel_default,{class:`config-section`,options:unref(configData)?.options||[],"has-options":unref(hasOptions),"can-configure-options":unref(canConfigureOptions)},null,8,[`options`,`has-options`,`can-configure-options`]),[[unref(BngOnUiNav_default),goBack,`back`],[unref(BngOnUiNav_default),goBack,`menu`]])])):createCommentVNode(``,!0)]),createBaseVNode(`div`,_hoisted_15$9,[unref(error)?(openBlock(),createElementBlock(`div`,_hoisted_16$9,[createVNode(BlurBackground_default),createBaseVNode(`div`,_hoisted_17$8,[createVNode(unref(bngIcon_default),{type:`warning`,class:`error-icon`}),_cache[6]||=createBaseVNode(`p`,null,`Failed to load configuration`,-1),createVNode(unref(bngButton_default),{onClick:unref(initialize),accent:unref(ACCENTS).secondary},{default:withCtx(()=>[..._cache[5]||=[createTextVNode(`Retry`,-1)]]),_:1},8,[`onClick`,`accent`])])])):(openBlock(),createElementBlock(`div`,_hoisted_18$6,[withDirectives((openBlock(),createElementBlock(`div`,_hoisted_19$4,[createBaseVNode(`div`,_hoisted_20$4,[createVNode(BlurBackground_default)]),createVNode(wizardStepButton_default,{first:``,active:__props.step===`level`,completed:stepCompleted.value.level,title:`Location`,tooltip:unref(configData)?.currentSpawnPoint?.headerTitle,preview:unref(configData)?.currentSpawnPoint?.preview,icon:`road`,onActivate:onSpawnPointTileClick},null,8,[`active`,`completed`,`tooltip`,`preview`]),createVNode(wizardStepButton_default,{active:__props.step===`vehicle`,completed:stepCompleted.value.vehicle,title:`Vehicle`,tooltip:unref(configData)?.currentVehicle?.headerTitle,preview:unref(configData)?.currentVehicle?.preview,icon:`car`,"show-paint-tile":!!vehiclePaintData.value,"paint-id":`${unref(configData)?.currentVehicle?.key||`vehicle`}:${vehiclePaintData.value?.paint}`,paints:vehiclePaintData.value?.paints||[],"paint-name":vehiclePaintData.value?vehiclePaintData.value.paintNames.join(`, `):``,onActivate:onVehicleTileClick},null,8,[`active`,`completed`,`tooltip`,`preview`,`show-paint-tile`,`paint-id`,`paints`,`paint-name`]),createVNode(wizardStepButton_default,{active:__props.step===`options`,completed:stepCompleted.value.options,title:`Options`,tooltip:`Options`,icon:`adjust`,onActivate:onOptionsTileClick},null,8,[`active`,`completed`])])),[[unref(BngBlur_default)]]),withDirectives((openBlock(),createElementBlock(`div`,{class:`play-button`,onClick:_cache[0]||=$event=>onStartButtonClick(unref(button)?.meta?.buttonId),"bng-nav-item":``,tabindex:`1`},[_cache[8]||=createBaseVNode(`div`,{class:`background`},null,-1),createBaseVNode(`div`,_hoisted_21$4,[withDirectives(createBaseVNode(`div`,_hoisted_22$4,[createVNode(unref(bngBinding_default),{ref_key:`holdBindingRef`,ref:holdBindingRef,class:`binding`,"ui-event":`ok`,controller:``},null,512),_cache[7]||=createBaseVNode(`svg`,{class:`hold-arrow`,xmlns:`http://www.w3.org/2000/svg`,viewBox:`0 0 16 12`,preserveAspectRatio:`xMidYMid`},[createBaseVNode(`path`,{d:`M1,1 L8,2 L16,1 L8,11 z`})],-1)],512),[[vShow,holdBindingRef.value?.displayed]]),createTextVNode(` `+toDisplayString(unref(button)?.meta?.label||`Start`),1)])])),[[unref(BngOnUiNav_default),void 0,`ok`,{asMouse:!0}],[unref(BngSoundClass_default),`bng_click_hover_generic`]])]))])],2)),[[unref(BngScopedNav_default),{scopeId:WIZARD_SCOPE_ID,canDeactivate:()=>!1,activateOnMount:!0,bubbleBlacklistEvents:[`back`,`menu`]}],[unref(BngClick_default),{holdCallback:()=>onStartButtonClick(unref(button)?.meta?.buttonId),holdDelay:2e3,repeatInterval:0},void 0,{controller:!0}],[unref(BngOnUiNav_default),void 0,`ok`,{asMouse:!0}]])]),_:1}))}},FreeroamWizard_default=__plugin_vue_export_helper_default(_sfc_main$124,[[`__scopeId`,`data-v-6c942499`]]),routes_default$5=[{name:`menu.freeroamselector`,path:`/freeroam-selector/:pathMatch(.*)*/:itemDetails(.*)*`,component:FreeroamSelector_default,props:!0,meta:{clickThrough:!0,infoBar:{visible:!0,showSysInfo:!1},uiApps:{shown:!1},topBar:{visible:!0}}},{name:`menu.freeroamconfigurator`,path:`/freeroam-configurator`,component:FreeroamConfigurator_default,meta:{clickThrough:!0,infoBar:{visible:!0,showSysInfo:!1},uiApps:{shown:!1},topBar:{visible:!1}}},{name:`menu.freeroamWizard`,path:`/freeroam-wizard/:step/:pathMatch(.*)*/:itemDetails(.*)*`,component:FreeroamWizard_default,props:!0,meta:{clickThrough:!0,infoBar:{visible:!0,showSysInfo:!1},uiApps:{shown:!1},topBar:{visible:!1}}}],_sfc_main$123={__name:`GameplaySelector`,setup(__props){return(_ctx,_cache)=>(openBlock(),createBlock(GridSelector_default,{backendName:`gameplaySelector`,routePath:`/gameplay-selector`,defaultPath:{keys:[`allGameplay`]},defaultDetailsMode:`detail`,hiddenTabs:[`filter`]},{"item-details":withCtx(({activeItem,activeItemDetails,executeButton,toggleFavourite,exploreFolder,goToMod})=>[createVNode(GameplayDetails_default,{activeItem,activeItemDetails,executeButton,toggleFavourite,exploreFolder,goToMod,showHeaderTitle:!0},null,8,[`activeItem`,`activeItemDetails`,`executeButton`,`toggleFavourite`,`exploreFolder`,`goToMod`])]),_:1}))}},GameplaySelector_default=_sfc_main$123,routes_default$6=[{name:`menu.gameplayselector`,path:`/gameplay-selector/:pathMatch(.*)*`,component:GameplaySelector_default,props:!0,meta:{clickThrough:!0,infoBar:{visible:!0,showSysInfo:!1},uiApps:{shown:!1},topBar:{visible:!0}}}],_hoisted_1$111={key:0,class:`garage-button-content`},_sfc_main$122={__name:`GarageButton`,props:{icon:[Object,String],externalIcon:String,disabled:Boolean,active:Boolean,type:{type:String,validator:val=>[`drawer-toggle`,`drawer-button`,``].includes(val)||val===void 0}},setup(__props){let props=__props,slots=useSlots(),hasContent=computed(()=>slots.default),showContent=computed(()=>hasContent.value&&!(props.type===`drawer-toggle`&&!props.active)),btnRef=ref(null);return onUpdated(()=>ensureFocus(btnRef.value?.getElement?.())),(_ctx,_cache)=>(openBlock(),createBlock(unref(bngButton_default),mergeProps({ref_key:`btnRef`,ref:btnRef,accent:unref(ACCENTS).custom,disabled:__props.disabled,icon:__props.icon,externalIcon:__props.externalIcon,class:[`garage-button`,{[`garage-button-${__props.type}`]:!!__props.type,"garage-button-with-content":hasContent.value,"garage-button-active":__props.active}]},_ctx.$attrs),{default:withCtx(()=>[showContent.value?(openBlock(),createElementBlock(`div`,_hoisted_1$111,[renderSlot(_ctx.$slots,`default`,{},void 0,!0)])):createCommentVNode(``,!0)]),_:3},16,[`accent`,`disabled`,`icon`,`externalIcon`,`class`]))}},GarageButton_default=__plugin_vue_export_helper_default(_sfc_main$122,[[`__scopeId`,`data-v-8b374028`]]),_hoisted_1$110={class:`paint-preview`},_hoisted_2$92=[`onClick`],_hoisted_3$80={key:0,class:`empty-slot-indicator`},refpad=25,_sfc_main$121={__name:`PaintPreview`,props:{paints:Array,paintNames:{type:Array,default:()=>[]}},emits:[`select`],setup(__props,{emit:__emit}){let props=__props,emit$1=__emit,previews=computed(()=>{let res=[];if(!props.paints||!Array.isArray(props.paints))return res;let paints=props.paints,len=paints.length;for(let idx=0;idx1?refpad+(100-refpad*2)/(len-1)*idx:50}%`,"--paint-color":isEmpty?`rgba(128, 128, 128, 0.3)`:`rgb(${paint.rgb255.join(`, `)})`,"--paint-metallic":isEmpty?0:Math.max(0,paint.metallic-paint.roughness/.5),"--paint-roughness":isEmpty?1:paint.roughness,"--paint-clearcoat":isEmpty?0:paint.clearcoat,"--paint-clearcoat-roughness":isEmpty?0:paint.clearcoatRoughness,isEmpty,tooltipText};res.push(vars)}return res});return(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$110,[(openBlock(!0),createElementBlock(Fragment,null,renderList(previews.value,(preview,idx)=>withDirectives((openBlock(),createElementBlock(`div`,{key:idx,class:normalizeClass([`paint-preview-item`,{"empty-slot":preview.isEmpty}]),style:normalizeStyle(preview),onClick:$event=>preview.isEmpty?null:emit$1(`select`,idx)},[_cache[0]||=createStaticVNode(`
    `,5),preview.isEmpty?(openBlock(),createElementBlock(`div`,_hoisted_3$80)):createCommentVNode(``,!0)],14,_hoisted_2$92)),[[unref(BngTooltip_default),preview.tooltipText,`bottom`]])),128))]))}},PaintPreview_default=__plugin_vue_export_helper_default(_sfc_main$121,[[`__scopeId`,`data-v-38e5e63f`]]),_hoisted_1$109={class:`paint-preview-container`},_hoisted_2$91={class:`multi-paint-setups-content`},_hoisted_3$79={key:0},colorDefault=`1 1 1 1 0 1 1 0`,previewAnimTime=400,_sfc_main$120={__name:`Paint`,props:{withBackground:Boolean,tabbed:{type:Boolean,default:!0},legacy:{type:Boolean,default:!0}},setup(__props){useUINavBlocker().blockOnly([`context`]);let paintPreviews=usePaintPreviews(),props=__props,events$3=useEvents(),configId=ref(`none`),vehiclePaintPresets=ref({}),multiPaintSetups=ref({}),tabsState=ref([!0,!1,!1]);function tabExpand(idx){for(let i=0;i{tabsState.value[idx]=!0})}let color=ref([colorDefault,colorDefault,colorDefault]),updateColor=(index,preview=!0)=>nextTick(()=>{Lua_default.core_vehicle_colors.setVehicleColor(index,color.value[index]),paints[index].paint=color.value[index],preview&&updatePaint(index)});function resetScroll(){let elm=document.activeElement.closest(`.bng-accitem-content`);elm&&(elm.scrollTop=0)}let paints=Array.from({length:color.value.length},()=>reactive(new Paint({legacy:props.legacy}))),paintImgs=ref(Array(color.value.length).fill(null)),previewStyles=ref(Array(color.value.length).fill(null).map(()=>({"--paint-url":`none`,"--paint-prev-url":`none`,"--paint-prev-transition":`none`,"--paint-prev-opacity":0}))),previewAnimating=Array(color.value.length).fill(0),updatePaintPreview=async(index,url)=>{if(previewAnimating[index]===1)for(previewAnimating[index]=-1;previewAnimating[index]===-1;)await sleep(50);if(previewAnimating[index]=1,previewStyles.value[index][`--paint-prev-transition`]=`none`,paintImgs.value[index]=url,previewAnimTime===0){if(previewAnimating[index]===-1)return previewAnimating[index]=0;previewStyles.value[index][`--paint-url`]=`url(${url})`,previewAnimating[index]=0;return}let currentUrl=previewStyles.value[index][`--paint-url`];if(currentUrl===`none`||!currentUrl){if(previewAnimating[index]===-1)return previewAnimating[index]=0;previewStyles.value[index][`--paint-url`]=`url(${url})`,previewAnimating[index]=0;return}previewStyles.value[index][`--paint-prev-url`]=currentUrl,previewStyles.value[index][`--paint-url`]=`url(${url})`,previewStyles.value[index][`--paint-prev-opacity`]=1,previewStyles.value[index][`--paint-prev-transition`]=`none`,requestAnimationFrame(()=>{if(previewAnimating[index]===-1)return previewAnimating[index]=0;previewStyles.value[index][`--paint-prev-transition`]=`opacity ${previewAnimTime}ms ease-in-out`,previewStyles.value[index][`--paint-prev-opacity`]=0,setTimeout(()=>{if(previewAnimating[index]===-1)return previewAnimating[index]=0;previewStyles.value[index][`--paint-prev-transition`]=`none`,previewAnimating[index]=0},previewAnimTime)})},updatePaint=debounce(async index=>{let paintData=color.value[index];paintPreviews.getBlobPreview(paintData,{paintId:`${configId.value}:single-${index}`,width:80,height:24}).then(url=>{url&&updatePaintPreview(index,url)}).catch(()=>{})},30),updateAllPaints=async()=>{let urls=await Promise.all(paints.map(async(paint,idx)=>await paintPreviews.getBlobPreview(paint.paint,{paintId:`${configId.value}:single-${idx}`,width:80,height:24})));for(let i=0;i{let res=[];for(let i=0;ivehiclePaintPresets.value[name]);res.push({id:paintNames.join(`|`),name:setup$3.name,paintNames,paints:paints$1,apply:idx=>applyMultipaint(setup$3,idx)})}return res});function applyMultipaint(setup$3,index=-1){console.log(`applyMultipaint`,index);let paintNames=[setup$3.paintName1,setup$3.paintName2,setup$3.paintName3];for(let i=0;i-1&&i!==index)continue;let paintName=paintNames[i];if(paintName&&paintName.trim()!==``&&vehiclePaintPresets.value[paintName]){let paintData=vehiclePaintPresets.value[paintName],paint=new Paint({legacy:props.legacy});paint.paint=paintData,color.value[i]=paint.paintString,updateColor(i,!1)}}nextTick(updateAllPaints)}async function fetchDefinedColors(){for(let i=0;i__props.tabbed?(openBlock(),createElementBlock(`div`,{key:0,class:normalizeClass([`paint-acc-wrapper`,{"with-background":__props.withBackground}])},[createBaseVNode(`div`,_hoisted_1$109,[createVNode(PaintPreview_default,{paints:unref(paints),onSelect:tabExpand},null,8,[`paints`])]),withDirectives((openBlock(),createBlock(unref(accordion_default),{class:`paint-acc-container`,singular:``},{default:withCtx(()=>[createVNode(unref(accordionItem_default),{key:`multi-paint-setups`,class:`paint-acc-content`,navigable:``},{caption:withCtx(()=>[..._cache[0]||=[createTextVNode(` Multi Paint Setups `,-1)]]),default:withCtx(()=>[createBaseVNode(`div`,_hoisted_2$91,[(openBlock(!0),createElementBlock(Fragment,null,renderList(multipaint.value,paint=>(openBlock(),createBlock(unref(bngPaintTile_default),{key:paint.name,class:`multi-paint-setup-item`,"paint-id":`${configId.value}:${paint.id}`,paint:paint.paints,"paint-name":paint.name,"paint-names":paint.paintNames,width:72,height:24,"with-menu":``,onClick:paint.apply,onMenuClick:paint.apply},null,8,[`paint-id`,`paint`,`paint-name`,`paint-names`,`onClick`,`onMenuClick`]))),128))])]),_:1}),(openBlock(!0),createElementBlock(Fragment,null,renderList(color.value.length,idx=>(openBlock(),createBlock(unref(accordionItem_default),{key:idx,class:`paint-acc-content`,navigable:``,expanded:tabsState.value[idx-1],style:normalizeStyle(previewStyles.value[idx-1])},{caption:withCtx(()=>[createTextVNode(toDisplayString(_ctx.$t(`ui.trackBuilder.matEditor.paint`)+` `+idx),1)]),default:withCtx(()=>[withDirectives((openBlock(),createElementBlock(`div`,{class:`paint-picker-wrapper`,onDeactivate:resetScroll},[createVNode(PaintPicker_default,{class:`paint-picker`,"picker-mode":`compact_luminosity`,modelValue:color.value[idx-1],"onUpdate:modelValue":$event=>color.value[idx-1]=$event,onChange:$event=>updateColor(idx-1),"show-preview":!1,"presets-editable":``,presets:vehiclePaintPresets.value,legacy:__props.legacy},null,8,[`modelValue`,`onUpdate:modelValue`,`onChange`,`presets`,`legacy`])],32)),[[unref(BngScopedNav_default),{bubbleWhitelistEvents:[`menu`]}]])]),_:2},1032,[`expanded`,`style`]))),128))]),_:1})),[[unref(BngBlur_default),__props.withBackground]])],2)):withDirectives((openBlock(),createElementBlock(`div`,{key:1,class:normalizeClass([`paint-container`,{"with-background":__props.withBackground}])},[(openBlock(!0),createElementBlock(Fragment,null,renderList(color.value.length,idx=>(openBlock(),createBlock(PaintPicker_default,{key:idx,modelValue:color.value[idx-1],"onUpdate:modelValue":$event=>color.value[idx-1]=$event,onChange:$event=>updateColor(idx-1),"show-preview":!1,"presets-editable":``,presets:vehiclePaintPresets.value,legacy:__props.legacy},{default:withCtx(()=>[createTextVNode(toDisplayString(_ctx.$t(`ui.trackBuilder.matEditor.paint`))+` `+toDisplayString(idx),1)]),_:2},1032,[`modelValue`,`onUpdate:modelValue`,`onChange`,`presets`,`legacy`]))),128)),color.value.length%2==1?(openBlock(),createElementBlock(`div`,_hoisted_3$79)):createCommentVNode(``,!0)],2)),[[unref(BngBlur_default),__props.withBackground]])}},Paint_default=__plugin_vue_export_helper_default(_sfc_main$120,[[`__scopeId`,`data-v-956741b3`]]),rgxWheel=/^(\d+(?:\.\d+)?)(x)(\d+(?:\.\d+)?)/i,rgxTire=/^(\d+(?:\.\d+)?)(\/)(\d+(?:\.\d+)?)(R)(\d+(?:\.\d+)?)/i,rgxNum=/(^| )(\d+)($| )/,zeroPad=num=>String(~~(num*1e3)).padStart(10,`0`);function partOptionSorter(...ab){let cmp=[``,``];for(let i=0;i<2;i++){let label=ab[i].label;if(typeof label!=`string`)return 0;rgxWheel.test(label)?cmp[i]=label.replace(rgxWheel,(_,a$1,s,b)=>[a$1,b].map(zeroPad).join(`x`)):rgxTire.test(label)?cmp[i]=label.replace(rgxTire,(_,a$1,s1,b,s2,c)=>[a$1,b,c].map(zeroPad).join(`x`)):rgxNum.test(label)?cmp[i]=label.replace(rgxNum,(_,a$1,num,b)=>a$1+zeroPad(num)+b):cmp[i]=label,label.startsWith(`40x4`)&&console.log(cmp[i])}return cmp[0].localeCompare(cmp[1])}function partOptionGrouper(list){let seq=[],groups={},grouping=!1;for(let itm of list){let group,match=itm.label.match(rgxWheel)||itm.label.match(rgxTire);group=match&&match.length>0?match.slice(1).map(s=>s===`R`?s:s+` `).join(``).trim():itm.label,groups[group]?grouping=!0:(groups[group]=[],seq.push(group)),groups[group].push(itm)}if(!grouping)return list;let res=[];for(let group of seq){let list$1=groups[group];list$1.length===1?res.push(...list$1):(res.push({label:group,group:!0}),res.push(...list$1.map(itm=>({...itm,grouped:!0}))))}return res}var _hoisted_1$108={key:1},_sfc_main$119={__name:`PartsBranch`,props:{rootSlot:Boolean,children:Object,child:Object,info:Object,treeState:Object,treeStateKey:String,flatEntry:Boolean,displayNames:Boolean,showAuxiliary:Boolean,separateSort:Boolean,alwaysSort:Boolean,showEmpty:Boolean,highlighter:[String,Array,RegExp]},emits:[`select`,`deselect`,`highlight`,`change`,`dropdown`],setup(__props,{emit:__emit}){let props=__props,accordionItem=ref(),partsDropdown=ref(),openPartsDropdown=()=>partsDropdown.value&&partsDropdown.value.open(),emit$1=__emit,select=(slot,mouse=!1)=>(!props.child||highlightable.value)&&emit$1(`select`,slot,mouse),deselect=(slot,mouse=!1)=>emit$1(`deselect`,slot,mouse),highlight=slot=>emit$1(`highlight`,slot),change=slot=>emit$1(`change`,slot),dropdown=val=>emit$1(`dropdown`,val),focusReturn=()=>nextTick(()=>accordionItem.value.focus()),accItemUnwatch=watch(accordionItem,()=>{let elm=accordionItem.value?.captionElement;elm&&(accItemUnwatch(),elm.partSelect=()=>props.child&&select(props.child))});function toggleHighlight(slot){slot.highlight=!slot.highlight,highlight(slot)}let toggleHighlightCurrent=()=>toggleHighlight(props.child),highlightable=computed(()=>typeof props.child?.highlight==`boolean`),expanded=ref(!1);if(!props.flatEntry){let unwatchTreeState;unwatchTreeState=watch(()=>props.treeState,()=>setTimeout(()=>{unwatchTreeState(),expanded.value=props.treeStateKey&&props.treeState[props.treeStateKey]&&props.treeState[props.treeStateKey]||!1,watch(()=>expanded.value,val=>{props.treeStateKey&&(val?props.treeState[props.treeStateKey]=val:props.treeStateKey in props.treeState&&delete props.treeState[props.treeStateKey])})},50),{immediate:!0})}let childrenSorter=(a$1,b)=>{if(props.separateSort){if(a$1.children&&!b.children)return 1;if(b.children&&!a$1.children)return-1}if(props.displayNames||!props.alwaysSort)return a$1.slotName.localeCompare(b.slotName);{let info=props.info[a$1.parentSlotName]?.slotInfoUi||{};return getSlotName(a$1,info).localeCompare(getSlotName(b,info))}},slotInfo=computed(()=>props.displayNames?{}:props.info[props.child?.parentSlotName]?.slotInfoUi||{}),isCoreSlot=computed(()=>!!props.info[props.child?.parentSlotName]?.slotInfoUi?.[props.child?.slotName]?.coreSlot),getSlotName=(slot,info={})=>props.displayNames?slot.slotName:info[slot.slotName]?.description||slot.slotName,displayName=computed(()=>getSlotName(props.child,slotInfo.value)),hasPartList=computed(()=>{let list=props.child?.suitablePartNames||[];return list.length===0&&(list=props.child?.chosenPartName?[props.child.chosenPartName]:(props.child?.unsuitablePartNames||[]).map(({partName})=>partName)),props.showAuxiliary||(list=list.filter(partName=>!props.info[partName]?.isAuxiliary)),list.length>0}),partsList=computed(()=>{if(!hasPartList.value)return[];let addEmpty=!0,list=props.child?.suitablePartNames||[];list.length===0&&props.child?.chosenPartName&&(list=[props.child.chosenPartName],addEmpty=!1);let unsuitable=(props.child?.unsuitablePartNames||[]).reduce((res,{partName,reason})=>({...res,[partName]:reason}),{});return list.push(...Object.keys(unsuitable)),list.length===0||(list=list.map(partName=>({value:partName,label:(props.info[partName]?.isAuxiliary?`[!] `:``)+(props.displayNames?partName:props.info[partName]?.description||partName),disabled:partName in unsuitable,tooltip:partName in unsuitable?{text:unsuitable[partName],position:`right`}:void 0,isAuxiliary:props.info[partName]?.isAuxiliary})).filter(opt=>!opt.isAuxiliary||props.showAuxiliary||props.child?.chosenPartName===opt.value),!props.showAuxiliary&&list.length===1&&list[0].isAuxiliary&&isCoreSlot.value)?[]:(list.sort(partOptionSorter),list=partOptionGrouper(list),addEmpty&&!isCoreSlot.value&&list.unshift({value:``,label:`Empty`}),list)}),parentAllChildren=computed(()=>props.children?Object.values(props.children||{}):[]),parentHasChildren=computed(()=>parentAllChildren.value.length>0),parentChildren=computed(()=>[...parentAllChildren.value].sort(childrenSorter)),childAllChildren=computed(()=>props.child?.children?Object.values(props.child.children||{}):[]),childHasChildren=computed(()=>childAllChildren.value.length>0),childChildren=computed(()=>[...childAllChildren.value].sort(childrenSorter)),shouldShow=computed(()=>childHasChildren.value||hasPartList.value||props.showEmpty);return(_ctx,_cache)=>__props.treeState&&parentHasChildren.value?(openBlock(),createBlock(unref(accordion_default),{key:0,class:`branch-category`},{default:withCtx(()=>[(openBlock(!0),createElementBlock(Fragment,null,renderList(parentChildren.value,child=>(openBlock(),createBlock(PartsBranch_default,{key:child.slotName,"root-slot":__props.rootSlot,child,info:__props.info,"tree-state":__props.treeState,"tree-state-key":child.slotName,"display-names":__props.displayNames,"show-auxiliary":__props.showAuxiliary,"separate-sort":__props.separateSort,"always-sort":__props.alwaysSort,"show-empty":__props.showEmpty,"flat-entry":__props.flatEntry,highlighter:__props.highlighter,onSelect:select,onDeselect:deselect,onHighlight:highlight,onChange:change,onDropdown:dropdown},null,8,[`root-slot`,`child`,`info`,`tree-state`,`tree-state-key`,`display-names`,`show-auxiliary`,`separate-sort`,`always-sort`,`show-empty`,`flat-entry`,`highlighter`]))),128))]),_:1})):__props.treeState&&shouldShow.value?(openBlock(),createBlock(unref(accordionItem_default),{key:1,ref_key:`accordionItem`,ref:accordionItem,static:__props.flatEntry||!childHasChildren.value,expanded:expanded.value,onExpanded:_cache[6]||=$event=>expanded.value=$event,class:normalizeClass({"item-changed":__props.child.changed}),"arrow-big":``,navigable:``,onMouseover:_cache[7]||=withModifiers($event=>select(__props.child,!0),[`stop`]),onMouseleave:_cache[8]||=withModifiers($event=>deselect(__props.child,!0),[`stop`]),onFocusin:_cache[9]||=withModifiers($event=>select(__props.child,!1),[`stop`]),onFocusout:_cache[10]||=withModifiers($event=>deselect(__props.child,!1),[`stop`]),"primary-action":partsList.value.length>0?openPartsDropdown:void 0,"secondary-action":highlightable.value?toggleHighlightCurrent:void 0,"primary-label":`ui.inputActions.menu.menu_item_select.title`,"secondary-label":`ui.vehicleconfig.highlight`,"expand-hint-inline":``,"secondary-hint-inline":``},{caption:withCtx(()=>[withDirectives((openBlock(),createElementBlock(`span`,null,[createTextVNode(toDisplayString(displayName.value),1)])),[[unref(BngHighlighter_default),__props.highlighter]])]),controls:withCtx(()=>[createVNode(unref(bngDropdown_default),{ref_key:`partsDropdown`,ref:partsDropdown,modelValue:__props.child.chosenPartName,"onUpdate:modelValue":_cache[0]||=$event=>__props.child.chosenPartName=$event,items:partsList.value,disabled:!hasPartList.value,highlight:__props.highlighter,"show-search":partsList.value.length>5,"long-names":`cut`,onValueChanged:_cache[1]||=$event=>change(__props.child),onFocus:focusReturn,onOpen:_cache[2]||=$event=>dropdown(!0),onClose:_cache[3]||=$event=>dropdown(!1),"bng-no-nav":``},null,8,[`modelValue`,`items`,`disabled`,`highlight`,`show-search`]),createVNode(unref(bngButton_default),{accent:unref(ACCENTS).text,class:normalizeClass({"visibility-toggle":!0,"visibility-toggle-on":__props.child.highlight}),icon:__props.child.highlight?unref(icons).eyeSolidOpened:unref(icons).eyeSolidClosed,disabled:!highlightable.value,onClick:_cache[4]||=$event=>toggleHighlight(__props.child),onFocus:_cache[5]||=$event=>accordionItem.value.focus(),"bng-no-nav":``},null,8,[`accent`,`class`,`icon`,`disabled`])]),default:withCtx(()=>[!__props.flatEntry&&__props.treeState&&childHasChildren.value?(openBlock(),createBlock(PartsBranch_default,{key:0,children:childChildren.value,info:__props.info,"tree-state":__props.treeState,"display-names":__props.displayNames,"show-auxiliary":__props.showAuxiliary,"separate-sort":__props.separateSort,"always-sort":__props.alwaysSort,"show-empty":__props.showEmpty,highlighter:__props.highlighter,onSelect:select,onDeselect:deselect,onHighlight:highlight,onChange:change,onDropdown:dropdown},null,8,[`children`,`info`,`tree-state`,`display-names`,`show-auxiliary`,`separate-sort`,`always-sort`,`show-empty`,`highlighter`])):!__props.flatEntry&&__props.treeState?(openBlock(),createElementBlock(`div`,_hoisted_1$108,`—`)):createCommentVNode(``,!0)]),_:1},8,[`static`,`expanded`,`class`,`primary-action`,`secondary-action`])):createCommentVNode(``,!0)}},PartsBranch_default=__plugin_vue_export_helper_default(_sfc_main$119,[[`__scopeId`,`data-v-a5433800`]]),SearchHistory=class{list=[];index=-1;browsing=!1;saveKey=`partSearchHistory`;constructor(search$1){this.search=search$1,this.load()}load(){let res=localStorage.getItem(this.saveKey);res&&(this.list=JSON.parse(res)||[])}save(){localStorage.setItem(this.saveKey,JSON.stringify(this.list))}update(){if(this.search.query.length===0)return;let text=(isRef(this.search.text)?this.search.text.value:this.search.text).trim().replace(/ +/g,` `),textLC=text.toLowerCase(),idx=this.list.findIndex(txt=>textLC===txt.toLowerCase());if(idx>-1){this.index=idx;return}idx=this.list.findIndex(txt=>txt.toLowerCase().startsWith(textLC)),!(idx>-1)&&(idx=this.list.findIndex(txt=>textLC.startsWith(txt.toLowerCase())),idx>-1?(this.list[idx]=text,this.index=idx):(this.index=this.list.length,this.list.push(text)),this.save())}onKeyDown(event){if(this.list.length!==0){switch(event.key){case`ArrowUp`:this.browsing=!0,this.index--;break;case`ArrowDown`:this.browsing=!0,this.index++;break;case`k`:if(event.ctrlKey)console.log(`Search history cleaned`),localStorage.removeItem(`partSearchHistory`),this.list=[],this.index=0,event.preventDefault();else return;default:event.ctrlKey||(this.browsing=!1);return}this.browsing&&(this.index=Math.abs(this.index+this.list.length)%this.list.length,this.search.text=this.list[this.index]),event.preventDefault()}}},isOfficial=info=>info.authors!==`BeamNG`,PartsSearch=class{active=!1;text=ref(``);query={};message=ref(``);highlight=ref([]);minText=3;history=null;currentConfig=[];richPartInfo=[];opts={};constructor(currentConfig,richPartInfo,opts=null){if(!isRef(currentConfig))throw Error(`currentConfig must be ref`);if(!isRef(richPartInfo))throw Error(`richPartInfo must be ref`);this.currentConfig=currentConfig,this.richPartInfo=richPartInfo,opts&&(this.opts=opts),this.history=new SearchHistory(this),this.result=computed(()=>this.generateResult()),this.messages={noResults:$translate.instant(`ui.common.search.noResults`),tooShort:$translate.instant(`ui.common.search.queryTooShort`),invalidFormat:$translate.instant(`ui.common.search.invalidFormat`),unknownArgument:$translate.instant(`ui.common.search.unknownArgument`)}}generateResult(){let queryArgs=this.parseQuery(isRef(this.text)?this.text.value:this.text);if(this.query=queryArgs,this.highlight.value=queryArgs.highlight,!queryArgs.good)return this.message.value=queryArgs.reason,{};this.message.value=``;let res={},currentConfig=isRef(this.currentConfig)?this.currentConfig.value:this.currentConfig,cnt=0,dive=node=>{if(node.children)for(let child of Object.values(node.children)){let match=this.matchSlot(child);match.matched&&(child.search=match,res[child.slotName+`?`+ ++cnt]=child),dive(child)}};return dive(currentConfig),Object.keys(res).length>0?this.history.update():this.message.value=this.messages.noResults,res}parseQuery(text){let queryString=text.trim().toLowerCase().replace(/ +/g,` `),queryArgs={mode:`or`,reason:``,highlight:[]},ignoreKeys=Object.keys(queryArgs);if(queryString.length-1){let args2=arg.split(/:/);args2.length===2&&args2[1].trim()!==``?(queryArgs[args2[0]]=args2[1],parsedargs++):queryArgs.reason+=this.messages.invalidFormat+`: ${arg}\n`}else queryArgs.reason+=this.messages.unknownArgument+`: ${arg}\n`;parsedargs>1&&(queryArgs.mode=`and`)}return queryArgs.good=!queryArgs.reason,queryArgs.highlight=queryArgs.good?Object.entries(queryArgs).filter(([key])=>!ignoreKeys.includes(key)).map(([_,value])=>value):[],queryArgs}matchSlot(slot){let opts=this.opts,query=this.query,queryMode={or:(a$1,b)=>a$1||b,and:(a$1,b)=>a$1&&b}[query.mode],queryOr=query.mode===`or`,matched=!queryOr,matchDetails={slot:!1,part:!1,mod:!1},info=isRef(this.richPartInfo)?this.richPartInfo.value:this.richPartInfo,match=(string,query$1)=>matched=queryMode(matched,(string?string.toLowerCase():`empty`).indexOf(query$1)>-1);function*pairs(){query.name&&(yield[`slot`,slot.chosenPartName,query.name]),query.slot&&(yield[`slot`,slot.slotName,query.slot]),query.description&&(yield[`slot`,(slot.parentSlotName&&info[slot.parentSlotName]?.slotInfoUi?.[slot.slotName]||{}).description,query.description]);let part=slot.chosenPartName?info[slot.chosenPartName]:null;if(part?(query.description&&(yield[`slot`,part.description,query.description]),query.author&&(yield[`slot`,part.authors,query.author,!isOfficial(part)]),query.mod&&!isOfficial(part)&&(yield[`slot`,part.description,query.mod,!0])):query.description&&(yield[`slot`,null,query.description]),query.partname||query.description||query.mod||query.author)for(let partNames of[slot.suitablePartNames,slot.unsuitablePartNames.map(({partName})=>partName)])for(let partName of partNames){let part$1=info[partName];!part$1||!opts.showAux&&part$1.isAuxiliary||(query.partname&&(yield[`part`,partName,query.partname]),query.description&&(yield[`part`,part$1.description,query.description]),query.author&&(yield[`part`,part$1.authors,query.author,!isOfficial(part$1)]),query.mod&&part$1&&!isOfficial(part$1)&&(yield[`part`,part$1.description,query.mod,!0]))}}let lastType;for(let[type,string,query$1,isMod=!1]of pairs()){if(query$1&&match(string,query$1)&&(queryOr||lastType!==type)){matchDetails[type]=!0,isMod&&(matchDetails.mod=!0);break}lastType=type}return{matched,matchedSlot:matchDetails.slot,matchedOptions:matchDetails.part,matchedMod:matchDetails.mod}}onChange(){let text=isRef(this.text)?this.text.value:this.text;!this.active&&text&&this.start()}start(){this.active=!0}stop(){this.active=!1,isRef(this.text)?this.text.value=``:this.text=``,this.query={},this.history.index=-1}},_hoisted_1$107={class:`parts-browser-content`},_hoisted_2$90={key:1},_hoisted_3$78={style:{padding:`0.5em`,display:`inline-block`}},_hoisted_4$60={class:`search-help`},_hoisted_5$50={key:0},_hoisted_6$37={class:`parts-options-row parts-options-row-separator`},_hoisted_7$31={class:`parts-options-left`},_hoisted_8$24={class:`popover-contents-wrapper`},_hoisted_9$21={class:`parts-options-right`},_hoisted_10$15={class:`parts-options-row`},_hoisted_11$13={class:`license-plate`},_hoisted_12$9={class:`parts-options-right parts-options-buttons`},treeStateKey=`partsTreeState`,_sfc_main$118={__name:`Parts`,props:{withBackground:Boolean},setup(__props){let events$3=useEvents(),queue$2=new ExecQueue,currentVehID=-1,currentConfig=ref({}),richPartInfo=ref({}),partsHighlighted={},treeState=ref({}),isDev=window.beamng&&!window.beamng.shipping,savedOptions=[`applyPartChangesAutomatically`,`selectSubParts`,`showNames`,`showAux`,`separateSort`,`alwaysSort`],opts=reactive({stickyPartSelection:!1,selectSubParts:!0,applyPartChangesAutomatically:!0,simple:!1,showNames:!1,showAux:!beamng.shipping,separateSort:!1,alwaysSort:!1,showEmpty:!1}),waitingForData=ref(!0),waitForData=async()=>{for(;waitingForData.value;)await sleep(100)},search$1=reactive(new PartsSearch(currentConfig,richPartInfo,opts)),partsChanged=ref(!1),vehChange=()=>Lua_default.extensions.core_vehicle_partmgmt.sendDataToUI();events$3.on(`VehicleFocusChanged`,vehChange),events$3.on(`VehicleJbeamIoChanged`,vehChange);function iterateChildren(slot,func){func(slot),slot.children&&Object.values(slot.children).forEach(child=>iterateChildren(child,func))}async function highlightPart(part){waitingForData.value||(iterateChildren(part,child=>typeof child.highlight==`boolean`?partsHighlighted[child.partPath]=child.highlight=part.highlight:void 0),Lua_default.extensions.core_vehicle_partmgmt.highlightParts(partsHighlighted,currentVehID))}let mouseUsedLast=!0,tmrSelect,selectPart=queue$2.wrap(`selectPart`,async(slot,mouse=!1)=>{if(mouseUsedLast=mouse,tmrSelect&&clearTimeout(tmrSelect),waitingForData.value||opts.stickyPartSelection)return;let parts={};for(let part in opts.selectSubParts?iterateChildren(slot,child=>child.partPath&&(parts[child.partPath]=!0)):parts[slot.partPath]=!0,parts)part in partsHighlighted||delete parts[part];Object.keys(parts).length!==0&&await Lua_default.extensions.core_vehicle_partmgmt.selectParts(parts,currentVehID)},{selectPart:queue$2.resolution.replaceWithResolve,deselectPart:queue$2.resolution.resolveOthers,write:queue$2.resolution.resolveThis,reset:queue$2.resolution.resolveThis,resetAllToLoadedConfig:queue$2.resolution.resolveThis,restoreHighlight:queue$2.resolution.resolveThis}),deselectPart=queue$2.wrap(`deselectPart`,(slot,mouse=!1)=>{mouseUsedLast=mouse,tmrSelect&&clearTimeout(tmrSelect),!waitingForData.value&&(tmrSelect=setTimeout(async()=>{tmrSelect=null,!(opts.stickyPartSelection||Object.keys(currentConfig.value).length===0)&&await Lua_default.extensions.core_vehicle_partmgmt.showHighlightedParts(currentVehID)},100))},{deselectPart:queue$2.resolution.replaceWithResolve,write:queue$2.resolution.resolveThis,reset:queue$2.resolution.resolveThis,resetAllToLoadedConfig:queue$2.resolution.resolveThis,restoreHighlight:queue$2.resolution.resolveThis,restoreSelection:queue$2.resolution.resolveThis}),restoreHighlight=queue$2.wrap(`restoreHighlight`,()=>{tmrSelect&&clearTimeout(tmrSelect),tmrSelect=setTimeout(async()=>{tmrSelect=null,await Lua_default.extensions.core_vehicle_partmgmt.highlightParts(partsHighlighted,currentVehID)},100)},{selectPart:queue$2.resolution.replaceWithResolve,deselectPart:queue$2.resolution.replaceWithResolve,restoreHighlight:queue$2.resolution.replaceWithResolve}),restoreSelection=queue$2.wrap(`restoreSelection`,element=>{element?.partSelect?.()},{selectPart:queue$2.resolution.replaceWithResolve,deselectPart:queue$2.resolution.replaceWithResolve,restoreSelection:queue$2.resolution.replaceWithResolve}),dropdownOpened=val=>opts.stickyPartSelection=val,skipLicGen=ref(!1),licensePlate=ref(``),licensePlateTextValid=ref(!0),settingsChanged=async()=>skipLicGen.value=await Lua_default.settings.getValue(`SkipGenerateLicencePlate`),getLicensePlate=()=>bngApi.engineLua(`core_vehicles.getVehicleLicenseText(getPlayerVehicle(0))`,str=>licensePlate.value=str),applyLicensePlateDebounced=debounce(()=>{opts.applyPartChangesAutomatically&&applyLicensePlate()},500);function applyLicensePlate(){applyLicensePlateDebounced.cancel(),licensePlateTextValid.value&&Lua_default.core_vehicles.setPlateText(licensePlate.value)}function applyRandomLicensePlate(){bngApi.engineLua(`core_vehicles.setPlateText(core_vehicles.regenerateVehicleLicenseText(getPlayerVehicle(0)),nil,nil,nil)`),getLicensePlate()}let isLicensePlateTextValid=text=>(Lua_default.core_vehicles.isLicensePlateValid(text).then(valid=>{licensePlateTextValid.value=valid}),licensePlateTextValid.value),changedPart=null;async function partConfigChanged(part){changedPart=part,opts.applyPartChangesAutomatically?await write():(part.changed=!0,partsChanged.value=!0)}let write=queue$2.wrap(`write`,async()=>{waitingForData.value=!0,await Lua_default.extensions.core_vehicle_partmgmt.setPartsTreeConfig(currentConfig.value),await waitForData()},{write:queue$2.resolution.merge,reset:queue$2.resolution.resolveThis,resetAllToLoadedConfig:queue$2.resolution.resolveThis});queue$2.wrap(`reset`,async()=>{waitingForData.value=!0,await Lua_default.extensions.core_vehicle_partmgmt.resetPartsToLoadedConfig(),await waitForData()},{write:queue$2.resolution.resolveThis,reset:queue$2.resolution.merge,resetAllToLoadedConfig:queue$2.resolution.resolveThis});let resetAllToLoadedConfig=queue$2.wrap(`resetAllToLoadedConfig`,async()=>{waitingForData.value=!0,await Lua_default.extensions.core_vehicle_partmgmt.resetAllToLoadedConfig(),await waitForData()},{write:queue$2.resolution.resolveThis,reset:queue$2.resolution.resolveThis,resetAllToLoadedConfig:queue$2.resolution.merge});function processConfig(config){treeStateSave(),waitingForData.value=!0,richPartInfo.value=Object.fromEntries(Object.entries(config.richPartInfo).map(([name,info])=>[name,info.information])),partsHighlighted=config.partsHighlighted;let processSlot=(slot,slotName,parentSlotName=void 0)=>{if(slot.slotName=slotName,slot.parentSlotName=parentSlotName,changedPart&&changedPart.chosenPartName===slot.chosenPartName&&(changedPart=slot),slot.highlight=config.partsHighlighted[slot.partPath],typeof slot.children==`object`)if(Object.keys(slot.children).length===0)delete slot.children;else for(let childSlotName in slot.children)slot.children[childSlotName]=processSlot(slot.children[childSlotName],childSlotName,slot.chosenPartName);return(typeof slot.suitablePartNames!=`object`||!Array.isArray(slot.suitablePartNames))&&(slot.suitablePartNames=[]),(typeof slot.unsuitablePartNames!=`object`||!Array.isArray(slot.unsuitablePartNames))&&(slot.unsuitablePartNames=[]),slot};currentVehID=config.vehID,currentConfig.value=processSlot(config.chosenPartsTree,config.chosenPartsTree.chosenPartName),partsChanged.value=!1,waitingForData.value=!1,nextTick(()=>{opts.stickyPartSelection=!1,deselectPart(),treeStateLoad(),changedPart=null,opts.applyPartChangesAutomatically&&!mouseUsedLast?restoreSelection(document.activeElement):restoreHighlight()})}events$3.on(`VehicleConfigChange`,processConfig);let readOption=(name,val=null)=>JSON.parse(localStorage.getItem(name)||JSON.stringify(val)),saveOption=(name,val)=>localStorage.setItem(name,JSON.stringify(val)),treeStateStorage=sessionStorage,treeStateSave=()=>currentConfig.value.chosenPartName&&treeStateStorage.setItem(`${treeStateKey}_${currentConfig.value.chosenPartName}`,JSON.stringify(treeState.value)),treeStateLoad=()=>{if(!currentConfig.value.chosenPartName)return;let state=treeStateStorage.getItem(`${treeStateKey}_${currentConfig.value.chosenPartName}`);if(state)try{treeState.value=JSON.parse(state)}catch{treeState.value={}}else treeState.value={}};return onMounted(()=>{settingsChanged(),getLicensePlate(),Lua_default.extensions.core_vehicle_partmgmt.sendDataToUI();for(let name of savedOptions)opts[name]=readOption(name,opts[name])}),onUnmounted(()=>{treeStateSave(),deselectPart(!1)}),(_ctx,_cache)=>withDirectives((openBlock(),createElementBlock(`div`,{class:normalizeClass({"parts-browser":!0,"with-background":__props.withBackground})},[withDirectives((openBlock(),createElementBlock(`div`,{class:`parts-browser-search`,onActivate:_cache[5]||=(...args)=>search$1.start&&search$1.start(...args),onDeactivate:_cache[6]||=()=>!search$1.text&&search$1.stop()},[createVNode(unref(bngInput_default),{modelValue:search$1.text,"onUpdate:modelValue":_cache[0]||=$event=>search$1.text=$event,modelModifiers:{trim:!0},"leading-icon":unref(icons).search,"floating-label":`Search`,onClick:_cache[1]||=$event=>search$1.start(),onValueChanged:_cache[2]||=$event=>search$1.onChange(),onKeydown:_cache[3]||=$event=>search$1.history.onKeyDown($event)},null,8,[`modelValue`,`leading-icon`]),withDirectives(createVNode(unref(bngButton_default),{icon:unref(icons).mathMultiply,style:`font-size: 0.75rem`,accent:unref(ACCENTS).text,onClick:_cache[4]||=$event=>search$1.stop()},null,8,[`icon`,`accent`]),[[unref(BngDisabled_default),!search$1.active]])],32)),[[unref(BngScopedNav_default),{bubbleWhitelistEvents:[`menu`]}]]),withDirectives((openBlock(),createElementBlock(`div`,{class:`parts-browser-content-wrapper`,onMouseleave:_cache[7]||=(...args)=>unref(deselectPart)&&unref(deselectPart)(...args),onDeactivate:_cache[8]||=(...args)=>unref(deselectPart)&&unref(deselectPart)(...args)},[createBaseVNode(`div`,_hoisted_1$107,[!search$1.active&¤tConfig.value?.children&&Object.keys(currentConfig.value.children).length>0?(openBlock(),createBlock(PartsBranch_default,{key:0,"root-slot":``,children:currentConfig.value.children,info:richPartInfo.value,"tree-state":treeState.value,"display-names":opts.showNames,"show-auxiliary":opts.showAux,"separate-sort":opts.separateSort,"always-sort":opts.alwaysSort,"show-empty":opts.showEmpty,onSelect:unref(selectPart),onDeselect:unref(deselectPart),onHighlight:highlightPart,onChange:partConfigChanged,onDropdown:dropdownOpened},null,8,[`children`,`info`,`tree-state`,`display-names`,`show-auxiliary`,`separate-sort`,`always-sort`,`show-empty`,`onSelect`,`onDeselect`])):search$1.active?(openBlock(),createElementBlock(`div`,_hoisted_2$90,[createVNode(PartsBranch_default,{children:search$1.result,info:richPartInfo.value,"tree-state":treeState.value,"flat-entry":``,"display-names":opts.showNames,"show-auxiliary":opts.showAux,"separate-sort":opts.separateSort,"always-sort":opts.alwaysSort,"show-empty":opts.showEmpty,highlighter:search$1.highlight,onSelect:unref(selectPart),onDeselect:unref(deselectPart),onHighlight:highlightPart,onChange:partConfigChanged,onDropdown:dropdownOpened},null,8,[`children`,`info`,`tree-state`,`display-names`,`show-auxiliary`,`separate-sort`,`always-sort`,`show-empty`,`highlighter`,`onSelect`,`onDeselect`]),withDirectives(createBaseVNode(`div`,null,[createVNode(unref(bngIcon_default),{type:unref(icons).danger,color:`#d60`},null,8,[`type`]),createBaseVNode(`span`,_hoisted_3$78,toDisplayString(search$1.message),1)],512),[[vShow,search$1.message!==``]]),withDirectives(createBaseVNode(`div`,_hoisted_4$60,[_cache[37]||=createBaseVNode(`hr`,null,null,-1),_cache[38]||=createTextVNode(` Examples: `,-1),createBaseVNode(`ul`,null,[createBaseVNode(`li`,null,[_cache[23]||=createBaseVNode(`span`,{class:`search-example`},`left`,-1),_cache[24]||=createBaseVNode(`br`,null,null,-1),createTextVNode(` `+toDisplayString(_ctx.$t(`ui.vehicleconfig.searchHelp.example1`)),1)]),createBaseVNode(`li`,null,[_cache[25]||=createBaseVNode(`span`,{class:`search-example`},`slot:_fr`,-1),_cache[26]||=createBaseVNode(`br`,null,null,-1),createTextVNode(` `+toDisplayString(_ctx.$t(`ui.vehicleconfig.searchHelp.example2`)),1)]),createBaseVNode(`li`,null,[_cache[27]||=createBaseVNode(`span`,{class:`search-example`},`name:frame`,-1),_cache[28]||=createBaseVNode(`br`,null,null,-1),createTextVNode(` `+toDisplayString(_ctx.$t(`ui.vehicleconfig.searchHelp.example3`)),1)]),createBaseVNode(`li`,null,[_cache[29]||=createBaseVNode(`span`,{class:`search-example`},`slot:_fr name:signal`,-1),_cache[30]||=createBaseVNode(`br`,null,null,-1),createTextVNode(` `+toDisplayString(_ctx.$t(`ui.vehicleconfig.searchHelp.example4`)),1)]),createBaseVNode(`li`,null,[_cache[31]||=createBaseVNode(`span`,{class:`search-example`},`partname:pickup_fr`,-1),_cache[32]||=createBaseVNode(`br`,null,null,-1),createTextVNode(` `+toDisplayString(_ctx.$t(`ui.vehicleconfig.searchHelp.example5`)),1)]),createBaseVNode(`li`,null,[_cache[33]||=createBaseVNode(`span`,{class:`search-example`},`author:bob`,-1),_cache[34]||=createBaseVNode(`br`,null,null,-1),createTextVNode(` `+toDisplayString(_ctx.$t(`ui.vehicleconfig.searchHelp.example6`)),1)]),createBaseVNode(`li`,null,[_cache[35]||=createBaseVNode(`span`,{class:`search-example`},`mod:super`,-1),_cache[36]||=createBaseVNode(`br`,null,null,-1),createTextVNode(` `+toDisplayString(_ctx.$t(`ui.vehicleconfig.searchHelp.example7`)),1)])]),_cache[39]||=createBaseVNode(`hr`,null,null,-1),createTextVNode(` `+toDisplayString(_ctx.$t(`ui.vehicleconfig.searchHelp.notes`))+`: `,1),createBaseVNode(`ul`,null,[createBaseVNode(`li`,null,toDisplayString(_ctx.$t(`ui.vehicleconfig.searchHelp.notes1`)),1),createBaseVNode(`li`,null,toDisplayString(_ctx.$t(`ui.vehicleconfig.searchHelp.notes3`)),1)])],512),[[vShow,Object.keys(search$1.result).length===0]]),search$1.history.browsing&&search$1.history.list.length>0?(openBlock(),createElementBlock(`div`,_hoisted_5$50,[_cache[40]||=createBaseVNode(`hr`,null,null,-1),createTextVNode(` `+toDisplayString(_ctx.$t(`ui.vehicleconfig.searchHelp.history`))+`: `,1),_cache[41]||=createBaseVNode(`br`,null,null,-1),_cache[42]||=createBaseVNode(`br`,null,null,-1),(openBlock(!0),createElementBlock(Fragment,null,renderList(search$1.history.list,(historyEntry,idx)=>(openBlock(),createElementBlock(`span`,{class:normalizeClass({"history-entry":!0,"history-indicator":idx===search$1.history.index})},toDisplayString(historyEntry),3))),256)),_cache[43]||=createBaseVNode(`br`,null,null,-1),createTextVNode(` `+toDisplayString(_ctx.$t(`ui.vehicleconfig.searchHelp.historyClear`)),1)])):createCommentVNode(``,!0)])):createCommentVNode(``,!0)])],32)),[[unref(BngScopedNav_default),{bubbleWhitelistEvents:[`menu`]}]]),createBaseVNode(`div`,_hoisted_6$37,[createBaseVNode(`div`,_hoisted_7$31,[withDirectives(createVNode(unref(bngButton_default),{accent:unref(ACCENTS).secondary,icon:unref(icons).sortAsc,disabled:waitingForData.value},null,8,[`accent`,`icon`,`disabled`]),[[unref(BngPopover_default),`parts-options-menu`,`top-start`,{click:!0}],[unref(BngTooltip_default),_ctx.$t(`ui.garage.optionsSwitch`),`right`]]),createVNode(unref(bngPopoverMenu_default),{name:`parts-options-menu`,focus:``},{default:withCtx(()=>[createBaseVNode(`div`,_hoisted_8$24,[withDirectives((openBlock(),createBlock(unref(bngButton_default),{accent:unref(ACCENTS).menu,icon:opts.showAux?unref(icons).checkmark:unref(icons)._empty,onClick:_cache[9]||=$event=>saveOption(`showAux`,opts.showAux=!opts.showAux)},{default:withCtx(()=>[createTextVNode(toDisplayString(_ctx.$t(`ui.showAuxiliary`)),1)]),_:1},8,[`accent`,`icon`])),[[unref(BngOnUiNav_default),void 0,`ok`,{focusRequired:!0,asMouse:!0}]]),withDirectives((openBlock(),createBlock(unref(bngButton_default),{accent:unref(ACCENTS).menu,icon:opts.showNames?unref(icons).checkmark:unref(icons)._empty,onClick:_cache[10]||=$event=>saveOption(`showNames`,opts.showNames=!opts.showNames)},{default:withCtx(()=>[createTextVNode(toDisplayString(_ctx.$t(`ui.vehicleconfig.displayNames`)),1)]),_:1},8,[`accent`,`icon`])),[[unref(BngOnUiNav_default),void 0,`ok`,{focusRequired:!0,asMouse:!0}]]),withDirectives((openBlock(),createBlock(unref(bngButton_default),{accent:unref(ACCENTS).menu,icon:opts.selectSubParts?unref(icons).checkmark:unref(icons)._empty,onClick:_cache[11]||=$event=>saveOption(`selectSubParts`,opts.selectSubParts=!opts.selectSubParts)},{default:withCtx(()=>[createTextVNode(toDisplayString(_ctx.$t(`ui.vehicleconfig.subparts`)),1)]),_:1},8,[`accent`,`icon`])),[[unref(BngOnUiNav_default),void 0,`ok`,{focusRequired:!0,asMouse:!0}]]),withDirectives((openBlock(),createBlock(unref(bngButton_default),{accent:unref(ACCENTS).menu,icon:opts.separateSort?unref(icons).checkmark:unref(icons)._empty,onClick:_cache[12]||=$event=>saveOption(`separateSort`,opts.separateSort=!opts.separateSort)},{default:withCtx(()=>[..._cache[44]||=[createTextVNode(`Sort sublists separately`,-1)]]),_:1},8,[`accent`,`icon`])),[[unref(BngOnUiNav_default),void 0,`ok`,{focusRequired:!0,asMouse:!0}]]),withDirectives((openBlock(),createBlock(unref(bngButton_default),{accent:unref(ACCENTS).menu,icon:opts.alwaysSort?unref(icons).checkmark:unref(icons)._empty,onClick:_cache[13]||=$event=>saveOption(`alwaysSort`,opts.alwaysSort=!opts.alwaysSort)},{default:withCtx(()=>[..._cache[45]||=[createTextVNode(`Always sort by name`,-1)]]),_:1},8,[`accent`,`icon`])),[[unref(BngOnUiNav_default),void 0,`ok`,{focusRequired:!0,asMouse:!0}]]),unref(isDev)?withDirectives((openBlock(),createBlock(unref(bngButton_default),{key:0,accent:unref(ACCENTS).menu,icon:opts.showEmpty?unref(icons).checkmark:unref(icons)._empty,onClick:_cache[14]||=$event=>opts.showEmpty=!opts.showEmpty},{default:withCtx(()=>[..._cache[46]||=[createTextVNode(`Show empty slots 🐞`,-1)]]),_:1},8,[`accent`,`icon`])),[[unref(BngOnUiNav_default),void 0,`ok`,{focusRequired:!0,asMouse:!0}]]):createCommentVNode(``,!0)])]),_:1})]),createBaseVNode(`div`,_hoisted_9$21,[createVNode(unref(bngSwitch_default),{disabled:partsChanged.value||waitingForData.value,modelValue:opts.applyPartChangesAutomatically,"onUpdate:modelValue":_cache[15]||=$event=>opts.applyPartChangesAutomatically=$event,onValueChanged:_cache[16]||=$event=>saveOption(`applyPartChangesAutomatically`,opts.applyPartChangesAutomatically)},{default:withCtx(()=>[createTextVNode(toDisplayString(_ctx.$t(`ui.garage.liveUpdates`)),1)]),_:1},8,[`disabled`,`modelValue`])])]),createBaseVNode(`div`,_hoisted_10$15,[withDirectives((openBlock(),createElementBlock(`div`,_hoisted_11$13,[createVNode(unref(bngInput_default),{modelValue:licensePlate.value,"onUpdate:modelValue":_cache[17]||=$event=>licensePlate.value=$event,"floating-label":_ctx.$t(`ui.vehicleconfig.licensePlate`),maxlength:`50`,onValueChanged:_cache[18]||=$event=>unref(applyLicensePlateDebounced)(),onKeyup:_cache[19]||=withKeys($event=>applyLicensePlate(),[`enter`]),validate:isLicensePlateTextValid},null,8,[`modelValue`,`floating-label`]),withDirectives(createVNode(unref(bngButton_default),{accent:unref(ACCENTS).outlined,icon:unref(icons).sync,onClick:_cache[20]||=$event=>applyRandomLicensePlate()},null,8,[`accent`,`icon`]),[[unref(BngTooltip_default),_ctx.$t(`ui.vehicleconfig.licensePlateGen`),`top`]]),opts.applyPartChangesAutomatically?createCommentVNode(``,!0):withDirectives((openBlock(),createBlock(unref(bngButton_default),{key:0,disabled:!licensePlateTextValid.value,icon:unref(icons).checkmark,onClick:_cache[21]||=$event=>applyLicensePlate()},null,8,[`disabled`,`icon`])),[[unref(BngTooltip_default),_ctx.$t(`ui.vehicleconfig.applyLicensePlate`),`top`]])])),[[unref(BngDisabled_default),skipLicGen.value||waitingForData.value],[unref(BngScopedNav_default),{bubbleWhitelistEvents:[`menu`]}]]),createBaseVNode(`div`,_hoisted_12$9,[withDirectives(createVNode(unref(bngButton_default),{"show-hold":``,icon:unref(icons).undo,accent:unref(ACCENTS).custom,class:`reset-button`,disabled:waitingForData.value},null,8,[`icon`,`accent`,`disabled`]),[[unref(BngOnUiNav_default),void 0,`ok`,{asMouse:!0,focusRequired:!0}],[unref(BngClick_default),{holdCallback:unref(resetAllToLoadedConfig),holdDelay:1e3,repeatInterval:0}],[unref(BngTooltip_default),`Reset to original config`]]),createVNode(unref(bngButton_default),{class:`parts-apply-button`,icon:unref(icons).checkmark,onClick:_cache[22]||=$event=>unref(write)(),disabled:opts.applyPartChangesAutomatically||!partsChanged.value||waitingForData.value},{default:withCtx(()=>[createTextVNode(toDisplayString(_ctx.$t(`ui.common.apply`)),1)]),_:1},8,[`icon`,`disabled`])])])],2)),[[unref(BngBlur_default),__props.withBackground]])}},Parts_default=__plugin_vue_export_helper_default(_sfc_main$118,[[`__scopeId`,`data-v-13e05ae0`]]),_hoisted_1$106={key:0,class:`saveload-static`},_hoisted_2$89={class:`saveload-row saveload-filename`},_hoisted_3$77={class:`saveload-list`},_hoisted_4$59=[`onClick`],_hoisted_5$49={class:`saveload-list-item-label`},_hoisted_6$36={class:`saveload-static saveload-row saveload-controls`},_sfc_main$117={__name:`Save`,props:{withBackground:Boolean},setup(__props){useUINavBlocker().blockOnly([`context`]);let{api:api$1}=useBridge(),events$3=useEvents(),saveThumbnail=ref(!0),configList=ref([]),configFiltered=computed(()=>{let res=configList.value;return saveName.value&&(res=res.filter(itm=>itm.name.toLowerCase().includes(saveName.value.toLowerCase()))),res=res.slice().sort((a$1,b)=>a$1.player&&!b.player?-1:!a$1.player&&b.player?1:a$1.name.localeCompare(b.name)),res}),saveDisabled=computed(()=>!saveName.value||/^\.|[<>:"/\\|?*]/.test(saveName.value)),saveName=ref(``),configExists=computed(()=>!!configList.value.some(itm=>itm.name.toLowerCase()===saveName.value.toLowerCase()));async function openConfigFolderInExplorer(){await Lua_default.extensions.core_vehicle_partmgmt.openConfigFolderInExplorer()}async function save(configName){configExists.value&&!await openConfirmation(`Are you sure?`,$translate.instant(`ui.garage.save.overwrite`),[{label:`Overwrite`,value:!0},{label:`Cancel`,value:!1,extras:{accent:ACCENTS.secondary}}])||(await Lua_default.extensions.core_vehicle_partmgmt.saveLocal(configName+`.pc`),saveThumbnail.value&&api$1.engineLua(`extensions.load('util_screenshotCreator'); util_screenshotCreator.startWork({selection="${configName}"})`))}async function load(configName){await Lua_default.extensions.core_vehicle_partmgmt.loadLocal(configName+`.pc`)}async function remove$3(configName){await openConfirmation(`Are you sure?`,`This will permanently remove the configuration. You will not be able to recover it.`,[{label:`Delete permanently`,value:!0,extras:{accent:ACCENTS.attention}},{label:`Cancel`,value:!1,extras:{accent:ACCENTS.secondary}}])&&(await Lua_default.extensions.core_vehicle_partmgmt.removeLocal(configName),await getConfigList())}async function getConfigList(){let configs$1=await Lua_default.extensions.core_vehicle_partmgmt.getConfigList();configList.value=Array.isArray(configs$1)?configs$1:[]}return events$3.on(`VehicleChange`,getConfigList),events$3.on(`VehicleFocusChanged`,getConfigList),events$3.on(`VehicleconfigSaved`,getConfigList),getConfigList(),(_ctx,_cache)=>withDirectives((openBlock(),createElementBlock(`div`,{class:normalizeClass({saveload:!0,"with-background":__props.withBackground})},[configList.value?(openBlock(),createElementBlock(`div`,_hoisted_1$106,[createBaseVNode(`div`,_hoisted_2$89,[createVNode(unref(bngInput_default),{modelValue:saveName.value,"onUpdate:modelValue":_cache[0]||=$event=>saveName.value=$event,modelModifiers:{trim:!0},"leading-icon":unref(icons).saveAs1,"floating-label":_ctx.$t(`ui.vehicleconfig.filename`)},null,8,[`modelValue`,`leading-icon`,`floating-label`]),withDirectives(createVNode(unref(bngButton_default),{icon:unref(icons).mathMultiply,style:`font-size: 0.75rem`,accent:unref(ACCENTS).text,onClick:_cache[1]||=$event=>saveName.value=``},null,8,[`icon`,`accent`]),[[unref(BngDisabled_default),!saveName.value]]),withDirectives((openBlock(),createBlock(unref(bngButton_default),{accent:configExists.value?unref(ACCENTS).attention:unref(ACCENTS).main,onClick:_cache[2]||=$event=>save(saveName.value)},{default:withCtx(()=>[createTextVNode(toDisplayString(configExists.value?_ctx.$t(`ui.common.overwrite`):_ctx.$t(`ui.common.save`)),1)]),_:1},8,[`accent`])),[[unref(BngDisabled_default),saveDisabled.value]])])])):createCommentVNode(``,!0),createBaseVNode(`div`,_hoisted_3$77,[(openBlock(!0),createElementBlock(Fragment,null,renderList(configFiltered.value,config=>(openBlock(),createElementBlock(`div`,{class:`saveload-list-item`,onClick:$event=>saveName.value=config.name,tabindex:`1`},[config.official?withDirectives((openBlock(),createBlock(unref(bngIcon_default),{key:0,type:unref(icons).beamNG},null,8,[`type`])),[[unref(BngTooltip_default),_ctx.$t(`ui.vehicleconfig.sourceOfficial`),`top`]]):config.player?withDirectives((openBlock(),createBlock(unref(bngIcon_default),{key:1,type:unref(icons).personSolid},null,8,[`type`])),[[unref(BngTooltip_default),_ctx.$t(`ui.vehicleconfig.sourceUser`),`top`]]):withDirectives((openBlock(),createBlock(unref(bngIcon_default),{key:2,type:unref(icons).puzzleModule},null,8,[`type`])),[[unref(BngTooltip_default),_ctx.$t(`ui.vehicleconfig.sourceMod`),`top`]]),createBaseVNode(`div`,_hoisted_5$49,toDisplayString(config.name),1),withDirectives((openBlock(),createBlock(unref(bngButton_default),{class:`saveload-list-item-load`,accent:unref(ACCENTS).outlined,icon:unref(icons).BNGFolder,onClick:withModifiers($event=>load(config.name),[`stop`])},{default:withCtx(()=>[createTextVNode(toDisplayString(_ctx.$t(`ui.vehicleconfig.load`)),1)]),_:1},8,[`accent`,`icon`,`onClick`])),[[unref(BngTooltip_default),_ctx.$t(`ui.vehicleconfig.loadTooltip`),`top`]]),config.player?withDirectives((openBlock(),createBlock(unref(bngButton_default),{key:3,class:`saveload-list-item-delete`,accent:unref(ACCENTS).outlined,icon:unref(icons).trashBin2,onClick:withModifiers($event=>remove$3(config.name),[`stop`])},null,8,[`accent`,`icon`,`onClick`])),[[unref(BngTooltip_default),`Remove configuration`,`top`]]):createCommentVNode(``,!0)],8,_hoisted_4$59))),256))]),createBaseVNode(`div`,_hoisted_6$36,[createVNode(unref(bngSwitch_default),{modelValue:saveThumbnail.value,"onUpdate:modelValue":_cache[3]||=$event=>saveThumbnail.value=$event},{default:withCtx(()=>[createTextVNode(toDisplayString(_ctx.$t(`ui.vehicleconfig.saveThumbnail`)),1)]),_:1},8,[`modelValue`]),createVNode(unref(bngButton_default),{accent:unref(ACCENTS).main,onClick:_cache[4]||=$event=>openConfigFolderInExplorer()},{default:withCtx(()=>[createTextVNode(toDisplayString(_ctx.$t(`ui.vehicleconfig.openConfigFolder`)),1)]),_:1},8,[`accent`])])],2)),[[unref(BngBlur_default),__props.withBackground]])}},Save_default=__plugin_vue_export_helper_default(_sfc_main$117,[[`__scopeId`,`data-v-31dd4dbb`]]),_hoisted_1$105={class:`garage-row-title`},_hoisted_2$88={class:`headingContainer`},_hoisted_3$76={class:`garage-title-sup`},_hoisted_4$58={class:`garage-title-main`},_hoisted_5$48={class:`garage-row-main`},_hoisted_6$35={class:`garage-menu-container garage-menu-main`},_hoisted_7$30={key:0,class:`garage-menu garage-menu-primary`},_hoisted_8$23={key:1,class:`garage-menu garage-menu-secondary`},_hoisted_9$20={key:2,class:`garage-content`},_hoisted_10$14={class:`garage-sidemenu-title`},_hoisted_11$12={class:`garage-drawer-header`},_hoisted_12$8={class:`garage-drawer-content`},_hoisted_13$8={class:`garage-drawer-header`},_hoisted_14$8={class:`garage-drawer-content`},_hoisted_15$8={class:`garage-drawer-header`},_hoisted_16$8={class:`garage-drawer-content`},_hoisted_17$7={class:`garage-row-bottom`},ownerId=`garage`,_sfc_main$116={__name:`Garage`,props:{component:String},setup(__props){let components={paint:Paint_default,parts:Parts_default,tuning:Tuning_default,save:Save_default},uiNavTracker=useUINavTracker(),{showIfController}=storeToRefs(controls_default()),{lua,api:api$1}=useBridge(),events$3=useEvents(),bngVue$1=window.bngVue||{gotoGameState(){}},backBinding=ref(null),streamsList$1=[`electrics`];useStreams(streamsList$1,onStreamsUpdate);let drawerCamera=ref(!1),drawerVehicle=ref(!1),drawerGarage=ref(!1);watch(()=>showIfController,val=>val?uiNavTracker.addIgnore(`action_4`,ownerId):uiNavTracker.removeIgnore(`action_4`,ownerId),{immediate:!0});let launchLiveryEditor=async()=>{await runRaw(`extensions.core_vehicle_partmgmt.hasAvailablePart(be:getPlayerVehicle(0).JBeam .. "_skin_dynamicTextures")`)?await openExperimental(`Dynamic Decals`,`This is an early highly experimental preview of the Decal Editor. Please be aware that anything created with this feature may be lost in future hotfixes and updates. Do you wish to proceed?`,[{label:$translate.instant(`ui.common.no`),value:!1,extras:{accent:ACCENTS.secondary}},{label:`Yes, I'm buckled up and ready to go!`,value:!0,extras:{default:!0}}])&&bngVue$1.gotoGameState(`livery-manager`):openMessage(``,$translate.instant(`ui.garage.decals.notAvailableForVehicle`))},props=__props,sidemenuActive=ref(!1);function activateSidemenu(){sidemenuActive.value=!0}function deactivateSidemenu(){sidemenuActive.value=!1,nextTick(()=>{drawerCamera.value=!1,drawerVehicle.value=!1,drawerGarage.value=!1})}function toggleSidemenu(){sidemenuActive.value=!sidemenuActive.value}let canSidemenuDeactivate=()=>!drawerCamera.value&&!drawerVehicle.value&&!drawerGarage.value,lightState=ref([!1,!1,!1]);async function lightToggle(idx){lightState.value[idx]=!lightState.value[idx],await lua.extensions.gameplay_garageMode.setLighting(lightState.value)}async function setCamera(view){await lua.extensions.gameplay_garageMode.setCamera(view)}let switches=reactive({lowbeam:{func:`setLightsState`,value:`lights_state`,on:1,off:0,state:!1},highbeam:{func:`setLightsState`,value:`lights_state`,on:2,off:0,state:!1},fog:{func:`set_fog_lights`,value:`fog`,on:1,off:0,state:!1},lightbar:{func:`set_lightbar_signal`,value:`lightbar`,on:1,off:0,state:!1},hazard:{func:`set_warn_signal`,value:`hazard_enabled`,on:1,off:0,state:!1}});function vehSwitch(key,on){if(!(key in switches))return;let svc=switches[key];if(on===void 0)on=!svc.state;else if(on===svc.state)return;api$1.activeObjectLua(`electrics.${svc.func}(${on?svc.on:svc.off})`)}let loaded=reactive({init:!1,vehicle:!1,status:!1}),vehicle=reactive({name:`Unknown`,vehicle:null,electrics:{},state:{}}),blackscreen=ref(!1),vehcomp=ref(``),vehcompview=ref(null),tmrInit;async function menuOpen(mode){vehcomp.value=vehcomp.value===mode?``:mode;let component=null;switch(mode){case`paint`:lua.extensions.gameplay_garageMode.setGarageMenuState(`paint`),component=components.paint;break;case`decals`:bngVue$1.gotoGameState(`decals-loader`);break;case`parts`:lua.extensions.gameplay_garageMode.setGarageMenuState(`parts`),component=components.parts;break;case`tuning`:lua.extensions.gameplay_garageMode.setGarageMenuState(`tuning`),component=components.tuning;break;case`vehicles`:lua.extensions.gameplay_garageMode.setGarageMenuState(`vehicles`),bngVue$1.gotoGameState(`menu.vehicles`,{params:{mode:`garageMode`,garage:`all`}});break;case`mycars`:lua.extensions.gameplay_garageMode.setGarageMenuState(`myCars`),bngVue$1.gotoGameState(`menu.vehicles`,{params:{mode:`garageMode`,garage:`own`}});break;case`photo`:bngVue$1.gotoGameState(`menu.photomode`);break;case`save`:component=components.save;break;case`savedefault`:console.log(`TODO: save as default`);break;case`test`:vehcomp.value=``,lua.extensions.gameplay_garageMode.testVehicle();break;default:vehcomp.value=``;break}component&&(vehcompview.value=markRaw(component))}function exit(event){event.detail.force||(vehcomp.value?menuOpen():window.bngVue.gotoAngularState(`menu.mainmenu`))}async function vehChange(){loaded.vehicle=!1,loaded.status=!1,vehicle.name=`Unknown`,vehicle.vehicle=null,vehicle.electrics={},await api$1.activeObjectLua(`electrics.setIgnitionLevel(1)`);let data=await lua.core_vehicles.getCurrentVehicleDetails();tmrInit&&=(loaded.init=!0,clearTimeout(tmrInit),null),data&&(loaded.vehicle=!0,vehicle.vehicle=data,data.model.Brand?vehicle.name=`${data.model.Brand} ${data.model.Name}`:vehicle.name=data.configs.Name,data.configs.Configuration&&(data.configs.Source===`BeamNG - Official`?vehicle.name+=` - ${data.configs.Configuration}`:vehicle.name+=` - Custom`))}function onStreamsUpdate(streams){if(typeof streams!=`object`||!streamsList$1.every(name=>name in streams))return;let data=streams.electrics;for(let key in loaded.status=data.ignitionLevel>0,switches){let svc=switches[key];svc.state=svc.value in data&&data[svc.value]===svc.on,vehicle.electrics[key]=svc.state}}let canScopeDeactivate=()=>!vehcomp.value;return onBeforeMount(async()=>{tmrInit=setTimeout(()=>{console.log(`Unable to get vehicle details in time. Forcing to init...`),loaded.init=!0,tmrInit=null},3e3),events$3.on(`VehicleChange`,vehChange),api$1.activeObjectLua(`electrics.setIgnitionLevel(1)`),events$3.on(`GarageModeBlackscreen`,data=>blackscreen.value=data.active),vehChange(),lightState.value=await lua.extensions.gameplay_garageMode.getLighting(),props.component&&menuOpen(props.component)}),onUnmounted(()=>{tmrInit&&clearTimeout(tmrInit)}),(_ctx,_cache)=>(openBlock(),createElementBlock(Fragment,null,[withDirectives(createBaseVNode(`div`,{class:normalizeClass([`garage-blackscreen`,{"garage-blackscreen-active":blackscreen.value}])},null,2),[[unref(BngBlur_default),blackscreen.value]]),loaded.init?withDirectives((openBlock(),createElementBlock(`div`,{key:0,class:`garage-view`,onDeactivate:exit},[createBaseVNode(`div`,_hoisted_1$105,[createBaseVNode(`div`,_hoisted_2$88,[withDirectives((openBlock(),createElementBlock(`div`,_hoisted_3$76,[createBaseVNode(`h4`,null,[createTextVNode(toDisplayString(_ctx.$t(`ui.mainmenu.garage`))+` `,1),vehcomp.value?(openBlock(),createElementBlock(Fragment,{key:0},[createTextVNode(`/ `+toDisplayString(vehicle.name),1)],64)):createCommentVNode(``,!0)])])),[[unref(BngBlur_default)]]),withDirectives((openBlock(),createElementBlock(`h2`,_hoisted_4$58,[vehcomp.value?withDirectives((openBlock(),createBlock(unref(bngButton_default),{key:0,class:normalizeClass([`garage-back-button`,{"garage-back-binding-shown":backBinding.value?.displayed}]),accent:backBinding.value?.displayed?unref(ACCENTS).ghost:unref(ACCENTS).outlined,icon:unref(icons).arrowLargeLeft,"bng-no-nav":`true`,onClick:exit},{default:withCtx(()=>[withDirectives(createVNode(unref(bngBinding_default),{ref_key:`backBinding`,ref:backBinding,class:`back-binding`,"ui-event":`back`,controller:``,"track-ignore":``},null,512),[[vShow,!sidemenuActive.value]]),createTextVNode(` `+toDisplayString(backBinding.value?.displayed?``:_ctx.$t(`ui.common.back`)),1)]),_:1},8,[`class`,`accent`,`icon`])),[[unref(BngTooltip_default),!backBinding.value||backBinding.value?.displayed?_ctx.$t(`ui.common.back`):void 0,`top`]]):createCommentVNode(``,!0),createBaseVNode(`span`,null,toDisplayString(vehcomp.value?_ctx.$t(`ui.garage.tabs.`+(vehcomp.value===`tuning`?`tune`:vehcomp.value)):vehicle.name),1)])),[[unref(BngBlur_default)]])])]),createBaseVNode(`div`,_hoisted_5$48,[createBaseVNode(`div`,_hoisted_6$35,[vehcomp.value?createCommentVNode(``,!0):(openBlock(),createElementBlock(`div`,_hoisted_7$30,[withDirectives((openBlock(),createBlock(GarageButton_default,{icon:unref(icons).engine,active:vehcomp.value===`parts`,onClick:_cache[0]||=$event=>menuOpen(`parts`),"bng-scoped-nav-autofocus":loaded.vehicle&&!sidemenuActive.value&&unref(showIfController)},{default:withCtx(()=>[createTextVNode(toDisplayString(_ctx.$t(`ui.garage.tabs.parts`)),1)]),_:1},8,[`icon`,`active`,`bng-scoped-nav-autofocus`])),[[unref(BngDisabled_default),!loaded.vehicle],[unref(BngBlur_default)]]),withDirectives((openBlock(),createBlock(GarageButton_default,{icon:unref(icons).wrench,active:vehcomp.value===`tuning`,onClick:_cache[1]||=$event=>menuOpen(`tuning`)},{default:withCtx(()=>[createTextVNode(toDisplayString(_ctx.$t(`ui.garage.tabs.tune`)),1)]),_:1},8,[`icon`,`active`])),[[unref(BngDisabled_default),!loaded.vehicle],[unref(BngBlur_default)]]),withDirectives((openBlock(),createBlock(GarageButton_default,{icon:unref(icons).sprayCan,active:vehcomp.value===`paint`,onClick:_cache[2]||=$event=>menuOpen(`paint`)},{default:withCtx(()=>[createTextVNode(toDisplayString(_ctx.$t(`ui.garage.tabs.paint`)),1)]),_:1},8,[`icon`,`active`])),[[unref(BngDisabled_default),!loaded.vehicle],[unref(BngBlur_default)]]),withDirectives((openBlock(),createBlock(GarageButton_default,{icon:unref(icons).star,active:vehcomp.value===`decals`,onClick:launchLiveryEditor},{default:withCtx(()=>[createTextVNode(toDisplayString(_ctx.$t(`ui.garage.tabs.decals`)),1)]),_:1},8,[`icon`,`active`])),[[unref(BngDisabled_default),!loaded.vehicle],[unref(BngBlur_default)]])])),vehcomp.value?createCommentVNode(``,!0):(openBlock(),createElementBlock(`div`,_hoisted_8$23,[withDirectives((openBlock(),createBlock(GarageButton_default,{icon:unref(icons).car,active:vehcomp.value===`vehicles`,onClick:_cache[3]||=$event=>menuOpen(`vehicles`)},{default:withCtx(()=>[createTextVNode(toDisplayString(_ctx.$t(`ui.garage.tabs.vehicles`)),1)]),_:1},8,[`icon`,`active`])),[[unref(BngDisabled_default),!loaded.vehicle],[unref(BngBlur_default)]]),withDirectives((openBlock(),createBlock(GarageButton_default,{icon:unref(icons).keys1,active:vehcomp.value===`mycars`,onClick:_cache[4]||=$event=>menuOpen(`mycars`)},{default:withCtx(()=>[createTextVNode(toDisplayString(_ctx.$t(`ui.garage.tabs.load`)),1)]),_:1},8,[`icon`,`active`])),[[unref(BngDisabled_default),!loaded.vehicle],[unref(BngBlur_default)]]),withDirectives((openBlock(),createBlock(GarageButton_default,{icon:unref(icons).photo,onClick:_cache[5]||=$event=>menuOpen(`photo`)},{default:withCtx(()=>[createTextVNode(toDisplayString(_ctx.$t(`ui.garage.tabs.photo`)),1)]),_:1},8,[`icon`])),[[unref(BngDisabled_default),!loaded.vehicle],[unref(BngBlur_default)]])])),vehcomp.value&&vehcompview.value?withDirectives((openBlock(),createElementBlock(`div`,_hoisted_9$20,[(openBlock(),createBlock(resolveDynamicComponent(vehcompview.value),{"with-background":``,"with-padding":!1}))])),[[unref(BngOnUiNav_default),exit,`menu,back`],[unref(BngFrustumMover_default),!0,`left`]]):createCommentVNode(``,!0)]),withDirectives((openBlock(),createElementBlock(`div`,{class:`garage-sidemenu`,onActivate:activateSidemenu,onDeactivate:deactivateSidemenu},[withDirectives((openBlock(),createElementBlock(`h4`,_hoisted_10$14,[createVNode(unref(bngBinding_default),{class:`back-binding`,"ui-event":`action_4`,controller:``}),createTextVNode(` `+toDisplayString(_ctx.$t(`ui.garage2.features`)),1)])),[[unref(BngBlur_default)]]),createVNode(unref(drawer_default),{modelValue:drawerCamera.value,"onUpdate:modelValue":_cache[12]||=$event=>drawerCamera.value=$event,position:`left`,class:`garage-menugroup`},{header:withCtx(()=>[withDirectives((openBlock(),createElementBlock(`div`,_hoisted_11$12,[withDirectives((openBlock(),createBlock(GarageButton_default,{type:`drawer-toggle`,icon:unref(icons).movieCamera,active:drawerCamera.value,"bng-scoped-nav-autofocus":sidemenuActive.value&&unref(showIfController),onClick:_cache[6]||=$event=>drawerCamera.value=!drawerCamera.value},{default:withCtx(()=>[createTextVNode(toDisplayString(_ctx.$t(`ui.garage.photo.camera`)),1)]),_:1},8,[`icon`,`active`,`bng-scoped-nav-autofocus`])),[[unref(BngDisabled_default),!loaded.init]])])),[[unref(BngBlur_default)]])]),"expanded-content":withCtx(()=>[withDirectives((openBlock(),createElementBlock(`div`,_hoisted_12$8,[createVNode(GarageButton_default,{type:`drawer-button`,icon:unref(icons).camera3Fourth1,onClick:_cache[7]||=$event=>setCamera(`default`)},{default:withCtx(()=>[createTextVNode(toDisplayString(_ctx.$t(`engine.editor.menu.standartCamera`)),1)]),_:1},8,[`icon`]),createVNode(GarageButton_default,{type:`drawer-button`,icon:unref(icons).cameraFront1,onClick:_cache[8]||=$event=>setCamera(`front`)},{default:withCtx(()=>[createTextVNode(toDisplayString(_ctx.$t(`engine.editor.menu.camera.front`)),1)]),_:1},8,[`icon`]),createVNode(GarageButton_default,{type:`drawer-button`,icon:unref(icons).cameraBack1,onClick:_cache[9]||=$event=>setCamera(`back`)},{default:withCtx(()=>[createTextVNode(toDisplayString(_ctx.$t(`engine.editor.menu.camera.back`)),1)]),_:1},8,[`icon`]),createVNode(GarageButton_default,{type:`drawer-button`,icon:unref(icons).cameraSideRight,onClick:_cache[10]||=$event=>setCamera(`side`)},{default:withCtx(()=>[createTextVNode(toDisplayString(_ctx.$t(`engine.editor.menu.camera.right`)),1)]),_:1},8,[`icon`]),createVNode(GarageButton_default,{type:`drawer-button`,icon:unref(icons).cameraTop1,onClick:_cache[11]||=$event=>setCamera(`top`)},{default:withCtx(()=>[createTextVNode(toDisplayString(_ctx.$t(`engine.editor.menu.camera.top`)),1)]),_:1},8,[`icon`])])),[[unref(BngOnUiNav_default),toggleSidemenu,`menu,back`],[unref(BngBlur_default)]])]),_:1},8,[`modelValue`]),createVNode(unref(drawer_default),{modelValue:drawerVehicle.value,"onUpdate:modelValue":_cache[19]||=$event=>drawerVehicle.value=$event,position:`left`,class:`garage-menugroup`},{header:withCtx(()=>[withDirectives((openBlock(),createElementBlock(`div`,_hoisted_13$8,[withDirectives((openBlock(),createBlock(GarageButton_default,{type:`drawer-toggle`,icon:unref(icons).electronicSchemeOutline,active:drawerVehicle.value,onClick:_cache[13]||=$event=>drawerVehicle.value=!drawerVehicle.value},{default:withCtx(()=>[createTextVNode(toDisplayString(_ctx.$t(`ui.radialmenu2.electrics`)),1)]),_:1},8,[`icon`,`active`])),[[unref(BngDisabled_default),!loaded.vehicle||!loaded.status]])])),[[unref(BngBlur_default)]])]),"expanded-content":withCtx(()=>[withDirectives((openBlock(),createElementBlock(`div`,_hoisted_14$8,[withDirectives((openBlock(),createBlock(GarageButton_default,{type:`drawer-button`,icon:unref(icons).lowBeam,active:vehicle.electrics.lowbeam,onClick:_cache[14]||=$event=>vehSwitch(`lowbeam`)},{default:withCtx(()=>[createTextVNode(toDisplayString(_ctx.$t(`ui.radialmenu2.electrics.headlights.low`)),1)]),_:1},8,[`icon`,`active`])),[[unref(BngDisabled_default),!loaded.vehicle]]),withDirectives((openBlock(),createBlock(GarageButton_default,{type:`drawer-button`,icon:unref(icons).highBeam,active:vehicle.electrics.highbeam,onClick:_cache[15]||=$event=>vehSwitch(`highbeam`)},{default:withCtx(()=>[createTextVNode(toDisplayString(_ctx.$t(`ui.radialmenu2.electrics.headlights.high`)),1)]),_:1},8,[`icon`,`active`])),[[unref(BngDisabled_default),!loaded.vehicle]]),withDirectives((openBlock(),createBlock(GarageButton_default,{type:`drawer-button`,icon:unref(icons).fogLight,active:vehicle.electrics.fog_lights,onClick:_cache[16]||=$event=>vehSwitch(`fog`)},{default:withCtx(()=>[createTextVNode(toDisplayString(_ctx.$t(`ui.radialmenu2.electrics.fog_lights`)),1)]),_:1},8,[`icon`,`active`])),[[unref(BngDisabled_default),!loaded.vehicle]]),withDirectives((openBlock(),createBlock(GarageButton_default,{type:`drawer-button`,icon:unref(icons).hazardLights,active:vehicle.electrics.hazard,onClick:_cache[17]||=$event=>vehSwitch(`hazard`)},{default:withCtx(()=>[createTextVNode(toDisplayString(_ctx.$t(`ui.radialmenu2.electrics.hazard_lights`)),1)]),_:1},8,[`icon`,`active`])),[[unref(BngDisabled_default),!loaded.vehicle]]),withDirectives((openBlock(),createBlock(GarageButton_default,{type:`drawer-button`,icon:unref(icons).wigwags,active:vehicle.electrics.lightbar,onClick:_cache[18]||=$event=>vehSwitch(`lightbar`)},{default:withCtx(()=>[createTextVNode(toDisplayString(_ctx.$t(`ui.radialmenu2.electrics.lightbar`)),1)]),_:1},8,[`icon`,`active`])),[[unref(BngDisabled_default),!loaded.vehicle]])])),[[unref(BngOnUiNav_default),toggleSidemenu,`menu,back`],[unref(BngBlur_default)]])]),_:1},8,[`modelValue`]),createVNode(unref(drawer_default),{modelValue:drawerGarage.value,"onUpdate:modelValue":_cache[24]||=$event=>drawerGarage.value=$event,position:`left`,class:`garage-menugroup`},{header:withCtx(()=>[withDirectives((openBlock(),createElementBlock(`div`,_hoisted_15$8,[withDirectives((openBlock(),createBlock(GarageButton_default,{type:`drawer-toggle`,icon:unref(icons).garage01,active:drawerGarage.value,onClick:_cache[20]||=$event=>drawerGarage.value=!drawerGarage.value},{default:withCtx(()=>[createTextVNode(toDisplayString(_ctx.$t(`ui.garage2.features`)),1)]),_:1},8,[`icon`,`active`])),[[unref(BngDisabled_default),!loaded.init]])])),[[unref(BngBlur_default)]])]),"expanded-content":withCtx(()=>[withDirectives((openBlock(),createElementBlock(`div`,_hoisted_16$8,[createVNode(GarageButton_default,{type:`drawer-button`,icon:unref(icons).lightGarageG32,active:lightState.value[0],onClick:_cache[21]||=$event=>lightToggle(0)},{default:withCtx(()=>[createTextVNode(toDisplayString(_ctx.$t(`ui.garage2.lights.west`)),1)]),_:1},8,[`icon`,`active`]),createVNode(GarageButton_default,{type:`drawer-button`,icon:unref(icons).lightGarageG22,active:lightState.value[1],onClick:_cache[22]||=$event=>lightToggle(1)},{default:withCtx(()=>[createTextVNode(toDisplayString(_ctx.$t(`ui.garage2.lights.middle`)),1)]),_:1},8,[`icon`,`active`]),createVNode(GarageButton_default,{type:`drawer-button`,icon:unref(icons).lightGarageG12,active:lightState.value[2],onClick:_cache[23]||=$event=>lightToggle(2)},{default:withCtx(()=>[createTextVNode(toDisplayString(_ctx.$t(`ui.garage2.lights.east`)),1)]),_:1},8,[`icon`,`active`])])),[[unref(BngOnUiNav_default),toggleSidemenu,`menu,back`],[unref(BngBlur_default)]])]),_:1},8,[`modelValue`])],32)),[[unref(BngScopedNav_default),{activated:sidemenuActive.value,type:`container`,bubbleWhitelistEvents:[`menu`],canDeactivate:canSidemenuDeactivate}],[unref(BngOnUiNav_default),toggleSidemenu,`action_4`]])]),createBaseVNode(`div`,_hoisted_17$7,[withDirectives(createVNode(GarageButton_default,{active:vehcomp.value===`save`,onClick:_cache[25]||=$event=>menuOpen(`save`),icon:unref(icons).saveAs1},null,8,[`active`,`icon`]),[[unref(BngDisabled_default),!loaded.vehicle],[unref(BngBlur_default)],[unref(BngTooltip_default),_ctx.$t(`ui.vehicleconfig.save`),`top`]]),withDirectives(createVNode(GarageButton_default,{onClick:_cache[26]||=$event=>menuOpen(`test`),icon:unref(icons).trafficCone},null,8,[`icon`]),[[unref(BngDisabled_default),!loaded.vehicle],[unref(BngBlur_default)],[unref(BngTooltip_default),_ctx.$t(`ui.common.test`),`top`]])])],32)),[[unref(BngScopedNav_default),{activateOnMount:!0,bubbleWhitelistEvents:[`menu`],canDeactivate:canScopeDeactivate}],[unref(BngOnUiNav_default),toggleSidemenu,`action_4`]]):createCommentVNode(``,!0)],64))}},Garage_default=__plugin_vue_export_helper_default(_sfc_main$116,[[`__scopeId`,`data-v-b5f03823`]]),routes_default$7=[{path:`/garagemode/:component?`,name:`garagemode`,component:Garage_default,props:!0,meta:{infoBar:{visible:!0,showSysInfo:!1},uiApps:{shown:!0}}},{path:`/garagemode/tuning`,name:`garagemode.tuning`,component:Garage_default,props:{component:`tuning`},meta:{infoBar:{visible:!0,showSysInfo:!1},uiApps:{shown:!0}}}],_hoisted_1$104={class:`edit-form`},_sfc_main$115={__name:`FileEditForm`,props:{modelValue:{type:[Object,String,Number,Boolean],required:!0}},emits:[`update:modelValue`],setup(__props,{emit:__emit}){let props=__props,emit$1=__emit,formModel=computed({get:()=>props.modelValue,set:newValue=>{emit$1(`update:modelValue`,newValue)}});return(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$104,[createVNode(unref(bngInput_default),{modelValue:formModel.value.name,"onUpdate:modelValue":_cache[0]||=$event=>formModel.value.name=$event,suffix:`.dyndecals.json`},null,8,[`modelValue`])]))}},FileEditForm_default=__plugin_vue_export_helper_default(_sfc_main$115,[[`__scopeId`,`data-v-c94cd7bf`]]),_sfc_main$114={__name:`RenameLayerForm`,props:{modelValue:{type:[Object,String,Number,Boolean],required:!0}},emits:[`update:modelValue`],setup(__props,{emit:__emit}){let props=__props,emit$1=__emit,formModel=computed({get:()=>props.modelValue,set:newValue=>{emit$1(`update:modelValue`,newValue)}});return(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,null,[createVNode(unref(bngInput_default),{modelValue:formModel.value.name,"onUpdate:modelValue":_cache[0]||=$event=>formModel.value.name=$event},null,8,[`modelValue`])]))}},RenameLayerForm_default=_sfc_main$114,_hoisted_1$103={class:`exit-editor-dialog`},_hoisted_2$87={class:`apply-skin-wrapper`},_sfc_main$113={__name:`ExitEditorDialog`,props:{modelValue:{type:[Object,String,Number,Boolean],required:!0}},emits:[`update:modelValue`],setup(__props,{emit:__emit}){let props=__props,emit$1=__emit,formModel=computed({get:()=>props.modelValue,set:newValue=>{emit$1(`update:modelValue`,newValue)}});return(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$103,[createVNode(unref(bngInput_default),{modelValue:formModel.value.name,"onUpdate:modelValue":_cache[0]||=$event=>formModel.value.name=$event,suffix:`.dyndecals.json`},null,8,[`modelValue`]),createBaseVNode(`div`,_hoisted_2$87,[createVNode(unref(bngPillCheckbox_default),{modelValue:formModel.value.applySkin,"onUpdate:modelValue":_cache[1]||=$event=>formModel.value.applySkin=$event,disabled:!formModel.value.name},{default:withCtx(()=>[..._cache[2]||=[createTextVNode(`Apply Skin`,-1)]]),_:1},8,[`modelValue`,`disabled`])])]))}},ExitEditorDialog_default=__plugin_vue_export_helper_default(_sfc_main$113,[[`__scopeId`,`data-v-b4897c9e`]]);const openEditFileDialog=(title,description,formModel,formValidator)=>openFormDialog(FileEditForm_default,formModel,formValidator,title,description),openRenameLayerDialog=(title,description,formModel,formValidator)=>openFormDialog(RenameLayerForm_default,formModel,formValidator,title,description);var SELECTION_LUA$1=Lua_default.extensions.ui_liveryEditor_selection;const useLayerActionsStore=defineStore(`createLayer`,()=>{async function onActionItemSelected(action){if(!action.items)if(console.log(`[onActionItemSelected] do action`),action.value===`group`)await Lua_default.extensions.ui_liveryEditor_tools_group.groupLayers();else if(action.value===`ungroup`)await Lua_default.extensions.ui_liveryEditor_tools_group.ungroupLayer();else if(action.value===`delete`)await openConfirmation(`Delete Layer`,`Are you sure you want to delete ${singleSelectedLayer.value.name}?`)&&await Lua_default.extensions.ui_liveryEditor_tools_settings.deleteLayer();else if(action.value===`rename`){let res=await openRenameLayerDialog(`Rename Layer`,``,{name:singleSelectedLayer.value.name},model=>model.name!==null&&model.name!==void 0&&model.name!==``&&model.name!==singleSelectedLayer.value.name);res.value&&await Lua_default.extensions.ui_liveryEditor_tools_settings.rename(res.formData.name)}else action.value===`duplicate`?await SELECTION_LUA$1.duplicateSelectedLayer():await Lua_default.extensions.ui_liveryEditor_tools.useTool(action.value)}return{onActionItemSelected}});var EDIT_MODE=Lua_default.extensions.ui_liveryEditor_editMode,DECAL_LAYER=Lua_default.extensions.ui_liveryEditor_layers_decals,TRANSFORM_TOOL=Lua_default.extensions.ui_liveryEditor_tools_transform,MATERIAL_TOOL=Lua_default.extensions.ui_liveryEditor_tools_material,SETTINGS_TOOL=Lua_default.extensions.ui_liveryEditor_tools_settings;const useLayerSettingsStore=defineStore(`layerSettings`,()=>{let{events:events$3}=useBridge(),rootStore=useLiveryEditorStore(),active=ref(!1),targetLayer=ref({}),currentTool=ref(null),toolsData=ref(null),requestApplyActive=ref(!1),decalTexture=ref(null),isChangeDecal=ref(null),activeSettings=ref(null),editModeState=reactive({lockScaling:!1}),isStampMode=computed(()=>toolsData.value&&toolsData.value.mode===`stamp`),_reapplyActive=ref(!1),cursorData=ref(null),_appliedLayers=ref(null),activeLayerUid=ref(null),reapplyActive=computed({get:()=>_reapplyActive.value,set:async newValue=>{newValue?await Lua_default.extensions.ui_liveryEditor_editMode.requestReapply():await Lua_default.extensions.ui_liveryEditor_editMode.cancelReapply()}}),appliedLayers=computed(()=>!_appliedLayers.value||!Array.isArray(_appliedLayers.value)?null:_appliedLayers.value);events$3.on(`liveryEditor_EditMode_OnActiveStatusChanged`,async data=>{console.log(`liveryEditor_EditMode_OnActiveStatusChanged`,data),active.value=data}),events$3.on(`LiveryEditor_CursorUpdated`,async data=>{console.log(`LiveryEditor_CursorUpdated`,data),cursorData.value=data}),events$3.on(`LiveryEditor_SelectedLayersDataUpdated`,async data=>{console.log(`LiveryEditor_SelectedLayersDataUpdated`,data),data&&Array.isArray(data)&&data.length>0&&(targetLayer.value=data[0])}),events$3.on(`liveryEditor_OnSettingsChanged_UseMousePos`,data=>{console.log(`liveryEditor_OnSettingsChanged_UseMousePos`,data),cursorData.value&&(cursorData.value.isUseMousePos=data)}),events$3.on(`liveryEditor_OnEditMode_ReapplyChanged`,data=>{console.log(`liveryEditor_OnEditMode_ReapplyChanged`,data),_reapplyActive.value=data}),events$3.on(`LiveryEditorToolChanged`,data=>{console.log(`LiverEditorToolChanged`,data),currentTool.value=data}),events$3.on(`LiveryEditor_ToolDataUpdated`,async data=>{console.log(`LiveryEditor_ToolDataUpdated`,data),toolsData.value=data}),events$3.on(`liveryEditor_EditMode_OnRequestApplyChanged`,async data=>{console.log(`liveryEditor_EditMode_OnRequestApplyChanged`,data),requestApplyActive.value=data}),events$3.on(`liveryEditor_EditMode_OnAppliedLayersUpdated`,async data=>{console.log(`liveryEditor_EditMode_OnAppliedLayersUpdated`,data),_appliedLayers.value=data}),events$3.on(`liveryEditor_EditMode_OnActiveLayerChanged`,async data=>{console.log(`liveryEditor_EditMode_OnActiveLayerChanged`,data),activeLayerUid.value=data}),events$3.on(`liveryEditor_onDecalTextureChanged`,async data=>{console.log(`liveryEditor_onDecalTextureChanged`,data),console.log(`liveryEditor_onDecalTextureChanged active value`,active.value),active.value?!isChangeDecal.value&&!requestApplyActive.value&&await requestApply():await EDIT_MODE.activate(),await MATERIAL_TOOL.setDecal(data),rootStore.toggleShowDecalSelector(),isChangeDecal.value=null}),events$3.on(`liveryEditor_onDecalSelectorCancelled`,async data=>{console.log(`liveryEditor_onDecalSelectorCancelled`,data),active.value?rootStore.toggleShowDecalSelector():rootStore.toggleEditModeLayout(),isChangeDecal.value=null});function init$3(){active.value?EDIT_MODE.resetCursorProperties([]):rootStore.toggleShowDecalSelector()}let deactivate=async()=>{await Lua_default.extensions.ui_liveryEditor_editMode.deactivate(),rootStore.currentContext=EDITOR_CONTEXT.default,rootStore.editorView=EDITOR_VIEWS.default},toggleRequestApply=async()=>await Lua_default.extensions.ui_liveryEditor_editMode.toggleRequestApply(),requestApply=async()=>await Lua_default.extensions.ui_liveryEditor_editMode.requestApply(),cancelRequestApply=async()=>await Lua_default.extensions.ui_liveryEditor_editMode.cancelRequestApply(),getInitialData=async()=>await Lua_default.extensions.ui_liveryEditor_layers_cursor.requestData(),toggleStamp=async()=>{toolsData.value&&toolsData.value.mode===`stamp`?await Lua_default.extensions.ui_liveryEditor_tools_transform.cancelStamp():await Lua_default.extensions.ui_liveryEditor_tools_transform.useStamp()},setActiveLayer=async layerUid=>{await Lua_default.extensions.ui_liveryEditor_editMode.setActiveLayer(layerUid)},requestReapply=async()=>{await Lua_default.extensions.ui_liveryEditor_editMode.requestReapply()},cancelReapply=async()=>{await Lua_default.extensions.ui_liveryEditor_editMode.cancelReapply()},cancelChanges=async()=>{await Lua_default.extensions.ui_liveryEditor_editMode.cancelChanges(),await Lua_default.extensions.ui_liveryEditor_editMode.deactivate(),await Lua_default.extensions.ui_liveryEditor_tools.closeCurrentTool()},requestChangeDecal=async()=>{isChangeDecal.value=!0,rootStore.toggleShowDecalSelector()},toggleReapply=()=>reapplyActive.value=!reapplyActive.value,apply$1=async()=>await Lua_default.extensions.ui_liveryEditor_editMode.apply(),saveChanges=async params=>{await Lua_default.extensions.ui_liveryEditor_editMode.saveChanges(params),await Lua_default.extensions.ui_liveryEditor_editMode.deactivate(),rootStore.currentContext=EDITOR_CONTEXT.default,rootStore.editorView=EDITOR_VIEWS.default},closeCurrentTool=async()=>{await Lua_default.extensions.ui_liveryEditor_tools.closeCurrentTool()};return{...EDIT_MODE,...TRANSFORM_TOOL,...MATERIAL_TOOL,...SETTINGS_TOOL,...DECAL_LAYER,active,cursorData,appliedLayers,activeLayerUid,requestApplyActive,reapplyActive,decalTexture,editModeState,activeSettings,init:init$3,deactivate,getInitialData,toolsData,targetLayer,isStampMode,toggleStamp,requestReapply,cancelReapply,cancelChanges,requestApply,cancelRequestApply,toggleRequestApply,toggleReapply,setActiveLayer,saveChanges,requestChangeDecal,apply:apply$1,closeCurrentTool}}),useLayersManagerStore=defineStore(`layersManager`,()=>{let{events:events$3}=useBridge(),multipleSelection=ref(!1),_selection=ref([]),selectedLayers=computed({get(){return _selection.value},set(newValue){sendUpdatedSelection(newValue)}});events$3.on(`LiveryEditor_SelectedLayersChanged`,data=>{console.log(`selected Layer Updated`,data),_selection.value=data&&Array.isArray(data)&&data.length>0?data:[]});let sendUpdatedSelection=async selection=>{console.log(`sendUpdatedSelection`,selection),selection.length===0?await Lua_default.extensions.ui_liveryEditor_selection.clearSelection():multipleSelection.value?await Lua_default.extensions.ui_liveryEditor_selection.setMultipleSelected(selection):await Lua_default.extensions.ui_liveryEditor_selection.setSelected(selection)},canSort=data=>{let item=getItemByPath(data.targetDataset.draggablePath);return!(data.intersectionType===INTERSECTION_TYPES.sub&&item.type!==3)};async function clearSelection(){multipleSelection.value=!1,selectedLayers.value=[]}function getItemByPath(path){let pathSegments=path?path.split(`/`):void 0;if(!pathSegments)throw Error(`Path not defined`);let index=parseInt(pathSegments[0]),currentItem=layers.value[index];for(let i=1;i{Lua_default.extensions.ui_liveryEditor_tools_group.changeOrder(oldIndex+1,oldParentUid||``,newIndex+1,newParentUid||``)},clearSelection}});var FIRST_LAYER_ACTIONS=[{value:`edit`,label:`Edit`,icon:icons.edit,validator:()=>!0},{value:`order`,label:`Change Order`,icon:icons.order},{value:`rename`,label:`Rename`,icon:icons.rename},{value:`highlight`,label:`Highlight On`,icon:icons.eyeSolidOpened,toggleAction:!0,inactiveLabel:`Highlight Off`,inactiveIcon:icons.eyeSolidClosed},{value:`visibility`,label:`Enabled`,icon:icons.eyeOutlineOpened,toggleAction:!0,inactiveLabel:`Hidden`,inactiveIcon:icons.eyeOutlineClosed},{value:`delete`,label:`Delete`,icon:icons.trashBin2}],SELECTION_LUA=Lua_default.extensions.ui_liveryEditor_selection,SETTINGS_LUA=Lua_default.extensions.ui_liveryEditor_tools_settings,CAMERA_LUA=Lua_default.extensions.ui_liveryEditor_camera,EDITOR_LUA=Lua_default.extensions.ui_liveryEditor_editor;const EDITOR_CONTEXT={default:`default`,editMode:`editMode`,newLayer:`newLayer`};var SELECT_MODE={single:`single`,multi:`multi`};const EDITOR_VIEWS={default:`default`,decalSelector:`decalSelector`,editMode:`editMode`},useLiveryEditorStore=defineStore(`liveryEditor`,()=>{let{events:events$3}=useBridge(),layers$1=ref(null),visibleLayersCount=ref(null),selectedTool=ref(null),currentFile=ref(null),currentContext=ref(null),history$1=ref(null),selectMode=ref(SELECT_MODE.single),selectedLayers=ref([]),layerActions=ref(null),categories=ref(null),textures=ref(null),editorView=ref(EDITOR_VIEWS.main),cameraView=ref(null),showLayersManager=computed(()=>!(selectedTool.value&¤tContext.value===EDITOR_CONTEXT.editMode)),showLayerActions=computed(()=>selectedLayers.value),selectedLayerUids=computed(()=>selectedLayers.value?selectedLayers.value.map(x=>x.uid):void 0);events$3.on(`liveryEditor_OnLayersUpdated`,data=>{console.log(`liveryEditor_OnLayersUpdated`,data),layers$1.value=data}),events$3.on(`liveryEditor_Layers_OnVisibleCountChanged`,data=>{console.log(`liveryEditor_Layers_OnVisibleCountChanged`,data),visibleLayersCount.value=data}),events$3.on(`LiveryEditor_onSaveFileLoaded`,data=>{console.log(`LiveryEditor_onSaveFileLoaded`,data),currentFile.value=data}),events$3.on(`LiveryEditorLayersUpdate`,data=>{console.log(`LiveryEditorLayersUpdated`,data),layers$1.value=data}),events$3.on(`LiveryEditor_SelectedLayersDataUpdated`,async data=>{console.log(`LiveryEditor_SelectedLayersDataUpdated`,data),selectedLayers.value=data&&Array.isArray(data)?data:void 0}),events$3.on(`LiverEditorLayerActionsUpdated`,async data=>{console.log(`LiverEditorLayerActionsUpdated`,data)}),events$3.on(`LiveryEditor_onHistoryUpdated`,data=>{console.log(`LiveryEditor_onHistoryUpdated`,data),history$1.value=data}),events$3.on(`LiveryEditor_SelectedLayersChanged`,data=>{console.log(`selected Layer Updated`,data),currentContext.value=data&&data.length>0?EDITOR_CONTEXT.selectedLayer:null}),events$3.on(`LiveryEditorToolChanged`,data=>{console.log(`LiverEditorToolChanged`,data),selectedTool.value=data}),events$3.on(`LiveryEditor_OnCameraChanged`,data=>{console.log(`LiverEditorToolChanged`,data),cameraView.value=data});let dismissLayerActions=async()=>{await Lua_default.extensions.ui_liveryEditor_selection.clearSelection()},toggleEditModeLayout=async enable=>{enable=typeof enable==`boolean`?enable:currentContext.value===EDITOR_CONTEXT.default,enable?(currentContext.value=EDITOR_CONTEXT.editMode,editorView.value=EDITOR_VIEWS.editMode):(currentContext.value=EDITOR_CONTEXT.default,editorView.value=EDITOR_VIEWS.default)};function toggleShowDecalSelector(){editorView.value===EDITOR_VIEWS.decalSelector?editorView.value=EDITOR_VIEWS.editMode:editorView.value=EDITOR_VIEWS.decalSelector}let requestDismissLayerActions=()=>{currentContext.value===EDITOR_CONTEXT.newLayer?currentContext.value=null:currentContext.value===EDITOR_CONTEXT.selectedLayer&&(selectedLayers.value=[])},selectSingle=async layerUid=>{await Lua_default.extensions.ui_liveryEditor_selection.setSelected(layerUid)},toggleVisibility=async layer=>await Lua_default.extensions.ui_liveryEditor_tools_settings.toggleVisibilityById(layer.id),toggleLock=async layer=>await Lua_default.extensions.ui_liveryEditor_tools_settings.toggleLockById(layer.id),changeOrder=async(layer,direction$1)=>{direction$1===-1?await Lua_default.extensions.ui_liveryEditor_tools_group.moveOrderUpById(layer.uid):direction$1===1&&await Lua_default.extensions.ui_liveryEditor_tools_group.moveOrderDownById(layer.uid)},startEditor=async()=>{if(await Lua_default.extensions.ui_liveryEditor_editor.startEditor(),await Lua_default.extensions.ui_liveryEditor_editor.startSession(),currentContext.value=EDITOR_CONTEXT.default,editorView.value=EDITOR_VIEWS.default,await CAMERA_LUA.setOrthographicView(`right`),categories.value=await Lua_default.extensions.ui_liveryEditor_resources.getTextureCategories(),categories.value&&categories.value.length>0){let firstCategory=categories.value[0];setTexturesByCategory(firstCategory.value)}};async function setTexturesByCategory(category){textures.value=(await Lua_default.extensions.ui_liveryEditor_resources.getTexturesByCategory(category)).items}let createSaveFile=async filename=>{await Lua_default.extensions.ui_liveryEditor_userData.createSaveFile(filename)},useTool=async(toolName,params)=>{await Lua_default.extensions.ui_liveryEditor_tools.useTool(toolName)};async function onActionItemSelected(action){if(!action.items){let firstSelected=selectedLayers.value&&selectedLayers.value.length>0?selectedLayers.value[0]:null;if(action.value===`delete`)await openConfirmation(`Delete Layer`,`Are you sure you want to delete ${firstSelected.name}?`)&&await Lua_default.extensions.ui_liveryEditor_tools_settings.deleteLayer();else if(action.value===`rename`){let res=await openRenameLayerDialog(`Rename Layer`,``,{name:firstSelected.name},model=>model.name!==null&&model.name!==void 0&&model.name!==``&&model.name!==firstSelected.name);res.value&&await Lua_default.extensions.ui_liveryEditor_tools_settings.rename(res.formData.name)}else action.value===`duplicate`?await SELECTION_LUA.duplicateSelectedLayer():action.value===`visibility`?await SETTINGS_LUA.toggleVisibility():action.value===`highlight`?await SELECTION_LUA.toggleHighlightSelectedLayer():await Lua_default.extensions.ui_liveryEditor_tools.useTool(action.value)}}let editorState=reactive({isOpenExitDialog:!1,exitDialogResult:null,saving:!1});async function openExitDialog(){let res=await openFormDialog(ExitEditorDialog_default,ref({name:currentFile.value?currentFile.value.name:void 0,applySkin:!!(currentFile.value&¤tFile.value.name)}),form=>!form||!form.name?{error:!0,message:`Invalid Save Name`}:{error:!1},`Exit Editor`,null,[{label:`Cancel`,value:-1,extras:{cancel:!0,accent:ACCENTS.secondary}},{label:`Save and Exit`,value:1,emitData:!0,disableIfInvalid:!0,extras:{icon:icons.saveAs1}},{label:`Exit`,value:0,emitData:!0,extras:{accent:ACCENTS.attention,icon:icons.exit}}]);return res.value===-1?!1:(res.value===1&&await EDITOR_LUA.save(res.formData.name),res.formData.applySkin&&await EDITOR_LUA.applySkin(),await exit(),!0)}async function save(forceOpenPopup=!1){if(!currentFile.value||!currentFile.value.name||forceOpenPopup){editorState.isOpenExitDialog=!0;let res=await openEditFileDialog(`Save file`,`Enter name of your new save file`,{name:currentFile.value?currentFile.value.name:createFilename()},model=>model.name!==null&&model.name!==void 0&&model.name!==``);return res.value&&(editorState.saving=!0,await Lua_default.extensions.ui_liveryEditor_editor.save(res.formData.name),editorState.saving=!1),editorState.isOpenExitDialog=!1,res.value}else await Lua_default.extensions.ui_liveryEditor_editor.save(currentFile.value.name)}async function exit(){router_default.replace({name:`garagemode`}),await Lua_default.extensions.ui_liveryEditor_editor.exitEditor()}function createFilename(){let currentDate=new Date;return`${currentDate.getFullYear()}-${String(currentDate.getMonth()+1).padStart(2,`0`)}-${String(currentDate.getDate()).padStart(2,`0`)}_${String(currentDate.getHours()).padStart(2,`0`)}-${String(currentDate.getMinutes()).padStart(2,`0`)}-${String(currentDate.getSeconds()).padStart(2,`0`)}`}return{...SELECTION_LUA,...CAMERA_LUA,...SETTINGS_LUA,layers:layers$1,visibleLayersCount,layerActions,selectedTool,currentFile,currentContext,textures,categories,editorView,showLayersManager,showLayerActions,cameraView,editorState,dismissLayerActions,setTexturesByCategory,toggleEditModeLayout,toggleShowDecalSelector,requestDismissLayerActions,onActionItemSelected,selectMode,selectedLayers,selectedLayerUids,createSaveFile,toggleVisibility,toggleLock,startEditor,save,useTool,selectSingle,changeOrder,openExitDialog}}),SORT_OPTIONS=Object.freeze({name:`name`,modified:`modified`}),useLiveryFileStore=defineStore(`liveryFile`,()=>{let{events:events$3}=useBridge(),dataFiles=ref(null),sortKey=ref(SORT_OPTIONS.modified),sortDesc=ref(!0),files=computed(()=>{if(!dataFiles.value)return[];let sortOrder=sortDesc.value?-1:1;return dataFiles.value.sort((a$1,b)=>a$1[sortKey.value]b[sortKey.value]?1*sortOrder:0)}),init$3=async()=>{await Lua_default.extensions.ui_liveryEditor_userData.requestUpdatedData()},loadFile=async file$1=>await Lua_default.extensions.ui_liveryEditor_editor.loadFile(file$1.location),renameFile=async(file$1,newFilename)=>{await Lua_default.extensions.ui_liveryEditor_userData.renameFile(file$1.name,newFilename)},deleteFile=async file$1=>{await Lua_default.extensions.ui_liveryEditor_userData.deleteSaveFile(file$1.name)};events$3.on(`LiverySaveFilesUpdated`,data=>{data&&Array.isArray(data)&&data.length>0?(data.forEach(x=>{x.modifiedFormatted=formatDateTime(x.modified),x.fileSizeFormatted=formatSize(x.fileSize)}),dataFiles.value=data):dataFiles.value=[]});function formatDateTime(unixTime){let datetime=new Date(unixTime*1e3);return`${datetime.toLocaleDateString()} ${datetime.toLocaleTimeString()}`}function formatSize(bytes){return`${(bytes/1024).toFixed(2)} KB`}return{files,sortKey,sortDesc,init:init$3,loadFile,renameFile,deleteFile}});var EDITOR_RESOURCES_LUA=Lua_default.extensions.ui_liveryEditor_resources;const useDecalSelectorStore=defineStore(`liveryEditorDecalSelector`,()=>{let{events:events$3}=useBridge(),categories=ref(null),currentCategory=ref(null),isShow=ref(!1),textures=computed(()=>{if(!categories.value)return;let category=categories.value.find(x=>x.value===currentCategory.value);return category?category.items:void 0});async function init$3(){if(categories.value=await EDITOR_RESOURCES_LUA.getTextureCategories(),categories.value&&Array.isArray(categories.value)&&categories.value.length>0){let first=categories.value[0].value;await setCategory(first)}}async function setCategory(category){await fetchTextures(category),currentCategory.value=category}async function fetchTextures(category){let index=categories.value.findIndex(x=>x.value===category);if(index===-1)return;let textures$1=categories.value[index].items;if(index>=0&&(!textures$1||!textures$1.length===0)){let categoryWithTextures=await EDITOR_RESOURCES_LUA.getTexturesByCategory(category);categories.value[index].items=categoryWithTextures.items}}async function toggle(){isShow.value=!isShow.value,events$3.emit(`liveryEditor_onDecalStateChanged`,{show:isShow.value})}async function selectDecalItem(texturePath){await Lua_default.extensions.ui_liveryEditor_layerEdit.setup(),await Lua_default.extensions.ui_liveryEditor_layerEdit.editNewDecal({texturePath})}async function cancelSelection(){events$3.emit(`liveryEditor_onDecalSelectorCancelled`)}return{categories,currentCategory,textures,isShow,init:init$3,toggle,setCategory,selectDecalItem,cancelSelection}});var DEFAULT_ACCELERATION_RATE=.75,DEFAULT_ACCELERATION_NATURE=1.75,DEFAULT_ACTION_INTERVAL_MS=150,FOCUS_LD_TRIGGER_VALUE$2=-.5,FOCUS_RU_TRIGGER_VALUE$2=.5;const ACTION_PARAMS_TYPE={xyPoints:`xyPoints`,xPoint:`xPoint`},useActionHoldService=defineStore(`actionHoldService`,()=>{let data=ref({}),start=id=>{if(!data.value[id])throw Error(`Error starting hold action ${id}. Id not found.`);data.value[id].holdFn=setInterval(createHoldFn(id),data.value[id].actionInterval)},reset$1=id=>{let action=data.value[id];action&&(action.holdFn&&clearInterval(action.holdFn),data.value[id].holdFn=null,data.value[id].holdTimeMs=0)},add$2=(id,actionFn,immediateStart=!1,options={actionInterval:DEFAULT_ACTION_INTERVAL_MS,accelerationRate:DEFAULT_ACCELERATION_RATE,accelerationNature:DEFAULT_ACCELERATION_NATURE})=>{if(data.value[id])throw Error(`Error adding hold action for ${id}. Id already exists.`);data.value[id]={actionFn,...options,holdTimeMs:0,holdFn:null},immediateStart&&start(id)},remove$3=id=>{data.value[id]&&(reset$1(id),delete data.value[id])},removeAll=id=>{remove$3(id),remove$3(getFocusScalarName(id)),remove$3(getFocusScalarXName(id)),remove$3(getFocusScalarYName(id))},clear=()=>{let keys=Object.keys(data.value);for(let i=0;i{data.value[id]&&remove$3(id),add$2(id,actionFn,immediateStart,options)},onFocus=(id,actionFn,element,actionParamsType=ACTION_PARAMS_TYPE.xyPoints)=>{if(remove$3(getFocusScalarXName(id)),remove$3(getFocusScalarYName(id)),element.detail.value===0){remove$3(id);return}let eventName=element.detail.name,xDirection=0,yDirection=0;switch(eventName){case`focus_l`:xDirection=-1;break;case`focus_r`:xDirection=1;break;case`focus_d`:yDirection=-1;break;case`focus_u`:yDirection=1;break}switch(actionParamsType){case ACTION_PARAMS_TYPE.xyPoints:actionFn(xDirection,yDirection),addOrUpdate(id,multiplier=>actionFn(xDirection*multiplier,yDirection*multiplier),!0);break;case ACTION_PARAMS_TYPE.xPoint:let xValue=xDirection===0?yDirection:xDirection;xValue!==0&&(actionFn(xValue),addOrUpdate(id,multiplier=>actionFn(xValue*multiplier),!0));break}},inputNavStates=reactive({xLatestValue:0,yLatestValue:0,latestEventName:null}),onFocusScalar=(id,actionFn,element,actionParamsType=ACTION_PARAMS_TYPE.xyPoints)=>{console.log(`onFocusScalar`,{id,name:element.detail.name,value:element.detail.value}),remove$3(id);let eventName=element.detail.name,eventValue=element.detail.value;if(inputNavStates.latestEventName===eventName&&((eventName===`focus_lr`||eventName===`rotate_h_cam`)&&eventValue===inputNavStates.xLatestValue||(eventName===`focus_ud`||eventName===`rotate_v_cam`)&&eventValue===inputNavStates.yLatestValue))return;let xDirection=0,yDirection=0;if(eventName===`focus_lr`||eventName===`rotate_h_cam`){if(eventValue>FOCUS_RU_TRIGGER_VALUE$2&&eventValue>inputNavStates.xLatestValue?xDirection=1:eventValueactionFn(xDirection*multiplier,0),!0);break;case ACTION_PARAMS_TYPE.xPoint:actionFn(xDirection),addOrUpdate(getFocusScalarXName(id),multiplier=>actionFn(xDirection*multiplier),!0);break}inputNavStates.latestEventName=eventName}else remove$3(getFocusScalarXName(id));inputNavStates.xLatestValue=eventValue}else (eventName===`focus_ud`||eventName===`rotate_v_cam`)&&actionParamsType!==ACTION_PARAMS_TYPE.xPoint&&(eventValue>FOCUS_RU_TRIGGER_VALUE$2&&eventValue>inputNavStates.yLatestValue?yDirection=1:eventValueactionFn(0,yDirection*multiplier),!0),inputNavStates.latestEventName=eventName),inputNavStates.yLatestValue=eventValue)};function createHoldFn(id){let action=data.value[id];return()=>{let multiplier=1+action.accelerationRate*(action.holdTimeMs/1e3)**action.accelerationNature;action.actionFn(multiplier),data.value[id].holdTimeMs=action.holdTimeMs+action.actionInterval}}function getFocusScalarName(id){return`${id}_scalar`}function getFocusScalarXName(id){return`${getFocusScalarName(id)}_x`}function getFocusScalarYName(id){return`${getFocusScalarName(id)}_y`}return{onFocus,onFocusScalar,add:add$2,addOrUpdate,remove:remove$3,removeAll,clear,start,reset:reset$1}}),HEADER_SECTION_TYPE={start:`start`,center:`center`,end:`end`},useEditorHeaderStore=defineStore(`editorHeader`,()=>{let header=reactive({heading:null,preheading:[],type:`line`}),headerItems=ref([]),startSectionItems=computed(()=>headerItems.value.filter(x=>x.section===HEADER_SECTION_TYPE.start)),centerSectionItems=computed(()=>headerItems.value.filter(x=>x.section===HEADER_SECTION_TYPE.center)),endSectionItems=computed(()=>headerItems.value.filter(x=>x.section===HEADER_SECTION_TYPE.end)),headerHidden=ref(!1),itemsHidden=ref(!1),setHeader=(heading,headerType=`line`)=>{header.heading=heading,header.type=headerType},setPreheader=text=>{typeof text==`string`?header.preheading=[text]:header.preheading=text},addItems=(items$2,prepend=!1)=>{prepend?headerItems.value.unshift(...items$2):headerItems.value.push(...items$2)},addItem=(item,prepend=!1)=>{prepend?headerItems.value.unshift(item):headerItems.value.push(item)},addOrUpdateItem=(item,prepend=!1,prependIdOrIndex=0)=>{let existingIndex=-1;if(headerItems.value&&(existingIndex=headerItems.value.findIndex(x=>x.id===item.id)),existingIndex>-1)headerItems.value[existingIndex]={...item};else if(prepend){let preprendIdIndex=findIdOrIndex(prependIdOrIndex);headerItems.value.splice(preprendIdIndex,0,item)}else headerItems.value.push(item)},removeItem=itemOrId=>{let id=itemOrId.hasOwnProperty(`id`)?itemOrId.id:itemOrId,index=headerItems.value.findIndex(x=>x.id===id);index>-1&&headerItems.value.splice(index,1)},removeItems=itemsOrIds=>itemsOrIds.forEach(x=>removeItem(x)),removeItemsExcept=itemsOrIds=>{let ids=itemsOrIds.map(x=>x.hasOwnProperty(`id`)?x.id:x);removeItems(items.value.filter(x=>!ids.includes(x.id)))},showItem=itemOrId=>{let index=findIdOrIndex(itemOrId);index>-1&&(headerItems.value[index].hidden=!1)},hideItem=itemOrId=>{let index=findIdOrIndex(itemOrId);index>-1&&(headerItems.value[index].hidden=!0)},clearItems=()=>headerItems.value=[],getItem=id=>items.value.find(x=>x.id===id);function findIdOrIndex(idOrIndex){let prependIdIndex=headerItems.value.findIndex(x=>x.id===idOrIndex);return prependIdIndex===-1&&typeof idOrIndex==`number`&&idOrIndex>-1&&idOrIndex{let Controls=controls_default(),{events:events$3}=useBridge(),isSetupDone=ref(!1),{isControllerAvailable}=storeToRefs(Controls),currentSave=ref(initCurrentSave()),isLayerEditInitialized=ref(!1);watch(isControllerAvailable,async available=>{available&&await Lua_default.extensions.ui_liveryEditor.useMousePosition(!1)},{immediate:!0});async function onSetupDone(){isControllerAvailable.value&&await Lua_default.extensions.ui_liveryEditor.useMousePosition(!1)}function load(file$1){currentSave.value=file$1,isSetupDone.value=!1}function onChangeView(view){console.log(`onChangeView`,view),router_default.push({name:view})}async function setup$3(){isSetupDone.value||=(events$3.on(`liveryEditor_SetupSuccess`,onSetupDone),events$3.on(`liveryEditor_changeView`,onChangeView),await Lua_default.extensions.ui_liveryEditor.setup(currentSave.value.location),!0)}async function save(){await Lua_default.extensions.ui_liveryEditor.save(currentSave.value.name)}async function exit(){isSetupDone.value=!1,resetSave(),await Lua_default.extensions.ui_liveryEditor.deactivate()}async function setupLayerEdit(){isLayerEditInitialized.value||=(await Lua_default.extensions.ui_liveryEditor_camera.setOrthographicView(`right`),!0)}async function exitLayerEdit(){isLayerEditInitialized.value=!1}function resetSave(){currentSave.value=initCurrentSave()}function initCurrentSave(){return{name:createFilename(),location:null}}function dispose$2(){events$3.off(`liveryEditor_SetupSuccess`,onSetupDone)}function createFilename(){let currentDate=new Date;return`${currentDate.getFullYear()}-${String(currentDate.getMonth()+1).padStart(2,`0`)}-${String(currentDate.getDate()).padStart(2,`0`)}_${String(currentDate.getHours()).padStart(2,`0`)}-${String(currentDate.getMinutes()).padStart(2,`0`)}-${String(currentDate.getSeconds()).padStart(2,`0`)}`}return{currentSave,isSetupDone,load,setupLayerEdit,exitLayerEdit,save,exit,setup:setup$3,resetSave,dispose:dispose$2}});var _sfc_main$112=Object.assign({width:8,height:8,margin:.25},{__name:`DecalSelectorItem`,props:{externalImage:String},setup(__props){let props=__props;return(_ctx,_cache)=>(openBlock(),createBlock(unref(bngImageTile_default),normalizeProps(guardReactiveProps(props)),null,16))}}),DecalSelectorItem_default=_sfc_main$112,_hoisted_1$102={"bng-ui-scope":`liveryeditor-decal-selector`,class:`decal-selector`},_hoisted_2$86={class:`header-wrapper`},_hoisted_3$75={key:0,class:`filters-wrapper`},_sfc_main$111={__name:`DecalSelector`,setup(__props){useUINavScope(`liveryeditor-decal-selector`);let store$1=useDecalSelectorStore(),headerStore=useEditorHeaderStore(),selectedCategory=computed({get:()=>[store$1.currentCategory],async set(values){await store$1.setCategory(values[0])}}),switchCategory=direction$1=>{let index=store$1.categories.findIndex(x=>x.value===store$1.currentCategory);index!==-1&&(direction$1===-1?index>0?--index:index=store$1.categories.length-1:index{await store$1.init(),getUINavServiceInstance().useCrossfire=!0});let headerItemsHiddenValue=null;return onMounted(()=>{headerItemsHiddenValue=headerStore.itemsHidden,headerStore.itemsHidden||=!0}),onUnmounted(()=>{headerStore.itemsHidden=headerItemsHiddenValue}),(_ctx,_cache)=>withDirectives((openBlock(),createElementBlock(`div`,_hoisted_1$102,[createBaseVNode(`div`,_hoisted_2$86,[createVNode(unref(bngCardHeading_default),{class:`decal-selector-heading`,type:`ribbon`},{default:withCtx(()=>[..._cache[1]||=[createTextVNode(`Select Decal`,-1)]]),_:1}),createVNode(unref(bngButton_default),{"bng-no-nav":!0,accent:`attention`,label:`Close`,onClick:unref(store$1).cancelSelection},{default:withCtx(()=>[createVNode(unref(bngBinding_default),{action:`menu_item_back`})]),_:1},8,[`onClick`])]),unref(store$1).categories?(openBlock(),createElementBlock(`div`,_hoisted_3$75,[createBaseVNode(`div`,null,[createVNode(unref(bngIcon_default),{type:unref(icons).arrowSmallLeft},null,8,[`type`]),createVNode(unref(bngBinding_default),{action:`menu_tab_left`})]),createVNode(bngPillFilters_default,{modelValue:selectedCategory.value,"onUpdate:modelValue":_cache[0]||=$event=>selectedCategory.value=$event,"bng-no-child-nav":!0,options:unref(store$1).categories,required:``},null,8,[`modelValue`,`options`]),createBaseVNode(`div`,null,[createVNode(unref(bngBinding_default),{action:`menu_tab_right`}),createVNode(unref(bngIcon_default),{type:unref(icons).arrowSmallRight},null,8,[`type`])])])):createCommentVNode(``,!0),unref(store$1).textures&&unref(store$1).textures.length>0?(openBlock(),createBlock(unref(bngList_default),{key:1,noBackground:``},{default:withCtx(()=>[(openBlock(!0),createElementBlock(Fragment,null,renderList(unref(store$1).textures,(item,index)=>withDirectives((openBlock(),createBlock(DecalSelectorItem_default,{"bng-nav-item":``,key:item.preview,externalImage:item.preview,"data-decal-item":index,onClick:()=>unref(store$1).selectDecalItem(item.preview)},null,8,[`externalImage`,`data-decal-item`,`onClick`])),[[unref(BngOnUiNav_default),void 0,`ok`,{asMouse:!0,focusRequired:!0}]])),128))]),_:1})):createCommentVNode(``,!0)])),[[unref(BngBlur_default)],[unref(BngOnUiNav_default),()=>unref(store$1).cancelSelection(),`menu`],[unref(BngOnUiNav_default),()=>unref(store$1).cancelSelection(),`back`],[unref(BngOnUiNav_default),()=>switchCategory(-1),`tab_l`],[unref(BngOnUiNav_default),()=>switchCategory(1),`tab_r`]])}},DecalSelector_default=__plugin_vue_export_helper_default(_sfc_main$111,[[`__scopeId`,`data-v-e09a2ff1`]]),_hoisted_1$101={class:`decal-preview-tile`},_sfc_main$110={__name:`DecalPreviewTile`,props:{textureImage:{type:String,required:!0},textureColor:{type:Array,default:[255,255,255,1]},backgroundImage:String},setup(__props){useCssVars(_ctx=>({v036f09bc:alphaTextureBackground.value,v06c06c52:imgColor.value,v174dbaea:imageUrl.value}));let props=__props,alphaTextureBackground=computed(()=>`url(${props.backgroundImage?props.backgroundImage:getAssetURL(`images/alpha_texture.png`)}`),imageUrl=computed(()=>`url(${props.textureImage})`),imgColor=computed(()=>{let isDecimalFormat=props.textureColor.every(x=>x>=0&&x<=1),red=props.textureColor[0],green=props.textureColor[1],blue=props.textureColor[2],alpha=props.textureColor[3];return isDecimalFormat&&(red=Math.floor(red*255),green=Math.floor(green*255),blue=Math.floor(blue*255)),`rgba(${red}, ${green}, ${blue}, ${alpha})`});return(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$101,[..._cache[0]||=[createBaseVNode(`div`,{class:`image`},null,-1)]]))}},DecalPreviewTile_default=__plugin_vue_export_helper_default(_sfc_main$110,[[`__scopeId`,`data-v-8377c081`]]),_hoisted_1$100=[`disabled`],_sfc_main$109={__name:`EditModeLayersPreview`,props:{contextMenuName:String},setup(__props){let store$1=useLayerSettingsStore(),scroller=ref(null),tiles=ref({}),disabled=computed(()=>store$1.requestApplyActive||store$1.reapplyActive),onLayerClicked=async layer=>{store$1.activeLayerUid===layer.uid&&store$1.appliedLayers.length>1||await store$1.setActiveLayer(layer.uid)};watch(()=>store$1.activeLayerUid,layerUid=>{layerUid&&scrollTo(layerUid)});function setTileRef(layerUid,el){tiles.value[layerUid]=el}function scrollTo(layerUid){let tileEl=tiles.value[layerUid];if(!tileEl)return;let scrollerOffsetBottom=scroller.value.offsetTop+scroller.value.offsetHeight,scrollerOffsetTop=scroller.value.offsetTop+scroller.value.scrollTop,tileElOffsetBottom=tileEl.offsetTop+tileEl.offsetHeight,overflowsTop=tileEl.offsetTopscrollerOffsetBottom;!overflowsTop&&!overflowsBottom||window.requestAnimationFrame(()=>{overflowsTop?scroller.value.scrollBy({top:-(scrollerOffsetTop-tileEl.offsetTop)}):overflowsBottom&&(scroller.value.scrollTop=tileElOffsetBottom-scrollerOffsetBottom)})}return(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,{class:`layers-preview`,disabled:disabled.value},[createBaseVNode(`div`,{class:`item-navigation navigation-up`,onClick:_cache[0]||=$event=>unref(store$1).setActiveLayerDirection(-1)},[createVNode(unref(bngIcon_default),{type:unref(icons).arrowSmallUp},null,8,[`type`]),createVNode(unref(bngBinding_default),{action:`activate_previous_layer`,deviceMask:`xinput`,class:`navigation-icon`})]),createBaseVNode(`div`,{ref_key:`scroller`,ref:scroller,class:`preview-scroller`},[(openBlock(!0),createElementBlock(Fragment,null,renderList(unref(store$1).appliedLayers,layer=>(openBlock(),createElementBlock(`div`,{ref_for:!0,ref:el=>setTileRef(layer.uid,el),key:layer.uid,class:normalizeClass([{active:unref(store$1).activeLayerUid===layer.uid},`layer-item`])},[unref(store$1).activeLayerUid===layer.uid?withDirectives((openBlock(),createBlock(DecalPreviewTile_default,{key:0,class:`preview-img`,textureImage:layer.preview,textureColor:layer.color},null,8,[`textureImage`,`textureColor`])),[[unref(BngPopover_default),`context-menu`,`right`,{click:!0}]]):(openBlock(),createBlock(DecalPreviewTile_default,{key:1,class:`preview-img`,textureImage:layer.preview,textureColor:layer.color,onClick:()=>onLayerClicked(layer)},null,8,[`textureImage`,`textureColor`,`onClick`])),unref(store$1).activeLayerUid===layer.uid?(openBlock(),createBlock(unref(bngIcon_default),{key:2,class:`contextmenu-icon`,type:unref(icons).edit},null,8,[`type`])):createCommentVNode(``,!0)],2))),128))],512),createBaseVNode(`div`,{class:`item-navigation navigation-down`,onClick:_cache[1]||=$event=>unref(store$1).setActiveLayerDirection(1)},[createVNode(unref(bngBinding_default),{action:`activate_next_layer`,deviceMask:`xinput`,class:`navigation-icon`}),createVNode(unref(bngIcon_default),{type:unref(icons).arrowSmallDown},null,8,[`type`])])],8,_hoisted_1$100))}},EditModeLayersPreview_default=__plugin_vue_export_helper_default(_sfc_main$109,[[`__scopeId`,`data-v-9ede6133`]]),_hoisted_1$99={class:`material-settings`,"bng-ui-scope":`material-settings`},_hoisted_2$85={class:`subsettings-selector`},_hoisted_3$74=[`onClick`],_hoisted_4$57={class:`settings-content`},_hoisted_5$47={key:0,class:`setting-item color-setting`},_hoisted_6$34={key:1,class:`setting-item item-column`},_hoisted_7$29={class:`slider-text-container`},_hoisted_8$22={key:2,class:`setting-item item-column`},_hoisted_9$19={class:`slider-text-container`},_hoisted_10$13={key:3,class:`setting-item item-column`},_hoisted_11$11={class:`slider-text-container`},INPUT_CONTROL_STEPS$4=.01,INPUT_CONTROL_MIN$4=0,INPUT_CONTROL_MAX$4=1,CONTROLLER_SLIDER_BINDING=`focus_lr`,CONTROLLER_CHANGE_SUBSETTINGS_HINTS=[{id:`activate_previous_subsettings`,content:{type:`binding`,props:{uiEvent:`focus_u`},label:`Previous Setting`}},{id:`activate_next_subsettings`,content:{type:`binding`,props:{uiEvent:`focus_d`},label:`Next Setting`}}],subSettings=[{label:`Color`,icon:icons.colorCirclePalette,value:`color`},{label:`Saturation`,icon:icons.colorSaturation,value:`saturation`},{label:`Metalness`,icon:icons.materialMetal,value:`metallicIntensity`},{label:`Roughness`,icon:icons.materialRoughness,value:`roughnessIntensity`}],_sfc_main$108={__name:`LayerMaterialSettings`,emits:[`subSettingChanged`],setup(__props,{emit:__emit}){let emit$1=__emit,store$1=useLayerSettingsStore(),actionHoldService=useActionHoldService(),{showIfController}=storeToRefs(controls_default()),infoBar=useInfoBar(),activeSubSettingsIndex=ref(0),_color=reactive({hue:.5,saturation:1,luminosity:.5}),color=computed({get:()=>_color,set:async newValue=>{let paint=new Paint;paint.hsl=[newValue.hue,newValue.saturation,newValue.luminosity],await store$1.setColor([paint.red,paint.green,paint.blue,paint.alpha])}}),saturation=computed({get:()=>_color.saturation,set:async newValue=>{let sat=parseFloat(newValue.toFixed(2));color.value={hue:color.value.hue,saturation:sat,luminosity:color.value.luminosity},_color.saturation=sat}}),metallicIntensity=computed({get:()=>store$1.cursorData?store$1.cursorData.metallicIntensity:void 0,set:async newValue=>{await store$1.setMetallicIntensity(newValue)}}),roughnessIntensity=computed({get:()=>store$1.cursorData?store$1.cursorData.roughnessIntensity:void 0,set:async newValue=>{await store$1.setRoughnessIntensity(newValue)}}),activeSubSetting=computed(()=>subSettings[activeSubSettingsIndex.value]);watch(()=>store$1.activeLayerUid,(newValue,oldValue)=>{newValue&&oldValue&&initColorPicker(store$1.cursorData.color)},{deep:!0}),watch(activeSubSetting,(value,oldValue)=>{oldValue&&actionHoldService.remove(oldValue),setHints(),emit$1(`subSettingChanged`,value)},{immediate:!0}),onBeforeUnmount(()=>{actionHoldService.removeAll(`color`),actionHoldService.removeAll(`saturation`),actionHoldService.removeAll(`metallicIntensity`),actionHoldService.removeAll(`roughnessIntensity`),emit$1(`subSettingChanged`,void 0)}),onMounted(()=>{store$1.cursorData.color&&initColorPicker(store$1.cursorData.color)});let goPreviousSubSetting=()=>{activeSubSettingsIndex.value>0?--activeSubSettingsIndex.value:activeSubSettingsIndex.value=subSettings.length-1},goNextSubSetting=()=>{activeSubSettingsIndex.valuechangeColor(hue,luminosity,0);break;case`saturation`:actionFn=saturation$1=>changeColor(0,0,saturation$1);break;case`metallicIntensity`:actionFn=changeMetallicIntensity,actionParamsType=ACTION_PARAMS_TYPE.xPoint;break;case`roughnessIntensity`:actionFn=changeRoughnessIntensity,actionParamsType=ACTION_PARAMS_TYPE.xPoint;break}scalar?actionHoldService.onFocusScalar(subsettingValue,actionFn,element,actionParamsType):actionHoldService.onFocus(subsettingValue,actionFn,element,actionParamsType)}}async function changeColor(h$1,l,s){let newHue=color.value.hue+.01*h$1,newLuminosity=color.value.luminosity+.01*l,newSaturation=parseFloat((color.value.saturation+.1*s).toFixed(2));(newHue<0||newHue>1)&&(newHue=color.value.hue),(newLuminosity<0||newLuminosity>1)&&(newLuminosity=color.value.luminosity),(newSaturation<0||newSaturation>1)&&(newSaturation=color.value.saturation),_color.hue=newHue,_color.saturation=newSaturation,_color.luminosity=newLuminosity;let paint=new Paint;paint.hsl=[newHue,newSaturation,newLuminosity],store$1.setColor([paint.red,paint.green,paint.blue,paint.alpha])}let changeMetallicIntensity=direction$1=>{let newValue=metallicIntensity.value+.1*direction$1;newValue>=0&&newValue<=1&&(metallicIntensity.value=newValue)},changeRoughnessIntensity=direction$1=>{let newValue=roughnessIntensity.value+.1*direction$1;newValue>=0&&newValue<=1&&(roughnessIntensity.value=newValue)};function updateColorPickerModel(rgba){let paint=new Paint;paint.rgba=rgba,_color.hue=paint.hue,_color.saturation=paint.saturation,_color.luminosity=paint.luminosity}store$1.$onAction(({name,store:store$2,args,after,onError})=>{after(result=>{name===`resetCursorProperties`&&args[0].includes(`material`)&&initColorPicker(store$2.cursorData.color)})});function onReset(){let defaultColor=[1,1,1,1];switch(activeSubSetting.value.value){case`color`:store$1.setColor(defaultColor),updateColorPickerModel(defaultColor),saturation.value=1;break;case`saturation`:saturation.value=1;break;case`metallicIntensity`:metallicIntensity.value=0;break;case`roughnessIntensity`:roughnessIntensity.value=0;break}}function onTertiaryAction(){if(store$1.reapplyActive||store$1.requestApplyActive)onReset();else return!0}function initColorPicker(color$1){let isWhite=color$1.every(x=>x===1),paint=new Paint;paint.rgba=color$1,_color.hue=paint.hue,_color.saturation=isWhite?1:paint.saturation,_color.luminosity=paint.luminosity}useUINavScope(`material-settings`);let useCrossfireValue;onBeforeMount(()=>{useCrossfireValue=getUINavServiceInstance().useCrossfire,getUINavServiceInstance().useCrossfire=!1}),onBeforeUnmount(()=>{getUINavServiceInstance().useCrossfire=useCrossfireValue});let unwatchGamepad;onBeforeMount(()=>{unwatchGamepad=watch(showIfController,async()=>{await nextTick(()=>setHints())},{immediate:!0})}),onUnmounted(()=>{unwatchGamepad&&unwatchGamepad(),removeHints()});function setHints(){removeHints(),showIfController.value&&infoBar.addHints(CONTROLLER_CHANGE_SUBSETTINGS_HINTS)}function removeHints(){infoBar.removeHints(...CONTROLLER_CHANGE_SUBSETTINGS_HINTS.map(x=>x.id))}return(_ctx,_cache)=>withDirectives((openBlock(),createElementBlock(`div`,_hoisted_1$99,[createBaseVNode(`div`,_hoisted_2$85,[(openBlock(),createElementBlock(Fragment,null,renderList(subSettings,(subtab,index)=>withDirectives(createBaseVNode(`div`,{key:subtab.value,class:normalizeClass([{active:index===activeSubSettingsIndex.value},`subsettings-selector-item`]),onClick:()=>activeSubSettingsIndex.value=index},[createVNode(unref(bngIcon_default),{type:subtab.icon,class:`selector-item-icon`},null,8,[`type`])],10,_hoisted_3$74),[[unref(BngTooltip_default),index===activeSubSettingsIndex.value?void 0:subtab.label,`left`]])),64))]),createBaseVNode(`div`,_hoisted_4$57,[activeSubSetting.value.value===`color`?(openBlock(),createElementBlock(`div`,_hoisted_5$47,[createVNode(unref(bngColorPicker_default),{modelValue:color.value,"onUpdate:modelValue":_cache[0]||=$event=>color.value=$event,view:`luminosity`},null,8,[`modelValue`])])):createCommentVNode(``,!0),activeSubSetting.value.value===`saturation`?(openBlock(),createElementBlock(`div`,_hoisted_6$34,[createBaseVNode(`div`,_hoisted_7$29,[createVNode(unref(bngSlider_default),{modelValue:saturation.value,"onUpdate:modelValue":_cache[1]||=$event=>saturation.value=$event,min:INPUT_CONTROL_MIN$4,max:INPUT_CONTROL_MAX$4,step:INPUT_CONTROL_STEPS$4},null,8,[`modelValue`]),createVNode(unref(bngInput_default),{modelValue:saturation.value,"onUpdate:modelValue":_cache[2]||=$event=>saturation.value=$event,type:`number`,min:INPUT_CONTROL_MIN$4,max:INPUT_CONTROL_MAX$4,step:INPUT_CONTROL_STEPS$4},null,8,[`modelValue`]),createVNode(unref(bngBinding_default),{uiEvent:CONTROLLER_SLIDER_BINDING,deviceMask:`xinput`})])])):activeSubSetting.value.value===`metallicIntensity`?(openBlock(),createElementBlock(`div`,_hoisted_8$22,[createBaseVNode(`div`,_hoisted_9$19,[createVNode(unref(bngSlider_default),{modelValue:metallicIntensity.value,"onUpdate:modelValue":_cache[3]||=$event=>metallicIntensity.value=$event,min:INPUT_CONTROL_MIN$4,max:INPUT_CONTROL_MAX$4,step:INPUT_CONTROL_STEPS$4},null,8,[`modelValue`]),createVNode(unref(bngInput_default),{modelValue:metallicIntensity.value,"onUpdate:modelValue":_cache[4]||=$event=>metallicIntensity.value=$event,type:`number`,min:INPUT_CONTROL_MIN$4,max:INPUT_CONTROL_MAX$4,step:INPUT_CONTROL_STEPS$4},null,8,[`modelValue`]),createVNode(unref(bngBinding_default),{uiEvent:CONTROLLER_SLIDER_BINDING,deviceMask:`xinput`})])])):activeSubSetting.value.value===`roughnessIntensity`?(openBlock(),createElementBlock(`div`,_hoisted_10$13,[createBaseVNode(`div`,_hoisted_11$11,[createVNode(unref(bngSlider_default),{modelValue:roughnessIntensity.value,"onUpdate:modelValue":_cache[5]||=$event=>roughnessIntensity.value=$event,min:INPUT_CONTROL_MIN$4,max:INPUT_CONTROL_MAX$4,step:INPUT_CONTROL_STEPS$4},null,8,[`modelValue`]),createVNode(unref(bngInput_default),{modelValue:roughnessIntensity.value,"onUpdate:modelValue":_cache[6]||=$event=>roughnessIntensity.value=$event,type:`number`,min:INPUT_CONTROL_MIN$4,max:INPUT_CONTROL_MAX$4,step:INPUT_CONTROL_STEPS$4},null,8,[`modelValue`]),createVNode(unref(bngBinding_default),{uiEvent:CONTROLLER_SLIDER_BINDING,deviceMask:`xinput`})])])):createCommentVNode(``,!0)])])),[[unref(BngOnUiNav_default),goNextSubSetting,`action_2`],[unref(BngOnUiNav_default),onTertiaryAction,`action_3`],[unref(BngOnUiNav_default),onFocus,`focus_l`,{up:!0}],[unref(BngOnUiNav_default),onFocus,`focus_l`,{down:!0}],[unref(BngOnUiNav_default),onFocus,`focus_r`,{down:!0}],[unref(BngOnUiNav_default),onFocus,`focus_r`,{up:!0}],[unref(BngOnUiNav_default),onFocus,`focus_u`,{up:!0}],[unref(BngOnUiNav_default),onFocus,`focus_u`,{down:!0}],[unref(BngOnUiNav_default),onFocus,`focus_d`,{down:!0}],[unref(BngOnUiNav_default),onFocus,`focus_d`,{up:!0}],[unref(BngOnUiNav_default),el=>onFocus(el,!0),`focus_lr`],[unref(BngOnUiNav_default),el=>onFocus(el,!0),`focus_ud`]])}},LayerMaterialSettings_default=__plugin_vue_export_helper_default(_sfc_main$108,[[`__scopeId`,`data-v-ffe74e63`]]),_hoisted_1$98={class:`mirror-settings`,"bng-ui-scope":`mirror-settings`},_hoisted_2$84={class:`setting-item`},_hoisted_3$73={class:`setting-item offset-item`},_hoisted_4$56={class:`setting-item offset-item`},FOCUS_LD_TRIGGER_VALUE$1=-.999,FOCUS_RU_TRIGGER_VALUE$1=.999,FOCUS_HOLD_INTERVAL_MS=250,MIRROR_BINDING=`focus_l`,FLIP_BINDING=`focus_r`,CONTROLLER_OFFSET_BINDING=`focus_ud`,CONTROLLER_HINTS$4=[],KEYBOARD_HINTS$4=[],_sfc_main$107={__name:`LayerMirrorSettings`,setup(__props){let store$1=useLayerSettingsStore(),{showIfController}=storeToRefs(controls_default()),infoBar=useInfoBar(),inputNavStates=reactive({focusXLatestValue:0,focusYLatestValue:0,holdEventLatest:null,holdInterval:null}),mirror=computed({get:()=>store$1.cursorData?store$1.cursorData.mirrored:void 0,set:async newValue=>await store$1.setMirrored(newValue,store$1.cursorData.flipMirroredDecal)}),flip$2=computed({get:()=>store$1.cursorData?store$1.cursorData.flipMirroredDecal:void 0,set:async newValue=>await store$1.setMirrored(store$1.cursorData.mirrored,newValue)}),offset$2=computed({get:()=>store$1.cursorData?store$1.cursorData.mirrorOffset:void 0,set:async newValue=>await store$1.setMirrorOffset(newValue)}),toggleMirror=()=>mirror.value=!mirror.value,toggleFlipped=()=>{mirror.value&&(flip$2.value=!flip$2.value)},changeOffset=element=>{if(!mirror.value)return;let eventName=element.detail.name,direction$1=eventName===`focus_d`?-1:1,isPressed=element.detail.value;inputNavStates.holdEventLatest===eventName&&!isPressed&&inputNavStates.holdInterval&&(clearInterval(inputNavStates.holdInterval),inputNavStates.holdInterval=null),direction$1>0&&isPressed?doHoldAction(()=>store$1.setMirrorOffset(offset$2.value+1),eventName):direction$1<0&&isPressed&&doHoldAction(()=>store$1.setMirrorOffset(offset$2.value-1),eventName)},changeOffsetScalar=element=>{if(!mirror.value)return;let eventName=element.detail.name,direction$1=element.detail.value;inputNavStates.holdEventLatest===eventName&&inputNavStates.holdInterval&&clearInterval(inputNavStates.holdInterval),direction$1>FOCUS_RU_TRIGGER_VALUE$1&&direction$1>inputNavStates.focusXLatestValue?doHoldAction(()=>store$1.setMirrorOffset(offset$2.value+1),eventName):direction$1store$1.setMirrorOffset(offset$2.value-1),eventName),inputNavStates.focusXLatestValue=direction$1};function onReset(){store$1.setMirrored(!1,!1),store$1.setMirrorOffset(0)}function onTertiaryAction(){if(store$1.reapplyActive||store$1.requestApplyActive)onReset();else return!0}function doHoldAction(callbackFn,eventName){inputNavStates.holdInterval&&=(clearInterval(inputNavStates.holdInterval),null),callbackFn(),inputNavStates.holdInterval=setInterval(callbackFn,FOCUS_HOLD_INTERVAL_MS),inputNavStates.holdEventLatest=eventName}useUINavScope(`mirror-settings`);let useCrossfireValue;onBeforeMount(()=>{useCrossfireValue=getUINavServiceInstance().useCrossfire,getUINavServiceInstance().useCrossfire=!1}),onBeforeUnmount(()=>{getUINavServiceInstance().useCrossfire=useCrossfireValue});let unwatchGamepad;onBeforeMount(()=>{unwatchGamepad=watch(showIfController,async()=>{await nextTick(()=>setHints())},{immediate:!0})}),onUnmounted(()=>{unwatchGamepad&&unwatchGamepad(),removeHints()});function setHints(){let hints;removeHints(),hints=showIfController.value?CONTROLLER_HINTS$4:KEYBOARD_HINTS$4;for(let i=hints.length-1;i>=0;i--)infoBar.addHints(hints[i],0,!0)}function removeHints(){infoBar.removeHints(...KEYBOARD_HINTS$4.map(x=>x.id)),infoBar.removeHints(...CONTROLLER_HINTS$4.map(x=>x.id))}return(_ctx,_cache)=>withDirectives((openBlock(),createElementBlock(`div`,_hoisted_1$98,[createBaseVNode(`div`,_hoisted_2$84,[createVNode(unref(bngSwitch_default),{modelValue:mirror.value,"onUpdate:modelValue":_cache[0]||=$event=>mirror.value=$event},{default:withCtx(()=>[..._cache[3]||=[createTextVNode(`Mirror`,-1)]]),_:1},8,[`modelValue`]),createVNode(unref(bngBinding_default),{uiEvent:MIRROR_BINDING,deviceMask:`xinput`})]),createBaseVNode(`div`,_hoisted_3$73,[createVNode(unref(bngSwitch_default),{modelValue:flip$2.value,"onUpdate:modelValue":_cache[1]||=$event=>flip$2.value=$event,disabled:!mirror.value},{default:withCtx(()=>[..._cache[4]||=[createTextVNode(`Flip`,-1)]]),_:1},8,[`modelValue`,`disabled`]),createVNode(unref(bngBinding_default),{uiEvent:FLIP_BINDING,deviceMask:`xinput`,class:normalizeClass({disabled:!mirror.value})},null,8,[`class`])]),createBaseVNode(`div`,_hoisted_4$56,[createVNode(unref(bngInput_default),{modelValue:offset$2.value,"onUpdate:modelValue":_cache[2]||=$event=>offset$2.value=$event,step:.1,disabled:!mirror.value,type:`number`,prefix:`Offset`,class:`setting-input`},null,8,[`modelValue`,`disabled`]),createVNode(unref(bngBinding_default),{uiEvent:CONTROLLER_OFFSET_BINDING,deviceMask:`xinput`,class:normalizeClass({disabled:!mirror.value})},null,8,[`class`])])])),[[unref(BngOnUiNav_default),onTertiaryAction,`action_3`],[unref(BngOnUiNav_default),toggleMirror,`focus_l`],[unref(BngOnUiNav_default),toggleFlipped,`focus_r`],[unref(BngOnUiNav_default),changeOffset,`focus_u`,{up:!0}],[unref(BngOnUiNav_default),changeOffset,`focus_u`,{down:!0}],[unref(BngOnUiNav_default),changeOffset,`focus_d`,{up:!0}],[unref(BngOnUiNav_default),changeOffset,`focus_d`,{down:!0}],[unref(BngOnUiNav_default),changeOffsetScalar,`focus_ud`]])}},LayerMirrorSettings_default=__plugin_vue_export_helper_default(_sfc_main$107,[[`__scopeId`,`data-v-5ae7bab5`]]),_hoisted_1$97={"bng-ui-scope":`rotate-settings`},_hoisted_2$83={class:`setting-item item-column`},_hoisted_3$72={class:`slider-text-container`},INPUT_CONTROL_STEPS$3=.1,INPUT_CONTROL_MIN$3=0,INPUT_CONTROL_MAX$3=359.9,INPUT_DEFAULT_VALUE$3=0,CONTROLLER_ROTATE_BINDING=`focus_lr`,CONTROLLER_HINTS$3=[],KEYBOARD_HINTS$3=[],_sfc_main$106={__name:`LayerRotateSettings`,setup(__props){let store$1=useLayerSettingsStore(),actionHoldService=useActionHoldService(),{showIfController}=storeToRefs(controls_default()),infoBar=useInfoBar(),rotation=computed({get:()=>store$1.cursorData?parseFloat(store$1.cursorData.rotation.toFixed(1)):void 0,set:async newValue=>{await store$1.setRotation(newValue)}});function onReset(){rotation.value=INPUT_DEFAULT_VALUE$3}function onTertiaryAction(){if(store$1.reapplyActive||store$1.requestApplyActive)onReset();else return!0}useUINavScope(`rotate-settings`);let useCrossfireValue;onBeforeMount(()=>{useCrossfireValue=getUINavServiceInstance().useCrossfire,getUINavServiceInstance().useCrossfire=!1}),onBeforeUnmount(()=>{getUINavServiceInstance().useCrossfire=useCrossfireValue});let unwatchGamepad;onBeforeMount(()=>{unwatchGamepad=watch(showIfController,async()=>{await nextTick(()=>setHints())},{immediate:!0})}),onUnmounted(()=>{actionHoldService.removeAll(`rotate`),unwatchGamepad&&unwatchGamepad(),removeHints()});function setHints(){let hints=showIfController.value?CONTROLLER_HINTS$3:KEYBOARD_HINTS$3;removeHints();for(let i=hints.length-1;i>=0;i--)infoBar.addHints(hints[i],0,!0)}function removeHints(){infoBar.removeHints(...KEYBOARD_HINTS$3.map(x=>x.id)),infoBar.removeHints(...CONTROLLER_HINTS$3.map(x=>x.id))}return(_ctx,_cache)=>withDirectives((openBlock(),createElementBlock(`div`,_hoisted_1$97,[createBaseVNode(`div`,_hoisted_2$83,[createBaseVNode(`div`,_hoisted_3$72,[createVNode(unref(bngInput_default),{modelValue:rotation.value,"onUpdate:modelValue":_cache[0]||=$event=>rotation.value=$event,min:INPUT_CONTROL_MIN$3,max:INPUT_CONTROL_MAX$3,step:INPUT_CONTROL_STEPS$3,type:`number`,prefix:`X`,class:`slider-text-textinput`},null,8,[`modelValue`]),createVNode(unref(bngSlider_default),{modelValue:rotation.value,"onUpdate:modelValue":_cache[1]||=$event=>rotation.value=$event,min:INPUT_CONTROL_MIN$3,max:INPUT_CONTROL_MAX$3,step:INPUT_CONTROL_STEPS$3,class:`slider-text-sliderinput`},null,8,[`modelValue`]),createVNode(unref(bngBinding_default),{uiEvent:CONTROLLER_ROTATE_BINDING,deviceMask:`xinput`})])])])),[[unref(BngOnUiNav_default),onTertiaryAction,`action_3`],[unref(BngOnUiNav_default),element=>unref(actionHoldService).onFocus(`rotate`,unref(store$1).rotate,element,unref(ACTION_PARAMS_TYPE).xPoint),`focus_l`,{up:!0}],[unref(BngOnUiNav_default),element=>unref(actionHoldService).onFocus(`rotate`,unref(store$1).rotate,element,unref(ACTION_PARAMS_TYPE).xPoint),`focus_l`,{down:!0}],[unref(BngOnUiNav_default),element=>unref(actionHoldService).onFocus(`rotate`,unref(store$1).rotate,element,unref(ACTION_PARAMS_TYPE).xPoint),`focus_r`,{down:!0}],[unref(BngOnUiNav_default),element=>unref(actionHoldService).onFocus(`rotate`,unref(store$1).rotate,element,unref(ACTION_PARAMS_TYPE).xPoint),`focus_r`,{up:!0}],[unref(BngOnUiNav_default),element=>unref(actionHoldService).onFocus(`rotate`,unref(store$1).rotate,element,unref(ACTION_PARAMS_TYPE).xPoint),`focus_u`,{up:!0}],[unref(BngOnUiNav_default),element=>unref(actionHoldService).onFocus(`rotate`,unref(store$1).rotate,element,unref(ACTION_PARAMS_TYPE).xPoint),`focus_u`,{down:!0}],[unref(BngOnUiNav_default),element=>unref(actionHoldService).onFocus(`rotate`,unref(store$1).rotate,element,unref(ACTION_PARAMS_TYPE).xPoint),`focus_d`,{down:!0}],[unref(BngOnUiNav_default),element=>unref(actionHoldService).onFocus(`rotate`,unref(store$1).rotate,element,unref(ACTION_PARAMS_TYPE).xPoint),`focus_d`,{up:!0}],[unref(BngOnUiNav_default),element=>unref(actionHoldService).onFocusScalar(`rotate`,unref(store$1).rotate,element,unref(ACTION_PARAMS_TYPE).xPoint),`focus_lr`],[unref(BngOnUiNav_default),element=>unref(actionHoldService).onFocusScalar(`rotate`,unref(store$1).rotate,element,unref(ACTION_PARAMS_TYPE).xPoint),`focus_ud`]])}},LayerRotateSettings_default=__plugin_vue_export_helper_default(_sfc_main$106,[[`__scopeId`,`data-v-d8deaac6`]]),_sfc_main$105={__name:`BindingButton`,props:{uiEvent:String,deviceMask:String,action:String,label:String,showBinding:{type:Boolean,default:!0}},setup(__props){return(_ctx,_cache)=>(openBlock(),createBlock(unref(bngButton_default),{label:void 0},{default:withCtx(()=>[createBaseVNode(`span`,null,toDisplayString(__props.label),1),__props.showBinding?(openBlock(),createBlock(unref(bngBinding_default),{key:0,uiEvent:__props.uiEvent,deviceMask:__props.deviceMask,class:`button-binding`},null,8,[`uiEvent`,`deviceMask`])):createCommentVNode(``,!0)]),_:1}))}},BindingButton_default=__plugin_vue_export_helper_default(_sfc_main$105,[[`__scopeId`,`data-v-e77d3865`]]),_hoisted_1$96={class:`camera-popovermenu`},CONTROLLER_CAMERA_BINDING=`rotate_h_cam`,CAMERA_BUTTONS$2=[{label:`Right`,icon:icons.cameraSideRight,value:`right`},{label:`Front`,icon:icons.cameraFront1,value:`front`},{label:`Left`,icon:icons.cameraSideLeft,value:`left`},{label:`Back`,icon:icons.cameraBack1,value:`back`},{label:`Top Right`,icon:icons.cameraTop1,value:`topright`},{label:`Top Left`,icon:icons.cameraTop1,value:`topleft`},{label:`Top Front`,icon:icons.cameraTop1,value:`topfront`},{label:`Top Back`,icon:icons.cameraTop1,value:`topback`}],_sfc_main$104={__name:`CameraViewButton`,setup(__props){let store$1=useLiveryEditorStore(),popover=usePopover(),expand=ref(!1),currentCamera=computed(()=>{if(store$1.cameraView){let curr=CAMERA_BUTTONS$2.find(x=>x.value===store$1.cameraView);if(curr)return curr}return{icon:icons.movieCamera,label:`View`}}),onCameraViewClicked=view=>{popover.hide(`camera-popovermenu`),store$1.setOrthographicView(view)};return(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,null,[withDirectives((openBlock(),createBlock(unref(bngButton_default),{icon:currentCamera.value.icon,accent:unref(ACCENTS).secondary},{default:withCtx(()=>[createBaseVNode(`span`,null,toDisplayString(currentCamera.value.label),1),createVNode(unref(bngBinding_default),{uiEvent:CONTROLLER_CAMERA_BINDING,deviceMask:`xinput`})]),_:1},8,[`icon`,`accent`])),[[unref(BngPopover_default),`camera-popovermenu`,`bottom`,{click:!0}]]),createVNode(unref(bngPopoverContent_default),{name:`camera-popovermenu`,onShow:_cache[0]||=$event=>expand.value=!0,onHide:_cache[1]||=$event=>expand.value=!1},{default:withCtx(()=>[createBaseVNode(`div`,_hoisted_1$96,[(openBlock(),createElementBlock(Fragment,null,renderList(CAMERA_BUTTONS$2,cameraItem=>createVNode(unref(bngImageTile_default),{key:cameraItem.value,label:cameraItem.label,icon:cameraItem.icon,class:normalizeClass({active:cameraItem.value===currentCamera.value.value}),onClick:$event=>onCameraViewClicked(cameraItem.value)},null,8,[`label`,`icon`,`class`,`onClick`])),64))])]),_:1})]))}},CameraViewButton_default=__plugin_vue_export_helper_default(_sfc_main$104,[[`__scopeId`,`data-v-be949a44`]]),_hoisted_1$95={key:0,class:`liveryeditor-header`},_hoisted_2$82={key:0,class:`header-items`},_sfc_main$103={__name:`LiveryEditorHeader`,setup(__props){let store$1=useEditorHeaderStore(),{startSectionItems,centerSectionItems,endSectionItems}=storeToRefs(store$1),sections=ref({start:startSectionItems,center:centerSectionItems,end:endSectionItems});return(_ctx,_cache)=>unref(store$1).headerHidden?createCommentVNode(``,!0):(openBlock(),createElementBlock(`div`,_hoisted_1$95,[createVNode(unref(bngScreenHeading_default),{type:unref(store$1).header.type,preheadings:unref(store$1).header.preheading},{default:withCtx(()=>[createTextVNode(toDisplayString(unref(store$1).header.heading),1)]),_:1},8,[`type`,`preheadings`]),unref(store$1).itemsHidden?createCommentVNode(``,!0):(openBlock(),createElementBlock(`div`,_hoisted_2$82,[(openBlock(!0),createElementBlock(Fragment,null,renderList(sections.value,(items$2,section)=>(openBlock(),createElementBlock(`div`,{class:normalizeClass([[`section-${section}`],`header-section`])},[(openBlock(!0),createElementBlock(Fragment,null,renderList(items$2,item=>(openBlock(),createElementBlock(`div`,{key:item.id},[withDirectives((openBlock(),createBlock(resolveDynamicComponent(item.component),mergeProps({ref_for:!0},item.props,toHandlers(item.events)),null,16)),[[vShow,!item.hidden]])]))),128))],2))),256))]))]))}},LiveryEditorHeader_default=__plugin_vue_export_helper_default(_sfc_main$103,[[`__scopeId`,`data-v-b0fff070`]]),_hoisted_1$94={class:`transform-settings`,"bng-ui-scope":`transform-settings`},_hoisted_2$81={class:`setting-item item-column`},_hoisted_3$71={class:`slider-text-container`},_hoisted_4$55={class:`setting-item item-column`},_hoisted_5$46={class:`slider-text-container`},_hoisted_6$33={key:0,class:`setting-item`},_hoisted_7$28={class:`setting-item actions-container`},INPUT_CONTROL_STEPS$2=.001,INPUT_CONTROL_MIN$2=0,INPUT_CONTROL_MAX$2=1,INPUT_DEFAULT_VALUE$2=.5,APPLIED_CONTROLLER_HINTS=[],CONTROLLER_MOVE_Y_BINDING=`focus_ud`,CONTROLLER_MOVE_X_BINDING=`focus_lr`,CONTROLLER_SURFACE_NORMAL_BINDING=`action_2`,CONTROLLER_APPLY_BINDING=`ok`,CONTROLLER_CANCEL_REAPPLY_BINDING=`back`,CONTROLLER_HINTS$2=[],KEYBOARD_HINTS$2=[],MOUSE_HINTS=[{id:`stamp_decal`,content:{type:`binding`,props:{action:`stamp_decal`},label:`Apply`}}],_sfc_main$102={__name:`LayerTransformSettingsOld`,setup(__props){let store$1=useLayerSettingsStore(),{showIfController}=storeToRefs(controls_default()),infoBar=useInfoBar(),actionHoldService=useActionHoldService(),positionX=computed({get:()=>store$1.cursorData&&store$1.cursorData.position?store$1.cursorData.position.x:void 0,set:async newValue=>await store$1.setPosition(newValue,store$1.cursorData.position.y)}),positionY=computed({get:()=>store$1.cursorData&&store$1.cursorData.position?store$1.cursorData.position.y:void 0,set:async newValue=>await store$1.setPosition(store$1.cursorData.position.x,newValue)}),positionMaxX=computed(()=>store$1.cursorData&&store$1.cursorData.position?store$1.cursorData.position.maxX:INPUT_CONTROL_MAX$2),positionMaxY=computed(()=>store$1.cursorData&&store$1.cursorData.position?store$1.cursorData.position.maxY:INPUT_CONTROL_MAX$2),surfaceNormal=computed({get:()=>store$1.cursorData?store$1.cursorData.isProjectSurfaceNormal:void 0,set:async newValue=>await store$1.setProjectSurfaceNormal(newValue)}),mouseMode=computed(()=>store$1.cursorData?store$1.cursorData.isUseMousePos:void 0),applied=computed(()=>store$1.cursorData?store$1.cursorData.applied:void 0);computed(()=>store$1.active);let isShowControls=computed(()=>!store$1.cursorData.applied&&!mouseMode.value),toggleUseSurfaceNormal=()=>{if(console.log(`toggleUseSurfaceNormal`),!store$1.cursorData.applied)surfaceNormal.value=!surfaceNormal.value;else return console.log(`toggleUseSurfaceNormal returning true`),!0};function cancelApply(){store$1.requestApplyActive?store$1.cancelRequestApply():store$1.reapplyActive&&store$1.cancelReapply()}function onReset(){store$1.setPosition(INPUT_DEFAULT_VALUE$2,INPUT_DEFAULT_VALUE$2)}function onOk(){if(!store$1.requestApplyActive&&!store$1.reapplyActive)store$1.toggleReapply();else return!0}function onTertiaryAction(){if(store$1.reapplyActive||store$1.requestApplyActive)onReset();else return!0}useUINavScope(`transform-settings`);let useCrossfireValue;onBeforeMount(()=>{useCrossfireValue=getUINavServiceInstance().useCrossfire,getUINavServiceInstance().useCrossfire=!1}),onBeforeUnmount(()=>{getUINavServiceInstance().useCrossfire=useCrossfireValue}),watch(mouseMode,async()=>{await nextTick(()=>setHints())}),watch(applied,async()=>{await nextTick(()=>setHints())});function setHints(){let hints;removeHints(),hints=applied.value?showIfController.value?APPLIED_CONTROLLER_HINTS:KEYBOARD_HINTS$2:mouseMode.value?MOUSE_HINTS:showIfController.value?CONTROLLER_HINTS$2:KEYBOARD_HINTS$2;for(let i=hints.length-1;i>=0;i--)infoBar.addHints(hints[i],0,!0)}let unwatchGamepad;onBeforeMount(()=>{unwatchGamepad=watch(showIfController,async()=>{await nextTick(()=>{setHints()})},{immediate:!0})}),onUnmounted(()=>{actionHoldService.removeAll(`transform`),unwatchGamepad&&unwatchGamepad(),removeHints()});function removeHints(){infoBar.removeHints(...KEYBOARD_HINTS$2.map(x=>x.id)),infoBar.removeHints(...CONTROLLER_HINTS$2.map(x=>x.id)),infoBar.removeHints(...APPLIED_CONTROLLER_HINTS.map(x=>x.id)),infoBar.removeHints(...MOUSE_HINTS.map(x=>x.id))}return(_ctx,_cache)=>withDirectives((openBlock(),createElementBlock(`div`,_hoisted_1$94,[createBaseVNode(`div`,_hoisted_2$81,[withDirectives(createBaseVNode(`div`,_hoisted_3$71,[createVNode(unref(bngInput_default),{modelValue:positionX.value,"onUpdate:modelValue":_cache[0]||=$event=>positionX.value=$event,min:INPUT_CONTROL_MIN$2,max:positionMaxX.value,step:INPUT_CONTROL_STEPS$2,type:`number`,prefix:`X`,class:`slider-text-textinput`},null,8,[`modelValue`,`max`]),createVNode(unref(bngSlider_default),{modelValue:positionX.value,"onUpdate:modelValue":_cache[1]||=$event=>positionX.value=$event,min:INPUT_CONTROL_MIN$2,max:positionMaxX.value,step:INPUT_CONTROL_STEPS$2,class:`slider-text-sliderinput`},null,8,[`modelValue`,`max`]),createVNode(unref(bngBinding_default),{uiEvent:CONTROLLER_MOVE_X_BINDING,deviceMask:`xinput`})],512),[[vShow,isShowControls.value]])]),withDirectives(createBaseVNode(`div`,_hoisted_4$55,[createBaseVNode(`div`,_hoisted_5$46,[createVNode(unref(bngInput_default),{modelValue:positionY.value,"onUpdate:modelValue":_cache[2]||=$event=>positionY.value=$event,type:`number`,prefix:`Y`,min:INPUT_CONTROL_MIN$2,max:positionMaxY.value,step:INPUT_CONTROL_STEPS$2,class:`slider-text-textinput`},null,8,[`modelValue`,`max`]),createVNode(unref(bngSlider_default),{modelValue:positionY.value,"onUpdate:modelValue":_cache[3]||=$event=>positionY.value=$event,min:INPUT_CONTROL_MIN$2,max:positionMaxY.value,step:INPUT_CONTROL_STEPS$2,class:`slider-text-sliderinput`},null,8,[`modelValue`,`max`]),createVNode(unref(bngBinding_default),{uiEvent:CONTROLLER_MOVE_Y_BINDING,deviceMask:`xinput`})])],512),[[vShow,isShowControls.value]]),unref(store$1).cursorData.applied?createCommentVNode(``,!0):(openBlock(),createElementBlock(`div`,_hoisted_6$33,[createVNode(unref(bngSwitch_default),{modelValue:surfaceNormal.value,"onUpdate:modelValue":_cache[4]||=$event=>surfaceNormal.value=$event,disabled:!(unref(store$1).reapplyActive||!applied.value)},{default:withCtx(()=>[..._cache[5]||=[createTextVNode(`Use Surface Normal`,-1)]]),_:1},8,[`modelValue`,`disabled`]),createVNode(unref(bngBinding_default),{uiEvent:CONTROLLER_SURFACE_NORMAL_BINDING,deviceMask:`xinput`})])),createBaseVNode(`div`,_hoisted_7$28,[unref(store$1).requestApplyActive||unref(store$1).reapplyActive?(openBlock(),createElementBlock(Fragment,{key:0},[unref(store$1).appliedLayers&&unref(store$1).appliedLayers.length>0?(openBlock(),createBlock(unref(BindingButton_default),{key:0,icon:unref(store$1).reapplyActive?unref(icons).undo:``,uiEvent:CONTROLLER_CANCEL_REAPPLY_BINDING,label:unref(store$1).reapplyActive?`Undo`:`Cancel`,accent:`attention`,onClick:cancelApply},null,8,[`icon`,`label`])):createCommentVNode(``,!0),mouseMode.value?createCommentVNode(``,!0):(openBlock(),createBlock(unref(BindingButton_default),{key:1,uiEvent:CONTROLLER_APPLY_BINDING,label:`Apply`,accent:`primary`,onClick:unref(store$1).apply},null,8,[`onClick`]))],64)):(openBlock(),createBlock(unref(BindingButton_default),{key:1,uiEvent:CONTROLLER_APPLY_BINDING,label:`Reapply`,onClick:unref(store$1).requestReapply},null,8,[`onClick`]))])])),[[unref(BngOnUiNav_default),onOk,`ok`],[unref(BngOnUiNav_default),toggleUseSurfaceNormal,`action_2`],[unref(BngOnUiNav_default),onTertiaryAction,`action_3`],[unref(BngOnUiNav_default),element=>unref(actionHoldService).onFocus(`transform`,unref(store$1).translate,element),`focus_l`,{up:!0}],[unref(BngOnUiNav_default),element=>unref(actionHoldService).onFocus(`transform`,unref(store$1).translate,element),`focus_l`,{down:!0}],[unref(BngOnUiNav_default),element=>unref(actionHoldService).onFocus(`transform`,unref(store$1).translate,element),`focus_r`,{down:!0}],[unref(BngOnUiNav_default),element=>unref(actionHoldService).onFocus(`transform`,unref(store$1).translate,element),`focus_r`,{up:!0}],[unref(BngOnUiNav_default),element=>unref(actionHoldService).onFocus(`transform`,unref(store$1).translate,element),`focus_u`,{up:!0}],[unref(BngOnUiNav_default),element=>unref(actionHoldService).onFocus(`transform`,unref(store$1).translate,element),`focus_u`,{down:!0}],[unref(BngOnUiNav_default),element=>unref(actionHoldService).onFocus(`transform`,unref(store$1).translate,element),`focus_d`,{down:!0}],[unref(BngOnUiNav_default),element=>unref(actionHoldService).onFocus(`transform`,unref(store$1).translate,element),`focus_d`,{up:!0}],[unref(BngOnUiNav_default),element=>unref(actionHoldService).onFocusScalar(`transform`,unref(store$1).translate,element),`focus_lr`],[unref(BngOnUiNav_default),element=>unref(actionHoldService).onFocusScalar(`transform`,unref(store$1).translate,element),`focus_ud`]])}},LayerTransformSettingsOld_default=__plugin_vue_export_helper_default(_sfc_main$102,[[`__scopeId`,`data-v-79d0fe46`]]),_hoisted_1$93={class:`scale-settings`,"bng-ui-scope":`scale-settings`},_hoisted_2$80={class:`setting-item item-column`},_hoisted_3$70={class:`slider-text-container`},_hoisted_4$54={class:`setting-item item-column`},_hoisted_5$45={class:`slider-text-container`},_hoisted_6$32={class:`setting-item`},INPUT_CONTROL_STEPS$1=.01,INPUT_CONTROL_MIN$1=0,INPUT_CONTROL_MAX$1=6,INPUT_DEFAULT_VALUE$1=.5,CONTROLLER_SCALE_Y_BINDING=`focus_ud`,CONTROLLER_SCALE_X_BINDING=`focus_lr`,CONTROLLER_LOCK_BINDING=`action_2`,CONTROLLER_HINTS$1=[],KEYBOARD_HINTS$1=[],_sfc_main$101={__name:`LayerScaleSettings`,setup(__props){let store$1=useLayerSettingsStore(),actionHoldService=useActionHoldService(),{showIfController}=storeToRefs(controls_default()),infoBar=useInfoBar(),{editModeState}=storeToRefs(store$1),scaleX=computed({get:()=>store$1.cursorData&&store$1.cursorData.scale?store$1.cursorData.scale.x:void 0,set:async newValue=>{if(newValue===store$1.cursorData.scale.x)return;let scaleY$1=store$1.cursorData.scale.y;if(editModeState.value.lockScaling){let diff=newValue-store$1.cursorData.scale.x;scaleY$1+=diff}await store$1.setScale(newValue,scaleY$1)}}),scaleY=computed({get:()=>store$1.cursorData&&store$1.cursorData.scale?store$1.cursorData.scale.y:void 0,set:async newValue=>{if(newValue===store$1.cursorData.scale.y)return;let scaleX$1=store$1.cursorData.scale.x;if(editModeState.value.lockScaling){let diff=newValue-store$1.cursorData.scale.y;scaleX$1+=diff}await store$1.setScale(scaleX$1,newValue)}}),toggleLockScaling=()=>{editModeState.value.lockScaling=!editModeState.value.lockScaling};function onReset(){store$1.setScale(INPUT_DEFAULT_VALUE$1,INPUT_DEFAULT_VALUE$1)}function onTertiaryAction(){if(store$1.reapplyActive||store$1.requestApplyActive)onReset();else return!0}function onFocus(element,scalar=!1){let actionFn=(xDirection,yDirection)=>{xDirection!==0&&(scaleX.value=xDirection*INPUT_CONTROL_STEPS$1+scaleX.value),yDirection!==0&&(scaleY.value=yDirection*INPUT_CONTROL_STEPS$1+scaleY.value)};scalar?actionHoldService.onFocusScalar(`scale`,actionFn,element):actionHoldService.onFocus(`scale`,actionFn,element)}useUINavScope(`scale-settings`);let useCrossfireValue;onBeforeMount(()=>{useCrossfireValue=getUINavServiceInstance().useCrossfire,getUINavServiceInstance().useCrossfire=!1}),onBeforeUnmount(()=>{getUINavServiceInstance().useCrossfire=useCrossfireValue});let unwatchGamepad;onBeforeMount(()=>{unwatchGamepad=watch(showIfController,async()=>{await nextTick(()=>setHints())},{immediate:!0})}),onUnmounted(()=>{actionHoldService.removeAll(`scale`),unwatchGamepad&&unwatchGamepad(),removeHints()});function setHints(){let hints=showIfController.value?CONTROLLER_HINTS$1:KEYBOARD_HINTS$1;removeHints();for(let i=hints.length-1;i>=0;i--)infoBar.addHints(hints[i],0,!0)}function removeHints(){infoBar.removeHints(...KEYBOARD_HINTS$1.map(x=>x.id)),infoBar.removeHints(...CONTROLLER_HINTS$1.map(x=>x.id))}return(_ctx,_cache)=>withDirectives((openBlock(),createElementBlock(`div`,_hoisted_1$93,[createBaseVNode(`div`,_hoisted_2$80,[createBaseVNode(`div`,_hoisted_3$70,[createVNode(unref(bngInput_default),{modelValue:scaleX.value,"onUpdate:modelValue":_cache[0]||=$event=>scaleX.value=$event,min:INPUT_CONTROL_MIN$1,max:INPUT_CONTROL_MAX$1,step:INPUT_CONTROL_STEPS$1,type:`number`,prefix:`X`,class:`slider-text-textinput`},null,8,[`modelValue`]),createVNode(unref(bngSlider_default),{modelValue:scaleX.value,"onUpdate:modelValue":_cache[1]||=$event=>scaleX.value=$event,min:INPUT_CONTROL_MIN$1,max:INPUT_CONTROL_MAX$1,step:INPUT_CONTROL_STEPS$1,class:`slider-text-sliderinput`},null,8,[`modelValue`]),createVNode(unref(bngBinding_default),{uiEvent:CONTROLLER_SCALE_X_BINDING,deviceMask:`xinput`})])]),createBaseVNode(`div`,_hoisted_4$54,[createBaseVNode(`div`,_hoisted_5$45,[createVNode(unref(bngInput_default),{modelValue:scaleY.value,"onUpdate:modelValue":_cache[2]||=$event=>scaleY.value=$event,type:`number`,prefix:`Y`,min:INPUT_CONTROL_MIN$1,max:INPUT_CONTROL_MAX$1,step:INPUT_CONTROL_STEPS$1,class:`slider-text-textinput`},null,8,[`modelValue`]),createVNode(unref(bngSlider_default),{modelValue:scaleY.value,"onUpdate:modelValue":_cache[3]||=$event=>scaleY.value=$event,min:INPUT_CONTROL_MIN$1,max:INPUT_CONTROL_MAX$1,step:INPUT_CONTROL_STEPS$1,class:`slider-text-sliderinput`},null,8,[`modelValue`]),createVNode(unref(bngBinding_default),{uiEvent:CONTROLLER_SCALE_Y_BINDING,deviceMask:`xinput`})])]),createBaseVNode(`div`,_hoisted_6$32,[createVNode(unref(bngSwitch_default),{modelValue:unref(editModeState).lockScaling,"onUpdate:modelValue":_cache[4]||=$event=>unref(editModeState).lockScaling=$event},{default:withCtx(()=>[..._cache[5]||=[createTextVNode(`Lock Scaling`,-1)]]),_:1},8,[`modelValue`]),createVNode(unref(bngBinding_default),{uiEvent:CONTROLLER_LOCK_BINDING,deviceMask:`xinput`})])])),[[unref(BngOnUiNav_default),toggleLockScaling,`action_2`],[unref(BngOnUiNav_default),onTertiaryAction,`action_3`],[unref(BngOnUiNav_default),onFocus,`focus_l`,{up:!0}],[unref(BngOnUiNav_default),onFocus,`focus_l`,{down:!0}],[unref(BngOnUiNav_default),onFocus,`focus_r`,{down:!0}],[unref(BngOnUiNav_default),onFocus,`focus_r`,{up:!0}],[unref(BngOnUiNav_default),onFocus,`focus_u`,{up:!0}],[unref(BngOnUiNav_default),onFocus,`focus_u`,{down:!0}],[unref(BngOnUiNav_default),onFocus,`focus_d`,{down:!0}],[unref(BngOnUiNav_default),onFocus,`focus_d`,{up:!0}],[unref(BngOnUiNav_default),el=>onFocus(el,!0),`focus_lr`],[unref(BngOnUiNav_default),el=>onFocus(el,!0),`focus_ud`]])}},LayerScaleSettings_default=__plugin_vue_export_helper_default(_sfc_main$101,[[`__scopeId`,`data-v-56a383d1`]]),_hoisted_1$92={class:`sort-settings`,"bng-ui-scope":`sort-settings`},_hoisted_2$79={class:`setting-item`},_hoisted_3$69={class:`icon-binding-wrapper`},_hoisted_4$53={class:`icon-binding-wrapper`},_hoisted_5$44={class:`icon-binding-wrapper`},_hoisted_6$31={class:`stacked-arrows`},_hoisted_7$27={class:`icon-binding-wrapper`},_hoisted_8$21={class:`stacked-arrows`},_hoisted_9$18={key:0},ORDER_TOOL=Lua_default.extensions.ui_liveryEditor_tools_group,_sfc_main$100={__name:`LayerSortSettings`,setup(__props){let store$1=useLiveryEditorStore();useUINavScope(`sort-settings`);let order=computed({get:()=>store$1.selectedLayers[0].order,set(newValue){ORDER_TOOL.setOrder(newValue)}}),orderMax=computed(()=>store$1.selectedLayers[0].siblingCount),multiSelected=computed(()=>store$1.selectedLayerUids.length>1),orderOptions=computed(()=>Array.from({length:store$1.layers.length-1},(_,i)=>({label:`${i+1}`,value:i+2})));return onMounted(()=>{getUINavServiceInstance().useCrossfire=!1}),(_ctx,_cache)=>withDirectives((openBlock(),createElementBlock(`div`,_hoisted_1$92,[createBaseVNode(`div`,_hoisted_2$79,[createVNode(unref(bngButton_default),{onClick:_cache[0]||=()=>unref(ORDER_TOOL).moveOrderUp(),disabled:order.value===orderMax.value},{default:withCtx(()=>[createBaseVNode(`div`,_hoisted_3$69,[createVNode(unref(bngIcon_default),{type:unref(icons).arrowLargeUp},null,8,[`type`]),createVNode(unref(bngBinding_default),{action:`menu_item_up`})])]),_:1},8,[`disabled`]),createVNode(unref(bngButton_default),{onClick:_cache[1]||=()=>unref(ORDER_TOOL).moveOrderDown(),disabled:order.value===2},{default:withCtx(()=>[createBaseVNode(`div`,_hoisted_4$53,[createVNode(unref(bngIcon_default),{type:unref(icons).arrowLargeDown},null,8,[`type`]),createVNode(unref(bngBinding_default),{action:`menu_item_down`})])]),_:1},8,[`disabled`]),multiSelected.value?createCommentVNode(``,!0):(openBlock(),createBlock(unref(bngButton_default),{key:0,onClick:_cache[2]||=()=>unref(ORDER_TOOL).changeOrderToTop(),disabled:order.value===orderMax.value},{default:withCtx(()=>[createBaseVNode(`div`,_hoisted_5$44,[createBaseVNode(`div`,_hoisted_6$31,[createVNode(unref(bngIcon_default),{type:unref(icons).arrowLargeUp},null,8,[`type`]),createVNode(unref(bngIcon_default),{type:unref(icons).arrowLargeUp},null,8,[`type`])]),createVNode(unref(bngBinding_default),{action:`menu_item_right`})])]),_:1},8,[`disabled`])),multiSelected.value?createCommentVNode(``,!0):(openBlock(),createBlock(unref(bngButton_default),{key:1,onClick:_cache[3]||=()=>unref(ORDER_TOOL).changeOrderToBottom(),disabled:order.value===2},{default:withCtx(()=>[createBaseVNode(`div`,_hoisted_7$27,[createBaseVNode(`div`,_hoisted_8$21,[createVNode(unref(bngIcon_default),{type:unref(icons).arrowLargeDown,disabled:unref(store$1).selectedLayers.length>1},null,8,[`type`,`disabled`]),createVNode(unref(bngIcon_default),{type:unref(icons).arrowLargeDown,disabled:unref(store$1).selectedLayers.length>1},null,8,[`type`,`disabled`])]),createVNode(unref(bngBinding_default),{action:`menu_item_left`})])]),_:1},8,[`disabled`]))]),multiSelected.value?createCommentVNode(``,!0):(openBlock(),createElementBlock(`div`,_hoisted_9$18,[createVNode(unref(bngDropdown_default),{modelValue:order.value,"onUpdate:modelValue":_cache[4]||=$event=>order.value=$event,items:orderOptions.value},null,8,[`modelValue`,`items`])]))])),[[unref(BngOnUiNav_default),()=>unref(ORDER_TOOL).changeOrderToBottom(),`focus_l`],[unref(BngOnUiNav_default),()=>unref(ORDER_TOOL).changeOrderToTop(),`focus_r`],[unref(BngOnUiNav_default),()=>unref(ORDER_TOOL).moveOrderUp(),`focus_u`],[unref(BngOnUiNav_default),()=>unref(ORDER_TOOL).moveOrderDown(),`focus_d`]])}},LayerSortSettings_default=__plugin_vue_export_helper_default(_sfc_main$100,[[`__scopeId`,`data-v-1d4969be`]]),_hoisted_1$91={class:`skew-settings`,"bng-ui-scope":`skew-settings`},_hoisted_2$78={class:`setting-item item-column`},_hoisted_3$68={class:`slider-text-container`},_hoisted_4$52={class:`setting-item item-column`},_hoisted_5$43={class:`slider-text-container`},INPUT_CONTROL_STEPS=.01,INPUT_CONTROL_MIN=-2,INPUT_CONTROL_MAX=2,INPUT_DEFAULT_VALUE=0,CONTROLLER_SKEW_Y_BINDING=`focus_ud`,CONTROLLER_SKEW_X_BINDING=`focus_lr`,CONTROLLER_HINTS=[],KEYBOARD_HINTS=[],_sfc_main$99={__name:`LayerDeformSettings`,setup(__props){let store$1=useLayerSettingsStore(),actionHoldService=useActionHoldService(),{showIfController}=storeToRefs(controls_default()),infoBar=useInfoBar(),skewX=computed({get:()=>store$1.cursorData&&store$1.cursorData.skew?store$1.cursorData.skew.x:void 0,set:async newValue=>await store$1.setSkew(newValue,store$1.cursorData.skew.y)}),skewY=computed({get:()=>store$1.cursorData&&store$1.cursorData.skew?store$1.cursorData.skew.y:void 0,set:async newValue=>await store$1.setSkew(store$1.cursorData.skew.x,newValue)});function onReset(){store$1.setSkew(INPUT_DEFAULT_VALUE,INPUT_DEFAULT_VALUE)}function onTertiaryAction(){if(store$1.reapplyActive||store$1.requestApplyActive)onReset();else return!0}useUINavScope(`skew-settings`);let useCrossfireValue;onBeforeMount(()=>{useCrossfireValue=getUINavServiceInstance().useCrossfire,getUINavServiceInstance().useCrossfire=!1}),onBeforeUnmount(()=>{getUINavServiceInstance().useCrossfire=useCrossfireValue});let unwatchGamepad;onBeforeMount(()=>{unwatchGamepad=watch(showIfController,async()=>{await nextTick(()=>setHints())},{immediate:!0})}),onUnmounted(()=>{actionHoldService.removeAll(`skew`),unwatchGamepad&&unwatchGamepad(),removeHints()});function setHints(){let hints=showIfController.value?CONTROLLER_HINTS:KEYBOARD_HINTS;removeHints();for(let i=hints.length-1;i>=0;i--)infoBar.addHints(hints[i],0,!0)}function removeHints(){infoBar.removeHints(...KEYBOARD_HINTS.map(x=>x.id)),infoBar.removeHints(...CONTROLLER_HINTS.map(x=>x.id))}return(_ctx,_cache)=>withDirectives((openBlock(),createElementBlock(`div`,_hoisted_1$91,[createBaseVNode(`div`,_hoisted_2$78,[createBaseVNode(`div`,_hoisted_3$68,[createVNode(unref(bngInput_default),{modelValue:skewX.value,"onUpdate:modelValue":_cache[0]||=$event=>skewX.value=$event,min:INPUT_CONTROL_MIN,max:INPUT_CONTROL_MAX,step:INPUT_CONTROL_STEPS,type:`number`,prefix:`X`,class:`slider-text-textinput`},null,8,[`modelValue`]),createVNode(unref(bngSlider_default),{modelValue:skewX.value,"onUpdate:modelValue":_cache[1]||=$event=>skewX.value=$event,min:INPUT_CONTROL_MIN,max:INPUT_CONTROL_MAX,step:INPUT_CONTROL_STEPS,class:`slider-text-sliderinput`},null,8,[`modelValue`]),createVNode(unref(bngBinding_default),{uiEvent:CONTROLLER_SKEW_X_BINDING,deviceMask:`xinput`})])]),createBaseVNode(`div`,_hoisted_4$52,[createBaseVNode(`div`,_hoisted_5$43,[createVNode(unref(bngInput_default),{modelValue:skewY.value,"onUpdate:modelValue":_cache[2]||=$event=>skewY.value=$event,type:`number`,prefix:`Y`,min:INPUT_CONTROL_MIN,max:INPUT_CONTROL_MAX,step:INPUT_CONTROL_STEPS,class:`slider-text-textinput`},null,8,[`modelValue`]),createVNode(unref(bngSlider_default),{modelValue:skewY.value,"onUpdate:modelValue":_cache[3]||=$event=>skewY.value=$event,min:INPUT_CONTROL_MIN,max:INPUT_CONTROL_MAX,step:INPUT_CONTROL_STEPS,class:`slider-text-sliderinput`},null,8,[`modelValue`]),createVNode(unref(bngBinding_default),{uiEvent:CONTROLLER_SKEW_Y_BINDING,deviceMask:`xinput`})])])])),[[unref(BngOnUiNav_default),onTertiaryAction,`action_3`],[unref(BngOnUiNav_default),element=>unref(actionHoldService).onFocus(`skew`,unref(store$1).skew,element),`focus_l`,{up:!0}],[unref(BngOnUiNav_default),element=>unref(actionHoldService).onFocus(`skew`,unref(store$1).skew,element),`focus_l`,{down:!0}],[unref(BngOnUiNav_default),element=>unref(actionHoldService).onFocus(`skew`,unref(store$1).skew,element),`focus_r`,{down:!0}],[unref(BngOnUiNav_default),element=>unref(actionHoldService).onFocus(`skew`,unref(store$1).skew,element),`focus_r`,{up:!0}],[unref(BngOnUiNav_default),element=>unref(actionHoldService).onFocus(`skew`,unref(store$1).skew,element),`focus_u`,{up:!0}],[unref(BngOnUiNav_default),element=>unref(actionHoldService).onFocus(`skew`,unref(store$1).skew,element),`focus_u`,{down:!0}],[unref(BngOnUiNav_default),element=>unref(actionHoldService).onFocus(`skew`,unref(store$1).skew,element),`focus_d`,{down:!0}],[unref(BngOnUiNav_default),element=>unref(actionHoldService).onFocus(`skew`,unref(store$1).skew,element),`focus_d`,{up:!0}],[unref(BngOnUiNav_default),element=>unref(actionHoldService).onFocusScalar(`skew`,unref(store$1).skew,element),`focus_lr`],[unref(BngOnUiNav_default),element=>unref(actionHoldService).onFocusScalar(`skew`,unref(store$1).skew,element),`focus_ud`]])}},LayerDeformSettings_default=__plugin_vue_export_helper_default(_sfc_main$99,[[`__scopeId`,`data-v-b2c32ce6`]]),_hoisted_1$90={class:`layer-settings-base`},_hoisted_2$77={class:`settings-heading`},_hoisted_3$67={class:`settings-content`},_sfc_main$98={__name:`LayerSettingsBase`,props:{heading:{type:String}},emits:[`close`],setup(__props){let slots=useSlots();return(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$90,[createBaseVNode(`div`,_hoisted_2$77,[createVNode(unref(bngCardHeading_default),{type:`ribbon`},{default:withCtx(()=>[unref(slots).heading?renderSlot(_ctx.$slots,`heading`,{key:0},()=>[createBaseVNode(`span`,null,toDisplayString(__props.heading),1)],!0):createCommentVNode(``,!0)]),_:3})]),createBaseVNode(`div`,_hoisted_3$67,[renderSlot(_ctx.$slots,`default`,{},void 0,!0)])]))}},LayerSettingsBase_default=__plugin_vue_export_helper_default(_sfc_main$98,[[`__scopeId`,`data-v-c5fed92f`]]),_hoisted_1$89={class:`setting-item item-column`},_hoisted_2$76={class:`slider-text-container`},_hoisted_3$66={class:`setting-item item-column`},_hoisted_4$51={class:`slider-text-container`},_sfc_main$97={__name:`TransformSettings`,setup(__props){let scaleX=ref(.5),scaleY=ref(.5);return(_ctx,_cache)=>(openBlock(),createBlock(unref(LayerSettingsBase_default),null,{heading:withCtx(()=>[..._cache[2]||=[createTextVNode(`Transform`,-1)]]),default:withCtx(()=>[createBaseVNode(`template`,null,[createBaseVNode(`div`,_hoisted_1$89,[createBaseVNode(`div`,_hoisted_2$76,[createVNode(unref(bngInput_default),{modelValue:scaleX.value,"onUpdate:modelValue":_cache[0]||=$event=>scaleX.value=$event,min:0,max:6,step:.01,type:`number`,prefix:`X`},null,8,[`modelValue`])])]),createBaseVNode(`div`,_hoisted_3$66,[createBaseVNode(`div`,_hoisted_4$51,[createVNode(unref(bngInput_default),{modelValue:scaleY.value,"onUpdate:modelValue":_cache[1]||=$event=>scaleY.value=$event,type:`number`,prefix:`Y`,min:0,max:6,step:.01},null,8,[`modelValue`])])])])]),_:1}))}},TransformSettings_default=_sfc_main$97,_hoisted_1$88={class:`settings-container`},_hoisted_2$75={class:`setting-types-selector`},_hoisted_3$65={class:`setting-types`},_hoisted_4$50=[`onClick`],_hoisted_5$42={class:`heading-content-wrapper`},_hoisted_6$30={class:`heading-content-text`},_hoisted_7$26={key:0},_hoisted_8$20={key:0,class:`subheading`},CONTROLLER_RESET_BINDING=`advanced`,SETTING_TYPES=[{value:`transform`,label:`Transform`,icon:icons.transform,component:markRaw(TransformSettings_default)},{value:`transformold`,label:`Position`,icon:icons.transform,component:markRaw(LayerTransformSettingsOld_default)},{value:`scale`,label:`Scale`,icon:icons.scale,component:markRaw(LayerScaleSettings_default)},{value:`skew`,label:`Skew`,icon:icons.deform,component:markRaw(LayerDeformSettings_default)},{value:`rotate`,label:`Rotate`,icon:icons.rotationL,component:markRaw(LayerRotateSettings_default)},{value:`material`,label:`Material`,icon:icons.material,component:markRaw(LayerMaterialSettings_default)},{value:`mirror`,label:`Mirror`,icon:icons.reflect,component:markRaw(LayerMirrorSettings_default)}],_sfc_main$96={__name:`LayerSettings`,props:{settingTypes:Array,activeSetting:String,excludeSettingTypes:Array},setup(__props){let store$1=useLayerSettingsStore(),props=__props,currentIndex=ref(0),settingTypes=computed(()=>{let filtered=SETTING_TYPES;return props.settingTypes&&(filtered=filtered.filter(x=>props.settingTypes.includes(x.value))),props.excludeSettingTypes&&(filtered=filtered.filter(x=>!props.excludeSettingTypes.includes(x.value))),filtered}),activeSubSetting=ref(null),activeSettingType=computed(()=>settingTypes.value[currentIndex.value]),mouseMode=computed(()=>store$1.cursorData?store$1.cursorData.isUseMousePos:void 0);watch(()=>props.activeSetting,()=>{let index=settingTypes.value.findIndex(x=>x.value===props.activeSetting);index>-1?currentIndex.value=index:console.warn(`Error finding setting ${props.activeSetting}`)},{immediate:!0}),watch(activeSettingType,value=>store$1.activeSetting=value.value,{immediate:!0}),watch(activeSettingType,(newValue,oldValue)=>{newValue.value&&oldValue.value}),onMounted(()=>{getUINavServiceInstance().useCrossfire=!1}),onUnmounted(async()=>{getUINavServiceInstance().useCrossfire=!0});let setTool=settingType=>{currentIndex.value=settingTypes.value.findIndex(x=>x.value===settingType.value)},goPreviousTab=()=>{currentIndex.value=currentIndex.value>0?currentIndex.value-1:settingTypes.value.length-1},goNextTab=()=>{currentIndex.value=currentIndex.value(openBlock(),createElementBlock(`div`,_hoisted_1$88,[withDirectives((openBlock(),createElementBlock(`div`,_hoisted_2$75,[createBaseVNode(`div`,{onClick:goPreviousTab},[createVNode(unref(bngIcon_default),{type:unref(icons).arrowSmallLeft},null,8,[`type`]),createVNode(unref(bngBinding_default),{action:`menu_tab_left`,deviceMask:`xinput`})]),createBaseVNode(`div`,_hoisted_3$65,[(openBlock(!0),createElementBlock(Fragment,null,renderList(settingTypes.value,settingType=>withDirectives((openBlock(),createElementBlock(`div`,{key:settingType.value,class:normalizeClass([{active:activeSettingType.value.value===settingType.value},`setting-type`]),onClick:$event=>setTool(settingType)},[createVNode(unref(bngIcon_default),{type:settingType.icon,class:`setting-type-icon`},null,8,[`type`])],10,_hoisted_4$50)),[[unref(BngTooltip_default),activeSettingType.value.value===settingType.value?void 0:settingType.label,`top`]])),128))]),createBaseVNode(`div`,{onClick:goNextTab},[createVNode(unref(bngBinding_default),{action:`menu_tab_right`,deviceMask:`xinput`}),createVNode(unref(bngIcon_default),{type:unref(icons).arrowSmallRight},null,8,[`type`])])])),[[unref(BngBlur_default)],[unref(BngOnUiNav_default),goPreviousTab,`tab_l`],[unref(BngOnUiNav_default),goNextTab,`tab_r`]]),withDirectives((openBlock(),createBlock(LayerSettingsBase_default,null,{heading:withCtx(()=>[createBaseVNode(`div`,_hoisted_5$42,[createBaseVNode(`span`,_hoisted_6$30,[createBaseVNode(`span`,null,[createTextVNode(toDisplayString(activeSettingType.value.label)+` `,1),activeSubSetting.value?(openBlock(),createElementBlock(`span`,_hoisted_7$26,`/`)):createCommentVNode(``,!0)]),activeSubSetting.value?(openBlock(),createElementBlock(`span`,_hoisted_8$20,toDisplayString(activeSubSetting.value.label),1)):createCommentVNode(``,!0)]),(unref(store$1).reapplyActive||unref(store$1).requestApplyActive)&&(activeSettingType.value.value!==`transform`||!mouseMode.value)?(openBlock(),createBlock(unref(BindingButton_default),{key:0,icon:unref(icons).restart,accent:`text`,label:`Reset`,uiEvent:CONTROLLER_RESET_BINDING,onClick:resetSettings},null,8,[`icon`])):createCommentVNode(``,!0)])]),default:withCtx(()=>[(openBlock(),createBlock(resolveDynamicComponent(activeSettingType.value.component),{onSubSettingChanged},null,32))]),_:1})),[[unref(BngOnUiNav_default),onAdvanced,`advanced`],[unref(BngBlur_default)]])]))}},LayerSettings_default=__plugin_vue_export_helper_default(_sfc_main$96,[[`__scopeId`,`data-v-ca9ed9d2`]]),_hoisted_1$87={key:0,"bng-ui-scope":`liveryeditor-editmode`,class:`liveryeditor-editmode-layout`},_hoisted_2$74={class:`layers-preview-container`},_hoisted_3$64={class:`layer-settings-wrapper`},SAVE_TYPES={default:1,asGroup:2},FOCUS_LD_TRIGGER_VALUE=-.999,FOCUS_RU_TRIGGER_VALUE=.999,HEADER_TEXT$1=`Edit Mode`,CONTEXT_MENU_NAME=`context-menu`,CONTROLLER_EXIT_BINDING=`back`,CONTROLLER_SAVE_BINDING=`menu`,APPLY_DEFAULT_HINTS=[{id:`apply`,content:{type:`binding`,props:{uiEvent:`ok`},label:`Apply`}},{id:`cancel`,content:{type:`binding`,props:{uiEvent:`back`},label:`Cancel`}}],APPLY_MOUSE_HINTS=[{id:`cancel`,content:{type:`binding`,props:{uiEvent:`back`},label:`Cancel`}}],FREECAM_CONTROLLER_HINTS=[{id:`toggle_freecam`,content:{type:`binding`,props:{uiEvent:`action_4`},label:`Toggle View Point`}}],VIEWPOINT_CONTROLLER_HINTS=[{id:`toggle_freecam`,content:{type:`binding`,props:{uiEvent:`action_4`},label:`Toggle Free Cam`}}],DELETE_LAYER_HINT={id:`delete`,content:{type:`binding`,props:{uiEvent:`advanced`},label:`Delete`}},_sfc_main$95={__name:`EditModeLayout`,setup(__props){useCssVars(_ctx=>({ff7f3326:alphaTextureBackground.value}));let infoBar=useInfoBar(),{showIfController}=storeToRefs(controls_default()),actionHoldService=useActionHoldService(),rootStore=useLiveryEditorStore(),store$1=useLayerSettingsStore(),popover=usePopover(),freecam=ref(!1),CONTEXT_MENU_STYLES=ref({display:`flex`,"flex-direction":`column`}),contextMenuName=ref(`context-menu`),alphaTextureBackground=computed(()=>`url(${getAssetURL(`images/alpha_texture.png`)}`);onBeforeMount(async()=>{await store$1.getInitialData(),watch(showIfController,()=>{actionHoldService.clear()})}),onMounted(()=>{store$1.init(),infoBar.clearHints()}),onUnmounted(()=>{infoBar.clearHints()});async function onAddOrChangeDecal(){await rootStore.toggleShowDecalSelector()}function onBack(){popover.isShown(CONTEXT_MENU_NAME)?popover.hide(CONTEXT_MENU_NAME):store$1.appliedLayers&&store$1.appliedLayers.length>0&&store$1.requestApplyActive?store$1.cancelRequestApply():store$1.appliedLayers&&store$1.reapplyActive?store$1.cancelReapply():confirmCancelChanges()}function onContextMenu(){store$1.reapplyActive?store$1.requestChangeDecal():store$1.requestApplyActive?rootStore.toggleShowDecalSelector():store$1.duplicateActiveLayer()}function onAdvanced(){!store$1.requestApplyActive&&!store$1.reapplyActive&&store$1.activeLayerUid&&store$1.appliedLayers.length>1&&(getUINavServiceInstance().useCrossfire=!0,openConfirmation(`Delete Decal`).then(res=>{res&&store$1.removeAppliedLayer(store$1.activeLayerUid),getUINavServiceInstance().useCrossfire=!0}))}function onOk(){(store$1.requestApplyActive||store$1.reapplyActive)&&store$1.apply()}function confirmSaveChanges(){!store$1.appliedLayers||store$1.appliedLayers.length===0||(getUINavServiceInstance().useCrossfire=!0,openConfirmation(`Save`,`Save changes and exit edit mode?`,[{label:$translate.instant(`ui.common.cancel`),value:void 0,extras:{cancel:!0,accent:ACCENTS.secondary}},{label:$translate.instant(`ui.common.save`),value:SAVE_TYPES.default,extras:{default:!0}}]).then(res=>{res?store$1.saveChanges():getUINavServiceInstance().useCrossfire=!1}))}async function confirmCancelChanges(){getUINavServiceInstance().useCrossfire=!0;let hasChanges=store$1.appliedLayers&&store$1.appliedLayers.length>0;await openConfirmation(`Exit`,hasChanges?`Exit edit mode and lose all changes?`:`Exit Edit Mode?`)?(hasChanges&&await store$1.cancelChanges(),await store$1.deactivate()):getUINavServiceInstance().useCrossfire=!1}let removeLayer=()=>{store$1.removeAppliedLayer(store$1.activeLayerUid),popover.hide(CONTEXT_MENU_NAME)};function onSecondaryAction(element){!store$1.reapplyActive&&!store$1.requestApplyActive&&store$1.requestApply()}function onTertiaryAction(element){store$1.cursorData.applied&&!store$1.reapplyActive&&store$1.toggleHighlightActive()}function onQuaternaryAction(element){freecam.value=!freecam.value}function onRotateHCam(element){if(freecam.value)return!0;let direction$1=element.detail.value;(direction$1>=FOCUS_RU_TRIGGER_VALUE||direction$1<=FOCUS_LD_TRIGGER_VALUE)&&rootStore.switchOrthographicViewByDirection(direction$1>0?-1:1,0)}function onRotateVCam(element){if(freecam.value)return!0;let direction$1=element.detail.value;(direction$1>=FOCUS_RU_TRIGGER_VALUE||direction$1<=FOCUS_LD_TRIGGER_VALUE)&&rootStore.switchOrthographicViewByDirection(0,direction$1>0?-1:1)}let APPLY_CONTROLLER_HINTS=[{id:`change_decal`,content:{type:`binding`,props:{uiEvent:`context`},label:`Change Decal`},action:store$1.requestChangeDecal}],DEFAULT_HINTS=[{id:`duplicate_decal`,content:{type:`binding`,props:{action:`duplicate_active_layer`},label:`Duplicate Decal`,action:store$1.duplicateActiveLayer}},{id:`activate_previous_decal`,content:{type:`binding`,props:{action:`activate_previous_layer`},label:`Edit Previous Decal`}},{id:`activate_next_decal`,content:{type:`binding`,props:{action:`activate_next_layer`},label:`Edit Next Decal`}},{id:`save`,content:{type:`binding`,props:{uiEvent:`menu`},label:`Save`}},{id:`exit`,content:{type:`binding`,props:{uiEvent:`back`},label:`Exit`}}],DEFAULT_CONTROLLER_HINTS=[{id:`apply_or_new`,content:{type:`binding`,props:{uiEvent:`action_2`},label:`New Decal`}},{id:`delete_decal`,content:{type:`binding`,props:{uiEvent:`advanced`},label:`Delete Decal`,action:()=>store$1.removeAppliedLayer(store$1.activeLayerUid)}},{id:`duplicate_decal`,content:{type:`binding`,props:{uiEvent:`context`},label:`Duplicate Decal`},action:()=>store$1.duplicateActiveLayer()},{id:`highlight_decal`,content:{type:`binding`,props:{uiEvent:`action_3`},label:`Toggle Highlight`},action:()=>store$1.toggleHighlightActive()}];watchEffect(()=>{let isController$2=showIfController.value,defaultControllerHints=!1,hints;removeHints(),store$1.requestApplyActive||store$1.reapplyActive?hints=store$1.cursorData.isUseMousePos?APPLY_MOUSE_HINTS:isController$2?APPLY_CONTROLLER_HINTS:APPLY_DEFAULT_HINTS:isController$2?(hints=DEFAULT_CONTROLLER_HINTS,defaultControllerHints=!0):hints=DEFAULT_HINTS;for(let i=0;i1&&infoBar.addHints(DELETE_LAYER_HINT,`change_decal`,!0),(!store$1.appliedLayers||store$1.appliedLayers.length<=1)&&infoBar.removeHints(`delete_decal`)}),watch(()=>freecam.value,async()=>{freecam.value?rootStore.cameraView=`free`:await rootStore.setOrthographicView(`right`)});function removeHints(){APPLY_MOUSE_HINTS.forEach(x=>infoBar.removeHints(x.id)),APPLY_CONTROLLER_HINTS.forEach(x=>infoBar.removeHints(x.id)),APPLY_DEFAULT_HINTS.forEach(x=>infoBar.removeHints(x.id)),DEFAULT_HINTS.forEach(x=>infoBar.removeHints(x.id)),DEFAULT_CONTROLLER_HINTS.forEach(x=>infoBar.removeHints(x.id)),FREECAM_CONTROLLER_HINTS.forEach(x=>infoBar.removeHints(x.id)),VIEWPOINT_CONTROLLER_HINTS.forEach(x=>infoBar.removeHints(x.id)),infoBar.removeHints(DELETE_LAYER_HINT.id)}let headerStore=useEditorHeaderStore(),resetDisabled=ref(!1),saveDisabled=ref(!0),useMouse=computed(()=>store$1.cursorData?store$1.cursorData.isUseMousePos:void 0),changeMouseMode=async newValue=>await store$1.setUseMousePos(newValue),HEADER_APPLY_ITEMS=[{id:`cancel_apply`,section:`end`,component:shallowRef(bngButton_default),props:{label:`Cancel Apply`,accent:ACCENTS.attention},events:{click:()=>{store$1.requestApplyActive&&store$1.cancelRequestApply()}},hidden:!0},{id:`undo_reapply`,section:`end`,component:shallowRef(bngButton_default),props:{label:`Undo Reapply`,accent:ACCENTS.attention},events:{click:()=>{store$1.reapplyActive&&store$1.cancelReapply()}},hidden:!0},{id:`use_mouse`,section:`end`,component:shallowRef(bngSwitch_default),props:{modelValue:useMouse,label:`Use Mouse`,uncheckedWithBackground:!0},events:{"update:modelValue":changeMouseMode}}],showBinding=computed(()=>!store$1.active||!store$1.appliedLayers||store$1.appliedLayers.length===0||!(store$1.reapplyActive||store$1.requestApplyActive)),HEADER_GLOBAL_ITEMS=[{id:`save_changes`,section:`start`,component:shallowRef(BindingButton_default),props:{icon:icons.saveAs1,accent:ACCENTS.main,label:`Save and Exit`,disabled:saveDisabled,uiEvent:CONTROLLER_SAVE_BINDING,deviceMask:`xinput`},events:{click:confirmSaveChanges}},{id:`exit_edit_mode`,section:`start`,component:shallowRef(BindingButton_default),props:{icon:icons.exit,accent:ACCENTS.attention,label:`Exit Edit Mode`,uiEvent:CONTROLLER_EXIT_BINDING,deviceMask:`xinput`,showBinding},events:{click:confirmCancelChanges}}];return watch(()=>store$1.active,active=>{active&&(headerStore.setHeader(HEADER_TEXT$1,`ribbon`),headerStore.setPreheader(void 0))},{immediate:!0}),watchEffect(()=>{store$1.appliedLayers&&store$1.appliedLayers.length>0&&store$1.requestApplyActive?headerStore.showItem(`cancel_apply`):headerStore.hideItem(`cancel_apply`)}),watch(()=>store$1.reapplyActive,value=>{value?headerStore.showItem(`undo_reapply`):headerStore.hideItem(`undo_reapply`)}),watchEffect(()=>{saveDisabled.value=!store$1.appliedLayers||store$1.appliedLayers.length===0,resetDisabled.value=!store$1.requestApplyActive&&!store$1.reapplyActive}),onMounted(()=>{headerStore.removeItems(HEADER_APPLY_ITEMS),headerStore.removeItem(HEADER_GLOBAL_ITEMS),store$1.active&&(headerStore.addItems(HEADER_APPLY_ITEMS,!0),headerStore.addItems(HEADER_GLOBAL_ITEMS))}),onUnmounted(()=>{headerStore.removeItems(HEADER_APPLY_ITEMS),headerStore.removeItems(HEADER_GLOBAL_ITEMS)}),(_ctx,_cache)=>unref(store$1).active?withDirectives((openBlock(),createElementBlock(`div`,_hoisted_1$87,[createBaseVNode(`div`,_hoisted_2$74,[unref(store$1).appliedLayers&&!unref(store$1).requestApplyActive?withDirectives((openBlock(),createBlock(unref(bngImageTile_default),{key:0,icon:unref(icons).decal,class:normalizeClass([{cancel:unref(store$1).requestApplyActive},`add-item`]),disabled:unref(store$1).reapplyActive?`disabled`:``,ratio:`1:1`,onClick:onAddOrChangeDecal},{default:withCtx(()=>[..._cache[0]||=[createBaseVNode(`label`,null,`Add`,-1)]]),_:1},8,[`icon`,`class`,`disabled`])),[[unref(BngBlur_default)]]):withDirectives((openBlock(),createElementBlock(`div`,{key:1,class:`layer-ghost-wrapper`,onClick:onAddOrChangeDecal},[createVNode(DecalPreviewTile_default,{textureImage:unref(store$1).cursorData.decalTexturePath,textureColor:unref(store$1).cursorData.color},null,8,[`textureImage`,`textureColor`]),createVNode(unref(bngIcon_default),{class:`hover-icon`,type:unref(icons).edit},null,8,[`type`])])),[[unref(BngBlur_default)]]),unref(store$1).appliedLayers&&unref(store$1).appliedLayers.length>0?withDirectives((openBlock(),createBlock(EditModeLayersPreview_default,{key:2,contextMenuName:contextMenuName.value},null,8,[`contextMenuName`])),[[unref(BngBlur_default)]]):createCommentVNode(``,!0)]),createBaseVNode(`div`,_hoisted_3$64,[createVNode(unref(LayerSettings_default))]),unref(store$1).appliedLayers&&unref(store$1).appliedLayers.length>0&&unref(store$1).activeLayerUid!==null&&unref(store$1).activeLayerUid!==void 0?(openBlock(),createBlock(unref(bngPopoverContent_default),{key:0,name:contextMenuName.value},{default:withCtx(()=>[createBaseVNode(`div`,{class:`layer-context-menu`,style:normalizeStyle(CONTEXT_MENU_STYLES.value)},[createVNode(unref(bngButton_default),{onClick:withModifiers(unref(store$1).requestChangeDecal,[`stop`])},{default:withCtx(()=>[..._cache[1]||=[createTextVNode(`Change Decal`,-1)]]),_:1},8,[`onClick`]),createVNode(unref(bngButton_default),{disabled:unref(store$1).appliedLayers.length<=1,accent:`attention`,onClick:withModifiers(removeLayer,[`stop`])},{default:withCtx(()=>[..._cache[2]||=[createTextVNode(`Delete`,-1)]]),_:1},8,[`disabled`])],4)]),_:1},8,[`name`])):createCommentVNode(``,!0)])),[[unref(BngOnUiNav_default),onOk,`ok`],[unref(BngOnUiNav_default),onContextMenu,`context`],[unref(BngOnUiNav_default),onAdvanced,`advanced`],[unref(BngOnUiNav_default),onBack,`back`],[unref(BngOnUiNav_default),confirmSaveChanges,`menu`],[unref(BngOnUiNav_default),onSecondaryAction,`action_2`],[unref(BngOnUiNav_default),onTertiaryAction,`action_3`],[unref(BngOnUiNav_default),onQuaternaryAction,`action_4`],[unref(BngOnUiNav_default),onRotateHCam,`rotate_h_cam`],[unref(BngOnUiNav_default),onRotateVCam,`rotate_v_cam`]]):createCommentVNode(``,!0)}},EditModeLayout_default=__plugin_vue_export_helper_default(_sfc_main$95,[[`__scopeId`,`data-v-9b377f5e`]]),_hoisted_1$86={class:`layer-content`},_hoisted_2$73={class:`layer-name`},_hoisted_3$63={key:0,class:`layer-actions`},_hoisted_4$49={class:`layer-preview`},_hoisted_5$41={key:1,class:`group-preview`},_sfc_main$94={__name:`LayerTile`,props:{layer:Object,isTargeted:Boolean,forceShowActions:Boolean,disableMoveUp:Boolean,disableMoveDown:Boolean},emits:[`lockClicked`,`hideClicked`,`moveClicked`,`enableClicked`],setup(__props){let isHovered=ref(!1),toRgba255Styles=colors=>`rgba(${colors[0]*255}, ${colors[1]*255}, ${colors[2]*255}, ${colors[3]})`;return(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,{class:`layer-tile`,onMouseover:_cache[1]||=$event=>isHovered.value=!0,onMouseleave:_cache[2]||=$event=>isHovered.value=!1},[createBaseVNode(`div`,_hoisted_1$86,[renderSlot(_ctx.$slots,`content`,{},()=>[createBaseVNode(`div`,_hoisted_2$73,toDisplayString(__props.layer.name),1),__props.forceShowActions||!__props.layer.enabled?(openBlock(),createElementBlock(`div`,_hoisted_3$63,[__props.forceShowActions?(openBlock(),createBlock(unref(bngBinding_default),{key:0,"track-ignore":!0,uiEvent:`action_2`,deviceMask:`xinput`})):createCommentVNode(``,!0),createVNode(unref(bngButton_default),{accent:`outlined`,onClick:_cache[0]||=$event=>_ctx.$emit(`enableClicked`),icon:__props.layer.enabled?unref(icons).eyeSolidOpened:unref(icons).eyeSolidClosed},null,8,[`icon`])])):createCommentVNode(``,!0)],!0)]),createBaseVNode(`div`,_hoisted_4$49,[__props.layer.type===1?(openBlock(),createElementBlock(`div`,{key:0,class:`fill-preview`,style:normalizeStyle({"--layer-color":toRgba255Styles(__props.layer.color)})},null,4)):__props.layer.type===3?(openBlock(),createElementBlock(`div`,_hoisted_5$41,[createVNode(unref(bngIcon_default),{type:unref(icons).group},null,8,[`type`])])):__props.layer.type===0?(openBlock(),createBlock(DecalPreviewTile_default,{key:2,textureImage:__props.layer.preview,textureColor:__props.layer.color},null,8,[`textureImage`,`textureColor`])):createCommentVNode(``,!0)])],32))}},LayerTile_default=__plugin_vue_export_helper_default(_sfc_main$94,[[`__scopeId`,`data-v-87650a01`]]),_hoisted_1$85={class:`layers-manager`},_hoisted_2$72={class:`layers-manager-header`},_hoisted_3$62=[`onFocusin`];const VIEW_MODES={DEFAULT:`default`,COMPACT:`compact`};var _sfc_main$93={__name:`LayersManager`,props:mergeModels({layers:{type:Array,required:!0},view:{type:String,default:`default`,validator(value){return Object.values(VIEW_MODES).find(x=>x===value)}}},{selectedKeys:{},selectedKeysModifiers:{}}),emits:mergeModels([`focusedLayer`],[`update:selectedKeys`]),setup(__props,{emit:__emit}){let emit$1=__emit,rootStore=useLiveryEditorStore(),expandedKeys=ref([]),selectedKeys=useModel(__props,`selectedKeys`),focusLayer=ref(null),layersScrollable=ref(null);ref(!1);let isFocusFirstLayer=ref(!1);watch(()=>rootStore.selectedLayers,()=>{(!rootStore.selectedLayers||rootStore.selectedLayers.length===0)&&(rootStore.selectMode=`single`)}),watch(()=>selectedKeys.value,(newValue,oldValue)=>{(!newValue||newValue.length===0&&oldValue&&oldValue.length>0)&&(isFocusFirstLayer.value=!0)});let setMultiSelect=async node=>{rootStore.selectMode!==`multi`&&(rootStore.selectMode=`multi`,rootStore.toggleSelection(node.id,!1))},toggleEnabled=layer=>{Lua_default.extensions.ui_liveryEditor_layerAction.performAction(`enabled`).then(luaRes=>{layer.enabled=luaRes})},onClickItem=node=>{Lua_default.extensions.ui_liveryEditor_selection.select(node.id,!0),setFocusLayer(null)},setFocusLayer=layer=>{isFocusFirstLayer.value&&=!1,focusLayer.value=layer,emit$1(`focusedLayer`,layer)},handleFocusOut=event=>{setFocusLayer(null)};return(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$85,[createBaseVNode(`div`,_hoisted_2$72,[renderSlot(_ctx.$slots,`header`,{},void 0,!0)]),__props.layers?(openBlock(),createElementBlock(`div`,{key:0,ref_key:`layersScrollable`,ref:layersScrollable,class:`layers-scrollable`,onFocusout:handleFocusOut},[createVNode(unref(tree_default),{expandedKeys:expandedKeys.value,"onUpdate:expandedKeys":_cache[2]||=$event=>expandedKeys.value=$event,selectedKeys:selectedKeys.value,"onUpdate:selectedKeys":_cache[3]||=$event=>selectedKeys.value=$event,nodes:__props.layers,selectMode:unref(rootStore).selectMode,keyName:`id`,class:`layers-tree`},{node:withCtx(({node,parentNode,expanded,selected,expand})=>[node.hidden?createCommentVNode(``,!0):withDirectives((openBlock(),createElementBlock(`div`,{key:0,onFocusin:withModifiers($event=>setFocusLayer(node),[`self`]),"bng-nav-item":``,class:`layer-node`},[createVNode(LayerTile_default,{layer:node,forceShowActions:focusLayer.value&&focusLayer.value.uid===node.uid,onEnableClicked:()=>toggleEnabled(node)},null,8,[`layer`,`forceShowActions`,`onEnableClicked`]),node.children?(openBlock(),createBlock(unref(bngIcon_default),{key:0,type:expanded?unref(icons).arrowSmallUp:unref(icons).arrowSmallDown,class:`expand-icon`,onMousedown:_cache[0]||=withModifiers(()=>{},[`stop`]),onMouseup:_cache[1]||=withModifiers(()=>{},[`stop`]),onClick:withModifiers(expand,[`stop`])},null,8,[`type`,`onClick`])):createCommentVNode(``,!0)],40,_hoisted_3$62)),[[unref(BngClick_default),{clickCallback:()=>onClickItem(node),holdCallback:()=>setMultiSelect(node),repeatInterval:0}],[unref(BngUiNavFocus_default),isFocusFirstLayer.value&&__props.layers[0].uid===node.uid?0:void 0],[unref(BngFocusIf_default),isFocusFirstLayer.value&&__props.layers[0].uid===node.uid],[unref(BngOnUiNav_default),void 0,`ok`,{asMouse:!0,focusRequired:!0}]])]),_:1},8,[`expandedKeys`,`selectedKeys`,`nodes`,`selectMode`])],544)):createCommentVNode(``,!0)]))}},LayersManager_default=__plugin_vue_export_helper_default(_sfc_main$93,[[`__scopeId`,`data-v-1bc4f03d`]]),_hoisted_1$84={class:`paint-settings`},_sfc_main$92={__name:`PaintSettings`,setup(__props){let LUA_FILL_LAYER=Lua_default.extensions.ui_liveryEditor_layers_fill,paint=new Paint,color=ref({hue:.5,saturation:1,luminosity:.5});function setColor(){paint.hsl=[color.value.hue,color.value.saturation,color.value.luminosity],LUA_FILL_LAYER.updateLayer({color:paint.rgba})}return(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$84,[createVNode(unref(bngColorPicker_default),{modelValue:color.value,"onUpdate:modelValue":_cache[0]||=$event=>color.value=$event,view:`luminosity`},null,8,[`modelValue`]),createBaseVNode(`div`,null,[createVNode(unref(bngButton_default),{onClick:setColor},{default:withCtx(()=>[..._cache[1]||=[createTextVNode(`Save`,-1)]]),_:1})])]))}},PaintSettings_default=__plugin_vue_export_helper_default(_sfc_main$92,[[`__scopeId`,`data-v-66a34a99`]]),_hoisted_1$83={class:`liveryeditor-default-layout`,"bng-ui-scope":`default-layout`},_hoisted_2$71={class:`layers-manager-wrapper`},_hoisted_3$61={key:0,class:`multiselect-header`},_hoisted_4$48={class:`message`},_hoisted_5$40={class:`add-content-wrapper`},_hoisted_6$29={class:`action-tile`},_hoisted_7$25={key:1,class:`layer-settings-wrapper`,"bng-ui-scope":`layer-settings`},SETTINGS_VIEWS={edit:{label:`Edit`,value:`edit`,hideActions:!0,propertySettings:!0,disableLayersManager:!0,props:{excludeSettingTypes:[`transform`]}},order:{label:`Change Order`,value:`order`,component:LayerSortSettings_default,hideActions:!0,disableLayersManager:!0},paint:{label:`Paint`,value:`paint`,component:PaintSettings_default,hideActions:!0,disableLayersManager:!0}},HEADER_TEXT=`Livery Editor`,_sfc_main$91={__name:`DefaultLayout`,setup(__props){useUINavScope(`default-layout`);let rootStore=useLiveryEditorStore(),infoBar=useInfoBar(),{layers:layers$1}=storeToRefs(rootStore),actionsDrawer=ref(null),settingType=shallowRef(null),layerActions=computed(()=>rootStore.layerActions?{label:rootStore.selectedLayers.length===1?`${rootStore.selectedLayers[0].name} Actions`:`${rootStore.selectedLayers.length} Layers Actions`,items:rootStore.layerActions,allowOpenDrawer:!1}:void 0),headerLabel=computed(()=>rootStore.visibleLayersCount===0?`No Layers`:rootStore.visibleLayersCount+` Layer`+rootStore.visibleLayersCount>1?`s`:``),multiSelectMessage=computed(()=>{if(rootStore.selectedLayers)return rootStore.selectedLayers.length+`Layer${rootStore.selectedLayers.length>1?`s`:``}`});onMounted(()=>{getUINavServiceInstance().useCrossfire=!0});function onBack(){settingType.value?(console.log(`onBack > closed settings`),closeSettings()):rootStore.selectedLayers&&rootStore.selectedLayers.length>0?(console.log(`onBack > closed actions`),rootStore.dismissLayerActions().then()):(console.log(`onBack > catch all`),openExitDialog().then())}function onMenu(){settingType.value?closeActions():rootStore.selectedLayers&&rootStore.selectedLayers.length>0||openSaveDialog()}function closeActions(){settingType.value&&closeSettings(),rootStore.dismissLayerActions().then()}function closeSettings(){settingType.value=null}function onActionTriggered(actionItem){let setting=SETTINGS_VIEWS[actionItem.value];setting?settingType.value=setting:rootStore.onActionItemSelected(actionItem).then()}let saving=ref(!1),dialogStates=reactive({isDialogOpen:!1});async function openExitDialog(){if(dialogStates.isDialogOpen)return!0;dialogStates.isDialogOpen=!0,await rootStore.openExitDialog(),dialogStates.isDialogOpen=!1}function openSaveDialog(){if(dialogStates.isDialogOpen)return!0;saving.value=!0,dialogStates.isDialogOpen=!0,rootStore.save().then(()=>{saving.value=!1,dialogStates.isDialogOpen=!1})}function openPaintSettings(){settingType.value=SETTINGS_VIEWS.paint}let saveLabel=computed(()=>saving.value?`Saving...`:`Save`),HEADER_ITEMS=[{id:`save_editor`,section:`start`,component:shallowRef(bngButton_default),props:{icon:icons.saveAs1,accent:ACCENTS.main,label:saveLabel,disabled:saving},events:{click:openSaveDialog}},{id:`exit_editor`,section:`start`,component:shallowRef(bngButton_default),props:{icon:icons.exit,accent:ACCENTS.attention,label:`Exit`},events:{click:openExitDialog}},{id:`paint_settings`,section:`start`,component:shallowRef(bngButton_default),props:{icon:icons.exit,accent:ACCENTS.secondary,label:`Paint`},events:{click:openPaintSettings}}],headerStore=useEditorHeaderStore();watchEffect(()=>{rootStore.currentFile&&rootStore.currentFile.name&&headerStore.setPreheader(rootStore.currentFile.name)}),onMounted(()=>{headerStore.setHeader(HEADER_TEXT),headerStore.addItems(HEADER_ITEMS)}),onUnmounted(()=>{headerStore.removeItems(HEADER_ITEMS)});let NAV_HINTS=[{id:`save`,content:{type:`binding`,props:{uiEvent:`menu`},label:`Save`},action:async()=>await rootStore.save(!1)},{id:`exit`,content:{type:`binding`,props:{uiEvent:`back`},label:`Exit`},action:async()=>rootStore.openExitDialog}],ACTIONS_DRAWER_HINTS=[{id:`actions_back`,content:{type:`binding`,props:{uiEvent:`back`},label:`Back`}}],SETTINGS_NAV_HINTS=[{id:`selected_done`,content:{type:`binding`,props:{uiEvent:`menu`},label:`Done`}},{id:`selected_back`,content:{type:`binding`,props:{uiEvent:`back`},label:`Done (Return to Actions)`}}];return watchEffect(()=>{infoBar.clearHints(),settingType.value?infoBar.addHints(SETTINGS_NAV_HINTS):layerActions.value?infoBar.addHints(ACTIONS_DRAWER_HINTS):infoBar.addHints(NAV_HINTS)}),onMounted(()=>{infoBar.addHints(NAV_HINTS)}),onUnmounted(()=>{infoBar.removeHints(...NAV_HINTS.map(x=>x.id))}),(_ctx,_cache)=>withDirectives((openBlock(),createElementBlock(`div`,_hoisted_1$83,[createBaseVNode(`div`,_hoisted_2$71,[withDirectives((openBlock(),createBlock(unref(LayersManager_default),{selectedKeys:unref(rootStore).selectedLayerUids,"onUpdate:selectedKeys":_cache[0]||=$event=>unref(rootStore).selectedLayerUids=$event,layers:unref(layers$1),class:normalizeClass({inactive:settingType.value&&settingType.value.disableLayersManager})},{header:withCtx(()=>[createVNode(unref(bngCardHeading_default),{type:`ribbon`},{default:withCtx(()=>[createTextVNode(toDisplayString(headerLabel.value),1)]),_:1}),unref(rootStore).selectMode===`multi`?(openBlock(),createElementBlock(`div`,_hoisted_3$61,[withDirectives((openBlock(),createBlock(unref(bngButton_default),{accent:unref(ACCENTS).attention,onClick:closeActions,class:`cancel-btn`},{default:withCtx(()=>[..._cache[1]||=[createTextVNode(`Cancel`,-1)]]),_:1},8,[`accent`])),[[unref(BngOnUiNav_default),void 0,`ok`,{asMouse:!0,focusRequired:!0}]]),createBaseVNode(`span`,_hoisted_4$48,toDisplayString(multiSelectMessage.value),1)])):withDirectives((openBlock(),createBlock(unref(bngButton_default),{key:1,accent:unref(ACCENTS).outlined,disabled:unref(rootStore).selectedLayers&&unref(rootStore).selectedLayers.length>0,onClick:unref(rootStore).toggleEditModeLayout},{default:withCtx(()=>[createBaseVNode(`span`,_hoisted_5$40,[createVNode(unref(bngIcon_default),{type:unref(icons).plus},null,8,[`type`]),_cache[2]||=createBaseVNode(`span`,{class:`add-label`},`Add Decal`,-1)])]),_:1},8,[`accent`,`disabled`,`onClick`])),[[unref(BngOnUiNav_default),void 0,`ok`,{asMouse:!0,focusRequired:!0}]])]),_:1},8,[`selectedKeys`,`layers`,`class`])),[[unref(BngBlur_default)]])]),layerActions.value&&(!settingType.value||!settingType.value.hideActions)?(openBlock(),createBlock(unref(bngActionDrawer_default),{key:0,ref_key:`actionsDrawer`,ref:actionsDrawer,actions:layerActions.value,"item-width":10,"item-margin":1,class:`actions-drawer`,onSelect:onActionTriggered},{controls:withCtx(()=>[withDirectives(createVNode(unref(bngButton_default),{accent:unref(ACCENTS).outlined,icon:unref(icons).abandon,onClick:closeActions},null,8,[`accent`,`icon`]),[[unref(BngOnUiNav_default),void 0,`ok`,{asMouse:!0,focusRequired:!0}]])]),action:withCtx(({item,isLoading,select})=>[createBaseVNode(`div`,_hoisted_6$29,[withDirectives(createVNode(unref(bngImageTile_default),{label:item.toggleAction&&!item.active?item.inactiveLabel:item.label,icon:item.toggleAction&&!item.active?item.inactiveIcon:item.icon,externalImage:item.preview,"bng-nav-item":``,class:`action-tile`,onClick:$event=>select(item)},null,8,[`label`,`icon`,`externalImage`,`onClick`]),[[unref(BngOnUiNav_default),void 0,`ok`,{asMouse:!0,focusRequired:!0}]])])]),_:1},8,[`actions`])):createCommentVNode(``,!0),settingType.value?(openBlock(),createElementBlock(`div`,_hoisted_7$25,[settingType.value.propertySettings?(openBlock(),createBlock(unref(LayerSettings_default),normalizeProps(mergeProps({key:0},settingType.value.props)),null,16)):withDirectives((openBlock(),createBlock(unref(LayerSettingsBase_default),{key:1,heading:settingType.value.label},{default:withCtx(()=>[(openBlock(),createBlock(resolveDynamicComponent(settingType.value.component)))]),_:1},8,[`heading`])),[[unref(BngBlur_default)]])])):createCommentVNode(``,!0)])),[[unref(BngOnUiNav_default),onBack,`back`],[unref(BngOnUiNav_default),onMenu,`menu`]])}},DefaultLayout_default=__plugin_vue_export_helper_default(_sfc_main$91,[[`__scopeId`,`data-v-6dca75f9`]]),_hoisted_1$82={class:`editor`,"bng-ui-scope":`livery-editor`},_hoisted_2$70={class:`editor-header-wrapper`},EDITOR_VIEWS_COMPONENT={[EDITOR_VIEWS.decalSelector]:DecalSelector_default,[EDITOR_VIEWS.editMode]:EditModeLayout_default,[EDITOR_VIEWS.default]:DefaultLayout_default},_sfc_main$90={__name:`LiveryEditor`,setup(__props){let store$1=useLiveryEditorStore(),infobar=useInfoBar(),{showIfController}=storeToRefs(controls_default());infobar.visible=!0;let currentView=computed(()=>EDITOR_VIEWS_COMPONENT[store$1.editorView]),minimizedMode=ref(!1);watch(showIfController,value=>{store$1.setUseMousePos(!value)}),onBeforeMount(async()=>{await store$1.startEditor(),store$1.setUseMousePos(!showIfController.value)});let HEADER_ITEMS=[{id:`camera_view`,section:`end`,component:shallowRef(CameraViewButton_default)}],headerStore=useEditorHeaderStore();return onMounted(()=>{headerStore.setPreheader(store$1.currentFile?store$1.currentFile:`New Save`),headerStore.addItems(HEADER_ITEMS)}),onUnmounted(()=>{headerStore.removeItems(HEADER_ITEMS)}),(_ctx,_cache)=>withDirectives((openBlock(),createElementBlock(`div`,_hoisted_1$82,[createBaseVNode(`div`,_hoisted_2$70,[createVNode(unref(LiveryEditorHeader_default))]),createBaseVNode(`div`,{class:normalizeClass([`editor-content`,{"layers-collapse":minimizedMode.value}])},[(openBlock(),createBlock(resolveDynamicComponent(currentView.value)))],2)])),[[unref(BngOnUiNav_default),()=>{},`menu,back,ok`]])}},LiveryEditor_default=__plugin_vue_export_helper_default(_sfc_main$90,[[`__scopeId`,`data-v-27ec64b0`]]),_hoisted_1$81={class:`livery-main-view`,"bng-ui-scope":`livery-main-scope`},_hoisted_2$69={key:0,class:`loading-overlay`},_hoisted_3$60={class:`header`},_hoisted_4$47={class:`main-view-content`},_hoisted_5$39={class:`menu-container`},MENU_ITEMS$2=[{label:`Paint`,value:`paint`,icon:icons.colorPalette},{label:`Decals`,value:`decals`,icon:icons.decal},{label:`Settings`,value:`settings`,icon:icons.gearTuningOutline}],blockedEvents=[`tab_l`,`tab_r`],_sfc_main$89={__name:`LiveryMainNew`,setup(__props){let infobar=useInfoBar(),uiNavBlocker=useUINavBlocker(),store$1=useLiveryMainStore(),headerStore=useEditorHeaderStore();useUINavScope(`livery-main-scope`);function onMenuItemClicked(item){switch(item){case`paint`:window.bngVue.gotoGameState(`LiveryPaint`);break;case`decals`:window.bngVue.gotoGameState(`LiveryDecals`);break;case`settings`:window.bngVue.gotoGameState(`LiverySettings`);break}}let openedDialog=ref(null);onBeforeMount(async()=>{await store$1.setup(),headerStore.setHeader(`Livery Editor`),headerStore.setPreheader(null)}),onMounted(()=>{infobar.visible=!0,infobar.showSysInfo=!0,uiNavBlocker.blockOnly(blockedEvents)}),onUnmounted(()=>{uiNavBlocker.clear()});function exit(){store$1.exit().then(()=>{window.bngVue.gotoGameState(`garagemode`)})}function promptSave(){openedDialog.value||(openedDialog.value=`save`,openPrompt(`Enter save name`,`Save`,{buttons:[{label:`Save`,value:text=>({value:1,text}),extras:{default:!0}},{label:`Save and Exit`,value:text=>({value:-1,text}),extras:{accent:ACCENTS.secondary}},{label:`Cancel`,value:text=>({value:0,text}),extras:{cancel:!0,accent:ACCENTS.attention}}],defaultValue:store$1.currentSave.name}).then(res=>{let{value,text}=res;value!==0&&(store$1.currentSave.name=text,store$1.save().then(()=>{value===-1&&openProgress(`Saving and exporting skin...`,`Save`,{cancellable:!1,indeterminate:!0,timeout:1}).promise.then(()=>exit())}),openedDialog.value=null)}))}function promptBack(event){if(openedDialog.value){event.stopPropagation();return}openedDialog.value=`back`,openConfirmation(`Save`,`Save your changes`,[{label:`Save`,value:1,extras:{default:!0}},{label:`Exit (discard changes)`,value:-1,extras:{accent:ACCENTS.attention}},{label:`Cancel`,value:0,extras:{cancel:!0,accent:ACCENTS.secondary}}]).then(res=>{openedDialog.value=null,res===1?promptSave():res===-1&&exit()}),event.stopPropagation()}return(_ctx,_cache)=>withDirectives((openBlock(),createElementBlock(`div`,_hoisted_1$81,[unref(store$1).isSetupDone?createCommentVNode(``,!0):(openBlock(),createElementBlock(`div`,_hoisted_2$69,[..._cache[0]||=[createBaseVNode(`h1`,{class:`text`},`Loading...`,-1)]])),createBaseVNode(`div`,_hoisted_3$60,[createVNode(unref(LiveryEditorHeader_default))]),createBaseVNode(`div`,_hoisted_4$47,[createBaseVNode(`div`,_hoisted_5$39,[(openBlock(),createElementBlock(Fragment,null,renderList(MENU_ITEMS$2,(item,index)=>withDirectives(createVNode(unref(bngImageTile_default),{"bng-nav-item":``,key:item.value,label:item.label,icon:item.icon,onClick:$event=>onMenuItemClicked(item.value)},null,8,[`label`,`icon`,`onClick`]),[[unref(BngBlur_default)],[unref(BngUiNavFocus_default),MENU_ITEMS$2.length-index]])),64))])])])),[[unref(BngOnUiNav_default),promptBack,`menu`],[unref(BngOnUiNav_default),promptBack,`back`],[unref(BngUiNavLabel_default),`Save/Exit`,`menu,back`]])}},LiveryMainNew_default=__plugin_vue_export_helper_default(_sfc_main$89,[[`__scopeId`,`data-v-a9fbf094`]]),_hoisted_1$80={class:`save-info-container`},_hoisted_2$68={class:`file-name`},_hoisted_3$59={class:`file-modified`},_hoisted_4$46={class:`file-size`},_hoisted_5$38={key:0,class:`save-file-actions`},_sfc_main$88=Object.assign({width:14,height:6,margin:.25},{__name:`FileListItem`,props:{name:{type:String,required:!0},location:{type:String,required:!0},modifiedFormatted:String,fileSizeFormatted:String,selected:Boolean},setup(__props){let store$1=useLiveryFileStore(),mainStore=useLiveryMainStore(),props=__props,activated=ref(!1),openedDialog=ref(null);function load(){mainStore.load(props),window.bngVue.gotoGameState(`LiveryMain`)}function rename(){let model={name:props.name};nextTick(()=>{openedDialog.value=`rename`}),openFormDialog(FileEditForm_default,model,model$1=>model$1.name!==null&&model$1.name!==void 0&&model$1.name!==``,`Rename file`,`Enter new name`).then(res=>{res.value&&store$1.renameFile(props,res.formData.name),forceActivateScope()})}function deleteSave(){openConfirmation(`Delete`,`Are you sure you want to delete ${props.name}`).then(res=>{res?store$1.deleteFile(props):forceActivateScope()})}function onActivate$1(activate){activated.value=activate,nextTick(()=>{activate&&openedDialog.value&&(openedDialog.value=null)})}function forceActivateScope(){nextTick(()=>{activated.value=!0})}return(_ctx,_cache)=>withDirectives((openBlock(),createElementBlock(`div`,{class:`file-list-item`,onActivate:_cache[0]||=$event=>onActivate$1(!0),onDeactivate:_cache[1]||=$event=>onActivate$1(!1)},[createBaseVNode(`div`,_hoisted_1$80,[createBaseVNode(`div`,_hoisted_2$68,toDisplayString(__props.name),1),createBaseVNode(`div`,_hoisted_3$59,toDisplayString(__props.modifiedFormatted),1),createBaseVNode(`div`,_hoisted_4$46,toDisplayString(__props.fileSizeFormatted),1)]),__props.selected?(openBlock(),createElementBlock(`div`,_hoisted_5$38,[createVNode(unref(bngButton_default),{icon:unref(icons).import,onClick:load},null,8,[`icon`]),createVNode(unref(bngButton_default),{icon:unref(icons).rename,accent:unref(ACCENTS).secondary,onClick:rename},null,8,[`icon`,`accent`]),createVNode(unref(bngButton_default),{icon:unref(icons).trashBin2,accent:unref(ACCENTS).attention,onClick:deleteSave},null,8,[`icon`,`accent`])])):createCommentVNode(``,!0)],32)),[[unref(BngScopedNav_default),{activated:activated.value}]])}}),FileListItem_default=__plugin_vue_export_helper_default(_sfc_main$88,[[`__scopeId`,`data-v-46a472ab`]]),_hoisted_1$79={class:`livery-manager-view`,"bng-ui-scope":`livery-manager-scope`},_hoisted_2$67={class:`header`},_hoisted_3$58={class:`main-view-content`},_hoisted_4$45={key:1,class:`empty-save-container`},_hoisted_5$37={class:`empty-save-message`},_hoisted_6$28={key:1,class:`menu-container`},_sfc_main$87={__name:`LiveryManager`,setup(__props){let store$1=useLiveryFileStore(),mainStore=useLiveryMainStore(),headerStore=useEditorHeaderStore(),infobar=useInfoBar(),uiNavBlocker=useUINavBlocker();useUINavScope(`livery-manager-scope`);let{files}=storeToRefs(store$1),selectedSave=ref(null),screenState=reactive({isOpenLiveries:!1}),MENU_ITEMS$4=[{label:`New Livery`,value:`new`,icon:icons.plus,action:onCreateNew},{label:`Open Liveries`,value:`load`,icon:icons.decal,action:onOpenLiveries}];watch(()=>files.value,()=>selectedSave.value=null,{deep:!0}),onBeforeMount(()=>{store$1.init()}),onMounted(()=>{headerStore.setHeader(`Livery Editor`),headerStore.setPreheader(null),uiNavBlocker.blockOnly([`tab_l`,`tab_r`]),infobar.visible=!0}),onUnmounted(()=>{uiNavBlocker.clear()});function onCreateNew(){mainStore.isSetupDone=!1,window.bngVue.gotoGameState(`LiveryMain`)}function onOpenLiveries(){screenState.isOpenLiveries=!0,headerStore.setPreheader(`Liveries`)}function goBack(event){screenState.isOpenLiveries?(screenState.isOpenLiveries=!1,selectedSave.value=null):window.bngVue.gotoGameState(`garagemode`),event.stopPropagation()}return(_ctx,_cache)=>withDirectives((openBlock(),createElementBlock(`div`,_hoisted_1$79,[createBaseVNode(`div`,_hoisted_2$67,[createVNode(unref(LiveryEditorHeader_default))]),createBaseVNode(`div`,_hoisted_3$58,[screenState.isOpenLiveries?(openBlock(),createElementBlock(Fragment,{key:0},[unref(files)&&unref(files).length>0?withDirectives((openBlock(),createBlock(unref(bngList_default),{key:0,layout:unref(LIST_LAYOUTS).LIST,"target-width":14,"target-height":6,"target-margin":.25,big:!0,class:`files-list`},{default:withCtx(()=>[(openBlock(!0),createElementBlock(Fragment,null,renderList(unref(files),(file$1,index)=>withDirectives((openBlock(),createBlock(FileListItem_default,mergeProps({ref_for:!0},file$1,{key:file$1.name,selected:selectedSave.value===index,onFocus:$event=>selectedSave.value=index,onClick:$event=>selectedSave.value=index}),null,16,[`selected`,`onFocus`,`onClick`])),[[unref(BngFocusIf_default),selectedSave.value===null&&index===0]])),128))]),_:1},8,[`layout`])),[[unref(BngBlur_default)]]):(openBlock(),createElementBlock(`div`,_hoisted_4$45,[withDirectives((openBlock(),createElementBlock(`div`,_hoisted_5$37,[..._cache[0]||=[createTextVNode(`No saved liveries`,-1)]])),[[unref(BngBlur_default)]])]))],64)):(openBlock(),createElementBlock(`div`,_hoisted_6$28,[(openBlock(),createElementBlock(Fragment,null,renderList(MENU_ITEMS$4,(item,index)=>withDirectives(createVNode(unref(bngImageTile_default),{key:item.value,label:item.label,icon:item.icon,onClick:item.action},null,8,[`label`,`icon`,`onClick`]),[[unref(BngUiNavFocus_default),MENU_ITEMS$4.length-index],[unref(BngBlur_default)]])),64))]))])])),[[unref(BngOnUiNav_default),goBack,`back,menu`],[unref(BngUiNavLabel_default),`Back`,`back,menu`]])}},LiveryManager_default=__plugin_vue_export_helper_default(_sfc_main$87,[[`__scopeId`,`data-v-8e7dbe60`]]),_hoisted_1$78={class:`material-settings-content`},_hoisted_2$66={class:`color-values-container`,"bng-no-child-nav":``},_sfc_main$86={__name:`MaterialSettings`,props:{initialColor:Array},emits:[`change`],setup(__props,{emit:__emit}){let props=__props,emit$1=__emit,paint=new Paint,color=ref({hue:.5,saturation:1,luminosity:.5}),inputHue=computed({get:()=>color.value.hue.toFixed(3),set:newValue=>{color.value.hue=typeof newValue==`string`?+newValue:newValue,notifyListeners()}}),inputSat=computed({get:()=>color.value.saturation.toFixed(3),set:newValue=>{color.value.saturation=typeof newValue==`string`?+newValue:newValue,notifyListeners()}}),inputLum=computed({get:()=>color.value.luminosity.toFixed(3),set:newValue=>{color.value.luminosity=typeof newValue==`string`?+newValue:newValue,notifyListeners()}}),isPreciseActive=ref(!1),colorPickerStep=computed(()=>isPreciseActive.value?.001:.01);watch(()=>props.initialColor,()=>{props.initialColor&&(paint.rgba=props.initialColor,color.value.hue=paint.hsl[0],color.value.saturation=paint.hsl[1],color.value.luminosity=paint.hsl[2])},{deep:!0,immediate:!0});function notifyListeners(){let hsl=[color.value.hue,color.value.saturation,color.value.luminosity];paint.hsl=hsl,emit$1(`change`,{colorHsl:hsl,colorRgb:paint.rgb})}function handleAction2(element){isPreciseActive.value=element.detail.value===1}return(_ctx,_cache)=>withDirectives((openBlock(),createBlock(unref(LayerSettingsBase_default),{class:`material-settings`},{heading:withCtx(()=>[..._cache[4]||=[createTextVNode(`Color`,-1)]]),default:withCtx(()=>[createBaseVNode(`div`,_hoisted_1$78,[createVNode(unref(bngColorPicker_default),{modelValue:color.value,"onUpdate:modelValue":_cache[0]||=$event=>color.value=$event,step:colorPickerStep.value,onChange:notifyListeners},null,8,[`modelValue`,`step`]),createBaseVNode(`div`,_hoisted_2$66,[createVNode(unref(bngInput_default),{prefix:`h`,modelValue:inputHue.value,"onUpdate:modelValue":_cache[1]||=$event=>inputHue.value=$event},null,8,[`modelValue`]),createVNode(unref(bngInput_default),{prefix:`s`,modelValue:inputSat.value,"onUpdate:modelValue":_cache[2]||=$event=>inputSat.value=$event},null,8,[`modelValue`]),createVNode(unref(bngInput_default),{prefix:`b`,modelValue:inputLum.value,"onUpdate:modelValue":_cache[3]||=$event=>inputLum.value=$event},null,8,[`modelValue`])])])]),_:1})),[[unref(BngUiNavLabel_default),`[Hold] Precise`,`action_2`],[unref(BngOnUiNav_default),handleAction2,`action_2`,{up:!0}],[unref(BngOnUiNav_default),handleAction2,`action_2`,{down:!0}]])}},MaterialSettings_default=__plugin_vue_export_helper_default(_sfc_main$86,[[`__scopeId`,`data-v-45b64f6e`]]),_hoisted_1$77={class:`paint-main-view`,"bng-ui-scope":`paint-main-scope`},_hoisted_2$65={class:`header`},_hoisted_3$57={class:`paint-content-container`},_hoisted_4$44={class:`paint-content`},_sfc_main$85={__name:`LiveryPaintMain`,setup(__props){let store$1=useLiveryMainStore(),headerStore=useEditorHeaderStore(),infobar=useInfoBar(),uiNavBlocker=useUINavBlocker(),{events:events$3}=useBridge();useUINavScope(`paint-main-scope`);let initialColor=ref(null),blockedEvents$1=[`tab_r`,`tab_l`];onMounted(()=>{headerStore.setPreheader([`Paint`]),store$1.setup(),infobar.visible=!0,infobar.showSysInfo=!0,uiNavBlocker.blockOnly(blockedEvents$1),events$3.on(`liveryEditor_fill_layerData`,onLayerData),Lua_default.extensions.ui_liveryEditor_layers_fill.requestLayerData()}),onUnmounted(()=>{uiNavBlocker.clear(),events$3.off(`liveryEditor_fill_layerData`)});function onLayerData(data){console.log(`layer data changed`,data),initialColor.value=data.color}function saveChanges(){Lua_default.extensions.ui_liveryEditor_layers_fill.saveChanges().then(()=>{window.bngVue.gotoGameState(`LiveryMain`)})}function restoreDefault(){Lua_default.extensions.ui_liveryEditor_layers_fill.restoreDefault()}function cancelChanges(){openConfirmation(`Undo Changes`,`Lose unsaved changes?`).then(res=>{res&&(Lua_default.extensions.ui_liveryEditor_layers_fill.restoreLayer(),window.bngVue.gotoGameState(`LiveryMain`))})}function onMaterialValueChanged(data){Lua_default.extensions.ui_liveryEditor_layers_fill.updateLayer({color:data.colorRgb})}return(_ctx,_cache)=>withDirectives((openBlock(),createElementBlock(`div`,_hoisted_1$77,[createBaseVNode(`div`,_hoisted_2$65,[createVNode(unref(LiveryEditorHeader_default))]),createBaseVNode(`div`,_hoisted_3$57,[createBaseVNode(`div`,_hoisted_4$44,[withDirectives(createVNode(MaterialSettings_default,{"initial-color":initialColor.value,onChange:onMaterialValueChanged},null,8,[`initial-color`]),[[unref(BngBlur_default)]]),withDirectives((openBlock(),createBlock(unref(bngButton_default),{onClick:saveChanges},{default:withCtx(()=>[createVNode(unref(bngBinding_default),{controller:``,"ui-event":`context`}),_cache[0]||=createBaseVNode(`span`,null,`Apply`,-1)]),_:1})),[[unref(BngOnUiNav_default),void 0,`context`,{asMouse:!0}]]),withDirectives((openBlock(),createBlock(unref(bngButton_default),{accent:`secondary`,onClick:restoreDefault},{default:withCtx(()=>[createVNode(unref(bngBinding_default),{controller:``,"ui-event":`action_3`}),_cache[1]||=createBaseVNode(`span`,null,`Restore Default`,-1)]),_:1})),[[unref(BngOnUiNav_default),void 0,`action_3`,{asMouse:!0}]])])])])),[[unref(BngOnUiNav_default),cancelChanges,`back,menu`],[unref(BngUiNavLabel_default),`Back`,`back,menu`]])}},LiveryPaintMain_default=__plugin_vue_export_helper_default(_sfc_main$85,[[`__scopeId`,`data-v-74e232cb`]]),_hoisted_1$76={class:`layer-inspector-base`},_hoisted_2$64={class:`inspector-heading`},_hoisted_3$56={class:`inspector-content`},_sfc_main$84={__name:`LayerInspectorBase`,props:{heading:{type:String}},setup(__props){return useSlots(),(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$76,[createBaseVNode(`div`,_hoisted_2$64,[createVNode(unref(bngCardHeading_default),{type:`ribbon`},{default:withCtx(()=>[renderSlot(_ctx.$slots,`heading`,{},()=>[createBaseVNode(`span`,null,toDisplayString(__props.heading),1)],!0)]),_:3})]),createBaseVNode(`div`,_hoisted_3$56,[renderSlot(_ctx.$slots,`default`,{},void 0,!0)])]))}},LayerInspectorBase_default=__plugin_vue_export_helper_default(_sfc_main$84,[[`__scopeId`,`data-v-c60f30a4`]]),_hoisted_1$75={class:`direction-buttons-row`},_hoisted_2$63={class:`icon-binding-wrapper`},_hoisted_3$55={class:`icon-binding-wrapper`},_hoisted_4$43={class:`direction-buttons-row`},_hoisted_5$36={class:`icon-binding-wrapper`},_hoisted_6$27={class:`stacked-arrows`},_hoisted_7$24={class:`icon-binding-wrapper`},_hoisted_8$19={class:`stacked-arrows`},_hoisted_9$17={class:`dropdown-container`},_sfc_main$83={__name:`LayerOrder`,setup(__props){let ORDER_TOOL$1=Lua_default.extensions.ui_liveryEditor_tools_group,store$1=useLiveryEditorStore(),_order=ref(2),order=computed({get:()=>_order.value,set(newValue){_order.value=newValue,ORDER_TOOL$1.setOrder(newValue)}});computed(()=>store$1.selectedLayers[0].siblingCount);let orderOptions=computed(()=>Array.from({length:store$1.layers.length-1},(_,i)=>({label:`${i+1}`,value:i+2})));onMounted(()=>{store$1.selectedLayers&&store$1.selectedLayers.length>0&&(_order.value=store$1.selectedLayers[0].order)});let moveUp=()=>{ORDER_TOOL$1.moveOrderUp().then(value=>_order.value=value)},moveDown=()=>{ORDER_TOOL$1.moveOrderDown().then(value=>_order.value=value)},moveToTop=()=>{ORDER_TOOL$1.changeOrderToTop().then(value=>_order.value=value)},moveToBottom=()=>{ORDER_TOOL$1.changeOrderToBottom().then(value=>_order.value=value)};return(_ctx,_cache)=>withDirectives((openBlock(),createBlock(LayerInspectorBase_default,{heading:`Order`},{default:withCtx(()=>[createBaseVNode(`div`,_hoisted_1$75,[withDirectives((openBlock(),createBlock(unref(bngTile_default),{"bng-nav-item":``,label:`Move Up`,onClick:moveUp},{default:withCtx(()=>[createBaseVNode(`div`,_hoisted_2$63,[createVNode(unref(bngIcon_default),{type:unref(icons).arrowLargeUp},null,8,[`type`])])]),_:1})),[[unref(BngOnUiNav_default),moveUp,`ok`,{focusRequired:!0}]]),withDirectives((openBlock(),createBlock(unref(bngTile_default),{"bng-nav-item":``,label:`Move Down`,onClick:moveDown},{default:withCtx(()=>[createBaseVNode(`div`,_hoisted_3$55,[createVNode(unref(bngIcon_default),{type:unref(icons).arrowLargeDown},null,8,[`type`])])]),_:1})),[[unref(BngOnUiNav_default),moveDown,`ok`,{focusRequired:!0}]])]),createBaseVNode(`div`,_hoisted_4$43,[withDirectives((openBlock(),createBlock(unref(bngTile_default),{"bng-nav-item":``,label:`Move to Top`,onClick:moveToTop},{default:withCtx(()=>[createBaseVNode(`div`,_hoisted_5$36,[createBaseVNode(`div`,_hoisted_6$27,[createVNode(unref(bngIcon_default),{type:unref(icons).arrowLargeUp},null,8,[`type`]),createVNode(unref(bngIcon_default),{type:unref(icons).arrowLargeUp},null,8,[`type`])])])]),_:1})),[[unref(BngOnUiNav_default),moveToTop,`ok`,{focusRequired:!0}]]),withDirectives((openBlock(),createBlock(unref(bngTile_default),{"bng-nav-item":``,label:`Move to Bottom`,onClick:moveToBottom},{default:withCtx(()=>[createBaseVNode(`div`,_hoisted_7$24,[createBaseVNode(`div`,_hoisted_8$19,[createVNode(unref(bngIcon_default),{type:unref(icons).arrowLargeDown,disabled:unref(store$1).selectedLayers.length>1},null,8,[`type`,`disabled`]),createVNode(unref(bngIcon_default),{type:unref(icons).arrowLargeDown,disabled:unref(store$1).selectedLayers.length>1},null,8,[`type`,`disabled`])])])]),_:1})),[[unref(BngOnUiNav_default),moveToBottom,`ok`,{focusRequired:!0}]])]),createBaseVNode(`div`,_hoisted_9$17,[createVNode(unref(bngDropdown_default),{modelValue:order.value,"onUpdate:modelValue":_cache[0]||=$event=>order.value=$event,items:orderOptions.value},null,8,[`modelValue`,`items`])])]),_:1})),[[unref(BngBlur_default)]])}},LayerOrder_default=__plugin_vue_export_helper_default(_sfc_main$83,[[`__scopeId`,`data-v-d8fda3d9`]]),_hoisted_1$74={class:`decals-main-view`,"bng-ui-scope":`decals-main-scope`},_hoisted_2$62={class:`header`},_hoisted_3$54={class:`main-view-content`},_hoisted_4$42={class:`add-content-wrapper`},_hoisted_5$35={class:`action-tile`},_hoisted_6$26={key:1,class:`popup-settings`},CAMERA_BUTTONS$1=[{label:`Right`,icon:icons.cameraSideRight,value:`right`},{label:`Front`,icon:icons.cameraFront1,value:`front`},{label:`Left`,icon:icons.cameraSideLeft,value:`left`},{label:`Back`,icon:icons.cameraBack1,value:`back`},{label:`Top Right`,icon:icons.cameraTop1,value:`topright`},{label:`Top Left`,icon:icons.cameraTop1,value:`topleft`},{label:`Top Front`,icon:icons.cameraTop1,value:`topfront`},{label:`Top Back`,icon:icons.cameraTop1,value:`topback`}],BLOCKED_UINAV_EVENTS$1=[`tab_l`,`tab_r`],SHOW_HIDE_DECAL_EVENT=`action_2`,_sfc_main$82={__name:`LiveryDecalsMain`,setup(__props){let ACTION_ITEM_ICON={requestReproject:icons.view,transform:icons.transform,materials:icons.colorPalette,highlight:icons.lightGarageG11,requestMirror:icons.reflect,order:icons.sortAscDown,enabled:icons.eyeOutlineOpened,"enabled-off":icons.eyeOutlineClosed,delete:icons.trashBin1,duplicate:icons.copy},layerActionsState=reactive({mirrored:!1,mirrorFlipped:!1,highlight:!0,enabled:!0}),MIRROR_ITEMS=[{label:`Mirror`,value:`mirror`,isSwitch:!0,switchValue:toRef(layerActionsState,`mirrored`)},{label:`Flip Mirrored`,value:`flipMirrored`,isSwitch:!0,switchValue:toRef(layerActionsState,`mirrorFlipped`),disabled:computed(()=>!layerActionsState.mirrored)}],headerStore=useEditorHeaderStore(),infobar=useInfoBar();useUINavScope(`decals-main-scope`);let uiNavBlocker=useUINavBlocker(),{events:events$3}=useBridge(),layers$1=ref([]),selectedLayers=ref([]),layerActions=ref([]),allowActionsDrawerShow=ref(!0),actionDrawer=ref(null),currentActionDrawerLevel=ref(null),popupSettings=ref(null),isReprojectActive=ref(!1),focusedLayer=ref(null),selectedLayerKeys=computed(()=>selectedLayers.value?selectedLayers.value.map(x=>x.uid):null),actionsDrawerData=computed(()=>{let layerName=selectedLayers.value&&selectedLayers.value.length>0?selectedLayers.value[0].name:null;return layerActions.value&&layerActions.value.length>0?{label:layerName,items:layerActions.value,allowOpenDrawer:!1}:void 0}),contextUIEventLabel=computed(()=>isReprojectActive.value?`Reproject`:`Add Decal`),action2UIEventLabel=computed(()=>focusedLayer.value||selectedLayers.value&&selectedLayers.value.length>0?`Enable/Disable Decal`:void 0);watchEffect(()=>{let eventsToBlock=[...BLOCKED_UINAV_EVENTS$1];uiNavBlocker.clear(),(isReprojectActive.value||!focusedLayer.value&&(!selectedLayers.value||selectedLayers.value.length===0))&&eventsToBlock.push(SHOW_HIDE_DECAL_EVENT),uiNavBlocker.blockOnly(eventsToBlock)}),onBeforeMount(()=>{headerStore.setPreheader([`Decals`])}),onMounted(()=>{infobar.visible=!0,infobar.showSysInfo=!0,events$3.on(`liveryEditor_OnLayersUpdated`,onLayersUpdated),events$3.on(`liveryEditor_selection_actionsUpdated`,onActionsUpdated),events$3.on(`liveryEditor_selection_selectedChanged`,onSelectedChanged),Lua_default.extensions.ui_liveryEditor_layers.requestInitialData(),Lua_default.extensions.ui_liveryEditor_selection.requestInitialData()}),onBeforeUnmount(()=>{events$3.off(`liveryEditor_OnLayersUpdated`,onLayersUpdated),events$3.off(`liveryEditor_selection_actionsUpdated`,onActionsUpdated),events$3.off(`liveryEditor_selection_selectedChanged`,onSelectedChanged)});function onBack(event){popupSettings.value?(popupSettings.value=null,allowActionsDrawerShow.value=!0):actionsDrawerData.value?handleDrawerBack():window.bngVue.gotoGameState(`LiveryMain`),event.stopPropagation()}function addDecal(){window.bngVue.gotoGameState(`LiveryDecalSelector`)}let isReproject;async function onActionSwitchClicked(item){item.switchValue=await Lua_default.extensions.ui_liveryEditor_layerAction.performAction(item.value)}async function onActionTriggered(item){if(!item.value){currentActionDrawerLevel.value===`requestReproject`&&!isReproject&&await Lua_default.extensions.ui_liveryEditor_layerAction.performAction(`cancelReproject`),isReprojectActive.value=!1,isReproject=!1,currentActionDrawerLevel.value=null;return}if((item.lazyLoadItems||item.items)&&(currentActionDrawerLevel.value=item.value),item.value===`requestReproject`){if(!item.items){let timeoutid=setTimeout(()=>{item.items=CAMERA_BUTTONS$1,clearTimeout(timeoutid)},500)}isReprojectActive.value=!0}else if(item.value===`requestMirror`){item.items=MIRROR_ITEMS;return}else if(item.value===`order`){allowActionsDrawerShow.value=!1,popupSettings.value=markRaw(LayerOrder_default);return}else if(CAMERA_BUTTONS$1.find(x=>x.value===item.value)){await Lua_default.extensions.ui_liveryEditor_camera.setOrthographicView(item.value);return}await Lua_default.extensions.ui_liveryEditor_layerAction.performAction(item.value)}function onLayersUpdated(data){layers$1.value=data}function onActionsUpdated(data){if(layerActions.value=data,data&&Array.isArray(data)&&data.length>0){let highlightAction=layerActions.value.find(x=>x.value===`highlight`);highlightAction.switchValue=toRef(layerActionsState,`highlight`)}}function onSelectedChanged(data){if(selectedLayers.value=data,data&&Array.isArray(data)&&data.length>0){let first=data[0];layerActionsState.highlight=first.highlighted,layerActionsState.mirrored=first.mirrored,layerActionsState.mirrorFlipped=first.mirrorFlipped}}let closeActionDrawer=()=>{currentActionDrawerLevel.value&¤tActionDrawerLevel.value===`requestReproject`&&(Lua_default.extensions.ui_liveryEditor_layerAction.performAction(`cancelReproject`).then(()=>{}),currentActionDrawerLevel.value=null),Lua_default.extensions.ui_liveryEditor_selection.clearSelection()};function handleDrawerBack(){currentActionDrawerLevel.value?actionDrawer.value.goBack():closeActionDrawer()}function onFocusedLayer(layer){focusedLayer.value=layer}let toggleEnabled=()=>{if(focusedLayer.value)Lua_default.extensions.ui_liveryEditor_layerAction.toggleEnabledByLayerUid(focusedLayer.value.uid);else if(selectedLayers.value&&selectedLayers.value.length>0){let layer=selectedLayers.value[0];Lua_default.extensions.ui_liveryEditor_layerAction.performAction(`enabled`).then(luaRes=>{layer.enabled=luaRes})}},handleContext=()=>{isReprojectActive.value?Lua_default.extensions.ui_liveryEditor_layerAction.performAction(`reproject`).then(()=>{isReproject=!0,isReprojectActive.value=!1,actionDrawer.value.goBack()}):popupSettings.value||addDecal()},handleAction2=()=>{if(isReprojectActive.value)return!1;toggleEnabled()};return(_ctx,_cache)=>withDirectives((openBlock(),createElementBlock(`div`,_hoisted_1$74,[createBaseVNode(`div`,_hoisted_2$62,[createVNode(unref(LiveryEditorHeader_default))]),createBaseVNode(`div`,_hoisted_3$54,[withDirectives((openBlock(),createBlock(unref(LayersManager_default),{selectedKeys:selectedLayerKeys.value,"onUpdate:selectedKeys":_cache[0]||=$event=>selectedLayerKeys.value=$event,layers:layers$1.value,class:`layers-manager`,onFocusedLayer},{header:withCtx(()=>[createVNode(unref(bngCardHeading_default),{type:`ribbon`},{default:withCtx(()=>[..._cache[1]||=[createTextVNode(`Layers`,-1)]]),_:1}),withDirectives((openBlock(),createBlock(unref(bngButton_default),{"bng-no-nav":`true`,accent:unref(ACCENTS).outlined,onClick:addDecal},{default:withCtx(()=>[createBaseVNode(`span`,_hoisted_4$42,[createVNode(unref(bngBinding_default),{trackIgnore:!0,uiEvent:`context`,deviceMask:`xinput`}),_cache[2]||=createBaseVNode(`span`,{class:`add-label`},`Add Decal`,-1)])]),_:1},8,[`accent`])),[[unref(BngDisabled_default),isReprojectActive.value]])]),_:1},8,[`selectedKeys`,`layers`])),[[unref(BngBlur_default)]]),actionsDrawerData.value&&allowActionsDrawerShow.value?(openBlock(),createBlock(unref(bngActionDrawer_default),{key:0,ref_key:`actionDrawer`,ref:actionDrawer,blur:``,alwaysShowBack:!1,actions:actionsDrawerData.value,"item-width":10,"item-margin":1,class:`actions-drawer`,onSelect:onActionTriggered},{controls:withCtx(()=>[withDirectives(createVNode(unref(bngButton_default),{accent:unref(ACCENTS).outlined,icon:unref(icons).exit,onClick:closeActionDrawer},null,8,[`accent`,`icon`]),[[unref(BngOnUiNav_default),void 0,`ok`,{asMouse:!0,focusRequired:!0}]])]),action:withCtx(({item,select,order})=>[createBaseVNode(`div`,_hoisted_5$35,[item.isSwitch?withDirectives((openBlock(),createBlock(unref(bngTile_default),{key:0,"bng-nav-item":``,label:item.label,onClick:$event=>onActionSwitchClicked(item)},{default:withCtx(()=>[createVNode(unref(bngSwitch_default),{modelValue:item.switchValue,"onUpdate:modelValue":$event=>item.switchValue=$event},null,8,[`modelValue`,`onUpdate:modelValue`])]),_:2},1032,[`label`,`onClick`])),[[unref(BngUiNavFocus_default),order===0?0:void 0],[unref(BngFocusIf_default),order===0],[unref(BngDisabled_default),item.disabled],[unref(BngOnUiNav_default),void 0,`ok`,{asMouse:!0,focusRequired:!0}]]):withDirectives((openBlock(),createBlock(unref(bngImageTile_default),{key:1,"bng-nav-item":``,label:item.label,icon:item.icon?item.icon:ACTION_ITEM_ICON[item.value],class:`action-tile`,onClick:$event=>select(item)},null,8,[`label`,`icon`,`onClick`])),[[unref(BngUiNavFocus_default),order===0?0:void 0],[unref(BngFocusIf_default),order===0],[unref(BngOnUiNav_default),void 0,`ok`,{asMouse:!0,focusRequired:!0}]])])]),_:1},8,[`actions`])):createCommentVNode(``,!0),popupSettings.value?(openBlock(),createElementBlock(`div`,_hoisted_6$26,[(openBlock(),createBlock(resolveDynamicComponent(popupSettings.value)))])):createCommentVNode(``,!0)])])),[[unref(BngUiNavLabel_default),contextUIEventLabel.value,`context`],[unref(BngUiNavLabel_default),action2UIEventLabel.value,`action_2`],[unref(BngUiNavLabel_default),`Back`,`menu,back`],[unref(BngOnUiNav_default),onBack,`menu,back`],[unref(BngOnUiNav_default),handleContext,`context`],[unref(BngOnUiNav_default),handleAction2,`action_2`]])}},LiveryDecalsMain_default=__plugin_vue_export_helper_default(_sfc_main$82,[[`__scopeId`,`data-v-b9d45c3c`]]),_hoisted_1$73={class:`decal-selector-view`,"bng-ui-scope":`decal-selector-scope`},_hoisted_2$61={class:`header`},_hoisted_3$53={class:`main-view-content`},_hoisted_4$41={key:0,class:`side-menu`},_hoisted_5$34={class:`list-container`},BLOCKED_UINAV_EVENTS=[`tab_l`,`tab_r`],_sfc_main$81={__name:`LiveryDecalSelector`,setup(__props){let headerStore=useEditorHeaderStore(),infobar=useInfoBar(),uiNavBlocker=useUINavBlocker(),{events:events$3}=useBridge();useUINavScope(`decal-selector-scope`);let categorizedTextures=ref([]),selectedCategory=ref(null),textures=computed(()=>{if(categorizedTextures.value&&categorizedTextures.value.length>0&&selectedCategory.value){let cat=categorizedTextures.value.find(x=>x.value===selectedCategory.value);if(cat)return cat.items}return null});async function select(item){let layer=await Lua_default.extensions.ui_liveryEditor_layers_decal.addLayerCentered({texturePath:item.preview});await Lua_default.extensions.ui_liveryEditor_selection.select(layer.uid,!0),window.bngVue.gotoGameState(`LiveryDecals`)}function goBack(event){window.bngVue.gotoGameState(`LiveryDecals`),event.stopPropagation()}function onData(data){categorizedTextures.value=data,!data||data.length===0?selectedCategory.value=null:selectedCategory.value||=data[0].value}return onBeforeMount(()=>{headerStore.setPreheader([`Decals`,`Textures`])}),onMounted(()=>{infobar.visible=!0,infobar.showSysInfo=!0,Lua_default.extensions.ui_liveryEditor_resources.requestData(),events$3.on(`liveryEditor_resources_data`,onData),uiNavBlocker.blockOnly(BLOCKED_UINAV_EVENTS)}),onBeforeMount(()=>{events$3.off(`liveryEditor_resources_data`,onData),uiNavBlocker.clear()}),(_ctx,_cache)=>withDirectives((openBlock(),createElementBlock(`div`,_hoisted_1$73,[createBaseVNode(`div`,_hoisted_2$61,[createVNode(unref(LiveryEditorHeader_default))]),createBaseVNode(`div`,_hoisted_3$53,[categorizedTextures.value?withDirectives((openBlock(),createElementBlock(`div`,_hoisted_4$41,[(openBlock(!0),createElementBlock(Fragment,null,renderList(categorizedTextures.value,category=>(openBlock(),createBlock(unref(bngButton_default),{key:category.value,label:category.label,accent:`text`,onClick:$event=>selectedCategory.value=category.value},null,8,[`label`,`onClick`]))),128))])),[[unref(BngBlur_default)]]):createCommentVNode(``,!0),createBaseVNode(`div`,_hoisted_5$34,[textures.value?withDirectives((openBlock(),createBlock(unref(bngList_default),{key:0,layout:unref(LIST_LAYOUTS).TILES,"target-width":8,"target-height":8,"target-margin":.25,big:!0,class:`textures-list`},{default:withCtx(()=>[(openBlock(!0),createElementBlock(Fragment,null,renderList(textures.value,(item,index)=>withDirectives((openBlock(),createBlock(DecalSelectorItem_default,{"bng-nav-item":``,key:item.preview,externalImage:item.preview,"data-decal-item":index,onClick:$event=>select(item)},null,8,[`externalImage`,`data-decal-item`,`onClick`])),[[unref(BngOnUiNav_default),void 0,`ok`,{asMouse:!0,focusRequired:!0}],[unref(BngUiNavFocus_default),index===0?0:void 0],[unref(BngFocusIf_default),index===0]])),128))]),_:1},8,[`layout`])),[[unref(BngBlur_default)]]):createCommentVNode(``,!0)])])])),[[unref(BngOnUiNav_default),goBack,`back,menu`],[unref(BngUiNavLabel_default),`Back`,`back,menu`]])}},LiveryDecalSelector_default=__plugin_vue_export_helper_default(_sfc_main$81,[[`__scopeId`,`data-v-fc11228e`]]),_hoisted_1$72={class:`layer-edit-view`,"bng-ui-scope":`layer-edit-scope`},_hoisted_2$60={class:`header`},_hoisted_3$52={class:`main-view-content`},_hoisted_4$40={class:`menu-container`},MENU_ITEMS$1=[{label:`Projection`,value:`projection`,icon:icons.decal},{label:`Transform`,value:`transform`,icon:icons.colorPalette},{label:`Materials`,value:`materials`,icon:icons.decal}],noop=()=>{},_sfc_main$80={__name:`LiveryLayerEdit`,setup(__props){useEditorHeaderStore(),useDecalSelectorStore();let mainStore=useLiveryMainStore(),infobar=useInfoBar();useUINavScope(`layer-edit-scope`);function onMenuItemClicked(item){switch(item.value){case`transform`:router_default.push({name:`LayerTransform`});break;case`materials`:router_default.push({name:`LayerMaterials`});break;case`projection`:router_default.push({name:`LayerProjection`});break}}function goBack(){router_default.replace({name:`LiveryDecals`}),mainStore.exitLayerEdit()}function saveChanges(){Lua_default.extensions.ui_liveryEditor_layerEdit.saveChanges(!0).then(()=>goBack())}onBeforeMount(()=>{infobar.clearHints(),infobar.addHints(NAV_HINTS)}),onMounted(async()=>{infobar.visible=!0,infobar.showSysInfo=!0,await mainStore.setupLayerEdit(),await Lua_default.extensions.ui_liveryEditor_layerEdit.showCursorOrLayer(!0)}),onBeforeUnmount(async()=>{await Lua_default.extensions.ui_liveryEditor_layerEdit.showCursorOrLayer(!1)});let NAV_HINTS=[{id:`apply`,content:{type:`binding`,props:{uiEvent:`ok`},label:`Done`},action:saveChanges},{id:`back`,content:{type:`binding`,props:{uiEvent:`back`},label:`Back`},action:goBack}];return(_ctx,_cache)=>withDirectives((openBlock(),createElementBlock(`div`,_hoisted_1$72,[createBaseVNode(`div`,_hoisted_2$60,[createVNode(unref(LiveryEditorHeader_default))]),createBaseVNode(`div`,_hoisted_3$52,[createBaseVNode(`div`,_hoisted_4$40,[(openBlock(),createElementBlock(Fragment,null,renderList(MENU_ITEMS$1,item=>withDirectives(createVNode(unref(bngImageTile_default),{"bng-nav-item":``,key:item.value,label:item.label,icon:item.icon,class:`menu-item`,onClick:$event=>onMenuItemClicked(item)},null,8,[`label`,`icon`,`onClick`]),[[unref(BngBlur_default)]])),64))])])])),[[unref(BngOnUiNav_default),goBack,`back`],[unref(BngOnUiNav_default),saveChanges,`menu`],[unref(BngOnUiNav_default),noop,`rotate_h_cam`],[unref(BngOnUiNav_default),noop,`rotate_v_cam`]])}},LiveryLayerEdit_default=__plugin_vue_export_helper_default(_sfc_main$80,[[`__scopeId`,`data-v-c339e1a6`]]),_hoisted_1$71={class:`camera-settings-view`,"bng-ui-scope":`camera-settings-scope`},_hoisted_2$59={class:`header`},_hoisted_3$51={class:`main-view-content`},_hoisted_4$39={class:`menu-container`},MENU_ITEMS=[{label:`Right`,icon:icons.cameraSideRight,value:`right`},{label:`Front`,icon:icons.cameraFront1,value:`front`},{label:`Left`,icon:icons.cameraSideLeft,value:`left`},{label:`Back`,icon:icons.cameraBack1,value:`back`},{label:`Top Right`,icon:icons.cameraTop1,value:`topright`},{label:`Top Left`,icon:icons.cameraTop1,value:`topleft`},{label:`Top Front`,icon:icons.cameraTop1,value:`topfront`},{label:`Top Back`,icon:icons.cameraTop1,value:`topback`}],_sfc_main$79={__name:`LiveryCameraSettings`,setup(__props){let CAMERA_LUA$1=Lua_default.extensions.ui_liveryEditor_camera,headerStore=useEditorHeaderStore();useDecalSelectorStore();let infobar=useInfoBar();useUINavScope(`camera-settings-scope`);function onMenuItemClicked(item){CAMERA_LUA$1.setOrthographicView(item.value)}function goBack(){router_default.replace({name:`LiveryDecals`})}function done(){router_default.replace({name:`LiveryDecalSelector`})}onBeforeMount(()=>{infobar.clearHints(),infobar.addHints(NAV_HINTS),headerStore.setPreheader([`Select Camera`])}),onMounted(()=>{infobar.visible=!0,infobar.showSysInfo=!0});let NAV_HINTS=[{id:`apply`,content:{type:`binding`,props:{uiEvent:`menu`},label:`Done`}},{id:`back`,content:{type:`binding`,props:{uiEvent:`back`},label:`Back`},action:goBack}];return(_ctx,_cache)=>withDirectives((openBlock(),createElementBlock(`div`,_hoisted_1$71,[createBaseVNode(`div`,_hoisted_2$59,[createVNode(unref(LiveryEditorHeader_default))]),createBaseVNode(`div`,_hoisted_3$51,[createBaseVNode(`div`,_hoisted_4$39,[(openBlock(),createElementBlock(Fragment,null,renderList(MENU_ITEMS,item=>withDirectives(createVNode(unref(bngImageTile_default),{"bng-nav-item":``,key:item.value,label:item.label,icon:item.icon,onClick:$event=>onMenuItemClicked(item)},null,8,[`label`,`icon`,`onClick`]),[[unref(BngBlur_default)]])),64))])])])),[[unref(BngOnUiNav_default),goBack,`back`],[unref(BngOnUiNav_default),done,`menu`]])}},LiveryCameraSettings_default=__plugin_vue_export_helper_default(_sfc_main$79,[[`__scopeId`,`data-v-376ce11c`]]),_hoisted_1$70={class:`layer-transform-view`,"bng-ui-scope":`layer-transform-scope`},_hoisted_2$58={class:`header`},_hoisted_3$50={class:`main-view-content`},_hoisted_4$38={class:`inspector-container`},_hoisted_5$33={class:`transform-setting-item`},_hoisted_6$25={key:0},_hoisted_7$23={key:1,class:`transform-setting-inputs`},_hoisted_8$18={class:`slider-text-container`},_hoisted_9$16={class:`slider-text-container`},_hoisted_10$12={key:2,class:`display-values-container`},_hoisted_11$10={key:1,class:`transform-setting-item`},_hoisted_12$7={key:0,class:`transform-setting-inputs`},_hoisted_13$7={class:`slider-text-container`},_hoisted_14$7={class:`slider-text-container`},_hoisted_15$7={key:1,class:`display-values-container`},_hoisted_16$7={key:3,class:`transform-setting-item`},_hoisted_17$6={key:0,class:`transform-setting-inputs`},_hoisted_18$5={class:`slider-text-container`},_hoisted_19$3={key:1,class:`display-values-container`},_hoisted_20$3={key:5,class:`transform-setting-item`},_hoisted_21$3={key:0,class:`transform-setting-inputs`},_hoisted_22$3={class:`slider-text-container`},_hoisted_23$3={class:`slider-text-container`},_hoisted_24$2={key:1,class:`display-values-container`},_hoisted_25$1={class:`edit-button-label`},INPUT_MIN=0,INPUT_MAX=1,_sfc_main$78={__name:`LayerTransform`,setup(__props){let headerStore=useEditorHeaderStore(),infobar=useInfoBar(),navBlocker=useUINavBlocker(),{events:events$3}=useBridge();useUINavScope(`layer-transform-scope`);let transformState=reactive({positionX:0,positionY:0,scaleX:0,scaleY:0,skewX:0,skewY:0,rotation:0}),isHoldModifier=ref(!1),isPreciseActive=ref(!1),isTabRightActive=ref(!1),stateData=ref(null),isEdit=ref(!1),isReapplying=ref(!1),isRepositionActive=ref(!1),isUseMouse=ref(!1),positionX=computed({get:()=>transformState.positionX,set:newValue=>{let value=assertInt(newValue);transformState.positionX=value,isEdit.value&&Lua_default.extensions.ui_liveryEditor_layerEdit.setPosition(value,transformState.positionY)}}),positionY=computed({get:()=>transformState.positionY,set:newValue=>{let value=assertInt(newValue);transformState.positionY=value,isEdit.value&&Lua_default.extensions.ui_liveryEditor_layerEdit.setPosition(transformState.positionX,value)}}),scaleX=computed({get:()=>transformState.scaleX,set:newValue=>{let value=assertInt(newValue);transformState.scaleX=value,isEdit.value&&Lua_default.extensions.ui_liveryEditor_layerEdit.setScale(value,transformState.scaleY)}}),scaleY=computed({get:()=>transformState.scaleY,set:newValue=>{let value=assertInt(newValue);transformState.scaleY=value,isEdit.value&&Lua_default.extensions.ui_liveryEditor_layerEdit.setScale(transformState.scaleX,value)}}),skewX=computed({get:()=>transformState.skewX,set:newValue=>{let value=assertInt(newValue);transformState.skewX=value,isEdit.value&&Lua_default.extensions.ui_liveryEditor_layerEdit.setSkew(value,transformState.skewY)}}),skewY=computed({get:()=>transformState.skewY,set:newValue=>{let value=assertInt(newValue);transformState.skewY=value,isEdit.value&&Lua_default.extensions.ui_liveryEditor_layerEdit.setSkew(transformState.skewX,value)}}),rotation=computed({get:()=>transformState.rotation,set:newValue=>{let value=assertInt(newValue);transformState.rotation=value,isEdit.value&&Lua_default.extensions.ui_liveryEditor_layerEdit.setRotation(value)}}),hintLabels=computed(()=>{let labels={},focusLabel=`Move`,focusEvents=[`focus_l`,`focus_u`,`focus_r`,`focus_d`,`focus_lr`,`focus_ud`],rotateCamLabel=`Scale`;return isTabRightActive.value?rotateCamLabel=`Pan`:isHoldModifier.value&&(rotateCamLabel=`Skew`),!isTabRightActive.value&&!isHoldModifier.value&&focusEvents.forEach(uiEvent=>labels[uiEvent]=`Move`),[`rotate_h_cam`,`rotate_v_cam`].forEach(uiEvent=>labels[uiEvent]=rotateCamLabel),labels.tab_l=isTabRightActive.value?void 0:`[Hold] Skew`,labels.tab_r=isHoldModifier.value?void 0:`[Hold] Camera`,labels.action_2=isTabRightActive.value?void 0:`[Hold] Precise`,labels});watchEffect(()=>{navBlocker.clear(),isTabRightActive.value&&navBlocker.allowOnly([`rotate_h_cam`,`rotate_v_cam`,`tab_r`]),isHoldModifier.value&&navBlocker.allowOnly([`rotate_h_cam`,`rotate_v_cam`,`action_2`,`tab_l`])}),onBeforeMount(()=>{headerStore.setPreheader([`Transform`])}),onMounted(async()=>{infobar.visible=!0,infobar.showSysInfo=!0,events$3.on(`liveryEditor_layerEdit_state`,onStateData),events$3.on(`liveryEditor_layerEdit_initialLayerData`,onInitialLayerData),events$3.on(`liveryEditor_layerEdit_repositionSuccess`,onRepositionSuccess),events$3.on(`liveryEditor_layerEdit_rotationChanged`,onRotationChanged),events$3.on(`liveryEditor_layerEdit_positionChanged`,onPositionChanged),events$3.on(`liveryEditor_layerEdit_scaleChanged`,onScaleChanged),events$3.on(`liveryEditor_layerEdit_skewChanged`,onSkewChanged),await Lua_default.extensions.ui_liveryEditor_layerEdit.requestStateData(),await Lua_default.extensions.ui_liveryEditor_layerEdit.requestInitialLayerData()}),onBeforeUnmount(async()=>{events$3.off(`liveryEditor_layerEdit_state`,onStateData),events$3.off(`liveryEditor_layerEdit_initialLayerData`,onInitialLayerData),events$3.off(`liveryEditor_layerEdit_repositionSuccess`,onRepositionSuccess),events$3.off(`liveryEditor_layerEdit_rotationChanged`,onRotationChanged),events$3.off(`liveryEditor_layerEdit_positionChanged`,onPositionChanged),events$3.off(`liveryEditor_layerEdit_scaleChanged`,onScaleChanged),events$3.off(`liveryEditor_layerEdit_skewChanged`,onSkewChanged)});function onPositionChanged(position){positionX.value=position.x,positionY.value=position.y}function onRotationChanged(value){transformState.rotation=value}function onSkewChanged(skew){skewX.value=skew.x,skewY.value=skew.y}function onScaleChanged(scale){scaleX.value=scale.x,scaleY.value=scale.y}function onRepositionSuccess(){isRepositionActive.value=!isRepositionActive.value}function handleModifier(element){isHoldModifier.value=element.detail.value===1}function handlePrecise(element){let isPrecise=element.detail.value===1;isPreciseActive.value=isPrecise,Lua_default.extensions.ui_liveryEditor_layerEdit.holdPrecise(isPrecise)}function handleTabRight(element){isTabRightActive.value=element.detail.value===1}function handleAction3(element){isRepositionActive.value?toggleUseMouseOrCursor(element):toggleReposition(element)}function toggleReposition(element){let isReposition=isRepositionActive.value;isReposition?Lua_default.extensions.ui_liveryEditor_layerEdit.cancelReposition():Lua_default.extensions.ui_liveryEditor_layerEdit.requestReposition(),isRepositionActive.value=!isReposition}function toggleUseMouseOrCursor(element){if(!isRepositionActive.value)return!0;Lua_default.extensions.ui_liveryEditor_layerEdit.toggleUseMouseOrCursor().then(data=>{isUseMouse.value=data.isUseMouse})}function toggleEdit(element){if(isRepositionActive.value&&isUseMouse.value)return;let newValue=!isEdit.value;isEdit.value=newValue,Lua_default.extensions.ui_liveryEditor_layerEdit.setAllowRotationAction(!newValue).then(()=>{})}function handleFocusLinear(element){if(isEdit.value)return;let name=element.detail.name,value=element.detail.value,axis=name===`focus_d`||name===`focus_u`?`y`:`x`,direction$1=name===`focus_d`||name===`focus_l`?-1:1;Lua_default.extensions.ui_liveryEditor_layerEdit.holdTranslate(axis,direction$1*value)}function handleTranslateScalar(element){if(isEdit.value)return!0;let name=element.detail.name,value=element.detail.value,axis=name===`focus_lr`?`x`:`y`;Lua_default.extensions.ui_liveryEditor_layerEdit.holdTranslateScalar(axis,value)}function handleRotateCam(element){if(isRepositionActive.value||isTabRightActive.value)return!0;let name=element.detail.name,value=element.detail.value,axis=name===`rotate_h_cam`?`x`:`y`;isHoldModifier.value?Lua_default.extensions.ui_liveryEditor_layerEdit.holdSkew(axis,value):Lua_default.extensions.ui_liveryEditor_layerEdit.holdScale(axis,value)}function goBack(event){isRepositionActive.value?toggleReposition():isEdit.value?toggleEdit():openConfirmation(`Exit`,`Exit and lose unsaved changes?`).then(res=>{res&&(Lua_default.extensions.ui_liveryEditor_layerEdit.endTransform(),Lua_default.extensions.ui_liveryEditor_layerEdit.cancelChanges().then(()=>{window.bngVue.gotoGameState(`LiveryDecals`)}))}),event.stopPropagation()}function handleOk(){isRepositionActive.value?Lua_default.extensions.ui_liveryEditor_layerEdit.applyReposition():(Lua_default.extensions.ui_liveryEditor_layerEdit.endTransform(),Lua_default.extensions.ui_liveryEditor_layerEdit.saveChanges(!1).then(()=>{window.bngVue.gotoGameState(`LiveryDecals`)}))}function saveChanges(){Lua_default.extensions.ui_liveryEditor_layerEdit.saveChanges(!1).then(()=>{window.bngVue.gotoGameState(`LiveryDecals`)})}function onStateData(data){stateData.value=data,isReapplying.value=data.isStampReapplying}function onInitialLayerData(data){positionX.value=data.position.x,positionY.value=data.position.y,scaleX.value=data.scale.x,scaleY.value=data.scale.y,skewX.value=data.skew.x,skewY.value=data.skew.y,rotation.value=data.rotation}function assertInt(value){return typeof value==`string`?+value:value}return(_ctx,_cache)=>withDirectives((openBlock(),createElementBlock(`div`,_hoisted_1$70,[createBaseVNode(`div`,_hoisted_2$58,[createVNode(unref(LiveryEditorHeader_default))]),createBaseVNode(`div`,_hoisted_3$50,[createBaseVNode(`div`,_hoisted_4$38,[withDirectives((openBlock(),createBlock(LayerInspectorBase_default,{heading:`Transform`},{default:withCtx(()=>[createBaseVNode(`div`,{class:normalizeClass([`transform-inspector`,{"inspector-editing":isEdit.value}])},[createBaseVNode(`div`,_hoisted_5$33,[_cache[17]||=createBaseVNode(`div`,{class:`setting-item-name`},`Position`,-1),isRepositionActive.value&&isUseMouse.value?(openBlock(),createElementBlock(`div`,_hoisted_6$25,[..._cache[15]||=[createBaseVNode(`span`,null,`Using mouse position`,-1)]])):isEdit.value?(openBlock(),createElementBlock(`div`,_hoisted_7$23,[createBaseVNode(`div`,_hoisted_8$18,[createVNode(unref(bngInput_default),{modelValue:positionX.value,"onUpdate:modelValue":_cache[0]||=$event=>positionX.value=$event,type:`number`,step:.001,min:INPUT_MIN,max:1,prefix:`X`},null,8,[`modelValue`]),createVNode(unref(bngSlider_default),{modelValue:positionX.value,"onUpdate:modelValue":_cache[1]||=$event=>positionX.value=$event,step:.001,min:INPUT_MIN,max:1},null,8,[`modelValue`])]),createBaseVNode(`div`,_hoisted_9$16,[createVNode(unref(bngInput_default),{modelValue:positionY.value,"onUpdate:modelValue":_cache[2]||=$event=>positionY.value=$event,type:`number`,step:.001,min:INPUT_MIN,max:1,prefix:`Y`},null,8,[`modelValue`]),createVNode(unref(bngSlider_default),{modelValue:positionY.value,"onUpdate:modelValue":_cache[3]||=$event=>positionY.value=$event,step:.001,min:INPUT_MIN,max:1},null,8,[`modelValue`])])])):(openBlock(),createElementBlock(`div`,_hoisted_10$12,[createVNode(unref(bngPropVal_default),{keyLabel:`X`,valueLabel:positionX.value},null,8,[`valueLabel`]),createVNode(unref(bngPropVal_default),{keyLabel:`Y`,valueLabel:positionY.value},null,8,[`valueLabel`])])),isRepositionActive.value?createCommentVNode(``,!0):(openBlock(),createBlock(unref(bngButton_default),{key:3,accent:`outlined`,class:`reposition-button`,onClick:toggleReposition},{default:withCtx(()=>[createVNode(unref(bngBinding_default),{uiEvent:`action_3`}),_cache[16]||=createBaseVNode(`span`,{class:`reposition-button-label`},`Reproject and Position`,-1)]),_:1}))]),isRepositionActive.value?createCommentVNode(``,!0):(openBlock(),createBlock(unref(bngDivider_default),{key:0})),isRepositionActive.value?createCommentVNode(``,!0):(openBlock(),createElementBlock(`div`,_hoisted_11$10,[_cache[18]||=createBaseVNode(`div`,{class:`setting-item-name`},`Scale`,-1),isEdit.value?(openBlock(),createElementBlock(`div`,_hoisted_12$7,[createBaseVNode(`div`,_hoisted_13$7,[createVNode(unref(bngInput_default),{modelValue:scaleX.value,"onUpdate:modelValue":_cache[4]||=$event=>scaleX.value=$event,type:`number`,prefix:`X`,step:.01,min:INPUT_MIN,max:15},null,8,[`modelValue`]),createVNode(unref(bngSlider_default),{modelValue:scaleX.value,"onUpdate:modelValue":_cache[5]||=$event=>scaleX.value=$event,step:.01,min:INPUT_MIN,max:15},null,8,[`modelValue`])]),createBaseVNode(`div`,_hoisted_14$7,[createVNode(unref(bngInput_default),{modelValue:scaleY.value,"onUpdate:modelValue":_cache[6]||=$event=>scaleY.value=$event,type:`number`,step:.01,min:INPUT_MIN,max:15,prefix:`Y`},null,8,[`modelValue`]),createVNode(unref(bngSlider_default),{modelValue:scaleY.value,"onUpdate:modelValue":_cache[7]||=$event=>scaleY.value=$event,step:.01,min:INPUT_MIN,max:15},null,8,[`modelValue`])])])):(openBlock(),createElementBlock(`div`,_hoisted_15$7,[createVNode(unref(bngPropVal_default),{keyLabel:`X`,valueLabel:scaleX.value},null,8,[`valueLabel`]),createVNode(unref(bngPropVal_default),{keyLabel:`Y`,valueLabel:scaleY.value},null,8,[`valueLabel`])]))])),isRepositionActive.value?createCommentVNode(``,!0):(openBlock(),createBlock(unref(bngDivider_default),{key:2})),isRepositionActive.value?createCommentVNode(``,!0):(openBlock(),createElementBlock(`div`,_hoisted_16$7,[_cache[19]||=createBaseVNode(`div`,{class:`setting-item-name`},`Rotate`,-1),isEdit.value?(openBlock(),createElementBlock(`div`,_hoisted_17$6,[createBaseVNode(`div`,_hoisted_18$5,[createVNode(unref(bngInput_default),{modelValue:rotation.value,"onUpdate:modelValue":_cache[8]||=$event=>rotation.value=$event,type:`number`,step:.1,min:INPUT_MIN,max:359.9,suffix:`deg`},null,8,[`modelValue`]),createVNode(unref(bngSlider_default),{modelValue:rotation.value,"onUpdate:modelValue":_cache[9]||=$event=>rotation.value=$event,step:.1,min:INPUT_MIN,max:359.9},null,8,[`modelValue`])])])):(openBlock(),createElementBlock(`div`,_hoisted_19$3,[createVNode(unref(bngPropVal_default),{keyLabel:`deg`,valueLabel:rotation.value},null,8,[`valueLabel`])]))])),isRepositionActive.value?createCommentVNode(``,!0):(openBlock(),createBlock(unref(bngDivider_default),{key:4})),isRepositionActive.value?createCommentVNode(``,!0):(openBlock(),createElementBlock(`div`,_hoisted_20$3,[_cache[20]||=createBaseVNode(`div`,{class:`setting-item-name`},`Skew`,-1),isEdit.value?(openBlock(),createElementBlock(`div`,_hoisted_21$3,[createBaseVNode(`div`,_hoisted_22$3,[createVNode(unref(bngInput_default),{modelValue:skewX.value,"onUpdate:modelValue":_cache[10]||=$event=>skewX.value=$event,type:`number`,step:.01,min:INPUT_MIN,max:INPUT_MAX,prefix:`X`},null,8,[`modelValue`]),createVNode(unref(bngSlider_default),{modelValue:skewX.value,"onUpdate:modelValue":_cache[11]||=$event=>skewX.value=$event,step:.01,min:INPUT_MIN,max:INPUT_MAX},null,8,[`modelValue`])]),createBaseVNode(`div`,_hoisted_23$3,[createVNode(unref(bngInput_default),{modelValue:skewY.value,"onUpdate:modelValue":_cache[12]||=$event=>skewY.value=$event,type:`number`,step:.01,min:INPUT_MIN,max:INPUT_MAX,prefix:`Y`},null,8,[`modelValue`]),createVNode(unref(bngSlider_default),{modelValue:skewY.value,"onUpdate:modelValue":_cache[13]||=$event=>skewY.value=$event,step:.01,min:INPUT_MIN,max:INPUT_MAX},null,8,[`modelValue`])])])):(openBlock(),createElementBlock(`div`,_hoisted_24$2,[createVNode(unref(bngPropVal_default),{keyLabel:`X`,valueLabel:skewX.value},null,8,[`valueLabel`]),createVNode(unref(bngPropVal_default),{keyLabel:`Y`,valueLabel:skewY.value},null,8,[`valueLabel`])]))])),!isRepositionActive.value||!isUseMouse.value?withDirectives((openBlock(),createBlock(unref(bngButton_default),{key:6,accent:`text`,class:`inspector-edit-button`,onClick:_cache[14]||=$event=>isEdit.value=!isEdit.value},{default:withCtx(()=>[createVNode(unref(bngBinding_default),{uiEvent:`context`}),createBaseVNode(`span`,_hoisted_25$1,` Toggle `+toDisplayString(isEdit.value?`Simple`:`Advance`),1)]),_:1})),[[unref(BngOnUiNav_default),()=>isEdit.value=!isEdit.value,`ok`,{focusRequired:!0}]]):createCommentVNode(``,!0)],2)]),_:1})),[[unref(BngBlur_default)]]),!isRepositionActive.value||!isUseMouse.value?withDirectives((openBlock(),createBlock(unref(bngButton_default),{key:0,class:`apply-button`,onClick:handleOk},{default:withCtx(()=>[createVNode(unref(bngBinding_default),{uiEvent:`ok`}),_cache[21]||=createBaseVNode(`span`,null,`Apply`,-1)]),_:1})),[[unref(BngOnUiNav_default),handleOk,`ok`,{focusRequired:!0}]]):createCommentVNode(``,!0)])])])),[[unref(BngOnUiNav_default),handleOk,`ok`],[unref(BngOnUiNav_default),goBack,`back`],[unref(BngOnUiNav_default),saveChanges,`menu`],[unref(BngOnUiNav_default),handleTranslateScalar,`focus_lr`],[unref(BngOnUiNav_default),handleTranslateScalar,`focus_ud`],[unref(BngOnUiNav_default),handleFocusLinear,`focus_l`,{up:!0}],[unref(BngOnUiNav_default),handleFocusLinear,`focus_l`,{down:!0}],[unref(BngOnUiNav_default),handleFocusLinear,`focus_r`,{up:!0}],[unref(BngOnUiNav_default),handleFocusLinear,`focus_r`,{down:!0}],[unref(BngOnUiNav_default),handleFocusLinear,`focus_u`,{up:!0}],[unref(BngOnUiNav_default),handleFocusLinear,`focus_u`,{down:!0}],[unref(BngOnUiNav_default),handleFocusLinear,`focus_d`,{up:!0}],[unref(BngOnUiNav_default),handleFocusLinear,`focus_d`,{down:!0}],[unref(BngOnUiNav_default),handleFocusLinear,`focus_l`,{up:!0,modified:!0}],[unref(BngOnUiNav_default),handleFocusLinear,`focus_l`,{down:!0,modified:!0}],[unref(BngOnUiNav_default),handleFocusLinear,`focus_r`,{up:!0,modified:!0}],[unref(BngOnUiNav_default),handleFocusLinear,`focus_r`,{down:!0,modified:!0}],[unref(BngOnUiNav_default),handleFocusLinear,`focus_u`,{up:!0,modified:!0}],[unref(BngOnUiNav_default),handleFocusLinear,`focus_u`,{down:!0,modified:!0}],[unref(BngOnUiNav_default),handleFocusLinear,`focus_d`,{up:!0,modified:!0}],[unref(BngOnUiNav_default),handleFocusLinear,`focus_d`,{down:!0,modified:!0}],[unref(BngOnUiNav_default),handleRotateCam,`rotate_h_cam`],[unref(BngOnUiNav_default),handleRotateCam,`rotate_v_cam`],[unref(BngOnUiNav_default),handleRotateCam,`rotate_h_cam`,{modified:!0}],[unref(BngOnUiNav_default),handleRotateCam,`rotate_v_cam`,{modified:!0}],[unref(BngOnUiNav_default),handlePrecise,`action_2`,{up:!0}],[unref(BngOnUiNav_default),handlePrecise,`action_2`,{down:!0}],[unref(BngOnUiNav_default),handlePrecise,`action_2`,{up:!0,modified:!0}],[unref(BngOnUiNav_default),handlePrecise,`action_2`,{down:!0,modified:!0}],[unref(BngOnUiNav_default),handleModifier,`tab_l`,{up:!0}],[unref(BngOnUiNav_default),handleModifier,`tab_l`,{down:!0}],[unref(BngOnUiNav_default),handleTabRight,`tab_r`,{up:!0}],[unref(BngOnUiNav_default),handleTabRight,`tab_r`,{down:!0}],[unref(BngOnUiNav_default),handleAction3,`action_3`],[unref(BngOnUiNav_default),toggleEdit,`context`],[unref(BngUiNavLabel_default),hintLabels.value.focus_lr,`focus_lr`],[unref(BngUiNavLabel_default),hintLabels.value.focus_ud,`focus_ud`],[unref(BngUiNavLabel_default),hintLabels.value.focus_l,`focus_l`],[unref(BngUiNavLabel_default),hintLabels.value.focus_r,`focus_r`],[unref(BngUiNavLabel_default),hintLabels.value.focus_u,`focus_u`],[unref(BngUiNavLabel_default),hintLabels.value.focus_d,`focus_d`],[unref(BngUiNavLabel_default),hintLabels.value.rotate_h_cam,`rotate_h_cam`],[unref(BngUiNavLabel_default),hintLabels.value.rotate_v_cam,`rotate_v_cam`],[unref(BngUiNavLabel_default),hintLabels.value.action_2,`action_2`],[unref(BngUiNavLabel_default),hintLabels.value.action_3,`action_3`],[unref(BngUiNavLabel_default),hintLabels.value.tab_r,`tab_r`],[unref(BngUiNavLabel_default),hintLabels.value.tab_l,`tab_l`],[unref(BngUiNavLabel_default),hintLabels.value.ok,`ok`],[unref(BngUiNavLabel_default),hintLabels.value.back,`back`]])}},LayerTransform_default=__plugin_vue_export_helper_default(_sfc_main$78,[[`__scopeId`,`data-v-a4399a23`]]),_hoisted_1$69={class:`layer-materials-view`,"bng-ui-scope":`layer-materials-scope`},_hoisted_2$57={class:`header`},_hoisted_3$49={class:`main-view-content`},_hoisted_4$37={class:`inspector-container`},_hoisted_5$32={class:`materials-inspector`},_hoisted_6$24={class:`materials-setting-item`},_hoisted_7$22={class:`color-values-container`,"bng-no-child-nav":``},_hoisted_8$17={class:`materials-setting-item`},_hoisted_9$15={class:`slider-text-container`},_hoisted_10$11={class:`materials-setting-item`},_hoisted_11$9={class:`slider-text-container`},BLOCKED_UI_EVENTS=[`tab_l`,`tab_r`,`action_2`,`rotate_h_cam`,`rotate_v_cam`,`focus_lr`,`focus_ud`],_sfc_main$77={__name:`LayerMaterials`,setup(__props){let headerStore=useEditorHeaderStore(),infobar=useInfoBar(),uiNavBlocker=useUINavBlocker();useUINavScope(`layer-materials-scope`);let{events:events$3}=useBridge(),screenState=reactive({openedDialog:null}),color=ref({hue:.5,saturation:1,luminosity:.5}),inputHue=computed({get:()=>color.value.hue.toFixed(3),set:newValue=>{color.value.hue=typeof newValue==`string`?+newValue:newValue,onColorChanged()}}),inputSat=computed({get:()=>color.value.saturation.toFixed(3),set:newValue=>{color.value.saturation=typeof newValue==`string`?+newValue:newValue,onColorChanged()}}),inputLum=computed({get:()=>color.value.luminosity.toFixed(3),set:newValue=>{color.value.luminosity=typeof newValue==`string`?+newValue:newValue,onColorChanged()}}),metallicIntensity=ref(0),roughnessIntensity=ref(0),stateData=ref(),colorInitialized=ref(!1),isPreciseActive=ref(!1),colorPickerStep=computed(()=>isPreciseActive.value?.001:.01),slidersStep=computed(()=>isPreciseActive.value?.1:1),updateMaterialProperties=properties=>Lua_default.extensions.ui_liveryEditor_layerEdit.setLayerMaterials(properties);function onColorChanged(){if(!colorInitialized.value)return;let paint=new Paint;paint.hsl=[color.value.hue,color.value.saturation,color.value.luminosity],updateMaterialProperties({color:paint.rgba})}watch(()=>metallicIntensity.value,value=>updateMaterialProperties({metallicIntensity:value})),watch(()=>roughnessIntensity.value,value=>updateMaterialProperties({roughnessIntensity:value})),onBeforeMount(()=>{headerStore.setPreheader([`Materials`])}),onMounted(async()=>{infobar.visible=!0,infobar.showSysInfo=!0,uiNavBlocker.blockOnly(BLOCKED_UI_EVENTS),events$3.on(`liveryEditor_layerEdit_state`,onStateData),events$3.on(`liveryEditor_layerEdit_layerMaterialsData`,onMaterialPropertiesData),await Lua_default.extensions.ui_liveryEditor_layerEdit.requestStateData(),await Lua_default.extensions.ui_liveryEditor_layerEdit.requestLayerMaterials()}),onBeforeUnmount(async()=>{events$3.off(`liveryEditor_layerEdit_layerMaterialsData`,onMaterialPropertiesData),events$3.off(`liveryEditor_layerEdit_state`,onStateData),uiNavBlocker.clear()});async function onStateData(data){stateData.value=data}function onMaterialPropertiesData(data){colorInitialized.value=!1;let paint=new Paint;data.color[3]=1;let isWhite=data.color.every(num=>num===1);paint.rgba=data.color,color.value.hue=paint.hue,color.value.saturation=isWhite?.5:paint.saturation,color.value.luminosity=paint.luminosity,colorInitialized.value=!0,metallicIntensity.value=data.metallicIntensity,roughnessIntensity.value=data.roughnessIntensity}function handleAction2(element){isPreciseActive.value=element.detail.value===1}function goBack(event){screenState.openedDialog||(screenState.openedDialog=`exit`,openConfirmation(`Exit`,`Exit and lose changes?`).then(res=>{res&&Lua_default.extensions.ui_liveryEditor_layerEdit.cancelChanges().then(()=>{window.bngVue.gotoGameState(`LiveryDecals`)}),screenState.openedDialog=null}),event.stopPropagation())}function saveChanges(){Lua_default.extensions.ui_liveryEditor_layerEdit.saveChanges().then(()=>{window.bngVue.gotoGameState(`LiveryDecals`)})}return(_ctx,_cache)=>withDirectives((openBlock(),createElementBlock(`div`,_hoisted_1$69,[createBaseVNode(`div`,_hoisted_2$57,[createVNode(unref(LiveryEditorHeader_default))]),createBaseVNode(`div`,_hoisted_3$49,[createBaseVNode(`div`,_hoisted_4$37,[withDirectives((openBlock(),createBlock(LayerInspectorBase_default,{heading:`Materials`,class:``},{default:withCtx(()=>[createBaseVNode(`div`,_hoisted_5$32,[createBaseVNode(`div`,_hoisted_6$24,[_cache[8]||=createBaseVNode(`div`,{class:`setting-item-name`},`Color`,-1),withDirectives(createVNode(unref(bngColorPicker_default),{modelValue:color.value,"onUpdate:modelValue":_cache[0]||=$event=>color.value=$event,step:colorPickerStep.value,onChange:onColorChanged},null,8,[`modelValue`,`step`]),[[unref(BngUiNavFocus_default),0]]),createBaseVNode(`div`,_hoisted_7$22,[createVNode(unref(bngInput_default),{prefix:`h`,modelValue:inputHue.value,"onUpdate:modelValue":_cache[1]||=$event=>inputHue.value=$event,type:`number`},null,8,[`modelValue`]),createVNode(unref(bngInput_default),{prefix:`s`,modelValue:inputSat.value,"onUpdate:modelValue":_cache[2]||=$event=>inputSat.value=$event,type:`number`},null,8,[`modelValue`]),createVNode(unref(bngInput_default),{prefix:`b`,modelValue:inputLum.value,"onUpdate:modelValue":_cache[3]||=$event=>inputLum.value=$event,type:`number`},null,8,[`modelValue`])])]),createVNode(unref(bngDivider_default)),createBaseVNode(`div`,_hoisted_8$17,[_cache[9]||=createBaseVNode(`div`,{class:`setting-item-name`},`Metallic Intensity`,-1),createBaseVNode(`div`,_hoisted_9$15,[createVNode(unref(bngInput_default),{"bng-no-nav":``,modelValue:metallicIntensity.value,"onUpdate:modelValue":_cache[4]||=$event=>metallicIntensity.value=$event,type:`number`,min:0,max:100,step:slidersStep.value},null,8,[`modelValue`,`step`]),createVNode(unref(bngSlider_default),{modelValue:metallicIntensity.value,"onUpdate:modelValue":_cache[5]||=$event=>metallicIntensity.value=$event,min:0,max:100,step:slidersStep.value},null,8,[`modelValue`,`step`])])]),createVNode(unref(bngDivider_default)),createBaseVNode(`div`,_hoisted_10$11,[_cache[10]||=createBaseVNode(`div`,{class:`setting-item-name`},`Roughness Intensity`,-1),createBaseVNode(`div`,_hoisted_11$9,[createVNode(unref(bngInput_default),{"bng-no-nav":``,modelValue:roughnessIntensity.value,"onUpdate:modelValue":_cache[6]||=$event=>roughnessIntensity.value=$event,type:`number`,min:0,max:100,step:slidersStep.value},null,8,[`modelValue`,`step`]),createVNode(unref(bngSlider_default),{modelValue:roughnessIntensity.value,"onUpdate:modelValue":_cache[7]||=$event=>roughnessIntensity.value=$event,min:0,max:100,step:slidersStep.value},null,8,[`modelValue`,`step`])])])])]),_:1})),[[unref(BngBlur_default)]])])])])),[[unref(BngUiNavLabel_default),`Apply`,`context`],[unref(BngUiNavLabel_default),`[Hold]Precise`,`action_2`],[unref(BngUiNavLabel_default),`Back`,`back,menu`],[unref(BngOnUiNav_default),handleAction2,`action_2`,{up:!0}],[unref(BngOnUiNav_default),handleAction2,`action_2`,{down:!0}],[unref(BngOnUiNav_default),goBack,`back,menu`],[unref(BngOnUiNav_default),saveChanges,`context`]])}},LayerMaterials_default=__plugin_vue_export_helper_default(_sfc_main$77,[[`__scopeId`,`data-v-4b3730e9`]]),_hoisted_1$68={class:`layer-projection-view`,"bng-ui-scope":`layer-projection-scope`},_hoisted_2$56={class:`header`},_hoisted_3$48={class:`main-view-content`},_hoisted_4$36={class:`camera-views-container`},_hoisted_5$31={class:`mirror-settings-container`},CAMERA_BUTTONS=[{label:`Right`,icon:icons.cameraSideRight,value:`right`},{label:`Front`,icon:icons.cameraFront1,value:`front`},{label:`Left`,icon:icons.cameraSideLeft,value:`left`},{label:`Back`,icon:icons.cameraBack1,value:`back`},{label:`Top Right`,icon:icons.cameraTop1,value:`topright`},{label:`Top Left`,icon:icons.cameraTop1,value:`topleft`},{label:`Top Front`,icon:icons.cameraTop1,value:`topfront`},{label:`Top Back`,icon:icons.cameraTop1,value:`topback`}],_sfc_main$76={__name:`LayerProjection`,setup(__props){let{events:events$3}=useBridge(),headerStore=useEditorHeaderStore(),store$1=useLiveryEditorStore(),infobar=useInfoBar(),popover=usePopover(),uiNav=useUINavScope(`layer-projection-scope`),stateData=ref(null),mirrorState=reactive({mirrored:!1,mirrorFipped:!1,mirrorOffset:0}),mirrored=computed({get:()=>mirrorState.mirrored,set:async newValue=>{mirrorState.mirrored=newValue,await Lua_default.extensions.ui_liveryEditor_layerEdit.setMirrored(newValue,mirrorState.mirrorFipped,mirrorState.mirrorOffset)}}),mirrorFipped=computed({get:()=>mirrorState.mirrorFipped,set:async newValue=>{mirrorState.mirrorFipped=newValue,await Lua_default.extensions.ui_liveryEditor_layerEdit.setMirrored(mirrorState.mirrored,newValue,mirrorState.mirrorOffset)}}),mirrorOffset=computed({get:()=>mirrorState.mirrorOffset,set:async newValue=>{mirrorState.mirrorOffset=newValue,await Lua_default.extensions.ui_liveryEditor_layerEdit.setMirrored(mirrorState.mirrored,mirrorState.mirrorFipped,newValue)}}),NAV_HINTS=[{id:`apply`,content:{type:`binding`,props:{uiEvent:`menu`},label:`Done`},action:saveChanges},{id:`back`,content:{type:`binding`,props:{uiEvent:`back`},label:`Back`},action:goBack}];onBeforeMount(()=>{infobar.clearHints(),infobar.addHints(NAV_HINTS),headerStore.setPreheader([`Projection`]),headerStore.setHeader(`Decals`)}),onMounted(async()=>{infobar.visible=!0,infobar.showSysInfo=!0,events$3.on(`liveryEditor_layerEdit_state`,onStateData),events$3.on(`liveryEditor_layerEdit_initialLayerData`,onInitialLayerData),await Lua_default.extensions.ui_liveryEditor_layerEdit.requestStateData(),await Lua_default.extensions.ui_liveryEditor_layerEdit.requestInitialLayerData()}),onBeforeUnmount(()=>{events$3.off(`liveryEditor_layerEdit_state`,onStateData),events$3.off(`liveryEditor_layerEdit_initialLayerData`,onInitialLayerData)});function changeCameraView(view){popover.hide(`camera-views-menu`),console.log(`changeCameraView`,view),store$1.setOrthographicView(view)}function onStateData(data){console.log(`onStateData`,data),stateData.value=data}function onInitialLayerData(data){mirrorState.mirrored=data.mirrored,mirrorState.mirrorFipped=data.mirrorFipped,mirrorState.mirrorOffset=data.mirrorOffset}function goBack(){window.bngVue.gotoGameState(`LiveryLayerEdit`)}function saveChanges(){window.bngVue.gotoGameState(`LiveryLayerEdit`)}function onPopoverMenuHide(){uiNav.set(`layer-projection-scope`)}return(_ctx,_cache)=>withDirectives((openBlock(),createElementBlock(`div`,_hoisted_1$68,[createBaseVNode(`div`,_hoisted_2$56,[createVNode(unref(LiveryEditorHeader_default))]),createBaseVNode(`div`,_hoisted_3$48,[withDirectives(createVNode(unref(bngImageTile_default),{"bng-nav-item":``,icon:unref(icons).movieCamera,label:`Side`},null,8,[`icon`]),[[unref(BngBlur_default)],[unref(BngPopover_default),`camera-views-menu`,`right-start`,{click:!0}]]),withDirectives(createVNode(unref(bngImageTile_default),{"bng-nav-item":``,icon:unref(icons).reflect,label:`Mirror`},null,8,[`icon`]),[[unref(BngBlur_default)],[unref(BngPopover_default),`mirror-settings-menu`,`right-start`,{click:!0}]])]),createVNode(unref(bngPopoverMenu_default),{name:`camera-views-menu`,onHide:onPopoverMenuHide},{default:withCtx(()=>[createBaseVNode(`div`,_hoisted_4$36,[createVNode(unref(bngList_default),{targetWidth:8,targetMargin:.5,noBackground:``},{default:withCtx(()=>[(openBlock(),createElementBlock(Fragment,null,renderList(CAMERA_BUTTONS,view=>createVNode(unref(bngImageTile_default),{key:view.value,"bng-nav-item":``,label:view.label,icon:view.icon,onClick:$event=>changeCameraView(view.value)},null,8,[`label`,`icon`,`onClick`])),64))]),_:1})])]),_:1}),createVNode(unref(bngPopoverMenu_default),{name:`mirror-settings-menu`,onHide:onPopoverMenuHide},{default:withCtx(()=>[createBaseVNode(`div`,_hoisted_5$31,[createVNode(unref(bngPillCheckbox_default),{modelValue:mirrored.value,"onUpdate:modelValue":_cache[0]||=$event=>mirrored.value=$event},{default:withCtx(()=>[..._cache[3]||=[createTextVNode(`Mirrored`,-1)]]),_:1},8,[`modelValue`]),withDirectives((openBlock(),createBlock(unref(bngPillCheckbox_default),{modelValue:mirrorFipped.value,"onUpdate:modelValue":_cache[1]||=$event=>mirrorFipped.value=$event},{default:withCtx(()=>[..._cache[4]||=[createTextVNode(`Mirror Flipped`,-1)]]),_:1},8,[`modelValue`])),[[unref(BngDisabled_default),!mirrored.value]]),createVNode(unref(bngInput_default),{modelValue:mirrorOffset.value,"onUpdate:modelValue":_cache[2]||=$event=>mirrorOffset.value=$event,externalLabel:`Offset`,type:`number`,disabled:!mirrored.value},null,8,[`modelValue`,`disabled`])])]),_:1})])),[[unref(BngOnUiNav_default),goBack,`back`],[unref(BngOnUiNav_default),goBack,`menu`]])}},LayerProjection_default=__plugin_vue_export_helper_default(_sfc_main$76,[[`__scopeId`,`data-v-19e531c7`]]),_hoisted_1$67={class:`settings-main-view`,"bng-ui-scope":`settings-main-scope`},_hoisted_2$55={class:`header`},_hoisted_3$47={class:`main-view-content`},_hoisted_4$35={class:`settings-container`},_hoisted_5$30={class:`settings-item`},_sfc_main$75={__name:`LiverySettingsMain`,setup(__props){let headerStore=useEditorHeaderStore(),infobar=useInfoBar();useUINavScope(`settings-main-scope`);let{events:events$3}=useBridge(),stateData=ref(null),useSurfaceNormal=ref(!1);watch(()=>useSurfaceNormal.value,async value=>{await Lua_default.extensions.ui_liveryEditor.useSurfaceNormal(value)});let NAV_HINTS=[{id:`back`,content:{type:`binding`,props:{uiEvent:`back`},label:`Back`},action:goBack}];onBeforeMount(()=>{infobar.clearHints(),infobar.addHints(NAV_HINTS),headerStore.setHeader(`Decals`),headerStore.setPreheader([`Settings`])}),onMounted(async()=>{infobar.visible=!0,infobar.showSysInfo=!0,events$3.on(`liveryEditor_settingsData`,onSettingsData),await Lua_default.extensions.ui_liveryEditor.requestSettingsData()}),onBeforeUnmount(()=>{events$3.off(`liveryEditor_settingsData`,onSettingsData)});function onSettingsData(data){console.log(`onSettingsData`,data),stateData.value=data,useSurfaceNormal.value=data.useSurfaceNormal}function goBack(event){window.bngVue.gotoGameState(`LiveryMain`),event.stopPropagation()}return(_ctx,_cache)=>withDirectives((openBlock(),createElementBlock(`div`,_hoisted_1$67,[createBaseVNode(`div`,_hoisted_2$55,[createVNode(unref(LiveryEditorHeader_default))]),createBaseVNode(`div`,_hoisted_3$47,[withDirectives((openBlock(),createBlock(unref(bngCard_default),null,{default:withCtx(()=>[createVNode(unref(bngCardHeading_default),null,{default:withCtx(()=>[..._cache[1]||=[createTextVNode(`Settings`,-1)]]),_:1}),createBaseVNode(`div`,_hoisted_4$35,[createBaseVNode(`div`,_hoisted_5$30,[_cache[2]||=createBaseVNode(`div`,{class:`settings-item-name`},`Use Surface Normal`,-1),withDirectives(createVNode(unref(bngSwitch_default),{modelValue:useSurfaceNormal.value,"onUpdate:modelValue":_cache[0]||=$event=>useSurfaceNormal.value=$event,label:useSurfaceNormal.value?`Yes`:`No`},null,8,[`modelValue`,`label`]),[[unref(BngUiNavFocus_default),0],[unref(BngFocusIf_default),!0]])])])]),_:1})),[[unref(BngBlur_default)]])])])),[[unref(BngOnUiNav_default),goBack,`back,menu`]])}},LiverySettingsMain_default=__plugin_vue_export_helper_default(_sfc_main$75,[[`__scopeId`,`data-v-ad4291e2`]]),routes_default$8=[{path:`/livery-editor`,name:`LiveryEditor`,component:LiveryEditor_default},{path:`/livery-main`,name:`LiveryMain`,component:LiveryMainNew_default},{path:`/livery-paint`,name:`LiveryPaint`,component:LiveryPaintMain_default},{path:`/livery-decals`,name:`LiveryDecals`,component:LiveryDecalsMain_default},{path:`/livery-settings`,name:`LiverySettings`,component:LiverySettingsMain_default},{path:`/livery-camera-settings`,name:`LiveryCameraSettings`,component:LiveryCameraSettings_default},{path:`/livery-decal-selector`,name:`LiveryDecalSelector`,component:LiveryDecalSelector_default},{path:`/livery-layer-edit`,name:`LiveryLayerEdit`,component:LiveryLayerEdit_default},{path:`/layer-transform`,name:`LayerTransform`,component:LayerTransform_default},{path:`/layer-materials`,name:`LayerMaterials`,component:LayerMaterials_default},{path:`/layer-projection`,name:`LayerProjection`,component:LayerProjection_default},{path:`/livery-manager`,name:`LiveryManager`,component:LiveryManager_default}],_hoisted_1$66={class:`logo-wrapper`},_sfc_main$74={__name:`Logo`,setup(__props){let logos={beamng:getAssetURL(`images/logos.svg#bng-beamng`),tech:getAssetURL(`images/logos.svg#bng-tech`),drive:getAssetURL(`images/logos.svg#bng-drive`),research:getAssetURL(`images/logos.svg#bng-research`)},productLogo=ref(logos.drive);return onMounted(async()=>{if(await Lua_default.extensions.tech_license.isValid())productLogo.value=logos.tech;else if(window.beamng){let name=window.beamng.product.replace(`BeamNG.`,``);name in logos&&(productLogo.value=logos[name])}else productLogo.value=logos.drive}),(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$66,[createBaseVNode(`div`,{class:`logo`,style:normalizeStyle({"--logo":`url('${productLogo.value}')`})},null,4)]))}},Logo_default=__plugin_vue_export_helper_default(_sfc_main$74,[[`__scopeId`,`data-v-69adfd8c`]]),_hoisted_1$65={class:`main-view`},_hoisted_2$54={class:`dev-info-content`},_hoisted_3$46={class:`dev-info-text`},_hoisted_4$34={class:`mainmenu-title`},_hoisted_5$29={key:1,class:`bottom-buttons`},_hoisted_6$23={class:`btn-content`},_hoisted_7$21={class:`label`},_hoisted_8$16={key:0,class:`small`},_hoisted_9$14={class:`btn-content`},_hoisted_10$10={class:`label`},_hoisted_11$8={key:0,class:`small`},_hoisted_12$6={class:`btn-content`},_hoisted_13$6={class:`label`},_hoisted_14$6={class:`btn-content`},_hoisted_15$6={class:`label`},_hoisted_16$6={class:`btn-content`},_hoisted_17$5={class:`label`},_sfc_main$73={__name:`MainMenu`,setup(__props){let events$3=useEvents(),infoBar=useInfoBar();useUINavScope(`mainmenuUI`);let withAngular=computed(()=>!sysInfo_default.mainMenuBackgroundRequired.value),firstTime=ref(sysInfo_default.mainMenuFirstTime.value),bgRequired=sysInfo_default.mainMenuBackgroundRequired,parentImageCarousel=inject(`mainBackground`),modCounts$1=sysInfo_default.modCounts,devEnv=reactive({env:window.beamng&&!window.beamng.shipping,vue:!1,simplemenu:window.beamng&&window.beamng.simplemenu,videoApi:null,UIEngine:null}),quickLoadLevel=()=>Lua_default.core_levels.startLevel(`/levels/smallgrid/main.level.json`),addons=ref({}),addButton=({translateid,icon,targetState,title,iconId,action})=>{let newButton;newButton=translateid||icon||targetState?{title:$translate.instant(translateid),icon,action:targetState}:{title,iconId,action},addons.value[newButton.title]=newButton},viewName=ref(),changeView=name=>{viewName.value=name,router_default.push(`/menu.mainmenu`+(name?`/`+name:``))};watch(()=>viewName.value,val=>{val&&infoBar.flashHints(`back`),parentImageCarousel.value&&nextTick(parentImageCarousel.value.carousel.showNext)});let route=useRoute();watch(()=>route.name,name=>{if(typeof name!=`string`){viewName.value=null;return}name.startsWith(`menu.mainmenu`)&&(viewName.value=name===`menu.mainmenu`?null:name.slice(14))},{immediate:!0});let navigate$1=(...state)=>window.bngVue.gotoGameState(...state);function quitGame(){Lua_default.quit(),runRaw(`TorqueScript.eval('quit();')`,!1)}let handleBack=event=>{event.detail.force||(viewName.value?(viewName.value=null,changeView(null)):(event.detail.name===`back`||event.detail.name===`menu`)&&window.globalAngularRootScope?.$broadcast(`MenuToggle`))},canDeactivateScope=()=>!viewName.value,canBubbleEvent=event=>{if(event.detail.value!==1)return!1;let eventName=event.detail.name;return eventName===`tab_l`||eventName===`tab_r`?!viewName.value:!1};function displayToast(type,title,titleContext,msg,messageContext){let msgTxt=$translate.contextTranslate({txt:msg,context:messageContext}),titleTxt=$translate.contextTranslate({txt:title,context:titleContext}),msgHtml=window.angularParseBBCode(msgTxt),titleHtml=window.angularParseBBCode(titleTxt);window.globalAngularRootScope.$broadcast(`toastrMsg`,{type,msg:msgHtml,title:titleHtml,config:{positionClass:`toast-top-right`,timeOut:0,extendedTimeOut:0,onTap(){window.bngVue.gotoGameState(`menu.options.performance`)}}})}async function checkHardware(){Lua_default.checkFSErrors();let info=await Lua_default.core_hardwareinfo.getInfo();if(info.globalState!==`ok`){for(let key in info)if(!(!info[key].warnings||!Array.isArray(info[key].warnings)))for(let warning of info[key].warnings)warning.ack||displayToast(info.globalState===`warn`?`warning`:`error`,`ui.performance.warnings.`+warning.msg,warning.context,`ui.mainmenu.warningdetails`,null)}}let repoEnabled=ref(!1),modsAfterUpdate=ref(!1),onSettingsChanged=data=>{modsAfterUpdate.value=data.values.disableModsAfterUpdate,repoEnabled.value=data.values.onlineFeatures===`enable`&&!data.values.disableModsAfterUpdate};return onMounted(async()=>{function advertMainMenu(){events$3.emit(`MainMenuButtons`,addButton),window.globalAngularRootScope.$broadcast(`MainMenuButtons`,addButton)}advertMainMenu(),events$3.on(`UiModsChanged`,advertMainMenu),events$3.on(`BroadcastMainMenuButtons`,advertMainMenu),events$3.on(`SettingsChanged`,onSettingsChanged),Lua_default.settings.notifyUI(),devEnv.env&&(devEnv.videoApi=await Lua_default.Engine.Render.getAdapterType(),devEnv.UIEngine=await Lua_default.Engine.UI.getUIEngine()),sysInfo_default.mainMenuFirstTime.value&&checkHardware();let settings$1=await useSettingsAsync();await Lua_default.extensions.tech_license.isValid()||(settings$1.values.onlineFeatures===`ask`||settings$1.values.telemetry===`ask`?window.bngVue.gotoGameState(`menu.onlineFeatures`):Lua_default.settings.getValue(`showedInputLayoutPopupV37`).then(value=>{value===!1&&window.bngVue.gotoGameState(`buttonLayout`)})),sysInfo_default.mainMenuFirstTime.value=!1}),onUnmounted(()=>{events$3.off(`SettingsChanged`,onSettingsChanged)}),(_ctx,_cache)=>{let _component_router_view=resolveComponent(`router-view`);return withDirectives((openBlock(),createElementBlock(`div`,{class:normalizeClass({"mainmenu-container":!0,"mainmenu-with-angular":withAngular.value,"mainmenu-fadein":firstTime.value&&!withAngular.value}),onDeactivate:handleBack},[withDirectives((openBlock(),createElementBlock(`div`,_hoisted_1$65,[devEnv.env?(openBlock(),createBlock(unref(bngCard_default),{key:0,class:`dev-info`},{default:withCtx(()=>[createVNode(unref(bngCardHeading_default),{type:`ribbon`},{default:withCtx(()=>[..._cache[5]||=[createTextVNode(`Developer Release`,-1)]]),_:1}),createBaseVNode(`div`,_hoisted_2$54,[withDirectives(createVNode(unref(bngIcon_default),{class:`dev-info-icon`,type:unref(icons).bug,"bng-all-clicks-no-nav":``},null,8,[`type`]),[[unref(BngDoubleClick_default),quickLoadLevel]]),createBaseVNode(`div`,_hoisted_3$46,[createBaseVNode(`div`,null,` Graphics API: `+toDisplayString(devEnv.videoApi||`requesting...`),1),createBaseVNode(`div`,null,` UI Engine: `+toDisplayString(devEnv.UIEngine||`requesting...`),1)])])]),_:1})):createCommentVNode(``,!0),createBaseVNode(`div`,_hoisted_4$34,[createVNode(Logo_default)]),createVNode(_component_router_view,{"first-time":firstTime.value&&!withAngular.value,addons:addons.value,onChangeView:changeView},null,8,[`first-time`,`addons`]),viewName.value?createCommentVNode(``,!0):(openBlock(),createElementBlock(`div`,_hoisted_5$29,[repoEnabled.value?withDirectives((openBlock(),createBlock(unref(bngButton_default),{key:0,class:`btn-mods`,accent:unref(ACCENTS).text,onClick:_cache[0]||=$event=>navigate$1(`menu.mods.repository`)},{default:withCtx(()=>[unref(bgRequired)?(openBlock(),createBlock(BlurBackground_default,{key:0})):createCommentVNode(``,!0),createBaseVNode(`div`,_hoisted_6$23,[createBaseVNode(`span`,_hoisted_7$21,toDisplayString(_ctx.$tt(`ui.mainmenu.repo`)),1),unref(modCounts$1).total>0?(openBlock(),createElementBlock(`span`,_hoisted_8$16,`\xA0(`+toDisplayString(unref(modCounts$1).active)+` / `+toDisplayString(unref(modCounts$1).total)+`)`,1)):createCommentVNode(``,!0)])]),_:1},8,[`accent`])),[[unref(BngBlur_default),!unref(bgRequired)],[unref(BngSoundClass_default),`bng_click_hover_generic`]]):withDirectives((openBlock(),createBlock(unref(bngButton_default),{key:1,class:normalizeClass([`btn-mods`,{"mods-after-update":modsAfterUpdate.value}]),accent:unref(ACCENTS).text,onClick:_cache[1]||=$event=>navigate$1(`menu.mods.local`)},{default:withCtx(()=>[unref(bgRequired)?(openBlock(),createBlock(BlurBackground_default,{key:0})):createCommentVNode(``,!0),createBaseVNode(`div`,_hoisted_9$14,[createBaseVNode(`span`,_hoisted_10$10,[modsAfterUpdate.value?(openBlock(),createBlock(unref(bngIcon_default),{key:0,type:`danger`,style:{"font-size":`1.1em`},color:`#ff2d00`})):createCommentVNode(``,!0),createTextVNode(toDisplayString(_ctx.$tt(`ui.mainmenu.mods`)),1)]),unref(modCounts$1).total>0?(openBlock(),createElementBlock(`span`,_hoisted_11$8,`\xA0(`+toDisplayString(unref(modCounts$1).active)+` / `+toDisplayString(unref(modCounts$1).total)+`)`,1)):createCommentVNode(``,!0)])]),_:1},8,[`class`,`accent`])),[[unref(BngBlur_default),!unref(bgRequired)],[unref(BngSoundClass_default),`bng_click_hover_generic`]]),withDirectives((openBlock(),createBlock(unref(bngButton_default),{accent:unref(ACCENTS).text,onClick:_cache[2]||=$event=>navigate$1(`credits`)},{default:withCtx(()=>[unref(bgRequired)?(openBlock(),createBlock(BlurBackground_default,{key:0})):createCommentVNode(``,!0),createBaseVNode(`div`,_hoisted_12$6,[createBaseVNode(`span`,_hoisted_13$6,toDisplayString(_ctx.$tt(`ui.mainmenu.credits`)),1)])]),_:1},8,[`accent`])),[[unref(BngBlur_default),!unref(bgRequired)],[unref(BngSoundClass_default),`bng_click_hover_generic`]]),withDirectives((openBlock(),createBlock(unref(bngButton_default),{accent:unref(ACCENTS).text,onClick:_cache[3]||=$event=>navigate$1(`menu.options.display`)},{default:withCtx(()=>[unref(bgRequired)?(openBlock(),createBlock(BlurBackground_default,{key:0})):createCommentVNode(``,!0),createBaseVNode(`div`,_hoisted_14$6,[createBaseVNode(`span`,_hoisted_15$6,toDisplayString(_ctx.$tt(`ui.mainmenu.options`)),1)])]),_:1},8,[`accent`])),[[unref(BngBlur_default),!unref(bgRequired)],[unref(BngSoundClass_default),`bng_click_hover_generic`]]),devEnv.simplemenu?createCommentVNode(``,!0):withDirectives((openBlock(),createBlock(unref(bngButton_default),{key:2,class:`btn-quit`,accent:unref(ACCENTS).attention,icon:unref(icons).exit,onClick:_cache[4]||=$event=>quitGame()},{default:withCtx(()=>[unref(bgRequired)?(openBlock(),createBlock(BlurBackground_default,{key:0})):createCommentVNode(``,!0),createBaseVNode(`div`,_hoisted_16$6,[createBaseVNode(`span`,_hoisted_17$5,toDisplayString(_ctx.$tt(`ui.inputActions.general.quit.title`)),1)])]),_:1},8,[`accent`,`icon`])),[[unref(BngBlur_default),!unref(bgRequired)],[unref(BngSoundClass_default),`bng_click_hover_generic`]])]))])),[[unref(BngOnUiNav_default),handleBack,`back`]])],34)),[[unref(BngScopedNav_default),{activateOnMount:!0,canDeactivate:canDeactivateScope,canBubbleEvent}],[unref(BngOnUiNav_default),handleBack,`menu`]])}}},MainMenu_default=__plugin_vue_export_helper_default(_sfc_main$73,[[`__scopeId`,`data-v-1c7a0195`]]),_hoisted_1$64={key:1,class:`fancy-bg-wrap`},_hoisted_2$53={class:`mask-container`},_hoisted_3$45={key:0,class:`icon-text`},_hoisted_4$33={key:2,class:`tag`},_hoisted_5$28={key:3,class:`icon`},_hoisted_6$22={key:4,class:`icon`},_hoisted_7$20={key:5,class:`label-container`},_hoisted_8$15={class:`text`},_hoisted_9$13={key:6,class:`text`},_sfc_main$72={__name:`MenuButton`,props:{size:{type:String,default:`normal`},iconId:String,icon:String,highlighted:Boolean,disabled:Boolean,appearDisabled:Boolean,bgImg:String,bgImgAbs:String,tag:String,noBlur:Boolean},setup(__props,{expose:__expose}){let props=__props,btnRef=ref(null);__expose({getElement(){return btnRef.value}});let bgImgUrl=computed(()=>props.bgImgAbs?props.bgImgAbs:getAssetURL(props.bgImg)),hasBgImg=computed(()=>props.bgImgAbs||props.bgImg);return(_ctx,_cache)=>withDirectives((openBlock(),createElementBlock(`div`,{ref_key:`btnRef`,ref:btnRef,class:normalizeClass({"mainmenu-button":!0,[`size-${__props.size}`]:!0,"fancy-bg":!!hasBgImg.value,"with-icon":!!__props.iconId,"semi-disabled":__props.appearDisabled}),style:normalizeStyle({"--fancy-bg-img":`url('${bgImgUrl.value}')`}),"bng-nav-item":``},[__props.noBlur?createCommentVNode(``,!0):(openBlock(),createBlock(BlurBackground_default,{key:0,class:normalizeClass(`corners-${__props.size}`)},null,8,[`class`])),createBaseVNode(`div`,{class:normalizeClass([`button-background`,{stack:__props.size===`big-stacked`,highlighted:__props.highlighted}])},null,2),hasBgImg.value?(openBlock(),createElementBlock(`div`,_hoisted_1$64,[createBaseVNode(`div`,{class:normalizeClass([`bg-container`,{"with-icon":!!__props.iconId}])},[_cache[0]||=createBaseVNode(`div`,{class:`bg-image`},null,-1),createBaseVNode(`div`,_hoisted_2$53,[__props.iconId?(openBlock(),createElementBlock(`div`,_hoisted_3$45,toDisplayString(unref(icons)[__props.iconId].glyph),1)):createCommentVNode(``,!0)])],2)])):createCommentVNode(``,!0),__props.tag?(openBlock(),createElementBlock(`div`,_hoisted_4$33,toDisplayString(__props.tag),1)):createCommentVNode(``,!0),__props.iconId&&!hasBgImg.value?(openBlock(),createElementBlock(`div`,_hoisted_5$28,[createVNode(unref(bngIcon_default),{type:unref(icons)[__props.iconId],color:hasBgImg.value?`transparent`:void 0},null,8,[`type`,`color`])])):__props.icon?(openBlock(),createElementBlock(`div`,_hoisted_6$22,[createVNode(unref(bngImageAsset_default),{externalSrc:__props.icon},null,8,[`externalSrc`])])):createCommentVNode(``,!0),__props.size==`big`||__props.size==`big-stacked`?(openBlock(),createElementBlock(`div`,_hoisted_7$20,[createBaseVNode(`span`,_hoisted_8$15,[renderSlot(_ctx.$slots,`default`,{},void 0,!0)])])):(openBlock(),createElementBlock(`span`,_hoisted_9$13,[renderSlot(_ctx.$slots,`default`,{},void 0,!0)]))],6)),[[unref(BngSoundClass_default),!(__props.disabled||__props.appearDisabled)&&`bng_click_hover_generic`],[unref(BngDisabled_default),__props.disabled],[unref(BngBlur_default),!__props.noBlur]])}},MenuButton_default=__plugin_vue_export_helper_default(_sfc_main$72,[[`__scopeId`,`data-v-932e6a9a`]]),_hoisted_1$63={class:`center-wrap`},_hoisted_2$52={class:`primary`},IMG_PATH=`images/mainmenu/`,_sfc_main$71={__name:`MainView`,props:{firstTime:Boolean},emits:[`changeView`],setup(__props,{emit:__emit}){let props=__props,emit$1=__emit;ref(null);let settings$1=useSettings(),defaultWizardStep=computed(()=>settings$1.getValue(`freeroamSetupDefaultStep`)||`level`),firstTime=ref(props.firstTime);onMounted(()=>{firstTime.value&&setTimeout(()=>firstTime.value=!1,1500)});let navigate$1=(state,params=void 0)=>nextTick(()=>window.bngVue.gotoGameState(state,{params}));async function careerPrompt(){await openExperimental($translate.instant(`ui.career.experimentalTitle`),$translate.instant(`ui.career.experimentalPrompt`),[{label:$translate.instant(`ui.common.no`),value:!1,isCancel:!0,extras:{accent:ACCENTS.secondary}},{label:$translate.instant(`ui.career.experimentalAgree`),value:!0,default:!0}])&&navigate$1(`profiles`)}return(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$63,[createBaseVNode(`div`,_hoisted_2$52,[createVNode(MenuButton_default,{"bng-scoped-nav-autofocus":``,size:`big`,"icon-id":`keys1`,"bg-img":IMG_PATH+`experiences.jpg`,onClick:_cache[0]||=$event=>emit$1(`changeView`,`discover`),tag:_ctx.$t(`ui.playmodes.new`)},{default:withCtx(()=>[createTextVNode(toDisplayString(_ctx.$tt(`ui.playmodes.quickStartExperiences`)),1)]),_:1},8,[`bg-img`,`tag`]),createVNode(MenuButton_default,{size:`big`,"icon-id":`road`,"bg-img":IMG_PATH+`freeroam.jpg`,onClick:_cache[1]||=$event=>navigate$1(`menu.freeroamWizard`,{step:defaultWizardStep.value})},{default:withCtx(()=>[createTextVNode(toDisplayString(_ctx.$tt(`ui.playmodes.freeroam`)),1)]),_:1},8,[`bg-img`]),_ctx.$simplemenu.value?createCommentVNode(``,!0):(openBlock(),createBlock(MenuButton_default,{key:0,"appear-disabled":``,size:`big`,"icon-id":`cup`,"bg-img":IMG_PATH+`career.jpg`,onClick:_cache[2]||=$event=>careerPrompt(),tag:_ctx.$t(`ui.playmodes.comingSoon`),"tag-orange":``},{default:withCtx(()=>[createTextVNode(toDisplayString(_ctx.$tt(`ui.playmodes.career`)),1)]),_:1},8,[`bg-img`,`tag`])),createVNode(MenuButton_default,{size:`big-stacked`,"icon-id":`BNGFolder`,"bg-img":IMG_PATH+`others.jpg`,onClick:_cache[3]||=$event=>emit$1(`changeView`,`others`)},{default:withCtx(()=>[createTextVNode(toDisplayString(_ctx.$tt(`ui.mainmenu.more`)),1)]),_:1},8,[`bg-img`])])]))}},MainView_default=__plugin_vue_export_helper_default(_sfc_main$71,[[`__scopeId`,`data-v-0baa6516`]]),_hoisted_1$62={class:`center-wrap`},_hoisted_2$51={class:`others`},_hoisted_3$44={class:`buttons`},htmlBody=`
            text-shadow: 1px 1px 2px #000a;
          `,overlayDiv.textContent=count$1.toString(),overlayElement.appendChild(overlayDiv),overlayDivs.set(element,overlayDiv)}catch{}}function updateOverlayText(){if(!overlayActive||overlayDivs.size===0)return;let appsStats=getUIAppsStats(),counts=appsStats.sortedList.map(item=>item.count),maxCount=Math.max(...counts,1),minCount=Math.min(...counts,0);for(let{element,count:count$1}of appsStats.sortedList){let overlayDiv=overlayDivs.get(element);overlayDiv&&(overlayDiv.textContent=count$1.toString(),overlayDiv.style.opacity=getOverlayOpacity(count$1,minCount,maxCount))}}function destroyOverlay(){overlayUpdateTimer&&=(clearInterval(overlayUpdateTimer),null),overlayDivs.forEach(overlayDiv=>overlayDiv.remove()),overlayDivs.clear(),overlayElement&&=(overlayElement.remove(),null),overlayActive=!1}function toggleOverlay(){return overlayActive?(destroyOverlay(),!1):(overlayActive=!0,createOverlay(),updateOverlayDivs(),overlayUpdateTimer=setInterval(updateOverlayText,500),!0)}function refreshOverlay(){overlayActive&&updateOverlayDivs()}var isBrowser=typeof document<`u`;function isRouteComponent(component){return typeof component==`object`||`displayName`in component||`props`in component||`__vccOpts`in component}function isESModule(obj){return obj.__esModule||obj[Symbol.toStringTag]===`Module`||obj.default&&isRouteComponent(obj.default)}var assign=Object.assign;function applyToParams(fn,params){let newParams={};for(let key in params){let value=params[key];newParams[key]=isArray(value)?value.map(fn):fn(value)}return newParams}var noop$1=()=>{},isArray=Array.isArray;function mergeOptions(defaults,partialOptions){let options={};for(let key in defaults)options[key]=key in partialOptions?partialOptions[key]:defaults[key];return options}var HASH_RE=/#/g,AMPERSAND_RE=/&/g,SLASH_RE=/\//g,EQUAL_RE=/=/g,IM_RE=/\?/g,PLUS_RE=/\+/g,ENC_BRACKET_OPEN_RE=/%5B/g,ENC_BRACKET_CLOSE_RE=/%5D/g,ENC_CARET_RE=/%5E/g,ENC_BACKTICK_RE=/%60/g,ENC_CURLY_OPEN_RE=/%7B/g,ENC_PIPE_RE=/%7C/g,ENC_CURLY_CLOSE_RE=/%7D/g,ENC_SPACE_RE=/%20/g;function commonEncode(text){return text==null?``:encodeURI(``+text).replace(ENC_PIPE_RE,`|`).replace(ENC_BRACKET_OPEN_RE,`[`).replace(ENC_BRACKET_CLOSE_RE,`]`)}function encodeHash(text){return commonEncode(text).replace(ENC_CURLY_OPEN_RE,`{`).replace(ENC_CURLY_CLOSE_RE,`}`).replace(ENC_CARET_RE,`^`)}function encodeQueryValue(text){return commonEncode(text).replace(PLUS_RE,`%2B`).replace(ENC_SPACE_RE,`+`).replace(HASH_RE,`%23`).replace(AMPERSAND_RE,`%26`).replace(ENC_BACKTICK_RE,"`").replace(ENC_CURLY_OPEN_RE,`{`).replace(ENC_CURLY_CLOSE_RE,`}`).replace(ENC_CARET_RE,`^`)}function encodeQueryKey(text){return encodeQueryValue(text).replace(EQUAL_RE,`%3D`)}function encodePath(text){return commonEncode(text).replace(HASH_RE,`%23`).replace(IM_RE,`%3F`)}function encodeParam(text){return encodePath(text).replace(SLASH_RE,`%2F`)}function decode(text){if(text==null)return null;try{return decodeURIComponent(``+text)}catch{}return``+text}var TRAILING_SLASH_RE=/\/$/,removeTrailingSlash=path=>path.replace(TRAILING_SLASH_RE,``);function parseURL(parseQuery$1,location$1,currentLocation=`/`){let path,query={},searchString=``,hash=``,hashPos=location$1.indexOf(`#`),searchPos=location$1.indexOf(`?`);return searchPos=hashPos>=0&&searchPos>hashPos?-1:searchPos,searchPos>=0&&(path=location$1.slice(0,searchPos),searchString=location$1.slice(searchPos,hashPos>0?hashPos:location$1.length),query=parseQuery$1(searchString.slice(1))),hashPos>=0&&(path||=location$1.slice(0,hashPos),hash=location$1.slice(hashPos,location$1.length)),path=resolveRelativePath(path??location$1,currentLocation),{fullPath:path+searchString+hash,path,query,hash:decode(hash)}}function stringifyURL(stringifyQuery$1,location$1){let query=location$1.query?stringifyQuery$1(location$1.query):``;return location$1.path+(query&&`?`)+query+(location$1.hash||``)}function stripBase(pathname,base){return!base||!pathname.toLowerCase().startsWith(base.toLowerCase())?pathname:pathname.slice(base.length)||`/`}function isSameRouteLocation(stringifyQuery$1,a$1,b){let aLastIndex=a$1.matched.length-1,bLastIndex=b.matched.length-1;return aLastIndex>-1&&aLastIndex===bLastIndex&&isSameRouteRecord(a$1.matched[aLastIndex],b.matched[bLastIndex])&&isSameRouteLocationParams(a$1.params,b.params)&&stringifyQuery$1(a$1.query)===stringifyQuery$1(b.query)&&a$1.hash===b.hash}function isSameRouteRecord(a$1,b){return(a$1.aliasOf||a$1)===(b.aliasOf||b)}function isSameRouteLocationParams(a$1,b){if(Object.keys(a$1).length!==Object.keys(b).length)return!1;for(let key in a$1)if(!isSameRouteLocationParamsValue(a$1[key],b[key]))return!1;return!0}function isSameRouteLocationParamsValue(a$1,b){return isArray(a$1)?isEquivalentArray(a$1,b):isArray(b)?isEquivalentArray(b,a$1):a$1===b}function isEquivalentArray(a$1,b){return isArray(b)?a$1.length===b.length&&a$1.every((value,i)=>value===b[i]):a$1.length===1&&a$1[0]===b}function resolveRelativePath(to,from){if(to.startsWith(`/`))return to;if(!to)return from;let fromSegments=from.split(`/`),toSegments=to.split(`/`),lastToSegment=toSegments[toSegments.length-1];(lastToSegment===`..`||lastToSegment===`.`)&&toSegments.push(``);let position=fromSegments.length-1,toPosition,segment;for(toPosition=0;toPosition1&&position--;else break;return fromSegments.slice(0,position).join(`/`)+`/`+toSegments.slice(toPosition).join(`/`)}var START_LOCATION_NORMALIZED={path:`/`,name:void 0,params:{},query:{},hash:``,fullPath:`/`,matched:[],meta:{},redirectedFrom:void 0},NavigationType=function(NavigationType$1){return NavigationType$1.pop=`pop`,NavigationType$1.push=`push`,NavigationType$1}({}),NavigationDirection=function(NavigationDirection$1){return NavigationDirection$1.back=`back`,NavigationDirection$1.forward=`forward`,NavigationDirection$1.unknown=``,NavigationDirection$1}({});function normalizeBase(base){if(!base)if(isBrowser){let baseEl=document.querySelector(`base`);base=baseEl&&baseEl.getAttribute(`href`)||`/`,base=base.replace(/^\w+:\/\/[^\/]+/,``)}else base=`/`;return base[0]!==`/`&&base[0]!==`#`&&(base=`/`+base),removeTrailingSlash(base)}var BEFORE_HASH_RE=/^[^#]+#/;function createHref(base,location$1){return base.replace(BEFORE_HASH_RE,`#`)+location$1}function getElementPosition(el,offset$2){let docRect=document.documentElement.getBoundingClientRect(),elRect=el.getBoundingClientRect();return{behavior:offset$2.behavior,left:elRect.left-docRect.left-(offset$2.left||0),top:elRect.top-docRect.top-(offset$2.top||0)}}var computeScrollPosition=()=>({left:window.scrollX,top:window.scrollY});function scrollToPosition(position){let scrollToOptions;if(`el`in position){let positionEl=position.el,isIdSelector=typeof positionEl==`string`&&positionEl.startsWith(`#`),el=typeof positionEl==`string`?isIdSelector?document.getElementById(positionEl.slice(1)):document.querySelector(positionEl):positionEl;if(!el)return;scrollToOptions=getElementPosition(el,position)}else scrollToOptions=position;`scrollBehavior`in document.documentElement.style?window.scrollTo(scrollToOptions):window.scrollTo(scrollToOptions.left==null?window.scrollX:scrollToOptions.left,scrollToOptions.top==null?window.scrollY:scrollToOptions.top)}function getScrollKey(path,delta){return(history.state?history.state.position-delta:-1)+path}var scrollPositions=new Map;function saveScrollPosition(key,scrollPosition){scrollPositions.set(key,scrollPosition)}function getSavedScrollPosition(key){let scroll$1=scrollPositions.get(key);return scrollPositions.delete(key),scroll$1}function isRouteLocation(route){return typeof route==`string`||route&&typeof route==`object`}function isRouteName(name){return typeof name==`string`||typeof name==`symbol`}var ErrorTypes=function(ErrorTypes$1){return ErrorTypes$1[ErrorTypes$1.MATCHER_NOT_FOUND=1]=`MATCHER_NOT_FOUND`,ErrorTypes$1[ErrorTypes$1.NAVIGATION_GUARD_REDIRECT=2]=`NAVIGATION_GUARD_REDIRECT`,ErrorTypes$1[ErrorTypes$1.NAVIGATION_ABORTED=4]=`NAVIGATION_ABORTED`,ErrorTypes$1[ErrorTypes$1.NAVIGATION_CANCELLED=8]=`NAVIGATION_CANCELLED`,ErrorTypes$1[ErrorTypes$1.NAVIGATION_DUPLICATED=16]=`NAVIGATION_DUPLICATED`,ErrorTypes$1}({}),NavigationFailureSymbol=Symbol(``);ErrorTypes.MATCHER_NOT_FOUND,ErrorTypes.NAVIGATION_GUARD_REDIRECT,ErrorTypes.NAVIGATION_ABORTED,ErrorTypes.NAVIGATION_CANCELLED,ErrorTypes.NAVIGATION_DUPLICATED;function createRouterError(type,params){return assign(Error(),{type,[NavigationFailureSymbol]:!0},params)}function isNavigationFailure(error,type){return error instanceof Error&&NavigationFailureSymbol in error&&(type==null||!!(error.type&type))}function parseQuery(search$1){let query={};if(search$1===``||search$1===`?`)return query;let searchParams=(search$1[0]===`?`?search$1.slice(1):search$1).split(`&`);for(let i=0;iv&&encodeQueryValue(v)):[value&&encodeQueryValue(value)]).forEach(value$1=>{value$1!==void 0&&(search$1+=(search$1.length?`&`:``)+key,value$1!=null&&(search$1+=`=`+value$1))})}return search$1}function normalizeQuery(query){let normalizedQuery={};for(let key in query){let value=query[key];value!==void 0&&(normalizedQuery[key]=isArray(value)?value.map(v=>v==null?null:``+v):value==null?value:``+value)}return normalizedQuery}var matchedRouteKey=Symbol(``),viewDepthKey=Symbol(``),routerKey=Symbol(``),routeLocationKey=Symbol(``),routerViewLocationKey=Symbol(``);function useCallbacks(){let handlers$1=[];function add$2(handler$1){return handlers$1.push(handler$1),()=>{let i=handlers$1.indexOf(handler$1);i>-1&&handlers$1.splice(i,1)}}function reset$1(){handlers$1=[]}return{add:add$2,list:()=>handlers$1.slice(),reset:reset$1}}function guardToPromiseFn(guard,to,from,record,name,runWithContext=fn=>fn()){let enterCallbackArray=record&&(record.enterCallbacks[name]=record.enterCallbacks[name]||[]);return()=>new Promise((resolve$1,reject)=>{let next=valid=>{valid===!1?reject(createRouterError(ErrorTypes.NAVIGATION_ABORTED,{from,to})):valid instanceof Error?reject(valid):isRouteLocation(valid)?reject(createRouterError(ErrorTypes.NAVIGATION_GUARD_REDIRECT,{from:to,to:valid})):(enterCallbackArray&&record.enterCallbacks[name]===enterCallbackArray&&typeof valid==`function`&&enterCallbackArray.push(valid),resolve$1())},guardReturn=runWithContext(()=>guard.call(record&&record.instances[name],to,from,next)),guardCall=Promise.resolve(guardReturn);guard.length<3&&(guardCall=guardCall.then(next)),guardCall.catch(err=>reject(err))})}function extractComponentsGuards(matched,guardType,to,from,runWithContext=fn=>fn()){let guards=[];for(let record of matched)for(let name in record.components){let rawComponent=record.components[name];if(!(guardType!==`beforeRouteEnter`&&!record.instances[name]))if(isRouteComponent(rawComponent)){let guard=(rawComponent.__vccOpts||rawComponent)[guardType];guard&&guards.push(guardToPromiseFn(guard,to,from,record,name,runWithContext))}else{let componentPromise=rawComponent();guards.push(()=>componentPromise.then(resolved=>{if(!resolved)throw Error(`Couldn't resolve component "${name}" at "${record.path}"`);let resolvedComponent=isESModule(resolved)?resolved.default:resolved;record.mods[name]=resolved,record.components[name]=resolvedComponent;let guard=(resolvedComponent.__vccOpts||resolvedComponent)[guardType];return guard&&guardToPromiseFn(guard,to,from,record,name,runWithContext)()}))}}return guards}function extractChangingRecords(to,from){let leavingRecords=[],updatingRecords=[],enteringRecords=[],len=Math.max(from.matched.length,to.matched.length);for(let i=0;iisSameRouteRecord(record,recordFrom))?updatingRecords.push(recordFrom):leavingRecords.push(recordFrom));let recordTo=to.matched[i];recordTo&&(from.matched.find(record=>isSameRouteRecord(record,recordTo))||enteringRecords.push(recordTo))}return[leavingRecords,updatingRecords,enteringRecords]}var createBaseLocation=()=>location.protocol+`//`+location.host;function createCurrentLocation(base,location$1){let{pathname,search:search$1,hash}=location$1,hashPos=base.indexOf(`#`);if(hashPos>-1){let slicePos=hash.includes(base.slice(hashPos))?base.slice(hashPos).length:1,pathFromHash=hash.slice(slicePos);return pathFromHash[0]!==`/`&&(pathFromHash=`/`+pathFromHash),stripBase(pathFromHash,``)}return stripBase(pathname,base)+search$1+hash}function useHistoryListeners(base,historyState,currentLocation,replace){let listeners=[],teardowns=[],pauseState=null,popStateHandler=({state})=>{let to=createCurrentLocation(base,location),from=currentLocation.value,fromState=historyState.value,delta=0;if(state){if(currentLocation.value=to,historyState.value=state,pauseState&&pauseState===from){pauseState=null;return}delta=fromState?state.position-fromState.position:0}else replace(to);listeners.forEach(listener=>{listener(currentLocation.value,from,{delta,type:NavigationType.pop,direction:delta?delta>0?NavigationDirection.forward:NavigationDirection.back:NavigationDirection.unknown})})};function pauseListeners(){pauseState=currentLocation.value}function listen(callback){listeners.push(callback);let teardown=()=>{let index=listeners.indexOf(callback);index>-1&&listeners.splice(index,1)};return teardowns.push(teardown),teardown}function beforeUnloadListener(){if(document.visibilityState===`hidden`){let{history:history$1}=window;if(!history$1.state)return;history$1.replaceState(assign({},history$1.state,{scroll:computeScrollPosition()}),``)}}function destroy$1(){for(let teardown of teardowns)teardown();teardowns=[],window.removeEventListener(`popstate`,popStateHandler),window.removeEventListener(`pagehide`,beforeUnloadListener),document.removeEventListener(`visibilitychange`,beforeUnloadListener)}return window.addEventListener(`popstate`,popStateHandler),window.addEventListener(`pagehide`,beforeUnloadListener),document.addEventListener(`visibilitychange`,beforeUnloadListener),{pauseListeners,listen,destroy:destroy$1}}function buildState(back,current,forward,replaced=!1,computeScroll=!1){return{back,current,forward,replaced,position:window.history.length,scroll:computeScroll?computeScrollPosition():null}}function useHistoryStateNavigation(base){let{history:history$1,location:location$1}=window,currentLocation={value:createCurrentLocation(base,location$1)},historyState={value:history$1.state};historyState.value||changeLocation(currentLocation.value,{back:null,current:currentLocation.value,forward:null,position:history$1.length-1,replaced:!0,scroll:null},!0);function changeLocation(to,state,replace$1){let hashIndex=base.indexOf(`#`),url=hashIndex>-1?(location$1.host&&document.querySelector(`base`)?base:base.slice(hashIndex))+to:createBaseLocation()+base+to;try{history$1[replace$1?`replaceState`:`pushState`](state,``,url),historyState.value=state}catch(err){console.error(err),location$1[replace$1?`replace`:`assign`](url)}}function replace(to,data){changeLocation(to,assign({},history$1.state,buildState(historyState.value.back,to,historyState.value.forward,!0),data,{position:historyState.value.position}),!0),currentLocation.value=to}function push(to,data){let currentState=assign({},historyState.value,history$1.state,{forward:to,scroll:computeScrollPosition()});changeLocation(currentState.current,currentState,!0),changeLocation(to,assign({},buildState(currentLocation.value,to,null),{position:currentState.position+1},data),!1),currentLocation.value=to}return{location:currentLocation,state:historyState,push,replace}}function createWebHistory(base){base=normalizeBase(base);let historyNavigation=useHistoryStateNavigation(base),historyListeners=useHistoryListeners(base,historyNavigation.state,historyNavigation.location,historyNavigation.replace);function go(delta,triggerListeners=!0){triggerListeners||historyListeners.pauseListeners(),history.go(delta)}let routerHistory=assign({location:``,base,go,createHref:createHref.bind(null,base)},historyNavigation,historyListeners);return Object.defineProperty(routerHistory,`location`,{enumerable:!0,get:()=>historyNavigation.location.value}),Object.defineProperty(routerHistory,`state`,{enumerable:!0,get:()=>historyNavigation.state.value}),routerHistory}function createWebHashHistory(base){return base=location.host?base||location.pathname+location.search:``,base.includes(`#`)||(base+=`#`),createWebHistory(base)}var TokenType=function(TokenType$1){return TokenType$1[TokenType$1.Static=0]=`Static`,TokenType$1[TokenType$1.Param=1]=`Param`,TokenType$1[TokenType$1.Group=2]=`Group`,TokenType$1}({}),TokenizerState=function(TokenizerState$1){return TokenizerState$1[TokenizerState$1.Static=0]=`Static`,TokenizerState$1[TokenizerState$1.Param=1]=`Param`,TokenizerState$1[TokenizerState$1.ParamRegExp=2]=`ParamRegExp`,TokenizerState$1[TokenizerState$1.ParamRegExpEnd=3]=`ParamRegExpEnd`,TokenizerState$1[TokenizerState$1.EscapeNext=4]=`EscapeNext`,TokenizerState$1}(TokenizerState||{}),ROOT_TOKEN={type:TokenType.Static,value:``},VALID_PARAM_RE=/[a-zA-Z0-9_]/;function tokenizePath(path){if(!path)return[[]];if(path===`/`)return[[ROOT_TOKEN]];if(!path.startsWith(`/`))throw Error(`Invalid path "${path}"`);function crash(message){throw Error(`ERR (${state})/"${buffer$1}": ${message}`)}let state=TokenizerState.Static,previousState=state,tokens=[],segment;function finalizeSegment(){segment&&tokens.push(segment),segment=[]}let i=0,char,buffer$1=``,customRe=``;function consumeBuffer(){buffer$1&&=(state===TokenizerState.Static?segment.push({type:TokenType.Static,value:buffer$1}):state===TokenizerState.Param||state===TokenizerState.ParamRegExp||state===TokenizerState.ParamRegExpEnd?(segment.length>1&&(char===`*`||char===`+`)&&crash(`A repeatable param (${buffer$1}) must be alone in its segment. eg: '/:ids+.`),segment.push({type:TokenType.Param,value:buffer$1,regexp:customRe,repeatable:char===`*`||char===`+`,optional:char===`*`||char===`?`})):crash(`Invalid state to consume buffer`),``)}function addCharToBuffer(){buffer$1+=char}for(;ib.length?b.length===1&&b[0]===PathScore.Static+PathScore.Segment?1:-1:0}function comparePathParserScore(a$1,b){let i=0,aScore=a$1.score,bScore=b.score;for(;i0&&last[last.length-1]<0}var PATH_PARSER_OPTIONS_DEFAULTS={strict:!1,end:!0,sensitive:!1};function createRouteRecordMatcher(record,parent,options){let matcher=assign(tokensToParser(tokenizePath(record.path),options),{record,parent,children:[],alias:[]});return parent&&!matcher.record.aliasOf==!parent.record.aliasOf&&parent.children.push(matcher),matcher}function createRouterMatcher(routes,globalOptions){let matchers=[],matcherMap=new Map;globalOptions=mergeOptions(PATH_PARSER_OPTIONS_DEFAULTS,globalOptions);function getRecordMatcher(name){return matcherMap.get(name)}function addRoute(record,parent,originalRecord){let isRootAdd=!originalRecord,mainNormalizedRecord=normalizeRouteRecord(record);mainNormalizedRecord.aliasOf=originalRecord&&originalRecord.record;let options=mergeOptions(globalOptions,record),normalizedRecords=[mainNormalizedRecord];if(`alias`in record){let aliases=typeof record.alias==`string`?[record.alias]:record.alias;for(let alias of aliases)normalizedRecords.push(normalizeRouteRecord(assign({},mainNormalizedRecord,{components:originalRecord?originalRecord.record.components:mainNormalizedRecord.components,path:alias,aliasOf:originalRecord?originalRecord.record:mainNormalizedRecord})))}let matcher,originalMatcher;for(let normalizedRecord of normalizedRecords){let{path}=normalizedRecord;if(parent&&path[0]!==`/`){let parentPath=parent.record.path,connectingSlash=parentPath[parentPath.length-1]===`/`?``:`/`;normalizedRecord.path=parent.record.path+(path&&connectingSlash+path)}if(matcher=createRouteRecordMatcher(normalizedRecord,parent,options),originalRecord?originalRecord.alias.push(matcher):(originalMatcher||=matcher,originalMatcher!==matcher&&originalMatcher.alias.push(matcher),isRootAdd&&record.name&&!isAliasRecord(matcher)&&removeRoute(record.name)),isMatchable(matcher)&&insertMatcher(matcher),mainNormalizedRecord.children){let children=mainNormalizedRecord.children;for(let i=0;i{removeRoute(originalMatcher)}:noop$1}function removeRoute(matcherRef){if(isRouteName(matcherRef)){let matcher=matcherMap.get(matcherRef);matcher&&(matcherMap.delete(matcherRef),matchers.splice(matchers.indexOf(matcher),1),matcher.children.forEach(removeRoute),matcher.alias.forEach(removeRoute))}else{let index=matchers.indexOf(matcherRef);index>-1&&(matchers.splice(index,1),matcherRef.record.name&&matcherMap.delete(matcherRef.record.name),matcherRef.children.forEach(removeRoute),matcherRef.alias.forEach(removeRoute))}}function getRoutes(){return matchers}function insertMatcher(matcher){let index=findInsertionIndex(matcher,matchers);matchers.splice(index,0,matcher),matcher.record.name&&!isAliasRecord(matcher)&&matcherMap.set(matcher.record.name,matcher)}function resolve$1(location$1,currentLocation){let matcher,params={},path,name;if(`name`in location$1&&location$1.name){if(matcher=matcherMap.get(location$1.name),!matcher)throw createRouterError(ErrorTypes.MATCHER_NOT_FOUND,{location:location$1});name=matcher.record.name,params=assign(pickParams(currentLocation.params,matcher.keys.filter(k=>!k.optional).concat(matcher.parent?matcher.parent.keys.filter(k=>k.optional):[]).map(k=>k.name)),location$1.params&&pickParams(location$1.params,matcher.keys.map(k=>k.name))),path=matcher.stringify(params)}else if(location$1.path!=null)path=location$1.path,matcher=matchers.find(m=>m.re.test(path)),matcher&&(params=matcher.parse(path),name=matcher.record.name);else{if(matcher=currentLocation.name?matcherMap.get(currentLocation.name):matchers.find(m=>m.re.test(currentLocation.path)),!matcher)throw createRouterError(ErrorTypes.MATCHER_NOT_FOUND,{location:location$1,currentLocation});name=matcher.record.name,params=assign({},currentLocation.params,location$1.params),path=matcher.stringify(params)}let matched=[],parentMatcher=matcher;for(;parentMatcher;)matched.unshift(parentMatcher.record),parentMatcher=parentMatcher.parent;return{name,path,params,matched,meta:mergeMetaFields(matched)}}routes.forEach(route=>addRoute(route));function clearRoutes(){matchers.length=0,matcherMap.clear()}return{addRoute,resolve:resolve$1,removeRoute,clearRoutes,getRoutes,getRecordMatcher}}function pickParams(params,keys){let newParams={};for(let key of keys)key in params&&(newParams[key]=params[key]);return newParams}function normalizeRouteRecord(record){let normalized={path:record.path,redirect:record.redirect,name:record.name,meta:record.meta||{},aliasOf:record.aliasOf,beforeEnter:record.beforeEnter,props:normalizeRecordProps(record),children:record.children||[],instances:{},leaveGuards:new Set,updateGuards:new Set,enterCallbacks:{},components:`components`in record?record.components||null:record.component&&{default:record.component}};return Object.defineProperty(normalized,`mods`,{value:{}}),normalized}function normalizeRecordProps(record){let propsObject={},props=record.props||!1;if(`component`in record)propsObject.default=props;else for(let name in record.components)propsObject[name]=typeof props==`object`?props[name]:props;return propsObject}function isAliasRecord(record){for(;record;){if(record.record.aliasOf)return!0;record=record.parent}return!1}function mergeMetaFields(matched){return matched.reduce((meta,record)=>assign(meta,record.meta),{})}function findInsertionIndex(matcher,matchers){let lower=0,upper=matchers.length;for(;lower!==upper;){let mid=lower+upper>>1;comparePathParserScore(matcher,matchers[mid])<0?upper=mid:lower=mid+1}let insertionAncestor=getInsertionAncestor(matcher);return insertionAncestor&&(upper=matchers.lastIndexOf(insertionAncestor,upper-1)),upper}function getInsertionAncestor(matcher){let ancestor=matcher;for(;ancestor=ancestor.parent;)if(isMatchable(ancestor)&&comparePathParserScore(matcher,ancestor)===0)return ancestor}function isMatchable({record}){return!!(record.name||record.components&&Object.keys(record.components).length||record.redirect)}function useLink(props){let router$1=inject(routerKey),currentRoute=inject(routeLocationKey),route=computed(()=>{let to=unref(props.to);return router$1.resolve(to)}),activeRecordIndex=computed(()=>{let{matched}=route.value,{length}=matched,routeMatched=matched[length-1],currentMatched=currentRoute.matched;if(!routeMatched||!currentMatched.length)return-1;let index=currentMatched.findIndex(isSameRouteRecord.bind(null,routeMatched));if(index>-1)return index;let parentRecordPath=getOriginalPath(matched[length-2]);return length>1&&getOriginalPath(routeMatched)===parentRecordPath&¤tMatched[currentMatched.length-1].path!==parentRecordPath?currentMatched.findIndex(isSameRouteRecord.bind(null,matched[length-2])):index}),isActive=computed(()=>activeRecordIndex.value>-1&&includesParams(currentRoute.params,route.value.params)),isExactActive=computed(()=>activeRecordIndex.value>-1&&activeRecordIndex.value===currentRoute.matched.length-1&&isSameRouteLocationParams(currentRoute.params,route.value.params));function navigate$1(e={}){if(guardEvent(e)){let p$1=router$1[unref(props.replace)?`replace`:`push`](unref(props.to)).catch(noop$1);return props.viewTransition&&typeof document<`u`&&`startViewTransition`in document&&document.startViewTransition(()=>p$1),p$1}return Promise.resolve()}return{route,href:computed(()=>route.value.href),isActive,isExactActive,navigate:navigate$1}}function preferSingleVNode(vnodes){return vnodes.length===1?vnodes[0]:vnodes}var RouterLink=defineComponent({name:`RouterLink`,compatConfig:{MODE:3},props:{to:{type:[String,Object],required:!0},replace:Boolean,activeClass:String,exactActiveClass:String,custom:Boolean,ariaCurrentValue:{type:String,default:`page`},viewTransition:Boolean},useLink,setup(props,{slots}){let link=reactive(useLink(props)),{options}=inject(routerKey),elClass=computed(()=>({[getLinkClass(props.activeClass,options.linkActiveClass,`router-link-active`)]:link.isActive,[getLinkClass(props.exactActiveClass,options.linkExactActiveClass,`router-link-exact-active`)]:link.isExactActive}));return()=>{let children=slots.default&&preferSingleVNode(slots.default(link));return props.custom?children:h(`a`,{"aria-current":link.isExactActive?props.ariaCurrentValue:null,href:link.href,onClick:link.navigate,class:elClass.value},children)}}});function guardEvent(e){if(!(e.metaKey||e.altKey||e.ctrlKey||e.shiftKey)&&!e.defaultPrevented&&!(e.button!==void 0&&e.button!==0)){if(e.currentTarget&&e.currentTarget.getAttribute){let target=e.currentTarget.getAttribute(`target`);if(/\b_blank\b/i.test(target))return}return e.preventDefault&&e.preventDefault(),!0}}function includesParams(outer,inner){for(let key in inner){let innerValue=inner[key],outerValue=outer[key];if(typeof innerValue==`string`){if(innerValue!==outerValue)return!1}else if(!isArray(outerValue)||outerValue.length!==innerValue.length||innerValue.some((value,i)=>value!==outerValue[i]))return!1}return!0}function getOriginalPath(record){return record?record.aliasOf?record.aliasOf.path:record.path:``}var getLinkClass=(propClass,globalClass,defaultClass)=>propClass??globalClass??defaultClass,RouterViewImpl=defineComponent({name:`RouterView`,inheritAttrs:!1,props:{name:{type:String,default:`default`},route:Object},compatConfig:{MODE:3},setup(props,{attrs,slots}){let injectedRoute=inject(routerViewLocationKey),routeToDisplay=computed(()=>props.route||injectedRoute.value),injectedDepth=inject(viewDepthKey,0),depth=computed(()=>{let initialDepth=unref(injectedDepth),{matched}=routeToDisplay.value,matchedRoute;for(;(matchedRoute=matched[initialDepth])&&!matchedRoute.components;)initialDepth++;return initialDepth}),matchedRouteRef=computed(()=>routeToDisplay.value.matched[depth.value]);provide(viewDepthKey,computed(()=>depth.value+1)),provide(matchedRouteKey,matchedRouteRef),provide(routerViewLocationKey,routeToDisplay);let viewRef=ref();return watch(()=>[viewRef.value,matchedRouteRef.value,props.name],([instance$1,to,name],[oldInstance,from,oldName])=>{to&&(to.instances[name]=instance$1,from&&from!==to&&instance$1&&instance$1===oldInstance&&(to.leaveGuards.size||(to.leaveGuards=from.leaveGuards),to.updateGuards.size||(to.updateGuards=from.updateGuards))),instance$1&&to&&(!from||!isSameRouteRecord(to,from)||!oldInstance)&&(to.enterCallbacks[name]||[]).forEach(callback=>callback(instance$1))},{flush:`post`}),()=>{let route=routeToDisplay.value,currentName=props.name,matchedRoute=matchedRouteRef.value,ViewComponent=matchedRoute&&matchedRoute.components[currentName];if(!ViewComponent)return normalizeSlot(slots.default,{Component:ViewComponent,route});let routePropsOption=matchedRoute.props[currentName],component=h(ViewComponent,assign({},routePropsOption?routePropsOption===!0?route.params:typeof routePropsOption==`function`?routePropsOption(route):routePropsOption:null,attrs,{onVnodeUnmounted:vnode=>{vnode.component.isUnmounted&&(matchedRoute.instances[currentName]=null)},ref:viewRef}));return normalizeSlot(slots.default,{Component:component,route})||component}}});function normalizeSlot(slot,data){if(!slot)return null;let slotContent=slot(data);return slotContent.length===1?slotContent[0]:slotContent}var RouterView=RouterViewImpl;function createRouter(options){let matcher=createRouterMatcher(options.routes,options),parseQuery$1=options.parseQuery||parseQuery,stringifyQuery$1=options.stringifyQuery||stringifyQuery,routerHistory=options.history,beforeGuards=useCallbacks(),beforeResolveGuards=useCallbacks(),afterGuards=useCallbacks(),currentRoute=shallowRef(START_LOCATION_NORMALIZED),pendingLocation=START_LOCATION_NORMALIZED;isBrowser&&options.scrollBehavior&&`scrollRestoration`in history&&(history.scrollRestoration=`manual`);let normalizeParams=applyToParams.bind(null,paramValue=>``+paramValue),encodeParams=applyToParams.bind(null,encodeParam),decodeParams=applyToParams.bind(null,decode);function addRoute(parentOrRoute,route){let parent,record;return isRouteName(parentOrRoute)?(parent=matcher.getRecordMatcher(parentOrRoute),record=route):record=parentOrRoute,matcher.addRoute(record,parent)}function removeRoute(name){let recordMatcher=matcher.getRecordMatcher(name);recordMatcher&&matcher.removeRoute(recordMatcher)}function getRoutes(){return matcher.getRoutes().map(routeMatcher=>routeMatcher.record)}function hasRoute(name){return!!matcher.getRecordMatcher(name)}function resolve$1(rawLocation,currentLocation){if(currentLocation=assign({},currentLocation||currentRoute.value),typeof rawLocation==`string`){let locationNormalized=parseURL(parseQuery$1,rawLocation,currentLocation.path),matchedRoute$1=matcher.resolve({path:locationNormalized.path},currentLocation),href$1=routerHistory.createHref(locationNormalized.fullPath);return assign(locationNormalized,matchedRoute$1,{params:decodeParams(matchedRoute$1.params),hash:decode(locationNormalized.hash),redirectedFrom:void 0,href:href$1})}let matcherLocation;if(rawLocation.path!=null)matcherLocation=assign({},rawLocation,{path:parseURL(parseQuery$1,rawLocation.path,currentLocation.path).path});else{let targetParams=assign({},rawLocation.params);for(let key in targetParams)targetParams[key]??delete targetParams[key];matcherLocation=assign({},rawLocation,{params:encodeParams(targetParams)}),currentLocation.params=encodeParams(currentLocation.params)}let matchedRoute=matcher.resolve(matcherLocation,currentLocation),hash=rawLocation.hash||``;matchedRoute.params=normalizeParams(decodeParams(matchedRoute.params));let fullPath=stringifyURL(stringifyQuery$1,assign({},rawLocation,{hash:encodeHash(hash),path:matchedRoute.path})),href=routerHistory.createHref(fullPath);return assign({fullPath,hash,query:stringifyQuery$1===stringifyQuery?normalizeQuery(rawLocation.query):rawLocation.query||{}},matchedRoute,{redirectedFrom:void 0,href})}function locationAsObject(to){return typeof to==`string`?parseURL(parseQuery$1,to,currentRoute.value.path):assign({},to)}function checkCanceledNavigation(to,from){if(pendingLocation!==to)return createRouterError(ErrorTypes.NAVIGATION_CANCELLED,{from,to})}function push(to){return pushWithRedirect(to)}function replace(to){return push(assign(locationAsObject(to),{replace:!0}))}function handleRedirectRecord(to,from){let lastMatched=to.matched[to.matched.length-1];if(lastMatched&&lastMatched.redirect){let{redirect}=lastMatched,newTargetLocation=typeof redirect==`function`?redirect(to,from):redirect;return typeof newTargetLocation==`string`&&(newTargetLocation=newTargetLocation.includes(`?`)||newTargetLocation.includes(`#`)?newTargetLocation=locationAsObject(newTargetLocation):{path:newTargetLocation},newTargetLocation.params={}),assign({query:to.query,hash:to.hash,params:newTargetLocation.path==null?to.params:{}},newTargetLocation)}}function pushWithRedirect(to,redirectedFrom){let targetLocation=pendingLocation=resolve$1(to),from=currentRoute.value,data=to.state,force=to.force,replace$1=to.replace===!0,shouldRedirect=handleRedirectRecord(targetLocation,from);if(shouldRedirect)return pushWithRedirect(assign(locationAsObject(shouldRedirect),{state:typeof shouldRedirect==`object`?assign({},data,shouldRedirect.state):data,force,replace:replace$1}),redirectedFrom||targetLocation);let toLocation=targetLocation;toLocation.redirectedFrom=redirectedFrom;let failure;return!force&&isSameRouteLocation(stringifyQuery$1,from,targetLocation)&&(failure=createRouterError(ErrorTypes.NAVIGATION_DUPLICATED,{to:toLocation,from}),handleScroll(from,from,!0,!1)),(failure?Promise.resolve(failure):navigate$1(toLocation,from)).catch(error=>isNavigationFailure(error)?isNavigationFailure(error,ErrorTypes.NAVIGATION_GUARD_REDIRECT)?error:markAsReady(error):triggerError(error,toLocation,from)).then(failure$1=>{if(failure$1){if(isNavigationFailure(failure$1,ErrorTypes.NAVIGATION_GUARD_REDIRECT))return pushWithRedirect(assign({replace:replace$1},locationAsObject(failure$1.to),{state:typeof failure$1.to==`object`?assign({},data,failure$1.to.state):data,force}),redirectedFrom||toLocation)}else failure$1=finalizeNavigation(toLocation,from,!0,replace$1,data);return triggerAfterEach(toLocation,from,failure$1),failure$1})}function checkCanceledNavigationAndReject(to,from){let error=checkCanceledNavigation(to,from);return error?Promise.reject(error):Promise.resolve()}function runWithContext(fn){let app$1=installedApps.values().next().value;return app$1&&typeof app$1.runWithContext==`function`?app$1.runWithContext(fn):fn()}function navigate$1(to,from){let guards,[leavingRecords,updatingRecords,enteringRecords]=extractChangingRecords(to,from);guards=extractComponentsGuards(leavingRecords.reverse(),`beforeRouteLeave`,to,from);for(let record of leavingRecords)record.leaveGuards.forEach(guard=>{guards.push(guardToPromiseFn(guard,to,from))});let canceledNavigationCheck=checkCanceledNavigationAndReject.bind(null,to,from);return guards.push(canceledNavigationCheck),runGuardQueue(guards).then(()=>{guards=[];for(let guard of beforeGuards.list())guards.push(guardToPromiseFn(guard,to,from));return guards.push(canceledNavigationCheck),runGuardQueue(guards)}).then(()=>{guards=extractComponentsGuards(updatingRecords,`beforeRouteUpdate`,to,from);for(let record of updatingRecords)record.updateGuards.forEach(guard=>{guards.push(guardToPromiseFn(guard,to,from))});return guards.push(canceledNavigationCheck),runGuardQueue(guards)}).then(()=>{guards=[];for(let record of enteringRecords)if(record.beforeEnter)if(isArray(record.beforeEnter))for(let beforeEnter of record.beforeEnter)guards.push(guardToPromiseFn(beforeEnter,to,from));else guards.push(guardToPromiseFn(record.beforeEnter,to,from));return guards.push(canceledNavigationCheck),runGuardQueue(guards)}).then(()=>(to.matched.forEach(record=>record.enterCallbacks={}),guards=extractComponentsGuards(enteringRecords,`beforeRouteEnter`,to,from,runWithContext),guards.push(canceledNavigationCheck),runGuardQueue(guards))).then(()=>{guards=[];for(let guard of beforeResolveGuards.list())guards.push(guardToPromiseFn(guard,to,from));return guards.push(canceledNavigationCheck),runGuardQueue(guards)}).catch(err=>isNavigationFailure(err,ErrorTypes.NAVIGATION_CANCELLED)?err:Promise.reject(err))}function triggerAfterEach(to,from,failure){afterGuards.list().forEach(guard=>runWithContext(()=>guard(to,from,failure)))}function finalizeNavigation(toLocation,from,isPush,replace$1,data){let error=checkCanceledNavigation(toLocation,from);if(error)return error;let isFirstNavigation=from===START_LOCATION_NORMALIZED,state=isBrowser?history.state:{};isPush&&(replace$1||isFirstNavigation?routerHistory.replace(toLocation.fullPath,assign({scroll:isFirstNavigation&&state&&state.scroll},data)):routerHistory.push(toLocation.fullPath,data)),currentRoute.value=toLocation,handleScroll(toLocation,from,isPush,isFirstNavigation),markAsReady()}let removeHistoryListener;function setupListeners(){removeHistoryListener||=routerHistory.listen((to,_from,info)=>{if(!router$1.listening)return;let toLocation=resolve$1(to),shouldRedirect=handleRedirectRecord(toLocation,router$1.currentRoute.value);if(shouldRedirect){pushWithRedirect(assign(shouldRedirect,{replace:!0,force:!0}),toLocation).catch(noop$1);return}pendingLocation=toLocation;let from=currentRoute.value;isBrowser&&saveScrollPosition(getScrollKey(from.fullPath,info.delta),computeScrollPosition()),navigate$1(toLocation,from).catch(error=>isNavigationFailure(error,ErrorTypes.NAVIGATION_ABORTED|ErrorTypes.NAVIGATION_CANCELLED)?error:isNavigationFailure(error,ErrorTypes.NAVIGATION_GUARD_REDIRECT)?(pushWithRedirect(assign(locationAsObject(error.to),{force:!0}),toLocation).then(failure=>{isNavigationFailure(failure,ErrorTypes.NAVIGATION_ABORTED|ErrorTypes.NAVIGATION_DUPLICATED)&&!info.delta&&info.type===NavigationType.pop&&routerHistory.go(-1,!1)}).catch(noop$1),Promise.reject()):(info.delta&&routerHistory.go(-info.delta,!1),triggerError(error,toLocation,from))).then(failure=>{failure||=finalizeNavigation(toLocation,from,!1),failure&&(info.delta&&!isNavigationFailure(failure,ErrorTypes.NAVIGATION_CANCELLED)?routerHistory.go(-info.delta,!1):info.type===NavigationType.pop&&isNavigationFailure(failure,ErrorTypes.NAVIGATION_ABORTED|ErrorTypes.NAVIGATION_DUPLICATED)&&routerHistory.go(-1,!1)),triggerAfterEach(toLocation,from,failure)}).catch(noop$1)})}let readyHandlers=useCallbacks(),errorListeners=useCallbacks(),ready;function triggerError(error,to,from){markAsReady(error);let list=errorListeners.list();return list.length?list.forEach(handler$1=>handler$1(error,to,from)):console.error(error),Promise.reject(error)}function isReady(){return ready&¤tRoute.value!==START_LOCATION_NORMALIZED?Promise.resolve():new Promise((resolve$1$1,reject)=>{readyHandlers.add([resolve$1$1,reject])})}function markAsReady(err){return ready||(ready=!err,setupListeners(),readyHandlers.list().forEach(([resolve$1$1,reject])=>err?reject(err):resolve$1$1()),readyHandlers.reset()),err}function handleScroll(to,from,isPush,isFirstNavigation){let{scrollBehavior}=options;if(!isBrowser||!scrollBehavior)return Promise.resolve();let scrollPosition=!isPush&&getSavedScrollPosition(getScrollKey(to.fullPath,0))||(isFirstNavigation||!isPush)&&history.state&&history.state.scroll||null;return nextTick().then(()=>scrollBehavior(to,from,scrollPosition)).then(position=>position&&scrollToPosition(position)).catch(err=>triggerError(err,to,from))}let go=delta=>routerHistory.go(delta),started,installedApps=new Set,router$1={currentRoute,listening:!0,addRoute,removeRoute,clearRoutes:matcher.clearRoutes,hasRoute,getRoutes,resolve:resolve$1,options,push,replace,go,back:()=>go(-1),forward:()=>go(1),beforeEach:beforeGuards.add,beforeResolve:beforeResolveGuards.add,afterEach:afterGuards.add,onError:errorListeners.add,isReady,install(app$1){app$1.component(`RouterLink`,RouterLink),app$1.component(`RouterView`,RouterView),app$1.config.globalProperties.$router=router$1,Object.defineProperty(app$1.config.globalProperties,`$route`,{enumerable:!0,get:()=>unref(currentRoute)}),isBrowser&&!started&¤tRoute.value===START_LOCATION_NORMALIZED&&(started=!0,push(routerHistory.location).catch(err=>{}));let reactiveRoute={};for(let key in START_LOCATION_NORMALIZED)Object.defineProperty(reactiveRoute,key,{get:()=>currentRoute.value[key],enumerable:!0});app$1.provide(routerKey,router$1),app$1.provide(routeLocationKey,shallowReactive(reactiveRoute)),app$1.provide(routerViewLocationKey,currentRoute);let unmountApp=app$1.unmount;installedApps.add(app$1),app$1.unmount=function(){installedApps.delete(app$1),installedApps.size<1&&(pendingLocation=START_LOCATION_NORMALIZED,removeHistoryListener&&removeHistoryListener(),removeHistoryListener=null,currentRoute.value=START_LOCATION_NORMALIZED,started=!1,ready=!1),unmountApp()}}};function runGuardQueue(guards){return guards.reduce((promise,guard)=>promise.then(()=>runWithContext(guard)),Promise.resolve())}return router$1}function useRouter(){return inject(routerKey)}function useRoute(_name){return inject(routeLocationKey)}function spawnUiApp(appName,appId,params,apps){let props=params?params.props:null,appKey=`${appName}${appId}`;apps.push({name:appName,appId,appKey,comp:appName,props,teleport:`#${appName+appId}`})}function destroyUiApp(appName,apps){let index=apps.findIndex(x=>x.name===appName);index>-1&&apps.splice(index,1)}function registerApps(app$1,componentsMap){Object.keys(componentsMap).forEach(key=>app$1.component(key,componentsMap[key]))}var _sfc_main$325={};function _sfc_render$5(_ctx,_cache){return null}var layoutEmpty_default=__plugin_vue_export_helper_default(_sfc_main$325,[[`render`,_sfc_render$5]]);const LAYOUT_ALIGNMENTS={left:`flex-start`,right:`flex-end`,center:`center`};var _sfc_main$324={},_hoisted_1$287={class:`layout-wrapper layout-safezones`},_hoisted_2$235={class:`layout-content`};function _sfc_render$4(_ctx,_cache,$props,$setup,$data,$options){return openBlock(),createElementBlock(`div`,_hoisted_1$287,[createBaseVNode(`div`,_hoisted_2$235,[renderSlot(_ctx.$slots,`default`,{},()=>[_cache[0]||=createTextVNode(`Content here`,-1)])])])}var layoutSingle_default=__plugin_vue_export_helper_default(_sfc_main$324,[[`render`,_sfc_render$4]]);const useEvents=(onDispose=onBeforeUnmount)=>{let bridge$4=useBridge(),events$3={_on:{},_once:{},on(name,func){name in events$3._on||(events$3._on[name]=[]),events$3._on[name].indexOf(func)===-1&&(bridge$4.events.on(name,func),events$3._on[name].push(func))},once(name,func){name in events$3._once||(events$3._once[name]=[]),events$3._once[name].indexOf(func)===-1&&(bridge$4.events.once(name,()=>{let idx=events$3._once[name].indexOf(func);idx>-1&&events$3._once[name].splice(idx,1)}),bridge$4.events.once(name,func),events$3._once[name].push(func))},off(name=void 0,func=void 0){if(!name){for(let name$1 in events$3._on){for(let func$1 of events$3._on[name$1])bridge$4.events.off(name$1,func$1);delete events$3._on[name$1]}return}if(name in events$3._on)if(func){let idx=events$3._on[name].indexOf(func);idx>-1&&(bridge$4.events.off(name,func),events$3._on[name].splice(idx,1)),events$3._on[name].length===0&&delete events$3._on[name]}else{for(let func$1 of events$3._on[name])bridge$4.events.off(name,func$1);delete events$3._on[name]}},emit(name,...values){bridge$4.events.emit(name,...values)}};return onDispose(()=>{for(let type of[`_on`,`_once`])for(let name in events$3[type]){for(let func of events$3[type][name])bridge$4.events.off(name,func);delete events$3[type][name]}}),events$3},useStreams=(names,callback,onDispose=onBeforeUnmount)=>{let bridge$4=useBridge(),enabled=!1,streams={on(){enabled||(enabled=!0,bridge$4.streams.add(names),bridge$4.events.on(`onStreamsUpdate`,callback))},off(){enabled&&(enabled=!1,bridge$4.streams.remove(names),bridge$4.events.off(`onStreamsUpdate`,callback))}};return streams.on(),onDispose(streams.off),streams};var hints_default=`ui.hints.quickSteerResponse,ui.hints.raceBrakesEffectiveness,ui.hints.quickCameraMovement,ui.hints.grabVehicleParts,ui.hints.funStabilityControl,ui.hints.recoverVehicle,ui.hints.oldCarsBurn,ui.hints.smokingWheels,ui.hints.carsBurnFuel,ui.hints.delicateCars,ui.hints.stabilityControlPresent,ui.hints.absWasOptional,ui.hints.installRollCage,ui.hints.spatialNavigation,ui.hints.repairHood,ui.hints.slowMotionPhysics,ui.hints.removeRearSeats,ui.hints.tuning,ui.hints.customLicensePlate,ui.hints.driveAtNight,ui.hints.moonGravity,ui.hints.unlockExtraFunctionality,ui.hints.playMultiseat,ui.hints.increaseGroundClearance,ui.hints.tiresBurstOnBumps,ui.hints.blueSmokeIsPistonDamage,ui.hints.keepTheEngineUpright,ui.hints.thermalDebugApp,ui.hints.rollPitchApps,ui.hints.cruiseControlApp,ui.hints.driveTheCanon,ui.hints.vehicleSkins,ui.hints.toggleMods,ui.hints.importveFramerate,ui.hints.photoModeMenu,ui.hints.publishScreenshots,ui.hints.towTrailer,ui.hints.brakesAndSteeringVary,ui.hints.countersteerEarly,ui.hints.startSlow,ui.hints.parkingbrakeForTurning,ui.hints.carefulWithOldSportsCars,ui.hints.corneringWithKeyboard,ui.hints.adaptToBadRoads,ui.hints.notAllCarsCanRace,ui.hints.changeBrakePads,ui.hints.useTurnSignals,ui.hints.showStandalonePcs,ui.hints.tweakFOV,ui.hints.driveWithMouse,ui.hints.liftOffOversteer,ui.hints.snapOversteer,ui.hints.slideBackWithParkingBrake,ui.hints.customizeSpecializedBindings,ui.hints.toggleFogLights,ui.hints.toggleLightBars,ui.hints.TrackIRSupported,ui.hints.chooseShiftingMode,ui.hints.saveRestoreVehicleHome,ui.hints.switchVehicle,ui.hints.coolantVaporizes,ui.hints.dontRunIntoTheCar`.split(`,`),_hoisted_1$286={key:0,class:`progress-box`},_hoisted_2$234={class:`progress-icon-group`},_hoisted_3$208={class:`progress-bar-container`},_hoisted_4$178={class:`progress-status`},_hoisted_5$153={class:`progress-history`},_hoisted_6$132={class:`custom-left-container`},_hoisted_7$118={key:0,class:`custom-text-panel`},_hoisted_8$99={key:1,class:`text`},_hoisted_9$89={key:1,class:`custom-indeterminate-panel`},_hoisted_10$77={class:`custom-right-container`},_hoisted_11$69={key:2,class:`tips-bar`},_hoisted_12$57={class:`tips-bar-title`},_hoisted_13$49={class:`tips-bar-tip`},_hoisted_14$44={key:0,class:`loading-cache`},_hoisted_15$42=[`src`],imagesAmount=18,activeRepeatTime=1e4,fadeInDefault=1e3,fadeOutDefault=2e3,_sfc_main$323={__name:`LoadingScreen`,setup(__props){useCssVars(_ctx=>({v79c091d8:fadeInTimeVar.value,v07559aed:fadeOutTimeVar.value}));let events$3=useEvents(),{lua}=useBridge(),navBlocker=useUINavBlocker(),lastImageNum=-1,repeatTimer=null,customTimer=null,iconsList=[{id:`terrain`,icon:icons.terrain},{id:`environment`,icon:icons.water},{id:`forest`,icon:icons.trafficCone},{id:`meshes`,icon:icons.garage01},{id:`roads`,icon:icons.road},{id:`beamng`,icon:icons.beamNG}],state=reactive({active:!1,visible:!1,fading:!1,shown:!1,autoActivate:!0,highSeas:!1,mode:`progress`,image:null,iconState:{},currentEntries:[],historyEntriesDisplay:[],customContent:null,fadeInTime:fadeInDefault,fadeOutTime:fadeOutDefault,customPause:-1});function resetState(){state.mode=`progress`,state.customContent=null,state.iconState={},state.currentEntries=[],state.historyEntriesDisplay=[],state.fadeInTime=fadeInDefault,state.fadeOutTime=fadeOutDefault,state.customPause=-1}let tip=ref(``),setTip=(txt=void 0,_retrying=!1)=>{let idx=~~(Math.random()*hints_default.length);tip.value=txt||hints_default[idx],(!tip.value||tip.value===`undefined`)&&(logger_default.debug(`Loading Screen tip is undefined!\nARG: ${JSON.stringify(txt)} TIP: ${JSON.stringify(tip.value)} IDX: ${idx}/${hints_default.length}`),_retrying?tip.value=``:setTip(void 0,!0))},fadeInTimeVar=computed(()=>state.fadeInTime+`ms`),fadeOutTimeVar=computed(()=>state.fadeOutTime+`ms`),progressValue=computed(()=>state.currentEntries[0]?.progress||0),currentStatus=computed(()=>state.currentEntries[0]?.message||``);events$3.on(`LoadingScreen`,data=>{if(window.beamng?.ingame){if((!data||typeof data!=`object`)&&(data={}),state.autoActivate=!1,state.active=!!data.active,data.custom&&(state.mode=`custom`,state.fadeInTime=data.custom.fadeIn>0?data.custom.fadeIn*1e3:state.fadeInTime||0,state.fadeOutTime=data.custom.fadeOut>0?data.custom.fadeOut*1e3:state.fadeOutTime||0),state.active)data.custom?(state.customPause=data.custom.pause?data.custom.pause*1e3:-1,state.customContent=data.custom.data,state.customContent?.image&&(state.image=state.customContent.image)):(resetState(),window.bngVue.gotoAngularState(`blank`)),setTip(state.customContent?.tips);else if(state.mode===`progress`&&`gotoMainMenu`in data){let args=[];data.gotoMainMenu?args.push(`menu.mainmenu`):args.push(`menu`,[`loading`]),window.globalAngularRootScope?.$broadcast(`ChangeState`,...args),window.vueEventBus?.emit(`onChangeState`,...args)}}}),events$3.on(`UpdateLoadingProgressV2`,data=>{if(!window.beamng?.ingame||!state.autoActivate&&!state.active)return;let{currentEntries,historyEntries}=data;(!currentEntries||!Array.isArray(currentEntries))&&(currentEntries=[]),(!historyEntries||!Array.isArray(historyEntries))&&(historyEntries=[]),state.currentEntries=currentEntries,state.historyEntriesDisplay=historyEntries.slice(Math.max(historyEntries.length-3,1)),state.iconState={};for(let{name,progress}of currentEntries)state.iconState[name.toLowerCase()]=progress;for(let{name}of historyEntries)state.iconState[name.toLowerCase()]=100;state.autoActivate&&(state.active=currentEntries.length>0||historyEntries.length>0)});let onFadeIn=()=>{state.fading=!1,state.mode===`progress`?(lua.core_gamestate.loadingScreenActive(),repeatTimer=setTimeout(()=>{lua.core_gamestate.loadingScreenActive()},activeRepeatTime)):state.mode===`custom`&&(lua.extensions.ui_fadeScreen.onScreenFadeStateDelayed(1),state.customPause!==-1&&(customTimer=setTimeout(()=>{lua.extensions.ui_fadeScreen.onScreenFadeStateDelayed(2)},state.customPause*1e3)))},onFadeOut=()=>{state.fading=!1,state.shown=!1,state.mode===`custom`&&lua.extensions.ui_fadeScreen.onScreenFadeStateDelayed(3),resetState(),loadNextImage()};watch(()=>state.active,(newActive,oldActive)=>{window.beamng?.ingame&&(newActive&&!oldActive?activateLoading():!newActive&&oldActive&&deactivateLoading())});let activateLoading=()=>{state.active&&(deactivateLoading.cancel(),navBlocker.allowOnly([]),nextTick(()=>{state.visible=!0,state.fading=!0,state.shown=!0}))},deactivateLoading=debounce(()=>{state.active||(clearTimers(),navBlocker.clear(),nextTick(()=>{state.visible=!1,state.fading=!0}))},100),getRandomImageNum=()=>{let rnd=~~(Math.random()*imagesAmount)+1;return rnd===lastImageNum?getRandomImageNum():(lastImageNum=rnd,rnd)},getNextImageUrl=()=>{let url;return url=state.highSeas?`images/mainmenu/unofficial_version.jpg`:`images/loading/drive/${getRandomImageNum()}.jpg`,getAssetURL(url)},loadNextImage=async()=>{let url=getNextImageUrl();state.image!==url&&(await loadImage$1(url),state.image=url)},loadImage$1=url=>new Promise((resolve$1,reject)=>{let img=new Image;img.onload=()=>resolve$1(url),img.onerror=()=>reject(url),img.src=url}),clearTimers=()=>{repeatTimer&&=(clearTimeout(repeatTimer),null),customTimer&&=(clearTimeout(customTimer),null)},initLoadingScreen=()=>bngApi.engineLua(`sailingTheHighSeas`,async ahoy=>{state.highSeas=ahoy===!0,await loadNextImage(),setTip(),lua.core_gamestate.loadingScreenActive(),window.loadingTest=active=>{events$3.emit(`LoadingScreen`,{active})}});return onMounted(()=>{linkLoadingScreenState(state),initLoadingScreen()}),onUnmounted(()=>clearTimers()),(_ctx,_cache)=>(openBlock(),createElementBlock(Fragment,null,[createVNode(Transition,{name:`loading-fade`,onAfterEnter:onFadeIn,onAfterLeave:onFadeOut},{default:withCtx(()=>[state.visible?(openBlock(),createElementBlock(`dialog`,{key:0,open:``,class:normalizeClass([`loading-screen`,`loading-screen-${state.mode}`])},[createBaseVNode(`div`,{class:`loading-background`,style:normalizeStyle({backgroundImage:state.image?`url('${state.image}')`:`none`})},null,4),state.mode===`progress`?(openBlock(),createElementBlock(`div`,_hoisted_1$286,[createBaseVNode(`div`,_hoisted_2$234,[(openBlock(),createElementBlock(Fragment,null,renderList(iconsList,iconInfo=>createBaseVNode(`div`,{key:iconInfo.id,class:`progress-icon-box`,style:normalizeStyle({backgroundPosition:`0 ${state.iconState[iconInfo.id]||0}%`})},[createVNode(unref(bngIcon_default),{type:iconInfo.icon,color:`#fff`,class:`progress-icon`},null,8,[`type`])],4)),64))]),createBaseVNode(`div`,_hoisted_3$208,[createVNode(unref(bngProgressBar_default),{class:`progress-bar`,gradient:``,"show-value-label":!1,min:0,max:100,value:progressValue.value},null,8,[`value`])]),createBaseVNode(`div`,_hoisted_4$178,toDisplayString(currentStatus.value||_ctx.$tt(`ui.common.loading`)),1),createBaseVNode(`div`,_hoisted_5$153,[(openBlock(!0),createElementBlock(Fragment,null,renderList(state.historyEntriesDisplay,(item,idx)=>(openBlock(),createElementBlock(`div`,{key:idx},toDisplayString(item.message),1))),128))])])):createCommentVNode(``,!0),state.mode===`custom`?(openBlock(),createElementBlock(`div`,{key:1,class:normalizeClass([`custom-box`,{"custom-with-tips":state.customContent?.tips}])},[createBaseVNode(`div`,_hoisted_6$132,[state.customContent&&(state.customContent.title||state.customContent.text)?(openBlock(),createElementBlock(`div`,_hoisted_7$118,[state.customContent.title?(openBlock(),createBlock(unref(bngScreenHeading_default),{key:0,preheadings:[_ctx.$tt(state.customContent.subtitle)]},{default:withCtx(()=>[createTextVNode(toDisplayString(_ctx.$tt(state.customContent.title)),1)]),_:1},8,[`preheadings`])):createCommentVNode(``,!0),state.customContent.text?(openBlock(),createElementBlock(`p`,_hoisted_8$99,[createVNode(unref(dynamicComponent_default),{"translate-id":state.customContent.text,bbcode:``,"translate-context":``},null,8,[`translate-id`])])):createCommentVNode(``,!0)])):(openBlock(),createElementBlock(`div`,_hoisted_9$89,[createVNode(unref(bngScreenHeading_default),null,{default:withCtx(()=>[createTextVNode(toDisplayString(_ctx.$tt(`ui.common.loading.short`)),1)]),_:1}),createVNode(unref(bngProgressBar_default),{class:`progress-bar`,gradient:``,"show-value-label":!1,min:0,max:100,indeterminate:``})]))]),createBaseVNode(`div`,_hoisted_10$77,[state.customContent&&state.customContent.image?(openBlock(),createElementBlock(`div`,{key:0,class:`custom-image-panel`,style:normalizeStyle({backgroundImage:`url('${state.customContent.image}')`})},null,4)):createCommentVNode(``,!0)])],2)):createCommentVNode(``,!0),state.mode===`progress`||state.customContent?.tips?(openBlock(),createElementBlock(`div`,_hoisted_11$69,[createBaseVNode(`div`,_hoisted_12$57,toDisplayString(_ctx.$tt(`ui.loadingScreen.tips`))+`:`,1),createBaseVNode(`div`,_hoisted_13$49,[createVNode(unref(dynamicComponent_default),{"translate-id":tip.value,bbcode:``},null,8,[`translate-id`])])])):createCommentVNode(``,!0)],2)):createCommentVNode(``,!0)]),_:1}),state.image?(openBlock(),createElementBlock(`div`,_hoisted_14$44,[createBaseVNode(`img`,{src:state.image,alt:``},null,8,_hoisted_15$42)])):createCommentVNode(``,!0)],64))}},LoadingScreen_default=__plugin_vue_export_helper_default(_sfc_main$323,[[`__scopeId`,`data-v-2f135df0`]]),_hoisted_1$285={class:`pause-button-wrapper`},_sfc_main$322={__name:`pauseButton`,props:{teleportTo:[String,Object]},setup(__props){let route=useRoute(),events$3=useEvents(),gameContext=useGameContextStore(),isGamePaused=ref(!1),physicsMaybePaused=ref(!1),replayActive=ref(!1),replayPaused=ref(!1);events$3.on(`physicsStateChanged`,state=>{physicsMaybePaused.value=!state}),events$3.on(`replayStateChanged`,core_replay=>{replayActive.value=core_replay.state===`playback`,replayPaused.value=replayActive.value&&core_replay.paused}),events$3.on(`simTimeAuthority.pauseStateChanged`,data=>{isGamePaused.value=data.paused});let isInMenu=computed(()=>route.name?.startsWith(`menu`)&&!gameContext.activities?.length&&sysInfo_default.gameState.value!==void 0&&sysInfo_default.gameState.value!==`loading`),isPhysicsPaused=computed(()=>physicsMaybePaused.value),isReplayPaused=computed(()=>replayActive.value&&replayPaused.value),showPauseButton=computed(()=>isInMenu.value||isPhysicsPaused.value||isReplayPaused.value),isPaused=computed(()=>isGamePaused.value||isPhysicsPaused.value||isReplayPaused.value),buttonState=computed(()=>isInMenu.value&&isPaused.value?`menu-paused`:isInMenu.value?`menu`:isPaused.value?`paused`:`default`),togglePause=()=>{Lua_default.simTimeAuthority.togglePause()};return(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$285,[(openBlock(),createBlock(Teleport,{disabled:!__props.teleportTo,to:__props.teleportTo},[withDirectives((openBlock(),createBlock(unref(bngButton_default),{class:normalizeClass([`pause-button`,buttonState.value]),accent:unref(ACCENTS).custom,"no-sound":``,onClick:togglePause,"bng-no-nav":``},{default:withCtx(()=>[createVNode(unref(bngBinding_default),{class:`pause-button-binding-bg`,action:`pause`}),createVNode(unref(bngIcon_default),{class:`pause-button-icon`,type:isPaused.value?unref(icons).pause:unref(icons).play},null,8,[`type`])]),_:1},8,[`class`,`accent`])),[[vShow,showPauseButton.value],[unref(BngTooltip_default),_ctx.$tt(`ui.inputActions.general.pause.title`),void 0,{bottom:!0}]])],8,[`disabled`,`to`]))]))}},pauseButton_default=__plugin_vue_export_helper_default(_sfc_main$322,[[`__scopeId`,`data-v-ea9a26b4`]]),UIAppStorage,setupDone;const useUIApps=()=>(setupDone||setup(),service);var setup=()=>{UIAppStorage||=window.UIAppStorage,setupDone=!!UIAppStorage},setLayout=layoutName=>{layoutName==`blank`?_broadcast(`appContainer:clear`):_broadcast(`appContainer:loadLayoutByType`,layoutName)},setVisible=state=>{_broadcast(`ShowApps`,!!state)},service={setLayout,setVisible,get currentLayout(){return UIAppStorage.currentLayout}},_broadcast=(...params)=>{window.globalAngularRootScope&&window.globalAngularRootScope.$broadcast(...params)},_sfc_main$321={};function _sfc_render$3(_ctx,_cache){return openBlock(),createElementBlock(`span`)}var NotFound_default=__plugin_vue_export_helper_default(_sfc_main$321,[[`render`,_sfc_render$3]]);function useGridSelector(backendName=`gridSelector`,defaultPath={keys:[`missions`]},defaultDetailsMode=`detail`){let currentPath=ref(defaultPath),previousPath=ref(null),groups=ref([]),filterList=ref([]),filterByProp=ref([]),commonFilters=ref([]),lockedFiltersByProp=ref([]),activeFilters=ref([]),onlyCommonFilters=ref(!0),detailsMode=ref(defaultDetailsMode),selectedItem=ref(null),selectedItemDetails=ref(null),prevSelectedItem=ref(null),previewItem=ref(null),previewItemDetails=ref(null),managementDetails=ref(null),autoFocusKey=ref(null),showScreenHeader=ref(!0),screenHeaderTitle=ref(`Grid Selector`),screenHeaderPath=ref([{text:`Menu`,gotoAngularState:`menu`}]),{events:events$3}=useBridge(),backFromDetailsCallback=null,refreshAllHandler=backendName$1=>{backendName$1===backendName$1&&(logger_default.debug(`gridSelectorRefreshAll`),loadTiles(),loadFilters(),loadManagementDetails())},refreshCurrentItemDetailsHandler=backendName$1=>{backendName$1===backendName$1&&(logger_default.debug(`gridSelectorRefreshCurrentItemDetails`),setSelectedItem(selectedItem.value))};events$3.on(`gridSelectorRefreshAll`,refreshAllHandler),events$3.on(`gridSelectorRefreshCurrentItemDetails`,refreshCurrentItemDetailsHandler);let log=(...args)=>{},displayData=ref([]),searchText$1=ref(``);async function getSearchText(){try{let data=await Lua_default.ui_gridSelector.getSearchText(backendName);return searchText$1.value=data||``,data||``}catch(error){return logger_default.error(`Failed to get search text:`,error),``}}async function setSearchText(value){try{await Lua_default.ui_gridSelector.setSearchText(backendName,value),searchText$1.value=value||``,await loadTiles(),await loadFilters(),await updateScreenHeaderData()}catch(error){logger_default.error(`Failed to set search text:`,error)}}let isInitializing=ref(!1),safeArray=arr=>Array.isArray(arr)?arr:[];async function setCurrentPath(path){currentPath.value=path,await loadTiles()}async function loadTiles(){currentPath.value;try{let data=await Lua_default.ui_gridSelector.getTiles(backendName,currentPath.value,previousPath.value!==currentPath.value);if(Lua_default.ui_gridSelector.profilerFinish(backendName,`received lua data on UI`),groups.value=safeArray(data),groups.value,!selectedItem.value&&(detailsMode.value===`advanced`||detailsMode.value===`detail`)&&previousPath.value!==currentPath.value)for(let group of groups.value)for(let tile of group.tiles)tile.isDefaultSelected&&(autoFocusKey.value=tile.key,tile.name,tile.forceAutoFocus&&backFromDetailsCallback());previousPath.value=currentPath.value,Lua_default.ui_gridSelector.profilerFinish(backendName,`loaded tiles into reactive state`)}catch(error){logger_default.error(`Failed to load tiles:`,error)}}async function loadFilters(){try{let data=await Lua_default.ui_gridSelector.getFilters(backendName);filterList.value=safeArray(data.filterList),filterByProp.value=data.filterByProp,commonFilters.value=safeArray(data.commonFilters)||[],lockedFiltersByProp.value=data.lockedFiltersByProp||[],activeFilters.value=safeArray(data.activeFilters),onlyCommonFilters.value=data.onlyCommonFilters,filterList.value,filterByProp.value,activeFilters.value,onlyCommonFilters.value}catch(error){logger_default.error(`Failed to load filters:`,error)}}async function loadManagementDetails(){try{managementDetails.value=await Lua_default.ui_gridSelector.getManagementDetails(backendName),managementDetails.value}catch(error){logger_default.error(`Failed to load management details:`,error)}}async function toggleFilter(propName,option){try{await Lua_default.ui_gridSelector.toggleFilter(backendName,propName,option),await loadFilters(),await loadTiles(),await updateScreenHeaderData()}catch(error){logger_default.error(`Failed to toggle filter:`,error)}}async function updateRangeFilter(propName,min$1,max$1){try{await Lua_default.ui_gridSelector.updateRangeFilter(backendName,propName,min$1,max$1),await loadFilters(),await loadTiles(),await updateScreenHeaderData()}catch(error){logger_default.error(`Failed to update range filter:`,error)}}async function resetRangeFilter(propName){console.log(`Resetting range filter:`,propName);try{await Lua_default.ui_gridSelector.resetRangeFilter(backendName,propName),await loadFilters(),await loadTiles(),await updateScreenHeaderData()}catch(error){logger_default.error(`Failed to reset range filter:`,error)}}async function resetSetFilter(propName){try{await Lua_default.ui_gridSelector.resetSetFilter(backendName,propName),await loadFilters(),await loadTiles(),await updateScreenHeaderData()}catch(error){logger_default.error(`Failed to reset set filter:`,error)}}async function loadDisplayData(){try{displayData.value=safeArray(await Lua_default.ui_gridSelector.getDisplayDataOptions(backendName));let searchOption=displayData.value.find(option=>option.key===`searchText`);searchOption&&(searchText$1.value=searchOption.value||``),displayData.value}catch(error){logger_default.error(`Failed to load display data:`,error)}}async function updateDisplayData(key,value){try{await Lua_default.ui_gridSelector.setDisplayDataOption(backendName,key,value),await loadDisplayData(),await loadTiles(),await updateScreenHeaderData()}catch(error){logger_default.error(`Failed to update display data:`,error)}}async function resetDisplayDataToDefaults(){try{await Lua_default.ui_gridSelector.resetDisplayDataToDefaults(backendName),await loadDisplayData(),await loadTiles(),await updateScreenHeaderData()}catch(error){logger_default.error(`Failed to reset display data to defaults:`,error)}}function setDetailsMode(mode){detailsMode.value=mode}async function setSelectedItem(item){if(!item||!item.showDetails){autoFocusKey.value=null,selectedItem.value=null,selectedItemDetails.value=null,await loadManagementDetails();return}try{item.showDetails;let details=await Lua_default.ui_gridSelector.getDetails(backendName,item.showDetails);autoFocusKey.value=item.key,selectedItem.value=item,selectedItemDetails.value=details,details?.paintData&&details?.paints&&selectedItemDetails.value?.paints&&(selectedItemDetails.value.paints.multiPaintSetups=safeArray(selectedItemDetails.value.paints.multiPaintSetups),selectedItemDetails.value.paints.factoryPaints=safeArray(selectedItemDetails.value.paints.factoryPaints)),setDetailsMode(`detail`)}catch(error){logger_default.error(`Failed to get item details:`,error),autoFocusKey.value=null,selectedItem.value=item,selectedItemDetails.value=null}}async function clearSelectedItem(){selectedItem.value=null,selectedItemDetails.value=null,await loadManagementDetails()}async function setPreviewItem(item){if(!item||!item.showDetails){previewItem.value=null,previewItemDetails.value=null;return}try{let details=await Lua_default.ui_gridSelector.getDetails(backendName,item.showDetails);previewItem.value=item,previewItemDetails.value=details,setDetailsMode(`detail`)}catch{previewItem.value=item,previewItemDetails.value=null}}function clearPreviewItem(){previewItem.value=null,previewItemDetails.value=null}let activeItem=computed(()=>selectedItem.value||previewItem.value),activeItemDetails=computed(()=>selectedItem.value?selectedItemDetails.value:previewItemDetails.value);async function executeButton(buttonId,additionalData){try{if(additionalData?.waitForLoadingScreen)window.vueEventBus?.emit(`LoadingScreen`,{active:!0}),await startLoading(async()=>{await waitForLoadingScreenFadeIn();let data=await Lua_default.ui_gridSelector.executeButton(backendName,buttonId,additionalData);data&&data.gotoPath&&setCurrentPath(data.gotoPath)});else{let data=await Lua_default.ui_gridSelector.executeButton(backendName,buttonId,additionalData);data&&data.gotoPath&&setCurrentPath(data.gotoPath)}}catch(error){logger_default.error(`Failed to execute button:`,error)}}let executeButtonHandler=(backendName$1,buttonId,additionalData)=>{backendName$1===backendName$1&&executeButton(buttonId,additionalData)};events$3.on(`gridSelectorExecuteButton`,executeButtonHandler);async function toggleFavourite(item){await Lua_default.ui_gridSelector.toggleFavourite(backendName,item.showDetails);let details=await Lua_default.ui_gridSelector.getDetails(backendName,item.showDetails);selectedItem.value=item,selectedItemDetails.value=details,await loadTiles()}function clearSearch(){setSearchText(``)}function updateSearch(newSearchText){setSearchText(newSearchText||``)}function commitSearch(){setSearchText(searchText$1.value||``)}function isFilterLocked(propName,option=null){return lockedFiltersByProp.value[propName]?option?lockedFiltersByProp.value[propName][option]!==void 0:Object.keys(lockedFiltersByProp.value[propName]).length>0:!1}async function updateScreenHeaderData(){try{let headerData=await Lua_default.ui_gridSelector.getScreenHeaderTitleAndPath(backendName,currentPath.value);screenHeaderTitle.value=headerData.title||`Grid Selector`,screenHeaderPath.value=headerData.pathSegments}catch(error){logger_default.error(`Failed to update screen header title:`,error),screenHeaderTitle.value=`Grid Selector`,screenHeaderPath.value=[{text:`Menu`,gotoAngularState:`menu`}]}}function isFilterOptionLocked(propName,option){return isFilterLocked(propName,option)}function isRangeFilterLocked(propName){return isFilterLocked(propName)}watch(currentPath,()=>{clearSelectedItem(),clearPreviewItem(),updateScreenHeaderData()}),watch([filterByProp,activeFilters],()=>{clearSelectedItem(),clearPreviewItem(),updateScreenHeaderData()}),watch(displayData,()=>{updateScreenHeaderData()},{deep:!0});function notifyUIReady(tag){Lua_default.ui_gridSelector.profilerFinish(backendName,tag)}function setOnBackFromDetailsCallback(callback){backFromDetailsCallback=callback}async function initialize(){if(!isInitializing.value)try{isInitializing.value=!0,await Promise.all([loadFilters(),loadDisplayData(),loadManagementDetails(),getSearchText()])}catch(error){logger_default.error(`Failed to initialize GridSelector composable:`,error)}finally{isInitializing.value=!1}}return onUnmounted(()=>{logger_default.debug(`GridSelector composable unmounting`),events$3.off(`gridSelectorRefreshAll`,refreshAllHandler),events$3.off(`gridSelectorRefreshCurrentItemDetails`,refreshCurrentItemDetailsHandler),events$3.off(`gridSelectorExecuteButton`,executeButtonHandler)}),{groups,filterList,filterByProp,lockedFiltersByProp,commonFilters,activeFilters,onlyCommonFilters,displayData,currentPath,detailsMode,selectedItem,selectedItemDetails,prevSelectedItem,previewItem,previewItemDetails,activeItem,activeItemDetails,managementDetails,isInitializing,searchText:searchText$1,getSearchText,setSearchText,autoFocusKey,showScreenHeader,screenHeaderTitle,screenHeaderPath,initialize,setCurrentPath,loadTiles,loadFilters,loadManagementDetails,toggleFilter,updateRangeFilter,resetRangeFilter,resetSetFilter,loadDisplayData,updateDisplayData,resetDisplayDataToDefaults,setDetailsMode,setSelectedItem,clearSelectedItem,setPreviewItem,clearPreviewItem,executeButton,notifyUIReady,isFilterLocked,isFilterOptionLocked,isRangeFilterLocked,toggleFavourite,clearSearch,updateSearch,commitSearch,updateScreenHeaderData,exploreFolder:function(path){Lua_default.ui_gridSelector.exploreFolder(backendName,path)},goToMod:function(modId){Lua_default.ui_gridSelector.goToMod(backendName,modId)},setOnBackFromDetailsCallback}}var _hoisted_1$284=[`bng-scoped-nav-autofocus`],_hoisted_2$233={class:`image-container`},_hoisted_3$207={key:0,class:`sub-element-count-badge`},_hoisted_4$177={class:`item-label`},_hoisted_5$152={class:`item-name`},_hoisted_6$131={class:`icons-container`},_hoisted_7$117=[`src`],_hoisted_8$98={key:0,class:`sub-element-count-badge`},_hoisted_9$88={key:1},sizes={tiny:{width:7.5,margin:.5,fontSize:.8},small:{width:9.5,margin:.5,fontSize:1},medium:{width:12,margin:.5,fontSize:1},large:{width:16,margin:.5,fontSize:1},huge:{width:20,margin:.5,fontSize:1.5},list:{width:22,height:3,margin:.5,fontSize:.9}},thumbAspectRatio=16/9.5,captionHeightEm=2,getSizeCalc=displaySize=>ctx=>{let size$3=sizes[displaySize]||sizes.medium;if(displaySize===`list`)return{width:size$3.width,height:size$3.height,margin:size$3.margin};let height$1=size$3.width/thumbAspectRatio+size$3.fontSize*captionHeightEm-size$3.margin*2;return{width:size$3.width,height:height$1,margin:size$3.margin}},__default__$6={getSizeCalc},_sfc_main$320=Object.assign(__default__$6,{__name:`Tile`,props:{tile:{type:Object,required:!0},isFavourite:Boolean,isConfig:Boolean,displaySize:String,tileImagesTopAligned:{type:Boolean,default:!1}},emits:[`focus`,`blur`,`click`,`dblclick`],setup(__props,{expose:__expose,emit:__emit}){let{showIfController}=storeToRefs(controls_default()),props=__props,gridSelectionState=inject(`gridSelectionState`,null),state=computed(()=>{let res={selected:!1,dimmed:!1,isAutoFocused:!1};return gridSelectionState&&gridSelectionState.value&&(res.selected=gridSelectionState.value.inDetails&&gridSelectionState.value.activeItemKey===props.tile.key,res.dimmed=showIfController.value&&gridSelectionState.value.inDetails&&gridSelectionState.value.activeItemKey!==props.tile.key,res.isAutoFocused=gridSelectionState.value.autoFocusKey===props.tile.key),res}),emit$1=__emit,elTile=ref(null);__expose({getElement:()=>elTile.value});let isListItem=computed(()=>props.displaySize===`list`);function onClick(){emit$1(`click`)}function onFocus(){emit$1(`focus`)}function onBlur(){emit$1(`blur`)}return(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,{class:normalizeClass([`tile-wrapper`,`tile-size-${__props.displaySize}`]),style:normalizeStyle({"--tile-font-size":sizes[__props.displaySize].fontSize+`em`})},[_cache[0]||=createBaseVNode(`div`,{class:`tile-bg`},null,-1),withDirectives((openBlock(),createElementBlock(`div`,{ref_key:`elTile`,ref:elTile,"bng-scoped-nav-autofocus":state.value.isAutoFocused,class:normalizeClass({tile:!0,selected:state.value.selected,dimmed:state.value.dimmed,auxiliary:__props.tile.isAuxiliary,"is-career-only":__props.tile.isCareerOnly}),onClick:withModifiers(onClick,[`stop`]),onFocus,onBlur,"bng-nav-item":``},[createBaseVNode(`div`,_hoisted_2$233,[createVNode(unref(bngImage_default),{class:normalizeClass([`item-image`,{"top-aligned":__props.tileImagesTopAligned}]),src:__props.tile.preview},null,8,[`class`,`src`]),isListItem.value?createCommentVNode(``,!0):(openBlock(),createElementBlock(Fragment,{key:0},[!__props.isConfig&&__props.tile.subElementCount>=1?(openBlock(),createElementBlock(`div`,_hoisted_3$207,toDisplayString(__props.tile.subElementCount),1)):createCommentVNode(``,!0),__props.isFavourite||__props.tile.showFavouriteIconPercent>=1?(openBlock(),createBlock(unref(bngIcon_default),{key:1,class:`favorite-indicator`,type:`star`})):createCommentVNode(``,!0)],64))]),createBaseVNode(`div`,_hoisted_4$177,[createBaseVNode(`span`,_hoisted_5$152,toDisplayString(__props.tile.name),1),createBaseVNode(`div`,_hoisted_6$131,[__props.tile.sourceIcons?(openBlock(!0),createElementBlock(Fragment,{key:0},renderList(__props.tile.sourceIcons,sourceIcon=>(openBlock(),createElementBlock(Fragment,{key:sourceIcon},[sourceIcon.icon?(openBlock(),createBlock(unref(bngIcon_default),{key:0,type:sourceIcon.icon,class:`source-icon`,color:`var(--bng-cool-gray-100)`},null,8,[`type`])):createCommentVNode(``,!0),sourceIcon.svg?(openBlock(),createElementBlock(`img`,{key:1,class:`svg-icon`,src:sourceIcon.svg,alt:``},null,8,_hoisted_7$117)):createCommentVNode(``,!0)],64))),128)):createCommentVNode(``,!0),isListItem.value&&__props.tile.showFavouriteIconPercent>0?(openBlock(),createBlock(unref(bngIcon_default),{key:1,class:`favorite-indicator`,type:__props.tile.showFavouriteIconPercent>=1?`star`:`starSecondary`},null,8,[`type`])):createCommentVNode(``,!0)]),isListItem.value&&!__props.isConfig&&__props.tile.subElementCount>=1?(openBlock(),createElementBlock(`span`,_hoisted_8$98,toDisplayString(__props.tile.subElementCount),1)):isListItem.value?(openBlock(),createElementBlock(`span`,_hoisted_9$88)):createCommentVNode(``,!0)])],42,_hoisted_1$284)),[[unref(BngOnUiNav_default),void 0,`ok`,{focusRequired:!0,asMouse:!0,bubble:!0}],[unref(BngSoundClass_default),`bng_click_hover_generic`],[unref(BngDoubleClick_default),__props.tile.doubleClickDetails?()=>emit$1(`dblclick`):null,__props.tile.doubleClickMode]])],6))}}),Tile_default=__plugin_vue_export_helper_default(_sfc_main$320,[[`__scopeId`,`data-v-51fd3377`]]),_hoisted_1$283={class:`group-header`,"bng-list-title":``},_sfc_main$319={__name:`GroupHeader`,props:{label:{type:String,required:!0}},setup(__props){return(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$283,[createVNode(bngCardHeading_default,{class:`header-label`},{default:withCtx(()=>[createTextVNode(toDisplayString(__props.label),1)]),_:1}),_cache[0]||=createBaseVNode(`div`,{class:`header-line`},null,-1)]))}},GroupHeader_default=__plugin_vue_export_helper_default(_sfc_main$319,[[`__scopeId`,`data-v-28596ef8`]]),_sfc_main$318={__name:`Grid`,props:{autoFocusKey:{type:String,default:null},activeItem:{type:Object,default:null},groups:{type:Array,required:!0},isConfig:{type:Boolean,default:!1},displaySize:{type:String,default:`medium`,validator:value=>[`tiny`,`small`,`medium`,`large`,`huge`,`list`].includes(value)},inDetails:{type:Boolean,default:!1},backendName:{type:String,default:`gridSelector`},tileImagesTopAligned:{type:Boolean,default:!1},doubleClickOverride:{type:Function,default:null}},emits:[`select-item`,`deselect-item`,`focus-item`],setup(__props,{emit:__emit}){let{showIfController}=storeToRefs(controls_default()),props=__props,emit$1=__emit,gridListRef=ref(),containerWidth=ref(0),baseFontSize=ref(16),tileSizeCalc=ctx=>Tile_default.getSizeCalc(props.displaySize)(ctx),maxTilesPerRow=computed(()=>{if(!containerWidth.value)return 1/0;let size$3=Tile_default.getSizeCalc(props.displaySize)({}),tileWidthPx=(size$3.width+size$3.margin)*baseFontSize.value;return(Math.floor(containerWidth.value/tileWidthPx)||1)*(props.displaySize===`list`?2:1)}),limitedGroups=computed(()=>props.groups.map(group=>({...group,tiles:group.isRecentGroup?group.tiles.slice(0,maxTilesPerRow.value):group.tiles}))),updateContainerWidth=()=>{gridListRef.value?.$el&&(containerWidth.value=gridListRef.value.$el.clientWidth,baseFontSize.value=parseFloat(getComputedStyle(document.documentElement).fontSize)||16)},resizeObserver;onMounted(()=>{updateContainerWidth(),gridListRef.value?.$el&&(resizeObserver=new ResizeObserver(debounce(updateContainerWidth,100)),resizeObserver.observe(gridListRef.value.$el))}),onUnmounted(()=>{resizeObserver&&resizeObserver.disconnect()}),provide(`gridSelectionState`,computed(()=>({inDetails:props.inDetails,activeItemKey:props.activeItem?.key||null,autoFocusKey:props.autoFocusKey})));let focusItem=tile=>{props.inDetails||(showIfController.value&&preselectItem(tile),emit$1(`focus-item`,tile))},selectItem=tile=>{preselectItem.cancel(),emit$1(`select-item`,tile)},preselectItem=debounce(tile=>emit$1(`select-item`,tile,!1),200),handleDoubleClick=async item=>{if(console.log(`handleDoubleClick`,item),item.doubleClickDetails)try{props.doubleClickOverride?props.doubleClickOverride(item):await Lua_default.ui_gridSelector.executeDoubleClick(props.backendName,item.doubleClickDetails)}catch(error){console.error(`Failed to execute double click:`,error)}};return(_ctx,_cache)=>(openBlock(),createBlock(unref(bngList_default),{ref_key:`gridListRef`,ref:gridListRef,class:`grid-list`,layout:unref(LIST_LAYOUTS).TILES,"no-background":``,big:``,immediate:``,"keep-alive":500,"title-width":20,"title-height":1.5,"title-margin":.5,"tile-size-calc":tileSizeCalc},{default:withCtx(()=>[(openBlock(!0),createElementBlock(Fragment,null,renderList(limitedGroups.value,group=>(openBlock(),createElementBlock(Fragment,{key:group.label},[group.label?(openBlock(),createBlock(GroupHeader_default,{key:0,label:group.label,"bng-list-title":``},null,8,[`label`])):createCommentVNode(``,!0),(openBlock(!0),createElementBlock(Fragment,null,renderList(group.tiles,tile=>(openBlock(),createBlock(Tile_default,{key:tile.key,tile,"is-config":__props.isConfig,"display-size":__props.displaySize,"is-favourite":group.label===`Favourites`,"tile-images-top-aligned":__props.tileImagesTopAligned,onFocus:$event=>focusItem(tile),onClick:$event=>selectItem(tile),onDblclick:$event=>handleDoubleClick(tile)},null,8,[`tile`,`is-config`,`display-size`,`is-favourite`,`tile-images-top-aligned`,`onFocus`,`onClick`,`onDblclick`]))),128))],64))),128))]),_:1},8,[`layout`]))}},Grid_default$1=__plugin_vue_export_helper_default(_sfc_main$318,[[`__scopeId`,`data-v-efa73a51`]]),_hoisted_1$282={class:`display-controls-container`},_hoisted_2$232={class:`control-group-label`},_hoisted_3$206={key:0,class:`reset-button-container`},_sfc_main$317={__name:`DisplayControls`,props:{displayData:{type:Array,required:!0},detailsMode:{type:String,required:!0},updateDisplayData:{type:Function,required:!0},resetDisplayDataToDefaults:{type:Function,required:!0},setDetailsMode:{type:Function,required:!0}},emits:[`focus-item`],setup(__props,{emit:__emit}){let props=__props,emit$1=__emit,booleanToStringByKey=computed(()=>{let valuesByKey={};for(let option of props.displayData)if(option.type===`checkbox`){valuesByKey[option.key]={};for(let checkboxOption of option.options)valuesByKey[option.key][checkboxOption.value]=checkboxOption.label||(checkboxOption.value?`Yes`:`No`)}return valuesByKey}),controls$1=computed(()=>props.displayData.filter(x=>x.showInModes?.[props.detailsMode]).map(x=>({...x,checkboxLabel:x.type===`checkbox`?booleanToStringByKey.value[x.key]?.[x.value]:void 0}))),onOptionChanged=(key,newValue)=>{props.updateDisplayData(key,newValue),emit$1(`focus-item`,key)},resetToDefaults=()=>{props.resetDisplayDataToDefaults()};return(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$282,[createBaseVNode(`div`,{class:normalizeClass([`display-controls`,{"display-controls-list":__props.detailsMode===`displayControls`||__props.detailsMode===`default`}])},[(openBlock(!0),createElementBlock(Fragment,null,renderList(controls$1.value,option=>(openBlock(),createElementBlock(`div`,{key:option.key,class:normalizeClass([`control-group`,{"force-full-width":__props.detailsMode===`default`}])},[createBaseVNode(`div`,_hoisted_2$232,toDisplayString(option.label),1),createVNode(bngTooltip_default,{text:option.description||`No description available`,position:`top`},{default:withCtx(()=>[option.type===`dropdown`?(openBlock(),createBlock(unref(bngSmartSelect_default),{key:0,modelValue:option.value,items:option.options||[],"onUpdate:modelValue":newValue=>onOptionChanged(option.key,newValue),threshold:8},null,8,[`modelValue`,`items`,`onUpdate:modelValue`])):option.type===`checkbox`?(openBlock(),createBlock(unref(bngSwitch_default),{key:1,class:normalizeClass([`full-width-checkbox`,{active:option.value}]),modelValue:option.value,"onUpdate:modelValue":newValue=>onOptionChanged(option.key,newValue),labelBefore:``,alwaysTransparent:``},{default:withCtx(()=>[createTextVNode(toDisplayString(option.checkboxLabel),1)]),_:2},1032,[`class`,`modelValue`,`onUpdate:modelValue`])):option.type===`number`?(openBlock(),createBlock(unref(bngInputNew_default),{key:2,modelValue:option.value,min:option.min,max:option.max,showExternalButton:!1,type:`number`,"onUpdate:modelValue":newValue=>onOptionChanged(option.key,newValue)},null,8,[`modelValue`,`min`,`max`,`onUpdate:modelValue`])):createCommentVNode(``,!0)]),_:2},1032,[`text`])],2))),128))],2),__props.detailsMode===`displayControls`?(openBlock(),createElementBlock(`div`,_hoisted_3$206,[createVNode(unref(bngButton_default),{onClick:resetToDefaults,accent:`attention`,iconLeft:`trashBin1`,class:`reset-button`},{default:withCtx(()=>[..._cache[0]||=[createTextVNode(` Reset to Defaults `,-1)]]),_:1})])):createCommentVNode(``,!0)]))}},DisplayControls_default=__plugin_vue_export_helper_default(_sfc_main$317,[[`__scopeId`,`data-v-863e411a`]]),_sfc_main$316={__name:`SearchBar`,props:{searchText:{type:String,required:!0},setSearchText:{type:Function,required:!0},placeholder:{type:String,default:`Search...`},fullWidth:{type:Boolean,default:!1},showClearAllButton:{type:Boolean,default:!1}},emits:[`focus-item`,`clear-all`],setup(__props,{emit:__emit}){let props=__props,emit$1=__emit,clearSearch=()=>{props.setSearchText(``),emit$1(`focus-item`,`search`)},commitSearch=()=>{},onSearchChanged=value=>{props.setSearchText(value),emit$1(`focus-item`,`search`)};return(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,{class:normalizeClass([`search-container`,{"full-width":__props.fullWidth}])},[createVNode(unref(bngInput_default),{class:`search-input`,modelValue:__props.searchText,placeholder:__props.placeholder,onValueChanged:onSearchChanged,onKeydown:withKeys(commitSearch,[`enter`]),onBlur:commitSearch,onFocus:_cache[0]||=$event=>emit$1(`focus-item`,`search`)},null,8,[`modelValue`,`placeholder`]),createBaseVNode(`div`,{class:normalizeClass([`search-icon-container`,{active:__props.searchText}]),onClick:clearSearch},[createVNode(unref(bngIcon_default),{type:unref(icons).search,class:`search-icon show-unhovered`},null,8,[`type`]),createVNode(unref(bngIcon_default),{type:unref(icons).trashBin2,class:`search-icon show-hovered`},null,8,[`type`])],2)],2))}},SearchBar_default=__plugin_vue_export_helper_default(_sfc_main$316,[[`__scopeId`,`data-v-67aff9c0`]]),_hoisted_1$281={class:`filters`},_hoisted_2$231={key:0,class:`search-section`},_hoisted_3$205={key:1,class:`filter-options-grid`},_hoisted_4$176={class:`option-label`},_hoisted_5$151={class:`option-icon`},_hoisted_6$130={key:2,class:`filters-container`},_hoisted_7$116={class:`filter-container`,navigable:``,tabindex:`0`},_hoisted_8$97={class:`filter-content`},_hoisted_9$87={key:0,class:`filter-options`},_hoisted_10$76={class:`filter-options-grid`},_hoisted_11$68={class:`option-label`},_hoisted_12$56={class:`option-icon`},_hoisted_13$48={key:1,class:`filter-options`},_hoisted_14$43={class:`range-bar-container`},_hoisted_15$41={class:`range-bar`},_hoisted_16$39={class:`range-inputs`},_hoisted_17$32={class:`range-input-group`},_hoisted_18$29={class:`range-input-group`},_sfc_main$315={__name:`DetailedFilters`,props:{filterList:{type:Array,required:!0},filterByProp:{type:Object,required:!0},searchText:{type:String,default:``},commonFilters:{type:Array,default:()=>[]},detailsMode:{type:String,required:!0},onlyCommonFilters:{type:Boolean,default:!0},isFilterLocked:{type:Function,required:!0},isFilterOptionLocked:{type:Function,required:!0},isRangeFilterLocked:{type:Function,required:!0},toggleFilter:{type:Function,required:!0},updateRangeFilter:{type:Function,required:!0},resetRangeFilter:{type:Function,required:!0},setSearchText:{type:Function,required:!0},setDetailsMode:{type:Function,required:!0}},emits:[`focus-item`],setup(__props,{emit:__emit}){let props=__props,emit$1=__emit,expandedAccordions=ref({}),pendingRangeUpdates=ref({}),debouncedUpdateFunctions=ref({}),getDebouncedUpdate=propName=>(debouncedUpdateFunctions.value[propName]||(debouncedUpdateFunctions.value[propName]=debounce(()=>{if(pendingRangeUpdates.value[propName]){let{min:min$1,max:max$1}=pendingRangeUpdates.value[propName];props.updateRangeFilter(propName,min$1,max$1),delete pendingRangeUpdates.value[propName]}},300)),debouncedUpdateFunctions.value[propName]);onUnmounted(()=>{Object.values(debouncedUpdateFunctions.value).forEach(debouncedFn=>{debouncedFn&&debouncedFn.cancel&&debouncedFn.cancel()}),debouncedUpdateFunctions.value={},pendingRangeUpdates.value={}});let formatFilterName=key=>key,getFilterOptionClass=(propName,option)=>{let filter=props.filterList.find(f=>f.propName===propName);if(!filter||!filter.options)return``;let allEnabled=filter.options.every(opt=>props.filterByProp[propName]?.[opt]===!0),currentOptionEnabled=props.filterByProp[propName]?.[option]===!0;return allEnabled?`filter-neutral`:currentOptionEnabled?`filter-active`:`filter-inactive`},hasActiveFilters=propName=>{if(!props.filterList)return!1;let filter=props.filterList.find(f=>f.propName===propName);if(!filter)return!1;if(filter.type===`range`){let filterData=props.filterByProp[propName];if(!filterData)return!1;let currentMin=filterData.min,currentMax=filterData.max,defaultMin=filter.min,defaultMax=filter.max;return currentMin>defaultMin||currentMaxprops.filterByProp[propName]?.[option]===!1)},toggleFilter=(propName,option,event)=>{if(props.isFilterOptionLocked(propName,option)){console.log(`Cannot toggle locked filter:`,propName,option);return}event&&(event.preventDefault(),event.stopPropagation()),emit$1(`focus-item`,`filters`),props.toggleFilter(propName,option)},onRangeFilterChanged=(propName,newValue,field)=>{if(props.isRangeFilterLocked(propName)){console.log(`Cannot update locked range filter:`,propName);return}let filter=props.filterList.find(f=>f.propName===propName);if(!filter||filter.type!==`range`)return;let filterData=props.filterByProp[propName];if(!filterData)return;let currentPending=pendingRangeUpdates.value[propName],min$1=currentPending?currentPending.min:filterData.min,max$1=currentPending?currentPending.max:filterData.max;field===`min`?min$1=newValue:field===`max`&&(max$1=newValue),min$1=Math.max(filter.min,Math.min(filter.max,min$1)),max$1=Math.max(filter.min,Math.min(filter.max,max$1)),min$1>max$1&&([min$1,max$1]=[max$1,min$1]),pendingRangeUpdates.value[propName]={min:min$1,max:max$1},getDebouncedUpdate(propName)(),emit$1(`focus-item`,propName)},isFilterActive=filter=>hasActiveFilters(filter.propName),getRangeBarStyle=propName=>{let filter=props.filterList.find(f=>f.propName===propName);if(!filter||filter.type!==`range`)return{};let filterData=props.filterByProp[propName];if(!filterData)return{};let currentMin=filterData.min,currentMax=filterData.max,totalRange=filter.max-filter.min,leftPosition=(currentMin-filter.min)/totalRange*100,width$1=(currentMax-currentMin)/totalRange*100;return{left:`${leftPosition}%`,width:`${width$1}%`,backgroundColor:`var(--bng-orange-500)`}};return onMounted(()=>{props.filterList&&props.filterList.forEach(filter=>{hasActiveFilters(filter.propName)&&(expandedAccordions.value[filter.propName]=!0)})}),(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$281,[__props.detailsMode===`filter`?(openBlock(),createElementBlock(`div`,_hoisted_2$231,[createVNode(SearchBar_default,{searchText:__props.searchText,setSearchText:__props.setSearchText,placeholder:`Search items...`,"full-width":!0,onFocusItem:_cache[0]||=$event=>emit$1(`focus-item`,$event)},null,8,[`searchText`,`setSearchText`])])):createCommentVNode(``,!0),__props.detailsMode===`filter`?createCommentVNode(``,!0):(openBlock(),createElementBlock(`div`,_hoisted_3$205,[(openBlock(!0),createElementBlock(Fragment,null,renderList(__props.commonFilters,(filter,index)=>(openBlock(),createBlock(unref(bngPill_default),{key:index,class:normalizeClass([[getFilterOptionClass(filter[0],filter[1]),{"filter-locked":props.isFilterOptionLocked(filter[0],filter[1])}],`filter-option-chip`]),style:normalizeStyle({cursor:props.isFilterOptionLocked(filter[0],filter[1])?`not-allowed`:`pointer`}),"bng-nav-item":``,onClick:$event=>toggleFilter(filter[0],filter[1])},{default:withCtx(()=>[createBaseVNode(`span`,_hoisted_4$176,toDisplayString(filter[1]),1),createBaseVNode(`span`,_hoisted_5$151,[__props.filterByProp&&__props.filterByProp[filter[0]]&&__props.filterByProp[filter[0]][filter[1]]?(openBlock(),createBlock(unref(bngIcon_default),{key:0,type:unref(icons).checkmark},null,8,[`type`])):(openBlock(),createBlock(unref(bngIcon_default),{key:1,type:unref(icons).xmark},null,8,[`type`])),props.isFilterOptionLocked(filter[0],filter[1])?(openBlock(),createBlock(unref(bngIcon_default),{key:2,type:unref(icons).lockClosed,class:`lock-icon`},null,8,[`type`])):createCommentVNode(``,!0)])]),_:2},1032,[`class`,`style`,`onClick`]))),128))])),__props.detailsMode===`filter`?(openBlock(),createElementBlock(`div`,_hoisted_6$130,[createVNode(unref(accordion_default),{class:`filters-accordion`},{default:withCtx(()=>[(openBlock(!0),createElementBlock(Fragment,null,renderList(__props.filterList,filter=>(openBlock(),createElementBlock(`div`,{key:filter.propName,class:`filter-wrapper`},[createVNode(unref(accordionItem_default),{navigable:``,static:!filter.options||filter.options.length===0,"arrow-big":``,"expand-hint-inline":``,expanded:expandedAccordions.value[filter.propName],class:normalizeClass({"has-active-filters":isFilterActive(filter)}),onFocus:$event=>emit$1(`focus-item`,filter.propName)},{caption:withCtx(()=>[createBaseVNode(`div`,_hoisted_7$116,[createBaseVNode(`div`,_hoisted_8$97,toDisplayString(formatFilterName(filter.propName)),1)])]),default:withCtx(()=>[filter.type===`set`&&filter.options?(openBlock(),createElementBlock(`div`,_hoisted_9$87,[createBaseVNode(`div`,_hoisted_10$76,[(openBlock(!0),createElementBlock(Fragment,null,renderList(filter.options,(option,index)=>(openBlock(),createBlock(unref(bngPill_default),{key:index,class:normalizeClass([[getFilterOptionClass(filter.propName,option),{"filter-locked":props.isFilterOptionLocked(filter.propName,option)}],`filter-option-chip`]),style:normalizeStyle({cursor:props.isFilterOptionLocked(filter.propName,option)?`not-allowed`:`pointer`}),onClick:$event=>toggleFilter(filter.propName,option)},{default:withCtx(()=>[createBaseVNode(`span`,_hoisted_11$68,toDisplayString(option),1),createBaseVNode(`span`,_hoisted_12$56,[__props.filterByProp[filter.propName][option]?(openBlock(),createBlock(unref(bngIcon_default),{key:0,type:unref(icons).checkmark},null,8,[`type`])):(openBlock(),createBlock(unref(bngIcon_default),{key:1,type:unref(icons).abandon},null,8,[`type`])),props.isFilterOptionLocked(filter.propName,option)?(openBlock(),createBlock(unref(bngIcon_default),{key:2,type:unref(icons).lockClosed,class:`lock-icon`},null,8,[`type`])):createCommentVNode(``,!0)])]),_:2},1032,[`class`,`style`,`onClick`]))),128))])])):createCommentVNode(``,!0),filter.type===`range`?(openBlock(),createElementBlock(`div`,_hoisted_13$48,[createBaseVNode(`div`,_hoisted_14$43,[createBaseVNode(`div`,_hoisted_15$41,[createBaseVNode(`div`,{class:`range-selection`,style:normalizeStyle(getRangeBarStyle(filter.propName))},null,4)])]),createBaseVNode(`div`,_hoisted_16$39,[createBaseVNode(`div`,_hoisted_17$32,[_cache[1]||=createBaseVNode(`label`,{class:`range-label`},`Min:`,-1),(openBlock(),createBlock(unref(bngInput_default),{key:filter.propName+`min`,modelValue:__props.filterByProp[filter.propName].min,type:`number`,min:filter.min,max:filter.max,step:filter.step||1,disabled:props.isRangeFilterLocked(filter.propName),onValueChanged:val=>onRangeFilterChanged(filter.propName,val,`min`)},null,8,[`modelValue`,`min`,`max`,`step`,`disabled`,`onValueChanged`]))]),createBaseVNode(`div`,_hoisted_18$29,[_cache[2]||=createBaseVNode(`label`,{class:`range-label`},`Max:`,-1),(openBlock(),createBlock(unref(bngInput_default),{key:filter.propName+`max`,modelValue:__props.filterByProp[filter.propName].max,type:`number`,min:filter.min,max:filter.max,step:filter.step||1,disabled:props.isRangeFilterLocked(filter.propName),onValueChanged:val=>onRangeFilterChanged(filter.propName,val,`max`)},null,8,[`modelValue`,`min`,`max`,`step`,`disabled`,`onValueChanged`]))])])])):createCommentVNode(``,!0)]),_:2},1032,[`static`,`expanded`,`class`,`onFocus`])]))),128))]),_:1})])):createCommentVNode(``,!0)]))}},DetailedFilters_default=__plugin_vue_export_helper_default(_sfc_main$315,[[`__scopeId`,`data-v-a4758924`]]),_hoisted_1$280={key:1},_hoisted_2$230={key:1},_hoisted_3$204={key:1},_hoisted_4$175={key:1},_sfc_main$314={__name:`HeaderButtons`,props:{canSwitchDetails:{type:Boolean,default:!1},hiddenTabs:{type:Array,default:()=>[]},detailsMode:{type:String,required:!0},slim:{type:Boolean,default:!1}},emits:[`switch-details-mode`],setup(__props){return(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,{class:normalizeClass([`header-buttons`,{slim:__props.slim}])},[withDirectives(createVNode(unref(bngBinding_default),{class:`header-buttons-binding`,"ui-event":`context`,controller:``,"track-ignore":``},null,512),[[vShow,__props.canSwitchDetails]]),__props.hiddenTabs.includes(`detail`)?createCommentVNode(``,!0):withDirectives((openBlock(),createBlock(unref(bngButton_default),{key:0,class:normalizeClass([`header-button`,{selected:__props.detailsMode===`detail`}]),accent:unref(ACCENTS).text,onClick:_cache[0]||=$event=>_ctx.$emit(`switch-details-mode`,`detail`)},{default:withCtx(()=>[__props.slim?(openBlock(),createBlock(unref(bngIcon_default),{key:0,type:unref(icons).info},null,8,[`type`])):(openBlock(),createElementBlock(`span`,_hoisted_1$280,`Details`))]),_:1},8,[`class`,`accent`])),[[unref(BngTooltip_default),`Details`,`top`]]),__props.hiddenTabs.includes(`advanced`)?createCommentVNode(``,!0):withDirectives((openBlock(),createBlock(unref(bngButton_default),{key:1,class:normalizeClass([`header-button`,{selected:__props.detailsMode===`advanced`}]),accent:unref(ACCENTS).text,onClick:_cache[1]||=$event=>_ctx.$emit(`switch-details-mode`,`advanced`)},{default:withCtx(()=>[__props.slim?(openBlock(),createBlock(unref(bngIcon_default),{key:0,type:unref(icons).laneProperties},null,8,[`type`])):(openBlock(),createElementBlock(`span`,_hoisted_2$230,`Advanced`))]),_:1},8,[`class`,`accent`])),[[unref(BngTooltip_default),`Advanced`,`top`]]),__props.hiddenTabs.includes(`filter`)?createCommentVNode(``,!0):withDirectives((openBlock(),createBlock(unref(bngButton_default),{key:2,class:normalizeClass([`header-button`,{selected:__props.detailsMode===`filter`}]),accent:unref(ACCENTS).text,onClick:_cache[2]||=$event=>_ctx.$emit(`switch-details-mode`,`filter`)},{default:withCtx(()=>[__props.slim?(openBlock(),createBlock(unref(bngIcon_default),{key:0,type:unref(icons).filter},null,8,[`type`])):(openBlock(),createElementBlock(`span`,_hoisted_3$204,`Filters`))]),_:1},8,[`class`,`accent`])),[[unref(BngTooltip_default),`Filters`,`top`]]),__props.hiddenTabs.includes(`displayControls`)?createCommentVNode(``,!0):withDirectives((openBlock(),createBlock(unref(bngButton_default),{key:3,class:normalizeClass([`header-button`,{selected:__props.detailsMode===`displayControls`}]),accent:unref(ACCENTS).text,onClick:_cache[3]||=$event=>_ctx.$emit(`switch-details-mode`,`displayControls`)},{default:withCtx(()=>[__props.slim?(openBlock(),createBlock(unref(bngIcon_default),{key:0,type:unref(icons).adjust},null,8,[`type`])):(openBlock(),createElementBlock(`span`,_hoisted_4$175,`Display`))]),_:1},8,[`class`,`accent`])),[[unref(BngTooltip_default),`Display`,`top`]])],2))}},HeaderButtons_default=__plugin_vue_export_helper_default(_sfc_main$314,[[`__scopeId`,`data-v-157cdc63`]]),_sfc_main$313={__name:`Slideshow`,props:{images:Array,transition:Boolean,delay:{type:Number,default:1e4},parent:Object,shuffle:Boolean},setup(__props,{expose:__expose}){useCssVars(_ctx=>({v095d52f4:imgPrev.value,v095f8174:imgNext.value}));let props=__props,anim=ref(!1),imgPrev=ref(``),imgNext=ref(``),imgIndex=ref(-1),sequence=[],sequenceIndex=-1,tmrMain,tmrAnim,wImages,wParent;__expose({imgIndex,nextImage,carousel:{showNext:nextImage}}),onUnmounted(stopTimers);function stopTimers(){tmrMain&&=(clearTimeout(tmrMain),null),tmrAnim&&=(clearTimeout(tmrAnim),null)}watch(()=>props.parent,parent=>{wImages&&=(wImages(),null),wParent&&=(wParent(),null),parent?wParent=watch([()=>props.images,()=>parent.imgIndex],([images,index])=>{images&&(imgIndex.value=index,images.length>0&&nextTick(nextImage))},{immediate:!0}):wImages=watch([()=>props.images,()=>props.shuffle],([images,shuffle])=>{images&&(imgIndex.value=-1,images.length>0&&(shuffle&&(sequenceIndex=-1,sequence=Array.from(images).map((_,i)=>i).sort(()=>Math.random()-.5)),nextTick(nextImage)))},{immediate:!0})},{immediate:!0});function nextImage(){stopTimers(),props.parent||(props.shuffle&&sequence.length>0?(sequenceIndex=++sequenceIndex%props.images.length,imgIndex.value=sequence[sequenceIndex]):imgIndex.value=++imgIndex.value%props.images.length);let img=`url("${getAssetURL(props.images[imgIndex.value])}")`;props.transition?(imgNext.value=img,anim.value=!0,tmrAnim=setTimeout(()=>{tmrAnim=null,anim.value=!1,imgPrev.value=imgNext.value,imgNext.value=``},1e3)):imgPrev.value=img,!props.parent&&props.images.length>1&&(tmrMain=setTimeout(nextImage,props.delay))}return(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,{class:normalizeClass({anim:anim.value})},null,2))}},Slideshow_default=__plugin_vue_export_helper_default(_sfc_main$313,[[`__scopeId`,`data-v-f788946d`]]),_hoisted_1$279={key:0,class:`blur-wrap`},_sfc_main$312={__name:`BlurBackground`,setup(__props){let parentCarousel=inject(`mainBackground`),backgroundsBlur=inject(`mainBackgroundBlur`),bgRequired=sysInfo_default.mainMenuBackgroundRequired;return(_ctx,_cache)=>unref(bgRequired)?(openBlock(),createElementBlock(`div`,_hoisted_1$279,[createVNode(Slideshow_default,{class:`blur-carousel`,images:unref(backgroundsBlur),parent:unref(parentCarousel),transition:``},null,8,[`images`,`parent`])])):createCommentVNode(``,!0)}},BlurBackground_default=__plugin_vue_export_helper_default(_sfc_main$312,[[`__scopeId`,`data-v-cc1c4815`]]),_hoisted_1$278={class:`header-container`},_hoisted_2$229={key:1},_hoisted_3$203={class:`content-container`},_hoisted_4$174={class:`header-back-button`},_hoisted_5$150={key:0,class:`header-title-container`},_hoisted_6$129={class:`header-back-button`},_hoisted_7$115={class:`header-back-button`},_hoisted_8$96={key:0,class:`scrollable-content`},_hoisted_9$86={class:`details-mode-buttons`},_hoisted_10$75={key:1,class:`scrollable-content`},_hoisted_11$67={key:0,class:`details-content`},_hoisted_12$55={key:1,class:`scrollable-content`},_sfc_main$311={__name:`GridSelector`,props:{backendName:{type:String,default:`gridSelector`},routePath:{type:String,default:`/grid-selector`},defaultPath:{type:Object,default:()=>({keys:[`allModels`]})},defaultDetailsMode:{type:String,default:`detail`},hiddenTabs:{type:Array,default:()=>[]},tileImagesTopAligned:{type:Boolean,default:!1},doubleClickOverride:{type:Function,default:null},noBreadcrumbs:{type:Boolean,default:!1},overrideBackFromGrid:{type:Function,default:null},inlineHeaderContainer:{type:Boolean,default:!0},selectCallback:{type:Function,default:null},bubbleEvents:{type:Array,default:()=>[]}},setup(__props,{expose:__expose}){let props=__props,{showIfController}=storeToRefs(controls_default()),store$1=useGridSelector(props.backendName,props.defaultPath,props.defaultDetailsMode),{groups,displayData,detailsMode,selectedItem,showScreenHeader,screenHeaderTitle,screenHeaderPath,activeItemDetails,activeItem,activeFilters}=store$1,route=useRoute(),router$1=useRouter(),detailsModeTitles={detail:`Details`,advanced:`Advanced`,filter:`Filters`,displayControls:`Display`},detailsModeBackTo={filter:`advanced`,displayControls:`advanced`};watch(()=>[props.backendName,props.defaultPath,props.defaultDetailsMode],([newBackendName,newDefaultPath,newDefaultDetailsMode],[oldBackendName,oldDefaultPath,oldDefaultDetailsMode])=>{newBackendName!==oldBackendName&&newDefaultPath&&newDefaultPath.keys&&store$1.setCurrentPath(newDefaultPath),newDefaultDetailsMode!==oldDefaultDetailsMode&&store$1.setDetailsMode(newDefaultDetailsMode)},{deep:!0});let scopedNavState=reactive({isGridActive:!1,isDetailsActive:!1}),setBack=inject(`setBack`),showTopbarTabBindings=inject(`showTopbarTabBindings`),showTopbarBackBinding=inject(`showTopbarBackBinding`),showBreadcrumbsBack=ref(!1),canUseTopbar=ref(!0);watch(()=>scopedNavState.isDetailsActive,val=>{canUseTopbar.value=!val,showTopbarTabBindings(canUseTopbar.value)}),watch(screenHeaderPath,val=>{showBreadcrumbsBack.value=val&&val.length>2,showTopbarBackBinding(!showBreadcrumbsBack.value)});let switchSeq=computed(()=>[`detail`,`advanced`,`displayControls`].filter(tab=>!props.hiddenTabs.includes(tab))),getNextSwitchSeq=mode=>{mode||=detailsMode.value,mode===`filter`&&(mode=`advanced`);let seq=switchSeq.value;if(seq.length===0)return`detail`;let currentIndex=seq.indexOf(mode);return currentIndex===-1?seq[0]:seq[(currentIndex+1)%seq.length]},canSeeDetails=ref(!0),hasSelectedItem=computed(()=>!!store$1.selectedItem.value),canSwitchDetails=computed(()=>activeSectionScope.value!==`default`||detailsMode.value===`advanced`);function switchDetailsMode(mode){console.log(`switchDetailsMode`,mode),typeof mode!=`string`&&(mode=getNextSwitchSeq(mode)),mode===`detail`&&!canSeeDetails.value&&(mode=getNextSwitchSeq(mode)),console.log(`switchDetailsMode`,mode),store$1.setDetailsMode(mode),switchScope(`details`)}function onToggleSectionScope(){activeSectionScope.value===`grid`?switchScope(`details`):switchDetailsMode()}let activeSectionScope=ref(`grid`);function switchScope(name,force=!1){name||=activeSectionScope.value===`grid`?`details`:`grid`,name===`details`?(scopedNavState.isGridActive=!1,force&&(scopedNavState.isDetailsActive=!1),nextTick(()=>{activeSectionScope.value=name,scopedNavState.isDetailsActive=!0})):(scopedNavState.isDetailsActive=!1,force&&(scopedNavState.isGridActive=!1),nextTick(()=>{activeSectionScope.value=name,scopedNavState.isGridActive=!0}))}let onGridActivate=()=>{scopedNavState.isGridActive=!0},onGridDeactivate=event=>{scopedNavState.isGridActive=!1},onDetailsActivate=()=>{scopedNavState.isDetailsActive=!0},onDetailsDeactivate=event=>{scopedNavState.isDetailsActive=!1},setDetailsScope=info=>{switchScope(`details`)},canBubbleGridEvent=event=>!!(event.detail.name===`rotate_v_cam`||event.detail.name===`menu`||canUseTopbar.value&&(event.detail.name===`tab_l`||event.detail.name===`tab_r`)||props.bubbleEvents.includes(event.detail.name)),canBubbleDetailsEvent=event=>!!(event.detail.name===`rotate_v_cam`||props.bubbleEvents.includes(event.detail.name)),canDeactivateGrid=()=>screenHeaderPath.value.length<=1,onBackFromDetails=()=>{if(detailsMode.value===`displayControls`||detailsMode.value===`filter`){toggleDetailsMode(`advanced`);return}switchScope(`grid`)},onToggleFavorite=()=>{store$1.toggleFavourite(activeItem.value)},gridContentRef=ref(null),scrollPositions$1=ref(new Map),scrollTimeout=null,displaySize=computed(()=>{let option=displayData.value.find(option$1=>option$1.key===`displaySize`);return option?option.value:`medium`});store$1.initialize(),store$1.setOnBackFromDetailsCallback(()=>{onBackFromDetails()}),props.defaultPath.keys;let currentPathSegments=computed(()=>{let pathMatch=route.params.pathMatch;if(!pathMatch)return props.defaultPath?.keys||(Array.isArray(props.defaultPath)?props.defaultPath:[]);let segments=Array.isArray(pathMatch)?pathMatch.map(segment=>decodeURIComponent(segment)):[decodeURIComponent(pathMatch)];if(route.params.itemDetails){let itemDetails=Array.isArray(route.params.itemDetails)?route.params.itemDetails.map(segment=>decodeURIComponent(segment)):[decodeURIComponent(route.params.itemDetails)];segments.push(...itemDetails)}return segments}),saveScrollPosition$1=()=>{if(!gridContentRef.value)return;let pathKey=currentPathSegments.value.join(`/`),scrollTop=gridContentRef.value.scrollTop;scrollPositions$1.value.set(pathKey,scrollTop)},debouncedSaveScrollPosition=()=>{scrollTimeout&&clearTimeout(scrollTimeout),scrollTimeout=setTimeout(()=>{saveScrollPosition$1()},100)},restoreScrollPosition=()=>{if(!gridContentRef.value)return;let pathKey=currentPathSegments.value.join(`/`),savedPosition=scrollPositions$1.value.get(pathKey);savedPosition!==void 0&&nextTick(()=>{gridContentRef.value.scrollTop=savedPosition})};watch(groups,async newGroups=>{newGroups&&(await nextTick(),await nextTick(),store$1.notifyUIReady(),restoreScrollPosition())},{immediate:!0}),watch([currentPathSegments],async([segments],[oldSegments])=>{if(oldSegments&&gridContentRef.value){let oldPathKey=oldSegments.join(`/`),currentScrollTop=gridContentRef.value.scrollTop;scrollPositions$1.value.set(oldPathKey,currentScrollTop)}let path={keys:segments};await store$1.setCurrentPath(path)},{immediate:!0}),watch(gridContentRef,newElement=>{if(newElement){let handleScroll=()=>{debouncedSaveScrollPosition()};newElement.addEventListener(`scroll`,handleScroll),newElement._scrollHandler=handleScroll}},{immediate:!0}),onBeforeMount(()=>{Lua_default.simTimeAuthority.pushPauseRequest(`gridSelector`)}),onMounted(()=>{setBack(props.backendName,onBackFromGrid),nextTick(()=>{scopedNavState.isGridActive=!0})}),onUnmounted(()=>{setBack(props.backendName),gridContentRef.value&&gridContentRef.value._scrollHandler&&gridContentRef.value.removeEventListener(`scroll`,gridContentRef.value._scrollHandler),scrollTimeout&&clearTimeout(scrollTimeout),Lua_default.ui_gridSelector.closedFromUI(props.backendName),Lua_default.simTimeAuthority.popPauseRequest(`gridSelector`)});let onItemFocus=item=>{item&&item.showDetails&&store$1.setPreviewItem(item)},onItemSelect=async(item,doNavigation=!0)=>{if(item.gotoPath&&Array.isArray(item.gotoPath))store$1.prevSelectedItem.value=item.key,doNavigation&&routeNav(item),store$1.clearSelectedItem(),doNavigation&&switchScope(`grid`),props.selectCallback&&await props.selectCallback(item,doNavigation);else if(item.showDetails){item.key,selectedItem.value?.key;let consumed=!1;props.selectCallback&&(consumed=await props.selectCallback(item,doNavigation)),consumed||(await store$1.setSelectedItem(item),doNavigation&&switchScope(`details`))}},onGridWrapperClick=event=>{store$1.clearSelectedItem(),switchScope(`grid`,!0)},onDetailsWrapperClick=event=>{switchScope(`details`,!0)},onItemDeselect=()=>{store$1.clearSelectedItem()},toggleDetailsMode=mode=>{store$1.setDetailsMode(mode)};function routeNav(item){if(item.gotoAngularState)return;let encodedPath=item.gotoPath.map(segment=>encodeURIComponent(segment)).join(`/`);router$1.push(`${props.routePath}/${encodedPath}`)}let onBackFromGrid=()=>{if(console.log(`onBackFromGrid`,screenHeaderPath.value),props.overrideBackFromGrid&&screenHeaderPath.value.length<=2)return props.overrideBackFromGrid();if(screenHeaderPath.value.length>1){let item=screenHeaderPath.value[screenHeaderPath.value.length-2];return store$1.prevSelectedItem.value&&(store$1.autoFocusKey.value=store$1.prevSelectedItem.value),gotoHeaderItem(item),!1}return!0},onBreadBack=()=>nextTick(onBackFromGrid),clearSearch=()=>{store$1.setSearchText(``)},clearFilters=()=>{console.log(`clearFilters`,activeFilters.value);for(let filter of activeFilters.value)console.log(`clearFilter`,filter),filter&&filter.type===`range`?store$1.resetRangeFilter(filter.propName):store$1.resetSetFilter(filter.propName)},setCurrentPath=path=>{store$1.setCurrentPath(path)},gotoHeaderItem=item=>{console.log(`gotoHeaderItem`,item),item.gotoAngularState?window.bngVue.gotoAngularState(item.gotoAngularState):item.gotoPath&&(item.clearSearch&&clearSearch(),item.clearFilters&&clearFilters(),setCurrentPath({keys:item.gotoPath}),routeNav(item),switchScope(`grid`))};return __expose({screenHeaderPath,clearSearch,clearFilters,setCurrentPath}),(_ctx,_cache)=>withDirectives((openBlock(),createBlock(unref(layoutSingle_default),{class:`grid-selector`},{default:withCtx(()=>[createBaseVNode(`div`,_hoisted_1$278,[__props.noBreadcrumbs?(openBlock(),createElementBlock(`div`,_hoisted_2$229)):(openBlock(),createBlock(unref(bngBreadcrumbs_default),{key:0,class:`header-breadcrumbs`,items:unref(screenHeaderPath),limit:`5`,simple:``,"disable-last-item":``,"show-back-button":showBreadcrumbsBack.value,onClick:gotoHeaderItem,onBack:onBreadBack},null,8,[`items`,`show-back-button`])),__props.inlineHeaderContainer?createCommentVNode(``,!0):(openBlock(),createBlock(HeaderButtons_default,{key:2,"can-switch-details":canSwitchDetails.value,"hidden-tabs":props.hiddenTabs,"details-mode":unref(detailsMode),onSwitchDetailsMode:switchDetailsMode},null,8,[`can-switch-details`,`hidden-tabs`,`details-mode`]))]),createBaseVNode(`div`,_hoisted_3$203,[createBaseVNode(`div`,{class:normalizeClass([`grid-wrapper`,{active:activeSectionScope.value===`grid`}])},[createVNode(BlurBackground_default),unref(showScreenHeader)?(openBlock(),createElementBlock(`div`,{key:0,class:normalizeClass([`header-row`,{active:activeSectionScope.value===`grid`&&unref(showIfController),"no-controller":!unref(showIfController)}])},[createVNode(unref(bngScreenHeadingV2_default),{type:`2`,class:`header-title-v2`},{default:withCtx(()=>[createTextVNode(toDisplayString(unref(screenHeaderTitle)),1)]),_:1}),withDirectives(createBaseVNode(`div`,_hoisted_4$174,[createVNode(unref(bngBinding_default),{"ui-event":`back`,controller:``}),createVNode(unref(bngIcon_default),{type:unref(icons).undo},null,8,[`type`])],512),[[vShow,activeSectionScope.value===`grid`&&unref(showIfController)&¤tPathSegments.value.length>1]])],2)):createCommentVNode(``,!0),withDirectives((openBlock(),createElementBlock(`div`,{class:`grid-content`,ref_key:`gridContentRef`,ref:gridContentRef,"bng-nav-scroll":``,"bng-no-nav":`true`,tabindex:`-1`,onActivate:onGridActivate,onDeactivate:onGridDeactivate,onClick:onGridWrapperClick},[createVNode(Grid_default$1,{"in-details":activeSectionScope.value===`details`&&unref(detailsMode)===`detail`,"display-size":displaySize.value,"backend-name":props.backendName,"auto-focus-key":unref(store$1).autoFocusKey.value,"active-item":unref(store$1).activeItem.value,groups:unref(groups),"tile-images-top-aligned":__props.tileImagesTopAligned,onFocusItem:onItemFocus,onSelectItem:onItemSelect,onDeselectItem:onItemDeselect,"double-click-override":__props.doubleClickOverride},null,8,[`in-details`,`display-size`,`backend-name`,`auto-focus-key`,`active-item`,`groups`,`tile-images-top-aligned`,`double-click-override`])],32)),[[unref(BngScopedNav_default),{activated:scopedNavState.isGridActive,canBubbleEvent:canBubbleGridEvent,canDeactivate:canDeactivateGrid,preferAutoFocus:!0,autoFocusDelay:400}],[unref(BngOnUiNav_default),onToggleSectionScope,`context`],[unref(BngUiNavLabel_default),`Filters and more`,`context`],[unref(BngOnUiNav_default),onBackFromGrid,`back`],[unref(BngUiNavScroll_default)]])],2),withDirectives((openBlock(),createElementBlock(`div`,{class:normalizeClass([`details-wrapper wide`,{active:activeSectionScope.value===`details`,"no-controller":!unref(showIfController)}]),tabindex:`-1`,"bng-no-nav":`true`,onActivate:onDetailsActivate,onDeactivate:onDetailsDeactivate,onClick:onDetailsWrapperClick},[createVNode(BlurBackground_default),createBaseVNode(`div`,{class:normalizeClass([`header-row`,{active:activeSectionScope.value===`details`&&unref(showIfController),"no-controller":!unref(showIfController)}]),"bng-no-child-nav":`true`},[createVNode(HeaderButtons_default,{slim:``,"can-switch-details":canSwitchDetails.value,"hidden-tabs":props.hiddenTabs,"details-mode":unref(detailsMode),onSwitchDetailsMode:switchDetailsMode},null,8,[`can-switch-details`,`hidden-tabs`,`details-mode`]),__props.inlineHeaderContainer?createCommentVNode(``,!0):(openBlock(),createElementBlock(`div`,_hoisted_5$150,[createVNode(unref(bngCardHeading_default),{type:`ribbon`,class:`header-title`},{default:withCtx(()=>[createTextVNode(toDisplayString(detailsModeTitles[unref(detailsMode)]),1)]),_:1}),detailsModeBackTo[unref(detailsMode)]?(openBlock(),createBlock(unref(bngButton_default),{key:0,"bng-no-nav":`true`,onClick:_cache[0]||=$event=>toggleDetailsMode(detailsModeBackTo[unref(detailsMode)]),accent:unref(ACCENTS).outlined,iconRight:`undo`},{default:withCtx(()=>[createVNode(unref(bngBinding_default),{"ui-event":`back`,controller:``})]),_:1},8,[`accent`])):createCommentVNode(``,!0),withDirectives(createBaseVNode(`div`,_hoisted_6$129,[createVNode(unref(bngIcon_default),{type:unref(icons).adjust},null,8,[`type`]),createVNode(unref(bngBinding_default),{"ui-event":`context`,controller:``})],512),[[vShow,activeSectionScope.value===`grid`||!unref(showIfController)]]),withDirectives(createBaseVNode(`div`,_hoisted_7$115,[createVNode(unref(bngBinding_default),{"ui-event":`back`,controller:``}),createVNode(unref(bngIcon_default),{type:unref(icons).undo},null,8,[`type`])],512),[[vShow,activeSectionScope.value===`details`&&unref(showIfController)]])]))],2),unref(detailsMode)===`advanced`?(openBlock(),createElementBlock(`div`,_hoisted_8$96,[createVNode(SearchBar_default,{searchText:unref(store$1).searchText.value,setSearchText:unref(store$1).setSearchText},null,8,[`searchText`,`setSearchText`]),createVNode(DetailedFilters_default,{filterList:unref(store$1).filterList.value,filterByProp:unref(store$1).filterByProp.value,searchText:unref(store$1).searchText.value,commonFilters:unref(store$1).commonFilters.value,detailsMode:unref(store$1).detailsMode.value,onlyCommonFilters:unref(store$1).onlyCommonFilters.value,isFilterLocked:unref(store$1).isFilterLocked,isFilterOptionLocked:unref(store$1).isFilterOptionLocked,isRangeFilterLocked:unref(store$1).isRangeFilterLocked,toggleFilter:unref(store$1).toggleFilter,updateRangeFilter:unref(store$1).updateRangeFilter,resetRangeFilter:unref(store$1).resetRangeFilter,setSearchText:unref(store$1).setSearchText,setDetailsMode:unref(store$1).setDetailsMode},null,8,[`filterList`,`filterByProp`,`searchText`,`commonFilters`,`detailsMode`,`onlyCommonFilters`,`isFilterLocked`,`isFilterOptionLocked`,`isRangeFilterLocked`,`toggleFilter`,`updateRangeFilter`,`resetRangeFilter`,`setSearchText`,`setDetailsMode`]),createVNode(DisplayControls_default,{displayData:unref(store$1).displayData.value,detailsMode:unref(store$1).detailsMode.value,updateDisplayData:unref(store$1).updateDisplayData,resetDisplayDataToDefaults:unref(store$1).resetDisplayDataToDefaults,setDetailsMode:unref(store$1).setDetailsMode},null,8,[`displayData`,`detailsMode`,`updateDisplayData`,`resetDisplayDataToDefaults`,`setDetailsMode`]),createBaseVNode(`div`,_hoisted_9$86,[createVNode(unref(bngButton_default),{onClick:_cache[1]||=$event=>toggleDetailsMode(`filter`),accent:unref(ACCENTS).secondary,iconLeft:`filter`},{default:withCtx(()=>[..._cache[3]||=[createTextVNode(` More filters... `,-1)]]),_:1},8,[`accent`]),createVNode(unref(bngButton_default),{onClick:_cache[2]||=$event=>toggleDetailsMode(`displayControls`),accent:unref(ACCENTS).secondary,iconLeft:`adjust`},{default:withCtx(()=>[..._cache[4]||=[createTextVNode(` Display Options `,-1)]]),_:1},8,[`accent`])]),createVNode(unref(bngCardHeading_default),{type:`line`,class:`heading`},{default:withCtx(()=>[..._cache[5]||=[createTextVNode(`Management`,-1)]]),_:1}),renderSlot(_ctx.$slots,`management-details`,{managementDetails:unref(store$1).managementDetails.value,executeButton:unref(store$1).executeButton},void 0,!0)])):unref(detailsMode)===`filter`?(openBlock(),createElementBlock(`div`,_hoisted_10$75,[createVNode(DetailedFilters_default,{filterList:unref(store$1).filterList.value,filterByProp:unref(store$1).filterByProp.value,searchText:unref(store$1).searchText.value,commonFilters:unref(store$1).commonFilters.value,detailsMode:unref(store$1).detailsMode.value,onlyCommonFilters:unref(store$1).onlyCommonFilters.value,isFilterLocked:unref(store$1).isFilterLocked,isFilterOptionLocked:unref(store$1).isFilterOptionLocked,isRangeFilterLocked:unref(store$1).isRangeFilterLocked,toggleFilter:unref(store$1).toggleFilter,updateRangeFilter:unref(store$1).updateRangeFilter,resetRangeFilter:unref(store$1).resetRangeFilter,setSearchText:unref(store$1).setSearchText,setDetailsMode:unref(store$1).setDetailsMode},null,8,[`filterList`,`filterByProp`,`searchText`,`commonFilters`,`detailsMode`,`onlyCommonFilters`,`isFilterLocked`,`isFilterOptionLocked`,`isRangeFilterLocked`,`toggleFilter`,`updateRangeFilter`,`resetRangeFilter`,`setSearchText`,`setDetailsMode`])])):unref(detailsMode)===`displayControls`?(openBlock(),createBlock(DisplayControls_default,{key:2,class:`scrollable-content`,displayData:unref(store$1).displayData.value,detailsMode:unref(store$1).detailsMode.value,updateDisplayData:unref(store$1).updateDisplayData,resetDisplayDataToDefaults:unref(store$1).resetDisplayDataToDefaults,setDetailsMode:unref(store$1).setDetailsMode},null,8,[`displayData`,`detailsMode`,`updateDisplayData`,`resetDisplayDataToDefaults`,`setDetailsMode`])):unref(detailsMode)===`detail`?(openBlock(),createElementBlock(Fragment,{key:3},[hasSelectedItem.value?(openBlock(),createElementBlock(`div`,_hoisted_11$67,[renderSlot(_ctx.$slots,`item-details`,{activeItem:unref(store$1).activeItem.value,activeItemDetails:unref(store$1).activeItemDetails.value,executeButton:unref(store$1).executeButton,toggleFavourite:unref(store$1).toggleFavourite,exploreFolder:unref(store$1).exploreFolder,goToMod:unref(store$1).goToMod,onFocusItem:setDetailsScope},void 0,!0)])):(openBlock(),createElementBlock(`div`,_hoisted_12$55,[createVNode(SearchBar_default,{searchText:unref(store$1).searchText.value,setSearchText:unref(store$1).setSearchText},null,8,[`searchText`,`setSearchText`]),createVNode(DetailedFilters_default,{filterList:unref(store$1).filterList.value,filterByProp:unref(store$1).filterByProp.value,searchText:unref(store$1).searchText.value,commonFilters:unref(store$1).commonFilters.value,detailsMode:unref(store$1).detailsMode.value,onlyCommonFilters:unref(store$1).onlyCommonFilters.value,isFilterLocked:unref(store$1).isFilterLocked,isFilterOptionLocked:unref(store$1).isFilterOptionLocked,isRangeFilterLocked:unref(store$1).isRangeFilterLocked,toggleFilter:unref(store$1).toggleFilter,updateRangeFilter:unref(store$1).updateRangeFilter,resetRangeFilter:unref(store$1).resetRangeFilter,setSearchText:unref(store$1).setSearchText,setDetailsMode:unref(store$1).setDetailsMode},null,8,[`filterList`,`filterByProp`,`searchText`,`commonFilters`,`detailsMode`,`onlyCommonFilters`,`isFilterLocked`,`isFilterOptionLocked`,`isRangeFilterLocked`,`toggleFilter`,`updateRangeFilter`,`resetRangeFilter`,`setSearchText`,`setDetailsMode`]),createVNode(DisplayControls_default,{displayData:unref(store$1).displayData.value,detailsMode:unref(store$1).detailsMode.value,updateDisplayData:unref(store$1).updateDisplayData,resetDisplayDataToDefaults:unref(store$1).resetDisplayDataToDefaults,setDetailsMode:unref(store$1).setDetailsMode},null,8,[`displayData`,`detailsMode`,`updateDisplayData`,`resetDisplayDataToDefaults`,`setDetailsMode`]),createVNode(unref(bngCardHeading_default),{type:`line`,class:`heading`},{default:withCtx(()=>[..._cache[6]||=[createTextVNode(`Info`,-1)]]),_:1}),_cache[7]||=createBaseVNode(`div`,{class:`scrollable-content`},` Please select an item to see details. `,-1)]))],64)):createCommentVNode(``,!0)],34)),[[unref(BngScopedNav_default),{activated:scopedNavState.isDetailsActive,canDeactivate:()=>!1,canBubbleEvent:canBubbleDetailsEvent,bubbleWhitelistEvents:[`menu`]}],[unref(BngOnUiNav_default),onToggleSectionScope,`context`],[unref(BngUiNavLabel_default),`Filters and more`,`context`],[unref(BngOnUiNav_default),onToggleFavorite,`action_2`],[unref(BngUiNavLabel_default),`Toggle favorite`,`action_2`],[unref(BngOnUiNav_default),onBackFromDetails,`back`,{focusRequired:!0}]])])]),_:3})),[[unref(BngBlur_default)],[unref(BngOnUiNav_default),()=>{},`rotate_h_cam,rotate_v_cam`]])}},GridSelector_default=__plugin_vue_export_helper_default(_sfc_main$311,[[`__scopeId`,`data-v-d340d12f`]]),_hoisted_1$277={class:`details`,"bng-nav-scroll":``},_hoisted_2$228={key:0,class:`preview`},_hoisted_3$202={key:1,class:`content-header`},_hoisted_4$173={key:0,class:`description`},_hoisted_5$149={key:0,class:`specs-grid`},_hoisted_6$128={class:`specs-grid-container`},_hoisted_7$114={class:`spec-content`},_hoisted_8$95={class:`spec-label`},_hoisted_9$85={class:`spec-value`},_hoisted_10$74={key:2,class:`buttons-section`},_sfc_main$310={__name:`AppDetails`,props:{activeItem:{type:Object,default:null},activeItemDetails:{type:Object,default:null},executeButton:{type:Function,required:!0},toggleFavourite:{type:Function,required:!0}},setup(__props){let props=__props,handleButtonClick=buttonId=>{props.executeButton(buttonId)};return(_ctx,_cache)=>withDirectives((openBlock(),createElementBlock(`div`,_hoisted_1$277,[__props.activeItemDetails?.preview?(openBlock(),createElementBlock(`div`,_hoisted_2$228,[createVNode(unref(aspectRatio_default),{class:`preview-image`,ratio:`16:8`,"external-image":__props.activeItemDetails.preview},null,8,[`external-image`])])):createCommentVNode(``,!0),__props.activeItemDetails?.headerTitle?(openBlock(),createElementBlock(`div`,_hoisted_3$202,[__props.activeItemDetails?.description?(openBlock(),createElementBlock(`div`,_hoisted_4$173,toDisplayString(__props.activeItemDetails.description),1)):createCommentVNode(``,!0)])):createCommentVNode(``,!0),(openBlock(!0),createElementBlock(Fragment,null,renderList(__props.activeItemDetails?.specifications,(specList,specListIndex)=>(openBlock(),createElementBlock(Fragment,{key:specListIndex},[specList.length>0?(openBlock(),createElementBlock(`div`,_hoisted_5$149,[createBaseVNode(`div`,_hoisted_6$128,[(openBlock(!0),createElementBlock(Fragment,null,renderList(specList,specification=>(openBlock(),createElementBlock(`div`,{key:specification.key,class:`spec-cell`},[specification.icon?(openBlock(),createBlock(unref(bngIcon_default),{key:0,type:specification.icon,class:`spec-icon`},null,8,[`type`])):createCommentVNode(``,!0),createBaseVNode(`div`,_hoisted_7$114,[createBaseVNode(`div`,_hoisted_8$95,toDisplayString(specification.label)+`:`,1),createBaseVNode(`div`,_hoisted_9$85,[createBaseVNode(`span`,null,toDisplayString(specification.value),1)])])]))),128))])])):createCommentVNode(``,!0)],64))),128)),__props.activeItemDetails?.buttonInfo?.length>0?(openBlock(),createElementBlock(`div`,_hoisted_10$74,[(openBlock(!0),createElementBlock(Fragment,null,renderList(__props.activeItemDetails.buttonInfo,button=>(openBlock(),createBlock(unref(bngButton_default),{key:button.buttonId,"bng-scoped-nav-autofocus":button.primary,accent:button.primary?`main`:`secondary`,label:button.label,icon:button.icon,onClick:$event=>handleButtonClick(button.buttonId)},null,8,[`bng-scoped-nav-autofocus`,`accent`,`label`,`icon`,`onClick`]))),128))])):createCommentVNode(``,!0)])),[[unref(BngUiNavScroll_default),void 0,void 0,{force:!0}]])}},AppDetails_default=__plugin_vue_export_helper_default(_sfc_main$310,[[`__scopeId`,`data-v-c8fb13f2`]]),_sfc_main$309={__name:`AppSelector`,setup(__props){return(_ctx,_cache)=>(openBlock(),createBlock(GridSelector_default,{backendName:`appSelector`,routePath:`/app-selector`,defaultPath:{keys:[`allApps`]},defaultDetailsMode:`advanced`},{"item-details":withCtx(({activeItem,activeItemDetails,executeButton,toggleFavourite})=>[createVNode(AppDetails_default,{activeItem,activeItemDetails,executeButton,toggleFavourite},null,8,[`activeItem`,`activeItemDetails`,`executeButton`,`toggleFavourite`])]),_:1}))}},AppSelector_default=_sfc_main$309,routes_default=[{name:`menu.appselector`,path:`/app-selector/:pathMatch(.*)*`,component:AppSelector_default,props:!0,meta:{clickThrough:!1,infoBar:{visible:!0,showSysInfo:!1},uiApps:{shown:!1},topBar:{visible:!0}}},{name:`menu.appedit`,path:`/app-edit/`,component:NotFound_default,meta:{clickThrough:!0,infoBar:{visible:!0,showSysInfo:!1},uiApps:{shown:!0},topBar:{visible:!0}}}],_hoisted_1$276={class:`main-info`},_hoisted_2$227={class:`heading`},_hoisted_3$201={key:0,class:`stars`},_hoisted_4$172={key:1,class:`aggregate-primary`},_hoisted_5$148={class:`label`},_hoisted_6$127={class:`value`},_hoisted_7$113={key:2,class:`empty-gap`},_sfc_main$308={__name:`PoiCard`,props:{poi:{type:Object,required:!0},shown:{type:Boolean,default:!0}},emits:[`select`,`hover`],setup(__props,{emit:__emit}){let debugLog$1=(message,data)=>{},props=__props,emit$1=__emit,onSelect=()=>{props.poi.id,props.poi.name,emit$1(`select`,props.poi.id)},thumbLoaded=props.shown&&!!props.poi?.thumbnail,thumbShown=ref(thumbLoaded),thumb=ref(thumbLoaded?`url("${props.poi?.thumbnail}")`:`none`),lastThumb=thumbLoaded?props.poi?.thumbnail:void 0;return watch([()=>props.shown,()=>props.poi],()=>{if(props.shown&&props.poi?.thumbnail){let url=props.poi.thumbnail;if(lastThumb!==url){lastThumb=url,thumbLoaded=!1;let img=new Image;img.src=url,img.onload=()=>{lastThumb===url&&(thumbLoaded=!0,thumb.value=`url("${url}")`,thumbShown.value=!0)}}}else props.poi?.thumbnail||(lastThumb=void 0,thumbLoaded=!1,thumb.value=`none`,thumbShown.value=!1)},{immediate:!0}),(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,{class:normalizeClass([`poi-item`,{highlighted:__props.poi.isSelected}]),onClick:onSelect,"bng-nav-item":``},[createBaseVNode(`div`,{class:normalizeClass([`card-info`,{"content-shown":__props.shown,"thumb-show":thumbShown.value&&!!thumb.value}]),style:normalizeStyle({"--poi-image":thumb.value})},[__props.poi.icon?(openBlock(),createBlock(unref(bngIcon_default),{key:0,class:`mission-icon`,type:__props.poi.icon,color:`white`},null,8,[`type`])):createCommentVNode(``,!0),createBaseVNode(`div`,_hoisted_1$276,[createBaseVNode(`div`,_hoisted_2$227,toDisplayString(__props.poi.name),1),__props.poi.formattedProgress?(openBlock(),createElementBlock(`div`,_hoisted_3$201,[__props.poi.formattedProgress.unlockedStars?(openBlock(),createBlock(unref(bngMainStars_default),{key:0,"individual-stars":__props.poi.formattedProgress.unlockedStars.defaults,class:`main-stars`,scale:.6,reverse:``},null,8,[`individual-stars`])):createCommentVNode(``,!0),__props.poi.formattedProgress.unlockedStars&&__props.poi.formattedProgress.unlockedStars.totalBonusStarCount>0?(openBlock(),createBlock(unref(bngMainStars_default),{key:1,"individual-stars":__props.poi.formattedProgress.unlockedStars.bonus,class:`bonus-stars`,scale:.6},null,8,[`individual-stars`])):createCommentVNode(``,!0)])):__props.poi.aggregatePrimary?(openBlock(),createElementBlock(`div`,_hoisted_4$172,[createBaseVNode(`span`,_hoisted_5$148,toDisplayString(__props.poi.aggregatePrimary.label)+`:`,1),createBaseVNode(`span`,_hoisted_6$127,toDisplayString(__props.poi.aggregatePrimary.value),1)])):(openBlock(),createElementBlock(`div`,_hoisted_7$113))]),createVNode(unref(bngBinding_default),{class:`input-icon`,"ui-event":`ok`,controller:``})],6)],2))}},PoiCard_default=__plugin_vue_export_helper_default(_sfc_main$308,[[`__scopeId`,`data-v-cd49bd11`]]),_hoisted_1$275={class:`poi-list`},_hoisted_2$226={class:`filter-header`},_hoisted_3$200={class:`poi-list-items`},_sfc_main$307={__name:`PoiList`,props:{store:{type:Object,required:!0}},setup(__props){let props=__props,poiListContainer=ref(null),shownCards=ref(new Set),{groupData,poiData,selectedPoi,selectPoi,onHover,debugLog:debugLog$1}=props.store,processedPoiData=computed(()=>{let processed={};if(!poiData.value)return processed;for(let[poiId,poi]of Object.entries(poiData.value))poi&&(processed[poiId]={id:poi.id||poiId,name:poi.name?$translate.instant(poi.name):``,icon:poi.icon?icons[poi.icon]:icons._empty,thumbnail:poi.thumbnailFile,formattedProgress:poi.formattedProgress,aggregatePrimary:poi.aggregatePrimary?.label&&poi.aggregatePrimary?.value?{label:$translate.instant(poi.aggregatePrimary.label),value:$translate.instant(poi.aggregatePrimary.value)}:null,isSelected:selectedPoi.value?.id===poi.id});return processed});debugLog$1(`PoiList`,`Component initialized`,{groupDataCount:groupData.value?.length||0,poiDataCount:Object.keys(poiData.value||{}).length,processedPoiCount:Object.keys(processedPoiData.value).length});let observer$2=new IntersectionObserver(entries=>{for(let entry of entries){let poiId=entry.target.getAttribute(`data-poi-id`);poiId&&entry.isIntersecting?shownCards.value.add(poiId):shownCards.value.delete(poiId)}},{threshold:.1,rootMargin:`10px`}),setupObserver=()=>{if(!poiListContainer.value)return;let elms$4=poiListContainer.value.querySelectorAll(`[data-poi-id]`),ids=[];for(let elm of elms$4){let poiId=elm.getAttribute(`data-poi-id`);poiId&&(ids.push(poiId),observer$2.observe(elm))}for(let id of shownCards.value)ids.includes(id)||shownCards.value.delete(id)};return watch(poiListContainer,cont=>cont&&nextTick(setupObserver),{immediate:!0}),watch([groupData,processedPoiData],()=>{nextTick(()=>{observer$2.disconnect(),setupObserver()})},{immediate:!1}),onUnmounted(()=>{shownCards.value.clear(),observer$2.disconnect()}),(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$275,[createBaseVNode(`div`,{class:`poi-list-content`,ref_key:`poiListContainer`,ref:poiListContainer},[(openBlock(!0),createElementBlock(Fragment,null,renderList(unref(groupData),section=>(openBlock(),createElementBlock(`div`,{key:section.key,class:`filter-section`},[createBaseVNode(`div`,_hoisted_2$226,[createVNode(unref(bngIcon_default),{type:section.icon},null,8,[`type`]),createBaseVNode(`span`,null,toDisplayString(section.title?_ctx.$tt(section.title):``),1)]),(openBlock(!0),createElementBlock(Fragment,null,renderList(section.groups,group=>(openBlock(),createElementBlock(`div`,{key:group.key,class:`mission-group`},[createVNode(unref(bngCardHeading_default),{class:`mission-group-header`,type:`ribbon`,outline:``},{default:withCtx(()=>[createTextVNode(toDisplayString(_ctx.$t(group.label)),1)]),_:2},1024),createBaseVNode(`div`,_hoisted_3$200,[(openBlock(!0),createElementBlock(Fragment,null,renderList(group.elementIds,poiId=>(openBlock(),createBlock(PoiCard_default,{key:poiId,"data-poi-id":poiId,shown:shownCards.value.has(poiId),poi:processedPoiData.value[poiId],onSelect:unref(selectPoi),onHover:unref(onHover)},null,8,[`data-poi-id`,`shown`,`poi`,`onSelect`,`onHover`]))),128))])]))),128))]))),128))],512)]))}},PoiList_default=__plugin_vue_export_helper_default(_sfc_main$307,[[`__scopeId`,`data-v-0ccba230`]]),_hoisted_1$274={class:`header`},_sfc_main$306={__name:`bngAdvCardHeading`,props:{blurDelay:Number,preheadings:Array,divider:Boolean,icon:String,type:{type:String,default:`line`,validator:v=>[`line`,`ribbon`].includes(v)||v===``}},setup(__props){let blurVal=ref(!1);onMounted(()=>window.setTimeout(()=>blurVal.value=!0,~~+props.blurDelay));let props=__props;return(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,{class:normalizeClass([`bng-screen-header`,{[`heading-style-${__props.type}`]:!0,prehead:__props.preheadings}])},[_cache[0]||=createBaseVNode(`div`,{class:`decorator`},null,-1),__props.preheadings?(openBlock(),createElementBlock(`span`,{key:0,class:normalizeClass([`pre-header`,{"with-divider":__props.divider}])},[__props.icon?(openBlock(),createBlock(unref(bngIcon_default),{key:0,type:__props.icon,class:`pre-header-icon`},null,8,[`type`])):createCommentVNode(``,!0),(openBlock(!0),createElementBlock(Fragment,null,renderList(__props.preheadings,preheading=>(openBlock(),createElementBlock(`span`,{class:`location`,key:preheading},toDisplayString(preheading),1))),128))],2)):createCommentVNode(``,!0),createBaseVNode(`h1`,_hoisted_1$274,[renderSlot(_ctx.$slots,`default`,{},void 0,!0)])],2))}},bngAdvCardHeading_default=__plugin_vue_export_helper_default(_sfc_main$306,[[`__scopeId`,`data-v-16619e8d`]]),_hoisted_1$273={key:0,class:`poi-icons`},_hoisted_2$225=[`onClick`],_hoisted_3$199={key:1,class:`poi-details`},_hoisted_4$171={class:`poi-content`},_hoisted_5$147={class:`poi-scrollable`},_hoisted_6$126={key:0,class:`poi-aggregate-display`},_hoisted_7$112={key:0,class:`poi-stars`},_hoisted_8$94={class:`stars`},_hoisted_9$84={key:1,class:`aggregate-primary`},_hoisted_10$73={class:`label`},_hoisted_11$66={class:`value`},_hoisted_12$54={key:1,class:`poi-description`},_hoisted_13$47={class:`poi-actions`},_sfc_main$305={__name:`PoiDetails`,props:{store:{type:Object,required:!0}},emits:[`setRoute`,`teleport`],setup(__props,{emit:__emit}){let props=__props,{selectedPoi,selectedPoiIds,poiData,debugLog:debugLog$1}=props.store;debugLog$1(`PoiDetails`,`Component initialized`,{selectedPoiId:selectedPoi.value?.id,selectedPoiIdsCount:selectedPoiIds.value?.length||0});let selectedPoisList=computed(()=>{if(!selectedPoiIds.value||selectedPoiIds.value.length===0)return selectedPoi.value?[selectedPoi.value]:[];let pois=[];for(let poiId of selectedPoiIds.value){let poi=poiData.value[poiId];poi&&pois.push(poi)}return debugLog$1(`PoiDetails`,`Final pois list`,pois),pois}),currentPoiIndex=computed(()=>{if(selectedPoisList.value.length<=1)return 0;let index=selectedPoisList.value.findIndex(poi=>poi.id===selectedPoi.value?.id);return index>=0?index:0}),selectPoi=index=>{index>=0&&index{let headings=[];return selectedPoi.value?.label&&headings.push($translate.instant(selectedPoi.value.label)),headings}),preview=computed(()=>selectedPoi.value?.previewFiles?.length>0?selectedPoi.value.previewFiles[0]:selectedPoi.value?.thumbnailFile||null),safeTranslate=key=>{if(!key)return``;try{return typeof key==`string`?$translate.instant(key):(typeof key==`object`&&key.txt,$translate.contextTranslate(key))}catch(e){return console.warn(`Translation failed for key:`,key,e),typeof key==`string`?key:key?.txt||``}},aggregatePrimary=computed(()=>{let poi=selectedPoi.value;return poi?.aggregatePrimary?.label&&poi?.aggregatePrimary?.value?poi.aggregatePrimary:null}),onAction=action=>{props.store.executePoiAction(action.actionId)};return(_ctx,_cache)=>(openBlock(),createElementBlock(Fragment,null,[selectedPoisList.value.length>=1?withDirectives((openBlock(),createElementBlock(`div`,_hoisted_1$273,[(openBlock(!0),createElementBlock(Fragment,null,renderList(selectedPoisList.value,(poi,index)=>(openBlock(),createElementBlock(`div`,{key:poi.id||index,class:normalizeClass([`poi-icon`,{active:index===currentPoiIndex.value}]),onClick:$event=>selectPoi(index)},[createVNode(unref(bngSpriteIcon_default),{src:`map_`+poi.spriteIcon,style:{width:`100%`,height:`100%`}},null,8,[`src`])],10,_hoisted_2$225))),128))])),[[unref(BngBlur_default),!0]]):createCommentVNode(``,!0),unref(selectedPoi)?withDirectives((openBlock(),createElementBlock(`div`,_hoisted_3$199,[createBaseVNode(`div`,_hoisted_4$171,[createVNode(bngAdvCardHeading_default,{class:`poi-details-header`,type:`line`,preheadings:preheadings.value},{default:withCtx(()=>[createTextVNode(toDisplayString(safeTranslate(unref(selectedPoi).name)),1)]),_:1},8,[`preheadings`]),createBaseVNode(`div`,_hoisted_5$147,[preview.value?(openBlock(),createBlock(aspectRatio_default,{key:0,class:`poi-thumbnail`,ratio:`16:9`,externalImage:preview.value,imageMode:`cover`},{default:withCtx(()=>[aggregatePrimary.value||unref(selectedPoi).formattedProgress?(openBlock(),createElementBlock(`div`,_hoisted_6$126,[unref(selectedPoi).formattedProgress?(openBlock(),createElementBlock(`div`,_hoisted_7$112,[createBaseVNode(`div`,_hoisted_8$94,[unref(selectedPoi).formattedProgress.unlockedStars?(openBlock(),createBlock(unref(bngMainStars_default),{key:0,individualStars:unref(selectedPoi).formattedProgress.unlockedStars.defaults,class:`main-stars`,scale:.8,reverse:``},null,8,[`individualStars`])):createCommentVNode(``,!0),unref(selectedPoi).formattedProgress.unlockedStars&&unref(selectedPoi).formattedProgress.unlockedStars.totalBonusStarCount>0?(openBlock(),createBlock(unref(bngMainStars_default),{key:1,individualStars:unref(selectedPoi).formattedProgress.unlockedStars.bonus,class:`bonus-stars`,scale:.8},null,8,[`individualStars`])):createCommentVNode(``,!0)])])):aggregatePrimary.value?(openBlock(),createElementBlock(`div`,_hoisted_9$84,[createBaseVNode(`span`,_hoisted_10$73,toDisplayString(_ctx.$t(aggregatePrimary.value.label))+`:`,1),createBaseVNode(`span`,_hoisted_11$66,toDisplayString(_ctx.$t(aggregatePrimary.value.value)),1)])):createCommentVNode(``,!0)])):createCommentVNode(``,!0)]),_:1},8,[`externalImage`])):createCommentVNode(``,!0),unref(selectedPoi).description?(openBlock(),createElementBlock(`div`,_hoisted_12$54,toDisplayString(safeTranslate(unref(selectedPoi).description)),1)):createCommentVNode(``,!0)]),createBaseVNode(`div`,_hoisted_13$47,[(openBlock(!0),createElementBlock(Fragment,null,renderList(unref(selectedPoi).actions,action=>(openBlock(),createBlock(unref(bngButton_default),{key:action.id,accent:unref(ACCENTS).secondary,"icon-right":action.icon,label:action.label,onClick:$event=>onAction(action)},null,8,[`accent`,`icon-right`,`label`,`onClick`]))),128))])])])),[[unref(BngBlur_default),!0]]):createCommentVNode(``,!0)],64))}},PoiDetails_default=__plugin_vue_export_helper_default(_sfc_main$305,[[`__scopeId`,`data-v-35e47e7e`]]),_hoisted_1$272={class:`poi-filters`},_hoisted_2$224={key:0,class:`filter-row`},_hoisted_3$198=[`onClick`],_hoisted_4$170=[`onClick`],_sfc_main$304={__name:`PoiFilters`,props:{store:{type:Object,required:!0}},setup(__props){let props=__props,{filterData,debugLog:debugLog$1}=props.store;debugLog$1(`PoiFilters`,`Component initialized`,{filterDataCount:filterData.value?.length||0});let getGroupVisualState=(filter,group)=>{if(!filter||!group||!filter.groups||!Array.isArray(filter.groups))return`inactive`;let visibleGroups=0,totalGroups=0;for(let filterGroup of filter.groups)filterGroup&&filterGroup.elementCount>0&&(totalGroups++,filterGroup.visible&&visibleGroups++);let isAllGroupsActive=visibleGroups===totalGroups,isGroupActive=group.visible;return isAllGroupsActive?`neutral`:isGroupActive?`active`:`inactive`},getGroupColor=(filter,group)=>{switch(getGroupVisualState(filter,group)){case`neutral`:return`var(--bng-off-white)`;case`active`:return`var(--bng-add-green-100)`;case`inactive`:default:return`var(--bng-add-red-300)`}},hasActiveFilters=filter=>{if(!filter||!filter.groups||!Array.isArray(filter.groups))return!1;let visibleGroups=0,totalGroups=0;for(let group of filter.groups)group&&group.elementCount>0&&(totalGroups++,group.visible&&visibleGroups++);return visibleGroups{debugLog$1(`PoiFilters`,`Toggling group visibility`,groupKey),props.store.toggleGroupVisibility(groupKey)},toggleFilterSectionVisibility=filterKey=>{debugLog$1(`PoiFilters`,`Toggling filter section visibility`,filterKey),props.store.toggleFilterSectionVisibility(filterKey)};return(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$272,[(openBlock(!0),createElementBlock(Fragment,null,renderList(unref(filterData),filterSection=>(openBlock(),createElementBlock(Fragment,{key:filterSection.key},[filterSection&&filterSection.groups?withDirectives((openBlock(),createElementBlock(`div`,_hoisted_2$224,[createBaseVNode(`div`,{class:normalizeClass([`filter-icon`,{"has-active-filters":hasActiveFilters(filterSection)}]),onClick:$event=>toggleFilterSectionVisibility(filterSection.key)},[createVNode(bngTooltip_default,{text:_ctx.$tt(filterSection.title)},{default:withCtx(()=>[createVNode(unref(bngIcon_default),{type:filterSection.icon},null,8,[`type`])]),_:2},1032,[`text`])],10,_hoisted_3$198),_cache[0]||=createBaseVNode(`div`,{class:`filter-separator`},null,-1),(openBlock(!0),createElementBlock(Fragment,null,renderList(filterSection.groups,group=>(openBlock(),createElementBlock(Fragment,{key:group.key},[group&&group.elementCount>0?(openBlock(),createElementBlock(`div`,{key:0,class:normalizeClass([`filter-group`,{inactive:!group.visible}]),onClick:$event=>toggleGroupVisibility(group.key)},[createVNode(bngTooltip_default,{text:_ctx.$tt(group.label)+` ×`+group.elementCount},{default:withCtx(()=>[createVNode(unref(bngIcon_default),{type:group.icon||`info`,color:getGroupColor(filterSection,group)},null,8,[`type`,`color`])]),_:2},1032,[`text`])],10,_hoisted_4$170)):createCommentVNode(``,!0)],64))),128))])),[[unref(BngBlur_default),!0]]):createCommentVNode(``,!0)],64))),128))]))}},PoiFilters_default=__plugin_vue_export_helper_default(_sfc_main$304,[[`__scopeId`,`data-v-43aa27ac`]]);const debugLog=(component,message,data)=>{};function useBigMap(){let selectedPoi=ref(null),selectedPoiIds=ref([]),filterData=ref([]),groupData=ref([]),poiData=ref({}),gameMode=ref(``),levelData=ref({title:``}),isPoiListVisible=ref(!1),isDetailsVisible=ref(!1),{events:events$3}=useBridge(),translatedPreheadings=computed(()=>{let preheadings=[];return gameMode.value&&preheadings.push($translate.instant(`ui.playmodes.${gameMode.value}`)),levelData.value?.title&&preheadings.push($translate.instant(levelData.value.title)),preheadings}),currentFilterTitle=computed(()=>$translate.instant(`bigMap.sideMenu.pois`)),getStaticDataFromLua=async()=>{try{poiData.value=await Lua_default.freeroam_vueBigMap.getPoiData()||{};let gameStateResult=await Lua_default.freeroam_vueBigMap.getGameStateInfo();gameStateResult&&(gameMode.value=gameStateResult.gameMode||``,levelData.value=gameStateResult.levelData||{title:``}),poiData.value,gameMode.value}catch(error){console.error(`Error getting static data from Lua:`,error)}},getDynamicDataFromLua=async()=>{try{filterData.value=await Lua_default.freeroam_vueBigMap.getFilters()||[],groupData.value=await Lua_default.freeroam_vueBigMap.getGroups()||[],filterData.value,groupData.value}catch(error){console.error(`Error getting dynamic data from Lua:`,error)}},handleShowPoiDetails=data=>{let poiIds=data?.poiIds||[];if(selectedPoiIds.value=poiIds,poiIds.length===0){selectedPoi.value=null,isDetailsVisible.value=!1;return}let selectedPoiId=poiIds[0];selectedPoiId&&poiData.value[selectedPoiId]?(selectedPoi.value=poiData.value[selectedPoiId],isDetailsVisible.value=!0):(selectedPoi.value=null,isDetailsVisible.value=!1)},toggleGroupVisibility=async groupKey=>{try{let filterIds=[groupKey];await Lua_default.freeroam_vueBigMap.toggleFiltersByIds(filterIds),await getDynamicDataFromLua()}catch(error){console.error(`Error toggling group visibility:`,error)}},toggleFilterSectionVisibility=async filterKey=>{try{await Lua_default.freeroam_vueBigMap.toggleFilterSectionById(filterKey),await getDynamicDataFromLua()}catch(error){console.error(`Error toggling filter visibility:`,error)}},selectPoi=async poiId=>{try{let result=await Lua_default.freeroam_vueBigMap.selectPoiFromList(poiId);result===`success`?poiId?(selectedPoi.value=poiData.value[poiId],isDetailsVisible.value=!0):(selectedPoi.value=null,isDetailsVisible.value=!1):console.error(`Failed to select POI:`,result)}catch(error){console.error(`Error selecting POI:`,error)}};return{selectedPoi,selectedPoiIds,filterData,groupData,poiData,gameMode,levelData,isPoiListVisible,isDetailsVisible,translatedPreheadings,currentFilterTitle,initialize:async()=>{try{await Lua_default.freeroam_vueBigMap.enterBigMap(),await getStaticDataFromLua(),await getDynamicDataFromLua(),events$3.on(`showPoiDetails`,handleShowPoiDetails)}catch(error){console.error(`Error initializing bigmap:`,error)}},cleanup:async()=>{try{await Lua_default.freeroam_vueBigMap.exitBigMap(),events$3.off(`showPoiDetails`)}catch(error){console.error(`Error cleaning up bigmap:`,error)}},selectPoi,showPoiList:()=>{isPoiListVisible.value=!0},hidePoiList:()=>{isPoiListVisible.value=!1,selectedPoi.value&&selectPoi(null)},onHover:async(poiId,active)=>{try{await Lua_default.freeroam_vueBigMap.hoverPoiFromList(poiId,active)}catch(error){console.error(`Error hovering POI:`,error)}},executePoiAction:async actionId=>{try{await Lua_default.freeroam_vueBigMap.executePoiAction(actionId)}catch(error){console.error(`Error executing POI action:`,error)}},toggleGroupVisibility,toggleFilterSectionVisibility,debugLog}}var _hoisted_1$271={class:`bigmap-container`},_hoisted_2$223={class:`bigmap-content`},_hoisted_3$197={class:`bigmap-left-content`},_hoisted_4$169={class:`bigmap-poilist-outline`},_hoisted_5$146={key:0,class:`bigmap-details-outline`},_sfc_main$303={__name:`BigMap`,setup(__props){let store$1=useBigMap(),{isPoiListVisible,isDetailsVisible,translatedPreheadings,currentFilterTitle,onSetRoute,onTeleport,toggleGroupVisibility,initialize,cleanup,debugLog:debugLog$1}=store$1,handleToggleGroupVisibility=groupKey=>{debugLog$1(`BigMap`,`Toggle group visibility`,groupKey),toggleGroupVisibility(groupKey)};return onMounted(()=>{debugLog$1(`BigMap`,`Component mounted, initializing bigmap`),initialize()}),onUnmounted(()=>{debugLog$1(`BigMap`,`Component unmounted, cleaning up bigmap`),cleanup()}),(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$271,[createVNode(unref(bngScreenHeading_default),{class:`bigmap-heading`,preheadings:unref(translatedPreheadings),divider:!0,type:`line`},{default:withCtx(()=>[createTextVNode(toDisplayString(unref(currentFilterTitle)),1)]),_:1},8,[`preheadings`]),createBaseVNode(`div`,_hoisted_2$223,[createBaseVNode(`div`,_hoisted_3$197,[createVNode(PoiFilters_default,{store:unref(store$1),onToggleGroupVisibility:handleToggleGroupVisibility},null,8,[`store`]),createBaseVNode(`div`,_hoisted_4$169,[createVNode(unref(bngDrawer_default),{modelValue:unref(isPoiListVisible),"onUpdate:modelValue":_cache[0]||=$event=>isRef(isPoiListVisible)?isPoiListVisible.value=$event:null,position:`left`,blur:``,header:_ctx.$tt(`bigMap.sideMenu.pois`)},{default:withCtx(()=>[createVNode(PoiList_default,{class:`bigmap-poilist`,store:unref(store$1)},null,8,[`store`])]),_:1},8,[`modelValue`,`header`])])]),_cache[1]||=createBaseVNode(`div`,{class:`bigmap-center-outline`},null,-1),unref(isDetailsVisible)?(openBlock(),createElementBlock(`div`,_hoisted_5$146,[createVNode(PoiDetails_default,{store:unref(store$1),onSetRoute:unref(onSetRoute),onTeleport:unref(onTeleport)},null,8,[`store`,`onSetRoute`,`onTeleport`])])):createCommentVNode(``,!0)])]))}},BigMap_default=__plugin_vue_export_helper_default(_sfc_main$303,[[`__scopeId`,`data-v-e6716bb0`]]),_hoisted_1$270={class:`bigmap-view`},_sfc_main$302={__name:`BigMapView`,setup(__props){return(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$270,[createVNode(BigMap_default)]))}},BigMapView_default=__plugin_vue_export_helper_default(_sfc_main$302,[[`__scopeId`,`data-v-044f4742`]]),routes_default$1=[{path:`/bigmap`,name:`bigmap`,component:BigMapView_default,meta:{uiApps:{shown:!1},infoBar:{visible:!0,showSysInfo:!0}}}],_hoisted_1$269={class:`progress-steps`},_hoisted_2$222={class:`step-container`},_hoisted_3$196={class:`step-header`},_hoisted_4$168={class:`step-number`},_hoisted_5$145={class:`step-icon`},_hoisted_6$125={class:`step-label`},_sfc_main$301={__name:`ProgressSteps`,props:{steps:{type:Array,required:!0,validator:steps=>steps.every(step=>step.label&&typeof step.label==`string`||step.title&&typeof step.title==`string`)},currentStep:{type:Number,required:!0,validator:step=>step>=0}},setup(__props){let props=__props,styles={answeredYes:{class:`answered-yes`,icon:`checkboxOn`},answeredNo:{class:`answered-no`,icon:`missionCheckboxCross`},current:{class:`not-answered current`,icon:`arrowLargeRight`},next:{class:`not-answered`,icon:`checkboxOff`}},steps=computed(()=>props.steps.map((step,idx)=>{let answer=step.isAnswered?step.answerType||`yes`:null,status=`next`;return idx(openBlock(),createElementBlock(`div`,_hoisted_1$269,[createBaseVNode(`div`,_hoisted_2$222,[(openBlock(!0),createElementBlock(Fragment,null,renderList(steps.value,(step,index)=>(openBlock(),createElementBlock(`div`,{key:index,class:normalizeClass([`step`,step.class])},[createBaseVNode(`div`,_hoisted_3$196,[createBaseVNode(`div`,_hoisted_4$168,toDisplayString(index+1),1),step.isLastStep?createCommentVNode(``,!0):(openBlock(),createElementBlock(Fragment,{key:0},[_cache[0]||=createBaseVNode(`div`,{class:`step-connector`},null,-1),createBaseVNode(`div`,_hoisted_5$145,[createVNode(unref(bngIcon_default),{type:step.icon},null,8,[`type`])])],64))]),createBaseVNode(`div`,_hoisted_6$125,toDisplayString(_ctx.$tt(step.label)),1)],2))),128))])]))}},ProgressSteps_default=__plugin_vue_export_helper_default(_sfc_main$301,[[`__scopeId`,`data-v-d5d29cd2`]]);function useWizard(options={}){let{allowSkip=!1,validateSteps=!0}=options,stepRegistry=ref(new Map),currentStepIndex=ref(0),completedSteps=ref(new Set),isFinished=ref(!1),steps=computed(()=>{if(stepRegistry.value.size===0)return[];let res=Array.from(stepRegistry.value.values());for(let step of res)if(!(!step.enabledWhen||step.enabledWhen.length===0)){for(let condition of step.enabledWhen)if(condition.step){let dependencyStep=res.find(s=>s.id===condition.step);if(!dependencyStep)continue;dependencyStep.requiredFor||=[],dependencyStep.requiredFor.includes(step.id)||dependencyStep.requiredFor.push(step.id)}}return res}),registerStep=stepConfig=>stepRegistry.value.set(stepConfig.id,stepConfig),unregisterStep=stepId=>stepRegistry.value.delete(stepId);provide(`registerWizardStep`,registerStep),provide(`unregisterWizardStep`,unregisterStep);let currentStep=computed(()=>steps.value[currentStepIndex.value]||null),isFirstStep=computed(()=>currentStepIndex.value===0),isLastStep=computed(()=>currentStepIndex.value===steps.value.length-1),canGoNext=computed(()=>{if(!validateSteps)return!0;let step=currentStep.value;return!step||!isStepEnabled(step)||step.advanceDisabled?!1:typeof step.validate==`function`?step.validate(step.modelValue||{}):step.type===`choice`&&step.required!==!1?step.modelValue?.choice!==void 0:(step.type,!0)}),isStepEnabled=step=>!step.enabledWhen||step.enabledWhen.length===0?!0:step.enabledWhen.every(condition=>{if(condition.step){let dependencyStepData=steps.value.find(s=>s.id===condition.step)?.modelValue||{};if(condition.value!==void 0)return dependencyStepData?.choice===condition.value||dependencyStepData?.[Object.keys(dependencyStepData)[0]]===condition.value;if(typeof condition.condition==`function`)return condition.condition(dependencyStepData)}return typeof condition.condition==`function`?condition.condition():!0}),canGoBack=computed(()=>!isFirstStep.value),canFinish=computed(()=>validateSteps?isLastStep.value&&canGoNext.value:isLastStep.value),goToStep=index=>{index<=0&&(currentStepIndex.value=0),index>=steps.value.length&&(currentStepIndex.value=steps.value.length-1),currentStepIndex.value=index},nextStep=async()=>{if(await nextTick(),!canGoNext.value)return!1;if(currentStep.value&&completedSteps.value.add(currentStepIndex.value),isLastStep.value)return!0;for(currentStepIndex.value++;currentStepIndex.value=steps.value.length&&(currentStepIndex.value=steps.value.length-1),!0};return{currentStepIndex,currentStep,completedSteps,isFinished,steps,stepRegistry,isFirstStep,isLastStep,canGoNext,canGoBack,canFinish,progress:computed(()=>steps.value.length===0?0:Math.round((currentStepIndex.value+1)/steps.value.length*100)),stepProgress:computed(()=>steps.value.map((step,index)=>{let data=step.modelValue||{},choiceAnalysis=null;if(step.type===`choice`&&step.choices&&data.choice!==void 0){let selectedChoice=step.choices.find(c=>c.value===data.choice),yesChoice=step.choices.find(c=>c.isYes),noChoice=step.choices.find(c=>c.isNo),answerType=null;selectedChoice&&(answerType=selectedChoice.isYes||yesChoice&&selectedChoice.value===yesChoice.value?`yes`:selectedChoice.isNo||noChoice&&selectedChoice.value===noChoice.value?`no`:!yesChoice&&!noChoice?`yes`:step.choices.length===2&&!selectedChoice.isYes&&!selectedChoice.isNo?`no`:`yes`),choiceAnalysis={selectedValue:data.choice,selectedChoice,answerType,hasYesFlag:!!yesChoice,hasNoFlag:!!noChoice}}return{...step,index,isCompleted:completedSteps.value.has(index),isCurrent:index===currentStepIndex.value,isAccessible:index<=currentStepIndex.value,isEnabled:isStepEnabled(step),data,hasData:Object.keys(data).length>0,isAnswered:step.type===`choice`?data.choice!==void 0:Object.keys(data).length>0,answerType:choiceAnalysis?.answerType||null,choiceAnalysis}})),goToStep,nextStep,previousStep:async()=>{if(await nextTick(),!canGoBack.value)return!1;for(currentStepIndex.value--;currentStepIndex.value>=0;){let targetStep=steps.value[currentStepIndex.value];if(isStepEnabled(targetStep)||targetStep.autoSkip===!1)break;currentStepIndex.value--}return currentStepIndex.value<0&&(currentStepIndex.value=0),!0},finish:()=>canFinish.value?(isFinished.value=!0,{success:!0,completedSteps:Array.from(completedSteps.value)}):{success:!1},reset:()=>{currentStepIndex.value=0,completedSteps.value.clear(),isFinished.value=!1},skip:()=>allowSkip?nextStep():!1,isStepEnabled,registerStep,unregisterStep}}var _hoisted_1$268={class:`wizard-container`},_hoisted_2$221={class:`wizard-content`},_hoisted_3$195={class:`wizard-step-content`},_hoisted_4$167={key:0,class:`wizard-validation`},_hoisted_5$144={class:`validation-message`},_hoisted_6$124={class:`wizard-navigation`},_hoisted_7$111={key:2,class:`switch-buttons`};const wizardProps={wizardOptions:{type:Object,default:()=>({})},title:String,preheadings:Array,showDivider:{type:Boolean,default:!0},showProgress:{type:Boolean,default:!0},showBackButton:{type:Boolean,default:!0},allowSkip:{type:Boolean,default:!1},backButtonText:{type:String,default:`ui.common.back`},nextButtonText:{type:String,default:`ui.common.next`},finishButtonText:{type:String,default:`ui.common.finish`},skipButtonText:{type:String,default:`ui.common.skip`},validationMessage:String};var _sfc_main$300={__name:`Wizard`,props:mergeModels(wizardProps,{modelValue:{default:()=>({})},modelModifiers:{}}),emits:mergeModels([`step-change`,`step-complete`,`wizard-finish`,`validation-error`],[`update:modelValue`]),setup(__props,{expose:__expose,emit:__emit}){let props=__props,modelValue=useModel(__props,`modelValue`),emit$1=__emit,{currentStepIndex,currentStep,isFirstStep,isLastStep,canGoNext,canGoBack,canFinish,progress,stepProgress,nextStep:wizardNextStep,previousStep:wizardPreviousStep,skip:wizardSkip,steps,registerStep:originalRegisterStep}=useWizard({...props.wizardOptions,allowSkip:props.allowSkip}),instance$1=getCurrentInstance(),hasCentralizedModel=computed(()=>!!(instance$1&&instance$1.attrs&&`onUpdate:modelValue`in instance$1.attrs));provide(`currentWizardStep`,currentStep),provide(`wizardNext`,()=>nextStep()),provide(`wizardSteps`,steps),provide(`registerWizardStep`,stepConfig=>hasCentralizedModel.value?originalRegisterStep({...stepConfig,get modelValue(){return modelValue.value?.[stepConfig.id]||{}},updateModelValue:newValue=>{modelValue.value={...modelValue.value,[stepConfig.id]:newValue}}}):originalRegisterStep(stepConfig)),provide(`unregisterWizardStep`,stepId=>{if(hasCentralizedModel.value&&props.modelValue[stepId]){let updatedData={...props.modelValue};delete updatedData[stepId],emit$1(`update:modelValue`,updatedData)}});let currentStepChoices=computed(()=>currentStep.value?.choices||[]),getChoiceButtonClass=(choiceValue,selectedChoice)=>selectedChoice?selectedChoice===choiceValue?`answered-selected`:`answered-not-selected`:`unanswered`,handleChoiceClick=choice=>{currentStep.value?.updateModelValue&&(currentStep.value.updateModelValue({...currentStep.value.modelValue,choice:choice.value}),nextTick(()=>!currentStep.value?.advanceDisabled&&nextStep()))},nextStep=()=>{let stepId=currentStep.value?.id,currentData=currentStep.value?.modelValue||{};emit$1(`step-complete`,{stepId,stepIndex:currentStepIndex.value,step:currentStep.value,data:currentData}),wizardNextStep()&&emit$1(`step-change`,{from:currentStepIndex.value-1,to:currentStepIndex.value,step:currentStep.value})},previousStep=()=>{let prevIndex=currentStepIndex.value;wizardPreviousStep()&&emit$1(`step-change`,{from:prevIndex,to:currentStepIndex.value,step:currentStep.value})},skip=()=>{wizardSkip()&&emit$1(`step-complete`,{stepId:currentStep.value?.id,stepIndex:currentStepIndex.value-1,skipped:!0,data:currentStep.value?.modelValue||{}})},handleFinish=()=>{let allStepData={};steps.value.forEach(step=>{step.modelValue&&Object.keys(step.modelValue).length>0&&(allStepData[step.id]=step.modelValue)}),canFinish.value?emit$1(`wizard-finish`,{success:!0,data:allStepData,completedSteps:Array.from({length:steps.value.length},(_,i)=>i)}):emit$1(`validation-error`,{step:currentStep.value,message:`Cannot finish wizard - validation failed`})};return __expose({currentStepIndex,currentStep,progress,stepProgress,nextStep,previousStep,finish:handleFinish,skip,steps}),(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$268,[createBaseVNode(`div`,_hoisted_2$221,[_ctx.title?(openBlock(),createBlock(unref(bngScreenHeading_default),{key:0,preheadings:_ctx.preheadings,"show-divider":_ctx.showDivider},{default:withCtx(()=>[createTextVNode(toDisplayString(_ctx.$tt(_ctx.title)),1)]),_:1},8,[`preheadings`,`show-divider`])):createCommentVNode(``,!0),_ctx.showProgress?(openBlock(),createBlock(unref(bngCard_default),{key:1,class:`wizard-progress-card`},{default:withCtx(()=>[createVNode(ProgressSteps_default,{steps:unref(stepProgress),"current-step":unref(currentStepIndex)},null,8,[`steps`,`current-step`])]),_:1})):createCommentVNode(``,!0),createVNode(unref(bngCard_default),{class:`wizard-main-card`},{buttons:withCtx(()=>[createBaseVNode(`div`,_hoisted_6$124,[_ctx.showBackButton&&!unref(isFirstStep)?(openBlock(),createBlock(unref(bngButton_default),{key:0,disabled:!unref(canGoBack),accent:unref(ACCENTS).secondary,onClick:previousStep},{default:withCtx(()=>[createTextVNode(toDisplayString(_ctx.$tt(_ctx.backButtonText)),1)]),_:1},8,[`disabled`,`accent`])):createCommentVNode(``,!0),_ctx.allowSkip&&!unref(isLastStep)&&unref(currentStep)?.type!==`choice`?(openBlock(),createBlock(unref(bngButton_default),{key:1,accent:unref(ACCENTS).secondary,onClick:skip},{default:withCtx(()=>[createTextVNode(toDisplayString(_ctx.$tt(_ctx.skipButtonText)),1)]),_:1},8,[`accent`])):createCommentVNode(``,!0),_cache[0]||=createBaseVNode(`div`,{class:`spacer`},null,-1),unref(currentStep)?.type===`choice`?(openBlock(),createElementBlock(`div`,_hoisted_7$111,[(openBlock(!0),createElementBlock(Fragment,null,renderList(currentStepChoices.value,choice=>(openBlock(),createBlock(unref(bngButton_default),{key:choice.value,class:normalizeClass(getChoiceButtonClass(choice.value,unref(currentStep)?.modelValue?.choice||null)),accent:unref(ACCENTS).custom,icon:unref(currentStep)?.modelValue?.choice===choice.value?unref(icons).checkmark:null,disabled:unref(currentStep)?.advanceDisabled,onClick:$event=>handleChoiceClick(choice)},{default:withCtx(()=>[createTextVNode(toDisplayString(_ctx.$tt(choice.label)),1)]),_:2},1032,[`class`,`accent`,`icon`,`disabled`,`onClick`]))),128))])):createCommentVNode(``,!0),!unref(isLastStep)&&unref(currentStep)?.type!==`choice`?(openBlock(),createBlock(unref(bngButton_default),{key:3,disabled:!unref(canGoNext),accent:unref(ACCENTS).primary,onClick:nextStep},{default:withCtx(()=>[createTextVNode(toDisplayString(_ctx.$tt(_ctx.nextButtonText)),1)]),_:1},8,[`disabled`,`accent`])):unref(isLastStep)?(openBlock(),createBlock(unref(bngButton_default),{key:4,disabled:!unref(canFinish),accent:unref(ACCENTS).primary,onClick:handleFinish},{default:withCtx(()=>[createTextVNode(toDisplayString(_ctx.$tt(_ctx.finishButtonText)),1)]),_:1},8,[`disabled`,`accent`])):createCommentVNode(``,!0)])]),default:withCtx(()=>[unref(currentStep)?.title?(openBlock(),createBlock(unref(bngCardHeading_default),{key:0,type:`ribbon`},{default:withCtx(()=>[renderSlot(_ctx.$slots,`step-title`,{step:unref(currentStep)},()=>[createTextVNode(toDisplayString(_ctx.$tt(unref(currentStep).title)),1)],!0)]),_:3})):createCommentVNode(``,!0),withDirectives((openBlock(),createElementBlock(`div`,_hoisted_3$195,[renderSlot(_ctx.$slots,`step`,{step:unref(currentStep),stepData:unref(currentStep)?.modelValue,updateStepData:unref(currentStep)?.updateModelValue,stepIndex:unref(currentStepIndex),isFirst:unref(isFirstStep),isLast:unref(isLastStep)},()=>[renderSlot(_ctx.$slots,`default`,{},void 0,!0)],!0),_ctx.validationMessage?(openBlock(),createElementBlock(`div`,_hoisted_4$167,[createBaseVNode(`div`,_hoisted_5$144,toDisplayString(_ctx.validationMessage),1)])):createCommentVNode(``,!0)])),[[unref(BngUiNavScroll_default)]])]),_:3})])]))}},Wizard_default=__plugin_vue_export_helper_default(_sfc_main$300,[[`__scopeId`,`data-v-69c7b9c4`]]),_sfc_main$299={__name:`WizardView`,props:mergeModels({...wizardProps},{modelValue:{},modelModifiers:{}}),emits:mergeModels([`step-change`,`step-complete`,`wizard-finish`,`validation-error`],[`update:modelValue`]),setup(__props,{expose:__expose}){let props=__props,slots=useSlots(),wizardRef=ref(),wizardModel=useModel(__props,`modelValue`);return __expose({wizard:wizardRef,get currentStepIndex(){return wizardRef.value?.currentStepIndex},get currentStep(){return wizardRef.value?.currentStep},get progress(){return wizardRef.value?.progress},get stepProgress(){return wizardRef.value?.stepProgress},get steps(){return wizardRef.value?.steps},nextStep:()=>wizardRef.value?.nextStep(),previousStep:()=>wizardRef.value?.previousStep(),finish:()=>wizardRef.value?.finish(),skip:()=>wizardRef.value?.skip()}),(_ctx,_cache)=>withDirectives((openBlock(),createBlock(unref(layoutSingle_default),{class:`layout-content-full content-center layout-paddings wizard-view`},{default:withCtx(()=>[createVNode(Wizard_default,mergeProps({ref_key:`wizardRef`,ref:wizardRef},props,{modelValue:wizardModel.value,"onUpdate:modelValue":_cache[0]||=$event=>wizardModel.value=$event,onStepChange:_cache[1]||=$event=>_ctx.$emit(`step-change`,$event),onStepComplete:_cache[2]||=$event=>_ctx.$emit(`step-complete`,$event),onWizardFinish:_cache[3]||=$event=>_ctx.$emit(`wizard-finish`,$event),onValidationError:_cache[4]||=$event=>_ctx.$emit(`validation-error`,$event)}),createSlots({_:2},[renderList(unref(slots),(slot,name)=>({name,fn:withCtx(props$1=>[renderSlot(_ctx.$slots,name,normalizeProps(guardReactiveProps(props$1)),void 0,!0)])}))]),1040,[`modelValue`])]),_:3})),[[unref(BngBlur_default)]])}},WizardView_default=__plugin_vue_export_helper_default(_sfc_main$299,[[`__scopeId`,`data-v-e47281c4`]]),_hoisted_1$267={key:0,class:`wizard-summary`},_sfc_main$298={__name:`WizardSummary`,props:{custom:{type:Array,default:()=>[],validator:items$2=>items$2.every(item=>item.label&&item.value!==void 0)},replace:{type:Boolean,default:!1}},setup(__props){let props=__props,steps=inject(`wizardSteps`,ref([])),summaryItems=computed(()=>{let customItems=props.custom.map(item=>({stepId:uniqueId(),title:item.label,selectedLabel:item.value,hasSelection:!item.disabled}));if(props.replace)return customItems;let stepsList=steps.value||[],automaticItems=[];return Array.isArray(stepsList)&&(automaticItems=stepsList.filter(step=>step.type===`choice`&&step.choices&&step.choices.length>0).map(step=>{let selectedChoice=step.modelValue?.choice,choiceOption=step.choices.find(choice=>choice.value===selectedChoice);return{stepId:step.id,title:step.title,selectedLabel:choiceOption?.label||null,hasSelection:!!selectedChoice}}).filter(item=>item.hasSelection)),[...automaticItems,...customItems]});return(_ctx,_cache)=>summaryItems.value.length>0?(openBlock(),createElementBlock(`div`,_hoisted_1$267,[(openBlock(!0),createElementBlock(Fragment,null,renderList(summaryItems.value,item=>(openBlock(),createElementBlock(`div`,{key:item.stepId,class:`summary-item`},[createBaseVNode(`strong`,null,toDisplayString(_ctx.$tt(item.title))+`:`,1),createBaseVNode(`span`,{class:normalizeClass({enabled:item.hasSelection,disabled:!item.hasSelection})},toDisplayString(_ctx.$tt(item.selectedLabel||`ui.common.unknown`)),3)]))),128))])):createCommentVNode(``,!0)}},WizardSummary_default=__plugin_vue_export_helper_default(_sfc_main$298,[[`__scopeId`,`data-v-69c45791`]]),_hoisted_1$266={key:0,class:`wizard-step-container`},_hoisted_2$220={key:0,class:`step-description`},_hoisted_3$194=[`innerHTML`],_hoisted_4$166={class:`step-content`},_hoisted_5$143={key:0,class:`wizard-choice-step`},_hoisted_6$123={key:1,class:`wizard-form-step`},_hoisted_7$110={key:2,class:`wizard-confirmation-step`},_hoisted_8$93={key:3,class:`wizard-custom-step`},_hoisted_9$83={class:`custom-placeholder`},_sfc_main$297={__name:`WizardStep`,props:mergeModels({id:{type:String,required:!0},title:String,description:String,type:{type:String,default:`custom`,validator:value=>[`choice`,`form`,`confirmation`,`custom`].includes(value)},autoSkip:{type:Boolean,default:!0},advanceDisabled:{type:Boolean,default:!1},advanceDelay:{type:Number,default:300},required:{type:Boolean,default:!0},validator:{type:Function,default:null},enabledWhen:{type:Array,default:()=>[]},choices:{type:Array,default:()=>[]},component:{type:[String,Object],default:null},componentProps:{type:Object,default:()=>({})}},{modelValue:{default:()=>({})},modelModifiers:{}}),emits:[`update:modelValue`],setup(__props,{expose:__expose}){let props=__props,modelValue=useModel(__props,`modelValue`),registerStep=inject(`registerWizardStep`,null),unregisterStep=inject(`unregisterWizardStep`,null),currentStep=inject(`currentWizardStep`,null),slots=useSlots(),stepContext={stepId:props.id,stepType:props.type};provide(`wizardStepContext`,stepContext),__expose({stepId:props.id,stepContext});let isCurrentStep=computed(()=>currentStep?.value?.id===props.id);return onMounted(()=>{registerStep?.({id:props.id,title:props.title,description:props.description,type:props.type,autoSkip:props.autoSkip,get advanceDisabled(){return props.advanceDisabled},advanceDelay:props.advanceDelay,required:props.required,enabledWhen:props.enabledWhen,validate:props.validator,component:props.component,componentProps:props.componentProps,choices:props.choices,get modelValue(){return modelValue.value},updateModelValue:value=>{modelValue.value=value},hasDefaultSlot:!!slots.default,hasDescriptionSlot:!!slots.description})}),onUnmounted(()=>{unregisterStep?.(props.id)}),(_ctx,_cache)=>isCurrentStep.value?(openBlock(),createElementBlock(`div`,_hoisted_1$266,[__props.description||_ctx.$slots.description?(openBlock(),createElementBlock(`div`,_hoisted_2$220,[renderSlot(_ctx.$slots,`description`,{},()=>[__props.description?(openBlock(),createElementBlock(`div`,{key:0,innerHTML:__props.description},null,8,_hoisted_3$194)):createCommentVNode(``,!0)],!0)])):createCommentVNode(``,!0),createBaseVNode(`div`,_hoisted_4$166,[__props.type===`choice`?(openBlock(),createElementBlock(`div`,_hoisted_5$143,[renderSlot(_ctx.$slots,`default`,{},void 0,!0)])):__props.type===`form`?(openBlock(),createElementBlock(`div`,_hoisted_6$123,[renderSlot(_ctx.$slots,`default`,{},()=>[_cache[0]||=createBaseVNode(`div`,{class:`form-placeholder`},[createBaseVNode(`p`,null,`Add your form content here using BngInput, BngDropdown, etc.`),createBaseVNode(`p`,{class:`form-note`},`Use v-model bindings to connect to step data.`)],-1)],!0)])):__props.type===`confirmation`?(openBlock(),createElementBlock(`div`,_hoisted_7$110,[renderSlot(_ctx.$slots,`default`,{},()=>[createVNode(WizardSummary_default)],!0)])):(openBlock(),createElementBlock(`div`,_hoisted_8$93,[renderSlot(_ctx.$slots,`default`,{},()=>[createBaseVNode(`div`,_hoisted_9$83,[createBaseVNode(`p`,null,`Custom step content for: `+toDisplayString(__props.title),1),_cache[1]||=createBaseVNode(`p`,{class:`custom-note`},`Add your custom content in the WizardStep default slot`,-1)])],!0)]))])])):createCommentVNode(``,!0)}},WizardStep_default=__plugin_vue_export_helper_default(_sfc_main$297,[[`__scopeId`,`data-v-ede4abc3`]]),_hoisted_1$265={class:`description`},_hoisted_2$219={class:`image-section`},_hoisted_3$193={class:`image-row`},_hoisted_4$165=[`src`],_hoisted_5$142=[`src`],_sfc_main$296={__name:`ButtonLayoutView`,setup(__props){let settings$1=useSettings(),handleFinish=async()=>{await settings$1.apply({showedInputLayoutPopupV37:!0}),window.bngVue.gotoGameState(`menu.mainmenu`)},goToControls=async()=>{await settings$1.apply({showedInputLayoutPopupV37:!0}),window.bngVue.gotoGameState(`menu.options.controls.bindings`)};return onMounted(async()=>{await settings$1.waitForData()}),(_ctx,_cache)=>(openBlock(),createBlock(unref(WizardView_default),{title:`Input Changes`,class:`wizard-view`,"show-progress":!1,"finish-button-text":`ui.common.continue`,onWizardFinish:handleFinish},{default:withCtx(()=>[createVNode(unref(WizardStep_default),{id:`buttonLayout`,title:`Extended Modifier Buttons`,type:`confirmation`},{default:withCtx(()=>[withDirectives((openBlock(),createElementBlock(`div`,_hoisted_1$265,[_cache[1]||=createBaseVNode(`p`,null,` We updated the default button layout for Xbox and Playstation controllers using modifier buttons. Below you see the new default layout. `,-1),_cache[2]||=createBaseVNode(`p`,null,[createBaseVNode(`strong`,{class:`warning-text`},`If you made any changes to the default layout on Xbox or Playstation, we suggest you review your current layout and then either edit it or reset to the default if needed.`)],-1),createVNode(unref(bngButton_default),{accent:unref(ACCENTS).primary,onClick:goToControls},{default:withCtx(()=>[..._cache[0]||=[createTextVNode(` Go to Controls `,-1)]]),_:1},8,[`accent`])])),[[unref(BngUiNavScroll_default)]]),createBaseVNode(`div`,_hoisted_2$219,[_cache[3]||=createBaseVNode(`h4`,null,`New Button Layout`,-1),createBaseVNode(`div`,_hoisted_3$193,[createBaseVNode(`img`,{src:unref(getAssetURL)(`images/buttonLayout1.jpg`),alt:`Button Layout`,class:`button-layout-image`},null,8,_hoisted_4$165),createBaseVNode(`img`,{src:unref(getAssetURL)(`images/buttonLayout2.jpg`),alt:`Button Layout`,class:`button-layout-image`},null,8,_hoisted_5$142)])])]),_:1})]),_:1}))}},ButtonLayoutView_default=__plugin_vue_export_helper_default(_sfc_main$296,[[`__scopeId`,`data-v-ff98d0e0`]]),routes_default$2=[{path:`/buttonLayout`,name:`buttonLayout`,component:ButtonLayoutView_default,meta:{infoBar:{visible:!0,showSysInfo:!0},uiApps:{shown:!1}}}],_hoisted_1$264={class:`left`},_hoisted_2$218={class:`branch-icon-assembly`},_hoisted_3$192=[`innerHTML`],_hoisted_4$164=[`innerHTML`],_sfc_main$295={__name:`BranchSkillProgressBar`,props:{skill:Object,mode:{type:String,default:`long`,validator:value=>[`long`,`short`,`simple`,`with-value-label`].includes(value)},showLevel:{type:Boolean,default:!1},showLockedIcon:{type:Boolean,default:!1},isMainProgress:{type:Boolean,default:!1}},setup(__props){let props=__props,headerLeft=computed(()=>props.skill.name),headerRightLevelOrStars=computed(()=>props.skill.isInDevelopment?``:props.skill.unlocked?(props.showLevel&&props.skill.unlocked,props.skill.showProgressAsStars?$translate.contextTranslate({txt:`ui.career.slashStars`,context:{cur:props.skill.value,max:props.skill.max}}):props.skill.levelLabel?props.skill.levelLabel:props.skill.level?$translate.contextTranslate({txt:`ui.career.lvlLabel`,context:{lvl:props.skill.level}}):`Level ${props.skill.level}`):$translate.contextTranslate(`ui.career.locked`)),value=computed(()=>props.skill.max===-1?1:props.skill.value-props.skill.min),max$1=computed(()=>props.skill.max===-1?1:props.skill.max-props.skill.min),valueLabelFormat=computed(()=>{if(props.skill.isInDevelopment)return $translate.contextTranslate(`ui.career.inDevelopment`);if(!props.skill.unlocked)return $translate.contextTranslate(`ui.career.locked`);if(props.mode===`simple`)return props.skill.showProgressAsStars?$translate.contextTranslate({txt:`ui.career.slashStars`,context:{cur:value.value,max:max$1.value}}):$translate.contextTranslate({txt:`ui.career.lvlLabel`,context:{lvl:props.skill.level}});let unit=props.skill.showProgressAsStars?`Stars`:`XP`;return props.skill.max===-1?$translate.contextTranslate({txt:`ui.career.just`+unit,context:{cur:value.value}}):$translate.contextTranslate({txt:`ui.career.slashXP`,context:{cur:value.value,max:max$1.value}})}),skillIcon=computed(()=>props.skill.isInDevelopment?icons.roadblockL:props.skill.unlocked?props.skill.icon||`info`:`lockClosed`),belowValueLabelFormat=computed(()=>{if(!props.skill.unlocked&&props.skill.lockedReason)return $translate.contextTranslate(props.skill.lockedReason?.label||`ui.career.locked`);if(props.skill.isInDevelopment)return $translate.contextTranslate(`ui.career.inDevelopment`);if(props.skill.isMaxLevel)return`​`;if(!props.skill.showProgressAsStars)return $translate.contextTranslate({txt:`ui.career.justXP`,context:{cur:props.skill.value}})}),branchBackgroundStyle=computed(()=>{let color=props.skill.accentColor;return color?color.startsWith(`--`)?{"background-color":`var(${color})`}:color.startsWith(`#`)?{"background-color":color}:{"background-color":`rgb(${color})`}:{"background-color":`#555555`}});return(_ctx,_cache)=>__props.mode===`simple`?(openBlock(),createElementBlock(`div`,{key:0,class:normalizeClass([`simple-progress`,{"is-locked":!props.skill.unlocked}])},[createBaseVNode(`div`,_hoisted_1$264,[createBaseVNode(`div`,_hoisted_2$218,[!__props.skill.isSkill&&!__props.skill.isBranch?(openBlock(),createElementBlock(`div`,{key:0,class:`branch-background`,style:normalizeStyle(branchBackgroundStyle.value)},null,4)):createCommentVNode(``,!0),createVNode(unref(bngIcon_default),{type:skillIcon.value,class:`assembly-icon`},null,8,[`type`])]),createTextVNode(` `+toDisplayString(_ctx.$ctx_t(headerLeft.value)),1)]),createBaseVNode(`div`,{class:`right`,innerHTML:valueLabelFormat.value},null,8,_hoisted_3$192)],2)):(openBlock(),createElementBlock(`div`,{key:1,class:normalizeClass([`flex-column`,{"is-locked":!props.skill.unlocked}])},[createVNode(unref(bngProgressBar_default),{class:normalizeClass([`stat-progress-bar`,{short:__props.mode===`short`,isMainProgress:__props.isMainProgress}]),headerLeft:_ctx.$ctx_t(headerLeft.value),headerRight:_ctx.$ctx_t(headerRightLevelOrStars.value),value:value.value,max:max$1.value+.001,showValueLabel:!0,valueLabelFormat:``,valueColor:`#eeeeee`},null,8,[`class`,`headerLeft`,`headerRight`,`value`,`max`]),!props.skill.unlocked&&__props.mode===`with-value-label`&&props.showLockedIcon?(openBlock(),createElementBlock(Fragment,{key:0},[],64)):createCommentVNode(``,!0),__props.mode===`with-value-label`?(openBlock(),createElementBlock(`div`,{key:1,class:`below-progress-bar`,innerHTML:belowValueLabelFormat.value},null,8,_hoisted_4$164)):createCommentVNode(``,!0)],2))}},BranchSkillProgressBar_default=__plugin_vue_export_helper_default(_sfc_main$295,[[`__scopeId`,`data-v-2f641a65`]]);function hexToRgb(hex){hex=hex.replace(/^#/,``);let bigint=parseInt(hex,16);return`${bigint>>16&255}, ${bigint>>8&255}, ${bigint&255}`}function getBranchColorStyle({color,accentColor}){let style={};color&&(color.startsWith(`#`)?style[`--branch-color`]=hexToRgb(color):color.startsWith(`var(--`)&&(style[`--branch-color`]=color));let accent=accentColor||color;return accent&&(accent.startsWith(`#`)?style[`--branch-accent-color`]=hexToRgb(accent):accent.startsWith(`var(--`)&&(style[`--branch-accent-color`]=accent)),style}function getIconBackgroundStyle(color){return color?color.startsWith(`--`)?{"background-color":`var(${color})`}:color.startsWith(`#`)?{"background-color":color}:{"background-color":`rgb(${color})`}:{"background-color":`#555555`}}var _hoisted_1$263={class:`branch-details`},_hoisted_2$217={class:`backdrop`},_hoisted_3$191={class:`skill-levels-wrapper`},_hoisted_4$163={key:0,class:`branch-name-container`},_hoisted_5$141={key:2,class:`branch-footer`},_hoisted_6$122={key:0,class:`branch-description`},_hoisted_7$109={key:0,class:`branch-description`},_hoisted_8$92={class:`branch-footer-content`},_hoisted_9$82={class:`certification-text`},_hoisted_10$72={class:`status`},_hoisted_11$65={class:`unlock-info-row`},_hoisted_12$53={class:`icon-box`},_hoisted_13$46={class:`certification-text`},_sfc_main$294={__name:`BranchSkillCard`,props:{branchKey:String,displayMode:{type:String,default:`card`}},emits:[`openBranchPage`],setup(__props,{emit:__emit}){let props=__props,emit$1=__emit,branchData=ref();computed(()=>branchData.value&&`url(${getAssetURL(branchData.value.icon)})`);let branchColor=computed(()=>{let color=branchData.value&&branchData.value.color;return color?color.startsWith(`#`)?hexToRgb(color):color.startsWith(`var(--`)?`${color}`:`transparent`:``}),branchAccentColor=computed(()=>{let color=branchData.value&&(branchData.value.accentColor||branchData.value.color);return color?color.startsWith(`#`)?hexToRgb(color):color.startsWith(`var(--`)?`${color}`:`transparent`:``}),branchIconType=computed(()=>branchData.value&&branchData.value.isInDevelopment?icons.roadblockL:branchData.value&&branchData.value.unlocked?icons[branchData.value.glyphIcon]:icons.lockClosed),isHalf=computed(()=>{if(!branchData.value)return!1;let hasSkills=branchData.value.skills&&branchData.value.skills.length>0,hasDescription=branchData.value.shortDescription;return!hasSkills&&!hasDescription}),safeArray=arr=>Array.isArray(arr)?arr:[],openBranchPage=branchKey=>emit$1(`openBranchPage`,branchKey);function setup$3(data){branchData.value=data,branchData.value.skills=safeArray(data.skills)}let formatColor=color=>color?color.startsWith(`#`)?hexToRgb(color):color.startsWith(`var(--`)?`${color}`:`rgb(255, 255, 255)`:``;return onMounted(async()=>{setup$3(await Lua_default.career_modules_branches_landing.getBranchSkillCardData(props.branchKey))}),(_ctx,_cache)=>branchData.value?(openBlock(),createBlock(unref(bngCard_default),{key:0,class:normalizeClass([`branch-skill-card`,{"row-mode":__props.displayMode===`row`,locked:!branchData.value.unlocked,half:isHalf.value}]),onClick:_cache[0]||=$event=>openBranchPage(__props.branchKey),style:normalizeStyle({"--branch-color":branchColor.value,"--branch-accent-color":branchAccentColor.value})},{default:withCtx(()=>[createBaseVNode(`div`,_hoisted_1$263,[_cache[2]||=createBaseVNode(`div`,{class:`indicator left`},null,-1),_cache[3]||=createBaseVNode(`div`,{class:`indicator right`},null,-1),branchData.value.isDomain?createCommentVNode(``,!0):(openBlock(),createElementBlock(`div`,{key:0,class:normalizeClass([`branch-progress`,{"in-development":branchData.value.isInDevelopment}])},[branchData.value.isDomain?createCommentVNode(``,!0):(openBlock(),createElementBlock(`div`,{key:0,class:normalizeClass([`badge`,{"row-badge":__props.displayMode===`row`}])},[createBaseVNode(`div`,_hoisted_2$217,toDisplayString(branchData.value.value.color),1),createVNode(unref(bngIcon_default),{class:`icon-branch`,type:branchIconType.value},null,8,[`type`])],2))],2)),branchData.value.isDomain?(openBlock(),createBlock(unref(aspectRatio_default),{key:1,"external-image":branchData.value.cover,ratio:`16:9`,class:`image-container aspect-ratio`},null,8,[`external-image`])):createCommentVNode(``,!0),createBaseVNode(`div`,_hoisted_3$191,[__props.displayMode===`row`?(openBlock(),createElementBlock(`div`,_hoisted_4$163,[branchData.value?(openBlock(),createBlock(BranchSkillProgressBar_default,{key:0,class:`main-stat-progress-bar`,skill:branchData.value,showLevel:!0,mode:(branchData.value.isInDevelopment&&isHalf.value,``)},null,8,[`skill`,`mode`])):createCommentVNode(``,!0)])):createCommentVNode(``,!0)]),isHalf.value?createCommentVNode(``,!0):(openBlock(),createElementBlock(`div`,_hoisted_5$141,[branchData.value.isInDevelopment?(openBlock(),createElementBlock(`div`,_hoisted_6$122,toDisplayString(_ctx.$ctx_t(`ui.career.inDevelopment`)),1)):(openBlock(),createElementBlock(Fragment,{key:1},[branchData.value.shortDescription?(openBlock(),createElementBlock(`div`,_hoisted_7$109,toDisplayString(_ctx.$ctx_t(branchData.value.shortDescription)),1)):createCommentVNode(``,!0),createBaseVNode(`div`,_hoisted_8$92,[branchData.value.skills?(openBlock(!0),createElementBlock(Fragment,{key:0},renderList(branchData.value.skills,skill=>(openBlock(),createElementBlock(`div`,null,[branchData.value?(openBlock(),createBlock(BranchSkillProgressBar_default,{key:0,skill,mode:`simple`},null,8,[`skill`])):createCommentVNode(``,!0)]))),256)):createCommentVNode(``,!0),(openBlock(!0),createElementBlock(Fragment,null,renderList(branchData.value.certifications,certification=>(openBlock(),createElementBlock(`div`,{class:normalizeClass([`certification-container`,certification.status])},[createVNode(unref(bngIcon_default),{type:unref(icons).badgeRoundStar,style:normalizeStyle({color:certification.status===`completed`?`white`:certification.status===`available`?`rgba(255, 255, 255, 0.6)`:`rgba(255, 255, 255, 0.5)`})},null,8,[`type`,`style`]),createBaseVNode(`div`,_hoisted_9$82,[createTextVNode(toDisplayString(_ctx.$ctx_t(`ui.career.certification.name`))+` `,1),createBaseVNode(`span`,_hoisted_10$72,toDisplayString(_ctx.$ctx_t(certification.statusLabel)),1)])],2))),256)),branchData.value.unlockInfos?(openBlock(),createElementBlock(Fragment,{key:1},[_cache[1]||=createBaseVNode(`div`,{class:`unlock-info-title`},`Required Certifications:`,-1),createBaseVNode(`div`,_hoisted_11$65,[(openBlock(!0),createElementBlock(Fragment,null,renderList(branchData.value.unlockInfos,unlockInfo=>(openBlock(),createElementBlock(`div`,{class:normalizeClass([`unlock-info-item`,unlockInfo.status]),style:normalizeStyle({"--unlock-color":formatColor(unlockInfo.color?unlockInfo.color:`var(--bng-cool-gray-500-rgb)`)})},[createBaseVNode(`div`,_hoisted_12$53,[createVNode(unref(bngIcon_default),{type:unref(icons).badgeRoundStar,class:`certification-icon`},null,8,[`type`])]),createBaseVNode(`div`,_hoisted_13$46,toDisplayString(_ctx.$ctx_t(unlockInfo.label)),1)],6))),256))])],64)):createCommentVNode(``,!0)])],64))]))])]),_:1},8,[`class`,`style`])):createCommentVNode(``,!0)}},BranchSkillCard_default=__plugin_vue_export_helper_default(_sfc_main$294,[[`__scopeId`,`data-v-4321db2f`]]),_hoisted_1$262={class:`condensed`},_hoisted_2$216={key:3,class:`dev-icon-container`},_hoisted_3$190={class:`main-info`},_hoisted_4$162={key:1,class:`stars`},_sfc_main$293={__name:`MissionCard`,props:{mission:Object,isSkeleton:Boolean,showStartableIcons:Boolean},emits:[`clicked`],setup(__props,{emit:__emit}){let props=__props,emit$1=__emit,clicked=()=>emit$1(`clicked`,props.mission),backgroundImageStyle=computed(()=>({backgroundImage:`url(${props.mission.thumbnail})`,maskImage:`linear-gradient(to left, rgba(0, 0, 0, ${props.mission.startable?.75:.2}) 50%, rgba(0, 0, 0, 0.1) 100%)`,filter:props.mission.startable?`none`:`grayscale(100%)`})),iconType$1=computed(()=>props.isSkeleton?icons.medal:icons[props.mission.icon]||icons.medal),iconColor=computed(()=>props.isSkeleton||!props.mission.startable?`var(--bng-cool-gray-600)`:`#fff`),showStartableIcons=computed(()=>!props.isSkeleton&&props.showStartableIcons);return(_ctx,_cache)=>(openBlock(),createBlock(unref(bngCard_default),{"bng-nav-item":``,onClick:clicked,class:normalizeClass({"card-wrapper":!0,"click-startable":__props.mission&&__props.mission.startable})},{default:withCtx(()=>[createBaseVNode(`div`,_hoisted_1$262,[__props.isSkeleton?createCommentVNode(``,!0):(openBlock(),createBlock(unref(aspectRatio_default),{key:0,class:`image`,style:normalizeStyle(backgroundImageStyle.value)},null,8,[`style`])),!__props.isSkeleton&&!__props.mission.startable?(openBlock(),createBlock(unref(bngIcon_default),{key:1,class:`locked-icon`,type:unref(icons).lockClosed,color:iconColor.value},null,8,[`type`,`color`])):createCommentVNode(``,!0),!__props.isSkeleton&&showStartableIcons.value?(openBlock(),createElementBlock(Fragment,{key:2},[__props.mission.canStartFromProgressScreen&&__props.mission.startable?(openBlock(),createBlock(unref(bngIcon_default),{key:0,class:`locked-icon`,type:unref(icons).play,color:iconColor.value},null,8,[`type`,`color`])):createCommentVNode(``,!0),!__props.mission.canStartFromProgressScreen&&__props.mission.startable?(openBlock(),createBlock(unref(bngIcon_default),{key:1,class:`locked-icon`,type:unref(icons).mapPoint,color:iconColor.value},null,8,[`type`,`color`])):createCommentVNode(``,!0)],64)):createCommentVNode(``,!0),!__props.isSkeleton&&__props.mission.devMission?(openBlock(),createElementBlock(`div`,_hoisted_2$216,[createVNode(unref(bngIcon_default),{class:`dev-icon`,type:unref(icons).bug,color:`white`},null,8,[`type`]),_cache[0]||=createBaseVNode(`div`,{class:`dev-text`},` DEV MISSION `,-1)])):createCommentVNode(``,!0),_cache[1]||=createBaseVNode(`div`,{class:`highlight-marker`},null,-1),createVNode(unref(bngIcon_default),{class:`mission-icon`,type:iconType$1.value,color:iconColor.value},null,8,[`type`,`color`]),createVNode(unref(bngBinding_default),{class:`input-icon`,"ui-event":`ok`,controller:``}),createBaseVNode(`div`,_hoisted_3$190,[__props.isSkeleton?createCommentVNode(``,!0):(openBlock(),createElementBlock(`div`,{key:0,class:normalizeClass([`heading`,{locked:!__props.mission.startable}])},toDisplayString(_ctx.$tt(__props.mission.label)),3)),!__props.isSkeleton&&__props.mission.startable&&__props.mission.formattedProgress?(openBlock(),createElementBlock(`div`,_hoisted_4$162,[__props.mission.formattedProgress.unlockedStars&&__props.mission.formattedProgress.unlockedStars.totalDefaultStarCount?(openBlock(),createBlock(unref(bngMainStars_default),{key:0,individualStars:__props.mission.formattedProgress.unlockedStars.defaults,class:`main-stars`,scale:.6},null,8,[`individualStars`])):createCommentVNode(``,!0),__props.mission.formattedProgress.unlockedStars&&__props.mission.formattedProgress.unlockedStars.totalBonusStarCount>0?(openBlock(),createBlock(unref(bngMainStars_default),{key:1,individualStars:__props.mission.formattedProgress.unlockedStars.bonus,class:`bonus-stars`,scale:.6},null,8,[`individualStars`])):createCommentVNode(``,!0)])):createCommentVNode(``,!0)])])]),_:1},8,[`class`]))}},MissionCard_default=__plugin_vue_export_helper_default(_sfc_main$293,[[`__scopeId`,`data-v-52ea67db`]]),_hoisted_1$261={class:`rewards-pills-container`},_sfc_main$292={__name:`RewardPill`,props:{icon:String,attributeKey:String,rewardAmount:Number,highlight:Boolean,hideNumbers:Boolean,backgroundColor:{type:String,default:`rgba(var(--bng-cool-gray-900-rgb), 0.5)`}},setup(__props){return(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$261,[createBaseVNode(`div`,{class:`pill`,style:normalizeStyle({backgroundColor:__props.backgroundColor,filter:__props.highlight?`brightness(350%)`:``})},[createVNode(unref(bngUnit_default),mergeProps({[__props.icon?`beamXP`:__props.attributeKey]:__props.rewardAmount},{options:__props.hideNumbers?{formatter:x=>null}:null,iconType:__props.icon?unref(icons)[__props.icon]:null,formatter:__props.attributeKey}),null,16,[`options`,`iconType`,`formatter`])],4)]))}},RewardPill_default=__plugin_vue_export_helper_default(_sfc_main$292,[[`__scopeId`,`data-v-7719e2fc`]]),_hoisted_1$260={class:`rewards-pills-container`},_sfc_main$291={__name:`RewardsPills`,props:{rewards:Object,hideNumbers:Boolean,negativeBackground:{type:Boolean,default:!0}},setup(__props){return(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$260,[(openBlock(!0),createElementBlock(Fragment,null,renderList(__props.rewards,reward=>(openBlock(),createBlock(RewardPill_default,{icon:reward.icon,hideNumbers:__props.hideNumbers,attributeKey:reward.attributeKey,rewardAmount:reward.rewardAmount,highlight:reward.highlight,backgroundColor:__props.negativeBackground&&reward.rewardAmount<0?`rgba(var(--bng-add-red-700-rgb), 0.5)`:void 0},null,8,[`icon`,`hideNumbers`,`attributeKey`,`rewardAmount`,`highlight`,`backgroundColor`]))),256))]))}},RewardsPills_default=__plugin_vue_export_helper_default(_sfc_main$291,[[`__scopeId`,`data-v-40e5103d`]]),_hoisted_1$259={key:0,class:`animated-border claimable`},_hoisted_2$215={key:1,class:`complete`},_hoisted_3$189={key:0,class:`complete`},_hoisted_4$161={key:1,class:`complete-badge`},_hoisted_5$140={key:2,class:`step`},_hoisted_6$121={key:3,class:`step`},_hoisted_7$108={class:`content`},_hoisted_8$91={class:`heading`},_hoisted_9$81={key:0,class:`middle-content`},_hoisted_10$71={key:1,class:`middle-content`},_hoisted_11$64={key:3,class:`progress`},_sfc_main$290={__name:`MilestoneCard`,props:{milestone:Object,isCondensed:Boolean},emits:[`claim`],setup(__props,{emit:__emit}){let props=__props,emit$1=__emit,claimMilestone=()=>{console.log(`claimMilestone`,props.milestone),props.milestone.claimable&&(emit$1(`claim`,props.milestone),console.log(props.milestone))},milestoneColor=computed(()=>{let color=props.milestone.color;return color?color.startsWith(`#`)?hexToRgb$1(color):color.startsWith(`var(--`)?`${color}`:`transparent`:``});function hexToRgb$1(hex){return`${parseInt(hex.slice(1,3),16)}, ${parseInt(hex.slice(3,5),16)}, ${parseInt(hex.slice(5,7),16)}`}return(_ctx,_cache)=>withDirectives((openBlock(),createElementBlock(`div`,{"bng-nav-item":``,onClick:claimMilestone,class:`condensed`},[__props.milestone.claimable?(openBlock(),createElementBlock(`div`,_hoisted_1$259)):createCommentVNode(``,!0),__props.milestone.completed?(openBlock(),createElementBlock(`div`,_hoisted_2$215)):createCommentVNode(``,!0),createVNode(unref(aspectRatio_default),{class:`image`,style:normalizeStyle({backgroundColor:`rgb(`+milestoneColor.value+`)`}),ratio:`21:9`},{default:withCtx(()=>[__props.milestone.completed?(openBlock(),createElementBlock(`div`,_hoisted_3$189)):createCommentVNode(``,!0),__props.milestone.completed?(openBlock(),createElementBlock(`div`,_hoisted_4$161,[createVNode(unref(bngIcon_default),{class:`glyph small`,type:unref(icons).checkmark},null,8,[`type`])])):createCommentVNode(``,!0),createVNode(unref(bngIcon_default),{class:`glyph`,type:unref(icons)[__props.milestone.icon]},null,8,[`type`]),__props.milestone.step!==void 0&&__props.milestone.maxStep!==void 0?(openBlock(),createElementBlock(`div`,_hoisted_5$140,toDisplayString(__props.milestone.step)+`/`+toDisplayString(__props.milestone.maxStep),1)):createCommentVNode(``,!0),__props.milestone.step!==void 0&&__props.milestone.maxStep===void 0?(openBlock(),createElementBlock(`div`,_hoisted_6$121,toDisplayString(__props.milestone.step),1)):createCommentVNode(``,!0)]),_:1},8,[`style`]),createBaseVNode(`div`,_hoisted_7$108,[createBaseVNode(`div`,_hoisted_8$91,toDisplayString(_ctx.$ctx_t(__props.milestone.label)),1),__props.milestone.description?(openBlock(),createElementBlock(`div`,_hoisted_9$81,toDisplayString(_ctx.$ctx_t(__props.milestone.description)),1)):createCommentVNode(``,!0),__props.milestone.rewards?(openBlock(),createElementBlock(`div`,_hoisted_10$71,[createVNode(RewardsPills_default,{rewards:__props.milestone.rewards},null,8,[`rewards`])])):createCommentVNode(``,!0),__props.milestone.completed?(openBlock(),createBlock(unref(bngProgressBar_default),{key:2,value:1,max:1,min:0,valueLabelFormat:`Complete!`,class:`progress`})):createCommentVNode(``,!0),__props.milestone.progress?(openBlock(),createElementBlock(`div`,_hoisted_11$64,[(openBlock(!0),createElementBlock(Fragment,null,renderList(__props.milestone.progress,prog=>(openBlock(),createBlock(unref(bngProgressBar_default),{class:normalizeClass({claimProgressBar:__props.milestone.claimable}),value:prog.currValue,max:prog.maxValue,min:prog.minValue,valueLabelFormat:__props.milestone.claimable?`Click to claim!`:_ctx.$ctx_t(prog.label)},null,8,[`class`,`value`,`max`,`min`,`valueLabelFormat`]))),256))])):createCommentVNode(``,!0)])])),[[unref(BngOnUiNav_default),void 0,`ok`,{focusRequired:!0,asMouse:!0}]])}},MilestoneCard_default=__plugin_vue_export_helper_default(_sfc_main$290,[[`__scopeId`,`data-v-8fc3424a`]]),_hoisted_1$258={class:`progress-track`},_hoisted_2$214={key:0,class:`progress-fill`,style:{height:`100%`}},_hoisted_3$188={class:`header`},_hoisted_4$160={class:`name`},_hoisted_5$139={key:0,class:`stars`},_hoisted_6$120={key:1,class:`stars`},_hoisted_7$107={class:`info`},_hoisted_8$90={class:`unlock-condition`},_hoisted_9$80={class:`info`},_hoisted_10$70={class:`label`},_hoisted_11$63={class:`description`},_hoisted_12$52={key:0,class:`cards-container`},_hoisted_13$45={class:`basic-card locked coming-soon`},_hoisted_14$42={class:`label`},_hoisted_15$40={key:1,class:`right`},_sfc_main$289={__name:`LeagueRow`,props:{league:Object,leagueMissionClicked:Function,condensed:Boolean,vertical:Boolean,nowUnlocked:Boolean},setup(__props){let props=__props;function hexToRgb$1(hex){hex=hex.replace(/^#/,``);let bigint=parseInt(hex,16);return`${bigint>>16&255}, ${bigint>>8&255}, ${bigint&255}`}let leagueStyle=computed(()=>{if(!props.league.accentColor)return{};let style={};return props.league.accentColor.startsWith(`#`)?style[`--league-accent-color`]=hexToRgb$1(props.league.accentColor):props.league.accentColor.startsWith(`var(--`)&&(style[`--league-accent-color`]=props.league.accentColor),style});return(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,{class:normalizeClass([`league-row`,{locked:!__props.league._unlocked,condensed:__props.condensed}]),style:normalizeStyle(leagueStyle.value)},[createBaseVNode(`div`,_hoisted_1$258,[__props.league._unlocked?(openBlock(),createElementBlock(`div`,_hoisted_2$214)):createCommentVNode(``,!0)]),createBaseVNode(`div`,_hoisted_3$188,[createBaseVNode(`div`,_hoisted_4$160,[createVNode(unref(bngIcon_default),{type:unref(icons)[__props.league.icon],class:`skill-icon`,color:__props.league._unlocked?`white`:`gray`},null,8,[`type`,`color`]),createTextVNode(` `+toDisplayString(_ctx.$ctx_t(__props.league.name)),1)]),__props.nowUnlocked?(openBlock(),createElementBlock(`div`,_hoisted_6$120,[createVNode(unref(bngIcon_default),{type:unref(icons).lockOpened},null,8,[`type`])])):(openBlock(),createElementBlock(`div`,_hoisted_5$139,[__props.league._unlocked?(openBlock(),createBlock(unref(bngMainStars_default),{key:0,"unlocked-stars":__props.league.totalStarsObtained,"total-stars":__props.league.totalStarsAvailable,class:`main-stars`,scale:.8,reverse:``,numerical:``},null,8,[`unlocked-stars`,`total-stars`])):createCommentVNode(``,!0)]))]),createBaseVNode(`div`,{class:normalizeClass([`content-row`,{vertical:__props.vertical}])},[createBaseVNode(`div`,_hoisted_7$107,[(openBlock(!0),createElementBlock(Fragment,null,renderList(__props.league.unlock,cond=>(openBlock(),createElementBlock(Fragment,null,[cond.hidden?createCommentVNode(``,!0):(openBlock(),createBlock(unref(bngCard_default),{key:0},{default:withCtx(()=>[createBaseVNode(`div`,_hoisted_8$90,[createBaseVNode(`div`,_hoisted_9$80,[createVNode(unref(bngIcon_default),{class:`icon`,type:cond.met?unref(icons).lockOpened:unref(icons).lockClosed,color:cond.met?`white`:`gray`},null,8,[`type`,`color`]),createBaseVNode(`div`,_hoisted_10$70,toDisplayString(cond.label),1)]),cond.progress?(openBlock(),createBlock(unref(bngProgressBar_default),{key:0,value:cond.progress.cur,min:cond.progress.min,max:cond.progress.max,valueLabelFormat:``,class:`progress`},null,8,[`value`,`min`,`max`])):createCommentVNode(``,!0)])]),_:2},1024))],64))),256)),createBaseVNode(`div`,_hoisted_11$63,toDisplayString(_ctx.$ctx_t(__props.league.description)),1)]),__props.condensed?(openBlock(),createElementBlock(`div`,_hoisted_15$40,toDisplayString(__props.league.missions.length)+` Challenges `,1)):(openBlock(),createElementBlock(`div`,_hoisted_12$52,[(openBlock(!0),createElementBlock(Fragment,null,renderList(__props.league.missions,mission=>(openBlock(),createBlock(MissionCard_default,{class:`clickable-card`,key:mission.id,mission,onClicked:__props.leagueMissionClicked,showStartableIcons:!0},null,8,[`mission`,`onClicked`]))),128)),(openBlock(!0),createElementBlock(Fragment,null,renderList(__props.league.driftSpots,driftSpot=>(openBlock(),createBlock(MissionCard_default,{class:`clickable-card`,key:driftSpot.id,mission:driftSpot,onClicked:__props.leagueMissionClicked},null,8,[`mission`,`onClicked`]))),128)),__props.league.comingSoon?(openBlock(!0),createElementBlock(Fragment,{key:0},renderList(__props.league.comingSoon,info=>(openBlock(),createBlock(unref(bngCard_default),{class:`card-height`},{default:withCtx(()=>[createBaseVNode(`div`,_hoisted_13$45,[createVNode(unref(bngIcon_default),{class:`icon`,type:unref(icons)[info.icon],color:`gray`},null,8,[`type`]),createBaseVNode(`div`,_hoisted_14$42,toDisplayString(info.label),1)])]),_:2},1024))),256)):createCommentVNode(``,!0)]))],2)],6))}},LeagueRow_default=__plugin_vue_export_helper_default(_sfc_main$289,[[`__scopeId`,`data-v-f92a650f`]]),_hoisted_1$257={class:`label`},_hoisted_2$213={class:`text`},_hoisted_3$187={class:`description`},_sfc_main$288={__name:`TaskGoal`,props:{label:[String,Object],description:[String,Object],complete:Boolean,success:Boolean,settings:{type:Object,default:{animate:!1,animateOnMount:!1,successCallback:Function}}},setup(__props){let props=__props,slots=useSlots(),animationSettings=inject(`animationSettings`,props.settings),animate=ref(!1),labelParsed=computed(()=>parse$1($translate.contextTranslate(props.label,!0))),descriptionParsed=computed(()=>parse$1($translate.contextTranslate(props.description,!0))),checkboxSvgs=computed(()=>({"--checkbox-empty":`url(${getAssetURL(`icons/general/checkbox-empty.svg`)})`,"--checkbox-ok":`url(${getAssetURL(`icons/general/checkbox-ok.svg`)})`,"--checkbox-nope":`url(${getAssetURL(`icons/general/checkbox-nope.svg`)})`}));return watch(()=>[props.complete,props.success],(newValues,oldValues)=>{let isComplete=newValues[0],isSuccess=newValues[1];animate.value=animationSettings.animate&&isComplete,isSuccess&&animationSettings.successCallback()}),onBeforeMount(()=>{animate.value=props.settings.animate&&props.settings.animateOnMount}),(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,{class:normalizeClass([`task-goal`,{success:__props.complete&&__props.success,fail:__props.complete&&!__props.success,animate:animate.value}])},[createBaseVNode(`div`,_hoisted_1$257,[createBaseVNode(`span`,{class:`checkbox`,style:normalizeStyle(checkboxSvgs.value)},null,4),createBaseVNode(`span`,_hoisted_2$213,[unref(slots).label?renderSlot(_ctx.$slots,`label`,{key:0},void 0,!0):__props.label?(openBlock(),createBlock(unref(dynamicComponent_default),{key:1,template:labelParsed.value},null,8,[`template`])):createCommentVNode(``,!0)])]),createBaseVNode(`span`,_hoisted_3$187,[unref(slots).description?renderSlot(_ctx.$slots,`description`,{key:0},void 0,!0):__props.description?(openBlock(),createBlock(unref(dynamicComponent_default),{key:1,template:descriptionParsed.value},null,8,[`template`])):createCommentVNode(``,!0)])],2))}},TaskGoal_default=__plugin_vue_export_helper_default(_sfc_main$288,[[`__scopeId`,`data-v-5a381682`]]),_hoisted_1$256={key:0,class:`wrapper`},_hoisted_2$212={class:`heading`},_hoisted_3$186={class:`description`},_hoisted_4$159={key:1,class:`tasklist wrapper`},_hoisted_5$138={class:`task-content`},_hoisted_6$119={class:`heading`},_hoisted_7$106={class:`description`},_sfc_main$287={__name:`UnlockCard`,props:{data:Object},setup(__props){return(_ctx,_cache)=>(openBlock(),createElementBlock(Fragment,null,[__props.data.type==`tasklist`?createCommentVNode(``,!0):(openBlock(),createElementBlock(`div`,_hoisted_1$256,[createVNode(unref(bngIcon_default),{class:`icon`,type:unref(icons)[__props.data.icon]},null,8,[`type`]),createBaseVNode(`div`,_hoisted_2$212,toDisplayString(__props.data.heading),1),createBaseVNode(`div`,_hoisted_3$186,toDisplayString(__props.data.description),1)])),__props.data.type==`tasklist`?(openBlock(),createElementBlock(`div`,_hoisted_4$159,[(openBlock(!0),createElementBlock(Fragment,null,renderList(__props.data.tasklistData.tasks,task=>(openBlock(),createElementBlock(`div`,{class:`task`,key:task.label},[createVNode(unref(bngIcon_default),{class:`icon`,type:unref(icons)[task.done?`checkboxOn`:`checkboxOff`]},null,8,[`type`]),createBaseVNode(`div`,_hoisted_5$138,[createBaseVNode(`div`,_hoisted_6$119,toDisplayString(task.label),1),createBaseVNode(`div`,_hoisted_7$106,toDisplayString(task.description),1)])]))),128))])):createCommentVNode(``,!0)],64))}},UnlockCard_default=__plugin_vue_export_helper_default(_sfc_main$287,[[`__scopeId`,`data-v-c5fa6ca1`]]),_hoisted_1$255={class:`unlock-rows`},_hoisted_2$211={class:`rows-container`},_hoisted_3$185={class:`progress-track`},_hoisted_4$158={key:0,class:`progress-fill`,style:{height:`100%`}},_hoisted_5$137={class:`header`},_hoisted_6$118={class:`level-name-and-heading`},_hoisted_7$105={class:`level-label`},_hoisted_8$89={key:0,class:`description-heading`},_hoisted_9$79={class:`content-row`},_hoisted_10$69={class:`description-column`},_hoisted_11$62={class:`unlock-condition`},_hoisted_12$51={class:`info`},_hoisted_13$44={class:`label`},_hoisted_14$41={key:1,class:`description-text`},_hoisted_15$39={class:`unlocks-column`},_hoisted_16$38={key:0,class:`unlocks-list`},_sfc_main$286={__name:`UnlockRows`,props:{value:{type:Number,default:0},min:{type:Number,default:0},max:{type:Number,required:!0},maxRequiredValue:{type:Number,required:!1},tiers:Array,currentTier:Number,unlocked:Boolean,progressFillColor:{type:String,default:`#ff6600`}},setup(__props){useCssVars(_ctx=>({v1b3c87f1:props.progressFillColor.startsWith(`var(--`)&&props.progressFillColor.endsWith(`-rgb)`)?`rgb(${props.progressFillColor})`:props.progressFillColor}));let props=__props;function hexToRgb$1(hex){hex=hex.replace(/^#/,``);let bigint=parseInt(hex,16);return`${bigint>>16&255}, ${bigint>>8&255}, ${bigint&255}`}let progressStyle=computed(()=>{if(!props.progressFillColor)return{};let style={};return props.progressFillColor.startsWith(`#`)?style[`--progress-fill-color`]=hexToRgb$1(props.progressFillColor):props.progressFillColor.startsWith(`var(--`)&&(style[`--progress-fill-color`]=props.progressFillColor),style});return(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$255,[createBaseVNode(`div`,_hoisted_2$211,[(openBlock(!0),createElementBlock(Fragment,null,renderList(__props.tiers,(tier,idx)=>(openBlock(),createElementBlock(`div`,{key:tier.index,class:normalizeClass({"tier-row":!0,"grayed-out":__props.currentTier<=tier.index-1,completed:__props.currentTier+1>tier.index,"in-development":tier.isInDevelopment,"first-tier":idx===0,"last-tier":idx===__props.tiers.length-1})},[createBaseVNode(`div`,_hoisted_3$185,[__props.currentTier+1>tier.index?(openBlock(),createElementBlock(`div`,_hoisted_4$158)):createCommentVNode(``,!0)]),createBaseVNode(`div`,_hoisted_5$137,[createBaseVNode(`div`,_hoisted_6$118,[createBaseVNode(`span`,_hoisted_7$105,`Level `+toDisplayString(tier.label?tier.label:tier.index),1),tier.description&&tier.description.heading?(openBlock(),createElementBlock(`span`,_hoisted_8$89,`: `+toDisplayString(tier.description.heading),1)):createCommentVNode(``,!0)])]),createBaseVNode(`div`,_hoisted_9$79,[createBaseVNode(`div`,_hoisted_10$69,[tier.isInDevelopment||__props.currentTier+1<=tier.index||!__props.unlocked?(openBlock(),createBlock(unref(bngCard_default),{key:0,class:`unlock-condition-card`,style:normalizeStyle(progressStyle.value)},{default:withCtx(()=>[createBaseVNode(`div`,_hoisted_11$62,[createBaseVNode(`div`,_hoisted_12$51,[createVNode(unref(bngIcon_default),{class:`icon`,type:tier.isInDevelopment?unref(icons).roadblockL:unref(icons).lockClosed,color:`gray`},null,8,[`type`]),createBaseVNode(`div`,_hoisted_13$44,[tier.isInDevelopment?(openBlock(),createElementBlock(Fragment,{key:0},[createTextVNode(` Coming Soon! `)],64)):(openBlock(),createElementBlock(Fragment,{key:1},[createTextVNode(toDisplayString(tier.xpCurrent)+` / `+toDisplayString(tier.xpRequired)+` XP `,1)],64))])]),!tier.isInDevelopment&&tier.currentValue&&tier.requiredValue?(openBlock(),createBlock(unref(bngProgressBar_default),{key:0,value:tier.xpCurrent,min:0,max:tier.xpRequired,valueLabelFormat:``,class:`progress`},null,8,[`value`,`max`])):createCommentVNode(``,!0)])]),_:2},1032,[`style`])):createCommentVNode(``,!0),tier.description&&tier.description.description?(openBlock(),createElementBlock(`div`,_hoisted_14$41,toDisplayString(tier.description.description),1)):createCommentVNode(``,!0)]),createBaseVNode(`div`,_hoisted_15$39,[tier.list&&tier.list.length>0?(openBlock(),createElementBlock(`div`,_hoisted_16$38,[(openBlock(!0),createElementBlock(Fragment,null,renderList(tier.list,(item,idx$1)=>(openBlock(),createBlock(UnlockCard_default,{key:idx$1,class:`unlock-item`,data:item},null,8,[`data`]))),128))])):createCommentVNode(``,!0)])])],2))),128))])]))}},UnlockRows_default=__plugin_vue_export_helper_default(_sfc_main$286,[[`__scopeId`,`data-v-ec31f890`]]),_hoisted_1$254={class:`flex-row`},_hoisted_2$210={class:`player-content`},_hoisted_3$184={class:`stats-row`},_hoisted_4$157={class:`stat-content`},_sfc_main$285={__name:`careerSimpleStats`,setup(__props,{expose:__expose}){let careerStatsData=ref({}),handleCareerSimpleStats=data=>{data.branches.forEach(entry=>{entry.hasOwnProperty(`levelLabel`)&&(entry.name=$translate.contextTranslate(entry.name,!0),entry.levelLabel=$translate.contextTranslate(entry.levelLabel,!0))}),careerStatsData.value=data},updateDisplay=()=>{Lua_default.career_modules_uiUtils.getCareerSimpleStats().then(handleCareerSimpleStats)};return onMounted(()=>{updateDisplay()}),__expose({updateDisplay}),(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$254,[createBaseVNode(`div`,_hoisted_2$210,toDisplayString(careerStatsData.value.saveSlotName),1),createBaseVNode(`div`,_hoisted_3$184,[(openBlock(!0),createElementBlock(Fragment,null,renderList(careerStatsData.value.branches,branch=>(openBlock(),createElementBlock(`div`,_hoisted_4$157,[createVNode(unref(bngProgressBar_default),{class:`stat-progress-bar`,headerLeft:branch.name,headerRight:branch.levelLabel,min:branch.min,value:branch.value,max:branch.max},null,8,[`headerLeft`,`headerRight`,`min`,`value`,`max`])]))),256))])]))}},careerSimpleStats_default=__plugin_vue_export_helper_default(_sfc_main$285,[[`__scopeId`,`data-v-94a9390d`]]),_sfc_main$284={__name:`careerStatus`,props:{slim:{type:Boolean,default:!1}},setup(__props,{expose:__expose}){let careerStatusData=ref({}),handleCareerStatusData=data=>careerStatusData.value=data,updateDisplay=()=>Lua_default.career_modules_uiUtils.getCareerStatusData().then(handleCareerStatusData);return onMounted(updateDisplay),__expose({updateDisplay}),(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,null,[createBaseVNode(`div`,{class:normalizeClass([`career-status-progress`,{slim:__props.slim}])},[createVNode(unref(bngUnit_default),{class:`career-status-value`,insuranceScore:careerStatusData.value.insuranceScore},null,8,[`insuranceScore`]),createVNode(unref(bngDivider_default)),createVNode(unref(bngUnit_default),{class:`career-status-value`,vouchers:careerStatusData.value.vouchers},null,8,[`vouchers`]),createVNode(unref(bngDivider_default)),createVNode(unref(bngUnit_default),{class:`career-status-value`,money:careerStatusData.value.money},null,8,[`money`])],2)]))}},careerStatus_default=__plugin_vue_export_helper_default(_sfc_main$284,[[`__scopeId`,`data-v-0446c53b`]]),_hoisted_1$253={key:0},_sfc_main$283={__name:`TutorialButton`,props:{text:{type:String,default:``},icon:{type:Object,default:()=>icons.questionmark},pages:{type:Object,default:[]}},setup(__props){let props=__props,buttonRef=ref(null),seen$3=ref(!0);function clickHandler(){for(let key of props.pages)Lua_default.career_modules_linearTutorial.introPopup(key,!0);seen$3.value=!0}return onMounted(()=>{}),onUnmounted(()=>{}),(_ctx,_cache)=>withDirectives((openBlock(),createBlock(unref(bngButton_default),{ref_key:`buttonRef`,ref:buttonRef,class:normalizeClass([`tut-btn`,{blink:!seen$3.value}]),icon:__props.icon,onClick:withModifiers(clickHandler,[`stop`])},{default:withCtx(()=>[__props.text?(openBlock(),createElementBlock(`span`,_hoisted_1$253,toDisplayString(__props.text),1)):createCommentVNode(``,!0)]),_:1},8,[`icon`,`class`])),[[unref(BngTooltip_default),__props.text?void 0:`View tutorial for this section`]])}},TutorialButton_default=__plugin_vue_export_helper_default(_sfc_main$283,[[`__scopeId`,`data-v-3e539b42`]]),_hoisted_1$252={class:`content`},_hoisted_2$209={class:`insurance-perks-div`},_hoisted_3$183={key:0,class:`leaving-insurance-wrapper`},_hoisted_4$156={class:`breakdown-items-wrapper`},_hoisted_5$136={class:`breakdown-item`},_hoisted_6$117={class:`orange-price`},_hoisted_7$104={class:`breakdown-item`},_hoisted_8$88={class:`red-price`},_hoisted_9$78={class:`breakdown-item total`},_hoisted_10$68={class:`breakdown-item-value-total green-price`},_hoisted_11$61={key:1,class:`no-insurance-wrapper`},_hoisted_12$50={key:2,class:`group-discount-wrapper`},_hoisted_13$43={class:`group-discount-icon-wrapper`},_hoisted_14$40={class:`group-discount-main-text`},_hoisted_15$38={class:`tier-text`},_hoisted_16$37={class:`tier-text`},_hoisted_17$31={class:`discount-text`},_hoisted_18$28={class:`grey-small-text`},_hoisted_19$24={key:3,class:`price-details-wrapper`},_hoisted_20$20={class:`price-tile`},_hoisted_21$18={key:0,class:`old-price-wrapper`},_hoisted_22$16={class:`old-price`},_hoisted_23$15={class:`price-tile-value-wrapper`},_hoisted_24$14={key:1,class:`deductible-discount`},_hoisted_25$13={class:`price-tile`},_hoisted_26$11={class:`price-tile-title`},_hoisted_27$11={class:`price-tile-value-wrapper`},_hoisted_28$10={class:`premium-extra-info`},_hoisted_29$10={class:`renewal-distance`},_sfc_main$282={__name:`insuranceCard`,props:{insuranceData:Object,isSelected:Boolean,isCurrentProvider:{type:Boolean,default:!1}},emits:[`select`],setup(__props,{emit:__emit}){let props=__props,{units}=useBridge(),emit$1=__emit,hasNoInsurance=computed(()=>props.insuranceData?.id===-1),pillText=computed(()=>{if(props.isCurrentProvider)return`CURRENT PROVIDER`;if(props.insuranceData.groupDiscountData){if(props.insuranceData.groupDiscountData?.willHaveGroupDiscountForTheFirstTime)return`MULTI-VEHICLE DISCOUNT AVAILABLE`;if(props.insuranceData.groupDiscountData?.willBumpTheirDiscount)return`BIGGER DISCOUNT AVAILABLE`;if(props.insuranceData.groupDiscountData?.currentTierData&&props.insuranceData.groupDiscountData?.currentTierData.id>0)return`MULTI-VEHICLE DISCOUNT ACTIVE`}return null}),renewsInFormatted=computed(()=>props.insuranceData?.renewsIn?units.buildString(`length`,props.insuranceData.renewsIn*1e3,0):``),leavingInsuranceRenewsInFormatted=computed(()=>props.insuranceData?.leavingInsuranceInfo?.renewsIn?units.buildString(`length`,props.insuranceData.leavingInsuranceInfo.renewsIn*1e3,0):``),selectCard=()=>{emit$1(`select`,props.insuranceData.id)},cardStyles=computed(()=>{let styles={};return!hasNoInsurance.value&&props.insuranceData.color&&(styles[`--insurance-card-rgb`]=hexToRgb(props.insuranceData.color)),styles});return(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,{class:normalizeClass([`insurance-card-container`,{selected:__props.isSelected,"no-insurance-card":hasNoInsurance.value,"current-provider":__props.isCurrentProvider}]),style:normalizeStyle(cardStyles.value),onClick:selectCard,"bng-nav-item":``},[pillText.value===null?createCommentVNode(``,!0):(openBlock(),createElementBlock(`div`,{key:0,class:normalizeClass([`top-pill`,{"no-insurance":hasNoInsurance.value,"orange-pill":__props.insuranceData.groupDiscountData?.willHaveGroupDiscountForTheFirstTime,"current-provider-pill":__props.isCurrentProvider}])},[createBaseVNode(`div`,null,toDisplayString(pillText.value),1)],2)),createBaseVNode(`div`,_hoisted_1$252,[createVNode(unref(insuranceIdentity_default),{class:`insurance-identity`,insuranceData:__props.insuranceData},null,8,[`insuranceData`]),_cache[13]||=createBaseVNode(`div`,{class:`separator`},null,-1),createBaseVNode(`div`,_hoisted_2$209,[hasNoInsurance.value?(openBlock(),createElementBlock(`div`,{key:0,class:normalizeClass([`perks-header`,{"no-insurance":hasNoInsurance.value}])},toDisplayString(hasNoInsurance.value?`Consequences`:`Included Benefits`),3)):createCommentVNode(``,!0),createVNode(unref(insurancePerks_default),{insuranceData:__props.insuranceData},null,8,[`insuranceData`])]),_cache[14]||=createBaseVNode(`div`,{class:`separator`},null,-1),hasNoInsurance.value&&__props.insuranceData.leavingInsuranceInfo&&!__props.isCurrentProvider?(openBlock(),createElementBlock(`div`,_hoisted_3$183,[_cache[4]||=createBaseVNode(`div`,{class:`leaving-insurance-title`},`Cancellation Refund`,-1),createBaseVNode(`div`,_hoisted_4$156,[createBaseVNode(`div`,_hoisted_5$136,[createBaseVNode(`span`,null,` Unused coverage (`+toDisplayString(leavingInsuranceRenewsInFormatted.value)+`) `,1),createBaseVNode(`span`,_hoisted_6$117,[_cache[0]||=createTextVNode(` + `,-1),createVNode(unref(bngUnit_default),{money:__props.insuranceData.leavingInsuranceInfo.coverageRefundPrice},null,8,[`money`])])]),createBaseVNode(`div`,_hoisted_7$104,[_cache[2]||=createBaseVNode(`span`,null,` Early Cancellation Fee (25%) `,-1),createBaseVNode(`span`,_hoisted_8$88,[_cache[1]||=createTextVNode(` - `,-1),createVNode(unref(bngUnit_default),{money:__props.insuranceData.leavingInsuranceInfo.earlyTerminationPenalty},null,8,[`money`])])]),createBaseVNode(`div`,_hoisted_9$78,[_cache[3]||=createBaseVNode(`span`,{class:`breakdown-item-label-total`},` You'll receive `,-1),createBaseVNode(`span`,_hoisted_10$68,[createVNode(unref(bngUnit_default),{money:__props.insuranceData.leavingInsuranceInfo.netRefundPrice},null,8,[`money`])])])])])):createCommentVNode(``,!0),hasNoInsurance.value?(openBlock(),createElementBlock(`div`,_hoisted_11$61,[..._cache[5]||=[createBaseVNode(`span`,{class:`no-insurance-warning`},` You will pay full repair costs `,-1),createBaseVNode(`span`,null,` No coverage or benefits included `,-1)]])):createCommentVNode(``,!0),!hasNoInsurance.value&&__props.insuranceData.groupDiscountData?.mainText?(openBlock(),createElementBlock(`div`,_hoisted_12$50,[createBaseVNode(`div`,null,[createBaseVNode(`span`,_hoisted_13$43,[createVNode(unref(bngIcon_default),{type:unref(icons).checkmark},null,8,[`type`])]),createBaseVNode(`span`,_hoisted_14$40,toDisplayString(__props.insuranceData.groupDiscountData?.mainText),1)]),createBaseVNode(`div`,null,[_cache[7]||=createBaseVNode(`span`,{class:`grey-small-text`},` Currently Insured : `,-1),createBaseVNode(`span`,null,[createVNode(unref(bngIcon_default),{class:`vehicles-icon`,type:unref(icons).car},null,8,[`type`])]),createBaseVNode(`span`,_hoisted_15$38,toDisplayString(__props.insuranceData.carsInsuredCount),1),__props.insuranceData.groupDiscountData?.currentTierData?.id>0?(openBlock(),createElementBlock(Fragment,{key:0},[_cache[6]||=createBaseVNode(`span`,{class:`vertical-separator`},` | `,-1),createBaseVNode(`span`,_hoisted_16$37,` Tier `+toDisplayString(__props.insuranceData.groupDiscountData?.currentTierData?.id),1),createBaseVNode(`span`,_hoisted_17$31,` - `+toDisplayString(__props.insuranceData.groupDiscountData?.currentTierData?.discount*100)+`% off `,1)],64)):createCommentVNode(``,!0)]),createBaseVNode(`div`,_hoisted_18$28,toDisplayString(__props.insuranceData.groupDiscountData?.secondaryText),1)])):createCommentVNode(``,!0),hasNoInsurance.value?createCommentVNode(``,!0):(openBlock(),createElementBlock(`div`,_hoisted_19$24,[createBaseVNode(`div`,_hoisted_20$20,[_cache[9]||=createBaseVNode(`span`,{class:`price-tile-title`},`Deductible`,-1),__props.insuranceData.baseDeductibledData?.oldPrice?(openBlock(),createElementBlock(`div`,_hoisted_21$18,[createBaseVNode(`div`,_hoisted_22$16,[createVNode(unref(bngUnit_default),{money:__props.insuranceData.baseDeductibledData.oldPrice},null,8,[`money`]),_cache[8]||=createBaseVNode(`div`,{class:`strike`},null,-1)])])):createCommentVNode(``,!0),createBaseVNode(`div`,_hoisted_23$15,[createVNode(unref(bngUnit_default),{money:__props.insuranceData.baseDeductibledData.price,class:normalizeClass(__props.insuranceData.baseDeductibledData.oldPrice?`green-price`:`orange-price`)},null,8,[`money`,`class`])]),_cache[10]||=createBaseVNode(`div`,{class:`deductible-tips`},[createBaseVNode(`div`,null,` - You pay your deductible for each crash repair `),createBaseVNode(`div`,null,` - Customize this value after purchase `)],-1),__props.insuranceData.baseDeductibledData.perkData?(openBlock(),createElementBlock(`div`,_hoisted_24$14,toDisplayString(__props.insuranceData.baseDeductibledData.perkData.discount*100)+`% discount applied `,1)):createCommentVNode(``,!0)]),createBaseVNode(`div`,_hoisted_25$13,[createBaseVNode(`span`,_hoisted_26$11,toDisplayString(__props.insuranceData.amountDue>0?`Amount Due`:`Credit Received`),1),createBaseVNode(`div`,_hoisted_27$11,[createVNode(unref(bngUnit_default),{money:Math.abs(__props.insuranceData.amountDue),class:`green-price`},null,8,[`money`])]),createBaseVNode(`div`,_hoisted_28$10,[createBaseVNode(`div`,null,[_cache[11]||=createTextVNode(` Total policy : `,-1),createVNode(unref(bngUnit_default),{money:__props.insuranceData.futurePremiumDetails.totalPriceWithDriverScore},null,8,[`money`])]),createBaseVNode(`div`,null,[_cache[12]||=createBaseVNode(`span`,null,`Renews in : `,-1),createBaseVNode(`span`,_hoisted_29$10,toDisplayString(renewsInFormatted.value),1)])])])]))]),createBaseVNode(`div`,{class:normalizeClass([`background`,{"no-insurance":hasNoInsurance.value}])},null,2)],6))}},insuranceCard_default=__plugin_vue_export_helper_default(_sfc_main$282,[[`__scopeId`,`data-v-e481fbef`]]),_hoisted_1$251={class:`premium-wrapper`},_hoisted_2$208={class:`breakdown-item`},_hoisted_3$182={class:`breakdown-item-value`},_hoisted_4$155={class:`premium-value-wrapper`},_hoisted_5$135={class:`breakdown-item`},_hoisted_6$116={class:`breakdown-item-value`},_hoisted_7$103={class:`breakdown-item`},_hoisted_8$87={class:`breakdown-item-value`},_hoisted_9$77={class:`breakdown-item`},_hoisted_10$67={class:`breakdown-item-value orange-text`},_hoisted_11$60={class:`perks`},_hoisted_12$49={key:0,class:`grey-text`},_hoisted_13$42={key:1,class:`grey-text`},_hoisted_14$39={class:`group-discount-savings`},_hoisted_15$37={class:`breakdown-item`},_hoisted_16$36={key:0,class:`grey-text`},_hoisted_17$30={key:1,class:`grey-text`},_hoisted_18$27={class:`buttons`},_sfc_main$281={__name:`smallInsuranceCard`,props:{insuranceData:{type:Object,required:!0},driverScoreData:{type:Object,required:!0}},setup(__props){let{units}=useBridge(),props=__props,renewsEveryFormatted=computed(()=>units.buildString(`length`,props.insuranceData.renewsEvery*1e3,0)),renewsInFormatted=computed(()=>units.buildString(`length`,props.insuranceData.renewsIn*1e3,0)),buttonsDisabled=computed(()=>props.insuranceData.carsInsuredCount===0),openVehicleList=()=>{addPopup(vehicleInsuranceList_default,{insuranceData:props.insuranceData,driverScoreData:props.driverScoreData})},openEditPolicy=()=>{addPopup(editPolicy_default,{insuranceData:props.insuranceData,driverScoreData:props.driverScoreData})},tierToDisplay=computed(()=>props.insuranceData.groupDiscountData.currentTierData.id>0?props.insuranceData.groupDiscountData.currentTierData:props.insuranceData.groupDiscountData.groupDiscountTiers[0]);return(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,{class:normalizeClass([`small-insurance-card`,{"no-vehicles":buttonsDisabled.value}]),style:normalizeStyle({"border-top":`0.7rem solid ${props.insuranceData.color}`,background:`linear-gradient(180deg, ${props.insuranceData.color}80 0%, ${props.insuranceData.color}30 10%, ${props.insuranceData.color}10 35%, var(--bng-cool-gray-800) 50%, var(--blue-shade-100) 100%)`})},[createVNode(unref(insuranceIdentity_default),{class:`insurance-identity`,insuranceData:props.insuranceData},null,8,[`insuranceData`]),createBaseVNode(`div`,_hoisted_1$251,[createBaseVNode(`div`,_hoisted_2$208,[createBaseVNode(`span`,null,`Premium / `+toDisplayString(renewsEveryFormatted.value),1),createBaseVNode(`span`,_hoisted_3$182,[createBaseVNode(`div`,_hoisted_4$155,[createVNode(unref(bngUnit_default),{money:props.insuranceData.currentPremiumDetails.totalPriceWithDriverScore},null,8,[`money`])])])]),createBaseVNode(`div`,_hoisted_5$135,[_cache[0]||=createBaseVNode(`span`,null,`Renews in `,-1),createBaseVNode(`span`,_hoisted_6$116,[props.insuranceData.carsInsuredCount===0?(openBlock(),createElementBlock(Fragment,{key:0},[createTextVNode(` - `)],64)):(openBlock(),createElementBlock(Fragment,{key:1},[createTextVNode(toDisplayString(renewsInFormatted.value),1)],64))])]),createBaseVNode(`div`,_hoisted_7$103,[_cache[1]||=createBaseVNode(`span`,null,`Vehicle Coverage`,-1),createBaseVNode(`span`,_hoisted_8$87,[createVNode(unref(bngUnit_default),{money:props.insuranceData.totalInsuranceVehsValue},null,8,[`money`])])]),createBaseVNode(`div`,_hoisted_9$77,[_cache[2]||=createBaseVNode(`span`,null,`Vehicles`,-1),createBaseVNode(`span`,_hoisted_10$67,toDisplayString(props.insuranceData.carsInsuredCount),1)])]),createBaseVNode(`div`,_hoisted_11$60,[createVNode(unref(insurancePerks_default),{insuranceData:props.insuranceData,noDescription:!0},null,8,[`insuranceData`])]),createBaseVNode(`div`,{class:normalizeClass([`group-discount-wrapper`,{disabled:props.insuranceData.groupDiscountData.currentTierData.id===-1}])},[props.insuranceData.carsInsuredCount===0?(openBlock(),createElementBlock(`div`,_hoisted_12$49,` No vehicles insured under this policy `)):props.insuranceData.carsInsuredCount===1?(openBlock(),createElementBlock(`div`,_hoisted_13$42,` Add a second vehicle to unlock Tier 1 (`+toDisplayString(props.insuranceData.groupDiscountData.groupDiscountTiers[0].discount*100)+`%) coverage savings. `,1)):(openBlock(),createElementBlock(Fragment,{key:2},[_cache[4]||=createBaseVNode(`div`,{class:`group-discount`},` MULTI-VEHICLE DISCOUNT `,-1),createBaseVNode(`div`,_hoisted_14$39,[_cache[3]||=createTextVNode(` Savings :`,-1),createVNode(unref(bngUnit_default),{money:props.insuranceData.currentPremiumDetails.groupDiscountSavings},null,8,[`money`])]),createBaseVNode(`div`,_hoisted_15$37,[tierToDisplay.value.max?(openBlock(),createElementBlock(`span`,_hoisted_16$36,` Your coverage falls in the `+toDisplayString(tierToDisplay.value.min/1e3)+`k - `+toDisplayString(tierToDisplay.value.max/1e3)+`k range `,1)):(openBlock(),createElementBlock(`span`,_hoisted_17$30,` Your coverage falls in the `+toDisplayString(tierToDisplay.value.min/1e3)+`k+ range `,1))]),createBaseVNode(`div`,null,[createVNode(unref(insuranceTiers_default),{showTier:!0,tiers:props.insuranceData.groupDiscountData.groupDiscountTiers},null,8,[`tiers`])])],64))],2),createBaseVNode(`div`,_hoisted_18$27,[createVNode(unref(bngButton_default),{class:`edit-policy-button bigger-button`,accent:`custom`,onClick:openEditPolicy,disabled:buttonsDisabled.value},{default:withCtx(()=>[createVNode(unref(bngIcon_default),{class:normalizeClass([`button-icon`,{disabled:buttonsDisabled.value}]),type:unref(icons).adjust},null,8,[`type`,`class`]),createBaseVNode(`span`,{class:normalizeClass([`button-text`,{disabled:buttonsDisabled.value}])},`Edit Policy`,2)]),_:1},8,[`disabled`]),createVNode(unref(bngButton_default),{class:`see-vehicles-button bigger-button`,accent:`custom`,onClick:openVehicleList,disabled:buttonsDisabled.value},{default:withCtx(()=>[createVNode(unref(bngIcon_default),{class:normalizeClass([`button-icon`,{disabled:buttonsDisabled.value}]),type:unref(icons).car},null,8,[`type`,`class`]),createBaseVNode(`span`,{class:normalizeClass([`button-text`,{disabled:buttonsDisabled.value}])},`See Vehicles`,2)]),_:1},8,[`disabled`])])],6))}},smallInsuranceCard_default=__plugin_vue_export_helper_default(_sfc_main$281,[[`__scopeId`,`data-v-38392c0c`]]),_hoisted_1$250={class:`insurance-details-wrapper`,"bng-ui-scope":`insuranceDetailsPopup`},_hoisted_2$207={class:`card-content`},_hoisted_3$181={class:`header`},_hoisted_4$154={class:`header-left`},_hoisted_5$134={class:`insurance-identity`},_hoisted_6$115={class:`insurance-name`},_hoisted_7$102={class:`insurance-slogan`},_hoisted_8$86={class:`covers-renew-info`},_hoisted_9$76={class:`header-right`},_hoisted_10$66={class:`vehicle-name`},_hoisted_11$59={class:`vehicle-value blue-price`},_hoisted_12$48={key:0,class:`group-discount-wrapper`},_hoisted_13$41={class:`group-discount-header`},_hoisted_14$38={class:`group-discount-icon-wrapper`},_hoisted_15$36={class:`group-discount-text-wrapper`},_hoisted_16$35={class:`group-discount-main-text`},_hoisted_17$29={class:`tiers-wrapper`},_hoisted_18$26={class:`textual-tiers-wrapper`},_hoisted_19$23={class:`tier-number`},_hoisted_20$19={class:`money-bracket`},_hoisted_21$17={key:0},_hoisted_22$15={key:1},_hoisted_23$14={class:`current-after-discount-price`},_hoisted_24$13={class:`tier-discount-price`},_hoisted_25$12={class:`policy-value`},_hoisted_26$10={class:`policy-tier`},_hoisted_27$10={class:`tier-discount-price isFutureTier`},_hoisted_28$9={class:`policy-value`},_hoisted_29$9={class:`policy-tier isFuture`},_hoisted_30$9={class:`price-breakdown-wrapper`},_hoisted_31$9={class:`prices-breakdown-header`},_hoisted_32$9={class:`breakdown-item`},_hoisted_33$9={class:`breakdown-details`},_hoisted_34$9={class:`breakdown-item-value`},_hoisted_35$8={class:`breakdown-value`},_hoisted_36$8={class:`breakdown-item-value orange`},_hoisted_37$7={class:`breakdown-value`},_hoisted_38$6={key:0,class:`breakdown-item-value orange`},_hoisted_39$6={class:`breakdown-label`},_hoisted_40$5={class:`breakdown-value`},_hoisted_41$5={class:`breakdown-item-value result`},_hoisted_42$4={class:`breakdown-value result`},_hoisted_43$4={class:`breakdown-item`},_hoisted_44$4={class:`breakdown-details`},_hoisted_45$4={key:0,class:`breakdown-item-value`},_hoisted_46$2={key:0,class:`strikethrough-line`},_hoisted_47$2={key:1,class:`breakdown-item-value`},_hoisted_48$2={class:`breakdown-label`},_hoisted_49$2={class:`tier-discount-badge`},_hoisted_50$2={class:`breakdown-value green-price`},_hoisted_51$2={key:0,class:`breakdown-item-value`},_hoisted_52$2={class:`breakdown-label`},_hoisted_53$2={class:`breakdown-value`},_hoisted_54$2={class:`breakdown-item-value subtotal`},_hoisted_55$2={class:`breakdown-value`},_hoisted_56$2={class:`breakdown-item-value`},_hoisted_57$1={class:`breakdown-item-value result`},_hoisted_58$1={class:`breakdown-value`},_hoisted_59$1={class:`sum-to-pay`},_hoisted_60$1={class:`sum-to-pay-value`},_hoisted_61$1={class:`closeButton`},__default__$5={wrapper:{fade:!0,blur:!0,style:popupContainer.default},position:[popupPosition.center,popupPosition.center]},_sfc_main$280=Object.assign(__default__$5,{__name:`purchaseInsuranceDetails`,props:{insuranceData:Object,vehicleInfo:Object,driverScoreData:Object},emits:[`return`],setup(__props,{emit:__emit}){let{units}=useBridge();useUINavScope(`insuranceDetailsPopup`);let props=__props,emit$1=__emit,closePopup=()=>{emit$1(`return`,!0)},driverScoreAdjustmentText=computed(()=>{let multiplier=props.driverScoreData.tier.multiplier;return multiplier<1?`↓${((1-multiplier)*100).toFixed(0)}%`:multiplier>1?`↑${((multiplier-1)*100).toFixed(0)}%`:`0%`}),driverScoreClass=computed(()=>{let multiplier=props.driverScoreData.tier.multiplier;return multiplier<1?`driver-score-discount`:multiplier>1?`driver-score-penalty`:``}),groupDiscountText=computed(()=>{if(props.insuranceData.groupDiscountData){if(props.insuranceData.groupDiscountData.willHaveGroupDiscountForTheFirstTime)return`Multi-vehicle discount available`;if(props.insuranceData.groupDiscountData.willBumpTheirDiscount)return`Bigger discount available`;if(props.insuranceData.groupDiscountData.currentTierData&&props.insuranceData.groupDiscountData.currentTierData.id>0)return`Multi-vehicle discount active`}return null}),renewsEveryFormatted=computed(()=>props.insuranceData?.renewsEvery?units.buildString(`length`,props.insuranceData.renewsEvery*1e3,0):``);return(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$250,[createBaseVNode(`div`,_hoisted_2$207,[createBaseVNode(`div`,_hoisted_3$181,[createBaseVNode(`div`,_hoisted_4$154,[_cache[2]||=createBaseVNode(`div`,{class:`policy-details`},` Policy details `,-1),createBaseVNode(`div`,_hoisted_5$134,[createBaseVNode(`span`,_hoisted_6$115,toDisplayString(props.insuranceData.name),1),_cache[0]||=createBaseVNode(`span`,{class:`name-slogan-seperator`},null,-1),createBaseVNode(`span`,_hoisted_7$102,toDisplayString(props.insuranceData.slogan),1)]),createBaseVNode(`div`,_hoisted_8$86,[createBaseVNode(`span`,null,`Covers `+toDisplayString(props.insuranceData.carsInsuredCount)+` Vehicles`,1),_cache[1]||=createBaseVNode(`span`,{class:`covers-renew-seperator`},null,-1),createBaseVNode(`span`,null,`Renews every `+toDisplayString(renewsEveryFormatted.value),1)])]),createBaseVNode(`div`,_hoisted_9$76,[_cache[4]||=createBaseVNode(`div`,{class:`action-type`},`Adding vehicle`,-1),createBaseVNode(`div`,_hoisted_10$66,toDisplayString(props.vehicleInfo.Name),1),createBaseVNode(`div`,_hoisted_11$59,[_cache[3]||=createTextVNode(`Value : `,-1),createVNode(unref(bngUnit_default),{money:props.vehicleInfo.Value},null,8,[`money`])])])]),props.insuranceData.groupDiscountData.willHaveGroupDiscountForTheFirstTime||props.insuranceData.groupDiscountData.willBumpTheirDiscount||props.insuranceData.groupDiscountData.currentTierData.id>0?(openBlock(),createElementBlock(`div`,_hoisted_12$48,[createBaseVNode(`div`,_hoisted_13$41,[createBaseVNode(`div`,_hoisted_14$38,[createVNode(unref(bngIcon_default),{type:unref(icons).checkmark},null,8,[`type`])]),createBaseVNode(`div`,_hoisted_15$36,[createBaseVNode(`div`,_hoisted_16$35,toDisplayString(groupDiscountText.value),1),_cache[5]||=createBaseVNode(`div`,{class:`group-discount-secondary-text`},` Insurance discounts are based on the total value of your fleet. `,-1)])]),createBaseVNode(`div`,_hoisted_17$29,[createBaseVNode(`div`,_hoisted_18$26,[(openBlock(!0),createElementBlock(Fragment,null,renderList(props.insuranceData.groupDiscountData.groupDiscountTiers,tier=>(openBlock(),createElementBlock(`div`,{class:`tier`,key:tier.id},[createBaseVNode(`div`,_hoisted_19$23,` Tier `+toDisplayString(tier.id),1),createBaseVNode(`div`,_hoisted_20$19,[createBaseVNode(`span`,null,toDisplayString(tier.min/1e3)+`k`,1),tier.max?(openBlock(),createElementBlock(`span`,_hoisted_21$17,`-`+toDisplayString(tier.max/1e3)+`k`,1)):(openBlock(),createElementBlock(`span`,_hoisted_22$15,`+`))])]))),128))]),createVNode(unref(insuranceTiers_default),{tiers:props.insuranceData.groupDiscountData.groupDiscountTiers},null,8,[`tiers`])]),createBaseVNode(`div`,_hoisted_23$14,[createBaseVNode(`div`,_hoisted_24$13,[_cache[7]||=createBaseVNode(`div`,{class:`section-label deactivated`},` Current Tier `,-1),createBaseVNode(`div`,_hoisted_25$12,[_cache[6]||=createTextVNode(` Policy Value : `,-1),createVNode(unref(bngUnit_default),{money:props.insuranceData.totalInsuranceVehsValue},null,8,[`money`])]),createBaseVNode(`div`,_hoisted_26$10,` Tier `+toDisplayString(Math.max(props.insuranceData.groupDiscountData.currentTierData.id,0))+` - `+toDisplayString(props.insuranceData.groupDiscountData.currentTierData.discount*100)+`% off `,1)]),createBaseVNode(`div`,_hoisted_27$10,[_cache[9]||=createBaseVNode(`div`,{class:`section-label`},` After Purchase `,-1),createBaseVNode(`div`,_hoisted_28$9,[_cache[8]||=createTextVNode(` Policy Value : `,-1),createVNode(unref(bngUnit_default),{money:props.insuranceData.totalInsuranceVehsValue+props.insuranceData.vehicleValue},null,8,[`money`])]),createBaseVNode(`div`,_hoisted_29$9,` Tier `+toDisplayString(props.insuranceData.groupDiscountData.futureTierData.id)+` - `+toDisplayString(props.insuranceData.groupDiscountData.futureTierData.discount*100)+`% off `,1)])])])):createCommentVNode(``,!0),createBaseVNode(`div`,_hoisted_30$9,[createBaseVNode(`div`,_hoisted_31$9,[createBaseVNode(`div`,_hoisted_32$9,[_cache[13]||=createBaseVNode(`div`,{class:`section-label`},` Vehicle `,-1),createBaseVNode(`div`,_hoisted_33$9,[createBaseVNode(`div`,_hoisted_34$9,[_cache[10]||=createBaseVNode(`span`,{class:`breakdown-label`},` Coverage Cost `,-1),createBaseVNode(`span`,_hoisted_35$8,[createVNode(unref(bngUnit_default),{money:props.insuranceData.nonProRatedVehiclePremium},null,8,[`money`])])]),createBaseVNode(`div`,_hoisted_36$8,[_cache[11]||=createBaseVNode(`span`,{class:`breakdown-label`},` Pro-rated Renewal `,-1),createBaseVNode(`span`,_hoisted_37$7,` × `+toDisplayString(props.insuranceData.proRatedPercentage)+`% `,1)]),props.insuranceData.groupDiscountData?.currentTierData.id>0?(openBlock(),createElementBlock(`div`,_hoisted_38$6,[createBaseVNode(`span`,_hoisted_39$6,` Tier `+toDisplayString(props.insuranceData.groupDiscountData?.currentTierData.id)+` discount `,1),createBaseVNode(`span`,_hoisted_40$5,` - `+toDisplayString(props.insuranceData.groupDiscountData?.currentTierData.discount*100)+`% `,1)])):createCommentVNode(``,!0),createBaseVNode(`div`,_hoisted_41$5,[_cache[12]||=createBaseVNode(`span`,{class:`breakdown-label`},` Policy Add-On Cost `,-1),createBaseVNode(`span`,_hoisted_42$4,[createVNode(unref(bngUnit_default),{money:props.insuranceData.proRatedVehiclePremium},null,8,[`money`])])])])]),createBaseVNode(`div`,_hoisted_43$4,[_cache[18]||=createBaseVNode(`div`,{class:`section-label`},` New Premium `,-1),createBaseVNode(`div`,_hoisted_44$4,[props.insuranceData.futurePremiumDetails.items.vehsCoverage?(openBlock(),createElementBlock(`div`,_hoisted_45$4,[_cache[14]||=createBaseVNode(`div`,{class:`breakdown-label`},` Vehicles Coverage `,-1),createBaseVNode(`div`,{class:normalizeClass([`breakdown-value strikethrough-container`,{"strikethrough-grey":props.insuranceData.futurePremiumDetails.groupDiscountSavings>0}])},[createVNode(unref(bngUnit_default),{money:props.insuranceData.futurePremiumDetails.items.vehsCoverage.priceWithoutGroupDiscount},null,8,[`money`]),props.insuranceData.futurePremiumDetails.groupDiscountSavings>0?(openBlock(),createElementBlock(`div`,_hoisted_46$2)):createCommentVNode(``,!0)],2)])):createCommentVNode(``,!0),props.insuranceData.futurePremiumDetails.items.vehsCoverage&&props.insuranceData.futurePremiumDetails.groupDiscountSavings>0?(openBlock(),createElementBlock(`div`,_hoisted_47$2,[createBaseVNode(`div`,_hoisted_48$2,[createTextVNode(toDisplayString(props.insuranceData.futurePremiumDetails.items.vehsCoverage.name)+` `,1),createBaseVNode(`span`,null,[createTextVNode(`: Tier `+toDisplayString(props.insuranceData.groupDiscountData.currentTierData.id)+` `,1),createBaseVNode(`span`,_hoisted_49$2,`(`+toDisplayString(props.insuranceData.groupDiscountData.currentTierData.discount*100)+`% off)`,1)])]),createBaseVNode(`div`,_hoisted_50$2,[createVNode(unref(bngUnit_default),{money:props.insuranceData.futurePremiumDetails.items.vehsCoverage.price},null,8,[`money`])])])):createCommentVNode(``,!0),(openBlock(!0),createElementBlock(Fragment,null,renderList(props.insuranceData.futurePremiumDetails.items,(item,key)=>(openBlock(),createElementBlock(Fragment,{key},[key===`vehsCoverage`?createCommentVNode(``,!0):(openBlock(),createElementBlock(`div`,_hoisted_51$2,[createBaseVNode(`div`,_hoisted_52$2,toDisplayString(item.name),1),createBaseVNode(`div`,_hoisted_53$2,[createVNode(unref(bngUnit_default),{money:item.price},null,8,[`money`])])]))],64))),128)),createBaseVNode(`div`,_hoisted_54$2,[_cache[15]||=createBaseVNode(`div`,{class:`breakdown-label`},` Subtotal `,-1),createBaseVNode(`div`,_hoisted_55$2,[createVNode(unref(bngUnit_default),{money:props.insuranceData.futurePremiumDetails.totalPrice},null,8,[`money`])])]),createBaseVNode(`div`,_hoisted_56$2,[_cache[16]||=createBaseVNode(`div`,{class:`breakdown-label`},` Driver Score Adjustment `,-1),createBaseVNode(`div`,{class:normalizeClass([`breakdown-value`,driverScoreClass.value])},toDisplayString(driverScoreAdjustmentText.value),3)]),createBaseVNode(`div`,_hoisted_57$1,[_cache[17]||=createBaseVNode(`div`,{class:`breakdown-label`},` Total Premium `,-1),createBaseVNode(`div`,_hoisted_58$1,[createVNode(unref(bngUnit_default),{money:props.insuranceData.futurePremiumDetails.totalPriceWithDriverScore},null,8,[`money`])])])])])]),createBaseVNode(`div`,_hoisted_59$1,[_cache[19]||=createBaseVNode(`span`,null,`Amount due today`,-1),createBaseVNode(`span`,_hoisted_60$1,[createVNode(unref(bngUnit_default),{class:`green-price`,money:props.insuranceData.addVehiclePrice},null,8,[`money`])])])]),createBaseVNode(`div`,_hoisted_61$1,[createVNode(unref(bngButton_default),{accent:unref(ACCENTS).primary,onClick:closePopup},{default:withCtx(()=>[..._cache[20]||=[createTextVNode(` Close `,-1)]]),_:1},8,[`accent`])])])]))}}),purchaseInsuranceDetails_default=__plugin_vue_export_helper_default(_sfc_main$280,[[`__scopeId`,`data-v-9f20c127`]]),_hoisted_1$249={class:`content`},_hoisted_2$206={class:`top-banner`},_hoisted_3$180={class:`top-banner-left`},_hoisted_4$153={class:`insurance-details`},_hoisted_5$133={class:`insurance-name`},_hoisted_6$114={class:`insurance-slogan`},_hoisted_7$101={class:`small-grey-text`},_hoisted_8$85={class:`small-grey-text`},_hoisted_9$75={class:`top-banner-right`},_hoisted_10$65={class:`information-wrapper`},_hoisted_11$58={class:`information-value`},_hoisted_12$47={class:`driver-score-tier`},_hoisted_13$40={class:`premium-effect`},_hoisted_14$37={class:`switching-details-wrapper`},_hoisted_15$35={class:`three-columns-grid`},_hoisted_16$34={class:`switching-column column-leaving`},_hoisted_17$28={class:`column-header`},_hoisted_18$25={class:`column-details`},_hoisted_19$22={class:`detail-item`},_hoisted_20$18={class:`detail-value`},_hoisted_21$16={class:`detail-item`},_hoisted_22$14={class:`detail-item divider-above`},_hoisted_23$13={class:`detail-value-positive`},_hoisted_24$12={class:`detail-item`},_hoisted_25$11={class:`detail-value-negative`},_hoisted_26$9={class:`detail-item divider-above`},_hoisted_27$9={class:`detail-value-positive-bold`},_hoisted_28$8={class:`detail-note`},_hoisted_29$8={class:`switching-column column-vehicle`},_hoisted_30$8={class:`vehicle-display-box`},_hoisted_31$8=[`src`],_hoisted_32$8={class:`column-details`},_hoisted_33$8={class:`detail-item`},_hoisted_34$8={class:`detail-value-bold`},_hoisted_35$7={class:`detail-item`},_hoisted_36$7={class:`detail-value-bold`},_hoisted_37$6={class:`detail-item divider-above`},_hoisted_38$5={class:`detail-value-highlight`},_hoisted_39$5={class:`detail-note`},_hoisted_40$4={class:`switching-column column-joining`},_hoisted_41$4={class:`column-header`},_hoisted_42$3={class:`column-details`},_hoisted_43$3={class:`detail-item`},_hoisted_44$3={class:`detail-value`},_hoisted_45$3={class:`detail-item`},_hoisted_46$1={class:`detail-item divider-above`},_hoisted_47$1={class:`detail-value-negative`},_hoisted_48$1={class:`detail-item divider-above`},_hoisted_49$1={class:`detail-item divider-above`},_hoisted_50$1={class:`detail-value-bold`},_hoisted_51$1={class:`detail-note`},_hoisted_52$1={class:`final-amount-content-row`},_hoisted_53$1={class:`final-amount-label`},_hoisted_54$1={class:`final-amount-breakdown`},_hoisted_55$1={class:`buttons`},_hoisted_56$1={key:0},_sfc_main$279={__name:`changeInsuranceDetails`,props:{insuranceData:{type:Object,required:!0},vehicleInfo:{type:Object,default:()=>({})},driverScoreData:{type:Object,default:()=>({})}},emits:[`return`,`switch`],setup(__props,{emit:__emit}){let{units}=useBridge(),props=__props,emit$1=__emit,premiumSavingPercent=computed(()=>(1-(props.driverScoreData?.tier?.multiplier||1))*100),leavingInfo=computed(()=>props.insuranceData.leavingInsuranceInfo||null),leavingInsuranceName=computed(()=>leavingInfo.value?.currentInsuranceName||`Current Insurance`),tierDropped=computed(()=>leavingInfo.value?leavingInfo.value.discountTierData?.id>leavingInfo.value.newDiscountTierData?.id:!1),tierIncreased=computed(()=>{let current=props.insuranceData.groupDiscountData?.currentTierData?.id||0;return(props.insuranceData.groupDiscountData?.futureTierData?.id||current)>current}),currentTierId=computed(()=>props.insuranceData.groupDiscountData?.currentTierData?.id||0),futureTierId=computed(()=>props.insuranceData.groupDiscountData?.futureTierData?.id||props.insuranceData.groupDiscountData?.currentTierData?.id||0),proRatedPercentage=computed(()=>Math.round(props.insuranceData.proRatedPercentage||100)),driverScoreImpactPercent=computed(()=>(1-(props.driverScoreData?.tier?.multiplier||1))*100),driverScoreImpactClass=computed(()=>driverScoreImpactPercent.value>0?`saving`:driverScoreImpactPercent.value<0?`increase`:`neutral`),driverScoreImpactText=computed(()=>driverScoreImpactPercent.value>0?`↓${driverScoreImpactPercent.value.toFixed(0)}%`:driverScoreImpactPercent.value<0?`↑${Math.abs(driverScoreImpactPercent.value).toFixed(0)}%`:`0%`),renewsEveryFormatted=computed(()=>props.insuranceData?.renewsEvery?units.buildString(`length`,props.insuranceData.renewsEvery*1e3,0):``),renewsInFormatted=computed(()=>props.insuranceData?.renewsIn?units.buildString(`length`,props.insuranceData.renewsIn*1e3,0):``),leavingRenewsInFormatted=computed(()=>leavingInfo.value?.renewsIn?units.buildString(`length`,leavingInfo.value.renewsIn*1e3,0):``),closePopup=()=>{emit$1(`return`,!0)},onSwitchClick=()=>{Lua_default.career_modules_insurance_insurance.changeInvVehInsurance(props.vehicleInfo.invVehId,props.insuranceData.id),emit$1(`return`,!0)};return(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$249,[createBaseVNode(`div`,_hoisted_2$206,[createBaseVNode(`div`,_hoisted_3$180,[_cache[2]||=createBaseVNode(`div`,{class:`title`},` Change Insurance `,-1),createBaseVNode(`div`,_hoisted_4$153,[createBaseVNode(`span`,_hoisted_5$133,toDisplayString(props.insuranceData.name),1),_cache[0]||=createBaseVNode(`span`,{class:`name-slogan-seperator`},null,-1),createBaseVNode(`span`,_hoisted_6$114,` "`+toDisplayString(props.insuranceData.slogan)+`" `,1)]),createBaseVNode(`div`,null,[createBaseVNode(`span`,_hoisted_7$101,` Covers `+toDisplayString(props.insuranceData.carsInsuredCount)+` Vehicles `,1),_cache[1]||=createBaseVNode(`span`,{class:`dot-seperator`},null,-1),createBaseVNode(`span`,_hoisted_8$85,` Renews every `+toDisplayString(renewsEveryFormatted.value),1)])]),createBaseVNode(`div`,_hoisted_9$75,[createBaseVNode(`div`,_hoisted_10$65,[_cache[4]||=createBaseVNode(`div`,{class:`small-grey-text`},` Driver Score `,-1),createBaseVNode(`div`,_hoisted_11$58,toDisplayString(props.driverScoreData.score)+`: `+toDisplayString(props.driverScoreData.tier.risk),1),createBaseVNode(`div`,_hoisted_12$47,toDisplayString(props.driverScoreData.tier.name),1),createBaseVNode(`div`,_hoisted_13$40,[_cache[3]||=createBaseVNode(`span`,{class:`small-grey-text`},` Premium Effect : `,-1),createBaseVNode(`span`,{class:normalizeClass([`premium-effect-value`,{saving:premiumSavingPercent.value>0,increase:premiumSavingPercent.value<0}])},toDisplayString(premiumSavingPercent.value>0?`${premiumSavingPercent.value.toFixed(0)}% saving`:premiumSavingPercent.value<0?`${Math.abs(premiumSavingPercent.value).toFixed(0)}% increase`:`No change`),3)])])])]),createBaseVNode(`div`,_hoisted_14$37,[createBaseVNode(`div`,_hoisted_15$35,[createBaseVNode(`div`,_hoisted_16$34,[createBaseVNode(`div`,_hoisted_17$28,[_cache[5]||=createBaseVNode(`span`,null,`←`,-1),createTextVNode(` Leaving `+toDisplayString(leavingInsuranceName.value),1)]),createBaseVNode(`div`,_hoisted_18$25,[createBaseVNode(`div`,_hoisted_19$22,[_cache[6]||=createBaseVNode(`span`,{class:`detail-label`},`Vehicles:`,-1),createBaseVNode(`span`,_hoisted_20$18,toDisplayString(leavingInfo.value.vehicleCount)+` → `+toDisplayString(leavingInfo.value.newVehicleCount),1)]),createBaseVNode(`div`,_hoisted_21$16,[_cache[7]||=createBaseVNode(`span`,{class:`detail-label`},`Discount Tier:`,-1),createBaseVNode(`span`,{class:normalizeClass([`detail-value`,{"tier-change-down":tierDropped.value}])},toDisplayString(leavingInfo.value.discountTierData.id)+` → `+toDisplayString(leavingInfo.value.newDiscountTierData.id),3)]),createBaseVNode(`div`,_hoisted_22$14,[_cache[9]||=createBaseVNode(`span`,{class:`detail-label`},`Coverage refund:`,-1),createBaseVNode(`span`,_hoisted_23$13,[_cache[8]||=createTextVNode(`+`,-1),createVNode(unref(bngUnit_default),{money:leavingInfo.value.coverageRefundPrice},null,8,[`money`])])]),createBaseVNode(`div`,_hoisted_24$12,[_cache[11]||=createBaseVNode(`span`,{class:`detail-label`},`Cancellation fee (25%):`,-1),createBaseVNode(`span`,_hoisted_25$11,[_cache[10]||=createTextVNode(`-`,-1),createVNode(unref(bngUnit_default),{money:leavingInfo.value.earlyTerminationPenalty},null,8,[`money`])])]),createBaseVNode(`div`,_hoisted_26$9,[_cache[12]||=createBaseVNode(`span`,{class:`detail-label-bold`},`Net Refund:`,-1),createBaseVNode(`span`,_hoisted_27$9,[createVNode(unref(bngUnit_default),{money:leavingInfo.value.netRefundPrice},null,8,[`money`])])]),createBaseVNode(`div`,_hoisted_28$8,toDisplayString(leavingRenewsInFormatted.value)+` unused `,1)])]),createBaseVNode(`div`,_hoisted_29$8,[_cache[16]||=createBaseVNode(`div`,{class:`column-header column-header-center`},`Moving Vehicle`,-1),createBaseVNode(`div`,_hoisted_30$8,[createBaseVNode(`img`,{src:props.vehicleInfo?.thumbnail,alt:``,class:`vehicle-thumbnail`},null,8,_hoisted_31$8)]),createBaseVNode(`div`,_hoisted_32$8,[createBaseVNode(`div`,_hoisted_33$8,[_cache[13]||=createBaseVNode(`span`,{class:`detail-label`},`Vehicle:`,-1),createBaseVNode(`span`,_hoisted_34$8,toDisplayString(props.vehicleInfo.Name),1)]),createBaseVNode(`div`,_hoisted_35$7,[_cache[14]||=createBaseVNode(`span`,{class:`detail-label`},`Value:`,-1),createBaseVNode(`span`,_hoisted_36$7,[createVNode(unref(bngUnit_default),{money:props.vehicleInfo.Value},null,8,[`money`])])]),createBaseVNode(`div`,_hoisted_37$6,[_cache[15]||=createBaseVNode(`span`,{class:`detail-label`},`Joining mid-cycle:`,-1),createBaseVNode(`span`,_hoisted_38$5,`× `+toDisplayString(proRatedPercentage.value)+`%`,1)]),createBaseVNode(`div`,_hoisted_39$5,toDisplayString(renewsInFormatted.value)+` remaining in cycle `,1)])]),createBaseVNode(`div`,_hoisted_40$4,[createBaseVNode(`div`,_hoisted_41$4,[createTextVNode(` Joining `+toDisplayString(props.insuranceData.name)+` `,1),_cache[17]||=createBaseVNode(`span`,null,`→`,-1)]),createBaseVNode(`div`,_hoisted_42$3,[createBaseVNode(`div`,_hoisted_43$3,[_cache[18]||=createBaseVNode(`span`,{class:`detail-label`},`Vehicles:`,-1),createBaseVNode(`span`,_hoisted_44$3,toDisplayString(props.insuranceData.carsInsuredCount)+` → `+toDisplayString(props.insuranceData.carsInsuredCount+1),1)]),createBaseVNode(`div`,_hoisted_45$3,[_cache[19]||=createBaseVNode(`span`,{class:`detail-label`},`Discount Tier:`,-1),createBaseVNode(`span`,{class:normalizeClass([`detail-value`,{"tier-change-up":tierIncreased.value}])},toDisplayString(currentTierId.value)+` → `+toDisplayString(futureTierId.value),3)]),createBaseVNode(`div`,_hoisted_46$1,[_cache[21]||=createBaseVNode(`span`,{class:`detail-label`},`Add vehicle cost:`,-1),createBaseVNode(`span`,_hoisted_47$1,[_cache[20]||=createTextVNode(`+`,-1),createVNode(unref(bngUnit_default),{money:props.insuranceData.addVehiclePrice},null,8,[`money`])])]),createBaseVNode(`div`,_hoisted_48$1,[_cache[22]||=createBaseVNode(`span`,{class:`detail-label`},`Driver Score Impact:`,-1),createBaseVNode(`span`,{class:normalizeClass([`detail-value-impact`,driverScoreImpactClass.value])},toDisplayString(driverScoreImpactText.value),3)]),createBaseVNode(`div`,_hoisted_49$1,[_cache[23]||=createBaseVNode(`span`,{class:`detail-label-bold`},`New Policy Premium:`,-1),createBaseVNode(`span`,_hoisted_50$1,[createVNode(unref(bngUnit_default),{money:props.insuranceData.futurePremiumDetails.totalPriceWithDriverScore},null,8,[`money`])])]),createBaseVNode(`div`,_hoisted_51$1,toDisplayString(renewsInFormatted.value)+` until renewal `,1)])])]),createBaseVNode(`div`,{class:normalizeClass([`final-amount-box`,props.insuranceData.netSwitchingCost>0?`amount-credit`:`amount-payment`])},[createBaseVNode(`div`,_hoisted_52$1,[createBaseVNode(`div`,null,[createBaseVNode(`div`,_hoisted_53$1,toDisplayString(props.insuranceData.netSwitchingCost>0?`Credit Received Today`:`Amount Due Today`),1),createBaseVNode(`div`,_hoisted_54$1,[createVNode(unref(bngUnit_default),{money:leavingInfo.value.netRefundPrice},null,8,[`money`]),_cache[24]||=createTextVNode(` refund - `,-1),createVNode(unref(bngUnit_default),{money:props.insuranceData.addVehiclePrice},null,8,[`money`]),_cache[25]||=createTextVNode(` new cost `,-1)])]),createBaseVNode(`div`,{class:normalizeClass([`final-amount-total`,props.insuranceData.netSwitchingCost<0?`negative`:`positive`])},[createVNode(unref(bngUnit_default),{money:Math.abs(props.insuranceData.netSwitchingCost)},null,8,[`money`])],2)])],2)]),createBaseVNode(`div`,_hoisted_55$1,[createVNode(unref(bngButton_default),{class:`gray-button bigger-button`,accent:`custom`,onClick:closePopup},{default:withCtx(()=>[..._cache[26]||=[createTextVNode(` Cancel `,-1)]]),_:1}),createVNode(unref(bngButton_default),{class:`save-button bigger-button`,accent:`custom`,onClick:onSwitchClick},{default:withCtx(()=>[_cache[27]||=createTextVNode(` Switch for `,-1),props.insuranceData.netSwitchingCost<0?(openBlock(),createElementBlock(`div`,_hoisted_56$1,[createVNode(unref(bngUnit_default),{money:Math.abs(props.insuranceData.netSwitchingCost)},null,8,[`money`])])):createCommentVNode(``,!0)]),_:1})])]))}},changeInsuranceDetails_default=__plugin_vue_export_helper_default(_sfc_main$279,[[`__scopeId`,`data-v-9624a106`]]),_hoisted_1$248={class:`insurance-tiers`},_hoisted_2$205={key:0},_sfc_main$278={__name:`insuranceTiers`,props:{tiers:{type:Array,required:!0},showTier:{type:Boolean,default:!1}},setup(__props){let props=__props;return(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$248,[(openBlock(!0),createElementBlock(Fragment,null,renderList(props.tiers,tier=>(openBlock(),createElementBlock(`div`,{class:`tier`,key:tier.id},[createBaseVNode(`div`,{class:normalizeClass([`tier-discount`,{isCurrent:tier.isCurrent}])},[props.showTier?(openBlock(),createElementBlock(`div`,_hoisted_2$205,` Tier `+toDisplayString(tier.id),1)):createCommentVNode(``,!0),createBaseVNode(`div`,null,toDisplayString(tier.discount*100)+`% `,1)],2)]))),128))]))}},insuranceTiers_default=__plugin_vue_export_helper_default(_sfc_main$278,[[`__scopeId`,`data-v-ccd1e875`]]),_hoisted_1$247={class:`popup-content`},_hoisted_2$204={class:`top-banner`},_hoisted_3$179={class:`top-info`},_hoisted_4$152={class:`top-info-title`},_hoisted_5$132={class:`top-info-policy-name`},_hoisted_6$113={class:`customize-coverage section`},_hoisted_7$100={class:`premium-details section`},_hoisted_8$84={class:`premium-details-content`},_hoisted_9$74={class:`premium-details-left`},_hoisted_10$64={class:`premium-details-label`},_hoisted_11$57={class:`premium-details-right`},_hoisted_12$46={key:0,class:`price-diff-container`},_hoisted_13$39={class:`premium-details-total premium-details-item`},_hoisted_14$36={class:`premium-details-left`},_hoisted_15$34={class:`driver-score-details-wrapper`},_hoisted_16$33={class:`driver-score-details`},_hoisted_17$27={class:`premium-details-right`},_hoisted_18$24={key:0,class:`price-diff-container`},_hoisted_19$21={class:`buttons`},_sfc_main$277={__name:`editPolicy`,props:{insuranceData:{type:Object,required:!0},driverScoreData:{type:Object,required:!0}},emits:[`return`],setup(__props,{emit:__emit}){let props=__props,changedCoverageOptions=ref({}),newPremiumDetails=ref({}),computedNewPremiumDiffs=computed(()=>{if(!newPremiumDetails.value?.items)return{};let diffs={};for(let key in newPremiumDetails.value.items){let newPrice=newPremiumDetails.value.items[key]?.price||0,oldPrice=props.insuranceData.currentPremiumDetails.items[key]?.price||0;diffs[key]={priceDiff:newPrice-oldPrice,newPrice,oldPrice}}return diffs}),computedTotalPriceDiff=computed(()=>newPremiumDetails.value?.totalPrice?newPremiumDetails.value.totalPrice-props.insuranceData.currentPremiumDetails.totalPrice:0),driverScoreColorClass=computed(()=>{let multiplier=props.driverScoreData?.tier?.multiplier;return multiplier?multiplier<1?`driver-score-good`:multiplier>1?`driver-score-bad`:``:``}),hasChangedCoverageOptions=computed(()=>props.insuranceData?.coverageOptionsData?props.insuranceData.coverageOptionsData.some(option=>changedCoverageOptions.value[option.key]!==option.currentValueId):!1);onMounted(()=>{props.insuranceData?.coverageOptionsData&&props.insuranceData.coverageOptionsData.forEach(option=>{changedCoverageOptions.value[option.key]=option.currentValueId})});let emit$1=__emit,closePopup=()=>{emit$1(`return`,!0)},openVehicleList=()=>{addPopup(vehicleInsuranceList_default,{insuranceData:props.insuranceData,driverScoreData:props.driverScoreData}),closePopup()},onSaveClick=()=>{Lua_default.career_modules_insurance_insurance.saveNewInsuranceCoverageOptions(props.insuranceData.id,changedCoverageOptions.value),emit$1(`return`,!0)},updatePremiumDetails=async()=>{newPremiumDetails.value=await Lua_default.career_modules_insurance_insurance.calculateInsurancePremium(props.insuranceData.id,changedCoverageOptions.value,null)},onToggleChange=(coverageOption,newValue)=>{let targetChoiceIndex=coverageOption.choices.findIndex(choice=>choice.value===newValue);targetChoiceIndex!==-1&&(changedCoverageOptions.value[coverageOption.key]=targetChoiceIndex+1,updatePremiumDetails())},onChoiceClick=(coverageOption,choice)=>{changedCoverageOptions.value[coverageOption.key]=choice.id,updatePremiumDetails()};return(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$247,[createBaseVNode(`div`,_hoisted_2$204,[createBaseVNode(`div`,_hoisted_3$179,[createBaseVNode(`div`,_hoisted_4$152,[_cache[0]||=createTextVNode(` Edit Policy: `,-1),createBaseVNode(`span`,_hoisted_5$132,toDisplayString(props.insuranceData.name),1)]),_cache[1]||=createBaseVNode(`div`,{class:`top-info-description`},` These settings apply to all vehicles under this policy. Set deductibles per vehicle by clicking "Edit Vehicles" `,-1)]),createVNode(unref(bngButton_default),{class:`edit-vehicles-button`,accent:`custom`,onClick:openVehicleList},{default:withCtx(()=>[..._cache[2]||=[createTextVNode(` Edit Vehicles `,-1)]]),_:1})]),createBaseVNode(`div`,_hoisted_6$113,[(openBlock(!0),createElementBlock(Fragment,null,renderList(props.insuranceData.coverageOptionsData,coverageOption=>(openBlock(),createBlock(unref(coverageOption_default),{key:coverageOption.name,coverageOption,changedCoverageOptions:changedCoverageOptions.value,onChoiceClick,onToggleChange},null,8,[`coverageOption`,`changedCoverageOptions`]))),128))]),createBaseVNode(`div`,_hoisted_7$100,[_cache[5]||=createBaseVNode(`div`,{class:`premium-details-header`},` Premium Breakdown `,-1),createBaseVNode(`div`,_hoisted_8$84,[(openBlock(!0),createElementBlock(Fragment,null,renderList(props.insuranceData.currentPremiumDetails.items,(detail,key)=>(openBlock(),createElementBlock(`div`,{class:`premium-details-item`,key},[createBaseVNode(`div`,_hoisted_9$74,[createBaseVNode(`div`,_hoisted_10$64,toDisplayString(detail.name),1)]),createBaseVNode(`div`,_hoisted_11$57,[computedNewPremiumDiffs.value[key]&&computedNewPremiumDiffs.value[key].priceDiff!==0?(openBlock(),createElementBlock(`div`,_hoisted_12$46,[createBaseVNode(`span`,{class:normalizeClass([`arrow`,{"green-price":computedNewPremiumDiffs.value[key].priceDiff<0,"red-price":computedNewPremiumDiffs.value[key].priceDiff>0}])},toDisplayString(computedNewPremiumDiffs.value[key].priceDiff>0?`↑`:`↓`),3),createVNode(unref(bngUnit_default),{class:normalizeClass([`price-diff`,{"green-price":computedNewPremiumDiffs.value[key].priceDiff<0,"red-price":computedNewPremiumDiffs.value[key].priceDiff>0}]),money:computedNewPremiumDiffs.value[key].priceDiff},null,8,[`class`,`money`])])):createCommentVNode(``,!0),createVNode(unref(bngUnit_default),{money:newPremiumDetails.value?.items?.[key]?.price||detail.price},null,8,[`money`])])]))),128)),createBaseVNode(`div`,_hoisted_13$39,[createBaseVNode(`div`,_hoisted_14$36,[_cache[4]||=createBaseVNode(`div`,null,` Final Premium `,-1),createBaseVNode(`div`,_hoisted_15$34,[createBaseVNode(`span`,_hoisted_16$33,[_cache[3]||=createTextVNode(` Base Premium : `,-1),createVNode(unref(bngUnit_default),{money:props.insuranceData.currentPremiumDetails.totalPrice},null,8,[`money`]),createTextVNode(` × Driver Score `+toDisplayString(props.driverScoreData.score)+` @ `,1)]),createBaseVNode(`span`,{class:normalizeClass([`driver-score`,driverScoreColorClass.value])},toDisplayString(Math.round(props.driverScoreData.tier.multiplier*100))+`% `,3)])]),createBaseVNode(`div`,_hoisted_17$27,[computedTotalPriceDiff.value===0?createCommentVNode(``,!0):(openBlock(),createElementBlock(`div`,_hoisted_18$24,[createBaseVNode(`span`,{class:normalizeClass([`arrow`,{"green-price":computedTotalPriceDiff.value<0,"red-price":computedTotalPriceDiff.value>0}])},toDisplayString(computedTotalPriceDiff.value>0?`↑`:`↓`),3),createVNode(unref(bngUnit_default),{class:normalizeClass([`price-diff`,{"green-price":computedTotalPriceDiff.value<0,"red-price":computedTotalPriceDiff.value>0}]),money:computedTotalPriceDiff.value},null,8,[`class`,`money`])])),createVNode(unref(bngUnit_default),{money:newPremiumDetails.value?.totalPriceWithDriverScore||props.insuranceData.currentPremiumDetails.totalPriceWithDriverScore},null,8,[`money`])])])])]),createBaseVNode(`div`,_hoisted_19$21,[createVNode(unref(bngButton_default),{class:`cancel-button bigger-button`,accent:`custom`,onClick:closePopup},{default:withCtx(()=>[..._cache[6]||=[createTextVNode(` Cancel `,-1)]]),_:1}),createVNode(unref(bngButton_default),{class:`save-button bigger-button`,accent:`custom`,onClick:onSaveClick,disabled:!props.insuranceData.canPayPaperworkFees||!hasChangedCoverageOptions.value},{default:withCtx(()=>[props.insuranceData.canPayPaperworkFees?(openBlock(),createElementBlock(Fragment,{key:1},[_cache[7]||=createTextVNode(` Apply for `,-1),createVNode(unref(bngUnit_default),{money:props.insuranceData.paperworkFees},null,8,[`money`])],64)):(openBlock(),createElementBlock(Fragment,{key:0},[createTextVNode(` Insufficient funds `)],64))]),_:1},8,[`disabled`])])]))}},editPolicy_default=__plugin_vue_export_helper_default(_sfc_main$277,[[`__scopeId`,`data-v-081fecf3`]]),_sfc_main$276={__name:`insurancePerkIcon`,props:{perkIconData:{type:Object,required:!0}},setup(__props){let props=__props,computedColor=computed(()=>props.perkIconData.isSignaturePerk===void 0?props.perkIconData.color:props.perkIconData.isSignaturePerk?`green`:`blue`);return(_ctx,_cache)=>withDirectives((openBlock(),createElementBlock(`div`,{class:normalizeClass({"insurance-perk-icon":!__props.perkIconData.iconOnly,[computedColor.value]:computedColor.value})},[createVNode(unref(bngIcon_default),{type:unref(icons).shieldCheckmark,class:normalizeClass({"glowing-icon":!0,[computedColor.value]:computedColor.value})},null,8,[`type`,`class`]),__props.perkIconData.iconOnly?createCommentVNode(``,!0):(openBlock(),createElementBlock(`span`,{key:0,class:normalizeClass({"small-text":!0,[computedColor.value]:computedColor.value})},toDisplayString(__props.perkIconData.smallText),3))],2)),[[unref(BngTooltip_default),__props.perkIconData.iconOnly?null:__props.perkIconData.tooltipText,`top`]])}},insurancePerkIcon_default=__plugin_vue_export_helper_default(_sfc_main$276,[[`__scopeId`,`data-v-d2b025b6`]]),_hoisted_1$246={class:`insurance-perks-container`},_hoisted_2$203={class:`left`},_hoisted_3$178={class:`insurance-perk-icon-wrapper`},_hoisted_4$151={key:1},_hoisted_5$131={class:`insurance-perk-texts`},_hoisted_6$112={class:`insurance-perk-intro`},_hoisted_7$99={key:0,class:`insurance-perk-description`},_hoisted_8$83={key:0,class:`signature-perk-wrapper`},_sfc_main$275={__name:`insurancePerks`,props:{insuranceData:Object,noDescription:Boolean},setup(__props){let props=__props,sortedPerks=computed(()=>props.insuranceData.perks?[...Array.isArray(props.insuranceData.perks)?props.insuranceData.perks:Object.values(props.insuranceData.perks)].sort((a$1,b)=>Number(b.isSignaturePerk||!1)-Number(a$1.isSignaturePerk||!1)):[]);return(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$246,[(openBlock(!0),createElementBlock(Fragment,null,renderList(sortedPerks.value,perk=>(openBlock(),createElementBlock(`div`,{key:perk.id,class:normalizeClass([`insurance-perk`,{highlighted:perk.isSignaturePerk,"no-insurance":__props.insuranceData.id===-1}])},[createBaseVNode(`div`,_hoisted_2$203,[createBaseVNode(`div`,_hoisted_3$178,[__props.insuranceData.id===-1?(openBlock(),createElementBlock(`span`,_hoisted_4$151,`-`)):(openBlock(),createBlock(insurancePerkIcon_default,{key:0,perkIconData:{iconOnly:!0,isSignaturePerk:perk.isSignaturePerk&&perk.isSignaturePerk||!1}},null,8,[`perkIconData`]))]),createBaseVNode(`div`,_hoisted_5$131,[createBaseVNode(`div`,_hoisted_6$112,toDisplayString(perk.intro),1),__props.noDescription?createCommentVNode(``,!0):(openBlock(),createElementBlock(`div`,_hoisted_7$99,toDisplayString(perk.description),1))])]),perk.isSignaturePerk?(openBlock(),createElementBlock(`div`,_hoisted_8$83,[..._cache[0]||=[createBaseVNode(`div`,{class:`signature-perk`},` SIGNATURE PERK `,-1)]])):createCommentVNode(``,!0)],2))),128))]))}},insurancePerks_default=__plugin_vue_export_helper_default(_sfc_main$275,[[`__scopeId`,`data-v-75e74910`]]),_hoisted_1$245={class:`insurance-perk-notice`},_sfc_main$274={__name:`insurancePerkNotice`,props:{perkText:{type:String,required:!0}},setup(__props){let props=__props;return(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$245,[createVNode(insurancePerkIcon_default,{perkIconData:{iconOnly:!0}}),createTextVNode(` `+toDisplayString(props.perkText),1)]))}},insurancePerkNotice_default=__plugin_vue_export_helper_default(_sfc_main$274,[[`__scopeId`,`data-v-a98b3238`]]),_hoisted_1$244={class:`popup-content`},_hoisted_2$202={class:`top-info`},_hoisted_3$177={class:`top-info-title`},_hoisted_4$150={class:`top-info-veh-name`},_hoisted_5$130={class:`top-info-value-and-insurance`},_hoisted_6$111={class:`section`},_hoisted_7$98={class:`section`},_hoisted_8$82={class:`contribution-wrapper`},_hoisted_9$73={class:`contribution-item-value`},_hoisted_10$63={key:0,class:`price-diff-container`},_hoisted_11$56={class:`contribution-item-value`},_hoisted_12$45={key:0,class:`price-diff-container`},_hoisted_13$38={class:`buttons`},_sfc_main$273={__name:`editVehicleCoverage`,props:{insuranceData:{type:Object,required:!0},vehicleData:{type:Object,required:!0}},emits:[`return`],setup(__props,{emit:__emit}){let props=__props,newPremiumPrice=ref(0),newInsurancePremiumDetails=ref({totalPriceWithDriverScore:0}),computedNewPremiumDiff=computed(()=>newPremiumPrice.value-props.vehicleData.insuranceData.currentPremiumPrice),computedNewInsurancePremiumDiff=computed(()=>newInsurancePremiumDetails.value.totalPriceWithDriverScore-props.insuranceData.currentPremiumDetails.totalPriceWithDriverScore),hasChangedCoverageOptions=computed(()=>props.vehicleData?.insuranceData?.coverageOptionsData?.currentCoverageOptionsSanitized?props.vehicleData.insuranceData.coverageOptionsData.currentCoverageOptionsSanitized.some(option=>changedCoverageOptions.value[option.key]!==option.currentValueId):!1),emit$1=__emit,closePopup=()=>{emit$1(`return`,!0)},changedCoverageOptions=ref({}),updatePremiumPrice=async()=>{newPremiumPrice.value=(await Lua_default.career_modules_insurance_insurance.calculateVehiclePremium(props.vehicleData.id,null,changedCoverageOptions.value)).cost,newInsurancePremiumDetails.value=await Lua_default.career_modules_insurance_insurance.calculateInsurancePremium(props.insuranceData.id,null,{[props.vehicleData.id]:changedCoverageOptions.value})},onChoiceClick=(coverageOption,choice)=>{changedCoverageOptions.value[coverageOption.key]=choice.id,updatePremiumPrice()},onToggleChange=(coverageOption,newValue)=>{let targetChoiceIndex=coverageOption.choices.findIndex(choice=>choice.value===newValue);targetChoiceIndex!==-1&&(changedCoverageOptions.value[coverageOption.key]=targetChoiceIndex+1),updatePremiumPrice()},onSaveClick=()=>{Lua_default.career_modules_insurance_insurance.saveNewVehicleCoverageOptions(props.vehicleData.id,changedCoverageOptions.value),emit$1(`return`,!0)},openSwitchProvider=()=>{addPopup(ChooseInsuranceMain_default,{menuMode:`change`,params:{vehicleId:props.vehicleData.id}})};return onMounted(()=>{props.vehicleData.insuranceData.coverageOptionsData.currentCoverageOptionsSanitized.forEach(option=>{changedCoverageOptions.value[option.key]=option.currentValueId}),updatePremiumPrice()}),(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$244,[createBaseVNode(`div`,_hoisted_2$202,[createBaseVNode(`div`,_hoisted_3$177,[_cache[0]||=createTextVNode(` Select Deductible: `,-1),createBaseVNode(`span`,_hoisted_4$150,toDisplayString(props.vehicleData.name),1)]),createBaseVNode(`div`,_hoisted_5$130,[_cache[1]||=createTextVNode(` Value: `,-1),createVNode(unref(bngUnit_default),{money:props.vehicleData.initialValue},null,8,[`money`]),createTextVNode(` • Policy: `+toDisplayString(props.insuranceData.name),1)]),_cache[2]||=createBaseVNode(`div`,{class:`top-info-description`},` Choose how much you'll pay out-of-pocket when repairing this vehicle. Lower deductibles cost more per km. `,-1)]),createBaseVNode(`div`,_hoisted_6$111,[_cache[3]||=createBaseVNode(`div`,null,[createBaseVNode(`div`,{class:`header title`},` Choose Your Deductible `),createBaseVNode(`div`,{class:`under-title`},` You pay this amount per repair. `)],-1),createBaseVNode(`div`,null,[(openBlock(!0),createElementBlock(Fragment,null,renderList(props.vehicleData.insuranceData.coverageOptionsData.currentCoverageOptionsSanitized,coverageOption=>(openBlock(),createBlock(unref(coverageOption_default),{class:`coverage-option`,key:coverageOption.name,coverageOption,onlyShowMainText:!0,changedCoverageOptions:changedCoverageOptions.value,dontShowName:!0,onChoiceClick,onToggleChange},null,8,[`coverageOption`,`changedCoverageOptions`]))),128))])]),createBaseVNode(`div`,_hoisted_7$98,[_cache[6]||=createBaseVNode(`div`,{class:`title`},` Policy Impact `,-1),createBaseVNode(`div`,_hoisted_8$82,[createBaseVNode(`div`,{class:normalizeClass([`contribution-item`,{green:computedNewInsurancePremiumDiff.value<0,red:computedNewInsurancePremiumDiff.value>0}])},[_cache[4]||=createBaseVNode(`div`,{class:`contribution-item-title`},` Insurance Premium `,-1),createBaseVNode(`div`,_hoisted_9$73,[createVNode(unref(bngUnit_default),{money:props.insuranceData.currentPremiumDetails.totalPriceWithDriverScore},null,8,[`money`]),computedNewInsurancePremiumDiff.value!==0&&!isNaN(computedNewInsurancePremiumDiff.value)?(openBlock(),createElementBlock(`div`,_hoisted_10$63,` → `)):createCommentVNode(``,!0),computedNewInsurancePremiumDiff.value!==0&&!isNaN(computedNewInsurancePremiumDiff.value)?(openBlock(),createBlock(unref(bngUnit_default),{key:1,money:newInsurancePremiumDetails.value.totalPriceWithDriverScore},null,8,[`money`])):createCommentVNode(``,!0)])],2),createBaseVNode(`div`,{class:normalizeClass([`contribution-item`,{green:computedNewInsurancePremiumDiff.value<0,red:computedNewInsurancePremiumDiff.value>0}])},[_cache[5]||=createBaseVNode(`div`,{class:`contribution-item-title`},` Vehicle Contribution `,-1),createBaseVNode(`div`,_hoisted_11$56,[createVNode(unref(bngUnit_default),{money:props.vehicleData.insuranceData.currentPremiumPrice},null,8,[`money`]),computedNewPremiumDiff.value!==0&&!isNaN(computedNewPremiumDiff.value)?(openBlock(),createElementBlock(`div`,_hoisted_12$45,` → `)):createCommentVNode(``,!0),computedNewPremiumDiff.value!==0&&!isNaN(computedNewPremiumDiff.value)?(openBlock(),createBlock(unref(bngUnit_default),{key:1,money:newPremiumPrice.value},null,8,[`money`])):createCommentVNode(``,!0)])],2)])]),createBaseVNode(`div`,_hoisted_13$38,[createVNode(unref(bngButton_default),{class:`gray-button bigger-button`,accent:`custom`,onClick:closePopup},{default:withCtx(()=>[..._cache[7]||=[createTextVNode(` Cancel `,-1)]]),_:1}),createVNode(unref(bngButton_default),{class:`save-button bigger-button`,accent:`custom`,onClick:onSaveClick,disabled:!props.insuranceData.canPayPaperworkFees||!hasChangedCoverageOptions.value},{default:withCtx(()=>[props.insuranceData.canPayPaperworkFees?(openBlock(),createElementBlock(Fragment,{key:1},[_cache[8]||=createTextVNode(` Apply for `,-1),createVNode(unref(bngUnit_default),{money:props.insuranceData.paperworkFees},null,8,[`money`])],64)):(openBlock(),createElementBlock(Fragment,{key:0},[createTextVNode(` Insufficient funds `)],64))]),_:1},8,[`disabled`]),createVNode(unref(bngButton_default),{class:`gray-button bigger-button`,accent:`custom`,onClick:openSwitchProvider},{default:withCtx(()=>[..._cache[9]||=[createTextVNode(` Switch Provider `,-1)]]),_:1})])]))}},editVehicleCoverage_default=__plugin_vue_export_helper_default(_sfc_main$273,[[`__scopeId`,`data-v-9f014d2d`]]),_hoisted_1$243=[`innerHTML`],_hoisted_2$201={key:2,class:`insurance-icon`},_hoisted_3$176={class:`insurance-name`},_hoisted_4$149={key:3,class:`insurance-slogan`},_sfc_main$272={__name:`insuranceIdentity`,props:{insuranceData:{type:Object,required:!0}},setup(__props){let props=__props,hasInsurance=computed(()=>svgContent.value||props.insuranceData.image),hasNoInsurance=computed(()=>props.insuranceData?.id===-1),svgContent=ref(null);return watch(()=>props.insuranceData.image,async newPath=>{if(newPath&&newPath.endsWith(`.svg`))try{let rawSvg=await getFile(`/${newPath}`);rawSvg?svgContent.value=rawSvg.replace(/]*>([\s\S]*?)<\/script>/gim,``).replace(/ on\w+="[^"]*"/g,``):svgContent.value=null}catch(e){console.warn(`Failed to load SVG inline:`,newPath,e),svgContent.value=null}else svgContent.value=null},{immediate:!0}),(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,{class:normalizeClass([`insurance-identity`,{"no-insurance":!hasInsurance.value}])},[svgContent.value?(openBlock(),createElementBlock(`div`,{key:0,class:`insurance-icon`,innerHTML:svgContent.value},null,8,_hoisted_1$243)):props.insuranceData.image?(openBlock(),createBlock(unref(bngImage_default),{key:1,class:`insurance-icon`,src:`/${props.insuranceData.image}`,alt:props.insuranceData.name},null,8,[`src`,`alt`])):(openBlock(),createElementBlock(`div`,_hoisted_2$201,[createBaseVNode(`div`,_hoisted_3$176,[createVNode(unref(bngIcon_default),{class:`insurance-no-icon`,type:unref(icons).danger},null,8,[`type`]),createTextVNode(` `+toDisplayString(hasNoInsurance.value?_ctx.$t(`ui.career.insurance.noInsurance`):props.insuranceData.name),1)])])),hasNoInsurance.value?createCommentVNode(``,!0):(openBlock(),createElementBlock(`div`,_hoisted_4$149,` "`+toDisplayString(props.insuranceData.slogan)+`" `,1))],2))}},insuranceIdentity_default=__plugin_vue_export_helper_default(_sfc_main$272,[[`__scopeId`,`data-v-689b89ea`]]),_hoisted_1$242={key:1,class:`coverage-option-name`},_hoisted_2$200={key:2,class:`choices`},_hoisted_3$175=[`onClick`],_hoisted_4$148={class:`choice-label`},_hoisted_5$129={key:0},_hoisted_6$110={key:0,class:`choice-secondary-text`},_hoisted_7$97={key:1,class:`choice-price`},_hoisted_8$81={key:3,class:`toggle-container`},_hoisted_9$72={class:`toggle-price`},_sfc_main$271={__name:`coverageOption`,props:{coverageOption:{type:Object,required:!0},changedCoverageOptions:{type:Object,required:!1,default:()=>({})},onlyShowMainText:{type:Boolean,default:!1},simpleSelect:{type:Boolean},modelValue:{type:Number,required:!1},showPerkMode:{type:String,default:`deportedLabel`},dontShowName:{type:Boolean,default:!1}},emits:[`choiceClick`,`toggleChange`,`update:modelValue`],setup(__props,{emit:__emit}){let props=__props,emit$1=__emit;watch(()=>props.coverageOption?.choices,newChoices=>{if(props.modelValue!==void 0&&props.modelValue!==null&&newChoices){let maxValidId=newChoices.length;props.modelValue>maxValidId&&emit$1(`update:modelValue`,1)}},{immediate:!0});let getSelectedValueId=()=>props.modelValue!==void 0&&props.modelValue!==null?Math.min(props.modelValue,props.coverageOption.choices.length):props.changedCoverageOptions[props.coverageOption.key],getToggleValue=coverageOption=>(props.changedCoverageOptions[coverageOption.key]??coverageOption.currentValueId)===coverageOption.choices.findIndex(choice=>choice.value===!0)+1,getTogglePrice=coverageOption=>{let selectedValueId=props.changedCoverageOptions[coverageOption.key]??coverageOption.currentValueId;return coverageOption.choices[selectedValueId-1]?.premiumInfluence||0},onToggleChange=(coverageOption,newValue)=>{emit$1(`toggleChange`,coverageOption,newValue)},onChoiceClick=(coverageOption,choice)=>{choice.disabled||(props.simpleSelect&&(coverageOption.currentValueId=choice.id),props.modelValue!==void 0&&props.modelValue!==null&&emit$1(`update:modelValue`,choice.id),emit$1(`choiceClick`,coverageOption,choice))};return(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,{class:normalizeClass([`coverage-options`,{"in-row":__props.coverageOption.choiceType===`toggle`}])},[__props.coverageOption.perkText&&__props.showPerkMode===`deportedLabel`?(openBlock(),createBlock(unref(insurancePerkNotice_default),{key:0,perkText:__props.coverageOption.perkText},null,8,[`perkText`])):createCommentVNode(``,!0),__props.dontShowName?createCommentVNode(``,!0):(openBlock(),createElementBlock(`div`,_hoisted_1$242,toDisplayString(__props.coverageOption.name),1)),__props.coverageOption.choiceType===`multiple`?(openBlock(),createElementBlock(`div`,_hoisted_2$200,[(openBlock(!0),createElementBlock(Fragment,null,renderList(__props.coverageOption.choices,choice=>(openBlock(),createElementBlock(`div`,{class:normalizeClass([`choice`,{selected:choice.id===__props.changedCoverageOptions[__props.coverageOption.key],current:choice.id===getSelectedValueId(),disabled:choice.disabled}]),key:choice,onClick:()=>onChoiceClick(__props.coverageOption,choice)},[createBaseVNode(`div`,_hoisted_4$148,toDisplayString(choice.choiceText),1),__props.onlyShowMainText?createCommentVNode(``,!0):(openBlock(),createElementBlock(`div`,_hoisted_5$129,[choice.secondaryText?(openBlock(),createElementBlock(`div`,_hoisted_6$110,toDisplayString(choice.secondaryText),1)):(openBlock(),createElementBlock(`div`,_hoisted_7$97,[createVNode(unref(bngUnit_default),{money:choice.premiumInfluence},null,8,[`money`])]))]))],10,_hoisted_3$175))),128))])):__props.coverageOption.choiceType===`toggle`?(openBlock(),createElementBlock(`div`,_hoisted_8$81,[createVNode(unref(bngSwitch_default),{class:`toggle-switch`,"model-value":getToggleValue(__props.coverageOption),onChange:_cache[0]||=newValue=>onToggleChange(__props.coverageOption,newValue)},null,8,[`model-value`]),createBaseVNode(`div`,_hoisted_9$72,[createVNode(unref(bngUnit_default),{money:getTogglePrice(__props.coverageOption)},null,8,[`money`])])])):createCommentVNode(``,!0)],2))}},coverageOption_default=__plugin_vue_export_helper_default(_sfc_main$271,[[`__scopeId`,`data-v-4921f4f0`]]),_hoisted_1$241={class:`popup-content`},_hoisted_2$199={class:`popup-header`},_hoisted_3$174={class:`top-info`},_hoisted_4$147={class:`top-info-title`},_hoisted_5$128={class:`top-info-policy-name`},_hoisted_6$109={class:`top-info-description`},_hoisted_7$96={class:`vehicle-list`},_hoisted_8$80={class:`closeButton`},_sfc_main$270={__name:`vehicleInsuranceList`,props:{insuranceData:{type:Object,required:!0},driverScoreData:{type:Object,required:!0}},emits:[`return`],setup(__props,{emit:__emit}){let props=__props,emit$1=__emit,closePopup=()=>{emit$1(`return`,!0)},openEditVehicleCoverage=vehicle=>{addPopup(editVehicleCoverage_default,{insuranceData:props.insuranceData,vehicleData:vehicle})},openEditPolicy=()=>{addPopup(editPolicy_default,{insuranceData:props.insuranceData,driverScoreData:props.driverScoreData}),closePopup()};return(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$241,[createBaseVNode(`div`,_hoisted_2$199,[createBaseVNode(`div`,_hoisted_3$174,[createBaseVNode(`div`,_hoisted_4$147,[_cache[0]||=createTextVNode(` Vehicles Insured By `,-1),createBaseVNode(`span`,_hoisted_5$128,toDisplayString(props.insuranceData.name),1)]),createBaseVNode(`div`,_hoisted_6$109,[_cache[1]||=createTextVNode(` Click any vehicle to adjust its deductible • Total Value: `,-1),createVNode(unref(bngUnit_default),{money:props.insuranceData.totalInsuranceVehsValue},null,8,[`money`])])]),createVNode(unref(bngButton_default),{class:`policy-coverage-button`,accent:`custom`,onClick:openEditPolicy},{default:withCtx(()=>[..._cache[2]||=[createTextVNode(` Policy Coverage `,-1)]]),_:1})]),createBaseVNode(`div`,_hoisted_7$96,[(openBlock(!0),createElementBlock(Fragment,null,renderList(props.insuranceData.carsInsured,(vehicle,index)=>(openBlock(),createBlock(unref(insuranceVehTile_default),{key:index,vehicle},{rightContent:withCtx(()=>[createVNode(unref(bngButton_default),{class:`edit-coverage-button bigger-button`,accent:`custom`,disabled:vehicle.needsRepair,onClick:$event=>!vehicle.needsRepair&&openEditVehicleCoverage(vehicle)},{default:withCtx(()=>[createTextVNode(toDisplayString(vehicle.needsRepair?`Edit Coverage (Needs repair)`:`Edit Coverage`),1)]),_:2},1032,[`disabled`,`onClick`])]),_:2},1032,[`vehicle`]))),128))]),createBaseVNode(`div`,_hoisted_8$80,[createVNode(unref(bngButton_default),{class:`close-button`,accent:`custom`,onClick:closePopup},{default:withCtx(()=>[..._cache[3]||=[createTextVNode(` Cancel `,-1)]]),_:1})])]))}},vehicleInsuranceList_default=__plugin_vue_export_helper_default(_sfc_main$270,[[`__scopeId`,`data-v-2bd92225`]]),_hoisted_1$240={class:`vehicle-item`},_hoisted_2$198={class:`left`},_hoisted_3$173={class:`vehicle-thumbnail-wrapper`},_hoisted_4$146=[`src`],_hoisted_5$127={class:`name-value-wrapper`},_hoisted_6$108={class:`vehicle-name`},_hoisted_7$95={class:`vehicle-value`},_hoisted_8$79={class:`right`},_sfc_main$269={__name:`insuranceVehTile`,props:{vehicle:{type:Object,required:!0}},setup(__props){return(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$240,[createBaseVNode(`div`,_hoisted_2$198,[createBaseVNode(`div`,_hoisted_3$173,[createBaseVNode(`img`,{src:__props.vehicle.thumbnail,alt:``,class:`vehicle-thumbnail`},null,8,_hoisted_4$146)]),createBaseVNode(`div`,_hoisted_5$127,[createBaseVNode(`div`,_hoisted_6$108,toDisplayString(__props.vehicle.name),1),createBaseVNode(`div`,_hoisted_7$95,[_cache[0]||=createTextVNode(`Value : `,-1),createVNode(unref(bngUnit_default),{money:__props.vehicle.initialValue},null,8,[`money`])]),renderSlot(_ctx.$slots,`extra-info`,{},void 0,!0)])]),createBaseVNode(`div`,_hoisted_8$79,[renderSlot(_ctx.$slots,`rightContent`,{},void 0,!0)])]))}},insuranceVehTile_default=__plugin_vue_export_helper_default(_sfc_main$269,[[`__scopeId`,`data-v-b4076016`]]),_hoisted_1$239={class:`popup-content`},_hoisted_2$197={key:0,class:`vehicle-list`},_hoisted_3$172={key:1,class:`no-vehicles-wrapper`},_hoisted_4$145={class:`closeButton`},_sfc_main$268={__name:`uninsuredVehicles`,props:{uninsuredData:{type:Object,required:!0}},emits:[`return`],setup(__props,{emit:__emit}){let props=__props,emit$1=__emit,closePopup=()=>{emit$1(`return`,!0)},openAddCoverage=vehicle=>{addPopup(ChooseInsuranceMain_default,{menuMode:`change`,params:{vehicleId:vehicle.id}})};return(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$239,[_cache[5]||=createBaseVNode(`div`,{class:`popup-header`},[createBaseVNode(`span`,{class:`header-title`},`Uninsured Vehicles`)],-1),_cache[6]||=createBaseVNode(`div`,{class:`warning-message`},` These vehicles have no insurance coverage. Add coverage to protect against repair costs. `,-1),props.uninsuredData.carsUninsured&&props.uninsuredData.carsUninsured.length>0?(openBlock(),createElementBlock(`div`,_hoisted_2$197,[(openBlock(!0),createElementBlock(Fragment,null,renderList(props.uninsuredData.carsUninsured,(vehicle,index)=>(openBlock(),createBlock(unref(insuranceVehTile_default),{key:index,vehicle,class:`uninsured-vehicle-item`},{"extra-info":withCtx(()=>[..._cache[0]||=[createBaseVNode(`div`,{class:`no-coverage-warning`},` No coverage - you pay full repair costs `,-1)]]),rightContent:withCtx(()=>[createVNode(unref(bngButton_default),{class:`add-coverage-button bigger-button`,accent:`custom`,onClick:$event=>openAddCoverage(vehicle)},{default:withCtx(()=>[createVNode(unref(bngIcon_default),{class:`button-icon`,type:unref(icons).shieldCheckmark},null,8,[`type`]),_cache[1]||=createTextVNode(` Add Coverage `,-1)]),_:1},8,[`onClick`])]),_:2},1032,[`vehicle`]))),128))])):(openBlock(),createElementBlock(`div`,_hoisted_3$172,[createVNode(unref(bngIcon_default),{class:`success-icon`,type:unref(icons).checkmark},null,8,[`type`]),_cache[2]||=createBaseVNode(`div`,{class:`success-title`},`All Vehicles Insured`,-1),_cache[3]||=createBaseVNode(`div`,{class:`success-message`},`You don't have any uninsured vehicles.`,-1)])),createBaseVNode(`div`,_hoisted_4$145,[createVNode(unref(bngButton_default),{class:`close-button`,accent:`custom`,onClick:closePopup},{default:withCtx(()=>[..._cache[4]||=[createTextVNode(` Back `,-1)]]),_:1})])]))}},uninsuredVehicles_default=__plugin_vue_export_helper_default(_sfc_main$268,[[`__scopeId`,`data-v-f51ead8e`]]),sharedMode=ref(null),sharedContext=ref(null);function useChooseInsurance(){let{events:events$3}=useBridge(),insurancesData=ref([]),purchaseData=ref({}),vehicleInfo=ref({}),defaultInsuranceId=ref(null),firstSelectedInsuranceId=ref(null),driverScoreData=ref({}),currentInsuranceId=ref(null),handleChooseInsuranceData=data=>{insurancesData.value=data.applicableInsurancesData,purchaseData.value=data.purchaseData,vehicleInfo.value=data.vehicleInfo,driverScoreData.value=data.driverScoreData,defaultInsuranceId.value=data.defaultInsuranceId,firstSelectedInsuranceId.value=data.defaultInsuranceId,currentInsuranceId.value=data.currentInsuranceId};function openChooseInsuranceMenu(menuMode,params){sharedMode.value=menuMode,sharedContext.value=params,Lua_default.career_modules_insurance_insurance.openChooseInsuranceScreen()}function requestDataForCurrentContext(){sharedMode.value===`purchase`&&sharedContext.value?Lua_default.career_modules_insurance_insurance.sendChooseInsuranceDataToTheUI(sharedContext.value.purchaseType,sharedContext.value.shopId,sharedContext.value.insuranceId):sharedMode.value===`change`&&sharedContext.value&&Lua_default.career_modules_insurance_insurance.sendChangeInsuranceDataToTheUI(sharedContext.value.vehicleId)}return events$3.on(`chooseInsuranceData`,handleChooseInsuranceData),onUnmounted(()=>{events$3.off(`chooseInsuranceData`,handleChooseInsuranceData)}),{openChooseInsuranceMenu,requestDataForCurrentContext,insurancesData,purchaseData,vehicleInfo,defaultInsuranceId,firstSelectedInsuranceId,driverScoreData,currentInsuranceId,mode:sharedMode,context:sharedContext}}var _hoisted_1$238={class:`popup-content`},_hoisted_2$196={class:`popup-header`},_hoisted_3$171={class:`content-wrapper`},_hoisted_4$144={class:`buttons-wrapper`},_hoisted_5$126={class:`button-container`},_sfc_main$267={__name:`ChooseInsuranceMain`,props:{menuMode:{type:String,required:!0},params:{type:Object,required:!0}},emits:[`return`],setup(__props,{emit:__emit}){useUINavBlocker().ensureNoBlock([`tab_l`,`tab_r`]);let overflowRef=ref(null),onTabNav=evt=>{evt.detail.value===1&&(console.log(`onTabNav`,evt.detail),console.log(`overflowRef`,overflowRef.value),evt.detail.name===`tab_l`&&overflowRef.value?.activatePrev(),evt.detail.name===`tab_r`&&overflowRef.value?.activateNext())},props=__props,emit$1=__emit,{units}=useBridge(),selectedInsuranceId=ref(null),selectedShelfIndex=ref(0),{insurancesData,purchaseData,defaultInsuranceId,firstSelectedInsuranceId,vehicleInfo,requestDataForCurrentContext,mode,context,driverScoreData,currentInsuranceId}=useChooseInsurance();onMounted(()=>{window.addEventListener(DOM_UI_NAVIGATION_EVENT,onTabNav),mode.value=props.menuMode,context.value=props.params,props.menuMode===`purchase`&&props.params?Lua_default.career_modules_insurance_insurance.sendChooseInsuranceDataToTheUI(props.params.purchaseType,props.params.shopId,props.params.insuranceId):props.menuMode===`change`&&props.params&&Lua_default.career_modules_insurance_insurance.sendChangeInsuranceDataToTheUI(props.params.vehicleId)}),watch(selectedShelfIndex,newIndex=>{insurancesData.value[newIndex]&&(selectedInsuranceId.value=insurancesData.value[newIndex].id)}),watch(defaultInsuranceId,defaultId=>{if(defaultId!==null){selectedInsuranceId.value=defaultId;let index=insurancesData.value.findIndex(ins=>ins.id===defaultId);index!==-1&&(selectedShelfIndex.value=index)}},{immediate:!0});let onShelfClick=(insuranceId,index)=>{selectedInsuranceId.value=insuranceId,selectedShelfIndex.value=index},buttonText=computed(()=>mode.value===`change`?selectedInsuranceId.value===-1?`Remove Coverage`:selectedInsuranceId.value===currentInsuranceId.value?`Current Provider`:`Move vehicle here`:`Select this option`),viewCostBreakdown=()=>{mode.value===`purchase`?addPopup(purchaseInsuranceDetails_default,{insuranceData:insurancesData.value[selectedShelfIndex.value],vehicleInfo:vehicleInfo.value,driverScoreData:driverScoreData.value}):addPopup(changeInsuranceDetails_default,{insuranceData:insurancesData.value[selectedShelfIndex.value],vehicleInfo:vehicleInfo.value,driverScoreData:driverScoreData.value})},continueWithInsurance=()=>{mode.value===`purchase`?(selectedInsuranceId.value!==null&&selectedInsuranceId.value!==void 0&&Lua_default.career_modules_vehicleShopping.updateInsuranceSelection(selectedInsuranceId.value),emit$1(`return`,!0)):mode.value===`change`&&(selectedInsuranceId.value&&context.value?.vehicleId&&Lua_default.career_modules_insurance_insurance.changeInvVehInsurance(context.value.vehicleId,selectedInsuranceId.value),closeLastPopups(3))},cancel=()=>{emit$1(`return`,!0)};return onUnmounted(()=>{window.removeEventListener(DOM_UI_NAVIGATION_EVENT,onTabNav),mode.value=null,context.value=null}),(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$238,[createBaseVNode(`div`,_hoisted_2$196,[createVNode(unref(bngCardHeading_default),{type:`ribbon`},{default:withCtx(()=>[createTextVNode(toDisplayString(unref(mode)===`purchase`?`Insure your `:`Switch insurance for your `)+` `+toDisplayString(unref(vehicleInfo).Name),1)]),_:1})]),createBaseVNode(`div`,_hoisted_3$171,[createVNode(unref(bngOverflowContainer_default),{ref_key:`overflowRef`,ref:overflowRef,class:`insurance-shelf`,"scroll-speed":10,"initial-index":selectedShelfIndex.value,"use-bindings-only":``,"show-arrows":``,"no-wheel":``},{default:withCtx(()=>[(openBlock(!0),createElementBlock(Fragment,null,renderList(unref(insurancesData),(insurance,index)=>(openBlock(),createBlock(unref(insuranceCard_default),{key:insurance.id,insuranceData:insurance,isSelected:selectedInsuranceId.value===insurance.id,vehicleInfo:unref(vehicleInfo),isCurrentProvider:unref(mode)===`change`&&unref(currentInsuranceId)===insurance.id,class:`insurance-card`,onClick:$event=>onShelfClick(insurance.id,index)},null,8,[`insuranceData`,`isSelected`,`vehicleInfo`,`isCurrentProvider`,`onClick`]))),128))]),_:1},8,[`initial-index`])]),createBaseVNode(`div`,_hoisted_4$144,[createBaseVNode(`div`,_hoisted_5$126,[createVNode(unref(bngButton_default),{onClick:cancel,accent:unref(ACCENTS).attention},{default:withCtx(()=>[..._cache[0]||=[createTextVNode(`Cancel`,-1)]]),_:1},8,[`accent`]),createVNode(unref(bngButton_default),{onClick:viewCostBreakdown,disabled:selectedShelfIndex.value===0||unref(mode)===`change`&&selectedInsuranceId.value===unref(currentInsuranceId),accent:unref(ACCENTS).secondary},{default:withCtx(()=>[..._cache[1]||=[createTextVNode(`View Cost Breakdown`,-1)]]),_:1},8,[`disabled`,`accent`]),createVNode(unref(bngButton_default),{disabled:!selectedInsuranceId.value||unref(mode)===`change`&&selectedInsuranceId.value===unref(currentInsuranceId),onClick:continueWithInsurance},{default:withCtx(()=>[createTextVNode(toDisplayString(buttonText.value),1)]),_:1},8,[`disabled`])])])]))}},ChooseInsuranceMain_default=__plugin_vue_export_helper_default(_sfc_main$267,[[`__scopeId`,`data-v-7bb3e442`]]),_hoisted_1$237={class:`progress-view-actions`},_hoisted_2$195={class:`progress-view-page`},_hoisted_3$170={class:`progress-view-header`},_hoisted_4$143={class:`branch-icon-assembly large`},_hoisted_5$125={key:0,class:`reward-multiplier`},_hoisted_6$107={class:`reward-multiplier-label`},_hoisted_7$94={class:`reward-multiplier-value`},_hoisted_8$78={class:`progress-view-contents`},_hoisted_9$71={class:`progress-view-description`},_hoisted_10$62={class:`progress-view-scrollable`},_sfc_main$266={__name:`ProgressView`,props:{skillInfo:{type:Object,default:null},headingText:{type:String,default:``},breadcrumbItems:{type:Array,required:!0},branchStyle:{type:Object,required:!0},showBackButton:{type:Boolean,default:!0}},emits:[`breadcrumb-click`,`breadcrumb-back`,`exit`,`skill-click`],setup(__props,{emit:__emit}){let emit$1=__emit,handleBreadcrumbClick=item=>{emit$1(`breadcrumb-click`,item)},handleBreadcrumbBack=()=>{emit$1(`breadcrumb-back`)},handleExit=()=>{emit$1(`exit`)};return(_ctx,_cache)=>withDirectives((openBlock(),createBlock(unref(layoutSingle_default),{class:`progress-view-layout`},{default:withCtx(()=>[withDirectives((openBlock(),createElementBlock(`div`,{class:`progress-view-wrapper`,style:normalizeStyle(__props.branchStyle),"bng-ui-scope":`progressView`},[createBaseVNode(`div`,_hoisted_1$237,[createVNode(unref(bngBreadcrumbs_default),{class:`progress-view-breadcrumbs`,items:__props.breadcrumbItems,limit:`5`,simple:``,"disable-last-item":``,"show-back-button":__props.showBackButton,onClick:handleBreadcrumbClick,onBack:handleBreadcrumbBack},null,8,[`items`,`show-back-button`]),createVNode(unref(careerStatus_default),{class:`progress-view-career-status`,slim:``})]),createBaseVNode(`div`,_hoisted_2$195,[createBaseVNode(`div`,_hoisted_3$170,[__props.skillInfo?(openBlock(),createElementBlock(Fragment,{key:0},[createBaseVNode(`div`,{class:normalizeClass([`header-skill`,{"is-locked":!__props.skillInfo.unlocked}]),onClick:_cache[0]||=$event=>_ctx.$emit(`skill-click`,__props.skillInfo.id)},[createBaseVNode(`div`,_hoisted_4$143,[createBaseVNode(`div`,{class:`branch-background`,style:normalizeStyle(unref(getIconBackgroundStyle)(__props.skillInfo.color))},null,4),createVNode(unref(bngIcon_default),{type:unref(icons)[__props.skillInfo.unlocked?__props.skillInfo.icon:`lockClosed`],class:`assembly-icon large`},null,8,[`type`])]),createVNode(BranchSkillProgressBar_default,{class:`main-stat-progress-bar skill-progress-bar`,skill:__props.skillInfo,showLevel:!1,mode:`with-value-label`,showLockedIcon:!0,isMainProgress:!0},null,8,[`skill`])],2),__props.skillInfo.rewardMultiplier?(openBlock(),createElementBlock(`div`,_hoisted_5$125,[createBaseVNode(`div`,_hoisted_6$107,[createVNode(unref(bngIcon_default),{type:__props.skillInfo.rewardMultiplierSourceIcon},null,8,[`type`]),_cache[1]||=createTextVNode(` Reward Multiplier: `,-1)]),createBaseVNode(`div`,_hoisted_7$94,[createVNode(unref(bngIcon_default),{type:unref(icons).beamCurrency},null,8,[`type`]),createTextVNode(` ×`+toDisplayString(__props.skillInfo.rewardMultiplier.toFixed(2)),1)])])):createCommentVNode(``,!0)],64)):(openBlock(),createBlock(unref(bngScreenHeadingV2_default),{key:1,type:`2`,class:`header-title-v2`},{default:withCtx(()=>[createTextVNode(toDisplayString(__props.headingText),1)]),_:1}))]),createBaseVNode(`div`,_hoisted_8$78,[createBaseVNode(`div`,_hoisted_9$71,[renderSlot(_ctx.$slots,`description`,{},void 0,!0)]),_cache[2]||=createBaseVNode(`div`,{class:`progress-view-divider`},null,-1),createBaseVNode(`div`,_hoisted_10$62,[renderSlot(_ctx.$slots,`default`,{},void 0,!0)])])])],4)),[[unref(BngOnUiNav_default),handleExit,`back,menu`]])]),_:3})),[[unref(BngOnUiNav_default),handleExit,`back,menu`],[unref(BngBlur_default)]])}},ProgressView_default=__plugin_vue_export_helper_default(_sfc_main$266,[[`__scopeId`,`data-v-3fa921dc`]]),_hoisted_1$236={class:`description-text`},_hoisted_2$194={key:0,class:`cards-container grid-view`},_hoisted_3$169={key:1,class:`page-progress`},_hoisted_4$142={key:2,class:`facility-rows`},_hoisted_5$124={key:3,class:`buttons-container`},_hoisted_6$106={class:`content`},_hoisted_7$93={key:0,class:`indicator`},_sfc_main$265={__name:`ProgressLanding`,props:{pathId:String,comesFromBigMap:{type:Boolean,default:!1}},setup(__props){let props=__props,landingData=ref({heading:`ui.career.landingPage.name`,description:`ui.career.landingPage.description`,branches:[],showMilestones:!0,showOrganizations:!0}),leagues=ref([]),fetchLandingData=async()=>{landingData.value={heading:`ui.career.landingPage.name`,description:`ui.career.landingPage.description`,branches:[],showMilestones:!0,showOrganizations:!0};let data=await Lua_default.career_modules_branches_landing.getLandingPageData(props.pathId);landingData.value=data,leagues.value=data.leagues||[],console.log(`data`,data),data.breadcrumbs&&(screenHeaderPath.value=data.breadcrumbs,console.log(`screenHeaderPath`,screenHeaderPath.value))},hasUnclaimedMilestones=ref(!1);onMounted(async()=>{await fetchLandingData(),Lua_default.career_modules_milestones_milestones.unclaimedMilestonesCount().then(c=>hasUnclaimedMilestones.value=c)}),onBeforeMount(()=>{Lua_default.simTimeAuthority.pushPauseRequest(`progressLanding`)}),onUnmounted(()=>{Lua_default.simTimeAuthority.popPauseRequest(`progressLanding`)}),watch(()=>props.pathId,async(newPathId,oldPathId)=>{newPathId!==oldPathId&&(await fetchLandingData(),Lua_default.career_modules_milestones_milestones.unclaimedMilestonesCount().then(c=>hasUnclaimedMilestones.value=c))});let leagueMissionClicked=mission=>{mission.canStartFromProgressScreen?(Lua_default.extensions.gameplay_missions_missionScreen.setPreselectedMissionId(mission.id),Lua_default.extensions.gameplay_missions_missionScreen.openAPMChallenges(props.pathId,mission.skill[0])):Lua_default.extensions.gameplay_missions_missionScreen.navigateToMission(mission.id)},branchStyle=computed(()=>landingData.value.skillInfo?getBranchColorStyle({color:landingData.value.skillInfo.color,accentColor:landingData.value.skillInfo.accentColor}):{"--branch-accent-color":`var(--bng-cool-gray-500-rgb)`,"--branch-color":`var(--bng-cool-gray-500-rgb)`}),pageHeading=computed(()=>landingData.value.branchHeading||landingData.value.heading),currentDescription=ref(null),pageDescription=computed(()=>currentDescription.value||landingData.value.description),BRANCHES=computed(()=>landingData.value.branches),openBranchPage=branchKey=>{let target=landingData.value.branches.find(b=>b.id===branchKey).target;console.log(`openBranchPage`,branchKey),window.bngVue.gotoGameState(`progressLanding`,{params:{pathId:branchKey}})},exit=()=>{props.pathId&&!props.comesFromBigMap?router_default.back():window.bngVue.gotoAngularState(`menu.careerPause`)},openMilestonesScreen=()=>window.bngVue.gotoGameState(`milestones`),onBranchFocus=branch=>{currentDescription.value=branch.description},onBranchBlur=()=>{currentDescription.value=null},isHalfBranch=branch=>{let hasSkills=branch.skills&&branch.skills.length>0,hasDescription=branch.shortDescription;return!hasSkills&&!hasDescription},currentSkillToShow=computed(()=>landingData.value.skillInfo||null),screenHeaderPath=ref([{label:`Career`,path:`/career`},{label:landingData.value.heading,path:`/career/${landingData.value.id}`}]),gotoHeaderItem=item=>{item.gotoPath&&(window.bngVue.gotoGameState(item.gotoPath.path,{params:item.gotoPath.props}),console.log(`gotoPath`,item.gotoPath)),item.gotoAngularState&&window.bngVue.gotoAngularState(item.gotoAngularState)},onBreadBack=()=>{gotoHeaderItem(screenHeaderPath.value[screenHeaderPath.value.length-2])};return(_ctx,_cache)=>(openBlock(),createBlock(ProgressView_default,{"skill-info":landingData.value.skillInfo,"heading-text":_ctx.$t(pageHeading.value),"breadcrumb-items":screenHeaderPath.value,"branch-style":branchStyle.value,"show-back-button":!0,onBreadcrumbClick:gotoHeaderItem,onBreadcrumbBack:onBreadBack,onExit:exit},{description:withCtx(()=>[createBaseVNode(`div`,_hoisted_1$236,toDisplayString(_ctx.$t(pageDescription.value)),1)]),default:withCtx(()=>[BRANCHES.value.length>0?(openBlock(),createElementBlock(`div`,_hoisted_2$194,[(openBlock(!0),createElementBlock(Fragment,null,renderList(BRANCHES.value,branch=>withDirectives((openBlock(),createBlock(BranchSkillCard_default,{tabindex:`1`,branchKey:branch.id,onOpenBranchPage:openBranchPage,onMouseenter:$event=>onBranchFocus(branch),onMouseleave:onBranchBlur,onFocus:$event=>onBranchFocus(branch),onBlur:onBranchBlur,"bng-nav-item":``,"display-mode":`row`,class:normalizeClass({"full-width":!isHalfBranch(branch)})},null,8,[`branchKey`,`onMouseenter`,`onFocus`,`class`])),[[unref(BngSoundClass_default),`bng_click_hover_generic`]])),256))])):createCommentVNode(``,!0),currentSkillToShow.value&¤tSkillToShow.value.hasLevels&¤tSkillToShow.value.unlockInfo&¤tSkillToShow.value.unlockInfo.length?(openBlock(),createElementBlock(`div`,_hoisted_3$169,[currentSkillToShow.value.hasUnlocks?(openBlock(),createBlock(UnlockRows_default,{key:0,class:`stat-progress-bar bng-progress-bar progress-bar`,headerLeft:_ctx.$ctx_t(currentSkillToShow.value.name),headerRight:_ctx.$ctx_t(currentSkillToShow.value.levelLabel),value:currentSkillToShow.value.value,max:currentSkillToShow.value.max,min:currentSkillToShow.value.min,maxRequiredValue:currentSkillToShow.value.maxRequiredValue,tiers:currentSkillToShow.value.unlockInfo,currentTier:currentSkillToShow.value.unlocked?currentSkillToShow.value.level:-1,unlocked:currentSkillToShow.value.unlocked,progressFillColor:currentSkillToShow.value.accentColor},null,8,[`headerLeft`,`headerRight`,`value`,`max`,`min`,`maxRequiredValue`,`tiers`,`currentTier`,`unlocked`,`progressFillColor`])):createCommentVNode(``,!0)])):createCommentVNode(``,!0),leagues.value&&leagues.value.length>0?(openBlock(),createElementBlock(`div`,_hoisted_4$142,[(openBlock(!0),createElementBlock(Fragment,null,renderList(leagues.value,league=>(openBlock(),createBlock(LeagueRow_default,{key:league.id,league,leagueMissionClicked},null,8,[`league`]))),128))])):createCommentVNode(``,!0),landingData.value.showMilestones?(openBlock(),createElementBlock(`div`,_hoisted_5$124,[withDirectives((openBlock(),createBlock(unref(bngCard_default),{"bng-nav-item":``,class:`button milestone-button`,onClick:openMilestonesScreen},{default:withCtx(()=>[createBaseVNode(`div`,_hoisted_6$106,[createVNode(unref(bngIcon_default),{class:`icon`,type:unref(icons).checkboxOn},null,8,[`type`]),_cache[0]||=createBaseVNode(`div`,{class:`label`},` Milestones `,-1),hasUnclaimedMilestones.value>0?(openBlock(),createElementBlock(`div`,_hoisted_7$93)):createCommentVNode(``,!0)])]),_:1})),[[unref(BngSoundClass_default),`bng_click_hover_generic`]])])):createCommentVNode(``,!0)]),_:1},8,[`skill-info`,`heading-text`,`breadcrumb-items`,`branch-style`]))}},ProgressLanding_default=__plugin_vue_export_helper_default(_sfc_main$265,[[`__scopeId`,`data-v-cbe0bb9d`]]),_hoisted_1$235={class:`reward-wrapper`},_hoisted_2$193={class:`card-content`},_hoisted_3$168={class:`rewards-breakdown-container padding-bottom`},_hoisted_4$141={class:`grid-wrapper`},_hoisted_5$123={class:`grid-row grid`},_hoisted_6$105={class:`label primary`},_hoisted_7$92={class:`rewards primary`},_hoisted_8$77={class:`grid-wrapper wide`},_hoisted_9$70={class:`grid`},_hoisted_10$61={class:`label secondary`},_hoisted_11$55={class:`rewards secondary`},_hoisted_12$44={class:`grid-row grid`},_hoisted_13$37={class:`rewards primary`},_hoisted_14$35={class:`padding-bottom`},_hoisted_15$33={key:0,class:`unlocks-wrapper`},__default__$4={wrapper:{fade:!0,blur:!0,style:popupContainer.transparent},position:[popupPosition.center,popupPosition.center]},_sfc_main$264=Object.assign(__default__$4,{__name:`CargoDeliveryReward`,emits:[`return`],setup(__props,{emit:__emit}){useCssVars(_ctx=>({v4c61e8a8:ANIM_DURATION_CSS})),useUINavScope(`deliveryReward`);let ANIMATION_START_DELAY=1e3,ANIMATION_DURATION=2e3,ANIM_DURATION_CSS=ANIMATION_DURATION+`ms`,showBarAnimations=ref(!1),data=storeToRefs(useGameContextStore()).deliveryRewardData,exit=()=>{window.bngVue.gotoGameState(`play`)};function stopAnimations(){showBarAnimations.value=!1}function startProgressBarAnimation(){if(data.value){showBarAnimations.value=!0;for(let[key,value]of Object.entries(data.value.summary.rewards))value.branchInfo&&(value.branchInfo.animValue=value.branchInfo.value);setTimeout(stopAnimations,ANIMATION_DURATION)}}return onBeforeMount(()=>{Lua_default.simTimeAuthority.pushPauseRequest(`cargoDeliveryReward`)}),onMounted(()=>{getUINavServiceInstance().activate(),getUINavServiceInstance().clearFilteredEvents(),showBarAnimations.value=!1,setTimeout(startProgressBarAnimation,1e3)}),onUnmounted(()=>{Lua_default.career_modules_delivery_cargoScreen.unloadCargoPopupClosed(),Lua_default.simTimeAuthority.popPauseRequest(`cargoDeliveryReward`)}),(_ctx,_cache)=>unref(data)?withDirectives((openBlock(),createBlock(unref(layoutSingle_default),{key:0,class:`layout-content-full flex-column layout-paddings layout-align-center`,"bng-ui-scope":`deliveryReward`},{default:withCtx(()=>[createBaseVNode(`div`,_hoisted_1$235,[createVNode(unref(bngCard_default),null,{buttons:withCtx(()=>[createVNode(unref(bngButton_default),{onClick:exit},{default:withCtx(()=>[createVNode(unref(bngBinding_default),{"ui-event":`ok`,deviceMask:`xinput`}),_cache[5]||=createBaseVNode(`span`,null,`Continue`,-1)]),_:1})]),default:withCtx(()=>[createVNode(unref(careerStatus_default),{class:`career-status`}),createVNode(unref(bngCardHeading_default),{type:`ribbon`},{default:withCtx(()=>[..._cache[0]||=[createTextVNode(` Delivery Complete! `,-1)]]),_:1}),createBaseVNode(`div`,_hoisted_2$193,[createBaseVNode(`div`,_hoisted_3$168,[_cache[3]||=createBaseVNode(`span`,{class:`span2-heading`},` Reward Breakdown `,-1),createBaseVNode(`div`,_hoisted_4$141,[_cache[2]||=createBaseVNode(`div`,{class:`grid-row grid`},[createBaseVNode(`div`,{class:`label primary`},`Item`),createBaseVNode(`div`,{class:`rewards primary`},`Rewards`)],-1),(openBlock(!0),createElementBlock(Fragment,null,renderList(unref(data).sortedResults,result=>(openBlock(),createElementBlock(`div`,_hoisted_5$123,[createBaseVNode(`div`,_hoisted_6$105,toDisplayString(result.label),1),createBaseVNode(`div`,_hoisted_7$92,[createVNode(RewardsPills_default,{rewards:result.rewards},null,8,[`rewards`])]),createBaseVNode(`div`,_hoisted_8$77,[(openBlock(!0),createElementBlock(Fragment,null,renderList(result.breakdown,breakdown=>(openBlock(),createElementBlock(`div`,_hoisted_9$70,[createBaseVNode(`div`,_hoisted_10$61,toDisplayString(breakdown.label),1),createBaseVNode(`div`,_hoisted_11$55,[createVNode(RewardsPills_default,{rewards:breakdown.rewards},null,8,[`rewards`])])]))),256))])]))),256)),createVNode(unref(bngDivider_default)),createBaseVNode(`div`,_hoisted_12$44,[_cache[1]||=createBaseVNode(`div`,{class:`label primary`},`Summary`,-1),createBaseVNode(`div`,_hoisted_13$37,[createVNode(RewardsPills_default,{rewards:unref(data).summary.rewards},null,8,[`rewards`])])])])]),createBaseVNode(`div`,_hoisted_14$35,[(openBlock(!0),createElementBlock(Fragment,null,renderList(unref(data).summary.rewards,reward=>(openBlock(),createElementBlock(`div`,null,[reward.branchInfo?(openBlock(),createBlock(unref(bngProgressBar_default),{key:0,class:normalizeClass({"stat-progress-bar":!0,"animate-progress":showBarAnimations.value}),headerLeft:_ctx.$ctx_t(reward.branchInfo.name),headerRight:_ctx.$ctx_t(reward.branchInfo.level),min:reward.branchInfo.max==-1?0:reward.branchInfo.min,value:reward.branchInfo.max==-1?1:reward.branchInfo.animValue,max:reward.branchInfo.max==-1?1:reward.branchInfo.max,"value-label-format":reward.branchInfo.max==-1?`Max Level Reached`:void 0},null,8,[`class`,`headerLeft`,`headerRight`,`min`,`value`,`max`,`value-label-format`])):createCommentVNode(``,!0)]))),256))]),unref(data).summary.unlocks.length?(openBlock(),createElementBlock(`div`,_hoisted_15$33,[_cache[4]||=createBaseVNode(`span`,{class:`span2-heading`},` Unlocks`,-1),(openBlock(!0),createElementBlock(Fragment,null,renderList(unref(data).summary.unlocks,unlock=>(openBlock(),createBlock(UnlockCard_default,{class:`unlock-item`,data:unlock},null,8,[`data`]))),256))])):createCommentVNode(``,!0)])]),_:1})])]),_:1})),[[unref(BngBlur_default)],[unref(BngOnUiNav_default),exit,`back,menu,ok`]]):createCommentVNode(``,!0)}}),CargoDeliveryReward_default=__plugin_vue_export_helper_default(_sfc_main$264,[[`__scopeId`,`data-v-e964374f`]]),_hoisted_1$234={key:0,class:`context`},_hoisted_2$192={key:0,class:`card-label`},_hoisted_3$167={key:1,class:`card-label`},_hoisted_4$140={class:`simple-props-wrapper`},_hoisted_5$122={key:1,class:`to-load`},_hoisted_6$104={class:`chevron-arrow`},_hoisted_7$91={class:`chevron-outer`,width:`100%`,height:`100%`,xmlns:`http://www.w3.org/2000/svg`},_hoisted_8$76={class:`chevron-inner`,viewBox:`4 2 12 60`,preserveAspectRatio:`xMaxYMid slice`},_hoisted_9$69={key:0,d:`M-11 -2H1L14 32L1 66H-11V-2Z`,fill:`rgb(var(--chevron-color))`,"fill-opacity":`var(--chevron-alpha)`,stroke:`rgb(var(--chevron-color))`,"stroke-width":`3`,"vector-effect":`non-scaling-stroke`},_hoisted_10$60={key:1,d:`M-11 -2H1L14 32L1 66H-11V-2Z`,fill:`rgb(var(--chevron-color))`,"fill-opacity":`var(--chevron-alpha)`,stroke:`var(--bng-orange-500)`,"stroke-width":`3`,"vector-effect":`non-scaling-stroke`},_hoisted_11$54={key:2},_hoisted_12$43={key:0,class:`modifiers`},_hoisted_13$36={key:1,class:`timer-value`},_hoisted_14$34={key:0,class:`orange`},_sfc_main$263={__name:`CargoCard`,props:{card:{type:Object,required:!1},hideProps:Boolean,hideModsAndTimer:Boolean,focus:String,detailed:Boolean,showButtons:{type:Boolean,default:!0},alwaysShowLoadingWrapper:Boolean,ribbon:{type:Boolean,default:!0}},emits:[`cargoHovered`,`onAmountSelectorChanged`],setup(__props,{emit:__emit}){let emit$1=__emit;function onAmountSelectorChanged(value){emit$1(`onAmountSelectorChanged`,value)}let props=__props,cargoOverviewStore=useCargoOverviewStore(),{units}=useBridge(),getCargoCardClass=card=>({cardRow:!0,"bg-available":card.isFacilityCard&&card.enabled,"bg-available-selected":card.isFacilityCard&&card.enabled&&cargoOverviewStore.selectedCargo===card,"bg-assigned":card.transientMove,"bg-assigned-selected":card.transientMove&&cargoOverviewStore.selectedCargo===card,"bg-locked":card.isFacilityCard&&!card.enabled,"bg-locked-selected":card.isFacilityCard&&!card.enabled&&cargoOverviewStore.selectedCargo===card,"bg-loaded":card.isPlayerCard&&!card.transientMove,"bg-loaded-selected":card.isPlayerCard&&!card.transientMove&&cargoOverviewStore.selectedCargo===card,"highlight-poi-selected":!!(!props.detailed&&cargoOverviewStore.highlightedCards[card.cardId]),"card-disabled":!card.enabled,"with-thumbnail":card.thumbnail}),rewardMoney=computed(()=>props.card.rewardMoney||props.card.rewardMoneyPerLiter||(props.card.loanerCut?-(props.card.loanerCut.value*100-props.card.loanerCut.value*100%1)+`%`:void 0)),hasIds=computed(()=>props.card.rewardMoney&&props.card.ids&&props.card.ids.length>0&&!props.card.materialType),isPerLiter=computed(()=>props.card.rewardMoneyPerLiter),isLoadingFacilityCard=computed(()=>props.card.transientMoveCounts>0||props.card.spawnWhenCommitingCargo||props.card._transientMaterialMoveAmount>0),context=computed(()=>props.card.enabled?props.card.isFacilityCard?`Available`:props.card.transientMoveCounts>0||props.card.spawnWhenCommitingCargo||props.card._transientMaterialMoveAmount?`Assigned`:`Loaded`:`Locked`),isMoving=computed(()=>cargoOverviewStore.cargoData.player.isMoving),chevronProp=computed(()=>{let card=props.card;if(!card.isPlayerCard){if(card.cardType===`parcelGroup`)return card.materialType?card.transientMoveCounts>0||props.alwaysShowLoadingWrapper?{class:card.transientMoveCounts==0?`amount-load no-load`:`amount-load`,valueLabel:card.slots+`L`}:void 0:card.transientMoveCounts>0||props.alwaysShowLoadingWrapper?{class:card.transientMoveCounts==0?`amount-load no-load`:`amount-load`,valueLabel:card.transientMoveCounts+` / `+card.ids.length}:void 0;if(card.cardType===`vehicleOffer`)return card.spawnWhenCommitingCargo?{class:`amount-load`,valueLabel:`Accepted`,iconType:icons.fastTravel}:void 0;if(card.cardType===`storage`)return card._transientMaterialMoveAmount>0||props.alwaysShowLoadingWrapper?{class:card._transientMaterialMoveAmount==0?`amount-load no-load`:`amount-load`,valueLabel:card._transientMaterialMoveAmount+`L / `+card.storage.storedVolume+`L`}:void 0}}),propIcons=computed(()=>{let res=[],card=props.card;if(props.detailed)return res;if(card.enabled&&card.modifiers&&card.modifiers.length)for(let mod of card.modifiers)mod.important&&res.push({type:icons[mod.icon],color:`var(--bng-orange-300)`});return card.disableReason&&card.disableReason.type===`locked`&&res.push({type:icons.lockClosed,color:`var(--bng-add-red-300)`}),res}),cargoProps=computed(()=>{let res=[],card=props.card,detailed=props.detailed,focus$1=props.focus,$tt=$translate.instant,$ctx_t=$translate.contextTranslate,hideProps=props.hideProps;if(card.isFacilityCard&&!card.enabled&&(!card.transientMoveCounts||card.transientMoveCounts<=0)&&(card.disableReason?(card.disableReason.type===`noSpace`&&res.push({iconType:icons.info,keyLabel:detailed?`No Space`:``,valueLabel:detailed?card.disableReason.label?card.disableReason.label:`Not enough space to load this.`:`No Space`,class:`full-width red`,iconColor:`var(--bng-add-red-300)`}),card.disableReason.type===`expired`&&res.push({iconType:icons.info,keyLabel:detailed?`Expired`:``,valueLabel:detailed?card.disableReason.label?card.disableReason.label:`This offer is already expired.`:`Expired`,class:`full-width `}),card.disableReason.type===`limit`&&res.push({iconType:icons.info,keyLabel:detailed?`Limit reached`:``,valueLabel:detailed?card.disableReason.label?card.disableReason.label:`You cannot deliver more cars at the same time.`:`Limit reached`,class:`full-width red`,iconColor:`var(--bng-add-red-300)`})):res.push({iconType:icons.lockClosed,keyLabel:detailed?`Locked..?`:``,valueLabel:detailed?`Not enabled but no disablereason given!`:`Locked..?`,class:`full-width`,iconColor:`var(--bng-add-red-300)`})),card.unlockInfo){let locked=card.disableReason&&card.disableReason.type==`locked`;(detailed||locked)&&res.push({iconType:icons[card.unlockInfo.icon],valueLabel:detailed?$ctx_t(card.unlockInfo.longLabel):``,keyLabel:detailed?locked?`Locked`:``:$ctx_t(card.unlockInfo.shortLabel),class:`full-width `+(locked?`red`:``),iconColor:locked?`var(--bng-add-red-300)`:``})}if(hideProps)return res;if(card.nextTasks&&card.nextTasks.length>0&&(!focus$1||focus$1===`nextTasks`||detailed))for(let task of card.nextTasks)res.push({iconType:icons[task.checked?`checkboxOn`:`checkboxOff`],keyLabel:detailed?`Next Task`:``,valueLabel:task.label,class:`full-width`});if(card.locationName&&(!focus$1||focus$1===`location`||detailed)&&res.push({iconType:icons.locationSource,keyLabel:detailed?`Location`:``,valueLabel:detailed?card.locationNameLong:card.locationName,class:`full-width`}),card.destinationName&&(!focus$1||focus$1===`destination`||detailed)&&res.push({iconType:icons.locationDestination,keyLabel:detailed?`Destination`:``,valueLabel:detailed?card.destinationNameLong:card.destinationName,class:`full-width`}),card.locations&&(!focus$1||focus$1===`destination`)&&!detailed&&res.push({iconType:icons.mapPoint,valueLabel:card.locations.length+` possible Destinations`,class:`full-width`}),card.locations&&detailed)if(card.locations.length==1)res.push({iconType:icons.locationDestination,keyLabel:`Destination`,valueLabel:card.locations[0].name,class:`full-width`});else{res.push({iconType:icons.location2,keyLabel:`Multiple Destinations`,valueLabel:`Deliver this cargo to any of the possible destinations.`,class:`full-width`});let destinationsList=[];for(let location$1 of card.locations)destinationsList.push($tt(location$1.name));destinationsList=destinationsList.map(str=>str.replace(/ /g,` `)),res.push({iconType:icons.mapPoint,keyLabel:`Possible Destinations`,valueLabel:destinationsList.join(`, `),class:`full-width`})}if(card.distance&&(!focus$1||focus$1===`distance`||detailed)&&res.push({iconType:icons.routeSimple,keyLabel:detailed?`Distance`:``,valueLabel:units.buildString(`distance`,card.distance,1),class:``}),card.vehMileage&&(!focus$1||focus$1===`vehMileage`||detailed)&&res.push({iconType:icons.odometer,keyLabel:detailed?`Mileage`:``,valueLabel:units.buildString(`distance`,card.vehMileage,1),class:``}),card.weight&&(!focus$1||focus$1===`weight`||detailed)&&res.push({iconType:icons.weight,keyLabel:detailed?`Weight`:``,valueLabel:units.buildString(`weight`,card.weight,1),class:``}),card.density&&(!focus$1||focus$1===`density`||detailed)&&res.push({iconType:icons.weight,keyLabel:detailed?`Density`:``,valueLabel:units.buildString(`weight`,card.density,2),class:``}),card.storage&&(!focus$1||focus$1===`storage`||detailed)&&res.push({iconType:icons.boxDropOff01,keyLabel:detailed?`Available Volume`:``,valueLabel:(card.storage.storedVolume+(detailed?` / `+card.storage.capacity:``)).replace(/ /g,` `),class:``}),card.slots&&(!focus$1||focus$1===`slots`||detailed)&&res.push({iconType:icons.boxDropOff01,keyLabel:detailed?`Slots`:``,valueLabel:card.slots,class:``}),card.task&&(!focus$1||focus$1===`task`||detailed)&&res.push({iconType:icons.checkboxOff,keyLabel:detailed?`Task`:``,valueLabel:card.task,class:`full-width`}),card.cardType==`loaner`&&(!focus$1||detailed)&&res.push({iconType:icons.steeringWheelSporty,keyLabel:detailed?`Loaner`:``,valueLabel:detailed?card.isFacilityCard?`This vehicle can be loaned for delivery.`:`This vehicle can be used for delivery.`:`Loaner`,class:`full-width`}),card.cardType==`loaner`&&card.loanerCut&&!focus$1&&detailed&&res.push({iconType:icons.carCoins,keyLabel:detailed?`Loaner Cut`:``,valueLabel:detailed?`Organization takes `+(card.loanerCut.value*100-card.loanerCut.value*100%1)+`% of rewards earned with this loaner.`:card.loanerCut.value*100-card.loanerCut.value*100%1+`%`,class:`full-width`}),card.organizationName&&(!focus$1||detailed)&&res.push({iconType:icons.peopleOutline,keyLabel:detailed?`Organization`:``,valueLabel:$tt(card.organizationName),class:``}),card.capacity&&card.capacity.length)for(let cap of card.capacity)res.push({iconType:icons[cap.icon],keyLabel:detailed?`Capacity`:``,valueLabel:detailed?cap.labelLong:cap.labelShort,class:``});if(detailed&&card.modifiers&&card.modifiers.length>0)for(let mod of card.modifiers)res.push({iconType:icons[mod.icon],keyLabel:mod.label,valueLabel:mod.description,class:`full-width`+(mod.important?` orange`:``),iconColor:mod.important?`var(--bng-orange-300)`:``});return res});return(_ctx,_cache)=>(openBlock(),createBlock(unref(bngCard_default),mergeProps({class:[`card-item`,getCargoCardClass(__props.card)]},!__props.detailed&&{"bng-nav-item":!0,tabindex:1},{onClick:_cache[15]||=withModifiers(()=>{},[`stop`])}),{default:withCtx(()=>[!__props.detailed&&__props.card.thumbnail?(openBlock(),createBlock(unref(aspectRatio_default),{key:0,class:`image`,ratio:`4:3`,"external-image":__props.card.thumbnail},{default:withCtx(()=>[!__props.card.enabled&&__props.card.disableReason.type==`locked`?(openBlock(),createBlock(unref(bngIcon_default),{key:0,type:unref(icons).lockClosed,class:`icon`},null,8,[`type`])):createCommentVNode(``,!0)]),_:1},8,[`external-image`])):createCommentVNode(``,!0),createBaseVNode(`div`,{class:normalizeClass({"card-content-flex":!0,"with-actions":!__props.detailed})},[createBaseVNode(`div`,{class:normalizeClass([`heading-wrapper`,{"heading-detailed":__props.detailed}])},[__props.detailed?(openBlock(),createBlock(unref(bngCardHeading_default),{key:0,type:__props.ribbon?`ribbon`:`none`,class:`card-heading`},{default:withCtx(()=>[context.value===``?createCommentVNode(``,!0):(openBlock(),createElementBlock(`span`,_hoisted_1$234,toDisplayString(context.value),1)),createBaseVNode(`div`,null,[__props.card.vehName?(openBlock(),createElementBlock(Fragment,{key:1},[createTextVNode(toDisplayString(__props.card.vehName),1)],64)):(openBlock(),createElementBlock(Fragment,{key:0},[createTextVNode(toDisplayString(__props.card.name),1)],64))])]),_:1},8,[`type`])):(openBlock(),createElementBlock(Fragment,{key:1},[__props.card.vehName?(openBlock(),createElementBlock(`div`,_hoisted_3$167,toDisplayString(__props.card.vehName),1)):(openBlock(),createElementBlock(`div`,_hoisted_2$192,toDisplayString(__props.card.name),1))],64)),createBaseVNode(`div`,{class:normalizeClass([`pill pill-blue`,{"pill-orange":isLoadingFacilityCard.value}])},[typeof rewardMoney.value==`number`?(openBlock(),createBlock(unref(bngUnit_default),{key:0,class:`reward-money`,money:rewardMoney.value},null,8,[`money`])):(openBlock(),createBlock(unref(bngPropVal_default),{key:1,class:`reward-money`,iconType:unref(icons).beamCurrency,valueLabel:rewardMoney.value},null,8,[`iconType`,`valueLabel`])),hasIds.value&&!__props.card.transientMove?(openBlock(),createBlock(unref(bngPropVal_default),{key:2,class:`amount-avail`,valueLabel:`×`+__props.card.ids.length},null,8,[`valueLabel`])):createCommentVNode(``,!0),hasIds.value&&__props.card.transientMove?(openBlock(),createBlock(unref(bngPropVal_default),{key:3,class:`amount-avail`,valueLabel:`×`+__props.card.transientMoveCounts},null,8,[`valueLabel`])):createCommentVNode(``,!0),isPerLiter.value?(openBlock(),createBlock(unref(bngPropVal_default),{key:4,class:`amount-avail`,valueLabel:`/L`})):createCommentVNode(``,!0),__props.card.materialType?(openBlock(),createBlock(unref(bngPropVal_default),{key:5,class:`amount-avail`,valueLabel:__props.card.slots+` L`},null,8,[`valueLabel`])):createCommentVNode(``,!0)],2)],2),!__props.card.showAmountSelector&&cargoProps.value.length>0&&__props.detailed?(openBlock(),createElementBlock(`div`,{key:0,class:normalizeClass({"body-grid":__props.detailed,"body-list-wrapped":!__props.detailed,"content-detailed":__props.detailed})},[(openBlock(!0),createElementBlock(Fragment,null,renderList(cargoProps.value,props$1=>(openBlock(),createBlock(unref(bngPropVal_default),mergeProps({ref_for:!0},props$1),null,16))),256))],2)):createCommentVNode(``,!0),__props.detailed&&isMoving.value?(openBlock(),createElementBlock(`div`,{key:1,class:normalizeClass([`buttons-disabled-reason`,{"disabled-load-actions":!__props.card.enabled||!__props.showButtons,"footer-detailed":__props.detailed}])},[createVNode(unref(bngPropVal_default),{class:`prop`,iconType:unref(icons).info,keyLabel:``,valueLabel:`Cannot modify cargo while any vehicle is moving.`},null,8,[`iconType`])],2)):createCommentVNode(``,!0),createBaseVNode(`div`,{class:normalizeClass([`load-actions-wrapper`,{"disabled-load-actions":!__props.card.enabled||!__props.showButtons,"footer-detailed":__props.detailed,"chevrons-bg":__props.card.transientMoveCounts>0||__props.card.spawnWhenCommitingCargo||__props.card._transientMaterialMoveAmount>0}])},[createBaseVNode(`div`,_hoisted_4$140,[__props.detailed?createCommentVNode(``,!0):(openBlock(),createElementBlock(Fragment,{key:0},[(openBlock(!0),createElementBlock(Fragment,null,renderList(propIcons.value,icon=>(openBlock(),createBlock(unref(bngIcon_default),mergeProps({class:`icon`},{ref_for:!0},icon),null,16))),256)),(openBlock(!0),createElementBlock(Fragment,null,renderList(cargoProps.value,props$1=>(openBlock(),createBlock(unref(bngPropVal_default),mergeProps({class:`prop`},{ref_for:!0},props$1),null,16))),256))],64))]),__props.card.enabled&&__props.showButtons?(openBlock(),createElementBlock(`div`,{key:0,class:normalizeClass([`load-actions-buttons`,{undetailed:!__props.detailed}])},[__props.card.cardType==`parcelGroup`?(openBlock(),createElementBlock(Fragment,{key:0},[__props.card.isFacilityCard?(openBlock(),createElementBlock(Fragment,{key:0},[__props.card.transientMoveCounts==0?createCommentVNode(``,!0):(openBlock(),createBlock(unref(bngButton_default),{key:0,class:normalizeClass(__props.detailed?``:`button-load`),accent:unref(ACCENTS).secondary,"icon-right":unref(icons).undo,label:__props.detailed?`Clear load`:``,onClick:_cache[0]||=$event=>unref(cargoOverviewStore).clearLoad(__props.card),disabled:isMoving.value,tabindex:`0`},null,8,[`class`,`accent`,`icon-right`,`label`,`disabled`])),__props.card.autoLoadLocations&&__props.card.autoLoadLocations.length==0?createCommentVNode(``,!0):(openBlock(),createBlock(unref(bngButton_default),{key:1,class:normalizeClass(__props.detailed?``:`button-load`),accent:unref(ACCENTS).secondary,"icon-right":unref(icons).wrench,label:__props.detailed?`Custom load`:``,onClick:_cache[1]||=$event=>unref(cargoOverviewStore).loadCargoCustom(__props.card),disabled:isMoving.value,tabindex:`0`},null,8,[`class`,`accent`,`icon-right`,`label`,`disabled`])),__props.card.transientMoveCounts==__props.card.ids.length||__props.card.autoLoadLocations.length==0||!__props.card.autoLoadLocations.length?createCommentVNode(``,!0):(openBlock(),createBlock(unref(bngButton_default),{key:2,class:normalizeClass(__props.detailed?``:`button-load`),accent:unref(ACCENTS).main,"icon-right":unref(icons).arrowLargeRight,label:__props.detailed?`Load all`:``,onClick:_cache[2]||=$event=>unref(cargoOverviewStore).loadCargoAuto(__props.card),disabled:isMoving.value,tabindex:`0`},null,8,[`class`,`accent`,`icon-right`,`label`,`disabled`]))],64)):(openBlock(),createElementBlock(Fragment,{key:1},[__props.card.transientMoveCounts>0?(openBlock(),createBlock(unref(bngButton_default),{key:0,class:normalizeClass(__props.detailed?``:`button-load`),accent:unref(ACCENTS).attention,"icon-right":unref(icons).undo,label:__props.detailed?`Clear Load`:``,onClick:_cache[3]||=$event=>unref(cargoOverviewStore).clearLoad(__props.card),disabled:isMoving.value,tabindex:`0`},null,8,[`class`,`accent`,`icon-right`,`label`,`disabled`])):(openBlock(),createBlock(unref(bngButton_default),{key:1,class:normalizeClass(__props.detailed?``:`button-load`),accent:unref(ACCENTS).attention,"icon-right":unref(icons).trashBin1,label:__props.detailed?`Throw Away`:``,onClick:_cache[4]||=$event=>unref(cargoOverviewStore).throwAway(__props.card),disabled:isMoving.value,tabindex:`0`},null,8,[`class`,`accent`,`icon-right`,`label`,`disabled`])),__props.card.materialType===void 0?(openBlock(),createBlock(unref(bngButton_default),{key:2,class:normalizeClass(__props.detailed?``:`button-load`),accent:unref(ACCENTS).primary,"icon-right":unref(icons).wrench,label:__props.detailed?`Custom load`:``,onClick:_cache[5]||=$event=>unref(cargoOverviewStore).loadCargoCustom(__props.card),disabled:isMoving.value,tabindex:`0`},null,8,[`class`,`accent`,`icon-right`,`label`,`disabled`])):createCommentVNode(``,!0),__props.card.materialType!==void 0&&__props.card.transientMove?(openBlock(),createBlock(unref(bngButton_default),{key:3,class:normalizeClass(__props.detailed?``:`button-load`),accent:unref(ACCENTS).primary,"icon-right":unref(icons).wrench,label:__props.detailed?`Custom Load`:``,onClick:_cache[6]||=$event=>unref(cargoOverviewStore).modifyMaterialLoad(__props.card),disabled:isMoving.value,tabindex:`0`},null,8,[`class`,`accent`,`icon-right`,`label`,`disabled`])):createCommentVNode(``,!0)],64))],64)):createCommentVNode(``,!0),__props.card.isFacilityCard?(openBlock(),createElementBlock(Fragment,{key:1},[__props.card.cardType==`storage`?(openBlock(),createBlock(unref(bngButton_default),{key:0,class:normalizeClass(__props.detailed?``:`button-load`),accent:unref(ACCENTS).main,icon:unref(icons).wrench,label:__props.detailed?`Custom load`:``,onClick:_cache[7]||=$event=>unref(cargoOverviewStore).loadStorageCustom(__props.card),disabled:isMoving.value,tabindex:`0`},null,8,[`class`,`accent`,`icon`,`label`,`disabled`])):createCommentVNode(``,!0),__props.card.cardType==`vehicleOffer`&&!__props.card.spawnWhenCommitingCargo?(openBlock(),createBlock(unref(bngButton_default),{key:1,class:normalizeClass(__props.detailed?``:`button-load`),accent:unref(ACCENTS).main,icon:unref(icons).keys1,label:__props.detailed?`Accept Job`:``,onClick:_cache[8]||=$event=>unref(cargoOverviewStore).loadOffer(__props.card),disabled:isMoving.value,tabindex:`0`},null,8,[`class`,`accent`,`icon`,`label`,`disabled`])):createCommentVNode(``,!0),__props.card.cardType==`vehicleOffer`&&__props.card.spawnWhenCommitingCargo?(openBlock(),createBlock(unref(bngButton_default),{key:2,class:normalizeClass(__props.detailed?``:`button-load`),accent:unref(ACCENTS).attention,icon:unref(icons).undo,label:__props.detailed?`Decline Job`:``,onClick:_cache[9]||=$event=>unref(cargoOverviewStore).loadOffer(__props.card),disabled:isMoving.value,tabindex:`0`},null,8,[`class`,`accent`,`icon`,`label`,`disabled`])):createCommentVNode(``,!0),__props.card.cardType==`loaner`&&!__props.card.spawnWhenCommitingCargo?(openBlock(),createBlock(unref(bngButton_default),{key:3,class:normalizeClass(__props.detailed?``:`button-load`),accent:unref(ACCENTS).main,icon:unref(icons).keys1,label:__props.detailed?`Accept Loaner`:``,onClick:_cache[10]||=$event=>unref(cargoOverviewStore).loadLoaner(__props.card),disabled:isMoving.value,tabindex:`0`},null,8,[`class`,`accent`,`icon`,`label`,`disabled`])):createCommentVNode(``,!0),__props.card.cardType==`loaner`&&__props.card.spawnWhenCommitingCargo?(openBlock(),createBlock(unref(bngButton_default),{key:4,class:normalizeClass(__props.detailed?``:`button-load`),accent:unref(ACCENTS).attention,icon:unref(icons).undo,label:__props.detailed?`Decline Loaner`:``,onClick:_cache[11]||=$event=>unref(cargoOverviewStore).loadLoaner(__props.card),disabled:isMoving.value,tabindex:`0`},null,8,[`class`,`accent`,`icon`,`label`,`disabled`])):createCommentVNode(``,!0)],64)):(openBlock(),createElementBlock(Fragment,{key:2},[__props.card.cardType==`vehicleOffer`&&!__props.card.spawnWhenCommitingCargo?(openBlock(),createBlock(unref(bngButton_default),{key:0,class:normalizeClass(__props.detailed?``:`button-load`),accent:unref(ACCENTS).attention,icon:unref(icons).trashBin1,label:__props.detailed?`Abandon Job`:``,onClick:_cache[12]||=$event=>unref(cargoOverviewStore).abandonOffer(__props.card),disabled:isMoving.value,tabindex:`0`},null,8,[`class`,`accent`,`icon`,`label`,`disabled`])):createCommentVNode(``,!0),__props.card.cardType==`loaner`&&__props.card.isSpawnedLoaner?(openBlock(),createBlock(unref(bngButton_default),{key:1,class:normalizeClass(__props.detailed?``:`button-load`),accent:unref(ACCENTS).attention,icon:unref(icons).trashBin1,label:__props.detailed?`Return Loaner`:``,onClick:_cache[13]||=$event=>unref(cargoOverviewStore).returnLoaner(__props.card.id),disabled:isMoving.value,tabindex:`0`},null,8,[`class`,`accent`,`icon`,`label`,`disabled`])):createCommentVNode(``,!0)],64))],2)):createCommentVNode(``,!0),chevronProp.value?(openBlock(),createElementBlock(`div`,_hoisted_5$122,[createVNode(unref(bngPropVal_default),mergeProps({class:`amount-load`},chevronProp.value),null,16),createBaseVNode(`div`,_hoisted_6$104,[(openBlock(),createElementBlock(`svg`,_hoisted_7$91,[(openBlock(),createElementBlock(`svg`,_hoisted_8$76,[__props.card.transientMoveCounts===0?(openBlock(),createElementBlock(`path`,_hoisted_9$69)):(openBlock(),createElementBlock(`path`,_hoisted_10$60))]))]))])])):createCommentVNode(``,!0)],2),__props.card.showAmountSelector?(openBlock(),createElementBlock(`div`,_hoisted_11$54,[createTextVNode(` Selected Amount: `+toDisplayString(__props.card.amountSelector)+` `,1),createVNode(unref(bngSlider_default),{class:`slider`,min:0,max:__props.card.maxCount,step:1,modelValue:__props.card.amountSelector,"onUpdate:modelValue":_cache[14]||=$event=>__props.card.amountSelector=$event,onValueChanged:onAmountSelectorChanged},null,8,[`max`,`modelValue`])])):createCommentVNode(``,!0),createBaseVNode(`div`,{class:normalizeClass([`footer-grid`,{"footer-detailed":__props.detailed}])},[__props.detailed?(openBlock(),createElementBlock(Fragment,{key:0},[(__props.focus===`none`||!__props.focus)&&!__props.hideModsAndTimer?(openBlock(),createElementBlock(`div`,_hoisted_12$43,[__props.detailed?createCommentVNode(``,!0):(openBlock(!0),createElementBlock(Fragment,{key:0},renderList(__props.card.modifiers,mod=>(openBlock(),createBlock(unref(bngIcon_default),{type:unref(icons)[mod.icon]},null,8,[`type`]))),256))])):createCommentVNode(``,!0),__props.card.remainingTime&&(__props.focus===`none`||!__props.focus)&&!__props.hideModsAndTimer?(openBlock(),createElementBlock(`div`,_hoisted_13$36,[__props.card.remainingTime.type===`preLoad`?(openBlock(),createElementBlock(`div`,_hoisted_14$34,`Time for delivery: `+toDisplayString(unref(formatTime)(__props.card.remainingTime.time,2)),1)):createCommentVNode(``,!0),__props.card.remainingTime.type===`untilDelayed`?(openBlock(),createElementBlock(Fragment,{key:1},[createTextVNode(` Time until delivery is Delayed: `+toDisplayString(unref(formatTime)(__props.card.remainingTime.time,2)),1)],64)):createCommentVNode(``,!0),__props.card.remainingTime.type===`untilLate`?(openBlock(),createElementBlock(Fragment,{key:2},[createTextVNode(` Time until delivery is Late: `+toDisplayString(unref(formatTime)(__props.card.remainingTime.time,2)),1)],64)):createCommentVNode(``,!0),__props.card.remainingTime.type===`late`?(openBlock(),createElementBlock(Fragment,{key:3},[createTextVNode(` Delivery is late `)],64)):createCommentVNode(``,!0)])):createCommentVNode(``,!0)],64)):createCommentVNode(``,!0),__props.card.remainingTime&&__props.card.remainingTime.percent&&__props.card.isPlayerCard?(openBlock(),createElementBlock(`div`,{key:1,class:normalizeClass([`timer-progress-bar`,{slim:!__props.detailed}])},[createBaseVNode(`div`,{class:`progress-bar-fill`,style:normalizeStyle({width:__props.card.remainingTime.percent*100+`%`})},null,4)],2)):createCommentVNode(``,!0)],2)],2)]),_:1},16,[`class`]))}},CargoCard_default=__plugin_vue_export_helper_default(_sfc_main$263,[[`__scopeId`,`data-v-bafe8e5e`]]),_hoisted_1$233={class:`info-container`},_hoisted_2$191={key:0,class:`header`},_hoisted_3$166={key:0,class:`label`},_hoisted_4$139={class:`props`},_hoisted_5$121={key:4,class:`prop pill`},_sfc_main$262={__name:`CargoInfo`,props:{label:String,fillInfo:Object,meta:Object},setup(__props){let{units}=useBridge(),props=__props;return(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$233,[__props.meta.type===`hidden`?createCommentVNode(``,!0):(openBlock(),createElementBlock(`div`,_hoisted_2$191,[__props.label?(openBlock(),createElementBlock(`div`,_hoisted_3$166,[__props.meta.type==`task`?(openBlock(),createBlock(unref(bngIcon_default),{key:0,class:`icon`,type:unref(icons).checkboxOff},null,8,[`type`])):createCommentVNode(``,!0),__props.label?(openBlock(),createElementBlock(Fragment,{key:1},[createTextVNode(toDisplayString(_ctx.$tt(__props.label)),1)],64)):createCommentVNode(``,!0)])):createCommentVNode(``,!0),createBaseVNode(`div`,_hoisted_4$139,[__props.meta.type==`container`||__props.meta.type==`totalStorage`?(openBlock(),createBlock(unref(bngPropVal_default),{key:0,iconType:unref(icons)[__props.meta.icon],valueLabel:__props.meta.usedCargoSlots+` / `+__props.meta.totalCargoSlots},null,8,[`iconType`,`valueLabel`])):createCommentVNode(``,!0),__props.meta.type==`location`?(openBlock(),createBlock(unref(bngPropVal_default),{key:1,iconType:unref(icons).mapPoint,valueLabel:unref(units).buildString(`distance`,__props.meta.distance,1),style:{"--icon-size":`1.25em`}},null,8,[`iconType`,`valueLabel`])):createCommentVNode(``,!0),__props.meta.type==`trash`?(openBlock(),createBlock(unref(bngIcon_default),{key:2,class:`icon`,type:unref(icons).trashBin1},null,8,[`type`])):createCommentVNode(``,!0),props&&props.length?(openBlock(!0),createElementBlock(Fragment,{key:3},renderList(props,prop=>(openBlock(),createBlock(unref(bngPropVal_default),{iconType:unref(icons)[prop.icon],valueLabel:prop.label},null,8,[`iconType`,`valueLabel`]))),256)):createCommentVNode(``,!0),__props.fillInfo?(openBlock(),createElementBlock(`div`,_hoisted_5$121,[createVNode(unref(bngPropVal_default),{iconType:unref(icons)[__props.fillInfo.icon],valueLabel:__props.fillInfo.usedSlots+` / `+__props.fillInfo.availableSlots},null,8,[`iconType`,`valueLabel`])])):createCommentVNode(``,!0)]),__props.meta.fillPercent||__props.meta.fillPercent==0?(openBlock(),createElementBlock(`div`,{key:1,class:normalizeClass([`progress-bar`,{trash:__props.meta.type==`trash`}])},[__props.meta.fillPercentHighlight>0?(openBlock(),createElementBlock(`div`,{key:0,class:`progress-bar-fill highlight`,style:normalizeStyle({width:`${__props.meta.fillPercentHighlight*100}%`})},null,4)):createCommentVNode(``,!0),createBaseVNode(`div`,{class:`progress-bar-fill`,style:normalizeStyle({width:`${__props.meta.fillPercent*100}%`})},null,4)],2)):createCommentVNode(``,!0)]))]))}},CargoInfo_default=__plugin_vue_export_helper_default(_sfc_main$262,[[`__scopeId`,`data-v-ba3be877`]]),_hoisted_1$232={class:`group`},_hoisted_2$190={class:`cards`},_sfc_main$261={__name:`CardGroup`,props:{label:String,fillInfo:Object,meta:Object},setup(__props){return(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$232,[createVNode(CargoInfo_default,{label:__props.label,"fill-info":__props.fillInfo,meta:__props.meta},null,8,[`label`,`fill-info`,`meta`]),createBaseVNode(`div`,_hoisted_2$190,[renderSlot(_ctx.$slots,`default`,{},void 0,!0)])]))}},CardGroup_default=__plugin_vue_export_helper_default(_sfc_main$261,[[`__scopeId`,`data-v-f21d8701`]]),_hoisted_1$231={class:`customload-wrapper`,"bng-ui-scope":`cargoLoadPopup`},_hoisted_2$189={class:`card-container`},_hoisted_3$165={class:`content target-grid`},_hoisted_4$138={key:0,class:`target-tile`},_hoisted_5$120={class:`loading-controls amount-load`},_hoisted_6$103={class:`amount`},_hoisted_7$90={class:`chevron-arrow`},_hoisted_8$75={class:`chevron-outer`,width:`100%`,height:`100%`,xmlns:`http://www.w3.org/2000/svg`},_hoisted_9$68={class:`chevron-inner`,viewBox:`4 2 12 60`,preserveAspectRatio:`xMaxYMid slice`},_hoisted_10$59={key:0,d:`M-11 -2H1L14 32L1 66H-11V-2Z`,fill:`rgb(var(--chevron-color))`,"fill-opacity":`var(--chevron-alpha)`,stroke:`rgb(var(--chevron-color))`,"stroke-width":`3`,"vector-effect":`non-scaling-stroke`},_hoisted_11$53={key:1,d:`M-11 -2H1L14 32L1 66H-11V-2Z`,fill:`rgb(var(--chevron-color))`,"fill-opacity":`var(--chevron-alpha)`,stroke:`var(--bng-orange-500)`,"stroke-width":`3`,"vector-effect":`non-scaling-stroke`},_hoisted_12$42={key:1,class:`target-tile trash`},_hoisted_13$35={class:`loading-controls amount-load`},_hoisted_14$33={class:`amount`},_hoisted_15$32={class:`chevron-arrow`},_hoisted_16$32={class:`chevron-outer`,width:`100%`,height:`100%`,xmlns:`http://www.w3.org/2000/svg`},_hoisted_17$26={class:`chevron-inner`,viewBox:`4 2 12 60`,preserveAspectRatio:`xMaxYMid slice`},_hoisted_18$23={key:0,d:`M-11 -2H1L14 32L1 66H-11V-2Z`,fill:`rgb(var(--chevron-color))`,"fill-opacity":`var(--chevron-alpha)`,stroke:`rgb(var(--chevron-color))`,"stroke-width":`3`,"vector-effect":`non-scaling-stroke`},_hoisted_19$20={key:1,d:`M-11 -2H1L14 32L1 66H-11V-2Z`,fill:`rgb(var(--chevron-color))`,"fill-opacity":`var(--chevron-alpha)`,stroke:`var(--bng-add-red-500)`,"stroke-width":`3`,"vector-effect":`non-scaling-stroke`},_hoisted_20$17={class:`buttons content`},__default__$3={wrapper:{fade:!0,blur:!0,style:popupContainer.default},position:[popupPosition.center,popupPosition.center]},_sfc_main$260=Object.assign(__default__$3,{__name:`CargoLoadPopup`,props:{cargo:Object,storageData:Object,throwAway:Boolean},emits:[`return`],setup(__props,{emit:__emit}){let cargoOverviewStore=useCargoOverviewStore(),{events:events$3}=useBridge(),{units}=useBridge();useUINavScope(`cargoLoadPopup`);let emit$1=__emit,props=__props,isFacilityCard=ref(!1),vehicleFilterModel=ref([]),vehicleFilterOptions=ref([]),vehicleFilterChanged=function(filter){for(let target of targetLocations.value)target.hidden=target.containerVehicleInfo&&!filter.includes(target.containerVehicleInfo.vehId)},originalTransientMoveCounts=0,original_transientMaterialMoveAmount=0,card=ref({});ref(0);let throwAwayValue=ref(0),trashMeta=ref({}),loadingName=ref(``),slotsPerItem=ref(0),weightPerItem=ref(0),moneyRewardPerItem=ref(0),targetLocations=ref({}),less=function(target){target?(target.loadSliderValue=Math.max(0,target.loadSliderValue-1),updateSliderAmounts(target)):(throwAwayValue.value=Math.max(0,throwAwayValue.value-1),updateThrowAwayAmount())},more=function(target){target?(target.loadSliderValue=Math.min(target.loadSliderMax,target.loadSliderValue+1),updateSliderAmounts(target)):(throwAwayValue.value=Math.min(totalAvailableAmount.value,throwAwayValue.value+1),updateThrowAwayAmount())},acceptClickHandler=()=>{let loadIdx=0;if(props.cargo)for(let id of props.cargo.ids)Lua_default.career_modules_delivery_cargoScreen.clearTransientMoveForCargo(id);if(props.storageData&&Lua_default.career_modules_delivery_cargoScreen.clearTransientMovesForStorage(props.storageData.material.id),!props.throwAway)for(let target of targetLocations.value){if(props.cargo)for(let i=0;i{isFacilityCard.value&&(card.value.transientMoveCounts=originalTransientMoveCounts,card.value._transientMaterialMoveAmount=0),emit$1(`return`,!0)},totalAvailableAmount=ref(0),loadedAmount=ref(0),updateSliderAmounts=changedItem=>{loadedAmount.value=0;for(let target of targetLocations.value)target.maxAmount&&(loadedAmount.value+=target.loadSliderValue);let tooMuch=loadedAmount.value-totalAvailableAmount.value;if(tooMuch>0){for(let target of targetLocations.value)if(target.maxAmount&&target!==changedItem){let before=target.loadSliderValue;target.loadSliderValue=Math.max(0,target.loadSliderValue-tooMuch);let diff=target.loadSliderValue-before;tooMuch+=diff}loadedAmount.value=totalAvailableAmount.value}for(let target of targetLocations.value)target.meta.usedCargoSlots=target.usedCargoSlots+target.loadSliderValue*slotsPerItem.value,target.meta.fillPercentHighlight=target.meta.usedCargoSlots/target.meta.totalCargoSlots;isFacilityCard.value&&(throwAwayValue.value=totalAvailableAmount.value-loadedAmount.value,card.value.transientMoveCounts=loadedAmount.value,card.value._transientMaterialMoveAmount=loadedAmount.value,trashMeta.value.fillPercent=throwAwayValue.value/totalAvailableAmount.value)},updateThrowAwayAmount=()=>{loadedAmount.value=0;for(let target of targetLocations.value)target.maxAmount&&(loadedAmount.value+=target.loadSliderValue);let tooMuch=loadedAmount.value-totalAvailableAmount.value+throwAwayValue.value;for(let target of targetLocations.value){if(target.maxAmount){let before=target.loadSliderValue;target.loadSliderValue=Math.min(target.loadSliderMax,Math.max(0,target.loadSliderValue-tooMuch));let diff=target.loadSliderValue-before;tooMuch+=diff}loadedAmount.value=totalAvailableAmount.value}updateSliderAmounts()},splittable=ref(!1);return onMounted(()=>{if(getUINavServiceInstance().activate(),getUINavServiceInstance().clearFilteredEvents(),props.cargo){if(loadingName.value=props.cargo.name,slotsPerItem.value=props.cargo.slots,weightPerItem.value=props.cargo.weight,moneyRewardPerItem.value=props.cargo.rewardMoney,targetLocations.value=props.cargo.targetLocations,totalAvailableAmount.value=props.cargo.ids.length,props.cargo.splittable){splittable.value=!0,totalAvailableAmount.value=props.cargo.slots,slotsPerItem.value=1;for(let target of targetLocations.value)target.maxAmount=target.totalCargoSlots-target.usedCargoSlots}card.value=props.cargo,isFacilityCard.value=card.value.isFacilityCard,originalTransientMoveCounts=card.value.transientMoveCounts}props.storageData&&(console.log(props.storageData),loadingName.value=props.storageData.material.name,slotsPerItem.value=1,weightPerItem.value=props.storageData.material.density,moneyRewardPerItem.value=1,targetLocations.value=props.storageData.targetLocations,totalAvailableAmount.value=props.storageData.storage.storedVolume,card.value=props.storageData,isFacilityCard.value=card.value.isFacilityCard),targetLocations.value.length||(targetLocations.value=[]);for(let target of targetLocations.value)target.loadSliderValue=ref(target.selectedAmount),target.loadSliderMax=ref(Math.min(target.maxAmount,totalAvailableAmount.value)),target.meta={type:`container`,usedCargoSlots:target.usedCargoSlots,totalCargoSlots:target.totalCargoSlots,icon:`cardboardBox`,fillPercent:target.usedCargoSlots/target.totalCargoSlots};updateSliderAmounts();let vehicles={};for(let target of targetLocations.value)target.containerVehicleInfo&&(vehicles[target.containerVehicleInfo.vehId]=target.containerVehicleInfo);for(let vehId in vehicleFilterOptions.value=[],vehicles){let veh=vehicles[vehId];vehicleFilterOptions.value.push({value:veh.vehId,label:veh.vehName})}for(let vehId in vehicleFilterOptions.value.sort((a$1,b)=>a$1.name{window.bngVue.getCurrentRoute().name==`unknown`&&getUINavServiceInstance().setFilteredEventsAllExcept(UI_EVENTS.menu,UI_EVENTS.pause,UI_EVENTS.center_cam)}),(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$231,[createVNode(unref(bngCard_default),null,{default:withCtx(()=>[__props.throwAway?(openBlock(),createBlock(unref(bngCardHeading_default),{key:1,type:`ribbon`},{default:withCtx(()=>[createTextVNode(` Throwing away `+toDisplayString(loadingName.value),1)]),_:1})):(openBlock(),createBlock(unref(bngCardHeading_default),{key:0,type:`ribbon`},{default:withCtx(()=>[..._cache[4]||=[createTextVNode(`Custom Loading`,-1)]]),_:1})),createBaseVNode(`div`,_hoisted_2$189,[createVNode(CargoCard_default,{ribbon:!1,card:card.value,hideProps:!1,hideModsAndTimer:!0,showButtons:!1,detailed:!0,alwaysShowLoadingWrapper:isFacilityCard.value},null,8,[`card`,`alwaysShowLoadingWrapper`])]),_ctx.vehicles&&_ctx.vehicles.length>1?(openBlock(),createElementBlock(Fragment,{key:2},[_cache[5]||=createBaseVNode(`span`,null,`Vehicles`,-1),__props.throwAway?createCommentVNode(``,!0):(openBlock(),createBlock(unref(bngPillFilters_default),{key:0,modelValue:vehicleFilterModel.value,"onUpdate:modelValue":_cache[0]||=$event=>vehicleFilterModel.value=$event,selectMany:``,options:vehicleFilterOptions.value,showCheckIcon:!1,onValueChanged:vehicleFilterChanged},null,8,[`modelValue`,`options`]))],64)):createCommentVNode(``,!0),createBaseVNode(`div`,_hoisted_3$165,[targetLocations.value&&!__props.throwAway?(openBlock(!0),createElementBlock(Fragment,{key:0},renderList(targetLocations.value,(target,targetIndex)=>(openBlock(),createElementBlock(Fragment,null,[target.hidden?createCommentVNode(``,!0):(openBlock(),createElementBlock(`div`,_hoisted_4$138,[createVNode(CardGroup_default,{label:target.label,meta:target.meta},{default:withCtx(()=>[createBaseVNode(`div`,{class:normalizeClass([`to-load`,{"none-assigned":target.loadSliderValue==0}])},[createBaseVNode(`div`,_hoisted_5$120,[createVNode(unref(bngButton_default),{class:`less`,iconLeft:unref(icons).minus,accent:`text`,onClick:$event=>less(target)},null,8,[`iconLeft`,`onClick`]),createVNode(unref(bngSlider_default),{"bng-no-nav":``,class:`slider`,min:0,max:target.loadSliderMax,step:1,modelValue:target.loadSliderValue,"onUpdate:modelValue":$event=>target.loadSliderValue=$event,onValueChanged:$event=>updateSliderAmounts(target)},null,8,[`max`,`modelValue`,`onUpdate:modelValue`,`onValueChanged`]),createVNode(unref(bngButton_default),{class:`more`,iconLeft:unref(icons).plus,accent:`text`,onClick:$event=>more(target)},null,8,[`iconLeft`,`onClick`]),createBaseVNode(`div`,_hoisted_6$103,`×`+toDisplayString(target.loadSliderValue),1)]),createBaseVNode(`div`,_hoisted_7$90,[(openBlock(),createElementBlock(`svg`,_hoisted_8$75,[(openBlock(),createElementBlock(`svg`,_hoisted_9$68,[target.loadSliderValue===0?(openBlock(),createElementBlock(`path`,_hoisted_10$59)):(openBlock(),createElementBlock(`path`,_hoisted_11$53))]))]))])],2)]),_:2},1032,[`label`,`meta`])]))],64))),256)):createCommentVNode(``,!0),__props.cargo&&__props.cargo.throwAwayInfo&&unref(totalAvailableAmount)?(openBlock(),createElementBlock(`div`,_hoisted_12$42,[createVNode(CardGroup_default,{label:`Trash`,meta:trashMeta.value},{default:withCtx(()=>[createBaseVNode(`div`,{class:normalizeClass([`to-load`,{"none-assigned":throwAwayValue.value==0}])},[createBaseVNode(`div`,_hoisted_13$35,[createVNode(unref(bngButton_default),{class:`less`,iconLeft:unref(icons).minus,accent:`text`,onClick:_cache[1]||=$event=>less()},null,8,[`iconLeft`]),createVNode(unref(bngSlider_default),{"bng-no-nav":``,class:`slider`,min:0,max:unref(totalAvailableAmount),step:1,modelValue:throwAwayValue.value,"onUpdate:modelValue":_cache[2]||=$event=>throwAwayValue.value=$event,onValueChanged:updateThrowAwayAmount},null,8,[`max`,`modelValue`]),createVNode(unref(bngButton_default),{class:`more`,iconLeft:unref(icons).plus,accent:`text`,onClick:_cache[3]||=$event=>more()},null,8,[`iconLeft`]),createBaseVNode(`div`,_hoisted_14$33,`×`+toDisplayString(throwAwayValue.value),1)]),createBaseVNode(`div`,_hoisted_15$32,[(openBlock(),createElementBlock(`svg`,_hoisted_16$32,[(openBlock(),createElementBlock(`svg`,_hoisted_17$26,[throwAwayValue.value===0?(openBlock(),createElementBlock(`path`,_hoisted_18$23)):(openBlock(),createElementBlock(`path`,_hoisted_19$20))]))]))])],2)]),_:1},8,[`meta`])])):createCommentVNode(``,!0)]),createBaseVNode(`div`,_hoisted_20$17,[withDirectives(createVNode(unref(bngButton_default),{class:`button`,label:`Cancel`,accent:`secondary`,onClick:cancelClickHandler},null,512),[[unref(BngOnUiNav_default),void 0,`back,menu`,{asMouse:!0}]]),__props.cargo&&__props.cargo.throwAwayInfo&&throwAwayValue.value>0?withDirectives((openBlock(),createBlock(unref(bngButton_default),{key:0,class:`button`,accent:`attention`,onClick:acceptClickHandler},{default:withCtx(()=>[createTextVNode(toDisplayString(__props.throwAway?`Throw Away`:`Accept`)+` (`,1),createVNode(unref(bngUnit_default),{money:-__props.cargo.throwAwayInfo.penalty*throwAwayValue.value},null,8,[`money`]),_cache[6]||=createTextVNode(`) `,-1)]),_:1})),[[unref(BngFocusIf_default),!0],[unref(BngOnUiNav_default),void 0,`back,menu`,{asMouse:!0}]]):withDirectives((openBlock(),createBlock(unref(bngButton_default),{key:1,class:`button`,label:`Accept`,accent:`main`,onClick:acceptClickHandler},null,512)),[[unref(BngFocusIf_default),!0],[unref(BngOnUiNav_default),void 0,`back,menu`,{asMouse:!0}]])])]),_:1})]))}}),CargoLoadPopup_default=__plugin_vue_export_helper_default(_sfc_main$260,[[`__scopeId`,`data-v-0d30652e`]]),_hoisted_1$230={class:`settings-wrapper`,"bng-ui-scope":`cargoScreenSettings`},_hoisted_2$188={class:`cardContent`},_hoisted_3$164={class:`content`},_hoisted_4$137={class:`acceptButton`},__default__$2={wrapper:{fade:!0,blur:!0,style:popupContainer.default},position:[popupPosition.center,popupPosition.center]},_sfc_main$259=Object.assign(__default__$2,{__name:`CargoScreenSettings`,emits:[`return`],setup(__props,{emit:__emit}){useUINavScope(`cargoScreenSettings`);let emit$1=__emit,cargoOverviewStore=useCargoOverviewStore();ref();let facilityGroupingItems=[{label:`Item one`,value:1},{label:`Item two`,value:2},{label:`Item three`,value:3},{label:`Item four`,value:4},{label:`Item five`,value:5},{label:`Item six`,value:6},{label:`Item seven`,value:7},{label:`Item eight`,value:8},{label:`Item nine`,value:9},{label:`Item ten`,value:10},{label:`Item eleven`,value:11},{label:`Item twelve`,value:12},{label:`Item thirteen`,value:13},{label:`Item fourteen`,value:14},{label:`Item fifteen`,value:15},{label:`Item sixteen`,value:16},{label:`Item seventeen`,value:17},{label:`Item eighteen`,value:18},{label:`Item nineteen`,value:19},{label:`Item twenty`,value:20}];ref(),ref(),ref();let setFacilityGroupKey=key=>{cargoOverviewStore.facilityGroupingKey=key},setFacilitySortKey=key=>{cargoOverviewStore.facilitySortingKey=key},setPlayerGroupKey=key=>{cargoOverviewStore.playerGroupingKey=key},setPlayerSortKey=key=>{cargoOverviewStore.playerSortingKey=key};onMounted(()=>{console.log(facilityGroupingItems)});let acceptClickHandler=()=>{emit$1(`return`,!0)};return(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$230,[createVNode(unref(bngCard_default),null,{default:withCtx(()=>[createVNode(unref(bngCardHeading_default),{type:`ribbon`},{default:withCtx(()=>[..._cache[1]||=[createTextVNode(`Settings`,-1)]]),_:1}),createVNode(unref(bngCardHeading_default),null,{default:withCtx(()=>[..._cache[2]||=[createTextVNode(`Facility Display`,-1)]]),_:1}),createBaseVNode(`div`,_hoisted_2$188,[createBaseVNode(`div`,null,[_cache[3]||=createTextVNode(` Group By: `,-1),(openBlock(!0),createElementBlock(Fragment,null,renderList(unref(cargoOverviewStore).selectedFilter.groupings,gKey=>(openBlock(),createBlock(unref(bngButton_default),{onClick:$event=>setFacilityGroupKey(gKey)},{default:withCtx(()=>[createTextVNode(toDisplayString(unref(cargoOverviewStore).cargoData.facilityCardGroupSets[gKey].label),1)]),_:2},1032,[`onClick`]))),256))]),createBaseVNode(`div`,null,[_cache[4]||=createTextVNode(` Sorting: `,-1),(openBlock(!0),createElementBlock(Fragment,null,renderList(unref(cargoOverviewStore).cargoData.facilityCardGroupSets[unref(cargoOverviewStore).facilityGroupingKey].sortings,sKey=>(openBlock(),createBlock(unref(bngButton_default),{onClick:$event=>setFacilitySortKey(sKey)},{default:withCtx(()=>[createTextVNode(toDisplayString(unref(cargoOverviewStore).cargoData.sortingSets[sKey].label),1)]),_:2},1032,[`onClick`]))),256))])]),createBaseVNode(`div`,_hoisted_3$164,[createVNode(unref(bngCardHeading_default),null,{default:withCtx(()=>[..._cache[5]||=[createTextVNode(`My Cargo Display`,-1)]]),_:1}),createVNode(unref(bngSwitch_default),{modelValue:unref(cargoOverviewStore).automaticRoute,"onUpdate:modelValue":_cache[0]||=$event=>unref(cargoOverviewStore).automaticRoute=$event},{default:withCtx(()=>[..._cache[6]||=[createTextVNode(` Automatic route `,-1)]]),_:1},8,[`modelValue`]),createBaseVNode(`div`,null,[_cache[7]||=createTextVNode(` Group By: `,-1),(openBlock(!0),createElementBlock(Fragment,null,renderList(unref(cargoOverviewStore).playerGroupings,gKey=>(openBlock(),createBlock(unref(bngButton_default),{onClick:$event=>setPlayerGroupKey(gKey)},{default:withCtx(()=>[createTextVNode(toDisplayString(unref(cargoOverviewStore).cargoData.playerCardGroupSets[gKey].label),1)]),_:2},1032,[`onClick`]))),256))]),createBaseVNode(`div`,null,[_cache[8]||=createTextVNode(` Sorting: `,-1),(openBlock(!0),createElementBlock(Fragment,null,renderList(unref(cargoOverviewStore).cargoData.playerCardGroupSets[unref(cargoOverviewStore).facilityGroupingKey].sortings,sKey=>(openBlock(),createBlock(unref(bngButton_default),{onClick:$event=>setPlayerSortKey(sKey)},{default:withCtx(()=>[createTextVNode(toDisplayString(unref(cargoOverviewStore).cargoData.sortingSets[sKey].label),1)]),_:2},1032,[`onClick`]))),256))]),createBaseVNode(`div`,_hoisted_4$137,[withDirectives(createVNode(unref(bngButton_default),{label:`Continue`,accent:unref(ACCENTS).primary,onClick:acceptClickHandler},null,8,[`accent`]),[[unref(BngOnUiNav_default),void 0,`back,menu`,{asMouse:!0}]])])])]),_:1})]))}}),CargoScreenSettings_default=__plugin_vue_export_helper_default(_sfc_main$259,[[`__scopeId`,`data-v-9dd4f12f`]]),_forEach=(arr,func)=>Array.isArray(arr)&&arr.length>0&&arr.forEach(func);const useCargoOverviewStore=defineStore(`cargoOverview`,()=>{let{events:events$3}=useBridge(),cargoData=ref(),dropDownData=ref({}),newCargoAvailable=ref(!1),cargoHighlighted=ref(!1),automaticRoute=ref(!1),detailedDropOff=ref(!1),tutorialInfo=ref(),facilityGroupingKey=ref(`destinations`),facilitySortingKey=ref(`rewardMoney`),playerGroupings=[`containers`,`tasklist`,`ungrouped`],playerGroupingKey=ref(`tasklist`),playerSortingKey=ref(`cardId`),facilityId,parkingSpotPath,facilityFilter={value:`facility-info`,label:`Facility Info`,showInFilterTabs:!0,isFacilityPage:!0},filterSets=ref({}),filterSetsByValue=ref({}),selectedFilterRef=ref(),selectedFilter=ref(facilityFilter),selectFilter=f=>{Lua_default.career_modules_delivery_general.setSetting(`selectedFilterKey`,f),Lua_default.career_modules_delivery_cargoScreen.setCargoScreenTab(f);for(let filter of filterSets.value)if(filter.value==f[0]){let prevGrouping=facilityGroupingKey.value,prevSorting=facilitySortingKey.value;if(selectedFilter.value=filter,!filter.isFacilityPage&&(filter.groupings.includes(prevGrouping)||(facilityGroupingKey.value=filter.groupings[0]),cargoData.value.facilityCardGroupSets[facilityGroupingKey.value].sortings.includes(prevSorting)||(facilitySortingKey.value=cargoData.value.facilityCardGroupSets[facilityGroupingKey.value].sortings[0]),selectedCargo.value&&selectedCargo.value.isFacilityCard)){let contained=selectedCargo.value.filterTags[filter.value];if(contained)for(let groupKey of filter.groupings)for(let group of cargoData.value.facilityCardGroupSets[groupKey].groups)contained||=group.cardIdsUnsorted.includes(selectedCargo.value.cardId);contained||(selectedCargo.value=void 0)}}},facilityGroupings=computed(()=>selectedFilter.value?selectedFilter.value.groupings:[]),nextFacilityGrouping=()=>{let groups=facilityGroupings.value;facilityGroupingKey.value=groups[(groups.indexOf(facilityGroupingKey.value)+1)%groups.length]},facilitySortings=computed(()=>cargoData.value&&facilityGroupingKey.value&&cargoData.value.facilityCardGroupSets&&cargoData.value.facilityCardGroupSets[facilityGroupingKey.value]?cargoData.value.facilityCardGroupSets[facilityGroupingKey.value].sortings:[]),nextFacilitySorting=()=>{let group=facilitySortings.value;facilitySortingKey.value=group[(group.indexOf(facilitySortingKey.value)+1)%group.length]},nextPlayerGrouping=()=>{let groups=playerGroupings;playerGroupingKey.value=groups[(groups.indexOf(playerGroupingKey.value)+1)%groups.length]},playerSortings=computed(()=>cargoData.value&&facilityGroupingKey.value&&cargoData.value.playerCardGroupSets&&cargoData.value.playerCardGroupSets[facilityGroupingKey.value]?cargoData.value.playerCardGroupSets[facilityGroupingKey.value].sortings:[]),nextPlayerSorting=()=>{let group=cargoData.value.playerCardGroupSets[facilityGroupingKey.value];playerSortingKey.value=group[(group.indexOf(playerSortingKey.value)+1)%group.length]},currentFilterTutorialInfo=computed(()=>{if(!tutorialInfo.value||!selectedFilter.value)return null;let info=tutorialInfo.value[selectedFilter.value.value];return!info||!info.unlocked||!info.isActive?null:info}),openCargoScreenSettings=()=>{addPopup(CargoScreenSettings_default)},sortedParcelOffersByCargoType=computed(()=>{if(!cargoData.value||!cargoData.value.facility||!cargoData.value.facility.outgoingCargo)return{};let sorted={};for(let cargoType in _forEach(cargoData.value.facility.outgoingCargo,cargo=>{sorted[cargo.type]||(sorted[cargo.type]=[]),sorted[cargo.type].push(cargo)}),sorted)sorted[cargoType]=sortByProperty(sorted[cargoType]);return sorted}),sortedVehicleOffers=computed(()=>!cargoData.value||!cargoData.value.facility?[]:sortByProperty(cargoData.value.facility.vehicleOffers)),sortedTrailerOffers=computed(()=>!cargoData.value||!cargoData.value.facility?[]:sortByProperty(cargoData.value.facility.trailerOffers)),sortedAcceptedOffers=computed(()=>cargoData.value?sortByProperty(cargoData.value.player.acceptedOffers):[]),loanerOffers=computed(()=>{if(!cargoData.value||!cargoData.value.facility||!cargoData.value.facility.loanableVehicles)return[];let result=[];return result=result.concat(cargoData.value.facility.loanableVehicles),result}),menuClosed=()=>{cargoData.value=void 0,dropDownData.value={},selectedFilter.value=facilityFilter,selectedCargo.value=void 0,Lua_default.career_modules_delivery_cargoScreen.showCargoRoutePreview(void 0),loadingPrompt&&loadingPrompt.close(null)},requestCargoData=(_facilityId,_parkingSpotPath,updateMaxTimeStamp)=>{facilityId=_facilityId,parkingSpotPath=_parkingSpotPath,Lua_default.career_modules_delivery_cargoScreen.requestCargoDataForUi(facilityId,parkingSpotPath,updateMaxTimeStamp),updateMaxTimeStamp!=0&&(newCargoAvailable.value=!1)},requestCargoDataSimple=()=>{requestCargoData(facilityId,parkingSpotPath,!1)},moveCargoToLocation=(cargoId,targetLocation,skipRequest)=>{Lua_default.career_modules_delivery_cargoScreen.moveCargoFromUi(cargoId,targetLocation),skipRequest||requestCargoData(facilityId,parkingSpotPath,!1)},requestMoveCargoToLocation=(cargoId,moveData,skipRequest)=>{moveData.extraData?openThrowAwayPopup(cargoId,moveData.location,`Throw this cargo away with a `+moveData.extraData.penalty.toFixed(2)+` penalty?`):moveCargoToLocation(cargoId,moveData.location,skipRequest)};async function openThrowAwayPopup(cargoId,targetLocation,message){await openConfirmation(null,message)?moveCargoToLocation(cargoId,targetLocation):setCargoData()}let setCargoData=data=>{let previousCardId;if(selectedCargo.value&&(previousCardId=selectedCargo.value.cardId),data&&(cargoData.value=data),dropDownData.value={},cargoData.value.player&&cargoData.value.player.vehicles){getAutomaticRoute(data.settings.automaticRoute),getDetailedDropOff(data.settings.detailedDropOff),automaticRoute.value&&setAutomaticRoute(automaticRoute.value),filterSets.value=data.filterSets,filterSets.value.unshift(facilityFilter);for(let filter of filterSets.value)filterSetsByValue.value[filter.value]=filter;selectedFilter.value||=filterSets.value[0],previousCardId&&onCargoSelected(cargoData.value.cardsById[previousCardId]),tutorialInfo.value=data.tutorialInfo}},highlightedCards=ref({}),highlightCardIds=highlightedIdMap=>{highlightedCards.value=highlightedIdMap},focusedCargo=ref();ref();let selectedCargo=ref(),onCargoHovered=cargo=>{focusedCargo.value=cargo,highlightRoute(focusedCargo.value)},onCargoSelected=cargo=>{selectedCargo.value=cargo},highlightRoute=card=>{card?Lua_default.career_modules_delivery_cargoScreen.showRoutePreview(card.route):Lua_default.career_modules_delivery_cargoScreen.showRoutePreview(void 0)},setAutomaticRoute=(newValue,oldValue)=>{newValue!=oldValue&&Lua_default.career_modules_delivery_general.setAutomaticRoute(newValue)};watch(()=>automaticRoute.value,setAutomaticRoute);let getAutomaticRoute=enabled=>{automaticRoute.value=enabled};watch(()=>detailedDropOff.value,(newValue,oldValue)=>{newValue!=oldValue&&Lua_default.career_modules_delivery_general.setDetailedDropOff(newValue)});let getDetailedDropOff=enabled=>{detailedDropOff.value=enabled},setGroupingAndSorting=()=>{},cardClicked=card=>{switch(card.cardType){case`parcelGroup`:loadCargoAuto(card);break;case`vehicleOffer`:loadOffer(card);break;case`storage`:loadStorageCustom(card);break}},cardDeselect=()=>onCargoSelected(),cardHovered=card=>{onCargoHovered(card)},clearLoad=cargo=>{for(let id of cargo.ids)Lua_default.career_modules_delivery_cargoScreen.clearTransientMoveForCargo(id);requestCargoDataSimple()},throwAway=card=>{loadingPrompt=addPopup(CargoLoadPopup_default,{cargo:card,throwAway:!0}).promise},changeDistribution=cargo=>{for(let[id,card]of Object.entries(cargoData.value.cardsById))if(card.isFacilityCard&&card.cardType==`parcelGroup`&&card.ids.includes(cargo.ids[0])){loadCargoCustom(card);return}},modifyMaterialLoad=cargo=>{for(let[id,card]of Object.entries(cargoData.value.cardsById))if(card.isFacilityCard&&card.cardType==`storage`&&card.storage.materialType==cargo.materialType){loadStorageCustom(card);return}},loadCargoAuto=cargo=>{for(let id of cargo.ids)Lua_default.career_modules_delivery_cargoScreen.clearTransientMoveForCargo(id);let idx=0;for(let loc of cargo.autoLoadLocations)Lua_default.career_modules_delivery_cargoScreen.moveCargoFromUi(cargo.ids[idx],loc),idx++;requestCargoDataSimple()},loadingPrompt=null,loadCargoCustom=card=>{if(card.transientMove){let cargoId=card.ids[0];for(let[id,otherCard]of Object.entries(cargoData.value.cardsById))if(otherCard.isFacilityCard&&otherCard.cardType==`parcelGroup`&&otherCard.ids.includes(cargoId)){loadingPrompt=addPopup(CargoLoadPopup_default,{cargo:otherCard}).promise;return}}else loadingPrompt=addPopup(CargoLoadPopup_default,{cargo:card}).promise},loadStorageCustom=storageData=>{loadingPrompt=addPopup(CargoLoadPopup_default,{storageData}).promise},loadOffer=offer=>{Lua_default.career_modules_delivery_cargoScreen.toggleOfferForSpawning(offer.id),requestCargoDataSimple()},loadLoaner=offer=>{Lua_default.career_modules_loanerVehicles.markForSpawning(offer),requestCargoDataSimple()},returnLoaner=vehId=>{Lua_default.career_modules_loanerVehicles.returnVehicle(vehId).then(()=>{requestCargoDataSimple()})};async function abandonOffer(card){await openConfirmation(null,`Abandon `+card.name+`? There is a `+card.abandonInfo.penaltyMoney+`$ penalty.`)&&(Lua_default.career_modules_delivery_cargoScreen.abandonAcceptedOffer(card.abandonInfo.vehId),requestCargoDataSimple())}return events$3.on(`automaticRouteSet`,getAutomaticRoute),events$3.on(`cargoDataForUiReady`,setCargoData),events$3.on(`newCargoAvailable`,()=>newCargoAvailable.value=!0),events$3.on(`sendHighlightedCardIds`,highlightCardIds),events$3.on(`requestCargoDataSimple`,requestCargoDataSimple),{cargoData,tutorialInfo,sortedParcelOffersByCargoType,sortedVehicleOffers,sortedTrailerOffers,sortedAcceptedOffers,onCargoHovered,onCargoSelected,loanerOffers,dropDownData,newCargoAvailable,cargoHighlighted,automaticRoute,detailedDropOff,setGroupingAndSorting,requestCargoData,requestCargoDataSimple,requestMoveCargoToLocation,menuClosed,dispose:()=>{events$3.off(`cargoDataForUiReady`),events$3.off(`newCargoAvailable`),events$3.off(`sendHighlightedCardIds`),events$3.on(`requestCargoDataSimple`)},focusedCargo,selectedCargo,cardClicked,cardHovered,cardDeselect,clearLoad,changeDistribution,loadCargoAuto,loadCargoCustom,throwAway,loadStorageCustom,loadOffer,abandonOffer,loadLoaner,returnLoaner,modifyMaterialLoad,filterSets,filterSetsByValue,selectedFilterRef,selectedFilter,selectFilter,highlightedCards,openCargoScreenSettings,nextFacilityGrouping,nextFacilitySorting,nextPlayerGrouping,nextPlayerSorting,facilityGroupingKey,facilitySortingKey,playerGroupingKey,playerSortingKey,facilityGroupings,facilitySortings,playerGroupings,playerSortings,currentFilterTutorialInfo}});var _hoisted_1$229={class:`fill-panel`},_hoisted_2$187={key:1,class:`groupGrid`},_sfc_main$258={__name:`ProvidedOrdersPanel`,props:{groupSets:Object,groupIdx:[Number,String],sortingSets:Object,sortIdx:[Number,String],sortAsc:{type:Boolean,default:!0},ignoreFilter:Boolean},setup(__props){let cargoOverviewStore=useCargoOverviewStore(),props=__props;computed(()=>props.groupSets&&props.groupSets[props.groupIdx]&&props.groupSets[props.groupIdx].groups?props.groupSets[props.groupIdx].groups:[]);let sortedGroups=computed(()=>{let groupSet=props.groupSets[props.groupIdx];if(!cargoOverviewStore.cargoData||!cargoOverviewStore.cargoData.cardsById||!groupSet.groups||!groupSet.groups.length)return[];let groups=groupSet.groups,sortKey=props.sortingSets[props.sortIdx].key;function getHighestSortValue(group){let maxSortValue=-1/0;return group.cardIdsUnsorted&&group.cardIdsUnsorted.length&&group.cardIdsUnsorted.forEach(cardId=>{let card=cargoOverviewStore.cargoData.cardsById[cardId];if(card.filterTags[cargoOverviewStore.selectedFilter.value]||group.ignoreFilter||props.ignoreFilter){let sortValue=card.sortValues&&card.sortValues[sortKey]!==void 0?card.sortValues[sortKey]:1/0;sortValue>maxSortValue&&(maxSortValue=sortValue)}}),maxSortValue}return groups.sort((a$1,b)=>{let minValueA=getHighestSortValue(a$1),minValueB=getHighestSortValue(b);return props.sortAsc?minValueA-minValueB:minValueB-minValueA}),groups}),getSortedCardIds=group=>{if(!cargoOverviewStore.cargoData||!cargoOverviewStore.cargoData.cardsById||!group.cardIdsUnsorted)return[];let cardsById=cargoOverviewStore.cargoData.cardsById,sortKey=props.sortingSets[props.sortIdx].key;return group.cardIdsUnsorted&&group.cardIdsUnsorted.length?group.cardIdsUnsorted.slice().sort((a$1,b)=>{let cardA=cardsById[a$1],cardB=cardsById[b],valueA=cardA&&cardA.sortValues&&cardA.sortValues[sortKey]!==void 0?cardA.sortValues[sortKey]:0,valueB=cardB&&cardB.sortValues&&cardB.sortValues[sortKey]!==void 0?cardB.sortValues[sortKey]:0;return props.sortAsc?valueA-valueB:valueB-valueA}):[]};return(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$229,[unref(cargoOverviewStore).cargoData?unref(cargoOverviewStore).cargoData.cardsById?(openBlock(),createElementBlock(`div`,_hoisted_2$187,[(openBlock(!0),createElementBlock(Fragment,null,renderList(sortedGroups.value,group=>(openBlock(),createElementBlock(Fragment,{key:group.label},[(group.cardIdsUnsorted.length>0||group.showEmpty)&&(group.filterTags[unref(cargoOverviewStore).selectedFilter.value]||group.ignoreFilter||__props.ignoreFilter)?(openBlock(),createBlock(CardGroup_default,{key:0,label:group.label,meta:group.meta},{default:withCtx(()=>[(openBlock(!0),createElementBlock(Fragment,null,renderList(getSortedCardIds(group),cardId=>(openBlock(),createElementBlock(Fragment,{key:cardId},[unref(cargoOverviewStore).cargoData.cardsById[cardId].filterTags[unref(cargoOverviewStore).selectedFilter.value]||group.ignoreFilter||__props.ignoreFilter?(openBlock(),createBlock(CargoCard_default,{key:0,card:unref(cargoOverviewStore).cargoData.cardsById[cardId],onClick:withModifiers($event=>unref(cargoOverviewStore).onCargoSelected(unref(cargoOverviewStore).cargoData.cardsById[cardId]),[`stop`]),onMouseover:$event=>unref(cargoOverviewStore).onCargoHovered(unref(cargoOverviewStore).cargoData.cardsById[cardId]),onMouseleave:_cache[0]||=$event=>unref(cargoOverviewStore).onCargoHovered(),hideProps:__props.groupSets[__props.groupIdx].hideProps,hideModsAndTimer:__props.groupSets[__props.groupIdx].hideModsAndTimer},null,8,[`card`,`onClick`,`onMouseover`,`hideProps`,`hideModsAndTimer`])):createCommentVNode(``,!0)],64))),128))]),_:2},1032,[`label`,`meta`])):createCommentVNode(``,!0)],64))),128))])):createCommentVNode(``,!0):(openBlock(),createElementBlock(Fragment,{key:0},[createTextVNode(` No data yet... `)],64))]))}},ProvidedOrdersPanel_default=__plugin_vue_export_helper_default(_sfc_main$258,[[`__scopeId`,`data-v-877d97e8`]]),_hoisted_1$228={class:`header-text`},_hoisted_2$186={key:0,class:`disabled-reason noOffers`},_sfc_main$257={__name:`FilterCard`,props:{filter:Object},setup(__props){let props=__props,cargoOverviewStore=useCargoOverviewStore(),disabled=computed(()=>{if(props.filter){if(!props.filter.hasAvailableOffers)return{disabled:!0};if(props.filter.unavailableAtThisFacility)return{disabled:!0,reason:`Unavailable`};if(props.filter.lockedInfo)return{disabled:!0,reason:props.filter.lockedInfo.shortLabel}}return{disabled:!1}});return onMounted(()=>{}),(_ctx,_cache)=>(openBlock(),createBlock(unref(bngCard_default),{class:normalizeClass([`filterCard`,{disabled:disabled.value.disabled}]),onClick:_cache[0]||=withModifiers($event=>unref(cargoOverviewStore).selectFilter([__props.filter.value]),[`stop`])},{default:withCtx(()=>[createVNode(unref(bngCardHeading_default),{class:`card-heading`},{default:withCtx(()=>[createBaseVNode(`span`,_hoisted_1$228,toDisplayString(__props.filter.label),1)]),_:1}),createVNode(unref(aspectRatio_default),{class:`image`,ratio:`8:3`},{default:withCtx(()=>[createVNode(unref(bngIcon_default),{class:`glyph`,type:unref(icons)[__props.filter.icon]},null,8,[`type`]),createBaseVNode(`div`,{class:normalizeClass([`step`,{none:__props.filter.facilityCards===0}])},[createVNode(unref(bngPropVal_default),{class:`amount-avail`,valueLabel:`× `+__props.filter.facilityCards},null,8,[`valueLabel`])],2)]),_:1}),disabled.value.reason?(openBlock(),createElementBlock(`div`,_hoisted_2$186,[createVNode(unref(bngPropVal_default),{class:`amount-avail`,iconType:unref(icons).lockClosed,valueLabel:disabled.value.reason},null,8,[`iconType`,`valueLabel`])])):createCommentVNode(``,!0)]),_:1},8,[`class`]))}},FilterCard_default=__plugin_vue_export_helper_default(_sfc_main$257,[[`__scopeId`,`data-v-85dcf2d5`]]),_hoisted_1$227={key:0,class:`heading-container`},_hoisted_2$185={class:`status-add`},_hoisted_3$163={class:`controls-row`},_hoisted_4$136={key:1,class:`content-container`},_hoisted_5$119={class:`header-container`},_hoisted_6$102={class:`info-line`},_hoisted_7$89={class:`header-flex padding`},_hoisted_8$74={class:`groupSortButtons`},_hoisted_9$67={class:`scroll-panel`},_hoisted_10$58={key:0,class:`tasklist`},_hoisted_11$52={class:`tasklist-header`},_hoisted_12$41={class:`task-content`},_hoisted_13$34={class:`heading`},_hoisted_14$32={class:`description`},_hoisted_15$31={key:1,class:`empty-cargo-card`},_hoisted_16$31={class:`header-container`},_hoisted_17$25={class:`header-flex`},_hoisted_18$22={key:0,class:`map-overlay`},_hoisted_19$19={key:1,class:`empty-cargo-card`},_hoisted_20$16={class:`header-container`},_hoisted_21$15={class:`info-line`},_hoisted_22$13={class:`header-flex wrap padding`},_hoisted_23$12={class:`groupSortButtons`},_hoisted_24$11={class:`cargohold-info`},_hoisted_25$10={class:`scroll-panel padding`},_hoisted_26$8={class:`content`},_hoisted_27$8={key:0,class:`buttons-wrapper`},_hoisted_28$7={class:`content flex-container`},_hoisted_29$7={key:1,class:`header-flex progress-bar-padding`},_hoisted_30$7={key:0,class:`progress-bar-wrapper wide`},_hoisted_31$7=[`innerHTML`],_hoisted_32$7={class:`info-right`},_hoisted_33$7={key:0},_hoisted_34$7={key:0,class:`header-flex progress-bar-padding`},_hoisted_35$6={class:`progress-bar-wrapper wide`},_hoisted_36$6={class:`content`},_hoisted_37$5={class:`filterSelectGrid`},_sfc_main$256={__name:`CargoOverviewMain`,props:{facilityId:String,parkingSpotPath:String},setup(__props){let tabPills=ref();useUINavScope(`delivery`);let props=__props,cargoOverviewStore=useCargoOverviewStore();async function openDiscardPopup(){await openConfirmation(null,`Discard Changes?`)&&(Lua_default.career_modules_delivery_cargoScreen.cancelDeliveryConfiguration(),Lua_default.career_modules_delivery_cargoScreen.exitCargoOverviewScreen(),window.bngVue.gotoGameState(`play`))}let close=()=>{cargoOverviewStore.cargoData.confirmButtonInfo.itemCount>0&&props.facilityId?openDiscardPopup():(Lua_default.career_modules_delivery_cargoScreen.exitCargoOverviewScreen(),window.bngVue.gotoGameState(`play`))},acceptLoad=()=>{Lua_default.career_modules_delivery_cargoScreen.commitDeliveryConfiguration(),Lua_default.career_modules_delivery_cargoScreen.exitCargoOverviewScreen(),window.bngVue.gotoGameState(`play`)};async function openExitModePopup(){await openConfirmation(null,`Throw away all cargo and exit delivery mode?`)&&(Lua_default.career_modules_delivery_cargoScreen.exitDeliveryMode(),Lua_default.career_modules_delivery_cargoScreen.exitCargoOverviewScreen(),window.bngVue.gotoGameState(`play`))}let exitMode=()=>{openExitModePopup()};async function gotoSkillProgress(panel){cargoOverviewStore.cargoData.confirmButtonInfo.itemCount>0||window.bngVue.gotoGameState(`branchPage`,{params:{branchKey:panel.branchId,skillKey:panel.skillId}})}async function gotoOrganizations(id){cargoOverviewStore.cargoData.confirmButtonInfo.itemCount>0||window.bngVue.gotoGameState(`organizations`,{params:{orgId:id}})}let facilitySortAsc=ref(!1),playerSortAsc=ref(!0),activePopovers={},popShown=pop=>nextTick(()=>activePopovers[pop.name]=pop),popHidden=pop=>nextTick(()=>delete activePopovers[pop.name]);function popHideAll(){for(let pop of Object.values(activePopovers))pop.hide()}let screenCover=ref(),mapPanel=ref(null),observer$2,mapClipChanged;function resizer(){let elScreen=screenCover.value?.$el||screenCover.value;if(!mapPanel.value||!elScreen){mapClipChanged&&(mapClipChanged=!1,screenCover.value.style.setProperty(`--map-clip`,`unset`));return}let pad=3,{width:width$1,height:height$1}=elScreen.getBoundingClientRect(),rect=mapPanel.value.getBoundingClientRect(),percentile=[(rect.x+3)/width$1,(rect.y+3)/height$1,(rect.x+rect.width-3)/width$1,(rect.y+rect.height-3)/height$1].map(n=>`${n*100}%`);elScreen.style.setProperty(`--map-clip`,`polygon(0% 0%, 100% 0%, 100% 100%, 0% 100%, 0% 0%, ${percentile[0]} ${percentile[1]}, ${percentile[0]} ${percentile[3]}, ${percentile[2]} ${percentile[3]}, ${percentile[2]} ${percentile[1]}, ${percentile[0]} ${percentile[1]})`),mapClipChanged=!0,Lua_default.freeroam_bigMapMode.setBigmapScreenBounds({width:width$1,height:height$1},rect)}watch(()=>mapPanel.value,(elm,prev)=>{prev&&observer$2.unobserve(prev),elm&&observer$2.observe(elm)},{immediate:!0}),watch(()=>cargoOverviewStore.selectedFilter?.isFacilityPage,()=>nextTick(resizer));let selectedFilters=ref([]);return watch(()=>cargoOverviewStore.selectedFilter,filter=>{selectedFilters.value=[filter.value],cargoOverviewStore.focusedCargo=null}),onMounted(()=>{observer$2=new ResizeObserver(resizer),resizer(),cargoOverviewStore.requestCargoData(props.facilityId,props.parkingSpotPath),selectedFilters.value=[cargoOverviewStore.selectedFilter.value]}),onBeforeUnmount(()=>{observer$2?.disconnect()}),onUnmounted(()=>{Lua_default.career_modules_delivery_cargoScreen.exitCargoOverviewScreen(),cargoOverviewStore.menuClosed()}),(_ctx,_cache)=>(openBlock(),createBlock(unref(layoutSingle_default),{class:`cargo-overview-main-layout`,"bng-ui-scope":`delivery`,ref_key:`screenCover`,ref:screenCover},{default:withCtx(()=>[createBaseVNode(`div`,{class:`screen`,onClick:_cache[10]||=$event=>unref(cargoOverviewStore).cardDeselect(),onClickCapture:popHideAll},[unref(cargoOverviewStore).cargoData?(openBlock(),createElementBlock(`div`,_hoisted_1$227,[createVNode(unref(bngScreenHeading_default),{preheadings:[`Delivery Mode`],divider:``},{default:withCtx(()=>[createTextVNode(toDisplayString(unref(cargoOverviewStore).cargoData.facility?unref(cargoOverviewStore).cargoData.facility.name:`My Cargo`),1)]),_:1}),createVNode(unref(bngCard_default),{class:`status-container`},{default:withCtx(()=>[createVNode(unref(careerStatus_default)),createBaseVNode(`div`,_hoisted_2$185,[(openBlock(!0),createElementBlock(Fragment,null,renderList(unref(cargoOverviewStore).cargoData.skillLevels,(skill,index)=>(openBlock(),createBlock(unref(bngPropVal_default),{key:index,iconType:unref(icons)[skill.icon],valueLabel:_ctx.$ctx_t(skill.levelLabel)},null,8,[`iconType`,`valueLabel`]))),128)),unref(cargoOverviewStore).cargoData.facility&&unref(cargoOverviewStore).cargoData.facility.organization?(openBlock(),createBlock(unref(bngPropVal_default),{key:0,iconType:unref(icons).peopleOutline,valueLabel:_ctx.$ctx_t(unref(cargoOverviewStore).cargoData.facility.organization.reputation.label)},null,8,[`iconType`,`valueLabel`])):createCommentVNode(``,!0)])]),_:1})])):createCommentVNode(``,!0),createBaseVNode(`div`,_hoisted_3$163,[withDirectives((openBlock(),createBlock(unref(bngButton_default),{class:`back-button`,accent:unref(ACCENTS).attention,onClick:close},{default:withCtx(()=>[createVNode(unref(bngBinding_default),{"ui-event":`back`,deviceMask:`xinput`}),createTextVNode(` `+toDisplayString(_ctx.$t(`ui.common.close`)),1)]),_:1},8,[`accent`])),[[unref(BngOnUiNav_default),void 0,`back,menu`,{asMouse:!0}]]),unref(cargoOverviewStore).cargoData&&unref(cargoOverviewStore).filterSets&&__props.facilityId?(openBlock(),createBlock(unref(bngPillFilters_default),{key:0,ref_key:`tabPills`,ref:tabPills,required:``,modelValue:selectedFilters.value,"onUpdate:modelValue":_cache[0]||=$event=>selectedFilters.value=$event,options:unref(cargoOverviewStore).filterSets,onValueChanged:unref(cargoOverviewStore).selectFilter},null,8,[`modelValue`,`options`,`onValueChanged`])):createCommentVNode(``,!0),!__props.facilityId&&unref(cargoOverviewStore).cargoData&&unref(cargoOverviewStore).cargoData.player.penaltyForAbandon.money<0?(openBlock(),createBlock(unref(bngButton_default),{key:1,accent:`attention`,iconLeft:unref(icons).trashBin1,onClick:exitMode,class:`right-button`},{default:withCtx(()=>[..._cache[11]||=[createTextVNode(` Abandon all deliveries `,-1)]]),_:1},8,[`iconLeft`])):createCommentVNode(``,!0)]),unref(cargoOverviewStore).cargoData?(openBlock(),createElementBlock(`div`,_hoisted_4$136,[!unref(cargoOverviewStore).selectedFilter.isFacilityPage||!__props.facilityId?(openBlock(),createElementBlock(`div`,{key:0,class:normalizeClass([`panel-flex`,{reverse:!__props.facilityId}])},[__props.facilityId?(openBlock(),createBlock(unref(bngCard_default),{key:0,class:`content-row provided-orders-panel`},{default:withCtx(()=>[createBaseVNode(`div`,_hoisted_5$119,[unref(cargoOverviewStore).selectedFilter?(openBlock(),createBlock(unref(bngCardHeading_default),{key:0,type:`ribbon`,class:`cardHeadingFlex wide`},{default:withCtx(()=>[createBaseVNode(`span`,null,toDisplayString(unref(cargoOverviewStore).selectedFilter.label),1),unref(cargoOverviewStore).selectedFilter.howTo?(openBlock(),createBlock(TutorialButton_default,{key:0,class:`howto-button right`,accent:`secondary`,icon:unref(icons).help,pages:unref(cargoOverviewStore).selectedFilter.howTo.pages},null,8,[`icon`,`pages`])):createCommentVNode(``,!0)]),_:1})):createCommentVNode(``,!0),createBaseVNode(`div`,_hoisted_6$102,[createVNode(unref(bngIcon_default),{type:unref(icons).info},null,8,[`type`]),createBaseVNode(`span`,null,toDisplayString(unref(cargoOverviewStore).selectedFilter.shortDescription),1)]),createBaseVNode(`div`,_hoisted_7$89,[withDirectives((openBlock(),createBlock(unref(bngButton_default),{class:`groupSortButton`,accent:unref(ACCENTS).text,icon:unref(icons).group,onClick:_cache[1]||=withModifiers(()=>{},[`stop`])},{default:withCtx(()=>[createTextVNode(` Grouping: `+toDisplayString(unref(cargoOverviewStore).cargoData.facilityCardGroupSets[unref(cargoOverviewStore).facilityGroupingKey].label),1)]),_:1},8,[`accent`,`icon`])),[[unref(BngPopover_default),`facility-grouping`,`bottom`,{click:!0}]]),createVNode(unref(bngPopoverMenu_default),{name:`facility-grouping`,focus:``,onShow:popShown,onHide:popHidden},{default:withCtx(({hide:hide$2})=>[(openBlock(!0),createElementBlock(Fragment,null,renderList(unref(cargoOverviewStore).facilityGroupings,key=>withDirectives((openBlock(),createBlock(unref(bngButton_default),{key,accent:unref(ACCENTS).menu,class:normalizeClass({selected:unref(cargoOverviewStore).facilityGroupingKey===key}),onClick:withModifiers(()=>{unref(cargoOverviewStore).facilityGroupingKey=key,hide$2()},[`stop`])},{default:withCtx(()=>[createTextVNode(toDisplayString(unref(cargoOverviewStore).cargoData.facilityCardGroupSets[key].label),1)]),_:2},1032,[`accent`,`class`,`onClick`])),[[unref(BngOnUiNav_default),void 0,`ok`,{focusRequired:!0,asMouse:!0}]])),128))]),_:1}),createBaseVNode(`div`,_hoisted_8$74,[withDirectives((openBlock(),createBlock(unref(bngButton_default),{class:`groupSortButton`,accent:unref(ACCENTS).text,icon:unref(icons).order,onClick:_cache[2]||=withModifiers(()=>{},[`stop`])},{default:withCtx(()=>[createTextVNode(` Sorting: `+toDisplayString(unref(cargoOverviewStore).cargoData.sortingSets[unref(cargoOverviewStore).facilitySortingKey].label),1)]),_:1},8,[`accent`,`icon`])),[[unref(BngPopover_default),`facility-sorting`,`bottom`,{click:!0}]]),withDirectives(createVNode(unref(bngButton_default),{class:`groupSortButtonSmall`,accent:unref(ACCENTS).text,icon:facilitySortAsc.value?unref(icons).sortAsc:unref(icons).sortDesc,onClick:_cache[3]||=withModifiers($event=>facilitySortAsc.value=!facilitySortAsc.value,[`stop`])},null,8,[`accent`,`icon`]),[[unref(BngTooltip_default),facilitySortAsc.value?`Ascending order`:`Descending order`,`top`]])]),createVNode(unref(bngPopoverMenu_default),{name:`facility-sorting`,focus:``,onShow:popShown,onHide:popHidden},{default:withCtx(({hide:hide$2})=>[(openBlock(!0),createElementBlock(Fragment,null,renderList(unref(cargoOverviewStore).facilitySortings,key=>withDirectives((openBlock(),createBlock(unref(bngButton_default),{key,accent:unref(ACCENTS).menu,class:normalizeClass({selected:unref(cargoOverviewStore).facilitySortingKey===key}),onClick:()=>{unref(cargoOverviewStore).facilitySortingKey=key,hide$2()}},{default:withCtx(()=>[createTextVNode(toDisplayString(unref(cargoOverviewStore).cargoData.sortingSets[key].label),1)]),_:2},1032,[`accent`,`class`,`onClick`])),[[unref(BngOnUiNav_default),void 0,`ok`,{focusRequired:!0,asMouse:!0}]])),128))]),_:1})])]),_cache[12]||=createBaseVNode(`div`,{class:`separator`},null,-1),createBaseVNode(`div`,_hoisted_9$67,[unref(cargoOverviewStore).currentFilterTutorialInfo?.tasks?(openBlock(),createElementBlock(`div`,_hoisted_10$58,[createBaseVNode(`div`,_hoisted_11$52,toDisplayString(unref(cargoOverviewStore).selectedFilter.label)+` Tutorial `,1),(openBlock(!0),createElementBlock(Fragment,null,renderList(unref(cargoOverviewStore).currentFilterTutorialInfo.tasks,task=>(openBlock(),createElementBlock(`div`,{class:`task`,key:task.label},[createVNode(unref(bngIcon_default),{class:`icon`,type:unref(icons)[task.done?`checkboxOn`:`checkboxOff`]},null,8,[`type`]),createBaseVNode(`div`,_hoisted_12$41,[createBaseVNode(`div`,_hoisted_13$34,toDisplayString(task.label),1),createBaseVNode(`div`,_hoisted_14$32,toDisplayString(task.description),1)])]))),128))])):createCommentVNode(``,!0),createVNode(ProvidedOrdersPanel_default,{groupSets:unref(cargoOverviewStore).cargoData.facilityCardGroupSets,groupIdx:unref(cargoOverviewStore).facilityGroupingKey,sortingSets:unref(cargoOverviewStore).cargoData.sortingSets,sortIdx:unref(cargoOverviewStore).facilitySortingKey,sortAsc:facilitySortAsc.value,onCardHovered:unref(cargoOverviewStore).cardHovered,onCardClicked:unref(cargoOverviewStore).cardClicked},null,8,[`groupSets`,`groupIdx`,`sortingSets`,`sortIdx`,`sortAsc`,`onCardHovered`,`onCardClicked`])])]),_:1})):createCommentVNode(``,!0),createBaseVNode(`div`,{class:normalizeClass([`content-row selected-and-map-panel`,{wide:!__props.facilityId}])},[__props.facilityId?(openBlock(),createBlock(unref(bngCard_default),{key:0,class:`cargo-detail`},{default:withCtx(()=>[unref(cargoOverviewStore).focusedCargo||unref(cargoOverviewStore).selectedCargo?(openBlock(),createBlock(CargoCard_default,{key:0,card:unref(cargoOverviewStore).focusedCargo||unref(cargoOverviewStore).selectedCargo,detailed:``,"show-buttons":!unref(cargoOverviewStore).focusedCargo&&unref(cargoOverviewStore).selectedCargo||unref(cargoOverviewStore).focusedCargo===unref(cargoOverviewStore).selectedCargo},null,8,[`card`,`show-buttons`])):(openBlock(),createElementBlock(`div`,_hoisted_15$31,`Select a card to view details.`))]),_:1})):createCommentVNode(``,!0),createBaseVNode(`div`,{class:`map`,ref_key:`mapPanel`,ref:mapPanel},[createBaseVNode(`div`,_hoisted_16$31,[createBaseVNode(`div`,_hoisted_17$25,[createVNode(unref(bngCardHeading_default),{type:`ribbon`,class:`cardHeading wide`},{default:withCtx(()=>[createTextVNode(toDisplayString(_ctx.$t(unref(cargoOverviewStore).cargoData.levelInfo.name)),1)]),_:1}),createVNode(unref(bngSwitch_default),{modelValue:unref(cargoOverviewStore).automaticRoute,"onUpdate:modelValue":_cache[4]||=$event=>unref(cargoOverviewStore).automaticRoute=$event,onClick:_cache[5]||=withModifiers(()=>{},[`stop`])},{default:withCtx(()=>[..._cache[13]||=[createTextVNode(` Automatic route `,-1)]]),_:1},8,[`modelValue`])])]),__props.facilityId?createCommentVNode(``,!0):(openBlock(),createElementBlock(`div`,_hoisted_18$22,[createVNode(unref(bngCard_default),{class:`cargo-detail`},{default:withCtx(()=>[unref(cargoOverviewStore).focusedCargo||unref(cargoOverviewStore).selectedCargo?(openBlock(),createBlock(CargoCard_default,{key:0,card:unref(cargoOverviewStore).focusedCargo||unref(cargoOverviewStore).selectedCargo,detailed:``,"show-buttons":!unref(cargoOverviewStore).focusedCargo&&unref(cargoOverviewStore).selectedCargo||unref(cargoOverviewStore).focusedCargo===unref(cargoOverviewStore).selectedCargo},null,8,[`card`,`show-buttons`])):(openBlock(),createElementBlock(`div`,_hoisted_19$19,` Select a card to view details. `))]),_:1})]))],512)],2),createVNode(unref(bngCard_default),{class:`content-row my-cargo-panel`},{default:withCtx(()=>[createBaseVNode(`div`,_hoisted_20$16,[createVNode(unref(bngCardHeading_default),{type:`ribbon`,class:`cardHeadingFlex wide`},{default:withCtx(()=>[_cache[14]||=createBaseVNode(`span`,null,`My Cargo`,-1),createVNode(TutorialButton_default,{class:`howto-button right`,accent:`secondary`,icon:unref(icons).help,pages:[`delivery/myCargo`,`delivery/parcelDelivery`]},null,8,[`icon`])]),_:1}),createBaseVNode(`div`,_hoisted_21$15,[createVNode(unref(bngIcon_default),{type:unref(icons).info},null,8,[`type`]),_cache[15]||=createBaseVNode(`span`,null,`Check your loaded cargo and other delivery-related tasks.`,-1)]),createBaseVNode(`div`,_hoisted_22$13,[withDirectives((openBlock(),createBlock(unref(bngButton_default),{class:`groupSortButton`,accent:unref(ACCENTS).text,icon:unref(icons).group,onClick:_cache[6]||=withModifiers(()=>{},[`stop`])},{default:withCtx(()=>[createTextVNode(` Grouping: `+toDisplayString(unref(cargoOverviewStore).cargoData.playerCardGroupSets[unref(cargoOverviewStore).playerGroupingKey].label),1)]),_:1},8,[`accent`,`icon`])),[[unref(BngPopover_default),`player-grouping`,`bottom`,{click:!0}]]),createVNode(unref(bngPopoverMenu_default),{name:`player-grouping`,focus:``,onShow:popShown,onHide:popHidden},{default:withCtx(({hide:hide$2})=>[(openBlock(!0),createElementBlock(Fragment,null,renderList(unref(cargoOverviewStore).playerGroupings,key=>withDirectives((openBlock(),createBlock(unref(bngButton_default),{key,accent:unref(ACCENTS).menu,class:normalizeClass({selected:unref(cargoOverviewStore).playerGroupingKey===key}),onClick:()=>{unref(cargoOverviewStore).playerGroupingKey=key,hide$2()}},{default:withCtx(()=>[createTextVNode(toDisplayString(unref(cargoOverviewStore).cargoData.playerCardGroupSets[key].label),1)]),_:2},1032,[`accent`,`class`,`onClick`])),[[unref(BngOnUiNav_default),void 0,`ok`,{focusRequired:!0,asMouse:!0}]])),128))]),_:1}),createBaseVNode(`div`,_hoisted_23$12,[withDirectives((openBlock(),createBlock(unref(bngButton_default),{class:`groupSortButton`,accent:unref(ACCENTS).text,icon:unref(icons).order,onClick:_cache[7]||=withModifiers(()=>{},[`stop`])},{default:withCtx(()=>[createTextVNode(` Sorting: `+toDisplayString(unref(cargoOverviewStore).cargoData.sortingSets[unref(cargoOverviewStore).playerSortingKey].label),1)]),_:1},8,[`accent`,`icon`])),[[unref(BngPopover_default),`player-sorting`,`bottom`,{click:!0}]]),withDirectives(createVNode(unref(bngButton_default),{class:`groupSortButtonSmall`,accent:unref(ACCENTS).text,icon:playerSortAsc.value?unref(icons).sortAsc:unref(icons).sortDesc,onClick:_cache[8]||=withModifiers($event=>playerSortAsc.value=!playerSortAsc.value,[`stop`])},null,8,[`accent`,`icon`]),[[unref(BngTooltip_default),playerSortAsc.value?`Ascending order`:`Descending order`,`top`]])]),createVNode(unref(bngPopoverMenu_default),{name:`player-sorting`,focus:``,onShow:popShown,onHide:popHidden},{default:withCtx(({hide:hide$2})=>[(openBlock(!0),createElementBlock(Fragment,null,renderList(unref(cargoOverviewStore).playerSortings,key=>withDirectives((openBlock(),createBlock(unref(bngButton_default),{key,accent:unref(ACCENTS).menu,class:normalizeClass({selected:unref(cargoOverviewStore).playerSortingKey===key}),onClick:withModifiers(()=>{unref(cargoOverviewStore).playerSortingKey=key,hide$2()},[`stop`])},{default:withCtx(()=>[createTextVNode(toDisplayString(unref(cargoOverviewStore).cargoData.sortingSets[key].label),1)]),_:2},1032,[`accent`,`class`,`onClick`])),[[unref(BngOnUiNav_default),void 0,`ok`,{focusRequired:!0,asMouse:!0}]])),128))]),_:1}),createBaseVNode(`div`,_hoisted_24$11,[(openBlock(!0),createElementBlock(Fragment,null,renderList(unref(cargoOverviewStore).cargoData.playerCardGroupSets.totalStorages.groups,(group,index)=>(openBlock(),createElementBlock(Fragment,{key:index},[group.meta.totalCargoSlots?(openBlock(),createBlock(CargoInfo_default,{key:0,class:`info-with-gradient`,meta:group.meta},null,8,[`meta`])):createCommentVNode(``,!0)],64))),128))])])]),_cache[17]||=createBaseVNode(`div`,{class:`separator`},null,-1),createBaseVNode(`div`,_hoisted_25$10,[unref(cargoOverviewStore).selectedFilter.noContainers?(openBlock(),createBlock(unref(bngCard_default),{key:0,class:`no-container-card`},{default:withCtx(()=>[createBaseVNode(`div`,_hoisted_26$8,[createBaseVNode(`span`,null,[createVNode(unref(bngIcon_default),{type:unref(icons).info},null,8,[`type`]),_cache[16]||=createTextVNode(` You do not have any containers installed that can load this type of cargo. `,-1)]),createVNode(TutorialButton_default,{class:`button`,accent:`secondary`,icon:unref(icons).help,pages:[`delivery/cargoContainerHowTo`],text:`How do I install cargo containers?`},null,8,[`icon`])])]),_:1})):createCommentVNode(``,!0),createVNode(ProvidedOrdersPanel_default,{groupSets:unref(cargoOverviewStore).cargoData.playerCardGroupSets,groupIdx:unref(cargoOverviewStore).playerGroupingKey,sortingSets:unref(cargoOverviewStore).cargoData.sortingSets,sortIdx:unref(cargoOverviewStore).playerSortingKey,sortAsc:playerSortAsc.value,ignoreFilter:!0,onCardHovered:unref(cargoOverviewStore).cardHovered,onCardClicked:unref(cargoOverviewStore).cardClicked},null,8,[`groupSets`,`groupIdx`,`sortingSets`,`sortIdx`,`sortAsc`,`onCardHovered`,`onCardClicked`])]),unref(cargoOverviewStore).cargoData&&__props.facilityId?(openBlock(),createElementBlock(`div`,_hoisted_27$8,[unref(cargoOverviewStore).cargoData.confirmButtonInfo.itemCount>0?(openBlock(),createBlock(unref(bngButton_default),{key:0,class:`accept-button`,icon:unref(icons).checkmark,onClick:withModifiers(acceptLoad,[`stop`])},{default:withCtx(()=>[createTextVNode(` Continue (`+toDisplayString(unref(cargoOverviewStore).cargoData.confirmButtonInfo.itemCount)+` items) `,1)]),_:1},8,[`icon`])):createCommentVNode(``,!0)])):createCommentVNode(``,!0)]),_:1})],2)):(openBlock(),createBlock(unref(bngCard_default),{key:1,class:`detailedFilterSelector`},{default:withCtx(()=>[createBaseVNode(`div`,_hoisted_28$7,[createVNode(unref(bngCard_default),{class:`info-left`},{default:withCtx(()=>[unref(cargoOverviewStore).cargoData.facility.organization?(openBlock(),createBlock(unref(bngCardHeading_default),{key:0,type:`ribbon`,class:`cardHeadingFlex`},{default:withCtx(()=>[createBaseVNode(`span`,null,[_cache[18]||=createBaseVNode(`span`,null,`Reputation:\xA0`,-1),createBaseVNode(`span`,null,toDisplayString(unref(cargoOverviewStore).cargoData.facility.organization.reputation.label+` (lvl `+unref(cargoOverviewStore).cargoData.facility.organization.reputation.level+`)`),1)]),createVNode(unref(bngButton_default),{icon:unref(icons).signal05a,accent:`secondary`,onClick:_cache[9]||=$event=>gotoOrganizations(unref(cargoOverviewStore).cargoData.facility.organization.id)},{default:withCtx(()=>[..._cache[19]||=[createTextVNode(`Progress`,-1)]]),_:1},8,[`icon`])]),_:1})):createCommentVNode(``,!0),unref(cargoOverviewStore).cargoData.facility.organization?(openBlock(),createElementBlock(`div`,_hoisted_29$7,[createVNode(unref(bngIcon_default),{class:`progress-icon`,type:unref(icons).peopleOutline},null,8,[`type`]),unref(cargoOverviewStore).cargoData.facility.organization?(openBlock(),createElementBlock(`div`,_hoisted_30$7,[createVNode(unref(bngProgressBar_default),{class:`bar`,gradient:``,value:unref(cargoOverviewStore).cargoData.facility.organization.reputation.value,max:unref(cargoOverviewStore).cargoData.facility.organization.reputation.nextThreshold,min:unref(cargoOverviewStore).cargoData.facility.organization.prevThreshold,showValueLabel:!1},null,8,[`value`,`max`,`min`])])):createCommentVNode(``,!0)])):createCommentVNode(``,!0),createVNode(unref(aspectRatio_default),{class:`image`,ratio:`5:3`,"external-image":unref(cargoOverviewStore).cargoData.facility.preview},null,8,[`external-image`]),createVNode(unref(bngCardHeading_default),{type:`ribbon`,class:`cardHeading`},{default:withCtx(()=>[..._cache[20]||=[createTextVNode(` Facility Information `,-1)]]),_:1}),createBaseVNode(`div`,{class:`content text-justify`,innerHTML:unref(content_exports).bbcode.parse(unref(cargoOverviewStore).cargoData.facility.longDescription)},null,8,_hoisted_31$7)]),_:1}),createBaseVNode(`div`,_hoisted_32$7,[(openBlock(!0),createElementBlock(Fragment,null,renderList(unref(cargoOverviewStore).cargoData.facilityPanels,(panel,index)=>(openBlock(),createBlock(unref(bngCard_default),{key:index,class:`panel`},{default:withCtx(()=>[createVNode(unref(bngCardHeading_default),{type:`ribbon`,class:`cardHeadingFlex`},{default:withCtx(()=>[createBaseVNode(`span`,null,[createBaseVNode(`span`,null,toDisplayString(panel.heading)+`:\xA0`,1),panel.skillInfo?(openBlock(),createElementBlock(`span`,_hoisted_33$7,toDisplayString(panel.skillInfo.unlocked?_ctx.$ctx_t(panel.skillInfo.levelLabel):``),1)):createCommentVNode(``,!0)]),panel.skillInfo?(openBlock(),createBlock(unref(bngButton_default),{key:0,icon:unref(icons).signal05a,accent:`secondary`,onClick:$event=>gotoSkillProgress(panel)},{default:withCtx(()=>[..._cache[21]||=[createTextVNode(`Progress`,-1)]]),_:1},8,[`icon`,`onClick`])):createCommentVNode(``,!0)]),_:2},1024),panel.skillInfo?(openBlock(),createElementBlock(`div`,_hoisted_34$7,[createVNode(unref(bngIcon_default),{class:`progress-icon`,type:unref(icons)[panel.skillInfo.icon]},null,8,[`type`]),createBaseVNode(`div`,_hoisted_35$6,[createVNode(unref(bngProgressBar_default),{class:`bar`,gradient:``,value:panel.skillInfo.max==-1?1:panel.skillInfo.value-panel.skillInfo.min,max:panel.skillInfo.max==-1?1:panel.skillInfo.max-panel.skillInfo.min,showValueLabel:!0,valueLabelFormat:panel.skillInfo.max===-1?`Max`:panel.skillInfo.value+` XP`},null,8,[`value`,`max`,`valueLabelFormat`])])])):createCommentVNode(``,!0),createBaseVNode(`div`,_hoisted_36$6,[createBaseVNode(`span`,null,[createVNode(unref(bngIcon_default),{type:unref(icons).info},null,8,[`type`]),createTextVNode(` `+toDisplayString(panel.description),1)]),createBaseVNode(`div`,_hoisted_37$5,[(openBlock(!0),createElementBlock(Fragment,null,renderList(panel.filterValueButtons,filterKey=>(openBlock(),createBlock(FilterCard_default,{key:filterKey,filter:unref(cargoOverviewStore).filterSetsByValue[filterKey]},null,8,[`filter`]))),128))])])]),_:2},1024))),128))])])]),_:1}))])):createCommentVNode(``,!0)],32)]),_:1},512))}},CargoOverviewMain_default=__plugin_vue_export_helper_default(_sfc_main$256,[[`__scopeId`,`data-v-719883ab`]]),_hoisted_1$226={class:`unlock-wrapper`,"bng-ui-scope":`cargoUnlockPopup`},_hoisted_2$184={class:`cardContent`},_hoisted_3$162={class:`acceptButton`},__default__$1={wrapper:{fade:!0,blur:!0,style:popupContainer.default},position:[popupPosition.center,popupPosition.center]},_sfc_main$255=Object.assign(__default__$1,{__name:`UnlockPopup`,props:{reward:Object},emits:[`return`],setup(__props,{emit:__emit}){useUINavScope(`cargoUnlockPopup`);let emit$1=__emit,acceptClickHandler=()=>{emit$1(`return`,!0)};return(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$226,[createVNode(unref(bngCard_default),null,{default:withCtx(()=>[createVNode(unref(bngCardHeading_default),{type:`ribbon`},{default:withCtx(()=>[..._cache[0]||=[createTextVNode(` Level Up! `,-1)]]),_:1}),createBaseVNode(`div`,_hoisted_2$184,[createBaseVNode(`h3`,null,toDisplayString(__props.reward.unlockPopupHeader),1),_cache[2]||=createTextVNode(` Unlocks: `,-1),(openBlock(!0),createElementBlock(Fragment,null,renderList(__props.reward.branchLevels[__props.reward.animationData.level-1].unlocks,item=>(openBlock(),createBlock(UnlockCard_default,{class:`tier-unlocks-item`,data:item},null,8,[`data`]))),256)),createBaseVNode(`div`,_hoisted_3$162,[withDirectives((openBlock(),createBlock(unref(bngButton_default),{accent:unref(ACCENTS).primary,onClick:acceptClickHandler},{default:withCtx(()=>[createVNode(unref(bngBinding_default),{"ui-event":`ok`,deviceMask:`xinput`}),_cache[1]||=createBaseVNode(`span`,null,`Continue`,-1)]),_:1},8,[`accent`])),[[unref(BngOnUiNav_default),acceptClickHandler,`ok`]])])])]),_:1})]))}}),UnlockPopup_default=__plugin_vue_export_helper_default(_sfc_main$255,[[`__scopeId`,`data-v-127ed650`]]),_hoisted_1$225={class:`reward-wrapper`},_hoisted_2$183={class:`card-content`},_hoisted_3$161={class:`scroll-wrapper`},_hoisted_4$135={key:0},_hoisted_5$118={class:`cargo-wrapper`},_hoisted_6$101={class:`header`},_hoisted_7$88={class:`amount-controls`},_hoisted_8$73={class:`amount`},_hoisted_9$66={class:`card-content`},_hoisted_10$57={style:{display:`flex`}},_hoisted_11$51={style:{float:`left`}},_hoisted_12$40={key:0,class:`rewards-breakdown-container padding-bottom`},_hoisted_13$33={class:`grid-wrapper`},_hoisted_14$31={class:`grid-row grid`},_hoisted_15$30={class:`label primary`},_hoisted_16$30={class:`rewards primary`},_hoisted_17$24={class:`grid-wrapper wide`},_hoisted_18$21={class:`grid`},_hoisted_19$18={class:`label secondary`},_hoisted_20$15={class:`rewards secondary`},_hoisted_21$14={class:`grid-row grid`},_hoisted_22$12={class:`rewards primary`},_hoisted_23$11={key:1,class:`rewards-breakdown-container padding-bottom`},_hoisted_24$10={class:`grid-wrapper`},_hoisted_25$9={key:0,class:`grid-row grid`},_hoisted_26$7={class:`rewards primary`},_hoisted_27$7={key:1,class:`grid-row grid`},_hoisted_28$6={class:`rewards primary`},_hoisted_29$6={key:2,class:`grid-row grid`},_hoisted_30$6={class:`rewards primary`},_hoisted_31$6={key:3,class:`grid-row grid`},_hoisted_32$6={class:`rewards primary`},_hoisted_33$6={class:`grid-row grid`},_hoisted_34$6={class:`rewards primary`},_hoisted_35$5={style:{float:`left`}},_hoisted_36$5={key:0,style:{float:`left`}},_hoisted_37$4={key:0,class:`numberReward`},_hoisted_38$4={key:1,class:`numberReward`},_hoisted_39$4={key:2},_hoisted_40$3={key:1,style:{float:`left`,width:`100%`,padding:`0.2em`}},_hoisted_41$3={key:2},__default__={wrapper:{fade:!0,blur:!0,style:popupContainer.transparent},position:[popupPosition.center,popupPosition.center]},_sfc_main$254=Object.assign(__default__,{__name:`CargoDropOff`,props:{facilityId:String,parkingSpotPath:String},setup(__props){let ANIMATION_START_DELAY=400,ANIMATION_DURATION=3e3,ANIMATION_UPDATE_RATE=30,BAR_COLOR_DEFAULT=`#ff6600`,BAR_COLOR_ADDITION=`#ff6600`,BAR_COLOR_SUBTRACTION=`#c00000`,MODES={wait:`wait`,cargoSelection:`cargoSelection`,results:`results`},cargoOverviewStore=useCargoOverviewStore();useUINavScope(`cargoDropOff`);let props=__props,{events:events$3}=useBridge(),mode=ref(MODES.wait),data=ref({}),summary=ref([]),showConfirmDelay=ref(!1),confirmButtonEnabled=ref(!1),confirmButtonTimer=ref(0),confirmButtonTimerId=0,rewardAnimationIndex=ref(-1),animationSkipped=!1,showUnloadingDelay=!0,getLevelFromValue=(value,reward)=>{let branchLevels=reward.branchLevels,levelIndex=-1;for(let i=0;i=levelData.requiredValue&&(levelIndex=i)}let maxLevel=!(branchLevels[levelIndex+1]&&branchLevels[levelIndex+1].requiredValue!=null),displayValue=value-branchLevels[levelIndex].requiredValue;return{min:0,max:maxLevel?displayValue:branchLevels[levelIndex+1].requiredValue-branchLevels[levelIndex].requiredValue,displayValue,levelLabel:reward.type==`reputation`?branchLevels[levelIndex].label+` (Level `+(levelIndex-1)+`)`:branchLevels[levelIndex].levelLabel,level:levelIndex+1,maxLevel}},confirm=()=>{rewardAnimationIndex.value<0?confirmButtonEnabled.value&&confirmDropOff():skipAnimations()},getDeliveryList=()=>summary.value.detailledList.map(delivery=>delivery.label).join(`, `),getNiceTime=()=>confirmButtonTimer.value>0?confirmButtonTimer.value.toFixed(1)+`s remaining...`:`Done!`,exit=()=>{window.bngVue.gotoGameState(`play`)};function updateDisplayValue(reward){if(reward.branchLevels&&reward.branchLevels.length){let displayData=getLevelFromValue(reward.animationData.smoothedValue,reward);reward.animationData.max=displayData.max,reward.animationData.displayValue=displayData.displayValue,reward.animationData.levelLabel=displayData.levelLabel,reward.animationData.level=displayData.level,reward.animationData.maxLevel=displayData.maxLevel;let displayDataBefore=getLevelFromValue(reward.animationData.value-reward.rewardAmount,reward);displayData.level==displayDataBefore.level?(reward.animationData.displayValueBefore=displayDataBefore.displayValue,displayData.displayValue>=displayDataBefore.displayValue?(reward.valueColor=BAR_COLOR_ADDITION,reward.valueBeforeColor=BAR_COLOR_DEFAULT):(reward.valueBeforeColor=BAR_COLOR_SUBTRACTION,reward.valueColor=BAR_COLOR_DEFAULT)):displayData.level>displayDataBefore.level?(reward.animationData.displayValueBefore=0,reward.valueColor=BAR_COLOR_ADDITION,reward.valueBeforeColor=BAR_COLOR_DEFAULT):(reward.animationData.displayValueBefore=displayData.max,reward.valueColor=BAR_COLOR_DEFAULT,reward.valueBeforeColor=BAR_COLOR_SUBTRACTION)}}let startSmoothingValue=(reward,duration)=>{reward.animationData.numStep=(reward.animationData.value-reward.animationData.smoothedValue)/duration*30,clearInterval(reward.animationData.numTimer),reward.animationData.numTimer=setInterval(()=>{reward.animationData.smoothedValue+=reward.animationData.numStep,(reward.animationData.numStep>0?reward.animationData.smoothedValue>=reward.animationData.value:reward.animationData.smoothedValue<=reward.animationData.value)&&(Lua_default.career_modules_delivery_progress.activateSound(``,!1),reward.animationData.smoothedValue=reward.animationData.value,reward.animationData.numStep=0,clearInterval(reward.animationData.numTimer)),reward.highlight=reward.animationData.numStep!=0,updateDisplayValue(reward)},30)};async function openNewLevelPopup(reward){Lua_default.Engine.Audio.playOnce(`AudioGui`,`event:>UI>Career>Progress_LevelUp`),await addPopup(UnlockPopup_default,{reward}).promise,startProgressBarAnimation()}function didPlayerLevelUp(reward){let levelBefore=0,levelAfter=0;return reward.branchLevels&&reward.branchLevels.length&&(levelBefore=getLevelFromValue(reward.animationData.value-reward.rewardAmount,reward).level,levelAfter=getLevelFromValue(reward.animationData.value,reward).level),levelBeforeopenNewLevelPopup(reward),duration):setTimeout(startProgressBarAnimation,duration+400);return}rewardAnimationIndex.value=-1}}let start=()=>{getUINavServiceInstance().activate(),getUINavServiceInstance().clearFilteredEvents(),Lua_default.career_modules_delivery_general.setDeliveryTimePaused(!0),Lua_default.career_modules_delivery_cargoScreen.requestDropOffData(props.facilityId,props.parkingSpotPath)},kill=()=>{Lua_default.career_modules_delivery_general.setDeliveryTimePaused(!1),events$3.off(`SetDeliveryDropOffCargoSelection`),events$3.off(`SetDeliveryDropOffRewardResult`),clearInterval(confirmButtonTimerId),Lua_default.career_modules_delivery_cargoScreen.dropOffPopupClosed(mode.value)},confirmSelection=()=>{let confirmedCargoIds=[];data.value.customAmountPerMaterialType.forEach(info=>{info.items.forEach(item=>{item.amountSelector>0&&confirmedCargoIds.push({id:item.ids[0],amount:item.amountSelector})})});let confirmedDropOffs={confirmedCargoIds,confirmedOfferIds:[]};console.log(confirmedDropOffs),Lua_default.career_modules_delivery_cargoScreen.confirmDropOffData(confirmedDropOffs,props.facilityId,props.parkingSpotPath)},confirmDropOff=()=>{exit()},branchInfo;function rewardMapToRewardList(rewards){let newRewards=[];for(let key in rewards){let rewardInfo={attributeKey:key,rewardAmount:rewards[key],order:branchInfo[key].order,animationData:branchInfo[key].animationData,branchLevels:branchInfo[key].branchLevels,showLevelUpPopup:branchInfo[key].showLevelUpPopup,unlockPopupHeader:branchInfo[key].unlockPopupHeader,type:branchInfo[key].type};branchInfo[key].icon&&(rewardInfo.icon=branchInfo[key].icon),newRewards.push(rewardInfo)}return newRewards.sort((a$1,b)=>a$1.order-b.order),newRewards}let cargoBySummaryId=[],calculateSummary=()=>{let simpleBreakdownRewardsByType={base:[],bonus:[],loaner:[],branch:[]};summary.value={detailledList:[],total:{label:`Total`,rewards:{}}};let totalRewards={};for(let id in cargoBySummaryId){let group=cargoBySummaryId[id],first=group.list[0],totalCount=0;for(let cargo of group.list)totalCount+=1;let sum={label:first.name,rewards:rewardMapToRewardList(first.originalRewards),breakdown:[]};for(let i=0;i0&&summary.value.detailledList.push(sum)}if(data.value.rewardOffers.length)for(let veh of data.value.rewardOffers){let sum={label:veh.offer.name,rewards:rewardMapToRewardList(veh.originalRewards),breakdown:[]};if(simpleBreakdownRewardsByType.base.push(veh.originalRewards),veh.breakdown.length)for(let bd of veh.breakdown)sum.breakdown.push({label:bd.label,rewards:rewardMapToRewardList(bd.rewards)}),bd.simpleBreakdownType&&(simpleBreakdownRewardsByType[bd.simpleBreakdownType]||(simpleBreakdownRewardsByType[bd.simpleBreakdownType]=[]),simpleBreakdownRewardsByType[bd.simpleBreakdownType].push(bd.rewards));summary.value.detailledList.push(sum)}for(let type in simpleBreakdownRewardsByType){let sum={};for(let elem of simpleBreakdownRewardsByType[type])for(let attKey in elem)sum[attKey]||(sum[attKey]=0),sum[attKey]+=elem[attKey];simpleBreakdownRewardsByType[type]=rewardMapToRewardList(sum)}summary.value.simpleBreakdown=simpleBreakdownRewardsByType;for(let row of summary.value.detailledList){for(let elem of row.rewards)totalRewards[elem.attributeKey]||(totalRewards[elem.attributeKey]=0),totalRewards[elem.attributeKey]+=elem.rewardAmount;for(let bd of row.breakdown)for(let elem of bd.rewards)totalRewards[elem.attributeKey]||(totalRewards[elem.attributeKey]=0),totalRewards[elem.attributeKey]+=elem.rewardAmount}summary.value.total.rewards=rewardMapToRewardList(totalRewards);let counter$1=0;for(let reward of summary.value.total.rewards)reward.animationData.id!=`missing`&&(reward.animationOrderIndex=counter$1,reward.animationData.smoothedValue=reward.animationData.value-reward.rewardAmount,reward.animationData.numStep=0,reward.highlight=!1,updateDisplayValue(reward),counter$1++);rewardAnimationIndex.value=-1,animationSkipped=!1};events$3.on(`SetDeliveryDropOffCargoSelection`,dd=>{data.value=dd,mode.value=MODES.cargoSelection,branchInfo=dd.branchInfo,showUnloadingDelay=dd.unloadingDelay>.1,data.value.playerVehicleData.length&&data.value.customAmountPerMaterialType.forEach(info=>{let remainingFreeAmount=info.storage.capacity-info.storage.storedVolume;info.items.sort((a$1,b)=>a$1.slots-b.slots),info.items.forEach(item=>{item.amountSelectorPerSlot=item.type===`fluid`||item.type===`dryBulk`,item.maxCount=item.ids.length,item.amountSelectorPerSlot&&(item.maxCount=item.slots),item.amountSelector=ref(Math.max(0,Math.min(item.maxCount,remainingFreeAmount))),remainingFreeAmount-=item.amountSelector,item.showAmountSelector=!0,item.loadSliderMax=Math.min(item.maxCount,info.storage.capacity-info.storage.storedVolume)}),info.meta={type:`container`,usedCargoSlots:info.storage.storedVolume,totalCargoSlots:info.storage.capacity,fillPercent:info.storage.storedVolume/info.storage.capacity,icon:info.material.icon},info.meta.usedCargoSlots=info.storage.storedVolume,info.items.forEach(item=>{info.meta.usedCargoSlots+=item.amountSelector}),info.meta.fillPercentHighlight=info.meta.usedCargoSlots/info.storage.capacity,info.storage.capacity<=info.storage.storedVolume&&(info.isFull=!0)})});let updateSliderAmounts=(info,changedItem)=>{info.meta.usedCargoSlots=info.storage.storedVolume,info.items.forEach(item=>{info.meta.usedCargoSlots+=item.amountSelector});let tooMuch=info.meta.usedCargoSlots-info.meta.totalCargoSlots;tooMuch>0&&(info.items.reverse(),info.items.forEach(item=>{if(item!==changedItem){let before=item.amountSelector;item.amountSelector=Math.max(0,item.amountSelector-tooMuch);let diff=item.amountSelector-before;tooMuch+=diff}}),info.items.reverse()),info.meta.usedCargoSlots=info.storage.storedVolume,info.items.forEach(item=>{info.meta.usedCargoSlots+=item.amountSelector}),info.meta.fillPercentHighlight=info.meta.usedCargoSlots/info.storage.capacity};return events$3.on(`SetDeliveryDropOffRewardResult`,dd=>{if(console.log(`setDropOffRewardResult`,dd),data.value=dd,branchInfo=dd.branchInfo,mode.value=MODES.results,confirmButtonEnabled.value=!0,showConfirmDelay.value=!1,dd.unloadingDelay>.1){confirmButtonEnabled.value=!1,confirmButtonTimer.value=dd.unloadingDelay,showConfirmDelay.value=!0;let endTime=Date.now()+confirmButtonTimer.value*1e3,countdown=()=>{let timeLeft=(endTime-Date.now())/1e3;timeLeft>0?(confirmButtonTimer.value=timeLeft,confirmButtonTimerId=requestAnimationFrame(countdown)):(confirmButtonTimer.value=0,confirmButtonEnabled.value=!0)};confirmButtonTimerId=requestAnimationFrame(countdown),showUnloadingDelay=!0}else showUnloadingDelay=!1;if(dd.rewardParcels.length)for(let cargo of dd.rewardParcels)cargoBySummaryId[cargo.summaryId]||(cargoBySummaryId[cargo.summaryId]={list:[],display:{}}),cargoBySummaryId[cargo.summaryId].list.push(cargo);calculateSummary(),setTimeout(startProgressBarAnimation,400)}),onMounted(start),onUnmounted(kill),(_ctx,_cache)=>mode.value===MODES.wait?createCommentVNode(``,!0):withDirectives((openBlock(),createBlock(unref(layoutSingle_default),{key:0,class:`cargo-drop-off-wrapper`,"bng-ui-scope":`cargoDropOff`},{default:withCtx(()=>[createBaseVNode(`div`,_hoisted_1$225,[mode.value===MODES.cargoSelection?(openBlock(),createBlock(unref(bngCard_default),{key:0},{buttons:withCtx(()=>[createVNode(unref(bngButton_default),{onClick:confirmSelection},{default:withCtx(()=>[createVNode(unref(bngBinding_default),{"ui-event":`ok`,deviceMask:`xinput`}),_cache[4]||=createBaseVNode(`span`,null,`Confirm Selection`,-1)]),_:1})]),default:withCtx(()=>[createVNode(unref(careerStatus_default),{class:`career-status`}),createVNode(unref(bngCardHeading_default),{type:`ribbon`},{default:withCtx(()=>[..._cache[3]||=[createTextVNode(`Dropping off...`,-1)]]),_:1}),createBaseVNode(`div`,_hoisted_2$183,[createVNode(unref(bngPropVal_default),{class:`limited-capacity-info`,valueLabel:`This facility has limited capacity for cargo.`,iconType:unref(icons).info},null,8,[`iconType`]),createBaseVNode(`div`,_hoisted_3$161,[(openBlock(!0),createElementBlock(Fragment,null,renderList(data.value.customAmountPerMaterialType,info=>(openBlock(),createBlock(CardGroup_default,{class:`fullwidth-group`,label:info.material.name,meta:info.meta},{default:withCtx(()=>[info.isFull?(openBlock(),createElementBlock(`div`,_hoisted_4$135,[createVNode(unref(bngPropVal_default),{valueLabel:`The storage for this material is completely filled. Come back later.`,iconType:unref(icons).abandon},null,8,[`iconType`])])):createCommentVNode(``,!0),(openBlock(!0),createElementBlock(Fragment,null,renderList(info.items,item=>(openBlock(),createElementBlock(`div`,_hoisted_5$118,[createBaseVNode(`div`,_hoisted_6$101,[createVNode(unref(bngPropVal_default),{valueLabel:item.originName,keyLabel:`Origin`,iconType:unref(icons).locationSource},null,8,[`valueLabel`,`iconType`]),createVNode(unref(bngPropVal_default),{valueLabel:item.containerName,keyLabel:`Container`,iconType:unref(icons).cardboardBox},null,8,[`valueLabel`,`iconType`])]),createBaseVNode(`div`,_hoisted_7$88,[createVNode(unref(bngButton_default),{disabled:info.isFull,class:`less`,iconLeft:unref(icons).minus,accent:`text`,onClick:_cache[0]||=$event=>_ctx.less(_ctx.target)},null,8,[`disabled`,`iconLeft`]),createVNode(unref(bngSlider_default),{disabled:info.isFull,class:`slider`,min:0,max:item.loadSliderMax,modelValue:item.amountSelector,"onUpdate:modelValue":$event=>item.amountSelector=$event,step:1,onChange:$event=>updateSliderAmounts(info,item)},null,8,[`disabled`,`max`,`modelValue`,`onUpdate:modelValue`,`onChange`]),createVNode(unref(bngButton_default),{disabled:info.isFull,class:`more`,iconLeft:unref(icons).plus,accent:`text`,onClick:_cache[1]||=$event=>_ctx.more(_ctx.target)},null,8,[`disabled`,`iconLeft`]),createBaseVNode(`div`,_hoisted_8$73,toDisplayString(item.amountSelector)+` / `+toDisplayString(item.slots),1)])]))),256))]),_:2},1032,[`label`,`meta`]))),256))])])]),_:1})):createCommentVNode(``,!0),mode.value===MODES.results?(openBlock(),createBlock(unref(bngCard_default),{key:1},{buttons:withCtx(()=>[withDirectives((openBlock(),createBlock(unref(bngButton_default),{disabled:rewardAnimationIndex.value<0&&!confirmButtonEnabled.value,onClick:confirm},{default:withCtx(()=>[createVNode(unref(bngBinding_default),{deviceMask:`xinput`}),createBaseVNode(`span`,null,toDisplayString(rewardAnimationIndex.value<0?`Continue`:`Skip`),1)]),_:1},8,[`disabled`])),[[unref(BngFocusIf_default),rewardAnimationIndex.value==0]])]),default:withCtx(()=>[createVNode(unref(bngCardHeading_default),{type:`ribbon`},{default:withCtx(()=>[..._cache[5]||=[createTextVNode(`Delivery Complete!`,-1)]]),_:1}),createBaseVNode(`div`,_hoisted_9$66,[createBaseVNode(`div`,_hoisted_10$57,[createBaseVNode(`h3`,_hoisted_11$51,`Delivered: `+toDisplayString(getDeliveryList()),1),summary.value.detailledList.length>1?(openBlock(),createBlock(unref(bngSwitch_default),{key:0,style:{float:`right`},modelValue:unref(cargoOverviewStore).detailedDropOff,"onUpdate:modelValue":_cache[2]||=$event=>unref(cargoOverviewStore).detailedDropOff=$event},{default:withCtx(()=>[..._cache[6]||=[createTextVNode(`Detailed`,-1)]]),_:1},8,[`modelValue`])):createCommentVNode(``,!0)]),summary.value.detailledList.length<=1||unref(cargoOverviewStore).detailedDropOff?(openBlock(),createElementBlock(`div`,_hoisted_12$40,[createBaseVNode(`div`,_hoisted_13$33,[(openBlock(!0),createElementBlock(Fragment,null,renderList(summary.value.detailledList,result=>(openBlock(),createElementBlock(`div`,_hoisted_14$31,[createBaseVNode(`div`,_hoisted_15$30,toDisplayString(result.label),1),createBaseVNode(`div`,_hoisted_16$30,[createVNode(RewardsPills_default,{rewards:result.rewards},null,8,[`rewards`])]),createBaseVNode(`div`,_hoisted_17$24,[(openBlock(!0),createElementBlock(Fragment,null,renderList(result.breakdown,breakdown=>(openBlock(),createElementBlock(`div`,_hoisted_18$21,[createBaseVNode(`div`,_hoisted_19$18,toDisplayString(breakdown.label),1),createBaseVNode(`div`,_hoisted_20$15,[createVNode(RewardsPills_default,{rewards:breakdown.rewards},null,8,[`rewards`])])]))),256))])]))),256)),createVNode(unref(bngDivider_default)),createBaseVNode(`div`,_hoisted_21$14,[_cache[7]||=createBaseVNode(`div`,{class:`label primary`},`Summary`,-1),createBaseVNode(`div`,_hoisted_22$12,[createVNode(RewardsPills_default,{rewards:summary.value.total.rewards},null,8,[`rewards`])])])])])):(openBlock(),createElementBlock(`div`,_hoisted_23$11,[createBaseVNode(`div`,_hoisted_24$10,[summary.value.simpleBreakdown.base.length?(openBlock(),createElementBlock(`div`,_hoisted_25$9,[_cache[8]||=createBaseVNode(`div`,{class:`label primary`},`Base Rewards`,-1),createBaseVNode(`div`,_hoisted_26$7,[createVNode(RewardsPills_default,{rewards:summary.value.simpleBreakdown.base},null,8,[`rewards`])])])):createCommentVNode(``,!0),summary.value.simpleBreakdown.bonus.length?(openBlock(),createElementBlock(`div`,_hoisted_27$7,[_cache[9]||=createBaseVNode(`div`,{class:`label primary`},`Bonuses`,-1),createBaseVNode(`div`,_hoisted_28$6,[createVNode(RewardsPills_default,{rewards:summary.value.simpleBreakdown.bonus},null,8,[`rewards`])])])):createCommentVNode(``,!0),summary.value.simpleBreakdown.loaner.length?(openBlock(),createElementBlock(`div`,_hoisted_29$6,[_cache[10]||=createBaseVNode(`div`,{class:`label primary`},`Loaner Cuts`,-1),createBaseVNode(`div`,_hoisted_30$6,[createVNode(RewardsPills_default,{rewards:summary.value.simpleBreakdown.loaner},null,8,[`rewards`])])])):createCommentVNode(``,!0),summary.value.simpleBreakdown.branch.length?(openBlock(),createElementBlock(`div`,_hoisted_31$6,[_cache[11]||=createBaseVNode(`div`,{class:`label primary`},`Logistics Level Multiplier`,-1),createBaseVNode(`div`,_hoisted_32$6,[createVNode(RewardsPills_default,{rewards:summary.value.simpleBreakdown.branch},null,8,[`rewards`])])])):createCommentVNode(``,!0),createVNode(unref(bngDivider_default)),createBaseVNode(`div`,_hoisted_33$6,[_cache[12]||=createBaseVNode(`div`,{class:`label primary`},`Summary`,-1),createBaseVNode(`div`,_hoisted_34$6,[createVNode(RewardsPills_default,{rewards:summary.value.total.rewards},null,8,[`rewards`])])])])])),(openBlock(!0),createElementBlock(Fragment,null,renderList(summary.value.total.rewards,reward=>(openBlock(),createElementBlock(`div`,null,[reward.animationData.id==`missing`?createCommentVNode(``,!0):(openBlock(),createElementBlock(`div`,{key:0,class:normalizeClass(reward.animationData.numStep==0?``:`animate-progress-background`),style:{display:`flex`,"padding-bottom":`0.5em`,"padding-left":`0.2em`,"padding-right":`0.2em`}},[createBaseVNode(`div`,_hoisted_35$5,[reward.icon?(openBlock(),createBlock(unref(bngIcon_default),{key:0,style:{"padding-top":`0.5em`,"padding-right":`0.3em`},type:unref(icons)[reward.icon]},null,8,[`type`])):createCommentVNode(``,!0)]),reward.animationData.type==`number`?(openBlock(),createElementBlock(`div`,_hoisted_36$5,[reward.attributeKey==`money`?(openBlock(),createElementBlock(`div`,_hoisted_37$4,[createVNode(unref(bngUnit_default),{money:reward.animationData.smoothedValue,"no-icon":``},null,8,[`money`])])):reward.attributeKey==`beamXP`?(openBlock(),createElementBlock(`div`,_hoisted_38$4,[createVNode(unref(bngUnit_default),{beamXP:reward.animationData.smoothedValue,"no-icon":``},null,8,[`beamXP`])])):(openBlock(),createElementBlock(`div`,_hoisted_39$4,toDisplayString(reward.animationData.smoothedValue.toFixed(2)),1))])):(openBlock(),createElementBlock(`div`,_hoisted_40$3,[createVNode(unref(bngProgressBar_default),{headerLeft:_ctx.$t(reward.animationData.name),headerRight:reward.animationData.levelLabel,value:~~reward.animationData.displayValue,"old-value":~~reward.animationData.displayValueBefore,max:reward.animationData.max,showValueLabel:!0,valueColor:reward.valueColor,oldValueColor:reward.valueBeforeColor,valueLabelFormat:reward.animationData.maxLevel?~~reward.animationData.displayValue+`\xA0XP`:`#value#\xA0XP`,"animate-difference":!0},null,8,[`headerLeft`,`headerRight`,`value`,`old-value`,`max`,`valueColor`,`oldValueColor`,`valueLabelFormat`])]))],2))]))),256)),unref(showUnloadingDelay)?(openBlock(),createElementBlock(`div`,_hoisted_41$3,[createVNode(unref(bngDivider_default)),_cache[13]||=createTextVNode(` Unloading Delay `,-1),createVNode(unref(bngProgressBar_default),{class:`timer`,value:data.value.unloadingDelay-confirmButtonTimer.value,max:data.value.unloadingDelay,min:0,valueLabelFormat:getNiceTime()},null,8,[`value`,`max`,`valueLabelFormat`])])):createCommentVNode(``,!0)])]),_:1})):createCommentVNode(``,!0)])]),_:1})),[[unref(BngBlur_default)],[unref(BngOnUiNav_default),confirm,`back,menu`]])}}),CargoDropOff_default=__plugin_vue_export_helper_default(_sfc_main$254,[[`__scopeId`,`data-v-698d9552`]]);const useComputerStore=defineStore(`computer`,()=>{let computerData=ref({}),activeVehicleIndex=ref(0),activeInventoryId=computed(()=>computerData.value.vehicles&&computerData.value.vehicles[activeVehicleIndex.value]?computerData.value.vehicles[activeVehicleIndex.value].inventoryId:`0`),generalComputerFunctions=computed(()=>{if(!computerData.value.computerFunctions)return[];let result=[];return result=Object.values(computerData.value.computerFunctions.general),result.sort((a$1,b)=>a$1.order!=null&&b.order!=null?a$1.order{if(!computerData.value.computerFunctions)return{};let result={};for(let[inventoryId,computerFunctions]of Object.entries(computerData.value.computerFunctions.vehicleSpecific)){let sortedFunctions=Object.values(computerFunctions);sortedFunctions.sort((a$1,b)=>a$1.order!=null&&b.order!=null?a$1.order{computerData.value=data,(computerData.value.vehicles&&computerData.value.vehicles.length<=activeVehicleIndex.value||computerData.value.resetActiveVehicleIndex)&&(activeVehicleIndex.value=0)};return{activeVehicleIndex,activeInventoryId,computerData,generalComputerFunctions,vehicleSpecificComputerFunctions,requestComputerData:()=>{Lua_default.career_modules_computer.getComputerUIData().then(setComputerData)},computerButtonCallback:async(computerFunctionId,inventoryId)=>{await Lua_default.career_modules_computer.computerButtonCallback(computerFunctionId,inventoryId?Number(inventoryId):void 0)},switchActiveVehicle:offset$2=>{activeVehicleIndex.value=(activeVehicleIndex.value+offset$2+computerData.value.vehicles.length)%computerData.value.vehicles.length},onMenuClosed:()=>{Lua_default.career_modules_computer.onMenuClosed()}}});var _hoisted_1$224={class:`task-header`},_hoisted_2$182={class:`description`},_sfc_main$253={__name:`TaskHeader`,props:{title:[String,Object],description:[String,Object]},setup(__props){let props=__props,slots=useSlots(),titleParsed=computed(()=>parse$1($translate.contextTranslate(props.title,!0))),descriptionParsed=computed(()=>parse$1($translate.contextTranslate(props.description)));return(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$224,[createBaseVNode(`div`,null,[unref(slots).title?renderSlot(_ctx.$slots,`title`,{key:0},void 0,!0):__props.title?(openBlock(),createBlock(unref(dynamicComponent_default),{key:1,template:titleParsed.value},null,8,[`template`])):createCommentVNode(``,!0)]),createBaseVNode(`div`,_hoisted_2$182,[unref(slots).description?renderSlot(_ctx.$slots,`description`,{key:0},void 0,!0):__props.description?(openBlock(),createBlock(unref(dynamicComponent_default),{key:1,template:descriptionParsed.value},null,8,[`template`])):createCommentVNode(``,!0)])]))}},TaskHeader_default=__plugin_vue_export_helper_default(_sfc_main$253,[[`__scopeId`,`data-v-ae9fa7fe`]]),_hoisted_1$223={class:`task-message`},_hoisted_2$181={class:`label`},_hoisted_3$160={class:`description`},_sfc_main$252={__name:`TaskMessage`,props:{label:String,description:String},setup(__props){let props=__props,slots=useSlots(),labelParsed=computed(()=>parse$1($translate.contextTranslate(props.label,!0))),descriptionParsed=computed(()=>parse$1($translate.contextTranslate(props.description)));return(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$223,[createBaseVNode(`div`,_hoisted_2$181,[unref(slots).label?renderSlot(_ctx.$slots,`label`,{key:0},void 0,!0):__props.label?(openBlock(),createBlock(unref(dynamicComponent_default),{key:1,template:labelParsed.value},null,8,[`template`])):createCommentVNode(``,!0)]),createBaseVNode(`div`,_hoisted_3$160,[unref(slots).description?renderSlot(_ctx.$slots,`description`,{key:0},void 0,!0):__props.description?(openBlock(),createBlock(unref(dynamicComponent_default),{key:1,template:descriptionParsed.value},null,8,[`template`])):createCommentVNode(``,!0)])]))}},TaskMessage_default=__plugin_vue_export_helper_default(_sfc_main$252,[[`__scopeId`,`data-v-657447b0`]]),_hoisted_1$222=[`data-id`],_sfc_main$251={__name:`TaskList`,props:{header:Object,tasks:Array,settings:{type:Object,default:{animate:!1,animateOnMount:!1,animateOnMountIntervalDelay:.2,animateOnEmpty:!1,animateOnEmptyIntervalDelay:.2,animateNextTask:!1,taskCompleteCallback:{type:Function,required:!1}}}},setup(__props){let props=__props,animationSettings=inject(`animationSettings`,props.settings),previousTasks=ref(null),internalTasks=ref(null),tasksScroller=ref(null),canAnimate=computed(()=>!(!animationSettings.animate||previousTasks.value===null&&!animationSettings.animateOnMount)),nextTask=computed(()=>internalTasks.value.find(x=>x.type===`goal`&&!x.complete&&x.attention)),onBeforeHeaderLeave=el=>{el.style.animationDelay=`0s`},onBeforeLeave=(el,done)=>{el.style.animationDelay=`0s`},onBeforeEnterTask=el=>{let dataId=el.getAttribute(`data-id`),offset$2=props.header?1:0,delay=previousTasks.value===null||previousTasks.value.length===0?animationSettings.animateOnMountIntervalDelay*(Number(dataId)+offset$2):0;el.style.animationDelay=delay+`s`,requestAnimationFrame(()=>{tasksScroller.value&&(tasksScroller.value.scrollTop=tasksScroller.value.scrollHeight)})};onBeforeMount(()=>{(!internalTasks.value||internalTasks.value.length===0)&&(internalTasks.value=unwrapProxy(props.tasks))}),watch(()=>props.tasks,async(newValue,oldValue)=>{internalTasks.value!==null&&(previousTasks.value=internalTasks.value&&internalTasks.value.length>0?unwrapProxy([...internalTasks.value]):[]),internalTasks.value=unwrapProxy(props.tasks)},{deep:!0});function unwrapProxy(reactiveList){return reactiveList.map(x=>Object.assign({},x))}return(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,{class:normalizeClass([`tasks-container`,{animate:unref(animationSettings).animate}])},[createVNode(Transition,{"enter-active-class":`show`,"leave-active-class":`remove`,css:unref(animationSettings).animate,onBeforeLeave:onBeforeHeaderLeave},{default:withCtx(()=>[__props.header?(openBlock(),createElementBlock(`div`,{key:0,class:normalizeClass([`header-wrapper`,{"show-animate":canAnimate.value}])},[createVNode(TaskHeader_default,mergeProps(__props.header,{class:`header`}),null,16)],2)):createCommentVNode(``,!0)]),_:1},8,[`css`]),createBaseVNode(`div`,{class:`tasks-content`,ref_key:`tasksScroller`,ref:tasksScroller},[createVNode(TransitionGroup,{"enter-active-class":`show`,"leave-active-class":`remove`,css:unref(animationSettings).animate,onBeforeLeave,onBeforeEnter:onBeforeEnterTask},{default:withCtx(()=>[(openBlock(!0),createElementBlock(Fragment,null,renderList(internalTasks.value,(task,index)=>(openBlock(),createElementBlock(`div`,{key:task.id,class:normalizeClass([`task-wrapper`,{"show-animate":canAnimate.value,"remove-animate":canAnimate.value}]),"data-id":index},[task.type===`message`?(openBlock(),createBlock(TaskMessage_default,mergeProps({key:0,ref_for:!0},task,{class:`task-card`}),null,16)):task.type===`goal`?(openBlock(),createBlock(TaskGoal_default,mergeProps({key:1,ref_for:!0},task,{class:[`task-card`,{glow:unref(animationSettings).animateNextTask&&nextTask.value&&nextTask.value.id===task.id}]}),null,16,[`class`])):createCommentVNode(``,!0)],10,_hoisted_1$222))),128))]),_:1},8,[`css`])],512)],2))}},TaskList_default=__plugin_vue_export_helper_default(_sfc_main$251,[[`__scopeId`,`data-v-5118e548`]]);const useTasksStore=defineStore(`tasks`,()=>{let header=ref(null),tasks=ref([]),{$game}=useLibStore();$game.events.on(`SetTasklistHeader`,setTasklistHeader),$game.events.on(`SetTasklistTask`,setTasklistTask),$game.events.on(`UpdateTasklistItem`,updateTasklistItem),$game.events.on(`SortTasklistItems`,sortTasklistItems),$game.events.on(`CompleteTasklistGoal`,id=>updateTasklistItem(id,{complete:!0,success:!0})),$game.events.on(`FailTasklistGoal`,id=>updateTasklistItem(id,{complete:!0,success:!1})),$game.events.on(`DiscardTasklistItem`,discardTasklistItem),$game.events.on(`HighlightTasklistItem`,highlightTasklistItem),$game.events.on(`HideCareerTasklist`,hideCareerTasklist),$game.events.on(`ClearTasklist`,clearTasklist);function setTasklistHeader(data){data==null||data==``?header.value=null:header.value={title:data.label,description:data.subtext}}function setTasklistTask(data){let id=data.id===null||data.id===void 0?`default`:data.id,index=tasks.value.findIndex(x=>x.id===id);if(index===-1&&data.clear)return;if(data.clear){tasks.value.splice(index,1);return}let isComplete=data.done!==void 0&&data.done||data.fail!==void 0&&data.fail,isSuccess=data.done!==void 0&&data.done||data.fail!==void 0&&!data.fail,description=data.subtext===0?``:data.subtext;index===-1?tasks.value.push({id:data.id,label:data.label,description,type:data.type,attention:data.attention,complete:isComplete,success:isSuccess}):(tasks.value[index].attention=data.attention,tasks.value[index].complete=isComplete,tasks.value[index].success=isSuccess,data.subtext!==void 0&&(tasks.value[index].description=description),data.label!==void 0&&(tasks.value[index].label=data.label),data.type!==void 0&&(tasks.value[index].type=data.type))}function updateTasklistItem(id,data){let index=tasks.value.findIndex(task=>task.id===id);index!==-1&&Object.keys(data).forEach(key=>{tasks.value[index][key]!==void 0&&(tasks.value[index][key]=data[key])})}function sortTasklistItems(order){let inOrderTasks=[],notInOrderTasks=[];tasks.value.forEach(task=>{order.includes(task.id)?inOrderTasks.push(task):notInOrderTasks.push(task)}),inOrderTasks.sort((a$1,b)=>order.indexOf(a$1.id)-order.indexOf(b.id)),tasks.value=[...inOrderTasks,...notInOrderTasks]}function discardTasklistItem(id,delay){delay!==void 0&&delay>0?setTimeout(()=>{setTasklistTask({id,clear:!0})},delay*1e3):setTasklistTask({id,clear:!0})}function highlightTasklistItem(id,duration){setTasklistTask({id,attention:!0}),duration!==void 0&&duration>0&&setTimeout(()=>{setTasklistTask({id,attention:!1})},duration*1e3)}function hideCareerTasklist(){}function clearTasklist(){header.value=null,tasks.value=[]}return{header,tasks,hasItems:computed(()=>tasks.value.length>0||header.value!==null)}});var _hoisted_1$221={class:`heading-container`},_hoisted_2$180={key:0,class:`status-add`},_hoisted_3$159={class:`content-container`},_hoisted_4$134={class:`main-content`},_hoisted_5$117={class:`main-content-slotted`},_hoisted_6$100={class:`side-content-slotted`},_sfc_main$250={__name:`ComputerWrapper`,props:{title:{type:String,default:`My Computer`},path:Array,wallpaperFull:Boolean,wallpaperHalf:Boolean,back:Boolean,close:Boolean},emits:[`back`,`close`],setup(__props,{expose:__expose,emit:__emit}){useUINavScope(`computer`);let{$game}=useLibStore(),computerStore=useComputerStore(),props=__props,breadcrumbItems=computed(()=>[{label:`Career`,closeAllMenus:!0},{label:computerStore.computerData.facilityName},...(props.path||[]).map(path=>({label:path}))]),elStatus=ref(),store$1=useTasksStore();provide(`animationSettings`,{animate:!0,animateOnMount:!1,animateOnMountIntervalDelay:.2,animateOnEmptyIntervalDelay:.1,animateOnEmpty:!0,animateNextTask:!0,successCallback:playAudio});function playAudio(){$game.lua.Engine.Audio.playOnce(`AudioGui`,`event:>UI>Career>Checkbox`)}__expose({statusUpdate:()=>elStatus.value.updateDisplay()});function breadcrumbClick(item){item.closeAllMenus&&$game.lua.career_career.closeAllMenus()}let emit$1=__emit;return(_ctx,_cache)=>withDirectives((openBlock(),createBlock(unref(layoutSingle_default),{"bng-ui-scope":`computer`,class:`computer-wrapper-layout`},{default:withCtx(()=>[createBaseVNode(`div`,_hoisted_1$221,[createVNode(unref(bngScreenHeadingV2_default),{type:`2`},{preheadings:withCtx(()=>[createVNode(bngBreadcrumbs_default,{class:`breadcrumbs`,simple:``,"disable-last-item":``,"show-back-button":``,navigable:!1,onClick:breadcrumbClick,onBack:_cache[0]||=$event=>emit$1(`back`),items:breadcrumbItems.value},null,8,[`items`])]),default:withCtx(()=>[renderSlot(_ctx.$slots,`title`,{},()=>[createTextVNode(toDisplayString(__props.title),1)],!0)]),_:3}),withDirectives((openBlock(),createBlock(unref(bngCard_default),{class:`status-container`},{default:withCtx(()=>[createVNode(unref(careerStatus_default),{ref_key:`elStatus`,ref:elStatus},null,512),_ctx.$slots.status?(openBlock(),createElementBlock(`div`,_hoisted_2$180,[renderSlot(_ctx.$slots,`status`,{},void 0,!0)])):createCommentVNode(``,!0)]),_:3})),[[unref(BngBlur_default),!0]])]),createBaseVNode(`div`,_hoisted_3$159,[createBaseVNode(`div`,_hoisted_4$134,[createBaseVNode(`div`,_hoisted_5$117,[renderSlot(_ctx.$slots,`default`,{},void 0,!0)]),createBaseVNode(`div`,_hoisted_6$100,[createVNode(unref(TaskList_default),{class:`task-list`,header:unref(store$1).header,tasks:unref(store$1).tasks},null,8,[`header`,`tasks`]),renderSlot(_ctx.$slots,`side`,{},void 0,!0)])])])]),_:3})),[[unref(BngOnUiNav_default),()=>emit$1(`back`),`back`]])}},ComputerWrapper_default=__plugin_vue_export_helper_default(_sfc_main$250,[[`__scopeId`,`data-v-b7460ee1`]]),_hoisted_1$220={class:`indicators-overlay`},_hoisted_2$179={class:`performance-index`},_hoisted_3$158={key:0,class:`lock-reason`},_hoisted_4$133={key:1,class:`lock-time`},_hoisted_5$116={key:1,class:`valueReduced`},_hoisted_6$99={key:0,class:`content`},_hoisted_7$87={class:`header`},_hoisted_8$72={class:`title-section`},_hoisted_9$65={class:`name`},_hoisted_10$56={class:`details`},_hoisted_11$50={class:`location-section`},_hoisted_12$39={class:`location-value`},_hoisted_13$32={key:0,class:`value-section`},_hoisted_14$30={key:0,class:`value-label reduced`},_hoisted_15$29={key:1,class:`value-label`},_hoisted_16$29={key:2,class:`total-value`},_hoisted_17$23={class:`insurance-section`},_hoisted_18$20={class:`insurance-value`},_hoisted_19$17={key:0,class:`warn`},_sfc_main$249=Object.assign({width:100,margin:.25},{__name:`VehicleTileRow`,props:{data:Object,isTutorial:Boolean,selected:Boolean,enableHover:{type:Boolean,default:!0},small:Boolean},setup(__props){let{units}=useBridge(),props=__props,partConditionAvg=computed(()=>{if(!props.data)return 1;if(props.data.partConditions){let conds=Object.values(props.data.partConditions);return conds.reduce((i,c)=>i+c.integrityValue,0)/conds.length}return 1}),colour=computed(()=>props.data?.config?.paints?.[0]?.baseColor??`#ccc`),thumbUrl=computed(()=>props.data.thumbnail?`${props.data.thumbnail}?${props.data.dirtyDate}`:null),location$1=computed(()=>{let res;return res=locked.value&&!locked.value.location?locked.value.reason:props.data.inGarage?`In garage`:props.data.distance?`${units.buildString(`length`,props.data.distance,0)} away`:`Storage`,res}),locked=computed(()=>{let res;if(props.data._message)res={reason:props.data._message};else if(props.data.missingFile)res={reason:`Missing File!`};else if(props.data.timeToAccess){let eta=`${~~(props.data.timeToAccess/60)}:${String(~~props.data.timeToAccess%60).padStart(2,`0`)}`;res=props.data.delayReason===`bought`?{reason:`Out for delivery`,eta}:props.data.delayReason===`repair`?{reason:`Being repaired`,eta}:{reason:`Available in`,eta}}else props.data.needsRepair&&(res={reason:`Needs repair`,location:!0});return res});return(_ctx,_cache)=>__props.data?withDirectives((openBlock(),createElementBlock(`div`,{key:0,class:normalizeClass({"vehicle-tile-row":!0,selected:__props.selected,"hover-enabled":__props.enableHover}),role:`button`},[createBaseVNode(`div`,{class:normalizeClass({preview:!0,locked:locked.value,small:__props.small})},[thumbUrl.value?(openBlock(),createBlock(unref(aspectRatio_default),{key:0,ratio:`16:9`,"external-image":thumbUrl.value,class:`preview-image`},{default:withCtx(()=>[createBaseVNode(`div`,_hoisted_1$220,[__props.data.favorite?withDirectives((openBlock(),createBlock(unref(bngIcon_default),{key:0,type:unref(icons).star,color:`#fd0`},null,8,[`type`])),[[unref(BngTooltip_default),`Favourite`]]):createCommentVNode(``,!0),__props.data.delayReason===`repair`?(openBlock(),createBlock(unref(bngIcon_default),{key:1,type:unref(icons).wrench,color:`#fff`},null,8,[`type`])):(openBlock(),createBlock(unref(bngCondition_default),{key:2,integrity:partConditionAvg.value,"integrity-warning":__props.data.needsRepair,color:colour.value,"show-tooltip":``},null,8,[`integrity`,`integrity-warning`,`color`])),createBaseVNode(`div`,_hoisted_2$179,toDisplayString(__props.data.certificationData&&__props.data.certificationData.vehicleClass?__props.data.certificationData.vehicleClass.performanceIndex.toFixed(0):`N/A`),1)]),locked.value?(openBlock(),createElementBlock(`span`,_hoisted_3$158,toDisplayString(locked.value.reason),1)):createCommentVNode(``,!0),locked.value&&locked.value.eta?(openBlock(),createElementBlock(`span`,_hoisted_4$133,toDisplayString(locked.value.eta),1)):createCommentVNode(``,!0)]),_:1},8,[`external-image`])):createCommentVNode(``,!0),!(__props.data.returnLoanerPermission&&__props.data.returnLoanerPermission.allow)&&__props.data.partConditionAvg<1?(openBlock(),createElementBlock(`span`,_hoisted_5$116,`Value reduced!`)):createCommentVNode(``,!0),__props.data.isInsured?createCommentVNode(``,!0):(openBlock(),createBlock(insurancePerkIcon_default,{key:2,class:`not-insured-overlay`,perkIconData:{iconOnly:__props.data.isInsured,color:`red`,smallText:`Not insured`}},null,8,[`perkIconData`]))],2),__props.data._message?createCommentVNode(``,!0):(openBlock(),createElementBlock(`div`,_hoisted_6$99,[createBaseVNode(`div`,_hoisted_7$87,[createBaseVNode(`div`,_hoisted_8$72,[createBaseVNode(`div`,_hoisted_9$65,toDisplayString(__props.data.niceName),1)])]),createBaseVNode(`div`,_hoisted_10$56,[createBaseVNode(`div`,_hoisted_11$50,[_cache[0]||=createBaseVNode(`span`,{class:`location-label`},`Location:`,-1),createBaseVNode(`span`,_hoisted_12$39,toDisplayString(location$1.value),1)]),__props.data.returnLoanerPermission?.allow?createCommentVNode(``,!0):(openBlock(),createElementBlock(`div`,_hoisted_13$32,[partConditionAvg.value<1?(openBlock(),createElementBlock(`span`,_hoisted_14$30,`Current Value:`)):(openBlock(),createElementBlock(`span`,_hoisted_15$29,`Value:`)),createVNode(unref(bngUnit_default),{money:__props.data.value},null,8,[`money`]),partConditionAvg.value<1?(openBlock(),createElementBlock(`div`,_hoisted_16$29,[_cache[1]||=createTextVNode(` Total Value: `,-1),createVNode(unref(bngUnit_default),{money:__props.data.valueRepaired},null,8,[`money`])])):createCommentVNode(``,!0)])),createBaseVNode(`div`,_hoisted_17$23,[_cache[2]||=createBaseVNode(`span`,{class:`insurance-label`},`Insurance:`,-1),createBaseVNode(`span`,_hoisted_18$20,toDisplayString(__props.data.insuranceInfo?__props.data.insuranceInfo.name:`n/a`),1),__props.data.isInsured?createCommentVNode(``,!0):(openBlock(),createElementBlock(`div`,_hoisted_19$17,`Not Insured!`))])])]))],2)),[[unref(BngDisabled_default),__props.data.disabled]]):createCommentVNode(``,!0)}}),VehicleTileRow_default=__plugin_vue_export_helper_default(_sfc_main$249,[[`__scopeId`,`data-v-777a3003`]]),_hoisted_1$219={key:1,class:`computer-actions`},_hoisted_2$178={key:0,class:`vehicle-select-container`},_hoisted_3$157={class:`vehicle-select`},_hoisted_4$132={key:0,class:`actions-list`},_hoisted_5$115=[`onClick`,`onMouseover`,`onFocus`],_hoisted_6$98={class:`label`},_hoisted_7$86={key:1,class:`no-vehicle-container`},_hoisted_8$71={key:2,class:`action-header`},_hoisted_9$64={key:3,class:`general-functions-container`},_hoisted_10$55={class:`actions-list`},_hoisted_11$49=[`onClick`,`onMouseover`,`onFocus`],_hoisted_12$38={class:`label`},_hoisted_13$31={key:0,class:`disable-reason`},_hoisted_14$29=[`innerHTML`],_hoisted_15$28={key:1,class:`disable-reason`},_hoisted_16$28=[`innerHTML`],_sfc_main$248={__name:`ComputerMain`,setup(__props){let computerStore=useComputerStore(),currentVehicleData=ref(null);watch(()=>computerStore.activeInventoryId,newId=>{Number(newId)&&Lua_default.career_modules_inventory.getVehicleUiData(newId).then(data=>{currentVehicleData.value=data})});let showVehicleSelectorButtons=computed(()=>computerStore.computerData.vehicles&&computerStore.computerData.vehicles.length>1),hasVehicles=computed(()=>computerStore.computerData.vehicles&&computerStore.computerData.vehicles.length);computed(()=>hasVehicles.value?computerStore.computerData.vehicles[computerStore.activeVehicleIndex].vehicleName:``),computed(()=>hasVehicles.value?computerStore.computerData.vehicles[computerStore.activeVehicleIndex].thumbnail:``),computed(()=>hasVehicles.value?computerStore.computerData.vehicles[computerStore.activeVehicleIndex].needsRepair?`Assess Performance (Repair Required)`:`Assess Performance`:``);let slowFunctions=[`vehicleShop`,`partInventory`],computerLoading=ref(!1),computerButtonCallback=(computerFunction,inventoryId=void 0)=>{computerFunction.disabled||(slowFunctions.includes(computerFunction.id)?(computerLoading.value=!0,setTimeout(()=>computerStore.computerButtonCallback(computerFunction.id,inventoryId),100)):computerStore.computerButtonCallback(computerFunction.id,inventoryId))},switchActiveVehicle=computerStore.switchActiveVehicle,iconById={painting:icons.sprayCan,partShop:icons.doorFrontCoins,repair:icons.wrench,tuning:icons.cogs,insurances:icons.shieldHandCheckmark,playerAbstract:icons.personSolid,vehicleInventory:icons.keys1,partInventory:icons.engine,vehicleShop:icons.carCoins,performanceIndex:icons.raceFlag},infoById=computed(()=>[...computerStore.generalComputerFunctions,...(computerStore.activeInventoryId?computerStore.vehicleSpecificComputerFunctions[computerStore.activeInventoryId]:void 0)||[]].reduce((res,func)=>(res[func.id]={icon:iconById[func.id]||icons.bug,label:func.label,reason:void 0},func.reason&&(res[func.id].label+=` *`,res[func.id].reason=func.reason.label),res),{})),isTutorialActive=ref(!1),disableReason=ref([null,null]),setReason=(idx,reason=null)=>{disableReason.value[idx]=reason,disableReason.value[(idx+1)%2]=null},close=()=>{computerLoading.value||Lua_default.career_career.closeAllMenus()};return onMounted(async()=>{getUINavServiceInstance().setFilteredEvents(UI_EVENT_GROUPS.focusMoveScalar),computerStore.requestComputerData(),Number(computerStore.activeInventoryId)&&Lua_default.career_modules_inventory.getVehicleUiData(computerStore.activeInventoryId).then(data=>{currentVehicleData.value=data}),Lua_default.career_modules_linearTutorial.isLinearTutorialActive().then(data=>{isTutorialActive.value=data})}),onUnmounted(()=>{computerStore.onMenuClosed(),getUINavServiceInstance().clearFilteredEvents(),computerStore.$dispose()}),(_ctx,_cache)=>(openBlock(),createBlock(ComputerWrapper_default,{title:unref(computerStore).computerData.facilityName+` - Home screen`,close:``,onBack:close},{default:withCtx(()=>[withDirectives((openBlock(),createBlock(unref(bngCard_default),{class:`card-content`},{default:withCtx(()=>[computerLoading.value?(openBlock(),createBlock(unref(bngCardHeading_default),{key:0},{default:withCtx(()=>[..._cache[6]||=[createTextVNode(` Loading... `,-1)]]),_:1})):createCommentVNode(``,!0),computerLoading.value?createCommentVNode(``,!0):(openBlock(),createElementBlock(`div`,_hoisted_1$219,[_cache[9]||=createBaseVNode(`div`,{class:`action-header`},[createBaseVNode(`div`,{class:`line left`}),createBaseVNode(`div`,{class:`title`},`Vehicle Management`),createBaseVNode(`div`,{class:`line right`})],-1),hasVehicles.value?(openBlock(),createElementBlock(`div`,_hoisted_2$178,[createBaseVNode(`div`,_hoisted_3$157,[showVehicleSelectorButtons.value?withDirectives((openBlock(),createBlock(unref(bngButton_default),{key:0,style:{height:`3em`},accent:unref(ACCENTS).ghost,onClick:_cache[0]||=$event=>unref(switchActiveVehicle)(-1),icon:unref(icons).arrowLargeLeft},{default:withCtx(()=>[createVNode(unref(bngBinding_default),{"ui-event":`tab_l`,deviceMask:`xinput`})]),_:1},8,[`accent`,`icon`])),[[unref(BngOnUiNav_default),void 0,`tab_l`,{asMouse:!0}]]):createCommentVNode(``,!0),createVNode(VehicleTileRow_default,{class:normalizeClass([`vehicle-tile-row`,{hasButtons:showVehicleSelectorButtons.value}]),data:currentVehicleData.value,enableHover:!1,small:!0},null,8,[`class`,`data`]),showVehicleSelectorButtons.value?withDirectives((openBlock(),createBlock(unref(bngButton_default),{key:1,style:{height:`3em`},accent:unref(ACCENTS).ghost,onClick:_cache[1]||=$event=>unref(switchActiveVehicle)(1),icon:unref(icons).arrowLargeRight},{default:withCtx(()=>[createVNode(unref(bngBinding_default),{"ui-event":`tab_r`,deviceMask:`xinput`})]),_:1},8,[`accent`,`icon`])),[[unref(BngOnUiNav_default),void 0,`tab_r`,{asMouse:!0}]]):createCommentVNode(``,!0)]),unref(computerStore).activeInventoryId&&unref(computerStore).vehicleSpecificComputerFunctions[unref(computerStore).activeInventoryId]?(openBlock(),createElementBlock(`div`,_hoisted_4$132,[(openBlock(!0),createElementBlock(Fragment,null,renderList(unref(computerStore).vehicleSpecificComputerFunctions[unref(computerStore).activeInventoryId],(computerFunction,index)=>withDirectives((openBlock(),createElementBlock(`div`,{class:normalizeClass([`computer-function-tile`,{"action-disabled":computerFunction.disabled}]),key:computerFunction.id,tabindex:`0`,"bng-nav-item":``,onClick:$event=>computerButtonCallback(computerFunction,unref(computerStore).activeInventoryId),onMouseover:$event=>setReason(0,infoById.value[computerFunction.id].reason),onFocus:$event=>setReason(0,infoById.value[computerFunction.id].reason),onMouseleave:_cache[2]||=$event=>setReason(0),onBlur:_cache[3]||=$event=>setReason(0)},[createVNode(unref(bngIcon_default),{class:`icon`,type:infoById.value[computerFunction.id].icon},null,8,[`type`]),createBaseVNode(`span`,_hoisted_6$98,toDisplayString(infoById.value[computerFunction.id].label),1)],42,_hoisted_5$115)),[[unref(BngOnUiNav_default),void 0,`ok`,{asMouse:!0,focusRequired:!0}],[unref(BngUiNavFocus_default),index==0?0:void 0]])),128))])):createCommentVNode(``,!0)])):(openBlock(),createElementBlock(`div`,_hoisted_7$86,[..._cache[7]||=[createBaseVNode(`span`,null,`No vehicles in garage.`,-1),createBaseVNode(`p`,null,` Place a vehicle in your garage to access modify and manage it.`,-1)]])),unref(computerStore).generalComputerFunctions?(openBlock(),createElementBlock(`div`,_hoisted_8$71,[..._cache[8]||=[createBaseVNode(`div`,{class:`line left`},null,-1),createBaseVNode(`div`,{class:`title`},`General Computer Functions`,-1),createBaseVNode(`div`,{class:`line right`},null,-1)]])):createCommentVNode(``,!0),unref(computerStore).generalComputerFunctions?(openBlock(),createElementBlock(`div`,_hoisted_9$64,[createBaseVNode(`div`,_hoisted_10$55,[(openBlock(!0),createElementBlock(Fragment,null,renderList(unref(computerStore).generalComputerFunctions,(computerFunction,index)=>(openBlock(),createElementBlock(Fragment,{key:computerFunction.id},[computerFunction.type?createCommentVNode(``,!0):withDirectives((openBlock(),createElementBlock(`div`,{key:0,class:normalizeClass([`computer-function-tile`,{"action-disabled":computerFunction.disabled}]),tabindex:`0`,"bng-nav-item":``,onClick:$event=>computerButtonCallback(computerFunction),onMouseover:$event=>setReason(1,infoById.value[computerFunction.id].reason),onFocus:$event=>setReason(1,infoById.value[computerFunction.id].reason),onMouseleave:_cache[4]||=$event=>setReason(1),onBlur:_cache[5]||=$event=>setReason(1)},[createVNode(unref(bngIcon_default),{class:`icon`,type:infoById.value[computerFunction.id].icon},null,8,[`type`]),createBaseVNode(`span`,_hoisted_12$38,toDisplayString(infoById.value[computerFunction.id].label),1)],42,_hoisted_11$49)),[[unref(BngOnUiNav_default),void 0,`ok`,{asMouse:!0,focusRequired:!0}],[unref(BngUiNavFocus_default),!hasVehicles.value&&index==0?0:void 0]])],64))),128))]),disableReason.value[0]?(openBlock(),createElementBlock(`div`,_hoisted_13$31,[withDirectives(createVNode(unref(bngIcon_default),{class:`disable-icon`,type:unref(icons).info},null,8,[`type`]),[[vShow,disableReason.value[0]]]),createBaseVNode(`span`,{innerHTML:disableReason.value[0]||`\xA0`},null,8,_hoisted_14$29)])):createCommentVNode(``,!0),disableReason.value[1]?(openBlock(),createElementBlock(`div`,_hoisted_15$28,[createVNode(unref(bngIcon_default),{class:`disable-icon`,type:unref(icons).info},null,8,[`type`]),createBaseVNode(`span`,{innerHTML:disableReason.value[1]||`\xA0`},null,8,_hoisted_16$28)])):createCommentVNode(``,!0)])):createCommentVNode(``,!0)]))]),_:1})),[[unref(BngBlur_default),1]])]),_:1},8,[`title`]))}},ComputerMain_default=__plugin_vue_export_helper_default(_sfc_main$248,[[`__scopeId`,`data-v-10a4ce58`]]);const useInsurancesStore=defineStore(`insurances`,()=>{let{events:events$3}=useBridge(),invVehsInsurancesData=ref({}),plClassesData=ref({}),uninsuredVehsData=ref({}),driverScoreData=ref({});function requestInitialData(){Lua_default.career_modules_insurance_insurance.sendUIData()}return events$3.on(`insurancesData`,data=>{invVehsInsurancesData.value=data.invVehsInsurancesData,plClassesData.value=data.plClassesData,uninsuredVehsData.value=data.uninsuredVehsData,driverScoreData.value=data.driverScoreData}),{dispose:()=>{events$3.off(`insurancesData`)},requestInitialData,closeMenu:Lua_default.career_modules_insurance_insurance.closeMenu,invVehsInsurancesData,plClassesData,uninsuredVehsData,driverScoreData}});var _hoisted_1$218={key:0,class:`cards-wrapper blue-background`},_hoisted_2$177={class:`insurance-tiers-wrapper`},_hoisted_3$156=[`onClick`],_hoisted_4$131={class:`insurance-tier-card-name`},_hoisted_5$114={class:`insurance-tier-card-description`},_hoisted_6$97={class:`insurance-tier-card-cars-insured`},_hoisted_7$85={class:`left-no-insurance`},_hoisted_8$70={class:`no-insurance-text-wrapper`},_hoisted_9$63={class:`no-insurance-title`},_hoisted_10$54={class:`no-insurance-description`},_hoisted_11$48={class:`uninsured-count`},_hoisted_12$37={key:1,class:`small-insurance-cards-wrapper blue-background`},_sfc_main$247={__name:`InsurancesMain`,setup(__props){useComputerStore();let insurancesStore=useInsurancesStore(),selectedInsuranceClassId=ref(null),selectInsuranceClass=classId=>{selectedInsuranceClassId.value=classId},sortedInsuranceClasses=computed(()=>{let classes=insurancesStore.plClassesData;return classes?Object.entries(classes).map(([classId,classData])=>({classId,classData})).sort((a$1,b)=>a$1.classData.priority-b.classData.priority):[]});onBeforeMount(()=>{insurancesStore.requestInitialData()}),onUnmounted(()=>{Lua_default.extensions.hook(`onExitInsurancesComputerScreen`),insurancesStore.$dispose()});let close=()=>{selectedInsuranceClassId.value?selectedInsuranceClassId.value=null:insurancesStore.closeMenu()},openUninsuredVehicles=()=>{addPopup(uninsuredVehicles_default,{uninsuredData:insurancesStore.uninsuredVehsData})};return(_ctx,_cache)=>(openBlock(),createBlock(ComputerWrapper_default,{ref:`wrapper`,path:[`Insurance`],title:`Insurance`,back:``,onBack:close},{default:withCtx(()=>[createVNode(unref(bngCard_default),{class:`insurances-card blue-background`},{default:withCtx(()=>[selectedInsuranceClassId.value?createCommentVNode(``,!0):(openBlock(),createElementBlock(`div`,_hoisted_1$218,[createBaseVNode(`div`,_hoisted_2$177,[(openBlock(!0),createElementBlock(Fragment,null,renderList(sortedInsuranceClasses.value,({classId,classData})=>(openBlock(),createElementBlock(`div`,{class:`insurance-tier-card`,key:classId,onClick:$event=>selectInsuranceClass(classId)},[createVNode(unref(bngIcon_default),{class:`insurance-icon`,type:unref(icons)[classData.icon]},null,8,[`type`]),createBaseVNode(`div`,_hoisted_4$131,toDisplayString(classData.name),1),createBaseVNode(`div`,_hoisted_5$114,toDisplayString(classData.description),1),createBaseVNode(`div`,_hoisted_6$97,toDisplayString(classData.carsInsured)+` VEHICLES INSURED `,1)],8,_hoisted_3$156))),128))]),createBaseVNode(`div`,{class:`no-insurance-card`,onClick:openUninsuredVehicles},[createBaseVNode(`div`,_hoisted_7$85,[createVNode(unref(bngIcon_default),{class:`no-insurance-icon`,type:unref(icons).checkmark},null,8,[`type`]),createBaseVNode(`div`,_hoisted_8$70,[createBaseVNode(`div`,_hoisted_9$63,toDisplayString(unref(insurancesStore).uninsuredVehsData.title),1),createBaseVNode(`div`,_hoisted_10$54,toDisplayString(unref(insurancesStore).uninsuredVehsData.description),1)])]),createBaseVNode(`div`,_hoisted_11$48,toDisplayString(unref(insurancesStore).uninsuredVehsData.carsUninsuredCount)+` vehicles `,1)])])),selectedInsuranceClassId.value?(openBlock(),createElementBlock(`div`,_hoisted_12$37,[(openBlock(!0),createElementBlock(Fragment,null,renderList(unref(insurancesStore).plClassesData[selectedInsuranceClassId.value].insurances,insurance=>(openBlock(),createBlock(unref(smallInsuranceCard_default),{key:insurance.id,insuranceData:insurance,driverScoreData:unref(insurancesStore).driverScoreData},null,8,[`insuranceData`,`driverScoreData`]))),128))])):createCommentVNode(``,!0)]),_:1})]),_:1},512))}},InsurancesMain_default=__plugin_vue_export_helper_default(_sfc_main$247,[[`__scopeId`,`data-v-a9e49ad5`]]),_hoisted_1$217={key:0,class:`content`},_hoisted_2$176={class:`stats-grid-3`},_hoisted_3$155={class:`score-header`},_hoisted_4$130={class:`score-content`},_hoisted_5$113={class:`score-info`},_hoisted_6$96={class:`score-description`},_hoisted_7$84={class:`stat-card`},_hoisted_8$69={class:`stat-value blue`},_hoisted_9$62={class:`stat-card`},_hoisted_10$53={class:`stats-grid-2`},_hoisted_11$47={class:`info-card`},_hoisted_12$36={class:`info-rows`},_hoisted_13$30={class:`info-row`},_hoisted_14$28={class:`info-value orange`},_hoisted_15$27={class:`info-row`},_hoisted_16$27={class:`info-value green`},_hoisted_17$22={class:`info-row total`},_hoisted_18$19={class:`info-value`},_hoisted_19$16={class:`info-card`},_hoisted_20$14={class:`info-rows`},_hoisted_21$13={class:`info-row bottom-border`},_hoisted_22$11={class:`info-value blue`},_hoisted_23$10={class:`info-row`},_hoisted_24$9={class:`info-value red`},_hoisted_25$8={class:`info-row`},_hoisted_26$6={class:`info-value orange`},_hoisted_27$6={class:`info-row`},_hoisted_28$5={class:`info-value yellow`},_hoisted_29$5={class:`info-row total`},_hoisted_30$5={class:`info-value`},_hoisted_31$5={class:`info-summary`},_hoisted_32$5={class:`info-row small`},_hoisted_33$5={class:`info-value green bold`},_hoisted_34$5={class:`reset-card`},_hoisted_35$4={class:`reset-content`},_hoisted_36$4={class:`reset-description`},_hoisted_37$3={class:`highlight`},_hoisted_38$3={class:`reset-details`},_hoisted_39$3={class:`reset-row`},_hoisted_40$2={class:`reset-row`},_hoisted_41$2={class:`reset-value green`},_hoisted_42$2={class:`reset-row cost`},_hoisted_43$2={class:`reset-value yellow large`},_hoisted_44$2={key:0,class:`reset-payback`},_hoisted_45$2=[`disabled`],_sfc_main$246={__name:`DriverAbstract`,setup(__props){let{units}=useBridge(),abstractData=ref(null),driverTier=computed(()=>abstractData.value?.driverScoreTier),totalDistanceFormatted=computed(()=>abstractData.value?units.buildString(`length`,abstractData.value.totalDistanceDriven,0):``),premiumEffectClass=computed(()=>{if(!driverTier.value)return``;let multiplier=driverTier.value.multiplier;return multiplier<1?`green`:multiplier>1?`red`:`neutral`}),premiumEffectText=computed(()=>{if(!driverTier.value)return`Standard Rate`;let multiplier=driverTier.value.multiplier;return multiplier<1?`${Math.round((1-multiplier)*100)}% Savings`:multiplier>1?`${Math.round((multiplier-1)*100)}% Penalty`:`Standard Rate`}),canResetScore=computed(()=>abstractData.value?abstractData.value.driverScore{if(!driverTier.value)return`green`;let multiplier=driverTier.value.multiplier;return multiplier<1?`blue`:multiplier<1.1?`green`:multiplier<1.3?`yellow`:multiplier<1.5?`orange`:`red`},getDriverColor=()=>({blue:`var(--blue-200)`,green:`var(--green-300)`,yellow:`var(--yellow-400)`,orange:`var(--orange-shade-10)`,red:`var(--red-400)`})[getDriverColorClass()]||`var(--green-300)`,loadData=async()=>{try{abstractData.value=await Lua_default.career_modules_playerAbstract.getPlayerAbstractData()}catch(error){console.error(`Failed to load driver abstract data:`,error)}},resetDriverScore=async()=>{try{await Lua_default.career_modules_insurance_insurance.resetDriverScore(),await loadData()}catch(error){console.error(`Failed to reset driver score:`,error)}},close=()=>{Lua_default.career_modules_playerAbstract.closePlayerAbstractMenu()};return onBeforeMount(loadData),(_ctx,_cache)=>(openBlock(),createBlock(ComputerWrapper_default,{ref:`wrapper`,path:[`Driver's Abstract`],title:`Driver's Abstract`,back:``,onBack:close},{default:withCtx(()=>[createVNode(unref(bngCard_default),{class:`driver-abstract-card`},{default:withCtx(()=>[abstractData.value?(openBlock(),createElementBlock(`div`,_hoisted_1$217,[createBaseVNode(`div`,_hoisted_2$176,[createBaseVNode(`div`,{class:`score-card`,style:normalizeStyle({borderColor:getDriverColor()})},[createBaseVNode(`div`,_hoisted_3$155,[_cache[0]||=createBaseVNode(`div`,{class:`section-title`},`Driver Score: Out of 100`,-1),createVNode(unref(TutorialButton_default),{icon:unref(icons).help,pages:[`driverScore`]},null,8,[`icon`])]),createBaseVNode(`div`,_hoisted_4$130,[createBaseVNode(`div`,{class:normalizeClass([`score-value`,getDriverColorClass()])},toDisplayString(abstractData.value.driverScore),3),createBaseVNode(`div`,_hoisted_5$113,[createBaseVNode(`div`,{class:normalizeClass([`score-risk`,getDriverColorClass()])},toDisplayString(abstractData.value.driverScoreTier.risk),3),createBaseVNode(`div`,_hoisted_6$96,toDisplayString(abstractData.value.driverScoreTier.description),1)])])],4),createBaseVNode(`div`,_hoisted_7$84,[_cache[1]||=createBaseVNode(`div`,{class:`section-title`},`Total Distance Driven`,-1),createBaseVNode(`div`,_hoisted_8$69,toDisplayString(totalDistanceFormatted.value),1)]),createBaseVNode(`div`,_hoisted_9$62,[_cache[2]||=createBaseVNode(`div`,{class:`section-title`},`Premium Effect`,-1),createBaseVNode(`div`,{class:normalizeClass([`stat-value`,premiumEffectClass.value])},toDisplayString(premiumEffectText.value),3),_cache[3]||=createBaseVNode(`div`,{class:`stat-note`},` Applies to every insurance provider when premiums renew `,-1)])]),createBaseVNode(`div`,_hoisted_10$53,[createBaseVNode(`div`,_hoisted_11$47,[_cache[7]||=createBaseVNode(`div`,{class:`section-title`},`Repair History`,-1),createBaseVNode(`div`,_hoisted_12$36,[createBaseVNode(`div`,_hoisted_13$30,[_cache[4]||=createBaseVNode(`span`,{class:`info-label`},`Insurance Claims:`,-1),createBaseVNode(`span`,_hoisted_14$28,toDisplayString(abstractData.value.repairHistory.insuranceRepairs),1)]),createBaseVNode(`div`,_hoisted_15$27,[_cache[5]||=createBaseVNode(`span`,{class:`info-label`},`Private Repairs:`,-1),createBaseVNode(`span`,_hoisted_16$27,toDisplayString(abstractData.value.repairHistory.privateRepairs),1)]),createBaseVNode(`div`,_hoisted_17$22,[_cache[6]||=createBaseVNode(`span`,{class:`info-label`},`Total Repairs:`,-1),createBaseVNode(`span`,_hoisted_18$19,toDisplayString(abstractData.value.repairHistory.insuranceRepairs+abstractData.value.repairHistory.privateRepairs),1)])]),_cache[8]||=createBaseVNode(`div`,{class:`info-tip`},` Private repairs don't affect your record `,-1)]),createBaseVNode(`div`,_hoisted_19$16,[_cache[16]||=createBaseVNode(`div`,{class:`section-title`},`Financial Summary`,-1),createBaseVNode(`div`,_hoisted_20$14,[createBaseVNode(`div`,_hoisted_21$13,[_cache[9]||=createBaseVNode(`span`,{class:`info-label`},`Vehicles Currently Insured:`,-1),createBaseVNode(`span`,_hoisted_22$11,toDisplayString(abstractData.value.financialSummary.vehiclesInsuredCount),1)]),createBaseVNode(`div`,_hoisted_23$10,[_cache[10]||=createBaseVNode(`span`,{class:`info-label`},`Premiums Paid:`,-1),createBaseVNode(`span`,_hoisted_24$9,[createVNode(unref(bngUnit_default),{class:`no-margin`,money:abstractData.value.financialSummary.totalPremiumPaid},null,8,[`money`])])]),createBaseVNode(`div`,_hoisted_25$8,[_cache[11]||=createBaseVNode(`span`,{class:`info-label`},`Deductibles Paid:`,-1),createBaseVNode(`span`,_hoisted_26$6,[createVNode(unref(bngUnit_default),{class:`no-margin`,money:abstractData.value.financialSummary.totalDeductiblePaid},null,8,[`money`])])]),createBaseVNode(`div`,_hoisted_27$6,[_cache[12]||=createBaseVNode(`span`,{class:`info-label`},`Private Repairs:`,-1),createBaseVNode(`span`,_hoisted_28$5,[createVNode(unref(bngUnit_default),{class:`no-margin`,money:abstractData.value.financialSummary.totalPrivateRepairsPaid},null,8,[`money`])])]),createBaseVNode(`div`,_hoisted_29$5,[_cache[13]||=createBaseVNode(`span`,{class:`info-label`},`Total Spent:`,-1),createBaseVNode(`span`,_hoisted_30$5,[createVNode(unref(bngUnit_default),{class:`no-margin`,money:abstractData.value.financialSummary.totalPaid},null,8,[`money`])])])]),createBaseVNode(`div`,_hoisted_31$5,[createBaseVNode(`div`,_hoisted_32$5,[_cache[14]||=createBaseVNode(`span`,{class:`info-label`},`Damage Covered by Insurance:`,-1),createBaseVNode(`span`,_hoisted_33$5,[createVNode(unref(bngUnit_default),{class:`no-margin`,money:abstractData.value.financialSummary.damageCoveredByInsurance},null,8,[`money`])])]),_cache[15]||=createBaseVNode(`div`,{class:`info-tip blue italic`},` Insurance saved you from paying full repair costs `,-1)])])]),createBaseVNode(`div`,_hoisted_34$5,[_cache[22]||=createBaseVNode(`div`,{class:`section-title`},`Driver Score Reset`,-1),createBaseVNode(`div`,_hoisted_35$4,[createBaseVNode(`p`,_hoisted_36$4,[_cache[17]||=createTextVNode(` Reset your driver score to `,-1),createBaseVNode(`span`,_hoisted_37$3,toDisplayString(abstractData.value.driverScoreReset.resetTo),1),_cache[18]||=createTextVNode(` to remove premium penalties. `,-1)]),createBaseVNode(`div`,_hoisted_38$3,[createBaseVNode(`div`,_hoisted_39$3,[_cache[19]||=createBaseVNode(`span`,{class:`reset-label`},`Current Score:`,-1),createBaseVNode(`span`,{class:normalizeClass([`reset-value`,canResetScore.value?`red`:`green`])},toDisplayString(abstractData.value.driverScore),3)]),createBaseVNode(`div`,_hoisted_40$2,[_cache[20]||=createBaseVNode(`span`,{class:`reset-label`},`Reset To:`,-1),createBaseVNode(`span`,_hoisted_41$2,toDisplayString(abstractData.value.driverScoreReset.resetTo),1)]),createBaseVNode(`div`,_hoisted_42$2,[_cache[21]||=createBaseVNode(`span`,{class:`reset-label`},`Reset Cost:`,-1),createBaseVNode(`span`,_hoisted_43$2,[createVNode(unref(bngUnit_default),{class:`no-margin`,money:abstractData.value.driverScoreReset.resetCost},null,8,[`money`])])]),canResetScore.value&&_ctx.resetSavingsPer100km>0?(openBlock(),createElementBlock(`div`,_hoisted_44$2,` Pays for itself after xxx km `)):createCommentVNode(``,!0)]),createBaseVNode(`button`,{onClick:resetDriverScore,disabled:!canResetScore.value,class:normalizeClass([`reset-button`,{disabled:!canResetScore.value}])},toDisplayString(canResetScore.value?`Reset Score`:`Not Available (Score Already at or Higher than `+abstractData.value.driverScoreReset.resetTo+`)`),11,_hoisted_45$2)])])])):createCommentVNode(``,!0)]),_:1})]),_:1},512))}},DriverAbstract_default=__plugin_vue_export_helper_default(_sfc_main$246,[[`__scopeId`,`data-v-8041df87`]]),_hoisted_1$216={"bng-ui-scope":`logbook`,class:`career-logbook-wrapper`},_hoisted_2$175={class:`career-logbook-container`},_hoisted_3$154={class:`career-logbook-list`},_hoisted_4$129={class:`logbook-list-wrapper`},_hoisted_5$112=[`onClick`],_hoisted_6$95={class:`career-logbook-item-content`},_hoisted_7$83={class:`career-logbook-meta`},_hoisted_8$68={class:`career-logbook-newmark`},_hoisted_9$61={class:`career-logbook-item-label`},_hoisted_10$52={class:`career-logbook-details`},_hoisted_11$46={class:`career-logbook-title-newmark`},_hoisted_12$35={class:`career-logbook-meta`},_hoisted_13$29={key:0},_hoisted_14$27={class:`logbook-description`},_hoisted_15$26={key:1,class:`logbook-description logbook-table`},_hoisted_16$26={key:2},_hoisted_17$21={key:3,class:`logbook-description quest-status`},_hoisted_18$18={class:`quest-stats-wrapper`},_hoisted_19$15={class:`quest-labels`},_hoisted_20$13={class:`progress-label`},_hoisted_21$12={key:0,class:`progressbar-background`},_hoisted_22$10={class:`rewards-wrapper flex-row`},_hoisted_23$9={class:`label`},_hoisted_24$8={class:`rewards-section flex-row`},_hoisted_25$7={class:`flex-row`},_sfc_main$245={__name:`Logbook`,props:{id:String},setup(__props){useUINavScope(`logbook`);let rewardUnitTypes={money:`beambucks`,beamXP:`xp`},props=__props,sectionTabs=ref(),entryId=computed(()=>props.id===void 0?void 0:(``+props.id).replace(/%/g,`/`)),logbookTabs=ref([{id:`info`,name:`Info`,entries:[],filter:i=>i.type===`info`},{id:`history`,name:`History`,entries:[],filter:i=>i.type===`progress`}]),checkForNewLogEntries=()=>logbookTabs.value.forEach(tab=>tab.hasNew=!!tab.entries.some(i=>i.isNew));function setup$3(data){if(data.forEach(entry=>{Object.hasOwn(entry,`text`)&&(entry.text=parse$1($translate.contextTranslate(entry.text,!0)),entry._ready=!0)}),logbookTabs.value.forEach(tab=>tab.entries=data.filter(tab.filter)),checkForNewLogEntries(),entryId.value){for(let tab of logbookTabs.value)for(let entry of tab.entries)if(``+entry.entryId===entryId.value){toggleExpand(entry),tab.isPreselected=!0;return}}logbookTabs.value[0].entries.length&&toggleExpand(logbookTabs.value[0].entries[0])}ref({});let selectedEntry=ref({});ref({});let readTimer,toggleExpand=entry=>setTimeout(()=>{readTimer&&clearTimeout(readTimer),selectedEntry.value=entry,readTimer=window.setTimeout(()=>{selectedEntry.value.isNew=!1,checkForNewLogEntries(),entry.type===`quest`?Lua_default.career_modules_questManager.setQuestAsNotNew(entry.questId):Lua_default.career_modules_logbook.setLogbookEntryRead(entry.entryId,!0)},1e3)},0),tabChange=newTab=>{if(entryId.value){entryId.value=void 0;return}let tab=logbookTabs.value[newTab.id];!tab||!tab.entries||tab.entries.length===0||toggleExpand(tab.entries[0])},claimRewards=entry=>{Lua_default.career_modules_questManager.claimRewardsById(entry.questId),entry.claimable=!1,entry.claimed=!0},exit=()=>setTimeout(()=>window.bngVue.gotoAngularState(`menu.careerPause`),0);return onBeforeMount(()=>{Lua_default.simTimeAuthority.pushPauseRequest(`logbook`)}),onMounted(()=>{Lua_default.career_modules_logbook.getLogbook().then(setup$3)}),onUnmounted(()=>{Lua_default.simTimeAuthority.popPauseRequest(`logbook`)}),(_ctx,_cache)=>withDirectives((openBlock(),createBlock(unref(layoutSingle_default),{class:`logbook-layout`},{default:withCtx(()=>[createVNode(unref(bngScreenHeading_default),null,{default:withCtx(()=>[createTextVNode(toDisplayString(_ctx.$t(`ui.career.logbook.subHeading`)),1)]),_:1}),withDirectives((openBlock(),createElementBlock(`div`,_hoisted_1$216,[createBaseVNode(`div`,_hoisted_2$175,[createBaseVNode(`div`,_hoisted_3$154,[createVNode(unref(tabs_default),{ref_key:`sectionTabs`,ref:sectionTabs,onChange:tabChange,class:`bng-tabs`,"make-tab-header-classes":tabDetails=>({flagged:tabDetails.data.hasNew})},{default:withCtx(()=>[(openBlock(!0),createElementBlock(Fragment,null,renderList(logbookTabs.value,tabDetail=>(openBlock(),createBlock(unref(tab_default),{key:tabDetail.id,heading:_ctx.$t(tabDetail.name),active:tabDetail.isPreselected,data:tabDetail},{default:withCtx(()=>[withDirectives((openBlock(),createElementBlock(`div`,_hoisted_4$129,[(openBlock(!0),createElementBlock(Fragment,null,renderList(tabDetail.entries,(entry,index)=>withDirectives((openBlock(),createElementBlock(`div`,{key:entry.entryId,"bng-nav-item":``,class:normalizeClass([`career-logbook-item`,{selected:selectedEntry.value!==void 0&&selectedEntry.value.entryId==entry.entryId}]),onClick:$event=>toggleExpand(entry)},[createBaseVNode(`div`,_hoisted_6$95,[createBaseVNode(`div`,_hoisted_7$83,[createBaseVNode(`div`,null,toDisplayString(_ctx.$ctx_t(entry.cardTypeLabel)),1),createVNode(unref(bngDivider_default),{class:`vertical-divider`}),withDirectives(createBaseVNode(`div`,null,null,512),[[unref(BngRelativeTime_default),entry.time]]),withDirectives(createBaseVNode(`div`,_hoisted_8$68,null,512),[[vShow,entry.isNew]])]),createBaseVNode(`div`,_hoisted_9$61,toDisplayString(_ctx.$ctx_t(entry.title)),1)])],10,_hoisted_5$112)),[[unref(BngUiNavFocus_default),tabDetail.entries.length-index],[unref(BngSoundClass_default),`bng_click_generic_small`]])),128))])),[[unref(BngUiNavScroll_default)]])]),_:2},1032,[`heading`,`active`,`data`]))),128))]),_:1},8,[`make-tab-header-classes`])]),createBaseVNode(`div`,_hoisted_10$52,[withDirectives(createVNode(unref(bngCard_default),{class:`career-logbook-content-card`},createSlots({default:withCtx(()=>[createVNode(unref(bngCardHeading_default),{class:`logbook-entry-heading`,type:`ribbon`},{default:withCtx(()=>[createTextVNode(toDisplayString(selectedEntry.value&&_ctx.$ctx_t(selectedEntry.value.title))+` `,1),withDirectives(createBaseVNode(`div`,_hoisted_11$46,null,512),[[vShow,selectedEntry.value.isNew]]),withDirectives((openBlock(),createBlock(unref(bngButton_default),{class:`exitButton`,onClick:exit,accent:unref(ACCENTS).attention},{default:withCtx(()=>[createVNode(unref(bngBinding_default),{"ui-event":`back`,deviceMask:`xinput`}),_cache[1]||=createTextVNode(`Back`,-1)]),_:1},8,[`accent`])),[[unref(BngSoundClass_default),`bng_back_generic`]])]),_:1}),createBaseVNode(`div`,_hoisted_12$35,[createBaseVNode(`div`,null,toDisplayString(_ctx.$ctx_t(selectedEntry.value.cardTypeLabel)),1),createVNode(unref(bngDivider_default),{class:`vertical-divider`}),withDirectives(createBaseVNode(`div`,null,null,512),[[unref(BngRelativeTime_default),selectedEntry.value.time]])]),createBaseVNode(`div`,{class:normalizeClass({"card-body":!0,"with-rewards":selectedEntry.value.type===`quest`&&selectedEntry.value.rewards.length})},[selectedEntry.value.cover?(openBlock(),createElementBlock(`div`,{key:0,class:`logbook-cover-image`,style:normalizeStyle({backgroundImage:`url(${selectedEntry.value.cover})`})},[selectedEntry.value.coverText?(openBlock(),createElementBlock(`h1`,_hoisted_13$29,toDisplayString(selectedEntry.value.coverText),1)):createCommentVNode(``,!0)],4)):createCommentVNode(``,!0),createBaseVNode(`div`,_hoisted_14$27,[selectedEntry.value._ready?(openBlock(),createBlock(unref(dynamicComponent_default),{key:0,template:_ctx.$ctx_t(selectedEntry.value.text)},null,8,[`template`])):createCommentVNode(``,!0)]),selectedEntry.value.tables?(openBlock(),createElementBlock(`div`,_hoisted_15$26,[(openBlock(!0),createElementBlock(Fragment,null,renderList(selectedEntry.value.tables,(table,keyT)=>(openBlock(),createElementBlock(`table`,{key:keyT},[createBaseVNode(`tbody`,null,[createBaseVNode(`tr`,null,[(openBlock(!0),createElementBlock(Fragment,null,renderList(table.headers,(header,keyH)=>(openBlock(),createElementBlock(`th`,{key:keyH},toDisplayString(header),1))),128))]),(openBlock(!0),createElementBlock(Fragment,null,renderList(table.rows,(row,keyR)=>(openBlock(),createElementBlock(`tr`,{key:keyR},[(openBlock(!0),createElementBlock(Fragment,null,renderList(row,(data,keyD)=>(openBlock(),createElementBlock(`td`,{key:keyD},[typeof data==`object`&&data&&data.hasOwnProperty(`type`)&&data.type===`rewards`?(openBlock(),createBlock(RewardsPills_default,{key:0,rewards:data.rewards,hideNumbers:!1},null,8,[`rewards`])):(openBlock(),createBlock(unref(dynamicComponent_default),{key:1,template:_ctx.$ctx_t(data)},null,8,[`template`]))]))),128))]))),128))])]))),128))])):createCommentVNode(``,!0),selectedEntry.value.type===`quest`?(openBlock(),createElementBlock(`hr`,_hoisted_16$26)):createCommentVNode(``,!0),selectedEntry.value.type===`quest`?(openBlock(),createElementBlock(`div`,_hoisted_17$21,[_cache[2]||=createBaseVNode(`h4`,null,`Milestone Status`,-1),(openBlock(!0),createElementBlock(Fragment,null,renderList(selectedEntry.value.progress,prog=>(openBlock(),createElementBlock(`div`,null,[createBaseVNode(`div`,_hoisted_18$18,[createBaseVNode(`div`,_hoisted_19$15,[prog.done?(openBlock(),createBlock(unref(bngIcon_default),{key:0,class:`check-icon`,type:prog.failed?unref(icons).missionCheckboxCross:prog.done?unref(icons).checkboxOn:unref(icons).checkboxOff},null,8,[`type`])):createCommentVNode(``,!0),createBaseVNode(`div`,_hoisted_20$13,toDisplayString(_ctx.$ctx_t(prog.label)),1)]),prog.type===`progressBar`?(openBlock(),createElementBlock(`div`,_hoisted_21$12,[createBaseVNode(`div`,{class:`progressbar-fill`,style:normalizeStyle({width:(prog.currValue>0?prog.currValue/(prog.maxValue-prog.minValue)*100:0)+`%`})},null,4)])):createCommentVNode(``,!0)])]))),256))])):createCommentVNode(``,!0)],2)]),_:2},[selectedEntry.value.type===`quest`&&selectedEntry.value.rewards.length?{name:`footer`,fn:withCtx(()=>[createBaseVNode(`div`,_hoisted_22$10,[createBaseVNode(`div`,_hoisted_23$9,toDisplayString(_ctx.$t(`ui.career.logbook.rewards`))+`:`,1),createBaseVNode(`div`,_hoisted_24$8,[(openBlock(!0),createElementBlock(Fragment,null,renderList(selectedEntry.value.rewards,reward=>(openBlock(),createElementBlock(`div`,_hoisted_25$7,[createVNode(unref(bngUnit_default),mergeProps({class:`reward-icon`},{ref_for:!0},{[rewardUnitTypes[reward.attributeKey]]:reward.rewardAmount},{options:{formatter:x=>~~x}}),null,16,[`options`])]))),256))]),withDirectives((openBlock(),createBlock(unref(bngButton_default),{onClick:_cache[0]||=$event=>claimRewards(selectedEntry.value),disabled:!selectedEntry.value.claimable},{default:withCtx(()=>[createTextVNode(toDisplayString(_ctx.$t(`ui.career.logbook.claimRewards`)),1)]),_:1},8,[`disabled`])),[[vShow,!selectedEntry.value.claimed],[unref(BngSoundClass_default),`bng_click_generic`]]),withDirectives(createVNode(unref(bngButton_default),{disabled:!0},{default:withCtx(()=>[createTextVNode(toDisplayString(_ctx.$t(`ui.career.logbook.rewardsClaimed`)),1)]),_:1},512),[[vShow,selectedEntry.value.claimed]])])]),key:`0`}:void 0]),1536),[[vShow,selectedEntry.value!==void 0]])])])])),[[unref(BngOnUiNav_default),exit,`back,menu`],[unref(BngOnUiNav_default),sectionTabs.value&§ionTabs.value.goPrev,`tab_l`],[unref(BngOnUiNav_default),sectionTabs.value&§ionTabs.value.goNext,`tab_r`]])]),_:1})),[[unref(BngBlur_default)]])}},Logbook_default=__plugin_vue_export_helper_default(_sfc_main$245,[[`__scopeId`,`data-v-e8139034`]]),_hoisted_1$215={class:`milestones-wrapper`},_hoisted_2$174={"bng-ui-scope":`milestones`,class:`career-milestones-card`},_hoisted_3$153={class:`career-milestones-container`},_hoisted_4$128={class:`actions`},_hoisted_5$111={class:`filters`},_hoisted_6$94={class:`scrollable-container`,"bng-nav-scroll-force":``},_hoisted_7$82={class:`cards-container`},_sfc_main$244={__name:`Milestones`,props:{id:String},setup(__props){useUINavScope(`milestones`);let careerStatusRef=ref(),allEntries=[],entries=ref([]),selectOneFilters=ref(),selectedFilters=ref([`general`]),FILTER_OPTIONS=[{value:`general`,label:`General`},{value:`all`,label:`All`},{value:`mission`,label:`Challenges`},{value:`branch`,label:`Branches`},{value:`delivery`,label:`Delivery`},{value:`money`,label:`Money`},{value:`speedTrap`,label:`Speed Traps`},{value:`insurance`,label:`Insurance`}];function sortMilestones(){entries.value.sort(function(a$1,b){return a$1.claimable&&!b.claimable?-1:b.claimable&&!a$1.claimable?1:!a$1.completed&&b.completed?-1:a$1.completed&&!b.completed?1:a$1.claimId!0):entries.value=allEntries.filter(e=>e.filter[currentFilter]),sortMilestones()}function filterChanged(filterList){filterList&&(currentFilter=filterList[0]),filterEntries()}function setup$3(data){allEntries=data.list;let hasClaimable=!1;data.list.forEach(x=>{x.claimable&&(hasClaimable=!0)}),hasClaimable&&(selectedFilters.value=[`all`],filterChanged(selectedFilters.value)),filterEntries()}Lua_default.career_modules_milestones_milestones.getMilestones().then(setup$3);let claimMilestone=entry=>{Lua_default.career_modules_milestones_milestones.claim(entry.claimId).then(replacementEntry=>{careerStatusRef.value.updateDisplay();let replacementId=allEntries.findIndex(item=>item.claimId===entry.claimId);if(replacementEntry!=null&&replacementId!==-1){allEntries[replacementId]=replacementEntry,filterEntries();return}allEntries[replacementId].claimable=!1,filterEntries()})},exit=()=>{window.bngVue.gotoGameState(`progressLanding`)};return onUnmounted(()=>{Lua_default.simTimeAuthority.popPauseRequest(`milestones`)}),onBeforeMount(()=>{Lua_default.simTimeAuthority.pushPauseRequest(`milestones`)}),(_ctx,_cache)=>withDirectives((openBlock(),createBlock(unref(layoutSingle_default),{class:`milestones-layout`},{default:withCtx(()=>[createBaseVNode(`div`,_hoisted_1$215,[createVNode(unref(bngScreenHeading_default),null,{default:withCtx(()=>[..._cache[1]||=[createTextVNode(`Milestones`,-1)]]),_:1}),withDirectives((openBlock(),createElementBlock(`div`,_hoisted_2$174,[createBaseVNode(`div`,_hoisted_3$153,[createBaseVNode(`div`,_hoisted_4$128,[createVNode(unref(bngButton_default),{class:`exitButton`,onClick:exit,accent:unref(ACCENTS).attention},{default:withCtx(()=>[createVNode(unref(bngBinding_default),{tabindex:`1`,"ui-event":`back`,deviceMask:`xinput`}),_cache[2]||=createTextVNode(`Back`,-1)]),_:1},8,[`accent`]),createVNode(unref(careerStatus_default),{class:`career-page-status`,ref_key:`careerStatusRef`,ref:careerStatusRef},null,512)]),createBaseVNode(`div`,_hoisted_5$111,[createVNode(unref(bngIcon_default),{class:`career-filter-icon`,type:unref(icons).filter},null,8,[`type`]),createVNode(unref(bngPillFilters_default),{required:``,ref_key:`selectOneFilters`,ref:selectOneFilters,modelValue:selectedFilters.value,"onUpdate:modelValue":_cache[0]||=$event=>selectedFilters.value=$event,options:FILTER_OPTIONS,onValueChanged:filterChanged},null,8,[`modelValue`])]),createBaseVNode(`div`,_hoisted_6$94,[createBaseVNode(`div`,_hoisted_7$82,[(openBlock(!0),createElementBlock(Fragment,null,renderList(entries.value,entry=>withDirectives((openBlock(),createBlock(MilestoneCard_default,{tabindex:`1`,milestone:entry,isCondensed:!1,onClaim:claimMilestone},null,8,[`milestone`])),[[unref(BngSoundClass_default),entry.claimable?`bng_click_hover_generic`:`bng_hover_generic`]])),256))])])])])),[[unref(BngOnUiNav_default),exit,`back,menu`],[unref(BngOnUiNav_default),selectOneFilters.value&&selectOneFilters.value.focusPrevious,`tab_l`],[unref(BngOnUiNav_default),selectOneFilters.value&&selectOneFilters.value.focusNext,`tab_r`]])])]),_:1})),[[unref(BngOnUiNav_default),exit,`back,menu`],[unref(BngBlur_default)]])}},Milestones_default=__plugin_vue_export_helper_default(_sfc_main$244,[[`__scopeId`,`data-v-798d8c2a`]]),_hoisted_1$214={class:`panel-flex`},_hoisted_2$173={style:{"overflow-y":`scroll`}},_hoisted_3$152={class:`content-row selected-and-map-panel`},_hoisted_4$127={key:0,class:`content`},TAB_HEADINGS={parcels:`Parcels`,smallFluids:`Fluid Orders`,largeFluids:`Fluid Custom`,smallDryBulk:`Dry Bulk Orders`,largeDryBulk:`Dry Bulk Custom`,vehicles:`Vehicles`,trailers:`Trailers`,loaners:`Loaners`},_sfc_main$243={__name:`MyCargo`,props:{facilityId:String,parkingSpotPath:String},setup(__props){ref(3),ref(1);let{events:events$3}=useBridge();useUINavScope(`myCargo`);let props=__props;ref(null),ref(),ref(TAB_HEADINGS.parcels),ref(),ref();let cargoOverviewStore=useCargoOverviewStore(),updateCargoDataAll=()=>{cargoOverviewStore.requestCargoData(props.facilityId,props.parkingSpotPath)},close=()=>{Lua_default.career_modules_delivery_cargoScreen.exitCargoOverviewScreen()};return events$3.on(`updateCargoData`,updateCargoDataAll),onMounted(()=>{Lua_default.career_modules_delivery_cargoScreen.setCargoScreenTab(`all`),updateCargoDataAll()}),onUnmounted(()=>{cargoOverviewStore.menuClosed(),events$3.off(`updateCargoData`,updateCargoDataAll)}),(_ctx,_cache)=>(openBlock(),createElementBlock(Fragment,null,[_cache[22]||=createBaseVNode(`div`,{style:{color:`white`}},`#Hello`,-1),unref(cargoOverviewStore).cargoData?(openBlock(),createBlock(ComputerWrapper_default,{key:0,path:[`My Cargo`],title:`My Cargo 2`,back:``,onBack:close},{status:withCtx(()=>[..._cache[10]||=[createTextVNode(` Delivery Lvl 2 | Car Jockey Lvl 3 | Facility Reputation: Good `,-1)]]),top:withCtx(()=>[..._cache[11]||=[createBaseVNode(`div`,{style:{width:`100%`,padding:`0.3em`,background:`#8888ff`}},` FILTERTABS `,-1)]]),default:withCtx(()=>[createBaseVNode(`div`,_hoisted_1$214,[createVNode(unref(bngCard_default),{class:`content-row provided-orders-panel`},{default:withCtx(()=>[createVNode(unref(bngCardHeading_default),{type:`ribbon`,class:`cardHeading`},{default:withCtx(()=>[..._cache[12]||=[createTextVNode(` My Cargo `,-1)]]),_:1}),createVNode(unref(bngSwitch_default),{modelValue:unref(cargoOverviewStore).automaticRoute,"onUpdate:modelValue":_cache[0]||=$event=>unref(cargoOverviewStore).automaticRoute=$event},{default:withCtx(()=>[..._cache[13]||=[createTextVNode(` Automatic route `,-1)]]),_:1},8,[`modelValue`]),createVNode(unref(bngSlider_default),{min:0,max:unref(cargoOverviewStore).cargoData.playerCardGroupSets.length-1,step:1,modelValue:unref(cargoOverviewStore).playerGroupingIdx,"onUpdate:modelValue":_cache[1]||=$event=>unref(cargoOverviewStore).playerGroupingIdx=$event,onChange:unref(cargoOverviewStore).setGroupingAndSorting},null,8,[`max`,`modelValue`,`onChange`]),createVNode(unref(bngSlider_default),{min:0,max:unref(cargoOverviewStore).cargoData.sortingSets.length-1,step:1,modelValue:unref(cargoOverviewStore).playerSortingIdx,"onUpdate:modelValue":_cache[2]||=$event=>unref(cargoOverviewStore).playerSortingIdx=$event,onChange:unref(cargoOverviewStore).setGroupingAndSorting},null,8,[`max`,`modelValue`,`onChange`]),createVNode(unref(bngCardHeading_default),{type:`ribbon`,class:`cardHeading`},{default:withCtx(()=>[createTextVNode(` Grouped `+toDisplayString(unref(cargoOverviewStore).cargoData.playerCardGroupSets[unref(cargoOverviewStore).playerGroupingIdx].label)+`, Sorted `+toDisplayString(unref(cargoOverviewStore).cargoData.sortingSets[unref(cargoOverviewStore).playerSortingIdx].label),1)]),_:1}),createBaseVNode(`div`,_hoisted_2$173,[createVNode(ProvidedOrdersPanel_default,{groupSets:unref(cargoOverviewStore).cargoData.playerCardGroupSets,groupIdx:unref(cargoOverviewStore).playerGroupingIdx,sortingSets:unref(cargoOverviewStore).cargoData.sortingSets,sortIdx:unref(cargoOverviewStore).playerSortingIdx,onCardHovered:unref(cargoOverviewStore).cardHovered,onCardClicked:unref(cargoOverviewStore).cardClicked},null,8,[`groupSets`,`groupIdx`,`sortingSets`,`sortIdx`,`onCardHovered`,`onCardClicked`])])]),_:1}),createBaseVNode(`div`,_hoisted_3$152,[createVNode(unref(bngCard_default),{class:`cargo-detail`},createSlots({default:withCtx(()=>[createVNode(unref(bngCardHeading_default),{type:`ribbon`,class:`cardHeading`},{default:withCtx(()=>[..._cache[14]||=[createTextVNode(` Details View `,-1)]]),_:1}),unref(cargoOverviewStore).focusedCargo?(openBlock(),createElementBlock(`div`,_hoisted_4$127,[createVNode(CargoCard_default,{card:unref(cargoOverviewStore).focusedCargo,detailed:``},null,8,[`card`])])):createCommentVNode(``,!0)]),_:2},[unref(cargoOverviewStore).focusedCargo?{name:`buttons`,fn:withCtx(()=>[unref(cargoOverviewStore).focusedCargo.cardType==`parcelGroup`?(openBlock(),createElementBlock(Fragment,{key:0},[unref(cargoOverviewStore).focusedCargo.isFacilityCard?(openBlock(),createElementBlock(Fragment,{key:0},[createVNode(unref(bngButton_default),{disabled:!unref(cargoOverviewStore).focusedCargo.enabled||unref(cargoOverviewStore).focusedCargo.transientMoveCounts==0,accent:`text`,onClick:_cache[3]||=$event=>unref(cargoOverviewStore).clearLoad(unref(cargoOverviewStore).focusedCargo)},{default:withCtx(()=>[..._cache[15]||=[createTextVNode(` Clear Load `,-1)]]),_:1},8,[`disabled`]),createVNode(unref(bngButton_default),{disabled:!unref(cargoOverviewStore).focusedCargo.enabled||unref(cargoOverviewStore).focusedCargo.autoLoadLocations&&unref(cargoOverviewStore).focusedCargo.autoLoadLocations.length==0,accent:`text`,onClick:_cache[4]||=$event=>unref(cargoOverviewStore).loadCargoCustom(unref(cargoOverviewStore).focusedCargo)},{default:withCtx(()=>[..._cache[16]||=[createTextVNode(` Custom Load `,-1)]]),_:1},8,[`disabled`]),createVNode(unref(bngButton_default),{disabled:!unref(cargoOverviewStore).focusedCargo.enabled||unref(cargoOverviewStore).focusedCargo.autoLoadLocations&&unref(cargoOverviewStore).focusedCargo.autoLoadLocations.length<=unref(cargoOverviewStore).focusedCargo.transientMoveCounts,onClick:_cache[5]||=$event=>unref(cargoOverviewStore).loadCargoAuto(unref(cargoOverviewStore).focusedCargo)},{default:withCtx(()=>[..._cache[17]||=[createTextVNode(` Auto Load `,-1)]]),_:1},8,[`disabled`])],64)):createCommentVNode(``,!0),unref(cargoOverviewStore).focusedCargo.isPlayerCard?(openBlock(),createElementBlock(Fragment,{key:1},[createVNode(unref(bngButton_default),{accent:`text`,disabled:unref(cargoOverviewStore).focusedCargo.transientCargo,onClick:_cache[6]||=$event=>unref(cargoOverviewStore).changeDistribution(unref(cargoOverviewStore).focusedCargo)},{default:withCtx(()=>[..._cache[18]||=[createTextVNode(` Change Distribution `,-1)]]),_:1},8,[`disabled`]),createVNode(unref(bngButton_default),{disabled:unref(cargoOverviewStore).focusedCargo.transientCargo,onClick:_cache[7]||=$event=>unref(cargoOverviewStore).clearLoad(unref(cargoOverviewStore).focusedCargo)},{default:withCtx(()=>[..._cache[19]||=[createTextVNode(` Clear Load `,-1)]]),_:1},8,[`disabled`])],64)):createCommentVNode(``,!0)],64)):createCommentVNode(``,!0),unref(cargoOverviewStore).focusedCargo.cardType==`storage`?(openBlock(),createElementBlock(Fragment,{key:1},[unref(cargoOverviewStore).focusedCargo.isFacilityCard?(openBlock(),createBlock(unref(bngButton_default),{key:0,disabled:!unref(cargoOverviewStore).focusedCargo.enabled,onClick:_cache[8]||=$event=>unref(cargoOverviewStore).loadStorageCustom(unref(cargoOverviewStore).focusedCargo)},{default:withCtx(()=>[..._cache[20]||=[createTextVNode(` Load Custom `,-1)]]),_:1},8,[`disabled`])):createCommentVNode(``,!0)],64)):createCommentVNode(``,!0),unref(cargoOverviewStore).focusedCargo.cardType==`vehicleOffer`?(openBlock(),createBlock(unref(bngButton_default),{key:2,disabled:!unref(cargoOverviewStore).focusedCargo.enabled,onClick:_cache[9]||=$event=>unref(cargoOverviewStore).loadOffer(unref(cargoOverviewStore).focusedCargo)},{default:withCtx(()=>[createTextVNode(toDisplayString(unref(cargoOverviewStore).focusedCargo.spawnWhenCommitingCargo?`Don't bring out`:`Bring Out`),1)]),_:1},8,[`disabled`])):createCommentVNode(``,!0)]),key:`0`}:void 0]),1024),createVNode(unref(bngCard_default),{class:`map`},{default:withCtx(()=>[..._cache[21]||=[createTextVNode(` Map Screen `,-1)]]),_:1})])])]),_:1})):createCommentVNode(``,!0)],64))}},MyCargo_default=__plugin_vue_export_helper_default(_sfc_main$243,[[`__scopeId`,`data-v-9a756c16`]]),_hoisted_1$213={class:`paint-presets`},_hoisted_2$172={class:`paint-presets-group`},_hoisted_3$151={class:`paint-presets-name`},_hoisted_4$126={class:`presets-items`},_sfc_main$242={__name:`PaintPresets`,props:{presets:{type:Object,required:!0},showText:{type:Boolean,default:!1},editable:{type:Boolean,default:!1},current:{type:Object}},emits:[`apply`],setup(__props,{emit:__emit}){let settings$1=useSettings(),props=__props,emit$1=__emit,factoryPresets=computed(()=>{let presets=props.presets,factoryRes={},customRes={};if(typeof presets==`object`&&!Array.isArray(presets)){let paint=new Paint;for(let name in presets)try{paint.paint=presets[name];let paintObject=paint.paintObject;presets[name]&&typeof presets[name]==`object`&&presets[name].class===`custom`?customRes[name]=paintObject:factoryRes[name]=paintObject}catch{}}return{factory:factoryRes,custom:customRes}}),userPresets=ref({}),presetGroups=computed(()=>{let res=[];Object.keys(factoryPresets.value.factory).length&&res.push({name:`factory`,showTooltip:!0,editable:!1,presets:factoryPresets.value.factory}),Object.keys(factoryPresets.value.custom).length&&res.push({name:`custom`,showTooltip:!0,editable:!1,presets:factoryPresets.value.custom}),props.editable&&res.push({name:`user`,showTooltip:!1,editable:!0,presets:userPresets.value||{}});for(let group of res){let presets=Object.keys(group.presets).map(colname=>({name:colname,...group.presets[colname],css:`rgb(${group.presets[colname].baseColor.slice(0,3).map(val=>val*255)})`}));group.name!==`user`&&(presets=sortColors(presets)),group.presets=presets}return res});function average(arr){return arr.reduce((a$1,b)=>a$1+b)/arr.length}function valComparable(col,thres=.05){let bool=!0,av=average(col);for(let i=0;i=col[i];return bool&&=av>.8||av<.2,bool}function colorHigherHelper(itm){let av=average(itm.orig.baseColor.slice(0,3)),al=itm.orig.baseColor[3]/2,res=Math.abs(av-1)*al;return res===0?(av+al)/2:res+1}function colorHigher(a$1,b){let aColor=valComparable(a$1.orig.baseColor.slice(0,3)),bColor=valComparable(b.orig.baseColor.slice(0,3));if(aColor&&bColor)return colorHigherHelper(b)-colorHigherHelper(a$1);if(aColor&&!bColor)return 1;if(!aColor&&bColor)return-1;for(let i=0;i<3;i++)if(a$1.val[i]!==b.val[i])return a$1.val[i]-b.val[i];return 0}function colorValue(arr){let repitions=8,rgb=[];for(let i=0;i<3;i++)rgb[i]=(1-arr[3]/2)*arr[i]+arr[3]/2*arr[i];let lum=Math.sqrt(.241*rgb[0]+.691*rgb[1]+.068*rgb[2]),hsl=Paint.rgbToHsl(rgb),out=[hsl[0],lum,hsl[1]].map(elem=>elem*8);return out[0]%2==1&&(out[1]=8-out[1],out[2]=8-out[2]),out.push(arr[3]),out}function sortColors(list){return list.map(elem=>({val:colorValue(elem.baseColor),orig:elem})).sort(colorHigher).map(elem=>elem.orig)}function addPreset(){if(!props.current)return;let colour={...props.current,baseColor:toRaw(props.current.baseColor)},idx=1;for(;`Custom ${idx}`in userPresets.value;)idx++;let presetName=`Custom ${idx}`;userPresets.value[presetName]=colour,savePresets(),nextTick(()=>{let presetElements=document.querySelectorAll(`.paint-presets-item`),newPreset=Array.from(presetElements).find(el=>el.getAttribute(`data-preset-name`)===presetName);newPreset&&setFocusExternal(newPreset)})}function removePreset(name){let presetElements=document.querySelectorAll(`.paint-presets-item`),currentIndex=Array.from(presetElements).findIndex(el=>el.getAttribute(`data-preset-name`)===name);delete userPresets.value[name],savePresets(),nextTick(()=>{let group=presetGroups.value.find(g=>g.name===`user`);if(group)if(group.presets.length>0){let newPresetElements=document.querySelectorAll(`.paint-presets-item`);setFocusExternal(newPresetElements[Math.min(currentIndex,newPresetElements.length-1)])}else{let addButton=document.querySelector(`.presets-empty`);addButton&&setFocusExternal(addButton)}})}function savePresets(){settings$1.apply({userPaintPresets:JSON.stringify(Object.values(userPresets.value))})}return onMounted(async()=>{await settings$1.waitForData();let paints={};if(settings$1.values.userPaintPresets&&(paints=JSON.parse(settings$1.values.userPaintPresets.replace(/'/g,`"`)),typeof paints==`object`)){Array.isArray(paints)&&(paints=paints.reduce((res,paint,idx)=>({...res,[`Custom ${idx}`]:paint}),{}));let test=new Paint;for(let name in paints)try{test.paint=paints[name],paints[name]=test.paintObject}catch{delete paints[name]}}userPresets.value=paints}),(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$213,[(openBlock(!0),createElementBlock(Fragment,null,renderList(presetGroups.value,group=>(openBlock(),createElementBlock(`div`,_hoisted_2$172,[createBaseVNode(`span`,_hoisted_3$151,toDisplayString(_ctx.$t(`ui.color.${group.name}`))+`: `,1),createBaseVNode(`div`,_hoisted_4$126,[(openBlock(!0),createElementBlock(Fragment,null,renderList(group.presets,(preset,index)=>(openBlock(),createBlock(unref(bngPaintTile_default),{key:`${index}#${preset.name}`,size:24,paint:preset,"vehicle-name":`factory`,"paint-name":preset.name,"tooltip-position":`top`,class:`paint-presets-item`,"data-preset-name":preset.name,"with-menu":__props.editable&&group.editable,"custom-menu":[{label:`ui.common.delete`,action:()=>removePreset(preset.name)}],onClick:$event=>emit$1(`apply`,preset)},null,8,[`paint`,`paint-name`,`data-preset-name`,`with-menu`,`custom-menu`,`onClick`]))),128)),!group.presets||Object.keys(group.presets).length===0?withDirectives((openBlock(),createBlock(unref(bngButton_default),{key:0,class:`presets-empty`,accent:unref(ACCENTS).text,onClick:addPreset,"bng-nav-item":``},{default:withCtx(()=>[createTextVNode(toDisplayString(_ctx.$t(`ui.colorpicker.noPresets`)),1)]),_:1},8,[`accent`])),[[unref(BngOnUiNav_default),void 0,`ok`,{asMouse:!0,focusRequired:!0}]]):createCommentVNode(``,!0),group.presets&&Object.keys(group.presets).length>0&&__props.editable&&group.editable?withDirectives((openBlock(),createBlock(unref(bngButton_default),{key:1,class:`paint-presets-button`,accent:unref(ACCENTS).text,onClick:addPreset,icon:unref(icons).mathPlus,"bng-nav-item":``},null,8,[`accent`,`icon`])),[[unref(BngTooltip_default),_ctx.$t(`ui.colorpicker.colToPre`),`top`],[unref(BngOnUiNav_default),void 0,`ok`,{asMouse:!0,focusRequired:!0}]]):createCommentVNode(``,!0)])]))),256))]))}},PaintPresets_default=__plugin_vue_export_helper_default(_sfc_main$242,[[`__scopeId`,`data-v-469b2f89`]]),_hoisted_1$212={class:`paint-picker`},_hoisted_2$171={key:0,class:`paint-flex`},_hoisted_3$150={key:0,class:`paint-preview`,xmlns:`http://www.w3.org/2000/svg`,viewBox:`0 0 1 1`,preserveAspectRatio:`xMidYMid meet`},_hoisted_4$125={id:`light`,cy:`0.28`,cx:`0.35`,r:`0.3`,spreadMethod:`pad`},_hoisted_5$110=[`offset`],_hoisted_6$93=[`offset`],_hoisted_7$81={id:`colPreview`,x:`0`,y:`0`,width:`1`,height:`1`,patternUnits:`userSpaceOnUse`},_hoisted_8$67=[`fill`],_hoisted_9$60={key:1},_hoisted_10$51={key:0},_hoisted_11$45={key:2},_hoisted_12$34={key:0},_sfc_main$241={__name:`PaintPicker`,props:{modelValue:{type:[String,Object]},legacy:{type:Boolean,default:!1},presets:{type:Object,default:{}},presetsEditable:{type:Boolean,default:!1},showPresets:{type:Boolean,default:!0},showMain:{type:Boolean,default:!0},pickerMode:{type:String,default:`full_luminosity`},showText:{type:Boolean,default:!0},showPreview:{type:Boolean,default:!1},advancedOpen:{type:Boolean,default:!1},showAdvancedSwitch:{type:Boolean,default:!0}},emits:[`update:modelValue`,`change`],setup(__props,{expose:__expose,emit:__emit}){let props=__props;__expose({paintUpdated,setAdvancedVisible}),watch(()=>props.modelValue,init$3);let emitter=__emit,advanced=ref(props.advancedOpen),paint=reactive(new Paint({legacy:props.legacy}));watch(()=>props.legacy,val=>paint.legacy=val);let paintPicker=ref(paint),isPaintObject=!1,factoryPresets=computed(()=>props.presets||{}),hslColour=computed(()=>Paint.hslCssStr(paint.hsl));function init$3(){let defPaint=[1,1,1,1,0,1,1,0];if(!props.modelValue){paint.paint=defPaint;return}if(isPaintObject=props.modelValue instanceof Paint,isPaintObject){paint.paint=props.modelValue.paintObject;return}let newpaint=new Paint({legacy:props.legacy});try{newpaint.paint=props.modelValue}catch{newpaint.paint=defPaint}newpaint.paintString!==paint.paintString&&(paint.paint=newpaint.paintObject)}function returnPaint(){let res;isPaintObject?(res=props.modelValue,res.paint=paint.paintObject):res=paint.paintString,emitter(`change`,res),emitter(`update:modelValue`,res)}function paintUpdated(){init$3(),returnPaint()}function setAdvancedVisible(visible){advanced.value=visible}function applyPreset(preset){paint.paint=preset,returnPaint()}return init$3(),(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$212,[__props.showPreview||__props.showPresets?(openBlock(),createElementBlock(`div`,_hoisted_2$171,[__props.showPreview?(openBlock(),createElementBlock(`svg`,_hoisted_3$150,[createBaseVNode(`defs`,null,[createBaseVNode(`radialGradient`,_hoisted_4$125,[createBaseVNode(`stop`,mergeProps({offset:.1+.2*(1-paint.roughness)},{"stop-opacity":.4+.2*paint.roughness},{"stop-color":`#fff`}),null,16,_hoisted_5$110),createBaseVNode(`stop`,{offset:1-paint.roughness*.5,"stop-opacity":`0.0`,"stop-color":`#fff`},null,8,_hoisted_6$93)]),_cache[16]||=createBaseVNode(`radialGradient`,{id:`shadow`,cy:`0.43`,cx:`0.45`,r:`0.55`,spreadMethod:`pad`},[createBaseVNode(`stop`,{offset:`0.7`,"stop-opacity":`0.0`,"stop-color":`#000`}),createBaseVNode(`stop`,{offset:`0.85`,"stop-opacity":`0.2`,"stop-color":`#000`}),createBaseVNode(`stop`,{offset:`1.0`,"stop-opacity":`0.5`,"stop-color":`#000`})],-1),createBaseVNode(`pattern`,_hoisted_7$81,[_cache[13]||=createBaseVNode(`image`,{x:`0`,y:`0`,height:`1`,width:`1`,"xlink:href":`/ui/lib/int/colorpicker/color-chrome.png`},null,-1),createBaseVNode(`rect`,mergeProps({y:`0`,x:`0`,width:`1`,height:`1`,fill:`hsl(${hslColour.value})`},{"fill-opacity":paint.alpha/2},{stroke:`transparent`}),null,16,_hoisted_8$67),_cache[14]||=createBaseVNode(`rect`,{y:`0`,x:`0`,width:`1`,height:`1`,fill:`url(#light)`,stroke:`transparent`},null,-1),_cache[15]||=createBaseVNode(`rect`,{y:`0`,x:`0`,width:`1`,height:`1`,fill:`url(#shadow)`,stroke:`transparent`},null,-1)])]),_cache[17]||=createBaseVNode(`circle`,{cy:`0.5`,cx:`0.5`,r:`0.5`,fill:`url(#colPreview)`,stroke:`transparent`},null,-1)])):createCommentVNode(``,!0),__props.showPresets?(openBlock(),createBlock(PaintPresets_default,{key:1,presets:factoryPresets.value,"show-text":__props.showText,editable:__props.presetsEditable,current:paint.paintObject,onApply:applyPreset},null,8,[`presets`,`show-text`,`editable`,`current`])):createCommentVNode(``,!0)])):createCommentVNode(``,!0),__props.showMain?(openBlock(),createElementBlock(`div`,_hoisted_9$60,[__props.showText&&_ctx.$slots.default?(openBlock(),createElementBlock(`span`,_hoisted_10$51,[renderSlot(_ctx.$slots,`default`,{},void 0,!0)])):createCommentVNode(``,!0),createVNode(unref(bngColorPicker_default),{modelValue:paintPicker.value,"onUpdate:modelValue":_cache[0]||=$event=>paintPicker.value=$event,onChange:_cache[1]||=$event=>returnPaint(),view:__props.pickerMode,"show-text":__props.showText},null,8,[`modelValue`,`view`,`show-text`])])):createCommentVNode(``,!0),__props.showMain?(openBlock(),createElementBlock(`div`,_hoisted_11$45,[__props.showAdvancedSwitch?(openBlock(),createElementBlock(`h3`,_hoisted_12$34,[createVNode(unref(bngSwitch_default),{modelValue:advanced.value,"onUpdate:modelValue":_cache[2]||=$event=>advanced.value=$event},{default:withCtx(()=>[createTextVNode(toDisplayString(_ctx.$t(`ui.color.configurations`)),1)]),_:1},8,[`modelValue`])])):createCommentVNode(``,!0),advanced.value?(openBlock(),createElementBlock(`div`,{key:1,class:normalizeClass([`paint-slider-group`,{"paint-slider-group-fullrow":_ctx.$simplemenu.value}])},[__props.legacy?(openBlock(),createBlock(unref(bngColorSlider_default),{key:0,modelValue:paint.alpha,"onUpdate:modelValue":_cache[3]||=$event=>paint.alpha=$event,max:2,onChange:_cache[4]||=$event=>returnPaint(),fill:[`hsla(${hslColour.value}, 0)`,`hsla(${hslColour.value}, 2)`]},{default:withCtx(()=>[createTextVNode(toDisplayString(__props.showText?`${_ctx.$t(`ui.color.chrominess`)} (${paint.alphaPercent}%)`:null),1)]),_:1},8,[`modelValue`,`fill`])):createCommentVNode(``,!0),createVNode(unref(bngColorSlider_default),{modelValue:paint.metallic,"onUpdate:modelValue":_cache[5]||=$event=>paint.metallic=$event,onChange:_cache[6]||=$event=>returnPaint()},{default:withCtx(()=>[createTextVNode(toDisplayString(__props.showText?`${_ctx.$t(`ui.color.metallic`)} (${paint.metallicPercent}%)`:null),1)]),_:1},8,[`modelValue`]),createVNode(unref(bngColorSlider_default),{modelValue:paint.roughness,"onUpdate:modelValue":_cache[7]||=$event=>paint.roughness=$event,onChange:_cache[8]||=$event=>returnPaint()},{default:withCtx(()=>[createTextVNode(toDisplayString(__props.showText?`${_ctx.$t(`ui.color.roughness`)} (${paint.roughnessPercent}%)`:null),1)]),_:1},8,[`modelValue`]),createVNode(unref(bngColorSlider_default),{modelValue:paint.clearcoat,"onUpdate:modelValue":_cache[9]||=$event=>paint.clearcoat=$event,onChange:_cache[10]||=$event=>returnPaint()},{default:withCtx(()=>[createTextVNode(toDisplayString(__props.showText?`${_ctx.$t(`ui.color.clearCoat`)} (${paint.clearcoatPercent}%)`:null),1)]),_:1},8,[`modelValue`]),createVNode(unref(bngColorSlider_default),{modelValue:paint.clearcoatRoughness,"onUpdate:modelValue":_cache[11]||=$event=>paint.clearcoatRoughness=$event,onChange:_cache[12]||=$event=>returnPaint()},{default:withCtx(()=>[createTextVNode(toDisplayString(__props.showText?`${_ctx.$t(`ui.color.clearCoatRoughness`)} (${paint.clearcoatRoughnessPercent}%)`:null),1)]),_:1},8,[`modelValue`])],2)):createCommentVNode(``,!0)])):createCommentVNode(``,!0)]))}},PaintPicker_default=__plugin_vue_export_helper_default(_sfc_main$241,[[`__scopeId`,`data-v-2d18c0ad`]]),_hoisted_1$211={class:`paintingWrapper`},_hoisted_2$170={style:{overflow:`auto`}},_hoisted_3$149=[`tab-heading`],_hoisted_4$124={class:`paintPicker`},_hoisted_5$109={key:0,class:`clearCoatSection`},_hoisted_6$92={key:0,class:`innerShoppingCart`},_hoisted_7$80={class:`shoppingCartTable`},_hoisted_8$66={class:`price`},_hoisted_9$59={class:`price--total`},_hoisted_10$50={class:`purchase-button-container`},_sfc_main$240={__name:`Painting`,props:{noHeader:Boolean},setup(__props,{expose:__expose}){let{units,events:events$3}=useBridge(),presets=ref({});Lua_default.career_modules_painting.getFactoryPaint().then(data=>presets.value=data);let colorClass=ref(`factory`),paintIndex=ref(0),chosenPackage=ref([{},{},{}]),changedPaint=ref(!1),totalPrice=ref(0),clearCoatActive=ref(!1),clearCoatPolish=ref(0),paints=ref([]),originalPaints=ref([]),prices=ref({}),colorClassData=ref({}),canPay=ref(!1),paintPicker=ref(null),paintClassTabInfo=[{title:`Factory`},{title:`Gloss`,paintClasses:[{id:`matte`,title:`Matte`},{id:`semiGloss`,title:`Semi Gloss`},{id:`gloss`,title:`Full Gloss`}]},{title:`Metallic`,paintClasses:[{id:`semiMetallic`,title:`Semi Metallic`},{id:`metallic`,title:`Metallic`},{id:`chrome`,title:`Chrome`}]},{title:`Custom`}],clearCoatUpdateCallback=newValue=>{clearCoatPolish.value=0,changeClearCoatPolish(0),enableClearCoat(newValue)},enableClearCoat=enabled=>{paints.value[paintIndex.value]._clearcoat=enabled?1:0,paintPicker.value.paintUpdated()},changeClearCoatPolish=value=>{paints.value[paintIndex.value]._clearcoatRoughness=-.13*value+.13,paintPicker.value.paintUpdated()},getShoppingCartTable=()=>{let res=[];for(let[index,paintOptions]of chosenPackage.value.entries())Object.keys(paintOptions).length&&(res.push({name:`Paint `+(index+1)+`: `+getNicePaintClassName(paintOptions.paintClass),price:prices.value.basePrices[paintOptions.paintClass].money.amount,topLevel:!0,index}),paintOptions.clearCoat&&(res.push({name:`Clearcoat`,price:prices.value.clearcoatBase.money.amount}),res.push({name:`Extra Clearcoat Polish`,price:prices.value.clearcoatPolishFactor.money.amount*paintOptions.clearCoatPolish})));return res};events$3.on(`sendPaintingShoppingCartData`,data=>{canPay.value=data.canPay,totalPrice.value=data.totalPrice.money.amount}),Lua_default.career_modules_painting.getPaintData().then(data=>{if(prices.value=data.prices,!data||!Array.isArray(data.colors)){paints.value=[];return}paints.value=data.colors.map(val=>new Paint({paint:val})),originalPaints.value=data.colors.map(val=>new Paint({paint:val})),colorClassData.value=data.colorClassData});let getPickerShowPresets=()=>colorClass.value==`factory`,getPickerPresetsEditable=()=>colorClass.value==`custom`,showPickerMain=()=>colorClass.value!=`factory`,showClearCoatOption=()=>colorClass.value!=`factory`&&colorClass.value!=`custom`,setCurrentColorClass=()=>{paintPicker.value.setAdvancedVisible(!1),paints.value[paintIndex.value]._metallic=colorClassData.value[colorClass.value].metallic,paints.value[paintIndex.value]._roughness=colorClassData.value[colorClass.value].roughness,clearCoatActive.value=!1,enableClearCoat(!1)},changedPaintIndexTab=tab=>{paintIndex.value=tab.index,colorClass.value=chosenPackage.value[paintIndex.value].paintClass||`factory`,paintPicker.value.setAdvancedVisible(colorClass.value==`custom`),clearCoatActive.value=chosenPackage.value[paintIndex.value].clearCoat,clearCoatPolish.value=chosenPackage.value[paintIndex.value].clearCoatPolish},changedTopLevelPaintClassTab=tab=>{let classTab={Factory:`factory`,Custom:`custom`,Gloss:`semiGloss`,Metallic:`metallic`}[tab.heading];classTab&&changedPaintClassTab(classTab)},changedPaintClassTab=paintClass=>{if(paintClass==`factory`){colorClass.value=`factory`;return}if(paintClass==`custom`){colorClass.value=`custom`,paintPicker.value.setAdvancedVisible(!0),clearCoatActive.value=!1;return}colorClass.value=paintClass,setCurrentColorClass()};function resetPaint(index){chosenPackage.value[index]={},Object.assign(paints.value[index],originalPaints.value[index]);let chosenPackageEmpty=!0;for(let[index$1,color]of Object.entries(chosenPackage.value))Object.keys(color).length!==0&&(chosenPackageEmpty=!1);chosenPackageEmpty&&(changedPaint.value=!1),Lua_default.career_modules_painting.setPaints(paints.value.map(paint=>paint.paintObject),chosenPackage.value)}function onChange(){colorClass.value==`factory`&&(clearCoatActive.value=!1),chosenPackage.value[paintIndex.value].paintClass=colorClass.value,chosenPackage.value[paintIndex.value].clearCoat=clearCoatActive.value,chosenPackage.value[paintIndex.value].clearCoatPolish=clearCoatPolish.value,changedPaint.value=!0,Lua_default.career_modules_painting.setPaints(paints.value.map(paint=>paint.paintObject),chosenPackage.value)}let NICE_PAINT_CLASS_NAMES={factory:`Factory`,semiGloss:`Semi Gloss`,gloss:`Gloss`,semiMetallic:`Semi Metallic`,metallic:`Metallic`,matte:`Matte`,chrome:`Chrome`,custom:`Custom`},getNicePaintClassName=paintClass=>NICE_PAINT_CLASS_NAMES[paintClass];function headerClass(tab){return{"painting-tab":!0,[`painting-tab-${tab.index}`]:!0}}let headerVars=computed(()=>paints.value.reduce((res,paint,idx)=>({...res,[`--painting-dot-${idx}`]:`hsl(${Paint.hslCssStr(paint.hsl)})`}),{})),apply$1=()=>Lua_default.career_modules_painting.apply(),close=()=>Lua_default.career_modules_painting.close();return onMounted(()=>{Lua_default.career_modules_painting.onUIOpened()}),onUnmounted(close),__expose({apply:apply$1,close}),(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$211,[withDirectives((openBlock(),createBlock(unref(bngCard_default),{class:`paintingPage`},{default:withCtx(()=>[createBaseVNode(`div`,_hoisted_2$170,[__props.noHeader?createCommentVNode(``,!0):(openBlock(),createBlock(unref(bngCardHeading_default),{key:0},{default:withCtx(()=>[..._cache[3]||=[createTextVNode(` Painting `,-1)]]),_:1})),createVNode(unref(tabs_default),{class:`bng-tabs`,"selected-index":0,"make-tab-header-classes":headerClass,style:normalizeStyle(headerVars.value),onChange:changedPaintIndexTab},{default:withCtx(()=>[(openBlock(!0),createElementBlock(Fragment,null,renderList(paints.value,(paint,idx)=>(openBlock(),createBlock(unref(tabs_default),{key:idx,"tab-heading":_ctx.$t(`ui.trackBuilder.matEditor.paint`)+` `+(idx+1),class:`bng-tabs`,"selected-index":0,onChange:changedTopLevelPaintClassTab},{default:withCtx(()=>[(openBlock(),createElementBlock(Fragment,null,renderList(paintClassTabInfo,(paintClassTab,idx$1)=>createBaseVNode(`div`,{key:idx$1,"tab-heading":paintClassTab.title,style:{margin:`0.3em`,"background-color":`#00000000`}},[(openBlock(!0),createElementBlock(Fragment,null,renderList(paintClassTab.paintClasses,(paintClass,idx$2)=>(openBlock(),createBlock(unref(bngButton_default),{key:idx$2,onClick:$event=>changedPaintClassTab(paintClass.id),accent:colorClass.value==paintClass.id?void 0:unref(ACCENTS).secondary,class:`paint-class-button`},{default:withCtx(()=>[createTextVNode(toDisplayString(paintClass.title),1)]),_:2},1032,[`onClick`,`accent`]))),128))],8,_hoisted_3$149)),64))]),_:2},1032,[`tab-heading`]))),128))]),_:1},8,[`style`]),createVNode(unref(bngCard_default),null,{default:withCtx(()=>[createBaseVNode(`div`,_hoisted_4$124,[createVNode(PaintPicker_default,{ref_key:`paintPicker`,ref:paintPicker,modelValue:paints.value[paintIndex.value],"onUpdate:modelValue":_cache[0]||=$event=>paints.value[paintIndex.value]=$event,"show-main":showPickerMain(),presets:getPickerShowPresets()?presets.value:void 0,"presets-editable":getPickerPresetsEditable(),"advanced-open":!1,"show-advanced-switch":!1,onChange},null,8,[`modelValue`,`show-main`,`presets`,`presets-editable`]),showClearCoatOption()?(openBlock(),createElementBlock(`div`,_hoisted_5$109,[createVNode(unref(bngSwitch_default),{modelValue:clearCoatActive.value,"onUpdate:modelValue":_cache[1]||=$event=>clearCoatActive.value=$event,onValueChanged:clearCoatUpdateCallback},{default:withCtx(()=>[createTextVNode(` Add Clear Coat (Baseprice: `+toDisplayString(unref(units).beamBucks(prices.value.clearcoatBase.money.amount))+`) `,1)]),_:1},8,[`modelValue`]),clearCoatActive.value?(openBlock(),createBlock(unref(bngColorSlider_default),{key:0,style:{"margin-top":`0.7em`},modelValue:clearCoatPolish.value,"onUpdate:modelValue":_cache[2]||=$event=>clearCoatPolish.value=$event,onChange:changeClearCoatPolish},{default:withCtx(()=>[..._cache[4]||=[createTextVNode(` Clear Coat Polish `,-1)]]),_:1},8,[`modelValue`])):createCommentVNode(``,!0)])):createCommentVNode(``,!0)])]),_:1})])]),_:1})),[[unref(BngBlur_default),1]]),createVNode(unref(bngCard_default),{class:`shoppingCart`},{default:withCtx(()=>[createVNode(unref(bngCardHeading_default),null,{default:withCtx(()=>[..._cache[5]||=[createTextVNode(`Shopping Cart`,-1)]]),_:1}),changedPaint.value?(openBlock(),createElementBlock(`div`,_hoisted_6$92,[createBaseVNode(`table`,_hoisted_7$80,[_cache[9]||=createBaseVNode(`thead`,null,[createBaseVNode(`tr`,null,[createBaseVNode(`th`),createBaseVNode(`th`,{class:`article`},`Option`),createBaseVNode(`th`,{class:`price`},`Price`)])],-1),createBaseVNode(`tbody`,null,[(openBlock(!0),createElementBlock(Fragment,null,renderList(getShoppingCartTable(),(date,idx)=>(openBlock(),createElementBlock(`tr`,null,[createBaseVNode(`th`,null,[date.topLevel?(openBlock(),createBlock(unref(bngButton_default),{key:0,onClick:$event=>resetPaint(date.index)},{default:withCtx(()=>[..._cache[6]||=[createTextVNode(`remove`,-1)]]),_:1},8,[`onClick`])):createCommentVNode(``,!0)]),createBaseVNode(`th`,{class:normalizeClass(date.topLevel?`article`:`article--subLevel`)},toDisplayString(date.name),3),createBaseVNode(`th`,_hoisted_8$66,toDisplayString(unref(units).beamBucks(date.price)),1)]))),256)),createBaseVNode(`tr`,null,[_cache[7]||=createBaseVNode(`th`,null,null,-1),_cache[8]||=createBaseVNode(`th`,{class:`article--total`},`Total`,-1),createBaseVNode(`th`,_hoisted_9$59,toDisplayString(unref(units).beamBucks(totalPrice.value)),1)])])])])):createCommentVNode(``,!0),createBaseVNode(`div`,_hoisted_10$50,[withDirectives((openBlock(),createBlock(unref(bngButton_default),{class:`purchase-button`,disabled:!canPay.value||!changedPaint.value,"show-hold":``},{default:withCtx(()=>[..._cache[10]||=[createTextVNode(` Purchase and Apply `,-1)]]),_:1},8,[`disabled`])),[[unref(BngOnUiNav_default),void 0,`ok`,{asMouse:!0,focusRequired:!0}],[unref(BngClick_default),{holdCallback:()=>apply$1(),holdDelay:1e3,repeatInterval:0}]])])]),_:1})]))}},Painting_default=__plugin_vue_export_helper_default(_sfc_main$240,[[`__scopeId`,`data-v-9dc00fbe`]]),_sfc_main$239={__name:`PaintingMain`,setup(__props){useComputerStore();let elPainting=ref(),close=()=>elPainting.value.close();return(_ctx,_cache)=>(openBlock(),createBlock(ComputerWrapper_default,{path:[`Painting`],title:`Painting`,back:``,onBack:close},{default:withCtx(()=>[createVNode(Painting_default,{ref_key:`elPainting`,ref:elPainting,"no-header":``},null,512)]),_:1}))}},PaintingMain_default=_sfc_main$239;const usePartInventoryStore=defineStore(`partInventory`,()=>{let{events:events$3}=useBridge(),partInventoryData=ref({}),newPartsPopupOpen=ref(!1),newParts=ref([]),searchString=ref(``);function requestInitialData(){Lua_default.career_modules_partInventory.sendUIData()}function closeNewPartsPopup(){newPartsPopupOpen.value=!1}function closeMenu(){searchString.value=``,Lua_default.career_modules_partInventory.closeMenu()}function partInventoryClosed(){Lua_default.career_modules_partInventory.partInventoryClosed()}function dispose$2(){events$3.off(`partInventoryData`)}function openNewPartsPopup(newPartIds){newPartsPopupOpen.value=!0,newParts.value=[];for(let i=0;ipart.description.description.toLowerCase().includes(searchString.value.toLowerCase())||part.name.toLowerCase().includes(searchString.value.toLowerCase()),searchValueChanged=()=>{partInventoryData.value.partList.filter?partInventoryData.value.filteredPartList=partInventoryData.value.partList.filter(doesPartPassFilter):partInventoryData.value.filteredPartList={}};return watch(()=>searchString.value,searchValueChanged),events$3.on(`partInventoryData`,data=>{partInventoryData.value=data,searchValueChanged()}),{closeMenu,closeNewPartsPopup,dispose:dispose$2,newParts,newPartsPopupOpen,openNewPartsPopup,partInventoryClosed,partInventoryData,requestInitialData,searchString}});var _hoisted_1$210={style:{padding:`1em`}},_hoisted_2$169={class:`selectButtons`},_hoisted_3$148={class:`part-info-row`},_hoisted_4$123={class:`partList`},_hoisted_5$108=[`onClick`],_hoisted_6$91={class:`part-info-col`},_hoisted_7$79={class:`part-name`},_hoisted_8$65={class:`part-info-row`},_hoisted_9$58={class:`right`},_hoisted_10$49={class:`right`},_hoisted_11$44={class:`center`},_hoisted_12$33={class:`popup-buttons`},_sfc_main$238={__name:`PartSellingPopup`,props:{parts:{type:Array,default:[]}},emits:[`return`],setup(__props,{emit:__emit}){useUINavScope(`partSelling`);let{units}=useBridge(),partsChecked=ref([]),emit$1=__emit,props=__props,saleData=computed(()=>{let total=0,numberOfSelected=0;for(let[index,isChecked]of Object.entries(partsChecked.value))if(isChecked){let part=props.parts[index];total+=part.data.finalValue,numberOfSelected+=1}return{price:total,numberOfSelected}}),buildRefList=()=>{for(let i=0;i{for(let i=0;i{let partIds=[];for(let[index,isChecked]of Object.entries(partsChecked.value))if(isChecked){let part=props.parts[index];partIds.push(part.data.id)}Lua_default.career_modules_partInventory.sellParts(partIds),close()},close=()=>{emit$1(`return`,!0)};return onMounted(buildRefList),(_ctx,_cache)=>withDirectives((openBlock(),createBlock(unref(bngCard_default),{"bng-ui-scope":`partSelling`,class:`sellingCard`},{default:withCtx(()=>[createVNode(unref(bngCardHeading_default),null,{default:withCtx(()=>[..._cache[2]||=[createTextVNode(`Sell Parts`,-1)]]),_:1}),createBaseVNode(`div`,_hoisted_1$210,[createBaseVNode(`div`,_hoisted_2$169,[_cache[5]||=createTextVNode(` Select: `,-1),createBaseVNode(`div`,_hoisted_3$148,[createVNode(unref(bngButton_default),{accent:unref(ACCENTS).secondary,onClick:_cache[0]||=$event=>selectAll(!0)},{default:withCtx(()=>[..._cache[3]||=[createTextVNode(` All `,-1)]]),_:1},8,[`accent`]),createVNode(unref(bngButton_default),{accent:unref(ACCENTS).secondary,onClick:_cache[1]||=$event=>selectAll(!1)},{default:withCtx(()=>[..._cache[4]||=[createTextVNode(` None `,-1)]]),_:1},8,[`accent`])])]),createBaseVNode(`div`,_hoisted_4$123,[(openBlock(!0),createElementBlock(Fragment,null,renderList(__props.parts,(part,index)=>(openBlock(),createElementBlock(`div`,{class:normalizeClass([`part-item`,partsChecked.value[index]?`partSelected`:``]),"bng-nav-item":``,onClick:$event=>partsChecked.value[index]=!partsChecked.value[index]},[createVNode(unref(bngIcon_default),{class:`selectionCheckbox`,type:partsChecked.value[index]?unref(icons).checkboxOn:unref(icons).checkboxOff},null,8,[`type`]),createBaseVNode(`div`,_hoisted_6$91,[createBaseVNode(`div`,null,[createBaseVNode(`span`,_hoisted_7$79,toDisplayString(part.name),1)]),createBaseVNode(`div`,_hoisted_8$65,[createBaseVNode(`span`,_hoisted_9$58,toDisplayString(part.mileage),1),createBaseVNode(`span`,_hoisted_10$49,[createVNode(unref(bngPropVal_default),{iconType:unref(icons).beamCurrency,valueLabel:part.valueFormatted},null,8,[`iconType`,`valueLabel`])]),createBaseVNode(`span`,_hoisted_11$44,toDisplayString(part.model),1)])])],10,_hoisted_5$108))),256))]),createBaseVNode(`div`,_hoisted_12$33,[withDirectives((openBlock(),createBlock(unref(bngButton_default),{disabled:saleData.value.numberOfSelected<=0,"show-hold":``},{default:withCtx(()=>[createTextVNode(` Sell `+toDisplayString(saleData.value.numberOfSelected)+` parts for `,1),createVNode(unref(bngUnit_default),{money:saleData.value.price},null,8,[`money`])]),_:1},8,[`disabled`])),[[unref(BngClick_default),{holdCallback:sellSelectedParts,holdDelay:1e3,repeatInterval:0}]]),createVNode(unref(bngButton_default),{accent:unref(ACCENTS).attention,onClick:close},{default:withCtx(()=>[..._cache[6]||=[createTextVNode(` Cancel `,-1)]]),_:1},8,[`accent`])])])]),_:1})),[[unref(BngOnUiNav_default),close,`back,menu`]])}},PartSellingPopup_default=__plugin_vue_export_helper_default(_sfc_main$238,[[`__scopeId`,`data-v-c325ab7a`]]),_hoisted_1$209={style:{height:`100%`,color:`white`}},_hoisted_2$168={key:0},_hoisted_3$147={class:`veh-part-caption`},_hoisted_4$122={class:`veh-name`},_hoisted_5$107={class:`veh-name-count`},_hoisted_6$90={class:`part-item`,"bng-ui-scope":`veh-part-inv`},_hoisted_7$78={key:0,class:`part-info-col`},_hoisted_8$64={class:`part-name`},_hoisted_9$57={class:`part-info-row`},_hoisted_10$48={class:`right`},_hoisted_11$43={class:`right`},_hoisted_12$32={key:0,class:`center`},_hoisted_13$28={key:1,class:`center`},_hoisted_14$26={class:`center`},_hoisted_15$25={key:0},_hoisted_16$25={class:`center`},_hoisted_17$20={key:0},immediateLimit=15,_sfc_main$237={__name:`PartList`,emits:[`partSold`],setup(__props,{emit:__emit}){let{units}=useBridge(),emit$1=__emit,partInventoryStore=usePartInventoryStore(),groupBy=ref(`location`),groups=ref([]),accordionItems=ref([]),disableInstallButtons=ref(!1),addExpandedFuncToGroup=group=>{group.onExpanded=state=>{let grp=groups.value.find(g=>g.id===group.id);if(grp.expanded=state,!state){delete grp.ready;let elm=document.querySelector(`[data-groupid="${group.id}"] > .bng-accitem-caption`);elm&&elm.focus();return}`ready`in grp||(grp.ready=!1,setTimeout(()=>{let grp$1=groups.value.find(g=>g.id===group.id);grp$1&&typeof grp$1.ready==`boolean`&&(grp$1.ready=!0)},100))}},openSellPopup=async()=>{await addPopup(PartSellingPopup_default,{parts:groups.value[0].parts}).promise&&emit$1(`partSold`)};watchEffect(()=>{if(disableInstallButtons.value=!1,!partInventoryStore||!Array.isArray(partInventoryStore.partInventoryData.partList)||partInventoryStore.partInventoryData.partList.length===0)return[];let res=[];if(groupBy.value==`location`){let group={id:0,name:` Inventory`,parts:[],expanded:!1,icon:icons.BNGFolder};addExpandedFuncToGroup(group),res.push(group);for(let[vehId,vehicle]of Object.entries(partInventoryStore.partInventoryData.vehicles)){let group$1={id:vehId,name:vehicle.niceName,parts:[],expanded:!1,thumbnail:partInventoryStore.partInventoryData.vehicles[vehId].thumbnail};addExpandedFuncToGroup(group$1),res.push(group$1)}}for(let part of partInventoryStore.partInventoryData.filteredPartList){let item={name:part.missingFile?`Missing File`:part.description.description,model:part.vehicleModel,mileage:units.buildString(`length`,part.partCondition.odometer,0),valueFormatted:units.beamBucks(part.finalValue),location:part.location,locationName:part.location===0?` Inventory`:partInventoryStore.partInventoryData.vehicles[part.location].niceName,functions:{install:!1,uninstall:!1,sell:!1},data:part};!part.missingFile&&part.accessible&&(item.functions.install=part.fitsCurrentVehicle&&part.location!==partInventoryStore.partInventoryData.currentVehicle&&(part.location===0||!partInventoryStore.partInventoryData.brokenVehicleInventoryIds[part.location])&&!partInventoryStore.partInventoryData.brokenVehicleInventoryIds[partInventoryStore.partInventoryData.currentVehicle],item.functions.uninstall=part.location!==0&&!part.isInCoreSlot&&!partInventoryStore.partInventoryData.brokenVehicleInventoryIds[part.location],item.functions.sell=part.location===0);let groupId=item[groupBy.value],group=res.find(g=>g.id==groupId);group||(group={id:groupId,name:item[`${groupBy.value}Name`]||item[groupBy.value],parts:[],expanded:!1},part.location>0?group.thumbnail=partInventoryStore.partInventoryData.vehicles[part.location].thumbnail:group.icon=icons.BNGFolder,addExpandedFuncToGroup(group),res.push(group)),group.parts.push(item)}if(res.length>0){let sorter=(a$1,b)=>a$1.name.localeCompare(b.name);res.sort(sorter);for(let group of res)group.parts.sort(sorter)}for(let group of groups.value)if(group.ready){let grp=res.find(g=>g.name===group.name);grp&&(grp.expanded=!0,grp.ready=!0)}groups.value=res});let confirmSellPart=async partToSell=>{await openConfirmation(partToSell.description.description,`Do you want to sell this part for ${units.beamBucks(partToSell.finalValue)}?`,[{label:$translate.instant(`ui.common.yes`),value:!0,extras:{default:!0}},{label:$translate.instant(`ui.common.no`),value:!1,extras:{accent:ACCENTS.secondary}}])&&sellPart(partToSell)},sellPart=part=>{Lua_default.career_modules_partInventory.sellParts([part.id]),emit$1(`partSold`)};return(_ctx,_cache)=>withDirectives((openBlock(),createElementBlock(`div`,_hoisted_1$209,[createVNode(unref(bngInput_default),{class:`searchField`,"floating-label":`Search`,"leading-icon":unref(icons).search,modelValue:unref(partInventoryStore).searchString,"onUpdate:modelValue":_cache[0]||=$event=>unref(partInventoryStore).searchString=$event,modelModifiers:{trim:!0}},null,8,[`leading-icon`,`modelValue`]),withDirectives((openBlock(),createBlock(unref(bngCard_default),{style:{"max-height":`90%`}},{default:withCtx(()=>[unref(partInventoryStore)?(openBlock(),createBlock(unref(accordion_default),{key:1,class:`part-groups`,singular:``},{default:withCtx(()=>[(openBlock(!0),createElementBlock(Fragment,null,renderList(groups.value,(group,index)=>(openBlock(),createBlock(unref(accordionItem_default),{key:group.id,"data-groupid":group.id,ref_for:!0,ref_key:`accordionItems`,ref:accordionItems,navigable:``,onExpanded:group.onExpanded,onSelected:$event=>accordionItems.value[index]?accordionItems.value[index].captionClick():void 0},{caption:withCtx(()=>[createBaseVNode(`div`,_hoisted_3$147,[group.icon?(openBlock(),createBlock(unref(bngIcon_default),{key:0,class:`veh-icon`,type:group.icon},null,8,[`type`])):createCommentVNode(``,!0),group.thumbnail?(openBlock(),createElementBlock(`div`,{key:1,class:`veh-preview`,style:normalizeStyle({backgroundImage:`url('${group.thumbnail}')`})},null,4)):createCommentVNode(``,!0),createBaseVNode(`span`,_hoisted_4$122,[createTextVNode(toDisplayString(group.name)+` `,1),createBaseVNode(`span`,_hoisted_5$107,`(`+toDisplayString(group.parts.length)+`)`,1)])])]),default:withCtx(()=>[group.name==` Inventory`?(openBlock(),createBlock(unref(bngButton_default),{key:0,accent:unref(ACCENTS).outlined,onClick:_cache[1]||=$event=>openSellPopup()},{default:withCtx(()=>[..._cache[2]||=[createTextVNode(` Sell Parts `,-1)]]),_:1},8,[`accent`])):createCommentVNode(``,!0),(openBlock(!0),createElementBlock(Fragment,null,renderList(group.parts,(part,index$1)=>withDirectives((openBlock(),createElementBlock(`div`,_hoisted_6$90,[group.ready||index$1confirmSellPart(part.data)},{default:withCtx(()=>[..._cache[3]||=[createTextVNode(` Sell `,-1)]]),_:1},8,[`accent`,`onClick`])):createCommentVNode(``,!0)])),[[unref(BngOnUiNav_default),()=>group.onExpanded(!1),`back`]])),256))]),_:2},1032,[`data-groupid`,`onExpanded`,`onSelected`]))),128))]),_:1})):(openBlock(),createElementBlock(`div`,_hoisted_2$168,` Please wait... `))]),_:1})),[[unref(BngDisabled_default),!unref(partInventoryStore)]])])),[[unref(BngBlur_default)]])}},PartList_default=__plugin_vue_export_helper_default(_sfc_main$237,[[`__scopeId`,`data-v-7c222f4e`]]),_hoisted_1$208={style:{width:`100%`}},_sfc_main$236={__name:`PartInventoryAddedParts`,props:{parts:{type:Object,default:{}}},setup(__props){let{units}=useBridge(),getLocationName=part=>part.location?`Vehicle No. `+part.location+` (`+part.vehicleModel+`)`:`Inventory`;return(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,null,[_cache[1]||=createTextVNode(` The following additional parts have been added to the vehicle from your inventory to fill the core slots: `,-1),createBaseVNode(`table`,_hoisted_1$208,[_cache[0]||=createBaseVNode(`thead`,null,[createBaseVNode(`tr`,null,[createBaseVNode(`th`,null,`id`),createBaseVNode(`th`,null,`Description`),createBaseVNode(`th`,null,`Location`),createBaseVNode(`th`,null,`Mileage`),createBaseVNode(`th`,null,`Part Value`)])],-1),createBaseVNode(`tbody`,null,[(openBlock(!0),createElementBlock(Fragment,null,renderList(__props.parts,(part,key)=>(openBlock(),createElementBlock(`tr`,{key},[createBaseVNode(`td`,null,toDisplayString(part.id),1),createBaseVNode(`td`,null,toDisplayString(part.description.description),1),createBaseVNode(`td`,null,toDisplayString(getLocationName(part)),1),createBaseVNode(`td`,null,toDisplayString(unref(units).buildString(`length`,part.partCondition.odometer,0)),1),createBaseVNode(`td`,null,toDisplayString(unref(units).beamBucks(part.finalValue)),1)]))),128))])])]))}},PartInventoryAddedParts_default=__plugin_vue_export_helper_default(_sfc_main$236,[[`__scopeId`,`data-v-8dbd3a82`]]),_sfc_main$235={__name:`PartInventoryMain`,setup(__props){useComputerStore();let wrapper=ref(),partInventoryStore=usePartInventoryStore();watch(()=>partInventoryStore.newPartsPopupOpen,(newVal,oldVal)=>newVal&&confirmAddedParts());let confirmAddedParts=async vehicle=>{await openMessage(``,{component:markRaw(PartInventoryAddedParts_default),props:{parts:partInventoryStore.newParts}}),closeNewPartsPopup()},updateCareerStatus=()=>{wrapper.value.statusUpdate()};onBeforeMount(()=>{partInventoryStore.requestInitialData()}),onUnmounted(()=>{partInventoryStore.partInventoryClosed(),partInventoryStore.$dispose()});let close=()=>{partInventoryStore.closeMenu()},closeNewPartsPopup=()=>{partInventoryStore.closeNewPartsPopup()};return(_ctx,_cache)=>(openBlock(),createBlock(ComputerWrapper_default,{ref_key:`wrapper`,ref:wrapper,path:[`Part Inventory`],title:`Part Inventory`,back:``,onBack:close},{default:withCtx(()=>[createVNode(PartList_default,{class:`part-inventory`,onPartSold:updateCareerStatus})]),_:1},512))}},PartInventoryMain_default=__plugin_vue_export_helper_default(_sfc_main$235,[[`__scopeId`,`data-v-54c60dea`]]);const usePartShoppingStore=defineStore(`partShopping`,()=>{let{events:events$3}=useBridge(),partShoppingData=ref({}),filteredSlots=ref([]),path=ref(``),filteredParts=ref([]),category=ref(``),expandedSlots=ref({}),searchString=``,slotToScrollTo=ref(),backAction=()=>{},slotsDict={},partFilter;function doesNameContainString(name,searchStrings){for(let searchString$1 of searchStrings)if(name.includes(searchString$1))return!0;return!1}function filterParts(){if(filteredParts.value=[],slotsDict={},partShoppingData.value.partsInShop){for(let[_,part]of Object.entries(partShoppingData.value.partsInShop)){if(!part.slot)continue;partFilter?doesNameContainString(part.name,partFilter)&&filteredParts.value.push(part):part.containingSlot===path.value&&filteredParts.value.push(part);let niceName=partShoppingData.value.slotsNiceName[part.slot];niceName==null?slotsDict[part.slot]=part.slot:slotsDict[part.slot]=niceName}filteredParts.value.sort((a$1,b)=>a$1.emptyPlaceholder?-1:b.emptyPlaceholder?1:a$1.partId&&!b.partId?-1:!a$1.partId&&b.partId?1:a$1.description.description0?(filteredSlotsDict=getSlotsFromSearchString(),filteredSlots.value=partShoppingData.value.searchSlotList.filter(doesSlotPassFilter)):filteredSlots.value=[]}function setSlotExpanded(path$1,expanded){expandedSlots.value[path$1]=expanded}function setSlot(_slot){_slot==``&&(slotToScrollTo.value=path.value),path.value=_slot,partFilter=void 0,filterParts()}function setCategory(_category){category.value=_category,filterSlots(),category.value==`everything`||category.value==``?setSlot(``):category.value==`cargo`&&(path.value=`Blablabla`,partFilter=[`cargo_load`],filterParts())}let requestInitialData=()=>{Lua_default.career_modules_partShopping.sendShoppingDataToUI()},cancelShopping=()=>{expandedSlots.value={},Lua_default.career_modules_partShopping.cancelShopping(),setCategory(``)};function fixSlots(slot){if(`children`in slot){Array.isArray(slot.children)||(slot.children=Object.values(slot.children).filter(Boolean)),slot.children.sort((a$1,b)=>(a$1.slotNiceName||a$1.slot)<(b.slotNiceName||b.slot)?-1:1);for(let childSlot of slot.children)fixSlots(childSlot)}}let handleShoppingData=data=>{data.partTree&&fixSlots(data.partTree),partShoppingData.value=data,filterParts(),filterSlots()},searchValueChanged=_searchString=>{searchString=_searchString,filterSlots()},listen=state=>{events$3[state?`on`:`off`](`partShoppingData`,handleShoppingData)};listen(!0);function dispose$2(){listen(!1)}return{partShoppingData,slot:path,filteredSlots,filteredParts,category,expandedSlots,slotToScrollTo,searchValueChanged,setSlot,setCategory,requestInitialData,cancelShopping,dispose:dispose$2,setSlotExpanded,set backAction(actionFunc){backAction=actionFunc},get backAction(){return backAction}}});var _hoisted_1$207={class:`cart-main`},_hoisted_2$167={class:`cart-list`,"bng-nav-scroll":``},_hoisted_3$146={key:0,class:`extra-info-text`},_hoisted_4$121={key:0},_hoisted_5$106={key:1},_hoisted_6$89={class:`cart-row cart-subtotal`},_hoisted_7$77={class:`cart-row cart-tax`},_hoisted_8$63={class:`cart-row cart-total`},_sfc_main$234={__name:`ShoppingCart`,props:{cartData:Object,playerMoney:Number,apply:Function,cancel:Function,confirmButtonText:String},setup(__props){let props=__props,{units}=useBridge(),expanded=ref(!1),subtotal=computed(()=>props.cartData&&props.cartData.total&&props.cartData.taxes?props.cartData.total-props.cartData.taxes:0),salesTax=computed(()=>props.cartData&&props.cartData.taxes?props.cartData.taxes:0);return(_ctx,_cache)=>(openBlock(),createBlock(unref(bngCard_default),{class:normalizeClass([`cart`,{expanded:expanded.value}])},{buttons:withCtx(()=>[withDirectives((openBlock(),createBlock(unref(bngButton_default),{"show-hold":``,disabled:!__props.apply||!__props.cartData||__props.cartData.items.length===0||__props.cartData.total>0&&__props.cartData.total>__props.playerMoney},{default:withCtx(()=>[createTextVNode(toDisplayString(__props.confirmButtonText||`Purchase`),1)]),_:1},8,[`disabled`])),[[unref(BngOnUiNav_default),void 0,`ok`,{asMouse:!0,focusRequired:!0}],[unref(BngClick_default),{holdCallback:__props.apply,holdDelay:1e3,repeatInterval:0}]]),createVNode(unref(bngButton_default),{disabled:!__props.cancel,onClick:_cache[1]||=$event=>props.cancel(),accent:unref(ACCENTS).secondary},{default:withCtx(()=>[..._cache[10]||=[createTextVNode(` Cancel `,-1)]]),_:1},8,[`disabled`,`accent`])]),default:withCtx(()=>[createVNode(unref(bngCardHeading_default),null,{default:withCtx(()=>[..._cache[2]||=[createTextVNode(` Shopping Cart `,-1)]]),_:1}),createVNode(unref(bngButton_default),{class:`cart-expand`,accent:unref(ACCENTS).outlined,icon:expanded.value?unref(icons).arrowLargeDown:unref(icons).arrowLargeUp,onClick:_cache[0]||=$event=>expanded.value=!expanded.value},null,8,[`accent`,`icon`]),createBaseVNode(`div`,_hoisted_1$207,[_cache[9]||=createBaseVNode(`div`,{class:`cart-row cart-header`},[createBaseVNode(`div`),createBaseVNode(`div`,null,`Part`),createBaseVNode(`div`,null,`Price`)],-1),createBaseVNode(`div`,_hoisted_2$167,[__props.cartData?(openBlock(!0),createElementBlock(Fragment,{key:0},renderList(__props.cartData.items,item=>(openBlock(),createElementBlock(`div`,{class:normalizeClass([`cart-row`,item.type?[`type-${item.type}`]:null])},[createBaseVNode(`div`,null,[item.removeShow?(openBlock(),createBlock(unref(bngButton_default),{key:0,accent:`attention`,icon:unref(icons).abandon,disabled:item.removeDisabled,onClick:$event=>item.remove()},null,8,[`icon`,`disabled`,`onClick`])):createCommentVNode(``,!0)]),createBaseVNode(`div`,{style:normalizeStyle({paddingLeft:item.level?`${item.level-1}em`:void 0})},[createTextVNode(toDisplayString(item.name)+` `,1),item.extraInfo?(openBlock(),createElementBlock(`div`,_hoisted_3$146,toDisplayString(item.extraInfo),1)):createCommentVNode(``,!0)],4),item.priceHide?(openBlock(),createElementBlock(`div`,_hoisted_5$106)):(openBlock(),createElementBlock(`div`,_hoisted_4$121,toDisplayString(unref(units).beamBucks(item.price)),1))],2))),256)):createCommentVNode(``,!0),createBaseVNode(`div`,_hoisted_6$89,[_cache[3]||=createBaseVNode(`div`,null,null,-1),_cache[4]||=createBaseVNode(`div`,null,`Subtotal`,-1),createBaseVNode(`div`,null,toDisplayString(unref(units).beamBucks(subtotal.value)),1)]),createBaseVNode(`div`,_hoisted_7$77,[_cache[5]||=createBaseVNode(`div`,null,null,-1),_cache[6]||=createBaseVNode(`div`,null,`Sales Tax (7%)`,-1),createBaseVNode(`div`,null,toDisplayString(unref(units).beamBucks(salesTax.value)),1)])]),createBaseVNode(`div`,_hoisted_8$63,[_cache[7]||=createBaseVNode(`div`,null,null,-1),_cache[8]||=createBaseVNode(`div`,null,`Total`,-1),createBaseVNode(`div`,null,[createVNode(unref(bngUnit_default),{money:__props.cartData?__props.cartData.total:0},null,8,[`money`])])])])]),_:1},8,[`class`]))}},ShoppingCart_default=__plugin_vue_export_helper_default(_sfc_main$234,[[`__scopeId`,`data-v-e9392f36`]]),_hoisted_1$206={class:`parts-wrapper`},_hoisted_2$166={key:2,class:`parts-list`},_hoisted_3$145={class:`part-info-col`},_hoisted_4$120={class:`part-name`},_hoisted_5$105={key:0},_hoisted_6$88={key:1},_hoisted_7$76={key:2},_hoisted_8$62={class:`part-info-row`},_hoisted_9$56={key:0,class:`mileage-text`},_hoisted_10$47={key:1},_hoisted_11$42={key:2,class:`disabled-reason`},_hoisted_12$31={key:3,class:`right`},_hoisted_13$27={key:0},_sfc_main$233={__name:`PartsList`,setup(__props){let partShoppingStore=usePartShoppingStore(),{units}=useBridge(),oldBack,isPartInShoppingCart=part=>{if(!partShoppingStore.partShoppingData||!partShoppingStore.partShoppingData.shoppingCart)return!1;let partList=partShoppingStore.partShoppingData.shoppingCart.partsInList;for(let i=0;i{oldBack=partShoppingStore.backAction,partShoppingStore.backAction=()=>partShoppingStore.setSlot(``)}),onUnmounted(()=>{partShoppingStore.backAction=oldBack}),(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$206,[unref(partShoppingStore).category===`cargo`?(openBlock(),createBlock(unref(bngCardHeading_default),{key:0},{default:withCtx(()=>[..._cache[0]||=[createTextVNode(` Cargo `,-1)]]),_:1})):unref(partShoppingStore).filteredParts[0]?(openBlock(),createBlock(unref(bngCardHeading_default),{key:1},{default:withCtx(()=>[createTextVNode(toDisplayString(unref(partShoppingStore).partShoppingData.slotsNiceName[unref(partShoppingStore).filteredParts[0].containingSlot]),1)]),_:1})):createCommentVNode(``,!0),unref(partShoppingStore).filteredParts?(openBlock(),createElementBlock(`div`,_hoisted_2$166,[(openBlock(!0),createElementBlock(Fragment,null,renderList(unref(partShoppingStore).filteredParts,part=>(openBlock(),createElementBlock(`div`,{class:normalizeClass([`part-item`,{"part-installed":unref(partShoppingStore).partShoppingData.vehicleSlotToPartMap[part.containingSlot]&&unref(partShoppingStore).partShoppingData.vehicleSlotToPartMap[part.containingSlot].description.description===part.description.description,disabled:part.disabled}])},[createBaseVNode(`div`,_hoisted_3$145,[createBaseVNode(`div`,null,[createBaseVNode(`span`,_hoisted_4$120,[part.partId?(openBlock(),createElementBlock(`div`,_hoisted_5$105,toDisplayString(part.description.description)+` (Inventory) `,1)):part.emptyPlaceholder?(openBlock(),createElementBlock(`div`,_hoisted_6$88,` Remove current part `)):(openBlock(),createElementBlock(`div`,_hoisted_7$76,toDisplayString(part.description.description),1))])]),createBaseVNode(`div`,_hoisted_8$62,[part.partId?(openBlock(),createElementBlock(`span`,_hoisted_9$56,` Mileage: `+toDisplayString(unref(units).buildString(`length`,part.partCondition.odometer,0)),1)):createCommentVNode(``,!0),unref(partShoppingStore).category===`cargo`?(openBlock(),createElementBlock(`span`,_hoisted_10$47,toDisplayString(unref(partShoppingStore).partShoppingData.slotsNiceName[part.containingSlot]),1)):createCommentVNode(``,!0),part.disabled&&part.disabledReason?(openBlock(),createElementBlock(`span`,_hoisted_11$42,toDisplayString(part.disabledReason),1)):createCommentVNode(``,!0),!part.partId&&!part.emptyPlaceholder?(openBlock(),createElementBlock(`span`,_hoisted_12$31,[createVNode(unref(bngPropVal_default),{iconType:unref(icons).beamCurrency,valueLabel:unref(units).beamBucks(part.finalValue)},null,8,[`iconType`,`valueLabel`])])):createCommentVNode(``,!0)])]),createVNode(unref(bngButton_default),{accent:isPartInShoppingCart(part)?unref(ACCENTS).attention:unref(ACCENTS).outlined,class:`part-button`,disabled:part.disabled||unref(partShoppingStore).partShoppingData.tutorialPartNames!==void 0&&(!unref(partShoppingStore).partShoppingData.tutorialPartNames[part.name]||isPartInShoppingCart(part)),onClick:$event=>isPartInShoppingCart(part)?unref(Lua_default).career_modules_partShopping.removePartBySlot(part.containingSlot):unref(Lua_default).career_modules_partShopping.installPartByPartShopId(part.partShopId),icon:isPartInShoppingCart(part)?unref(icons).undo:``},{default:withCtx(()=>[isPartInShoppingCart(part)?createCommentVNode(``,!0):(openBlock(),createElementBlock(`div`,_hoisted_13$27,toDisplayString(part.emptyPlaceholder?`Remove`:`Install`),1))]),_:2},1032,[`accent`,`disabled`,`onClick`,`icon`])],2))),256))])):createCommentVNode(``,!0)]))}},PartsList_default=__plugin_vue_export_helper_default(_sfc_main$233,[[`__scopeId`,`data-v-c224fcea`]]),_hoisted_1$205={key:0,class:`highlighted`},_hoisted_2$165={key:1,class:`slot-path`},_hoisted_3$144={class:`buy-button-label`},_sfc_main$232={__name:`SlotItem`,props:{static:Boolean,expanded:Boolean,path:String,nicePath:String,slotNiceName:String,partNiceName:String},setup(__props){let slotItem=ref(),focused$1=ref(!1),props=__props;onMounted(()=>{partShoppingStore.slotToScrollTo&&props.path===partShoppingStore.slotToScrollTo&&slotItem.value.scrollIntoView({block:`center`})});let partShoppingStore=usePartShoppingStore(),itemExpanded=val=>{partShoppingStore.setSlotExpanded(props.path,val)},onFocus=val=>{focused$1.value=!0},onUnfocus=val=>{focused$1.value=!1},selectSlot=val=>{partShoppingStore.setSlot(props.path)};return(_ctx,_cache)=>(openBlock(),createBlock(unref(accordionItem_default),{static:__props.static,expanded:__props.expanded,onExpanded:itemExpanded,onFocus,onUnfocus,onSelected:selectSlot,navigable:``,"primary-action":()=>unref(partShoppingStore).setSlot(__props.path),"expand-hint-inline":``,"primary-hint-inline":``},{caption:withCtx(()=>[unref(partShoppingStore).slotToScrollTo===__props.path?(openBlock(),createElementBlock(`div`,_hoisted_1$205)):createCommentVNode(``,!0),__props.nicePath?(openBlock(),createElementBlock(`span`,_hoisted_2$165,toDisplayString(__props.nicePath),1)):createCommentVNode(``,!0),createBaseVNode(`span`,{ref_key:`slotItem`,ref:slotItem,class:`slot-name`},toDisplayString(__props.slotNiceName),513)]),controls:withCtx(()=>[withDirectives((openBlock(),createBlock(unref(bngButton_default),{"bng-no-nav":`true`,class:`buy-button`,accent:unref(ACCENTS).outlined,onClick:_cache[0]||=$event=>unref(partShoppingStore).setSlot(__props.path),style:normalizeStyle({backgroundColor:unref(partShoppingStore).slotToScrollTo&&unref(partShoppingStore).slotToScrollTo==__props.path?`rgba(75,75,75,0.8)`:``})},{default:withCtx(()=>[createBaseVNode(`span`,_hoisted_3$144,toDisplayString(__props.partNiceName?__props.partNiceName:`-`),1)]),_:1},8,[`accent`,`style`])),[[unref(BngTooltip_default),__props.partNiceName,`top`]])]),default:withCtx(()=>[renderSlot(_ctx.$slots,`default`,{},void 0,!0)]),_:3},8,[`static`,`expanded`,`primary-action`]))}},SlotItem_default=__plugin_vue_export_helper_default(_sfc_main$232,[[`__scopeId`,`data-v-3223c56d`]]),_sfc_main$231={__name:`PartSubTree`,props:{children:Object},setup(__props){let slotItemRefs=ref([]),partShoppingStore=usePartShoppingStore();return(_ctx,_cache)=>(openBlock(),createBlock(unref(accordion_default),null,{default:withCtx(()=>[(openBlock(!0),createElementBlock(Fragment,null,renderList(__props.children,childSlot=>(openBlock(),createBlock(SlotItem_default,{ref_for:!0,ref_key:`slotItemRefs`,ref:slotItemRefs,static:!childSlot.chosenPartName||!childSlot.children||Object.keys(childSlot.children).length===0,expanded:unref(partShoppingStore).expandedSlots[childSlot.path],path:childSlot.path,slotNiceName:childSlot.slotNiceName,partNiceName:childSlot.chosenPartNiceName},{default:withCtx(()=>[childSlot.children&&Object.keys(childSlot.children).length>0?(openBlock(),createBlock(PartSubTree_default,{key:0,children:childSlot.children},null,8,[`children`])):createCommentVNode(``,!0)]),_:2},1032,[`static`,`expanded`,`path`,`slotNiceName`,`partNiceName`]))),256))]),_:1}))}},PartSubTree_default=_sfc_main$231,_hoisted_1$204={class:`innerList`},_sfc_main$230={__name:`SlotList`,props:{cancel:Function},setup(__props){let partShoppingStore=usePartShoppingStore(),props=__props,searchValue=ref(``),searchValueChanged=()=>{partShoppingStore.searchValueChanged(searchValue.value)};return onMounted(()=>{partShoppingStore.backAction,partShoppingStore.backAction=()=>partShoppingStore.setCategory(``)}),onUnmounted(()=>{partShoppingStore.backAction=()=>props.cancel()}),(_ctx,_cache)=>unref(partShoppingStore).slot===``?(openBlock(),createElementBlock(Fragment,{key:1},[createVNode(unref(bngInput_default),{"floating-label":`Search`,"leading-icon":unref(icons).search,modelValue:searchValue.value,"onUpdate:modelValue":_cache[0]||=$event=>searchValue.value=$event,modelModifiers:{trim:!0},onValueChanged:searchValueChanged},null,8,[`leading-icon`,`modelValue`]),createBaseVNode(`div`,_hoisted_1$204,[searchValue.value.length>0?(openBlock(),createBlock(unref(accordion_default),{key:0,class:`slot-flat-view`},{default:withCtx(()=>[(openBlock(!0),createElementBlock(Fragment,null,renderList(unref(partShoppingStore).filteredSlots,slotInfo=>(openBlock(),createBlock(SlotItem_default,{static:!0,path:slotInfo.path,nicePath:slotInfo.nicePath,slotNiceName:slotInfo.slotNiceName,partNiceName:slotInfo.partNiceName?slotInfo.partNiceName:null},null,8,[`path`,`nicePath`,`slotNiceName`,`partNiceName`]))),256))]),_:1})):unref(partShoppingStore).partShoppingData.partTree.children?(openBlock(),createBlock(PartSubTree_default,{key:1,class:`slot-tree-view`,children:unref(partShoppingStore).partShoppingData.partTree.children},null,8,[`children`])):createCommentVNode(``,!0)])],64)):(openBlock(),createBlock(PartsList_default,{key:0}))}},SlotList_default=__plugin_vue_export_helper_default(_sfc_main$230,[[`__scopeId`,`data-v-f602b7c1`]]),_hoisted_1$203={key:0,class:`mainCategories`},_hoisted_2$164=[`disabled`],_sfc_main$229={__name:`Categories`,props:{cancel:Function},setup(__props){let partShoppingStore=usePartShoppingStore(),props=__props;return onMounted(()=>{partShoppingStore.backAction=()=>props.cancel()}),(_ctx,_cache)=>(openBlock(),createBlock(unref(bngCard_default),{class:`categoryList`},{default:withCtx(()=>[unref(partShoppingStore).category===``?(openBlock(),createElementBlock(`div`,_hoisted_1$203,[withDirectives((openBlock(),createElementBlock(`div`,{class:`computer-function-tile`,"bng-nav-item":``,tabindex:`0`,disabled:unref(partShoppingStore).partShoppingData.tutorialPartNames===void 0?void 0:!0,onClick:_cache[0]||=$event=>unref(partShoppingStore).partShoppingData.tutorialPartNames===void 0?unref(partShoppingStore).setCategory(`everything`):void 0},[createVNode(unref(bngIcon_default),{class:`icon`,type:unref(icons).doorFrontCoins},null,8,[`type`]),_cache[2]||=createBaseVNode(`span`,{class:`label`},`All Parts`,-1)],8,_hoisted_2$164)),[[unref(BngFocusIf_default),!0]]),createBaseVNode(`div`,{class:`computer-function-tile`,"bng-nav-item":``,tabindex:`0`,onClick:_cache[1]||=$event=>unref(partShoppingStore).setCategory(`cargo`)},[createVNode(unref(bngIcon_default),{class:`icon`,type:unref(icons).boxPickUp03},null,8,[`type`]),_cache[3]||=createBaseVNode(`span`,{class:`label`},`Cargo Parts`,-1)])])):(openBlock(),createBlock(SlotList_default,{key:1,cancel:props.cancel},null,8,[`cancel`]))]),_:1}))}},Categories_default=__plugin_vue_export_helper_default(_sfc_main$229,[[`__scopeId`,`data-v-70c591df`]]),CANCEL_MESSAGE$1=`Are you sure you want to cancel?
    All changes to your vehicle will be reversed`,_sfc_main$228={__name:`PartShoppingMain`,setup(__props){let{$game}=useLibStore();useComputerStore();let partShoppingStore=usePartShoppingStore(),CONFIRM_BUTTONS=[{label:$translate.instant(`ui.common.yes`),value:!0},{label:$translate.instant(`ui.common.no`),value:!1,extras:{accent:ACCENTS.secondary}}],confirmCancel=async()=>{(!partShoppingStore.partShoppingData.shoppingCart.partsInList.length||await openConfirmation(null,CANCEL_MESSAGE$1,CONFIRM_BUTTONS))&&cancelShopping()},getPartName=item=>item.description.description+(item.partId?` (Inventory)`:``),cartData=computed(()=>{let cart=partShoppingStore.partShoppingData?partShoppingStore.partShoppingData.shoppingCart:null,res={total:0,taxes:0,items:[]};return cart&&(res.total=cart.total,res.taxes=cart.taxes,Array.isArray(cart.partsInList)&&(res.items=cart.partsInList.map(item=>({name:getPartName(item),price:item.finalValue,extraInfo:item.partCondition?.odometer?`Mileage: `+$game.units.buildString(`length`,item.partCondition.odometer,0):void 0,removeShow:!!item.sourcePart,removeDisabled:!!partShoppingStore.partShoppingData.tutorialPartNames,remove:()=>Lua_default.career_modules_partShopping.removePartBySlot(item.containingSlot)})))),res}),applyShopping=()=>Lua_default.career_modules_partShopping.applyShopping(),cancelShopping=()=>Lua_default.career_modules_partShopping.cancelShopping(),start=()=>{partShoppingStore.setSlot(``),partShoppingStore.requestInitialData(),getUINavServiceInstance().setFilteredEvents(UI_EVENT_GROUPS.focusMoveScalar)},kill=()=>{partShoppingStore.cancelShopping(),getUINavServiceInstance().clearFilteredEvents(),partShoppingStore.$dispose()},close=()=>{partShoppingStore.backAction()};return onBeforeMount(start),onUnmounted(kill),(_ctx,_cache)=>(openBlock(),createBlock(ComputerWrapper_default,{path:[`Part Customization`],title:`Parts`,back:``,onBack:close},{side:withCtx(()=>[createVNode(ShoppingCart_default,{partShoppingData:unref(partShoppingStore).partShoppingData,"cart-data":cartData.value,"player-money":unref(partShoppingStore).partShoppingData.playerMoney,apply:applyShopping,cancel:confirmCancel,"confirm-button-text":`Confirm`},null,8,[`partShoppingData`,`cart-data`,`player-money`])]),default:withCtx(()=>[withDirectives(createVNode(Categories_default,{cancel:confirmCancel},null,512),[[unref(BngBlur_default),1]])]),_:1}))}},PartShoppingMain_default=__plugin_vue_export_helper_default(_sfc_main$228,[[`__scopeId`,`data-v-871a3a9f`]]),_hoisted_1$202={class:`profile-status`},_hoisted_2$163={class:`profile-status-progress`},_hoisted_3$143={class:`status-progress-item`},_hoisted_4$119={class:`status-progress-item`},_hoisted_5$104={class:`status-progress-item`},_hoisted_6$87={key:0,class:`profile-status-levels`},_hoisted_7$75={class:`profile-status-level`},_hoisted_8$61={class:`branch-icon-assembly`},_hoisted_9$55={class:`level-content-wrapper`},_sfc_main$227={__name:`ProfileStatus`,props:{beamXP:{type:Object,required:!0},vouchers:{type:Object,required:!0},money:{type:Object,required:!0},insuranceScore:{type:Object,required:!0},branches:{type:Array,required:!0},expanded:Boolean},setup(__props){let props=__props,formatterFn=num=>shrinkNum(num,1),moneyFormatter=computed(()=>props.money&&props.money>1e5?formatterFn:void 0);computed(()=>props.beamXP&&props.beamXP>1e5?formatterFn:void 0);let vouchersFormatter=computed(()=>props.vouchers&&props.vouchers>1e5?formatterFn:void 0);function getBranchStyle(color){return getIconBackgroundStyle(color)}return(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$202,[createBaseVNode(`div`,_hoisted_2$163,[createBaseVNode(`div`,_hoisted_3$143,[createVNode(unref(bngUnit_default),{insuranceScore:__props.insuranceScore?.value||0},null,8,[`insuranceScore`])]),createVNode(unref(bngDivider_default)),createBaseVNode(`div`,_hoisted_4$119,[createVNode(unref(bngUnit_default),{vouchers:__props.vouchers?.value||0,formatter:vouchersFormatter.value},null,8,[`vouchers`,`formatter`])]),createVNode(unref(bngDivider_default)),createBaseVNode(`div`,_hoisted_5$104,[createVNode(unref(bngUnit_default),{money:__props.money?.value||0,formatter:moneyFormatter.value},null,8,[`money`,`formatter`])])]),createVNode(Transition,{name:`expand-height`},{default:withCtx(()=>[__props.branches?withDirectives((openBlock(),createElementBlock(`div`,_hoisted_6$87,[(openBlock(!0),createElementBlock(Fragment,null,renderList(__props.branches,branch=>(openBlock(),createElementBlock(`div`,_hoisted_7$75,[createBaseVNode(`div`,_hoisted_8$61,[createBaseVNode(`div`,{class:`branch-background`,style:normalizeStyle(getBranchStyle(branch.color))},null,4),createVNode(unref(bngIcon_default),{type:branch.icon,class:`assembly-icon`},null,8,[`type`])]),createBaseVNode(`div`,_hoisted_9$55,[createVNode(unref(bngProgressBar_default),{class:`slim`,value:branch.curLvlProgress,min:0,max:branch.neededForNext,headerLeft:_ctx.$ctx_t(branch.label),headerRight:`${_ctx.$ctx_t(branch.levelLabel)} `,valueColor:`white`,showValueLabel:!1},null,8,[`value`,`max`,`headerLeft`,`headerRight`])])]))),256))],512)),[[vShow,__props.expanded]]):createCommentVNode(``,!0)]),_:1})]))}},ProfileStatus_default=__plugin_vue_export_helper_default(_sfc_main$227,[[`__scopeId`,`data-v-26c35504`]]),_hoisted_1$201={style:{position:`absolute`,left:`0`,right:`0`,top:`0`,bottom:`0`,background:`rgba(0,0,0,0.5)`}},_sfc_main$226={__name:`PauseMapPreview`,setup(__props){let levelTitle=ref(``),levelImage=ref(``);function setup$3(data){levelTitle.value=$translate.contextTranslate(data.title,!0),levelImage.value=data.previews[0]}let start=()=>{Lua_default.career_modules_uiUtils.getCareerCurrentLevelName().then(setup$3)};function goToBigMap(){Lua_default.freeroam_bigMapMode.enterBigMap()}return onMounted(start),(_ctx,_cache)=>{let _directive_bng_sound_class=resolveDirective(`bng-sound-class`);return withDirectives((openBlock(),createBlock(unref(aspectRatio_default),{"external-image":`/levels/west_coast_usa/spawns_quarry.jpg`,ratio:`4:3`,onClick:_cache[1]||=$event=>goToBigMap()},{default:withCtx(()=>[createBaseVNode(`div`,_hoisted_1$201,[createVNode(unref(bngCardHeading_default),{style:{color:`white`},type:`ribbon`},{default:withCtx(()=>[createTextVNode(toDisplayString(levelTitle.value),1)]),_:1}),createVNode(unref(bngButton_default),{style:{position:`absolute`,bottom:`1em`,right:`1em`},tabindex:`1`,accent:unref(ACCENTS).text,onClick:_cache[0]||=$event=>goToBigMap()},{default:withCtx(()=>[..._cache[2]||=[createTextVNode(`Open Map`,-1)]]),_:1},8,[`accent`])])]),_:1})),[[_directive_bng_sound_class,`bng_click_generic`]])}}},PauseMapPreview_default=__plugin_vue_export_helper_default(_sfc_main$226,[[`__scopeId`,`data-v-5a91faef`]]),_hoisted_1$200={class:`content-wrapper`},_hoisted_2$162={class:`cards-container`},_sfc_main$225={__name:`PauseMilestonesPreview`,setup(__props){let milestones=ref([]);function setup$3(data){milestones.value=data.list}let start=()=>{Lua_default.career_modules_milestones_milestones.getMilestones().then(setup$3)};function goToMilestones(){window.bngVue.gotoGameState(`milestones`)}return onMounted(start),(_ctx,_cache)=>{let _directive_bng_sound_class=resolveDirective(`bng-sound-class`);return withDirectives((openBlock(),createBlock(unref(aspectRatio_default),{onClick:_cache[1]||=$event=>goToMilestones(),ratio:`4:3`},{default:withCtx(()=>[createBaseVNode(`div`,_hoisted_1$200,[createVNode(unref(bngCardHeading_default),{style:{color:`white`},type:`ribbon`},{default:withCtx(()=>[..._cache[2]||=[createTextVNode(`Recent Milestones`,-1)]]),_:1}),createBaseVNode(`div`,_hoisted_2$162,[(openBlock(!0),createElementBlock(Fragment,null,renderList(milestones.value.slice(0,5),entry=>(openBlock(),createBlock(MilestoneCard_default,{milestone:entry,isCondensed:!0},null,8,[`milestone`]))),256))]),createVNode(unref(bngButton_default),{style:{position:`absolute`,bottom:`1em`,right:`1em`},tabindex:`1`,accent:unref(ACCENTS).text,onClick:_cache[0]||=$event=>goToMilestones()},{default:withCtx(()=>[..._cache[3]||=[createTextVNode(`Go to Milestones`,-1)]]),_:1},8,[`accent`])])]),_:1})),[[_directive_bng_sound_class,`bng_click_generic`]])}}},PauseMilestonesPreview_default=__plugin_vue_export_helper_default(_sfc_main$225,[[`__scopeId`,`data-v-7fcfd236`]]),_hoisted_1$199={class:`pause-body-wrapper`},_hoisted_2$161={class:`heading-container`},_hoisted_3$142={class:`buttons-and-status`},_hoisted_4$118={key:0,class:`indicator`},_hoisted_5$103={class:`save-load-row`},_hoisted_6$86={class:`status-container`},_hoisted_7$74={key:2,class:`vehicle-name`},_sfc_main$224={__name:`Pause`,setup(__props){useUINavScope(`pause`),ref({value:0,label:`Map`,type:`Map`}.type),ref(null),ref(.5);let contextButtons=ref({});function setupContextButtons(data){contextButtons.value=data.buttons}Lua_default.career_modules_uiUtils.getCareerPauseContextButtons().then(setupContextButtons);function onContextButtonClicked(btn){Lua_default.career_modules_uiUtils.callCareerPauseContextButtons(btn.functionId)}function onSaveButtonClicked(){Lua_default.career_saveSystem.saveCurrent(),exit()}async function onLoadButtonClicked(){await openConfirmation(`Load Profile`,`Are you sure you want to load a different profile? Any unsaved progress will be lost.`)&&window.bngVue.gotoGameState(`profiles`)}let exit=()=>window.bngVue.gotoGameState(`play`),saveSlotData=ref(null),currentVehicleName=ref(``);function makeVehicleName(data){return!data||data.key===`unicycle`?`Walking`:data.niceName}return onMounted(async()=>{let data=await Lua_default.career_career.sendCurrentSaveSlotData();saveSlotData.value=data,currentVehicleName.value=makeVehicleName(data.currentVehicle)}),onBeforeMount(()=>{Lua_default.simTimeAuthority.pushPauseRequest(`careerPause`)}),onUnmounted(()=>{Lua_default.simTimeAuthority.popPauseRequest(`careerPause`)}),(_ctx,_cache)=>withDirectives((openBlock(),createBlock(unref(layoutSingle_default),{class:`career-pause-layout`,"bng-ui-scope":`pause`},{default:withCtx(()=>[createBaseVNode(`div`,_hoisted_1$199,[createBaseVNode(`div`,_hoisted_2$161,[createVNode(unref(bngCardHeading_default),{class:`pause-heading`,type:`ribbon`},{default:withCtx(()=>[..._cache[0]||=[createTextVNode(`Career: Paused`,-1)]]),_:1})]),createBaseVNode(`div`,_hoisted_3$142,[createVNode(unref(bngCard_default),{class:`system-buttons`},{default:withCtx(()=>[createVNode(unref(bngButton_default),{class:`button`,tabindex:`1`,accent:unref(ACCENTS).text,onClick:exit},{default:withCtx(()=>[..._cache[1]||=[createTextVNode(`Resume`,-1)]]),_:1},8,[`accent`]),contextButtons.value.length>0?(openBlock(!0),createElementBlock(Fragment,{key:0},renderList(contextButtons.value,btn=>(openBlock(),createBlock(unref(bngButton_default),{class:`button`,tabindex:`1`,accent:unref(ACCENTS).text,onClick:$event=>onContextButtonClicked(btn)},{default:withCtx(()=>[createTextVNode(toDisplayString(_ctx.$ctx_t(btn.label))+` `,1),btn.showIndicator?(openBlock(),createElementBlock(`div`,_hoisted_4$118)):createCommentVNode(``,!0)]),_:2},1032,[`accent`,`onClick`]))),256)):createCommentVNode(``,!0),createBaseVNode(`div`,_hoisted_5$103,[createVNode(unref(bngButton_default),{class:`button`,tabindex:`1`,accent:unref(ACCENTS).text,onClick:onSaveButtonClicked},{default:withCtx(()=>[..._cache[2]||=[createTextVNode(`Save`,-1)]]),_:1},8,[`accent`]),createVNode(unref(bngButton_default),{class:`button`,tabindex:`1`,accent:unref(ACCENTS).text,onClick:onLoadButtonClicked},{default:withCtx(()=>[..._cache[3]||=[createTextVNode(`Load`,-1)]]),_:1},8,[`accent`])])]),_:1}),createBaseVNode(`div`,_hoisted_6$86,[saveSlotData.value?(openBlock(),createBlock(unref(bngCardHeading_default),{key:0,class:`profile-name`,type:`ribbon`},{default:withCtx(()=>[createTextVNode(toDisplayString(saveSlotData.value.id),1)]),_:1})):createCommentVNode(``,!0),saveSlotData.value?(openBlock(),createBlock(ProfileStatus_default,{key:1,class:`pause-profile-status`,expanded:!0,beamXP:saveSlotData.value.beamXP,vouchers:saveSlotData.value.vouchers,money:saveSlotData.value.money,insuranceScore:saveSlotData.value.insuranceScore,branches:saveSlotData.value.branches},null,8,[`beamXP`,`vouchers`,`money`,`insuranceScore`,`branches`])):createCommentVNode(``,!0),saveSlotData.value?(openBlock(),createElementBlock(`div`,_hoisted_7$74,[createVNode(unref(bngIcon_default),{type:unref(icons).car},null,8,[`type`]),createTextVNode(` `+toDisplayString(currentVehicleName.value),1)])):createCommentVNode(``,!0)])])])]),_:1})),[[unref(BngOnUiNav_default),exit,`menu,back`],[unref(BngBlur_default),!0]])}},Pause_default=__plugin_vue_export_helper_default(_sfc_main$224,[[`__scopeId`,`data-v-c6f22d14`]]),_hoisted_1$198={class:`career-pause-wrapper`},_hoisted_2$160={class:`layout-center-wrapper`},_hoisted_3$141={class:`pause-body-wrapper`},_hoisted_4$117={class:`left-content`},_hoisted_5$102={class:`tabs-group`},_hoisted_6$85={class:`tab-content`},_hoisted_7$73={style:{position:`absolute`,left:`0`,right:`0`,top:`0`,bottom:`0`,background:`rgba(0, 0, 0, 0.5)`}},_hoisted_8$60={class:`right-content`},_hoisted_9$54={class:`bottom-content`},ICON_RATIO=`2.25:1`,_sfc_main$223={__name:`PauseBigMiddlePanel`,setup(__props){useUINavScope(`pause`);let MIDDLE_PILL_OPTIONS=[{value:0,label:`Map`,type:`Map`},{value:1,label:`Milestones`,type:`Milestones`},{value:2,label:`Engine`},{value:3,label:`Transmission`},{value:4,label:`Suspension`},{value:5,label:`Electrics`},{value:6,label:`Electrics1`},{value:7,label:`Electrics2`},{value:8,label:`Electrics3`}],currentPillTypeSelected=ref(MIDDLE_PILL_OPTIONS[0].type),middlePillsContainerRef=ref(null);function onMiddlePillsSelectPrevious(){middlePillsContainerRef.value.selectPrevious()}function onMiddlePillsSelectNext(){middlePillsContainerRef.value.selectNext()}function middlePillsValueChanged(selectedValues){let pillId=selectedValues[0],selectedPill=MIDDLE_PILL_OPTIONS.find(pill=>pill.value===pillId);console.log(selectedPill),currentPillTypeSelected.value=selectedPill.type}let todSliderValue=ref(.5),onTODChanged=v=>{console.log(v)},contextButtons=ref({});function setupContextButtons(data){console.log(data),contextButtons.value=data.buttons}Lua_default.career_modules_uiUtils.getCareerPauseContextButtons().then(setupContextButtons);function onContextButtonClicked(btn){console.log(btn),Lua_default.career_modules_uiUtils.callCareerPauseContextButtons(btn.functionId)}function onExitCareerButtonClicked(){console.log(`onExitCareerButtonClicked`)}function onSaveButtonClicked(){career_saveSystem.saveCurrent()}function onLoadButtonClicked(){console.log(`onLoadButtonClicked`)}function onSettingsButtonClicked(){console.log(`onSettingsButtonClicked`)}return(_ctx,_cache)=>withDirectives((openBlock(),createElementBlock(`div`,_hoisted_1$198,[createVNode(unref(careerSimpleStats_default)),createBaseVNode(`div`,_hoisted_2$160,[createBaseVNode(`div`,_hoisted_3$141,[createVNode(unref(careerStatus_default),{class:`pause-profile-status`}),createBaseVNode(`div`,_hoisted_4$117,[createVNode(unref(bngImageTile_default),{label:`Exit Career`,icon:unref(icons).abandon,onClick:onExitCareerButtonClicked,ratio:ICON_RATIO},null,8,[`icon`]),createVNode(unref(bngCard_default),{class:`system-buttons`},{default:withCtx(()=>[createVNode(unref(bngButton_default),{tabindex:`1`,accent:unref(ACCENTS).text,onClick:onSaveButtonClicked},{default:withCtx(()=>[..._cache[1]||=[createTextVNode(`Save`,-1)]]),_:1},8,[`accent`]),createVNode(unref(bngButton_default),{tabindex:`1`,accent:unref(ACCENTS).text,onClick:onLoadButtonClicked},{default:withCtx(()=>[..._cache[2]||=[createTextVNode(`Load`,-1)]]),_:1},8,[`accent`]),createVNode(unref(bngButton_default),{tabindex:`1`,accent:unref(ACCENTS).text,onClick:onSettingsButtonClicked},{default:withCtx(()=>[..._cache[3]||=[createTextVNode(`Settings`,-1)]]),_:1},8,[`accent`])]),_:1})]),createVNode(unref(bngCard_default),{class:`main-content grid`},{default:withCtx(()=>[createBaseVNode(`div`,_hoisted_5$102,[createVNode(unref(bngButton_default),{class:`button prev-button`,onClick:onMiddlePillsSelectPrevious,tabindex:`0`,accent:unref(ACCENTS).text},{default:withCtx(()=>[..._cache[4]||=[createTextVNode(`Previous`,-1)]]),_:1},8,[`accent`]),createVNode(unref(bngPillFiltersContainer_default),{class:`tabs-track`,ref_key:`middlePillsContainerRef`,ref:middlePillsContainerRef,"html-id":`middle-pills-container-ref`,options:MIDDLE_PILL_OPTIONS,"select-on-navigation":!1,onValueChanged:middlePillsValueChanged,required:!0,"has-checked-icon":!1},null,512),createVNode(unref(bngButton_default),{class:`button next-button`,onClick:onMiddlePillsSelectNext,tabindex:`0`,accent:unref(ACCENTS).text},{default:withCtx(()=>[..._cache[5]||=[createTextVNode(`Next`,-1)]]),_:1},8,[`accent`])]),createBaseVNode(`div`,_hoisted_6$85,[currentPillTypeSelected.value==`Map`?(openBlock(),createBlock(PauseMapPreview_default,{key:0})):createCommentVNode(``,!0),currentPillTypeSelected.value==`Milestones`?(openBlock(),createBlock(PauseMilestonesPreview_default,{key:1})):createCommentVNode(``,!0),currentPillTypeSelected.value===void 0?withDirectives((openBlock(),createBlock(unref(aspectRatio_default),{key:2,style:{background:`red`},ratio:`4:3`},{default:withCtx(()=>[createBaseVNode(`div`,_hoisted_7$73,[createVNode(unref(bngCardHeading_default),{style:{color:`white`},type:`ribbon`},{default:withCtx(()=>[..._cache[6]||=[createTextVNode(`Undefined Pill Type!`,-1)]]),_:1})])]),_:1})),[[unref(BngSoundClass_default),`bng_click_generic`]]):createCommentVNode(``,!0)])]),_:1}),createBaseVNode(`div`,_hoisted_8$60,[(openBlock(!0),createElementBlock(Fragment,null,renderList(contextButtons.value,btn=>(openBlock(),createBlock(unref(bngImageTile_default),{label:btn.label,icon:unref(icons)[btn.icon],onClick:$event=>onContextButtonClicked(btn),ratio:ICON_RATIO},null,8,[`label`,`icon`,`onClick`]))),256))]),createBaseVNode(`div`,_hoisted_9$54,[createVNode(unref(bngImageTile_default),{class:`photo-mode`,label:`Photo Mode`,icon:unref(icons).photo,ratio:ICON_RATIO},null,8,[`icon`]),createVNode(unref(bngCard_default),{class:`tod`},{default:withCtx(()=>[_cache[7]||=createBaseVNode(`div`,{class:`icon-box`},`I'm an icon box!`,-1),createVNode(unref(bngSlider_default),{ref:`iptChanged`,min:0,max:1,step:.1,modelValue:todSliderValue.value,"onUpdate:modelValue":_cache[0]||=$event=>todSliderValue.value=$event,onValueChanged:onTODChanged},null,8,[`modelValue`]),createVNode(unref(bngInput_default),{class:`tod-value`})]),_:1})])])]),_cache[8]||=createBaseVNode(`div`,{style:{background:`green`,height:`5em`}},`FOOTER`,-1)])),[[unref(BngBlur_default)]])}},PauseBigMiddlePanel_default=__plugin_vue_export_helper_default(_sfc_main$223,[[`__scopeId`,`data-v-7b3f120b`]]),_hoisted_1$197={class:`back-text`},_sfc_main$222={__name:`BackAside`,emits:[`click`],setup(__props,{emit:__emit}){let emit$1=__emit;return(_ctx,_cache)=>withDirectives((openBlock(),createElementBlock(`div`,{class:`back-aside`,onClick:_cache[0]||=$event=>emit$1(`click`)},[createVNode(unref(bngIcon_default),{class:`back-arrow`,type:unref(icons).arrowLargeLeft},null,8,[`type`]),createBaseVNode(`span`,_hoisted_1$197,[createVNode(unref(bngBinding_default),{class:`back-binding`,"ui-event":`back`,controller:``,"track-ignore":``}),createTextVNode(` `+toDisplayString(_ctx.$tt(`ui.common.back`)),1)])])),[[unref(BngSoundClass_default),`bng_click_hover_generic`]])}},BackAside_default=__plugin_vue_export_helper_default(_sfc_main$222,[[`__scopeId`,`data-v-2fa47f3c`]]);const PROFILE_NAME_MAX_LENGTH=100,useProfilesStore=defineStore(`profiles`,()=>{async function loadProfile(profileName,tutorialEnabled,isAdd=!1){if(console.log(`profileStore.loadProfile`,profileName,tutorialEnabled,isAdd),!profileName)return console.warn(`profileStore.loadProfile: profileName is required. Not loading profile.`),!1;if(profileName.length>100&&isAdd)return console.warn(`profileStore.loadProfile: profileName is too long. Not loading profile.`),!1;console.log(`profileStore.loadProfile: creating or loading career and starting`,profileName),/^ +| +$/.test(profileName)&&(profileName=profileName.replace(/^ +| +$/g,``));let createOrLoadCareerAndStartResult=await Lua_default.career_career.createOrLoadCareerAndStart(profileName,null,tutorialEnabled);console.log(`profileStore.loadProfile: createOrLoadCareerAndStartResult`,createOrLoadCareerAndStartResult);let toastrMessage=isAdd?`added`:`loaded`;window.globalAngularRootScope.$broadcast(`toastrMsg`,{type:`info`,msg:$translate.contextTranslate(`ui.career.notification.${toastrMessage}`),config:{positionClass:`toast-top-right`,toastClass:`beamng-message-toast`,timeOut:5e3,extendedTimeOut:1e3}})}return{loadProfile}});var _hoisted_1$196={class:`profile-card-cover`},_hoisted_2$159={class:`profile-card-container`},_hoisted_3$140={class:`profile-card-title`},_hoisted_4$116={key:0,class:`profile-card-date`},_hoisted_5$101={key:0},_hoisted_6$84={key:1},_hoisted_7$72={class:`profile-card-content`},_hoisted_8$59={key:0,class:`profile-manage`},_hoisted_9$53={key:0,class:`profile-manage-rename`},_hoisted_10$46={key:1,class:`profile-manage-delete`},_hoisted_11$41={key:2,class:`profile-manage-main`},MENU_ITEMS$3={RENAME:`rename`,DELETE:`delete`},_sfc_main$221={__name:`ProfileCard`,props:{id:{type:String,required:!0},date:{type:String,required:!0},creationDate:{type:String,required:!0},incompatibleVersion:Boolean,outdatedVersion:{type:Boolean,required:!0},preview:{type:String,default:`/ui/modules/career/profilePreview_WCUSA.jpg`},beamXP:Object,vouchers:Object,vehicleCount:Number,money:Object,insuranceScore:Object,active:Boolean,branches:Array,disabled:Boolean},emits:[`card:activate`,`load`,`rename`],setup(__props,{emit:__emit}){let props=__props,emit$1=__emit,isActivated=ref(!1),isManage=ref(!1),currentMenu=ref(null),expanded=ref(!1),internalDisabled=ref(!1),cardStates=reactive({focused:!1,hovered:!1}),validateName=inject(`validateName`),nameError=ref(null),lastPlayedDescription=computed(()=>timeSpan(props.date));watch(()=>props.disabled,value=>{nextTick(()=>{internalDisabled.value=value,value&&(expanded.value=!1)})});let onScopeChanged=value=>{isActivated.value=value},cardFooterStyles$1={"background-color":`hsla(217, 22%, 12%, 1)`},validateFn=name=>{let res=validateName(name);return name===props.id&&(res=null),res?nameError.value=res:nameError.value=null,!res},canDeactivate=()=>!isManage.value,canBubbleEvent=e=>e.detail.name===`menu`&&!isManage.value;function onFocused(focused$1){cardStates.focused=focused$1,updatedExpanded()}function onHover(hover){cardStates.hovered=hover,updatedExpanded()}function updatedExpanded(){let enable=cardStates.focused||cardStates.hovered;!enable&&(isActivated.value||isManage.value)||(expanded.value=enable)}function enableManage(enable=!0){nextTick(()=>isManage.value=enable),enable&&!isActivated.value&&(isActivated.value=!0),emit$1(`card:activate`,enable)}function goBack(){if(saveName.value=props.id,currentMenu.value)currentMenu.value=null;else if(isManage.value)enableManage(!1);else return!0}let saveName=ref(props.id),deleteProfile=()=>{Lua_default.career_saveSystem.removeSaveSlot(props.id),Lua_default.career_career.sendAllCareerSaveSlotsData()},updateProfileName=()=>emit$1(`rename`,saveName.value);return(_ctx,_cache)=>withDirectives((openBlock(),createBlock(unref(bngCard_default),{backgroundImage:__props.preview,footerStyles:cardFooterStyles$1,hideFooter:!expanded.value&&!isManage.value,class:normalizeClass([{"profile-card-active":__props.active,"manage-active":isManage.value,"profile-outdated":__props.incompatibleVersion},`profile-card`]),animateFooterDelay:expanded.value?`0s`:`0.1s`,animateFooterType:`slide`,onActivate:_cache[5]||=$event=>onScopeChanged(!0),onDeactivate:_cache[6]||=$event=>onScopeChanged(!1),onFocusin:_cache[7]||=withModifiers($event=>onFocused(!0),[`self`]),onFocusout:_cache[8]||=withModifiers($event=>onFocused(!1),[`self`]),onMouseover:_cache[9]||=$event=>onHover(!0),onMouseleave:_cache[10]||=$event=>onHover(!1)},{buttons:withCtx(()=>[isManage.value?(openBlock(),createElementBlock(Fragment,{key:0},[currentMenu.value===MENU_ITEMS$3.RENAME?withDirectives((openBlock(),createBlock(unref(bngButton_default),{key:0,disabled:nameError.value!==null||saveName.value===props.id,onClick:updateProfileName},{default:withCtx(()=>[..._cache[11]||=[createTextVNode(` Save `,-1)]]),_:1},8,[`disabled`])),[[unref(BngOnUiNav_default),void 0,`ok`,{asMouse:!0,focusRequired:!0}],[unref(BngSoundClass_default),`bng_click_generic`]]):createCommentVNode(``,!0),withDirectives((openBlock(),createBlock(unref(bngButton_default),{accent:`outlined`,onClick:goBack},{default:withCtx(()=>[..._cache[12]||=[createTextVNode(` Back `,-1)]]),_:1})),[[unref(BngOnUiNav_default),void 0,`ok`,{asMouse:!0,focusRequired:!0}],[unref(BngSoundClass_default),`bng_cancel_generic`]])],64)):(openBlock(),createElementBlock(Fragment,{key:1},[withDirectives((openBlock(),createBlock(unref(bngButton_default),{accent:`outlined`,onClick:enableManage},{default:withCtx(()=>[..._cache[13]||=[createTextVNode(`Manage `,-1)]]),_:1})),[[unref(BngOnUiNav_default),void 0,`ok`,{asMouse:!0,focusRequired:!0}],[unref(BngSoundClass_default),`bng_click_generic`]]),withDirectives((openBlock(),createBlock(unref(bngButton_default),{onClick:_cache[4]||=$event=>_ctx.$emit(`load`,__props.id),disabled:__props.active||__props.incompatibleVersion},{default:withCtx(()=>[..._cache[14]||=[createTextVNode(`Load `,-1)]]),_:1},8,[`disabled`])),[[unref(BngOnUiNav_default),void 0,`ok`,{asMouse:!0,focusRequired:!0}],[unref(BngSoundClass_default),`bng_click_generic`]])],64))]),default:withCtx(()=>[createBaseVNode(`div`,_hoisted_1$196,[createBaseVNode(`div`,_hoisted_2$159,[createBaseVNode(`div`,_hoisted_3$140,toDisplayString(_ctx.$ctx_t(__props.id)),1),isManage.value?createCommentVNode(``,!0):(openBlock(),createElementBlock(`div`,_hoisted_4$116,[__props.active?(openBlock(),createElementBlock(`span`,_hoisted_5$101,toDisplayString(_ctx.$ctx_t(`ui.career.nowplaying`)),1)):(openBlock(),createElementBlock(`span`,_hoisted_6$84,toDisplayString(_ctx.$ctx_t(`ui.career.lastplayed`))+` `+toDisplayString(lastPlayedDescription.value),1))]))])]),withDirectives((openBlock(),createElementBlock(`div`,_hoisted_7$72,[isManage.value?(openBlock(),createElementBlock(`div`,_hoisted_8$59,[currentMenu.value===MENU_ITEMS$3.RENAME?(openBlock(),createElementBlock(`div`,_hoisted_9$53,[createVNode(unref(bngInput_default),{modelValue:saveName.value,"onUpdate:modelValue":_cache[0]||=$event=>saveName.value=$event,maxlength:unref(100),validate:validateFn,errorMessage:nameError.value,externalLabel:`Save Name`,onKeydown:_cache[1]||=withKeys(withModifiers(()=>{},[`prevent`]),[`enter`])},null,8,[`modelValue`,`maxlength`,`errorMessage`])])):currentMenu.value===MENU_ITEMS$3.DELETE?(openBlock(),createElementBlock(`div`,_hoisted_10$46,[createBaseVNode(`span`,null,toDisplayString(_ctx.$ctx_t(`ui.career.deletePrompt`)),1),withDirectives(createVNode(unref(bngButton_default),{label:_ctx.$ctx_t(`ui.common.yes`),accent:`attention`,onClick:deleteProfile},null,8,[`label`]),[[unref(BngOnUiNav_default),void 0,`ok`,{asMouse:!0,focusRequired:!0}],[unref(BngSoundClass_default),`bng_click_generic`]]),withDirectives(createVNode(unref(bngButton_default),{label:_ctx.$ctx_t(`ui.common.no`),accent:`secondary`,onClick:goBack},null,8,[`label`]),[[unref(BngOnUiNav_default),void 0,`ok`,{asMouse:!0,focusRequired:!0}],[unref(BngSoundClass_default),`bng_cancel_generic`]])])):(openBlock(),createElementBlock(`div`,_hoisted_11$41,[withDirectives(createVNode(unref(bngButton_default),{accent:`secondary`,label:_ctx.$ctx_t(`ui.career.rename`),disabled:__props.active,onClick:_cache[2]||=()=>currentMenu.value=MENU_ITEMS$3.RENAME},null,8,[`label`,`disabled`]),[[unref(BngOnUiNav_default),void 0,`ok`,{asMouse:!0,focusRequired:!0}],[unref(BngSoundClass_default),`bng_click_generic`]]),withDirectives(createVNode(unref(bngButton_default),{accent:`secondary`,label:_ctx.$ctx_t(`ui.career.delete`),disabled:__props.active,onClick:_cache[3]||=()=>currentMenu.value=MENU_ITEMS$3.DELETE},null,8,[`label`,`disabled`]),[[unref(BngOnUiNav_default),void 0,`ok`,{asMouse:!0,focusRequired:!0}],[unref(BngSoundClass_default),`bng_click_generic`]]),createVNode(unref(bngButton_default),{label:_ctx.$ctx_t(`ui.career.mods`),accent:`secondary`,disabled:``},null,8,[`label`]),createVNode(unref(bngButton_default),{label:_ctx.$ctx_t(`ui.career.backup`),accent:`secondary`,disabled:``},null,8,[`label`])]))])):(openBlock(),createBlock(ProfileStatus_default,{key:1,branches:__props.branches,beamXP:__props.beamXP,vouchers:__props.vouchers,vehicleCount:__props.vehicleCount,money:__props.money,insuranceScore:__props.insuranceScore},null,8,[`branches`,`beamXP`,`vouchers`,`vehicleCount`,`money`,`insuranceScore`]))])),[[unref(BngOnUiNav_default),goBack,`menu,back`]])]),_:1},8,[`backgroundImage`,`hideFooter`,`class`,`animateFooterDelay`])),[[unref(BngScopedNav_default),{canDeactivate,canBubbleEvent}],[unref(BngSoundClass_default),`bng_hover_generic`],[unref(BngDisabled_default),internalDisabled.value]])}},ProfileCard_default=__plugin_vue_export_helper_default(_sfc_main$221,[[`__scopeId`,`data-v-16215408`]]),cardFooterStyles={"background-color":`hsla(217, 22%, 12%, 1)`},_sfc_main$220={__name:`ProfileCreateCard`,props:{profileName:{required:!0},profileNameModifiers:{}},emits:mergeModels([`card:activate`,`load`],[`update:profileName`]),setup(__props,{emit:__emit}){let emit$1=__emit,profileName=useModel(__props,`profileName`),tutorialChecked=ref(!0),isActive=ref(!1),validateName=inject(`validateName`),nameError=ref(null),startButton=ref(null),cancelButton=ref(null),validateFn=name=>{let res=validateName(name);return res?nameError.value=res:nameError.value=null,!res},load=()=>emit$1(`load`,profileName.value,tutorialChecked.value);function setActive(value){isActive.value=value,emit$1(`card:activate`,value)}function onCancel(event){setTimeout(()=>{isActive.value=!1,emit$1(`card:activate`,!1)},200)}function onEnter(event){event.preventDefault();let focusButton=nameError.value?cancelButton:startButton;focusButton.value&&nextTick(()=>setFocusExternal(focusButton.value.$el))}function onMenu(){setActive(!1)}return(_ctx,_cache)=>withDirectives((openBlock(),createBlock(unref(bngCard_default),{hideFooter:!isActive.value,footerStyles:cardFooterStyles,class:`profile-create-card`,onActivate:_cache[3]||=()=>setActive(!0),onDeactivate:_cache[4]||=()=>setActive(!1)},{buttons:withCtx(()=>[withDirectives((openBlock(),createBlock(unref(bngButton_default),{ref_key:`startButton`,ref:startButton,disabled:nameError.value!==null,onClick:withModifiers(load,[`stop`])},{default:withCtx(()=>[..._cache[6]||=[createTextVNode(`Start`,-1)]]),_:1},8,[`disabled`])),[[unref(BngOnUiNav_default),void 0,`ok`,{asMouse:!0,focusRequired:!0}]]),withDirectives((openBlock(),createBlock(unref(bngButton_default),{ref_key:`cancelButton`,ref:cancelButton,accent:`outlined`,onClick:withModifiers(onCancel,[`stop`])},{default:withCtx(()=>[..._cache[7]||=[createTextVNode(`Cancel`,-1)]]),_:1})),[[unref(BngOnUiNav_default),void 0,`ok`,{asMouse:!0,focusRequired:!0}]])]),default:withCtx(()=>[withDirectives((openBlock(),createElementBlock(`div`,{class:normalizeClass([{"create-active":isActive.value},`create-content-container`])},[isActive.value?(openBlock(),createElementBlock(Fragment,{key:0},[createVNode(unref(bngInput_default),{modelValue:profileName.value,"onUpdate:modelValue":_cache[0]||=$event=>profileName.value=$event,maxlength:unref(100),validate:validateFn,errorMessage:nameError.value,externalLabel:`Save Name`,onKeydown:withKeys(onEnter,[`enter`])},null,8,[`modelValue`,`maxlength`,`errorMessage`]),createVNode(unref(bngSwitch_default),{modelValue:tutorialChecked.value,"onUpdate:modelValue":_cache[1]||=$event=>tutorialChecked.value=$event,"label-before":``,inline:!1,"label-alignment":unref(LABEL_ALIGNMENTS).START},{default:withCtx(()=>[createTextVNode(toDisplayString(_ctx.$ctx_t(`ui.career.tutorialCheckDesc`)),1)]),_:1},8,[`modelValue`,`label-alignment`]),createBaseVNode(`span`,{class:normalizeClass([`tutorial-desc`,{checked:tutorialChecked.value}])},toDisplayString(_ctx.$ctx_t(`ui.career.tutorialOnDesc`)),3)],64)):(openBlock(),createElementBlock(`div`,{key:1,"bng-nav-item":``,class:`create-content-cover`,onClick:_cache[2]||=withModifiers($event=>setActive(!0),[`stop`])},[..._cache[5]||=[createBaseVNode(`div`,{class:`cover-plus-container`},[createBaseVNode(`div`,{class:`cover-plus-button`},`+`)],-1)]]))],2)),[[unref(BngOnUiNav_default),onMenu,`menu`]])]),_:1},8,[`hideFooter`])),[[unref(BngScopedNav_default),{activated:isActive.value}],[unref(BngBlur_default)],[unref(BngSoundClass_default),`bng_hover_generic`]])}},ProfileCreateCard_default=__plugin_vue_export_helper_default(_sfc_main$220,[[`__scopeId`,`data-v-1524a2bb`]]),_sfc_main$219={__name:`Profiles`,setup(__props){let store$1=useProfilesStore(),{events:events$3}=useBridge(),profiles=ref([]),activeProfileId=ref(null),selectedCard=ref(null),newProfileName=ref(null),onLoad=async id=>{await store$1.loadProfile(id)},onRename=async(profile,newName)=>{await Lua_default.career_saveSystem.renameSaveSlot(profile.id,newName)&&(profile.id=newName)},onCreateSave=async(profileName,tutorialChecked)=>{await store$1.loadProfile(profileName,tutorialChecked,!0)};function onCardActivated(active,index){active?(selectedCard.value=index,index===-1&&(newProfileName.value=getNewName())):selectedCard.value=null}onMounted(()=>{events$3.on(`allCareerSaveSlots`,onProfilesReceived),Lua_default.career_career.sendAllCareerSaveSlotsData()}),onBeforeUnmount(()=>{events$3.off(`allCareerSaveSlots`,onProfilesReceived)}),provide(`validateName`,validateName);let navigateToMainMenu=e=>{activeProfileId.value?window.bngVue.gotoAngularState(`menu.careerPause`):window.bngVue.gotoGameState(`menu.mainmenu`)};function onDeactivate$1(event){event.detail.force||navigateToMainMenu()}async function onProfilesReceived(data){selectedCard.value=null,activeProfileId.value=null,profiles.value=[],!(!data||!Array.isArray(data)||data.length===0)&&(profiles.value=(await updateActiveProfile(data)).map(p$1=>({id:p$1.id,date:p$1.date,creationDate:p$1.creationDate,incompatibleVersion:p$1.incompatibleVersion,outdatedVersion:p$1.outdatedVersion,preview:p$1.preview,beamXP:p$1.beamXP,vouchers:p$1.vouchers,vehicleCount:p$1.vehicleCount,money:p$1.money,insuranceScore:p$1.insuranceScore,branches:p$1.branches})))}async function updateActiveProfile(data){let currentSave=await Lua_default.career_career.sendCurrentSaveSlotData();if(data.sort((a$1,b)=>new Date(b.date)-new Date(a$1.date)),currentSave){activeProfileId.value=currentSave.id;let current=data.find(x=>x.id===currentSave.id);current||=currentSave,data=data.filter(x=>x.id!==currentSave.id),data.splice(0,0,current)}return data}function validateName(newName){return newName?newName.length>100?`Save name cannot be longer than 100 characters`:/[<>:"/\\|?*]/.test(newName)?`Save name cannot contain invalid characters`:profiles.value&&profiles.value.find(profile=>profile.id.toLowerCase()===newName.toLowerCase())?`Save name already exists`:null:`Save name cannot be empty`}function getNewName(){let prefix$1=$translate.contextTranslate(`ui.career.profile`),id;for(let i=1;i<1e3&&(id=`${prefix$1} ${i}`,!(!profiles.value||!profiles.value.find(profile=>profile.id===id)));i++);return id}return onBeforeMount(()=>{Lua_default.simTimeAuthority.pushPauseRequest(`profiles`)}),onUnmounted(()=>{Lua_default.simTimeAuthority.popPauseRequest(`profiles`)}),(_ctx,_cache)=>(openBlock(),createElementBlock(Fragment,null,[withDirectives((openBlock(),createElementBlock(`div`,{class:`profiles-container`,onDeactivate:onDeactivate$1},[createVNode(unref(bngScreenHeading_default),{class:`profiles-title`,preheadings:[_ctx.$ctx_t(`ui.playmodes.career`)]},{default:withCtx(()=>[createTextVNode(toDisplayString(_ctx.$ctx_t(`ui.career.savedProgress`)),1)]),_:1},8,[`preheadings`]),withDirectives(createVNode(BackAside_default,{class:`profiles-back`,onClick:navigateToMainMenu},null,512),[[unref(BngOnUiNav_default),navigateToMainMenu,`back,menu`]]),createVNode(unref(bngList_default),{layout:unref(LIST_LAYOUTS).RIBBON,"target-width":22,"target-height":28,"target-margin":1,"no-background":``},{default:withCtx(()=>[createVNode(ProfileCreateCard_default,{profileName:newProfileName.value,"onUpdate:profileName":_cache[0]||=$event=>newProfileName.value=$event,class:`profile-card`,"onCard:activate":_cache[1]||=value=>onCardActivated(value,-1),onLoad:onCreateSave},null,8,[`profileName`]),(openBlock(!0),createElementBlock(Fragment,null,renderList(profiles.value,(profile,index)=>withDirectives((openBlock(),createBlock(ProfileCard_default,{key:index,id:profile.id,date:profile.date,creationDate:profile.creationDate,incompatibleVersion:profile.incompatibleVersion,outdatedVersion:profile.outdatedVersion,preview:profile.preview,beamXP:profile.beamXP,vouchers:profile.vouchers,vehicleCount:profile.vehicleCount,money:profile.money,insuranceScore:profile.insuranceScore,branches:profile.branches,active:activeProfileId.value===profile.id,disabled:selectedCard.value!==null&&selectedCard.value!==index,class:`profile-card`,"onCard:activate":value=>onCardActivated(value,index),onLoad,onRename:newName=>onRename(profile,newName)},null,8,[`id`,`date`,`creationDate`,`incompatibleVersion`,`outdatedVersion`,`preview`,`beamXP`,`vouchers`,`vehicleCount`,`money`,`insuranceScore`,`branches`,`active`,`disabled`,`onCard:activate`,`onRename`])),[[unref(BngPopover_default),profile.incompatibleVersion?`tooltip-outdated-message`:null,`top`]])),128))]),_:1},8,[`layout`])],32)),[[unref(BngScopedNav_default),{activateOnMount:!0}]]),createVNode(unref(bngPopoverContent_default),{name:`tooltip-outdated-message`},{default:withCtx(()=>[..._cache[2]||=[createBaseVNode(`div`,{class:`tooltip-outdated-message`},`This profile was saved with an old version of the game. It can no longer be loaded.`,-1)]]),_:1})],64))}},Profiles_default=__plugin_vue_export_helper_default(_sfc_main$219,[[`__scopeId`,`data-v-6aef0f62`]]);const useRepairStore=defineStore(`repair`,()=>{let repairOptions=ref({}),vehicleData=ref({}),playerAttributes=ref({}),driverScoreTierData=ref({}),futureDriverScore=ref(0),driverScore=ref(0),resetStore=()=>{repairOptions.value={},vehicleData.value={},playerAttributes.value={},driverScoreTierData.value={},futureDriverScore.value=0,driverScore.value=0};return{repairOptions,vehicleData,playerAttributes,getRepairData:()=>{resetStore(),Lua_default.career_modules_insurance_repairScreen.getRepairData().then(data=>{repairOptions.value=data.repairOptions,vehicleData.value=data.vehicleData,playerAttributes.value=data.playerAttributes,driverScoreTierData.value=data.driverScoreTierData,futureDriverScore.value=data.futureDriverScore,driverScore.value=data.driverScore})},driverScoreTierData,futureDriverScore,driverScore,resetStore}});var _hoisted_1$195={class:`content blue-background`},_hoisted_2$158={class:`vehicle-info`},_hoisted_3$139={class:`right-info-wrapper`},_hoisted_4$115={class:`damage-estimate-wrapper`},_hoisted_5$100={class:`damage-estimate-value`},_hoisted_6$83={key:0},_hoisted_7$71={class:`repair-options`},_hoisted_8$58=[`onClick`],_hoisted_9$52={class:`icon-wrapper`},_hoisted_10$45={key:0,class:`option-text-wrapper`},_hoisted_11$40={class:`smaller-text`},_hoisted_12$30={class:`bigger-text`,style:{"margin-top":`-5px`}},_hoisted_13$26={key:1,class:`option-text-wrapper`},_hoisted_14$25={key:0},_hoisted_15$24={class:`details-wrapper`},_hoisted_16$24={class:`detail-wrapper`},_hoisted_17$19={class:`item`},_hoisted_18$17={key:0,class:`accident-forgivenesses-text`},_hoisted_19$14={key:0,class:`item`},_hoisted_20$12={class:`item-value`},_hoisted_21$11={key:1,class:`renews-in-wrapper`},_hoisted_22$9={class:`renews-in-name`},_hoisted_23$8={class:`renews-in-value`},_hoisted_24$7={class:`detail-wrapper`},_hoisted_25$6={class:`item`},_hoisted_26$5={class:`item-value`},_hoisted_27$5={class:`item`},_hoisted_28$4={class:`item-value`},_hoisted_29$4={key:0,class:`item`},_hoisted_30$4={class:`item-value`},_hoisted_31$4={key:1,class:`item`},_hoisted_32$4={class:`item-value`},_hoisted_33$4={class:`item total-cost`},_hoisted_34$4={class:`item-value`},_hoisted_35$3={key:0},_hoisted_36$3={key:1},_hoisted_37$2={class:`confirm-repair-money-wrapper`},_hoisted_38$2={key:2},_hoisted_39$2={class:`confirm-repair-money-wrapper`},_sfc_main$218={__name:`RepairMain`,setup(__props){let{units}=useBridge();useComputerStore();let repairStore=useRepairStore(),selectedRepairOptionKey=ref(null),selectedRepairTimeOptionIndex=ref(1),currentRepairOption=computed(()=>!selectedRepairOptionKey.value||!repairStore.repairOptions?null:repairStore.repairOptions[selectedRepairOptionKey.value]),accidentForgivenessesText=computed(()=>!repairStore.repairOptions.insuranceRepairData.accidentForgivenesses>0?`(No Accident Forgivenesses left)`:`(`+repairStore.repairOptions.insuranceRepairData.accidentForgivenesses+` Accident Forgivenesses left)`),selectedRepairTimeOption=computed(()=>currentRepairOption.value?.repairTimeOptions?.choices?currentRepairOption.value.repairTimeOptions.choices.find(choice=>choice.id===selectedRepairTimeOptionIndex.value):null),renewsInFormatted=computed(()=>currentRepairOption.value?.renewsIn?units.buildString(`length`,currentRepairOption.value.renewsIn*1e3,0):``);watch(()=>repairStore.repairOptions,newOptions=>{if(newOptions&&Object.keys(newOptions).length>0&&!selectedRepairOptionKey.value){let selectedKey=Object.keys(newOptions).find(key=>newOptions[key].useInsurance)||Object.keys(newOptions)[0];selectedRepairOptionKey.value=selectedKey,newOptions[selectedKey]?.repairTimeOptions?.currentValueId&&(selectedRepairTimeOptionIndex.value=newOptions[selectedKey].repairTimeOptions.currentValueId)}},{immediate:!0}),watch(()=>selectedRepairOptionKey.value,newKey=>{newKey&&repairStore.repairOptions[newKey]?.repairTimeOptions?.currentValueId?selectedRepairTimeOptionIndex.value=repairStore.repairOptions[newKey].repairTimeOptions.currentValueId:selectedRepairTimeOptionIndex.value=1});let onRepairOptionClick=key=>{selectedRepairOptionKey.value=key},close=()=>{Lua_default.career_modules_insurance_repairScreen.closeMenu()},startRepair=(repairOptionKey,repairTimeOptionIndex)=>{selectedRepairTimeOption.value&&Lua_default.career_modules_insurance_repairScreen.startRepairInGarage(repairStore.vehicleData.invVehId,{repairTime:selectedRepairTimeOption.value.value,isInsuranceRepair:currentRepairOption.value.useInsurance,cost:{repairTimeCost:selectedRepairTimeOption.value.premiumInfluence,deductible:currentRepairOption.value.useInsurance?repairStore.repairOptions.insuranceRepairData.deductible:repairStore.vehicleData.damageCost}})};return onMounted(()=>{repairStore.getRepairData()}),onUnmounted(()=>{repairStore.resetStore()}),(_ctx,_cache)=>(openBlock(),createBlock(ComputerWrapper_default,{path:[`Repair`],title:`Repair ${unref(repairStore).vehicleData.name}`,back:``,onBack:close},{default:withCtx(()=>[unref(repairStore).vehicleData.name?(openBlock(),createBlock(unref(bngCard_default),{key:0,class:`repairMain blue-background`},{default:withCtx(()=>[createBaseVNode(`div`,_hoisted_1$195,[_cache[23]||=createBaseVNode(`div`,{class:`title`},`Vehicle Repair`,-1),createBaseVNode(`div`,_hoisted_2$158,[createVNode(unref(insuranceVehTile_default),{class:`vehicle-tile`,vehicle:unref(repairStore).vehicleData},{rightContent:withCtx(()=>[createBaseVNode(`div`,_hoisted_3$139,[createBaseVNode(`div`,_hoisted_4$115,[_cache[2]||=createBaseVNode(`span`,{class:`damage-estimate-text`},` Damage Estimate: `,-1),createBaseVNode(`span`,_hoisted_5$100,[createVNode(unref(bngUnit_default),{class:`red-price`,money:unref(repairStore).vehicleData.damageCost},null,8,[`money`])])]),unref(repairStore).vehicleData.isInsured?createCommentVNode(``,!0):(openBlock(),createElementBlock(`div`,_hoisted_6$83,[..._cache[3]||=[createBaseVNode(`span`,{class:`not-insured-text`},` Not Insured! `,-1)]]))])]),_:1},8,[`vehicle`])]),createBaseVNode(`div`,null,[_cache[7]||=createBaseVNode(`div`,{class:`repair-options-title`},`Repair Options`,-1),createBaseVNode(`div`,_hoisted_7$71,[(openBlock(!0),createElementBlock(Fragment,null,renderList(unref(repairStore).repairOptions,(repairOption,key)=>(openBlock(),createElementBlock(`div`,{key,class:normalizeClass([`repair-option`,{selected:selectedRepairOptionKey.value===key}]),onClick:$event=>onRepairOptionClick(key)},[createBaseVNode(`div`,_hoisted_9$52,[createVNode(unref(bngIcon_default),{type:repairOption.useInsurance?unref(icons).shieldCheckmark:unref(icons).wrench},null,8,[`type`])]),createBaseVNode(`div`,null,[repairOption.useInsurance?(openBlock(),createElementBlock(`div`,_hoisted_10$45,[_cache[5]||=createBaseVNode(`div`,{class:`bigger-text`},` Insurance Claim `,-1),createBaseVNode(`div`,_hoisted_11$40,toDisplayString(repairOption.insuranceName),1),createBaseVNode(`div`,_hoisted_12$30,[_cache[4]||=createTextVNode(` Deductible : `,-1),createVNode(unref(bngUnit_default),{class:`unit-no-padding`,money:unref(repairStore).repairOptions.insuranceRepairData.deductible},null,8,[`money`])])])):(openBlock(),createElementBlock(`div`,_hoisted_13$26,[..._cache[6]||=[createBaseVNode(`div`,{class:`bigger-text`},` Private Repair `,-1),createBaseVNode(`div`,{class:`smaller-text`},` No Policy Impact `,-1),createBaseVNode(`div`,{class:`bigger-text`},` Full Damage Cost `,-1)]]))])],10,_hoisted_8$58))),128))])]),currentRepairOption.value?(openBlock(),createElementBlock(`div`,_hoisted_14$25,[(openBlock(),createBlock(unref(coverageOption_default),{coverageOption:currentRepairOption.value.repairTimeOptions,key:`repairTime-${selectedRepairOptionKey.value}`,modelValue:selectedRepairTimeOptionIndex.value,"onUpdate:modelValue":_cache[0]||=$event=>selectedRepairTimeOptionIndex.value=$event,simpleSelect:!0,showPerkMode:`none`},null,8,[`coverageOption`,`modelValue`]))])):createCommentVNode(``,!0),createBaseVNode(`div`,_hoisted_15$24,[createBaseVNode(`div`,_hoisted_16$24,[_cache[13]||=createBaseVNode(`h3`,null,`Insurance Impact`,-1),createBaseVNode(`div`,_hoisted_17$19,[createBaseVNode(`span`,null,[_cache[8]||=createBaseVNode(`div`,{class:`item-label`},`Driver Score Change`,-1),currentRepairOption.value.useInsurance?(openBlock(),createElementBlock(`div`,_hoisted_18$17,toDisplayString(accidentForgivenessesText.value),1)):createCommentVNode(``,!0)]),createBaseVNode(`span`,{class:normalizeClass([`item-value`,{"red-text":currentRepairOption.value.useInsurance&&unref(repairStore).futureDriverScorestartRepair(selectedRepairOptionKey.value,selectedRepairTimeOptionIndex.value)},{default:withCtx(()=>[unref(repairStore).vehicleData.needsRepair?selectedRepairTimeOption.value?.canPay?(openBlock(),createElementBlock(`div`,_hoisted_38$2,[_cache[22]||=createTextVNode(` Confirm Repair `,-1),createBaseVNode(`div`,_hoisted_39$2,[createVNode(unref(bngUnit_default),{money:selectedRepairTimeOption.value?.totalPrice},null,8,[`money`])])])):(openBlock(),createElementBlock(`div`,_hoisted_36$3,[_cache[21]||=createTextVNode(` Insufficient funds `,-1),createBaseVNode(`div`,_hoisted_37$2,[createVNode(unref(bngUnit_default),{money:selectedRepairTimeOption.value?.totalPrice},null,8,[`money`])])])):(openBlock(),createElementBlock(`div`,_hoisted_35$3,` Vehicle doesn't need repair `))]),_:1},8,[`disabled`])])]),_:1})):createCommentVNode(``,!0)]),_:1},8,[`title`]))}},RepairMain_default=__plugin_vue_export_helper_default(_sfc_main$218,[[`__scopeId`,`data-v-19ad91be`]]),_hoisted_1$194={class:`awd-container bng-app`},_hoisted_2$157={key:0,class:`awd-table`},_hoisted_3$138={class:`data-name`},_sfc_main$217={__name:`app`,setup(__props,{expose:__expose}){let{$game}=useLibStore(),streamList=[`advancedWheelDebugData`],data=ref([]),hasData=computed(()=>Array.isArray(data.value)&&data.value.length>0),orderedData=computed(()=>Array.isArray(data.value)?data.value.sort((a$1,b)=>a$1.name.toLowerCase().localeCompare(b.name.toLowerCase())):[]);__expose({hasData}),onMounted(()=>{$game.streams.add(streamList),register()}),onUnmounted(()=>{$game.streams.remove(streamList),$game.api.activeObjectLua(`extensions.advancedwheeldebug.registerDebugUser("advancedWheelDebugApp", false)`)});let register=()=>$game.api.activeObjectLua(`extensions.advancedwheeldebug.registerDebugUser("advancedWheelDebugApp", true)`),format$2=value=>value?parseFloat(value).toFixed(3):``;return $game.events.on(`onStreamsUpdate`,streams=>data.value=streams.advancedWheelDebugData),$game.events.on(`VehicleReset`,register),$game.events.on(`VehicleChange`,register),(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$194,[orderedData.value&&orderedData.value.length>0?(openBlock(),createElementBlock(`table`,_hoisted_2$157,[_cache[0]||=createBaseVNode(`thead`,null,[createBaseVNode(`tr`,null,[createBaseVNode(`th`,null,`Name`),createBaseVNode(`th`,null,`Camber`),createBaseVNode(`th`,null,`Toe`),createBaseVNode(`th`,null,`Caster`),createBaseVNode(`th`,null,`SAI`)])],-1),(openBlock(!0),createElementBlock(Fragment,null,renderList(orderedData.value,w=>(openBlock(),createElementBlock(`tr`,null,[createBaseVNode(`td`,_hoisted_3$138,toDisplayString(w.name),1),createBaseVNode(`td`,null,toDisplayString(format$2(w.camber)),1),createBaseVNode(`td`,null,toDisplayString(format$2(w.toe)),1),createBaseVNode(`td`,null,toDisplayString(format$2(w.caster)),1),createBaseVNode(`td`,null,toDisplayString(format$2(w.sai)),1)]))),256))])):createCommentVNode(``,!0)]))}},app_default$2=__plugin_vue_export_helper_default(_sfc_main$217,[[`__scopeId`,`data-v-5eb5aaaa`]]),_hoisted_1$193={class:`legends-container`},TAG=`[beamng.apps:brakeTorqueGraph]`,_sfc_main$216={__name:`app`,setup(__props){let{$game}=useLibStore(),app$1=ref(null),canvas=ref(null),graphList=ref([]),streamsList$1=[`wheelInfo`,`electrics`],colors=[],chart=new SmoothieChart({minValue:0,millisPerPixel:20,interpolation:`linear`,grid:{fillStyle:`rgba(250, 250, 250, 0.8)`,strokeStyle:`rgba(0,0,0,0.3)`,verticalSections:6,millisPerLine:1e3,sharpLines:!0},labels:{fillStyle:`black`}}),speedGraph=new TimeSeries,appResizeObserver=new ResizeObserver(entries=>{let entry=entries[0];canvas.value.width=entry.target.offsetWidth,canvas.value.height=entry.target.offsetHeight}),graphs={},globalMax=2e3;onMounted(()=>{initColors(),initChart(),appResizeObserver.observe(app$1.value),graphList.value=[{title:`ui.apps.brake_torque_graph.speed`,color:colors[0]}],$game.streams.add(streamsList$1),$game.events.on(`onStreamsUpdate`,onStreamsUpdate),$game.events.on(`VehicleReset`,onVehicleReset),$game.events.on(`VehicleChange`,onVehicleChange)}),onBeforeUnmount(()=>{appResizeObserver.unobserve(app$1.value)}),onUnmounted(()=>{$game.events.off(`onStreamsUpdate`,onStreamsUpdate),$game.events.off(`VehicleReset`,onVehicleReset),$game.events.off(`VehicleChange`,onVehicleChange),$game.streams.remove(streamsList$1)});function onStreamsUpdate(streams){for(let stream of streamsList$1)if(!streams[stream])return;globalMax=Math.max(globalMax,streams.electrics.airspeed*15);let xPoint=new Date;for(let w in speedGraph.append(xPoint,streams.electrics.airspeed*15),streams.wheelInfo){let wheelName=streams.wheelInfo[w][0];if(!graphs.hasOwnProperty(wheelName)){graphs[wheelName]=new TimeSeries,logger_default.debug(`${TAG} adding graph for ${wheelName}`);let wheelColor=colors[graphList.value.length%colors.length];graphList.value.push({title:wheelName,color:wheelColor}),chart.addTimeSeries(graphs[wheelName],{strokeStyle:wheelColor,lineWidth:2});return}graphs[wheelName].append(xPoint,streams.wheelInfo[w][8]),globalMax=Math.max(globalMax,streams.wheelInfo[w][8])}chart.options.maxValue=globalMax}function onVehicleReset(data){graphs={},graphList.value=[{title:`Speed`,color:colors[0]}]}function onVehicleChange(data){graphs={},graphList.value=[{title:`Speed`,color:colors[0]}]}function initChart(){chart.addTimeSeries(speedGraph,{strokeStyle:colors[0],lineWidth:2}),chart.streamTo(canvas.value,40)}function initColors(){for(let i=15;i>0;i--){let c=rainbow(15,i);colors.push(`rgb(${Math.round(255*c[0])}, ${Math.round(255*c[1])}, ${Math.round(255*c[2])})`)}}return(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,{class:`btg-app`,ref_key:`app`,ref:app$1},[createBaseVNode(`div`,_hoisted_1$193,[(openBlock(!0),createElementBlock(Fragment,null,renderList(graphList.value,graph=>(openBlock(),createElementBlock(`small`,{class:`legend`,style:normalizeStyle({color:graph.color})},toDisplayString(_ctx.$t(graph.title)),5))),256))]),createBaseVNode(`canvas`,{ref_key:`canvas`,ref:canvas},null,512)],512))}},app_default$3=__plugin_vue_export_helper_default(_sfc_main$216,[[`__scopeId`,`data-v-642d2338`]]),_hoisted_1$192={class:`bus-line bng-app`},_hoisted_2$156={class:`header`},_hoisted_3$137={class:`time`},_hoisted_4$114={class:`logo`},_hoisted_5$99=[`src`],_hoisted_6$82={class:`route-id`},_hoisted_7$70={class:`text`},_hoisted_8$57={class:`destination`},_hoisted_9$51={key:0,class:`display-stops`},_hoisted_10$44={class:`title`},_hoisted_11$39={key:1,class:`next-stop`},_hoisted_12$29={class:`title`},defaultRouteId=`00`,defaultDestination=`Not in service`,defaultRouteColor=`#FFA200`,totalRoutesDisplayed=4,_sfc_main$215={__name:`app`,setup(__props){let{$game}=useLibStore(),timerInterval,navDisplay=reactive({time:``,stopRequested:!1}),localBusRoute=ref(null),routeId=computed(()=>localBusRoute.value&&localBusRoute.value.routeId?localBusRoute.value.routeId.substring(0,3):defaultRouteId),destination=computed(()=>localBusRoute.value&&localBusRoute.value.destination?localBusRoute.value.destination.substring(0,20):defaultDestination),routeColor=computed(()=>localBusRoute.value&&localBusRoute.value.routeColor?localBusRoute.value.routeColor:defaultRouteColor),stops=computed(()=>{if(!localBusRoute.value||!localBusRoute.value.stops)return null;let data=localBusRoute.value.stops.slice(0,-1);return data.length>totalRoutesDisplayed&&(data=data.slice(1).slice(0,totalRoutesDisplayed)),data.reverse()}),nextStop=computed(()=>localBusRoute.value&&localBusRoute.value.stops&&localBusRoute.value.stops.length-1>totalRoutesDisplayed?localBusRoute.value.stops[0]:null);onBeforeMount(()=>{updateTime(),timerInterval=setInterval(()=>{updateTime()},1e3)}),onMounted(()=>{$game.events.on(`BusDisplayUpdate`,onBusDisplayUpdate),$game.events.on(`SetStopRequest`,onSetStopRequest),$game.api.engineLua(`if scenario_busdriver then scenario_busdriver.requestState() end`)}),onUnmounted(()=>{clearInterval(timerInterval),$game.events.off(`BusDisplayUpdate`,onBusDisplayUpdate),$game.events.off(`SetStopRequest`,onSetStopRequest)});function onBusDisplayUpdate(data){console.log(`onBusDisplayUpdate`,data),localBusRoute.value?(localBusRoute.value.routeId=data.routeId,localBusRoute.value.stops=localBusRoute.value.stops.filter(x=>data.tasklist.find(y=>y[0]===x.id))):localBusRoute.value=parseBusData(data)}function onSetStopRequest(data){console.log(`onSetStopRequest`,data),data&&data.stopRequested!==null&&(navDisplay.stopRequested=data.stopRequested)}function updateTime(){let date=new Date;navDisplay.time=`${date.getHours()}:${date.getMinutes()<10?`0`+date.getMinutes():date.getMinutes()}`}function parseBusData(data){return{destination:data.direction,routeId:data.routeId,routeColor:data.routeColor,stops:data.tasklist.map(x=>({id:x[0],name:x[1]}))}}return(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$192,[createBaseVNode(`div`,{class:`content`,style:normalizeStyle({"--routeColor":routeColor.value})},[createBaseVNode(`div`,_hoisted_2$156,[createBaseVNode(`div`,_hoisted_3$137,toDisplayString(navDisplay.time),1),createBaseVNode(`div`,_hoisted_4$114,[createBaseVNode(`img`,{src:unref(getAssetURL)(`images/beamng_logo_50x50.png`)},null,8,_hoisted_5$99)])]),createBaseVNode(`div`,{class:normalizeClass([`route`,{highlight:!stops.value||stops.value.length===0}])},[createBaseVNode(`div`,_hoisted_6$82,[createBaseVNode(`span`,_hoisted_7$70,toDisplayString(routeId.value),1),_cache[0]||=createBaseVNode(`span`,{class:`chevron`},null,-1)]),createBaseVNode(`div`,_hoisted_8$57,toDisplayString(destination.value),1)],2),stops.value?(openBlock(),createElementBlock(`div`,_hoisted_9$51,[(openBlock(!0),createElementBlock(Fragment,null,renderList(stops.value,stop$1=>(openBlock(),createElementBlock(`div`,{class:`stop`,key:stop$1.id},[_cache[1]||=createBaseVNode(`div`,{class:`chevron`},null,-1),createBaseVNode(`div`,_hoisted_10$44,toDisplayString(stop$1.name),1)]))),128))])):createCommentVNode(``,!0),nextStop.value?(openBlock(),createElementBlock(`div`,_hoisted_11$39,[_cache[2]||=createBaseVNode(`div`,{class:`chevron`},null,-1),createBaseVNode(`div`,_hoisted_12$29,toDisplayString(nextStop.value.name),1)])):createCommentVNode(``,!0)],4),createBaseVNode(`div`,{class:normalizeClass([`stop-request`,{requested:navDisplay.stopRequested}])},[createBaseVNode(`div`,{class:normalizeClass([`text`,{glow:navDisplay.stopRequested}])},toDisplayString(_ctx.$t(`ui.busRoute.stopRequested`)),3)],2)]))}},app_default$4=__plugin_vue_export_helper_default(_sfc_main$215,[[`__scopeId`,`data-v-7731db49`]]),_hoisted_1$191={class:`bng-app cd-container`,layout:`column`,"layout-align":`center center`},_sfc_main$214={__name:`app`,setup(__props){let{$game}=useLibStore(),cameraDistance=ref(null);return onMounted(()=>{$game.api.engineLua(`extensions.load("ui_cameraDistanceApp")`)}),onUnmounted(()=>{$game.api.engineLua(`extensions.unload("ui_cameraDistanceApp")`)}),$game.events.on(`cameraDistance`,function(distance,errMsg){distance<0?cameraDistance.value=errMsg:cameraDistance.value=$game.units.buildString(`length`,distance,2)}),(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$191,[createBaseVNode(`span`,null,toDisplayString(cameraDistance.value),1)]))}},app_default$5=__plugin_vue_export_helper_default(_sfc_main$214,[[`__scopeId`,`data-v-d72a4879`]]),_hoisted_1$190={key:0,class:`bng-app thermal-clutch-debug`},_hoisted_2$155={class:`set-name`},_sfc_main$213={__name:`app`,setup(__props){let{$game}=useLibStore(),streamsList$1=[`clutchThermalData`],data=ref([]);onMounted(()=>{$game.streams.add(streamsList$1)}),onUnmounted(()=>{$game.streams.remove(streamsList$1)}),$game.events.on(`onStreamsUpdate`,streams=>{streams.clutchThermalData?data.value=parseData(streams.clutchThermalData):data.value=null});function parseData(data$1){return[{str:$game.units.buildString(`temperature`,data$1.clutchTemperature,0),name:`Clutch temperature`,warn:data$1.clutchTemperature>data$1.maxSafeTemp&&data$1.clutchTemperature<=data$1.efficiencyScaleEnd,error:data$1.clutchTemperature>data$1.efficiencyScaleEnd},{str:$game.units.buildString(`temperature`,data$1.maxSafeTemp,0),name:`Max safe temperature`},{str:$game.units.buildString(`temperature`,data$1.efficiencyScaleEnd,0),name:`Efficiency scale end`},{str:data$1.thermalEfficiency.toFixed(3),name:`Clutch efficiency`,warn:data$1.thermalEfficiency<1&&data$1.thermalEfficiency>=.5,error:data$1.thermalEfficiency<.5},{str:$game.units.buildString(`energy`,data$1.energyToClutch,0),name:`Q to clutch`},{str:$game.units.buildString(`energy`,data$1.energyClutchToBellHousing,0),name:`Q clutch to bell housing`}]}return(_ctx,_cache)=>data.value?(openBlock(),createElementBlock(`div`,_hoisted_1$190,[(openBlock(!0),createElementBlock(Fragment,null,renderList(data.value,(set,index)=>(openBlock(),createElementBlock(`div`,{key:index,class:`set`},[createBaseVNode(`div`,_hoisted_2$155,toDisplayString(set.name),1),createBaseVNode(`div`,{class:normalizeClass([`set-value`,{"thermal-warning":set.warn,"thermal-error":set.error}])},toDisplayString(set.str),3)]))),128))])):createCommentVNode(``,!0)}},app_default$6=__plugin_vue_export_helper_default(_sfc_main$213,[[`__scopeId`,`data-v-c0f00383`]]),_hoisted_1$189={width:`100%`,height:`100%`,viewBox:`0 0 244 244`},_hoisted_2$154=[`transform`],_sfc_main$212={__name:`app`,setup(__props){let streamsList$1=[`sensors`],{$game}=useLibStore(),arrow$3=ref(null),circle=ref(null),yawDegrees=ref(0),bbox=computed(()=>arrow$3.value?arrow$3.value.getBBox():null),rotateOrigin=computed(()=>bbox.value?`${yawDegrees.value} ${bbox.value.x+bbox.value.width/2} ${bbox.value.y+bbox.value.height/2}`:0);onMounted(()=>{$game.events.on(`onStreamsUpdate`,onStreamsUpdate),$game.streams.add(streamsList$1)}),onUnmounted(()=>{$game.events.off(`onStreamsUpdate`,onStreamsUpdate),$game.streams.remove(streamsList$1)});function onStreamsUpdate(streams){for(let stream of streamsList$1)if(!streams[stream])return;yawDegrees.value=streams.sensors.yaw*180/Math.PI+180}return(_ctx,_cache)=>(openBlock(),createElementBlock(`svg`,_hoisted_1$189,[createBaseVNode(`g`,{ref_key:`circle`,ref:circle,transform:`rotate(${rotateOrigin.value})`},[..._cache[0]||=[createStaticVNode(`NESW`,5)]],8,_hoisted_2$154),createBaseVNode(`path`,{d:`M122 90 L105 154 L139 154 Z`,ref_key:`arrow`,ref:arrow$3,class:`arrow`},null,512)]))}},app_default$7=__plugin_vue_export_helper_default(_sfc_main$212,[[`__scopeId`,`data-v-4a5918e7`]]),compassWidth=2e3,_sfc_main$211={__name:`app`,setup(__props){let streamsList$1=[`sensors`],{$game}=useLibStore(),app$1=ref(null),canvas=ref(null),osCanvas=ref(null),widthLess=computed(()=>(compassWidth-canvas.value.width)/2),appResizeObserver=new ResizeObserver(entries=>{let entry=entries[0];canvas.value.width=entry.target.offsetWidth,canvas.value.height=entry.target.offsetHeight});onMounted(()=>{initOsCanvas(),appResizeObserver.observe(app$1.value),$game.events.on(`onStreamsUpdate`,onStreamsUpdate),$game.streams.add(streamsList$1)}),onBeforeUnmount(()=>{appResizeObserver.unobserve(app$1.value)}),onUnmounted(()=>{$game.events.off(`onStreamsUpdate`,onStreamsUpdate),$game.streams.remove(streamsList$1)});function onStreamsUpdate(streams){for(let stream of streamsList$1)if(!streams[stream])return;let canvasCtx=canvas.value.getContext(`2d`);canvasCtx.clearRect(0,0,canvas.value.width,canvas.value.height),canvasCtx.fillStyle=`rgba(255,255,255,0.8)`,canvasCtx.strokeStyle=`rgba(255,255,255,0.6)`;let heading=streams.sensors.yaw,posX=heading*compassWidth/(2*Math.PI)-widthLess.value;canvasCtx.drawImage(osCanvas.value,posX,0),heading*compassWidth/(2*Math.PI)-widthLess.value>0?canvasCtx.drawImage(osCanvas.value,posX-compassWidth,0):posX+compassWidth(openBlock(),createElementBlock(`div`,{class:`container`,ref_key:`app`,ref:app$1},[createBaseVNode(`canvas`,{ref_key:`canvas`,ref:canvas,width:`280`,height:`56`},null,512),createBaseVNode(`canvas`,{ref_key:`osCanvas`,ref:osCanvas,class:`os-canvas`},null,512)],512))}},app_default$8=__plugin_vue_export_helper_default(_sfc_main$211,[[`__scopeId`,`data-v-e608df6a`]]),_hoisted_1$188={transform:`translate(-13.701535,-283.48656)`,style:{display:`inline`},id:`carGroup`},_hoisted_2$153={y:`255.49614`,x:`142.73175`,style:{"font-style":`normal`,"font-variant":`normal`,"font-weight":`normal`,"font-stretch":`normal`,"font-size":`18.66665649px`,"line-height":`1.25`,"font-family":`roboto`,"-inkscape-font-specification":`roboto`,"letter-spacing":`0px`,"word-spacing":`0px`,fill:`#ffffff`},"xml:space":`preserve`},componentDamageMap={body:{FL:{svgId:`bodyFL`,priority:2,tempDamage:!1},FR:{svgId:`bodyFR`,priority:2,tempDamage:!1},ML:{svgId:`bodyML`,priority:2,tempDamage:!1},MR:{svgId:`bodyMR`,priority:2,tempDamage:!1},RL:{svgId:`bodyRL`,priority:2,tempDamage:!1},RR:{svgId:`bodyRR`,priority:2,tempDamage:!1}},engine:{oilStarvation:{svgId:`engine`,priority:0,damageText:`Oil Starvation`,tempDamage:!0},coolantHot:{svgId:`engine`,priority:0,damageText:`Coolant Overheating`,tempDamage:!1},oilHot:{svgId:`engine`,priority:0,damageText:`Oil Overheating`,tempDamage:!1},pistonRingsDamaged:{svgId:`engine`,priority:0,damageText:`Piston Rings Damaged`,tempDamage:!1},rodBearingsDamaged:{svgId:`engine`,priority:0,damageText:`Rod Bearings Damaged`,tempDamage:!1},headGasketDamaged:{svgId:`engine`,priority:0,damageText:`Head Gasket Damaged`,tempDamage:!1},turbochargerHot:{svgId:`engine`,priority:0,damageText:`Turbocharger Overheating`,tempDamage:!1},engineIsHydrolocking:{svgId:`engine`,priority:0,damageText:`Engine is Hydrolocking`,tempDamage:!1},engineReducedTorque:{svgId:`engine`,priority:0,damageText:`Engine Torque Reduced`,tempDamage:!1},mildOverrevDamage:{svgId:`engine`,priority:0,damageText:`Mild Over Rev Damage`,tempDamage:!1},overRevDanger:{svgId:`engine`,priority:0,damageText:`Over Rev Risk`,tempDamage:!1},overTorqueDanger:{svgId:`engine`,priority:0,damageText:`Over Torque Risk`,tempDamage:!1},engineHydrolocked:{svgId:`engine`,priority:1,damageText:`Engine is Hydrolocked`,tempDamage:!1},engineDisabled:{svgId:`engine`,priority:1,damageText:`Engine Disabled`,tempDamage:!1},blockMelted:{svgId:`engine`,priority:1,damageText:`Block Melted`,tempDamage:!1},engineLockedUp:{svgId:`engine`,priority:1,damageText:`Engine Locked Up`,tempDamage:!1},radiatorLeak:{svgId:`radiator`,priority:1,damageText:`Radiator Leaking`,tempDamage:!1}},powertrain:{wheelaxleFL:{svgId:`wheelaxleFL`,priority:1,damageText:`Front Left Axle Broken`,tempDamage:!1},wheelaxleFR:{svgId:`wheelaxleFR`,priority:1,damageText:`Front Right Axle Broken`,tempDamage:!1},wheelaxleRL:{svgId:`wheelaxleRL`,priority:1,damageText:`Rear Left Axle Broken`,tempDamage:!1},wheelaxleRR:{svgId:`wheelaxleRR`,priority:1,damageText:`Rear Right Axle Broken`,tempDamage:!1},driveshaft:{svgId:`driveshaft`,priority:1,damageText:`Driveshaft Broken`,tempDamage:!1},driveshaft_F:{svgId:`driveshaft`,priority:1,damageText:`Front Driveshaft Broken`,tempDamage:!1},mainEngine:{svgId:`engine`,priority:1,damageText:`Engine Broken`,tempDamage:!1}},energyStorage:{mainTank:{svgId:`fueltank`,priority:1,damageText:`Fuel Tank Damaged`,tempDamage:!1}},wheels:{tireFL:{svgId:`tireFL`,priority:0,damageText:`Front Left Tire Burst`,tempDamage:!1},tireFR:{svgId:`tireFR`,priority:0,damageText:`Front Right Tire Burst`,tempDamage:!1},tireRL:{svgId:`tireRL`,priority:0,damageText:`Rear Left Tire Burst`,tempDamage:!1},tireRR:{svgId:`tireRR`,priority:0,damageText:`Rear Right Tire Burst`,tempDamage:!1},brakeFL:{svgId:`brakeFL`,priority:1,damageText:`FL Brake Damaged`,tempDamage:!1},brakeFR:{svgId:`brakeFR`,priority:1,damageText:`FR Brake Damaged`,tempDamage:!1},brakeRL:{svgId:`brakeRL`,priority:1,damageText:`RL Brake Damaged`,tempDamage:!1},brakeRR:{svgId:`brakeRR`,priority:1,damageText:`RR Brake Damaged`,tempDamage:!1},brakeOverHeatFL:{svgId:`brakeFL`,priority:0,damageText:`FL Brake Fading`,tempDamage:!0},brakeOverHeatFR:{svgId:`brakeFR`,priority:0,damageText:`FR Brake Fading`,tempDamage:!0},brakeOverHeatRL:{svgId:`brakeRL`,priority:0,damageText:`RL Brake Fading`,tempDamage:!0},brakeOverHeatRR:{svgId:`brakeRR`,priority:0,damageText:`RR Brake Fading`,tempDamage:!0},FL:{svgId:`tireFL`,priority:1,damageText:`Front Left Tire Broken`,tempDamage:!1},FR:{svgId:`tireFR`,priority:1,damageText:`Front Right Tire Broken`,tempDamage:!1},RL:{svgId:`tireRL`,priority:1,damageText:`Rear Left Tire Broken`,tempDamage:!1},RR:{svgId:`tireRR`,priority:1,damageText:`Rear Right Tire Broken`,tempDamage:!1}}},textDisplayTime=2e3,orangeColor=`rgba(255, 132, 0, 0.6)`,redColor=`rgba(255, 0, 0, 0.6)`,noDataColor=`rgba(0, 0, 0, 0 )`,streamsList=[`wheelThermalData`,`engineInfo`],_sfc_main$210={__name:`app`,setup(__props){let{$game}=useLibStore(),svg=ref(null),tireFL=ref(null),tireFR=ref(null),tireRL=ref(null),tireRR=ref(null),bodyFL=ref(null),bodyML=ref(null),bodyMR=ref(null),driveShaft=ref(null),engine=ref(null),fueltank=ref(null),radiator=ref(null),wheelaxleFL=ref(null),wheelaxleFR=ref(null),brakeFL=ref(null),brakeFR=ref(null),bodyFR=ref(null),bodyRL=ref(null),bodyRR=ref(null),brakeRL=ref(null),brakeRR=ref(null),wheelaxleRL=ref(null),wheelaxleRR=ref(null),damageContainer=ref(null),damageBox=ref(null),damageText=ref(null),appState=reactive({isAppDisplayed:!1,hasDamage:!1,permanentDamagedParts:0,isProcessingMessages:!1}),damageTextQueue=ref([]),componentDamage=ref({body:{FL:{damageDisplayed:!1,reference:bodyFL},FR:{damageDisplayed:!1,reference:bodyFR},ML:{damageDisplayed:!1,reference:bodyML},MR:{damageDisplayed:!1,reference:bodyMR},RL:{damageDisplayed:!1,reference:bodyRL},RR:{damageDisplayed:!1,reference:bodyRR}},engine:{oilStarvation:{damageDisplayed:!1,reference:engine},coolantHot:{damageDisplayed:!1,reference:engine},oilHot:{damageDisplayed:!1,reference:engine},pistonRingsDamaged:{damageDisplayed:!1,reference:engine},rodBearingsDamaged:{damageDisplayed:!1,reference:engine},headGasketDamaged:{damageDisplayed:!1,reference:engine},turbochargerHot:{damageDisplayed:!1,reference:engine},engineIsHydrolocking:{damageDisplayed:!1,reference:engine},engineReducedTorque:{damageDisplayed:!1,reference:engine},mildOverrevDamage:{damageDisplayed:!1,reference:engine},overRevDanger:{damageDisplayed:!1,reference:engine},overTorqueDanger:{damageDisplayed:!1,reference:engine},engineHydrolocked:{damageDisplayed:!1,reference:engine},engineDisabled:{damageDisplayed:!1,reference:engine},blockMelted:{damageDisplayed:!1,reference:engine},engineLockedUp:{damageDisplayed:!1,reference:engine},radiatorLeak:{damageDisplayed:!1,reference:radiator}},powertrain:{wheelaxleFL:{damageDisplayed:!1,reference:wheelaxleFL},wheelaxleFR:{damageDisplayed:!1,reference:wheelaxleFR},wheelaxleRL:{damageDisplayed:!1,reference:wheelaxleRL},wheelaxleRR:{damageDisplayed:!1,reference:wheelaxleRR},driveshaft:{damageDisplayed:!1,reference:driveShaft},driveshaft_F:{damageDisplayed:!1,reference:driveShaft},mainEngine:{damageDisplayed:!1,reference:engine}},energyStorage:{mainTank:{damageDisplayed:!1,reference:fueltank}},wheels:{tireFL:{damageDisplayed:!1,reference:tireFL},tireFR:{damageDisplayed:!1,reference:tireFR},tireRL:{damageDisplayed:!1,reference:tireRL},tireRR:{damageDisplayed:!1,reference:tireRR},brakeFL:{damageDisplayed:!1,reference:brakeFL},brakeFR:{damageDisplayed:!1,reference:brakeFR},brakeRL:{damageDisplayed:!1,reference:brakeRL},brakeRR:{damageDisplayed:!1,reference:brakeRR},brakeOverHeatFL:{damageDisplayed:!1,reference:brakeFL},brakeOverHeatFR:{damageDisplayed:!1,reference:brakeFR},brakeOverHeatRL:{damageDisplayed:!1,reference:brakeRL},brakeOverHeatRR:{damageDisplayed:!1,reference:brakeRR},FL:{damageDisplayed:!1,reference:tireFL},FR:{damageDisplayed:!1,reference:tireFR},RL:{damageDisplayed:!1,reference:tireRL},RR:{damageDisplayed:!1,reference:tireRR}}}),damageTimeout=ref(null),animTimeout=ref(null);onMounted(()=>{$game.events.on(`DamageData`,onDamageData),$game.events.on(`VehicleReset`,onReset),$game.events.on(`VehicleChange`,onReset),$game.events.on(`VehicleFocusChanged`,onVehicleFocusChanged),$game.streams.add(streamsList)}),onUnmounted(()=>{$game.events.off(`DamageData`,onDamageData),$game.events.off(`VehicleReset`,onReset),$game.events.off(`VehicleChange`,onReset),$game.events.off(`VehicleFocusChanged`,onVehicleFocusChanged),$game.streams.remove(streamsList)});function onDamageData(data){for(let type in data)for(let component in data[type]){if(componentDamageMap[type]===void 0||componentDamageMap[type][component]===void 0)continue;let damagedComponent=componentDamage.value[type][component],damageComponentProps=componentDamageMap[type][component];if(!damagedComponent.damageDisplayed&&(data[type][component]===!0||data[type][component]>0)){if(damageComponentProps.priority===1)appState.permanentDamagedParts+=1,clearTimeout(damageTimeout.value),setComponentDamageStyles(damagedComponent.reference,redColor,`flashAnim`);else if(damageComponentProps.priority===0)appState.permanentDamagedParts+=1,clearTimeout(damageTimeout.value),setComponentDamageStyles(damagedComponent.reference,orangeColor,`flashAnim`);else if(damageComponentProps.priority===2){let damageAmount=Math.round(data[type][component]*1e3),bodyColor=`rgba(${150+damageAmount}, ${150-damageAmount}, 0, 0.6)`;setComponentDamageStyles(damagedComponent.reference,bodyColor,``)}appState.hasDamage=!0,damageComponentProps.damageText!==void 0&&(damageTextQueue.value.push(damageComponentProps.damageText),damagedComponent.damageDisplayed=!0)}else damageComponentProps.tempDamage&&(data[type][component]===!0||data[type][component]>0?setComponentDamageStyles(damagedComponent.reference,orangeColor,`flashAnim`):(damagedComponent.damageDisplayed=!1,appState.permanentDamagedParts=-1,setComponentDamageStyles(damagedComponent.reference,noDataColor,``)))}!appState.isAppDisplayed&&appState.hasDamage&&(appState.isAppDisplayed=!0,processDamageText(),appState.permanentDamagedParts===0?showAppTimed():clearTimeout(damageTimeout.value))}function processDamageText(){damageTextQueue.value&&damageTextQueue.value.length>0?(damageContainer.value.style.opacity=1,damageText.value.textContent=damageTextQueue.value[0],damageTextQueue.value.splice(0,1),animTimeout.value=setTimeout(processDamageText,textDisplayTime)):(damageContainer.value.style.opacity=0,damageText.value.textContent=``,clearTimeout(animTimeout.value))}function onReset(){for(let type in componentDamage.value)for(let component in componentDamage.value[type])componentDamage.value[type][component].reference.style.fill=noDataColor;appState.isAppDisplayed=!1,appState.hasDamage=!1,appState.permanentDamagedParts=0,damageTextQueue.value=[],showAppTimed()}function onVehicleFocusChanged(data){data.mode===!0&&onReset()}function showAppTimed(){damageTimeout.value&&clearTimeout(damageTimeout.value),appState.isAppDisplayed=!0,damageTimeout.value=setTimeout(function(){appState.isAppDisplayed=!1},2700)}function setComponentDamageStyles(componentRef,color,anim){componentRef.style.fill=color,anim===``?componentRef.classList=[]:componentRef.classList.add(anim)}return(_ctx,_cache)=>(openBlock(),createElementBlock(`svg`,{ref_key:`svg`,ref:svg,class:`svg-app`,viewBox:`-20 -50 300 527`,style:normalizeStyle({opacity:appState.isAppDisplayed?1:0})},[createBaseVNode(`g`,_hoisted_1$188,[createBaseVNode(`path`,{ref_key:`tireFL`,ref:tireFL,d:`m 40.219516,385.93366 0.0893,-35.49107 c 0,0 0.44642,-5.22322 5.08928,-5.22322 4.64286,0 22.41072,-0.13394 22.41072,-0.13394 0,0 5.44643,-10e-6 5.49107,5.22321 0.0534,6.25041 -0.0447,34.64286 -0.0447,34.64286 l 0.0893,36.25 c 0,0 -0.0446,5.35714 -5.53571,5.44643 -3.12586,0.0508 -21.47322,-10e-6 -21.47322,-10e-6 0,0 -5.98214,10e-6 -6.02678,-5.3125 -0.0375,-4.46412 -0.0893,-35.40178 -0.0893,-35.40178 z`,style:{fill:`none`,"fill-rule":`evenodd`,stroke:`#000000`,"stroke-width":`1px`,"stroke-linecap":`butt`,"stroke-linejoin":`miter`,"stroke-opacity":`1`}},null,512),createBaseVNode(`path`,{style:{fill:`none`,"fill-rule":`evenodd`,stroke:`#000000`,"stroke-width":`1px`,"stroke-linecap":`butt`,"stroke-linejoin":`miter`,"stroke-opacity":`1`},d:`m 212.19799,385.43366 0.0893,-35.49107 c 0,0 0.44642,-5.22322 5.08928,-5.22322 4.64286,0 22.41072,-0.13394 22.41072,-0.13394 0,0 5.44643,-10e-6 5.49107,5.22321 0.0534,6.25041 -0.0447,34.64286 -0.0447,34.64286 l 0.0893,36.25 c 0,0 -0.0446,5.35714 -5.53571,5.44643 -3.12586,0.0508 -21.47322,-10e-6 -21.47322,-10e-6 0,0 -5.98214,10e-6 -6.02678,-5.3125 -0.0375,-4.46412 -0.0893,-35.40178 -0.0893,-35.40178 z`,ref_key:`tireFR`,ref:tireFR},null,512),createBaseVNode(`path`,{ref_key:`tireRR`,ref:tireRR,d:`m 212.19799,654.14795 0.0893,-35.49107 c 0,0 0.44642,-5.22322 5.08928,-5.22322 4.64286,0 22.41072,-0.13394 22.41072,-0.13394 0,0 5.44643,-10e-6 5.49107,5.22321 0.0534,6.25041 -0.0447,34.64286 -0.0447,34.64286 l 0.0893,36.25 c 0,0 -0.0446,5.35714 -5.53571,5.44643 -3.12586,0.0508 -21.47322,-10e-6 -21.47322,-10e-6 0,0 -5.98214,10e-6 -6.02678,-5.3125 -0.0375,-4.46412 -0.0893,-35.40178 -0.0893,-35.40178 z`,style:{fill:`none`,"fill-rule":`evenodd`,stroke:`#000000`,"stroke-width":`1px`,"stroke-linecap":`butt`,"stroke-linejoin":`miter`,"stroke-opacity":`1`}},null,512),createBaseVNode(`path`,{style:{fill:`none`,"fill-rule":`evenodd`,stroke:`#000000`,"stroke-width":`1px`,"stroke-linecap":`butt`,"stroke-linejoin":`miter`,"stroke-opacity":`1`},d:`m 40.219516,654.14795 0.0893,-35.49107 c 0,0 0.44642,-5.22322 5.08928,-5.22322 4.64286,0 22.41072,-0.13394 22.41072,-0.13394 0,0 5.44643,-10e-6 5.49107,5.22321 0.0534,6.25041 -0.0447,34.64286 -0.0447,34.64286 l 0.0893,36.25 c 0,0 -0.0446,5.35714 -5.53571,5.44643 -3.12586,0.0508 -21.47322,-10e-6 -21.47322,-10e-6 0,0 -5.98214,10e-6 -6.02678,-5.3125 -0.0375,-4.46412 -0.0893,-35.40178 -0.0893,-35.40178 z`,ref_key:`tireRL`,ref:tireRL},null,512),createBaseVNode(`path`,{ref_key:`bodyFL`,ref:bodyFL,d:`m 139.30351,268.73244 c 0,0 -20.06962,-0.0115 -32.7295,1.35397 -11.849388,1.27802 -23.33457,5.11217 -35.698872,11.89174 -11.963689,6.55991 -22.259598,16.59274 -27.506842,31.58729 -3.060137,8.74465 -3.902495,25.39725 -3.902495,25.39725 l 9.609942,-0.14814 c 0,0 1.636978,-16.52695 5.208997,-24.93149 3.978738,-9.3615 11.635356,-19.52025 21.213285,-24.53523 10.627835,-5.56471 18.689453,-8.01564 32.759185,-10.2291 11.61143,-1.82671 31.13813,-1.14019 31.13813,-1.14019 z`,style:{fill:`none`,"fill-rule":`evenodd`,stroke:`#000000`,"stroke-width":`1px`,"stroke-linecap":`butt`,"stroke-linejoin":`miter`,"stroke-opacity":`1`}},null,512),createBaseVNode(`path`,{ref_key:`bodyML`,ref:bodyML,d:`m 46.365238,434.85859 c 0,0 -4.37766,0.0905 -6.56641,0.125 -0.0234,2.215 -0.08,17.90873 -0.125,26.86328 0,0 -20.45068,7.80958 -22.22461,10.85938 -1.79329,3.0831 -4.63644,8.09161 -2.46289,8.46094 0,0 25.14091,-3.55661 25.60352,-3.40821 0.0618,2.25563 -0.62153,126.52252 -0.59375,127.77539 1.21285,-0.002 9.6289,0.0312 9.6289,0.0312 l -0.01,-170.70703 z`,style:{fill:`none`,"fill-rule":`evenodd`,stroke:`#000000`,"stroke-width":`1px`,"stroke-linecap":`butt`,"stroke-linejoin":`miter`,"stroke-opacity":`1`}},null,512),createBaseVNode(`path`,{ref_key:`bodyMR`,ref:bodyMR,d:`m 236.6054,434.90159 -0.0117,170.70899 c 0,0 7.91605,-0.0352 9.1289,-0.0332 0.0278,-1.25287 -0.65555,-125.51976 -0.59375,-127.77539 0.46261,-0.1484 25.60352,3.40821 25.60352,3.40821 2.17355,-0.36933 -0.6696,-5.37589 -2.46289,-8.45899 -1.77393,-3.0498 -22.22266,-10.85937 -22.22266,-10.85937 -0.045,-8.95456 -0.10355,-24.64828 -0.12695,-26.86328 -2.18875,-0.0345 -9.31447,-0.12697 -9.31447,-0.12697 z`,style:{fill:`none`,"fill-rule":`evenodd`,stroke:`#000000`,"stroke-width":`1px`,"stroke-linecap":`butt`,"stroke-linejoin":`miter`,"stroke-opacity":`1`}},null,512),createBaseVNode(`path`,{ref_key:`driveShaft`,ref:driveShaft,d:`m 146.88019,519.13977 0.34682,-126.1992 c 0,0 14.81582,-18.06715 -4.26439,-17.94569 -19.92,0.12681 -4.95719,17.95354 -4.95719,17.95354 l 0.0408,126.25385 c -0.48292,33.8145 0.52349,126.53492 0.52349,126.53492 -3.70809,6.93305 -6.96405,16.59296 4.6368,16.4848 11.45601,-0.10682 8.66714,-8.10662 4.65438,-16.55312 -1.97544,-4.15814 -0.98066,-126.5291 -0.98066,-126.5291 z`,style:{fill:`none`,"fill-rule":`evenodd`,stroke:`#000000`,"stroke-width":`0.99999976`,"stroke-linecap":`butt`,"stroke-linejoin":`miter`,"stroke-miterlimit":`4`,"stroke-dasharray":`none`,"stroke-opacity":`1`}},null,512),createBaseVNode(`path`,{ref_key:`engine`,ref:engine,d:`m 122.07373,314.95322 h 33.63152 v 5.9272 h -13.25677 v 5.34505 h 12.93926 l 6.08594,9.31416 h 5.37155 v 4.97461 h 6.00656 v -5.05399 h 8.22927 c 0,0 2.66605,2.98563 3.2282,4.8423 1.71505,5.66443 1.56492,12.04739 0,17.75512 -0.61276,2.23494 -3.54572,5.98011 -3.54572,5.98011 h -7.93821 v -5.39797 h -6.29763 v 11.32517 h -34.98103 l -6.50934,-7.93822 H 113.0771 v -16.51145 h -5.98011 v 15.87643 h -5.1863 v -28.89508 h 4.97462 v 7.62066 h 6.29764 v -7.72651 h 8.99664 v -5.98013 h 14.12999 v -6.19179 h -14.23585 z`,style:{display:`inline`,fill:`none`,"fill-rule":`evenodd`,stroke:`#000000`,"stroke-width":`1.00000012`,"stroke-linecap":`butt`,"stroke-linejoin":`miter`,"stroke-miterlimit":`4`,"stroke-dasharray":`none`,"stroke-opacity":`1`}},null,512),createBaseVNode(`path`,{d:`m 117.17264,721.33809 -7.7414,-9.05075 c 0,0 -1.6874,1.50785 -2.481,2.29715 -0.685,0.6814 -1.3051,1.5911 0.2757,3.6525 0.5444,0.7098 3.2227,3.9338 3.7903,4.5024 1.6325,1.6355 2.5754,1.6201 3.3309,1.0108 0.9517,-0.7675 2.8255,-2.4121 2.8255,-2.4121 z m -5.4902,-9.02777 c -0.2639,-0.33031 -0.3782,-0.42184 0.023,-0.78103 0.2875,-0.31046 1.9506,-1.87788 2.2512,-2.13637 0.2218,-0.19078 0.3561,-0.42492 0.1149,-0.7236 -0.2412,-0.33308 -2.1908,-2.68012 -2.4982,-3.06097 -0.2198,-0.27232 -0.2732,-0.32108 -0.2732,-0.50554 0,-0.75917 0.011,-34.43177 0.015,-35.00437 0,-0.2149 0.056,-0.3086 0.5162,-0.3086 h 51.67845 c 2.0683,0 3.0251,0.3486 4.3679,1.4435 1.1871,0.9678 2.1659,2.0917 2.17,4.6095 0,0 0.065,37.07605 0.065,38.41705 0,1.2398 -0.1967,4.1364 -1.6325,5.5294 -1.0614,1.0299 -3.8532,1.8924 -4.9438,1.8924 -1.5414,0 -37.80368,-0.016 -38.25553,-0.016 -0.32906,0 -0.70707,-0.079 -0.93514,-0.3163 -0.27185,-0.2826 -2.9151,-3.0777 -3.22317,-3.371 -0.15862,-0.151 -0.25989,-0.4548 -0.64972,-0.097 -0.3899,0.3574 -1.73649,1.4573 -2.04669,1.7218 -0.1403,0.1197 -0.2841,0.2357 -0.5523,-0.032 -0.4136,-0.4769 -5.8261,-6.80285 -6.191,-7.25968 z m 20.26835,-10.96158 c -0.003,-4.55255 -0.0326,-8.19817 0,-12.74562 0,-0.7695 -0.32724,-0.97794 -1.30987,-1.85445 -0.76302,-0.68063 -1.41614,-1.23286 -1.90915,-1.69336 -0.36587,-0.34178 -0.85706,-0.80537 -0.84008,-1.1791 0.0258,-0.56967 0.59396,-1.0422 0.93428,-1.21472 0.54578,-0.27667 0.94727,-0.0528 1.23375,0.23366 0.30382,0.30381 1.84818,1.77993 2.58906,2.39496 0.44759,0.37156 0.58562,0.67733 1.67741,0.67733 5.46749,-0.0217 12.23023,-0.18415 18.32732,0 1.09189,0 1.22992,-0.30577 1.67737,-0.67733 0.74089,-0.61503 2.28521,-2.09115 2.58911,-2.39496 0.2865,-0.28643 0.688,-0.51033 1.2338,-0.23366 0.3404,0.17252 0.9085,0.64505 0.9344,1.21472 0.017,0.37373 -0.4743,0.83732 -0.8402,1.1791 -0.493,0.4605 -1.1461,1.01273 -1.909,1.69336 -0.98279,0.87651 -1.30997,1.08495 -1.30997,1.85445 0,4.55255 0.0323,8.19817 0,12.74562 0,0.76951 0.32718,0.97793 1.30997,1.85447 0.7629,0.68062 1.416,1.23285 1.909,1.69335 0.3659,0.34177 0.857,0.80537 0.8402,1.1791 -0.026,0.56967 -0.594,1.04219 -0.9344,1.21472 -0.5458,0.27667 -0.9473,0.0528 -1.2338,-0.23366 -0.3039,-0.30382 -1.84822,-1.77992 -2.58911,-2.39497 -0.44745,-0.37154 -0.58548,-0.67731 -1.67737,-0.67731 -6.55155,0.019 -11.82218,0.18501 -18.32732,0 -1.09179,0 -1.22982,0.30577 -1.67741,0.67731 -0.74088,0.61505 -2.28524,2.09115 -2.58906,2.39497 -0.28648,0.28644 -0.68797,0.51033 -1.23375,0.23366 -0.34032,-0.17253 -0.90842,-0.64505 -0.93428,-1.21472 -0.017,-0.37373 0.47421,-0.83733 0.84008,-1.1791 0.49301,-0.4605 1.14613,-1.01273 1.90915,-1.69335 0.98263,-0.87654 1.30987,-1.08496 1.30987,-1.85447 z m 2.56799,-10.35082 c 0,2.40538 0,5.36454 0,8.01339 0,0.63296 -0.0236,1.4238 0.45482,1.90048 0.45132,0.44967 1.08277,0.42233 1.81926,0.42233 h 13.2426 c 0.7365,0 1.36798,0.0273 1.81926,-0.42233 0.47837,-0.47668 0.45477,-1.26752 0.45477,-1.90048 v -3.94714 c 0,-1.35542 0,-2.71084 0,-4.06625 0,-0.63296 0.0233,-1.42381 -0.45477,-1.90047 -0.45128,-0.44969 -1.08276,-0.42234 -1.81926,-0.42234 h -13.2426 c -0.73649,0 -1.36794,-0.0273 -1.81926,0.42234 -0.47842,0.47666 -0.45482,1.26751 -0.45482,1.90047 z`,style:{fill:`none`,"fill-opacity":`1`,"fill-rule":`evenodd`,stroke:`#000000`,"stroke-width":`1.00000012`,"stroke-linecap":`butt`,"stroke-linejoin":`miter`,"stroke-miterlimit":`4`,"stroke-dasharray":`none`,"stroke-opacity":`1`},ref_key:`fueltank`,ref:fueltank},null,512),createBaseVNode(`path`,{d:`m 162.19586,303.74311 v 1.62868 c 0,0 -0.0239,0.60243 0.40384,0.86252 0.36641,0.22282 3.17759,0.31545 3.59707,-0.042 0.34847,-0.29691 0.34658,-0.78069 0.34658,-0.78069 v -4.32093 c 0,0 -0.004,-0.63642 -0.53018,-0.91858 -0.27049,-0.14492 -2.81926,2.15048 -3.22871,2.49847 -0.49791,0.42318 -0.5886,0.94557 -0.5886,0.94557 z m -8.74296,-2.37979 v 4.00847 c 0,0 -0.0239,0.60243 0.40383,0.86252 0.36641,0.22282 3.17759,0.31545 3.59708,-0.042 0.34846,-0.29691 0.34657,-0.78069 0.34657,-0.78069 v -3.43014 c 0,0 -0.004,-0.63642 -0.53018,-0.91857 -0.27049,-0.14493 -2.94617,-0.75348 -3.2287,-0.64521 -0.61019,0.23381 -0.5886,0.94557 -0.5886,0.94557 z m -8.57375,1.15667 v 2.8518 c 0,0 -0.0239,0.60243 0.40383,0.86252 0.36641,0.22282 3.17759,0.31545 3.59708,-0.042 0.34846,-0.29691 0.34657,-0.78069 0.34657,-0.78069 v -3.78911 c 0,0 -0.002,-0.37799 -0.24416,-0.68051 -0.072,-0.09 -0.16527,-0.17335 -0.28602,-0.23806 -0.27049,-0.14492 -2.94617,0.76217 -3.2287,0.87043 -0.61019,0.23381 -0.5886,0.94557 -0.5886,0.94557 z m -8.63016,2.23357 v 0.61823 c 0,0 -0.0239,0.60243 0.40383,0.86252 0.36642,0.22282 3.17759,0.31545 3.59707,-0.042 0.34847,-0.29691 0.34658,-0.78069 0.34658,-0.78069 v -1.35611 c 0,0 -0.004,-0.63641 -0.53017,-0.91857 -0.2705,-0.14492 -2.94617,0.56274 -3.22871,0.671 -0.61019,0.23381 -0.5886,0.94557 -0.5886,0.94557 z m -8.50835,1.48075 c 0.36641,0.22282 3.17758,0.31545 3.59707,-0.042 0.34847,-0.29691 0.34658,-0.50066 0.34658,-0.50066 0,0 -0.004,-1.03528 -0.53018,-1.31744 -0.27049,-0.14492 -2.94617,-0.0851 -3.22871,0.0232 -0.61018,0.23381 -0.5886,1.10014 -0.5886,1.10014 0,0 -0.0239,0.47668 0.40384,0.73676 z m -9.0904,-2.1588 v 1.29628 c 0,0 -0.0239,0.60243 0.40383,0.86252 0.36642,0.22282 3.17759,0.31545 3.59707,-0.042 0.34847,-0.29691 0.34658,-0.78069 0.34658,-0.78069 v -0.5584 c 0,0 -0.004,-0.63642 -0.53017,-0.91858 -0.2705,-0.14492 -2.94617,-0.91301 -3.22871,-0.80474 -0.61019,0.23381 -0.5886,0.94556 -0.5886,0.94556 z m 52.345,1.37742 v -16.61221 c 0,0 -0.0239,-0.60242 0.40383,-0.86252 0.36642,-0.22281 3.17759,-0.31544 3.59707,0.042 0.34847,0.29692 0.34658,0.78069 0.34658,0.78069 v 16.63216 c 0,0 -0.004,0.63642 -0.53017,0.91857 -0.2705,0.14493 -2.94617,0.1552 -3.22871,0.0469 -0.61019,-0.23381 -0.5886,-0.94556 -0.5886,-0.94556 z m -8.79938,-16.61221 c 0,0 -0.0239,-0.60242 0.40384,-0.86252 0.36641,-0.22281 3.17759,-0.31544 3.59707,0.042 0.34847,0.29692 0.34658,0.78069 0.34658,0.78069 v 3.32029 c 0,0 -0.004,0.63641 -0.53018,0.91857 -0.27049,0.14492 -2.60773,-2.10106 -3.22871,-2.63237 -0.4965,-0.42482 -0.5886,-0.97378 -0.5886,-0.97378 z m -8.74296,0 c 0,0 -0.0239,-0.60242 0.40383,-0.86252 0.36641,-0.22281 3.17759,-0.31544 3.59708,0.042 0.34846,0.29692 0.34657,0.78069 0.34657,0.78069 v 1.74529 c 0,0 -0.004,0.63642 -0.53018,0.91857 -0.27049,0.14493 -2.94617,-0.12683 -3.2287,-0.2351 -0.61019,-0.23381 -0.5886,-0.77636 -0.5886,-0.77636 z m -8.57375,0 c 0,0 -0.0239,-0.60242 0.40383,-0.86252 0.36641,-0.22281 3.17759,-0.31544 3.59708,0.042 0.34846,0.29692 0.34657,0.78069 0.34657,0.78069 v 1.80688 c 0,0 -0.002,0.378 -0.24416,0.68052 -0.072,0.09 -0.16527,0.17335 -0.28602,0.23805 -0.27049,0.14493 -2.94617,1.1141 -3.2287,1.00584 -0.61019,-0.23381 -0.5886,-0.81866 -0.5886,-0.81866 z m -8.63016,0 c 0,0 -0.0239,-0.60242 0.40383,-0.86252 0.36642,-0.22281 3.17759,-0.31544 3.59707,0.042 0.34847,0.29692 0.34658,0.78069 0.34658,0.78069 v 4.46516 c 0,0 -0.004,0.63641 -0.53017,0.91857 -0.2705,0.14493 -2.94617,0.97309 -3.22871,0.86482 -0.61019,-0.23381 -0.6027,-0.81866 -0.6027,-0.81866 z m -8.91219,0 c 0,0 -0.0239,-0.60242 0.40384,-0.86252 0.36641,-0.22281 3.17758,-0.31544 3.59707,0.042 0.34847,0.29692 0.34658,0.78069 0.34658,0.78069 v 6.04004 c 0,0 -0.004,0.63641 -0.53018,0.91857 -0.27049,0.14493 -2.94617,-0.0986 -3.22871,-0.2069 -0.61018,-0.23381 -0.5886,-0.90327 -0.5886,-0.90327 z m -8.68656,4.20791 v -4.20791 c 0,0 -0.0239,-0.60242 0.40383,-0.86252 0.36642,-0.22281 3.17759,-0.31544 3.59707,0.042 0.34847,0.29692 0.34658,0.78069 0.34658,0.78069 v 4.90473 c 0,0 -0.004,0.63641 -0.53017,0.91857 -0.2705,0.14492 -2.94617,-0.52168 -3.22871,-0.62994 -0.61019,-0.23382 -0.5886,-0.94557 -0.5886,-0.94557 z m 0.0383,3.38266 0.0424,3.80682 c 4.76147,1.58463 12.44208,1.37115 18.62715,0.76876 4.9084,-0.47805 9.46499,-3.13968 14.38678,-3.45098 2.56844,-0.16246 7.67481,0.84058 7.67481,0.84058 l 0.018,4.52569 c 0,0 4.30181,-3.85868 6.85434,-6.08209 0.23182,-0.21672 0.26026,-0.28202 -0.0588,-0.61036 -2.4793,-2.37833 -6.8878,-6.08125 -6.8878,-6.08125 l 0.0141,4.90206 c 0,0 -5.19129,-1.89571 -12.24908,-0.16859 -3.96245,1.32729 -6.76872,2.21825 -10.27188,2.769 -2.7191,0.42749 -5.4997,0.55723 -8.24775,0.4009 -3.33921,-0.18995 -6.69491,-0.50286 -9.90211,-1.62054 z m -15.25121,10.1713 c 0,0.39543 -0.18036,1.62226 1.45209,3.25472 1.40638,1.19302 2.9727,1.1712 3.41028,1.1712 23.19944,0.0992 44.97243,0.0226 68.7019,0 0.43758,0 2.0039,0.0218 3.41029,-1.1712 1.63245,-1.63246 1.45208,-2.85929 1.45208,-3.25472 0.12422,-16.06162 0.0264,-3.05893 0,-19.25937 0,-0.39543 0.18037,-1.62225 -1.45208,-3.25471 -1.40639,-1.19302 -2.97271,-1.1712 -3.41029,-1.1712 -23.19944,-0.0992 -44.97243,-0.0226 -68.7019,0 -0.43758,0 -2.0039,-0.0218 -3.41028,1.1712 -1.63245,1.63246 -1.45209,2.85928 -1.45209,3.25471 -0.11802,17.21566 -0.0338,3.97954 0,19.25937 z m 1.90997,-17.51991 c 0,-0.36657 -0.12323,-2.09175 1.14118,-3.35617 1.05214,-0.89259 3.06543,-0.74668 3.48144,-0.74668 22.55947,-0.021 43.30609,-0.0919 65.36168,0 1.3185,0 2.52269,-0.19776 3.66518,0.74727 1.05732,1.05732 0.95743,2.19932 0.95743,3.35558 0.0252,15.01782 0.11812,0.8913 0,15.78046 0,1.5229 -0.0428,2.46913 -0.90102,3.32738 -1.06456,0.88061 -2.31847,0.77547 -3.72159,0.77547 -22.55947,0.021 -43.30609,0.0919 -65.36168,0 -1.7721,0 -2.45712,0.11664 -3.44156,-0.68686 -1.36393,-1.36393 -1.18106,-1.95258 -1.18106,-3.41599 0.12429,-15.20955 -0.092,-2.68107 0,-15.78046 z m 4.56001,16.37025 v -16.61221 c 0,0 -0.0239,-0.60242 0.40383,-0.86252 0.36641,-0.22281 3.1776,-0.31544 3.59708,0.042 0.34846,0.29692 0.34658,0.78069 0.34658,0.78069 v 16.63216 c 0,0 -0.004,0.63642 -0.53019,0.91857 -0.27048,0.14493 -2.94617,0.1552 -3.2287,0.0469 -0.61019,-0.23381 -0.5886,-0.94556 -0.5886,-0.94556 z`,style:{display:`inline`,fill:`none`,"fill-opacity":`1`,"fill-rule":`evenodd`,stroke:`#000000`,"stroke-width":`0.75000012`,"stroke-linecap":`butt`,"stroke-linejoin":`miter`,"stroke-miterlimit":`4`,"stroke-dasharray":`none`,"stroke-opacity":`1`},ref_key:`radiator`,ref:radiator},null,512),createBaseVNode(`path`,{ref_key:`wheelaxleFL`,ref:wheelaxleFL,d:`m 91.691145,389.0121 c 0,0 -2.43068,0.29676 -2.43068,-4.28053 0,-4.0406 2.22866,-4.30576 2.22866,-4.30576 9.222155,-0.11908 21.694875,-0.0585 30.917405,-0.0594 3.70837,-9.1e-4 6.85841,-0.28274 8.24298,0.90893 0.51207,0.44072 0.75871,1.92799 1.01166,3.17533 0.35371,1.74427 0.74974,2.96105 0.32477,3.71154 -0.50969,0.90009 -2.57006,0.96141 -2.57006,0.96141 -11.49186,0.003 -26.23329,-0.0229 -37.724735,-0.11152 z`,style:{display:`inline`,opacity:`1`,fill:`none`,"fill-rule":`evenodd`,stroke:`#000000`,"stroke-width":`1px`,"stroke-linecap":`butt`,"stroke-linejoin":`miter`,"stroke-opacity":`1`}},null,512),createBaseVNode(`path`,{style:{display:`inline`,opacity:`1`,fill:`none`,"fill-rule":`evenodd`,stroke:`#000000`,"stroke-width":`1px`,"stroke-linecap":`butt`,"stroke-linejoin":`miter`,"stroke-opacity":`1`},d:`m 193.49174,389.0121 c 0,0 2.43068,0.29676 2.43068,-4.28053 0,-4.0406 -2.22865,-4.30576 -2.22865,-4.30576 -9.22216,-0.11908 -21.44488,-0.0585 -30.66742,-0.0594 -3.70837,-9.1e-4 -6.85841,-0.28274 -8.24298,0.90893 -0.51207,0.44072 -0.75871,1.92799 -1.01166,3.17533 -0.35371,1.74427 -0.74974,2.96105 -0.32477,3.71154 0.50969,0.90009 2.57006,0.96141 2.57006,0.96141 11.49186,0.003 25.98329,-0.0229 37.47474,-0.11152 z`,ref_key:`wheelaxleFR`,ref:wheelaxleFR},null,512),createBaseVNode(`path`,{ref_key:`brakeFR`,ref:brakeFR,d:`m 210.35279,373.43366 h -5.22322 l -0.0446,-11.25 c 0,0 -0.0446,-1.02679 -1.51786,-1.16071 -0.91518,-0.15626 -3.83928,-0.067 -3.83928,-0.067 0,0 -2.04238,-0.11866 -2.0759,1.22768 -0.0626,2.51339 -0.0446,47.43304 -0.0446,47.43304 0,0 -0.0431,1.36663 1.7634,1.40625 1.21935,0.0262 3.83928,0.005 3.83928,0.005 0,0 1.86958,0.12132 1.96428,-1.61256 0.073,-1.33729 -0.0207,-10.46221 -0.0207,-10.46221 l 5.24395,-0.12581 z`,style:{display:`inline`,opacity:`1`,fill:`none`,"fill-opacity":`1`,"fill-rule":`evenodd`,stroke:`#000000`,"stroke-width":`1px`,"stroke-linecap":`butt`,"stroke-linejoin":`miter`,"stroke-opacity":`1`}},null,512),createBaseVNode(`path`,{ref_key:`brakeFL`,ref:brakeFL,d:`m 74.826658,373.43366 h 5.22322 l 0.0446,-11.25 c 0,0 0.0446,-1.02679 1.51786,-1.16071 0.91518,-0.15626 3.83928,-0.067 3.83928,-0.067 0,0 2.04238,-0.11866 2.0759,1.22768 0.0626,2.51339 0.0446,47.43304 0.0446,47.43304 0,0 0.0431,1.36663 -1.7634,1.40625 -1.21935,0.0262 -3.83928,0.005 -3.83928,0.005 0,0 -1.86958,0.12132 -1.96428,-1.61256 -0.073,-1.33729 0.0207,-10.46221 0.0207,-10.46221 l -5.24395,-0.12581 z`,style:{display:`inline`,opacity:`1`,fill:`none`,"fill-opacity":`1`,"fill-rule":`evenodd`,stroke:`#000000`,"stroke-width":`1px`,"stroke-linecap":`butt`,"stroke-linejoin":`miter`,"stroke-opacity":`1`}},null,512),createBaseVNode(`path`,{style:{fill:`none`,"fill-rule":`evenodd`,stroke:`#000000`,"stroke-width":`1px`,"stroke-linecap":`butt`,"stroke-linejoin":`miter`,"stroke-opacity":`1`},d:`m 145.98404,268.73244 c 0,0 19.06962,-0.0115 31.7295,1.35397 11.84939,1.27802 23.33457,5.11217 35.69887,11.89174 11.96369,6.55991 22.2596,16.59274 27.50684,31.58729 3.06014,8.74465 3.9025,25.39725 3.9025,25.39725 l -9.60995,-0.14814 c 0,0 -1.63697,-16.52695 -5.20899,-24.93149 -3.97874,-9.3615 -11.63536,-19.52025 -21.21329,-24.53523 -10.62783,-5.56471 -18.68945,-8.01564 -32.75918,-10.2291 -11.61143,-1.82671 -30.13813,-1.14019 -30.13813,-1.14019 z`,ref_key:`bodyFR`,ref:bodyFR},null,512),createBaseVNode(`path`,{style:{fill:`none`,"fill-rule":`evenodd`,stroke:`#000000`,"stroke-width":`1.00000012`,"stroke-linecap":`butt`,"stroke-linejoin":`miter`,"stroke-miterlimit":`4`,"stroke-dasharray":`none`,"stroke-opacity":`1`},d:`m 139.36946,758.05809 c 0,0 -20.14699,0.01 -32.81319,-1.1024 -11.855294,-1.0405 -23.346203,-4.162 -35.716671,-9.6818 -11.969654,-5.3407 -20.679708,-11.5646 -25.929569,-23.7724 -3.061663,-7.1197 -5.495432,-24.34913 -5.495432,-24.34913 l 9.614735,0.12066 c 0,0 1.637794,15.18257 5.211595,22.02527 3.980722,7.6218 11.817934,15.0086 21.40064,19.0916 10.633134,4.5306 18.345219,5.9957 32.421962,7.798 11.61723,1.487 31.39781,0.9282 31.39781,0.9282 z`,ref_key:`bodyRL`,ref:bodyRL},null,512),createBaseVNode(`path`,{ref_key:`bodyRR`,ref:bodyRR,d:`m 145.99795,758.05809 c 0,0 19.59077,0.01 32.25697,-1.1024 11.8553,-1.0405 23.34621,-4.162 35.71668,-9.6818 11.96965,-5.3407 20.67971,-11.5646 25.92957,-23.7724 3.06166,-7.1197 5.49543,-24.34913 5.49543,-24.34913 l -9.61473,0.12066 c 0,0 -1.6378,15.18257 -5.2116,22.02527 -3.98072,7.6218 -11.81793,15.0086 -21.40064,19.0916 -10.63314,4.5306 -18.34522,5.9957 -32.42197,7.798 -11.61723,1.487 -30.84159,0.9282 -30.84159,0.9282 z`,style:{fill:`none`,"fill-rule":`evenodd`,stroke:`#000000`,"stroke-width":`1.00000012`,"stroke-linecap":`butt`,"stroke-linejoin":`miter`,"stroke-miterlimit":`4`,"stroke-dasharray":`none`,"stroke-opacity":`1`}},null,512),createBaseVNode(`path`,{style:{display:`inline`,opacity:`1`,fill:`none`,"fill-rule":`evenodd`,stroke:`#000000`,"stroke-width":`1.00000012`,"stroke-linecap":`butt`,"stroke-linejoin":`miter`,"stroke-miterlimit":`4`,"stroke-dasharray":`none`,"stroke-opacity":`1`},d:`m 75.326658,641.12409 h 5.22322 l 0.0446,-11.25 c 0,0 0.0446,-1.02679 1.51786,-1.16071 0.91518,-0.15626 3.83928,-0.067 3.83928,-0.067 0,0 2.04238,-0.11866 2.0759,1.22768 0.0626,2.51339 0.0446,47.43304 0.0446,47.43304 0,0 0.0431,1.36663 -1.7634,1.40625 -1.21935,0.0262 -3.83928,0.005 -3.83928,0.005 0,0 -1.86958,0.12132 -1.96428,-1.61256 -0.073,-1.33729 0.0207,-10.46221 0.0207,-10.46221 l -5.24395,-0.12581 z`,ref_key:`brakeRL`,ref:brakeRL},null,512),createBaseVNode(`path`,{ref_key:`brakeRR`,ref:brakeRR,d:`m 209.87792,642.37917 h -5.22322 l -0.0446,-11.25 c 0,0 -0.0446,-1.02679 -1.51786,-1.16071 -0.91518,-0.15626 -3.83928,-0.067 -3.83928,-0.067 0,0 -2.04238,-0.11866 -2.0759,1.22768 -0.0626,2.51339 -0.0446,47.43304 -0.0446,47.43304 0,0 -0.0431,1.36663 1.7634,1.40625 1.21935,0.0262 3.83928,0.005 3.83928,0.005 0,0 1.86958,0.12132 1.96428,-1.61256 0.073,-1.33729 -0.0207,-10.46221 -0.0207,-10.46221 l 5.24395,-0.12581 z`,style:{display:`inline`,opacity:`1`,fill:`none`,"fill-rule":`evenodd`,stroke:`#000000`,"stroke-width":`1.00000012`,"stroke-linecap":`butt`,"stroke-linejoin":`miter`,"stroke-miterlimit":`4`,"stroke-dasharray":`none`,"stroke-opacity":`1`}},null,512),createBaseVNode(`path`,{style:{display:`inline`,opacity:`1`,fill:`none`,"fill-rule":`evenodd`,stroke:`#000000`,"stroke-width":`1.00000012`,"stroke-linecap":`butt`,"stroke-linejoin":`miter`,"stroke-miterlimit":`4`,"stroke-dasharray":`none`,"stroke-opacity":`1`},d:`m 92.206308,649.46453 c 0,0 -2.43068,-0.29676 -2.43068,4.28053 0,4.0406 2.22866,4.30576 2.22866,4.30576 9.222162,0.11908 21.444882,0.0585 30.667412,0.0594 3.70837,9.1e-4 8.80295,0.28274 10.18752,-0.90893 0.51207,-0.44072 0.6941,-2.38196 0.90117,-3.66147 0.26289,-1.62435 0.42635,-2.41047 0.26953,-3.25855 -0.21138,-1.14316 -2.40433,-0.92826 -2.40433,-0.92826 -12.14004,-6.2e-4 -27.27967,0.0179 -39.419282,0.11152 z`,ref_key:`wheelaxleRL`,ref:wheelaxleRL},null,512),createBaseVNode(`path`,{ref_key:`wheelaxleRR`,ref:wheelaxleRR,d:`m 192.84519,649.46453 c 0,0 2.43068,-0.29676 2.43068,4.28053 0,4.0406 -2.22866,4.30576 -2.22866,4.30576 -9.22216,0.11908 -20.31988,0.0585 -29.54242,0.0594 -3.70837,9.1e-4 -8.80295,0.28274 -10.18752,-0.90893 -0.51207,-0.44072 -0.6941,-2.38196 -0.90117,-3.66147 -0.26289,-1.62435 -0.42635,-2.41047 -0.26953,-3.25855 0.21138,-1.14316 2.40433,-0.92826 2.40433,-0.92826 12.14004,-6.2e-4 26.15468,0.0179 38.29429,0.11152 z`,style:{display:`inline`,opacity:`1`,fill:`none`,"fill-rule":`evenodd`,stroke:`#000000`,"stroke-width":`1.00000012`,"stroke-linecap":`butt`,"stroke-linejoin":`miter`,"stroke-miterlimit":`4`,"stroke-dasharray":`none`,"stroke-opacity":`1`}},null,512),createBaseVNode(`g`,{style:{opacity:`0`},ref_key:`damageContainer`,ref:damageContainer},[createBaseVNode(`rect`,{style:{opacity:`0.77399998`,fill:`#3e3e3e`,"stroke-width":`1.99999893`,"stroke-miterlimit":`4`,"stroke-dasharray":`none`,"stroke-dashoffset":`0`},ref_key:`damageBox`,ref:damageBox,width:`206.75557`,height:`28.991379`,x:`39.481575`,y:`234.25491`},null,512),_cache[0]||=createBaseVNode(`path`,{style:{opacity:`1`,fill:`none`,stroke:`#ffffff`,"stroke-width":`1.99999893`,"stroke-linecap":`butt`,"stroke-linejoin":`miter`,"stroke-miterlimit":`4`,"stroke-dasharray":`none`,"stroke-opacity":`1`},d:`m 39.48159,263.2463 206.75556,-2e-5`},null,-1),createBaseVNode(`text`,_hoisted_2$153,[createBaseVNode(`tspan`,{ref_key:`damageText`,ref:damageText,style:{"text-align":`center`,"text-anchor":`middle`,fill:`#ffffff`},y:`255.49614`,x:`142.73175`},` Driveshaft Broken `,512)])],512)])],4))}},app_default$9=__plugin_vue_export_helper_default(_sfc_main$210,[[`__scopeId`,`data-v-f6aa177d`]]),_hoisted_1$187={class:`timeslip`,id:`slip`},_hoisted_2$152={class:`paper`},_hoisted_3$136={class:`header`},_hoisted_4$113={class:`table-wrapper`},_hoisted_5$98={class:`custom-table`},_hoisted_6$81={class:`left-align`},_hoisted_7$69={class:`right-align`},_hoisted_8$56={class:`right-align`},_hoisted_9$50={key:0},_hoisted_10$43={class:`right-align`},_hoisted_11$38={class:`right-align`},_hoisted_12$28={class:`header`},_hoisted_13$25={class:`left`},_hoisted_14$24={class:`right`},_hoisted_15$23={class:`name`},_hoisted_16$23={key:0,class:`rewards`},_hoisted_17$18={class:`reward`},_hoisted_18$16={class:`header`},_hoisted_19$13={key:0},_sfc_main$209={__name:`Timeslip`,props:{slip:Object},setup(__props){let{units}=useBridge(),props=__props,TIMER_ROWS_INFO=[{key:`laneName`,label:`Lane`},{key:null,label:``},{key:`dial`,label:`DIAL`},{key:`reactionTime`,label:`R/T`},{key:`time_60`,label:`60'`},{key:`time_330`,label:`330'`},{key:`time_1_8`,label:`1/8`},{key:`velAt_1_8_kmh`,label:`KM/H`},{key:`velAt_1_8_mph`,label:`MPH`},{key:`time_1000`,label:`1000'`},{key:`time_1_4`,label:`1/4`},{key:`velAt_1_4_kmh`,label:`KM/H`},{key:`velAt_1_4_mph`,label:`MPH`},{key:`dialDiff`,label:`DIFF`}],getRacerByLane=laneNum=>props.slip.racerInfos.find(racer=>racer.laneNum===laneNum),getTimerValue=(laneNum,timerKey)=>{let racer=getRacerByLane(laneNum);if(!racer)return`-`;if(timerKey===null)return``;if(timerKey===`laneName`)return racer.lane||`-`;if(timerKey===`dial`){if(props.slip.dragType!==`bracketRace`)return`-`;let racer$1=getRacerByLane(laneNum);if(!racer$1)return`-`;let value=racer$1.timers.dial;if(value==null)return`-`;let num=parseFloat(value);return isNaN(num)?`-`:num.toFixed(3)}if(timerKey===`dialDiff`){if(props.slip.dragType!==`bracketRace`)return`-`;let racer$1=getRacerByLane(laneNum);if(!racer$1)return`-`;let value=racer$1.dialDiff;return value==null?`-`:formatDialDiff(value)}if(timerKey.includes(`velAt_`)){if(timerKey.includes(`_kmh`)){let baseKey=timerKey.replace(`_kmh`,``);return racer.velocities[baseKey+`_km/h`]||`-`}else if(timerKey.includes(`_mph`)){let baseKey=timerKey.replace(`_mph`,``);return racer.velocities[baseKey+`_mph`]||`-`}}return racer.timers[timerKey]||`-`},formatDialDiff=value=>{if(value===`-`)return`-`;let num=parseFloat(value);return isNaN(num)?`-`:(num>0?`+`:``)+num.toFixed(3)},getWinnerResult=laneNum=>{let racer=getRacerByLane(laneNum);if(!racer)return`-`;if(racer.disqualification)return`DQ`;if(props.slip.racerInfos.length===1)return`-`;let otherRacer=getRacerByLane(laneNum===1?2:1);if(!otherRacer)return`-`;if(otherRacer.disqualification)return`WINNER`;if(props.slip.dragType===`bracketRace`){let thisDiff=parseFloat(racer.dialDiff),otherDiff=parseFloat(otherRacer.dialDiff);return thisDiff===otherDiff?`TIE`:thisDiff>0&&otherDiff>0?thisDiffotherDiff?`WINNER`:`Break Out`}else{let thisTime=parseFloat(racer.finalTime),otherTime=parseFloat(otherRacer.finalTime);return thisTime>otherTime?`+${(thisTime-otherTime).toFixed(3)}`:`WINNER`}};return(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$187,[_cache[3]||=createBaseVNode(`div`,{class:`rip reverse top`},null,-1),createBaseVNode(`div`,_hoisted_2$152,[createBaseVNode(`div`,_hoisted_3$136,[(openBlock(!0),createElementBlock(Fragment,null,renderList(__props.slip.stripInfo,info=>(openBlock(),createElementBlock(`div`,{key:info},toDisplayString(_ctx.$tt(info)),1))),128))]),createBaseVNode(`div`,_hoisted_4$113,[createBaseVNode(`table`,_hoisted_5$98,[createBaseVNode(`tbody`,null,[(openBlock(),createElementBlock(Fragment,null,renderList(TIMER_ROWS_INFO,(rowInfo,rowIndex)=>createBaseVNode(`tr`,{key:`timer-`+rowIndex,class:normalizeClass({"quarter-mile-row":rowInfo.key===`time_1_4`})},[createBaseVNode(`td`,_hoisted_6$81,toDisplayString(rowInfo.label),1),createBaseVNode(`td`,_hoisted_7$69,toDisplayString(getTimerValue(2,rowInfo.key)),1),createBaseVNode(`td`,_hoisted_8$56,toDisplayString(getTimerValue(1,rowInfo.key)),1)],2)),64)),__props.slip.racerInfos.length>1?(openBlock(),createElementBlock(`tr`,_hoisted_9$50,[_cache[0]||=createBaseVNode(`td`,{class:`left-align`},null,-1),createBaseVNode(`td`,_hoisted_10$43,toDisplayString(getWinnerResult(2)),1),createBaseVNode(`td`,_hoisted_11$38,toDisplayString(getWinnerResult(1)),1)])):createCommentVNode(``,!0)])])]),(openBlock(!0),createElementBlock(Fragment,null,renderList(__props.slip.racerInfos,racer=>(openBlock(),createElementBlock(`div`,{key:racer.name,class:`racer`},[createBaseVNode(`div`,_hoisted_12$28,[createBaseVNode(`div`,_hoisted_13$25,toDisplayString(racer.lane),1),createBaseVNode(`div`,_hoisted_14$24,toDisplayString(racer.licenseText),1)]),createBaseVNode(`div`,_hoisted_15$23,toDisplayString(racer.name),1),Object.keys(racer.rewards).length===0?createCommentVNode(``,!0):(openBlock(),createElementBlock(`div`,_hoisted_16$23,[_cache[1]||=createTextVNode(` Rewards... `,-1),(openBlock(!0),createElementBlock(Fragment,null,renderList(racer.rewards,reward=>(openBlock(),createElementBlock(`div`,_hoisted_17$18,[createTextVNode(toDisplayString(reward)+` BMRA-XP `,1),createVNode(unref(bngIcon_default),{class:`reward-icon`,type:unref(icons).wheelOutline,color:`black`},null,8,[`type`])]))),256)),_cache[2]||=createBaseVNode(`template`,null,[createTextVNode(` ... `)],-1)]))]))),128)),createBaseVNode(`div`,_hoisted_18$16,[createBaseVNode(`div`,null,toDisplayString(unref(units).buildString(`temperature`,__props.slip.env.tempC,1,`c`))+` / `+toDisplayString(unref(units).buildString(`temperature`,__props.slip.env.tempC,1,`f`)),1),__props.slip.env.customGrav?(openBlock(),createElementBlock(`div`,_hoisted_19$13,toDisplayString(_ctx.$tt(`ui.environment.gravity`))+`: `+toDisplayString(__props.slip.env.gravity),1)):createCommentVNode(``,!0)])]),_cache[4]||=createBaseVNode(`div`,{class:`rip bottom`},null,-1)]))}},Timeslip_default=__plugin_vue_export_helper_default(_sfc_main$209,[[`__scopeId`,`data-v-4b627404`]]),_hoisted_1$186={key:0,class:`bng-app`,id:`container`},_hoisted_2$151={class:`slide`},_sfc_main$208={__name:`app`,setup(__props){let{$game}=useLibStore(),slip=ref({});onMounted(()=>{$game.events.on(`onDragRaceTimeslipData`,onDragRaceTimeslipData)}),onUnmounted(()=>{$game.events.off(`onDragRaceTimeslipData`,onDragRaceTimeslipData)});function onDragRaceTimeslipData(rawData){slip.value=rawData,rawData&&(console.log(rawData),Lua_default.Engine.Audio.playOnce(`AudioGui`,`event:>UI>Missions>Timeslip`))}let screenshot=function(){Lua_default.gameplay_drag_dragBridge.screenshotTimeslip()},clear=function(){slip.value=null};return(_ctx,_cache)=>slip.value&&slip.value.stripInfo?(openBlock(),createElementBlock(`div`,_hoisted_1$186,[createBaseVNode(`div`,_hoisted_2$151,[createVNode(Timeslip_default,{slip:slip.value,save:``,clear:``},null,8,[`slip`]),createVNode(unref(bngIcon_default),{class:`clear`,type:unref(icons).trashBin1,onClick:clear},null,8,[`type`]),createVNode(unref(bngIcon_default),{class:`save`,type:unref(icons).floppyDisk,onClick:screenshot},null,8,[`type`])])])):createCommentVNode(``,!0)}},app_default$10=__plugin_vue_export_helper_default(_sfc_main$208,[[`__scopeId`,`data-v-84d60911`]]),_hoisted_1$185={key:0},_hoisted_2$150={class:`lights-container`},_hoisted_3$135={class:`circles-wrapper`},_hoisted_4$112={class:`stage-circle`},_hoisted_5$97={class:`stage-top`},_hoisted_6$80={class:`stage-middle`},_hoisted_7$68={class:`stage-bottom`},_hoisted_8$55={class:`circles-wrapper`},_hoisted_9$49={class:`circles-wrapper`},_hoisted_10$42={class:`circles-wrapper`},_hoisted_11$37={class:`circles-wrapper`},_sfc_main$207={__name:`Treelights`,setup(__props){let events$3=useEvents(),isStaging=ref(!1),stageLights=ref([{stageLights:{prestageLight:!1,stageLight:!1},countDownLights:{amberLight1:!1,amberLight2:!1,amberLight3:!1,greenLight:!1,redLight:!1},globalLights:{blueLight:!1}}]),updateLights=changes=>{changes.stageLights&&(stageLights.value[0].stageLights={...stageLights.value[0].stageLights,...changes.stageLights}),changes.countDownLights&&(stageLights.value[0].countDownLights={...stageLights.value[0].countDownLights,...changes.countDownLights},(changes.countDownLights.greenLight||changes.countDownLights.redLight)&&setTimeout(()=>{isStaging.value=!1},2e3))},updateStaging=isNearby=>{isStaging.value=isNearby};return onMounted(()=>{events$3.on(`updateTreeLightApp`,updateLights),events$3.on(`updateTreeLightStaging`,updateStaging)}),onUnmounted(()=>{events$3.off(`updateTreeLightApp`,updateLights),events$3.off(`updateTreeLightStaging`,updateStaging)}),(_ctx,_cache)=>isStaging.value.valueOf==0?createCommentVNode(``,!0):(openBlock(),createElementBlock(`div`,_hoisted_1$185,[createBaseVNode(`div`,_hoisted_2$150,[createBaseVNode(`div`,_hoisted_3$135,[createBaseVNode(`div`,{class:normalizeClass([`light-circle black`,{blue:stageLights.value[0].globalLights.blueLight,red:stageLights.value[0].countDownLights.redLight}])},[withDirectives(createBaseVNode(`div`,_hoisted_4$112,[withDirectives(createBaseVNode(`div`,_hoisted_5$97,[..._cache[0]||=[createStaticVNode(``,1)]],512),[[vShow,stageLights.value[0].stageLights.prestageLight]]),withDirectives(createBaseVNode(`div`,_hoisted_6$80,[..._cache[1]||=[createStaticVNode(``,1)]],512),[[vShow,stageLights.value[0].stageLights.prestageLight&&stageLights.value[0].stageLights.stageLight]]),withDirectives(createBaseVNode(`div`,_hoisted_7$68,[..._cache[2]||=[createStaticVNode(``,1)]],512),[[vShow,stageLights.value[0].stageLights.stageLight]])],512),[[vShow,!stageLights.value[0].countDownLights.redLight]])],2)]),createBaseVNode(`div`,_hoisted_8$55,[createBaseVNode(`div`,{class:normalizeClass([`light-circle black`,{amber:stageLights.value[0].countDownLights.amberLight1,red:stageLights.value[0].countDownLights.redLight}])},null,2)]),createBaseVNode(`div`,_hoisted_9$49,[createBaseVNode(`div`,{class:normalizeClass([`light-circle black`,{amber:stageLights.value[0].countDownLights.amberLight2,red:stageLights.value[0].countDownLights.redLight}])},null,2)]),createBaseVNode(`div`,_hoisted_10$42,[createBaseVNode(`div`,{class:normalizeClass([`light-circle black`,{amber:stageLights.value[0].countDownLights.amberLight3,red:stageLights.value[0].countDownLights.redLight}])},null,2)]),createBaseVNode(`div`,_hoisted_11$37,[createBaseVNode(`div`,{class:normalizeClass([`light-circle black go`,{green:stageLights.value[0].countDownLights.greenLight,red:stageLights.value[0].countDownLights.redLight}])},null,2)])])]))}},Treelights_default=__plugin_vue_export_helper_default(_sfc_main$207,[[`__scopeId`,`data-v-c2ff1007`]]),_sfc_main$206={__name:`bngModifierTiles`,props:{modifierActionInfos:{type:Object,required:!0}},setup(__props){let{isControllerUsed}=storeToRefs(controls_default()),props=__props,controllerActions=computed(()=>{let mod1Active=props.modifierActionInfos.customModifier1?.active,mod2Active=props.modifierActionInfos.customModifier2?.active,mod1Disabled=props.modifierActionInfos.customModifier1?.disabled,mod2Disabled=props.modifierActionInfos.customModifier2?.disabled,mod1modifier2Disabled=props.modifierActionInfos.modifier1modifier2?.disabled;return[{actions:[{actionName:`customModifier2`}],active:!mod2Disabled&&mod2Active&&!mod1Active,disabled:mod2Disabled},{actions:[{actionName:`customModifier2`},{actionName:`customModifier1`}],active:!mod1modifier2Disabled&&mod1Active&&mod2Active,disabled:mod1modifier2Disabled},{actions:[{actionName:`customModifier1`}],active:!mod1Disabled&&mod1Active&&!mod2Active,disabled:mod1Disabled}]}),kbmActions=computed(()=>{props.modifierActionInfos.shift?.active;let ctrlActive=props.modifierActionInfos.ctrl?.active!==void 0,altActive=props.modifierActionInfos.alt?.active!==void 0;return[{active:ctrlActive,actions:[{actionName:`kbmModifier1`,device:`keyboard0`,deviceKey:`ctrl`}]},{active:altActive,actions:[{actionName:`kbmModifier3`,device:`keyboard0`,deviceKey:`alt`}]}]}),entries=computed(()=>isControllerUsed.value?controllerActions.value:kbmActions.value),getModifierClass=entry=>{let cls=`modifier-tile`;return entry.active&&(cls+=` active`),entry.disabled&&(cls+=` disabled`),cls};return(_ctx,_cache)=>(openBlock(!0),createElementBlock(Fragment,null,renderList(entries.value,entry=>(openBlock(),createElementBlock(`div`,{class:normalizeClass(getModifierClass(entry))},[(openBlock(!0),createElementBlock(Fragment,null,renderList(entry.actions,(action,actionIdx)=>(openBlock(),createElementBlock(`div`,{key:actionIdx},[actionIdx>0?(openBlock(),createBlock(unref(bngIcon_default),{key:0,type:`mathPlus`})):createCommentVNode(``,!0),createVNode(unref(bngBinding_default),{action:action.actionName,device:action.device,"device-key":action.deviceKey,"show-unassigned":!1},null,8,[`action`,`device`,`device-key`])]))),128))],2))),256))}},bngModifierTiles_default=__plugin_vue_export_helper_default(_sfc_main$206,[[`__scopeId`,`data-v-ea01b9d8`]]),_hoisted_1$184={key:0,class:`bng-app-binding-display`},_hoisted_2$149={key:0,class:`modifier-bindings`},_hoisted_3$134={class:`label-column`},_hoisted_4$111={key:0,class:`label-text`},_hoisted_5$96={class:`binding-column`},_hoisted_6$79={class:`flexible-area`},_hoisted_7$67={class:`label-column`},_hoisted_8$54={key:0,class:`label-text`},_hoisted_9$48={class:`binding-column`},_hoisted_10$41={key:0,class:`tile-flex`},_hoisted_11$36={key:1,class:`bottom-left-group`},_sfc_main$205={__name:`bngAppBindingDisplay`,setup(__props){let events$3=useEvents(),actions=shallowRef([]),tileActions=shallowRef([]),constantActions=shallowRef([]),modifierActionInfos=shallowRef([]),additionalData=shallowRef({}),isFaded=ref(!1),isHovered=ref(!1),mouseDownAction=ref(``),actionOpacity=ref(1),fadeOutTimeout=null,isFadingOut=ref(!1),showApp=ref(!0),tileRefs=ref([]),isWide=ref([]),narrowSpan=ref(4),setActions=data=>{let newActions=Array.isArray(data.actions)?data.actions:[];showApp.value=data.showApp,constantActions.value=Array.isArray(data.constantActions)?data.constantActions:[],modifierActionInfos.value=data.modifierActionInfos?{...data.modifierActionInfos}:{},additionalData.value=data.additionalData?{...data.additionalData}:{},fadeOutTimeout&&(clearTimeout(fadeOutTimeout),fadeOutTimeout=null,isFadingOut.value=!1),actions.value.length>0&&newActions.length===0?(isFadingOut.value=!0,actionOpacity.value=0,fadeOutTimeout=setTimeout(()=>{actions.value=newActions,actionOpacity.value=1,isFadingOut.value=!1,fadeOutTimeout=null},0)):newActions.length>0&&actions.value.length===0?(actions.value=newActions,actionOpacity.value=0,nextTick(()=>{actionOpacity.value=1})):(actions.value=newActions,actionOpacity.value=1),tileActions.value=actions.value.filter(action=>action.icon),actions.value=actions.value.filter(action=>!action.icon)},getActionClass=(action,isConstant)=>{let cls=`binding-row`;return isConstant?cls+=` is-constant`:isFadingOut.value&&(cls+=` is-fading-out`),!action.onClick&&!action.inputActionOnClick&&(cls+=` no-hover`),action.highlighted&&(cls+=` highlighted`),cls},onActionClickDown=action=>{action.onClick?runRaw(action.onClick):action.inputActionOnClick&&(mouseDownAction.value=action.action,Lua_default.ui_bindingsLegend.triggerInputAction(action.action,1))},onMouseEnter=()=>{isHovered.value=!0},onMouseLeave=()=>{isHovered.value=!1},onGlobalMouseUp=event=>{mouseDownAction.value&&=(Lua_default.ui_bindingsLegend.triggerInputAction(mouseDownAction.value,0),``)};onMounted(()=>{events$3.on(`setActionsForLegend`,setActions),events$3.on(`setBindingsLegendFade`,value=>{isFaded.value=!!value}),Lua_default.ui_bindingsLegend.sendDataToUI(!0),listenFilteredInputEvents(!0),document.addEventListener(`mouseup`,onGlobalMouseUp)}),onBeforeUnmount(()=>{document.removeEventListener(`mouseup`,onGlobalMouseUp),fadeOutTimeout&&=(clearTimeout(fadeOutTimeout),null),actionOpacity.value=1,listenFilteredInputEvents(!1)});function listenFilteredInputEvents(listen){events$3[listen?`on`:`off`](`FilteredInputChanged`,onFilteredInputChanged),Lua_default.WinInput.setForwardFilteredEvents(listen)}function onFilteredInputChanged(data){let updated$2=!1;for(let action of tileActions.value)action.action===data.bindingAction&&(action.value=data.value,updated$2=!0);updated$2&&triggerRef(tileActions)}function setTileRef(i,compOrEl){tileRefs.value[i]=compOrEl&&compOrEl.$el?compOrEl.$el:compOrEl}function classifyTiles(){isWide.value=tileRefs.value.map(el=>!!el?.querySelector?.(`.combo-binding`))}function pickNarrowSpanByCount(n){let options=[{cols:4,span:3},{cols:3,span:4},{cols:2,span:6}],best=options[0],bestR=n%best.cols;for(let opt of options){let r=n%opt.cols;r{await nextTick(),tileRefs.value.length=tileActions.value.length,classifyTiles(),recomputeLayout()}),onMounted(async()=>{await nextTick(),classifyTiles(),recomputeLayout()}),(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,{class:normalizeClass([`bng-app-binding-display-wrapper`,{"is-faded":isFaded.value&&!isHovered.value}]),onMouseenter:onMouseEnter,onMouseleave:onMouseLeave},[showApp.value?(openBlock(),createElementBlock(`div`,_hoisted_1$184,[modifierActionInfos.value&&additionalData.value.vehicleSpecificStatus!==`enabled`?(openBlock(),createElementBlock(`div`,_hoisted_2$149,[createVNode(bngModifierTiles_default,{"modifier-action-infos":modifierActionInfos.value},null,8,[`modifier-action-infos`])])):createCommentVNode(``,!0),(openBlock(!0),createElementBlock(Fragment,null,renderList(constantActions.value,action=>(openBlock(),createBlock(unref(bngButton_default),{accent:unref(ACCENTS).custom,onMousedown:$event=>onActionClickDown(action),tabindex:`-1`,class:normalizeClass(getActionClass(action,!0))},{default:withCtx(()=>[createBaseVNode(`div`,_hoisted_3$134,[action.label?(openBlock(),createElementBlock(`span`,_hoisted_4$111,toDisplayString(_ctx.$t(action.label)),1)):createCommentVNode(``,!0)]),createBaseVNode(`div`,_hoisted_5$96,[action.bindings?(openBlock(!0),createElementBlock(Fragment,{key:0},renderList(action.bindings,binding=>(openBlock(),createBlock(unref(bngBinding_default),{key:binding.device+`:`+binding.control,action:action.action,device:binding.device,"device-key":binding.control,"show-unassigned":``,"action-variants":``},null,8,[`action`,`device`,`device-key`]))),128)):(openBlock(),createBlock(unref(bngBinding_default),{key:1,action:action.action,"show-unassigned":``,"action-variants":``},null,8,[`action`]))])]),_:2},1032,[`accent`,`onMousedown`,`class`]))),256)),createBaseVNode(`div`,_hoisted_6$79,[(openBlock(!0),createElementBlock(Fragment,null,renderList(actions.value,(action,index)=>(openBlock(),createBlock(unref(bngButton_default),{key:action.action||action.label,accent:unref(ACCENTS).custom,onMousedown:$event=>onActionClickDown(action),tabindex:`-1`,ref_for:!0,ref:index===0?`actionButton`:void 0,class:normalizeClass(getActionClass(action,!1))},{default:withCtx(()=>[createBaseVNode(`div`,_hoisted_7$67,[action.label?(openBlock(),createElementBlock(`span`,_hoisted_8$54,toDisplayString(_ctx.$t(action.label)),1)):createCommentVNode(``,!0)]),createBaseVNode(`div`,_hoisted_9$48,[action.bindings?(openBlock(!0),createElementBlock(Fragment,{key:0},renderList(action.bindings,binding=>(openBlock(),createBlock(unref(bngBinding_default),{key:binding.device+`:`+binding.control,action:action.action,device:binding.device,"device-key":binding.control,"show-unassigned":``,"action-variants":``},null,8,[`action`,`device`,`device-key`]))),128)):(openBlock(),createBlock(unref(bngBinding_default),{key:1,action:action.action,"show-unassigned":``,"action-variants":``},null,8,[`action`]))])]),_:2},1032,[`accent`,`onMousedown`,`class`]))),128)),tileActions.value.length>0?(openBlock(),createElementBlock(`div`,_hoisted_10$41,[(openBlock(!0),createElementBlock(Fragment,null,renderList(tileActions.value,(action,i)=>(openBlock(),createBlock(unref(bngBindingTileButton_default),{class:normalizeClass([`tile-grid-item`,{highlighted:action.highlighted}]),action,icon:action.icon,label:_ctx.$t(action.label),layout:action.direction,showValueBar:action.direction!==void 0,isBidirectional:action.isCentered,value:action.value,style:{"--tile-span":4},ref_for:!0,ref:el=>setTileRef(i,el),"show-unassigned":``,"action-variants":``,"bng-no-nav":``,tabindex:`-1`},{default:withCtx(()=>[action.bindings?(openBlock(!0),createElementBlock(Fragment,{key:0},renderList(action.bindings,binding=>(openBlock(),createBlock(unref(bngBinding_default),{key:binding.device+`:`+binding.control,action:action.action,device:binding.device,"device-key":binding.control,"show-unassigned":``,"action-variants":``},null,8,[`action`,`device`,`device-key`]))),128)):(openBlock(),createBlock(unref(bngBinding_default),{key:1,action:action.action,"show-unassigned":``,"action-variants":``},null,8,[`action`]))]),_:2},1032,[`class`,`action`,`icon`,`label`,`layout`,`showValueBar`,`isBidirectional`,`value`]))),256))])):createCommentVNode(``,!0)])])):createCommentVNode(``,!0),showApp.value?(openBlock(),createElementBlock(`div`,_hoisted_11$36,[withDirectives((openBlock(),createBlock(unref(bngButton_default),{class:`bottom-left-button`,disabled:additionalData.value.vehicleSpecificStatus===`inactive`,accent:additionalData.value.vehicleSpecificStatus===`enabled`||additionalData.value.vehicleSpecificStatus===`fleeting`?unref(ACCENTS).main:unref(ACCENTS).text,onClick:_cache[0]||=$event=>unref(Lua_default).ui_bindingsLegend.toggleShowVehicleSpecificActions(),"bng-no-nav":``,tabindex:`-1`},{default:withCtx(()=>[createVNode(unref(bngIcon_default),{type:unref(icons).car},null,8,[`type`]),additionalData.value.vehicleSpecificStatus===`enabled`?(openBlock(),createBlock(unref(bngIcon_default),{key:0,class:`bottom-left-lock`,type:unref(icons).lockClosed},null,8,[`type`])):createCommentVNode(``,!0)]),_:1},8,[`disabled`,`accent`])),[[unref(BngTooltip_default),`Press to show/hide vehicle specific actions`,`right`]])])):createCommentVNode(``,!0),createVNode(unref(bngButton_default),{class:`bottom-left-button`,accent:unref(ACCENTS).text,icon:unref(icons).eyeSolidOpened,onClick:_cache[1]||=$event=>unref(Lua_default).ui_bindingsLegend.toggleShowApp(),"bng-no-nav":``,tabindex:`-1`},null,8,[`accent`,`icon`])],34))}},bngAppBindingDisplay_default=__plugin_vue_export_helper_default(_sfc_main$205,[[`__scopeId`,`data-v-cf4052e5`]]),_hoisted_1$183={class:`action`},_hoisted_2$148={key:0,class:`indicators`},_hoisted_3$133={class:`icon-wrapper`},_hoisted_4$110={key:2,class:`tile-fallback-label`},_hoisted_5$95={key:0,class:`value-bar`},_hoisted_6$78={class:`bindings-wrapper`},_sfc_main$204={__name:`bngBindingTileButton`,props:{label:String,icon:[Object,String],showIndicators:{type:Boolean,default:!1},layout:{type:String,default:`horizontal`,validator:v=>[`horizontal`,`vertical`].includes(v)},dark:Boolean,disabled:Boolean,action:{type:Object,required:!0},bindings:{type:Array,default:()=>void 0},actionVariants:Boolean,showValueBar:{type:Boolean,default:!0},value:{type:Number,default:0},targetValue:{type:Number,default:0},isBidirectional:{type:Boolean,default:!1}},emits:[`click`],setup(__props,{expose:__expose}){let props=__props,layoutClass=computed(()=>props.layout===`vertical`?`layout-vertical`:`layout-horizontal`);__expose({icons});let isLikelyImagePath=val=>typeof val==`string`&&(val.includes(`/`)||val.startsWith(`.`)||val.includes(`\\`)),candidateIcon=computed(()=>props.icon??null),useGlyphIcon=computed(()=>{let c=candidateIcon.value;return c?typeof c==`object`?!!c.glyph:typeof c==`string`?!isLikelyImagePath(c)&&c in icons:!1:!1}),resolvedGlyphType=computed(()=>useGlyphIcon.value?candidateIcon.value:null),resolvedImagePath=computed(()=>{let c=candidateIcon.value;return typeof c==`string`&&isLikelyImagePath(c)?c:null});return(_ctx,_cache)=>(openBlock(),createBlock(unref(bngButton_default),{class:`bng-binding-tile-button`,accent:unref(ACCENTS).custom,disabled:__props.disabled,onClick:_cache[0]||=$event=>_ctx.$emit(`click`)},{default:withCtx(()=>[createBaseVNode(`div`,{class:normalizeClass([`content`,layoutClass.value])},[createBaseVNode(`div`,_hoisted_1$183,[__props.showIndicators?(openBlock(),createElementBlock(`div`,_hoisted_2$148,[(openBlock(),createElementBlock(Fragment,null,renderList(5,i=>createBaseVNode(`div`,{class:normalizeClass([`indicator`,{active:i===2}]),key:i},null,2)),64))])):createCommentVNode(``,!0),createBaseVNode(`div`,_hoisted_3$133,[useGlyphIcon.value?(openBlock(),createBlock(unref(bngIcon_default),{key:0,class:`icon-glyph`,type:resolvedGlyphType.value},null,8,[`type`])):resolvedImagePath.value?(openBlock(),createBlock(unref(bngImageAsset_default),{key:1,externalSrc:resolvedImagePath.value,class:`icon-img`,mask:``},null,8,[`externalSrc`])):__props.label?(openBlock(),createElementBlock(`div`,_hoisted_4$110,toDisplayString(__props.label),1)):createCommentVNode(``,!0)])]),__props.showValueBar?(openBlock(),createElementBlock(`div`,_hoisted_5$95,[createVNode(unref(bngInputBar_default),{value:__props.value,"target-value":__props.targetValue,"is-bidirectional":__props.isBidirectional,vertical:__props.layout==`vertical`},null,8,[`value`,`target-value`,`is-bidirectional`,`vertical`])])):createCommentVNode(``,!0),createBaseVNode(`div`,_hoisted_6$78,[renderSlot(_ctx.$slots,`binding`,{},()=>[__props.action&&__props.action.bindings?(openBlock(!0),createElementBlock(Fragment,{key:0},renderList(__props.action.bindings,binding=>(openBlock(),createBlock(unref(bngBinding_default),{key:binding.device+`:`+binding.control,action:__props.action.action,device:binding.device,"device-key":binding.control,dark:__props.dark,"show-unassigned":``,"action-variants":__props.actionVariants,vertical:__props.layout===`vertical`},null,8,[`action`,`device`,`device-key`,`dark`,`action-variants`,`vertical`]))),128)):(openBlock(),createBlock(unref(bngBinding_default),{key:1,vertical:__props.layout===`vertical`,action:__props.action&&__props.action.action,dark:__props.dark,"show-unassigned":``,"action-variants":__props.actionVariants},null,8,[`vertical`,`action`,`dark`,`action-variants`]))],!0)])],2)]),_:3},8,[`accent`,`disabled`]))}},bngBindingTileButton_default=__plugin_vue_export_helper_default(_sfc_main$204,[[`__scopeId`,`data-v-db243a30`]]),_hoisted_1$182={class:`message-container`},_sfc_main$203={__name:`bngFlashMessage`,props:{messageSource:{type:String,default:`ScenarioFlashMessage`}},setup(__props){let props=__props,events$3=useEvents(),{api:api$1}=useBridge(),txt=ref(``),messageQueue=ref([]),stepTimeout=ref(null),animationClass=ref(``),fontSizeClass=ref(`font-small`),paused=ref(!1);onMounted(()=>{events$3.on(props.messageSource,data=>{if(Array.isArray(data))data.forEach(item=>{let messageObject={msg:item[0],ttl:item[1],luaCall:item[2]&&typeof item[2]==`string`?item[2]:void 0,jsCallback:item[2]&&typeof item[2]==`function`?item[2]:void 0,big:item[3]===void 0?!1:item[3]};messageQueue.value.push(messageObject)}),messageQueue.value.length>0&&!stepTimeout.value&&playMessagesAnimation();else if(typeof data==`object`){let messageObject={msg:data.msg,ttl:data.ttl,luaCall:data.luaCall||void 0,jsCallback:data.jsCallback||void 0,big:data.big===void 0?!1:data.big};messageQueue.value.push(messageObject),stepTimeout.value||playMessagesAnimation()}else console.warn(`Unexpected data format received for FlashMessage`)}),events$3.on(`physicsStateChanged`,state=>{paused.value=!state,paused.value?stepTimeout.value&&=(clearTimeout(stepTimeout.value),null):state&&playMessagesAnimation()})}),onUnmounted(()=>{stepTimeout.value&&=(clearTimeout(stepTimeout.value),null)});function playMessagesAnimation(){if(messageQueue.value.length===0){resetCountdown();return}animationClass.value=`fade-in`,setTimeout(()=>{animationClass.value=``},200);let msg=messageQueue.value[0];txt.value=msg.msg,fontSizeClass.value=msg.big?`font-large`:`font-small`,msg.luaCall&&typeof msg.luaCall==`string`&&api$1.engineLua(msg.luaCall),msg.jsCallback&&typeof msg.jsCallback==`function`&&msg.jsCallback(),messageQueue.value.shift(),setTimeout(()=>{animationClass.value=`fade-out`},msg.ttl*1e3-200),stepTimeout.value=setTimeout(()=>{playMessagesAnimation()},msg.ttl*1e3)}function resetCountdown(){stepTimeout.value&&clearTimeout(stepTimeout.value),messageQueue.value=[],txt.value=``,stepTimeout.value=null}return(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$182,[createBaseVNode(`div`,{class:normalizeClass([`message`,[`message`,animationClass.value,fontSizeClass.value]])},toDisplayString(txt.value),3)]))}},bngFlashMessage_default=__plugin_vue_export_helper_default(_sfc_main$203,[[`__scopeId`,`data-v-02941c3f`]]),_hoisted_1$181={class:`track`},_sfc_main$202={__name:`bngInputBar`,props:{value:{type:Number,default:0},targetValue:{type:Number,default:0},isBidirectional:{type:Boolean,default:!1},vertical:{type:Boolean,default:!1}},setup(__props){let props=__props,isVertical=computed(()=>props.vertical),clamp$2=(v,min$1,max$1)=>Math.min(max$1,Math.max(min$1,v)),toUnits=(v,bidir)=>{let vv=clamp$2(v,bidir?-1:0,1);return bidir?(vv+1)/2:vv},zeroUnits=computed(()=>props.isBidirectional?.5:0),actualUnits=computed(()=>toUnits(props.value,props.isBidirectional)),targetUnits=computed(()=>toUnits(props.targetValue,props.isBidirectional)),makeFillStyle=units=>{if(!isVertical.value){if(props.isBidirectional){let start=Math.min(units,zeroUnits.value),end=Math.max(units,zeroUnits.value);return{left:`${start*100}%`,right:`${(1-end)*100}%`}}return{left:`0%`,right:`${(1-units)*100}%`}}if(props.isBidirectional){let start=Math.min(units,zeroUnits.value),end=Math.max(units,zeroUnits.value);return{bottom:`${start*100}%`,top:`${(1-end)*100}%`}}return{bottom:`0%`,top:`${(1-units)*100}%`}},actualStyle=computed(()=>makeFillStyle(actualUnits.value)),targetStyle=computed(()=>makeFillStyle(targetUnits.value)),showTarget=computed(()=>props.targetValue!==void 0&&props.targetValue!==null),knobStyle=computed(()=>isVertical.value?{bottom:`calc(${actualUnits.value*100}% - 2px)`}:{left:`calc(${actualUnits.value*100}% - 2px)`});return(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,{class:normalizeClass([`bng-input-bar`,{bidirectional:__props.isBidirectional,vertical:isVertical.value}])},[createBaseVNode(`div`,_hoisted_1$181,[showTarget.value?(openBlock(),createElementBlock(`div`,{key:0,class:`fill target`,style:normalizeStyle(targetStyle.value)},null,4)):createCommentVNode(``,!0),createBaseVNode(`div`,{class:`fill actual`,style:normalizeStyle(actualStyle.value)},null,4)]),createBaseVNode(`div`,{class:`knob`,style:normalizeStyle(knobStyle.value)},null,4)],2))}},bngInputBar_default=__plugin_vue_export_helper_default(_sfc_main$202,[[`__scopeId`,`data-v-30b04794`]]),_hoisted_1$180={key:1,class:`data-label`},_hoisted_2$147={key:2,class:`data-value`},_hoisted_3$132={key:3,class:`time-container`},_hoisted_4$109={class:`time-seconds`},_hoisted_5$94={class:`time-milliseconds`},_hoisted_6$77={key:4,class:`data-value-extra`},_sfc_main$201={__name:`bngSimpleDataDisplay`,props:{label:{type:String,default:``},value:{type:[String,Number,Object,Array],default:``},icon:{type:String,default:``},minutes:{type:String},seconds:{type:String},milliseconds:{type:String}},setup(__props){let props=__props,iconType$1=computed(()=>props.icon);return(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,{class:normalizeClass([`simple-data-display`,{"with-icon":__props.icon}])},[__props.icon?(openBlock(),createBlock(unref(bngIcon_default),{key:0,type:iconType$1.value,class:`icon`},null,8,[`type`])):createCommentVNode(``,!0),__props.label&&!__props.icon?(openBlock(),createElementBlock(`div`,_hoisted_1$180,toDisplayString(__props.label),1)):createCommentVNode(``,!0),_ctx.$slots.default?createCommentVNode(``,!0):(openBlock(),createElementBlock(`div`,_hoisted_2$147,toDisplayString(__props.value),1)),props.minutes||props.seconds?(openBlock(),createElementBlock(`div`,_hoisted_3$132,[createBaseVNode(`span`,{class:normalizeClass({"time-minutes":!0,zero:__props.minutes===`00`})},toDisplayString(props.minutes),3),_cache[1]||=createTextVNode(` :`,-1),createBaseVNode(`span`,_hoisted_4$109,toDisplayString(props.seconds),1),props.milliseconds?(openBlock(),createElementBlock(Fragment,{key:0},[_cache[0]||=createTextVNode(` .`,-1),createBaseVNode(`span`,_hoisted_5$94,toDisplayString(props.milliseconds),1)],64)):createCommentVNode(``,!0)])):createCommentVNode(``,!0),_ctx.$slots.default?(openBlock(),createElementBlock(`div`,_hoisted_6$77,[renderSlot(_ctx.$slots,`default`,{},void 0,!0)])):createCommentVNode(``,!0)],2))}},bngSimpleDataDisplay_default=__plugin_vue_export_helper_default(_sfc_main$201,[[`__scopeId`,`data-v-f2b79846`]]),_sfc_main$200={__name:`app`,props:{showFlash:{type:Boolean,default:!0}},setup(__props){let props=__props;return(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,null,[createVNode(Treelights_default),props.showFlash?(openBlock(),createBlock(unref(bngFlashMessage_default),{key:0,"message-source":`DragRaceTreeFlashMessage`})):createCommentVNode(``,!0)]))}},app_default$11=_sfc_main$200,_hoisted_1$179={class:`stage-indicator-container`},_hoisted_2$146={class:`stage-bar`},_hoisted_3$131={key:0,class:`segment grey-segment top`},_hoisted_4$108={key:1,class:`segment grey-segment bottom`},_hoisted_5$93={class:`indicator-line`},THROTTLE_MS=1,HIDE_DELAY_MS=5e3,_sfc_main$199={__name:`app`,setup(__props){let events$3=useEvents(),stageDistance=ref(-100),isVisible$1=ref(!0),hideTimeout,isDetailedView=computed(()=>stageDistance.value>-1&&stageDistance.value<1),indicatorPosition=computed(()=>isDetailedView?70-(stageDistance.value+1)*20:stageDistance.value<-1?10-stageDistance.value:30-(stageDistance.value-1)*(30/3)),lastUpdate=0;function updateStageApp(distance){let now$1=performance.now();now$1-lastUpdate{isVisible$1.value=!1},HIDE_DELAY_MS))}return onMounted(()=>{events$3.on(`updateStageApp`,updateStageApp)}),onUnmounted(()=>{lastUpdate=0,clearTimeout(hideTimeout),events$3.off(`updateStageApp`,updateStageApp)}),(_ctx,_cache)=>(openBlock(),createElementBlock(Fragment,null,[createBaseVNode(`div`,null,toDisplayString(stageDistance.value),1),withDirectives(createBaseVNode(`div`,_hoisted_1$179,[createBaseVNode(`div`,_hoisted_2$146,[isDetailedView.value?(openBlock(),createElementBlock(`div`,_hoisted_3$131)):createCommentVNode(``,!0),createBaseVNode(`div`,{class:normalizeClass([`middle-section`,{"align-top":!isDetailedView.value&&stageDistance.value<-1,"align-bottom":!isDetailedView.value&&stageDistance.value>1}])},[isDetailedView.value?(openBlock(),createElementBlock(Fragment,{key:0},[_cache[0]||=createBaseVNode(`div`,{class:`segment deep-stage`,style:{height:`20px`}},null,-1),_cache[1]||=createBaseVNode(`div`,{class:`segment stage`,style:{height:`40px`}},null,-1),_cache[2]||=createBaseVNode(`div`,{class:`segment pre-stage`,style:{height:`40px`}},null,-1)],64)):(openBlock(),createElementBlock(`div`,{key:1,class:normalizeClass([`segment green-segment`,{top:stageDistance.value<-1,bottom:stageDistance.value>1}])},null,2))],2),stageDistance.value<=1?(openBlock(),createElementBlock(`div`,_hoisted_4$108)):createCommentVNode(``,!0)]),createBaseVNode(`div`,{class:`distance-indicator`,style:normalizeStyle({top:indicatorPosition.value+`%`})},[createBaseVNode(`div`,_hoisted_5$93,[createBaseVNode(`div`,{class:normalizeClass([`car-icon`,{"car-icon-detailed":isDetailedView.value}])},null,2)])],4)],512),[[vShow,isVisible$1.value&&stageDistance.value>=-4&&stageDistance.value<=4]])],64))}},app_default$12=__plugin_vue_export_helper_default(_sfc_main$199,[[`__scopeId`,`data-v-5245723d`]]),_hoisted_1$178={class:`main-container drift-app`},_hoisted_2$145={class:`cached-score-wrapper`},_hoisted_3$130={class:`added-score`},_hoisted_4$107={class:`cached-score`},_hoisted_5$92={class:`score-container`},_hoisted_6$76={class:`score`},_hoisted_7$66={class:`combo-wrapper`},_hoisted_8$53=[`id`],_hoisted_9$47=[`id`],_hoisted_10$40=[`stop-color`],_hoisted_11$35=[`stop-color`],_hoisted_12$27=[`id`],_hoisted_13$24={class:`multiplier`,x:`0`,y:`15.5`,fill:`#fff`,"dominant-baseline":`hanging`,"text-anchor":`start`,style:{fontSize:`1.9rem`}},_hoisted_14$23=[`mask`],_hoisted_15$22=[`fill`],_hoisted_16$22={class:`remaining-time`},_hoisted_17$17={class:`wrapper`},_hoisted_18$15={class:`drift-bar`},_hoisted_19$12={class:`drift-scale`},_hoisted_20$11={class:`drift-progress-bar`},FAIL_ANIMATION_DURATION=900,_sfc_main$198={__name:`app`,props:{showFlash:{type:Boolean,default:!0}},setup(__props){let props=__props,{lua}=useBridge(),bgId=uniqueId(``,`_`),events$3=useEvents(),realtimeScorePoints=ref(0),realtimeScoreCombo=ref(0),creep=ref(0),remainingComboTime=ref(0),centerIcon=ref(null),centerMessage=ref(null),centerFailMessage=ref(null),scoreToAdd=ref(0),countdownTimer=null,countdownStartTime=null,delayTimer=null,startTimer=null,centerMessageTimer=null,bonusDisplayAdd=null,bonusDisplayDispose=null,bonusQueue=ref([]),bonusDisplay=ref([]),realtimeAngle=ref(0),steppedPerformanceFactor=ref(1),isCenterMessageFading=ref(!1),isFailActive=ref(!1),isFailAnimating=ref(!1),failAnimationStartTime=null,failAnimationTimer=null,currentModifier=ref(null),isModifierFading=ref(!1),modifierTimer=null;onMounted(()=>{let rafScheduled=!1,buffered={points:0,combo:0,remaining:0,creep:0,angle:0},flushBuffered=()=>{realtimeScorePoints.value=buffered.points,realtimeScoreCombo.value=buffered.combo,remainingComboTime.value=buffered.remaining,creep.value=buffered.creep,realtimeAngle.value=buffered.angle,rafScheduled=!1},scheduleFlush=()=>{rafScheduled||(rafScheduled=!0,requestAnimationFrame(flushBuffered))},streamsList$1=[`drift`];useStreams(streamsList$1,streams=>{for(let stream of streamsList$1)if(!streams[stream])return;buffered.points=streams.drift.realtimeCachedScoreFloored,buffered.combo=streams.drift.realtimeCombo,buffered.points>0&&(centerMessage.value=null),buffered.remaining=streams.drift.realtimeRemainingComboTime,buffered.creep=streams.drift.realtimeCreep,buffered.angle=-streams.drift.realtimeAngle,steppedPerformanceFactor.value=streams.drift.realtimePerformanceFactor,scheduleFlush()}),events$3.on(`setDriftRealtimeFail`,(reason,icon)=>{cancelTimers(),isFailActive.value=!0,isFailAnimating.value=!0,isCenterMessageFading.value=!1,centerFailMessage.value=reason,centerIcon.value=icon||``,bonusDisplay.value=[],creep.value=0;let initialComboTime=remainingComboTime.value;failAnimationStartTime=performance.now();let animateFailBar=timestamp=>{let elapsed=timestamp-failAnimationStartTime,progress=Math.max(0,1-elapsed/FAIL_ANIMATION_DURATION);remainingComboTime.value=initialComboTime*progress,progress>0&&(failAnimationTimer=requestAnimationFrame(animateFailBar))};failAnimationTimer=requestAnimationFrame(animateFailBar),centerMessageTimer&&clearTimeout(centerMessageTimer),setTimeout(()=>{isFailActive.value=!1,isFailAnimating.value=!1,remainingComboTime.value=0,failAnimationTimer&&=(cancelAnimationFrame(failAnimationTimer),null)},FAIL_ANIMATION_DURATION),centerMessageTimer=setTimeout(()=>{isCenterMessageFading.value=!0},1e3),setTimeout(()=>{centerFailMessage.value=null,centerIcon.value=null,isCenterMessageFading.value=!1},1500)}),events$3.on(`setDriftPersistentDriftScored`,(final,score,combo)=>{centerMessage.value=`+ `,scoreToAdd.value=final,bonusDisplay.value=[],startCountdown()}),events$3.on(`displayDriftScoreModifier`,msg=>{modifierTimer&&clearTimeout(modifierTimer),isModifierFading.value=!1,currentModifier.value=msg,modifierTimer=setTimeout(()=>{isModifierFading.value=!0},1500)})}),onUnmounted(()=>{cancelTimers(),centerMessageTimer&&clearTimeout(centerMessageTimer),clearInterval(bonusDisplayAdd),clearInterval(bonusDisplayDispose),failAnimationTimer&&cancelAnimationFrame(failAnimationTimer),modifierTimer&&clearTimeout(modifierTimer),window.removeEventListener(`resize`,onResize)});let barClass=computed(()=>({"bar-good":!isFailAnimating.value&&steppedPerformanceFactor.value>=3,"bar-warn":!isFailAnimating.value&&steppedPerformanceFactor.value<3,"bar-fail":isFailAnimating.value})),barVarsStyle=computed(()=>({"--bar-scale":String(Math.max(0,Math.min(1,remainingComboTime.value))),"--bar-visible":remainingComboTime.value<=.01?`hidden`:`visible`})),driftProgressStyle=computed(()=>{let pos=Math.abs(calculatePosition(realtimeAngle.value,thresholds,positions))/100;return{left:`50%`,width:`50%`,transform:`scaleX(${((realtimeAngle.value>0?1:-1)>0?1:-1)*(pos/2)})`,opacity:Math.abs(realtimeAngle.value)<7?`0.65`:`1`}}),formattedCombo=computed(()=>parseFloat(realtimeScoreCombo.value).toFixed(1)),formattedRealtimeAngle=computed(()=>Math.abs(Math.round(realtimeAngle.value))),layoutVersion=ref(0),tickLefts=computed(()=>positions.map(p$1=>`${(p$1+100)/2}%`)),onResize=()=>{layoutVersion.value++};window.addEventListener(`resize`,onResize);function cancelTimers(){countdownTimer&&=(cancelAnimationFrame(countdownTimer),null),delayTimer&&=(clearTimeout(delayTimer),null),startTimer&&=(clearTimeout(startTimer),null),failAnimationTimer&&=(cancelAnimationFrame(failAnimationTimer),null)}function startCountdown(){cancelTimers(),startTimer=setTimeout(()=>{let initialScore=scoreToAdd.value,scoreDwindleAnimDuration=1e3;function countdown(timestamp){countdownStartTime||=timestamp;let elapsedTime=timestamp-countdownStartTime;elapsedTime>=scoreDwindleAnimDuration?(scoreToAdd.value=0,countdownStartTime=null,delayTimer=setTimeout(()=>{scoreToAdd.value=-1,centerMessage.value=null,realtimeScorePoints.value=0,realtimeScoreCombo.value=0,creep.value=0,delayTimer=null},1e3)):(scoreToAdd.value=Math.floor(initialScore*(1-elapsedTime/scoreDwindleAnimDuration)),countdownTimer=requestAnimationFrame(countdown))}countdownTimer=requestAnimationFrame(countdown)},1250)}let thresholds=[-110,-60,-20,0,20,60,110],positions=[-100,-70,-35,0,35,70,100],calculatePosition=(y,thresholds$1,positions$1)=>{let clampedY=Math.max(thresholds$1[0],Math.min(thresholds$1[thresholds$1.length-1],y));for(let i=0;i=thresholds$1[i]&&clampedY<=thresholds$1[i+1]){let t=(clampedY-thresholds$1[i])/(thresholds$1[i+1]-thresholds$1[i]);return positions$1[i]+t*(positions$1[i+1]-positions$1[i])}return 0},performanceBgClass=computed(()=>({"perf-good":steppedPerformanceFactor.value>=3,"perf-warn":steppedPerformanceFactor.value<3})),performanceTransformStyle=computed(()=>{let sRaw=Math.min(steppedPerformanceFactor.value/3,1);return{transform:`scale(${sRaw===0?.001:sRaw})`,transformOrigin:`center bottom`,opacity:sRaw===0?0:1}});function onModifierTransitionEnd(e){e.propertyName===`opacity`&&(isModifierFading.value&&=(currentModifier.value=null,!1))}let comboVarsStyle=computed(()=>({"--combo-glow-color":realtimeScoreCombo.value>=25?`210, 110, 0`:`255, 255, 0`,"--combo-glow-alpha":String(creep.value),"--combo-rect-translate":`${-creep.value*2}rem`}));function ensureBonusTimers(){!bonusDisplayAdd&&bonusQueue.value.length>0&&(bonusDisplayAdd=setInterval(()=>{if(bonusQueue.value.length===0)return;let item=bonusQueue.value.pop();bonusDisplay.value.unshift(item)},500)),!bonusDisplayDispose&&bonusDisplay.value.length>0&&(bonusDisplayDispose=setInterval(()=>{bonusDisplay.value.length>0&&bonusDisplay.value.pop()},1e4)),bonusQueue.value.length===0&&bonusDisplay.value.length===0&&(bonusDisplayAdd&&=(clearInterval(bonusDisplayAdd),null),bonusDisplayDispose&&=(clearInterval(bonusDisplayDispose),null))}return watch(bonusQueue,ensureBonusTimers,{deep:!0}),watch(bonusDisplay,ensureBonusTimers,{deep:!0}),onMounted(()=>{lua.extensions.gameplay_drift_general.onDriftAppMounted()}),onUnmounted(()=>{lua.extensions.gameplay_drift_general.onDriftAppUnmounted()}),(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$178,[createBaseVNode(`div`,_hoisted_2$145,[createBaseVNode(`div`,{class:normalizeClass([`fail-overlay`,{active:isFailActive.value}])},null,2),createBaseVNode(`div`,{class:normalizeClass([`performance-background`,performanceBgClass.value]),style:normalizeStyle(performanceTransformStyle.value)},null,6),centerFailMessage.value?(openBlock(),createElementBlock(`div`,{key:0,class:normalizeClass([`center`,{"fade-out":isCenterMessageFading.value}])},toDisplayString(centerFailMessage.value),3)):centerMessage.value?(openBlock(),createElementBlock(`div`,{key:1,class:normalizeClass([`center`,{"fade-out":isCenterMessageFading.value}])},[createTextVNode(toDisplayString(centerMessage.value)+` `,1),centerMessage.value&&scoreToAdd.value>=0?(openBlock(),createElementBlock(Fragment,{key:0},[createTextVNode(toDisplayString(scoreToAdd.value),1)],64)):createCommentVNode(``,!0)],2)):(openBlock(),createElementBlock(Fragment,{key:2},[createBaseVNode(`div`,_hoisted_3$130,[(openBlock(!0),createElementBlock(Fragment,null,renderList(bonusDisplay.value,(item,index)=>(openBlock(),createElementBlock(`div`,{key:index,class:`score-item`},` +`+toDisplayString(~~item.score),1))),128))]),createBaseVNode(`div`,_hoisted_4$107,[createBaseVNode(`div`,_hoisted_5$92,[(openBlock(),createElementBlock(`div`,{class:normalizeClass([`score-modifier`,{"fade-out":isModifierFading.value}]),key:currentModifier.value,onTransitionend:onModifierTransitionEnd},toDisplayString(currentModifier.value),35)),createBaseVNode(`div`,_hoisted_6$76,toDisplayString(realtimeScorePoints.value),1)]),createBaseVNode(`div`,_hoisted_7$66,[(openBlock(),createElementBlock(`svg`,{id:`svg_${unref(bgId)}`,class:`combo`,viewBox:`0 0 100 30`,style:normalizeStyle([{width:`100%`,height:`3rem`},comboVarsStyle.value]),preserveAspectRatio:`xMinYMid meet`},[createBaseVNode(`defs`,null,[createBaseVNode(`linearGradient`,{id:`grad_${unref(bgId)}`,x1:`0%`,y1:`0%`,x2:`0%`,y2:`100%`},[_cache[0]||=createBaseVNode(`stop`,{offset:`50%`,"stop-color":`var(--bng-ter-yellow-100)`},null,-1),createBaseVNode(`stop`,{offset:`51%`,"stop-color":realtimeScoreCombo.value>=25?`#ff8400`:`#fff`},null,8,_hoisted_10$40),createBaseVNode(`stop`,{offset:`75%`,"stop-color":realtimeScoreCombo.value>=25?`#ff8400`:`#fff`},null,8,_hoisted_11$35)],8,_hoisted_9$47),createBaseVNode(`mask`,{id:`mask_${unref(bgId)}`},[createBaseVNode(`text`,_hoisted_13$24,` ×`+toDisplayString(formattedCombo.value),1)],8,_hoisted_12$27)]),createBaseVNode(`g`,{mask:`url(#mask_${unref(bgId)})`},[createBaseVNode(`rect`,{width:`100%`,height:`4.2rem`,x:`0`,y:`15.5`,fill:`url(#grad_${unref(bgId)})`,class:`animated-rect`},null,8,_hoisted_15$22)],8,_hoisted_14$23)],12,_hoisted_8$53))])])],64))]),createBaseVNode(`div`,_hoisted_16$22,[createBaseVNode(`div`,_hoisted_17$17,[createBaseVNode(`div`,{class:normalizeClass([`bar`,barClass.value]),style:normalizeStyle(barVarsStyle.value)},null,6)])]),createBaseVNode(`div`,_hoisted_18$15,[createBaseVNode(`div`,_hoisted_19$12,[createBaseVNode(`div`,_hoisted_20$11,[createBaseVNode(`div`,{class:`progress-fill`,style:normalizeStyle(driftProgressStyle.value)},null,4)]),(openBlock(),createElementBlock(`div`,{class:`value-marks`,key:layoutVersion.value},[(openBlock(),createElementBlock(Fragment,null,renderList(thresholds,(threshold,index)=>createBaseVNode(`div`,{class:`line`,key:threshold,style:normalizeStyle({position:`absolute`,left:tickLefts.value[index],width:`0.125rem`,height:`0.24rem`,transform:threshold===0?`translateX(-50%)`:threshold>0?`translateX(-100%)`:`translateX(0%)`,backgroundColor:`white`})},null,4)),64))]))]),(openBlock(),createElementBlock(`div`,{class:`drift-labels`,key:layoutVersion.value},[(openBlock(),createElementBlock(Fragment,null,renderList(thresholds,(threshold,index)=>createBaseVNode(`span`,{key:threshold,style:normalizeStyle({position:`absolute`,left:tickLefts.value[index],transform:`translateX(-50%)`,textAlign:`center`})},toDisplayString(threshold===0?`${formattedRealtimeAngle.value}°`:`${Math.abs(threshold)}°`),5)),64))])),props.showFlash?(openBlock(),createBlock(unref(bngFlashMessage_default),{key:0,"message-source":`DriftFlashMessage`})):createCommentVNode(``,!0)])]))}},app_default$13=__plugin_vue_export_helper_default(_sfc_main$198,[[`__scopeId`,`data-v-aa80ede0`]]),_hoisted_1$177={class:`main-container-grid`},_hoisted_2$144={class:`scores-container`},_hoisted_3$129={class:`permanent`},_hoisted_4$106={class:`points-label`},_sfc_main$197={__name:`app`,setup(__props){let events$3=useEvents(),permanentScore=ref(0),potentialScore=ref(0),isAnimatingPotentialScore=ref(!1),dontUpdateScores=ref(!1),lastPotentialScore=ref(0);onMounted(()=>{events$3.on(`setDriftPersistentDriftScored`,(score,combo)=>{isAnimatingPotentialScore.value=!0,dontUpdateScores.value=!0,potentialScore.value=score,lastPotentialScore.value=potentialScore.value,setTimeout(()=>{isAnimatingPotentialScore.value=!1},1e3),setTimeout(()=>{dontUpdateScores.value=!1},900)})}),onUnmounted(()=>{events$3.off(`setDriftPersistentDriftScored`)});let streamsList$1=[`drift`];return useStreams(streamsList$1,streams=>{for(let stream of streamsList$1)if(!streams[stream])return;dontUpdateScores.value||(permanentScore.value=streams.drift.permanentScore,potentialScore.value=streams.drift.potentialScore)}),(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$177,[createBaseVNode(`div`,_hoisted_2$144,[createBaseVNode(`div`,_hoisted_3$129,[createBaseVNode(`span`,_hoisted_4$106,toDisplayString(unref($translate).instant(`missions.drift.general.pointsShort`))+`: `,1),createTextVNode(toDisplayString(permanentScore.value),1)]),createBaseVNode(`div`,{class:normalizeClass([`potential`,{"animate-potential-score":isAnimatingPotentialScore.value}])},` + `+toDisplayString(potentialScore.value),3)])]))}},app_default$14=__plugin_vue_export_helper_default(_sfc_main$197,[[`__scopeId`,`data-v-29f9fe6b`]]),_hoisted_1$176={class:`main-container-grid`},_sfc_main$196={__name:`app`,setup(__props){let{lua}=useBridge(),events$3=useEvents(),showButton=ref(!1),handleNextStep=()=>{lua.gameplay_crashTest_scenarioManager.nextStepFromUI(),showButton.value=!1};return onMounted(()=>{events$3.on(`onCrashTestStepFinished`,()=>{console.log(`onCrashTestStepFinished`),showButton.value=!0})}),onUnmounted(()=>{events$3.off(`onCrashTestStepFinished`)}),(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$176,[showButton.value?(openBlock(),createBlock(unref(bngButton_default),{key:0,onClick:handleNextStep,accent:unref(ACCENTS).text,icon:unref(icons).arrowSolidRight,class:normalizeClass({"next-step-button":!0})},{default:withCtx(()=>[createTextVNode(toDisplayString(unref($translate).instant(`missions.crashTest.general.nextStep`)),1)]),_:1},8,[`accent`,`icon`])):createCommentVNode(``,!0)]))}},app_default$15=__plugin_vue_export_helper_default(_sfc_main$196,[[`__scopeId`,`data-v-6d935866`]]),_hoisted_1$175={class:`bng-app`},_sfc_main$195={__name:`app`,setup(__props){let{$game}=useLibStore(),streamsList$1=[`engineInfo`],data=reactive({engineT:0,wheelT:0,rpm:0,gearText:``});onMounted(()=>$game.streams.add(streamsList$1)),onUnmounted(()=>$game.streams.remove(streamsList$1)),$game.events.on(`onStreamsUpdate`,streams=>{streams.engineInfo!==null&&(data.engineT=$game.units.buildString(`torque`,streams.engineInfo[8],0),data.wheelT=$game.units.buildString(`torque`,streams.engineInfo[19],0),data.rpm=streams.engineInfo[4].toFixed(),data.gearText=getGearText(streams.engineInfo[16],streams.engineInfo[6],streams.engineInfo[7]))});let getGearText=(gear,fGear,rGear)=>gear>0?`F `+gear+` / `+fGear:gear<0?`R `+Math.abs(gear)+` / `+rGear:`N`;return(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$175,[createTextVNode(toDisplayString(_ctx.$t(`ui.apps.engineinfo.rpm`))+`: `+toDisplayString(data.rpm),1),_cache[0]||=createBaseVNode(`br`,null,null,-1),createTextVNode(` `+toDisplayString(_ctx.$t(`ui.apps.engineinfo.gear`))+`: `+toDisplayString(data.gearText),1),_cache[1]||=createBaseVNode(`br`,null,null,-1),createTextVNode(` `+toDisplayString(_ctx.$t(`ui.apps.engineinfo.flywheelTorque`))+`: `+toDisplayString(data.engineT)+` `,1),_cache[2]||=createBaseVNode(`br`,null,null,-1),createTextVNode(` `+toDisplayString(_ctx.$t(`ui.apps.engineinfo.wheelTorque`))+`: `+toDisplayString(data.wheelT),1)]))}},app_default$16=_sfc_main$195,_hoisted_1$174={class:`legends`},_hoisted_2$143={class:`torque-flywheel`},_hoisted_3$128={class:`power-flywheel`},_hoisted_4$105={class:`power-wheels`},_hoisted_5$91={class:`rpm`},_hoisted_6$75={class:`content`},_hoisted_7$65={class:`power-label`},_hoisted_8$52={class:`label`},_hoisted_9$46={class:`canvas-container`},_hoisted_10$39={class:`torque-label`},_hoisted_11$34={class:`label`},tickLabels=21,torqueGraphColor=`#000000`,powerGraphColor=`#FF0000`,powerWheelGraphColor=`#FF4400`,rpmGraphColor=`#0000FF`,_sfc_main$194={__name:`app`,setup(__props){let{$game}=useLibStore(),streamsList$1=[`engineInfo`],app$1=ref(null),canvas=ref(null),globalMax=ref(0),torqueUnit=ref(null),powerUnit=ref(null),tickSpacing=ref(0),tickInterval=computed(()=>globalMax.value/10),appResizeObserver=new ResizeObserver(entries=>{let entry=entries[0];canvas.value.width=entry.target.offsetWidth-130,canvas.value.height=entry.target.offsetHeight-20,tickSpacing.value=canvas.value.height/10,console.log(`width`,entry.target.offsetWidth),console.log(`height`,entry.target.offsetHeight),console.log(`tickspacing`,tickSpacing.value),console.log(`canvas`,canvas.value.width,canvas.value.height)}),chart=new SmoothieChart({minValue:0,maxValue:1e3,millisPerPixel:20,interpolation:`bezier`,grid:{fillStyle:`rgba(250,250,250,0.2)`,strokeStyle:`grey`,verticalSections:20,millisPerLine:1e3,sharpLines:!0},labels:{disabled:!0}}),torqueGraph=new TimeSeries,powerGraph=new TimeSeries,powerWheelGraph=new TimeSeries,rpmGraph=new TimeSeries;onMounted(()=>{initChart(),appResizeObserver.observe(app$1.value),$game.events.on(`onStreamsUpdate`,onStreamsUpdate),$game.streams.add(streamsList$1)}),onBeforeUnmount(()=>{appResizeObserver.unobserve(app$1.value)}),onUnmounted(()=>{$game.events.off(`onStreamsUpdate`,onStreamsUpdate),$game.streams.remove(streamsList$1)});function onStreamsUpdate(streams){for(let stream of streamsList$1)if(!streams[stream])return;let xPoint=new Date,torque=$game.units.torque(streams.engineInfo[8]).val,power$1=$game.units.power(streams.engineInfo[4]*.104719755*streams.engineInfo[8]/1e3*1.34102).val,wheelPower=$game.units.power(streams.engineInfo[20]/1e3*1.34102).val,rpm=streams.engineInfo[4]/10;torqueUnit.value=$game.units.torque().unit,powerUnit.value=$game.units.power().unit,globalMax.value=Math.ceil(Math.max.apply(null,[globalMax.value,torque,power$1])/100)*100,chart.options.maxValue=globalMax.value,torqueGraph.append(xPoint,torque),powerGraph.append(xPoint,power$1),powerWheelGraph.append(xPoint,wheelPower),rpmGraph.append(xPoint,rpm)}function initChart(){chart.addTimeSeries(torqueGraph,{strokeStyle:torqueGraphColor,lineWidth:1.5}),chart.addTimeSeries(powerGraph,{strokeStyle:powerGraphColor,lineWidth:1.5}),chart.addTimeSeries(powerWheelGraph,{strokeStyle:powerWheelGraphColor,lineWidth:1.5}),chart.addTimeSeries(rpmGraph,{strokeStyle:rpmGraphColor,lineWidth:1.5}),chart.streamTo(canvas.value,40)}return(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,{ref_key:`app`,ref:app$1,class:`engine-dynamometer`},[createBaseVNode(`div`,_hoisted_1$174,[createBaseVNode(`small`,_hoisted_2$143,toDisplayString(_ctx.$t(`ui.apps.engine_dynamometer.torqueFlywheel`)),1),createBaseVNode(`small`,_hoisted_3$128,toDisplayString(_ctx.$t(`ui.apps.engine_dynamometer.powerFlywheel`)),1),createBaseVNode(`small`,_hoisted_4$105,toDisplayString(_ctx.$t(`ui.apps.engine_dynamometer.powerWheels`)),1),createBaseVNode(`small`,_hoisted_5$91,toDisplayString(_ctx.$t(`ui.apps.engine_dynamometer.rpm`)),1)]),createBaseVNode(`div`,_hoisted_6$75,[createBaseVNode(`div`,_hoisted_7$65,[createBaseVNode(`div`,_hoisted_8$52,toDisplayString(_ctx.$t(`ui.apps.engine_dynamometer.power`))+` (`+toDisplayString(powerUnit.value)+`) `,1),(openBlock(),createElementBlock(Fragment,null,renderList(tickLabels,(n,index)=>createBaseVNode(`div`,{class:`ruler`,style:normalizeStyle({top:index*tickSpacing.value+`px`})},toDisplayString((globalMax.value-index*tickInterval.value).toFixed(0)),5)),64))]),createBaseVNode(`div`,_hoisted_9$46,[createBaseVNode(`canvas`,{ref_key:`canvas`,ref:canvas,class:`canvas`},null,512)]),createBaseVNode(`div`,_hoisted_10$39,[createBaseVNode(`div`,_hoisted_11$34,toDisplayString(_ctx.$t(`ui.apps.engine_dynamometer.torque`))+` (`+toDisplayString(torqueUnit.value)+`) `,1),(openBlock(),createElementBlock(Fragment,null,renderList(tickLabels,(n,index)=>createBaseVNode(`div`,{class:`ruler`,style:normalizeStyle({top:index*tickSpacing.value+`px`})},toDisplayString((globalMax.value-index*tickInterval.value).toFixed(0)),5)),64))])])],512))}},app_default$17=__plugin_vue_export_helper_default(_sfc_main$194,[[`__scopeId`,`data-v-e025129d`]]),_hoisted_1$173={class:`legends`},_hoisted_2$142={class:`water`},_hoisted_3$127={class:`oil`},_hoisted_4$104={class:`block`},_hoisted_5$90={class:`exhaust`},coolantGraphColor=`#333676`,oilGraphColor=`#AA8C39`,blockGraphColor=`#378B2E`,exhaustGraphColor=`#A7383E`,_sfc_main$193={__name:`app`,setup(__props){let{$game}=useLibStore(),streamsList$1=[`engineThermalData`],app$1=ref(null),canvas=ref(null),isRunning=ref(!1),appResizeObserver=new ResizeObserver(entries=>{let entry=entries[0];canvas.value.width=entry.target.offsetWidth,canvas.value.height=entry.target.offsetHeight}),chart=new SmoothieChart({minValue:50,maxValue:150,millisPerPixel:40,interpolation:`bezier`,grid:{fillStyle:`rgba(250,250,250,0.8)`,strokeStyle:`black`,verticalSections:0,millisPerLine:0},labels:{fillStyle:`black`}}),coolantGraph=new TimeSeries,oilGraph=new TimeSeries,blockGraph=new TimeSeries,exhaustGraph=new TimeSeries;onMounted(()=>{initChart(),appResizeObserver.observe(app$1.value),$game.streams.add(streamsList$1),$game.events.on(`onStreamsUpdate`,onStreamsUpdate)}),onBeforeUnmount(()=>{appResizeObserver.unobserve(app$1.value)}),onUnmounted(()=>{$game.events.off(`onStreamsUpdate`,onStreamsUpdate),$game.streams.remove(streamsList$1)});function onStreamsUpdate(streams){if(streams.engineThermalData){isRunning.value||(isRunning.value=!0,chart.start());let xPoint=new Date;coolantGraph.append(xPoint,streams.engineThermalData.coolantTemperature),oilGraph.append(xPoint,streams.engineThermalData.oilTemperature),blockGraph.append(xPoint,streams.engineThermalData.engineBlockTemperature),exhaustGraph.append(xPoint,streams.engineThermalData.exhaustTemperature)}else isRunning.value&&(isRunning.value=!1,chart.stop())}function initChart(){chart.addTimeSeries(coolantGraph,{strokeStyle:coolantGraphColor,lineWidth:1}),chart.addTimeSeries(oilGraph,{strokeStyle:oilGraphColor,lineWidth:1}),chart.addTimeSeries(blockGraph,{strokeStyle:blockGraphColor,lineWidth:1}),chart.addTimeSeries(exhaustGraph,{strokeStyle:exhaustGraphColor,lineWidth:1}),chart.streamTo(canvas.value,40)}return(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,{ref_key:`app`,ref:app$1,class:`engine-hdg`},[createBaseVNode(`div`,_hoisted_1$173,[createBaseVNode(`small`,_hoisted_2$142,toDisplayString(_ctx.$t(`ui.apps.engine_heat_debug_graph.water`)),1),createBaseVNode(`small`,_hoisted_3$127,toDisplayString(_ctx.$t(`ui.apps.engine_heat_debug_graph.oil`)),1),createBaseVNode(`small`,_hoisted_4$104,toDisplayString(_ctx.$t(`ui.apps.engine_heat_debug_graph.block`)),1),createBaseVNode(`small`,_hoisted_5$90,toDisplayString(_ctx.$t(`ui.apps.engine_heat_debug_graph.exhaust`)),1)]),createBaseVNode(`canvas`,{ref_key:`canvas`,ref:canvas},null,512)],512))}},app_default$18=__plugin_vue_export_helper_default(_sfc_main$193,[[`__scopeId`,`data-v-ac69837e`]]),_hoisted_1$172={class:`bng-app thermal-clutch-debug`},_hoisted_2$141={class:`set-name`},_sfc_main$192={__name:`app`,setup(__props){let{$game}=useLibStore(),streamsList$1=[`engineThermalData`],data=ref(null);onMounted(()=>{$game.streams.add(streamsList$1)}),onUnmounted(()=>{$game.streams.remove(streamsList$1)}),$game.events.on(`onStreamsUpdate`,streams=>data.value=streams.engineThermalData?parseData(streams.engineThermalData):null);function parseData(data$1){return[{str:$game.units.buildString(`temperature`,data$1.coolantTemperature,0),name:`ui.apps.engine_thermal_debug.coolant`,warn:data$1.coolantTemperature>data$1.thermostatTemperature&&data$1.coolantTemperature<120&&data$1.thermostatStatus==1,error:data$1.coolantTemperature>120},{str:$game.units.buildString(`temperature`,data$1.oilTemperature,0),name:`ui.apps.engine_thermal_debug.oil`,warn:data$1.oilTemperature>140,error:data$1.oilTemperature>150},{str:$game.units.buildString(`temperature`,data$1.engineBlockTemperature,0),name:`ui.apps.engine_thermal_debug.block`},{str:$game.units.buildString(`temperature`,data$1.cylinderWallTemperature,0),name:`ui.apps.engine_thermal_debug.cylinderlWall`},{str:$game.units.buildString(`temperature`,data$1.exhaustTemperature,0),name:`ui.apps.engine_thermal_debug.exhaustManifold`},{str:data$1.thermostatStatus.toFixed(3),name:`ui.apps.engine_thermal_debug.coolantThermostat`,warn:data$1.thermostatStatus>.9},{str:data$1.airRegulatorStatus.toFixed(3),name:`ui.apps.engine_thermal_debug.airRegulator`,warn:data$1.airRegulatorStatus>.9},{str:$game.units.buildString(`speed`,data$1.radiatorAirSpeed,0),name:`ui.apps.engine_thermal_debug.radiatorAirSpeed`},{str:data$1.radiatorAirSpeedEfficiency.toFixed(4),name:`ui.apps.engine_thermal_debug.radiatorAirSpeedEfficiency`},{str:data$1.fanActive,name:`ui.apps.engine_thermal_debug.radiatorFanActive`},{str:data$1.coolantMass.toFixed(3),name:`ui.apps.engine_thermal_debug.coolantMass`},{str:data$1.coolantLeakRateOverpressure.toFixed(3),name:`ui.apps.engine_thermal_debug.coolantLeakRateOverpressure`,warn:data$1.coolantLeakRateOverpressure>0},{str:data$1.coolantLeakRateHeadGasket.toFixed(3),name:`ui.apps.engine_thermal_debug.coolantLeakRateHeadGasket`,warn:data$1.coolantLeakRateHeadGasket>0},{str:data$1.coolantLeakRateRadiator.toFixed(3),name:`ui.apps.engine_thermal_debug.coolantLeakRateRadiator`,warn:data$1.coolantLeakRateRadiator>0},{str:data$1.coolantLeakRateOverall.toFixed(3),name:`ui.apps.engine_thermal_debug.coolantLeakRateOverall`,warn:data$1.coolantLeakRateOverall>0},{str:data$1.coolantEfficiency.toFixed(3),name:`ui.apps.engine_thermal_debug.coolantEfficiency`,warn:data$1.coolantEfficiency<1,error:data$1.coolantEfficiency===0},{str:data$1.oilThermostatStatus.toFixed(3),name:`ui.apps.engine_thermal_debug.oilThermostat`,warn:data$1.oilThermostatStatus>.9},{str:data$1.oilMass.toFixed(3),name:`ui.apps.engine_thermal_debug.oilMass`,warn:data$1.oilMassdata$1.maximumSafeOilMass},{str:data$1.miniumSafeOilMass.toFixed(3),name:`ui.apps.engine_thermal_debug.miniumSafeOilMass`},{str:data$1.maximumSafeOilMass.toFixed(3),name:`ui.apps.engine_thermal_debug.maximumSafeOilMass`},{str:data$1.oilLeakRateOilpan.toFixed(3),name:`ui.apps.engine_thermal_debug.oilLeakRateOilpan`,warn:data$1.oilLeakRateOilpan>0},{str:data$1.oilLeakRateRadiator.toFixed(3),name:`ui.apps.engine_thermal_debug.oilLeakRateRadiator`,warn:data$1.oilLeakRateRadiator>0},{str:data$1.oilLeakRateGravity.toFixed(3),name:`ui.apps.engine_thermal_debug.oilLeakRateGravity`,warn:data$1.oilLeakRateGravity>0},{str:data$1.oilLeakRatePistonRingDamage.toFixed(3),name:`ui.apps.engine_thermal_debug.oilLeakRatePistonRingDamage`,warn:data$1.oilLeakRatePistonRingDamage>0},{str:data$1.oilLeakRateOverall.toFixed(3),name:`ui.apps.engine_thermal_debug.oilLeakRateOverall`,warn:data$1.oilLeakRateOverall>0},{str:data$1.oilStarvingSevernessXY.toFixed(3),name:`ui.apps.engine_thermal_debug.oilStarvingSevernessXY`,warn:data$1.oilStarvingSevernessXY>0},{str:data$1.oilStarvingSevernessZ.toFixed(3),name:`ui.apps.engine_thermal_debug.oilStarvingSevernessZ`,warn:data$1.oilStarvingSevernessZ>0},{str:data$1.maximumSafeG.toFixed(3),name:`ui.apps.engine_thermal_debug.maximumSafeG`},{str:data$1.oilLubricationCoef.toFixed(3),name:`ui.apps.engine_thermal_debug.oilLubricationCoef`,warn:data$1.oilLubricationCoef<1},{str:data$1.missingOilDamage.toFixed(3),name:`ui.apps.engine_thermal_debug.missingOilDamage`,warn:data$1.missingOilDamage>0},{str:data$1.engineEfficiency.toFixed(2),name:`ui.apps.engine_thermal_debug.engineEfficiency`},{str:$game.units.buildString(`energy`,data$1.energyToCylinderWall,0),name:`ui.apps.engine_thermal_debug.qtocylinderwall`},{str:$game.units.buildString(`energy`,data$1.energyCylinderWallToCoolant,0),name:`ui.apps.engine_thermal_debug.qcylinderwalltocoolant`},{str:$game.units.buildString(`energy`,data$1.energyCoolantToAir,0),name:`ui.apps.engine_thermal_debug.qcoolanttoair`},{str:$game.units.buildString(`energy`,data$1.energyCoolantToBlock,0),name:`ui.apps.engine_thermal_debug.qcoolanttoblock`},{str:$game.units.buildString(`energy`,data$1.energyCylinderWallToBlock,0),name:`ui.apps.engine_thermal_debug.qcylinderwalltoblock`},{str:$game.units.buildString(`energy`,data$1.energyBlockToAir,0),name:`ui.apps.engine_thermal_debug.qblocktoair`},{str:$game.units.buildString(`energy`,data$1.energyToOil,0),name:`ui.apps.engine_thermal_debug.qtooil`},{str:$game.units.buildString(`energy`,data$1.energyCylinderWallToOil,0),name:`ui.apps.engine_thermal_debug.qcylinderwalltooil`},{str:$game.units.buildString(`energy`,data$1.energyOilToAir,0),name:`ui.apps.engine_thermal_debug.qoilradiatortoair`},{str:$game.units.buildString(`energy`,data$1.energyOilSumpToAir,0),name:`ui.apps.engine_thermal_debug.qoilsumptoair`},{str:$game.units.buildString(`energy`,data$1.energyToExhaust,0),name:`ui.apps.engine_thermal_debug.qtoexhaust`},{str:$game.units.buildString(`energy`,data$1.energyExhaustToAir,0),name:`ui.apps.engine_thermal_debug.qexhausttoair`},{str:data$1.engineBlockOverheatDamage.toFixed(),name:`ui.apps.engine_thermal_debug.blockDamage`,warn:data$1.engineBlockOverheatDamage>0},{str:data$1.oilOverheatDamage.toFixed(),name:`ui.apps.engine_thermal_debug.oilDamage`,warn:data$1.oilOverheatDamage>0},{str:data$1.cylinderWallOverheatDamage.toFixed(),name:`ui.apps.engine_thermal_debug.cylinderwallDamage`,warn:data$1.cylinderWallOverheatDamage>0},{str:data$1.headGasketBlown,name:`ui.apps.engine_thermal_debug.headGasketBlown`,error:data$1.headGasketBlown},{str:data$1.pistonRingsDamaged,name:`ui.apps.engine_thermal_debug.pistonRingsDamaged`,error:data$1.pistonRingsDamaged},{str:data$1.connectingRodBearingsDamaged,name:`ui.apps.engine_thermal_debug.connectingRodBearingsDamaged`,error:data$1.connectingRodBearingsDamaged}]}return(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$172,[(openBlock(!0),createElementBlock(Fragment,null,renderList(data.value,(set,index)=>(openBlock(),createElementBlock(`div`,{key:index,class:`set`},[createBaseVNode(`div`,_hoisted_2$141,toDisplayString(_ctx.$t(set.name)),1),createBaseVNode(`div`,{class:normalizeClass([`set-value`,{"thermal-warning":set.warn,"thermal-error":set.error}])},toDisplayString(set.str),3)]))),128))]))}},app_default$19=__plugin_vue_export_helper_default(_sfc_main$192,[[`__scopeId`,`data-v-6de0b81a`]]),_hoisted_1$171={"xmlns:dc":`http://purl.org/dc/elements/1.1/`,"xmlns:cc":`http://creativecommons.org/ns#`,"xmlns:rdf":`http://www.w3.org/1999/02/22-rdf-syntax-ns#`,"xmlns:svg":`http://www.w3.org/2000/svg`,xmlns:`http://www.w3.org/2000/svg`,"xmlns:xlink":`http://www.w3.org/1999/xlink`,"xmlns:sodipodi":`http://sodipodi.sourceforge.net/DTD/sodipodi-0.dtd`,"xmlns:inkscape":`http://www.inkscape.org/namespaces/inkscape`,version:`1.1`,width:`100%`,height:`100%`,viewBox:`0 0 660 660`},_hoisted_2$140={"inkscape:groupmode":`layer`,id:`layer6`,class:`layer6`,"inkscape:label":`new`,style:{display:`inline`}},_hoisted_3$126={"xml:space":`preserve`,style:{"font-style":`normal`,"font-variant":`normal`,"font-weight":`normal`,"font-stretch":`normal`,"font-size":`159.64709473px`,"line-height":`125%`,"font-family":`'Squada One'`,"-inkscape-font-specification":`'Squada One'`,"text-align":`center`,"letter-spacing":`0px`,"word-spacing":`0px`,"writing-mode":`lr-tb`,"text-anchor":`middle`,display:`inline`,fill:`#ffffff`,"fill-opacity":`1`,stroke:`none`},x:`329.85437`,y:`328.48807`,id:`tspan4449-43`,"sodipodi:linespacing":`125%`,"inkscape:label":`#pressureText`},_hoisted_4$103={"xml:space":`preserve`,style:{"font-style":`normal`,"font-variant":`normal`,"font-weight":`normal`,"font-stretch":`normal`,"font-size":`65px`,"line-height":`125%`,"font-family":`'Squada One'`,"-inkscape-font-specification":`'Squada One'`,"text-align":`center`,"letter-spacing":`0px`,"word-spacing":`0px`,"writing-mode":`lr-tb`,"text-anchor":`middle`,display:`inline`,fill:`#ffffff`,"fill-opacity":`0.78835976`,stroke:`none`},x:`329.03198`,y:`413.62915`,id:`speed_units`,"sodipodi:linespacing":`125%`,"inkscape:label":`#speed_units`,"inkscape:transform-center-y":`-4.486084`},_hoisted_5$89=[`id`,`x`,`y`],_hoisted_6$74=[`id`,`x`,`y`],_hoisted_7$64={"inkscape:groupmode":`layer`,id:`layer3`,"inkscape:label":`FIX`,style:{display:`inline`}},_hoisted_8$51={id:`revcurvemask`,style:{display:`inline`}},_hoisted_9$45={"inkscape:groupmode":`layer`,id:`layer11`,"inkscape:label":`revs`,style:{display:`inline`}},_hoisted_10$38={"inkscape:groupmode":`layer`,id:`layer7`,"inkscape:label":`new2`,style:{display:`inline`}},width=660,height=660,dashSize=5,pressureTextSize=50,dashCount=5,PRESURE_MAX_CONST=150,PRESURE_MIN_CONST=-100,_sfc_main$191={__name:`forcedInduction`,setup(__props,{expose:__expose}){let initialized=ref(!1),pressureTextRef=ref(null),pressureCurveRef=ref(null),pressureCurveLen=computed(()=>pressureCurveRef.value.getTotalLength()),pressureCurveDashesRef=ref(null),pressureCurveDashesLen=computed(()=>pressureCurveDashesRef.value.getTotalLength()),redLineRef=ref(null),redLineLen=computed(()=>redLineRef.value.getTotalLength()),pressureTextGuideLineRef=ref(null),pressureTextGuideLineLen=computed(()=>pressureTextGuideLineRef.value.getTotalLength()),pressureTextRefs=ref([]),pressureTextAttrs=ref([{id:`pressuretext1`,x:197.49423,y:531.5639,text:1},{id:`pressuretext2`,x:124.71793,y:434.92328,text:2},{id:`pressuretext3`,x:110.04411,y:303.35791,text:3},{id:`pressuretext4`,x:165.89227,y:187.39682,text:4},{id:`pressuretext5`,x:284.48657,y:123.71478,text:5},{id:`pressuretext6`,x:419.43579,y:137.55835,text:6},{id:`pressuretext7`,x:520.0791,y:228.94992,text:7},{id:`pressuretext8`,x:520.0791,y:228.94992,text:8},{id:`pressuretext9`,x:520.0791,y:228.94992,text:9},{id:`pressuretext10`,x:520.0791,y:228.94992,text:10}]),pressureTSpanRefs=ref([]),pressureMax=ref(null),pressureMin=ref(null),pressureNeedleRef=ref(null),pressureUnitRef=ref(null),UiUnitscallback=ref(()=>null),roundDecCallback=ref(()=>0);onMounted(()=>{pressureTextRef.value.textContent=``,pressureCurveRef.value.style.strokeDasharray=pressureCurveLen.value+` `+pressureCurveLen.value,pressureTextGuideLineRef.value.style.display=`none`;for(let k=0;k10?0:1),rpSpan.style.visibility=`visible`}initialized.value=!0}applyData(streamData)}function reset$1(){initialized.value=!1;for(let k=0;k1&&(percPos=1),pressureNeedleRef.value.setAttribute(`transform`,`rotate(`+(percPos*270-135)+`,`+width/2+`,`+height/2+`)`),pressureCurveRef.value.style.strokeDashoffset=pressureCurveLen.value-pressureCurveLen.value*percPos}function UnitPressure(val){let convertedVal=UiUnitscallback.value(val,`pressure`);return pressureNeedleRef.value.textContent!==convertedVal.unit&&(pressureUnitRef.value.textContent=convertedVal.unit,initialized.value=!1),convertedVal.val}return(_ctx,_cache)=>(openBlock(),createElementBlock(`svg`,_hoisted_1$171,[_cache[4]||=createBaseVNode(`defs`,{id:`defs4`},[createBaseVNode(`linearGradient`,{id:`linearGradient3938`},[createBaseVNode(`stop`,{style:{"stop-color":`#ff0000`,"stop-opacity":`1`},offset:`0`,id:`stop3940`}),createBaseVNode(`stop`,{style:{"stop-color":`#00ff4b`,"stop-opacity":`1`},offset:`1`,id:`stop3942`})]),createBaseVNode(`linearGradient`,{id:`linearGradient4607`},[createBaseVNode(`stop`,{id:`stop4609`,offset:`0`,style:{"stop-color":`#e40000`,"stop-opacity":`1`}}),createBaseVNode(`stop`,{style:{"stop-color":`#e40000`,"stop-opacity":`1`},offset:`0.89960396`,id:`stop4611`}),createBaseVNode(`stop`,{id:`stop4613`,offset:`1`,style:{"stop-color":`#e40000`,"stop-opacity":`0`}}),createBaseVNode(`stop`,{id:`stop4615`,offset:`1`,style:{"stop-color":`#e40000`,"stop-opacity":`0`}})]),createBaseVNode(`linearGradient`,{id:`linearGradient4597`},[createBaseVNode(`stop`,{id:`stop4599`,offset:`0`,style:{"stop-color":`#e40000`,"stop-opacity":`1`}}),createBaseVNode(`stop`,{style:{"stop-color":`#e40000`,"stop-opacity":`1`},offset:`0.99812102`,id:`stop4601`}),createBaseVNode(`stop`,{id:`stop4603`,offset:`1`,style:{"stop-color":`#e40000`,"stop-opacity":`0`}}),createBaseVNode(`stop`,{id:`stop4605`,offset:`1`,style:{"stop-color":`#e40000`,"stop-opacity":`1`}})]),createBaseVNode(`linearGradient`,{id:`linearGradient4545`},[createBaseVNode(`stop`,{style:{"stop-color":`#e40000`,"stop-opacity":`1`},offset:`0`,id:`stop4547`}),createBaseVNode(`stop`,{id:`stop4553`,offset:`0.9861111`,style:{"stop-color":`#e40000`,"stop-opacity":`1`}}),createBaseVNode(`stop`,{style:{"stop-color":`#e40000`,"stop-opacity":`0`},offset:`1`,id:`stop4555`}),createBaseVNode(`stop`,{style:{"stop-color":`#e40000`,"stop-opacity":`0`},offset:`1`,id:`stop4549`})]),createBaseVNode(`linearGradient`,{"inkscape:collect":`always`,id:`linearGradient4256`},[createBaseVNode(`stop`,{style:{"stop-color":`#6d0000`,"stop-opacity":`1`},offset:`0`,id:`stop4258`}),createBaseVNode(`stop`,{style:{"stop-color":`#6d0000`,"stop-opacity":`0`},offset:`1`,id:`stop4260`})]),createBaseVNode(`linearGradient`,{id:`linearGradient4365`},[createBaseVNode(`stop`,{style:{"stop-color":`#000000`,"stop-opacity":`0.42857143`},offset:`0`,id:`stop4367`}),createBaseVNode(`stop`,{id:`stop4373`,offset:`0.5`,style:{"stop-color":`#000000`,"stop-opacity":`0.33035713`}}),createBaseVNode(`stop`,{style:{"stop-color":`#000000`,"stop-opacity":`0`},offset:`1`,id:`stop4369`})]),createBaseVNode(`linearGradient`,{id:`linearGradient4357`},[createBaseVNode(`stop`,{style:{"stop-color":`#000000`,"stop-opacity":`1`},offset:`0`,id:`stop4359`}),createBaseVNode(`stop`,{style:{"stop-color":`#000000`,"stop-opacity":`0.19642857`},offset:`1`,id:`stop4361`})]),createBaseVNode(`marker`,{style:{overflow:`visible`},id:`DistanceStart`,refX:`0`,refY:`0`,orient:`auto`,"inkscape:stockid":`DistanceStart`},[createBaseVNode(`g`,{id:`g2300`},[createBaseVNode(`path`,{style:{fill:`none`,stroke:`#ffffff`,"stroke-width":`1.14999998`,"stroke-linecap":`square`},d:`M 0,0 2,0`,id:`path2306`,"inkscape:connector-curvature":`0`}),createBaseVNode(`path`,{style:{fill:`#000000`,"fill-rule":`evenodd`,stroke:`none`},d:`M 0,0 13,4 9,0 13,-4 0,0 z`,id:`path2302`,"inkscape:connector-curvature":`0`}),createBaseVNode(`path`,{style:{fill:`none`,stroke:`#000000`,"stroke-width":`1`,"stroke-linecap":`square`},d:`M 0,-4 0,40`,id:`path2304`,"inkscape:connector-curvature":`0`})])]),createBaseVNode(`radialGradient`,{"inkscape:collect":`always`,"xlink:href":`#linearGradient4357`,id:`radialGradient4363`,cx:`480`,cy:`544`,fx:`480`,fy:`544`,r:`320`,gradientUnits:`userSpaceOnUse`,gradientTransform:`matrix(1.03125,0,0,1.03125,-15,-17)`}),createBaseVNode(`radialGradient`,{"inkscape:collect":`always`,"xlink:href":`#linearGradient4365`,id:`radialGradient4371`,cx:`480`,cy:`544`,fx:`480`,fy:`544`,r:`320`,gradientUnits:`userSpaceOnUse`}),createBaseVNode(`clipPath`,{clipPathUnits:`userSpaceOnUse`,id:`clipPath4407`},[createBaseVNode(`path`,{"inkscape:connector-curvature":`0`,id:`path4409`,d:`m 480,-103.33 c -357.5105,0 -647.33,289.8195 -647.33,647.33 0,357.5105 289.8195,647.33 647.33,647.33 357.5105,0 647.33,-289.8195 647.33,-647.33 0,-357.5105 -289.8195,-647.33 -647.33,-647.33 z m 0,453.131 c 107.25316,0 194.199,86.94584 194.199,194.199 0,107.25316 -86.94584,194.199 -194.199,194.199 -107.25316,0 -194.199,-86.94584 -194.199,-194.199 0,-107.25316 86.94584,-194.199 194.199,-194.199 z`,style:{color:`#000000`,fill:`#ffffff`,"fill-opacity":`0.61375661`,"fill-rule":`nonzero`,stroke:`none`,"stroke-width":`16`,marker:`none`,visibility:`visible`,display:`inline`,overflow:`visible`,"enable-background":`accumulate`}})]),createBaseVNode(`clipPath`,{clipPathUnits:`userSpaceOnUse`,id:`clipPath4321-9`},[createBaseVNode(`path`,{style:{color:`#000000`,fill:`#ffffff`,"fill-opacity":`1`,"fill-rule":`nonzero`,stroke:`none`,"stroke-width":`5`,marker:`none`,visibility:`visible`,display:`inline`,overflow:`visible`,"enable-background":`accumulate`},d:`m 480,224 c -20.28024,0 -40.11069,1.89279 -59.34375,5.5 l 12.0625,58.8125 C 448.05208,285.49499 463.85489,284 480,284 c 35.52728,0 69.40254,7.13112 100.25,20.03125 l 24.1875,-54.9375 C 566.18747,232.93508 524.13347,224 480,224 z m -69.0625,7.5 c -59.26533,13.0371 -112.35258,42.49901 -154.28125,83.375 l 42.53125,42.3125 c 24.37935,-23.60266 53.35266,-42.49216 85.46875,-55.15625 1.96795,-0.77601 3.94641,-1.52096 5.9375,-2.25 10.51172,-3.84886 21.33856,-7.01901 32.4375,-9.5 L 410.9375,231.5 z M 613.5,253.125 589.3125,308.03125 c 44.07702,20.45389 81.43119,52.91567 107.9375,93.15625 l 50.875,-31.875 C 715.25578,318.96815 668.59379,278.45303 613.5,253.125 z m -363.8125,68.75 c -41.23795,42.75016 -70.70543,96.92973 -83.125,157.34375 l 59.03125,11.0625 c 10.15322,-48.33557 33.70357,-91.7229 66.625,-126.09375 L 249.6875,321.875 z m 503.78125,55.8125 -50.90625,31.84375 C 726.31882,448.76688 740,494.78478 740,544 l 60,0 c 0,-60.90677 -16.99384,-117.84887 -46.53125,-166.3125 z m -588.75,111.25 C 161.61652,506.82573 160,525.2248 160,544 c 0,42.78463 8.42108,83.60181 23.65625,120.90625 L 238.84375,641.375 C 226.69144,611.30216 220,578.42944 220,544 c 0,-2.24366 0.0373,-4.48871 0.0937,-6.71875 0.3211,-12.67426 1.55282,-25.12039 3.625,-37.28125 l -59,-11.0625 z M 242.75,650.5 187.53125,674 c 23.4008,52.56805 60.5346,97.67196 106.875,130.71875 l 34.0625,-49.4375 C 291.42063,728.66516 261.6562,692.55546 242.75,650.5 z m 93.875,110.40625 -34.03125,49.40625 C 353.37348,844.20872 414.36502,864 480,864 l 0,-60 c -33.65485,0 -65.82451,-6.39115 -95.34375,-18.03125 -1.96795,-0.77601 -3.93088,-1.58396 -5.875,-2.40625 -14.80462,-6.26183 -28.90394,-13.88046 -42.15625,-22.65625 z`,id:`path4323-8`,"inkscape:connector-curvature":`0`})]),createBaseVNode(`radialGradient`,{"inkscape:collect":`always`,"xlink:href":`#linearGradient4357`,id:`radialGradient4363-9`,cx:`480`,cy:`544`,fx:`480`,fy:`544`,r:`320`,gradientUnits:`userSpaceOnUse`,gradientTransform:`matrix(1.03125,0,0,1.03125,-15,-17)`}),createBaseVNode(`clipPath`,{clipPathUnits:`userSpaceOnUse`,id:`clipPath4407-3`},[createBaseVNode(`path`,{"inkscape:connector-curvature":`0`,id:`path4409-5`,d:`m 480,-103.33 c -357.5105,0 -647.33,289.8195 -647.33,647.33 0,357.5105 289.8195,647.33 647.33,647.33 357.5105,0 647.33,-289.8195 647.33,-647.33 0,-357.5105 -289.8195,-647.33 -647.33,-647.33 z m 0,453.131 c 107.25316,0 194.199,86.94584 194.199,194.199 0,107.25316 -86.94584,194.199 -194.199,194.199 -107.25316,0 -194.199,-86.94584 -194.199,-194.199 0,-107.25316 86.94584,-194.199 194.199,-194.199 z`,style:{color:`#000000`,fill:`#ffffff`,"fill-opacity":`0.61375661`,"fill-rule":`nonzero`,stroke:`none`,"stroke-width":`16`,marker:`none`,visibility:`visible`,display:`inline`,overflow:`visible`,"enable-background":`accumulate`}})]),createBaseVNode(`radialGradient`,{gradientTransform:`matrix(0.37015162,0,0,0.37015162,685.90181,-270.76027)`,"inkscape:collect":`always`,"xlink:href":`#linearGradient4365`,id:`radialGradient4371-4`,cx:`480`,cy:`544`,fx:`480`,fy:`544`,r:`320`,gradientUnits:`userSpaceOnUse`}),createBaseVNode(`linearGradient`,{"inkscape:collect":`always`,"xlink:href":`#linearGradient4256`,id:`linearGradient4433`,gradientUnits:`userSpaceOnUse`,x1:`569.20557`,y1:`424.29861`,x2:`890.55139`,y2:`424.29861`}),createBaseVNode(`clipPath`,{clipPathUnits:`userSpaceOnUse`,id:`clipPath4321-4`},[createBaseVNode(`path`,{style:{color:`#000000`,fill:`#ffffff`,"fill-opacity":`1`,"fill-rule":`nonzero`,stroke:`none`,"stroke-width":`5`,marker:`none`,visibility:`visible`,display:`inline`,overflow:`visible`,"enable-background":`accumulate`},d:`m 480,224 c -20.28024,0 -40.11069,1.89279 -59.34375,5.5 l 12.0625,58.8125 C 448.05208,285.49499 463.85489,284 480,284 c 35.52728,0 69.40254,7.13112 100.25,20.03125 l 24.1875,-54.9375 C 566.18747,232.93508 524.13347,224 480,224 z m -69.0625,7.5 c -59.26533,13.0371 -112.35258,42.49901 -154.28125,83.375 l 42.53125,42.3125 c 24.37935,-23.60266 53.35266,-42.49216 85.46875,-55.15625 1.96795,-0.77601 3.94641,-1.52096 5.9375,-2.25 10.51172,-3.84886 21.33856,-7.01901 32.4375,-9.5 L 410.9375,231.5 z M 613.5,253.125 589.3125,308.03125 c 44.07702,20.45389 81.43119,52.91567 107.9375,93.15625 l 50.875,-31.875 C 715.25578,318.96815 668.59379,278.45303 613.5,253.125 z m -363.8125,68.75 c -41.23795,42.75016 -70.70543,96.92973 -83.125,157.34375 l 59.03125,11.0625 c 10.15322,-48.33557 33.70357,-91.7229 66.625,-126.09375 L 249.6875,321.875 z m 503.78125,55.8125 -50.90625,31.84375 C 726.31882,448.76688 740,494.78478 740,544 l 60,0 c 0,-60.90677 -16.99384,-117.84887 -46.53125,-166.3125 z m -588.75,111.25 C 161.61652,506.82573 160,525.2248 160,544 c 0,42.78463 8.42108,83.60181 23.65625,120.90625 L 238.84375,641.375 C 226.69144,611.30216 220,578.42944 220,544 c 0,-2.24366 0.0373,-4.48871 0.0937,-6.71875 0.3211,-12.67426 1.55282,-25.12039 3.625,-37.28125 l -59,-11.0625 z M 242.75,650.5 187.53125,674 c 23.4008,52.56805 60.5346,97.67196 106.875,130.71875 l 34.0625,-49.4375 C 291.42063,728.66516 261.6562,692.55546 242.75,650.5 z m 93.875,110.40625 -34.03125,49.40625 C 353.37348,844.20872 414.36502,864 480,864 l 0,-60 c -33.65485,0 -65.82451,-6.39115 -95.34375,-18.03125 -1.96795,-0.77601 -3.93088,-1.58396 -5.875,-2.40625 -14.80462,-6.26183 -28.90394,-13.88046 -42.15625,-22.65625 z`,id:`path4323-7`,"inkscape:connector-curvature":`0`})]),createBaseVNode(`radialGradient`,{"inkscape:collect":`always`,"xlink:href":`#linearGradient4357`,id:`radialGradient4363-5`,cx:`480`,cy:`544`,fx:`480`,fy:`544`,r:`320`,gradientUnits:`userSpaceOnUse`,gradientTransform:`matrix(1.03125,0,0,1.03125,-15,-17)`}),createBaseVNode(`clipPath`,{clipPathUnits:`userSpaceOnUse`,id:`clipPath4407-6`},[createBaseVNode(`path`,{"inkscape:connector-curvature":`0`,id:`path4409-1`,d:`m 480,-103.33 c -357.5105,0 -647.33,289.8195 -647.33,647.33 0,357.5105 289.8195,647.33 647.33,647.33 357.5105,0 647.33,-289.8195 647.33,-647.33 0,-357.5105 -289.8195,-647.33 -647.33,-647.33 z m 0,453.131 c 107.25316,0 194.199,86.94584 194.199,194.199 0,107.25316 -86.94584,194.199 -194.199,194.199 -107.25316,0 -194.199,-86.94584 -194.199,-194.199 0,-107.25316 86.94584,-194.199 194.199,-194.199 z`,style:{color:`#000000`,fill:`#ffffff`,"fill-opacity":`0.61375661`,"fill-rule":`nonzero`,stroke:`none`,"stroke-width":`16`,marker:`none`,visibility:`visible`,display:`inline`,overflow:`visible`,"enable-background":`accumulate`}})]),createBaseVNode(`radialGradient`,{gradientTransform:`matrix(0.36968813,0,0,0.36968813,1026.9451,-270.68256)`,"inkscape:collect":`always`,"xlink:href":`#linearGradient4365`,id:`radialGradient4371-49`,cx:`480`,cy:`544`,fx:`480`,fy:`544`,r:`320`,gradientUnits:`userSpaceOnUse`}),createBaseVNode(`linearGradient`,{"inkscape:collect":`always`,"xlink:href":`#linearGradient4256`,id:`linearGradient4746`,gradientUnits:`userSpaceOnUse`,x1:`569.20557`,y1:`424.29861`,x2:`890.55139`,y2:`424.29861`}),createBaseVNode(`clipPath`,{clipPathUnits:`userSpaceOnUse`,id:`clipPath3921`},[createBaseVNode(`path`,{"inkscape:connector-curvature":`0`,id:`path3923`,d:`m 480,224 c -20.95323,0 -41.43416,2.01857 -61.26367,5.86328 l 12.08008,58.80274 C 446.74495,285.61583 463.18224,284 480,284 c 36.22419,0 70.7135,7.41519 102.04492,20.79883 l 24.1836,-54.92188 C 567.49749,233.23259 524.82925,224 480,224 z m -67.13867,7.07812 c -60.69914,12.96113 -115.01734,43.12659 -157.60938,85.15821 l 42.54297,42.3125 c 34.42536,-33.82645 78.22177,-58.13556 127.14258,-68.68555 l -12.07617,-58.78516 z m 198.86328,21.20508 -24.1875,54.9336 c 45.44422,20.67199 83.88358,54.04459 110.80078,95.58008 l 50.87305,-31.84376 C 715.93577,319.29347 668.20331,277.82636 611.72461,252.2832 z m -360.70117,68.21094 c -42.37565,43.40627 -72.5223,98.80082 -84.8418,160.63281 l 58.99024,11.05664 c 10.06229,-49.7524 34.33605,-94.34359 68.39257,-129.3789 l -42.54101,-42.31055 z m 501.3789,55.54102 -50.86132,31.83398 C 725.92383,447.46544 740,494.08649 740,544 l 60,0 C 800,482.39079 782.57195,424.85952 752.40234,376.03516 z M 165.06055,487.02148 C 161.7373,505.51211 160,524.55271 160,544 c 0,43.47625 8.68492,84.91949 24.39062,122.71094 l 55.21485,-23.5293 C 226.98058,612.61583 220,579.12541 220,544 c 0,-15.6701 1.38639,-31.01527 4.04297,-45.92188 l -58.98242,-11.05664 z m 76.90039,161.67774 -55.20899,23.52734 c 23.61428,53.92719 61.65397,100.09134 109.25586,133.60352 l 34.03516,-49.41406 C 291.73258,729.3212 261.08736,692.12046 241.96094,648.69922 z m 93.01953,111.12695 -34.04102,49.42188 C 352.04051,843.81227 413.66249,864 480,864 l 0,-60 c -53.69777,0 -103.59151,-16.28243 -145.01953,-44.17383 z`,style:{color:`#000000`,fill:`#ffffff`,"fill-opacity":`1`,"fill-rule":`nonzero`,stroke:`none`,"stroke-width":`5`,marker:`none`,visibility:`visible`,display:`inline`,overflow:`visible`,"enable-background":`accumulate`}})]),createBaseVNode(`clipPath`,{clipPathUnits:`userSpaceOnUse`,id:`clipPath3925-1`},[createBaseVNode(`path`,{"inkscape:connector-curvature":`0`,id:`path3927-7`,d:`m 330,10 c -20.95323,0 -41.43416,2.01857 -61.26367,5.86328 l 12.08008,58.80274 C 296.74495,71.61583 313.18224,70 330,70 c 36.22419,0 70.7135,7.41519 102.04492,20.79883 l 24.1836,-54.92188 C 417.49749,19.23259 374.82925,10 330,10 z m -67.13867,7.07812 C 202.16219,30.03925 147.84399,60.20471 105.25195,102.23633 l 42.54297,42.3125 C 182.22028,110.72238 226.01669,86.41327 274.9375,75.86328 L 262.86133,17.07812 z m 198.86328,21.20508 -24.1875,54.9336 c 45.44422,20.67199 83.88358,54.04459 110.80078,95.58008 l 50.87305,-31.84376 C 565.93577,105.29347 518.20331,63.82636 461.72461,38.2832 z m -360.70117,68.21094 c -42.37565,43.40627 -72.5223,98.80082 -84.8418,160.63281 l 58.99024,11.05664 c 10.06229,-49.7524 34.33605,-94.34359 68.39257,-129.3789 l -42.54101,-42.31055 z m 501.3789,55.54102 -50.86132,31.83398 C 575.92383,233.46544 590,280.08649 590,330 l 60,0 C 650,268.39079 632.57195,210.85952 602.40234,162.03516 z M 15.06055,273.02148 C 11.7373,291.51211 10,310.55271 10,330 c 0,43.47625 8.68492,84.91949 24.39062,122.71094 l 55.21485,-23.5293 C 76.98058,398.61583 70,365.12541 70,330 c 0,-15.6701 1.38639,-31.01527 4.04297,-45.92188 L 15.06055,273.02148 z m 76.90039,161.67774 -55.20899,23.52734 c 23.61428,53.92719 61.65397,100.09134 109.25586,133.60352 l 34.03516,-49.41406 C 141.73258,515.3212 111.08736,478.12046 91.96094,434.69922 z m 93.01953,111.12695 -34.04102,49.42188 C 202.04051,629.81227 263.66249,650 330,650 l 0,-60 c -53.69777,0 -103.59151,-16.28243 -145.01953,-44.17383 z`,style:{color:`#000000`,fill:`#ffffff`,"fill-opacity":`1`,"fill-rule":`nonzero`,stroke:`none`,"stroke-width":`5`,marker:`none`,visibility:`visible`,display:`inline`,overflow:`visible`,"enable-background":`accumulate`}})]),createBaseVNode(`clipPath`,{clipPathUnits:`userSpaceOnUse`,id:`clipPath4036`},[createBaseVNode(`path`,{style:{color:`#000000`,fill:`#ffffff`,"fill-opacity":`1`,"fill-rule":`nonzero`,stroke:`none`,"stroke-width":`5`,marker:`none`,visibility:`visible`,display:`inline`,overflow:`visible`,"enable-background":`accumulate`},d:`m 480,224 c -20.95323,0 -41.43416,2.01857 -61.26367,5.86328 l 12.08008,58.80274 C 446.74495,285.61583 463.18224,284 480,284 c 36.22419,0 70.7135,7.41519 102.04492,20.79883 l 24.1836,-54.92188 C 567.49749,233.23259 524.82925,224 480,224 z m -67.13867,7.07812 c -60.69914,12.96113 -115.01734,43.12659 -157.60938,85.15821 l 42.54297,42.3125 c 34.42536,-33.82645 78.22177,-58.13556 127.14258,-68.68555 l -12.07617,-58.78516 z m 198.86328,21.20508 -24.1875,54.9336 c 45.44422,20.67199 83.88358,54.04459 110.80078,95.58008 l 50.87305,-31.84376 C 715.93577,319.29347 668.20331,277.82636 611.72461,252.2832 z m -360.70117,68.21094 c -42.37565,43.40627 -72.5223,98.80082 -84.8418,160.63281 l 58.99024,11.05664 c 10.06229,-49.7524 34.33605,-94.34359 68.39257,-129.3789 l -42.54101,-42.31055 z m 501.3789,55.54102 -50.86132,31.83398 C 725.92383,447.46544 740,494.08649 740,544 l 60,0 C 800,482.39079 782.57195,424.85952 752.40234,376.03516 z M 165.06055,487.02148 C 161.7373,505.51211 160,524.55271 160,544 c 0,43.47625 8.68492,84.91949 24.39062,122.71094 l 55.21485,-23.5293 C 226.98058,612.61583 220,579.12541 220,544 c 0,-15.6701 1.38639,-31.01527 4.04297,-45.92188 l -58.98242,-11.05664 z m 76.90039,161.67774 -55.20899,23.52734 c 23.61428,53.92719 61.65397,100.09134 109.25586,133.60352 l 34.03516,-49.41406 C 291.73258,729.3212 261.08736,692.12046 241.96094,648.69922 z m 93.01953,111.12695 -34.04102,49.42188 C 352.04051,843.81227 413.66249,864 480,864 l 0,-60 c -53.69777,0 -103.59151,-16.28243 -145.01953,-44.17383 z`,id:`path4038`,"inkscape:connector-curvature":`0`})]),createBaseVNode(`linearGradient`,{"inkscape:collect":`always`,"xlink:href":`#linearGradient4545`,id:`linearGradient4551`,x1:`480`,y1:`214`,x2:`480`,y2:`474`,gradientUnits:`userSpaceOnUse`}),createBaseVNode(`linearGradient`,{"inkscape:collect":`always`,"xlink:href":`#linearGradient4545-2`,id:`linearGradient4551-8`,x1:`480`,y1:`214`,x2:`480`,y2:`474`,gradientUnits:`userSpaceOnUse`}),createBaseVNode(`linearGradient`,{id:`linearGradient4545-2`},[createBaseVNode(`stop`,{style:{"stop-color":`#e40000`,"stop-opacity":`1`},offset:`0`,id:`stop4547-4`}),createBaseVNode(`stop`,{id:`stop4553-5`,offset:`0.99000001`,style:{"stop-color":`#e40000`,"stop-opacity":`0`}}),createBaseVNode(`stop`,{style:{"stop-color":`#000000`,"stop-opacity":`0`},offset:`1`,id:`stop4555-5`}),createBaseVNode(`stop`,{style:{"stop-color":`#000000`,"stop-opacity":`0`},offset:`1`,id:`stop4549-1`})]),createBaseVNode(`linearGradient`,{y2:`282.59341`,x2:`474.60886`,y1:`211.1199`,x1:`480`,gradientUnits:`userSpaceOnUse`,id:`linearGradient4574`,"xlink:href":`#linearGradient4607`,"inkscape:collect":`always`,gradientTransform:`matrix(1,0,0,0.9882541,0,10.359887)`}),createBaseVNode(`clipPath`,{clipPathUnits:`userSpaceOnUse`,id:`clipPath4036-1`},[createBaseVNode(`path`,{style:{color:`#000000`,fill:`#ffffff`,"fill-opacity":`1`,"fill-rule":`nonzero`,stroke:`none`,"stroke-width":`5`,marker:`none`,visibility:`visible`,display:`inline`,overflow:`visible`,"enable-background":`accumulate`},d:`m 480,224 c -20.95323,0 -41.43416,2.01857 -61.26367,5.86328 l 12.08008,58.80274 C 446.74495,285.61583 463.18224,284 480,284 c 36.22419,0 70.7135,7.41519 102.04492,20.79883 l 24.1836,-54.92188 C 567.49749,233.23259 524.82925,224 480,224 z m -67.13867,7.07812 c -60.69914,12.96113 -115.01734,43.12659 -157.60938,85.15821 l 42.54297,42.3125 c 34.42536,-33.82645 78.22177,-58.13556 127.14258,-68.68555 l -12.07617,-58.78516 z m 198.86328,21.20508 -24.1875,54.9336 c 45.44422,20.67199 83.88358,54.04459 110.80078,95.58008 l 50.87305,-31.84376 C 715.93577,319.29347 668.20331,277.82636 611.72461,252.2832 z m -360.70117,68.21094 c -42.37565,43.40627 -72.5223,98.80082 -84.8418,160.63281 l 58.99024,11.05664 c 10.06229,-49.7524 34.33605,-94.34359 68.39257,-129.3789 l -42.54101,-42.31055 z m 501.3789,55.54102 -50.86132,31.83398 C 725.92383,447.46544 740,494.08649 740,544 l 60,0 C 800,482.39079 782.57195,424.85952 752.40234,376.03516 z M 165.06055,487.02148 C 161.7373,505.51211 160,524.55271 160,544 c 0,43.47625 8.68492,84.91949 24.39062,122.71094 l 55.21485,-23.5293 C 226.98058,612.61583 220,579.12541 220,544 c 0,-15.6701 1.38639,-31.01527 4.04297,-45.92188 l -58.98242,-11.05664 z m 76.90039,161.67774 -55.20899,23.52734 c 23.61428,53.92719 61.65397,100.09134 109.25586,133.60352 l 34.03516,-49.41406 C 291.73258,729.3212 261.08736,692.12046 241.96094,648.69922 z m 93.01953,111.12695 -34.04102,49.42188 C 352.04051,843.81227 413.66249,864 480,864 l 0,-60 c -53.69777,0 -103.59151,-16.28243 -145.01953,-44.17383 z`,id:`path4038-7`,"inkscape:connector-curvature":`0`})]),createBaseVNode(`radialGradient`,{"inkscape:collect":`always`,"xlink:href":`#linearGradient4357-0`,id:`radialGradient4363-4`,cx:`480`,cy:`544`,fx:`480`,fy:`544`,r:`320`,gradientUnits:`userSpaceOnUse`,gradientTransform:`matrix(1.03125,0,0,1.03125,-15,-17)`}),createBaseVNode(`linearGradient`,{id:`linearGradient4357-0`},[createBaseVNode(`stop`,{style:{"stop-color":`#000000`,"stop-opacity":`0.65178573`},offset:`0`,id:`stop4359-9`}),createBaseVNode(`stop`,{style:{"stop-color":`#000000`,"stop-opacity":`0.24107143`},offset:`1`,id:`stop4361-4`})]),createBaseVNode(`radialGradient`,{"inkscape:collect":`always`,"xlink:href":`#linearGradient4365-4`,id:`radialGradient4371-2`,cx:`480`,cy:`544`,fx:`480`,fy:`544`,r:`320`,gradientUnits:`userSpaceOnUse`}),createBaseVNode(`linearGradient`,{id:`linearGradient4365-4`},[createBaseVNode(`stop`,{style:{"stop-color":`#000000`,"stop-opacity":`0.42857143`},offset:`0`,id:`stop4367-5`}),createBaseVNode(`stop`,{id:`stop4373-5`,offset:`0.5`,style:{"stop-color":`#000000`,"stop-opacity":`0.33035713`}}),createBaseVNode(`stop`,{style:{"stop-color":`#000000`,"stop-opacity":`0`},offset:`1`,id:`stop4369-1`})]),createBaseVNode(`radialGradient`,{r:`320`,fy:`544`,fx:`480`,cy:`544`,cx:`480`,gradientUnits:`userSpaceOnUse`,id:`radialGradient3997`,"xlink:href":`#linearGradient4365-4`,"inkscape:collect":`always`}),createBaseVNode(`radialGradient`,{"inkscape:collect":`always`,"xlink:href":`#linearGradient4357-0-7`,id:`radialGradient4363-4-1`,cx:`480`,cy:`544`,fx:`480`,fy:`544`,r:`320`,gradientUnits:`userSpaceOnUse`,gradientTransform:`matrix(1.03125,0,0,1.03125,-15,-17)`}),createBaseVNode(`linearGradient`,{id:`linearGradient4357-0-7`},[createBaseVNode(`stop`,{style:{"stop-color":`#000000`,"stop-opacity":`0.51785713`},offset:`0`,id:`stop4359-9-4`}),createBaseVNode(`stop`,{style:{"stop-color":`#000000`,"stop-opacity":`0.11607143`},offset:`1`,id:`stop4361-4-0`})]),createBaseVNode(`radialGradient`,{r:`320`,fy:`544`,fx:`480`,cy:`544`,cx:`480`,gradientTransform:`matrix(1.03125,0,0,1.03125,-15,-17)`,gradientUnits:`userSpaceOnUse`,id:`radialGradient4001`,"xlink:href":`#linearGradient4357-0-7`,"inkscape:collect":`always`}),createBaseVNode(`radialGradient`,{"inkscape:collect":`always`,"xlink:href":`#linearGradient4357-0-7`,id:`radialGradient4040`,gradientUnits:`userSpaceOnUse`,gradientTransform:`matrix(1.03125,0,0,1.03125,-885,-231)`,cx:`480`,cy:`544`,fx:`480`,fy:`544`,r:`320`}),createBaseVNode(`radialGradient`,{"inkscape:collect":`always`,"xlink:href":`#linearGradient4357-0-7`,id:`radialGradient4045`,gradientUnits:`userSpaceOnUse`,gradientTransform:`matrix(1.03125,0,0,1.03125,-885,-231)`,cx:`480`,cy:`544`,fx:`480`,fy:`544`,r:`320`}),createBaseVNode(`radialGradient`,{"inkscape:collect":`always`,"xlink:href":`#linearGradient4357-0-7-2`,id:`radialGradient4045-8`,gradientUnits:`userSpaceOnUse`,gradientTransform:`matrix(1.03125,0,0,1.03125,-885,-231)`,cx:`480`,cy:`544`,fx:`480`,fy:`544`,r:`320`}),createBaseVNode(`linearGradient`,{id:`linearGradient4357-0-7-2`},[createBaseVNode(`stop`,{style:{"stop-color":`#000000`,"stop-opacity":`0.51785713`},offset:`0`,id:`stop4359-9-4-4`}),createBaseVNode(`stop`,{style:{"stop-color":`#000000`,"stop-opacity":`0.11607143`},offset:`1`,id:`stop4361-4-0-5`})]),createBaseVNode(`radialGradient`,{r:`320`,fy:`544`,fx:`480`,cy:`544`,cx:`480`,gradientTransform:`matrix(1.03125,0,0,1.03125,-758.53125,-231)`,gradientUnits:`userSpaceOnUse`,id:`radialGradient4063`,"xlink:href":`#linearGradient4357-0-7-2`,"inkscape:collect":`always`}),createBaseVNode(`radialGradient`,{"inkscape:collect":`always`,"xlink:href":`#linearGradient4357-0-7`,id:`radialGradient4082`,gradientUnits:`userSpaceOnUse`,gradientTransform:`matrix(1.03125,0,0,1.03125,-885,-231)`,cx:`480`,cy:`544`,fx:`480`,fy:`544`,r:`320`}),createBaseVNode(`radialGradient`,{"inkscape:collect":`always`,"xlink:href":`#linearGradient4357-0-8`,id:`radialGradient4363-4-9`,cx:`480`,cy:`544`,fx:`480`,fy:`544`,r:`320`,gradientUnits:`userSpaceOnUse`,gradientTransform:`matrix(1.03125,0,0,1.03125,-15,-17)`}),createBaseVNode(`linearGradient`,{id:`linearGradient4357-0-8`},[createBaseVNode(`stop`,{style:{"stop-color":`#000000`,"stop-opacity":`0.51785713`},offset:`0`,id:`stop4359-9-40`}),createBaseVNode(`stop`,{style:{"stop-color":`#000000`,"stop-opacity":`0.11607143`},offset:`1`,id:`stop4361-4-7`})]),createBaseVNode(`radialGradient`,{r:`320`,fy:`544`,fx:`480`,cy:`544`,cx:`480`,gradientTransform:`matrix(1.03125,0,0,1.03125,-15,-17)`,gradientUnits:`userSpaceOnUse`,id:`radialGradient4031-1`,"xlink:href":`#linearGradient4357-0-8-5`,"inkscape:collect":`always`}),createBaseVNode(`linearGradient`,{id:`linearGradient4357-0-8-5`},[createBaseVNode(`stop`,{style:{"stop-color":`#000000`,"stop-opacity":`0.51785713`},offset:`0`,id:`stop4359-9-40-4`}),createBaseVNode(`stop`,{style:{"stop-color":`#000000`,"stop-opacity":`0.11607143`},offset:`1`,id:`stop4361-4-7-2`})]),createBaseVNode(`radialGradient`,{"inkscape:collect":`always`,"xlink:href":`#linearGradient4357-0-3`,id:`radialGradient4363-4-0`,cx:`480`,cy:`544`,fx:`480`,fy:`544`,r:`320`,gradientUnits:`userSpaceOnUse`,gradientTransform:`matrix(1.03125,0,0,1.03125,-15,-17)`}),createBaseVNode(`linearGradient`,{id:`linearGradient4357-0-3`},[createBaseVNode(`stop`,{style:{"stop-color":`#000000`,"stop-opacity":`0.65178573`},offset:`0`,id:`stop4359-9-8`}),createBaseVNode(`stop`,{style:{"stop-color":`#000000`,"stop-opacity":`0.24107143`},offset:`1`,id:`stop4361-4-01`})]),createBaseVNode(`clipPath`,{clipPathUnits:`userSpaceOnUse`,id:`clipPath4407-8-2`},[createBaseVNode(`path`,{"inkscape:connector-curvature":`0`,id:`path4409-8-5`,d:`m 480,-103.33 c -357.5105,0 -647.33,289.8195 -647.33,647.33 0,357.5105 289.8195,647.33 647.33,647.33 357.5105,0 647.33,-289.8195 647.33,-647.33 0,-357.5105 -289.8195,-647.33 -647.33,-647.33 z m 0,453.131 c 107.25316,0 194.199,86.94584 194.199,194.199 0,107.25316 -86.94584,194.199 -194.199,194.199 -107.25316,0 -194.199,-86.94584 -194.199,-194.199 0,-107.25316 86.94584,-194.199 194.199,-194.199 z`,style:{color:`#000000`,fill:`#ffffff`,"fill-opacity":`0.61375661`,"fill-rule":`nonzero`,stroke:`none`,"stroke-width":`16`,marker:`none`,visibility:`visible`,display:`inline`,overflow:`visible`,"enable-background":`accumulate`}})]),createBaseVNode(`radialGradient`,{r:`320`,fy:`544`,fx:`480`,cy:`544`,cx:`480`,gradientTransform:`matrix(1.03125,0,0,1.03125,-15,-17)`,gradientUnits:`userSpaceOnUse`,id:`radialGradient4401`,"xlink:href":`#linearGradient4357-0-3`,"inkscape:collect":`always`}),createBaseVNode(`radialGradient`,{r:`320`,fy:`544`,fx:`480`,cy:`544`,cx:`480`,gradientUnits:`userSpaceOnUse`,id:`radialGradient3997-4`,"xlink:href":`#linearGradient4365-4-7`,"inkscape:collect":`always`}),createBaseVNode(`linearGradient`,{id:`linearGradient4365-4-7`},[createBaseVNode(`stop`,{style:{"stop-color":`#000000`,"stop-opacity":`0.42857143`},offset:`0`,id:`stop4367-5-8`}),createBaseVNode(`stop`,{id:`stop4373-5-3`,offset:`0.5`,style:{"stop-color":`#000000`,"stop-opacity":`0.33035713`}}),createBaseVNode(`stop`,{style:{"stop-color":`#000000`,"stop-opacity":`0`},offset:`1`,id:`stop4369-1-5`})]),createBaseVNode(`radialGradient`,{r:`320`,fy:`544`,fx:`480`,cy:`544`,cx:`480`,gradientUnits:`userSpaceOnUse`,id:`radialGradient4458`,"xlink:href":`#linearGradient4365-4-7`,"inkscape:collect":`always`}),createBaseVNode(`clipPath`,{clipPathUnits:`userSpaceOnUse`,id:`clipPath3653`},[createBaseVNode(`path`,{style:{color:`#000000`,display:`inline`,overflow:`visible`,visibility:`visible`,fill:`#ffffff`,"fill-opacity":`0.61375661`,"fill-rule":`nonzero`,stroke:`none`,"stroke-width":`16`,marker:`none`,"enable-background":`accumulate`},d:`M 480,84 C 225.94901,84 20,289.94901 20,544 20,798.05099 225.94901,1004 480,1004 734.05099,1004 940,798.05099 940,544 940,289.94901 734.05099,84 480,84 Z m 0,322 c 76.21531,0 138,61.78469 138,138 0,76.21531 -61.78469,138 -138,138 -76.21531,0 -138,-61.78469 -138,-138 0,-76.21531 61.78469,-138 138,-138 z`,id:`path3655`,"inkscape:connector-curvature":`0`})]),createBaseVNode(`clipPath`,{clipPathUnits:`userSpaceOnUse`,id:`clipPath4490`},[createBaseVNode(`path`,{style:{color:`#000000`,"font-style":`normal`,"font-variant":`normal`,"font-weight":`normal`,"font-stretch":`normal`,"font-size":`medium`,"line-height":`normal`,"font-family":`sans-serif`,"text-indent":`0`,"text-align":`start`,"text-decoration":`none`,"text-decoration-line":`none`,"text-decoration-style":`solid`,"text-decoration-color":`#000000`,"letter-spacing":`normal`,"word-spacing":`normal`,"text-transform":`none`,direction:`ltr`,"block-progression":`tb`,"writing-mode":`lr-tb`,"baseline-shift":`baseline`,"text-anchor":`start`,"white-space":`normal`,"clip-rule":`nonzero`,display:`inline`,overflow:`visible`,visibility:`visible`,opacity:`1`,isolation:`auto`,"mix-blend-mode":`normal`,"color-interpolation":`sRGB`,"color-interpolation-filters":`linearRGB`,"solid-color":`#000000`,"solid-opacity":`1`,fill:`#000000`,"fill-opacity":`1`,"fill-rule":`evenodd`,stroke:`none`,"stroke-width":`96.91093445`,"stroke-linecap":`butt`,"stroke-linejoin":`miter`,"stroke-miterlimit":`4`,"stroke-dasharray":`none`,"stroke-dashoffset":`0`,"stroke-opacity":`1`,"color-rendering":`auto`,"image-rendering":`auto`,"shape-rendering":`auto`,"text-rendering":`auto`,"enable-background":`accumulate`},d:`m 330,10 c -176.15718,3e-6 -319.999997,143.84282 -320,320 0,88.07859 35.961054,168.07824 93.94141,226.05859 l 68.0957,-68.0957 C 131.73748,447.66326 106.91016,391.89131 106.91016,330 c 0,-123.78262 99.30722,-223.08984 223.08984,-223.08984 123.78262,0 223.08984,99.30722 223.08984,223.08984 0,61.89131 -24.82732,117.66326 -65.12695,157.96289 l 68.0957,68.0957 C 614.03895,498.07824 650,418.07859 650,330 650,153.84282 506.15718,10 330,10 Z`,id:`path4492`,"inkscape:connector-curvature":`0`})]),createBaseVNode(`clipPath`,{clipPathUnits:`userSpaceOnUse`,id:`clipPath4494`},[createBaseVNode(`path`,{style:{color:`#000000`,"font-style":`normal`,"font-variant":`normal`,"font-weight":`normal`,"font-stretch":`normal`,"font-size":`medium`,"line-height":`normal`,"font-family":`sans-serif`,"text-indent":`0`,"text-align":`start`,"text-decoration":`none`,"text-decoration-line":`none`,"text-decoration-style":`solid`,"text-decoration-color":`#000000`,"letter-spacing":`normal`,"word-spacing":`normal`,"text-transform":`none`,direction:`ltr`,"block-progression":`tb`,"writing-mode":`lr-tb`,"baseline-shift":`baseline`,"text-anchor":`start`,"white-space":`normal`,"clip-rule":`nonzero`,display:`inline`,overflow:`visible`,visibility:`visible`,opacity:`1`,isolation:`auto`,"mix-blend-mode":`normal`,"color-interpolation":`sRGB`,"color-interpolation-filters":`linearRGB`,"solid-color":`#000000`,"solid-opacity":`1`,fill:`#000000`,"fill-opacity":`1`,"fill-rule":`evenodd`,stroke:`none`,"stroke-width":`96.91093445`,"stroke-linecap":`butt`,"stroke-linejoin":`miter`,"stroke-miterlimit":`4`,"stroke-dasharray":`none`,"stroke-dashoffset":`0`,"stroke-opacity":`1`,"color-rendering":`auto`,"image-rendering":`auto`,"shape-rendering":`auto`,"text-rendering":`auto`,"enable-background":`accumulate`},d:`m 330,10 c -176.15718,3e-6 -319.999997,143.84282 -320,320 0,88.07859 35.961054,168.07824 93.94141,226.05859 l 68.0957,-68.0957 C 131.73748,447.66326 106.91016,391.89131 106.91016,330 c 0,-123.78262 99.30722,-223.08984 223.08984,-223.08984 123.78262,0 223.08984,99.30722 223.08984,223.08984 0,61.89131 -24.82732,117.66326 -65.12695,157.96289 l 68.0957,68.0957 C 614.03895,498.07824 650,418.07859 650,330 650,153.84282 506.15718,10 330,10 Z`,id:`path4496`,"inkscape:connector-curvature":`0`})]),createBaseVNode(`clipPath`,{clipPathUnits:`userSpaceOnUse`,id:`clipPath4498`},[createBaseVNode(`path`,{style:{color:`#000000`,"font-style":`normal`,"font-variant":`normal`,"font-weight":`normal`,"font-stretch":`normal`,"font-size":`medium`,"line-height":`normal`,"font-family":`sans-serif`,"text-indent":`0`,"text-align":`start`,"text-decoration":`none`,"text-decoration-line":`none`,"text-decoration-style":`solid`,"text-decoration-color":`#000000`,"letter-spacing":`normal`,"word-spacing":`normal`,"text-transform":`none`,direction:`ltr`,"block-progression":`tb`,"writing-mode":`lr-tb`,"baseline-shift":`baseline`,"text-anchor":`start`,"white-space":`normal`,"clip-rule":`nonzero`,display:`inline`,overflow:`visible`,visibility:`visible`,opacity:`1`,isolation:`auto`,"mix-blend-mode":`normal`,"color-interpolation":`sRGB`,"color-interpolation-filters":`linearRGB`,"solid-color":`#000000`,"solid-opacity":`1`,fill:`#000000`,"fill-opacity":`1`,"fill-rule":`evenodd`,stroke:`none`,"stroke-width":`96.91093445`,"stroke-linecap":`butt`,"stroke-linejoin":`miter`,"stroke-miterlimit":`4`,"stroke-dasharray":`none`,"stroke-dashoffset":`0`,"stroke-opacity":`1`,"color-rendering":`auto`,"image-rendering":`auto`,"shape-rendering":`auto`,"text-rendering":`auto`,"enable-background":`accumulate`},d:`m 240.41631,-226.27417 c -124.56194,124.56194 -124.56194,327.9864 0,452.54834 62.28096,62.28097 144.27756,93.42096 226.27417,93.42095 l 0,-96.30186 c -56.99229,0 -113.98458,-21.88116 -157.74834,-65.64492 -87.52753,-87.527531 -87.52753,-227.969149 0,-315.49668 87.52753,-87.52753 227.96915,-87.52753 315.49668,0 C 668.20258,-113.98457 690.08374,-56.992283 690.08374,0 l 96.30186,0 c 1e-5,-81.996605 -31.13998,-163.9932 -93.42095,-226.27417 -124.56194,-124.56194 -327.98641,-124.56194 -452.54834,0 z`,id:`path4500`,"inkscape:connector-curvature":`0`})])],-1),_cache[5]||=createBaseVNode(`g`,{"inkscape:label":`background`,"inkscape:groupmode":`layer`,id:`layer1`,transform:`translate(-150,-242.36218)`,style:{display:`none`,opacity:`1`}},[createBaseVNode(`rect`,{style:{fill:`#505050`,"fill-opacity":`1`,stroke:`none`},id:`rect4616`,width:`2175.3789`,height:`1458.4727`,x:`-727.47485`,y:`-115.47279`})],-1),createBaseVNode(`g`,_hoisted_2$140,[_cache[0]||=createBaseVNode(`circle`,{style:{color:`#000000`,display:`inline`,overflow:`visible`,visibility:`visible`,fill:`url(#radialGradient3997)`,"fill-opacity":`1`,"fill-rule":`nonzero`,stroke:`none`,"stroke-width":`16`,marker:`none`,"enable-background":`accumulate`},id:`path4281-5`,cx:`480`,cy:`544`,r:`320`,transform:`translate(-150,-214)`},null,-1),_cache[1]||=createBaseVNode(`path`,{style:{color:`#000000`,display:`inline`,overflow:`visible`,visibility:`visible`,fill:`url(#radialGradient4363-4)`,"fill-opacity":`1`,"fill-rule":`nonzero`,stroke:`none`,"stroke-width":`6`,marker:`none`,"enable-background":`accumulate`},d:`M 480,214 C 297.74603,214 150,361.74603 150,544 150,726.25397 297.74603,874 480,874 662.25397,874 810,726.25397 810,544 810,361.74603 662.25397,214 480,214 Z`,id:`path4281`,"inkscape:connector-curvature":`0`,"sodipodi:nodetypes":`sssss`,"clip-path":`url(#clipPath3653)`,transform:`translate(-150,-214)`},null,-1),createBaseVNode(`text`,_hoisted_3$126,[createBaseVNode(`tspan`,{ref_key:`pressureTextRef`,ref:pressureTextRef,"sodipodi:role":`line`,id:`pressureText`,x:`329.85437`,y:`328.48807`,style:{"font-style":`normal`,"font-variant":`normal`,"font-weight":`normal`,"font-stretch":`normal`,"font-size":`159.64709473px`,"line-height":`125%`,"font-family":`'Squada One'`,"-inkscape-font-specification":`'Squada One'`,"text-align":`center`,"writing-mode":`lr-tb`,"text-anchor":`middle`,fill:`#ffffff`,"fill-opacity":`1`}},` 0`,512)]),createBaseVNode(`text`,_hoisted_4$103,[createBaseVNode(`tspan`,{ref_key:`pressureUnitRef`,ref:pressureUnitRef,"sodipodi:role":`line`,id:`pressureunit`,x:`329.03198`,y:`413.62915`},`PSI`,512)]),(openBlock(!0),createElementBlock(Fragment,null,renderList(pressureTextAttrs.value,attrs=>(openBlock(),createElementBlock(`text`,{ref_for:!0,ref:el=>pressureTextRefs.value.push(el),"xml:space":`preserve`,class:`pressure-text`,id:attrs.id+`p`,x:attrs.x,y:attrs.y},[createBaseVNode(`tspan`,{ref_for:!0,ref:el2=>pressureTSpanRefs.value.push(el2),id:attrs.id,x:attrs.x,y:attrs.y},toDisplayString(attrs.text),9,_hoisted_6$74)],8,_hoisted_5$89))),256))]),createBaseVNode(`g`,_hoisted_7$64,[createBaseVNode(`g`,_hoisted_8$51,[_cache[2]||=createBaseVNode(`rect`,{style:{color:`#000000`,display:`inline`,overflow:`visible`,visibility:`visible`,fill:`#000000`,"fill-opacity":`0.37037036`,"fill-rule":`nonzero`,stroke:`none`,"stroke-width":`16`,marker:`none`,"enable-background":`accumulate`},id:`rect4001`,width:`683.79401`,height:`683.79401`,x:`127.97179`,y:`-340.09323`,transform:`matrix(0.70710678,0.70710678,-0.70710678,0.70710678,0,0)`,"clip-path":`url(#clipPath4498)`},null,-1),createBaseVNode(`path`,{ref_key:`pressureCurveRef`,ref:pressureCurveRef,style:{color:`#000000`,display:`inline`,overflow:`visible`,visibility:`visible`,fill:`none`,stroke:`#ffffff`,"stroke-width":`99.31034088`,"stroke-miterlimit":`4`,"stroke-dasharray":`2374.27468498, 2374.27468498`,"stroke-dashoffset":`0`,"stroke-opacity":`1`,marker:`none`,"enable-background":`accumulate`},d:`M 147.9957,528.59996 C 50,420 27.118653,298.1594 119.95323,156.00847 150,110 350,-30 532.60856,149.71493 c 74.5117,73.33098 97.08931,264.86379 -10.87668,369.15745`,id:`pressureCurve`,"clip-path":`url(#clipPath4494)`},null,512),createBaseVNode(`path`,{ref_key:`redLineRef`,ref:redLineRef,style:{color:`#000000`,overflow:`visible`,visibility:`visible`,fill:`none`,stroke:`#9c0000`,"stroke-width":`117.91827393`,"stroke-linecap":`butt`,"stroke-linejoin":`bevel`,"stroke-miterlimit":`4`,"stroke-dasharray":`none`,"stroke-dashoffset":`604.6484375`,"stroke-opacity":`0.66137564`,marker:`none`,"enable-background":`accumulate`},d:`M 147.99571,510.41274 C 33.434043,395.42128 59.279735,242.76116 138.14044,153.71911 230,50 387.77546,50.913502 485.67663,112.95746 c 165.77018,105.05531 132.03401,312.46382 37.32761,407.0596`,id:`pressure_redline`,"clip-path":`url(#clipPath4490)`},null,512)])]),createBaseVNode(`g`,_hoisted_9$45,[createBaseVNode(`path`,{ref_key:`pressureCurveDashesRef`,ref:pressureCurveDashesRef,style:{display:`inline`,fill:`none`,stroke:`#000000`,"stroke-width":`96.91100311`,"stroke-miterlimit":`0.40000001`,"stroke-dasharray":`48.4555, 48.4555`,"stroke-dashoffset":`0`,"stroke-opacity":`0.37566139`},d:`m 137.9887,522.0113 c -106.044908,-106.04491 -106.044903,-277.97769 1e-5,-384.0226 106.04491,-106.044917 277.97767,-106.044914 384.02259,0 106.04491,106.04491 106.04492,277.97769 10e-6,384.0226`,id:`pressureCurve_dashes`,"inkscape:connector-curvature":`0`,"sodipodi:nodetypes":`cssc`,"inkscape:label":`#path4531-4`},null,512),createBaseVNode(`path`,{ref_key:`pressureTextGuideLineRef`,ref:pressureTextGuideLineRef,style:{display:`inline`,fill:`none`,stroke:`#e90000`,"stroke-width":`2.86352348`,"stroke-miterlimit":`0.40000001`,"stroke-dasharray":`none`,"stroke-dashoffset":`0`,"stroke-opacity":`0.24404764`},d:`m 202.03513,457.96488 c -70.12576,-70.12575 -70.12576,-183.82209 0,-253.94784 70.12575,-70.12576 183.82208,-70.12576 253.94784,0 70.12575,70.12575 70.12575,183.82209 0,253.94784`,id:`pressuretextline`,"inkscape:connector-curvature":`0`,"sodipodi:nodetypes":`cssc`,"inkscape:label":`#path4531-4`},null,512)]),createBaseVNode(`g`,_hoisted_10$38,[createBaseVNode(`g`,{ref_key:`pressureNeedleRef`,ref:pressureNeedleRef,id:`pressure_needle_d`,"inkscape:label":`#g4147`,transform:`translate(-1.2852971e-6,1.993565e-6)`},[..._cache[3]||=[createBaseVNode(`rect`,{y:`7.0002151`,x:`322.0993`,height:`103.00317`,width:`12.038266`,id:`rect4625`,style:{color:`#000000`,display:`inline`,overflow:`visible`,visibility:`visible`,fill:`#d70000`,"fill-opacity":`1`,"fill-rule":`nonzero`,stroke:`none`,"stroke-width":`67.38899994`,marker:`none`,"enable-background":`accumulate`},transform:`matrix(1,0,0.00784004,0.99996927,0,0)`},null,-1),createBaseVNode(`rect`,{transform:`scale(1,-1)`,y:`-660`,x:`322.44037`,height:`660`,width:`15.11928`,id:`rect4625-1`,style:{color:`#000000`,display:`inline`,overflow:`visible`,visibility:`visible`,fill:`#008000`,"fill-opacity":`0`,"fill-rule":`nonzero`,stroke:`none`,"stroke-width":`67.38899994`,marker:`none`,"enable-background":`accumulate`}},null,-1)]],512)])]))}},forcedInduction_default=__plugin_vue_export_helper_default(_sfc_main$191,[[`__scopeId`,`data-v-a0f39cc4`]]),_sfc_main$190={__name:`app`,setup(__props){let{$game}=useLibStore(),forcedInductionRef=ref(null),fiContainerRef=ref(null),enabled=ref(!1);return onMounted(()=>{forcedInductionRef.value.wireThroughRoundDec(roundDec),forcedInductionRef.value.wireThroughUnitSystem((val,func)=>UiUnits[func](val)),$game.streams.add([`forcedInductionInfo`])}),onUnmounted(()=>{$game.streams.remove([`forcedInductionInfo`])}),$game.events.on(`VechicleChange`,()=>forcedInductionRef.value.reset()),$game.events.on(`VehicleFocusChanged`,data=>{data.mode==1&&forcedInductionRef.value!==null&&forcedInductionRef.value.reset()}),$game.events.on(`onStreamsUpdate`,streams=>{if(forcedInductionRef.value===null)return;let newEnabled=forcedInductionRef.value.isStreamValid(streams);newEnabled?(newEnabled&&!enabled.value&&(fiContainerRef.value.style.opacity=1),forcedInductionRef.value.update(streams)):!newEnabled&&enabled&&(fiContainerRef.value.style.opacity=0),enabled.value=newEnabled}),(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,{ref_key:`fiContainerRef`,ref:fiContainerRef,class:`fi-container`},[createVNode(forcedInduction_default,{ref_key:`forcedInductionRef`,ref:forcedInductionRef},null,512)],512))}},app_default$20=__plugin_vue_export_helper_default(_sfc_main$190,[[`__scopeId`,`data-v-3ea976f6`]]),_hoisted_1$170={class:`fi-debug`},_hoisted_2$139={class:`name`},_hoisted_3$125={class:`value`},_sfc_main$189={__name:`app`,setup(__props){let{$game}=useLibStore(),streamsList$1=[`forcedInductionInfo`],defaultMeasures=[{name:`RPM`,key:`rpm`},{name:`Boost`,key:`boost`,type:`pressure`},{name:`Power Coef`,key:`coef`},{name:`Pressure Pulses`,key:`pulses`},{name:`SC Loss`,key:`loss`},{name:`Exhaust Power`,key:`exhaustPower`},{name:`Friction`,key:`friction`},{name:`Backpressure`,key:`backpressure`},{name:`Wastegate Factor`,key:`wastegateFactor`},{name:`Turbo Temp`,key:`turboTemp`,type:`temperature`}],measures=ref([]),filteredMeasures=computed(()=>measures.value.filter(m=>m.val!==void 0));onMounted(()=>{$game.streams.add(streamsList$1),$game.events.on(`onStreamsUpdate`,onStreamsUpdate),$game.events.on(`VehicleReset`,init$3),$game.events.on(`VehicleFocusChanged`,init$3),init$3()}),onUnmounted(()=>{$game.streams.remove(streamsList$1),$game.events.off(`onStreamsUpdate`,onStreamsUpdate),$game.events.off(`VehicleReset`,init$3),$game.events.off(`VehicleFocusChanged`,init$3)});function onStreamsUpdate(streams){for(let stream of streamsList$1)if(!streams[stream])return;measures.value.forEach(x=>{let val=streams.forcedInductionInfo[x.key];val!==void 0&&(x.val=x.type===void 0?val.toFixed(2):$game.units.buildString(x.type,val,2))})}function init$3(){measures.value=defaultMeasures}return(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$170,[(openBlock(!0),createElementBlock(Fragment,null,renderList(filteredMeasures.value,m=>(openBlock(),createElementBlock(`div`,{class:`measure`,key:m.key},[createBaseVNode(`div`,_hoisted_2$139,toDisplayString(m.name),1),createBaseVNode(`div`,_hoisted_3$125,toDisplayString(m.val),1)]))),128))]))}},app_default$21=__plugin_vue_export_helper_default(_sfc_main$189,[[`__scopeId`,`data-v-8094d28b`]]),_sfc_main$188={},_hoisted_1$169={xmlns:`http://www.w3.org/2000/svg`,width:`60`,height:`100`,viewBox:`0 0 60 100`};function _sfc_render$2(_ctx,_cache){return openBlock(),createElementBlock(`svg`,_hoisted_1$169,[..._cache[0]||=[createBaseVNode(`rect`,{x:`4`,y:`4`,width:`52`,height:`92`,rx:`25`,ry:`25`,stroke:`black`,"stroke-width":`4`,fill:`none`},null,-1)]])}var accumulator_default=__plugin_vue_export_helper_default(_sfc_main$188,[[`render`,_sfc_render$2]]),_sfc_main$187={},_hoisted_1$168={xmlns:`http://www.w3.org/2000/svg`,width:`100`,height:`125`,viewBox:`0 0 100 125`,"stroke-width":`4`,stroke:`black`};function _sfc_render$1(_ctx,_cache){return openBlock(),createElementBlock(`svg`,_hoisted_1$168,[..._cache[0]||=[createBaseVNode(`circle`,{cx:`50`,cy:`32`,r:`30`,fill:`none`},null,-1),createBaseVNode(`path`,{d:`M50 6 L57 15 L43 15 Z`,fill:`black`},null,-1),createBaseVNode(`line`,{x1:`50`,y1:`61`,x2:`50`,y2:`90`,stroke:`black`},null,-1),createBaseVNode(`path`,{d:`M15 59 L15 115 L85 115 L85 59`,fill:`none`},null,-1)]])}var pump_default=__plugin_vue_export_helper_default(_sfc_main$187,[[`render`,_sfc_render$1]]),_sfc_main$186={},_hoisted_1$167={xmlns:`http://www.w3.org/2000/svg`,width:`100`,height:`130`,viewBox:`0 0 100 130`,"stroke-width":`4`,stroke:`black`};function _sfc_render(_ctx,_cache){return openBlock(),createElementBlock(`svg`,_hoisted_1$167,[..._cache[0]||=[createStaticVNode(``,6)]])}var reliefValve_default=__plugin_vue_export_helper_default(_sfc_main$186,[[`render`,_sfc_render]]),_hoisted_1$166={xmlns:`http://www.w3.org/2000/svg`,width:`100`,height:`210`,viewBox:`0 0 200 310`},_hoisted_2$138={transform:`translate(100, 0)`},_hoisted_3$124={transform:`translate(0, 110)`},_hoisted_4$102={transform:`translate(110, 190)`},_sfc_main$185={__name:`pumpAssembly`,setup(__props){return(_ctx,_cache)=>(openBlock(),createElementBlock(`svg`,_hoisted_1$166,[createBaseVNode(`g`,_hoisted_2$138,[createVNode(accumulator_default)]),createBaseVNode(`g`,_hoisted_3$124,[createVNode(reliefValve_default)]),createBaseVNode(`g`,_hoisted_4$102,[createVNode(pump_default)]),_cache[0]||=createBaseVNode(`path`,{d:`M56 122 L56 138 M54 120 L128 120 M130 122 L130 98 M130 120 L158 120 M160 118 L160 190`,stroke:`black`,"stroke-width":`4`},null,-1)]))}},pumpAssembly_default=_sfc_main$185,_hoisted_1$165={class:`hydraulics-debug`},_hoisted_2$137={width:`100%`,height:`100%`},_hoisted_3$123={id:`myGradient`,x1:`0%`,y1:`0%`,x2:`100%`,y2:`0%`},_hoisted_4$101=[`offset`],_hoisted_5$88={transform:`translate(0, 150)`,id:`pumpAssembly`},_hoisted_6$73=[`transform`],_hoisted_7$63=[`width`],_sfc_main$184={__name:`app`,setup(__props){let streamsList$1=[],{$game}=useLibStore(),offset$2=ref(0),offsetLeft=computed(()=>`${offset$2.value}%`),increase=()=>{offset$2.value<=100&&(offset$2.value+=10)},decrease=()=>{offset$2.value>0&&(offset$2.value-=10)},consumers=ref([{type:`hydraulicMotor`},{type:`cylinder`}]),addCylinder=function(){consumers.value.push({type:`cylinder`})},addhydraulicMotor=function(){consumers.value.push({type:`hydraulicMotor`})},removeConsumer=function(index=null){index===null?consumers.value.pop():consumers.value.splice(index,1)};onMounted(()=>{$game.events.on(`onStreamsUpdate`,onStreamsUpdate),$game.streams.add(streamsList$1)}),onUnmounted(()=>{$game.events.off(`onStreamsUpdate`,onStreamsUpdate),$game.streams.remove(streamsList$1)});function onStreamsUpdate(streams){for(let stream of streamsList$1)if(!streams[stream])return}return(_ctx,_cache)=>(openBlock(),createElementBlock(Fragment,null,[_cache[1]||=createBaseVNode(`h1`,null,`Hydraulics Debug`,-1),createBaseVNode(`button`,{onClick:decrease},`dec`),createBaseVNode(`button`,{onClick:increase},`inc`),createBaseVNode(`button`,{onClick:addhydraulicMotor},`motor`),createBaseVNode(`button`,{onClick:addCylinder},`cylinder`),createBaseVNode(`button`,{onClick:removeConsumer},`Remove Consumer`),createBaseVNode(`div`,null,` offset: `+toDisplayString(offset$2.value)+` left: `+toDisplayString(offsetLeft.value),1),createBaseVNode(`div`,_hoisted_1$165,[(openBlock(),createElementBlock(`svg`,_hoisted_2$137,[createBaseVNode(`defs`,null,[createBaseVNode(`linearGradient`,_hoisted_3$123,[createBaseVNode(`stop`,{offset:offsetLeft.value,"stop-color":`green`},null,8,_hoisted_4$101),_cache[0]||=createBaseVNode(`stop`,{offset:`0`,"stop-color":`black`},null,-1)])]),createBaseVNode(`g`,_hoisted_5$88,[createVNode(pumpAssembly_default)]),(openBlock(!0),createElementBlock(Fragment,null,renderList(consumers.value,(consumer,index)=>(openBlock(),createElementBlock(`g`,{transform:`translate(${(index+1)*100}, 95)`},[createVNode(consumer,{consumerType:consumer.type},null,8,[`consumerType`])],8,_hoisted_6$73))),256)),createBaseVNode(`rect`,{x:`80`,y:`236.5`,width:100*(consumers.value.length-1)+66,height:`2`,fill:`url(#myGradient)`},null,8,_hoisted_7$63)]))])],64))}},app_default$22=__plugin_vue_export_helper_default(_sfc_main$184,[[`__scopeId`,`data-v-a5aea534`]]),_hoisted_1$164={key:0,class:`bindings-app`},_hoisted_2$136={key:0,class:`toggle-icon`},_hoisted_3$122={key:1,class:`toggle-icon`},_hoisted_4$100={key:0,class:`players-binding`},_hoisted_5$87={key:0},_hoisted_6$72={key:1,class:`bindings-container`},_hoisted_7$62={class:`binding-item`},_sfc_main$183={__name:`app`,setup(__props){let{$game}=useLibStore(),bindings=ref([]),small=ref(!0),timeout=ref(null),show=ref(0),players=ref([]),forward=()=>{show.value=(show.value+1)%bindings.value.length},backward=()=>{show.value=show.value===0?bindings.value.length-1:show.value-1},toggleSmall=()=>{small.value=!small.value,clearTimeout(timeout)},goToBindings=(action,control)=>{$game.events.emit(`MenuHide`,!1),bngVue.gotoGameState(`menu.options.controls.bindings.edit`,{params:{action:action.actionName,oldBinding:{control:control.c,device:control.n}}})};onMounted(()=>{$game.events.on(`InputBindingsChanged`,onInputBindingsChanged),$game.events.on(`VehicleChange`,showBriefly),$game.events.on(`VehicleFocusChanged`,showBriefly),$game.api.engineLua(`extensions.core_input_bindings.notifyUI("keys app: link init")`),setTimeout(function(){$game.api.engineLua(`settings.notifyUI()`)},200)}),onUnmounted(()=>{$game.events.off(`InputBindingsChanged`,onInputBindingsChanged),$game.events.off(`VehicleChange`,showBriefly),$game.events.off(`VehicleFocusChanged`,showBriefly)});function showBriefly(){small.value&&(timeout.value=setTimeout(()=>small.value=!0,1e4)),small.value=!1}function onInputBindingsChanged(data){let specialKeys=[];players.value=[];for(let i=0;i=bindings.value.length&&(show.value=0)}function existsAt(arr,ac){return arr.map(function(elem,i){return elem.actionName===ac?i:-1}).filter(function(elem){return elem!==-1})}return(_ctx,_cache)=>players.value.length>1||bindings.value[show.value]&&bindings.value[show.value].length>0?(openBlock(),createElementBlock(`div`,_hoisted_1$164,[createBaseVNode(`div`,{onClick:_cache[0]||=$event=>toggleSmall(),class:`binding-show`},[small.value?(openBlock(),createElementBlock(`span`,_hoisted_2$136,[createVNode(unref(bngIcon_default),{class:`key-icon`,type:unref(icons).arrowSmallLeft},null,8,[`type`])])):(openBlock(),createElementBlock(`span`,_hoisted_3$122,[createVNode(unref(bngIcon_default),{class:`key-icon`,type:unref(icons).arrowSmallRight},null,8,[`type`])]))]),!small.value&&(players.value.length>1||bindings.value[show.value]&&bindings.value[show.value].length>0)?(openBlock(),createElementBlock(`div`,_hoisted_4$100,[!small.value&&players.value.length>1?(openBlock(),createElementBlock(`div`,_hoisted_5$87,[bindings.value.length>1?(openBlock(),createBlock(unref(bngButton_default),{key:0,onClick:_cache[1]||=$event=>backward()})):createCommentVNode(``,!0),createBaseVNode(`span`,null,`Player `+toDisplayString(show.value),1),bindings.value.length>1?(openBlock(),createBlock(unref(bngButton_default),{key:1,onClick:_cache[2]||=$event=>forward()})):createCommentVNode(``,!0)])):createCommentVNode(``,!0),bindings.value[show.value].length>0&&!small.value?(openBlock(),createElementBlock(`div`,_hoisted_6$72,[(openBlock(!0),createElementBlock(Fragment,null,renderList(bindings.value[show.value],entry=>(openBlock(),createElementBlock(`div`,_hoisted_7$62,[createBaseVNode(`div`,null,toDisplayString(_ctx.$t(entry.action)),1),createBaseVNode(`div`,null,[(openBlock(!0),createElementBlock(Fragment,null,renderList(entry.control,b=>(openBlock(),createBlock(unref(bngBinding_default),{deviceKey:b.c,device:b.d,"show-unassigned":!0,onClick:$event=>goToBindings(entry,b)},null,8,[`deviceKey`,`device`,`onClick`]))),256))])]))),256))])):createCommentVNode(``,!0)])):createCommentVNode(``,!0)])):createCommentVNode(``,!0)}},app_default$23=__plugin_vue_export_helper_default(_sfc_main$183,[[`__scopeId`,`data-v-b0d8eae9`]]),_hoisted_1$163={class:`bng-app log-vehicle-stats`},_hoisted_2$135={class:`update-period`},_hoisted_3$121={class:`settings-row`},_hoisted_4$99={class:`settings-row`},_hoisted_5$86={class:`settings-row`},_hoisted_6$71={class:`settings-row`},_hoisted_7$61={class:`log-btns`},_sfc_main$182={__name:`app`,setup(__props){const{$game}=useLibStore(),config=reactive({updateTime:5,moduleGeneral:!0,moduleWheels:!0,moduleEngine:!0,moduleInputs:!0,modulePowertrain:!0,outputFileName:`settings.json`,inputFileName:`settings.json`,outputDir:`VSL`}),configChanged=(configName,value)=>{switch(configName){case`moduleGeneral`:config.moduleGeneral=value;break;case`moduleWheels`:config.moduleWheels=value;break;case`moduleEngine`:config.moduleEngine=value;break;case`moduleInputs`:config.moduleInputs=value;break;case`modulePowertrain`:config.modulePowertrain=value;break}},applySettings=()=>{$game.api.activeObjectLua(`extensions.vehicleStatsLogger.updateTime = ${config.updateTime}`),$game.api.activeObjectLua(`extensions.vehicleStatsLogger.settings.useModule["General"] = ${config.moduleGeneral}`),$game.api.activeObjectLua(`extensions.vehicleStatsLogger.settings.useModule["Wheels"] = ${config.moduleWheels}`),$game.api.activeObjectLua(`extensions.vehicleStatsLogger.settings.useModule["Inputs"] = ${config.moduleInputs}`),$game.api.activeObjectLua(`extensions.vehicleStatsLogger.settings.useModule["Engine"] = ${config.moduleEngine}`),$game.api.activeObjectLua(`extensions.vehicleStatsLogger.settings.useModule["Powertrain"] = ${config.modulePowertrain}`)},useAsOutputDir=()=>{$game.api.activeObjectLua(`extensions.vehicleStatsLogger.settings.outputDir = "${config.outputDir}"`)},getNewOutputFilename=()=>{$game.api.activeObjectLua(`extensions.vehicleStatsLogger.suggestOutputFilename()`,function(data){config.outputFileName=data})},saveSettingsToJson=()=>{config.outputFileName!==``&&$game.api.activeObjectLua(`extensions.vehicleStatsLogger.writeSettingsToJSON("${config.outputFileName}")`)},importSettingsFromFile=()=>{scope.inputFileName!==``&&($game.api.activeObjectLua(`extensions.vehicleStatsLogger.applySettingsFromJSON("${config.inputFileName}")`),config.moduleGeneral=eval(`${extensions.vehicleStatsLogger.settings.useModule.General}`),config.moduleWheels=eval(`${extensions.vehicleStatsLogger.settings.useModule.Wheels}`),config.moduleInputs=eval(`${extensions.vehicleStatsLogger.settings.useModule.Inputs}`),config.moduleEngine=eval(`${extensions.vehicleStatsLogger.settings.useModule.Engine}`),config.modulePowertrain=eval(`${extensions.vehicleStatsLogger.settings.useModule.Powertrain}`))},startLogging=()=>{$game.api.activeObjectLua(`extensions.vehicleStatsLogger.startLogging()`)},stopLogging=()=>{$game.api.activeObjectLua(`extensions.vehicleStatsLogger.stopLogging()`)};return(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$163,[createBaseVNode(`div`,_hoisted_2$135,[_cache[20]||=createBaseVNode(`span`,{class:`label`},`Update Period:`,-1),createVNode(unref(bngInput_default),{type:`number`,min:1,max:360,step:1,modelValue:config.updateTime,"onUpdate:modelValue":_cache[0]||=$event=>config.updateTime=$event,suffix:`seconds`},null,8,[`modelValue`])]),createBaseVNode(`div`,null,[createVNode(unref(bngPillCheckbox_default),{modelValue:config.moduleGeneral,"onUpdate:modelValue":_cache[1]||=$event=>config.moduleGeneral=$event,onValueChanged:_cache[2]||=val=>configChanged(`moduleGeneral`,val)},{default:withCtx(()=>[..._cache[21]||=[createTextVNode(` General`,-1)]]),_:1},8,[`modelValue`]),createVNode(unref(bngPillCheckbox_default),{modelValue:config.moduleWheels,"onUpdate:modelValue":_cache[3]||=$event=>config.moduleWheels=$event,onValueChanged:_cache[4]||=val=>configChanged(`moduleWheels`,val)},{default:withCtx(()=>[..._cache[22]||=[createTextVNode(` Wheels`,-1)]]),_:1},8,[`modelValue`]),createVNode(unref(bngPillCheckbox_default),{modelValue:config.moduleEngine,"onUpdate:modelValue":_cache[5]||=$event=>config.moduleEngine=$event,onValueChanged:_cache[6]||=val=>configChanged(`moduleEngine`,val)},{default:withCtx(()=>[..._cache[23]||=[createTextVNode(` Engine`,-1)]]),_:1},8,[`modelValue`]),createVNode(unref(bngPillCheckbox_default),{modelValue:config.moduleInputs,"onUpdate:modelValue":_cache[7]||=$event=>config.moduleInputs=$event,onValueChanged:_cache[8]||=val=>configChanged(`moduleInputs`,val)},{default:withCtx(()=>[..._cache[24]||=[createTextVNode(` Inputs`,-1)]]),_:1},8,[`modelValue`]),createVNode(unref(bngPillCheckbox_default),{modelValue:config.modulePowertrain,"onUpdate:modelValue":_cache[9]||=$event=>config.modulePowertrain=$event,onValueChanged:_cache[10]||=val=>configChanged(`modulePowertrain`,val)},{default:withCtx(()=>[..._cache[25]||=[createTextVNode(`Powertrain`,-1)]]),_:1},8,[`modelValue`])]),createBaseVNode(`div`,_hoisted_3$121,[_cache[27]||=createBaseVNode(`label`,null,`Apply Settings:`,-1),createVNode(unref(bngButton_default),{class:`settings-btn`,onClick:_cache[11]||=$event=>applySettings()},{default:withCtx(()=>[..._cache[26]||=[createTextVNode(`Apply`,-1)]]),_:1})]),withDirectives((openBlock(),createElementBlock(`div`,_hoisted_4$99,[_cache[29]||=createBaseVNode(`label`,null,`Set Custom Output Directory:`,-1),createVNode(unref(bngInput_default),{modelValue:config.outputDir,"onUpdate:modelValue":_cache[12]||=$event=>config.outputDir=$event},null,8,[`modelValue`]),createVNode(unref(bngButton_default),{class:`settings-btn`,onClick:_cache[13]||=$event=>useAsOutputDir()},{default:withCtx(()=>[..._cache[28]||=[createTextVNode(`Use`,-1)]]),_:1})])),[[unref(BngTooltip_default),`Subdirectory of the BeamNG.drive/BeamNG.tech directory.`]]),withDirectives((openBlock(),createElementBlock(`div`,_hoisted_5$86,[_cache[31]||=createBaseVNode(`label`,null,`Settings Output Filename:`,-1),createVNode(unref(bngInput_default),{modelValue:config.outputFileName,"onUpdate:modelValue":_cache[14]||=$event=>config.outputFileName=$event},null,8,[`modelValue`]),createVNode(unref(bngButton_default),{class:`settings-btn`,onClick:_cache[15]||=$event=>saveSettingsToJson()},{default:withCtx(()=>[..._cache[30]||=[createTextVNode(`Write`,-1)]]),_:1})])),[[unref(BngTooltip_default),`Settings files are written to the BeamNG.drive/BeamNG.tech directory.`]]),withDirectives((openBlock(),createElementBlock(`div`,_hoisted_6$71,[_cache[33]||=createBaseVNode(`label`,null,`Settings Input Filename:`,-1),createVNode(unref(bngInput_default),{modelValue:config.inputFileName,"onUpdate:modelValue":_cache[16]||=$event=>config.inputFileName=$event},null,8,[`modelValue`]),createVNode(unref(bngButton_default),{class:`settings-btn`,onClick:_cache[17]||=$event=>importSettingsFromFile()},{default:withCtx(()=>[..._cache[32]||=[createTextVNode(`Load`,-1)]]),_:1})])),[[unref(BngTooltip_default),`Settings files are assumed to be in the BeamNG.drive/BeamNG.tech directory.`]]),createBaseVNode(`div`,_hoisted_7$61,[createVNode(unref(bngButton_default),{class:`start-btn`,onClick:_cache[18]||=$event=>startLogging()},{default:withCtx(()=>[..._cache[34]||=[createTextVNode(`Start Log`,-1)]]),_:1}),createVNode(unref(bngButton_default),{class:`stop-btn`,onClick:_cache[19]||=$event=>stopLogging()},{default:withCtx(()=>[..._cache[35]||=[createTextVNode(`Stop Log`,-1)]]),_:1})])]))}},app_default$24=__plugin_vue_export_helper_default(_sfc_main$182,[[`__scopeId`,`data-v-686c3ac5`]]),_hoisted_1$162={class:`replay-app-container`,ref:`appContainerRef`},_hoisted_2$134={class:`left-controls`},_hoisted_3$120={class:`filename-container`},_hoisted_4$98={key:1,class:`filename`},_hoisted_5$85={key:1,class:`filename`},_hoisted_6$70={class:`right-controls`},_hoisted_7$60={class:`replay-controls-container`},_hoisted_8$50={class:`play-controls`},_hoisted_9$44={key:0,class:`speed-controls`},_hoisted_10$37={class:`svg-time-container`},_hoisted_11$33={width:`100%`,height:`100%`,preserveAspectRatio:`xMidYMid meet`},_hoisted_12$26={viewBox:`0 0 200 50`,width:`100%`,height:`100%`,overflow:`visible`},_hoisted_13$23={transform:`translate(100, 25)`},_hoisted_14$22={"text-anchor":`middle`,"dominant-baseline":`middle`,class:`time-text`,"font-size":`40`,"line-height":`1`},_hoisted_15$21={class:`time-display-total`},_hoisted_16$21={class:`position-slider`},replayFolder=`replays/`,replayFileExtension=`.rpl`,_sfc_main$181={__name:`app`,props:{hideFileControls:{type:Boolean,default:!1}},setup(__props){let state=ref(`inactive`),speed=ref(1),paused=ref(!1),renaming=ref(!1),isSeeking=ref(!1),loadedFile=ref(``),positionSeconds=ref(0),totalSeconds=ref(0),positionPercent=ref(0),fpsRec=ref(0),fpsPlay=ref(0),originalFilename=``,lastSeek=0,events$3=useEvents(),resizeObserver=ref(null),replayControlsRef=ref(null),containerWidth=shallowRef(0),layoutState=computed(()=>{let width$1=containerWidth.value;return{isReplayControlsNarrow:width$1<301,isFileControlsNarrow:width$1<361}}),props=__props,formatTime$1=seconds=>new Date(seconds*1e3).toISOString().substr(14,8),debounce$1=(fn,delay)=>{let timer=null;return(...args)=>{timer&&clearTimeout(timer),timer=setTimeout(()=>{fn(...args),timer=null},delay)}},listRecordings=()=>{window.bngVue.gotoGameState(`menu.replay`)},startRenaming=()=>{renaming.value=!0,originalFilename=loadedFile.value},cancelRename=()=>{renaming.value=!1,loadedFile.value=originalFilename},acceptRename=()=>{if(loadedFile.value===originalFilename){cancelRename();return}renaming.value=!1,Lua_default.core_replay.acceptRename(replayFolder+originalFilename+replayFileExtension,replayFolder+loadedFile.value+replayFileExtension)},toggleSpeed=val=>{Lua_default.core_replay.toggleSpeed(val)},togglePlay=()=>{Lua_default.core_replay.togglePlay()},toggleRecording=()=>{Lua_default.core_replay.toggleRecording(!0)},cancelRecording=()=>{Lua_default.core_replay.cancelRecording()},stop$1=()=>{Lua_default.core_replay.stop()},seek=()=>{state.value===`playback`&&(lastSeek=Date.now(),Lua_default.core_replay.pause(!0),Lua_default.core_replay.seek(positionPercent.value))};watch(positionSeconds,(newVal,oldVal)=>{Date.now()-lastSeek>500&&totalSeconds.value>0&&(positionPercent.value=newVal/totalSeconds.value)});let setupResizeObserver=()=>{if(!replayControlsRef.value)return;let rafId=null,updateWidth=debounce$1(width$1=>{containerWidth.value=width$1},100);resizeObserver.value=new ResizeObserver(entries=>{rafId!==null&&cancelAnimationFrame(rafId),rafId=requestAnimationFrame(()=>{for(let entry of entries)updateWidth(entry.contentRect.width);rafId=null})}),resizeObserver.value.observe(replayControlsRef.value)};return onMounted(async()=>{try{Lua_default.core_replay.onInit()}catch(e){console.error(`Error initializing replay state:`,e)}events$3.on(`replayStateChanged`,val=>{renaming.value||(loadedFile.value=val.loadedFile.replace(replayFolder,``).replace(replayFileExtension,``)),positionSeconds.value=val.positionSeconds,totalSeconds.value=val.totalSeconds,speed.value=val.speed,paused.value=val.paused,fpsRec.value=val.fpsRec,fpsPlay.value=val.fpsPlay,state.value=val.state,isSeeking.value=val.jumpOffset!==0,Date.now()-lastSeek>500&&totalSeconds.value>0?positionPercent.value=positionSeconds.value/totalSeconds.value:isSeeking.value=!0}),await nextTick(),setupResizeObserver()}),onUnmounted(()=>{resizeObserver.value&&=(resizeObserver.value.disconnect(),null),events$3.off(`replayStateChanged`)}),(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$162,[props.hideFileControls?createCommentVNode(``,!0):(openBlock(),createElementBlock(`div`,{key:0,class:normalizeClass([`file-controls`,{narrow:layoutState.value.isFileControlsNarrow}])},[createBaseVNode(`div`,_hoisted_2$134,[createVNode(unref(bngButton_default),{class:`recordings-button`,onClick:listRecordings,icon:`folder`,tooltip:`Open recordings`,accent:unref(ACCENTS).text},null,8,[`accent`]),loadedFile.value&&state.value!==`recording`&&!renaming.value?(openBlock(),createBlock(unref(bngButton_default),{key:0,class:`recordings-button`,onClick:stop$1,icon:`xmark`,disabled:state.value!==`playback`,tooltip:`Close replay`,accent:unref(ACCENTS).text},null,8,[`disabled`,`accent`])):createCommentVNode(``,!0),state.value===`recording`?(openBlock(),createBlock(unref(bngButton_default),{key:1,class:`recordings-button`,onClick:cancelRecording,icon:`undo`,accent:unref(ACCENTS).attention,tooltip:`Cancel recording`},null,8,[`accent`])):createCommentVNode(``,!0)]),createBaseVNode(`div`,_hoisted_3$120,[loadedFile.value&&state.value!==`recording`?(openBlock(),createElementBlock(Fragment,{key:0},[renaming.value?(openBlock(),createElementBlock(Fragment,{key:0},[createVNode(unref(bngButton_default),{onClick:cancelRename,icon:`xmark`,accent:unref(ACCENTS).ghost,class:`cancel-rename-button`},null,8,[`accent`]),createVNode(unref(bngInput_default),{id:`replay-filename-input`,class:`filename-input`,prefix:replayFolder,suffix:replayFileExtension,modelValue:loadedFile.value,"onUpdate:modelValue":_cache[0]||=$event=>loadedFile.value=$event,placeholder:`(no file)`,disabled:state.value===`recording`||!loadedFile.value,onKeyup:withKeys(acceptRename,[`enter`])},null,8,[`modelValue`,`disabled`])],64)):(openBlock(),createElementBlock(`div`,_hoisted_4$98,toDisplayString(replayFolder)+toDisplayString(loadedFile.value)+toDisplayString(replayFileExtension),1)),createVNode(unref(bngButton_default),{onClick:_cache[1]||=$event=>renaming.value?acceptRename():startRenaming(),icon:renaming.value?`checkmark`:`edit`,accent:renaming.value?unref(ACCENTS).main:unref(ACCENTS).ghost},null,8,[`icon`,`accent`])],64)):(openBlock(),createElementBlock(`div`,_hoisted_5$85,` No File loaded `))]),createBaseVNode(`div`,_hoisted_6$70,[createVNode(unref(bngButton_default),{onClick:toggleRecording,icon:state.value===`recording`?`square`:`bigDot`,accent:unref(ACCENTS).text,disabled:state.value===`playback`,tooltip:state.value===`recording`?`Save recording`:`Record new replay`,class:`recordings-button record-button`},null,8,[`icon`,`accent`,`disabled`,`tooltip`])])],2)),createBaseVNode(`div`,_hoisted_7$60,[createBaseVNode(`div`,{class:normalizeClass([`replay-controls`,{narrow:layoutState.value.isReplayControlsNarrow}]),ref_key:`replayControlsRef`,ref:replayControlsRef},[createBaseVNode(`div`,_hoisted_8$50,[createVNode(unref(bngButton_default),{onClick:togglePlay,class:`play-button`,icon:state.value===`playback`&&!paused.value?`pause`:`play`,disabled:state.value===`recording`||!loadedFile.value,accent:unref(ACCENTS).ghost},null,8,[`icon`,`disabled`,`accent`]),state.value===`inactive`?createCommentVNode(``,!0):(openBlock(),createElementBlock(`div`,_hoisted_9$44,[createVNode(unref(bngButton_default),{class:`speed-button small`,onClick:_cache[2]||=$event=>toggleSpeed(-1),icon:`mathMinus`,disabled:!loadedFile.value,accent:unref(ACCENTS).text},null,8,[`disabled`,`accent`]),createBaseVNode(`div`,{class:normalizeClass([`playback-speed-display`,{disabled:!loadedFile.value}])},toDisplayString(speed.value.toFixed(2))+`x`,3),createVNode(unref(bngButton_default),{class:`speed-button small`,onClick:_cache[3]||=$event=>toggleSpeed(1),icon:`mathPlus`,disabled:!loadedFile.value,accent:unref(ACCENTS).text},null,8,[`disabled`,`accent`])]))]),createBaseVNode(`div`,{class:normalizeClass([`time-display`,{active:loadedFile.value,seeking:isSeeking.value}])},[createBaseVNode(`div`,_hoisted_10$37,[(openBlock(),createElementBlock(`svg`,_hoisted_11$33,[(openBlock(),createElementBlock(`svg`,_hoisted_12$26,[createBaseVNode(`g`,_hoisted_13$23,[createBaseVNode(`text`,_hoisted_14$22,toDisplayString(formatTime$1(positionSeconds.value)),1)])]))]))]),createBaseVNode(`span`,_hoisted_15$21,`(`+toDisplayString(formatTime$1(totalSeconds.value))+`)`,1)],2)],2),createBaseVNode(`div`,_hoisted_16$21,[createVNode(unref(bngSlider_default),{modelValue:positionPercent.value,"onUpdate:modelValue":_cache[4]||=$event=>positionPercent.value=$event,min:0,max:1,step:.001,onInput:seek,disabled:state.value!==`playback`||!loadedFile.value},null,8,[`modelValue`,`disabled`])])])],512))}},app_default$1=__plugin_vue_export_helper_default(_sfc_main$181,[[`__scopeId`,`data-v-bf84291a`]]),_hoisted_1$161={style:{width:`100%`,height:`100%`},class:`bng-app`,layout:`column`},_hoisted_2$133={style:{display:`flex`,"justify-content":`center`,"align-items":`baseline`}},_hoisted_3$119={style:{"font-size":`1.3em`,"font-weight":`bold`}},_hoisted_4$97={style:{color:`rgba(255, 255, 255, 0.8)`}},_hoisted_5$84={style:{"text-align":`center`,color:`rgba(255, 255, 255, 0.8)`,"font-size":`0.75em`}},_sfc_main$180={__name:`app`,setup(__props){let{$game}=useLibStore(),streamsList$1=[`engineInfo`];$game.streams.add(streamsList$1);let numToBig=ref(`1`);ref(NaN);let rpm=ref(0),leadingZeros=ref(null);onMounted(()=>{console.log(`simpleDigTacho mounted`),$game.events.on(`onStreamsUpdate`,onStreamsUpdate)}),onUnmounted(()=>{console.log(`simpleDigTacho unmounted`),$game.streams.remove(streamsList$1),$game.events.off(`onStreamsUpdate`,onStreamsUpdate)});function onStreamsUpdate(streams){for(let stream of streamsList$1)if(!streams[stream])return;if(rpm.value=Math.round(streams.engineInfo[4]),rpm.value.toString().length>4){let help=10**(rpm.value.toString().length-4);numToBig.value=help.toString(),rpm.value=Math.round(rpm.value/help)}else numToBig.value=`1`;rpm.value=rpm.value.toString().slice(-4),isNaN(rpm.value)||(leadingZeros.value=`0000`.slice(rpm.value.length))}return(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$161,[createBaseVNode(`div`,_hoisted_2$133,[createBaseVNode(`span`,_hoisted_3$119,[createBaseVNode(`span`,_hoisted_4$97,toDisplayString(leadingZeros.value),1),createBaseVNode(`span`,null,toDisplayString(rpm.value),1)]),_cache[0]||=createBaseVNode(`span`,{style:{"font-size":`0.9em`,"font-weight":`bold`,"margin-left":`2px`}},`RPM`,-1)]),createBaseVNode(`small`,_hoisted_5$84,[createTextVNode(toDisplayString(_ctx.$t(`ui.apps.digTacho.engine`))+` `,1),createBaseVNode(`span`,null,`(x`+toDisplayString(numToBig.value)+`)`,1)])]))}},app_default$25=_sfc_main$180,_hoisted_1$160={"xmlns:svg":`http://www.w3.org/2000/svg`,xmlns:`http://www.w3.org/2000/svg`,"xmlns:xlink":`http://www.w3.org/1999/xlink`,version:`1.1`,width:`100%`,height:`100%`,viewBox:`0 0 660 660`},_hoisted_2$132={"xml:space":`preserve`,class:`text1`,x:`329.88641`,y:`289.30463`,id:`tspan4449-43`},_hoisted_3$118={"xml:space":`preserve`,id:`speed_units`,class:`speed-units`,x:`330`,y:`348`},_hoisted_4$96={"xml:space":`preserve`,id:`tspan4449-4-3`,class:`tacho2-gear`,x:`386.67343`,y:`457.94861`,transform:`matrix(1,0,-0.13142611,1,0,0)`},_hoisted_5$83={"xml:space":`preserve`,x:`330.09229`,y:`498.18045`,id:`text4447-2-4`,class:`rpm-text-legend`},_hoisted_6$69={transform:`translate(-150,-214)`,id:`revcurvemask`,class:`revcurvemask`,"clip-path":`url(#clipPath4710)`},rpmTextSize=50,maxRpmTexts=13,tickMarkLength=64,tickInnerOffset=42,_sfc_main$179={__name:`tacho`,setup(__props,{expose:__expose}){let width$1=660,height$1=660,initialized=ref(!1),dashSize$1=5,computeGaugeFullRange=maxrpm=>Math.ceil((maxrpm||0)/1e3)*1e3+1e3,computeGaugeStep=maxrpm=>maxrpm<4e3?500:maxrpm>15e3?2e3:1e3,computeGaugeMarks=maxrpm=>{let fullRange=computeGaugeFullRange(maxrpm),step=computeGaugeStep(maxrpm);return Math.ceil(fullRange/step)+1},rpmTextRefs=ref([]),setRpmRef=(el,i)=>{el&&(rpmTextRefs.value[i]=el)},oilTempBarRef=ref(null),oilTempBarLen=computed(()=>oilTempBarRef.value.getTotalLength()),oilTempIcoOffRef=ref(null),oilTempIcoOnRef=ref(null),speedTextRef=ref(null),gearTextRef=ref(null),revcurveRef=ref(null),revCurveLen=computed(()=>revcurveRef.value.getTotalLength()),revcurveDashesRef=ref(null),revCurveDashesLen=computed(()=>revcurveDashesRef.value.getTotalLength()),fuelBarRef=ref(null),fuelBarLen=computed(()=>fuelBarRef.value.getTotalLength()),fuelWarnIcoOffRef=ref(null),fuelWarnIcoOnRef=ref(null),lastFuelLevel=0,shouldPlayFuelLowSound=!1,lowFuelSoundPlayed=!1,isCareer=!1,redLineRef=ref(null),redLineLen=computed(()=>redLineRef.value.getTotalLength()),rpmTextGuideLineRef=ref(null),rpmTextGuideLineLen=computed(()=>rpmTextGuideLineRef.value.getTotalLength()),tickMarkRefs=ref([]),setTickRef=(el,i)=>{el&&(tickMarkRefs.value[i]=el)},icoHandBrakeOffRef=ref(null),icoHandBrakeOnRef=ref(null),icoABSOffRef=ref(null),icoABSOnRef=ref(null),icoIndicatorLeftOffRef=ref(null),icoIndicatorLeftOnRef=ref(null),icoIndicatorRightOffRef=ref(null),icoIndicatorRightOnRef=ref(null),icoLightsOffRef=ref(null),icoLightsOnRef=ref(null),icoLightsHighRef=ref(null),layer3Ref=ref(null),layer4Ref=ref(null),layer6Ref=ref(null),layer7Ref=ref(null),layer10Ref=ref(null),layer11Ref=ref(null),layer12Ref=ref(null),tickLayerRef=ref(null),speedUnitTextRef=ref(null),rpm_max=ref(8e3),rpmLegendTextRef=ref(null),revNeedleRef=ref(null),displayMode=ref(2);onMounted(()=>{rpmLegendTextRef?.value&&(rpmLegendTextRef.value.textContent=`x1000 RPM`),oilTempBarRef.value.style.strokeDasharray=oilTempBarLen.value+` `+oilTempBarLen.value,speedTextRef.value.textContent=``,revcurveRef.value.style.strokeDasharray=revCurveLen.value+` `+revCurveLen.value,fuelBarRef.value.style.strokeDasharray=fuelBarLen.value+` `+fuelBarLen.value,rpmTextGuideLineRef.value.style.display=`none`;for(let k=0;kisCareer=isActive)});function applyData(data$1){speedTextRef.value.textContent=data$1.speedtext,(speedTextRef.value.textContent==`-Infinity`||speedTextRef.value.textContent==`Infinity`)&&(speedTextRef.value.textContent=`-`),gearTextRef.value.textContent=data$1.geartext,fuelBarRef.value.style[`stroke-dashoffset`]=(1-data$1.fuel)*fuelBarLen.value;let fuelLow=data$1.fuel<.1,fuelGoneLow=lastFuelLevel>=.1&&fuelLow;lastFuelLevel=data$1.fuel,fuelWarnIcoOffRef.value.style.visibility=fuelLow?`hidden`:`visible`,fuelWarnIcoOnRef.value.style.visibility=fuelLow?`visible`:`hidden`,data$1.ignition&&isCareer&&fuelGoneLow&&!shouldPlayFuelLowSound&&setTimeout(()=>shouldPlayFuelLowSound=!0,0),shouldPlayFuelLowSound&&!lowFuelSoundPlayed&&(lowFuelSoundPlayed=!0,Lua_default.ui_audio.playEventSound(`bng_career_fuel`,`low_fuel`)),icoHandBrakeOffRef.value.style.visibility=data$1.parkingBrake?`hidden`:`visible`,icoHandBrakeOnRef.value.style.visibility=data$1.parkingBrake?`visible`:`hidden`,icoABSOffRef.value.style.visibility=data$1.absWorking?`hidden`:`visible`,icoABSOnRef.value.style.visibility=data$1.absWorking?`visible`:`hidden`,icoIndicatorLeftOffRef.value.style.visibility=data$1.signalL?`hidden`:`visible`,icoIndicatorLeftOnRef.value.style.visibility=data$1.signalL?`visible`:`hidden`,icoIndicatorRightOffRef.value.style.visibility=data$1.signalR?`hidden`:`visible`,icoIndicatorRightOnRef.value.style.visibility=data$1.signalR?`visible`:`hidden`;let tempNormalized=Math.max(Math.min((data$1.waterTemp-50)/80,1),0);oilTempBarRef.value.style.strokeDashoffset=(1+tempNormalized)*oilTempBarLen.value;let oilTemp_warn=tempNormalized>.8125;if(oilTempIcoOffRef.value.style.visibility=oilTemp_warn?`hidden`:`visible`,oilTempIcoOnRef.value.style.visibility=oilTemp_warn?`visible`:`hidden`,data$1.lowBeam!==void 0&&data$1.highBeam!==void 0){let nb=!0,lb=data$1.lowBeam>.9,hb=data$1.highBeam>.9;lb&&(nb=!1),hb&&(nb=!1),icoLightsOffRef.value.style.visibility=nb?`visible`:`hidden`,icoLightsOnRef.value.style.visibility=lb?`visible`:`hidden`,icoLightsHighRef.value.style.visibility=hb?`visible`:`hidden`}else icoLightsOffRef.value.style.visibility=`hidden`,icoLightsOnRef.value.style.visibility=`hidden`,icoLightsHighRef.value.style.visibility=`hidden`;let rpm_rotation=data$1.rpm*270-180;rpm_rotation<-180&&(rpm_rotation=-180),rpm_rotation>90&&(rpm_rotation=90),revNeedleRef.value.setAttribute(`transform`,`rotate(`+rpm_rotation+`,330,330)`);let revCurveOffset=(1-data$1.rpm)*revCurveLen.value;revCurveOffset<0&&(revCurveOffset=0),revCurveOffset>revCurveLen.value&&(revCurveOffset=revCurveLen.value),revcurveRef.value.style.strokeDashoffset=revCurveOffset}let data=ref({}),layersVisible=!1;function setlayersVisible(v){if(layersVisible!=v){let val=v?`inline`:`none`;layer3Ref.value.style.display=val,layer4Ref.value.style.display=val,layer6Ref.value.style.display=val,layer7Ref.value.style.display=val,layer10Ref.value.style.display=val,layer11Ref.value.style.display=val,layer12Ref.value.style.display=val,tickLayerRef.value.style.display=val,layersVisible=v}}function reset$1(){setlayersVisible(!1),initialized.value=!1;for(let k=0;k=0?1:-1,inx=nx*sign,iny=ny*sign,x1=pt.x+inx*tickInnerOffset,y1=pt.y+iny*tickInnerOffset,x2=x1+inx*tickMarkLength,y2=y1+iny*tickMarkLength;line.setAttribute(`x1`,x1),line.setAttribute(`y1`,y1),line.setAttribute(`x2`,x2),line.setAttribute(`y2`,y2),line.style.visibility=`visible`}}for(let k=dashCount$1+1;k<=maxRpmTexts;k++){let rp=rpmTextRefs.value[k];rp&&(rp.style.visibility=`hidden`);let line=tickMarkRefs.value[k];line&&(line.style.visibility=`hidden`)}initialized.value=!0}if(!isStreamValid)return!1;if(setlayersVisible(!0),displayMode.value==2)streams.electrics.wheelspeed?(data.speedtext=UnitSpeed(streams.electrics.wheelspeed),streams.electrics.wheelspeed>9e3&&(speedUnitTextRef.value.textContent=`brrrr`)):streams.electrics.airspeed&&(data.speedtext=UnitSpeed(streams.electrics.airspeed)),(function(){if(streams.engineInfo[13]==`manual`){let gear=streams.engineInfo[5],gearStr=gear.toString();gear==0?gearStr=`N`:gear==-1?gearStr=`R`:-gear>1&&(gearStr=`R`+-gear),data.geartext=gearStr}else data.geartext=[`P`,`R`,`N`,`D`,`2`,`1`][Math.round(streams.electrics.gear_A*5)]})(),data.fuel=streams.engineInfo[11]/streams.engineInfo[12],data.parkingBrake=streams.electrics.parkingbrake,data.absWorking=streams.electrics.abs,data.signalL=streams.electrics.signal_L,data.signalR=streams.electrics.signal_R,data.waterTemp=streams.electrics.watertemp,data.lowBeam=streams.electrics.lowbeam,data.highBeam=streams.electrics.highbeam,data.rpm=(streams.electrics.rpmTacho||0)/rpm_max.value;else if(displayMode.value==0){testVar+=.04,testVar>1&&(testVar=1),data.speedtext=Math.round(testVar*100),data.geartext=Math.round(testVar*5),data.fuel=testVar;let boolTest=!0;data.parkingBrake=!0,data.absWorking=!0,data.signalL=!0,data.signalR=!0,data.oilTemp=testVar,data.lowBeam=!0,data.highBeam=!1,data.rpm=testVar,testVar>=1&&(testVar=0,displayMode.value=1)}else if(displayMode.value==1){streams.electrics.wheelspeed?data.speedtext=UnitSpeed(streams.electrics.wheelspeed):(data.speedtext=``,speedUnitTextRef.value.textContent=``),(function(){let gear=streams.engineInfo[5],gearStr=gear.toString();gear==0?gearStr=`N`:gear==-1&&(gearStr=`R`),data.geartext=gearStr})(),data.parkingBrake=streams.electrics.parkingbrake,data.absWorking=streams.electrics.abs,data.signalL=streams.electrics.signal_L,data.signalR=streams.electrics.signal_R,data.lowBeam=streams.electrics.lowbeam,data.highBeam=streams.electrics.highbeam;let oilok=Math.abs(data.oilTemp-streams.electrics.oiltemp)<.005;oilok||(data.oilTemp+=(streams.electrics.oiltemp-data.oilTemp)*.2);let rpmperc=streams.electrics.rpm/rpm_max.value,rpmok=Math.abs(data.rpm-rpmperc)<.005;rpmok||(data.rpm+=(rpmperc-data.rpm)*.2);let fuelperc=streams.engineInfo[11]/streams.engineInfo[12],fuelok=Math.abs(data.fuel-fuelperc)<.005;fuelok||(data.fuel+=(fuelperc-data.fuel)*.2),oilok&&rpmok&&fuelok&&(displayMode.value=2)}return data.engineRunning=streams.electrics.engineRunning,data.ignition=streams.electrics.ignition,applyData(data),!0}function vehicleChanged(){initialized.value=!1}let UiUnitscallback=ref(()=>null);function UnitSpeed(val){let convertedVal=UiUnitscallback.value(val,`speed`);return speedUnitTextRef.value.textContent=convertedVal.unit,Math.round(convertedVal.val)}function wireThroughUnitSystem(callback){UiUnitscallback.value=callback}return __expose({wireThroughUnitSystem,update:update$6,vehicleChanged}),(_ctx,_cache)=>(openBlock(),createElementBlock(`svg`,_hoisted_1$160,[_cache[17]||=createBaseVNode(`defs`,{id:`defs4`},[createBaseVNode(`linearGradient`,{id:`linearGradient3938`},[createBaseVNode(`stop`,{style:{"stop-color":`#ff0000`,"stop-opacity":`1`},offset:`0`,id:`stop3940`}),createBaseVNode(`stop`,{style:{"stop-color":`#00ff4b`,"stop-opacity":`1`},offset:`1`,id:`stop3942`})]),createBaseVNode(`linearGradient`,{id:`linearGradient4607`},[createBaseVNode(`stop`,{id:`stop4609`,offset:`0`,style:{"stop-color":`#e40000`,"stop-opacity":`1`}}),createBaseVNode(`stop`,{style:{"stop-color":`#e40000`,"stop-opacity":`1`},offset:`0.89960396`,id:`stop4611`}),createBaseVNode(`stop`,{id:`stop4613`,offset:`1`,style:{"stop-color":`#e40000`,"stop-opacity":`0`}}),createBaseVNode(`stop`,{id:`stop4615`,offset:`1`,style:{"stop-color":`#e40000`,"stop-opacity":`0`}})]),createBaseVNode(`linearGradient`,{id:`linearGradient4597`},[createBaseVNode(`stop`,{id:`stop4599`,offset:`0`,style:{"stop-color":`#e40000`,"stop-opacity":`1`}}),createBaseVNode(`stop`,{style:{"stop-color":`#e40000`,"stop-opacity":`1`},offset:`0.99812102`,id:`stop4601`}),createBaseVNode(`stop`,{id:`stop4603`,offset:`1`,style:{"stop-color":`#e40000`,"stop-opacity":`0`}}),createBaseVNode(`stop`,{id:`stop4605`,offset:`1`,style:{"stop-color":`#e40000`,"stop-opacity":`1`}})]),createBaseVNode(`linearGradient`,{id:`linearGradient4545`},[createBaseVNode(`stop`,{style:{"stop-color":`#e40000`,"stop-opacity":`1`},offset:`0`,id:`stop4547`}),createBaseVNode(`stop`,{id:`stop4553`,offset:`0.9861111`,style:{"stop-color":`#e40000`,"stop-opacity":`1`}}),createBaseVNode(`stop`,{style:{"stop-color":`#e40000`,"stop-opacity":`0`},offset:`1`,id:`stop4555`}),createBaseVNode(`stop`,{style:{"stop-color":`#e40000`,"stop-opacity":`0`},offset:`1`,id:`stop4549`})]),createBaseVNode(`linearGradient`,{id:`linearGradient4256`},[createBaseVNode(`stop`,{style:{"stop-color":`#6d0000`,"stop-opacity":`1`},offset:`0`,id:`stop4258`}),createBaseVNode(`stop`,{style:{"stop-color":`#6d0000`,"stop-opacity":`0`},offset:`1`,id:`stop4260`})]),createBaseVNode(`linearGradient`,{id:`linearGradient4365`},[createBaseVNode(`stop`,{style:{"stop-color":`#000000`,"stop-opacity":`0.42857143`},offset:`0`,id:`stop4367`}),createBaseVNode(`stop`,{id:`stop4373`,offset:`0.5`,style:{"stop-color":`#000000`,"stop-opacity":`0.33035713`}}),createBaseVNode(`stop`,{style:{"stop-color":`#000000`,"stop-opacity":`0`},offset:`1`,id:`stop4369`})]),createBaseVNode(`linearGradient`,{id:`linearGradient4357`},[createBaseVNode(`stop`,{style:{"stop-color":`#000000`,"stop-opacity":`1`},offset:`0`,id:`stop4359`}),createBaseVNode(`stop`,{style:{"stop-color":`#000000`,"stop-opacity":`0.19642857`},offset:`1`,id:`stop4361`})]),createBaseVNode(`marker`,{style:{overflow:`visible`},id:`DistanceStart`,refX:`0`,refY:`0`,orient:`auto`},[createBaseVNode(`g`,{id:`g2300`},[createBaseVNode(`path`,{style:{fill:`none`,stroke:`#ffffff`,"stroke-width":`1.14999998`,"stroke-linecap":`square`},d:`M 0,0 2,0`,id:`path2306`}),createBaseVNode(`path`,{style:{fill:`#000000`,"fill-rule":`evenodd`,stroke:`none`},d:`M 0,0 13,4 9,0 13,-4 0,0 z`,id:`path2302`}),createBaseVNode(`path`,{style:{fill:`none`,stroke:`#000000`,"stroke-width":`1`,"stroke-linecap":`square`},d:`M 0,-4 0,40`,id:`path2304`})])]),createBaseVNode(`radialGradient`,{"xlink:href":`#linearGradient4357`,id:`radialGradient4363`,cx:`480`,cy:`544`,fx:`480`,fy:`544`,r:`320`,gradientUnits:`userSpaceOnUse`,gradientTransform:`matrix(1.03125,0,0,1.03125,-15,-17)`}),createBaseVNode(`radialGradient`,{"xlink:href":`#linearGradient4365`,id:`radialGradient4371`,cx:`480`,cy:`544`,fx:`480`,fy:`544`,r:`320`,gradientUnits:`userSpaceOnUse`}),createBaseVNode(`clipPath`,{clipPathUnits:`userSpaceOnUse`,id:`clipPath4407`},[createBaseVNode(`path`,{id:`path4409`,d:`m 480,-103.33 c -357.5105,0 -647.33,289.8195 -647.33,647.33 0,357.5105 289.8195,647.33 647.33,647.33 357.5105,0 647.33,-289.8195 647.33,-647.33 0,-357.5105 -289.8195,-647.33 -647.33,-647.33 z m 0,453.131 c 107.25316,0 194.199,86.94584 194.199,194.199 0,107.25316 -86.94584,194.199 -194.199,194.199 -107.25316,0 -194.199,-86.94584 -194.199,-194.199 0,-107.25316 86.94584,-194.199 194.199,-194.199 z`,style:{color:`#000000`,fill:`#ffffff`,"fill-opacity":`0.61375661`,"fill-rule":`nonzero`,stroke:`none`,"stroke-width":`16`,marker:`none`,visibility:`visible`,display:`inline`,overflow:`visible`,"enable-background":`accumulate`}})]),createBaseVNode(`clipPath`,{clipPathUnits:`userSpaceOnUse`,id:`clipPath4321-9`},[createBaseVNode(`path`,{style:{color:`#000000`,fill:`#ffffff`,"fill-opacity":`1`,"fill-rule":`nonzero`,stroke:`none`,"stroke-width":`5`,marker:`none`,visibility:`visible`,display:`inline`,overflow:`visible`,"enable-background":`accumulate`},d:`m 480,224 c -20.28024,0 -40.11069,1.89279 -59.34375,5.5 l 12.0625,58.8125 C 448.05208,285.49499 463.85489,284 480,284 c 35.52728,0 69.40254,7.13112 100.25,20.03125 l 24.1875,-54.9375 C 566.18747,232.93508 524.13347,224 480,224 z m -69.0625,7.5 c -59.26533,13.0371 -112.35258,42.49901 -154.28125,83.375 l 42.53125,42.3125 c 24.37935,-23.60266 53.35266,-42.49216 85.46875,-55.15625 1.96795,-0.77601 3.94641,-1.52096 5.9375,-2.25 10.51172,-3.84886 21.33856,-7.01901 32.4375,-9.5 L 410.9375,231.5 z M 613.5,253.125 589.3125,308.03125 c 44.07702,20.45389 81.43119,52.91567 107.9375,93.15625 l 50.875,-31.875 C 715.25578,318.96815 668.59379,278.45303 613.5,253.125 z m -363.8125,68.75 c -41.23795,42.75016 -70.70543,96.92973 -83.125,157.34375 l 59.03125,11.0625 c 10.15322,-48.33557 33.70357,-91.7229 66.625,-126.09375 L 249.6875,321.875 z m 503.78125,55.8125 -50.90625,31.84375 C 726.31882,448.76688 740,494.78478 740,544 l 60,0 c 0,-60.90677 -16.99384,-117.84887 -46.53125,-166.3125 z m -588.75,111.25 C 161.61652,506.82573 160,525.2248 160,544 c 0,42.78463 8.42108,83.60181 23.65625,120.90625 L 238.84375,641.375 C 226.69144,611.30216 220,578.42944 220,544 c 0,-2.24366 0.0373,-4.48871 0.0937,-6.71875 0.3211,-12.67426 1.55282,-25.12039 3.625,-37.28125 l -59,-11.0625 z M 242.75,650.5 187.53125,674 c 23.4008,52.56805 60.5346,97.67196 106.875,130.71875 l 34.0625,-49.4375 C 291.42063,728.66516 261.6562,692.55546 242.75,650.5 z m 93.875,110.40625 -34.03125,49.40625 C 353.37348,844.20872 414.36502,864 480,864 l 0,-60 c -33.65485,0 -65.82451,-6.39115 -95.34375,-18.03125 -1.96795,-0.77601 -3.93088,-1.58396 -5.875,-2.40625 -14.80462,-6.26183 -28.90394,-13.88046 -42.15625,-22.65625 z`,id:`path4323-8`,"inkscape:connector-curvature":`0`})]),createBaseVNode(`radialGradient`,{"xlink:href":`#linearGradient4357`,id:`radialGradient4363-9`,cx:`480`,cy:`544`,fx:`480`,fy:`544`,r:`320`,gradientUnits:`userSpaceOnUse`,gradientTransform:`matrix(1.03125,0,0,1.03125,-15,-17)`}),createBaseVNode(`clipPath`,{clipPathUnits:`userSpaceOnUse`,id:`clipPath4407-3`},[createBaseVNode(`path`,{id:`path4409-5`,d:`m 480,-103.33 c -357.5105,0 -647.33,289.8195 -647.33,647.33 0,357.5105 289.8195,647.33 647.33,647.33 357.5105,0 647.33,-289.8195 647.33,-647.33 0,-357.5105 -289.8195,-647.33 -647.33,-647.33 z m 0,453.131 c 107.25316,0 194.199,86.94584 194.199,194.199 0,107.25316 -86.94584,194.199 -194.199,194.199 -107.25316,0 -194.199,-86.94584 -194.199,-194.199 0,-107.25316 86.94584,-194.199 194.199,-194.199 z`,style:{color:`#000000`,fill:`#ffffff`,"fill-opacity":`0.61375661`,"fill-rule":`nonzero`,stroke:`none`,"stroke-width":`16`,marker:`none`,visibility:`visible`,display:`inline`,overflow:`visible`,"enable-background":`accumulate`}})]),createBaseVNode(`radialGradient`,{gradientTransform:`matrix(0.37015162,0,0,0.37015162,685.90181,-270.76027)`,"xlink:href":`#linearGradient4365`,id:`radialGradient4371-4`,cx:`480`,cy:`544`,fx:`480`,fy:`544`,r:`320`,gradientUnits:`userSpaceOnUse`}),createBaseVNode(`linearGradient`,{"xlink:href":`#linearGradient4256`,id:`linearGradient4433`,gradientUnits:`userSpaceOnUse`,x1:`569.20557`,y1:`424.29861`,x2:`890.55139`,y2:`424.29861`}),createBaseVNode(`clipPath`,{clipPathUnits:`userSpaceOnUse`,id:`clipPath4321-4`},[createBaseVNode(`path`,{style:{color:`#000000`,fill:`#ffffff`,"fill-opacity":`1`,"fill-rule":`nonzero`,stroke:`none`,"stroke-width":`5`,marker:`none`,visibility:`visible`,display:`inline`,overflow:`visible`,"enable-background":`accumulate`},d:`m 480,224 c -20.28024,0 -40.11069,1.89279 -59.34375,5.5 l 12.0625,58.8125 C 448.05208,285.49499 463.85489,284 480,284 c 35.52728,0 69.40254,7.13112 100.25,20.03125 l 24.1875,-54.9375 C 566.18747,232.93508 524.13347,224 480,224 z m -69.0625,7.5 c -59.26533,13.0371 -112.35258,42.49901 -154.28125,83.375 l 42.53125,42.3125 c 24.37935,-23.60266 53.35266,-42.49216 85.46875,-55.15625 1.96795,-0.77601 3.94641,-1.52096 5.9375,-2.25 10.51172,-3.84886 21.33856,-7.01901 32.4375,-9.5 L 410.9375,231.5 z M 613.5,253.125 589.3125,308.03125 c 44.07702,20.45389 81.43119,52.91567 107.9375,93.15625 l 50.875,-31.875 C 715.25578,318.96815 668.59379,278.45303 613.5,253.125 z m -363.8125,68.75 c -41.23795,42.75016 -70.70543,96.92973 -83.125,157.34375 l 59.03125,11.0625 c 10.15322,-48.33557 33.70357,-91.7229 66.625,-126.09375 L 249.6875,321.875 z m 503.78125,55.8125 -50.90625,31.84375 C 726.31882,448.76688 740,494.78478 740,544 l 60,0 c 0,-60.90677 -16.99384,-117.84887 -46.53125,-166.3125 z m -588.75,111.25 C 161.61652,506.82573 160,525.2248 160,544 c 0,42.78463 8.42108,83.60181 23.65625,120.90625 L 238.84375,641.375 C 226.69144,611.30216 220,578.42944 220,544 c 0,-2.24366 0.0373,-4.48871 0.0937,-6.71875 0.3211,-12.67426 1.55282,-25.12039 3.625,-37.28125 l -59,-11.0625 z M 242.75,650.5 187.53125,674 c 23.4008,52.56805 60.5346,97.67196 106.875,130.71875 l 34.0625,-49.4375 C 291.42063,728.66516 261.6562,692.55546 242.75,650.5 z m 93.875,110.40625 -34.03125,49.40625 C 353.37348,844.20872 414.36502,864 480,864 l 0,-60 c -33.65485,0 -65.82451,-6.39115 -95.34375,-18.03125 -1.96795,-0.77601 -3.93088,-1.58396 -5.875,-2.40625 -14.80462,-6.26183 -28.90394,-13.88046 -42.15625,-22.65625 z`,id:`path4323-7`,"inkscape:connector-curvature":`0`})]),createBaseVNode(`radialGradient`,{"xlink:href":`#linearGradient4357`,id:`radialGradient4363-5`,cx:`480`,cy:`544`,fx:`480`,fy:`544`,r:`320`,gradientUnits:`userSpaceOnUse`,gradientTransform:`matrix(1.03125,0,0,1.03125,-15,-17)`}),createBaseVNode(`clipPath`,{clipPathUnits:`userSpaceOnUse`,id:`clipPath4407-6`},[createBaseVNode(`path`,{id:`path4409-1`,d:`m 480,-103.33 c -357.5105,0 -647.33,289.8195 -647.33,647.33 0,357.5105 289.8195,647.33 647.33,647.33 357.5105,0 647.33,-289.8195 647.33,-647.33 0,-357.5105 -289.8195,-647.33 -647.33,-647.33 z m 0,453.131 c 107.25316,0 194.199,86.94584 194.199,194.199 0,107.25316 -86.94584,194.199 -194.199,194.199 -107.25316,0 -194.199,-86.94584 -194.199,-194.199 0,-107.25316 86.94584,-194.199 194.199,-194.199 z`,style:{color:`#000000`,fill:`#ffffff`,"fill-opacity":`0.61375661`,"fill-rule":`nonzero`,stroke:`none`,"stroke-width":`16`,marker:`none`,visibility:`visible`,display:`inline`,overflow:`visible`,"enable-background":`accumulate`}})]),createBaseVNode(`radialGradient`,{gradientTransform:`matrix(0.36968813,0,0,0.36968813,1026.9451,-270.68256)`,"xlink:href":`#linearGradient4365`,id:`radialGradient4371-49`,cx:`480`,cy:`544`,fx:`480`,fy:`544`,r:`320`,gradientUnits:`userSpaceOnUse`}),createBaseVNode(`linearGradient`,{"xlink:href":`#linearGradient4256`,id:`linearGradient4746`,gradientUnits:`userSpaceOnUse`,x1:`569.20557`,y1:`424.29861`,x2:`890.55139`,y2:`424.29861`}),createBaseVNode(`clipPath`,{clipPathUnits:`userSpaceOnUse`,id:`clipPath3921`},[createBaseVNode(`path`,{"inkscape:connector-curvature":`0`,id:`path3923`,d:`m 480,224 c -20.95323,0 -41.43416,2.01857 -61.26367,5.86328 l 12.08008,58.80274 C 446.74495,285.61583 463.18224,284 480,284 c 36.22419,0 70.7135,7.41519 102.04492,20.79883 l 24.1836,-54.92188 C 567.49749,233.23259 524.82925,224 480,224 z m -67.13867,7.07812 c -60.69914,12.96113 -115.01734,43.12659 -157.60938,85.15821 l 42.54297,42.3125 c 34.42536,-33.82645 78.22177,-58.13556 127.14258,-68.68555 l -12.07617,-58.78516 z m 198.86328,21.20508 -24.1875,54.9336 c 45.44422,20.67199 83.88358,54.04459 110.80078,95.58008 l 50.87305,-31.84376 C 715.93577,319.29347 668.20331,277.82636 611.72461,252.2832 z m -360.70117,68.21094 c -42.37565,43.40627 -72.5223,98.80082 -84.8418,160.63281 l 58.99024,11.05664 c 10.06229,-49.7524 34.33605,-94.34359 68.39257,-129.3789 l -42.54101,-42.31055 z m 501.3789,55.54102 -50.86132,31.83398 C 725.92383,447.46544 740,494.08649 740,544 l 60,0 C 800,482.39079 782.57195,424.85952 752.40234,376.03516 z M 165.06055,487.02148 C 161.7373,505.51211 160,524.55271 160,544 c 0,43.47625 8.68492,84.91949 24.39062,122.71094 l 55.21485,-23.5293 C 226.98058,612.61583 220,579.12541 220,544 c 0,-15.6701 1.38639,-31.01527 4.04297,-45.92188 l -58.98242,-11.05664 z m 76.90039,161.67774 -55.20899,23.52734 c 23.61428,53.92719 61.65397,100.09134 109.25586,133.60352 l 34.03516,-49.41406 C 291.73258,729.3212 261.08736,692.12046 241.96094,648.69922 z m 93.01953,111.12695 -34.04102,49.42188 C 352.04051,843.81227 413.66249,864 480,864 l 0,-60 c -53.69777,0 -103.59151,-16.28243 -145.01953,-44.17383 z`,style:{color:`#000000`,fill:`#ffffff`,"fill-opacity":`1`,"fill-rule":`nonzero`,stroke:`none`,"stroke-width":`5`,marker:`none`,visibility:`visible`,display:`inline`,overflow:`visible`,"enable-background":`accumulate`}})]),createBaseVNode(`clipPath`,{clipPathUnits:`userSpaceOnUse`,id:`clipPath3925-1`},[createBaseVNode(`path`,{"inkscape:connector-curvature":`0`,id:`path3927-7`,d:`m 330,10 c -20.95323,0 -41.43416,2.01857 -61.26367,5.86328 l 12.08008,58.80274 C 296.74495,71.61583 313.18224,70 330,70 c 36.22419,0 70.7135,7.41519 102.04492,20.79883 l 24.1836,-54.92188 C 417.49749,19.23259 374.82925,10 330,10 z m -67.13867,7.07812 C 202.16219,30.03925 147.84399,60.20471 105.25195,102.23633 l 42.54297,42.3125 C 182.22028,110.72238 226.01669,86.41327 274.9375,75.86328 L 262.86133,17.07812 z m 198.86328,21.20508 -24.1875,54.9336 c 45.44422,20.67199 83.88358,54.04459 110.80078,95.58008 l 50.87305,-31.84376 C 565.93577,105.29347 518.20331,63.82636 461.72461,38.2832 z m -360.70117,68.21094 c -42.37565,43.40627 -72.5223,98.80082 -84.8418,160.63281 l 58.99024,11.05664 c 10.06229,-49.7524 34.33605,-94.34359 68.39257,-129.3789 l -42.54101,-42.31055 z m 501.3789,55.54102 -50.86132,31.83398 C 575.92383,233.46544 590,280.08649 590,330 l 60,0 C 650,268.39079 632.57195,210.85952 602.40234,162.03516 z M 15.06055,273.02148 C 11.7373,291.51211 10,310.55271 10,330 c 0,43.47625 8.68492,84.91949 24.39062,122.71094 l 55.21485,-23.5293 C 76.98058,398.61583 70,365.12541 70,330 c 0,-15.6701 1.38639,-31.01527 4.04297,-45.92188 L 15.06055,273.02148 z m 76.90039,161.67774 -55.20899,23.52734 c 23.61428,53.92719 61.65397,100.09134 109.25586,133.60352 l 34.03516,-49.41406 C 141.73258,515.3212 111.08736,478.12046 91.96094,434.69922 z m 93.01953,111.12695 -34.04102,49.42188 C 202.04051,629.81227 263.66249,650 330,650 l 0,-60 c -53.69777,0 -103.59151,-16.28243 -145.01953,-44.17383 z`,style:{color:`#000000`,fill:`#ffffff`,"fill-opacity":`1`,"fill-rule":`nonzero`,stroke:`none`,"stroke-width":`5`,marker:`none`,visibility:`visible`,display:`inline`,overflow:`visible`,"enable-background":`accumulate`}})]),createBaseVNode(`clipPath`,{clipPathUnits:`userSpaceOnUse`,id:`clipPath4036`},[createBaseVNode(`path`,{style:{color:`#000000`,fill:`#ffffff`,"fill-opacity":`1`,"fill-rule":`nonzero`,stroke:`none`,"stroke-width":`5`,marker:`none`,visibility:`visible`,display:`inline`,overflow:`visible`,"enable-background":`accumulate`},d:`m 480,224 c -20.95323,0 -41.43416,2.01857 -61.26367,5.86328 l 12.08008,58.80274 C 446.74495,285.61583 463.18224,284 480,284 c 36.22419,0 70.7135,7.41519 102.04492,20.79883 l 24.1836,-54.92188 C 567.49749,233.23259 524.82925,224 480,224 z m -67.13867,7.07812 c -60.69914,12.96113 -115.01734,43.12659 -157.60938,85.15821 l 42.54297,42.3125 c 34.42536,-33.82645 78.22177,-58.13556 127.14258,-68.68555 l -12.07617,-58.78516 z m 198.86328,21.20508 -24.1875,54.9336 c 45.44422,20.67199 83.88358,54.04459 110.80078,95.58008 l 50.87305,-31.84376 C 715.93577,319.29347 668.20331,277.82636 611.72461,252.2832 z m -360.70117,68.21094 c -42.37565,43.40627 -72.5223,98.80082 -84.8418,160.63281 l 58.99024,11.05664 c 10.06229,-49.7524 34.33605,-94.34359 68.39257,-129.3789 l -42.54101,-42.31055 z m 501.3789,55.54102 -50.86132,31.83398 C 725.92383,447.46544 740,494.08649 740,544 l 60,0 C 800,482.39079 782.57195,424.85952 752.40234,376.03516 z M 165.06055,487.02148 C 161.7373,505.51211 160,524.55271 160,544 c 0,43.47625 8.68492,84.91949 24.39062,122.71094 l 55.21485,-23.5293 C 226.98058,612.61583 220,579.12541 220,544 c 0,-15.6701 1.38639,-31.01527 4.04297,-45.92188 l -58.98242,-11.05664 z m 76.90039,161.67774 -55.20899,23.52734 c 23.61428,53.92719 61.65397,100.09134 109.25586,133.60352 l 34.03516,-49.41406 C 291.73258,729.3212 261.08736,692.12046 241.96094,648.69922 z m 93.01953,111.12695 -34.04102,49.42188 C 352.04051,843.81227 413.66249,864 480,864 l 0,-60 c -53.69777,0 -103.59151,-16.28243 -145.01953,-44.17383 z`,id:`path4038`,"inkscape:connector-curvature":`0`})]),createBaseVNode(`linearGradient`,{"inkscape:collect":`always`,"xlink:href":`#linearGradient4545`,id:`linearGradient4551`,x1:`480`,y1:`214`,x2:`480`,y2:`474`,gradientUnits:`userSpaceOnUse`}),createBaseVNode(`linearGradient`,{"inkscape:collect":`always`,"xlink:href":`#linearGradient4545-2`,id:`linearGradient4551-8`,x1:`480`,y1:`214`,x2:`480`,y2:`474`,gradientUnits:`userSpaceOnUse`}),createBaseVNode(`linearGradient`,{id:`linearGradient4545-2`},[createBaseVNode(`stop`,{style:{"stop-color":`#e40000`,"stop-opacity":`1`},offset:`0`,id:`stop4547-4`}),createBaseVNode(`stop`,{id:`stop4553-5`,offset:`0.99000001`,style:{"stop-color":`#e40000`,"stop-opacity":`0`}}),createBaseVNode(`stop`,{style:{"stop-color":`#000000`,"stop-opacity":`0`},offset:`1`,id:`stop4555-5`}),createBaseVNode(`stop`,{style:{"stop-color":`#000000`,"stop-opacity":`0`},offset:`1`,id:`stop4549-1`})]),createBaseVNode(`linearGradient`,{y2:`282.59341`,x2:`474.60886`,y1:`211.1199`,x1:`480`,gradientUnits:`userSpaceOnUse`,id:`linearGradient4574`,"xlink:href":`#linearGradient4607`,"inkscape:collect":`always`,gradientTransform:`matrix(1,0,0,0.9882541,0,10.359887)`}),createBaseVNode(`clipPath`,{clipPathUnits:`userSpaceOnUse`,id:`clipPath4036-1`},[createBaseVNode(`path`,{style:{color:`#000000`,fill:`#ffffff`,"fill-opacity":`1`,"fill-rule":`nonzero`,stroke:`none`,"stroke-width":`5`,marker:`none`,visibility:`visible`,display:`inline`,overflow:`visible`,"enable-background":`accumulate`},d:`m 480,224 c -20.95323,0 -41.43416,2.01857 -61.26367,5.86328 l 12.08008,58.80274 C 446.74495,285.61583 463.18224,284 480,284 c 36.22419,0 70.7135,7.41519 102.04492,20.79883 l 24.1836,-54.92188 C 567.49749,233.23259 524.82925,224 480,224 z m -67.13867,7.07812 c -60.69914,12.96113 -115.01734,43.12659 -157.60938,85.15821 l 42.54297,42.3125 c 34.42536,-33.82645 78.22177,-58.13556 127.14258,-68.68555 l -12.07617,-58.78516 z m 198.86328,21.20508 -24.1875,54.9336 c 45.44422,20.67199 83.88358,54.04459 110.80078,95.58008 l 50.87305,-31.84376 C 715.93577,319.29347 668.20331,277.82636 611.72461,252.2832 z m -360.70117,68.21094 c -42.37565,43.40627 -72.5223,98.80082 -84.8418,160.63281 l 58.99024,11.05664 c 10.06229,-49.7524 34.33605,-94.34359 68.39257,-129.3789 l -42.54101,-42.31055 z m 501.3789,55.54102 -50.86132,31.83398 C 725.92383,447.46544 740,494.08649 740,544 l 60,0 C 800,482.39079 782.57195,424.85952 752.40234,376.03516 z M 165.06055,487.02148 C 161.7373,505.51211 160,524.55271 160,544 c 0,43.47625 8.68492,84.91949 24.39062,122.71094 l 55.21485,-23.5293 C 226.98058,612.61583 220,579.12541 220,544 c 0,-15.6701 1.38639,-31.01527 4.04297,-45.92188 l -58.98242,-11.05664 z m 76.90039,161.67774 -55.20899,23.52734 c 23.61428,53.92719 61.65397,100.09134 109.25586,133.60352 l 34.03516,-49.41406 C 291.73258,729.3212 261.08736,692.12046 241.96094,648.69922 z m 93.01953,111.12695 -34.04102,49.42188 C 352.04051,843.81227 413.66249,864 480,864 l 0,-60 c -53.69777,0 -103.59151,-16.28243 -145.01953,-44.17383 z`,id:`path4038-7`,"inkscape:connector-curvature":`0`})]),createBaseVNode(`radialGradient`,{"xlink:href":`#linearGradient4357-0`,id:`radialGradient4363-4`,cx:`480`,cy:`544`,fx:`480`,fy:`544`,r:`320`,gradientUnits:`userSpaceOnUse`,gradientTransform:`matrix(1.03125,0,0,1.03125,-15,-17)`}),createBaseVNode(`linearGradient`,{id:`linearGradient4357-0`},[createBaseVNode(`stop`,{style:{"stop-color":`#000000`,"stop-opacity":`0.65178573`},offset:`0`,id:`stop4359-9`}),createBaseVNode(`stop`,{style:{"stop-color":`#000000`,"stop-opacity":`0.24107143`},offset:`1`,id:`stop4361-4`})]),createBaseVNode(`clipPath`,{clipPathUnits:`userSpaceOnUse`,id:`clipPath4407-8`},[createBaseVNode(`path`,{id:`path4409-8`,d:`m 480,-103.33 c -357.5105,0 -647.33,289.8195 -647.33,647.33 0,357.5105 289.8195,647.33 647.33,647.33 357.5105,0 647.33,-289.8195 647.33,-647.33 0,-357.5105 -289.8195,-647.33 -647.33,-647.33 z m 0,453.131 c 107.25316,0 194.199,86.94584 194.199,194.199 0,107.25316 -86.94584,194.199 -194.199,194.199 -107.25316,0 -194.199,-86.94584 -194.199,-194.199 0,-107.25316 86.94584,-194.199 194.199,-194.199 z`,style:{color:`#000000`,fill:`#ffffff`,"fill-opacity":`0.61375661`,"fill-rule":`nonzero`,stroke:`none`,"stroke-width":`16`,marker:`none`,visibility:`visible`,display:`inline`,overflow:`visible`,"enable-background":`accumulate`}})]),createBaseVNode(`radialGradient`,{"xlink:href":`#linearGradient4365-4`,id:`radialGradient4371-2`,cx:`480`,cy:`544`,fx:`480`,fy:`544`,r:`320`,gradientUnits:`userSpaceOnUse`}),createBaseVNode(`linearGradient`,{id:`linearGradient4365-4`},[createBaseVNode(`stop`,{style:{"stop-color":`#000000`,"stop-opacity":`0.42857143`},offset:`0`,id:`stop4367-5`}),createBaseVNode(`stop`,{id:`stop4373-5`,offset:`0.5`,style:{"stop-color":`#000000`,"stop-opacity":`0.33035713`}}),createBaseVNode(`stop`,{style:{"stop-color":`#000000`,"stop-opacity":`0`},offset:`1`,id:`stop4369-1`})]),createBaseVNode(`radialGradient`,{r:`320`,fy:`544`,fx:`480`,cy:`544`,cx:`480`,gradientUnits:`userSpaceOnUse`,id:`radialGradient3997`,"xlink:href":`#linearGradient4365-4`}),createBaseVNode(`radialGradient`,{"xlink:href":`#linearGradient4357-0-7`,id:`radialGradient4363-4-1`,cx:`480`,cy:`544`,fx:`480`,fy:`544`,r:`320`,gradientUnits:`userSpaceOnUse`,gradientTransform:`matrix(1.03125,0,0,1.03125,-15,-17)`}),createBaseVNode(`linearGradient`,{id:`linearGradient4357-0-7`},[createBaseVNode(`stop`,{style:{"stop-color":`#000000`,"stop-opacity":`0.51785713`},offset:`0`,id:`stop4359-9-4`}),createBaseVNode(`stop`,{style:{"stop-color":`#000000`,"stop-opacity":`0.11607143`},offset:`1`,id:`stop4361-4-0`})]),createBaseVNode(`radialGradient`,{r:`320`,fy:`544`,fx:`480`,cy:`544`,cx:`480`,gradientTransform:`matrix(1.03125,0,0,1.03125,-15,-17)`,gradientUnits:`userSpaceOnUse`,id:`radialGradient4001`,"xlink:href":`#linearGradient4357-0-7`}),createBaseVNode(`radialGradient`,{"xlink:href":`#linearGradient4357-0-7`,id:`radialGradient4040`,gradientUnits:`userSpaceOnUse`,gradientTransform:`matrix(1.03125,0,0,1.03125,-885,-231)`,cx:`480`,cy:`544`,fx:`480`,fy:`544`,r:`320`}),createBaseVNode(`radialGradient`,{"xlink:href":`#linearGradient4357-0-7`,id:`radialGradient4045`,gradientUnits:`userSpaceOnUse`,gradientTransform:`matrix(1.03125,0,0,1.03125,-885,-231)`,cx:`480`,cy:`544`,fx:`480`,fy:`544`,r:`320`}),createBaseVNode(`radialGradient`,{"inkscape:collect":`always`,"xlink:href":`#linearGradient4357-0-7-2`,id:`radialGradient4045-8`,gradientUnits:`userSpaceOnUse`,gradientTransform:`matrix(1.03125,0,0,1.03125,-885,-231)`,cx:`480`,cy:`544`,fx:`480`,fy:`544`,r:`320`}),createBaseVNode(`linearGradient`,{id:`linearGradient4357-0-7-2`},[createBaseVNode(`stop`,{style:{"stop-color":`#000000`,"stop-opacity":`0.51785713`},offset:`0`,id:`stop4359-9-4-4`}),createBaseVNode(`stop`,{style:{"stop-color":`#000000`,"stop-opacity":`0.11607143`},offset:`1`,id:`stop4361-4-0-5`})]),createBaseVNode(`radialGradient`,{r:`320`,fy:`544`,fx:`480`,cy:`544`,cx:`480`,gradientTransform:`matrix(1.03125,0,0,1.03125,-758.53125,-231)`,gradientUnits:`userSpaceOnUse`,id:`radialGradient4063`,"xlink:href":`#linearGradient4357-0-7-2`,"inkscape:collect":`always`}),createBaseVNode(`radialGradient`,{"inkscape:collect":`always`,"xlink:href":`#linearGradient4357-0-7`,id:`radialGradient4082`,gradientUnits:`userSpaceOnUse`,gradientTransform:`matrix(1.03125,0,0,1.03125,-885,-231)`,cx:`480`,cy:`544`,fx:`480`,fy:`544`,r:`320`}),createBaseVNode(`radialGradient`,{"inkscape:collect":`always`,"xlink:href":`#linearGradient4357-0-8`,id:`radialGradient4363-4-9`,cx:`480`,cy:`544`,fx:`480`,fy:`544`,r:`320`,gradientUnits:`userSpaceOnUse`,gradientTransform:`matrix(1.03125,0,0,1.03125,-15,-17)`}),createBaseVNode(`linearGradient`,{id:`linearGradient4357-0-8`},[createBaseVNode(`stop`,{style:{"stop-color":`#000000`,"stop-opacity":`0.51785713`},offset:`0`,id:`stop4359-9-40`}),createBaseVNode(`stop`,{style:{"stop-color":`#000000`,"stop-opacity":`0.11607143`},offset:`1`,id:`stop4361-4-7`})]),createBaseVNode(`radialGradient`,{r:`320`,fy:`544`,fx:`480`,cy:`544`,cx:`480`,gradientTransform:`matrix(1.03125,0,0,1.03125,-15,-17)`,gradientUnits:`userSpaceOnUse`,id:`radialGradient4031-1`,"xlink:href":`#linearGradient4357-0-8-5`,"inkscape:collect":`always`}),createBaseVNode(`linearGradient`,{id:`linearGradient4357-0-8-5`},[createBaseVNode(`stop`,{style:{"stop-color":`#000000`,"stop-opacity":`0.51785713`},offset:`0`,id:`stop4359-9-40-4`}),createBaseVNode(`stop`,{style:{"stop-color":`#000000`,"stop-opacity":`0.11607143`},offset:`1`,id:`stop4361-4-7-2`})]),createBaseVNode(`radialGradient`,{"inkscape:collect":`always`,"xlink:href":`#linearGradient4357-0-3`,id:`radialGradient4363-4-0`,cx:`480`,cy:`544`,fx:`480`,fy:`544`,r:`320`,gradientUnits:`userSpaceOnUse`,gradientTransform:`matrix(1.03125,0,0,1.03125,-15,-17)`}),createBaseVNode(`linearGradient`,{id:`linearGradient4357-0-3`},[createBaseVNode(`stop`,{style:{"stop-color":`#000000`,"stop-opacity":`0.65178573`},offset:`0`,id:`stop4359-9-8`}),createBaseVNode(`stop`,{style:{"stop-color":`#000000`,"stop-opacity":`0.24107143`},offset:`1`,id:`stop4361-4-01`})]),createBaseVNode(`clipPath`,{clipPathUnits:`userSpaceOnUse`,id:`clipPath4407-8-2`},[createBaseVNode(`path`,{"inkscape:connector-curvature":`0`,id:`path4409-8-5`,d:`m 480,-103.33 c -357.5105,0 -647.33,289.8195 -647.33,647.33 0,357.5105 289.8195,647.33 647.33,647.33 357.5105,0 647.33,-289.8195 647.33,-647.33 0,-357.5105 -289.8195,-647.33 -647.33,-647.33 z m 0,453.131 c 107.25316,0 194.199,86.94584 194.199,194.199 0,107.25316 -86.94584,194.199 -194.199,194.199 -107.25316,0 -194.199,-86.94584 -194.199,-194.199 0,-107.25316 86.94584,-194.199 194.199,-194.199 z`,style:{color:`#000000`,fill:`#ffffff`,"fill-opacity":`0.61375661`,"fill-rule":`nonzero`,stroke:`none`,"stroke-width":`16`,marker:`none`,visibility:`visible`,display:`inline`,overflow:`visible`,"enable-background":`accumulate`}})]),createBaseVNode(`radialGradient`,{r:`320`,fy:`544`,fx:`480`,cy:`544`,cx:`480`,gradientTransform:`matrix(1.03125,0,0,1.03125,-15,-17)`,gradientUnits:`userSpaceOnUse`,id:`radialGradient4401`,"xlink:href":`#linearGradient4357-0-3`,"inkscape:collect":`always`}),createBaseVNode(`radialGradient`,{r:`320`,fy:`544`,fx:`480`,cy:`544`,cx:`480`,gradientUnits:`userSpaceOnUse`,id:`radialGradient3997-4`,"xlink:href":`#linearGradient4365-4-7`,"inkscape:collect":`always`}),createBaseVNode(`linearGradient`,{id:`linearGradient4365-4-7`},[createBaseVNode(`stop`,{style:{"stop-color":`#000000`,"stop-opacity":`0.42857143`},offset:`0`,id:`stop4367-5-8`}),createBaseVNode(`stop`,{id:`stop4373-5-3`,offset:`0.5`,style:{"stop-color":`#000000`,"stop-opacity":`0.33035713`}}),createBaseVNode(`stop`,{style:{"stop-color":`#000000`,"stop-opacity":`0`},offset:`1`,id:`stop4369-1-5`})]),createBaseVNode(`radialGradient`,{r:`320`,fy:`544`,fx:`480`,cy:`544`,cx:`480`,gradientUnits:`userSpaceOnUse`,id:`radialGradient4458`,"xlink:href":`#linearGradient4365-4-7`,"inkscape:collect":`always`}),createBaseVNode(`clipPath`,{clipPathUnits:`userSpaceOnUse`,id:`clipPath4710`},[createBaseVNode(`path`,{style:{color:`#000000`,"font-style":`normal`,"font-variant":`normal`,"font-weight":`normal`,"font-stretch":`normal`,"font-size":`medium`,"line-height":`normal`,"font-family":`sans-serif`,"text-indent":`0`,"text-align":`start`,"text-decoration":`none`,"text-decoration-line":`none`,"text-decoration-style":`solid`,"text-decoration-color":`#000000`,"letter-spacing":`normal`,"word-spacing":`normal`,"text-transform":`none`,direction:`ltr`,"block-progression":`tb`,"writing-mode":`lr-tb`,"baseline-shift":`baseline`,"text-anchor":`start`,"white-space":`normal`,"clip-rule":`nonzero`,display:`inline`,overflow:`visible`,visibility:`visible`,opacity:`1`,isolation:`auto`,"mix-blend-mode":`normal`,"color-interpolation":`sRGB`,"color-interpolation-filters":`linearRGB`,"solid-color":`#000000`,"solid-opacity":`1`,fill:`#000000`,"fill-opacity":`1`,"fill-rule":`nonzero`,stroke:`none`,"stroke-width":`66.66205597`,"stroke-linecap":`butt`,"stroke-linejoin":`miter`,"stroke-miterlimit":`0.40000001`,"stroke-dasharray":`none`,"stroke-dashoffset":`0`,"stroke-opacity":`1`,"color-rendering":`auto`,"image-rendering":`auto`,"shape-rendering":`auto`,"text-rendering":`auto`,"enable-background":`accumulate`},d:`m 480,224 c -176.33633,0 -320,143.66367 -320,320 0,176.33633 143.66368,320 320,320 l 0,-66.66211 C 339.69052,797.33789 226.66211,684.30947 226.66211,544 226.66211,403.69051 339.69051,290.66211 480,290.66211 620.30948,290.66211 733.33789,403.69052 733.33789,544 L 800,544 C 800,367.66368 656.33632,224 480,224 Z`,id:`path4712`,"inkscape:connector-curvature":`0`})])],-1),createBaseVNode(`g`,{ref_key:`layer6Ref`,ref:layer6Ref,id:`layer6`,class:`layer6`},[_cache[1]||=createBaseVNode(`circle`,{transform:`translate(-150,-214)`,id:`path4281-5`,class:`circle1`,cx:`480`,cy:`544`,r:`320`,d:`M 800,544 C 800,720.73112 656.73112,864 480,864 303.26888,864 160,720.73112 160,544 160,367.26888 303.26888,224 480,224 c 176.73112,0 320,143.26888 320,320 z`},null,-1),_cache[2]||=createBaseVNode(`path`,{transform:`translate(-150,-214)`,id:`path4281`,class:`path1`,d:`M 480,214 C 297.74603,214 150,361.74603 150,544 150,726.25397 297.74603,874 480,874 662.25397,874 810,726.25397 810,544 810,361.74603 662.25397,214 480,214 z`,"clip-path":`url(#clipPath4407-8)`},null,-1),createBaseVNode(`text`,_hoisted_2$132,[createBaseVNode(`tspan`,{ref_key:`speedTextRef`,ref:speedTextRef,id:`tacho2speed`,class:`tacho2-speed`,x:`329.88641`,y:`289.30463`},`0`,512)]),createBaseVNode(`text`,_hoisted_3$118,[createBaseVNode(`tspan`,{ref_key:`speedUnitTextRef`,ref:speedUnitTextRef,id:`speedunit`,x:`330`,y:`348`},`mph`,512)]),createBaseVNode(`text`,_hoisted_4$96,[createBaseVNode(`tspan`,{ref_key:`gearTextRef`,ref:gearTextRef,id:`tacho2gear`,class:`text`,x:`386.67343`,y:`457.94861`},`4`,512)]),(openBlock(),createElementBlock(Fragment,null,renderList(maxRpmTexts,k=>createBaseVNode(`text`,{ref_for:!0,ref:el=>setRpmRef(el,k),"xml:space":`preserve`,x:`0`,y:`0`,class:`rpm-text`},[..._cache[0]||=[createBaseVNode(`tspan`,{x:`0`,y:`0`},null,-1)]],512)),64)),createBaseVNode(`text`,_hoisted_5$83,[createBaseVNode(`tspan`,{ref_key:`rpmLegendTextRef`,ref:rpmLegendTextRef,id:`tspan4449-3-1`,x:`330.09229`,y:`498.18045`},`x1000 RPM`,512)]),_cache[3]||=createBaseVNode(`path`,{"clip-path":`none`,id:`path4258`,class:`path-oil-fuel`,d:`M 462.44226,446.99523 C 489.99031,415.832 506.71155,374.86426 506.71155,330 c 0,-44.86426 -16.72124,-85.832 -44.26929,-116.99523 m -264.88452,0 C 170.00969,244.168 153.28845,285.13574 153.28845,330 c 0,44.86426 16.72124,85.832 44.26929,116.99523`},null,-1),createBaseVNode(`path`,{ref_key:`fuelBarRef`,ref:fuelBarRef,id:`fuel`,class:`fuel-bar`,d:`M 462.44226,446.99523 C 489.99031,415.832 506.71155,374.86426 506.71155,330 c 0,-44.86426 -16.72124,-85.832 -44.26929,-116.99523`},null,512),createBaseVNode(`path`,{ref_key:`oilTempBarRef`,ref:oilTempBarRef,id:`temp`,class:`oil-temp-bar`,d:`M 197.55774,213.00477 C 170.00969,244.168 153.28845,285.13574 153.28845,330 c 0,44.86426 16.72124,85.832 44.26929,116.99523`},null,512)],512),createBaseVNode(`g`,{ref_key:`layer3Ref`,ref:layer3Ref,id:`layer3`,class:`layer3`},[createBaseVNode(`g`,_hoisted_6$69,[_cache[4]||=createBaseVNode(`rect`,{y:`203.90677`,x:`141.28131`,height:`683.79401`,width:`683.79401`,id:`rect4001`,class:`layer3-rect`},null,-1),createBaseVNode(`path`,{ref_key:`revcurveRef`,ref:revcurveRef,class:`revcurve`,id:`revcurve`,"clip-path":`none`,d:`M 330,690 C 131.17749,690 -30,528.82251 -30,330 -30,131.17749 131.17749,-30 330,-30 c 198.82251,0 360,161.17749 360,360`,transform:`matrix(0.80555556,0,0,0.80555556,214.16667,278.16667)`},null,512),createBaseVNode(`path`,{ref_key:`redLineRef`,ref:redLineRef,class:`redline`,id:`rpm_redline`,d:`M 330,610 C 175.36027,610 50,484.63973 50,330 50,175.36027 175.36027,50 330,50 484.63973,50 610,175.36027 610,330`,transform:`matrix(1.038252,0,0,1.038252,137.37687,201.37687)`},null,512)])],512),createBaseVNode(`g`,{ref_key:`layer11Ref`,ref:layer11Ref,id:`layer11`,class:`layer11`},[createBaseVNode(`path`,{ref_key:`revcurveDashesRef`,ref:revcurveDashesRef,id:`revcurve_dashes`,class:`revcurve-dashes`,d:`M 330,616.66897 C 171.6771,616.66897 43.331027,488.3229 43.331027,330 43.331026,171.67709 171.67709,43.33103 330,43.331031 488.3229,43.331031 616.66897,171.6771 616.66897,330`},null,512),createBaseVNode(`path`,{ref_key:`rpmTextGuideLineRef`,ref:rpmTextGuideLineRef,id:`rpmtextline`,class:`rpm-textline`,d:`M 329,550 C 204.73594,550 104,449.26406 104,325 104,200.73593 204.73593,100 329,100 c 124.26406,0 225,100.73594 225,225`},null,512)],512),_cache[18]||=createBaseVNode(`g`,{id:`layer2`,style:{display:`none`}},[createBaseVNode(`g`,{style:{display:`inline`},id:`ico_handbrake_12343525ron`,transform:`translate(-4.2182737e-6,-2.0000051)`},[createBaseVNode(`path`,{transform:`matrix(0.43850147,2.6141077e-4,-2.6141077e-4,0.43850147,320.9902,18.916914)`,style:{display:`inline`,fill:`#ff7900`,"fill-opacity":`1`,stroke:`#ffffff`,"stroke-width":`12`,"stroke-miterlimit":`4`,"stroke-dasharray":`none`,"stroke-opacity":`1`},d:`m 631.44636,979.59082 a 65.760933,65.760933 0 0 1 -65.76094,65.76098 65.760933,65.760933 0 0 1 -65.76093,-65.76098 65.760933,65.760933 0 0 1 65.76093,-65.76093 65.760933,65.760933 0 0 1 65.76094,65.76093 z`,id:`path4551-2-7`}),createBaseVNode(`path`,{"sodipodi:nodetypes":`csc`,id:`path4551-7-7-3`,d:`m 546.9327,480.53664 c -10.16748,-6.97507 -16.83385,-18.68164 -16.82592,-31.94291 0.008,-13.00305 6.43054,-24.50375 16.27369,-31.51076`,style:{display:`inline`,fill:`none`,stroke:`#ffffff`,"stroke-width":`5.26201868`,"stroke-linecap":`round`,"stroke-linejoin":`round`,"stroke-miterlimit":`4`,"stroke-opacity":`1`}}),createBaseVNode(`path`,{"sodipodi:nodetypes":`csc`,id:`path4551-7-4-7-72`,d:`m 590.24076,480.56245 c 10.17587,-6.96293 16.8562,-18.66157 16.86414,-31.92282 0.008,-13.00303 -6.40141,-24.51142 -16.23624,-31.5301`,style:{display:`inline`,fill:`none`,stroke:`#ffffff`,"stroke-width":`5.26201868`,"stroke-linecap":`round`,"stroke-linejoin":`round`,"stroke-miterlimit":`4`,"stroke-opacity":`1`}}),createBaseVNode(`g`,{id:`flowRoot5902-7-4`,style:{"font-style":`normal`,"font-variant":`normal`,"font-weight":`bold`,"font-stretch":`normal`,"font-size":`55px`,"line-height":`125%`,"font-family":`'Open Sans'`,"-inkscape-font-specification":`'Open Sans Bold'`,"letter-spacing":`-3.45999861px`,"word-spacing":`0px`,display:`inline`,fill:`#ffffff`,"fill-opacity":`1`,stroke:`none`},transform:`matrix(0.43849858,-0.00161469,0.00161469,0.43849858,259.17408,95.334998)`},[createBaseVNode(`path`,{id:`path3978-3-5`,style:{"-inkscape-font-specification":`'Open Sans Bold'`},d:`m 548.35205,1001.1788 -2.84668,-9.34567 -14.31396,0 -2.84668,9.34567 -8.96973,0 13.85742,-39.4238 10.17822,0 13.91114,39.4238 z m -4.83398,-16.32809 c -2.63186,-8.4684 -4.11339,-13.25762 -4.44458,-14.36768 -0.33124,-1.10999 -0.56846,-1.98727 -0.71167,-2.63183 -0.59084,2.29169 -2.28274,7.95819 -5.07569,16.99951 z`}),createBaseVNode(`path`,{id:`path3980-3-4`,style:{"-inkscape-font-specification":`'Open Sans Bold'`},d:`m 558.77633,961.91614 12.21924,0 c 5.56801,4e-5 9.60975,0.79227 12.12524,2.37671 2.51543,1.5845 3.77316,4.10444 3.77319,7.55981 -3e-5,2.3454 -0.55056,4.27004 -1.65161,5.77393 -1.1011,1.50392 -2.56472,2.40806 -4.39087,2.7124 l 0,0.26855 c 2.48858,0.55504 4.28342,1.59345 5.38453,3.11524 1.10104,1.52182 1.65157,3.54493 1.65161,6.06933 -4e-5,3.58074 -1.29357,6.37371 -3.88062,8.37891 -2.5871,2.00518 -6.10069,3.00778 -10.54077,3.00778 l -14.68994,0 z m 8.32519,15.54931 4.83399,0 c 2.25584,3e-5 3.88954,-0.34909 4.90112,-1.04736 1.01153,-0.69822 1.51731,-1.853 1.51734,-3.46436 -3e-5,-1.50387 -0.55057,-2.58257 -1.65162,-3.23608 -1.10109,-0.65345 -2.84222,-0.98019 -5.22338,-0.98022 l -4.37745,0 z m 0,6.60645 0,10.23193 5.42481,0 c 2.29164,1e-5 3.98354,-0.43863 5.07568,-1.31592 1.0921,-0.87727 1.63816,-2.22004 1.63819,-4.02832 -3e-5,-3.25844 -2.3275,-4.88767 -6.98243,-4.88769 z`}),createBaseVNode(`path`,{id:`path3982-5-4`,style:{"-inkscape-font-specification":`'Open Sans Bold'`},d:`m 615.44572,990.27551 c -2e-5,3.54493 -1.27566,6.3379 -3.8269,8.37891 -2.55129,2.04098 -6.10069,3.06148 -10.64819,3.06148 -4.18947,0 -7.89552,-0.7877 -11.11817,-2.36324 l 0,-7.73437 c 2.64974,1.18164 4.89217,2.01416 6.7273,2.49755 1.83511,0.48341 3.51358,0.72511 5.0354,0.7251 1.82615,10e-6 3.22711,-0.34911 4.20288,-1.04736 0.97573,-0.69824 1.4636,-1.73665 1.46362,-3.11524 -2e-5,-0.76984 -0.21486,-1.45466 -0.64453,-2.05444 -0.42971,-0.59976 -1.06081,-1.17715 -1.89331,-1.73218 -0.83254,-0.555 -2.5289,-1.44123 -5.08911,-2.65869 -2.3991,-1.12791 -4.19841,-2.21108 -5.39795,-3.24951 -1.19955,-1.03839 -2.15739,-2.24689 -2.87354,-3.62549 -0.71614,-1.37855 -1.07422,-2.98988 -1.07421,-4.83398 -10e-6,-3.47328 1.17716,-6.20358 3.53149,-8.19092 2.35432,-1.98727 5.6083,-2.98092 9.76196,-2.98096 2.041,4e-5 3.98802,0.24174 5.84107,0.7251 1.853,0.48344 3.79107,1.16377 5.81421,2.04102 l -2.68555,6.47216 c -2.09475,-0.85934 -3.82693,-1.45911 -5.19653,-1.79931 -1.36965,-0.34014 -2.7169,-0.51022 -4.04175,-0.51026 -1.57554,4e-5 -2.78403,0.36706 -3.62549,1.10108 -0.84148,0.73408 -1.26222,1.69192 -1.26221,2.87353 -10e-6,0.73408 0.17008,1.37413 0.51026,1.92017 0.34015,0.54609 0.88174,1.07424 1.62475,1.58447 0.74299,0.51028 2.50202,1.42784 5.2771,2.75269 3.67023,1.75457 6.18569,3.51361 7.54639,5.2771 1.36065,1.76352 2.04099,3.92538 2.04101,6.48559 z`})]),createBaseVNode(`g`,{id:`flowRoot5902-7-5`,style:{"font-style":`normal`,"font-variant":`normal`,"font-weight":`bold`,"font-stretch":`normal`,"font-size":`55px`,"line-height":`125%`,"font-family":`'Open Sans'`,"-inkscape-font-specification":`'Open Sans Bold'`,"letter-spacing":`-3.45999861px`,"word-spacing":`0px`,display:`inline`,fill:`#ffffff`,"fill-opacity":`1`,stroke:`none`},transform:`matrix(0.43849858,-0.00161469,0.00161469,0.43849858,317.47869,20.439182)`},[createBaseVNode(`g`,{transform:`matrix(0.99999322,0.00368229,-0.00368229,0.99999322,0,0)`,style:{"font-style":`normal`,"font-weight":`normal`,"font-size":`94.63018036px`,"line-height":`125%`,"font-family":`sans-serif`,"letter-spacing":`0px`,"word-spacing":`0px`,fill:`#ffffff`,"fill-opacity":`1`,stroke:`none`,"stroke-width":`1px`,"stroke-linecap":`butt`,"stroke-linejoin":`miter`,"stroke-opacity":`1`},id:`text4455`},[createBaseVNode(`path`,{d:`m 607.02483,962.46092 q 0,4.62062 -1.61722,9.05641 -1.61721,4.38958 -4.62061,7.39298 -4.11235,4.06614 -9.19502,6.14542 -5.03647,2.07927 -12.56807,2.07927 l -11.04327,0 0,22.41 -17.74316,0 0,-68.80096 29.20228,0 q 6.56127,0 11.04327,1.15515 4.5282,1.10895 7.99366,3.37305 4.15856,2.72616 6.33024,6.97713 2.2179,4.25096 2.2179,10.21155 z m -18.34384,0.41586 q 0,-2.91099 -1.57101,-4.99026 -1.57101,-2.12549 -3.65028,-2.9572 -2.77237,-1.10895 -5.40612,-1.20136 -2.63375,-0.13862 -7.02334,-0.13862 l -3.0496,0 0,20.60794 5.08267,0 q 4.52821,0 7.43919,-0.55447 2.9572,-0.55447 4.94406,-2.21789 1.70963,-1.4786 2.44893,-3.51167 0.7855,-2.07928 0.7855,-5.03647 z`,style:{"font-style":`normal`,"font-variant":`normal`,"font-weight":`bold`,"font-stretch":`normal`,"font-size":`94.63018036px`,"line-height":`125%`,"font-family":`'Open Sans Extrabold'`,"-inkscape-font-specification":`'Open Sans Extrabold, Bold'`,"text-align":`start`,"writing-mode":`lr-tb`,"text-anchor":`start`,fill:`#ffffff`,"fill-opacity":`1`},id:`path4527`,"inkscape:connector-curvature":`0`})]),createBaseVNode(`path`,{transform:`matrix(0.99999322,0.00368229,-0.00368229,0.99999322,0,0)`,style:{fill:`none`,"fill-opacity":`1`,stroke:`#000000`,"stroke-width":`5.69782162`,"stroke-miterlimit":`4`,"stroke-dasharray":`none`,"stroke-opacity":`1`},d:`m 28.554777,1230.2663 c -137.847287,0 -270.048717,-54.7596 -367.521467,-152.2324 -97.47276,-97.47273 -152.23238,-229.67416 -152.23238,-367.52145 0,-137.84729 54.75963,-270.04871 152.23238,-367.52146 97.47275,-97.47276 229.67418,-152.23238 367.521467,-152.23238 137.847293,0 270.048713,54.75962 367.521463,152.23238 97.47275,97.47275 152.23238,229.67417 152.23238,367.52146 0,137.84729 -54.75962,270.04871 -152.23238,367.52145 -97.47275,97.4728 -229.67417,152.2324 -367.521463,152.2324`,id:`text_path`,"inkscape:connector-curvature":`0`,"sodipodi:nodetypes":`csssssssc`,"inkscape:label":`#path4459`})])])],-1),createBaseVNode(`g`,{ref_key:`layer7Ref`,ref:layer7Ref,"inkscape:groupmode":`layer`,id:`layer7`,class:`layer7`,"inkscape:label":`new2`},[createBaseVNode(`g`,{ref_key:`revNeedleRef`,ref:revNeedleRef,id:`revneedle`,"inkscape:label":`#g4147`},[..._cache[5]||=[createBaseVNode(`rect`,{y:`7`,x:`322.44037`,height:`72`,width:`12`,id:`rect4625`,class:`rev-needle-rect`},null,-1)]],512)],512),createBaseVNode(`g`,{ref_key:`layer4Ref`,ref:layer4Ref,"inkscape:groupmode":`layer`,id:`layer4`,class:`layer4`,"inkscape:label":`Icons bottom right`},[createBaseVNode(`path`,{ref_key:`icoIndicatorLeftOffRef`,ref:icoIndicatorLeftOffRef,id:`ico_indicatorl`,class:`ico-indicator-l`,d:`m 386.4512,577.16251 0.0556,17.08797 15.45962,0.24613 0,10.03868 0,10.03869 -15.45962,0.24608 -0.0556,17.08797 -35.33627,-27.37274 z`,"inkscape:connector-curvature":`0`,"sodipodi:nodetypes":`ccccccccc`,"inkscape:label":`#rect4655-9`},null,512),createBaseVNode(`path`,{ref_key:`icoIndicatorRightOffRef`,ref:icoIndicatorRightOffRef,id:`ico_indicatorr`,class:`ico-indicator-r`,d:`m 442.9256,554.57416 -0.0557,17.08798 -15.45965,0.24611 0,10.03869 0,10.03869 15.45965,0.24608 0.0557,17.08796 35.33627,-27.37273 z`,"inkscape:connector-curvature":`0`,"sodipodi:nodetypes":`ccccccccc`,"inkscape:label":`#rect4655-9-3`},null,512),createBaseVNode(`g`,{ref_key:`icoLightsOffRef`,ref:icoLightsOffRef,id:`ico_lights`,class:`ico-lights`,"inkscape:label":`#g4122`,transform:`translate(-12,-2)`},[..._cache[6]||=[createBaseVNode(`path`,{"inkscape:connector-curvature":`0`,id:`rect5824`,class:`light-source`,d:`m 611.67051,352.21188 19.61837,0 c 0,0 13.56687,7.61647 13.56687,22.35122 0,14.73475 -13.56687,21.08238 -13.56687,21.08238 l -19.61837,0 c 0,0 -1.90879,-4.49141 -1.95206,-21.08238 -0.0435,-16.59097 1.95206,-22.35122 1.95206,-22.35122 z`},null,-1),createBaseVNode(`path`,{class:`light-dash`,"inkscape:connector-curvature":`0`,d:`m 600.68152,355.88611 -13.21963,0`},null,-1),createBaseVNode(`path`,{class:`light-dash`,"inkscape:connector-curvature":`0`,d:`m 600.68152,365.4103 -13.21963,0`},null,-1),createBaseVNode(`path`,{class:`light-dash`,"inkscape:connector-curvature":`0`,d:`m 600.68152,374.58946 -13.21963,0`},null,-1),createBaseVNode(`path`,{class:`light-dash`,"inkscape:connector-curvature":`0`,d:`m 600.68152,384.11369 -13.21963,0`},null,-1),createBaseVNode(`path`,{class:`light-dash`,"inkscape:connector-curvature":`0`,d:`m 600.68152,393.43089 -13.21963,0`},null,-1)]],512),createBaseVNode(`g`,{ref_key:`icoABSOffRef`,ref:icoABSOffRef,id:`ico_abs`,class:`ico-abs-off`,"inkscape:label":`#g4111`},[..._cache[7]||=[createBaseVNode(`path`,{transform:`matrix(0.43849858,-0.00161469,0.00161469,0.43849858,260.26675,95.346428)`,id:`path4551dd`,class:`main`,d:`m 631.44636,979.59082 c 0,36.31878 -29.44217,65.76098 -65.76094,65.76098 -36.31876,0 -65.76093,-29.4422 -65.76093,-65.76098 0,-36.31876 29.44217,-65.76093 65.76093,-65.76093 36.31877,0 65.76094,29.44217 65.76094,65.76093 z`,"inkscape:connector-curvature":`0`},null,-1),createBaseVNode(`path`,{"inkscape:connector-curvature":`0`,id:`path4551-7`,class:`curve-l`,d:`m 488.18221,555.99526 c -10.19731,-6.9315 -16.91369,-18.60946 -16.96251,-31.87062 -0.0478,-13.00297 6.32573,-24.53106 16.1388,-31.5801`},null,-1),createBaseVNode(`path`,{"inkscape:connector-curvature":`0`,id:`path4551-7-4`,class:`curve-r`,d:`m 531.48996,555.83579 c 10.14597,-7.00643 16.77617,-18.73351 16.72734,-31.99467 -0.0478,-13.00299 -6.50623,-24.48382 -16.37094,-31.4604`},null,-1),createBaseVNode(`path`,{"inkscape:connector-curvature":`0`,id:`path3978`,class:`text-a`,d:`m 501.24227,531.46506 -1.26336,-4.09346 -6.27665,0.0231 -1.23317,4.10266 -3.93322,0.0145 6.01281,-17.30965 4.46313,-0.0164 6.16367,17.26482 z m -2.14606,-7.15204 c -1.16774,-3.70913 -1.82512,-5.8068 -1.97214,-6.29303 -0.14704,-0.48619 -0.25248,-0.87049 -0.31632,-1.1529 -0.25538,1.00586 -0.98812,3.49334 -2.19823,7.46246 z`},null,-1),createBaseVNode(`path`,{"inkscape:connector-curvature":`0`,id:`path3980`,class:`text-b`,d:`m 505.7499,514.23161 5.35812,-0.0197 c 2.44157,-0.009 4.21514,0.33189 5.32074,1.02261 1.10557,0.69074 1.66115,1.79369 1.66675,3.30887 0.004,1.02845 -0.23453,1.87329 -0.71491,2.53453 -0.4804,0.66124 -1.12074,1.06007 -1.92101,1.19647 l 4.3e-4,0.11776 c 1.09214,0.23936 1.88085,0.69181 2.36614,1.35733 0.48526,0.66554 0.72994,1.55178 0.73403,2.65873 0.006,1.57015 -0.55694,2.79695 -1.68812,3.6804 -1.1312,0.88345 -2.67028,1.32876 -4.61725,1.33593 l -6.44152,0.0237 z m 3.67569,6.80491 2.1197,-0.008 c 0.98919,-0.004 1.705,-0.15935 2.14745,-0.46718 0.44242,-0.3078 0.66234,-0.81498 0.65975,-1.52156 -0.002,-0.65945 -0.24559,-1.13157 -0.72946,-1.41635 -0.48388,-0.28476 -1.24789,-0.42523 -2.29202,-0.42139 l -1.91951,0.007 z m 0.0107,2.89692 0.0165,4.48668 2.37878,-0.009 c 1.00488,-0.004 1.74606,-0.19878 2.22355,-0.58523 0.47747,-0.38644 0.71474,-0.97613 0.71184,-1.76906 -0.005,-1.42882 -1.0285,-2.13948 -3.06968,-2.13197 z`},null,-1),createBaseVNode(`path`,{"inkscape:connector-curvature":`0`,id:`path3982`,class:`text-s`,d:`m 530.64514,526.57565 c 0.006,1.55445 -0.54914,2.78122 -1.66456,3.68032 -1.11544,0.89909 -2.6702,1.35231 -4.66427,1.35965 -1.83708,0.007 -3.46345,-0.33266 -4.87912,-1.01833 l -0.0125,-3.39151 c 1.16382,0.51387 2.14846,0.87531 2.95395,1.08431 0.80547,0.20901 1.54187,0.31229 2.20918,0.30983 0.80077,-0.003 1.41452,-0.1583 1.84127,-0.46605 0.42673,-0.30776 0.63898,-0.76389 0.63676,-1.3684 -10e-4,-0.33757 -0.0966,-0.63752 -0.28594,-0.89982 -0.18939,-0.2623 -0.46706,-0.51447 -0.83301,-0.75651 -0.36596,-0.24202 -1.11125,-0.62789 -2.23586,-1.15761 -1.05382,-0.49071 -1.84457,-0.96278 -2.37224,-1.41619 -0.52768,-0.4534 -0.94964,-0.98177 -1.2659,-1.58513 -0.31625,-0.60334 -0.47587,-1.30933 -0.47884,-2.11796 -0.006,-1.52303 0.50616,-2.72216 1.53533,-3.59741 1.02915,-0.87522 2.45441,-1.31619 4.27579,-1.32291 0.89497,-0.003 1.74913,0.0996 2.56247,0.30852 0.81332,0.209 1.66426,0.50419 2.55282,0.8856 l -1.16716,2.84237 c -0.91993,-0.37344 -1.68046,-0.63364 -2.28158,-0.7806 -0.60114,-0.14694 -1.19218,-0.21935 -1.77312,-0.21723 -0.69088,0.003 -1.2202,0.16545 -1.588,0.48868 -0.3678,0.32325 -0.55075,0.74394 -0.54884,1.26208 10e-4,0.32189 0.0768,0.60228 0.22685,0.84116 0.15004,0.23892 0.38838,0.46963 0.71501,0.69217 0.32663,0.22256 1.09944,0.62206 2.31845,1.19853 1.61222,0.76345 2.71809,1.53072 3.3176,2.30181 0.59949,0.77111 0.90131,1.71798 0.90545,2.84063 z`},null,-1)]],512),createBaseVNode(`g`,{ref_key:`icoHandBrakeOffRef`,ref:icoHandBrakeOffRef,class:`ico-handbrake-off`,id:`ico_handbrake`,"inkscape:label":`#g4115`,transform:`translate(-3.5925881e-6,-2.0000007)`},[..._cache[8]||=[createBaseVNode(`path`,{transform:`matrix(0.43850147,2.6141077e-4,-2.6141077e-4,0.43850147,320.9902,18.916914)`,id:`path4551-2-74-7`,class:`main`,d:`m 631.44636,979.59082 c 0,36.31878 -29.44217,65.76098 -65.76094,65.76098 -36.31876,0 -65.76093,-29.4422 -65.76093,-65.76098 0,-36.31876 29.44217,-65.76093 65.76093,-65.76093 36.31877,0 65.76094,29.44217 65.76094,65.76093 z`,"inkscape:connector-curvature":`0`},null,-1),createBaseVNode(`path`,{class:`curve-l`,id:`path4551-7-7-0-4`,"inkscape:connector-curvature":`0`,d:`m 546.9327,480.53664 c -10.16748,-6.97507 -16.83385,-18.68164 -16.82592,-31.94291 0.008,-13.00305 6.43054,-24.50375 16.27369,-31.51076`},null,-1),createBaseVNode(`path`,{"inkscape:connector-curvature":`0`,id:`path4551-7-4-7-9-0`,class:`curve-r`,d:`m 590.24076,480.56245 c 10.17587,-6.96293 16.8562,-18.66157 16.86414,-31.92282 0.008,-13.00303 -6.40141,-24.51142 -16.23624,-31.5301`},null,-1),createBaseVNode(`g`,{class:`text-p`,id:`text4055-4-9`},[createBaseVNode(`path`,{"inkscape:connector-curvature":`0`,id:`path3269-4`,d:`m 566.88168,447.27286 2.26429,0 c 2.11628,2e-5 3.6998,-0.41806 4.75057,-1.25424 1.05073,-0.83614 1.57611,-2.05338 1.57612,-3.65172 -10e-6,-1.6131 -0.44029,-2.80444 -1.32083,-3.57403 -0.88058,-0.76954 -2.26061,-1.15432 -4.1401,-1.15435 l -3.13005,0 z m 15.53925,-5.15015 c -3e-5,3.49265 -1.09147,6.16392 -3.27434,8.01381 -2.18292,1.84993 -5.28707,2.77488 -9.31245,2.77487 l -2.95246,0 0,11.54344 -6.88167,0 0,-32.45483 10.3669,0 c 3.93659,3e-5 6.92975,0.84729 8.97947,2.54177 2.04967,1.69455 3.07452,4.22153 3.07455,7.58094 z`})],-1)]],512),createBaseVNode(`g`,{ref_key:`oilTempIcoOffRef`,ref:oilTempIcoOffRef,style:{display:`inline`},id:`ico_temp`,class:`ico-temp`,transform:`matrix(0.82879177,0,0,0.82879177,40.706638,69.281349)`,"inkscape:label":`#g4374`},[..._cache[9]||=[createBaseVNode(`path`,{"inkscape:connector-curvature":`0`,id:`path4347`,class:`path1`,d:`m 199.61025,285.93078 2e-5,37.83129`},null,-1),createBaseVNode(`path`,{"inkscape:connector-curvature":`0`,id:`path4347-5`,class:`path2`,d:`m 208.85791,292.09588 -7.00577,0`},null,-1),createBaseVNode(`path`,{"inkscape:connector-curvature":`0`,id:`path4347-5-4`,class:`path3`,d:`m 208.8579,301.06329 -7.00578,0`},null,-1),createBaseVNode(`path`,{"inkscape:connector-curvature":`0`,id:`path4347-5-3`,class:`path4`,d:`m 208.85793,309.75049 -7.00583,-1e-5`},null,-1),createBaseVNode(`circle`,{transform:`matrix(0.72059621,0,0,0.72059621,-1146.435,-0.73321691)`,id:`path4392`,class:`path5`,cx:`1867.8225`,cy:`454.9176`,r:`14.849242`,d:`m 1882.6718,454.9176 c 0,8.20101 -6.6483,14.84924 -14.8493,14.84924 -8.201,0 -14.8492,-6.64823 -14.8492,-14.84924 0,-8.20101 6.6482,-14.84924 14.8492,-14.84924 8.201,0 14.8493,6.64823 14.8493,14.84924 z`},null,-1),createBaseVNode(`path`,{"inkscape:connector-curvature":`0`,id:`path4347-5-1-2`,class:`path6`,d:`m 183.69241,332.71741 -7.00578,0`},null,-1),createBaseVNode(`path`,{"inkscape:connector-curvature":`0`,id:`path4347-5-1-2-3`,class:`path7`,d:`m 223.32319,343.08941 -46.63658,-10e-6`},null,-1),createBaseVNode(`path`,{"inkscape:connector-curvature":`0`,id:`path4347-5-1-2-34`,class:`path8`,d:`m 222.33239,332.7174 -7.00578,0`},null,-1)]],512),createBaseVNode(`g`,{ref_key:`fuelWarnIcoOffRef`,ref:fuelWarnIcoOffRef,id:`ico_fuel`,class:`ico-fuel`,transform:`matrix(0.88747678,0,0,0.88747678,64.601263,56.302973)`,"inkscape:label":`#g4368`},[..._cache[10]||=[createBaseVNode(`rect`,{id:`rect4466`,class:`rect1`,y:`284.07593`,x:`420.99237`,height:`38.905876`,width:`22.650679`},null,-1),createBaseVNode(`rect`,{id:`rect4466-1`,class:`rect2`,y:`298.80991`,x:`420.99237`,height:`24.171896`,width:`22.650679`},null,-1),createBaseVNode(`path`,{"inkscape:connector-curvature":`0`,id:`path4347-5-1-2-3-3`,class:`path1`,d:`m 448.00445,330.93084 -30.96928,0`},null,-1),createBaseVNode(`path`,{"inkscape:connector-curvature":`0`,id:`path4347-5-1-2-3-3-8`,class:`path2`,d:`m 460.25266,299.90863 0.0166,18.02062 c 0,0 -0.41583,2.18743 -4.92393,2.16693 -4.50811,-0.0205 -4.80496,-2.16693 -4.80496,-2.16693 l 0.0579,-17.71243 -7.25174,-0.0941`},null,-1)]],512)],512),createBaseVNode(`g`,{ref_key:`layer10Ref`,ref:layer10Ref,"inkscape:groupmode":`layer`,id:`layer10`,class:`layer10`,"inkscape:label":`icons bottom right activated`},[createBaseVNode(`path`,{ref_key:`icoIndicatorLeftOnRef`,ref:icoIndicatorLeftOnRef,class:`ico-indicator-l-on`,d:`m 386.4512,577.16251 0.0556,17.08797 15.45962,0.24613 0,10.03868 0,10.03869 -15.45962,0.24608 -0.0556,17.08797 -35.33627,-27.37274 z`,id:`ico_indicatorl_on`,"inkscape:connector-curvature":`0`,"inkscape:label":`#rect4655-9`},null,512),createBaseVNode(`path`,{ref_key:`icoIndicatorRightOnRef`,ref:icoIndicatorRightOnRef,id:`ico_indicatorr_on`,class:`ico-indicator-r-on`,d:`m 442.9256,554.57416 -0.0557,17.08798 -15.45965,0.24611 0,10.03869 0,10.03869 15.45965,0.24608 0.0557,17.08796 35.33627,-27.37273 z`,"inkscape:connector-curvature":`0`,"inkscape:label":`#rect4655-9-3`},null,512),createBaseVNode(`g`,{ref_key:`icoLightsOnRef`,ref:icoLightsOnRef,id:`ico_lights_on`,class:`ico-lights-on`,"inkscape:label":`#g4122`,transform:`translate(-12,-2.0000028)`},[..._cache[11]||=[createBaseVNode(`path`,{"inkscape:connector-curvature":`0`,id:`rect5824-4`,class:`path1`,d:`m 611.67051,352.21188 19.61837,0 c 0,0 13.56687,7.61647 13.56687,22.35122 0,14.73475 -13.56687,21.08238 -13.56687,21.08238 l -19.61837,0 c 0,0 -1.90879,-4.49141 -1.95206,-21.08238 -0.0435,-16.59097 1.95206,-22.35122 1.95206,-22.35122 z`},null,-1),createBaseVNode(`path`,{"inkscape:connector-curvature":`0`,id:`path4347-5-1-2-3-1-1`,class:`path2`,d:`m 600.68152,355.88611 -13.21963,0`},null,-1),createBaseVNode(`path`,{"inkscape:connector-curvature":`0`,id:`path4347-5-1-2-3-1-9-20`,class:`path3`,d:`m 600.68152,365.4103 -13.21963,0`},null,-1),createBaseVNode(`path`,{"inkscape:connector-curvature":`0`,id:`path4347-5-1-2-3-1-8-0`,class:`path4`,d:`m 600.68152,374.58946 -13.21963,0`},null,-1),createBaseVNode(`path`,{"inkscape:connector-curvature":`0`,id:`path4347-5-1-2-3-1-9-6-1`,class:`path5`,d:`m 600.68152,384.11369 -13.21963,0`},null,-1),createBaseVNode(`path`,{"inkscape:connector-curvature":`0`,id:`path4347-5-1-2-3-1-9-6-5-4`,class:`path6`,d:`m 600.68152,393.43089 -13.21963,0`},null,-1)]],512),createBaseVNode(`g`,{ref_key:`icoABSOnRef`,ref:icoABSOnRef,transform:`translate(0,-2.8038025e-6)`,id:`ico_abs_on`,class:`ico-abs-on`,"inkscape:label":`#g4106`},[..._cache[12]||=[createBaseVNode(`path`,{id:`path4551-0`,class:`path1`,"inkscape:connector-curvature":`0`,transform:`matrix(0.43849858,-0.00161469,0.00161469,0.43849858,260.26675,95.34643)`,d:`m 631.44636,979.59082 c 0,36.31878 -29.44217,65.76098 -65.76094,65.76098 -36.31876,0 -65.76093,-29.4422 -65.76093,-65.76098 0,-36.31876 29.44217,-65.76093 65.76093,-65.76093 36.31877,0 65.76094,29.44217 65.76094,65.76093 z`},null,-1),createBaseVNode(`path`,{"inkscape:connector-curvature":`0`,id:`path4551-7-717`,class:`path2`,d:`m 488.18221,555.99526 c -10.19731,-6.9315 -16.91369,-18.60946 -16.96251,-31.87062 -0.0478,-13.00297 6.32573,-24.53106 16.1388,-31.5801`},null,-1),createBaseVNode(`path`,{"inkscape:connector-curvature":`0`,id:`path4551-7-4-77`,class:`path3`,d:`m 531.48996,555.83579 c 10.14597,-7.00643 16.77617,-18.73351 16.72734,-31.99467 -0.0478,-13.00299 -6.50623,-24.48382 -16.37094,-31.4604`},null,-1),createBaseVNode(`g`,{id:`flowRoot5902-7`,class:`text-path`,transform:`matrix(0.43849858,-0.00161469,0.00161469,0.43849858,259.17408,93.335)`},[createBaseVNode(`path`,{id:`path3978-3`,class:`text-path1`,"inkscape:connector-curvature":`0`,d:`m 548.35205,1001.1788 -2.84668,-9.34567 -14.31396,0 -2.84668,9.34567 -8.96973,0 13.85742,-39.4238 10.17822,0 13.91114,39.4238 z m -4.83398,-16.32809 c -2.63186,-8.4684 -4.11339,-13.25762 -4.44458,-14.36768 -0.33124,-1.10999 -0.56846,-1.98727 -0.71167,-2.63183 -0.59084,2.29169 -2.28274,7.95819 -5.07569,16.99951 z`}),createBaseVNode(`path`,{id:`path3980-3`,class:`text-path2`,"inkscape:connector-curvature":`0`,d:`m 558.77633,961.91614 12.21924,0 c 5.56801,4e-5 9.60975,0.79227 12.12524,2.37671 2.51543,1.5845 3.77316,4.10444 3.77319,7.55981 -3e-5,2.3454 -0.55056,4.27004 -1.65161,5.77393 -1.1011,1.50392 -2.56472,2.40806 -4.39087,2.7124 l 0,0.26855 c 2.48858,0.55504 4.28342,1.59345 5.38453,3.11524 1.10104,1.52182 1.65157,3.54493 1.65161,6.06933 -4e-5,3.58074 -1.29357,6.37371 -3.88062,8.37891 -2.5871,2.00518 -6.10069,3.00778 -10.54077,3.00778 l -14.68994,0 z m 8.32519,15.54931 4.83399,0 c 2.25584,3e-5 3.88954,-0.34909 4.90112,-1.04736 1.01153,-0.69822 1.51731,-1.853 1.51734,-3.46436 -3e-5,-1.50387 -0.55057,-2.58257 -1.65162,-3.23608 -1.10109,-0.65345 -2.84222,-0.98019 -5.22338,-0.98022 l -4.37745,0 z m 0,6.60645 0,10.23193 5.42481,0 c 2.29164,1e-5 3.98354,-0.43863 5.07568,-1.31592 1.0921,-0.87727 1.63816,-2.22004 1.63819,-4.02832 -3e-5,-3.25844 -2.3275,-4.88767 -6.98243,-4.88769 z`}),createBaseVNode(`path`,{id:`path3982-5`,class:`text-path3`,"inkscape:connector-curvature":`0`,d:`m 615.44572,990.27551 c -2e-5,3.54493 -1.27566,6.3379 -3.8269,8.37891 -2.55129,2.04098 -6.10069,3.06148 -10.64819,3.06148 -4.18947,0 -7.89552,-0.7877 -11.11817,-2.36324 l 0,-7.73437 c 2.64974,1.18164 4.89217,2.01416 6.7273,2.49755 1.83511,0.48341 3.51358,0.72511 5.0354,0.7251 1.82615,10e-6 3.22711,-0.34911 4.20288,-1.04736 0.97573,-0.69824 1.4636,-1.73665 1.46362,-3.11524 -2e-5,-0.76984 -0.21486,-1.45466 -0.64453,-2.05444 -0.42971,-0.59976 -1.06081,-1.17715 -1.89331,-1.73218 -0.83254,-0.555 -2.5289,-1.44123 -5.08911,-2.65869 -2.3991,-1.12791 -4.19841,-2.21108 -5.39795,-3.24951 -1.19955,-1.03839 -2.15739,-2.24689 -2.87354,-3.62549 -0.71614,-1.37855 -1.07422,-2.98988 -1.07421,-4.83398 -10e-6,-3.47328 1.17716,-6.20358 3.53149,-8.19092 2.35432,-1.98727 5.6083,-2.98092 9.76196,-2.98096 2.041,4e-5 3.98802,0.24174 5.84107,0.7251 1.853,0.48344 3.79107,1.16377 5.81421,2.04102 l -2.68555,6.47216 c -2.09475,-0.85934 -3.82693,-1.45911 -5.19653,-1.79931 -1.36965,-0.34014 -2.7169,-0.51022 -4.04175,-0.51026 -1.57554,4e-5 -2.78403,0.36706 -3.62549,1.10108 -0.84148,0.73408 -1.26222,1.69192 -1.26221,2.87353 -10e-6,0.73408 0.17008,1.37413 0.51026,1.92017 0.34015,0.54609 0.88174,1.07424 1.62475,1.58447 0.74299,0.51028 2.50202,1.42784 5.2771,2.75269 3.67023,1.75457 6.18569,3.51361 7.54639,5.2771 1.36065,1.76352 2.04099,3.92538 2.04101,6.48559 z`})],-1)]],512),createBaseVNode(`g`,{ref_key:`icoHandBrakeOnRef`,ref:icoHandBrakeOnRef,id:`ico_handbrake_on`,class:`ico-handbrake-on`,"inkscape:label":`#g4115`,transform:`translate(-3.5925881e-6,-2.0000007)`},[..._cache[13]||=[createBaseVNode(`path`,{id:`path4551-2-74`,class:`path1`,transform:`matrix(0.43850147,2.6141077e-4,-2.6141077e-4,0.43850147,320.9902,18.916914)`,d:`m 631.44636,979.59082 c 0,36.31878 -29.44217,65.76098 -65.76094,65.76098 -36.31876,0 -65.76093,-29.4422 -65.76093,-65.76098 0,-36.31876 29.44217,-65.76093 65.76093,-65.76093 36.31877,0 65.76094,29.44217 65.76094,65.76093 z`,"inkscape:connector-curvature":`0`},null,-1),createBaseVNode(`path`,{"inkscape:connector-curvature":`0`,id:`path4551-7-7-0`,class:`path2`,d:`m 546.9327,480.53664 c -10.16748,-6.97507 -16.83385,-18.68164 -16.82592,-31.94291 0.008,-13.00305 6.43054,-24.50375 16.27369,-31.51076`},null,-1),createBaseVNode(`path`,{"inkscape:connector-curvature":`0`,id:`path4551-7-4-7-9`,class:`path3`,d:`m 590.24076,480.56245 c 10.17587,-6.96293 16.8562,-18.66157 16.86414,-31.92282 0.008,-13.00303 -6.40141,-24.51142 -16.23624,-31.5301`},null,-1),createBaseVNode(`g`,{class:`text-p`,id:`text4055-4`},[createBaseVNode(`path`,{d:`m 566.88168,447.27286 2.26429,0 c 2.11628,2e-5 3.6998,-0.41806 4.75057,-1.25424 1.05073,-0.83614 1.57611,-2.05338 1.57612,-3.65172 -10e-6,-1.6131 -0.44029,-2.80444 -1.32083,-3.57403 -0.88058,-0.76954 -2.26061,-1.15432 -4.1401,-1.15435 l -3.13005,0 z m 15.53925,-5.15015 c -3e-5,3.49265 -1.09147,6.16392 -3.27434,8.01381 -2.18292,1.84993 -5.28707,2.77488 -9.31245,2.77487 l -2.95246,0 0,11.54344 -6.88167,0 0,-32.45483 10.3669,0 c 3.93659,3e-5 6.92975,0.84729 8.97947,2.54177 2.04967,1.69455 3.07452,4.22153 3.07455,7.58094 z`,id:`path3269`,"inkscape:connector-curvature":`0`})],-1)]],512),createBaseVNode(`g`,{ref_key:`oilTempIcoOnRef`,ref:oilTempIcoOnRef,id:`ico_temp_on`,class:`ico-temp-on`,transform:`matrix(0.82879177,0,0,0.82879177,40.706638,69.281349)`,"inkscape:label":`#g4374`},[..._cache[14]||=[createBaseVNode(`path`,{"inkscape:connector-curvature":`0`,id:`path4347-7`,class:`path1`,d:`m 199.61025,285.93078 2e-5,37.83129`},null,-1),createBaseVNode(`path`,{"inkscape:connector-curvature":`0`,id:`path4347-5-40`,class:`path2`,d:`m 208.85791,292.09588 -7.00577,0`},null,-1),createBaseVNode(`path`,{"inkscape:connector-curvature":`0`,id:`path4347-5-4-9`,class:`path3`,d:`m 208.8579,301.06329 -7.00578,0`},null,-1),createBaseVNode(`path`,{"inkscape:connector-curvature":`0`,id:`path4347-5-3-4`,class:`path4`,d:`m 208.85793,309.75049 -7.00583,-1e-5`},null,-1),createBaseVNode(`circle`,{id:`path4392-8`,class:`circle1`,transform:`matrix(0.72059621,0,0,0.72059621,-1146.435,-0.73321691)`,cx:`1867.8225`,cy:`454.9176`,r:`14.849242`,d:`m 1882.6718,454.9176 c 0,8.20101 -6.6483,14.84924 -14.8493,14.84924 -8.201,0 -14.8492,-6.64823 -14.8492,-14.84924 0,-8.20101 6.6482,-14.84924 14.8492,-14.84924 8.201,0 14.8493,6.64823 14.8493,14.84924 z`},null,-1),createBaseVNode(`path`,{"inkscape:connector-curvature":`0`,id:`path4347-5-1-2-8`,class:`path5`,d:`m 183.69241,332.71741 -7.00578,0`},null,-1),createBaseVNode(`path`,{"inkscape:connector-curvature":`0`,id:`path4347-5-1-2-3-2`,class:`path6`,d:`m 223.32319,343.08941 -46.63658,-10e-6`},null,-1),createBaseVNode(`path`,{"inkscape:connector-curvature":`0`,id:`path4347-5-1-2-34-4`,class:`path7`,d:`m 222.33239,332.7174 -7.00578,0`},null,-1)]],512),createBaseVNode(`g`,{ref_key:`fuelWarnIcoOnRef`,ref:fuelWarnIcoOnRef,id:`ico_fuel_on`,class:`ico-fuel-on`,transform:`matrix(0.88747678,0,0,0.88747678,64.601263,56.302973)`,"inkscape:label":`#g4368-5`},[..._cache[15]||=[createBaseVNode(`rect`,{id:`rect4466-5`,class:`rect1`,y:`284.07593`,x:`420.99237`,height:`38.905876`,width:`22.650679`},null,-1),createBaseVNode(`rect`,{id:`rect4466-1-1`,class:`rect2`,y:`298.80991`,x:`420.99237`,height:`24.171896`,width:`22.650679`},null,-1),createBaseVNode(`path`,{"inkscape:connector-curvature":`0`,id:`path4347-5-1-2-3-3-7`,class:`path1`,d:`m 448.00445,330.93084 -30.96928,0`},null,-1),createBaseVNode(`path`,{"inkscape:connector-curvature":`0`,id:`path4347-5-1-2-3-3-8-1`,class:`path2`,d:`m 460.25266,299.90863 0.0166,18.02062 c 0,0 -0.41583,2.18743 -4.92393,2.16693 -4.50811,-0.0205 -4.80496,-2.16693 -4.80496,-2.16693 l 0.0579,-17.71243 -7.25174,-0.0941`},null,-1)]],512)],512),createBaseVNode(`g`,{ref_key:`layer12Ref`,ref:layer12Ref,"inkscape:groupmode":`layer`,id:`layer12`,class:`layer12`,"inkscape:label":`icons bottom right 2`},[createBaseVNode(`g`,{ref_key:`icoLightsHighRef`,ref:icoLightsHighRef,id:`ico_lights_high`,class:`ico-lights-high`,"inkscape:label":`#g4122`,transform:`translate(-12.000003,-2.0000028)`},[..._cache[16]||=[createBaseVNode(`path`,{"inkscape:connector-curvature":`0`,id:`rect5824-4-9`,class:`path1`,d:`m 611.67051,352.21188 19.61837,0 c 0,0 13.56687,7.61647 13.56687,22.35122 0,14.73475 -13.56687,21.08238 -13.56687,21.08238 l -19.61837,0 c 0,0 -1.90879,-4.49141 -1.95206,-21.08238 -0.0435,-16.59097 1.95206,-22.35122 1.95206,-22.35122 z`},null,-1),createBaseVNode(`path`,{"inkscape:connector-curvature":`0`,id:`path4347-5-1-2-3-1-1-8`,class:`path2`,d:`m 600.68152,355.88611 -13.21963,0`},null,-1),createBaseVNode(`path`,{"inkscape:connector-curvature":`0`,id:`path4347-5-1-2-3-1-9-20-1`,class:`path3`,d:`m 600.68152,365.4103 -13.21963,0`},null,-1),createBaseVNode(`path`,{"inkscape:connector-curvature":`0`,id:`path4347-5-1-2-3-1-8-0-8`,class:`path4`,d:`m 600.68152,374.58946 -13.21963,0`},null,-1),createBaseVNode(`path`,{"inkscape:connector-curvature":`0`,id:`path4347-5-1-2-3-1-9-6-1-2`,class:`path5`,d:`m 600.68152,384.11369 -13.21963,0`},null,-1),createBaseVNode(`path`,{"inkscape:connector-curvature":`0`,id:`path4347-5-1-2-3-1-9-6-5-4-6`,class:`path6`,d:`m 600.68152,393.43089 -13.21963,0`},null,-1)]],512)],512),createBaseVNode(`g`,{ref_key:`tickLayerRef`,ref:tickLayerRef,id:`tickLayer`,class:`tick-layer`},[(openBlock(),createElementBlock(Fragment,null,renderList(maxRpmTexts,k=>createBaseVNode(`line`,{ref_for:!0,ref:el=>setTickRef(el,k),x1:`0`,y1:`0`,x2:`0`,y2:`0`,class:`tick-line`},null,512)),64))],512)]))}},tacho_default=__plugin_vue_export_helper_default(_sfc_main$179,[[`__scopeId`,`data-v-310c7a2d`]]),_hoisted_1$159={class:`tacho-container`},_sfc_main$178={__name:`app`,setup(__props){let{$game}=useLibStore(),tachoRef=ref(null),visible=ref(!1);ref(!1),onMounted(()=>{tachoRef.value.wireThroughUnitSystem((val,func)=>UiUnits[func](val)),$game.streams.add([`electrics`,`engineInfo`]),$game.events.on(`onStreamsUpdate`,onStreamsUpdate),$game.events.on(`VehicleChange`,onVehicleChange),$game.events.on(`VehicleFocusChanged`,onVehicleFocusChanged)}),onUnmounted(()=>{$game.streams.remove([`electrics`,`engineInfo`]),$game.events.off(`onStreamsUpdate`,onStreamsUpdate),$game.events.off(`VehicleChange`,onVehicleChange),$game.events.off(`VehicleFocusChanged`,onVehicleFocusChanged)});let _done=!1;function onStreamsUpdate(streams){tachoRef.value!==null&&(_done||=!0,tachoRef.value.update(streams)?visible.value||=!0:visible&&(visible.value=!1))}function onVehicleChange(){tachoRef.value!==null&&tachoRef.value.vehicleChanged()}function onVehicleFocusChanged(data){tachoRef.value!==null&&data.mode===!0&&tachoRef.value.vehicleChanged()}return(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$159,[createVNode(tacho_default,{ref_key:`tachoRef`,ref:tachoRef},null,512)]))}},app_default$26=__plugin_vue_export_helper_default(_sfc_main$178,[[`__scopeId`,`data-v-57c978c8`]]),_sfc_main$177={__name:`app`,setup(__props){let{$game}=useLibStore(),store$1=useTasksStore();provide(`animationSettings`,{animate:!0,animateOnMount:!1,animateOnMountIntervalDelay:.2,animateOnEmptyIntervalDelay:.1,animateOnEmpty:!0,animateNextTask:!0,successCallback:playAudio});function playAudio(){$game.lua.Engine.Audio.playOnce(`AudioGui`,`event:>UI>Career>Checkbox`)}return(_ctx,_cache)=>(openBlock(),createBlock(unref(TaskList_default),{header:unref(store$1).header,tasks:unref(store$1).tasks},null,8,[`header`,`tasks`]))}},app_default$27=_sfc_main$177,_hoisted_1$158={class:`pacenote`},_hoisted_2$131=[`id`],_hoisted_3$117=[`fill`,`stroke`],_hoisted_4$95=[`id`],_hoisted_5$82=[`fill`,`stroke`],_hoisted_6$68=[`fill`],_hoisted_7$59={class:`content`},_hoisted_8$49={class:`instruction`},_hoisted_9$43={key:0,class:`modifier`},_hoisted_10$36={key:1,class:`add-note`},_hoisted_11$32={key:0,class:`distance`},_sfc_main$176={__name:`PaceNote`,props:{note:{type:Object,required:!0,validator(value){return value.type===`empty`?!0:typeof value.type==`string`},default:()=>({type:`empty`,typeExt:null,turnModifier:null,background:{color:`var(--bng-cool-gray-600)`,strokeColor:`var(--bng-cool-gray-500)`,opacity:.6},isInto:!1,isLeft:!1,size:5,turnTypeValue:null,distance:null,additionalNote:{color:`#fff`,icon:null,text:null}})}},setup(__props){useCssVars(_ctx=>({v5d4f1806:props.note.size,v654d2548:backgroundColor.value,v7d5e0455:colorNoteIcon.value,v7d630d09:colorNoteText.value,v305678bf:colorDistance.value}));let bgId=uniqueId(``,`_`),props=__props,noteUrl=computed(()=>{if(props.note.typeExt)return props.note.typeExt;let assetPath=noteTypes[props.note.type];return assetPath?getAssetURL(assetPath):null}),backgroundColor=computed(()=>props.note.background&&props.note.background.color?props.note.background.color:`var(--bng-cool-gray-600)`),strokeColor=computed(()=>props.note.background&&props.note.background.strokeColor?props.note.background.strokeColor:`var(--bng-cool-gray-500)`),backgroundOpacity=computed(()=>props.note.background&&props.note.background.opacity?props.note.background.opacity:.6),colorNoteIcon=computed(()=>props.note.colorNoteIcon?props.note.colorNoteIcon:`#fff`),colorNoteText=computed(()=>props.note.colorNoteText?props.note.colorNoteText:`#fff`),intoColor=computed(()=>props.note.intoColor?props.note.intoColor:`#fff`),colorDistance=computed(()=>props.note.colorDistance?props.note.colorDistance:`#ececec`);return(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$158,[createBaseVNode(`div`,{class:`background`,style:normalizeStyle({opacity:backgroundOpacity.value})},[__props.note.isInto?(openBlock(),createElementBlock(`svg`,{key:1,id:`note_${unref(bgId)}`,style:{width:`var(--note-size)`,height:`var(--note-size)`},viewBox:`0 0 56 56`,fill:`none`,xmlns:`http://www.w3.org/2000/svg`},[createBaseVNode(`path`,{d:`M5 47.75H5.54967L5.71519 47.2258L11.3348 29.4304C11.6288 28.4994 11.6288 27.5006 11.3348 26.5696L5.95963 9.54823C5.82856 9.13317 5.7822 8.69601 5.8233 8.26269L6.25669 3.69314C6.41494 2.02457 7.81612 0.75 9.49217 0.75H51.4137C53.3423 0.75 54.8466 2.41974 54.6461 4.33788L49.631 52.3157C49.4572 53.9784 48.0504 55.238 46.3787 55.2278L4.46341 54.9706C2.52935 54.9587 1.03362 53.2707 1.25464 51.3493L1.66867 47.75H5Z`,fill:backgroundColor.value,stroke:strokeColor.value,"stroke-width":`1.5`},null,8,_hoisted_5$82),createBaseVNode(`path`,{d:`M4 11H1L6 28L1 45H4L9.5 28L4 11Z`,fill:intoColor.value},null,8,_hoisted_6$68)],8,_hoisted_4$95)):(openBlock(),createElementBlock(`svg`,{key:0,id:`note_${unref(bgId)}`,style:{width:`var(--note-size)`,height:`var(--note-size)`},viewBox:`0 0 56 56`,fill:`none`,xmlns:`http://www.w3.org/2000/svg`},[createBaseVNode(`path`,{d:`M9.45521 0.75H51.4137C53.3423 0.75 54.8466 2.41974 54.6461 4.33788L49.631 52.3157C49.4572 53.9784 48.0504 55.238 46.3787 55.2278L4.41965 54.9703C2.49833 54.9585 1.00656 53.2915 1.2074 51.3807L6.22301 3.66028C6.39689 2.00598 7.7918 0.75 9.45521 0.75Z`,fill:backgroundColor.value,stroke:strokeColor.value,"stroke-width":`1.5`},null,8,_hoisted_3$117)],8,_hoisted_2$131))],4),createBaseVNode(`div`,_hoisted_7$59,[createBaseVNode(`div`,_hoisted_8$49,[unref(icons)[__props.note.type]?(openBlock(),createBlock(unref(bngIcon_default),{key:0,class:normalizeClass([`note-icon`,{left:__props.note.isLeft}]),type:__props.note.type},null,8,[`type`,`class`])):__props.note.typeExt&¬eUrl.value?(openBlock(),createElementBlock(`div`,{key:1,class:normalizeClass([`note-icon svg-used`,[__props.note.type,{left:__props.note.isLeft}]]),style:normalizeStyle(noteUrl.value?{maskImage:`url(${noteUrl.value})`,WebkitMaskImage:`url(${noteUrl.value})`}:null)},null,6)):createCommentVNode(``,!0),__props.note.turnTypeValue?(openBlock(),createElementBlock(`div`,{key:2,class:normalizeClass([`turn-value`,{left:__props.note.isLeft,"is-into":__props.note.isInto,"text-2-chars":__props.note.turnTypeValue.length===2}])},toDisplayString(__props.note.turnTypeValue),3)):createCommentVNode(``,!0)]),__props.note.turnModifier?(openBlock(),createElementBlock(`div`,_hoisted_9$43,[createVNode(unref(bngIcon_default),{type:__props.note.turnModifier,class:`icon-small`,color:colorNoteIcon.value},null,8,[`type`,`color`])])):createCommentVNode(``,!0),__props.note.additionalNote&&(__props.note.additionalNote.icon||__props.note.additionalNote.text)?(openBlock(),createElementBlock(`div`,_hoisted_10$36,[__props.note.additionalNote.icon?(openBlock(),createBlock(unref(bngIcon_default),{key:0,type:__props.note.additionalNote.icon,color:__props.note.additionalNote.color,class:`icon-small`},null,8,[`type`,`color`])):__props.note.additionalNote.text?(openBlock(),createElementBlock(`span`,{key:1,class:`add-text`,style:normalizeStyle(__props.note.additionalNote.color?{color:__props.note.additionalNote.color}:null)},toDisplayString(__props.note.additionalNote.text),5)):createCommentVNode(``,!0)])):createCommentVNode(``,!0)]),__props.note.distance?(openBlock(),createElementBlock(`div`,_hoisted_11$32,toDisplayString(__props.note.distance),1)):createCommentVNode(``,!0)]))}},PaceNote_default=__plugin_vue_export_helper_default(_sfc_main$176,[[`__scopeId`,`data-v-8c4cf384`]]),_hoisted_1$157={class:`pacenotes-app`},_hoisted_2$130={class:`notes-container`},FADE_DURATION=250,TOTAL_SLOTS=4,DEFAULT_NOTE_SIZE=1.8,_sfc_main$175={__name:`app`,setup(__props){useCssVars(_ctx=>({v492216b0:noteSize.value}));let incomingQueue=ref([]),noteSize=ref(DEFAULT_NOTE_SIZE),events$3=useEvents(),{lua}=useBridge(),devEnv=reactive({env:window.beamng&&!window.beamng.shipping,vue:!1}),debugSlots=computed(()=>incomingQueue.value.map(slot=>slot?`id=${slot.note.id} pnId=${slot.pacenoteId} ts=${slot.serialNo} type=${slot.note.type} isFading=${slot.isFading} isCurrent=${slot.isCurrent}`:null)),firstFourFromQueue=computed(()=>{let result=[...incomingQueue.value.slice(0,TOTAL_SLOTS)];for(;result.length<4;)result.push({id:-1,type:`empty`});return result});function getNoteKey(slot,index){return!slot||!slot.note?`empty-${index}`:`${slot.note.id}-${index}`}function getNoteWithSize(slot){return!slot||!slot.note?{type:`empty`,size:noteSize.value}:{...slot.note,size:noteSize.value}}let mockNotes=[{id:`q1`,pnId:`1`,type:`turn3`,isLeft:!1,turnTypeValue:`3`,distance:`140`,background:{color:`var(--bng-ter-yellow-300)`,strokeColor:`var(--bng-ter-yellow-200)`,opacity:.8}},{id:`q2`,pnId:`2`,type:`turnHp`,isLeft:!0,isInto:!0,background:{color:`var(--bng-add-red-500)`,strokeColor:`var(--bng-add-red-400)`,opacity:.8},additionalNote:{icon:`scissorsSlashed`,color:`var(--bng-add-red-400)`}},{id:`q3`,pnId:`2`,type:`jumpOverBump`,isLeft:!1,turnModifier:`mathLessThan`,additionalNote:{icon:`circleSlashed`,color:`var(--bng-ter-yellow-100)`}},{id:`q4`,pnId:`3`,type:`turn6`,isLeft:!0,turnTypeValue:`6`,distance:`140`,background:{color:`var(--bng-ter-yellow-300)`,strokeColor:`var(--bng-ter-yellow-200)`,opacity:.8}},{id:`q5`,pnId:`3`,type:`rocks`,isLeft:!0,distance:`50`}];function updateCurrent(){if(incomingQueue.value.length===0||(incomingQueue.value=incomingQueue.value.filter(item=>item!==null),incomingQueue.value.length===0))return;let firstPacenoteId=incomingQueue.value[0].pacenoteId;incomingQueue.value.forEach(slot=>{slot&&!slot.isFading&&(slot.isCurrent=slot.pacenoteId===firstPacenoteId)})}function addToQueue(newItems,serialNo){try{(Array.isArray(newItems)?newItems:[newItems]).forEach(note=>{if(!note.id||!note.type){console.warn(`Invalid note format:`,JSON.stringify(note,null,2));return}let val={note,isVisible:!0,isFading:!1,isCurrent:!1,pacenoteId:note.pnId,serialNo};incomingQueue.value.push(val)}),updateCurrent()}catch(error){console.error(`Error adding to queue:`,error)}}onMounted(()=>{lua.pacenotes&&lua.pacenotes.onPaceNotesAppMounted&&lua.pacenotes.onPaceNotesAppMounted(),events$3.on(`showVisualPacenote2`,pacenoteEvent=>{let serialNo=pacenoteEvent.serialNo,notes=pacenoteEvent.visualPacenotes;addToQueue(notes,serialNo)}),events$3.on(`clearOneVisualPacenote`,serialNo=>{clearOne(serialNo)}),events$3.on(`clearAllVisualPacenotes`,()=>{clearAll()})}),onUnmounted(()=>{lua.pacenotes&&lua.pacenotes.onPaceNotesAppUnmounted&&lua.pacenotes.onPaceNotesAppUnmounted()});let testAddSequence=()=>{console.log(`Adding sequence...`);let fakeSerialNo=666,lastPnid=0;mockNotes.forEach(note=>{note.pnId!==lastPnid&&(fakeSerialNo++,lastPnid=note.pnId),addToQueue(note,fakeSerialNo)}),console.log(`Current queue:`,incomingQueue.value)},clearAll=()=>{incomingQueue.value=[]},clearOne=serialNo=>{let fadeCount=0,fadeExpected=0;incomingQueue.value.forEach((item,index)=>{item.serialNo<=serialNo&&(item.isFading=!0,item.isVisible=!1,item.isCurrent=!1,fadeExpected++),setTimeout(()=>{item&&item.isFading&&(incomingQueue.value[index]=null,fadeCount++,fadeCount===fadeExpected&&updateCurrent())},FADE_DURATION)})},testClearAll=()=>{clearAll()},testClearOne=()=>{let serialNo=incomingQueue.value[0].serialNo;clearOne(serialNo)};(devEnv.env||devEnv.vue)&&(window.testPaceNotes={addSequence:testAddSequence,clearAll:testClearAll,clearOne:testClearOne,getState:()=>({queue:incomingQueue.value,slots:debugSlots.value})});function onAnimationEnd(index){let slot=incomingQueue.value[index];slot&&slot.isVisible&&!slot.isFading&&(slot.hasAnimated=!0)}return ref(null),(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$157,[createBaseVNode(`div`,_hoisted_2$130,[_cache[1]||=createBaseVNode(`div`,{class:`spacer`},null,-1),(openBlock(!0),createElementBlock(Fragment,null,renderList(firstFourFromQueue.value,(slot,index)=>(openBlock(),createBlock(PaceNote_default,{key:getNoteKey(slot,index),class:normalizeClass({"pacenote-initial":!slot?.hasAnimated,[`position-${index}`]:!0,"fade-out":slot&&slot.isFading,"fade-in":slot&&slot.isVisible&&!slot.isFading&&!slot.hasAnimated,hidden:!slot||!slot.isVisible&&!slot.isFading,current:slot&&slot.isCurrent}),note:getNoteWithSize(slot),onAnimationend:$event=>onAnimationEnd(index)},null,8,[`class`,`note`,`onAnimationend`]))),128))]),createCommentVNode(``,!0)]))}},app_default$28=__plugin_vue_export_helper_default(_sfc_main$175,[[`__scopeId`,`data-v-13adc0e2`]]),_hoisted_1$156={class:`countdown-top`},_hoisted_2$129={key:0,class:`countdown-go`},_hoisted_3$116={class:`countdown-bottom`},_hoisted_4$94={class:`rally-loop-manager-text`},_hoisted_5$81={class:`time-main`},_hoisted_6$67={key:0,class:`time-period`},_sfc_main$174={__name:`CountdownWidget`,props:{rallyLoopManager:{type:String,default:`--:--:--`},period:{type:String,default:null},countdown:{type:Number,default:10}},setup(__props){let props=__props,stage=computed(()=>props.countdown<=0?6:props.countdown>5?0:6-props.countdown);return(_ctx,_cache)=>(openBlock(),createElementBlock(Fragment,null,[createBaseVNode(`div`,_hoisted_1$156,[stage.value===6?(openBlock(),createElementBlock(`div`,_hoisted_2$129)):(openBlock(),createElementBlock(Fragment,{key:1},[createBaseVNode(`div`,{class:normalizeClass([`countdown-square`,{visible:stage.value>=1}])},null,2),createBaseVNode(`div`,{class:normalizeClass([`countdown-square`,{visible:stage.value>=2}])},null,2),createBaseVNode(`div`,{class:normalizeClass([`countdown-square`,{visible:stage.value>=3}])},null,2),createBaseVNode(`div`,{class:normalizeClass([`countdown-square`,{visible:stage.value>=4}])},null,2),createBaseVNode(`div`,{class:normalizeClass([`countdown-square`,{visible:stage.value>=5}])},null,2)],64))]),createBaseVNode(`div`,_hoisted_3$116,[createBaseVNode(`div`,_hoisted_4$94,[createBaseVNode(`span`,_hoisted_5$81,toDisplayString(__props.rallyLoopManager),1),__props.period?(openBlock(),createElementBlock(`span`,_hoisted_6$67,toDisplayString(__props.period),1)):createCommentVNode(``,!0)])])],64))}},CountdownWidget_default=__plugin_vue_export_helper_default(_sfc_main$174,[[`__scopeId`,`data-v-a0ececba`]]),_hoisted_1$155={class:`vehicle-proximity`},_hoisted_2$128={class:`top-row`},_hoisted_3$115={class:`proximity-status`},_hoisted_4$93={key:2},_sfc_main$173={__name:`VehicleProximity`,props:{vehicleProximity:{type:Object,required:!0},stage:{type:String,required:!0},precision:{type:Number,default:0,validator:value=>value>=0&&value<=2},badgeText:{type:String,default:``},instruction:{type:Object,required:!1,default:()=>({text:``,type:`notice`}),validator:value=>value?typeof value.text==`string`&&[`alert`,`alert-sm`,`notice`].includes(value.type):!0},instruction2:{type:Object,required:!1,default:()=>({structuredText:null})}},setup(__props){let props=__props,distanceDimmed=computed(()=>props.stage===`stop`||props.stage===`staged`),hasLabel=computed(()=>props.stage===`approaching`&&props.badgeText),formattedDistance=computed(()=>{let dist=props.vehicleProximity.distance;if(Math.abs(dist)>200)return`${(dist/1e3).toFixed(2)}km`;if(dist<0){let multiplier=10**props.precision,flooredDist=Math.floor(dist*multiplier)/multiplier;return`${(flooredDist===0?0:flooredDist).toFixed(props.precision)}m`}return`${dist.toFixed(props.precision)}m`});return(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$155,[createBaseVNode(`div`,_hoisted_2$128,[createBaseVNode(`div`,_hoisted_3$115,[createBaseVNode(`div`,{class:normalizeClass([`proximity-status-badge`,[__props.stage,{"has-label":hasLabel.value}]])},[__props.stage===`stop`?(openBlock(),createElementBlock(Fragment,{key:0},[createTextVNode(`STOP`)],64)):__props.stage===`goback`?(openBlock(),createElementBlock(Fragment,{key:1},[createTextVNode(`BACK`)],64)):__props.stage===`slow`?(openBlock(),createElementBlock(Fragment,{key:2},[createTextVNode(`SLOW`)],64)):__props.stage===`staged`?(openBlock(),createElementBlock(Fragment,{key:3},[createTextVNode(`STAGED`)],64)):__props.stage===`approaching`?(openBlock(),createElementBlock(Fragment,{key:4},[createTextVNode(toDisplayString(__props.badgeText),1)],64)):createCommentVNode(``,!0)],2)]),createBaseVNode(`div`,{class:normalizeClass([`proximity-distance`,{dimmed:distanceDimmed.value}])},toDisplayString(formattedDistance.value),3)]),__props.instruction?.text?(openBlock(),createElementBlock(`div`,{key:0,class:normalizeClass([`instruction-row`,__props.instruction?.type||`notice`])},toDisplayString(__props.instruction?.text),3)):createCommentVNode(``,!0),__props.instruction2?.structuredText?(openBlock(),createElementBlock(`div`,{key:1,class:normalizeClass([`instruction-row`,[__props.instruction2?.type||`notice`,{flash:__props.instruction2?.flash}]])},[(openBlock(!0),createElementBlock(Fragment,null,renderList(__props.instruction2?.structuredText,item=>(openBlock(),createElementBlock(Fragment,{key:item.id},[item.type===`clock`?(openBlock(),createElementBlock(`span`,{key:0,class:normalizeClass(item.class)},toDisplayString(item.val),3)):item.type===`penalty`?(openBlock(),createElementBlock(`span`,{key:1,class:normalizeClass(item.class)},toDisplayString(item.val),3)):(openBlock(),createElementBlock(`span`,_hoisted_4$93,toDisplayString(item),1))],64))),128))],2)):createCommentVNode(``,!0)]))}},VehicleProximity_default=__plugin_vue_export_helper_default(_sfc_main$173,[[`__scopeId`,`data-v-871af6e6`]]),_hoisted_1$154={class:`rally-countdown-app-container`},_hoisted_2$127={class:`panel-countdown`},_hoisted_3$114={key:2,class:`section-interact-hint`},_sfc_main$172={__name:`appCountdown`,setup(__props){useCssVars(_ctx=>({v730cc8f6:themeColor.value}));let{lua}=useBridge(),devEnv=reactive({env:window.beamng&&!window.beamng.shipping,vue:!1}),showDebugInfo=ref(!1),ActiveState={INACTIVE:`inactive`,VEHICLE_PROXIMITY:`vehicleProximity`,STAGE_ACTIVE:`stageActive`,COUNTDOWN:`countdown`},rallyClockData=reactive({wallClockTime:null,day:null,totalTime:0,canSkipTimeControls:!1,isTimeControlSkipAvailable:!1,canSkipCountdown:!1,isNgrcMode:!1}),activeState=ref(ActiveState.INACTIVE),vehicleProximityData=reactive({isNear:!1,distance:0,distanceToPlane:0,isStopped:!1,isFrozen:!1,usingGroundMarkerDistance:!1}),scheduleData=reactive({label:null,eventType:null,ssLabel:null,eventWallClockStart:null,eventWallClockEnd:null,timeDiff:null,timeDiffWithEnd:null,lateness:null,penalty:0,hasPenalty:!1,canIncurLatePenalty:!1,speedLimit:null,speedLimitDisplay:null,speedUnit:`km/h`,isSpeeding:!1}),stageData=reactive({currentSSTime:null,isActive:!1,isComplete:!1,splits:[],label:null,completion:{distM:0,distPct:0}}),countdownData=reactive({countdown:null,state:null}),themeColor=computed(()=>`#07ff00`),canInteract=computed(()=>rallyClockData.canSkipTimeControls||rallyClockData.canSkipCountdown),interactLabel=computed(()=>rallyClockData.canSkipCountdown||rallyClockData.canSkipTimeControls?`[action=gameplay_interact]Skip Clock`:``),proximityStage=computed(()=>{scheduleData.eventType;let distance=vehicleProximityData.distance;return scheduleData.eventType===`ss_start`?vehicleProximityData.isNear&&vehicleProximityData.isStopped?`staged`:distance<0?`goback`:vehicleProximityData.isNear&&!vehicleProximityData.isStopped?`stop`:!vehicleProximityData.isNear&&distance>=0&&distance<=25?`slow`:`approaching`:distance<0?`goback`:vehicleProximityData.isNear?`stop`:!vehicleProximityData.isNear&&distance>=0&&distance<=25||scheduleData.eventType===`ss_stop`?`slow`:`approaching`}),distancePrecision=computed(()=>{let distAbs=Math.abs(vehicleProximityData.distance),closenessThreshold=5;if(scheduleData.eventType===`ss_start`){if(distAbs<5)return proximityStage.value===`stop`||proximityStage.value===`goback`||proximityStage.value===`staged`||proximityStage.value===`slow`?2:0}else if((scheduleData.eventType===`tc`||scheduleData.eventType===`ss_stop`)&&distAbs<5)return proximityStage.value===`stop`||proximityStage.value===`goback`?1:0;return 0}),badgeText=computed(()=>scheduleData.eventType===`ss_start`?`SS${scheduleData.ssLabel}`:scheduleData.eventType===`tc`?scheduleData.label:scheduleData.eventType===`ss_stop`?`SLOW`:scheduleData.eventType===`service_in`?`SERVICE`:``),proximityInstruction2=computed(()=>{let stage=proximityStage.value;if(scheduleData.eventType===`ss_start`)return{structuredText:[`Start in `,{type:`clock`,val:scheduleData.timeDiff,class:`clock-badge`}],flash:!1};if(stage===`approaching`){if(rallyClockData.isTimeControlSkipAvailable&&scheduleData.eventType===`tc`)return{structuredText:[`Slow Down for `,{type:`clock`,val:`Clock Skip`,class:`clock-badge`}],flash:!1};if(scheduleData.eventType===`service_in`||scheduleData.label===`TC0`||scheduleData.eventType===`tc`)return{structuredText:[`Limit `,{type:`penalty`,val:`${scheduleData.speedLimitDisplay}${scheduleData.speedUnit}`,class:`penalty-badge`}],flash:scheduleData.isSpeeding}}else return null}),proximityInstruction=computed(()=>{let stage=proximityStage.value,text=``,type=`notice`;return stage===`slow`?scheduleData.eventType===`ss_start`?text=`Stage vehicle at start line.`:scheduleData.eventType===`tc`||scheduleData.eventType:stage===`stop`?scheduleData.eventType:stage===`goback`||(stage===`staged`?vehicleProximityData.isFrozen:stage===`approaching`&&(scheduleData.eventType===`ss_start`?text=`Stage vehicle at start line.`:scheduleData.eventType===`tc`||scheduleData.eventType===`service_in`||scheduleData.eventType)),{text,type:`notice`}}),streamsList$1=[`rallyLoop`],streamBuffer={rallyLoop:null},rafId=null;function processStreamUpdates(){if(streamBuffer.rallyLoop){let data=streamBuffer.rallyLoop;activeState.value=data.activeState||ActiveState.INACTIVE,data.rallyClock&&Object.assign(rallyClockData,data.rallyClock),data.scheduleData&&Object.assign(scheduleData,data.scheduleData),data.stageData&&Object.assign(stageData,data.stageData),data.countdownData&&Object.assign(countdownData,data.countdownData),data.vehicleProximity&&Object.assign(vehicleProximityData,data.vehicleProximity),data.showDebugInfo!==void 0&&(showDebugInfo.value=data.showDebugInfo),streamBuffer.rallyLoop=null}rafId=requestAnimationFrame(processStreamUpdates)}rafId=requestAnimationFrame(processStreamUpdates),useStreams(streamsList$1,streams=>{streams.rallyLoop&&(streamBuffer.rallyLoop=streams.rallyLoop)}),onMounted(()=>{}),onUnmounted(()=>{rafId&&cancelAnimationFrame(rafId)});function isStageActive(){return activeState.value===ActiveState.STAGE_ACTIVE}return(devEnv.env||devEnv.vue)&&(window.rallyLoopApp={activeState,vehicleProximityData,rallyClockData,scheduleData,stageData,countdownData,proximityStage,distancePrecision,badgeText}),(_ctx,_cache)=>(openBlock(),createBlock(Transition,{name:`fade`},{default:withCtx(()=>[createBaseVNode(`div`,_hoisted_1$154,[isStageActive()?createCommentVNode(``,!0):(openBlock(),createElementBlock(`div`,{key:0,class:normalizeClass([`rally-countdown-app`,{"show-active-stage":isStageActive()}])},[activeState.value===ActiveState.VEHICLE_PROXIMITY?(openBlock(),createElementBlock(`div`,{key:0,class:normalizeClass([`section-vehicle-positioning`,{"has-interact-hint":canInteract.value}])},[createVNode(VehicleProximity_default,{"vehicle-proximity":vehicleProximityData,stage:proximityStage.value,precision:distancePrecision.value,"badge-text":badgeText.value,instruction:proximityInstruction.value,instruction2:proximityInstruction2.value},null,8,[`vehicle-proximity`,`stage`,`precision`,`badge-text`,`instruction`,`instruction2`])],2)):createCommentVNode(``,!0),activeState.value===ActiveState.COUNTDOWN?(openBlock(),createElementBlock(`div`,{key:1,class:normalizeClass([`section-vehicle-positioning`,{"has-interact-hint":canInteract.value}])},[createBaseVNode(`div`,_hoisted_2$127,[createVNode(CountdownWidget_default,{"rally-loop-manager":rallyClockData.wallClockTime?.time||`--:--:--`,period:rallyClockData.wallClockTime?.ampm||``,countdown:countdownData.countdown},null,8,[`rally-loop-manager`,`period`,`countdown`])])],2)):createCommentVNode(``,!0),canInteract.value?(openBlock(),createElementBlock(`div`,_hoisted_3$114,[createVNode(unref(dynamicComponent_default),{template:interactLabel.value,bbcode:``},null,8,[`template`])])):createCommentVNode(``,!0)],2))])]),_:1}))}},appCountdown_default=__plugin_vue_export_helper_default(_sfc_main$172,[[`__scopeId`,`data-v-bde5d1a7`]]),_hoisted_1$153={class:`rally-timecard-app-container`},_hoisted_2$126={key:0,class:`rally-timecard-app`},_hoisted_3$113={class:`interact-label-on-timecard`},_hoisted_4$92={class:`time-card`},_hoisted_5$80={class:`rally-card-header`},_hoisted_6$66={class:`header-top`},_hoisted_7$58=[`src`],_hoisted_8$48={key:0,class:`mission-name`},_hoisted_9$42={class:`rally-card-content`},_hoisted_10$35={key:0,class:`group-divider`},_hoisted_11$31={class:`col-label`},_hoisted_12$25={class:`event-label`},_hoisted_13$22={class:`event-data-container`},_hoisted_14$21={key:0,class:`time-widget`},_hoisted_15$20={class:`col-recorded-time time-widget-value time-taken-value`},_hoisted_16$20={key:0,class:`stage-time`},_hoisted_17$16={key:0,class:`ampm`},_hoisted_18$14={class:`time-widget time-widget-due`},_hoisted_19$11={class:`col-due-time time-widget-value`},_hoisted_20$10={key:0,class:`scheduled-time`},_hoisted_21$10={key:0,class:`ampm`},_hoisted_22$8={class:`time-widget-combined`},_hoisted_23$7={class:`time-widget`},_hoisted_24$6={class:`col-recorded-time time-widget-value actual-value`},_hoisted_25$5={key:0,class:`recorded-time`},_hoisted_26$4={key:0,class:`ampm`},_hoisted_27$4={class:`time-widget`},_hoisted_28$3={class:`col-status time-widget-value status-value`},_hoisted_29$3={key:0,class:`status-text early`},_hoisted_30$3={key:1,class:`status-text late`},_hoisted_31$3={key:2,class:`status-text ok`},_hoisted_32$3={key:0,class:`penalty-card`},_hoisted_33$3={class:`rally-card-header penalty-card-header`},_hoisted_34$3={class:`header-top`},_hoisted_35$2={class:`penalty-total-header`},_hoisted_36$2={class:`total-value`},_hoisted_37$1={class:`penalty-card-content`},_hoisted_38$1={class:`penalty-group-header`},_hoisted_39$1={class:`group-name`},_hoisted_40$1={class:`group-total`},_hoisted_41$1={class:`penalty-list`},_hoisted_42$1={class:`penalty-type`},_hoisted_43$1={class:`penalty-amount`},_hoisted_44$1={key:1,class:`interact-label`},_hoisted_45$1={class:`interact-label-text`},_sfc_main$171={__name:`appTimecard`,setup(__props){useCssVars(_ctx=>({a6aff4e0:themeColor.value}));let{lua}=useBridge(),events$3=useEvents(),penaltyData=ref({totalPenalty:0,groups:[]}),displayMode=ref(1);reactive({env:window.beamng&&!window.beamng.shipping,vue:!1}),events$3.on(`RallyGameplayInteract`,data=>{data&&data.forceShowTimecard?displayMode.value=1:displayMode.value===1?displayMode.value=0:displayMode.value=1});let toggleLabel=computed(()=>displayMode.value===1?`Hide`:`Show`),interactLabel=computed(()=>`[action=gameplay_interact]`),ActiveState={INACTIVE:`inactive`,VEHICLE_PROXIMITY:`vehicleProximity`,STAGE_ACTIVE:`stageActive`,COUNTDOWN:`countdown`},showDebugInfo=ref(!1),missionName=ref(``),activeState=ref(ActiveState.INACTIVE),timecardData=ref([]),rallyClockData=reactive({}),vehicleProximityData=reactive({}),scheduleData=reactive({}),stageData=reactive({}),countdownData=reactive({}),themeColor=computed(()=>`#07ff00`);function shouldShowApp(){return displayMode.value===1}function formatPenaltyType(type){return type?type.replace(/_/g,` `):``}let streamsList$1=[`rallyLoop`],streamBuffer={rallyLoop:null},rafId=null;function processStreamUpdates(){if(streamBuffer.rallyLoop){let data=streamBuffer.rallyLoop;activeState.value=data.activeState||ActiveState.INACTIVE,data.rallyClock&&Object.assign(rallyClockData,data.rallyClock),data.scheduleData&&Object.assign(scheduleData,data.scheduleData),data.timecardData&&(timecardData.value=data.timecardData),data.penaltyData&&(penaltyData.value=data.penaltyData),data.stageData&&Object.assign(stageData,data.stageData),data.countdownData&&Object.assign(countdownData,data.countdownData),data.vehicleProximity&&Object.assign(vehicleProximityData,data.vehicleProximity),data.showDebugInfo!==void 0&&(showDebugInfo.value=data.showDebugInfo),data.missionName!==void 0&&(missionName.value=data.missionName||``),streamBuffer.rallyLoop=null}rafId=requestAnimationFrame(processStreamUpdates)}return rafId=requestAnimationFrame(processStreamUpdates),useStreams(streamsList$1,streams=>{streams.rallyLoop&&(streamBuffer.rallyLoop=streams.rallyLoop)}),onMounted(()=>{}),onUnmounted(()=>{rafId&&cancelAnimationFrame(rafId)}),(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$153,[createVNode(Transition,{name:`slide`},{default:withCtx(()=>[shouldShowApp()?(openBlock(),createElementBlock(`div`,_hoisted_2$126,[createBaseVNode(`div`,null,[createBaseVNode(`div`,_hoisted_3$113,[createVNode(unref(dynamicComponent_default),{template:`[action=gameplay_interact]${toggleLabel.value} Time Card`,bbcode:``},null,8,[`template`])]),createBaseVNode(`div`,_hoisted_4$92,[createBaseVNode(`div`,_hoisted_5$80,[createBaseVNode(`div`,_hoisted_6$66,[_cache[0]||=createBaseVNode(`span`,{class:`rally-card-title`},`TIME CARD`,-1),createBaseVNode(`img`,{class:`header-beamng-logo`,src:unref(getAssetURL)(`images/beamng-logo-mono_189x174.png`)},null,8,_hoisted_7$58)]),missionName.value?(openBlock(),createElementBlock(`div`,_hoisted_8$48,`Event: `+toDisplayString(missionName.value),1)):createCommentVNode(``,!0)]),createBaseVNode(`div`,_hoisted_9$42,[(openBlock(!0),createElementBlock(Fragment,null,renderList(timecardData.value,(entry,idx)=>(openBlock(),createElementBlock(Fragment,{key:idx},[idx>0&&entry.group!==timecardData.value[idx-1].group?(openBlock(),createElementBlock(`div`,_hoisted_10$35)):createCommentVNode(``,!0),createBaseVNode(`div`,{class:normalizeClass([`checklist-row`,{completed:entry.recordedTime||entry.stageTime,"stage-entry":entry.isStageEntry,early:entry.status===`early`,late:entry.status===`late`,"on-time":entry.status===`on-time`,pending:!entry.recordedTime&&!entry.stageTime}])},[createBaseVNode(`div`,_hoisted_11$31,[_cache[1]||=createBaseVNode(`div`,{class:`event-label-top`},`\xA0`,-1),createBaseVNode(`div`,_hoisted_12$25,toDisplayString(entry.label),1)]),createBaseVNode(`div`,_hoisted_13$22,[entry.isStageEntry?(openBlock(),createElementBlock(`div`,_hoisted_14$21,[_cache[2]||=createBaseVNode(`div`,{class:`time-widget-label`},`Time Taken`,-1),createBaseVNode(`div`,_hoisted_15$20,[entry.stageTime?(openBlock(),createElementBlock(`div`,_hoisted_16$20,[createTextVNode(toDisplayString(entry.stageTime),1),entry.stageTime.ampm?(openBlock(),createElementBlock(`span`,_hoisted_17$16,toDisplayString(entry.stageTime.ampm),1)):createCommentVNode(``,!0)])):createCommentVNode(``,!0)])])):(openBlock(),createElementBlock(Fragment,{key:1},[createBaseVNode(`div`,_hoisted_18$14,[_cache[3]||=createBaseVNode(`div`,{class:`time-widget-label`},`Due`,-1),createBaseVNode(`div`,_hoisted_19$11,[entry.scheduledTime?(openBlock(),createElementBlock(`div`,_hoisted_20$10,[createTextVNode(toDisplayString(entry.scheduledTime.time),1),entry.scheduledTime.ampm?(openBlock(),createElementBlock(`span`,_hoisted_21$10,toDisplayString(entry.scheduledTime.ampm),1)):createCommentVNode(``,!0)])):createCommentVNode(``,!0)])]),createBaseVNode(`div`,_hoisted_22$8,[createBaseVNode(`div`,_hoisted_23$7,[_cache[4]||=createBaseVNode(`div`,{class:`time-widget-label`},`Actual`,-1),createBaseVNode(`div`,_hoisted_24$6,[entry.recordedTime?(openBlock(),createElementBlock(`div`,_hoisted_25$5,[createTextVNode(toDisplayString(entry.recordedTime.time),1),entry.recordedTime.ampm?(openBlock(),createElementBlock(`span`,_hoisted_26$4,toDisplayString(entry.recordedTime.ampm),1)):createCommentVNode(``,!0)])):createCommentVNode(``,!0)])]),createBaseVNode(`div`,_hoisted_27$4,[_cache[5]||=createBaseVNode(`div`,{class:`time-widget-label`},`Status`,-1),createBaseVNode(`div`,_hoisted_28$3,[entry.status===`early`?(openBlock(),createElementBlock(`span`,_hoisted_29$3,`EARLY`)):entry.status===`late`?(openBlock(),createElementBlock(`span`,_hoisted_30$3,`LATE`)):entry.recordedTime||entry.status===`on-time`?(openBlock(),createElementBlock(`span`,_hoisted_31$3,`OK`)):createCommentVNode(``,!0)])])])],64))])],2)],64))),128))])]),penaltyData.value&&penaltyData.value.totalPenalty>0?(openBlock(),createElementBlock(`div`,_hoisted_32$3,[createBaseVNode(`div`,_hoisted_33$3,[createBaseVNode(`div`,_hoisted_34$3,[_cache[7]||=createBaseVNode(`span`,{class:`rally-card-title`},`PENALTIES`,-1),createBaseVNode(`div`,_hoisted_35$2,[_cache[6]||=createBaseVNode(`span`,{class:`total-label`},`Total`,-1),createBaseVNode(`span`,_hoisted_36$2,toDisplayString(penaltyData.value.totalPenalty)+`s`,1)])])]),createBaseVNode(`div`,_hoisted_37$1,[(openBlock(!0),createElementBlock(Fragment,null,renderList(penaltyData.value.groups,(group,idx)=>withDirectives((openBlock(),createElementBlock(`div`,{key:idx,class:`penalty-group`},[createBaseVNode(`div`,_hoisted_38$1,[createBaseVNode(`span`,_hoisted_39$1,toDisplayString(group.eventGroup),1),_cache[8]||=createBaseVNode(`span`,{class:`group-mid`},null,-1),createBaseVNode(`span`,_hoisted_40$1,toDisplayString(group.totalPenalty)+`s`,1)]),createBaseVNode(`div`,_hoisted_41$1,[(openBlock(!0),createElementBlock(Fragment,null,renderList(group.penalties,(penalty,pidx)=>(openBlock(),createElementBlock(`div`,{key:pidx,class:`penalty-item`},[createBaseVNode(`span`,_hoisted_42$1,toDisplayString(formatPenaltyType(penalty.type)),1),createBaseVNode(`span`,_hoisted_43$1,toDisplayString(penalty.amount)+`s (x`+toDisplayString(penalty.count)+`)`,1)]))),128))])])),[[vShow,group.totalPenalty>0]])),128))])])):createCommentVNode(``,!0)])])):(openBlock(),createElementBlock(`div`,_hoisted_44$1,[createBaseVNode(`div`,null,[createVNode(unref(dynamicComponent_default),{template:interactLabel.value,bbcode:``},null,8,[`template`]),createBaseVNode(`div`,_hoisted_45$1,[createBaseVNode(`div`,null,toDisplayString(toggleLabel.value),1),_cache[9]||=createBaseVNode(`div`,null,`Time Card`,-1)])])]))]),_:1})]))}},appTimecard_default=__plugin_vue_export_helper_default(_sfc_main$171,[[`__scopeId`,`data-v-216504fd`]]),_hoisted_1$152={class:`rally-dashboard-app-container`},_hoisted_2$125={class:`dashboard-widget widget-rally-clock`},_hoisted_3$112={key:0,class:`period`},_hoisted_4$91={class:`dashboard-widget widget-rally-sstime`},_hoisted_5$79={class:`widget-value`},_hoisted_6$65={class:`dashboard-widget widget-rally-objective`},_hoisted_7$57={class:`widget-value`},_hoisted_8$47={key:2},_sfc_main$170={__name:`appDashboard`,setup(__props){let{lua}=useBridge(),events$3=useEvents(),recoverVehicleTemplate=computed(()=>` Press [action=reset_physics] to recover vehicle.`),ActiveState={INACTIVE:`inactive`,VEHICLE_PROXIMITY:`vehicleProximity`,STAGE_ACTIVE:`stageActive`,COUNTDOWN:`countdown`},rallyClockData=reactive({wallClockTime:null,day:null,totalTime:0,canSkipTimeControls:!1,canSkipCountdown:!1,isNgrcMode:!1}),activeState=ref(ActiveState.INACTIVE),clockFlash=ref(!1);events$3.on(`RallyClockSkipped`,()=>{clockFlash.value=!1,setTimeout(()=>{clockFlash.value=!0},0),setTimeout(()=>{clockFlash.value=!1},1e3)});let scheduleData=reactive({label:null,eventType:null,ssLabel:null,eventWallClockStart:null,eventWallClockEnd:null,timeDiff:null,timeDiffWithEnd:null,lateness:null,penalty:0,hasPenalty:!1,canIncurLatePenalty:!1,speedLimit:null,speedLimitDisplay:null,speedUnit:`km/h`}),formattedWallClock=computed(()=>rallyClockData.wallClockTime?{time:rallyClockData.wallClockTime.time||`--:--:--`,period:rallyClockData.wallClockTime.ampm||``}:{time:`--:--:--`,period:``}),objectiveText=computed(()=>{let obj=scheduleData;return!obj||!obj.eventType?[]:obj.eventType===`service_in`?[`Drive to your `,{type:`badge`,val:`service bay`,class:`tc-badge`},`.`]:obj.eventType===`tc`&&obj.label===`TC0`?[`Reverse out and reach `,{type:`badge`,val:obj.label,class:`tc-badge`},` between `,{type:`clock`,val:obj.eventWallClockStart,class:`clock-badge`},` - `,{type:`clock`,val:obj.eventWallClockEnd,class:`clock-badge`},`. Penalty for each minute early or late: `,{type:`badge`,val:`+10s`,class:`penalty-badge`},`.`]:obj.eventType===`tc`?[`Reach `,{type:`badge`,val:obj.label,class:`tc-badge`},` between `,{type:`clock`,val:obj.eventWallClockStart,class:`clock-badge`},` - `,{type:`clock`,val:obj.eventWallClockEnd,class:`clock-badge`},`. Penalty for each minute early or late: `,{type:`badge`,val:`10sec`,class:`penalty-badge`},`.`]:[]}),streamsList$1=[`rallyLoop`],streamBuffer={rallyLoop:null},rafId=null;function processStreamUpdates(){if(streamBuffer.rallyLoop){let data=streamBuffer.rallyLoop;activeState.value=data.activeState||ActiveState.INACTIVE,data.rallyClock&&Object.assign(rallyClockData,data.rallyClock),data.scheduleData&&Object.assign(scheduleData,data.scheduleData),streamBuffer.rallyLoop=null}rafId=requestAnimationFrame(processStreamUpdates)}rafId=requestAnimationFrame(processStreamUpdates),useStreams(streamsList$1,streams=>{streams.rallyLoop&&(streamBuffer.rallyLoop=streams.rallyLoop)}),onMounted(()=>{}),onUnmounted(()=>{rafId&&cancelAnimationFrame(rafId)});function isStageActive(){return activeState.value===ActiveState.STAGE_ACTIVE}return(_ctx,_cache)=>(openBlock(),createBlock(Transition,{name:`fade`},{default:withCtx(()=>[createBaseVNode(`div`,_hoisted_1$152,[isStageActive()?createCommentVNode(``,!0):(openBlock(),createElementBlock(`div`,{key:0,class:normalizeClass([`rally-dashboard-app`,{"show-active-stage":isStageActive()}])},[createBaseVNode(`div`,_hoisted_2$125,[_cache[0]||=createBaseVNode(`div`,{class:`widget-label`},`Event Clock`,-1),createBaseVNode(`div`,{class:normalizeClass([`widget-value clock-value`,{"flash-pink":clockFlash.value}])},[createTextVNode(toDisplayString(formattedWallClock.value.time),1),formattedWallClock.value.period?(openBlock(),createElementBlock(`span`,_hoisted_3$112,toDisplayString(formattedWallClock.value.period),1)):createCommentVNode(``,!0)],2)]),createBaseVNode(`div`,_hoisted_4$91,[_cache[1]||=createBaseVNode(`div`,{class:`widget-label`},`Your Time`,-1),createBaseVNode(`div`,_hoisted_5$79,toDisplayString(rallyClockData.totalTime),1)]),createBaseVNode(`div`,_hoisted_6$65,[_cache[2]||=createBaseVNode(`div`,{class:`widget-label`},`Instructions`,-1),createBaseVNode(`div`,_hoisted_7$57,[(openBlock(!0),createElementBlock(Fragment,null,renderList(objectiveText.value,item=>(openBlock(),createElementBlock(`span`,{key:item},[item.type===`badge`?(openBlock(),createElementBlock(`span`,{key:0,class:normalizeClass(item.class)},toDisplayString(item.val),3)):item.type===`clock`?(openBlock(),createElementBlock(`span`,{key:1,class:normalizeClass(item.class)},toDisplayString(item.val.time)+toDisplayString(item.val.period),3)):(openBlock(),createElementBlock(`span`,_hoisted_8$47,toDisplayString(item),1))]))),128)),createVNode(unref(dynamicComponent_default),{template:recoverVehicleTemplate.value,bbcode:``},null,8,[`template`])])])],2))])]),_:1}))}},appDashboard_default=__plugin_vue_export_helper_default(_sfc_main$170,[[`__scopeId`,`data-v-a3bb6c18`]]),_hoisted_1$151={class:`rally-debug-app-container`},_hoisted_2$124={key:0,class:`debug-info`},_sfc_main$169={__name:`appDebug`,setup(__props){let{lua}=useBridge(),ActiveState={INACTIVE:`inactive`,VEHICLE_PROXIMITY:`vehicleProximity`,STAGE_ACTIVE:`stageActive`,COUNTDOWN:`countdown`},showDebugInfo=ref(!0),activeState=ref(ActiveState.INACTIVE),timecardData=ref([]),penaltyData=ref({totalPenalty:0,groups:[]}),rallyClockData=reactive({}),vehicleProximityData=reactive({}),scheduleData=reactive({}),stageData=reactive({}),countdownData=reactive({}),streamsList$1=[`rallyLoop`],streamBuffer={rallyLoop:null},rafId=null;function processStreamUpdates(){if(streamBuffer.rallyLoop){let data=streamBuffer.rallyLoop;activeState.value=data.activeState||ActiveState.INACTIVE,data.rallyClock&&Object.assign(rallyClockData,data.rallyClock),data.scheduleData&&Object.assign(scheduleData,data.scheduleData),data.timecardData&&(timecardData.value=data.timecardData),data.penaltyData&&(penaltyData.value=data.penaltyData),data.stageData&&Object.assign(stageData,data.stageData),data.countdownData&&Object.assign(countdownData,data.countdownData),data.vehicleProximity&&Object.assign(vehicleProximityData,data.vehicleProximity),streamBuffer.rallyLoop=null}rafId=requestAnimationFrame(processStreamUpdates)}return rafId=requestAnimationFrame(processStreamUpdates),useStreams(streamsList$1,streams=>{streams.rallyLoop&&(streamBuffer.rallyLoop=streams.rallyLoop)}),onMounted(()=>{}),onUnmounted(()=>{rafId&&cancelAnimationFrame(rafId)}),(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$151,[showDebugInfo.value?(openBlock(),createElementBlock(`div`,_hoisted_2$124,[createBaseVNode(`div`,null,`activeState: "`+toDisplayString(activeState.value)+`"`,1),createBaseVNode(`div`,null,`rallyClock: `+toDisplayString(rallyClockData),1),createBaseVNode(`div`,null,`countdownData: `+toDisplayString(countdownData),1),createBaseVNode(`div`,null,`vehicleProximityData: `+toDisplayString(vehicleProximityData),1),createBaseVNode(`div`,null,`scheduleData: `+toDisplayString(scheduleData),1),createBaseVNode(`div`,null,`timecardData: `+toDisplayString(timecardData.value),1),createBaseVNode(`div`,null,`penaltyData: `+toDisplayString(penaltyData.value),1),createBaseVNode(`div`,null,`stageData: `+toDisplayString(stageData),1)])):createCommentVNode(``,!0)]))}},appDebug_default=__plugin_vue_export_helper_default(_sfc_main$169,[[`__scopeId`,`data-v-c2c6bfeb`]]),_hoisted_1$150={class:`distance-widget-svg`},_hoisted_2$123=[`x`,`y`,`height`],_hoisted_3$111=[`x`,`y`,`width`,`height`],_hoisted_4$90=[`x`,`y`,`width`,`height`],_hoisted_5$78=[`x`,`y`,`width`,`height`],_hoisted_6$64={x:0,y:`90%`,"text-anchor":`middle`},_hoisted_7$56={class:`tick-label`},_hoisted_8$46={class:`tick-label-unit`,dx:`2`},_hoisted_9$41=[`x`,`y`,`width`,`height`],_hoisted_10$34={x:0,y:`90%`,dx:`20`,"text-anchor":`end`},_hoisted_11$30={key:0,class:`tick-label-bold`},_hoisted_12$24={class:`tick-label-unit`,dx:`2`},_hoisted_13$21=[`x`,`y`,`width`,`height`],PAD_PX=20,PADRIGHT_PX=26,barHeightPct=8,barCenterY=50,tickStrokeWidth=2,tickSize=12,trackingRectSize=14,_sfc_main$168={__name:`DistanceWidgetSVGRect`,props:{distPct:{type:Number,required:!0},totalDistM:{type:Number,required:!0},splits:{type:Array,default:()=>[]},splitPrecision:{type:Number,default:1},themeColor:{type:String,required:!0},unit:{type:String,default:`km`}},setup(__props){useCssVars(_ctx=>({v94238812:__props.themeColor}));let props=__props,barStartX=PAD_PX,barY=barCenterY-barHeightPct/2;100-PADRIGHT_PX,computed(()=>PAD_PX+(100-PAD_PX-PADRIGHT_PX)*props.distPct);let currentX=computed(()=>`calc(${PAD_PX}px + (100% - ${PAD_PX+PADRIGHT_PX}px) * ${props.distPct})`),barWidth=`calc(100% - ${PAD_PX+PADRIGHT_PX}px)`,progressWidth=computed(()=>`calc((100% - ${PAD_PX+PADRIGHT_PX}px) * ${props.distPct})`),barEndX=`calc(100% - ${PADRIGHT_PX}px)`,splitMarkers=computed(()=>props.splits?props.splits.filter(s=>typeof s?.pathnodeType==`string`&&s.pathnodeType.startsWith(`split_`)).map((s,idx)=>{let pct=s.distPct||0,x=`calc(${PAD_PX}px + (100% - ${PAD_PX+PADRIGHT_PX}px) * ${pct})`;return{key:s.pathnodeId??idx,x,label:{val:s.splitLabel,unit:props.unit}}}):[]),finalSplitLabel=computed(()=>!props.splits||props.splits.length===0?{val:null,unit:null}:{val:props.splits[props.splits.length-1]?.splitLabel,unit:props.unit});return(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$150,[(openBlock(),createElementBlock(`svg`,null,[createBaseVNode(`rect`,{x:unref(barStartX)+`px`,y:barY+`%`,width:barWidth,height:barHeightPct+`%`,fill:`white`},null,8,_hoisted_2$123),createBaseVNode(`rect`,{x:unref(barStartX)+`px`,y:barY-1+`%`,width:progressWidth.value,height:barHeightPct+2+`%`,fill:`var(--theme-color)`},null,8,_hoisted_3$111),createBaseVNode(`rect`,{x:unref(barStartX)-tickSize/2+`px`,y:`calc(`+barCenterY+`% - `+tickSize/2+`px)`,width:tickSize+`px`,height:tickSize+`px`,fill:`var(--theme-color)`},null,8,_hoisted_4$90),(openBlock(!0),createElementBlock(Fragment,null,renderList(splitMarkers.value,split=>(openBlock(),createElementBlock(`g`,{key:split.key,style:normalizeStyle(`transform: translateX(${split.x})`)},[createBaseVNode(`rect`,{x:-(tickSize/2)+`px`,y:`calc(`+barCenterY+`% - `+tickSize/2+`px)`,width:tickSize+`px`,height:tickSize+`px`,"stroke-width":tickStrokeWidth,fill:`#202020`,stroke:`#ffffff`},null,8,_hoisted_5$78),createBaseVNode(`text`,_hoisted_6$64,[createBaseVNode(`tspan`,_hoisted_7$56,toDisplayString(split.label.val),1),createBaseVNode(`tspan`,_hoisted_8$46,toDisplayString(split.label.unit),1)])],4))),128)),createBaseVNode(`g`,{style:normalizeStyle(`transform: translateX(${barEndX})`)},[createBaseVNode(`rect`,{x:-(tickSize/2)+`px`,y:`calc(`+barCenterY+`% - `+tickSize/2+`px)`,width:tickSize+`px`,height:tickSize+`px`,"stroke-width":tickStrokeWidth,fill:`#202020`,stroke:`#ffffff`},null,8,_hoisted_9$41),createBaseVNode(`text`,_hoisted_10$34,[finalSplitLabel.value?(openBlock(),createElementBlock(`tspan`,_hoisted_11$30,toDisplayString(finalSplitLabel.value.val),1)):createCommentVNode(``,!0),createBaseVNode(`tspan`,_hoisted_12$24,toDisplayString(finalSplitLabel.value.unit),1)])],4),createBaseVNode(`g`,{style:normalizeStyle(`transform: translateX(${currentX.value})`)},[createBaseVNode(`rect`,{x:-(trackingRectSize/2)+`px`,y:`calc(`+barCenterY+`% - `+trackingRectSize/2+`px)`,width:trackingRectSize+`px`,height:trackingRectSize+`px`,fill:`var(--theme-color)`},null,8,_hoisted_13$21)],4)]))]))}},DistanceWidgetSVGRect_default=__plugin_vue_export_helper_default(_sfc_main$168,[[`__scopeId`,`data-v-9c6ef477`]]);function rallyStageThemeColor(withAlpha=null){return`#009a1a${withAlpha===!0?`a0`:``}`}var _hoisted_1$149={key:0,class:`rally-stage-timing-app`},_sfc_main$167={__name:`appStageProgress`,setup(__props){useCssVars(_ctx=>({v708a5eb2:themeColor.value}));let{lua}=useBridge();reactive({env:window.beamng&&!window.beamng.shipping,vue:!1});let ActiveState={INACTIVE:`inactive`,VEHICLE_PROXIMITY:`vehicleProximity`,STAGE_ACTIVE:`stageActive`,COUNTDOWN:`countdown`},rallyClockData=reactive({wallClockSecs:null,epochTime:null,day:null,totalPenalty:0,totalTime:0,use24hFormat:!0,canSkipTimeControls:!1,canSkipCountdown:!1,isNgrcMode:!1}),activeState=ref(ActiveState.INACTIVE),vehicleProximityData=reactive({isNear:!1,distance:0,distanceToPlane:0,isStopped:!1,isFrozen:!1,usingGroundMarkerDistance:!1}),scheduleData=reactive({label:null,eventType:null,ssLabel:null,eventWallClockStart:null,eventWallClockEnd:null,timeDiff:null,timeDiffWithEnd:null,lateness:null,penalty:0,hasPenalty:!1,canIncurLatePenalty:!1}),stageData=reactive({currentSSTime:null,isActive:!1,isComplete:!1,splits:[],label:null,completion:{distPct:0},unit:`km`}),themeColor=computed(()=>rallyStageThemeColor()),streamsList$1=[`rallyLoop`],streamBuffer={rallyLoop:null},rafId=null;function processStreamUpdates(){if(streamBuffer.rallyLoop){let data=streamBuffer.rallyLoop;activeState.value=data.activeState||ActiveState.INACTIVE,data.rallyClock&&Object.assign(rallyClockData,data.rallyClock),data.scheduleData&&Object.assign(scheduleData,data.scheduleData),data.stageData&&Object.assign(stageData,data.stageData),data.vehicleProximity&&Object.assign(vehicleProximityData,data.vehicleProximity),streamBuffer.rallyLoop=null}rafId=requestAnimationFrame(processStreamUpdates)}rafId=requestAnimationFrame(processStreamUpdates),useStreams(streamsList$1,streams=>{streams.rallyLoop&&(streamBuffer.rallyLoop=streams.rallyLoop)}),onMounted(()=>{}),onUnmounted(()=>{rafId&&cancelAnimationFrame(rafId)});function shouldShowApp(){return!0}return(_ctx,_cache)=>(openBlock(),createBlock(Transition,{name:`fade`},{default:withCtx(()=>[shouldShowApp()?(openBlock(),createElementBlock(`div`,_hoisted_1$149,[createVNode(DistanceWidgetSVGRect_default,{"dist-pct":stageData.completion.distPct,"total-dist-m":stageData.completion.totalDistM,splits:stageData.splits,"theme-color":themeColor.value,unit:stageData.unit},null,8,[`dist-pct`,`total-dist-m`,`splits`,`theme-color`,`unit`])])):createCommentVNode(``,!0)]),_:1}))}},appStageProgress_default=__plugin_vue_export_helper_default(_sfc_main$167,[[`__scopeId`,`data-v-a8eba296`]]);function formatSSTime(seconds,activeState){if(activeState===`inactive`)return`--:--:--`;let roundedSeconds=Math.round(seconds*10)/10,hours=Math.floor(roundedSeconds/3600),minutes=Math.floor(roundedSeconds%3600/60),secs=Math.floor(roundedSeconds%60),tenths=Math.round(roundedSeconds%1*10)%10;return hours>0?`${hours}:${String(minutes).padStart(2,`0`)}:${String(secs).padStart(2,`0`)}.${tenths}`:minutes>0?`${minutes}:${String(secs).padStart(2,`0`)}.${tenths}`:`${secs}.${tenths}`}var _hoisted_1$148={key:0,class:`rally-stage-timing-app`},_hoisted_2$122={class:`section-active-stage`},_hoisted_3$110={class:`stage-header`},_hoisted_4$89={class:`stage-time`},_hoisted_5$77={key:0,class:`splits-header`},_hoisted_6$63={key:1,class:`stage-splits`},_hoisted_7$55={class:`stage-split-label`},_hoisted_8$45={class:`stage-split-label-unit`},_hoisted_9$40={class:`stage-split-time`},_hoisted_10$33=[`src`],_sfc_main$166={__name:`appStageTiming`,setup(__props){let{lua}=useBridge(),ActiveState={INACTIVE:`inactive`,VEHICLE_PROXIMITY:`vehicleProximity`,STAGE_ACTIVE:`stageActive`,COUNTDOWN:`countdown`},rallyClockData=reactive({wallClockSecs:null,epochTime:null,day:null,totalPenalty:0,totalTime:0,use24hFormat:!0,canSkipTimeControls:!1,canSkipCountdown:!1,isNgrcMode:!1}),activeState=ref(ActiveState.INACTIVE),vehicleProximityData=reactive({isNear:!1,distance:0,distanceToPlane:0,isStopped:!1,isFrozen:!1,usingGroundMarkerDistance:!1}),scheduleData=reactive({label:null,eventType:null,ssLabel:null,eventWallClockStart:null,eventWallClockEnd:null,timeDiff:null,timeDiffWithEnd:null,lateness:null,penalty:0,hasPenalty:!1,canIncurLatePenalty:!1}),stageData=reactive({currentSSTime:null,isActive:!1,isComplete:!1,splits:[],label:null,completion:{distM:0,distPct:0}});computed(()=>rallyStageThemeColor(!0));let completedSplits=computed(()=>stageData.splits?.filter(split=>split.time!=null)||[]),splitUnit=computed(()=>`km`),streamsList$1=[`rallyLoop`],streamBuffer={rallyLoop:null},rafId=null;function processStreamUpdates(){if(streamBuffer.rallyLoop){let data=streamBuffer.rallyLoop;activeState.value=data.activeState||ActiveState.INACTIVE,data.rallyClock&&Object.assign(rallyClockData,data.rallyClock),data.scheduleData&&Object.assign(scheduleData,data.scheduleData),data.stageData&&Object.assign(stageData,data.stageData),data.vehicleProximity&&Object.assign(vehicleProximityData,data.vehicleProximity),streamBuffer.rallyLoop=null}rafId=requestAnimationFrame(processStreamUpdates)}rafId=requestAnimationFrame(processStreamUpdates),useStreams(streamsList$1,streams=>{streams.rallyLoop&&(streamBuffer.rallyLoop=streams.rallyLoop)}),onMounted(()=>{}),onUnmounted(()=>{rafId&&cancelAnimationFrame(rafId)});function shouldShowApp(){return!0}return(_ctx,_cache)=>(openBlock(),createBlock(Transition,{name:`fade`},{default:withCtx(()=>[shouldShowApp()?(openBlock(),createElementBlock(`div`,_hoisted_1$148,[createBaseVNode(`div`,_hoisted_2$122,[createBaseVNode(`div`,_hoisted_3$110,`STAGE `+toDisplayString(stageData.label)+` / `+toDisplayString(scheduleData.totalSSCount),1),createBaseVNode(`div`,_hoisted_4$89,toDisplayString(unref(formatSSTime)(stageData.currentSSTime,activeState.value)),1),completedSplits.value.length>0?(openBlock(),createElementBlock(`div`,_hoisted_5$77,`SPLITS`)):createCommentVNode(``,!0),completedSplits.value.length>0?(openBlock(),createElementBlock(`div`,_hoisted_6$63,[(openBlock(!0),createElementBlock(Fragment,null,renderList(completedSplits.value,split=>(openBlock(),createElementBlock(`div`,{class:`stage-split`,key:split.pathnodeId},[createBaseVNode(`div`,_hoisted_7$55,[createBaseVNode(`span`,null,toDisplayString(split.splitLabel),1),createBaseVNode(`span`,_hoisted_8$45,toDisplayString(splitUnit.value),1)]),createBaseVNode(`div`,_hoisted_9$40,toDisplayString(unref(formatSSTime)(split.time,activeState.value)),1)]))),128))])):createCommentVNode(``,!0),rallyClockData.isNgrcMode?(openBlock(),createElementBlock(`img`,{key:2,class:`stage-ngrc-badge`,src:unref(getAssetURL)(`images/ngrc_logo_dark_128x40.png`),alt:`NGRC`},null,8,_hoisted_10$33)):createCommentVNode(``,!0)])])):createCommentVNode(``,!0)]),_:1}))}},appStageTiming_default=__plugin_vue_export_helper_default(_sfc_main$166,[[`__scopeId`,`data-v-cea09957`]]),_hoisted_1$147={class:`gameplay-apps`},gameplayAppsFlashMessage=`GameplayAppsFlashMessage`,_sfc_main$165={__name:`gameplayApps`,setup(__props){let{lua}=useBridge(),events$3=useEvents(),isDrift=ref(!1),isDragStaging=ref(!1),isRally=ref(!1),isPointsBar=ref(!1),isFlashMessage=ref(!1),isCountdown=ref(!1),appStates={drift:isDrift,drag:isDragStaging,rally:isRally,pointsBar:isPointsBar,flashMessage:isFlashMessage,countdown:isCountdown},setAppVisibility=data=>{data.appId&&appStates[data.appId]&&(appStates[data.appId].value=data.visible),data.hideAll&&Object.values(appStates).forEach(state=>state.value=!1)},loadInitialVisibility=async()=>{try{let visibleApps=await lua.ui_gameplayAppContainers.getVisibleApps(`gameplayApps`);Object.values(appStates).forEach(state=>state.value=!1),Array.isArray(visibleApps)&&visibleApps.forEach(appId=>{appStates[appId]&&(appStates[appId].value=!0)})}catch{}};return onMounted(()=>{events$3.on(`setGameplayAppVisibility`,setAppVisibility),lua.ui_gameplayAppContainers.onGameplayAppContainerMounted(),loadInitialVisibility()}),onUnmounted(()=>{events$3.off(`setGameplayAppVisibility`,setAppVisibility),lua.ui_gameplayAppContainers.onGameplayAppContainerUnmounted()}),(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$147,[withDirectives((openBlock(),createBlock(resolveDynamicComponent(unref(app_default)),mergeProps({class:`app`},_ctx.$attrs),null,16)),[[vShow,isPointsBar.value]]),withDirectives((openBlock(),createBlock(resolveDynamicComponent(unref(app_default$28)),mergeProps({class:`app rally`},_ctx.$attrs),null,16)),[[vShow,isRally.value]]),withDirectives((openBlock(),createBlock(resolveDynamicComponent(unref(app_default$13)),mergeProps({class:`app`,showFlash:!1},_ctx.$attrs),null,16)),[[vShow,isDrift.value]]),withDirectives((openBlock(),createBlock(resolveDynamicComponent(unref(app_default$11)),mergeProps({class:`app`,showFlash:!1},_ctx.$attrs),null,16)),[[vShow,isDragStaging.value]]),withDirectives((openBlock(),createBlock(resolveDynamicComponent(unref(flashMessageApp_default)),mergeProps({class:`app flash-message`,"message-source":gameplayAppsFlashMessage},_ctx.$attrs),null,16)),[[vShow,isFlashMessage.value]]),withDirectives((openBlock(),createBlock(resolveDynamicComponent(unref(countdownApp_default)),mergeProps({class:`countdown`},_ctx.$attrs),null,16)),[[vShow,isCountdown.value]])]))}},gameplayApps_default=__plugin_vue_export_helper_default(_sfc_main$165,[[`__scopeId`,`data-v-8ac28a96`]]),_hoisted_1$146={class:`messages-tasks-apps`},_sfc_main$164={__name:`messagesTasksApps`,setup(__props){let{lua}=useBridge(),events$3=useEvents(),isMessages=ref(!1),isTasks=ref(!1),appStates={messages:isMessages,tasks:isTasks},setAppVisibility=data=>{data.appId&&appStates[data.appId]&&(appStates[data.appId].value=data.visible),data.hideAll&&Object.values(appStates).forEach(state=>{state.value=!1})},loadInitialVisibility=async()=>{try{let visibleApps=await lua.ui_messagesTasksAppContainers.getVisibleApps(`messagesTasksApps`);Object.values(appStates).forEach(state=>{state.value=!1}),Array.isArray(visibleApps)&&visibleApps.forEach(appId=>{appStates[appId]&&(appStates[appId].value=!0)})}catch{}};return onMounted(()=>{events$3.on(`setMessagesTasksAppVisibility`,setAppVisibility),lua.ui_messagesTasksAppContainers.onMessagesTasksAppContainerMounted(),loadInitialVisibility()}),onUnmounted(()=>{events$3.off(`setMessagesTasksAppVisibility`,setAppVisibility),lua.ui_messagesTasksAppContainers.onMessagesTasksAppContainerUnmounted()}),(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$146,[withDirectives((openBlock(),createBlock(resolveDynamicComponent(unref(app_default$27)),mergeProps({class:`app`},_ctx.$attrs),null,16)),[[vShow,isTasks.value]]),withDirectives((openBlock(),createBlock(resolveDynamicComponent(unref(app_default$32)),mergeProps({class:`app`},_ctx.$attrs),null,16)),[[vShow,isMessages.value]])]))}},messagesTasksApps_default=__plugin_vue_export_helper_default(_sfc_main$164,[[`__scopeId`,`data-v-0ac32403`]]),_sfc_main$163={__name:`countdownApp`,setup(__props){let events$3=useEvents();function convertLegacyMessage(data){return Array.isArray(data)?data.map(item=>({msg:typeof item[0]==`object`?item[0].txt:item[0],ttl:item[1],luaCall:typeof item[2]==`string`?item[2]:void 0,jsCallback:typeof item[2]==`function`?item[2]:void 0,big:item[3]??!1})):data}return onMounted(()=>{events$3.on(`ScenarioFlashMessage`,data=>{let convertedData=convertLegacyMessage(data);if(Array.isArray(convertedData)&&convertedData.length>0){let lastMessage=convertedData[convertedData.length-1];lastMessage.msg===`GO!`&&(lastMessage.jsCallback=()=>{events$3.emit(`CountdownEnded`)})}events$3.emit(`CountdownMessage`,convertedData)}),events$3.on(`ScenarioNotRunning`,()=>{events$3.emit(`CountdownMessage`,{msg:``,ttl:0})})}),(_ctx,_cache)=>(openBlock(),createBlock(bngFlashMessage_default,{"message-source":`CountdownMessage`}))}},countdownApp_default=__plugin_vue_export_helper_default(_sfc_main$163,[[`__scopeId`,`data-v-8ddc025c`]]),_sfc_main$162={__name:`flashMessageApp`,setup(__props){let events$3=useEvents();return onMounted(()=>{events$3.on(`ScenarioFlashMessage`,data=>{let convertedData=Array.isArray(data)?data.map(item=>({msg:typeof item[0]==`object`?item[0].txt:item[0],ttl:item[1],luaCall:typeof item[2]==`string`?item[2]:void 0,jsCallback:typeof item[2]==`function`?item[2]:void 0,big:item[3]??!1})):data;events$3.emit(`SimpleFlashMessage`,convertedData)}),events$3.on(`ScenarioNotRunning`,()=>{events$3.emit(`SimpleFlashMessage`,{msg:``,ttl:0})})}),(_ctx,_cache)=>(openBlock(),createBlock(bngFlashMessage_default,{"message-source":`SimpleFlashMessage`}))}},flashMessageApp_default=__plugin_vue_export_helper_default(_sfc_main$162,[[`__scopeId`,`data-v-48db34d3`]]),_hoisted_1$145={class:`generic-mission-data`},_sfc_main$161={__name:`bngGenericMissionData`,setup(__props){let events$3=useEvents(),{lua}=useBridge(),displayElements=ref([]),getElementValue=element=>element.minutes||element.seconds?``:typeof element.txt==`number`?element.txt:element.style===`text`||element.style===void 0?$translate.instant(element.txt):`Error: Unsupported style`,handleMissionDataChanged=data=>{if(data){for(;displayElements.value.length<=data.index;)displayElements.value.push(null);displayElements.value[data.index]=data.element}},handleMissionDataReset=()=>{displayElements.value=[]};return onMounted(()=>{events$3.on(`SetGenericMissionData`,handleMissionDataChanged),events$3.on(`SetGenericMissionDataResetAll`,handleMissionDataReset),lua.extensions.load(`ui_apps_genericMissionData`),lua.ui_apps_genericMissionData.sendAllData()}),(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$145,[(openBlock(!0),createElementBlock(Fragment,null,renderList(displayElements.value,(element,index)=>(openBlock(),createElementBlock(Fragment,{key:index},[element?(openBlock(),createBlock(bngSimpleDataDisplay_default,{key:0,label:_ctx.$tt(element.title),value:getElementValue(element),icon:element.icon,minutes:element.minutes,seconds:element.seconds,milliseconds:element.milliseconds,class:`mission-data-item`},null,8,[`label`,`value`,`icon`,`minutes`,`seconds`,`milliseconds`])):createCommentVNode(``,!0)],64))),128))]))}},bngGenericMissionData_default=__plugin_vue_export_helper_default(_sfc_main$161,[[`__scopeId`,`data-v-1cdb0dd5`]]),_hoisted_1$144={class:`controls-container`},_sfc_main$160={__name:`app`,setup(__props){let{$game}=useLibStore();return ref(!0),(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$144,[createVNode(unref(bngAppBindingDisplay_default))]))}},app_default$29=__plugin_vue_export_helper_default(_sfc_main$160,[[`__scopeId`,`data-v-66fafb5f`]]),_hoisted_1$143={class:`main-container-grid`},_hoisted_2$121={class:`points-display`},_hoisted_3$109={class:`star-wrapper`},_sfc_main$159={__name:`app`,setup(__props){let{lua}=useBridge(),fillPercent=ref(0),pointsLabel=ref(`0`),thresholdPercentages=ref([]),thresholdsReached=ref([]),thresholdCount=ref(0),thresholdIndices=computed(()=>Array.from({length:thresholdCount.value},(_,index)=>index));onMounted(()=>{lua.extensions.load(`ui_apps_pointsBar`),lua.ui_apps_pointsBar.requestAllData()}),onUnmounted(()=>{});let streamsList$1=[`pointsBar`];return useStreams(streamsList$1,streams=>{for(let stream of streamsList$1)if(!streams[stream])return;fillPercent.value=streams.pointsBar.fillPercent,pointsLabel.value=streams.pointsBar.pointsLabel,streams.pointsBar.thresholdPercentages&&Array.isArray(streams.pointsBar.thresholdPercentages)&&(thresholdPercentages.value=streams.pointsBar.thresholdPercentages),streams.pointsBar.thresholdsReached&&Array.isArray(streams.pointsBar.thresholdsReached)&&(thresholdsReached.value=streams.pointsBar.thresholdsReached),thresholdCount.value=streams.pointsBar.thresholdCount}),(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$143,[createBaseVNode(`div`,{class:`progress-bar-container`,style:normalizeStyle({"--threshold-percentage":thresholdPercentages.value[0]||0})},[createBaseVNode(`div`,_hoisted_2$121,toDisplayString(_ctx.$t(pointsLabel.value)),1),createBaseVNode(`div`,{class:`progress-bar`,style:normalizeStyle({width:`${fillPercent.value*100}%`})},null,4),(openBlock(!0),createElementBlock(Fragment,null,renderList(thresholdIndices.value,i=>(openBlock(),createElementBlock(`div`,{key:i,class:normalizeClass([`limit-marker`,{passed:thresholdsReached.value[i]}]),style:normalizeStyle({left:`${thresholdPercentages.value[i]}%`})},[createBaseVNode(`div`,_hoisted_3$109,[createVNode(unref(bngIcon_default),{type:thresholdsReached.value[i]?unref(icons).star:unref(icons).starSecondary,class:normalizeClass([`star-icon`,{passed:thresholdsReached.value[i]}])},null,8,[`type`,`class`])])],6))),128))],4)]))}},app_default=__plugin_vue_export_helper_default(_sfc_main$159,[[`__scopeId`,`data-v-4e2c4ac3`]]),_hoisted_1$142={key:0,class:`minimap-container-additional-info top`},_hoisted_2$120={key:0},_hoisted_3$108={key:1,class:`minimap-container-additional-info bottom`},_hoisted_4$88={key:2},_hoisted_5$76={key:0,class:`minimap-container-additional-info top round`},_hoisted_6$62={key:0},_hoisted_7$54={key:1,class:`minimap-container-additional-info bottom round`},_hoisted_8$44={key:2},transformUpdateAttempts=15,_sfc_main$158={__name:`app`,setup(__props){useCssVars(_ctx=>({v01db66c6:squareSize.value,v32146572:minimapSize.value}));let{lua}=useBridge(),events$3=useEvents(),route=useRoute(),$globalStore=inject(`$globalStore`),uiVisible=ref(!0),initialising=ref(!1),initialised=ref(!1),minimapMode=ref(`circle`),minimapContainerRef=ref(null),containerRef=ref(null);ref(null),ref(null);let resizeObserver=ref(null),mapMetrics=reactive({x:0,y:0,width:0,height:0,xRel:0,yRel:0,widthRel:0,heightRel:0}),allowedRoutes=[`/play`,``],showMinimap=computed(()=>uiVisible.value&&!loadingScreen.shown&&$globalStore.__uiAppsShown&&!$globalStore.__introPopupShown&&!popupsView.popups&&!popupsView.activities&&allowedRoutes.includes(route.path)),additionalInfo=reactive({distToTarget:null,locationName:null,policeMode:`disabled`}),hasTopInfo=computed(()=>!!additionalInfo.locationName),hasBottomInfo=computed(()=>!!(additionalInfo.distToTarget||additionalInfo.policeMode===`visibleToPolice`||additionalInfo.policeMode===`hiddenFromPolice`));watch(hasTopInfo,val=>{showMinimap.value&&requestAnimationFrame(updateDrawTransform)}),watch(hasBottomInfo,val=>{showMinimap.value&&requestAnimationFrame(updateDrawTransform)});let transformUpdateAttempt=0,minimapSize=ref(`100%`),minimapShift=ref(`0px`),squareSize=ref(`100%`);async function updateDrawTransform(){if(minimapMode.value===`circle`&&minimapContainerRef.value){let rect$1=minimapContainerRef.value.getBoundingClientRect(),size$3=Math.min(rect$1.width,rect$1.height),sizepx=size$3+`px`;minimapSize.value!==sizepx&&(minimapSize.value=sizepx,rect$1.width>rect$1.height?minimapShift.value=-(rect$1.width-size$3)/2+`px`:minimapShift.value=`0px`,await nextTick())}if(!initialised.value||!showMinimap.value||!containerRef.value)return;let screen$1={width:window.innerWidth,height:window.innerHeight,scrollX:window.scrollX,scrollY:window.scrollY},rect=containerRef.value.getBoundingClientRect();mapMetrics.x=rect.left+screen$1.scrollX,mapMetrics.y=rect.top+screen$1.scrollY,mapMetrics.width=rect.width,mapMetrics.height=rect.height,mapMetrics.xRel=mapMetrics.x/screen$1.width,mapMetrics.yRel=mapMetrics.y/screen$1.height,mapMetrics.widthRel=mapMetrics.width/screen$1.width,mapMetrics.heightRel=mapMetrics.height/screen$1.height;let keys=[`xRel`,`yRel`,`widthRel`,`heightRel`];if(keys.some(key=>mapMetrics[key]<0||mapMetrics[key]>1)||keys.every(key=>mapMetrics[key]===0)){transformUpdateAttempt++,transformUpdateAttempt{val?updateDrawTransform():initialised.value&&sendTransformToLua(!1)}),watch([initialised,containerRef],()=>{updateDrawTransform(),containerRef.value&&!resizeObserver.value&&(resizeObserver.value=new ResizeObserver(()=>{updateDrawTransform()}),resizeObserver.value.observe(containerRef.value))},{immediate:!0}),onMounted(()=>{window.addEventListener(`scroll`,updateDrawTransform),window.addEventListener(`resize`,updateDrawTransform),events$3.on(`onCefVisibilityChanged`,visible=>{uiVisible.value=visible,nextTick(updateDrawTransform)}),initMinimap()}),onUnmounted(()=>{let wasInitialised=initialised.value;initialised.value=!1,window.removeEventListener(`scroll`,updateDrawTransform),window.removeEventListener(`resize`,updateDrawTransform),resizeObserver.value&&=(resizeObserver.value.disconnect(),null),wasInitialised&&sendTransformToLua(!1)}),useStreams([`minimap`],streams=>{streams.minimap&&(additionalInfo.distToTarget=streams.minimap.distToTarget,additionalInfo.locationName=streams.minimap.locationName,additionalInfo.policeMode=streams.minimap.policeMode)}),(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,{ref_key:`minimapContainerRef`,ref:minimapContainerRef,class:normalizeClass([`minimap-container-wrapper`,{[`police-`+additionalInfo.policeMode]:minimapMode.value===`rect`,round:minimapMode.value===`circle`}]),onClick:updateDrawTransform},[minimapMode.value===`rect`?(openBlock(),createElementBlock(Fragment,{key:0},[hasTopInfo.value?(openBlock(),createElementBlock(`div`,_hoisted_1$142,[additionalInfo.locationName?(openBlock(),createElementBlock(`span`,_hoisted_2$120,toDisplayString(additionalInfo.locationName),1)):createCommentVNode(``,!0)])):createCommentVNode(``,!0),createBaseVNode(`div`,{class:normalizeClass([`minimap-container`,{"round-bottom":!hasBottomInfo.value,"round-top":!hasTopInfo.value}]),ref_key:`containerRef`,ref:containerRef},null,2),hasBottomInfo.value?(openBlock(),createElementBlock(`div`,_hoisted_3$108,[additionalInfo.policeMode===`visibleToPolice`?(openBlock(),createBlock(unref(bngIcon_default),{key:0,type:`eyeSolidOpened`})):createCommentVNode(``,!0),additionalInfo.policeMode===`hiddenFromPolice`?(openBlock(),createBlock(unref(bngIcon_default),{key:1,type:`eyeSolidClosed`})):createCommentVNode(``,!0),additionalInfo.distToTarget?(openBlock(),createElementBlock(`span`,_hoisted_4$88,toDisplayString(additionalInfo.distToTarget),1)):createCommentVNode(``,!0),additionalInfo.distToTarget?(openBlock(),createBlock(unref(bngIcon_default),{key:3,class:``,type:`mapPoint`})):createCommentVNode(``,!0)])):createCommentVNode(``,!0)],64)):minimapMode.value===`circle`?(openBlock(),createElementBlock(Fragment,{key:1},[hasTopInfo.value?(openBlock(),createElementBlock(`div`,_hoisted_5$76,[additionalInfo.locationName?(openBlock(),createElementBlock(`span`,_hoisted_6$62,toDisplayString(additionalInfo.locationName),1)):createCommentVNode(``,!0)])):createCommentVNode(``,!0),createBaseVNode(`div`,{class:normalizeClass([`minimap-container round`,{[`police-`+additionalInfo.policeMode]:!0}]),ref_key:`containerRef`,ref:containerRef},null,2),hasBottomInfo.value?(openBlock(),createElementBlock(`div`,_hoisted_7$54,[additionalInfo.policeMode===`visibleToPolice`?(openBlock(),createBlock(unref(bngIcon_default),{key:0,type:`eyeSolidOpened`})):createCommentVNode(``,!0),additionalInfo.policeMode===`hiddenFromPolice`?(openBlock(),createBlock(unref(bngIcon_default),{key:1,type:`eyeSolidClosed`})):createCommentVNode(``,!0),additionalInfo.distToTarget?(openBlock(),createElementBlock(`span`,_hoisted_8$44,toDisplayString(additionalInfo.distToTarget),1)):createCommentVNode(``,!0),additionalInfo.distToTarget?(openBlock(),createBlock(unref(bngIcon_default),{key:3,class:``,type:`mapPoint`})):createCommentVNode(``,!0)])):createCommentVNode(``,!0)],64)):createCommentVNode(``,!0)],2))}},app_default$30=__plugin_vue_export_helper_default(_sfc_main$158,[[`__scopeId`,`data-v-4d3d3a71`]]),_hoisted_1$141={class:`hotlapping-app`},_hoisted_2$119={class:`hotlapping-header`},_hoisted_3$107={class:`header-flex`},_hoisted_4$87={class:`hotlapping-content`},_hoisted_5$75={key:0,class:`grid-header`},_hoisted_6$61={class:`grid-item current-item`},_hoisted_7$53={class:`grid-item current-item`},_hoisted_8$43={class:`grid-item current-item`},_sfc_main$157={__name:`app`,setup(__props){useEvents();let fastData=ref({}),slowData=ref({}),staticData=ref({}),placementData=ref({}),displayMode=ref(`combined`);onMounted(()=>{useStreams([`lapTimes_fast`,`lapTimes_slow`,`lapTimes_static`,`lapTimes_placement`],streams=>{streams.lapTimes_fast&&(fastData.value=streams.lapTimes_fast),streams.lapTimes_slow&&(slowData.value=streams.lapTimes_slow),streams.lapTimes_static&&(staticData.value=streams.lapTimes_static),streams.lapTimes_placement&&(placementData.value=streams.lapTimes_placement)})}),onUnmounted(()=>{});let getLapValue=()=>`${slowData.value?.currentLap||0}/${staticData.value?.totalLaps||0}`,getSegmentValue=()=>`${slowData.value?.currentSegment||0}/${staticData.value?.totalSegments||0}`,getTotalRaceTime=()=>fastData.value?.currentTimeFormatted||`00:00.000`,parseTimeString=timeStr=>{if(!timeStr)return{minutes:`00`,seconds:`00`,milliseconds:`000`};let parts=timeStr.split(`:`);if(parts.length===2){let minutes=parts[0].padStart(2,`0`),secondsParts=parts[1].split(`.`);return{minutes,seconds:secondsParts[0].padStart(2,`0`),milliseconds:secondsParts[1]?secondsParts[1].padEnd(3,`0`):`000`}}else{let secondsParts=parts[0].split(`.`);return{minutes:`00`,seconds:secondsParts[0].padStart(2,`0`),milliseconds:secondsParts[1]?secondsParts[1].padEnd(3,`0`):`000`}}},getTotalRaceTimeMinutes=()=>parseTimeString(getTotalRaceTime()).minutes,getTotalRaceTimeSeconds=()=>parseTimeString(getTotalRaceTime()).seconds,getTotalRaceTimeMilliseconds=()=>parseTimeString(getTotalRaceTime()).milliseconds,isRacing=()=>slowData.value?.status===`started`||slowData.value?.status===`paused`,getCurrentLapDiffClass=()=>{let flavor=fastData.value?.currentLapDiffToBestFlavor;return flavor===`better`?`diff-better`:flavor===`worse`?`diff-worse`:`diff-neutral`},getDiffClass=(flavor,value)=>!value||value===``||value===`N/A`?`diff-neutral`:flavor===`better`?`diff-better`:flavor===`worse`?`diff-worse`:`diff-neutral`,shouldShowToggleIcon=()=>(staticData.value?.totalLaps||0)>1,shouldShowSegmentsByDefault=()=>(staticData.value?.totalLaps||0)<=1,cycleDisplayMode=()=>{if(shouldShowToggleIcon()){let modes=[`combined`,`laps`,`segments`];displayMode.value=modes[(modes.indexOf(displayMode.value)+1)%modes.length]}},getTableHeaderLabel=()=>displayMode.value===`combined`?`Combined`:displayMode.value===`segments`?`Split`:`Lap`,shouldHideVsPrevBest=()=>(staticData.value?.totalLaps||0)<=1,getCurrentTimeFormatted=()=>displayMode.value===`segments`||shouldShowSegmentsByDefault()&&displayMode.value===`combined`?fastData.value?.currentSegmentTimeFormatted:fastData.value?.currentLapTimeFormatted,getCurrentItemNumber=()=>displayMode.value===`segments`||shouldShowSegmentsByDefault()&&displayMode.value===`combined`?`${slowData.value?.currentLap||1}-${slowData.value?.currentSegment||1}`:slowData.value?.currentLap||1,getCurrentDiff=()=>displayMode.value===`segments`||shouldShowSegmentsByDefault()&&displayMode.value===`combined`?fastData.value?.currentSegmentDiffToBestFormatted||``:fastData.value?.currentLapDiffToBestFormatted||``,getCurrentTotalTime=()=>fastData.value?.currentTimeFormatted||``,getFilteredCombinedItems=()=>{if(!slowData.value||!slowData.value.combinedTimes||!Array.isArray(slowData.value.combinedTimes))return[];let filtered=[];return displayMode.value===`combined`?filtered=[...slowData.value.combinedTimes]:displayMode.value===`laps`?filtered=slowData.value.combinedTimes.filter(item=>item.type===`lap`):displayMode.value===`segments`&&(filtered=slowData.value.combinedTimes.filter(item=>item.type===`segment`)),filtered.reverse()},getItemKey=item=>`${item.type}-${item.identifier}`,getItemNumber=item=>item.identifier;return(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$141,[createBaseVNode(`div`,_hoisted_2$119,[createBaseVNode(`div`,_hoisted_3$107,[staticData.value.totalLaps>1?(openBlock(),createBlock(bngSimpleDataDisplay_default,{key:0,class:`header-cell`,label:`Lap`,value:getLapValue()},null,8,[`value`])):createCommentVNode(``,!0),staticData.value.totalSegments>1?(openBlock(),createBlock(bngSimpleDataDisplay_default,{key:1,class:`header-cell`,label:`Split`,value:getSegmentValue()},null,8,[`value`])):createCommentVNode(``,!0),createVNode(bngSimpleDataDisplay_default,{class:`header-cell`,label:`Race Clock`,minutes:getTotalRaceTimeMinutes(),seconds:getTotalRaceTimeSeconds(),milliseconds:getTotalRaceTimeMilliseconds()},null,8,[`minutes`,`seconds`,`milliseconds`])])]),createBaseVNode(`div`,_hoisted_4$87,[createBaseVNode(`div`,{class:normalizeClass([`times-grid`,{"single-lap":shouldHideVsPrevBest()}])},[createBaseVNode(`div`,{class:normalizeClass([`grid-header clickable-header`,{"has-toggle":shouldShowToggleIcon()}]),onClick:_cache[0]||=$event=>shouldShowToggleIcon()?cycleDisplayMode():null},toDisplayString(getTableHeaderLabel()),3),_cache[1]||=createBaseVNode(`div`,{class:`grid-header`},`Duration`,-1),shouldHideVsPrevBest()?createCommentVNode(``,!0):(openBlock(),createElementBlock(`div`,_hoisted_5$75,`Vs prev`)),_cache[2]||=createBaseVNode(`div`,{class:`grid-header`},`Total`,-1),isRacing()&&getCurrentTimeFormatted()?(openBlock(),createElementBlock(Fragment,{key:1},[createBaseVNode(`div`,_hoisted_6$61,toDisplayString(getCurrentItemNumber()),1),createBaseVNode(`div`,_hoisted_7$53,toDisplayString(getCurrentTimeFormatted()),1),shouldHideVsPrevBest()?createCommentVNode(``,!0):(openBlock(),createElementBlock(`div`,{key:0,class:normalizeClass([`grid-item current-item`,getCurrentLapDiffClass()])},toDisplayString(getCurrentDiff()),3)),createBaseVNode(`div`,_hoisted_8$43,toDisplayString(getCurrentTotalTime()),1)],64)):createCommentVNode(``,!0),(openBlock(!0),createElementBlock(Fragment,null,renderList(getFilteredCombinedItems(),item=>(openBlock(),createElementBlock(Fragment,{key:getItemKey(item)},[createBaseVNode(`div`,{class:normalizeClass([`grid-item`,{"best-item left-indicator":item.flavor===`best`,"is-lap":item.type===`lap`}])},toDisplayString(getItemNumber(item)),3),createBaseVNode(`div`,{class:normalizeClass([`grid-item`,{"best-item":item.flavor===`best`}])},toDisplayString(item.durationFormatted),3),shouldHideVsPrevBest()?createCommentVNode(``,!0):(openBlock(),createElementBlock(`div`,{key:0,class:normalizeClass([`grid-item`,[{"best-item":item.flavor===`best`},getDiffClass(item.diffToPreviousFlavor,item.diffToPreviousFormatted)]])},toDisplayString(item.diffToPreviousFormatted||``),3)),createBaseVNode(`div`,{class:normalizeClass([`grid-item`,{"best-item":item.flavor===`best`}])},toDisplayString(item.endTimeFormatted||``),3)],64))),128))],2)])]))}},app_default$31=__plugin_vue_export_helper_default(_sfc_main$157,[[`__scopeId`,`data-v-a9e5d83a`]]),_hoisted_1$140={class:`laptimes-section`},_hoisted_2$118={class:`collapse-icon`},_hoisted_3$106={class:`collapsible-content`},_hoisted_4$86={class:`laptimes-data-grid`},_hoisted_5$74={key:0,class:`data-item`},_hoisted_6$60={class:`value`},_hoisted_7$52={key:1,class:`data-item`},_hoisted_8$42={class:`data-item`},_hoisted_9$39={class:`value`},_hoisted_10$32={class:`data-item`},_hoisted_11$29={class:`value`},_hoisted_12$23={class:`data-item`},_hoisted_13$20={class:`value`},_hoisted_14$20={class:`data-item`},_hoisted_15$19={class:`value`},_hoisted_16$19={key:0,class:`laptimes-data-grid`,style:{"margin-top":`1rem`}},_hoisted_17$15={key:0,class:`data-item`},_hoisted_18$13={key:1,class:`data-item`},_hoisted_19$10={key:1,class:`laptimes-data-grid`,style:{"margin-top":`1rem`}},_hoisted_20$9={key:0,class:`data-item`},_hoisted_21$9={key:1,class:`data-item`},_sfc_main$156={__name:`BasicInfo`,props:{fastData:{type:Object,required:!0},staticData:{type:Object,required:!0},slowData:{type:Object,required:!0}},setup(__props){let isCollapsed=ref(!1),toggleCollapse=()=>{isCollapsed.value=!isCollapsed.value};return(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$140,[createBaseVNode(`h3`,{onClick:toggleCollapse,class:`collapsible-header`},[createBaseVNode(`span`,_hoisted_2$118,toDisplayString(isCollapsed.value?`▶`:`▼`),1),_cache[0]||=createTextVNode(` Race Info `,-1)]),withDirectives(createBaseVNode(`div`,_hoisted_3$106,[createBaseVNode(`div`,_hoisted_4$86,[__props.slowData.status===`started`||__props.slowData.status===`paused`?(openBlock(),createElementBlock(`div`,_hoisted_5$74,[_cache[1]||=createBaseVNode(`span`,{class:`label`},`Current Time:`,-1),createBaseVNode(`span`,_hoisted_6$60,toDisplayString(__props.fastData.currentTimeFormatted||`00:00.000`),1)])):(openBlock(),createElementBlock(`div`,_hoisted_7$52,[_cache[2]||=createBaseVNode(`span`,{class:`label`},`Status:`,-1),createBaseVNode(`span`,{class:normalizeClass([`value`,{active:__props.slowData.status===`started`,paused:__props.slowData.status===`paused`}])},toDisplayString(__props.slowData.status?.toUpperCase()||`STOPPED`),3)])),createBaseVNode(`div`,_hoisted_8$42,[_cache[3]||=createBaseVNode(`span`,{class:`label`},`Lap:`,-1),createBaseVNode(`span`,_hoisted_9$39,toDisplayString(__props.slowData.currentLap||0)+`/`+toDisplayString(__props.staticData.totalLaps||0),1)]),createBaseVNode(`div`,_hoisted_10$32,[_cache[4]||=createBaseVNode(`span`,{class:`label`},`Segment:`,-1),createBaseVNode(`span`,_hoisted_11$29,toDisplayString(__props.slowData.currentSegment||0)+`/`+toDisplayString(__props.staticData.totalSegments||0),1)]),createBaseVNode(`div`,_hoisted_12$23,[_cache[5]||=createBaseVNode(`span`,{class:`label`},`Current Lap Time:`,-1),createBaseVNode(`span`,_hoisted_13$20,toDisplayString(__props.fastData.currentLapTimeFormatted||`00:00.000`),1)]),createBaseVNode(`div`,_hoisted_14$20,[_cache[6]||=createBaseVNode(`span`,{class:`label`},`Current Segment Time:`,-1),createBaseVNode(`span`,_hoisted_15$19,toDisplayString(__props.fastData.currentSegmentTimeFormatted||`00:00.000`),1)])]),__props.fastData.currentLapDiffToBestFormatted||__props.fastData.currentLapDiffToPreviousFormatted?(openBlock(),createElementBlock(`div`,_hoisted_16$19,[__props.fastData.currentLapDiffToBestFormatted?(openBlock(),createElementBlock(`div`,_hoisted_17$15,[_cache[7]||=createBaseVNode(`span`,{class:`label`},`Lap Diff to Best:`,-1),createBaseVNode(`span`,{class:normalizeClass([`value`,`diff-`+(__props.fastData.currentLapDiffToBestFlavor||`default`)])},toDisplayString(__props.fastData.currentLapDiffToBestFormatted),3)])):createCommentVNode(``,!0),__props.fastData.currentLapDiffToPreviousFormatted?(openBlock(),createElementBlock(`div`,_hoisted_18$13,[_cache[8]||=createBaseVNode(`span`,{class:`label`},`Lap Diff to Previous:`,-1),createBaseVNode(`span`,{class:normalizeClass([`value`,`diff-`+(__props.fastData.currentLapDiffToPreviousFlavor||`default`)])},toDisplayString(__props.fastData.currentLapDiffToPreviousFormatted),3)])):createCommentVNode(``,!0)])):createCommentVNode(``,!0),__props.fastData.currentSegmentDiffToBestFormatted||__props.fastData.currentSegmentDiffToPreviousFormatted?(openBlock(),createElementBlock(`div`,_hoisted_19$10,[__props.fastData.currentSegmentDiffToBestFormatted?(openBlock(),createElementBlock(`div`,_hoisted_20$9,[_cache[9]||=createBaseVNode(`span`,{class:`label`},`Segment Diff to Best:`,-1),createBaseVNode(`span`,{class:normalizeClass([`value`,`diff-`+(__props.fastData.currentSegmentDiffToBestFlavor||`default`)])},toDisplayString(__props.fastData.currentSegmentDiffToBestFormatted),3)])):createCommentVNode(``,!0),__props.fastData.currentSegmentDiffToPreviousFormatted?(openBlock(),createElementBlock(`div`,_hoisted_21$9,[_cache[10]||=createBaseVNode(`span`,{class:`label`},`Segment Diff to Previous:`,-1),createBaseVNode(`span`,{class:normalizeClass([`value`,`diff-`+(__props.fastData.currentSegmentDiffToPreviousFlavor||`default`)])},toDisplayString(__props.fastData.currentSegmentDiffToPreviousFormatted),3)])):createCommentVNode(``,!0)])):createCommentVNode(``,!0)],512),[[vShow,!isCollapsed.value]])]))}},BasicInfo_default=__plugin_vue_export_helper_default(_sfc_main$156,[[`__scopeId`,`data-v-4329fa2c`]]),_hoisted_1$139={class:`laptimes-section`},_hoisted_2$117={class:`collapse-icon`},_hoisted_3$105={class:`collapsible-content`},_hoisted_4$85={class:`laptimes-data-grid`,style:{"margin-bottom":`1rem`}},_hoisted_5$73={class:`data-item`},_hoisted_6$59={class:`value`},_hoisted_7$51={key:0,class:`laptimes-data-grid`},_hoisted_8$41={class:`label`},_hoisted_9$38={class:`value`},_sfc_main$155={__name:`BestTimes`,props:{slowData:{type:Object,required:!0}},setup(__props){let props=__props,isCollapsed=ref(!1),toggleCollapse=()=>{isCollapsed.value=!isCollapsed.value},getBestLapDisplay=()=>{let bestTime=props.slowData.bestLapTimeFormatted||`N/A`,bestIndex=props.slowData.bestLapIndex===-1?null:props.slowData.bestLapIndex;return bestTime===`N/A`||bestIndex===null?`N/A`:`${bestTime} in Lap ${bestIndex}`},getBestSegmentDisplayFromData=segmentData=>{if(!segmentData||typeof segmentData!=`object`)return`N/A`;let time=segmentData.time||`N/A`,lap=segmentData.lap;return lap?`${time} in Lap ${lap}`:time};return(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$139,[createBaseVNode(`h3`,{onClick:toggleCollapse,class:`collapsible-header`},[createBaseVNode(`span`,_hoisted_2$117,toDisplayString(isCollapsed.value?`▶`:`▼`),1),_cache[0]||=createTextVNode(` Best Times `,-1)]),withDirectives(createBaseVNode(`div`,_hoisted_3$105,[createBaseVNode(`div`,_hoisted_4$85,[createBaseVNode(`div`,_hoisted_5$73,[_cache[1]||=createBaseVNode(`span`,{class:`label`},`Best Lap:`,-1),createBaseVNode(`span`,_hoisted_6$59,toDisplayString(getBestLapDisplay()),1)])]),__props.slowData.bestSegmentTimesFormatted&&Object.keys(__props.slowData.bestSegmentTimesFormatted).length>0?(openBlock(),createElementBlock(`div`,_hoisted_7$51,[(openBlock(!0),createElementBlock(Fragment,null,renderList(__props.slowData.bestSegmentTimesFormatted,(segmentData,segment)=>(openBlock(),createElementBlock(`div`,{class:`data-item`,key:segment},[createBaseVNode(`span`,_hoisted_8$41,`Best Segment `+toDisplayString(parseInt(segment)+1)+`:`,1),createBaseVNode(`span`,_hoisted_9$38,toDisplayString(getBestSegmentDisplayFromData(segmentData)),1)]))),128))])):createCommentVNode(``,!0)],512),[[vShow,!isCollapsed.value]])]))}},BestTimes_default=__plugin_vue_export_helper_default(_sfc_main$155,[[`__scopeId`,`data-v-3cd1750d`]]),_hoisted_1$138={class:`laptimes-section`},_hoisted_2$116={class:`collapse-icon`},_hoisted_3$104={class:`collapsible-content`},_hoisted_4$84={class:`table-header`},_hoisted_5$72={key:0},_hoisted_6$58={key:1},_hoisted_7$50={key:0,class:`table-row current-lap-row`},_sfc_main$154={__name:`LapTimes`,props:{fastData:{type:Object,required:!0},slowData:{type:Object,required:!0},staticData:{type:Object,required:!0}},setup(__props){let isCollapsed=ref(!1),toggleCollapse=()=>{isCollapsed.value=!isCollapsed.value},getDiffFlavorClass=flavor=>flavor?{"diff-better":flavor===`better`,"diff-worse":flavor===`worse`,"diff-same":flavor===`same`}:``;return(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$138,[createBaseVNode(`h3`,{onClick:toggleCollapse,class:`collapsible-header`},[createBaseVNode(`span`,_hoisted_2$116,toDisplayString(isCollapsed.value?`▶`:`▼`),1),_cache[0]||=createTextVNode(` Lap Times `,-1)]),withDirectives(createBaseVNode(`div`,_hoisted_3$104,[__props.slowData.lapTimes&&__props.slowData.lapTimes.length>0||__props.slowData.status===`started`||__props.slowData.status===`paused`?(openBlock(),createElementBlock(`div`,{key:0,class:normalizeClass([`laptimes-table`,{"single-lap":__props.staticData.totalLaps<=1}])},[createBaseVNode(`div`,_hoisted_4$84,[_cache[1]||=createBaseVNode(`span`,null,`Lap`,-1),_cache[2]||=createBaseVNode(`span`,null,`Time`,-1),_cache[3]||=createBaseVNode(`span`,null,`Duration`,-1),__props.staticData.totalLaps>1?(openBlock(),createElementBlock(`span`,_hoisted_5$72,`Diff to Best`)):createCommentVNode(``,!0),__props.staticData.totalLaps>1?(openBlock(),createElementBlock(`span`,_hoisted_6$58,`Diff to Prev`)):createCommentVNode(``,!0)]),(openBlock(!0),createElementBlock(Fragment,null,renderList(__props.slowData.lapTimes,lap=>(openBlock(),createElementBlock(`div`,{key:lap.lap,class:normalizeClass([`table-row`,{"best-lap":lap.lapFlavor===`best`,"current-lap":lap.isCurrent}])},[createBaseVNode(`span`,null,toDisplayString(lap.lap),1),createBaseVNode(`span`,null,toDisplayString(lap.timeFormatted||lap.endTimeFormatted||`N/A`),1),createBaseVNode(`span`,null,toDisplayString(lap.durationFormatted),1),__props.staticData.totalLaps>1?(openBlock(),createElementBlock(`span`,{key:0,class:normalizeClass(getDiffFlavorClass(lap.diffToBestFlavor))},toDisplayString(lap.diffToBestFormatted||`N/A`),3)):createCommentVNode(``,!0),__props.staticData.totalLaps>1?(openBlock(),createElementBlock(`span`,{key:1,class:normalizeClass(getDiffFlavorClass(lap.diffToPreviousFlavor))},toDisplayString(lap.diffToPreviousFormatted||`N/A`),3)):createCommentVNode(``,!0)],2))),128)),(__props.slowData.status===`started`||__props.slowData.status===`paused`)&&__props.fastData.currentLapTimeFormatted?(openBlock(),createElementBlock(`div`,_hoisted_7$50,[createBaseVNode(`span`,null,toDisplayString(__props.slowData.currentLap||1),1),createBaseVNode(`span`,null,toDisplayString(__props.fastData.currentTimeFormatted),1),createBaseVNode(`span`,null,toDisplayString(__props.fastData.currentLapTimeFormatted),1),__props.staticData.totalLaps>1?(openBlock(),createElementBlock(`span`,{key:0,class:normalizeClass(getDiffFlavorClass(__props.fastData.currentLapDiffToBestFlavor))},toDisplayString(__props.fastData.currentLapDiffToBestFormatted||`N/A`),3)):createCommentVNode(``,!0),__props.staticData.totalLaps>1?(openBlock(),createElementBlock(`span`,{key:1,class:normalizeClass(getDiffFlavorClass(__props.fastData.currentLapDiffToPreviousFlavor))},toDisplayString(__props.fastData.currentLapDiffToPreviousFormatted||`N/A`),3)):createCommentVNode(``,!0)])):createCommentVNode(``,!0)],2)):createCommentVNode(``,!0)],512),[[vShow,!isCollapsed.value]])]))}},LapTimes_default=__plugin_vue_export_helper_default(_sfc_main$154,[[`__scopeId`,`data-v-ed892fc5`]]),_hoisted_1$137={class:`laptimes-section`},_hoisted_2$115={class:`collapse-icon`},_hoisted_3$103={class:`collapsible-content`},_hoisted_4$83={class:`table-header`},_hoisted_5$71={key:0},_hoisted_6$57={key:1},_hoisted_7$49={key:0,class:`table-row current-segment-row`},_sfc_main$153={__name:`SegmentTimes`,props:{fastData:{type:Object,required:!0},slowData:{type:Object,required:!0},staticData:{type:Object,required:!0}},setup(__props){let isCollapsed=ref(!1),toggleCollapse=()=>{isCollapsed.value=!isCollapsed.value},getDiffFlavorClass=flavor=>flavor?{"diff-better":flavor===`better`,"diff-worse":flavor===`worse`,"diff-same":flavor===`same`}:``;return(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$137,[createBaseVNode(`h3`,{onClick:toggleCollapse,class:`collapsible-header`},[createBaseVNode(`span`,_hoisted_2$115,toDisplayString(isCollapsed.value?`▶`:`▼`),1),_cache[0]||=createTextVNode(` Segment Times `,-1)]),withDirectives(createBaseVNode(`div`,_hoisted_3$103,[__props.slowData.segmentTimes&&__props.slowData.segmentTimes.length>0||__props.slowData.status===`started`||__props.slowData.status===`paused`?(openBlock(),createElementBlock(`div`,{key:0,class:normalizeClass([`laptimes-table`,{"single-lap":__props.staticData.totalLaps<=1}])},[createBaseVNode(`div`,_hoisted_4$83,[_cache[1]||=createBaseVNode(`span`,null,`Segment`,-1),_cache[2]||=createBaseVNode(`span`,null,`Time`,-1),_cache[3]||=createBaseVNode(`span`,null,`Duration`,-1),__props.staticData.totalLaps>1?(openBlock(),createElementBlock(`span`,_hoisted_5$71,`Diff to Best`)):createCommentVNode(``,!0),__props.staticData.totalLaps>1?(openBlock(),createElementBlock(`span`,_hoisted_6$57,`Diff to Prev`)):createCommentVNode(``,!0)]),(openBlock(!0),createElementBlock(Fragment,null,renderList(__props.slowData.segmentTimes,segment=>(openBlock(),createElementBlock(`div`,{key:segment.segment,class:normalizeClass([`table-row`,{"best-segment":segment.segmentFlavor===`best`,"current-segment":segment.isCurrent}])},[createBaseVNode(`span`,null,toDisplayString(segment.segment),1),createBaseVNode(`span`,null,toDisplayString(segment.timeFormatted||segment.endTimeFormatted||`N/A`),1),createBaseVNode(`span`,null,toDisplayString(segment.durationFormatted),1),__props.staticData.totalLaps>1?(openBlock(),createElementBlock(`span`,{key:0,class:normalizeClass(getDiffFlavorClass(segment.diffToBestFlavor))},toDisplayString(segment.diffToBestFormatted||`N/A`),3)):createCommentVNode(``,!0),__props.staticData.totalLaps>1?(openBlock(),createElementBlock(`span`,{key:1,class:normalizeClass(getDiffFlavorClass(segment.diffToPreviousFlavor))},toDisplayString(segment.diffToPreviousFormatted||`N/A`),3)):createCommentVNode(``,!0)],2))),128)),(__props.slowData.status===`started`||__props.slowData.status===`paused`)&&__props.fastData.currentSegmentTimeFormatted?(openBlock(),createElementBlock(`div`,_hoisted_7$49,[createBaseVNode(`span`,null,toDisplayString(__props.slowData.currentLap||1)+`-`+toDisplayString(__props.slowData.currentSegment||1),1),createBaseVNode(`span`,null,toDisplayString(__props.fastData.currentTimeFormatted),1),createBaseVNode(`span`,null,toDisplayString(__props.fastData.currentSegmentTimeFormatted),1),__props.staticData.totalLaps>1?(openBlock(),createElementBlock(`span`,{key:0,class:normalizeClass(getDiffFlavorClass(__props.fastData.currentSegmentDiffToBestFlavor))},toDisplayString(__props.fastData.currentSegmentDiffToBestFormatted||`N/A`),3)):createCommentVNode(``,!0),__props.staticData.totalLaps>1?(openBlock(),createElementBlock(`span`,{key:1,class:normalizeClass(getDiffFlavorClass(__props.fastData.currentSegmentDiffToPreviousFlavor))},toDisplayString(__props.fastData.currentSegmentDiffToPreviousFormatted||`N/A`),3)):createCommentVNode(``,!0)])):createCommentVNode(``,!0)],2)):createCommentVNode(``,!0)],512),[[vShow,!isCollapsed.value]])]))}},SegmentTimes_default=__plugin_vue_export_helper_default(_sfc_main$153,[[`__scopeId`,`data-v-3801fbed`]]),_hoisted_1$136={key:0,class:`laptimes-section`},_hoisted_2$114={class:`collapse-icon`},_hoisted_3$102={class:`collapsible-content`},_hoisted_4$82={class:`laptimes-data-grid`,style:{"margin-bottom":`1rem`}},_hoisted_5$70={class:`data-item`},_hoisted_6$56={class:`value`},_hoisted_7$48={class:`data-item`},_hoisted_8$40={class:`value`},_hoisted_9$37={class:`laptimes-table`},_hoisted_10$31={class:`table-header`},_hoisted_11$28={key:0},_hoisted_12$22={key:1},_hoisted_13$19={key:0},_hoisted_14$19={key:1},_sfc_main$152={__name:`Placement`,props:{fastData:{type:Object,required:!0},slowData:{type:Object,required:!0},staticData:{type:Object,required:!0},placementData:{type:Object,required:!0}},setup(__props){let props=__props,isCollapsed=ref(!1),toggleCollapse=()=>{isCollapsed.value=!isCollapsed.value},playerVehicleId=computed(()=>{if(props.placementData.vehicleStates){let vehicleIds=Object.keys(props.placementData.vehicleStates);return vehicleIds.length>0?parseInt(vehicleIds[0]):null}return null}),playerPlacement=computed(()=>!playerVehicleId.value||!props.placementData.placements?null:props.placementData.placements[playerVehicleId.value]),totalRacers=computed(()=>props.placementData.placements?Object.keys(props.placementData.placements).length:0),shouldShowLapColumn=computed(()=>{if(!props.staticData.pathConfig)return!1;let pathConfig=props.staticData.pathConfig;return pathConfig.isClosed&&pathConfig.lapCount>1}),shouldShowSegmentColumn=computed(()=>{if(!props.staticData.pathConfig)return!1;let pathConfig=props.staticData.pathConfig;return!pathConfig.isClosed||pathConfig.isClosed&&pathConfig.lapCount>1}),sortedRacers=computed(()=>{if(!props.placementData.placements||!props.placementData.vehicleStates)return[];let racers=[];return Object.entries(props.placementData.placements).forEach(([vehicleId,placement])=>{let vehicleIdNum=parseInt(vehicleId),vehicleState=props.placementData.vehicleStates[vehicleId],timeDiffData=props.placementData.timeDifferencesToFirst?.[vehicleId],timeDiff=timeDiffData?.timeDifference||0;racers.push({vehicleId:vehicleIdNum,placement,currentLap:vehicleState?.currentLap||0,currentSegment:vehicleState?.currentSegment||0,isPlayer:vehicleIdNum===playerVehicleId.value,timeDiff,timeDiffFormatted:timeDiffData?.timeDifferenceFormatted||`0.000`})}),racers.sort((a$1,b)=>a$1.placement-b.placement)}),getTimeDiffClass=timeDiff=>timeDiff==null?``:{"diff-red":timeDiff>0,"diff-green":timeDiff<0,"diff-neutral":timeDiff===0};return(_ctx,_cache)=>__props.placementData.placements&&Object.keys(__props.placementData.placements).length>1?(openBlock(),createElementBlock(`div`,_hoisted_1$136,[createBaseVNode(`h3`,{onClick:toggleCollapse,class:`collapsible-header`},[createBaseVNode(`span`,_hoisted_2$114,toDisplayString(isCollapsed.value?`▶`:`▼`),1),_cache[0]||=createTextVNode(` Race Positions `,-1)]),withDirectives(createBaseVNode(`div`,_hoisted_3$102,[createBaseVNode(`div`,_hoisted_4$82,[createBaseVNode(`div`,_hoisted_5$70,[_cache[1]||=createBaseVNode(`span`,{class:`label`},`Your Position:`,-1),createBaseVNode(`span`,_hoisted_6$56,toDisplayString(playerPlacement.value||`N/A`),1)]),createBaseVNode(`div`,_hoisted_7$48,[_cache[2]||=createBaseVNode(`span`,{class:`label`},`Total Racers:`,-1),createBaseVNode(`span`,_hoisted_8$40,toDisplayString(totalRacers.value),1)])]),createBaseVNode(`div`,_hoisted_9$37,[createBaseVNode(`div`,_hoisted_10$31,[_cache[3]||=createBaseVNode(`span`,null,`Pos`,-1),_cache[4]||=createBaseVNode(`span`,null,`Vehicle`,-1),shouldShowLapColumn.value?(openBlock(),createElementBlock(`span`,_hoisted_11$28,`Lap`)):createCommentVNode(``,!0),shouldShowSegmentColumn.value?(openBlock(),createElementBlock(`span`,_hoisted_12$22,`Segment`)):createCommentVNode(``,!0),_cache[5]||=createBaseVNode(`span`,null,`Time Diff`,-1)]),(openBlock(!0),createElementBlock(Fragment,null,renderList(sortedRacers.value,(racer,index)=>(openBlock(),createElementBlock(`div`,{key:racer.vehicleId,class:normalizeClass([`table-row`,{"player-row":racer.isPlayer,"leader-row":index===0}])},[createBaseVNode(`span`,null,toDisplayString(racer.placement),1),createBaseVNode(`span`,null,toDisplayString(racer.vehicleId===playerVehicleId.value?`You`:`Vehicle ${racer.vehicleId}`),1),shouldShowLapColumn.value?(openBlock(),createElementBlock(`span`,_hoisted_13$19,toDisplayString(racer.currentLap||0),1)):createCommentVNode(``,!0),shouldShowSegmentColumn.value?(openBlock(),createElementBlock(`span`,_hoisted_14$19,toDisplayString(racer.currentSegment||0),1)):createCommentVNode(``,!0),createBaseVNode(`span`,{class:normalizeClass(getTimeDiffClass(racer.timeDiff))},toDisplayString(racer.timeDiffFormatted),3)],2))),128))])],512),[[vShow,!isCollapsed.value]])])):createCommentVNode(``,!0)}},Placement_default=__plugin_vue_export_helper_default(_sfc_main$152,[[`__scopeId`,`data-v-c2373a09`]]),_hoisted_1$135={class:`laptimes-section`},_hoisted_2$113={class:`collapse-icon`},_hoisted_3$101={class:`collapsible-content`},_hoisted_4$81={class:`raw-data-container`},_hoisted_5$69={key:0,class:`data-stream`},_hoisted_6$55={class:`data-content`},_hoisted_7$47={key:1,class:`data-stream`},_hoisted_8$39={class:`data-content`},_hoisted_9$36={key:2,class:`data-stream`},_hoisted_10$30={class:`data-content`},_hoisted_11$27={key:3,class:`data-stream`},_hoisted_12$21={class:`data-content`},_sfc_main$151={__name:`RawData`,props:{fastData:{type:Object,required:!0},slowData:{type:Object,required:!0},staticData:{type:Object,required:!0},placementData:{type:Object,required:!0}},setup(__props){let isCollapsed=ref(!0),toggleCollapse=()=>{isCollapsed.value=!isCollapsed.value};return(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$135,[createBaseVNode(`h3`,{onClick:toggleCollapse,class:`collapsible-header`},[createBaseVNode(`span`,_hoisted_2$113,toDisplayString(isCollapsed.value?`▶`:`▼`),1),_cache[0]||=createTextVNode(` Raw Stream Data `,-1)]),withDirectives(createBaseVNode(`div`,_hoisted_3$101,[createBaseVNode(`div`,_hoisted_4$81,[__props.fastData?(openBlock(),createElementBlock(`div`,_hoisted_5$69,[createBaseVNode(`h4`,null,`Fast Stream Data `+toDisplayString(__props.fastData.timestamp),1),createBaseVNode(`pre`,_hoisted_6$55,toDisplayString(JSON.stringify(__props.fastData,null,1)),1)])):createCommentVNode(``,!0),__props.slowData?(openBlock(),createElementBlock(`div`,_hoisted_7$47,[createBaseVNode(`h4`,null,`Slow Stream Data `+toDisplayString(__props.slowData.timestamp),1),createBaseVNode(`pre`,_hoisted_8$39,toDisplayString(JSON.stringify(__props.slowData,null,1)),1)])):createCommentVNode(``,!0),__props.staticData?(openBlock(),createElementBlock(`div`,_hoisted_9$36,[createBaseVNode(`h4`,null,`Static Stream Data `+toDisplayString(__props.staticData.timestamp),1),createBaseVNode(`pre`,_hoisted_10$30,toDisplayString(JSON.stringify(__props.staticData,null,1)),1)])):createCommentVNode(``,!0),__props.placementData?(openBlock(),createElementBlock(`div`,_hoisted_11$27,[createBaseVNode(`h4`,null,`Placement Stream Data `+toDisplayString(__props.placementData.timestamp),1),createBaseVNode(`pre`,_hoisted_12$21,toDisplayString(JSON.stringify(__props.placementData,null,1)),1)])):createCommentVNode(``,!0)])],512),[[vShow,!isCollapsed.value]])]))}},RawData_default=__plugin_vue_export_helper_default(_sfc_main$151,[[`__scopeId`,`data-v-7bc3ab60`]]),_hoisted_1$134={class:`laptimes-app`,style:{"overflow-y":`scroll`}},_sfc_main$150={__name:`appDebug`,setup(__props){useEvents();let fastData=ref({}),slowData=ref({}),staticData=ref({}),placementData=ref({});return onMounted(()=>{useStreams([`lapTimes_fast`,`lapTimes_slow`,`lapTimes_static`,`lapTimes_placement`],streams=>{streams.lapTimes_fast&&(fastData.value=streams.lapTimes_fast),streams.lapTimes_slow&&(slowData.value=streams.lapTimes_slow),streams.lapTimes_static&&(staticData.value=streams.lapTimes_static),streams.lapTimes_placement&&(placementData.value=streams.lapTimes_placement)})}),onUnmounted(()=>{}),(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$134,[_cache[0]||=createBaseVNode(`div`,{class:`laptimes-header`},[createBaseVNode(`h2`,null,`Lap Times Debug`)],-1),createVNode(BasicInfo_default,{fastData:fastData.value,slowData:slowData.value,staticData:staticData.value},null,8,[`fastData`,`slowData`,`staticData`]),createVNode(BestTimes_default,{slowData:slowData.value},null,8,[`slowData`]),createVNode(LapTimes_default,{fastData:fastData.value,slowData:slowData.value,staticData:staticData.value},null,8,[`fastData`,`slowData`,`staticData`]),createVNode(SegmentTimes_default,{fastData:fastData.value,slowData:slowData.value,staticData:staticData.value},null,8,[`fastData`,`slowData`,`staticData`]),createVNode(Placement_default,{fastData:fastData.value,slowData:slowData.value,staticData:staticData.value,placementData:placementData.value},null,8,[`fastData`,`slowData`,`staticData`,`placementData`]),createVNode(RawData_default,{fastData:fastData.value,slowData:slowData.value,staticData:staticData.value,placementData:placementData.value},null,8,[`fastData`,`slowData`,`staticData`,`placementData`])]))}},appDebug_default$1=__plugin_vue_export_helper_default(_sfc_main$150,[[`__scopeId`,`data-v-49102eaf`]]),_hoisted_1$133={class:`messages-app`},_hoisted_2$112={key:0,class:`icon-cell`},_hoisted_3$100={class:`text-cell`},_hoisted_4$80={key:0},timerIntervalMs=300,_sfc_main$149={__name:`app`,props:{maxMessages:{type:Number,default:void 0},dense:{type:Boolean,default:!1},wrap:{type:Boolean,default:!0},showIcons:{type:Boolean,default:!0}},setup(__props){let props=__props,events$3=useEvents(),messagesByCategory=reactive({}),bypassTtl=ref(!1),getIconProps=item=>{let icon=resolvedType(item.icon);if(icon)return{type:icon};let externalImage=resolvedExternalImage(item.icon);return externalImage?{externalImage}:{type:`info`}},timerId,isAssetPath=icon=>typeof icon==`string`&&icon.startsWith(`/`),resolvedType=icon=>typeof icon==`string`&&!isAssetPath(icon)?icon:void 0,resolvedExternalImage=icon=>typeof icon==`string`&&isAssetPath(icon)?icon:void 0,messagesList=computed(()=>{let list=Object.values(messagesByCategory);return typeof props.maxMessages==`number`&&props.maxMessages>0?list.slice(0,props.maxMessages):list});function resolveTranslation(val){return val==null?``:typeof val==`string`?$translate.instant(val):Array.isArray(val)?$translate.multiContextTranslate(val):typeof val==`object`?$translate.contextTranslate(val):String(val)}function htmlToPlainText(html){if(typeof html!=`string`)return String(html??``);let h$1=html.replace(//gi,` `),el=document.createElement(`div`);el.innerHTML=h$1;let text=el.textContent??el.innerText??h$1;return text=text.replace(/<[^>]*>/g,``),text}function sanitizeTextSegment(text){return text?htmlToPlainText(parse$1?parse$1(text):text):``}function getParts(item){let raw=resolveTranslation(item.text);if(typeof raw!=`string`)return[{t:`text`,v:sanitizeTextSegment(String(raw))}];let parts=[],rgx=/\[action=([^\]]+)\]/gi,lastIndex=0,match;for(;(match=rgx.exec(raw))!==null;){let head=raw.slice(lastIndex,match.index);head&&parts.push({t:`text`,v:sanitizeTextSegment(head)});let actionName=match[1].trim();parts.push({t:`binding`,action:actionName}),lastIndex=match.index+match[0].length}let tail=raw.slice(lastIndex);return tail&&parts.push({t:`text`,v:sanitizeTextSegment(tail)}),parts.length?parts:[{t:`text`,v:sanitizeTextSegment(raw)}]}function normalizePayload(args){let category=args?.category??`default`,clear=!!args?.clear,text=args&&`text`in args?args.text:args&&`msg`in args?args.msg:``,icon=typeof args?.icon==`string`?args.icon:void 0,ttlMs=typeof args?.ttlMs==`number`?args.ttlMs:typeof args?.ttl==`number`?args.ttl*1e3:void 0;return ttlMs??=5e3,{category,clear,text,icon,ttlMs}}let CATEGORY_ICONS=[{match:`vehicle.absBehavior`,icon:`ABSIndicator`},{match:`vehicle.brakingdistance`,icon:`carsFollow`},{prefix:`vehicle.compressionBrake.`,icon:`engine`},{prefix:`vehicle.damage.exhaust`,icon:`exhaustMuffler`},{prefix:`vehicle.damage.deflated.`,icon:`tireDeflated`},{prefix:`vehicle.beamstate.tireDeflated`,icon:`tireDeflated`},{match:`vehicle.damage.mildOverrev`,icon:`powerGauge05`},{match:`vehicle.damage.catastrophicOverrev`,icon:`powerGauge05`},{match:`vehicle.damage.catastrophicOverTorque`,icon:`cogDamaged`},{match:`vehicle.damage.flood`,icon:`water`},{match:`vehicle.engine.isStalling`,icon:`powerGauge01`},{match:`vehicle.ignition.ignitionLevel`,icon:`keys1`},{match:`vehicle.lightbar.mode`,icon:`wigwags`},{match:`vehicle.linelock.status`,icon:`wheelDisc`},{match:`vehicle.postCrashBrake.impact`,icon:`hazardLights`},{prefix:`vehicle.powertrain.diffmode.`,icon:`drivetrainGeneric`},{match:`vehicle.powertrain.nitrousOxideInjection`,icon:`N2OHoriz`},{match:`vehicle.shiftLogic.cannotShift`,icon:`cogsDamaged`},{match:`vehicle.shiftermode`,icon:`transmissionM`},{match:`vehicle.transbrake.status`,icon:`cogs`},{match:`vehicle.twoStep.status`,icon:`signal04a`},{match:`vehicle.tirePressureControl.inflateDeflate`,icon:`tirePressureGaugeOutlined03`},{prefix:`vehicle.wheels.tirePunctured.`,icon:`tireAirPuff`},{prefix:`vehicle.damage.device.`,icon:`cogDamaged`},{match:`vehicle.driveModes`,icon:`ESC`},{prefix:`vehicle.driveModes.`,icon:`ESC`},{match:`vehicle.engine.oilOverheating.true`,icon:`coolantTemp`},{match:`vehicle.engine.blockMelted.true`,icon:`coolantTemp`},{match:`vehicle.engine.headGasketDamaged.true`,icon:`coolantTemp`},{match:`vehicle.engine.coolantOverheating.true`,icon:`coolantTemp`},{match:`vehicle.engine.radiatorLeak.true`,icon:`coolantTemp`},{prefix:`vehicle.engine.`,icon:`engine`},{prefix:`vehicle.recovery.`,icon:`tow`},{match:`rally`,icon:`rallyHelmet`},{match:`fill`,icon:`import`},{match:`align`,icon:`flag`},{match:`delivery`,icon:`boxTruckFast`},{match:`refueling`,icon:`fuelPumpFilling`},{prefix:`refueling-`,icon:`fuelPumpFilling`},{prefix:`ui.camera.`,icon:`movieCamera`},{match:`input`,icon:`gamepad`},{prefix:`ui.apps.damage_app_vehicle_simple.component.`,icon:`cogsDamaged`},{match:`AI debug`,icon:`AIMicrochip`},{match:`debug`,icon:`code`},{match:`hydros`,icon:`steeringWheelCommon`},{match:`GLTFexport`,icon:`loadMesh`},{match:`bigmap.info.reachedTarget`,icon:`raceFlag`}];function deriveIconForCategory(category){if(!category)return`info`;console.debug(`[messages] deriveIconForCategory`,category);for(let{match,prefix:prefix$1,icon}of CATEGORY_ICONS){if(match&&category===match)return console.debug(` -> match:`,match,icon),icon;if(prefix$1&&category.startsWith(prefix$1))return console.debug(` -> prefix:`,prefix$1,icon),icon}return console.debug(` -> no match, fallback to info`),`info`}function onMessage(args){let{category,clear,text,icon,ttlMs}=normalizePayload(args),matched=[];try{let re=new RegExp(category);matched=Object.keys(messagesByCategory).filter(k=>re.test(k))}catch{}matched.length===0&&(matched=[category]);for(let cat of matched){if(clear||typeof text==`string`&&text===``){delete messagesByCategory[cat];continue}let offset$2=Object.keys(messagesByCategory).length*timerIntervalMs*2;messagesByCategory[cat]={_key:cat,text,icon:icon||deriveIconForCategory(cat),ttl:ttlMs+offset$2}}}function onClearAll(){for(let k in messagesByCategory)delete messagesByCategory[k]}function tick(){for(let k in messagesByCategory){let m=messagesByCategory[k];bypassTtl.value||(m.ttl-=timerIntervalMs),m.ttl<=0&&delete messagesByCategory[k]}}return onMounted(()=>{events$3.on(`Message`,onMessage),events$3.on(`ClearAllMessages`,onClearAll),events$3.on(`MessagesDebug`,data=>{data&&typeof data.bypassTtl==`boolean`&&(bypassTtl.value=!!data.bypassTtl)}),timerId=window.setInterval(tick,timerIntervalMs)}),onUnmounted(()=>{timerId&&window.clearInterval(timerId)}),(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$133,[(openBlock(!0),createElementBlock(Fragment,null,renderList(messagesList.value,item=>(openBlock(),createElementBlock(`div`,{key:item._key,class:`message-row`},[__props.showIcons&&item.icon?(openBlock(),createElementBlock(`div`,_hoisted_2$112,[createVNode(unref(bngIcon_default),mergeProps({class:`msg-icon`,fallbackType:`info`},{ref_for:!0},getIconProps(item)),null,16)])):createCommentVNode(``,!0),createBaseVNode(`div`,_hoisted_3$100,[(openBlock(!0),createElementBlock(Fragment,null,renderList(getParts(item),(part,i)=>(openBlock(),createElementBlock(Fragment,{key:i},[part.t===`text`?(openBlock(),createElementBlock(`span`,_hoisted_4$80,toDisplayString(part.v),1)):(openBlock(),createBlock(unref(bngBinding_default),{key:1,action:part.action,"show-unassigned":``},null,8,[`action`]))],64))),128))])]))),128))]))}},app_default$32=__plugin_vue_export_helper_default(_sfc_main$149,[[`__scopeId`,`data-v-ddfd9832`]]),apps_exports=__export({advancedWheelsDebug:()=>app_default$2,brakeTorqueGraph:()=>app_default$3,busLine:()=>app_default$4,cameraDistance:()=>app_default$5,clutchThermalDebug:()=>app_default$6,compass:()=>app_default$7,compassPrecise:()=>app_default$8,countdown:()=>countdownApp_default,crashTestNextStep:()=>app_default$15,damageApp:()=>app_default$9,dragRace:()=>app_default$10,dragRaceStage:()=>app_default$12,dragRaceTree:()=>app_default$11,driftCurrentDrift:()=>app_default$13,driftScores:()=>app_default$14,engineDebug:()=>app_default$16,engineDynamometer:()=>app_default$17,engineHeatDebugGraph:()=>app_default$18,engineThermalDebug:()=>app_default$19,forcedInduction:()=>app_default$20,forcedInductionDebug:()=>app_default$21,gameplayApps:()=>gameplayApps_default,genericMissionData:()=>bngGenericMissionData_default,hydraulicsDebug:()=>app_default$22,inputHints:()=>app_default$29,keyList:()=>app_default$23,lapTimes:()=>app_default$31,lapTimesDebug:()=>appDebug_default$1,logvehiclestats:()=>app_default$24,messages:()=>app_default$32,messagesTasksApps:()=>messagesTasksApps_default,navigation:()=>app_default$30,pointsBar:()=>app_default,rallyCountdown:()=>appCountdown_default,rallyDashboard:()=>appDashboard_default,rallyDebug:()=>appDebug_default,rallyStageProgress:()=>appStageProgress_default,rallyStageTiming:()=>appStageTiming_default,rallyTimecard:()=>appTimecard_default,rallyVisualPacenotes:()=>app_default$28,replayAppV2:()=>app_default$1,simpleDigTacho:()=>app_default$25,simpleFlashMessage:()=>flashMessageApp_default,tacho2:()=>app_default$26,tasklist:()=>app_default$27});const useTuningStore=defineStore(`tuning`,()=>{let{lua,events:events$3}=useBridge(),buckets=ref({}),tuningVariables=ref({}),editedTuningVars={},isCareer=!1,shoppingData=ref({}),noapi=()=>{throw Error(`Tuning store must be initialised first`)},api$1={request:noapi,apply:noapi,reset:noapi,close:()=>{},menuClose:()=>{}};async function init$3(){for(let name in editedTuningVars={},isCareer=await lua.career_career.isActive(),isCareer?(api$1.request=async()=>processTuningData(await lua.career_modules_tuning.getTuningData()),api$1.apply=(values,edited)=>{let res={};for(let[varName,_]of Object.entries(edited))res[varName]=valDisToVal(values[varName]);lua.career_modules_tuning.apply(res)},api$1.reset=()=>{},api$1.close=()=>{events$3.off(`sendTuningShoppingData`,setShoppingData),events$3.off(`updateTuningVariable`,updateTuningVariable),shoppingData.value={}},events$3.on(`sendTuningShoppingData`,setShoppingData),events$3.on(`updateTuningVariable`,updateTuningVariable)):(api$1.request=async()=>await lua.extensions.core_vehicle_partmgmt.sendDataToUI(),api$1.apply=(values,edited)=>{let res={};for(let varName in values)res[varName]=valDisToVal(values[varName]);lua.extensions.core_vehicle_partmgmt.setConfigVars(res)},api$1.reset=async()=>await lua.extensions.core_vehicle_partmgmt.resetVarsToLoadedConfig(),api$1.close=()=>{events$3.off(`VehicleFocusChanged`,api$1.request),events$3.off(`VehicleConfigChange`,processTuningData)},api$1.menuClose=api$1.close,events$3.on(`VehicleFocusChanged`,api$1.request),events$3.on(`VehicleConfigChange`,processTuningData)),api$1)api$1[name]===noapi&&(api$1[name]=()=>{})}function apply$1(){api$1.apply(tuningVariables.value,editedTuningVars),editedTuningVars={}}function setShoppingData(data){shoppingData.value=data}function updateTuningVariable(tuningVar){tuningVariables.value[tuningVar.name].valDis=Number(valToValDis(tuningVar))}let processTuningData=data=>{data.variables&&(data=data.variables),isCareer&&(delete data.$fuel,delete data.$fuel_R,delete data.$fuel_L),buckets.value=[],tuningVariables.value={};for(let varData of Object.values(data)){if(isCareer&&varData.category===`Cargo`||varData.hideInUI)continue;varData.category||=`Other`,varData.subCategory||=`Other`;let cat=(buckets.value.find(cat$1=>cat$1.name===varData.category)||buckets.value[buckets.value.push({name:varData.category,items:[]})-1]).items;(cat.find(sub=>sub.name===varData.subCategory)||cat[cat.push({name:varData.subCategory,items:[]})-1]).items.push(varData),tuningVariables.value[varData.name]={valDis:Number(valToValDis(varData)),minDis:varData.minDis,maxDis:varData.maxDis,min:varData.min,max:varData.max,default:Number(valToValDis(varData,!0))}}let sorter=(a$1,b)=>a$1.name.localeCompare(b.name);buckets.value.sort(sorter);for(let cat of buckets.value){cat.items.sort(sorter);for(let sub of cat.items)sub.items.sort(sorter)}};function countDecimals(num){return typeof num!=`number`||~~num===num?0:num.toString().split(`.`)[1].length||0}function valToValDis(varData,useDef=!1){return roundDec(round(((useDef?varData.default:varData.val)-varData.min)/(varData.max-varData.min)*(varData.maxDis-varData.minDis),varData.stepDis)+varData.minDis,countDecimals(varData.stepDis))}function valDisToVal(varData){return(varData.valDis-varData.minDis)/(varData.maxDis-varData.minDis)*(varData.max-varData.min)+varData.min}function tuningVarChanged(varName){editedTuningVars[varName]=!0}return{init:init$3,buckets,tuningVariables,shoppingData,apply:apply$1,requestInitialData:()=>api$1.request(),close:()=>api$1.close(),notifyOnMenuClosed:()=>api$1.menuClose(),tuningVarChanged,resetTuningData:()=>api$1.reset()}});var _hoisted_1$132={key:0,class:`tuning-form`},_hoisted_2$111={key:0,class:`extra-features`},_hoisted_3$99={class:`category-heading`},_hoisted_4$79={class:`category-name`},_hoisted_5$68={key:0,class:`subcategory-heading`},_hoisted_6$54={class:`subcategory-name`},_hoisted_7$46={class:`variable-title`},_hoisted_8$38={class:`variable-box`},_hoisted_9$35={class:`tuning-static`},_hoisted_10$29={class:`buttons`},_sfc_main$148={__name:`Tuning`,props:{withBackground:Boolean,buttonTarget:{type:Object},closeButton:Boolean},setup(__props,{expose:__expose}){useUINavBlocker().blockOnly([`context`]);let{lua}=useBridge(),tuningStore=useTuningStore(),awdApp=ref(),awdShow=ref(!1),apply$1=()=>{tuningStore.apply()},close=()=>{tuningStore.close()},mirrorsShown=ref(!0),mirrorsEnabled=ref(!1),mirrorsRoute=`menu.vehicleconfig.tuning.mirrors`,toMirrors=()=>{window.bngVue.gotoGameState(mirrorsRoute)},inputs=ref([]),isChanged=computed(()=>inputs.value.some(ipt=>ipt.dirty));__expose({apply:apply$1,close});let autoApply=ref(!1),applyDebounce=debounce(apply$1,1e3);function onChange(varName){tuningStore.tuningVarChanged(varName),autoApply.value&&applyDebounce()}let applySettingChanged=val=>localStorage.setItem(`applyTuningChangesAutomatically`,JSON.stringify(val));watch(()=>tuningStore.buckets,()=>nextTick(()=>{for(let ipt of inputs.value)ipt.markClean()}));async function resetVarsToLoadedConfig(){tuningStore.resetTuningData(),await tuningStore.requestInitialData(),await nextTick();for(let ipt of inputs.value)ipt.markClean()}onBeforeMount(async()=>{let optAutoApply=localStorage.getItem(`applyTuningChangesAutomatically`);if(optAutoApply)try{autoApply.value=!!JSON.parse(optAutoApply)}catch{}await lua.extensions.gameplay_garageMode.isActive()&&(mirrorsRoute=`menu.vehicleconfig.tuning.mirrors.in-garage`),await lua.career_career.isActive()?mirrorsShown.value=!1:mirrorsEnabled.value=(await useSettingsAsync()).values.GraphicDynMirrorsEnabled,await tuningStore.init(),await tuningStore.requestInitialData(),getUINavServiceInstance().setFilteredEvents(UI_EVENT_GROUPS.focusMoveScalar)});let extraFeatures=computed(()=>{let features=[];return mirrorsEnabled.value&&features.push({mirrorsEnabled:!0}),features});return onUnmounted(async()=>{await tuningStore.notifyOnMenuClosed(),tuningStore.close(),tuningStore.$dispose(),getUINavServiceInstance().clearFilteredEvents()}),(_ctx,_cache)=>withDirectives((openBlock(),createElementBlock(`div`,{class:normalizeClass({innerTuningCard:!0,"with-background":__props.withBackground})},[unref(tuningStore).buckets?(openBlock(),createElementBlock(`div`,_hoisted_1$132,[extraFeatures.value.length>0?(openBlock(),createElementBlock(`div`,_hoisted_2$111,[withDirectives((openBlock(),createBlock(unref(bngButton_default),{onClick:toMirrors,accent:`secondary`},{default:withCtx(()=>[createTextVNode(toDisplayString(_ctx.$t(`ui.mirrors.name`)),1)]),_:1})),[[unref(BngDisabled_default),!extraFeatures.value.find(f=>f.mirrorsEnabled)]])])):createCommentVNode(``,!0),(openBlock(!0),createElementBlock(Fragment,null,renderList(unref(tuningStore).buckets,category=>(openBlock(),createElementBlock(`div`,{class:`tuning-category`,key:category.name},[createBaseVNode(`h2`,_hoisted_3$99,[createBaseVNode(`span`,_hoisted_4$79,toDisplayString(category.name),1)]),(openBlock(!0),createElementBlock(Fragment,null,renderList(category.items,subCategory=>(openBlock(),createElementBlock(`div`,{class:`tuning-subcategory`,key:subCategory.name},[subCategory.name===`Other`?createCommentVNode(``,!0):(openBlock(),createElementBlock(`h3`,_hoisted_5$68,[createBaseVNode(`span`,_hoisted_6$54,toDisplayString(subCategory.name),1)])),(openBlock(!0),createElementBlock(Fragment,null,renderList(subCategory.items,varData=>withDirectives((openBlock(),createElementBlock(`div`,{key:category.name+subCategory.name+varData.name,class:normalizeClass({"input-container":!0,"variable-box":varData.type===`slider`})},[createBaseVNode(`div`,_hoisted_7$46,toDisplayString(varData.title),1),createBaseVNode(`div`,_hoisted_8$38,[createVNode(unref(bngSlider_default),{ref_for:!0,ref_key:`inputs`,ref:inputs,min:varData.minDis,max:varData.maxDis,step:varData.stepDis,unit:varData.unit,class:normalizeClass({"property-slider":!0}),"with-input":``,"with-reset":``,"orig-value":unref(tuningStore).tuningVariables[varData.name].default,modelValue:unref(tuningStore).tuningVariables[varData.name].valDis,"onUpdate:modelValue":$event=>unref(tuningStore).tuningVariables[varData.name].valDis=$event,onValueChanged:$event=>onChange(varData.name)},null,8,[`min`,`max`,`step`,`unit`,`orig-value`,`modelValue`,`onUpdate:modelValue`,`onValueChanged`])])],2)),[[unref(BngTooltip_default),varData.description,`top`]])),128))]))),128))]))),128))])):createCommentVNode(``,!0),createBaseVNode(`div`,_hoisted_9$35,[withDirectives(createVNode(unref(app_default$2),{class:normalizeClass({"awd-app":awdApp.value}),ref_key:`awdApp`,ref:awdApp},null,8,[`class`]),[[vShow,awdShow.value]]),awdApp.value&&awdApp.value.hasData?(openBlock(),createBlock(unref(bngSwitch_default),{key:0,modelValue:awdShow.value,"onUpdate:modelValue":_cache[0]||=$event=>awdShow.value=$event},{default:withCtx(()=>[createTextVNode(toDisplayString(_ctx.$t(`ui.garage.tune.advWheel`)),1)]),_:1},8,[`modelValue`])):createCommentVNode(``,!0),createVNode(unref(bngSwitch_default),{modelValue:autoApply.value,"onUpdate:modelValue":_cache[1]||=$event=>autoApply.value=$event,onValueChanged:applySettingChanged},{default:withCtx(()=>[createTextVNode(toDisplayString(_ctx.$t(`ui.garage.liveUpdates`)),1)]),_:1},8,[`modelValue`]),createBaseVNode(`div`,_hoisted_10$29,[withDirectives(createVNode(unref(bngButton_default),{"show-hold":``,icon:unref(icons).undo,accent:unref(ACCENTS).custom,class:`reset-button`},null,8,[`icon`,`accent`]),[[unref(BngOnUiNav_default),void 0,`ok`,{asMouse:!0,focusRequired:!0}],[unref(BngClick_default),{holdCallback:resetVarsToLoadedConfig,holdDelay:1e3,repeatInterval:0}],[unref(BngTooltip_default),`Reset to original config`]]),createVNode(unref(bngButton_default),{disabled:autoApply.value||!isChanged.value,onClick:apply$1},{default:withCtx(()=>[createTextVNode(toDisplayString(_ctx.$t(`ui.common.apply`)),1)]),_:1},8,[`disabled`]),__props.closeButton?(openBlock(),createBlock(unref(bngButton_default),{key:0,onClick:close,accent:unref(ACCENTS).attention},{default:withCtx(()=>[createVNode(unref(bngBinding_default),{"ui-event":`back`,deviceMask:`xinput`}),createTextVNode(toDisplayString(_ctx.$t(`ui.common.close`)),1)]),_:1},8,[`accent`])):createCommentVNode(``,!0)])])],2)),[[unref(BngBlur_default),__props.withBackground]])}},Tuning_default=__plugin_vue_export_helper_default(_sfc_main$148,[[`__scopeId`,`data-v-907bf291`]]),CANCEL_MESSAGE=`Are you sure you want to cancel?
    All changes to your vehicle will be reversed`,_sfc_main$147={__name:`TuningMain`,setup(__props){useComputerStore();let tuningStore=useTuningStore(),CONFIRM_BUTTONS=[{label:$translate.instant(`ui.common.yes`),value:!0},{label:$translate.instant(`ui.common.no`),value:!1,extras:{accent:ACCENTS.secondary}}],confirmCancel=async()=>{(!(tuningStore.shoppingData.shoppingCart&&tuningStore.shoppingData.shoppingCart.items.length)||await openConfirmation(null,CANCEL_MESSAGE,CONFIRM_BUTTONS))&&cancelShopping()},cartData=computed(()=>{let cart=tuningStore.shoppingData?tuningStore.shoppingData.shoppingCart:null,res={total:0,taxes:0,items:[]};return cart&&(res.total=cart.total,res.taxes=cart.taxes,Array.isArray(cart.items)&&(res.items=cart.items.map(item=>({type:item.type||item.level===1&&`item`,level:item.level,name:item.title,price:item.price,priceHide:!item.price,removeShow:!!item.varName,remove:()=>Lua_default.career_modules_tuning.removeVarFromShoppingCart(item.varName)})))),res}),elCard=ref(),applyShopping=()=>Lua_default.career_modules_tuning.applyShopping(),cancelShopping=()=>Lua_default.career_modules_tuning.cancelShopping();return(_ctx,_cache)=>(openBlock(),createBlock(ComputerWrapper_default,{path:[`Tuning`],title:`Tuning`,back:``,onBack:confirmCancel},{side:withCtx(()=>[createVNode(ShoppingCart_default,{"cart-data":cartData.value,"player-money":unref(tuningStore).shoppingData.playerMoney,"confirm-button-text":`Confirm`,apply:applyShopping,cancel:confirmCancel},null,8,[`cart-data`,`player-money`])]),default:withCtx(()=>[withDirectives((openBlock(),createBlock(unref(bngCard_default),{class:`tuningCard`,ref_key:`elCard`,ref:elCard},{buttons:withCtx(()=>[..._cache[0]||=[]]),default:withCtx(()=>[createVNode(Tuning_default,{"button-target":elCard.value&&elCard.value.buttonsContainer,"close-button":!1},null,8,[`button-target`])]),_:1})),[[unref(BngBlur_default),1]])]),_:1}))}},TuningMain_default=__plugin_vue_export_helper_default(_sfc_main$147,[[`__scopeId`,`data-v-60311783`]]);const useVehicleInventoryStore=defineStore(`vehicleInventory`,()=>{let{events:events$3}=useBridge(),vehicleInventoryData=ref({}),vehIdToChooseAfterRepairPopup=ref(0),filteredVehicles=computed(()=>{let data=vehicleInventoryData.value;return data.vehicles?Object.values(data.vehicles):[]}),menuOpen=!1;function requestInitialData(){Lua_default.career_modules_inventory.sendDataToUi()}function closeMenu(){Lua_default.career_modules_inventory.closeMenu()}let getExpediteRepairCost=vehicle=>Math.max(vehicle.quickRepairExtraPrice*(vehicle.timeToAccess/vehicle.initialRepairTime),50);function countDownVehicleDelays(){if(menuOpen){for(let vehicle of filteredVehicles.value)vehicle.timeToAccess&&(--vehicle.timeToAccess,vehicle.delayReason==`repair`&&(vehicle.expediteRepairCost=getExpediteRepairCost(vehicle)),vehicle.timeToAccess<=0&&Lua_default.career_modules_inventory.sendDataToUi());setTimeout(countDownVehicleDelays,1e3)}}events$3.on(`vehicleInventoryData`,data=>{Object.values(data.vehicles).forEach(vehicle=>{data.currentVehicleId===vehicle.id&&(vehicle.niceName+=` (Current Vehicle)`),vehicle.owned||(vehicle.niceName+=` (Not owned)`)}),vehicleInventoryData.value=data,vehIdToChooseAfterRepairPopup.value=0,menuOpen||(menuOpen=!0,countDownVehicleDelays())});function menuClosed(){menuOpen=!1}function repairPopupAccept(){Lua_default.career_modules_inventory.chooseVehicleFromMenu(vehIdToChooseAfterRepairPopup.value,1,!0),vehIdToChooseAfterRepairPopup.value=0}function repairPopupDecline(){Lua_default.career_modules_inventory.chooseVehicleFromMenu(vehIdToChooseAfterRepairPopup.value,1,!1),vehIdToChooseAfterRepairPopup.value=0}function chooseVehicle(vehId,buttonIndex){let showRepairPopup=!1,data=vehicleInventoryData.value;if(data.currentVehicleId!==void 0&&vehId!==data.currentVehicleId&&(showRepairPopup=data.vehicles[data.currentVehicleId].needsRepair),showRepairPopup){vehIdToChooseAfterRepairPopup.value=vehId;return}Lua_default.career_modules_inventory.chooseVehicleFromMenu(vehId,buttonIndex+1,!1)}function dispose$2(){events$3.off(`vehicleInventoryData`)}return{filteredVehicles,vehIdToChooseAfterRepairPopup,vehicleInventoryData,requestInitialData,chooseVehicle,repairPopupAccept,repairPopupDecline,menuClosed,closeMenu,dispose:dispose$2}});var _hoisted_1$131={class:`list-vehicle-dialog`},_hoisted_2$110={class:`vehicle-info`},_hoisted_3$98={class:`name`},_hoisted_4$78={key:0,class:`meta`},_hoisted_5$67={key:1,class:`meta`},_hoisted_6$53={class:`price-box`},_hoisted_7$45={class:`price-content`},_hoisted_8$37={class:`price-row`},_hoisted_9$34={class:`step-buttons-group`},_hoisted_10$28={class:`price`},_hoisted_11$26={class:`step-buttons-group`},_sfc_main$146={__name:`ListVehicleDialog`,props:{modelValue:{type:Object,required:!0}},emits:[`update:modelValue`],setup(__props,{emit:__emit}){let props=__props,emit$1=__emit,{units}=useBridge(),formModel=computed({get:()=>props.modelValue,set:newValue=>emit$1(`update:modelValue`,newValue)});function adjustPrice(amount){let price=Math.max(0,Math.round(((formModel.value.price||0)+amount)/50)*50);emit$1(`update:modelValue`,{...formModel.value,price})}let priceHint=computed(()=>{let mv=Number(formModel.value.marketValue||0),p$1=Number(formModel.value.price||0);if(!mv||!p$1)return{text:``,class:``};let diff=(p$1-mv)/mv,percent=Math.round(Math.abs(diff)*100);return percent<1?{text:`Fair market value`,class:`ok`}:diff>0?{text:`${percent}% above market value`,class:`high`}:{text:`${percent}% below market value`,class:`low`}}),offerHint=computed(()=>{let mv=Number(formModel.value.marketValue||0),p$1=Number(formModel.value.price||0);if(!mv||!p$1)return{text:`Regular offers expected`,class:`regular`};let ratio=p$1/mv;return ratio<=.9?{text:`More offers expected`,class:`more`}:ratio>=1.2?{text:`Fewer offers expected`,class:`fewer`}:{text:`Regular offers expected`,class:`regular`}}),formModelText=computed(()=>formModel.value.odometerKm?new Intl.NumberFormat().format(Math.round(formModel.value.odometerKm))+` km`:``);return(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$131,[createBaseVNode(`div`,_hoisted_2$110,[createBaseVNode(`div`,_hoisted_3$98,toDisplayString(formModel.value.vehicleName),1),formModelText.value?(openBlock(),createElementBlock(`div`,_hoisted_4$78,toDisplayString(formModelText.value)+` — Market Value: `+toDisplayString(unref(units).beamBucks(formModel.value.marketValue||0)),1)):(openBlock(),createElementBlock(`div`,_hoisted_5$67,` Market Value: `+toDisplayString(unref(units).beamBucks(formModel.value.marketValue||0)),1))]),createBaseVNode(`div`,_hoisted_6$53,[createBaseVNode(`div`,_hoisted_7$45,[_cache[12]||=createBaseVNode(`div`,{class:`label`},`Your Asking Price`,-1),createBaseVNode(`div`,_hoisted_8$37,[createBaseVNode(`div`,_hoisted_9$34,[createVNode(unref(bngButton_default),{class:`step step-large`,accent:unref(ACCENTS).secondary,onClick:_cache[0]||=$event=>adjustPrice(-5e3)},{default:withCtx(()=>[..._cache[6]||=[createTextVNode(`-5000`,-1)]]),_:1},8,[`accent`]),createVNode(unref(bngButton_default),{class:`step step-medium`,accent:unref(ACCENTS).secondary,onClick:_cache[1]||=$event=>adjustPrice(-500)},{default:withCtx(()=>[..._cache[7]||=[createTextVNode(`-500`,-1)]]),_:1},8,[`accent`]),createVNode(unref(bngButton_default),{class:`step`,accent:unref(ACCENTS).secondary,onClick:_cache[2]||=$event=>adjustPrice(-50)},{default:withCtx(()=>[..._cache[8]||=[createTextVNode(`-50`,-1)]]),_:1},8,[`accent`])]),createBaseVNode(`div`,_hoisted_10$28,toDisplayString(unref(units).beamBucks(formModel.value.price||0)),1),createBaseVNode(`div`,_hoisted_11$26,[createVNode(unref(bngButton_default),{class:`step`,accent:unref(ACCENTS).secondary,onClick:_cache[3]||=$event=>adjustPrice(50)},{default:withCtx(()=>[..._cache[9]||=[createTextVNode(`+50`,-1)]]),_:1},8,[`accent`]),createVNode(unref(bngButton_default),{class:`step step-medium`,accent:unref(ACCENTS).secondary,onClick:_cache[4]||=$event=>adjustPrice(500)},{default:withCtx(()=>[..._cache[10]||=[createTextVNode(`+500`,-1)]]),_:1},8,[`accent`]),createVNode(unref(bngButton_default),{class:`step step-large`,accent:unref(ACCENTS).secondary,onClick:_cache[5]||=$event=>adjustPrice(5e3)},{default:withCtx(()=>[..._cache[11]||=[createTextVNode(`+5000`,-1)]]),_:1},8,[`accent`])])]),createBaseVNode(`div`,{class:normalizeClass([`hint`,[priceHint.value.class]])},toDisplayString(priceHint.value.text),3),createBaseVNode(`div`,{class:normalizeClass([`offer-hint`,[offerHint.value.class]])},toDisplayString(offerHint.value.text),3)])])]))}},ListVehicleDialog_default=__plugin_vue_export_helper_default(_sfc_main$146,[[`__scopeId`,`data-v-87a25af5`]]),_hoisted_1$130={class:`vehicle-list-container`},_sfc_main$145={__name:`VehicleList`,setup(__props){let{units}=useBridge(),{$game}=useLibStore(),popover=usePopover(),popId=uniqueId(`veh_options`),popHide=()=>popover.hide(popId),licensePlateTextValid=ref(!0),vehicleNameValid=ref(!0),vehicleInventoryStore=useVehicleInventoryStore(),selectedVehId=ref(),vehSelected=computed(()=>{if(typeof selectedVehId.value==`number`)return listView.value.find(v=>v.id===selectedVehId.value)}),careerStatusData=ref({}),updateCareerStatusData=()=>Lua_default.career_modules_uiUtils.getCareerStatusData().then(data=>careerStatusData.value=data),cantPayLicensePlate=computed(()=>!careerStatusData.value.money||300>careerStatusData.value.money),listStatus=computed(()=>vehicleInventoryStore?!Array.isArray(vehicleInventoryStore.filteredVehicles)||vehicleInventoryStore.filteredVehicles.length===0?`You don't currently own any vehicles`:null:`Please wait...`),listView=computed(()=>{if(!vehicleInventoryStore||!Array.isArray(vehicleInventoryStore.filteredVehicles)||vehicleInventoryStore.filteredVehicles.length===0)return[];let res=vehicleInventoryStore.filteredVehicles;if(singleFunction.value)for(let veh of res)veh.disabled=!isFunctionAvailable(veh,singleFunction.value);return res.sort((a$1,b)=>a$1.favorite?-1:b.favorite?1:a$1.niceName.localeCompare(b.niceName)),res}),itemLayout=ref({TILE:`tile`,LIST:`row`}.TILE),singleFunction=computed(()=>{if(!vehicleInventoryStore||!vehicleInventoryStore.vehicleInventoryData)return null;let data=vehicleInventoryStore.vehicleInventoryData;return Object.values(data.buttonsActive).includes(!0)||!Array.isArray(data.chooseButtonsData)||data.chooseButtonsData.length!==1?null:data.chooseButtonsData[0]});function select(vehicle,evt){let show=vehicleInventoryStore&&vehicleInventoryStore.vehicleInventoryData&&(Object.values(vehicleInventoryStore.vehicleInventoryData.buttonsActive).includes(!0)||vehicleInventoryStore.vehicleInventoryData.chooseButtonsData.length>0)&&vehicle&&(!vehSelected.value||vehSelected.value.id!==vehicle.id),popover$1;if(evt&&evt.target){let cur=evt.target;for(;popover$1=cur.__popover,!(popover$1||(cur=cur.parentNode,cur===document.body)););}if(vehicle&&singleFunction.value){selectedVehId.value=null,popover$1&&popover$1.hide(),vehicleInventoryStore.chooseVehicle(vehicle.id,0);return}show&&popover$1&&popover$1.hide(),nextTick(()=>{show?(selectedVehId.value=vehicle.id,popover$1&&popover$1.show()):(popover$1&&popover$1.hide(),selectedVehId.value=null)})}let isFunctionAvailable=(vehicle,buttonData)=>!(vehicle.timeToAccess||vehicle.missingFile||buttonData.requiredVehicleNotInGarage&&vehicle.inGarage||buttonData.requiredOtherVehicleInGarage&&!vehicle.otherVehicleInGarage||buttonData.ownedRequired&&!vehicle.owned||buttonData.repairRequired&&vehicle.needsRepair||buttonData.notForSaleRequired&&vehicle.listedForSale),lookAtVehicleListing=()=>{Lua_default.career_modules_marketplace.openMenu(vehicleInventoryStore.vehicleInventoryData.originComputerId)},confirmReturnVehicle=async()=>{let vehicle=vehSelected.value;popHide(),await openConfirmation(``,`Do you want to return this loaned vehicle to the owner?`,[{label:$translate.instant(`ui.common.yes`),value:!0,extras:{default:!0}},{label:$translate.instant(`ui.common.no`),value:!1,extras:{accent:ACCENTS.secondary}}])&&Lua_default.career_modules_inventory.returnLoanedVehicleFromInventory(vehicle.id)},personalizeLicensePlate=async()=>{let vehicle=vehSelected.value;popHide(),updateCareerStatusData();let res=await openPrompt(`Enter your new license plate text:`,`Personalize License Plate`,{maxLength:10,defaultValue:vehicle.config.licenseName,buttons:[{label:$translate.instant(`ui.common.cancel`),value:!1,extras:{cancel:!0,accent:ACCENTS.secondary}},{label:$translate.instant(`ui.common.okay`)+` (Cost: ${units.beamBucks(300)})`,value:text=>text,extras:{disabled:cantPayLicensePlate,accent:ACCENTS.primary}}],validate:text=>(Lua_default.career_modules_inventory.isLicensePlateValid(text).then(valid=>{licensePlateTextValid.value=valid}),licensePlateTextValid.value),errorMessage:`Invalid character in license plate text`,disableWhenInvalid:!0});res!=0&&(Lua_default.career_modules_inventory.purchaseLicensePlateText(vehicle.id,res,300),vehicle.config.licenseName=res)},confirmExpediteRepair=async()=>{let vehicle=vehSelected.value;popHide();let price=vehicle.expediteRepairCost;await openConfirmation(``,`Do you want to expedite the repair for ${units.beamBucks(price)}?`,[{label:$translate.instant(`ui.common.yes`),value:!0,extras:{default:!0}},{label:$translate.instant(`ui.common.no`),value:!1,extras:{accent:ACCENTS.secondary}}])&&Lua_default.career_modules_inventory.expediteRepairFromInventory(vehicle.id,price)},openRepairMenu=()=>{let vehicle=vehSelected.value;popHide(),Lua_default.career_modules_insurance_repairScreen.openRepairMenu(vehicle,vehicleInventoryStore.vehicleInventoryData.originComputerId)},setFavoriteVehicle=()=>{let vehicle=vehSelected.value;popHide(),Lua_default.career_modules_inventory.setFavoriteVehicle(vehicle.id),Lua_default.career_modules_inventory.sendDataToUi()},storeVehicle=()=>{let vehicle=vehSelected.value;popHide(),Lua_default.career_modules_inventory.removeVehicleObject(vehicle.id),Lua_default.career_modules_inventory.sendDataToUi()},renameVehicle=async()=>{let vehicle=vehSelected.value;popHide();let res=await openPrompt(`Enter new vehicle name:`,`Rename Vehicle`,{maxLength:30,defaultValue:vehicle.niceName,buttons:[{label:$translate.instant(`ui.common.cancel`),value:!1,extras:{cancel:!0,accent:ACCENTS.secondary}},{label:$translate.instant(`ui.common.okay`),value:text=>text,extras:{accent:ACCENTS.primary}}],validate:text=>(Lua_default.career_modules_inventory.isVehicleNameValid(text).then(valid=>{vehicleNameValid.value=valid}),vehicleNameValid.value),errorMessage:`Invalid characters in vehicle name`,disableWhenInvalid:!0});res!=0&&(Lua_default.career_modules_inventory.renameVehicle(vehicle.id,res),vehicle.niceName=res)},listVehicleForSale=async vehicle=>{popHide();let res=await openFormDialog(ListVehicleDialog_default,{vehicleName:vehicle.niceName,odometer:vehicle.odometer,marketValue:vehicle.value,price:Math.max(50,Math.round((vehicle.value||0)/50)*50)},model=>!Number.isFinite(model.price)||model.price<=0?{error:!0,message:`Enter a valid positive price`}:{error:!1},`List a Vehicle for Sale`,void 0,void 0,`90rem`);!res||!res.value||await Lua_default.career_modules_marketplace.listVehicles([{inventoryId:vehicle.id,value:res.formData.price}])},listVehicleForSaleFromContextMenu=async()=>{let vehicle=vehSelected.value;await listVehicleForSale(vehicle),Lua_default.career_modules_marketplace.openMenu(vehicleInventoryStore.vehicleInventoryData.originComputerId)},listVehicleForSaleFromMarketplaceMenu=async vehicle=>{await listVehicleForSale(vehicle),router_default.back()};return $game.events.on(`addListing`,data=>{listVehicleForSaleFromMarketplaceMenu(listView.value.find(v=>v.id===data.inventoryId))}),onUnmounted(()=>{$game.events.off(`addListing`)}),(_ctx,_cache)=>withDirectives((openBlock(),createElementBlock(`div`,_hoisted_1$130,[listStatus.value?withDirectives((openBlock(),createBlock(VehicleTileRow_default,{key:0,class:`vehicle-list-item`,data:{_message:listStatus.value},layout:itemLayout.value},null,8,[`data`,`layout`])),[[unref(BngDisabled_default)]]):(openBlock(!0),createElementBlock(Fragment,{key:1},renderList(listView.value,vehicle=>withDirectives((openBlock(),createBlock(VehicleTileRow_default,{class:`vehicle-list-item`,key:vehicle.id,data:vehicle,layout:itemLayout.value,selected:vehSelected.value&&vehSelected.value.id===vehicle.id,"is-tutorial":unref(vehicleInventoryStore)&&unref(vehicleInventoryStore).vehicleInventoryData.tutorialActive,money:unref(vehicleInventoryStore)?unref(vehicleInventoryStore).vehicleInventoryData.playerMoney:0,tabindex:`0`,"bng-nav-item":``,onClick:$event=>!vehicle.disabled&&select(vehicle,$event)},null,8,[`data`,`layout`,`selected`,`is-tutorial`,`money`,`onClick`])),[[unref(BngDisabled_default),vehicle.disabled],[unref(BngOnUiNav_default),void 0,`ok`,{asMouse:!0,focusRequired:!0}],[unref(BngPopover_default),unref(popId),`right-start`,{click:!0}]])),128)),createVNode(unref(bngPopoverMenu_default),{name:unref(popId),focus:``,onHide:_cache[9]||=$event=>selectedVehId.value=null},{default:withCtx(()=>[(openBlock(!0),createElementBlock(Fragment,null,renderList(unref(vehicleInventoryStore).vehicleInventoryData.chooseButtonsData,(buttonData,index)=>(openBlock(),createElementBlock(Fragment,{key:index},[buttonData.repairRequired&&vehSelected.value&&vehSelected.value.needsRepair&&!unref(vehicleInventoryStore).vehicleInventoryData.tutorialActive?(openBlock(),createBlock(unref(bngButton_default),{key:0,accent:unref(ACCENTS).menu,disabled:``},{default:withCtx(()=>[createTextVNode(toDisplayString(buttonData.buttonText)+` (Needs repair) `,1)]),_:2},1032,[`accent`])):vehSelected.value&&isFunctionAvailable(vehSelected.value,buttonData)?withDirectives((openBlock(),createBlock(unref(bngButton_default),{key:1,accent:unref(ACCENTS).menu,onClick:$event=>unref(vehicleInventoryStore).chooseVehicle(vehSelected.value.id,index)},{default:withCtx(()=>[createTextVNode(toDisplayString(buttonData.buttonText),1)]),_:2},1032,[`accent`,`onClick`])),[[unref(BngOnUiNav_default),void 0,`ok`,{focusRequired:!0,asMouse:!0}]]):createCommentVNode(``,!0)],64))),128)),vehSelected.value&&unref(vehicleInventoryStore).vehicleInventoryData.buttonsActive.returnLoanerEnabled&&vehSelected.value.returnLoanerPermission.allow?withDirectives((openBlock(),createBlock(unref(bngButton_default),{key:0,accent:unref(ACCENTS).menu,onClick:_cache[0]||=$event=>confirmReturnVehicle()},{default:withCtx(()=>[..._cache[10]||=[createTextVNode(` Return loaned vehicle `,-1)]]),_:1},8,[`accent`])),[[unref(BngOnUiNav_default),void 0,`ok`,{focusRequired:!0,asMouse:!0}]]):createCommentVNode(``,!0),vehSelected.value&&vehSelected.value.delayReason===`repair`?withDirectives((openBlock(),createBlock(unref(bngButton_default),{key:1,accent:unref(ACCENTS).menu,disabled:vehSelected.value.expediteRepairCost>unref(vehicleInventoryStore).vehicleInventoryData.playerMoney,onClick:_cache[1]||=$event=>confirmExpediteRepair(vehSelected.value)},{default:withCtx(()=>[_cache[11]||=createTextVNode(` Expedite Repair `,-1),createVNode(unref(bngUnit_default),{money:vehSelected.value.expediteRepairCost},null,8,[`money`])]),_:1},8,[`accent`,`disabled`])),[[unref(BngOnUiNav_default),void 0,`ok`,{focusRequired:!0,asMouse:!0}]]):createCommentVNode(``,!0),vehSelected.value&&vehSelected.value.delayReason!==`repair`&&unref(vehicleInventoryStore).vehicleInventoryData.buttonsActive.repairEnabled?withDirectives((openBlock(),createBlock(unref(bngButton_default),{key:2,accent:unref(ACCENTS).menu,disabled:!vehSelected.value.repairPermission.allow,onClick:_cache[2]||=$event=>openRepairMenu()},{default:withCtx(()=>[..._cache[12]||=[createTextVNode(` Repair `,-1)]]),_:1},8,[`accent`,`disabled`])),[[unref(BngOnUiNav_default),void 0,`ok`,{focusRequired:!0,asMouse:!0}]]):createCommentVNode(``,!0),vehSelected.value&&unref(vehicleInventoryStore).vehicleInventoryData.buttonsActive.storingEnabled&&!vehSelected.value.inStorage?withDirectives((openBlock(),createBlock(unref(bngButton_default),{key:3,accent:unref(ACCENTS).menu,disabled:!vehSelected.value.storePermission.allow,onClick:_cache[3]||=$event=>storeVehicle()},{default:withCtx(()=>[..._cache[13]||=[createTextVNode(` Put in storage `,-1)]]),_:1},8,[`accent`,`disabled`])),[[unref(BngOnUiNav_default),void 0,`ok`,{focusRequired:!0,asMouse:!0}]]):createCommentVNode(``,!0),vehSelected.value&&unref(vehicleInventoryStore).vehicleInventoryData.buttonsActive.favoriteEnabled?withDirectives((openBlock(),createBlock(unref(bngButton_default),{key:4,accent:unref(ACCENTS).menu,disabled:!vehSelected.value.favoritePermission.allow||vehSelected.value.favorite,onClick:_cache[4]||=$event=>setFavoriteVehicle()},{default:withCtx(()=>[..._cache[14]||=[createTextVNode(` Set as Favorite `,-1)]]),_:1},8,[`accent`,`disabled`])),[[unref(BngOnUiNav_default),void 0,`ok`,{focusRequired:!0,asMouse:!0}]]):createCommentVNode(``,!0),vehSelected.value?withDirectives((openBlock(),createBlock(unref(bngButton_default),{key:5,accent:unref(ACCENTS).menu,disabled:!vehSelected.value.licensePlateChangePermission.allow,onClick:_cache[5]||=$event=>personalizeLicensePlate(vehSelected.value)},{default:withCtx(()=>[..._cache[15]||=[createTextVNode(` Personalize license plate `,-1)]]),_:1},8,[`accent`,`disabled`])),[[unref(BngOnUiNav_default),void 0,`ok`,{focusRequired:!0,asMouse:!0}]]):createCommentVNode(``,!0),vehSelected.value?withDirectives((openBlock(),createBlock(unref(bngButton_default),{key:6,accent:unref(ACCENTS).menu,onClick:_cache[6]||=$event=>renameVehicle()},{default:withCtx(()=>[..._cache[16]||=[createTextVNode(` Rename vehicle `,-1)]]),_:1},8,[`accent`])),[[unref(BngOnUiNav_default),void 0,`ok`,{focusRequired:!0,asMouse:!0}]]):createCommentVNode(``,!0),vehSelected.value&&unref(vehicleInventoryStore).vehicleInventoryData.buttonsActive.sellEnabled&&!vehSelected.value.listedForSale?withDirectives((openBlock(),createBlock(unref(bngButton_default),{key:7,accent:unref(ACCENTS).menu,disabled:!vehSelected.value.sellPermission.allow,onClick:_cache[7]||=$event=>listVehicleForSaleFromContextMenu()},{default:withCtx(()=>[..._cache[17]||=[createTextVNode(` List vehicle for sale `,-1)]]),_:1},8,[`accent`,`disabled`])),[[unref(BngOnUiNav_default),void 0,`ok`,{focusRequired:!0,asMouse:!0}]]):createCommentVNode(``,!0),vehSelected.value&&unref(vehicleInventoryStore).vehicleInventoryData.buttonsActive.sellEnabled&&vehSelected.value.listedForSale?withDirectives((openBlock(),createBlock(unref(bngButton_default),{key:8,accent:unref(ACCENTS).menu,disabled:!vehSelected.value.sellPermission.allow,onClick:_cache[8]||=$event=>lookAtVehicleListing()},{default:withCtx(()=>[..._cache[18]||=[createTextVNode(` Go to vehicle listing `,-1)]]),_:1},8,[`accent`,`disabled`])),[[unref(BngOnUiNav_default),void 0,`ok`,{focusRequired:!0,asMouse:!0}]]):createCommentVNode(``,!0)]),_:1},8,[`name`])])),[[unref(BngDisabled_default),!unref(vehicleInventoryStore)]])}},VehicleList_default$1=__plugin_vue_export_helper_default(_sfc_main$145,[[`__scopeId`,`data-v-5a84a046`]]),_sfc_main$144=Object.assign({inheritAttrs:!1},{__name:`VehicleInventory`,setup(__props,{expose:__expose}){let vehicleInventoryStore=useVehicleInventoryStore(),attrs=useAttrs();return __expose({closeMenu:vehicleInventoryStore.closeMenu}),onBeforeMount(()=>{vehicleInventoryStore.requestInitialData()}),onUnmounted(()=>{Lua_default.extensions.hook(`onExitVehicleInventory`),vehicleInventoryStore.menuClosed(),vehicleInventoryStore.$dispose()}),(_ctx,_cache)=>(openBlock(),createBlock(VehicleList_default$1,normalizeProps(guardReactiveProps(unref(attrs))),null,16))}}),VehicleInventory_default=_sfc_main$144,_sfc_main$143={__name:`VehicleInventoryMain`,setup(__props){let vehicleInventoryStore=useVehicleInventoryStore(),router$1=useRouter(),title=computed(()=>vehicleInventoryStore.vehicleInventoryData.header||`My vehicles`);watch(()=>vehicleInventoryStore.vehIdToChooseAfterRepairPopup,(newId,oldId)=>{!oldId&&newId&&confirmRepair()});let confirmRepair=async vehicle=>{await openConfirmation(``,`Do you want to repair your previous vehicle?`,[{label:$translate.instant(`ui.common.yes`),value:!0,extras:{default:!0}},{label:$translate.instant(`ui.common.no`),value:!1,extras:{accent:ACCENTS.secondary}}])?vehicleInventoryStore.repairPopupAccept():vehicleInventoryStore.repairPopupDecline()},elInventory=ref(),close=()=>router$1.back();return onUnmounted(()=>{vehicleInventoryStore.$dispose()}),(_ctx,_cache)=>(openBlock(),createBlock(ComputerWrapper_default,{ref:`wrapper`,title:title.value,back:``,onBack:close},{default:withCtx(()=>[createVNode(VehicleInventory_default,{ref_key:`elInventory`,ref:elInventory,class:`vehicle-inventory`},null,512)]),_:1},8,[`title`]))}},VehicleInventoryMain_default=__plugin_vue_export_helper_default(_sfc_main$143,[[`__scopeId`,`data-v-88176408`]]);const useVehiclePurchaseStore=defineStore(`vehiclePurchase`,()=>{let{events:events$3}=useBridge(),purchaseType=ref(``),vehicleInfo=ref({}),playerMoney=ref(0),alreadyDidTestDrive=ref(!1),inventoryHasFreeSlot=ref(!1),tradeInVehicleInfo=ref({}),tradeInEnabled=ref(!1),forceTradeIn=ref(!1),locationSelectionEnabled=ref(!1),forceNoDelivery=ref(!1),makeDelivery=ref(!1),buyCustomLicensePlate=ref(!1),customLicensePlateText=ref(``),prices=ref({}),insuranceOptions=ref({}),finalPackagePrice=computed(()=>{let price=prices.value.finalPrice;return buyCustomLicensePlate.value&&(price+=prices.value.customLicensePlate),insuranceOptions.value.insuranceId>0&&(price+=insuranceOptions.value.priceMoney),price}),handlePurchaseData=data=>{vehicleInfo.value=data.vehicleInfo,playerMoney.value=data.playerMoney,inventoryHasFreeSlot.value=data.inventoryHasFreeSlot,purchaseType.value=data.purchaseType,tradeInEnabled.value=data.tradeInEnabled,locationSelectionEnabled.value=data.locationSelectionEnabled,forceNoDelivery.value=data.forceNoDelivery,prices.value=data.prices,makeDelivery.value=!1,buyCustomLicensePlate.value=!1,customLicensePlateText.value=``,alreadyDidTestDrive.value=data.alreadyDidTestDrive,forceTradeIn.value=data.forceTradeIn,insuranceOptions.value=data.insuranceOptions,data.tradeInVehicleInfo===void 0?tradeInVehicleInfo.value={}:tradeInVehicleInfo.value=data.tradeInVehicleInfo};function requestPurchaseData(){Lua_default.career_modules_vehicleShopping.sendPurchaseDataToUi()}function buyVehicle(makeDelivery$1){let options={makeDelivery:makeDelivery$1,insuranceId:insuranceOptions.value.insuranceId};buyCustomLicensePlate.value&&(options.licensePlateText=customLicensePlateText.value),Lua_default.career_modules_vehicleShopping.buyFromPurchaseMenu(purchaseType.value,options)}function inventoryIsEmpty(){return Lua_default.career_modules_inventory.isEmpty()}function chooseTradeInVehicle(){Lua_default.career_modules_vehicleShopping.openInventoryMenuForTradeIn()}function removeTradeInVehicle(){Lua_default.career_modules_vehicleShopping.removeTradeInVehicle()}function cancel(){Lua_default.career_modules_vehicleShopping.cancelPurchase(purchaseType.value)}function startTestDrive(){Lua_default.career_modules_inspectVehicle.startTestDrive()}function dispose$2(){listen(!1)}let listen=state=>{events$3[state?`on`:`off`](`vehiclePurchaseData`,handlePurchaseData)};return listen(!0),{buyVehicle,cancel,chooseTradeInVehicle,purchaseType,startTestDrive,dispose:dispose$2,forceNoDelivery,forceTradeIn,inventoryIsEmpty,inventoryHasFreeSlot,locationSelectionEnabled,makeDelivery,playerMoney,prices,finalPackagePrice,removeTradeInVehicle,requestPurchaseData,tradeInEnabled,tradeInVehicleInfo,vehicleInfo,buyCustomLicensePlate,customLicensePlateText,alreadyDidTestDrive,insuranceOptions}});var _hoisted_1$129={class:`header-row`},_hoisted_2$109={class:`header-seller-info`},_hoisted_3$97={class:`purchase-list`},_hoisted_4$77={class:`purchase-row`},_hoisted_5$66={class:`label`},_hoisted_6$52={class:`sub-info`},_hoisted_7$44={class:`price`},_hoisted_8$36={class:`current-price-line`},_hoisted_9$33={key:0,class:`old-price`},_hoisted_10$27={class:`sub-info`},_hoisted_11$25={key:0,class:`purchase-row thin light-blue`},_hoisted_12$20={class:`label category`},_hoisted_13$18={class:`price category`},_hoisted_14$18={class:`purchase-row thin light-blue`},_hoisted_15$18={class:`price`},_hoisted_16$18={key:1,class:`purchase-divider`},_hoisted_17$14={key:2,class:`purchase-row thin green`},_hoisted_18$12={class:`label`},_hoisted_19$9={class:`price`},_hoisted_20$8={class:`purchase-row`},_hoisted_21$8={class:`price`},_hoisted_22$7={class:`purchase-row thin yellow`},_hoisted_23$6={class:`price`},_hoisted_24$5={key:3,class:`purchase-row thin`},_hoisted_25$4={class:`price`},_hoisted_26$3={class:`purchase-row`},_hoisted_27$3={class:`price highlight-category`},_hoisted_28$2={key:4,class:`purchase-row money-warning red`},_hoisted_29$2={class:`label`},_hoisted_30$2={class:`price`},_hoisted_31$2={class:`purchase-customization-group`},_hoisted_32$2={class:`button-group`},_hoisted_33$2={key:0},_hoisted_34$2={key:1},_hoisted_35$1={key:2},_hoisted_36$1={class:`right-side`},_sfc_main$142={__name:`VehiclePurchaseMain`,setup(__props){useUINavScope(`vehiclePurchase`);let{showIfController}=storeToRefs(controls_default()),{units}=useBridge(),router$1=useRouter(),hasVehicle=ref(!1),licensePlateTextValid=ref(!0),vehiclePurchaseStore=useVehiclePurchaseStore(),store$1=useTasksStore(),tradeInButtonMessage=computed(()=>vehiclePurchaseStore.tradeInEnabled?hasVehicle.value?void 0:`You don't own any vehicles`:`Trade in only possible in person at a dealership`),testDriveButtonMessage=computed(()=>{if(vehiclePurchaseStore.purchaseType!==`inspect`)return`Test drive only available for inspect purchases`;if(vehiclePurchaseStore.alreadyDidTestDrive)return`You have already done a test drive`}),vehicleFitsInventory=computed(()=>vehiclePurchaseStore.vehicleInfo.takesNoInventorySpace?!0:vehiclePurchaseStore.inventoryHasFreeSlot||vehiclePurchaseStore.tradeInVehicleInfo.niceName&&!vehiclePurchaseStore.tradeInVehicleInfo.takesNoInventorySpace);vehiclePurchaseStore.inventoryIsEmpty().then(empty=>{hasVehicle.value=!empty});let buy=()=>buyVehicle(!vehiclePurchaseStore.locationSelectionEnabled||vehiclePurchaseStore.makeDelivery),cancel=()=>{router$1.back()},startTestDrive=()=>{vehiclePurchaseStore.startTestDrive()},chooseTradeInVehicle=()=>{vehiclePurchaseStore.chooseTradeInVehicle()},chooseInsurance=()=>{addPopup(ChooseInsuranceMain_default,{menuMode:`purchase`,params:{purchaseType:vehiclePurchaseStore.purchaseType,shopId:vehiclePurchaseStore.vehicleInfo.shopId,insuranceId:vehiclePurchaseStore.insuranceOptions.insuranceId}})},negotiatePrice=()=>{Lua_default.career_modules_marketplace.startNegotiateSellingOffer(vehiclePurchaseStore.vehicleInfo.shopId)},removeTradeInVehicle=()=>{vehiclePurchaseStore.removeTradeInVehicle()},buyVehicle=_makeDelivery=>{vehiclePurchaseStore.buyVehicle(_makeDelivery)};return onMounted(()=>{vehiclePurchaseStore.requestPurchaseData()}),onUnmounted(async()=>{await Lua_default.career_modules_inspectVehicle.onPurchaseMenuClosed(),vehiclePurchaseStore.$dispose()}),(_ctx,_cache)=>(openBlock(),createBlock(unref(layoutSingle_default),{class:`purchase-layout`},{default:withCtx(()=>[unref(vehiclePurchaseStore).vehicleInfo.niceName?withDirectives((openBlock(),createBlock(unref(bngCard_default),{key:0,"bng-ui-scope":`vehiclePurchase`,class:`purchase-screen`},{buttons:withCtx(()=>[createBaseVNode(`div`,_hoisted_32$2,[withDirectives((openBlock(),createBlock(unref(bngButton_default),{disabled:unref(vehiclePurchaseStore).purchaseType!==`inspect`||unref(vehiclePurchaseStore).alreadyDidTestDrive,onClick:startTestDrive,accent:unref(ACCENTS).secondary},{default:withCtx(()=>[..._cache[16]||=[createTextVNode(`Test Drive`,-1)]]),_:1},8,[`disabled`,`accent`])),[[unref(BngTooltip_default),testDriveButtonMessage.value,`top`]]),withDirectives((openBlock(),createBlock(unref(bngButton_default),{disabled:unref(vehiclePurchaseStore).finalPackagePrice>unref(vehiclePurchaseStore).playerMoney||!vehicleFitsInventory.value||unref(vehiclePurchaseStore).forceTradeIn&&!unref(vehiclePurchaseStore).tradeInVehicleInfo.niceName||unref(vehiclePurchaseStore).buyCustomLicensePlate&&!licensePlateTextValid.value,"show-hold":``},{default:withCtx(()=>[unref(vehiclePurchaseStore).finalPackagePrice>unref(vehiclePurchaseStore).playerMoney?(openBlock(),createElementBlock(`div`,_hoisted_33$2,`Insufficient Funds`)):vehicleFitsInventory.value?(openBlock(),createElementBlock(`div`,_hoisted_35$1,`Purchase`)):(openBlock(),createElementBlock(`div`,_hoisted_34$2,`No free inventory slots`))]),_:1},8,[`disabled`])),[[unref(BngOnUiNav_default),void 0,`ok`,{asMouse:!0,focusRequired:!0}],[unref(BngClick_default),{holdCallback:buy,holdDelay:1e3,repeatInterval:0}]])])]),default:withCtx(()=>[createBaseVNode(`div`,_hoisted_1$129,[createVNode(unref(bngCardHeading_default),{type:`ribbon`},{default:withCtx(()=>[_cache[0]||=createTextVNode(` Purchase Information `,-1),createBaseVNode(`div`,_hoisted_2$109,` Purchasing from: `+toDisplayString(unref(vehiclePurchaseStore).vehicleInfo.sellerName),1)]),_:1}),createVNode(unref(bngButton_default),{class:`close-button`,onClick:cancel,accent:unref(ACCENTS).attention,"bng-no-nav":`true`,tabindex:`-1`},{default:withCtx(()=>[createVNode(unref(bngBinding_default),{"ui-event":`menu`,controller:``}),createVNode(unref(bngIcon_default),{type:`xmarkBold`,color:`var(--bng-cool-gray-100)`})]),_:1},8,[`accent`])]),createBaseVNode(`div`,_hoisted_3$97,[createBaseVNode(`div`,_hoisted_4$77,[createBaseVNode(`div`,_hoisted_5$66,[createBaseVNode(`div`,null,toDisplayString(unref(vehiclePurchaseStore).vehicleInfo.year)+` `+toDisplayString(unref(vehiclePurchaseStore).vehicleInfo.niceName),1),createBaseVNode(`div`,_hoisted_6$52,`(`+toDisplayString(unref(units).buildString(`length`,unref(vehiclePurchaseStore).vehicleInfo.Mileage,0))+`)`,1)]),createBaseVNode(`div`,_hoisted_7$44,[createBaseVNode(`div`,_hoisted_8$36,[unref(vehiclePurchaseStore).vehicleInfo.originalSellValue?(openBlock(),createElementBlock(`span`,_hoisted_9$33,[createVNode(unref(bngUnit_default),{money:unref(vehiclePurchaseStore).vehicleInfo.originalSellValue},null,8,[`money`])])):createCommentVNode(``,!0),createVNode(unref(bngUnit_default),{class:`money`,money:unref(vehiclePurchaseStore).vehicleInfo.Value},null,8,[`money`])]),createBaseVNode(`div`,_hoisted_10$27,[createBaseVNode(`div`,null,[_cache[1]||=createTextVNode(` Est. Market: `,-1),createVNode(unref(bngUnit_default),{class:`money`,money:unref(vehiclePurchaseStore).vehicleInfo.marketValue},null,8,[`money`])])])])]),_cache[13]||=createBaseVNode(`div`,{class:`purchase-divider`},null,-1),unref(vehiclePurchaseStore).insuranceOptions.insuranceId>0?(openBlock(),createElementBlock(`div`,_hoisted_11$25,[createBaseVNode(`div`,_hoisted_12$20,toDisplayString(unref(vehiclePurchaseStore).insuranceOptions.spendingReason),1),createBaseVNode(`div`,_hoisted_13$18,[createVNode(unref(bngUnit_default),{class:`money`,money:unref(vehiclePurchaseStore).insuranceOptions.priceMoney},null,8,[`money`])])])):createCommentVNode(``,!0),createBaseVNode(`div`,_hoisted_14$18,[_cache[2]||=createBaseVNode(`div`,{class:`label`},`Dealership Fees`,-1),createBaseVNode(`div`,_hoisted_15$18,[createVNode(unref(bngUnit_default),{class:`money`,money:unref(vehiclePurchaseStore).vehicleInfo.fees},null,8,[`money`])])]),unref(vehiclePurchaseStore).tradeInVehicleInfo?.niceName?(openBlock(),createElementBlock(`div`,_hoisted_16$18)):createCommentVNode(``,!0),unref(vehiclePurchaseStore).tradeInVehicleInfo.niceName?(openBlock(),createElementBlock(`div`,_hoisted_17$14,[createBaseVNode(`div`,_hoisted_18$12,`Trade-in: `+toDisplayString(unref(vehiclePurchaseStore).tradeInVehicleInfo.niceName),1),createBaseVNode(`div`,_hoisted_19$9,[createVNode(unref(bngUnit_default),{class:`money`,money:-unref(vehiclePurchaseStore).tradeInVehicleInfo.Value},null,8,[`money`])])])):createCommentVNode(``,!0),_cache[14]||=createBaseVNode(`div`,{class:`purchase-divider`},null,-1),createBaseVNode(`div`,_hoisted_20$8,[_cache[3]||=createBaseVNode(`div`,{class:`label`},`Subtotal`,-1),createBaseVNode(`div`,_hoisted_21$8,[createVNode(unref(bngUnit_default),{class:`money`,money:unref(vehiclePurchaseStore).finalPackagePrice-unref(vehiclePurchaseStore).prices.taxes-(unref(vehiclePurchaseStore).buyCustomLicensePlate?unref(vehiclePurchaseStore).prices.customLicensePlate:0)},null,8,[`money`])])]),createBaseVNode(`div`,_hoisted_22$7,[_cache[4]||=createBaseVNode(`div`,{class:`label`},`Sales Tax (7%)`,-1),createBaseVNode(`div`,_hoisted_23$6,[createVNode(unref(bngUnit_default),{class:`money`,money:unref(vehiclePurchaseStore).prices.taxes},null,8,[`money`])])]),unref(vehiclePurchaseStore).buyCustomLicensePlate?(openBlock(),createElementBlock(`div`,_hoisted_24$5,[_cache[5]||=createBaseVNode(`div`,{class:`label`},`Custom License Plate`,-1),createBaseVNode(`div`,_hoisted_25$4,[createVNode(unref(bngUnit_default),{class:`money`,money:unref(vehiclePurchaseStore).prices.customLicensePlate},null,8,[`money`])])])):createCommentVNode(``,!0),_cache[15]||=createBaseVNode(`div`,{class:`purchase-divider`},null,-1),createBaseVNode(`div`,_hoisted_26$3,[_cache[6]||=createBaseVNode(`div`,{class:`label highlight-category`},`Total`,-1),createBaseVNode(`div`,_hoisted_27$3,[createVNode(unref(bngUnit_default),{class:`money`,money:unref(vehiclePurchaseStore).finalPackagePrice},null,8,[`money`])])]),unref(vehiclePurchaseStore).finalPackagePrice>unref(vehiclePurchaseStore).playerMoney?(openBlock(),createElementBlock(`div`,_hoisted_28$2,[createBaseVNode(`div`,_hoisted_29$2,[createVNode(unref(bngIcon_default),{type:`danger`}),_cache[7]||=createTextVNode(` Additional funds required`,-1)]),createBaseVNode(`div`,_hoisted_30$2,[createVNode(unref(bngUnit_default),{class:`money`,money:unref(vehiclePurchaseStore).finalPackagePrice-unref(vehiclePurchaseStore).playerMoney},null,8,[`money`])])])):createCommentVNode(``,!0),createBaseVNode(`div`,_hoisted_31$2,[_cache[12]||=createBaseVNode(`h4`,null,`Purchase Options`,-1),createVNode(unref(bngButton_default),{disabled:!unref(vehiclePurchaseStore).vehicleInfo.negotiationPossible,accent:`secondary`,onClick:negotiatePrice},{default:withCtx(()=>[..._cache[8]||=[createTextVNode(` Negotiate Price `,-1)]]),_:1},8,[`disabled`]),withDirectives((openBlock(),createBlock(unref(bngButton_default),{disabled:!unref(vehiclePurchaseStore).tradeInEnabled||!hasVehicle.value,accent:`secondary`,onClick:chooseTradeInVehicle},{default:withCtx(()=>[..._cache[9]||=[createTextVNode(`Choose Trade-In`,-1)]]),_:1},8,[`disabled`])),[[unref(BngTooltip_default),tradeInButtonMessage.value,`top`]]),unref(vehiclePurchaseStore).tradeInEnabled&&unref(vehiclePurchaseStore).tradeInVehicleInfo.niceName?(openBlock(),createBlock(unref(bngButton_default),{key:0,onClick:removeTradeInVehicle,accent:unref(ACCENTS).attention},{default:withCtx(()=>[..._cache[10]||=[createTextVNode(`Remove Trade-In`,-1)]]),_:1},8,[`accent`])):createCommentVNode(``,!0),createVNode(unref(bngButton_default),{onClick:chooseInsurance,accent:unref(ACCENTS).secondary},{default:withCtx(()=>[..._cache[11]||=[createTextVNode(`Choose Insurance`,-1)]]),_:1},8,[`accent`])])])]),_:1})),[[unref(BngBlur_default),1]]):createCommentVNode(``,!0),createBaseVNode(`div`,_hoisted_36$1,[createVNode(unref(bngCard_default),{class:`status-container`},{default:withCtx(()=>[createVNode(unref(careerStatus_default),{class:`profile-status`})]),_:1}),createVNode(TaskList_default,{class:`task-list`,header:unref(store$1).header,tasks:unref(store$1).tasks},null,8,[`header`,`tasks`])])]),_:1}))}},VehiclePurchaseMain_default=__plugin_vue_export_helper_default(_sfc_main$142,[[`__scopeId`,`data-v-b2028538`]]);const useVehicleShoppingStore=defineStore(`vehicleShopping`,()=>{let selectedSellerId=ref(``),currentSeller=ref({}),vehicleShoppingData=ref({}),filteredVehicles=ref([]),filteredSoldVehicles=ref([]),buildFilteredListByKey=(data,key)=>{if(!data||!data[key])return[];let filteredList=Object.keys(data[key]).reduce((result,itemKey)=>{let item=data[key][itemKey];return selectedSellerId.value?item.sellerId===selectedSellerId.value&&result.push(item):result.push(item),result},[]);return filteredList.length&&filteredList.sort((a$1,b)=>a$1.Value-b.Value),filteredList},updateListsFromData=()=>{filteredVehicles.value=buildFilteredListByKey(vehicleShoppingData.value,`vehiclesInShop`),filteredSoldVehicles.value=buildFilteredListByKey(vehicleShoppingData.value,`soldVehicles`)};return{vehicleShoppingData,filteredVehicles,filteredSoldVehicles,currentSeller,requestVehicleShoppingData:async()=>{vehicleShoppingData.value=await Lua_default.career_modules_vehicleShopping.getShoppingData(),updateListsFromData()},setSelectedSellerId:sellerId=>{selectedSellerId.value=sellerId,updateListsFromData(),currentSeller.value=vehicleShoppingData.value.uiDealershipsData.find(dealership=>dealership.id===sellerId)}}});var _hoisted_1$128={class:`cover-container`},_hoisted_2$108={key:0,class:`sold-overlay`},_hoisted_3$96={class:`car-details`},_hoisted_4$76={class:`car-value`},_hoisted_5$65={class:`name`},_hoisted_6$51={class:`brand`},_hoisted_7$43={class:`main-data`},_hoisted_8$35={key:0,class:`price`},_hoisted_9$32={class:`was`},_hoisted_10$26={class:`sold`},_hoisted_11$24={key:0,class:`market`},_hoisted_12$19={key:1,class:`price`},_hoisted_13$17={key:0},_hoisted_14$17={key:1,style:{color:`rgb(245, 29, 29)`}},_hoisted_15$17={key:2,class:`market`},_hoisted_16$17={class:`car-data`},_hoisted_17$13={style:{width:`100%`}},_hoisted_18$11={key:0,style:{flex:`1 0 auto`,"justify-content":`flex-end`,padding:`0.5em 0.75em`,"font-weight":`400`,"font-family":`var(--fnt-defs)`}},DRIVE_TRAIN_ICONS={AWD:icons.AWD,"4WD":icons[`4WD`],FWD:icons.FWD,RWD:icons.RWD,drivetrain_special:icons.drivetrainSpecial,drivetrain_generic:icons.drivetrainGeneric,defaultMissing:icons.drivetrainGeneric,defaultUnknown:icons.drivetrainGeneric},FUEL_TYPE_ICONS={Battery:icons.charge,Gasoline:icons.fuelPump,Diesel:icons.fuelPump,defaultMissing:icons.fuelPump,defaultUnknown:icons.fuelPump},TRANSMISSION_ICONS={Automatic:icons.transmissionA,Manual:icons.transmissionM,defaultMissing:icons.transmissionM,defaultUnknown:icons.transmissionM},_sfc_main$141={__name:`VehicleCard`,props:{vehicleShoppingData:Object,vehicle:Object},setup(__props){let{units}=useBridge(),props=__props,soldPercent=computed(()=>{let asking=props.vehicle?.Value,sold=props.vehicle?.soldFor;return!asking||!sold?0:(sold-asking)/asking*100}),soldDeltaPrefix=computed(()=>soldPercent.value>=0?`+`:``),soldDeltaClass=computed(()=>soldPercent.value>0?`up`:soldPercent.value<0?`down`:`flat`),confirmTaxi=async vehicle=>{await openConfirmation(``,`Do you want to taxi to this vehicle for ${units.beamBucks(vehicle.quickTravelPrice)}?`,[{label:$translate.instant(`ui.common.yes`),value:!0,extras:{default:!0}},{label:$translate.instant(`ui.common.no`),value:!1,extras:{accent:ACCENTS.secondary}}])&&quickTravelToVehicle(vehicle)},showVehicle=shopId=>{Lua_default.career_modules_vehicleShopping.showVehicle(shopId)},quickTravelToVehicle=vehicle=>{Lua_default.career_modules_vehicleShopping.quickTravelToVehicle(vehicle.shopId)},openPurchaseMenu=(purchaseType,shopId)=>{Lua_default.career_modules_vehicleShopping.openPurchaseMenu(purchaseType,shopId)},getAttributeIcon=(vehicle,attribute)=>{let iconDict;return attribute==`Drivetrain`?iconDict=DRIVE_TRAIN_ICONS:attribute==`Fuel Type`?iconDict=FUEL_TYPE_ICONS:attribute==`Transmission`&&(iconDict=TRANSMISSION_ICONS),vehicle[attribute]?iconDict[vehicle[attribute]]||iconDict.defaultUnknown:iconDict.defaultMissing};return(_ctx,_cache)=>(openBlock(),createBlock(unref(bngCard_default),{class:normalizeClass(`vehicle-card row`)},{buttons:withCtx(()=>[createBaseVNode(`div`,_hoisted_17$13,[__props.vehicleShoppingData.currentSeller?createCommentVNode(``,!0):(openBlock(),createBlock(unref(bngPropVal_default),{key:0,style:{float:`left`},keyLabel:`Seller:`,valueLabel:__props.vehicle.sellerName},null,8,[`valueLabel`])),__props.vehicleShoppingData.currentSeller?createCommentVNode(``,!0):(openBlock(),createBlock(unref(bngPropVal_default),{key:1,style:{float:`left`},keyLabel:`Distance:`,valueLabel:unref(units).buildString(`length`,__props.vehicle.distance,1)},null,8,[`valueLabel`])),createVNode(unref(bngPropVal_default),{style:{float:`left`},keyLabel:`Insurance Class:`,valueLabel:__props.vehicle.insuranceClass?.name??`Unknown`},null,8,[`valueLabel`])]),__props.vehicleShoppingData.disableShopping?(openBlock(),createElementBlock(`span`,_hoisted_18$11,toDisplayString(__props.vehicleShoppingData.disableShoppingReason),1)):createCommentVNode(``,!0),__props.vehicle.sellerId===__props.vehicleShoppingData.currentSeller?(openBlock(),createBlock(unref(bngButton_default),{key:1,onClick:_cache[0]||=$event=>showVehicle(__props.vehicle.shopId),accent:unref(ACCENTS).secondary,disabled:__props.vehicleShoppingData.disableShopping||!!__props.vehicle.soldViewCounter},{default:withCtx(()=>[..._cache[10]||=[createTextVNode(`Inspect Vehicle`,-1)]]),_:1},8,[`accent`,`disabled`])):(openBlock(),createBlock(unref(bngButton_default),{key:2,onClick:_cache[1]||=$event=>showVehicle(__props.vehicle.shopId),accent:unref(ACCENTS).secondary,disabled:__props.vehicleShoppingData.disableShopping||!!__props.vehicle.soldViewCounter},{default:withCtx(()=>[..._cache[11]||=[createTextVNode(`Set Route`,-1)]]),_:1},8,[`accent`,`disabled`])),__props.vehicleShoppingData.currentSeller?createCommentVNode(``,!0):(openBlock(),createBlock(unref(bngButton_default),{key:3,disabled:__props.vehicleShoppingData.playerAttributes.money.value<__props.vehicle.quickTravelPrice||__props.vehicleShoppingData.disableShopping||!!__props.vehicle.soldViewCounter,onClick:_cache[2]||=$event=>confirmTaxi(__props.vehicle),accent:__props.vehicle.sellerId===`private`?unref(ACCENTS).main:unref(ACCENTS).secondary},{default:withCtx(()=>[..._cache[12]||=[createBaseVNode(`span`,{style:{flex:`1 0 auto`}},`Take Taxi`,-1)]]),_:1},8,[`disabled`,`accent`])),__props.vehicle.sellerId===`private`?createCommentVNode(``,!0):(openBlock(),createBlock(unref(bngButton_default),{key:4,disabled:__props.vehicleShoppingData.tutorialPurchase||__props.vehicleShoppingData.disableShopping||!!__props.vehicle.soldViewCounter,onClick:_cache[3]||=$event=>openPurchaseMenu(`instant`,__props.vehicle.shopId)},{default:withCtx(()=>[..._cache[13]||=[createTextVNode(`Purchase`,-1)]]),_:1},8,[`disabled`]))]),default:withCtx(()=>[createBaseVNode(`div`,_hoisted_1$128,[createVNode(unref(aspectRatio_default),{class:`cover`,ratio:`16:9`,"external-image":__props.vehicle.preview},null,8,[`external-image`]),__props.vehicle.soldViewCounter>0?(openBlock(),createElementBlock(`div`,_hoisted_2$108,`SOLD`)):createCommentVNode(``,!0)]),createBaseVNode(`div`,_hoisted_3$96,[createBaseVNode(`div`,_hoisted_4$76,[createBaseVNode(`div`,{class:normalizeClass([`car-name`,{sold:__props.vehicle.soldViewCounter>0}])},[createBaseVNode(`h3`,_hoisted_5$65,toDisplayString(__props.vehicle.year)+` `+toDisplayString(__props.vehicle.Name)+` `+toDisplayString(__props.vehicle.soldViewCounter>0?` (Sold)`:``),1),createBaseVNode(`div`,_hoisted_6$51,toDisplayString(__props.vehicle.Brand),1)],2),createBaseVNode(`div`,_hoisted_7$43,[createVNode(unref(bngPropVal_default),{class:`prop-small`,iconColor:`var(--bng-cool-gray-300)`,iconType:unref(icons).bus,valueLabel:unref(units).buildString(`length`,__props.vehicle.Mileage,0)},null,8,[`iconType`,`valueLabel`]),createVNode(unref(bngPropVal_default),{class:`prop-small`,style:{flex:`1 0 auto`},iconColor:`var(--bng-cool-gray-300)`,iconType:unref(icons).bus,valueLabel:__props.vehicle.Drivetrain},null,8,[`iconType`,`valueLabel`]),__props.vehicle.soldFor?(openBlock(),createElementBlock(`div`,_hoisted_8$35,[createBaseVNode(`div`,_hoisted_9$32,[_cache[4]||=createTextVNode(`Was: `,-1),createVNode(unref(bngUnit_default),{money:__props.vehicle.Value},null,8,[`money`])]),createBaseVNode(`div`,_hoisted_10$26,[_cache[5]||=createTextVNode(`Sold for: `,-1),createVNode(unref(bngUnit_default),{class:`car-price`,money:__props.vehicle.soldFor},null,8,[`money`])]),createBaseVNode(`div`,{class:normalizeClass([`delta`,soldDeltaClass.value])},toDisplayString(soldDeltaPrefix.value)+toDisplayString(soldPercent.value.toFixed(1))+`% from asking`,3),__props.vehicle.marketValue?(openBlock(),createElementBlock(`div`,_hoisted_11$24,[_cache[6]||=createTextVNode(`Market: `,-1),createVNode(unref(bngUnit_default),{money:__props.vehicle.marketValue},null,8,[`money`])])):createCommentVNode(``,!0)])):(openBlock(),createElementBlock(`div`,_hoisted_12$19,[__props.vehicle.Value<=__props.vehicleShoppingData.playerAttributes.money.value?(openBlock(),createElementBlock(`div`,_hoisted_13$17,[createVNode(unref(bngUnit_default),{class:`car-price`,money:__props.vehicle.Value},null,8,[`money`]),_cache[7]||=createTextVNode(`*`,-1)])):(openBlock(),createElementBlock(`div`,_hoisted_14$17,[createVNode(unref(bngUnit_default),{class:`car-price`,money:__props.vehicle.Value},null,8,[`money`]),_cache[8]||=createTextVNode(`* Insufficient Funds`,-1)])),__props.vehicle.marketValue?(openBlock(),createElementBlock(`div`,_hoisted_15$17,[_cache[9]||=createTextVNode(`Market: `,-1),createVNode(unref(bngUnit_default),{money:__props.vehicle.marketValue},null,8,[`money`])])):createCommentVNode(``,!0)]))])]),createBaseVNode(`div`,_hoisted_16$17,[__props.vehicle.Power==null?createCommentVNode(``,!0):(openBlock(),createBlock(unref(bngPropVal_default),{key:0,iconType:unref(icons).powerGauge04,keyLabel:`Power:`,valueLabel:unref(units).buildString(`power`,__props.vehicle.Power,0)},null,8,[`iconType`,`valueLabel`])),__props.vehicle.Mileage==null?createCommentVNode(``,!0):(openBlock(),createBlock(unref(bngPropVal_default),{key:1,iconType:unref(icons).odometer,keyLabel:`Mileage:`,valueLabel:unref(units).buildString(`length`,__props.vehicle.Mileage,0)},null,8,[`iconType`,`valueLabel`])),__props.vehicle.Transmission==null?createCommentVNode(``,!0):(openBlock(),createBlock(unref(bngPropVal_default),{key:2,iconType:getAttributeIcon(__props.vehicle,`Transmission`),keyLabel:`Transmission:`,valueLabel:__props.vehicle.Transmission},null,8,[`iconType`,`valueLabel`])),__props.vehicle[`Fuel Type`]==null?createCommentVNode(``,!0):(openBlock(),createBlock(unref(bngPropVal_default),{key:3,iconType:getAttributeIcon(__props.vehicle,`Fuel Type`),keyLabel:`Fuel type:`,valueLabel:__props.vehicle[`Fuel Type`]},null,8,[`iconType`,`valueLabel`])),__props.vehicle.Drivetrain==null?createCommentVNode(``,!0):(openBlock(),createBlock(unref(bngPropVal_default),{key:4,iconType:getAttributeIcon(__props.vehicle,`Drivetrain`),keyLabel:`Drivetrain:`,valueLabel:__props.vehicle.Drivetrain},null,8,[`iconType`,`valueLabel`])),__props.vehicle.Weight==null?createCommentVNode(``,!0):(openBlock(),createBlock(unref(bngPropVal_default),{key:5,iconType:unref(icons).weight,keyLabel:`Weight:`,valueLabel:unref(units).buildString(`weight`,__props.vehicle.Weight,0)},null,8,[`iconType`,`valueLabel`]))])])]),_:1}))}},VehicleCard_default=__plugin_vue_export_helper_default(_sfc_main$141,[[`__scopeId`,`data-v-dea06661`]]),_hoisted_1$127={class:`site-body`,"bng-nav-scroll":``,"bng-nav-scroll-force":``},_hoisted_2$107={class:`heading`},_hoisted_3$95={class:`header-text`},_hoisted_4$75={key:0,class:`vehicle-list`},_hoisted_5$64={key:1,class:`vehicle-list sold-list`},_hoisted_6$50={class:`list-section-title`},_sfc_main$140={__name:`VehicleList`,setup(__props){useUINavScope(`vehicleList`);let vehicleShoppingStore=useVehicleShoppingStore(),getHeaderText=()=>vehicleShoppingStore?.currentSeller?.name||`BeamCar24`;return reactive([{name:`switch`,selected:!0,class:``},{name:`me`,selected:!1,class:``},{name:`please`,selected:!1,class:``}]),(_ctx,_cache)=>withDirectives((openBlock(),createBlock(unref(bngCard_default),{class:`vehicle-shop-wrapper`,"bng-ui-scope":`vehicleList`},{default:withCtx(()=>[createBaseVNode(`div`,_hoisted_1$127,[createBaseVNode(`div`,_hoisted_2$107,[createBaseVNode(`span`,_hoisted_3$95,toDisplayString(getHeaderText()),1),_cache[0]||=createBaseVNode(`span`,{class:`price-notice`},[createBaseVNode(`span`,null,`*\xA0`),createBaseVNode(`span`,null,`Additional taxes and fees are applicable`)],-1)]),unref(vehicleShoppingStore)?(openBlock(),createElementBlock(`div`,_hoisted_4$75,[(openBlock(!0),createElementBlock(Fragment,null,renderList(unref(vehicleShoppingStore).filteredVehicles,(vehicle,key)=>(openBlock(),createBlock(VehicleCard_default,{key,vehicleShoppingData:unref(vehicleShoppingStore).vehicleShoppingData,vehicle},null,8,[`vehicleShoppingData`,`vehicle`]))),128))])):createCommentVNode(``,!0),unref(vehicleShoppingStore)&&unref(vehicleShoppingStore).filteredSoldVehicles&&unref(vehicleShoppingStore).filteredSoldVehicles.length>0?(openBlock(),createElementBlock(`div`,_hoisted_5$64,[createBaseVNode(`div`,_hoisted_6$50,`Recently Sold Vehicles You Viewed (`+toDisplayString(unref(vehicleShoppingStore).filteredSoldVehicles.length)+`)`,1),(openBlock(!0),createElementBlock(Fragment,null,renderList(unref(vehicleShoppingStore).filteredSoldVehicles,(vehicle,key)=>(openBlock(),createBlock(VehicleCard_default,{key,vehicleShoppingData:unref(vehicleShoppingStore).vehicleShoppingData,vehicle},null,8,[`vehicleShoppingData`,`vehicle`]))),128))])):createCommentVNode(``,!0)])]),_:1})),[[unref(BngBlur_default)]])}},VehicleList_default=__plugin_vue_export_helper_default(_sfc_main$140,[[`__scopeId`,`data-v-5045aa89`]]),_hoisted_1$126={class:`veh-part-caption`},_hoisted_2$106={class:`veh-name`},_hoisted_3$94={class:`veh-name-count`},_hoisted_4$74={class:`veh-price`},_hoisted_5$63={class:`veh-remove`},_hoisted_6$49={key:0,class:`offer-card red`},_hoisted_7$42=[`onMouseover`,`onMouseleave`,`onActivate`,`onDeactivate`],_hoisted_8$34={class:`offer-info`},_hoisted_9$31={class:`offer-header`},_hoisted_10$25={class:`buyer-name`},_hoisted_11$23={key:0,class:`expired-badge`},_hoisted_12$18={class:`offer-details`},_hoisted_13$16={class:`detail-row`},_hoisted_14$16={class:`detail-row`},_hoisted_15$16={class:`spec-actions`},_hoisted_16$16={key:1,class:`offer-card`},_sfc_main$139={__name:`VehicleMarketplace`,setup(__props){useComputerStore();let listings=ref([]),confirmRemoveListingScreen=async listingId=>{await openConfirmation(``,`Do you want to remove this listing?`,[{label:$translate.instant(`ui.common.yes`),value:!0,extras:{default:!0}},{label:$translate.instant(`ui.common.no`),value:!1,extras:{accent:ACCENTS.secondary}}])&&removeVehicleListing(listingId)},onActivated$1=offer=>{offer.active=!0},onDeactivated$1=offer=>{offer.active=!1},onOfferHovered=offer=>{offer.hovered=!0},onOfferUnhovered=offer=>{offer.hovered=!1},handleListings=data=>{listings.value=data},getNewData=()=>{Lua_default.career_modules_marketplace.getListings().then(handleListings)},acceptOffer=(inventoryId,offerIndex)=>{Lua_default.career_modules_marketplace.acceptOffer(inventoryId,offerIndex+1).then(getNewData)},declineOffer=(inventoryId,offerIndex)=>{Lua_default.career_modules_marketplace.declineOffer(inventoryId,offerIndex+1).then(getNewData)},startNegotiateBuyingOffer=(inventoryId,offerIndex)=>{Lua_default.career_modules_marketplace.startNegotiateBuyingOffer(inventoryId,offerIndex+1).then(getNewData)},removeVehicleListing=inventoryId=>{Lua_default.career_modules_marketplace.removeVehicleListing(inventoryId).then(getNewData)},listVehicle=()=>{Lua_default.career_modules_inventory.openInventoryMenuForChoosingListing()};return onMounted(()=>{Lua_default.career_modules_marketplace.menuOpened(!0),getNewData()}),onUnmounted(()=>{Lua_default.career_modules_marketplace.menuOpened(!1)}),(_ctx,_cache)=>(openBlock(),createElementBlock(Fragment,null,[createVNode(unref(accordion_default),{class:`part-groups`,items:listings.value},{default:withCtx(()=>[(openBlock(!0),createElementBlock(Fragment,null,renderList(listings.value,listing=>(openBlock(),createBlock(unref(accordionItem_default),{key:listing.id,expanded:!0,class:normalizeClass([`marketplace-listing`,{disabled:listing.disabled}])},{caption:withCtx(()=>[createBaseVNode(`div`,_hoisted_1$126,[listing.thumbnail?(openBlock(),createElementBlock(`div`,{key:0,class:`veh-preview`,style:normalizeStyle({backgroundImage:`url('${listing.thumbnail}')`})},null,4)):createCommentVNode(``,!0),createBaseVNode(`span`,_hoisted_2$106,[createTextVNode(toDisplayString(listing.niceName)+` `,1),createBaseVNode(`span`,_hoisted_3$94,`(`+toDisplayString(listing.offers.length||0)+`)`,1)]),createBaseVNode(`span`,_hoisted_4$74,[createBaseVNode(`div`,null,[_cache[0]||=createTextVNode(` Asking Price: `,-1),createVNode(unref(bngUnit_default),{money:listing.value},null,8,[`money`])]),createBaseVNode(`div`,null,[_cache[1]||=createTextVNode(` Estimated Market Value: `,-1),createVNode(unref(bngUnit_default),{money:listing.marketValue},null,8,[`money`])])]),createBaseVNode(`span`,_hoisted_5$63,[createVNode(unref(bngButton_default),{onClick:withModifiers($event=>confirmRemoveListingScreen(listing.id),[`stop`]),icon:unref(icons).trashBin1,accent:unref(ACCENTS).attentionghost},null,8,[`onClick`,`icon`,`accent`])])])]),default:withCtx(()=>[listing.disabled?(openBlock(),createElementBlock(`div`,_hoisted_6$49,toDisplayString(listing.disableReason),1)):createCommentVNode(``,!0),(openBlock(!0),createElementBlock(Fragment,null,renderList(listing.offers,(offer,index)=>withDirectives((openBlock(),createElementBlock(`div`,{class:normalizeClass([`offer-card`,{expired:offer.expiredViewCounter==1}]),onMouseover:$event=>onOfferHovered(offer),onMouseleave:$event=>onOfferUnhovered(offer),onActivate:$event=>onActivated$1(offer),onDeactivate:$event=>onDeactivated$1(offer)},[createBaseVNode(`div`,_hoisted_8$34,[createBaseVNode(`div`,_hoisted_9$31,[createBaseVNode(`span`,_hoisted_10$25,toDisplayString(offer.buyerPersonality.name),1),offer.expiredViewCounter?(openBlock(),createElementBlock(`span`,_hoisted_11$23,`EXPIRED`)):createCommentVNode(``,!0)]),createBaseVNode(`div`,_hoisted_12$18,[createBaseVNode(`div`,_hoisted_13$16,[_cache[3]||=createBaseVNode(`span`,{class:`detail-label`},`Offer:`,-1),createVNode(unref(bngUnit_default),{money:offer.value},null,8,[`money`]),createBaseVNode(`span`,{class:normalizeClass([`delta`,{up:offer.value>listing.value,down:offer.valuelisting.value?`+`:`-`),1),createVNode(unref(bngUnit_default),{money:Math.abs(offer.value-listing.value)},null,8,[`money`]),_cache[2]||=createTextVNode(`) `,-1)],2)]),createBaseVNode(`div`,_hoisted_14$16,[_cache[4]||=createBaseVNode(`span`,{class:`detail-label`},`Vehicle:`,-1),createBaseVNode(`span`,null,toDisplayString(listing.niceName),1)])])]),createBaseVNode(`div`,_hoisted_15$16,[createVNode(unref(bngButton_default),{class:`part-button`,onClick:$event=>declineOffer(listing.id,index),accent:unref(ACCENTS).attention},{default:withCtx(()=>[createTextVNode(toDisplayString(offer.expiredViewCounter?`Discard`:`Deny`),1)]),_:2},1032,[`onClick`,`accent`]),offer.expiredViewCounter?createCommentVNode(``,!0):(openBlock(),createBlock(unref(bngButton_default),{key:0,class:`part-button negotiate-button`,onClick:$event=>startNegotiateBuyingOffer(listing.id,index),accent:unref(ACCENTS).secondary,disabled:!offer.negotiationPossible||offer.value>=listing.value||listing.disabled},{default:withCtx(()=>[..._cache[5]||=[createTextVNode(` Negotiate `,-1)]]),_:1},8,[`onClick`,`accent`,`disabled`])),offer.expiredViewCounter?createCommentVNode(``,!0):(openBlock(),createBlock(unref(bngButton_default),{key:1,class:`part-button`,onClick:$event=>acceptOffer(listing.id,index),disabled:listing.disabled||offer.disabled,accent:unref(ACCENTS).main},{default:withCtx(()=>[..._cache[6]||=[createTextVNode(` Accept Offer `,-1)]]),_:1},8,[`onClick`,`disabled`,`accent`]))])],42,_hoisted_7$42)),[[unref(BngScopedNav_default)]])),256)),Object.keys(listing.offers||{}).length===0?(openBlock(),createElementBlock(`div`,_hoisted_16$16,toDisplayString(unref($translate).instant(`ui.career.vehicleMarketplace.noOffers`)),1)):createCommentVNode(``,!0)]),_:2},1032,[`class`]))),128))]),_:1},8,[`items`]),createVNode(unref(bngButton_default),{class:`add-listing-button`,onClick:listVehicle,accent:unref(ACCENTS).custom},{default:withCtx(()=>[..._cache[7]||=[createBaseVNode(`span`,{class:`add-listing-button-icon`},`+`,-1),createTextVNode(` Add Listing `,-1)]]),_:1},8,[`accent`])],64))}},VehicleMarketplace_default=__plugin_vue_export_helper_default(_sfc_main$139,[[`__scopeId`,`data-v-468e550d`]]),_hoisted_1$125={class:`flex-container`},_hoisted_2$105={class:`content`},_hoisted_3$93={key:0},_hoisted_4$73={class:`seller-grid`},_hoisted_5$62={class:`seller-card__label`},_hoisted_6$48={class:`seller-card__header`},_hoisted_7$41={class:`seller-card__title`},_hoisted_8$33={key:0,class:`seller-card__subtitle`},_hoisted_9$30={class:`seller-card__vehicle-thumbnails`},_hoisted_10$24={class:`seller-card__vehicle-thumbnail`},_hoisted_11$22={key:0,class:`more-label`},_hoisted_12$17={key:1},buyVehicleTitle=`Buy Vehicles`,sellVehicleTitle=`Sell Vehicles`,_sfc_main$138={__name:`VehicleShoppingMain`,props:{screenTag:{type:String,default:``},buyingAvailable:{type:String,default:`true`},marketplaceAvailable:{type:String,default:`true`},selectedSellerId:{type:String,default:``}},setup(__props){useUINavScope(`vehicleShopping`),useComputerStore();let vehicleShoppingStore=useVehicleShoppingStore(),selectedTab=ref(0),selectedSellerId=ref(``),router$1=useRouter(),loaded=ref(!1),selectSeller=sellerId=>{setSelectedSellerId(sellerId),updateRouteScreenTag()},tabs=computed(()=>{let tabs$1=[];return props.buyingAvailable===`true`&&tabs$1.push(buyVehicleTitle),props.marketplaceAvailable===`true`&&tabs$1.push(sellVehicleTitle),tabs$1}),props=__props,processTabInput=event=>{event.detail.name===`tab_l`?selectedTab.value=(selectedTab.value-1+tabs.value.length)%tabs.value.length:event.detail.name===`tab_r`&&(selectedTab.value=(selectedTab.value+1)%tabs.value.length)},onTabsChange=(tab,old)=>{let idx=tabs.value.indexOf(tab&&tab.heading?tab.heading:``);idx!==-1&&(selectedTab.value=idx),selectedTab.value===tabs.value.indexOf(buyVehicleTitle)&&(selectedSellerId.value=``)},headerTitle=computed(()=>{switch(tabs.value[selectedTab.value]){case buyVehicleTitle:return`Buy Vehicles`;case sellVehicleTitle:return`Sell Vehicles`;default:return`Available Vehicles`}}),updateRouteScreenTag=()=>{let screenTag=selectedTab.value===tabs.value.indexOf(sellVehicleTitle)?`marketplace`:`buying`;router$1.replace({name:`vehicleShopping`,params:{screenTag,buyingAvailable:props.buyingAvailable,marketplaceAvailable:props.marketplaceAvailable,selectedSellerId:selectedSellerId.value}})};watch(selectedTab,()=>{updateRouteScreenTag()});let setSelectedSellerId=sellerId=>{selectedSellerId.value=sellerId,vehicleShoppingStore.setSelectedSellerId(selectedSellerId.value)},dealershipVehiclesMap=computed(()=>{let map=new Map;return vehicleShoppingStore.vehicleShoppingData.vehiclesInShop&&vehicleShoppingStore.vehicleShoppingData.vehiclesInShop.filter(vehicle=>vehicle.preview).forEach(vehicle=>{map.has(vehicle.sellerId)||map.set(vehicle.sellerId,[]),map.get(vehicle.sellerId).push(vehicle)}),map}),getDealershipVehicles=dealershipId=>dealershipVehiclesMap.value.get(dealershipId)||[],start=()=>{nextTick(async()=>{await vehicleShoppingStore.requestVehicleShoppingData(),loaded.value=!0,vehicleShoppingStore.vehicleShoppingData.currentSeller?setSelectedSellerId(vehicleShoppingStore.vehicleShoppingData.currentSeller):setSelectedSellerId(props.selectedSellerId),props.screenTag==`buying`?selectedTab.value=tabs.value.indexOf(buyVehicleTitle):props.screenTag==`marketplace`?selectedTab.value=tabs.value.indexOf(sellVehicleTitle):selectedTab.value=0,updateRouteScreenTag()})},kill=async()=>{await Lua_default.career_modules_vehicleShopping.onShoppingMenuClosed(),vehicleShoppingStore.$dispose()},close=()=>{!vehicleShoppingStore.vehicleShoppingData.currentSeller&&selectedTab.value===tabs.value.indexOf(buyVehicleTitle)&&selectedSellerId.value?selectedSellerId.value=``:router$1.back()};return onMounted(start),onUnmounted(kill),(_ctx,_cache)=>withDirectives((openBlock(),createBlock(ComputerWrapper_default,{path:[unref(vehicleShoppingStore).vehicleShoppingData.currentSellerNiceName||`Vehicle Marketplace`],title:headerTitle.value,"bng-ui-scope":`vehicleShopping`,back:``,onBack:close},{status:withCtx(()=>[createTextVNode(` Free Inventory Slots: `+toDisplayString(unref(vehicleShoppingStore)?unref(vehicleShoppingStore).vehicleShoppingData.numberOfFreeSlots:0),1)]),default:withCtx(()=>[createBaseVNode(`div`,_hoisted_1$125,[withDirectives((openBlock(),createElementBlock(`div`,_hoisted_2$105,[createVNode(unref(tabs_default),{class:normalizeClass([`bng-tabs`,{"single-tab":tabs.value.length===1}]),selectedIndex:selectedTab.value,onChange:onTabsChange},{default:withCtx(()=>[createVNode(unref(tabList_default)),props.buyingAvailable===`true`?(openBlock(),createElementBlock(`div`,{key:0,"tab-heading":buyVehicleTitle,class:`buying-tab-content`},[loaded.value&&!selectedSellerId.value?(openBlock(),createBlock(unref(bngCard_default),{key:0,class:`buying-card`},{default:withCtx(()=>[unref(vehicleShoppingStore).vehicleShoppingData.uiDealershipsData&&Object.keys(unref(vehicleShoppingStore).vehicleShoppingData.uiDealershipsData).length?(openBlock(),createElementBlock(`div`,_hoisted_3$93,[createBaseVNode(`div`,_hoisted_4$73,[(openBlock(!0),createElementBlock(Fragment,null,renderList(unref(vehicleShoppingStore).vehicleShoppingData.uiDealershipsData,dealership=>(openBlock(),createBlock(unref(bngTile_default),{key:dealership.id,class:`seller-card`,style:normalizeStyle({backgroundImage:`linear-gradient(180deg, rgba(0,0,0,0.9), rgba(0,0,0,0)), url(`+(dealership.preview&&dealership.preview[0]===`/`?dealership.preview:`/`+dealership.preview)+`)`}),onClick:$event=>dealership.vehicleCount&&selectSeller(dealership.id)},{label:withCtx(()=>[createBaseVNode(`div`,_hoisted_5$62,[createBaseVNode(`div`,_hoisted_6$48,[createBaseVNode(`div`,_hoisted_7$41,[createVNode(unref(bngIcon_default),{type:dealership.icon},null,8,[`type`]),createTextVNode(toDisplayString(dealership.name),1)]),dealership.description?(openBlock(),createElementBlock(`div`,_hoisted_8$33,toDisplayString(dealership.description),1)):createCommentVNode(``,!0)]),createBaseVNode(`div`,_hoisted_9$30,[(openBlock(!0),createElementBlock(Fragment,null,renderList(getDealershipVehicles(dealership.id).slice(0,5),(vehicle,index)=>(openBlock(),createElementBlock(`div`,_hoisted_10$24,[createVNode(unref(aspectRatio_default),{ratio:`16:9`,class:`seller-card__vehicle-thumbnail-image`,"external-image":vehicle.preview},{default:withCtx(()=>[index==0&&getDealershipVehicles(dealership.id).length>5?(openBlock(),createElementBlock(`div`,_hoisted_11$22,` +`+toDisplayString(getDealershipVehicles(dealership.id).length-4),1)):createCommentVNode(``,!0)]),_:2},1032,[`external-image`])]))),256))])])]),_:2},1032,[`style`,`onClick`]))),128))])])):(openBlock(),createElementBlock(`div`,_hoisted_12$17,[..._cache[0]||=[createBaseVNode(`span`,null,`No sellers available.`,-1)]]))]),_:1})):loaded.value?(openBlock(),createBlock(VehicleList_default,{key:1})):(openBlock(),createBlock(unref(bngCard_default),{key:2},{default:withCtx(()=>[createVNode(unref(bngCardHeading_default),{style:{color:`#fff`}},{default:withCtx(()=>[..._cache[1]||=[createTextVNode(`Please wait...`,-1)]]),_:1})]),_:1}))])):createCommentVNode(``,!0),props.marketplaceAvailable===`true`?(openBlock(),createElementBlock(`div`,{key:1,"tab-heading":sellVehicleTitle,class:`marketplace-tab-content`},[createVNode(VehicleMarketplace_default)])):createCommentVNode(``,!0)]),_:1},8,[`class`,`selectedIndex`])])),[[unref(BngBlur_default),1]])])]),_:1},8,[`path`,`title`])),[[unref(BngOnUiNav_default),processTabInput,`tab_l,tab_r`]])}},VehicleShoppingMain_default=__plugin_vue_export_helper_default(_sfc_main$138,[[`__scopeId`,`data-v-83009aa9`]]),_hoisted_1$124={style:{padding:`1em`,overflow:`auto`}},_hoisted_2$104={class:`performance-class-container`},_hoisted_3$92={key:0,class:`performance-class-wrapper`},_hoisted_4$72={class:`class-badge`},_hoisted_5$61={class:`certification-container`},_hoisted_6$47={class:`specs-section`},_hoisted_7$40={key:0},_hoisted_8$32={key:1,class:`specs-grid`},_hoisted_9$29={class:`spec-row`},_hoisted_10$23={class:`spec-label`},_hoisted_11$21={class:`spec-value`},_hoisted_12$16={class:`spec-row`},_hoisted_13$15={class:`spec-value`},_hoisted_14$15={class:`spec-row`},_hoisted_15$15={class:`spec-label`},_hoisted_16$15={class:`spec-value`},_hoisted_17$12={class:`spec-row`},_hoisted_18$10={class:`spec-label`},_hoisted_19$8={class:`spec-value`},_hoisted_20$7={class:`spec-row`},_hoisted_21$7={class:`spec-label`},_hoisted_22$6={class:`spec-value`},_hoisted_23$5={class:`spec-row`},_hoisted_24$4={class:`spec-value`},_hoisted_25$3={class:`spec-row`},_hoisted_26$2={class:`spec-value`},_hoisted_27$2={class:`specs-section`},_hoisted_28$1={key:0,class:`metrics-grid`},_hoisted_29$1={key:3,class:`performance-index-container`},_hoisted_30$1={class:`progress-wrapper`},_hoisted_31$1={class:`class-markers`},_hoisted_32$1={class:`marker-label`},_hoisted_33$1={class:`history-dropdown-container`},_hoisted_34$1={class:`dropdown`},_sfc_main$137={__name:`VehiclePerformanceTile`,props:{vehicleData:Object},setup(__props){let{units}=useBridge(),props=__props;computed(()=>props.vehicleData.niceName||`No Name`);let startTestTitle=computed(()=>props.vehicleData.needsRepair?`Assess Performance (Repair Required)`:`Assess Performance Now`),startTest=function(){Lua_default.career_modules_vehiclePerformance.startDragTest(props.vehicleData.id)},getColorForValue=(value,min$1=0,max$1=1)=>{let normalizedValue=(value-min$1)/(max$1-min$1),adjustedValue=Math.max(0,normalizedValue-.1)*(1/.9),red,green;return adjustedValue<.5?(red=200,green=Math.round(200*(adjustedValue*2))):(red=Math.round(200*(2-adjustedValue*2)),green=200),`rgb(${red}, ${green}, 0)`},selectedHistoryIndex=ref(0),allCertificationData=computed(()=>[props.vehicleData.certificationData||{noPerformanceData:!0},...props.vehicleData.performanceHistory||[]]),historyOptions=computed(()=>allCertificationData.value.length?allCertificationData.value.map((item,index)=>({value:index,label:index===0?item.noPerformanceData?`Current Test Results: No data`:`Current Test Results - `+new Date(item.timeStamp).toLocaleString():`Previous Test Results - ${new Date(item.timeStamp).toLocaleString()}`})):[]),selectedCertificationData=computed(()=>allCertificationData.value[selectedHistoryIndex.value]);return watch(()=>props.vehicleData,newVal=>{},{immediate:!0}),(_ctx,_cache)=>withDirectives((openBlock(),createBlock(unref(bngCard_default),{class:`card`},{footer:withCtx(()=>[createBaseVNode(`div`,_hoisted_33$1,[createBaseVNode(`div`,_hoisted_34$1,[_cache[8]||=createBaseVNode(`div`,{class:`dropdown-label`},`Previous Assessments`,-1),createVNode(unref(bngDropdown_default),{modelValue:selectedHistoryIndex.value,"onUpdate:modelValue":_cache[0]||=$event=>selectedHistoryIndex.value=$event,items:historyOptions.value,class:`history-select`},{default:withCtx(()=>[createTextVNode(toDisplayString(historyOptions.value[selectedHistoryIndex.value].text),1)]),_:1},8,[`modelValue`,`items`])]),createVNode(unref(bngButton_default),{onClick:_cache[1]||=$event=>startTest(),disabled:__props.vehicleData.needsRepair||!__props.vehicleData.owned},{default:withCtx(()=>[createTextVNode(toDisplayString(startTestTitle.value),1)]),_:1},8,[`disabled`])])]),default:withCtx(()=>[createBaseVNode(`div`,_hoisted_1$124,[createBaseVNode(`div`,null,[createVNode(VehicleTileRow_default,{class:`vehicle-tile-row`,data:__props.vehicleData,enableHover:!1,small:!0},null,8,[`data`]),createBaseVNode(`div`,_hoisted_2$104,[selectedCertificationData.value&&selectedCertificationData.value.vehicleClass?(openBlock(),createElementBlock(`div`,_hoisted_3$92,[createBaseVNode(`span`,_hoisted_4$72,` Class `+toDisplayString(selectedCertificationData.value.vehicleClass.class.name)+` | PI `+toDisplayString(selectedCertificationData.value.vehicleClass.performanceIndex.toFixed(0)),1)])):createCommentVNode(``,!0)])]),createBaseVNode(`div`,_hoisted_5$61,[createBaseVNode(`div`,_hoisted_6$47,[_cache[5]||=createBaseVNode(`div`,{class:`section-header`},[createBaseVNode(`h2`,null,`Technical Specifications`)],-1),selectedCertificationData.value.vehicleClass?(openBlock(),createElementBlock(`div`,_hoisted_8$32,[createBaseVNode(`div`,_hoisted_9$29,[createBaseVNode(`div`,_hoisted_10$23,toDisplayString(_ctx.$t(`ui.options.units.weight`)),1),createBaseVNode(`div`,_hoisted_11$21,toDisplayString(_ctx.$game.units.buildString(`weight`,selectedCertificationData.value.weight,0)),1)]),createBaseVNode(`div`,_hoisted_12$16,[_cache[2]||=createBaseVNode(`div`,{class:`spec-label`},`Power/Weight`,-1),createBaseVNode(`div`,_hoisted_13$15,toDisplayString(selectedCertificationData.value.powerPerTon.toFixed(0))+`hp/1000kg`,1)]),createBaseVNode(`div`,_hoisted_14$15,[createBaseVNode(`div`,_hoisted_15$15,toDisplayString(_ctx.$t(`vehicle.info.Drivetrain`)),1),createBaseVNode(`div`,_hoisted_16$15,toDisplayString(selectedCertificationData.value.drivetrain),1)]),createBaseVNode(`div`,_hoisted_17$12,[createBaseVNode(`div`,_hoisted_18$10,toDisplayString(_ctx.$t(`vehicle.info.Fuel Type`)),1),createBaseVNode(`div`,_hoisted_19$8,toDisplayString(selectedCertificationData.value.fuelType),1)]),createBaseVNode(`div`,_hoisted_20$7,[createBaseVNode(`div`,_hoisted_21$7,toDisplayString(_ctx.$t(`vehicle.info.Induction Type`)),1),createBaseVNode(`div`,_hoisted_22$6,toDisplayString(selectedCertificationData.value.inductionType),1)]),createBaseVNode(`div`,_hoisted_23$5,[_cache[3]||=createBaseVNode(`div`,{class:`spec-label`},`Mileage`,-1),createBaseVNode(`div`,_hoisted_24$4,toDisplayString(unref(units).buildString(`length`,selectedCertificationData.value.mileage,0)),1)]),createBaseVNode(`div`,_hoisted_25$3,[_cache[4]||=createBaseVNode(`div`,{class:`spec-label`},`Lateral G-Force`,-1),createBaseVNode(`div`,_hoisted_26$2,toDisplayString(selectedCertificationData.value.lateralGForce.toFixed(2))+` G`,1)])])):(openBlock(),createElementBlock(`div`,_hoisted_7$40,` Vehicle has not been assessed yet. `))]),createBaseVNode(`div`,_hoisted_27$2,[_cache[7]||=createBaseVNode(`div`,{class:`section-header`},[createBaseVNode(`h2`,null,`Metrics`)],-1),selectedCertificationData.value.vehicleClass?(openBlock(),createElementBlock(`div`,_hoisted_28$1,[selectedCertificationData.value.power?(openBlock(),createBlock(unref(bngProgressBar_default),{key:0,headerLeft:`Power Output`,headerRight:_ctx.$game.units.buildString(`power`,selectedCertificationData.value.power,0),value:selectedCertificationData.value.power,min:0,max:1e3,showValueLabel:!1,valueColor:getColorForValue(selectedCertificationData.value.power,0,1e3),class:`score-progress`},null,8,[`headerRight`,`value`,`valueColor`])):createCommentVNode(``,!0),createVNode(unref(bngProgressBar_default),{headerLeft:`0-60 mph time (prepped surface)`,headerRight:selectedCertificationData.value.time_0_60?selectedCertificationData.value.time_0_60.toFixed(2)+` s`:`N/A`,value:selectedCertificationData.value.time_0_60?-selectedCertificationData.value.time_0_60:-25,min:-25,max:-2,showValueLabel:!1,valueColor:getColorForValue(selectedCertificationData.value.time_0_60?-selectedCertificationData.value.time_0_60:-25,-25,-2),class:`score-progress`},null,8,[`headerRight`,`value`,`valueColor`]),selectedCertificationData.value.time_1_4?(openBlock(),createBlock(unref(bngProgressBar_default),{key:1,headerLeft:`Quarter Mile`,headerRight:selectedCertificationData.value.time_1_4.toFixed(2)+` s @ `+_ctx.$game.units.buildString(`speed`,selectedCertificationData.value.velAt_1_4,0),value:selectedCertificationData.value.time_1_4?-selectedCertificationData.value.time_1_4:-35,min:-35,max:-8.1,showValueLabel:!1,valueColor:getColorForValue(selectedCertificationData.value.time_1_4?-selectedCertificationData.value.time_1_4:-35,-35,-8.1),class:`score-progress`},null,8,[`headerRight`,`value`,`valueColor`])):createCommentVNode(``,!0),selectedCertificationData.value.performanceAggregateScores.brakingGForceScore?(openBlock(),createBlock(unref(bngProgressBar_default),{key:2,headerLeft:`Braking Force`,headerRight:selectedCertificationData.value.brakingG?selectedCertificationData.value.brakingG.toFixed(2)+` G`:`N/A`,value:selectedCertificationData.value.brakingG||0,min:.5,max:1.9,showValueLabel:!1,valueColor:getColorForValue(selectedCertificationData.value.brakingG||0,.5,1.9),class:`score-progress`},null,8,[`headerRight`,`value`,`valueColor`])):createCommentVNode(``,!0),selectedCertificationData.value&&selectedCertificationData.value.vehicleClass?(openBlock(),createElementBlock(`div`,_hoisted_29$1,[createBaseVNode(`div`,_hoisted_30$1,[createVNode(unref(bngProgressBar_default),{headerLeft:`Performance Index`,headerRight:`Class: `+selectedCertificationData.value.vehicleClass.class.name,value:selectedCertificationData.value.vehicleClass.performanceIndex,min:0,max:110,showValueLabel:!1,valueColor:getColorForValue(selectedCertificationData.value.vehicleClass.performanceIndex/110),class:`score-progress performance-index`},null,8,[`headerRight`,`value`,`valueColor`]),createBaseVNode(`div`,_hoisted_31$1,[(openBlock(),createElementBlock(Fragment,null,renderList([{pi:101,name:`X`},{pi:86,name:`S`},{pi:66,name:`A`},{pi:41,name:`B`},{pi:21,name:`C`}],(classInfo,index)=>createBaseVNode(`div`,{key:index,class:`class-marker`,style:normalizeStyle({left:`${classInfo.pi/110*100}%`})},[_cache[6]||=createBaseVNode(`div`,{class:`marker-line`},null,-1),createBaseVNode(`div`,_hoisted_32$1,toDisplayString(classInfo.name),1)],4)),64))])])])):createCommentVNode(``,!0)])):createCommentVNode(``,!0)])])])]),_:1})),[[unref(BngBlur_default),!0]])}},VehiclePerformanceTile_default=__plugin_vue_export_helper_default(_sfc_main$137,[[`__scopeId`,`data-v-ca2efe1a`]]),_hoisted_1$123={key:0,class:`certification-test-in-progress`},_hoisted_2$103={class:`certification-content`},_hoisted_3$91={class:`certification-icon`},_hoisted_4$71={class:`cancelButton`},_hoisted_5$60={key:1},_sfc_main$136={__name:`VehiclePerformanceMain`,props:{inventoryId:String},setup(__props){let router$1=useRouter(),vehicleData=ref({}),assessmentProgressMessage=ref(`Performance Assessment in progress...`),cancellingTest=ref(!1),testInProgress=ref(!1),{$game}=useLibStore(),title=computed(()=>vehicleData.value.niceName?`Performance Index: `+vehicleData.value.niceName:`Performance Index`),props=__props;$game.events.on(`PerformanceTestMessage`,data=>{assessmentProgressMessage.value=data.message,cancellingTest.value=!0}),$game.events.on(`PerformanceTestStarted`,data=>{testInProgress.value=data.testInProgress,getVehicleData()});let close=()=>{router$1.back()},kill=()=>{$game.events.off(`PerformanceTestMessage`),$game.events.off(`PerformanceTestStarted`)},getVehicleData=()=>{Lua_default.career_modules_inventory.getVehicleUiData(Number(props.inventoryId)).then(data=>{vehicleData.value=data})},start=()=>{getVehicleData()},cancelTest=()=>{Lua_default.career_modules_vehiclePerformance.cancelTest()};return onUnmounted(kill),onMounted(start),(_ctx,_cache)=>testInProgress.value?(openBlock(),createElementBlock(`div`,_hoisted_1$123,[createVNode(unref(bngCard_default),{class:`certification-card`},{default:withCtx(()=>[createBaseVNode(`div`,_hoisted_2$103,[createBaseVNode(`div`,null,[createBaseVNode(`div`,{class:normalizeClass([`certificationTestText`,{cancelling:cancellingTest.value}])},toDisplayString(assessmentProgressMessage.value),3)]),createBaseVNode(`div`,_hoisted_3$91,[createVNode(unref(bngIcon_default),{type:unref(icons).timeUnlockOutline},null,8,[`type`])])]),createBaseVNode(`div`,_hoisted_4$71,[withDirectives((openBlock(),createBlock(unref(bngButton_default),{accent:unref(ACCENTS).RED,onClick:cancelTest,tabindex:`0`},{default:withCtx(()=>[..._cache[0]||=[createTextVNode(` Cancel Test `,-1)]]),_:1},8,[`accent`])),[[unref(BngOnUiNav_default),void 0,`back,menu`,{asMouse:!0}]])])]),_:1})])):(openBlock(),createElementBlock(`div`,_hoisted_5$60,[createVNode(ComputerWrapper_default,{ref:`wrapper`,path:[`Performance Index`],title:title.value,back:``,onBack:close},{default:withCtx(()=>[createVNode(VehiclePerformanceTile_default,{"vehicle-data":vehicleData.value},null,8,[`vehicle-data`])]),_:1},8,[`title`])]))}},VehiclePerformanceMain_default=__plugin_vue_export_helper_default(_sfc_main$136,[[`__scopeId`,`data-v-ea737c56`]]),_hoisted_1$122={class:`offer-chat-container-wrapper`},_hoisted_2$102={key:0,class:`above`},_hoisted_3$90={key:1,class:`red`},_hoisted_4$70={key:2,class:`green`},_hoisted_5$59={key:3,class:`above`},_hoisted_6$46={key:4,class:`above`},_hoisted_7$39={key:5,class:`price`},_sfc_main$135={__name:`NegotiationChat`,props:{offerHistory:{type:Array,default:()=>[]},negotiationStatus:{type:String,default:``},startingPrice:{type:Number,default:0},amISelling:{type:Boolean,default:!1}},setup(__props,{expose:__expose}){let props=__props,offerChatContainer=ref(null),statusTextFromStatus=status=>{switch(String(status||``)){case`counterOffer`:return`Counter offer`;case`counterOfferLastChance`:return`Last chance counter offer`;case`accepted`:return`Accepted`;case`failed`:return`Negotiation failed`;case`refused`:return`Offer refused`;case`initial`:return props.amISelling?`Initial offer`:`Asking Price`;case`thinking`:return`Thinking`;default:return``}},fillInOfferHistory=history$1=>{if(!history$1||!Array.isArray(history$1))return[];let hasSeenMyOffer=!1,isFirstInitialOffer=!0;return history$1.map(item=>{let isMyOffer=item.myOffer!=null,isTheirOffer=item.theirOffer!=null,currentOffer=isMyOffer?item.myOffer:item.theirOffer,difference=null;isTheirOffer&&isFirstInitialOffer?isFirstInitialOffer=!1:difference=currentOffer-props.startingPrice;let offerStatus=null;return isMyOffer&&(hasSeenMyOffer?offerStatus=`counterOffer`:(offerStatus=`initial`,hasSeenMyOffer=!0)),isMyOffer?item.myOffer:isTheirOffer&&item.theirOffer,{theirOffer:item.theirOffer,myOffer:item.myOffer,negotiationStatus:item.negotiationStatus,messageClass:isMyOffer?`sent-message`:`received-message`,difference,offerStatus}})},typingMessageId=ref(null),previousOfferHistoryLength=ref(0);watch(()=>props.negotiationStatus,newStatus=>{newStatus===`typing`&&typingMessageId.value===null&&(typingMessageId.value=`typing-${Date.now()}`)});let processedOfferHistory=computed(()=>{let history$1=fillInOfferHistory(props.offerHistory),currentHistoryLength=(props.offerHistory||[]).length;if(currentHistoryLength>previousOfferHistoryLength.value&&typingMessageId.value!==null){let responseId=typingMessageId.value,responseData=history$1[history$1.length-1],result=[...history$1];return result[result.length-1]={...responseData,typingId:responseId,isTyping:!1},typingMessageId.value=null,previousOfferHistoryLength.value=currentHistoryLength,result}return currentHistoryLength!==previousOfferHistoryLength.value&&(previousOfferHistoryLength.value=currentHistoryLength),props.negotiationStatus===`typing`&&typingMessageId.value!==null?[...history$1,{theirOffer:null,myOffer:null,negotiationStatus:`typing`,messageClass:`received-message`,difference:null,isTyping:!0,typingId:typingMessageId.value}]:history$1});watch(processedOfferHistory,()=>{nextTick(()=>{if(offerChatContainer.value){let container=offerChatContainer.value;container.scrollHeight-container.scrollTop-container.clientHeight<100&&(container.scrollTop=container.scrollHeight)}})},{deep:!0});let scrollToBottom=()=>{nextTick(()=>{offerChatContainer.value&&(offerChatContainer.value.scrollTop=offerChatContainer.value.scrollHeight)})},reset$1=()=>{typingMessageId.value=null,previousOfferHistoryLength.value=(props.offerHistory||[]).length};return onMounted(()=>{reset$1(),scrollToBottom()}),__expose({scrollToBottom,reset:reset$1}),(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$122,[createBaseVNode(`div`,{ref_key:`offerChatContainer`,ref:offerChatContainer,class:`offer-chat-container`},[createVNode(TransitionGroup,{name:`message`,tag:`div`},{default:withCtx(()=>[(openBlock(!0),createElementBlock(Fragment,null,renderList(processedOfferHistory.value,(item,index)=>(openBlock(),createElementBlock(`div`,{key:item.typingId||`${item.myOffer||item.theirOffer||`message`}-${index}`,class:normalizeClass([`message`,item.messageClass])},[item.isTyping?(openBlock(),createElementBlock(`div`,_hoisted_2$102,[..._cache[0]||=[createBaseVNode(`span`,{class:`spinner`,"aria-label":`Typing`},null,-1),createTextVNode(` Typing... `,-1)]])):item.negotiationStatus===`failed`?(openBlock(),createElementBlock(`div`,_hoisted_3$90,[createVNode(unref(bngIcon_default),{type:`abandon`}),_cache[1]||=createTextVNode(` Negotiation failed! `,-1)])):item.negotiationStatus===`accepted`?(openBlock(),createElementBlock(`div`,_hoisted_4$70,[createVNode(unref(bngIcon_default),{type:`checkmark`,color:`var(--bng-add-green-400)`}),_cache[2]||=createTextVNode(` Accepted! `,-1)])):item.offerStatus?(openBlock(),createElementBlock(`div`,_hoisted_5$59,[item.offerStatus===`initial`?(openBlock(),createElementBlock(Fragment,{key:0},[createTextVNode(toDisplayString(props.amISelling?`Asking Price`:`Initial offer`),1)],64)):(openBlock(),createElementBlock(Fragment,{key:1},[createTextVNode(` Counter offer `)],64))])):item.negotiationStatus?(openBlock(),createElementBlock(`div`,_hoisted_6$46,toDisplayString(statusTextFromStatus(item.negotiationStatus)),1)):createCommentVNode(``,!0),!item.isTyping&&item.negotiationStatus!==`failed`&&item.negotiationStatus!==`accepted`?(openBlock(),createElementBlock(`div`,_hoisted_7$39,[createVNode(unref(bngUnit_default),{class:`money`,money:item.myOffer||item.theirOffer||0},null,8,[`money`])])):createCommentVNode(``,!0)],2))),128))]),_:1})],512)]))}},NegotiationChat_default=__plugin_vue_export_helper_default(_sfc_main$135,[[`__scopeId`,`data-v-c4558f29`]]),_hoisted_1$121={class:`price-finder-label right`},_hoisted_2$101={class:`price-finder-track`},_hoisted_3$89={key:0,class:`tick-label`},_hoisted_4$69={class:`price-finder-label left`},_sfc_main$134={__name:`PriceFinder`,props:{offerHistory:{type:Array,default:()=>[]},negotiationStatus:{type:String,default:``},startingPrice:{type:Number,default:0},offerPreview:{type:Number,default:0},actualVehicleValue:{type:Number,default:null},amISelling:{type:Boolean,default:!1}},setup(__props){let{units}=useBridge(),props=__props,priceFinderData=computed(()=>{let history$1=props.offerHistory||[];if(history$1.length===0)return null;let initialTheirOffer=null,initialMyOffer=null;for(let item of history$1)if(initialTheirOffer===null&&item.theirOffer!=null&&(initialTheirOffer=item.theirOffer),initialMyOffer===null&&item.myOffer!=null&&(initialMyOffer=item.myOffer),initialTheirOffer!==null&&initialMyOffer!==null)break;let hasBothInitialOffers=initialTheirOffer!==null&&initialMyOffer!==null;initialTheirOffer===null&&(initialTheirOffer=props.startingPrice),initialMyOffer===null&&(initialMyOffer=props.offerPreview||props.startingPrice);let offers=[],offerIndex=0,lastMyOfferIndex=-1,lastTheirOfferIndex=-1;for(let item of history$1)item.myOffer==null?item.theirOffer!=null&&(offers.push({price:item.theirOffer,isMyOffer:!1,index:offerIndex++,isUnsent:!1}),lastTheirOfferIndex=offers.length-1):(offers.push({price:item.myOffer,isMyOffer:!0,index:offerIndex++,isUnsent:!1}),lastMyOfferIndex=offers.length-1);props.negotiationStatus!==`failed`&&props.negotiationStatus!==`accepted`&&props.offerPreview>0&&(offers.push({price:props.offerPreview,isMyOffer:!0,index:offerIndex++,isUnsent:!0}),lastMyOfferIndex=offers.length-1);let leftPrice=Math.min(initialTheirOffer,initialMyOffer),rightPrice=Math.max(initialTheirOffer,initialMyOffer),topIsTheir=props.amISelling,range=rightPrice-leftPrice||1,{majorTicks,minorTicks}=((min$1,max$1,priceRange)=>{let niceNumbers=[1,2,5,10,20,50,100,200,500,1e3,2e3,5e3,1e4],tickRange=max$1-min$1;if(tickRange===0)return{majorTicks:[],minorTicks:[]};let roughStep=tickRange/4,magnitude=10**Math.floor(Math.log10(roughStep)),normalizedStep=roughStep/magnitude,closestNice=niceNumbers[0],minDiff=Math.abs(normalizedStep-closestNice);for(let nice of niceNumbers){let diff=Math.abs(normalizedStep-nice);diff=min$1&&price<=max$1){let position=(price-leftPrice)/priceRange*100;majorTicks$1.push({price,position:Math.max(0,Math.min(100,position))})}let minorStep=step/5,minorTicks$1=[];for(let price=niceMin;price<=niceMax;price+=minorStep)if(price>=min$1&&price<=max$1&&Math.abs(price%step)>.01){let position=(price-leftPrice)/priceRange*100;minorTicks$1.push({price,position:Math.max(0,Math.min(100,position))})}return{majorTicks:majorTicks$1,minorTicks:minorTicks$1}})(leftPrice,rightPrice,range),hasVisibleTicks=range>0&&majorTicks.length>0,offerPositions=offers.map((offer,index)=>{let position=(offer.price-leftPrice)/range*100,isMostRecent=offer.isMyOffer&&index===lastMyOfferIndex||!offer.isMyOffer&&index===lastTheirOfferIndex;return{...offer,position:Math.max(0,Math.min(100,position)),isMostRecent}}),marketValuePosition=null;if(hasVisibleTicks&&props.actualVehicleValue!=null&&props.actualVehicleValue>0&&props.actualVehicleValue>=leftPrice&&props.actualVehicleValue<=rightPrice){let position=(props.actualVehicleValue-leftPrice)/range*100;marketValuePosition=Math.max(0,Math.min(100,position))}let initialMarkers=[];if(hasVisibleTicks){let theirPosition=initialTheirOffer===leftPrice?0:100;initialMarkers.push({price:initialTheirOffer,isMyOffer:!1,position:theirPosition,isInitial:!0});let myPosition=initialMyOffer===leftPrice?0:100;initialMarkers.push({price:initialMyOffer,isMyOffer:!0,position:myPosition,isInitial:!0})}return{initialTheirOffer,initialMyOffer,leftPrice,rightPrice,topIsTheir,hasBothInitialOffers,majorTicks,minorTicks,offers:offerPositions,marketValuePosition,initialMarkers}});return(_ctx,_cache)=>priceFinderData.value?(openBlock(),createElementBlock(`div`,{key:0,class:normalizeClass([`price-finder-container`,{selling:__props.amISelling,buying:!__props.amISelling}])},[createBaseVNode(`div`,_hoisted_1$121,[createTextVNode(toDisplayString(priceFinderData.value.topIsTheir?`Your`:`Their`)+` Asking Price: `,1),createVNode(unref(bngUnit_default),{class:`money`,money:priceFinderData.value.rightPrice},null,8,[`money`])]),createBaseVNode(`div`,_hoisted_2$101,[(openBlock(!0),createElementBlock(Fragment,null,renderList(priceFinderData.value.minorTicks,(tick,index)=>(openBlock(),createElementBlock(`div`,{key:`minor-`+index,class:`price-finder-tick minor`,style:normalizeStyle({top:100-tick.position+`%`})},null,4))),128)),(openBlock(!0),createElementBlock(Fragment,null,renderList(priceFinderData.value.majorTicks,(tick,index)=>(openBlock(),createElementBlock(`div`,{key:`major-`+index,class:`price-finder-tick major`,style:normalizeStyle({top:100-tick.position+`%`})},[tick.position>5&&tick.position<95?(openBlock(),createElementBlock(`div`,_hoisted_3$89,toDisplayString(unref(units).beamBucks(tick.price)),1)):createCommentVNode(``,!0)],4))),128)),priceFinderData.value.hasBothInitialOffers?(openBlock(!0),createElementBlock(Fragment,{key:0},renderList(priceFinderData.value.offers,(offer,index)=>(openBlock(),createElementBlock(`div`,{key:index,class:normalizeClass([`price-finder-marker`,{"my-offer":offer.isMyOffer,"their-offer":!offer.isMyOffer,"most-recent":offer.isMostRecent,unsent:offer.isUnsent}]),style:normalizeStyle({top:100-offer.position+`%`})},[..._cache[0]||=[createBaseVNode(`div`,{class:`marker-triangle`},null,-1)]],6))),128)):createCommentVNode(``,!0),priceFinderData.value.marketValuePosition===null?createCommentVNode(``,!0):(openBlock(),createElementBlock(`div`,{key:1,class:`price-finder-marker market-value`,style:normalizeStyle({top:100-priceFinderData.value.marketValuePosition+`%`,bottom:`0`})},[..._cache[1]||=[createBaseVNode(`div`,{class:`marker-dot`},null,-1)]],4)),(openBlock(!0),createElementBlock(Fragment,null,renderList(priceFinderData.value.initialMarkers,(marker$1,index)=>(openBlock(),createElementBlock(`div`,{key:`initial-`+index,class:normalizeClass([`price-finder-marker`,{"my-offer":marker$1.isMyOffer,"their-offer":!marker$1.isMyOffer,initial:!0}]),style:normalizeStyle({top:100-marker$1.position+`%`})},[..._cache[2]||=[createBaseVNode(`div`,{class:`marker-triangle`},null,-1)]],6))),128))]),createBaseVNode(`div`,_hoisted_4$69,[createTextVNode(toDisplayString(priceFinderData.value.topIsTheir?`Their`:`Your`)+` initial offer: `,1),createVNode(unref(bngUnit_default),{class:`money`,money:priceFinderData.value.leftPrice},null,8,[`money`])])],2)):createCommentVNode(``,!0)}},PriceFinder_default=__plugin_vue_export_helper_default(_sfc_main$134,[[`__scopeId`,`data-v-ba044f86`]]),_hoisted_1$120={class:`center-wrap`},_hoisted_2$100={class:`header-row`},_hoisted_3$88={key:0,class:`header-seller-info`},_hoisted_4$68={class:`main-content`},_hoisted_5$58={class:`summary`},_hoisted_6$45={key:0,class:`vehicle-info`},_hoisted_7$38={class:`purchase-row`},_hoisted_8$31={class:`label`},_hoisted_9$28={class:`sub-info`},_hoisted_10$22={class:`price`},_hoisted_11$20={class:`offer-container`},_hoisted_12$15={class:`patience`},_hoisted_13$14={class:`label-row`},_hoisted_14$14={class:`offer-controls`},_hoisted_15$14={key:0,class:`offer-controls-row`},_hoisted_16$14={class:`step-buttons-group`},_hoisted_17$11={class:`resolved-negotiation-message`},_hoisted_18$9={class:`price-column`},_hoisted_19$7={key:0,class:`price`},_hoisted_20$6={key:1,class:`price`},_hoisted_21$6={class:`action-buttons wide`},_sfc_main$133={__name:`VehicleNegotiationMain`,setup(__props){useUINavScope(`vehicleNegotiation`);let{units}=useBridge(),events$3=useEvents(),router$1=useRouter(),state=ref({active:!1,startingPrice:0,patience:0,myOffer:null,theirOffer:0,thinking:!1,status:``,negotiationStatus:``,opponentName:``,vehicleNiceName:``,vehicleThumbnail:``,amISelling:!1}),opponent=computed(()=>state.value.amISelling?`Buyer`:`Seller`),biggerIsBetter=computed(()=>!!state.value.amISelling),increaseOfferDisabled=computed(()=>state.value.amISelling?state.value.myOffer!=null&&offerPreview.value>=state.value.myOffer:offerPreview.value>=state.value.theirOffer),decreaseOfferDisabled=computed(()=>state.value.amISelling?(console.log(`decreaseOfferDisabled`,offerPreview.value,state.value.theirOffer),offerPreview.value<=state.value.theirOffer):state.value.myOffer!=null&&offerPreview.value<=state.value.myOffer),offerPreview=ref(0);computed(()=>{let baseStep=state.value.startingPrice/500;return Math.round(baseStep/5)*5}),computed(()=>{let diff=(offerPreview.value-state.value.startingPrice)/state.value.startingPrice*100;return Math.round(diff)});let diffOfferPreviewToStarting=computed(()=>offerPreview.value-state.value.startingPrice),isDiffOfferPreviewToStartingGood=computed(()=>biggerIsBetter.value?diffOfferPreviewToStarting.value>=0:diffOfferPreviewToStarting.value<=0),diffPercentOfferPreviewToMarket=computed(()=>{if(!state.value.actualVehicleValue||state.value.actualVehicleValue===0)return null;let diff=(offerPreview.value-state.value.actualVehicleValue)/state.value.actualVehicleValue*100;return Math.round(diff)}),isDiffPercentOfferPreviewToMarketGood=computed(()=>diffPercentOfferPreviewToMarket.value===null?null:biggerIsBetter.value?diffPercentOfferPreviewToMarket.value>=0:diffPercentOfferPreviewToMarket.value<=0),diffTheirOfferToStarting=computed(()=>state.value.theirOffer-state.value.startingPrice);computed(()=>biggerIsBetter.value?diffTheirOfferToStarting.value>=0:diffTheirOfferToStarting.value<=0);let nudgeOffer=delta=>{let roundedOfferPreview=Math.max(0,Math.round((offerPreview.value+delta)/50)*50),min$1=0,max$1=1/0;state.value.amISelling?(min$1=state.value.theirOffer,state.value.myOffer!=null&&(max$1=state.value.myOffer)):(max$1=state.value.theirOffer,state.value.myOffer!=null&&(min$1=state.value.myOffer)),offerPreview.value=Math.min(max$1,Math.max(min$1,roundedOfferPreview))},offerDisabled=computed(()=>state.value.negotiationStatus===`thinking`||state.value.negotiationStatus===`typing`||state.value.negotiationStatus===`accepted`||state.value.negotiationStatus===`failed`),patienceClass=computed(()=>{let m=state.value.patience??0;return m>.66?`patience-good`:m>.33?`patience-mid`:`patience-bad`}),noDeal=computed(()=>state.value.negotiationStatus===`failed`&&state.value.amISelling);computed(()=>state.value.negotiationStatus===`failed`),computed(()=>{switch(String(state.value.negotiationStatus||``)){case`counterOffer`:return`Counter offer`;case`counterOfferLastChance`:return`Last chance counter offer`;case`accepted`:return`Accepted`;case`failed`:return`Negotiation failed`;case`refused`:return`Offer refused`;case`initial`:return`Initial offer`;case`thinking`:return`Thinking`;case`typing`:return`Typing...`;default:return``}});let resolvedStatusText=computed(()=>state.value.negotiationStatus===`failed`?state.value.amISelling?`The other party ran out of patience and does not want to buy this vehicle.`:`The other party ran out of patience. You can still buy the vehicle at the starting price: `:state.value.negotiationStatus===`accepted`?`Congratulations! You've successfully negotiatied a deal with `+state.value.opponentName+`.`:``),negotiationChat=ref(null),refresh$1=async()=>{state.value=await Lua_default.career_modules_marketplace.getNegotiationState()||state.value;let base=state.value.myOffer==null?state.value.startingPrice:state.value.myOffer;Number.isNaN(Number(base))||(offerPreview.value=Number(base)),state.value.negotiationStatus===`failed`&&(offerPreview.value=state.value.startingPrice)},submitOffer=async()=>{let price=Number(offerPreview.value);Number.isFinite(price)&&await Lua_default.career_modules_marketplace.makeNegotiationOffer(price)},takeOffer=async()=>{await Lua_default.career_modules_marketplace.takeTheirOffer(),state.value.negotiationStatus=`accepted`,state.value.status=`accepted`,offerPreview.value=state.value.theirOffer,state.value.iAccepted=!0,state.value.offerHistory.push({myOffer:state.value.theirOffer,negotiationStatus:`accepted`})},cancel=async()=>{state.value.negotiationStatus!==`accepted`&&await Lua_default.career_modules_marketplace.cancelNegotiation()},goBack=event=>{router$1.back(),state.value.negotiationStatus===`accepted`&&!state.value.iAccepted&&Lua_default.career_modules_marketplace.takeTheirOffer(),cancel(),event&&event.stopPropagation&&event.stopPropagation()};return events$3.on(`negotiationData`,data=>{refresh$1()}),onMounted(async()=>{await refresh$1(),nextTick(()=>{negotiationChat.value&&(negotiationChat.value.reset(),negotiationChat.value.scrollToBottom())})}),onUnmounted(async()=>{events$3.off(`negotiationData`)}),(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$120,[withDirectives((openBlock(),createBlock(unref(bngCard_default),{"bng-ui-scope":`vehicleNegotiation`,class:`negotiation-screen`},{buttons:withCtx(()=>[createBaseVNode(`div`,_hoisted_21$6,[state.value.negotiationStatus!==`accepted`&&state.value.negotiationStatus!==`failed`?(openBlock(),createBlock(unref(bngButton_default),{key:0,class:`submit-offer`,disabled:state.value.negotiationStatus===`counterOfferLastChance`||offerPreview.value==state.value.theirOffer||offerPreview.value==state.value.myOffer||offerDisabled.value,onClick:_cache[6]||=$event=>submitOffer(),accent:unref(ACCENTS).secondary},{default:withCtx(()=>[..._cache[16]||=[createTextVNode(` Submit This Offer `,-1)]]),_:1},8,[`disabled`,`accent`])):createCommentVNode(``,!0),state.value.negotiationStatus!==`accepted`&&state.value.negotiationStatus!==`failed`?withDirectives((openBlock(),createBlock(unref(bngButton_default),{key:1,class:`submit-offer`,disabled:state.value.negotiationStatus===`counterOfferLastChance`||offerDisabled.value,"show-hold":``},{default:withCtx(()=>[..._cache[17]||=[createTextVNode(` Agree to their Price `,-1)]]),_:1},8,[`disabled`])),[[unref(BngClick_default),{holdCallback:takeOffer,holdDelay:1e3,repeatInterval:0}]]):createCommentVNode(``,!0),state.value.negotiationStatus===`failed`||state.value.negotiationStatus===`accepted`?(openBlock(),createBlock(unref(bngButton_default),{key:2,class:`go-back`,accent:unref(ACCENTS).primary,onClick:goBack},{default:withCtx(()=>[createTextVNode(toDisplayString(state.value.amISelling?`Continue`:`Go to Purchase Screen`),1)]),_:1},8,[`accent`])):createCommentVNode(``,!0)])]),default:withCtx(()=>[createBaseVNode(`div`,_hoisted_2$100,[createVNode(unref(bngCardHeading_default),{type:`ribbon`},{default:withCtx(()=>[createTextVNode(` Negotiation with `+toDisplayString(state.value.opponentName||opponent.value)+` `,1),state.value.opponentQuote?(openBlock(),createElementBlock(`div`,_hoisted_3$88,` "`+toDisplayString(state.value.opponentQuote)+`" `,1)):createCommentVNode(``,!0)]),_:1}),createVNode(unref(bngButton_default),{class:`close-button`,onClick:goBack,accent:unref(ACCENTS).attention,"bng-no-nav":`true`,tabindex:`-1`},{default:withCtx(()=>[createVNode(unref(bngBinding_default),{"ui-event":`menu`,controller:``}),createVNode(unref(bngIcon_default),{type:`xmarkBold`,color:`var(--bng-cool-gray-100)`})]),_:1},8,[`accent`])]),createBaseVNode(`div`,_hoisted_4$68,[createBaseVNode(`div`,_hoisted_5$58,[state.value.vehicleNiceName||state.value.vehicleThumbnail?(openBlock(),createElementBlock(`div`,_hoisted_6$45,[createBaseVNode(`div`,_hoisted_7$38,[createBaseVNode(`div`,_hoisted_8$31,[createBaseVNode(`div`,null,toDisplayString(state.value.vehicleNiceName||`Vehicle`),1),createBaseVNode(`div`,_hoisted_9$28,toDisplayString(unref(units).buildString(`length`,state.value.vehicleMileage,0)),1)]),createBaseVNode(`div`,_hoisted_10$22,[_cache[7]||=createTextVNode(` Est. Market: `,-1),createBaseVNode(`div`,null,[createVNode(unref(bngUnit_default),{class:`money`,money:state.value.actualVehicleValue||0},null,8,[`money`])])])])])):createCommentVNode(``,!0)]),createBaseVNode(`div`,_hoisted_11$20,[createVNode(NegotiationChat_default,{ref_key:`negotiationChat`,ref:negotiationChat,"offer-history":state.value.offerHistory||[],"negotiation-status":state.value.negotiationStatus,"starting-price":state.value.startingPrice||0,"am-i-selling":state.value.amISelling},null,8,[`offer-history`,`negotiation-status`,`starting-price`,`am-i-selling`]),createVNode(PriceFinder_default,{"offer-history":state.value.offerHistory||[],"negotiation-status":state.value.negotiationStatus,"starting-price":state.value.startingPrice||0,"offer-preview":offerPreview.value||0,"actual-vehicle-value":state.value.actualVehicleValue,"am-i-selling":state.value.amISelling},null,8,[`offer-history`,`negotiation-status`,`starting-price`,`offer-preview`,`actual-vehicle-value`,`am-i-selling`])]),createBaseVNode(`div`,_hoisted_12$15,[createBaseVNode(`div`,{class:normalizeClass([`bar`,patienceClass.value])},[_cache[8]||=createBaseVNode(`div`,{class:`separator`,style:{left:`33.0%`}},null,-1),_cache[9]||=createBaseVNode(`div`,{class:`separator`,style:{left:`66.0%`}},null,-1),createBaseVNode(`div`,{class:normalizeClass([`fill`,patienceClass.value]),style:normalizeStyle({width:Math.max(0,Math.min(1,state.value.patience||0))*100+`%`})},null,6)],2),createBaseVNode(`div`,_hoisted_13$14,[createBaseVNode(`span`,null,toDisplayString(opponent.value)+`'s Patience`,1)])]),createBaseVNode(`div`,_hoisted_14$14,[state.value.negotiationStatus!==`failed`&&state.value.negotiationStatus!==`accepted`?(openBlock(),createElementBlock(`div`,_hoisted_15$14,[createBaseVNode(`div`,_hoisted_16$14,[createVNode(unref(bngButton_default),{class:`step step-large`,disabled:offerDisabled.value||decreaseOfferDisabled.value,onClick:_cache[0]||=$event=>nudgeOffer(-5e3)},{default:withCtx(()=>[..._cache[10]||=[createTextVNode(`-5000`,-1)]]),_:1},8,[`disabled`]),createVNode(unref(bngButton_default),{class:`step step-medium`,disabled:offerDisabled.value||decreaseOfferDisabled.value,onClick:_cache[1]||=$event=>nudgeOffer(-500)},{default:withCtx(()=>[..._cache[11]||=[createTextVNode(`-500`,-1)]]),_:1},8,[`disabled`]),createVNode(unref(bngButton_default),{class:`step`,disabled:offerDisabled.value||decreaseOfferDisabled.value,onClick:_cache[2]||=$event=>nudgeOffer(-50)},{default:withCtx(()=>[..._cache[12]||=[createTextVNode(`-50`,-1)]]),_:1},8,[`disabled`]),createVNode(unref(bngButton_default),{class:`step`,disabled:offerDisabled.value||increaseOfferDisabled.value,onClick:_cache[3]||=$event=>nudgeOffer(50)},{default:withCtx(()=>[..._cache[13]||=[createTextVNode(`+50`,-1)]]),_:1},8,[`disabled`]),createVNode(unref(bngButton_default),{class:`step step-medium`,disabled:offerDisabled.value||increaseOfferDisabled.value,onClick:_cache[4]||=$event=>nudgeOffer(500)},{default:withCtx(()=>[..._cache[14]||=[createTextVNode(`+500`,-1)]]),_:1},8,[`disabled`]),createVNode(unref(bngButton_default),{class:`step step-large`,disabled:offerDisabled.value||increaseOfferDisabled.value,onClick:_cache[5]||=$event=>nudgeOffer(5e3)},{default:withCtx(()=>[..._cache[15]||=[createTextVNode(`+5000`,-1)]]),_:1},8,[`disabled`])])])):createCommentVNode(``,!0),state.value.negotiationStatus===`failed`||state.value.negotiationStatus===`accepted`?(openBlock(),createElementBlock(`div`,{key:1,class:normalizeClass([`offer-controls-row`,{accepted:state.value.negotiationStatus===`accepted`,failed:state.value.negotiationStatus===`failed`}])},[createVNode(unref(bngIcon_default),{type:state.value.negotiationStatus===`accepted`?`checkmark`:`abandon`,class:`resolved-negotiation-icon`},null,8,[`type`]),createBaseVNode(`div`,_hoisted_17$11,toDisplayString(resolvedStatusText.value),1)],2)):createCommentVNode(``,!0),createBaseVNode(`div`,_hoisted_18$9,[noDeal.value?(openBlock(),createElementBlock(`div`,_hoisted_19$7,` NO DEAL `)):(openBlock(),createElementBlock(`div`,_hoisted_20$6,toDisplayString(unref(units).beamBucks(offerPreview.value||0)),1)),diffOfferPreviewToStarting.value===null?createCommentVNode(``,!0):(openBlock(),createElementBlock(`div`,{key:2,class:normalizeClass([`diff-percent-offer-preview-to-starting`,{positive:isDiffOfferPreviewToStartingGood.value&&diffOfferPreviewToStarting.value!==0,negative:!isDiffOfferPreviewToStartingGood.value&&diffOfferPreviewToStarting.value!==0,zero:diffOfferPreviewToStarting.value===0,hidden:noDeal.value}])},[diffOfferPreviewToStarting.value===0?createCommentVNode(``,!0):(openBlock(),createBlock(unref(bngUnit_default),{key:0,class:`money`,money:Math.abs(diffOfferPreviewToStarting.value)},null,8,[`money`])),createTextVNode(` `+toDisplayString(diffOfferPreviewToStarting.value<0?`under`:diffOfferPreviewToStarting.value>0?`over`:`Same as`)+` starting price `,1)],2)),diffPercentOfferPreviewToMarket.value===null?createCommentVNode(``,!0):(openBlock(),createElementBlock(`div`,{key:3,class:normalizeClass([`diff-percent-offer-preview-to-market`,{positive:isDiffPercentOfferPreviewToMarketGood.value,negative:!isDiffPercentOfferPreviewToMarketGood.value,hidden:noDeal.value}])},toDisplayString(Math.abs(diffPercentOfferPreviewToMarket.value))+`% `+toDisplayString(diffPercentOfferPreviewToMarket.value<0?`under`:`over`)+` Est. Market value `,3))])])])]),_:1})),[[unref(BngBlur_default),1]])]))}},VehicleNegotiationMain_default=__plugin_vue_export_helper_default(_sfc_main$133,[[`__scopeId`,`data-v-29ff8ba1`]]),routes_default$3=[{path:`/menu.careerPause`,name:`menu.careerPause`,component:Pause_default,props:!0,meta:{clickThrough:!0,infoBar:{withAngular:!0,visible:!0,showSysInfo:!0},uiApps:{shown:!1},topBar:{visible:!0}}},{path:`/career`,children:[{path:`chooseInsurance`,name:`chooseInsurance`,component:ChooseInsuranceMain_default},{path:`pauseBigMiddlePanel`,name:`pauseBigMiddlePanel`,component:PauseBigMiddlePanel_default,props:!0},{path:`logbook/:id(\\*?.*?)?`,name:`logbook`,component:Logbook_default,meta:{uiApps:{shown:!1}},props:!0},{path:`milestones/:id(\\*?.*?)?`,name:`milestones`,component:Milestones_default,props:!0,meta:{uiApps:{shown:!1}}},{path:`computer`,name:`computer`,component:ComputerMain_default,props:!0,meta:{uiApps:{shown:!1}}},{path:`vehicleInventory`,name:`vehicleInventory`,component:VehicleInventoryMain_default},{path:`vehiclePerformance/:inventoryId?`,name:`vehiclePerformance`,component:VehiclePerformanceMain_default,props:!0},{path:`tuning`,name:`tuning`,component:TuningMain_default},{path:`painting`,name:`painting`,component:PaintingMain_default},{path:`repair/:header?`,name:`repair`,component:RepairMain_default,props:!0},{path:`partShopping`,name:`partShopping`,component:PartShoppingMain_default,meta:{uiApps:{shown:!1}}},{path:`partInventory`,name:`partInventory`,component:PartInventoryMain_default},{path:`vehiclePurchase/:vehicleInfo?/:playerMoney?/:inventoryHasFreeSlot?/:lastVehicleInfo?`,name:`vehiclePurchase`,component:VehiclePurchaseMain_default,props:!0,meta:{uiApps:{shown:!1}}},{path:`negotiation`,name:`negotiation`,component:VehicleNegotiationMain_default},{path:`vehicleShopping/:screenTag?/:buyingAvailable?/:marketplaceAvailable?/:selectedSellerId?`,name:`vehicleShopping`,component:VehicleShoppingMain_default,props:!0,meta:{uiApps:{shown:!1}}},{path:`insurances`,name:`insurances`,component:InsurancesMain_default},{path:`playerAbstract`,name:`playerAbstract`,component:DriverAbstract_default},{path:`cargoDeliveryReward`,name:`cargoDeliveryReward`,component:CargoDeliveryReward_default,props:!0},{path:`cargoDropOff/:facilityId?/:parkingSpotPath(\\*?.*?)?`,name:`cargoDropOff`,component:CargoDropOff_default,props:!0},{path:`cargoOverview/:facilityId?/:parkingSpotPath(\\*?.*?)?`,name:`cargoOverview`,component:CargoOverviewMain_default,props:!0,meta:{uiApps:{shown:!1}}},{path:`myCargo`,name:`myCargo`,component:MyCargo_default,props:!0,meta:{uiApps:{shown:!1}}},{path:`progressLanding/:pathId?/:comesFromBigMap?`,name:`progressLanding`,component:ProgressLanding_default,props:route=>({pathId:route.params.pathId,comesFromBigMap:route.params.comesFromBigMap===`true`||route.params.comesFromBigMap===!0}),meta:{uiApps:{shown:!1},infoBar:{visible:!0}}},{path:`domainSelection`,name:`domainSelection`,component:ProgressLanding_default,props:!0,meta:{uiApps:{shown:!1},infoBar:{visible:!0}}},{path:`profiles`,name:`profiles`,component:Profiles_default,meta:{uiApps:{shown:!1},infoBar:{visible:!0,showSysInfo:!0}}}]}],data_default=[{translateId:`ui.credits.programmers`,members:[{first:`Thomas`,last:`Fischer`,aka:`tdev`,title:`CEO`},{first:`Lefteris`,last:`Stamatogiannakis`,aka:`estama`,title:`CTO / Physics / Sound / AI`},{first:`Luis`,last:`Anton Rebollo`,aka:`Souga`,title:`Lead Render Developer`},{first:`Alex`,last:`Spodheim`,aka:`CrankyCleric`,title:`Developer`},{first:`Ananda Neelam`,last:`Thathayya`,aka:`Nadeox1`,title:`Technical Artist`},{first:`Andrew`,last:`Kabakwu`,aka:``,title:`Developer`},{first:`Bruno`,last:`Gonzalez Campo`,aka:`stenyak`,title:`Lead Game Engine Developer`},{first:`Cosmin`,last:`Traian`,aka:``,title:`Developer`},{first:`Emre`,last:`Kut`,aka:``,title:`Developer`},{first:`Felix`,last:`Unger`,aka:``,title:`Developer`},{first:`George`,last:`Troulitakis`,aka:`AtmanB`,title:`Developer`},{first:`Guillem`,last:`Ortega`,aka:``,title:`Developer`},{first:`Logane`,last:`Ramez`,aka:`Gadoy`,title:`Developer`},{first:`Lorenzo`,last:`Bartali`,aka:``,title:`AI Developer`},{first:`Ludger`,last:`Meyer-Wülfing`,aka:`meywue`,title:`Developer`},{first:`Nicusor`,last:`Nedelcu`,aka:``,title:`Tools Developer`},{first:`Panos`,last:`Karabelas`,aka:``,title:`Developer`},{first:`Patrick `,last:`Schrangl`,aka:``,title:`Simulation Software Engineer`},{first:`Petros`,last:`Kondylis`,aka:``,title:`AI Developer`},{first:`Ronny`,last:`Nowak`,aka:``,title:`Developer`},{first:`Thomas`,last:`Portassau`,aka:`thomatoes50`,title:`Developer`},{first:`Thomas`,last:`Wilczynski`,aka:`Gamergull`,title:`Developer`},{first:`Timo`,last:`Stabbert`,aka:``,title:`Gameplay Dev Lead`},{first:`Valery`,last:`Dolotin`,aka:``,title:`AI Developer`},{first:`Daniel`,last:`Wakefield`,aka:``,title:`Developer`}]},{translateId:`ui.credits.vehiclePhysics`,members:[{first:`Fabian`,last:`Enkler`,aka:`Diamondback`,title:`Vehicle Systems Lead`},{first:`Angelo`,last:`Matteo`,aka:`angelo234`,title:`Tools Developer`},{first:`Aubrey`,last:`Percival`,aka:``,title:`Vehicle Physics Engineer`},{first:`Bobby`,last:`Villeneuve`,aka:`Binkey`,title:`Vehicle Physics Engineer`},{first:`Brian`,last:`Rickets`,aka:``,title:`Vehicle Systems Engineer`},{first:`Corey`,last:`Bergerud`,aka:`Goosah`,title:`Vehicle Physics Engineer`},{first:`Davide`,last:`Serpi`,aka:``,title:`Vehicle Dynamics Control Intern`},{first:`Efe Can`,last:`Kiraz`,aka:`RenAzuma66`,title:`Vehicle Physics Engineer`},{first:`Grzegorz`,last:`Węgrzyn`,aka:`AiTorror`,title:`Vehicle Physics Engineer / QA`},{first:`Jack`,last:`Jermany`,aka:``,title:`Vehicle Physics Engineer / QA`},{first:`Oliver`,last:`Čajka`,aka:`MRcrash`,title:`Vehicle Physics Engineer`},{first:`Piotr`,last:`Gajek`,aka:`Agent_Y`,title:`Vehicle Physics Engineer / QA`},{first:`Toma Ioan`,last:` Turcu`,aka:``,title:`Vehicle Physics Engineer`},{first:`Quinn`,last:`Howling`,aka:`SpeedHero`,title:`Vehicle Physics Designer`}]},{translateId:`ui.credits.vehicleArt`,members:[{first:`Gabriel`,last:`Fink`,aka:`gabester`,title:`Vehicle Art Director`},{first:`Jared`,last:`Samuelson`,aka:``,title:`Vehicle Team Lead / Subaru Expert`},{first:`Alexandr`,last:`Shesternin`,aka:``,title:`3D Vehicle Artist`},{first:`Andreas`,last:`Focht`,aka:``,title:`Vehicle Concept Artist`},{first:`Daniel`,last:`Russo`,aka:`A3DR`,title:`3D Vehicle Artist`},{first:`Dennis`,last:`Mateja`,aka:`NinetyNine`,title:`Vehicle Designer`},{first:`Manish`,last:`Rawat`,aka:``,title:`3D Vehicle Artist`}]},{translateId:`ui.credits.environmentArtists`,members:[{first:`Sam`,last:`Hutchinson`,aka:`LJFHutch`,title:`Environment Art Director`},{first:`Luca`,last:`Brighi`,aka:``,title:`Lead 3D Environment Artist`},{first:`Huiqin`,last:`Li`,aka:``,title:`3D Environment Artist`},{first:`Sebastien`,last:`Pelletier`,aka:`DoullPepper`,title:`3D Environment Artist`}]},{translateId:`ui.credits.conceptArtists`,members:[{first:`Mary Jane`,last:`Pajaron`,aka:``,title:`2D Concept Artist`}]},{translateId:`ui.credits.gameDesigners`,members:[{first:`James`,last:`Heslop`,aka:`Krallopian`,title:`Game Design Lead`},{first:`Alex`,last:`Bird`,aka:``,title:`Gameplay Developer`},{first:`Rob`,last:`Herridge`,aka:`HighDef`,title:`Gameplay Developer / QA`}]},{translateId:`ui.credits.ui`,members:[{first:`Pavel`,last:`Tiunov`,aka:`Dizboosta`,title:`UI Lead`},{first:`Destiny`,last:`Abellana`,aka:``,title:`Developer`},{first:`Stani`,last:`Tolmacheva`,aka:`Snowly`,title:`Developer`}]},{translateId:`ui.credits.sound`,members:[{first:`Mark`,last:`Knight`,aka:`TDK`,title:`Audio Designer`},{first:`Sebastian`,last:`Emling`,aka:``,title:`Audio Designer`},{first:`Jethro`,last:`Dunn`,aka:``,title:`Audio Outsourcer`},{first:`Max`,last:`Schumann`,aka:``,title:`Audio Outsourcer`}]},{translateId:`ui.credits.qa`,members:[{first:`Colin`,last:`Wenz`,aka:`synsol`,title:`QA Lead`},{first:`Przemysław`,last:`Wolny`,aka:`Car_Killer`,title:`QA / Mod Support`}]},{translateId:`ui.credits.production`,members:[{first:`Ryan`,last:`Dunne`,aka:``,title:`Producer`}]},{translateId:`ui.credits.sysops`,members:[{first:`Charalampos`,last:`Tsipizidis`,aka:``,title:`System Administrator`},{first:`Dimitrios`,last:`Folias`,aka:``,title:`System Administrator`}]},{translateId:`ui.credits.comms`,members:[{first:`Nataliia`,last:`Dmytriievska`,aka:`Leeloo`,title:`Communications & Marketing Lead`},{first:`Bernice`,last:`Mills`,aka:`Bee`,title:`Community Support & Marketing Specialist`},{first:`Mariia`,last:`Gumarova`,aka:`Fluffy Panda`,title:`Customer Support & Marketing Specialist`},{first:`Slawomir`,last:`Niemczyk`,aka:`Sedricoo`,title:`Community Coordinator`},{first:`Vincent`,last:`Liu`,aka:``,title:`Community & Marketing Specialist (APAC)`}]},{translateId:`ui.credits.research`,members:[{first:`Chrysanthi`,last:`Papamichail`,aka:``,title:`Lead Research Software Engineer`},{first:`Abdulrahman`,last:`Saeed`,aka:``,title:`Research Software Engineer`},{first:`Adam`,last:`Ivora`,aka:``,title:`Research Software Engineer`},{first:`David`,last:`Stark`,aka:``,title:`Research Software Engineer`},{first:`Florian`,last:`Faistauer`,aka:``,title:`Vehicle Simulation Expert`},{first:`Gabriel Puretas`,last:`Moral`,aka:``,title:`UX Intern`},{first:`Sayali`,last:`Rajhans`,aka:``,title:`Research Software Engineer`},{first:`Iskren`,last:`Rusimov`,aka:``,title:`Research Software Engineer Intern`}]},{translateId:`ui.credits.organization`,members:[{first:`Christoforos`,last:`Lambrianidis`,aka:``,title:`CFO`},{first:`Joseph`,last:`Inba Raj`,aka:``,title:`HR & Talent Acquisition Lead`},{first:`Cecilia`,last:`Sari`,aka:``,title:`Recruitment Specialist`},{first:`Dimitra`,last:`Litsardou`,aka:`Thamy`,title:`EU / Co-funding Advisory Specialist`},{first:`Eva`,last:`Pigova`,aka:``,title:`Senior Program Manager`},{first:`Maria`,last:`Kosmachevskaya`,aka:``,title:`Business Development Intern`},{first:`Özge`,last:`Altinkaya Erkok`,aka:``,title:`Communication Consultant`},{first:`Renars`,last:`Skesteris`,aka:``,title:`Business Development Intern`},{first:`Sabrina`,last:`Wee`,aka:``,title:`Business Development Manager`},{first:`Sandra`,last:`Campos`,aka:``,title:`Accounting Assistant`},{first:`Ulrike`,last:`Lentz`,aka:``,title:`Executive Assistant`}]},{translateId:`ui.credits.additionalVehiclePhysics`,members:[{first:`Will`,last:`Leader`,aka:``,title:`Off-road Suspension Development and Vehicle Dynamics`}]},{translateId:`ui.credits.additionalVehicleArt`,members:[{first:`Ashish`,last:`Singh`,aka:``,title:`Freelance 3D Vehicle Artist`},{first:`Juan Manuel`,last:`Orcellet`,aka:``,title:`Freelance 3D Vehicle Artist`},{first:`M. Yusuf`,last:`Bolukbasi`,aka:``,title:`Freelance Vehicle Artist`},{first:`Naman`,last:`Deep`,aka:``,title:`Freelance 3D Vehicle Artist`}]},{translateId:`ui.credits.externalContributors`,members:[{first:`Da`,last:`Li`,aka:``,title:``},{first:`Ruhmit`,last:`Sahu `,aka:``,title:``}]},{translateId:`ui.credits.formerEmployee`,members:[{first:`Aaron`,last:`Sutcliffe`,aka:``,title:`Developer / Vehicle Creation`},{first:`Alex`,last:`Raskin`,aka:``,title:`DevOps Engineer`},{first:`Artem`,last:`Arbatskii`,aka:``,title:`Developer`},{first:`Arturo`,last:`Campos`,aka:``,title:`Developer`},{first:`Ben`,last:`Payne`,aka:``,title:`Developer`},{first:`Boluwatife`,last:`Falaye`,aka:``,title:`Developer`},{first:`Clément`,last:`Roche`,aka:``,title:`Developer`},{first:`Edelmar`,last:`Schneider`,aka:``,title:`Developer`},{first:`Eike`,last:`Externest`,aka:``,title:`Developer`},{first:`Jali`,last:`Hautala`,aka:`Jalkku`,title:`Developer`},{first:`Jeremy`,last:`Lu`,aka:``,title:`Developer`},{first:`John`,last:`Beinecke`,aka:``,title:`Developer`},{first:`Juan`,last:`Mendez`,aka:``,title:`Developer`},{first:`Leander`,last:`Beernaert`,aka:``,title:`Game Engine Developer`},{first:`Marc`,last:`Müller`,aka:``,title:`Developer`},{first:`Mark`,last:`Vince`,aka:``,title:`Developer`},{first:`Matti`,last:`Yrjänheikki`,aka:`Masa`,title:`Developer`},{first:`Max`,last:`Razer`,aka:``,title:`Developer`},{first:`Mayowa David`,last:`Abogunrin`,aka:``,title:`Developer`},{first:`Moncef`,last:`Slimane`,aka:``,title:`Developer`},{first:`Nourelhoda`,last:`Mohamed`,aka:``,title:`Developer`},{first:`Pascale`,last:`Maul`,aka:``,title:`Developer`},{first:`Paul`,last:`De Almeida`,aka:``,title:`AI Developer`},{first:`Paul`,last:`Görs`,aka:``,title:`Developer`},{first:`Peter`,last:`Landwehr`,aka:``,title:`Developer`},{first:`Petteri`,last:`Koivumäki`,aka:``,title:`Developer`},{first:`Vasilis`,last:`Douvaras`,aka:``,title:`Developer`},{first:`Vatroslav `,last:`Bodrozic`,aka:``,title:`Developer`},{first:`Waldemar`,last:`Zeitler`,aka:``,title:`Developer`},{first:`Xiaoyi`,last:`Wang`,aka:``,title:`Developer`},{first:``,last:``,aka:``,title:``},{first:`Adrian`,last:`Baboi`,aka:``,title:`Vehicle Creation`},{first:`Brandon`,last:`Proulx`,aka:`Hondune`,title:`Vehicle Creation`},{first:`Carlos`,last:`Bergillos Varela`,aka:`CarlosAir`,title:`Content Creation`},{first:`David`,last:`Thurlbeck`,aka:``,title:`Vehicle Creation`},{first:`Janne`,last:`Nummela`,aka:``,title:`Vehicle Creation`},{first:`Jukka`,last:`Muikkula`,aka:`Miura`,title:`Vehicle Creation`},{first:`Karol`,last:`Miklas`,aka:``,title:`Freelance 3D Vehicle Artist`},{first:`Mardem`,last:`Pires das Dores`,aka:``,title:`Vehicle Creation`},{first:`Mikko`,last:`Lesonen`,aka:``,title:`Vehicle Creation`},{first:`Renju`,last:`Therakathu`,aka:``,title:`Vehicle Creation`},{first:`Sam`,last:`Millington`,aka:`DrowsySam`,title:`Vehicle Creation / Support`},{first:`Sebastian`,last:`Wessel`,aka:``,title:`Vehicle Creation`},{first:`Virtual Mechanix`,last:``,aka:``,title:`Vehicle Creation - Outsourcing Agency`},{first:`Winston`,last:`Broderick`,aka:``,title:`Vehicle Creation`},{first:`Mitchell`,last:`Sahl`,aka:`B25Mitch`,title:`3D Vehicle / Environment Artist`},{first:``,last:``,aka:``,title:``},{first:`Christin`,last:`Walther`,aka:``,title:`Lead 3D Artist`},{first:`Justin`,last:`Roczniak`,aka:`Donoteat`,title:`Environment Artist`},{first:`Lisa`,last:`Steinberg`,aka:``,title:`2D Artist`},{first:`Moses`,last:`Mulinge`,aka:``,title:`2D Artist`},{first:``,last:``,aka:``,title:``},{first:`Barend`,last:`van der Meulen`,aka:``,title:`Content Creator`},{first:`Matthias`,last:`Niebergall`,aka:``,title:`Game Designer`},{first:`SanityCheckMyGame`,last:``,aka:``,title:`Additional Design`},{first:``,last:``,aka:``,title:``},{first:`Georgios`,last:`Siantikos`,aka:`gntikos`,title:`User Interface`},{first:`Jonathan`,last:`Randy`,aka:``,title:`Lead Developer`},{first:`Mirco`,last:`Weigel`,aka:`theshark`,title:`User Interface`},{first:`Svetlozar`,last:`Valchev`,aka:``,title:`User Interface`},{first:`Theodoros`,last:`Manouilidis`,aka:``,title:`User Interface`},{first:`Yale`,last:`Hartmann`,aka:``,title:`User Interface`},{first:``,last:``,aka:``,title:``},{first:`Arend`,last:`Stührmann`,aka:``,title:`Producer`},{first:`Marie Cécile`,last:`Jacq`,aka:``,title:`Producer`},{first:`Nhung Van`,last:`Ho`,aka:``,title:`Project Management`},{first:``,last:``,aka:``,title:``},{first:`Bhavinkumar Babulal`,last:`Arya`,aka:``,title:`Research Software Engineer`},{first:`Carol`,last:`Halim`,aka:`Carotte`,title:`Research Software Engineer`},{first:`Elmar`,last:`Berghöfer`,aka:``,title:`Research`},{first:`Mattia`,last:`Vicari`,aka:``,title:`Research Software Engineer`},{first:``,last:``,aka:``,title:``},{first:`Camila`,last:`Navia`,aka:``,title:`Operations Assistant`},{first:`Danish`,last:`Abbasi`,aka:``,title:`Business Development Intern`},{first:`Lucien`,last:`Frei`,aka:``,title:`Business Development Intern`},{first:`Weiwei`,last:`Kong`,aka:``,title:`Business Development Intern`},{first:`Özgen`,last:`Saatçilar`,aka:``,title:`Communications Consultant`},{first:`Saskia`,last:`Opitz`,aka:``,title:`Administration`},{first:``,last:``,aka:``,title:``},{first:`Hala`,last:`Mahmoud`,aka:``,title:`Quality Assurance`},{first:`Jan Niklas`,last:`Hasse`,aka:``,title:`Quality Assurance`},{first:`Kamil`,last:`Kozak`,aka:``,title:`Quality Assurance`},{first:`Kemisola`,last:`Adeniyi`,aka:``,title:`Quality Assurance`},{first:`Kaja`,last:`Jambrek`,aka:``,title:`Quality Assurance`},{first:`Rajinder`,last:`Rajinder`,aka:``,title:`Quality Assurance`},{first:`Safdar`,last:`Mahmood`,aka:``,title:`Quality Assurance`},{first:`Uros`,last:`Sakic`,aka:`Uki`,title:`QA / Mod Support / Tools QA`},{first:``,last:``,aka:``,title:``},{first:`Konstantinos`,last:`Stamou`,aka:``,title:`System Administrator`},{first:``,last:``,aka:``,title:``},{first:`Erik`,last:`Heldt`,aka:``,title:`Documentation`},{first:`Maxime`,last:`Desharnais`,aka:``,title:`Documentation`},{first:`Harm`,last:`Schulz`,aka:``,title:`Student Assistant`},{first:`Annisa`,last:`Utami`,aka:``,title:`Student Assistant`},{first:`Brandon`,last:`Lynch`,aka:`Chuck_Norris_`,title:`Community Coordinator`},{first:`Monica`,last:`Huang`,aka:``,title:`Community Coordinator`}]},{translateId:`ui.credits.ourAwesomeCommunity`,members:[{first:`Daniel`,last:`Jones`,aka:`daniel_j`},{first:`Dennis`,last:`Wrekenhorst`,aka:`Dennis-W`},{first:`Dustin`,last:`Kutchara`,aka:`dkutch`},{first:`Kristian`,last:`Fagerland`,aka:``},{first:`Richard`,last:`Sixsmith`,aka:`Metalmuncher`},{first:`Sergy`,last:`Karpowicz`,aka:`0xsergy`},{first:`Sven`,last:`Nabeck`,aka:`sputnik_1`},{first:`Tom`,last:`Verhoeve`,aka:`Mythbuster`},{first:`Yannis`,last:`Vaiopoulos`,aka:`JohnV`},{first:``,last:``,aka:`Fufsgfen`}]},{translateId:`ui.credits.specialThanksTo`,members:[{first:`Luis`,last:`Placid`,aka:``,title:`VFX Developer`},{first:`Pierre-Michel`,last:`Ricordel`,aka:`pricorde`}]},{translateId:`ui.credits.soundtrack`,members:[{first:`Gabriel "gabester" Fink`,last:`Copyright 2014`,aka:`Lonle`},{first:`Mark "TDK" Knight`,last:`Copyright 2018`,aka:`Element No. 10`},{first:`Mark "TDK" Knight`,last:`Copyright 2018`,aka:`Getting Away`},{first:`Mark "TDK" Knight`,last:`Copyright 2018`,aka:`Juno Rocks`},{first:`Mark "TDK" Knight`,last:`Copyright 2018`,aka:`Neon Night Racer`},{first:`Mark "TDK" Knight`,last:`Copyright 2018`,aka:`Night Driver`}]},{translateId:`ui.credits.madePossibleWith`,members:[{first:`FMOD Studio by Firelight Technologies Pty Ltd.`,last:``,aka:``},{first:`LuaJIT`,last:``,aka:``},{first:`lua-intf, LuaBridge`,last:``,aka:``},{first:`Chromium Embedded Framework`,last:``,aka:``},{first:`AngularJS`,last:``,aka:``},{first:`Vue.js`,last:``,aka:``},{first:`Material Design`,last:``,aka:``},{first:`LuaSocket`,last:``,aka:``},{first:`Dear ImGui`,last:``,aka:``},{first:`Blender ®`,last:`www.blender.org`,aka:``}]},{translateId:``,members:[{first:`“DUALSHOCK” and “DualSense” are registered trademarks or trademarks of Sony Interactive Entertainment Inc. Library programs for DUALSHOCK®4 and DualSense™ wireless controllers © 2022 Sony Interactive Entertainment Inc.`,last:``,aka:``}]}],_hoisted_1$119={class:`bng-credits-content`},_hoisted_2$99=[`src`],_hoisted_3$87={class:`category`},_hoisted_4$67={class:`credits-table`},_hoisted_5$57={class:`member-cell member-name`},_hoisted_6$44={key:0,class:`aka`},_hoisted_7$37={key:1},_hoisted_8$30={key:0,class:`member-cell member-dot`},_hoisted_9$27={key:1},_hoisted_10$21={key:2,class:`member-cell member-role`},_hoisted_11$19={key:3},_sfc_main$132={__name:`CreditsScroller`,setup(__props){useUINavScope(`credits`);let imageURL=getAssetURL(`images/logos.svg#bng-drive-white`),wrapper=ref(),running=!0,exit=()=>{running=!1,Lua_default.extensions.unload(`ui_credits`),Lua_default.scenetree[`maincef:setMaxFPSLimit`](30),window.bngVue.gotoAngularState(`menu.mainmenu`)};onMounted(()=>{Lua_default.extensions.load(`ui_credits`),Lua_default.scenetree[`maincef:setMaxFPSLimit`](60),wrapper.value.focus(),scrollContainer(wrapper.value,65,exit)}),onUnmounted(()=>{exit()});function scrollContainer(container,pxPerSecond){let scrollSpeed=pxPerSecond/1e3,currentPos=0,lastTime=0,smoother=0;window.requestAnimationFrame(function step(timestamp){let delta=Math.min(150,Math.max(0,timestamp-lastTime));smoother+=(delta-smoother)*.02;let moveDelta=smoother*scrollSpeed;lastTime=timestamp,currentPos+=moveDelta;let targetPos=container.scrollHeight-container.clientHeight;running&¤tPoswithDirectives((openBlock(),createElementBlock(`div`,{ref_key:`wrapper`,ref:wrapper,class:`bng-credits-wrapper`,tabindex:`0`,onKeypress:exit,"bng-ui-scope":`credits`},[createBaseVNode(`div`,_hoisted_1$119,[createBaseVNode(`img`,{class:`logo`,src:unref(imageURL),alt:``},null,8,_hoisted_2$99),(openBlock(!0),createElementBlock(Fragment,null,renderList(unref(data_default),(category,cIndex)=>(openBlock(),createElementBlock(`div`,{key:cIndex},[createBaseVNode(`div`,_hoisted_3$87,[createBaseVNode(`span`,null,toDisplayString(_ctx.$t(category.translateId)),1)]),createBaseVNode(`div`,_hoisted_4$67,[(openBlock(!0),createElementBlock(Fragment,null,renderList(category.members,(member,mIndex)=>(openBlock(),createElementBlock(`div`,{class:`member-row`,key:mIndex},[createBaseVNode(`span`,_hoisted_5$57,[createTextVNode(toDisplayString(member.first)+` `,1),member.aka?(openBlock(),createElementBlock(`span`,_hoisted_6$44,toDisplayString(`<`+member.aka+`>`),1)):(openBlock(),createElementBlock(`span`,_hoisted_7$37,`\xA0`)),createTextVNode(` `+toDisplayString(member.last),1)]),member.title?(openBlock(),createElementBlock(`span`,_hoisted_8$30,` . `)):(openBlock(),createElementBlock(`span`,_hoisted_9$27,`\xA0`)),member.title?(openBlock(),createElementBlock(`span`,_hoisted_10$21,toDisplayString(_ctx.$t(member.title)),1)):(openBlock(),createElementBlock(`span`,_hoisted_11$19,`\xA0`))]))),128))])]))),128)),_cache[0]||=createBaseVNode(`div`,{style:{"padding-top":`70vh`}},null,-1)])],32)),[[unref(BngOnUiNav_default),exit,`menu,back`]])}},CreditsScroller_default=__plugin_vue_export_helper_default(_sfc_main$132,[[`__scopeId`,`data-v-9c2fdcd3`]]),routes_default$4=[{path:`/credits`,name:`credits`,component:CreditsScroller_default}],_hoisted_1$118={class:`details`,"bng-nav-scroll":``},_hoisted_2$98={key:0,class:`header-content`},_hoisted_3$86={key:1,class:`preview`},_hoisted_4$66={key:2,class:`tags-section`},_hoisted_5$56={class:`tags-container`},_hoisted_6$43=[`onClick`],_hoisted_7$36=[`src`],_hoisted_8$29={key:3,class:`description`},_hoisted_9$26={key:0,class:`specs-grid`},_hoisted_10$20={class:`specs-grid-container`},_hoisted_11$18={class:`spec-content`},_hoisted_12$14={class:`spec-label`},_hoisted_13$13={class:`spec-value`},_hoisted_14$13={key:0,class:`bottom-section`},_hoisted_15$13={class:`buttons-section`},_hoisted_16$13={key:1,class:`button-container`},_sfc_main$131={__name:`GameplayDetails`,props:{activeItem:{type:Object,default:null},activeItemDetails:{type:Object,default:null},executeButton:{type:Function,default:()=>{}},toggleFavourite:{type:Function,default:()=>{}},exploreFolder:{type:Function,default:()=>{}},goToMod:{type:Function,default:()=>{}},showHeaderTitle:{type:Boolean,default:!0},inline:{type:Boolean,default:!1},buttonOverride:{type:Object,default:null}},setup(__props){let props=__props,handleButtonClick=buttonId=>{props.executeButton(buttonId)};return(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,{class:normalizeClass([`gameplay-details`,{inline:__props.inline}])},[withDirectives((openBlock(),createElementBlock(`div`,_hoisted_1$118,[__props.activeItemDetails?.headerTitle?(openBlock(),createElementBlock(`div`,_hoisted_2$98,[__props.showHeaderTitle?(openBlock(),createBlock(unref(bngCardHeading_default),{key:0,type:`none`,class:`header-title`},{default:withCtx(()=>[createTextVNode(toDisplayString(__props.activeItemDetails.headerTitle),1)]),_:1})):createCommentVNode(``,!0),__props.activeItemDetails?.preview?(openBlock(),createElementBlock(`div`,_hoisted_3$86,[createVNode(unref(aspectRatio_default),{class:normalizeClass([`preview-image`,{"has-header-title":__props.showHeaderTitle}]),ratio:`16:8`,"external-image":__props.activeItemDetails.preview},{default:withCtx(()=>[__props.inline?createCommentVNode(``,!0):(openBlock(),createBlock(unref(bngIcon_default),{key:0,class:`favourite-icon`,type:__props.activeItemDetails?.isFavourite?`star`:`starSecondary`,onClick:_cache[0]||=$event=>__props.toggleFavourite(__props.activeItem),color:__props.activeItemDetails?.isFavourite?`var(--bng-ter-yellow-50)`:`var(--bng-cool-gray-100)`},null,8,[`type`,`color`]))]),_:1},8,[`external-image`,`class`])])):createCommentVNode(``,!0),__props.activeItemDetails?.tags?.length>0?(openBlock(),createElementBlock(`div`,_hoisted_4$66,[createBaseVNode(`div`,_hoisted_5$56,[(openBlock(!0),createElementBlock(Fragment,null,renderList(__props.activeItemDetails.tags,tag=>(openBlock(),createElementBlock(`div`,{key:tag.key||tag.label,class:normalizeClass([`tag-item`,{clickable:tag.goToMod}]),onClick:$event=>tag.goToMod?__props.goToMod(tag.goToMod):null},[tag.icon?(openBlock(),createBlock(unref(bngIcon_default),{key:0,type:tag.icon},null,8,[`type`])):createCommentVNode(``,!0),tag.svg?(openBlock(),createElementBlock(`img`,{key:1,class:`svg-icon`,src:tag.svg},null,8,_hoisted_7$36)):createCommentVNode(``,!0),createTextVNode(` `+toDisplayString(tag.label),1)],10,_hoisted_6$43))),128))])])):createCommentVNode(``,!0),__props.activeItemDetails?.description?(openBlock(),createElementBlock(`div`,_hoisted_8$29,toDisplayString(__props.activeItemDetails.description),1)):createCommentVNode(``,!0)])):createCommentVNode(``,!0),__props.activeItemDetails?.buttonInfo?.length>0||__props.activeItemDetails?.bottomTags?.length>0?(openBlock(!0),createElementBlock(Fragment,{key:1},renderList(__props.activeItemDetails?.specifications,(specList,specListIndex)=>(openBlock(),createElementBlock(Fragment,{key:specListIndex},[specList.length>0?(openBlock(),createElementBlock(`div`,_hoisted_9$26,[createBaseVNode(`div`,_hoisted_10$20,[(openBlock(!0),createElementBlock(Fragment,null,renderList(specList,specification=>(openBlock(),createElementBlock(`div`,{key:specification.key,class:`spec-cell`},[specification.icon?(openBlock(),createBlock(unref(bngIcon_default),{key:0,type:specification.icon,class:`spec-icon`},null,8,[`type`])):createCommentVNode(``,!0),createBaseVNode(`div`,_hoisted_11$18,[createBaseVNode(`div`,_hoisted_12$14,toDisplayString(specification.label)+`:`,1),createBaseVNode(`div`,_hoisted_13$13,[createBaseVNode(`span`,null,toDisplayString(specification.value),1)])])]))),128))])])):createCommentVNode(``,!0)],64))),128)):createCommentVNode(``,!0)])),[[unref(BngUiNavScroll_default),void 0,void 0,{force:!0}]]),__props.activeItemDetails?.buttonInfo?.length>0||__props.buttonOverride?(openBlock(),createElementBlock(`div`,_hoisted_14$13,[createBaseVNode(`div`,_hoisted_15$13,[__props.buttonOverride?createCommentVNode(``,!0):(openBlock(!0),createElementBlock(Fragment,{key:0},renderList(__props.activeItemDetails.buttonInfo,button=>(openBlock(),createElementBlock(`div`,{key:button.buttonId,class:`button-container`},[createVNode(unref(bngButton_default),{"bng-scoped-nav-autofocus":button.primary,accent:button.primary?`main`:`secondary`,label:button.label,icon:button.icon,onClick:$event=>handleButtonClick(button.buttonId)},null,8,[`bng-scoped-nav-autofocus`,`accent`,`label`,`icon`,`onClick`])]))),128)),__props.buttonOverride?(openBlock(),createElementBlock(`div`,_hoisted_16$13,[createVNode(unref(bngButton_default),{"bng-scoped-nav-autofocus":!0,accent:`main`,label:__props.buttonOverride.label,icon:__props.buttonOverride.icon,onClick:_cache[1]||=$event=>__props.buttonOverride.click(__props.activeItem)},null,8,[`label`,`icon`])])):createCommentVNode(``,!0)])])):createCommentVNode(``,!0)],2))}},GameplayDetails_default=__plugin_vue_export_helper_default(_sfc_main$131,[[`__scopeId`,`data-v-7baeb809`]]),_hoisted_1$117=[`bng-ui-scope`],_hoisted_2$97={class:`popup-content`},_hoisted_3$85={class:`modal-header`},_hoisted_4$65={class:`vehicle-selector-section`},_hoisted_5$55={class:`vehicle-tile-wrapper`},_hoisted_6$42={class:`modal-content`},_hoisted_7$35={class:`spawnpoint-section`},_hoisted_8$28={class:`spawnpoint-info`},_hoisted_9$25={key:0,class:`spawnpoint-preview`},_hoisted_10$19=[`src`],_hoisted_11$17={class:`spawnpoint-name`},_hoisted_12$13={key:0,class:`config-section`},_hoisted_13$12={class:`group-title`},_hoisted_14$12={key:0},_hoisted_15$12={class:`always-show-section`},_hoisted_16$12={key:0,class:`modal-footer`},_sfc_main$130={__name:`LevelConfigurationModal`,props:{levelData:{type:Object,required:!0}},emits:[`return`],setup(__props,{emit:__emit}){useUINavBlocker().allowNavigationOnly();let{lua,events:events$3}=useBridge(),props=__props,emit$1=__emit,scopeName=usePopupUINavScopeName(`_levelConfigPopup`,props);provide(`gridSelectionState`,ref(null));let spawningOptions=ref([]),config=reactive({}),alwaysShowDialogue=ref(!1),vehicleTile=ref({}),loadSpawningOptions=async()=>{try{let levelName=props.levelData?.levelName,backendName=props.levelData?.backendName,result=await lua.ui_gameplaySelector_tileGenerators_levelTiles.getSpawningOptions(levelName,backendName);if(result){let options=result.options||[];spawningOptions.value=options,alwaysShowDialogue.value=result.alwaysShowDialogue||!1,result.vehicleTile?vehicleTile.value={key:`vehicle-selector`,name:result.vehicleTile.name||`Select Vehicle`,preview:result.vehicleTile.preview||`/ui/modules/vehicleSelector/placeholder.png`,sourceIcons:result.vehicleTile.sourceIcons||[]}:vehicleTile.value={key:`vehicle-selector`,name:`Select Vehicle`,preview:`/ui/modules/vehicleSelector/placeholder.png`,sourceIcons:[]},options.forEach(group=>{group.options&&Array.isArray(group.options)&&group.options.forEach(option=>{option.key&&option.value!==void 0&&(config[option.key]=option.value)})})}}catch(error){console.error(`Failed to load spawning options:`,error)}},handleOptionChange=async(key,newValue)=>{try{await lua.ui_gameplaySelector_tileGenerators_levelTiles.changeSpawningOption(key,newValue),events$3.emit(`gridSelectorRefreshCurrentItemDetails`,`freeroamSelector`)}catch(error){console.error(`Failed to update ${key} option:`,error)}},handleAlwaysShowDialogueChange=async newValue=>{try{let backendName=props.levelData?.backendName;await lua.ui_gameplaySelector_tileGenerators_levelTiles.setAlwaysShowDialogue(backendName,newValue),events$3.emit(`gridSelectorRefreshCurrentItemDetails`,`freeroamSelector`)}catch(error){console.error(`Failed to save default action preference:`,error)}},openVehicleSelector=async()=>{try{await lua.ui_vehicleSelector_general.openVehicleSelectorForFreeroamModal(),emit$1(`return`,!0)}catch(e){console.error(`Failed to open vehicle selector:`,e)}};onMounted(()=>{loadSpawningOptions()});let closeModal=()=>{emit$1(`return`,!1)},handleButtonClick=buttonId=>{closeModal(),events$3.emit(`gridSelectorExecuteButton`,`freeroamSelector`,buttonId)},handleCancelWithBack=()=>{closeModal()};return(_ctx,_cache)=>withDirectives((openBlock(),createElementBlock(`div`,{class:`level-configuration-modal popup`,"bng-ui-scope":unref(scopeName)},[createBaseVNode(`div`,_hoisted_2$97,[createBaseVNode(`div`,_hoisted_3$85,[_cache[1]||=createBaseVNode(`h2`,null,`Freeroam Spawning Options`,-1),createVNode(unref(bngIcon_default),{type:`xmarkBold`,class:`close-button`,onClick:closeModal,color:`var(--bng-cool-gray-100)`})]),createBaseVNode(`div`,_hoisted_4$65,[_cache[2]||=createBaseVNode(`h3`,{class:`group-title`},`Vehicle`,-1),createBaseVNode(`div`,_hoisted_5$55,[createTextVNode(toDisplayString(vehicleTile.value)+` `,1),createVNode(Tile_default,{tile:vehicleTile.value,displaySize:`small`,isConfig:!0,onClick:openVehicleSelector},null,8,[`tile`])])]),createBaseVNode(`div`,_hoisted_6$42,[createBaseVNode(`div`,_hoisted_7$35,[_cache[3]||=createBaseVNode(`h3`,null,`Selected Spawnpoint`,-1),createBaseVNode(`div`,_hoisted_8$28,[__props.levelData?.spawnPoint?.previews?.[0]?(openBlock(),createElementBlock(`div`,_hoisted_9$25,[createBaseVNode(`img`,{src:__props.levelData.spawnPoint.previews[0],alt:`Spawnpoint preview`},null,8,_hoisted_10$19)])):createCommentVNode(``,!0),createBaseVNode(`div`,_hoisted_11$17,toDisplayString(_ctx.$tt(__props.levelData?.spawnPoint?.translationId||`No Name?`)),1)])]),spawningOptions.value.length>0?(openBlock(),createElementBlock(`div`,_hoisted_12$13,[(openBlock(!0),createElementBlock(Fragment,null,renderList(spawningOptions.value,group=>(openBlock(),createElementBlock(`div`,{class:`config-group`,key:group.name},[createBaseVNode(`h3`,_hoisted_13$12,toDisplayString(group.name),1),(openBlock(!0),createElementBlock(Fragment,null,renderList(group.options,option=>(openBlock(),createElementBlock(`div`,{class:`config-item`,key:option.key},[option.label?(openBlock(),createElementBlock(`label`,_hoisted_14$12,[option.icon?(openBlock(),createBlock(unref(bngIcon_default),{key:0,type:option.icon,class:`option-icon`},null,8,[`type`])):createCommentVNode(``,!0),createTextVNode(` `+toDisplayString(option.label)+`: `,1)])):createCommentVNode(``,!0),createVNode(unref(bngSelect_default),{modelValue:config[option.key],"onUpdate:modelValue":[$event=>config[option.key]=$event,newValue=>handleOptionChange(option.key,newValue)],options:option.options,loop:``,config:{value:opt=>opt.value,label:opt=>opt.label}},null,8,[`modelValue`,`onUpdate:modelValue`,`options`,`config`])]))),128))]))),128))])):createCommentVNode(``,!0)]),createBaseVNode(`div`,_hoisted_15$12,[createVNode(unref(bngSwitch_default),{modelValue:alwaysShowDialogue.value,"onUpdate:modelValue":[_cache[0]||=$event=>alwaysShowDialogue.value=$event,handleAlwaysShowDialogueChange],label:`Always show this dialogue`,labelBefore:``},null,8,[`modelValue`])]),spawningOptions.value.length>0||__props.levelData?.buttonInfo&&__props.levelData.buttonInfo.length>0?(openBlock(),createElementBlock(`div`,_hoisted_16$12,[__props.levelData?.buttonInfo&&__props.levelData.buttonInfo.length>0?(openBlock(!0),createElementBlock(Fragment,{key:0},renderList(__props.levelData.buttonInfo,button=>(openBlock(),createBlock(unref(bngButton_default),{key:button.buttonId,label:button.label,icon:button.icon,accent:button.primary?`main`:`secondary`,onClick:$event=>handleButtonClick(button.buttonId)},null,8,[`label`,`icon`,`accent`,`onClick`]))),128)):createCommentVNode(``,!0)])):createCommentVNode(``,!0)])],8,_hoisted_1$117)),[[unref(BngOnUiNav_default),handleCancelWithBack,`back,menu`]])}},LevelConfigurationModal_default=__plugin_vue_export_helper_default(_sfc_main$130,[[`__scopeId`,`data-v-ec35f32c`]]),_sfc_main$129={__name:`FreeroamSelector`,setup(__props){let{events:events$3}=useBridge(),handleOpenLevelConfigPopup=data=>{addPopup(LevelConfigurationModal_default,{levelData:data}).promise};return onMounted(()=>{events$3.on(`openLevelConfigurationPopup`,handleOpenLevelConfigPopup)}),onUnmounted(()=>{events$3.off(`openLevelConfigurationPopup`,handleOpenLevelConfigPopup)}),(_ctx,_cache)=>(openBlock(),createBlock(GridSelector_default,{backendName:`freeroamSelector`,routePath:`/freeroam-selector`,defaultPath:{keys:[`allFreeroam`]},defaultDetailsMode:`detail`,hiddenTabs:[`filter`]},{"item-details":withCtx(({activeItem,activeItemDetails,executeButton,toggleFavourite,exploreFolder,goToMod})=>[createVNode(GameplayDetails_default,{activeItem,activeItemDetails,executeButton,toggleFavourite,exploreFolder,goToMod},null,8,[`activeItem`,`activeItemDetails`,`executeButton`,`toggleFavourite`,`exploreFolder`,`goToMod`])]),_:1}))}},FreeroamSelector_default=_sfc_main$129,_hoisted_1$116={class:`preview`},_hoisted_2$96={key:0,class:`general-tags`},_hoisted_3$84={key:1,class:`icon-text-tag`},_hoisted_4$64={class:`vehicle-text-header`},_hoisted_5$54={key:0,class:`general-specs`},_hoisted_6$41={key:1,class:`divider`},_hoisted_7$34={class:`vehicle-tags`},_hoisted_8$27=[`onClick`],_hoisted_9$24=[`src`],_hoisted_10$18={key:0,class:`source-icon-container`},_hoisted_11$16={key:1,class:`source-icon-container`},_hoisted_12$12={key:2,class:`source-icon-container auxiliary-icon`},_hoisted_13$11={key:2,class:`vehicle-description`},_hoisted_14$11={class:`specs-grid-container`},_hoisted_15$11={key:0,class:`spec-label`},_hoisted_16$11={class:`spec-value`},_hoisted_17$10={key:1,class:`spec-value`},_hoisted_18$8={key:0,class:`bottom-section`},_hoisted_19$6={class:`paint-list expanded`},_sfc_main$128={__name:`VehicleDetails`,props:{activeItem:{type:Object,default:null},activeItemDetails:{type:Object,default:null},executeButton:{type:Function,default:()=>{}},toggleFavourite:{type:Function,default:()=>{}},exploreFolder:{type:Function,default:()=>{}},goToMod:{type:Function,default:()=>{}},showHeaderTitle:{type:Boolean,default:!0},hideDetailsAndButtons:{type:Boolean,default:!1},inline:{type:Boolean,default:!1},buttonOverride:{type:Object,default:null}},emits:[`focus-item`],setup(__props,{emit:__emit}){let{showIfController}=storeToRefs(controls_default()),props=__props,emit$1=__emit,handleButtonClick=buttonId=>{let additionalData={};selectedMultiPaint.value&&(additionalData.paint=selectedMultiPaint.value.paintNames[0],additionalData.paint2=selectedMultiPaint.value.paintNames[1],additionalData.paint3=selectedMultiPaint.value.paintNames[2]),selectedPaint.value&&(additionalData.paint=selectedPaint.value.name),props.executeButton(buttonId,additionalData),emit$1(`button-click`,buttonId)},toggleFavourite=()=>{props.activeItem&&props.toggleFavourite(props.activeItem)},openFolder=path=>{props.exploreFolder(path)},goToMod=modId=>{props.goToMod(modId)},sortedFactoryPaints=computed(()=>{let factoryPaints=props.activeItemDetails?.paints?.factoryPaints;return Array.isArray(factoryPaints)?sortColors(factoryPaints).filter(paint=>paint&&paint.name):[]}),multiPaints=computed(()=>{let res=[],multiPaintSetups=props.activeItemDetails?.paints?.multiPaintSetups,factoryPaints=props.activeItemDetails?.paints?.factoryPaints;if(!Array.isArray(multiPaintSetups)||!Array.isArray(factoryPaints))return res;for(let i=0;iname&&factoryPaints.find(paint=>paint.name===name)||null).filter(paint=>paint!==null);paints.length>0&&res.push({id:paintNames.join(`|`),name:setup$3.name,paintNames,paints,applyAll:()=>applyMultipaint(setup$3)})}return res}),hasPaintData=computed(()=>props.activeItemDetails?.additionalData?.paint&&props.activeItemDetails?.paints?.factoryPaints),paintData=computed(()=>{if(!hasPaintData.value)return null;let additionalData=props.activeItemDetails.additionalData,factoryPaints=props.activeItemDetails.paints.factoryPaints,paintNames=[additionalData.paint,additionalData.paint2,additionalData.paint3].filter(name=>name),paints=paintNames.map(name=>{let paint=factoryPaints.find(p$1=>p$1.name===name);return paint?convertPaintToTileFormat(paint):null}).filter(paint=>paint!==null);return paints.length===0?null:{paint:paintNames[0],paintNames,paints}});function applyMultipaint(setup$3){selectedMultiPaint.value=setup$3,selectedPaint.value=null}let selectedMultiPaint=ref(null),selectedPaint=ref(null);ref(!1);let handleMultiPaintClick=(multiPaint,focus$1=!0)=>{selectedMultiPaint.value=multiPaints.value.find(mp=>mp.name===multiPaint.name),selectedPaint.value=null,focus$1&&emit$1(`focus-item`,`multiPaints`)},handlePaintClick=paint=>{selectedPaint.value=paint,selectedMultiPaint.value=null,emit$1(`focus-item`,`paints`)},convertPaintToTileFormat=paint=>{if(!paint)return null;if(paint.baseColor&&paint.paintString)return paint;try{let paintObj=new Paint;return paintObj.paint=paint,paintObj.paintObject}catch(error){return console.warn(`Failed to convert paint:`,paint,error),null}},selectDefaultMultiPaint=()=>{if(!props.activeItemDetails?.paints)return;let multiPaintSetups=props.activeItemDetails?.paints.multiPaintSetups;if(Array.isArray(multiPaintSetups)&&multiPaintSetups.length>0){let defaultMultiPaintSetup=multiPaintSetups.find(setup$3=>setup$3.isDefault);if(defaultMultiPaintSetup){let multiPaintsObj=multiPaints.value.find(mp=>mp.name===defaultMultiPaintSetup.name);if(multiPaintsObj){handleMultiPaintClick(multiPaintsObj,!1);return}}}};watch(()=>props.activeItemDetails,()=>{selectDefaultMultiPaint()}),onMounted(()=>{selectDefaultMultiPaint()});function average(arr){return arr.reduce((a$1,b)=>a$1+b)/arr.length}function valComparable(col,thres=.05){let bool=!0,av=average(col);for(let i=0;i=col[i];return bool&&=av>.8||av<.2,bool}function colorHigherHelper(itm){if(!itm||!itm.orig||!itm.orig.baseColor||!Array.isArray(itm.orig.baseColor)||itm.orig.baseColor.length<4)return 0;let av=average(itm.orig.baseColor.slice(0,3)),al=itm.orig.baseColor[3]/2,res=Math.abs(av-1)*al;return res===0?(av+al)/2:res+1}function colorHigher(a$1,b){if(!a$1||!b||!a$1.orig||!b.orig||!a$1.orig.baseColor||!b.orig.baseColor)return 0;let aColor=valComparable(a$1.orig.baseColor.slice(0,3)),bColor=valComparable(b.orig.baseColor.slice(0,3));if(aColor&&bColor)return colorHigherHelper(b)-colorHigherHelper(a$1);if(aColor&&!bColor)return 1;if(!aColor&&bColor)return-1;for(let i=0;i<3;i++)if(a$1.val[i]!==b.val[i])return a$1.val[i]-b.val[i];return 0}function colorValue(arr){if(!Array.isArray(arr)||arr.length<4)return[0,0,0,0];let repitions=8,rgb=[];for(let i=0;i<3;i++)rgb[i]=(1-arr[3]/2)*arr[i]+arr[3]/2*arr[i];let lum=Math.sqrt(.241*rgb[0]+.691*rgb[1]+.068*rgb[2]),hsl=Paint.rgbToHsl(rgb),out=[hsl[0],lum,hsl[1]].map(elem=>elem*8);return out[0]%2==1&&(out[1]=8-out[1],out[2]=8-out[2]),out.push(arr[3]),out}function sortColors(list){return Array.isArray(list)?list.filter(elem=>elem&&elem.baseColor&&Array.isArray(elem.baseColor)&&elem.baseColor.length>=4).map(elem=>({val:colorValue(elem.baseColor),orig:elem})).sort(colorHigher).map(elem=>elem.orig):[]}return(_ctx,_cache)=>(openBlock(),createElementBlock(Fragment,null,[withDirectives((openBlock(),createElementBlock(`div`,{class:normalizeClass([`details`,{inline:__props.inline}]),"bng-nav-scroll":``},[createBaseVNode(`div`,_hoisted_1$116,[__props.showHeaderTitle?(openBlock(),createBlock(bngCardHeading_default,{key:0,type:`none`,class:`header-title`},{default:withCtx(()=>[createTextVNode(toDisplayString(__props.activeItemDetails.headerTitle),1)]),_:1})):createCommentVNode(``,!0),createBaseVNode(`div`,{class:normalizeClass([`tags-and-preview`,{"has-header-title":__props.showHeaderTitle}])},[__props.activeItemDetails?.iconTags?.length>0?(openBlock(),createElementBlock(`div`,_hoisted_2$96,[(openBlock(!0),createElementBlock(Fragment,null,renderList(__props.activeItemDetails?.iconTags,icon=>(openBlock(),createBlock(bngTooltip_default,{key:icon.icon,text:icon.label,position:`left`},{default:withCtx(()=>[icon.icon?(openBlock(),createBlock(unref(bngIcon_default),{key:0,type:icon.icon,label:icon.label,onClick:$event=>goToMod(icon.goToMod),class:normalizeClass({"favourite-icon":icon.goToMod})},null,8,[`type`,`label`,`onClick`,`class`])):createCommentVNode(``,!0),icon.iconText?(openBlock(),createElementBlock(`span`,_hoisted_3$84,toDisplayString(icon.iconText),1)):createCommentVNode(``,!0)]),_:2},1032,[`text`]))),128))])):createCommentVNode(``,!0),createVNode(unref(aspectRatio_default),{class:normalizeClass([`preview-image`,{"has-header-title":__props.showHeaderTitle}]),ratio:`16:8`,"external-image":__props.activeItemDetails?.preview},{default:withCtx(()=>[__props.inline?createCommentVNode(``,!0):(openBlock(),createBlock(unref(bngIcon_default),{key:0,class:`favourite-icon`,type:__props.activeItemDetails?.isFavourite?`star`:`starSecondary`,onClick:toggleFavourite,color:__props.activeItemDetails?.isFavourite?`var(--bng-ter-yellow-50)`:`var(--bng-cool-gray-100)`},null,8,[`type`,`color`])),hasPaintData.value?(openBlock(),createBlock(unref(bngPaintTile_default),{key:1,"paint-id":`${__props.activeItem?.id||`vehicle`}:${paintData.value.paint}`,paint:paintData.value.paints,"paint-name":paintData.value.paintNames.join(`, `),width:56,height:24,class:`preview-paint-tile`,"bng-no-nav":`true`,tabindex:`-1`},null,8,[`paint-id`,`paint`,`paint-name`])):createCommentVNode(``,!0)]),_:1},8,[`class`,`external-image`])],2)]),createBaseVNode(`div`,_hoisted_4$64,[__props.activeItemDetails?.generalSpecs?.length>0?(openBlock(),createElementBlock(`div`,_hoisted_5$54,[(openBlock(!0),createElementBlock(Fragment,null,renderList(__props.activeItemDetails?.generalSpecs,spec=>(openBlock(),createElementBlock(`div`,{class:`spec-value`,key:spec.key},[Array.isArray(spec.value)?(openBlock(),createElementBlock(Fragment,{key:0},[createTextVNode(toDisplayString(_ctx.$tt(spec.value[0].text)),1)],64)):(openBlock(),createElementBlock(Fragment,{key:1},[createTextVNode(toDisplayString(spec.value),1)],64))]))),128))])):createCommentVNode(``,!0),__props.activeItemDetails?.generalSpecs.length>0?(openBlock(),createElementBlock(`div`,_hoisted_6$41)):createCommentVNode(``,!0),createBaseVNode(`div`,_hoisted_7$34,[(openBlock(!0),createElementBlock(Fragment,null,renderList(__props.activeItemDetails?.tags,tag=>(openBlock(),createElementBlock(`div`,{key:tag.key,class:normalizeClass([`source-icon-container`,{"auxiliary-icon":tag.auxiliary}]),onClick:$event=>_ctx.tagClicked(tag)},[tag.icon?(openBlock(),createBlock(unref(bngIcon_default),{key:0,type:tag.icon},null,8,[`type`])):createCommentVNode(``,!0),tag.svg?(openBlock(),createElementBlock(`img`,{key:1,class:`svg-icon`,src:tag.svg},null,8,_hoisted_9$24)):createCommentVNode(``,!0),createTextVNode(` `+toDisplayString(tag.label),1)],10,_hoisted_8$27))),128)),__props.activeItemDetails?.sourceIcon?(openBlock(),createElementBlock(`div`,_hoisted_10$18,[createVNode(unref(bngIcon_default),{type:__props.activeItemDetails?.sourceIcon.icon,onClick:_cache[0]||=$event=>goToMod(__props.activeItemDetails?.sourceIcon.goToMod)},null,8,[`type`]),createTextVNode(` `+toDisplayString(__props.activeItemDetails?.sourceIcon.label),1)])):createCommentVNode(``,!0),__props.activeItemDetails?.isFavourite?(openBlock(),createElementBlock(`div`,_hoisted_11$16,[createVNode(unref(bngIcon_default),{type:`star`,onClick:toggleFavourite}),_cache[2]||=createTextVNode(` Favourite`,-1)])):createCommentVNode(``,!0),__props.activeItemDetails?.configDetails.isAuxiliary?(openBlock(),createElementBlock(`div`,_hoisted_12$12,[createVNode(unref(bngIcon_default),{type:`bug`}),_cache[3]||=createTextVNode(` Auxiliary`,-1)])):createCommentVNode(``,!0)]),__props.activeItemDetails?.configDetails?.Description?(openBlock(),createElementBlock(`div`,_hoisted_13$11,toDisplayString(__props.activeItemDetails?.configDetails?.Description),1)):createCommentVNode(``,!0)]),__props.activeItemDetails?.configDetails&&!__props.hideDetailsAndButtons?(openBlock(!0),createElementBlock(Fragment,{key:0},renderList(__props.activeItemDetails?.specificationsList,(value,key)=>(openBlock(),createElementBlock(`div`,{key,class:`specs-grid`},[createBaseVNode(`div`,_hoisted_14$11,[(openBlock(!0),createElementBlock(Fragment,null,renderList(value.specifications,specification=>(openBlock(),createElementBlock(`div`,{key:specification.key,class:normalizeClass([`spec-cell`,{"full-width":!specification.key}])},[specification.key?(openBlock(),createElementBlock(`div`,_hoisted_15$11,toDisplayString(specification.key)+`:`,1)):createCommentVNode(``,!0),createBaseVNode(`div`,_hoisted_16$11,[Array.isArray(specification.value)?(openBlock(!0),createElementBlock(Fragment,{key:0},renderList(specification.value,(item,index)=>(openBlock(),createElementBlock(`div`,{key:index,class:normalizeClass([`spec-value-item`,{italic:item.italic}])},[createBaseVNode(`span`,null,toDisplayString(item.text),1),specification.postIcon?(openBlock(),createBlock(unref(bngIcon_default),{key:0,class:`spec-post-icon`,type:specification.postIcon},null,8,[`type`])):createCommentVNode(``,!0),specification.openFolder?(openBlock(),createBlock(unref(bngIcon_default),{key:1,class:`spec-post-icon`,type:`folder`,onClick:$event=>openFolder(specification.value)},null,8,[`onClick`])):createCommentVNode(``,!0)],2))),128)):(openBlock(),createElementBlock(`div`,_hoisted_17$10,[createBaseVNode(`span`,null,toDisplayString(specification.value),1),specification.postIcon?(openBlock(),createBlock(unref(bngIcon_default),{key:0,class:`spec-post-icon`,type:specification.postIcon},null,8,[`type`])):createCommentVNode(``,!0),specification.openFolder?(openBlock(),createBlock(unref(bngIcon_default),{key:1,class:`spec-post-icon`,type:`folder`,onClick:$event=>openFolder(specification.value)},null,8,[`onClick`])):createCommentVNode(``,!0)]))])],2))),128))])]))),128)):createCommentVNode(``,!0)],2)),[[unref(BngUiNavScroll_default),void 0,void 0,{force:!0}]]),__props.hideDetailsAndButtons?createCommentVNode(``,!0):(openBlock(),createElementBlock(`div`,_hoisted_18$8,[createBaseVNode(`div`,_hoisted_19$6,[(openBlock(!0),createElementBlock(Fragment,null,renderList(multiPaints.value,multiPaint=>(openBlock(),createBlock(unref(bngPaintTile_default),{key:multiPaint.name,"paint-id":`${__props.activeItem?.id||`vehicle`}:${multiPaint.name}`,paint:multiPaint.paints,"paint-name":multiPaint.name,"paint-names":multiPaint.paintNames,width:56,height:24,class:normalizeClass([`multi-paint-item`,{selected:selectedMultiPaint.value?.name===multiPaint.name}]),onClick:$event=>handleMultiPaintClick(multiPaint)},null,8,[`paint-id`,`paint`,`paint-name`,`paint-names`,`class`,`onClick`]))),128)),(openBlock(!0),createElementBlock(Fragment,null,renderList(sortedFactoryPaints.value,paint=>(openBlock(),createElementBlock(Fragment,{key:paint.name},[paint&&paint.class===`factory`&&paint.name?(openBlock(),createBlock(unref(bngPaintTile_default),{key:0,"paint-id":`${__props.activeItem?.id||`vehicle`}:${paint.name}`,paint:convertPaintToTileFormat(paint),"vehicle-name":`factory`,"paint-name":paint.name,width:24,height:24,class:normalizeClass([`paint-item`,{selected:selectedPaint.value===paint}]),onClick:$event=>handlePaintClick(paint)},null,8,[`paint-id`,`paint`,`paint-name`,`class`,`onClick`])):createCommentVNode(``,!0)],64))),128))]),__props.activeItemDetails?.buttonInfo&&!__props.buttonOverride?(openBlock(!0),createElementBlock(Fragment,{key:0},renderList(__props.activeItemDetails?.buttonInfo,button=>(openBlock(),createBlock(unref(bngButton_default),{key:button.buttonId,"bng-scoped-nav-autofocus":button.primary,accent:button.primary?`main`:`secondary`,label:button.label,icon:button.icon,onClick:$event=>handleButtonClick(button.buttonId)},null,8,[`bng-scoped-nav-autofocus`,`accent`,`label`,`icon`,`onClick`]))),128)):createCommentVNode(``,!0),__props.buttonOverride?(openBlock(),createBlock(unref(bngButton_default),{key:1,"bng-scoped-nav-autofocus":!0,accent:`main`,label:__props.buttonOverride.label,icon:__props.buttonOverride.icon,onClick:_cache[1]||=$event=>__props.buttonOverride.click(__props.activeItem,selectedPaint.value,selectedMultiPaint.value)},null,8,[`label`,`icon`])):createCommentVNode(``,!0)]))],64))}},VehicleDetails_default=__plugin_vue_export_helper_default(_sfc_main$128,[[`__scopeId`,`data-v-58d013e3`]]);function useFreeroamConfigurator(){let{events:events$3}=useBridge(),configData=ref(null),button=ref(null),error=ref(null),isInitializing=ref(!1),refreshConfigHandler=()=>{logger_default.debug(`freeroamConfiguratorRefreshConfig`),loadConfiguration()},refreshButtonHandler=()=>{logger_default.debug(`freeroamConfiguratorRefreshButton`),loadButtons()};events$3.on(`freeroamConfiguratorRefreshConfig`,refreshConfigHandler),events$3.on(`freeroamConfiguratorRefreshButton`,refreshButtonHandler);let loadButtons=async()=>{try{let buttonData=await Lua_default.freeroam_freeroamConfigurator.getButtons();button.value=buttonData||null,logger_default.debug(`Loaded button:`,buttonData)}catch(err){logger_default.error(`Failed to load button:`,err),error.value=err}},loadConfiguration=async()=>{try{error.value=null;let data=await Lua_default.freeroam_freeroamConfigurator.getConfiguration();data?.options&&processOptionsTree(data.options),configData.value=data,logger_default.debug(`Loaded configuration:`,data),await loadButtons()}catch(err){logger_default.error(`Failed to load freeroam configuration:`,err),error.value=err}},processOptionsTree=options=>{!options||!Array.isArray(options)||options.forEach(group=>{group.key&&(group.onChange=val=>{group.value=val,handleOptionChange(group.key,val)}),Object.defineProperty(group,`enabled`,{get(){return!this.key||!!this.value},enumerable:!0,configurable:!0}),group.options&&Array.isArray(group.options)&&group.options.forEach(option=>{option.key&&(option.onChange=val=>{option.value=val,handleOptionChange(option.key,val)})})})},onSpawnPointTileClick=async()=>{try{await Lua_default.freeroam_freeroamConfigurator.onSpawnPointTileClick(),logger_default.debug(`Spawn point tile clicked`)}catch(err){logger_default.error(`Failed to handle spawnpoint tile click:`,err),error.value=err}},onVehicleTileClick=async()=>{try{await Lua_default.freeroam_freeroamConfigurator.onVehicleTileClick(),logger_default.debug(`Vehicle tile clicked`)}catch(err){logger_default.error(`Failed to handle vehicle tile click:`,err),error.value=err}},updateOption=async(key,value)=>{try{await Lua_default.freeroam_freeroamConfigurator.updateOption(key,value),logger_default.debug(`Updated option ${key}:`,value)}catch(err){logger_default.error(`Failed to update option ${key}:`,err),error.value=err}},handleOptionChange=async(key,newValue)=>{try{await Lua_default.freeroam_freeroamConfigurator.updateOption(key,newValue),await loadButtons(),logger_default.debug(`Handled option change ${key}:`,newValue)}catch(err){logger_default.error(`Failed to update ${key} option:`,err),error.value=err}},handleButtonClick=async buttonId=>{try{await Lua_default.freeroam_freeroamConfigurator.triggerButton(buttonId),logger_default.debug(`Button clicked:`,buttonId)}catch(err){logger_default.error(`Failed to trigger button:`,err),error.value=err}},selectSpawnPoint=async(levelName,spawnPointObjectName,key)=>{try{if(!levelName)throw logger_default.error(`selectSpawnPoint: levelName is required`),Error(`levelName is required`);return await Lua_default.freeroam_freeroamConfigurator.setSpawnPoint(levelName,spawnPointObjectName,key),configData.value.currentSpawnPoint=await Lua_default.freeroam_freeroamConfigurator.getCurrentSpawnPointTile(),logger_default.debug(`Selected spawn point:`,{levelName,spawnPointObjectName}),!0}catch(err){return logger_default.error(`Failed to select spawn point:`,err),error.value=err,!1}},selectVehicle=async(model,config,additionalData,key)=>{try{if(!model||!config)throw logger_default.error(`selectVehicle: model and config are required`),Error(`model and config are required`);return await Lua_default.freeroam_freeroamConfigurator.setVehicle(model,config,additionalData||{},key),configData.value.currentVehicle=await Lua_default.freeroam_freeroamConfigurator.getCurrentVehicleTile(),logger_default.debug(`Selected vehicle:`,{model,config,additionalData}),!0}catch(err){return logger_default.error(`Failed to select vehicle:`,err),error.value=err,!1}},gotoHeaderItem=item=>{item.gotoPath&&(window.bngVue.gotoGameState(item.gotoPath.path,{params:item.gotoPath.props}),logger_default.debug(`Navigated to path:`,item.gotoPath)),item.gotoAngularState&&(window.bngVue.gotoAngularState(item.gotoAngularState),logger_default.debug(`Navigated to angular state:`,item.gotoAngularState)),item.click&&(item.click(),logger_default.debug(`Navigated to click:`,item.click))},goBack=()=>{logger_default.debug(`goBack called`),gotoHeaderItem({gotoAngularState:`menu.mainmenu`})},hasOptions=computed(()=>configData.value?.options&&configData.value.options.length>0),hasSpawnPoint=computed(()=>!!configData.value?.currentSpawnPoint),hasVehicle=computed(()=>!!configData.value?.currentVehicle),canConfigureOptions=computed(()=>hasSpawnPoint.value&&hasVehicle.value),isGroupEnabled=group=>!group.key||!!group.value,initialize=async()=>{if(isInitializing.value){logger_default.debug(`Already initializing, skipping...`);return}try{isInitializing.value=!0,logger_default.debug(`Initializing FreeroamConfigurator composable...`),await loadConfiguration(),logger_default.debug(`FreeroamConfigurator composable initialized successfully`)}catch(err){logger_default.error(`Failed to initialize FreeroamConfigurator composable:`,err),error.value=err}finally{isInitializing.value=!1}},cleanup=()=>{logger_default.debug(`FreeroamConfigurator composable cleanup`),events$3.off(`freeroamConfiguratorRefreshConfig`,refreshConfigHandler),events$3.off(`freeroamConfiguratorRefreshButton`,refreshButtonHandler)};return onUnmounted(()=>{cleanup()}),{configData,config:configData,button,error,isInitializing,hasOptions,hasSpawnPoint,hasVehicle,canConfigureOptions,initialize,loadConfiguration,loadButtons,onSpawnPointTileClick,onVehicleTileClick,updateOption,handleOptionChange,handleButtonClick,selectSpawnPoint,selectVehicle,gotoHeaderItem,goBack,isGroupEnabled}}var _hoisted_1$115={class:`configurator-content`},_hoisted_2$95={key:0,class:`error-state`},_hoisted_3$83={class:`error-content`},_hoisted_4$63={key:1,class:`configurator-sections`,"bng-nav-item":``},_hoisted_5$53={class:`three-column-layout`},_hoisted_6$40={class:`config-section`,"bng-nav-item":``},_hoisted_7$33={class:`section-header`},_hoisted_8$26={class:`section-title-value`},_hoisted_9$23={class:`section-content`},_hoisted_10$17={key:0,class:`clickable`},_hoisted_11$15={key:1,class:`placeholder-content`},_hoisted_12$11={class:`config-section`,"bng-nav-item":``},_hoisted_13$10={class:`section-header`},_hoisted_14$10={class:`section-title-value`},_hoisted_15$10={class:`section-content`},_hoisted_16$10={key:0,class:`clickable`},_hoisted_17$9={key:1,class:`placeholder-content`},_hoisted_18$7={class:`config-section`,"bng-nav-item":``},_hoisted_19$5={class:`section-header`},_hoisted_20$5={key:0,class:`options-scope`},_hoisted_21$5={key:0,class:`section-header`},_hoisted_22$5=[`bng-scoped-nav-autofocus`],_hoisted_23$4={class:`option-label`},_hoisted_24$3={key:1,class:`placeholder-content`},_hoisted_25$2={class:`action-button-container`},_hoisted_26$1={class:`button-content`},_hoisted_27$1={key:1,class:`placeholder-content row`},_sfc_main$127={__name:`FreeroamConfigurator`,setup(__props){let{lua}=useBridge(),{configData,config,button,error,hasOptions,hasSpawnPoint,hasVehicle,canConfigureOptions,initialize,onSpawnPointTileClick,onVehicleTileClick,handleOptionChange,handleButtonClick,gotoHeaderItem,goBack,isGroupEnabled}=useFreeroamConfigurator();return onBeforeMount(()=>{lua.simTimeAuthority.pushPauseRequest(`freeroamConfigurator`)}),onMounted(()=>{initialize()}),onUnmounted(()=>{lua.simTimeAuthority.popPauseRequest(`freeroamConfigurator`)}),(_ctx,_cache)=>withDirectives((openBlock(),createBlock(unref(layoutSingle_default),{class:`freeroam-configurator`},{default:withCtx(()=>[createBaseVNode(`div`,_hoisted_1$115,[createVNode(unref(bngScreenHeadingV2_default),{class:`configurator-heading`},{preheadings:withCtx(()=>[createVNode(unref(bngBreadcrumbs_default),{"show-back-button":!0,simple:``,"disable-last-item":``,class:`configurator-breadcrumbs`,onBack:unref(goBack),onClick:unref(gotoHeaderItem),items:[{label:`Menu`,gotoAngularState:`menu.mainmenu`},{label:`Freeroam Configurator`}]},null,8,[`onBack`,`onClick`])]),default:withCtx(()=>[_cache[3]||=createTextVNode(` Freeroam `,-1)]),_:1}),unref(error)?(openBlock(),createElementBlock(`div`,_hoisted_2$95,[createVNode(BlurBackground_default),createBaseVNode(`div`,_hoisted_3$83,[createVNode(unref(bngIcon_default),{type:`warning`,class:`error-icon`}),_cache[5]||=createBaseVNode(`p`,null,`Failed to load configuration`,-1),createVNode(unref(bngButton_default),{onClick:unref(initialize),accent:unref(ACCENTS).secondary},{default:withCtx(()=>[..._cache[4]||=[createTextVNode(`Retry`,-1)]]),_:1},8,[`onClick`,`accent`])])])):withDirectives((openBlock(),createElementBlock(`div`,_hoisted_4$63,[createBaseVNode(`div`,_hoisted_5$53,[withDirectives((openBlock(),createElementBlock(`div`,_hoisted_6$40,[createVNode(BlurBackground_default),createBaseVNode(`div`,_hoisted_7$33,[createVNode(unref(bngCardHeading_default),{type:`ribbon`,class:`section-title`},{default:withCtx(()=>[_cache[6]||=createBaseVNode(`span`,{class:`section-title-label`},`Location:`,-1),createBaseVNode(`span`,_hoisted_8$26,toDisplayString(unref(configData)?.currentSpawnPoint?.headerTitle||`Select location...`),1)]),_:1})]),createBaseVNode(`div`,_hoisted_9$23,[createBaseVNode(`div`,{class:`selectable-component`,onClick:_cache[0]||=()=>unref(onSpawnPointTileClick)()},[unref(configData)?.currentSpawnPoint?(openBlock(),createElementBlock(`div`,_hoisted_10$17,[createVNode(GameplayDetails_default,{"active-item":{levelName:unref(configData).currentSpawnPoint.levelName,spawnPointObjectName:unref(configData).currentSpawnPoint.spawnPointObjectName},"active-item-details":unref(configData).currentSpawnPoint,inline:``},null,8,[`active-item`,`active-item-details`])])):(openBlock(),createElementBlock(`div`,_hoisted_11$15,[createVNode(unref(bngIcon_default),{type:`road`,class:`placeholder-icon`}),_cache[7]||=createBaseVNode(`p`,{class:`placeholder-text`},`Click to select location`,-1)]))])])])),[[unref(BngBlur_default)],[unref(BngOnUiNav_default),()=>unref(onSpawnPointTileClick)(),`ok`,{focusRequired:!0}]]),withDirectives((openBlock(),createElementBlock(`div`,_hoisted_12$11,[createVNode(BlurBackground_default),createBaseVNode(`div`,_hoisted_13$10,[createVNode(unref(bngCardHeading_default),{type:`ribbon`,class:`section-title`},{default:withCtx(()=>[_cache[8]||=createBaseVNode(`span`,{class:`section-title-label`},`Vehicle:`,-1),createBaseVNode(`span`,_hoisted_14$10,toDisplayString(unref(configData)?.currentVehicle?.headerTitle||`Select vehicle...`),1)]),_:1})]),createBaseVNode(`div`,_hoisted_15$10,[createBaseVNode(`div`,{class:`selectable-component`,onClick:_cache[1]||=()=>unref(onVehicleTileClick)()},[unref(configData)?.currentVehicle?(openBlock(),createElementBlock(`div`,_hoisted_16$10,[createVNode(VehicleDetails_default,{"active-item":{model:unref(configData).currentVehicle.model,config:unref(configData).currentVehicle.config},"active-item-details":unref(configData).currentVehicle,"hide-details-and-buttons":``,inline:``},null,8,[`active-item`,`active-item-details`])])):(openBlock(),createElementBlock(`div`,_hoisted_17$9,[createVNode(unref(bngIcon_default),{type:`car`,class:`placeholder-icon`}),_cache[9]||=createBaseVNode(`p`,{class:`placeholder-text`},`Click to select vehicle`,-1)]))])])])),[[unref(BngBlur_default)],[unref(BngOnUiNav_default),()=>unref(onVehicleTileClick)(),`ok`,{focusRequired:!0}]]),withDirectives((openBlock(),createElementBlock(`div`,_hoisted_18$7,[createVNode(BlurBackground_default),createBaseVNode(`div`,_hoisted_19$5,[createVNode(unref(bngCardHeading_default),{type:`ribbon`,class:`section-title`},{default:withCtx(()=>[..._cache[10]||=[createTextVNode(`Options`,-1)]]),_:1})]),createBaseVNode(`div`,{class:normalizeClass([`section-content`,{disabled:!unref(canConfigureOptions)}])},[unref(hasOptions)?(openBlock(),createElementBlock(`div`,_hoisted_20$5,[(openBlock(!0),createElementBlock(Fragment,null,renderList(unref(configData).options,group=>(openBlock(),createElementBlock(`div`,{class:`config-group`,key:group.name},[group.name?(openBlock(),createElementBlock(`div`,_hoisted_21$5,[createVNode(unref(bngCardHeading_default),{outline:!unref(isGroupEnabled)(group),type:`ribbon`,class:`section-title`},{default:withCtx(()=>[group.type===`switch`?(openBlock(),createBlock(unref(bngSwitch_default),{key:0,class:`group-switch`,modelValue:unref(config)[group.key],"onUpdate:modelValue":[$event=>unref(config)[group.key]=$event,newValue=>unref(handleOptionChange)(group.key,newValue)],label:group.name,labelBefore:``,inline:``,alwaysTransparent:``},null,8,[`modelValue`,`onUpdate:modelValue`,`label`])):createCommentVNode(``,!0)]),_:2},1032,[`outline`])])):createCommentVNode(``,!0),unref(isGroupEnabled)(group)?(openBlock(!0),createElementBlock(Fragment,{key:1},renderList(group.options,(option,optionIndex)=>(openBlock(),createElementBlock(`div`,{class:`config-item`,key:option.key,"bng-scoped-nav-autofocus":optionIndex===0},[createBaseVNode(`div`,{class:normalizeClass([`option-row`,{disabled:option.disabled}])},[createBaseVNode(`label`,_hoisted_23$4,[option.icon?(openBlock(),createBlock(unref(bngIcon_default),{key:0,type:option.icon,class:`option-icon`},null,8,[`type`])):createCommentVNode(``,!0),createTextVNode(` `+toDisplayString(option.label),1)]),option.type===`select`?(openBlock(),createBlock(unref(bngSmartSelect_default),{key:0,modelValue:unref(config)[option.key],items:option.options||[],threshold:80,"onUpdate:modelValue":newValue=>unref(handleOptionChange)(option.key,newValue)},null,8,[`modelValue`,`items`,`onUpdate:modelValue`])):option.type===`switch`?(openBlock(),createBlock(unref(bngSwitch_default),{key:1,modelValue:unref(config)[option.key],"onUpdate:modelValue":[$event=>unref(config)[option.key]=$event,newValue=>unref(handleOptionChange)(option.key,newValue)],label:option.label,labelBefore:``},null,8,[`modelValue`,`onUpdate:modelValue`,`label`])):option.type===`string`?(openBlock(),createBlock(unref(bngInput_default),{key:2,modelValue:unref(config)[option.key],"onUpdate:modelValue":$event=>unref(config)[option.key]=$event,placeholder:option.placeholder,"char-max":option.maxLength,onValueChanged:newValue=>unref(handleOptionChange)(option.key,newValue)},null,8,[`modelValue`,`onUpdate:modelValue`,`placeholder`,`char-max`,`onValueChanged`])):option.type===`number`?(openBlock(),createBlock(unref(bngInput_default),{key:3,modelValue:unref(config)[option.key],"onUpdate:modelValue":$event=>unref(config)[option.key]=$event,type:`number`,"num-min":option.min,"num-max":option.max,"num-step":option.step,onValueChanged:newValue=>unref(handleOptionChange)(option.key,newValue)},null,8,[`modelValue`,`onUpdate:modelValue`,`num-min`,`num-max`,`num-step`,`onValueChanged`])):createCommentVNode(``,!0)],2)],8,_hoisted_22$5))),128)):createCommentVNode(``,!0)]))),128))])):(openBlock(),createElementBlock(`div`,_hoisted_24$3,[createVNode(unref(bngIcon_default),{type:`adjust`,class:`placeholder-icon`}),_cache[11]||=createBaseVNode(`p`,{class:`placeholder-text`},`No options available`,-1)]))],2)])),[[unref(BngBlur_default)],[unref(BngScopedNav_default),{type:unref(SCOPED_NAV_TYPES).normal}]])]),createBaseVNode(`div`,_hoisted_25$2,[createVNode(BlurBackground_default),unref(button)?withDirectives((openBlock(),createBlock(unref(bngButton_default),{key:0,class:`action-button`,accent:unref(ACCENTS).custom,onClick:_cache[2]||=()=>unref(handleButtonClick)(unref(button).meta.buttonId),"bng-scoped-nav-autofocus":``},{default:withCtx(()=>[createBaseVNode(`div`,_hoisted_26$1,[unref(button).meta.icon?(openBlock(),createBlock(unref(bngIcon_default),{key:0,type:unref(button).meta.icon,class:`button-icon`},null,8,[`type`])):createCommentVNode(``,!0),createTextVNode(` `+toDisplayString(unref(button).meta.label),1)])]),_:1},8,[`accent`])),[[unref(BngBlur_default)]]):(openBlock(),createElementBlock(`div`,_hoisted_27$1,[createVNode(unref(bngIcon_default),{type:`play`,class:`placeholder-icon`}),_cache[12]||=createBaseVNode(`p`,{class:`placeholder-text`},`Select location and vehicle to start`,-1)]))])])),[[unref(BngScopedNav_default),{canDeactivate:()=>!1,activateOnMount:!0}],[unref(BngOnUiNav_default),unref(goBack),`back,menu`]])])]),_:1})),[[unref(BngOnUiNav_default),unref(goBack),`back,menu`]])}},FreeroamConfigurator_default=__plugin_vue_export_helper_default(_sfc_main$127,[[`__scopeId`,`data-v-14f15b24`]]),_hoisted_1$114={class:`options-panel-content`},_hoisted_2$94={class:`header-row`},_hoisted_3$82={key:0,class:`options-scope`},_hoisted_4$62={key:0,class:`section-header`},_hoisted_5$52={class:`option-label`},_hoisted_6$39={key:1,class:`placeholder-content`},_sfc_main$126={__name:`OptionsPanel`,props:{options:{type:Array,default:()=>[]},hasOptions:{type:Boolean,default:!1},canConfigureOptions:{type:Boolean,default:!0}},setup(__props){return(_ctx,_cache)=>withDirectives((openBlock(),createElementBlock(`div`,_hoisted_1$114,[createVNode(BlurBackground_default),createBaseVNode(`div`,_hoisted_2$94,[createVNode(unref(bngScreenHeadingV2_default),{type:`2`,class:`header-title-v2`},{default:withCtx(()=>[..._cache[0]||=[createTextVNode(` Options `,-1)]]),_:1})]),createBaseVNode(`div`,{class:normalizeClass([`section-content`,{disabled:!__props.canConfigureOptions}])},[__props.hasOptions?(openBlock(),createElementBlock(`div`,_hoisted_3$82,[(openBlock(!0),createElementBlock(Fragment,null,renderList(__props.options,group=>(openBlock(),createElementBlock(`div`,{class:`config-group`,key:group.name},[group.name?(openBlock(),createElementBlock(`div`,_hoisted_4$62,[createVNode(unref(bngCardHeading_default),{outline:!group.enabled,type:`ribbon`,class:`section-title`},{default:withCtx(()=>[group.type===`switch`?(openBlock(),createBlock(unref(bngSwitch_default),{key:0,class:`group-switch`,modelValue:group.value,"onUpdate:modelValue":[$event=>group.value=$event,group.onChange],label:group.name,labelBefore:``,inline:``,alwaysTransparent:``},null,8,[`modelValue`,`onUpdate:modelValue`,`label`])):createCommentVNode(``,!0)]),_:2},1032,[`outline`])])):createCommentVNode(``,!0),group.enabled?(openBlock(!0),createElementBlock(Fragment,{key:1},renderList(group.options,(option,optionIndex)=>(openBlock(),createElementBlock(`div`,{class:`config-item`,key:option.key},[createBaseVNode(`div`,{class:normalizeClass([`option-row`,{disabled:option.disabled}])},[createBaseVNode(`label`,_hoisted_5$52,[option.icon?(openBlock(),createBlock(unref(bngIcon_default),{key:0,type:option.icon,class:`option-icon`},null,8,[`type`])):createCommentVNode(``,!0),createTextVNode(` `+toDisplayString(option.label),1)]),option.type===`select`?(openBlock(),createBlock(unref(bngSmartSelect_default),{key:0,modelValue:option.value,"onUpdate:modelValue":[$event=>option.value=$event,option.onChange],items:option.options||[],threshold:80},null,8,[`modelValue`,`onUpdate:modelValue`,`items`])):option.type===`switch`?(openBlock(),createBlock(unref(bngSwitch_default),{key:1,modelValue:option.value,"onUpdate:modelValue":[$event=>option.value=$event,option.onChange],label:option.label,labelBefore:``},null,8,[`modelValue`,`onUpdate:modelValue`,`label`])):option.type===`string`?(openBlock(),createBlock(unref(bngInput_default),{key:2,modelValue:option.value,"onUpdate:modelValue":$event=>option.value=$event,placeholder:option.placeholder,"char-max":option.maxLength,onValueChanged:option.onChange},null,8,[`modelValue`,`onUpdate:modelValue`,`placeholder`,`char-max`,`onValueChanged`])):option.type===`number`?(openBlock(),createBlock(unref(bngInput_default),{key:3,modelValue:option.value,"onUpdate:modelValue":$event=>option.value=$event,type:`number`,"num-min":option.min,"num-max":option.max,"num-step":option.step,onValueChanged:option.onChange},null,8,[`modelValue`,`onUpdate:modelValue`,`num-min`,`num-max`,`num-step`,`onValueChanged`])):createCommentVNode(``,!0)],2)]))),128)):createCommentVNode(``,!0)]))),128))])):(openBlock(),createElementBlock(`div`,_hoisted_6$39,[createVNode(unref(bngIcon_default),{type:`adjust`,class:`placeholder-icon`}),_cache[1]||=createBaseVNode(`p`,{class:`placeholder-text`},`No options available`,-1)]))],2),renderSlot(_ctx.$slots,`buttons`,{},void 0,!0)])),[[unref(BngBlur_default)]])}},OptionsPanel_default=__plugin_vue_export_helper_default(_sfc_main$126,[[`__scopeId`,`data-v-c933da42`]]),_hoisted_1$113={class:`icon-wrapper`},_sfc_main$125={__name:`wizardStepButton`,props:{first:{type:Boolean,default:!1},title:{type:String,required:!0},tooltip:{type:String},active:{type:Boolean,default:!1},completed:{type:Boolean,default:!1},preview:{type:String,default:``},icon:{type:String,default:``},ratio:{type:String,default:`2:1`},showPaintTile:{type:Boolean,default:!1},paintId:{type:String,default:``},paints:{type:Array,default:()=>[]},paintName:{type:String,default:``},paintWidth:{type:Number,default:45},paintHeight:{type:Number,default:20}},emits:[`activate`],setup(__props,{emit:__emit}){let emit$1=__emit;function handleActivate(){emit$1(`activate`)}return(_ctx,_cache)=>withDirectives((openBlock(),createElementBlock(`div`,{class:normalizeClass([`step-tab`,{"first-tab":__props.first,"active-tab":__props.active,"completed-tab":__props.completed,"no-thumbnail":!__props.preview}]),onClick:handleActivate},[createBaseVNode(`div`,_hoisted_1$113,[createVNode(unref(bngIcon_default),{class:`step-icon`,type:__props.icon},null,8,[`type`])]),__props.preview?(openBlock(),createBlock(unref(aspectRatio_default),{key:0,class:`thumbnail-image`,ratio:__props.ratio,"external-image":__props.preview},{default:withCtx(()=>[renderSlot(_ctx.$slots,`overlay`,{},void 0,!0),__props.showPaintTile&&__props.paints&&__props.paints.length>0?(openBlock(),createBlock(unref(bngPaintTile_default),{key:0,"paint-id":__props.paintId,paint:__props.paints,"paint-name":__props.paintName,width:__props.paintWidth,height:__props.paintHeight,onClick:handleActivate,class:`preview-paint-tile`,"bng-no-nav":`true`,tabindex:`-1`},null,8,[`paint-id`,`paint`,`paint-name`,`width`,`height`])):createCommentVNode(``,!0)]),_:3},8,[`ratio`,`external-image`])):createCommentVNode(``,!0)],2)),[[unref(BngOnUiNav_default),handleActivate,`ok`,{focusRequired:!0}],[unref(BngTooltip_default),__props.tooltip,`bottom`]])}},wizardStepButton_default=__plugin_vue_export_helper_default(_sfc_main$125,[[`__scopeId`,`data-v-475a9f52`]]),_hoisted_1$112={class:`configurator-heading`},_hoisted_2$93={class:`configurator-body`},_hoisted_3$81={key:0,class:`grid-section`},_hoisted_4$61={key:1,class:`option-summary-panel`},_hoisted_5$51={class:`section-header`},_hoisted_6$38={class:`section-title-value`},_hoisted_7$32={class:`section-content`},_hoisted_8$25={key:0,class:`clickable`},_hoisted_9$22={key:1,class:`placeholder-content`},_hoisted_10$16={class:`section-header`},_hoisted_11$14={class:`section-title-value`},_hoisted_12$10={class:`section-content`},_hoisted_13$9={key:0,class:`clickable`},_hoisted_14$9={key:1,class:`placeholder-content`},_hoisted_15$9={class:`configurator-heading`},_hoisted_16$9={key:0,class:`error-state`},_hoisted_17$8={class:`error-content`},_hoisted_18$6={key:1,class:`configurator-sections`},_hoisted_19$4={class:`steps-container`},_hoisted_20$4={class:`background-bar`},_hoisted_21$4={class:`label`},_hoisted_22$4={class:`hold-binding`},WIZARD_SCOPE_ID=`freeroam-wizard`,_sfc_main$124={__name:`FreeroamWizard`,props:{step:{type:String,default:``},pathMatch:{type:[String,Array],default:``},itemDetails:{type:[String,Array],default:``}},setup(__props){let{lua,events:events$3}=useBridge(),router$1=useRouter(),scopedNav=useScopedNav(),steps={level:{title:`Location`,backendName:`freeroamSelector`,path:`/freeroam-wizard/level`,defaultPath:{keys:[`allFreeroam`]},defaultDetailsMode:`detail`,hiddenTabs:[`filter`,`advanced`]},vehicle:{title:`Vehicle`,backendName:`vehicleSelector`,path:`/freeroam-wizard/vehicle`,defaultPath:{keys:[`allModels`]},defaultDetailsMode:`detail`,hiddenTabs:[`advanced`]},options:{title:`Options`,path:`/freeroam-wizard/options`}},stepCompleted=computed(()=>({level:props.step===`vehicle`||props.step===`options`,vehicle:props.step===`options`,options:!1})),gridSelectorProps=computed(()=>{let stepConfig=steps[props.step];return stepConfig&&stepConfig.backendName&&stepConfig.path?{backendName:stepConfig.backendName,routePath:stepConfig.path,defaultPath:stepConfig.defaultPath||{keys:[]},defaultDetailsMode:stepConfig.defaultDetailsMode||`detail`,hiddenTabs:stepConfig.hiddenTabs||[]}:null}),props=__props,gridSelectorRef=ref(null),holdBindingRef=ref(null),isLoading=ref(!1),breadcrumbItems=computed(()=>{let items$2=[{label:`Menu`,gotoAngularState:`menu.mainmenu`},{label:`Freeroam Configurator`,dividerType:`arrowSmallRight`}];props.step===`level`?items$2.push({label:`Location`,click:()=>{onSpawnPointTileClick(!0)}}):props.step===`vehicle`?items$2.push({label:`Vehicle`,click:()=>{onVehicleTileClick(!0)}}):props.step===`options`&&items$2.push({label:`Options`,click:onOptionsTileClick});let screenHeaderPath=gridSelectorRef.value?.screenHeaderPath,pathValue=screenHeaderPath?.value||screenHeaderPath;return pathValue&&Array.isArray(pathValue)&&pathValue.length>2&&(pathValue.length>3?(items$2.push({label:pathValue[2].label,click:()=>{gridSelectorRef.value.setCurrentPath({keys:pathValue[2].gotoPath}),onSpawnPointTileClick()}}),items$2.push(pathValue[3])):items$2.push(pathValue[2])),items$2}),{configData,button,error,hasOptions,hasSpawnPoint,hasVehicle,canConfigureOptions,initialize,handleButtonClick,selectSpawnPoint,selectVehicle,gotoHeaderItem,loadConfiguration}=useFreeroamConfigurator();watch(()=>props.step,step=>{step===`options`&&(loadConfiguration(),scopedNav.resumeScope(WIZARD_SCOPE_ID))});let overrideSelectItem=async(step,...args)=>{if(props.step===`level`){let item=args[0];if(!item?.showDetails?.levelName)return logger_default.error(`overrideSelectItem: Invalid item data for level selection`),null;await selectSpawnPoint(item.showDetails.levelName,item.showDetails.spawnPointObjectName,item.key)&&router$1.push(steps.vehicle.path)}else if(props.step===`vehicle`){let item=args[0];if(!item?.showDetails?.model||!item?.showDetails?.config)return logger_default.error(`overrideSelectItem: Invalid item data for vehicle selection`),null;let selectedPaint=args[1],selectedMultiPaint=args[2],additionalData={};selectedMultiPaint?.paintNames?(additionalData.paint=selectedMultiPaint.paintNames[0],additionalData.paint2=selectedMultiPaint.paintNames[1],additionalData.paint3=selectedMultiPaint.paintNames[2]):selectedPaint?.name&&(additionalData.paint=selectedPaint.name),await selectVehicle(item.showDetails.model,item.showDetails.config,additionalData,item.key)&&router$1.push(steps.options.path)}return null},onSelectCallback=async(item,doNavigation)=>{if(doNavigation){if(props.step===`level`){if(!item?.doubleClickDetails?.levelName)return logger_default.error(`overrideSelectItem: Invalid item data for level selection`),null;await selectSpawnPoint(item.doubleClickDetails.levelName,item.doubleClickDetails.spawnPointObjectName,item.key)}else if(props.step===`vehicle`){if(!item?.doubleClickDetails?.model||!item?.doubleClickDetails?.config)return logger_default.error(`overrideSelectItem: Invalid item data for vehicle selection`),null;await selectVehicle(item.doubleClickDetails.model,item.doubleClickDetails.config,{},item.key)}}return null},doubleClickOverride=async item=>{if(!item?.doubleClickDetails){logger_default.error(`doubleClickOverride: Invalid item data`);return}let details=item.doubleClickDetails;details.levelName?await selectSpawnPoint(details.levelName,details.spawnPointObjectName,item.key)&&router$1.push(steps.vehicle.path):details.model&&details.config&&await selectVehicle(details.model,details.config,{},item.key)&&router$1.push(steps.options.path)},goBack=()=>{logger_default.debug(`goBack called`);let gridSelectorPath=gridSelectorRef.value?.screenHeaderPath;props.step===`level`?gridSelectorPath&&gridSelectorPath.length>2?onSpawnPointTileClick():window.bngVue.gotoAngularState(`menu.mainmenu`):props.step===`vehicle`?gridSelectorPath&&gridSelectorPath.length>2?onVehicleTileClick():onSpawnPointTileClick():props.step===`options`&&onVehicleTileClick()},onSpawnPointTileClick=async()=>{router$1.replace(steps.level.path)},onVehicleTileClick=async(clearSearch=!1)=>{clearSearch&&gridSelectorRef.value&&(gridSelectorRef.value.clearSearch(),gridSelectorRef.value.clearFilters()),router$1.replace(steps.vehicle.path)},onOptionsTileClick=async()=>{router$1.replace(steps.options.path)},onStartButtonClick=async buttonId=>{isLoading.value=!0,events$3.emit(`LoadingScreen`,{active:!0}),await startLoading$1(async()=>{await waitForLoadingScreenFadeIn$1(),await handleButtonClick(buttonId)})};function convertPaintToTileFormat(paint){if(!paint)return null;if(paint.baseColor&&paint.paintString)return paint;try{let paintObj=new Paint;return paintObj.paint=paint,paintObj.paintObject}catch(error$1){return console.warn(`Failed to convert paint:`,paint,error$1),null}}let vehiclePaintData=computed(()=>{let vehicle=configData.value?.currentVehicle;if(!vehicle?.additionalData?.paint||!vehicle?.paints?.factoryPaints)return null;let additionalData=vehicle.additionalData,factoryPaints=vehicle.paints.factoryPaints,paintNames=[additionalData.paint,additionalData.paint2,additionalData.paint3].filter(name=>name),paints=paintNames.map(name=>{let paint=factoryPaints.find(p$1=>p$1.name===name);return paint?convertPaintToTileFormat(paint):null}).filter(paint=>paint!==null);return paints.length===0?null:{paint:paintNames[0],paintNames,paints}});return onBeforeMount(()=>{lua.simTimeAuthority.pushPauseRequest(`freeroamConfigurator`)}),onMounted(()=>{initialize()}),onUnmounted(()=>{lua.simTimeAuthority.popPauseRequest(`freeroamConfigurator`)}),(_ctx,_cache)=>(openBlock(),createBlock(unref(layoutSingle_default),{class:`freeroam-configurator`},{default:withCtx(()=>[withDirectives((openBlock(),createElementBlock(`div`,{class:normalizeClass([`configurator-content`,{"options-step":__props.step===`options`}])},[createBaseVNode(`div`,_hoisted_1$112,[withDirectives(createVNode(unref(bngBreadcrumbs_default),{class:`configurator-breadcrumbs`,simple:``,"show-back-button":``,"disable-last-item":``,onBack:goBack,onClick:unref(gotoHeaderItem),limit:`15`,items:breadcrumbItems.value},null,8,[`onClick`,`items`]),[[unref(BngBlur_default)]])]),createBaseVNode(`div`,_hoisted_2$93,[__props.step!==`options`&&gridSelectorProps.value?(openBlock(),createElementBlock(`div`,_hoisted_3$81,[(openBlock(),createBlock(GridSelector_default,{ref_key:`gridSelectorRef`,ref:gridSelectorRef,key:`grid-selector-${__props.step}`,"backend-name":gridSelectorProps.value.backendName,"route-path":gridSelectorProps.value.routePath,"default-path":gridSelectorProps.value.defaultPath,"default-details-mode":gridSelectorProps.value.defaultDetailsMode,"hidden-tabs":gridSelectorProps.value.hiddenTabs,"no-breadcrumbs":``,"select-callback":onSelectCallback,"double-click-override":doubleClickOverride,"override-back-from-grid":goBack,"inline-header-container":``,"bubble-events":[`ok`]},{"item-details":withCtx(({activeItem,activeItemDetails,executeButton,toggleFavourite,exploreFolder,goToMod})=>[__props.step===`level`?(openBlock(),createBlock(GameplayDetails_default,{key:0,activeItem,activeItemDetails,toggleFavourite,exploreFolder,goToMod,buttonOverride:{icon:`fastTravel`,label:`Next Step`,click:(...args)=>overrideSelectItem(`level`,...args)},showHeaderTitle:!0},null,8,[`activeItem`,`activeItemDetails`,`toggleFavourite`,`exploreFolder`,`goToMod`,`buttonOverride`])):createCommentVNode(``,!0),__props.step===`vehicle`?(openBlock(),createBlock(VehicleDetails_default,{key:1,activeItem,activeItemDetails,toggleFavourite,exploreFolder,goToMod,buttonOverride:{icon:`fastTravel`,label:`Next Step`,click:(...args)=>overrideSelectItem(`vehicle`,...args)},showHeaderTitle:!0},null,8,[`activeItem`,`activeItemDetails`,`toggleFavourite`,`exploreFolder`,`goToMod`,`buttonOverride`])):createCommentVNode(``,!0)]),_:1},8,[`backend-name`,`route-path`,`default-path`,`default-details-mode`,`hidden-tabs`]))])):createCommentVNode(``,!0),__props.step===`options`&&unref(configData)?(openBlock(),createElementBlock(`div`,_hoisted_4$61,[withDirectives((openBlock(),createElementBlock(`div`,{class:`config-section selectable-component`,onClick:onSpawnPointTileClick},[createVNode(BlurBackground_default),createBaseVNode(`div`,_hoisted_5$51,[createVNode(unref(bngCardHeading_default),{type:`ribbon`,class:`section-title`},{default:withCtx(()=>[_cache[1]||=createBaseVNode(`span`,{class:`section-title-label`},`Location:`,-1),createBaseVNode(`span`,_hoisted_6$38,toDisplayString(unref(configData)?.currentSpawnPoint?.headerTitle||`Select location...`),1)]),_:1})]),createBaseVNode(`div`,_hoisted_7$32,[createBaseVNode(`div`,null,[unref(configData)?.currentSpawnPoint?(openBlock(),createElementBlock(`div`,_hoisted_8$25,[createVNode(GameplayDetails_default,{"active-item":{levelName:unref(configData).currentSpawnPoint.levelName,spawnPointObjectName:unref(configData).currentSpawnPoint.spawnPointObjectName},"active-item-details":unref(configData).currentSpawnPoint,inline:``,"show-header-title":!1},null,8,[`active-item`,`active-item-details`])])):(openBlock(),createElementBlock(`div`,_hoisted_9$22,[createVNode(unref(bngIcon_default),{type:`road`,class:`placeholder-icon`}),_cache[2]||=createBaseVNode(`p`,{class:`placeholder-text`},`Click to select location`,-1)]))])])])),[[unref(BngBlur_default)]]),withDirectives((openBlock(),createElementBlock(`div`,{class:`config-section selectable-component`,onClick:onVehicleTileClick},[createVNode(BlurBackground_default),createBaseVNode(`div`,_hoisted_10$16,[createVNode(unref(bngCardHeading_default),{type:`ribbon`,class:`section-title`},{default:withCtx(()=>[_cache[3]||=createBaseVNode(`span`,{class:`section-title-label`},`Vehicle:`,-1),createBaseVNode(`span`,_hoisted_11$14,toDisplayString(unref(configData)?.currentVehicle?.headerTitle||`Select vehicle...`),1)]),_:1})]),createBaseVNode(`div`,_hoisted_12$10,[createBaseVNode(`div`,null,[unref(configData)?.currentVehicle?(openBlock(),createElementBlock(`div`,_hoisted_13$9,[createVNode(VehicleDetails_default,{"active-item":{model:unref(configData).currentVehicle.model,config:unref(configData).currentVehicle.config},"active-item-details":unref(configData).currentVehicle,"hide-details-and-buttons":``,inline:``,"show-header-title":!1},null,8,[`active-item`,`active-item-details`])])):(openBlock(),createElementBlock(`div`,_hoisted_14$9,[createVNode(unref(bngIcon_default),{type:`car`,class:`placeholder-icon`}),_cache[4]||=createBaseVNode(`p`,{class:`placeholder-text`},`Click to select vehicle`,-1)]))])])])),[[unref(BngBlur_default)]]),withDirectives(createVNode(OptionsPanel_default,{class:`config-section`,options:unref(configData)?.options||[],"has-options":unref(hasOptions),"can-configure-options":unref(canConfigureOptions)},null,8,[`options`,`has-options`,`can-configure-options`]),[[unref(BngOnUiNav_default),goBack,`back`],[unref(BngOnUiNav_default),goBack,`menu`]])])):createCommentVNode(``,!0)]),createBaseVNode(`div`,_hoisted_15$9,[unref(error)?(openBlock(),createElementBlock(`div`,_hoisted_16$9,[createVNode(BlurBackground_default),createBaseVNode(`div`,_hoisted_17$8,[createVNode(unref(bngIcon_default),{type:`warning`,class:`error-icon`}),_cache[6]||=createBaseVNode(`p`,null,`Failed to load configuration`,-1),createVNode(unref(bngButton_default),{onClick:unref(initialize),accent:unref(ACCENTS).secondary},{default:withCtx(()=>[..._cache[5]||=[createTextVNode(`Retry`,-1)]]),_:1},8,[`onClick`,`accent`])])])):(openBlock(),createElementBlock(`div`,_hoisted_18$6,[withDirectives((openBlock(),createElementBlock(`div`,_hoisted_19$4,[createBaseVNode(`div`,_hoisted_20$4,[createVNode(BlurBackground_default)]),createVNode(wizardStepButton_default,{first:``,active:__props.step===`level`,completed:stepCompleted.value.level,title:`Location`,tooltip:unref(configData)?.currentSpawnPoint?.headerTitle,preview:unref(configData)?.currentSpawnPoint?.preview,icon:`road`,onActivate:onSpawnPointTileClick},null,8,[`active`,`completed`,`tooltip`,`preview`]),createVNode(wizardStepButton_default,{active:__props.step===`vehicle`,completed:stepCompleted.value.vehicle,title:`Vehicle`,tooltip:unref(configData)?.currentVehicle?.headerTitle,preview:unref(configData)?.currentVehicle?.preview,icon:`car`,"show-paint-tile":!!vehiclePaintData.value,"paint-id":`${unref(configData)?.currentVehicle?.key||`vehicle`}:${vehiclePaintData.value?.paint}`,paints:vehiclePaintData.value?.paints||[],"paint-name":vehiclePaintData.value?vehiclePaintData.value.paintNames.join(`, `):``,onActivate:onVehicleTileClick},null,8,[`active`,`completed`,`tooltip`,`preview`,`show-paint-tile`,`paint-id`,`paints`,`paint-name`]),createVNode(wizardStepButton_default,{active:__props.step===`options`,completed:stepCompleted.value.options,title:`Options`,tooltip:`Options`,icon:`adjust`,onActivate:onOptionsTileClick},null,8,[`active`,`completed`])])),[[unref(BngBlur_default)]]),withDirectives((openBlock(),createElementBlock(`div`,{class:`play-button`,onClick:_cache[0]||=$event=>onStartButtonClick(unref(button)?.meta?.buttonId),"bng-nav-item":``,tabindex:`1`},[_cache[8]||=createBaseVNode(`div`,{class:`background`},null,-1),createBaseVNode(`div`,_hoisted_21$4,[withDirectives(createBaseVNode(`div`,_hoisted_22$4,[createVNode(unref(bngBinding_default),{ref_key:`holdBindingRef`,ref:holdBindingRef,class:`binding`,"ui-event":`ok`,controller:``},null,512),_cache[7]||=createBaseVNode(`svg`,{class:`hold-arrow`,xmlns:`http://www.w3.org/2000/svg`,viewBox:`0 0 16 12`,preserveAspectRatio:`xMidYMid`},[createBaseVNode(`path`,{d:`M1,1 L8,2 L16,1 L8,11 z`})],-1)],512),[[vShow,holdBindingRef.value?.displayed]]),createTextVNode(` `+toDisplayString(unref(button)?.meta?.label||`Start`),1)])])),[[unref(BngOnUiNav_default),void 0,`ok`,{asMouse:!0}],[unref(BngSoundClass_default),`bng_click_hover_generic`]])]))])],2)),[[unref(BngScopedNav_default),{scopeId:WIZARD_SCOPE_ID,canDeactivate:()=>!1,activateOnMount:!0,bubbleBlacklistEvents:[`back`,`menu`]}],[unref(BngClick_default),{holdCallback:()=>onStartButtonClick(unref(button)?.meta?.buttonId),holdDelay:2e3,repeatInterval:0},void 0,{controller:!0}],[unref(BngOnUiNav_default),void 0,`ok`,{asMouse:!0}]])]),_:1}))}},FreeroamWizard_default=__plugin_vue_export_helper_default(_sfc_main$124,[[`__scopeId`,`data-v-6c942499`]]),routes_default$5=[{name:`menu.freeroamselector`,path:`/freeroam-selector/:pathMatch(.*)*/:itemDetails(.*)*`,component:FreeroamSelector_default,props:!0,meta:{clickThrough:!0,infoBar:{visible:!0,showSysInfo:!1},uiApps:{shown:!1},topBar:{visible:!0}}},{name:`menu.freeroamconfigurator`,path:`/freeroam-configurator`,component:FreeroamConfigurator_default,meta:{clickThrough:!0,infoBar:{visible:!0,showSysInfo:!1},uiApps:{shown:!1},topBar:{visible:!1}}},{name:`menu.freeroamWizard`,path:`/freeroam-wizard/:step/:pathMatch(.*)*/:itemDetails(.*)*`,component:FreeroamWizard_default,props:!0,meta:{clickThrough:!0,infoBar:{visible:!0,showSysInfo:!1},uiApps:{shown:!1},topBar:{visible:!1}}}],_sfc_main$123={__name:`GameplaySelector`,setup(__props){return(_ctx,_cache)=>(openBlock(),createBlock(GridSelector_default,{backendName:`gameplaySelector`,routePath:`/gameplay-selector`,defaultPath:{keys:[`allGameplay`]},defaultDetailsMode:`detail`,hiddenTabs:[`filter`]},{"item-details":withCtx(({activeItem,activeItemDetails,executeButton,toggleFavourite,exploreFolder,goToMod})=>[createVNode(GameplayDetails_default,{activeItem,activeItemDetails,executeButton,toggleFavourite,exploreFolder,goToMod,showHeaderTitle:!0},null,8,[`activeItem`,`activeItemDetails`,`executeButton`,`toggleFavourite`,`exploreFolder`,`goToMod`])]),_:1}))}},GameplaySelector_default=_sfc_main$123,routes_default$6=[{name:`menu.gameplayselector`,path:`/gameplay-selector/:pathMatch(.*)*`,component:GameplaySelector_default,props:!0,meta:{clickThrough:!0,infoBar:{visible:!0,showSysInfo:!1},uiApps:{shown:!1},topBar:{visible:!0}}}],_hoisted_1$111={key:0,class:`garage-button-content`},_sfc_main$122={__name:`GarageButton`,props:{icon:[Object,String],externalIcon:String,disabled:Boolean,active:Boolean,type:{type:String,validator:val=>[`drawer-toggle`,`drawer-button`,``].includes(val)||val===void 0}},setup(__props){let props=__props,slots=useSlots(),hasContent=computed(()=>slots.default),showContent=computed(()=>hasContent.value&&!(props.type===`drawer-toggle`&&!props.active)),btnRef=ref(null);return onUpdated(()=>ensureFocus(btnRef.value?.getElement?.())),(_ctx,_cache)=>(openBlock(),createBlock(unref(bngButton_default),mergeProps({ref_key:`btnRef`,ref:btnRef,accent:unref(ACCENTS).custom,disabled:__props.disabled,icon:__props.icon,externalIcon:__props.externalIcon,class:[`garage-button`,{[`garage-button-${__props.type}`]:!!__props.type,"garage-button-with-content":hasContent.value,"garage-button-active":__props.active}]},_ctx.$attrs),{default:withCtx(()=>[showContent.value?(openBlock(),createElementBlock(`div`,_hoisted_1$111,[renderSlot(_ctx.$slots,`default`,{},void 0,!0)])):createCommentVNode(``,!0)]),_:3},16,[`accent`,`disabled`,`icon`,`externalIcon`,`class`]))}},GarageButton_default=__plugin_vue_export_helper_default(_sfc_main$122,[[`__scopeId`,`data-v-8b374028`]]),_hoisted_1$110={class:`paint-preview`},_hoisted_2$92=[`onClick`],_hoisted_3$80={key:0,class:`empty-slot-indicator`},refpad=25,_sfc_main$121={__name:`PaintPreview`,props:{paints:Array,paintNames:{type:Array,default:()=>[]}},emits:[`select`],setup(__props,{emit:__emit}){let props=__props,emit$1=__emit,previews=computed(()=>{let res=[];if(!props.paints||!Array.isArray(props.paints))return res;let paints=props.paints,len=paints.length;for(let idx=0;idx1?refpad+(100-refpad*2)/(len-1)*idx:50}%`,"--paint-color":isEmpty?`rgba(128, 128, 128, 0.3)`:`rgb(${paint.rgb255.join(`, `)})`,"--paint-metallic":isEmpty?0:Math.max(0,paint.metallic-paint.roughness/.5),"--paint-roughness":isEmpty?1:paint.roughness,"--paint-clearcoat":isEmpty?0:paint.clearcoat,"--paint-clearcoat-roughness":isEmpty?0:paint.clearcoatRoughness,isEmpty,tooltipText};res.push(vars)}return res});return(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$110,[(openBlock(!0),createElementBlock(Fragment,null,renderList(previews.value,(preview,idx)=>withDirectives((openBlock(),createElementBlock(`div`,{key:idx,class:normalizeClass([`paint-preview-item`,{"empty-slot":preview.isEmpty}]),style:normalizeStyle(preview),onClick:$event=>preview.isEmpty?null:emit$1(`select`,idx)},[_cache[0]||=createStaticVNode(`
    `,5),preview.isEmpty?(openBlock(),createElementBlock(`div`,_hoisted_3$80)):createCommentVNode(``,!0)],14,_hoisted_2$92)),[[unref(BngTooltip_default),preview.tooltipText,`bottom`]])),128))]))}},PaintPreview_default=__plugin_vue_export_helper_default(_sfc_main$121,[[`__scopeId`,`data-v-38e5e63f`]]),_hoisted_1$109={class:`paint-preview-container`},_hoisted_2$91={class:`multi-paint-setups-content`},_hoisted_3$79={key:0},colorDefault=`1 1 1 1 0 1 1 0`,previewAnimTime=400,_sfc_main$120={__name:`Paint`,props:{withBackground:Boolean,tabbed:{type:Boolean,default:!0},legacy:{type:Boolean,default:!0}},setup(__props){useUINavBlocker().blockOnly([`context`]);let paintPreviews=usePaintPreviews(),props=__props,events$3=useEvents(),configId=ref(`none`),vehiclePaintPresets=ref({}),multiPaintSetups=ref({}),tabsState=ref([!0,!1,!1]);function tabExpand(idx){for(let i=0;i{tabsState.value[idx]=!0})}let color=ref([colorDefault,colorDefault,colorDefault]),updateColor=(index,preview=!0)=>nextTick(()=>{Lua_default.core_vehicle_colors.setVehicleColor(index,color.value[index]),paints[index].paint=color.value[index],preview&&updatePaint(index)});function resetScroll(){let elm=document.activeElement.closest(`.bng-accitem-content`);elm&&(elm.scrollTop=0)}let paints=Array.from({length:color.value.length},()=>reactive(new Paint({legacy:props.legacy}))),paintImgs=ref(Array(color.value.length).fill(null)),previewStyles=ref(Array(color.value.length).fill(null).map(()=>({"--paint-url":`none`,"--paint-prev-url":`none`,"--paint-prev-transition":`none`,"--paint-prev-opacity":0}))),previewAnimating=Array(color.value.length).fill(0),updatePaintPreview=async(index,url)=>{if(previewAnimating[index]===1)for(previewAnimating[index]=-1;previewAnimating[index]===-1;)await sleep(50);if(previewAnimating[index]=1,previewStyles.value[index][`--paint-prev-transition`]=`none`,paintImgs.value[index]=url,previewAnimTime===0){if(previewAnimating[index]===-1)return previewAnimating[index]=0;previewStyles.value[index][`--paint-url`]=`url(${url})`,previewAnimating[index]=0;return}let currentUrl=previewStyles.value[index][`--paint-url`];if(currentUrl===`none`||!currentUrl){if(previewAnimating[index]===-1)return previewAnimating[index]=0;previewStyles.value[index][`--paint-url`]=`url(${url})`,previewAnimating[index]=0;return}previewStyles.value[index][`--paint-prev-url`]=currentUrl,previewStyles.value[index][`--paint-url`]=`url(${url})`,previewStyles.value[index][`--paint-prev-opacity`]=1,previewStyles.value[index][`--paint-prev-transition`]=`none`,requestAnimationFrame(()=>{if(previewAnimating[index]===-1)return previewAnimating[index]=0;previewStyles.value[index][`--paint-prev-transition`]=`opacity ${previewAnimTime}ms ease-in-out`,previewStyles.value[index][`--paint-prev-opacity`]=0,setTimeout(()=>{if(previewAnimating[index]===-1)return previewAnimating[index]=0;previewStyles.value[index][`--paint-prev-transition`]=`none`,previewAnimating[index]=0},previewAnimTime)})},updatePaint=debounce(async index=>{let paintData=color.value[index];paintPreviews.getBlobPreview(paintData,{paintId:`${configId.value}:single-${index}`,width:80,height:24}).then(url=>{url&&updatePaintPreview(index,url)}).catch(()=>{})},30),updateAllPaints=async()=>{let urls=await Promise.all(paints.map(async(paint,idx)=>await paintPreviews.getBlobPreview(paint.paint,{paintId:`${configId.value}:single-${idx}`,width:80,height:24})));for(let i=0;i{let res=[];for(let i=0;ivehiclePaintPresets.value[name]);res.push({id:paintNames.join(`|`),name:setup$3.name,paintNames,paints:paints$1,apply:idx=>applyMultipaint(setup$3,idx)})}return res});function applyMultipaint(setup$3,index=-1){console.log(`applyMultipaint`,index);let paintNames=[setup$3.paintName1,setup$3.paintName2,setup$3.paintName3];for(let i=0;i-1&&i!==index)continue;let paintName=paintNames[i];if(paintName&&paintName.trim()!==``&&vehiclePaintPresets.value[paintName]){let paintData=vehiclePaintPresets.value[paintName],paint=new Paint({legacy:props.legacy});paint.paint=paintData,color.value[i]=paint.paintString,updateColor(i,!1)}}nextTick(updateAllPaints)}async function fetchDefinedColors(){for(let i=0;i__props.tabbed?(openBlock(),createElementBlock(`div`,{key:0,class:normalizeClass([`paint-acc-wrapper`,{"with-background":__props.withBackground}])},[createBaseVNode(`div`,_hoisted_1$109,[createVNode(PaintPreview_default,{paints:unref(paints),onSelect:tabExpand},null,8,[`paints`])]),withDirectives((openBlock(),createBlock(unref(accordion_default),{class:`paint-acc-container`,singular:``},{default:withCtx(()=>[createVNode(unref(accordionItem_default),{key:`multi-paint-setups`,class:`paint-acc-content`,navigable:``},{caption:withCtx(()=>[..._cache[0]||=[createTextVNode(` Multi Paint Setups `,-1)]]),default:withCtx(()=>[createBaseVNode(`div`,_hoisted_2$91,[(openBlock(!0),createElementBlock(Fragment,null,renderList(multipaint.value,paint=>(openBlock(),createBlock(unref(bngPaintTile_default),{key:paint.name,class:`multi-paint-setup-item`,"paint-id":`${configId.value}:${paint.id}`,paint:paint.paints,"paint-name":paint.name,"paint-names":paint.paintNames,width:72,height:24,"with-menu":``,onClick:paint.apply,onMenuClick:paint.apply},null,8,[`paint-id`,`paint`,`paint-name`,`paint-names`,`onClick`,`onMenuClick`]))),128))])]),_:1}),(openBlock(!0),createElementBlock(Fragment,null,renderList(color.value.length,idx=>(openBlock(),createBlock(unref(accordionItem_default),{key:idx,class:`paint-acc-content`,navigable:``,expanded:tabsState.value[idx-1],style:normalizeStyle(previewStyles.value[idx-1])},{caption:withCtx(()=>[createTextVNode(toDisplayString(_ctx.$t(`ui.trackBuilder.matEditor.paint`)+` `+idx),1)]),default:withCtx(()=>[withDirectives((openBlock(),createElementBlock(`div`,{class:`paint-picker-wrapper`,onDeactivate:resetScroll},[createVNode(PaintPicker_default,{class:`paint-picker`,"picker-mode":`compact_luminosity`,modelValue:color.value[idx-1],"onUpdate:modelValue":$event=>color.value[idx-1]=$event,onChange:$event=>updateColor(idx-1),"show-preview":!1,"presets-editable":``,presets:vehiclePaintPresets.value,legacy:__props.legacy},null,8,[`modelValue`,`onUpdate:modelValue`,`onChange`,`presets`,`legacy`])],32)),[[unref(BngScopedNav_default),{bubbleWhitelistEvents:[`menu`]}]])]),_:2},1032,[`expanded`,`style`]))),128))]),_:1})),[[unref(BngBlur_default),__props.withBackground]])],2)):withDirectives((openBlock(),createElementBlock(`div`,{key:1,class:normalizeClass([`paint-container`,{"with-background":__props.withBackground}])},[(openBlock(!0),createElementBlock(Fragment,null,renderList(color.value.length,idx=>(openBlock(),createBlock(PaintPicker_default,{key:idx,modelValue:color.value[idx-1],"onUpdate:modelValue":$event=>color.value[idx-1]=$event,onChange:$event=>updateColor(idx-1),"show-preview":!1,"presets-editable":``,presets:vehiclePaintPresets.value,legacy:__props.legacy},{default:withCtx(()=>[createTextVNode(toDisplayString(_ctx.$t(`ui.trackBuilder.matEditor.paint`))+` `+toDisplayString(idx),1)]),_:2},1032,[`modelValue`,`onUpdate:modelValue`,`onChange`,`presets`,`legacy`]))),128)),color.value.length%2==1?(openBlock(),createElementBlock(`div`,_hoisted_3$79)):createCommentVNode(``,!0)],2)),[[unref(BngBlur_default),__props.withBackground]])}},Paint_default=__plugin_vue_export_helper_default(_sfc_main$120,[[`__scopeId`,`data-v-956741b3`]]),rgxWheel=/^(\d+(?:\.\d+)?)(x)(\d+(?:\.\d+)?)/i,rgxTire=/^(\d+(?:\.\d+)?)(\/)(\d+(?:\.\d+)?)(R)(\d+(?:\.\d+)?)/i,rgxNum=/(^| )(\d+)($| )/,zeroPad=num=>String(~~(num*1e3)).padStart(10,`0`);function partOptionSorter(...ab){let cmp=[``,``];for(let i=0;i<2;i++){let label=ab[i].label;if(typeof label!=`string`)return 0;rgxWheel.test(label)?cmp[i]=label.replace(rgxWheel,(_,a$1,s,b)=>[a$1,b].map(zeroPad).join(`x`)):rgxTire.test(label)?cmp[i]=label.replace(rgxTire,(_,a$1,s1,b,s2,c)=>[a$1,b,c].map(zeroPad).join(`x`)):rgxNum.test(label)?cmp[i]=label.replace(rgxNum,(_,a$1,num,b)=>a$1+zeroPad(num)+b):cmp[i]=label,label.startsWith(`40x4`)&&console.log(cmp[i])}return cmp[0].localeCompare(cmp[1])}function partOptionGrouper(list){let seq=[],groups={},grouping=!1;for(let itm of list){let group,match=itm.label.match(rgxWheel)||itm.label.match(rgxTire);group=match&&match.length>0?match.slice(1).map(s=>s===`R`?s:s+` `).join(``).trim():itm.label,groups[group]?grouping=!0:(groups[group]=[],seq.push(group)),groups[group].push(itm)}if(!grouping)return list;let res=[];for(let group of seq){let list$1=groups[group];list$1.length===1?res.push(...list$1):(res.push({label:group,group:!0}),res.push(...list$1.map(itm=>({...itm,grouped:!0}))))}return res}var _hoisted_1$108={key:1},_sfc_main$119={__name:`PartsBranch`,props:{rootSlot:Boolean,children:Object,child:Object,info:Object,treeState:Object,treeStateKey:String,flatEntry:Boolean,displayNames:Boolean,showAuxiliary:Boolean,separateSort:Boolean,alwaysSort:Boolean,showEmpty:Boolean,highlighter:[String,Array,RegExp]},emits:[`select`,`deselect`,`highlight`,`change`,`dropdown`],setup(__props,{emit:__emit}){let props=__props,accordionItem=ref(),partsDropdown=ref(),openPartsDropdown=()=>partsDropdown.value&&partsDropdown.value.open(),emit$1=__emit,select=(slot,mouse=!1)=>(!props.child||highlightable.value)&&emit$1(`select`,slot,mouse),deselect=(slot,mouse=!1)=>emit$1(`deselect`,slot,mouse),highlight=slot=>emit$1(`highlight`,slot),change=slot=>emit$1(`change`,slot),dropdown=val=>emit$1(`dropdown`,val),focusReturn=()=>nextTick(()=>accordionItem.value.focus()),accItemUnwatch=watch(accordionItem,()=>{let elm=accordionItem.value?.captionElement;elm&&(accItemUnwatch(),elm.partSelect=()=>props.child&&select(props.child))});function toggleHighlight(slot){slot.highlight=!slot.highlight,highlight(slot)}let toggleHighlightCurrent=()=>toggleHighlight(props.child),highlightable=computed(()=>typeof props.child?.highlight==`boolean`),expanded=ref(!1);if(!props.flatEntry){let unwatchTreeState;unwatchTreeState=watch(()=>props.treeState,()=>setTimeout(()=>{unwatchTreeState(),expanded.value=props.treeStateKey&&props.treeState[props.treeStateKey]&&props.treeState[props.treeStateKey]||!1,watch(()=>expanded.value,val=>{props.treeStateKey&&(val?props.treeState[props.treeStateKey]=val:props.treeStateKey in props.treeState&&delete props.treeState[props.treeStateKey])})},50),{immediate:!0})}let childrenSorter=(a$1,b)=>{if(props.separateSort){if(a$1.children&&!b.children)return 1;if(b.children&&!a$1.children)return-1}if(props.displayNames||!props.alwaysSort)return a$1.slotName.localeCompare(b.slotName);{let info=props.info[a$1.parentSlotName]?.slotInfoUi||{};return getSlotName(a$1,info).localeCompare(getSlotName(b,info))}},slotInfo=computed(()=>props.displayNames?{}:props.info[props.child?.parentSlotName]?.slotInfoUi||{}),isCoreSlot=computed(()=>!!props.info[props.child?.parentSlotName]?.slotInfoUi?.[props.child?.slotName]?.coreSlot),getSlotName=(slot,info={})=>props.displayNames?slot.slotName:info[slot.slotName]?.description||slot.slotName,displayName=computed(()=>getSlotName(props.child,slotInfo.value)),hasPartList=computed(()=>{let list=props.child?.suitablePartNames||[];return list.length===0&&(list=props.child?.chosenPartName?[props.child.chosenPartName]:(props.child?.unsuitablePartNames||[]).map(({partName})=>partName)),props.showAuxiliary||(list=list.filter(partName=>!props.info[partName]?.isAuxiliary)),list.length>0}),partsList=computed(()=>{if(!hasPartList.value)return[];let addEmpty=!0,list=props.child?.suitablePartNames||[];list.length===0&&props.child?.chosenPartName&&(list=[props.child.chosenPartName],addEmpty=!1);let unsuitable=(props.child?.unsuitablePartNames||[]).reduce((res,{partName,reason})=>({...res,[partName]:reason}),{});return list.push(...Object.keys(unsuitable)),list.length===0||(list=list.map(partName=>({value:partName,label:(props.info[partName]?.isAuxiliary?`[!] `:``)+(props.displayNames?partName:props.info[partName]?.description||partName),disabled:partName in unsuitable,tooltip:partName in unsuitable?{text:unsuitable[partName],position:`right`}:void 0,isAuxiliary:props.info[partName]?.isAuxiliary})).filter(opt=>!opt.isAuxiliary||props.showAuxiliary||props.child?.chosenPartName===opt.value),!props.showAuxiliary&&list.length===1&&list[0].isAuxiliary&&isCoreSlot.value)?[]:(list.sort(partOptionSorter),list=partOptionGrouper(list),addEmpty&&!isCoreSlot.value&&list.unshift({value:``,label:`Empty`}),list)}),parentAllChildren=computed(()=>props.children?Object.values(props.children||{}):[]),parentHasChildren=computed(()=>parentAllChildren.value.length>0),parentChildren=computed(()=>[...parentAllChildren.value].sort(childrenSorter)),childAllChildren=computed(()=>props.child?.children?Object.values(props.child.children||{}):[]),childHasChildren=computed(()=>childAllChildren.value.length>0),childChildren=computed(()=>[...childAllChildren.value].sort(childrenSorter)),shouldShow=computed(()=>childHasChildren.value||hasPartList.value||props.showEmpty);return(_ctx,_cache)=>__props.treeState&&parentHasChildren.value?(openBlock(),createBlock(unref(accordion_default),{key:0,class:`branch-category`},{default:withCtx(()=>[(openBlock(!0),createElementBlock(Fragment,null,renderList(parentChildren.value,child=>(openBlock(),createBlock(PartsBranch_default,{key:child.slotName,"root-slot":__props.rootSlot,child,info:__props.info,"tree-state":__props.treeState,"tree-state-key":child.slotName,"display-names":__props.displayNames,"show-auxiliary":__props.showAuxiliary,"separate-sort":__props.separateSort,"always-sort":__props.alwaysSort,"show-empty":__props.showEmpty,"flat-entry":__props.flatEntry,highlighter:__props.highlighter,onSelect:select,onDeselect:deselect,onHighlight:highlight,onChange:change,onDropdown:dropdown},null,8,[`root-slot`,`child`,`info`,`tree-state`,`tree-state-key`,`display-names`,`show-auxiliary`,`separate-sort`,`always-sort`,`show-empty`,`flat-entry`,`highlighter`]))),128))]),_:1})):__props.treeState&&shouldShow.value?(openBlock(),createBlock(unref(accordionItem_default),{key:1,ref_key:`accordionItem`,ref:accordionItem,static:__props.flatEntry||!childHasChildren.value,expanded:expanded.value,onExpanded:_cache[6]||=$event=>expanded.value=$event,class:normalizeClass({"item-changed":__props.child.changed}),"arrow-big":``,navigable:``,onMouseover:_cache[7]||=withModifiers($event=>select(__props.child,!0),[`stop`]),onMouseleave:_cache[8]||=withModifiers($event=>deselect(__props.child,!0),[`stop`]),onFocusin:_cache[9]||=withModifiers($event=>select(__props.child,!1),[`stop`]),onFocusout:_cache[10]||=withModifiers($event=>deselect(__props.child,!1),[`stop`]),"primary-action":partsList.value.length>0?openPartsDropdown:void 0,"secondary-action":highlightable.value?toggleHighlightCurrent:void 0,"primary-label":`ui.inputActions.menu.menu_item_select.title`,"secondary-label":`ui.vehicleconfig.highlight`,"expand-hint-inline":``,"secondary-hint-inline":``},{caption:withCtx(()=>[withDirectives((openBlock(),createElementBlock(`span`,null,[createTextVNode(toDisplayString(displayName.value),1)])),[[unref(BngHighlighter_default),__props.highlighter]])]),controls:withCtx(()=>[createVNode(unref(bngDropdown_default),{ref_key:`partsDropdown`,ref:partsDropdown,modelValue:__props.child.chosenPartName,"onUpdate:modelValue":_cache[0]||=$event=>__props.child.chosenPartName=$event,items:partsList.value,disabled:!hasPartList.value,highlight:__props.highlighter,"show-search":partsList.value.length>5,"long-names":`cut`,onValueChanged:_cache[1]||=$event=>change(__props.child),onFocus:focusReturn,onOpen:_cache[2]||=$event=>dropdown(!0),onClose:_cache[3]||=$event=>dropdown(!1),"bng-no-nav":``},null,8,[`modelValue`,`items`,`disabled`,`highlight`,`show-search`]),createVNode(unref(bngButton_default),{accent:unref(ACCENTS).text,class:normalizeClass({"visibility-toggle":!0,"visibility-toggle-on":__props.child.highlight}),icon:__props.child.highlight?unref(icons).eyeSolidOpened:unref(icons).eyeSolidClosed,disabled:!highlightable.value,onClick:_cache[4]||=$event=>toggleHighlight(__props.child),onFocus:_cache[5]||=$event=>accordionItem.value.focus(),"bng-no-nav":``},null,8,[`accent`,`class`,`icon`,`disabled`])]),default:withCtx(()=>[!__props.flatEntry&&__props.treeState&&childHasChildren.value?(openBlock(),createBlock(PartsBranch_default,{key:0,children:childChildren.value,info:__props.info,"tree-state":__props.treeState,"display-names":__props.displayNames,"show-auxiliary":__props.showAuxiliary,"separate-sort":__props.separateSort,"always-sort":__props.alwaysSort,"show-empty":__props.showEmpty,highlighter:__props.highlighter,onSelect:select,onDeselect:deselect,onHighlight:highlight,onChange:change,onDropdown:dropdown},null,8,[`children`,`info`,`tree-state`,`display-names`,`show-auxiliary`,`separate-sort`,`always-sort`,`show-empty`,`highlighter`])):!__props.flatEntry&&__props.treeState?(openBlock(),createElementBlock(`div`,_hoisted_1$108,`—`)):createCommentVNode(``,!0)]),_:1},8,[`static`,`expanded`,`class`,`primary-action`,`secondary-action`])):createCommentVNode(``,!0)}},PartsBranch_default=__plugin_vue_export_helper_default(_sfc_main$119,[[`__scopeId`,`data-v-a5433800`]]),SearchHistory=class{list=[];index=-1;browsing=!1;saveKey=`partSearchHistory`;constructor(search$1){this.search=search$1,this.load()}load(){let res=localStorage.getItem(this.saveKey);res&&(this.list=JSON.parse(res)||[])}save(){localStorage.setItem(this.saveKey,JSON.stringify(this.list))}update(){if(this.search.query.length===0)return;let text=(isRef(this.search.text)?this.search.text.value:this.search.text).trim().replace(/ +/g,` `),textLC=text.toLowerCase(),idx=this.list.findIndex(txt=>textLC===txt.toLowerCase());if(idx>-1){this.index=idx;return}idx=this.list.findIndex(txt=>txt.toLowerCase().startsWith(textLC)),!(idx>-1)&&(idx=this.list.findIndex(txt=>textLC.startsWith(txt.toLowerCase())),idx>-1?(this.list[idx]=text,this.index=idx):(this.index=this.list.length,this.list.push(text)),this.save())}onKeyDown(event){if(this.list.length!==0){switch(event.key){case`ArrowUp`:this.browsing=!0,this.index--;break;case`ArrowDown`:this.browsing=!0,this.index++;break;case`k`:if(event.ctrlKey)console.log(`Search history cleaned`),localStorage.removeItem(`partSearchHistory`),this.list=[],this.index=0,event.preventDefault();else return;default:event.ctrlKey||(this.browsing=!1);return}this.browsing&&(this.index=Math.abs(this.index+this.list.length)%this.list.length,this.search.text=this.list[this.index]),event.preventDefault()}}},isOfficial=info=>info.authors!==`BeamNG`,PartsSearch=class{active=!1;text=ref(``);query={};message=ref(``);highlight=ref([]);minText=3;history=null;currentConfig=[];richPartInfo=[];opts={};constructor(currentConfig,richPartInfo,opts=null){if(!isRef(currentConfig))throw Error(`currentConfig must be ref`);if(!isRef(richPartInfo))throw Error(`richPartInfo must be ref`);this.currentConfig=currentConfig,this.richPartInfo=richPartInfo,opts&&(this.opts=opts),this.history=new SearchHistory(this),this.result=computed(()=>this.generateResult()),this.messages={noResults:$translate.instant(`ui.common.search.noResults`),tooShort:$translate.instant(`ui.common.search.queryTooShort`),invalidFormat:$translate.instant(`ui.common.search.invalidFormat`),unknownArgument:$translate.instant(`ui.common.search.unknownArgument`)}}generateResult(){let queryArgs=this.parseQuery(isRef(this.text)?this.text.value:this.text);if(this.query=queryArgs,this.highlight.value=queryArgs.highlight,!queryArgs.good)return this.message.value=queryArgs.reason,{};this.message.value=``;let res={},currentConfig=isRef(this.currentConfig)?this.currentConfig.value:this.currentConfig,cnt=0,dive=node=>{if(node.children)for(let child of Object.values(node.children)){let match=this.matchSlot(child);match.matched&&(child.search=match,res[child.slotName+`?`+ ++cnt]=child),dive(child)}};return dive(currentConfig),Object.keys(res).length>0?this.history.update():this.message.value=this.messages.noResults,res}parseQuery(text){let queryString=text.trim().toLowerCase().replace(/ +/g,` `),queryArgs={mode:`or`,reason:``,highlight:[]},ignoreKeys=Object.keys(queryArgs);if(queryString.length-1){let args2=arg.split(/:/);args2.length===2&&args2[1].trim()!==``?(queryArgs[args2[0]]=args2[1],parsedargs++):queryArgs.reason+=this.messages.invalidFormat+`: ${arg}\n`}else queryArgs.reason+=this.messages.unknownArgument+`: ${arg}\n`;parsedargs>1&&(queryArgs.mode=`and`)}return queryArgs.good=!queryArgs.reason,queryArgs.highlight=queryArgs.good?Object.entries(queryArgs).filter(([key])=>!ignoreKeys.includes(key)).map(([_,value])=>value):[],queryArgs}matchSlot(slot){let opts=this.opts,query=this.query,queryMode={or:(a$1,b)=>a$1||b,and:(a$1,b)=>a$1&&b}[query.mode],queryOr=query.mode===`or`,matched=!queryOr,matchDetails={slot:!1,part:!1,mod:!1},info=isRef(this.richPartInfo)?this.richPartInfo.value:this.richPartInfo,match=(string,query$1)=>matched=queryMode(matched,(string?string.toLowerCase():`empty`).indexOf(query$1)>-1);function*pairs(){query.name&&(yield[`slot`,slot.chosenPartName,query.name]),query.slot&&(yield[`slot`,slot.slotName,query.slot]),query.description&&(yield[`slot`,(slot.parentSlotName&&info[slot.parentSlotName]?.slotInfoUi?.[slot.slotName]||{}).description,query.description]);let part=slot.chosenPartName?info[slot.chosenPartName]:null;if(part?(query.description&&(yield[`slot`,part.description,query.description]),query.author&&(yield[`slot`,part.authors,query.author,!isOfficial(part)]),query.mod&&!isOfficial(part)&&(yield[`slot`,part.description,query.mod,!0])):query.description&&(yield[`slot`,null,query.description]),query.partname||query.description||query.mod||query.author)for(let partNames of[slot.suitablePartNames,slot.unsuitablePartNames.map(({partName})=>partName)])for(let partName of partNames){let part$1=info[partName];!part$1||!opts.showAux&&part$1.isAuxiliary||(query.partname&&(yield[`part`,partName,query.partname]),query.description&&(yield[`part`,part$1.description,query.description]),query.author&&(yield[`part`,part$1.authors,query.author,!isOfficial(part$1)]),query.mod&&part$1&&!isOfficial(part$1)&&(yield[`part`,part$1.description,query.mod,!0]))}}let lastType;for(let[type,string,query$1,isMod=!1]of pairs()){if(query$1&&match(string,query$1)&&(queryOr||lastType!==type)){matchDetails[type]=!0,isMod&&(matchDetails.mod=!0);break}lastType=type}return{matched,matchedSlot:matchDetails.slot,matchedOptions:matchDetails.part,matchedMod:matchDetails.mod}}onChange(){let text=isRef(this.text)?this.text.value:this.text;!this.active&&text&&this.start()}start(){this.active=!0}stop(){this.active=!1,isRef(this.text)?this.text.value=``:this.text=``,this.query={},this.history.index=-1}},_hoisted_1$107={class:`parts-browser-content`},_hoisted_2$90={key:1},_hoisted_3$78={style:{padding:`0.5em`,display:`inline-block`}},_hoisted_4$60={class:`search-help`},_hoisted_5$50={key:0},_hoisted_6$37={class:`parts-options-row parts-options-row-separator`},_hoisted_7$31={class:`parts-options-left`},_hoisted_8$24={class:`popover-contents-wrapper`},_hoisted_9$21={class:`parts-options-right`},_hoisted_10$15={class:`parts-options-row`},_hoisted_11$13={class:`license-plate`},_hoisted_12$9={class:`parts-options-right parts-options-buttons`},treeStateKey=`partsTreeState`,_sfc_main$118={__name:`Parts`,props:{withBackground:Boolean},setup(__props){let events$3=useEvents(),queue$2=new ExecQueue,currentVehID=-1,currentConfig=ref({}),richPartInfo=ref({}),partsHighlighted={},treeState=ref({}),isDev=window.beamng&&!window.beamng.shipping,savedOptions=[`applyPartChangesAutomatically`,`selectSubParts`,`showNames`,`showAux`,`separateSort`,`alwaysSort`],opts=reactive({stickyPartSelection:!1,selectSubParts:!0,applyPartChangesAutomatically:!0,simple:!1,showNames:!1,showAux:!beamng.shipping,separateSort:!1,alwaysSort:!1,showEmpty:!1}),waitingForData=ref(!0),waitForData=async()=>{for(;waitingForData.value;)await sleep(100)},search$1=reactive(new PartsSearch(currentConfig,richPartInfo,opts)),partsChanged=ref(!1),vehChange=()=>Lua_default.extensions.core_vehicle_partmgmt.sendDataToUI();events$3.on(`VehicleFocusChanged`,vehChange),events$3.on(`VehicleJbeamIoChanged`,vehChange);function iterateChildren(slot,func){func(slot),slot.children&&Object.values(slot.children).forEach(child=>iterateChildren(child,func))}async function highlightPart(part){waitingForData.value||(iterateChildren(part,child=>typeof child.highlight==`boolean`?partsHighlighted[child.partPath]=child.highlight=part.highlight:void 0),Lua_default.extensions.core_vehicle_partmgmt.highlightParts(partsHighlighted,currentVehID))}let mouseUsedLast=!0,tmrSelect,selectPart=queue$2.wrap(`selectPart`,async(slot,mouse=!1)=>{if(mouseUsedLast=mouse,tmrSelect&&clearTimeout(tmrSelect),waitingForData.value||opts.stickyPartSelection)return;let parts={};for(let part in opts.selectSubParts?iterateChildren(slot,child=>child.partPath&&(parts[child.partPath]=!0)):parts[slot.partPath]=!0,parts)part in partsHighlighted||delete parts[part];Object.keys(parts).length!==0&&await Lua_default.extensions.core_vehicle_partmgmt.selectParts(parts,currentVehID)},{selectPart:queue$2.resolution.replaceWithResolve,deselectPart:queue$2.resolution.resolveOthers,write:queue$2.resolution.resolveThis,reset:queue$2.resolution.resolveThis,resetAllToLoadedConfig:queue$2.resolution.resolveThis,restoreHighlight:queue$2.resolution.resolveThis}),deselectPart=queue$2.wrap(`deselectPart`,(slot,mouse=!1)=>{mouseUsedLast=mouse,tmrSelect&&clearTimeout(tmrSelect),!waitingForData.value&&(tmrSelect=setTimeout(async()=>{tmrSelect=null,!(opts.stickyPartSelection||Object.keys(currentConfig.value).length===0)&&await Lua_default.extensions.core_vehicle_partmgmt.showHighlightedParts(currentVehID)},100))},{deselectPart:queue$2.resolution.replaceWithResolve,write:queue$2.resolution.resolveThis,reset:queue$2.resolution.resolveThis,resetAllToLoadedConfig:queue$2.resolution.resolveThis,restoreHighlight:queue$2.resolution.resolveThis,restoreSelection:queue$2.resolution.resolveThis}),restoreHighlight=queue$2.wrap(`restoreHighlight`,()=>{tmrSelect&&clearTimeout(tmrSelect),tmrSelect=setTimeout(async()=>{tmrSelect=null,await Lua_default.extensions.core_vehicle_partmgmt.highlightParts(partsHighlighted,currentVehID)},100)},{selectPart:queue$2.resolution.replaceWithResolve,deselectPart:queue$2.resolution.replaceWithResolve,restoreHighlight:queue$2.resolution.replaceWithResolve}),restoreSelection=queue$2.wrap(`restoreSelection`,element=>{element?.partSelect?.()},{selectPart:queue$2.resolution.replaceWithResolve,deselectPart:queue$2.resolution.replaceWithResolve,restoreSelection:queue$2.resolution.replaceWithResolve}),dropdownOpened=val=>opts.stickyPartSelection=val,skipLicGen=ref(!1),licensePlate=ref(``),licensePlateTextValid=ref(!0),settingsChanged=async()=>skipLicGen.value=await Lua_default.settings.getValue(`SkipGenerateLicencePlate`),getLicensePlate=()=>bngApi.engineLua(`core_vehicles.getVehicleLicenseText(getPlayerVehicle(0))`,str=>licensePlate.value=str),applyLicensePlateDebounced=debounce(()=>{opts.applyPartChangesAutomatically&&applyLicensePlate()},500);function applyLicensePlate(){applyLicensePlateDebounced.cancel(),licensePlateTextValid.value&&Lua_default.core_vehicles.setPlateText(licensePlate.value)}function applyRandomLicensePlate(){bngApi.engineLua(`core_vehicles.setPlateText(core_vehicles.regenerateVehicleLicenseText(getPlayerVehicle(0)),nil,nil,nil)`),getLicensePlate()}let isLicensePlateTextValid=text=>(Lua_default.core_vehicles.isLicensePlateValid(text).then(valid=>{licensePlateTextValid.value=valid}),licensePlateTextValid.value),changedPart=null;async function partConfigChanged(part){changedPart=part,opts.applyPartChangesAutomatically?await write():(part.changed=!0,partsChanged.value=!0)}let write=queue$2.wrap(`write`,async()=>{waitingForData.value=!0,await Lua_default.extensions.core_vehicle_partmgmt.setPartsTreeConfig(currentConfig.value),await waitForData()},{write:queue$2.resolution.merge,reset:queue$2.resolution.resolveThis,resetAllToLoadedConfig:queue$2.resolution.resolveThis});queue$2.wrap(`reset`,async()=>{waitingForData.value=!0,await Lua_default.extensions.core_vehicle_partmgmt.resetPartsToLoadedConfig(),await waitForData()},{write:queue$2.resolution.resolveThis,reset:queue$2.resolution.merge,resetAllToLoadedConfig:queue$2.resolution.resolveThis});let resetAllToLoadedConfig=queue$2.wrap(`resetAllToLoadedConfig`,async()=>{waitingForData.value=!0,await Lua_default.extensions.core_vehicle_partmgmt.resetAllToLoadedConfig(),await waitForData()},{write:queue$2.resolution.resolveThis,reset:queue$2.resolution.resolveThis,resetAllToLoadedConfig:queue$2.resolution.merge});function processConfig(config){treeStateSave(),waitingForData.value=!0,richPartInfo.value=Object.fromEntries(Object.entries(config.richPartInfo).map(([name,info])=>[name,info.information])),partsHighlighted=config.partsHighlighted;let processSlot=(slot,slotName,parentSlotName=void 0)=>{if(slot.slotName=slotName,slot.parentSlotName=parentSlotName,changedPart&&changedPart.chosenPartName===slot.chosenPartName&&(changedPart=slot),slot.highlight=config.partsHighlighted[slot.partPath],typeof slot.children==`object`)if(Object.keys(slot.children).length===0)delete slot.children;else for(let childSlotName in slot.children)slot.children[childSlotName]=processSlot(slot.children[childSlotName],childSlotName,slot.chosenPartName);return(typeof slot.suitablePartNames!=`object`||!Array.isArray(slot.suitablePartNames))&&(slot.suitablePartNames=[]),(typeof slot.unsuitablePartNames!=`object`||!Array.isArray(slot.unsuitablePartNames))&&(slot.unsuitablePartNames=[]),slot};currentVehID=config.vehID,currentConfig.value=processSlot(config.chosenPartsTree,config.chosenPartsTree.chosenPartName),partsChanged.value=!1,waitingForData.value=!1,nextTick(()=>{opts.stickyPartSelection=!1,deselectPart(),treeStateLoad(),changedPart=null,opts.applyPartChangesAutomatically&&!mouseUsedLast?restoreSelection(document.activeElement):restoreHighlight()})}events$3.on(`VehicleConfigChange`,processConfig);let readOption=(name,val=null)=>JSON.parse(localStorage.getItem(name)||JSON.stringify(val)),saveOption=(name,val)=>localStorage.setItem(name,JSON.stringify(val)),treeStateStorage=sessionStorage,treeStateSave=()=>currentConfig.value.chosenPartName&&treeStateStorage.setItem(`${treeStateKey}_${currentConfig.value.chosenPartName}`,JSON.stringify(treeState.value)),treeStateLoad=()=>{if(!currentConfig.value.chosenPartName)return;let state=treeStateStorage.getItem(`${treeStateKey}_${currentConfig.value.chosenPartName}`);if(state)try{treeState.value=JSON.parse(state)}catch{treeState.value={}}else treeState.value={}};return onMounted(()=>{settingsChanged(),getLicensePlate(),Lua_default.extensions.core_vehicle_partmgmt.sendDataToUI();for(let name of savedOptions)opts[name]=readOption(name,opts[name])}),onUnmounted(()=>{treeStateSave(),deselectPart(!1)}),(_ctx,_cache)=>withDirectives((openBlock(),createElementBlock(`div`,{class:normalizeClass({"parts-browser":!0,"with-background":__props.withBackground})},[withDirectives((openBlock(),createElementBlock(`div`,{class:`parts-browser-search`,onActivate:_cache[5]||=(...args)=>search$1.start&&search$1.start(...args),onDeactivate:_cache[6]||=()=>!search$1.text&&search$1.stop()},[createVNode(unref(bngInput_default),{modelValue:search$1.text,"onUpdate:modelValue":_cache[0]||=$event=>search$1.text=$event,modelModifiers:{trim:!0},"leading-icon":unref(icons).search,"floating-label":`Search`,onClick:_cache[1]||=$event=>search$1.start(),onValueChanged:_cache[2]||=$event=>search$1.onChange(),onKeydown:_cache[3]||=$event=>search$1.history.onKeyDown($event)},null,8,[`modelValue`,`leading-icon`]),withDirectives(createVNode(unref(bngButton_default),{icon:unref(icons).mathMultiply,style:`font-size: 0.75rem`,accent:unref(ACCENTS).text,onClick:_cache[4]||=$event=>search$1.stop()},null,8,[`icon`,`accent`]),[[unref(BngDisabled_default),!search$1.active]])],32)),[[unref(BngScopedNav_default),{bubbleWhitelistEvents:[`menu`]}]]),withDirectives((openBlock(),createElementBlock(`div`,{class:`parts-browser-content-wrapper`,onMouseleave:_cache[7]||=(...args)=>unref(deselectPart)&&unref(deselectPart)(...args),onDeactivate:_cache[8]||=(...args)=>unref(deselectPart)&&unref(deselectPart)(...args)},[createBaseVNode(`div`,_hoisted_1$107,[!search$1.active&¤tConfig.value?.children&&Object.keys(currentConfig.value.children).length>0?(openBlock(),createBlock(PartsBranch_default,{key:0,"root-slot":``,children:currentConfig.value.children,info:richPartInfo.value,"tree-state":treeState.value,"display-names":opts.showNames,"show-auxiliary":opts.showAux,"separate-sort":opts.separateSort,"always-sort":opts.alwaysSort,"show-empty":opts.showEmpty,onSelect:unref(selectPart),onDeselect:unref(deselectPart),onHighlight:highlightPart,onChange:partConfigChanged,onDropdown:dropdownOpened},null,8,[`children`,`info`,`tree-state`,`display-names`,`show-auxiliary`,`separate-sort`,`always-sort`,`show-empty`,`onSelect`,`onDeselect`])):search$1.active?(openBlock(),createElementBlock(`div`,_hoisted_2$90,[createVNode(PartsBranch_default,{children:search$1.result,info:richPartInfo.value,"tree-state":treeState.value,"flat-entry":``,"display-names":opts.showNames,"show-auxiliary":opts.showAux,"separate-sort":opts.separateSort,"always-sort":opts.alwaysSort,"show-empty":opts.showEmpty,highlighter:search$1.highlight,onSelect:unref(selectPart),onDeselect:unref(deselectPart),onHighlight:highlightPart,onChange:partConfigChanged,onDropdown:dropdownOpened},null,8,[`children`,`info`,`tree-state`,`display-names`,`show-auxiliary`,`separate-sort`,`always-sort`,`show-empty`,`highlighter`,`onSelect`,`onDeselect`]),withDirectives(createBaseVNode(`div`,null,[createVNode(unref(bngIcon_default),{type:unref(icons).danger,color:`#d60`},null,8,[`type`]),createBaseVNode(`span`,_hoisted_3$78,toDisplayString(search$1.message),1)],512),[[vShow,search$1.message!==``]]),withDirectives(createBaseVNode(`div`,_hoisted_4$60,[_cache[37]||=createBaseVNode(`hr`,null,null,-1),_cache[38]||=createTextVNode(` Examples: `,-1),createBaseVNode(`ul`,null,[createBaseVNode(`li`,null,[_cache[23]||=createBaseVNode(`span`,{class:`search-example`},`left`,-1),_cache[24]||=createBaseVNode(`br`,null,null,-1),createTextVNode(` `+toDisplayString(_ctx.$t(`ui.vehicleconfig.searchHelp.example1`)),1)]),createBaseVNode(`li`,null,[_cache[25]||=createBaseVNode(`span`,{class:`search-example`},`slot:_fr`,-1),_cache[26]||=createBaseVNode(`br`,null,null,-1),createTextVNode(` `+toDisplayString(_ctx.$t(`ui.vehicleconfig.searchHelp.example2`)),1)]),createBaseVNode(`li`,null,[_cache[27]||=createBaseVNode(`span`,{class:`search-example`},`name:frame`,-1),_cache[28]||=createBaseVNode(`br`,null,null,-1),createTextVNode(` `+toDisplayString(_ctx.$t(`ui.vehicleconfig.searchHelp.example3`)),1)]),createBaseVNode(`li`,null,[_cache[29]||=createBaseVNode(`span`,{class:`search-example`},`slot:_fr name:signal`,-1),_cache[30]||=createBaseVNode(`br`,null,null,-1),createTextVNode(` `+toDisplayString(_ctx.$t(`ui.vehicleconfig.searchHelp.example4`)),1)]),createBaseVNode(`li`,null,[_cache[31]||=createBaseVNode(`span`,{class:`search-example`},`partname:pickup_fr`,-1),_cache[32]||=createBaseVNode(`br`,null,null,-1),createTextVNode(` `+toDisplayString(_ctx.$t(`ui.vehicleconfig.searchHelp.example5`)),1)]),createBaseVNode(`li`,null,[_cache[33]||=createBaseVNode(`span`,{class:`search-example`},`author:bob`,-1),_cache[34]||=createBaseVNode(`br`,null,null,-1),createTextVNode(` `+toDisplayString(_ctx.$t(`ui.vehicleconfig.searchHelp.example6`)),1)]),createBaseVNode(`li`,null,[_cache[35]||=createBaseVNode(`span`,{class:`search-example`},`mod:super`,-1),_cache[36]||=createBaseVNode(`br`,null,null,-1),createTextVNode(` `+toDisplayString(_ctx.$t(`ui.vehicleconfig.searchHelp.example7`)),1)])]),_cache[39]||=createBaseVNode(`hr`,null,null,-1),createTextVNode(` `+toDisplayString(_ctx.$t(`ui.vehicleconfig.searchHelp.notes`))+`: `,1),createBaseVNode(`ul`,null,[createBaseVNode(`li`,null,toDisplayString(_ctx.$t(`ui.vehicleconfig.searchHelp.notes1`)),1),createBaseVNode(`li`,null,toDisplayString(_ctx.$t(`ui.vehicleconfig.searchHelp.notes3`)),1)])],512),[[vShow,Object.keys(search$1.result).length===0]]),search$1.history.browsing&&search$1.history.list.length>0?(openBlock(),createElementBlock(`div`,_hoisted_5$50,[_cache[40]||=createBaseVNode(`hr`,null,null,-1),createTextVNode(` `+toDisplayString(_ctx.$t(`ui.vehicleconfig.searchHelp.history`))+`: `,1),_cache[41]||=createBaseVNode(`br`,null,null,-1),_cache[42]||=createBaseVNode(`br`,null,null,-1),(openBlock(!0),createElementBlock(Fragment,null,renderList(search$1.history.list,(historyEntry,idx)=>(openBlock(),createElementBlock(`span`,{class:normalizeClass({"history-entry":!0,"history-indicator":idx===search$1.history.index})},toDisplayString(historyEntry),3))),256)),_cache[43]||=createBaseVNode(`br`,null,null,-1),createTextVNode(` `+toDisplayString(_ctx.$t(`ui.vehicleconfig.searchHelp.historyClear`)),1)])):createCommentVNode(``,!0)])):createCommentVNode(``,!0)])],32)),[[unref(BngScopedNav_default),{bubbleWhitelistEvents:[`menu`]}]]),createBaseVNode(`div`,_hoisted_6$37,[createBaseVNode(`div`,_hoisted_7$31,[withDirectives(createVNode(unref(bngButton_default),{accent:unref(ACCENTS).secondary,icon:unref(icons).sortAsc,disabled:waitingForData.value},null,8,[`accent`,`icon`,`disabled`]),[[unref(BngPopover_default),`parts-options-menu`,`top-start`,{click:!0}],[unref(BngTooltip_default),_ctx.$t(`ui.garage.optionsSwitch`),`right`]]),createVNode(unref(bngPopoverMenu_default),{name:`parts-options-menu`,focus:``},{default:withCtx(()=>[createBaseVNode(`div`,_hoisted_8$24,[withDirectives((openBlock(),createBlock(unref(bngButton_default),{accent:unref(ACCENTS).menu,icon:opts.showAux?unref(icons).checkmark:unref(icons)._empty,onClick:_cache[9]||=$event=>saveOption(`showAux`,opts.showAux=!opts.showAux)},{default:withCtx(()=>[createTextVNode(toDisplayString(_ctx.$t(`ui.showAuxiliary`)),1)]),_:1},8,[`accent`,`icon`])),[[unref(BngOnUiNav_default),void 0,`ok`,{focusRequired:!0,asMouse:!0}]]),withDirectives((openBlock(),createBlock(unref(bngButton_default),{accent:unref(ACCENTS).menu,icon:opts.showNames?unref(icons).checkmark:unref(icons)._empty,onClick:_cache[10]||=$event=>saveOption(`showNames`,opts.showNames=!opts.showNames)},{default:withCtx(()=>[createTextVNode(toDisplayString(_ctx.$t(`ui.vehicleconfig.displayNames`)),1)]),_:1},8,[`accent`,`icon`])),[[unref(BngOnUiNav_default),void 0,`ok`,{focusRequired:!0,asMouse:!0}]]),withDirectives((openBlock(),createBlock(unref(bngButton_default),{accent:unref(ACCENTS).menu,icon:opts.selectSubParts?unref(icons).checkmark:unref(icons)._empty,onClick:_cache[11]||=$event=>saveOption(`selectSubParts`,opts.selectSubParts=!opts.selectSubParts)},{default:withCtx(()=>[createTextVNode(toDisplayString(_ctx.$t(`ui.vehicleconfig.subparts`)),1)]),_:1},8,[`accent`,`icon`])),[[unref(BngOnUiNav_default),void 0,`ok`,{focusRequired:!0,asMouse:!0}]]),withDirectives((openBlock(),createBlock(unref(bngButton_default),{accent:unref(ACCENTS).menu,icon:opts.separateSort?unref(icons).checkmark:unref(icons)._empty,onClick:_cache[12]||=$event=>saveOption(`separateSort`,opts.separateSort=!opts.separateSort)},{default:withCtx(()=>[..._cache[44]||=[createTextVNode(`Sort sublists separately`,-1)]]),_:1},8,[`accent`,`icon`])),[[unref(BngOnUiNav_default),void 0,`ok`,{focusRequired:!0,asMouse:!0}]]),withDirectives((openBlock(),createBlock(unref(bngButton_default),{accent:unref(ACCENTS).menu,icon:opts.alwaysSort?unref(icons).checkmark:unref(icons)._empty,onClick:_cache[13]||=$event=>saveOption(`alwaysSort`,opts.alwaysSort=!opts.alwaysSort)},{default:withCtx(()=>[..._cache[45]||=[createTextVNode(`Always sort by name`,-1)]]),_:1},8,[`accent`,`icon`])),[[unref(BngOnUiNav_default),void 0,`ok`,{focusRequired:!0,asMouse:!0}]]),unref(isDev)?withDirectives((openBlock(),createBlock(unref(bngButton_default),{key:0,accent:unref(ACCENTS).menu,icon:opts.showEmpty?unref(icons).checkmark:unref(icons)._empty,onClick:_cache[14]||=$event=>opts.showEmpty=!opts.showEmpty},{default:withCtx(()=>[..._cache[46]||=[createTextVNode(`Show empty slots 🐞`,-1)]]),_:1},8,[`accent`,`icon`])),[[unref(BngOnUiNav_default),void 0,`ok`,{focusRequired:!0,asMouse:!0}]]):createCommentVNode(``,!0)])]),_:1})]),createBaseVNode(`div`,_hoisted_9$21,[createVNode(unref(bngSwitch_default),{disabled:partsChanged.value||waitingForData.value,modelValue:opts.applyPartChangesAutomatically,"onUpdate:modelValue":_cache[15]||=$event=>opts.applyPartChangesAutomatically=$event,onValueChanged:_cache[16]||=$event=>saveOption(`applyPartChangesAutomatically`,opts.applyPartChangesAutomatically)},{default:withCtx(()=>[createTextVNode(toDisplayString(_ctx.$t(`ui.garage.liveUpdates`)),1)]),_:1},8,[`disabled`,`modelValue`])])]),createBaseVNode(`div`,_hoisted_10$15,[withDirectives((openBlock(),createElementBlock(`div`,_hoisted_11$13,[createVNode(unref(bngInput_default),{modelValue:licensePlate.value,"onUpdate:modelValue":_cache[17]||=$event=>licensePlate.value=$event,"floating-label":_ctx.$t(`ui.vehicleconfig.licensePlate`),maxlength:`50`,onValueChanged:_cache[18]||=$event=>unref(applyLicensePlateDebounced)(),onKeyup:_cache[19]||=withKeys($event=>applyLicensePlate(),[`enter`]),validate:isLicensePlateTextValid},null,8,[`modelValue`,`floating-label`]),withDirectives(createVNode(unref(bngButton_default),{accent:unref(ACCENTS).outlined,icon:unref(icons).sync,onClick:_cache[20]||=$event=>applyRandomLicensePlate()},null,8,[`accent`,`icon`]),[[unref(BngTooltip_default),_ctx.$t(`ui.vehicleconfig.licensePlateGen`),`top`]]),opts.applyPartChangesAutomatically?createCommentVNode(``,!0):withDirectives((openBlock(),createBlock(unref(bngButton_default),{key:0,disabled:!licensePlateTextValid.value,icon:unref(icons).checkmark,onClick:_cache[21]||=$event=>applyLicensePlate()},null,8,[`disabled`,`icon`])),[[unref(BngTooltip_default),_ctx.$t(`ui.vehicleconfig.applyLicensePlate`),`top`]])])),[[unref(BngDisabled_default),skipLicGen.value||waitingForData.value],[unref(BngScopedNav_default),{bubbleWhitelistEvents:[`menu`]}]]),createBaseVNode(`div`,_hoisted_12$9,[withDirectives(createVNode(unref(bngButton_default),{"show-hold":``,icon:unref(icons).undo,accent:unref(ACCENTS).custom,class:`reset-button`,disabled:waitingForData.value},null,8,[`icon`,`accent`,`disabled`]),[[unref(BngOnUiNav_default),void 0,`ok`,{asMouse:!0,focusRequired:!0}],[unref(BngClick_default),{holdCallback:unref(resetAllToLoadedConfig),holdDelay:1e3,repeatInterval:0}],[unref(BngTooltip_default),`Reset to original config`]]),createVNode(unref(bngButton_default),{class:`parts-apply-button`,icon:unref(icons).checkmark,onClick:_cache[22]||=$event=>unref(write)(),disabled:opts.applyPartChangesAutomatically||!partsChanged.value||waitingForData.value},{default:withCtx(()=>[createTextVNode(toDisplayString(_ctx.$t(`ui.common.apply`)),1)]),_:1},8,[`icon`,`disabled`])])])],2)),[[unref(BngBlur_default),__props.withBackground]])}},Parts_default=__plugin_vue_export_helper_default(_sfc_main$118,[[`__scopeId`,`data-v-13e05ae0`]]),_hoisted_1$106={key:0,class:`saveload-static`},_hoisted_2$89={class:`saveload-row saveload-filename`},_hoisted_3$77={class:`saveload-list`},_hoisted_4$59=[`onClick`],_hoisted_5$49={class:`saveload-list-item-label`},_hoisted_6$36={class:`saveload-static saveload-row saveload-controls`},_sfc_main$117={__name:`Save`,props:{withBackground:Boolean},setup(__props){useUINavBlocker().blockOnly([`context`]);let{api:api$1}=useBridge(),events$3=useEvents(),saveThumbnail=ref(!0),configList=ref([]),configFiltered=computed(()=>{let res=configList.value;return saveName.value&&(res=res.filter(itm=>itm.name.toLowerCase().includes(saveName.value.toLowerCase()))),res=res.slice().sort((a$1,b)=>a$1.player&&!b.player?-1:!a$1.player&&b.player?1:a$1.name.localeCompare(b.name)),res}),saveDisabled=computed(()=>!saveName.value||/^\.|[<>:"/\\|?*]/.test(saveName.value)),saveName=ref(``),configExists=computed(()=>!!configList.value.some(itm=>itm.name.toLowerCase()===saveName.value.toLowerCase()));async function openConfigFolderInExplorer(){await Lua_default.extensions.core_vehicle_partmgmt.openConfigFolderInExplorer()}async function save(configName){configExists.value&&!await openConfirmation(`Are you sure?`,$translate.instant(`ui.garage.save.overwrite`),[{label:`Overwrite`,value:!0},{label:`Cancel`,value:!1,extras:{accent:ACCENTS.secondary}}])||(await Lua_default.extensions.core_vehicle_partmgmt.saveLocal(configName+`.pc`),saveThumbnail.value&&api$1.engineLua(`extensions.load('util_screenshotCreator'); util_screenshotCreator.startWork({selection="${configName}"})`))}async function load(configName){await Lua_default.extensions.core_vehicle_partmgmt.loadLocal(configName+`.pc`)}async function remove$3(configName){await openConfirmation(`Are you sure?`,`This will permanently remove the configuration. You will not be able to recover it.`,[{label:`Delete permanently`,value:!0,extras:{accent:ACCENTS.attention}},{label:`Cancel`,value:!1,extras:{accent:ACCENTS.secondary}}])&&(await Lua_default.extensions.core_vehicle_partmgmt.removeLocal(configName),await getConfigList())}async function getConfigList(){let configs$1=await Lua_default.extensions.core_vehicle_partmgmt.getConfigList();configList.value=Array.isArray(configs$1)?configs$1:[]}return events$3.on(`VehicleChange`,getConfigList),events$3.on(`VehicleFocusChanged`,getConfigList),events$3.on(`VehicleconfigSaved`,getConfigList),getConfigList(),(_ctx,_cache)=>withDirectives((openBlock(),createElementBlock(`div`,{class:normalizeClass({saveload:!0,"with-background":__props.withBackground})},[configList.value?(openBlock(),createElementBlock(`div`,_hoisted_1$106,[createBaseVNode(`div`,_hoisted_2$89,[createVNode(unref(bngInput_default),{modelValue:saveName.value,"onUpdate:modelValue":_cache[0]||=$event=>saveName.value=$event,modelModifiers:{trim:!0},"leading-icon":unref(icons).saveAs1,"floating-label":_ctx.$t(`ui.vehicleconfig.filename`)},null,8,[`modelValue`,`leading-icon`,`floating-label`]),withDirectives(createVNode(unref(bngButton_default),{icon:unref(icons).mathMultiply,style:`font-size: 0.75rem`,accent:unref(ACCENTS).text,onClick:_cache[1]||=$event=>saveName.value=``},null,8,[`icon`,`accent`]),[[unref(BngDisabled_default),!saveName.value]]),withDirectives((openBlock(),createBlock(unref(bngButton_default),{accent:configExists.value?unref(ACCENTS).attention:unref(ACCENTS).main,onClick:_cache[2]||=$event=>save(saveName.value)},{default:withCtx(()=>[createTextVNode(toDisplayString(configExists.value?_ctx.$t(`ui.common.overwrite`):_ctx.$t(`ui.common.save`)),1)]),_:1},8,[`accent`])),[[unref(BngDisabled_default),saveDisabled.value]])])])):createCommentVNode(``,!0),createBaseVNode(`div`,_hoisted_3$77,[(openBlock(!0),createElementBlock(Fragment,null,renderList(configFiltered.value,config=>(openBlock(),createElementBlock(`div`,{class:`saveload-list-item`,onClick:$event=>saveName.value=config.name,tabindex:`1`},[config.official?withDirectives((openBlock(),createBlock(unref(bngIcon_default),{key:0,type:unref(icons).beamNG},null,8,[`type`])),[[unref(BngTooltip_default),_ctx.$t(`ui.vehicleconfig.sourceOfficial`),`top`]]):config.player?withDirectives((openBlock(),createBlock(unref(bngIcon_default),{key:1,type:unref(icons).personSolid},null,8,[`type`])),[[unref(BngTooltip_default),_ctx.$t(`ui.vehicleconfig.sourceUser`),`top`]]):withDirectives((openBlock(),createBlock(unref(bngIcon_default),{key:2,type:unref(icons).puzzleModule},null,8,[`type`])),[[unref(BngTooltip_default),_ctx.$t(`ui.vehicleconfig.sourceMod`),`top`]]),createBaseVNode(`div`,_hoisted_5$49,toDisplayString(config.name),1),withDirectives((openBlock(),createBlock(unref(bngButton_default),{class:`saveload-list-item-load`,accent:unref(ACCENTS).outlined,icon:unref(icons).BNGFolder,onClick:withModifiers($event=>load(config.name),[`stop`])},{default:withCtx(()=>[createTextVNode(toDisplayString(_ctx.$t(`ui.vehicleconfig.load`)),1)]),_:1},8,[`accent`,`icon`,`onClick`])),[[unref(BngTooltip_default),_ctx.$t(`ui.vehicleconfig.loadTooltip`),`top`]]),config.player?withDirectives((openBlock(),createBlock(unref(bngButton_default),{key:3,class:`saveload-list-item-delete`,accent:unref(ACCENTS).outlined,icon:unref(icons).trashBin2,onClick:withModifiers($event=>remove$3(config.name),[`stop`])},null,8,[`accent`,`icon`,`onClick`])),[[unref(BngTooltip_default),`Remove configuration`,`top`]]):createCommentVNode(``,!0)],8,_hoisted_4$59))),256))]),createBaseVNode(`div`,_hoisted_6$36,[createVNode(unref(bngSwitch_default),{modelValue:saveThumbnail.value,"onUpdate:modelValue":_cache[3]||=$event=>saveThumbnail.value=$event},{default:withCtx(()=>[createTextVNode(toDisplayString(_ctx.$t(`ui.vehicleconfig.saveThumbnail`)),1)]),_:1},8,[`modelValue`]),createVNode(unref(bngButton_default),{accent:unref(ACCENTS).main,onClick:_cache[4]||=$event=>openConfigFolderInExplorer()},{default:withCtx(()=>[createTextVNode(toDisplayString(_ctx.$t(`ui.vehicleconfig.openConfigFolder`)),1)]),_:1},8,[`accent`])])],2)),[[unref(BngBlur_default),__props.withBackground]])}},Save_default=__plugin_vue_export_helper_default(_sfc_main$117,[[`__scopeId`,`data-v-31dd4dbb`]]),_hoisted_1$105={class:`garage-row-title`},_hoisted_2$88={class:`headingContainer`},_hoisted_3$76={class:`garage-title-sup`},_hoisted_4$58={class:`garage-title-main`},_hoisted_5$48={class:`garage-row-main`},_hoisted_6$35={class:`garage-menu-container garage-menu-main`},_hoisted_7$30={key:0,class:`garage-menu garage-menu-primary`},_hoisted_8$23={key:1,class:`garage-menu garage-menu-secondary`},_hoisted_9$20={key:2,class:`garage-content`},_hoisted_10$14={class:`garage-sidemenu-title`},_hoisted_11$12={class:`garage-drawer-header`},_hoisted_12$8={class:`garage-drawer-content`},_hoisted_13$8={class:`garage-drawer-header`},_hoisted_14$8={class:`garage-drawer-content`},_hoisted_15$8={class:`garage-drawer-header`},_hoisted_16$8={class:`garage-drawer-content`},_hoisted_17$7={class:`garage-row-bottom`},ownerId=`garage`,_sfc_main$116={__name:`Garage`,props:{component:String},setup(__props){let components={paint:Paint_default,parts:Parts_default,tuning:Tuning_default,save:Save_default},uiNavTracker=useUINavTracker(),{showIfController}=storeToRefs(controls_default()),{lua,api:api$1}=useBridge(),events$3=useEvents(),bngVue$1=window.bngVue||{gotoGameState(){}},backBinding=ref(null),streamsList$1=[`electrics`];useStreams(streamsList$1,onStreamsUpdate);let drawerCamera=ref(!1),drawerVehicle=ref(!1),drawerGarage=ref(!1);watch(()=>showIfController,val=>val?uiNavTracker.addIgnore(`action_4`,ownerId):uiNavTracker.removeIgnore(`action_4`,ownerId),{immediate:!0});let launchLiveryEditor=async()=>{await runRaw(`extensions.core_vehicle_partmgmt.hasAvailablePart(be:getPlayerVehicle(0).JBeam .. "_skin_dynamicTextures")`)?await openExperimental(`Dynamic Decals`,`This is an early highly experimental preview of the Decal Editor. Please be aware that anything created with this feature may be lost in future hotfixes and updates. Do you wish to proceed?`,[{label:$translate.instant(`ui.common.no`),value:!1,extras:{accent:ACCENTS.secondary}},{label:`Yes, I'm buckled up and ready to go!`,value:!0,extras:{default:!0}}])&&bngVue$1.gotoGameState(`livery-manager`):openMessage(``,$translate.instant(`ui.garage.decals.notAvailableForVehicle`))},props=__props,sidemenuActive=ref(!1);function activateSidemenu(){sidemenuActive.value=!0}function deactivateSidemenu(){sidemenuActive.value=!1,nextTick(()=>{drawerCamera.value=!1,drawerVehicle.value=!1,drawerGarage.value=!1})}function toggleSidemenu(){sidemenuActive.value=!sidemenuActive.value}let canSidemenuDeactivate=()=>!drawerCamera.value&&!drawerVehicle.value&&!drawerGarage.value,lightState=ref([!1,!1,!1]);async function lightToggle(idx){lightState.value[idx]=!lightState.value[idx],await lua.extensions.gameplay_garageMode.setLighting(lightState.value)}async function setCamera(view){await lua.extensions.gameplay_garageMode.setCamera(view)}let switches=reactive({lowbeam:{func:`setLightsState`,value:`lights_state`,on:1,off:0,state:!1},highbeam:{func:`setLightsState`,value:`lights_state`,on:2,off:0,state:!1},fog:{func:`set_fog_lights`,value:`fog`,on:1,off:0,state:!1},lightbar:{func:`set_lightbar_signal`,value:`lightbar`,on:1,off:0,state:!1},hazard:{func:`set_warn_signal`,value:`hazard_enabled`,on:1,off:0,state:!1}});function vehSwitch(key,on){if(!(key in switches))return;let svc=switches[key];if(on===void 0)on=!svc.state;else if(on===svc.state)return;api$1.activeObjectLua(`electrics.${svc.func}(${on?svc.on:svc.off})`)}let loaded=reactive({init:!1,vehicle:!1,status:!1}),vehicle=reactive({name:`Unknown`,vehicle:null,electrics:{},state:{}}),blackscreen=ref(!1),vehcomp=ref(``),vehcompview=ref(null),tmrInit;async function menuOpen(mode){vehcomp.value=vehcomp.value===mode?``:mode;let component=null;switch(mode){case`paint`:lua.extensions.gameplay_garageMode.setGarageMenuState(`paint`),component=components.paint;break;case`decals`:bngVue$1.gotoGameState(`decals-loader`);break;case`parts`:lua.extensions.gameplay_garageMode.setGarageMenuState(`parts`),component=components.parts;break;case`tuning`:lua.extensions.gameplay_garageMode.setGarageMenuState(`tuning`),component=components.tuning;break;case`vehicles`:lua.extensions.gameplay_garageMode.setGarageMenuState(`vehicles`),bngVue$1.gotoGameState(`menu.vehicles`,{params:{mode:`garageMode`,garage:`all`}});break;case`mycars`:lua.extensions.gameplay_garageMode.setGarageMenuState(`myCars`),bngVue$1.gotoGameState(`menu.vehicles`,{params:{mode:`garageMode`,garage:`own`}});break;case`photo`:bngVue$1.gotoGameState(`menu.photomode`);break;case`save`:component=components.save;break;case`savedefault`:console.log(`TODO: save as default`);break;case`test`:vehcomp.value=``,lua.extensions.gameplay_garageMode.testVehicle();break;default:vehcomp.value=``;break}component&&(vehcompview.value=markRaw(component))}function exit(event){event.detail.force||(vehcomp.value?menuOpen():window.bngVue.gotoAngularState(`menu.mainmenu`))}async function vehChange(){loaded.vehicle=!1,loaded.status=!1,vehicle.name=`Unknown`,vehicle.vehicle=null,vehicle.electrics={},await api$1.activeObjectLua(`electrics.setIgnitionLevel(1)`);let data=await lua.core_vehicles.getCurrentVehicleDetails();tmrInit&&=(loaded.init=!0,clearTimeout(tmrInit),null),data&&(loaded.vehicle=!0,vehicle.vehicle=data,data.model.Brand?vehicle.name=`${data.model.Brand} ${data.model.Name}`:vehicle.name=data.configs.Name,data.configs.Configuration&&(data.configs.Source===`BeamNG - Official`?vehicle.name+=` - ${data.configs.Configuration}`:vehicle.name+=` - Custom`))}function onStreamsUpdate(streams){if(typeof streams!=`object`||!streamsList$1.every(name=>name in streams))return;let data=streams.electrics;for(let key in loaded.status=data.ignitionLevel>0,switches){let svc=switches[key];svc.state=svc.value in data&&data[svc.value]===svc.on,vehicle.electrics[key]=svc.state}}let canScopeDeactivate=()=>!vehcomp.value;return onBeforeMount(async()=>{tmrInit=setTimeout(()=>{console.log(`Unable to get vehicle details in time. Forcing to init...`),loaded.init=!0,tmrInit=null},3e3),events$3.on(`VehicleChange`,vehChange),api$1.activeObjectLua(`electrics.setIgnitionLevel(1)`),events$3.on(`GarageModeBlackscreen`,data=>blackscreen.value=data.active),vehChange(),lightState.value=await lua.extensions.gameplay_garageMode.getLighting(),props.component&&menuOpen(props.component)}),onUnmounted(()=>{tmrInit&&clearTimeout(tmrInit)}),(_ctx,_cache)=>(openBlock(),createElementBlock(Fragment,null,[withDirectives(createBaseVNode(`div`,{class:normalizeClass([`garage-blackscreen`,{"garage-blackscreen-active":blackscreen.value}])},null,2),[[unref(BngBlur_default),blackscreen.value]]),loaded.init?withDirectives((openBlock(),createElementBlock(`div`,{key:0,class:`garage-view`,onDeactivate:exit},[createBaseVNode(`div`,_hoisted_1$105,[createBaseVNode(`div`,_hoisted_2$88,[withDirectives((openBlock(),createElementBlock(`div`,_hoisted_3$76,[createBaseVNode(`h4`,null,[createTextVNode(toDisplayString(_ctx.$t(`ui.mainmenu.garage`))+` `,1),vehcomp.value?(openBlock(),createElementBlock(Fragment,{key:0},[createTextVNode(`/ `+toDisplayString(vehicle.name),1)],64)):createCommentVNode(``,!0)])])),[[unref(BngBlur_default)]]),withDirectives((openBlock(),createElementBlock(`h2`,_hoisted_4$58,[vehcomp.value?withDirectives((openBlock(),createBlock(unref(bngButton_default),{key:0,class:normalizeClass([`garage-back-button`,{"garage-back-binding-shown":backBinding.value?.displayed}]),accent:backBinding.value?.displayed?unref(ACCENTS).ghost:unref(ACCENTS).outlined,icon:unref(icons).arrowLargeLeft,"bng-no-nav":`true`,onClick:exit},{default:withCtx(()=>[withDirectives(createVNode(unref(bngBinding_default),{ref_key:`backBinding`,ref:backBinding,class:`back-binding`,"ui-event":`back`,controller:``,"track-ignore":``},null,512),[[vShow,!sidemenuActive.value]]),createTextVNode(` `+toDisplayString(backBinding.value?.displayed?``:_ctx.$t(`ui.common.back`)),1)]),_:1},8,[`class`,`accent`,`icon`])),[[unref(BngTooltip_default),!backBinding.value||backBinding.value?.displayed?_ctx.$t(`ui.common.back`):void 0,`top`]]):createCommentVNode(``,!0),createBaseVNode(`span`,null,toDisplayString(vehcomp.value?_ctx.$t(`ui.garage.tabs.`+(vehcomp.value===`tuning`?`tune`:vehcomp.value)):vehicle.name),1)])),[[unref(BngBlur_default)]])])]),createBaseVNode(`div`,_hoisted_5$48,[createBaseVNode(`div`,_hoisted_6$35,[vehcomp.value?createCommentVNode(``,!0):(openBlock(),createElementBlock(`div`,_hoisted_7$30,[withDirectives((openBlock(),createBlock(GarageButton_default,{icon:unref(icons).engine,active:vehcomp.value===`parts`,onClick:_cache[0]||=$event=>menuOpen(`parts`),"bng-scoped-nav-autofocus":loaded.vehicle&&!sidemenuActive.value&&unref(showIfController)},{default:withCtx(()=>[createTextVNode(toDisplayString(_ctx.$t(`ui.garage.tabs.parts`)),1)]),_:1},8,[`icon`,`active`,`bng-scoped-nav-autofocus`])),[[unref(BngDisabled_default),!loaded.vehicle],[unref(BngBlur_default)]]),withDirectives((openBlock(),createBlock(GarageButton_default,{icon:unref(icons).wrench,active:vehcomp.value===`tuning`,onClick:_cache[1]||=$event=>menuOpen(`tuning`)},{default:withCtx(()=>[createTextVNode(toDisplayString(_ctx.$t(`ui.garage.tabs.tune`)),1)]),_:1},8,[`icon`,`active`])),[[unref(BngDisabled_default),!loaded.vehicle],[unref(BngBlur_default)]]),withDirectives((openBlock(),createBlock(GarageButton_default,{icon:unref(icons).sprayCan,active:vehcomp.value===`paint`,onClick:_cache[2]||=$event=>menuOpen(`paint`)},{default:withCtx(()=>[createTextVNode(toDisplayString(_ctx.$t(`ui.garage.tabs.paint`)),1)]),_:1},8,[`icon`,`active`])),[[unref(BngDisabled_default),!loaded.vehicle],[unref(BngBlur_default)]]),withDirectives((openBlock(),createBlock(GarageButton_default,{icon:unref(icons).star,active:vehcomp.value===`decals`,onClick:launchLiveryEditor},{default:withCtx(()=>[createTextVNode(toDisplayString(_ctx.$t(`ui.garage.tabs.decals`)),1)]),_:1},8,[`icon`,`active`])),[[unref(BngDisabled_default),!loaded.vehicle],[unref(BngBlur_default)]])])),vehcomp.value?createCommentVNode(``,!0):(openBlock(),createElementBlock(`div`,_hoisted_8$23,[withDirectives((openBlock(),createBlock(GarageButton_default,{icon:unref(icons).car,active:vehcomp.value===`vehicles`,onClick:_cache[3]||=$event=>menuOpen(`vehicles`)},{default:withCtx(()=>[createTextVNode(toDisplayString(_ctx.$t(`ui.garage.tabs.vehicles`)),1)]),_:1},8,[`icon`,`active`])),[[unref(BngDisabled_default),!loaded.vehicle],[unref(BngBlur_default)]]),withDirectives((openBlock(),createBlock(GarageButton_default,{icon:unref(icons).keys1,active:vehcomp.value===`mycars`,onClick:_cache[4]||=$event=>menuOpen(`mycars`)},{default:withCtx(()=>[createTextVNode(toDisplayString(_ctx.$t(`ui.garage.tabs.load`)),1)]),_:1},8,[`icon`,`active`])),[[unref(BngDisabled_default),!loaded.vehicle],[unref(BngBlur_default)]]),withDirectives((openBlock(),createBlock(GarageButton_default,{icon:unref(icons).photo,onClick:_cache[5]||=$event=>menuOpen(`photo`)},{default:withCtx(()=>[createTextVNode(toDisplayString(_ctx.$t(`ui.garage.tabs.photo`)),1)]),_:1},8,[`icon`])),[[unref(BngDisabled_default),!loaded.vehicle],[unref(BngBlur_default)]])])),vehcomp.value&&vehcompview.value?withDirectives((openBlock(),createElementBlock(`div`,_hoisted_9$20,[(openBlock(),createBlock(resolveDynamicComponent(vehcompview.value),{"with-background":``,"with-padding":!1}))])),[[unref(BngOnUiNav_default),exit,`menu,back`],[unref(BngFrustumMover_default),!0,`left`]]):createCommentVNode(``,!0)]),withDirectives((openBlock(),createElementBlock(`div`,{class:`garage-sidemenu`,onActivate:activateSidemenu,onDeactivate:deactivateSidemenu},[withDirectives((openBlock(),createElementBlock(`h4`,_hoisted_10$14,[createVNode(unref(bngBinding_default),{class:`back-binding`,"ui-event":`action_4`,controller:``}),createTextVNode(` `+toDisplayString(_ctx.$t(`ui.garage2.features`)),1)])),[[unref(BngBlur_default)]]),createVNode(unref(drawer_default),{modelValue:drawerCamera.value,"onUpdate:modelValue":_cache[12]||=$event=>drawerCamera.value=$event,position:`left`,class:`garage-menugroup`},{header:withCtx(()=>[withDirectives((openBlock(),createElementBlock(`div`,_hoisted_11$12,[withDirectives((openBlock(),createBlock(GarageButton_default,{type:`drawer-toggle`,icon:unref(icons).movieCamera,active:drawerCamera.value,"bng-scoped-nav-autofocus":sidemenuActive.value&&unref(showIfController),onClick:_cache[6]||=$event=>drawerCamera.value=!drawerCamera.value},{default:withCtx(()=>[createTextVNode(toDisplayString(_ctx.$t(`ui.garage.photo.camera`)),1)]),_:1},8,[`icon`,`active`,`bng-scoped-nav-autofocus`])),[[unref(BngDisabled_default),!loaded.init]])])),[[unref(BngBlur_default)]])]),"expanded-content":withCtx(()=>[withDirectives((openBlock(),createElementBlock(`div`,_hoisted_12$8,[createVNode(GarageButton_default,{type:`drawer-button`,icon:unref(icons).camera3Fourth1,onClick:_cache[7]||=$event=>setCamera(`default`)},{default:withCtx(()=>[createTextVNode(toDisplayString(_ctx.$t(`engine.editor.menu.standartCamera`)),1)]),_:1},8,[`icon`]),createVNode(GarageButton_default,{type:`drawer-button`,icon:unref(icons).cameraFront1,onClick:_cache[8]||=$event=>setCamera(`front`)},{default:withCtx(()=>[createTextVNode(toDisplayString(_ctx.$t(`engine.editor.menu.camera.front`)),1)]),_:1},8,[`icon`]),createVNode(GarageButton_default,{type:`drawer-button`,icon:unref(icons).cameraBack1,onClick:_cache[9]||=$event=>setCamera(`back`)},{default:withCtx(()=>[createTextVNode(toDisplayString(_ctx.$t(`engine.editor.menu.camera.back`)),1)]),_:1},8,[`icon`]),createVNode(GarageButton_default,{type:`drawer-button`,icon:unref(icons).cameraSideRight,onClick:_cache[10]||=$event=>setCamera(`side`)},{default:withCtx(()=>[createTextVNode(toDisplayString(_ctx.$t(`engine.editor.menu.camera.right`)),1)]),_:1},8,[`icon`]),createVNode(GarageButton_default,{type:`drawer-button`,icon:unref(icons).cameraTop1,onClick:_cache[11]||=$event=>setCamera(`top`)},{default:withCtx(()=>[createTextVNode(toDisplayString(_ctx.$t(`engine.editor.menu.camera.top`)),1)]),_:1},8,[`icon`])])),[[unref(BngOnUiNav_default),toggleSidemenu,`menu,back`],[unref(BngBlur_default)]])]),_:1},8,[`modelValue`]),createVNode(unref(drawer_default),{modelValue:drawerVehicle.value,"onUpdate:modelValue":_cache[19]||=$event=>drawerVehicle.value=$event,position:`left`,class:`garage-menugroup`},{header:withCtx(()=>[withDirectives((openBlock(),createElementBlock(`div`,_hoisted_13$8,[withDirectives((openBlock(),createBlock(GarageButton_default,{type:`drawer-toggle`,icon:unref(icons).electronicSchemeOutline,active:drawerVehicle.value,onClick:_cache[13]||=$event=>drawerVehicle.value=!drawerVehicle.value},{default:withCtx(()=>[createTextVNode(toDisplayString(_ctx.$t(`ui.radialmenu2.electrics`)),1)]),_:1},8,[`icon`,`active`])),[[unref(BngDisabled_default),!loaded.vehicle||!loaded.status]])])),[[unref(BngBlur_default)]])]),"expanded-content":withCtx(()=>[withDirectives((openBlock(),createElementBlock(`div`,_hoisted_14$8,[withDirectives((openBlock(),createBlock(GarageButton_default,{type:`drawer-button`,icon:unref(icons).lowBeam,active:vehicle.electrics.lowbeam,onClick:_cache[14]||=$event=>vehSwitch(`lowbeam`)},{default:withCtx(()=>[createTextVNode(toDisplayString(_ctx.$t(`ui.radialmenu2.electrics.headlights.low`)),1)]),_:1},8,[`icon`,`active`])),[[unref(BngDisabled_default),!loaded.vehicle]]),withDirectives((openBlock(),createBlock(GarageButton_default,{type:`drawer-button`,icon:unref(icons).highBeam,active:vehicle.electrics.highbeam,onClick:_cache[15]||=$event=>vehSwitch(`highbeam`)},{default:withCtx(()=>[createTextVNode(toDisplayString(_ctx.$t(`ui.radialmenu2.electrics.headlights.high`)),1)]),_:1},8,[`icon`,`active`])),[[unref(BngDisabled_default),!loaded.vehicle]]),withDirectives((openBlock(),createBlock(GarageButton_default,{type:`drawer-button`,icon:unref(icons).fogLight,active:vehicle.electrics.fog_lights,onClick:_cache[16]||=$event=>vehSwitch(`fog`)},{default:withCtx(()=>[createTextVNode(toDisplayString(_ctx.$t(`ui.radialmenu2.electrics.fog_lights`)),1)]),_:1},8,[`icon`,`active`])),[[unref(BngDisabled_default),!loaded.vehicle]]),withDirectives((openBlock(),createBlock(GarageButton_default,{type:`drawer-button`,icon:unref(icons).hazardLights,active:vehicle.electrics.hazard,onClick:_cache[17]||=$event=>vehSwitch(`hazard`)},{default:withCtx(()=>[createTextVNode(toDisplayString(_ctx.$t(`ui.radialmenu2.electrics.hazard_lights`)),1)]),_:1},8,[`icon`,`active`])),[[unref(BngDisabled_default),!loaded.vehicle]]),withDirectives((openBlock(),createBlock(GarageButton_default,{type:`drawer-button`,icon:unref(icons).wigwags,active:vehicle.electrics.lightbar,onClick:_cache[18]||=$event=>vehSwitch(`lightbar`)},{default:withCtx(()=>[createTextVNode(toDisplayString(_ctx.$t(`ui.radialmenu2.electrics.lightbar`)),1)]),_:1},8,[`icon`,`active`])),[[unref(BngDisabled_default),!loaded.vehicle]])])),[[unref(BngOnUiNav_default),toggleSidemenu,`menu,back`],[unref(BngBlur_default)]])]),_:1},8,[`modelValue`]),createVNode(unref(drawer_default),{modelValue:drawerGarage.value,"onUpdate:modelValue":_cache[24]||=$event=>drawerGarage.value=$event,position:`left`,class:`garage-menugroup`},{header:withCtx(()=>[withDirectives((openBlock(),createElementBlock(`div`,_hoisted_15$8,[withDirectives((openBlock(),createBlock(GarageButton_default,{type:`drawer-toggle`,icon:unref(icons).garage01,active:drawerGarage.value,onClick:_cache[20]||=$event=>drawerGarage.value=!drawerGarage.value},{default:withCtx(()=>[createTextVNode(toDisplayString(_ctx.$t(`ui.garage2.features`)),1)]),_:1},8,[`icon`,`active`])),[[unref(BngDisabled_default),!loaded.init]])])),[[unref(BngBlur_default)]])]),"expanded-content":withCtx(()=>[withDirectives((openBlock(),createElementBlock(`div`,_hoisted_16$8,[createVNode(GarageButton_default,{type:`drawer-button`,icon:unref(icons).lightGarageG32,active:lightState.value[0],onClick:_cache[21]||=$event=>lightToggle(0)},{default:withCtx(()=>[createTextVNode(toDisplayString(_ctx.$t(`ui.garage2.lights.west`)),1)]),_:1},8,[`icon`,`active`]),createVNode(GarageButton_default,{type:`drawer-button`,icon:unref(icons).lightGarageG22,active:lightState.value[1],onClick:_cache[22]||=$event=>lightToggle(1)},{default:withCtx(()=>[createTextVNode(toDisplayString(_ctx.$t(`ui.garage2.lights.middle`)),1)]),_:1},8,[`icon`,`active`]),createVNode(GarageButton_default,{type:`drawer-button`,icon:unref(icons).lightGarageG12,active:lightState.value[2],onClick:_cache[23]||=$event=>lightToggle(2)},{default:withCtx(()=>[createTextVNode(toDisplayString(_ctx.$t(`ui.garage2.lights.east`)),1)]),_:1},8,[`icon`,`active`])])),[[unref(BngOnUiNav_default),toggleSidemenu,`menu,back`],[unref(BngBlur_default)]])]),_:1},8,[`modelValue`])],32)),[[unref(BngScopedNav_default),{activated:sidemenuActive.value,type:`container`,bubbleWhitelistEvents:[`menu`],canDeactivate:canSidemenuDeactivate}],[unref(BngOnUiNav_default),toggleSidemenu,`action_4`]])]),createBaseVNode(`div`,_hoisted_17$7,[withDirectives(createVNode(GarageButton_default,{active:vehcomp.value===`save`,onClick:_cache[25]||=$event=>menuOpen(`save`),icon:unref(icons).saveAs1},null,8,[`active`,`icon`]),[[unref(BngDisabled_default),!loaded.vehicle],[unref(BngBlur_default)],[unref(BngTooltip_default),_ctx.$t(`ui.vehicleconfig.save`),`top`]]),withDirectives(createVNode(GarageButton_default,{onClick:_cache[26]||=$event=>menuOpen(`test`),icon:unref(icons).trafficCone},null,8,[`icon`]),[[unref(BngDisabled_default),!loaded.vehicle],[unref(BngBlur_default)],[unref(BngTooltip_default),_ctx.$t(`ui.common.test`),`top`]])])],32)),[[unref(BngScopedNav_default),{activateOnMount:!0,bubbleWhitelistEvents:[`menu`],canDeactivate:canScopeDeactivate}],[unref(BngOnUiNav_default),toggleSidemenu,`action_4`]]):createCommentVNode(``,!0)],64))}},Garage_default=__plugin_vue_export_helper_default(_sfc_main$116,[[`__scopeId`,`data-v-b5f03823`]]),routes_default$7=[{path:`/garagemode/:component?`,name:`garagemode`,component:Garage_default,props:!0,meta:{infoBar:{visible:!0,showSysInfo:!1},uiApps:{shown:!0}}},{path:`/garagemode/tuning`,name:`garagemode.tuning`,component:Garage_default,props:{component:`tuning`},meta:{infoBar:{visible:!0,showSysInfo:!1},uiApps:{shown:!0}}}],_hoisted_1$104={class:`edit-form`},_sfc_main$115={__name:`FileEditForm`,props:{modelValue:{type:[Object,String,Number,Boolean],required:!0}},emits:[`update:modelValue`],setup(__props,{emit:__emit}){let props=__props,emit$1=__emit,formModel=computed({get:()=>props.modelValue,set:newValue=>{emit$1(`update:modelValue`,newValue)}});return(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$104,[createVNode(unref(bngInput_default),{modelValue:formModel.value.name,"onUpdate:modelValue":_cache[0]||=$event=>formModel.value.name=$event,suffix:`.dyndecals.json`},null,8,[`modelValue`])]))}},FileEditForm_default=__plugin_vue_export_helper_default(_sfc_main$115,[[`__scopeId`,`data-v-c94cd7bf`]]),_sfc_main$114={__name:`RenameLayerForm`,props:{modelValue:{type:[Object,String,Number,Boolean],required:!0}},emits:[`update:modelValue`],setup(__props,{emit:__emit}){let props=__props,emit$1=__emit,formModel=computed({get:()=>props.modelValue,set:newValue=>{emit$1(`update:modelValue`,newValue)}});return(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,null,[createVNode(unref(bngInput_default),{modelValue:formModel.value.name,"onUpdate:modelValue":_cache[0]||=$event=>formModel.value.name=$event},null,8,[`modelValue`])]))}},RenameLayerForm_default=_sfc_main$114,_hoisted_1$103={class:`exit-editor-dialog`},_hoisted_2$87={class:`apply-skin-wrapper`},_sfc_main$113={__name:`ExitEditorDialog`,props:{modelValue:{type:[Object,String,Number,Boolean],required:!0}},emits:[`update:modelValue`],setup(__props,{emit:__emit}){let props=__props,emit$1=__emit,formModel=computed({get:()=>props.modelValue,set:newValue=>{emit$1(`update:modelValue`,newValue)}});return(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$103,[createVNode(unref(bngInput_default),{modelValue:formModel.value.name,"onUpdate:modelValue":_cache[0]||=$event=>formModel.value.name=$event,suffix:`.dyndecals.json`},null,8,[`modelValue`]),createBaseVNode(`div`,_hoisted_2$87,[createVNode(unref(bngPillCheckbox_default),{modelValue:formModel.value.applySkin,"onUpdate:modelValue":_cache[1]||=$event=>formModel.value.applySkin=$event,disabled:!formModel.value.name},{default:withCtx(()=>[..._cache[2]||=[createTextVNode(`Apply Skin`,-1)]]),_:1},8,[`modelValue`,`disabled`])])]))}},ExitEditorDialog_default=__plugin_vue_export_helper_default(_sfc_main$113,[[`__scopeId`,`data-v-b4897c9e`]]);const openEditFileDialog=(title,description,formModel,formValidator)=>openFormDialog(FileEditForm_default,formModel,formValidator,title,description),openRenameLayerDialog=(title,description,formModel,formValidator)=>openFormDialog(RenameLayerForm_default,formModel,formValidator,title,description);var SELECTION_LUA$1=Lua_default.extensions.ui_liveryEditor_selection;const useLayerActionsStore=defineStore(`createLayer`,()=>{async function onActionItemSelected(action){if(!action.items)if(console.log(`[onActionItemSelected] do action`),action.value===`group`)await Lua_default.extensions.ui_liveryEditor_tools_group.groupLayers();else if(action.value===`ungroup`)await Lua_default.extensions.ui_liveryEditor_tools_group.ungroupLayer();else if(action.value===`delete`)await openConfirmation(`Delete Layer`,`Are you sure you want to delete ${singleSelectedLayer.value.name}?`)&&await Lua_default.extensions.ui_liveryEditor_tools_settings.deleteLayer();else if(action.value===`rename`){let res=await openRenameLayerDialog(`Rename Layer`,``,{name:singleSelectedLayer.value.name},model=>model.name!==null&&model.name!==void 0&&model.name!==``&&model.name!==singleSelectedLayer.value.name);res.value&&await Lua_default.extensions.ui_liveryEditor_tools_settings.rename(res.formData.name)}else action.value===`duplicate`?await SELECTION_LUA$1.duplicateSelectedLayer():await Lua_default.extensions.ui_liveryEditor_tools.useTool(action.value)}return{onActionItemSelected}});var EDIT_MODE=Lua_default.extensions.ui_liveryEditor_editMode,DECAL_LAYER=Lua_default.extensions.ui_liveryEditor_layers_decals,TRANSFORM_TOOL=Lua_default.extensions.ui_liveryEditor_tools_transform,MATERIAL_TOOL=Lua_default.extensions.ui_liveryEditor_tools_material,SETTINGS_TOOL=Lua_default.extensions.ui_liveryEditor_tools_settings;const useLayerSettingsStore=defineStore(`layerSettings`,()=>{let{events:events$3}=useBridge(),rootStore=useLiveryEditorStore(),active=ref(!1),targetLayer=ref({}),currentTool=ref(null),toolsData=ref(null),requestApplyActive=ref(!1),decalTexture=ref(null),isChangeDecal=ref(null),activeSettings=ref(null),editModeState=reactive({lockScaling:!1}),isStampMode=computed(()=>toolsData.value&&toolsData.value.mode===`stamp`),_reapplyActive=ref(!1),cursorData=ref(null),_appliedLayers=ref(null),activeLayerUid=ref(null),reapplyActive=computed({get:()=>_reapplyActive.value,set:async newValue=>{newValue?await Lua_default.extensions.ui_liveryEditor_editMode.requestReapply():await Lua_default.extensions.ui_liveryEditor_editMode.cancelReapply()}}),appliedLayers=computed(()=>!_appliedLayers.value||!Array.isArray(_appliedLayers.value)?null:_appliedLayers.value);events$3.on(`liveryEditor_EditMode_OnActiveStatusChanged`,async data=>{console.log(`liveryEditor_EditMode_OnActiveStatusChanged`,data),active.value=data}),events$3.on(`LiveryEditor_CursorUpdated`,async data=>{console.log(`LiveryEditor_CursorUpdated`,data),cursorData.value=data}),events$3.on(`LiveryEditor_SelectedLayersDataUpdated`,async data=>{console.log(`LiveryEditor_SelectedLayersDataUpdated`,data),data&&Array.isArray(data)&&data.length>0&&(targetLayer.value=data[0])}),events$3.on(`liveryEditor_OnSettingsChanged_UseMousePos`,data=>{console.log(`liveryEditor_OnSettingsChanged_UseMousePos`,data),cursorData.value&&(cursorData.value.isUseMousePos=data)}),events$3.on(`liveryEditor_OnEditMode_ReapplyChanged`,data=>{console.log(`liveryEditor_OnEditMode_ReapplyChanged`,data),_reapplyActive.value=data}),events$3.on(`LiveryEditorToolChanged`,data=>{console.log(`LiverEditorToolChanged`,data),currentTool.value=data}),events$3.on(`LiveryEditor_ToolDataUpdated`,async data=>{console.log(`LiveryEditor_ToolDataUpdated`,data),toolsData.value=data}),events$3.on(`liveryEditor_EditMode_OnRequestApplyChanged`,async data=>{console.log(`liveryEditor_EditMode_OnRequestApplyChanged`,data),requestApplyActive.value=data}),events$3.on(`liveryEditor_EditMode_OnAppliedLayersUpdated`,async data=>{console.log(`liveryEditor_EditMode_OnAppliedLayersUpdated`,data),_appliedLayers.value=data}),events$3.on(`liveryEditor_EditMode_OnActiveLayerChanged`,async data=>{console.log(`liveryEditor_EditMode_OnActiveLayerChanged`,data),activeLayerUid.value=data}),events$3.on(`liveryEditor_onDecalTextureChanged`,async data=>{console.log(`liveryEditor_onDecalTextureChanged`,data),console.log(`liveryEditor_onDecalTextureChanged active value`,active.value),active.value?!isChangeDecal.value&&!requestApplyActive.value&&await requestApply():await EDIT_MODE.activate(),await MATERIAL_TOOL.setDecal(data),rootStore.toggleShowDecalSelector(),isChangeDecal.value=null}),events$3.on(`liveryEditor_onDecalSelectorCancelled`,async data=>{console.log(`liveryEditor_onDecalSelectorCancelled`,data),active.value?rootStore.toggleShowDecalSelector():rootStore.toggleEditModeLayout(),isChangeDecal.value=null});function init$3(){active.value?EDIT_MODE.resetCursorProperties([]):rootStore.toggleShowDecalSelector()}let deactivate=async()=>{await Lua_default.extensions.ui_liveryEditor_editMode.deactivate(),rootStore.currentContext=EDITOR_CONTEXT.default,rootStore.editorView=EDITOR_VIEWS.default},toggleRequestApply=async()=>await Lua_default.extensions.ui_liveryEditor_editMode.toggleRequestApply(),requestApply=async()=>await Lua_default.extensions.ui_liveryEditor_editMode.requestApply(),cancelRequestApply=async()=>await Lua_default.extensions.ui_liveryEditor_editMode.cancelRequestApply(),getInitialData=async()=>await Lua_default.extensions.ui_liveryEditor_layers_cursor.requestData(),toggleStamp=async()=>{toolsData.value&&toolsData.value.mode===`stamp`?await Lua_default.extensions.ui_liveryEditor_tools_transform.cancelStamp():await Lua_default.extensions.ui_liveryEditor_tools_transform.useStamp()},setActiveLayer=async layerUid=>{await Lua_default.extensions.ui_liveryEditor_editMode.setActiveLayer(layerUid)},requestReapply=async()=>{await Lua_default.extensions.ui_liveryEditor_editMode.requestReapply()},cancelReapply=async()=>{await Lua_default.extensions.ui_liveryEditor_editMode.cancelReapply()},cancelChanges=async()=>{await Lua_default.extensions.ui_liveryEditor_editMode.cancelChanges(),await Lua_default.extensions.ui_liveryEditor_editMode.deactivate(),await Lua_default.extensions.ui_liveryEditor_tools.closeCurrentTool()},requestChangeDecal=async()=>{isChangeDecal.value=!0,rootStore.toggleShowDecalSelector()},toggleReapply=()=>reapplyActive.value=!reapplyActive.value,apply$1=async()=>await Lua_default.extensions.ui_liveryEditor_editMode.apply(),saveChanges=async params=>{await Lua_default.extensions.ui_liveryEditor_editMode.saveChanges(params),await Lua_default.extensions.ui_liveryEditor_editMode.deactivate(),rootStore.currentContext=EDITOR_CONTEXT.default,rootStore.editorView=EDITOR_VIEWS.default},closeCurrentTool=async()=>{await Lua_default.extensions.ui_liveryEditor_tools.closeCurrentTool()};return{...EDIT_MODE,...TRANSFORM_TOOL,...MATERIAL_TOOL,...SETTINGS_TOOL,...DECAL_LAYER,active,cursorData,appliedLayers,activeLayerUid,requestApplyActive,reapplyActive,decalTexture,editModeState,activeSettings,init:init$3,deactivate,getInitialData,toolsData,targetLayer,isStampMode,toggleStamp,requestReapply,cancelReapply,cancelChanges,requestApply,cancelRequestApply,toggleRequestApply,toggleReapply,setActiveLayer,saveChanges,requestChangeDecal,apply:apply$1,closeCurrentTool}}),useLayersManagerStore=defineStore(`layersManager`,()=>{let{events:events$3}=useBridge(),multipleSelection=ref(!1),_selection=ref([]),selectedLayers=computed({get(){return _selection.value},set(newValue){sendUpdatedSelection(newValue)}});events$3.on(`LiveryEditor_SelectedLayersChanged`,data=>{console.log(`selected Layer Updated`,data),_selection.value=data&&Array.isArray(data)&&data.length>0?data:[]});let sendUpdatedSelection=async selection=>{console.log(`sendUpdatedSelection`,selection),selection.length===0?await Lua_default.extensions.ui_liveryEditor_selection.clearSelection():multipleSelection.value?await Lua_default.extensions.ui_liveryEditor_selection.setMultipleSelected(selection):await Lua_default.extensions.ui_liveryEditor_selection.setSelected(selection)},canSort=data=>{let item=getItemByPath(data.targetDataset.draggablePath);return!(data.intersectionType===INTERSECTION_TYPES.sub&&item.type!==3)};async function clearSelection(){multipleSelection.value=!1,selectedLayers.value=[]}function getItemByPath(path){let pathSegments=path?path.split(`/`):void 0;if(!pathSegments)throw Error(`Path not defined`);let index=parseInt(pathSegments[0]),currentItem=layers.value[index];for(let i=1;i{Lua_default.extensions.ui_liveryEditor_tools_group.changeOrder(oldIndex+1,oldParentUid||``,newIndex+1,newParentUid||``)},clearSelection}});var FIRST_LAYER_ACTIONS=[{value:`edit`,label:`Edit`,icon:icons.edit,validator:()=>!0},{value:`order`,label:`Change Order`,icon:icons.order},{value:`rename`,label:`Rename`,icon:icons.rename},{value:`highlight`,label:`Highlight On`,icon:icons.eyeSolidOpened,toggleAction:!0,inactiveLabel:`Highlight Off`,inactiveIcon:icons.eyeSolidClosed},{value:`visibility`,label:`Enabled`,icon:icons.eyeOutlineOpened,toggleAction:!0,inactiveLabel:`Hidden`,inactiveIcon:icons.eyeOutlineClosed},{value:`delete`,label:`Delete`,icon:icons.trashBin2}],SELECTION_LUA=Lua_default.extensions.ui_liveryEditor_selection,SETTINGS_LUA=Lua_default.extensions.ui_liveryEditor_tools_settings,CAMERA_LUA=Lua_default.extensions.ui_liveryEditor_camera,EDITOR_LUA=Lua_default.extensions.ui_liveryEditor_editor;const EDITOR_CONTEXT={default:`default`,editMode:`editMode`,newLayer:`newLayer`};var SELECT_MODE={single:`single`,multi:`multi`};const EDITOR_VIEWS={default:`default`,decalSelector:`decalSelector`,editMode:`editMode`},useLiveryEditorStore=defineStore(`liveryEditor`,()=>{let{events:events$3}=useBridge(),layers$1=ref(null),visibleLayersCount=ref(null),selectedTool=ref(null),currentFile=ref(null),currentContext=ref(null),history$1=ref(null),selectMode=ref(SELECT_MODE.single),selectedLayers=ref([]),layerActions=ref(null),categories=ref(null),textures=ref(null),editorView=ref(EDITOR_VIEWS.main),cameraView=ref(null),showLayersManager=computed(()=>!(selectedTool.value&¤tContext.value===EDITOR_CONTEXT.editMode)),showLayerActions=computed(()=>selectedLayers.value),selectedLayerUids=computed(()=>selectedLayers.value?selectedLayers.value.map(x=>x.uid):void 0);events$3.on(`liveryEditor_OnLayersUpdated`,data=>{console.log(`liveryEditor_OnLayersUpdated`,data),layers$1.value=data}),events$3.on(`liveryEditor_Layers_OnVisibleCountChanged`,data=>{console.log(`liveryEditor_Layers_OnVisibleCountChanged`,data),visibleLayersCount.value=data}),events$3.on(`LiveryEditor_onSaveFileLoaded`,data=>{console.log(`LiveryEditor_onSaveFileLoaded`,data),currentFile.value=data}),events$3.on(`LiveryEditorLayersUpdate`,data=>{console.log(`LiveryEditorLayersUpdated`,data),layers$1.value=data}),events$3.on(`LiveryEditor_SelectedLayersDataUpdated`,async data=>{console.log(`LiveryEditor_SelectedLayersDataUpdated`,data),selectedLayers.value=data&&Array.isArray(data)?data:void 0}),events$3.on(`LiverEditorLayerActionsUpdated`,async data=>{console.log(`LiverEditorLayerActionsUpdated`,data)}),events$3.on(`LiveryEditor_onHistoryUpdated`,data=>{console.log(`LiveryEditor_onHistoryUpdated`,data),history$1.value=data}),events$3.on(`LiveryEditor_SelectedLayersChanged`,data=>{console.log(`selected Layer Updated`,data),currentContext.value=data&&data.length>0?EDITOR_CONTEXT.selectedLayer:null}),events$3.on(`LiveryEditorToolChanged`,data=>{console.log(`LiverEditorToolChanged`,data),selectedTool.value=data}),events$3.on(`LiveryEditor_OnCameraChanged`,data=>{console.log(`LiverEditorToolChanged`,data),cameraView.value=data});let dismissLayerActions=async()=>{await Lua_default.extensions.ui_liveryEditor_selection.clearSelection()},toggleEditModeLayout=async enable=>{enable=typeof enable==`boolean`?enable:currentContext.value===EDITOR_CONTEXT.default,enable?(currentContext.value=EDITOR_CONTEXT.editMode,editorView.value=EDITOR_VIEWS.editMode):(currentContext.value=EDITOR_CONTEXT.default,editorView.value=EDITOR_VIEWS.default)};function toggleShowDecalSelector(){editorView.value===EDITOR_VIEWS.decalSelector?editorView.value=EDITOR_VIEWS.editMode:editorView.value=EDITOR_VIEWS.decalSelector}let requestDismissLayerActions=()=>{currentContext.value===EDITOR_CONTEXT.newLayer?currentContext.value=null:currentContext.value===EDITOR_CONTEXT.selectedLayer&&(selectedLayers.value=[])},selectSingle=async layerUid=>{await Lua_default.extensions.ui_liveryEditor_selection.setSelected(layerUid)},toggleVisibility=async layer=>await Lua_default.extensions.ui_liveryEditor_tools_settings.toggleVisibilityById(layer.id),toggleLock=async layer=>await Lua_default.extensions.ui_liveryEditor_tools_settings.toggleLockById(layer.id),changeOrder=async(layer,direction$1)=>{direction$1===-1?await Lua_default.extensions.ui_liveryEditor_tools_group.moveOrderUpById(layer.uid):direction$1===1&&await Lua_default.extensions.ui_liveryEditor_tools_group.moveOrderDownById(layer.uid)},startEditor=async()=>{if(await Lua_default.extensions.ui_liveryEditor_editor.startEditor(),await Lua_default.extensions.ui_liveryEditor_editor.startSession(),currentContext.value=EDITOR_CONTEXT.default,editorView.value=EDITOR_VIEWS.default,await CAMERA_LUA.setOrthographicView(`right`),categories.value=await Lua_default.extensions.ui_liveryEditor_resources.getTextureCategories(),categories.value&&categories.value.length>0){let firstCategory=categories.value[0];setTexturesByCategory(firstCategory.value)}};async function setTexturesByCategory(category){textures.value=(await Lua_default.extensions.ui_liveryEditor_resources.getTexturesByCategory(category)).items}let createSaveFile=async filename=>{await Lua_default.extensions.ui_liveryEditor_userData.createSaveFile(filename)},useTool=async(toolName,params)=>{await Lua_default.extensions.ui_liveryEditor_tools.useTool(toolName)};async function onActionItemSelected(action){if(!action.items){let firstSelected=selectedLayers.value&&selectedLayers.value.length>0?selectedLayers.value[0]:null;if(action.value===`delete`)await openConfirmation(`Delete Layer`,`Are you sure you want to delete ${firstSelected.name}?`)&&await Lua_default.extensions.ui_liveryEditor_tools_settings.deleteLayer();else if(action.value===`rename`){let res=await openRenameLayerDialog(`Rename Layer`,``,{name:firstSelected.name},model=>model.name!==null&&model.name!==void 0&&model.name!==``&&model.name!==firstSelected.name);res.value&&await Lua_default.extensions.ui_liveryEditor_tools_settings.rename(res.formData.name)}else action.value===`duplicate`?await SELECTION_LUA.duplicateSelectedLayer():action.value===`visibility`?await SETTINGS_LUA.toggleVisibility():action.value===`highlight`?await SELECTION_LUA.toggleHighlightSelectedLayer():await Lua_default.extensions.ui_liveryEditor_tools.useTool(action.value)}}let editorState=reactive({isOpenExitDialog:!1,exitDialogResult:null,saving:!1});async function openExitDialog(){let res=await openFormDialog(ExitEditorDialog_default,ref({name:currentFile.value?currentFile.value.name:void 0,applySkin:!!(currentFile.value&¤tFile.value.name)}),form=>!form||!form.name?{error:!0,message:`Invalid Save Name`}:{error:!1},`Exit Editor`,null,[{label:`Cancel`,value:-1,extras:{cancel:!0,accent:ACCENTS.secondary}},{label:`Save and Exit`,value:1,emitData:!0,disableIfInvalid:!0,extras:{icon:icons.saveAs1}},{label:`Exit`,value:0,emitData:!0,extras:{accent:ACCENTS.attention,icon:icons.exit}}]);return res.value===-1?!1:(res.value===1&&await EDITOR_LUA.save(res.formData.name),res.formData.applySkin&&await EDITOR_LUA.applySkin(),await exit(),!0)}async function save(forceOpenPopup=!1){if(!currentFile.value||!currentFile.value.name||forceOpenPopup){editorState.isOpenExitDialog=!0;let res=await openEditFileDialog(`Save file`,`Enter name of your new save file`,{name:currentFile.value?currentFile.value.name:createFilename()},model=>model.name!==null&&model.name!==void 0&&model.name!==``);return res.value&&(editorState.saving=!0,await Lua_default.extensions.ui_liveryEditor_editor.save(res.formData.name),editorState.saving=!1),editorState.isOpenExitDialog=!1,res.value}else await Lua_default.extensions.ui_liveryEditor_editor.save(currentFile.value.name)}async function exit(){router_default.replace({name:`garagemode`}),await Lua_default.extensions.ui_liveryEditor_editor.exitEditor()}function createFilename(){let currentDate=new Date;return`${currentDate.getFullYear()}-${String(currentDate.getMonth()+1).padStart(2,`0`)}-${String(currentDate.getDate()).padStart(2,`0`)}_${String(currentDate.getHours()).padStart(2,`0`)}-${String(currentDate.getMinutes()).padStart(2,`0`)}-${String(currentDate.getSeconds()).padStart(2,`0`)}`}return{...SELECTION_LUA,...CAMERA_LUA,...SETTINGS_LUA,layers:layers$1,visibleLayersCount,layerActions,selectedTool,currentFile,currentContext,textures,categories,editorView,showLayersManager,showLayerActions,cameraView,editorState,dismissLayerActions,setTexturesByCategory,toggleEditModeLayout,toggleShowDecalSelector,requestDismissLayerActions,onActionItemSelected,selectMode,selectedLayers,selectedLayerUids,createSaveFile,toggleVisibility,toggleLock,startEditor,save,useTool,selectSingle,changeOrder,openExitDialog}}),SORT_OPTIONS=Object.freeze({name:`name`,modified:`modified`}),useLiveryFileStore=defineStore(`liveryFile`,()=>{let{events:events$3}=useBridge(),dataFiles=ref(null),sortKey=ref(SORT_OPTIONS.modified),sortDesc=ref(!0),files=computed(()=>{if(!dataFiles.value)return[];let sortOrder=sortDesc.value?-1:1;return dataFiles.value.sort((a$1,b)=>a$1[sortKey.value]b[sortKey.value]?1*sortOrder:0)}),init$3=async()=>{await Lua_default.extensions.ui_liveryEditor_userData.requestUpdatedData()},loadFile=async file$1=>await Lua_default.extensions.ui_liveryEditor_editor.loadFile(file$1.location),renameFile=async(file$1,newFilename)=>{await Lua_default.extensions.ui_liveryEditor_userData.renameFile(file$1.name,newFilename)},deleteFile=async file$1=>{await Lua_default.extensions.ui_liveryEditor_userData.deleteSaveFile(file$1.name)};events$3.on(`LiverySaveFilesUpdated`,data=>{data&&Array.isArray(data)&&data.length>0?(data.forEach(x=>{x.modifiedFormatted=formatDateTime(x.modified),x.fileSizeFormatted=formatSize(x.fileSize)}),dataFiles.value=data):dataFiles.value=[]});function formatDateTime(unixTime){let datetime=new Date(unixTime*1e3);return`${datetime.toLocaleDateString()} ${datetime.toLocaleTimeString()}`}function formatSize(bytes){return`${(bytes/1024).toFixed(2)} KB`}return{files,sortKey,sortDesc,init:init$3,loadFile,renameFile,deleteFile}});var EDITOR_RESOURCES_LUA=Lua_default.extensions.ui_liveryEditor_resources;const useDecalSelectorStore=defineStore(`liveryEditorDecalSelector`,()=>{let{events:events$3}=useBridge(),categories=ref(null),currentCategory=ref(null),isShow=ref(!1),textures=computed(()=>{if(!categories.value)return;let category=categories.value.find(x=>x.value===currentCategory.value);return category?category.items:void 0});async function init$3(){if(categories.value=await EDITOR_RESOURCES_LUA.getTextureCategories(),categories.value&&Array.isArray(categories.value)&&categories.value.length>0){let first=categories.value[0].value;await setCategory(first)}}async function setCategory(category){await fetchTextures(category),currentCategory.value=category}async function fetchTextures(category){let index=categories.value.findIndex(x=>x.value===category);if(index===-1)return;let textures$1=categories.value[index].items;if(index>=0&&(!textures$1||!textures$1.length===0)){let categoryWithTextures=await EDITOR_RESOURCES_LUA.getTexturesByCategory(category);categories.value[index].items=categoryWithTextures.items}}async function toggle(){isShow.value=!isShow.value,events$3.emit(`liveryEditor_onDecalStateChanged`,{show:isShow.value})}async function selectDecalItem(texturePath){await Lua_default.extensions.ui_liveryEditor_layerEdit.setup(),await Lua_default.extensions.ui_liveryEditor_layerEdit.editNewDecal({texturePath})}async function cancelSelection(){events$3.emit(`liveryEditor_onDecalSelectorCancelled`)}return{categories,currentCategory,textures,isShow,init:init$3,toggle,setCategory,selectDecalItem,cancelSelection}});var DEFAULT_ACCELERATION_RATE=.75,DEFAULT_ACCELERATION_NATURE=1.75,DEFAULT_ACTION_INTERVAL_MS=150,FOCUS_LD_TRIGGER_VALUE$2=-.5,FOCUS_RU_TRIGGER_VALUE$2=.5;const ACTION_PARAMS_TYPE={xyPoints:`xyPoints`,xPoint:`xPoint`},useActionHoldService=defineStore(`actionHoldService`,()=>{let data=ref({}),start=id=>{if(!data.value[id])throw Error(`Error starting hold action ${id}. Id not found.`);data.value[id].holdFn=setInterval(createHoldFn(id),data.value[id].actionInterval)},reset$1=id=>{let action=data.value[id];action&&(action.holdFn&&clearInterval(action.holdFn),data.value[id].holdFn=null,data.value[id].holdTimeMs=0)},add$2=(id,actionFn,immediateStart=!1,options={actionInterval:DEFAULT_ACTION_INTERVAL_MS,accelerationRate:DEFAULT_ACCELERATION_RATE,accelerationNature:DEFAULT_ACCELERATION_NATURE})=>{if(data.value[id])throw Error(`Error adding hold action for ${id}. Id already exists.`);data.value[id]={actionFn,...options,holdTimeMs:0,holdFn:null},immediateStart&&start(id)},remove$3=id=>{data.value[id]&&(reset$1(id),delete data.value[id])},removeAll=id=>{remove$3(id),remove$3(getFocusScalarName(id)),remove$3(getFocusScalarXName(id)),remove$3(getFocusScalarYName(id))},clear=()=>{let keys=Object.keys(data.value);for(let i=0;i{data.value[id]&&remove$3(id),add$2(id,actionFn,immediateStart,options)},onFocus=(id,actionFn,element,actionParamsType=ACTION_PARAMS_TYPE.xyPoints)=>{if(remove$3(getFocusScalarXName(id)),remove$3(getFocusScalarYName(id)),element.detail.value===0){remove$3(id);return}let eventName=element.detail.name,xDirection=0,yDirection=0;switch(eventName){case`focus_l`:xDirection=-1;break;case`focus_r`:xDirection=1;break;case`focus_d`:yDirection=-1;break;case`focus_u`:yDirection=1;break}switch(actionParamsType){case ACTION_PARAMS_TYPE.xyPoints:actionFn(xDirection,yDirection),addOrUpdate(id,multiplier=>actionFn(xDirection*multiplier,yDirection*multiplier),!0);break;case ACTION_PARAMS_TYPE.xPoint:let xValue=xDirection===0?yDirection:xDirection;xValue!==0&&(actionFn(xValue),addOrUpdate(id,multiplier=>actionFn(xValue*multiplier),!0));break}},inputNavStates=reactive({xLatestValue:0,yLatestValue:0,latestEventName:null}),onFocusScalar=(id,actionFn,element,actionParamsType=ACTION_PARAMS_TYPE.xyPoints)=>{console.log(`onFocusScalar`,{id,name:element.detail.name,value:element.detail.value}),remove$3(id);let eventName=element.detail.name,eventValue=element.detail.value;if(inputNavStates.latestEventName===eventName&&((eventName===`focus_lr`||eventName===`rotate_h_cam`)&&eventValue===inputNavStates.xLatestValue||(eventName===`focus_ud`||eventName===`rotate_v_cam`)&&eventValue===inputNavStates.yLatestValue))return;let xDirection=0,yDirection=0;if(eventName===`focus_lr`||eventName===`rotate_h_cam`){if(eventValue>FOCUS_RU_TRIGGER_VALUE$2&&eventValue>inputNavStates.xLatestValue?xDirection=1:eventValueactionFn(xDirection*multiplier,0),!0);break;case ACTION_PARAMS_TYPE.xPoint:actionFn(xDirection),addOrUpdate(getFocusScalarXName(id),multiplier=>actionFn(xDirection*multiplier),!0);break}inputNavStates.latestEventName=eventName}else remove$3(getFocusScalarXName(id));inputNavStates.xLatestValue=eventValue}else (eventName===`focus_ud`||eventName===`rotate_v_cam`)&&actionParamsType!==ACTION_PARAMS_TYPE.xPoint&&(eventValue>FOCUS_RU_TRIGGER_VALUE$2&&eventValue>inputNavStates.yLatestValue?yDirection=1:eventValueactionFn(0,yDirection*multiplier),!0),inputNavStates.latestEventName=eventName),inputNavStates.yLatestValue=eventValue)};function createHoldFn(id){let action=data.value[id];return()=>{let multiplier=1+action.accelerationRate*(action.holdTimeMs/1e3)**action.accelerationNature;action.actionFn(multiplier),data.value[id].holdTimeMs=action.holdTimeMs+action.actionInterval}}function getFocusScalarName(id){return`${id}_scalar`}function getFocusScalarXName(id){return`${getFocusScalarName(id)}_x`}function getFocusScalarYName(id){return`${getFocusScalarName(id)}_y`}return{onFocus,onFocusScalar,add:add$2,addOrUpdate,remove:remove$3,removeAll,clear,start,reset:reset$1}}),HEADER_SECTION_TYPE={start:`start`,center:`center`,end:`end`},useEditorHeaderStore=defineStore(`editorHeader`,()=>{let header=reactive({heading:null,preheading:[],type:`line`}),headerItems=ref([]),startSectionItems=computed(()=>headerItems.value.filter(x=>x.section===HEADER_SECTION_TYPE.start)),centerSectionItems=computed(()=>headerItems.value.filter(x=>x.section===HEADER_SECTION_TYPE.center)),endSectionItems=computed(()=>headerItems.value.filter(x=>x.section===HEADER_SECTION_TYPE.end)),headerHidden=ref(!1),itemsHidden=ref(!1),setHeader=(heading,headerType=`line`)=>{header.heading=heading,header.type=headerType},setPreheader=text=>{typeof text==`string`?header.preheading=[text]:header.preheading=text},addItems=(items$2,prepend=!1)=>{prepend?headerItems.value.unshift(...items$2):headerItems.value.push(...items$2)},addItem=(item,prepend=!1)=>{prepend?headerItems.value.unshift(item):headerItems.value.push(item)},addOrUpdateItem=(item,prepend=!1,prependIdOrIndex=0)=>{let existingIndex=-1;if(headerItems.value&&(existingIndex=headerItems.value.findIndex(x=>x.id===item.id)),existingIndex>-1)headerItems.value[existingIndex]={...item};else if(prepend){let preprendIdIndex=findIdOrIndex(prependIdOrIndex);headerItems.value.splice(preprendIdIndex,0,item)}else headerItems.value.push(item)},removeItem=itemOrId=>{let id=itemOrId.hasOwnProperty(`id`)?itemOrId.id:itemOrId,index=headerItems.value.findIndex(x=>x.id===id);index>-1&&headerItems.value.splice(index,1)},removeItems=itemsOrIds=>itemsOrIds.forEach(x=>removeItem(x)),removeItemsExcept=itemsOrIds=>{let ids=itemsOrIds.map(x=>x.hasOwnProperty(`id`)?x.id:x);removeItems(items.value.filter(x=>!ids.includes(x.id)))},showItem=itemOrId=>{let index=findIdOrIndex(itemOrId);index>-1&&(headerItems.value[index].hidden=!1)},hideItem=itemOrId=>{let index=findIdOrIndex(itemOrId);index>-1&&(headerItems.value[index].hidden=!0)},clearItems=()=>headerItems.value=[],getItem=id=>items.value.find(x=>x.id===id);function findIdOrIndex(idOrIndex){let prependIdIndex=headerItems.value.findIndex(x=>x.id===idOrIndex);return prependIdIndex===-1&&typeof idOrIndex==`number`&&idOrIndex>-1&&idOrIndex{let Controls=controls_default(),{events:events$3}=useBridge(),isSetupDone=ref(!1),{isControllerAvailable}=storeToRefs(Controls),currentSave=ref(initCurrentSave()),isLayerEditInitialized=ref(!1);watch(isControllerAvailable,async available=>{available&&await Lua_default.extensions.ui_liveryEditor.useMousePosition(!1)},{immediate:!0});async function onSetupDone(){isControllerAvailable.value&&await Lua_default.extensions.ui_liveryEditor.useMousePosition(!1)}function load(file$1){currentSave.value=file$1,isSetupDone.value=!1}function onChangeView(view){console.log(`onChangeView`,view),router_default.push({name:view})}async function setup$3(){isSetupDone.value||=(events$3.on(`liveryEditor_SetupSuccess`,onSetupDone),events$3.on(`liveryEditor_changeView`,onChangeView),await Lua_default.extensions.ui_liveryEditor.setup(currentSave.value.location),!0)}async function save(){await Lua_default.extensions.ui_liveryEditor.save(currentSave.value.name)}async function exit(){isSetupDone.value=!1,resetSave(),await Lua_default.extensions.ui_liveryEditor.deactivate()}async function setupLayerEdit(){isLayerEditInitialized.value||=(await Lua_default.extensions.ui_liveryEditor_camera.setOrthographicView(`right`),!0)}async function exitLayerEdit(){isLayerEditInitialized.value=!1}function resetSave(){currentSave.value=initCurrentSave()}function initCurrentSave(){return{name:createFilename(),location:null}}function dispose$2(){events$3.off(`liveryEditor_SetupSuccess`,onSetupDone)}function createFilename(){let currentDate=new Date;return`${currentDate.getFullYear()}-${String(currentDate.getMonth()+1).padStart(2,`0`)}-${String(currentDate.getDate()).padStart(2,`0`)}_${String(currentDate.getHours()).padStart(2,`0`)}-${String(currentDate.getMinutes()).padStart(2,`0`)}-${String(currentDate.getSeconds()).padStart(2,`0`)}`}return{currentSave,isSetupDone,load,setupLayerEdit,exitLayerEdit,save,exit,setup:setup$3,resetSave,dispose:dispose$2}});var _sfc_main$112=Object.assign({width:8,height:8,margin:.25},{__name:`DecalSelectorItem`,props:{externalImage:String},setup(__props){let props=__props;return(_ctx,_cache)=>(openBlock(),createBlock(unref(bngImageTile_default),normalizeProps(guardReactiveProps(props)),null,16))}}),DecalSelectorItem_default=_sfc_main$112,_hoisted_1$102={"bng-ui-scope":`liveryeditor-decal-selector`,class:`decal-selector`},_hoisted_2$86={class:`header-wrapper`},_hoisted_3$75={key:0,class:`filters-wrapper`},_sfc_main$111={__name:`DecalSelector`,setup(__props){useUINavScope(`liveryeditor-decal-selector`);let store$1=useDecalSelectorStore(),headerStore=useEditorHeaderStore(),selectedCategory=computed({get:()=>[store$1.currentCategory],async set(values){await store$1.setCategory(values[0])}}),switchCategory=direction$1=>{let index=store$1.categories.findIndex(x=>x.value===store$1.currentCategory);index!==-1&&(direction$1===-1?index>0?--index:index=store$1.categories.length-1:index{await store$1.init(),getUINavServiceInstance().useCrossfire=!0});let headerItemsHiddenValue=null;return onMounted(()=>{headerItemsHiddenValue=headerStore.itemsHidden,headerStore.itemsHidden||=!0}),onUnmounted(()=>{headerStore.itemsHidden=headerItemsHiddenValue}),(_ctx,_cache)=>withDirectives((openBlock(),createElementBlock(`div`,_hoisted_1$102,[createBaseVNode(`div`,_hoisted_2$86,[createVNode(unref(bngCardHeading_default),{class:`decal-selector-heading`,type:`ribbon`},{default:withCtx(()=>[..._cache[1]||=[createTextVNode(`Select Decal`,-1)]]),_:1}),createVNode(unref(bngButton_default),{"bng-no-nav":!0,accent:`attention`,label:`Close`,onClick:unref(store$1).cancelSelection},{default:withCtx(()=>[createVNode(unref(bngBinding_default),{action:`menu_item_back`})]),_:1},8,[`onClick`])]),unref(store$1).categories?(openBlock(),createElementBlock(`div`,_hoisted_3$75,[createBaseVNode(`div`,null,[createVNode(unref(bngIcon_default),{type:unref(icons).arrowSmallLeft},null,8,[`type`]),createVNode(unref(bngBinding_default),{action:`menu_tab_left`})]),createVNode(bngPillFilters_default,{modelValue:selectedCategory.value,"onUpdate:modelValue":_cache[0]||=$event=>selectedCategory.value=$event,"bng-no-child-nav":!0,options:unref(store$1).categories,required:``},null,8,[`modelValue`,`options`]),createBaseVNode(`div`,null,[createVNode(unref(bngBinding_default),{action:`menu_tab_right`}),createVNode(unref(bngIcon_default),{type:unref(icons).arrowSmallRight},null,8,[`type`])])])):createCommentVNode(``,!0),unref(store$1).textures&&unref(store$1).textures.length>0?(openBlock(),createBlock(unref(bngList_default),{key:1,noBackground:``},{default:withCtx(()=>[(openBlock(!0),createElementBlock(Fragment,null,renderList(unref(store$1).textures,(item,index)=>withDirectives((openBlock(),createBlock(DecalSelectorItem_default,{"bng-nav-item":``,key:item.preview,externalImage:item.preview,"data-decal-item":index,onClick:()=>unref(store$1).selectDecalItem(item.preview)},null,8,[`externalImage`,`data-decal-item`,`onClick`])),[[unref(BngOnUiNav_default),void 0,`ok`,{asMouse:!0,focusRequired:!0}]])),128))]),_:1})):createCommentVNode(``,!0)])),[[unref(BngBlur_default)],[unref(BngOnUiNav_default),()=>unref(store$1).cancelSelection(),`menu`],[unref(BngOnUiNav_default),()=>unref(store$1).cancelSelection(),`back`],[unref(BngOnUiNav_default),()=>switchCategory(-1),`tab_l`],[unref(BngOnUiNav_default),()=>switchCategory(1),`tab_r`]])}},DecalSelector_default=__plugin_vue_export_helper_default(_sfc_main$111,[[`__scopeId`,`data-v-e09a2ff1`]]),_hoisted_1$101={class:`decal-preview-tile`},_sfc_main$110={__name:`DecalPreviewTile`,props:{textureImage:{type:String,required:!0},textureColor:{type:Array,default:[255,255,255,1]},backgroundImage:String},setup(__props){useCssVars(_ctx=>({v036f09bc:alphaTextureBackground.value,v06c06c52:imgColor.value,v174dbaea:imageUrl.value}));let props=__props,alphaTextureBackground=computed(()=>`url(${props.backgroundImage?props.backgroundImage:getAssetURL(`images/alpha_texture.png`)}`),imageUrl=computed(()=>`url(${props.textureImage})`),imgColor=computed(()=>{let isDecimalFormat=props.textureColor.every(x=>x>=0&&x<=1),red=props.textureColor[0],green=props.textureColor[1],blue=props.textureColor[2],alpha=props.textureColor[3];return isDecimalFormat&&(red=Math.floor(red*255),green=Math.floor(green*255),blue=Math.floor(blue*255)),`rgba(${red}, ${green}, ${blue}, ${alpha})`});return(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$101,[..._cache[0]||=[createBaseVNode(`div`,{class:`image`},null,-1)]]))}},DecalPreviewTile_default=__plugin_vue_export_helper_default(_sfc_main$110,[[`__scopeId`,`data-v-8377c081`]]),_hoisted_1$100=[`disabled`],_sfc_main$109={__name:`EditModeLayersPreview`,props:{contextMenuName:String},setup(__props){let store$1=useLayerSettingsStore(),scroller=ref(null),tiles=ref({}),disabled=computed(()=>store$1.requestApplyActive||store$1.reapplyActive),onLayerClicked=async layer=>{store$1.activeLayerUid===layer.uid&&store$1.appliedLayers.length>1||await store$1.setActiveLayer(layer.uid)};watch(()=>store$1.activeLayerUid,layerUid=>{layerUid&&scrollTo(layerUid)});function setTileRef(layerUid,el){tiles.value[layerUid]=el}function scrollTo(layerUid){let tileEl=tiles.value[layerUid];if(!tileEl)return;let scrollerOffsetBottom=scroller.value.offsetTop+scroller.value.offsetHeight,scrollerOffsetTop=scroller.value.offsetTop+scroller.value.scrollTop,tileElOffsetBottom=tileEl.offsetTop+tileEl.offsetHeight,overflowsTop=tileEl.offsetTopscrollerOffsetBottom;!overflowsTop&&!overflowsBottom||window.requestAnimationFrame(()=>{overflowsTop?scroller.value.scrollBy({top:-(scrollerOffsetTop-tileEl.offsetTop)}):overflowsBottom&&(scroller.value.scrollTop=tileElOffsetBottom-scrollerOffsetBottom)})}return(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,{class:`layers-preview`,disabled:disabled.value},[createBaseVNode(`div`,{class:`item-navigation navigation-up`,onClick:_cache[0]||=$event=>unref(store$1).setActiveLayerDirection(-1)},[createVNode(unref(bngIcon_default),{type:unref(icons).arrowSmallUp},null,8,[`type`]),createVNode(unref(bngBinding_default),{action:`activate_previous_layer`,deviceMask:`xinput`,class:`navigation-icon`})]),createBaseVNode(`div`,{ref_key:`scroller`,ref:scroller,class:`preview-scroller`},[(openBlock(!0),createElementBlock(Fragment,null,renderList(unref(store$1).appliedLayers,layer=>(openBlock(),createElementBlock(`div`,{ref_for:!0,ref:el=>setTileRef(layer.uid,el),key:layer.uid,class:normalizeClass([{active:unref(store$1).activeLayerUid===layer.uid},`layer-item`])},[unref(store$1).activeLayerUid===layer.uid?withDirectives((openBlock(),createBlock(DecalPreviewTile_default,{key:0,class:`preview-img`,textureImage:layer.preview,textureColor:layer.color},null,8,[`textureImage`,`textureColor`])),[[unref(BngPopover_default),`context-menu`,`right`,{click:!0}]]):(openBlock(),createBlock(DecalPreviewTile_default,{key:1,class:`preview-img`,textureImage:layer.preview,textureColor:layer.color,onClick:()=>onLayerClicked(layer)},null,8,[`textureImage`,`textureColor`,`onClick`])),unref(store$1).activeLayerUid===layer.uid?(openBlock(),createBlock(unref(bngIcon_default),{key:2,class:`contextmenu-icon`,type:unref(icons).edit},null,8,[`type`])):createCommentVNode(``,!0)],2))),128))],512),createBaseVNode(`div`,{class:`item-navigation navigation-down`,onClick:_cache[1]||=$event=>unref(store$1).setActiveLayerDirection(1)},[createVNode(unref(bngBinding_default),{action:`activate_next_layer`,deviceMask:`xinput`,class:`navigation-icon`}),createVNode(unref(bngIcon_default),{type:unref(icons).arrowSmallDown},null,8,[`type`])])],8,_hoisted_1$100))}},EditModeLayersPreview_default=__plugin_vue_export_helper_default(_sfc_main$109,[[`__scopeId`,`data-v-9ede6133`]]),_hoisted_1$99={class:`material-settings`,"bng-ui-scope":`material-settings`},_hoisted_2$85={class:`subsettings-selector`},_hoisted_3$74=[`onClick`],_hoisted_4$57={class:`settings-content`},_hoisted_5$47={key:0,class:`setting-item color-setting`},_hoisted_6$34={key:1,class:`setting-item item-column`},_hoisted_7$29={class:`slider-text-container`},_hoisted_8$22={key:2,class:`setting-item item-column`},_hoisted_9$19={class:`slider-text-container`},_hoisted_10$13={key:3,class:`setting-item item-column`},_hoisted_11$11={class:`slider-text-container`},INPUT_CONTROL_STEPS$4=.01,INPUT_CONTROL_MIN$4=0,INPUT_CONTROL_MAX$4=1,CONTROLLER_SLIDER_BINDING=`focus_lr`,CONTROLLER_CHANGE_SUBSETTINGS_HINTS=[{id:`activate_previous_subsettings`,content:{type:`binding`,props:{uiEvent:`focus_u`},label:`Previous Setting`}},{id:`activate_next_subsettings`,content:{type:`binding`,props:{uiEvent:`focus_d`},label:`Next Setting`}}],subSettings=[{label:`Color`,icon:icons.colorCirclePalette,value:`color`},{label:`Saturation`,icon:icons.colorSaturation,value:`saturation`},{label:`Metalness`,icon:icons.materialMetal,value:`metallicIntensity`},{label:`Roughness`,icon:icons.materialRoughness,value:`roughnessIntensity`}],_sfc_main$108={__name:`LayerMaterialSettings`,emits:[`subSettingChanged`],setup(__props,{emit:__emit}){let emit$1=__emit,store$1=useLayerSettingsStore(),actionHoldService=useActionHoldService(),{showIfController}=storeToRefs(controls_default()),infoBar=useInfoBar(),activeSubSettingsIndex=ref(0),_color=reactive({hue:.5,saturation:1,luminosity:.5}),color=computed({get:()=>_color,set:async newValue=>{let paint=new Paint;paint.hsl=[newValue.hue,newValue.saturation,newValue.luminosity],await store$1.setColor([paint.red,paint.green,paint.blue,paint.alpha])}}),saturation=computed({get:()=>_color.saturation,set:async newValue=>{let sat=parseFloat(newValue.toFixed(2));color.value={hue:color.value.hue,saturation:sat,luminosity:color.value.luminosity},_color.saturation=sat}}),metallicIntensity=computed({get:()=>store$1.cursorData?store$1.cursorData.metallicIntensity:void 0,set:async newValue=>{await store$1.setMetallicIntensity(newValue)}}),roughnessIntensity=computed({get:()=>store$1.cursorData?store$1.cursorData.roughnessIntensity:void 0,set:async newValue=>{await store$1.setRoughnessIntensity(newValue)}}),activeSubSetting=computed(()=>subSettings[activeSubSettingsIndex.value]);watch(()=>store$1.activeLayerUid,(newValue,oldValue)=>{newValue&&oldValue&&initColorPicker(store$1.cursorData.color)},{deep:!0}),watch(activeSubSetting,(value,oldValue)=>{oldValue&&actionHoldService.remove(oldValue),setHints(),emit$1(`subSettingChanged`,value)},{immediate:!0}),onBeforeUnmount(()=>{actionHoldService.removeAll(`color`),actionHoldService.removeAll(`saturation`),actionHoldService.removeAll(`metallicIntensity`),actionHoldService.removeAll(`roughnessIntensity`),emit$1(`subSettingChanged`,void 0)}),onMounted(()=>{store$1.cursorData.color&&initColorPicker(store$1.cursorData.color)});let goPreviousSubSetting=()=>{activeSubSettingsIndex.value>0?--activeSubSettingsIndex.value:activeSubSettingsIndex.value=subSettings.length-1},goNextSubSetting=()=>{activeSubSettingsIndex.valuechangeColor(hue,luminosity,0);break;case`saturation`:actionFn=saturation$1=>changeColor(0,0,saturation$1);break;case`metallicIntensity`:actionFn=changeMetallicIntensity,actionParamsType=ACTION_PARAMS_TYPE.xPoint;break;case`roughnessIntensity`:actionFn=changeRoughnessIntensity,actionParamsType=ACTION_PARAMS_TYPE.xPoint;break}scalar?actionHoldService.onFocusScalar(subsettingValue,actionFn,element,actionParamsType):actionHoldService.onFocus(subsettingValue,actionFn,element,actionParamsType)}}async function changeColor(h$1,l,s){let newHue=color.value.hue+.01*h$1,newLuminosity=color.value.luminosity+.01*l,newSaturation=parseFloat((color.value.saturation+.1*s).toFixed(2));(newHue<0||newHue>1)&&(newHue=color.value.hue),(newLuminosity<0||newLuminosity>1)&&(newLuminosity=color.value.luminosity),(newSaturation<0||newSaturation>1)&&(newSaturation=color.value.saturation),_color.hue=newHue,_color.saturation=newSaturation,_color.luminosity=newLuminosity;let paint=new Paint;paint.hsl=[newHue,newSaturation,newLuminosity],store$1.setColor([paint.red,paint.green,paint.blue,paint.alpha])}let changeMetallicIntensity=direction$1=>{let newValue=metallicIntensity.value+.1*direction$1;newValue>=0&&newValue<=1&&(metallicIntensity.value=newValue)},changeRoughnessIntensity=direction$1=>{let newValue=roughnessIntensity.value+.1*direction$1;newValue>=0&&newValue<=1&&(roughnessIntensity.value=newValue)};function updateColorPickerModel(rgba){let paint=new Paint;paint.rgba=rgba,_color.hue=paint.hue,_color.saturation=paint.saturation,_color.luminosity=paint.luminosity}store$1.$onAction(({name,store:store$2,args,after,onError})=>{after(result=>{name===`resetCursorProperties`&&args[0].includes(`material`)&&initColorPicker(store$2.cursorData.color)})});function onReset(){let defaultColor=[1,1,1,1];switch(activeSubSetting.value.value){case`color`:store$1.setColor(defaultColor),updateColorPickerModel(defaultColor),saturation.value=1;break;case`saturation`:saturation.value=1;break;case`metallicIntensity`:metallicIntensity.value=0;break;case`roughnessIntensity`:roughnessIntensity.value=0;break}}function onTertiaryAction(){if(store$1.reapplyActive||store$1.requestApplyActive)onReset();else return!0}function initColorPicker(color$1){let isWhite=color$1.every(x=>x===1),paint=new Paint;paint.rgba=color$1,_color.hue=paint.hue,_color.saturation=isWhite?1:paint.saturation,_color.luminosity=paint.luminosity}useUINavScope(`material-settings`);let useCrossfireValue;onBeforeMount(()=>{useCrossfireValue=getUINavServiceInstance().useCrossfire,getUINavServiceInstance().useCrossfire=!1}),onBeforeUnmount(()=>{getUINavServiceInstance().useCrossfire=useCrossfireValue});let unwatchGamepad;onBeforeMount(()=>{unwatchGamepad=watch(showIfController,async()=>{await nextTick(()=>setHints())},{immediate:!0})}),onUnmounted(()=>{unwatchGamepad&&unwatchGamepad(),removeHints()});function setHints(){removeHints(),showIfController.value&&infoBar.addHints(CONTROLLER_CHANGE_SUBSETTINGS_HINTS)}function removeHints(){infoBar.removeHints(...CONTROLLER_CHANGE_SUBSETTINGS_HINTS.map(x=>x.id))}return(_ctx,_cache)=>withDirectives((openBlock(),createElementBlock(`div`,_hoisted_1$99,[createBaseVNode(`div`,_hoisted_2$85,[(openBlock(),createElementBlock(Fragment,null,renderList(subSettings,(subtab,index)=>withDirectives(createBaseVNode(`div`,{key:subtab.value,class:normalizeClass([{active:index===activeSubSettingsIndex.value},`subsettings-selector-item`]),onClick:()=>activeSubSettingsIndex.value=index},[createVNode(unref(bngIcon_default),{type:subtab.icon,class:`selector-item-icon`},null,8,[`type`])],10,_hoisted_3$74),[[unref(BngTooltip_default),index===activeSubSettingsIndex.value?void 0:subtab.label,`left`]])),64))]),createBaseVNode(`div`,_hoisted_4$57,[activeSubSetting.value.value===`color`?(openBlock(),createElementBlock(`div`,_hoisted_5$47,[createVNode(unref(bngColorPicker_default),{modelValue:color.value,"onUpdate:modelValue":_cache[0]||=$event=>color.value=$event,view:`luminosity`},null,8,[`modelValue`])])):createCommentVNode(``,!0),activeSubSetting.value.value===`saturation`?(openBlock(),createElementBlock(`div`,_hoisted_6$34,[createBaseVNode(`div`,_hoisted_7$29,[createVNode(unref(bngSlider_default),{modelValue:saturation.value,"onUpdate:modelValue":_cache[1]||=$event=>saturation.value=$event,min:INPUT_CONTROL_MIN$4,max:INPUT_CONTROL_MAX$4,step:INPUT_CONTROL_STEPS$4},null,8,[`modelValue`]),createVNode(unref(bngInput_default),{modelValue:saturation.value,"onUpdate:modelValue":_cache[2]||=$event=>saturation.value=$event,type:`number`,min:INPUT_CONTROL_MIN$4,max:INPUT_CONTROL_MAX$4,step:INPUT_CONTROL_STEPS$4},null,8,[`modelValue`]),createVNode(unref(bngBinding_default),{uiEvent:CONTROLLER_SLIDER_BINDING,deviceMask:`xinput`})])])):activeSubSetting.value.value===`metallicIntensity`?(openBlock(),createElementBlock(`div`,_hoisted_8$22,[createBaseVNode(`div`,_hoisted_9$19,[createVNode(unref(bngSlider_default),{modelValue:metallicIntensity.value,"onUpdate:modelValue":_cache[3]||=$event=>metallicIntensity.value=$event,min:INPUT_CONTROL_MIN$4,max:INPUT_CONTROL_MAX$4,step:INPUT_CONTROL_STEPS$4},null,8,[`modelValue`]),createVNode(unref(bngInput_default),{modelValue:metallicIntensity.value,"onUpdate:modelValue":_cache[4]||=$event=>metallicIntensity.value=$event,type:`number`,min:INPUT_CONTROL_MIN$4,max:INPUT_CONTROL_MAX$4,step:INPUT_CONTROL_STEPS$4},null,8,[`modelValue`]),createVNode(unref(bngBinding_default),{uiEvent:CONTROLLER_SLIDER_BINDING,deviceMask:`xinput`})])])):activeSubSetting.value.value===`roughnessIntensity`?(openBlock(),createElementBlock(`div`,_hoisted_10$13,[createBaseVNode(`div`,_hoisted_11$11,[createVNode(unref(bngSlider_default),{modelValue:roughnessIntensity.value,"onUpdate:modelValue":_cache[5]||=$event=>roughnessIntensity.value=$event,min:INPUT_CONTROL_MIN$4,max:INPUT_CONTROL_MAX$4,step:INPUT_CONTROL_STEPS$4},null,8,[`modelValue`]),createVNode(unref(bngInput_default),{modelValue:roughnessIntensity.value,"onUpdate:modelValue":_cache[6]||=$event=>roughnessIntensity.value=$event,type:`number`,min:INPUT_CONTROL_MIN$4,max:INPUT_CONTROL_MAX$4,step:INPUT_CONTROL_STEPS$4},null,8,[`modelValue`]),createVNode(unref(bngBinding_default),{uiEvent:CONTROLLER_SLIDER_BINDING,deviceMask:`xinput`})])])):createCommentVNode(``,!0)])])),[[unref(BngOnUiNav_default),goNextSubSetting,`action_2`],[unref(BngOnUiNav_default),onTertiaryAction,`action_3`],[unref(BngOnUiNav_default),onFocus,`focus_l`,{up:!0}],[unref(BngOnUiNav_default),onFocus,`focus_l`,{down:!0}],[unref(BngOnUiNav_default),onFocus,`focus_r`,{down:!0}],[unref(BngOnUiNav_default),onFocus,`focus_r`,{up:!0}],[unref(BngOnUiNav_default),onFocus,`focus_u`,{up:!0}],[unref(BngOnUiNav_default),onFocus,`focus_u`,{down:!0}],[unref(BngOnUiNav_default),onFocus,`focus_d`,{down:!0}],[unref(BngOnUiNav_default),onFocus,`focus_d`,{up:!0}],[unref(BngOnUiNav_default),el=>onFocus(el,!0),`focus_lr`],[unref(BngOnUiNav_default),el=>onFocus(el,!0),`focus_ud`]])}},LayerMaterialSettings_default=__plugin_vue_export_helper_default(_sfc_main$108,[[`__scopeId`,`data-v-ffe74e63`]]),_hoisted_1$98={class:`mirror-settings`,"bng-ui-scope":`mirror-settings`},_hoisted_2$84={class:`setting-item`},_hoisted_3$73={class:`setting-item offset-item`},_hoisted_4$56={class:`setting-item offset-item`},FOCUS_LD_TRIGGER_VALUE$1=-.999,FOCUS_RU_TRIGGER_VALUE$1=.999,FOCUS_HOLD_INTERVAL_MS=250,MIRROR_BINDING=`focus_l`,FLIP_BINDING=`focus_r`,CONTROLLER_OFFSET_BINDING=`focus_ud`,CONTROLLER_HINTS$4=[],KEYBOARD_HINTS$4=[],_sfc_main$107={__name:`LayerMirrorSettings`,setup(__props){let store$1=useLayerSettingsStore(),{showIfController}=storeToRefs(controls_default()),infoBar=useInfoBar(),inputNavStates=reactive({focusXLatestValue:0,focusYLatestValue:0,holdEventLatest:null,holdInterval:null}),mirror=computed({get:()=>store$1.cursorData?store$1.cursorData.mirrored:void 0,set:async newValue=>await store$1.setMirrored(newValue,store$1.cursorData.flipMirroredDecal)}),flip$2=computed({get:()=>store$1.cursorData?store$1.cursorData.flipMirroredDecal:void 0,set:async newValue=>await store$1.setMirrored(store$1.cursorData.mirrored,newValue)}),offset$2=computed({get:()=>store$1.cursorData?store$1.cursorData.mirrorOffset:void 0,set:async newValue=>await store$1.setMirrorOffset(newValue)}),toggleMirror=()=>mirror.value=!mirror.value,toggleFlipped=()=>{mirror.value&&(flip$2.value=!flip$2.value)},changeOffset=element=>{if(!mirror.value)return;let eventName=element.detail.name,direction$1=eventName===`focus_d`?-1:1,isPressed=element.detail.value;inputNavStates.holdEventLatest===eventName&&!isPressed&&inputNavStates.holdInterval&&(clearInterval(inputNavStates.holdInterval),inputNavStates.holdInterval=null),direction$1>0&&isPressed?doHoldAction(()=>store$1.setMirrorOffset(offset$2.value+1),eventName):direction$1<0&&isPressed&&doHoldAction(()=>store$1.setMirrorOffset(offset$2.value-1),eventName)},changeOffsetScalar=element=>{if(!mirror.value)return;let eventName=element.detail.name,direction$1=element.detail.value;inputNavStates.holdEventLatest===eventName&&inputNavStates.holdInterval&&clearInterval(inputNavStates.holdInterval),direction$1>FOCUS_RU_TRIGGER_VALUE$1&&direction$1>inputNavStates.focusXLatestValue?doHoldAction(()=>store$1.setMirrorOffset(offset$2.value+1),eventName):direction$1store$1.setMirrorOffset(offset$2.value-1),eventName),inputNavStates.focusXLatestValue=direction$1};function onReset(){store$1.setMirrored(!1,!1),store$1.setMirrorOffset(0)}function onTertiaryAction(){if(store$1.reapplyActive||store$1.requestApplyActive)onReset();else return!0}function doHoldAction(callbackFn,eventName){inputNavStates.holdInterval&&=(clearInterval(inputNavStates.holdInterval),null),callbackFn(),inputNavStates.holdInterval=setInterval(callbackFn,FOCUS_HOLD_INTERVAL_MS),inputNavStates.holdEventLatest=eventName}useUINavScope(`mirror-settings`);let useCrossfireValue;onBeforeMount(()=>{useCrossfireValue=getUINavServiceInstance().useCrossfire,getUINavServiceInstance().useCrossfire=!1}),onBeforeUnmount(()=>{getUINavServiceInstance().useCrossfire=useCrossfireValue});let unwatchGamepad;onBeforeMount(()=>{unwatchGamepad=watch(showIfController,async()=>{await nextTick(()=>setHints())},{immediate:!0})}),onUnmounted(()=>{unwatchGamepad&&unwatchGamepad(),removeHints()});function setHints(){let hints;removeHints(),hints=showIfController.value?CONTROLLER_HINTS$4:KEYBOARD_HINTS$4;for(let i=hints.length-1;i>=0;i--)infoBar.addHints(hints[i],0,!0)}function removeHints(){infoBar.removeHints(...KEYBOARD_HINTS$4.map(x=>x.id)),infoBar.removeHints(...CONTROLLER_HINTS$4.map(x=>x.id))}return(_ctx,_cache)=>withDirectives((openBlock(),createElementBlock(`div`,_hoisted_1$98,[createBaseVNode(`div`,_hoisted_2$84,[createVNode(unref(bngSwitch_default),{modelValue:mirror.value,"onUpdate:modelValue":_cache[0]||=$event=>mirror.value=$event},{default:withCtx(()=>[..._cache[3]||=[createTextVNode(`Mirror`,-1)]]),_:1},8,[`modelValue`]),createVNode(unref(bngBinding_default),{uiEvent:MIRROR_BINDING,deviceMask:`xinput`})]),createBaseVNode(`div`,_hoisted_3$73,[createVNode(unref(bngSwitch_default),{modelValue:flip$2.value,"onUpdate:modelValue":_cache[1]||=$event=>flip$2.value=$event,disabled:!mirror.value},{default:withCtx(()=>[..._cache[4]||=[createTextVNode(`Flip`,-1)]]),_:1},8,[`modelValue`,`disabled`]),createVNode(unref(bngBinding_default),{uiEvent:FLIP_BINDING,deviceMask:`xinput`,class:normalizeClass({disabled:!mirror.value})},null,8,[`class`])]),createBaseVNode(`div`,_hoisted_4$56,[createVNode(unref(bngInput_default),{modelValue:offset$2.value,"onUpdate:modelValue":_cache[2]||=$event=>offset$2.value=$event,step:.1,disabled:!mirror.value,type:`number`,prefix:`Offset`,class:`setting-input`},null,8,[`modelValue`,`disabled`]),createVNode(unref(bngBinding_default),{uiEvent:CONTROLLER_OFFSET_BINDING,deviceMask:`xinput`,class:normalizeClass({disabled:!mirror.value})},null,8,[`class`])])])),[[unref(BngOnUiNav_default),onTertiaryAction,`action_3`],[unref(BngOnUiNav_default),toggleMirror,`focus_l`],[unref(BngOnUiNav_default),toggleFlipped,`focus_r`],[unref(BngOnUiNav_default),changeOffset,`focus_u`,{up:!0}],[unref(BngOnUiNav_default),changeOffset,`focus_u`,{down:!0}],[unref(BngOnUiNav_default),changeOffset,`focus_d`,{up:!0}],[unref(BngOnUiNav_default),changeOffset,`focus_d`,{down:!0}],[unref(BngOnUiNav_default),changeOffsetScalar,`focus_ud`]])}},LayerMirrorSettings_default=__plugin_vue_export_helper_default(_sfc_main$107,[[`__scopeId`,`data-v-5ae7bab5`]]),_hoisted_1$97={"bng-ui-scope":`rotate-settings`},_hoisted_2$83={class:`setting-item item-column`},_hoisted_3$72={class:`slider-text-container`},INPUT_CONTROL_STEPS$3=.1,INPUT_CONTROL_MIN$3=0,INPUT_CONTROL_MAX$3=359.9,INPUT_DEFAULT_VALUE$3=0,CONTROLLER_ROTATE_BINDING=`focus_lr`,CONTROLLER_HINTS$3=[],KEYBOARD_HINTS$3=[],_sfc_main$106={__name:`LayerRotateSettings`,setup(__props){let store$1=useLayerSettingsStore(),actionHoldService=useActionHoldService(),{showIfController}=storeToRefs(controls_default()),infoBar=useInfoBar(),rotation=computed({get:()=>store$1.cursorData?parseFloat(store$1.cursorData.rotation.toFixed(1)):void 0,set:async newValue=>{await store$1.setRotation(newValue)}});function onReset(){rotation.value=INPUT_DEFAULT_VALUE$3}function onTertiaryAction(){if(store$1.reapplyActive||store$1.requestApplyActive)onReset();else return!0}useUINavScope(`rotate-settings`);let useCrossfireValue;onBeforeMount(()=>{useCrossfireValue=getUINavServiceInstance().useCrossfire,getUINavServiceInstance().useCrossfire=!1}),onBeforeUnmount(()=>{getUINavServiceInstance().useCrossfire=useCrossfireValue});let unwatchGamepad;onBeforeMount(()=>{unwatchGamepad=watch(showIfController,async()=>{await nextTick(()=>setHints())},{immediate:!0})}),onUnmounted(()=>{actionHoldService.removeAll(`rotate`),unwatchGamepad&&unwatchGamepad(),removeHints()});function setHints(){let hints=showIfController.value?CONTROLLER_HINTS$3:KEYBOARD_HINTS$3;removeHints();for(let i=hints.length-1;i>=0;i--)infoBar.addHints(hints[i],0,!0)}function removeHints(){infoBar.removeHints(...KEYBOARD_HINTS$3.map(x=>x.id)),infoBar.removeHints(...CONTROLLER_HINTS$3.map(x=>x.id))}return(_ctx,_cache)=>withDirectives((openBlock(),createElementBlock(`div`,_hoisted_1$97,[createBaseVNode(`div`,_hoisted_2$83,[createBaseVNode(`div`,_hoisted_3$72,[createVNode(unref(bngInput_default),{modelValue:rotation.value,"onUpdate:modelValue":_cache[0]||=$event=>rotation.value=$event,min:INPUT_CONTROL_MIN$3,max:INPUT_CONTROL_MAX$3,step:INPUT_CONTROL_STEPS$3,type:`number`,prefix:`X`,class:`slider-text-textinput`},null,8,[`modelValue`]),createVNode(unref(bngSlider_default),{modelValue:rotation.value,"onUpdate:modelValue":_cache[1]||=$event=>rotation.value=$event,min:INPUT_CONTROL_MIN$3,max:INPUT_CONTROL_MAX$3,step:INPUT_CONTROL_STEPS$3,class:`slider-text-sliderinput`},null,8,[`modelValue`]),createVNode(unref(bngBinding_default),{uiEvent:CONTROLLER_ROTATE_BINDING,deviceMask:`xinput`})])])])),[[unref(BngOnUiNav_default),onTertiaryAction,`action_3`],[unref(BngOnUiNav_default),element=>unref(actionHoldService).onFocus(`rotate`,unref(store$1).rotate,element,unref(ACTION_PARAMS_TYPE).xPoint),`focus_l`,{up:!0}],[unref(BngOnUiNav_default),element=>unref(actionHoldService).onFocus(`rotate`,unref(store$1).rotate,element,unref(ACTION_PARAMS_TYPE).xPoint),`focus_l`,{down:!0}],[unref(BngOnUiNav_default),element=>unref(actionHoldService).onFocus(`rotate`,unref(store$1).rotate,element,unref(ACTION_PARAMS_TYPE).xPoint),`focus_r`,{down:!0}],[unref(BngOnUiNav_default),element=>unref(actionHoldService).onFocus(`rotate`,unref(store$1).rotate,element,unref(ACTION_PARAMS_TYPE).xPoint),`focus_r`,{up:!0}],[unref(BngOnUiNav_default),element=>unref(actionHoldService).onFocus(`rotate`,unref(store$1).rotate,element,unref(ACTION_PARAMS_TYPE).xPoint),`focus_u`,{up:!0}],[unref(BngOnUiNav_default),element=>unref(actionHoldService).onFocus(`rotate`,unref(store$1).rotate,element,unref(ACTION_PARAMS_TYPE).xPoint),`focus_u`,{down:!0}],[unref(BngOnUiNav_default),element=>unref(actionHoldService).onFocus(`rotate`,unref(store$1).rotate,element,unref(ACTION_PARAMS_TYPE).xPoint),`focus_d`,{down:!0}],[unref(BngOnUiNav_default),element=>unref(actionHoldService).onFocus(`rotate`,unref(store$1).rotate,element,unref(ACTION_PARAMS_TYPE).xPoint),`focus_d`,{up:!0}],[unref(BngOnUiNav_default),element=>unref(actionHoldService).onFocusScalar(`rotate`,unref(store$1).rotate,element,unref(ACTION_PARAMS_TYPE).xPoint),`focus_lr`],[unref(BngOnUiNav_default),element=>unref(actionHoldService).onFocusScalar(`rotate`,unref(store$1).rotate,element,unref(ACTION_PARAMS_TYPE).xPoint),`focus_ud`]])}},LayerRotateSettings_default=__plugin_vue_export_helper_default(_sfc_main$106,[[`__scopeId`,`data-v-d8deaac6`]]),_sfc_main$105={__name:`BindingButton`,props:{uiEvent:String,deviceMask:String,action:String,label:String,showBinding:{type:Boolean,default:!0}},setup(__props){return(_ctx,_cache)=>(openBlock(),createBlock(unref(bngButton_default),{label:void 0},{default:withCtx(()=>[createBaseVNode(`span`,null,toDisplayString(__props.label),1),__props.showBinding?(openBlock(),createBlock(unref(bngBinding_default),{key:0,uiEvent:__props.uiEvent,deviceMask:__props.deviceMask,class:`button-binding`},null,8,[`uiEvent`,`deviceMask`])):createCommentVNode(``,!0)]),_:1}))}},BindingButton_default=__plugin_vue_export_helper_default(_sfc_main$105,[[`__scopeId`,`data-v-e77d3865`]]),_hoisted_1$96={class:`camera-popovermenu`},CONTROLLER_CAMERA_BINDING=`rotate_h_cam`,CAMERA_BUTTONS$2=[{label:`Right`,icon:icons.cameraSideRight,value:`right`},{label:`Front`,icon:icons.cameraFront1,value:`front`},{label:`Left`,icon:icons.cameraSideLeft,value:`left`},{label:`Back`,icon:icons.cameraBack1,value:`back`},{label:`Top Right`,icon:icons.cameraTop1,value:`topright`},{label:`Top Left`,icon:icons.cameraTop1,value:`topleft`},{label:`Top Front`,icon:icons.cameraTop1,value:`topfront`},{label:`Top Back`,icon:icons.cameraTop1,value:`topback`}],_sfc_main$104={__name:`CameraViewButton`,setup(__props){let store$1=useLiveryEditorStore(),popover=usePopover(),expand=ref(!1),currentCamera=computed(()=>{if(store$1.cameraView){let curr=CAMERA_BUTTONS$2.find(x=>x.value===store$1.cameraView);if(curr)return curr}return{icon:icons.movieCamera,label:`View`}}),onCameraViewClicked=view=>{popover.hide(`camera-popovermenu`),store$1.setOrthographicView(view)};return(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,null,[withDirectives((openBlock(),createBlock(unref(bngButton_default),{icon:currentCamera.value.icon,accent:unref(ACCENTS).secondary},{default:withCtx(()=>[createBaseVNode(`span`,null,toDisplayString(currentCamera.value.label),1),createVNode(unref(bngBinding_default),{uiEvent:CONTROLLER_CAMERA_BINDING,deviceMask:`xinput`})]),_:1},8,[`icon`,`accent`])),[[unref(BngPopover_default),`camera-popovermenu`,`bottom`,{click:!0}]]),createVNode(unref(bngPopoverContent_default),{name:`camera-popovermenu`,onShow:_cache[0]||=$event=>expand.value=!0,onHide:_cache[1]||=$event=>expand.value=!1},{default:withCtx(()=>[createBaseVNode(`div`,_hoisted_1$96,[(openBlock(),createElementBlock(Fragment,null,renderList(CAMERA_BUTTONS$2,cameraItem=>createVNode(unref(bngImageTile_default),{key:cameraItem.value,label:cameraItem.label,icon:cameraItem.icon,class:normalizeClass({active:cameraItem.value===currentCamera.value.value}),onClick:$event=>onCameraViewClicked(cameraItem.value)},null,8,[`label`,`icon`,`class`,`onClick`])),64))])]),_:1})]))}},CameraViewButton_default=__plugin_vue_export_helper_default(_sfc_main$104,[[`__scopeId`,`data-v-be949a44`]]),_hoisted_1$95={key:0,class:`liveryeditor-header`},_hoisted_2$82={key:0,class:`header-items`},_sfc_main$103={__name:`LiveryEditorHeader`,setup(__props){let store$1=useEditorHeaderStore(),{startSectionItems,centerSectionItems,endSectionItems}=storeToRefs(store$1),sections=ref({start:startSectionItems,center:centerSectionItems,end:endSectionItems});return(_ctx,_cache)=>unref(store$1).headerHidden?createCommentVNode(``,!0):(openBlock(),createElementBlock(`div`,_hoisted_1$95,[createVNode(unref(bngScreenHeading_default),{type:unref(store$1).header.type,preheadings:unref(store$1).header.preheading},{default:withCtx(()=>[createTextVNode(toDisplayString(unref(store$1).header.heading),1)]),_:1},8,[`type`,`preheadings`]),unref(store$1).itemsHidden?createCommentVNode(``,!0):(openBlock(),createElementBlock(`div`,_hoisted_2$82,[(openBlock(!0),createElementBlock(Fragment,null,renderList(sections.value,(items$2,section)=>(openBlock(),createElementBlock(`div`,{class:normalizeClass([[`section-${section}`],`header-section`])},[(openBlock(!0),createElementBlock(Fragment,null,renderList(items$2,item=>(openBlock(),createElementBlock(`div`,{key:item.id},[withDirectives((openBlock(),createBlock(resolveDynamicComponent(item.component),mergeProps({ref_for:!0},item.props,toHandlers(item.events)),null,16)),[[vShow,!item.hidden]])]))),128))],2))),256))]))]))}},LiveryEditorHeader_default=__plugin_vue_export_helper_default(_sfc_main$103,[[`__scopeId`,`data-v-b0fff070`]]),_hoisted_1$94={class:`transform-settings`,"bng-ui-scope":`transform-settings`},_hoisted_2$81={class:`setting-item item-column`},_hoisted_3$71={class:`slider-text-container`},_hoisted_4$55={class:`setting-item item-column`},_hoisted_5$46={class:`slider-text-container`},_hoisted_6$33={key:0,class:`setting-item`},_hoisted_7$28={class:`setting-item actions-container`},INPUT_CONTROL_STEPS$2=.001,INPUT_CONTROL_MIN$2=0,INPUT_CONTROL_MAX$2=1,INPUT_DEFAULT_VALUE$2=.5,APPLIED_CONTROLLER_HINTS=[],CONTROLLER_MOVE_Y_BINDING=`focus_ud`,CONTROLLER_MOVE_X_BINDING=`focus_lr`,CONTROLLER_SURFACE_NORMAL_BINDING=`action_2`,CONTROLLER_APPLY_BINDING=`ok`,CONTROLLER_CANCEL_REAPPLY_BINDING=`back`,CONTROLLER_HINTS$2=[],KEYBOARD_HINTS$2=[],MOUSE_HINTS=[{id:`stamp_decal`,content:{type:`binding`,props:{action:`stamp_decal`},label:`Apply`}}],_sfc_main$102={__name:`LayerTransformSettingsOld`,setup(__props){let store$1=useLayerSettingsStore(),{showIfController}=storeToRefs(controls_default()),infoBar=useInfoBar(),actionHoldService=useActionHoldService(),positionX=computed({get:()=>store$1.cursorData&&store$1.cursorData.position?store$1.cursorData.position.x:void 0,set:async newValue=>await store$1.setPosition(newValue,store$1.cursorData.position.y)}),positionY=computed({get:()=>store$1.cursorData&&store$1.cursorData.position?store$1.cursorData.position.y:void 0,set:async newValue=>await store$1.setPosition(store$1.cursorData.position.x,newValue)}),positionMaxX=computed(()=>store$1.cursorData&&store$1.cursorData.position?store$1.cursorData.position.maxX:INPUT_CONTROL_MAX$2),positionMaxY=computed(()=>store$1.cursorData&&store$1.cursorData.position?store$1.cursorData.position.maxY:INPUT_CONTROL_MAX$2),surfaceNormal=computed({get:()=>store$1.cursorData?store$1.cursorData.isProjectSurfaceNormal:void 0,set:async newValue=>await store$1.setProjectSurfaceNormal(newValue)}),mouseMode=computed(()=>store$1.cursorData?store$1.cursorData.isUseMousePos:void 0),applied=computed(()=>store$1.cursorData?store$1.cursorData.applied:void 0);computed(()=>store$1.active);let isShowControls=computed(()=>!store$1.cursorData.applied&&!mouseMode.value),toggleUseSurfaceNormal=()=>{if(console.log(`toggleUseSurfaceNormal`),!store$1.cursorData.applied)surfaceNormal.value=!surfaceNormal.value;else return console.log(`toggleUseSurfaceNormal returning true`),!0};function cancelApply(){store$1.requestApplyActive?store$1.cancelRequestApply():store$1.reapplyActive&&store$1.cancelReapply()}function onReset(){store$1.setPosition(INPUT_DEFAULT_VALUE$2,INPUT_DEFAULT_VALUE$2)}function onOk(){if(!store$1.requestApplyActive&&!store$1.reapplyActive)store$1.toggleReapply();else return!0}function onTertiaryAction(){if(store$1.reapplyActive||store$1.requestApplyActive)onReset();else return!0}useUINavScope(`transform-settings`);let useCrossfireValue;onBeforeMount(()=>{useCrossfireValue=getUINavServiceInstance().useCrossfire,getUINavServiceInstance().useCrossfire=!1}),onBeforeUnmount(()=>{getUINavServiceInstance().useCrossfire=useCrossfireValue}),watch(mouseMode,async()=>{await nextTick(()=>setHints())}),watch(applied,async()=>{await nextTick(()=>setHints())});function setHints(){let hints;removeHints(),hints=applied.value?showIfController.value?APPLIED_CONTROLLER_HINTS:KEYBOARD_HINTS$2:mouseMode.value?MOUSE_HINTS:showIfController.value?CONTROLLER_HINTS$2:KEYBOARD_HINTS$2;for(let i=hints.length-1;i>=0;i--)infoBar.addHints(hints[i],0,!0)}let unwatchGamepad;onBeforeMount(()=>{unwatchGamepad=watch(showIfController,async()=>{await nextTick(()=>{setHints()})},{immediate:!0})}),onUnmounted(()=>{actionHoldService.removeAll(`transform`),unwatchGamepad&&unwatchGamepad(),removeHints()});function removeHints(){infoBar.removeHints(...KEYBOARD_HINTS$2.map(x=>x.id)),infoBar.removeHints(...CONTROLLER_HINTS$2.map(x=>x.id)),infoBar.removeHints(...APPLIED_CONTROLLER_HINTS.map(x=>x.id)),infoBar.removeHints(...MOUSE_HINTS.map(x=>x.id))}return(_ctx,_cache)=>withDirectives((openBlock(),createElementBlock(`div`,_hoisted_1$94,[createBaseVNode(`div`,_hoisted_2$81,[withDirectives(createBaseVNode(`div`,_hoisted_3$71,[createVNode(unref(bngInput_default),{modelValue:positionX.value,"onUpdate:modelValue":_cache[0]||=$event=>positionX.value=$event,min:INPUT_CONTROL_MIN$2,max:positionMaxX.value,step:INPUT_CONTROL_STEPS$2,type:`number`,prefix:`X`,class:`slider-text-textinput`},null,8,[`modelValue`,`max`]),createVNode(unref(bngSlider_default),{modelValue:positionX.value,"onUpdate:modelValue":_cache[1]||=$event=>positionX.value=$event,min:INPUT_CONTROL_MIN$2,max:positionMaxX.value,step:INPUT_CONTROL_STEPS$2,class:`slider-text-sliderinput`},null,8,[`modelValue`,`max`]),createVNode(unref(bngBinding_default),{uiEvent:CONTROLLER_MOVE_X_BINDING,deviceMask:`xinput`})],512),[[vShow,isShowControls.value]])]),withDirectives(createBaseVNode(`div`,_hoisted_4$55,[createBaseVNode(`div`,_hoisted_5$46,[createVNode(unref(bngInput_default),{modelValue:positionY.value,"onUpdate:modelValue":_cache[2]||=$event=>positionY.value=$event,type:`number`,prefix:`Y`,min:INPUT_CONTROL_MIN$2,max:positionMaxY.value,step:INPUT_CONTROL_STEPS$2,class:`slider-text-textinput`},null,8,[`modelValue`,`max`]),createVNode(unref(bngSlider_default),{modelValue:positionY.value,"onUpdate:modelValue":_cache[3]||=$event=>positionY.value=$event,min:INPUT_CONTROL_MIN$2,max:positionMaxY.value,step:INPUT_CONTROL_STEPS$2,class:`slider-text-sliderinput`},null,8,[`modelValue`,`max`]),createVNode(unref(bngBinding_default),{uiEvent:CONTROLLER_MOVE_Y_BINDING,deviceMask:`xinput`})])],512),[[vShow,isShowControls.value]]),unref(store$1).cursorData.applied?createCommentVNode(``,!0):(openBlock(),createElementBlock(`div`,_hoisted_6$33,[createVNode(unref(bngSwitch_default),{modelValue:surfaceNormal.value,"onUpdate:modelValue":_cache[4]||=$event=>surfaceNormal.value=$event,disabled:!(unref(store$1).reapplyActive||!applied.value)},{default:withCtx(()=>[..._cache[5]||=[createTextVNode(`Use Surface Normal`,-1)]]),_:1},8,[`modelValue`,`disabled`]),createVNode(unref(bngBinding_default),{uiEvent:CONTROLLER_SURFACE_NORMAL_BINDING,deviceMask:`xinput`})])),createBaseVNode(`div`,_hoisted_7$28,[unref(store$1).requestApplyActive||unref(store$1).reapplyActive?(openBlock(),createElementBlock(Fragment,{key:0},[unref(store$1).appliedLayers&&unref(store$1).appliedLayers.length>0?(openBlock(),createBlock(unref(BindingButton_default),{key:0,icon:unref(store$1).reapplyActive?unref(icons).undo:``,uiEvent:CONTROLLER_CANCEL_REAPPLY_BINDING,label:unref(store$1).reapplyActive?`Undo`:`Cancel`,accent:`attention`,onClick:cancelApply},null,8,[`icon`,`label`])):createCommentVNode(``,!0),mouseMode.value?createCommentVNode(``,!0):(openBlock(),createBlock(unref(BindingButton_default),{key:1,uiEvent:CONTROLLER_APPLY_BINDING,label:`Apply`,accent:`primary`,onClick:unref(store$1).apply},null,8,[`onClick`]))],64)):(openBlock(),createBlock(unref(BindingButton_default),{key:1,uiEvent:CONTROLLER_APPLY_BINDING,label:`Reapply`,onClick:unref(store$1).requestReapply},null,8,[`onClick`]))])])),[[unref(BngOnUiNav_default),onOk,`ok`],[unref(BngOnUiNav_default),toggleUseSurfaceNormal,`action_2`],[unref(BngOnUiNav_default),onTertiaryAction,`action_3`],[unref(BngOnUiNav_default),element=>unref(actionHoldService).onFocus(`transform`,unref(store$1).translate,element),`focus_l`,{up:!0}],[unref(BngOnUiNav_default),element=>unref(actionHoldService).onFocus(`transform`,unref(store$1).translate,element),`focus_l`,{down:!0}],[unref(BngOnUiNav_default),element=>unref(actionHoldService).onFocus(`transform`,unref(store$1).translate,element),`focus_r`,{down:!0}],[unref(BngOnUiNav_default),element=>unref(actionHoldService).onFocus(`transform`,unref(store$1).translate,element),`focus_r`,{up:!0}],[unref(BngOnUiNav_default),element=>unref(actionHoldService).onFocus(`transform`,unref(store$1).translate,element),`focus_u`,{up:!0}],[unref(BngOnUiNav_default),element=>unref(actionHoldService).onFocus(`transform`,unref(store$1).translate,element),`focus_u`,{down:!0}],[unref(BngOnUiNav_default),element=>unref(actionHoldService).onFocus(`transform`,unref(store$1).translate,element),`focus_d`,{down:!0}],[unref(BngOnUiNav_default),element=>unref(actionHoldService).onFocus(`transform`,unref(store$1).translate,element),`focus_d`,{up:!0}],[unref(BngOnUiNav_default),element=>unref(actionHoldService).onFocusScalar(`transform`,unref(store$1).translate,element),`focus_lr`],[unref(BngOnUiNav_default),element=>unref(actionHoldService).onFocusScalar(`transform`,unref(store$1).translate,element),`focus_ud`]])}},LayerTransformSettingsOld_default=__plugin_vue_export_helper_default(_sfc_main$102,[[`__scopeId`,`data-v-79d0fe46`]]),_hoisted_1$93={class:`scale-settings`,"bng-ui-scope":`scale-settings`},_hoisted_2$80={class:`setting-item item-column`},_hoisted_3$70={class:`slider-text-container`},_hoisted_4$54={class:`setting-item item-column`},_hoisted_5$45={class:`slider-text-container`},_hoisted_6$32={class:`setting-item`},INPUT_CONTROL_STEPS$1=.01,INPUT_CONTROL_MIN$1=0,INPUT_CONTROL_MAX$1=6,INPUT_DEFAULT_VALUE$1=.5,CONTROLLER_SCALE_Y_BINDING=`focus_ud`,CONTROLLER_SCALE_X_BINDING=`focus_lr`,CONTROLLER_LOCK_BINDING=`action_2`,CONTROLLER_HINTS$1=[],KEYBOARD_HINTS$1=[],_sfc_main$101={__name:`LayerScaleSettings`,setup(__props){let store$1=useLayerSettingsStore(),actionHoldService=useActionHoldService(),{showIfController}=storeToRefs(controls_default()),infoBar=useInfoBar(),{editModeState}=storeToRefs(store$1),scaleX=computed({get:()=>store$1.cursorData&&store$1.cursorData.scale?store$1.cursorData.scale.x:void 0,set:async newValue=>{if(newValue===store$1.cursorData.scale.x)return;let scaleY$1=store$1.cursorData.scale.y;if(editModeState.value.lockScaling){let diff=newValue-store$1.cursorData.scale.x;scaleY$1+=diff}await store$1.setScale(newValue,scaleY$1)}}),scaleY=computed({get:()=>store$1.cursorData&&store$1.cursorData.scale?store$1.cursorData.scale.y:void 0,set:async newValue=>{if(newValue===store$1.cursorData.scale.y)return;let scaleX$1=store$1.cursorData.scale.x;if(editModeState.value.lockScaling){let diff=newValue-store$1.cursorData.scale.y;scaleX$1+=diff}await store$1.setScale(scaleX$1,newValue)}}),toggleLockScaling=()=>{editModeState.value.lockScaling=!editModeState.value.lockScaling};function onReset(){store$1.setScale(INPUT_DEFAULT_VALUE$1,INPUT_DEFAULT_VALUE$1)}function onTertiaryAction(){if(store$1.reapplyActive||store$1.requestApplyActive)onReset();else return!0}function onFocus(element,scalar=!1){let actionFn=(xDirection,yDirection)=>{xDirection!==0&&(scaleX.value=xDirection*INPUT_CONTROL_STEPS$1+scaleX.value),yDirection!==0&&(scaleY.value=yDirection*INPUT_CONTROL_STEPS$1+scaleY.value)};scalar?actionHoldService.onFocusScalar(`scale`,actionFn,element):actionHoldService.onFocus(`scale`,actionFn,element)}useUINavScope(`scale-settings`);let useCrossfireValue;onBeforeMount(()=>{useCrossfireValue=getUINavServiceInstance().useCrossfire,getUINavServiceInstance().useCrossfire=!1}),onBeforeUnmount(()=>{getUINavServiceInstance().useCrossfire=useCrossfireValue});let unwatchGamepad;onBeforeMount(()=>{unwatchGamepad=watch(showIfController,async()=>{await nextTick(()=>setHints())},{immediate:!0})}),onUnmounted(()=>{actionHoldService.removeAll(`scale`),unwatchGamepad&&unwatchGamepad(),removeHints()});function setHints(){let hints=showIfController.value?CONTROLLER_HINTS$1:KEYBOARD_HINTS$1;removeHints();for(let i=hints.length-1;i>=0;i--)infoBar.addHints(hints[i],0,!0)}function removeHints(){infoBar.removeHints(...KEYBOARD_HINTS$1.map(x=>x.id)),infoBar.removeHints(...CONTROLLER_HINTS$1.map(x=>x.id))}return(_ctx,_cache)=>withDirectives((openBlock(),createElementBlock(`div`,_hoisted_1$93,[createBaseVNode(`div`,_hoisted_2$80,[createBaseVNode(`div`,_hoisted_3$70,[createVNode(unref(bngInput_default),{modelValue:scaleX.value,"onUpdate:modelValue":_cache[0]||=$event=>scaleX.value=$event,min:INPUT_CONTROL_MIN$1,max:INPUT_CONTROL_MAX$1,step:INPUT_CONTROL_STEPS$1,type:`number`,prefix:`X`,class:`slider-text-textinput`},null,8,[`modelValue`]),createVNode(unref(bngSlider_default),{modelValue:scaleX.value,"onUpdate:modelValue":_cache[1]||=$event=>scaleX.value=$event,min:INPUT_CONTROL_MIN$1,max:INPUT_CONTROL_MAX$1,step:INPUT_CONTROL_STEPS$1,class:`slider-text-sliderinput`},null,8,[`modelValue`]),createVNode(unref(bngBinding_default),{uiEvent:CONTROLLER_SCALE_X_BINDING,deviceMask:`xinput`})])]),createBaseVNode(`div`,_hoisted_4$54,[createBaseVNode(`div`,_hoisted_5$45,[createVNode(unref(bngInput_default),{modelValue:scaleY.value,"onUpdate:modelValue":_cache[2]||=$event=>scaleY.value=$event,type:`number`,prefix:`Y`,min:INPUT_CONTROL_MIN$1,max:INPUT_CONTROL_MAX$1,step:INPUT_CONTROL_STEPS$1,class:`slider-text-textinput`},null,8,[`modelValue`]),createVNode(unref(bngSlider_default),{modelValue:scaleY.value,"onUpdate:modelValue":_cache[3]||=$event=>scaleY.value=$event,min:INPUT_CONTROL_MIN$1,max:INPUT_CONTROL_MAX$1,step:INPUT_CONTROL_STEPS$1,class:`slider-text-sliderinput`},null,8,[`modelValue`]),createVNode(unref(bngBinding_default),{uiEvent:CONTROLLER_SCALE_Y_BINDING,deviceMask:`xinput`})])]),createBaseVNode(`div`,_hoisted_6$32,[createVNode(unref(bngSwitch_default),{modelValue:unref(editModeState).lockScaling,"onUpdate:modelValue":_cache[4]||=$event=>unref(editModeState).lockScaling=$event},{default:withCtx(()=>[..._cache[5]||=[createTextVNode(`Lock Scaling`,-1)]]),_:1},8,[`modelValue`]),createVNode(unref(bngBinding_default),{uiEvent:CONTROLLER_LOCK_BINDING,deviceMask:`xinput`})])])),[[unref(BngOnUiNav_default),toggleLockScaling,`action_2`],[unref(BngOnUiNav_default),onTertiaryAction,`action_3`],[unref(BngOnUiNav_default),onFocus,`focus_l`,{up:!0}],[unref(BngOnUiNav_default),onFocus,`focus_l`,{down:!0}],[unref(BngOnUiNav_default),onFocus,`focus_r`,{down:!0}],[unref(BngOnUiNav_default),onFocus,`focus_r`,{up:!0}],[unref(BngOnUiNav_default),onFocus,`focus_u`,{up:!0}],[unref(BngOnUiNav_default),onFocus,`focus_u`,{down:!0}],[unref(BngOnUiNav_default),onFocus,`focus_d`,{down:!0}],[unref(BngOnUiNav_default),onFocus,`focus_d`,{up:!0}],[unref(BngOnUiNav_default),el=>onFocus(el,!0),`focus_lr`],[unref(BngOnUiNav_default),el=>onFocus(el,!0),`focus_ud`]])}},LayerScaleSettings_default=__plugin_vue_export_helper_default(_sfc_main$101,[[`__scopeId`,`data-v-56a383d1`]]),_hoisted_1$92={class:`sort-settings`,"bng-ui-scope":`sort-settings`},_hoisted_2$79={class:`setting-item`},_hoisted_3$69={class:`icon-binding-wrapper`},_hoisted_4$53={class:`icon-binding-wrapper`},_hoisted_5$44={class:`icon-binding-wrapper`},_hoisted_6$31={class:`stacked-arrows`},_hoisted_7$27={class:`icon-binding-wrapper`},_hoisted_8$21={class:`stacked-arrows`},_hoisted_9$18={key:0},ORDER_TOOL=Lua_default.extensions.ui_liveryEditor_tools_group,_sfc_main$100={__name:`LayerSortSettings`,setup(__props){let store$1=useLiveryEditorStore();useUINavScope(`sort-settings`);let order=computed({get:()=>store$1.selectedLayers[0].order,set(newValue){ORDER_TOOL.setOrder(newValue)}}),orderMax=computed(()=>store$1.selectedLayers[0].siblingCount),multiSelected=computed(()=>store$1.selectedLayerUids.length>1),orderOptions=computed(()=>Array.from({length:store$1.layers.length-1},(_,i)=>({label:`${i+1}`,value:i+2})));return onMounted(()=>{getUINavServiceInstance().useCrossfire=!1}),(_ctx,_cache)=>withDirectives((openBlock(),createElementBlock(`div`,_hoisted_1$92,[createBaseVNode(`div`,_hoisted_2$79,[createVNode(unref(bngButton_default),{onClick:_cache[0]||=()=>unref(ORDER_TOOL).moveOrderUp(),disabled:order.value===orderMax.value},{default:withCtx(()=>[createBaseVNode(`div`,_hoisted_3$69,[createVNode(unref(bngIcon_default),{type:unref(icons).arrowLargeUp},null,8,[`type`]),createVNode(unref(bngBinding_default),{action:`menu_item_up`})])]),_:1},8,[`disabled`]),createVNode(unref(bngButton_default),{onClick:_cache[1]||=()=>unref(ORDER_TOOL).moveOrderDown(),disabled:order.value===2},{default:withCtx(()=>[createBaseVNode(`div`,_hoisted_4$53,[createVNode(unref(bngIcon_default),{type:unref(icons).arrowLargeDown},null,8,[`type`]),createVNode(unref(bngBinding_default),{action:`menu_item_down`})])]),_:1},8,[`disabled`]),multiSelected.value?createCommentVNode(``,!0):(openBlock(),createBlock(unref(bngButton_default),{key:0,onClick:_cache[2]||=()=>unref(ORDER_TOOL).changeOrderToTop(),disabled:order.value===orderMax.value},{default:withCtx(()=>[createBaseVNode(`div`,_hoisted_5$44,[createBaseVNode(`div`,_hoisted_6$31,[createVNode(unref(bngIcon_default),{type:unref(icons).arrowLargeUp},null,8,[`type`]),createVNode(unref(bngIcon_default),{type:unref(icons).arrowLargeUp},null,8,[`type`])]),createVNode(unref(bngBinding_default),{action:`menu_item_right`})])]),_:1},8,[`disabled`])),multiSelected.value?createCommentVNode(``,!0):(openBlock(),createBlock(unref(bngButton_default),{key:1,onClick:_cache[3]||=()=>unref(ORDER_TOOL).changeOrderToBottom(),disabled:order.value===2},{default:withCtx(()=>[createBaseVNode(`div`,_hoisted_7$27,[createBaseVNode(`div`,_hoisted_8$21,[createVNode(unref(bngIcon_default),{type:unref(icons).arrowLargeDown,disabled:unref(store$1).selectedLayers.length>1},null,8,[`type`,`disabled`]),createVNode(unref(bngIcon_default),{type:unref(icons).arrowLargeDown,disabled:unref(store$1).selectedLayers.length>1},null,8,[`type`,`disabled`])]),createVNode(unref(bngBinding_default),{action:`menu_item_left`})])]),_:1},8,[`disabled`]))]),multiSelected.value?createCommentVNode(``,!0):(openBlock(),createElementBlock(`div`,_hoisted_9$18,[createVNode(unref(bngDropdown_default),{modelValue:order.value,"onUpdate:modelValue":_cache[4]||=$event=>order.value=$event,items:orderOptions.value},null,8,[`modelValue`,`items`])]))])),[[unref(BngOnUiNav_default),()=>unref(ORDER_TOOL).changeOrderToBottom(),`focus_l`],[unref(BngOnUiNav_default),()=>unref(ORDER_TOOL).changeOrderToTop(),`focus_r`],[unref(BngOnUiNav_default),()=>unref(ORDER_TOOL).moveOrderUp(),`focus_u`],[unref(BngOnUiNav_default),()=>unref(ORDER_TOOL).moveOrderDown(),`focus_d`]])}},LayerSortSettings_default=__plugin_vue_export_helper_default(_sfc_main$100,[[`__scopeId`,`data-v-1d4969be`]]),_hoisted_1$91={class:`skew-settings`,"bng-ui-scope":`skew-settings`},_hoisted_2$78={class:`setting-item item-column`},_hoisted_3$68={class:`slider-text-container`},_hoisted_4$52={class:`setting-item item-column`},_hoisted_5$43={class:`slider-text-container`},INPUT_CONTROL_STEPS=.01,INPUT_CONTROL_MIN=-2,INPUT_CONTROL_MAX=2,INPUT_DEFAULT_VALUE=0,CONTROLLER_SKEW_Y_BINDING=`focus_ud`,CONTROLLER_SKEW_X_BINDING=`focus_lr`,CONTROLLER_HINTS=[],KEYBOARD_HINTS=[],_sfc_main$99={__name:`LayerDeformSettings`,setup(__props){let store$1=useLayerSettingsStore(),actionHoldService=useActionHoldService(),{showIfController}=storeToRefs(controls_default()),infoBar=useInfoBar(),skewX=computed({get:()=>store$1.cursorData&&store$1.cursorData.skew?store$1.cursorData.skew.x:void 0,set:async newValue=>await store$1.setSkew(newValue,store$1.cursorData.skew.y)}),skewY=computed({get:()=>store$1.cursorData&&store$1.cursorData.skew?store$1.cursorData.skew.y:void 0,set:async newValue=>await store$1.setSkew(store$1.cursorData.skew.x,newValue)});function onReset(){store$1.setSkew(INPUT_DEFAULT_VALUE,INPUT_DEFAULT_VALUE)}function onTertiaryAction(){if(store$1.reapplyActive||store$1.requestApplyActive)onReset();else return!0}useUINavScope(`skew-settings`);let useCrossfireValue;onBeforeMount(()=>{useCrossfireValue=getUINavServiceInstance().useCrossfire,getUINavServiceInstance().useCrossfire=!1}),onBeforeUnmount(()=>{getUINavServiceInstance().useCrossfire=useCrossfireValue});let unwatchGamepad;onBeforeMount(()=>{unwatchGamepad=watch(showIfController,async()=>{await nextTick(()=>setHints())},{immediate:!0})}),onUnmounted(()=>{actionHoldService.removeAll(`skew`),unwatchGamepad&&unwatchGamepad(),removeHints()});function setHints(){let hints=showIfController.value?CONTROLLER_HINTS:KEYBOARD_HINTS;removeHints();for(let i=hints.length-1;i>=0;i--)infoBar.addHints(hints[i],0,!0)}function removeHints(){infoBar.removeHints(...KEYBOARD_HINTS.map(x=>x.id)),infoBar.removeHints(...CONTROLLER_HINTS.map(x=>x.id))}return(_ctx,_cache)=>withDirectives((openBlock(),createElementBlock(`div`,_hoisted_1$91,[createBaseVNode(`div`,_hoisted_2$78,[createBaseVNode(`div`,_hoisted_3$68,[createVNode(unref(bngInput_default),{modelValue:skewX.value,"onUpdate:modelValue":_cache[0]||=$event=>skewX.value=$event,min:INPUT_CONTROL_MIN,max:INPUT_CONTROL_MAX,step:INPUT_CONTROL_STEPS,type:`number`,prefix:`X`,class:`slider-text-textinput`},null,8,[`modelValue`]),createVNode(unref(bngSlider_default),{modelValue:skewX.value,"onUpdate:modelValue":_cache[1]||=$event=>skewX.value=$event,min:INPUT_CONTROL_MIN,max:INPUT_CONTROL_MAX,step:INPUT_CONTROL_STEPS,class:`slider-text-sliderinput`},null,8,[`modelValue`]),createVNode(unref(bngBinding_default),{uiEvent:CONTROLLER_SKEW_X_BINDING,deviceMask:`xinput`})])]),createBaseVNode(`div`,_hoisted_4$52,[createBaseVNode(`div`,_hoisted_5$43,[createVNode(unref(bngInput_default),{modelValue:skewY.value,"onUpdate:modelValue":_cache[2]||=$event=>skewY.value=$event,type:`number`,prefix:`Y`,min:INPUT_CONTROL_MIN,max:INPUT_CONTROL_MAX,step:INPUT_CONTROL_STEPS,class:`slider-text-textinput`},null,8,[`modelValue`]),createVNode(unref(bngSlider_default),{modelValue:skewY.value,"onUpdate:modelValue":_cache[3]||=$event=>skewY.value=$event,min:INPUT_CONTROL_MIN,max:INPUT_CONTROL_MAX,step:INPUT_CONTROL_STEPS,class:`slider-text-sliderinput`},null,8,[`modelValue`]),createVNode(unref(bngBinding_default),{uiEvent:CONTROLLER_SKEW_Y_BINDING,deviceMask:`xinput`})])])])),[[unref(BngOnUiNav_default),onTertiaryAction,`action_3`],[unref(BngOnUiNav_default),element=>unref(actionHoldService).onFocus(`skew`,unref(store$1).skew,element),`focus_l`,{up:!0}],[unref(BngOnUiNav_default),element=>unref(actionHoldService).onFocus(`skew`,unref(store$1).skew,element),`focus_l`,{down:!0}],[unref(BngOnUiNav_default),element=>unref(actionHoldService).onFocus(`skew`,unref(store$1).skew,element),`focus_r`,{down:!0}],[unref(BngOnUiNav_default),element=>unref(actionHoldService).onFocus(`skew`,unref(store$1).skew,element),`focus_r`,{up:!0}],[unref(BngOnUiNav_default),element=>unref(actionHoldService).onFocus(`skew`,unref(store$1).skew,element),`focus_u`,{up:!0}],[unref(BngOnUiNav_default),element=>unref(actionHoldService).onFocus(`skew`,unref(store$1).skew,element),`focus_u`,{down:!0}],[unref(BngOnUiNav_default),element=>unref(actionHoldService).onFocus(`skew`,unref(store$1).skew,element),`focus_d`,{down:!0}],[unref(BngOnUiNav_default),element=>unref(actionHoldService).onFocus(`skew`,unref(store$1).skew,element),`focus_d`,{up:!0}],[unref(BngOnUiNav_default),element=>unref(actionHoldService).onFocusScalar(`skew`,unref(store$1).skew,element),`focus_lr`],[unref(BngOnUiNav_default),element=>unref(actionHoldService).onFocusScalar(`skew`,unref(store$1).skew,element),`focus_ud`]])}},LayerDeformSettings_default=__plugin_vue_export_helper_default(_sfc_main$99,[[`__scopeId`,`data-v-b2c32ce6`]]),_hoisted_1$90={class:`layer-settings-base`},_hoisted_2$77={class:`settings-heading`},_hoisted_3$67={class:`settings-content`},_sfc_main$98={__name:`LayerSettingsBase`,props:{heading:{type:String}},emits:[`close`],setup(__props){let slots=useSlots();return(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$90,[createBaseVNode(`div`,_hoisted_2$77,[createVNode(unref(bngCardHeading_default),{type:`ribbon`},{default:withCtx(()=>[unref(slots).heading?renderSlot(_ctx.$slots,`heading`,{key:0},()=>[createBaseVNode(`span`,null,toDisplayString(__props.heading),1)],!0):createCommentVNode(``,!0)]),_:3})]),createBaseVNode(`div`,_hoisted_3$67,[renderSlot(_ctx.$slots,`default`,{},void 0,!0)])]))}},LayerSettingsBase_default=__plugin_vue_export_helper_default(_sfc_main$98,[[`__scopeId`,`data-v-c5fed92f`]]),_hoisted_1$89={class:`setting-item item-column`},_hoisted_2$76={class:`slider-text-container`},_hoisted_3$66={class:`setting-item item-column`},_hoisted_4$51={class:`slider-text-container`},_sfc_main$97={__name:`TransformSettings`,setup(__props){let scaleX=ref(.5),scaleY=ref(.5);return(_ctx,_cache)=>(openBlock(),createBlock(unref(LayerSettingsBase_default),null,{heading:withCtx(()=>[..._cache[2]||=[createTextVNode(`Transform`,-1)]]),default:withCtx(()=>[createBaseVNode(`template`,null,[createBaseVNode(`div`,_hoisted_1$89,[createBaseVNode(`div`,_hoisted_2$76,[createVNode(unref(bngInput_default),{modelValue:scaleX.value,"onUpdate:modelValue":_cache[0]||=$event=>scaleX.value=$event,min:0,max:6,step:.01,type:`number`,prefix:`X`},null,8,[`modelValue`])])]),createBaseVNode(`div`,_hoisted_3$66,[createBaseVNode(`div`,_hoisted_4$51,[createVNode(unref(bngInput_default),{modelValue:scaleY.value,"onUpdate:modelValue":_cache[1]||=$event=>scaleY.value=$event,type:`number`,prefix:`Y`,min:0,max:6,step:.01},null,8,[`modelValue`])])])])]),_:1}))}},TransformSettings_default=_sfc_main$97,_hoisted_1$88={class:`settings-container`},_hoisted_2$75={class:`setting-types-selector`},_hoisted_3$65={class:`setting-types`},_hoisted_4$50=[`onClick`],_hoisted_5$42={class:`heading-content-wrapper`},_hoisted_6$30={class:`heading-content-text`},_hoisted_7$26={key:0},_hoisted_8$20={key:0,class:`subheading`},CONTROLLER_RESET_BINDING=`advanced`,SETTING_TYPES=[{value:`transform`,label:`Transform`,icon:icons.transform,component:markRaw(TransformSettings_default)},{value:`transformold`,label:`Position`,icon:icons.transform,component:markRaw(LayerTransformSettingsOld_default)},{value:`scale`,label:`Scale`,icon:icons.scale,component:markRaw(LayerScaleSettings_default)},{value:`skew`,label:`Skew`,icon:icons.deform,component:markRaw(LayerDeformSettings_default)},{value:`rotate`,label:`Rotate`,icon:icons.rotationL,component:markRaw(LayerRotateSettings_default)},{value:`material`,label:`Material`,icon:icons.material,component:markRaw(LayerMaterialSettings_default)},{value:`mirror`,label:`Mirror`,icon:icons.reflect,component:markRaw(LayerMirrorSettings_default)}],_sfc_main$96={__name:`LayerSettings`,props:{settingTypes:Array,activeSetting:String,excludeSettingTypes:Array},setup(__props){let store$1=useLayerSettingsStore(),props=__props,currentIndex=ref(0),settingTypes=computed(()=>{let filtered=SETTING_TYPES;return props.settingTypes&&(filtered=filtered.filter(x=>props.settingTypes.includes(x.value))),props.excludeSettingTypes&&(filtered=filtered.filter(x=>!props.excludeSettingTypes.includes(x.value))),filtered}),activeSubSetting=ref(null),activeSettingType=computed(()=>settingTypes.value[currentIndex.value]),mouseMode=computed(()=>store$1.cursorData?store$1.cursorData.isUseMousePos:void 0);watch(()=>props.activeSetting,()=>{let index=settingTypes.value.findIndex(x=>x.value===props.activeSetting);index>-1?currentIndex.value=index:console.warn(`Error finding setting ${props.activeSetting}`)},{immediate:!0}),watch(activeSettingType,value=>store$1.activeSetting=value.value,{immediate:!0}),watch(activeSettingType,(newValue,oldValue)=>{newValue.value&&oldValue.value}),onMounted(()=>{getUINavServiceInstance().useCrossfire=!1}),onUnmounted(async()=>{getUINavServiceInstance().useCrossfire=!0});let setTool=settingType=>{currentIndex.value=settingTypes.value.findIndex(x=>x.value===settingType.value)},goPreviousTab=()=>{currentIndex.value=currentIndex.value>0?currentIndex.value-1:settingTypes.value.length-1},goNextTab=()=>{currentIndex.value=currentIndex.value(openBlock(),createElementBlock(`div`,_hoisted_1$88,[withDirectives((openBlock(),createElementBlock(`div`,_hoisted_2$75,[createBaseVNode(`div`,{onClick:goPreviousTab},[createVNode(unref(bngIcon_default),{type:unref(icons).arrowSmallLeft},null,8,[`type`]),createVNode(unref(bngBinding_default),{action:`menu_tab_left`,deviceMask:`xinput`})]),createBaseVNode(`div`,_hoisted_3$65,[(openBlock(!0),createElementBlock(Fragment,null,renderList(settingTypes.value,settingType=>withDirectives((openBlock(),createElementBlock(`div`,{key:settingType.value,class:normalizeClass([{active:activeSettingType.value.value===settingType.value},`setting-type`]),onClick:$event=>setTool(settingType)},[createVNode(unref(bngIcon_default),{type:settingType.icon,class:`setting-type-icon`},null,8,[`type`])],10,_hoisted_4$50)),[[unref(BngTooltip_default),activeSettingType.value.value===settingType.value?void 0:settingType.label,`top`]])),128))]),createBaseVNode(`div`,{onClick:goNextTab},[createVNode(unref(bngBinding_default),{action:`menu_tab_right`,deviceMask:`xinput`}),createVNode(unref(bngIcon_default),{type:unref(icons).arrowSmallRight},null,8,[`type`])])])),[[unref(BngBlur_default)],[unref(BngOnUiNav_default),goPreviousTab,`tab_l`],[unref(BngOnUiNav_default),goNextTab,`tab_r`]]),withDirectives((openBlock(),createBlock(LayerSettingsBase_default,null,{heading:withCtx(()=>[createBaseVNode(`div`,_hoisted_5$42,[createBaseVNode(`span`,_hoisted_6$30,[createBaseVNode(`span`,null,[createTextVNode(toDisplayString(activeSettingType.value.label)+` `,1),activeSubSetting.value?(openBlock(),createElementBlock(`span`,_hoisted_7$26,`/`)):createCommentVNode(``,!0)]),activeSubSetting.value?(openBlock(),createElementBlock(`span`,_hoisted_8$20,toDisplayString(activeSubSetting.value.label),1)):createCommentVNode(``,!0)]),(unref(store$1).reapplyActive||unref(store$1).requestApplyActive)&&(activeSettingType.value.value!==`transform`||!mouseMode.value)?(openBlock(),createBlock(unref(BindingButton_default),{key:0,icon:unref(icons).restart,accent:`text`,label:`Reset`,uiEvent:CONTROLLER_RESET_BINDING,onClick:resetSettings},null,8,[`icon`])):createCommentVNode(``,!0)])]),default:withCtx(()=>[(openBlock(),createBlock(resolveDynamicComponent(activeSettingType.value.component),{onSubSettingChanged},null,32))]),_:1})),[[unref(BngOnUiNav_default),onAdvanced,`advanced`],[unref(BngBlur_default)]])]))}},LayerSettings_default=__plugin_vue_export_helper_default(_sfc_main$96,[[`__scopeId`,`data-v-ca9ed9d2`]]),_hoisted_1$87={key:0,"bng-ui-scope":`liveryeditor-editmode`,class:`liveryeditor-editmode-layout`},_hoisted_2$74={class:`layers-preview-container`},_hoisted_3$64={class:`layer-settings-wrapper`},SAVE_TYPES={default:1,asGroup:2},FOCUS_LD_TRIGGER_VALUE=-.999,FOCUS_RU_TRIGGER_VALUE=.999,HEADER_TEXT$1=`Edit Mode`,CONTEXT_MENU_NAME=`context-menu`,CONTROLLER_EXIT_BINDING=`back`,CONTROLLER_SAVE_BINDING=`menu`,APPLY_DEFAULT_HINTS=[{id:`apply`,content:{type:`binding`,props:{uiEvent:`ok`},label:`Apply`}},{id:`cancel`,content:{type:`binding`,props:{uiEvent:`back`},label:`Cancel`}}],APPLY_MOUSE_HINTS=[{id:`cancel`,content:{type:`binding`,props:{uiEvent:`back`},label:`Cancel`}}],FREECAM_CONTROLLER_HINTS=[{id:`toggle_freecam`,content:{type:`binding`,props:{uiEvent:`action_4`},label:`Toggle View Point`}}],VIEWPOINT_CONTROLLER_HINTS=[{id:`toggle_freecam`,content:{type:`binding`,props:{uiEvent:`action_4`},label:`Toggle Free Cam`}}],DELETE_LAYER_HINT={id:`delete`,content:{type:`binding`,props:{uiEvent:`advanced`},label:`Delete`}},_sfc_main$95={__name:`EditModeLayout`,setup(__props){useCssVars(_ctx=>({ff7f3326:alphaTextureBackground.value}));let infoBar=useInfoBar(),{showIfController}=storeToRefs(controls_default()),actionHoldService=useActionHoldService(),rootStore=useLiveryEditorStore(),store$1=useLayerSettingsStore(),popover=usePopover(),freecam=ref(!1),CONTEXT_MENU_STYLES=ref({display:`flex`,"flex-direction":`column`}),contextMenuName=ref(`context-menu`),alphaTextureBackground=computed(()=>`url(${getAssetURL(`images/alpha_texture.png`)}`);onBeforeMount(async()=>{await store$1.getInitialData(),watch(showIfController,()=>{actionHoldService.clear()})}),onMounted(()=>{store$1.init(),infoBar.clearHints()}),onUnmounted(()=>{infoBar.clearHints()});async function onAddOrChangeDecal(){await rootStore.toggleShowDecalSelector()}function onBack(){popover.isShown(CONTEXT_MENU_NAME)?popover.hide(CONTEXT_MENU_NAME):store$1.appliedLayers&&store$1.appliedLayers.length>0&&store$1.requestApplyActive?store$1.cancelRequestApply():store$1.appliedLayers&&store$1.reapplyActive?store$1.cancelReapply():confirmCancelChanges()}function onContextMenu(){store$1.reapplyActive?store$1.requestChangeDecal():store$1.requestApplyActive?rootStore.toggleShowDecalSelector():store$1.duplicateActiveLayer()}function onAdvanced(){!store$1.requestApplyActive&&!store$1.reapplyActive&&store$1.activeLayerUid&&store$1.appliedLayers.length>1&&(getUINavServiceInstance().useCrossfire=!0,openConfirmation(`Delete Decal`).then(res=>{res&&store$1.removeAppliedLayer(store$1.activeLayerUid),getUINavServiceInstance().useCrossfire=!0}))}function onOk(){(store$1.requestApplyActive||store$1.reapplyActive)&&store$1.apply()}function confirmSaveChanges(){!store$1.appliedLayers||store$1.appliedLayers.length===0||(getUINavServiceInstance().useCrossfire=!0,openConfirmation(`Save`,`Save changes and exit edit mode?`,[{label:$translate.instant(`ui.common.cancel`),value:void 0,extras:{cancel:!0,accent:ACCENTS.secondary}},{label:$translate.instant(`ui.common.save`),value:SAVE_TYPES.default,extras:{default:!0}}]).then(res=>{res?store$1.saveChanges():getUINavServiceInstance().useCrossfire=!1}))}async function confirmCancelChanges(){getUINavServiceInstance().useCrossfire=!0;let hasChanges=store$1.appliedLayers&&store$1.appliedLayers.length>0;await openConfirmation(`Exit`,hasChanges?`Exit edit mode and lose all changes?`:`Exit Edit Mode?`)?(hasChanges&&await store$1.cancelChanges(),await store$1.deactivate()):getUINavServiceInstance().useCrossfire=!1}let removeLayer=()=>{store$1.removeAppliedLayer(store$1.activeLayerUid),popover.hide(CONTEXT_MENU_NAME)};function onSecondaryAction(element){!store$1.reapplyActive&&!store$1.requestApplyActive&&store$1.requestApply()}function onTertiaryAction(element){store$1.cursorData.applied&&!store$1.reapplyActive&&store$1.toggleHighlightActive()}function onQuaternaryAction(element){freecam.value=!freecam.value}function onRotateHCam(element){if(freecam.value)return!0;let direction$1=element.detail.value;(direction$1>=FOCUS_RU_TRIGGER_VALUE||direction$1<=FOCUS_LD_TRIGGER_VALUE)&&rootStore.switchOrthographicViewByDirection(direction$1>0?-1:1,0)}function onRotateVCam(element){if(freecam.value)return!0;let direction$1=element.detail.value;(direction$1>=FOCUS_RU_TRIGGER_VALUE||direction$1<=FOCUS_LD_TRIGGER_VALUE)&&rootStore.switchOrthographicViewByDirection(0,direction$1>0?-1:1)}let APPLY_CONTROLLER_HINTS=[{id:`change_decal`,content:{type:`binding`,props:{uiEvent:`context`},label:`Change Decal`},action:store$1.requestChangeDecal}],DEFAULT_HINTS=[{id:`duplicate_decal`,content:{type:`binding`,props:{action:`duplicate_active_layer`},label:`Duplicate Decal`,action:store$1.duplicateActiveLayer}},{id:`activate_previous_decal`,content:{type:`binding`,props:{action:`activate_previous_layer`},label:`Edit Previous Decal`}},{id:`activate_next_decal`,content:{type:`binding`,props:{action:`activate_next_layer`},label:`Edit Next Decal`}},{id:`save`,content:{type:`binding`,props:{uiEvent:`menu`},label:`Save`}},{id:`exit`,content:{type:`binding`,props:{uiEvent:`back`},label:`Exit`}}],DEFAULT_CONTROLLER_HINTS=[{id:`apply_or_new`,content:{type:`binding`,props:{uiEvent:`action_2`},label:`New Decal`}},{id:`delete_decal`,content:{type:`binding`,props:{uiEvent:`advanced`},label:`Delete Decal`,action:()=>store$1.removeAppliedLayer(store$1.activeLayerUid)}},{id:`duplicate_decal`,content:{type:`binding`,props:{uiEvent:`context`},label:`Duplicate Decal`},action:()=>store$1.duplicateActiveLayer()},{id:`highlight_decal`,content:{type:`binding`,props:{uiEvent:`action_3`},label:`Toggle Highlight`},action:()=>store$1.toggleHighlightActive()}];watchEffect(()=>{let isController$2=showIfController.value,defaultControllerHints=!1,hints;removeHints(),store$1.requestApplyActive||store$1.reapplyActive?hints=store$1.cursorData.isUseMousePos?APPLY_MOUSE_HINTS:isController$2?APPLY_CONTROLLER_HINTS:APPLY_DEFAULT_HINTS:isController$2?(hints=DEFAULT_CONTROLLER_HINTS,defaultControllerHints=!0):hints=DEFAULT_HINTS;for(let i=0;i1&&infoBar.addHints(DELETE_LAYER_HINT,`change_decal`,!0),(!store$1.appliedLayers||store$1.appliedLayers.length<=1)&&infoBar.removeHints(`delete_decal`)}),watch(()=>freecam.value,async()=>{freecam.value?rootStore.cameraView=`free`:await rootStore.setOrthographicView(`right`)});function removeHints(){APPLY_MOUSE_HINTS.forEach(x=>infoBar.removeHints(x.id)),APPLY_CONTROLLER_HINTS.forEach(x=>infoBar.removeHints(x.id)),APPLY_DEFAULT_HINTS.forEach(x=>infoBar.removeHints(x.id)),DEFAULT_HINTS.forEach(x=>infoBar.removeHints(x.id)),DEFAULT_CONTROLLER_HINTS.forEach(x=>infoBar.removeHints(x.id)),FREECAM_CONTROLLER_HINTS.forEach(x=>infoBar.removeHints(x.id)),VIEWPOINT_CONTROLLER_HINTS.forEach(x=>infoBar.removeHints(x.id)),infoBar.removeHints(DELETE_LAYER_HINT.id)}let headerStore=useEditorHeaderStore(),resetDisabled=ref(!1),saveDisabled=ref(!0),useMouse=computed(()=>store$1.cursorData?store$1.cursorData.isUseMousePos:void 0),changeMouseMode=async newValue=>await store$1.setUseMousePos(newValue),HEADER_APPLY_ITEMS=[{id:`cancel_apply`,section:`end`,component:shallowRef(bngButton_default),props:{label:`Cancel Apply`,accent:ACCENTS.attention},events:{click:()=>{store$1.requestApplyActive&&store$1.cancelRequestApply()}},hidden:!0},{id:`undo_reapply`,section:`end`,component:shallowRef(bngButton_default),props:{label:`Undo Reapply`,accent:ACCENTS.attention},events:{click:()=>{store$1.reapplyActive&&store$1.cancelReapply()}},hidden:!0},{id:`use_mouse`,section:`end`,component:shallowRef(bngSwitch_default),props:{modelValue:useMouse,label:`Use Mouse`,uncheckedWithBackground:!0},events:{"update:modelValue":changeMouseMode}}],showBinding=computed(()=>!store$1.active||!store$1.appliedLayers||store$1.appliedLayers.length===0||!(store$1.reapplyActive||store$1.requestApplyActive)),HEADER_GLOBAL_ITEMS=[{id:`save_changes`,section:`start`,component:shallowRef(BindingButton_default),props:{icon:icons.saveAs1,accent:ACCENTS.main,label:`Save and Exit`,disabled:saveDisabled,uiEvent:CONTROLLER_SAVE_BINDING,deviceMask:`xinput`},events:{click:confirmSaveChanges}},{id:`exit_edit_mode`,section:`start`,component:shallowRef(BindingButton_default),props:{icon:icons.exit,accent:ACCENTS.attention,label:`Exit Edit Mode`,uiEvent:CONTROLLER_EXIT_BINDING,deviceMask:`xinput`,showBinding},events:{click:confirmCancelChanges}}];return watch(()=>store$1.active,active=>{active&&(headerStore.setHeader(HEADER_TEXT$1,`ribbon`),headerStore.setPreheader(void 0))},{immediate:!0}),watchEffect(()=>{store$1.appliedLayers&&store$1.appliedLayers.length>0&&store$1.requestApplyActive?headerStore.showItem(`cancel_apply`):headerStore.hideItem(`cancel_apply`)}),watch(()=>store$1.reapplyActive,value=>{value?headerStore.showItem(`undo_reapply`):headerStore.hideItem(`undo_reapply`)}),watchEffect(()=>{saveDisabled.value=!store$1.appliedLayers||store$1.appliedLayers.length===0,resetDisabled.value=!store$1.requestApplyActive&&!store$1.reapplyActive}),onMounted(()=>{headerStore.removeItems(HEADER_APPLY_ITEMS),headerStore.removeItem(HEADER_GLOBAL_ITEMS),store$1.active&&(headerStore.addItems(HEADER_APPLY_ITEMS,!0),headerStore.addItems(HEADER_GLOBAL_ITEMS))}),onUnmounted(()=>{headerStore.removeItems(HEADER_APPLY_ITEMS),headerStore.removeItems(HEADER_GLOBAL_ITEMS)}),(_ctx,_cache)=>unref(store$1).active?withDirectives((openBlock(),createElementBlock(`div`,_hoisted_1$87,[createBaseVNode(`div`,_hoisted_2$74,[unref(store$1).appliedLayers&&!unref(store$1).requestApplyActive?withDirectives((openBlock(),createBlock(unref(bngImageTile_default),{key:0,icon:unref(icons).decal,class:normalizeClass([{cancel:unref(store$1).requestApplyActive},`add-item`]),disabled:unref(store$1).reapplyActive?`disabled`:``,ratio:`1:1`,onClick:onAddOrChangeDecal},{default:withCtx(()=>[..._cache[0]||=[createBaseVNode(`label`,null,`Add`,-1)]]),_:1},8,[`icon`,`class`,`disabled`])),[[unref(BngBlur_default)]]):withDirectives((openBlock(),createElementBlock(`div`,{key:1,class:`layer-ghost-wrapper`,onClick:onAddOrChangeDecal},[createVNode(DecalPreviewTile_default,{textureImage:unref(store$1).cursorData.decalTexturePath,textureColor:unref(store$1).cursorData.color},null,8,[`textureImage`,`textureColor`]),createVNode(unref(bngIcon_default),{class:`hover-icon`,type:unref(icons).edit},null,8,[`type`])])),[[unref(BngBlur_default)]]),unref(store$1).appliedLayers&&unref(store$1).appliedLayers.length>0?withDirectives((openBlock(),createBlock(EditModeLayersPreview_default,{key:2,contextMenuName:contextMenuName.value},null,8,[`contextMenuName`])),[[unref(BngBlur_default)]]):createCommentVNode(``,!0)]),createBaseVNode(`div`,_hoisted_3$64,[createVNode(unref(LayerSettings_default))]),unref(store$1).appliedLayers&&unref(store$1).appliedLayers.length>0&&unref(store$1).activeLayerUid!==null&&unref(store$1).activeLayerUid!==void 0?(openBlock(),createBlock(unref(bngPopoverContent_default),{key:0,name:contextMenuName.value},{default:withCtx(()=>[createBaseVNode(`div`,{class:`layer-context-menu`,style:normalizeStyle(CONTEXT_MENU_STYLES.value)},[createVNode(unref(bngButton_default),{onClick:withModifiers(unref(store$1).requestChangeDecal,[`stop`])},{default:withCtx(()=>[..._cache[1]||=[createTextVNode(`Change Decal`,-1)]]),_:1},8,[`onClick`]),createVNode(unref(bngButton_default),{disabled:unref(store$1).appliedLayers.length<=1,accent:`attention`,onClick:withModifiers(removeLayer,[`stop`])},{default:withCtx(()=>[..._cache[2]||=[createTextVNode(`Delete`,-1)]]),_:1},8,[`disabled`])],4)]),_:1},8,[`name`])):createCommentVNode(``,!0)])),[[unref(BngOnUiNav_default),onOk,`ok`],[unref(BngOnUiNav_default),onContextMenu,`context`],[unref(BngOnUiNav_default),onAdvanced,`advanced`],[unref(BngOnUiNav_default),onBack,`back`],[unref(BngOnUiNav_default),confirmSaveChanges,`menu`],[unref(BngOnUiNav_default),onSecondaryAction,`action_2`],[unref(BngOnUiNav_default),onTertiaryAction,`action_3`],[unref(BngOnUiNav_default),onQuaternaryAction,`action_4`],[unref(BngOnUiNav_default),onRotateHCam,`rotate_h_cam`],[unref(BngOnUiNav_default),onRotateVCam,`rotate_v_cam`]]):createCommentVNode(``,!0)}},EditModeLayout_default=__plugin_vue_export_helper_default(_sfc_main$95,[[`__scopeId`,`data-v-9b377f5e`]]),_hoisted_1$86={class:`layer-content`},_hoisted_2$73={class:`layer-name`},_hoisted_3$63={key:0,class:`layer-actions`},_hoisted_4$49={class:`layer-preview`},_hoisted_5$41={key:1,class:`group-preview`},_sfc_main$94={__name:`LayerTile`,props:{layer:Object,isTargeted:Boolean,forceShowActions:Boolean,disableMoveUp:Boolean,disableMoveDown:Boolean},emits:[`lockClicked`,`hideClicked`,`moveClicked`,`enableClicked`],setup(__props){let isHovered=ref(!1),toRgba255Styles=colors=>`rgba(${colors[0]*255}, ${colors[1]*255}, ${colors[2]*255}, ${colors[3]})`;return(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,{class:`layer-tile`,onMouseover:_cache[1]||=$event=>isHovered.value=!0,onMouseleave:_cache[2]||=$event=>isHovered.value=!1},[createBaseVNode(`div`,_hoisted_1$86,[renderSlot(_ctx.$slots,`content`,{},()=>[createBaseVNode(`div`,_hoisted_2$73,toDisplayString(__props.layer.name),1),__props.forceShowActions||!__props.layer.enabled?(openBlock(),createElementBlock(`div`,_hoisted_3$63,[__props.forceShowActions?(openBlock(),createBlock(unref(bngBinding_default),{key:0,"track-ignore":!0,uiEvent:`action_2`,deviceMask:`xinput`})):createCommentVNode(``,!0),createVNode(unref(bngButton_default),{accent:`outlined`,onClick:_cache[0]||=$event=>_ctx.$emit(`enableClicked`),icon:__props.layer.enabled?unref(icons).eyeSolidOpened:unref(icons).eyeSolidClosed},null,8,[`icon`])])):createCommentVNode(``,!0)],!0)]),createBaseVNode(`div`,_hoisted_4$49,[__props.layer.type===1?(openBlock(),createElementBlock(`div`,{key:0,class:`fill-preview`,style:normalizeStyle({"--layer-color":toRgba255Styles(__props.layer.color)})},null,4)):__props.layer.type===3?(openBlock(),createElementBlock(`div`,_hoisted_5$41,[createVNode(unref(bngIcon_default),{type:unref(icons).group},null,8,[`type`])])):__props.layer.type===0?(openBlock(),createBlock(DecalPreviewTile_default,{key:2,textureImage:__props.layer.preview,textureColor:__props.layer.color},null,8,[`textureImage`,`textureColor`])):createCommentVNode(``,!0)])],32))}},LayerTile_default=__plugin_vue_export_helper_default(_sfc_main$94,[[`__scopeId`,`data-v-87650a01`]]),_hoisted_1$85={class:`layers-manager`},_hoisted_2$72={class:`layers-manager-header`},_hoisted_3$62=[`onFocusin`];const VIEW_MODES={DEFAULT:`default`,COMPACT:`compact`};var _sfc_main$93={__name:`LayersManager`,props:mergeModels({layers:{type:Array,required:!0},view:{type:String,default:`default`,validator(value){return Object.values(VIEW_MODES).find(x=>x===value)}}},{selectedKeys:{},selectedKeysModifiers:{}}),emits:mergeModels([`focusedLayer`],[`update:selectedKeys`]),setup(__props,{emit:__emit}){let emit$1=__emit,rootStore=useLiveryEditorStore(),expandedKeys=ref([]),selectedKeys=useModel(__props,`selectedKeys`),focusLayer=ref(null),layersScrollable=ref(null);ref(!1);let isFocusFirstLayer=ref(!1);watch(()=>rootStore.selectedLayers,()=>{(!rootStore.selectedLayers||rootStore.selectedLayers.length===0)&&(rootStore.selectMode=`single`)}),watch(()=>selectedKeys.value,(newValue,oldValue)=>{(!newValue||newValue.length===0&&oldValue&&oldValue.length>0)&&(isFocusFirstLayer.value=!0)});let setMultiSelect=async node=>{rootStore.selectMode!==`multi`&&(rootStore.selectMode=`multi`,rootStore.toggleSelection(node.id,!1))},toggleEnabled=layer=>{Lua_default.extensions.ui_liveryEditor_layerAction.performAction(`enabled`).then(luaRes=>{layer.enabled=luaRes})},onClickItem=node=>{Lua_default.extensions.ui_liveryEditor_selection.select(node.id,!0),setFocusLayer(null)},setFocusLayer=layer=>{isFocusFirstLayer.value&&=!1,focusLayer.value=layer,emit$1(`focusedLayer`,layer)},handleFocusOut=event=>{setFocusLayer(null)};return(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$85,[createBaseVNode(`div`,_hoisted_2$72,[renderSlot(_ctx.$slots,`header`,{},void 0,!0)]),__props.layers?(openBlock(),createElementBlock(`div`,{key:0,ref_key:`layersScrollable`,ref:layersScrollable,class:`layers-scrollable`,onFocusout:handleFocusOut},[createVNode(unref(tree_default),{expandedKeys:expandedKeys.value,"onUpdate:expandedKeys":_cache[2]||=$event=>expandedKeys.value=$event,selectedKeys:selectedKeys.value,"onUpdate:selectedKeys":_cache[3]||=$event=>selectedKeys.value=$event,nodes:__props.layers,selectMode:unref(rootStore).selectMode,keyName:`id`,class:`layers-tree`},{node:withCtx(({node,parentNode,expanded,selected,expand})=>[node.hidden?createCommentVNode(``,!0):withDirectives((openBlock(),createElementBlock(`div`,{key:0,onFocusin:withModifiers($event=>setFocusLayer(node),[`self`]),"bng-nav-item":``,class:`layer-node`},[createVNode(LayerTile_default,{layer:node,forceShowActions:focusLayer.value&&focusLayer.value.uid===node.uid,onEnableClicked:()=>toggleEnabled(node)},null,8,[`layer`,`forceShowActions`,`onEnableClicked`]),node.children?(openBlock(),createBlock(unref(bngIcon_default),{key:0,type:expanded?unref(icons).arrowSmallUp:unref(icons).arrowSmallDown,class:`expand-icon`,onMousedown:_cache[0]||=withModifiers(()=>{},[`stop`]),onMouseup:_cache[1]||=withModifiers(()=>{},[`stop`]),onClick:withModifiers(expand,[`stop`])},null,8,[`type`,`onClick`])):createCommentVNode(``,!0)],40,_hoisted_3$62)),[[unref(BngClick_default),{clickCallback:()=>onClickItem(node),holdCallback:()=>setMultiSelect(node),repeatInterval:0}],[unref(BngUiNavFocus_default),isFocusFirstLayer.value&&__props.layers[0].uid===node.uid?0:void 0],[unref(BngFocusIf_default),isFocusFirstLayer.value&&__props.layers[0].uid===node.uid],[unref(BngOnUiNav_default),void 0,`ok`,{asMouse:!0,focusRequired:!0}]])]),_:1},8,[`expandedKeys`,`selectedKeys`,`nodes`,`selectMode`])],544)):createCommentVNode(``,!0)]))}},LayersManager_default=__plugin_vue_export_helper_default(_sfc_main$93,[[`__scopeId`,`data-v-1bc4f03d`]]),_hoisted_1$84={class:`paint-settings`},_sfc_main$92={__name:`PaintSettings`,setup(__props){let LUA_FILL_LAYER=Lua_default.extensions.ui_liveryEditor_layers_fill,paint=new Paint,color=ref({hue:.5,saturation:1,luminosity:.5});function setColor(){paint.hsl=[color.value.hue,color.value.saturation,color.value.luminosity],LUA_FILL_LAYER.updateLayer({color:paint.rgba})}return(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$84,[createVNode(unref(bngColorPicker_default),{modelValue:color.value,"onUpdate:modelValue":_cache[0]||=$event=>color.value=$event,view:`luminosity`},null,8,[`modelValue`]),createBaseVNode(`div`,null,[createVNode(unref(bngButton_default),{onClick:setColor},{default:withCtx(()=>[..._cache[1]||=[createTextVNode(`Save`,-1)]]),_:1})])]))}},PaintSettings_default=__plugin_vue_export_helper_default(_sfc_main$92,[[`__scopeId`,`data-v-66a34a99`]]),_hoisted_1$83={class:`liveryeditor-default-layout`,"bng-ui-scope":`default-layout`},_hoisted_2$71={class:`layers-manager-wrapper`},_hoisted_3$61={key:0,class:`multiselect-header`},_hoisted_4$48={class:`message`},_hoisted_5$40={class:`add-content-wrapper`},_hoisted_6$29={class:`action-tile`},_hoisted_7$25={key:1,class:`layer-settings-wrapper`,"bng-ui-scope":`layer-settings`},SETTINGS_VIEWS={edit:{label:`Edit`,value:`edit`,hideActions:!0,propertySettings:!0,disableLayersManager:!0,props:{excludeSettingTypes:[`transform`]}},order:{label:`Change Order`,value:`order`,component:LayerSortSettings_default,hideActions:!0,disableLayersManager:!0},paint:{label:`Paint`,value:`paint`,component:PaintSettings_default,hideActions:!0,disableLayersManager:!0}},HEADER_TEXT=`Livery Editor`,_sfc_main$91={__name:`DefaultLayout`,setup(__props){useUINavScope(`default-layout`);let rootStore=useLiveryEditorStore(),infoBar=useInfoBar(),{layers:layers$1}=storeToRefs(rootStore),actionsDrawer=ref(null),settingType=shallowRef(null),layerActions=computed(()=>rootStore.layerActions?{label:rootStore.selectedLayers.length===1?`${rootStore.selectedLayers[0].name} Actions`:`${rootStore.selectedLayers.length} Layers Actions`,items:rootStore.layerActions,allowOpenDrawer:!1}:void 0),headerLabel=computed(()=>rootStore.visibleLayersCount===0?`No Layers`:rootStore.visibleLayersCount+` Layer`+rootStore.visibleLayersCount>1?`s`:``),multiSelectMessage=computed(()=>{if(rootStore.selectedLayers)return rootStore.selectedLayers.length+`Layer${rootStore.selectedLayers.length>1?`s`:``}`});onMounted(()=>{getUINavServiceInstance().useCrossfire=!0});function onBack(){settingType.value?(console.log(`onBack > closed settings`),closeSettings()):rootStore.selectedLayers&&rootStore.selectedLayers.length>0?(console.log(`onBack > closed actions`),rootStore.dismissLayerActions().then()):(console.log(`onBack > catch all`),openExitDialog().then())}function onMenu(){settingType.value?closeActions():rootStore.selectedLayers&&rootStore.selectedLayers.length>0||openSaveDialog()}function closeActions(){settingType.value&&closeSettings(),rootStore.dismissLayerActions().then()}function closeSettings(){settingType.value=null}function onActionTriggered(actionItem){let setting=SETTINGS_VIEWS[actionItem.value];setting?settingType.value=setting:rootStore.onActionItemSelected(actionItem).then()}let saving=ref(!1),dialogStates=reactive({isDialogOpen:!1});async function openExitDialog(){if(dialogStates.isDialogOpen)return!0;dialogStates.isDialogOpen=!0,await rootStore.openExitDialog(),dialogStates.isDialogOpen=!1}function openSaveDialog(){if(dialogStates.isDialogOpen)return!0;saving.value=!0,dialogStates.isDialogOpen=!0,rootStore.save().then(()=>{saving.value=!1,dialogStates.isDialogOpen=!1})}function openPaintSettings(){settingType.value=SETTINGS_VIEWS.paint}let saveLabel=computed(()=>saving.value?`Saving...`:`Save`),HEADER_ITEMS=[{id:`save_editor`,section:`start`,component:shallowRef(bngButton_default),props:{icon:icons.saveAs1,accent:ACCENTS.main,label:saveLabel,disabled:saving},events:{click:openSaveDialog}},{id:`exit_editor`,section:`start`,component:shallowRef(bngButton_default),props:{icon:icons.exit,accent:ACCENTS.attention,label:`Exit`},events:{click:openExitDialog}},{id:`paint_settings`,section:`start`,component:shallowRef(bngButton_default),props:{icon:icons.exit,accent:ACCENTS.secondary,label:`Paint`},events:{click:openPaintSettings}}],headerStore=useEditorHeaderStore();watchEffect(()=>{rootStore.currentFile&&rootStore.currentFile.name&&headerStore.setPreheader(rootStore.currentFile.name)}),onMounted(()=>{headerStore.setHeader(HEADER_TEXT),headerStore.addItems(HEADER_ITEMS)}),onUnmounted(()=>{headerStore.removeItems(HEADER_ITEMS)});let NAV_HINTS=[{id:`save`,content:{type:`binding`,props:{uiEvent:`menu`},label:`Save`},action:async()=>await rootStore.save(!1)},{id:`exit`,content:{type:`binding`,props:{uiEvent:`back`},label:`Exit`},action:async()=>rootStore.openExitDialog}],ACTIONS_DRAWER_HINTS=[{id:`actions_back`,content:{type:`binding`,props:{uiEvent:`back`},label:`Back`}}],SETTINGS_NAV_HINTS=[{id:`selected_done`,content:{type:`binding`,props:{uiEvent:`menu`},label:`Done`}},{id:`selected_back`,content:{type:`binding`,props:{uiEvent:`back`},label:`Done (Return to Actions)`}}];return watchEffect(()=>{infoBar.clearHints(),settingType.value?infoBar.addHints(SETTINGS_NAV_HINTS):layerActions.value?infoBar.addHints(ACTIONS_DRAWER_HINTS):infoBar.addHints(NAV_HINTS)}),onMounted(()=>{infoBar.addHints(NAV_HINTS)}),onUnmounted(()=>{infoBar.removeHints(...NAV_HINTS.map(x=>x.id))}),(_ctx,_cache)=>withDirectives((openBlock(),createElementBlock(`div`,_hoisted_1$83,[createBaseVNode(`div`,_hoisted_2$71,[withDirectives((openBlock(),createBlock(unref(LayersManager_default),{selectedKeys:unref(rootStore).selectedLayerUids,"onUpdate:selectedKeys":_cache[0]||=$event=>unref(rootStore).selectedLayerUids=$event,layers:unref(layers$1),class:normalizeClass({inactive:settingType.value&&settingType.value.disableLayersManager})},{header:withCtx(()=>[createVNode(unref(bngCardHeading_default),{type:`ribbon`},{default:withCtx(()=>[createTextVNode(toDisplayString(headerLabel.value),1)]),_:1}),unref(rootStore).selectMode===`multi`?(openBlock(),createElementBlock(`div`,_hoisted_3$61,[withDirectives((openBlock(),createBlock(unref(bngButton_default),{accent:unref(ACCENTS).attention,onClick:closeActions,class:`cancel-btn`},{default:withCtx(()=>[..._cache[1]||=[createTextVNode(`Cancel`,-1)]]),_:1},8,[`accent`])),[[unref(BngOnUiNav_default),void 0,`ok`,{asMouse:!0,focusRequired:!0}]]),createBaseVNode(`span`,_hoisted_4$48,toDisplayString(multiSelectMessage.value),1)])):withDirectives((openBlock(),createBlock(unref(bngButton_default),{key:1,accent:unref(ACCENTS).outlined,disabled:unref(rootStore).selectedLayers&&unref(rootStore).selectedLayers.length>0,onClick:unref(rootStore).toggleEditModeLayout},{default:withCtx(()=>[createBaseVNode(`span`,_hoisted_5$40,[createVNode(unref(bngIcon_default),{type:unref(icons).plus},null,8,[`type`]),_cache[2]||=createBaseVNode(`span`,{class:`add-label`},`Add Decal`,-1)])]),_:1},8,[`accent`,`disabled`,`onClick`])),[[unref(BngOnUiNav_default),void 0,`ok`,{asMouse:!0,focusRequired:!0}]])]),_:1},8,[`selectedKeys`,`layers`,`class`])),[[unref(BngBlur_default)]])]),layerActions.value&&(!settingType.value||!settingType.value.hideActions)?(openBlock(),createBlock(unref(bngActionDrawer_default),{key:0,ref_key:`actionsDrawer`,ref:actionsDrawer,actions:layerActions.value,"item-width":10,"item-margin":1,class:`actions-drawer`,onSelect:onActionTriggered},{controls:withCtx(()=>[withDirectives(createVNode(unref(bngButton_default),{accent:unref(ACCENTS).outlined,icon:unref(icons).abandon,onClick:closeActions},null,8,[`accent`,`icon`]),[[unref(BngOnUiNav_default),void 0,`ok`,{asMouse:!0,focusRequired:!0}]])]),action:withCtx(({item,isLoading,select})=>[createBaseVNode(`div`,_hoisted_6$29,[withDirectives(createVNode(unref(bngImageTile_default),{label:item.toggleAction&&!item.active?item.inactiveLabel:item.label,icon:item.toggleAction&&!item.active?item.inactiveIcon:item.icon,externalImage:item.preview,"bng-nav-item":``,class:`action-tile`,onClick:$event=>select(item)},null,8,[`label`,`icon`,`externalImage`,`onClick`]),[[unref(BngOnUiNav_default),void 0,`ok`,{asMouse:!0,focusRequired:!0}]])])]),_:1},8,[`actions`])):createCommentVNode(``,!0),settingType.value?(openBlock(),createElementBlock(`div`,_hoisted_7$25,[settingType.value.propertySettings?(openBlock(),createBlock(unref(LayerSettings_default),normalizeProps(mergeProps({key:0},settingType.value.props)),null,16)):withDirectives((openBlock(),createBlock(unref(LayerSettingsBase_default),{key:1,heading:settingType.value.label},{default:withCtx(()=>[(openBlock(),createBlock(resolveDynamicComponent(settingType.value.component)))]),_:1},8,[`heading`])),[[unref(BngBlur_default)]])])):createCommentVNode(``,!0)])),[[unref(BngOnUiNav_default),onBack,`back`],[unref(BngOnUiNav_default),onMenu,`menu`]])}},DefaultLayout_default=__plugin_vue_export_helper_default(_sfc_main$91,[[`__scopeId`,`data-v-6dca75f9`]]),_hoisted_1$82={class:`editor`,"bng-ui-scope":`livery-editor`},_hoisted_2$70={class:`editor-header-wrapper`},EDITOR_VIEWS_COMPONENT={[EDITOR_VIEWS.decalSelector]:DecalSelector_default,[EDITOR_VIEWS.editMode]:EditModeLayout_default,[EDITOR_VIEWS.default]:DefaultLayout_default},_sfc_main$90={__name:`LiveryEditor`,setup(__props){let store$1=useLiveryEditorStore(),infobar=useInfoBar(),{showIfController}=storeToRefs(controls_default());infobar.visible=!0;let currentView=computed(()=>EDITOR_VIEWS_COMPONENT[store$1.editorView]),minimizedMode=ref(!1);watch(showIfController,value=>{store$1.setUseMousePos(!value)}),onBeforeMount(async()=>{await store$1.startEditor(),store$1.setUseMousePos(!showIfController.value)});let HEADER_ITEMS=[{id:`camera_view`,section:`end`,component:shallowRef(CameraViewButton_default)}],headerStore=useEditorHeaderStore();return onMounted(()=>{headerStore.setPreheader(store$1.currentFile?store$1.currentFile:`New Save`),headerStore.addItems(HEADER_ITEMS)}),onUnmounted(()=>{headerStore.removeItems(HEADER_ITEMS)}),(_ctx,_cache)=>withDirectives((openBlock(),createElementBlock(`div`,_hoisted_1$82,[createBaseVNode(`div`,_hoisted_2$70,[createVNode(unref(LiveryEditorHeader_default))]),createBaseVNode(`div`,{class:normalizeClass([`editor-content`,{"layers-collapse":minimizedMode.value}])},[(openBlock(),createBlock(resolveDynamicComponent(currentView.value)))],2)])),[[unref(BngOnUiNav_default),()=>{},`menu,back,ok`]])}},LiveryEditor_default=__plugin_vue_export_helper_default(_sfc_main$90,[[`__scopeId`,`data-v-27ec64b0`]]),_hoisted_1$81={class:`livery-main-view`,"bng-ui-scope":`livery-main-scope`},_hoisted_2$69={key:0,class:`loading-overlay`},_hoisted_3$60={class:`header`},_hoisted_4$47={class:`main-view-content`},_hoisted_5$39={class:`menu-container`},MENU_ITEMS$2=[{label:`Paint`,value:`paint`,icon:icons.colorPalette},{label:`Decals`,value:`decals`,icon:icons.decal},{label:`Settings`,value:`settings`,icon:icons.gearTuningOutline}],blockedEvents=[`tab_l`,`tab_r`],_sfc_main$89={__name:`LiveryMainNew`,setup(__props){let infobar=useInfoBar(),uiNavBlocker=useUINavBlocker(),store$1=useLiveryMainStore(),headerStore=useEditorHeaderStore();useUINavScope(`livery-main-scope`);function onMenuItemClicked(item){switch(item){case`paint`:window.bngVue.gotoGameState(`LiveryPaint`);break;case`decals`:window.bngVue.gotoGameState(`LiveryDecals`);break;case`settings`:window.bngVue.gotoGameState(`LiverySettings`);break}}let openedDialog=ref(null);onBeforeMount(async()=>{await store$1.setup(),headerStore.setHeader(`Livery Editor`),headerStore.setPreheader(null)}),onMounted(()=>{infobar.visible=!0,infobar.showSysInfo=!0,uiNavBlocker.blockOnly(blockedEvents)}),onUnmounted(()=>{uiNavBlocker.clear()});function exit(){store$1.exit().then(()=>{window.bngVue.gotoGameState(`garagemode`)})}function promptSave(){openedDialog.value||(openedDialog.value=`save`,openPrompt(`Enter save name`,`Save`,{buttons:[{label:`Save`,value:text=>({value:1,text}),extras:{default:!0}},{label:`Save and Exit`,value:text=>({value:-1,text}),extras:{accent:ACCENTS.secondary}},{label:`Cancel`,value:text=>({value:0,text}),extras:{cancel:!0,accent:ACCENTS.attention}}],defaultValue:store$1.currentSave.name}).then(res=>{let{value,text}=res;value!==0&&(store$1.currentSave.name=text,store$1.save().then(()=>{value===-1&&openProgress(`Saving and exporting skin...`,`Save`,{cancellable:!1,indeterminate:!0,timeout:1}).promise.then(()=>exit())}),openedDialog.value=null)}))}function promptBack(event){if(openedDialog.value){event.stopPropagation();return}openedDialog.value=`back`,openConfirmation(`Save`,`Save your changes`,[{label:`Save`,value:1,extras:{default:!0}},{label:`Exit (discard changes)`,value:-1,extras:{accent:ACCENTS.attention}},{label:`Cancel`,value:0,extras:{cancel:!0,accent:ACCENTS.secondary}}]).then(res=>{openedDialog.value=null,res===1?promptSave():res===-1&&exit()}),event.stopPropagation()}return(_ctx,_cache)=>withDirectives((openBlock(),createElementBlock(`div`,_hoisted_1$81,[unref(store$1).isSetupDone?createCommentVNode(``,!0):(openBlock(),createElementBlock(`div`,_hoisted_2$69,[..._cache[0]||=[createBaseVNode(`h1`,{class:`text`},`Loading...`,-1)]])),createBaseVNode(`div`,_hoisted_3$60,[createVNode(unref(LiveryEditorHeader_default))]),createBaseVNode(`div`,_hoisted_4$47,[createBaseVNode(`div`,_hoisted_5$39,[(openBlock(),createElementBlock(Fragment,null,renderList(MENU_ITEMS$2,(item,index)=>withDirectives(createVNode(unref(bngImageTile_default),{"bng-nav-item":``,key:item.value,label:item.label,icon:item.icon,onClick:$event=>onMenuItemClicked(item.value)},null,8,[`label`,`icon`,`onClick`]),[[unref(BngBlur_default)],[unref(BngUiNavFocus_default),MENU_ITEMS$2.length-index]])),64))])])])),[[unref(BngOnUiNav_default),promptBack,`menu`],[unref(BngOnUiNav_default),promptBack,`back`],[unref(BngUiNavLabel_default),`Save/Exit`,`menu,back`]])}},LiveryMainNew_default=__plugin_vue_export_helper_default(_sfc_main$89,[[`__scopeId`,`data-v-a9fbf094`]]),_hoisted_1$80={class:`save-info-container`},_hoisted_2$68={class:`file-name`},_hoisted_3$59={class:`file-modified`},_hoisted_4$46={class:`file-size`},_hoisted_5$38={key:0,class:`save-file-actions`},_sfc_main$88=Object.assign({width:14,height:6,margin:.25},{__name:`FileListItem`,props:{name:{type:String,required:!0},location:{type:String,required:!0},modifiedFormatted:String,fileSizeFormatted:String,selected:Boolean},setup(__props){let store$1=useLiveryFileStore(),mainStore=useLiveryMainStore(),props=__props,activated=ref(!1),openedDialog=ref(null);function load(){mainStore.load(props),window.bngVue.gotoGameState(`LiveryMain`)}function rename(){let model={name:props.name};nextTick(()=>{openedDialog.value=`rename`}),openFormDialog(FileEditForm_default,model,model$1=>model$1.name!==null&&model$1.name!==void 0&&model$1.name!==``,`Rename file`,`Enter new name`).then(res=>{res.value&&store$1.renameFile(props,res.formData.name),forceActivateScope()})}function deleteSave(){openConfirmation(`Delete`,`Are you sure you want to delete ${props.name}`).then(res=>{res?store$1.deleteFile(props):forceActivateScope()})}function onActivate$1(activate){activated.value=activate,nextTick(()=>{activate&&openedDialog.value&&(openedDialog.value=null)})}function forceActivateScope(){nextTick(()=>{activated.value=!0})}return(_ctx,_cache)=>withDirectives((openBlock(),createElementBlock(`div`,{class:`file-list-item`,onActivate:_cache[0]||=$event=>onActivate$1(!0),onDeactivate:_cache[1]||=$event=>onActivate$1(!1)},[createBaseVNode(`div`,_hoisted_1$80,[createBaseVNode(`div`,_hoisted_2$68,toDisplayString(__props.name),1),createBaseVNode(`div`,_hoisted_3$59,toDisplayString(__props.modifiedFormatted),1),createBaseVNode(`div`,_hoisted_4$46,toDisplayString(__props.fileSizeFormatted),1)]),__props.selected?(openBlock(),createElementBlock(`div`,_hoisted_5$38,[createVNode(unref(bngButton_default),{icon:unref(icons).import,onClick:load},null,8,[`icon`]),createVNode(unref(bngButton_default),{icon:unref(icons).rename,accent:unref(ACCENTS).secondary,onClick:rename},null,8,[`icon`,`accent`]),createVNode(unref(bngButton_default),{icon:unref(icons).trashBin2,accent:unref(ACCENTS).attention,onClick:deleteSave},null,8,[`icon`,`accent`])])):createCommentVNode(``,!0)],32)),[[unref(BngScopedNav_default),{activated:activated.value}]])}}),FileListItem_default=__plugin_vue_export_helper_default(_sfc_main$88,[[`__scopeId`,`data-v-46a472ab`]]),_hoisted_1$79={class:`livery-manager-view`,"bng-ui-scope":`livery-manager-scope`},_hoisted_2$67={class:`header`},_hoisted_3$58={class:`main-view-content`},_hoisted_4$45={key:1,class:`empty-save-container`},_hoisted_5$37={class:`empty-save-message`},_hoisted_6$28={key:1,class:`menu-container`},_sfc_main$87={__name:`LiveryManager`,setup(__props){let store$1=useLiveryFileStore(),mainStore=useLiveryMainStore(),headerStore=useEditorHeaderStore(),infobar=useInfoBar(),uiNavBlocker=useUINavBlocker();useUINavScope(`livery-manager-scope`);let{files}=storeToRefs(store$1),selectedSave=ref(null),screenState=reactive({isOpenLiveries:!1}),MENU_ITEMS$4=[{label:`New Livery`,value:`new`,icon:icons.plus,action:onCreateNew},{label:`Open Liveries`,value:`load`,icon:icons.decal,action:onOpenLiveries}];watch(()=>files.value,()=>selectedSave.value=null,{deep:!0}),onBeforeMount(()=>{store$1.init()}),onMounted(()=>{headerStore.setHeader(`Livery Editor`),headerStore.setPreheader(null),uiNavBlocker.blockOnly([`tab_l`,`tab_r`]),infobar.visible=!0}),onUnmounted(()=>{uiNavBlocker.clear()});function onCreateNew(){mainStore.isSetupDone=!1,window.bngVue.gotoGameState(`LiveryMain`)}function onOpenLiveries(){screenState.isOpenLiveries=!0,headerStore.setPreheader(`Liveries`)}function goBack(event){screenState.isOpenLiveries?(screenState.isOpenLiveries=!1,selectedSave.value=null):window.bngVue.gotoGameState(`garagemode`),event.stopPropagation()}return(_ctx,_cache)=>withDirectives((openBlock(),createElementBlock(`div`,_hoisted_1$79,[createBaseVNode(`div`,_hoisted_2$67,[createVNode(unref(LiveryEditorHeader_default))]),createBaseVNode(`div`,_hoisted_3$58,[screenState.isOpenLiveries?(openBlock(),createElementBlock(Fragment,{key:0},[unref(files)&&unref(files).length>0?withDirectives((openBlock(),createBlock(unref(bngList_default),{key:0,layout:unref(LIST_LAYOUTS).LIST,"target-width":14,"target-height":6,"target-margin":.25,big:!0,class:`files-list`},{default:withCtx(()=>[(openBlock(!0),createElementBlock(Fragment,null,renderList(unref(files),(file$1,index)=>withDirectives((openBlock(),createBlock(FileListItem_default,mergeProps({ref_for:!0},file$1,{key:file$1.name,selected:selectedSave.value===index,onFocus:$event=>selectedSave.value=index,onClick:$event=>selectedSave.value=index}),null,16,[`selected`,`onFocus`,`onClick`])),[[unref(BngFocusIf_default),selectedSave.value===null&&index===0]])),128))]),_:1},8,[`layout`])),[[unref(BngBlur_default)]]):(openBlock(),createElementBlock(`div`,_hoisted_4$45,[withDirectives((openBlock(),createElementBlock(`div`,_hoisted_5$37,[..._cache[0]||=[createTextVNode(`No saved liveries`,-1)]])),[[unref(BngBlur_default)]])]))],64)):(openBlock(),createElementBlock(`div`,_hoisted_6$28,[(openBlock(),createElementBlock(Fragment,null,renderList(MENU_ITEMS$4,(item,index)=>withDirectives(createVNode(unref(bngImageTile_default),{key:item.value,label:item.label,icon:item.icon,onClick:item.action},null,8,[`label`,`icon`,`onClick`]),[[unref(BngUiNavFocus_default),MENU_ITEMS$4.length-index],[unref(BngBlur_default)]])),64))]))])])),[[unref(BngOnUiNav_default),goBack,`back,menu`],[unref(BngUiNavLabel_default),`Back`,`back,menu`]])}},LiveryManager_default=__plugin_vue_export_helper_default(_sfc_main$87,[[`__scopeId`,`data-v-8e7dbe60`]]),_hoisted_1$78={class:`material-settings-content`},_hoisted_2$66={class:`color-values-container`,"bng-no-child-nav":``},_sfc_main$86={__name:`MaterialSettings`,props:{initialColor:Array},emits:[`change`],setup(__props,{emit:__emit}){let props=__props,emit$1=__emit,paint=new Paint,color=ref({hue:.5,saturation:1,luminosity:.5}),inputHue=computed({get:()=>color.value.hue.toFixed(3),set:newValue=>{color.value.hue=typeof newValue==`string`?+newValue:newValue,notifyListeners()}}),inputSat=computed({get:()=>color.value.saturation.toFixed(3),set:newValue=>{color.value.saturation=typeof newValue==`string`?+newValue:newValue,notifyListeners()}}),inputLum=computed({get:()=>color.value.luminosity.toFixed(3),set:newValue=>{color.value.luminosity=typeof newValue==`string`?+newValue:newValue,notifyListeners()}}),isPreciseActive=ref(!1),colorPickerStep=computed(()=>isPreciseActive.value?.001:.01);watch(()=>props.initialColor,()=>{props.initialColor&&(paint.rgba=props.initialColor,color.value.hue=paint.hsl[0],color.value.saturation=paint.hsl[1],color.value.luminosity=paint.hsl[2])},{deep:!0,immediate:!0});function notifyListeners(){let hsl=[color.value.hue,color.value.saturation,color.value.luminosity];paint.hsl=hsl,emit$1(`change`,{colorHsl:hsl,colorRgb:paint.rgb})}function handleAction2(element){isPreciseActive.value=element.detail.value===1}return(_ctx,_cache)=>withDirectives((openBlock(),createBlock(unref(LayerSettingsBase_default),{class:`material-settings`},{heading:withCtx(()=>[..._cache[4]||=[createTextVNode(`Color`,-1)]]),default:withCtx(()=>[createBaseVNode(`div`,_hoisted_1$78,[createVNode(unref(bngColorPicker_default),{modelValue:color.value,"onUpdate:modelValue":_cache[0]||=$event=>color.value=$event,step:colorPickerStep.value,onChange:notifyListeners},null,8,[`modelValue`,`step`]),createBaseVNode(`div`,_hoisted_2$66,[createVNode(unref(bngInput_default),{prefix:`h`,modelValue:inputHue.value,"onUpdate:modelValue":_cache[1]||=$event=>inputHue.value=$event},null,8,[`modelValue`]),createVNode(unref(bngInput_default),{prefix:`s`,modelValue:inputSat.value,"onUpdate:modelValue":_cache[2]||=$event=>inputSat.value=$event},null,8,[`modelValue`]),createVNode(unref(bngInput_default),{prefix:`b`,modelValue:inputLum.value,"onUpdate:modelValue":_cache[3]||=$event=>inputLum.value=$event},null,8,[`modelValue`])])])]),_:1})),[[unref(BngUiNavLabel_default),`[Hold] Precise`,`action_2`],[unref(BngOnUiNav_default),handleAction2,`action_2`,{up:!0}],[unref(BngOnUiNav_default),handleAction2,`action_2`,{down:!0}]])}},MaterialSettings_default=__plugin_vue_export_helper_default(_sfc_main$86,[[`__scopeId`,`data-v-45b64f6e`]]),_hoisted_1$77={class:`paint-main-view`,"bng-ui-scope":`paint-main-scope`},_hoisted_2$65={class:`header`},_hoisted_3$57={class:`paint-content-container`},_hoisted_4$44={class:`paint-content`},_sfc_main$85={__name:`LiveryPaintMain`,setup(__props){let store$1=useLiveryMainStore(),headerStore=useEditorHeaderStore(),infobar=useInfoBar(),uiNavBlocker=useUINavBlocker(),{events:events$3}=useBridge();useUINavScope(`paint-main-scope`);let initialColor=ref(null),blockedEvents$1=[`tab_r`,`tab_l`];onMounted(()=>{headerStore.setPreheader([`Paint`]),store$1.setup(),infobar.visible=!0,infobar.showSysInfo=!0,uiNavBlocker.blockOnly(blockedEvents$1),events$3.on(`liveryEditor_fill_layerData`,onLayerData),Lua_default.extensions.ui_liveryEditor_layers_fill.requestLayerData()}),onUnmounted(()=>{uiNavBlocker.clear(),events$3.off(`liveryEditor_fill_layerData`)});function onLayerData(data){console.log(`layer data changed`,data),initialColor.value=data.color}function saveChanges(){Lua_default.extensions.ui_liveryEditor_layers_fill.saveChanges().then(()=>{window.bngVue.gotoGameState(`LiveryMain`)})}function restoreDefault(){Lua_default.extensions.ui_liveryEditor_layers_fill.restoreDefault()}function cancelChanges(){openConfirmation(`Undo Changes`,`Lose unsaved changes?`).then(res=>{res&&(Lua_default.extensions.ui_liveryEditor_layers_fill.restoreLayer(),window.bngVue.gotoGameState(`LiveryMain`))})}function onMaterialValueChanged(data){Lua_default.extensions.ui_liveryEditor_layers_fill.updateLayer({color:data.colorRgb})}return(_ctx,_cache)=>withDirectives((openBlock(),createElementBlock(`div`,_hoisted_1$77,[createBaseVNode(`div`,_hoisted_2$65,[createVNode(unref(LiveryEditorHeader_default))]),createBaseVNode(`div`,_hoisted_3$57,[createBaseVNode(`div`,_hoisted_4$44,[withDirectives(createVNode(MaterialSettings_default,{"initial-color":initialColor.value,onChange:onMaterialValueChanged},null,8,[`initial-color`]),[[unref(BngBlur_default)]]),withDirectives((openBlock(),createBlock(unref(bngButton_default),{onClick:saveChanges},{default:withCtx(()=>[createVNode(unref(bngBinding_default),{controller:``,"ui-event":`context`}),_cache[0]||=createBaseVNode(`span`,null,`Apply`,-1)]),_:1})),[[unref(BngOnUiNav_default),void 0,`context`,{asMouse:!0}]]),withDirectives((openBlock(),createBlock(unref(bngButton_default),{accent:`secondary`,onClick:restoreDefault},{default:withCtx(()=>[createVNode(unref(bngBinding_default),{controller:``,"ui-event":`action_3`}),_cache[1]||=createBaseVNode(`span`,null,`Restore Default`,-1)]),_:1})),[[unref(BngOnUiNav_default),void 0,`action_3`,{asMouse:!0}]])])])])),[[unref(BngOnUiNav_default),cancelChanges,`back,menu`],[unref(BngUiNavLabel_default),`Back`,`back,menu`]])}},LiveryPaintMain_default=__plugin_vue_export_helper_default(_sfc_main$85,[[`__scopeId`,`data-v-74e232cb`]]),_hoisted_1$76={class:`layer-inspector-base`},_hoisted_2$64={class:`inspector-heading`},_hoisted_3$56={class:`inspector-content`},_sfc_main$84={__name:`LayerInspectorBase`,props:{heading:{type:String}},setup(__props){return useSlots(),(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$76,[createBaseVNode(`div`,_hoisted_2$64,[createVNode(unref(bngCardHeading_default),{type:`ribbon`},{default:withCtx(()=>[renderSlot(_ctx.$slots,`heading`,{},()=>[createBaseVNode(`span`,null,toDisplayString(__props.heading),1)],!0)]),_:3})]),createBaseVNode(`div`,_hoisted_3$56,[renderSlot(_ctx.$slots,`default`,{},void 0,!0)])]))}},LayerInspectorBase_default=__plugin_vue_export_helper_default(_sfc_main$84,[[`__scopeId`,`data-v-c60f30a4`]]),_hoisted_1$75={class:`direction-buttons-row`},_hoisted_2$63={class:`icon-binding-wrapper`},_hoisted_3$55={class:`icon-binding-wrapper`},_hoisted_4$43={class:`direction-buttons-row`},_hoisted_5$36={class:`icon-binding-wrapper`},_hoisted_6$27={class:`stacked-arrows`},_hoisted_7$24={class:`icon-binding-wrapper`},_hoisted_8$19={class:`stacked-arrows`},_hoisted_9$17={class:`dropdown-container`},_sfc_main$83={__name:`LayerOrder`,setup(__props){let ORDER_TOOL$1=Lua_default.extensions.ui_liveryEditor_tools_group,store$1=useLiveryEditorStore(),_order=ref(2),order=computed({get:()=>_order.value,set(newValue){_order.value=newValue,ORDER_TOOL$1.setOrder(newValue)}});computed(()=>store$1.selectedLayers[0].siblingCount);let orderOptions=computed(()=>Array.from({length:store$1.layers.length-1},(_,i)=>({label:`${i+1}`,value:i+2})));onMounted(()=>{store$1.selectedLayers&&store$1.selectedLayers.length>0&&(_order.value=store$1.selectedLayers[0].order)});let moveUp=()=>{ORDER_TOOL$1.moveOrderUp().then(value=>_order.value=value)},moveDown=()=>{ORDER_TOOL$1.moveOrderDown().then(value=>_order.value=value)},moveToTop=()=>{ORDER_TOOL$1.changeOrderToTop().then(value=>_order.value=value)},moveToBottom=()=>{ORDER_TOOL$1.changeOrderToBottom().then(value=>_order.value=value)};return(_ctx,_cache)=>withDirectives((openBlock(),createBlock(LayerInspectorBase_default,{heading:`Order`},{default:withCtx(()=>[createBaseVNode(`div`,_hoisted_1$75,[withDirectives((openBlock(),createBlock(unref(bngTile_default),{"bng-nav-item":``,label:`Move Up`,onClick:moveUp},{default:withCtx(()=>[createBaseVNode(`div`,_hoisted_2$63,[createVNode(unref(bngIcon_default),{type:unref(icons).arrowLargeUp},null,8,[`type`])])]),_:1})),[[unref(BngOnUiNav_default),moveUp,`ok`,{focusRequired:!0}]]),withDirectives((openBlock(),createBlock(unref(bngTile_default),{"bng-nav-item":``,label:`Move Down`,onClick:moveDown},{default:withCtx(()=>[createBaseVNode(`div`,_hoisted_3$55,[createVNode(unref(bngIcon_default),{type:unref(icons).arrowLargeDown},null,8,[`type`])])]),_:1})),[[unref(BngOnUiNav_default),moveDown,`ok`,{focusRequired:!0}]])]),createBaseVNode(`div`,_hoisted_4$43,[withDirectives((openBlock(),createBlock(unref(bngTile_default),{"bng-nav-item":``,label:`Move to Top`,onClick:moveToTop},{default:withCtx(()=>[createBaseVNode(`div`,_hoisted_5$36,[createBaseVNode(`div`,_hoisted_6$27,[createVNode(unref(bngIcon_default),{type:unref(icons).arrowLargeUp},null,8,[`type`]),createVNode(unref(bngIcon_default),{type:unref(icons).arrowLargeUp},null,8,[`type`])])])]),_:1})),[[unref(BngOnUiNav_default),moveToTop,`ok`,{focusRequired:!0}]]),withDirectives((openBlock(),createBlock(unref(bngTile_default),{"bng-nav-item":``,label:`Move to Bottom`,onClick:moveToBottom},{default:withCtx(()=>[createBaseVNode(`div`,_hoisted_7$24,[createBaseVNode(`div`,_hoisted_8$19,[createVNode(unref(bngIcon_default),{type:unref(icons).arrowLargeDown,disabled:unref(store$1).selectedLayers.length>1},null,8,[`type`,`disabled`]),createVNode(unref(bngIcon_default),{type:unref(icons).arrowLargeDown,disabled:unref(store$1).selectedLayers.length>1},null,8,[`type`,`disabled`])])])]),_:1})),[[unref(BngOnUiNav_default),moveToBottom,`ok`,{focusRequired:!0}]])]),createBaseVNode(`div`,_hoisted_9$17,[createVNode(unref(bngDropdown_default),{modelValue:order.value,"onUpdate:modelValue":_cache[0]||=$event=>order.value=$event,items:orderOptions.value},null,8,[`modelValue`,`items`])])]),_:1})),[[unref(BngBlur_default)]])}},LayerOrder_default=__plugin_vue_export_helper_default(_sfc_main$83,[[`__scopeId`,`data-v-d8fda3d9`]]),_hoisted_1$74={class:`decals-main-view`,"bng-ui-scope":`decals-main-scope`},_hoisted_2$62={class:`header`},_hoisted_3$54={class:`main-view-content`},_hoisted_4$42={class:`add-content-wrapper`},_hoisted_5$35={class:`action-tile`},_hoisted_6$26={key:1,class:`popup-settings`},CAMERA_BUTTONS$1=[{label:`Right`,icon:icons.cameraSideRight,value:`right`},{label:`Front`,icon:icons.cameraFront1,value:`front`},{label:`Left`,icon:icons.cameraSideLeft,value:`left`},{label:`Back`,icon:icons.cameraBack1,value:`back`},{label:`Top Right`,icon:icons.cameraTop1,value:`topright`},{label:`Top Left`,icon:icons.cameraTop1,value:`topleft`},{label:`Top Front`,icon:icons.cameraTop1,value:`topfront`},{label:`Top Back`,icon:icons.cameraTop1,value:`topback`}],BLOCKED_UINAV_EVENTS$1=[`tab_l`,`tab_r`],SHOW_HIDE_DECAL_EVENT=`action_2`,_sfc_main$82={__name:`LiveryDecalsMain`,setup(__props){let ACTION_ITEM_ICON={requestReproject:icons.view,transform:icons.transform,materials:icons.colorPalette,highlight:icons.lightGarageG11,requestMirror:icons.reflect,order:icons.sortAscDown,enabled:icons.eyeOutlineOpened,"enabled-off":icons.eyeOutlineClosed,delete:icons.trashBin1,duplicate:icons.copy},layerActionsState=reactive({mirrored:!1,mirrorFlipped:!1,highlight:!0,enabled:!0}),MIRROR_ITEMS=[{label:`Mirror`,value:`mirror`,isSwitch:!0,switchValue:toRef(layerActionsState,`mirrored`)},{label:`Flip Mirrored`,value:`flipMirrored`,isSwitch:!0,switchValue:toRef(layerActionsState,`mirrorFlipped`),disabled:computed(()=>!layerActionsState.mirrored)}],headerStore=useEditorHeaderStore(),infobar=useInfoBar();useUINavScope(`decals-main-scope`);let uiNavBlocker=useUINavBlocker(),{events:events$3}=useBridge(),layers$1=ref([]),selectedLayers=ref([]),layerActions=ref([]),allowActionsDrawerShow=ref(!0),actionDrawer=ref(null),currentActionDrawerLevel=ref(null),popupSettings=ref(null),isReprojectActive=ref(!1),focusedLayer=ref(null),selectedLayerKeys=computed(()=>selectedLayers.value?selectedLayers.value.map(x=>x.uid):null),actionsDrawerData=computed(()=>{let layerName=selectedLayers.value&&selectedLayers.value.length>0?selectedLayers.value[0].name:null;return layerActions.value&&layerActions.value.length>0?{label:layerName,items:layerActions.value,allowOpenDrawer:!1}:void 0}),contextUIEventLabel=computed(()=>isReprojectActive.value?`Reproject`:`Add Decal`),action2UIEventLabel=computed(()=>focusedLayer.value||selectedLayers.value&&selectedLayers.value.length>0?`Enable/Disable Decal`:void 0);watchEffect(()=>{let eventsToBlock=[...BLOCKED_UINAV_EVENTS$1];uiNavBlocker.clear(),(isReprojectActive.value||!focusedLayer.value&&(!selectedLayers.value||selectedLayers.value.length===0))&&eventsToBlock.push(SHOW_HIDE_DECAL_EVENT),uiNavBlocker.blockOnly(eventsToBlock)}),onBeforeMount(()=>{headerStore.setPreheader([`Decals`])}),onMounted(()=>{infobar.visible=!0,infobar.showSysInfo=!0,events$3.on(`liveryEditor_OnLayersUpdated`,onLayersUpdated),events$3.on(`liveryEditor_selection_actionsUpdated`,onActionsUpdated),events$3.on(`liveryEditor_selection_selectedChanged`,onSelectedChanged),Lua_default.extensions.ui_liveryEditor_layers.requestInitialData(),Lua_default.extensions.ui_liveryEditor_selection.requestInitialData()}),onBeforeUnmount(()=>{events$3.off(`liveryEditor_OnLayersUpdated`,onLayersUpdated),events$3.off(`liveryEditor_selection_actionsUpdated`,onActionsUpdated),events$3.off(`liveryEditor_selection_selectedChanged`,onSelectedChanged)});function onBack(event){popupSettings.value?(popupSettings.value=null,allowActionsDrawerShow.value=!0):actionsDrawerData.value?handleDrawerBack():window.bngVue.gotoGameState(`LiveryMain`),event.stopPropagation()}function addDecal(){window.bngVue.gotoGameState(`LiveryDecalSelector`)}let isReproject;async function onActionSwitchClicked(item){item.switchValue=await Lua_default.extensions.ui_liveryEditor_layerAction.performAction(item.value)}async function onActionTriggered(item){if(!item.value){currentActionDrawerLevel.value===`requestReproject`&&!isReproject&&await Lua_default.extensions.ui_liveryEditor_layerAction.performAction(`cancelReproject`),isReprojectActive.value=!1,isReproject=!1,currentActionDrawerLevel.value=null;return}if((item.lazyLoadItems||item.items)&&(currentActionDrawerLevel.value=item.value),item.value===`requestReproject`){if(!item.items){let timeoutid=setTimeout(()=>{item.items=CAMERA_BUTTONS$1,clearTimeout(timeoutid)},500)}isReprojectActive.value=!0}else if(item.value===`requestMirror`){item.items=MIRROR_ITEMS;return}else if(item.value===`order`){allowActionsDrawerShow.value=!1,popupSettings.value=markRaw(LayerOrder_default);return}else if(CAMERA_BUTTONS$1.find(x=>x.value===item.value)){await Lua_default.extensions.ui_liveryEditor_camera.setOrthographicView(item.value);return}await Lua_default.extensions.ui_liveryEditor_layerAction.performAction(item.value)}function onLayersUpdated(data){layers$1.value=data}function onActionsUpdated(data){if(layerActions.value=data,data&&Array.isArray(data)&&data.length>0){let highlightAction=layerActions.value.find(x=>x.value===`highlight`);highlightAction.switchValue=toRef(layerActionsState,`highlight`)}}function onSelectedChanged(data){if(selectedLayers.value=data,data&&Array.isArray(data)&&data.length>0){let first=data[0];layerActionsState.highlight=first.highlighted,layerActionsState.mirrored=first.mirrored,layerActionsState.mirrorFlipped=first.mirrorFlipped}}let closeActionDrawer=()=>{currentActionDrawerLevel.value&¤tActionDrawerLevel.value===`requestReproject`&&(Lua_default.extensions.ui_liveryEditor_layerAction.performAction(`cancelReproject`).then(()=>{}),currentActionDrawerLevel.value=null),Lua_default.extensions.ui_liveryEditor_selection.clearSelection()};function handleDrawerBack(){currentActionDrawerLevel.value?actionDrawer.value.goBack():closeActionDrawer()}function onFocusedLayer(layer){focusedLayer.value=layer}let toggleEnabled=()=>{if(focusedLayer.value)Lua_default.extensions.ui_liveryEditor_layerAction.toggleEnabledByLayerUid(focusedLayer.value.uid);else if(selectedLayers.value&&selectedLayers.value.length>0){let layer=selectedLayers.value[0];Lua_default.extensions.ui_liveryEditor_layerAction.performAction(`enabled`).then(luaRes=>{layer.enabled=luaRes})}},handleContext=()=>{isReprojectActive.value?Lua_default.extensions.ui_liveryEditor_layerAction.performAction(`reproject`).then(()=>{isReproject=!0,isReprojectActive.value=!1,actionDrawer.value.goBack()}):popupSettings.value||addDecal()},handleAction2=()=>{if(isReprojectActive.value)return!1;toggleEnabled()};return(_ctx,_cache)=>withDirectives((openBlock(),createElementBlock(`div`,_hoisted_1$74,[createBaseVNode(`div`,_hoisted_2$62,[createVNode(unref(LiveryEditorHeader_default))]),createBaseVNode(`div`,_hoisted_3$54,[withDirectives((openBlock(),createBlock(unref(LayersManager_default),{selectedKeys:selectedLayerKeys.value,"onUpdate:selectedKeys":_cache[0]||=$event=>selectedLayerKeys.value=$event,layers:layers$1.value,class:`layers-manager`,onFocusedLayer},{header:withCtx(()=>[createVNode(unref(bngCardHeading_default),{type:`ribbon`},{default:withCtx(()=>[..._cache[1]||=[createTextVNode(`Layers`,-1)]]),_:1}),withDirectives((openBlock(),createBlock(unref(bngButton_default),{"bng-no-nav":`true`,accent:unref(ACCENTS).outlined,onClick:addDecal},{default:withCtx(()=>[createBaseVNode(`span`,_hoisted_4$42,[createVNode(unref(bngBinding_default),{trackIgnore:!0,uiEvent:`context`,deviceMask:`xinput`}),_cache[2]||=createBaseVNode(`span`,{class:`add-label`},`Add Decal`,-1)])]),_:1},8,[`accent`])),[[unref(BngDisabled_default),isReprojectActive.value]])]),_:1},8,[`selectedKeys`,`layers`])),[[unref(BngBlur_default)]]),actionsDrawerData.value&&allowActionsDrawerShow.value?(openBlock(),createBlock(unref(bngActionDrawer_default),{key:0,ref_key:`actionDrawer`,ref:actionDrawer,blur:``,alwaysShowBack:!1,actions:actionsDrawerData.value,"item-width":10,"item-margin":1,class:`actions-drawer`,onSelect:onActionTriggered},{controls:withCtx(()=>[withDirectives(createVNode(unref(bngButton_default),{accent:unref(ACCENTS).outlined,icon:unref(icons).exit,onClick:closeActionDrawer},null,8,[`accent`,`icon`]),[[unref(BngOnUiNav_default),void 0,`ok`,{asMouse:!0,focusRequired:!0}]])]),action:withCtx(({item,select,order})=>[createBaseVNode(`div`,_hoisted_5$35,[item.isSwitch?withDirectives((openBlock(),createBlock(unref(bngTile_default),{key:0,"bng-nav-item":``,label:item.label,onClick:$event=>onActionSwitchClicked(item)},{default:withCtx(()=>[createVNode(unref(bngSwitch_default),{modelValue:item.switchValue,"onUpdate:modelValue":$event=>item.switchValue=$event},null,8,[`modelValue`,`onUpdate:modelValue`])]),_:2},1032,[`label`,`onClick`])),[[unref(BngUiNavFocus_default),order===0?0:void 0],[unref(BngFocusIf_default),order===0],[unref(BngDisabled_default),item.disabled],[unref(BngOnUiNav_default),void 0,`ok`,{asMouse:!0,focusRequired:!0}]]):withDirectives((openBlock(),createBlock(unref(bngImageTile_default),{key:1,"bng-nav-item":``,label:item.label,icon:item.icon?item.icon:ACTION_ITEM_ICON[item.value],class:`action-tile`,onClick:$event=>select(item)},null,8,[`label`,`icon`,`onClick`])),[[unref(BngUiNavFocus_default),order===0?0:void 0],[unref(BngFocusIf_default),order===0],[unref(BngOnUiNav_default),void 0,`ok`,{asMouse:!0,focusRequired:!0}]])])]),_:1},8,[`actions`])):createCommentVNode(``,!0),popupSettings.value?(openBlock(),createElementBlock(`div`,_hoisted_6$26,[(openBlock(),createBlock(resolveDynamicComponent(popupSettings.value)))])):createCommentVNode(``,!0)])])),[[unref(BngUiNavLabel_default),contextUIEventLabel.value,`context`],[unref(BngUiNavLabel_default),action2UIEventLabel.value,`action_2`],[unref(BngUiNavLabel_default),`Back`,`menu,back`],[unref(BngOnUiNav_default),onBack,`menu,back`],[unref(BngOnUiNav_default),handleContext,`context`],[unref(BngOnUiNav_default),handleAction2,`action_2`]])}},LiveryDecalsMain_default=__plugin_vue_export_helper_default(_sfc_main$82,[[`__scopeId`,`data-v-b9d45c3c`]]),_hoisted_1$73={class:`decal-selector-view`,"bng-ui-scope":`decal-selector-scope`},_hoisted_2$61={class:`header`},_hoisted_3$53={class:`main-view-content`},_hoisted_4$41={key:0,class:`side-menu`},_hoisted_5$34={class:`list-container`},BLOCKED_UINAV_EVENTS=[`tab_l`,`tab_r`],_sfc_main$81={__name:`LiveryDecalSelector`,setup(__props){let headerStore=useEditorHeaderStore(),infobar=useInfoBar(),uiNavBlocker=useUINavBlocker(),{events:events$3}=useBridge();useUINavScope(`decal-selector-scope`);let categorizedTextures=ref([]),selectedCategory=ref(null),textures=computed(()=>{if(categorizedTextures.value&&categorizedTextures.value.length>0&&selectedCategory.value){let cat=categorizedTextures.value.find(x=>x.value===selectedCategory.value);if(cat)return cat.items}return null});async function select(item){let layer=await Lua_default.extensions.ui_liveryEditor_layers_decal.addLayerCentered({texturePath:item.preview});await Lua_default.extensions.ui_liveryEditor_selection.select(layer.uid,!0),window.bngVue.gotoGameState(`LiveryDecals`)}function goBack(event){window.bngVue.gotoGameState(`LiveryDecals`),event.stopPropagation()}function onData(data){categorizedTextures.value=data,!data||data.length===0?selectedCategory.value=null:selectedCategory.value||=data[0].value}return onBeforeMount(()=>{headerStore.setPreheader([`Decals`,`Textures`])}),onMounted(()=>{infobar.visible=!0,infobar.showSysInfo=!0,Lua_default.extensions.ui_liveryEditor_resources.requestData(),events$3.on(`liveryEditor_resources_data`,onData),uiNavBlocker.blockOnly(BLOCKED_UINAV_EVENTS)}),onBeforeMount(()=>{events$3.off(`liveryEditor_resources_data`,onData),uiNavBlocker.clear()}),(_ctx,_cache)=>withDirectives((openBlock(),createElementBlock(`div`,_hoisted_1$73,[createBaseVNode(`div`,_hoisted_2$61,[createVNode(unref(LiveryEditorHeader_default))]),createBaseVNode(`div`,_hoisted_3$53,[categorizedTextures.value?withDirectives((openBlock(),createElementBlock(`div`,_hoisted_4$41,[(openBlock(!0),createElementBlock(Fragment,null,renderList(categorizedTextures.value,category=>(openBlock(),createBlock(unref(bngButton_default),{key:category.value,label:category.label,accent:`text`,onClick:$event=>selectedCategory.value=category.value},null,8,[`label`,`onClick`]))),128))])),[[unref(BngBlur_default)]]):createCommentVNode(``,!0),createBaseVNode(`div`,_hoisted_5$34,[textures.value?withDirectives((openBlock(),createBlock(unref(bngList_default),{key:0,layout:unref(LIST_LAYOUTS).TILES,"target-width":8,"target-height":8,"target-margin":.25,big:!0,class:`textures-list`},{default:withCtx(()=>[(openBlock(!0),createElementBlock(Fragment,null,renderList(textures.value,(item,index)=>withDirectives((openBlock(),createBlock(DecalSelectorItem_default,{"bng-nav-item":``,key:item.preview,externalImage:item.preview,"data-decal-item":index,onClick:$event=>select(item)},null,8,[`externalImage`,`data-decal-item`,`onClick`])),[[unref(BngOnUiNav_default),void 0,`ok`,{asMouse:!0,focusRequired:!0}],[unref(BngUiNavFocus_default),index===0?0:void 0],[unref(BngFocusIf_default),index===0]])),128))]),_:1},8,[`layout`])),[[unref(BngBlur_default)]]):createCommentVNode(``,!0)])])])),[[unref(BngOnUiNav_default),goBack,`back,menu`],[unref(BngUiNavLabel_default),`Back`,`back,menu`]])}},LiveryDecalSelector_default=__plugin_vue_export_helper_default(_sfc_main$81,[[`__scopeId`,`data-v-fc11228e`]]),_hoisted_1$72={class:`layer-edit-view`,"bng-ui-scope":`layer-edit-scope`},_hoisted_2$60={class:`header`},_hoisted_3$52={class:`main-view-content`},_hoisted_4$40={class:`menu-container`},MENU_ITEMS$1=[{label:`Projection`,value:`projection`,icon:icons.decal},{label:`Transform`,value:`transform`,icon:icons.colorPalette},{label:`Materials`,value:`materials`,icon:icons.decal}],noop=()=>{},_sfc_main$80={__name:`LiveryLayerEdit`,setup(__props){useEditorHeaderStore(),useDecalSelectorStore();let mainStore=useLiveryMainStore(),infobar=useInfoBar();useUINavScope(`layer-edit-scope`);function onMenuItemClicked(item){switch(item.value){case`transform`:router_default.push({name:`LayerTransform`});break;case`materials`:router_default.push({name:`LayerMaterials`});break;case`projection`:router_default.push({name:`LayerProjection`});break}}function goBack(){router_default.replace({name:`LiveryDecals`}),mainStore.exitLayerEdit()}function saveChanges(){Lua_default.extensions.ui_liveryEditor_layerEdit.saveChanges(!0).then(()=>goBack())}onBeforeMount(()=>{infobar.clearHints(),infobar.addHints(NAV_HINTS)}),onMounted(async()=>{infobar.visible=!0,infobar.showSysInfo=!0,await mainStore.setupLayerEdit(),await Lua_default.extensions.ui_liveryEditor_layerEdit.showCursorOrLayer(!0)}),onBeforeUnmount(async()=>{await Lua_default.extensions.ui_liveryEditor_layerEdit.showCursorOrLayer(!1)});let NAV_HINTS=[{id:`apply`,content:{type:`binding`,props:{uiEvent:`ok`},label:`Done`},action:saveChanges},{id:`back`,content:{type:`binding`,props:{uiEvent:`back`},label:`Back`},action:goBack}];return(_ctx,_cache)=>withDirectives((openBlock(),createElementBlock(`div`,_hoisted_1$72,[createBaseVNode(`div`,_hoisted_2$60,[createVNode(unref(LiveryEditorHeader_default))]),createBaseVNode(`div`,_hoisted_3$52,[createBaseVNode(`div`,_hoisted_4$40,[(openBlock(),createElementBlock(Fragment,null,renderList(MENU_ITEMS$1,item=>withDirectives(createVNode(unref(bngImageTile_default),{"bng-nav-item":``,key:item.value,label:item.label,icon:item.icon,class:`menu-item`,onClick:$event=>onMenuItemClicked(item)},null,8,[`label`,`icon`,`onClick`]),[[unref(BngBlur_default)]])),64))])])])),[[unref(BngOnUiNav_default),goBack,`back`],[unref(BngOnUiNav_default),saveChanges,`menu`],[unref(BngOnUiNav_default),noop,`rotate_h_cam`],[unref(BngOnUiNav_default),noop,`rotate_v_cam`]])}},LiveryLayerEdit_default=__plugin_vue_export_helper_default(_sfc_main$80,[[`__scopeId`,`data-v-c339e1a6`]]),_hoisted_1$71={class:`camera-settings-view`,"bng-ui-scope":`camera-settings-scope`},_hoisted_2$59={class:`header`},_hoisted_3$51={class:`main-view-content`},_hoisted_4$39={class:`menu-container`},MENU_ITEMS=[{label:`Right`,icon:icons.cameraSideRight,value:`right`},{label:`Front`,icon:icons.cameraFront1,value:`front`},{label:`Left`,icon:icons.cameraSideLeft,value:`left`},{label:`Back`,icon:icons.cameraBack1,value:`back`},{label:`Top Right`,icon:icons.cameraTop1,value:`topright`},{label:`Top Left`,icon:icons.cameraTop1,value:`topleft`},{label:`Top Front`,icon:icons.cameraTop1,value:`topfront`},{label:`Top Back`,icon:icons.cameraTop1,value:`topback`}],_sfc_main$79={__name:`LiveryCameraSettings`,setup(__props){let CAMERA_LUA$1=Lua_default.extensions.ui_liveryEditor_camera,headerStore=useEditorHeaderStore();useDecalSelectorStore();let infobar=useInfoBar();useUINavScope(`camera-settings-scope`);function onMenuItemClicked(item){CAMERA_LUA$1.setOrthographicView(item.value)}function goBack(){router_default.replace({name:`LiveryDecals`})}function done(){router_default.replace({name:`LiveryDecalSelector`})}onBeforeMount(()=>{infobar.clearHints(),infobar.addHints(NAV_HINTS),headerStore.setPreheader([`Select Camera`])}),onMounted(()=>{infobar.visible=!0,infobar.showSysInfo=!0});let NAV_HINTS=[{id:`apply`,content:{type:`binding`,props:{uiEvent:`menu`},label:`Done`}},{id:`back`,content:{type:`binding`,props:{uiEvent:`back`},label:`Back`},action:goBack}];return(_ctx,_cache)=>withDirectives((openBlock(),createElementBlock(`div`,_hoisted_1$71,[createBaseVNode(`div`,_hoisted_2$59,[createVNode(unref(LiveryEditorHeader_default))]),createBaseVNode(`div`,_hoisted_3$51,[createBaseVNode(`div`,_hoisted_4$39,[(openBlock(),createElementBlock(Fragment,null,renderList(MENU_ITEMS,item=>withDirectives(createVNode(unref(bngImageTile_default),{"bng-nav-item":``,key:item.value,label:item.label,icon:item.icon,onClick:$event=>onMenuItemClicked(item)},null,8,[`label`,`icon`,`onClick`]),[[unref(BngBlur_default)]])),64))])])])),[[unref(BngOnUiNav_default),goBack,`back`],[unref(BngOnUiNav_default),done,`menu`]])}},LiveryCameraSettings_default=__plugin_vue_export_helper_default(_sfc_main$79,[[`__scopeId`,`data-v-376ce11c`]]),_hoisted_1$70={class:`layer-transform-view`,"bng-ui-scope":`layer-transform-scope`},_hoisted_2$58={class:`header`},_hoisted_3$50={class:`main-view-content`},_hoisted_4$38={class:`inspector-container`},_hoisted_5$33={class:`transform-setting-item`},_hoisted_6$25={key:0},_hoisted_7$23={key:1,class:`transform-setting-inputs`},_hoisted_8$18={class:`slider-text-container`},_hoisted_9$16={class:`slider-text-container`},_hoisted_10$12={key:2,class:`display-values-container`},_hoisted_11$10={key:1,class:`transform-setting-item`},_hoisted_12$7={key:0,class:`transform-setting-inputs`},_hoisted_13$7={class:`slider-text-container`},_hoisted_14$7={class:`slider-text-container`},_hoisted_15$7={key:1,class:`display-values-container`},_hoisted_16$7={key:3,class:`transform-setting-item`},_hoisted_17$6={key:0,class:`transform-setting-inputs`},_hoisted_18$5={class:`slider-text-container`},_hoisted_19$3={key:1,class:`display-values-container`},_hoisted_20$3={key:5,class:`transform-setting-item`},_hoisted_21$3={key:0,class:`transform-setting-inputs`},_hoisted_22$3={class:`slider-text-container`},_hoisted_23$3={class:`slider-text-container`},_hoisted_24$2={key:1,class:`display-values-container`},_hoisted_25$1={class:`edit-button-label`},INPUT_MIN=0,INPUT_MAX=1,_sfc_main$78={__name:`LayerTransform`,setup(__props){let headerStore=useEditorHeaderStore(),infobar=useInfoBar(),navBlocker=useUINavBlocker(),{events:events$3}=useBridge();useUINavScope(`layer-transform-scope`);let transformState=reactive({positionX:0,positionY:0,scaleX:0,scaleY:0,skewX:0,skewY:0,rotation:0}),isHoldModifier=ref(!1),isPreciseActive=ref(!1),isTabRightActive=ref(!1),stateData=ref(null),isEdit=ref(!1),isReapplying=ref(!1),isRepositionActive=ref(!1),isUseMouse=ref(!1),positionX=computed({get:()=>transformState.positionX,set:newValue=>{let value=assertInt(newValue);transformState.positionX=value,isEdit.value&&Lua_default.extensions.ui_liveryEditor_layerEdit.setPosition(value,transformState.positionY)}}),positionY=computed({get:()=>transformState.positionY,set:newValue=>{let value=assertInt(newValue);transformState.positionY=value,isEdit.value&&Lua_default.extensions.ui_liveryEditor_layerEdit.setPosition(transformState.positionX,value)}}),scaleX=computed({get:()=>transformState.scaleX,set:newValue=>{let value=assertInt(newValue);transformState.scaleX=value,isEdit.value&&Lua_default.extensions.ui_liveryEditor_layerEdit.setScale(value,transformState.scaleY)}}),scaleY=computed({get:()=>transformState.scaleY,set:newValue=>{let value=assertInt(newValue);transformState.scaleY=value,isEdit.value&&Lua_default.extensions.ui_liveryEditor_layerEdit.setScale(transformState.scaleX,value)}}),skewX=computed({get:()=>transformState.skewX,set:newValue=>{let value=assertInt(newValue);transformState.skewX=value,isEdit.value&&Lua_default.extensions.ui_liveryEditor_layerEdit.setSkew(value,transformState.skewY)}}),skewY=computed({get:()=>transformState.skewY,set:newValue=>{let value=assertInt(newValue);transformState.skewY=value,isEdit.value&&Lua_default.extensions.ui_liveryEditor_layerEdit.setSkew(transformState.skewX,value)}}),rotation=computed({get:()=>transformState.rotation,set:newValue=>{let value=assertInt(newValue);transformState.rotation=value,isEdit.value&&Lua_default.extensions.ui_liveryEditor_layerEdit.setRotation(value)}}),hintLabels=computed(()=>{let labels={},focusLabel=`Move`,focusEvents=[`focus_l`,`focus_u`,`focus_r`,`focus_d`,`focus_lr`,`focus_ud`],rotateCamLabel=`Scale`;return isTabRightActive.value?rotateCamLabel=`Pan`:isHoldModifier.value&&(rotateCamLabel=`Skew`),!isTabRightActive.value&&!isHoldModifier.value&&focusEvents.forEach(uiEvent=>labels[uiEvent]=`Move`),[`rotate_h_cam`,`rotate_v_cam`].forEach(uiEvent=>labels[uiEvent]=rotateCamLabel),labels.tab_l=isTabRightActive.value?void 0:`[Hold] Skew`,labels.tab_r=isHoldModifier.value?void 0:`[Hold] Camera`,labels.action_2=isTabRightActive.value?void 0:`[Hold] Precise`,labels});watchEffect(()=>{navBlocker.clear(),isTabRightActive.value&&navBlocker.allowOnly([`rotate_h_cam`,`rotate_v_cam`,`tab_r`]),isHoldModifier.value&&navBlocker.allowOnly([`rotate_h_cam`,`rotate_v_cam`,`action_2`,`tab_l`])}),onBeforeMount(()=>{headerStore.setPreheader([`Transform`])}),onMounted(async()=>{infobar.visible=!0,infobar.showSysInfo=!0,events$3.on(`liveryEditor_layerEdit_state`,onStateData),events$3.on(`liveryEditor_layerEdit_initialLayerData`,onInitialLayerData),events$3.on(`liveryEditor_layerEdit_repositionSuccess`,onRepositionSuccess),events$3.on(`liveryEditor_layerEdit_rotationChanged`,onRotationChanged),events$3.on(`liveryEditor_layerEdit_positionChanged`,onPositionChanged),events$3.on(`liveryEditor_layerEdit_scaleChanged`,onScaleChanged),events$3.on(`liveryEditor_layerEdit_skewChanged`,onSkewChanged),await Lua_default.extensions.ui_liveryEditor_layerEdit.requestStateData(),await Lua_default.extensions.ui_liveryEditor_layerEdit.requestInitialLayerData()}),onBeforeUnmount(async()=>{events$3.off(`liveryEditor_layerEdit_state`,onStateData),events$3.off(`liveryEditor_layerEdit_initialLayerData`,onInitialLayerData),events$3.off(`liveryEditor_layerEdit_repositionSuccess`,onRepositionSuccess),events$3.off(`liveryEditor_layerEdit_rotationChanged`,onRotationChanged),events$3.off(`liveryEditor_layerEdit_positionChanged`,onPositionChanged),events$3.off(`liveryEditor_layerEdit_scaleChanged`,onScaleChanged),events$3.off(`liveryEditor_layerEdit_skewChanged`,onSkewChanged)});function onPositionChanged(position){positionX.value=position.x,positionY.value=position.y}function onRotationChanged(value){transformState.rotation=value}function onSkewChanged(skew){skewX.value=skew.x,skewY.value=skew.y}function onScaleChanged(scale){scaleX.value=scale.x,scaleY.value=scale.y}function onRepositionSuccess(){isRepositionActive.value=!isRepositionActive.value}function handleModifier(element){isHoldModifier.value=element.detail.value===1}function handlePrecise(element){let isPrecise=element.detail.value===1;isPreciseActive.value=isPrecise,Lua_default.extensions.ui_liveryEditor_layerEdit.holdPrecise(isPrecise)}function handleTabRight(element){isTabRightActive.value=element.detail.value===1}function handleAction3(element){isRepositionActive.value?toggleUseMouseOrCursor(element):toggleReposition(element)}function toggleReposition(element){let isReposition=isRepositionActive.value;isReposition?Lua_default.extensions.ui_liveryEditor_layerEdit.cancelReposition():Lua_default.extensions.ui_liveryEditor_layerEdit.requestReposition(),isRepositionActive.value=!isReposition}function toggleUseMouseOrCursor(element){if(!isRepositionActive.value)return!0;Lua_default.extensions.ui_liveryEditor_layerEdit.toggleUseMouseOrCursor().then(data=>{isUseMouse.value=data.isUseMouse})}function toggleEdit(element){if(isRepositionActive.value&&isUseMouse.value)return;let newValue=!isEdit.value;isEdit.value=newValue,Lua_default.extensions.ui_liveryEditor_layerEdit.setAllowRotationAction(!newValue).then(()=>{})}function handleFocusLinear(element){if(isEdit.value)return;let name=element.detail.name,value=element.detail.value,axis=name===`focus_d`||name===`focus_u`?`y`:`x`,direction$1=name===`focus_d`||name===`focus_l`?-1:1;Lua_default.extensions.ui_liveryEditor_layerEdit.holdTranslate(axis,direction$1*value)}function handleTranslateScalar(element){if(isEdit.value)return!0;let name=element.detail.name,value=element.detail.value,axis=name===`focus_lr`?`x`:`y`;Lua_default.extensions.ui_liveryEditor_layerEdit.holdTranslateScalar(axis,value)}function handleRotateCam(element){if(isRepositionActive.value||isTabRightActive.value)return!0;let name=element.detail.name,value=element.detail.value,axis=name===`rotate_h_cam`?`x`:`y`;isHoldModifier.value?Lua_default.extensions.ui_liveryEditor_layerEdit.holdSkew(axis,value):Lua_default.extensions.ui_liveryEditor_layerEdit.holdScale(axis,value)}function goBack(event){isRepositionActive.value?toggleReposition():isEdit.value?toggleEdit():openConfirmation(`Exit`,`Exit and lose unsaved changes?`).then(res=>{res&&(Lua_default.extensions.ui_liveryEditor_layerEdit.endTransform(),Lua_default.extensions.ui_liveryEditor_layerEdit.cancelChanges().then(()=>{window.bngVue.gotoGameState(`LiveryDecals`)}))}),event.stopPropagation()}function handleOk(){isRepositionActive.value?Lua_default.extensions.ui_liveryEditor_layerEdit.applyReposition():(Lua_default.extensions.ui_liveryEditor_layerEdit.endTransform(),Lua_default.extensions.ui_liveryEditor_layerEdit.saveChanges(!1).then(()=>{window.bngVue.gotoGameState(`LiveryDecals`)}))}function saveChanges(){Lua_default.extensions.ui_liveryEditor_layerEdit.saveChanges(!1).then(()=>{window.bngVue.gotoGameState(`LiveryDecals`)})}function onStateData(data){stateData.value=data,isReapplying.value=data.isStampReapplying}function onInitialLayerData(data){positionX.value=data.position.x,positionY.value=data.position.y,scaleX.value=data.scale.x,scaleY.value=data.scale.y,skewX.value=data.skew.x,skewY.value=data.skew.y,rotation.value=data.rotation}function assertInt(value){return typeof value==`string`?+value:value}return(_ctx,_cache)=>withDirectives((openBlock(),createElementBlock(`div`,_hoisted_1$70,[createBaseVNode(`div`,_hoisted_2$58,[createVNode(unref(LiveryEditorHeader_default))]),createBaseVNode(`div`,_hoisted_3$50,[createBaseVNode(`div`,_hoisted_4$38,[withDirectives((openBlock(),createBlock(LayerInspectorBase_default,{heading:`Transform`},{default:withCtx(()=>[createBaseVNode(`div`,{class:normalizeClass([`transform-inspector`,{"inspector-editing":isEdit.value}])},[createBaseVNode(`div`,_hoisted_5$33,[_cache[17]||=createBaseVNode(`div`,{class:`setting-item-name`},`Position`,-1),isRepositionActive.value&&isUseMouse.value?(openBlock(),createElementBlock(`div`,_hoisted_6$25,[..._cache[15]||=[createBaseVNode(`span`,null,`Using mouse position`,-1)]])):isEdit.value?(openBlock(),createElementBlock(`div`,_hoisted_7$23,[createBaseVNode(`div`,_hoisted_8$18,[createVNode(unref(bngInput_default),{modelValue:positionX.value,"onUpdate:modelValue":_cache[0]||=$event=>positionX.value=$event,type:`number`,step:.001,min:INPUT_MIN,max:1,prefix:`X`},null,8,[`modelValue`]),createVNode(unref(bngSlider_default),{modelValue:positionX.value,"onUpdate:modelValue":_cache[1]||=$event=>positionX.value=$event,step:.001,min:INPUT_MIN,max:1},null,8,[`modelValue`])]),createBaseVNode(`div`,_hoisted_9$16,[createVNode(unref(bngInput_default),{modelValue:positionY.value,"onUpdate:modelValue":_cache[2]||=$event=>positionY.value=$event,type:`number`,step:.001,min:INPUT_MIN,max:1,prefix:`Y`},null,8,[`modelValue`]),createVNode(unref(bngSlider_default),{modelValue:positionY.value,"onUpdate:modelValue":_cache[3]||=$event=>positionY.value=$event,step:.001,min:INPUT_MIN,max:1},null,8,[`modelValue`])])])):(openBlock(),createElementBlock(`div`,_hoisted_10$12,[createVNode(unref(bngPropVal_default),{keyLabel:`X`,valueLabel:positionX.value},null,8,[`valueLabel`]),createVNode(unref(bngPropVal_default),{keyLabel:`Y`,valueLabel:positionY.value},null,8,[`valueLabel`])])),isRepositionActive.value?createCommentVNode(``,!0):(openBlock(),createBlock(unref(bngButton_default),{key:3,accent:`outlined`,class:`reposition-button`,onClick:toggleReposition},{default:withCtx(()=>[createVNode(unref(bngBinding_default),{uiEvent:`action_3`}),_cache[16]||=createBaseVNode(`span`,{class:`reposition-button-label`},`Reproject and Position`,-1)]),_:1}))]),isRepositionActive.value?createCommentVNode(``,!0):(openBlock(),createBlock(unref(bngDivider_default),{key:0})),isRepositionActive.value?createCommentVNode(``,!0):(openBlock(),createElementBlock(`div`,_hoisted_11$10,[_cache[18]||=createBaseVNode(`div`,{class:`setting-item-name`},`Scale`,-1),isEdit.value?(openBlock(),createElementBlock(`div`,_hoisted_12$7,[createBaseVNode(`div`,_hoisted_13$7,[createVNode(unref(bngInput_default),{modelValue:scaleX.value,"onUpdate:modelValue":_cache[4]||=$event=>scaleX.value=$event,type:`number`,prefix:`X`,step:.01,min:INPUT_MIN,max:15},null,8,[`modelValue`]),createVNode(unref(bngSlider_default),{modelValue:scaleX.value,"onUpdate:modelValue":_cache[5]||=$event=>scaleX.value=$event,step:.01,min:INPUT_MIN,max:15},null,8,[`modelValue`])]),createBaseVNode(`div`,_hoisted_14$7,[createVNode(unref(bngInput_default),{modelValue:scaleY.value,"onUpdate:modelValue":_cache[6]||=$event=>scaleY.value=$event,type:`number`,step:.01,min:INPUT_MIN,max:15,prefix:`Y`},null,8,[`modelValue`]),createVNode(unref(bngSlider_default),{modelValue:scaleY.value,"onUpdate:modelValue":_cache[7]||=$event=>scaleY.value=$event,step:.01,min:INPUT_MIN,max:15},null,8,[`modelValue`])])])):(openBlock(),createElementBlock(`div`,_hoisted_15$7,[createVNode(unref(bngPropVal_default),{keyLabel:`X`,valueLabel:scaleX.value},null,8,[`valueLabel`]),createVNode(unref(bngPropVal_default),{keyLabel:`Y`,valueLabel:scaleY.value},null,8,[`valueLabel`])]))])),isRepositionActive.value?createCommentVNode(``,!0):(openBlock(),createBlock(unref(bngDivider_default),{key:2})),isRepositionActive.value?createCommentVNode(``,!0):(openBlock(),createElementBlock(`div`,_hoisted_16$7,[_cache[19]||=createBaseVNode(`div`,{class:`setting-item-name`},`Rotate`,-1),isEdit.value?(openBlock(),createElementBlock(`div`,_hoisted_17$6,[createBaseVNode(`div`,_hoisted_18$5,[createVNode(unref(bngInput_default),{modelValue:rotation.value,"onUpdate:modelValue":_cache[8]||=$event=>rotation.value=$event,type:`number`,step:.1,min:INPUT_MIN,max:359.9,suffix:`deg`},null,8,[`modelValue`]),createVNode(unref(bngSlider_default),{modelValue:rotation.value,"onUpdate:modelValue":_cache[9]||=$event=>rotation.value=$event,step:.1,min:INPUT_MIN,max:359.9},null,8,[`modelValue`])])])):(openBlock(),createElementBlock(`div`,_hoisted_19$3,[createVNode(unref(bngPropVal_default),{keyLabel:`deg`,valueLabel:rotation.value},null,8,[`valueLabel`])]))])),isRepositionActive.value?createCommentVNode(``,!0):(openBlock(),createBlock(unref(bngDivider_default),{key:4})),isRepositionActive.value?createCommentVNode(``,!0):(openBlock(),createElementBlock(`div`,_hoisted_20$3,[_cache[20]||=createBaseVNode(`div`,{class:`setting-item-name`},`Skew`,-1),isEdit.value?(openBlock(),createElementBlock(`div`,_hoisted_21$3,[createBaseVNode(`div`,_hoisted_22$3,[createVNode(unref(bngInput_default),{modelValue:skewX.value,"onUpdate:modelValue":_cache[10]||=$event=>skewX.value=$event,type:`number`,step:.01,min:INPUT_MIN,max:INPUT_MAX,prefix:`X`},null,8,[`modelValue`]),createVNode(unref(bngSlider_default),{modelValue:skewX.value,"onUpdate:modelValue":_cache[11]||=$event=>skewX.value=$event,step:.01,min:INPUT_MIN,max:INPUT_MAX},null,8,[`modelValue`])]),createBaseVNode(`div`,_hoisted_23$3,[createVNode(unref(bngInput_default),{modelValue:skewY.value,"onUpdate:modelValue":_cache[12]||=$event=>skewY.value=$event,type:`number`,step:.01,min:INPUT_MIN,max:INPUT_MAX,prefix:`Y`},null,8,[`modelValue`]),createVNode(unref(bngSlider_default),{modelValue:skewY.value,"onUpdate:modelValue":_cache[13]||=$event=>skewY.value=$event,step:.01,min:INPUT_MIN,max:INPUT_MAX},null,8,[`modelValue`])])])):(openBlock(),createElementBlock(`div`,_hoisted_24$2,[createVNode(unref(bngPropVal_default),{keyLabel:`X`,valueLabel:skewX.value},null,8,[`valueLabel`]),createVNode(unref(bngPropVal_default),{keyLabel:`Y`,valueLabel:skewY.value},null,8,[`valueLabel`])]))])),!isRepositionActive.value||!isUseMouse.value?withDirectives((openBlock(),createBlock(unref(bngButton_default),{key:6,accent:`text`,class:`inspector-edit-button`,onClick:_cache[14]||=$event=>isEdit.value=!isEdit.value},{default:withCtx(()=>[createVNode(unref(bngBinding_default),{uiEvent:`context`}),createBaseVNode(`span`,_hoisted_25$1,` Toggle `+toDisplayString(isEdit.value?`Simple`:`Advance`),1)]),_:1})),[[unref(BngOnUiNav_default),()=>isEdit.value=!isEdit.value,`ok`,{focusRequired:!0}]]):createCommentVNode(``,!0)],2)]),_:1})),[[unref(BngBlur_default)]]),!isRepositionActive.value||!isUseMouse.value?withDirectives((openBlock(),createBlock(unref(bngButton_default),{key:0,class:`apply-button`,onClick:handleOk},{default:withCtx(()=>[createVNode(unref(bngBinding_default),{uiEvent:`ok`}),_cache[21]||=createBaseVNode(`span`,null,`Apply`,-1)]),_:1})),[[unref(BngOnUiNav_default),handleOk,`ok`,{focusRequired:!0}]]):createCommentVNode(``,!0)])])])),[[unref(BngOnUiNav_default),handleOk,`ok`],[unref(BngOnUiNav_default),goBack,`back`],[unref(BngOnUiNav_default),saveChanges,`menu`],[unref(BngOnUiNav_default),handleTranslateScalar,`focus_lr`],[unref(BngOnUiNav_default),handleTranslateScalar,`focus_ud`],[unref(BngOnUiNav_default),handleFocusLinear,`focus_l`,{up:!0}],[unref(BngOnUiNav_default),handleFocusLinear,`focus_l`,{down:!0}],[unref(BngOnUiNav_default),handleFocusLinear,`focus_r`,{up:!0}],[unref(BngOnUiNav_default),handleFocusLinear,`focus_r`,{down:!0}],[unref(BngOnUiNav_default),handleFocusLinear,`focus_u`,{up:!0}],[unref(BngOnUiNav_default),handleFocusLinear,`focus_u`,{down:!0}],[unref(BngOnUiNav_default),handleFocusLinear,`focus_d`,{up:!0}],[unref(BngOnUiNav_default),handleFocusLinear,`focus_d`,{down:!0}],[unref(BngOnUiNav_default),handleFocusLinear,`focus_l`,{up:!0,modified:!0}],[unref(BngOnUiNav_default),handleFocusLinear,`focus_l`,{down:!0,modified:!0}],[unref(BngOnUiNav_default),handleFocusLinear,`focus_r`,{up:!0,modified:!0}],[unref(BngOnUiNav_default),handleFocusLinear,`focus_r`,{down:!0,modified:!0}],[unref(BngOnUiNav_default),handleFocusLinear,`focus_u`,{up:!0,modified:!0}],[unref(BngOnUiNav_default),handleFocusLinear,`focus_u`,{down:!0,modified:!0}],[unref(BngOnUiNav_default),handleFocusLinear,`focus_d`,{up:!0,modified:!0}],[unref(BngOnUiNav_default),handleFocusLinear,`focus_d`,{down:!0,modified:!0}],[unref(BngOnUiNav_default),handleRotateCam,`rotate_h_cam`],[unref(BngOnUiNav_default),handleRotateCam,`rotate_v_cam`],[unref(BngOnUiNav_default),handleRotateCam,`rotate_h_cam`,{modified:!0}],[unref(BngOnUiNav_default),handleRotateCam,`rotate_v_cam`,{modified:!0}],[unref(BngOnUiNav_default),handlePrecise,`action_2`,{up:!0}],[unref(BngOnUiNav_default),handlePrecise,`action_2`,{down:!0}],[unref(BngOnUiNav_default),handlePrecise,`action_2`,{up:!0,modified:!0}],[unref(BngOnUiNav_default),handlePrecise,`action_2`,{down:!0,modified:!0}],[unref(BngOnUiNav_default),handleModifier,`tab_l`,{up:!0}],[unref(BngOnUiNav_default),handleModifier,`tab_l`,{down:!0}],[unref(BngOnUiNav_default),handleTabRight,`tab_r`,{up:!0}],[unref(BngOnUiNav_default),handleTabRight,`tab_r`,{down:!0}],[unref(BngOnUiNav_default),handleAction3,`action_3`],[unref(BngOnUiNav_default),toggleEdit,`context`],[unref(BngUiNavLabel_default),hintLabels.value.focus_lr,`focus_lr`],[unref(BngUiNavLabel_default),hintLabels.value.focus_ud,`focus_ud`],[unref(BngUiNavLabel_default),hintLabels.value.focus_l,`focus_l`],[unref(BngUiNavLabel_default),hintLabels.value.focus_r,`focus_r`],[unref(BngUiNavLabel_default),hintLabels.value.focus_u,`focus_u`],[unref(BngUiNavLabel_default),hintLabels.value.focus_d,`focus_d`],[unref(BngUiNavLabel_default),hintLabels.value.rotate_h_cam,`rotate_h_cam`],[unref(BngUiNavLabel_default),hintLabels.value.rotate_v_cam,`rotate_v_cam`],[unref(BngUiNavLabel_default),hintLabels.value.action_2,`action_2`],[unref(BngUiNavLabel_default),hintLabels.value.action_3,`action_3`],[unref(BngUiNavLabel_default),hintLabels.value.tab_r,`tab_r`],[unref(BngUiNavLabel_default),hintLabels.value.tab_l,`tab_l`],[unref(BngUiNavLabel_default),hintLabels.value.ok,`ok`],[unref(BngUiNavLabel_default),hintLabels.value.back,`back`]])}},LayerTransform_default=__plugin_vue_export_helper_default(_sfc_main$78,[[`__scopeId`,`data-v-a4399a23`]]),_hoisted_1$69={class:`layer-materials-view`,"bng-ui-scope":`layer-materials-scope`},_hoisted_2$57={class:`header`},_hoisted_3$49={class:`main-view-content`},_hoisted_4$37={class:`inspector-container`},_hoisted_5$32={class:`materials-inspector`},_hoisted_6$24={class:`materials-setting-item`},_hoisted_7$22={class:`color-values-container`,"bng-no-child-nav":``},_hoisted_8$17={class:`materials-setting-item`},_hoisted_9$15={class:`slider-text-container`},_hoisted_10$11={class:`materials-setting-item`},_hoisted_11$9={class:`slider-text-container`},BLOCKED_UI_EVENTS=[`tab_l`,`tab_r`,`action_2`,`rotate_h_cam`,`rotate_v_cam`,`focus_lr`,`focus_ud`],_sfc_main$77={__name:`LayerMaterials`,setup(__props){let headerStore=useEditorHeaderStore(),infobar=useInfoBar(),uiNavBlocker=useUINavBlocker();useUINavScope(`layer-materials-scope`);let{events:events$3}=useBridge(),screenState=reactive({openedDialog:null}),color=ref({hue:.5,saturation:1,luminosity:.5}),inputHue=computed({get:()=>color.value.hue.toFixed(3),set:newValue=>{color.value.hue=typeof newValue==`string`?+newValue:newValue,onColorChanged()}}),inputSat=computed({get:()=>color.value.saturation.toFixed(3),set:newValue=>{color.value.saturation=typeof newValue==`string`?+newValue:newValue,onColorChanged()}}),inputLum=computed({get:()=>color.value.luminosity.toFixed(3),set:newValue=>{color.value.luminosity=typeof newValue==`string`?+newValue:newValue,onColorChanged()}}),metallicIntensity=ref(0),roughnessIntensity=ref(0),stateData=ref(),colorInitialized=ref(!1),isPreciseActive=ref(!1),colorPickerStep=computed(()=>isPreciseActive.value?.001:.01),slidersStep=computed(()=>isPreciseActive.value?.1:1),updateMaterialProperties=properties=>Lua_default.extensions.ui_liveryEditor_layerEdit.setLayerMaterials(properties);function onColorChanged(){if(!colorInitialized.value)return;let paint=new Paint;paint.hsl=[color.value.hue,color.value.saturation,color.value.luminosity],updateMaterialProperties({color:paint.rgba})}watch(()=>metallicIntensity.value,value=>updateMaterialProperties({metallicIntensity:value})),watch(()=>roughnessIntensity.value,value=>updateMaterialProperties({roughnessIntensity:value})),onBeforeMount(()=>{headerStore.setPreheader([`Materials`])}),onMounted(async()=>{infobar.visible=!0,infobar.showSysInfo=!0,uiNavBlocker.blockOnly(BLOCKED_UI_EVENTS),events$3.on(`liveryEditor_layerEdit_state`,onStateData),events$3.on(`liveryEditor_layerEdit_layerMaterialsData`,onMaterialPropertiesData),await Lua_default.extensions.ui_liveryEditor_layerEdit.requestStateData(),await Lua_default.extensions.ui_liveryEditor_layerEdit.requestLayerMaterials()}),onBeforeUnmount(async()=>{events$3.off(`liveryEditor_layerEdit_layerMaterialsData`,onMaterialPropertiesData),events$3.off(`liveryEditor_layerEdit_state`,onStateData),uiNavBlocker.clear()});async function onStateData(data){stateData.value=data}function onMaterialPropertiesData(data){colorInitialized.value=!1;let paint=new Paint;data.color[3]=1;let isWhite=data.color.every(num=>num===1);paint.rgba=data.color,color.value.hue=paint.hue,color.value.saturation=isWhite?.5:paint.saturation,color.value.luminosity=paint.luminosity,colorInitialized.value=!0,metallicIntensity.value=data.metallicIntensity,roughnessIntensity.value=data.roughnessIntensity}function handleAction2(element){isPreciseActive.value=element.detail.value===1}function goBack(event){screenState.openedDialog||(screenState.openedDialog=`exit`,openConfirmation(`Exit`,`Exit and lose changes?`).then(res=>{res&&Lua_default.extensions.ui_liveryEditor_layerEdit.cancelChanges().then(()=>{window.bngVue.gotoGameState(`LiveryDecals`)}),screenState.openedDialog=null}),event.stopPropagation())}function saveChanges(){Lua_default.extensions.ui_liveryEditor_layerEdit.saveChanges().then(()=>{window.bngVue.gotoGameState(`LiveryDecals`)})}return(_ctx,_cache)=>withDirectives((openBlock(),createElementBlock(`div`,_hoisted_1$69,[createBaseVNode(`div`,_hoisted_2$57,[createVNode(unref(LiveryEditorHeader_default))]),createBaseVNode(`div`,_hoisted_3$49,[createBaseVNode(`div`,_hoisted_4$37,[withDirectives((openBlock(),createBlock(LayerInspectorBase_default,{heading:`Materials`,class:``},{default:withCtx(()=>[createBaseVNode(`div`,_hoisted_5$32,[createBaseVNode(`div`,_hoisted_6$24,[_cache[8]||=createBaseVNode(`div`,{class:`setting-item-name`},`Color`,-1),withDirectives(createVNode(unref(bngColorPicker_default),{modelValue:color.value,"onUpdate:modelValue":_cache[0]||=$event=>color.value=$event,step:colorPickerStep.value,onChange:onColorChanged},null,8,[`modelValue`,`step`]),[[unref(BngUiNavFocus_default),0]]),createBaseVNode(`div`,_hoisted_7$22,[createVNode(unref(bngInput_default),{prefix:`h`,modelValue:inputHue.value,"onUpdate:modelValue":_cache[1]||=$event=>inputHue.value=$event,type:`number`},null,8,[`modelValue`]),createVNode(unref(bngInput_default),{prefix:`s`,modelValue:inputSat.value,"onUpdate:modelValue":_cache[2]||=$event=>inputSat.value=$event,type:`number`},null,8,[`modelValue`]),createVNode(unref(bngInput_default),{prefix:`b`,modelValue:inputLum.value,"onUpdate:modelValue":_cache[3]||=$event=>inputLum.value=$event,type:`number`},null,8,[`modelValue`])])]),createVNode(unref(bngDivider_default)),createBaseVNode(`div`,_hoisted_8$17,[_cache[9]||=createBaseVNode(`div`,{class:`setting-item-name`},`Metallic Intensity`,-1),createBaseVNode(`div`,_hoisted_9$15,[createVNode(unref(bngInput_default),{"bng-no-nav":``,modelValue:metallicIntensity.value,"onUpdate:modelValue":_cache[4]||=$event=>metallicIntensity.value=$event,type:`number`,min:0,max:100,step:slidersStep.value},null,8,[`modelValue`,`step`]),createVNode(unref(bngSlider_default),{modelValue:metallicIntensity.value,"onUpdate:modelValue":_cache[5]||=$event=>metallicIntensity.value=$event,min:0,max:100,step:slidersStep.value},null,8,[`modelValue`,`step`])])]),createVNode(unref(bngDivider_default)),createBaseVNode(`div`,_hoisted_10$11,[_cache[10]||=createBaseVNode(`div`,{class:`setting-item-name`},`Roughness Intensity`,-1),createBaseVNode(`div`,_hoisted_11$9,[createVNode(unref(bngInput_default),{"bng-no-nav":``,modelValue:roughnessIntensity.value,"onUpdate:modelValue":_cache[6]||=$event=>roughnessIntensity.value=$event,type:`number`,min:0,max:100,step:slidersStep.value},null,8,[`modelValue`,`step`]),createVNode(unref(bngSlider_default),{modelValue:roughnessIntensity.value,"onUpdate:modelValue":_cache[7]||=$event=>roughnessIntensity.value=$event,min:0,max:100,step:slidersStep.value},null,8,[`modelValue`,`step`])])])])]),_:1})),[[unref(BngBlur_default)]])])])])),[[unref(BngUiNavLabel_default),`Apply`,`context`],[unref(BngUiNavLabel_default),`[Hold]Precise`,`action_2`],[unref(BngUiNavLabel_default),`Back`,`back,menu`],[unref(BngOnUiNav_default),handleAction2,`action_2`,{up:!0}],[unref(BngOnUiNav_default),handleAction2,`action_2`,{down:!0}],[unref(BngOnUiNav_default),goBack,`back,menu`],[unref(BngOnUiNav_default),saveChanges,`context`]])}},LayerMaterials_default=__plugin_vue_export_helper_default(_sfc_main$77,[[`__scopeId`,`data-v-4b3730e9`]]),_hoisted_1$68={class:`layer-projection-view`,"bng-ui-scope":`layer-projection-scope`},_hoisted_2$56={class:`header`},_hoisted_3$48={class:`main-view-content`},_hoisted_4$36={class:`camera-views-container`},_hoisted_5$31={class:`mirror-settings-container`},CAMERA_BUTTONS=[{label:`Right`,icon:icons.cameraSideRight,value:`right`},{label:`Front`,icon:icons.cameraFront1,value:`front`},{label:`Left`,icon:icons.cameraSideLeft,value:`left`},{label:`Back`,icon:icons.cameraBack1,value:`back`},{label:`Top Right`,icon:icons.cameraTop1,value:`topright`},{label:`Top Left`,icon:icons.cameraTop1,value:`topleft`},{label:`Top Front`,icon:icons.cameraTop1,value:`topfront`},{label:`Top Back`,icon:icons.cameraTop1,value:`topback`}],_sfc_main$76={__name:`LayerProjection`,setup(__props){let{events:events$3}=useBridge(),headerStore=useEditorHeaderStore(),store$1=useLiveryEditorStore(),infobar=useInfoBar(),popover=usePopover(),uiNav=useUINavScope(`layer-projection-scope`),stateData=ref(null),mirrorState=reactive({mirrored:!1,mirrorFipped:!1,mirrorOffset:0}),mirrored=computed({get:()=>mirrorState.mirrored,set:async newValue=>{mirrorState.mirrored=newValue,await Lua_default.extensions.ui_liveryEditor_layerEdit.setMirrored(newValue,mirrorState.mirrorFipped,mirrorState.mirrorOffset)}}),mirrorFipped=computed({get:()=>mirrorState.mirrorFipped,set:async newValue=>{mirrorState.mirrorFipped=newValue,await Lua_default.extensions.ui_liveryEditor_layerEdit.setMirrored(mirrorState.mirrored,newValue,mirrorState.mirrorOffset)}}),mirrorOffset=computed({get:()=>mirrorState.mirrorOffset,set:async newValue=>{mirrorState.mirrorOffset=newValue,await Lua_default.extensions.ui_liveryEditor_layerEdit.setMirrored(mirrorState.mirrored,mirrorState.mirrorFipped,newValue)}}),NAV_HINTS=[{id:`apply`,content:{type:`binding`,props:{uiEvent:`menu`},label:`Done`},action:saveChanges},{id:`back`,content:{type:`binding`,props:{uiEvent:`back`},label:`Back`},action:goBack}];onBeforeMount(()=>{infobar.clearHints(),infobar.addHints(NAV_HINTS),headerStore.setPreheader([`Projection`]),headerStore.setHeader(`Decals`)}),onMounted(async()=>{infobar.visible=!0,infobar.showSysInfo=!0,events$3.on(`liveryEditor_layerEdit_state`,onStateData),events$3.on(`liveryEditor_layerEdit_initialLayerData`,onInitialLayerData),await Lua_default.extensions.ui_liveryEditor_layerEdit.requestStateData(),await Lua_default.extensions.ui_liveryEditor_layerEdit.requestInitialLayerData()}),onBeforeUnmount(()=>{events$3.off(`liveryEditor_layerEdit_state`,onStateData),events$3.off(`liveryEditor_layerEdit_initialLayerData`,onInitialLayerData)});function changeCameraView(view){popover.hide(`camera-views-menu`),console.log(`changeCameraView`,view),store$1.setOrthographicView(view)}function onStateData(data){console.log(`onStateData`,data),stateData.value=data}function onInitialLayerData(data){mirrorState.mirrored=data.mirrored,mirrorState.mirrorFipped=data.mirrorFipped,mirrorState.mirrorOffset=data.mirrorOffset}function goBack(){window.bngVue.gotoGameState(`LiveryLayerEdit`)}function saveChanges(){window.bngVue.gotoGameState(`LiveryLayerEdit`)}function onPopoverMenuHide(){uiNav.set(`layer-projection-scope`)}return(_ctx,_cache)=>withDirectives((openBlock(),createElementBlock(`div`,_hoisted_1$68,[createBaseVNode(`div`,_hoisted_2$56,[createVNode(unref(LiveryEditorHeader_default))]),createBaseVNode(`div`,_hoisted_3$48,[withDirectives(createVNode(unref(bngImageTile_default),{"bng-nav-item":``,icon:unref(icons).movieCamera,label:`Side`},null,8,[`icon`]),[[unref(BngBlur_default)],[unref(BngPopover_default),`camera-views-menu`,`right-start`,{click:!0}]]),withDirectives(createVNode(unref(bngImageTile_default),{"bng-nav-item":``,icon:unref(icons).reflect,label:`Mirror`},null,8,[`icon`]),[[unref(BngBlur_default)],[unref(BngPopover_default),`mirror-settings-menu`,`right-start`,{click:!0}]])]),createVNode(unref(bngPopoverMenu_default),{name:`camera-views-menu`,onHide:onPopoverMenuHide},{default:withCtx(()=>[createBaseVNode(`div`,_hoisted_4$36,[createVNode(unref(bngList_default),{targetWidth:8,targetMargin:.5,noBackground:``},{default:withCtx(()=>[(openBlock(),createElementBlock(Fragment,null,renderList(CAMERA_BUTTONS,view=>createVNode(unref(bngImageTile_default),{key:view.value,"bng-nav-item":``,label:view.label,icon:view.icon,onClick:$event=>changeCameraView(view.value)},null,8,[`label`,`icon`,`onClick`])),64))]),_:1})])]),_:1}),createVNode(unref(bngPopoverMenu_default),{name:`mirror-settings-menu`,onHide:onPopoverMenuHide},{default:withCtx(()=>[createBaseVNode(`div`,_hoisted_5$31,[createVNode(unref(bngPillCheckbox_default),{modelValue:mirrored.value,"onUpdate:modelValue":_cache[0]||=$event=>mirrored.value=$event},{default:withCtx(()=>[..._cache[3]||=[createTextVNode(`Mirrored`,-1)]]),_:1},8,[`modelValue`]),withDirectives((openBlock(),createBlock(unref(bngPillCheckbox_default),{modelValue:mirrorFipped.value,"onUpdate:modelValue":_cache[1]||=$event=>mirrorFipped.value=$event},{default:withCtx(()=>[..._cache[4]||=[createTextVNode(`Mirror Flipped`,-1)]]),_:1},8,[`modelValue`])),[[unref(BngDisabled_default),!mirrored.value]]),createVNode(unref(bngInput_default),{modelValue:mirrorOffset.value,"onUpdate:modelValue":_cache[2]||=$event=>mirrorOffset.value=$event,externalLabel:`Offset`,type:`number`,disabled:!mirrored.value},null,8,[`modelValue`,`disabled`])])]),_:1})])),[[unref(BngOnUiNav_default),goBack,`back`],[unref(BngOnUiNav_default),goBack,`menu`]])}},LayerProjection_default=__plugin_vue_export_helper_default(_sfc_main$76,[[`__scopeId`,`data-v-19e531c7`]]),_hoisted_1$67={class:`settings-main-view`,"bng-ui-scope":`settings-main-scope`},_hoisted_2$55={class:`header`},_hoisted_3$47={class:`main-view-content`},_hoisted_4$35={class:`settings-container`},_hoisted_5$30={class:`settings-item`},_sfc_main$75={__name:`LiverySettingsMain`,setup(__props){let headerStore=useEditorHeaderStore(),infobar=useInfoBar();useUINavScope(`settings-main-scope`);let{events:events$3}=useBridge(),stateData=ref(null),useSurfaceNormal=ref(!1);watch(()=>useSurfaceNormal.value,async value=>{await Lua_default.extensions.ui_liveryEditor.useSurfaceNormal(value)});let NAV_HINTS=[{id:`back`,content:{type:`binding`,props:{uiEvent:`back`},label:`Back`},action:goBack}];onBeforeMount(()=>{infobar.clearHints(),infobar.addHints(NAV_HINTS),headerStore.setHeader(`Decals`),headerStore.setPreheader([`Settings`])}),onMounted(async()=>{infobar.visible=!0,infobar.showSysInfo=!0,events$3.on(`liveryEditor_settingsData`,onSettingsData),await Lua_default.extensions.ui_liveryEditor.requestSettingsData()}),onBeforeUnmount(()=>{events$3.off(`liveryEditor_settingsData`,onSettingsData)});function onSettingsData(data){console.log(`onSettingsData`,data),stateData.value=data,useSurfaceNormal.value=data.useSurfaceNormal}function goBack(event){window.bngVue.gotoGameState(`LiveryMain`),event.stopPropagation()}return(_ctx,_cache)=>withDirectives((openBlock(),createElementBlock(`div`,_hoisted_1$67,[createBaseVNode(`div`,_hoisted_2$55,[createVNode(unref(LiveryEditorHeader_default))]),createBaseVNode(`div`,_hoisted_3$47,[withDirectives((openBlock(),createBlock(unref(bngCard_default),null,{default:withCtx(()=>[createVNode(unref(bngCardHeading_default),null,{default:withCtx(()=>[..._cache[1]||=[createTextVNode(`Settings`,-1)]]),_:1}),createBaseVNode(`div`,_hoisted_4$35,[createBaseVNode(`div`,_hoisted_5$30,[_cache[2]||=createBaseVNode(`div`,{class:`settings-item-name`},`Use Surface Normal`,-1),withDirectives(createVNode(unref(bngSwitch_default),{modelValue:useSurfaceNormal.value,"onUpdate:modelValue":_cache[0]||=$event=>useSurfaceNormal.value=$event,label:useSurfaceNormal.value?`Yes`:`No`},null,8,[`modelValue`,`label`]),[[unref(BngUiNavFocus_default),0],[unref(BngFocusIf_default),!0]])])])]),_:1})),[[unref(BngBlur_default)]])])])),[[unref(BngOnUiNav_default),goBack,`back,menu`]])}},LiverySettingsMain_default=__plugin_vue_export_helper_default(_sfc_main$75,[[`__scopeId`,`data-v-ad4291e2`]]),routes_default$8=[{path:`/livery-editor`,name:`LiveryEditor`,component:LiveryEditor_default},{path:`/livery-main`,name:`LiveryMain`,component:LiveryMainNew_default},{path:`/livery-paint`,name:`LiveryPaint`,component:LiveryPaintMain_default},{path:`/livery-decals`,name:`LiveryDecals`,component:LiveryDecalsMain_default},{path:`/livery-settings`,name:`LiverySettings`,component:LiverySettingsMain_default},{path:`/livery-camera-settings`,name:`LiveryCameraSettings`,component:LiveryCameraSettings_default},{path:`/livery-decal-selector`,name:`LiveryDecalSelector`,component:LiveryDecalSelector_default},{path:`/livery-layer-edit`,name:`LiveryLayerEdit`,component:LiveryLayerEdit_default},{path:`/layer-transform`,name:`LayerTransform`,component:LayerTransform_default},{path:`/layer-materials`,name:`LayerMaterials`,component:LayerMaterials_default},{path:`/layer-projection`,name:`LayerProjection`,component:LayerProjection_default},{path:`/livery-manager`,name:`LiveryManager`,component:LiveryManager_default}],_hoisted_1$66={class:`logo-wrapper`},_sfc_main$74={__name:`Logo`,setup(__props){let logos={beamng:getAssetURL(`images/logos.svg#bng-beamng`),tech:getAssetURL(`images/logos.svg#bng-tech`),drive:getAssetURL(`images/logos.svg#bng-drive`),research:getAssetURL(`images/logos.svg#bng-research`)},productLogo=ref(logos.drive);return onMounted(async()=>{if(await Lua_default.extensions.tech_license.isValid())productLogo.value=logos.tech;else if(window.beamng){let name=window.beamng.product.replace(`BeamNG.`,``);name in logos&&(productLogo.value=logos[name])}else productLogo.value=logos.drive}),(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$66,[createBaseVNode(`div`,{class:`logo`,style:normalizeStyle({"--logo":`url('${productLogo.value}')`})},null,4)]))}},Logo_default=__plugin_vue_export_helper_default(_sfc_main$74,[[`__scopeId`,`data-v-69adfd8c`]]),_hoisted_1$65={class:`main-view`},_hoisted_2$54={class:`dev-info-content`},_hoisted_3$46={class:`dev-info-text`},_hoisted_4$34={class:`mainmenu-title`},_hoisted_5$29={key:1,class:`bottom-buttons`},_hoisted_6$23={class:`btn-content`},_hoisted_7$21={class:`label`},_hoisted_8$16={key:0,class:`small`},_hoisted_9$14={class:`btn-content`},_hoisted_10$10={class:`label`},_hoisted_11$8={key:0,class:`small`},_hoisted_12$6={class:`btn-content`},_hoisted_13$6={class:`label`},_hoisted_14$6={class:`btn-content`},_hoisted_15$6={class:`label`},_hoisted_16$6={class:`btn-content`},_hoisted_17$5={class:`label`},_sfc_main$73={__name:`MainMenu`,setup(__props){let events$3=useEvents(),infoBar=useInfoBar();useUINavScope(`mainmenuUI`);let withAngular=computed(()=>!sysInfo_default.mainMenuBackgroundRequired.value),firstTime=ref(sysInfo_default.mainMenuFirstTime.value),bgRequired=sysInfo_default.mainMenuBackgroundRequired,parentImageCarousel=inject(`mainBackground`),modCounts$1=sysInfo_default.modCounts,devEnv=reactive({env:window.beamng&&!window.beamng.shipping,vue:!1,simplemenu:window.beamng&&window.beamng.simplemenu,videoApi:null,UIEngine:null}),quickLoadLevel=()=>Lua_default.core_levels.startLevel(`/levels/smallgrid/main.level.json`),addons=ref({}),addButton=({translateid,icon,targetState,title,iconId,action})=>{let newButton;newButton=translateid||icon||targetState?{title:$translate.instant(translateid),icon,action:targetState}:{title,iconId,action},addons.value[newButton.title]=newButton},viewName=ref(),changeView=name=>{viewName.value=name,router_default.push(`/menu.mainmenu`+(name?`/`+name:``))};watch(()=>viewName.value,val=>{val&&infoBar.flashHints(`back`),parentImageCarousel.value&&nextTick(parentImageCarousel.value.carousel.showNext)});let route=useRoute();watch(()=>route.name,name=>{if(typeof name!=`string`){viewName.value=null;return}name.startsWith(`menu.mainmenu`)&&(viewName.value=name===`menu.mainmenu`?null:name.slice(14))},{immediate:!0});let navigate$1=(...state)=>window.bngVue.gotoGameState(...state);function quitGame(){Lua_default.quit(),runRaw(`TorqueScript.eval('quit();')`,!1)}let handleBack=event=>{event.detail.force||(viewName.value?(viewName.value=null,changeView(null)):(event.detail.name===`back`||event.detail.name===`menu`)&&window.globalAngularRootScope?.$broadcast(`MenuToggle`))},canDeactivateScope=()=>!viewName.value,canBubbleEvent=event=>{if(event.detail.value!==1)return!1;let eventName=event.detail.name;return eventName===`tab_l`||eventName===`tab_r`?!viewName.value:!1};function displayToast(type,title,titleContext,msg,messageContext){let msgTxt=$translate.contextTranslate({txt:msg,context:messageContext}),titleTxt=$translate.contextTranslate({txt:title,context:titleContext}),msgHtml=window.angularParseBBCode(msgTxt),titleHtml=window.angularParseBBCode(titleTxt);window.globalAngularRootScope.$broadcast(`toastrMsg`,{type,msg:msgHtml,title:titleHtml,config:{positionClass:`toast-top-right`,timeOut:0,extendedTimeOut:0,onTap(){window.bngVue.gotoGameState(`menu.options.performance`)}}})}async function checkHardware(){Lua_default.checkFSErrors();let info=await Lua_default.core_hardwareinfo.getInfo();if(info.globalState!==`ok`){for(let key in info)if(!(!info[key].warnings||!Array.isArray(info[key].warnings)))for(let warning of info[key].warnings)warning.ack||displayToast(info.globalState===`warn`?`warning`:`error`,`ui.performance.warnings.`+warning.msg,warning.context,`ui.mainmenu.warningdetails`,null)}}let repoEnabled=ref(!1),modsAfterUpdate=ref(!1),onSettingsChanged=data=>{modsAfterUpdate.value=data.values.disableModsAfterUpdate,repoEnabled.value=data.values.onlineFeatures===`enable`&&!data.values.disableModsAfterUpdate};return onMounted(async()=>{function advertMainMenu(){events$3.emit(`MainMenuButtons`,addButton),window.globalAngularRootScope.$broadcast(`MainMenuButtons`,addButton)}advertMainMenu(),events$3.on(`UiModsChanged`,advertMainMenu),events$3.on(`BroadcastMainMenuButtons`,advertMainMenu),events$3.on(`SettingsChanged`,onSettingsChanged),Lua_default.settings.notifyUI(),devEnv.env&&(devEnv.videoApi=await Lua_default.Engine.Render.getAdapterType(),devEnv.UIEngine=await Lua_default.Engine.UI.getUIEngine()),sysInfo_default.mainMenuFirstTime.value&&checkHardware();let settings$1=await useSettingsAsync();await Lua_default.extensions.tech_license.isValid()||(settings$1.values.onlineFeatures===`ask`||settings$1.values.telemetry===`ask`?window.bngVue.gotoGameState(`menu.onlineFeatures`):Lua_default.settings.getValue(`showedInputLayoutPopupV37`).then(value=>{value===!1&&window.bngVue.gotoGameState(`buttonLayout`)})),sysInfo_default.mainMenuFirstTime.value=!1}),onUnmounted(()=>{events$3.off(`SettingsChanged`,onSettingsChanged)}),(_ctx,_cache)=>{let _component_router_view=resolveComponent(`router-view`);return withDirectives((openBlock(),createElementBlock(`div`,{class:normalizeClass({"mainmenu-container":!0,"mainmenu-with-angular":withAngular.value,"mainmenu-fadein":firstTime.value&&!withAngular.value}),onDeactivate:handleBack},[withDirectives((openBlock(),createElementBlock(`div`,_hoisted_1$65,[devEnv.env?(openBlock(),createBlock(unref(bngCard_default),{key:0,class:`dev-info`},{default:withCtx(()=>[createVNode(unref(bngCardHeading_default),{type:`ribbon`},{default:withCtx(()=>[..._cache[5]||=[createTextVNode(`Developer Release`,-1)]]),_:1}),createBaseVNode(`div`,_hoisted_2$54,[withDirectives(createVNode(unref(bngIcon_default),{class:`dev-info-icon`,type:unref(icons).bug,"bng-all-clicks-no-nav":``},null,8,[`type`]),[[unref(BngDoubleClick_default),quickLoadLevel]]),createBaseVNode(`div`,_hoisted_3$46,[createBaseVNode(`div`,null,` Graphics API: `+toDisplayString(devEnv.videoApi||`requesting...`),1),createBaseVNode(`div`,null,` UI Engine: `+toDisplayString(devEnv.UIEngine||`requesting...`),1)])])]),_:1})):createCommentVNode(``,!0),createBaseVNode(`div`,_hoisted_4$34,[createVNode(Logo_default)]),createVNode(_component_router_view,{"first-time":firstTime.value&&!withAngular.value,addons:addons.value,onChangeView:changeView},null,8,[`first-time`,`addons`]),viewName.value?createCommentVNode(``,!0):(openBlock(),createElementBlock(`div`,_hoisted_5$29,[repoEnabled.value?withDirectives((openBlock(),createBlock(unref(bngButton_default),{key:0,class:`btn-mods`,accent:unref(ACCENTS).text,onClick:_cache[0]||=$event=>navigate$1(`menu.mods.repository`)},{default:withCtx(()=>[unref(bgRequired)?(openBlock(),createBlock(BlurBackground_default,{key:0})):createCommentVNode(``,!0),createBaseVNode(`div`,_hoisted_6$23,[createBaseVNode(`span`,_hoisted_7$21,toDisplayString(_ctx.$tt(`ui.mainmenu.repo`)),1),unref(modCounts$1).total>0?(openBlock(),createElementBlock(`span`,_hoisted_8$16,`\xA0(`+toDisplayString(unref(modCounts$1).active)+` / `+toDisplayString(unref(modCounts$1).total)+`)`,1)):createCommentVNode(``,!0)])]),_:1},8,[`accent`])),[[unref(BngBlur_default),!unref(bgRequired)],[unref(BngSoundClass_default),`bng_click_hover_generic`]]):withDirectives((openBlock(),createBlock(unref(bngButton_default),{key:1,class:normalizeClass([`btn-mods`,{"mods-after-update":modsAfterUpdate.value}]),accent:unref(ACCENTS).text,onClick:_cache[1]||=$event=>navigate$1(`menu.mods.local`)},{default:withCtx(()=>[unref(bgRequired)?(openBlock(),createBlock(BlurBackground_default,{key:0})):createCommentVNode(``,!0),createBaseVNode(`div`,_hoisted_9$14,[createBaseVNode(`span`,_hoisted_10$10,[modsAfterUpdate.value?(openBlock(),createBlock(unref(bngIcon_default),{key:0,type:`danger`,style:{"font-size":`1.1em`},color:`#ff2d00`})):createCommentVNode(``,!0),createTextVNode(toDisplayString(_ctx.$tt(`ui.mainmenu.mods`)),1)]),unref(modCounts$1).total>0?(openBlock(),createElementBlock(`span`,_hoisted_11$8,`\xA0(`+toDisplayString(unref(modCounts$1).active)+` / `+toDisplayString(unref(modCounts$1).total)+`)`,1)):createCommentVNode(``,!0)])]),_:1},8,[`class`,`accent`])),[[unref(BngBlur_default),!unref(bgRequired)],[unref(BngSoundClass_default),`bng_click_hover_generic`]]),withDirectives((openBlock(),createBlock(unref(bngButton_default),{accent:unref(ACCENTS).text,onClick:_cache[2]||=$event=>navigate$1(`credits`)},{default:withCtx(()=>[unref(bgRequired)?(openBlock(),createBlock(BlurBackground_default,{key:0})):createCommentVNode(``,!0),createBaseVNode(`div`,_hoisted_12$6,[createBaseVNode(`span`,_hoisted_13$6,toDisplayString(_ctx.$tt(`ui.mainmenu.credits`)),1)])]),_:1},8,[`accent`])),[[unref(BngBlur_default),!unref(bgRequired)],[unref(BngSoundClass_default),`bng_click_hover_generic`]]),withDirectives((openBlock(),createBlock(unref(bngButton_default),{accent:unref(ACCENTS).text,onClick:_cache[3]||=$event=>navigate$1(`menu.options.display`)},{default:withCtx(()=>[unref(bgRequired)?(openBlock(),createBlock(BlurBackground_default,{key:0})):createCommentVNode(``,!0),createBaseVNode(`div`,_hoisted_14$6,[createBaseVNode(`span`,_hoisted_15$6,toDisplayString(_ctx.$tt(`ui.mainmenu.options`)),1)])]),_:1},8,[`accent`])),[[unref(BngBlur_default),!unref(bgRequired)],[unref(BngSoundClass_default),`bng_click_hover_generic`]]),devEnv.simplemenu?createCommentVNode(``,!0):withDirectives((openBlock(),createBlock(unref(bngButton_default),{key:2,class:`btn-quit`,accent:unref(ACCENTS).attention,icon:unref(icons).exit,onClick:_cache[4]||=$event=>quitGame()},{default:withCtx(()=>[unref(bgRequired)?(openBlock(),createBlock(BlurBackground_default,{key:0})):createCommentVNode(``,!0),createBaseVNode(`div`,_hoisted_16$6,[createBaseVNode(`span`,_hoisted_17$5,toDisplayString(_ctx.$tt(`ui.inputActions.general.quit.title`)),1)])]),_:1},8,[`accent`,`icon`])),[[unref(BngBlur_default),!unref(bgRequired)],[unref(BngSoundClass_default),`bng_click_hover_generic`]])]))])),[[unref(BngOnUiNav_default),handleBack,`back`]])],34)),[[unref(BngScopedNav_default),{activateOnMount:!0,canDeactivate:canDeactivateScope,canBubbleEvent}],[unref(BngOnUiNav_default),handleBack,`menu`]])}}},MainMenu_default=__plugin_vue_export_helper_default(_sfc_main$73,[[`__scopeId`,`data-v-1c7a0195`]]),_hoisted_1$64={key:1,class:`fancy-bg-wrap`},_hoisted_2$53={class:`mask-container`},_hoisted_3$45={key:0,class:`icon-text`},_hoisted_4$33={key:2,class:`tag`},_hoisted_5$28={key:3,class:`icon`},_hoisted_6$22={key:4,class:`icon`},_hoisted_7$20={key:5,class:`label-container`},_hoisted_8$15={class:`text`},_hoisted_9$13={key:6,class:`text`},_sfc_main$72={__name:`MenuButton`,props:{size:{type:String,default:`normal`},iconId:String,icon:String,highlighted:Boolean,disabled:Boolean,appearDisabled:Boolean,bgImg:String,bgImgAbs:String,tag:String,noBlur:Boolean},setup(__props,{expose:__expose}){let props=__props,btnRef=ref(null);__expose({getElement(){return btnRef.value}});let bgImgUrl=computed(()=>props.bgImgAbs?props.bgImgAbs:getAssetURL(props.bgImg)),hasBgImg=computed(()=>props.bgImgAbs||props.bgImg);return(_ctx,_cache)=>withDirectives((openBlock(),createElementBlock(`div`,{ref_key:`btnRef`,ref:btnRef,class:normalizeClass({"mainmenu-button":!0,[`size-${__props.size}`]:!0,"fancy-bg":!!hasBgImg.value,"with-icon":!!__props.iconId,"semi-disabled":__props.appearDisabled}),style:normalizeStyle({"--fancy-bg-img":`url('${bgImgUrl.value}')`}),"bng-nav-item":``},[__props.noBlur?createCommentVNode(``,!0):(openBlock(),createBlock(BlurBackground_default,{key:0,class:normalizeClass(`corners-${__props.size}`)},null,8,[`class`])),createBaseVNode(`div`,{class:normalizeClass([`button-background`,{stack:__props.size===`big-stacked`,highlighted:__props.highlighted}])},null,2),hasBgImg.value?(openBlock(),createElementBlock(`div`,_hoisted_1$64,[createBaseVNode(`div`,{class:normalizeClass([`bg-container`,{"with-icon":!!__props.iconId}])},[_cache[0]||=createBaseVNode(`div`,{class:`bg-image`},null,-1),createBaseVNode(`div`,_hoisted_2$53,[__props.iconId?(openBlock(),createElementBlock(`div`,_hoisted_3$45,toDisplayString(unref(icons)[__props.iconId].glyph),1)):createCommentVNode(``,!0)])],2)])):createCommentVNode(``,!0),__props.tag?(openBlock(),createElementBlock(`div`,_hoisted_4$33,toDisplayString(__props.tag),1)):createCommentVNode(``,!0),__props.iconId&&!hasBgImg.value?(openBlock(),createElementBlock(`div`,_hoisted_5$28,[createVNode(unref(bngIcon_default),{type:unref(icons)[__props.iconId],color:hasBgImg.value?`transparent`:void 0},null,8,[`type`,`color`])])):__props.icon?(openBlock(),createElementBlock(`div`,_hoisted_6$22,[createVNode(unref(bngImageAsset_default),{externalSrc:__props.icon},null,8,[`externalSrc`])])):createCommentVNode(``,!0),__props.size==`big`||__props.size==`big-stacked`?(openBlock(),createElementBlock(`div`,_hoisted_7$20,[createBaseVNode(`span`,_hoisted_8$15,[renderSlot(_ctx.$slots,`default`,{},void 0,!0)])])):(openBlock(),createElementBlock(`span`,_hoisted_9$13,[renderSlot(_ctx.$slots,`default`,{},void 0,!0)]))],6)),[[unref(BngSoundClass_default),!(__props.disabled||__props.appearDisabled)&&`bng_click_hover_generic`],[unref(BngDisabled_default),__props.disabled],[unref(BngBlur_default),!__props.noBlur]])}},MenuButton_default=__plugin_vue_export_helper_default(_sfc_main$72,[[`__scopeId`,`data-v-932e6a9a`]]),_hoisted_1$63={class:`center-wrap`},_hoisted_2$52={class:`primary`},IMG_PATH=`images/mainmenu/`,_sfc_main$71={__name:`MainView`,props:{firstTime:Boolean},emits:[`changeView`],setup(__props,{emit:__emit}){let props=__props,emit$1=__emit;ref(null);let settings$1=useSettings(),defaultWizardStep=computed(()=>settings$1.getValue(`freeroamSetupDefaultStep`)||`level`),firstTime=ref(props.firstTime);onMounted(()=>{firstTime.value&&setTimeout(()=>firstTime.value=!1,1500)});let navigate$1=(state,params=void 0)=>nextTick(()=>window.bngVue.gotoGameState(state,{params}));async function careerPrompt(){await openExperimental($translate.instant(`ui.career.experimentalTitle`),$translate.instant(`ui.career.experimentalPrompt`),[{label:$translate.instant(`ui.common.no`),value:!1,isCancel:!0,extras:{accent:ACCENTS.secondary}},{label:$translate.instant(`ui.career.experimentalAgree`),value:!0,default:!0}])&&navigate$1(`profiles`)}return(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$63,[createBaseVNode(`div`,_hoisted_2$52,[createVNode(MenuButton_default,{"bng-scoped-nav-autofocus":``,size:`big`,"icon-id":`keys1`,"bg-img":IMG_PATH+`experiences.jpg`,onClick:_cache[0]||=$event=>emit$1(`changeView`,`discover`),tag:_ctx.$t(`ui.playmodes.new`)},{default:withCtx(()=>[createTextVNode(toDisplayString(_ctx.$tt(`ui.playmodes.quickStartExperiences`)),1)]),_:1},8,[`bg-img`,`tag`]),createVNode(MenuButton_default,{size:`big`,"icon-id":`road`,"bg-img":IMG_PATH+`freeroam.jpg`,onClick:_cache[1]||=$event=>navigate$1(`menu.freeroamWizard`,{step:defaultWizardStep.value})},{default:withCtx(()=>[createTextVNode(toDisplayString(_ctx.$tt(`ui.playmodes.freeroam`)),1)]),_:1},8,[`bg-img`]),_ctx.$simplemenu.value?createCommentVNode(``,!0):(openBlock(),createBlock(MenuButton_default,{key:0,"appear-disabled":``,size:`big`,"icon-id":`cup`,"bg-img":IMG_PATH+`career.jpg`,onClick:_cache[2]||=$event=>careerPrompt(),tag:_ctx.$t(`ui.playmodes.comingSoon`),"tag-orange":``},{default:withCtx(()=>[createTextVNode(toDisplayString(_ctx.$tt(`ui.playmodes.career`)),1)]),_:1},8,[`bg-img`,`tag`])),createVNode(MenuButton_default,{size:`big-stacked`,"icon-id":`BNGFolder`,"bg-img":IMG_PATH+`others.jpg`,onClick:_cache[3]||=$event=>emit$1(`changeView`,`others`)},{default:withCtx(()=>[createTextVNode(toDisplayString(_ctx.$tt(`ui.mainmenu.more`)),1)]),_:1},8,[`bg-img`])])]))}},MainView_default=__plugin_vue_export_helper_default(_sfc_main$71,[[`__scopeId`,`data-v-0baa6516`]]),_hoisted_1$62={class:`center-wrap`},_hoisted_2$51={class:`others`},_hoisted_3$44={class:`buttons`},htmlBody=`
          `,overlayDiv.textContent=count$1.toString(),overlayElement.appendChild(overlayDiv),overlayDivs.set(element,overlayDiv)}catch{}}function updateOverlayText(){if(!overlayActive||overlayDivs.size===0)return;let appsStats=getUIAppsStats(),counts=appsStats.sortedList.map(item=>item.count),maxCount=Math.max(...counts,1),minCount=Math.min(...counts,0);for(let{element,count:count$1}of appsStats.sortedList){let overlayDiv=overlayDivs.get(element);overlayDiv&&(overlayDiv.textContent=count$1.toString(),overlayDiv.style.opacity=getOverlayOpacity(count$1,minCount,maxCount))}}function destroyOverlay(){overlayUpdateTimer&&=(clearInterval(overlayUpdateTimer),null),overlayDivs.forEach(overlayDiv=>overlayDiv.remove()),overlayDivs.clear(),overlayElement&&=(overlayElement.remove(),null),overlayActive=!1}function toggleOverlay(){return overlayActive?(destroyOverlay(),!1):(overlayActive=!0,createOverlay(),updateOverlayDivs(),overlayUpdateTimer=setInterval(updateOverlayText,500),!0)}function refreshOverlay(){overlayActive&&updateOverlayDivs()}var isBrowser=typeof document<`u`;function isRouteComponent(component){return typeof component==`object`||`displayName`in component||`props`in component||`__vccOpts`in component}function isESModule(obj){return obj.__esModule||obj[Symbol.toStringTag]===`Module`||obj.default&&isRouteComponent(obj.default)}var assign=Object.assign;function applyToParams(fn,params){let newParams={};for(let key in params){let value=params[key];newParams[key]=isArray(value)?value.map(fn):fn(value)}return newParams}var noop$1=()=>{},isArray=Array.isArray;function mergeOptions(defaults,partialOptions){let options={};for(let key in defaults)options[key]=key in partialOptions?partialOptions[key]:defaults[key];return options}var HASH_RE=/#/g,AMPERSAND_RE=/&/g,SLASH_RE=/\//g,EQUAL_RE=/=/g,IM_RE=/\?/g,PLUS_RE=/\+/g,ENC_BRACKET_OPEN_RE=/%5B/g,ENC_BRACKET_CLOSE_RE=/%5D/g,ENC_CARET_RE=/%5E/g,ENC_BACKTICK_RE=/%60/g,ENC_CURLY_OPEN_RE=/%7B/g,ENC_PIPE_RE=/%7C/g,ENC_CURLY_CLOSE_RE=/%7D/g,ENC_SPACE_RE=/%20/g;function commonEncode(text){return text==null?``:encodeURI(``+text).replace(ENC_PIPE_RE,`|`).replace(ENC_BRACKET_OPEN_RE,`[`).replace(ENC_BRACKET_CLOSE_RE,`]`)}function encodeHash(text){return commonEncode(text).replace(ENC_CURLY_OPEN_RE,`{`).replace(ENC_CURLY_CLOSE_RE,`}`).replace(ENC_CARET_RE,`^`)}function encodeQueryValue(text){return commonEncode(text).replace(PLUS_RE,`%2B`).replace(ENC_SPACE_RE,`+`).replace(HASH_RE,`%23`).replace(AMPERSAND_RE,`%26`).replace(ENC_BACKTICK_RE,"`").replace(ENC_CURLY_OPEN_RE,`{`).replace(ENC_CURLY_CLOSE_RE,`}`).replace(ENC_CARET_RE,`^`)}function encodeQueryKey(text){return encodeQueryValue(text).replace(EQUAL_RE,`%3D`)}function encodePath(text){return commonEncode(text).replace(HASH_RE,`%23`).replace(IM_RE,`%3F`)}function encodeParam(text){return encodePath(text).replace(SLASH_RE,`%2F`)}function decode(text){if(text==null)return null;try{return decodeURIComponent(``+text)}catch{}return``+text}var TRAILING_SLASH_RE=/\/$/,removeTrailingSlash=path=>path.replace(TRAILING_SLASH_RE,``);function parseURL(parseQuery$1,location$1,currentLocation=`/`){let path,query={},searchString=``,hash=``,hashPos=location$1.indexOf(`#`),searchPos=location$1.indexOf(`?`);return searchPos=hashPos>=0&&searchPos>hashPos?-1:searchPos,searchPos>=0&&(path=location$1.slice(0,searchPos),searchString=location$1.slice(searchPos,hashPos>0?hashPos:location$1.length),query=parseQuery$1(searchString.slice(1))),hashPos>=0&&(path||=location$1.slice(0,hashPos),hash=location$1.slice(hashPos,location$1.length)),path=resolveRelativePath(path??location$1,currentLocation),{fullPath:path+searchString+hash,path,query,hash:decode(hash)}}function stringifyURL(stringifyQuery$1,location$1){let query=location$1.query?stringifyQuery$1(location$1.query):``;return location$1.path+(query&&`?`)+query+(location$1.hash||``)}function stripBase(pathname,base){return!base||!pathname.toLowerCase().startsWith(base.toLowerCase())?pathname:pathname.slice(base.length)||`/`}function isSameRouteLocation(stringifyQuery$1,a$1,b){let aLastIndex=a$1.matched.length-1,bLastIndex=b.matched.length-1;return aLastIndex>-1&&aLastIndex===bLastIndex&&isSameRouteRecord(a$1.matched[aLastIndex],b.matched[bLastIndex])&&isSameRouteLocationParams(a$1.params,b.params)&&stringifyQuery$1(a$1.query)===stringifyQuery$1(b.query)&&a$1.hash===b.hash}function isSameRouteRecord(a$1,b){return(a$1.aliasOf||a$1)===(b.aliasOf||b)}function isSameRouteLocationParams(a$1,b){if(Object.keys(a$1).length!==Object.keys(b).length)return!1;for(let key in a$1)if(!isSameRouteLocationParamsValue(a$1[key],b[key]))return!1;return!0}function isSameRouteLocationParamsValue(a$1,b){return isArray(a$1)?isEquivalentArray(a$1,b):isArray(b)?isEquivalentArray(b,a$1):a$1===b}function isEquivalentArray(a$1,b){return isArray(b)?a$1.length===b.length&&a$1.every((value,i)=>value===b[i]):a$1.length===1&&a$1[0]===b}function resolveRelativePath(to,from){if(to.startsWith(`/`))return to;if(!to)return from;let fromSegments=from.split(`/`),toSegments=to.split(`/`),lastToSegment=toSegments[toSegments.length-1];(lastToSegment===`..`||lastToSegment===`.`)&&toSegments.push(``);let position=fromSegments.length-1,toPosition,segment;for(toPosition=0;toPosition1&&position--;else break;return fromSegments.slice(0,position).join(`/`)+`/`+toSegments.slice(toPosition).join(`/`)}var START_LOCATION_NORMALIZED={path:`/`,name:void 0,params:{},query:{},hash:``,fullPath:`/`,matched:[],meta:{},redirectedFrom:void 0},NavigationType=function(NavigationType$1){return NavigationType$1.pop=`pop`,NavigationType$1.push=`push`,NavigationType$1}({}),NavigationDirection=function(NavigationDirection$1){return NavigationDirection$1.back=`back`,NavigationDirection$1.forward=`forward`,NavigationDirection$1.unknown=``,NavigationDirection$1}({});function normalizeBase(base){if(!base)if(isBrowser){let baseEl=document.querySelector(`base`);base=baseEl&&baseEl.getAttribute(`href`)||`/`,base=base.replace(/^\w+:\/\/[^\/]+/,``)}else base=`/`;return base[0]!==`/`&&base[0]!==`#`&&(base=`/`+base),removeTrailingSlash(base)}var BEFORE_HASH_RE=/^[^#]+#/;function createHref(base,location$1){return base.replace(BEFORE_HASH_RE,`#`)+location$1}function getElementPosition(el,offset$2){let docRect=document.documentElement.getBoundingClientRect(),elRect=el.getBoundingClientRect();return{behavior:offset$2.behavior,left:elRect.left-docRect.left-(offset$2.left||0),top:elRect.top-docRect.top-(offset$2.top||0)}}var computeScrollPosition=()=>({left:window.scrollX,top:window.scrollY});function scrollToPosition(position){let scrollToOptions;if(`el`in position){let positionEl=position.el,isIdSelector=typeof positionEl==`string`&&positionEl.startsWith(`#`),el=typeof positionEl==`string`?isIdSelector?document.getElementById(positionEl.slice(1)):document.querySelector(positionEl):positionEl;if(!el)return;scrollToOptions=getElementPosition(el,position)}else scrollToOptions=position;`scrollBehavior`in document.documentElement.style?window.scrollTo(scrollToOptions):window.scrollTo(scrollToOptions.left==null?window.scrollX:scrollToOptions.left,scrollToOptions.top==null?window.scrollY:scrollToOptions.top)}function getScrollKey(path,delta){return(history.state?history.state.position-delta:-1)+path}var scrollPositions=new Map;function saveScrollPosition(key,scrollPosition){scrollPositions.set(key,scrollPosition)}function getSavedScrollPosition(key){let scroll$1=scrollPositions.get(key);return scrollPositions.delete(key),scroll$1}function isRouteLocation(route){return typeof route==`string`||route&&typeof route==`object`}function isRouteName(name){return typeof name==`string`||typeof name==`symbol`}var ErrorTypes=function(ErrorTypes$1){return ErrorTypes$1[ErrorTypes$1.MATCHER_NOT_FOUND=1]=`MATCHER_NOT_FOUND`,ErrorTypes$1[ErrorTypes$1.NAVIGATION_GUARD_REDIRECT=2]=`NAVIGATION_GUARD_REDIRECT`,ErrorTypes$1[ErrorTypes$1.NAVIGATION_ABORTED=4]=`NAVIGATION_ABORTED`,ErrorTypes$1[ErrorTypes$1.NAVIGATION_CANCELLED=8]=`NAVIGATION_CANCELLED`,ErrorTypes$1[ErrorTypes$1.NAVIGATION_DUPLICATED=16]=`NAVIGATION_DUPLICATED`,ErrorTypes$1}({}),NavigationFailureSymbol=Symbol(``);ErrorTypes.MATCHER_NOT_FOUND,ErrorTypes.NAVIGATION_GUARD_REDIRECT,ErrorTypes.NAVIGATION_ABORTED,ErrorTypes.NAVIGATION_CANCELLED,ErrorTypes.NAVIGATION_DUPLICATED;function createRouterError(type,params){return assign(Error(),{type,[NavigationFailureSymbol]:!0},params)}function isNavigationFailure(error,type){return error instanceof Error&&NavigationFailureSymbol in error&&(type==null||!!(error.type&type))}function parseQuery(search$1){let query={};if(search$1===``||search$1===`?`)return query;let searchParams=(search$1[0]===`?`?search$1.slice(1):search$1).split(`&`);for(let i=0;iv&&encodeQueryValue(v)):[value&&encodeQueryValue(value)]).forEach(value$1=>{value$1!==void 0&&(search$1+=(search$1.length?`&`:``)+key,value$1!=null&&(search$1+=`=`+value$1))})}return search$1}function normalizeQuery(query){let normalizedQuery={};for(let key in query){let value=query[key];value!==void 0&&(normalizedQuery[key]=isArray(value)?value.map(v=>v==null?null:``+v):value==null?value:``+value)}return normalizedQuery}var matchedRouteKey=Symbol(``),viewDepthKey=Symbol(``),routerKey=Symbol(``),routeLocationKey=Symbol(``),routerViewLocationKey=Symbol(``);function useCallbacks(){let handlers$1=[];function add$2(handler$1){return handlers$1.push(handler$1),()=>{let i=handlers$1.indexOf(handler$1);i>-1&&handlers$1.splice(i,1)}}function reset$1(){handlers$1=[]}return{add:add$2,list:()=>handlers$1.slice(),reset:reset$1}}function guardToPromiseFn(guard,to,from,record,name,runWithContext=fn=>fn()){let enterCallbackArray=record&&(record.enterCallbacks[name]=record.enterCallbacks[name]||[]);return()=>new Promise((resolve$1,reject)=>{let next=valid=>{valid===!1?reject(createRouterError(ErrorTypes.NAVIGATION_ABORTED,{from,to})):valid instanceof Error?reject(valid):isRouteLocation(valid)?reject(createRouterError(ErrorTypes.NAVIGATION_GUARD_REDIRECT,{from:to,to:valid})):(enterCallbackArray&&record.enterCallbacks[name]===enterCallbackArray&&typeof valid==`function`&&enterCallbackArray.push(valid),resolve$1())},guardReturn=runWithContext(()=>guard.call(record&&record.instances[name],to,from,next)),guardCall=Promise.resolve(guardReturn);guard.length<3&&(guardCall=guardCall.then(next)),guardCall.catch(err=>reject(err))})}function extractComponentsGuards(matched,guardType,to,from,runWithContext=fn=>fn()){let guards=[];for(let record of matched)for(let name in record.components){let rawComponent=record.components[name];if(!(guardType!==`beforeRouteEnter`&&!record.instances[name]))if(isRouteComponent(rawComponent)){let guard=(rawComponent.__vccOpts||rawComponent)[guardType];guard&&guards.push(guardToPromiseFn(guard,to,from,record,name,runWithContext))}else{let componentPromise=rawComponent();guards.push(()=>componentPromise.then(resolved=>{if(!resolved)throw Error(`Couldn't resolve component "${name}" at "${record.path}"`);let resolvedComponent=isESModule(resolved)?resolved.default:resolved;record.mods[name]=resolved,record.components[name]=resolvedComponent;let guard=(resolvedComponent.__vccOpts||resolvedComponent)[guardType];return guard&&guardToPromiseFn(guard,to,from,record,name,runWithContext)()}))}}return guards}function extractChangingRecords(to,from){let leavingRecords=[],updatingRecords=[],enteringRecords=[],len=Math.max(from.matched.length,to.matched.length);for(let i=0;iisSameRouteRecord(record,recordFrom))?updatingRecords.push(recordFrom):leavingRecords.push(recordFrom));let recordTo=to.matched[i];recordTo&&(from.matched.find(record=>isSameRouteRecord(record,recordTo))||enteringRecords.push(recordTo))}return[leavingRecords,updatingRecords,enteringRecords]}var createBaseLocation=()=>location.protocol+`//`+location.host;function createCurrentLocation(base,location$1){let{pathname,search:search$1,hash}=location$1,hashPos=base.indexOf(`#`);if(hashPos>-1){let slicePos=hash.includes(base.slice(hashPos))?base.slice(hashPos).length:1,pathFromHash=hash.slice(slicePos);return pathFromHash[0]!==`/`&&(pathFromHash=`/`+pathFromHash),stripBase(pathFromHash,``)}return stripBase(pathname,base)+search$1+hash}function useHistoryListeners(base,historyState,currentLocation,replace){let listeners=[],teardowns=[],pauseState=null,popStateHandler=({state})=>{let to=createCurrentLocation(base,location),from=currentLocation.value,fromState=historyState.value,delta=0;if(state){if(currentLocation.value=to,historyState.value=state,pauseState&&pauseState===from){pauseState=null;return}delta=fromState?state.position-fromState.position:0}else replace(to);listeners.forEach(listener=>{listener(currentLocation.value,from,{delta,type:NavigationType.pop,direction:delta?delta>0?NavigationDirection.forward:NavigationDirection.back:NavigationDirection.unknown})})};function pauseListeners(){pauseState=currentLocation.value}function listen(callback){listeners.push(callback);let teardown=()=>{let index=listeners.indexOf(callback);index>-1&&listeners.splice(index,1)};return teardowns.push(teardown),teardown}function beforeUnloadListener(){if(document.visibilityState===`hidden`){let{history:history$1}=window;if(!history$1.state)return;history$1.replaceState(assign({},history$1.state,{scroll:computeScrollPosition()}),``)}}function destroy$1(){for(let teardown of teardowns)teardown();teardowns=[],window.removeEventListener(`popstate`,popStateHandler),window.removeEventListener(`pagehide`,beforeUnloadListener),document.removeEventListener(`visibilitychange`,beforeUnloadListener)}return window.addEventListener(`popstate`,popStateHandler),window.addEventListener(`pagehide`,beforeUnloadListener),document.addEventListener(`visibilitychange`,beforeUnloadListener),{pauseListeners,listen,destroy:destroy$1}}function buildState(back,current,forward,replaced=!1,computeScroll=!1){return{back,current,forward,replaced,position:window.history.length,scroll:computeScroll?computeScrollPosition():null}}function useHistoryStateNavigation(base){let{history:history$1,location:location$1}=window,currentLocation={value:createCurrentLocation(base,location$1)},historyState={value:history$1.state};historyState.value||changeLocation(currentLocation.value,{back:null,current:currentLocation.value,forward:null,position:history$1.length-1,replaced:!0,scroll:null},!0);function changeLocation(to,state,replace$1){let hashIndex=base.indexOf(`#`),url=hashIndex>-1?(location$1.host&&document.querySelector(`base`)?base:base.slice(hashIndex))+to:createBaseLocation()+base+to;try{history$1[replace$1?`replaceState`:`pushState`](state,``,url),historyState.value=state}catch(err){console.error(err),location$1[replace$1?`replace`:`assign`](url)}}function replace(to,data){changeLocation(to,assign({},history$1.state,buildState(historyState.value.back,to,historyState.value.forward,!0),data,{position:historyState.value.position}),!0),currentLocation.value=to}function push(to,data){let currentState=assign({},historyState.value,history$1.state,{forward:to,scroll:computeScrollPosition()});changeLocation(currentState.current,currentState,!0),changeLocation(to,assign({},buildState(currentLocation.value,to,null),{position:currentState.position+1},data),!1),currentLocation.value=to}return{location:currentLocation,state:historyState,push,replace}}function createWebHistory(base){base=normalizeBase(base);let historyNavigation=useHistoryStateNavigation(base),historyListeners=useHistoryListeners(base,historyNavigation.state,historyNavigation.location,historyNavigation.replace);function go(delta,triggerListeners=!0){triggerListeners||historyListeners.pauseListeners(),history.go(delta)}let routerHistory=assign({location:``,base,go,createHref:createHref.bind(null,base)},historyNavigation,historyListeners);return Object.defineProperty(routerHistory,`location`,{enumerable:!0,get:()=>historyNavigation.location.value}),Object.defineProperty(routerHistory,`state`,{enumerable:!0,get:()=>historyNavigation.state.value}),routerHistory}function createWebHashHistory(base){return base=location.host?base||location.pathname+location.search:``,base.includes(`#`)||(base+=`#`),createWebHistory(base)}var TokenType=function(TokenType$1){return TokenType$1[TokenType$1.Static=0]=`Static`,TokenType$1[TokenType$1.Param=1]=`Param`,TokenType$1[TokenType$1.Group=2]=`Group`,TokenType$1}({}),TokenizerState=function(TokenizerState$1){return TokenizerState$1[TokenizerState$1.Static=0]=`Static`,TokenizerState$1[TokenizerState$1.Param=1]=`Param`,TokenizerState$1[TokenizerState$1.ParamRegExp=2]=`ParamRegExp`,TokenizerState$1[TokenizerState$1.ParamRegExpEnd=3]=`ParamRegExpEnd`,TokenizerState$1[TokenizerState$1.EscapeNext=4]=`EscapeNext`,TokenizerState$1}(TokenizerState||{}),ROOT_TOKEN={type:TokenType.Static,value:``},VALID_PARAM_RE=/[a-zA-Z0-9_]/;function tokenizePath(path){if(!path)return[[]];if(path===`/`)return[[ROOT_TOKEN]];if(!path.startsWith(`/`))throw Error(`Invalid path "${path}"`);function crash(message){throw Error(`ERR (${state})/"${buffer$1}": ${message}`)}let state=TokenizerState.Static,previousState=state,tokens=[],segment;function finalizeSegment(){segment&&tokens.push(segment),segment=[]}let i=0,char,buffer$1=``,customRe=``;function consumeBuffer(){buffer$1&&=(state===TokenizerState.Static?segment.push({type:TokenType.Static,value:buffer$1}):state===TokenizerState.Param||state===TokenizerState.ParamRegExp||state===TokenizerState.ParamRegExpEnd?(segment.length>1&&(char===`*`||char===`+`)&&crash(`A repeatable param (${buffer$1}) must be alone in its segment. eg: '/:ids+.`),segment.push({type:TokenType.Param,value:buffer$1,regexp:customRe,repeatable:char===`*`||char===`+`,optional:char===`*`||char===`?`})):crash(`Invalid state to consume buffer`),``)}function addCharToBuffer(){buffer$1+=char}for(;ib.length?b.length===1&&b[0]===PathScore.Static+PathScore.Segment?1:-1:0}function comparePathParserScore(a$1,b){let i=0,aScore=a$1.score,bScore=b.score;for(;i0&&last[last.length-1]<0}var PATH_PARSER_OPTIONS_DEFAULTS={strict:!1,end:!0,sensitive:!1};function createRouteRecordMatcher(record,parent,options){let matcher=assign(tokensToParser(tokenizePath(record.path),options),{record,parent,children:[],alias:[]});return parent&&!matcher.record.aliasOf==!parent.record.aliasOf&&parent.children.push(matcher),matcher}function createRouterMatcher(routes,globalOptions){let matchers=[],matcherMap=new Map;globalOptions=mergeOptions(PATH_PARSER_OPTIONS_DEFAULTS,globalOptions);function getRecordMatcher(name){return matcherMap.get(name)}function addRoute(record,parent,originalRecord){let isRootAdd=!originalRecord,mainNormalizedRecord=normalizeRouteRecord(record);mainNormalizedRecord.aliasOf=originalRecord&&originalRecord.record;let options=mergeOptions(globalOptions,record),normalizedRecords=[mainNormalizedRecord];if(`alias`in record){let aliases=typeof record.alias==`string`?[record.alias]:record.alias;for(let alias of aliases)normalizedRecords.push(normalizeRouteRecord(assign({},mainNormalizedRecord,{components:originalRecord?originalRecord.record.components:mainNormalizedRecord.components,path:alias,aliasOf:originalRecord?originalRecord.record:mainNormalizedRecord})))}let matcher,originalMatcher;for(let normalizedRecord of normalizedRecords){let{path}=normalizedRecord;if(parent&&path[0]!==`/`){let parentPath=parent.record.path,connectingSlash=parentPath[parentPath.length-1]===`/`?``:`/`;normalizedRecord.path=parent.record.path+(path&&connectingSlash+path)}if(matcher=createRouteRecordMatcher(normalizedRecord,parent,options),originalRecord?originalRecord.alias.push(matcher):(originalMatcher||=matcher,originalMatcher!==matcher&&originalMatcher.alias.push(matcher),isRootAdd&&record.name&&!isAliasRecord(matcher)&&removeRoute(record.name)),isMatchable(matcher)&&insertMatcher(matcher),mainNormalizedRecord.children){let children=mainNormalizedRecord.children;for(let i=0;i{removeRoute(originalMatcher)}:noop$1}function removeRoute(matcherRef){if(isRouteName(matcherRef)){let matcher=matcherMap.get(matcherRef);matcher&&(matcherMap.delete(matcherRef),matchers.splice(matchers.indexOf(matcher),1),matcher.children.forEach(removeRoute),matcher.alias.forEach(removeRoute))}else{let index=matchers.indexOf(matcherRef);index>-1&&(matchers.splice(index,1),matcherRef.record.name&&matcherMap.delete(matcherRef.record.name),matcherRef.children.forEach(removeRoute),matcherRef.alias.forEach(removeRoute))}}function getRoutes(){return matchers}function insertMatcher(matcher){let index=findInsertionIndex(matcher,matchers);matchers.splice(index,0,matcher),matcher.record.name&&!isAliasRecord(matcher)&&matcherMap.set(matcher.record.name,matcher)}function resolve$1(location$1,currentLocation){let matcher,params={},path,name;if(`name`in location$1&&location$1.name){if(matcher=matcherMap.get(location$1.name),!matcher)throw createRouterError(ErrorTypes.MATCHER_NOT_FOUND,{location:location$1});name=matcher.record.name,params=assign(pickParams(currentLocation.params,matcher.keys.filter(k=>!k.optional).concat(matcher.parent?matcher.parent.keys.filter(k=>k.optional):[]).map(k=>k.name)),location$1.params&&pickParams(location$1.params,matcher.keys.map(k=>k.name))),path=matcher.stringify(params)}else if(location$1.path!=null)path=location$1.path,matcher=matchers.find(m=>m.re.test(path)),matcher&&(params=matcher.parse(path),name=matcher.record.name);else{if(matcher=currentLocation.name?matcherMap.get(currentLocation.name):matchers.find(m=>m.re.test(currentLocation.path)),!matcher)throw createRouterError(ErrorTypes.MATCHER_NOT_FOUND,{location:location$1,currentLocation});name=matcher.record.name,params=assign({},currentLocation.params,location$1.params),path=matcher.stringify(params)}let matched=[],parentMatcher=matcher;for(;parentMatcher;)matched.unshift(parentMatcher.record),parentMatcher=parentMatcher.parent;return{name,path,params,matched,meta:mergeMetaFields(matched)}}routes.forEach(route=>addRoute(route));function clearRoutes(){matchers.length=0,matcherMap.clear()}return{addRoute,resolve:resolve$1,removeRoute,clearRoutes,getRoutes,getRecordMatcher}}function pickParams(params,keys){let newParams={};for(let key of keys)key in params&&(newParams[key]=params[key]);return newParams}function normalizeRouteRecord(record){let normalized={path:record.path,redirect:record.redirect,name:record.name,meta:record.meta||{},aliasOf:record.aliasOf,beforeEnter:record.beforeEnter,props:normalizeRecordProps(record),children:record.children||[],instances:{},leaveGuards:new Set,updateGuards:new Set,enterCallbacks:{},components:`components`in record?record.components||null:record.component&&{default:record.component}};return Object.defineProperty(normalized,`mods`,{value:{}}),normalized}function normalizeRecordProps(record){let propsObject={},props=record.props||!1;if(`component`in record)propsObject.default=props;else for(let name in record.components)propsObject[name]=typeof props==`object`?props[name]:props;return propsObject}function isAliasRecord(record){for(;record;){if(record.record.aliasOf)return!0;record=record.parent}return!1}function mergeMetaFields(matched){return matched.reduce((meta,record)=>assign(meta,record.meta),{})}function findInsertionIndex(matcher,matchers){let lower=0,upper=matchers.length;for(;lower!==upper;){let mid=lower+upper>>1;comparePathParserScore(matcher,matchers[mid])<0?upper=mid:lower=mid+1}let insertionAncestor=getInsertionAncestor(matcher);return insertionAncestor&&(upper=matchers.lastIndexOf(insertionAncestor,upper-1)),upper}function getInsertionAncestor(matcher){let ancestor=matcher;for(;ancestor=ancestor.parent;)if(isMatchable(ancestor)&&comparePathParserScore(matcher,ancestor)===0)return ancestor}function isMatchable({record}){return!!(record.name||record.components&&Object.keys(record.components).length||record.redirect)}function useLink(props){let router$1=inject(routerKey),currentRoute=inject(routeLocationKey),route=computed(()=>{let to=unref(props.to);return router$1.resolve(to)}),activeRecordIndex=computed(()=>{let{matched}=route.value,{length}=matched,routeMatched=matched[length-1],currentMatched=currentRoute.matched;if(!routeMatched||!currentMatched.length)return-1;let index=currentMatched.findIndex(isSameRouteRecord.bind(null,routeMatched));if(index>-1)return index;let parentRecordPath=getOriginalPath(matched[length-2]);return length>1&&getOriginalPath(routeMatched)===parentRecordPath&¤tMatched[currentMatched.length-1].path!==parentRecordPath?currentMatched.findIndex(isSameRouteRecord.bind(null,matched[length-2])):index}),isActive=computed(()=>activeRecordIndex.value>-1&&includesParams(currentRoute.params,route.value.params)),isExactActive=computed(()=>activeRecordIndex.value>-1&&activeRecordIndex.value===currentRoute.matched.length-1&&isSameRouteLocationParams(currentRoute.params,route.value.params));function navigate$1(e={}){if(guardEvent(e)){let p$1=router$1[unref(props.replace)?`replace`:`push`](unref(props.to)).catch(noop$1);return props.viewTransition&&typeof document<`u`&&`startViewTransition`in document&&document.startViewTransition(()=>p$1),p$1}return Promise.resolve()}return{route,href:computed(()=>route.value.href),isActive,isExactActive,navigate:navigate$1}}function preferSingleVNode(vnodes){return vnodes.length===1?vnodes[0]:vnodes}var RouterLink=defineComponent({name:`RouterLink`,compatConfig:{MODE:3},props:{to:{type:[String,Object],required:!0},replace:Boolean,activeClass:String,exactActiveClass:String,custom:Boolean,ariaCurrentValue:{type:String,default:`page`},viewTransition:Boolean},useLink,setup(props,{slots}){let link=reactive(useLink(props)),{options}=inject(routerKey),elClass=computed(()=>({[getLinkClass(props.activeClass,options.linkActiveClass,`router-link-active`)]:link.isActive,[getLinkClass(props.exactActiveClass,options.linkExactActiveClass,`router-link-exact-active`)]:link.isExactActive}));return()=>{let children=slots.default&&preferSingleVNode(slots.default(link));return props.custom?children:h(`a`,{"aria-current":link.isExactActive?props.ariaCurrentValue:null,href:link.href,onClick:link.navigate,class:elClass.value},children)}}});function guardEvent(e){if(!(e.metaKey||e.altKey||e.ctrlKey||e.shiftKey)&&!e.defaultPrevented&&!(e.button!==void 0&&e.button!==0)){if(e.currentTarget&&e.currentTarget.getAttribute){let target=e.currentTarget.getAttribute(`target`);if(/\b_blank\b/i.test(target))return}return e.preventDefault&&e.preventDefault(),!0}}function includesParams(outer,inner){for(let key in inner){let innerValue=inner[key],outerValue=outer[key];if(typeof innerValue==`string`){if(innerValue!==outerValue)return!1}else if(!isArray(outerValue)||outerValue.length!==innerValue.length||innerValue.some((value,i)=>value!==outerValue[i]))return!1}return!0}function getOriginalPath(record){return record?record.aliasOf?record.aliasOf.path:record.path:``}var getLinkClass=(propClass,globalClass,defaultClass)=>propClass??globalClass??defaultClass,RouterViewImpl=defineComponent({name:`RouterView`,inheritAttrs:!1,props:{name:{type:String,default:`default`},route:Object},compatConfig:{MODE:3},setup(props,{attrs,slots}){let injectedRoute=inject(routerViewLocationKey),routeToDisplay=computed(()=>props.route||injectedRoute.value),injectedDepth=inject(viewDepthKey,0),depth=computed(()=>{let initialDepth=unref(injectedDepth),{matched}=routeToDisplay.value,matchedRoute;for(;(matchedRoute=matched[initialDepth])&&!matchedRoute.components;)initialDepth++;return initialDepth}),matchedRouteRef=computed(()=>routeToDisplay.value.matched[depth.value]);provide(viewDepthKey,computed(()=>depth.value+1)),provide(matchedRouteKey,matchedRouteRef),provide(routerViewLocationKey,routeToDisplay);let viewRef=ref();return watch(()=>[viewRef.value,matchedRouteRef.value,props.name],([instance$1,to,name],[oldInstance,from,oldName])=>{to&&(to.instances[name]=instance$1,from&&from!==to&&instance$1&&instance$1===oldInstance&&(to.leaveGuards.size||(to.leaveGuards=from.leaveGuards),to.updateGuards.size||(to.updateGuards=from.updateGuards))),instance$1&&to&&(!from||!isSameRouteRecord(to,from)||!oldInstance)&&(to.enterCallbacks[name]||[]).forEach(callback=>callback(instance$1))},{flush:`post`}),()=>{let route=routeToDisplay.value,currentName=props.name,matchedRoute=matchedRouteRef.value,ViewComponent=matchedRoute&&matchedRoute.components[currentName];if(!ViewComponent)return normalizeSlot(slots.default,{Component:ViewComponent,route});let routePropsOption=matchedRoute.props[currentName],component=h(ViewComponent,assign({},routePropsOption?routePropsOption===!0?route.params:typeof routePropsOption==`function`?routePropsOption(route):routePropsOption:null,attrs,{onVnodeUnmounted:vnode=>{vnode.component.isUnmounted&&(matchedRoute.instances[currentName]=null)},ref:viewRef}));return normalizeSlot(slots.default,{Component:component,route})||component}}});function normalizeSlot(slot,data){if(!slot)return null;let slotContent=slot(data);return slotContent.length===1?slotContent[0]:slotContent}var RouterView=RouterViewImpl;function createRouter(options){let matcher=createRouterMatcher(options.routes,options),parseQuery$1=options.parseQuery||parseQuery,stringifyQuery$1=options.stringifyQuery||stringifyQuery,routerHistory=options.history,beforeGuards=useCallbacks(),beforeResolveGuards=useCallbacks(),afterGuards=useCallbacks(),currentRoute=shallowRef(START_LOCATION_NORMALIZED),pendingLocation=START_LOCATION_NORMALIZED;isBrowser&&options.scrollBehavior&&`scrollRestoration`in history&&(history.scrollRestoration=`manual`);let normalizeParams=applyToParams.bind(null,paramValue=>``+paramValue),encodeParams=applyToParams.bind(null,encodeParam),decodeParams=applyToParams.bind(null,decode);function addRoute(parentOrRoute,route){let parent,record;return isRouteName(parentOrRoute)?(parent=matcher.getRecordMatcher(parentOrRoute),record=route):record=parentOrRoute,matcher.addRoute(record,parent)}function removeRoute(name){let recordMatcher=matcher.getRecordMatcher(name);recordMatcher&&matcher.removeRoute(recordMatcher)}function getRoutes(){return matcher.getRoutes().map(routeMatcher=>routeMatcher.record)}function hasRoute(name){return!!matcher.getRecordMatcher(name)}function resolve$1(rawLocation,currentLocation){if(currentLocation=assign({},currentLocation||currentRoute.value),typeof rawLocation==`string`){let locationNormalized=parseURL(parseQuery$1,rawLocation,currentLocation.path),matchedRoute$1=matcher.resolve({path:locationNormalized.path},currentLocation),href$1=routerHistory.createHref(locationNormalized.fullPath);return assign(locationNormalized,matchedRoute$1,{params:decodeParams(matchedRoute$1.params),hash:decode(locationNormalized.hash),redirectedFrom:void 0,href:href$1})}let matcherLocation;if(rawLocation.path!=null)matcherLocation=assign({},rawLocation,{path:parseURL(parseQuery$1,rawLocation.path,currentLocation.path).path});else{let targetParams=assign({},rawLocation.params);for(let key in targetParams)targetParams[key]??delete targetParams[key];matcherLocation=assign({},rawLocation,{params:encodeParams(targetParams)}),currentLocation.params=encodeParams(currentLocation.params)}let matchedRoute=matcher.resolve(matcherLocation,currentLocation),hash=rawLocation.hash||``;matchedRoute.params=normalizeParams(decodeParams(matchedRoute.params));let fullPath=stringifyURL(stringifyQuery$1,assign({},rawLocation,{hash:encodeHash(hash),path:matchedRoute.path})),href=routerHistory.createHref(fullPath);return assign({fullPath,hash,query:stringifyQuery$1===stringifyQuery?normalizeQuery(rawLocation.query):rawLocation.query||{}},matchedRoute,{redirectedFrom:void 0,href})}function locationAsObject(to){return typeof to==`string`?parseURL(parseQuery$1,to,currentRoute.value.path):assign({},to)}function checkCanceledNavigation(to,from){if(pendingLocation!==to)return createRouterError(ErrorTypes.NAVIGATION_CANCELLED,{from,to})}function push(to){return pushWithRedirect(to)}function replace(to){return push(assign(locationAsObject(to),{replace:!0}))}function handleRedirectRecord(to,from){let lastMatched=to.matched[to.matched.length-1];if(lastMatched&&lastMatched.redirect){let{redirect}=lastMatched,newTargetLocation=typeof redirect==`function`?redirect(to,from):redirect;return typeof newTargetLocation==`string`&&(newTargetLocation=newTargetLocation.includes(`?`)||newTargetLocation.includes(`#`)?newTargetLocation=locationAsObject(newTargetLocation):{path:newTargetLocation},newTargetLocation.params={}),assign({query:to.query,hash:to.hash,params:newTargetLocation.path==null?to.params:{}},newTargetLocation)}}function pushWithRedirect(to,redirectedFrom){let targetLocation=pendingLocation=resolve$1(to),from=currentRoute.value,data=to.state,force=to.force,replace$1=to.replace===!0,shouldRedirect=handleRedirectRecord(targetLocation,from);if(shouldRedirect)return pushWithRedirect(assign(locationAsObject(shouldRedirect),{state:typeof shouldRedirect==`object`?assign({},data,shouldRedirect.state):data,force,replace:replace$1}),redirectedFrom||targetLocation);let toLocation=targetLocation;toLocation.redirectedFrom=redirectedFrom;let failure;return!force&&isSameRouteLocation(stringifyQuery$1,from,targetLocation)&&(failure=createRouterError(ErrorTypes.NAVIGATION_DUPLICATED,{to:toLocation,from}),handleScroll(from,from,!0,!1)),(failure?Promise.resolve(failure):navigate$1(toLocation,from)).catch(error=>isNavigationFailure(error)?isNavigationFailure(error,ErrorTypes.NAVIGATION_GUARD_REDIRECT)?error:markAsReady(error):triggerError(error,toLocation,from)).then(failure$1=>{if(failure$1){if(isNavigationFailure(failure$1,ErrorTypes.NAVIGATION_GUARD_REDIRECT))return pushWithRedirect(assign({replace:replace$1},locationAsObject(failure$1.to),{state:typeof failure$1.to==`object`?assign({},data,failure$1.to.state):data,force}),redirectedFrom||toLocation)}else failure$1=finalizeNavigation(toLocation,from,!0,replace$1,data);return triggerAfterEach(toLocation,from,failure$1),failure$1})}function checkCanceledNavigationAndReject(to,from){let error=checkCanceledNavigation(to,from);return error?Promise.reject(error):Promise.resolve()}function runWithContext(fn){let app$1=installedApps.values().next().value;return app$1&&typeof app$1.runWithContext==`function`?app$1.runWithContext(fn):fn()}function navigate$1(to,from){let guards,[leavingRecords,updatingRecords,enteringRecords]=extractChangingRecords(to,from);guards=extractComponentsGuards(leavingRecords.reverse(),`beforeRouteLeave`,to,from);for(let record of leavingRecords)record.leaveGuards.forEach(guard=>{guards.push(guardToPromiseFn(guard,to,from))});let canceledNavigationCheck=checkCanceledNavigationAndReject.bind(null,to,from);return guards.push(canceledNavigationCheck),runGuardQueue(guards).then(()=>{guards=[];for(let guard of beforeGuards.list())guards.push(guardToPromiseFn(guard,to,from));return guards.push(canceledNavigationCheck),runGuardQueue(guards)}).then(()=>{guards=extractComponentsGuards(updatingRecords,`beforeRouteUpdate`,to,from);for(let record of updatingRecords)record.updateGuards.forEach(guard=>{guards.push(guardToPromiseFn(guard,to,from))});return guards.push(canceledNavigationCheck),runGuardQueue(guards)}).then(()=>{guards=[];for(let record of enteringRecords)if(record.beforeEnter)if(isArray(record.beforeEnter))for(let beforeEnter of record.beforeEnter)guards.push(guardToPromiseFn(beforeEnter,to,from));else guards.push(guardToPromiseFn(record.beforeEnter,to,from));return guards.push(canceledNavigationCheck),runGuardQueue(guards)}).then(()=>(to.matched.forEach(record=>record.enterCallbacks={}),guards=extractComponentsGuards(enteringRecords,`beforeRouteEnter`,to,from,runWithContext),guards.push(canceledNavigationCheck),runGuardQueue(guards))).then(()=>{guards=[];for(let guard of beforeResolveGuards.list())guards.push(guardToPromiseFn(guard,to,from));return guards.push(canceledNavigationCheck),runGuardQueue(guards)}).catch(err=>isNavigationFailure(err,ErrorTypes.NAVIGATION_CANCELLED)?err:Promise.reject(err))}function triggerAfterEach(to,from,failure){afterGuards.list().forEach(guard=>runWithContext(()=>guard(to,from,failure)))}function finalizeNavigation(toLocation,from,isPush,replace$1,data){let error=checkCanceledNavigation(toLocation,from);if(error)return error;let isFirstNavigation=from===START_LOCATION_NORMALIZED,state=isBrowser?history.state:{};isPush&&(replace$1||isFirstNavigation?routerHistory.replace(toLocation.fullPath,assign({scroll:isFirstNavigation&&state&&state.scroll},data)):routerHistory.push(toLocation.fullPath,data)),currentRoute.value=toLocation,handleScroll(toLocation,from,isPush,isFirstNavigation),markAsReady()}let removeHistoryListener;function setupListeners(){removeHistoryListener||=routerHistory.listen((to,_from,info)=>{if(!router$1.listening)return;let toLocation=resolve$1(to),shouldRedirect=handleRedirectRecord(toLocation,router$1.currentRoute.value);if(shouldRedirect){pushWithRedirect(assign(shouldRedirect,{replace:!0,force:!0}),toLocation).catch(noop$1);return}pendingLocation=toLocation;let from=currentRoute.value;isBrowser&&saveScrollPosition(getScrollKey(from.fullPath,info.delta),computeScrollPosition()),navigate$1(toLocation,from).catch(error=>isNavigationFailure(error,ErrorTypes.NAVIGATION_ABORTED|ErrorTypes.NAVIGATION_CANCELLED)?error:isNavigationFailure(error,ErrorTypes.NAVIGATION_GUARD_REDIRECT)?(pushWithRedirect(assign(locationAsObject(error.to),{force:!0}),toLocation).then(failure=>{isNavigationFailure(failure,ErrorTypes.NAVIGATION_ABORTED|ErrorTypes.NAVIGATION_DUPLICATED)&&!info.delta&&info.type===NavigationType.pop&&routerHistory.go(-1,!1)}).catch(noop$1),Promise.reject()):(info.delta&&routerHistory.go(-info.delta,!1),triggerError(error,toLocation,from))).then(failure=>{failure||=finalizeNavigation(toLocation,from,!1),failure&&(info.delta&&!isNavigationFailure(failure,ErrorTypes.NAVIGATION_CANCELLED)?routerHistory.go(-info.delta,!1):info.type===NavigationType.pop&&isNavigationFailure(failure,ErrorTypes.NAVIGATION_ABORTED|ErrorTypes.NAVIGATION_DUPLICATED)&&routerHistory.go(-1,!1)),triggerAfterEach(toLocation,from,failure)}).catch(noop$1)})}let readyHandlers=useCallbacks(),errorListeners=useCallbacks(),ready;function triggerError(error,to,from){markAsReady(error);let list=errorListeners.list();return list.length?list.forEach(handler$1=>handler$1(error,to,from)):console.error(error),Promise.reject(error)}function isReady(){return ready&¤tRoute.value!==START_LOCATION_NORMALIZED?Promise.resolve():new Promise((resolve$1$1,reject)=>{readyHandlers.add([resolve$1$1,reject])})}function markAsReady(err){return ready||(ready=!err,setupListeners(),readyHandlers.list().forEach(([resolve$1$1,reject])=>err?reject(err):resolve$1$1()),readyHandlers.reset()),err}function handleScroll(to,from,isPush,isFirstNavigation){let{scrollBehavior}=options;if(!isBrowser||!scrollBehavior)return Promise.resolve();let scrollPosition=!isPush&&getSavedScrollPosition(getScrollKey(to.fullPath,0))||(isFirstNavigation||!isPush)&&history.state&&history.state.scroll||null;return nextTick().then(()=>scrollBehavior(to,from,scrollPosition)).then(position=>position&&scrollToPosition(position)).catch(err=>triggerError(err,to,from))}let go=delta=>routerHistory.go(delta),started,installedApps=new Set,router$1={currentRoute,listening:!0,addRoute,removeRoute,clearRoutes:matcher.clearRoutes,hasRoute,getRoutes,resolve:resolve$1,options,push,replace,go,back:()=>go(-1),forward:()=>go(1),beforeEach:beforeGuards.add,beforeResolve:beforeResolveGuards.add,afterEach:afterGuards.add,onError:errorListeners.add,isReady,install(app$1){app$1.component(`RouterLink`,RouterLink),app$1.component(`RouterView`,RouterView),app$1.config.globalProperties.$router=router$1,Object.defineProperty(app$1.config.globalProperties,`$route`,{enumerable:!0,get:()=>unref(currentRoute)}),isBrowser&&!started&¤tRoute.value===START_LOCATION_NORMALIZED&&(started=!0,push(routerHistory.location).catch(err=>{}));let reactiveRoute={};for(let key in START_LOCATION_NORMALIZED)Object.defineProperty(reactiveRoute,key,{get:()=>currentRoute.value[key],enumerable:!0});app$1.provide(routerKey,router$1),app$1.provide(routeLocationKey,shallowReactive(reactiveRoute)),app$1.provide(routerViewLocationKey,currentRoute);let unmountApp=app$1.unmount;installedApps.add(app$1),app$1.unmount=function(){installedApps.delete(app$1),installedApps.size<1&&(pendingLocation=START_LOCATION_NORMALIZED,removeHistoryListener&&removeHistoryListener(),removeHistoryListener=null,currentRoute.value=START_LOCATION_NORMALIZED,started=!1,ready=!1),unmountApp()}}};function runGuardQueue(guards){return guards.reduce((promise,guard)=>promise.then(()=>runWithContext(guard)),Promise.resolve())}return router$1}function useRouter(){return inject(routerKey)}function useRoute(_name){return inject(routeLocationKey)}function spawnUiApp(appName,appId,params,apps){let props=params?params.props:null,appKey=`${appName}${appId}`;apps.push({name:appName,appId,appKey,comp:appName,props,teleport:`#${appName+appId}`})}function destroyUiApp(appName,apps){let index=apps.findIndex(x=>x.name===appName);index>-1&&apps.splice(index,1)}function registerApps(app$1,componentsMap){Object.keys(componentsMap).forEach(key=>app$1.component(key,componentsMap[key]))}var _sfc_main$325={};function _sfc_render$5(_ctx,_cache){return null}var layoutEmpty_default=__plugin_vue_export_helper_default(_sfc_main$325,[[`render`,_sfc_render$5]]);const LAYOUT_ALIGNMENTS={left:`flex-start`,right:`flex-end`,center:`center`};var _sfc_main$324={},_hoisted_1$287={class:`layout-wrapper layout-safezones`},_hoisted_2$235={class:`layout-content`};function _sfc_render$4(_ctx,_cache,$props,$setup,$data,$options){return openBlock(),createElementBlock(`div`,_hoisted_1$287,[createBaseVNode(`div`,_hoisted_2$235,[renderSlot(_ctx.$slots,`default`,{},()=>[_cache[0]||=createTextVNode(`Content here`,-1)])])])}var layoutSingle_default=__plugin_vue_export_helper_default(_sfc_main$324,[[`render`,_sfc_render$4]]);const useEvents=(onDispose=onBeforeUnmount)=>{let bridge$4=useBridge(),events$3={_on:{},_once:{},on(name,func){name in events$3._on||(events$3._on[name]=[]),events$3._on[name].indexOf(func)===-1&&(bridge$4.events.on(name,func),events$3._on[name].push(func))},once(name,func){name in events$3._once||(events$3._once[name]=[]),events$3._once[name].indexOf(func)===-1&&(bridge$4.events.once(name,()=>{let idx=events$3._once[name].indexOf(func);idx>-1&&events$3._once[name].splice(idx,1)}),bridge$4.events.once(name,func),events$3._once[name].push(func))},off(name=void 0,func=void 0){if(!name){for(let name$1 in events$3._on){for(let func$1 of events$3._on[name$1])bridge$4.events.off(name$1,func$1);delete events$3._on[name$1]}return}if(name in events$3._on)if(func){let idx=events$3._on[name].indexOf(func);idx>-1&&(bridge$4.events.off(name,func),events$3._on[name].splice(idx,1)),events$3._on[name].length===0&&delete events$3._on[name]}else{for(let func$1 of events$3._on[name])bridge$4.events.off(name,func$1);delete events$3._on[name]}},emit(name,...values){bridge$4.events.emit(name,...values)}};return onDispose(()=>{for(let type of[`_on`,`_once`])for(let name in events$3[type]){for(let func of events$3[type][name])bridge$4.events.off(name,func);delete events$3[type][name]}}),events$3},useStreams=(names,callback,onDispose=onBeforeUnmount)=>{let bridge$4=useBridge(),enabled=!1,streams={on(){enabled||(enabled=!0,bridge$4.streams.add(names),bridge$4.events.on(`onStreamsUpdate`,callback))},off(){enabled&&(enabled=!1,bridge$4.streams.remove(names),bridge$4.events.off(`onStreamsUpdate`,callback))}};return streams.on(),onDispose(streams.off),streams};var hints_default=`ui.hints.quickSteerResponse,ui.hints.raceBrakesEffectiveness,ui.hints.quickCameraMovement,ui.hints.grabVehicleParts,ui.hints.funStabilityControl,ui.hints.recoverVehicle,ui.hints.oldCarsBurn,ui.hints.smokingWheels,ui.hints.carsBurnFuel,ui.hints.delicateCars,ui.hints.stabilityControlPresent,ui.hints.absWasOptional,ui.hints.installRollCage,ui.hints.spatialNavigation,ui.hints.repairHood,ui.hints.slowMotionPhysics,ui.hints.removeRearSeats,ui.hints.tuning,ui.hints.customLicensePlate,ui.hints.driveAtNight,ui.hints.moonGravity,ui.hints.unlockExtraFunctionality,ui.hints.playMultiseat,ui.hints.increaseGroundClearance,ui.hints.tiresBurstOnBumps,ui.hints.blueSmokeIsPistonDamage,ui.hints.keepTheEngineUpright,ui.hints.thermalDebugApp,ui.hints.rollPitchApps,ui.hints.cruiseControlApp,ui.hints.driveTheCanon,ui.hints.vehicleSkins,ui.hints.toggleMods,ui.hints.importveFramerate,ui.hints.photoModeMenu,ui.hints.publishScreenshots,ui.hints.towTrailer,ui.hints.brakesAndSteeringVary,ui.hints.countersteerEarly,ui.hints.startSlow,ui.hints.parkingbrakeForTurning,ui.hints.carefulWithOldSportsCars,ui.hints.corneringWithKeyboard,ui.hints.adaptToBadRoads,ui.hints.notAllCarsCanRace,ui.hints.changeBrakePads,ui.hints.useTurnSignals,ui.hints.showStandalonePcs,ui.hints.tweakFOV,ui.hints.driveWithMouse,ui.hints.liftOffOversteer,ui.hints.snapOversteer,ui.hints.slideBackWithParkingBrake,ui.hints.customizeSpecializedBindings,ui.hints.toggleFogLights,ui.hints.toggleLightBars,ui.hints.TrackIRSupported,ui.hints.chooseShiftingMode,ui.hints.saveRestoreVehicleHome,ui.hints.switchVehicle,ui.hints.coolantVaporizes,ui.hints.dontRunIntoTheCar`.split(`,`),_hoisted_1$286={key:0,class:`progress-box`},_hoisted_2$234={class:`progress-icon-group`},_hoisted_3$208={class:`progress-bar-container`},_hoisted_4$178={class:`progress-status`},_hoisted_5$153={class:`progress-history`},_hoisted_6$132={class:`custom-left-container`},_hoisted_7$118={key:0,class:`custom-text-panel`},_hoisted_8$99={key:1,class:`text`},_hoisted_9$89={key:1,class:`custom-indeterminate-panel`},_hoisted_10$77={class:`custom-right-container`},_hoisted_11$69={key:2,class:`tips-bar`},_hoisted_12$57={class:`tips-bar-title`},_hoisted_13$49={class:`tips-bar-tip`},_hoisted_14$44={key:0,class:`loading-cache`},_hoisted_15$42=[`src`],imagesAmount=18,activeRepeatTime=1e4,fadeInDefault=1e3,fadeOutDefault=2e3,_sfc_main$323={__name:`LoadingScreen`,setup(__props){useCssVars(_ctx=>({v79c091d8:fadeInTimeVar.value,v07559aed:fadeOutTimeVar.value}));let events$3=useEvents(),{lua}=useBridge(),navBlocker=useUINavBlocker(),lastImageNum=-1,repeatTimer=null,customTimer=null,iconsList=[{id:`terrain`,icon:icons.terrain},{id:`environment`,icon:icons.water},{id:`forest`,icon:icons.trafficCone},{id:`meshes`,icon:icons.garage01},{id:`roads`,icon:icons.road},{id:`beamng`,icon:icons.beamNG}],state=reactive({active:!1,visible:!1,fading:!1,shown:!1,autoActivate:!0,highSeas:!1,mode:`progress`,image:null,iconState:{},currentEntries:[],historyEntriesDisplay:[],customContent:null,fadeInTime:fadeInDefault,fadeOutTime:fadeOutDefault,customPause:-1});function resetState(){state.mode=`progress`,state.customContent=null,state.iconState={},state.currentEntries=[],state.historyEntriesDisplay=[],state.fadeInTime=fadeInDefault,state.fadeOutTime=fadeOutDefault,state.customPause=-1}let tip=ref(``),setTip=(txt=void 0,_retrying=!1)=>{let idx=~~(Math.random()*hints_default.length);tip.value=txt||hints_default[idx],(!tip.value||tip.value===`undefined`)&&(logger_default.debug(`Loading Screen tip is undefined!\nARG: ${JSON.stringify(txt)} TIP: ${JSON.stringify(tip.value)} IDX: ${idx}/${hints_default.length}`),_retrying?tip.value=``:setTip(void 0,!0))},fadeInTimeVar=computed(()=>state.fadeInTime+`ms`),fadeOutTimeVar=computed(()=>state.fadeOutTime+`ms`),progressValue=computed(()=>state.currentEntries[0]?.progress||0),currentStatus=computed(()=>state.currentEntries[0]?.message||``);events$3.on(`LoadingScreen`,data=>{if(window.beamng?.ingame){if((!data||typeof data!=`object`)&&(data={}),state.autoActivate=!1,state.active=!!data.active,data.custom&&(state.mode=`custom`,state.fadeInTime=data.custom.fadeIn>0?data.custom.fadeIn*1e3:state.fadeInTime||0,state.fadeOutTime=data.custom.fadeOut>0?data.custom.fadeOut*1e3:state.fadeOutTime||0),state.active)data.custom?(state.customPause=data.custom.pause?data.custom.pause*1e3:-1,state.customContent=data.custom.data,state.customContent?.image&&(state.image=state.customContent.image)):(resetState(),window.bngVue.gotoAngularState(`blank`)),setTip(state.customContent?.tips);else if(state.mode===`progress`&&`gotoMainMenu`in data){let args=[];data.gotoMainMenu?args.push(`menu.mainmenu`):args.push(`menu`,[`loading`]),window.globalAngularRootScope?.$broadcast(`ChangeState`,...args),window.vueEventBus?.emit(`onChangeState`,...args)}}}),events$3.on(`UpdateLoadingProgressV2`,data=>{if(!window.beamng?.ingame||!state.autoActivate&&!state.active)return;let{currentEntries,historyEntries}=data;(!currentEntries||!Array.isArray(currentEntries))&&(currentEntries=[]),(!historyEntries||!Array.isArray(historyEntries))&&(historyEntries=[]),state.currentEntries=currentEntries,state.historyEntriesDisplay=historyEntries.slice(Math.max(historyEntries.length-3,1)),state.iconState={};for(let{name,progress}of currentEntries)state.iconState[name.toLowerCase()]=progress;for(let{name}of historyEntries)state.iconState[name.toLowerCase()]=100;state.autoActivate&&(state.active=currentEntries.length>0||historyEntries.length>0)});let onFadeIn=()=>{state.fading=!1,state.mode===`progress`?(lua.core_gamestate.loadingScreenActive(),repeatTimer=setTimeout(()=>{lua.core_gamestate.loadingScreenActive()},activeRepeatTime)):state.mode===`custom`&&(lua.extensions.ui_fadeScreen.onScreenFadeStateDelayed(1),state.customPause!==-1&&(customTimer=setTimeout(()=>{lua.extensions.ui_fadeScreen.onScreenFadeStateDelayed(2)},state.customPause*1e3)))},onFadeOut=()=>{state.fading=!1,state.shown=!1,state.mode===`custom`&&lua.extensions.ui_fadeScreen.onScreenFadeStateDelayed(3),resetState(),loadNextImage()};watch(()=>state.active,(newActive,oldActive)=>{window.beamng?.ingame&&(newActive&&!oldActive?activateLoading():!newActive&&oldActive&&deactivateLoading())});let activateLoading=()=>{state.active&&(deactivateLoading.cancel(),navBlocker.allowOnly([]),nextTick(()=>{state.visible=!0,state.fading=!0,state.shown=!0}))},deactivateLoading=debounce(()=>{state.active||(clearTimers(),navBlocker.clear(),nextTick(()=>{state.visible=!1,state.fading=!0}))},100),getRandomImageNum=()=>{let rnd=~~(Math.random()*imagesAmount)+1;return rnd===lastImageNum?getRandomImageNum():(lastImageNum=rnd,rnd)},getNextImageUrl=()=>{let url;return url=state.highSeas?`images/mainmenu/unofficial_version.jpg`:`images/loading/drive/${getRandomImageNum()}.jpg`,getAssetURL(url)},loadNextImage=async()=>{let url=getNextImageUrl();state.image!==url&&(await loadImage$1(url),state.image=url)},loadImage$1=url=>new Promise((resolve$1,reject)=>{let img=new Image;img.onload=()=>resolve$1(url),img.onerror=()=>reject(url),img.src=url}),clearTimers=()=>{repeatTimer&&=(clearTimeout(repeatTimer),null),customTimer&&=(clearTimeout(customTimer),null)},initLoadingScreen=()=>bngApi.engineLua(`sailingTheHighSeas`,async ahoy=>{state.highSeas=ahoy===!0,await loadNextImage(),setTip(),lua.core_gamestate.loadingScreenActive(),window.loadingTest=active=>{events$3.emit(`LoadingScreen`,{active})}});return onMounted(()=>{linkLoadingScreenState(state),initLoadingScreen()}),onUnmounted(()=>clearTimers()),(_ctx,_cache)=>(openBlock(),createElementBlock(Fragment,null,[createVNode(Transition,{name:`loading-fade`,onAfterEnter:onFadeIn,onAfterLeave:onFadeOut},{default:withCtx(()=>[state.visible?(openBlock(),createElementBlock(`dialog`,{key:0,open:``,class:normalizeClass([`loading-screen`,`loading-screen-${state.mode}`])},[createBaseVNode(`div`,{class:`loading-background`,style:normalizeStyle({backgroundImage:state.image?`url('${state.image}')`:`none`})},null,4),state.mode===`progress`?(openBlock(),createElementBlock(`div`,_hoisted_1$286,[createBaseVNode(`div`,_hoisted_2$234,[(openBlock(),createElementBlock(Fragment,null,renderList(iconsList,iconInfo=>createBaseVNode(`div`,{key:iconInfo.id,class:`progress-icon-box`,style:normalizeStyle({backgroundPosition:`0 ${state.iconState[iconInfo.id]||0}%`})},[createVNode(unref(bngIcon_default),{type:iconInfo.icon,color:`#fff`,class:`progress-icon`},null,8,[`type`])],4)),64))]),createBaseVNode(`div`,_hoisted_3$208,[createVNode(unref(bngProgressBar_default),{class:`progress-bar`,gradient:``,"show-value-label":!1,min:0,max:100,value:progressValue.value},null,8,[`value`])]),createBaseVNode(`div`,_hoisted_4$178,toDisplayString(currentStatus.value||_ctx.$tt(`ui.common.loading`)),1),createBaseVNode(`div`,_hoisted_5$153,[(openBlock(!0),createElementBlock(Fragment,null,renderList(state.historyEntriesDisplay,(item,idx)=>(openBlock(),createElementBlock(`div`,{key:idx},toDisplayString(item.message),1))),128))])])):createCommentVNode(``,!0),state.mode===`custom`?(openBlock(),createElementBlock(`div`,{key:1,class:normalizeClass([`custom-box`,{"custom-with-tips":state.customContent?.tips}])},[createBaseVNode(`div`,_hoisted_6$132,[state.customContent&&(state.customContent.title||state.customContent.text)?(openBlock(),createElementBlock(`div`,_hoisted_7$118,[state.customContent.title?(openBlock(),createBlock(unref(bngScreenHeading_default),{key:0,preheadings:[_ctx.$tt(state.customContent.subtitle)]},{default:withCtx(()=>[createTextVNode(toDisplayString(_ctx.$tt(state.customContent.title)),1)]),_:1},8,[`preheadings`])):createCommentVNode(``,!0),state.customContent.text?(openBlock(),createElementBlock(`p`,_hoisted_8$99,[createVNode(unref(dynamicComponent_default),{"translate-id":state.customContent.text,bbcode:``,"translate-context":``},null,8,[`translate-id`])])):createCommentVNode(``,!0)])):(openBlock(),createElementBlock(`div`,_hoisted_9$89,[createVNode(unref(bngScreenHeading_default),null,{default:withCtx(()=>[createTextVNode(toDisplayString(_ctx.$tt(`ui.common.loading.short`)),1)]),_:1}),createVNode(unref(bngProgressBar_default),{class:`progress-bar`,gradient:``,"show-value-label":!1,min:0,max:100,indeterminate:``})]))]),createBaseVNode(`div`,_hoisted_10$77,[state.customContent&&state.customContent.image?(openBlock(),createElementBlock(`div`,{key:0,class:`custom-image-panel`,style:normalizeStyle({backgroundImage:`url('${state.customContent.image}')`})},null,4)):createCommentVNode(``,!0)])],2)):createCommentVNode(``,!0),state.mode===`progress`||state.customContent?.tips?(openBlock(),createElementBlock(`div`,_hoisted_11$69,[createBaseVNode(`div`,_hoisted_12$57,toDisplayString(_ctx.$tt(`ui.loadingScreen.tips`))+`:`,1),createBaseVNode(`div`,_hoisted_13$49,[createVNode(unref(dynamicComponent_default),{"translate-id":tip.value,bbcode:``},null,8,[`translate-id`])])])):createCommentVNode(``,!0)],2)):createCommentVNode(``,!0)]),_:1}),state.image?(openBlock(),createElementBlock(`div`,_hoisted_14$44,[createBaseVNode(`img`,{src:state.image,alt:``},null,8,_hoisted_15$42)])):createCommentVNode(``,!0)],64))}},LoadingScreen_default=__plugin_vue_export_helper_default(_sfc_main$323,[[`__scopeId`,`data-v-2f135df0`]]),_hoisted_1$285={class:`pause-button-wrapper`},_sfc_main$322={__name:`pauseButton`,props:{teleportTo:[String,Object]},setup(__props){let route=useRoute(),events$3=useEvents(),gameContext=useGameContextStore(),isGamePaused=ref(!1),physicsMaybePaused=ref(!1),replayActive=ref(!1),replayPaused=ref(!1);events$3.on(`physicsStateChanged`,state=>{physicsMaybePaused.value=!state}),events$3.on(`replayStateChanged`,core_replay=>{replayActive.value=core_replay.state===`playback`,replayPaused.value=replayActive.value&&core_replay.paused}),events$3.on(`simTimeAuthority.pauseStateChanged`,data=>{isGamePaused.value=data.paused});let isInMenu=computed(()=>route.name?.startsWith(`menu`)&&!gameContext.activities?.length&&sysInfo_default.gameState.value!==void 0&&sysInfo_default.gameState.value!==`loading`),isPhysicsPaused=computed(()=>physicsMaybePaused.value),isReplayPaused=computed(()=>replayActive.value&&replayPaused.value),showPauseButton=computed(()=>isInMenu.value||isPhysicsPaused.value||isReplayPaused.value),isPaused=computed(()=>isGamePaused.value||isPhysicsPaused.value||isReplayPaused.value),buttonState=computed(()=>isInMenu.value&&isPaused.value?`menu-paused`:isInMenu.value?`menu`:isPaused.value?`paused`:`default`),togglePause=()=>{Lua_default.simTimeAuthority.togglePause()};return(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$285,[(openBlock(),createBlock(Teleport,{disabled:!__props.teleportTo,to:__props.teleportTo},[withDirectives((openBlock(),createBlock(unref(bngButton_default),{class:normalizeClass([`pause-button`,buttonState.value]),accent:unref(ACCENTS).custom,"no-sound":``,onClick:togglePause,"bng-no-nav":``},{default:withCtx(()=>[createVNode(unref(bngBinding_default),{class:`pause-button-binding-bg`,action:`pause`}),createVNode(unref(bngIcon_default),{class:`pause-button-icon`,type:isPaused.value?unref(icons).pause:unref(icons).play},null,8,[`type`])]),_:1},8,[`class`,`accent`])),[[vShow,showPauseButton.value],[unref(BngTooltip_default),_ctx.$tt(`ui.inputActions.general.pause.title`),void 0,{bottom:!0}]])],8,[`disabled`,`to`]))]))}},pauseButton_default=__plugin_vue_export_helper_default(_sfc_main$322,[[`__scopeId`,`data-v-ea9a26b4`]]),UIAppStorage,setupDone;const useUIApps=()=>(setupDone||setup(),service);var setup=()=>{UIAppStorage||=window.UIAppStorage,setupDone=!!UIAppStorage},setLayout=layoutName=>{layoutName==`blank`?_broadcast(`appContainer:clear`):_broadcast(`appContainer:loadLayoutByType`,layoutName)},setVisible=state=>{_broadcast(`ShowApps`,!!state)},service={setLayout,setVisible,get currentLayout(){return UIAppStorage.currentLayout}},_broadcast=(...params)=>{window.globalAngularRootScope&&window.globalAngularRootScope.$broadcast(...params)},_sfc_main$321={};function _sfc_render$3(_ctx,_cache){return openBlock(),createElementBlock(`span`)}var NotFound_default=__plugin_vue_export_helper_default(_sfc_main$321,[[`render`,_sfc_render$3]]);function useGridSelector(backendName=`gridSelector`,defaultPath={keys:[`missions`]},defaultDetailsMode=`detail`){let currentPath=ref(defaultPath),previousPath=ref(null),groups=ref([]),filterList=ref([]),filterByProp=ref([]),commonFilters=ref([]),lockedFiltersByProp=ref([]),activeFilters=ref([]),onlyCommonFilters=ref(!0),detailsMode=ref(defaultDetailsMode),selectedItem=ref(null),selectedItemDetails=ref(null),prevSelectedItem=ref(null),previewItem=ref(null),previewItemDetails=ref(null),managementDetails=ref(null),autoFocusKey=ref(null),showScreenHeader=ref(!0),screenHeaderTitle=ref(`Grid Selector`),screenHeaderPath=ref([{text:`Menu`,gotoAngularState:`menu`}]),{events:events$3}=useBridge(),backFromDetailsCallback=null,refreshAllHandler=backendName$1=>{backendName$1===backendName$1&&(logger_default.debug(`gridSelectorRefreshAll`),loadTiles(),loadFilters(),loadManagementDetails())},refreshCurrentItemDetailsHandler=backendName$1=>{backendName$1===backendName$1&&(logger_default.debug(`gridSelectorRefreshCurrentItemDetails`),setSelectedItem(selectedItem.value))};events$3.on(`gridSelectorRefreshAll`,refreshAllHandler),events$3.on(`gridSelectorRefreshCurrentItemDetails`,refreshCurrentItemDetailsHandler);let log=(...args)=>{},displayData=ref([]),searchText$1=ref(``);async function getSearchText(){try{let data=await Lua_default.ui_gridSelector.getSearchText(backendName);return searchText$1.value=data||``,data||``}catch(error){return logger_default.error(`Failed to get search text:`,error),``}}async function setSearchText(value){try{await Lua_default.ui_gridSelector.setSearchText(backendName,value),searchText$1.value=value||``,await loadTiles(),await loadFilters(),await updateScreenHeaderData()}catch(error){logger_default.error(`Failed to set search text:`,error)}}let isInitializing=ref(!1),safeArray=arr=>Array.isArray(arr)?arr:[];async function setCurrentPath(path){currentPath.value=path,await loadTiles()}async function loadTiles(){currentPath.value;try{let data=await Lua_default.ui_gridSelector.getTiles(backendName,currentPath.value,previousPath.value!==currentPath.value);if(Lua_default.ui_gridSelector.profilerFinish(backendName,`received lua data on UI`),groups.value=safeArray(data),groups.value,!selectedItem.value&&(detailsMode.value===`advanced`||detailsMode.value===`detail`)&&previousPath.value!==currentPath.value)for(let group of groups.value)for(let tile of group.tiles)tile.isDefaultSelected&&(autoFocusKey.value=tile.key,tile.name,tile.forceAutoFocus&&backFromDetailsCallback());previousPath.value=currentPath.value,Lua_default.ui_gridSelector.profilerFinish(backendName,`loaded tiles into reactive state`)}catch(error){logger_default.error(`Failed to load tiles:`,error)}}async function loadFilters(){try{let data=await Lua_default.ui_gridSelector.getFilters(backendName);filterList.value=safeArray(data.filterList),filterByProp.value=data.filterByProp,commonFilters.value=safeArray(data.commonFilters)||[],lockedFiltersByProp.value=data.lockedFiltersByProp||[],activeFilters.value=safeArray(data.activeFilters),onlyCommonFilters.value=data.onlyCommonFilters,filterList.value,filterByProp.value,activeFilters.value,onlyCommonFilters.value}catch(error){logger_default.error(`Failed to load filters:`,error)}}async function loadManagementDetails(){try{managementDetails.value=await Lua_default.ui_gridSelector.getManagementDetails(backendName),managementDetails.value}catch(error){logger_default.error(`Failed to load management details:`,error)}}async function toggleFilter(propName,option){try{await Lua_default.ui_gridSelector.toggleFilter(backendName,propName,option),await loadFilters(),await loadTiles(),await updateScreenHeaderData()}catch(error){logger_default.error(`Failed to toggle filter:`,error)}}async function updateRangeFilter(propName,min$1,max$1){try{await Lua_default.ui_gridSelector.updateRangeFilter(backendName,propName,min$1,max$1),await loadFilters(),await loadTiles(),await updateScreenHeaderData()}catch(error){logger_default.error(`Failed to update range filter:`,error)}}async function resetRangeFilter(propName){console.log(`Resetting range filter:`,propName);try{await Lua_default.ui_gridSelector.resetRangeFilter(backendName,propName),await loadFilters(),await loadTiles(),await updateScreenHeaderData()}catch(error){logger_default.error(`Failed to reset range filter:`,error)}}async function resetSetFilter(propName){try{await Lua_default.ui_gridSelector.resetSetFilter(backendName,propName),await loadFilters(),await loadTiles(),await updateScreenHeaderData()}catch(error){logger_default.error(`Failed to reset set filter:`,error)}}async function loadDisplayData(){try{displayData.value=safeArray(await Lua_default.ui_gridSelector.getDisplayDataOptions(backendName));let searchOption=displayData.value.find(option=>option.key===`searchText`);searchOption&&(searchText$1.value=searchOption.value||``),displayData.value}catch(error){logger_default.error(`Failed to load display data:`,error)}}async function updateDisplayData(key,value){try{await Lua_default.ui_gridSelector.setDisplayDataOption(backendName,key,value),await loadDisplayData(),await loadTiles(),await updateScreenHeaderData()}catch(error){logger_default.error(`Failed to update display data:`,error)}}async function resetDisplayDataToDefaults(){try{await Lua_default.ui_gridSelector.resetDisplayDataToDefaults(backendName),await loadDisplayData(),await loadTiles(),await updateScreenHeaderData()}catch(error){logger_default.error(`Failed to reset display data to defaults:`,error)}}function setDetailsMode(mode){detailsMode.value=mode}async function setSelectedItem(item){if(!item||!item.showDetails){autoFocusKey.value=null,selectedItem.value=null,selectedItemDetails.value=null,await loadManagementDetails();return}try{item.showDetails;let details=await Lua_default.ui_gridSelector.getDetails(backendName,item.showDetails);autoFocusKey.value=item.key,selectedItem.value=item,selectedItemDetails.value=details,details?.paintData&&details?.paints&&selectedItemDetails.value?.paints&&(selectedItemDetails.value.paints.multiPaintSetups=safeArray(selectedItemDetails.value.paints.multiPaintSetups),selectedItemDetails.value.paints.factoryPaints=safeArray(selectedItemDetails.value.paints.factoryPaints)),setDetailsMode(`detail`)}catch(error){logger_default.error(`Failed to get item details:`,error),autoFocusKey.value=null,selectedItem.value=item,selectedItemDetails.value=null}}async function clearSelectedItem(){selectedItem.value=null,selectedItemDetails.value=null,await loadManagementDetails()}async function setPreviewItem(item){if(!item||!item.showDetails){previewItem.value=null,previewItemDetails.value=null;return}try{let details=await Lua_default.ui_gridSelector.getDetails(backendName,item.showDetails);previewItem.value=item,previewItemDetails.value=details,setDetailsMode(`detail`)}catch{previewItem.value=item,previewItemDetails.value=null}}function clearPreviewItem(){previewItem.value=null,previewItemDetails.value=null}let activeItem=computed(()=>selectedItem.value||previewItem.value),activeItemDetails=computed(()=>selectedItem.value?selectedItemDetails.value:previewItemDetails.value);async function executeButton(buttonId,additionalData){try{if(additionalData?.waitForLoadingScreen)window.vueEventBus?.emit(`LoadingScreen`,{active:!0}),await startLoading(async()=>{await waitForLoadingScreenFadeIn();let data=await Lua_default.ui_gridSelector.executeButton(backendName,buttonId,additionalData);data&&data.gotoPath&&setCurrentPath(data.gotoPath)});else{let data=await Lua_default.ui_gridSelector.executeButton(backendName,buttonId,additionalData);data&&data.gotoPath&&setCurrentPath(data.gotoPath)}}catch(error){logger_default.error(`Failed to execute button:`,error)}}let executeButtonHandler=(backendName$1,buttonId,additionalData)=>{backendName$1===backendName$1&&executeButton(buttonId,additionalData)};events$3.on(`gridSelectorExecuteButton`,executeButtonHandler);async function toggleFavourite(item){await Lua_default.ui_gridSelector.toggleFavourite(backendName,item.showDetails);let details=await Lua_default.ui_gridSelector.getDetails(backendName,item.showDetails);selectedItem.value=item,selectedItemDetails.value=details,await loadTiles()}function clearSearch(){setSearchText(``)}function updateSearch(newSearchText){setSearchText(newSearchText||``)}function commitSearch(){setSearchText(searchText$1.value||``)}function isFilterLocked(propName,option=null){return lockedFiltersByProp.value[propName]?option?lockedFiltersByProp.value[propName][option]!==void 0:Object.keys(lockedFiltersByProp.value[propName]).length>0:!1}async function updateScreenHeaderData(){try{let headerData=await Lua_default.ui_gridSelector.getScreenHeaderTitleAndPath(backendName,currentPath.value);screenHeaderTitle.value=headerData.title||`Grid Selector`,screenHeaderPath.value=headerData.pathSegments}catch(error){logger_default.error(`Failed to update screen header title:`,error),screenHeaderTitle.value=`Grid Selector`,screenHeaderPath.value=[{text:`Menu`,gotoAngularState:`menu`}]}}function isFilterOptionLocked(propName,option){return isFilterLocked(propName,option)}function isRangeFilterLocked(propName){return isFilterLocked(propName)}watch(currentPath,()=>{clearSelectedItem(),clearPreviewItem(),updateScreenHeaderData()}),watch([filterByProp,activeFilters],()=>{clearSelectedItem(),clearPreviewItem(),updateScreenHeaderData()}),watch(displayData,()=>{updateScreenHeaderData()},{deep:!0});function notifyUIReady(tag){Lua_default.ui_gridSelector.profilerFinish(backendName,tag)}function setOnBackFromDetailsCallback(callback){backFromDetailsCallback=callback}async function initialize(){if(!isInitializing.value)try{isInitializing.value=!0,await Promise.all([loadFilters(),loadDisplayData(),loadManagementDetails(),getSearchText()])}catch(error){logger_default.error(`Failed to initialize GridSelector composable:`,error)}finally{isInitializing.value=!1}}return onUnmounted(()=>{logger_default.debug(`GridSelector composable unmounting`),events$3.off(`gridSelectorRefreshAll`,refreshAllHandler),events$3.off(`gridSelectorRefreshCurrentItemDetails`,refreshCurrentItemDetailsHandler),events$3.off(`gridSelectorExecuteButton`,executeButtonHandler)}),{groups,filterList,filterByProp,lockedFiltersByProp,commonFilters,activeFilters,onlyCommonFilters,displayData,currentPath,detailsMode,selectedItem,selectedItemDetails,prevSelectedItem,previewItem,previewItemDetails,activeItem,activeItemDetails,managementDetails,isInitializing,searchText:searchText$1,getSearchText,setSearchText,autoFocusKey,showScreenHeader,screenHeaderTitle,screenHeaderPath,initialize,setCurrentPath,loadTiles,loadFilters,loadManagementDetails,toggleFilter,updateRangeFilter,resetRangeFilter,resetSetFilter,loadDisplayData,updateDisplayData,resetDisplayDataToDefaults,setDetailsMode,setSelectedItem,clearSelectedItem,setPreviewItem,clearPreviewItem,executeButton,notifyUIReady,isFilterLocked,isFilterOptionLocked,isRangeFilterLocked,toggleFavourite,clearSearch,updateSearch,commitSearch,updateScreenHeaderData,exploreFolder:function(path){Lua_default.ui_gridSelector.exploreFolder(backendName,path)},goToMod:function(modId){Lua_default.ui_gridSelector.goToMod(backendName,modId)},setOnBackFromDetailsCallback}}var _hoisted_1$284=[`bng-scoped-nav-autofocus`],_hoisted_2$233={class:`image-container`},_hoisted_3$207={key:0,class:`sub-element-count-badge`},_hoisted_4$177={class:`item-label`},_hoisted_5$152={class:`item-name`},_hoisted_6$131={class:`icons-container`},_hoisted_7$117=[`src`],_hoisted_8$98={key:0,class:`sub-element-count-badge`},_hoisted_9$88={key:1},sizes={tiny:{width:7.5,margin:.5,fontSize:.8},small:{width:9.5,margin:.5,fontSize:1},medium:{width:12,margin:.5,fontSize:1},large:{width:16,margin:.5,fontSize:1},huge:{width:20,margin:.5,fontSize:1.5},list:{width:22,height:3,margin:.5,fontSize:.9}},thumbAspectRatio=16/9.5,captionHeightEm=2,getSizeCalc=displaySize=>ctx=>{let size$3=sizes[displaySize]||sizes.medium;if(displaySize===`list`)return{width:size$3.width,height:size$3.height,margin:size$3.margin};let height$1=size$3.width/thumbAspectRatio+size$3.fontSize*captionHeightEm-size$3.margin*2;return{width:size$3.width,height:height$1,margin:size$3.margin}},__default__$6={getSizeCalc},_sfc_main$320=Object.assign(__default__$6,{__name:`Tile`,props:{tile:{type:Object,required:!0},isFavourite:Boolean,isConfig:Boolean,displaySize:String,tileImagesTopAligned:{type:Boolean,default:!1}},emits:[`focus`,`blur`,`click`,`dblclick`],setup(__props,{expose:__expose,emit:__emit}){let{showIfController}=storeToRefs(controls_default()),props=__props,gridSelectionState=inject(`gridSelectionState`,null),state=computed(()=>{let res={selected:!1,dimmed:!1,isAutoFocused:!1};return gridSelectionState&&gridSelectionState.value&&(res.selected=gridSelectionState.value.inDetails&&gridSelectionState.value.activeItemKey===props.tile.key,res.dimmed=showIfController.value&&gridSelectionState.value.inDetails&&gridSelectionState.value.activeItemKey!==props.tile.key,res.isAutoFocused=gridSelectionState.value.autoFocusKey===props.tile.key),res}),emit$1=__emit,elTile=ref(null);__expose({getElement:()=>elTile.value});let isListItem=computed(()=>props.displaySize===`list`);function onClick(){emit$1(`click`)}function onFocus(){emit$1(`focus`)}function onBlur(){emit$1(`blur`)}return(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,{class:normalizeClass([`tile-wrapper`,`tile-size-${__props.displaySize}`]),style:normalizeStyle({"--tile-font-size":sizes[__props.displaySize].fontSize+`em`})},[_cache[0]||=createBaseVNode(`div`,{class:`tile-bg`},null,-1),withDirectives((openBlock(),createElementBlock(`div`,{ref_key:`elTile`,ref:elTile,"bng-scoped-nav-autofocus":state.value.isAutoFocused,class:normalizeClass({tile:!0,selected:state.value.selected,dimmed:state.value.dimmed,auxiliary:__props.tile.isAuxiliary,"is-career-only":__props.tile.isCareerOnly}),onClick:withModifiers(onClick,[`stop`]),onFocus,onBlur,"bng-nav-item":``},[createBaseVNode(`div`,_hoisted_2$233,[createVNode(unref(bngImage_default),{class:normalizeClass([`item-image`,{"top-aligned":__props.tileImagesTopAligned}]),src:__props.tile.preview},null,8,[`class`,`src`]),isListItem.value?createCommentVNode(``,!0):(openBlock(),createElementBlock(Fragment,{key:0},[!__props.isConfig&&__props.tile.subElementCount>=1?(openBlock(),createElementBlock(`div`,_hoisted_3$207,toDisplayString(__props.tile.subElementCount),1)):createCommentVNode(``,!0),__props.isFavourite||__props.tile.showFavouriteIconPercent>=1?(openBlock(),createBlock(unref(bngIcon_default),{key:1,class:`favorite-indicator`,type:`star`})):createCommentVNode(``,!0)],64))]),createBaseVNode(`div`,_hoisted_4$177,[createBaseVNode(`span`,_hoisted_5$152,toDisplayString(__props.tile.name),1),createBaseVNode(`div`,_hoisted_6$131,[__props.tile.sourceIcons?(openBlock(!0),createElementBlock(Fragment,{key:0},renderList(__props.tile.sourceIcons,sourceIcon=>(openBlock(),createElementBlock(Fragment,{key:sourceIcon},[sourceIcon.icon?(openBlock(),createBlock(unref(bngIcon_default),{key:0,type:sourceIcon.icon,class:`source-icon`,color:`var(--bng-cool-gray-100)`},null,8,[`type`])):createCommentVNode(``,!0),sourceIcon.svg?(openBlock(),createElementBlock(`img`,{key:1,class:`svg-icon`,src:sourceIcon.svg,alt:``},null,8,_hoisted_7$117)):createCommentVNode(``,!0)],64))),128)):createCommentVNode(``,!0),isListItem.value&&__props.tile.showFavouriteIconPercent>0?(openBlock(),createBlock(unref(bngIcon_default),{key:1,class:`favorite-indicator`,type:__props.tile.showFavouriteIconPercent>=1?`star`:`starSecondary`},null,8,[`type`])):createCommentVNode(``,!0)]),isListItem.value&&!__props.isConfig&&__props.tile.subElementCount>=1?(openBlock(),createElementBlock(`span`,_hoisted_8$98,toDisplayString(__props.tile.subElementCount),1)):isListItem.value?(openBlock(),createElementBlock(`span`,_hoisted_9$88)):createCommentVNode(``,!0)])],42,_hoisted_1$284)),[[unref(BngOnUiNav_default),void 0,`ok`,{focusRequired:!0,asMouse:!0,bubble:!0}],[unref(BngSoundClass_default),`bng_click_hover_generic`],[unref(BngDoubleClick_default),__props.tile.doubleClickDetails?()=>emit$1(`dblclick`):null,__props.tile.doubleClickMode]])],6))}}),Tile_default=__plugin_vue_export_helper_default(_sfc_main$320,[[`__scopeId`,`data-v-51fd3377`]]),_hoisted_1$283={class:`group-header`,"bng-list-title":``},_sfc_main$319={__name:`GroupHeader`,props:{label:{type:String,required:!0}},setup(__props){return(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$283,[createVNode(bngCardHeading_default,{class:`header-label`},{default:withCtx(()=>[createTextVNode(toDisplayString(__props.label),1)]),_:1}),_cache[0]||=createBaseVNode(`div`,{class:`header-line`},null,-1)]))}},GroupHeader_default=__plugin_vue_export_helper_default(_sfc_main$319,[[`__scopeId`,`data-v-28596ef8`]]),_sfc_main$318={__name:`Grid`,props:{autoFocusKey:{type:String,default:null},activeItem:{type:Object,default:null},groups:{type:Array,required:!0},isConfig:{type:Boolean,default:!1},displaySize:{type:String,default:`medium`,validator:value=>[`tiny`,`small`,`medium`,`large`,`huge`,`list`].includes(value)},inDetails:{type:Boolean,default:!1},backendName:{type:String,default:`gridSelector`},tileImagesTopAligned:{type:Boolean,default:!1},doubleClickOverride:{type:Function,default:null}},emits:[`select-item`,`deselect-item`,`focus-item`],setup(__props,{emit:__emit}){let{showIfController}=storeToRefs(controls_default()),props=__props,emit$1=__emit,gridListRef=ref(),containerWidth=ref(0),baseFontSize=ref(16),tileSizeCalc=ctx=>Tile_default.getSizeCalc(props.displaySize)(ctx),maxTilesPerRow=computed(()=>{if(!containerWidth.value)return 1/0;let size$3=Tile_default.getSizeCalc(props.displaySize)({}),tileWidthPx=(size$3.width+size$3.margin)*baseFontSize.value;return(Math.floor(containerWidth.value/tileWidthPx)||1)*(props.displaySize===`list`?2:1)}),limitedGroups=computed(()=>props.groups.map(group=>({...group,tiles:group.isRecentGroup?group.tiles.slice(0,maxTilesPerRow.value):group.tiles}))),updateContainerWidth=()=>{gridListRef.value?.$el&&(containerWidth.value=gridListRef.value.$el.clientWidth,baseFontSize.value=parseFloat(getComputedStyle(document.documentElement).fontSize)||16)},resizeObserver;onMounted(()=>{updateContainerWidth(),gridListRef.value?.$el&&(resizeObserver=new ResizeObserver(debounce(updateContainerWidth,100)),resizeObserver.observe(gridListRef.value.$el))}),onUnmounted(()=>{resizeObserver&&resizeObserver.disconnect()}),provide(`gridSelectionState`,computed(()=>({inDetails:props.inDetails,activeItemKey:props.activeItem?.key||null,autoFocusKey:props.autoFocusKey})));let focusItem=tile=>{props.inDetails||(showIfController.value&&preselectItem(tile),emit$1(`focus-item`,tile))},selectItem=tile=>{preselectItem.cancel(),emit$1(`select-item`,tile)},preselectItem=debounce(tile=>emit$1(`select-item`,tile,!1),200),handleDoubleClick=async item=>{if(console.log(`handleDoubleClick`,item),item.doubleClickDetails)try{props.doubleClickOverride?props.doubleClickOverride(item):await Lua_default.ui_gridSelector.executeDoubleClick(props.backendName,item.doubleClickDetails)}catch(error){console.error(`Failed to execute double click:`,error)}};return(_ctx,_cache)=>(openBlock(),createBlock(unref(bngList_default),{ref_key:`gridListRef`,ref:gridListRef,class:`grid-list`,layout:unref(LIST_LAYOUTS).TILES,"no-background":``,big:``,immediate:``,"keep-alive":500,"title-width":20,"title-height":1.5,"title-margin":.5,"tile-size-calc":tileSizeCalc},{default:withCtx(()=>[(openBlock(!0),createElementBlock(Fragment,null,renderList(limitedGroups.value,group=>(openBlock(),createElementBlock(Fragment,{key:group.label},[group.label?(openBlock(),createBlock(GroupHeader_default,{key:0,label:group.label,"bng-list-title":``},null,8,[`label`])):createCommentVNode(``,!0),(openBlock(!0),createElementBlock(Fragment,null,renderList(group.tiles,tile=>(openBlock(),createBlock(Tile_default,{key:tile.key,tile,"is-config":__props.isConfig,"display-size":__props.displaySize,"is-favourite":group.label===`Favourites`,"tile-images-top-aligned":__props.tileImagesTopAligned,onFocus:$event=>focusItem(tile),onClick:$event=>selectItem(tile),onDblclick:$event=>handleDoubleClick(tile)},null,8,[`tile`,`is-config`,`display-size`,`is-favourite`,`tile-images-top-aligned`,`onFocus`,`onClick`,`onDblclick`]))),128))],64))),128))]),_:1},8,[`layout`]))}},Grid_default$1=__plugin_vue_export_helper_default(_sfc_main$318,[[`__scopeId`,`data-v-efa73a51`]]),_hoisted_1$282={class:`display-controls-container`},_hoisted_2$232={class:`control-group-label`},_hoisted_3$206={key:0,class:`reset-button-container`},_sfc_main$317={__name:`DisplayControls`,props:{displayData:{type:Array,required:!0},detailsMode:{type:String,required:!0},updateDisplayData:{type:Function,required:!0},resetDisplayDataToDefaults:{type:Function,required:!0},setDetailsMode:{type:Function,required:!0}},emits:[`focus-item`],setup(__props,{emit:__emit}){let props=__props,emit$1=__emit,booleanToStringByKey=computed(()=>{let valuesByKey={};for(let option of props.displayData)if(option.type===`checkbox`){valuesByKey[option.key]={};for(let checkboxOption of option.options)valuesByKey[option.key][checkboxOption.value]=checkboxOption.label||(checkboxOption.value?`Yes`:`No`)}return valuesByKey}),controls$1=computed(()=>props.displayData.filter(x=>x.showInModes?.[props.detailsMode]).map(x=>({...x,checkboxLabel:x.type===`checkbox`?booleanToStringByKey.value[x.key]?.[x.value]:void 0}))),onOptionChanged=(key,newValue)=>{props.updateDisplayData(key,newValue),emit$1(`focus-item`,key)},resetToDefaults=()=>{props.resetDisplayDataToDefaults()};return(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$282,[createBaseVNode(`div`,{class:normalizeClass([`display-controls`,{"display-controls-list":__props.detailsMode===`displayControls`||__props.detailsMode===`default`}])},[(openBlock(!0),createElementBlock(Fragment,null,renderList(controls$1.value,option=>(openBlock(),createElementBlock(`div`,{key:option.key,class:normalizeClass([`control-group`,{"force-full-width":__props.detailsMode===`default`}])},[createBaseVNode(`div`,_hoisted_2$232,toDisplayString(option.label),1),createVNode(bngTooltip_default,{text:option.description||`No description available`,position:`top`},{default:withCtx(()=>[option.type===`dropdown`?(openBlock(),createBlock(unref(bngSmartSelect_default),{key:0,modelValue:option.value,items:option.options||[],"onUpdate:modelValue":newValue=>onOptionChanged(option.key,newValue),threshold:8},null,8,[`modelValue`,`items`,`onUpdate:modelValue`])):option.type===`checkbox`?(openBlock(),createBlock(unref(bngSwitch_default),{key:1,class:normalizeClass([`full-width-checkbox`,{active:option.value}]),modelValue:option.value,"onUpdate:modelValue":newValue=>onOptionChanged(option.key,newValue),labelBefore:``,alwaysTransparent:``},{default:withCtx(()=>[createTextVNode(toDisplayString(option.checkboxLabel),1)]),_:2},1032,[`class`,`modelValue`,`onUpdate:modelValue`])):option.type===`number`?(openBlock(),createBlock(unref(bngInputNew_default),{key:2,modelValue:option.value,min:option.min,max:option.max,showExternalButton:!1,type:`number`,"onUpdate:modelValue":newValue=>onOptionChanged(option.key,newValue)},null,8,[`modelValue`,`min`,`max`,`onUpdate:modelValue`])):createCommentVNode(``,!0)]),_:2},1032,[`text`])],2))),128))],2),__props.detailsMode===`displayControls`?(openBlock(),createElementBlock(`div`,_hoisted_3$206,[createVNode(unref(bngButton_default),{onClick:resetToDefaults,accent:`attention`,iconLeft:`trashBin1`,class:`reset-button`},{default:withCtx(()=>[..._cache[0]||=[createTextVNode(` Reset to Defaults `,-1)]]),_:1})])):createCommentVNode(``,!0)]))}},DisplayControls_default=__plugin_vue_export_helper_default(_sfc_main$317,[[`__scopeId`,`data-v-863e411a`]]),_sfc_main$316={__name:`SearchBar`,props:{searchText:{type:String,required:!0},setSearchText:{type:Function,required:!0},placeholder:{type:String,default:`Search...`},fullWidth:{type:Boolean,default:!1},showClearAllButton:{type:Boolean,default:!1}},emits:[`focus-item`,`clear-all`],setup(__props,{emit:__emit}){let props=__props,emit$1=__emit,clearSearch=()=>{props.setSearchText(``),emit$1(`focus-item`,`search`)},commitSearch=()=>{},onSearchChanged=value=>{props.setSearchText(value),emit$1(`focus-item`,`search`)};return(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,{class:normalizeClass([`search-container`,{"full-width":__props.fullWidth}])},[createVNode(unref(bngInput_default),{class:`search-input`,modelValue:__props.searchText,placeholder:__props.placeholder,onValueChanged:onSearchChanged,onKeydown:withKeys(commitSearch,[`enter`]),onBlur:commitSearch,onFocus:_cache[0]||=$event=>emit$1(`focus-item`,`search`)},null,8,[`modelValue`,`placeholder`]),createBaseVNode(`div`,{class:normalizeClass([`search-icon-container`,{active:__props.searchText}]),onClick:clearSearch},[createVNode(unref(bngIcon_default),{type:unref(icons).search,class:`search-icon show-unhovered`},null,8,[`type`]),createVNode(unref(bngIcon_default),{type:unref(icons).trashBin2,class:`search-icon show-hovered`},null,8,[`type`])],2)],2))}},SearchBar_default=__plugin_vue_export_helper_default(_sfc_main$316,[[`__scopeId`,`data-v-67aff9c0`]]),_hoisted_1$281={class:`filters`},_hoisted_2$231={key:0,class:`search-section`},_hoisted_3$205={key:1,class:`filter-options-grid`},_hoisted_4$176={class:`option-label`},_hoisted_5$151={class:`option-icon`},_hoisted_6$130={key:2,class:`filters-container`},_hoisted_7$116={class:`filter-container`,navigable:``,tabindex:`0`},_hoisted_8$97={class:`filter-content`},_hoisted_9$87={key:0,class:`filter-options`},_hoisted_10$76={class:`filter-options-grid`},_hoisted_11$68={class:`option-label`},_hoisted_12$56={class:`option-icon`},_hoisted_13$48={key:1,class:`filter-options`},_hoisted_14$43={class:`range-bar-container`},_hoisted_15$41={class:`range-bar`},_hoisted_16$39={class:`range-inputs`},_hoisted_17$32={class:`range-input-group`},_hoisted_18$29={class:`range-input-group`},_sfc_main$315={__name:`DetailedFilters`,props:{filterList:{type:Array,required:!0},filterByProp:{type:Object,required:!0},searchText:{type:String,default:``},commonFilters:{type:Array,default:()=>[]},detailsMode:{type:String,required:!0},onlyCommonFilters:{type:Boolean,default:!0},isFilterLocked:{type:Function,required:!0},isFilterOptionLocked:{type:Function,required:!0},isRangeFilterLocked:{type:Function,required:!0},toggleFilter:{type:Function,required:!0},updateRangeFilter:{type:Function,required:!0},resetRangeFilter:{type:Function,required:!0},setSearchText:{type:Function,required:!0},setDetailsMode:{type:Function,required:!0}},emits:[`focus-item`],setup(__props,{emit:__emit}){let props=__props,emit$1=__emit,expandedAccordions=ref({}),pendingRangeUpdates=ref({}),debouncedUpdateFunctions=ref({}),getDebouncedUpdate=propName=>(debouncedUpdateFunctions.value[propName]||(debouncedUpdateFunctions.value[propName]=debounce(()=>{if(pendingRangeUpdates.value[propName]){let{min:min$1,max:max$1}=pendingRangeUpdates.value[propName];props.updateRangeFilter(propName,min$1,max$1),delete pendingRangeUpdates.value[propName]}},300)),debouncedUpdateFunctions.value[propName]);onUnmounted(()=>{Object.values(debouncedUpdateFunctions.value).forEach(debouncedFn=>{debouncedFn&&debouncedFn.cancel&&debouncedFn.cancel()}),debouncedUpdateFunctions.value={},pendingRangeUpdates.value={}});let formatFilterName=key=>key,getFilterOptionClass=(propName,option)=>{let filter=props.filterList.find(f=>f.propName===propName);if(!filter||!filter.options)return``;let allEnabled=filter.options.every(opt=>props.filterByProp[propName]?.[opt]===!0),currentOptionEnabled=props.filterByProp[propName]?.[option]===!0;return allEnabled?`filter-neutral`:currentOptionEnabled?`filter-active`:`filter-inactive`},hasActiveFilters=propName=>{if(!props.filterList)return!1;let filter=props.filterList.find(f=>f.propName===propName);if(!filter)return!1;if(filter.type===`range`){let filterData=props.filterByProp[propName];if(!filterData)return!1;let currentMin=filterData.min,currentMax=filterData.max,defaultMin=filter.min,defaultMax=filter.max;return currentMin>defaultMin||currentMaxprops.filterByProp[propName]?.[option]===!1)},toggleFilter=(propName,option,event)=>{if(props.isFilterOptionLocked(propName,option)){console.log(`Cannot toggle locked filter:`,propName,option);return}event&&(event.preventDefault(),event.stopPropagation()),emit$1(`focus-item`,`filters`),props.toggleFilter(propName,option)},onRangeFilterChanged=(propName,newValue,field)=>{if(props.isRangeFilterLocked(propName)){console.log(`Cannot update locked range filter:`,propName);return}let filter=props.filterList.find(f=>f.propName===propName);if(!filter||filter.type!==`range`)return;let filterData=props.filterByProp[propName];if(!filterData)return;let currentPending=pendingRangeUpdates.value[propName],min$1=currentPending?currentPending.min:filterData.min,max$1=currentPending?currentPending.max:filterData.max;field===`min`?min$1=newValue:field===`max`&&(max$1=newValue),min$1=Math.max(filter.min,Math.min(filter.max,min$1)),max$1=Math.max(filter.min,Math.min(filter.max,max$1)),min$1>max$1&&([min$1,max$1]=[max$1,min$1]),pendingRangeUpdates.value[propName]={min:min$1,max:max$1},getDebouncedUpdate(propName)(),emit$1(`focus-item`,propName)},isFilterActive=filter=>hasActiveFilters(filter.propName),getRangeBarStyle=propName=>{let filter=props.filterList.find(f=>f.propName===propName);if(!filter||filter.type!==`range`)return{};let filterData=props.filterByProp[propName];if(!filterData)return{};let currentMin=filterData.min,currentMax=filterData.max,totalRange=filter.max-filter.min,leftPosition=(currentMin-filter.min)/totalRange*100,width$1=(currentMax-currentMin)/totalRange*100;return{left:`${leftPosition}%`,width:`${width$1}%`,backgroundColor:`var(--bng-orange-500)`}};return onMounted(()=>{props.filterList&&props.filterList.forEach(filter=>{hasActiveFilters(filter.propName)&&(expandedAccordions.value[filter.propName]=!0)})}),(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$281,[__props.detailsMode===`filter`?(openBlock(),createElementBlock(`div`,_hoisted_2$231,[createVNode(SearchBar_default,{searchText:__props.searchText,setSearchText:__props.setSearchText,placeholder:`Search items...`,"full-width":!0,onFocusItem:_cache[0]||=$event=>emit$1(`focus-item`,$event)},null,8,[`searchText`,`setSearchText`])])):createCommentVNode(``,!0),__props.detailsMode===`filter`?createCommentVNode(``,!0):(openBlock(),createElementBlock(`div`,_hoisted_3$205,[(openBlock(!0),createElementBlock(Fragment,null,renderList(__props.commonFilters,(filter,index)=>(openBlock(),createBlock(unref(bngPill_default),{key:index,class:normalizeClass([[getFilterOptionClass(filter[0],filter[1]),{"filter-locked":props.isFilterOptionLocked(filter[0],filter[1])}],`filter-option-chip`]),style:normalizeStyle({cursor:props.isFilterOptionLocked(filter[0],filter[1])?`not-allowed`:`pointer`}),"bng-nav-item":``,onClick:$event=>toggleFilter(filter[0],filter[1])},{default:withCtx(()=>[createBaseVNode(`span`,_hoisted_4$176,toDisplayString(filter[1]),1),createBaseVNode(`span`,_hoisted_5$151,[__props.filterByProp&&__props.filterByProp[filter[0]]&&__props.filterByProp[filter[0]][filter[1]]?(openBlock(),createBlock(unref(bngIcon_default),{key:0,type:unref(icons).checkmark},null,8,[`type`])):(openBlock(),createBlock(unref(bngIcon_default),{key:1,type:unref(icons).xmark},null,8,[`type`])),props.isFilterOptionLocked(filter[0],filter[1])?(openBlock(),createBlock(unref(bngIcon_default),{key:2,type:unref(icons).lockClosed,class:`lock-icon`},null,8,[`type`])):createCommentVNode(``,!0)])]),_:2},1032,[`class`,`style`,`onClick`]))),128))])),__props.detailsMode===`filter`?(openBlock(),createElementBlock(`div`,_hoisted_6$130,[createVNode(unref(accordion_default),{class:`filters-accordion`},{default:withCtx(()=>[(openBlock(!0),createElementBlock(Fragment,null,renderList(__props.filterList,filter=>(openBlock(),createElementBlock(`div`,{key:filter.propName,class:`filter-wrapper`},[createVNode(unref(accordionItem_default),{navigable:``,static:!filter.options||filter.options.length===0,"arrow-big":``,"expand-hint-inline":``,expanded:expandedAccordions.value[filter.propName],class:normalizeClass({"has-active-filters":isFilterActive(filter)}),onFocus:$event=>emit$1(`focus-item`,filter.propName)},{caption:withCtx(()=>[createBaseVNode(`div`,_hoisted_7$116,[createBaseVNode(`div`,_hoisted_8$97,toDisplayString(formatFilterName(filter.propName)),1)])]),default:withCtx(()=>[filter.type===`set`&&filter.options?(openBlock(),createElementBlock(`div`,_hoisted_9$87,[createBaseVNode(`div`,_hoisted_10$76,[(openBlock(!0),createElementBlock(Fragment,null,renderList(filter.options,(option,index)=>(openBlock(),createBlock(unref(bngPill_default),{key:index,class:normalizeClass([[getFilterOptionClass(filter.propName,option),{"filter-locked":props.isFilterOptionLocked(filter.propName,option)}],`filter-option-chip`]),style:normalizeStyle({cursor:props.isFilterOptionLocked(filter.propName,option)?`not-allowed`:`pointer`}),onClick:$event=>toggleFilter(filter.propName,option)},{default:withCtx(()=>[createBaseVNode(`span`,_hoisted_11$68,toDisplayString(option),1),createBaseVNode(`span`,_hoisted_12$56,[__props.filterByProp[filter.propName][option]?(openBlock(),createBlock(unref(bngIcon_default),{key:0,type:unref(icons).checkmark},null,8,[`type`])):(openBlock(),createBlock(unref(bngIcon_default),{key:1,type:unref(icons).abandon},null,8,[`type`])),props.isFilterOptionLocked(filter.propName,option)?(openBlock(),createBlock(unref(bngIcon_default),{key:2,type:unref(icons).lockClosed,class:`lock-icon`},null,8,[`type`])):createCommentVNode(``,!0)])]),_:2},1032,[`class`,`style`,`onClick`]))),128))])])):createCommentVNode(``,!0),filter.type===`range`?(openBlock(),createElementBlock(`div`,_hoisted_13$48,[createBaseVNode(`div`,_hoisted_14$43,[createBaseVNode(`div`,_hoisted_15$41,[createBaseVNode(`div`,{class:`range-selection`,style:normalizeStyle(getRangeBarStyle(filter.propName))},null,4)])]),createBaseVNode(`div`,_hoisted_16$39,[createBaseVNode(`div`,_hoisted_17$32,[_cache[1]||=createBaseVNode(`label`,{class:`range-label`},`Min:`,-1),(openBlock(),createBlock(unref(bngInput_default),{key:filter.propName+`min`,modelValue:__props.filterByProp[filter.propName].min,type:`number`,min:filter.min,max:filter.max,step:filter.step||1,disabled:props.isRangeFilterLocked(filter.propName),onValueChanged:val=>onRangeFilterChanged(filter.propName,val,`min`)},null,8,[`modelValue`,`min`,`max`,`step`,`disabled`,`onValueChanged`]))]),createBaseVNode(`div`,_hoisted_18$29,[_cache[2]||=createBaseVNode(`label`,{class:`range-label`},`Max:`,-1),(openBlock(),createBlock(unref(bngInput_default),{key:filter.propName+`max`,modelValue:__props.filterByProp[filter.propName].max,type:`number`,min:filter.min,max:filter.max,step:filter.step||1,disabled:props.isRangeFilterLocked(filter.propName),onValueChanged:val=>onRangeFilterChanged(filter.propName,val,`max`)},null,8,[`modelValue`,`min`,`max`,`step`,`disabled`,`onValueChanged`]))])])])):createCommentVNode(``,!0)]),_:2},1032,[`static`,`expanded`,`class`,`onFocus`])]))),128))]),_:1})])):createCommentVNode(``,!0)]))}},DetailedFilters_default=__plugin_vue_export_helper_default(_sfc_main$315,[[`__scopeId`,`data-v-a4758924`]]),_hoisted_1$280={key:1},_hoisted_2$230={key:1},_hoisted_3$204={key:1},_hoisted_4$175={key:1},_sfc_main$314={__name:`HeaderButtons`,props:{canSwitchDetails:{type:Boolean,default:!1},hiddenTabs:{type:Array,default:()=>[]},detailsMode:{type:String,required:!0},slim:{type:Boolean,default:!1}},emits:[`switch-details-mode`],setup(__props){return(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,{class:normalizeClass([`header-buttons`,{slim:__props.slim}])},[withDirectives(createVNode(unref(bngBinding_default),{class:`header-buttons-binding`,"ui-event":`context`,controller:``,"track-ignore":``},null,512),[[vShow,__props.canSwitchDetails]]),__props.hiddenTabs.includes(`detail`)?createCommentVNode(``,!0):withDirectives((openBlock(),createBlock(unref(bngButton_default),{key:0,class:normalizeClass([`header-button`,{selected:__props.detailsMode===`detail`}]),accent:unref(ACCENTS).text,onClick:_cache[0]||=$event=>_ctx.$emit(`switch-details-mode`,`detail`)},{default:withCtx(()=>[__props.slim?(openBlock(),createBlock(unref(bngIcon_default),{key:0,type:unref(icons).info},null,8,[`type`])):(openBlock(),createElementBlock(`span`,_hoisted_1$280,`Details`))]),_:1},8,[`class`,`accent`])),[[unref(BngTooltip_default),`Details`,`top`]]),__props.hiddenTabs.includes(`advanced`)?createCommentVNode(``,!0):withDirectives((openBlock(),createBlock(unref(bngButton_default),{key:1,class:normalizeClass([`header-button`,{selected:__props.detailsMode===`advanced`}]),accent:unref(ACCENTS).text,onClick:_cache[1]||=$event=>_ctx.$emit(`switch-details-mode`,`advanced`)},{default:withCtx(()=>[__props.slim?(openBlock(),createBlock(unref(bngIcon_default),{key:0,type:unref(icons).laneProperties},null,8,[`type`])):(openBlock(),createElementBlock(`span`,_hoisted_2$230,`Advanced`))]),_:1},8,[`class`,`accent`])),[[unref(BngTooltip_default),`Advanced`,`top`]]),__props.hiddenTabs.includes(`filter`)?createCommentVNode(``,!0):withDirectives((openBlock(),createBlock(unref(bngButton_default),{key:2,class:normalizeClass([`header-button`,{selected:__props.detailsMode===`filter`}]),accent:unref(ACCENTS).text,onClick:_cache[2]||=$event=>_ctx.$emit(`switch-details-mode`,`filter`)},{default:withCtx(()=>[__props.slim?(openBlock(),createBlock(unref(bngIcon_default),{key:0,type:unref(icons).filter},null,8,[`type`])):(openBlock(),createElementBlock(`span`,_hoisted_3$204,`Filters`))]),_:1},8,[`class`,`accent`])),[[unref(BngTooltip_default),`Filters`,`top`]]),__props.hiddenTabs.includes(`displayControls`)?createCommentVNode(``,!0):withDirectives((openBlock(),createBlock(unref(bngButton_default),{key:3,class:normalizeClass([`header-button`,{selected:__props.detailsMode===`displayControls`}]),accent:unref(ACCENTS).text,onClick:_cache[3]||=$event=>_ctx.$emit(`switch-details-mode`,`displayControls`)},{default:withCtx(()=>[__props.slim?(openBlock(),createBlock(unref(bngIcon_default),{key:0,type:unref(icons).adjust},null,8,[`type`])):(openBlock(),createElementBlock(`span`,_hoisted_4$175,`Display`))]),_:1},8,[`class`,`accent`])),[[unref(BngTooltip_default),`Display`,`top`]])],2))}},HeaderButtons_default=__plugin_vue_export_helper_default(_sfc_main$314,[[`__scopeId`,`data-v-157cdc63`]]),_sfc_main$313={__name:`Slideshow`,props:{images:Array,transition:Boolean,delay:{type:Number,default:1e4},parent:Object,shuffle:Boolean},setup(__props,{expose:__expose}){useCssVars(_ctx=>({v095d52f4:imgPrev.value,v095f8174:imgNext.value}));let props=__props,anim=ref(!1),imgPrev=ref(``),imgNext=ref(``),imgIndex=ref(-1),sequence=[],sequenceIndex=-1,tmrMain,tmrAnim,wImages,wParent;__expose({imgIndex,nextImage,carousel:{showNext:nextImage}}),onUnmounted(stopTimers);function stopTimers(){tmrMain&&=(clearTimeout(tmrMain),null),tmrAnim&&=(clearTimeout(tmrAnim),null)}watch(()=>props.parent,parent=>{wImages&&=(wImages(),null),wParent&&=(wParent(),null),parent?wParent=watch([()=>props.images,()=>parent.imgIndex],([images,index])=>{images&&(imgIndex.value=index,images.length>0&&nextTick(nextImage))},{immediate:!0}):wImages=watch([()=>props.images,()=>props.shuffle],([images,shuffle])=>{images&&(imgIndex.value=-1,images.length>0&&(shuffle&&(sequenceIndex=-1,sequence=Array.from(images).map((_,i)=>i).sort(()=>Math.random()-.5)),nextTick(nextImage)))},{immediate:!0})},{immediate:!0});function nextImage(){stopTimers(),props.parent||(props.shuffle&&sequence.length>0?(sequenceIndex=++sequenceIndex%props.images.length,imgIndex.value=sequence[sequenceIndex]):imgIndex.value=++imgIndex.value%props.images.length);let img=`url("${getAssetURL(props.images[imgIndex.value])}")`;props.transition?(imgNext.value=img,anim.value=!0,tmrAnim=setTimeout(()=>{tmrAnim=null,anim.value=!1,imgPrev.value=imgNext.value,imgNext.value=``},1e3)):imgPrev.value=img,!props.parent&&props.images.length>1&&(tmrMain=setTimeout(nextImage,props.delay))}return(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,{class:normalizeClass({anim:anim.value})},null,2))}},Slideshow_default=__plugin_vue_export_helper_default(_sfc_main$313,[[`__scopeId`,`data-v-f788946d`]]),_hoisted_1$279={key:0,class:`blur-wrap`},_sfc_main$312={__name:`BlurBackground`,setup(__props){let parentCarousel=inject(`mainBackground`),backgroundsBlur=inject(`mainBackgroundBlur`),bgRequired=sysInfo_default.mainMenuBackgroundRequired;return(_ctx,_cache)=>unref(bgRequired)?(openBlock(),createElementBlock(`div`,_hoisted_1$279,[createVNode(Slideshow_default,{class:`blur-carousel`,images:unref(backgroundsBlur),parent:unref(parentCarousel),transition:``},null,8,[`images`,`parent`])])):createCommentVNode(``,!0)}},BlurBackground_default=__plugin_vue_export_helper_default(_sfc_main$312,[[`__scopeId`,`data-v-cc1c4815`]]),_hoisted_1$278={class:`header-container`},_hoisted_2$229={key:1},_hoisted_3$203={class:`content-container`},_hoisted_4$174={class:`header-back-button`},_hoisted_5$150={key:0,class:`header-title-container`},_hoisted_6$129={class:`header-back-button`},_hoisted_7$115={class:`header-back-button`},_hoisted_8$96={key:0,class:`scrollable-content`},_hoisted_9$86={class:`details-mode-buttons`},_hoisted_10$75={key:1,class:`scrollable-content`},_hoisted_11$67={key:0,class:`details-content`},_hoisted_12$55={key:1,class:`scrollable-content`},_sfc_main$311={__name:`GridSelector`,props:{backendName:{type:String,default:`gridSelector`},routePath:{type:String,default:`/grid-selector`},defaultPath:{type:Object,default:()=>({keys:[`allModels`]})},defaultDetailsMode:{type:String,default:`detail`},hiddenTabs:{type:Array,default:()=>[]},tileImagesTopAligned:{type:Boolean,default:!1},doubleClickOverride:{type:Function,default:null},noBreadcrumbs:{type:Boolean,default:!1},overrideBackFromGrid:{type:Function,default:null},inlineHeaderContainer:{type:Boolean,default:!0},selectCallback:{type:Function,default:null},bubbleEvents:{type:Array,default:()=>[]}},setup(__props,{expose:__expose}){let props=__props,{showIfController}=storeToRefs(controls_default()),store$1=useGridSelector(props.backendName,props.defaultPath,props.defaultDetailsMode),{groups,displayData,detailsMode,selectedItem,showScreenHeader,screenHeaderTitle,screenHeaderPath,activeItemDetails,activeItem,activeFilters}=store$1,route=useRoute(),router$1=useRouter(),detailsModeTitles={detail:`Details`,advanced:`Advanced`,filter:`Filters`,displayControls:`Display`},detailsModeBackTo={filter:`advanced`,displayControls:`advanced`};watch(()=>[props.backendName,props.defaultPath,props.defaultDetailsMode],([newBackendName,newDefaultPath,newDefaultDetailsMode],[oldBackendName,oldDefaultPath,oldDefaultDetailsMode])=>{newBackendName!==oldBackendName&&newDefaultPath&&newDefaultPath.keys&&store$1.setCurrentPath(newDefaultPath),newDefaultDetailsMode!==oldDefaultDetailsMode&&store$1.setDetailsMode(newDefaultDetailsMode)},{deep:!0});let scopedNavState=reactive({isGridActive:!1,isDetailsActive:!1}),setBack=inject(`setBack`),showTopbarTabBindings=inject(`showTopbarTabBindings`),showTopbarBackBinding=inject(`showTopbarBackBinding`),showBreadcrumbsBack=ref(!1),canUseTopbar=ref(!0);watch(()=>scopedNavState.isDetailsActive,val=>{canUseTopbar.value=!val,showTopbarTabBindings(canUseTopbar.value)}),watch(screenHeaderPath,val=>{showBreadcrumbsBack.value=val&&val.length>2,showTopbarBackBinding(!showBreadcrumbsBack.value)});let switchSeq=computed(()=>[`detail`,`advanced`,`displayControls`].filter(tab=>!props.hiddenTabs.includes(tab))),getNextSwitchSeq=mode=>{mode||=detailsMode.value,mode===`filter`&&(mode=`advanced`);let seq=switchSeq.value;if(seq.length===0)return`detail`;let currentIndex=seq.indexOf(mode);return currentIndex===-1?seq[0]:seq[(currentIndex+1)%seq.length]},canSeeDetails=ref(!0),hasSelectedItem=computed(()=>!!store$1.selectedItem.value),canSwitchDetails=computed(()=>activeSectionScope.value!==`default`||detailsMode.value===`advanced`);function switchDetailsMode(mode){console.log(`switchDetailsMode`,mode),typeof mode!=`string`&&(mode=getNextSwitchSeq(mode)),mode===`detail`&&!canSeeDetails.value&&(mode=getNextSwitchSeq(mode)),console.log(`switchDetailsMode`,mode),store$1.setDetailsMode(mode),switchScope(`details`)}function onToggleSectionScope(){activeSectionScope.value===`grid`?switchScope(`details`):switchDetailsMode()}let activeSectionScope=ref(`grid`);function switchScope(name,force=!1){name||=activeSectionScope.value===`grid`?`details`:`grid`,name===`details`?(scopedNavState.isGridActive=!1,force&&(scopedNavState.isDetailsActive=!1),nextTick(()=>{activeSectionScope.value=name,scopedNavState.isDetailsActive=!0})):(scopedNavState.isDetailsActive=!1,force&&(scopedNavState.isGridActive=!1),nextTick(()=>{activeSectionScope.value=name,scopedNavState.isGridActive=!0}))}let onGridActivate=()=>{scopedNavState.isGridActive=!0},onGridDeactivate=event=>{scopedNavState.isGridActive=!1},onDetailsActivate=()=>{scopedNavState.isDetailsActive=!0},onDetailsDeactivate=event=>{scopedNavState.isDetailsActive=!1},setDetailsScope=info=>{switchScope(`details`)},canBubbleGridEvent=event=>!!(event.detail.name===`rotate_v_cam`||event.detail.name===`menu`||canUseTopbar.value&&(event.detail.name===`tab_l`||event.detail.name===`tab_r`)||props.bubbleEvents.includes(event.detail.name)),canBubbleDetailsEvent=event=>!!(event.detail.name===`rotate_v_cam`||props.bubbleEvents.includes(event.detail.name)),canDeactivateGrid=()=>screenHeaderPath.value.length<=1,onBackFromDetails=()=>{if(detailsMode.value===`displayControls`||detailsMode.value===`filter`){toggleDetailsMode(`advanced`);return}switchScope(`grid`)},onToggleFavorite=()=>{store$1.toggleFavourite(activeItem.value)},gridContentRef=ref(null),scrollPositions$1=ref(new Map),scrollTimeout=null,displaySize=computed(()=>{let option=displayData.value.find(option$1=>option$1.key===`displaySize`);return option?option.value:`medium`});store$1.initialize(),store$1.setOnBackFromDetailsCallback(()=>{onBackFromDetails()}),props.defaultPath.keys;let currentPathSegments=computed(()=>{let pathMatch=route.params.pathMatch;if(!pathMatch)return props.defaultPath?.keys||(Array.isArray(props.defaultPath)?props.defaultPath:[]);let segments=Array.isArray(pathMatch)?pathMatch.map(segment=>decodeURIComponent(segment)):[decodeURIComponent(pathMatch)];if(route.params.itemDetails){let itemDetails=Array.isArray(route.params.itemDetails)?route.params.itemDetails.map(segment=>decodeURIComponent(segment)):[decodeURIComponent(route.params.itemDetails)];segments.push(...itemDetails)}return segments}),saveScrollPosition$1=()=>{if(!gridContentRef.value)return;let pathKey=currentPathSegments.value.join(`/`),scrollTop=gridContentRef.value.scrollTop;scrollPositions$1.value.set(pathKey,scrollTop)},debouncedSaveScrollPosition=()=>{scrollTimeout&&clearTimeout(scrollTimeout),scrollTimeout=setTimeout(()=>{saveScrollPosition$1()},100)},restoreScrollPosition=()=>{if(!gridContentRef.value)return;let pathKey=currentPathSegments.value.join(`/`),savedPosition=scrollPositions$1.value.get(pathKey);savedPosition!==void 0&&nextTick(()=>{gridContentRef.value.scrollTop=savedPosition})};watch(groups,async newGroups=>{newGroups&&(await nextTick(),await nextTick(),store$1.notifyUIReady(),restoreScrollPosition())},{immediate:!0}),watch([currentPathSegments],async([segments],[oldSegments])=>{if(oldSegments&&gridContentRef.value){let oldPathKey=oldSegments.join(`/`),currentScrollTop=gridContentRef.value.scrollTop;scrollPositions$1.value.set(oldPathKey,currentScrollTop)}let path={keys:segments};await store$1.setCurrentPath(path)},{immediate:!0}),watch(gridContentRef,newElement=>{if(newElement){let handleScroll=()=>{debouncedSaveScrollPosition()};newElement.addEventListener(`scroll`,handleScroll),newElement._scrollHandler=handleScroll}},{immediate:!0}),onBeforeMount(()=>{Lua_default.simTimeAuthority.pushPauseRequest(`gridSelector`)}),onMounted(()=>{setBack(props.backendName,onBackFromGrid),nextTick(()=>{scopedNavState.isGridActive=!0})}),onUnmounted(()=>{setBack(props.backendName),gridContentRef.value&&gridContentRef.value._scrollHandler&&gridContentRef.value.removeEventListener(`scroll`,gridContentRef.value._scrollHandler),scrollTimeout&&clearTimeout(scrollTimeout),Lua_default.ui_gridSelector.closedFromUI(props.backendName),Lua_default.simTimeAuthority.popPauseRequest(`gridSelector`)});let onItemFocus=item=>{item&&item.showDetails&&store$1.setPreviewItem(item)},onItemSelect=async(item,doNavigation=!0)=>{if(item.gotoPath&&Array.isArray(item.gotoPath))store$1.prevSelectedItem.value=item.key,doNavigation&&routeNav(item),store$1.clearSelectedItem(),doNavigation&&switchScope(`grid`),props.selectCallback&&await props.selectCallback(item,doNavigation);else if(item.showDetails){item.key,selectedItem.value?.key;let consumed=!1;props.selectCallback&&(consumed=await props.selectCallback(item,doNavigation)),consumed||(await store$1.setSelectedItem(item),doNavigation&&switchScope(`details`))}},onGridWrapperClick=event=>{store$1.clearSelectedItem(),switchScope(`grid`,!0)},onDetailsWrapperClick=event=>{switchScope(`details`,!0)},onItemDeselect=()=>{store$1.clearSelectedItem()},toggleDetailsMode=mode=>{store$1.setDetailsMode(mode)};function routeNav(item){if(item.gotoAngularState)return;let encodedPath=item.gotoPath.map(segment=>encodeURIComponent(segment)).join(`/`);router$1.push(`${props.routePath}/${encodedPath}`)}let onBackFromGrid=()=>{if(console.log(`onBackFromGrid`,screenHeaderPath.value),props.overrideBackFromGrid&&screenHeaderPath.value.length<=2)return props.overrideBackFromGrid();if(screenHeaderPath.value.length>1){let item=screenHeaderPath.value[screenHeaderPath.value.length-2];return store$1.prevSelectedItem.value&&(store$1.autoFocusKey.value=store$1.prevSelectedItem.value),gotoHeaderItem(item),!1}return!0},onBreadBack=()=>nextTick(onBackFromGrid),clearSearch=()=>{store$1.setSearchText(``)},clearFilters=()=>{console.log(`clearFilters`,activeFilters.value);for(let filter of activeFilters.value)console.log(`clearFilter`,filter),filter&&filter.type===`range`?store$1.resetRangeFilter(filter.propName):store$1.resetSetFilter(filter.propName)},setCurrentPath=path=>{store$1.setCurrentPath(path)},gotoHeaderItem=item=>{console.log(`gotoHeaderItem`,item),item.gotoAngularState?window.bngVue.gotoAngularState(item.gotoAngularState):item.gotoPath&&(item.clearSearch&&clearSearch(),item.clearFilters&&clearFilters(),setCurrentPath({keys:item.gotoPath}),routeNav(item),switchScope(`grid`))};return __expose({screenHeaderPath,clearSearch,clearFilters,setCurrentPath}),(_ctx,_cache)=>withDirectives((openBlock(),createBlock(unref(layoutSingle_default),{class:`grid-selector`},{default:withCtx(()=>[createBaseVNode(`div`,_hoisted_1$278,[__props.noBreadcrumbs?(openBlock(),createElementBlock(`div`,_hoisted_2$229)):(openBlock(),createBlock(unref(bngBreadcrumbs_default),{key:0,class:`header-breadcrumbs`,items:unref(screenHeaderPath),limit:`5`,simple:``,"disable-last-item":``,"show-back-button":showBreadcrumbsBack.value,onClick:gotoHeaderItem,onBack:onBreadBack},null,8,[`items`,`show-back-button`])),__props.inlineHeaderContainer?createCommentVNode(``,!0):(openBlock(),createBlock(HeaderButtons_default,{key:2,"can-switch-details":canSwitchDetails.value,"hidden-tabs":props.hiddenTabs,"details-mode":unref(detailsMode),onSwitchDetailsMode:switchDetailsMode},null,8,[`can-switch-details`,`hidden-tabs`,`details-mode`]))]),createBaseVNode(`div`,_hoisted_3$203,[createBaseVNode(`div`,{class:normalizeClass([`grid-wrapper`,{active:activeSectionScope.value===`grid`}])},[createVNode(BlurBackground_default),unref(showScreenHeader)?(openBlock(),createElementBlock(`div`,{key:0,class:normalizeClass([`header-row`,{active:activeSectionScope.value===`grid`&&unref(showIfController),"no-controller":!unref(showIfController)}])},[createVNode(unref(bngScreenHeadingV2_default),{type:`2`,class:`header-title-v2`},{default:withCtx(()=>[createTextVNode(toDisplayString(unref(screenHeaderTitle)),1)]),_:1}),withDirectives(createBaseVNode(`div`,_hoisted_4$174,[createVNode(unref(bngBinding_default),{"ui-event":`back`,controller:``}),createVNode(unref(bngIcon_default),{type:unref(icons).undo},null,8,[`type`])],512),[[vShow,activeSectionScope.value===`grid`&&unref(showIfController)&¤tPathSegments.value.length>1]])],2)):createCommentVNode(``,!0),withDirectives((openBlock(),createElementBlock(`div`,{class:`grid-content`,ref_key:`gridContentRef`,ref:gridContentRef,"bng-nav-scroll":``,"bng-no-nav":`true`,tabindex:`-1`,onActivate:onGridActivate,onDeactivate:onGridDeactivate,onClick:onGridWrapperClick},[createVNode(Grid_default$1,{"in-details":activeSectionScope.value===`details`&&unref(detailsMode)===`detail`,"display-size":displaySize.value,"backend-name":props.backendName,"auto-focus-key":unref(store$1).autoFocusKey.value,"active-item":unref(store$1).activeItem.value,groups:unref(groups),"tile-images-top-aligned":__props.tileImagesTopAligned,onFocusItem:onItemFocus,onSelectItem:onItemSelect,onDeselectItem:onItemDeselect,"double-click-override":__props.doubleClickOverride},null,8,[`in-details`,`display-size`,`backend-name`,`auto-focus-key`,`active-item`,`groups`,`tile-images-top-aligned`,`double-click-override`])],32)),[[unref(BngScopedNav_default),{activated:scopedNavState.isGridActive,canBubbleEvent:canBubbleGridEvent,canDeactivate:canDeactivateGrid,preferAutoFocus:!0,autoFocusDelay:400}],[unref(BngOnUiNav_default),onToggleSectionScope,`context`],[unref(BngUiNavLabel_default),`Filters and more`,`context`],[unref(BngOnUiNav_default),onBackFromGrid,`back`],[unref(BngUiNavScroll_default)]])],2),withDirectives((openBlock(),createElementBlock(`div`,{class:normalizeClass([`details-wrapper wide`,{active:activeSectionScope.value===`details`,"no-controller":!unref(showIfController)}]),tabindex:`-1`,"bng-no-nav":`true`,onActivate:onDetailsActivate,onDeactivate:onDetailsDeactivate,onClick:onDetailsWrapperClick},[createVNode(BlurBackground_default),createBaseVNode(`div`,{class:normalizeClass([`header-row`,{active:activeSectionScope.value===`details`&&unref(showIfController),"no-controller":!unref(showIfController)}]),"bng-no-child-nav":`true`},[createVNode(HeaderButtons_default,{slim:``,"can-switch-details":canSwitchDetails.value,"hidden-tabs":props.hiddenTabs,"details-mode":unref(detailsMode),onSwitchDetailsMode:switchDetailsMode},null,8,[`can-switch-details`,`hidden-tabs`,`details-mode`]),__props.inlineHeaderContainer?createCommentVNode(``,!0):(openBlock(),createElementBlock(`div`,_hoisted_5$150,[createVNode(unref(bngCardHeading_default),{type:`ribbon`,class:`header-title`},{default:withCtx(()=>[createTextVNode(toDisplayString(detailsModeTitles[unref(detailsMode)]),1)]),_:1}),detailsModeBackTo[unref(detailsMode)]?(openBlock(),createBlock(unref(bngButton_default),{key:0,"bng-no-nav":`true`,onClick:_cache[0]||=$event=>toggleDetailsMode(detailsModeBackTo[unref(detailsMode)]),accent:unref(ACCENTS).outlined,iconRight:`undo`},{default:withCtx(()=>[createVNode(unref(bngBinding_default),{"ui-event":`back`,controller:``})]),_:1},8,[`accent`])):createCommentVNode(``,!0),withDirectives(createBaseVNode(`div`,_hoisted_6$129,[createVNode(unref(bngIcon_default),{type:unref(icons).adjust},null,8,[`type`]),createVNode(unref(bngBinding_default),{"ui-event":`context`,controller:``})],512),[[vShow,activeSectionScope.value===`grid`||!unref(showIfController)]]),withDirectives(createBaseVNode(`div`,_hoisted_7$115,[createVNode(unref(bngBinding_default),{"ui-event":`back`,controller:``}),createVNode(unref(bngIcon_default),{type:unref(icons).undo},null,8,[`type`])],512),[[vShow,activeSectionScope.value===`details`&&unref(showIfController)]])]))],2),unref(detailsMode)===`advanced`?(openBlock(),createElementBlock(`div`,_hoisted_8$96,[createVNode(SearchBar_default,{searchText:unref(store$1).searchText.value,setSearchText:unref(store$1).setSearchText},null,8,[`searchText`,`setSearchText`]),createVNode(DetailedFilters_default,{filterList:unref(store$1).filterList.value,filterByProp:unref(store$1).filterByProp.value,searchText:unref(store$1).searchText.value,commonFilters:unref(store$1).commonFilters.value,detailsMode:unref(store$1).detailsMode.value,onlyCommonFilters:unref(store$1).onlyCommonFilters.value,isFilterLocked:unref(store$1).isFilterLocked,isFilterOptionLocked:unref(store$1).isFilterOptionLocked,isRangeFilterLocked:unref(store$1).isRangeFilterLocked,toggleFilter:unref(store$1).toggleFilter,updateRangeFilter:unref(store$1).updateRangeFilter,resetRangeFilter:unref(store$1).resetRangeFilter,setSearchText:unref(store$1).setSearchText,setDetailsMode:unref(store$1).setDetailsMode},null,8,[`filterList`,`filterByProp`,`searchText`,`commonFilters`,`detailsMode`,`onlyCommonFilters`,`isFilterLocked`,`isFilterOptionLocked`,`isRangeFilterLocked`,`toggleFilter`,`updateRangeFilter`,`resetRangeFilter`,`setSearchText`,`setDetailsMode`]),createVNode(DisplayControls_default,{displayData:unref(store$1).displayData.value,detailsMode:unref(store$1).detailsMode.value,updateDisplayData:unref(store$1).updateDisplayData,resetDisplayDataToDefaults:unref(store$1).resetDisplayDataToDefaults,setDetailsMode:unref(store$1).setDetailsMode},null,8,[`displayData`,`detailsMode`,`updateDisplayData`,`resetDisplayDataToDefaults`,`setDetailsMode`]),createBaseVNode(`div`,_hoisted_9$86,[createVNode(unref(bngButton_default),{onClick:_cache[1]||=$event=>toggleDetailsMode(`filter`),accent:unref(ACCENTS).secondary,iconLeft:`filter`},{default:withCtx(()=>[..._cache[3]||=[createTextVNode(` More filters... `,-1)]]),_:1},8,[`accent`]),createVNode(unref(bngButton_default),{onClick:_cache[2]||=$event=>toggleDetailsMode(`displayControls`),accent:unref(ACCENTS).secondary,iconLeft:`adjust`},{default:withCtx(()=>[..._cache[4]||=[createTextVNode(` Display Options `,-1)]]),_:1},8,[`accent`])]),createVNode(unref(bngCardHeading_default),{type:`line`,class:`heading`},{default:withCtx(()=>[..._cache[5]||=[createTextVNode(`Management`,-1)]]),_:1}),renderSlot(_ctx.$slots,`management-details`,{managementDetails:unref(store$1).managementDetails.value,executeButton:unref(store$1).executeButton},void 0,!0)])):unref(detailsMode)===`filter`?(openBlock(),createElementBlock(`div`,_hoisted_10$75,[createVNode(DetailedFilters_default,{filterList:unref(store$1).filterList.value,filterByProp:unref(store$1).filterByProp.value,searchText:unref(store$1).searchText.value,commonFilters:unref(store$1).commonFilters.value,detailsMode:unref(store$1).detailsMode.value,onlyCommonFilters:unref(store$1).onlyCommonFilters.value,isFilterLocked:unref(store$1).isFilterLocked,isFilterOptionLocked:unref(store$1).isFilterOptionLocked,isRangeFilterLocked:unref(store$1).isRangeFilterLocked,toggleFilter:unref(store$1).toggleFilter,updateRangeFilter:unref(store$1).updateRangeFilter,resetRangeFilter:unref(store$1).resetRangeFilter,setSearchText:unref(store$1).setSearchText,setDetailsMode:unref(store$1).setDetailsMode},null,8,[`filterList`,`filterByProp`,`searchText`,`commonFilters`,`detailsMode`,`onlyCommonFilters`,`isFilterLocked`,`isFilterOptionLocked`,`isRangeFilterLocked`,`toggleFilter`,`updateRangeFilter`,`resetRangeFilter`,`setSearchText`,`setDetailsMode`])])):unref(detailsMode)===`displayControls`?(openBlock(),createBlock(DisplayControls_default,{key:2,class:`scrollable-content`,displayData:unref(store$1).displayData.value,detailsMode:unref(store$1).detailsMode.value,updateDisplayData:unref(store$1).updateDisplayData,resetDisplayDataToDefaults:unref(store$1).resetDisplayDataToDefaults,setDetailsMode:unref(store$1).setDetailsMode},null,8,[`displayData`,`detailsMode`,`updateDisplayData`,`resetDisplayDataToDefaults`,`setDetailsMode`])):unref(detailsMode)===`detail`?(openBlock(),createElementBlock(Fragment,{key:3},[hasSelectedItem.value?(openBlock(),createElementBlock(`div`,_hoisted_11$67,[renderSlot(_ctx.$slots,`item-details`,{activeItem:unref(store$1).activeItem.value,activeItemDetails:unref(store$1).activeItemDetails.value,executeButton:unref(store$1).executeButton,toggleFavourite:unref(store$1).toggleFavourite,exploreFolder:unref(store$1).exploreFolder,goToMod:unref(store$1).goToMod,onFocusItem:setDetailsScope},void 0,!0)])):(openBlock(),createElementBlock(`div`,_hoisted_12$55,[createVNode(SearchBar_default,{searchText:unref(store$1).searchText.value,setSearchText:unref(store$1).setSearchText},null,8,[`searchText`,`setSearchText`]),createVNode(DetailedFilters_default,{filterList:unref(store$1).filterList.value,filterByProp:unref(store$1).filterByProp.value,searchText:unref(store$1).searchText.value,commonFilters:unref(store$1).commonFilters.value,detailsMode:unref(store$1).detailsMode.value,onlyCommonFilters:unref(store$1).onlyCommonFilters.value,isFilterLocked:unref(store$1).isFilterLocked,isFilterOptionLocked:unref(store$1).isFilterOptionLocked,isRangeFilterLocked:unref(store$1).isRangeFilterLocked,toggleFilter:unref(store$1).toggleFilter,updateRangeFilter:unref(store$1).updateRangeFilter,resetRangeFilter:unref(store$1).resetRangeFilter,setSearchText:unref(store$1).setSearchText,setDetailsMode:unref(store$1).setDetailsMode},null,8,[`filterList`,`filterByProp`,`searchText`,`commonFilters`,`detailsMode`,`onlyCommonFilters`,`isFilterLocked`,`isFilterOptionLocked`,`isRangeFilterLocked`,`toggleFilter`,`updateRangeFilter`,`resetRangeFilter`,`setSearchText`,`setDetailsMode`]),createVNode(DisplayControls_default,{displayData:unref(store$1).displayData.value,detailsMode:unref(store$1).detailsMode.value,updateDisplayData:unref(store$1).updateDisplayData,resetDisplayDataToDefaults:unref(store$1).resetDisplayDataToDefaults,setDetailsMode:unref(store$1).setDetailsMode},null,8,[`displayData`,`detailsMode`,`updateDisplayData`,`resetDisplayDataToDefaults`,`setDetailsMode`]),createVNode(unref(bngCardHeading_default),{type:`line`,class:`heading`},{default:withCtx(()=>[..._cache[6]||=[createTextVNode(`Info`,-1)]]),_:1}),_cache[7]||=createBaseVNode(`div`,{class:`scrollable-content`},` Please select an item to see details. `,-1)]))],64)):createCommentVNode(``,!0)],34)),[[unref(BngScopedNav_default),{activated:scopedNavState.isDetailsActive,canDeactivate:()=>!1,canBubbleEvent:canBubbleDetailsEvent,bubbleWhitelistEvents:[`menu`]}],[unref(BngOnUiNav_default),onToggleSectionScope,`context`],[unref(BngUiNavLabel_default),`Filters and more`,`context`],[unref(BngOnUiNav_default),onToggleFavorite,`action_2`],[unref(BngUiNavLabel_default),`Toggle favorite`,`action_2`],[unref(BngOnUiNav_default),onBackFromDetails,`back`,{focusRequired:!0}]])])]),_:3})),[[unref(BngBlur_default)],[unref(BngOnUiNav_default),()=>{},`rotate_h_cam,rotate_v_cam`]])}},GridSelector_default=__plugin_vue_export_helper_default(_sfc_main$311,[[`__scopeId`,`data-v-d340d12f`]]),_hoisted_1$277={class:`details`,"bng-nav-scroll":``},_hoisted_2$228={key:0,class:`preview`},_hoisted_3$202={key:1,class:`content-header`},_hoisted_4$173={key:0,class:`description`},_hoisted_5$149={key:0,class:`specs-grid`},_hoisted_6$128={class:`specs-grid-container`},_hoisted_7$114={class:`spec-content`},_hoisted_8$95={class:`spec-label`},_hoisted_9$85={class:`spec-value`},_hoisted_10$74={key:2,class:`buttons-section`},_sfc_main$310={__name:`AppDetails`,props:{activeItem:{type:Object,default:null},activeItemDetails:{type:Object,default:null},executeButton:{type:Function,required:!0},toggleFavourite:{type:Function,required:!0}},setup(__props){let props=__props,handleButtonClick=buttonId=>{props.executeButton(buttonId)};return(_ctx,_cache)=>withDirectives((openBlock(),createElementBlock(`div`,_hoisted_1$277,[__props.activeItemDetails?.preview?(openBlock(),createElementBlock(`div`,_hoisted_2$228,[createVNode(unref(aspectRatio_default),{class:`preview-image`,ratio:`16:8`,"external-image":__props.activeItemDetails.preview},null,8,[`external-image`])])):createCommentVNode(``,!0),__props.activeItemDetails?.headerTitle?(openBlock(),createElementBlock(`div`,_hoisted_3$202,[__props.activeItemDetails?.description?(openBlock(),createElementBlock(`div`,_hoisted_4$173,toDisplayString(__props.activeItemDetails.description),1)):createCommentVNode(``,!0)])):createCommentVNode(``,!0),(openBlock(!0),createElementBlock(Fragment,null,renderList(__props.activeItemDetails?.specifications,(specList,specListIndex)=>(openBlock(),createElementBlock(Fragment,{key:specListIndex},[specList.length>0?(openBlock(),createElementBlock(`div`,_hoisted_5$149,[createBaseVNode(`div`,_hoisted_6$128,[(openBlock(!0),createElementBlock(Fragment,null,renderList(specList,specification=>(openBlock(),createElementBlock(`div`,{key:specification.key,class:`spec-cell`},[specification.icon?(openBlock(),createBlock(unref(bngIcon_default),{key:0,type:specification.icon,class:`spec-icon`},null,8,[`type`])):createCommentVNode(``,!0),createBaseVNode(`div`,_hoisted_7$114,[createBaseVNode(`div`,_hoisted_8$95,toDisplayString(specification.label)+`:`,1),createBaseVNode(`div`,_hoisted_9$85,[createBaseVNode(`span`,null,toDisplayString(specification.value),1)])])]))),128))])])):createCommentVNode(``,!0)],64))),128)),__props.activeItemDetails?.buttonInfo?.length>0?(openBlock(),createElementBlock(`div`,_hoisted_10$74,[(openBlock(!0),createElementBlock(Fragment,null,renderList(__props.activeItemDetails.buttonInfo,button=>(openBlock(),createBlock(unref(bngButton_default),{key:button.buttonId,"bng-scoped-nav-autofocus":button.primary,accent:button.primary?`main`:`secondary`,label:button.label,icon:button.icon,onClick:$event=>handleButtonClick(button.buttonId)},null,8,[`bng-scoped-nav-autofocus`,`accent`,`label`,`icon`,`onClick`]))),128))])):createCommentVNode(``,!0)])),[[unref(BngUiNavScroll_default),void 0,void 0,{force:!0}]])}},AppDetails_default=__plugin_vue_export_helper_default(_sfc_main$310,[[`__scopeId`,`data-v-c8fb13f2`]]),_sfc_main$309={__name:`AppSelector`,setup(__props){return(_ctx,_cache)=>(openBlock(),createBlock(GridSelector_default,{backendName:`appSelector`,routePath:`/app-selector`,defaultPath:{keys:[`allApps`]},defaultDetailsMode:`advanced`},{"item-details":withCtx(({activeItem,activeItemDetails,executeButton,toggleFavourite})=>[createVNode(AppDetails_default,{activeItem,activeItemDetails,executeButton,toggleFavourite},null,8,[`activeItem`,`activeItemDetails`,`executeButton`,`toggleFavourite`])]),_:1}))}},AppSelector_default=_sfc_main$309,routes_default=[{name:`menu.appselector`,path:`/app-selector/:pathMatch(.*)*`,component:AppSelector_default,props:!0,meta:{clickThrough:!1,infoBar:{visible:!0,showSysInfo:!1},uiApps:{shown:!1},topBar:{visible:!0}}},{name:`menu.appedit`,path:`/app-edit/`,component:NotFound_default,meta:{clickThrough:!0,infoBar:{visible:!0,showSysInfo:!1},uiApps:{shown:!0},topBar:{visible:!0}}}],_hoisted_1$276={class:`main-info`},_hoisted_2$227={class:`heading`},_hoisted_3$201={key:0,class:`stars`},_hoisted_4$172={key:1,class:`aggregate-primary`},_hoisted_5$148={class:`label`},_hoisted_6$127={class:`value`},_hoisted_7$113={key:2,class:`empty-gap`},_sfc_main$308={__name:`PoiCard`,props:{poi:{type:Object,required:!0},shown:{type:Boolean,default:!0}},emits:[`select`,`hover`],setup(__props,{emit:__emit}){let debugLog$1=(message,data)=>{},props=__props,emit$1=__emit,onSelect=()=>{props.poi.id,props.poi.name,emit$1(`select`,props.poi.id)},thumbLoaded=props.shown&&!!props.poi?.thumbnail,thumbShown=ref(thumbLoaded),thumb=ref(thumbLoaded?`url("${props.poi?.thumbnail}")`:`none`),lastThumb=thumbLoaded?props.poi?.thumbnail:void 0;return watch([()=>props.shown,()=>props.poi],()=>{if(props.shown&&props.poi?.thumbnail){let url=props.poi.thumbnail;if(lastThumb!==url){lastThumb=url,thumbLoaded=!1;let img=new Image;img.src=url,img.onload=()=>{lastThumb===url&&(thumbLoaded=!0,thumb.value=`url("${url}")`,thumbShown.value=!0)}}}else props.poi?.thumbnail||(lastThumb=void 0,thumbLoaded=!1,thumb.value=`none`,thumbShown.value=!1)},{immediate:!0}),(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,{class:normalizeClass([`poi-item`,{highlighted:__props.poi.isSelected}]),onClick:onSelect,"bng-nav-item":``},[createBaseVNode(`div`,{class:normalizeClass([`card-info`,{"content-shown":__props.shown,"thumb-show":thumbShown.value&&!!thumb.value}]),style:normalizeStyle({"--poi-image":thumb.value})},[__props.poi.icon?(openBlock(),createBlock(unref(bngIcon_default),{key:0,class:`mission-icon`,type:__props.poi.icon,color:`white`},null,8,[`type`])):createCommentVNode(``,!0),createBaseVNode(`div`,_hoisted_1$276,[createBaseVNode(`div`,_hoisted_2$227,toDisplayString(__props.poi.name),1),__props.poi.formattedProgress?(openBlock(),createElementBlock(`div`,_hoisted_3$201,[__props.poi.formattedProgress.unlockedStars?(openBlock(),createBlock(unref(bngMainStars_default),{key:0,"individual-stars":__props.poi.formattedProgress.unlockedStars.defaults,class:`main-stars`,scale:.6,reverse:``},null,8,[`individual-stars`])):createCommentVNode(``,!0),__props.poi.formattedProgress.unlockedStars&&__props.poi.formattedProgress.unlockedStars.totalBonusStarCount>0?(openBlock(),createBlock(unref(bngMainStars_default),{key:1,"individual-stars":__props.poi.formattedProgress.unlockedStars.bonus,class:`bonus-stars`,scale:.6},null,8,[`individual-stars`])):createCommentVNode(``,!0)])):__props.poi.aggregatePrimary?(openBlock(),createElementBlock(`div`,_hoisted_4$172,[createBaseVNode(`span`,_hoisted_5$148,toDisplayString(__props.poi.aggregatePrimary.label)+`:`,1),createBaseVNode(`span`,_hoisted_6$127,toDisplayString(__props.poi.aggregatePrimary.value),1)])):(openBlock(),createElementBlock(`div`,_hoisted_7$113))]),createVNode(unref(bngBinding_default),{class:`input-icon`,"ui-event":`ok`,controller:``})],6)],2))}},PoiCard_default=__plugin_vue_export_helper_default(_sfc_main$308,[[`__scopeId`,`data-v-cd49bd11`]]),_hoisted_1$275={class:`poi-list`},_hoisted_2$226={class:`filter-header`},_hoisted_3$200={class:`poi-list-items`},_sfc_main$307={__name:`PoiList`,props:{store:{type:Object,required:!0}},setup(__props){let props=__props,poiListContainer=ref(null),shownCards=ref(new Set),{groupData,poiData,selectedPoi,selectPoi,onHover,debugLog:debugLog$1}=props.store,processedPoiData=computed(()=>{let processed={};if(!poiData.value)return processed;for(let[poiId,poi]of Object.entries(poiData.value))poi&&(processed[poiId]={id:poi.id||poiId,name:poi.name?$translate.instant(poi.name):``,icon:poi.icon?icons[poi.icon]:icons._empty,thumbnail:poi.thumbnailFile,formattedProgress:poi.formattedProgress,aggregatePrimary:poi.aggregatePrimary?.label&&poi.aggregatePrimary?.value?{label:$translate.instant(poi.aggregatePrimary.label),value:$translate.instant(poi.aggregatePrimary.value)}:null,isSelected:selectedPoi.value?.id===poi.id});return processed});debugLog$1(`PoiList`,`Component initialized`,{groupDataCount:groupData.value?.length||0,poiDataCount:Object.keys(poiData.value||{}).length,processedPoiCount:Object.keys(processedPoiData.value).length});let observer$2=new IntersectionObserver(entries=>{for(let entry of entries){let poiId=entry.target.getAttribute(`data-poi-id`);poiId&&entry.isIntersecting?shownCards.value.add(poiId):shownCards.value.delete(poiId)}},{threshold:.1,rootMargin:`10px`}),setupObserver=()=>{if(!poiListContainer.value)return;let elms$4=poiListContainer.value.querySelectorAll(`[data-poi-id]`),ids=[];for(let elm of elms$4){let poiId=elm.getAttribute(`data-poi-id`);poiId&&(ids.push(poiId),observer$2.observe(elm))}for(let id of shownCards.value)ids.includes(id)||shownCards.value.delete(id)};return watch(poiListContainer,cont=>cont&&nextTick(setupObserver),{immediate:!0}),watch([groupData,processedPoiData],()=>{nextTick(()=>{observer$2.disconnect(),setupObserver()})},{immediate:!1}),onUnmounted(()=>{shownCards.value.clear(),observer$2.disconnect()}),(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$275,[createBaseVNode(`div`,{class:`poi-list-content`,ref_key:`poiListContainer`,ref:poiListContainer},[(openBlock(!0),createElementBlock(Fragment,null,renderList(unref(groupData),section=>(openBlock(),createElementBlock(`div`,{key:section.key,class:`filter-section`},[createBaseVNode(`div`,_hoisted_2$226,[createVNode(unref(bngIcon_default),{type:section.icon},null,8,[`type`]),createBaseVNode(`span`,null,toDisplayString(section.title?_ctx.$tt(section.title):``),1)]),(openBlock(!0),createElementBlock(Fragment,null,renderList(section.groups,group=>(openBlock(),createElementBlock(`div`,{key:group.key,class:`mission-group`},[createVNode(unref(bngCardHeading_default),{class:`mission-group-header`,type:`ribbon`,outline:``},{default:withCtx(()=>[createTextVNode(toDisplayString(_ctx.$t(group.label)),1)]),_:2},1024),createBaseVNode(`div`,_hoisted_3$200,[(openBlock(!0),createElementBlock(Fragment,null,renderList(group.elementIds,poiId=>(openBlock(),createBlock(PoiCard_default,{key:poiId,"data-poi-id":poiId,shown:shownCards.value.has(poiId),poi:processedPoiData.value[poiId],onSelect:unref(selectPoi),onHover:unref(onHover)},null,8,[`data-poi-id`,`shown`,`poi`,`onSelect`,`onHover`]))),128))])]))),128))]))),128))],512)]))}},PoiList_default=__plugin_vue_export_helper_default(_sfc_main$307,[[`__scopeId`,`data-v-0ccba230`]]),_hoisted_1$274={class:`header`},_sfc_main$306={__name:`bngAdvCardHeading`,props:{blurDelay:Number,preheadings:Array,divider:Boolean,icon:String,type:{type:String,default:`line`,validator:v=>[`line`,`ribbon`].includes(v)||v===``}},setup(__props){let blurVal=ref(!1);onMounted(()=>window.setTimeout(()=>blurVal.value=!0,~~+props.blurDelay));let props=__props;return(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,{class:normalizeClass([`bng-screen-header`,{[`heading-style-${__props.type}`]:!0,prehead:__props.preheadings}])},[_cache[0]||=createBaseVNode(`div`,{class:`decorator`},null,-1),__props.preheadings?(openBlock(),createElementBlock(`span`,{key:0,class:normalizeClass([`pre-header`,{"with-divider":__props.divider}])},[__props.icon?(openBlock(),createBlock(unref(bngIcon_default),{key:0,type:__props.icon,class:`pre-header-icon`},null,8,[`type`])):createCommentVNode(``,!0),(openBlock(!0),createElementBlock(Fragment,null,renderList(__props.preheadings,preheading=>(openBlock(),createElementBlock(`span`,{class:`location`,key:preheading},toDisplayString(preheading),1))),128))],2)):createCommentVNode(``,!0),createBaseVNode(`h1`,_hoisted_1$274,[renderSlot(_ctx.$slots,`default`,{},void 0,!0)])],2))}},bngAdvCardHeading_default=__plugin_vue_export_helper_default(_sfc_main$306,[[`__scopeId`,`data-v-16619e8d`]]),_hoisted_1$273={key:0,class:`poi-icons`},_hoisted_2$225=[`onClick`],_hoisted_3$199={key:1,class:`poi-details`},_hoisted_4$171={class:`poi-content`},_hoisted_5$147={class:`poi-scrollable`},_hoisted_6$126={key:0,class:`poi-aggregate-display`},_hoisted_7$112={key:0,class:`poi-stars`},_hoisted_8$94={class:`stars`},_hoisted_9$84={key:1,class:`aggregate-primary`},_hoisted_10$73={class:`label`},_hoisted_11$66={class:`value`},_hoisted_12$54={key:1,class:`poi-description`},_hoisted_13$47={class:`poi-actions`},_sfc_main$305={__name:`PoiDetails`,props:{store:{type:Object,required:!0}},emits:[`setRoute`,`teleport`],setup(__props,{emit:__emit}){let props=__props,{selectedPoi,selectedPoiIds,poiData,debugLog:debugLog$1}=props.store;debugLog$1(`PoiDetails`,`Component initialized`,{selectedPoiId:selectedPoi.value?.id,selectedPoiIdsCount:selectedPoiIds.value?.length||0});let selectedPoisList=computed(()=>{if(!selectedPoiIds.value||selectedPoiIds.value.length===0)return selectedPoi.value?[selectedPoi.value]:[];let pois=[];for(let poiId of selectedPoiIds.value){let poi=poiData.value[poiId];poi&&pois.push(poi)}return debugLog$1(`PoiDetails`,`Final pois list`,pois),pois}),currentPoiIndex=computed(()=>{if(selectedPoisList.value.length<=1)return 0;let index=selectedPoisList.value.findIndex(poi=>poi.id===selectedPoi.value?.id);return index>=0?index:0}),selectPoi=index=>{index>=0&&index{let headings=[];return selectedPoi.value?.label&&headings.push($translate.instant(selectedPoi.value.label)),headings}),preview=computed(()=>selectedPoi.value?.previewFiles?.length>0?selectedPoi.value.previewFiles[0]:selectedPoi.value?.thumbnailFile||null),safeTranslate=key=>{if(!key)return``;try{return typeof key==`string`?$translate.instant(key):(typeof key==`object`&&key.txt,$translate.contextTranslate(key))}catch(e){return console.warn(`Translation failed for key:`,key,e),typeof key==`string`?key:key?.txt||``}},aggregatePrimary=computed(()=>{let poi=selectedPoi.value;return poi?.aggregatePrimary?.label&&poi?.aggregatePrimary?.value?poi.aggregatePrimary:null}),onAction=action=>{props.store.executePoiAction(action.actionId)};return(_ctx,_cache)=>(openBlock(),createElementBlock(Fragment,null,[selectedPoisList.value.length>=1?withDirectives((openBlock(),createElementBlock(`div`,_hoisted_1$273,[(openBlock(!0),createElementBlock(Fragment,null,renderList(selectedPoisList.value,(poi,index)=>(openBlock(),createElementBlock(`div`,{key:poi.id||index,class:normalizeClass([`poi-icon`,{active:index===currentPoiIndex.value}]),onClick:$event=>selectPoi(index)},[createVNode(unref(bngSpriteIcon_default),{src:`map_`+poi.spriteIcon,style:{width:`100%`,height:`100%`}},null,8,[`src`])],10,_hoisted_2$225))),128))])),[[unref(BngBlur_default),!0]]):createCommentVNode(``,!0),unref(selectedPoi)?withDirectives((openBlock(),createElementBlock(`div`,_hoisted_3$199,[createBaseVNode(`div`,_hoisted_4$171,[createVNode(bngAdvCardHeading_default,{class:`poi-details-header`,type:`line`,preheadings:preheadings.value},{default:withCtx(()=>[createTextVNode(toDisplayString(safeTranslate(unref(selectedPoi).name)),1)]),_:1},8,[`preheadings`]),createBaseVNode(`div`,_hoisted_5$147,[preview.value?(openBlock(),createBlock(aspectRatio_default,{key:0,class:`poi-thumbnail`,ratio:`16:9`,externalImage:preview.value,imageMode:`cover`},{default:withCtx(()=>[aggregatePrimary.value||unref(selectedPoi).formattedProgress?(openBlock(),createElementBlock(`div`,_hoisted_6$126,[unref(selectedPoi).formattedProgress?(openBlock(),createElementBlock(`div`,_hoisted_7$112,[createBaseVNode(`div`,_hoisted_8$94,[unref(selectedPoi).formattedProgress.unlockedStars?(openBlock(),createBlock(unref(bngMainStars_default),{key:0,individualStars:unref(selectedPoi).formattedProgress.unlockedStars.defaults,class:`main-stars`,scale:.8,reverse:``},null,8,[`individualStars`])):createCommentVNode(``,!0),unref(selectedPoi).formattedProgress.unlockedStars&&unref(selectedPoi).formattedProgress.unlockedStars.totalBonusStarCount>0?(openBlock(),createBlock(unref(bngMainStars_default),{key:1,individualStars:unref(selectedPoi).formattedProgress.unlockedStars.bonus,class:`bonus-stars`,scale:.8},null,8,[`individualStars`])):createCommentVNode(``,!0)])])):aggregatePrimary.value?(openBlock(),createElementBlock(`div`,_hoisted_9$84,[createBaseVNode(`span`,_hoisted_10$73,toDisplayString(_ctx.$t(aggregatePrimary.value.label))+`:`,1),createBaseVNode(`span`,_hoisted_11$66,toDisplayString(_ctx.$t(aggregatePrimary.value.value)),1)])):createCommentVNode(``,!0)])):createCommentVNode(``,!0)]),_:1},8,[`externalImage`])):createCommentVNode(``,!0),unref(selectedPoi).description?(openBlock(),createElementBlock(`div`,_hoisted_12$54,toDisplayString(safeTranslate(unref(selectedPoi).description)),1)):createCommentVNode(``,!0)]),createBaseVNode(`div`,_hoisted_13$47,[(openBlock(!0),createElementBlock(Fragment,null,renderList(unref(selectedPoi).actions,action=>(openBlock(),createBlock(unref(bngButton_default),{key:action.id,accent:unref(ACCENTS).secondary,"icon-right":action.icon,label:action.label,onClick:$event=>onAction(action)},null,8,[`accent`,`icon-right`,`label`,`onClick`]))),128))])])])),[[unref(BngBlur_default),!0]]):createCommentVNode(``,!0)],64))}},PoiDetails_default=__plugin_vue_export_helper_default(_sfc_main$305,[[`__scopeId`,`data-v-35e47e7e`]]),_hoisted_1$272={class:`poi-filters`},_hoisted_2$224={key:0,class:`filter-row`},_hoisted_3$198=[`onClick`],_hoisted_4$170=[`onClick`],_sfc_main$304={__name:`PoiFilters`,props:{store:{type:Object,required:!0}},setup(__props){let props=__props,{filterData,debugLog:debugLog$1}=props.store;debugLog$1(`PoiFilters`,`Component initialized`,{filterDataCount:filterData.value?.length||0});let getGroupVisualState=(filter,group)=>{if(!filter||!group||!filter.groups||!Array.isArray(filter.groups))return`inactive`;let visibleGroups=0,totalGroups=0;for(let filterGroup of filter.groups)filterGroup&&filterGroup.elementCount>0&&(totalGroups++,filterGroup.visible&&visibleGroups++);let isAllGroupsActive=visibleGroups===totalGroups,isGroupActive=group.visible;return isAllGroupsActive?`neutral`:isGroupActive?`active`:`inactive`},getGroupColor=(filter,group)=>{switch(getGroupVisualState(filter,group)){case`neutral`:return`var(--bng-off-white)`;case`active`:return`var(--bng-add-green-100)`;case`inactive`:default:return`var(--bng-add-red-300)`}},hasActiveFilters=filter=>{if(!filter||!filter.groups||!Array.isArray(filter.groups))return!1;let visibleGroups=0,totalGroups=0;for(let group of filter.groups)group&&group.elementCount>0&&(totalGroups++,group.visible&&visibleGroups++);return visibleGroups{debugLog$1(`PoiFilters`,`Toggling group visibility`,groupKey),props.store.toggleGroupVisibility(groupKey)},toggleFilterSectionVisibility=filterKey=>{debugLog$1(`PoiFilters`,`Toggling filter section visibility`,filterKey),props.store.toggleFilterSectionVisibility(filterKey)};return(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$272,[(openBlock(!0),createElementBlock(Fragment,null,renderList(unref(filterData),filterSection=>(openBlock(),createElementBlock(Fragment,{key:filterSection.key},[filterSection&&filterSection.groups?withDirectives((openBlock(),createElementBlock(`div`,_hoisted_2$224,[createBaseVNode(`div`,{class:normalizeClass([`filter-icon`,{"has-active-filters":hasActiveFilters(filterSection)}]),onClick:$event=>toggleFilterSectionVisibility(filterSection.key)},[createVNode(bngTooltip_default,{text:_ctx.$tt(filterSection.title)},{default:withCtx(()=>[createVNode(unref(bngIcon_default),{type:filterSection.icon},null,8,[`type`])]),_:2},1032,[`text`])],10,_hoisted_3$198),_cache[0]||=createBaseVNode(`div`,{class:`filter-separator`},null,-1),(openBlock(!0),createElementBlock(Fragment,null,renderList(filterSection.groups,group=>(openBlock(),createElementBlock(Fragment,{key:group.key},[group&&group.elementCount>0?(openBlock(),createElementBlock(`div`,{key:0,class:normalizeClass([`filter-group`,{inactive:!group.visible}]),onClick:$event=>toggleGroupVisibility(group.key)},[createVNode(bngTooltip_default,{text:_ctx.$tt(group.label)+` ×`+group.elementCount},{default:withCtx(()=>[createVNode(unref(bngIcon_default),{type:group.icon||`info`,color:getGroupColor(filterSection,group)},null,8,[`type`,`color`])]),_:2},1032,[`text`])],10,_hoisted_4$170)):createCommentVNode(``,!0)],64))),128))])),[[unref(BngBlur_default),!0]]):createCommentVNode(``,!0)],64))),128))]))}},PoiFilters_default=__plugin_vue_export_helper_default(_sfc_main$304,[[`__scopeId`,`data-v-43aa27ac`]]);const debugLog=(component,message,data)=>{};function useBigMap(){let selectedPoi=ref(null),selectedPoiIds=ref([]),filterData=ref([]),groupData=ref([]),poiData=ref({}),gameMode=ref(``),levelData=ref({title:``}),isPoiListVisible=ref(!1),isDetailsVisible=ref(!1),{events:events$3}=useBridge(),translatedPreheadings=computed(()=>{let preheadings=[];return gameMode.value&&preheadings.push($translate.instant(`ui.playmodes.${gameMode.value}`)),levelData.value?.title&&preheadings.push($translate.instant(levelData.value.title)),preheadings}),currentFilterTitle=computed(()=>$translate.instant(`bigMap.sideMenu.pois`)),getStaticDataFromLua=async()=>{try{poiData.value=await Lua_default.freeroam_vueBigMap.getPoiData()||{};let gameStateResult=await Lua_default.freeroam_vueBigMap.getGameStateInfo();gameStateResult&&(gameMode.value=gameStateResult.gameMode||``,levelData.value=gameStateResult.levelData||{title:``}),poiData.value,gameMode.value}catch(error){console.error(`Error getting static data from Lua:`,error)}},getDynamicDataFromLua=async()=>{try{filterData.value=await Lua_default.freeroam_vueBigMap.getFilters()||[],groupData.value=await Lua_default.freeroam_vueBigMap.getGroups()||[],filterData.value,groupData.value}catch(error){console.error(`Error getting dynamic data from Lua:`,error)}},handleShowPoiDetails=data=>{let poiIds=data?.poiIds||[];if(selectedPoiIds.value=poiIds,poiIds.length===0){selectedPoi.value=null,isDetailsVisible.value=!1;return}let selectedPoiId=poiIds[0];selectedPoiId&&poiData.value[selectedPoiId]?(selectedPoi.value=poiData.value[selectedPoiId],isDetailsVisible.value=!0):(selectedPoi.value=null,isDetailsVisible.value=!1)},toggleGroupVisibility=async groupKey=>{try{let filterIds=[groupKey];await Lua_default.freeroam_vueBigMap.toggleFiltersByIds(filterIds),await getDynamicDataFromLua()}catch(error){console.error(`Error toggling group visibility:`,error)}},toggleFilterSectionVisibility=async filterKey=>{try{await Lua_default.freeroam_vueBigMap.toggleFilterSectionById(filterKey),await getDynamicDataFromLua()}catch(error){console.error(`Error toggling filter visibility:`,error)}},selectPoi=async poiId=>{try{let result=await Lua_default.freeroam_vueBigMap.selectPoiFromList(poiId);result===`success`?poiId?(selectedPoi.value=poiData.value[poiId],isDetailsVisible.value=!0):(selectedPoi.value=null,isDetailsVisible.value=!1):console.error(`Failed to select POI:`,result)}catch(error){console.error(`Error selecting POI:`,error)}};return{selectedPoi,selectedPoiIds,filterData,groupData,poiData,gameMode,levelData,isPoiListVisible,isDetailsVisible,translatedPreheadings,currentFilterTitle,initialize:async()=>{try{await Lua_default.freeroam_vueBigMap.enterBigMap(),await getStaticDataFromLua(),await getDynamicDataFromLua(),events$3.on(`showPoiDetails`,handleShowPoiDetails)}catch(error){console.error(`Error initializing bigmap:`,error)}},cleanup:async()=>{try{await Lua_default.freeroam_vueBigMap.exitBigMap(),events$3.off(`showPoiDetails`)}catch(error){console.error(`Error cleaning up bigmap:`,error)}},selectPoi,showPoiList:()=>{isPoiListVisible.value=!0},hidePoiList:()=>{isPoiListVisible.value=!1,selectedPoi.value&&selectPoi(null)},onHover:async(poiId,active)=>{try{await Lua_default.freeroam_vueBigMap.hoverPoiFromList(poiId,active)}catch(error){console.error(`Error hovering POI:`,error)}},executePoiAction:async actionId=>{try{await Lua_default.freeroam_vueBigMap.executePoiAction(actionId)}catch(error){console.error(`Error executing POI action:`,error)}},toggleGroupVisibility,toggleFilterSectionVisibility,debugLog}}var _hoisted_1$271={class:`bigmap-container`},_hoisted_2$223={class:`bigmap-content`},_hoisted_3$197={class:`bigmap-left-content`},_hoisted_4$169={class:`bigmap-poilist-outline`},_hoisted_5$146={key:0,class:`bigmap-details-outline`},_sfc_main$303={__name:`BigMap`,setup(__props){let store$1=useBigMap(),{isPoiListVisible,isDetailsVisible,translatedPreheadings,currentFilterTitle,onSetRoute,onTeleport,toggleGroupVisibility,initialize,cleanup,debugLog:debugLog$1}=store$1,handleToggleGroupVisibility=groupKey=>{debugLog$1(`BigMap`,`Toggle group visibility`,groupKey),toggleGroupVisibility(groupKey)};return onMounted(()=>{debugLog$1(`BigMap`,`Component mounted, initializing bigmap`),initialize()}),onUnmounted(()=>{debugLog$1(`BigMap`,`Component unmounted, cleaning up bigmap`),cleanup()}),(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$271,[createVNode(unref(bngScreenHeading_default),{class:`bigmap-heading`,preheadings:unref(translatedPreheadings),divider:!0,type:`line`},{default:withCtx(()=>[createTextVNode(toDisplayString(unref(currentFilterTitle)),1)]),_:1},8,[`preheadings`]),createBaseVNode(`div`,_hoisted_2$223,[createBaseVNode(`div`,_hoisted_3$197,[createVNode(PoiFilters_default,{store:unref(store$1),onToggleGroupVisibility:handleToggleGroupVisibility},null,8,[`store`]),createBaseVNode(`div`,_hoisted_4$169,[createVNode(unref(bngDrawer_default),{modelValue:unref(isPoiListVisible),"onUpdate:modelValue":_cache[0]||=$event=>isRef(isPoiListVisible)?isPoiListVisible.value=$event:null,position:`left`,blur:``,header:_ctx.$tt(`bigMap.sideMenu.pois`)},{default:withCtx(()=>[createVNode(PoiList_default,{class:`bigmap-poilist`,store:unref(store$1)},null,8,[`store`])]),_:1},8,[`modelValue`,`header`])])]),_cache[1]||=createBaseVNode(`div`,{class:`bigmap-center-outline`},null,-1),unref(isDetailsVisible)?(openBlock(),createElementBlock(`div`,_hoisted_5$146,[createVNode(PoiDetails_default,{store:unref(store$1),onSetRoute:unref(onSetRoute),onTeleport:unref(onTeleport)},null,8,[`store`,`onSetRoute`,`onTeleport`])])):createCommentVNode(``,!0)])]))}},BigMap_default=__plugin_vue_export_helper_default(_sfc_main$303,[[`__scopeId`,`data-v-e6716bb0`]]),_hoisted_1$270={class:`bigmap-view`},_sfc_main$302={__name:`BigMapView`,setup(__props){return(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$270,[createVNode(BigMap_default)]))}},BigMapView_default=__plugin_vue_export_helper_default(_sfc_main$302,[[`__scopeId`,`data-v-044f4742`]]),routes_default$1=[{path:`/bigmap`,name:`bigmap`,component:BigMapView_default,meta:{uiApps:{shown:!1},infoBar:{visible:!0,showSysInfo:!0}}}],_hoisted_1$269={class:`progress-steps`},_hoisted_2$222={class:`step-container`},_hoisted_3$196={class:`step-header`},_hoisted_4$168={class:`step-number`},_hoisted_5$145={class:`step-icon`},_hoisted_6$125={class:`step-label`},_sfc_main$301={__name:`ProgressSteps`,props:{steps:{type:Array,required:!0,validator:steps=>steps.every(step=>step.label&&typeof step.label==`string`||step.title&&typeof step.title==`string`)},currentStep:{type:Number,required:!0,validator:step=>step>=0}},setup(__props){let props=__props,styles={answeredYes:{class:`answered-yes`,icon:`checkboxOn`},answeredNo:{class:`answered-no`,icon:`missionCheckboxCross`},current:{class:`not-answered current`,icon:`arrowLargeRight`},next:{class:`not-answered`,icon:`checkboxOff`}},steps=computed(()=>props.steps.map((step,idx)=>{let answer=step.isAnswered?step.answerType||`yes`:null,status=`next`;return idx(openBlock(),createElementBlock(`div`,_hoisted_1$269,[createBaseVNode(`div`,_hoisted_2$222,[(openBlock(!0),createElementBlock(Fragment,null,renderList(steps.value,(step,index)=>(openBlock(),createElementBlock(`div`,{key:index,class:normalizeClass([`step`,step.class])},[createBaseVNode(`div`,_hoisted_3$196,[createBaseVNode(`div`,_hoisted_4$168,toDisplayString(index+1),1),step.isLastStep?createCommentVNode(``,!0):(openBlock(),createElementBlock(Fragment,{key:0},[_cache[0]||=createBaseVNode(`div`,{class:`step-connector`},null,-1),createBaseVNode(`div`,_hoisted_5$145,[createVNode(unref(bngIcon_default),{type:step.icon},null,8,[`type`])])],64))]),createBaseVNode(`div`,_hoisted_6$125,toDisplayString(_ctx.$tt(step.label)),1)],2))),128))])]))}},ProgressSteps_default=__plugin_vue_export_helper_default(_sfc_main$301,[[`__scopeId`,`data-v-d5d29cd2`]]);function useWizard(options={}){let{allowSkip=!1,validateSteps=!0}=options,stepRegistry=ref(new Map),currentStepIndex=ref(0),completedSteps=ref(new Set),isFinished=ref(!1),steps=computed(()=>{if(stepRegistry.value.size===0)return[];let res=Array.from(stepRegistry.value.values());for(let step of res)if(!(!step.enabledWhen||step.enabledWhen.length===0)){for(let condition of step.enabledWhen)if(condition.step){let dependencyStep=res.find(s=>s.id===condition.step);if(!dependencyStep)continue;dependencyStep.requiredFor||=[],dependencyStep.requiredFor.includes(step.id)||dependencyStep.requiredFor.push(step.id)}}return res}),registerStep=stepConfig=>stepRegistry.value.set(stepConfig.id,stepConfig),unregisterStep=stepId=>stepRegistry.value.delete(stepId);provide(`registerWizardStep`,registerStep),provide(`unregisterWizardStep`,unregisterStep);let currentStep=computed(()=>steps.value[currentStepIndex.value]||null),isFirstStep=computed(()=>currentStepIndex.value===0),isLastStep=computed(()=>currentStepIndex.value===steps.value.length-1),canGoNext=computed(()=>{if(!validateSteps)return!0;let step=currentStep.value;return!step||!isStepEnabled(step)||step.advanceDisabled?!1:typeof step.validate==`function`?step.validate(step.modelValue||{}):step.type===`choice`&&step.required!==!1?step.modelValue?.choice!==void 0:(step.type,!0)}),isStepEnabled=step=>!step.enabledWhen||step.enabledWhen.length===0?!0:step.enabledWhen.every(condition=>{if(condition.step){let dependencyStepData=steps.value.find(s=>s.id===condition.step)?.modelValue||{};if(condition.value!==void 0)return dependencyStepData?.choice===condition.value||dependencyStepData?.[Object.keys(dependencyStepData)[0]]===condition.value;if(typeof condition.condition==`function`)return condition.condition(dependencyStepData)}return typeof condition.condition==`function`?condition.condition():!0}),canGoBack=computed(()=>!isFirstStep.value),canFinish=computed(()=>validateSteps?isLastStep.value&&canGoNext.value:isLastStep.value),goToStep=index=>{index<=0&&(currentStepIndex.value=0),index>=steps.value.length&&(currentStepIndex.value=steps.value.length-1),currentStepIndex.value=index},nextStep=async()=>{if(await nextTick(),!canGoNext.value)return!1;if(currentStep.value&&completedSteps.value.add(currentStepIndex.value),isLastStep.value)return!0;for(currentStepIndex.value++;currentStepIndex.value=steps.value.length&&(currentStepIndex.value=steps.value.length-1),!0};return{currentStepIndex,currentStep,completedSteps,isFinished,steps,stepRegistry,isFirstStep,isLastStep,canGoNext,canGoBack,canFinish,progress:computed(()=>steps.value.length===0?0:Math.round((currentStepIndex.value+1)/steps.value.length*100)),stepProgress:computed(()=>steps.value.map((step,index)=>{let data=step.modelValue||{},choiceAnalysis=null;if(step.type===`choice`&&step.choices&&data.choice!==void 0){let selectedChoice=step.choices.find(c=>c.value===data.choice),yesChoice=step.choices.find(c=>c.isYes),noChoice=step.choices.find(c=>c.isNo),answerType=null;selectedChoice&&(answerType=selectedChoice.isYes||yesChoice&&selectedChoice.value===yesChoice.value?`yes`:selectedChoice.isNo||noChoice&&selectedChoice.value===noChoice.value?`no`:!yesChoice&&!noChoice?`yes`:step.choices.length===2&&!selectedChoice.isYes&&!selectedChoice.isNo?`no`:`yes`),choiceAnalysis={selectedValue:data.choice,selectedChoice,answerType,hasYesFlag:!!yesChoice,hasNoFlag:!!noChoice}}return{...step,index,isCompleted:completedSteps.value.has(index),isCurrent:index===currentStepIndex.value,isAccessible:index<=currentStepIndex.value,isEnabled:isStepEnabled(step),data,hasData:Object.keys(data).length>0,isAnswered:step.type===`choice`?data.choice!==void 0:Object.keys(data).length>0,answerType:choiceAnalysis?.answerType||null,choiceAnalysis}})),goToStep,nextStep,previousStep:async()=>{if(await nextTick(),!canGoBack.value)return!1;for(currentStepIndex.value--;currentStepIndex.value>=0;){let targetStep=steps.value[currentStepIndex.value];if(isStepEnabled(targetStep)||targetStep.autoSkip===!1)break;currentStepIndex.value--}return currentStepIndex.value<0&&(currentStepIndex.value=0),!0},finish:()=>canFinish.value?(isFinished.value=!0,{success:!0,completedSteps:Array.from(completedSteps.value)}):{success:!1},reset:()=>{currentStepIndex.value=0,completedSteps.value.clear(),isFinished.value=!1},skip:()=>allowSkip?nextStep():!1,isStepEnabled,registerStep,unregisterStep}}var _hoisted_1$268={class:`wizard-container`},_hoisted_2$221={class:`wizard-content`},_hoisted_3$195={class:`wizard-step-content`},_hoisted_4$167={key:0,class:`wizard-validation`},_hoisted_5$144={class:`validation-message`},_hoisted_6$124={class:`wizard-navigation`},_hoisted_7$111={key:2,class:`switch-buttons`};const wizardProps={wizardOptions:{type:Object,default:()=>({})},title:String,preheadings:Array,showDivider:{type:Boolean,default:!0},showProgress:{type:Boolean,default:!0},showBackButton:{type:Boolean,default:!0},allowSkip:{type:Boolean,default:!1},backButtonText:{type:String,default:`ui.common.back`},nextButtonText:{type:String,default:`ui.common.next`},finishButtonText:{type:String,default:`ui.common.finish`},skipButtonText:{type:String,default:`ui.common.skip`},validationMessage:String};var _sfc_main$300={__name:`Wizard`,props:mergeModels(wizardProps,{modelValue:{default:()=>({})},modelModifiers:{}}),emits:mergeModels([`step-change`,`step-complete`,`wizard-finish`,`validation-error`],[`update:modelValue`]),setup(__props,{expose:__expose,emit:__emit}){let props=__props,modelValue=useModel(__props,`modelValue`),emit$1=__emit,{currentStepIndex,currentStep,isFirstStep,isLastStep,canGoNext,canGoBack,canFinish,progress,stepProgress,nextStep:wizardNextStep,previousStep:wizardPreviousStep,skip:wizardSkip,steps,registerStep:originalRegisterStep}=useWizard({...props.wizardOptions,allowSkip:props.allowSkip}),instance$1=getCurrentInstance(),hasCentralizedModel=computed(()=>!!(instance$1&&instance$1.attrs&&`onUpdate:modelValue`in instance$1.attrs));provide(`currentWizardStep`,currentStep),provide(`wizardNext`,()=>nextStep()),provide(`wizardSteps`,steps),provide(`registerWizardStep`,stepConfig=>hasCentralizedModel.value?originalRegisterStep({...stepConfig,get modelValue(){return modelValue.value?.[stepConfig.id]||{}},updateModelValue:newValue=>{modelValue.value={...modelValue.value,[stepConfig.id]:newValue}}}):originalRegisterStep(stepConfig)),provide(`unregisterWizardStep`,stepId=>{if(hasCentralizedModel.value&&props.modelValue[stepId]){let updatedData={...props.modelValue};delete updatedData[stepId],emit$1(`update:modelValue`,updatedData)}});let currentStepChoices=computed(()=>currentStep.value?.choices||[]),getChoiceButtonClass=(choiceValue,selectedChoice)=>selectedChoice?selectedChoice===choiceValue?`answered-selected`:`answered-not-selected`:`unanswered`,handleChoiceClick=choice=>{currentStep.value?.updateModelValue&&(currentStep.value.updateModelValue({...currentStep.value.modelValue,choice:choice.value}),nextTick(()=>!currentStep.value?.advanceDisabled&&nextStep()))},nextStep=()=>{let stepId=currentStep.value?.id,currentData=currentStep.value?.modelValue||{};emit$1(`step-complete`,{stepId,stepIndex:currentStepIndex.value,step:currentStep.value,data:currentData}),wizardNextStep()&&emit$1(`step-change`,{from:currentStepIndex.value-1,to:currentStepIndex.value,step:currentStep.value})},previousStep=()=>{let prevIndex=currentStepIndex.value;wizardPreviousStep()&&emit$1(`step-change`,{from:prevIndex,to:currentStepIndex.value,step:currentStep.value})},skip=()=>{wizardSkip()&&emit$1(`step-complete`,{stepId:currentStep.value?.id,stepIndex:currentStepIndex.value-1,skipped:!0,data:currentStep.value?.modelValue||{}})},handleFinish=()=>{let allStepData={};steps.value.forEach(step=>{step.modelValue&&Object.keys(step.modelValue).length>0&&(allStepData[step.id]=step.modelValue)}),canFinish.value?emit$1(`wizard-finish`,{success:!0,data:allStepData,completedSteps:Array.from({length:steps.value.length},(_,i)=>i)}):emit$1(`validation-error`,{step:currentStep.value,message:`Cannot finish wizard - validation failed`})};return __expose({currentStepIndex,currentStep,progress,stepProgress,nextStep,previousStep,finish:handleFinish,skip,steps}),(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$268,[createBaseVNode(`div`,_hoisted_2$221,[_ctx.title?(openBlock(),createBlock(unref(bngScreenHeading_default),{key:0,preheadings:_ctx.preheadings,"show-divider":_ctx.showDivider},{default:withCtx(()=>[createTextVNode(toDisplayString(_ctx.$tt(_ctx.title)),1)]),_:1},8,[`preheadings`,`show-divider`])):createCommentVNode(``,!0),_ctx.showProgress?(openBlock(),createBlock(unref(bngCard_default),{key:1,class:`wizard-progress-card`},{default:withCtx(()=>[createVNode(ProgressSteps_default,{steps:unref(stepProgress),"current-step":unref(currentStepIndex)},null,8,[`steps`,`current-step`])]),_:1})):createCommentVNode(``,!0),createVNode(unref(bngCard_default),{class:`wizard-main-card`},{buttons:withCtx(()=>[createBaseVNode(`div`,_hoisted_6$124,[_ctx.showBackButton&&!unref(isFirstStep)?(openBlock(),createBlock(unref(bngButton_default),{key:0,disabled:!unref(canGoBack),accent:unref(ACCENTS).secondary,onClick:previousStep},{default:withCtx(()=>[createTextVNode(toDisplayString(_ctx.$tt(_ctx.backButtonText)),1)]),_:1},8,[`disabled`,`accent`])):createCommentVNode(``,!0),_ctx.allowSkip&&!unref(isLastStep)&&unref(currentStep)?.type!==`choice`?(openBlock(),createBlock(unref(bngButton_default),{key:1,accent:unref(ACCENTS).secondary,onClick:skip},{default:withCtx(()=>[createTextVNode(toDisplayString(_ctx.$tt(_ctx.skipButtonText)),1)]),_:1},8,[`accent`])):createCommentVNode(``,!0),_cache[0]||=createBaseVNode(`div`,{class:`spacer`},null,-1),unref(currentStep)?.type===`choice`?(openBlock(),createElementBlock(`div`,_hoisted_7$111,[(openBlock(!0),createElementBlock(Fragment,null,renderList(currentStepChoices.value,choice=>(openBlock(),createBlock(unref(bngButton_default),{key:choice.value,class:normalizeClass(getChoiceButtonClass(choice.value,unref(currentStep)?.modelValue?.choice||null)),accent:unref(ACCENTS).custom,icon:unref(currentStep)?.modelValue?.choice===choice.value?unref(icons).checkmark:null,disabled:unref(currentStep)?.advanceDisabled,onClick:$event=>handleChoiceClick(choice)},{default:withCtx(()=>[createTextVNode(toDisplayString(_ctx.$tt(choice.label)),1)]),_:2},1032,[`class`,`accent`,`icon`,`disabled`,`onClick`]))),128))])):createCommentVNode(``,!0),!unref(isLastStep)&&unref(currentStep)?.type!==`choice`?(openBlock(),createBlock(unref(bngButton_default),{key:3,disabled:!unref(canGoNext),accent:unref(ACCENTS).primary,onClick:nextStep},{default:withCtx(()=>[createTextVNode(toDisplayString(_ctx.$tt(_ctx.nextButtonText)),1)]),_:1},8,[`disabled`,`accent`])):unref(isLastStep)?(openBlock(),createBlock(unref(bngButton_default),{key:4,disabled:!unref(canFinish),accent:unref(ACCENTS).primary,onClick:handleFinish},{default:withCtx(()=>[createTextVNode(toDisplayString(_ctx.$tt(_ctx.finishButtonText)),1)]),_:1},8,[`disabled`,`accent`])):createCommentVNode(``,!0)])]),default:withCtx(()=>[unref(currentStep)?.title?(openBlock(),createBlock(unref(bngCardHeading_default),{key:0,type:`ribbon`},{default:withCtx(()=>[renderSlot(_ctx.$slots,`step-title`,{step:unref(currentStep)},()=>[createTextVNode(toDisplayString(_ctx.$tt(unref(currentStep).title)),1)],!0)]),_:3})):createCommentVNode(``,!0),withDirectives((openBlock(),createElementBlock(`div`,_hoisted_3$195,[renderSlot(_ctx.$slots,`step`,{step:unref(currentStep),stepData:unref(currentStep)?.modelValue,updateStepData:unref(currentStep)?.updateModelValue,stepIndex:unref(currentStepIndex),isFirst:unref(isFirstStep),isLast:unref(isLastStep)},()=>[renderSlot(_ctx.$slots,`default`,{},void 0,!0)],!0),_ctx.validationMessage?(openBlock(),createElementBlock(`div`,_hoisted_4$167,[createBaseVNode(`div`,_hoisted_5$144,toDisplayString(_ctx.validationMessage),1)])):createCommentVNode(``,!0)])),[[unref(BngUiNavScroll_default)]])]),_:3})])]))}},Wizard_default=__plugin_vue_export_helper_default(_sfc_main$300,[[`__scopeId`,`data-v-69c7b9c4`]]),_sfc_main$299={__name:`WizardView`,props:mergeModels({...wizardProps},{modelValue:{},modelModifiers:{}}),emits:mergeModels([`step-change`,`step-complete`,`wizard-finish`,`validation-error`],[`update:modelValue`]),setup(__props,{expose:__expose}){let props=__props,slots=useSlots(),wizardRef=ref(),wizardModel=useModel(__props,`modelValue`);return __expose({wizard:wizardRef,get currentStepIndex(){return wizardRef.value?.currentStepIndex},get currentStep(){return wizardRef.value?.currentStep},get progress(){return wizardRef.value?.progress},get stepProgress(){return wizardRef.value?.stepProgress},get steps(){return wizardRef.value?.steps},nextStep:()=>wizardRef.value?.nextStep(),previousStep:()=>wizardRef.value?.previousStep(),finish:()=>wizardRef.value?.finish(),skip:()=>wizardRef.value?.skip()}),(_ctx,_cache)=>withDirectives((openBlock(),createBlock(unref(layoutSingle_default),{class:`layout-content-full content-center layout-paddings wizard-view`},{default:withCtx(()=>[createVNode(Wizard_default,mergeProps({ref_key:`wizardRef`,ref:wizardRef},props,{modelValue:wizardModel.value,"onUpdate:modelValue":_cache[0]||=$event=>wizardModel.value=$event,onStepChange:_cache[1]||=$event=>_ctx.$emit(`step-change`,$event),onStepComplete:_cache[2]||=$event=>_ctx.$emit(`step-complete`,$event),onWizardFinish:_cache[3]||=$event=>_ctx.$emit(`wizard-finish`,$event),onValidationError:_cache[4]||=$event=>_ctx.$emit(`validation-error`,$event)}),createSlots({_:2},[renderList(unref(slots),(slot,name)=>({name,fn:withCtx(props$1=>[renderSlot(_ctx.$slots,name,normalizeProps(guardReactiveProps(props$1)),void 0,!0)])}))]),1040,[`modelValue`])]),_:3})),[[unref(BngBlur_default)]])}},WizardView_default=__plugin_vue_export_helper_default(_sfc_main$299,[[`__scopeId`,`data-v-e47281c4`]]),_hoisted_1$267={key:0,class:`wizard-summary`},_sfc_main$298={__name:`WizardSummary`,props:{custom:{type:Array,default:()=>[],validator:items$2=>items$2.every(item=>item.label&&item.value!==void 0)},replace:{type:Boolean,default:!1}},setup(__props){let props=__props,steps=inject(`wizardSteps`,ref([])),summaryItems=computed(()=>{let customItems=props.custom.map(item=>({stepId:uniqueId(),title:item.label,selectedLabel:item.value,hasSelection:!item.disabled}));if(props.replace)return customItems;let stepsList=steps.value||[],automaticItems=[];return Array.isArray(stepsList)&&(automaticItems=stepsList.filter(step=>step.type===`choice`&&step.choices&&step.choices.length>0).map(step=>{let selectedChoice=step.modelValue?.choice,choiceOption=step.choices.find(choice=>choice.value===selectedChoice);return{stepId:step.id,title:step.title,selectedLabel:choiceOption?.label||null,hasSelection:!!selectedChoice}}).filter(item=>item.hasSelection)),[...automaticItems,...customItems]});return(_ctx,_cache)=>summaryItems.value.length>0?(openBlock(),createElementBlock(`div`,_hoisted_1$267,[(openBlock(!0),createElementBlock(Fragment,null,renderList(summaryItems.value,item=>(openBlock(),createElementBlock(`div`,{key:item.stepId,class:`summary-item`},[createBaseVNode(`strong`,null,toDisplayString(_ctx.$tt(item.title))+`:`,1),createBaseVNode(`span`,{class:normalizeClass({enabled:item.hasSelection,disabled:!item.hasSelection})},toDisplayString(_ctx.$tt(item.selectedLabel||`ui.common.unknown`)),3)]))),128))])):createCommentVNode(``,!0)}},WizardSummary_default=__plugin_vue_export_helper_default(_sfc_main$298,[[`__scopeId`,`data-v-69c45791`]]),_hoisted_1$266={key:0,class:`wizard-step-container`},_hoisted_2$220={key:0,class:`step-description`},_hoisted_3$194=[`innerHTML`],_hoisted_4$166={class:`step-content`},_hoisted_5$143={key:0,class:`wizard-choice-step`},_hoisted_6$123={key:1,class:`wizard-form-step`},_hoisted_7$110={key:2,class:`wizard-confirmation-step`},_hoisted_8$93={key:3,class:`wizard-custom-step`},_hoisted_9$83={class:`custom-placeholder`},_sfc_main$297={__name:`WizardStep`,props:mergeModels({id:{type:String,required:!0},title:String,description:String,type:{type:String,default:`custom`,validator:value=>[`choice`,`form`,`confirmation`,`custom`].includes(value)},autoSkip:{type:Boolean,default:!0},advanceDisabled:{type:Boolean,default:!1},advanceDelay:{type:Number,default:300},required:{type:Boolean,default:!0},validator:{type:Function,default:null},enabledWhen:{type:Array,default:()=>[]},choices:{type:Array,default:()=>[]},component:{type:[String,Object],default:null},componentProps:{type:Object,default:()=>({})}},{modelValue:{default:()=>({})},modelModifiers:{}}),emits:[`update:modelValue`],setup(__props,{expose:__expose}){let props=__props,modelValue=useModel(__props,`modelValue`),registerStep=inject(`registerWizardStep`,null),unregisterStep=inject(`unregisterWizardStep`,null),currentStep=inject(`currentWizardStep`,null),slots=useSlots(),stepContext={stepId:props.id,stepType:props.type};provide(`wizardStepContext`,stepContext),__expose({stepId:props.id,stepContext});let isCurrentStep=computed(()=>currentStep?.value?.id===props.id);return onMounted(()=>{registerStep?.({id:props.id,title:props.title,description:props.description,type:props.type,autoSkip:props.autoSkip,get advanceDisabled(){return props.advanceDisabled},advanceDelay:props.advanceDelay,required:props.required,enabledWhen:props.enabledWhen,validate:props.validator,component:props.component,componentProps:props.componentProps,choices:props.choices,get modelValue(){return modelValue.value},updateModelValue:value=>{modelValue.value=value},hasDefaultSlot:!!slots.default,hasDescriptionSlot:!!slots.description})}),onUnmounted(()=>{unregisterStep?.(props.id)}),(_ctx,_cache)=>isCurrentStep.value?(openBlock(),createElementBlock(`div`,_hoisted_1$266,[__props.description||_ctx.$slots.description?(openBlock(),createElementBlock(`div`,_hoisted_2$220,[renderSlot(_ctx.$slots,`description`,{},()=>[__props.description?(openBlock(),createElementBlock(`div`,{key:0,innerHTML:__props.description},null,8,_hoisted_3$194)):createCommentVNode(``,!0)],!0)])):createCommentVNode(``,!0),createBaseVNode(`div`,_hoisted_4$166,[__props.type===`choice`?(openBlock(),createElementBlock(`div`,_hoisted_5$143,[renderSlot(_ctx.$slots,`default`,{},void 0,!0)])):__props.type===`form`?(openBlock(),createElementBlock(`div`,_hoisted_6$123,[renderSlot(_ctx.$slots,`default`,{},()=>[_cache[0]||=createBaseVNode(`div`,{class:`form-placeholder`},[createBaseVNode(`p`,null,`Add your form content here using BngInput, BngDropdown, etc.`),createBaseVNode(`p`,{class:`form-note`},`Use v-model bindings to connect to step data.`)],-1)],!0)])):__props.type===`confirmation`?(openBlock(),createElementBlock(`div`,_hoisted_7$110,[renderSlot(_ctx.$slots,`default`,{},()=>[createVNode(WizardSummary_default)],!0)])):(openBlock(),createElementBlock(`div`,_hoisted_8$93,[renderSlot(_ctx.$slots,`default`,{},()=>[createBaseVNode(`div`,_hoisted_9$83,[createBaseVNode(`p`,null,`Custom step content for: `+toDisplayString(__props.title),1),_cache[1]||=createBaseVNode(`p`,{class:`custom-note`},`Add your custom content in the WizardStep default slot`,-1)])],!0)]))])])):createCommentVNode(``,!0)}},WizardStep_default=__plugin_vue_export_helper_default(_sfc_main$297,[[`__scopeId`,`data-v-ede4abc3`]]),_hoisted_1$265={class:`description`},_hoisted_2$219={class:`image-section`},_hoisted_3$193={class:`image-row`},_hoisted_4$165=[`src`],_hoisted_5$142=[`src`],_sfc_main$296={__name:`ButtonLayoutView`,setup(__props){let settings$1=useSettings(),handleFinish=async()=>{await settings$1.apply({showedInputLayoutPopupV37:!0}),window.bngVue.gotoGameState(`menu.mainmenu`)},goToControls=async()=>{await settings$1.apply({showedInputLayoutPopupV37:!0}),window.bngVue.gotoGameState(`menu.options.controls.bindings`)};return onMounted(async()=>{await settings$1.waitForData()}),(_ctx,_cache)=>(openBlock(),createBlock(unref(WizardView_default),{title:`Input Changes`,class:`wizard-view`,"show-progress":!1,"finish-button-text":`ui.common.continue`,onWizardFinish:handleFinish},{default:withCtx(()=>[createVNode(unref(WizardStep_default),{id:`buttonLayout`,title:`Extended Modifier Buttons`,type:`confirmation`},{default:withCtx(()=>[withDirectives((openBlock(),createElementBlock(`div`,_hoisted_1$265,[_cache[1]||=createBaseVNode(`p`,null,` We updated the default button layout for Xbox and Playstation controllers using modifier buttons. Below you see the new default layout. `,-1),_cache[2]||=createBaseVNode(`p`,null,[createBaseVNode(`strong`,{class:`warning-text`},`If you made any changes to the default layout on Xbox or Playstation, we suggest you review your current layout and then either edit it or reset to the default if needed.`)],-1),createVNode(unref(bngButton_default),{accent:unref(ACCENTS).primary,onClick:goToControls},{default:withCtx(()=>[..._cache[0]||=[createTextVNode(` Go to Controls `,-1)]]),_:1},8,[`accent`])])),[[unref(BngUiNavScroll_default)]]),createBaseVNode(`div`,_hoisted_2$219,[_cache[3]||=createBaseVNode(`h4`,null,`New Button Layout`,-1),createBaseVNode(`div`,_hoisted_3$193,[createBaseVNode(`img`,{src:unref(getAssetURL)(`images/buttonLayout1.jpg`),alt:`Button Layout`,class:`button-layout-image`},null,8,_hoisted_4$165),createBaseVNode(`img`,{src:unref(getAssetURL)(`images/buttonLayout2.jpg`),alt:`Button Layout`,class:`button-layout-image`},null,8,_hoisted_5$142)])])]),_:1})]),_:1}))}},ButtonLayoutView_default=__plugin_vue_export_helper_default(_sfc_main$296,[[`__scopeId`,`data-v-ff98d0e0`]]),routes_default$2=[{path:`/buttonLayout`,name:`buttonLayout`,component:ButtonLayoutView_default,meta:{infoBar:{visible:!0,showSysInfo:!0},uiApps:{shown:!1}}}],_hoisted_1$264={class:`left`},_hoisted_2$218={class:`branch-icon-assembly`},_hoisted_3$192=[`innerHTML`],_hoisted_4$164=[`innerHTML`],_sfc_main$295={__name:`BranchSkillProgressBar`,props:{skill:Object,mode:{type:String,default:`long`,validator:value=>[`long`,`short`,`simple`,`with-value-label`].includes(value)},showLevel:{type:Boolean,default:!1},showLockedIcon:{type:Boolean,default:!1},isMainProgress:{type:Boolean,default:!1}},setup(__props){let props=__props,headerLeft=computed(()=>props.skill.name),headerRightLevelOrStars=computed(()=>props.skill.isInDevelopment?``:props.skill.unlocked?(props.showLevel&&props.skill.unlocked,props.skill.showProgressAsStars?$translate.contextTranslate({txt:`ui.career.slashStars`,context:{cur:props.skill.value,max:props.skill.max}}):props.skill.levelLabel?props.skill.levelLabel:props.skill.level?$translate.contextTranslate({txt:`ui.career.lvlLabel`,context:{lvl:props.skill.level}}):`Level ${props.skill.level}`):$translate.contextTranslate(`ui.career.locked`)),value=computed(()=>props.skill.max===-1?1:props.skill.value-props.skill.min),max$1=computed(()=>props.skill.max===-1?1:props.skill.max-props.skill.min),valueLabelFormat=computed(()=>{if(props.skill.isInDevelopment)return $translate.contextTranslate(`ui.career.inDevelopment`);if(!props.skill.unlocked)return $translate.contextTranslate(`ui.career.locked`);if(props.mode===`simple`)return props.skill.showProgressAsStars?$translate.contextTranslate({txt:`ui.career.slashStars`,context:{cur:value.value,max:max$1.value}}):$translate.contextTranslate({txt:`ui.career.lvlLabel`,context:{lvl:props.skill.level}});let unit=props.skill.showProgressAsStars?`Stars`:`XP`;return props.skill.max===-1?$translate.contextTranslate({txt:`ui.career.just`+unit,context:{cur:value.value}}):$translate.contextTranslate({txt:`ui.career.slashXP`,context:{cur:value.value,max:max$1.value}})}),skillIcon=computed(()=>props.skill.isInDevelopment?icons.roadblockL:props.skill.unlocked?props.skill.icon||`info`:`lockClosed`),belowValueLabelFormat=computed(()=>{if(!props.skill.unlocked&&props.skill.lockedReason)return $translate.contextTranslate(props.skill.lockedReason?.label||`ui.career.locked`);if(props.skill.isInDevelopment)return $translate.contextTranslate(`ui.career.inDevelopment`);if(props.skill.isMaxLevel)return`​`;if(!props.skill.showProgressAsStars)return $translate.contextTranslate({txt:`ui.career.justXP`,context:{cur:props.skill.value}})}),branchBackgroundStyle=computed(()=>{let color=props.skill.accentColor;return color?color.startsWith(`--`)?{"background-color":`var(${color})`}:color.startsWith(`#`)?{"background-color":color}:{"background-color":`rgb(${color})`}:{"background-color":`#555555`}});return(_ctx,_cache)=>__props.mode===`simple`?(openBlock(),createElementBlock(`div`,{key:0,class:normalizeClass([`simple-progress`,{"is-locked":!props.skill.unlocked}])},[createBaseVNode(`div`,_hoisted_1$264,[createBaseVNode(`div`,_hoisted_2$218,[!__props.skill.isSkill&&!__props.skill.isBranch?(openBlock(),createElementBlock(`div`,{key:0,class:`branch-background`,style:normalizeStyle(branchBackgroundStyle.value)},null,4)):createCommentVNode(``,!0),createVNode(unref(bngIcon_default),{type:skillIcon.value,class:`assembly-icon`},null,8,[`type`])]),createTextVNode(` `+toDisplayString(_ctx.$ctx_t(headerLeft.value)),1)]),createBaseVNode(`div`,{class:`right`,innerHTML:valueLabelFormat.value},null,8,_hoisted_3$192)],2)):(openBlock(),createElementBlock(`div`,{key:1,class:normalizeClass([`flex-column`,{"is-locked":!props.skill.unlocked}])},[createVNode(unref(bngProgressBar_default),{class:normalizeClass([`stat-progress-bar`,{short:__props.mode===`short`,isMainProgress:__props.isMainProgress}]),headerLeft:_ctx.$ctx_t(headerLeft.value),headerRight:_ctx.$ctx_t(headerRightLevelOrStars.value),value:value.value,max:max$1.value+.001,showValueLabel:!0,valueLabelFormat:``,valueColor:`#eeeeee`},null,8,[`class`,`headerLeft`,`headerRight`,`value`,`max`]),!props.skill.unlocked&&__props.mode===`with-value-label`&&props.showLockedIcon?(openBlock(),createElementBlock(Fragment,{key:0},[],64)):createCommentVNode(``,!0),__props.mode===`with-value-label`?(openBlock(),createElementBlock(`div`,{key:1,class:`below-progress-bar`,innerHTML:belowValueLabelFormat.value},null,8,_hoisted_4$164)):createCommentVNode(``,!0)],2))}},BranchSkillProgressBar_default=__plugin_vue_export_helper_default(_sfc_main$295,[[`__scopeId`,`data-v-2f641a65`]]);function hexToRgb(hex){hex=hex.replace(/^#/,``);let bigint=parseInt(hex,16);return`${bigint>>16&255}, ${bigint>>8&255}, ${bigint&255}`}function getBranchColorStyle({color,accentColor}){let style={};color&&(color.startsWith(`#`)?style[`--branch-color`]=hexToRgb(color):color.startsWith(`var(--`)&&(style[`--branch-color`]=color));let accent=accentColor||color;return accent&&(accent.startsWith(`#`)?style[`--branch-accent-color`]=hexToRgb(accent):accent.startsWith(`var(--`)&&(style[`--branch-accent-color`]=accent)),style}function getIconBackgroundStyle(color){return color?color.startsWith(`--`)?{"background-color":`var(${color})`}:color.startsWith(`#`)?{"background-color":color}:{"background-color":`rgb(${color})`}:{"background-color":`#555555`}}var _hoisted_1$263={class:`branch-details`},_hoisted_2$217={class:`backdrop`},_hoisted_3$191={class:`skill-levels-wrapper`},_hoisted_4$163={key:0,class:`branch-name-container`},_hoisted_5$141={key:2,class:`branch-footer`},_hoisted_6$122={key:0,class:`branch-description`},_hoisted_7$109={key:0,class:`branch-description`},_hoisted_8$92={class:`branch-footer-content`},_hoisted_9$82={class:`certification-text`},_hoisted_10$72={class:`status`},_hoisted_11$65={class:`unlock-info-row`},_hoisted_12$53={class:`icon-box`},_hoisted_13$46={class:`certification-text`},_sfc_main$294={__name:`BranchSkillCard`,props:{branchKey:String,displayMode:{type:String,default:`card`}},emits:[`openBranchPage`],setup(__props,{emit:__emit}){let props=__props,emit$1=__emit,branchData=ref();computed(()=>branchData.value&&`url(${getAssetURL(branchData.value.icon)})`);let branchColor=computed(()=>{let color=branchData.value&&branchData.value.color;return color?color.startsWith(`#`)?hexToRgb(color):color.startsWith(`var(--`)?`${color}`:`transparent`:``}),branchAccentColor=computed(()=>{let color=branchData.value&&(branchData.value.accentColor||branchData.value.color);return color?color.startsWith(`#`)?hexToRgb(color):color.startsWith(`var(--`)?`${color}`:`transparent`:``}),branchIconType=computed(()=>branchData.value&&branchData.value.isInDevelopment?icons.roadblockL:branchData.value&&branchData.value.unlocked?icons[branchData.value.glyphIcon]:icons.lockClosed),isHalf=computed(()=>{if(!branchData.value)return!1;let hasSkills=branchData.value.skills&&branchData.value.skills.length>0,hasDescription=branchData.value.shortDescription;return!hasSkills&&!hasDescription}),safeArray=arr=>Array.isArray(arr)?arr:[],openBranchPage=branchKey=>emit$1(`openBranchPage`,branchKey);function setup$3(data){branchData.value=data,branchData.value.skills=safeArray(data.skills)}let formatColor=color=>color?color.startsWith(`#`)?hexToRgb(color):color.startsWith(`var(--`)?`${color}`:`rgb(255, 255, 255)`:``;return onMounted(async()=>{setup$3(await Lua_default.career_modules_branches_landing.getBranchSkillCardData(props.branchKey))}),(_ctx,_cache)=>branchData.value?(openBlock(),createBlock(unref(bngCard_default),{key:0,class:normalizeClass([`branch-skill-card`,{"row-mode":__props.displayMode===`row`,locked:!branchData.value.unlocked,half:isHalf.value}]),onClick:_cache[0]||=$event=>openBranchPage(__props.branchKey),style:normalizeStyle({"--branch-color":branchColor.value,"--branch-accent-color":branchAccentColor.value})},{default:withCtx(()=>[createBaseVNode(`div`,_hoisted_1$263,[_cache[2]||=createBaseVNode(`div`,{class:`indicator left`},null,-1),_cache[3]||=createBaseVNode(`div`,{class:`indicator right`},null,-1),branchData.value.isDomain?createCommentVNode(``,!0):(openBlock(),createElementBlock(`div`,{key:0,class:normalizeClass([`branch-progress`,{"in-development":branchData.value.isInDevelopment}])},[branchData.value.isDomain?createCommentVNode(``,!0):(openBlock(),createElementBlock(`div`,{key:0,class:normalizeClass([`badge`,{"row-badge":__props.displayMode===`row`}])},[createBaseVNode(`div`,_hoisted_2$217,toDisplayString(branchData.value.value.color),1),createVNode(unref(bngIcon_default),{class:`icon-branch`,type:branchIconType.value},null,8,[`type`])],2))],2)),branchData.value.isDomain?(openBlock(),createBlock(unref(aspectRatio_default),{key:1,"external-image":branchData.value.cover,ratio:`16:9`,class:`image-container aspect-ratio`},null,8,[`external-image`])):createCommentVNode(``,!0),createBaseVNode(`div`,_hoisted_3$191,[__props.displayMode===`row`?(openBlock(),createElementBlock(`div`,_hoisted_4$163,[branchData.value?(openBlock(),createBlock(BranchSkillProgressBar_default,{key:0,class:`main-stat-progress-bar`,skill:branchData.value,showLevel:!0,mode:(branchData.value.isInDevelopment&&isHalf.value,``)},null,8,[`skill`,`mode`])):createCommentVNode(``,!0)])):createCommentVNode(``,!0)]),isHalf.value?createCommentVNode(``,!0):(openBlock(),createElementBlock(`div`,_hoisted_5$141,[branchData.value.isInDevelopment?(openBlock(),createElementBlock(`div`,_hoisted_6$122,toDisplayString(_ctx.$ctx_t(`ui.career.inDevelopment`)),1)):(openBlock(),createElementBlock(Fragment,{key:1},[branchData.value.shortDescription?(openBlock(),createElementBlock(`div`,_hoisted_7$109,toDisplayString(_ctx.$ctx_t(branchData.value.shortDescription)),1)):createCommentVNode(``,!0),createBaseVNode(`div`,_hoisted_8$92,[branchData.value.skills?(openBlock(!0),createElementBlock(Fragment,{key:0},renderList(branchData.value.skills,skill=>(openBlock(),createElementBlock(`div`,null,[branchData.value?(openBlock(),createBlock(BranchSkillProgressBar_default,{key:0,skill,mode:`simple`},null,8,[`skill`])):createCommentVNode(``,!0)]))),256)):createCommentVNode(``,!0),(openBlock(!0),createElementBlock(Fragment,null,renderList(branchData.value.certifications,certification=>(openBlock(),createElementBlock(`div`,{class:normalizeClass([`certification-container`,certification.status])},[createVNode(unref(bngIcon_default),{type:unref(icons).badgeRoundStar,style:normalizeStyle({color:certification.status===`completed`?`white`:certification.status===`available`?`rgba(255, 255, 255, 0.6)`:`rgba(255, 255, 255, 0.5)`})},null,8,[`type`,`style`]),createBaseVNode(`div`,_hoisted_9$82,[createTextVNode(toDisplayString(_ctx.$ctx_t(`ui.career.certification.name`))+` `,1),createBaseVNode(`span`,_hoisted_10$72,toDisplayString(_ctx.$ctx_t(certification.statusLabel)),1)])],2))),256)),branchData.value.unlockInfos?(openBlock(),createElementBlock(Fragment,{key:1},[_cache[1]||=createBaseVNode(`div`,{class:`unlock-info-title`},`Required Certifications:`,-1),createBaseVNode(`div`,_hoisted_11$65,[(openBlock(!0),createElementBlock(Fragment,null,renderList(branchData.value.unlockInfos,unlockInfo=>(openBlock(),createElementBlock(`div`,{class:normalizeClass([`unlock-info-item`,unlockInfo.status]),style:normalizeStyle({"--unlock-color":formatColor(unlockInfo.color?unlockInfo.color:`var(--bng-cool-gray-500-rgb)`)})},[createBaseVNode(`div`,_hoisted_12$53,[createVNode(unref(bngIcon_default),{type:unref(icons).badgeRoundStar,class:`certification-icon`},null,8,[`type`])]),createBaseVNode(`div`,_hoisted_13$46,toDisplayString(_ctx.$ctx_t(unlockInfo.label)),1)],6))),256))])],64)):createCommentVNode(``,!0)])],64))]))])]),_:1},8,[`class`,`style`])):createCommentVNode(``,!0)}},BranchSkillCard_default=__plugin_vue_export_helper_default(_sfc_main$294,[[`__scopeId`,`data-v-4321db2f`]]),_hoisted_1$262={class:`condensed`},_hoisted_2$216={key:3,class:`dev-icon-container`},_hoisted_3$190={class:`main-info`},_hoisted_4$162={key:1,class:`stars`},_sfc_main$293={__name:`MissionCard`,props:{mission:Object,isSkeleton:Boolean,showStartableIcons:Boolean},emits:[`clicked`],setup(__props,{emit:__emit}){let props=__props,emit$1=__emit,clicked=()=>emit$1(`clicked`,props.mission),backgroundImageStyle=computed(()=>({backgroundImage:`url(${props.mission.thumbnail})`,maskImage:`linear-gradient(to left, rgba(0, 0, 0, ${props.mission.startable?.75:.2}) 50%, rgba(0, 0, 0, 0.1) 100%)`,filter:props.mission.startable?`none`:`grayscale(100%)`})),iconType$1=computed(()=>props.isSkeleton?icons.medal:icons[props.mission.icon]||icons.medal),iconColor=computed(()=>props.isSkeleton||!props.mission.startable?`var(--bng-cool-gray-600)`:`#fff`),showStartableIcons=computed(()=>!props.isSkeleton&&props.showStartableIcons);return(_ctx,_cache)=>(openBlock(),createBlock(unref(bngCard_default),{"bng-nav-item":``,onClick:clicked,class:normalizeClass({"card-wrapper":!0,"click-startable":__props.mission&&__props.mission.startable})},{default:withCtx(()=>[createBaseVNode(`div`,_hoisted_1$262,[__props.isSkeleton?createCommentVNode(``,!0):(openBlock(),createBlock(unref(aspectRatio_default),{key:0,class:`image`,style:normalizeStyle(backgroundImageStyle.value)},null,8,[`style`])),!__props.isSkeleton&&!__props.mission.startable?(openBlock(),createBlock(unref(bngIcon_default),{key:1,class:`locked-icon`,type:unref(icons).lockClosed,color:iconColor.value},null,8,[`type`,`color`])):createCommentVNode(``,!0),!__props.isSkeleton&&showStartableIcons.value?(openBlock(),createElementBlock(Fragment,{key:2},[__props.mission.canStartFromProgressScreen&&__props.mission.startable?(openBlock(),createBlock(unref(bngIcon_default),{key:0,class:`locked-icon`,type:unref(icons).play,color:iconColor.value},null,8,[`type`,`color`])):createCommentVNode(``,!0),!__props.mission.canStartFromProgressScreen&&__props.mission.startable?(openBlock(),createBlock(unref(bngIcon_default),{key:1,class:`locked-icon`,type:unref(icons).mapPoint,color:iconColor.value},null,8,[`type`,`color`])):createCommentVNode(``,!0)],64)):createCommentVNode(``,!0),!__props.isSkeleton&&__props.mission.devMission?(openBlock(),createElementBlock(`div`,_hoisted_2$216,[createVNode(unref(bngIcon_default),{class:`dev-icon`,type:unref(icons).bug,color:`white`},null,8,[`type`]),_cache[0]||=createBaseVNode(`div`,{class:`dev-text`},` DEV MISSION `,-1)])):createCommentVNode(``,!0),_cache[1]||=createBaseVNode(`div`,{class:`highlight-marker`},null,-1),createVNode(unref(bngIcon_default),{class:`mission-icon`,type:iconType$1.value,color:iconColor.value},null,8,[`type`,`color`]),createVNode(unref(bngBinding_default),{class:`input-icon`,"ui-event":`ok`,controller:``}),createBaseVNode(`div`,_hoisted_3$190,[__props.isSkeleton?createCommentVNode(``,!0):(openBlock(),createElementBlock(`div`,{key:0,class:normalizeClass([`heading`,{locked:!__props.mission.startable}])},toDisplayString(_ctx.$tt(__props.mission.label)),3)),!__props.isSkeleton&&__props.mission.startable&&__props.mission.formattedProgress?(openBlock(),createElementBlock(`div`,_hoisted_4$162,[__props.mission.formattedProgress.unlockedStars&&__props.mission.formattedProgress.unlockedStars.totalDefaultStarCount?(openBlock(),createBlock(unref(bngMainStars_default),{key:0,individualStars:__props.mission.formattedProgress.unlockedStars.defaults,class:`main-stars`,scale:.6},null,8,[`individualStars`])):createCommentVNode(``,!0),__props.mission.formattedProgress.unlockedStars&&__props.mission.formattedProgress.unlockedStars.totalBonusStarCount>0?(openBlock(),createBlock(unref(bngMainStars_default),{key:1,individualStars:__props.mission.formattedProgress.unlockedStars.bonus,class:`bonus-stars`,scale:.6},null,8,[`individualStars`])):createCommentVNode(``,!0)])):createCommentVNode(``,!0)])])]),_:1},8,[`class`]))}},MissionCard_default=__plugin_vue_export_helper_default(_sfc_main$293,[[`__scopeId`,`data-v-52ea67db`]]),_hoisted_1$261={class:`rewards-pills-container`},_sfc_main$292={__name:`RewardPill`,props:{icon:String,attributeKey:String,rewardAmount:Number,highlight:Boolean,hideNumbers:Boolean,backgroundColor:{type:String,default:`rgba(var(--bng-cool-gray-900-rgb), 0.5)`}},setup(__props){return(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$261,[createBaseVNode(`div`,{class:`pill`,style:normalizeStyle({backgroundColor:__props.backgroundColor,filter:__props.highlight?`brightness(350%)`:``})},[createVNode(unref(bngUnit_default),mergeProps({[__props.icon?`beamXP`:__props.attributeKey]:__props.rewardAmount},{options:__props.hideNumbers?{formatter:x=>null}:null,iconType:__props.icon?unref(icons)[__props.icon]:null,formatter:__props.attributeKey}),null,16,[`options`,`iconType`,`formatter`])],4)]))}},RewardPill_default=__plugin_vue_export_helper_default(_sfc_main$292,[[`__scopeId`,`data-v-7719e2fc`]]),_hoisted_1$260={class:`rewards-pills-container`},_sfc_main$291={__name:`RewardsPills`,props:{rewards:Object,hideNumbers:Boolean,negativeBackground:{type:Boolean,default:!0}},setup(__props){return(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$260,[(openBlock(!0),createElementBlock(Fragment,null,renderList(__props.rewards,reward=>(openBlock(),createBlock(RewardPill_default,{icon:reward.icon,hideNumbers:__props.hideNumbers,attributeKey:reward.attributeKey,rewardAmount:reward.rewardAmount,highlight:reward.highlight,backgroundColor:__props.negativeBackground&&reward.rewardAmount<0?`rgba(var(--bng-add-red-700-rgb), 0.5)`:void 0},null,8,[`icon`,`hideNumbers`,`attributeKey`,`rewardAmount`,`highlight`,`backgroundColor`]))),256))]))}},RewardsPills_default=__plugin_vue_export_helper_default(_sfc_main$291,[[`__scopeId`,`data-v-40e5103d`]]),_hoisted_1$259={key:0,class:`animated-border claimable`},_hoisted_2$215={key:1,class:`complete`},_hoisted_3$189={key:0,class:`complete`},_hoisted_4$161={key:1,class:`complete-badge`},_hoisted_5$140={key:2,class:`step`},_hoisted_6$121={key:3,class:`step`},_hoisted_7$108={class:`content`},_hoisted_8$91={class:`heading`},_hoisted_9$81={key:0,class:`middle-content`},_hoisted_10$71={key:1,class:`middle-content`},_hoisted_11$64={key:3,class:`progress`},_sfc_main$290={__name:`MilestoneCard`,props:{milestone:Object,isCondensed:Boolean},emits:[`claim`],setup(__props,{emit:__emit}){let props=__props,emit$1=__emit,claimMilestone=()=>{console.log(`claimMilestone`,props.milestone),props.milestone.claimable&&(emit$1(`claim`,props.milestone),console.log(props.milestone))},milestoneColor=computed(()=>{let color=props.milestone.color;return color?color.startsWith(`#`)?hexToRgb$1(color):color.startsWith(`var(--`)?`${color}`:`transparent`:``});function hexToRgb$1(hex){return`${parseInt(hex.slice(1,3),16)}, ${parseInt(hex.slice(3,5),16)}, ${parseInt(hex.slice(5,7),16)}`}return(_ctx,_cache)=>withDirectives((openBlock(),createElementBlock(`div`,{"bng-nav-item":``,onClick:claimMilestone,class:`condensed`},[__props.milestone.claimable?(openBlock(),createElementBlock(`div`,_hoisted_1$259)):createCommentVNode(``,!0),__props.milestone.completed?(openBlock(),createElementBlock(`div`,_hoisted_2$215)):createCommentVNode(``,!0),createVNode(unref(aspectRatio_default),{class:`image`,style:normalizeStyle({backgroundColor:`rgb(`+milestoneColor.value+`)`}),ratio:`21:9`},{default:withCtx(()=>[__props.milestone.completed?(openBlock(),createElementBlock(`div`,_hoisted_3$189)):createCommentVNode(``,!0),__props.milestone.completed?(openBlock(),createElementBlock(`div`,_hoisted_4$161,[createVNode(unref(bngIcon_default),{class:`glyph small`,type:unref(icons).checkmark},null,8,[`type`])])):createCommentVNode(``,!0),createVNode(unref(bngIcon_default),{class:`glyph`,type:unref(icons)[__props.milestone.icon]},null,8,[`type`]),__props.milestone.step!==void 0&&__props.milestone.maxStep!==void 0?(openBlock(),createElementBlock(`div`,_hoisted_5$140,toDisplayString(__props.milestone.step)+`/`+toDisplayString(__props.milestone.maxStep),1)):createCommentVNode(``,!0),__props.milestone.step!==void 0&&__props.milestone.maxStep===void 0?(openBlock(),createElementBlock(`div`,_hoisted_6$121,toDisplayString(__props.milestone.step),1)):createCommentVNode(``,!0)]),_:1},8,[`style`]),createBaseVNode(`div`,_hoisted_7$108,[createBaseVNode(`div`,_hoisted_8$91,toDisplayString(_ctx.$ctx_t(__props.milestone.label)),1),__props.milestone.description?(openBlock(),createElementBlock(`div`,_hoisted_9$81,toDisplayString(_ctx.$ctx_t(__props.milestone.description)),1)):createCommentVNode(``,!0),__props.milestone.rewards?(openBlock(),createElementBlock(`div`,_hoisted_10$71,[createVNode(RewardsPills_default,{rewards:__props.milestone.rewards},null,8,[`rewards`])])):createCommentVNode(``,!0),__props.milestone.completed?(openBlock(),createBlock(unref(bngProgressBar_default),{key:2,value:1,max:1,min:0,valueLabelFormat:`Complete!`,class:`progress`})):createCommentVNode(``,!0),__props.milestone.progress?(openBlock(),createElementBlock(`div`,_hoisted_11$64,[(openBlock(!0),createElementBlock(Fragment,null,renderList(__props.milestone.progress,prog=>(openBlock(),createBlock(unref(bngProgressBar_default),{class:normalizeClass({claimProgressBar:__props.milestone.claimable}),value:prog.currValue,max:prog.maxValue,min:prog.minValue,valueLabelFormat:__props.milestone.claimable?`Click to claim!`:_ctx.$ctx_t(prog.label)},null,8,[`class`,`value`,`max`,`min`,`valueLabelFormat`]))),256))])):createCommentVNode(``,!0)])])),[[unref(BngOnUiNav_default),void 0,`ok`,{focusRequired:!0,asMouse:!0}]])}},MilestoneCard_default=__plugin_vue_export_helper_default(_sfc_main$290,[[`__scopeId`,`data-v-8fc3424a`]]),_hoisted_1$258={class:`progress-track`},_hoisted_2$214={key:0,class:`progress-fill`,style:{height:`100%`}},_hoisted_3$188={class:`header`},_hoisted_4$160={class:`name`},_hoisted_5$139={key:0,class:`stars`},_hoisted_6$120={key:1,class:`stars`},_hoisted_7$107={class:`info`},_hoisted_8$90={class:`unlock-condition`},_hoisted_9$80={class:`info`},_hoisted_10$70={class:`label`},_hoisted_11$63={class:`description`},_hoisted_12$52={key:0,class:`cards-container`},_hoisted_13$45={class:`basic-card locked coming-soon`},_hoisted_14$42={class:`label`},_hoisted_15$40={key:1,class:`right`},_sfc_main$289={__name:`LeagueRow`,props:{league:Object,leagueMissionClicked:Function,condensed:Boolean,vertical:Boolean,nowUnlocked:Boolean},setup(__props){let props=__props;function hexToRgb$1(hex){hex=hex.replace(/^#/,``);let bigint=parseInt(hex,16);return`${bigint>>16&255}, ${bigint>>8&255}, ${bigint&255}`}let leagueStyle=computed(()=>{if(!props.league.accentColor)return{};let style={};return props.league.accentColor.startsWith(`#`)?style[`--league-accent-color`]=hexToRgb$1(props.league.accentColor):props.league.accentColor.startsWith(`var(--`)&&(style[`--league-accent-color`]=props.league.accentColor),style});return(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,{class:normalizeClass([`league-row`,{locked:!__props.league._unlocked,condensed:__props.condensed}]),style:normalizeStyle(leagueStyle.value)},[createBaseVNode(`div`,_hoisted_1$258,[__props.league._unlocked?(openBlock(),createElementBlock(`div`,_hoisted_2$214)):createCommentVNode(``,!0)]),createBaseVNode(`div`,_hoisted_3$188,[createBaseVNode(`div`,_hoisted_4$160,[createVNode(unref(bngIcon_default),{type:unref(icons)[__props.league.icon],class:`skill-icon`,color:__props.league._unlocked?`white`:`gray`},null,8,[`type`,`color`]),createTextVNode(` `+toDisplayString(_ctx.$ctx_t(__props.league.name)),1)]),__props.nowUnlocked?(openBlock(),createElementBlock(`div`,_hoisted_6$120,[createVNode(unref(bngIcon_default),{type:unref(icons).lockOpened},null,8,[`type`])])):(openBlock(),createElementBlock(`div`,_hoisted_5$139,[__props.league._unlocked?(openBlock(),createBlock(unref(bngMainStars_default),{key:0,"unlocked-stars":__props.league.totalStarsObtained,"total-stars":__props.league.totalStarsAvailable,class:`main-stars`,scale:.8,reverse:``,numerical:``},null,8,[`unlocked-stars`,`total-stars`])):createCommentVNode(``,!0)]))]),createBaseVNode(`div`,{class:normalizeClass([`content-row`,{vertical:__props.vertical}])},[createBaseVNode(`div`,_hoisted_7$107,[(openBlock(!0),createElementBlock(Fragment,null,renderList(__props.league.unlock,cond=>(openBlock(),createElementBlock(Fragment,null,[cond.hidden?createCommentVNode(``,!0):(openBlock(),createBlock(unref(bngCard_default),{key:0},{default:withCtx(()=>[createBaseVNode(`div`,_hoisted_8$90,[createBaseVNode(`div`,_hoisted_9$80,[createVNode(unref(bngIcon_default),{class:`icon`,type:cond.met?unref(icons).lockOpened:unref(icons).lockClosed,color:cond.met?`white`:`gray`},null,8,[`type`,`color`]),createBaseVNode(`div`,_hoisted_10$70,toDisplayString(cond.label),1)]),cond.progress?(openBlock(),createBlock(unref(bngProgressBar_default),{key:0,value:cond.progress.cur,min:cond.progress.min,max:cond.progress.max,valueLabelFormat:``,class:`progress`},null,8,[`value`,`min`,`max`])):createCommentVNode(``,!0)])]),_:2},1024))],64))),256)),createBaseVNode(`div`,_hoisted_11$63,toDisplayString(_ctx.$ctx_t(__props.league.description)),1)]),__props.condensed?(openBlock(),createElementBlock(`div`,_hoisted_15$40,toDisplayString(__props.league.missions.length)+` Challenges `,1)):(openBlock(),createElementBlock(`div`,_hoisted_12$52,[(openBlock(!0),createElementBlock(Fragment,null,renderList(__props.league.missions,mission=>(openBlock(),createBlock(MissionCard_default,{class:`clickable-card`,key:mission.id,mission,onClicked:__props.leagueMissionClicked,showStartableIcons:!0},null,8,[`mission`,`onClicked`]))),128)),(openBlock(!0),createElementBlock(Fragment,null,renderList(__props.league.driftSpots,driftSpot=>(openBlock(),createBlock(MissionCard_default,{class:`clickable-card`,key:driftSpot.id,mission:driftSpot,onClicked:__props.leagueMissionClicked},null,8,[`mission`,`onClicked`]))),128)),__props.league.comingSoon?(openBlock(!0),createElementBlock(Fragment,{key:0},renderList(__props.league.comingSoon,info=>(openBlock(),createBlock(unref(bngCard_default),{class:`card-height`},{default:withCtx(()=>[createBaseVNode(`div`,_hoisted_13$45,[createVNode(unref(bngIcon_default),{class:`icon`,type:unref(icons)[info.icon],color:`gray`},null,8,[`type`]),createBaseVNode(`div`,_hoisted_14$42,toDisplayString(info.label),1)])]),_:2},1024))),256)):createCommentVNode(``,!0)]))],2)],6))}},LeagueRow_default=__plugin_vue_export_helper_default(_sfc_main$289,[[`__scopeId`,`data-v-f92a650f`]]),_hoisted_1$257={class:`label`},_hoisted_2$213={class:`text`},_hoisted_3$187={class:`description`},_sfc_main$288={__name:`TaskGoal`,props:{label:[String,Object],description:[String,Object],complete:Boolean,success:Boolean,settings:{type:Object,default:{animate:!1,animateOnMount:!1,successCallback:Function}}},setup(__props){let props=__props,slots=useSlots(),animationSettings=inject(`animationSettings`,props.settings),animate=ref(!1),labelParsed=computed(()=>parse$1($translate.contextTranslate(props.label,!0))),descriptionParsed=computed(()=>parse$1($translate.contextTranslate(props.description,!0))),checkboxSvgs=computed(()=>({"--checkbox-empty":`url(${getAssetURL(`icons/general/checkbox-empty.svg`)})`,"--checkbox-ok":`url(${getAssetURL(`icons/general/checkbox-ok.svg`)})`,"--checkbox-nope":`url(${getAssetURL(`icons/general/checkbox-nope.svg`)})`}));return watch(()=>[props.complete,props.success],(newValues,oldValues)=>{let isComplete=newValues[0],isSuccess=newValues[1];animate.value=animationSettings.animate&&isComplete,isSuccess&&animationSettings.successCallback()}),onBeforeMount(()=>{animate.value=props.settings.animate&&props.settings.animateOnMount}),(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,{class:normalizeClass([`task-goal`,{success:__props.complete&&__props.success,fail:__props.complete&&!__props.success,animate:animate.value}])},[createBaseVNode(`div`,_hoisted_1$257,[createBaseVNode(`span`,{class:`checkbox`,style:normalizeStyle(checkboxSvgs.value)},null,4),createBaseVNode(`span`,_hoisted_2$213,[unref(slots).label?renderSlot(_ctx.$slots,`label`,{key:0},void 0,!0):__props.label?(openBlock(),createBlock(unref(dynamicComponent_default),{key:1,template:labelParsed.value},null,8,[`template`])):createCommentVNode(``,!0)])]),createBaseVNode(`span`,_hoisted_3$187,[unref(slots).description?renderSlot(_ctx.$slots,`description`,{key:0},void 0,!0):__props.description?(openBlock(),createBlock(unref(dynamicComponent_default),{key:1,template:descriptionParsed.value},null,8,[`template`])):createCommentVNode(``,!0)])],2))}},TaskGoal_default=__plugin_vue_export_helper_default(_sfc_main$288,[[`__scopeId`,`data-v-5a381682`]]),_hoisted_1$256={key:0,class:`wrapper`},_hoisted_2$212={class:`heading`},_hoisted_3$186={class:`description`},_hoisted_4$159={key:1,class:`tasklist wrapper`},_hoisted_5$138={class:`task-content`},_hoisted_6$119={class:`heading`},_hoisted_7$106={class:`description`},_sfc_main$287={__name:`UnlockCard`,props:{data:Object},setup(__props){return(_ctx,_cache)=>(openBlock(),createElementBlock(Fragment,null,[__props.data.type==`tasklist`?createCommentVNode(``,!0):(openBlock(),createElementBlock(`div`,_hoisted_1$256,[createVNode(unref(bngIcon_default),{class:`icon`,type:unref(icons)[__props.data.icon]},null,8,[`type`]),createBaseVNode(`div`,_hoisted_2$212,toDisplayString(__props.data.heading),1),createBaseVNode(`div`,_hoisted_3$186,toDisplayString(__props.data.description),1)])),__props.data.type==`tasklist`?(openBlock(),createElementBlock(`div`,_hoisted_4$159,[(openBlock(!0),createElementBlock(Fragment,null,renderList(__props.data.tasklistData.tasks,task=>(openBlock(),createElementBlock(`div`,{class:`task`,key:task.label},[createVNode(unref(bngIcon_default),{class:`icon`,type:unref(icons)[task.done?`checkboxOn`:`checkboxOff`]},null,8,[`type`]),createBaseVNode(`div`,_hoisted_5$138,[createBaseVNode(`div`,_hoisted_6$119,toDisplayString(task.label),1),createBaseVNode(`div`,_hoisted_7$106,toDisplayString(task.description),1)])]))),128))])):createCommentVNode(``,!0)],64))}},UnlockCard_default=__plugin_vue_export_helper_default(_sfc_main$287,[[`__scopeId`,`data-v-c5fa6ca1`]]),_hoisted_1$255={class:`unlock-rows`},_hoisted_2$211={class:`rows-container`},_hoisted_3$185={class:`progress-track`},_hoisted_4$158={key:0,class:`progress-fill`,style:{height:`100%`}},_hoisted_5$137={class:`header`},_hoisted_6$118={class:`level-name-and-heading`},_hoisted_7$105={class:`level-label`},_hoisted_8$89={key:0,class:`description-heading`},_hoisted_9$79={class:`content-row`},_hoisted_10$69={class:`description-column`},_hoisted_11$62={class:`unlock-condition`},_hoisted_12$51={class:`info`},_hoisted_13$44={class:`label`},_hoisted_14$41={key:1,class:`description-text`},_hoisted_15$39={class:`unlocks-column`},_hoisted_16$38={key:0,class:`unlocks-list`},_sfc_main$286={__name:`UnlockRows`,props:{value:{type:Number,default:0},min:{type:Number,default:0},max:{type:Number,required:!0},maxRequiredValue:{type:Number,required:!1},tiers:Array,currentTier:Number,unlocked:Boolean,progressFillColor:{type:String,default:`#ff6600`}},setup(__props){useCssVars(_ctx=>({v1b3c87f1:props.progressFillColor.startsWith(`var(--`)&&props.progressFillColor.endsWith(`-rgb)`)?`rgb(${props.progressFillColor})`:props.progressFillColor}));let props=__props;function hexToRgb$1(hex){hex=hex.replace(/^#/,``);let bigint=parseInt(hex,16);return`${bigint>>16&255}, ${bigint>>8&255}, ${bigint&255}`}let progressStyle=computed(()=>{if(!props.progressFillColor)return{};let style={};return props.progressFillColor.startsWith(`#`)?style[`--progress-fill-color`]=hexToRgb$1(props.progressFillColor):props.progressFillColor.startsWith(`var(--`)&&(style[`--progress-fill-color`]=props.progressFillColor),style});return(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$255,[createBaseVNode(`div`,_hoisted_2$211,[(openBlock(!0),createElementBlock(Fragment,null,renderList(__props.tiers,(tier,idx)=>(openBlock(),createElementBlock(`div`,{key:tier.index,class:normalizeClass({"tier-row":!0,"grayed-out":__props.currentTier<=tier.index-1,completed:__props.currentTier+1>tier.index,"in-development":tier.isInDevelopment,"first-tier":idx===0,"last-tier":idx===__props.tiers.length-1})},[createBaseVNode(`div`,_hoisted_3$185,[__props.currentTier+1>tier.index?(openBlock(),createElementBlock(`div`,_hoisted_4$158)):createCommentVNode(``,!0)]),createBaseVNode(`div`,_hoisted_5$137,[createBaseVNode(`div`,_hoisted_6$118,[createBaseVNode(`span`,_hoisted_7$105,`Level `+toDisplayString(tier.label?tier.label:tier.index),1),tier.description&&tier.description.heading?(openBlock(),createElementBlock(`span`,_hoisted_8$89,`: `+toDisplayString(tier.description.heading),1)):createCommentVNode(``,!0)])]),createBaseVNode(`div`,_hoisted_9$79,[createBaseVNode(`div`,_hoisted_10$69,[tier.isInDevelopment||__props.currentTier+1<=tier.index||!__props.unlocked?(openBlock(),createBlock(unref(bngCard_default),{key:0,class:`unlock-condition-card`,style:normalizeStyle(progressStyle.value)},{default:withCtx(()=>[createBaseVNode(`div`,_hoisted_11$62,[createBaseVNode(`div`,_hoisted_12$51,[createVNode(unref(bngIcon_default),{class:`icon`,type:tier.isInDevelopment?unref(icons).roadblockL:unref(icons).lockClosed,color:`gray`},null,8,[`type`]),createBaseVNode(`div`,_hoisted_13$44,[tier.isInDevelopment?(openBlock(),createElementBlock(Fragment,{key:0},[createTextVNode(` Coming Soon! `)],64)):(openBlock(),createElementBlock(Fragment,{key:1},[createTextVNode(toDisplayString(tier.xpCurrent)+` / `+toDisplayString(tier.xpRequired)+` XP `,1)],64))])]),!tier.isInDevelopment&&tier.currentValue&&tier.requiredValue?(openBlock(),createBlock(unref(bngProgressBar_default),{key:0,value:tier.xpCurrent,min:0,max:tier.xpRequired,valueLabelFormat:``,class:`progress`},null,8,[`value`,`max`])):createCommentVNode(``,!0)])]),_:2},1032,[`style`])):createCommentVNode(``,!0),tier.description&&tier.description.description?(openBlock(),createElementBlock(`div`,_hoisted_14$41,toDisplayString(tier.description.description),1)):createCommentVNode(``,!0)]),createBaseVNode(`div`,_hoisted_15$39,[tier.list&&tier.list.length>0?(openBlock(),createElementBlock(`div`,_hoisted_16$38,[(openBlock(!0),createElementBlock(Fragment,null,renderList(tier.list,(item,idx$1)=>(openBlock(),createBlock(UnlockCard_default,{key:idx$1,class:`unlock-item`,data:item},null,8,[`data`]))),128))])):createCommentVNode(``,!0)])])],2))),128))])]))}},UnlockRows_default=__plugin_vue_export_helper_default(_sfc_main$286,[[`__scopeId`,`data-v-ec31f890`]]),_hoisted_1$254={class:`flex-row`},_hoisted_2$210={class:`player-content`},_hoisted_3$184={class:`stats-row`},_hoisted_4$157={class:`stat-content`},_sfc_main$285={__name:`careerSimpleStats`,setup(__props,{expose:__expose}){let careerStatsData=ref({}),handleCareerSimpleStats=data=>{data.branches.forEach(entry=>{entry.hasOwnProperty(`levelLabel`)&&(entry.name=$translate.contextTranslate(entry.name,!0),entry.levelLabel=$translate.contextTranslate(entry.levelLabel,!0))}),careerStatsData.value=data},updateDisplay=()=>{Lua_default.career_modules_uiUtils.getCareerSimpleStats().then(handleCareerSimpleStats)};return onMounted(()=>{updateDisplay()}),__expose({updateDisplay}),(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$254,[createBaseVNode(`div`,_hoisted_2$210,toDisplayString(careerStatsData.value.saveSlotName),1),createBaseVNode(`div`,_hoisted_3$184,[(openBlock(!0),createElementBlock(Fragment,null,renderList(careerStatsData.value.branches,branch=>(openBlock(),createElementBlock(`div`,_hoisted_4$157,[createVNode(unref(bngProgressBar_default),{class:`stat-progress-bar`,headerLeft:branch.name,headerRight:branch.levelLabel,min:branch.min,value:branch.value,max:branch.max},null,8,[`headerLeft`,`headerRight`,`min`,`value`,`max`])]))),256))])]))}},careerSimpleStats_default=__plugin_vue_export_helper_default(_sfc_main$285,[[`__scopeId`,`data-v-94a9390d`]]),_sfc_main$284={__name:`careerStatus`,props:{slim:{type:Boolean,default:!1}},setup(__props,{expose:__expose}){let careerStatusData=ref({}),handleCareerStatusData=data=>careerStatusData.value=data,updateDisplay=()=>Lua_default.career_modules_uiUtils.getCareerStatusData().then(handleCareerStatusData);return onMounted(updateDisplay),__expose({updateDisplay}),(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,null,[createBaseVNode(`div`,{class:normalizeClass([`career-status-progress`,{slim:__props.slim}])},[createVNode(unref(bngUnit_default),{class:`career-status-value`,insuranceScore:careerStatusData.value.insuranceScore},null,8,[`insuranceScore`]),createVNode(unref(bngDivider_default)),createVNode(unref(bngUnit_default),{class:`career-status-value`,vouchers:careerStatusData.value.vouchers},null,8,[`vouchers`]),createVNode(unref(bngDivider_default)),createVNode(unref(bngUnit_default),{class:`career-status-value`,money:careerStatusData.value.money},null,8,[`money`])],2)]))}},careerStatus_default=__plugin_vue_export_helper_default(_sfc_main$284,[[`__scopeId`,`data-v-0446c53b`]]),_hoisted_1$253={key:0},_sfc_main$283={__name:`TutorialButton`,props:{text:{type:String,default:``},icon:{type:Object,default:()=>icons.questionmark},pages:{type:Object,default:[]}},setup(__props){let props=__props,buttonRef=ref(null),seen$3=ref(!0);function clickHandler(){for(let key of props.pages)Lua_default.career_modules_linearTutorial.introPopup(key,!0);seen$3.value=!0}return onMounted(()=>{}),onUnmounted(()=>{}),(_ctx,_cache)=>withDirectives((openBlock(),createBlock(unref(bngButton_default),{ref_key:`buttonRef`,ref:buttonRef,class:normalizeClass([`tut-btn`,{blink:!seen$3.value}]),icon:__props.icon,onClick:withModifiers(clickHandler,[`stop`])},{default:withCtx(()=>[__props.text?(openBlock(),createElementBlock(`span`,_hoisted_1$253,toDisplayString(__props.text),1)):createCommentVNode(``,!0)]),_:1},8,[`icon`,`class`])),[[unref(BngTooltip_default),__props.text?void 0:`View tutorial for this section`]])}},TutorialButton_default=__plugin_vue_export_helper_default(_sfc_main$283,[[`__scopeId`,`data-v-3e539b42`]]),_hoisted_1$252={class:`content`},_hoisted_2$209={class:`insurance-perks-div`},_hoisted_3$183={key:0,class:`leaving-insurance-wrapper`},_hoisted_4$156={class:`breakdown-items-wrapper`},_hoisted_5$136={class:`breakdown-item`},_hoisted_6$117={class:`orange-price`},_hoisted_7$104={class:`breakdown-item`},_hoisted_8$88={class:`red-price`},_hoisted_9$78={class:`breakdown-item total`},_hoisted_10$68={class:`breakdown-item-value-total green-price`},_hoisted_11$61={key:1,class:`no-insurance-wrapper`},_hoisted_12$50={key:2,class:`group-discount-wrapper`},_hoisted_13$43={class:`group-discount-icon-wrapper`},_hoisted_14$40={class:`group-discount-main-text`},_hoisted_15$38={class:`tier-text`},_hoisted_16$37={class:`tier-text`},_hoisted_17$31={class:`discount-text`},_hoisted_18$28={class:`grey-small-text`},_hoisted_19$24={key:3,class:`price-details-wrapper`},_hoisted_20$20={class:`price-tile`},_hoisted_21$18={key:0,class:`old-price-wrapper`},_hoisted_22$16={class:`old-price`},_hoisted_23$15={class:`price-tile-value-wrapper`},_hoisted_24$14={key:1,class:`deductible-discount`},_hoisted_25$13={class:`price-tile`},_hoisted_26$11={class:`price-tile-title`},_hoisted_27$11={class:`price-tile-value-wrapper`},_hoisted_28$10={class:`premium-extra-info`},_hoisted_29$10={class:`renewal-distance`},_sfc_main$282={__name:`insuranceCard`,props:{insuranceData:Object,isSelected:Boolean,isCurrentProvider:{type:Boolean,default:!1}},emits:[`select`],setup(__props,{emit:__emit}){let props=__props,{units}=useBridge(),emit$1=__emit,hasNoInsurance=computed(()=>props.insuranceData?.id===-1),pillText=computed(()=>{if(props.isCurrentProvider)return`CURRENT PROVIDER`;if(props.insuranceData.groupDiscountData){if(props.insuranceData.groupDiscountData?.willHaveGroupDiscountForTheFirstTime)return`MULTI-VEHICLE DISCOUNT AVAILABLE`;if(props.insuranceData.groupDiscountData?.willBumpTheirDiscount)return`BIGGER DISCOUNT AVAILABLE`;if(props.insuranceData.groupDiscountData?.currentTierData&&props.insuranceData.groupDiscountData?.currentTierData.id>0)return`MULTI-VEHICLE DISCOUNT ACTIVE`}return null}),renewsInFormatted=computed(()=>props.insuranceData?.renewsIn?units.buildString(`length`,props.insuranceData.renewsIn*1e3,0):``),leavingInsuranceRenewsInFormatted=computed(()=>props.insuranceData?.leavingInsuranceInfo?.renewsIn?units.buildString(`length`,props.insuranceData.leavingInsuranceInfo.renewsIn*1e3,0):``),selectCard=()=>{emit$1(`select`,props.insuranceData.id)},cardStyles=computed(()=>{let styles={};return!hasNoInsurance.value&&props.insuranceData.color&&(styles[`--insurance-card-rgb`]=hexToRgb(props.insuranceData.color)),styles});return(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,{class:normalizeClass([`insurance-card-container`,{selected:__props.isSelected,"no-insurance-card":hasNoInsurance.value,"current-provider":__props.isCurrentProvider}]),style:normalizeStyle(cardStyles.value),onClick:selectCard,"bng-nav-item":``},[pillText.value===null?createCommentVNode(``,!0):(openBlock(),createElementBlock(`div`,{key:0,class:normalizeClass([`top-pill`,{"no-insurance":hasNoInsurance.value,"orange-pill":__props.insuranceData.groupDiscountData?.willHaveGroupDiscountForTheFirstTime,"current-provider-pill":__props.isCurrentProvider}])},[createBaseVNode(`div`,null,toDisplayString(pillText.value),1)],2)),createBaseVNode(`div`,_hoisted_1$252,[createVNode(unref(insuranceIdentity_default),{class:`insurance-identity`,insuranceData:__props.insuranceData},null,8,[`insuranceData`]),_cache[13]||=createBaseVNode(`div`,{class:`separator`},null,-1),createBaseVNode(`div`,_hoisted_2$209,[hasNoInsurance.value?(openBlock(),createElementBlock(`div`,{key:0,class:normalizeClass([`perks-header`,{"no-insurance":hasNoInsurance.value}])},toDisplayString(hasNoInsurance.value?`Consequences`:`Included Benefits`),3)):createCommentVNode(``,!0),createVNode(unref(insurancePerks_default),{insuranceData:__props.insuranceData},null,8,[`insuranceData`])]),_cache[14]||=createBaseVNode(`div`,{class:`separator`},null,-1),hasNoInsurance.value&&__props.insuranceData.leavingInsuranceInfo&&!__props.isCurrentProvider?(openBlock(),createElementBlock(`div`,_hoisted_3$183,[_cache[4]||=createBaseVNode(`div`,{class:`leaving-insurance-title`},`Cancellation Refund`,-1),createBaseVNode(`div`,_hoisted_4$156,[createBaseVNode(`div`,_hoisted_5$136,[createBaseVNode(`span`,null,` Unused coverage (`+toDisplayString(leavingInsuranceRenewsInFormatted.value)+`) `,1),createBaseVNode(`span`,_hoisted_6$117,[_cache[0]||=createTextVNode(` + `,-1),createVNode(unref(bngUnit_default),{money:__props.insuranceData.leavingInsuranceInfo.coverageRefundPrice},null,8,[`money`])])]),createBaseVNode(`div`,_hoisted_7$104,[_cache[2]||=createBaseVNode(`span`,null,` Early Cancellation Fee (25%) `,-1),createBaseVNode(`span`,_hoisted_8$88,[_cache[1]||=createTextVNode(` - `,-1),createVNode(unref(bngUnit_default),{money:__props.insuranceData.leavingInsuranceInfo.earlyTerminationPenalty},null,8,[`money`])])]),createBaseVNode(`div`,_hoisted_9$78,[_cache[3]||=createBaseVNode(`span`,{class:`breakdown-item-label-total`},` You'll receive `,-1),createBaseVNode(`span`,_hoisted_10$68,[createVNode(unref(bngUnit_default),{money:__props.insuranceData.leavingInsuranceInfo.netRefundPrice},null,8,[`money`])])])])])):createCommentVNode(``,!0),hasNoInsurance.value?(openBlock(),createElementBlock(`div`,_hoisted_11$61,[..._cache[5]||=[createBaseVNode(`span`,{class:`no-insurance-warning`},` You will pay full repair costs `,-1),createBaseVNode(`span`,null,` No coverage or benefits included `,-1)]])):createCommentVNode(``,!0),!hasNoInsurance.value&&__props.insuranceData.groupDiscountData?.mainText?(openBlock(),createElementBlock(`div`,_hoisted_12$50,[createBaseVNode(`div`,null,[createBaseVNode(`span`,_hoisted_13$43,[createVNode(unref(bngIcon_default),{type:unref(icons).checkmark},null,8,[`type`])]),createBaseVNode(`span`,_hoisted_14$40,toDisplayString(__props.insuranceData.groupDiscountData?.mainText),1)]),createBaseVNode(`div`,null,[_cache[7]||=createBaseVNode(`span`,{class:`grey-small-text`},` Currently Insured : `,-1),createBaseVNode(`span`,null,[createVNode(unref(bngIcon_default),{class:`vehicles-icon`,type:unref(icons).car},null,8,[`type`])]),createBaseVNode(`span`,_hoisted_15$38,toDisplayString(__props.insuranceData.carsInsuredCount),1),__props.insuranceData.groupDiscountData?.currentTierData?.id>0?(openBlock(),createElementBlock(Fragment,{key:0},[_cache[6]||=createBaseVNode(`span`,{class:`vertical-separator`},` | `,-1),createBaseVNode(`span`,_hoisted_16$37,` Tier `+toDisplayString(__props.insuranceData.groupDiscountData?.currentTierData?.id),1),createBaseVNode(`span`,_hoisted_17$31,` - `+toDisplayString(__props.insuranceData.groupDiscountData?.currentTierData?.discount*100)+`% off `,1)],64)):createCommentVNode(``,!0)]),createBaseVNode(`div`,_hoisted_18$28,toDisplayString(__props.insuranceData.groupDiscountData?.secondaryText),1)])):createCommentVNode(``,!0),hasNoInsurance.value?createCommentVNode(``,!0):(openBlock(),createElementBlock(`div`,_hoisted_19$24,[createBaseVNode(`div`,_hoisted_20$20,[_cache[9]||=createBaseVNode(`span`,{class:`price-tile-title`},`Deductible`,-1),__props.insuranceData.baseDeductibledData?.oldPrice?(openBlock(),createElementBlock(`div`,_hoisted_21$18,[createBaseVNode(`div`,_hoisted_22$16,[createVNode(unref(bngUnit_default),{money:__props.insuranceData.baseDeductibledData.oldPrice},null,8,[`money`]),_cache[8]||=createBaseVNode(`div`,{class:`strike`},null,-1)])])):createCommentVNode(``,!0),createBaseVNode(`div`,_hoisted_23$15,[createVNode(unref(bngUnit_default),{money:__props.insuranceData.baseDeductibledData.price,class:normalizeClass(__props.insuranceData.baseDeductibledData.oldPrice?`green-price`:`orange-price`)},null,8,[`money`,`class`])]),_cache[10]||=createBaseVNode(`div`,{class:`deductible-tips`},[createBaseVNode(`div`,null,` - You pay your deductible for each crash repair `),createBaseVNode(`div`,null,` - Customize this value after purchase `)],-1),__props.insuranceData.baseDeductibledData.perkData?(openBlock(),createElementBlock(`div`,_hoisted_24$14,toDisplayString(__props.insuranceData.baseDeductibledData.perkData.discount*100)+`% discount applied `,1)):createCommentVNode(``,!0)]),createBaseVNode(`div`,_hoisted_25$13,[createBaseVNode(`span`,_hoisted_26$11,toDisplayString(__props.insuranceData.amountDue>0?`Amount Due`:`Credit Received`),1),createBaseVNode(`div`,_hoisted_27$11,[createVNode(unref(bngUnit_default),{money:Math.abs(__props.insuranceData.amountDue),class:`green-price`},null,8,[`money`])]),createBaseVNode(`div`,_hoisted_28$10,[createBaseVNode(`div`,null,[_cache[11]||=createTextVNode(` Total policy : `,-1),createVNode(unref(bngUnit_default),{money:__props.insuranceData.futurePremiumDetails.totalPriceWithDriverScore},null,8,[`money`])]),createBaseVNode(`div`,null,[_cache[12]||=createBaseVNode(`span`,null,`Renews in : `,-1),createBaseVNode(`span`,_hoisted_29$10,toDisplayString(renewsInFormatted.value),1)])])])]))]),createBaseVNode(`div`,{class:normalizeClass([`background`,{"no-insurance":hasNoInsurance.value}])},null,2)],6))}},insuranceCard_default=__plugin_vue_export_helper_default(_sfc_main$282,[[`__scopeId`,`data-v-e481fbef`]]),_hoisted_1$251={class:`premium-wrapper`},_hoisted_2$208={class:`breakdown-item`},_hoisted_3$182={class:`breakdown-item-value`},_hoisted_4$155={class:`premium-value-wrapper`},_hoisted_5$135={class:`breakdown-item`},_hoisted_6$116={class:`breakdown-item-value`},_hoisted_7$103={class:`breakdown-item`},_hoisted_8$87={class:`breakdown-item-value`},_hoisted_9$77={class:`breakdown-item`},_hoisted_10$67={class:`breakdown-item-value orange-text`},_hoisted_11$60={class:`perks`},_hoisted_12$49={key:0,class:`grey-text`},_hoisted_13$42={key:1,class:`grey-text`},_hoisted_14$39={class:`group-discount-savings`},_hoisted_15$37={class:`breakdown-item`},_hoisted_16$36={key:0,class:`grey-text`},_hoisted_17$30={key:1,class:`grey-text`},_hoisted_18$27={class:`buttons`},_sfc_main$281={__name:`smallInsuranceCard`,props:{insuranceData:{type:Object,required:!0},driverScoreData:{type:Object,required:!0}},setup(__props){let{units}=useBridge(),props=__props,renewsEveryFormatted=computed(()=>units.buildString(`length`,props.insuranceData.renewsEvery*1e3,0)),renewsInFormatted=computed(()=>units.buildString(`length`,props.insuranceData.renewsIn*1e3,0)),buttonsDisabled=computed(()=>props.insuranceData.carsInsuredCount===0),openVehicleList=()=>{addPopup(vehicleInsuranceList_default,{insuranceData:props.insuranceData,driverScoreData:props.driverScoreData})},openEditPolicy=()=>{addPopup(editPolicy_default,{insuranceData:props.insuranceData,driverScoreData:props.driverScoreData})},tierToDisplay=computed(()=>props.insuranceData.groupDiscountData.currentTierData.id>0?props.insuranceData.groupDiscountData.currentTierData:props.insuranceData.groupDiscountData.groupDiscountTiers[0]);return(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,{class:normalizeClass([`small-insurance-card`,{"no-vehicles":buttonsDisabled.value}]),style:normalizeStyle({"border-top":`0.7rem solid ${props.insuranceData.color}`,background:`linear-gradient(180deg, ${props.insuranceData.color}80 0%, ${props.insuranceData.color}30 10%, ${props.insuranceData.color}10 35%, var(--bng-cool-gray-800) 50%, var(--blue-shade-100) 100%)`})},[createVNode(unref(insuranceIdentity_default),{class:`insurance-identity`,insuranceData:props.insuranceData},null,8,[`insuranceData`]),createBaseVNode(`div`,_hoisted_1$251,[createBaseVNode(`div`,_hoisted_2$208,[createBaseVNode(`span`,null,`Premium / `+toDisplayString(renewsEveryFormatted.value),1),createBaseVNode(`span`,_hoisted_3$182,[createBaseVNode(`div`,_hoisted_4$155,[createVNode(unref(bngUnit_default),{money:props.insuranceData.currentPremiumDetails.totalPriceWithDriverScore},null,8,[`money`])])])]),createBaseVNode(`div`,_hoisted_5$135,[_cache[0]||=createBaseVNode(`span`,null,`Renews in `,-1),createBaseVNode(`span`,_hoisted_6$116,[props.insuranceData.carsInsuredCount===0?(openBlock(),createElementBlock(Fragment,{key:0},[createTextVNode(` - `)],64)):(openBlock(),createElementBlock(Fragment,{key:1},[createTextVNode(toDisplayString(renewsInFormatted.value),1)],64))])]),createBaseVNode(`div`,_hoisted_7$103,[_cache[1]||=createBaseVNode(`span`,null,`Vehicle Coverage`,-1),createBaseVNode(`span`,_hoisted_8$87,[createVNode(unref(bngUnit_default),{money:props.insuranceData.totalInsuranceVehsValue},null,8,[`money`])])]),createBaseVNode(`div`,_hoisted_9$77,[_cache[2]||=createBaseVNode(`span`,null,`Vehicles`,-1),createBaseVNode(`span`,_hoisted_10$67,toDisplayString(props.insuranceData.carsInsuredCount),1)])]),createBaseVNode(`div`,_hoisted_11$60,[createVNode(unref(insurancePerks_default),{insuranceData:props.insuranceData,noDescription:!0},null,8,[`insuranceData`])]),createBaseVNode(`div`,{class:normalizeClass([`group-discount-wrapper`,{disabled:props.insuranceData.groupDiscountData.currentTierData.id===-1}])},[props.insuranceData.carsInsuredCount===0?(openBlock(),createElementBlock(`div`,_hoisted_12$49,` No vehicles insured under this policy `)):props.insuranceData.carsInsuredCount===1?(openBlock(),createElementBlock(`div`,_hoisted_13$42,` Add a second vehicle to unlock Tier 1 (`+toDisplayString(props.insuranceData.groupDiscountData.groupDiscountTiers[0].discount*100)+`%) coverage savings. `,1)):(openBlock(),createElementBlock(Fragment,{key:2},[_cache[4]||=createBaseVNode(`div`,{class:`group-discount`},` MULTI-VEHICLE DISCOUNT `,-1),createBaseVNode(`div`,_hoisted_14$39,[_cache[3]||=createTextVNode(` Savings :`,-1),createVNode(unref(bngUnit_default),{money:props.insuranceData.currentPremiumDetails.groupDiscountSavings},null,8,[`money`])]),createBaseVNode(`div`,_hoisted_15$37,[tierToDisplay.value.max?(openBlock(),createElementBlock(`span`,_hoisted_16$36,` Your coverage falls in the `+toDisplayString(tierToDisplay.value.min/1e3)+`k - `+toDisplayString(tierToDisplay.value.max/1e3)+`k range `,1)):(openBlock(),createElementBlock(`span`,_hoisted_17$30,` Your coverage falls in the `+toDisplayString(tierToDisplay.value.min/1e3)+`k+ range `,1))]),createBaseVNode(`div`,null,[createVNode(unref(insuranceTiers_default),{showTier:!0,tiers:props.insuranceData.groupDiscountData.groupDiscountTiers},null,8,[`tiers`])])],64))],2),createBaseVNode(`div`,_hoisted_18$27,[createVNode(unref(bngButton_default),{class:`edit-policy-button bigger-button`,accent:`custom`,onClick:openEditPolicy,disabled:buttonsDisabled.value},{default:withCtx(()=>[createVNode(unref(bngIcon_default),{class:normalizeClass([`button-icon`,{disabled:buttonsDisabled.value}]),type:unref(icons).adjust},null,8,[`type`,`class`]),createBaseVNode(`span`,{class:normalizeClass([`button-text`,{disabled:buttonsDisabled.value}])},`Edit Policy`,2)]),_:1},8,[`disabled`]),createVNode(unref(bngButton_default),{class:`see-vehicles-button bigger-button`,accent:`custom`,onClick:openVehicleList,disabled:buttonsDisabled.value},{default:withCtx(()=>[createVNode(unref(bngIcon_default),{class:normalizeClass([`button-icon`,{disabled:buttonsDisabled.value}]),type:unref(icons).car},null,8,[`type`,`class`]),createBaseVNode(`span`,{class:normalizeClass([`button-text`,{disabled:buttonsDisabled.value}])},`See Vehicles`,2)]),_:1},8,[`disabled`])])],6))}},smallInsuranceCard_default=__plugin_vue_export_helper_default(_sfc_main$281,[[`__scopeId`,`data-v-38392c0c`]]),_hoisted_1$250={class:`insurance-details-wrapper`,"bng-ui-scope":`insuranceDetailsPopup`},_hoisted_2$207={class:`card-content`},_hoisted_3$181={class:`header`},_hoisted_4$154={class:`header-left`},_hoisted_5$134={class:`insurance-identity`},_hoisted_6$115={class:`insurance-name`},_hoisted_7$102={class:`insurance-slogan`},_hoisted_8$86={class:`covers-renew-info`},_hoisted_9$76={class:`header-right`},_hoisted_10$66={class:`vehicle-name`},_hoisted_11$59={class:`vehicle-value blue-price`},_hoisted_12$48={key:0,class:`group-discount-wrapper`},_hoisted_13$41={class:`group-discount-header`},_hoisted_14$38={class:`group-discount-icon-wrapper`},_hoisted_15$36={class:`group-discount-text-wrapper`},_hoisted_16$35={class:`group-discount-main-text`},_hoisted_17$29={class:`tiers-wrapper`},_hoisted_18$26={class:`textual-tiers-wrapper`},_hoisted_19$23={class:`tier-number`},_hoisted_20$19={class:`money-bracket`},_hoisted_21$17={key:0},_hoisted_22$15={key:1},_hoisted_23$14={class:`current-after-discount-price`},_hoisted_24$13={class:`tier-discount-price`},_hoisted_25$12={class:`policy-value`},_hoisted_26$10={class:`policy-tier`},_hoisted_27$10={class:`tier-discount-price isFutureTier`},_hoisted_28$9={class:`policy-value`},_hoisted_29$9={class:`policy-tier isFuture`},_hoisted_30$9={class:`price-breakdown-wrapper`},_hoisted_31$9={class:`prices-breakdown-header`},_hoisted_32$9={class:`breakdown-item`},_hoisted_33$9={class:`breakdown-details`},_hoisted_34$9={class:`breakdown-item-value`},_hoisted_35$8={class:`breakdown-value`},_hoisted_36$8={class:`breakdown-item-value orange`},_hoisted_37$7={class:`breakdown-value`},_hoisted_38$6={key:0,class:`breakdown-item-value orange`},_hoisted_39$6={class:`breakdown-label`},_hoisted_40$5={class:`breakdown-value`},_hoisted_41$5={class:`breakdown-item-value result`},_hoisted_42$4={class:`breakdown-value result`},_hoisted_43$4={class:`breakdown-item`},_hoisted_44$4={class:`breakdown-details`},_hoisted_45$4={key:0,class:`breakdown-item-value`},_hoisted_46$2={key:0,class:`strikethrough-line`},_hoisted_47$2={key:1,class:`breakdown-item-value`},_hoisted_48$2={class:`breakdown-label`},_hoisted_49$2={class:`tier-discount-badge`},_hoisted_50$2={class:`breakdown-value green-price`},_hoisted_51$2={key:0,class:`breakdown-item-value`},_hoisted_52$2={class:`breakdown-label`},_hoisted_53$2={class:`breakdown-value`},_hoisted_54$2={class:`breakdown-item-value subtotal`},_hoisted_55$2={class:`breakdown-value`},_hoisted_56$2={class:`breakdown-item-value`},_hoisted_57$1={class:`breakdown-item-value result`},_hoisted_58$1={class:`breakdown-value`},_hoisted_59$1={class:`sum-to-pay`},_hoisted_60$1={class:`sum-to-pay-value`},_hoisted_61$1={class:`closeButton`},__default__$5={wrapper:{fade:!0,blur:!0,style:popupContainer.default},position:[popupPosition.center,popupPosition.center]},_sfc_main$280=Object.assign(__default__$5,{__name:`purchaseInsuranceDetails`,props:{insuranceData:Object,vehicleInfo:Object,driverScoreData:Object},emits:[`return`],setup(__props,{emit:__emit}){let{units}=useBridge();useUINavScope(`insuranceDetailsPopup`);let props=__props,emit$1=__emit,closePopup=()=>{emit$1(`return`,!0)},driverScoreAdjustmentText=computed(()=>{let multiplier=props.driverScoreData.tier.multiplier;return multiplier<1?`↓${((1-multiplier)*100).toFixed(0)}%`:multiplier>1?`↑${((multiplier-1)*100).toFixed(0)}%`:`0%`}),driverScoreClass=computed(()=>{let multiplier=props.driverScoreData.tier.multiplier;return multiplier<1?`driver-score-discount`:multiplier>1?`driver-score-penalty`:``}),groupDiscountText=computed(()=>{if(props.insuranceData.groupDiscountData){if(props.insuranceData.groupDiscountData.willHaveGroupDiscountForTheFirstTime)return`Multi-vehicle discount available`;if(props.insuranceData.groupDiscountData.willBumpTheirDiscount)return`Bigger discount available`;if(props.insuranceData.groupDiscountData.currentTierData&&props.insuranceData.groupDiscountData.currentTierData.id>0)return`Multi-vehicle discount active`}return null}),renewsEveryFormatted=computed(()=>props.insuranceData?.renewsEvery?units.buildString(`length`,props.insuranceData.renewsEvery*1e3,0):``);return(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$250,[createBaseVNode(`div`,_hoisted_2$207,[createBaseVNode(`div`,_hoisted_3$181,[createBaseVNode(`div`,_hoisted_4$154,[_cache[2]||=createBaseVNode(`div`,{class:`policy-details`},` Policy details `,-1),createBaseVNode(`div`,_hoisted_5$134,[createBaseVNode(`span`,_hoisted_6$115,toDisplayString(props.insuranceData.name),1),_cache[0]||=createBaseVNode(`span`,{class:`name-slogan-seperator`},null,-1),createBaseVNode(`span`,_hoisted_7$102,toDisplayString(props.insuranceData.slogan),1)]),createBaseVNode(`div`,_hoisted_8$86,[createBaseVNode(`span`,null,`Covers `+toDisplayString(props.insuranceData.carsInsuredCount)+` Vehicles`,1),_cache[1]||=createBaseVNode(`span`,{class:`covers-renew-seperator`},null,-1),createBaseVNode(`span`,null,`Renews every `+toDisplayString(renewsEveryFormatted.value),1)])]),createBaseVNode(`div`,_hoisted_9$76,[_cache[4]||=createBaseVNode(`div`,{class:`action-type`},`Adding vehicle`,-1),createBaseVNode(`div`,_hoisted_10$66,toDisplayString(props.vehicleInfo.Name),1),createBaseVNode(`div`,_hoisted_11$59,[_cache[3]||=createTextVNode(`Value : `,-1),createVNode(unref(bngUnit_default),{money:props.vehicleInfo.Value},null,8,[`money`])])])]),props.insuranceData.groupDiscountData.willHaveGroupDiscountForTheFirstTime||props.insuranceData.groupDiscountData.willBumpTheirDiscount||props.insuranceData.groupDiscountData.currentTierData.id>0?(openBlock(),createElementBlock(`div`,_hoisted_12$48,[createBaseVNode(`div`,_hoisted_13$41,[createBaseVNode(`div`,_hoisted_14$38,[createVNode(unref(bngIcon_default),{type:unref(icons).checkmark},null,8,[`type`])]),createBaseVNode(`div`,_hoisted_15$36,[createBaseVNode(`div`,_hoisted_16$35,toDisplayString(groupDiscountText.value),1),_cache[5]||=createBaseVNode(`div`,{class:`group-discount-secondary-text`},` Insurance discounts are based on the total value of your fleet. `,-1)])]),createBaseVNode(`div`,_hoisted_17$29,[createBaseVNode(`div`,_hoisted_18$26,[(openBlock(!0),createElementBlock(Fragment,null,renderList(props.insuranceData.groupDiscountData.groupDiscountTiers,tier=>(openBlock(),createElementBlock(`div`,{class:`tier`,key:tier.id},[createBaseVNode(`div`,_hoisted_19$23,` Tier `+toDisplayString(tier.id),1),createBaseVNode(`div`,_hoisted_20$19,[createBaseVNode(`span`,null,toDisplayString(tier.min/1e3)+`k`,1),tier.max?(openBlock(),createElementBlock(`span`,_hoisted_21$17,`-`+toDisplayString(tier.max/1e3)+`k`,1)):(openBlock(),createElementBlock(`span`,_hoisted_22$15,`+`))])]))),128))]),createVNode(unref(insuranceTiers_default),{tiers:props.insuranceData.groupDiscountData.groupDiscountTiers},null,8,[`tiers`])]),createBaseVNode(`div`,_hoisted_23$14,[createBaseVNode(`div`,_hoisted_24$13,[_cache[7]||=createBaseVNode(`div`,{class:`section-label deactivated`},` Current Tier `,-1),createBaseVNode(`div`,_hoisted_25$12,[_cache[6]||=createTextVNode(` Policy Value : `,-1),createVNode(unref(bngUnit_default),{money:props.insuranceData.totalInsuranceVehsValue},null,8,[`money`])]),createBaseVNode(`div`,_hoisted_26$10,` Tier `+toDisplayString(Math.max(props.insuranceData.groupDiscountData.currentTierData.id,0))+` - `+toDisplayString(props.insuranceData.groupDiscountData.currentTierData.discount*100)+`% off `,1)]),createBaseVNode(`div`,_hoisted_27$10,[_cache[9]||=createBaseVNode(`div`,{class:`section-label`},` After Purchase `,-1),createBaseVNode(`div`,_hoisted_28$9,[_cache[8]||=createTextVNode(` Policy Value : `,-1),createVNode(unref(bngUnit_default),{money:props.insuranceData.totalInsuranceVehsValue+props.insuranceData.vehicleValue},null,8,[`money`])]),createBaseVNode(`div`,_hoisted_29$9,` Tier `+toDisplayString(props.insuranceData.groupDiscountData.futureTierData.id)+` - `+toDisplayString(props.insuranceData.groupDiscountData.futureTierData.discount*100)+`% off `,1)])])])):createCommentVNode(``,!0),createBaseVNode(`div`,_hoisted_30$9,[createBaseVNode(`div`,_hoisted_31$9,[createBaseVNode(`div`,_hoisted_32$9,[_cache[13]||=createBaseVNode(`div`,{class:`section-label`},` Vehicle `,-1),createBaseVNode(`div`,_hoisted_33$9,[createBaseVNode(`div`,_hoisted_34$9,[_cache[10]||=createBaseVNode(`span`,{class:`breakdown-label`},` Coverage Cost `,-1),createBaseVNode(`span`,_hoisted_35$8,[createVNode(unref(bngUnit_default),{money:props.insuranceData.nonProRatedVehiclePremium},null,8,[`money`])])]),createBaseVNode(`div`,_hoisted_36$8,[_cache[11]||=createBaseVNode(`span`,{class:`breakdown-label`},` Pro-rated Renewal `,-1),createBaseVNode(`span`,_hoisted_37$7,` × `+toDisplayString(props.insuranceData.proRatedPercentage)+`% `,1)]),props.insuranceData.groupDiscountData?.currentTierData.id>0?(openBlock(),createElementBlock(`div`,_hoisted_38$6,[createBaseVNode(`span`,_hoisted_39$6,` Tier `+toDisplayString(props.insuranceData.groupDiscountData?.currentTierData.id)+` discount `,1),createBaseVNode(`span`,_hoisted_40$5,` - `+toDisplayString(props.insuranceData.groupDiscountData?.currentTierData.discount*100)+`% `,1)])):createCommentVNode(``,!0),createBaseVNode(`div`,_hoisted_41$5,[_cache[12]||=createBaseVNode(`span`,{class:`breakdown-label`},` Policy Add-On Cost `,-1),createBaseVNode(`span`,_hoisted_42$4,[createVNode(unref(bngUnit_default),{money:props.insuranceData.proRatedVehiclePremium},null,8,[`money`])])])])]),createBaseVNode(`div`,_hoisted_43$4,[_cache[18]||=createBaseVNode(`div`,{class:`section-label`},` New Premium `,-1),createBaseVNode(`div`,_hoisted_44$4,[props.insuranceData.futurePremiumDetails.items.vehsCoverage?(openBlock(),createElementBlock(`div`,_hoisted_45$4,[_cache[14]||=createBaseVNode(`div`,{class:`breakdown-label`},` Vehicles Coverage `,-1),createBaseVNode(`div`,{class:normalizeClass([`breakdown-value strikethrough-container`,{"strikethrough-grey":props.insuranceData.futurePremiumDetails.groupDiscountSavings>0}])},[createVNode(unref(bngUnit_default),{money:props.insuranceData.futurePremiumDetails.items.vehsCoverage.priceWithoutGroupDiscount},null,8,[`money`]),props.insuranceData.futurePremiumDetails.groupDiscountSavings>0?(openBlock(),createElementBlock(`div`,_hoisted_46$2)):createCommentVNode(``,!0)],2)])):createCommentVNode(``,!0),props.insuranceData.futurePremiumDetails.items.vehsCoverage&&props.insuranceData.futurePremiumDetails.groupDiscountSavings>0?(openBlock(),createElementBlock(`div`,_hoisted_47$2,[createBaseVNode(`div`,_hoisted_48$2,[createTextVNode(toDisplayString(props.insuranceData.futurePremiumDetails.items.vehsCoverage.name)+` `,1),createBaseVNode(`span`,null,[createTextVNode(`: Tier `+toDisplayString(props.insuranceData.groupDiscountData.currentTierData.id)+` `,1),createBaseVNode(`span`,_hoisted_49$2,`(`+toDisplayString(props.insuranceData.groupDiscountData.currentTierData.discount*100)+`% off)`,1)])]),createBaseVNode(`div`,_hoisted_50$2,[createVNode(unref(bngUnit_default),{money:props.insuranceData.futurePremiumDetails.items.vehsCoverage.price},null,8,[`money`])])])):createCommentVNode(``,!0),(openBlock(!0),createElementBlock(Fragment,null,renderList(props.insuranceData.futurePremiumDetails.items,(item,key)=>(openBlock(),createElementBlock(Fragment,{key},[key===`vehsCoverage`?createCommentVNode(``,!0):(openBlock(),createElementBlock(`div`,_hoisted_51$2,[createBaseVNode(`div`,_hoisted_52$2,toDisplayString(item.name),1),createBaseVNode(`div`,_hoisted_53$2,[createVNode(unref(bngUnit_default),{money:item.price},null,8,[`money`])])]))],64))),128)),createBaseVNode(`div`,_hoisted_54$2,[_cache[15]||=createBaseVNode(`div`,{class:`breakdown-label`},` Subtotal `,-1),createBaseVNode(`div`,_hoisted_55$2,[createVNode(unref(bngUnit_default),{money:props.insuranceData.futurePremiumDetails.totalPrice},null,8,[`money`])])]),createBaseVNode(`div`,_hoisted_56$2,[_cache[16]||=createBaseVNode(`div`,{class:`breakdown-label`},` Driver Score Adjustment `,-1),createBaseVNode(`div`,{class:normalizeClass([`breakdown-value`,driverScoreClass.value])},toDisplayString(driverScoreAdjustmentText.value),3)]),createBaseVNode(`div`,_hoisted_57$1,[_cache[17]||=createBaseVNode(`div`,{class:`breakdown-label`},` Total Premium `,-1),createBaseVNode(`div`,_hoisted_58$1,[createVNode(unref(bngUnit_default),{money:props.insuranceData.futurePremiumDetails.totalPriceWithDriverScore},null,8,[`money`])])])])])]),createBaseVNode(`div`,_hoisted_59$1,[_cache[19]||=createBaseVNode(`span`,null,`Amount due today`,-1),createBaseVNode(`span`,_hoisted_60$1,[createVNode(unref(bngUnit_default),{class:`green-price`,money:props.insuranceData.addVehiclePrice},null,8,[`money`])])])]),createBaseVNode(`div`,_hoisted_61$1,[createVNode(unref(bngButton_default),{accent:unref(ACCENTS).primary,onClick:closePopup},{default:withCtx(()=>[..._cache[20]||=[createTextVNode(` Close `,-1)]]),_:1},8,[`accent`])])])]))}}),purchaseInsuranceDetails_default=__plugin_vue_export_helper_default(_sfc_main$280,[[`__scopeId`,`data-v-9f20c127`]]),_hoisted_1$249={class:`content`},_hoisted_2$206={class:`top-banner`},_hoisted_3$180={class:`top-banner-left`},_hoisted_4$153={class:`insurance-details`},_hoisted_5$133={class:`insurance-name`},_hoisted_6$114={class:`insurance-slogan`},_hoisted_7$101={class:`small-grey-text`},_hoisted_8$85={class:`small-grey-text`},_hoisted_9$75={class:`top-banner-right`},_hoisted_10$65={class:`information-wrapper`},_hoisted_11$58={class:`information-value`},_hoisted_12$47={class:`driver-score-tier`},_hoisted_13$40={class:`premium-effect`},_hoisted_14$37={class:`switching-details-wrapper`},_hoisted_15$35={class:`three-columns-grid`},_hoisted_16$34={class:`switching-column column-leaving`},_hoisted_17$28={class:`column-header`},_hoisted_18$25={class:`column-details`},_hoisted_19$22={class:`detail-item`},_hoisted_20$18={class:`detail-value`},_hoisted_21$16={class:`detail-item`},_hoisted_22$14={class:`detail-item divider-above`},_hoisted_23$13={class:`detail-value-positive`},_hoisted_24$12={class:`detail-item`},_hoisted_25$11={class:`detail-value-negative`},_hoisted_26$9={class:`detail-item divider-above`},_hoisted_27$9={class:`detail-value-positive-bold`},_hoisted_28$8={class:`detail-note`},_hoisted_29$8={class:`switching-column column-vehicle`},_hoisted_30$8={class:`vehicle-display-box`},_hoisted_31$8=[`src`],_hoisted_32$8={class:`column-details`},_hoisted_33$8={class:`detail-item`},_hoisted_34$8={class:`detail-value-bold`},_hoisted_35$7={class:`detail-item`},_hoisted_36$7={class:`detail-value-bold`},_hoisted_37$6={class:`detail-item divider-above`},_hoisted_38$5={class:`detail-value-highlight`},_hoisted_39$5={class:`detail-note`},_hoisted_40$4={class:`switching-column column-joining`},_hoisted_41$4={class:`column-header`},_hoisted_42$3={class:`column-details`},_hoisted_43$3={class:`detail-item`},_hoisted_44$3={class:`detail-value`},_hoisted_45$3={class:`detail-item`},_hoisted_46$1={class:`detail-item divider-above`},_hoisted_47$1={class:`detail-value-negative`},_hoisted_48$1={class:`detail-item divider-above`},_hoisted_49$1={class:`detail-item divider-above`},_hoisted_50$1={class:`detail-value-bold`},_hoisted_51$1={class:`detail-note`},_hoisted_52$1={class:`final-amount-content-row`},_hoisted_53$1={class:`final-amount-label`},_hoisted_54$1={class:`final-amount-breakdown`},_hoisted_55$1={class:`buttons`},_hoisted_56$1={key:0},_sfc_main$279={__name:`changeInsuranceDetails`,props:{insuranceData:{type:Object,required:!0},vehicleInfo:{type:Object,default:()=>({})},driverScoreData:{type:Object,default:()=>({})}},emits:[`return`,`switch`],setup(__props,{emit:__emit}){let{units}=useBridge(),props=__props,emit$1=__emit,premiumSavingPercent=computed(()=>(1-(props.driverScoreData?.tier?.multiplier||1))*100),leavingInfo=computed(()=>props.insuranceData.leavingInsuranceInfo||null),leavingInsuranceName=computed(()=>leavingInfo.value?.currentInsuranceName||`Current Insurance`),tierDropped=computed(()=>leavingInfo.value?leavingInfo.value.discountTierData?.id>leavingInfo.value.newDiscountTierData?.id:!1),tierIncreased=computed(()=>{let current=props.insuranceData.groupDiscountData?.currentTierData?.id||0;return(props.insuranceData.groupDiscountData?.futureTierData?.id||current)>current}),currentTierId=computed(()=>props.insuranceData.groupDiscountData?.currentTierData?.id||0),futureTierId=computed(()=>props.insuranceData.groupDiscountData?.futureTierData?.id||props.insuranceData.groupDiscountData?.currentTierData?.id||0),proRatedPercentage=computed(()=>Math.round(props.insuranceData.proRatedPercentage||100)),driverScoreImpactPercent=computed(()=>(1-(props.driverScoreData?.tier?.multiplier||1))*100),driverScoreImpactClass=computed(()=>driverScoreImpactPercent.value>0?`saving`:driverScoreImpactPercent.value<0?`increase`:`neutral`),driverScoreImpactText=computed(()=>driverScoreImpactPercent.value>0?`↓${driverScoreImpactPercent.value.toFixed(0)}%`:driverScoreImpactPercent.value<0?`↑${Math.abs(driverScoreImpactPercent.value).toFixed(0)}%`:`0%`),renewsEveryFormatted=computed(()=>props.insuranceData?.renewsEvery?units.buildString(`length`,props.insuranceData.renewsEvery*1e3,0):``),renewsInFormatted=computed(()=>props.insuranceData?.renewsIn?units.buildString(`length`,props.insuranceData.renewsIn*1e3,0):``),leavingRenewsInFormatted=computed(()=>leavingInfo.value?.renewsIn?units.buildString(`length`,leavingInfo.value.renewsIn*1e3,0):``),closePopup=()=>{emit$1(`return`,!0)},onSwitchClick=()=>{Lua_default.career_modules_insurance_insurance.changeInvVehInsurance(props.vehicleInfo.invVehId,props.insuranceData.id),emit$1(`return`,!0)};return(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$249,[createBaseVNode(`div`,_hoisted_2$206,[createBaseVNode(`div`,_hoisted_3$180,[_cache[2]||=createBaseVNode(`div`,{class:`title`},` Change Insurance `,-1),createBaseVNode(`div`,_hoisted_4$153,[createBaseVNode(`span`,_hoisted_5$133,toDisplayString(props.insuranceData.name),1),_cache[0]||=createBaseVNode(`span`,{class:`name-slogan-seperator`},null,-1),createBaseVNode(`span`,_hoisted_6$114,` "`+toDisplayString(props.insuranceData.slogan)+`" `,1)]),createBaseVNode(`div`,null,[createBaseVNode(`span`,_hoisted_7$101,` Covers `+toDisplayString(props.insuranceData.carsInsuredCount)+` Vehicles `,1),_cache[1]||=createBaseVNode(`span`,{class:`dot-seperator`},null,-1),createBaseVNode(`span`,_hoisted_8$85,` Renews every `+toDisplayString(renewsEveryFormatted.value),1)])]),createBaseVNode(`div`,_hoisted_9$75,[createBaseVNode(`div`,_hoisted_10$65,[_cache[4]||=createBaseVNode(`div`,{class:`small-grey-text`},` Driver Score `,-1),createBaseVNode(`div`,_hoisted_11$58,toDisplayString(props.driverScoreData.score)+`: `+toDisplayString(props.driverScoreData.tier.risk),1),createBaseVNode(`div`,_hoisted_12$47,toDisplayString(props.driverScoreData.tier.name),1),createBaseVNode(`div`,_hoisted_13$40,[_cache[3]||=createBaseVNode(`span`,{class:`small-grey-text`},` Premium Effect : `,-1),createBaseVNode(`span`,{class:normalizeClass([`premium-effect-value`,{saving:premiumSavingPercent.value>0,increase:premiumSavingPercent.value<0}])},toDisplayString(premiumSavingPercent.value>0?`${premiumSavingPercent.value.toFixed(0)}% saving`:premiumSavingPercent.value<0?`${Math.abs(premiumSavingPercent.value).toFixed(0)}% increase`:`No change`),3)])])])]),createBaseVNode(`div`,_hoisted_14$37,[createBaseVNode(`div`,_hoisted_15$35,[createBaseVNode(`div`,_hoisted_16$34,[createBaseVNode(`div`,_hoisted_17$28,[_cache[5]||=createBaseVNode(`span`,null,`←`,-1),createTextVNode(` Leaving `+toDisplayString(leavingInsuranceName.value),1)]),createBaseVNode(`div`,_hoisted_18$25,[createBaseVNode(`div`,_hoisted_19$22,[_cache[6]||=createBaseVNode(`span`,{class:`detail-label`},`Vehicles:`,-1),createBaseVNode(`span`,_hoisted_20$18,toDisplayString(leavingInfo.value.vehicleCount)+` → `+toDisplayString(leavingInfo.value.newVehicleCount),1)]),createBaseVNode(`div`,_hoisted_21$16,[_cache[7]||=createBaseVNode(`span`,{class:`detail-label`},`Discount Tier:`,-1),createBaseVNode(`span`,{class:normalizeClass([`detail-value`,{"tier-change-down":tierDropped.value}])},toDisplayString(leavingInfo.value.discountTierData.id)+` → `+toDisplayString(leavingInfo.value.newDiscountTierData.id),3)]),createBaseVNode(`div`,_hoisted_22$14,[_cache[9]||=createBaseVNode(`span`,{class:`detail-label`},`Coverage refund:`,-1),createBaseVNode(`span`,_hoisted_23$13,[_cache[8]||=createTextVNode(`+`,-1),createVNode(unref(bngUnit_default),{money:leavingInfo.value.coverageRefundPrice},null,8,[`money`])])]),createBaseVNode(`div`,_hoisted_24$12,[_cache[11]||=createBaseVNode(`span`,{class:`detail-label`},`Cancellation fee (25%):`,-1),createBaseVNode(`span`,_hoisted_25$11,[_cache[10]||=createTextVNode(`-`,-1),createVNode(unref(bngUnit_default),{money:leavingInfo.value.earlyTerminationPenalty},null,8,[`money`])])]),createBaseVNode(`div`,_hoisted_26$9,[_cache[12]||=createBaseVNode(`span`,{class:`detail-label-bold`},`Net Refund:`,-1),createBaseVNode(`span`,_hoisted_27$9,[createVNode(unref(bngUnit_default),{money:leavingInfo.value.netRefundPrice},null,8,[`money`])])]),createBaseVNode(`div`,_hoisted_28$8,toDisplayString(leavingRenewsInFormatted.value)+` unused `,1)])]),createBaseVNode(`div`,_hoisted_29$8,[_cache[16]||=createBaseVNode(`div`,{class:`column-header column-header-center`},`Moving Vehicle`,-1),createBaseVNode(`div`,_hoisted_30$8,[createBaseVNode(`img`,{src:props.vehicleInfo?.thumbnail,alt:``,class:`vehicle-thumbnail`},null,8,_hoisted_31$8)]),createBaseVNode(`div`,_hoisted_32$8,[createBaseVNode(`div`,_hoisted_33$8,[_cache[13]||=createBaseVNode(`span`,{class:`detail-label`},`Vehicle:`,-1),createBaseVNode(`span`,_hoisted_34$8,toDisplayString(props.vehicleInfo.Name),1)]),createBaseVNode(`div`,_hoisted_35$7,[_cache[14]||=createBaseVNode(`span`,{class:`detail-label`},`Value:`,-1),createBaseVNode(`span`,_hoisted_36$7,[createVNode(unref(bngUnit_default),{money:props.vehicleInfo.Value},null,8,[`money`])])]),createBaseVNode(`div`,_hoisted_37$6,[_cache[15]||=createBaseVNode(`span`,{class:`detail-label`},`Joining mid-cycle:`,-1),createBaseVNode(`span`,_hoisted_38$5,`× `+toDisplayString(proRatedPercentage.value)+`%`,1)]),createBaseVNode(`div`,_hoisted_39$5,toDisplayString(renewsInFormatted.value)+` remaining in cycle `,1)])]),createBaseVNode(`div`,_hoisted_40$4,[createBaseVNode(`div`,_hoisted_41$4,[createTextVNode(` Joining `+toDisplayString(props.insuranceData.name)+` `,1),_cache[17]||=createBaseVNode(`span`,null,`→`,-1)]),createBaseVNode(`div`,_hoisted_42$3,[createBaseVNode(`div`,_hoisted_43$3,[_cache[18]||=createBaseVNode(`span`,{class:`detail-label`},`Vehicles:`,-1),createBaseVNode(`span`,_hoisted_44$3,toDisplayString(props.insuranceData.carsInsuredCount)+` → `+toDisplayString(props.insuranceData.carsInsuredCount+1),1)]),createBaseVNode(`div`,_hoisted_45$3,[_cache[19]||=createBaseVNode(`span`,{class:`detail-label`},`Discount Tier:`,-1),createBaseVNode(`span`,{class:normalizeClass([`detail-value`,{"tier-change-up":tierIncreased.value}])},toDisplayString(currentTierId.value)+` → `+toDisplayString(futureTierId.value),3)]),createBaseVNode(`div`,_hoisted_46$1,[_cache[21]||=createBaseVNode(`span`,{class:`detail-label`},`Add vehicle cost:`,-1),createBaseVNode(`span`,_hoisted_47$1,[_cache[20]||=createTextVNode(`+`,-1),createVNode(unref(bngUnit_default),{money:props.insuranceData.addVehiclePrice},null,8,[`money`])])]),createBaseVNode(`div`,_hoisted_48$1,[_cache[22]||=createBaseVNode(`span`,{class:`detail-label`},`Driver Score Impact:`,-1),createBaseVNode(`span`,{class:normalizeClass([`detail-value-impact`,driverScoreImpactClass.value])},toDisplayString(driverScoreImpactText.value),3)]),createBaseVNode(`div`,_hoisted_49$1,[_cache[23]||=createBaseVNode(`span`,{class:`detail-label-bold`},`New Policy Premium:`,-1),createBaseVNode(`span`,_hoisted_50$1,[createVNode(unref(bngUnit_default),{money:props.insuranceData.futurePremiumDetails.totalPriceWithDriverScore},null,8,[`money`])])]),createBaseVNode(`div`,_hoisted_51$1,toDisplayString(renewsInFormatted.value)+` until renewal `,1)])])]),createBaseVNode(`div`,{class:normalizeClass([`final-amount-box`,props.insuranceData.netSwitchingCost>0?`amount-credit`:`amount-payment`])},[createBaseVNode(`div`,_hoisted_52$1,[createBaseVNode(`div`,null,[createBaseVNode(`div`,_hoisted_53$1,toDisplayString(props.insuranceData.netSwitchingCost>0?`Credit Received Today`:`Amount Due Today`),1),createBaseVNode(`div`,_hoisted_54$1,[createVNode(unref(bngUnit_default),{money:leavingInfo.value.netRefundPrice},null,8,[`money`]),_cache[24]||=createTextVNode(` refund - `,-1),createVNode(unref(bngUnit_default),{money:props.insuranceData.addVehiclePrice},null,8,[`money`]),_cache[25]||=createTextVNode(` new cost `,-1)])]),createBaseVNode(`div`,{class:normalizeClass([`final-amount-total`,props.insuranceData.netSwitchingCost<0?`negative`:`positive`])},[createVNode(unref(bngUnit_default),{money:Math.abs(props.insuranceData.netSwitchingCost)},null,8,[`money`])],2)])],2)]),createBaseVNode(`div`,_hoisted_55$1,[createVNode(unref(bngButton_default),{class:`gray-button bigger-button`,accent:`custom`,onClick:closePopup},{default:withCtx(()=>[..._cache[26]||=[createTextVNode(` Cancel `,-1)]]),_:1}),createVNode(unref(bngButton_default),{class:`save-button bigger-button`,accent:`custom`,onClick:onSwitchClick},{default:withCtx(()=>[_cache[27]||=createTextVNode(` Switch for `,-1),props.insuranceData.netSwitchingCost<0?(openBlock(),createElementBlock(`div`,_hoisted_56$1,[createVNode(unref(bngUnit_default),{money:Math.abs(props.insuranceData.netSwitchingCost)},null,8,[`money`])])):createCommentVNode(``,!0)]),_:1})])]))}},changeInsuranceDetails_default=__plugin_vue_export_helper_default(_sfc_main$279,[[`__scopeId`,`data-v-9624a106`]]),_hoisted_1$248={class:`insurance-tiers`},_hoisted_2$205={key:0},_sfc_main$278={__name:`insuranceTiers`,props:{tiers:{type:Array,required:!0},showTier:{type:Boolean,default:!1}},setup(__props){let props=__props;return(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$248,[(openBlock(!0),createElementBlock(Fragment,null,renderList(props.tiers,tier=>(openBlock(),createElementBlock(`div`,{class:`tier`,key:tier.id},[createBaseVNode(`div`,{class:normalizeClass([`tier-discount`,{isCurrent:tier.isCurrent}])},[props.showTier?(openBlock(),createElementBlock(`div`,_hoisted_2$205,` Tier `+toDisplayString(tier.id),1)):createCommentVNode(``,!0),createBaseVNode(`div`,null,toDisplayString(tier.discount*100)+`% `,1)],2)]))),128))]))}},insuranceTiers_default=__plugin_vue_export_helper_default(_sfc_main$278,[[`__scopeId`,`data-v-ccd1e875`]]),_hoisted_1$247={class:`popup-content`},_hoisted_2$204={class:`top-banner`},_hoisted_3$179={class:`top-info`},_hoisted_4$152={class:`top-info-title`},_hoisted_5$132={class:`top-info-policy-name`},_hoisted_6$113={class:`customize-coverage section`},_hoisted_7$100={class:`premium-details section`},_hoisted_8$84={class:`premium-details-content`},_hoisted_9$74={class:`premium-details-left`},_hoisted_10$64={class:`premium-details-label`},_hoisted_11$57={class:`premium-details-right`},_hoisted_12$46={key:0,class:`price-diff-container`},_hoisted_13$39={class:`premium-details-total premium-details-item`},_hoisted_14$36={class:`premium-details-left`},_hoisted_15$34={class:`driver-score-details-wrapper`},_hoisted_16$33={class:`driver-score-details`},_hoisted_17$27={class:`premium-details-right`},_hoisted_18$24={key:0,class:`price-diff-container`},_hoisted_19$21={class:`buttons`},_sfc_main$277={__name:`editPolicy`,props:{insuranceData:{type:Object,required:!0},driverScoreData:{type:Object,required:!0}},emits:[`return`],setup(__props,{emit:__emit}){let props=__props,changedCoverageOptions=ref({}),newPremiumDetails=ref({}),computedNewPremiumDiffs=computed(()=>{if(!newPremiumDetails.value?.items)return{};let diffs={};for(let key in newPremiumDetails.value.items){let newPrice=newPremiumDetails.value.items[key]?.price||0,oldPrice=props.insuranceData.currentPremiumDetails.items[key]?.price||0;diffs[key]={priceDiff:newPrice-oldPrice,newPrice,oldPrice}}return diffs}),computedTotalPriceDiff=computed(()=>newPremiumDetails.value?.totalPrice?newPremiumDetails.value.totalPrice-props.insuranceData.currentPremiumDetails.totalPrice:0),driverScoreColorClass=computed(()=>{let multiplier=props.driverScoreData?.tier?.multiplier;return multiplier?multiplier<1?`driver-score-good`:multiplier>1?`driver-score-bad`:``:``}),hasChangedCoverageOptions=computed(()=>props.insuranceData?.coverageOptionsData?props.insuranceData.coverageOptionsData.some(option=>changedCoverageOptions.value[option.key]!==option.currentValueId):!1);onMounted(()=>{props.insuranceData?.coverageOptionsData&&props.insuranceData.coverageOptionsData.forEach(option=>{changedCoverageOptions.value[option.key]=option.currentValueId})});let emit$1=__emit,closePopup=()=>{emit$1(`return`,!0)},openVehicleList=()=>{addPopup(vehicleInsuranceList_default,{insuranceData:props.insuranceData,driverScoreData:props.driverScoreData}),closePopup()},onSaveClick=()=>{Lua_default.career_modules_insurance_insurance.saveNewInsuranceCoverageOptions(props.insuranceData.id,changedCoverageOptions.value),emit$1(`return`,!0)},updatePremiumDetails=async()=>{newPremiumDetails.value=await Lua_default.career_modules_insurance_insurance.calculateInsurancePremium(props.insuranceData.id,changedCoverageOptions.value,null)},onToggleChange=(coverageOption,newValue)=>{let targetChoiceIndex=coverageOption.choices.findIndex(choice=>choice.value===newValue);targetChoiceIndex!==-1&&(changedCoverageOptions.value[coverageOption.key]=targetChoiceIndex+1,updatePremiumDetails())},onChoiceClick=(coverageOption,choice)=>{changedCoverageOptions.value[coverageOption.key]=choice.id,updatePremiumDetails()};return(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$247,[createBaseVNode(`div`,_hoisted_2$204,[createBaseVNode(`div`,_hoisted_3$179,[createBaseVNode(`div`,_hoisted_4$152,[_cache[0]||=createTextVNode(` Edit Policy: `,-1),createBaseVNode(`span`,_hoisted_5$132,toDisplayString(props.insuranceData.name),1)]),_cache[1]||=createBaseVNode(`div`,{class:`top-info-description`},` These settings apply to all vehicles under this policy. Set deductibles per vehicle by clicking "Edit Vehicles" `,-1)]),createVNode(unref(bngButton_default),{class:`edit-vehicles-button`,accent:`custom`,onClick:openVehicleList},{default:withCtx(()=>[..._cache[2]||=[createTextVNode(` Edit Vehicles `,-1)]]),_:1})]),createBaseVNode(`div`,_hoisted_6$113,[(openBlock(!0),createElementBlock(Fragment,null,renderList(props.insuranceData.coverageOptionsData,coverageOption=>(openBlock(),createBlock(unref(coverageOption_default),{key:coverageOption.name,coverageOption,changedCoverageOptions:changedCoverageOptions.value,onChoiceClick,onToggleChange},null,8,[`coverageOption`,`changedCoverageOptions`]))),128))]),createBaseVNode(`div`,_hoisted_7$100,[_cache[5]||=createBaseVNode(`div`,{class:`premium-details-header`},` Premium Breakdown `,-1),createBaseVNode(`div`,_hoisted_8$84,[(openBlock(!0),createElementBlock(Fragment,null,renderList(props.insuranceData.currentPremiumDetails.items,(detail,key)=>(openBlock(),createElementBlock(`div`,{class:`premium-details-item`,key},[createBaseVNode(`div`,_hoisted_9$74,[createBaseVNode(`div`,_hoisted_10$64,toDisplayString(detail.name),1)]),createBaseVNode(`div`,_hoisted_11$57,[computedNewPremiumDiffs.value[key]&&computedNewPremiumDiffs.value[key].priceDiff!==0?(openBlock(),createElementBlock(`div`,_hoisted_12$46,[createBaseVNode(`span`,{class:normalizeClass([`arrow`,{"green-price":computedNewPremiumDiffs.value[key].priceDiff<0,"red-price":computedNewPremiumDiffs.value[key].priceDiff>0}])},toDisplayString(computedNewPremiumDiffs.value[key].priceDiff>0?`↑`:`↓`),3),createVNode(unref(bngUnit_default),{class:normalizeClass([`price-diff`,{"green-price":computedNewPremiumDiffs.value[key].priceDiff<0,"red-price":computedNewPremiumDiffs.value[key].priceDiff>0}]),money:computedNewPremiumDiffs.value[key].priceDiff},null,8,[`class`,`money`])])):createCommentVNode(``,!0),createVNode(unref(bngUnit_default),{money:newPremiumDetails.value?.items?.[key]?.price||detail.price},null,8,[`money`])])]))),128)),createBaseVNode(`div`,_hoisted_13$39,[createBaseVNode(`div`,_hoisted_14$36,[_cache[4]||=createBaseVNode(`div`,null,` Final Premium `,-1),createBaseVNode(`div`,_hoisted_15$34,[createBaseVNode(`span`,_hoisted_16$33,[_cache[3]||=createTextVNode(` Base Premium : `,-1),createVNode(unref(bngUnit_default),{money:props.insuranceData.currentPremiumDetails.totalPrice},null,8,[`money`]),createTextVNode(` × Driver Score `+toDisplayString(props.driverScoreData.score)+` @ `,1)]),createBaseVNode(`span`,{class:normalizeClass([`driver-score`,driverScoreColorClass.value])},toDisplayString(Math.round(props.driverScoreData.tier.multiplier*100))+`% `,3)])]),createBaseVNode(`div`,_hoisted_17$27,[computedTotalPriceDiff.value===0?createCommentVNode(``,!0):(openBlock(),createElementBlock(`div`,_hoisted_18$24,[createBaseVNode(`span`,{class:normalizeClass([`arrow`,{"green-price":computedTotalPriceDiff.value<0,"red-price":computedTotalPriceDiff.value>0}])},toDisplayString(computedTotalPriceDiff.value>0?`↑`:`↓`),3),createVNode(unref(bngUnit_default),{class:normalizeClass([`price-diff`,{"green-price":computedTotalPriceDiff.value<0,"red-price":computedTotalPriceDiff.value>0}]),money:computedTotalPriceDiff.value},null,8,[`class`,`money`])])),createVNode(unref(bngUnit_default),{money:newPremiumDetails.value?.totalPriceWithDriverScore||props.insuranceData.currentPremiumDetails.totalPriceWithDriverScore},null,8,[`money`])])])])]),createBaseVNode(`div`,_hoisted_19$21,[createVNode(unref(bngButton_default),{class:`cancel-button bigger-button`,accent:`custom`,onClick:closePopup},{default:withCtx(()=>[..._cache[6]||=[createTextVNode(` Cancel `,-1)]]),_:1}),createVNode(unref(bngButton_default),{class:`save-button bigger-button`,accent:`custom`,onClick:onSaveClick,disabled:!props.insuranceData.canPayPaperworkFees||!hasChangedCoverageOptions.value},{default:withCtx(()=>[props.insuranceData.canPayPaperworkFees?(openBlock(),createElementBlock(Fragment,{key:1},[_cache[7]||=createTextVNode(` Apply for `,-1),createVNode(unref(bngUnit_default),{money:props.insuranceData.paperworkFees},null,8,[`money`])],64)):(openBlock(),createElementBlock(Fragment,{key:0},[createTextVNode(` Insufficient funds `)],64))]),_:1},8,[`disabled`])])]))}},editPolicy_default=__plugin_vue_export_helper_default(_sfc_main$277,[[`__scopeId`,`data-v-081fecf3`]]),_sfc_main$276={__name:`insurancePerkIcon`,props:{perkIconData:{type:Object,required:!0}},setup(__props){let props=__props,computedColor=computed(()=>props.perkIconData.isSignaturePerk===void 0?props.perkIconData.color:props.perkIconData.isSignaturePerk?`green`:`blue`);return(_ctx,_cache)=>withDirectives((openBlock(),createElementBlock(`div`,{class:normalizeClass({"insurance-perk-icon":!__props.perkIconData.iconOnly,[computedColor.value]:computedColor.value})},[createVNode(unref(bngIcon_default),{type:unref(icons).shieldCheckmark,class:normalizeClass({"glowing-icon":!0,[computedColor.value]:computedColor.value})},null,8,[`type`,`class`]),__props.perkIconData.iconOnly?createCommentVNode(``,!0):(openBlock(),createElementBlock(`span`,{key:0,class:normalizeClass({"small-text":!0,[computedColor.value]:computedColor.value})},toDisplayString(__props.perkIconData.smallText),3))],2)),[[unref(BngTooltip_default),__props.perkIconData.iconOnly?null:__props.perkIconData.tooltipText,`top`]])}},insurancePerkIcon_default=__plugin_vue_export_helper_default(_sfc_main$276,[[`__scopeId`,`data-v-d2b025b6`]]),_hoisted_1$246={class:`insurance-perks-container`},_hoisted_2$203={class:`left`},_hoisted_3$178={class:`insurance-perk-icon-wrapper`},_hoisted_4$151={key:1},_hoisted_5$131={class:`insurance-perk-texts`},_hoisted_6$112={class:`insurance-perk-intro`},_hoisted_7$99={key:0,class:`insurance-perk-description`},_hoisted_8$83={key:0,class:`signature-perk-wrapper`},_sfc_main$275={__name:`insurancePerks`,props:{insuranceData:Object,noDescription:Boolean},setup(__props){let props=__props,sortedPerks=computed(()=>props.insuranceData.perks?[...Array.isArray(props.insuranceData.perks)?props.insuranceData.perks:Object.values(props.insuranceData.perks)].sort((a$1,b)=>Number(b.isSignaturePerk||!1)-Number(a$1.isSignaturePerk||!1)):[]);return(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$246,[(openBlock(!0),createElementBlock(Fragment,null,renderList(sortedPerks.value,perk=>(openBlock(),createElementBlock(`div`,{key:perk.id,class:normalizeClass([`insurance-perk`,{highlighted:perk.isSignaturePerk,"no-insurance":__props.insuranceData.id===-1}])},[createBaseVNode(`div`,_hoisted_2$203,[createBaseVNode(`div`,_hoisted_3$178,[__props.insuranceData.id===-1?(openBlock(),createElementBlock(`span`,_hoisted_4$151,`-`)):(openBlock(),createBlock(insurancePerkIcon_default,{key:0,perkIconData:{iconOnly:!0,isSignaturePerk:perk.isSignaturePerk&&perk.isSignaturePerk||!1}},null,8,[`perkIconData`]))]),createBaseVNode(`div`,_hoisted_5$131,[createBaseVNode(`div`,_hoisted_6$112,toDisplayString(perk.intro),1),__props.noDescription?createCommentVNode(``,!0):(openBlock(),createElementBlock(`div`,_hoisted_7$99,toDisplayString(perk.description),1))])]),perk.isSignaturePerk?(openBlock(),createElementBlock(`div`,_hoisted_8$83,[..._cache[0]||=[createBaseVNode(`div`,{class:`signature-perk`},` SIGNATURE PERK `,-1)]])):createCommentVNode(``,!0)],2))),128))]))}},insurancePerks_default=__plugin_vue_export_helper_default(_sfc_main$275,[[`__scopeId`,`data-v-75e74910`]]),_hoisted_1$245={class:`insurance-perk-notice`},_sfc_main$274={__name:`insurancePerkNotice`,props:{perkText:{type:String,required:!0}},setup(__props){let props=__props;return(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$245,[createVNode(insurancePerkIcon_default,{perkIconData:{iconOnly:!0}}),createTextVNode(` `+toDisplayString(props.perkText),1)]))}},insurancePerkNotice_default=__plugin_vue_export_helper_default(_sfc_main$274,[[`__scopeId`,`data-v-a98b3238`]]),_hoisted_1$244={class:`popup-content`},_hoisted_2$202={class:`top-info`},_hoisted_3$177={class:`top-info-title`},_hoisted_4$150={class:`top-info-veh-name`},_hoisted_5$130={class:`top-info-value-and-insurance`},_hoisted_6$111={class:`section`},_hoisted_7$98={class:`section`},_hoisted_8$82={class:`contribution-wrapper`},_hoisted_9$73={class:`contribution-item-value`},_hoisted_10$63={key:0,class:`price-diff-container`},_hoisted_11$56={class:`contribution-item-value`},_hoisted_12$45={key:0,class:`price-diff-container`},_hoisted_13$38={class:`buttons`},_sfc_main$273={__name:`editVehicleCoverage`,props:{insuranceData:{type:Object,required:!0},vehicleData:{type:Object,required:!0}},emits:[`return`],setup(__props,{emit:__emit}){let props=__props,newPremiumPrice=ref(0),newInsurancePremiumDetails=ref({totalPriceWithDriverScore:0}),computedNewPremiumDiff=computed(()=>newPremiumPrice.value-props.vehicleData.insuranceData.currentPremiumPrice),computedNewInsurancePremiumDiff=computed(()=>newInsurancePremiumDetails.value.totalPriceWithDriverScore-props.insuranceData.currentPremiumDetails.totalPriceWithDriverScore),hasChangedCoverageOptions=computed(()=>props.vehicleData?.insuranceData?.coverageOptionsData?.currentCoverageOptionsSanitized?props.vehicleData.insuranceData.coverageOptionsData.currentCoverageOptionsSanitized.some(option=>changedCoverageOptions.value[option.key]!==option.currentValueId):!1),emit$1=__emit,closePopup=()=>{emit$1(`return`,!0)},changedCoverageOptions=ref({}),updatePremiumPrice=async()=>{newPremiumPrice.value=(await Lua_default.career_modules_insurance_insurance.calculateVehiclePremium(props.vehicleData.id,null,changedCoverageOptions.value)).cost,newInsurancePremiumDetails.value=await Lua_default.career_modules_insurance_insurance.calculateInsurancePremium(props.insuranceData.id,null,{[props.vehicleData.id]:changedCoverageOptions.value})},onChoiceClick=(coverageOption,choice)=>{changedCoverageOptions.value[coverageOption.key]=choice.id,updatePremiumPrice()},onToggleChange=(coverageOption,newValue)=>{let targetChoiceIndex=coverageOption.choices.findIndex(choice=>choice.value===newValue);targetChoiceIndex!==-1&&(changedCoverageOptions.value[coverageOption.key]=targetChoiceIndex+1),updatePremiumPrice()},onSaveClick=()=>{Lua_default.career_modules_insurance_insurance.saveNewVehicleCoverageOptions(props.vehicleData.id,changedCoverageOptions.value),emit$1(`return`,!0)},openSwitchProvider=()=>{addPopup(ChooseInsuranceMain_default,{menuMode:`change`,params:{vehicleId:props.vehicleData.id}})};return onMounted(()=>{props.vehicleData.insuranceData.coverageOptionsData.currentCoverageOptionsSanitized.forEach(option=>{changedCoverageOptions.value[option.key]=option.currentValueId}),updatePremiumPrice()}),(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$244,[createBaseVNode(`div`,_hoisted_2$202,[createBaseVNode(`div`,_hoisted_3$177,[_cache[0]||=createTextVNode(` Select Deductible: `,-1),createBaseVNode(`span`,_hoisted_4$150,toDisplayString(props.vehicleData.name),1)]),createBaseVNode(`div`,_hoisted_5$130,[_cache[1]||=createTextVNode(` Value: `,-1),createVNode(unref(bngUnit_default),{money:props.vehicleData.initialValue},null,8,[`money`]),createTextVNode(` • Policy: `+toDisplayString(props.insuranceData.name),1)]),_cache[2]||=createBaseVNode(`div`,{class:`top-info-description`},` Choose how much you'll pay out-of-pocket when repairing this vehicle. Lower deductibles cost more per km. `,-1)]),createBaseVNode(`div`,_hoisted_6$111,[_cache[3]||=createBaseVNode(`div`,null,[createBaseVNode(`div`,{class:`header title`},` Choose Your Deductible `),createBaseVNode(`div`,{class:`under-title`},` You pay this amount per repair. `)],-1),createBaseVNode(`div`,null,[(openBlock(!0),createElementBlock(Fragment,null,renderList(props.vehicleData.insuranceData.coverageOptionsData.currentCoverageOptionsSanitized,coverageOption=>(openBlock(),createBlock(unref(coverageOption_default),{class:`coverage-option`,key:coverageOption.name,coverageOption,onlyShowMainText:!0,changedCoverageOptions:changedCoverageOptions.value,dontShowName:!0,onChoiceClick,onToggleChange},null,8,[`coverageOption`,`changedCoverageOptions`]))),128))])]),createBaseVNode(`div`,_hoisted_7$98,[_cache[6]||=createBaseVNode(`div`,{class:`title`},` Policy Impact `,-1),createBaseVNode(`div`,_hoisted_8$82,[createBaseVNode(`div`,{class:normalizeClass([`contribution-item`,{green:computedNewInsurancePremiumDiff.value<0,red:computedNewInsurancePremiumDiff.value>0}])},[_cache[4]||=createBaseVNode(`div`,{class:`contribution-item-title`},` Insurance Premium `,-1),createBaseVNode(`div`,_hoisted_9$73,[createVNode(unref(bngUnit_default),{money:props.insuranceData.currentPremiumDetails.totalPriceWithDriverScore},null,8,[`money`]),computedNewInsurancePremiumDiff.value!==0&&!isNaN(computedNewInsurancePremiumDiff.value)?(openBlock(),createElementBlock(`div`,_hoisted_10$63,` → `)):createCommentVNode(``,!0),computedNewInsurancePremiumDiff.value!==0&&!isNaN(computedNewInsurancePremiumDiff.value)?(openBlock(),createBlock(unref(bngUnit_default),{key:1,money:newInsurancePremiumDetails.value.totalPriceWithDriverScore},null,8,[`money`])):createCommentVNode(``,!0)])],2),createBaseVNode(`div`,{class:normalizeClass([`contribution-item`,{green:computedNewInsurancePremiumDiff.value<0,red:computedNewInsurancePremiumDiff.value>0}])},[_cache[5]||=createBaseVNode(`div`,{class:`contribution-item-title`},` Vehicle Contribution `,-1),createBaseVNode(`div`,_hoisted_11$56,[createVNode(unref(bngUnit_default),{money:props.vehicleData.insuranceData.currentPremiumPrice},null,8,[`money`]),computedNewPremiumDiff.value!==0&&!isNaN(computedNewPremiumDiff.value)?(openBlock(),createElementBlock(`div`,_hoisted_12$45,` → `)):createCommentVNode(``,!0),computedNewPremiumDiff.value!==0&&!isNaN(computedNewPremiumDiff.value)?(openBlock(),createBlock(unref(bngUnit_default),{key:1,money:newPremiumPrice.value},null,8,[`money`])):createCommentVNode(``,!0)])],2)])]),createBaseVNode(`div`,_hoisted_13$38,[createVNode(unref(bngButton_default),{class:`gray-button bigger-button`,accent:`custom`,onClick:closePopup},{default:withCtx(()=>[..._cache[7]||=[createTextVNode(` Cancel `,-1)]]),_:1}),createVNode(unref(bngButton_default),{class:`save-button bigger-button`,accent:`custom`,onClick:onSaveClick,disabled:!props.insuranceData.canPayPaperworkFees||!hasChangedCoverageOptions.value},{default:withCtx(()=>[props.insuranceData.canPayPaperworkFees?(openBlock(),createElementBlock(Fragment,{key:1},[_cache[8]||=createTextVNode(` Apply for `,-1),createVNode(unref(bngUnit_default),{money:props.insuranceData.paperworkFees},null,8,[`money`])],64)):(openBlock(),createElementBlock(Fragment,{key:0},[createTextVNode(` Insufficient funds `)],64))]),_:1},8,[`disabled`]),createVNode(unref(bngButton_default),{class:`gray-button bigger-button`,accent:`custom`,onClick:openSwitchProvider},{default:withCtx(()=>[..._cache[9]||=[createTextVNode(` Switch Provider `,-1)]]),_:1})])]))}},editVehicleCoverage_default=__plugin_vue_export_helper_default(_sfc_main$273,[[`__scopeId`,`data-v-9f014d2d`]]),_hoisted_1$243=[`innerHTML`],_hoisted_2$201={key:2,class:`insurance-icon`},_hoisted_3$176={class:`insurance-name`},_hoisted_4$149={key:3,class:`insurance-slogan`},_sfc_main$272={__name:`insuranceIdentity`,props:{insuranceData:{type:Object,required:!0}},setup(__props){let props=__props,hasInsurance=computed(()=>svgContent.value||props.insuranceData.image),hasNoInsurance=computed(()=>props.insuranceData?.id===-1),svgContent=ref(null);return watch(()=>props.insuranceData.image,async newPath=>{if(newPath&&newPath.endsWith(`.svg`))try{let rawSvg=await getFile(`/${newPath}`);rawSvg?svgContent.value=rawSvg.replace(/]*>([\s\S]*?)<\/script>/gim,``).replace(/ on\w+="[^"]*"/g,``):svgContent.value=null}catch(e){console.warn(`Failed to load SVG inline:`,newPath,e),svgContent.value=null}else svgContent.value=null},{immediate:!0}),(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,{class:normalizeClass([`insurance-identity`,{"no-insurance":!hasInsurance.value}])},[svgContent.value?(openBlock(),createElementBlock(`div`,{key:0,class:`insurance-icon`,innerHTML:svgContent.value},null,8,_hoisted_1$243)):props.insuranceData.image?(openBlock(),createBlock(unref(bngImage_default),{key:1,class:`insurance-icon`,src:`/${props.insuranceData.image}`,alt:props.insuranceData.name},null,8,[`src`,`alt`])):(openBlock(),createElementBlock(`div`,_hoisted_2$201,[createBaseVNode(`div`,_hoisted_3$176,[createVNode(unref(bngIcon_default),{class:`insurance-no-icon`,type:unref(icons).danger},null,8,[`type`]),createTextVNode(` `+toDisplayString(hasNoInsurance.value?_ctx.$t(`ui.career.insurance.noInsurance`):props.insuranceData.name),1)])])),hasNoInsurance.value?createCommentVNode(``,!0):(openBlock(),createElementBlock(`div`,_hoisted_4$149,` "`+toDisplayString(props.insuranceData.slogan)+`" `,1))],2))}},insuranceIdentity_default=__plugin_vue_export_helper_default(_sfc_main$272,[[`__scopeId`,`data-v-689b89ea`]]),_hoisted_1$242={key:1,class:`coverage-option-name`},_hoisted_2$200={key:2,class:`choices`},_hoisted_3$175=[`onClick`],_hoisted_4$148={class:`choice-label`},_hoisted_5$129={key:0},_hoisted_6$110={key:0,class:`choice-secondary-text`},_hoisted_7$97={key:1,class:`choice-price`},_hoisted_8$81={key:3,class:`toggle-container`},_hoisted_9$72={class:`toggle-price`},_sfc_main$271={__name:`coverageOption`,props:{coverageOption:{type:Object,required:!0},changedCoverageOptions:{type:Object,required:!1,default:()=>({})},onlyShowMainText:{type:Boolean,default:!1},simpleSelect:{type:Boolean},modelValue:{type:Number,required:!1},showPerkMode:{type:String,default:`deportedLabel`},dontShowName:{type:Boolean,default:!1}},emits:[`choiceClick`,`toggleChange`,`update:modelValue`],setup(__props,{emit:__emit}){let props=__props,emit$1=__emit;watch(()=>props.coverageOption?.choices,newChoices=>{if(props.modelValue!==void 0&&props.modelValue!==null&&newChoices){let maxValidId=newChoices.length;props.modelValue>maxValidId&&emit$1(`update:modelValue`,1)}},{immediate:!0});let getSelectedValueId=()=>props.modelValue!==void 0&&props.modelValue!==null?Math.min(props.modelValue,props.coverageOption.choices.length):props.changedCoverageOptions[props.coverageOption.key],getToggleValue=coverageOption=>(props.changedCoverageOptions[coverageOption.key]??coverageOption.currentValueId)===coverageOption.choices.findIndex(choice=>choice.value===!0)+1,getTogglePrice=coverageOption=>{let selectedValueId=props.changedCoverageOptions[coverageOption.key]??coverageOption.currentValueId;return coverageOption.choices[selectedValueId-1]?.premiumInfluence||0},onToggleChange=(coverageOption,newValue)=>{emit$1(`toggleChange`,coverageOption,newValue)},onChoiceClick=(coverageOption,choice)=>{choice.disabled||(props.simpleSelect&&(coverageOption.currentValueId=choice.id),props.modelValue!==void 0&&props.modelValue!==null&&emit$1(`update:modelValue`,choice.id),emit$1(`choiceClick`,coverageOption,choice))};return(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,{class:normalizeClass([`coverage-options`,{"in-row":__props.coverageOption.choiceType===`toggle`}])},[__props.coverageOption.perkText&&__props.showPerkMode===`deportedLabel`?(openBlock(),createBlock(unref(insurancePerkNotice_default),{key:0,perkText:__props.coverageOption.perkText},null,8,[`perkText`])):createCommentVNode(``,!0),__props.dontShowName?createCommentVNode(``,!0):(openBlock(),createElementBlock(`div`,_hoisted_1$242,toDisplayString(__props.coverageOption.name),1)),__props.coverageOption.choiceType===`multiple`?(openBlock(),createElementBlock(`div`,_hoisted_2$200,[(openBlock(!0),createElementBlock(Fragment,null,renderList(__props.coverageOption.choices,choice=>(openBlock(),createElementBlock(`div`,{class:normalizeClass([`choice`,{selected:choice.id===__props.changedCoverageOptions[__props.coverageOption.key],current:choice.id===getSelectedValueId(),disabled:choice.disabled}]),key:choice,onClick:()=>onChoiceClick(__props.coverageOption,choice)},[createBaseVNode(`div`,_hoisted_4$148,toDisplayString(choice.choiceText),1),__props.onlyShowMainText?createCommentVNode(``,!0):(openBlock(),createElementBlock(`div`,_hoisted_5$129,[choice.secondaryText?(openBlock(),createElementBlock(`div`,_hoisted_6$110,toDisplayString(choice.secondaryText),1)):(openBlock(),createElementBlock(`div`,_hoisted_7$97,[createVNode(unref(bngUnit_default),{money:choice.premiumInfluence},null,8,[`money`])]))]))],10,_hoisted_3$175))),128))])):__props.coverageOption.choiceType===`toggle`?(openBlock(),createElementBlock(`div`,_hoisted_8$81,[createVNode(unref(bngSwitch_default),{class:`toggle-switch`,"model-value":getToggleValue(__props.coverageOption),onChange:_cache[0]||=newValue=>onToggleChange(__props.coverageOption,newValue)},null,8,[`model-value`]),createBaseVNode(`div`,_hoisted_9$72,[createVNode(unref(bngUnit_default),{money:getTogglePrice(__props.coverageOption)},null,8,[`money`])])])):createCommentVNode(``,!0)],2))}},coverageOption_default=__plugin_vue_export_helper_default(_sfc_main$271,[[`__scopeId`,`data-v-4921f4f0`]]),_hoisted_1$241={class:`popup-content`},_hoisted_2$199={class:`popup-header`},_hoisted_3$174={class:`top-info`},_hoisted_4$147={class:`top-info-title`},_hoisted_5$128={class:`top-info-policy-name`},_hoisted_6$109={class:`top-info-description`},_hoisted_7$96={class:`vehicle-list`},_hoisted_8$80={class:`closeButton`},_sfc_main$270={__name:`vehicleInsuranceList`,props:{insuranceData:{type:Object,required:!0},driverScoreData:{type:Object,required:!0}},emits:[`return`],setup(__props,{emit:__emit}){let props=__props,emit$1=__emit,closePopup=()=>{emit$1(`return`,!0)},openEditVehicleCoverage=vehicle=>{addPopup(editVehicleCoverage_default,{insuranceData:props.insuranceData,vehicleData:vehicle})},openEditPolicy=()=>{addPopup(editPolicy_default,{insuranceData:props.insuranceData,driverScoreData:props.driverScoreData}),closePopup()};return(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$241,[createBaseVNode(`div`,_hoisted_2$199,[createBaseVNode(`div`,_hoisted_3$174,[createBaseVNode(`div`,_hoisted_4$147,[_cache[0]||=createTextVNode(` Vehicles Insured By `,-1),createBaseVNode(`span`,_hoisted_5$128,toDisplayString(props.insuranceData.name),1)]),createBaseVNode(`div`,_hoisted_6$109,[_cache[1]||=createTextVNode(` Click any vehicle to adjust its deductible • Total Value: `,-1),createVNode(unref(bngUnit_default),{money:props.insuranceData.totalInsuranceVehsValue},null,8,[`money`])])]),createVNode(unref(bngButton_default),{class:`policy-coverage-button`,accent:`custom`,onClick:openEditPolicy},{default:withCtx(()=>[..._cache[2]||=[createTextVNode(` Policy Coverage `,-1)]]),_:1})]),createBaseVNode(`div`,_hoisted_7$96,[(openBlock(!0),createElementBlock(Fragment,null,renderList(props.insuranceData.carsInsured,(vehicle,index)=>(openBlock(),createBlock(unref(insuranceVehTile_default),{key:index,vehicle},{rightContent:withCtx(()=>[createVNode(unref(bngButton_default),{class:`edit-coverage-button bigger-button`,accent:`custom`,disabled:vehicle.needsRepair,onClick:$event=>!vehicle.needsRepair&&openEditVehicleCoverage(vehicle)},{default:withCtx(()=>[createTextVNode(toDisplayString(vehicle.needsRepair?`Edit Coverage (Needs repair)`:`Edit Coverage`),1)]),_:2},1032,[`disabled`,`onClick`])]),_:2},1032,[`vehicle`]))),128))]),createBaseVNode(`div`,_hoisted_8$80,[createVNode(unref(bngButton_default),{class:`close-button`,accent:`custom`,onClick:closePopup},{default:withCtx(()=>[..._cache[3]||=[createTextVNode(` Cancel `,-1)]]),_:1})])]))}},vehicleInsuranceList_default=__plugin_vue_export_helper_default(_sfc_main$270,[[`__scopeId`,`data-v-2bd92225`]]),_hoisted_1$240={class:`vehicle-item`},_hoisted_2$198={class:`left`},_hoisted_3$173={class:`vehicle-thumbnail-wrapper`},_hoisted_4$146=[`src`],_hoisted_5$127={class:`name-value-wrapper`},_hoisted_6$108={class:`vehicle-name`},_hoisted_7$95={class:`vehicle-value`},_hoisted_8$79={class:`right`},_sfc_main$269={__name:`insuranceVehTile`,props:{vehicle:{type:Object,required:!0}},setup(__props){return(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$240,[createBaseVNode(`div`,_hoisted_2$198,[createBaseVNode(`div`,_hoisted_3$173,[createBaseVNode(`img`,{src:__props.vehicle.thumbnail,alt:``,class:`vehicle-thumbnail`},null,8,_hoisted_4$146)]),createBaseVNode(`div`,_hoisted_5$127,[createBaseVNode(`div`,_hoisted_6$108,toDisplayString(__props.vehicle.name),1),createBaseVNode(`div`,_hoisted_7$95,[_cache[0]||=createTextVNode(`Value : `,-1),createVNode(unref(bngUnit_default),{money:__props.vehicle.initialValue},null,8,[`money`])]),renderSlot(_ctx.$slots,`extra-info`,{},void 0,!0)])]),createBaseVNode(`div`,_hoisted_8$79,[renderSlot(_ctx.$slots,`rightContent`,{},void 0,!0)])]))}},insuranceVehTile_default=__plugin_vue_export_helper_default(_sfc_main$269,[[`__scopeId`,`data-v-b4076016`]]),_hoisted_1$239={class:`popup-content`},_hoisted_2$197={key:0,class:`vehicle-list`},_hoisted_3$172={key:1,class:`no-vehicles-wrapper`},_hoisted_4$145={class:`closeButton`},_sfc_main$268={__name:`uninsuredVehicles`,props:{uninsuredData:{type:Object,required:!0}},emits:[`return`],setup(__props,{emit:__emit}){let props=__props,emit$1=__emit,closePopup=()=>{emit$1(`return`,!0)},openAddCoverage=vehicle=>{addPopup(ChooseInsuranceMain_default,{menuMode:`change`,params:{vehicleId:vehicle.id}})};return(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$239,[_cache[5]||=createBaseVNode(`div`,{class:`popup-header`},[createBaseVNode(`span`,{class:`header-title`},`Uninsured Vehicles`)],-1),_cache[6]||=createBaseVNode(`div`,{class:`warning-message`},` These vehicles have no insurance coverage. Add coverage to protect against repair costs. `,-1),props.uninsuredData.carsUninsured&&props.uninsuredData.carsUninsured.length>0?(openBlock(),createElementBlock(`div`,_hoisted_2$197,[(openBlock(!0),createElementBlock(Fragment,null,renderList(props.uninsuredData.carsUninsured,(vehicle,index)=>(openBlock(),createBlock(unref(insuranceVehTile_default),{key:index,vehicle,class:`uninsured-vehicle-item`},{"extra-info":withCtx(()=>[..._cache[0]||=[createBaseVNode(`div`,{class:`no-coverage-warning`},` No coverage - you pay full repair costs `,-1)]]),rightContent:withCtx(()=>[createVNode(unref(bngButton_default),{class:`add-coverage-button bigger-button`,accent:`custom`,onClick:$event=>openAddCoverage(vehicle)},{default:withCtx(()=>[createVNode(unref(bngIcon_default),{class:`button-icon`,type:unref(icons).shieldCheckmark},null,8,[`type`]),_cache[1]||=createTextVNode(` Add Coverage `,-1)]),_:1},8,[`onClick`])]),_:2},1032,[`vehicle`]))),128))])):(openBlock(),createElementBlock(`div`,_hoisted_3$172,[createVNode(unref(bngIcon_default),{class:`success-icon`,type:unref(icons).checkmark},null,8,[`type`]),_cache[2]||=createBaseVNode(`div`,{class:`success-title`},`All Vehicles Insured`,-1),_cache[3]||=createBaseVNode(`div`,{class:`success-message`},`You don't have any uninsured vehicles.`,-1)])),createBaseVNode(`div`,_hoisted_4$145,[createVNode(unref(bngButton_default),{class:`close-button`,accent:`custom`,onClick:closePopup},{default:withCtx(()=>[..._cache[4]||=[createTextVNode(` Back `,-1)]]),_:1})])]))}},uninsuredVehicles_default=__plugin_vue_export_helper_default(_sfc_main$268,[[`__scopeId`,`data-v-f51ead8e`]]),sharedMode=ref(null),sharedContext=ref(null);function useChooseInsurance(){let{events:events$3}=useBridge(),insurancesData=ref([]),purchaseData=ref({}),vehicleInfo=ref({}),defaultInsuranceId=ref(null),firstSelectedInsuranceId=ref(null),driverScoreData=ref({}),currentInsuranceId=ref(null),handleChooseInsuranceData=data=>{insurancesData.value=data.applicableInsurancesData,purchaseData.value=data.purchaseData,vehicleInfo.value=data.vehicleInfo,driverScoreData.value=data.driverScoreData,defaultInsuranceId.value=data.defaultInsuranceId,firstSelectedInsuranceId.value=data.defaultInsuranceId,currentInsuranceId.value=data.currentInsuranceId};function openChooseInsuranceMenu(menuMode,params){sharedMode.value=menuMode,sharedContext.value=params,Lua_default.career_modules_insurance_insurance.openChooseInsuranceScreen()}function requestDataForCurrentContext(){sharedMode.value===`purchase`&&sharedContext.value?Lua_default.career_modules_insurance_insurance.sendChooseInsuranceDataToTheUI(sharedContext.value.purchaseType,sharedContext.value.shopId,sharedContext.value.insuranceId):sharedMode.value===`change`&&sharedContext.value&&Lua_default.career_modules_insurance_insurance.sendChangeInsuranceDataToTheUI(sharedContext.value.vehicleId)}return events$3.on(`chooseInsuranceData`,handleChooseInsuranceData),onUnmounted(()=>{events$3.off(`chooseInsuranceData`,handleChooseInsuranceData)}),{openChooseInsuranceMenu,requestDataForCurrentContext,insurancesData,purchaseData,vehicleInfo,defaultInsuranceId,firstSelectedInsuranceId,driverScoreData,currentInsuranceId,mode:sharedMode,context:sharedContext}}var _hoisted_1$238={class:`popup-content`},_hoisted_2$196={class:`popup-header`},_hoisted_3$171={class:`content-wrapper`},_hoisted_4$144={class:`buttons-wrapper`},_hoisted_5$126={class:`button-container`},_sfc_main$267={__name:`ChooseInsuranceMain`,props:{menuMode:{type:String,required:!0},params:{type:Object,required:!0}},emits:[`return`],setup(__props,{emit:__emit}){useUINavBlocker().ensureNoBlock([`tab_l`,`tab_r`]);let overflowRef=ref(null),onTabNav=evt=>{evt.detail.value===1&&(console.log(`onTabNav`,evt.detail),console.log(`overflowRef`,overflowRef.value),evt.detail.name===`tab_l`&&overflowRef.value?.activatePrev(),evt.detail.name===`tab_r`&&overflowRef.value?.activateNext())},props=__props,emit$1=__emit,{units}=useBridge(),selectedInsuranceId=ref(null),selectedShelfIndex=ref(0),{insurancesData,purchaseData,defaultInsuranceId,firstSelectedInsuranceId,vehicleInfo,requestDataForCurrentContext,mode,context,driverScoreData,currentInsuranceId}=useChooseInsurance();onMounted(()=>{window.addEventListener(DOM_UI_NAVIGATION_EVENT,onTabNav),mode.value=props.menuMode,context.value=props.params,props.menuMode===`purchase`&&props.params?Lua_default.career_modules_insurance_insurance.sendChooseInsuranceDataToTheUI(props.params.purchaseType,props.params.shopId,props.params.insuranceId):props.menuMode===`change`&&props.params&&Lua_default.career_modules_insurance_insurance.sendChangeInsuranceDataToTheUI(props.params.vehicleId)}),watch(selectedShelfIndex,newIndex=>{insurancesData.value[newIndex]&&(selectedInsuranceId.value=insurancesData.value[newIndex].id)}),watch(defaultInsuranceId,defaultId=>{if(defaultId!==null){selectedInsuranceId.value=defaultId;let index=insurancesData.value.findIndex(ins=>ins.id===defaultId);index!==-1&&(selectedShelfIndex.value=index)}},{immediate:!0});let onShelfClick=(insuranceId,index)=>{selectedInsuranceId.value=insuranceId,selectedShelfIndex.value=index},buttonText=computed(()=>mode.value===`change`?selectedInsuranceId.value===-1?`Remove Coverage`:selectedInsuranceId.value===currentInsuranceId.value?`Current Provider`:`Move vehicle here`:`Select this option`),viewCostBreakdown=()=>{mode.value===`purchase`?addPopup(purchaseInsuranceDetails_default,{insuranceData:insurancesData.value[selectedShelfIndex.value],vehicleInfo:vehicleInfo.value,driverScoreData:driverScoreData.value}):addPopup(changeInsuranceDetails_default,{insuranceData:insurancesData.value[selectedShelfIndex.value],vehicleInfo:vehicleInfo.value,driverScoreData:driverScoreData.value})},continueWithInsurance=()=>{mode.value===`purchase`?(selectedInsuranceId.value!==null&&selectedInsuranceId.value!==void 0&&Lua_default.career_modules_vehicleShopping.updateInsuranceSelection(selectedInsuranceId.value),emit$1(`return`,!0)):mode.value===`change`&&(selectedInsuranceId.value&&context.value?.vehicleId&&Lua_default.career_modules_insurance_insurance.changeInvVehInsurance(context.value.vehicleId,selectedInsuranceId.value),closeLastPopups(3))},cancel=()=>{emit$1(`return`,!0)};return onUnmounted(()=>{window.removeEventListener(DOM_UI_NAVIGATION_EVENT,onTabNav),mode.value=null,context.value=null}),(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$238,[createBaseVNode(`div`,_hoisted_2$196,[createVNode(unref(bngCardHeading_default),{type:`ribbon`},{default:withCtx(()=>[createTextVNode(toDisplayString(unref(mode)===`purchase`?`Insure your `:`Switch insurance for your `)+` `+toDisplayString(unref(vehicleInfo).Name),1)]),_:1})]),createBaseVNode(`div`,_hoisted_3$171,[createVNode(unref(bngOverflowContainer_default),{ref_key:`overflowRef`,ref:overflowRef,class:`insurance-shelf`,"scroll-speed":10,"initial-index":selectedShelfIndex.value,"use-bindings-only":``,"show-arrows":``,"no-wheel":``},{default:withCtx(()=>[(openBlock(!0),createElementBlock(Fragment,null,renderList(unref(insurancesData),(insurance,index)=>(openBlock(),createBlock(unref(insuranceCard_default),{key:insurance.id,insuranceData:insurance,isSelected:selectedInsuranceId.value===insurance.id,vehicleInfo:unref(vehicleInfo),isCurrentProvider:unref(mode)===`change`&&unref(currentInsuranceId)===insurance.id,class:`insurance-card`,onClick:$event=>onShelfClick(insurance.id,index)},null,8,[`insuranceData`,`isSelected`,`vehicleInfo`,`isCurrentProvider`,`onClick`]))),128))]),_:1},8,[`initial-index`])]),createBaseVNode(`div`,_hoisted_4$144,[createBaseVNode(`div`,_hoisted_5$126,[createVNode(unref(bngButton_default),{onClick:cancel,accent:unref(ACCENTS).attention},{default:withCtx(()=>[..._cache[0]||=[createTextVNode(`Cancel`,-1)]]),_:1},8,[`accent`]),createVNode(unref(bngButton_default),{onClick:viewCostBreakdown,disabled:selectedShelfIndex.value===0||unref(mode)===`change`&&selectedInsuranceId.value===unref(currentInsuranceId),accent:unref(ACCENTS).secondary},{default:withCtx(()=>[..._cache[1]||=[createTextVNode(`View Cost Breakdown`,-1)]]),_:1},8,[`disabled`,`accent`]),createVNode(unref(bngButton_default),{disabled:!selectedInsuranceId.value||unref(mode)===`change`&&selectedInsuranceId.value===unref(currentInsuranceId),onClick:continueWithInsurance},{default:withCtx(()=>[createTextVNode(toDisplayString(buttonText.value),1)]),_:1},8,[`disabled`])])])]))}},ChooseInsuranceMain_default=__plugin_vue_export_helper_default(_sfc_main$267,[[`__scopeId`,`data-v-7bb3e442`]]),_hoisted_1$237={class:`progress-view-actions`},_hoisted_2$195={class:`progress-view-page`},_hoisted_3$170={class:`progress-view-header`},_hoisted_4$143={class:`branch-icon-assembly large`},_hoisted_5$125={key:0,class:`reward-multiplier`},_hoisted_6$107={class:`reward-multiplier-label`},_hoisted_7$94={class:`reward-multiplier-value`},_hoisted_8$78={class:`progress-view-contents`},_hoisted_9$71={class:`progress-view-description`},_hoisted_10$62={class:`progress-view-scrollable`},_sfc_main$266={__name:`ProgressView`,props:{skillInfo:{type:Object,default:null},headingText:{type:String,default:``},breadcrumbItems:{type:Array,required:!0},branchStyle:{type:Object,required:!0},showBackButton:{type:Boolean,default:!0}},emits:[`breadcrumb-click`,`breadcrumb-back`,`exit`,`skill-click`],setup(__props,{emit:__emit}){let emit$1=__emit,handleBreadcrumbClick=item=>{emit$1(`breadcrumb-click`,item)},handleBreadcrumbBack=()=>{emit$1(`breadcrumb-back`)},handleExit=()=>{emit$1(`exit`)};return(_ctx,_cache)=>withDirectives((openBlock(),createBlock(unref(layoutSingle_default),{class:`progress-view-layout`},{default:withCtx(()=>[withDirectives((openBlock(),createElementBlock(`div`,{class:`progress-view-wrapper`,style:normalizeStyle(__props.branchStyle),"bng-ui-scope":`progressView`},[createBaseVNode(`div`,_hoisted_1$237,[createVNode(unref(bngBreadcrumbs_default),{class:`progress-view-breadcrumbs`,items:__props.breadcrumbItems,limit:`5`,simple:``,"disable-last-item":``,"show-back-button":__props.showBackButton,onClick:handleBreadcrumbClick,onBack:handleBreadcrumbBack},null,8,[`items`,`show-back-button`]),createVNode(unref(careerStatus_default),{class:`progress-view-career-status`,slim:``})]),createBaseVNode(`div`,_hoisted_2$195,[createBaseVNode(`div`,_hoisted_3$170,[__props.skillInfo?(openBlock(),createElementBlock(Fragment,{key:0},[createBaseVNode(`div`,{class:normalizeClass([`header-skill`,{"is-locked":!__props.skillInfo.unlocked}]),onClick:_cache[0]||=$event=>_ctx.$emit(`skill-click`,__props.skillInfo.id)},[createBaseVNode(`div`,_hoisted_4$143,[createBaseVNode(`div`,{class:`branch-background`,style:normalizeStyle(unref(getIconBackgroundStyle)(__props.skillInfo.color))},null,4),createVNode(unref(bngIcon_default),{type:unref(icons)[__props.skillInfo.unlocked?__props.skillInfo.icon:`lockClosed`],class:`assembly-icon large`},null,8,[`type`])]),createVNode(BranchSkillProgressBar_default,{class:`main-stat-progress-bar skill-progress-bar`,skill:__props.skillInfo,showLevel:!1,mode:`with-value-label`,showLockedIcon:!0,isMainProgress:!0},null,8,[`skill`])],2),__props.skillInfo.rewardMultiplier?(openBlock(),createElementBlock(`div`,_hoisted_5$125,[createBaseVNode(`div`,_hoisted_6$107,[createVNode(unref(bngIcon_default),{type:__props.skillInfo.rewardMultiplierSourceIcon},null,8,[`type`]),_cache[1]||=createTextVNode(` Reward Multiplier: `,-1)]),createBaseVNode(`div`,_hoisted_7$94,[createVNode(unref(bngIcon_default),{type:unref(icons).beamCurrency},null,8,[`type`]),createTextVNode(` ×`+toDisplayString(__props.skillInfo.rewardMultiplier.toFixed(2)),1)])])):createCommentVNode(``,!0)],64)):(openBlock(),createBlock(unref(bngScreenHeadingV2_default),{key:1,type:`2`,class:`header-title-v2`},{default:withCtx(()=>[createTextVNode(toDisplayString(__props.headingText),1)]),_:1}))]),createBaseVNode(`div`,_hoisted_8$78,[createBaseVNode(`div`,_hoisted_9$71,[renderSlot(_ctx.$slots,`description`,{},void 0,!0)]),_cache[2]||=createBaseVNode(`div`,{class:`progress-view-divider`},null,-1),createBaseVNode(`div`,_hoisted_10$62,[renderSlot(_ctx.$slots,`default`,{},void 0,!0)])])])],4)),[[unref(BngOnUiNav_default),handleExit,`back,menu`]])]),_:3})),[[unref(BngOnUiNav_default),handleExit,`back,menu`],[unref(BngBlur_default)]])}},ProgressView_default=__plugin_vue_export_helper_default(_sfc_main$266,[[`__scopeId`,`data-v-3fa921dc`]]),_hoisted_1$236={class:`description-text`},_hoisted_2$194={key:0,class:`cards-container grid-view`},_hoisted_3$169={key:1,class:`page-progress`},_hoisted_4$142={key:2,class:`facility-rows`},_hoisted_5$124={key:3,class:`buttons-container`},_hoisted_6$106={class:`content`},_hoisted_7$93={key:0,class:`indicator`},_sfc_main$265={__name:`ProgressLanding`,props:{pathId:String,comesFromBigMap:{type:Boolean,default:!1}},setup(__props){let props=__props,landingData=ref({heading:`ui.career.landingPage.name`,description:`ui.career.landingPage.description`,branches:[],showMilestones:!0,showOrganizations:!0}),leagues=ref([]),fetchLandingData=async()=>{landingData.value={heading:`ui.career.landingPage.name`,description:`ui.career.landingPage.description`,branches:[],showMilestones:!0,showOrganizations:!0};let data=await Lua_default.career_modules_branches_landing.getLandingPageData(props.pathId);landingData.value=data,leagues.value=data.leagues||[],console.log(`data`,data),data.breadcrumbs&&(screenHeaderPath.value=data.breadcrumbs,console.log(`screenHeaderPath`,screenHeaderPath.value))},hasUnclaimedMilestones=ref(!1);onMounted(async()=>{await fetchLandingData(),Lua_default.career_modules_milestones_milestones.unclaimedMilestonesCount().then(c=>hasUnclaimedMilestones.value=c)}),onBeforeMount(()=>{Lua_default.simTimeAuthority.pushPauseRequest(`progressLanding`)}),onUnmounted(()=>{Lua_default.simTimeAuthority.popPauseRequest(`progressLanding`)}),watch(()=>props.pathId,async(newPathId,oldPathId)=>{newPathId!==oldPathId&&(await fetchLandingData(),Lua_default.career_modules_milestones_milestones.unclaimedMilestonesCount().then(c=>hasUnclaimedMilestones.value=c))});let leagueMissionClicked=mission=>{mission.canStartFromProgressScreen?(Lua_default.extensions.gameplay_missions_missionScreen.setPreselectedMissionId(mission.id),Lua_default.extensions.gameplay_missions_missionScreen.openAPMChallenges(props.pathId,mission.skill[0])):Lua_default.extensions.gameplay_missions_missionScreen.navigateToMission(mission.id)},branchStyle=computed(()=>landingData.value.skillInfo?getBranchColorStyle({color:landingData.value.skillInfo.color,accentColor:landingData.value.skillInfo.accentColor}):{"--branch-accent-color":`var(--bng-cool-gray-500-rgb)`,"--branch-color":`var(--bng-cool-gray-500-rgb)`}),pageHeading=computed(()=>landingData.value.branchHeading||landingData.value.heading),currentDescription=ref(null),pageDescription=computed(()=>currentDescription.value||landingData.value.description),BRANCHES=computed(()=>landingData.value.branches),openBranchPage=branchKey=>{let target=landingData.value.branches.find(b=>b.id===branchKey).target;console.log(`openBranchPage`,branchKey),window.bngVue.gotoGameState(`progressLanding`,{params:{pathId:branchKey}})},exit=()=>{props.pathId&&!props.comesFromBigMap?router_default.back():window.bngVue.gotoAngularState(`menu.careerPause`)},openMilestonesScreen=()=>window.bngVue.gotoGameState(`milestones`),onBranchFocus=branch=>{currentDescription.value=branch.description},onBranchBlur=()=>{currentDescription.value=null},isHalfBranch=branch=>{let hasSkills=branch.skills&&branch.skills.length>0,hasDescription=branch.shortDescription;return!hasSkills&&!hasDescription},currentSkillToShow=computed(()=>landingData.value.skillInfo||null),screenHeaderPath=ref([{label:`Career`,path:`/career`},{label:landingData.value.heading,path:`/career/${landingData.value.id}`}]),gotoHeaderItem=item=>{item.gotoPath&&(window.bngVue.gotoGameState(item.gotoPath.path,{params:item.gotoPath.props}),console.log(`gotoPath`,item.gotoPath)),item.gotoAngularState&&window.bngVue.gotoAngularState(item.gotoAngularState)},onBreadBack=()=>{gotoHeaderItem(screenHeaderPath.value[screenHeaderPath.value.length-2])};return(_ctx,_cache)=>(openBlock(),createBlock(ProgressView_default,{"skill-info":landingData.value.skillInfo,"heading-text":_ctx.$t(pageHeading.value),"breadcrumb-items":screenHeaderPath.value,"branch-style":branchStyle.value,"show-back-button":!0,onBreadcrumbClick:gotoHeaderItem,onBreadcrumbBack:onBreadBack,onExit:exit},{description:withCtx(()=>[createBaseVNode(`div`,_hoisted_1$236,toDisplayString(_ctx.$t(pageDescription.value)),1)]),default:withCtx(()=>[BRANCHES.value.length>0?(openBlock(),createElementBlock(`div`,_hoisted_2$194,[(openBlock(!0),createElementBlock(Fragment,null,renderList(BRANCHES.value,branch=>withDirectives((openBlock(),createBlock(BranchSkillCard_default,{tabindex:`1`,branchKey:branch.id,onOpenBranchPage:openBranchPage,onMouseenter:$event=>onBranchFocus(branch),onMouseleave:onBranchBlur,onFocus:$event=>onBranchFocus(branch),onBlur:onBranchBlur,"bng-nav-item":``,"display-mode":`row`,class:normalizeClass({"full-width":!isHalfBranch(branch)})},null,8,[`branchKey`,`onMouseenter`,`onFocus`,`class`])),[[unref(BngSoundClass_default),`bng_click_hover_generic`]])),256))])):createCommentVNode(``,!0),currentSkillToShow.value&¤tSkillToShow.value.hasLevels&¤tSkillToShow.value.unlockInfo&¤tSkillToShow.value.unlockInfo.length?(openBlock(),createElementBlock(`div`,_hoisted_3$169,[currentSkillToShow.value.hasUnlocks?(openBlock(),createBlock(UnlockRows_default,{key:0,class:`stat-progress-bar bng-progress-bar progress-bar`,headerLeft:_ctx.$ctx_t(currentSkillToShow.value.name),headerRight:_ctx.$ctx_t(currentSkillToShow.value.levelLabel),value:currentSkillToShow.value.value,max:currentSkillToShow.value.max,min:currentSkillToShow.value.min,maxRequiredValue:currentSkillToShow.value.maxRequiredValue,tiers:currentSkillToShow.value.unlockInfo,currentTier:currentSkillToShow.value.unlocked?currentSkillToShow.value.level:-1,unlocked:currentSkillToShow.value.unlocked,progressFillColor:currentSkillToShow.value.accentColor},null,8,[`headerLeft`,`headerRight`,`value`,`max`,`min`,`maxRequiredValue`,`tiers`,`currentTier`,`unlocked`,`progressFillColor`])):createCommentVNode(``,!0)])):createCommentVNode(``,!0),leagues.value&&leagues.value.length>0?(openBlock(),createElementBlock(`div`,_hoisted_4$142,[(openBlock(!0),createElementBlock(Fragment,null,renderList(leagues.value,league=>(openBlock(),createBlock(LeagueRow_default,{key:league.id,league,leagueMissionClicked},null,8,[`league`]))),128))])):createCommentVNode(``,!0),landingData.value.showMilestones?(openBlock(),createElementBlock(`div`,_hoisted_5$124,[withDirectives((openBlock(),createBlock(unref(bngCard_default),{"bng-nav-item":``,class:`button milestone-button`,onClick:openMilestonesScreen},{default:withCtx(()=>[createBaseVNode(`div`,_hoisted_6$106,[createVNode(unref(bngIcon_default),{class:`icon`,type:unref(icons).checkboxOn},null,8,[`type`]),_cache[0]||=createBaseVNode(`div`,{class:`label`},` Milestones `,-1),hasUnclaimedMilestones.value>0?(openBlock(),createElementBlock(`div`,_hoisted_7$93)):createCommentVNode(``,!0)])]),_:1})),[[unref(BngSoundClass_default),`bng_click_hover_generic`]])])):createCommentVNode(``,!0)]),_:1},8,[`skill-info`,`heading-text`,`breadcrumb-items`,`branch-style`]))}},ProgressLanding_default=__plugin_vue_export_helper_default(_sfc_main$265,[[`__scopeId`,`data-v-cbe0bb9d`]]),_hoisted_1$235={class:`reward-wrapper`},_hoisted_2$193={class:`card-content`},_hoisted_3$168={class:`rewards-breakdown-container padding-bottom`},_hoisted_4$141={class:`grid-wrapper`},_hoisted_5$123={class:`grid-row grid`},_hoisted_6$105={class:`label primary`},_hoisted_7$92={class:`rewards primary`},_hoisted_8$77={class:`grid-wrapper wide`},_hoisted_9$70={class:`grid`},_hoisted_10$61={class:`label secondary`},_hoisted_11$55={class:`rewards secondary`},_hoisted_12$44={class:`grid-row grid`},_hoisted_13$37={class:`rewards primary`},_hoisted_14$35={class:`padding-bottom`},_hoisted_15$33={key:0,class:`unlocks-wrapper`},__default__$4={wrapper:{fade:!0,blur:!0,style:popupContainer.transparent},position:[popupPosition.center,popupPosition.center]},_sfc_main$264=Object.assign(__default__$4,{__name:`CargoDeliveryReward`,emits:[`return`],setup(__props,{emit:__emit}){useCssVars(_ctx=>({v4c61e8a8:ANIM_DURATION_CSS})),useUINavScope(`deliveryReward`);let ANIMATION_START_DELAY=1e3,ANIMATION_DURATION=2e3,ANIM_DURATION_CSS=ANIMATION_DURATION+`ms`,showBarAnimations=ref(!1),data=storeToRefs(useGameContextStore()).deliveryRewardData,exit=()=>{window.bngVue.gotoGameState(`play`)};function stopAnimations(){showBarAnimations.value=!1}function startProgressBarAnimation(){if(data.value){showBarAnimations.value=!0;for(let[key,value]of Object.entries(data.value.summary.rewards))value.branchInfo&&(value.branchInfo.animValue=value.branchInfo.value);setTimeout(stopAnimations,ANIMATION_DURATION)}}return onBeforeMount(()=>{Lua_default.simTimeAuthority.pushPauseRequest(`cargoDeliveryReward`)}),onMounted(()=>{getUINavServiceInstance().activate(),getUINavServiceInstance().clearFilteredEvents(),showBarAnimations.value=!1,setTimeout(startProgressBarAnimation,1e3)}),onUnmounted(()=>{Lua_default.career_modules_delivery_cargoScreen.unloadCargoPopupClosed(),Lua_default.simTimeAuthority.popPauseRequest(`cargoDeliveryReward`)}),(_ctx,_cache)=>unref(data)?withDirectives((openBlock(),createBlock(unref(layoutSingle_default),{key:0,class:`layout-content-full flex-column layout-paddings layout-align-center`,"bng-ui-scope":`deliveryReward`},{default:withCtx(()=>[createBaseVNode(`div`,_hoisted_1$235,[createVNode(unref(bngCard_default),null,{buttons:withCtx(()=>[createVNode(unref(bngButton_default),{onClick:exit},{default:withCtx(()=>[createVNode(unref(bngBinding_default),{"ui-event":`ok`,deviceMask:`xinput`}),_cache[5]||=createBaseVNode(`span`,null,`Continue`,-1)]),_:1})]),default:withCtx(()=>[createVNode(unref(careerStatus_default),{class:`career-status`}),createVNode(unref(bngCardHeading_default),{type:`ribbon`},{default:withCtx(()=>[..._cache[0]||=[createTextVNode(` Delivery Complete! `,-1)]]),_:1}),createBaseVNode(`div`,_hoisted_2$193,[createBaseVNode(`div`,_hoisted_3$168,[_cache[3]||=createBaseVNode(`span`,{class:`span2-heading`},` Reward Breakdown `,-1),createBaseVNode(`div`,_hoisted_4$141,[_cache[2]||=createBaseVNode(`div`,{class:`grid-row grid`},[createBaseVNode(`div`,{class:`label primary`},`Item`),createBaseVNode(`div`,{class:`rewards primary`},`Rewards`)],-1),(openBlock(!0),createElementBlock(Fragment,null,renderList(unref(data).sortedResults,result=>(openBlock(),createElementBlock(`div`,_hoisted_5$123,[createBaseVNode(`div`,_hoisted_6$105,toDisplayString(result.label),1),createBaseVNode(`div`,_hoisted_7$92,[createVNode(RewardsPills_default,{rewards:result.rewards},null,8,[`rewards`])]),createBaseVNode(`div`,_hoisted_8$77,[(openBlock(!0),createElementBlock(Fragment,null,renderList(result.breakdown,breakdown=>(openBlock(),createElementBlock(`div`,_hoisted_9$70,[createBaseVNode(`div`,_hoisted_10$61,toDisplayString(breakdown.label),1),createBaseVNode(`div`,_hoisted_11$55,[createVNode(RewardsPills_default,{rewards:breakdown.rewards},null,8,[`rewards`])])]))),256))])]))),256)),createVNode(unref(bngDivider_default)),createBaseVNode(`div`,_hoisted_12$44,[_cache[1]||=createBaseVNode(`div`,{class:`label primary`},`Summary`,-1),createBaseVNode(`div`,_hoisted_13$37,[createVNode(RewardsPills_default,{rewards:unref(data).summary.rewards},null,8,[`rewards`])])])])]),createBaseVNode(`div`,_hoisted_14$35,[(openBlock(!0),createElementBlock(Fragment,null,renderList(unref(data).summary.rewards,reward=>(openBlock(),createElementBlock(`div`,null,[reward.branchInfo?(openBlock(),createBlock(unref(bngProgressBar_default),{key:0,class:normalizeClass({"stat-progress-bar":!0,"animate-progress":showBarAnimations.value}),headerLeft:_ctx.$ctx_t(reward.branchInfo.name),headerRight:_ctx.$ctx_t(reward.branchInfo.level),min:reward.branchInfo.max==-1?0:reward.branchInfo.min,value:reward.branchInfo.max==-1?1:reward.branchInfo.animValue,max:reward.branchInfo.max==-1?1:reward.branchInfo.max,"value-label-format":reward.branchInfo.max==-1?`Max Level Reached`:void 0},null,8,[`class`,`headerLeft`,`headerRight`,`min`,`value`,`max`,`value-label-format`])):createCommentVNode(``,!0)]))),256))]),unref(data).summary.unlocks.length?(openBlock(),createElementBlock(`div`,_hoisted_15$33,[_cache[4]||=createBaseVNode(`span`,{class:`span2-heading`},` Unlocks`,-1),(openBlock(!0),createElementBlock(Fragment,null,renderList(unref(data).summary.unlocks,unlock=>(openBlock(),createBlock(UnlockCard_default,{class:`unlock-item`,data:unlock},null,8,[`data`]))),256))])):createCommentVNode(``,!0)])]),_:1})])]),_:1})),[[unref(BngBlur_default)],[unref(BngOnUiNav_default),exit,`back,menu,ok`]]):createCommentVNode(``,!0)}}),CargoDeliveryReward_default=__plugin_vue_export_helper_default(_sfc_main$264,[[`__scopeId`,`data-v-e964374f`]]),_hoisted_1$234={key:0,class:`context`},_hoisted_2$192={key:0,class:`card-label`},_hoisted_3$167={key:1,class:`card-label`},_hoisted_4$140={class:`simple-props-wrapper`},_hoisted_5$122={key:1,class:`to-load`},_hoisted_6$104={class:`chevron-arrow`},_hoisted_7$91={class:`chevron-outer`,width:`100%`,height:`100%`,xmlns:`http://www.w3.org/2000/svg`},_hoisted_8$76={class:`chevron-inner`,viewBox:`4 2 12 60`,preserveAspectRatio:`xMaxYMid slice`},_hoisted_9$69={key:0,d:`M-11 -2H1L14 32L1 66H-11V-2Z`,fill:`rgb(var(--chevron-color))`,"fill-opacity":`var(--chevron-alpha)`,stroke:`rgb(var(--chevron-color))`,"stroke-width":`3`,"vector-effect":`non-scaling-stroke`},_hoisted_10$60={key:1,d:`M-11 -2H1L14 32L1 66H-11V-2Z`,fill:`rgb(var(--chevron-color))`,"fill-opacity":`var(--chevron-alpha)`,stroke:`var(--bng-orange-500)`,"stroke-width":`3`,"vector-effect":`non-scaling-stroke`},_hoisted_11$54={key:2},_hoisted_12$43={key:0,class:`modifiers`},_hoisted_13$36={key:1,class:`timer-value`},_hoisted_14$34={key:0,class:`orange`},_sfc_main$263={__name:`CargoCard`,props:{card:{type:Object,required:!1},hideProps:Boolean,hideModsAndTimer:Boolean,focus:String,detailed:Boolean,showButtons:{type:Boolean,default:!0},alwaysShowLoadingWrapper:Boolean,ribbon:{type:Boolean,default:!0}},emits:[`cargoHovered`,`onAmountSelectorChanged`],setup(__props,{emit:__emit}){let emit$1=__emit;function onAmountSelectorChanged(value){emit$1(`onAmountSelectorChanged`,value)}let props=__props,cargoOverviewStore=useCargoOverviewStore(),{units}=useBridge(),getCargoCardClass=card=>({cardRow:!0,"bg-available":card.isFacilityCard&&card.enabled,"bg-available-selected":card.isFacilityCard&&card.enabled&&cargoOverviewStore.selectedCargo===card,"bg-assigned":card.transientMove,"bg-assigned-selected":card.transientMove&&cargoOverviewStore.selectedCargo===card,"bg-locked":card.isFacilityCard&&!card.enabled,"bg-locked-selected":card.isFacilityCard&&!card.enabled&&cargoOverviewStore.selectedCargo===card,"bg-loaded":card.isPlayerCard&&!card.transientMove,"bg-loaded-selected":card.isPlayerCard&&!card.transientMove&&cargoOverviewStore.selectedCargo===card,"highlight-poi-selected":!!(!props.detailed&&cargoOverviewStore.highlightedCards[card.cardId]),"card-disabled":!card.enabled,"with-thumbnail":card.thumbnail}),rewardMoney=computed(()=>props.card.rewardMoney||props.card.rewardMoneyPerLiter||(props.card.loanerCut?-(props.card.loanerCut.value*100-props.card.loanerCut.value*100%1)+`%`:void 0)),hasIds=computed(()=>props.card.rewardMoney&&props.card.ids&&props.card.ids.length>0&&!props.card.materialType),isPerLiter=computed(()=>props.card.rewardMoneyPerLiter),isLoadingFacilityCard=computed(()=>props.card.transientMoveCounts>0||props.card.spawnWhenCommitingCargo||props.card._transientMaterialMoveAmount>0),context=computed(()=>props.card.enabled?props.card.isFacilityCard?`Available`:props.card.transientMoveCounts>0||props.card.spawnWhenCommitingCargo||props.card._transientMaterialMoveAmount?`Assigned`:`Loaded`:`Locked`),isMoving=computed(()=>cargoOverviewStore.cargoData.player.isMoving),chevronProp=computed(()=>{let card=props.card;if(!card.isPlayerCard){if(card.cardType===`parcelGroup`)return card.materialType?card.transientMoveCounts>0||props.alwaysShowLoadingWrapper?{class:card.transientMoveCounts==0?`amount-load no-load`:`amount-load`,valueLabel:card.slots+`L`}:void 0:card.transientMoveCounts>0||props.alwaysShowLoadingWrapper?{class:card.transientMoveCounts==0?`amount-load no-load`:`amount-load`,valueLabel:card.transientMoveCounts+` / `+card.ids.length}:void 0;if(card.cardType===`vehicleOffer`)return card.spawnWhenCommitingCargo?{class:`amount-load`,valueLabel:`Accepted`,iconType:icons.fastTravel}:void 0;if(card.cardType===`storage`)return card._transientMaterialMoveAmount>0||props.alwaysShowLoadingWrapper?{class:card._transientMaterialMoveAmount==0?`amount-load no-load`:`amount-load`,valueLabel:card._transientMaterialMoveAmount+`L / `+card.storage.storedVolume+`L`}:void 0}}),propIcons=computed(()=>{let res=[],card=props.card;if(props.detailed)return res;if(card.enabled&&card.modifiers&&card.modifiers.length)for(let mod of card.modifiers)mod.important&&res.push({type:icons[mod.icon],color:`var(--bng-orange-300)`});return card.disableReason&&card.disableReason.type===`locked`&&res.push({type:icons.lockClosed,color:`var(--bng-add-red-300)`}),res}),cargoProps=computed(()=>{let res=[],card=props.card,detailed=props.detailed,focus$1=props.focus,$tt=$translate.instant,$ctx_t=$translate.contextTranslate,hideProps=props.hideProps;if(card.isFacilityCard&&!card.enabled&&(!card.transientMoveCounts||card.transientMoveCounts<=0)&&(card.disableReason?(card.disableReason.type===`noSpace`&&res.push({iconType:icons.info,keyLabel:detailed?`No Space`:``,valueLabel:detailed?card.disableReason.label?card.disableReason.label:`Not enough space to load this.`:`No Space`,class:`full-width red`,iconColor:`var(--bng-add-red-300)`}),card.disableReason.type===`expired`&&res.push({iconType:icons.info,keyLabel:detailed?`Expired`:``,valueLabel:detailed?card.disableReason.label?card.disableReason.label:`This offer is already expired.`:`Expired`,class:`full-width `}),card.disableReason.type===`limit`&&res.push({iconType:icons.info,keyLabel:detailed?`Limit reached`:``,valueLabel:detailed?card.disableReason.label?card.disableReason.label:`You cannot deliver more cars at the same time.`:`Limit reached`,class:`full-width red`,iconColor:`var(--bng-add-red-300)`})):res.push({iconType:icons.lockClosed,keyLabel:detailed?`Locked..?`:``,valueLabel:detailed?`Not enabled but no disablereason given!`:`Locked..?`,class:`full-width`,iconColor:`var(--bng-add-red-300)`})),card.unlockInfo){let locked=card.disableReason&&card.disableReason.type==`locked`;(detailed||locked)&&res.push({iconType:icons[card.unlockInfo.icon],valueLabel:detailed?$ctx_t(card.unlockInfo.longLabel):``,keyLabel:detailed?locked?`Locked`:``:$ctx_t(card.unlockInfo.shortLabel),class:`full-width `+(locked?`red`:``),iconColor:locked?`var(--bng-add-red-300)`:``})}if(hideProps)return res;if(card.nextTasks&&card.nextTasks.length>0&&(!focus$1||focus$1===`nextTasks`||detailed))for(let task of card.nextTasks)res.push({iconType:icons[task.checked?`checkboxOn`:`checkboxOff`],keyLabel:detailed?`Next Task`:``,valueLabel:task.label,class:`full-width`});if(card.locationName&&(!focus$1||focus$1===`location`||detailed)&&res.push({iconType:icons.locationSource,keyLabel:detailed?`Location`:``,valueLabel:detailed?card.locationNameLong:card.locationName,class:`full-width`}),card.destinationName&&(!focus$1||focus$1===`destination`||detailed)&&res.push({iconType:icons.locationDestination,keyLabel:detailed?`Destination`:``,valueLabel:detailed?card.destinationNameLong:card.destinationName,class:`full-width`}),card.locations&&(!focus$1||focus$1===`destination`)&&!detailed&&res.push({iconType:icons.mapPoint,valueLabel:card.locations.length+` possible Destinations`,class:`full-width`}),card.locations&&detailed)if(card.locations.length==1)res.push({iconType:icons.locationDestination,keyLabel:`Destination`,valueLabel:card.locations[0].name,class:`full-width`});else{res.push({iconType:icons.location2,keyLabel:`Multiple Destinations`,valueLabel:`Deliver this cargo to any of the possible destinations.`,class:`full-width`});let destinationsList=[];for(let location$1 of card.locations)destinationsList.push($tt(location$1.name));destinationsList=destinationsList.map(str=>str.replace(/ /g,` `)),res.push({iconType:icons.mapPoint,keyLabel:`Possible Destinations`,valueLabel:destinationsList.join(`, `),class:`full-width`})}if(card.distance&&(!focus$1||focus$1===`distance`||detailed)&&res.push({iconType:icons.routeSimple,keyLabel:detailed?`Distance`:``,valueLabel:units.buildString(`distance`,card.distance,1),class:``}),card.vehMileage&&(!focus$1||focus$1===`vehMileage`||detailed)&&res.push({iconType:icons.odometer,keyLabel:detailed?`Mileage`:``,valueLabel:units.buildString(`distance`,card.vehMileage,1),class:``}),card.weight&&(!focus$1||focus$1===`weight`||detailed)&&res.push({iconType:icons.weight,keyLabel:detailed?`Weight`:``,valueLabel:units.buildString(`weight`,card.weight,1),class:``}),card.density&&(!focus$1||focus$1===`density`||detailed)&&res.push({iconType:icons.weight,keyLabel:detailed?`Density`:``,valueLabel:units.buildString(`weight`,card.density,2),class:``}),card.storage&&(!focus$1||focus$1===`storage`||detailed)&&res.push({iconType:icons.boxDropOff01,keyLabel:detailed?`Available Volume`:``,valueLabel:(card.storage.storedVolume+(detailed?` / `+card.storage.capacity:``)).replace(/ /g,` `),class:``}),card.slots&&(!focus$1||focus$1===`slots`||detailed)&&res.push({iconType:icons.boxDropOff01,keyLabel:detailed?`Slots`:``,valueLabel:card.slots,class:``}),card.task&&(!focus$1||focus$1===`task`||detailed)&&res.push({iconType:icons.checkboxOff,keyLabel:detailed?`Task`:``,valueLabel:card.task,class:`full-width`}),card.cardType==`loaner`&&(!focus$1||detailed)&&res.push({iconType:icons.steeringWheelSporty,keyLabel:detailed?`Loaner`:``,valueLabel:detailed?card.isFacilityCard?`This vehicle can be loaned for delivery.`:`This vehicle can be used for delivery.`:`Loaner`,class:`full-width`}),card.cardType==`loaner`&&card.loanerCut&&!focus$1&&detailed&&res.push({iconType:icons.carCoins,keyLabel:detailed?`Loaner Cut`:``,valueLabel:detailed?`Organization takes `+(card.loanerCut.value*100-card.loanerCut.value*100%1)+`% of rewards earned with this loaner.`:card.loanerCut.value*100-card.loanerCut.value*100%1+`%`,class:`full-width`}),card.organizationName&&(!focus$1||detailed)&&res.push({iconType:icons.peopleOutline,keyLabel:detailed?`Organization`:``,valueLabel:$tt(card.organizationName),class:``}),card.capacity&&card.capacity.length)for(let cap of card.capacity)res.push({iconType:icons[cap.icon],keyLabel:detailed?`Capacity`:``,valueLabel:detailed?cap.labelLong:cap.labelShort,class:``});if(detailed&&card.modifiers&&card.modifiers.length>0)for(let mod of card.modifiers)res.push({iconType:icons[mod.icon],keyLabel:mod.label,valueLabel:mod.description,class:`full-width`+(mod.important?` orange`:``),iconColor:mod.important?`var(--bng-orange-300)`:``});return res});return(_ctx,_cache)=>(openBlock(),createBlock(unref(bngCard_default),mergeProps({class:[`card-item`,getCargoCardClass(__props.card)]},!__props.detailed&&{"bng-nav-item":!0,tabindex:1},{onClick:_cache[15]||=withModifiers(()=>{},[`stop`])}),{default:withCtx(()=>[!__props.detailed&&__props.card.thumbnail?(openBlock(),createBlock(unref(aspectRatio_default),{key:0,class:`image`,ratio:`4:3`,"external-image":__props.card.thumbnail},{default:withCtx(()=>[!__props.card.enabled&&__props.card.disableReason.type==`locked`?(openBlock(),createBlock(unref(bngIcon_default),{key:0,type:unref(icons).lockClosed,class:`icon`},null,8,[`type`])):createCommentVNode(``,!0)]),_:1},8,[`external-image`])):createCommentVNode(``,!0),createBaseVNode(`div`,{class:normalizeClass({"card-content-flex":!0,"with-actions":!__props.detailed})},[createBaseVNode(`div`,{class:normalizeClass([`heading-wrapper`,{"heading-detailed":__props.detailed}])},[__props.detailed?(openBlock(),createBlock(unref(bngCardHeading_default),{key:0,type:__props.ribbon?`ribbon`:`none`,class:`card-heading`},{default:withCtx(()=>[context.value===``?createCommentVNode(``,!0):(openBlock(),createElementBlock(`span`,_hoisted_1$234,toDisplayString(context.value),1)),createBaseVNode(`div`,null,[__props.card.vehName?(openBlock(),createElementBlock(Fragment,{key:1},[createTextVNode(toDisplayString(__props.card.vehName),1)],64)):(openBlock(),createElementBlock(Fragment,{key:0},[createTextVNode(toDisplayString(__props.card.name),1)],64))])]),_:1},8,[`type`])):(openBlock(),createElementBlock(Fragment,{key:1},[__props.card.vehName?(openBlock(),createElementBlock(`div`,_hoisted_3$167,toDisplayString(__props.card.vehName),1)):(openBlock(),createElementBlock(`div`,_hoisted_2$192,toDisplayString(__props.card.name),1))],64)),createBaseVNode(`div`,{class:normalizeClass([`pill pill-blue`,{"pill-orange":isLoadingFacilityCard.value}])},[typeof rewardMoney.value==`number`?(openBlock(),createBlock(unref(bngUnit_default),{key:0,class:`reward-money`,money:rewardMoney.value},null,8,[`money`])):(openBlock(),createBlock(unref(bngPropVal_default),{key:1,class:`reward-money`,iconType:unref(icons).beamCurrency,valueLabel:rewardMoney.value},null,8,[`iconType`,`valueLabel`])),hasIds.value&&!__props.card.transientMove?(openBlock(),createBlock(unref(bngPropVal_default),{key:2,class:`amount-avail`,valueLabel:`×`+__props.card.ids.length},null,8,[`valueLabel`])):createCommentVNode(``,!0),hasIds.value&&__props.card.transientMove?(openBlock(),createBlock(unref(bngPropVal_default),{key:3,class:`amount-avail`,valueLabel:`×`+__props.card.transientMoveCounts},null,8,[`valueLabel`])):createCommentVNode(``,!0),isPerLiter.value?(openBlock(),createBlock(unref(bngPropVal_default),{key:4,class:`amount-avail`,valueLabel:`/L`})):createCommentVNode(``,!0),__props.card.materialType?(openBlock(),createBlock(unref(bngPropVal_default),{key:5,class:`amount-avail`,valueLabel:__props.card.slots+` L`},null,8,[`valueLabel`])):createCommentVNode(``,!0)],2)],2),!__props.card.showAmountSelector&&cargoProps.value.length>0&&__props.detailed?(openBlock(),createElementBlock(`div`,{key:0,class:normalizeClass({"body-grid":__props.detailed,"body-list-wrapped":!__props.detailed,"content-detailed":__props.detailed})},[(openBlock(!0),createElementBlock(Fragment,null,renderList(cargoProps.value,props$1=>(openBlock(),createBlock(unref(bngPropVal_default),mergeProps({ref_for:!0},props$1),null,16))),256))],2)):createCommentVNode(``,!0),__props.detailed&&isMoving.value?(openBlock(),createElementBlock(`div`,{key:1,class:normalizeClass([`buttons-disabled-reason`,{"disabled-load-actions":!__props.card.enabled||!__props.showButtons,"footer-detailed":__props.detailed}])},[createVNode(unref(bngPropVal_default),{class:`prop`,iconType:unref(icons).info,keyLabel:``,valueLabel:`Cannot modify cargo while any vehicle is moving.`},null,8,[`iconType`])],2)):createCommentVNode(``,!0),createBaseVNode(`div`,{class:normalizeClass([`load-actions-wrapper`,{"disabled-load-actions":!__props.card.enabled||!__props.showButtons,"footer-detailed":__props.detailed,"chevrons-bg":__props.card.transientMoveCounts>0||__props.card.spawnWhenCommitingCargo||__props.card._transientMaterialMoveAmount>0}])},[createBaseVNode(`div`,_hoisted_4$140,[__props.detailed?createCommentVNode(``,!0):(openBlock(),createElementBlock(Fragment,{key:0},[(openBlock(!0),createElementBlock(Fragment,null,renderList(propIcons.value,icon=>(openBlock(),createBlock(unref(bngIcon_default),mergeProps({class:`icon`},{ref_for:!0},icon),null,16))),256)),(openBlock(!0),createElementBlock(Fragment,null,renderList(cargoProps.value,props$1=>(openBlock(),createBlock(unref(bngPropVal_default),mergeProps({class:`prop`},{ref_for:!0},props$1),null,16))),256))],64))]),__props.card.enabled&&__props.showButtons?(openBlock(),createElementBlock(`div`,{key:0,class:normalizeClass([`load-actions-buttons`,{undetailed:!__props.detailed}])},[__props.card.cardType==`parcelGroup`?(openBlock(),createElementBlock(Fragment,{key:0},[__props.card.isFacilityCard?(openBlock(),createElementBlock(Fragment,{key:0},[__props.card.transientMoveCounts==0?createCommentVNode(``,!0):(openBlock(),createBlock(unref(bngButton_default),{key:0,class:normalizeClass(__props.detailed?``:`button-load`),accent:unref(ACCENTS).secondary,"icon-right":unref(icons).undo,label:__props.detailed?`Clear load`:``,onClick:_cache[0]||=$event=>unref(cargoOverviewStore).clearLoad(__props.card),disabled:isMoving.value,tabindex:`0`},null,8,[`class`,`accent`,`icon-right`,`label`,`disabled`])),__props.card.autoLoadLocations&&__props.card.autoLoadLocations.length==0?createCommentVNode(``,!0):(openBlock(),createBlock(unref(bngButton_default),{key:1,class:normalizeClass(__props.detailed?``:`button-load`),accent:unref(ACCENTS).secondary,"icon-right":unref(icons).wrench,label:__props.detailed?`Custom load`:``,onClick:_cache[1]||=$event=>unref(cargoOverviewStore).loadCargoCustom(__props.card),disabled:isMoving.value,tabindex:`0`},null,8,[`class`,`accent`,`icon-right`,`label`,`disabled`])),__props.card.transientMoveCounts==__props.card.ids.length||__props.card.autoLoadLocations.length==0||!__props.card.autoLoadLocations.length?createCommentVNode(``,!0):(openBlock(),createBlock(unref(bngButton_default),{key:2,class:normalizeClass(__props.detailed?``:`button-load`),accent:unref(ACCENTS).main,"icon-right":unref(icons).arrowLargeRight,label:__props.detailed?`Load all`:``,onClick:_cache[2]||=$event=>unref(cargoOverviewStore).loadCargoAuto(__props.card),disabled:isMoving.value,tabindex:`0`},null,8,[`class`,`accent`,`icon-right`,`label`,`disabled`]))],64)):(openBlock(),createElementBlock(Fragment,{key:1},[__props.card.transientMoveCounts>0?(openBlock(),createBlock(unref(bngButton_default),{key:0,class:normalizeClass(__props.detailed?``:`button-load`),accent:unref(ACCENTS).attention,"icon-right":unref(icons).undo,label:__props.detailed?`Clear Load`:``,onClick:_cache[3]||=$event=>unref(cargoOverviewStore).clearLoad(__props.card),disabled:isMoving.value,tabindex:`0`},null,8,[`class`,`accent`,`icon-right`,`label`,`disabled`])):(openBlock(),createBlock(unref(bngButton_default),{key:1,class:normalizeClass(__props.detailed?``:`button-load`),accent:unref(ACCENTS).attention,"icon-right":unref(icons).trashBin1,label:__props.detailed?`Throw Away`:``,onClick:_cache[4]||=$event=>unref(cargoOverviewStore).throwAway(__props.card),disabled:isMoving.value,tabindex:`0`},null,8,[`class`,`accent`,`icon-right`,`label`,`disabled`])),__props.card.materialType===void 0?(openBlock(),createBlock(unref(bngButton_default),{key:2,class:normalizeClass(__props.detailed?``:`button-load`),accent:unref(ACCENTS).primary,"icon-right":unref(icons).wrench,label:__props.detailed?`Custom load`:``,onClick:_cache[5]||=$event=>unref(cargoOverviewStore).loadCargoCustom(__props.card),disabled:isMoving.value,tabindex:`0`},null,8,[`class`,`accent`,`icon-right`,`label`,`disabled`])):createCommentVNode(``,!0),__props.card.materialType!==void 0&&__props.card.transientMove?(openBlock(),createBlock(unref(bngButton_default),{key:3,class:normalizeClass(__props.detailed?``:`button-load`),accent:unref(ACCENTS).primary,"icon-right":unref(icons).wrench,label:__props.detailed?`Custom Load`:``,onClick:_cache[6]||=$event=>unref(cargoOverviewStore).modifyMaterialLoad(__props.card),disabled:isMoving.value,tabindex:`0`},null,8,[`class`,`accent`,`icon-right`,`label`,`disabled`])):createCommentVNode(``,!0)],64))],64)):createCommentVNode(``,!0),__props.card.isFacilityCard?(openBlock(),createElementBlock(Fragment,{key:1},[__props.card.cardType==`storage`?(openBlock(),createBlock(unref(bngButton_default),{key:0,class:normalizeClass(__props.detailed?``:`button-load`),accent:unref(ACCENTS).main,icon:unref(icons).wrench,label:__props.detailed?`Custom load`:``,onClick:_cache[7]||=$event=>unref(cargoOverviewStore).loadStorageCustom(__props.card),disabled:isMoving.value,tabindex:`0`},null,8,[`class`,`accent`,`icon`,`label`,`disabled`])):createCommentVNode(``,!0),__props.card.cardType==`vehicleOffer`&&!__props.card.spawnWhenCommitingCargo?(openBlock(),createBlock(unref(bngButton_default),{key:1,class:normalizeClass(__props.detailed?``:`button-load`),accent:unref(ACCENTS).main,icon:unref(icons).keys1,label:__props.detailed?`Accept Job`:``,onClick:_cache[8]||=$event=>unref(cargoOverviewStore).loadOffer(__props.card),disabled:isMoving.value,tabindex:`0`},null,8,[`class`,`accent`,`icon`,`label`,`disabled`])):createCommentVNode(``,!0),__props.card.cardType==`vehicleOffer`&&__props.card.spawnWhenCommitingCargo?(openBlock(),createBlock(unref(bngButton_default),{key:2,class:normalizeClass(__props.detailed?``:`button-load`),accent:unref(ACCENTS).attention,icon:unref(icons).undo,label:__props.detailed?`Decline Job`:``,onClick:_cache[9]||=$event=>unref(cargoOverviewStore).loadOffer(__props.card),disabled:isMoving.value,tabindex:`0`},null,8,[`class`,`accent`,`icon`,`label`,`disabled`])):createCommentVNode(``,!0),__props.card.cardType==`loaner`&&!__props.card.spawnWhenCommitingCargo?(openBlock(),createBlock(unref(bngButton_default),{key:3,class:normalizeClass(__props.detailed?``:`button-load`),accent:unref(ACCENTS).main,icon:unref(icons).keys1,label:__props.detailed?`Accept Loaner`:``,onClick:_cache[10]||=$event=>unref(cargoOverviewStore).loadLoaner(__props.card),disabled:isMoving.value,tabindex:`0`},null,8,[`class`,`accent`,`icon`,`label`,`disabled`])):createCommentVNode(``,!0),__props.card.cardType==`loaner`&&__props.card.spawnWhenCommitingCargo?(openBlock(),createBlock(unref(bngButton_default),{key:4,class:normalizeClass(__props.detailed?``:`button-load`),accent:unref(ACCENTS).attention,icon:unref(icons).undo,label:__props.detailed?`Decline Loaner`:``,onClick:_cache[11]||=$event=>unref(cargoOverviewStore).loadLoaner(__props.card),disabled:isMoving.value,tabindex:`0`},null,8,[`class`,`accent`,`icon`,`label`,`disabled`])):createCommentVNode(``,!0)],64)):(openBlock(),createElementBlock(Fragment,{key:2},[__props.card.cardType==`vehicleOffer`&&!__props.card.spawnWhenCommitingCargo?(openBlock(),createBlock(unref(bngButton_default),{key:0,class:normalizeClass(__props.detailed?``:`button-load`),accent:unref(ACCENTS).attention,icon:unref(icons).trashBin1,label:__props.detailed?`Abandon Job`:``,onClick:_cache[12]||=$event=>unref(cargoOverviewStore).abandonOffer(__props.card),disabled:isMoving.value,tabindex:`0`},null,8,[`class`,`accent`,`icon`,`label`,`disabled`])):createCommentVNode(``,!0),__props.card.cardType==`loaner`&&__props.card.isSpawnedLoaner?(openBlock(),createBlock(unref(bngButton_default),{key:1,class:normalizeClass(__props.detailed?``:`button-load`),accent:unref(ACCENTS).attention,icon:unref(icons).trashBin1,label:__props.detailed?`Return Loaner`:``,onClick:_cache[13]||=$event=>unref(cargoOverviewStore).returnLoaner(__props.card.id),disabled:isMoving.value,tabindex:`0`},null,8,[`class`,`accent`,`icon`,`label`,`disabled`])):createCommentVNode(``,!0)],64))],2)):createCommentVNode(``,!0),chevronProp.value?(openBlock(),createElementBlock(`div`,_hoisted_5$122,[createVNode(unref(bngPropVal_default),mergeProps({class:`amount-load`},chevronProp.value),null,16),createBaseVNode(`div`,_hoisted_6$104,[(openBlock(),createElementBlock(`svg`,_hoisted_7$91,[(openBlock(),createElementBlock(`svg`,_hoisted_8$76,[__props.card.transientMoveCounts===0?(openBlock(),createElementBlock(`path`,_hoisted_9$69)):(openBlock(),createElementBlock(`path`,_hoisted_10$60))]))]))])])):createCommentVNode(``,!0)],2),__props.card.showAmountSelector?(openBlock(),createElementBlock(`div`,_hoisted_11$54,[createTextVNode(` Selected Amount: `+toDisplayString(__props.card.amountSelector)+` `,1),createVNode(unref(bngSlider_default),{class:`slider`,min:0,max:__props.card.maxCount,step:1,modelValue:__props.card.amountSelector,"onUpdate:modelValue":_cache[14]||=$event=>__props.card.amountSelector=$event,onValueChanged:onAmountSelectorChanged},null,8,[`max`,`modelValue`])])):createCommentVNode(``,!0),createBaseVNode(`div`,{class:normalizeClass([`footer-grid`,{"footer-detailed":__props.detailed}])},[__props.detailed?(openBlock(),createElementBlock(Fragment,{key:0},[(__props.focus===`none`||!__props.focus)&&!__props.hideModsAndTimer?(openBlock(),createElementBlock(`div`,_hoisted_12$43,[__props.detailed?createCommentVNode(``,!0):(openBlock(!0),createElementBlock(Fragment,{key:0},renderList(__props.card.modifiers,mod=>(openBlock(),createBlock(unref(bngIcon_default),{type:unref(icons)[mod.icon]},null,8,[`type`]))),256))])):createCommentVNode(``,!0),__props.card.remainingTime&&(__props.focus===`none`||!__props.focus)&&!__props.hideModsAndTimer?(openBlock(),createElementBlock(`div`,_hoisted_13$36,[__props.card.remainingTime.type===`preLoad`?(openBlock(),createElementBlock(`div`,_hoisted_14$34,`Time for delivery: `+toDisplayString(unref(formatTime)(__props.card.remainingTime.time,2)),1)):createCommentVNode(``,!0),__props.card.remainingTime.type===`untilDelayed`?(openBlock(),createElementBlock(Fragment,{key:1},[createTextVNode(` Time until delivery is Delayed: `+toDisplayString(unref(formatTime)(__props.card.remainingTime.time,2)),1)],64)):createCommentVNode(``,!0),__props.card.remainingTime.type===`untilLate`?(openBlock(),createElementBlock(Fragment,{key:2},[createTextVNode(` Time until delivery is Late: `+toDisplayString(unref(formatTime)(__props.card.remainingTime.time,2)),1)],64)):createCommentVNode(``,!0),__props.card.remainingTime.type===`late`?(openBlock(),createElementBlock(Fragment,{key:3},[createTextVNode(` Delivery is late `)],64)):createCommentVNode(``,!0)])):createCommentVNode(``,!0)],64)):createCommentVNode(``,!0),__props.card.remainingTime&&__props.card.remainingTime.percent&&__props.card.isPlayerCard?(openBlock(),createElementBlock(`div`,{key:1,class:normalizeClass([`timer-progress-bar`,{slim:!__props.detailed}])},[createBaseVNode(`div`,{class:`progress-bar-fill`,style:normalizeStyle({width:__props.card.remainingTime.percent*100+`%`})},null,4)],2)):createCommentVNode(``,!0)],2)],2)]),_:1},16,[`class`]))}},CargoCard_default=__plugin_vue_export_helper_default(_sfc_main$263,[[`__scopeId`,`data-v-bafe8e5e`]]),_hoisted_1$233={class:`info-container`},_hoisted_2$191={key:0,class:`header`},_hoisted_3$166={key:0,class:`label`},_hoisted_4$139={class:`props`},_hoisted_5$121={key:4,class:`prop pill`},_sfc_main$262={__name:`CargoInfo`,props:{label:String,fillInfo:Object,meta:Object},setup(__props){let{units}=useBridge(),props=__props;return(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$233,[__props.meta.type===`hidden`?createCommentVNode(``,!0):(openBlock(),createElementBlock(`div`,_hoisted_2$191,[__props.label?(openBlock(),createElementBlock(`div`,_hoisted_3$166,[__props.meta.type==`task`?(openBlock(),createBlock(unref(bngIcon_default),{key:0,class:`icon`,type:unref(icons).checkboxOff},null,8,[`type`])):createCommentVNode(``,!0),__props.label?(openBlock(),createElementBlock(Fragment,{key:1},[createTextVNode(toDisplayString(_ctx.$tt(__props.label)),1)],64)):createCommentVNode(``,!0)])):createCommentVNode(``,!0),createBaseVNode(`div`,_hoisted_4$139,[__props.meta.type==`container`||__props.meta.type==`totalStorage`?(openBlock(),createBlock(unref(bngPropVal_default),{key:0,iconType:unref(icons)[__props.meta.icon],valueLabel:__props.meta.usedCargoSlots+` / `+__props.meta.totalCargoSlots},null,8,[`iconType`,`valueLabel`])):createCommentVNode(``,!0),__props.meta.type==`location`?(openBlock(),createBlock(unref(bngPropVal_default),{key:1,iconType:unref(icons).mapPoint,valueLabel:unref(units).buildString(`distance`,__props.meta.distance,1),style:{"--icon-size":`1.25em`}},null,8,[`iconType`,`valueLabel`])):createCommentVNode(``,!0),__props.meta.type==`trash`?(openBlock(),createBlock(unref(bngIcon_default),{key:2,class:`icon`,type:unref(icons).trashBin1},null,8,[`type`])):createCommentVNode(``,!0),props&&props.length?(openBlock(!0),createElementBlock(Fragment,{key:3},renderList(props,prop=>(openBlock(),createBlock(unref(bngPropVal_default),{iconType:unref(icons)[prop.icon],valueLabel:prop.label},null,8,[`iconType`,`valueLabel`]))),256)):createCommentVNode(``,!0),__props.fillInfo?(openBlock(),createElementBlock(`div`,_hoisted_5$121,[createVNode(unref(bngPropVal_default),{iconType:unref(icons)[__props.fillInfo.icon],valueLabel:__props.fillInfo.usedSlots+` / `+__props.fillInfo.availableSlots},null,8,[`iconType`,`valueLabel`])])):createCommentVNode(``,!0)]),__props.meta.fillPercent||__props.meta.fillPercent==0?(openBlock(),createElementBlock(`div`,{key:1,class:normalizeClass([`progress-bar`,{trash:__props.meta.type==`trash`}])},[__props.meta.fillPercentHighlight>0?(openBlock(),createElementBlock(`div`,{key:0,class:`progress-bar-fill highlight`,style:normalizeStyle({width:`${__props.meta.fillPercentHighlight*100}%`})},null,4)):createCommentVNode(``,!0),createBaseVNode(`div`,{class:`progress-bar-fill`,style:normalizeStyle({width:`${__props.meta.fillPercent*100}%`})},null,4)],2)):createCommentVNode(``,!0)]))]))}},CargoInfo_default=__plugin_vue_export_helper_default(_sfc_main$262,[[`__scopeId`,`data-v-ba3be877`]]),_hoisted_1$232={class:`group`},_hoisted_2$190={class:`cards`},_sfc_main$261={__name:`CardGroup`,props:{label:String,fillInfo:Object,meta:Object},setup(__props){return(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$232,[createVNode(CargoInfo_default,{label:__props.label,"fill-info":__props.fillInfo,meta:__props.meta},null,8,[`label`,`fill-info`,`meta`]),createBaseVNode(`div`,_hoisted_2$190,[renderSlot(_ctx.$slots,`default`,{},void 0,!0)])]))}},CardGroup_default=__plugin_vue_export_helper_default(_sfc_main$261,[[`__scopeId`,`data-v-f21d8701`]]),_hoisted_1$231={class:`customload-wrapper`,"bng-ui-scope":`cargoLoadPopup`},_hoisted_2$189={class:`card-container`},_hoisted_3$165={class:`content target-grid`},_hoisted_4$138={key:0,class:`target-tile`},_hoisted_5$120={class:`loading-controls amount-load`},_hoisted_6$103={class:`amount`},_hoisted_7$90={class:`chevron-arrow`},_hoisted_8$75={class:`chevron-outer`,width:`100%`,height:`100%`,xmlns:`http://www.w3.org/2000/svg`},_hoisted_9$68={class:`chevron-inner`,viewBox:`4 2 12 60`,preserveAspectRatio:`xMaxYMid slice`},_hoisted_10$59={key:0,d:`M-11 -2H1L14 32L1 66H-11V-2Z`,fill:`rgb(var(--chevron-color))`,"fill-opacity":`var(--chevron-alpha)`,stroke:`rgb(var(--chevron-color))`,"stroke-width":`3`,"vector-effect":`non-scaling-stroke`},_hoisted_11$53={key:1,d:`M-11 -2H1L14 32L1 66H-11V-2Z`,fill:`rgb(var(--chevron-color))`,"fill-opacity":`var(--chevron-alpha)`,stroke:`var(--bng-orange-500)`,"stroke-width":`3`,"vector-effect":`non-scaling-stroke`},_hoisted_12$42={key:1,class:`target-tile trash`},_hoisted_13$35={class:`loading-controls amount-load`},_hoisted_14$33={class:`amount`},_hoisted_15$32={class:`chevron-arrow`},_hoisted_16$32={class:`chevron-outer`,width:`100%`,height:`100%`,xmlns:`http://www.w3.org/2000/svg`},_hoisted_17$26={class:`chevron-inner`,viewBox:`4 2 12 60`,preserveAspectRatio:`xMaxYMid slice`},_hoisted_18$23={key:0,d:`M-11 -2H1L14 32L1 66H-11V-2Z`,fill:`rgb(var(--chevron-color))`,"fill-opacity":`var(--chevron-alpha)`,stroke:`rgb(var(--chevron-color))`,"stroke-width":`3`,"vector-effect":`non-scaling-stroke`},_hoisted_19$20={key:1,d:`M-11 -2H1L14 32L1 66H-11V-2Z`,fill:`rgb(var(--chevron-color))`,"fill-opacity":`var(--chevron-alpha)`,stroke:`var(--bng-add-red-500)`,"stroke-width":`3`,"vector-effect":`non-scaling-stroke`},_hoisted_20$17={class:`buttons content`},__default__$3={wrapper:{fade:!0,blur:!0,style:popupContainer.default},position:[popupPosition.center,popupPosition.center]},_sfc_main$260=Object.assign(__default__$3,{__name:`CargoLoadPopup`,props:{cargo:Object,storageData:Object,throwAway:Boolean},emits:[`return`],setup(__props,{emit:__emit}){let cargoOverviewStore=useCargoOverviewStore(),{events:events$3}=useBridge(),{units}=useBridge();useUINavScope(`cargoLoadPopup`);let emit$1=__emit,props=__props,isFacilityCard=ref(!1),vehicleFilterModel=ref([]),vehicleFilterOptions=ref([]),vehicleFilterChanged=function(filter){for(let target of targetLocations.value)target.hidden=target.containerVehicleInfo&&!filter.includes(target.containerVehicleInfo.vehId)},originalTransientMoveCounts=0,original_transientMaterialMoveAmount=0,card=ref({});ref(0);let throwAwayValue=ref(0),trashMeta=ref({}),loadingName=ref(``),slotsPerItem=ref(0),weightPerItem=ref(0),moneyRewardPerItem=ref(0),targetLocations=ref({}),less=function(target){target?(target.loadSliderValue=Math.max(0,target.loadSliderValue-1),updateSliderAmounts(target)):(throwAwayValue.value=Math.max(0,throwAwayValue.value-1),updateThrowAwayAmount())},more=function(target){target?(target.loadSliderValue=Math.min(target.loadSliderMax,target.loadSliderValue+1),updateSliderAmounts(target)):(throwAwayValue.value=Math.min(totalAvailableAmount.value,throwAwayValue.value+1),updateThrowAwayAmount())},acceptClickHandler=()=>{let loadIdx=0;if(props.cargo)for(let id of props.cargo.ids)Lua_default.career_modules_delivery_cargoScreen.clearTransientMoveForCargo(id);if(props.storageData&&Lua_default.career_modules_delivery_cargoScreen.clearTransientMovesForStorage(props.storageData.material.id),!props.throwAway)for(let target of targetLocations.value){if(props.cargo)for(let i=0;i{isFacilityCard.value&&(card.value.transientMoveCounts=originalTransientMoveCounts,card.value._transientMaterialMoveAmount=0),emit$1(`return`,!0)},totalAvailableAmount=ref(0),loadedAmount=ref(0),updateSliderAmounts=changedItem=>{loadedAmount.value=0;for(let target of targetLocations.value)target.maxAmount&&(loadedAmount.value+=target.loadSliderValue);let tooMuch=loadedAmount.value-totalAvailableAmount.value;if(tooMuch>0){for(let target of targetLocations.value)if(target.maxAmount&&target!==changedItem){let before=target.loadSliderValue;target.loadSliderValue=Math.max(0,target.loadSliderValue-tooMuch);let diff=target.loadSliderValue-before;tooMuch+=diff}loadedAmount.value=totalAvailableAmount.value}for(let target of targetLocations.value)target.meta.usedCargoSlots=target.usedCargoSlots+target.loadSliderValue*slotsPerItem.value,target.meta.fillPercentHighlight=target.meta.usedCargoSlots/target.meta.totalCargoSlots;isFacilityCard.value&&(throwAwayValue.value=totalAvailableAmount.value-loadedAmount.value,card.value.transientMoveCounts=loadedAmount.value,card.value._transientMaterialMoveAmount=loadedAmount.value,trashMeta.value.fillPercent=throwAwayValue.value/totalAvailableAmount.value)},updateThrowAwayAmount=()=>{loadedAmount.value=0;for(let target of targetLocations.value)target.maxAmount&&(loadedAmount.value+=target.loadSliderValue);let tooMuch=loadedAmount.value-totalAvailableAmount.value+throwAwayValue.value;for(let target of targetLocations.value){if(target.maxAmount){let before=target.loadSliderValue;target.loadSliderValue=Math.min(target.loadSliderMax,Math.max(0,target.loadSliderValue-tooMuch));let diff=target.loadSliderValue-before;tooMuch+=diff}loadedAmount.value=totalAvailableAmount.value}updateSliderAmounts()},splittable=ref(!1);return onMounted(()=>{if(getUINavServiceInstance().activate(),getUINavServiceInstance().clearFilteredEvents(),props.cargo){if(loadingName.value=props.cargo.name,slotsPerItem.value=props.cargo.slots,weightPerItem.value=props.cargo.weight,moneyRewardPerItem.value=props.cargo.rewardMoney,targetLocations.value=props.cargo.targetLocations,totalAvailableAmount.value=props.cargo.ids.length,props.cargo.splittable){splittable.value=!0,totalAvailableAmount.value=props.cargo.slots,slotsPerItem.value=1;for(let target of targetLocations.value)target.maxAmount=target.totalCargoSlots-target.usedCargoSlots}card.value=props.cargo,isFacilityCard.value=card.value.isFacilityCard,originalTransientMoveCounts=card.value.transientMoveCounts}props.storageData&&(console.log(props.storageData),loadingName.value=props.storageData.material.name,slotsPerItem.value=1,weightPerItem.value=props.storageData.material.density,moneyRewardPerItem.value=1,targetLocations.value=props.storageData.targetLocations,totalAvailableAmount.value=props.storageData.storage.storedVolume,card.value=props.storageData,isFacilityCard.value=card.value.isFacilityCard),targetLocations.value.length||(targetLocations.value=[]);for(let target of targetLocations.value)target.loadSliderValue=ref(target.selectedAmount),target.loadSliderMax=ref(Math.min(target.maxAmount,totalAvailableAmount.value)),target.meta={type:`container`,usedCargoSlots:target.usedCargoSlots,totalCargoSlots:target.totalCargoSlots,icon:`cardboardBox`,fillPercent:target.usedCargoSlots/target.totalCargoSlots};updateSliderAmounts();let vehicles={};for(let target of targetLocations.value)target.containerVehicleInfo&&(vehicles[target.containerVehicleInfo.vehId]=target.containerVehicleInfo);for(let vehId in vehicleFilterOptions.value=[],vehicles){let veh=vehicles[vehId];vehicleFilterOptions.value.push({value:veh.vehId,label:veh.vehName})}for(let vehId in vehicleFilterOptions.value.sort((a$1,b)=>a$1.name{window.bngVue.getCurrentRoute().name==`unknown`&&getUINavServiceInstance().setFilteredEventsAllExcept(UI_EVENTS.menu,UI_EVENTS.pause,UI_EVENTS.center_cam)}),(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$231,[createVNode(unref(bngCard_default),null,{default:withCtx(()=>[__props.throwAway?(openBlock(),createBlock(unref(bngCardHeading_default),{key:1,type:`ribbon`},{default:withCtx(()=>[createTextVNode(` Throwing away `+toDisplayString(loadingName.value),1)]),_:1})):(openBlock(),createBlock(unref(bngCardHeading_default),{key:0,type:`ribbon`},{default:withCtx(()=>[..._cache[4]||=[createTextVNode(`Custom Loading`,-1)]]),_:1})),createBaseVNode(`div`,_hoisted_2$189,[createVNode(CargoCard_default,{ribbon:!1,card:card.value,hideProps:!1,hideModsAndTimer:!0,showButtons:!1,detailed:!0,alwaysShowLoadingWrapper:isFacilityCard.value},null,8,[`card`,`alwaysShowLoadingWrapper`])]),_ctx.vehicles&&_ctx.vehicles.length>1?(openBlock(),createElementBlock(Fragment,{key:2},[_cache[5]||=createBaseVNode(`span`,null,`Vehicles`,-1),__props.throwAway?createCommentVNode(``,!0):(openBlock(),createBlock(unref(bngPillFilters_default),{key:0,modelValue:vehicleFilterModel.value,"onUpdate:modelValue":_cache[0]||=$event=>vehicleFilterModel.value=$event,selectMany:``,options:vehicleFilterOptions.value,showCheckIcon:!1,onValueChanged:vehicleFilterChanged},null,8,[`modelValue`,`options`]))],64)):createCommentVNode(``,!0),createBaseVNode(`div`,_hoisted_3$165,[targetLocations.value&&!__props.throwAway?(openBlock(!0),createElementBlock(Fragment,{key:0},renderList(targetLocations.value,(target,targetIndex)=>(openBlock(),createElementBlock(Fragment,null,[target.hidden?createCommentVNode(``,!0):(openBlock(),createElementBlock(`div`,_hoisted_4$138,[createVNode(CardGroup_default,{label:target.label,meta:target.meta},{default:withCtx(()=>[createBaseVNode(`div`,{class:normalizeClass([`to-load`,{"none-assigned":target.loadSliderValue==0}])},[createBaseVNode(`div`,_hoisted_5$120,[createVNode(unref(bngButton_default),{class:`less`,iconLeft:unref(icons).minus,accent:`text`,onClick:$event=>less(target)},null,8,[`iconLeft`,`onClick`]),createVNode(unref(bngSlider_default),{"bng-no-nav":``,class:`slider`,min:0,max:target.loadSliderMax,step:1,modelValue:target.loadSliderValue,"onUpdate:modelValue":$event=>target.loadSliderValue=$event,onValueChanged:$event=>updateSliderAmounts(target)},null,8,[`max`,`modelValue`,`onUpdate:modelValue`,`onValueChanged`]),createVNode(unref(bngButton_default),{class:`more`,iconLeft:unref(icons).plus,accent:`text`,onClick:$event=>more(target)},null,8,[`iconLeft`,`onClick`]),createBaseVNode(`div`,_hoisted_6$103,`×`+toDisplayString(target.loadSliderValue),1)]),createBaseVNode(`div`,_hoisted_7$90,[(openBlock(),createElementBlock(`svg`,_hoisted_8$75,[(openBlock(),createElementBlock(`svg`,_hoisted_9$68,[target.loadSliderValue===0?(openBlock(),createElementBlock(`path`,_hoisted_10$59)):(openBlock(),createElementBlock(`path`,_hoisted_11$53))]))]))])],2)]),_:2},1032,[`label`,`meta`])]))],64))),256)):createCommentVNode(``,!0),__props.cargo&&__props.cargo.throwAwayInfo&&unref(totalAvailableAmount)?(openBlock(),createElementBlock(`div`,_hoisted_12$42,[createVNode(CardGroup_default,{label:`Trash`,meta:trashMeta.value},{default:withCtx(()=>[createBaseVNode(`div`,{class:normalizeClass([`to-load`,{"none-assigned":throwAwayValue.value==0}])},[createBaseVNode(`div`,_hoisted_13$35,[createVNode(unref(bngButton_default),{class:`less`,iconLeft:unref(icons).minus,accent:`text`,onClick:_cache[1]||=$event=>less()},null,8,[`iconLeft`]),createVNode(unref(bngSlider_default),{"bng-no-nav":``,class:`slider`,min:0,max:unref(totalAvailableAmount),step:1,modelValue:throwAwayValue.value,"onUpdate:modelValue":_cache[2]||=$event=>throwAwayValue.value=$event,onValueChanged:updateThrowAwayAmount},null,8,[`max`,`modelValue`]),createVNode(unref(bngButton_default),{class:`more`,iconLeft:unref(icons).plus,accent:`text`,onClick:_cache[3]||=$event=>more()},null,8,[`iconLeft`]),createBaseVNode(`div`,_hoisted_14$33,`×`+toDisplayString(throwAwayValue.value),1)]),createBaseVNode(`div`,_hoisted_15$32,[(openBlock(),createElementBlock(`svg`,_hoisted_16$32,[(openBlock(),createElementBlock(`svg`,_hoisted_17$26,[throwAwayValue.value===0?(openBlock(),createElementBlock(`path`,_hoisted_18$23)):(openBlock(),createElementBlock(`path`,_hoisted_19$20))]))]))])],2)]),_:1},8,[`meta`])])):createCommentVNode(``,!0)]),createBaseVNode(`div`,_hoisted_20$17,[withDirectives(createVNode(unref(bngButton_default),{class:`button`,label:`Cancel`,accent:`secondary`,onClick:cancelClickHandler},null,512),[[unref(BngOnUiNav_default),void 0,`back,menu`,{asMouse:!0}]]),__props.cargo&&__props.cargo.throwAwayInfo&&throwAwayValue.value>0?withDirectives((openBlock(),createBlock(unref(bngButton_default),{key:0,class:`button`,accent:`attention`,onClick:acceptClickHandler},{default:withCtx(()=>[createTextVNode(toDisplayString(__props.throwAway?`Throw Away`:`Accept`)+` (`,1),createVNode(unref(bngUnit_default),{money:-__props.cargo.throwAwayInfo.penalty*throwAwayValue.value},null,8,[`money`]),_cache[6]||=createTextVNode(`) `,-1)]),_:1})),[[unref(BngFocusIf_default),!0],[unref(BngOnUiNav_default),void 0,`back,menu`,{asMouse:!0}]]):withDirectives((openBlock(),createBlock(unref(bngButton_default),{key:1,class:`button`,label:`Accept`,accent:`main`,onClick:acceptClickHandler},null,512)),[[unref(BngFocusIf_default),!0],[unref(BngOnUiNav_default),void 0,`back,menu`,{asMouse:!0}]])])]),_:1})]))}}),CargoLoadPopup_default=__plugin_vue_export_helper_default(_sfc_main$260,[[`__scopeId`,`data-v-0d30652e`]]),_hoisted_1$230={class:`settings-wrapper`,"bng-ui-scope":`cargoScreenSettings`},_hoisted_2$188={class:`cardContent`},_hoisted_3$164={class:`content`},_hoisted_4$137={class:`acceptButton`},__default__$2={wrapper:{fade:!0,blur:!0,style:popupContainer.default},position:[popupPosition.center,popupPosition.center]},_sfc_main$259=Object.assign(__default__$2,{__name:`CargoScreenSettings`,emits:[`return`],setup(__props,{emit:__emit}){useUINavScope(`cargoScreenSettings`);let emit$1=__emit,cargoOverviewStore=useCargoOverviewStore();ref();let facilityGroupingItems=[{label:`Item one`,value:1},{label:`Item two`,value:2},{label:`Item three`,value:3},{label:`Item four`,value:4},{label:`Item five`,value:5},{label:`Item six`,value:6},{label:`Item seven`,value:7},{label:`Item eight`,value:8},{label:`Item nine`,value:9},{label:`Item ten`,value:10},{label:`Item eleven`,value:11},{label:`Item twelve`,value:12},{label:`Item thirteen`,value:13},{label:`Item fourteen`,value:14},{label:`Item fifteen`,value:15},{label:`Item sixteen`,value:16},{label:`Item seventeen`,value:17},{label:`Item eighteen`,value:18},{label:`Item nineteen`,value:19},{label:`Item twenty`,value:20}];ref(),ref(),ref();let setFacilityGroupKey=key=>{cargoOverviewStore.facilityGroupingKey=key},setFacilitySortKey=key=>{cargoOverviewStore.facilitySortingKey=key},setPlayerGroupKey=key=>{cargoOverviewStore.playerGroupingKey=key},setPlayerSortKey=key=>{cargoOverviewStore.playerSortingKey=key};onMounted(()=>{console.log(facilityGroupingItems)});let acceptClickHandler=()=>{emit$1(`return`,!0)};return(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$230,[createVNode(unref(bngCard_default),null,{default:withCtx(()=>[createVNode(unref(bngCardHeading_default),{type:`ribbon`},{default:withCtx(()=>[..._cache[1]||=[createTextVNode(`Settings`,-1)]]),_:1}),createVNode(unref(bngCardHeading_default),null,{default:withCtx(()=>[..._cache[2]||=[createTextVNode(`Facility Display`,-1)]]),_:1}),createBaseVNode(`div`,_hoisted_2$188,[createBaseVNode(`div`,null,[_cache[3]||=createTextVNode(` Group By: `,-1),(openBlock(!0),createElementBlock(Fragment,null,renderList(unref(cargoOverviewStore).selectedFilter.groupings,gKey=>(openBlock(),createBlock(unref(bngButton_default),{onClick:$event=>setFacilityGroupKey(gKey)},{default:withCtx(()=>[createTextVNode(toDisplayString(unref(cargoOverviewStore).cargoData.facilityCardGroupSets[gKey].label),1)]),_:2},1032,[`onClick`]))),256))]),createBaseVNode(`div`,null,[_cache[4]||=createTextVNode(` Sorting: `,-1),(openBlock(!0),createElementBlock(Fragment,null,renderList(unref(cargoOverviewStore).cargoData.facilityCardGroupSets[unref(cargoOverviewStore).facilityGroupingKey].sortings,sKey=>(openBlock(),createBlock(unref(bngButton_default),{onClick:$event=>setFacilitySortKey(sKey)},{default:withCtx(()=>[createTextVNode(toDisplayString(unref(cargoOverviewStore).cargoData.sortingSets[sKey].label),1)]),_:2},1032,[`onClick`]))),256))])]),createBaseVNode(`div`,_hoisted_3$164,[createVNode(unref(bngCardHeading_default),null,{default:withCtx(()=>[..._cache[5]||=[createTextVNode(`My Cargo Display`,-1)]]),_:1}),createVNode(unref(bngSwitch_default),{modelValue:unref(cargoOverviewStore).automaticRoute,"onUpdate:modelValue":_cache[0]||=$event=>unref(cargoOverviewStore).automaticRoute=$event},{default:withCtx(()=>[..._cache[6]||=[createTextVNode(` Automatic route `,-1)]]),_:1},8,[`modelValue`]),createBaseVNode(`div`,null,[_cache[7]||=createTextVNode(` Group By: `,-1),(openBlock(!0),createElementBlock(Fragment,null,renderList(unref(cargoOverviewStore).playerGroupings,gKey=>(openBlock(),createBlock(unref(bngButton_default),{onClick:$event=>setPlayerGroupKey(gKey)},{default:withCtx(()=>[createTextVNode(toDisplayString(unref(cargoOverviewStore).cargoData.playerCardGroupSets[gKey].label),1)]),_:2},1032,[`onClick`]))),256))]),createBaseVNode(`div`,null,[_cache[8]||=createTextVNode(` Sorting: `,-1),(openBlock(!0),createElementBlock(Fragment,null,renderList(unref(cargoOverviewStore).cargoData.playerCardGroupSets[unref(cargoOverviewStore).facilityGroupingKey].sortings,sKey=>(openBlock(),createBlock(unref(bngButton_default),{onClick:$event=>setPlayerSortKey(sKey)},{default:withCtx(()=>[createTextVNode(toDisplayString(unref(cargoOverviewStore).cargoData.sortingSets[sKey].label),1)]),_:2},1032,[`onClick`]))),256))]),createBaseVNode(`div`,_hoisted_4$137,[withDirectives(createVNode(unref(bngButton_default),{label:`Continue`,accent:unref(ACCENTS).primary,onClick:acceptClickHandler},null,8,[`accent`]),[[unref(BngOnUiNav_default),void 0,`back,menu`,{asMouse:!0}]])])])]),_:1})]))}}),CargoScreenSettings_default=__plugin_vue_export_helper_default(_sfc_main$259,[[`__scopeId`,`data-v-9dd4f12f`]]),_forEach=(arr,func)=>Array.isArray(arr)&&arr.length>0&&arr.forEach(func);const useCargoOverviewStore=defineStore(`cargoOverview`,()=>{let{events:events$3}=useBridge(),cargoData=ref(),dropDownData=ref({}),newCargoAvailable=ref(!1),cargoHighlighted=ref(!1),automaticRoute=ref(!1),detailedDropOff=ref(!1),tutorialInfo=ref(),facilityGroupingKey=ref(`destinations`),facilitySortingKey=ref(`rewardMoney`),playerGroupings=[`containers`,`tasklist`,`ungrouped`],playerGroupingKey=ref(`tasklist`),playerSortingKey=ref(`cardId`),facilityId,parkingSpotPath,facilityFilter={value:`facility-info`,label:`Facility Info`,showInFilterTabs:!0,isFacilityPage:!0},filterSets=ref({}),filterSetsByValue=ref({}),selectedFilterRef=ref(),selectedFilter=ref(facilityFilter),selectFilter=f=>{Lua_default.career_modules_delivery_general.setSetting(`selectedFilterKey`,f),Lua_default.career_modules_delivery_cargoScreen.setCargoScreenTab(f);for(let filter of filterSets.value)if(filter.value==f[0]){let prevGrouping=facilityGroupingKey.value,prevSorting=facilitySortingKey.value;if(selectedFilter.value=filter,!filter.isFacilityPage&&(filter.groupings.includes(prevGrouping)||(facilityGroupingKey.value=filter.groupings[0]),cargoData.value.facilityCardGroupSets[facilityGroupingKey.value].sortings.includes(prevSorting)||(facilitySortingKey.value=cargoData.value.facilityCardGroupSets[facilityGroupingKey.value].sortings[0]),selectedCargo.value&&selectedCargo.value.isFacilityCard)){let contained=selectedCargo.value.filterTags[filter.value];if(contained)for(let groupKey of filter.groupings)for(let group of cargoData.value.facilityCardGroupSets[groupKey].groups)contained||=group.cardIdsUnsorted.includes(selectedCargo.value.cardId);contained||(selectedCargo.value=void 0)}}},facilityGroupings=computed(()=>selectedFilter.value?selectedFilter.value.groupings:[]),nextFacilityGrouping=()=>{let groups=facilityGroupings.value;facilityGroupingKey.value=groups[(groups.indexOf(facilityGroupingKey.value)+1)%groups.length]},facilitySortings=computed(()=>cargoData.value&&facilityGroupingKey.value&&cargoData.value.facilityCardGroupSets&&cargoData.value.facilityCardGroupSets[facilityGroupingKey.value]?cargoData.value.facilityCardGroupSets[facilityGroupingKey.value].sortings:[]),nextFacilitySorting=()=>{let group=facilitySortings.value;facilitySortingKey.value=group[(group.indexOf(facilitySortingKey.value)+1)%group.length]},nextPlayerGrouping=()=>{let groups=playerGroupings;playerGroupingKey.value=groups[(groups.indexOf(playerGroupingKey.value)+1)%groups.length]},playerSortings=computed(()=>cargoData.value&&facilityGroupingKey.value&&cargoData.value.playerCardGroupSets&&cargoData.value.playerCardGroupSets[facilityGroupingKey.value]?cargoData.value.playerCardGroupSets[facilityGroupingKey.value].sortings:[]),nextPlayerSorting=()=>{let group=cargoData.value.playerCardGroupSets[facilityGroupingKey.value];playerSortingKey.value=group[(group.indexOf(playerSortingKey.value)+1)%group.length]},currentFilterTutorialInfo=computed(()=>{if(!tutorialInfo.value||!selectedFilter.value)return null;let info=tutorialInfo.value[selectedFilter.value.value];return!info||!info.unlocked||!info.isActive?null:info}),openCargoScreenSettings=()=>{addPopup(CargoScreenSettings_default)},sortedParcelOffersByCargoType=computed(()=>{if(!cargoData.value||!cargoData.value.facility||!cargoData.value.facility.outgoingCargo)return{};let sorted={};for(let cargoType in _forEach(cargoData.value.facility.outgoingCargo,cargo=>{sorted[cargo.type]||(sorted[cargo.type]=[]),sorted[cargo.type].push(cargo)}),sorted)sorted[cargoType]=sortByProperty(sorted[cargoType]);return sorted}),sortedVehicleOffers=computed(()=>!cargoData.value||!cargoData.value.facility?[]:sortByProperty(cargoData.value.facility.vehicleOffers)),sortedTrailerOffers=computed(()=>!cargoData.value||!cargoData.value.facility?[]:sortByProperty(cargoData.value.facility.trailerOffers)),sortedAcceptedOffers=computed(()=>cargoData.value?sortByProperty(cargoData.value.player.acceptedOffers):[]),loanerOffers=computed(()=>{if(!cargoData.value||!cargoData.value.facility||!cargoData.value.facility.loanableVehicles)return[];let result=[];return result=result.concat(cargoData.value.facility.loanableVehicles),result}),menuClosed=()=>{cargoData.value=void 0,dropDownData.value={},selectedFilter.value=facilityFilter,selectedCargo.value=void 0,Lua_default.career_modules_delivery_cargoScreen.showCargoRoutePreview(void 0),loadingPrompt&&loadingPrompt.close(null)},requestCargoData=(_facilityId,_parkingSpotPath,updateMaxTimeStamp)=>{facilityId=_facilityId,parkingSpotPath=_parkingSpotPath,Lua_default.career_modules_delivery_cargoScreen.requestCargoDataForUi(facilityId,parkingSpotPath,updateMaxTimeStamp),updateMaxTimeStamp!=0&&(newCargoAvailable.value=!1)},requestCargoDataSimple=()=>{requestCargoData(facilityId,parkingSpotPath,!1)},moveCargoToLocation=(cargoId,targetLocation,skipRequest)=>{Lua_default.career_modules_delivery_cargoScreen.moveCargoFromUi(cargoId,targetLocation),skipRequest||requestCargoData(facilityId,parkingSpotPath,!1)},requestMoveCargoToLocation=(cargoId,moveData,skipRequest)=>{moveData.extraData?openThrowAwayPopup(cargoId,moveData.location,`Throw this cargo away with a `+moveData.extraData.penalty.toFixed(2)+` penalty?`):moveCargoToLocation(cargoId,moveData.location,skipRequest)};async function openThrowAwayPopup(cargoId,targetLocation,message){await openConfirmation(null,message)?moveCargoToLocation(cargoId,targetLocation):setCargoData()}let setCargoData=data=>{let previousCardId;if(selectedCargo.value&&(previousCardId=selectedCargo.value.cardId),data&&(cargoData.value=data),dropDownData.value={},cargoData.value.player&&cargoData.value.player.vehicles){getAutomaticRoute(data.settings.automaticRoute),getDetailedDropOff(data.settings.detailedDropOff),automaticRoute.value&&setAutomaticRoute(automaticRoute.value),filterSets.value=data.filterSets,filterSets.value.unshift(facilityFilter);for(let filter of filterSets.value)filterSetsByValue.value[filter.value]=filter;selectedFilter.value||=filterSets.value[0],previousCardId&&onCargoSelected(cargoData.value.cardsById[previousCardId]),tutorialInfo.value=data.tutorialInfo}},highlightedCards=ref({}),highlightCardIds=highlightedIdMap=>{highlightedCards.value=highlightedIdMap},focusedCargo=ref();ref();let selectedCargo=ref(),onCargoHovered=cargo=>{focusedCargo.value=cargo,highlightRoute(focusedCargo.value)},onCargoSelected=cargo=>{selectedCargo.value=cargo},highlightRoute=card=>{card?Lua_default.career_modules_delivery_cargoScreen.showRoutePreview(card.route):Lua_default.career_modules_delivery_cargoScreen.showRoutePreview(void 0)},setAutomaticRoute=(newValue,oldValue)=>{newValue!=oldValue&&Lua_default.career_modules_delivery_general.setAutomaticRoute(newValue)};watch(()=>automaticRoute.value,setAutomaticRoute);let getAutomaticRoute=enabled=>{automaticRoute.value=enabled};watch(()=>detailedDropOff.value,(newValue,oldValue)=>{newValue!=oldValue&&Lua_default.career_modules_delivery_general.setDetailedDropOff(newValue)});let getDetailedDropOff=enabled=>{detailedDropOff.value=enabled},setGroupingAndSorting=()=>{},cardClicked=card=>{switch(card.cardType){case`parcelGroup`:loadCargoAuto(card);break;case`vehicleOffer`:loadOffer(card);break;case`storage`:loadStorageCustom(card);break}},cardDeselect=()=>onCargoSelected(),cardHovered=card=>{onCargoHovered(card)},clearLoad=cargo=>{for(let id of cargo.ids)Lua_default.career_modules_delivery_cargoScreen.clearTransientMoveForCargo(id);requestCargoDataSimple()},throwAway=card=>{loadingPrompt=addPopup(CargoLoadPopup_default,{cargo:card,throwAway:!0}).promise},changeDistribution=cargo=>{for(let[id,card]of Object.entries(cargoData.value.cardsById))if(card.isFacilityCard&&card.cardType==`parcelGroup`&&card.ids.includes(cargo.ids[0])){loadCargoCustom(card);return}},modifyMaterialLoad=cargo=>{for(let[id,card]of Object.entries(cargoData.value.cardsById))if(card.isFacilityCard&&card.cardType==`storage`&&card.storage.materialType==cargo.materialType){loadStorageCustom(card);return}},loadCargoAuto=cargo=>{for(let id of cargo.ids)Lua_default.career_modules_delivery_cargoScreen.clearTransientMoveForCargo(id);let idx=0;for(let loc of cargo.autoLoadLocations)Lua_default.career_modules_delivery_cargoScreen.moveCargoFromUi(cargo.ids[idx],loc),idx++;requestCargoDataSimple()},loadingPrompt=null,loadCargoCustom=card=>{if(card.transientMove){let cargoId=card.ids[0];for(let[id,otherCard]of Object.entries(cargoData.value.cardsById))if(otherCard.isFacilityCard&&otherCard.cardType==`parcelGroup`&&otherCard.ids.includes(cargoId)){loadingPrompt=addPopup(CargoLoadPopup_default,{cargo:otherCard}).promise;return}}else loadingPrompt=addPopup(CargoLoadPopup_default,{cargo:card}).promise},loadStorageCustom=storageData=>{loadingPrompt=addPopup(CargoLoadPopup_default,{storageData}).promise},loadOffer=offer=>{Lua_default.career_modules_delivery_cargoScreen.toggleOfferForSpawning(offer.id),requestCargoDataSimple()},loadLoaner=offer=>{Lua_default.career_modules_loanerVehicles.markForSpawning(offer),requestCargoDataSimple()},returnLoaner=vehId=>{Lua_default.career_modules_loanerVehicles.returnVehicle(vehId).then(()=>{requestCargoDataSimple()})};async function abandonOffer(card){await openConfirmation(null,`Abandon `+card.name+`? There is a `+card.abandonInfo.penaltyMoney+`$ penalty.`)&&(Lua_default.career_modules_delivery_cargoScreen.abandonAcceptedOffer(card.abandonInfo.vehId),requestCargoDataSimple())}return events$3.on(`automaticRouteSet`,getAutomaticRoute),events$3.on(`cargoDataForUiReady`,setCargoData),events$3.on(`newCargoAvailable`,()=>newCargoAvailable.value=!0),events$3.on(`sendHighlightedCardIds`,highlightCardIds),events$3.on(`requestCargoDataSimple`,requestCargoDataSimple),{cargoData,tutorialInfo,sortedParcelOffersByCargoType,sortedVehicleOffers,sortedTrailerOffers,sortedAcceptedOffers,onCargoHovered,onCargoSelected,loanerOffers,dropDownData,newCargoAvailable,cargoHighlighted,automaticRoute,detailedDropOff,setGroupingAndSorting,requestCargoData,requestCargoDataSimple,requestMoveCargoToLocation,menuClosed,dispose:()=>{events$3.off(`cargoDataForUiReady`),events$3.off(`newCargoAvailable`),events$3.off(`sendHighlightedCardIds`),events$3.on(`requestCargoDataSimple`)},focusedCargo,selectedCargo,cardClicked,cardHovered,cardDeselect,clearLoad,changeDistribution,loadCargoAuto,loadCargoCustom,throwAway,loadStorageCustom,loadOffer,abandonOffer,loadLoaner,returnLoaner,modifyMaterialLoad,filterSets,filterSetsByValue,selectedFilterRef,selectedFilter,selectFilter,highlightedCards,openCargoScreenSettings,nextFacilityGrouping,nextFacilitySorting,nextPlayerGrouping,nextPlayerSorting,facilityGroupingKey,facilitySortingKey,playerGroupingKey,playerSortingKey,facilityGroupings,facilitySortings,playerGroupings,playerSortings,currentFilterTutorialInfo}});var _hoisted_1$229={class:`fill-panel`},_hoisted_2$187={key:1,class:`groupGrid`},_sfc_main$258={__name:`ProvidedOrdersPanel`,props:{groupSets:Object,groupIdx:[Number,String],sortingSets:Object,sortIdx:[Number,String],sortAsc:{type:Boolean,default:!0},ignoreFilter:Boolean},setup(__props){let cargoOverviewStore=useCargoOverviewStore(),props=__props;computed(()=>props.groupSets&&props.groupSets[props.groupIdx]&&props.groupSets[props.groupIdx].groups?props.groupSets[props.groupIdx].groups:[]);let sortedGroups=computed(()=>{let groupSet=props.groupSets[props.groupIdx];if(!cargoOverviewStore.cargoData||!cargoOverviewStore.cargoData.cardsById||!groupSet.groups||!groupSet.groups.length)return[];let groups=groupSet.groups,sortKey=props.sortingSets[props.sortIdx].key;function getHighestSortValue(group){let maxSortValue=-1/0;return group.cardIdsUnsorted&&group.cardIdsUnsorted.length&&group.cardIdsUnsorted.forEach(cardId=>{let card=cargoOverviewStore.cargoData.cardsById[cardId];if(card.filterTags[cargoOverviewStore.selectedFilter.value]||group.ignoreFilter||props.ignoreFilter){let sortValue=card.sortValues&&card.sortValues[sortKey]!==void 0?card.sortValues[sortKey]:1/0;sortValue>maxSortValue&&(maxSortValue=sortValue)}}),maxSortValue}return groups.sort((a$1,b)=>{let minValueA=getHighestSortValue(a$1),minValueB=getHighestSortValue(b);return props.sortAsc?minValueA-minValueB:minValueB-minValueA}),groups}),getSortedCardIds=group=>{if(!cargoOverviewStore.cargoData||!cargoOverviewStore.cargoData.cardsById||!group.cardIdsUnsorted)return[];let cardsById=cargoOverviewStore.cargoData.cardsById,sortKey=props.sortingSets[props.sortIdx].key;return group.cardIdsUnsorted&&group.cardIdsUnsorted.length?group.cardIdsUnsorted.slice().sort((a$1,b)=>{let cardA=cardsById[a$1],cardB=cardsById[b],valueA=cardA&&cardA.sortValues&&cardA.sortValues[sortKey]!==void 0?cardA.sortValues[sortKey]:0,valueB=cardB&&cardB.sortValues&&cardB.sortValues[sortKey]!==void 0?cardB.sortValues[sortKey]:0;return props.sortAsc?valueA-valueB:valueB-valueA}):[]};return(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$229,[unref(cargoOverviewStore).cargoData?unref(cargoOverviewStore).cargoData.cardsById?(openBlock(),createElementBlock(`div`,_hoisted_2$187,[(openBlock(!0),createElementBlock(Fragment,null,renderList(sortedGroups.value,group=>(openBlock(),createElementBlock(Fragment,{key:group.label},[(group.cardIdsUnsorted.length>0||group.showEmpty)&&(group.filterTags[unref(cargoOverviewStore).selectedFilter.value]||group.ignoreFilter||__props.ignoreFilter)?(openBlock(),createBlock(CardGroup_default,{key:0,label:group.label,meta:group.meta},{default:withCtx(()=>[(openBlock(!0),createElementBlock(Fragment,null,renderList(getSortedCardIds(group),cardId=>(openBlock(),createElementBlock(Fragment,{key:cardId},[unref(cargoOverviewStore).cargoData.cardsById[cardId].filterTags[unref(cargoOverviewStore).selectedFilter.value]||group.ignoreFilter||__props.ignoreFilter?(openBlock(),createBlock(CargoCard_default,{key:0,card:unref(cargoOverviewStore).cargoData.cardsById[cardId],onClick:withModifiers($event=>unref(cargoOverviewStore).onCargoSelected(unref(cargoOverviewStore).cargoData.cardsById[cardId]),[`stop`]),onMouseover:$event=>unref(cargoOverviewStore).onCargoHovered(unref(cargoOverviewStore).cargoData.cardsById[cardId]),onMouseleave:_cache[0]||=$event=>unref(cargoOverviewStore).onCargoHovered(),hideProps:__props.groupSets[__props.groupIdx].hideProps,hideModsAndTimer:__props.groupSets[__props.groupIdx].hideModsAndTimer},null,8,[`card`,`onClick`,`onMouseover`,`hideProps`,`hideModsAndTimer`])):createCommentVNode(``,!0)],64))),128))]),_:2},1032,[`label`,`meta`])):createCommentVNode(``,!0)],64))),128))])):createCommentVNode(``,!0):(openBlock(),createElementBlock(Fragment,{key:0},[createTextVNode(` No data yet... `)],64))]))}},ProvidedOrdersPanel_default=__plugin_vue_export_helper_default(_sfc_main$258,[[`__scopeId`,`data-v-877d97e8`]]),_hoisted_1$228={class:`header-text`},_hoisted_2$186={key:0,class:`disabled-reason noOffers`},_sfc_main$257={__name:`FilterCard`,props:{filter:Object},setup(__props){let props=__props,cargoOverviewStore=useCargoOverviewStore(),disabled=computed(()=>{if(props.filter){if(!props.filter.hasAvailableOffers)return{disabled:!0};if(props.filter.unavailableAtThisFacility)return{disabled:!0,reason:`Unavailable`};if(props.filter.lockedInfo)return{disabled:!0,reason:props.filter.lockedInfo.shortLabel}}return{disabled:!1}});return onMounted(()=>{}),(_ctx,_cache)=>(openBlock(),createBlock(unref(bngCard_default),{class:normalizeClass([`filterCard`,{disabled:disabled.value.disabled}]),onClick:_cache[0]||=withModifiers($event=>unref(cargoOverviewStore).selectFilter([__props.filter.value]),[`stop`])},{default:withCtx(()=>[createVNode(unref(bngCardHeading_default),{class:`card-heading`},{default:withCtx(()=>[createBaseVNode(`span`,_hoisted_1$228,toDisplayString(__props.filter.label),1)]),_:1}),createVNode(unref(aspectRatio_default),{class:`image`,ratio:`8:3`},{default:withCtx(()=>[createVNode(unref(bngIcon_default),{class:`glyph`,type:unref(icons)[__props.filter.icon]},null,8,[`type`]),createBaseVNode(`div`,{class:normalizeClass([`step`,{none:__props.filter.facilityCards===0}])},[createVNode(unref(bngPropVal_default),{class:`amount-avail`,valueLabel:`× `+__props.filter.facilityCards},null,8,[`valueLabel`])],2)]),_:1}),disabled.value.reason?(openBlock(),createElementBlock(`div`,_hoisted_2$186,[createVNode(unref(bngPropVal_default),{class:`amount-avail`,iconType:unref(icons).lockClosed,valueLabel:disabled.value.reason},null,8,[`iconType`,`valueLabel`])])):createCommentVNode(``,!0)]),_:1},8,[`class`]))}},FilterCard_default=__plugin_vue_export_helper_default(_sfc_main$257,[[`__scopeId`,`data-v-85dcf2d5`]]),_hoisted_1$227={key:0,class:`heading-container`},_hoisted_2$185={class:`status-add`},_hoisted_3$163={class:`controls-row`},_hoisted_4$136={key:1,class:`content-container`},_hoisted_5$119={class:`header-container`},_hoisted_6$102={class:`info-line`},_hoisted_7$89={class:`header-flex padding`},_hoisted_8$74={class:`groupSortButtons`},_hoisted_9$67={class:`scroll-panel`},_hoisted_10$58={key:0,class:`tasklist`},_hoisted_11$52={class:`tasklist-header`},_hoisted_12$41={class:`task-content`},_hoisted_13$34={class:`heading`},_hoisted_14$32={class:`description`},_hoisted_15$31={key:1,class:`empty-cargo-card`},_hoisted_16$31={class:`header-container`},_hoisted_17$25={class:`header-flex`},_hoisted_18$22={key:0,class:`map-overlay`},_hoisted_19$19={key:1,class:`empty-cargo-card`},_hoisted_20$16={class:`header-container`},_hoisted_21$15={class:`info-line`},_hoisted_22$13={class:`header-flex wrap padding`},_hoisted_23$12={class:`groupSortButtons`},_hoisted_24$11={class:`cargohold-info`},_hoisted_25$10={class:`scroll-panel padding`},_hoisted_26$8={class:`content`},_hoisted_27$8={key:0,class:`buttons-wrapper`},_hoisted_28$7={class:`content flex-container`},_hoisted_29$7={key:1,class:`header-flex progress-bar-padding`},_hoisted_30$7={key:0,class:`progress-bar-wrapper wide`},_hoisted_31$7=[`innerHTML`],_hoisted_32$7={class:`info-right`},_hoisted_33$7={key:0},_hoisted_34$7={key:0,class:`header-flex progress-bar-padding`},_hoisted_35$6={class:`progress-bar-wrapper wide`},_hoisted_36$6={class:`content`},_hoisted_37$5={class:`filterSelectGrid`},_sfc_main$256={__name:`CargoOverviewMain`,props:{facilityId:String,parkingSpotPath:String},setup(__props){let tabPills=ref();useUINavScope(`delivery`);let props=__props,cargoOverviewStore=useCargoOverviewStore();async function openDiscardPopup(){await openConfirmation(null,`Discard Changes?`)&&(Lua_default.career_modules_delivery_cargoScreen.cancelDeliveryConfiguration(),Lua_default.career_modules_delivery_cargoScreen.exitCargoOverviewScreen(),window.bngVue.gotoGameState(`play`))}let close=()=>{cargoOverviewStore.cargoData.confirmButtonInfo.itemCount>0&&props.facilityId?openDiscardPopup():(Lua_default.career_modules_delivery_cargoScreen.exitCargoOverviewScreen(),window.bngVue.gotoGameState(`play`))},acceptLoad=()=>{Lua_default.career_modules_delivery_cargoScreen.commitDeliveryConfiguration(),Lua_default.career_modules_delivery_cargoScreen.exitCargoOverviewScreen(),window.bngVue.gotoGameState(`play`)};async function openExitModePopup(){await openConfirmation(null,`Throw away all cargo and exit delivery mode?`)&&(Lua_default.career_modules_delivery_cargoScreen.exitDeliveryMode(),Lua_default.career_modules_delivery_cargoScreen.exitCargoOverviewScreen(),window.bngVue.gotoGameState(`play`))}let exitMode=()=>{openExitModePopup()};async function gotoSkillProgress(panel){cargoOverviewStore.cargoData.confirmButtonInfo.itemCount>0||window.bngVue.gotoGameState(`branchPage`,{params:{branchKey:panel.branchId,skillKey:panel.skillId}})}async function gotoOrganizations(id){cargoOverviewStore.cargoData.confirmButtonInfo.itemCount>0||window.bngVue.gotoGameState(`organizations`,{params:{orgId:id}})}let facilitySortAsc=ref(!1),playerSortAsc=ref(!0),activePopovers={},popShown=pop=>nextTick(()=>activePopovers[pop.name]=pop),popHidden=pop=>nextTick(()=>delete activePopovers[pop.name]);function popHideAll(){for(let pop of Object.values(activePopovers))pop.hide()}let screenCover=ref(),mapPanel=ref(null),observer$2,mapClipChanged;function resizer(){let elScreen=screenCover.value?.$el||screenCover.value;if(!mapPanel.value||!elScreen){mapClipChanged&&(mapClipChanged=!1,screenCover.value.style.setProperty(`--map-clip`,`unset`));return}let pad=3,{width:width$1,height:height$1}=elScreen.getBoundingClientRect(),rect=mapPanel.value.getBoundingClientRect(),percentile=[(rect.x+3)/width$1,(rect.y+3)/height$1,(rect.x+rect.width-3)/width$1,(rect.y+rect.height-3)/height$1].map(n=>`${n*100}%`);elScreen.style.setProperty(`--map-clip`,`polygon(0% 0%, 100% 0%, 100% 100%, 0% 100%, 0% 0%, ${percentile[0]} ${percentile[1]}, ${percentile[0]} ${percentile[3]}, ${percentile[2]} ${percentile[3]}, ${percentile[2]} ${percentile[1]}, ${percentile[0]} ${percentile[1]})`),mapClipChanged=!0,Lua_default.freeroam_bigMapMode.setBigmapScreenBounds({width:width$1,height:height$1},rect)}watch(()=>mapPanel.value,(elm,prev)=>{prev&&observer$2.unobserve(prev),elm&&observer$2.observe(elm)},{immediate:!0}),watch(()=>cargoOverviewStore.selectedFilter?.isFacilityPage,()=>nextTick(resizer));let selectedFilters=ref([]);return watch(()=>cargoOverviewStore.selectedFilter,filter=>{selectedFilters.value=[filter.value],cargoOverviewStore.focusedCargo=null}),onMounted(()=>{observer$2=new ResizeObserver(resizer),resizer(),cargoOverviewStore.requestCargoData(props.facilityId,props.parkingSpotPath),selectedFilters.value=[cargoOverviewStore.selectedFilter.value]}),onBeforeUnmount(()=>{observer$2?.disconnect()}),onUnmounted(()=>{Lua_default.career_modules_delivery_cargoScreen.exitCargoOverviewScreen(),cargoOverviewStore.menuClosed()}),(_ctx,_cache)=>(openBlock(),createBlock(unref(layoutSingle_default),{class:`cargo-overview-main-layout`,"bng-ui-scope":`delivery`,ref_key:`screenCover`,ref:screenCover},{default:withCtx(()=>[createBaseVNode(`div`,{class:`screen`,onClick:_cache[10]||=$event=>unref(cargoOverviewStore).cardDeselect(),onClickCapture:popHideAll},[unref(cargoOverviewStore).cargoData?(openBlock(),createElementBlock(`div`,_hoisted_1$227,[createVNode(unref(bngScreenHeading_default),{preheadings:[`Delivery Mode`],divider:``},{default:withCtx(()=>[createTextVNode(toDisplayString(unref(cargoOverviewStore).cargoData.facility?unref(cargoOverviewStore).cargoData.facility.name:`My Cargo`),1)]),_:1}),createVNode(unref(bngCard_default),{class:`status-container`},{default:withCtx(()=>[createVNode(unref(careerStatus_default)),createBaseVNode(`div`,_hoisted_2$185,[(openBlock(!0),createElementBlock(Fragment,null,renderList(unref(cargoOverviewStore).cargoData.skillLevels,(skill,index)=>(openBlock(),createBlock(unref(bngPropVal_default),{key:index,iconType:unref(icons)[skill.icon],valueLabel:_ctx.$ctx_t(skill.levelLabel)},null,8,[`iconType`,`valueLabel`]))),128)),unref(cargoOverviewStore).cargoData.facility&&unref(cargoOverviewStore).cargoData.facility.organization?(openBlock(),createBlock(unref(bngPropVal_default),{key:0,iconType:unref(icons).peopleOutline,valueLabel:_ctx.$ctx_t(unref(cargoOverviewStore).cargoData.facility.organization.reputation.label)},null,8,[`iconType`,`valueLabel`])):createCommentVNode(``,!0)])]),_:1})])):createCommentVNode(``,!0),createBaseVNode(`div`,_hoisted_3$163,[withDirectives((openBlock(),createBlock(unref(bngButton_default),{class:`back-button`,accent:unref(ACCENTS).attention,onClick:close},{default:withCtx(()=>[createVNode(unref(bngBinding_default),{"ui-event":`back`,deviceMask:`xinput`}),createTextVNode(` `+toDisplayString(_ctx.$t(`ui.common.close`)),1)]),_:1},8,[`accent`])),[[unref(BngOnUiNav_default),void 0,`back,menu`,{asMouse:!0}]]),unref(cargoOverviewStore).cargoData&&unref(cargoOverviewStore).filterSets&&__props.facilityId?(openBlock(),createBlock(unref(bngPillFilters_default),{key:0,ref_key:`tabPills`,ref:tabPills,required:``,modelValue:selectedFilters.value,"onUpdate:modelValue":_cache[0]||=$event=>selectedFilters.value=$event,options:unref(cargoOverviewStore).filterSets,onValueChanged:unref(cargoOverviewStore).selectFilter},null,8,[`modelValue`,`options`,`onValueChanged`])):createCommentVNode(``,!0),!__props.facilityId&&unref(cargoOverviewStore).cargoData&&unref(cargoOverviewStore).cargoData.player.penaltyForAbandon.money<0?(openBlock(),createBlock(unref(bngButton_default),{key:1,accent:`attention`,iconLeft:unref(icons).trashBin1,onClick:exitMode,class:`right-button`},{default:withCtx(()=>[..._cache[11]||=[createTextVNode(` Abandon all deliveries `,-1)]]),_:1},8,[`iconLeft`])):createCommentVNode(``,!0)]),unref(cargoOverviewStore).cargoData?(openBlock(),createElementBlock(`div`,_hoisted_4$136,[!unref(cargoOverviewStore).selectedFilter.isFacilityPage||!__props.facilityId?(openBlock(),createElementBlock(`div`,{key:0,class:normalizeClass([`panel-flex`,{reverse:!__props.facilityId}])},[__props.facilityId?(openBlock(),createBlock(unref(bngCard_default),{key:0,class:`content-row provided-orders-panel`},{default:withCtx(()=>[createBaseVNode(`div`,_hoisted_5$119,[unref(cargoOverviewStore).selectedFilter?(openBlock(),createBlock(unref(bngCardHeading_default),{key:0,type:`ribbon`,class:`cardHeadingFlex wide`},{default:withCtx(()=>[createBaseVNode(`span`,null,toDisplayString(unref(cargoOverviewStore).selectedFilter.label),1),unref(cargoOverviewStore).selectedFilter.howTo?(openBlock(),createBlock(TutorialButton_default,{key:0,class:`howto-button right`,accent:`secondary`,icon:unref(icons).help,pages:unref(cargoOverviewStore).selectedFilter.howTo.pages},null,8,[`icon`,`pages`])):createCommentVNode(``,!0)]),_:1})):createCommentVNode(``,!0),createBaseVNode(`div`,_hoisted_6$102,[createVNode(unref(bngIcon_default),{type:unref(icons).info},null,8,[`type`]),createBaseVNode(`span`,null,toDisplayString(unref(cargoOverviewStore).selectedFilter.shortDescription),1)]),createBaseVNode(`div`,_hoisted_7$89,[withDirectives((openBlock(),createBlock(unref(bngButton_default),{class:`groupSortButton`,accent:unref(ACCENTS).text,icon:unref(icons).group,onClick:_cache[1]||=withModifiers(()=>{},[`stop`])},{default:withCtx(()=>[createTextVNode(` Grouping: `+toDisplayString(unref(cargoOverviewStore).cargoData.facilityCardGroupSets[unref(cargoOverviewStore).facilityGroupingKey].label),1)]),_:1},8,[`accent`,`icon`])),[[unref(BngPopover_default),`facility-grouping`,`bottom`,{click:!0}]]),createVNode(unref(bngPopoverMenu_default),{name:`facility-grouping`,focus:``,onShow:popShown,onHide:popHidden},{default:withCtx(({hide:hide$2})=>[(openBlock(!0),createElementBlock(Fragment,null,renderList(unref(cargoOverviewStore).facilityGroupings,key=>withDirectives((openBlock(),createBlock(unref(bngButton_default),{key,accent:unref(ACCENTS).menu,class:normalizeClass({selected:unref(cargoOverviewStore).facilityGroupingKey===key}),onClick:withModifiers(()=>{unref(cargoOverviewStore).facilityGroupingKey=key,hide$2()},[`stop`])},{default:withCtx(()=>[createTextVNode(toDisplayString(unref(cargoOverviewStore).cargoData.facilityCardGroupSets[key].label),1)]),_:2},1032,[`accent`,`class`,`onClick`])),[[unref(BngOnUiNav_default),void 0,`ok`,{focusRequired:!0,asMouse:!0}]])),128))]),_:1}),createBaseVNode(`div`,_hoisted_8$74,[withDirectives((openBlock(),createBlock(unref(bngButton_default),{class:`groupSortButton`,accent:unref(ACCENTS).text,icon:unref(icons).order,onClick:_cache[2]||=withModifiers(()=>{},[`stop`])},{default:withCtx(()=>[createTextVNode(` Sorting: `+toDisplayString(unref(cargoOverviewStore).cargoData.sortingSets[unref(cargoOverviewStore).facilitySortingKey].label),1)]),_:1},8,[`accent`,`icon`])),[[unref(BngPopover_default),`facility-sorting`,`bottom`,{click:!0}]]),withDirectives(createVNode(unref(bngButton_default),{class:`groupSortButtonSmall`,accent:unref(ACCENTS).text,icon:facilitySortAsc.value?unref(icons).sortAsc:unref(icons).sortDesc,onClick:_cache[3]||=withModifiers($event=>facilitySortAsc.value=!facilitySortAsc.value,[`stop`])},null,8,[`accent`,`icon`]),[[unref(BngTooltip_default),facilitySortAsc.value?`Ascending order`:`Descending order`,`top`]])]),createVNode(unref(bngPopoverMenu_default),{name:`facility-sorting`,focus:``,onShow:popShown,onHide:popHidden},{default:withCtx(({hide:hide$2})=>[(openBlock(!0),createElementBlock(Fragment,null,renderList(unref(cargoOverviewStore).facilitySortings,key=>withDirectives((openBlock(),createBlock(unref(bngButton_default),{key,accent:unref(ACCENTS).menu,class:normalizeClass({selected:unref(cargoOverviewStore).facilitySortingKey===key}),onClick:()=>{unref(cargoOverviewStore).facilitySortingKey=key,hide$2()}},{default:withCtx(()=>[createTextVNode(toDisplayString(unref(cargoOverviewStore).cargoData.sortingSets[key].label),1)]),_:2},1032,[`accent`,`class`,`onClick`])),[[unref(BngOnUiNav_default),void 0,`ok`,{focusRequired:!0,asMouse:!0}]])),128))]),_:1})])]),_cache[12]||=createBaseVNode(`div`,{class:`separator`},null,-1),createBaseVNode(`div`,_hoisted_9$67,[unref(cargoOverviewStore).currentFilterTutorialInfo?.tasks?(openBlock(),createElementBlock(`div`,_hoisted_10$58,[createBaseVNode(`div`,_hoisted_11$52,toDisplayString(unref(cargoOverviewStore).selectedFilter.label)+` Tutorial `,1),(openBlock(!0),createElementBlock(Fragment,null,renderList(unref(cargoOverviewStore).currentFilterTutorialInfo.tasks,task=>(openBlock(),createElementBlock(`div`,{class:`task`,key:task.label},[createVNode(unref(bngIcon_default),{class:`icon`,type:unref(icons)[task.done?`checkboxOn`:`checkboxOff`]},null,8,[`type`]),createBaseVNode(`div`,_hoisted_12$41,[createBaseVNode(`div`,_hoisted_13$34,toDisplayString(task.label),1),createBaseVNode(`div`,_hoisted_14$32,toDisplayString(task.description),1)])]))),128))])):createCommentVNode(``,!0),createVNode(ProvidedOrdersPanel_default,{groupSets:unref(cargoOverviewStore).cargoData.facilityCardGroupSets,groupIdx:unref(cargoOverviewStore).facilityGroupingKey,sortingSets:unref(cargoOverviewStore).cargoData.sortingSets,sortIdx:unref(cargoOverviewStore).facilitySortingKey,sortAsc:facilitySortAsc.value,onCardHovered:unref(cargoOverviewStore).cardHovered,onCardClicked:unref(cargoOverviewStore).cardClicked},null,8,[`groupSets`,`groupIdx`,`sortingSets`,`sortIdx`,`sortAsc`,`onCardHovered`,`onCardClicked`])])]),_:1})):createCommentVNode(``,!0),createBaseVNode(`div`,{class:normalizeClass([`content-row selected-and-map-panel`,{wide:!__props.facilityId}])},[__props.facilityId?(openBlock(),createBlock(unref(bngCard_default),{key:0,class:`cargo-detail`},{default:withCtx(()=>[unref(cargoOverviewStore).focusedCargo||unref(cargoOverviewStore).selectedCargo?(openBlock(),createBlock(CargoCard_default,{key:0,card:unref(cargoOverviewStore).focusedCargo||unref(cargoOverviewStore).selectedCargo,detailed:``,"show-buttons":!unref(cargoOverviewStore).focusedCargo&&unref(cargoOverviewStore).selectedCargo||unref(cargoOverviewStore).focusedCargo===unref(cargoOverviewStore).selectedCargo},null,8,[`card`,`show-buttons`])):(openBlock(),createElementBlock(`div`,_hoisted_15$31,`Select a card to view details.`))]),_:1})):createCommentVNode(``,!0),createBaseVNode(`div`,{class:`map`,ref_key:`mapPanel`,ref:mapPanel},[createBaseVNode(`div`,_hoisted_16$31,[createBaseVNode(`div`,_hoisted_17$25,[createVNode(unref(bngCardHeading_default),{type:`ribbon`,class:`cardHeading wide`},{default:withCtx(()=>[createTextVNode(toDisplayString(_ctx.$t(unref(cargoOverviewStore).cargoData.levelInfo.name)),1)]),_:1}),createVNode(unref(bngSwitch_default),{modelValue:unref(cargoOverviewStore).automaticRoute,"onUpdate:modelValue":_cache[4]||=$event=>unref(cargoOverviewStore).automaticRoute=$event,onClick:_cache[5]||=withModifiers(()=>{},[`stop`])},{default:withCtx(()=>[..._cache[13]||=[createTextVNode(` Automatic route `,-1)]]),_:1},8,[`modelValue`])])]),__props.facilityId?createCommentVNode(``,!0):(openBlock(),createElementBlock(`div`,_hoisted_18$22,[createVNode(unref(bngCard_default),{class:`cargo-detail`},{default:withCtx(()=>[unref(cargoOverviewStore).focusedCargo||unref(cargoOverviewStore).selectedCargo?(openBlock(),createBlock(CargoCard_default,{key:0,card:unref(cargoOverviewStore).focusedCargo||unref(cargoOverviewStore).selectedCargo,detailed:``,"show-buttons":!unref(cargoOverviewStore).focusedCargo&&unref(cargoOverviewStore).selectedCargo||unref(cargoOverviewStore).focusedCargo===unref(cargoOverviewStore).selectedCargo},null,8,[`card`,`show-buttons`])):(openBlock(),createElementBlock(`div`,_hoisted_19$19,` Select a card to view details. `))]),_:1})]))],512)],2),createVNode(unref(bngCard_default),{class:`content-row my-cargo-panel`},{default:withCtx(()=>[createBaseVNode(`div`,_hoisted_20$16,[createVNode(unref(bngCardHeading_default),{type:`ribbon`,class:`cardHeadingFlex wide`},{default:withCtx(()=>[_cache[14]||=createBaseVNode(`span`,null,`My Cargo`,-1),createVNode(TutorialButton_default,{class:`howto-button right`,accent:`secondary`,icon:unref(icons).help,pages:[`delivery/myCargo`,`delivery/parcelDelivery`]},null,8,[`icon`])]),_:1}),createBaseVNode(`div`,_hoisted_21$15,[createVNode(unref(bngIcon_default),{type:unref(icons).info},null,8,[`type`]),_cache[15]||=createBaseVNode(`span`,null,`Check your loaded cargo and other delivery-related tasks.`,-1)]),createBaseVNode(`div`,_hoisted_22$13,[withDirectives((openBlock(),createBlock(unref(bngButton_default),{class:`groupSortButton`,accent:unref(ACCENTS).text,icon:unref(icons).group,onClick:_cache[6]||=withModifiers(()=>{},[`stop`])},{default:withCtx(()=>[createTextVNode(` Grouping: `+toDisplayString(unref(cargoOverviewStore).cargoData.playerCardGroupSets[unref(cargoOverviewStore).playerGroupingKey].label),1)]),_:1},8,[`accent`,`icon`])),[[unref(BngPopover_default),`player-grouping`,`bottom`,{click:!0}]]),createVNode(unref(bngPopoverMenu_default),{name:`player-grouping`,focus:``,onShow:popShown,onHide:popHidden},{default:withCtx(({hide:hide$2})=>[(openBlock(!0),createElementBlock(Fragment,null,renderList(unref(cargoOverviewStore).playerGroupings,key=>withDirectives((openBlock(),createBlock(unref(bngButton_default),{key,accent:unref(ACCENTS).menu,class:normalizeClass({selected:unref(cargoOverviewStore).playerGroupingKey===key}),onClick:()=>{unref(cargoOverviewStore).playerGroupingKey=key,hide$2()}},{default:withCtx(()=>[createTextVNode(toDisplayString(unref(cargoOverviewStore).cargoData.playerCardGroupSets[key].label),1)]),_:2},1032,[`accent`,`class`,`onClick`])),[[unref(BngOnUiNav_default),void 0,`ok`,{focusRequired:!0,asMouse:!0}]])),128))]),_:1}),createBaseVNode(`div`,_hoisted_23$12,[withDirectives((openBlock(),createBlock(unref(bngButton_default),{class:`groupSortButton`,accent:unref(ACCENTS).text,icon:unref(icons).order,onClick:_cache[7]||=withModifiers(()=>{},[`stop`])},{default:withCtx(()=>[createTextVNode(` Sorting: `+toDisplayString(unref(cargoOverviewStore).cargoData.sortingSets[unref(cargoOverviewStore).playerSortingKey].label),1)]),_:1},8,[`accent`,`icon`])),[[unref(BngPopover_default),`player-sorting`,`bottom`,{click:!0}]]),withDirectives(createVNode(unref(bngButton_default),{class:`groupSortButtonSmall`,accent:unref(ACCENTS).text,icon:playerSortAsc.value?unref(icons).sortAsc:unref(icons).sortDesc,onClick:_cache[8]||=withModifiers($event=>playerSortAsc.value=!playerSortAsc.value,[`stop`])},null,8,[`accent`,`icon`]),[[unref(BngTooltip_default),playerSortAsc.value?`Ascending order`:`Descending order`,`top`]])]),createVNode(unref(bngPopoverMenu_default),{name:`player-sorting`,focus:``,onShow:popShown,onHide:popHidden},{default:withCtx(({hide:hide$2})=>[(openBlock(!0),createElementBlock(Fragment,null,renderList(unref(cargoOverviewStore).playerSortings,key=>withDirectives((openBlock(),createBlock(unref(bngButton_default),{key,accent:unref(ACCENTS).menu,class:normalizeClass({selected:unref(cargoOverviewStore).playerSortingKey===key}),onClick:withModifiers(()=>{unref(cargoOverviewStore).playerSortingKey=key,hide$2()},[`stop`])},{default:withCtx(()=>[createTextVNode(toDisplayString(unref(cargoOverviewStore).cargoData.sortingSets[key].label),1)]),_:2},1032,[`accent`,`class`,`onClick`])),[[unref(BngOnUiNav_default),void 0,`ok`,{focusRequired:!0,asMouse:!0}]])),128))]),_:1}),createBaseVNode(`div`,_hoisted_24$11,[(openBlock(!0),createElementBlock(Fragment,null,renderList(unref(cargoOverviewStore).cargoData.playerCardGroupSets.totalStorages.groups,(group,index)=>(openBlock(),createElementBlock(Fragment,{key:index},[group.meta.totalCargoSlots?(openBlock(),createBlock(CargoInfo_default,{key:0,class:`info-with-gradient`,meta:group.meta},null,8,[`meta`])):createCommentVNode(``,!0)],64))),128))])])]),_cache[17]||=createBaseVNode(`div`,{class:`separator`},null,-1),createBaseVNode(`div`,_hoisted_25$10,[unref(cargoOverviewStore).selectedFilter.noContainers?(openBlock(),createBlock(unref(bngCard_default),{key:0,class:`no-container-card`},{default:withCtx(()=>[createBaseVNode(`div`,_hoisted_26$8,[createBaseVNode(`span`,null,[createVNode(unref(bngIcon_default),{type:unref(icons).info},null,8,[`type`]),_cache[16]||=createTextVNode(` You do not have any containers installed that can load this type of cargo. `,-1)]),createVNode(TutorialButton_default,{class:`button`,accent:`secondary`,icon:unref(icons).help,pages:[`delivery/cargoContainerHowTo`],text:`How do I install cargo containers?`},null,8,[`icon`])])]),_:1})):createCommentVNode(``,!0),createVNode(ProvidedOrdersPanel_default,{groupSets:unref(cargoOverviewStore).cargoData.playerCardGroupSets,groupIdx:unref(cargoOverviewStore).playerGroupingKey,sortingSets:unref(cargoOverviewStore).cargoData.sortingSets,sortIdx:unref(cargoOverviewStore).playerSortingKey,sortAsc:playerSortAsc.value,ignoreFilter:!0,onCardHovered:unref(cargoOverviewStore).cardHovered,onCardClicked:unref(cargoOverviewStore).cardClicked},null,8,[`groupSets`,`groupIdx`,`sortingSets`,`sortIdx`,`sortAsc`,`onCardHovered`,`onCardClicked`])]),unref(cargoOverviewStore).cargoData&&__props.facilityId?(openBlock(),createElementBlock(`div`,_hoisted_27$8,[unref(cargoOverviewStore).cargoData.confirmButtonInfo.itemCount>0?(openBlock(),createBlock(unref(bngButton_default),{key:0,class:`accept-button`,icon:unref(icons).checkmark,onClick:withModifiers(acceptLoad,[`stop`])},{default:withCtx(()=>[createTextVNode(` Continue (`+toDisplayString(unref(cargoOverviewStore).cargoData.confirmButtonInfo.itemCount)+` items) `,1)]),_:1},8,[`icon`])):createCommentVNode(``,!0)])):createCommentVNode(``,!0)]),_:1})],2)):(openBlock(),createBlock(unref(bngCard_default),{key:1,class:`detailedFilterSelector`},{default:withCtx(()=>[createBaseVNode(`div`,_hoisted_28$7,[createVNode(unref(bngCard_default),{class:`info-left`},{default:withCtx(()=>[unref(cargoOverviewStore).cargoData.facility.organization?(openBlock(),createBlock(unref(bngCardHeading_default),{key:0,type:`ribbon`,class:`cardHeadingFlex`},{default:withCtx(()=>[createBaseVNode(`span`,null,[_cache[18]||=createBaseVNode(`span`,null,`Reputation:\xA0`,-1),createBaseVNode(`span`,null,toDisplayString(unref(cargoOverviewStore).cargoData.facility.organization.reputation.label+` (lvl `+unref(cargoOverviewStore).cargoData.facility.organization.reputation.level+`)`),1)]),createVNode(unref(bngButton_default),{icon:unref(icons).signal05a,accent:`secondary`,onClick:_cache[9]||=$event=>gotoOrganizations(unref(cargoOverviewStore).cargoData.facility.organization.id)},{default:withCtx(()=>[..._cache[19]||=[createTextVNode(`Progress`,-1)]]),_:1},8,[`icon`])]),_:1})):createCommentVNode(``,!0),unref(cargoOverviewStore).cargoData.facility.organization?(openBlock(),createElementBlock(`div`,_hoisted_29$7,[createVNode(unref(bngIcon_default),{class:`progress-icon`,type:unref(icons).peopleOutline},null,8,[`type`]),unref(cargoOverviewStore).cargoData.facility.organization?(openBlock(),createElementBlock(`div`,_hoisted_30$7,[createVNode(unref(bngProgressBar_default),{class:`bar`,gradient:``,value:unref(cargoOverviewStore).cargoData.facility.organization.reputation.value,max:unref(cargoOverviewStore).cargoData.facility.organization.reputation.nextThreshold,min:unref(cargoOverviewStore).cargoData.facility.organization.prevThreshold,showValueLabel:!1},null,8,[`value`,`max`,`min`])])):createCommentVNode(``,!0)])):createCommentVNode(``,!0),createVNode(unref(aspectRatio_default),{class:`image`,ratio:`5:3`,"external-image":unref(cargoOverviewStore).cargoData.facility.preview},null,8,[`external-image`]),createVNode(unref(bngCardHeading_default),{type:`ribbon`,class:`cardHeading`},{default:withCtx(()=>[..._cache[20]||=[createTextVNode(` Facility Information `,-1)]]),_:1}),createBaseVNode(`div`,{class:`content text-justify`,innerHTML:unref(content_exports).bbcode.parse(unref(cargoOverviewStore).cargoData.facility.longDescription)},null,8,_hoisted_31$7)]),_:1}),createBaseVNode(`div`,_hoisted_32$7,[(openBlock(!0),createElementBlock(Fragment,null,renderList(unref(cargoOverviewStore).cargoData.facilityPanels,(panel,index)=>(openBlock(),createBlock(unref(bngCard_default),{key:index,class:`panel`},{default:withCtx(()=>[createVNode(unref(bngCardHeading_default),{type:`ribbon`,class:`cardHeadingFlex`},{default:withCtx(()=>[createBaseVNode(`span`,null,[createBaseVNode(`span`,null,toDisplayString(panel.heading)+`:\xA0`,1),panel.skillInfo?(openBlock(),createElementBlock(`span`,_hoisted_33$7,toDisplayString(panel.skillInfo.unlocked?_ctx.$ctx_t(panel.skillInfo.levelLabel):``),1)):createCommentVNode(``,!0)]),panel.skillInfo?(openBlock(),createBlock(unref(bngButton_default),{key:0,icon:unref(icons).signal05a,accent:`secondary`,onClick:$event=>gotoSkillProgress(panel)},{default:withCtx(()=>[..._cache[21]||=[createTextVNode(`Progress`,-1)]]),_:1},8,[`icon`,`onClick`])):createCommentVNode(``,!0)]),_:2},1024),panel.skillInfo?(openBlock(),createElementBlock(`div`,_hoisted_34$7,[createVNode(unref(bngIcon_default),{class:`progress-icon`,type:unref(icons)[panel.skillInfo.icon]},null,8,[`type`]),createBaseVNode(`div`,_hoisted_35$6,[createVNode(unref(bngProgressBar_default),{class:`bar`,gradient:``,value:panel.skillInfo.max==-1?1:panel.skillInfo.value-panel.skillInfo.min,max:panel.skillInfo.max==-1?1:panel.skillInfo.max-panel.skillInfo.min,showValueLabel:!0,valueLabelFormat:panel.skillInfo.max===-1?`Max`:panel.skillInfo.value+` XP`},null,8,[`value`,`max`,`valueLabelFormat`])])])):createCommentVNode(``,!0),createBaseVNode(`div`,_hoisted_36$6,[createBaseVNode(`span`,null,[createVNode(unref(bngIcon_default),{type:unref(icons).info},null,8,[`type`]),createTextVNode(` `+toDisplayString(panel.description),1)]),createBaseVNode(`div`,_hoisted_37$5,[(openBlock(!0),createElementBlock(Fragment,null,renderList(panel.filterValueButtons,filterKey=>(openBlock(),createBlock(FilterCard_default,{key:filterKey,filter:unref(cargoOverviewStore).filterSetsByValue[filterKey]},null,8,[`filter`]))),128))])])]),_:2},1024))),128))])])]),_:1}))])):createCommentVNode(``,!0)],32)]),_:1},512))}},CargoOverviewMain_default=__plugin_vue_export_helper_default(_sfc_main$256,[[`__scopeId`,`data-v-719883ab`]]),_hoisted_1$226={class:`unlock-wrapper`,"bng-ui-scope":`cargoUnlockPopup`},_hoisted_2$184={class:`cardContent`},_hoisted_3$162={class:`acceptButton`},__default__$1={wrapper:{fade:!0,blur:!0,style:popupContainer.default},position:[popupPosition.center,popupPosition.center]},_sfc_main$255=Object.assign(__default__$1,{__name:`UnlockPopup`,props:{reward:Object},emits:[`return`],setup(__props,{emit:__emit}){useUINavScope(`cargoUnlockPopup`);let emit$1=__emit,acceptClickHandler=()=>{emit$1(`return`,!0)};return(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$226,[createVNode(unref(bngCard_default),null,{default:withCtx(()=>[createVNode(unref(bngCardHeading_default),{type:`ribbon`},{default:withCtx(()=>[..._cache[0]||=[createTextVNode(` Level Up! `,-1)]]),_:1}),createBaseVNode(`div`,_hoisted_2$184,[createBaseVNode(`h3`,null,toDisplayString(__props.reward.unlockPopupHeader),1),_cache[2]||=createTextVNode(` Unlocks: `,-1),(openBlock(!0),createElementBlock(Fragment,null,renderList(__props.reward.branchLevels[__props.reward.animationData.level-1].unlocks,item=>(openBlock(),createBlock(UnlockCard_default,{class:`tier-unlocks-item`,data:item},null,8,[`data`]))),256)),createBaseVNode(`div`,_hoisted_3$162,[withDirectives((openBlock(),createBlock(unref(bngButton_default),{accent:unref(ACCENTS).primary,onClick:acceptClickHandler},{default:withCtx(()=>[createVNode(unref(bngBinding_default),{"ui-event":`ok`,deviceMask:`xinput`}),_cache[1]||=createBaseVNode(`span`,null,`Continue`,-1)]),_:1},8,[`accent`])),[[unref(BngOnUiNav_default),acceptClickHandler,`ok`]])])])]),_:1})]))}}),UnlockPopup_default=__plugin_vue_export_helper_default(_sfc_main$255,[[`__scopeId`,`data-v-127ed650`]]),_hoisted_1$225={class:`reward-wrapper`},_hoisted_2$183={class:`card-content`},_hoisted_3$161={class:`scroll-wrapper`},_hoisted_4$135={key:0},_hoisted_5$118={class:`cargo-wrapper`},_hoisted_6$101={class:`header`},_hoisted_7$88={class:`amount-controls`},_hoisted_8$73={class:`amount`},_hoisted_9$66={class:`card-content`},_hoisted_10$57={style:{display:`flex`}},_hoisted_11$51={style:{float:`left`}},_hoisted_12$40={key:0,class:`rewards-breakdown-container padding-bottom`},_hoisted_13$33={class:`grid-wrapper`},_hoisted_14$31={class:`grid-row grid`},_hoisted_15$30={class:`label primary`},_hoisted_16$30={class:`rewards primary`},_hoisted_17$24={class:`grid-wrapper wide`},_hoisted_18$21={class:`grid`},_hoisted_19$18={class:`label secondary`},_hoisted_20$15={class:`rewards secondary`},_hoisted_21$14={class:`grid-row grid`},_hoisted_22$12={class:`rewards primary`},_hoisted_23$11={key:1,class:`rewards-breakdown-container padding-bottom`},_hoisted_24$10={class:`grid-wrapper`},_hoisted_25$9={key:0,class:`grid-row grid`},_hoisted_26$7={class:`rewards primary`},_hoisted_27$7={key:1,class:`grid-row grid`},_hoisted_28$6={class:`rewards primary`},_hoisted_29$6={key:2,class:`grid-row grid`},_hoisted_30$6={class:`rewards primary`},_hoisted_31$6={key:3,class:`grid-row grid`},_hoisted_32$6={class:`rewards primary`},_hoisted_33$6={class:`grid-row grid`},_hoisted_34$6={class:`rewards primary`},_hoisted_35$5={style:{float:`left`}},_hoisted_36$5={key:0,style:{float:`left`}},_hoisted_37$4={key:0,class:`numberReward`},_hoisted_38$4={key:1,class:`numberReward`},_hoisted_39$4={key:2},_hoisted_40$3={key:1,style:{float:`left`,width:`100%`,padding:`0.2em`}},_hoisted_41$3={key:2},__default__={wrapper:{fade:!0,blur:!0,style:popupContainer.transparent},position:[popupPosition.center,popupPosition.center]},_sfc_main$254=Object.assign(__default__,{__name:`CargoDropOff`,props:{facilityId:String,parkingSpotPath:String},setup(__props){let ANIMATION_START_DELAY=400,ANIMATION_DURATION=3e3,ANIMATION_UPDATE_RATE=30,BAR_COLOR_DEFAULT=`#ff6600`,BAR_COLOR_ADDITION=`#ff6600`,BAR_COLOR_SUBTRACTION=`#c00000`,MODES={wait:`wait`,cargoSelection:`cargoSelection`,results:`results`},cargoOverviewStore=useCargoOverviewStore();useUINavScope(`cargoDropOff`);let props=__props,{events:events$3}=useBridge(),mode=ref(MODES.wait),data=ref({}),summary=ref([]),showConfirmDelay=ref(!1),confirmButtonEnabled=ref(!1),confirmButtonTimer=ref(0),confirmButtonTimerId=0,rewardAnimationIndex=ref(-1),animationSkipped=!1,showUnloadingDelay=!0,getLevelFromValue=(value,reward)=>{let branchLevels=reward.branchLevels,levelIndex=-1;for(let i=0;i=levelData.requiredValue&&(levelIndex=i)}let maxLevel=!(branchLevels[levelIndex+1]&&branchLevels[levelIndex+1].requiredValue!=null),displayValue=value-branchLevels[levelIndex].requiredValue;return{min:0,max:maxLevel?displayValue:branchLevels[levelIndex+1].requiredValue-branchLevels[levelIndex].requiredValue,displayValue,levelLabel:reward.type==`reputation`?branchLevels[levelIndex].label+` (Level `+(levelIndex-1)+`)`:branchLevels[levelIndex].levelLabel,level:levelIndex+1,maxLevel}},confirm=()=>{rewardAnimationIndex.value<0?confirmButtonEnabled.value&&confirmDropOff():skipAnimations()},getDeliveryList=()=>summary.value.detailledList.map(delivery=>delivery.label).join(`, `),getNiceTime=()=>confirmButtonTimer.value>0?confirmButtonTimer.value.toFixed(1)+`s remaining...`:`Done!`,exit=()=>{window.bngVue.gotoGameState(`play`)};function updateDisplayValue(reward){if(reward.branchLevels&&reward.branchLevels.length){let displayData=getLevelFromValue(reward.animationData.smoothedValue,reward);reward.animationData.max=displayData.max,reward.animationData.displayValue=displayData.displayValue,reward.animationData.levelLabel=displayData.levelLabel,reward.animationData.level=displayData.level,reward.animationData.maxLevel=displayData.maxLevel;let displayDataBefore=getLevelFromValue(reward.animationData.value-reward.rewardAmount,reward);displayData.level==displayDataBefore.level?(reward.animationData.displayValueBefore=displayDataBefore.displayValue,displayData.displayValue>=displayDataBefore.displayValue?(reward.valueColor=BAR_COLOR_ADDITION,reward.valueBeforeColor=BAR_COLOR_DEFAULT):(reward.valueBeforeColor=BAR_COLOR_SUBTRACTION,reward.valueColor=BAR_COLOR_DEFAULT)):displayData.level>displayDataBefore.level?(reward.animationData.displayValueBefore=0,reward.valueColor=BAR_COLOR_ADDITION,reward.valueBeforeColor=BAR_COLOR_DEFAULT):(reward.animationData.displayValueBefore=displayData.max,reward.valueColor=BAR_COLOR_DEFAULT,reward.valueBeforeColor=BAR_COLOR_SUBTRACTION)}}let startSmoothingValue=(reward,duration)=>{reward.animationData.numStep=(reward.animationData.value-reward.animationData.smoothedValue)/duration*30,clearInterval(reward.animationData.numTimer),reward.animationData.numTimer=setInterval(()=>{reward.animationData.smoothedValue+=reward.animationData.numStep,(reward.animationData.numStep>0?reward.animationData.smoothedValue>=reward.animationData.value:reward.animationData.smoothedValue<=reward.animationData.value)&&(Lua_default.career_modules_delivery_progress.activateSound(``,!1),reward.animationData.smoothedValue=reward.animationData.value,reward.animationData.numStep=0,clearInterval(reward.animationData.numTimer)),reward.highlight=reward.animationData.numStep!=0,updateDisplayValue(reward)},30)};async function openNewLevelPopup(reward){Lua_default.Engine.Audio.playOnce(`AudioGui`,`event:>UI>Career>Progress_LevelUp`),await addPopup(UnlockPopup_default,{reward}).promise,startProgressBarAnimation()}function didPlayerLevelUp(reward){let levelBefore=0,levelAfter=0;return reward.branchLevels&&reward.branchLevels.length&&(levelBefore=getLevelFromValue(reward.animationData.value-reward.rewardAmount,reward).level,levelAfter=getLevelFromValue(reward.animationData.value,reward).level),levelBeforeopenNewLevelPopup(reward),duration):setTimeout(startProgressBarAnimation,duration+400);return}rewardAnimationIndex.value=-1}}let start=()=>{getUINavServiceInstance().activate(),getUINavServiceInstance().clearFilteredEvents(),Lua_default.career_modules_delivery_general.setDeliveryTimePaused(!0),Lua_default.career_modules_delivery_cargoScreen.requestDropOffData(props.facilityId,props.parkingSpotPath)},kill=()=>{Lua_default.career_modules_delivery_general.setDeliveryTimePaused(!1),events$3.off(`SetDeliveryDropOffCargoSelection`),events$3.off(`SetDeliveryDropOffRewardResult`),clearInterval(confirmButtonTimerId),Lua_default.career_modules_delivery_cargoScreen.dropOffPopupClosed(mode.value)},confirmSelection=()=>{let confirmedCargoIds=[];data.value.customAmountPerMaterialType.forEach(info=>{info.items.forEach(item=>{item.amountSelector>0&&confirmedCargoIds.push({id:item.ids[0],amount:item.amountSelector})})});let confirmedDropOffs={confirmedCargoIds,confirmedOfferIds:[]};console.log(confirmedDropOffs),Lua_default.career_modules_delivery_cargoScreen.confirmDropOffData(confirmedDropOffs,props.facilityId,props.parkingSpotPath)},confirmDropOff=()=>{exit()},branchInfo;function rewardMapToRewardList(rewards){let newRewards=[];for(let key in rewards){let rewardInfo={attributeKey:key,rewardAmount:rewards[key],order:branchInfo[key].order,animationData:branchInfo[key].animationData,branchLevels:branchInfo[key].branchLevels,showLevelUpPopup:branchInfo[key].showLevelUpPopup,unlockPopupHeader:branchInfo[key].unlockPopupHeader,type:branchInfo[key].type};branchInfo[key].icon&&(rewardInfo.icon=branchInfo[key].icon),newRewards.push(rewardInfo)}return newRewards.sort((a$1,b)=>a$1.order-b.order),newRewards}let cargoBySummaryId=[],calculateSummary=()=>{let simpleBreakdownRewardsByType={base:[],bonus:[],loaner:[],branch:[]};summary.value={detailledList:[],total:{label:`Total`,rewards:{}}};let totalRewards={};for(let id in cargoBySummaryId){let group=cargoBySummaryId[id],first=group.list[0],totalCount=0;for(let cargo of group.list)totalCount+=1;let sum={label:first.name,rewards:rewardMapToRewardList(first.originalRewards),breakdown:[]};for(let i=0;i0&&summary.value.detailledList.push(sum)}if(data.value.rewardOffers.length)for(let veh of data.value.rewardOffers){let sum={label:veh.offer.name,rewards:rewardMapToRewardList(veh.originalRewards),breakdown:[]};if(simpleBreakdownRewardsByType.base.push(veh.originalRewards),veh.breakdown.length)for(let bd of veh.breakdown)sum.breakdown.push({label:bd.label,rewards:rewardMapToRewardList(bd.rewards)}),bd.simpleBreakdownType&&(simpleBreakdownRewardsByType[bd.simpleBreakdownType]||(simpleBreakdownRewardsByType[bd.simpleBreakdownType]=[]),simpleBreakdownRewardsByType[bd.simpleBreakdownType].push(bd.rewards));summary.value.detailledList.push(sum)}for(let type in simpleBreakdownRewardsByType){let sum={};for(let elem of simpleBreakdownRewardsByType[type])for(let attKey in elem)sum[attKey]||(sum[attKey]=0),sum[attKey]+=elem[attKey];simpleBreakdownRewardsByType[type]=rewardMapToRewardList(sum)}summary.value.simpleBreakdown=simpleBreakdownRewardsByType;for(let row of summary.value.detailledList){for(let elem of row.rewards)totalRewards[elem.attributeKey]||(totalRewards[elem.attributeKey]=0),totalRewards[elem.attributeKey]+=elem.rewardAmount;for(let bd of row.breakdown)for(let elem of bd.rewards)totalRewards[elem.attributeKey]||(totalRewards[elem.attributeKey]=0),totalRewards[elem.attributeKey]+=elem.rewardAmount}summary.value.total.rewards=rewardMapToRewardList(totalRewards);let counter$1=0;for(let reward of summary.value.total.rewards)reward.animationData.id!=`missing`&&(reward.animationOrderIndex=counter$1,reward.animationData.smoothedValue=reward.animationData.value-reward.rewardAmount,reward.animationData.numStep=0,reward.highlight=!1,updateDisplayValue(reward),counter$1++);rewardAnimationIndex.value=-1,animationSkipped=!1};events$3.on(`SetDeliveryDropOffCargoSelection`,dd=>{data.value=dd,mode.value=MODES.cargoSelection,branchInfo=dd.branchInfo,showUnloadingDelay=dd.unloadingDelay>.1,data.value.playerVehicleData.length&&data.value.customAmountPerMaterialType.forEach(info=>{let remainingFreeAmount=info.storage.capacity-info.storage.storedVolume;info.items.sort((a$1,b)=>a$1.slots-b.slots),info.items.forEach(item=>{item.amountSelectorPerSlot=item.type===`fluid`||item.type===`dryBulk`,item.maxCount=item.ids.length,item.amountSelectorPerSlot&&(item.maxCount=item.slots),item.amountSelector=ref(Math.max(0,Math.min(item.maxCount,remainingFreeAmount))),remainingFreeAmount-=item.amountSelector,item.showAmountSelector=!0,item.loadSliderMax=Math.min(item.maxCount,info.storage.capacity-info.storage.storedVolume)}),info.meta={type:`container`,usedCargoSlots:info.storage.storedVolume,totalCargoSlots:info.storage.capacity,fillPercent:info.storage.storedVolume/info.storage.capacity,icon:info.material.icon},info.meta.usedCargoSlots=info.storage.storedVolume,info.items.forEach(item=>{info.meta.usedCargoSlots+=item.amountSelector}),info.meta.fillPercentHighlight=info.meta.usedCargoSlots/info.storage.capacity,info.storage.capacity<=info.storage.storedVolume&&(info.isFull=!0)})});let updateSliderAmounts=(info,changedItem)=>{info.meta.usedCargoSlots=info.storage.storedVolume,info.items.forEach(item=>{info.meta.usedCargoSlots+=item.amountSelector});let tooMuch=info.meta.usedCargoSlots-info.meta.totalCargoSlots;tooMuch>0&&(info.items.reverse(),info.items.forEach(item=>{if(item!==changedItem){let before=item.amountSelector;item.amountSelector=Math.max(0,item.amountSelector-tooMuch);let diff=item.amountSelector-before;tooMuch+=diff}}),info.items.reverse()),info.meta.usedCargoSlots=info.storage.storedVolume,info.items.forEach(item=>{info.meta.usedCargoSlots+=item.amountSelector}),info.meta.fillPercentHighlight=info.meta.usedCargoSlots/info.storage.capacity};return events$3.on(`SetDeliveryDropOffRewardResult`,dd=>{if(console.log(`setDropOffRewardResult`,dd),data.value=dd,branchInfo=dd.branchInfo,mode.value=MODES.results,confirmButtonEnabled.value=!0,showConfirmDelay.value=!1,dd.unloadingDelay>.1){confirmButtonEnabled.value=!1,confirmButtonTimer.value=dd.unloadingDelay,showConfirmDelay.value=!0;let endTime=Date.now()+confirmButtonTimer.value*1e3,countdown=()=>{let timeLeft=(endTime-Date.now())/1e3;timeLeft>0?(confirmButtonTimer.value=timeLeft,confirmButtonTimerId=requestAnimationFrame(countdown)):(confirmButtonTimer.value=0,confirmButtonEnabled.value=!0)};confirmButtonTimerId=requestAnimationFrame(countdown),showUnloadingDelay=!0}else showUnloadingDelay=!1;if(dd.rewardParcels.length)for(let cargo of dd.rewardParcels)cargoBySummaryId[cargo.summaryId]||(cargoBySummaryId[cargo.summaryId]={list:[],display:{}}),cargoBySummaryId[cargo.summaryId].list.push(cargo);calculateSummary(),setTimeout(startProgressBarAnimation,400)}),onMounted(start),onUnmounted(kill),(_ctx,_cache)=>mode.value===MODES.wait?createCommentVNode(``,!0):withDirectives((openBlock(),createBlock(unref(layoutSingle_default),{key:0,class:`cargo-drop-off-wrapper`,"bng-ui-scope":`cargoDropOff`},{default:withCtx(()=>[createBaseVNode(`div`,_hoisted_1$225,[mode.value===MODES.cargoSelection?(openBlock(),createBlock(unref(bngCard_default),{key:0},{buttons:withCtx(()=>[createVNode(unref(bngButton_default),{onClick:confirmSelection},{default:withCtx(()=>[createVNode(unref(bngBinding_default),{"ui-event":`ok`,deviceMask:`xinput`}),_cache[4]||=createBaseVNode(`span`,null,`Confirm Selection`,-1)]),_:1})]),default:withCtx(()=>[createVNode(unref(careerStatus_default),{class:`career-status`}),createVNode(unref(bngCardHeading_default),{type:`ribbon`},{default:withCtx(()=>[..._cache[3]||=[createTextVNode(`Dropping off...`,-1)]]),_:1}),createBaseVNode(`div`,_hoisted_2$183,[createVNode(unref(bngPropVal_default),{class:`limited-capacity-info`,valueLabel:`This facility has limited capacity for cargo.`,iconType:unref(icons).info},null,8,[`iconType`]),createBaseVNode(`div`,_hoisted_3$161,[(openBlock(!0),createElementBlock(Fragment,null,renderList(data.value.customAmountPerMaterialType,info=>(openBlock(),createBlock(CardGroup_default,{class:`fullwidth-group`,label:info.material.name,meta:info.meta},{default:withCtx(()=>[info.isFull?(openBlock(),createElementBlock(`div`,_hoisted_4$135,[createVNode(unref(bngPropVal_default),{valueLabel:`The storage for this material is completely filled. Come back later.`,iconType:unref(icons).abandon},null,8,[`iconType`])])):createCommentVNode(``,!0),(openBlock(!0),createElementBlock(Fragment,null,renderList(info.items,item=>(openBlock(),createElementBlock(`div`,_hoisted_5$118,[createBaseVNode(`div`,_hoisted_6$101,[createVNode(unref(bngPropVal_default),{valueLabel:item.originName,keyLabel:`Origin`,iconType:unref(icons).locationSource},null,8,[`valueLabel`,`iconType`]),createVNode(unref(bngPropVal_default),{valueLabel:item.containerName,keyLabel:`Container`,iconType:unref(icons).cardboardBox},null,8,[`valueLabel`,`iconType`])]),createBaseVNode(`div`,_hoisted_7$88,[createVNode(unref(bngButton_default),{disabled:info.isFull,class:`less`,iconLeft:unref(icons).minus,accent:`text`,onClick:_cache[0]||=$event=>_ctx.less(_ctx.target)},null,8,[`disabled`,`iconLeft`]),createVNode(unref(bngSlider_default),{disabled:info.isFull,class:`slider`,min:0,max:item.loadSliderMax,modelValue:item.amountSelector,"onUpdate:modelValue":$event=>item.amountSelector=$event,step:1,onChange:$event=>updateSliderAmounts(info,item)},null,8,[`disabled`,`max`,`modelValue`,`onUpdate:modelValue`,`onChange`]),createVNode(unref(bngButton_default),{disabled:info.isFull,class:`more`,iconLeft:unref(icons).plus,accent:`text`,onClick:_cache[1]||=$event=>_ctx.more(_ctx.target)},null,8,[`disabled`,`iconLeft`]),createBaseVNode(`div`,_hoisted_8$73,toDisplayString(item.amountSelector)+` / `+toDisplayString(item.slots),1)])]))),256))]),_:2},1032,[`label`,`meta`]))),256))])])]),_:1})):createCommentVNode(``,!0),mode.value===MODES.results?(openBlock(),createBlock(unref(bngCard_default),{key:1},{buttons:withCtx(()=>[withDirectives((openBlock(),createBlock(unref(bngButton_default),{disabled:rewardAnimationIndex.value<0&&!confirmButtonEnabled.value,onClick:confirm},{default:withCtx(()=>[createVNode(unref(bngBinding_default),{deviceMask:`xinput`}),createBaseVNode(`span`,null,toDisplayString(rewardAnimationIndex.value<0?`Continue`:`Skip`),1)]),_:1},8,[`disabled`])),[[unref(BngFocusIf_default),rewardAnimationIndex.value==0]])]),default:withCtx(()=>[createVNode(unref(bngCardHeading_default),{type:`ribbon`},{default:withCtx(()=>[..._cache[5]||=[createTextVNode(`Delivery Complete!`,-1)]]),_:1}),createBaseVNode(`div`,_hoisted_9$66,[createBaseVNode(`div`,_hoisted_10$57,[createBaseVNode(`h3`,_hoisted_11$51,`Delivered: `+toDisplayString(getDeliveryList()),1),summary.value.detailledList.length>1?(openBlock(),createBlock(unref(bngSwitch_default),{key:0,style:{float:`right`},modelValue:unref(cargoOverviewStore).detailedDropOff,"onUpdate:modelValue":_cache[2]||=$event=>unref(cargoOverviewStore).detailedDropOff=$event},{default:withCtx(()=>[..._cache[6]||=[createTextVNode(`Detailed`,-1)]]),_:1},8,[`modelValue`])):createCommentVNode(``,!0)]),summary.value.detailledList.length<=1||unref(cargoOverviewStore).detailedDropOff?(openBlock(),createElementBlock(`div`,_hoisted_12$40,[createBaseVNode(`div`,_hoisted_13$33,[(openBlock(!0),createElementBlock(Fragment,null,renderList(summary.value.detailledList,result=>(openBlock(),createElementBlock(`div`,_hoisted_14$31,[createBaseVNode(`div`,_hoisted_15$30,toDisplayString(result.label),1),createBaseVNode(`div`,_hoisted_16$30,[createVNode(RewardsPills_default,{rewards:result.rewards},null,8,[`rewards`])]),createBaseVNode(`div`,_hoisted_17$24,[(openBlock(!0),createElementBlock(Fragment,null,renderList(result.breakdown,breakdown=>(openBlock(),createElementBlock(`div`,_hoisted_18$21,[createBaseVNode(`div`,_hoisted_19$18,toDisplayString(breakdown.label),1),createBaseVNode(`div`,_hoisted_20$15,[createVNode(RewardsPills_default,{rewards:breakdown.rewards},null,8,[`rewards`])])]))),256))])]))),256)),createVNode(unref(bngDivider_default)),createBaseVNode(`div`,_hoisted_21$14,[_cache[7]||=createBaseVNode(`div`,{class:`label primary`},`Summary`,-1),createBaseVNode(`div`,_hoisted_22$12,[createVNode(RewardsPills_default,{rewards:summary.value.total.rewards},null,8,[`rewards`])])])])])):(openBlock(),createElementBlock(`div`,_hoisted_23$11,[createBaseVNode(`div`,_hoisted_24$10,[summary.value.simpleBreakdown.base.length?(openBlock(),createElementBlock(`div`,_hoisted_25$9,[_cache[8]||=createBaseVNode(`div`,{class:`label primary`},`Base Rewards`,-1),createBaseVNode(`div`,_hoisted_26$7,[createVNode(RewardsPills_default,{rewards:summary.value.simpleBreakdown.base},null,8,[`rewards`])])])):createCommentVNode(``,!0),summary.value.simpleBreakdown.bonus.length?(openBlock(),createElementBlock(`div`,_hoisted_27$7,[_cache[9]||=createBaseVNode(`div`,{class:`label primary`},`Bonuses`,-1),createBaseVNode(`div`,_hoisted_28$6,[createVNode(RewardsPills_default,{rewards:summary.value.simpleBreakdown.bonus},null,8,[`rewards`])])])):createCommentVNode(``,!0),summary.value.simpleBreakdown.loaner.length?(openBlock(),createElementBlock(`div`,_hoisted_29$6,[_cache[10]||=createBaseVNode(`div`,{class:`label primary`},`Loaner Cuts`,-1),createBaseVNode(`div`,_hoisted_30$6,[createVNode(RewardsPills_default,{rewards:summary.value.simpleBreakdown.loaner},null,8,[`rewards`])])])):createCommentVNode(``,!0),summary.value.simpleBreakdown.branch.length?(openBlock(),createElementBlock(`div`,_hoisted_31$6,[_cache[11]||=createBaseVNode(`div`,{class:`label primary`},`Logistics Level Multiplier`,-1),createBaseVNode(`div`,_hoisted_32$6,[createVNode(RewardsPills_default,{rewards:summary.value.simpleBreakdown.branch},null,8,[`rewards`])])])):createCommentVNode(``,!0),createVNode(unref(bngDivider_default)),createBaseVNode(`div`,_hoisted_33$6,[_cache[12]||=createBaseVNode(`div`,{class:`label primary`},`Summary`,-1),createBaseVNode(`div`,_hoisted_34$6,[createVNode(RewardsPills_default,{rewards:summary.value.total.rewards},null,8,[`rewards`])])])])])),(openBlock(!0),createElementBlock(Fragment,null,renderList(summary.value.total.rewards,reward=>(openBlock(),createElementBlock(`div`,null,[reward.animationData.id==`missing`?createCommentVNode(``,!0):(openBlock(),createElementBlock(`div`,{key:0,class:normalizeClass(reward.animationData.numStep==0?``:`animate-progress-background`),style:{display:`flex`,"padding-bottom":`0.5em`,"padding-left":`0.2em`,"padding-right":`0.2em`}},[createBaseVNode(`div`,_hoisted_35$5,[reward.icon?(openBlock(),createBlock(unref(bngIcon_default),{key:0,style:{"padding-top":`0.5em`,"padding-right":`0.3em`},type:unref(icons)[reward.icon]},null,8,[`type`])):createCommentVNode(``,!0)]),reward.animationData.type==`number`?(openBlock(),createElementBlock(`div`,_hoisted_36$5,[reward.attributeKey==`money`?(openBlock(),createElementBlock(`div`,_hoisted_37$4,[createVNode(unref(bngUnit_default),{money:reward.animationData.smoothedValue,"no-icon":``},null,8,[`money`])])):reward.attributeKey==`beamXP`?(openBlock(),createElementBlock(`div`,_hoisted_38$4,[createVNode(unref(bngUnit_default),{beamXP:reward.animationData.smoothedValue,"no-icon":``},null,8,[`beamXP`])])):(openBlock(),createElementBlock(`div`,_hoisted_39$4,toDisplayString(reward.animationData.smoothedValue.toFixed(2)),1))])):(openBlock(),createElementBlock(`div`,_hoisted_40$3,[createVNode(unref(bngProgressBar_default),{headerLeft:_ctx.$t(reward.animationData.name),headerRight:reward.animationData.levelLabel,value:~~reward.animationData.displayValue,"old-value":~~reward.animationData.displayValueBefore,max:reward.animationData.max,showValueLabel:!0,valueColor:reward.valueColor,oldValueColor:reward.valueBeforeColor,valueLabelFormat:reward.animationData.maxLevel?~~reward.animationData.displayValue+`\xA0XP`:`#value#\xA0XP`,"animate-difference":!0},null,8,[`headerLeft`,`headerRight`,`value`,`old-value`,`max`,`valueColor`,`oldValueColor`,`valueLabelFormat`])]))],2))]))),256)),unref(showUnloadingDelay)?(openBlock(),createElementBlock(`div`,_hoisted_41$3,[createVNode(unref(bngDivider_default)),_cache[13]||=createTextVNode(` Unloading Delay `,-1),createVNode(unref(bngProgressBar_default),{class:`timer`,value:data.value.unloadingDelay-confirmButtonTimer.value,max:data.value.unloadingDelay,min:0,valueLabelFormat:getNiceTime()},null,8,[`value`,`max`,`valueLabelFormat`])])):createCommentVNode(``,!0)])]),_:1})):createCommentVNode(``,!0)])]),_:1})),[[unref(BngBlur_default)],[unref(BngOnUiNav_default),confirm,`back,menu`]])}}),CargoDropOff_default=__plugin_vue_export_helper_default(_sfc_main$254,[[`__scopeId`,`data-v-698d9552`]]);const useComputerStore=defineStore(`computer`,()=>{let computerData=ref({}),activeVehicleIndex=ref(0),activeInventoryId=computed(()=>computerData.value.vehicles&&computerData.value.vehicles[activeVehicleIndex.value]?computerData.value.vehicles[activeVehicleIndex.value].inventoryId:`0`),generalComputerFunctions=computed(()=>{if(!computerData.value.computerFunctions)return[];let result=[];return result=Object.values(computerData.value.computerFunctions.general),result.sort((a$1,b)=>a$1.order!=null&&b.order!=null?a$1.order{if(!computerData.value.computerFunctions)return{};let result={};for(let[inventoryId,computerFunctions]of Object.entries(computerData.value.computerFunctions.vehicleSpecific)){let sortedFunctions=Object.values(computerFunctions);sortedFunctions.sort((a$1,b)=>a$1.order!=null&&b.order!=null?a$1.order{computerData.value=data,(computerData.value.vehicles&&computerData.value.vehicles.length<=activeVehicleIndex.value||computerData.value.resetActiveVehicleIndex)&&(activeVehicleIndex.value=0)};return{activeVehicleIndex,activeInventoryId,computerData,generalComputerFunctions,vehicleSpecificComputerFunctions,requestComputerData:()=>{Lua_default.career_modules_computer.getComputerUIData().then(setComputerData)},computerButtonCallback:async(computerFunctionId,inventoryId)=>{await Lua_default.career_modules_computer.computerButtonCallback(computerFunctionId,inventoryId?Number(inventoryId):void 0)},switchActiveVehicle:offset$2=>{activeVehicleIndex.value=(activeVehicleIndex.value+offset$2+computerData.value.vehicles.length)%computerData.value.vehicles.length},onMenuClosed:()=>{Lua_default.career_modules_computer.onMenuClosed()}}});var _hoisted_1$224={class:`task-header`},_hoisted_2$182={class:`description`},_sfc_main$253={__name:`TaskHeader`,props:{title:[String,Object],description:[String,Object]},setup(__props){let props=__props,slots=useSlots(),titleParsed=computed(()=>parse$1($translate.contextTranslate(props.title,!0))),descriptionParsed=computed(()=>parse$1($translate.contextTranslate(props.description)));return(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$224,[createBaseVNode(`div`,null,[unref(slots).title?renderSlot(_ctx.$slots,`title`,{key:0},void 0,!0):__props.title?(openBlock(),createBlock(unref(dynamicComponent_default),{key:1,template:titleParsed.value},null,8,[`template`])):createCommentVNode(``,!0)]),createBaseVNode(`div`,_hoisted_2$182,[unref(slots).description?renderSlot(_ctx.$slots,`description`,{key:0},void 0,!0):__props.description?(openBlock(),createBlock(unref(dynamicComponent_default),{key:1,template:descriptionParsed.value},null,8,[`template`])):createCommentVNode(``,!0)])]))}},TaskHeader_default=__plugin_vue_export_helper_default(_sfc_main$253,[[`__scopeId`,`data-v-ae9fa7fe`]]),_hoisted_1$223={class:`task-message`},_hoisted_2$181={class:`label`},_hoisted_3$160={class:`description`},_sfc_main$252={__name:`TaskMessage`,props:{label:String,description:String},setup(__props){let props=__props,slots=useSlots(),labelParsed=computed(()=>parse$1($translate.contextTranslate(props.label,!0))),descriptionParsed=computed(()=>parse$1($translate.contextTranslate(props.description)));return(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$223,[createBaseVNode(`div`,_hoisted_2$181,[unref(slots).label?renderSlot(_ctx.$slots,`label`,{key:0},void 0,!0):__props.label?(openBlock(),createBlock(unref(dynamicComponent_default),{key:1,template:labelParsed.value},null,8,[`template`])):createCommentVNode(``,!0)]),createBaseVNode(`div`,_hoisted_3$160,[unref(slots).description?renderSlot(_ctx.$slots,`description`,{key:0},void 0,!0):__props.description?(openBlock(),createBlock(unref(dynamicComponent_default),{key:1,template:descriptionParsed.value},null,8,[`template`])):createCommentVNode(``,!0)])]))}},TaskMessage_default=__plugin_vue_export_helper_default(_sfc_main$252,[[`__scopeId`,`data-v-657447b0`]]),_hoisted_1$222=[`data-id`],_sfc_main$251={__name:`TaskList`,props:{header:Object,tasks:Array,settings:{type:Object,default:{animate:!1,animateOnMount:!1,animateOnMountIntervalDelay:.2,animateOnEmpty:!1,animateOnEmptyIntervalDelay:.2,animateNextTask:!1,taskCompleteCallback:{type:Function,required:!1}}}},setup(__props){let props=__props,animationSettings=inject(`animationSettings`,props.settings),previousTasks=ref(null),internalTasks=ref(null),tasksScroller=ref(null),canAnimate=computed(()=>!(!animationSettings.animate||previousTasks.value===null&&!animationSettings.animateOnMount)),nextTask=computed(()=>internalTasks.value.find(x=>x.type===`goal`&&!x.complete&&x.attention)),onBeforeHeaderLeave=el=>{el.style.animationDelay=`0s`},onBeforeLeave=(el,done)=>{el.style.animationDelay=`0s`},onBeforeEnterTask=el=>{let dataId=el.getAttribute(`data-id`),offset$2=props.header?1:0,delay=previousTasks.value===null||previousTasks.value.length===0?animationSettings.animateOnMountIntervalDelay*(Number(dataId)+offset$2):0;el.style.animationDelay=delay+`s`,requestAnimationFrame(()=>{tasksScroller.value&&(tasksScroller.value.scrollTop=tasksScroller.value.scrollHeight)})};onBeforeMount(()=>{(!internalTasks.value||internalTasks.value.length===0)&&(internalTasks.value=unwrapProxy(props.tasks))}),watch(()=>props.tasks,async(newValue,oldValue)=>{internalTasks.value!==null&&(previousTasks.value=internalTasks.value&&internalTasks.value.length>0?unwrapProxy([...internalTasks.value]):[]),internalTasks.value=unwrapProxy(props.tasks)},{deep:!0});function unwrapProxy(reactiveList){return reactiveList.map(x=>Object.assign({},x))}return(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,{class:normalizeClass([`tasks-container`,{animate:unref(animationSettings).animate}])},[createVNode(Transition,{"enter-active-class":`show`,"leave-active-class":`remove`,css:unref(animationSettings).animate,onBeforeLeave:onBeforeHeaderLeave},{default:withCtx(()=>[__props.header?(openBlock(),createElementBlock(`div`,{key:0,class:normalizeClass([`header-wrapper`,{"show-animate":canAnimate.value}])},[createVNode(TaskHeader_default,mergeProps(__props.header,{class:`header`}),null,16)],2)):createCommentVNode(``,!0)]),_:1},8,[`css`]),createBaseVNode(`div`,{class:`tasks-content`,ref_key:`tasksScroller`,ref:tasksScroller},[createVNode(TransitionGroup,{"enter-active-class":`show`,"leave-active-class":`remove`,css:unref(animationSettings).animate,onBeforeLeave,onBeforeEnter:onBeforeEnterTask},{default:withCtx(()=>[(openBlock(!0),createElementBlock(Fragment,null,renderList(internalTasks.value,(task,index)=>(openBlock(),createElementBlock(`div`,{key:task.id,class:normalizeClass([`task-wrapper`,{"show-animate":canAnimate.value,"remove-animate":canAnimate.value}]),"data-id":index},[task.type===`message`?(openBlock(),createBlock(TaskMessage_default,mergeProps({key:0,ref_for:!0},task,{class:`task-card`}),null,16)):task.type===`goal`?(openBlock(),createBlock(TaskGoal_default,mergeProps({key:1,ref_for:!0},task,{class:[`task-card`,{glow:unref(animationSettings).animateNextTask&&nextTask.value&&nextTask.value.id===task.id}]}),null,16,[`class`])):createCommentVNode(``,!0)],10,_hoisted_1$222))),128))]),_:1},8,[`css`])],512)],2))}},TaskList_default=__plugin_vue_export_helper_default(_sfc_main$251,[[`__scopeId`,`data-v-5118e548`]]);const useTasksStore=defineStore(`tasks`,()=>{let header=ref(null),tasks=ref([]),{$game}=useLibStore();$game.events.on(`SetTasklistHeader`,setTasklistHeader),$game.events.on(`SetTasklistTask`,setTasklistTask),$game.events.on(`UpdateTasklistItem`,updateTasklistItem),$game.events.on(`SortTasklistItems`,sortTasklistItems),$game.events.on(`CompleteTasklistGoal`,id=>updateTasklistItem(id,{complete:!0,success:!0})),$game.events.on(`FailTasklistGoal`,id=>updateTasklistItem(id,{complete:!0,success:!1})),$game.events.on(`DiscardTasklistItem`,discardTasklistItem),$game.events.on(`HighlightTasklistItem`,highlightTasklistItem),$game.events.on(`HideCareerTasklist`,hideCareerTasklist),$game.events.on(`ClearTasklist`,clearTasklist);function setTasklistHeader(data){data==null||data==``?header.value=null:header.value={title:data.label,description:data.subtext}}function setTasklistTask(data){let id=data.id===null||data.id===void 0?`default`:data.id,index=tasks.value.findIndex(x=>x.id===id);if(index===-1&&data.clear)return;if(data.clear){tasks.value.splice(index,1);return}let isComplete=data.done!==void 0&&data.done||data.fail!==void 0&&data.fail,isSuccess=data.done!==void 0&&data.done||data.fail!==void 0&&!data.fail,description=data.subtext===0?``:data.subtext;index===-1?tasks.value.push({id:data.id,label:data.label,description,type:data.type,attention:data.attention,complete:isComplete,success:isSuccess}):(tasks.value[index].attention=data.attention,tasks.value[index].complete=isComplete,tasks.value[index].success=isSuccess,data.subtext!==void 0&&(tasks.value[index].description=description),data.label!==void 0&&(tasks.value[index].label=data.label),data.type!==void 0&&(tasks.value[index].type=data.type))}function updateTasklistItem(id,data){let index=tasks.value.findIndex(task=>task.id===id);index!==-1&&Object.keys(data).forEach(key=>{tasks.value[index][key]!==void 0&&(tasks.value[index][key]=data[key])})}function sortTasklistItems(order){let inOrderTasks=[],notInOrderTasks=[];tasks.value.forEach(task=>{order.includes(task.id)?inOrderTasks.push(task):notInOrderTasks.push(task)}),inOrderTasks.sort((a$1,b)=>order.indexOf(a$1.id)-order.indexOf(b.id)),tasks.value=[...inOrderTasks,...notInOrderTasks]}function discardTasklistItem(id,delay){delay!==void 0&&delay>0?setTimeout(()=>{setTasklistTask({id,clear:!0})},delay*1e3):setTasklistTask({id,clear:!0})}function highlightTasklistItem(id,duration){setTasklistTask({id,attention:!0}),duration!==void 0&&duration>0&&setTimeout(()=>{setTasklistTask({id,attention:!1})},duration*1e3)}function hideCareerTasklist(){}function clearTasklist(){header.value=null,tasks.value=[]}return{header,tasks,hasItems:computed(()=>tasks.value.length>0||header.value!==null)}});var _hoisted_1$221={class:`heading-container`},_hoisted_2$180={key:0,class:`status-add`},_hoisted_3$159={class:`content-container`},_hoisted_4$134={class:`main-content`},_hoisted_5$117={class:`main-content-slotted`},_hoisted_6$100={class:`side-content-slotted`},_sfc_main$250={__name:`ComputerWrapper`,props:{title:{type:String,default:`My Computer`},path:Array,wallpaperFull:Boolean,wallpaperHalf:Boolean,back:Boolean,close:Boolean},emits:[`back`,`close`],setup(__props,{expose:__expose,emit:__emit}){useUINavScope(`computer`);let{$game}=useLibStore(),computerStore=useComputerStore(),props=__props,breadcrumbItems=computed(()=>[{label:`Career`,closeAllMenus:!0},{label:computerStore.computerData.facilityName},...(props.path||[]).map(path=>({label:path}))]),elStatus=ref(),store$1=useTasksStore();provide(`animationSettings`,{animate:!0,animateOnMount:!1,animateOnMountIntervalDelay:.2,animateOnEmptyIntervalDelay:.1,animateOnEmpty:!0,animateNextTask:!0,successCallback:playAudio});function playAudio(){$game.lua.Engine.Audio.playOnce(`AudioGui`,`event:>UI>Career>Checkbox`)}__expose({statusUpdate:()=>elStatus.value.updateDisplay()});function breadcrumbClick(item){item.closeAllMenus&&$game.lua.career_career.closeAllMenus()}let emit$1=__emit;return(_ctx,_cache)=>withDirectives((openBlock(),createBlock(unref(layoutSingle_default),{"bng-ui-scope":`computer`,class:`computer-wrapper-layout`},{default:withCtx(()=>[createBaseVNode(`div`,_hoisted_1$221,[createVNode(unref(bngScreenHeadingV2_default),{type:`2`},{preheadings:withCtx(()=>[createVNode(bngBreadcrumbs_default,{class:`breadcrumbs`,simple:``,"disable-last-item":``,"show-back-button":``,navigable:!1,onClick:breadcrumbClick,onBack:_cache[0]||=$event=>emit$1(`back`),items:breadcrumbItems.value},null,8,[`items`])]),default:withCtx(()=>[renderSlot(_ctx.$slots,`title`,{},()=>[createTextVNode(toDisplayString(__props.title),1)],!0)]),_:3}),withDirectives((openBlock(),createBlock(unref(bngCard_default),{class:`status-container`},{default:withCtx(()=>[createVNode(unref(careerStatus_default),{ref_key:`elStatus`,ref:elStatus},null,512),_ctx.$slots.status?(openBlock(),createElementBlock(`div`,_hoisted_2$180,[renderSlot(_ctx.$slots,`status`,{},void 0,!0)])):createCommentVNode(``,!0)]),_:3})),[[unref(BngBlur_default),!0]])]),createBaseVNode(`div`,_hoisted_3$159,[createBaseVNode(`div`,_hoisted_4$134,[createBaseVNode(`div`,_hoisted_5$117,[renderSlot(_ctx.$slots,`default`,{},void 0,!0)]),createBaseVNode(`div`,_hoisted_6$100,[createVNode(unref(TaskList_default),{class:`task-list`,header:unref(store$1).header,tasks:unref(store$1).tasks},null,8,[`header`,`tasks`]),renderSlot(_ctx.$slots,`side`,{},void 0,!0)])])])]),_:3})),[[unref(BngOnUiNav_default),()=>emit$1(`back`),`back`]])}},ComputerWrapper_default=__plugin_vue_export_helper_default(_sfc_main$250,[[`__scopeId`,`data-v-b7460ee1`]]),_hoisted_1$220={class:`indicators-overlay`},_hoisted_2$179={class:`performance-index`},_hoisted_3$158={key:0,class:`lock-reason`},_hoisted_4$133={key:1,class:`lock-time`},_hoisted_5$116={key:1,class:`valueReduced`},_hoisted_6$99={key:0,class:`content`},_hoisted_7$87={class:`header`},_hoisted_8$72={class:`title-section`},_hoisted_9$65={class:`name`},_hoisted_10$56={class:`details`},_hoisted_11$50={class:`location-section`},_hoisted_12$39={class:`location-value`},_hoisted_13$32={key:0,class:`value-section`},_hoisted_14$30={key:0,class:`value-label reduced`},_hoisted_15$29={key:1,class:`value-label`},_hoisted_16$29={key:2,class:`total-value`},_hoisted_17$23={class:`insurance-section`},_hoisted_18$20={class:`insurance-value`},_hoisted_19$17={key:0,class:`warn`},_sfc_main$249=Object.assign({width:100,margin:.25},{__name:`VehicleTileRow`,props:{data:Object,isTutorial:Boolean,selected:Boolean,enableHover:{type:Boolean,default:!0},small:Boolean},setup(__props){let{units}=useBridge(),props=__props,partConditionAvg=computed(()=>{if(!props.data)return 1;if(props.data.partConditions){let conds=Object.values(props.data.partConditions);return conds.reduce((i,c)=>i+c.integrityValue,0)/conds.length}return 1}),colour=computed(()=>props.data?.config?.paints?.[0]?.baseColor??`#ccc`),thumbUrl=computed(()=>props.data.thumbnail?`${props.data.thumbnail}?${props.data.dirtyDate}`:null),location$1=computed(()=>{let res;return res=locked.value&&!locked.value.location?locked.value.reason:props.data.inGarage?`In garage`:props.data.distance?`${units.buildString(`length`,props.data.distance,0)} away`:`Storage`,res}),locked=computed(()=>{let res;if(props.data._message)res={reason:props.data._message};else if(props.data.missingFile)res={reason:`Missing File!`};else if(props.data.timeToAccess){let eta=`${~~(props.data.timeToAccess/60)}:${String(~~props.data.timeToAccess%60).padStart(2,`0`)}`;res=props.data.delayReason===`bought`?{reason:`Out for delivery`,eta}:props.data.delayReason===`repair`?{reason:`Being repaired`,eta}:{reason:`Available in`,eta}}else props.data.needsRepair&&(res={reason:`Needs repair`,location:!0});return res});return(_ctx,_cache)=>__props.data?withDirectives((openBlock(),createElementBlock(`div`,{key:0,class:normalizeClass({"vehicle-tile-row":!0,selected:__props.selected,"hover-enabled":__props.enableHover}),role:`button`},[createBaseVNode(`div`,{class:normalizeClass({preview:!0,locked:locked.value,small:__props.small})},[thumbUrl.value?(openBlock(),createBlock(unref(aspectRatio_default),{key:0,ratio:`16:9`,"external-image":thumbUrl.value,class:`preview-image`},{default:withCtx(()=>[createBaseVNode(`div`,_hoisted_1$220,[__props.data.favorite?withDirectives((openBlock(),createBlock(unref(bngIcon_default),{key:0,type:unref(icons).star,color:`#fd0`},null,8,[`type`])),[[unref(BngTooltip_default),`Favourite`]]):createCommentVNode(``,!0),__props.data.delayReason===`repair`?(openBlock(),createBlock(unref(bngIcon_default),{key:1,type:unref(icons).wrench,color:`#fff`},null,8,[`type`])):(openBlock(),createBlock(unref(bngCondition_default),{key:2,integrity:partConditionAvg.value,"integrity-warning":__props.data.needsRepair,color:colour.value,"show-tooltip":``},null,8,[`integrity`,`integrity-warning`,`color`])),createBaseVNode(`div`,_hoisted_2$179,toDisplayString(__props.data.certificationData&&__props.data.certificationData.vehicleClass?__props.data.certificationData.vehicleClass.performanceIndex.toFixed(0):`N/A`),1)]),locked.value?(openBlock(),createElementBlock(`span`,_hoisted_3$158,toDisplayString(locked.value.reason),1)):createCommentVNode(``,!0),locked.value&&locked.value.eta?(openBlock(),createElementBlock(`span`,_hoisted_4$133,toDisplayString(locked.value.eta),1)):createCommentVNode(``,!0)]),_:1},8,[`external-image`])):createCommentVNode(``,!0),!(__props.data.returnLoanerPermission&&__props.data.returnLoanerPermission.allow)&&__props.data.partConditionAvg<1?(openBlock(),createElementBlock(`span`,_hoisted_5$116,`Value reduced!`)):createCommentVNode(``,!0),__props.data.isInsured?createCommentVNode(``,!0):(openBlock(),createBlock(insurancePerkIcon_default,{key:2,class:`not-insured-overlay`,perkIconData:{iconOnly:__props.data.isInsured,color:`red`,smallText:`Not insured`}},null,8,[`perkIconData`]))],2),__props.data._message?createCommentVNode(``,!0):(openBlock(),createElementBlock(`div`,_hoisted_6$99,[createBaseVNode(`div`,_hoisted_7$87,[createBaseVNode(`div`,_hoisted_8$72,[createBaseVNode(`div`,_hoisted_9$65,toDisplayString(__props.data.niceName),1)])]),createBaseVNode(`div`,_hoisted_10$56,[createBaseVNode(`div`,_hoisted_11$50,[_cache[0]||=createBaseVNode(`span`,{class:`location-label`},`Location:`,-1),createBaseVNode(`span`,_hoisted_12$39,toDisplayString(location$1.value),1)]),__props.data.returnLoanerPermission?.allow?createCommentVNode(``,!0):(openBlock(),createElementBlock(`div`,_hoisted_13$32,[partConditionAvg.value<1?(openBlock(),createElementBlock(`span`,_hoisted_14$30,`Current Value:`)):(openBlock(),createElementBlock(`span`,_hoisted_15$29,`Value:`)),createVNode(unref(bngUnit_default),{money:__props.data.value},null,8,[`money`]),partConditionAvg.value<1?(openBlock(),createElementBlock(`div`,_hoisted_16$29,[_cache[1]||=createTextVNode(` Total Value: `,-1),createVNode(unref(bngUnit_default),{money:__props.data.valueRepaired},null,8,[`money`])])):createCommentVNode(``,!0)])),createBaseVNode(`div`,_hoisted_17$23,[_cache[2]||=createBaseVNode(`span`,{class:`insurance-label`},`Insurance:`,-1),createBaseVNode(`span`,_hoisted_18$20,toDisplayString(__props.data.insuranceInfo?__props.data.insuranceInfo.name:`n/a`),1),__props.data.isInsured?createCommentVNode(``,!0):(openBlock(),createElementBlock(`div`,_hoisted_19$17,`Not Insured!`))])])]))],2)),[[unref(BngDisabled_default),__props.data.disabled]]):createCommentVNode(``,!0)}}),VehicleTileRow_default=__plugin_vue_export_helper_default(_sfc_main$249,[[`__scopeId`,`data-v-777a3003`]]),_hoisted_1$219={key:1,class:`computer-actions`},_hoisted_2$178={key:0,class:`vehicle-select-container`},_hoisted_3$157={class:`vehicle-select`},_hoisted_4$132={key:0,class:`actions-list`},_hoisted_5$115=[`onClick`,`onMouseover`,`onFocus`],_hoisted_6$98={class:`label`},_hoisted_7$86={key:1,class:`no-vehicle-container`},_hoisted_8$71={key:2,class:`action-header`},_hoisted_9$64={key:3,class:`general-functions-container`},_hoisted_10$55={class:`actions-list`},_hoisted_11$49=[`onClick`,`onMouseover`,`onFocus`],_hoisted_12$38={class:`label`},_hoisted_13$31={key:0,class:`disable-reason`},_hoisted_14$29=[`innerHTML`],_hoisted_15$28={key:1,class:`disable-reason`},_hoisted_16$28=[`innerHTML`],_sfc_main$248={__name:`ComputerMain`,setup(__props){let computerStore=useComputerStore(),currentVehicleData=ref(null);watch(()=>computerStore.activeInventoryId,newId=>{Number(newId)&&Lua_default.career_modules_inventory.getVehicleUiData(newId).then(data=>{currentVehicleData.value=data})});let showVehicleSelectorButtons=computed(()=>computerStore.computerData.vehicles&&computerStore.computerData.vehicles.length>1),hasVehicles=computed(()=>computerStore.computerData.vehicles&&computerStore.computerData.vehicles.length);computed(()=>hasVehicles.value?computerStore.computerData.vehicles[computerStore.activeVehicleIndex].vehicleName:``),computed(()=>hasVehicles.value?computerStore.computerData.vehicles[computerStore.activeVehicleIndex].thumbnail:``),computed(()=>hasVehicles.value?computerStore.computerData.vehicles[computerStore.activeVehicleIndex].needsRepair?`Assess Performance (Repair Required)`:`Assess Performance`:``);let slowFunctions=[`vehicleShop`,`partInventory`],computerLoading=ref(!1),computerButtonCallback=(computerFunction,inventoryId=void 0)=>{computerFunction.disabled||(slowFunctions.includes(computerFunction.id)?(computerLoading.value=!0,setTimeout(()=>computerStore.computerButtonCallback(computerFunction.id,inventoryId),100)):computerStore.computerButtonCallback(computerFunction.id,inventoryId))},switchActiveVehicle=computerStore.switchActiveVehicle,iconById={painting:icons.sprayCan,partShop:icons.doorFrontCoins,repair:icons.wrench,tuning:icons.cogs,insurances:icons.shieldHandCheckmark,playerAbstract:icons.personSolid,vehicleInventory:icons.keys1,partInventory:icons.engine,vehicleShop:icons.carCoins,performanceIndex:icons.raceFlag},infoById=computed(()=>[...computerStore.generalComputerFunctions,...(computerStore.activeInventoryId?computerStore.vehicleSpecificComputerFunctions[computerStore.activeInventoryId]:void 0)||[]].reduce((res,func)=>(res[func.id]={icon:iconById[func.id]||icons.bug,label:func.label,reason:void 0},func.reason&&(res[func.id].label+=` *`,res[func.id].reason=func.reason.label),res),{})),isTutorialActive=ref(!1),disableReason=ref([null,null]),setReason=(idx,reason=null)=>{disableReason.value[idx]=reason,disableReason.value[(idx+1)%2]=null},close=()=>{computerLoading.value||Lua_default.career_career.closeAllMenus()};return onMounted(async()=>{getUINavServiceInstance().setFilteredEvents(UI_EVENT_GROUPS.focusMoveScalar),computerStore.requestComputerData(),Number(computerStore.activeInventoryId)&&Lua_default.career_modules_inventory.getVehicleUiData(computerStore.activeInventoryId).then(data=>{currentVehicleData.value=data}),Lua_default.career_modules_linearTutorial.isLinearTutorialActive().then(data=>{isTutorialActive.value=data})}),onUnmounted(()=>{computerStore.onMenuClosed(),getUINavServiceInstance().clearFilteredEvents(),computerStore.$dispose()}),(_ctx,_cache)=>(openBlock(),createBlock(ComputerWrapper_default,{title:unref(computerStore).computerData.facilityName+` - Home screen`,close:``,onBack:close},{default:withCtx(()=>[withDirectives((openBlock(),createBlock(unref(bngCard_default),{class:`card-content`},{default:withCtx(()=>[computerLoading.value?(openBlock(),createBlock(unref(bngCardHeading_default),{key:0},{default:withCtx(()=>[..._cache[6]||=[createTextVNode(` Loading... `,-1)]]),_:1})):createCommentVNode(``,!0),computerLoading.value?createCommentVNode(``,!0):(openBlock(),createElementBlock(`div`,_hoisted_1$219,[_cache[9]||=createBaseVNode(`div`,{class:`action-header`},[createBaseVNode(`div`,{class:`line left`}),createBaseVNode(`div`,{class:`title`},`Vehicle Management`),createBaseVNode(`div`,{class:`line right`})],-1),hasVehicles.value?(openBlock(),createElementBlock(`div`,_hoisted_2$178,[createBaseVNode(`div`,_hoisted_3$157,[showVehicleSelectorButtons.value?withDirectives((openBlock(),createBlock(unref(bngButton_default),{key:0,style:{height:`3em`},accent:unref(ACCENTS).ghost,onClick:_cache[0]||=$event=>unref(switchActiveVehicle)(-1),icon:unref(icons).arrowLargeLeft},{default:withCtx(()=>[createVNode(unref(bngBinding_default),{"ui-event":`tab_l`,deviceMask:`xinput`})]),_:1},8,[`accent`,`icon`])),[[unref(BngOnUiNav_default),void 0,`tab_l`,{asMouse:!0}]]):createCommentVNode(``,!0),createVNode(VehicleTileRow_default,{class:normalizeClass([`vehicle-tile-row`,{hasButtons:showVehicleSelectorButtons.value}]),data:currentVehicleData.value,enableHover:!1,small:!0},null,8,[`class`,`data`]),showVehicleSelectorButtons.value?withDirectives((openBlock(),createBlock(unref(bngButton_default),{key:1,style:{height:`3em`},accent:unref(ACCENTS).ghost,onClick:_cache[1]||=$event=>unref(switchActiveVehicle)(1),icon:unref(icons).arrowLargeRight},{default:withCtx(()=>[createVNode(unref(bngBinding_default),{"ui-event":`tab_r`,deviceMask:`xinput`})]),_:1},8,[`accent`,`icon`])),[[unref(BngOnUiNav_default),void 0,`tab_r`,{asMouse:!0}]]):createCommentVNode(``,!0)]),unref(computerStore).activeInventoryId&&unref(computerStore).vehicleSpecificComputerFunctions[unref(computerStore).activeInventoryId]?(openBlock(),createElementBlock(`div`,_hoisted_4$132,[(openBlock(!0),createElementBlock(Fragment,null,renderList(unref(computerStore).vehicleSpecificComputerFunctions[unref(computerStore).activeInventoryId],(computerFunction,index)=>withDirectives((openBlock(),createElementBlock(`div`,{class:normalizeClass([`computer-function-tile`,{"action-disabled":computerFunction.disabled}]),key:computerFunction.id,tabindex:`0`,"bng-nav-item":``,onClick:$event=>computerButtonCallback(computerFunction,unref(computerStore).activeInventoryId),onMouseover:$event=>setReason(0,infoById.value[computerFunction.id].reason),onFocus:$event=>setReason(0,infoById.value[computerFunction.id].reason),onMouseleave:_cache[2]||=$event=>setReason(0),onBlur:_cache[3]||=$event=>setReason(0)},[createVNode(unref(bngIcon_default),{class:`icon`,type:infoById.value[computerFunction.id].icon},null,8,[`type`]),createBaseVNode(`span`,_hoisted_6$98,toDisplayString(infoById.value[computerFunction.id].label),1)],42,_hoisted_5$115)),[[unref(BngOnUiNav_default),void 0,`ok`,{asMouse:!0,focusRequired:!0}],[unref(BngUiNavFocus_default),index==0?0:void 0]])),128))])):createCommentVNode(``,!0)])):(openBlock(),createElementBlock(`div`,_hoisted_7$86,[..._cache[7]||=[createBaseVNode(`span`,null,`No vehicles in garage.`,-1),createBaseVNode(`p`,null,` Place a vehicle in your garage to access modify and manage it.`,-1)]])),unref(computerStore).generalComputerFunctions?(openBlock(),createElementBlock(`div`,_hoisted_8$71,[..._cache[8]||=[createBaseVNode(`div`,{class:`line left`},null,-1),createBaseVNode(`div`,{class:`title`},`General Computer Functions`,-1),createBaseVNode(`div`,{class:`line right`},null,-1)]])):createCommentVNode(``,!0),unref(computerStore).generalComputerFunctions?(openBlock(),createElementBlock(`div`,_hoisted_9$64,[createBaseVNode(`div`,_hoisted_10$55,[(openBlock(!0),createElementBlock(Fragment,null,renderList(unref(computerStore).generalComputerFunctions,(computerFunction,index)=>(openBlock(),createElementBlock(Fragment,{key:computerFunction.id},[computerFunction.type?createCommentVNode(``,!0):withDirectives((openBlock(),createElementBlock(`div`,{key:0,class:normalizeClass([`computer-function-tile`,{"action-disabled":computerFunction.disabled}]),tabindex:`0`,"bng-nav-item":``,onClick:$event=>computerButtonCallback(computerFunction),onMouseover:$event=>setReason(1,infoById.value[computerFunction.id].reason),onFocus:$event=>setReason(1,infoById.value[computerFunction.id].reason),onMouseleave:_cache[4]||=$event=>setReason(1),onBlur:_cache[5]||=$event=>setReason(1)},[createVNode(unref(bngIcon_default),{class:`icon`,type:infoById.value[computerFunction.id].icon},null,8,[`type`]),createBaseVNode(`span`,_hoisted_12$38,toDisplayString(infoById.value[computerFunction.id].label),1)],42,_hoisted_11$49)),[[unref(BngOnUiNav_default),void 0,`ok`,{asMouse:!0,focusRequired:!0}],[unref(BngUiNavFocus_default),!hasVehicles.value&&index==0?0:void 0]])],64))),128))]),disableReason.value[0]?(openBlock(),createElementBlock(`div`,_hoisted_13$31,[withDirectives(createVNode(unref(bngIcon_default),{class:`disable-icon`,type:unref(icons).info},null,8,[`type`]),[[vShow,disableReason.value[0]]]),createBaseVNode(`span`,{innerHTML:disableReason.value[0]||`\xA0`},null,8,_hoisted_14$29)])):createCommentVNode(``,!0),disableReason.value[1]?(openBlock(),createElementBlock(`div`,_hoisted_15$28,[createVNode(unref(bngIcon_default),{class:`disable-icon`,type:unref(icons).info},null,8,[`type`]),createBaseVNode(`span`,{innerHTML:disableReason.value[1]||`\xA0`},null,8,_hoisted_16$28)])):createCommentVNode(``,!0)])):createCommentVNode(``,!0)]))]),_:1})),[[unref(BngBlur_default),1]])]),_:1},8,[`title`]))}},ComputerMain_default=__plugin_vue_export_helper_default(_sfc_main$248,[[`__scopeId`,`data-v-10a4ce58`]]);const useInsurancesStore=defineStore(`insurances`,()=>{let{events:events$3}=useBridge(),invVehsInsurancesData=ref({}),plClassesData=ref({}),uninsuredVehsData=ref({}),driverScoreData=ref({});function requestInitialData(){Lua_default.career_modules_insurance_insurance.sendUIData()}return events$3.on(`insurancesData`,data=>{invVehsInsurancesData.value=data.invVehsInsurancesData,plClassesData.value=data.plClassesData,uninsuredVehsData.value=data.uninsuredVehsData,driverScoreData.value=data.driverScoreData}),{dispose:()=>{events$3.off(`insurancesData`)},requestInitialData,closeMenu:Lua_default.career_modules_insurance_insurance.closeMenu,invVehsInsurancesData,plClassesData,uninsuredVehsData,driverScoreData}});var _hoisted_1$218={key:0,class:`cards-wrapper blue-background`},_hoisted_2$177={class:`insurance-tiers-wrapper`},_hoisted_3$156=[`onClick`],_hoisted_4$131={class:`insurance-tier-card-name`},_hoisted_5$114={class:`insurance-tier-card-description`},_hoisted_6$97={class:`insurance-tier-card-cars-insured`},_hoisted_7$85={class:`left-no-insurance`},_hoisted_8$70={class:`no-insurance-text-wrapper`},_hoisted_9$63={class:`no-insurance-title`},_hoisted_10$54={class:`no-insurance-description`},_hoisted_11$48={class:`uninsured-count`},_hoisted_12$37={key:1,class:`small-insurance-cards-wrapper blue-background`},_sfc_main$247={__name:`InsurancesMain`,setup(__props){useComputerStore();let insurancesStore=useInsurancesStore(),selectedInsuranceClassId=ref(null),selectInsuranceClass=classId=>{selectedInsuranceClassId.value=classId},sortedInsuranceClasses=computed(()=>{let classes=insurancesStore.plClassesData;return classes?Object.entries(classes).map(([classId,classData])=>({classId,classData})).sort((a$1,b)=>a$1.classData.priority-b.classData.priority):[]});onBeforeMount(()=>{insurancesStore.requestInitialData()}),onUnmounted(()=>{Lua_default.extensions.hook(`onExitInsurancesComputerScreen`),insurancesStore.$dispose()});let close=()=>{selectedInsuranceClassId.value?selectedInsuranceClassId.value=null:insurancesStore.closeMenu()},openUninsuredVehicles=()=>{addPopup(uninsuredVehicles_default,{uninsuredData:insurancesStore.uninsuredVehsData})};return(_ctx,_cache)=>(openBlock(),createBlock(ComputerWrapper_default,{ref:`wrapper`,path:[`Insurance`],title:`Insurance`,back:``,onBack:close},{default:withCtx(()=>[createVNode(unref(bngCard_default),{class:`insurances-card blue-background`},{default:withCtx(()=>[selectedInsuranceClassId.value?createCommentVNode(``,!0):(openBlock(),createElementBlock(`div`,_hoisted_1$218,[createBaseVNode(`div`,_hoisted_2$177,[(openBlock(!0),createElementBlock(Fragment,null,renderList(sortedInsuranceClasses.value,({classId,classData})=>(openBlock(),createElementBlock(`div`,{class:`insurance-tier-card`,key:classId,onClick:$event=>selectInsuranceClass(classId)},[createVNode(unref(bngIcon_default),{class:`insurance-icon`,type:unref(icons)[classData.icon]},null,8,[`type`]),createBaseVNode(`div`,_hoisted_4$131,toDisplayString(classData.name),1),createBaseVNode(`div`,_hoisted_5$114,toDisplayString(classData.description),1),createBaseVNode(`div`,_hoisted_6$97,toDisplayString(classData.carsInsured)+` VEHICLES INSURED `,1)],8,_hoisted_3$156))),128))]),createBaseVNode(`div`,{class:`no-insurance-card`,onClick:openUninsuredVehicles},[createBaseVNode(`div`,_hoisted_7$85,[createVNode(unref(bngIcon_default),{class:`no-insurance-icon`,type:unref(icons).checkmark},null,8,[`type`]),createBaseVNode(`div`,_hoisted_8$70,[createBaseVNode(`div`,_hoisted_9$63,toDisplayString(unref(insurancesStore).uninsuredVehsData.title),1),createBaseVNode(`div`,_hoisted_10$54,toDisplayString(unref(insurancesStore).uninsuredVehsData.description),1)])]),createBaseVNode(`div`,_hoisted_11$48,toDisplayString(unref(insurancesStore).uninsuredVehsData.carsUninsuredCount)+` vehicles `,1)])])),selectedInsuranceClassId.value?(openBlock(),createElementBlock(`div`,_hoisted_12$37,[(openBlock(!0),createElementBlock(Fragment,null,renderList(unref(insurancesStore).plClassesData[selectedInsuranceClassId.value].insurances,insurance=>(openBlock(),createBlock(unref(smallInsuranceCard_default),{key:insurance.id,insuranceData:insurance,driverScoreData:unref(insurancesStore).driverScoreData},null,8,[`insuranceData`,`driverScoreData`]))),128))])):createCommentVNode(``,!0)]),_:1})]),_:1},512))}},InsurancesMain_default=__plugin_vue_export_helper_default(_sfc_main$247,[[`__scopeId`,`data-v-a9e49ad5`]]),_hoisted_1$217={key:0,class:`content`},_hoisted_2$176={class:`stats-grid-3`},_hoisted_3$155={class:`score-header`},_hoisted_4$130={class:`score-content`},_hoisted_5$113={class:`score-info`},_hoisted_6$96={class:`score-description`},_hoisted_7$84={class:`stat-card`},_hoisted_8$69={class:`stat-value blue`},_hoisted_9$62={class:`stat-card`},_hoisted_10$53={class:`stats-grid-2`},_hoisted_11$47={class:`info-card`},_hoisted_12$36={class:`info-rows`},_hoisted_13$30={class:`info-row`},_hoisted_14$28={class:`info-value orange`},_hoisted_15$27={class:`info-row`},_hoisted_16$27={class:`info-value green`},_hoisted_17$22={class:`info-row total`},_hoisted_18$19={class:`info-value`},_hoisted_19$16={class:`info-card`},_hoisted_20$14={class:`info-rows`},_hoisted_21$13={class:`info-row bottom-border`},_hoisted_22$11={class:`info-value blue`},_hoisted_23$10={class:`info-row`},_hoisted_24$9={class:`info-value red`},_hoisted_25$8={class:`info-row`},_hoisted_26$6={class:`info-value orange`},_hoisted_27$6={class:`info-row`},_hoisted_28$5={class:`info-value yellow`},_hoisted_29$5={class:`info-row total`},_hoisted_30$5={class:`info-value`},_hoisted_31$5={class:`info-summary`},_hoisted_32$5={class:`info-row small`},_hoisted_33$5={class:`info-value green bold`},_hoisted_34$5={class:`reset-card`},_hoisted_35$4={class:`reset-content`},_hoisted_36$4={class:`reset-description`},_hoisted_37$3={class:`highlight`},_hoisted_38$3={class:`reset-details`},_hoisted_39$3={class:`reset-row`},_hoisted_40$2={class:`reset-row`},_hoisted_41$2={class:`reset-value green`},_hoisted_42$2={class:`reset-row cost`},_hoisted_43$2={class:`reset-value yellow large`},_hoisted_44$2={key:0,class:`reset-payback`},_hoisted_45$2=[`disabled`],_sfc_main$246={__name:`DriverAbstract`,setup(__props){let{units}=useBridge(),abstractData=ref(null),driverTier=computed(()=>abstractData.value?.driverScoreTier),totalDistanceFormatted=computed(()=>abstractData.value?units.buildString(`length`,abstractData.value.totalDistanceDriven,0):``),premiumEffectClass=computed(()=>{if(!driverTier.value)return``;let multiplier=driverTier.value.multiplier;return multiplier<1?`green`:multiplier>1?`red`:`neutral`}),premiumEffectText=computed(()=>{if(!driverTier.value)return`Standard Rate`;let multiplier=driverTier.value.multiplier;return multiplier<1?`${Math.round((1-multiplier)*100)}% Savings`:multiplier>1?`${Math.round((multiplier-1)*100)}% Penalty`:`Standard Rate`}),canResetScore=computed(()=>abstractData.value?abstractData.value.driverScore{if(!driverTier.value)return`green`;let multiplier=driverTier.value.multiplier;return multiplier<1?`blue`:multiplier<1.1?`green`:multiplier<1.3?`yellow`:multiplier<1.5?`orange`:`red`},getDriverColor=()=>({blue:`var(--blue-200)`,green:`var(--green-300)`,yellow:`var(--yellow-400)`,orange:`var(--orange-shade-10)`,red:`var(--red-400)`})[getDriverColorClass()]||`var(--green-300)`,loadData=async()=>{try{abstractData.value=await Lua_default.career_modules_playerAbstract.getPlayerAbstractData()}catch(error){console.error(`Failed to load driver abstract data:`,error)}},resetDriverScore=async()=>{try{await Lua_default.career_modules_insurance_insurance.resetDriverScore(),await loadData()}catch(error){console.error(`Failed to reset driver score:`,error)}},close=()=>{Lua_default.career_modules_playerAbstract.closePlayerAbstractMenu()};return onBeforeMount(loadData),(_ctx,_cache)=>(openBlock(),createBlock(ComputerWrapper_default,{ref:`wrapper`,path:[`Driver's Abstract`],title:`Driver's Abstract`,back:``,onBack:close},{default:withCtx(()=>[createVNode(unref(bngCard_default),{class:`driver-abstract-card`},{default:withCtx(()=>[abstractData.value?(openBlock(),createElementBlock(`div`,_hoisted_1$217,[createBaseVNode(`div`,_hoisted_2$176,[createBaseVNode(`div`,{class:`score-card`,style:normalizeStyle({borderColor:getDriverColor()})},[createBaseVNode(`div`,_hoisted_3$155,[_cache[0]||=createBaseVNode(`div`,{class:`section-title`},`Driver Score: Out of 100`,-1),createVNode(unref(TutorialButton_default),{icon:unref(icons).help,pages:[`driverScore`]},null,8,[`icon`])]),createBaseVNode(`div`,_hoisted_4$130,[createBaseVNode(`div`,{class:normalizeClass([`score-value`,getDriverColorClass()])},toDisplayString(abstractData.value.driverScore),3),createBaseVNode(`div`,_hoisted_5$113,[createBaseVNode(`div`,{class:normalizeClass([`score-risk`,getDriverColorClass()])},toDisplayString(abstractData.value.driverScoreTier.risk),3),createBaseVNode(`div`,_hoisted_6$96,toDisplayString(abstractData.value.driverScoreTier.description),1)])])],4),createBaseVNode(`div`,_hoisted_7$84,[_cache[1]||=createBaseVNode(`div`,{class:`section-title`},`Total Distance Driven`,-1),createBaseVNode(`div`,_hoisted_8$69,toDisplayString(totalDistanceFormatted.value),1)]),createBaseVNode(`div`,_hoisted_9$62,[_cache[2]||=createBaseVNode(`div`,{class:`section-title`},`Premium Effect`,-1),createBaseVNode(`div`,{class:normalizeClass([`stat-value`,premiumEffectClass.value])},toDisplayString(premiumEffectText.value),3),_cache[3]||=createBaseVNode(`div`,{class:`stat-note`},` Applies to every insurance provider when premiums renew `,-1)])]),createBaseVNode(`div`,_hoisted_10$53,[createBaseVNode(`div`,_hoisted_11$47,[_cache[7]||=createBaseVNode(`div`,{class:`section-title`},`Repair History`,-1),createBaseVNode(`div`,_hoisted_12$36,[createBaseVNode(`div`,_hoisted_13$30,[_cache[4]||=createBaseVNode(`span`,{class:`info-label`},`Insurance Claims:`,-1),createBaseVNode(`span`,_hoisted_14$28,toDisplayString(abstractData.value.repairHistory.insuranceRepairs),1)]),createBaseVNode(`div`,_hoisted_15$27,[_cache[5]||=createBaseVNode(`span`,{class:`info-label`},`Private Repairs:`,-1),createBaseVNode(`span`,_hoisted_16$27,toDisplayString(abstractData.value.repairHistory.privateRepairs),1)]),createBaseVNode(`div`,_hoisted_17$22,[_cache[6]||=createBaseVNode(`span`,{class:`info-label`},`Total Repairs:`,-1),createBaseVNode(`span`,_hoisted_18$19,toDisplayString(abstractData.value.repairHistory.insuranceRepairs+abstractData.value.repairHistory.privateRepairs),1)])]),_cache[8]||=createBaseVNode(`div`,{class:`info-tip`},` Private repairs don't affect your record `,-1)]),createBaseVNode(`div`,_hoisted_19$16,[_cache[16]||=createBaseVNode(`div`,{class:`section-title`},`Financial Summary`,-1),createBaseVNode(`div`,_hoisted_20$14,[createBaseVNode(`div`,_hoisted_21$13,[_cache[9]||=createBaseVNode(`span`,{class:`info-label`},`Vehicles Currently Insured:`,-1),createBaseVNode(`span`,_hoisted_22$11,toDisplayString(abstractData.value.financialSummary.vehiclesInsuredCount),1)]),createBaseVNode(`div`,_hoisted_23$10,[_cache[10]||=createBaseVNode(`span`,{class:`info-label`},`Premiums Paid:`,-1),createBaseVNode(`span`,_hoisted_24$9,[createVNode(unref(bngUnit_default),{class:`no-margin`,money:abstractData.value.financialSummary.totalPremiumPaid},null,8,[`money`])])]),createBaseVNode(`div`,_hoisted_25$8,[_cache[11]||=createBaseVNode(`span`,{class:`info-label`},`Deductibles Paid:`,-1),createBaseVNode(`span`,_hoisted_26$6,[createVNode(unref(bngUnit_default),{class:`no-margin`,money:abstractData.value.financialSummary.totalDeductiblePaid},null,8,[`money`])])]),createBaseVNode(`div`,_hoisted_27$6,[_cache[12]||=createBaseVNode(`span`,{class:`info-label`},`Private Repairs:`,-1),createBaseVNode(`span`,_hoisted_28$5,[createVNode(unref(bngUnit_default),{class:`no-margin`,money:abstractData.value.financialSummary.totalPrivateRepairsPaid},null,8,[`money`])])]),createBaseVNode(`div`,_hoisted_29$5,[_cache[13]||=createBaseVNode(`span`,{class:`info-label`},`Total Spent:`,-1),createBaseVNode(`span`,_hoisted_30$5,[createVNode(unref(bngUnit_default),{class:`no-margin`,money:abstractData.value.financialSummary.totalPaid},null,8,[`money`])])])]),createBaseVNode(`div`,_hoisted_31$5,[createBaseVNode(`div`,_hoisted_32$5,[_cache[14]||=createBaseVNode(`span`,{class:`info-label`},`Damage Covered by Insurance:`,-1),createBaseVNode(`span`,_hoisted_33$5,[createVNode(unref(bngUnit_default),{class:`no-margin`,money:abstractData.value.financialSummary.damageCoveredByInsurance},null,8,[`money`])])]),_cache[15]||=createBaseVNode(`div`,{class:`info-tip blue italic`},` Insurance saved you from paying full repair costs `,-1)])])]),createBaseVNode(`div`,_hoisted_34$5,[_cache[22]||=createBaseVNode(`div`,{class:`section-title`},`Driver Score Reset`,-1),createBaseVNode(`div`,_hoisted_35$4,[createBaseVNode(`p`,_hoisted_36$4,[_cache[17]||=createTextVNode(` Reset your driver score to `,-1),createBaseVNode(`span`,_hoisted_37$3,toDisplayString(abstractData.value.driverScoreReset.resetTo),1),_cache[18]||=createTextVNode(` to remove premium penalties. `,-1)]),createBaseVNode(`div`,_hoisted_38$3,[createBaseVNode(`div`,_hoisted_39$3,[_cache[19]||=createBaseVNode(`span`,{class:`reset-label`},`Current Score:`,-1),createBaseVNode(`span`,{class:normalizeClass([`reset-value`,canResetScore.value?`red`:`green`])},toDisplayString(abstractData.value.driverScore),3)]),createBaseVNode(`div`,_hoisted_40$2,[_cache[20]||=createBaseVNode(`span`,{class:`reset-label`},`Reset To:`,-1),createBaseVNode(`span`,_hoisted_41$2,toDisplayString(abstractData.value.driverScoreReset.resetTo),1)]),createBaseVNode(`div`,_hoisted_42$2,[_cache[21]||=createBaseVNode(`span`,{class:`reset-label`},`Reset Cost:`,-1),createBaseVNode(`span`,_hoisted_43$2,[createVNode(unref(bngUnit_default),{class:`no-margin`,money:abstractData.value.driverScoreReset.resetCost},null,8,[`money`])])]),canResetScore.value&&_ctx.resetSavingsPer100km>0?(openBlock(),createElementBlock(`div`,_hoisted_44$2,` Pays for itself after xxx km `)):createCommentVNode(``,!0)]),createBaseVNode(`button`,{onClick:resetDriverScore,disabled:!canResetScore.value,class:normalizeClass([`reset-button`,{disabled:!canResetScore.value}])},toDisplayString(canResetScore.value?`Reset Score`:`Not Available (Score Already at or Higher than `+abstractData.value.driverScoreReset.resetTo+`)`),11,_hoisted_45$2)])])])):createCommentVNode(``,!0)]),_:1})]),_:1},512))}},DriverAbstract_default=__plugin_vue_export_helper_default(_sfc_main$246,[[`__scopeId`,`data-v-8041df87`]]),_hoisted_1$216={"bng-ui-scope":`logbook`,class:`career-logbook-wrapper`},_hoisted_2$175={class:`career-logbook-container`},_hoisted_3$154={class:`career-logbook-list`},_hoisted_4$129={class:`logbook-list-wrapper`},_hoisted_5$112=[`onClick`],_hoisted_6$95={class:`career-logbook-item-content`},_hoisted_7$83={class:`career-logbook-meta`},_hoisted_8$68={class:`career-logbook-newmark`},_hoisted_9$61={class:`career-logbook-item-label`},_hoisted_10$52={class:`career-logbook-details`},_hoisted_11$46={class:`career-logbook-title-newmark`},_hoisted_12$35={class:`career-logbook-meta`},_hoisted_13$29={key:0},_hoisted_14$27={class:`logbook-description`},_hoisted_15$26={key:1,class:`logbook-description logbook-table`},_hoisted_16$26={key:2},_hoisted_17$21={key:3,class:`logbook-description quest-status`},_hoisted_18$18={class:`quest-stats-wrapper`},_hoisted_19$15={class:`quest-labels`},_hoisted_20$13={class:`progress-label`},_hoisted_21$12={key:0,class:`progressbar-background`},_hoisted_22$10={class:`rewards-wrapper flex-row`},_hoisted_23$9={class:`label`},_hoisted_24$8={class:`rewards-section flex-row`},_hoisted_25$7={class:`flex-row`},_sfc_main$245={__name:`Logbook`,props:{id:String},setup(__props){useUINavScope(`logbook`);let rewardUnitTypes={money:`beambucks`,beamXP:`xp`},props=__props,sectionTabs=ref(),entryId=computed(()=>props.id===void 0?void 0:(``+props.id).replace(/%/g,`/`)),logbookTabs=ref([{id:`info`,name:`Info`,entries:[],filter:i=>i.type===`info`},{id:`history`,name:`History`,entries:[],filter:i=>i.type===`progress`}]),checkForNewLogEntries=()=>logbookTabs.value.forEach(tab=>tab.hasNew=!!tab.entries.some(i=>i.isNew));function setup$3(data){if(data.forEach(entry=>{Object.hasOwn(entry,`text`)&&(entry.text=parse$1($translate.contextTranslate(entry.text,!0)),entry._ready=!0)}),logbookTabs.value.forEach(tab=>tab.entries=data.filter(tab.filter)),checkForNewLogEntries(),entryId.value){for(let tab of logbookTabs.value)for(let entry of tab.entries)if(``+entry.entryId===entryId.value){toggleExpand(entry),tab.isPreselected=!0;return}}logbookTabs.value[0].entries.length&&toggleExpand(logbookTabs.value[0].entries[0])}ref({});let selectedEntry=ref({});ref({});let readTimer,toggleExpand=entry=>setTimeout(()=>{readTimer&&clearTimeout(readTimer),selectedEntry.value=entry,readTimer=window.setTimeout(()=>{selectedEntry.value.isNew=!1,checkForNewLogEntries(),entry.type===`quest`?Lua_default.career_modules_questManager.setQuestAsNotNew(entry.questId):Lua_default.career_modules_logbook.setLogbookEntryRead(entry.entryId,!0)},1e3)},0),tabChange=newTab=>{if(entryId.value){entryId.value=void 0;return}let tab=logbookTabs.value[newTab.id];!tab||!tab.entries||tab.entries.length===0||toggleExpand(tab.entries[0])},claimRewards=entry=>{Lua_default.career_modules_questManager.claimRewardsById(entry.questId),entry.claimable=!1,entry.claimed=!0},exit=()=>setTimeout(()=>window.bngVue.gotoAngularState(`menu.careerPause`),0);return onBeforeMount(()=>{Lua_default.simTimeAuthority.pushPauseRequest(`logbook`)}),onMounted(()=>{Lua_default.career_modules_logbook.getLogbook().then(setup$3)}),onUnmounted(()=>{Lua_default.simTimeAuthority.popPauseRequest(`logbook`)}),(_ctx,_cache)=>withDirectives((openBlock(),createBlock(unref(layoutSingle_default),{class:`logbook-layout`},{default:withCtx(()=>[createVNode(unref(bngScreenHeading_default),null,{default:withCtx(()=>[createTextVNode(toDisplayString(_ctx.$t(`ui.career.logbook.subHeading`)),1)]),_:1}),withDirectives((openBlock(),createElementBlock(`div`,_hoisted_1$216,[createBaseVNode(`div`,_hoisted_2$175,[createBaseVNode(`div`,_hoisted_3$154,[createVNode(unref(tabs_default),{ref_key:`sectionTabs`,ref:sectionTabs,onChange:tabChange,class:`bng-tabs`,"make-tab-header-classes":tabDetails=>({flagged:tabDetails.data.hasNew})},{default:withCtx(()=>[(openBlock(!0),createElementBlock(Fragment,null,renderList(logbookTabs.value,tabDetail=>(openBlock(),createBlock(unref(tab_default),{key:tabDetail.id,heading:_ctx.$t(tabDetail.name),active:tabDetail.isPreselected,data:tabDetail},{default:withCtx(()=>[withDirectives((openBlock(),createElementBlock(`div`,_hoisted_4$129,[(openBlock(!0),createElementBlock(Fragment,null,renderList(tabDetail.entries,(entry,index)=>withDirectives((openBlock(),createElementBlock(`div`,{key:entry.entryId,"bng-nav-item":``,class:normalizeClass([`career-logbook-item`,{selected:selectedEntry.value!==void 0&&selectedEntry.value.entryId==entry.entryId}]),onClick:$event=>toggleExpand(entry)},[createBaseVNode(`div`,_hoisted_6$95,[createBaseVNode(`div`,_hoisted_7$83,[createBaseVNode(`div`,null,toDisplayString(_ctx.$ctx_t(entry.cardTypeLabel)),1),createVNode(unref(bngDivider_default),{class:`vertical-divider`}),withDirectives(createBaseVNode(`div`,null,null,512),[[unref(BngRelativeTime_default),entry.time]]),withDirectives(createBaseVNode(`div`,_hoisted_8$68,null,512),[[vShow,entry.isNew]])]),createBaseVNode(`div`,_hoisted_9$61,toDisplayString(_ctx.$ctx_t(entry.title)),1)])],10,_hoisted_5$112)),[[unref(BngUiNavFocus_default),tabDetail.entries.length-index],[unref(BngSoundClass_default),`bng_click_generic_small`]])),128))])),[[unref(BngUiNavScroll_default)]])]),_:2},1032,[`heading`,`active`,`data`]))),128))]),_:1},8,[`make-tab-header-classes`])]),createBaseVNode(`div`,_hoisted_10$52,[withDirectives(createVNode(unref(bngCard_default),{class:`career-logbook-content-card`},createSlots({default:withCtx(()=>[createVNode(unref(bngCardHeading_default),{class:`logbook-entry-heading`,type:`ribbon`},{default:withCtx(()=>[createTextVNode(toDisplayString(selectedEntry.value&&_ctx.$ctx_t(selectedEntry.value.title))+` `,1),withDirectives(createBaseVNode(`div`,_hoisted_11$46,null,512),[[vShow,selectedEntry.value.isNew]]),withDirectives((openBlock(),createBlock(unref(bngButton_default),{class:`exitButton`,onClick:exit,accent:unref(ACCENTS).attention},{default:withCtx(()=>[createVNode(unref(bngBinding_default),{"ui-event":`back`,deviceMask:`xinput`}),_cache[1]||=createTextVNode(`Back`,-1)]),_:1},8,[`accent`])),[[unref(BngSoundClass_default),`bng_back_generic`]])]),_:1}),createBaseVNode(`div`,_hoisted_12$35,[createBaseVNode(`div`,null,toDisplayString(_ctx.$ctx_t(selectedEntry.value.cardTypeLabel)),1),createVNode(unref(bngDivider_default),{class:`vertical-divider`}),withDirectives(createBaseVNode(`div`,null,null,512),[[unref(BngRelativeTime_default),selectedEntry.value.time]])]),createBaseVNode(`div`,{class:normalizeClass({"card-body":!0,"with-rewards":selectedEntry.value.type===`quest`&&selectedEntry.value.rewards.length})},[selectedEntry.value.cover?(openBlock(),createElementBlock(`div`,{key:0,class:`logbook-cover-image`,style:normalizeStyle({backgroundImage:`url(${selectedEntry.value.cover})`})},[selectedEntry.value.coverText?(openBlock(),createElementBlock(`h1`,_hoisted_13$29,toDisplayString(selectedEntry.value.coverText),1)):createCommentVNode(``,!0)],4)):createCommentVNode(``,!0),createBaseVNode(`div`,_hoisted_14$27,[selectedEntry.value._ready?(openBlock(),createBlock(unref(dynamicComponent_default),{key:0,template:_ctx.$ctx_t(selectedEntry.value.text)},null,8,[`template`])):createCommentVNode(``,!0)]),selectedEntry.value.tables?(openBlock(),createElementBlock(`div`,_hoisted_15$26,[(openBlock(!0),createElementBlock(Fragment,null,renderList(selectedEntry.value.tables,(table,keyT)=>(openBlock(),createElementBlock(`table`,{key:keyT},[createBaseVNode(`tbody`,null,[createBaseVNode(`tr`,null,[(openBlock(!0),createElementBlock(Fragment,null,renderList(table.headers,(header,keyH)=>(openBlock(),createElementBlock(`th`,{key:keyH},toDisplayString(header),1))),128))]),(openBlock(!0),createElementBlock(Fragment,null,renderList(table.rows,(row,keyR)=>(openBlock(),createElementBlock(`tr`,{key:keyR},[(openBlock(!0),createElementBlock(Fragment,null,renderList(row,(data,keyD)=>(openBlock(),createElementBlock(`td`,{key:keyD},[typeof data==`object`&&data&&data.hasOwnProperty(`type`)&&data.type===`rewards`?(openBlock(),createBlock(RewardsPills_default,{key:0,rewards:data.rewards,hideNumbers:!1},null,8,[`rewards`])):(openBlock(),createBlock(unref(dynamicComponent_default),{key:1,template:_ctx.$ctx_t(data)},null,8,[`template`]))]))),128))]))),128))])]))),128))])):createCommentVNode(``,!0),selectedEntry.value.type===`quest`?(openBlock(),createElementBlock(`hr`,_hoisted_16$26)):createCommentVNode(``,!0),selectedEntry.value.type===`quest`?(openBlock(),createElementBlock(`div`,_hoisted_17$21,[_cache[2]||=createBaseVNode(`h4`,null,`Milestone Status`,-1),(openBlock(!0),createElementBlock(Fragment,null,renderList(selectedEntry.value.progress,prog=>(openBlock(),createElementBlock(`div`,null,[createBaseVNode(`div`,_hoisted_18$18,[createBaseVNode(`div`,_hoisted_19$15,[prog.done?(openBlock(),createBlock(unref(bngIcon_default),{key:0,class:`check-icon`,type:prog.failed?unref(icons).missionCheckboxCross:prog.done?unref(icons).checkboxOn:unref(icons).checkboxOff},null,8,[`type`])):createCommentVNode(``,!0),createBaseVNode(`div`,_hoisted_20$13,toDisplayString(_ctx.$ctx_t(prog.label)),1)]),prog.type===`progressBar`?(openBlock(),createElementBlock(`div`,_hoisted_21$12,[createBaseVNode(`div`,{class:`progressbar-fill`,style:normalizeStyle({width:(prog.currValue>0?prog.currValue/(prog.maxValue-prog.minValue)*100:0)+`%`})},null,4)])):createCommentVNode(``,!0)])]))),256))])):createCommentVNode(``,!0)],2)]),_:2},[selectedEntry.value.type===`quest`&&selectedEntry.value.rewards.length?{name:`footer`,fn:withCtx(()=>[createBaseVNode(`div`,_hoisted_22$10,[createBaseVNode(`div`,_hoisted_23$9,toDisplayString(_ctx.$t(`ui.career.logbook.rewards`))+`:`,1),createBaseVNode(`div`,_hoisted_24$8,[(openBlock(!0),createElementBlock(Fragment,null,renderList(selectedEntry.value.rewards,reward=>(openBlock(),createElementBlock(`div`,_hoisted_25$7,[createVNode(unref(bngUnit_default),mergeProps({class:`reward-icon`},{ref_for:!0},{[rewardUnitTypes[reward.attributeKey]]:reward.rewardAmount},{options:{formatter:x=>~~x}}),null,16,[`options`])]))),256))]),withDirectives((openBlock(),createBlock(unref(bngButton_default),{onClick:_cache[0]||=$event=>claimRewards(selectedEntry.value),disabled:!selectedEntry.value.claimable},{default:withCtx(()=>[createTextVNode(toDisplayString(_ctx.$t(`ui.career.logbook.claimRewards`)),1)]),_:1},8,[`disabled`])),[[vShow,!selectedEntry.value.claimed],[unref(BngSoundClass_default),`bng_click_generic`]]),withDirectives(createVNode(unref(bngButton_default),{disabled:!0},{default:withCtx(()=>[createTextVNode(toDisplayString(_ctx.$t(`ui.career.logbook.rewardsClaimed`)),1)]),_:1},512),[[vShow,selectedEntry.value.claimed]])])]),key:`0`}:void 0]),1536),[[vShow,selectedEntry.value!==void 0]])])])])),[[unref(BngOnUiNav_default),exit,`back,menu`],[unref(BngOnUiNav_default),sectionTabs.value&§ionTabs.value.goPrev,`tab_l`],[unref(BngOnUiNav_default),sectionTabs.value&§ionTabs.value.goNext,`tab_r`]])]),_:1})),[[unref(BngBlur_default)]])}},Logbook_default=__plugin_vue_export_helper_default(_sfc_main$245,[[`__scopeId`,`data-v-e8139034`]]),_hoisted_1$215={class:`milestones-wrapper`},_hoisted_2$174={"bng-ui-scope":`milestones`,class:`career-milestones-card`},_hoisted_3$153={class:`career-milestones-container`},_hoisted_4$128={class:`actions`},_hoisted_5$111={class:`filters`},_hoisted_6$94={class:`scrollable-container`,"bng-nav-scroll-force":``},_hoisted_7$82={class:`cards-container`},_sfc_main$244={__name:`Milestones`,props:{id:String},setup(__props){useUINavScope(`milestones`);let careerStatusRef=ref(),allEntries=[],entries=ref([]),selectOneFilters=ref(),selectedFilters=ref([`general`]),FILTER_OPTIONS=[{value:`general`,label:`General`},{value:`all`,label:`All`},{value:`mission`,label:`Challenges`},{value:`branch`,label:`Branches`},{value:`delivery`,label:`Delivery`},{value:`money`,label:`Money`},{value:`speedTrap`,label:`Speed Traps`},{value:`insurance`,label:`Insurance`}];function sortMilestones(){entries.value.sort(function(a$1,b){return a$1.claimable&&!b.claimable?-1:b.claimable&&!a$1.claimable?1:!a$1.completed&&b.completed?-1:a$1.completed&&!b.completed?1:a$1.claimId!0):entries.value=allEntries.filter(e=>e.filter[currentFilter]),sortMilestones()}function filterChanged(filterList){filterList&&(currentFilter=filterList[0]),filterEntries()}function setup$3(data){allEntries=data.list;let hasClaimable=!1;data.list.forEach(x=>{x.claimable&&(hasClaimable=!0)}),hasClaimable&&(selectedFilters.value=[`all`],filterChanged(selectedFilters.value)),filterEntries()}Lua_default.career_modules_milestones_milestones.getMilestones().then(setup$3);let claimMilestone=entry=>{Lua_default.career_modules_milestones_milestones.claim(entry.claimId).then(replacementEntry=>{careerStatusRef.value.updateDisplay();let replacementId=allEntries.findIndex(item=>item.claimId===entry.claimId);if(replacementEntry!=null&&replacementId!==-1){allEntries[replacementId]=replacementEntry,filterEntries();return}allEntries[replacementId].claimable=!1,filterEntries()})},exit=()=>{window.bngVue.gotoGameState(`progressLanding`)};return onUnmounted(()=>{Lua_default.simTimeAuthority.popPauseRequest(`milestones`)}),onBeforeMount(()=>{Lua_default.simTimeAuthority.pushPauseRequest(`milestones`)}),(_ctx,_cache)=>withDirectives((openBlock(),createBlock(unref(layoutSingle_default),{class:`milestones-layout`},{default:withCtx(()=>[createBaseVNode(`div`,_hoisted_1$215,[createVNode(unref(bngScreenHeading_default),null,{default:withCtx(()=>[..._cache[1]||=[createTextVNode(`Milestones`,-1)]]),_:1}),withDirectives((openBlock(),createElementBlock(`div`,_hoisted_2$174,[createBaseVNode(`div`,_hoisted_3$153,[createBaseVNode(`div`,_hoisted_4$128,[createVNode(unref(bngButton_default),{class:`exitButton`,onClick:exit,accent:unref(ACCENTS).attention},{default:withCtx(()=>[createVNode(unref(bngBinding_default),{tabindex:`1`,"ui-event":`back`,deviceMask:`xinput`}),_cache[2]||=createTextVNode(`Back`,-1)]),_:1},8,[`accent`]),createVNode(unref(careerStatus_default),{class:`career-page-status`,ref_key:`careerStatusRef`,ref:careerStatusRef},null,512)]),createBaseVNode(`div`,_hoisted_5$111,[createVNode(unref(bngIcon_default),{class:`career-filter-icon`,type:unref(icons).filter},null,8,[`type`]),createVNode(unref(bngPillFilters_default),{required:``,ref_key:`selectOneFilters`,ref:selectOneFilters,modelValue:selectedFilters.value,"onUpdate:modelValue":_cache[0]||=$event=>selectedFilters.value=$event,options:FILTER_OPTIONS,onValueChanged:filterChanged},null,8,[`modelValue`])]),createBaseVNode(`div`,_hoisted_6$94,[createBaseVNode(`div`,_hoisted_7$82,[(openBlock(!0),createElementBlock(Fragment,null,renderList(entries.value,entry=>withDirectives((openBlock(),createBlock(MilestoneCard_default,{tabindex:`1`,milestone:entry,isCondensed:!1,onClaim:claimMilestone},null,8,[`milestone`])),[[unref(BngSoundClass_default),entry.claimable?`bng_click_hover_generic`:`bng_hover_generic`]])),256))])])])])),[[unref(BngOnUiNav_default),exit,`back,menu`],[unref(BngOnUiNav_default),selectOneFilters.value&&selectOneFilters.value.focusPrevious,`tab_l`],[unref(BngOnUiNav_default),selectOneFilters.value&&selectOneFilters.value.focusNext,`tab_r`]])])]),_:1})),[[unref(BngOnUiNav_default),exit,`back,menu`],[unref(BngBlur_default)]])}},Milestones_default=__plugin_vue_export_helper_default(_sfc_main$244,[[`__scopeId`,`data-v-798d8c2a`]]),_hoisted_1$214={class:`panel-flex`},_hoisted_2$173={style:{"overflow-y":`scroll`}},_hoisted_3$152={class:`content-row selected-and-map-panel`},_hoisted_4$127={key:0,class:`content`},TAB_HEADINGS={parcels:`Parcels`,smallFluids:`Fluid Orders`,largeFluids:`Fluid Custom`,smallDryBulk:`Dry Bulk Orders`,largeDryBulk:`Dry Bulk Custom`,vehicles:`Vehicles`,trailers:`Trailers`,loaners:`Loaners`},_sfc_main$243={__name:`MyCargo`,props:{facilityId:String,parkingSpotPath:String},setup(__props){ref(3),ref(1);let{events:events$3}=useBridge();useUINavScope(`myCargo`);let props=__props;ref(null),ref(),ref(TAB_HEADINGS.parcels),ref(),ref();let cargoOverviewStore=useCargoOverviewStore(),updateCargoDataAll=()=>{cargoOverviewStore.requestCargoData(props.facilityId,props.parkingSpotPath)},close=()=>{Lua_default.career_modules_delivery_cargoScreen.exitCargoOverviewScreen()};return events$3.on(`updateCargoData`,updateCargoDataAll),onMounted(()=>{Lua_default.career_modules_delivery_cargoScreen.setCargoScreenTab(`all`),updateCargoDataAll()}),onUnmounted(()=>{cargoOverviewStore.menuClosed(),events$3.off(`updateCargoData`,updateCargoDataAll)}),(_ctx,_cache)=>(openBlock(),createElementBlock(Fragment,null,[_cache[22]||=createBaseVNode(`div`,{style:{color:`white`}},`#Hello`,-1),unref(cargoOverviewStore).cargoData?(openBlock(),createBlock(ComputerWrapper_default,{key:0,path:[`My Cargo`],title:`My Cargo 2`,back:``,onBack:close},{status:withCtx(()=>[..._cache[10]||=[createTextVNode(` Delivery Lvl 2 | Car Jockey Lvl 3 | Facility Reputation: Good `,-1)]]),top:withCtx(()=>[..._cache[11]||=[createBaseVNode(`div`,{style:{width:`100%`,padding:`0.3em`,background:`#8888ff`}},` FILTERTABS `,-1)]]),default:withCtx(()=>[createBaseVNode(`div`,_hoisted_1$214,[createVNode(unref(bngCard_default),{class:`content-row provided-orders-panel`},{default:withCtx(()=>[createVNode(unref(bngCardHeading_default),{type:`ribbon`,class:`cardHeading`},{default:withCtx(()=>[..._cache[12]||=[createTextVNode(` My Cargo `,-1)]]),_:1}),createVNode(unref(bngSwitch_default),{modelValue:unref(cargoOverviewStore).automaticRoute,"onUpdate:modelValue":_cache[0]||=$event=>unref(cargoOverviewStore).automaticRoute=$event},{default:withCtx(()=>[..._cache[13]||=[createTextVNode(` Automatic route `,-1)]]),_:1},8,[`modelValue`]),createVNode(unref(bngSlider_default),{min:0,max:unref(cargoOverviewStore).cargoData.playerCardGroupSets.length-1,step:1,modelValue:unref(cargoOverviewStore).playerGroupingIdx,"onUpdate:modelValue":_cache[1]||=$event=>unref(cargoOverviewStore).playerGroupingIdx=$event,onChange:unref(cargoOverviewStore).setGroupingAndSorting},null,8,[`max`,`modelValue`,`onChange`]),createVNode(unref(bngSlider_default),{min:0,max:unref(cargoOverviewStore).cargoData.sortingSets.length-1,step:1,modelValue:unref(cargoOverviewStore).playerSortingIdx,"onUpdate:modelValue":_cache[2]||=$event=>unref(cargoOverviewStore).playerSortingIdx=$event,onChange:unref(cargoOverviewStore).setGroupingAndSorting},null,8,[`max`,`modelValue`,`onChange`]),createVNode(unref(bngCardHeading_default),{type:`ribbon`,class:`cardHeading`},{default:withCtx(()=>[createTextVNode(` Grouped `+toDisplayString(unref(cargoOverviewStore).cargoData.playerCardGroupSets[unref(cargoOverviewStore).playerGroupingIdx].label)+`, Sorted `+toDisplayString(unref(cargoOverviewStore).cargoData.sortingSets[unref(cargoOverviewStore).playerSortingIdx].label),1)]),_:1}),createBaseVNode(`div`,_hoisted_2$173,[createVNode(ProvidedOrdersPanel_default,{groupSets:unref(cargoOverviewStore).cargoData.playerCardGroupSets,groupIdx:unref(cargoOverviewStore).playerGroupingIdx,sortingSets:unref(cargoOverviewStore).cargoData.sortingSets,sortIdx:unref(cargoOverviewStore).playerSortingIdx,onCardHovered:unref(cargoOverviewStore).cardHovered,onCardClicked:unref(cargoOverviewStore).cardClicked},null,8,[`groupSets`,`groupIdx`,`sortingSets`,`sortIdx`,`onCardHovered`,`onCardClicked`])])]),_:1}),createBaseVNode(`div`,_hoisted_3$152,[createVNode(unref(bngCard_default),{class:`cargo-detail`},createSlots({default:withCtx(()=>[createVNode(unref(bngCardHeading_default),{type:`ribbon`,class:`cardHeading`},{default:withCtx(()=>[..._cache[14]||=[createTextVNode(` Details View `,-1)]]),_:1}),unref(cargoOverviewStore).focusedCargo?(openBlock(),createElementBlock(`div`,_hoisted_4$127,[createVNode(CargoCard_default,{card:unref(cargoOverviewStore).focusedCargo,detailed:``},null,8,[`card`])])):createCommentVNode(``,!0)]),_:2},[unref(cargoOverviewStore).focusedCargo?{name:`buttons`,fn:withCtx(()=>[unref(cargoOverviewStore).focusedCargo.cardType==`parcelGroup`?(openBlock(),createElementBlock(Fragment,{key:0},[unref(cargoOverviewStore).focusedCargo.isFacilityCard?(openBlock(),createElementBlock(Fragment,{key:0},[createVNode(unref(bngButton_default),{disabled:!unref(cargoOverviewStore).focusedCargo.enabled||unref(cargoOverviewStore).focusedCargo.transientMoveCounts==0,accent:`text`,onClick:_cache[3]||=$event=>unref(cargoOverviewStore).clearLoad(unref(cargoOverviewStore).focusedCargo)},{default:withCtx(()=>[..._cache[15]||=[createTextVNode(` Clear Load `,-1)]]),_:1},8,[`disabled`]),createVNode(unref(bngButton_default),{disabled:!unref(cargoOverviewStore).focusedCargo.enabled||unref(cargoOverviewStore).focusedCargo.autoLoadLocations&&unref(cargoOverviewStore).focusedCargo.autoLoadLocations.length==0,accent:`text`,onClick:_cache[4]||=$event=>unref(cargoOverviewStore).loadCargoCustom(unref(cargoOverviewStore).focusedCargo)},{default:withCtx(()=>[..._cache[16]||=[createTextVNode(` Custom Load `,-1)]]),_:1},8,[`disabled`]),createVNode(unref(bngButton_default),{disabled:!unref(cargoOverviewStore).focusedCargo.enabled||unref(cargoOverviewStore).focusedCargo.autoLoadLocations&&unref(cargoOverviewStore).focusedCargo.autoLoadLocations.length<=unref(cargoOverviewStore).focusedCargo.transientMoveCounts,onClick:_cache[5]||=$event=>unref(cargoOverviewStore).loadCargoAuto(unref(cargoOverviewStore).focusedCargo)},{default:withCtx(()=>[..._cache[17]||=[createTextVNode(` Auto Load `,-1)]]),_:1},8,[`disabled`])],64)):createCommentVNode(``,!0),unref(cargoOverviewStore).focusedCargo.isPlayerCard?(openBlock(),createElementBlock(Fragment,{key:1},[createVNode(unref(bngButton_default),{accent:`text`,disabled:unref(cargoOverviewStore).focusedCargo.transientCargo,onClick:_cache[6]||=$event=>unref(cargoOverviewStore).changeDistribution(unref(cargoOverviewStore).focusedCargo)},{default:withCtx(()=>[..._cache[18]||=[createTextVNode(` Change Distribution `,-1)]]),_:1},8,[`disabled`]),createVNode(unref(bngButton_default),{disabled:unref(cargoOverviewStore).focusedCargo.transientCargo,onClick:_cache[7]||=$event=>unref(cargoOverviewStore).clearLoad(unref(cargoOverviewStore).focusedCargo)},{default:withCtx(()=>[..._cache[19]||=[createTextVNode(` Clear Load `,-1)]]),_:1},8,[`disabled`])],64)):createCommentVNode(``,!0)],64)):createCommentVNode(``,!0),unref(cargoOverviewStore).focusedCargo.cardType==`storage`?(openBlock(),createElementBlock(Fragment,{key:1},[unref(cargoOverviewStore).focusedCargo.isFacilityCard?(openBlock(),createBlock(unref(bngButton_default),{key:0,disabled:!unref(cargoOverviewStore).focusedCargo.enabled,onClick:_cache[8]||=$event=>unref(cargoOverviewStore).loadStorageCustom(unref(cargoOverviewStore).focusedCargo)},{default:withCtx(()=>[..._cache[20]||=[createTextVNode(` Load Custom `,-1)]]),_:1},8,[`disabled`])):createCommentVNode(``,!0)],64)):createCommentVNode(``,!0),unref(cargoOverviewStore).focusedCargo.cardType==`vehicleOffer`?(openBlock(),createBlock(unref(bngButton_default),{key:2,disabled:!unref(cargoOverviewStore).focusedCargo.enabled,onClick:_cache[9]||=$event=>unref(cargoOverviewStore).loadOffer(unref(cargoOverviewStore).focusedCargo)},{default:withCtx(()=>[createTextVNode(toDisplayString(unref(cargoOverviewStore).focusedCargo.spawnWhenCommitingCargo?`Don't bring out`:`Bring Out`),1)]),_:1},8,[`disabled`])):createCommentVNode(``,!0)]),key:`0`}:void 0]),1024),createVNode(unref(bngCard_default),{class:`map`},{default:withCtx(()=>[..._cache[21]||=[createTextVNode(` Map Screen `,-1)]]),_:1})])])]),_:1})):createCommentVNode(``,!0)],64))}},MyCargo_default=__plugin_vue_export_helper_default(_sfc_main$243,[[`__scopeId`,`data-v-9a756c16`]]),_hoisted_1$213={class:`paint-presets`},_hoisted_2$172={class:`paint-presets-group`},_hoisted_3$151={class:`paint-presets-name`},_hoisted_4$126={class:`presets-items`},_sfc_main$242={__name:`PaintPresets`,props:{presets:{type:Object,required:!0},showText:{type:Boolean,default:!1},editable:{type:Boolean,default:!1},current:{type:Object}},emits:[`apply`],setup(__props,{emit:__emit}){let settings$1=useSettings(),props=__props,emit$1=__emit,factoryPresets=computed(()=>{let presets=props.presets,factoryRes={},customRes={};if(typeof presets==`object`&&!Array.isArray(presets)){let paint=new Paint;for(let name in presets)try{paint.paint=presets[name];let paintObject=paint.paintObject;presets[name]&&typeof presets[name]==`object`&&presets[name].class===`custom`?customRes[name]=paintObject:factoryRes[name]=paintObject}catch{}}return{factory:factoryRes,custom:customRes}}),userPresets=ref({}),presetGroups=computed(()=>{let res=[];Object.keys(factoryPresets.value.factory).length&&res.push({name:`factory`,showTooltip:!0,editable:!1,presets:factoryPresets.value.factory}),Object.keys(factoryPresets.value.custom).length&&res.push({name:`custom`,showTooltip:!0,editable:!1,presets:factoryPresets.value.custom}),props.editable&&res.push({name:`user`,showTooltip:!1,editable:!0,presets:userPresets.value||{}});for(let group of res){let presets=Object.keys(group.presets).map(colname=>({name:colname,...group.presets[colname],css:`rgb(${group.presets[colname].baseColor.slice(0,3).map(val=>val*255)})`}));group.name!==`user`&&(presets=sortColors(presets)),group.presets=presets}return res});function average(arr){return arr.reduce((a$1,b)=>a$1+b)/arr.length}function valComparable(col,thres=.05){let bool=!0,av=average(col);for(let i=0;i=col[i];return bool&&=av>.8||av<.2,bool}function colorHigherHelper(itm){let av=average(itm.orig.baseColor.slice(0,3)),al=itm.orig.baseColor[3]/2,res=Math.abs(av-1)*al;return res===0?(av+al)/2:res+1}function colorHigher(a$1,b){let aColor=valComparable(a$1.orig.baseColor.slice(0,3)),bColor=valComparable(b.orig.baseColor.slice(0,3));if(aColor&&bColor)return colorHigherHelper(b)-colorHigherHelper(a$1);if(aColor&&!bColor)return 1;if(!aColor&&bColor)return-1;for(let i=0;i<3;i++)if(a$1.val[i]!==b.val[i])return a$1.val[i]-b.val[i];return 0}function colorValue(arr){let repitions=8,rgb=[];for(let i=0;i<3;i++)rgb[i]=(1-arr[3]/2)*arr[i]+arr[3]/2*arr[i];let lum=Math.sqrt(.241*rgb[0]+.691*rgb[1]+.068*rgb[2]),hsl=Paint.rgbToHsl(rgb),out=[hsl[0],lum,hsl[1]].map(elem=>elem*8);return out[0]%2==1&&(out[1]=8-out[1],out[2]=8-out[2]),out.push(arr[3]),out}function sortColors(list){return list.map(elem=>({val:colorValue(elem.baseColor),orig:elem})).sort(colorHigher).map(elem=>elem.orig)}function addPreset(){if(!props.current)return;let colour={...props.current,baseColor:toRaw(props.current.baseColor)},idx=1;for(;`Custom ${idx}`in userPresets.value;)idx++;let presetName=`Custom ${idx}`;userPresets.value[presetName]=colour,savePresets(),nextTick(()=>{let presetElements=document.querySelectorAll(`.paint-presets-item`),newPreset=Array.from(presetElements).find(el=>el.getAttribute(`data-preset-name`)===presetName);newPreset&&setFocusExternal(newPreset)})}function removePreset(name){let presetElements=document.querySelectorAll(`.paint-presets-item`),currentIndex=Array.from(presetElements).findIndex(el=>el.getAttribute(`data-preset-name`)===name);delete userPresets.value[name],savePresets(),nextTick(()=>{let group=presetGroups.value.find(g=>g.name===`user`);if(group)if(group.presets.length>0){let newPresetElements=document.querySelectorAll(`.paint-presets-item`);setFocusExternal(newPresetElements[Math.min(currentIndex,newPresetElements.length-1)])}else{let addButton=document.querySelector(`.presets-empty`);addButton&&setFocusExternal(addButton)}})}function savePresets(){settings$1.apply({userPaintPresets:JSON.stringify(Object.values(userPresets.value))})}return onMounted(async()=>{await settings$1.waitForData();let paints={};if(settings$1.values.userPaintPresets&&(paints=JSON.parse(settings$1.values.userPaintPresets.replace(/'/g,`"`)),typeof paints==`object`)){Array.isArray(paints)&&(paints=paints.reduce((res,paint,idx)=>({...res,[`Custom ${idx}`]:paint}),{}));let test=new Paint;for(let name in paints)try{test.paint=paints[name],paints[name]=test.paintObject}catch{delete paints[name]}}userPresets.value=paints}),(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$213,[(openBlock(!0),createElementBlock(Fragment,null,renderList(presetGroups.value,group=>(openBlock(),createElementBlock(`div`,_hoisted_2$172,[createBaseVNode(`span`,_hoisted_3$151,toDisplayString(_ctx.$t(`ui.color.${group.name}`))+`: `,1),createBaseVNode(`div`,_hoisted_4$126,[(openBlock(!0),createElementBlock(Fragment,null,renderList(group.presets,(preset,index)=>(openBlock(),createBlock(unref(bngPaintTile_default),{key:`${index}#${preset.name}`,size:24,paint:preset,"vehicle-name":`factory`,"paint-name":preset.name,"tooltip-position":`top`,class:`paint-presets-item`,"data-preset-name":preset.name,"with-menu":__props.editable&&group.editable,"custom-menu":[{label:`ui.common.delete`,action:()=>removePreset(preset.name)}],onClick:$event=>emit$1(`apply`,preset)},null,8,[`paint`,`paint-name`,`data-preset-name`,`with-menu`,`custom-menu`,`onClick`]))),128)),!group.presets||Object.keys(group.presets).length===0?withDirectives((openBlock(),createBlock(unref(bngButton_default),{key:0,class:`presets-empty`,accent:unref(ACCENTS).text,onClick:addPreset,"bng-nav-item":``},{default:withCtx(()=>[createTextVNode(toDisplayString(_ctx.$t(`ui.colorpicker.noPresets`)),1)]),_:1},8,[`accent`])),[[unref(BngOnUiNav_default),void 0,`ok`,{asMouse:!0,focusRequired:!0}]]):createCommentVNode(``,!0),group.presets&&Object.keys(group.presets).length>0&&__props.editable&&group.editable?withDirectives((openBlock(),createBlock(unref(bngButton_default),{key:1,class:`paint-presets-button`,accent:unref(ACCENTS).text,onClick:addPreset,icon:unref(icons).mathPlus,"bng-nav-item":``},null,8,[`accent`,`icon`])),[[unref(BngTooltip_default),_ctx.$t(`ui.colorpicker.colToPre`),`top`],[unref(BngOnUiNav_default),void 0,`ok`,{asMouse:!0,focusRequired:!0}]]):createCommentVNode(``,!0)])]))),256))]))}},PaintPresets_default=__plugin_vue_export_helper_default(_sfc_main$242,[[`__scopeId`,`data-v-469b2f89`]]),_hoisted_1$212={class:`paint-picker`},_hoisted_2$171={key:0,class:`paint-flex`},_hoisted_3$150={key:0,class:`paint-preview`,xmlns:`http://www.w3.org/2000/svg`,viewBox:`0 0 1 1`,preserveAspectRatio:`xMidYMid meet`},_hoisted_4$125={id:`light`,cy:`0.28`,cx:`0.35`,r:`0.3`,spreadMethod:`pad`},_hoisted_5$110=[`offset`],_hoisted_6$93=[`offset`],_hoisted_7$81={id:`colPreview`,x:`0`,y:`0`,width:`1`,height:`1`,patternUnits:`userSpaceOnUse`},_hoisted_8$67=[`fill`],_hoisted_9$60={key:1},_hoisted_10$51={key:0},_hoisted_11$45={key:2},_hoisted_12$34={key:0},_sfc_main$241={__name:`PaintPicker`,props:{modelValue:{type:[String,Object]},legacy:{type:Boolean,default:!1},presets:{type:Object,default:{}},presetsEditable:{type:Boolean,default:!1},showPresets:{type:Boolean,default:!0},showMain:{type:Boolean,default:!0},pickerMode:{type:String,default:`full_luminosity`},showText:{type:Boolean,default:!0},showPreview:{type:Boolean,default:!1},advancedOpen:{type:Boolean,default:!1},showAdvancedSwitch:{type:Boolean,default:!0}},emits:[`update:modelValue`,`change`],setup(__props,{expose:__expose,emit:__emit}){let props=__props;__expose({paintUpdated,setAdvancedVisible}),watch(()=>props.modelValue,init$3);let emitter=__emit,advanced=ref(props.advancedOpen),paint=reactive(new Paint({legacy:props.legacy}));watch(()=>props.legacy,val=>paint.legacy=val);let paintPicker=ref(paint),isPaintObject=!1,factoryPresets=computed(()=>props.presets||{}),hslColour=computed(()=>Paint.hslCssStr(paint.hsl));function init$3(){let defPaint=[1,1,1,1,0,1,1,0];if(!props.modelValue){paint.paint=defPaint;return}if(isPaintObject=props.modelValue instanceof Paint,isPaintObject){paint.paint=props.modelValue.paintObject;return}let newpaint=new Paint({legacy:props.legacy});try{newpaint.paint=props.modelValue}catch{newpaint.paint=defPaint}newpaint.paintString!==paint.paintString&&(paint.paint=newpaint.paintObject)}function returnPaint(){let res;isPaintObject?(res=props.modelValue,res.paint=paint.paintObject):res=paint.paintString,emitter(`change`,res),emitter(`update:modelValue`,res)}function paintUpdated(){init$3(),returnPaint()}function setAdvancedVisible(visible){advanced.value=visible}function applyPreset(preset){paint.paint=preset,returnPaint()}return init$3(),(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$212,[__props.showPreview||__props.showPresets?(openBlock(),createElementBlock(`div`,_hoisted_2$171,[__props.showPreview?(openBlock(),createElementBlock(`svg`,_hoisted_3$150,[createBaseVNode(`defs`,null,[createBaseVNode(`radialGradient`,_hoisted_4$125,[createBaseVNode(`stop`,mergeProps({offset:.1+.2*(1-paint.roughness)},{"stop-opacity":.4+.2*paint.roughness},{"stop-color":`#fff`}),null,16,_hoisted_5$110),createBaseVNode(`stop`,{offset:1-paint.roughness*.5,"stop-opacity":`0.0`,"stop-color":`#fff`},null,8,_hoisted_6$93)]),_cache[16]||=createBaseVNode(`radialGradient`,{id:`shadow`,cy:`0.43`,cx:`0.45`,r:`0.55`,spreadMethod:`pad`},[createBaseVNode(`stop`,{offset:`0.7`,"stop-opacity":`0.0`,"stop-color":`#000`}),createBaseVNode(`stop`,{offset:`0.85`,"stop-opacity":`0.2`,"stop-color":`#000`}),createBaseVNode(`stop`,{offset:`1.0`,"stop-opacity":`0.5`,"stop-color":`#000`})],-1),createBaseVNode(`pattern`,_hoisted_7$81,[_cache[13]||=createBaseVNode(`image`,{x:`0`,y:`0`,height:`1`,width:`1`,"xlink:href":`/ui/lib/int/colorpicker/color-chrome.png`},null,-1),createBaseVNode(`rect`,mergeProps({y:`0`,x:`0`,width:`1`,height:`1`,fill:`hsl(${hslColour.value})`},{"fill-opacity":paint.alpha/2},{stroke:`transparent`}),null,16,_hoisted_8$67),_cache[14]||=createBaseVNode(`rect`,{y:`0`,x:`0`,width:`1`,height:`1`,fill:`url(#light)`,stroke:`transparent`},null,-1),_cache[15]||=createBaseVNode(`rect`,{y:`0`,x:`0`,width:`1`,height:`1`,fill:`url(#shadow)`,stroke:`transparent`},null,-1)])]),_cache[17]||=createBaseVNode(`circle`,{cy:`0.5`,cx:`0.5`,r:`0.5`,fill:`url(#colPreview)`,stroke:`transparent`},null,-1)])):createCommentVNode(``,!0),__props.showPresets?(openBlock(),createBlock(PaintPresets_default,{key:1,presets:factoryPresets.value,"show-text":__props.showText,editable:__props.presetsEditable,current:paint.paintObject,onApply:applyPreset},null,8,[`presets`,`show-text`,`editable`,`current`])):createCommentVNode(``,!0)])):createCommentVNode(``,!0),__props.showMain?(openBlock(),createElementBlock(`div`,_hoisted_9$60,[__props.showText&&_ctx.$slots.default?(openBlock(),createElementBlock(`span`,_hoisted_10$51,[renderSlot(_ctx.$slots,`default`,{},void 0,!0)])):createCommentVNode(``,!0),createVNode(unref(bngColorPicker_default),{modelValue:paintPicker.value,"onUpdate:modelValue":_cache[0]||=$event=>paintPicker.value=$event,onChange:_cache[1]||=$event=>returnPaint(),view:__props.pickerMode,"show-text":__props.showText},null,8,[`modelValue`,`view`,`show-text`])])):createCommentVNode(``,!0),__props.showMain?(openBlock(),createElementBlock(`div`,_hoisted_11$45,[__props.showAdvancedSwitch?(openBlock(),createElementBlock(`h3`,_hoisted_12$34,[createVNode(unref(bngSwitch_default),{modelValue:advanced.value,"onUpdate:modelValue":_cache[2]||=$event=>advanced.value=$event},{default:withCtx(()=>[createTextVNode(toDisplayString(_ctx.$t(`ui.color.configurations`)),1)]),_:1},8,[`modelValue`])])):createCommentVNode(``,!0),advanced.value?(openBlock(),createElementBlock(`div`,{key:1,class:normalizeClass([`paint-slider-group`,{"paint-slider-group-fullrow":_ctx.$simplemenu.value}])},[__props.legacy?(openBlock(),createBlock(unref(bngColorSlider_default),{key:0,modelValue:paint.alpha,"onUpdate:modelValue":_cache[3]||=$event=>paint.alpha=$event,max:2,onChange:_cache[4]||=$event=>returnPaint(),fill:[`hsla(${hslColour.value}, 0)`,`hsla(${hslColour.value}, 2)`]},{default:withCtx(()=>[createTextVNode(toDisplayString(__props.showText?`${_ctx.$t(`ui.color.chrominess`)} (${paint.alphaPercent}%)`:null),1)]),_:1},8,[`modelValue`,`fill`])):createCommentVNode(``,!0),createVNode(unref(bngColorSlider_default),{modelValue:paint.metallic,"onUpdate:modelValue":_cache[5]||=$event=>paint.metallic=$event,onChange:_cache[6]||=$event=>returnPaint()},{default:withCtx(()=>[createTextVNode(toDisplayString(__props.showText?`${_ctx.$t(`ui.color.metallic`)} (${paint.metallicPercent}%)`:null),1)]),_:1},8,[`modelValue`]),createVNode(unref(bngColorSlider_default),{modelValue:paint.roughness,"onUpdate:modelValue":_cache[7]||=$event=>paint.roughness=$event,onChange:_cache[8]||=$event=>returnPaint()},{default:withCtx(()=>[createTextVNode(toDisplayString(__props.showText?`${_ctx.$t(`ui.color.roughness`)} (${paint.roughnessPercent}%)`:null),1)]),_:1},8,[`modelValue`]),createVNode(unref(bngColorSlider_default),{modelValue:paint.clearcoat,"onUpdate:modelValue":_cache[9]||=$event=>paint.clearcoat=$event,onChange:_cache[10]||=$event=>returnPaint()},{default:withCtx(()=>[createTextVNode(toDisplayString(__props.showText?`${_ctx.$t(`ui.color.clearCoat`)} (${paint.clearcoatPercent}%)`:null),1)]),_:1},8,[`modelValue`]),createVNode(unref(bngColorSlider_default),{modelValue:paint.clearcoatRoughness,"onUpdate:modelValue":_cache[11]||=$event=>paint.clearcoatRoughness=$event,onChange:_cache[12]||=$event=>returnPaint()},{default:withCtx(()=>[createTextVNode(toDisplayString(__props.showText?`${_ctx.$t(`ui.color.clearCoatRoughness`)} (${paint.clearcoatRoughnessPercent}%)`:null),1)]),_:1},8,[`modelValue`])],2)):createCommentVNode(``,!0)])):createCommentVNode(``,!0)]))}},PaintPicker_default=__plugin_vue_export_helper_default(_sfc_main$241,[[`__scopeId`,`data-v-2d18c0ad`]]),_hoisted_1$211={class:`paintingWrapper`},_hoisted_2$170={style:{overflow:`auto`}},_hoisted_3$149=[`tab-heading`],_hoisted_4$124={class:`paintPicker`},_hoisted_5$109={key:0,class:`clearCoatSection`},_hoisted_6$92={key:0,class:`innerShoppingCart`},_hoisted_7$80={class:`shoppingCartTable`},_hoisted_8$66={class:`price`},_hoisted_9$59={class:`price--total`},_hoisted_10$50={class:`purchase-button-container`},_sfc_main$240={__name:`Painting`,props:{noHeader:Boolean},setup(__props,{expose:__expose}){let{units,events:events$3}=useBridge(),presets=ref({});Lua_default.career_modules_painting.getFactoryPaint().then(data=>presets.value=data);let colorClass=ref(`factory`),paintIndex=ref(0),chosenPackage=ref([{},{},{}]),changedPaint=ref(!1),totalPrice=ref(0),clearCoatActive=ref(!1),clearCoatPolish=ref(0),paints=ref([]),originalPaints=ref([]),prices=ref({}),colorClassData=ref({}),canPay=ref(!1),paintPicker=ref(null),paintClassTabInfo=[{title:`Factory`},{title:`Gloss`,paintClasses:[{id:`matte`,title:`Matte`},{id:`semiGloss`,title:`Semi Gloss`},{id:`gloss`,title:`Full Gloss`}]},{title:`Metallic`,paintClasses:[{id:`semiMetallic`,title:`Semi Metallic`},{id:`metallic`,title:`Metallic`},{id:`chrome`,title:`Chrome`}]},{title:`Custom`}],clearCoatUpdateCallback=newValue=>{clearCoatPolish.value=0,changeClearCoatPolish(0),enableClearCoat(newValue)},enableClearCoat=enabled=>{paints.value[paintIndex.value]._clearcoat=enabled?1:0,paintPicker.value.paintUpdated()},changeClearCoatPolish=value=>{paints.value[paintIndex.value]._clearcoatRoughness=-.13*value+.13,paintPicker.value.paintUpdated()},getShoppingCartTable=()=>{let res=[];for(let[index,paintOptions]of chosenPackage.value.entries())Object.keys(paintOptions).length&&(res.push({name:`Paint `+(index+1)+`: `+getNicePaintClassName(paintOptions.paintClass),price:prices.value.basePrices[paintOptions.paintClass].money.amount,topLevel:!0,index}),paintOptions.clearCoat&&(res.push({name:`Clearcoat`,price:prices.value.clearcoatBase.money.amount}),res.push({name:`Extra Clearcoat Polish`,price:prices.value.clearcoatPolishFactor.money.amount*paintOptions.clearCoatPolish})));return res};events$3.on(`sendPaintingShoppingCartData`,data=>{canPay.value=data.canPay,totalPrice.value=data.totalPrice.money.amount}),Lua_default.career_modules_painting.getPaintData().then(data=>{if(prices.value=data.prices,!data||!Array.isArray(data.colors)){paints.value=[];return}paints.value=data.colors.map(val=>new Paint({paint:val})),originalPaints.value=data.colors.map(val=>new Paint({paint:val})),colorClassData.value=data.colorClassData});let getPickerShowPresets=()=>colorClass.value==`factory`,getPickerPresetsEditable=()=>colorClass.value==`custom`,showPickerMain=()=>colorClass.value!=`factory`,showClearCoatOption=()=>colorClass.value!=`factory`&&colorClass.value!=`custom`,setCurrentColorClass=()=>{paintPicker.value.setAdvancedVisible(!1),paints.value[paintIndex.value]._metallic=colorClassData.value[colorClass.value].metallic,paints.value[paintIndex.value]._roughness=colorClassData.value[colorClass.value].roughness,clearCoatActive.value=!1,enableClearCoat(!1)},changedPaintIndexTab=tab=>{paintIndex.value=tab.index,colorClass.value=chosenPackage.value[paintIndex.value].paintClass||`factory`,paintPicker.value.setAdvancedVisible(colorClass.value==`custom`),clearCoatActive.value=chosenPackage.value[paintIndex.value].clearCoat,clearCoatPolish.value=chosenPackage.value[paintIndex.value].clearCoatPolish},changedTopLevelPaintClassTab=tab=>{let classTab={Factory:`factory`,Custom:`custom`,Gloss:`semiGloss`,Metallic:`metallic`}[tab.heading];classTab&&changedPaintClassTab(classTab)},changedPaintClassTab=paintClass=>{if(paintClass==`factory`){colorClass.value=`factory`;return}if(paintClass==`custom`){colorClass.value=`custom`,paintPicker.value.setAdvancedVisible(!0),clearCoatActive.value=!1;return}colorClass.value=paintClass,setCurrentColorClass()};function resetPaint(index){chosenPackage.value[index]={},Object.assign(paints.value[index],originalPaints.value[index]);let chosenPackageEmpty=!0;for(let[index$1,color]of Object.entries(chosenPackage.value))Object.keys(color).length!==0&&(chosenPackageEmpty=!1);chosenPackageEmpty&&(changedPaint.value=!1),Lua_default.career_modules_painting.setPaints(paints.value.map(paint=>paint.paintObject),chosenPackage.value)}function onChange(){colorClass.value==`factory`&&(clearCoatActive.value=!1),chosenPackage.value[paintIndex.value].paintClass=colorClass.value,chosenPackage.value[paintIndex.value].clearCoat=clearCoatActive.value,chosenPackage.value[paintIndex.value].clearCoatPolish=clearCoatPolish.value,changedPaint.value=!0,Lua_default.career_modules_painting.setPaints(paints.value.map(paint=>paint.paintObject),chosenPackage.value)}let NICE_PAINT_CLASS_NAMES={factory:`Factory`,semiGloss:`Semi Gloss`,gloss:`Gloss`,semiMetallic:`Semi Metallic`,metallic:`Metallic`,matte:`Matte`,chrome:`Chrome`,custom:`Custom`},getNicePaintClassName=paintClass=>NICE_PAINT_CLASS_NAMES[paintClass];function headerClass(tab){return{"painting-tab":!0,[`painting-tab-${tab.index}`]:!0}}let headerVars=computed(()=>paints.value.reduce((res,paint,idx)=>({...res,[`--painting-dot-${idx}`]:`hsl(${Paint.hslCssStr(paint.hsl)})`}),{})),apply$1=()=>Lua_default.career_modules_painting.apply(),close=()=>Lua_default.career_modules_painting.close();return onMounted(()=>{Lua_default.career_modules_painting.onUIOpened()}),onUnmounted(close),__expose({apply:apply$1,close}),(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$211,[withDirectives((openBlock(),createBlock(unref(bngCard_default),{class:`paintingPage`},{default:withCtx(()=>[createBaseVNode(`div`,_hoisted_2$170,[__props.noHeader?createCommentVNode(``,!0):(openBlock(),createBlock(unref(bngCardHeading_default),{key:0},{default:withCtx(()=>[..._cache[3]||=[createTextVNode(` Painting `,-1)]]),_:1})),createVNode(unref(tabs_default),{class:`bng-tabs`,"selected-index":0,"make-tab-header-classes":headerClass,style:normalizeStyle(headerVars.value),onChange:changedPaintIndexTab},{default:withCtx(()=>[(openBlock(!0),createElementBlock(Fragment,null,renderList(paints.value,(paint,idx)=>(openBlock(),createBlock(unref(tabs_default),{key:idx,"tab-heading":_ctx.$t(`ui.trackBuilder.matEditor.paint`)+` `+(idx+1),class:`bng-tabs`,"selected-index":0,onChange:changedTopLevelPaintClassTab},{default:withCtx(()=>[(openBlock(),createElementBlock(Fragment,null,renderList(paintClassTabInfo,(paintClassTab,idx$1)=>createBaseVNode(`div`,{key:idx$1,"tab-heading":paintClassTab.title,style:{margin:`0.3em`,"background-color":`#00000000`}},[(openBlock(!0),createElementBlock(Fragment,null,renderList(paintClassTab.paintClasses,(paintClass,idx$2)=>(openBlock(),createBlock(unref(bngButton_default),{key:idx$2,onClick:$event=>changedPaintClassTab(paintClass.id),accent:colorClass.value==paintClass.id?void 0:unref(ACCENTS).secondary,class:`paint-class-button`},{default:withCtx(()=>[createTextVNode(toDisplayString(paintClass.title),1)]),_:2},1032,[`onClick`,`accent`]))),128))],8,_hoisted_3$149)),64))]),_:2},1032,[`tab-heading`]))),128))]),_:1},8,[`style`]),createVNode(unref(bngCard_default),null,{default:withCtx(()=>[createBaseVNode(`div`,_hoisted_4$124,[createVNode(PaintPicker_default,{ref_key:`paintPicker`,ref:paintPicker,modelValue:paints.value[paintIndex.value],"onUpdate:modelValue":_cache[0]||=$event=>paints.value[paintIndex.value]=$event,"show-main":showPickerMain(),presets:getPickerShowPresets()?presets.value:void 0,"presets-editable":getPickerPresetsEditable(),"advanced-open":!1,"show-advanced-switch":!1,onChange},null,8,[`modelValue`,`show-main`,`presets`,`presets-editable`]),showClearCoatOption()?(openBlock(),createElementBlock(`div`,_hoisted_5$109,[createVNode(unref(bngSwitch_default),{modelValue:clearCoatActive.value,"onUpdate:modelValue":_cache[1]||=$event=>clearCoatActive.value=$event,onValueChanged:clearCoatUpdateCallback},{default:withCtx(()=>[createTextVNode(` Add Clear Coat (Baseprice: `+toDisplayString(unref(units).beamBucks(prices.value.clearcoatBase.money.amount))+`) `,1)]),_:1},8,[`modelValue`]),clearCoatActive.value?(openBlock(),createBlock(unref(bngColorSlider_default),{key:0,style:{"margin-top":`0.7em`},modelValue:clearCoatPolish.value,"onUpdate:modelValue":_cache[2]||=$event=>clearCoatPolish.value=$event,onChange:changeClearCoatPolish},{default:withCtx(()=>[..._cache[4]||=[createTextVNode(` Clear Coat Polish `,-1)]]),_:1},8,[`modelValue`])):createCommentVNode(``,!0)])):createCommentVNode(``,!0)])]),_:1})])]),_:1})),[[unref(BngBlur_default),1]]),createVNode(unref(bngCard_default),{class:`shoppingCart`},{default:withCtx(()=>[createVNode(unref(bngCardHeading_default),null,{default:withCtx(()=>[..._cache[5]||=[createTextVNode(`Shopping Cart`,-1)]]),_:1}),changedPaint.value?(openBlock(),createElementBlock(`div`,_hoisted_6$92,[createBaseVNode(`table`,_hoisted_7$80,[_cache[9]||=createBaseVNode(`thead`,null,[createBaseVNode(`tr`,null,[createBaseVNode(`th`),createBaseVNode(`th`,{class:`article`},`Option`),createBaseVNode(`th`,{class:`price`},`Price`)])],-1),createBaseVNode(`tbody`,null,[(openBlock(!0),createElementBlock(Fragment,null,renderList(getShoppingCartTable(),(date,idx)=>(openBlock(),createElementBlock(`tr`,null,[createBaseVNode(`th`,null,[date.topLevel?(openBlock(),createBlock(unref(bngButton_default),{key:0,onClick:$event=>resetPaint(date.index)},{default:withCtx(()=>[..._cache[6]||=[createTextVNode(`remove`,-1)]]),_:1},8,[`onClick`])):createCommentVNode(``,!0)]),createBaseVNode(`th`,{class:normalizeClass(date.topLevel?`article`:`article--subLevel`)},toDisplayString(date.name),3),createBaseVNode(`th`,_hoisted_8$66,toDisplayString(unref(units).beamBucks(date.price)),1)]))),256)),createBaseVNode(`tr`,null,[_cache[7]||=createBaseVNode(`th`,null,null,-1),_cache[8]||=createBaseVNode(`th`,{class:`article--total`},`Total`,-1),createBaseVNode(`th`,_hoisted_9$59,toDisplayString(unref(units).beamBucks(totalPrice.value)),1)])])])])):createCommentVNode(``,!0),createBaseVNode(`div`,_hoisted_10$50,[withDirectives((openBlock(),createBlock(unref(bngButton_default),{class:`purchase-button`,disabled:!canPay.value||!changedPaint.value,"show-hold":``},{default:withCtx(()=>[..._cache[10]||=[createTextVNode(` Purchase and Apply `,-1)]]),_:1},8,[`disabled`])),[[unref(BngOnUiNav_default),void 0,`ok`,{asMouse:!0,focusRequired:!0}],[unref(BngClick_default),{holdCallback:()=>apply$1(),holdDelay:1e3,repeatInterval:0}]])])]),_:1})]))}},Painting_default=__plugin_vue_export_helper_default(_sfc_main$240,[[`__scopeId`,`data-v-9dc00fbe`]]),_sfc_main$239={__name:`PaintingMain`,setup(__props){useComputerStore();let elPainting=ref(),close=()=>elPainting.value.close();return(_ctx,_cache)=>(openBlock(),createBlock(ComputerWrapper_default,{path:[`Painting`],title:`Painting`,back:``,onBack:close},{default:withCtx(()=>[createVNode(Painting_default,{ref_key:`elPainting`,ref:elPainting,"no-header":``},null,512)]),_:1}))}},PaintingMain_default=_sfc_main$239;const usePartInventoryStore=defineStore(`partInventory`,()=>{let{events:events$3}=useBridge(),partInventoryData=ref({}),newPartsPopupOpen=ref(!1),newParts=ref([]),searchString=ref(``);function requestInitialData(){Lua_default.career_modules_partInventory.sendUIData()}function closeNewPartsPopup(){newPartsPopupOpen.value=!1}function closeMenu(){searchString.value=``,Lua_default.career_modules_partInventory.closeMenu()}function partInventoryClosed(){Lua_default.career_modules_partInventory.partInventoryClosed()}function dispose$2(){events$3.off(`partInventoryData`)}function openNewPartsPopup(newPartIds){newPartsPopupOpen.value=!0,newParts.value=[];for(let i=0;ipart.description.description.toLowerCase().includes(searchString.value.toLowerCase())||part.name.toLowerCase().includes(searchString.value.toLowerCase()),searchValueChanged=()=>{partInventoryData.value.partList.filter?partInventoryData.value.filteredPartList=partInventoryData.value.partList.filter(doesPartPassFilter):partInventoryData.value.filteredPartList={}};return watch(()=>searchString.value,searchValueChanged),events$3.on(`partInventoryData`,data=>{partInventoryData.value=data,searchValueChanged()}),{closeMenu,closeNewPartsPopup,dispose:dispose$2,newParts,newPartsPopupOpen,openNewPartsPopup,partInventoryClosed,partInventoryData,requestInitialData,searchString}});var _hoisted_1$210={style:{padding:`1em`}},_hoisted_2$169={class:`selectButtons`},_hoisted_3$148={class:`part-info-row`},_hoisted_4$123={class:`partList`},_hoisted_5$108=[`onClick`],_hoisted_6$91={class:`part-info-col`},_hoisted_7$79={class:`part-name`},_hoisted_8$65={class:`part-info-row`},_hoisted_9$58={class:`right`},_hoisted_10$49={class:`right`},_hoisted_11$44={class:`center`},_hoisted_12$33={class:`popup-buttons`},_sfc_main$238={__name:`PartSellingPopup`,props:{parts:{type:Array,default:[]}},emits:[`return`],setup(__props,{emit:__emit}){useUINavScope(`partSelling`);let{units}=useBridge(),partsChecked=ref([]),emit$1=__emit,props=__props,saleData=computed(()=>{let total=0,numberOfSelected=0;for(let[index,isChecked]of Object.entries(partsChecked.value))if(isChecked){let part=props.parts[index];total+=part.data.finalValue,numberOfSelected+=1}return{price:total,numberOfSelected}}),buildRefList=()=>{for(let i=0;i{for(let i=0;i{let partIds=[];for(let[index,isChecked]of Object.entries(partsChecked.value))if(isChecked){let part=props.parts[index];partIds.push(part.data.id)}Lua_default.career_modules_partInventory.sellParts(partIds),close()},close=()=>{emit$1(`return`,!0)};return onMounted(buildRefList),(_ctx,_cache)=>withDirectives((openBlock(),createBlock(unref(bngCard_default),{"bng-ui-scope":`partSelling`,class:`sellingCard`},{default:withCtx(()=>[createVNode(unref(bngCardHeading_default),null,{default:withCtx(()=>[..._cache[2]||=[createTextVNode(`Sell Parts`,-1)]]),_:1}),createBaseVNode(`div`,_hoisted_1$210,[createBaseVNode(`div`,_hoisted_2$169,[_cache[5]||=createTextVNode(` Select: `,-1),createBaseVNode(`div`,_hoisted_3$148,[createVNode(unref(bngButton_default),{accent:unref(ACCENTS).secondary,onClick:_cache[0]||=$event=>selectAll(!0)},{default:withCtx(()=>[..._cache[3]||=[createTextVNode(` All `,-1)]]),_:1},8,[`accent`]),createVNode(unref(bngButton_default),{accent:unref(ACCENTS).secondary,onClick:_cache[1]||=$event=>selectAll(!1)},{default:withCtx(()=>[..._cache[4]||=[createTextVNode(` None `,-1)]]),_:1},8,[`accent`])])]),createBaseVNode(`div`,_hoisted_4$123,[(openBlock(!0),createElementBlock(Fragment,null,renderList(__props.parts,(part,index)=>(openBlock(),createElementBlock(`div`,{class:normalizeClass([`part-item`,partsChecked.value[index]?`partSelected`:``]),"bng-nav-item":``,onClick:$event=>partsChecked.value[index]=!partsChecked.value[index]},[createVNode(unref(bngIcon_default),{class:`selectionCheckbox`,type:partsChecked.value[index]?unref(icons).checkboxOn:unref(icons).checkboxOff},null,8,[`type`]),createBaseVNode(`div`,_hoisted_6$91,[createBaseVNode(`div`,null,[createBaseVNode(`span`,_hoisted_7$79,toDisplayString(part.name),1)]),createBaseVNode(`div`,_hoisted_8$65,[createBaseVNode(`span`,_hoisted_9$58,toDisplayString(part.mileage),1),createBaseVNode(`span`,_hoisted_10$49,[createVNode(unref(bngPropVal_default),{iconType:unref(icons).beamCurrency,valueLabel:part.valueFormatted},null,8,[`iconType`,`valueLabel`])]),createBaseVNode(`span`,_hoisted_11$44,toDisplayString(part.model),1)])])],10,_hoisted_5$108))),256))]),createBaseVNode(`div`,_hoisted_12$33,[withDirectives((openBlock(),createBlock(unref(bngButton_default),{disabled:saleData.value.numberOfSelected<=0,"show-hold":``},{default:withCtx(()=>[createTextVNode(` Sell `+toDisplayString(saleData.value.numberOfSelected)+` parts for `,1),createVNode(unref(bngUnit_default),{money:saleData.value.price},null,8,[`money`])]),_:1},8,[`disabled`])),[[unref(BngClick_default),{holdCallback:sellSelectedParts,holdDelay:1e3,repeatInterval:0}]]),createVNode(unref(bngButton_default),{accent:unref(ACCENTS).attention,onClick:close},{default:withCtx(()=>[..._cache[6]||=[createTextVNode(` Cancel `,-1)]]),_:1},8,[`accent`])])])]),_:1})),[[unref(BngOnUiNav_default),close,`back,menu`]])}},PartSellingPopup_default=__plugin_vue_export_helper_default(_sfc_main$238,[[`__scopeId`,`data-v-c325ab7a`]]),_hoisted_1$209={style:{height:`100%`,color:`white`}},_hoisted_2$168={key:0},_hoisted_3$147={class:`veh-part-caption`},_hoisted_4$122={class:`veh-name`},_hoisted_5$107={class:`veh-name-count`},_hoisted_6$90={class:`part-item`,"bng-ui-scope":`veh-part-inv`},_hoisted_7$78={key:0,class:`part-info-col`},_hoisted_8$64={class:`part-name`},_hoisted_9$57={class:`part-info-row`},_hoisted_10$48={class:`right`},_hoisted_11$43={class:`right`},_hoisted_12$32={key:0,class:`center`},_hoisted_13$28={key:1,class:`center`},_hoisted_14$26={class:`center`},_hoisted_15$25={key:0},_hoisted_16$25={class:`center`},_hoisted_17$20={key:0},immediateLimit=15,_sfc_main$237={__name:`PartList`,emits:[`partSold`],setup(__props,{emit:__emit}){let{units}=useBridge(),emit$1=__emit,partInventoryStore=usePartInventoryStore(),groupBy=ref(`location`),groups=ref([]),accordionItems=ref([]),disableInstallButtons=ref(!1),addExpandedFuncToGroup=group=>{group.onExpanded=state=>{let grp=groups.value.find(g=>g.id===group.id);if(grp.expanded=state,!state){delete grp.ready;let elm=document.querySelector(`[data-groupid="${group.id}"] > .bng-accitem-caption`);elm&&elm.focus();return}`ready`in grp||(grp.ready=!1,setTimeout(()=>{let grp$1=groups.value.find(g=>g.id===group.id);grp$1&&typeof grp$1.ready==`boolean`&&(grp$1.ready=!0)},100))}},openSellPopup=async()=>{await addPopup(PartSellingPopup_default,{parts:groups.value[0].parts}).promise&&emit$1(`partSold`)};watchEffect(()=>{if(disableInstallButtons.value=!1,!partInventoryStore||!Array.isArray(partInventoryStore.partInventoryData.partList)||partInventoryStore.partInventoryData.partList.length===0)return[];let res=[];if(groupBy.value==`location`){let group={id:0,name:` Inventory`,parts:[],expanded:!1,icon:icons.BNGFolder};addExpandedFuncToGroup(group),res.push(group);for(let[vehId,vehicle]of Object.entries(partInventoryStore.partInventoryData.vehicles)){let group$1={id:vehId,name:vehicle.niceName,parts:[],expanded:!1,thumbnail:partInventoryStore.partInventoryData.vehicles[vehId].thumbnail};addExpandedFuncToGroup(group$1),res.push(group$1)}}for(let part of partInventoryStore.partInventoryData.filteredPartList){let item={name:part.missingFile?`Missing File`:part.description.description,model:part.vehicleModel,mileage:units.buildString(`length`,part.partCondition.odometer,0),valueFormatted:units.beamBucks(part.finalValue),location:part.location,locationName:part.location===0?` Inventory`:partInventoryStore.partInventoryData.vehicles[part.location].niceName,functions:{install:!1,uninstall:!1,sell:!1},data:part};!part.missingFile&&part.accessible&&(item.functions.install=part.fitsCurrentVehicle&&part.location!==partInventoryStore.partInventoryData.currentVehicle&&(part.location===0||!partInventoryStore.partInventoryData.brokenVehicleInventoryIds[part.location])&&!partInventoryStore.partInventoryData.brokenVehicleInventoryIds[partInventoryStore.partInventoryData.currentVehicle],item.functions.uninstall=part.location!==0&&!part.isInCoreSlot&&!partInventoryStore.partInventoryData.brokenVehicleInventoryIds[part.location],item.functions.sell=part.location===0);let groupId=item[groupBy.value],group=res.find(g=>g.id==groupId);group||(group={id:groupId,name:item[`${groupBy.value}Name`]||item[groupBy.value],parts:[],expanded:!1},part.location>0?group.thumbnail=partInventoryStore.partInventoryData.vehicles[part.location].thumbnail:group.icon=icons.BNGFolder,addExpandedFuncToGroup(group),res.push(group)),group.parts.push(item)}if(res.length>0){let sorter=(a$1,b)=>a$1.name.localeCompare(b.name);res.sort(sorter);for(let group of res)group.parts.sort(sorter)}for(let group of groups.value)if(group.ready){let grp=res.find(g=>g.name===group.name);grp&&(grp.expanded=!0,grp.ready=!0)}groups.value=res});let confirmSellPart=async partToSell=>{await openConfirmation(partToSell.description.description,`Do you want to sell this part for ${units.beamBucks(partToSell.finalValue)}?`,[{label:$translate.instant(`ui.common.yes`),value:!0,extras:{default:!0}},{label:$translate.instant(`ui.common.no`),value:!1,extras:{accent:ACCENTS.secondary}}])&&sellPart(partToSell)},sellPart=part=>{Lua_default.career_modules_partInventory.sellParts([part.id]),emit$1(`partSold`)};return(_ctx,_cache)=>withDirectives((openBlock(),createElementBlock(`div`,_hoisted_1$209,[createVNode(unref(bngInput_default),{class:`searchField`,"floating-label":`Search`,"leading-icon":unref(icons).search,modelValue:unref(partInventoryStore).searchString,"onUpdate:modelValue":_cache[0]||=$event=>unref(partInventoryStore).searchString=$event,modelModifiers:{trim:!0}},null,8,[`leading-icon`,`modelValue`]),withDirectives((openBlock(),createBlock(unref(bngCard_default),{style:{"max-height":`90%`}},{default:withCtx(()=>[unref(partInventoryStore)?(openBlock(),createBlock(unref(accordion_default),{key:1,class:`part-groups`,singular:``},{default:withCtx(()=>[(openBlock(!0),createElementBlock(Fragment,null,renderList(groups.value,(group,index)=>(openBlock(),createBlock(unref(accordionItem_default),{key:group.id,"data-groupid":group.id,ref_for:!0,ref_key:`accordionItems`,ref:accordionItems,navigable:``,onExpanded:group.onExpanded,onSelected:$event=>accordionItems.value[index]?accordionItems.value[index].captionClick():void 0},{caption:withCtx(()=>[createBaseVNode(`div`,_hoisted_3$147,[group.icon?(openBlock(),createBlock(unref(bngIcon_default),{key:0,class:`veh-icon`,type:group.icon},null,8,[`type`])):createCommentVNode(``,!0),group.thumbnail?(openBlock(),createElementBlock(`div`,{key:1,class:`veh-preview`,style:normalizeStyle({backgroundImage:`url('${group.thumbnail}')`})},null,4)):createCommentVNode(``,!0),createBaseVNode(`span`,_hoisted_4$122,[createTextVNode(toDisplayString(group.name)+` `,1),createBaseVNode(`span`,_hoisted_5$107,`(`+toDisplayString(group.parts.length)+`)`,1)])])]),default:withCtx(()=>[group.name==` Inventory`?(openBlock(),createBlock(unref(bngButton_default),{key:0,accent:unref(ACCENTS).outlined,onClick:_cache[1]||=$event=>openSellPopup()},{default:withCtx(()=>[..._cache[2]||=[createTextVNode(` Sell Parts `,-1)]]),_:1},8,[`accent`])):createCommentVNode(``,!0),(openBlock(!0),createElementBlock(Fragment,null,renderList(group.parts,(part,index$1)=>withDirectives((openBlock(),createElementBlock(`div`,_hoisted_6$90,[group.ready||index$1confirmSellPart(part.data)},{default:withCtx(()=>[..._cache[3]||=[createTextVNode(` Sell `,-1)]]),_:1},8,[`accent`,`onClick`])):createCommentVNode(``,!0)])),[[unref(BngOnUiNav_default),()=>group.onExpanded(!1),`back`]])),256))]),_:2},1032,[`data-groupid`,`onExpanded`,`onSelected`]))),128))]),_:1})):(openBlock(),createElementBlock(`div`,_hoisted_2$168,` Please wait... `))]),_:1})),[[unref(BngDisabled_default),!unref(partInventoryStore)]])])),[[unref(BngBlur_default)]])}},PartList_default=__plugin_vue_export_helper_default(_sfc_main$237,[[`__scopeId`,`data-v-7c222f4e`]]),_hoisted_1$208={style:{width:`100%`}},_sfc_main$236={__name:`PartInventoryAddedParts`,props:{parts:{type:Object,default:{}}},setup(__props){let{units}=useBridge(),getLocationName=part=>part.location?`Vehicle No. `+part.location+` (`+part.vehicleModel+`)`:`Inventory`;return(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,null,[_cache[1]||=createTextVNode(` The following additional parts have been added to the vehicle from your inventory to fill the core slots: `,-1),createBaseVNode(`table`,_hoisted_1$208,[_cache[0]||=createBaseVNode(`thead`,null,[createBaseVNode(`tr`,null,[createBaseVNode(`th`,null,`id`),createBaseVNode(`th`,null,`Description`),createBaseVNode(`th`,null,`Location`),createBaseVNode(`th`,null,`Mileage`),createBaseVNode(`th`,null,`Part Value`)])],-1),createBaseVNode(`tbody`,null,[(openBlock(!0),createElementBlock(Fragment,null,renderList(__props.parts,(part,key)=>(openBlock(),createElementBlock(`tr`,{key},[createBaseVNode(`td`,null,toDisplayString(part.id),1),createBaseVNode(`td`,null,toDisplayString(part.description.description),1),createBaseVNode(`td`,null,toDisplayString(getLocationName(part)),1),createBaseVNode(`td`,null,toDisplayString(unref(units).buildString(`length`,part.partCondition.odometer,0)),1),createBaseVNode(`td`,null,toDisplayString(unref(units).beamBucks(part.finalValue)),1)]))),128))])])]))}},PartInventoryAddedParts_default=__plugin_vue_export_helper_default(_sfc_main$236,[[`__scopeId`,`data-v-8dbd3a82`]]),_sfc_main$235={__name:`PartInventoryMain`,setup(__props){useComputerStore();let wrapper=ref(),partInventoryStore=usePartInventoryStore();watch(()=>partInventoryStore.newPartsPopupOpen,(newVal,oldVal)=>newVal&&confirmAddedParts());let confirmAddedParts=async vehicle=>{await openMessage(``,{component:markRaw(PartInventoryAddedParts_default),props:{parts:partInventoryStore.newParts}}),closeNewPartsPopup()},updateCareerStatus=()=>{wrapper.value.statusUpdate()};onBeforeMount(()=>{partInventoryStore.requestInitialData()}),onUnmounted(()=>{partInventoryStore.partInventoryClosed(),partInventoryStore.$dispose()});let close=()=>{partInventoryStore.closeMenu()},closeNewPartsPopup=()=>{partInventoryStore.closeNewPartsPopup()};return(_ctx,_cache)=>(openBlock(),createBlock(ComputerWrapper_default,{ref_key:`wrapper`,ref:wrapper,path:[`Part Inventory`],title:`Part Inventory`,back:``,onBack:close},{default:withCtx(()=>[createVNode(PartList_default,{class:`part-inventory`,onPartSold:updateCareerStatus})]),_:1},512))}},PartInventoryMain_default=__plugin_vue_export_helper_default(_sfc_main$235,[[`__scopeId`,`data-v-54c60dea`]]);const usePartShoppingStore=defineStore(`partShopping`,()=>{let{events:events$3}=useBridge(),partShoppingData=ref({}),filteredSlots=ref([]),path=ref(``),filteredParts=ref([]),category=ref(``),expandedSlots=ref({}),searchString=``,slotToScrollTo=ref(),backAction=()=>{},slotsDict={},partFilter;function doesNameContainString(name,searchStrings){for(let searchString$1 of searchStrings)if(name.includes(searchString$1))return!0;return!1}function filterParts(){if(filteredParts.value=[],slotsDict={},partShoppingData.value.partsInShop){for(let[_,part]of Object.entries(partShoppingData.value.partsInShop)){if(!part.slot)continue;partFilter?doesNameContainString(part.name,partFilter)&&filteredParts.value.push(part):part.containingSlot===path.value&&filteredParts.value.push(part);let niceName=partShoppingData.value.slotsNiceName[part.slot];niceName==null?slotsDict[part.slot]=part.slot:slotsDict[part.slot]=niceName}filteredParts.value.sort((a$1,b)=>a$1.emptyPlaceholder?-1:b.emptyPlaceholder?1:a$1.partId&&!b.partId?-1:!a$1.partId&&b.partId?1:a$1.description.description0?(filteredSlotsDict=getSlotsFromSearchString(),filteredSlots.value=partShoppingData.value.searchSlotList.filter(doesSlotPassFilter)):filteredSlots.value=[]}function setSlotExpanded(path$1,expanded){expandedSlots.value[path$1]=expanded}function setSlot(_slot){_slot==``&&(slotToScrollTo.value=path.value),path.value=_slot,partFilter=void 0,filterParts()}function setCategory(_category){category.value=_category,filterSlots(),category.value==`everything`||category.value==``?setSlot(``):category.value==`cargo`&&(path.value=`Blablabla`,partFilter=[`cargo_load`],filterParts())}let requestInitialData=()=>{Lua_default.career_modules_partShopping.sendShoppingDataToUI()},cancelShopping=()=>{expandedSlots.value={},Lua_default.career_modules_partShopping.cancelShopping(),setCategory(``)};function fixSlots(slot){if(`children`in slot){Array.isArray(slot.children)||(slot.children=Object.values(slot.children).filter(Boolean)),slot.children.sort((a$1,b)=>(a$1.slotNiceName||a$1.slot)<(b.slotNiceName||b.slot)?-1:1);for(let childSlot of slot.children)fixSlots(childSlot)}}let handleShoppingData=data=>{data.partTree&&fixSlots(data.partTree),partShoppingData.value=data,filterParts(),filterSlots()},searchValueChanged=_searchString=>{searchString=_searchString,filterSlots()},listen=state=>{events$3[state?`on`:`off`](`partShoppingData`,handleShoppingData)};listen(!0);function dispose$2(){listen(!1)}return{partShoppingData,slot:path,filteredSlots,filteredParts,category,expandedSlots,slotToScrollTo,searchValueChanged,setSlot,setCategory,requestInitialData,cancelShopping,dispose:dispose$2,setSlotExpanded,set backAction(actionFunc){backAction=actionFunc},get backAction(){return backAction}}});var _hoisted_1$207={class:`cart-main`},_hoisted_2$167={class:`cart-list`,"bng-nav-scroll":``},_hoisted_3$146={key:0,class:`extra-info-text`},_hoisted_4$121={key:0},_hoisted_5$106={key:1},_hoisted_6$89={class:`cart-row cart-subtotal`},_hoisted_7$77={class:`cart-row cart-tax`},_hoisted_8$63={class:`cart-row cart-total`},_sfc_main$234={__name:`ShoppingCart`,props:{cartData:Object,playerMoney:Number,apply:Function,cancel:Function,confirmButtonText:String},setup(__props){let props=__props,{units}=useBridge(),expanded=ref(!1),subtotal=computed(()=>props.cartData&&props.cartData.total&&props.cartData.taxes?props.cartData.total-props.cartData.taxes:0),salesTax=computed(()=>props.cartData&&props.cartData.taxes?props.cartData.taxes:0);return(_ctx,_cache)=>(openBlock(),createBlock(unref(bngCard_default),{class:normalizeClass([`cart`,{expanded:expanded.value}])},{buttons:withCtx(()=>[withDirectives((openBlock(),createBlock(unref(bngButton_default),{"show-hold":``,disabled:!__props.apply||!__props.cartData||__props.cartData.items.length===0||__props.cartData.total>0&&__props.cartData.total>__props.playerMoney},{default:withCtx(()=>[createTextVNode(toDisplayString(__props.confirmButtonText||`Purchase`),1)]),_:1},8,[`disabled`])),[[unref(BngOnUiNav_default),void 0,`ok`,{asMouse:!0,focusRequired:!0}],[unref(BngClick_default),{holdCallback:__props.apply,holdDelay:1e3,repeatInterval:0}]]),createVNode(unref(bngButton_default),{disabled:!__props.cancel,onClick:_cache[1]||=$event=>props.cancel(),accent:unref(ACCENTS).secondary},{default:withCtx(()=>[..._cache[10]||=[createTextVNode(` Cancel `,-1)]]),_:1},8,[`disabled`,`accent`])]),default:withCtx(()=>[createVNode(unref(bngCardHeading_default),null,{default:withCtx(()=>[..._cache[2]||=[createTextVNode(` Shopping Cart `,-1)]]),_:1}),createVNode(unref(bngButton_default),{class:`cart-expand`,accent:unref(ACCENTS).outlined,icon:expanded.value?unref(icons).arrowLargeDown:unref(icons).arrowLargeUp,onClick:_cache[0]||=$event=>expanded.value=!expanded.value},null,8,[`accent`,`icon`]),createBaseVNode(`div`,_hoisted_1$207,[_cache[9]||=createBaseVNode(`div`,{class:`cart-row cart-header`},[createBaseVNode(`div`),createBaseVNode(`div`,null,`Part`),createBaseVNode(`div`,null,`Price`)],-1),createBaseVNode(`div`,_hoisted_2$167,[__props.cartData?(openBlock(!0),createElementBlock(Fragment,{key:0},renderList(__props.cartData.items,item=>(openBlock(),createElementBlock(`div`,{class:normalizeClass([`cart-row`,item.type?[`type-${item.type}`]:null])},[createBaseVNode(`div`,null,[item.removeShow?(openBlock(),createBlock(unref(bngButton_default),{key:0,accent:`attention`,icon:unref(icons).abandon,disabled:item.removeDisabled,onClick:$event=>item.remove()},null,8,[`icon`,`disabled`,`onClick`])):createCommentVNode(``,!0)]),createBaseVNode(`div`,{style:normalizeStyle({paddingLeft:item.level?`${item.level-1}em`:void 0})},[createTextVNode(toDisplayString(item.name)+` `,1),item.extraInfo?(openBlock(),createElementBlock(`div`,_hoisted_3$146,toDisplayString(item.extraInfo),1)):createCommentVNode(``,!0)],4),item.priceHide?(openBlock(),createElementBlock(`div`,_hoisted_5$106)):(openBlock(),createElementBlock(`div`,_hoisted_4$121,toDisplayString(unref(units).beamBucks(item.price)),1))],2))),256)):createCommentVNode(``,!0),createBaseVNode(`div`,_hoisted_6$89,[_cache[3]||=createBaseVNode(`div`,null,null,-1),_cache[4]||=createBaseVNode(`div`,null,`Subtotal`,-1),createBaseVNode(`div`,null,toDisplayString(unref(units).beamBucks(subtotal.value)),1)]),createBaseVNode(`div`,_hoisted_7$77,[_cache[5]||=createBaseVNode(`div`,null,null,-1),_cache[6]||=createBaseVNode(`div`,null,`Sales Tax (7%)`,-1),createBaseVNode(`div`,null,toDisplayString(unref(units).beamBucks(salesTax.value)),1)])]),createBaseVNode(`div`,_hoisted_8$63,[_cache[7]||=createBaseVNode(`div`,null,null,-1),_cache[8]||=createBaseVNode(`div`,null,`Total`,-1),createBaseVNode(`div`,null,[createVNode(unref(bngUnit_default),{money:__props.cartData?__props.cartData.total:0},null,8,[`money`])])])])]),_:1},8,[`class`]))}},ShoppingCart_default=__plugin_vue_export_helper_default(_sfc_main$234,[[`__scopeId`,`data-v-e9392f36`]]),_hoisted_1$206={class:`parts-wrapper`},_hoisted_2$166={key:2,class:`parts-list`},_hoisted_3$145={class:`part-info-col`},_hoisted_4$120={class:`part-name`},_hoisted_5$105={key:0},_hoisted_6$88={key:1},_hoisted_7$76={key:2},_hoisted_8$62={class:`part-info-row`},_hoisted_9$56={key:0,class:`mileage-text`},_hoisted_10$47={key:1},_hoisted_11$42={key:2,class:`disabled-reason`},_hoisted_12$31={key:3,class:`right`},_hoisted_13$27={key:0},_sfc_main$233={__name:`PartsList`,setup(__props){let partShoppingStore=usePartShoppingStore(),{units}=useBridge(),oldBack,isPartInShoppingCart=part=>{if(!partShoppingStore.partShoppingData||!partShoppingStore.partShoppingData.shoppingCart)return!1;let partList=partShoppingStore.partShoppingData.shoppingCart.partsInList;for(let i=0;i{oldBack=partShoppingStore.backAction,partShoppingStore.backAction=()=>partShoppingStore.setSlot(``)}),onUnmounted(()=>{partShoppingStore.backAction=oldBack}),(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$206,[unref(partShoppingStore).category===`cargo`?(openBlock(),createBlock(unref(bngCardHeading_default),{key:0},{default:withCtx(()=>[..._cache[0]||=[createTextVNode(` Cargo `,-1)]]),_:1})):unref(partShoppingStore).filteredParts[0]?(openBlock(),createBlock(unref(bngCardHeading_default),{key:1},{default:withCtx(()=>[createTextVNode(toDisplayString(unref(partShoppingStore).partShoppingData.slotsNiceName[unref(partShoppingStore).filteredParts[0].containingSlot]),1)]),_:1})):createCommentVNode(``,!0),unref(partShoppingStore).filteredParts?(openBlock(),createElementBlock(`div`,_hoisted_2$166,[(openBlock(!0),createElementBlock(Fragment,null,renderList(unref(partShoppingStore).filteredParts,part=>(openBlock(),createElementBlock(`div`,{class:normalizeClass([`part-item`,{"part-installed":unref(partShoppingStore).partShoppingData.vehicleSlotToPartMap[part.containingSlot]&&unref(partShoppingStore).partShoppingData.vehicleSlotToPartMap[part.containingSlot].description.description===part.description.description,disabled:part.disabled}])},[createBaseVNode(`div`,_hoisted_3$145,[createBaseVNode(`div`,null,[createBaseVNode(`span`,_hoisted_4$120,[part.partId?(openBlock(),createElementBlock(`div`,_hoisted_5$105,toDisplayString(part.description.description)+` (Inventory) `,1)):part.emptyPlaceholder?(openBlock(),createElementBlock(`div`,_hoisted_6$88,` Remove current part `)):(openBlock(),createElementBlock(`div`,_hoisted_7$76,toDisplayString(part.description.description),1))])]),createBaseVNode(`div`,_hoisted_8$62,[part.partId?(openBlock(),createElementBlock(`span`,_hoisted_9$56,` Mileage: `+toDisplayString(unref(units).buildString(`length`,part.partCondition.odometer,0)),1)):createCommentVNode(``,!0),unref(partShoppingStore).category===`cargo`?(openBlock(),createElementBlock(`span`,_hoisted_10$47,toDisplayString(unref(partShoppingStore).partShoppingData.slotsNiceName[part.containingSlot]),1)):createCommentVNode(``,!0),part.disabled&&part.disabledReason?(openBlock(),createElementBlock(`span`,_hoisted_11$42,toDisplayString(part.disabledReason),1)):createCommentVNode(``,!0),!part.partId&&!part.emptyPlaceholder?(openBlock(),createElementBlock(`span`,_hoisted_12$31,[createVNode(unref(bngPropVal_default),{iconType:unref(icons).beamCurrency,valueLabel:unref(units).beamBucks(part.finalValue)},null,8,[`iconType`,`valueLabel`])])):createCommentVNode(``,!0)])]),createVNode(unref(bngButton_default),{accent:isPartInShoppingCart(part)?unref(ACCENTS).attention:unref(ACCENTS).outlined,class:`part-button`,disabled:part.disabled||unref(partShoppingStore).partShoppingData.tutorialPartNames!==void 0&&(!unref(partShoppingStore).partShoppingData.tutorialPartNames[part.name]||isPartInShoppingCart(part)),onClick:$event=>isPartInShoppingCart(part)?unref(Lua_default).career_modules_partShopping.removePartBySlot(part.containingSlot):unref(Lua_default).career_modules_partShopping.installPartByPartShopId(part.partShopId),icon:isPartInShoppingCart(part)?unref(icons).undo:``},{default:withCtx(()=>[isPartInShoppingCart(part)?createCommentVNode(``,!0):(openBlock(),createElementBlock(`div`,_hoisted_13$27,toDisplayString(part.emptyPlaceholder?`Remove`:`Install`),1))]),_:2},1032,[`accent`,`disabled`,`onClick`,`icon`])],2))),256))])):createCommentVNode(``,!0)]))}},PartsList_default=__plugin_vue_export_helper_default(_sfc_main$233,[[`__scopeId`,`data-v-c224fcea`]]),_hoisted_1$205={key:0,class:`highlighted`},_hoisted_2$165={key:1,class:`slot-path`},_hoisted_3$144={class:`buy-button-label`},_sfc_main$232={__name:`SlotItem`,props:{static:Boolean,expanded:Boolean,path:String,nicePath:String,slotNiceName:String,partNiceName:String},setup(__props){let slotItem=ref(),focused$1=ref(!1),props=__props;onMounted(()=>{partShoppingStore.slotToScrollTo&&props.path===partShoppingStore.slotToScrollTo&&slotItem.value.scrollIntoView({block:`center`})});let partShoppingStore=usePartShoppingStore(),itemExpanded=val=>{partShoppingStore.setSlotExpanded(props.path,val)},onFocus=val=>{focused$1.value=!0},onUnfocus=val=>{focused$1.value=!1},selectSlot=val=>{partShoppingStore.setSlot(props.path)};return(_ctx,_cache)=>(openBlock(),createBlock(unref(accordionItem_default),{static:__props.static,expanded:__props.expanded,onExpanded:itemExpanded,onFocus,onUnfocus,onSelected:selectSlot,navigable:``,"primary-action":()=>unref(partShoppingStore).setSlot(__props.path),"expand-hint-inline":``,"primary-hint-inline":``},{caption:withCtx(()=>[unref(partShoppingStore).slotToScrollTo===__props.path?(openBlock(),createElementBlock(`div`,_hoisted_1$205)):createCommentVNode(``,!0),__props.nicePath?(openBlock(),createElementBlock(`span`,_hoisted_2$165,toDisplayString(__props.nicePath),1)):createCommentVNode(``,!0),createBaseVNode(`span`,{ref_key:`slotItem`,ref:slotItem,class:`slot-name`},toDisplayString(__props.slotNiceName),513)]),controls:withCtx(()=>[withDirectives((openBlock(),createBlock(unref(bngButton_default),{"bng-no-nav":`true`,class:`buy-button`,accent:unref(ACCENTS).outlined,onClick:_cache[0]||=$event=>unref(partShoppingStore).setSlot(__props.path),style:normalizeStyle({backgroundColor:unref(partShoppingStore).slotToScrollTo&&unref(partShoppingStore).slotToScrollTo==__props.path?`rgba(75,75,75,0.8)`:``})},{default:withCtx(()=>[createBaseVNode(`span`,_hoisted_3$144,toDisplayString(__props.partNiceName?__props.partNiceName:`-`),1)]),_:1},8,[`accent`,`style`])),[[unref(BngTooltip_default),__props.partNiceName,`top`]])]),default:withCtx(()=>[renderSlot(_ctx.$slots,`default`,{},void 0,!0)]),_:3},8,[`static`,`expanded`,`primary-action`]))}},SlotItem_default=__plugin_vue_export_helper_default(_sfc_main$232,[[`__scopeId`,`data-v-3223c56d`]]),_sfc_main$231={__name:`PartSubTree`,props:{children:Object},setup(__props){let slotItemRefs=ref([]),partShoppingStore=usePartShoppingStore();return(_ctx,_cache)=>(openBlock(),createBlock(unref(accordion_default),null,{default:withCtx(()=>[(openBlock(!0),createElementBlock(Fragment,null,renderList(__props.children,childSlot=>(openBlock(),createBlock(SlotItem_default,{ref_for:!0,ref_key:`slotItemRefs`,ref:slotItemRefs,static:!childSlot.chosenPartName||!childSlot.children||Object.keys(childSlot.children).length===0,expanded:unref(partShoppingStore).expandedSlots[childSlot.path],path:childSlot.path,slotNiceName:childSlot.slotNiceName,partNiceName:childSlot.chosenPartNiceName},{default:withCtx(()=>[childSlot.children&&Object.keys(childSlot.children).length>0?(openBlock(),createBlock(PartSubTree_default,{key:0,children:childSlot.children},null,8,[`children`])):createCommentVNode(``,!0)]),_:2},1032,[`static`,`expanded`,`path`,`slotNiceName`,`partNiceName`]))),256))]),_:1}))}},PartSubTree_default=_sfc_main$231,_hoisted_1$204={class:`innerList`},_sfc_main$230={__name:`SlotList`,props:{cancel:Function},setup(__props){let partShoppingStore=usePartShoppingStore(),props=__props,searchValue=ref(``),searchValueChanged=()=>{partShoppingStore.searchValueChanged(searchValue.value)};return onMounted(()=>{partShoppingStore.backAction,partShoppingStore.backAction=()=>partShoppingStore.setCategory(``)}),onUnmounted(()=>{partShoppingStore.backAction=()=>props.cancel()}),(_ctx,_cache)=>unref(partShoppingStore).slot===``?(openBlock(),createElementBlock(Fragment,{key:1},[createVNode(unref(bngInput_default),{"floating-label":`Search`,"leading-icon":unref(icons).search,modelValue:searchValue.value,"onUpdate:modelValue":_cache[0]||=$event=>searchValue.value=$event,modelModifiers:{trim:!0},onValueChanged:searchValueChanged},null,8,[`leading-icon`,`modelValue`]),createBaseVNode(`div`,_hoisted_1$204,[searchValue.value.length>0?(openBlock(),createBlock(unref(accordion_default),{key:0,class:`slot-flat-view`},{default:withCtx(()=>[(openBlock(!0),createElementBlock(Fragment,null,renderList(unref(partShoppingStore).filteredSlots,slotInfo=>(openBlock(),createBlock(SlotItem_default,{static:!0,path:slotInfo.path,nicePath:slotInfo.nicePath,slotNiceName:slotInfo.slotNiceName,partNiceName:slotInfo.partNiceName?slotInfo.partNiceName:null},null,8,[`path`,`nicePath`,`slotNiceName`,`partNiceName`]))),256))]),_:1})):unref(partShoppingStore).partShoppingData.partTree.children?(openBlock(),createBlock(PartSubTree_default,{key:1,class:`slot-tree-view`,children:unref(partShoppingStore).partShoppingData.partTree.children},null,8,[`children`])):createCommentVNode(``,!0)])],64)):(openBlock(),createBlock(PartsList_default,{key:0}))}},SlotList_default=__plugin_vue_export_helper_default(_sfc_main$230,[[`__scopeId`,`data-v-f602b7c1`]]),_hoisted_1$203={key:0,class:`mainCategories`},_hoisted_2$164=[`disabled`],_sfc_main$229={__name:`Categories`,props:{cancel:Function},setup(__props){let partShoppingStore=usePartShoppingStore(),props=__props;return onMounted(()=>{partShoppingStore.backAction=()=>props.cancel()}),(_ctx,_cache)=>(openBlock(),createBlock(unref(bngCard_default),{class:`categoryList`},{default:withCtx(()=>[unref(partShoppingStore).category===``?(openBlock(),createElementBlock(`div`,_hoisted_1$203,[withDirectives((openBlock(),createElementBlock(`div`,{class:`computer-function-tile`,"bng-nav-item":``,tabindex:`0`,disabled:unref(partShoppingStore).partShoppingData.tutorialPartNames===void 0?void 0:!0,onClick:_cache[0]||=$event=>unref(partShoppingStore).partShoppingData.tutorialPartNames===void 0?unref(partShoppingStore).setCategory(`everything`):void 0},[createVNode(unref(bngIcon_default),{class:`icon`,type:unref(icons).doorFrontCoins},null,8,[`type`]),_cache[2]||=createBaseVNode(`span`,{class:`label`},`All Parts`,-1)],8,_hoisted_2$164)),[[unref(BngFocusIf_default),!0]]),createBaseVNode(`div`,{class:`computer-function-tile`,"bng-nav-item":``,tabindex:`0`,onClick:_cache[1]||=$event=>unref(partShoppingStore).setCategory(`cargo`)},[createVNode(unref(bngIcon_default),{class:`icon`,type:unref(icons).boxPickUp03},null,8,[`type`]),_cache[3]||=createBaseVNode(`span`,{class:`label`},`Cargo Parts`,-1)])])):(openBlock(),createBlock(SlotList_default,{key:1,cancel:props.cancel},null,8,[`cancel`]))]),_:1}))}},Categories_default=__plugin_vue_export_helper_default(_sfc_main$229,[[`__scopeId`,`data-v-70c591df`]]),CANCEL_MESSAGE$1=`Are you sure you want to cancel?
    All changes to your vehicle will be reversed`,_sfc_main$228={__name:`PartShoppingMain`,setup(__props){let{$game}=useLibStore();useComputerStore();let partShoppingStore=usePartShoppingStore(),CONFIRM_BUTTONS=[{label:$translate.instant(`ui.common.yes`),value:!0},{label:$translate.instant(`ui.common.no`),value:!1,extras:{accent:ACCENTS.secondary}}],confirmCancel=async()=>{(!partShoppingStore.partShoppingData.shoppingCart.partsInList.length||await openConfirmation(null,CANCEL_MESSAGE$1,CONFIRM_BUTTONS))&&cancelShopping()},getPartName=item=>item.description.description+(item.partId?` (Inventory)`:``),cartData=computed(()=>{let cart=partShoppingStore.partShoppingData?partShoppingStore.partShoppingData.shoppingCart:null,res={total:0,taxes:0,items:[]};return cart&&(res.total=cart.total,res.taxes=cart.taxes,Array.isArray(cart.partsInList)&&(res.items=cart.partsInList.map(item=>({name:getPartName(item),price:item.finalValue,extraInfo:item.partCondition?.odometer?`Mileage: `+$game.units.buildString(`length`,item.partCondition.odometer,0):void 0,removeShow:!!item.sourcePart,removeDisabled:!!partShoppingStore.partShoppingData.tutorialPartNames,remove:()=>Lua_default.career_modules_partShopping.removePartBySlot(item.containingSlot)})))),res}),applyShopping=()=>Lua_default.career_modules_partShopping.applyShopping(),cancelShopping=()=>Lua_default.career_modules_partShopping.cancelShopping(),start=()=>{partShoppingStore.setSlot(``),partShoppingStore.requestInitialData(),getUINavServiceInstance().setFilteredEvents(UI_EVENT_GROUPS.focusMoveScalar)},kill=()=>{partShoppingStore.cancelShopping(),getUINavServiceInstance().clearFilteredEvents(),partShoppingStore.$dispose()},close=()=>{partShoppingStore.backAction()};return onBeforeMount(start),onUnmounted(kill),(_ctx,_cache)=>(openBlock(),createBlock(ComputerWrapper_default,{path:[`Part Customization`],title:`Parts`,back:``,onBack:close},{side:withCtx(()=>[createVNode(ShoppingCart_default,{partShoppingData:unref(partShoppingStore).partShoppingData,"cart-data":cartData.value,"player-money":unref(partShoppingStore).partShoppingData.playerMoney,apply:applyShopping,cancel:confirmCancel,"confirm-button-text":`Confirm`},null,8,[`partShoppingData`,`cart-data`,`player-money`])]),default:withCtx(()=>[withDirectives(createVNode(Categories_default,{cancel:confirmCancel},null,512),[[unref(BngBlur_default),1]])]),_:1}))}},PartShoppingMain_default=__plugin_vue_export_helper_default(_sfc_main$228,[[`__scopeId`,`data-v-871a3a9f`]]),_hoisted_1$202={class:`profile-status`},_hoisted_2$163={class:`profile-status-progress`},_hoisted_3$143={class:`status-progress-item`},_hoisted_4$119={class:`status-progress-item`},_hoisted_5$104={class:`status-progress-item`},_hoisted_6$87={key:0,class:`profile-status-levels`},_hoisted_7$75={class:`profile-status-level`},_hoisted_8$61={class:`branch-icon-assembly`},_hoisted_9$55={class:`level-content-wrapper`},_sfc_main$227={__name:`ProfileStatus`,props:{beamXP:{type:Object,required:!0},vouchers:{type:Object,required:!0},money:{type:Object,required:!0},insuranceScore:{type:Object,required:!0},branches:{type:Array,required:!0},expanded:Boolean},setup(__props){let props=__props,formatterFn=num=>shrinkNum(num,1),moneyFormatter=computed(()=>props.money&&props.money>1e5?formatterFn:void 0);computed(()=>props.beamXP&&props.beamXP>1e5?formatterFn:void 0);let vouchersFormatter=computed(()=>props.vouchers&&props.vouchers>1e5?formatterFn:void 0);function getBranchStyle(color){return getIconBackgroundStyle(color)}return(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$202,[createBaseVNode(`div`,_hoisted_2$163,[createBaseVNode(`div`,_hoisted_3$143,[createVNode(unref(bngUnit_default),{insuranceScore:__props.insuranceScore?.value||0},null,8,[`insuranceScore`])]),createVNode(unref(bngDivider_default)),createBaseVNode(`div`,_hoisted_4$119,[createVNode(unref(bngUnit_default),{vouchers:__props.vouchers?.value||0,formatter:vouchersFormatter.value},null,8,[`vouchers`,`formatter`])]),createVNode(unref(bngDivider_default)),createBaseVNode(`div`,_hoisted_5$104,[createVNode(unref(bngUnit_default),{money:__props.money?.value||0,formatter:moneyFormatter.value},null,8,[`money`,`formatter`])])]),createVNode(Transition,{name:`expand-height`},{default:withCtx(()=>[__props.branches?withDirectives((openBlock(),createElementBlock(`div`,_hoisted_6$87,[(openBlock(!0),createElementBlock(Fragment,null,renderList(__props.branches,branch=>(openBlock(),createElementBlock(`div`,_hoisted_7$75,[createBaseVNode(`div`,_hoisted_8$61,[createBaseVNode(`div`,{class:`branch-background`,style:normalizeStyle(getBranchStyle(branch.color))},null,4),createVNode(unref(bngIcon_default),{type:branch.icon,class:`assembly-icon`},null,8,[`type`])]),createBaseVNode(`div`,_hoisted_9$55,[createVNode(unref(bngProgressBar_default),{class:`slim`,value:branch.curLvlProgress,min:0,max:branch.neededForNext,headerLeft:_ctx.$ctx_t(branch.label),headerRight:`${_ctx.$ctx_t(branch.levelLabel)} `,valueColor:`white`,showValueLabel:!1},null,8,[`value`,`max`,`headerLeft`,`headerRight`])])]))),256))],512)),[[vShow,__props.expanded]]):createCommentVNode(``,!0)]),_:1})]))}},ProfileStatus_default=__plugin_vue_export_helper_default(_sfc_main$227,[[`__scopeId`,`data-v-26c35504`]]),_hoisted_1$201={style:{position:`absolute`,left:`0`,right:`0`,top:`0`,bottom:`0`,background:`rgba(0,0,0,0.5)`}},_sfc_main$226={__name:`PauseMapPreview`,setup(__props){let levelTitle=ref(``),levelImage=ref(``);function setup$3(data){levelTitle.value=$translate.contextTranslate(data.title,!0),levelImage.value=data.previews[0]}let start=()=>{Lua_default.career_modules_uiUtils.getCareerCurrentLevelName().then(setup$3)};function goToBigMap(){Lua_default.freeroam_bigMapMode.enterBigMap()}return onMounted(start),(_ctx,_cache)=>{let _directive_bng_sound_class=resolveDirective(`bng-sound-class`);return withDirectives((openBlock(),createBlock(unref(aspectRatio_default),{"external-image":`/levels/west_coast_usa/spawns_quarry.jpg`,ratio:`4:3`,onClick:_cache[1]||=$event=>goToBigMap()},{default:withCtx(()=>[createBaseVNode(`div`,_hoisted_1$201,[createVNode(unref(bngCardHeading_default),{style:{color:`white`},type:`ribbon`},{default:withCtx(()=>[createTextVNode(toDisplayString(levelTitle.value),1)]),_:1}),createVNode(unref(bngButton_default),{style:{position:`absolute`,bottom:`1em`,right:`1em`},tabindex:`1`,accent:unref(ACCENTS).text,onClick:_cache[0]||=$event=>goToBigMap()},{default:withCtx(()=>[..._cache[2]||=[createTextVNode(`Open Map`,-1)]]),_:1},8,[`accent`])])]),_:1})),[[_directive_bng_sound_class,`bng_click_generic`]])}}},PauseMapPreview_default=__plugin_vue_export_helper_default(_sfc_main$226,[[`__scopeId`,`data-v-5a91faef`]]),_hoisted_1$200={class:`content-wrapper`},_hoisted_2$162={class:`cards-container`},_sfc_main$225={__name:`PauseMilestonesPreview`,setup(__props){let milestones=ref([]);function setup$3(data){milestones.value=data.list}let start=()=>{Lua_default.career_modules_milestones_milestones.getMilestones().then(setup$3)};function goToMilestones(){window.bngVue.gotoGameState(`milestones`)}return onMounted(start),(_ctx,_cache)=>{let _directive_bng_sound_class=resolveDirective(`bng-sound-class`);return withDirectives((openBlock(),createBlock(unref(aspectRatio_default),{onClick:_cache[1]||=$event=>goToMilestones(),ratio:`4:3`},{default:withCtx(()=>[createBaseVNode(`div`,_hoisted_1$200,[createVNode(unref(bngCardHeading_default),{style:{color:`white`},type:`ribbon`},{default:withCtx(()=>[..._cache[2]||=[createTextVNode(`Recent Milestones`,-1)]]),_:1}),createBaseVNode(`div`,_hoisted_2$162,[(openBlock(!0),createElementBlock(Fragment,null,renderList(milestones.value.slice(0,5),entry=>(openBlock(),createBlock(MilestoneCard_default,{milestone:entry,isCondensed:!0},null,8,[`milestone`]))),256))]),createVNode(unref(bngButton_default),{style:{position:`absolute`,bottom:`1em`,right:`1em`},tabindex:`1`,accent:unref(ACCENTS).text,onClick:_cache[0]||=$event=>goToMilestones()},{default:withCtx(()=>[..._cache[3]||=[createTextVNode(`Go to Milestones`,-1)]]),_:1},8,[`accent`])])]),_:1})),[[_directive_bng_sound_class,`bng_click_generic`]])}}},PauseMilestonesPreview_default=__plugin_vue_export_helper_default(_sfc_main$225,[[`__scopeId`,`data-v-7fcfd236`]]),_hoisted_1$199={class:`pause-body-wrapper`},_hoisted_2$161={class:`heading-container`},_hoisted_3$142={class:`buttons-and-status`},_hoisted_4$118={key:0,class:`indicator`},_hoisted_5$103={class:`save-load-row`},_hoisted_6$86={class:`status-container`},_hoisted_7$74={key:2,class:`vehicle-name`},_sfc_main$224={__name:`Pause`,setup(__props){useUINavScope(`pause`),ref({value:0,label:`Map`,type:`Map`}.type),ref(null),ref(.5);let contextButtons=ref({});function setupContextButtons(data){contextButtons.value=data.buttons}Lua_default.career_modules_uiUtils.getCareerPauseContextButtons().then(setupContextButtons);function onContextButtonClicked(btn){Lua_default.career_modules_uiUtils.callCareerPauseContextButtons(btn.functionId)}function onSaveButtonClicked(){Lua_default.career_saveSystem.saveCurrent(),exit()}async function onLoadButtonClicked(){await openConfirmation(`Load Profile`,`Are you sure you want to load a different profile? Any unsaved progress will be lost.`)&&window.bngVue.gotoGameState(`profiles`)}let exit=()=>window.bngVue.gotoGameState(`play`),saveSlotData=ref(null),currentVehicleName=ref(``);function makeVehicleName(data){return!data||data.key===`unicycle`?`Walking`:data.niceName}return onMounted(async()=>{let data=await Lua_default.career_career.sendCurrentSaveSlotData();saveSlotData.value=data,currentVehicleName.value=makeVehicleName(data.currentVehicle)}),onBeforeMount(()=>{Lua_default.simTimeAuthority.pushPauseRequest(`careerPause`)}),onUnmounted(()=>{Lua_default.simTimeAuthority.popPauseRequest(`careerPause`)}),(_ctx,_cache)=>withDirectives((openBlock(),createBlock(unref(layoutSingle_default),{class:`career-pause-layout`,"bng-ui-scope":`pause`},{default:withCtx(()=>[createBaseVNode(`div`,_hoisted_1$199,[createBaseVNode(`div`,_hoisted_2$161,[createVNode(unref(bngCardHeading_default),{class:`pause-heading`,type:`ribbon`},{default:withCtx(()=>[..._cache[0]||=[createTextVNode(`Career: Paused`,-1)]]),_:1})]),createBaseVNode(`div`,_hoisted_3$142,[createVNode(unref(bngCard_default),{class:`system-buttons`},{default:withCtx(()=>[createVNode(unref(bngButton_default),{class:`button`,tabindex:`1`,accent:unref(ACCENTS).text,onClick:exit},{default:withCtx(()=>[..._cache[1]||=[createTextVNode(`Resume`,-1)]]),_:1},8,[`accent`]),contextButtons.value.length>0?(openBlock(!0),createElementBlock(Fragment,{key:0},renderList(contextButtons.value,btn=>(openBlock(),createBlock(unref(bngButton_default),{class:`button`,tabindex:`1`,accent:unref(ACCENTS).text,onClick:$event=>onContextButtonClicked(btn)},{default:withCtx(()=>[createTextVNode(toDisplayString(_ctx.$ctx_t(btn.label))+` `,1),btn.showIndicator?(openBlock(),createElementBlock(`div`,_hoisted_4$118)):createCommentVNode(``,!0)]),_:2},1032,[`accent`,`onClick`]))),256)):createCommentVNode(``,!0),createBaseVNode(`div`,_hoisted_5$103,[createVNode(unref(bngButton_default),{class:`button`,tabindex:`1`,accent:unref(ACCENTS).text,onClick:onSaveButtonClicked},{default:withCtx(()=>[..._cache[2]||=[createTextVNode(`Save`,-1)]]),_:1},8,[`accent`]),createVNode(unref(bngButton_default),{class:`button`,tabindex:`1`,accent:unref(ACCENTS).text,onClick:onLoadButtonClicked},{default:withCtx(()=>[..._cache[3]||=[createTextVNode(`Load`,-1)]]),_:1},8,[`accent`])])]),_:1}),createBaseVNode(`div`,_hoisted_6$86,[saveSlotData.value?(openBlock(),createBlock(unref(bngCardHeading_default),{key:0,class:`profile-name`,type:`ribbon`},{default:withCtx(()=>[createTextVNode(toDisplayString(saveSlotData.value.id),1)]),_:1})):createCommentVNode(``,!0),saveSlotData.value?(openBlock(),createBlock(ProfileStatus_default,{key:1,class:`pause-profile-status`,expanded:!0,beamXP:saveSlotData.value.beamXP,vouchers:saveSlotData.value.vouchers,money:saveSlotData.value.money,insuranceScore:saveSlotData.value.insuranceScore,branches:saveSlotData.value.branches},null,8,[`beamXP`,`vouchers`,`money`,`insuranceScore`,`branches`])):createCommentVNode(``,!0),saveSlotData.value?(openBlock(),createElementBlock(`div`,_hoisted_7$74,[createVNode(unref(bngIcon_default),{type:unref(icons).car},null,8,[`type`]),createTextVNode(` `+toDisplayString(currentVehicleName.value),1)])):createCommentVNode(``,!0)])])])]),_:1})),[[unref(BngOnUiNav_default),exit,`menu,back`],[unref(BngBlur_default),!0]])}},Pause_default=__plugin_vue_export_helper_default(_sfc_main$224,[[`__scopeId`,`data-v-c6f22d14`]]),_hoisted_1$198={class:`career-pause-wrapper`},_hoisted_2$160={class:`layout-center-wrapper`},_hoisted_3$141={class:`pause-body-wrapper`},_hoisted_4$117={class:`left-content`},_hoisted_5$102={class:`tabs-group`},_hoisted_6$85={class:`tab-content`},_hoisted_7$73={style:{position:`absolute`,left:`0`,right:`0`,top:`0`,bottom:`0`,background:`rgba(0, 0, 0, 0.5)`}},_hoisted_8$60={class:`right-content`},_hoisted_9$54={class:`bottom-content`},ICON_RATIO=`2.25:1`,_sfc_main$223={__name:`PauseBigMiddlePanel`,setup(__props){useUINavScope(`pause`);let MIDDLE_PILL_OPTIONS=[{value:0,label:`Map`,type:`Map`},{value:1,label:`Milestones`,type:`Milestones`},{value:2,label:`Engine`},{value:3,label:`Transmission`},{value:4,label:`Suspension`},{value:5,label:`Electrics`},{value:6,label:`Electrics1`},{value:7,label:`Electrics2`},{value:8,label:`Electrics3`}],currentPillTypeSelected=ref(MIDDLE_PILL_OPTIONS[0].type),middlePillsContainerRef=ref(null);function onMiddlePillsSelectPrevious(){middlePillsContainerRef.value.selectPrevious()}function onMiddlePillsSelectNext(){middlePillsContainerRef.value.selectNext()}function middlePillsValueChanged(selectedValues){let pillId=selectedValues[0],selectedPill=MIDDLE_PILL_OPTIONS.find(pill=>pill.value===pillId);console.log(selectedPill),currentPillTypeSelected.value=selectedPill.type}let todSliderValue=ref(.5),onTODChanged=v=>{console.log(v)},contextButtons=ref({});function setupContextButtons(data){console.log(data),contextButtons.value=data.buttons}Lua_default.career_modules_uiUtils.getCareerPauseContextButtons().then(setupContextButtons);function onContextButtonClicked(btn){console.log(btn),Lua_default.career_modules_uiUtils.callCareerPauseContextButtons(btn.functionId)}function onExitCareerButtonClicked(){console.log(`onExitCareerButtonClicked`)}function onSaveButtonClicked(){career_saveSystem.saveCurrent()}function onLoadButtonClicked(){console.log(`onLoadButtonClicked`)}function onSettingsButtonClicked(){console.log(`onSettingsButtonClicked`)}return(_ctx,_cache)=>withDirectives((openBlock(),createElementBlock(`div`,_hoisted_1$198,[createVNode(unref(careerSimpleStats_default)),createBaseVNode(`div`,_hoisted_2$160,[createBaseVNode(`div`,_hoisted_3$141,[createVNode(unref(careerStatus_default),{class:`pause-profile-status`}),createBaseVNode(`div`,_hoisted_4$117,[createVNode(unref(bngImageTile_default),{label:`Exit Career`,icon:unref(icons).abandon,onClick:onExitCareerButtonClicked,ratio:ICON_RATIO},null,8,[`icon`]),createVNode(unref(bngCard_default),{class:`system-buttons`},{default:withCtx(()=>[createVNode(unref(bngButton_default),{tabindex:`1`,accent:unref(ACCENTS).text,onClick:onSaveButtonClicked},{default:withCtx(()=>[..._cache[1]||=[createTextVNode(`Save`,-1)]]),_:1},8,[`accent`]),createVNode(unref(bngButton_default),{tabindex:`1`,accent:unref(ACCENTS).text,onClick:onLoadButtonClicked},{default:withCtx(()=>[..._cache[2]||=[createTextVNode(`Load`,-1)]]),_:1},8,[`accent`]),createVNode(unref(bngButton_default),{tabindex:`1`,accent:unref(ACCENTS).text,onClick:onSettingsButtonClicked},{default:withCtx(()=>[..._cache[3]||=[createTextVNode(`Settings`,-1)]]),_:1},8,[`accent`])]),_:1})]),createVNode(unref(bngCard_default),{class:`main-content grid`},{default:withCtx(()=>[createBaseVNode(`div`,_hoisted_5$102,[createVNode(unref(bngButton_default),{class:`button prev-button`,onClick:onMiddlePillsSelectPrevious,tabindex:`0`,accent:unref(ACCENTS).text},{default:withCtx(()=>[..._cache[4]||=[createTextVNode(`Previous`,-1)]]),_:1},8,[`accent`]),createVNode(unref(bngPillFiltersContainer_default),{class:`tabs-track`,ref_key:`middlePillsContainerRef`,ref:middlePillsContainerRef,"html-id":`middle-pills-container-ref`,options:MIDDLE_PILL_OPTIONS,"select-on-navigation":!1,onValueChanged:middlePillsValueChanged,required:!0,"has-checked-icon":!1},null,512),createVNode(unref(bngButton_default),{class:`button next-button`,onClick:onMiddlePillsSelectNext,tabindex:`0`,accent:unref(ACCENTS).text},{default:withCtx(()=>[..._cache[5]||=[createTextVNode(`Next`,-1)]]),_:1},8,[`accent`])]),createBaseVNode(`div`,_hoisted_6$85,[currentPillTypeSelected.value==`Map`?(openBlock(),createBlock(PauseMapPreview_default,{key:0})):createCommentVNode(``,!0),currentPillTypeSelected.value==`Milestones`?(openBlock(),createBlock(PauseMilestonesPreview_default,{key:1})):createCommentVNode(``,!0),currentPillTypeSelected.value===void 0?withDirectives((openBlock(),createBlock(unref(aspectRatio_default),{key:2,style:{background:`red`},ratio:`4:3`},{default:withCtx(()=>[createBaseVNode(`div`,_hoisted_7$73,[createVNode(unref(bngCardHeading_default),{style:{color:`white`},type:`ribbon`},{default:withCtx(()=>[..._cache[6]||=[createTextVNode(`Undefined Pill Type!`,-1)]]),_:1})])]),_:1})),[[unref(BngSoundClass_default),`bng_click_generic`]]):createCommentVNode(``,!0)])]),_:1}),createBaseVNode(`div`,_hoisted_8$60,[(openBlock(!0),createElementBlock(Fragment,null,renderList(contextButtons.value,btn=>(openBlock(),createBlock(unref(bngImageTile_default),{label:btn.label,icon:unref(icons)[btn.icon],onClick:$event=>onContextButtonClicked(btn),ratio:ICON_RATIO},null,8,[`label`,`icon`,`onClick`]))),256))]),createBaseVNode(`div`,_hoisted_9$54,[createVNode(unref(bngImageTile_default),{class:`photo-mode`,label:`Photo Mode`,icon:unref(icons).photo,ratio:ICON_RATIO},null,8,[`icon`]),createVNode(unref(bngCard_default),{class:`tod`},{default:withCtx(()=>[_cache[7]||=createBaseVNode(`div`,{class:`icon-box`},`I'm an icon box!`,-1),createVNode(unref(bngSlider_default),{ref:`iptChanged`,min:0,max:1,step:.1,modelValue:todSliderValue.value,"onUpdate:modelValue":_cache[0]||=$event=>todSliderValue.value=$event,onValueChanged:onTODChanged},null,8,[`modelValue`]),createVNode(unref(bngInput_default),{class:`tod-value`})]),_:1})])])]),_cache[8]||=createBaseVNode(`div`,{style:{background:`green`,height:`5em`}},`FOOTER`,-1)])),[[unref(BngBlur_default)]])}},PauseBigMiddlePanel_default=__plugin_vue_export_helper_default(_sfc_main$223,[[`__scopeId`,`data-v-7b3f120b`]]),_hoisted_1$197={class:`back-text`},_sfc_main$222={__name:`BackAside`,emits:[`click`],setup(__props,{emit:__emit}){let emit$1=__emit;return(_ctx,_cache)=>withDirectives((openBlock(),createElementBlock(`div`,{class:`back-aside`,onClick:_cache[0]||=$event=>emit$1(`click`)},[createVNode(unref(bngIcon_default),{class:`back-arrow`,type:unref(icons).arrowLargeLeft},null,8,[`type`]),createBaseVNode(`span`,_hoisted_1$197,[createVNode(unref(bngBinding_default),{class:`back-binding`,"ui-event":`back`,controller:``,"track-ignore":``}),createTextVNode(` `+toDisplayString(_ctx.$tt(`ui.common.back`)),1)])])),[[unref(BngSoundClass_default),`bng_click_hover_generic`]])}},BackAside_default=__plugin_vue_export_helper_default(_sfc_main$222,[[`__scopeId`,`data-v-2fa47f3c`]]);const PROFILE_NAME_MAX_LENGTH=100,useProfilesStore=defineStore(`profiles`,()=>{async function loadProfile(profileName,tutorialEnabled,isAdd=!1){if(console.log(`profileStore.loadProfile`,profileName,tutorialEnabled,isAdd),!profileName)return console.warn(`profileStore.loadProfile: profileName is required. Not loading profile.`),!1;if(profileName.length>100&&isAdd)return console.warn(`profileStore.loadProfile: profileName is too long. Not loading profile.`),!1;console.log(`profileStore.loadProfile: creating or loading career and starting`,profileName),/^ +| +$/.test(profileName)&&(profileName=profileName.replace(/^ +| +$/g,``));let createOrLoadCareerAndStartResult=await Lua_default.career_career.createOrLoadCareerAndStart(profileName,null,tutorialEnabled);console.log(`profileStore.loadProfile: createOrLoadCareerAndStartResult`,createOrLoadCareerAndStartResult);let toastrMessage=isAdd?`added`:`loaded`;window.globalAngularRootScope.$broadcast(`toastrMsg`,{type:`info`,msg:$translate.contextTranslate(`ui.career.notification.${toastrMessage}`),config:{positionClass:`toast-top-right`,toastClass:`beamng-message-toast`,timeOut:5e3,extendedTimeOut:1e3}})}return{loadProfile}});var _hoisted_1$196={class:`profile-card-cover`},_hoisted_2$159={class:`profile-card-container`},_hoisted_3$140={class:`profile-card-title`},_hoisted_4$116={key:0,class:`profile-card-date`},_hoisted_5$101={key:0},_hoisted_6$84={key:1},_hoisted_7$72={class:`profile-card-content`},_hoisted_8$59={key:0,class:`profile-manage`},_hoisted_9$53={key:0,class:`profile-manage-rename`},_hoisted_10$46={key:1,class:`profile-manage-delete`},_hoisted_11$41={key:2,class:`profile-manage-main`},MENU_ITEMS$3={RENAME:`rename`,DELETE:`delete`},_sfc_main$221={__name:`ProfileCard`,props:{id:{type:String,required:!0},date:{type:String,required:!0},creationDate:{type:String,required:!0},incompatibleVersion:Boolean,outdatedVersion:{type:Boolean,required:!0},preview:{type:String,default:`/ui/modules/career/profilePreview_WCUSA.jpg`},beamXP:Object,vouchers:Object,vehicleCount:Number,money:Object,insuranceScore:Object,active:Boolean,branches:Array,disabled:Boolean},emits:[`card:activate`,`load`,`rename`],setup(__props,{emit:__emit}){let props=__props,emit$1=__emit,isActivated=ref(!1),isManage=ref(!1),currentMenu=ref(null),expanded=ref(!1),internalDisabled=ref(!1),cardStates=reactive({focused:!1,hovered:!1}),validateName=inject(`validateName`),nameError=ref(null),lastPlayedDescription=computed(()=>timeSpan(props.date));watch(()=>props.disabled,value=>{nextTick(()=>{internalDisabled.value=value,value&&(expanded.value=!1)})});let onScopeChanged=value=>{isActivated.value=value},cardFooterStyles$1={"background-color":`hsla(217, 22%, 12%, 1)`},validateFn=name=>{let res=validateName(name);return name===props.id&&(res=null),res?nameError.value=res:nameError.value=null,!res},canDeactivate=()=>!isManage.value,canBubbleEvent=e=>e.detail.name===`menu`&&!isManage.value;function onFocused(focused$1){cardStates.focused=focused$1,updatedExpanded()}function onHover(hover){cardStates.hovered=hover,updatedExpanded()}function updatedExpanded(){let enable=cardStates.focused||cardStates.hovered;!enable&&(isActivated.value||isManage.value)||(expanded.value=enable)}function enableManage(enable=!0){nextTick(()=>isManage.value=enable),enable&&!isActivated.value&&(isActivated.value=!0),emit$1(`card:activate`,enable)}function goBack(){if(saveName.value=props.id,currentMenu.value)currentMenu.value=null;else if(isManage.value)enableManage(!1);else return!0}let saveName=ref(props.id),deleteProfile=()=>{Lua_default.career_saveSystem.removeSaveSlot(props.id),Lua_default.career_career.sendAllCareerSaveSlotsData()},updateProfileName=()=>emit$1(`rename`,saveName.value);return(_ctx,_cache)=>withDirectives((openBlock(),createBlock(unref(bngCard_default),{backgroundImage:__props.preview,footerStyles:cardFooterStyles$1,hideFooter:!expanded.value&&!isManage.value,class:normalizeClass([{"profile-card-active":__props.active,"manage-active":isManage.value,"profile-outdated":__props.incompatibleVersion},`profile-card`]),animateFooterDelay:expanded.value?`0s`:`0.1s`,animateFooterType:`slide`,onActivate:_cache[5]||=$event=>onScopeChanged(!0),onDeactivate:_cache[6]||=$event=>onScopeChanged(!1),onFocusin:_cache[7]||=withModifiers($event=>onFocused(!0),[`self`]),onFocusout:_cache[8]||=withModifiers($event=>onFocused(!1),[`self`]),onMouseover:_cache[9]||=$event=>onHover(!0),onMouseleave:_cache[10]||=$event=>onHover(!1)},{buttons:withCtx(()=>[isManage.value?(openBlock(),createElementBlock(Fragment,{key:0},[currentMenu.value===MENU_ITEMS$3.RENAME?withDirectives((openBlock(),createBlock(unref(bngButton_default),{key:0,disabled:nameError.value!==null||saveName.value===props.id,onClick:updateProfileName},{default:withCtx(()=>[..._cache[11]||=[createTextVNode(` Save `,-1)]]),_:1},8,[`disabled`])),[[unref(BngOnUiNav_default),void 0,`ok`,{asMouse:!0,focusRequired:!0}],[unref(BngSoundClass_default),`bng_click_generic`]]):createCommentVNode(``,!0),withDirectives((openBlock(),createBlock(unref(bngButton_default),{accent:`outlined`,onClick:goBack},{default:withCtx(()=>[..._cache[12]||=[createTextVNode(` Back `,-1)]]),_:1})),[[unref(BngOnUiNav_default),void 0,`ok`,{asMouse:!0,focusRequired:!0}],[unref(BngSoundClass_default),`bng_cancel_generic`]])],64)):(openBlock(),createElementBlock(Fragment,{key:1},[withDirectives((openBlock(),createBlock(unref(bngButton_default),{accent:`outlined`,onClick:enableManage},{default:withCtx(()=>[..._cache[13]||=[createTextVNode(`Manage `,-1)]]),_:1})),[[unref(BngOnUiNav_default),void 0,`ok`,{asMouse:!0,focusRequired:!0}],[unref(BngSoundClass_default),`bng_click_generic`]]),withDirectives((openBlock(),createBlock(unref(bngButton_default),{onClick:_cache[4]||=$event=>_ctx.$emit(`load`,__props.id),disabled:__props.active||__props.incompatibleVersion},{default:withCtx(()=>[..._cache[14]||=[createTextVNode(`Load `,-1)]]),_:1},8,[`disabled`])),[[unref(BngOnUiNav_default),void 0,`ok`,{asMouse:!0,focusRequired:!0}],[unref(BngSoundClass_default),`bng_click_generic`]])],64))]),default:withCtx(()=>[createBaseVNode(`div`,_hoisted_1$196,[createBaseVNode(`div`,_hoisted_2$159,[createBaseVNode(`div`,_hoisted_3$140,toDisplayString(_ctx.$ctx_t(__props.id)),1),isManage.value?createCommentVNode(``,!0):(openBlock(),createElementBlock(`div`,_hoisted_4$116,[__props.active?(openBlock(),createElementBlock(`span`,_hoisted_5$101,toDisplayString(_ctx.$ctx_t(`ui.career.nowplaying`)),1)):(openBlock(),createElementBlock(`span`,_hoisted_6$84,toDisplayString(_ctx.$ctx_t(`ui.career.lastplayed`))+` `+toDisplayString(lastPlayedDescription.value),1))]))])]),withDirectives((openBlock(),createElementBlock(`div`,_hoisted_7$72,[isManage.value?(openBlock(),createElementBlock(`div`,_hoisted_8$59,[currentMenu.value===MENU_ITEMS$3.RENAME?(openBlock(),createElementBlock(`div`,_hoisted_9$53,[createVNode(unref(bngInput_default),{modelValue:saveName.value,"onUpdate:modelValue":_cache[0]||=$event=>saveName.value=$event,maxlength:unref(100),validate:validateFn,errorMessage:nameError.value,externalLabel:`Save Name`,onKeydown:_cache[1]||=withKeys(withModifiers(()=>{},[`prevent`]),[`enter`])},null,8,[`modelValue`,`maxlength`,`errorMessage`])])):currentMenu.value===MENU_ITEMS$3.DELETE?(openBlock(),createElementBlock(`div`,_hoisted_10$46,[createBaseVNode(`span`,null,toDisplayString(_ctx.$ctx_t(`ui.career.deletePrompt`)),1),withDirectives(createVNode(unref(bngButton_default),{label:_ctx.$ctx_t(`ui.common.yes`),accent:`attention`,onClick:deleteProfile},null,8,[`label`]),[[unref(BngOnUiNav_default),void 0,`ok`,{asMouse:!0,focusRequired:!0}],[unref(BngSoundClass_default),`bng_click_generic`]]),withDirectives(createVNode(unref(bngButton_default),{label:_ctx.$ctx_t(`ui.common.no`),accent:`secondary`,onClick:goBack},null,8,[`label`]),[[unref(BngOnUiNav_default),void 0,`ok`,{asMouse:!0,focusRequired:!0}],[unref(BngSoundClass_default),`bng_cancel_generic`]])])):(openBlock(),createElementBlock(`div`,_hoisted_11$41,[withDirectives(createVNode(unref(bngButton_default),{accent:`secondary`,label:_ctx.$ctx_t(`ui.career.rename`),disabled:__props.active,onClick:_cache[2]||=()=>currentMenu.value=MENU_ITEMS$3.RENAME},null,8,[`label`,`disabled`]),[[unref(BngOnUiNav_default),void 0,`ok`,{asMouse:!0,focusRequired:!0}],[unref(BngSoundClass_default),`bng_click_generic`]]),withDirectives(createVNode(unref(bngButton_default),{accent:`secondary`,label:_ctx.$ctx_t(`ui.career.delete`),disabled:__props.active,onClick:_cache[3]||=()=>currentMenu.value=MENU_ITEMS$3.DELETE},null,8,[`label`,`disabled`]),[[unref(BngOnUiNav_default),void 0,`ok`,{asMouse:!0,focusRequired:!0}],[unref(BngSoundClass_default),`bng_click_generic`]]),createVNode(unref(bngButton_default),{label:_ctx.$ctx_t(`ui.career.mods`),accent:`secondary`,disabled:``},null,8,[`label`]),createVNode(unref(bngButton_default),{label:_ctx.$ctx_t(`ui.career.backup`),accent:`secondary`,disabled:``},null,8,[`label`])]))])):(openBlock(),createBlock(ProfileStatus_default,{key:1,branches:__props.branches,beamXP:__props.beamXP,vouchers:__props.vouchers,vehicleCount:__props.vehicleCount,money:__props.money,insuranceScore:__props.insuranceScore},null,8,[`branches`,`beamXP`,`vouchers`,`vehicleCount`,`money`,`insuranceScore`]))])),[[unref(BngOnUiNav_default),goBack,`menu,back`]])]),_:1},8,[`backgroundImage`,`hideFooter`,`class`,`animateFooterDelay`])),[[unref(BngScopedNav_default),{canDeactivate,canBubbleEvent}],[unref(BngSoundClass_default),`bng_hover_generic`],[unref(BngDisabled_default),internalDisabled.value]])}},ProfileCard_default=__plugin_vue_export_helper_default(_sfc_main$221,[[`__scopeId`,`data-v-16215408`]]),cardFooterStyles={"background-color":`hsla(217, 22%, 12%, 1)`},_sfc_main$220={__name:`ProfileCreateCard`,props:{profileName:{required:!0},profileNameModifiers:{}},emits:mergeModels([`card:activate`,`load`],[`update:profileName`]),setup(__props,{emit:__emit}){let emit$1=__emit,profileName=useModel(__props,`profileName`),tutorialChecked=ref(!0),isActive=ref(!1),validateName=inject(`validateName`),nameError=ref(null),startButton=ref(null),cancelButton=ref(null),validateFn=name=>{let res=validateName(name);return res?nameError.value=res:nameError.value=null,!res},load=()=>emit$1(`load`,profileName.value,tutorialChecked.value);function setActive(value){isActive.value=value,emit$1(`card:activate`,value)}function onCancel(event){setTimeout(()=>{isActive.value=!1,emit$1(`card:activate`,!1)},200)}function onEnter(event){event.preventDefault();let focusButton=nameError.value?cancelButton:startButton;focusButton.value&&nextTick(()=>setFocusExternal(focusButton.value.$el))}function onMenu(){setActive(!1)}return(_ctx,_cache)=>withDirectives((openBlock(),createBlock(unref(bngCard_default),{hideFooter:!isActive.value,footerStyles:cardFooterStyles,class:`profile-create-card`,onActivate:_cache[3]||=()=>setActive(!0),onDeactivate:_cache[4]||=()=>setActive(!1)},{buttons:withCtx(()=>[withDirectives((openBlock(),createBlock(unref(bngButton_default),{ref_key:`startButton`,ref:startButton,disabled:nameError.value!==null,onClick:withModifiers(load,[`stop`])},{default:withCtx(()=>[..._cache[6]||=[createTextVNode(`Start`,-1)]]),_:1},8,[`disabled`])),[[unref(BngOnUiNav_default),void 0,`ok`,{asMouse:!0,focusRequired:!0}]]),withDirectives((openBlock(),createBlock(unref(bngButton_default),{ref_key:`cancelButton`,ref:cancelButton,accent:`outlined`,onClick:withModifiers(onCancel,[`stop`])},{default:withCtx(()=>[..._cache[7]||=[createTextVNode(`Cancel`,-1)]]),_:1})),[[unref(BngOnUiNav_default),void 0,`ok`,{asMouse:!0,focusRequired:!0}]])]),default:withCtx(()=>[withDirectives((openBlock(),createElementBlock(`div`,{class:normalizeClass([{"create-active":isActive.value},`create-content-container`])},[isActive.value?(openBlock(),createElementBlock(Fragment,{key:0},[createVNode(unref(bngInput_default),{modelValue:profileName.value,"onUpdate:modelValue":_cache[0]||=$event=>profileName.value=$event,maxlength:unref(100),validate:validateFn,errorMessage:nameError.value,externalLabel:`Save Name`,onKeydown:withKeys(onEnter,[`enter`])},null,8,[`modelValue`,`maxlength`,`errorMessage`]),createVNode(unref(bngSwitch_default),{modelValue:tutorialChecked.value,"onUpdate:modelValue":_cache[1]||=$event=>tutorialChecked.value=$event,"label-before":``,inline:!1,"label-alignment":unref(LABEL_ALIGNMENTS).START},{default:withCtx(()=>[createTextVNode(toDisplayString(_ctx.$ctx_t(`ui.career.tutorialCheckDesc`)),1)]),_:1},8,[`modelValue`,`label-alignment`]),createBaseVNode(`span`,{class:normalizeClass([`tutorial-desc`,{checked:tutorialChecked.value}])},toDisplayString(_ctx.$ctx_t(`ui.career.tutorialOnDesc`)),3)],64)):(openBlock(),createElementBlock(`div`,{key:1,"bng-nav-item":``,class:`create-content-cover`,onClick:_cache[2]||=withModifiers($event=>setActive(!0),[`stop`])},[..._cache[5]||=[createBaseVNode(`div`,{class:`cover-plus-container`},[createBaseVNode(`div`,{class:`cover-plus-button`},`+`)],-1)]]))],2)),[[unref(BngOnUiNav_default),onMenu,`menu`]])]),_:1},8,[`hideFooter`])),[[unref(BngScopedNav_default),{activated:isActive.value}],[unref(BngBlur_default)],[unref(BngSoundClass_default),`bng_hover_generic`]])}},ProfileCreateCard_default=__plugin_vue_export_helper_default(_sfc_main$220,[[`__scopeId`,`data-v-1524a2bb`]]),_sfc_main$219={__name:`Profiles`,setup(__props){let store$1=useProfilesStore(),{events:events$3}=useBridge(),profiles=ref([]),activeProfileId=ref(null),selectedCard=ref(null),newProfileName=ref(null),onLoad=async id=>{await store$1.loadProfile(id)},onRename=async(profile,newName)=>{await Lua_default.career_saveSystem.renameSaveSlot(profile.id,newName)&&(profile.id=newName)},onCreateSave=async(profileName,tutorialChecked)=>{await store$1.loadProfile(profileName,tutorialChecked,!0)};function onCardActivated(active,index){active?(selectedCard.value=index,index===-1&&(newProfileName.value=getNewName())):selectedCard.value=null}onMounted(()=>{events$3.on(`allCareerSaveSlots`,onProfilesReceived),Lua_default.career_career.sendAllCareerSaveSlotsData()}),onBeforeUnmount(()=>{events$3.off(`allCareerSaveSlots`,onProfilesReceived)}),provide(`validateName`,validateName);let navigateToMainMenu=e=>{activeProfileId.value?window.bngVue.gotoAngularState(`menu.careerPause`):window.bngVue.gotoGameState(`menu.mainmenu`)};function onDeactivate$1(event){event.detail.force||navigateToMainMenu()}async function onProfilesReceived(data){selectedCard.value=null,activeProfileId.value=null,profiles.value=[],!(!data||!Array.isArray(data)||data.length===0)&&(profiles.value=(await updateActiveProfile(data)).map(p$1=>({id:p$1.id,date:p$1.date,creationDate:p$1.creationDate,incompatibleVersion:p$1.incompatibleVersion,outdatedVersion:p$1.outdatedVersion,preview:p$1.preview,beamXP:p$1.beamXP,vouchers:p$1.vouchers,vehicleCount:p$1.vehicleCount,money:p$1.money,insuranceScore:p$1.insuranceScore,branches:p$1.branches})))}async function updateActiveProfile(data){let currentSave=await Lua_default.career_career.sendCurrentSaveSlotData();if(data.sort((a$1,b)=>new Date(b.date)-new Date(a$1.date)),currentSave){activeProfileId.value=currentSave.id;let current=data.find(x=>x.id===currentSave.id);current||=currentSave,data=data.filter(x=>x.id!==currentSave.id),data.splice(0,0,current)}return data}function validateName(newName){return newName?newName.length>100?`Save name cannot be longer than 100 characters`:/[<>:"/\\|?*]/.test(newName)?`Save name cannot contain invalid characters`:profiles.value&&profiles.value.find(profile=>profile.id.toLowerCase()===newName.toLowerCase())?`Save name already exists`:null:`Save name cannot be empty`}function getNewName(){let prefix$1=$translate.contextTranslate(`ui.career.profile`),id;for(let i=1;i<1e3&&(id=`${prefix$1} ${i}`,!(!profiles.value||!profiles.value.find(profile=>profile.id===id)));i++);return id}return onBeforeMount(()=>{Lua_default.simTimeAuthority.pushPauseRequest(`profiles`)}),onUnmounted(()=>{Lua_default.simTimeAuthority.popPauseRequest(`profiles`)}),(_ctx,_cache)=>(openBlock(),createElementBlock(Fragment,null,[withDirectives((openBlock(),createElementBlock(`div`,{class:`profiles-container`,onDeactivate:onDeactivate$1},[createVNode(unref(bngScreenHeading_default),{class:`profiles-title`,preheadings:[_ctx.$ctx_t(`ui.playmodes.career`)]},{default:withCtx(()=>[createTextVNode(toDisplayString(_ctx.$ctx_t(`ui.career.savedProgress`)),1)]),_:1},8,[`preheadings`]),withDirectives(createVNode(BackAside_default,{class:`profiles-back`,onClick:navigateToMainMenu},null,512),[[unref(BngOnUiNav_default),navigateToMainMenu,`back,menu`]]),createVNode(unref(bngList_default),{layout:unref(LIST_LAYOUTS).RIBBON,"target-width":22,"target-height":28,"target-margin":1,"no-background":``},{default:withCtx(()=>[createVNode(ProfileCreateCard_default,{profileName:newProfileName.value,"onUpdate:profileName":_cache[0]||=$event=>newProfileName.value=$event,class:`profile-card`,"onCard:activate":_cache[1]||=value=>onCardActivated(value,-1),onLoad:onCreateSave},null,8,[`profileName`]),(openBlock(!0),createElementBlock(Fragment,null,renderList(profiles.value,(profile,index)=>withDirectives((openBlock(),createBlock(ProfileCard_default,{key:index,id:profile.id,date:profile.date,creationDate:profile.creationDate,incompatibleVersion:profile.incompatibleVersion,outdatedVersion:profile.outdatedVersion,preview:profile.preview,beamXP:profile.beamXP,vouchers:profile.vouchers,vehicleCount:profile.vehicleCount,money:profile.money,insuranceScore:profile.insuranceScore,branches:profile.branches,active:activeProfileId.value===profile.id,disabled:selectedCard.value!==null&&selectedCard.value!==index,class:`profile-card`,"onCard:activate":value=>onCardActivated(value,index),onLoad,onRename:newName=>onRename(profile,newName)},null,8,[`id`,`date`,`creationDate`,`incompatibleVersion`,`outdatedVersion`,`preview`,`beamXP`,`vouchers`,`vehicleCount`,`money`,`insuranceScore`,`branches`,`active`,`disabled`,`onCard:activate`,`onRename`])),[[unref(BngPopover_default),profile.incompatibleVersion?`tooltip-outdated-message`:null,`top`]])),128))]),_:1},8,[`layout`])],32)),[[unref(BngScopedNav_default),{activateOnMount:!0}]]),createVNode(unref(bngPopoverContent_default),{name:`tooltip-outdated-message`},{default:withCtx(()=>[..._cache[2]||=[createBaseVNode(`div`,{class:`tooltip-outdated-message`},`This profile was saved with an old version of the game. It can no longer be loaded.`,-1)]]),_:1})],64))}},Profiles_default=__plugin_vue_export_helper_default(_sfc_main$219,[[`__scopeId`,`data-v-6aef0f62`]]);const useRepairStore=defineStore(`repair`,()=>{let repairOptions=ref({}),vehicleData=ref({}),playerAttributes=ref({}),driverScoreTierData=ref({}),futureDriverScore=ref(0),driverScore=ref(0),resetStore=()=>{repairOptions.value={},vehicleData.value={},playerAttributes.value={},driverScoreTierData.value={},futureDriverScore.value=0,driverScore.value=0};return{repairOptions,vehicleData,playerAttributes,getRepairData:()=>{resetStore(),Lua_default.career_modules_insurance_repairScreen.getRepairData().then(data=>{repairOptions.value=data.repairOptions,vehicleData.value=data.vehicleData,playerAttributes.value=data.playerAttributes,driverScoreTierData.value=data.driverScoreTierData,futureDriverScore.value=data.futureDriverScore,driverScore.value=data.driverScore})},driverScoreTierData,futureDriverScore,driverScore,resetStore}});var _hoisted_1$195={class:`content blue-background`},_hoisted_2$158={class:`vehicle-info`},_hoisted_3$139={class:`right-info-wrapper`},_hoisted_4$115={class:`damage-estimate-wrapper`},_hoisted_5$100={class:`damage-estimate-value`},_hoisted_6$83={key:0},_hoisted_7$71={class:`repair-options`},_hoisted_8$58=[`onClick`],_hoisted_9$52={class:`icon-wrapper`},_hoisted_10$45={key:0,class:`option-text-wrapper`},_hoisted_11$40={class:`smaller-text`},_hoisted_12$30={class:`bigger-text`,style:{"margin-top":`-5px`}},_hoisted_13$26={key:1,class:`option-text-wrapper`},_hoisted_14$25={key:0},_hoisted_15$24={class:`details-wrapper`},_hoisted_16$24={class:`detail-wrapper`},_hoisted_17$19={class:`item`},_hoisted_18$17={key:0,class:`accident-forgivenesses-text`},_hoisted_19$14={key:0,class:`item`},_hoisted_20$12={class:`item-value`},_hoisted_21$11={key:1,class:`renews-in-wrapper`},_hoisted_22$9={class:`renews-in-name`},_hoisted_23$8={class:`renews-in-value`},_hoisted_24$7={class:`detail-wrapper`},_hoisted_25$6={class:`item`},_hoisted_26$5={class:`item-value`},_hoisted_27$5={class:`item`},_hoisted_28$4={class:`item-value`},_hoisted_29$4={key:0,class:`item`},_hoisted_30$4={class:`item-value`},_hoisted_31$4={key:1,class:`item`},_hoisted_32$4={class:`item-value`},_hoisted_33$4={class:`item total-cost`},_hoisted_34$4={class:`item-value`},_hoisted_35$3={key:0},_hoisted_36$3={key:1},_hoisted_37$2={class:`confirm-repair-money-wrapper`},_hoisted_38$2={key:2},_hoisted_39$2={class:`confirm-repair-money-wrapper`},_sfc_main$218={__name:`RepairMain`,setup(__props){let{units}=useBridge();useComputerStore();let repairStore=useRepairStore(),selectedRepairOptionKey=ref(null),selectedRepairTimeOptionIndex=ref(1),currentRepairOption=computed(()=>!selectedRepairOptionKey.value||!repairStore.repairOptions?null:repairStore.repairOptions[selectedRepairOptionKey.value]),accidentForgivenessesText=computed(()=>!repairStore.repairOptions.insuranceRepairData.accidentForgivenesses>0?`(No Accident Forgivenesses left)`:`(`+repairStore.repairOptions.insuranceRepairData.accidentForgivenesses+` Accident Forgivenesses left)`),selectedRepairTimeOption=computed(()=>currentRepairOption.value?.repairTimeOptions?.choices?currentRepairOption.value.repairTimeOptions.choices.find(choice=>choice.id===selectedRepairTimeOptionIndex.value):null),renewsInFormatted=computed(()=>currentRepairOption.value?.renewsIn?units.buildString(`length`,currentRepairOption.value.renewsIn*1e3,0):``);watch(()=>repairStore.repairOptions,newOptions=>{if(newOptions&&Object.keys(newOptions).length>0&&!selectedRepairOptionKey.value){let selectedKey=Object.keys(newOptions).find(key=>newOptions[key].useInsurance)||Object.keys(newOptions)[0];selectedRepairOptionKey.value=selectedKey,newOptions[selectedKey]?.repairTimeOptions?.currentValueId&&(selectedRepairTimeOptionIndex.value=newOptions[selectedKey].repairTimeOptions.currentValueId)}},{immediate:!0}),watch(()=>selectedRepairOptionKey.value,newKey=>{newKey&&repairStore.repairOptions[newKey]?.repairTimeOptions?.currentValueId?selectedRepairTimeOptionIndex.value=repairStore.repairOptions[newKey].repairTimeOptions.currentValueId:selectedRepairTimeOptionIndex.value=1});let onRepairOptionClick=key=>{selectedRepairOptionKey.value=key},close=()=>{Lua_default.career_modules_insurance_repairScreen.closeMenu()},startRepair=(repairOptionKey,repairTimeOptionIndex)=>{selectedRepairTimeOption.value&&Lua_default.career_modules_insurance_repairScreen.startRepairInGarage(repairStore.vehicleData.invVehId,{repairTime:selectedRepairTimeOption.value.value,isInsuranceRepair:currentRepairOption.value.useInsurance,cost:{repairTimeCost:selectedRepairTimeOption.value.premiumInfluence,deductible:currentRepairOption.value.useInsurance?repairStore.repairOptions.insuranceRepairData.deductible:repairStore.vehicleData.damageCost}})};return onMounted(()=>{repairStore.getRepairData()}),onUnmounted(()=>{repairStore.resetStore()}),(_ctx,_cache)=>(openBlock(),createBlock(ComputerWrapper_default,{path:[`Repair`],title:`Repair ${unref(repairStore).vehicleData.name}`,back:``,onBack:close},{default:withCtx(()=>[unref(repairStore).vehicleData.name?(openBlock(),createBlock(unref(bngCard_default),{key:0,class:`repairMain blue-background`},{default:withCtx(()=>[createBaseVNode(`div`,_hoisted_1$195,[_cache[23]||=createBaseVNode(`div`,{class:`title`},`Vehicle Repair`,-1),createBaseVNode(`div`,_hoisted_2$158,[createVNode(unref(insuranceVehTile_default),{class:`vehicle-tile`,vehicle:unref(repairStore).vehicleData},{rightContent:withCtx(()=>[createBaseVNode(`div`,_hoisted_3$139,[createBaseVNode(`div`,_hoisted_4$115,[_cache[2]||=createBaseVNode(`span`,{class:`damage-estimate-text`},` Damage Estimate: `,-1),createBaseVNode(`span`,_hoisted_5$100,[createVNode(unref(bngUnit_default),{class:`red-price`,money:unref(repairStore).vehicleData.damageCost},null,8,[`money`])])]),unref(repairStore).vehicleData.isInsured?createCommentVNode(``,!0):(openBlock(),createElementBlock(`div`,_hoisted_6$83,[..._cache[3]||=[createBaseVNode(`span`,{class:`not-insured-text`},` Not Insured! `,-1)]]))])]),_:1},8,[`vehicle`])]),createBaseVNode(`div`,null,[_cache[7]||=createBaseVNode(`div`,{class:`repair-options-title`},`Repair Options`,-1),createBaseVNode(`div`,_hoisted_7$71,[(openBlock(!0),createElementBlock(Fragment,null,renderList(unref(repairStore).repairOptions,(repairOption,key)=>(openBlock(),createElementBlock(`div`,{key,class:normalizeClass([`repair-option`,{selected:selectedRepairOptionKey.value===key}]),onClick:$event=>onRepairOptionClick(key)},[createBaseVNode(`div`,_hoisted_9$52,[createVNode(unref(bngIcon_default),{type:repairOption.useInsurance?unref(icons).shieldCheckmark:unref(icons).wrench},null,8,[`type`])]),createBaseVNode(`div`,null,[repairOption.useInsurance?(openBlock(),createElementBlock(`div`,_hoisted_10$45,[_cache[5]||=createBaseVNode(`div`,{class:`bigger-text`},` Insurance Claim `,-1),createBaseVNode(`div`,_hoisted_11$40,toDisplayString(repairOption.insuranceName),1),createBaseVNode(`div`,_hoisted_12$30,[_cache[4]||=createTextVNode(` Deductible : `,-1),createVNode(unref(bngUnit_default),{class:`unit-no-padding`,money:unref(repairStore).repairOptions.insuranceRepairData.deductible},null,8,[`money`])])])):(openBlock(),createElementBlock(`div`,_hoisted_13$26,[..._cache[6]||=[createBaseVNode(`div`,{class:`bigger-text`},` Private Repair `,-1),createBaseVNode(`div`,{class:`smaller-text`},` No Policy Impact `,-1),createBaseVNode(`div`,{class:`bigger-text`},` Full Damage Cost `,-1)]]))])],10,_hoisted_8$58))),128))])]),currentRepairOption.value?(openBlock(),createElementBlock(`div`,_hoisted_14$25,[(openBlock(),createBlock(unref(coverageOption_default),{coverageOption:currentRepairOption.value.repairTimeOptions,key:`repairTime-${selectedRepairOptionKey.value}`,modelValue:selectedRepairTimeOptionIndex.value,"onUpdate:modelValue":_cache[0]||=$event=>selectedRepairTimeOptionIndex.value=$event,simpleSelect:!0,showPerkMode:`none`},null,8,[`coverageOption`,`modelValue`]))])):createCommentVNode(``,!0),createBaseVNode(`div`,_hoisted_15$24,[createBaseVNode(`div`,_hoisted_16$24,[_cache[13]||=createBaseVNode(`h3`,null,`Insurance Impact`,-1),createBaseVNode(`div`,_hoisted_17$19,[createBaseVNode(`span`,null,[_cache[8]||=createBaseVNode(`div`,{class:`item-label`},`Driver Score Change`,-1),currentRepairOption.value.useInsurance?(openBlock(),createElementBlock(`div`,_hoisted_18$17,toDisplayString(accidentForgivenessesText.value),1)):createCommentVNode(``,!0)]),createBaseVNode(`span`,{class:normalizeClass([`item-value`,{"red-text":currentRepairOption.value.useInsurance&&unref(repairStore).futureDriverScorestartRepair(selectedRepairOptionKey.value,selectedRepairTimeOptionIndex.value)},{default:withCtx(()=>[unref(repairStore).vehicleData.needsRepair?selectedRepairTimeOption.value?.canPay?(openBlock(),createElementBlock(`div`,_hoisted_38$2,[_cache[22]||=createTextVNode(` Confirm Repair `,-1),createBaseVNode(`div`,_hoisted_39$2,[createVNode(unref(bngUnit_default),{money:selectedRepairTimeOption.value?.totalPrice},null,8,[`money`])])])):(openBlock(),createElementBlock(`div`,_hoisted_36$3,[_cache[21]||=createTextVNode(` Insufficient funds `,-1),createBaseVNode(`div`,_hoisted_37$2,[createVNode(unref(bngUnit_default),{money:selectedRepairTimeOption.value?.totalPrice},null,8,[`money`])])])):(openBlock(),createElementBlock(`div`,_hoisted_35$3,` Vehicle doesn't need repair `))]),_:1},8,[`disabled`])])]),_:1})):createCommentVNode(``,!0)]),_:1},8,[`title`]))}},RepairMain_default=__plugin_vue_export_helper_default(_sfc_main$218,[[`__scopeId`,`data-v-19ad91be`]]),_hoisted_1$194={class:`awd-container bng-app`},_hoisted_2$157={key:0,class:`awd-table`},_hoisted_3$138={class:`data-name`},_sfc_main$217={__name:`app`,setup(__props,{expose:__expose}){let{$game}=useLibStore(),streamList=[`advancedWheelDebugData`],data=ref([]),hasData=computed(()=>Array.isArray(data.value)&&data.value.length>0),orderedData=computed(()=>Array.isArray(data.value)?data.value.sort((a$1,b)=>a$1.name.toLowerCase().localeCompare(b.name.toLowerCase())):[]);__expose({hasData}),onMounted(()=>{$game.streams.add(streamList),register()}),onUnmounted(()=>{$game.streams.remove(streamList),$game.api.activeObjectLua(`extensions.advancedwheeldebug.registerDebugUser("advancedWheelDebugApp", false)`)});let register=()=>$game.api.activeObjectLua(`extensions.advancedwheeldebug.registerDebugUser("advancedWheelDebugApp", true)`),format$2=value=>value?parseFloat(value).toFixed(3):``;return $game.events.on(`onStreamsUpdate`,streams=>data.value=streams.advancedWheelDebugData),$game.events.on(`VehicleReset`,register),$game.events.on(`VehicleChange`,register),(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$194,[orderedData.value&&orderedData.value.length>0?(openBlock(),createElementBlock(`table`,_hoisted_2$157,[_cache[0]||=createBaseVNode(`thead`,null,[createBaseVNode(`tr`,null,[createBaseVNode(`th`,null,`Name`),createBaseVNode(`th`,null,`Camber`),createBaseVNode(`th`,null,`Toe`),createBaseVNode(`th`,null,`Caster`),createBaseVNode(`th`,null,`SAI`)])],-1),(openBlock(!0),createElementBlock(Fragment,null,renderList(orderedData.value,w=>(openBlock(),createElementBlock(`tr`,null,[createBaseVNode(`td`,_hoisted_3$138,toDisplayString(w.name),1),createBaseVNode(`td`,null,toDisplayString(format$2(w.camber)),1),createBaseVNode(`td`,null,toDisplayString(format$2(w.toe)),1),createBaseVNode(`td`,null,toDisplayString(format$2(w.caster)),1),createBaseVNode(`td`,null,toDisplayString(format$2(w.sai)),1)]))),256))])):createCommentVNode(``,!0)]))}},app_default$2=__plugin_vue_export_helper_default(_sfc_main$217,[[`__scopeId`,`data-v-5eb5aaaa`]]),_hoisted_1$193={class:`legends-container`},TAG=`[beamng.apps:brakeTorqueGraph]`,_sfc_main$216={__name:`app`,setup(__props){let{$game}=useLibStore(),app$1=ref(null),canvas=ref(null),graphList=ref([]),streamsList$1=[`wheelInfo`,`electrics`],colors=[],chart=new SmoothieChart({minValue:0,millisPerPixel:20,interpolation:`linear`,grid:{fillStyle:`rgba(250, 250, 250, 0.8)`,strokeStyle:`rgba(0,0,0,0.3)`,verticalSections:6,millisPerLine:1e3,sharpLines:!0},labels:{fillStyle:`black`}}),speedGraph=new TimeSeries,appResizeObserver=new ResizeObserver(entries=>{let entry=entries[0];canvas.value.width=entry.target.offsetWidth,canvas.value.height=entry.target.offsetHeight}),graphs={},globalMax=2e3;onMounted(()=>{initColors(),initChart(),appResizeObserver.observe(app$1.value),graphList.value=[{title:`ui.apps.brake_torque_graph.speed`,color:colors[0]}],$game.streams.add(streamsList$1),$game.events.on(`onStreamsUpdate`,onStreamsUpdate),$game.events.on(`VehicleReset`,onVehicleReset),$game.events.on(`VehicleChange`,onVehicleChange)}),onBeforeUnmount(()=>{appResizeObserver.unobserve(app$1.value)}),onUnmounted(()=>{$game.events.off(`onStreamsUpdate`,onStreamsUpdate),$game.events.off(`VehicleReset`,onVehicleReset),$game.events.off(`VehicleChange`,onVehicleChange),$game.streams.remove(streamsList$1)});function onStreamsUpdate(streams){for(let stream of streamsList$1)if(!streams[stream])return;globalMax=Math.max(globalMax,streams.electrics.airspeed*15);let xPoint=new Date;for(let w in speedGraph.append(xPoint,streams.electrics.airspeed*15),streams.wheelInfo){let wheelName=streams.wheelInfo[w][0];if(!graphs.hasOwnProperty(wheelName)){graphs[wheelName]=new TimeSeries,logger_default.debug(`${TAG} adding graph for ${wheelName}`);let wheelColor=colors[graphList.value.length%colors.length];graphList.value.push({title:wheelName,color:wheelColor}),chart.addTimeSeries(graphs[wheelName],{strokeStyle:wheelColor,lineWidth:2});return}graphs[wheelName].append(xPoint,streams.wheelInfo[w][8]),globalMax=Math.max(globalMax,streams.wheelInfo[w][8])}chart.options.maxValue=globalMax}function onVehicleReset(data){graphs={},graphList.value=[{title:`Speed`,color:colors[0]}]}function onVehicleChange(data){graphs={},graphList.value=[{title:`Speed`,color:colors[0]}]}function initChart(){chart.addTimeSeries(speedGraph,{strokeStyle:colors[0],lineWidth:2}),chart.streamTo(canvas.value,40)}function initColors(){for(let i=15;i>0;i--){let c=rainbow(15,i);colors.push(`rgb(${Math.round(255*c[0])}, ${Math.round(255*c[1])}, ${Math.round(255*c[2])})`)}}return(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,{class:`btg-app`,ref_key:`app`,ref:app$1},[createBaseVNode(`div`,_hoisted_1$193,[(openBlock(!0),createElementBlock(Fragment,null,renderList(graphList.value,graph=>(openBlock(),createElementBlock(`small`,{class:`legend`,style:normalizeStyle({color:graph.color})},toDisplayString(_ctx.$t(graph.title)),5))),256))]),createBaseVNode(`canvas`,{ref_key:`canvas`,ref:canvas},null,512)],512))}},app_default$3=__plugin_vue_export_helper_default(_sfc_main$216,[[`__scopeId`,`data-v-642d2338`]]),_hoisted_1$192={class:`bus-line bng-app`},_hoisted_2$156={class:`header`},_hoisted_3$137={class:`time`},_hoisted_4$114={class:`logo`},_hoisted_5$99=[`src`],_hoisted_6$82={class:`route-id`},_hoisted_7$70={class:`text`},_hoisted_8$57={class:`destination`},_hoisted_9$51={key:0,class:`display-stops`},_hoisted_10$44={class:`title`},_hoisted_11$39={key:1,class:`next-stop`},_hoisted_12$29={class:`title`},defaultRouteId=`00`,defaultDestination=`Not in service`,defaultRouteColor=`#FFA200`,totalRoutesDisplayed=4,_sfc_main$215={__name:`app`,setup(__props){let{$game}=useLibStore(),timerInterval,navDisplay=reactive({time:``,stopRequested:!1}),localBusRoute=ref(null),routeId=computed(()=>localBusRoute.value&&localBusRoute.value.routeId?localBusRoute.value.routeId.substring(0,3):defaultRouteId),destination=computed(()=>localBusRoute.value&&localBusRoute.value.destination?localBusRoute.value.destination.substring(0,20):defaultDestination),routeColor=computed(()=>localBusRoute.value&&localBusRoute.value.routeColor?localBusRoute.value.routeColor:defaultRouteColor),stops=computed(()=>{if(!localBusRoute.value||!localBusRoute.value.stops)return null;let data=localBusRoute.value.stops.slice(0,-1);return data.length>totalRoutesDisplayed&&(data=data.slice(1).slice(0,totalRoutesDisplayed)),data.reverse()}),nextStop=computed(()=>localBusRoute.value&&localBusRoute.value.stops&&localBusRoute.value.stops.length-1>totalRoutesDisplayed?localBusRoute.value.stops[0]:null);onBeforeMount(()=>{updateTime(),timerInterval=setInterval(()=>{updateTime()},1e3)}),onMounted(()=>{$game.events.on(`BusDisplayUpdate`,onBusDisplayUpdate),$game.events.on(`SetStopRequest`,onSetStopRequest),$game.api.engineLua(`if scenario_busdriver then scenario_busdriver.requestState() end`)}),onUnmounted(()=>{clearInterval(timerInterval),$game.events.off(`BusDisplayUpdate`,onBusDisplayUpdate),$game.events.off(`SetStopRequest`,onSetStopRequest)});function onBusDisplayUpdate(data){console.log(`onBusDisplayUpdate`,data),localBusRoute.value?(localBusRoute.value.routeId=data.routeId,localBusRoute.value.stops=localBusRoute.value.stops.filter(x=>data.tasklist.find(y=>y[0]===x.id))):localBusRoute.value=parseBusData(data)}function onSetStopRequest(data){console.log(`onSetStopRequest`,data),data&&data.stopRequested!==null&&(navDisplay.stopRequested=data.stopRequested)}function updateTime(){let date=new Date;navDisplay.time=`${date.getHours()}:${date.getMinutes()<10?`0`+date.getMinutes():date.getMinutes()}`}function parseBusData(data){return{destination:data.direction,routeId:data.routeId,routeColor:data.routeColor,stops:data.tasklist.map(x=>({id:x[0],name:x[1]}))}}return(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$192,[createBaseVNode(`div`,{class:`content`,style:normalizeStyle({"--routeColor":routeColor.value})},[createBaseVNode(`div`,_hoisted_2$156,[createBaseVNode(`div`,_hoisted_3$137,toDisplayString(navDisplay.time),1),createBaseVNode(`div`,_hoisted_4$114,[createBaseVNode(`img`,{src:unref(getAssetURL)(`images/beamng_logo_50x50.png`)},null,8,_hoisted_5$99)])]),createBaseVNode(`div`,{class:normalizeClass([`route`,{highlight:!stops.value||stops.value.length===0}])},[createBaseVNode(`div`,_hoisted_6$82,[createBaseVNode(`span`,_hoisted_7$70,toDisplayString(routeId.value),1),_cache[0]||=createBaseVNode(`span`,{class:`chevron`},null,-1)]),createBaseVNode(`div`,_hoisted_8$57,toDisplayString(destination.value),1)],2),stops.value?(openBlock(),createElementBlock(`div`,_hoisted_9$51,[(openBlock(!0),createElementBlock(Fragment,null,renderList(stops.value,stop$1=>(openBlock(),createElementBlock(`div`,{class:`stop`,key:stop$1.id},[_cache[1]||=createBaseVNode(`div`,{class:`chevron`},null,-1),createBaseVNode(`div`,_hoisted_10$44,toDisplayString(stop$1.name),1)]))),128))])):createCommentVNode(``,!0),nextStop.value?(openBlock(),createElementBlock(`div`,_hoisted_11$39,[_cache[2]||=createBaseVNode(`div`,{class:`chevron`},null,-1),createBaseVNode(`div`,_hoisted_12$29,toDisplayString(nextStop.value.name),1)])):createCommentVNode(``,!0)],4),createBaseVNode(`div`,{class:normalizeClass([`stop-request`,{requested:navDisplay.stopRequested}])},[createBaseVNode(`div`,{class:normalizeClass([`text`,{glow:navDisplay.stopRequested}])},toDisplayString(_ctx.$t(`ui.busRoute.stopRequested`)),3)],2)]))}},app_default$4=__plugin_vue_export_helper_default(_sfc_main$215,[[`__scopeId`,`data-v-7731db49`]]),_hoisted_1$191={class:`bng-app cd-container`,layout:`column`,"layout-align":`center center`},_sfc_main$214={__name:`app`,setup(__props){let{$game}=useLibStore(),cameraDistance=ref(null);return onMounted(()=>{$game.api.engineLua(`extensions.load("ui_cameraDistanceApp")`)}),onUnmounted(()=>{$game.api.engineLua(`extensions.unload("ui_cameraDistanceApp")`)}),$game.events.on(`cameraDistance`,function(distance,errMsg){distance<0?cameraDistance.value=errMsg:cameraDistance.value=$game.units.buildString(`length`,distance,2)}),(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$191,[createBaseVNode(`span`,null,toDisplayString(cameraDistance.value),1)]))}},app_default$5=__plugin_vue_export_helper_default(_sfc_main$214,[[`__scopeId`,`data-v-d72a4879`]]),_hoisted_1$190={key:0,class:`bng-app thermal-clutch-debug`},_hoisted_2$155={class:`set-name`},_sfc_main$213={__name:`app`,setup(__props){let{$game}=useLibStore(),streamsList$1=[`clutchThermalData`],data=ref([]);onMounted(()=>{$game.streams.add(streamsList$1)}),onUnmounted(()=>{$game.streams.remove(streamsList$1)}),$game.events.on(`onStreamsUpdate`,streams=>{streams.clutchThermalData?data.value=parseData(streams.clutchThermalData):data.value=null});function parseData(data$1){return[{str:$game.units.buildString(`temperature`,data$1.clutchTemperature,0),name:`Clutch temperature`,warn:data$1.clutchTemperature>data$1.maxSafeTemp&&data$1.clutchTemperature<=data$1.efficiencyScaleEnd,error:data$1.clutchTemperature>data$1.efficiencyScaleEnd},{str:$game.units.buildString(`temperature`,data$1.maxSafeTemp,0),name:`Max safe temperature`},{str:$game.units.buildString(`temperature`,data$1.efficiencyScaleEnd,0),name:`Efficiency scale end`},{str:data$1.thermalEfficiency.toFixed(3),name:`Clutch efficiency`,warn:data$1.thermalEfficiency<1&&data$1.thermalEfficiency>=.5,error:data$1.thermalEfficiency<.5},{str:$game.units.buildString(`energy`,data$1.energyToClutch,0),name:`Q to clutch`},{str:$game.units.buildString(`energy`,data$1.energyClutchToBellHousing,0),name:`Q clutch to bell housing`}]}return(_ctx,_cache)=>data.value?(openBlock(),createElementBlock(`div`,_hoisted_1$190,[(openBlock(!0),createElementBlock(Fragment,null,renderList(data.value,(set,index)=>(openBlock(),createElementBlock(`div`,{key:index,class:`set`},[createBaseVNode(`div`,_hoisted_2$155,toDisplayString(set.name),1),createBaseVNode(`div`,{class:normalizeClass([`set-value`,{"thermal-warning":set.warn,"thermal-error":set.error}])},toDisplayString(set.str),3)]))),128))])):createCommentVNode(``,!0)}},app_default$6=__plugin_vue_export_helper_default(_sfc_main$213,[[`__scopeId`,`data-v-c0f00383`]]),_hoisted_1$189={width:`100%`,height:`100%`,viewBox:`0 0 244 244`},_hoisted_2$154=[`transform`],_sfc_main$212={__name:`app`,setup(__props){let streamsList$1=[`sensors`],{$game}=useLibStore(),arrow$3=ref(null),circle=ref(null),yawDegrees=ref(0),bbox=computed(()=>arrow$3.value?arrow$3.value.getBBox():null),rotateOrigin=computed(()=>bbox.value?`${yawDegrees.value} ${bbox.value.x+bbox.value.width/2} ${bbox.value.y+bbox.value.height/2}`:0);onMounted(()=>{$game.events.on(`onStreamsUpdate`,onStreamsUpdate),$game.streams.add(streamsList$1)}),onUnmounted(()=>{$game.events.off(`onStreamsUpdate`,onStreamsUpdate),$game.streams.remove(streamsList$1)});function onStreamsUpdate(streams){for(let stream of streamsList$1)if(!streams[stream])return;yawDegrees.value=streams.sensors.yaw*180/Math.PI+180}return(_ctx,_cache)=>(openBlock(),createElementBlock(`svg`,_hoisted_1$189,[createBaseVNode(`g`,{ref_key:`circle`,ref:circle,transform:`rotate(${rotateOrigin.value})`},[..._cache[0]||=[createStaticVNode(`NESW`,5)]],8,_hoisted_2$154),createBaseVNode(`path`,{d:`M122 90 L105 154 L139 154 Z`,ref_key:`arrow`,ref:arrow$3,class:`arrow`},null,512)]))}},app_default$7=__plugin_vue_export_helper_default(_sfc_main$212,[[`__scopeId`,`data-v-4a5918e7`]]),compassWidth=2e3,_sfc_main$211={__name:`app`,setup(__props){let streamsList$1=[`sensors`],{$game}=useLibStore(),app$1=ref(null),canvas=ref(null),osCanvas=ref(null),widthLess=computed(()=>(compassWidth-canvas.value.width)/2),appResizeObserver=new ResizeObserver(entries=>{let entry=entries[0];canvas.value.width=entry.target.offsetWidth,canvas.value.height=entry.target.offsetHeight});onMounted(()=>{initOsCanvas(),appResizeObserver.observe(app$1.value),$game.events.on(`onStreamsUpdate`,onStreamsUpdate),$game.streams.add(streamsList$1)}),onBeforeUnmount(()=>{appResizeObserver.unobserve(app$1.value)}),onUnmounted(()=>{$game.events.off(`onStreamsUpdate`,onStreamsUpdate),$game.streams.remove(streamsList$1)});function onStreamsUpdate(streams){for(let stream of streamsList$1)if(!streams[stream])return;let canvasCtx=canvas.value.getContext(`2d`);canvasCtx.clearRect(0,0,canvas.value.width,canvas.value.height),canvasCtx.fillStyle=`rgba(255,255,255,0.8)`,canvasCtx.strokeStyle=`rgba(255,255,255,0.6)`;let heading=streams.sensors.yaw,posX=heading*compassWidth/(2*Math.PI)-widthLess.value;canvasCtx.drawImage(osCanvas.value,posX,0),heading*compassWidth/(2*Math.PI)-widthLess.value>0?canvasCtx.drawImage(osCanvas.value,posX-compassWidth,0):posX+compassWidth(openBlock(),createElementBlock(`div`,{class:`container`,ref_key:`app`,ref:app$1},[createBaseVNode(`canvas`,{ref_key:`canvas`,ref:canvas,width:`280`,height:`56`},null,512),createBaseVNode(`canvas`,{ref_key:`osCanvas`,ref:osCanvas,class:`os-canvas`},null,512)],512))}},app_default$8=__plugin_vue_export_helper_default(_sfc_main$211,[[`__scopeId`,`data-v-e608df6a`]]),_hoisted_1$188={transform:`translate(-13.701535,-283.48656)`,style:{display:`inline`},id:`carGroup`},_hoisted_2$153={y:`255.49614`,x:`142.73175`,style:{"font-style":`normal`,"font-variant":`normal`,"font-weight":`normal`,"font-stretch":`normal`,"font-size":`18.66665649px`,"line-height":`1.25`,"font-family":`roboto`,"-inkscape-font-specification":`roboto`,"letter-spacing":`0px`,"word-spacing":`0px`,fill:`#ffffff`},"xml:space":`preserve`},componentDamageMap={body:{FL:{svgId:`bodyFL`,priority:2,tempDamage:!1},FR:{svgId:`bodyFR`,priority:2,tempDamage:!1},ML:{svgId:`bodyML`,priority:2,tempDamage:!1},MR:{svgId:`bodyMR`,priority:2,tempDamage:!1},RL:{svgId:`bodyRL`,priority:2,tempDamage:!1},RR:{svgId:`bodyRR`,priority:2,tempDamage:!1}},engine:{oilStarvation:{svgId:`engine`,priority:0,damageText:`Oil Starvation`,tempDamage:!0},coolantHot:{svgId:`engine`,priority:0,damageText:`Coolant Overheating`,tempDamage:!1},oilHot:{svgId:`engine`,priority:0,damageText:`Oil Overheating`,tempDamage:!1},pistonRingsDamaged:{svgId:`engine`,priority:0,damageText:`Piston Rings Damaged`,tempDamage:!1},rodBearingsDamaged:{svgId:`engine`,priority:0,damageText:`Rod Bearings Damaged`,tempDamage:!1},headGasketDamaged:{svgId:`engine`,priority:0,damageText:`Head Gasket Damaged`,tempDamage:!1},turbochargerHot:{svgId:`engine`,priority:0,damageText:`Turbocharger Overheating`,tempDamage:!1},engineIsHydrolocking:{svgId:`engine`,priority:0,damageText:`Engine is Hydrolocking`,tempDamage:!1},engineReducedTorque:{svgId:`engine`,priority:0,damageText:`Engine Torque Reduced`,tempDamage:!1},mildOverrevDamage:{svgId:`engine`,priority:0,damageText:`Mild Over Rev Damage`,tempDamage:!1},overRevDanger:{svgId:`engine`,priority:0,damageText:`Over Rev Risk`,tempDamage:!1},overTorqueDanger:{svgId:`engine`,priority:0,damageText:`Over Torque Risk`,tempDamage:!1},engineHydrolocked:{svgId:`engine`,priority:1,damageText:`Engine is Hydrolocked`,tempDamage:!1},engineDisabled:{svgId:`engine`,priority:1,damageText:`Engine Disabled`,tempDamage:!1},blockMelted:{svgId:`engine`,priority:1,damageText:`Block Melted`,tempDamage:!1},engineLockedUp:{svgId:`engine`,priority:1,damageText:`Engine Locked Up`,tempDamage:!1},radiatorLeak:{svgId:`radiator`,priority:1,damageText:`Radiator Leaking`,tempDamage:!1}},powertrain:{wheelaxleFL:{svgId:`wheelaxleFL`,priority:1,damageText:`Front Left Axle Broken`,tempDamage:!1},wheelaxleFR:{svgId:`wheelaxleFR`,priority:1,damageText:`Front Right Axle Broken`,tempDamage:!1},wheelaxleRL:{svgId:`wheelaxleRL`,priority:1,damageText:`Rear Left Axle Broken`,tempDamage:!1},wheelaxleRR:{svgId:`wheelaxleRR`,priority:1,damageText:`Rear Right Axle Broken`,tempDamage:!1},driveshaft:{svgId:`driveshaft`,priority:1,damageText:`Driveshaft Broken`,tempDamage:!1},driveshaft_F:{svgId:`driveshaft`,priority:1,damageText:`Front Driveshaft Broken`,tempDamage:!1},mainEngine:{svgId:`engine`,priority:1,damageText:`Engine Broken`,tempDamage:!1}},energyStorage:{mainTank:{svgId:`fueltank`,priority:1,damageText:`Fuel Tank Damaged`,tempDamage:!1}},wheels:{tireFL:{svgId:`tireFL`,priority:0,damageText:`Front Left Tire Burst`,tempDamage:!1},tireFR:{svgId:`tireFR`,priority:0,damageText:`Front Right Tire Burst`,tempDamage:!1},tireRL:{svgId:`tireRL`,priority:0,damageText:`Rear Left Tire Burst`,tempDamage:!1},tireRR:{svgId:`tireRR`,priority:0,damageText:`Rear Right Tire Burst`,tempDamage:!1},brakeFL:{svgId:`brakeFL`,priority:1,damageText:`FL Brake Damaged`,tempDamage:!1},brakeFR:{svgId:`brakeFR`,priority:1,damageText:`FR Brake Damaged`,tempDamage:!1},brakeRL:{svgId:`brakeRL`,priority:1,damageText:`RL Brake Damaged`,tempDamage:!1},brakeRR:{svgId:`brakeRR`,priority:1,damageText:`RR Brake Damaged`,tempDamage:!1},brakeOverHeatFL:{svgId:`brakeFL`,priority:0,damageText:`FL Brake Fading`,tempDamage:!0},brakeOverHeatFR:{svgId:`brakeFR`,priority:0,damageText:`FR Brake Fading`,tempDamage:!0},brakeOverHeatRL:{svgId:`brakeRL`,priority:0,damageText:`RL Brake Fading`,tempDamage:!0},brakeOverHeatRR:{svgId:`brakeRR`,priority:0,damageText:`RR Brake Fading`,tempDamage:!0},FL:{svgId:`tireFL`,priority:1,damageText:`Front Left Tire Broken`,tempDamage:!1},FR:{svgId:`tireFR`,priority:1,damageText:`Front Right Tire Broken`,tempDamage:!1},RL:{svgId:`tireRL`,priority:1,damageText:`Rear Left Tire Broken`,tempDamage:!1},RR:{svgId:`tireRR`,priority:1,damageText:`Rear Right Tire Broken`,tempDamage:!1}}},textDisplayTime=2e3,orangeColor=`rgba(255, 132, 0, 0.6)`,redColor=`rgba(255, 0, 0, 0.6)`,noDataColor=`rgba(0, 0, 0, 0 )`,streamsList=[`wheelThermalData`,`engineInfo`],_sfc_main$210={__name:`app`,setup(__props){let{$game}=useLibStore(),svg=ref(null),tireFL=ref(null),tireFR=ref(null),tireRL=ref(null),tireRR=ref(null),bodyFL=ref(null),bodyML=ref(null),bodyMR=ref(null),driveShaft=ref(null),engine=ref(null),fueltank=ref(null),radiator=ref(null),wheelaxleFL=ref(null),wheelaxleFR=ref(null),brakeFL=ref(null),brakeFR=ref(null),bodyFR=ref(null),bodyRL=ref(null),bodyRR=ref(null),brakeRL=ref(null),brakeRR=ref(null),wheelaxleRL=ref(null),wheelaxleRR=ref(null),damageContainer=ref(null),damageBox=ref(null),damageText=ref(null),appState=reactive({isAppDisplayed:!1,hasDamage:!1,permanentDamagedParts:0,isProcessingMessages:!1}),damageTextQueue=ref([]),componentDamage=ref({body:{FL:{damageDisplayed:!1,reference:bodyFL},FR:{damageDisplayed:!1,reference:bodyFR},ML:{damageDisplayed:!1,reference:bodyML},MR:{damageDisplayed:!1,reference:bodyMR},RL:{damageDisplayed:!1,reference:bodyRL},RR:{damageDisplayed:!1,reference:bodyRR}},engine:{oilStarvation:{damageDisplayed:!1,reference:engine},coolantHot:{damageDisplayed:!1,reference:engine},oilHot:{damageDisplayed:!1,reference:engine},pistonRingsDamaged:{damageDisplayed:!1,reference:engine},rodBearingsDamaged:{damageDisplayed:!1,reference:engine},headGasketDamaged:{damageDisplayed:!1,reference:engine},turbochargerHot:{damageDisplayed:!1,reference:engine},engineIsHydrolocking:{damageDisplayed:!1,reference:engine},engineReducedTorque:{damageDisplayed:!1,reference:engine},mildOverrevDamage:{damageDisplayed:!1,reference:engine},overRevDanger:{damageDisplayed:!1,reference:engine},overTorqueDanger:{damageDisplayed:!1,reference:engine},engineHydrolocked:{damageDisplayed:!1,reference:engine},engineDisabled:{damageDisplayed:!1,reference:engine},blockMelted:{damageDisplayed:!1,reference:engine},engineLockedUp:{damageDisplayed:!1,reference:engine},radiatorLeak:{damageDisplayed:!1,reference:radiator}},powertrain:{wheelaxleFL:{damageDisplayed:!1,reference:wheelaxleFL},wheelaxleFR:{damageDisplayed:!1,reference:wheelaxleFR},wheelaxleRL:{damageDisplayed:!1,reference:wheelaxleRL},wheelaxleRR:{damageDisplayed:!1,reference:wheelaxleRR},driveshaft:{damageDisplayed:!1,reference:driveShaft},driveshaft_F:{damageDisplayed:!1,reference:driveShaft},mainEngine:{damageDisplayed:!1,reference:engine}},energyStorage:{mainTank:{damageDisplayed:!1,reference:fueltank}},wheels:{tireFL:{damageDisplayed:!1,reference:tireFL},tireFR:{damageDisplayed:!1,reference:tireFR},tireRL:{damageDisplayed:!1,reference:tireRL},tireRR:{damageDisplayed:!1,reference:tireRR},brakeFL:{damageDisplayed:!1,reference:brakeFL},brakeFR:{damageDisplayed:!1,reference:brakeFR},brakeRL:{damageDisplayed:!1,reference:brakeRL},brakeRR:{damageDisplayed:!1,reference:brakeRR},brakeOverHeatFL:{damageDisplayed:!1,reference:brakeFL},brakeOverHeatFR:{damageDisplayed:!1,reference:brakeFR},brakeOverHeatRL:{damageDisplayed:!1,reference:brakeRL},brakeOverHeatRR:{damageDisplayed:!1,reference:brakeRR},FL:{damageDisplayed:!1,reference:tireFL},FR:{damageDisplayed:!1,reference:tireFR},RL:{damageDisplayed:!1,reference:tireRL},RR:{damageDisplayed:!1,reference:tireRR}}}),damageTimeout=ref(null),animTimeout=ref(null);onMounted(()=>{$game.events.on(`DamageData`,onDamageData),$game.events.on(`VehicleReset`,onReset),$game.events.on(`VehicleChange`,onReset),$game.events.on(`VehicleFocusChanged`,onVehicleFocusChanged),$game.streams.add(streamsList)}),onUnmounted(()=>{$game.events.off(`DamageData`,onDamageData),$game.events.off(`VehicleReset`,onReset),$game.events.off(`VehicleChange`,onReset),$game.events.off(`VehicleFocusChanged`,onVehicleFocusChanged),$game.streams.remove(streamsList)});function onDamageData(data){for(let type in data)for(let component in data[type]){if(componentDamageMap[type]===void 0||componentDamageMap[type][component]===void 0)continue;let damagedComponent=componentDamage.value[type][component],damageComponentProps=componentDamageMap[type][component];if(!damagedComponent.damageDisplayed&&(data[type][component]===!0||data[type][component]>0)){if(damageComponentProps.priority===1)appState.permanentDamagedParts+=1,clearTimeout(damageTimeout.value),setComponentDamageStyles(damagedComponent.reference,redColor,`flashAnim`);else if(damageComponentProps.priority===0)appState.permanentDamagedParts+=1,clearTimeout(damageTimeout.value),setComponentDamageStyles(damagedComponent.reference,orangeColor,`flashAnim`);else if(damageComponentProps.priority===2){let damageAmount=Math.round(data[type][component]*1e3),bodyColor=`rgba(${150+damageAmount}, ${150-damageAmount}, 0, 0.6)`;setComponentDamageStyles(damagedComponent.reference,bodyColor,``)}appState.hasDamage=!0,damageComponentProps.damageText!==void 0&&(damageTextQueue.value.push(damageComponentProps.damageText),damagedComponent.damageDisplayed=!0)}else damageComponentProps.tempDamage&&(data[type][component]===!0||data[type][component]>0?setComponentDamageStyles(damagedComponent.reference,orangeColor,`flashAnim`):(damagedComponent.damageDisplayed=!1,appState.permanentDamagedParts=-1,setComponentDamageStyles(damagedComponent.reference,noDataColor,``)))}!appState.isAppDisplayed&&appState.hasDamage&&(appState.isAppDisplayed=!0,processDamageText(),appState.permanentDamagedParts===0?showAppTimed():clearTimeout(damageTimeout.value))}function processDamageText(){damageTextQueue.value&&damageTextQueue.value.length>0?(damageContainer.value.style.opacity=1,damageText.value.textContent=damageTextQueue.value[0],damageTextQueue.value.splice(0,1),animTimeout.value=setTimeout(processDamageText,textDisplayTime)):(damageContainer.value.style.opacity=0,damageText.value.textContent=``,clearTimeout(animTimeout.value))}function onReset(){for(let type in componentDamage.value)for(let component in componentDamage.value[type])componentDamage.value[type][component].reference.style.fill=noDataColor;appState.isAppDisplayed=!1,appState.hasDamage=!1,appState.permanentDamagedParts=0,damageTextQueue.value=[],showAppTimed()}function onVehicleFocusChanged(data){data.mode===!0&&onReset()}function showAppTimed(){damageTimeout.value&&clearTimeout(damageTimeout.value),appState.isAppDisplayed=!0,damageTimeout.value=setTimeout(function(){appState.isAppDisplayed=!1},2700)}function setComponentDamageStyles(componentRef,color,anim){componentRef.style.fill=color,anim===``?componentRef.classList=[]:componentRef.classList.add(anim)}return(_ctx,_cache)=>(openBlock(),createElementBlock(`svg`,{ref_key:`svg`,ref:svg,class:`svg-app`,viewBox:`-20 -50 300 527`,style:normalizeStyle({opacity:appState.isAppDisplayed?1:0})},[createBaseVNode(`g`,_hoisted_1$188,[createBaseVNode(`path`,{ref_key:`tireFL`,ref:tireFL,d:`m 40.219516,385.93366 0.0893,-35.49107 c 0,0 0.44642,-5.22322 5.08928,-5.22322 4.64286,0 22.41072,-0.13394 22.41072,-0.13394 0,0 5.44643,-10e-6 5.49107,5.22321 0.0534,6.25041 -0.0447,34.64286 -0.0447,34.64286 l 0.0893,36.25 c 0,0 -0.0446,5.35714 -5.53571,5.44643 -3.12586,0.0508 -21.47322,-10e-6 -21.47322,-10e-6 0,0 -5.98214,10e-6 -6.02678,-5.3125 -0.0375,-4.46412 -0.0893,-35.40178 -0.0893,-35.40178 z`,style:{fill:`none`,"fill-rule":`evenodd`,stroke:`#000000`,"stroke-width":`1px`,"stroke-linecap":`butt`,"stroke-linejoin":`miter`,"stroke-opacity":`1`}},null,512),createBaseVNode(`path`,{style:{fill:`none`,"fill-rule":`evenodd`,stroke:`#000000`,"stroke-width":`1px`,"stroke-linecap":`butt`,"stroke-linejoin":`miter`,"stroke-opacity":`1`},d:`m 212.19799,385.43366 0.0893,-35.49107 c 0,0 0.44642,-5.22322 5.08928,-5.22322 4.64286,0 22.41072,-0.13394 22.41072,-0.13394 0,0 5.44643,-10e-6 5.49107,5.22321 0.0534,6.25041 -0.0447,34.64286 -0.0447,34.64286 l 0.0893,36.25 c 0,0 -0.0446,5.35714 -5.53571,5.44643 -3.12586,0.0508 -21.47322,-10e-6 -21.47322,-10e-6 0,0 -5.98214,10e-6 -6.02678,-5.3125 -0.0375,-4.46412 -0.0893,-35.40178 -0.0893,-35.40178 z`,ref_key:`tireFR`,ref:tireFR},null,512),createBaseVNode(`path`,{ref_key:`tireRR`,ref:tireRR,d:`m 212.19799,654.14795 0.0893,-35.49107 c 0,0 0.44642,-5.22322 5.08928,-5.22322 4.64286,0 22.41072,-0.13394 22.41072,-0.13394 0,0 5.44643,-10e-6 5.49107,5.22321 0.0534,6.25041 -0.0447,34.64286 -0.0447,34.64286 l 0.0893,36.25 c 0,0 -0.0446,5.35714 -5.53571,5.44643 -3.12586,0.0508 -21.47322,-10e-6 -21.47322,-10e-6 0,0 -5.98214,10e-6 -6.02678,-5.3125 -0.0375,-4.46412 -0.0893,-35.40178 -0.0893,-35.40178 z`,style:{fill:`none`,"fill-rule":`evenodd`,stroke:`#000000`,"stroke-width":`1px`,"stroke-linecap":`butt`,"stroke-linejoin":`miter`,"stroke-opacity":`1`}},null,512),createBaseVNode(`path`,{style:{fill:`none`,"fill-rule":`evenodd`,stroke:`#000000`,"stroke-width":`1px`,"stroke-linecap":`butt`,"stroke-linejoin":`miter`,"stroke-opacity":`1`},d:`m 40.219516,654.14795 0.0893,-35.49107 c 0,0 0.44642,-5.22322 5.08928,-5.22322 4.64286,0 22.41072,-0.13394 22.41072,-0.13394 0,0 5.44643,-10e-6 5.49107,5.22321 0.0534,6.25041 -0.0447,34.64286 -0.0447,34.64286 l 0.0893,36.25 c 0,0 -0.0446,5.35714 -5.53571,5.44643 -3.12586,0.0508 -21.47322,-10e-6 -21.47322,-10e-6 0,0 -5.98214,10e-6 -6.02678,-5.3125 -0.0375,-4.46412 -0.0893,-35.40178 -0.0893,-35.40178 z`,ref_key:`tireRL`,ref:tireRL},null,512),createBaseVNode(`path`,{ref_key:`bodyFL`,ref:bodyFL,d:`m 139.30351,268.73244 c 0,0 -20.06962,-0.0115 -32.7295,1.35397 -11.849388,1.27802 -23.33457,5.11217 -35.698872,11.89174 -11.963689,6.55991 -22.259598,16.59274 -27.506842,31.58729 -3.060137,8.74465 -3.902495,25.39725 -3.902495,25.39725 l 9.609942,-0.14814 c 0,0 1.636978,-16.52695 5.208997,-24.93149 3.978738,-9.3615 11.635356,-19.52025 21.213285,-24.53523 10.627835,-5.56471 18.689453,-8.01564 32.759185,-10.2291 11.61143,-1.82671 31.13813,-1.14019 31.13813,-1.14019 z`,style:{fill:`none`,"fill-rule":`evenodd`,stroke:`#000000`,"stroke-width":`1px`,"stroke-linecap":`butt`,"stroke-linejoin":`miter`,"stroke-opacity":`1`}},null,512),createBaseVNode(`path`,{ref_key:`bodyML`,ref:bodyML,d:`m 46.365238,434.85859 c 0,0 -4.37766,0.0905 -6.56641,0.125 -0.0234,2.215 -0.08,17.90873 -0.125,26.86328 0,0 -20.45068,7.80958 -22.22461,10.85938 -1.79329,3.0831 -4.63644,8.09161 -2.46289,8.46094 0,0 25.14091,-3.55661 25.60352,-3.40821 0.0618,2.25563 -0.62153,126.52252 -0.59375,127.77539 1.21285,-0.002 9.6289,0.0312 9.6289,0.0312 l -0.01,-170.70703 z`,style:{fill:`none`,"fill-rule":`evenodd`,stroke:`#000000`,"stroke-width":`1px`,"stroke-linecap":`butt`,"stroke-linejoin":`miter`,"stroke-opacity":`1`}},null,512),createBaseVNode(`path`,{ref_key:`bodyMR`,ref:bodyMR,d:`m 236.6054,434.90159 -0.0117,170.70899 c 0,0 7.91605,-0.0352 9.1289,-0.0332 0.0278,-1.25287 -0.65555,-125.51976 -0.59375,-127.77539 0.46261,-0.1484 25.60352,3.40821 25.60352,3.40821 2.17355,-0.36933 -0.6696,-5.37589 -2.46289,-8.45899 -1.77393,-3.0498 -22.22266,-10.85937 -22.22266,-10.85937 -0.045,-8.95456 -0.10355,-24.64828 -0.12695,-26.86328 -2.18875,-0.0345 -9.31447,-0.12697 -9.31447,-0.12697 z`,style:{fill:`none`,"fill-rule":`evenodd`,stroke:`#000000`,"stroke-width":`1px`,"stroke-linecap":`butt`,"stroke-linejoin":`miter`,"stroke-opacity":`1`}},null,512),createBaseVNode(`path`,{ref_key:`driveShaft`,ref:driveShaft,d:`m 146.88019,519.13977 0.34682,-126.1992 c 0,0 14.81582,-18.06715 -4.26439,-17.94569 -19.92,0.12681 -4.95719,17.95354 -4.95719,17.95354 l 0.0408,126.25385 c -0.48292,33.8145 0.52349,126.53492 0.52349,126.53492 -3.70809,6.93305 -6.96405,16.59296 4.6368,16.4848 11.45601,-0.10682 8.66714,-8.10662 4.65438,-16.55312 -1.97544,-4.15814 -0.98066,-126.5291 -0.98066,-126.5291 z`,style:{fill:`none`,"fill-rule":`evenodd`,stroke:`#000000`,"stroke-width":`0.99999976`,"stroke-linecap":`butt`,"stroke-linejoin":`miter`,"stroke-miterlimit":`4`,"stroke-dasharray":`none`,"stroke-opacity":`1`}},null,512),createBaseVNode(`path`,{ref_key:`engine`,ref:engine,d:`m 122.07373,314.95322 h 33.63152 v 5.9272 h -13.25677 v 5.34505 h 12.93926 l 6.08594,9.31416 h 5.37155 v 4.97461 h 6.00656 v -5.05399 h 8.22927 c 0,0 2.66605,2.98563 3.2282,4.8423 1.71505,5.66443 1.56492,12.04739 0,17.75512 -0.61276,2.23494 -3.54572,5.98011 -3.54572,5.98011 h -7.93821 v -5.39797 h -6.29763 v 11.32517 h -34.98103 l -6.50934,-7.93822 H 113.0771 v -16.51145 h -5.98011 v 15.87643 h -5.1863 v -28.89508 h 4.97462 v 7.62066 h 6.29764 v -7.72651 h 8.99664 v -5.98013 h 14.12999 v -6.19179 h -14.23585 z`,style:{display:`inline`,fill:`none`,"fill-rule":`evenodd`,stroke:`#000000`,"stroke-width":`1.00000012`,"stroke-linecap":`butt`,"stroke-linejoin":`miter`,"stroke-miterlimit":`4`,"stroke-dasharray":`none`,"stroke-opacity":`1`}},null,512),createBaseVNode(`path`,{d:`m 117.17264,721.33809 -7.7414,-9.05075 c 0,0 -1.6874,1.50785 -2.481,2.29715 -0.685,0.6814 -1.3051,1.5911 0.2757,3.6525 0.5444,0.7098 3.2227,3.9338 3.7903,4.5024 1.6325,1.6355 2.5754,1.6201 3.3309,1.0108 0.9517,-0.7675 2.8255,-2.4121 2.8255,-2.4121 z m -5.4902,-9.02777 c -0.2639,-0.33031 -0.3782,-0.42184 0.023,-0.78103 0.2875,-0.31046 1.9506,-1.87788 2.2512,-2.13637 0.2218,-0.19078 0.3561,-0.42492 0.1149,-0.7236 -0.2412,-0.33308 -2.1908,-2.68012 -2.4982,-3.06097 -0.2198,-0.27232 -0.2732,-0.32108 -0.2732,-0.50554 0,-0.75917 0.011,-34.43177 0.015,-35.00437 0,-0.2149 0.056,-0.3086 0.5162,-0.3086 h 51.67845 c 2.0683,0 3.0251,0.3486 4.3679,1.4435 1.1871,0.9678 2.1659,2.0917 2.17,4.6095 0,0 0.065,37.07605 0.065,38.41705 0,1.2398 -0.1967,4.1364 -1.6325,5.5294 -1.0614,1.0299 -3.8532,1.8924 -4.9438,1.8924 -1.5414,0 -37.80368,-0.016 -38.25553,-0.016 -0.32906,0 -0.70707,-0.079 -0.93514,-0.3163 -0.27185,-0.2826 -2.9151,-3.0777 -3.22317,-3.371 -0.15862,-0.151 -0.25989,-0.4548 -0.64972,-0.097 -0.3899,0.3574 -1.73649,1.4573 -2.04669,1.7218 -0.1403,0.1197 -0.2841,0.2357 -0.5523,-0.032 -0.4136,-0.4769 -5.8261,-6.80285 -6.191,-7.25968 z m 20.26835,-10.96158 c -0.003,-4.55255 -0.0326,-8.19817 0,-12.74562 0,-0.7695 -0.32724,-0.97794 -1.30987,-1.85445 -0.76302,-0.68063 -1.41614,-1.23286 -1.90915,-1.69336 -0.36587,-0.34178 -0.85706,-0.80537 -0.84008,-1.1791 0.0258,-0.56967 0.59396,-1.0422 0.93428,-1.21472 0.54578,-0.27667 0.94727,-0.0528 1.23375,0.23366 0.30382,0.30381 1.84818,1.77993 2.58906,2.39496 0.44759,0.37156 0.58562,0.67733 1.67741,0.67733 5.46749,-0.0217 12.23023,-0.18415 18.32732,0 1.09189,0 1.22992,-0.30577 1.67737,-0.67733 0.74089,-0.61503 2.28521,-2.09115 2.58911,-2.39496 0.2865,-0.28643 0.688,-0.51033 1.2338,-0.23366 0.3404,0.17252 0.9085,0.64505 0.9344,1.21472 0.017,0.37373 -0.4743,0.83732 -0.8402,1.1791 -0.493,0.4605 -1.1461,1.01273 -1.909,1.69336 -0.98279,0.87651 -1.30997,1.08495 -1.30997,1.85445 0,4.55255 0.0323,8.19817 0,12.74562 0,0.76951 0.32718,0.97793 1.30997,1.85447 0.7629,0.68062 1.416,1.23285 1.909,1.69335 0.3659,0.34177 0.857,0.80537 0.8402,1.1791 -0.026,0.56967 -0.594,1.04219 -0.9344,1.21472 -0.5458,0.27667 -0.9473,0.0528 -1.2338,-0.23366 -0.3039,-0.30382 -1.84822,-1.77992 -2.58911,-2.39497 -0.44745,-0.37154 -0.58548,-0.67731 -1.67737,-0.67731 -6.55155,0.019 -11.82218,0.18501 -18.32732,0 -1.09179,0 -1.22982,0.30577 -1.67741,0.67731 -0.74088,0.61505 -2.28524,2.09115 -2.58906,2.39497 -0.28648,0.28644 -0.68797,0.51033 -1.23375,0.23366 -0.34032,-0.17253 -0.90842,-0.64505 -0.93428,-1.21472 -0.017,-0.37373 0.47421,-0.83733 0.84008,-1.1791 0.49301,-0.4605 1.14613,-1.01273 1.90915,-1.69335 0.98263,-0.87654 1.30987,-1.08496 1.30987,-1.85447 z m 2.56799,-10.35082 c 0,2.40538 0,5.36454 0,8.01339 0,0.63296 -0.0236,1.4238 0.45482,1.90048 0.45132,0.44967 1.08277,0.42233 1.81926,0.42233 h 13.2426 c 0.7365,0 1.36798,0.0273 1.81926,-0.42233 0.47837,-0.47668 0.45477,-1.26752 0.45477,-1.90048 v -3.94714 c 0,-1.35542 0,-2.71084 0,-4.06625 0,-0.63296 0.0233,-1.42381 -0.45477,-1.90047 -0.45128,-0.44969 -1.08276,-0.42234 -1.81926,-0.42234 h -13.2426 c -0.73649,0 -1.36794,-0.0273 -1.81926,0.42234 -0.47842,0.47666 -0.45482,1.26751 -0.45482,1.90047 z`,style:{fill:`none`,"fill-opacity":`1`,"fill-rule":`evenodd`,stroke:`#000000`,"stroke-width":`1.00000012`,"stroke-linecap":`butt`,"stroke-linejoin":`miter`,"stroke-miterlimit":`4`,"stroke-dasharray":`none`,"stroke-opacity":`1`},ref_key:`fueltank`,ref:fueltank},null,512),createBaseVNode(`path`,{d:`m 162.19586,303.74311 v 1.62868 c 0,0 -0.0239,0.60243 0.40384,0.86252 0.36641,0.22282 3.17759,0.31545 3.59707,-0.042 0.34847,-0.29691 0.34658,-0.78069 0.34658,-0.78069 v -4.32093 c 0,0 -0.004,-0.63642 -0.53018,-0.91858 -0.27049,-0.14492 -2.81926,2.15048 -3.22871,2.49847 -0.49791,0.42318 -0.5886,0.94557 -0.5886,0.94557 z m -8.74296,-2.37979 v 4.00847 c 0,0 -0.0239,0.60243 0.40383,0.86252 0.36641,0.22282 3.17759,0.31545 3.59708,-0.042 0.34846,-0.29691 0.34657,-0.78069 0.34657,-0.78069 v -3.43014 c 0,0 -0.004,-0.63642 -0.53018,-0.91857 -0.27049,-0.14493 -2.94617,-0.75348 -3.2287,-0.64521 -0.61019,0.23381 -0.5886,0.94557 -0.5886,0.94557 z m -8.57375,1.15667 v 2.8518 c 0,0 -0.0239,0.60243 0.40383,0.86252 0.36641,0.22282 3.17759,0.31545 3.59708,-0.042 0.34846,-0.29691 0.34657,-0.78069 0.34657,-0.78069 v -3.78911 c 0,0 -0.002,-0.37799 -0.24416,-0.68051 -0.072,-0.09 -0.16527,-0.17335 -0.28602,-0.23806 -0.27049,-0.14492 -2.94617,0.76217 -3.2287,0.87043 -0.61019,0.23381 -0.5886,0.94557 -0.5886,0.94557 z m -8.63016,2.23357 v 0.61823 c 0,0 -0.0239,0.60243 0.40383,0.86252 0.36642,0.22282 3.17759,0.31545 3.59707,-0.042 0.34847,-0.29691 0.34658,-0.78069 0.34658,-0.78069 v -1.35611 c 0,0 -0.004,-0.63641 -0.53017,-0.91857 -0.2705,-0.14492 -2.94617,0.56274 -3.22871,0.671 -0.61019,0.23381 -0.5886,0.94557 -0.5886,0.94557 z m -8.50835,1.48075 c 0.36641,0.22282 3.17758,0.31545 3.59707,-0.042 0.34847,-0.29691 0.34658,-0.50066 0.34658,-0.50066 0,0 -0.004,-1.03528 -0.53018,-1.31744 -0.27049,-0.14492 -2.94617,-0.0851 -3.22871,0.0232 -0.61018,0.23381 -0.5886,1.10014 -0.5886,1.10014 0,0 -0.0239,0.47668 0.40384,0.73676 z m -9.0904,-2.1588 v 1.29628 c 0,0 -0.0239,0.60243 0.40383,0.86252 0.36642,0.22282 3.17759,0.31545 3.59707,-0.042 0.34847,-0.29691 0.34658,-0.78069 0.34658,-0.78069 v -0.5584 c 0,0 -0.004,-0.63642 -0.53017,-0.91858 -0.2705,-0.14492 -2.94617,-0.91301 -3.22871,-0.80474 -0.61019,0.23381 -0.5886,0.94556 -0.5886,0.94556 z m 52.345,1.37742 v -16.61221 c 0,0 -0.0239,-0.60242 0.40383,-0.86252 0.36642,-0.22281 3.17759,-0.31544 3.59707,0.042 0.34847,0.29692 0.34658,0.78069 0.34658,0.78069 v 16.63216 c 0,0 -0.004,0.63642 -0.53017,0.91857 -0.2705,0.14493 -2.94617,0.1552 -3.22871,0.0469 -0.61019,-0.23381 -0.5886,-0.94556 -0.5886,-0.94556 z m -8.79938,-16.61221 c 0,0 -0.0239,-0.60242 0.40384,-0.86252 0.36641,-0.22281 3.17759,-0.31544 3.59707,0.042 0.34847,0.29692 0.34658,0.78069 0.34658,0.78069 v 3.32029 c 0,0 -0.004,0.63641 -0.53018,0.91857 -0.27049,0.14492 -2.60773,-2.10106 -3.22871,-2.63237 -0.4965,-0.42482 -0.5886,-0.97378 -0.5886,-0.97378 z m -8.74296,0 c 0,0 -0.0239,-0.60242 0.40383,-0.86252 0.36641,-0.22281 3.17759,-0.31544 3.59708,0.042 0.34846,0.29692 0.34657,0.78069 0.34657,0.78069 v 1.74529 c 0,0 -0.004,0.63642 -0.53018,0.91857 -0.27049,0.14493 -2.94617,-0.12683 -3.2287,-0.2351 -0.61019,-0.23381 -0.5886,-0.77636 -0.5886,-0.77636 z m -8.57375,0 c 0,0 -0.0239,-0.60242 0.40383,-0.86252 0.36641,-0.22281 3.17759,-0.31544 3.59708,0.042 0.34846,0.29692 0.34657,0.78069 0.34657,0.78069 v 1.80688 c 0,0 -0.002,0.378 -0.24416,0.68052 -0.072,0.09 -0.16527,0.17335 -0.28602,0.23805 -0.27049,0.14493 -2.94617,1.1141 -3.2287,1.00584 -0.61019,-0.23381 -0.5886,-0.81866 -0.5886,-0.81866 z m -8.63016,0 c 0,0 -0.0239,-0.60242 0.40383,-0.86252 0.36642,-0.22281 3.17759,-0.31544 3.59707,0.042 0.34847,0.29692 0.34658,0.78069 0.34658,0.78069 v 4.46516 c 0,0 -0.004,0.63641 -0.53017,0.91857 -0.2705,0.14493 -2.94617,0.97309 -3.22871,0.86482 -0.61019,-0.23381 -0.6027,-0.81866 -0.6027,-0.81866 z m -8.91219,0 c 0,0 -0.0239,-0.60242 0.40384,-0.86252 0.36641,-0.22281 3.17758,-0.31544 3.59707,0.042 0.34847,0.29692 0.34658,0.78069 0.34658,0.78069 v 6.04004 c 0,0 -0.004,0.63641 -0.53018,0.91857 -0.27049,0.14493 -2.94617,-0.0986 -3.22871,-0.2069 -0.61018,-0.23381 -0.5886,-0.90327 -0.5886,-0.90327 z m -8.68656,4.20791 v -4.20791 c 0,0 -0.0239,-0.60242 0.40383,-0.86252 0.36642,-0.22281 3.17759,-0.31544 3.59707,0.042 0.34847,0.29692 0.34658,0.78069 0.34658,0.78069 v 4.90473 c 0,0 -0.004,0.63641 -0.53017,0.91857 -0.2705,0.14492 -2.94617,-0.52168 -3.22871,-0.62994 -0.61019,-0.23382 -0.5886,-0.94557 -0.5886,-0.94557 z m 0.0383,3.38266 0.0424,3.80682 c 4.76147,1.58463 12.44208,1.37115 18.62715,0.76876 4.9084,-0.47805 9.46499,-3.13968 14.38678,-3.45098 2.56844,-0.16246 7.67481,0.84058 7.67481,0.84058 l 0.018,4.52569 c 0,0 4.30181,-3.85868 6.85434,-6.08209 0.23182,-0.21672 0.26026,-0.28202 -0.0588,-0.61036 -2.4793,-2.37833 -6.8878,-6.08125 -6.8878,-6.08125 l 0.0141,4.90206 c 0,0 -5.19129,-1.89571 -12.24908,-0.16859 -3.96245,1.32729 -6.76872,2.21825 -10.27188,2.769 -2.7191,0.42749 -5.4997,0.55723 -8.24775,0.4009 -3.33921,-0.18995 -6.69491,-0.50286 -9.90211,-1.62054 z m -15.25121,10.1713 c 0,0.39543 -0.18036,1.62226 1.45209,3.25472 1.40638,1.19302 2.9727,1.1712 3.41028,1.1712 23.19944,0.0992 44.97243,0.0226 68.7019,0 0.43758,0 2.0039,0.0218 3.41029,-1.1712 1.63245,-1.63246 1.45208,-2.85929 1.45208,-3.25472 0.12422,-16.06162 0.0264,-3.05893 0,-19.25937 0,-0.39543 0.18037,-1.62225 -1.45208,-3.25471 -1.40639,-1.19302 -2.97271,-1.1712 -3.41029,-1.1712 -23.19944,-0.0992 -44.97243,-0.0226 -68.7019,0 -0.43758,0 -2.0039,-0.0218 -3.41028,1.1712 -1.63245,1.63246 -1.45209,2.85928 -1.45209,3.25471 -0.11802,17.21566 -0.0338,3.97954 0,19.25937 z m 1.90997,-17.51991 c 0,-0.36657 -0.12323,-2.09175 1.14118,-3.35617 1.05214,-0.89259 3.06543,-0.74668 3.48144,-0.74668 22.55947,-0.021 43.30609,-0.0919 65.36168,0 1.3185,0 2.52269,-0.19776 3.66518,0.74727 1.05732,1.05732 0.95743,2.19932 0.95743,3.35558 0.0252,15.01782 0.11812,0.8913 0,15.78046 0,1.5229 -0.0428,2.46913 -0.90102,3.32738 -1.06456,0.88061 -2.31847,0.77547 -3.72159,0.77547 -22.55947,0.021 -43.30609,0.0919 -65.36168,0 -1.7721,0 -2.45712,0.11664 -3.44156,-0.68686 -1.36393,-1.36393 -1.18106,-1.95258 -1.18106,-3.41599 0.12429,-15.20955 -0.092,-2.68107 0,-15.78046 z m 4.56001,16.37025 v -16.61221 c 0,0 -0.0239,-0.60242 0.40383,-0.86252 0.36641,-0.22281 3.1776,-0.31544 3.59708,0.042 0.34846,0.29692 0.34658,0.78069 0.34658,0.78069 v 16.63216 c 0,0 -0.004,0.63642 -0.53019,0.91857 -0.27048,0.14493 -2.94617,0.1552 -3.2287,0.0469 -0.61019,-0.23381 -0.5886,-0.94556 -0.5886,-0.94556 z`,style:{display:`inline`,fill:`none`,"fill-opacity":`1`,"fill-rule":`evenodd`,stroke:`#000000`,"stroke-width":`0.75000012`,"stroke-linecap":`butt`,"stroke-linejoin":`miter`,"stroke-miterlimit":`4`,"stroke-dasharray":`none`,"stroke-opacity":`1`},ref_key:`radiator`,ref:radiator},null,512),createBaseVNode(`path`,{ref_key:`wheelaxleFL`,ref:wheelaxleFL,d:`m 91.691145,389.0121 c 0,0 -2.43068,0.29676 -2.43068,-4.28053 0,-4.0406 2.22866,-4.30576 2.22866,-4.30576 9.222155,-0.11908 21.694875,-0.0585 30.917405,-0.0594 3.70837,-9.1e-4 6.85841,-0.28274 8.24298,0.90893 0.51207,0.44072 0.75871,1.92799 1.01166,3.17533 0.35371,1.74427 0.74974,2.96105 0.32477,3.71154 -0.50969,0.90009 -2.57006,0.96141 -2.57006,0.96141 -11.49186,0.003 -26.23329,-0.0229 -37.724735,-0.11152 z`,style:{display:`inline`,opacity:`1`,fill:`none`,"fill-rule":`evenodd`,stroke:`#000000`,"stroke-width":`1px`,"stroke-linecap":`butt`,"stroke-linejoin":`miter`,"stroke-opacity":`1`}},null,512),createBaseVNode(`path`,{style:{display:`inline`,opacity:`1`,fill:`none`,"fill-rule":`evenodd`,stroke:`#000000`,"stroke-width":`1px`,"stroke-linecap":`butt`,"stroke-linejoin":`miter`,"stroke-opacity":`1`},d:`m 193.49174,389.0121 c 0,0 2.43068,0.29676 2.43068,-4.28053 0,-4.0406 -2.22865,-4.30576 -2.22865,-4.30576 -9.22216,-0.11908 -21.44488,-0.0585 -30.66742,-0.0594 -3.70837,-9.1e-4 -6.85841,-0.28274 -8.24298,0.90893 -0.51207,0.44072 -0.75871,1.92799 -1.01166,3.17533 -0.35371,1.74427 -0.74974,2.96105 -0.32477,3.71154 0.50969,0.90009 2.57006,0.96141 2.57006,0.96141 11.49186,0.003 25.98329,-0.0229 37.47474,-0.11152 z`,ref_key:`wheelaxleFR`,ref:wheelaxleFR},null,512),createBaseVNode(`path`,{ref_key:`brakeFR`,ref:brakeFR,d:`m 210.35279,373.43366 h -5.22322 l -0.0446,-11.25 c 0,0 -0.0446,-1.02679 -1.51786,-1.16071 -0.91518,-0.15626 -3.83928,-0.067 -3.83928,-0.067 0,0 -2.04238,-0.11866 -2.0759,1.22768 -0.0626,2.51339 -0.0446,47.43304 -0.0446,47.43304 0,0 -0.0431,1.36663 1.7634,1.40625 1.21935,0.0262 3.83928,0.005 3.83928,0.005 0,0 1.86958,0.12132 1.96428,-1.61256 0.073,-1.33729 -0.0207,-10.46221 -0.0207,-10.46221 l 5.24395,-0.12581 z`,style:{display:`inline`,opacity:`1`,fill:`none`,"fill-opacity":`1`,"fill-rule":`evenodd`,stroke:`#000000`,"stroke-width":`1px`,"stroke-linecap":`butt`,"stroke-linejoin":`miter`,"stroke-opacity":`1`}},null,512),createBaseVNode(`path`,{ref_key:`brakeFL`,ref:brakeFL,d:`m 74.826658,373.43366 h 5.22322 l 0.0446,-11.25 c 0,0 0.0446,-1.02679 1.51786,-1.16071 0.91518,-0.15626 3.83928,-0.067 3.83928,-0.067 0,0 2.04238,-0.11866 2.0759,1.22768 0.0626,2.51339 0.0446,47.43304 0.0446,47.43304 0,0 0.0431,1.36663 -1.7634,1.40625 -1.21935,0.0262 -3.83928,0.005 -3.83928,0.005 0,0 -1.86958,0.12132 -1.96428,-1.61256 -0.073,-1.33729 0.0207,-10.46221 0.0207,-10.46221 l -5.24395,-0.12581 z`,style:{display:`inline`,opacity:`1`,fill:`none`,"fill-opacity":`1`,"fill-rule":`evenodd`,stroke:`#000000`,"stroke-width":`1px`,"stroke-linecap":`butt`,"stroke-linejoin":`miter`,"stroke-opacity":`1`}},null,512),createBaseVNode(`path`,{style:{fill:`none`,"fill-rule":`evenodd`,stroke:`#000000`,"stroke-width":`1px`,"stroke-linecap":`butt`,"stroke-linejoin":`miter`,"stroke-opacity":`1`},d:`m 145.98404,268.73244 c 0,0 19.06962,-0.0115 31.7295,1.35397 11.84939,1.27802 23.33457,5.11217 35.69887,11.89174 11.96369,6.55991 22.2596,16.59274 27.50684,31.58729 3.06014,8.74465 3.9025,25.39725 3.9025,25.39725 l -9.60995,-0.14814 c 0,0 -1.63697,-16.52695 -5.20899,-24.93149 -3.97874,-9.3615 -11.63536,-19.52025 -21.21329,-24.53523 -10.62783,-5.56471 -18.68945,-8.01564 -32.75918,-10.2291 -11.61143,-1.82671 -30.13813,-1.14019 -30.13813,-1.14019 z`,ref_key:`bodyFR`,ref:bodyFR},null,512),createBaseVNode(`path`,{style:{fill:`none`,"fill-rule":`evenodd`,stroke:`#000000`,"stroke-width":`1.00000012`,"stroke-linecap":`butt`,"stroke-linejoin":`miter`,"stroke-miterlimit":`4`,"stroke-dasharray":`none`,"stroke-opacity":`1`},d:`m 139.36946,758.05809 c 0,0 -20.14699,0.01 -32.81319,-1.1024 -11.855294,-1.0405 -23.346203,-4.162 -35.716671,-9.6818 -11.969654,-5.3407 -20.679708,-11.5646 -25.929569,-23.7724 -3.061663,-7.1197 -5.495432,-24.34913 -5.495432,-24.34913 l 9.614735,0.12066 c 0,0 1.637794,15.18257 5.211595,22.02527 3.980722,7.6218 11.817934,15.0086 21.40064,19.0916 10.633134,4.5306 18.345219,5.9957 32.421962,7.798 11.61723,1.487 31.39781,0.9282 31.39781,0.9282 z`,ref_key:`bodyRL`,ref:bodyRL},null,512),createBaseVNode(`path`,{ref_key:`bodyRR`,ref:bodyRR,d:`m 145.99795,758.05809 c 0,0 19.59077,0.01 32.25697,-1.1024 11.8553,-1.0405 23.34621,-4.162 35.71668,-9.6818 11.96965,-5.3407 20.67971,-11.5646 25.92957,-23.7724 3.06166,-7.1197 5.49543,-24.34913 5.49543,-24.34913 l -9.61473,0.12066 c 0,0 -1.6378,15.18257 -5.2116,22.02527 -3.98072,7.6218 -11.81793,15.0086 -21.40064,19.0916 -10.63314,4.5306 -18.34522,5.9957 -32.42197,7.798 -11.61723,1.487 -30.84159,0.9282 -30.84159,0.9282 z`,style:{fill:`none`,"fill-rule":`evenodd`,stroke:`#000000`,"stroke-width":`1.00000012`,"stroke-linecap":`butt`,"stroke-linejoin":`miter`,"stroke-miterlimit":`4`,"stroke-dasharray":`none`,"stroke-opacity":`1`}},null,512),createBaseVNode(`path`,{style:{display:`inline`,opacity:`1`,fill:`none`,"fill-rule":`evenodd`,stroke:`#000000`,"stroke-width":`1.00000012`,"stroke-linecap":`butt`,"stroke-linejoin":`miter`,"stroke-miterlimit":`4`,"stroke-dasharray":`none`,"stroke-opacity":`1`},d:`m 75.326658,641.12409 h 5.22322 l 0.0446,-11.25 c 0,0 0.0446,-1.02679 1.51786,-1.16071 0.91518,-0.15626 3.83928,-0.067 3.83928,-0.067 0,0 2.04238,-0.11866 2.0759,1.22768 0.0626,2.51339 0.0446,47.43304 0.0446,47.43304 0,0 0.0431,1.36663 -1.7634,1.40625 -1.21935,0.0262 -3.83928,0.005 -3.83928,0.005 0,0 -1.86958,0.12132 -1.96428,-1.61256 -0.073,-1.33729 0.0207,-10.46221 0.0207,-10.46221 l -5.24395,-0.12581 z`,ref_key:`brakeRL`,ref:brakeRL},null,512),createBaseVNode(`path`,{ref_key:`brakeRR`,ref:brakeRR,d:`m 209.87792,642.37917 h -5.22322 l -0.0446,-11.25 c 0,0 -0.0446,-1.02679 -1.51786,-1.16071 -0.91518,-0.15626 -3.83928,-0.067 -3.83928,-0.067 0,0 -2.04238,-0.11866 -2.0759,1.22768 -0.0626,2.51339 -0.0446,47.43304 -0.0446,47.43304 0,0 -0.0431,1.36663 1.7634,1.40625 1.21935,0.0262 3.83928,0.005 3.83928,0.005 0,0 1.86958,0.12132 1.96428,-1.61256 0.073,-1.33729 -0.0207,-10.46221 -0.0207,-10.46221 l 5.24395,-0.12581 z`,style:{display:`inline`,opacity:`1`,fill:`none`,"fill-rule":`evenodd`,stroke:`#000000`,"stroke-width":`1.00000012`,"stroke-linecap":`butt`,"stroke-linejoin":`miter`,"stroke-miterlimit":`4`,"stroke-dasharray":`none`,"stroke-opacity":`1`}},null,512),createBaseVNode(`path`,{style:{display:`inline`,opacity:`1`,fill:`none`,"fill-rule":`evenodd`,stroke:`#000000`,"stroke-width":`1.00000012`,"stroke-linecap":`butt`,"stroke-linejoin":`miter`,"stroke-miterlimit":`4`,"stroke-dasharray":`none`,"stroke-opacity":`1`},d:`m 92.206308,649.46453 c 0,0 -2.43068,-0.29676 -2.43068,4.28053 0,4.0406 2.22866,4.30576 2.22866,4.30576 9.222162,0.11908 21.444882,0.0585 30.667412,0.0594 3.70837,9.1e-4 8.80295,0.28274 10.18752,-0.90893 0.51207,-0.44072 0.6941,-2.38196 0.90117,-3.66147 0.26289,-1.62435 0.42635,-2.41047 0.26953,-3.25855 -0.21138,-1.14316 -2.40433,-0.92826 -2.40433,-0.92826 -12.14004,-6.2e-4 -27.27967,0.0179 -39.419282,0.11152 z`,ref_key:`wheelaxleRL`,ref:wheelaxleRL},null,512),createBaseVNode(`path`,{ref_key:`wheelaxleRR`,ref:wheelaxleRR,d:`m 192.84519,649.46453 c 0,0 2.43068,-0.29676 2.43068,4.28053 0,4.0406 -2.22866,4.30576 -2.22866,4.30576 -9.22216,0.11908 -20.31988,0.0585 -29.54242,0.0594 -3.70837,9.1e-4 -8.80295,0.28274 -10.18752,-0.90893 -0.51207,-0.44072 -0.6941,-2.38196 -0.90117,-3.66147 -0.26289,-1.62435 -0.42635,-2.41047 -0.26953,-3.25855 0.21138,-1.14316 2.40433,-0.92826 2.40433,-0.92826 12.14004,-6.2e-4 26.15468,0.0179 38.29429,0.11152 z`,style:{display:`inline`,opacity:`1`,fill:`none`,"fill-rule":`evenodd`,stroke:`#000000`,"stroke-width":`1.00000012`,"stroke-linecap":`butt`,"stroke-linejoin":`miter`,"stroke-miterlimit":`4`,"stroke-dasharray":`none`,"stroke-opacity":`1`}},null,512),createBaseVNode(`g`,{style:{opacity:`0`},ref_key:`damageContainer`,ref:damageContainer},[createBaseVNode(`rect`,{style:{opacity:`0.77399998`,fill:`#3e3e3e`,"stroke-width":`1.99999893`,"stroke-miterlimit":`4`,"stroke-dasharray":`none`,"stroke-dashoffset":`0`},ref_key:`damageBox`,ref:damageBox,width:`206.75557`,height:`28.991379`,x:`39.481575`,y:`234.25491`},null,512),_cache[0]||=createBaseVNode(`path`,{style:{opacity:`1`,fill:`none`,stroke:`#ffffff`,"stroke-width":`1.99999893`,"stroke-linecap":`butt`,"stroke-linejoin":`miter`,"stroke-miterlimit":`4`,"stroke-dasharray":`none`,"stroke-opacity":`1`},d:`m 39.48159,263.2463 206.75556,-2e-5`},null,-1),createBaseVNode(`text`,_hoisted_2$153,[createBaseVNode(`tspan`,{ref_key:`damageText`,ref:damageText,style:{"text-align":`center`,"text-anchor":`middle`,fill:`#ffffff`},y:`255.49614`,x:`142.73175`},` Driveshaft Broken `,512)])],512)])],4))}},app_default$9=__plugin_vue_export_helper_default(_sfc_main$210,[[`__scopeId`,`data-v-f6aa177d`]]),_hoisted_1$187={class:`timeslip`,id:`slip`},_hoisted_2$152={class:`paper`},_hoisted_3$136={class:`header`},_hoisted_4$113={class:`table-wrapper`},_hoisted_5$98={class:`custom-table`},_hoisted_6$81={class:`left-align`},_hoisted_7$69={class:`right-align`},_hoisted_8$56={class:`right-align`},_hoisted_9$50={key:0},_hoisted_10$43={class:`right-align`},_hoisted_11$38={class:`right-align`},_hoisted_12$28={class:`header`},_hoisted_13$25={class:`left`},_hoisted_14$24={class:`right`},_hoisted_15$23={class:`name`},_hoisted_16$23={key:0,class:`rewards`},_hoisted_17$18={class:`reward`},_hoisted_18$16={class:`header`},_hoisted_19$13={key:0},_sfc_main$209={__name:`Timeslip`,props:{slip:Object},setup(__props){let{units}=useBridge(),props=__props,TIMER_ROWS_INFO=[{key:`laneName`,label:`Lane`},{key:null,label:``},{key:`dial`,label:`DIAL`},{key:`reactionTime`,label:`R/T`},{key:`time_60`,label:`60'`},{key:`time_330`,label:`330'`},{key:`time_1_8`,label:`1/8`},{key:`velAt_1_8_kmh`,label:`KM/H`},{key:`velAt_1_8_mph`,label:`MPH`},{key:`time_1000`,label:`1000'`},{key:`time_1_4`,label:`1/4`},{key:`velAt_1_4_kmh`,label:`KM/H`},{key:`velAt_1_4_mph`,label:`MPH`},{key:`dialDiff`,label:`DIFF`}],getRacerByLane=laneNum=>props.slip.racerInfos.find(racer=>racer.laneNum===laneNum),getTimerValue=(laneNum,timerKey)=>{let racer=getRacerByLane(laneNum);if(!racer)return`-`;if(timerKey===null)return``;if(timerKey===`laneName`)return racer.lane||`-`;if(timerKey===`dial`){if(props.slip.dragType!==`bracketRace`)return`-`;let racer$1=getRacerByLane(laneNum);if(!racer$1)return`-`;let value=racer$1.timers.dial;if(value==null)return`-`;let num=parseFloat(value);return isNaN(num)?`-`:num.toFixed(3)}if(timerKey===`dialDiff`){if(props.slip.dragType!==`bracketRace`)return`-`;let racer$1=getRacerByLane(laneNum);if(!racer$1)return`-`;let value=racer$1.dialDiff;return value==null?`-`:formatDialDiff(value)}if(timerKey.includes(`velAt_`)){if(timerKey.includes(`_kmh`)){let baseKey=timerKey.replace(`_kmh`,``);return racer.velocities[baseKey+`_km/h`]||`-`}else if(timerKey.includes(`_mph`)){let baseKey=timerKey.replace(`_mph`,``);return racer.velocities[baseKey+`_mph`]||`-`}}return racer.timers[timerKey]||`-`},formatDialDiff=value=>{if(value===`-`)return`-`;let num=parseFloat(value);return isNaN(num)?`-`:(num>0?`+`:``)+num.toFixed(3)},getWinnerResult=laneNum=>{let racer=getRacerByLane(laneNum);if(!racer)return`-`;if(racer.disqualification)return`DQ`;if(props.slip.racerInfos.length===1)return`-`;let otherRacer=getRacerByLane(laneNum===1?2:1);if(!otherRacer)return`-`;if(otherRacer.disqualification)return`WINNER`;if(props.slip.dragType===`bracketRace`){let thisDiff=parseFloat(racer.dialDiff),otherDiff=parseFloat(otherRacer.dialDiff);return thisDiff===otherDiff?`TIE`:thisDiff>0&&otherDiff>0?thisDiffotherDiff?`WINNER`:`Break Out`}else{let thisTime=parseFloat(racer.finalTime),otherTime=parseFloat(otherRacer.finalTime);return thisTime>otherTime?`+${(thisTime-otherTime).toFixed(3)}`:`WINNER`}};return(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$187,[_cache[3]||=createBaseVNode(`div`,{class:`rip reverse top`},null,-1),createBaseVNode(`div`,_hoisted_2$152,[createBaseVNode(`div`,_hoisted_3$136,[(openBlock(!0),createElementBlock(Fragment,null,renderList(__props.slip.stripInfo,info=>(openBlock(),createElementBlock(`div`,{key:info},toDisplayString(_ctx.$tt(info)),1))),128))]),createBaseVNode(`div`,_hoisted_4$113,[createBaseVNode(`table`,_hoisted_5$98,[createBaseVNode(`tbody`,null,[(openBlock(),createElementBlock(Fragment,null,renderList(TIMER_ROWS_INFO,(rowInfo,rowIndex)=>createBaseVNode(`tr`,{key:`timer-`+rowIndex,class:normalizeClass({"quarter-mile-row":rowInfo.key===`time_1_4`})},[createBaseVNode(`td`,_hoisted_6$81,toDisplayString(rowInfo.label),1),createBaseVNode(`td`,_hoisted_7$69,toDisplayString(getTimerValue(2,rowInfo.key)),1),createBaseVNode(`td`,_hoisted_8$56,toDisplayString(getTimerValue(1,rowInfo.key)),1)],2)),64)),__props.slip.racerInfos.length>1?(openBlock(),createElementBlock(`tr`,_hoisted_9$50,[_cache[0]||=createBaseVNode(`td`,{class:`left-align`},null,-1),createBaseVNode(`td`,_hoisted_10$43,toDisplayString(getWinnerResult(2)),1),createBaseVNode(`td`,_hoisted_11$38,toDisplayString(getWinnerResult(1)),1)])):createCommentVNode(``,!0)])])]),(openBlock(!0),createElementBlock(Fragment,null,renderList(__props.slip.racerInfos,racer=>(openBlock(),createElementBlock(`div`,{key:racer.name,class:`racer`},[createBaseVNode(`div`,_hoisted_12$28,[createBaseVNode(`div`,_hoisted_13$25,toDisplayString(racer.lane),1),createBaseVNode(`div`,_hoisted_14$24,toDisplayString(racer.licenseText),1)]),createBaseVNode(`div`,_hoisted_15$23,toDisplayString(racer.name),1),Object.keys(racer.rewards).length===0?createCommentVNode(``,!0):(openBlock(),createElementBlock(`div`,_hoisted_16$23,[_cache[1]||=createTextVNode(` Rewards... `,-1),(openBlock(!0),createElementBlock(Fragment,null,renderList(racer.rewards,reward=>(openBlock(),createElementBlock(`div`,_hoisted_17$18,[createTextVNode(toDisplayString(reward)+` BMRA-XP `,1),createVNode(unref(bngIcon_default),{class:`reward-icon`,type:unref(icons).wheelOutline,color:`black`},null,8,[`type`])]))),256)),_cache[2]||=createBaseVNode(`template`,null,[createTextVNode(` ... `)],-1)]))]))),128)),createBaseVNode(`div`,_hoisted_18$16,[createBaseVNode(`div`,null,toDisplayString(unref(units).buildString(`temperature`,__props.slip.env.tempC,1,`c`))+` / `+toDisplayString(unref(units).buildString(`temperature`,__props.slip.env.tempC,1,`f`)),1),__props.slip.env.customGrav?(openBlock(),createElementBlock(`div`,_hoisted_19$13,toDisplayString(_ctx.$tt(`ui.environment.gravity`))+`: `+toDisplayString(__props.slip.env.gravity),1)):createCommentVNode(``,!0)])]),_cache[4]||=createBaseVNode(`div`,{class:`rip bottom`},null,-1)]))}},Timeslip_default=__plugin_vue_export_helper_default(_sfc_main$209,[[`__scopeId`,`data-v-4b627404`]]),_hoisted_1$186={key:0,class:`bng-app`,id:`container`},_hoisted_2$151={class:`slide`},_sfc_main$208={__name:`app`,setup(__props){let{$game}=useLibStore(),slip=ref({});onMounted(()=>{$game.events.on(`onDragRaceTimeslipData`,onDragRaceTimeslipData)}),onUnmounted(()=>{$game.events.off(`onDragRaceTimeslipData`,onDragRaceTimeslipData)});function onDragRaceTimeslipData(rawData){slip.value=rawData,rawData&&(console.log(rawData),Lua_default.Engine.Audio.playOnce(`AudioGui`,`event:>UI>Missions>Timeslip`))}let screenshot=function(){Lua_default.gameplay_drag_dragBridge.screenshotTimeslip()},clear=function(){slip.value=null};return(_ctx,_cache)=>slip.value&&slip.value.stripInfo?(openBlock(),createElementBlock(`div`,_hoisted_1$186,[createBaseVNode(`div`,_hoisted_2$151,[createVNode(Timeslip_default,{slip:slip.value,save:``,clear:``},null,8,[`slip`]),createVNode(unref(bngIcon_default),{class:`clear`,type:unref(icons).trashBin1,onClick:clear},null,8,[`type`]),createVNode(unref(bngIcon_default),{class:`save`,type:unref(icons).floppyDisk,onClick:screenshot},null,8,[`type`])])])):createCommentVNode(``,!0)}},app_default$10=__plugin_vue_export_helper_default(_sfc_main$208,[[`__scopeId`,`data-v-84d60911`]]),_hoisted_1$185={key:0},_hoisted_2$150={class:`lights-container`},_hoisted_3$135={class:`circles-wrapper`},_hoisted_4$112={class:`stage-circle`},_hoisted_5$97={class:`stage-top`},_hoisted_6$80={class:`stage-middle`},_hoisted_7$68={class:`stage-bottom`},_hoisted_8$55={class:`circles-wrapper`},_hoisted_9$49={class:`circles-wrapper`},_hoisted_10$42={class:`circles-wrapper`},_hoisted_11$37={class:`circles-wrapper`},_sfc_main$207={__name:`Treelights`,setup(__props){let events$3=useEvents(),isStaging=ref(!1),stageLights=ref([{stageLights:{prestageLight:!1,stageLight:!1},countDownLights:{amberLight1:!1,amberLight2:!1,amberLight3:!1,greenLight:!1,redLight:!1},globalLights:{blueLight:!1}}]),updateLights=changes=>{changes.stageLights&&(stageLights.value[0].stageLights={...stageLights.value[0].stageLights,...changes.stageLights}),changes.countDownLights&&(stageLights.value[0].countDownLights={...stageLights.value[0].countDownLights,...changes.countDownLights},(changes.countDownLights.greenLight||changes.countDownLights.redLight)&&setTimeout(()=>{isStaging.value=!1},2e3))},updateStaging=isNearby=>{isStaging.value=isNearby};return onMounted(()=>{events$3.on(`updateTreeLightApp`,updateLights),events$3.on(`updateTreeLightStaging`,updateStaging)}),onUnmounted(()=>{events$3.off(`updateTreeLightApp`,updateLights),events$3.off(`updateTreeLightStaging`,updateStaging)}),(_ctx,_cache)=>isStaging.value.valueOf==0?createCommentVNode(``,!0):(openBlock(),createElementBlock(`div`,_hoisted_1$185,[createBaseVNode(`div`,_hoisted_2$150,[createBaseVNode(`div`,_hoisted_3$135,[createBaseVNode(`div`,{class:normalizeClass([`light-circle black`,{blue:stageLights.value[0].globalLights.blueLight,red:stageLights.value[0].countDownLights.redLight}])},[withDirectives(createBaseVNode(`div`,_hoisted_4$112,[withDirectives(createBaseVNode(`div`,_hoisted_5$97,[..._cache[0]||=[createStaticVNode(``,1)]],512),[[vShow,stageLights.value[0].stageLights.prestageLight]]),withDirectives(createBaseVNode(`div`,_hoisted_6$80,[..._cache[1]||=[createStaticVNode(``,1)]],512),[[vShow,stageLights.value[0].stageLights.prestageLight&&stageLights.value[0].stageLights.stageLight]]),withDirectives(createBaseVNode(`div`,_hoisted_7$68,[..._cache[2]||=[createStaticVNode(``,1)]],512),[[vShow,stageLights.value[0].stageLights.stageLight]])],512),[[vShow,!stageLights.value[0].countDownLights.redLight]])],2)]),createBaseVNode(`div`,_hoisted_8$55,[createBaseVNode(`div`,{class:normalizeClass([`light-circle black`,{amber:stageLights.value[0].countDownLights.amberLight1,red:stageLights.value[0].countDownLights.redLight}])},null,2)]),createBaseVNode(`div`,_hoisted_9$49,[createBaseVNode(`div`,{class:normalizeClass([`light-circle black`,{amber:stageLights.value[0].countDownLights.amberLight2,red:stageLights.value[0].countDownLights.redLight}])},null,2)]),createBaseVNode(`div`,_hoisted_10$42,[createBaseVNode(`div`,{class:normalizeClass([`light-circle black`,{amber:stageLights.value[0].countDownLights.amberLight3,red:stageLights.value[0].countDownLights.redLight}])},null,2)]),createBaseVNode(`div`,_hoisted_11$37,[createBaseVNode(`div`,{class:normalizeClass([`light-circle black go`,{green:stageLights.value[0].countDownLights.greenLight,red:stageLights.value[0].countDownLights.redLight}])},null,2)])])]))}},Treelights_default=__plugin_vue_export_helper_default(_sfc_main$207,[[`__scopeId`,`data-v-c2ff1007`]]),_sfc_main$206={__name:`bngModifierTiles`,props:{modifierActionInfos:{type:Object,required:!0}},setup(__props){let{isControllerUsed}=storeToRefs(controls_default()),props=__props,controllerActions=computed(()=>{let mod1Active=props.modifierActionInfos.customModifier1?.active,mod2Active=props.modifierActionInfos.customModifier2?.active,mod1Disabled=props.modifierActionInfos.customModifier1?.disabled,mod2Disabled=props.modifierActionInfos.customModifier2?.disabled,mod1modifier2Disabled=props.modifierActionInfos.modifier1modifier2?.disabled;return[{actions:[{actionName:`customModifier2`}],active:!mod2Disabled&&mod2Active&&!mod1Active,disabled:mod2Disabled},{actions:[{actionName:`customModifier2`},{actionName:`customModifier1`}],active:!mod1modifier2Disabled&&mod1Active&&mod2Active,disabled:mod1modifier2Disabled},{actions:[{actionName:`customModifier1`}],active:!mod1Disabled&&mod1Active&&!mod2Active,disabled:mod1Disabled}]}),kbmActions=computed(()=>{props.modifierActionInfos.shift?.active;let ctrlActive=props.modifierActionInfos.ctrl?.active!==void 0,altActive=props.modifierActionInfos.alt?.active!==void 0;return[{active:ctrlActive,actions:[{actionName:`kbmModifier1`,device:`keyboard0`,deviceKey:`ctrl`}]},{active:altActive,actions:[{actionName:`kbmModifier3`,device:`keyboard0`,deviceKey:`alt`}]}]}),entries=computed(()=>isControllerUsed.value?controllerActions.value:kbmActions.value),getModifierClass=entry=>{let cls=`modifier-tile`;return entry.active&&(cls+=` active`),entry.disabled&&(cls+=` disabled`),cls};return(_ctx,_cache)=>(openBlock(!0),createElementBlock(Fragment,null,renderList(entries.value,entry=>(openBlock(),createElementBlock(`div`,{class:normalizeClass(getModifierClass(entry))},[(openBlock(!0),createElementBlock(Fragment,null,renderList(entry.actions,(action,actionIdx)=>(openBlock(),createElementBlock(`div`,{key:actionIdx},[actionIdx>0?(openBlock(),createBlock(unref(bngIcon_default),{key:0,type:`mathPlus`})):createCommentVNode(``,!0),createVNode(unref(bngBinding_default),{action:action.actionName,device:action.device,"device-key":action.deviceKey,"show-unassigned":!1},null,8,[`action`,`device`,`device-key`])]))),128))],2))),256))}},bngModifierTiles_default=__plugin_vue_export_helper_default(_sfc_main$206,[[`__scopeId`,`data-v-ea01b9d8`]]),_hoisted_1$184={key:0,class:`bng-app-binding-display`},_hoisted_2$149={key:0,class:`modifier-bindings`},_hoisted_3$134={class:`label-column`},_hoisted_4$111={key:0,class:`label-text`},_hoisted_5$96={class:`binding-column`},_hoisted_6$79={class:`flexible-area`},_hoisted_7$67={class:`label-column`},_hoisted_8$54={key:0,class:`label-text`},_hoisted_9$48={class:`binding-column`},_hoisted_10$41={key:0,class:`tile-flex`},_hoisted_11$36={key:1,class:`bottom-left-group`},_sfc_main$205={__name:`bngAppBindingDisplay`,setup(__props){let events$3=useEvents(),actions=shallowRef([]),tileActions=shallowRef([]),constantActions=shallowRef([]),modifierActionInfos=shallowRef([]),additionalData=shallowRef({}),isFaded=ref(!1),isHovered=ref(!1),mouseDownAction=ref(``),actionOpacity=ref(1),fadeOutTimeout=null,isFadingOut=ref(!1),showApp=ref(!0),tileRefs=ref([]),isWide=ref([]),narrowSpan=ref(4),setActions=data=>{let newActions=Array.isArray(data.actions)?data.actions:[];showApp.value=data.showApp,constantActions.value=Array.isArray(data.constantActions)?data.constantActions:[],modifierActionInfos.value=data.modifierActionInfos?{...data.modifierActionInfos}:{},additionalData.value=data.additionalData?{...data.additionalData}:{},fadeOutTimeout&&(clearTimeout(fadeOutTimeout),fadeOutTimeout=null,isFadingOut.value=!1),actions.value.length>0&&newActions.length===0?(isFadingOut.value=!0,actionOpacity.value=0,fadeOutTimeout=setTimeout(()=>{actions.value=newActions,actionOpacity.value=1,isFadingOut.value=!1,fadeOutTimeout=null},0)):newActions.length>0&&actions.value.length===0?(actions.value=newActions,actionOpacity.value=0,nextTick(()=>{actionOpacity.value=1})):(actions.value=newActions,actionOpacity.value=1),tileActions.value=actions.value.filter(action=>action.icon),actions.value=actions.value.filter(action=>!action.icon)},getActionClass=(action,isConstant)=>{let cls=`binding-row`;return isConstant?cls+=` is-constant`:isFadingOut.value&&(cls+=` is-fading-out`),!action.onClick&&!action.inputActionOnClick&&(cls+=` no-hover`),action.highlighted&&(cls+=` highlighted`),cls},onActionClickDown=action=>{action.onClick?runRaw(action.onClick):action.inputActionOnClick&&(mouseDownAction.value=action.action,Lua_default.ui_bindingsLegend.triggerInputAction(action.action,1))},onMouseEnter=()=>{isHovered.value=!0},onMouseLeave=()=>{isHovered.value=!1},onGlobalMouseUp=event=>{mouseDownAction.value&&=(Lua_default.ui_bindingsLegend.triggerInputAction(mouseDownAction.value,0),``)};onMounted(()=>{events$3.on(`setActionsForLegend`,setActions),events$3.on(`setBindingsLegendFade`,value=>{isFaded.value=!!value}),Lua_default.ui_bindingsLegend.sendDataToUI(!0),listenFilteredInputEvents(!0),document.addEventListener(`mouseup`,onGlobalMouseUp)}),onBeforeUnmount(()=>{document.removeEventListener(`mouseup`,onGlobalMouseUp),fadeOutTimeout&&=(clearTimeout(fadeOutTimeout),null),actionOpacity.value=1,listenFilteredInputEvents(!1)});function listenFilteredInputEvents(listen){events$3[listen?`on`:`off`](`FilteredInputChanged`,onFilteredInputChanged),Lua_default.WinInput.setForwardFilteredEvents(listen)}function onFilteredInputChanged(data){let updated$2=!1;for(let action of tileActions.value)action.action===data.bindingAction&&(action.value=data.value,updated$2=!0);updated$2&&triggerRef(tileActions)}function setTileRef(i,compOrEl){tileRefs.value[i]=compOrEl&&compOrEl.$el?compOrEl.$el:compOrEl}function classifyTiles(){isWide.value=tileRefs.value.map(el=>!!el?.querySelector?.(`.combo-binding`))}function pickNarrowSpanByCount(n){let options=[{cols:4,span:3},{cols:3,span:4},{cols:2,span:6}],best=options[0],bestR=n%best.cols;for(let opt of options){let r=n%opt.cols;r{await nextTick(),tileRefs.value.length=tileActions.value.length,classifyTiles(),recomputeLayout()}),onMounted(async()=>{await nextTick(),classifyTiles(),recomputeLayout()}),(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,{class:normalizeClass([`bng-app-binding-display-wrapper`,{"is-faded":isFaded.value&&!isHovered.value}]),onMouseenter:onMouseEnter,onMouseleave:onMouseLeave},[showApp.value?(openBlock(),createElementBlock(`div`,_hoisted_1$184,[modifierActionInfos.value&&additionalData.value.vehicleSpecificStatus!==`enabled`?(openBlock(),createElementBlock(`div`,_hoisted_2$149,[createVNode(bngModifierTiles_default,{"modifier-action-infos":modifierActionInfos.value},null,8,[`modifier-action-infos`])])):createCommentVNode(``,!0),(openBlock(!0),createElementBlock(Fragment,null,renderList(constantActions.value,action=>(openBlock(),createBlock(unref(bngButton_default),{accent:unref(ACCENTS).custom,onMousedown:$event=>onActionClickDown(action),tabindex:`-1`,class:normalizeClass(getActionClass(action,!0))},{default:withCtx(()=>[createBaseVNode(`div`,_hoisted_3$134,[action.label?(openBlock(),createElementBlock(`span`,_hoisted_4$111,toDisplayString(_ctx.$t(action.label)),1)):createCommentVNode(``,!0)]),createBaseVNode(`div`,_hoisted_5$96,[action.bindings?(openBlock(!0),createElementBlock(Fragment,{key:0},renderList(action.bindings,binding=>(openBlock(),createBlock(unref(bngBinding_default),{key:binding.device+`:`+binding.control,action:action.action,device:binding.device,"device-key":binding.control,"show-unassigned":``,"action-variants":``},null,8,[`action`,`device`,`device-key`]))),128)):(openBlock(),createBlock(unref(bngBinding_default),{key:1,action:action.action,"show-unassigned":``,"action-variants":``},null,8,[`action`]))])]),_:2},1032,[`accent`,`onMousedown`,`class`]))),256)),createBaseVNode(`div`,_hoisted_6$79,[(openBlock(!0),createElementBlock(Fragment,null,renderList(actions.value,(action,index)=>(openBlock(),createBlock(unref(bngButton_default),{key:action.action||action.label,accent:unref(ACCENTS).custom,onMousedown:$event=>onActionClickDown(action),tabindex:`-1`,ref_for:!0,ref:index===0?`actionButton`:void 0,class:normalizeClass(getActionClass(action,!1))},{default:withCtx(()=>[createBaseVNode(`div`,_hoisted_7$67,[action.label?(openBlock(),createElementBlock(`span`,_hoisted_8$54,toDisplayString(_ctx.$t(action.label)),1)):createCommentVNode(``,!0)]),createBaseVNode(`div`,_hoisted_9$48,[action.bindings?(openBlock(!0),createElementBlock(Fragment,{key:0},renderList(action.bindings,binding=>(openBlock(),createBlock(unref(bngBinding_default),{key:binding.device+`:`+binding.control,action:action.action,device:binding.device,"device-key":binding.control,"show-unassigned":``,"action-variants":``},null,8,[`action`,`device`,`device-key`]))),128)):(openBlock(),createBlock(unref(bngBinding_default),{key:1,action:action.action,"show-unassigned":``,"action-variants":``},null,8,[`action`]))])]),_:2},1032,[`accent`,`onMousedown`,`class`]))),128)),tileActions.value.length>0?(openBlock(),createElementBlock(`div`,_hoisted_10$41,[(openBlock(!0),createElementBlock(Fragment,null,renderList(tileActions.value,(action,i)=>(openBlock(),createBlock(unref(bngBindingTileButton_default),{class:normalizeClass([`tile-grid-item`,{highlighted:action.highlighted}]),action,icon:action.icon,label:_ctx.$t(action.label),layout:action.direction,showValueBar:action.direction!==void 0,isBidirectional:action.isCentered,value:action.value,style:{"--tile-span":4},ref_for:!0,ref:el=>setTileRef(i,el),"show-unassigned":``,"action-variants":``,"bng-no-nav":``,tabindex:`-1`},{default:withCtx(()=>[action.bindings?(openBlock(!0),createElementBlock(Fragment,{key:0},renderList(action.bindings,binding=>(openBlock(),createBlock(unref(bngBinding_default),{key:binding.device+`:`+binding.control,action:action.action,device:binding.device,"device-key":binding.control,"show-unassigned":``,"action-variants":``},null,8,[`action`,`device`,`device-key`]))),128)):(openBlock(),createBlock(unref(bngBinding_default),{key:1,action:action.action,"show-unassigned":``,"action-variants":``},null,8,[`action`]))]),_:2},1032,[`class`,`action`,`icon`,`label`,`layout`,`showValueBar`,`isBidirectional`,`value`]))),256))])):createCommentVNode(``,!0)])])):createCommentVNode(``,!0),showApp.value?(openBlock(),createElementBlock(`div`,_hoisted_11$36,[withDirectives((openBlock(),createBlock(unref(bngButton_default),{class:`bottom-left-button`,disabled:additionalData.value.vehicleSpecificStatus===`inactive`,accent:additionalData.value.vehicleSpecificStatus===`enabled`||additionalData.value.vehicleSpecificStatus===`fleeting`?unref(ACCENTS).main:unref(ACCENTS).text,onClick:_cache[0]||=$event=>unref(Lua_default).ui_bindingsLegend.toggleShowVehicleSpecificActions(),"bng-no-nav":``,tabindex:`-1`},{default:withCtx(()=>[createVNode(unref(bngIcon_default),{type:unref(icons).car},null,8,[`type`]),additionalData.value.vehicleSpecificStatus===`enabled`?(openBlock(),createBlock(unref(bngIcon_default),{key:0,class:`bottom-left-lock`,type:unref(icons).lockClosed},null,8,[`type`])):createCommentVNode(``,!0)]),_:1},8,[`disabled`,`accent`])),[[unref(BngTooltip_default),`Press to show/hide vehicle specific actions`,`right`]])])):createCommentVNode(``,!0),createVNode(unref(bngButton_default),{class:`bottom-left-button`,accent:unref(ACCENTS).text,icon:unref(icons).eyeSolidOpened,onClick:_cache[1]||=$event=>unref(Lua_default).ui_bindingsLegend.toggleShowApp(),"bng-no-nav":``,tabindex:`-1`},null,8,[`accent`,`icon`])],34))}},bngAppBindingDisplay_default=__plugin_vue_export_helper_default(_sfc_main$205,[[`__scopeId`,`data-v-cf4052e5`]]),_hoisted_1$183={class:`action`},_hoisted_2$148={key:0,class:`indicators`},_hoisted_3$133={class:`icon-wrapper`},_hoisted_4$110={key:2,class:`tile-fallback-label`},_hoisted_5$95={key:0,class:`value-bar`},_hoisted_6$78={class:`bindings-wrapper`},_sfc_main$204={__name:`bngBindingTileButton`,props:{label:String,icon:[Object,String],showIndicators:{type:Boolean,default:!1},layout:{type:String,default:`horizontal`,validator:v=>[`horizontal`,`vertical`].includes(v)},dark:Boolean,disabled:Boolean,action:{type:Object,required:!0},bindings:{type:Array,default:()=>void 0},actionVariants:Boolean,showValueBar:{type:Boolean,default:!0},value:{type:Number,default:0},targetValue:{type:Number,default:0},isBidirectional:{type:Boolean,default:!1}},emits:[`click`],setup(__props,{expose:__expose}){let props=__props,layoutClass=computed(()=>props.layout===`vertical`?`layout-vertical`:`layout-horizontal`);__expose({icons});let isLikelyImagePath=val=>typeof val==`string`&&(val.includes(`/`)||val.startsWith(`.`)||val.includes(`\\`)),candidateIcon=computed(()=>props.icon??null),useGlyphIcon=computed(()=>{let c=candidateIcon.value;return c?typeof c==`object`?!!c.glyph:typeof c==`string`?!isLikelyImagePath(c)&&c in icons:!1:!1}),resolvedGlyphType=computed(()=>useGlyphIcon.value?candidateIcon.value:null),resolvedImagePath=computed(()=>{let c=candidateIcon.value;return typeof c==`string`&&isLikelyImagePath(c)?c:null});return(_ctx,_cache)=>(openBlock(),createBlock(unref(bngButton_default),{class:`bng-binding-tile-button`,accent:unref(ACCENTS).custom,disabled:__props.disabled,onClick:_cache[0]||=$event=>_ctx.$emit(`click`)},{default:withCtx(()=>[createBaseVNode(`div`,{class:normalizeClass([`content`,layoutClass.value])},[createBaseVNode(`div`,_hoisted_1$183,[__props.showIndicators?(openBlock(),createElementBlock(`div`,_hoisted_2$148,[(openBlock(),createElementBlock(Fragment,null,renderList(5,i=>createBaseVNode(`div`,{class:normalizeClass([`indicator`,{active:i===2}]),key:i},null,2)),64))])):createCommentVNode(``,!0),createBaseVNode(`div`,_hoisted_3$133,[useGlyphIcon.value?(openBlock(),createBlock(unref(bngIcon_default),{key:0,class:`icon-glyph`,type:resolvedGlyphType.value},null,8,[`type`])):resolvedImagePath.value?(openBlock(),createBlock(unref(bngImageAsset_default),{key:1,externalSrc:resolvedImagePath.value,class:`icon-img`,mask:``},null,8,[`externalSrc`])):__props.label?(openBlock(),createElementBlock(`div`,_hoisted_4$110,toDisplayString(__props.label),1)):createCommentVNode(``,!0)])]),__props.showValueBar?(openBlock(),createElementBlock(`div`,_hoisted_5$95,[createVNode(unref(bngInputBar_default),{value:__props.value,"target-value":__props.targetValue,"is-bidirectional":__props.isBidirectional,vertical:__props.layout==`vertical`},null,8,[`value`,`target-value`,`is-bidirectional`,`vertical`])])):createCommentVNode(``,!0),createBaseVNode(`div`,_hoisted_6$78,[renderSlot(_ctx.$slots,`binding`,{},()=>[__props.action&&__props.action.bindings?(openBlock(!0),createElementBlock(Fragment,{key:0},renderList(__props.action.bindings,binding=>(openBlock(),createBlock(unref(bngBinding_default),{key:binding.device+`:`+binding.control,action:__props.action.action,device:binding.device,"device-key":binding.control,dark:__props.dark,"show-unassigned":``,"action-variants":__props.actionVariants,vertical:__props.layout===`vertical`},null,8,[`action`,`device`,`device-key`,`dark`,`action-variants`,`vertical`]))),128)):(openBlock(),createBlock(unref(bngBinding_default),{key:1,vertical:__props.layout===`vertical`,action:__props.action&&__props.action.action,dark:__props.dark,"show-unassigned":``,"action-variants":__props.actionVariants},null,8,[`vertical`,`action`,`dark`,`action-variants`]))],!0)])],2)]),_:3},8,[`accent`,`disabled`]))}},bngBindingTileButton_default=__plugin_vue_export_helper_default(_sfc_main$204,[[`__scopeId`,`data-v-db243a30`]]),_hoisted_1$182={class:`message-container`},_sfc_main$203={__name:`bngFlashMessage`,props:{messageSource:{type:String,default:`ScenarioFlashMessage`}},setup(__props){let props=__props,events$3=useEvents(),{api:api$1}=useBridge(),txt=ref(``),messageQueue=ref([]),stepTimeout=ref(null),animationClass=ref(``),fontSizeClass=ref(`font-small`),paused=ref(!1);onMounted(()=>{events$3.on(props.messageSource,data=>{if(Array.isArray(data))data.forEach(item=>{let messageObject={msg:item[0],ttl:item[1],luaCall:item[2]&&typeof item[2]==`string`?item[2]:void 0,jsCallback:item[2]&&typeof item[2]==`function`?item[2]:void 0,big:item[3]===void 0?!1:item[3]};messageQueue.value.push(messageObject)}),messageQueue.value.length>0&&!stepTimeout.value&&playMessagesAnimation();else if(typeof data==`object`){let messageObject={msg:data.msg,ttl:data.ttl,luaCall:data.luaCall||void 0,jsCallback:data.jsCallback||void 0,big:data.big===void 0?!1:data.big};messageQueue.value.push(messageObject),stepTimeout.value||playMessagesAnimation()}else console.warn(`Unexpected data format received for FlashMessage`)}),events$3.on(`physicsStateChanged`,state=>{paused.value=!state,paused.value?stepTimeout.value&&=(clearTimeout(stepTimeout.value),null):state&&playMessagesAnimation()})}),onUnmounted(()=>{stepTimeout.value&&=(clearTimeout(stepTimeout.value),null)});function playMessagesAnimation(){if(messageQueue.value.length===0){resetCountdown();return}animationClass.value=`fade-in`,setTimeout(()=>{animationClass.value=``},200);let msg=messageQueue.value[0];txt.value=msg.msg,fontSizeClass.value=msg.big?`font-large`:`font-small`,msg.luaCall&&typeof msg.luaCall==`string`&&api$1.engineLua(msg.luaCall),msg.jsCallback&&typeof msg.jsCallback==`function`&&msg.jsCallback(),messageQueue.value.shift(),setTimeout(()=>{animationClass.value=`fade-out`},msg.ttl*1e3-200),stepTimeout.value=setTimeout(()=>{playMessagesAnimation()},msg.ttl*1e3)}function resetCountdown(){stepTimeout.value&&clearTimeout(stepTimeout.value),messageQueue.value=[],txt.value=``,stepTimeout.value=null}return(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$182,[createBaseVNode(`div`,{class:normalizeClass([`message`,[`message`,animationClass.value,fontSizeClass.value]])},toDisplayString(txt.value),3)]))}},bngFlashMessage_default=__plugin_vue_export_helper_default(_sfc_main$203,[[`__scopeId`,`data-v-02941c3f`]]),_hoisted_1$181={class:`track`},_sfc_main$202={__name:`bngInputBar`,props:{value:{type:Number,default:0},targetValue:{type:Number,default:0},isBidirectional:{type:Boolean,default:!1},vertical:{type:Boolean,default:!1}},setup(__props){let props=__props,isVertical=computed(()=>props.vertical),clamp$2=(v,min$1,max$1)=>Math.min(max$1,Math.max(min$1,v)),toUnits=(v,bidir)=>{let vv=clamp$2(v,bidir?-1:0,1);return bidir?(vv+1)/2:vv},zeroUnits=computed(()=>props.isBidirectional?.5:0),actualUnits=computed(()=>toUnits(props.value,props.isBidirectional)),targetUnits=computed(()=>toUnits(props.targetValue,props.isBidirectional)),makeFillStyle=units=>{if(!isVertical.value){if(props.isBidirectional){let start=Math.min(units,zeroUnits.value),end=Math.max(units,zeroUnits.value);return{left:`${start*100}%`,right:`${(1-end)*100}%`}}return{left:`0%`,right:`${(1-units)*100}%`}}if(props.isBidirectional){let start=Math.min(units,zeroUnits.value),end=Math.max(units,zeroUnits.value);return{bottom:`${start*100}%`,top:`${(1-end)*100}%`}}return{bottom:`0%`,top:`${(1-units)*100}%`}},actualStyle=computed(()=>makeFillStyle(actualUnits.value)),targetStyle=computed(()=>makeFillStyle(targetUnits.value)),showTarget=computed(()=>props.targetValue!==void 0&&props.targetValue!==null),knobStyle=computed(()=>isVertical.value?{bottom:`calc(${actualUnits.value*100}% - 2px)`}:{left:`calc(${actualUnits.value*100}% - 2px)`});return(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,{class:normalizeClass([`bng-input-bar`,{bidirectional:__props.isBidirectional,vertical:isVertical.value}])},[createBaseVNode(`div`,_hoisted_1$181,[showTarget.value?(openBlock(),createElementBlock(`div`,{key:0,class:`fill target`,style:normalizeStyle(targetStyle.value)},null,4)):createCommentVNode(``,!0),createBaseVNode(`div`,{class:`fill actual`,style:normalizeStyle(actualStyle.value)},null,4)]),createBaseVNode(`div`,{class:`knob`,style:normalizeStyle(knobStyle.value)},null,4)],2))}},bngInputBar_default=__plugin_vue_export_helper_default(_sfc_main$202,[[`__scopeId`,`data-v-30b04794`]]),_hoisted_1$180={key:1,class:`data-label`},_hoisted_2$147={key:2,class:`data-value`},_hoisted_3$132={key:3,class:`time-container`},_hoisted_4$109={class:`time-seconds`},_hoisted_5$94={class:`time-milliseconds`},_hoisted_6$77={key:4,class:`data-value-extra`},_sfc_main$201={__name:`bngSimpleDataDisplay`,props:{label:{type:String,default:``},value:{type:[String,Number,Object,Array],default:``},icon:{type:String,default:``},minutes:{type:String},seconds:{type:String},milliseconds:{type:String}},setup(__props){let props=__props,iconType$1=computed(()=>props.icon);return(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,{class:normalizeClass([`simple-data-display`,{"with-icon":__props.icon}])},[__props.icon?(openBlock(),createBlock(unref(bngIcon_default),{key:0,type:iconType$1.value,class:`icon`},null,8,[`type`])):createCommentVNode(``,!0),__props.label&&!__props.icon?(openBlock(),createElementBlock(`div`,_hoisted_1$180,toDisplayString(__props.label),1)):createCommentVNode(``,!0),_ctx.$slots.default?createCommentVNode(``,!0):(openBlock(),createElementBlock(`div`,_hoisted_2$147,toDisplayString(__props.value),1)),props.minutes||props.seconds?(openBlock(),createElementBlock(`div`,_hoisted_3$132,[createBaseVNode(`span`,{class:normalizeClass({"time-minutes":!0,zero:__props.minutes===`00`})},toDisplayString(props.minutes),3),_cache[1]||=createTextVNode(` :`,-1),createBaseVNode(`span`,_hoisted_4$109,toDisplayString(props.seconds),1),props.milliseconds?(openBlock(),createElementBlock(Fragment,{key:0},[_cache[0]||=createTextVNode(` .`,-1),createBaseVNode(`span`,_hoisted_5$94,toDisplayString(props.milliseconds),1)],64)):createCommentVNode(``,!0)])):createCommentVNode(``,!0),_ctx.$slots.default?(openBlock(),createElementBlock(`div`,_hoisted_6$77,[renderSlot(_ctx.$slots,`default`,{},void 0,!0)])):createCommentVNode(``,!0)],2))}},bngSimpleDataDisplay_default=__plugin_vue_export_helper_default(_sfc_main$201,[[`__scopeId`,`data-v-f2b79846`]]),_sfc_main$200={__name:`app`,props:{showFlash:{type:Boolean,default:!0}},setup(__props){let props=__props;return(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,null,[createVNode(Treelights_default),props.showFlash?(openBlock(),createBlock(unref(bngFlashMessage_default),{key:0,"message-source":`DragRaceTreeFlashMessage`})):createCommentVNode(``,!0)]))}},app_default$11=_sfc_main$200,_hoisted_1$179={class:`stage-indicator-container`},_hoisted_2$146={class:`stage-bar`},_hoisted_3$131={key:0,class:`segment grey-segment top`},_hoisted_4$108={key:1,class:`segment grey-segment bottom`},_hoisted_5$93={class:`indicator-line`},THROTTLE_MS=1,HIDE_DELAY_MS=5e3,_sfc_main$199={__name:`app`,setup(__props){let events$3=useEvents(),stageDistance=ref(-100),isVisible$1=ref(!0),hideTimeout,isDetailedView=computed(()=>stageDistance.value>-1&&stageDistance.value<1),indicatorPosition=computed(()=>isDetailedView?70-(stageDistance.value+1)*20:stageDistance.value<-1?10-stageDistance.value:30-(stageDistance.value-1)*(30/3)),lastUpdate=0;function updateStageApp(distance){let now$1=performance.now();now$1-lastUpdate{isVisible$1.value=!1},HIDE_DELAY_MS))}return onMounted(()=>{events$3.on(`updateStageApp`,updateStageApp)}),onUnmounted(()=>{lastUpdate=0,clearTimeout(hideTimeout),events$3.off(`updateStageApp`,updateStageApp)}),(_ctx,_cache)=>(openBlock(),createElementBlock(Fragment,null,[createBaseVNode(`div`,null,toDisplayString(stageDistance.value),1),withDirectives(createBaseVNode(`div`,_hoisted_1$179,[createBaseVNode(`div`,_hoisted_2$146,[isDetailedView.value?(openBlock(),createElementBlock(`div`,_hoisted_3$131)):createCommentVNode(``,!0),createBaseVNode(`div`,{class:normalizeClass([`middle-section`,{"align-top":!isDetailedView.value&&stageDistance.value<-1,"align-bottom":!isDetailedView.value&&stageDistance.value>1}])},[isDetailedView.value?(openBlock(),createElementBlock(Fragment,{key:0},[_cache[0]||=createBaseVNode(`div`,{class:`segment deep-stage`,style:{height:`20px`}},null,-1),_cache[1]||=createBaseVNode(`div`,{class:`segment stage`,style:{height:`40px`}},null,-1),_cache[2]||=createBaseVNode(`div`,{class:`segment pre-stage`,style:{height:`40px`}},null,-1)],64)):(openBlock(),createElementBlock(`div`,{key:1,class:normalizeClass([`segment green-segment`,{top:stageDistance.value<-1,bottom:stageDistance.value>1}])},null,2))],2),stageDistance.value<=1?(openBlock(),createElementBlock(`div`,_hoisted_4$108)):createCommentVNode(``,!0)]),createBaseVNode(`div`,{class:`distance-indicator`,style:normalizeStyle({top:indicatorPosition.value+`%`})},[createBaseVNode(`div`,_hoisted_5$93,[createBaseVNode(`div`,{class:normalizeClass([`car-icon`,{"car-icon-detailed":isDetailedView.value}])},null,2)])],4)],512),[[vShow,isVisible$1.value&&stageDistance.value>=-4&&stageDistance.value<=4]])],64))}},app_default$12=__plugin_vue_export_helper_default(_sfc_main$199,[[`__scopeId`,`data-v-5245723d`]]),_hoisted_1$178={class:`main-container drift-app`},_hoisted_2$145={class:`cached-score-wrapper`},_hoisted_3$130={class:`added-score`},_hoisted_4$107={class:`cached-score`},_hoisted_5$92={class:`score-container`},_hoisted_6$76={class:`score`},_hoisted_7$66={class:`combo-wrapper`},_hoisted_8$53=[`id`],_hoisted_9$47=[`id`],_hoisted_10$40=[`stop-color`],_hoisted_11$35=[`stop-color`],_hoisted_12$27=[`id`],_hoisted_13$24={class:`multiplier`,x:`0`,y:`15.5`,fill:`#fff`,"dominant-baseline":`hanging`,"text-anchor":`start`,style:{fontSize:`1.9rem`}},_hoisted_14$23=[`mask`],_hoisted_15$22=[`fill`],_hoisted_16$22={class:`remaining-time`},_hoisted_17$17={class:`wrapper`},_hoisted_18$15={class:`drift-bar`},_hoisted_19$12={class:`drift-scale`},_hoisted_20$11={class:`drift-progress-bar`},FAIL_ANIMATION_DURATION=900,_sfc_main$198={__name:`app`,props:{showFlash:{type:Boolean,default:!0}},setup(__props){let props=__props,{lua}=useBridge(),bgId=uniqueId(``,`_`),events$3=useEvents(),realtimeScorePoints=ref(0),realtimeScoreCombo=ref(0),creep=ref(0),remainingComboTime=ref(0),centerIcon=ref(null),centerMessage=ref(null),centerFailMessage=ref(null),scoreToAdd=ref(0),countdownTimer=null,countdownStartTime=null,delayTimer=null,startTimer=null,centerMessageTimer=null,bonusDisplayAdd=null,bonusDisplayDispose=null,bonusQueue=ref([]),bonusDisplay=ref([]),realtimeAngle=ref(0),steppedPerformanceFactor=ref(1),isCenterMessageFading=ref(!1),isFailActive=ref(!1),isFailAnimating=ref(!1),failAnimationStartTime=null,failAnimationTimer=null,currentModifier=ref(null),isModifierFading=ref(!1),modifierTimer=null;onMounted(()=>{let rafScheduled=!1,buffered={points:0,combo:0,remaining:0,creep:0,angle:0},flushBuffered=()=>{realtimeScorePoints.value=buffered.points,realtimeScoreCombo.value=buffered.combo,remainingComboTime.value=buffered.remaining,creep.value=buffered.creep,realtimeAngle.value=buffered.angle,rafScheduled=!1},scheduleFlush=()=>{rafScheduled||(rafScheduled=!0,requestAnimationFrame(flushBuffered))},streamsList$1=[`drift`];useStreams(streamsList$1,streams=>{for(let stream of streamsList$1)if(!streams[stream])return;buffered.points=streams.drift.realtimeCachedScoreFloored,buffered.combo=streams.drift.realtimeCombo,buffered.points>0&&(centerMessage.value=null),buffered.remaining=streams.drift.realtimeRemainingComboTime,buffered.creep=streams.drift.realtimeCreep,buffered.angle=-streams.drift.realtimeAngle,steppedPerformanceFactor.value=streams.drift.realtimePerformanceFactor,scheduleFlush()}),events$3.on(`setDriftRealtimeFail`,(reason,icon)=>{cancelTimers(),isFailActive.value=!0,isFailAnimating.value=!0,isCenterMessageFading.value=!1,centerFailMessage.value=reason,centerIcon.value=icon||``,bonusDisplay.value=[],creep.value=0;let initialComboTime=remainingComboTime.value;failAnimationStartTime=performance.now();let animateFailBar=timestamp=>{let elapsed=timestamp-failAnimationStartTime,progress=Math.max(0,1-elapsed/FAIL_ANIMATION_DURATION);remainingComboTime.value=initialComboTime*progress,progress>0&&(failAnimationTimer=requestAnimationFrame(animateFailBar))};failAnimationTimer=requestAnimationFrame(animateFailBar),centerMessageTimer&&clearTimeout(centerMessageTimer),setTimeout(()=>{isFailActive.value=!1,isFailAnimating.value=!1,remainingComboTime.value=0,failAnimationTimer&&=(cancelAnimationFrame(failAnimationTimer),null)},FAIL_ANIMATION_DURATION),centerMessageTimer=setTimeout(()=>{isCenterMessageFading.value=!0},1e3),setTimeout(()=>{centerFailMessage.value=null,centerIcon.value=null,isCenterMessageFading.value=!1},1500)}),events$3.on(`setDriftPersistentDriftScored`,(final,score,combo)=>{centerMessage.value=`+ `,scoreToAdd.value=final,bonusDisplay.value=[],startCountdown()}),events$3.on(`displayDriftScoreModifier`,msg=>{modifierTimer&&clearTimeout(modifierTimer),isModifierFading.value=!1,currentModifier.value=msg,modifierTimer=setTimeout(()=>{isModifierFading.value=!0},1500)})}),onUnmounted(()=>{cancelTimers(),centerMessageTimer&&clearTimeout(centerMessageTimer),clearInterval(bonusDisplayAdd),clearInterval(bonusDisplayDispose),failAnimationTimer&&cancelAnimationFrame(failAnimationTimer),modifierTimer&&clearTimeout(modifierTimer),window.removeEventListener(`resize`,onResize)});let barClass=computed(()=>({"bar-good":!isFailAnimating.value&&steppedPerformanceFactor.value>=3,"bar-warn":!isFailAnimating.value&&steppedPerformanceFactor.value<3,"bar-fail":isFailAnimating.value})),barVarsStyle=computed(()=>({"--bar-scale":String(Math.max(0,Math.min(1,remainingComboTime.value))),"--bar-visible":remainingComboTime.value<=.01?`hidden`:`visible`})),driftProgressStyle=computed(()=>{let pos=Math.abs(calculatePosition(realtimeAngle.value,thresholds,positions))/100;return{left:`50%`,width:`50%`,transform:`scaleX(${((realtimeAngle.value>0?1:-1)>0?1:-1)*(pos/2)})`,opacity:Math.abs(realtimeAngle.value)<7?`0.65`:`1`}}),formattedCombo=computed(()=>parseFloat(realtimeScoreCombo.value).toFixed(1)),formattedRealtimeAngle=computed(()=>Math.abs(Math.round(realtimeAngle.value))),layoutVersion=ref(0),tickLefts=computed(()=>positions.map(p$1=>`${(p$1+100)/2}%`)),onResize=()=>{layoutVersion.value++};window.addEventListener(`resize`,onResize);function cancelTimers(){countdownTimer&&=(cancelAnimationFrame(countdownTimer),null),delayTimer&&=(clearTimeout(delayTimer),null),startTimer&&=(clearTimeout(startTimer),null),failAnimationTimer&&=(cancelAnimationFrame(failAnimationTimer),null)}function startCountdown(){cancelTimers(),startTimer=setTimeout(()=>{let initialScore=scoreToAdd.value,scoreDwindleAnimDuration=1e3;function countdown(timestamp){countdownStartTime||=timestamp;let elapsedTime=timestamp-countdownStartTime;elapsedTime>=scoreDwindleAnimDuration?(scoreToAdd.value=0,countdownStartTime=null,delayTimer=setTimeout(()=>{scoreToAdd.value=-1,centerMessage.value=null,realtimeScorePoints.value=0,realtimeScoreCombo.value=0,creep.value=0,delayTimer=null},1e3)):(scoreToAdd.value=Math.floor(initialScore*(1-elapsedTime/scoreDwindleAnimDuration)),countdownTimer=requestAnimationFrame(countdown))}countdownTimer=requestAnimationFrame(countdown)},1250)}let thresholds=[-110,-60,-20,0,20,60,110],positions=[-100,-70,-35,0,35,70,100],calculatePosition=(y,thresholds$1,positions$1)=>{let clampedY=Math.max(thresholds$1[0],Math.min(thresholds$1[thresholds$1.length-1],y));for(let i=0;i=thresholds$1[i]&&clampedY<=thresholds$1[i+1]){let t=(clampedY-thresholds$1[i])/(thresholds$1[i+1]-thresholds$1[i]);return positions$1[i]+t*(positions$1[i+1]-positions$1[i])}return 0},performanceBgClass=computed(()=>({"perf-good":steppedPerformanceFactor.value>=3,"perf-warn":steppedPerformanceFactor.value<3})),performanceTransformStyle=computed(()=>{let sRaw=Math.min(steppedPerformanceFactor.value/3,1);return{transform:`scale(${sRaw===0?.001:sRaw})`,transformOrigin:`center bottom`,opacity:sRaw===0?0:1}});function onModifierTransitionEnd(e){e.propertyName===`opacity`&&(isModifierFading.value&&=(currentModifier.value=null,!1))}let comboVarsStyle=computed(()=>({"--combo-glow-color":realtimeScoreCombo.value>=25?`210, 110, 0`:`255, 255, 0`,"--combo-glow-alpha":String(creep.value),"--combo-rect-translate":`${-creep.value*2}rem`}));function ensureBonusTimers(){!bonusDisplayAdd&&bonusQueue.value.length>0&&(bonusDisplayAdd=setInterval(()=>{if(bonusQueue.value.length===0)return;let item=bonusQueue.value.pop();bonusDisplay.value.unshift(item)},500)),!bonusDisplayDispose&&bonusDisplay.value.length>0&&(bonusDisplayDispose=setInterval(()=>{bonusDisplay.value.length>0&&bonusDisplay.value.pop()},1e4)),bonusQueue.value.length===0&&bonusDisplay.value.length===0&&(bonusDisplayAdd&&=(clearInterval(bonusDisplayAdd),null),bonusDisplayDispose&&=(clearInterval(bonusDisplayDispose),null))}return watch(bonusQueue,ensureBonusTimers,{deep:!0}),watch(bonusDisplay,ensureBonusTimers,{deep:!0}),onMounted(()=>{lua.extensions.gameplay_drift_general.onDriftAppMounted()}),onUnmounted(()=>{lua.extensions.gameplay_drift_general.onDriftAppUnmounted()}),(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$178,[createBaseVNode(`div`,_hoisted_2$145,[createBaseVNode(`div`,{class:normalizeClass([`fail-overlay`,{active:isFailActive.value}])},null,2),createBaseVNode(`div`,{class:normalizeClass([`performance-background`,performanceBgClass.value]),style:normalizeStyle(performanceTransformStyle.value)},null,6),centerFailMessage.value?(openBlock(),createElementBlock(`div`,{key:0,class:normalizeClass([`center`,{"fade-out":isCenterMessageFading.value}])},toDisplayString(centerFailMessage.value),3)):centerMessage.value?(openBlock(),createElementBlock(`div`,{key:1,class:normalizeClass([`center`,{"fade-out":isCenterMessageFading.value}])},[createTextVNode(toDisplayString(centerMessage.value)+` `,1),centerMessage.value&&scoreToAdd.value>=0?(openBlock(),createElementBlock(Fragment,{key:0},[createTextVNode(toDisplayString(scoreToAdd.value),1)],64)):createCommentVNode(``,!0)],2)):(openBlock(),createElementBlock(Fragment,{key:2},[createBaseVNode(`div`,_hoisted_3$130,[(openBlock(!0),createElementBlock(Fragment,null,renderList(bonusDisplay.value,(item,index)=>(openBlock(),createElementBlock(`div`,{key:index,class:`score-item`},` +`+toDisplayString(~~item.score),1))),128))]),createBaseVNode(`div`,_hoisted_4$107,[createBaseVNode(`div`,_hoisted_5$92,[(openBlock(),createElementBlock(`div`,{class:normalizeClass([`score-modifier`,{"fade-out":isModifierFading.value}]),key:currentModifier.value,onTransitionend:onModifierTransitionEnd},toDisplayString(currentModifier.value),35)),createBaseVNode(`div`,_hoisted_6$76,toDisplayString(realtimeScorePoints.value),1)]),createBaseVNode(`div`,_hoisted_7$66,[(openBlock(),createElementBlock(`svg`,{id:`svg_${unref(bgId)}`,class:`combo`,viewBox:`0 0 100 30`,style:normalizeStyle([{width:`100%`,height:`3rem`},comboVarsStyle.value]),preserveAspectRatio:`xMinYMid meet`},[createBaseVNode(`defs`,null,[createBaseVNode(`linearGradient`,{id:`grad_${unref(bgId)}`,x1:`0%`,y1:`0%`,x2:`0%`,y2:`100%`},[_cache[0]||=createBaseVNode(`stop`,{offset:`50%`,"stop-color":`var(--bng-ter-yellow-100)`},null,-1),createBaseVNode(`stop`,{offset:`51%`,"stop-color":realtimeScoreCombo.value>=25?`#ff8400`:`#fff`},null,8,_hoisted_10$40),createBaseVNode(`stop`,{offset:`75%`,"stop-color":realtimeScoreCombo.value>=25?`#ff8400`:`#fff`},null,8,_hoisted_11$35)],8,_hoisted_9$47),createBaseVNode(`mask`,{id:`mask_${unref(bgId)}`},[createBaseVNode(`text`,_hoisted_13$24,` ×`+toDisplayString(formattedCombo.value),1)],8,_hoisted_12$27)]),createBaseVNode(`g`,{mask:`url(#mask_${unref(bgId)})`},[createBaseVNode(`rect`,{width:`100%`,height:`4.2rem`,x:`0`,y:`15.5`,fill:`url(#grad_${unref(bgId)})`,class:`animated-rect`},null,8,_hoisted_15$22)],8,_hoisted_14$23)],12,_hoisted_8$53))])])],64))]),createBaseVNode(`div`,_hoisted_16$22,[createBaseVNode(`div`,_hoisted_17$17,[createBaseVNode(`div`,{class:normalizeClass([`bar`,barClass.value]),style:normalizeStyle(barVarsStyle.value)},null,6)])]),createBaseVNode(`div`,_hoisted_18$15,[createBaseVNode(`div`,_hoisted_19$12,[createBaseVNode(`div`,_hoisted_20$11,[createBaseVNode(`div`,{class:`progress-fill`,style:normalizeStyle(driftProgressStyle.value)},null,4)]),(openBlock(),createElementBlock(`div`,{class:`value-marks`,key:layoutVersion.value},[(openBlock(),createElementBlock(Fragment,null,renderList(thresholds,(threshold,index)=>createBaseVNode(`div`,{class:`line`,key:threshold,style:normalizeStyle({position:`absolute`,left:tickLefts.value[index],width:`0.125rem`,height:`0.24rem`,transform:threshold===0?`translateX(-50%)`:threshold>0?`translateX(-100%)`:`translateX(0%)`,backgroundColor:`white`})},null,4)),64))]))]),(openBlock(),createElementBlock(`div`,{class:`drift-labels`,key:layoutVersion.value},[(openBlock(),createElementBlock(Fragment,null,renderList(thresholds,(threshold,index)=>createBaseVNode(`span`,{key:threshold,style:normalizeStyle({position:`absolute`,left:tickLefts.value[index],transform:`translateX(-50%)`,textAlign:`center`})},toDisplayString(threshold===0?`${formattedRealtimeAngle.value}°`:`${Math.abs(threshold)}°`),5)),64))])),props.showFlash?(openBlock(),createBlock(unref(bngFlashMessage_default),{key:0,"message-source":`DriftFlashMessage`})):createCommentVNode(``,!0)])]))}},app_default$13=__plugin_vue_export_helper_default(_sfc_main$198,[[`__scopeId`,`data-v-aa80ede0`]]),_hoisted_1$177={class:`main-container-grid`},_hoisted_2$144={class:`scores-container`},_hoisted_3$129={class:`permanent`},_hoisted_4$106={class:`points-label`},_sfc_main$197={__name:`app`,setup(__props){let events$3=useEvents(),permanentScore=ref(0),potentialScore=ref(0),isAnimatingPotentialScore=ref(!1),dontUpdateScores=ref(!1),lastPotentialScore=ref(0);onMounted(()=>{events$3.on(`setDriftPersistentDriftScored`,(score,combo)=>{isAnimatingPotentialScore.value=!0,dontUpdateScores.value=!0,potentialScore.value=score,lastPotentialScore.value=potentialScore.value,setTimeout(()=>{isAnimatingPotentialScore.value=!1},1e3),setTimeout(()=>{dontUpdateScores.value=!1},900)})}),onUnmounted(()=>{events$3.off(`setDriftPersistentDriftScored`)});let streamsList$1=[`drift`];return useStreams(streamsList$1,streams=>{for(let stream of streamsList$1)if(!streams[stream])return;dontUpdateScores.value||(permanentScore.value=streams.drift.permanentScore,potentialScore.value=streams.drift.potentialScore)}),(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$177,[createBaseVNode(`div`,_hoisted_2$144,[createBaseVNode(`div`,_hoisted_3$129,[createBaseVNode(`span`,_hoisted_4$106,toDisplayString(unref($translate).instant(`missions.drift.general.pointsShort`))+`: `,1),createTextVNode(toDisplayString(permanentScore.value),1)]),createBaseVNode(`div`,{class:normalizeClass([`potential`,{"animate-potential-score":isAnimatingPotentialScore.value}])},` + `+toDisplayString(potentialScore.value),3)])]))}},app_default$14=__plugin_vue_export_helper_default(_sfc_main$197,[[`__scopeId`,`data-v-29f9fe6b`]]),_hoisted_1$176={class:`main-container-grid`},_sfc_main$196={__name:`app`,setup(__props){let{lua}=useBridge(),events$3=useEvents(),showButton=ref(!1),handleNextStep=()=>{lua.gameplay_crashTest_scenarioManager.nextStepFromUI(),showButton.value=!1};return onMounted(()=>{events$3.on(`onCrashTestStepFinished`,()=>{console.log(`onCrashTestStepFinished`),showButton.value=!0})}),onUnmounted(()=>{events$3.off(`onCrashTestStepFinished`)}),(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$176,[showButton.value?(openBlock(),createBlock(unref(bngButton_default),{key:0,onClick:handleNextStep,accent:unref(ACCENTS).text,icon:unref(icons).arrowSolidRight,class:normalizeClass({"next-step-button":!0})},{default:withCtx(()=>[createTextVNode(toDisplayString(unref($translate).instant(`missions.crashTest.general.nextStep`)),1)]),_:1},8,[`accent`,`icon`])):createCommentVNode(``,!0)]))}},app_default$15=__plugin_vue_export_helper_default(_sfc_main$196,[[`__scopeId`,`data-v-6d935866`]]),_hoisted_1$175={class:`bng-app`},_sfc_main$195={__name:`app`,setup(__props){let{$game}=useLibStore(),streamsList$1=[`engineInfo`],data=reactive({engineT:0,wheelT:0,rpm:0,gearText:``});onMounted(()=>$game.streams.add(streamsList$1)),onUnmounted(()=>$game.streams.remove(streamsList$1)),$game.events.on(`onStreamsUpdate`,streams=>{streams.engineInfo!==null&&(data.engineT=$game.units.buildString(`torque`,streams.engineInfo[8],0),data.wheelT=$game.units.buildString(`torque`,streams.engineInfo[19],0),data.rpm=streams.engineInfo[4].toFixed(),data.gearText=getGearText(streams.engineInfo[16],streams.engineInfo[6],streams.engineInfo[7]))});let getGearText=(gear,fGear,rGear)=>gear>0?`F `+gear+` / `+fGear:gear<0?`R `+Math.abs(gear)+` / `+rGear:`N`;return(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$175,[createTextVNode(toDisplayString(_ctx.$t(`ui.apps.engineinfo.rpm`))+`: `+toDisplayString(data.rpm),1),_cache[0]||=createBaseVNode(`br`,null,null,-1),createTextVNode(` `+toDisplayString(_ctx.$t(`ui.apps.engineinfo.gear`))+`: `+toDisplayString(data.gearText),1),_cache[1]||=createBaseVNode(`br`,null,null,-1),createTextVNode(` `+toDisplayString(_ctx.$t(`ui.apps.engineinfo.flywheelTorque`))+`: `+toDisplayString(data.engineT)+` `,1),_cache[2]||=createBaseVNode(`br`,null,null,-1),createTextVNode(` `+toDisplayString(_ctx.$t(`ui.apps.engineinfo.wheelTorque`))+`: `+toDisplayString(data.wheelT),1)]))}},app_default$16=_sfc_main$195,_hoisted_1$174={class:`legends`},_hoisted_2$143={class:`torque-flywheel`},_hoisted_3$128={class:`power-flywheel`},_hoisted_4$105={class:`power-wheels`},_hoisted_5$91={class:`rpm`},_hoisted_6$75={class:`content`},_hoisted_7$65={class:`power-label`},_hoisted_8$52={class:`label`},_hoisted_9$46={class:`canvas-container`},_hoisted_10$39={class:`torque-label`},_hoisted_11$34={class:`label`},tickLabels=21,torqueGraphColor=`#000000`,powerGraphColor=`#FF0000`,powerWheelGraphColor=`#FF4400`,rpmGraphColor=`#0000FF`,_sfc_main$194={__name:`app`,setup(__props){let{$game}=useLibStore(),streamsList$1=[`engineInfo`],app$1=ref(null),canvas=ref(null),globalMax=ref(0),torqueUnit=ref(null),powerUnit=ref(null),tickSpacing=ref(0),tickInterval=computed(()=>globalMax.value/10),appResizeObserver=new ResizeObserver(entries=>{let entry=entries[0];canvas.value.width=entry.target.offsetWidth-130,canvas.value.height=entry.target.offsetHeight-20,tickSpacing.value=canvas.value.height/10,console.log(`width`,entry.target.offsetWidth),console.log(`height`,entry.target.offsetHeight),console.log(`tickspacing`,tickSpacing.value),console.log(`canvas`,canvas.value.width,canvas.value.height)}),chart=new SmoothieChart({minValue:0,maxValue:1e3,millisPerPixel:20,interpolation:`bezier`,grid:{fillStyle:`rgba(250,250,250,0.2)`,strokeStyle:`grey`,verticalSections:20,millisPerLine:1e3,sharpLines:!0},labels:{disabled:!0}}),torqueGraph=new TimeSeries,powerGraph=new TimeSeries,powerWheelGraph=new TimeSeries,rpmGraph=new TimeSeries;onMounted(()=>{initChart(),appResizeObserver.observe(app$1.value),$game.events.on(`onStreamsUpdate`,onStreamsUpdate),$game.streams.add(streamsList$1)}),onBeforeUnmount(()=>{appResizeObserver.unobserve(app$1.value)}),onUnmounted(()=>{$game.events.off(`onStreamsUpdate`,onStreamsUpdate),$game.streams.remove(streamsList$1)});function onStreamsUpdate(streams){for(let stream of streamsList$1)if(!streams[stream])return;let xPoint=new Date,torque=$game.units.torque(streams.engineInfo[8]).val,power$1=$game.units.power(streams.engineInfo[4]*.104719755*streams.engineInfo[8]/1e3*1.34102).val,wheelPower=$game.units.power(streams.engineInfo[20]/1e3*1.34102).val,rpm=streams.engineInfo[4]/10;torqueUnit.value=$game.units.torque().unit,powerUnit.value=$game.units.power().unit,globalMax.value=Math.ceil(Math.max.apply(null,[globalMax.value,torque,power$1])/100)*100,chart.options.maxValue=globalMax.value,torqueGraph.append(xPoint,torque),powerGraph.append(xPoint,power$1),powerWheelGraph.append(xPoint,wheelPower),rpmGraph.append(xPoint,rpm)}function initChart(){chart.addTimeSeries(torqueGraph,{strokeStyle:torqueGraphColor,lineWidth:1.5}),chart.addTimeSeries(powerGraph,{strokeStyle:powerGraphColor,lineWidth:1.5}),chart.addTimeSeries(powerWheelGraph,{strokeStyle:powerWheelGraphColor,lineWidth:1.5}),chart.addTimeSeries(rpmGraph,{strokeStyle:rpmGraphColor,lineWidth:1.5}),chart.streamTo(canvas.value,40)}return(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,{ref_key:`app`,ref:app$1,class:`engine-dynamometer`},[createBaseVNode(`div`,_hoisted_1$174,[createBaseVNode(`small`,_hoisted_2$143,toDisplayString(_ctx.$t(`ui.apps.engine_dynamometer.torqueFlywheel`)),1),createBaseVNode(`small`,_hoisted_3$128,toDisplayString(_ctx.$t(`ui.apps.engine_dynamometer.powerFlywheel`)),1),createBaseVNode(`small`,_hoisted_4$105,toDisplayString(_ctx.$t(`ui.apps.engine_dynamometer.powerWheels`)),1),createBaseVNode(`small`,_hoisted_5$91,toDisplayString(_ctx.$t(`ui.apps.engine_dynamometer.rpm`)),1)]),createBaseVNode(`div`,_hoisted_6$75,[createBaseVNode(`div`,_hoisted_7$65,[createBaseVNode(`div`,_hoisted_8$52,toDisplayString(_ctx.$t(`ui.apps.engine_dynamometer.power`))+` (`+toDisplayString(powerUnit.value)+`) `,1),(openBlock(),createElementBlock(Fragment,null,renderList(tickLabels,(n,index)=>createBaseVNode(`div`,{class:`ruler`,style:normalizeStyle({top:index*tickSpacing.value+`px`})},toDisplayString((globalMax.value-index*tickInterval.value).toFixed(0)),5)),64))]),createBaseVNode(`div`,_hoisted_9$46,[createBaseVNode(`canvas`,{ref_key:`canvas`,ref:canvas,class:`canvas`},null,512)]),createBaseVNode(`div`,_hoisted_10$39,[createBaseVNode(`div`,_hoisted_11$34,toDisplayString(_ctx.$t(`ui.apps.engine_dynamometer.torque`))+` (`+toDisplayString(torqueUnit.value)+`) `,1),(openBlock(),createElementBlock(Fragment,null,renderList(tickLabels,(n,index)=>createBaseVNode(`div`,{class:`ruler`,style:normalizeStyle({top:index*tickSpacing.value+`px`})},toDisplayString((globalMax.value-index*tickInterval.value).toFixed(0)),5)),64))])])],512))}},app_default$17=__plugin_vue_export_helper_default(_sfc_main$194,[[`__scopeId`,`data-v-e025129d`]]),_hoisted_1$173={class:`legends`},_hoisted_2$142={class:`water`},_hoisted_3$127={class:`oil`},_hoisted_4$104={class:`block`},_hoisted_5$90={class:`exhaust`},coolantGraphColor=`#333676`,oilGraphColor=`#AA8C39`,blockGraphColor=`#378B2E`,exhaustGraphColor=`#A7383E`,_sfc_main$193={__name:`app`,setup(__props){let{$game}=useLibStore(),streamsList$1=[`engineThermalData`],app$1=ref(null),canvas=ref(null),isRunning=ref(!1),appResizeObserver=new ResizeObserver(entries=>{let entry=entries[0];canvas.value.width=entry.target.offsetWidth,canvas.value.height=entry.target.offsetHeight}),chart=new SmoothieChart({minValue:50,maxValue:150,millisPerPixel:40,interpolation:`bezier`,grid:{fillStyle:`rgba(250,250,250,0.8)`,strokeStyle:`black`,verticalSections:0,millisPerLine:0},labels:{fillStyle:`black`}}),coolantGraph=new TimeSeries,oilGraph=new TimeSeries,blockGraph=new TimeSeries,exhaustGraph=new TimeSeries;onMounted(()=>{initChart(),appResizeObserver.observe(app$1.value),$game.streams.add(streamsList$1),$game.events.on(`onStreamsUpdate`,onStreamsUpdate)}),onBeforeUnmount(()=>{appResizeObserver.unobserve(app$1.value)}),onUnmounted(()=>{$game.events.off(`onStreamsUpdate`,onStreamsUpdate),$game.streams.remove(streamsList$1)});function onStreamsUpdate(streams){if(streams.engineThermalData){isRunning.value||(isRunning.value=!0,chart.start());let xPoint=new Date;coolantGraph.append(xPoint,streams.engineThermalData.coolantTemperature),oilGraph.append(xPoint,streams.engineThermalData.oilTemperature),blockGraph.append(xPoint,streams.engineThermalData.engineBlockTemperature),exhaustGraph.append(xPoint,streams.engineThermalData.exhaustTemperature)}else isRunning.value&&(isRunning.value=!1,chart.stop())}function initChart(){chart.addTimeSeries(coolantGraph,{strokeStyle:coolantGraphColor,lineWidth:1}),chart.addTimeSeries(oilGraph,{strokeStyle:oilGraphColor,lineWidth:1}),chart.addTimeSeries(blockGraph,{strokeStyle:blockGraphColor,lineWidth:1}),chart.addTimeSeries(exhaustGraph,{strokeStyle:exhaustGraphColor,lineWidth:1}),chart.streamTo(canvas.value,40)}return(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,{ref_key:`app`,ref:app$1,class:`engine-hdg`},[createBaseVNode(`div`,_hoisted_1$173,[createBaseVNode(`small`,_hoisted_2$142,toDisplayString(_ctx.$t(`ui.apps.engine_heat_debug_graph.water`)),1),createBaseVNode(`small`,_hoisted_3$127,toDisplayString(_ctx.$t(`ui.apps.engine_heat_debug_graph.oil`)),1),createBaseVNode(`small`,_hoisted_4$104,toDisplayString(_ctx.$t(`ui.apps.engine_heat_debug_graph.block`)),1),createBaseVNode(`small`,_hoisted_5$90,toDisplayString(_ctx.$t(`ui.apps.engine_heat_debug_graph.exhaust`)),1)]),createBaseVNode(`canvas`,{ref_key:`canvas`,ref:canvas},null,512)],512))}},app_default$18=__plugin_vue_export_helper_default(_sfc_main$193,[[`__scopeId`,`data-v-ac69837e`]]),_hoisted_1$172={class:`bng-app thermal-clutch-debug`},_hoisted_2$141={class:`set-name`},_sfc_main$192={__name:`app`,setup(__props){let{$game}=useLibStore(),streamsList$1=[`engineThermalData`],data=ref(null);onMounted(()=>{$game.streams.add(streamsList$1)}),onUnmounted(()=>{$game.streams.remove(streamsList$1)}),$game.events.on(`onStreamsUpdate`,streams=>data.value=streams.engineThermalData?parseData(streams.engineThermalData):null);function parseData(data$1){return[{str:$game.units.buildString(`temperature`,data$1.coolantTemperature,0),name:`ui.apps.engine_thermal_debug.coolant`,warn:data$1.coolantTemperature>data$1.thermostatTemperature&&data$1.coolantTemperature<120&&data$1.thermostatStatus==1,error:data$1.coolantTemperature>120},{str:$game.units.buildString(`temperature`,data$1.oilTemperature,0),name:`ui.apps.engine_thermal_debug.oil`,warn:data$1.oilTemperature>140,error:data$1.oilTemperature>150},{str:$game.units.buildString(`temperature`,data$1.engineBlockTemperature,0),name:`ui.apps.engine_thermal_debug.block`},{str:$game.units.buildString(`temperature`,data$1.cylinderWallTemperature,0),name:`ui.apps.engine_thermal_debug.cylinderlWall`},{str:$game.units.buildString(`temperature`,data$1.exhaustTemperature,0),name:`ui.apps.engine_thermal_debug.exhaustManifold`},{str:data$1.thermostatStatus.toFixed(3),name:`ui.apps.engine_thermal_debug.coolantThermostat`,warn:data$1.thermostatStatus>.9},{str:data$1.airRegulatorStatus.toFixed(3),name:`ui.apps.engine_thermal_debug.airRegulator`,warn:data$1.airRegulatorStatus>.9},{str:$game.units.buildString(`speed`,data$1.radiatorAirSpeed,0),name:`ui.apps.engine_thermal_debug.radiatorAirSpeed`},{str:data$1.radiatorAirSpeedEfficiency.toFixed(4),name:`ui.apps.engine_thermal_debug.radiatorAirSpeedEfficiency`},{str:data$1.fanActive,name:`ui.apps.engine_thermal_debug.radiatorFanActive`},{str:data$1.coolantMass.toFixed(3),name:`ui.apps.engine_thermal_debug.coolantMass`},{str:data$1.coolantLeakRateOverpressure.toFixed(3),name:`ui.apps.engine_thermal_debug.coolantLeakRateOverpressure`,warn:data$1.coolantLeakRateOverpressure>0},{str:data$1.coolantLeakRateHeadGasket.toFixed(3),name:`ui.apps.engine_thermal_debug.coolantLeakRateHeadGasket`,warn:data$1.coolantLeakRateHeadGasket>0},{str:data$1.coolantLeakRateRadiator.toFixed(3),name:`ui.apps.engine_thermal_debug.coolantLeakRateRadiator`,warn:data$1.coolantLeakRateRadiator>0},{str:data$1.coolantLeakRateOverall.toFixed(3),name:`ui.apps.engine_thermal_debug.coolantLeakRateOverall`,warn:data$1.coolantLeakRateOverall>0},{str:data$1.coolantEfficiency.toFixed(3),name:`ui.apps.engine_thermal_debug.coolantEfficiency`,warn:data$1.coolantEfficiency<1,error:data$1.coolantEfficiency===0},{str:data$1.oilThermostatStatus.toFixed(3),name:`ui.apps.engine_thermal_debug.oilThermostat`,warn:data$1.oilThermostatStatus>.9},{str:data$1.oilMass.toFixed(3),name:`ui.apps.engine_thermal_debug.oilMass`,warn:data$1.oilMassdata$1.maximumSafeOilMass},{str:data$1.miniumSafeOilMass.toFixed(3),name:`ui.apps.engine_thermal_debug.miniumSafeOilMass`},{str:data$1.maximumSafeOilMass.toFixed(3),name:`ui.apps.engine_thermal_debug.maximumSafeOilMass`},{str:data$1.oilLeakRateOilpan.toFixed(3),name:`ui.apps.engine_thermal_debug.oilLeakRateOilpan`,warn:data$1.oilLeakRateOilpan>0},{str:data$1.oilLeakRateRadiator.toFixed(3),name:`ui.apps.engine_thermal_debug.oilLeakRateRadiator`,warn:data$1.oilLeakRateRadiator>0},{str:data$1.oilLeakRateGravity.toFixed(3),name:`ui.apps.engine_thermal_debug.oilLeakRateGravity`,warn:data$1.oilLeakRateGravity>0},{str:data$1.oilLeakRatePistonRingDamage.toFixed(3),name:`ui.apps.engine_thermal_debug.oilLeakRatePistonRingDamage`,warn:data$1.oilLeakRatePistonRingDamage>0},{str:data$1.oilLeakRateOverall.toFixed(3),name:`ui.apps.engine_thermal_debug.oilLeakRateOverall`,warn:data$1.oilLeakRateOverall>0},{str:data$1.oilStarvingSevernessXY.toFixed(3),name:`ui.apps.engine_thermal_debug.oilStarvingSevernessXY`,warn:data$1.oilStarvingSevernessXY>0},{str:data$1.oilStarvingSevernessZ.toFixed(3),name:`ui.apps.engine_thermal_debug.oilStarvingSevernessZ`,warn:data$1.oilStarvingSevernessZ>0},{str:data$1.maximumSafeG.toFixed(3),name:`ui.apps.engine_thermal_debug.maximumSafeG`},{str:data$1.oilLubricationCoef.toFixed(3),name:`ui.apps.engine_thermal_debug.oilLubricationCoef`,warn:data$1.oilLubricationCoef<1},{str:data$1.missingOilDamage.toFixed(3),name:`ui.apps.engine_thermal_debug.missingOilDamage`,warn:data$1.missingOilDamage>0},{str:data$1.engineEfficiency.toFixed(2),name:`ui.apps.engine_thermal_debug.engineEfficiency`},{str:$game.units.buildString(`energy`,data$1.energyToCylinderWall,0),name:`ui.apps.engine_thermal_debug.qtocylinderwall`},{str:$game.units.buildString(`energy`,data$1.energyCylinderWallToCoolant,0),name:`ui.apps.engine_thermal_debug.qcylinderwalltocoolant`},{str:$game.units.buildString(`energy`,data$1.energyCoolantToAir,0),name:`ui.apps.engine_thermal_debug.qcoolanttoair`},{str:$game.units.buildString(`energy`,data$1.energyCoolantToBlock,0),name:`ui.apps.engine_thermal_debug.qcoolanttoblock`},{str:$game.units.buildString(`energy`,data$1.energyCylinderWallToBlock,0),name:`ui.apps.engine_thermal_debug.qcylinderwalltoblock`},{str:$game.units.buildString(`energy`,data$1.energyBlockToAir,0),name:`ui.apps.engine_thermal_debug.qblocktoair`},{str:$game.units.buildString(`energy`,data$1.energyToOil,0),name:`ui.apps.engine_thermal_debug.qtooil`},{str:$game.units.buildString(`energy`,data$1.energyCylinderWallToOil,0),name:`ui.apps.engine_thermal_debug.qcylinderwalltooil`},{str:$game.units.buildString(`energy`,data$1.energyOilToAir,0),name:`ui.apps.engine_thermal_debug.qoilradiatortoair`},{str:$game.units.buildString(`energy`,data$1.energyOilSumpToAir,0),name:`ui.apps.engine_thermal_debug.qoilsumptoair`},{str:$game.units.buildString(`energy`,data$1.energyToExhaust,0),name:`ui.apps.engine_thermal_debug.qtoexhaust`},{str:$game.units.buildString(`energy`,data$1.energyExhaustToAir,0),name:`ui.apps.engine_thermal_debug.qexhausttoair`},{str:data$1.engineBlockOverheatDamage.toFixed(),name:`ui.apps.engine_thermal_debug.blockDamage`,warn:data$1.engineBlockOverheatDamage>0},{str:data$1.oilOverheatDamage.toFixed(),name:`ui.apps.engine_thermal_debug.oilDamage`,warn:data$1.oilOverheatDamage>0},{str:data$1.cylinderWallOverheatDamage.toFixed(),name:`ui.apps.engine_thermal_debug.cylinderwallDamage`,warn:data$1.cylinderWallOverheatDamage>0},{str:data$1.headGasketBlown,name:`ui.apps.engine_thermal_debug.headGasketBlown`,error:data$1.headGasketBlown},{str:data$1.pistonRingsDamaged,name:`ui.apps.engine_thermal_debug.pistonRingsDamaged`,error:data$1.pistonRingsDamaged},{str:data$1.connectingRodBearingsDamaged,name:`ui.apps.engine_thermal_debug.connectingRodBearingsDamaged`,error:data$1.connectingRodBearingsDamaged}]}return(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$172,[(openBlock(!0),createElementBlock(Fragment,null,renderList(data.value,(set,index)=>(openBlock(),createElementBlock(`div`,{key:index,class:`set`},[createBaseVNode(`div`,_hoisted_2$141,toDisplayString(_ctx.$t(set.name)),1),createBaseVNode(`div`,{class:normalizeClass([`set-value`,{"thermal-warning":set.warn,"thermal-error":set.error}])},toDisplayString(set.str),3)]))),128))]))}},app_default$19=__plugin_vue_export_helper_default(_sfc_main$192,[[`__scopeId`,`data-v-6de0b81a`]]),_hoisted_1$171={"xmlns:dc":`http://purl.org/dc/elements/1.1/`,"xmlns:cc":`http://creativecommons.org/ns#`,"xmlns:rdf":`http://www.w3.org/1999/02/22-rdf-syntax-ns#`,"xmlns:svg":`http://www.w3.org/2000/svg`,xmlns:`http://www.w3.org/2000/svg`,"xmlns:xlink":`http://www.w3.org/1999/xlink`,"xmlns:sodipodi":`http://sodipodi.sourceforge.net/DTD/sodipodi-0.dtd`,"xmlns:inkscape":`http://www.inkscape.org/namespaces/inkscape`,version:`1.1`,width:`100%`,height:`100%`,viewBox:`0 0 660 660`},_hoisted_2$140={"inkscape:groupmode":`layer`,id:`layer6`,class:`layer6`,"inkscape:label":`new`,style:{display:`inline`}},_hoisted_3$126={"xml:space":`preserve`,style:{"font-style":`normal`,"font-variant":`normal`,"font-weight":`normal`,"font-stretch":`normal`,"font-size":`159.64709473px`,"line-height":`125%`,"font-family":`'Squada One'`,"-inkscape-font-specification":`'Squada One'`,"text-align":`center`,"letter-spacing":`0px`,"word-spacing":`0px`,"writing-mode":`lr-tb`,"text-anchor":`middle`,display:`inline`,fill:`#ffffff`,"fill-opacity":`1`,stroke:`none`},x:`329.85437`,y:`328.48807`,id:`tspan4449-43`,"sodipodi:linespacing":`125%`,"inkscape:label":`#pressureText`},_hoisted_4$103={"xml:space":`preserve`,style:{"font-style":`normal`,"font-variant":`normal`,"font-weight":`normal`,"font-stretch":`normal`,"font-size":`65px`,"line-height":`125%`,"font-family":`'Squada One'`,"-inkscape-font-specification":`'Squada One'`,"text-align":`center`,"letter-spacing":`0px`,"word-spacing":`0px`,"writing-mode":`lr-tb`,"text-anchor":`middle`,display:`inline`,fill:`#ffffff`,"fill-opacity":`0.78835976`,stroke:`none`},x:`329.03198`,y:`413.62915`,id:`speed_units`,"sodipodi:linespacing":`125%`,"inkscape:label":`#speed_units`,"inkscape:transform-center-y":`-4.486084`},_hoisted_5$89=[`id`,`x`,`y`],_hoisted_6$74=[`id`,`x`,`y`],_hoisted_7$64={"inkscape:groupmode":`layer`,id:`layer3`,"inkscape:label":`FIX`,style:{display:`inline`}},_hoisted_8$51={id:`revcurvemask`,style:{display:`inline`}},_hoisted_9$45={"inkscape:groupmode":`layer`,id:`layer11`,"inkscape:label":`revs`,style:{display:`inline`}},_hoisted_10$38={"inkscape:groupmode":`layer`,id:`layer7`,"inkscape:label":`new2`,style:{display:`inline`}},width=660,height=660,dashSize=5,pressureTextSize=50,dashCount=5,PRESURE_MAX_CONST=150,PRESURE_MIN_CONST=-100,_sfc_main$191={__name:`forcedInduction`,setup(__props,{expose:__expose}){let initialized=ref(!1),pressureTextRef=ref(null),pressureCurveRef=ref(null),pressureCurveLen=computed(()=>pressureCurveRef.value.getTotalLength()),pressureCurveDashesRef=ref(null),pressureCurveDashesLen=computed(()=>pressureCurveDashesRef.value.getTotalLength()),redLineRef=ref(null),redLineLen=computed(()=>redLineRef.value.getTotalLength()),pressureTextGuideLineRef=ref(null),pressureTextGuideLineLen=computed(()=>pressureTextGuideLineRef.value.getTotalLength()),pressureTextRefs=ref([]),pressureTextAttrs=ref([{id:`pressuretext1`,x:197.49423,y:531.5639,text:1},{id:`pressuretext2`,x:124.71793,y:434.92328,text:2},{id:`pressuretext3`,x:110.04411,y:303.35791,text:3},{id:`pressuretext4`,x:165.89227,y:187.39682,text:4},{id:`pressuretext5`,x:284.48657,y:123.71478,text:5},{id:`pressuretext6`,x:419.43579,y:137.55835,text:6},{id:`pressuretext7`,x:520.0791,y:228.94992,text:7},{id:`pressuretext8`,x:520.0791,y:228.94992,text:8},{id:`pressuretext9`,x:520.0791,y:228.94992,text:9},{id:`pressuretext10`,x:520.0791,y:228.94992,text:10}]),pressureTSpanRefs=ref([]),pressureMax=ref(null),pressureMin=ref(null),pressureNeedleRef=ref(null),pressureUnitRef=ref(null),UiUnitscallback=ref(()=>null),roundDecCallback=ref(()=>0);onMounted(()=>{pressureTextRef.value.textContent=``,pressureCurveRef.value.style.strokeDasharray=pressureCurveLen.value+` `+pressureCurveLen.value,pressureTextGuideLineRef.value.style.display=`none`;for(let k=0;k10?0:1),rpSpan.style.visibility=`visible`}initialized.value=!0}applyData(streamData)}function reset$1(){initialized.value=!1;for(let k=0;k1&&(percPos=1),pressureNeedleRef.value.setAttribute(`transform`,`rotate(`+(percPos*270-135)+`,`+width/2+`,`+height/2+`)`),pressureCurveRef.value.style.strokeDashoffset=pressureCurveLen.value-pressureCurveLen.value*percPos}function UnitPressure(val){let convertedVal=UiUnitscallback.value(val,`pressure`);return pressureNeedleRef.value.textContent!==convertedVal.unit&&(pressureUnitRef.value.textContent=convertedVal.unit,initialized.value=!1),convertedVal.val}return(_ctx,_cache)=>(openBlock(),createElementBlock(`svg`,_hoisted_1$171,[_cache[4]||=createBaseVNode(`defs`,{id:`defs4`},[createBaseVNode(`linearGradient`,{id:`linearGradient3938`},[createBaseVNode(`stop`,{style:{"stop-color":`#ff0000`,"stop-opacity":`1`},offset:`0`,id:`stop3940`}),createBaseVNode(`stop`,{style:{"stop-color":`#00ff4b`,"stop-opacity":`1`},offset:`1`,id:`stop3942`})]),createBaseVNode(`linearGradient`,{id:`linearGradient4607`},[createBaseVNode(`stop`,{id:`stop4609`,offset:`0`,style:{"stop-color":`#e40000`,"stop-opacity":`1`}}),createBaseVNode(`stop`,{style:{"stop-color":`#e40000`,"stop-opacity":`1`},offset:`0.89960396`,id:`stop4611`}),createBaseVNode(`stop`,{id:`stop4613`,offset:`1`,style:{"stop-color":`#e40000`,"stop-opacity":`0`}}),createBaseVNode(`stop`,{id:`stop4615`,offset:`1`,style:{"stop-color":`#e40000`,"stop-opacity":`0`}})]),createBaseVNode(`linearGradient`,{id:`linearGradient4597`},[createBaseVNode(`stop`,{id:`stop4599`,offset:`0`,style:{"stop-color":`#e40000`,"stop-opacity":`1`}}),createBaseVNode(`stop`,{style:{"stop-color":`#e40000`,"stop-opacity":`1`},offset:`0.99812102`,id:`stop4601`}),createBaseVNode(`stop`,{id:`stop4603`,offset:`1`,style:{"stop-color":`#e40000`,"stop-opacity":`0`}}),createBaseVNode(`stop`,{id:`stop4605`,offset:`1`,style:{"stop-color":`#e40000`,"stop-opacity":`1`}})]),createBaseVNode(`linearGradient`,{id:`linearGradient4545`},[createBaseVNode(`stop`,{style:{"stop-color":`#e40000`,"stop-opacity":`1`},offset:`0`,id:`stop4547`}),createBaseVNode(`stop`,{id:`stop4553`,offset:`0.9861111`,style:{"stop-color":`#e40000`,"stop-opacity":`1`}}),createBaseVNode(`stop`,{style:{"stop-color":`#e40000`,"stop-opacity":`0`},offset:`1`,id:`stop4555`}),createBaseVNode(`stop`,{style:{"stop-color":`#e40000`,"stop-opacity":`0`},offset:`1`,id:`stop4549`})]),createBaseVNode(`linearGradient`,{"inkscape:collect":`always`,id:`linearGradient4256`},[createBaseVNode(`stop`,{style:{"stop-color":`#6d0000`,"stop-opacity":`1`},offset:`0`,id:`stop4258`}),createBaseVNode(`stop`,{style:{"stop-color":`#6d0000`,"stop-opacity":`0`},offset:`1`,id:`stop4260`})]),createBaseVNode(`linearGradient`,{id:`linearGradient4365`},[createBaseVNode(`stop`,{style:{"stop-color":`#000000`,"stop-opacity":`0.42857143`},offset:`0`,id:`stop4367`}),createBaseVNode(`stop`,{id:`stop4373`,offset:`0.5`,style:{"stop-color":`#000000`,"stop-opacity":`0.33035713`}}),createBaseVNode(`stop`,{style:{"stop-color":`#000000`,"stop-opacity":`0`},offset:`1`,id:`stop4369`})]),createBaseVNode(`linearGradient`,{id:`linearGradient4357`},[createBaseVNode(`stop`,{style:{"stop-color":`#000000`,"stop-opacity":`1`},offset:`0`,id:`stop4359`}),createBaseVNode(`stop`,{style:{"stop-color":`#000000`,"stop-opacity":`0.19642857`},offset:`1`,id:`stop4361`})]),createBaseVNode(`marker`,{style:{overflow:`visible`},id:`DistanceStart`,refX:`0`,refY:`0`,orient:`auto`,"inkscape:stockid":`DistanceStart`},[createBaseVNode(`g`,{id:`g2300`},[createBaseVNode(`path`,{style:{fill:`none`,stroke:`#ffffff`,"stroke-width":`1.14999998`,"stroke-linecap":`square`},d:`M 0,0 2,0`,id:`path2306`,"inkscape:connector-curvature":`0`}),createBaseVNode(`path`,{style:{fill:`#000000`,"fill-rule":`evenodd`,stroke:`none`},d:`M 0,0 13,4 9,0 13,-4 0,0 z`,id:`path2302`,"inkscape:connector-curvature":`0`}),createBaseVNode(`path`,{style:{fill:`none`,stroke:`#000000`,"stroke-width":`1`,"stroke-linecap":`square`},d:`M 0,-4 0,40`,id:`path2304`,"inkscape:connector-curvature":`0`})])]),createBaseVNode(`radialGradient`,{"inkscape:collect":`always`,"xlink:href":`#linearGradient4357`,id:`radialGradient4363`,cx:`480`,cy:`544`,fx:`480`,fy:`544`,r:`320`,gradientUnits:`userSpaceOnUse`,gradientTransform:`matrix(1.03125,0,0,1.03125,-15,-17)`}),createBaseVNode(`radialGradient`,{"inkscape:collect":`always`,"xlink:href":`#linearGradient4365`,id:`radialGradient4371`,cx:`480`,cy:`544`,fx:`480`,fy:`544`,r:`320`,gradientUnits:`userSpaceOnUse`}),createBaseVNode(`clipPath`,{clipPathUnits:`userSpaceOnUse`,id:`clipPath4407`},[createBaseVNode(`path`,{"inkscape:connector-curvature":`0`,id:`path4409`,d:`m 480,-103.33 c -357.5105,0 -647.33,289.8195 -647.33,647.33 0,357.5105 289.8195,647.33 647.33,647.33 357.5105,0 647.33,-289.8195 647.33,-647.33 0,-357.5105 -289.8195,-647.33 -647.33,-647.33 z m 0,453.131 c 107.25316,0 194.199,86.94584 194.199,194.199 0,107.25316 -86.94584,194.199 -194.199,194.199 -107.25316,0 -194.199,-86.94584 -194.199,-194.199 0,-107.25316 86.94584,-194.199 194.199,-194.199 z`,style:{color:`#000000`,fill:`#ffffff`,"fill-opacity":`0.61375661`,"fill-rule":`nonzero`,stroke:`none`,"stroke-width":`16`,marker:`none`,visibility:`visible`,display:`inline`,overflow:`visible`,"enable-background":`accumulate`}})]),createBaseVNode(`clipPath`,{clipPathUnits:`userSpaceOnUse`,id:`clipPath4321-9`},[createBaseVNode(`path`,{style:{color:`#000000`,fill:`#ffffff`,"fill-opacity":`1`,"fill-rule":`nonzero`,stroke:`none`,"stroke-width":`5`,marker:`none`,visibility:`visible`,display:`inline`,overflow:`visible`,"enable-background":`accumulate`},d:`m 480,224 c -20.28024,0 -40.11069,1.89279 -59.34375,5.5 l 12.0625,58.8125 C 448.05208,285.49499 463.85489,284 480,284 c 35.52728,0 69.40254,7.13112 100.25,20.03125 l 24.1875,-54.9375 C 566.18747,232.93508 524.13347,224 480,224 z m -69.0625,7.5 c -59.26533,13.0371 -112.35258,42.49901 -154.28125,83.375 l 42.53125,42.3125 c 24.37935,-23.60266 53.35266,-42.49216 85.46875,-55.15625 1.96795,-0.77601 3.94641,-1.52096 5.9375,-2.25 10.51172,-3.84886 21.33856,-7.01901 32.4375,-9.5 L 410.9375,231.5 z M 613.5,253.125 589.3125,308.03125 c 44.07702,20.45389 81.43119,52.91567 107.9375,93.15625 l 50.875,-31.875 C 715.25578,318.96815 668.59379,278.45303 613.5,253.125 z m -363.8125,68.75 c -41.23795,42.75016 -70.70543,96.92973 -83.125,157.34375 l 59.03125,11.0625 c 10.15322,-48.33557 33.70357,-91.7229 66.625,-126.09375 L 249.6875,321.875 z m 503.78125,55.8125 -50.90625,31.84375 C 726.31882,448.76688 740,494.78478 740,544 l 60,0 c 0,-60.90677 -16.99384,-117.84887 -46.53125,-166.3125 z m -588.75,111.25 C 161.61652,506.82573 160,525.2248 160,544 c 0,42.78463 8.42108,83.60181 23.65625,120.90625 L 238.84375,641.375 C 226.69144,611.30216 220,578.42944 220,544 c 0,-2.24366 0.0373,-4.48871 0.0937,-6.71875 0.3211,-12.67426 1.55282,-25.12039 3.625,-37.28125 l -59,-11.0625 z M 242.75,650.5 187.53125,674 c 23.4008,52.56805 60.5346,97.67196 106.875,130.71875 l 34.0625,-49.4375 C 291.42063,728.66516 261.6562,692.55546 242.75,650.5 z m 93.875,110.40625 -34.03125,49.40625 C 353.37348,844.20872 414.36502,864 480,864 l 0,-60 c -33.65485,0 -65.82451,-6.39115 -95.34375,-18.03125 -1.96795,-0.77601 -3.93088,-1.58396 -5.875,-2.40625 -14.80462,-6.26183 -28.90394,-13.88046 -42.15625,-22.65625 z`,id:`path4323-8`,"inkscape:connector-curvature":`0`})]),createBaseVNode(`radialGradient`,{"inkscape:collect":`always`,"xlink:href":`#linearGradient4357`,id:`radialGradient4363-9`,cx:`480`,cy:`544`,fx:`480`,fy:`544`,r:`320`,gradientUnits:`userSpaceOnUse`,gradientTransform:`matrix(1.03125,0,0,1.03125,-15,-17)`}),createBaseVNode(`clipPath`,{clipPathUnits:`userSpaceOnUse`,id:`clipPath4407-3`},[createBaseVNode(`path`,{"inkscape:connector-curvature":`0`,id:`path4409-5`,d:`m 480,-103.33 c -357.5105,0 -647.33,289.8195 -647.33,647.33 0,357.5105 289.8195,647.33 647.33,647.33 357.5105,0 647.33,-289.8195 647.33,-647.33 0,-357.5105 -289.8195,-647.33 -647.33,-647.33 z m 0,453.131 c 107.25316,0 194.199,86.94584 194.199,194.199 0,107.25316 -86.94584,194.199 -194.199,194.199 -107.25316,0 -194.199,-86.94584 -194.199,-194.199 0,-107.25316 86.94584,-194.199 194.199,-194.199 z`,style:{color:`#000000`,fill:`#ffffff`,"fill-opacity":`0.61375661`,"fill-rule":`nonzero`,stroke:`none`,"stroke-width":`16`,marker:`none`,visibility:`visible`,display:`inline`,overflow:`visible`,"enable-background":`accumulate`}})]),createBaseVNode(`radialGradient`,{gradientTransform:`matrix(0.37015162,0,0,0.37015162,685.90181,-270.76027)`,"inkscape:collect":`always`,"xlink:href":`#linearGradient4365`,id:`radialGradient4371-4`,cx:`480`,cy:`544`,fx:`480`,fy:`544`,r:`320`,gradientUnits:`userSpaceOnUse`}),createBaseVNode(`linearGradient`,{"inkscape:collect":`always`,"xlink:href":`#linearGradient4256`,id:`linearGradient4433`,gradientUnits:`userSpaceOnUse`,x1:`569.20557`,y1:`424.29861`,x2:`890.55139`,y2:`424.29861`}),createBaseVNode(`clipPath`,{clipPathUnits:`userSpaceOnUse`,id:`clipPath4321-4`},[createBaseVNode(`path`,{style:{color:`#000000`,fill:`#ffffff`,"fill-opacity":`1`,"fill-rule":`nonzero`,stroke:`none`,"stroke-width":`5`,marker:`none`,visibility:`visible`,display:`inline`,overflow:`visible`,"enable-background":`accumulate`},d:`m 480,224 c -20.28024,0 -40.11069,1.89279 -59.34375,5.5 l 12.0625,58.8125 C 448.05208,285.49499 463.85489,284 480,284 c 35.52728,0 69.40254,7.13112 100.25,20.03125 l 24.1875,-54.9375 C 566.18747,232.93508 524.13347,224 480,224 z m -69.0625,7.5 c -59.26533,13.0371 -112.35258,42.49901 -154.28125,83.375 l 42.53125,42.3125 c 24.37935,-23.60266 53.35266,-42.49216 85.46875,-55.15625 1.96795,-0.77601 3.94641,-1.52096 5.9375,-2.25 10.51172,-3.84886 21.33856,-7.01901 32.4375,-9.5 L 410.9375,231.5 z M 613.5,253.125 589.3125,308.03125 c 44.07702,20.45389 81.43119,52.91567 107.9375,93.15625 l 50.875,-31.875 C 715.25578,318.96815 668.59379,278.45303 613.5,253.125 z m -363.8125,68.75 c -41.23795,42.75016 -70.70543,96.92973 -83.125,157.34375 l 59.03125,11.0625 c 10.15322,-48.33557 33.70357,-91.7229 66.625,-126.09375 L 249.6875,321.875 z m 503.78125,55.8125 -50.90625,31.84375 C 726.31882,448.76688 740,494.78478 740,544 l 60,0 c 0,-60.90677 -16.99384,-117.84887 -46.53125,-166.3125 z m -588.75,111.25 C 161.61652,506.82573 160,525.2248 160,544 c 0,42.78463 8.42108,83.60181 23.65625,120.90625 L 238.84375,641.375 C 226.69144,611.30216 220,578.42944 220,544 c 0,-2.24366 0.0373,-4.48871 0.0937,-6.71875 0.3211,-12.67426 1.55282,-25.12039 3.625,-37.28125 l -59,-11.0625 z M 242.75,650.5 187.53125,674 c 23.4008,52.56805 60.5346,97.67196 106.875,130.71875 l 34.0625,-49.4375 C 291.42063,728.66516 261.6562,692.55546 242.75,650.5 z m 93.875,110.40625 -34.03125,49.40625 C 353.37348,844.20872 414.36502,864 480,864 l 0,-60 c -33.65485,0 -65.82451,-6.39115 -95.34375,-18.03125 -1.96795,-0.77601 -3.93088,-1.58396 -5.875,-2.40625 -14.80462,-6.26183 -28.90394,-13.88046 -42.15625,-22.65625 z`,id:`path4323-7`,"inkscape:connector-curvature":`0`})]),createBaseVNode(`radialGradient`,{"inkscape:collect":`always`,"xlink:href":`#linearGradient4357`,id:`radialGradient4363-5`,cx:`480`,cy:`544`,fx:`480`,fy:`544`,r:`320`,gradientUnits:`userSpaceOnUse`,gradientTransform:`matrix(1.03125,0,0,1.03125,-15,-17)`}),createBaseVNode(`clipPath`,{clipPathUnits:`userSpaceOnUse`,id:`clipPath4407-6`},[createBaseVNode(`path`,{"inkscape:connector-curvature":`0`,id:`path4409-1`,d:`m 480,-103.33 c -357.5105,0 -647.33,289.8195 -647.33,647.33 0,357.5105 289.8195,647.33 647.33,647.33 357.5105,0 647.33,-289.8195 647.33,-647.33 0,-357.5105 -289.8195,-647.33 -647.33,-647.33 z m 0,453.131 c 107.25316,0 194.199,86.94584 194.199,194.199 0,107.25316 -86.94584,194.199 -194.199,194.199 -107.25316,0 -194.199,-86.94584 -194.199,-194.199 0,-107.25316 86.94584,-194.199 194.199,-194.199 z`,style:{color:`#000000`,fill:`#ffffff`,"fill-opacity":`0.61375661`,"fill-rule":`nonzero`,stroke:`none`,"stroke-width":`16`,marker:`none`,visibility:`visible`,display:`inline`,overflow:`visible`,"enable-background":`accumulate`}})]),createBaseVNode(`radialGradient`,{gradientTransform:`matrix(0.36968813,0,0,0.36968813,1026.9451,-270.68256)`,"inkscape:collect":`always`,"xlink:href":`#linearGradient4365`,id:`radialGradient4371-49`,cx:`480`,cy:`544`,fx:`480`,fy:`544`,r:`320`,gradientUnits:`userSpaceOnUse`}),createBaseVNode(`linearGradient`,{"inkscape:collect":`always`,"xlink:href":`#linearGradient4256`,id:`linearGradient4746`,gradientUnits:`userSpaceOnUse`,x1:`569.20557`,y1:`424.29861`,x2:`890.55139`,y2:`424.29861`}),createBaseVNode(`clipPath`,{clipPathUnits:`userSpaceOnUse`,id:`clipPath3921`},[createBaseVNode(`path`,{"inkscape:connector-curvature":`0`,id:`path3923`,d:`m 480,224 c -20.95323,0 -41.43416,2.01857 -61.26367,5.86328 l 12.08008,58.80274 C 446.74495,285.61583 463.18224,284 480,284 c 36.22419,0 70.7135,7.41519 102.04492,20.79883 l 24.1836,-54.92188 C 567.49749,233.23259 524.82925,224 480,224 z m -67.13867,7.07812 c -60.69914,12.96113 -115.01734,43.12659 -157.60938,85.15821 l 42.54297,42.3125 c 34.42536,-33.82645 78.22177,-58.13556 127.14258,-68.68555 l -12.07617,-58.78516 z m 198.86328,21.20508 -24.1875,54.9336 c 45.44422,20.67199 83.88358,54.04459 110.80078,95.58008 l 50.87305,-31.84376 C 715.93577,319.29347 668.20331,277.82636 611.72461,252.2832 z m -360.70117,68.21094 c -42.37565,43.40627 -72.5223,98.80082 -84.8418,160.63281 l 58.99024,11.05664 c 10.06229,-49.7524 34.33605,-94.34359 68.39257,-129.3789 l -42.54101,-42.31055 z m 501.3789,55.54102 -50.86132,31.83398 C 725.92383,447.46544 740,494.08649 740,544 l 60,0 C 800,482.39079 782.57195,424.85952 752.40234,376.03516 z M 165.06055,487.02148 C 161.7373,505.51211 160,524.55271 160,544 c 0,43.47625 8.68492,84.91949 24.39062,122.71094 l 55.21485,-23.5293 C 226.98058,612.61583 220,579.12541 220,544 c 0,-15.6701 1.38639,-31.01527 4.04297,-45.92188 l -58.98242,-11.05664 z m 76.90039,161.67774 -55.20899,23.52734 c 23.61428,53.92719 61.65397,100.09134 109.25586,133.60352 l 34.03516,-49.41406 C 291.73258,729.3212 261.08736,692.12046 241.96094,648.69922 z m 93.01953,111.12695 -34.04102,49.42188 C 352.04051,843.81227 413.66249,864 480,864 l 0,-60 c -53.69777,0 -103.59151,-16.28243 -145.01953,-44.17383 z`,style:{color:`#000000`,fill:`#ffffff`,"fill-opacity":`1`,"fill-rule":`nonzero`,stroke:`none`,"stroke-width":`5`,marker:`none`,visibility:`visible`,display:`inline`,overflow:`visible`,"enable-background":`accumulate`}})]),createBaseVNode(`clipPath`,{clipPathUnits:`userSpaceOnUse`,id:`clipPath3925-1`},[createBaseVNode(`path`,{"inkscape:connector-curvature":`0`,id:`path3927-7`,d:`m 330,10 c -20.95323,0 -41.43416,2.01857 -61.26367,5.86328 l 12.08008,58.80274 C 296.74495,71.61583 313.18224,70 330,70 c 36.22419,0 70.7135,7.41519 102.04492,20.79883 l 24.1836,-54.92188 C 417.49749,19.23259 374.82925,10 330,10 z m -67.13867,7.07812 C 202.16219,30.03925 147.84399,60.20471 105.25195,102.23633 l 42.54297,42.3125 C 182.22028,110.72238 226.01669,86.41327 274.9375,75.86328 L 262.86133,17.07812 z m 198.86328,21.20508 -24.1875,54.9336 c 45.44422,20.67199 83.88358,54.04459 110.80078,95.58008 l 50.87305,-31.84376 C 565.93577,105.29347 518.20331,63.82636 461.72461,38.2832 z m -360.70117,68.21094 c -42.37565,43.40627 -72.5223,98.80082 -84.8418,160.63281 l 58.99024,11.05664 c 10.06229,-49.7524 34.33605,-94.34359 68.39257,-129.3789 l -42.54101,-42.31055 z m 501.3789,55.54102 -50.86132,31.83398 C 575.92383,233.46544 590,280.08649 590,330 l 60,0 C 650,268.39079 632.57195,210.85952 602.40234,162.03516 z M 15.06055,273.02148 C 11.7373,291.51211 10,310.55271 10,330 c 0,43.47625 8.68492,84.91949 24.39062,122.71094 l 55.21485,-23.5293 C 76.98058,398.61583 70,365.12541 70,330 c 0,-15.6701 1.38639,-31.01527 4.04297,-45.92188 L 15.06055,273.02148 z m 76.90039,161.67774 -55.20899,23.52734 c 23.61428,53.92719 61.65397,100.09134 109.25586,133.60352 l 34.03516,-49.41406 C 141.73258,515.3212 111.08736,478.12046 91.96094,434.69922 z m 93.01953,111.12695 -34.04102,49.42188 C 202.04051,629.81227 263.66249,650 330,650 l 0,-60 c -53.69777,0 -103.59151,-16.28243 -145.01953,-44.17383 z`,style:{color:`#000000`,fill:`#ffffff`,"fill-opacity":`1`,"fill-rule":`nonzero`,stroke:`none`,"stroke-width":`5`,marker:`none`,visibility:`visible`,display:`inline`,overflow:`visible`,"enable-background":`accumulate`}})]),createBaseVNode(`clipPath`,{clipPathUnits:`userSpaceOnUse`,id:`clipPath4036`},[createBaseVNode(`path`,{style:{color:`#000000`,fill:`#ffffff`,"fill-opacity":`1`,"fill-rule":`nonzero`,stroke:`none`,"stroke-width":`5`,marker:`none`,visibility:`visible`,display:`inline`,overflow:`visible`,"enable-background":`accumulate`},d:`m 480,224 c -20.95323,0 -41.43416,2.01857 -61.26367,5.86328 l 12.08008,58.80274 C 446.74495,285.61583 463.18224,284 480,284 c 36.22419,0 70.7135,7.41519 102.04492,20.79883 l 24.1836,-54.92188 C 567.49749,233.23259 524.82925,224 480,224 z m -67.13867,7.07812 c -60.69914,12.96113 -115.01734,43.12659 -157.60938,85.15821 l 42.54297,42.3125 c 34.42536,-33.82645 78.22177,-58.13556 127.14258,-68.68555 l -12.07617,-58.78516 z m 198.86328,21.20508 -24.1875,54.9336 c 45.44422,20.67199 83.88358,54.04459 110.80078,95.58008 l 50.87305,-31.84376 C 715.93577,319.29347 668.20331,277.82636 611.72461,252.2832 z m -360.70117,68.21094 c -42.37565,43.40627 -72.5223,98.80082 -84.8418,160.63281 l 58.99024,11.05664 c 10.06229,-49.7524 34.33605,-94.34359 68.39257,-129.3789 l -42.54101,-42.31055 z m 501.3789,55.54102 -50.86132,31.83398 C 725.92383,447.46544 740,494.08649 740,544 l 60,0 C 800,482.39079 782.57195,424.85952 752.40234,376.03516 z M 165.06055,487.02148 C 161.7373,505.51211 160,524.55271 160,544 c 0,43.47625 8.68492,84.91949 24.39062,122.71094 l 55.21485,-23.5293 C 226.98058,612.61583 220,579.12541 220,544 c 0,-15.6701 1.38639,-31.01527 4.04297,-45.92188 l -58.98242,-11.05664 z m 76.90039,161.67774 -55.20899,23.52734 c 23.61428,53.92719 61.65397,100.09134 109.25586,133.60352 l 34.03516,-49.41406 C 291.73258,729.3212 261.08736,692.12046 241.96094,648.69922 z m 93.01953,111.12695 -34.04102,49.42188 C 352.04051,843.81227 413.66249,864 480,864 l 0,-60 c -53.69777,0 -103.59151,-16.28243 -145.01953,-44.17383 z`,id:`path4038`,"inkscape:connector-curvature":`0`})]),createBaseVNode(`linearGradient`,{"inkscape:collect":`always`,"xlink:href":`#linearGradient4545`,id:`linearGradient4551`,x1:`480`,y1:`214`,x2:`480`,y2:`474`,gradientUnits:`userSpaceOnUse`}),createBaseVNode(`linearGradient`,{"inkscape:collect":`always`,"xlink:href":`#linearGradient4545-2`,id:`linearGradient4551-8`,x1:`480`,y1:`214`,x2:`480`,y2:`474`,gradientUnits:`userSpaceOnUse`}),createBaseVNode(`linearGradient`,{id:`linearGradient4545-2`},[createBaseVNode(`stop`,{style:{"stop-color":`#e40000`,"stop-opacity":`1`},offset:`0`,id:`stop4547-4`}),createBaseVNode(`stop`,{id:`stop4553-5`,offset:`0.99000001`,style:{"stop-color":`#e40000`,"stop-opacity":`0`}}),createBaseVNode(`stop`,{style:{"stop-color":`#000000`,"stop-opacity":`0`},offset:`1`,id:`stop4555-5`}),createBaseVNode(`stop`,{style:{"stop-color":`#000000`,"stop-opacity":`0`},offset:`1`,id:`stop4549-1`})]),createBaseVNode(`linearGradient`,{y2:`282.59341`,x2:`474.60886`,y1:`211.1199`,x1:`480`,gradientUnits:`userSpaceOnUse`,id:`linearGradient4574`,"xlink:href":`#linearGradient4607`,"inkscape:collect":`always`,gradientTransform:`matrix(1,0,0,0.9882541,0,10.359887)`}),createBaseVNode(`clipPath`,{clipPathUnits:`userSpaceOnUse`,id:`clipPath4036-1`},[createBaseVNode(`path`,{style:{color:`#000000`,fill:`#ffffff`,"fill-opacity":`1`,"fill-rule":`nonzero`,stroke:`none`,"stroke-width":`5`,marker:`none`,visibility:`visible`,display:`inline`,overflow:`visible`,"enable-background":`accumulate`},d:`m 480,224 c -20.95323,0 -41.43416,2.01857 -61.26367,5.86328 l 12.08008,58.80274 C 446.74495,285.61583 463.18224,284 480,284 c 36.22419,0 70.7135,7.41519 102.04492,20.79883 l 24.1836,-54.92188 C 567.49749,233.23259 524.82925,224 480,224 z m -67.13867,7.07812 c -60.69914,12.96113 -115.01734,43.12659 -157.60938,85.15821 l 42.54297,42.3125 c 34.42536,-33.82645 78.22177,-58.13556 127.14258,-68.68555 l -12.07617,-58.78516 z m 198.86328,21.20508 -24.1875,54.9336 c 45.44422,20.67199 83.88358,54.04459 110.80078,95.58008 l 50.87305,-31.84376 C 715.93577,319.29347 668.20331,277.82636 611.72461,252.2832 z m -360.70117,68.21094 c -42.37565,43.40627 -72.5223,98.80082 -84.8418,160.63281 l 58.99024,11.05664 c 10.06229,-49.7524 34.33605,-94.34359 68.39257,-129.3789 l -42.54101,-42.31055 z m 501.3789,55.54102 -50.86132,31.83398 C 725.92383,447.46544 740,494.08649 740,544 l 60,0 C 800,482.39079 782.57195,424.85952 752.40234,376.03516 z M 165.06055,487.02148 C 161.7373,505.51211 160,524.55271 160,544 c 0,43.47625 8.68492,84.91949 24.39062,122.71094 l 55.21485,-23.5293 C 226.98058,612.61583 220,579.12541 220,544 c 0,-15.6701 1.38639,-31.01527 4.04297,-45.92188 l -58.98242,-11.05664 z m 76.90039,161.67774 -55.20899,23.52734 c 23.61428,53.92719 61.65397,100.09134 109.25586,133.60352 l 34.03516,-49.41406 C 291.73258,729.3212 261.08736,692.12046 241.96094,648.69922 z m 93.01953,111.12695 -34.04102,49.42188 C 352.04051,843.81227 413.66249,864 480,864 l 0,-60 c -53.69777,0 -103.59151,-16.28243 -145.01953,-44.17383 z`,id:`path4038-7`,"inkscape:connector-curvature":`0`})]),createBaseVNode(`radialGradient`,{"inkscape:collect":`always`,"xlink:href":`#linearGradient4357-0`,id:`radialGradient4363-4`,cx:`480`,cy:`544`,fx:`480`,fy:`544`,r:`320`,gradientUnits:`userSpaceOnUse`,gradientTransform:`matrix(1.03125,0,0,1.03125,-15,-17)`}),createBaseVNode(`linearGradient`,{id:`linearGradient4357-0`},[createBaseVNode(`stop`,{style:{"stop-color":`#000000`,"stop-opacity":`0.65178573`},offset:`0`,id:`stop4359-9`}),createBaseVNode(`stop`,{style:{"stop-color":`#000000`,"stop-opacity":`0.24107143`},offset:`1`,id:`stop4361-4`})]),createBaseVNode(`radialGradient`,{"inkscape:collect":`always`,"xlink:href":`#linearGradient4365-4`,id:`radialGradient4371-2`,cx:`480`,cy:`544`,fx:`480`,fy:`544`,r:`320`,gradientUnits:`userSpaceOnUse`}),createBaseVNode(`linearGradient`,{id:`linearGradient4365-4`},[createBaseVNode(`stop`,{style:{"stop-color":`#000000`,"stop-opacity":`0.42857143`},offset:`0`,id:`stop4367-5`}),createBaseVNode(`stop`,{id:`stop4373-5`,offset:`0.5`,style:{"stop-color":`#000000`,"stop-opacity":`0.33035713`}}),createBaseVNode(`stop`,{style:{"stop-color":`#000000`,"stop-opacity":`0`},offset:`1`,id:`stop4369-1`})]),createBaseVNode(`radialGradient`,{r:`320`,fy:`544`,fx:`480`,cy:`544`,cx:`480`,gradientUnits:`userSpaceOnUse`,id:`radialGradient3997`,"xlink:href":`#linearGradient4365-4`,"inkscape:collect":`always`}),createBaseVNode(`radialGradient`,{"inkscape:collect":`always`,"xlink:href":`#linearGradient4357-0-7`,id:`radialGradient4363-4-1`,cx:`480`,cy:`544`,fx:`480`,fy:`544`,r:`320`,gradientUnits:`userSpaceOnUse`,gradientTransform:`matrix(1.03125,0,0,1.03125,-15,-17)`}),createBaseVNode(`linearGradient`,{id:`linearGradient4357-0-7`},[createBaseVNode(`stop`,{style:{"stop-color":`#000000`,"stop-opacity":`0.51785713`},offset:`0`,id:`stop4359-9-4`}),createBaseVNode(`stop`,{style:{"stop-color":`#000000`,"stop-opacity":`0.11607143`},offset:`1`,id:`stop4361-4-0`})]),createBaseVNode(`radialGradient`,{r:`320`,fy:`544`,fx:`480`,cy:`544`,cx:`480`,gradientTransform:`matrix(1.03125,0,0,1.03125,-15,-17)`,gradientUnits:`userSpaceOnUse`,id:`radialGradient4001`,"xlink:href":`#linearGradient4357-0-7`,"inkscape:collect":`always`}),createBaseVNode(`radialGradient`,{"inkscape:collect":`always`,"xlink:href":`#linearGradient4357-0-7`,id:`radialGradient4040`,gradientUnits:`userSpaceOnUse`,gradientTransform:`matrix(1.03125,0,0,1.03125,-885,-231)`,cx:`480`,cy:`544`,fx:`480`,fy:`544`,r:`320`}),createBaseVNode(`radialGradient`,{"inkscape:collect":`always`,"xlink:href":`#linearGradient4357-0-7`,id:`radialGradient4045`,gradientUnits:`userSpaceOnUse`,gradientTransform:`matrix(1.03125,0,0,1.03125,-885,-231)`,cx:`480`,cy:`544`,fx:`480`,fy:`544`,r:`320`}),createBaseVNode(`radialGradient`,{"inkscape:collect":`always`,"xlink:href":`#linearGradient4357-0-7-2`,id:`radialGradient4045-8`,gradientUnits:`userSpaceOnUse`,gradientTransform:`matrix(1.03125,0,0,1.03125,-885,-231)`,cx:`480`,cy:`544`,fx:`480`,fy:`544`,r:`320`}),createBaseVNode(`linearGradient`,{id:`linearGradient4357-0-7-2`},[createBaseVNode(`stop`,{style:{"stop-color":`#000000`,"stop-opacity":`0.51785713`},offset:`0`,id:`stop4359-9-4-4`}),createBaseVNode(`stop`,{style:{"stop-color":`#000000`,"stop-opacity":`0.11607143`},offset:`1`,id:`stop4361-4-0-5`})]),createBaseVNode(`radialGradient`,{r:`320`,fy:`544`,fx:`480`,cy:`544`,cx:`480`,gradientTransform:`matrix(1.03125,0,0,1.03125,-758.53125,-231)`,gradientUnits:`userSpaceOnUse`,id:`radialGradient4063`,"xlink:href":`#linearGradient4357-0-7-2`,"inkscape:collect":`always`}),createBaseVNode(`radialGradient`,{"inkscape:collect":`always`,"xlink:href":`#linearGradient4357-0-7`,id:`radialGradient4082`,gradientUnits:`userSpaceOnUse`,gradientTransform:`matrix(1.03125,0,0,1.03125,-885,-231)`,cx:`480`,cy:`544`,fx:`480`,fy:`544`,r:`320`}),createBaseVNode(`radialGradient`,{"inkscape:collect":`always`,"xlink:href":`#linearGradient4357-0-8`,id:`radialGradient4363-4-9`,cx:`480`,cy:`544`,fx:`480`,fy:`544`,r:`320`,gradientUnits:`userSpaceOnUse`,gradientTransform:`matrix(1.03125,0,0,1.03125,-15,-17)`}),createBaseVNode(`linearGradient`,{id:`linearGradient4357-0-8`},[createBaseVNode(`stop`,{style:{"stop-color":`#000000`,"stop-opacity":`0.51785713`},offset:`0`,id:`stop4359-9-40`}),createBaseVNode(`stop`,{style:{"stop-color":`#000000`,"stop-opacity":`0.11607143`},offset:`1`,id:`stop4361-4-7`})]),createBaseVNode(`radialGradient`,{r:`320`,fy:`544`,fx:`480`,cy:`544`,cx:`480`,gradientTransform:`matrix(1.03125,0,0,1.03125,-15,-17)`,gradientUnits:`userSpaceOnUse`,id:`radialGradient4031-1`,"xlink:href":`#linearGradient4357-0-8-5`,"inkscape:collect":`always`}),createBaseVNode(`linearGradient`,{id:`linearGradient4357-0-8-5`},[createBaseVNode(`stop`,{style:{"stop-color":`#000000`,"stop-opacity":`0.51785713`},offset:`0`,id:`stop4359-9-40-4`}),createBaseVNode(`stop`,{style:{"stop-color":`#000000`,"stop-opacity":`0.11607143`},offset:`1`,id:`stop4361-4-7-2`})]),createBaseVNode(`radialGradient`,{"inkscape:collect":`always`,"xlink:href":`#linearGradient4357-0-3`,id:`radialGradient4363-4-0`,cx:`480`,cy:`544`,fx:`480`,fy:`544`,r:`320`,gradientUnits:`userSpaceOnUse`,gradientTransform:`matrix(1.03125,0,0,1.03125,-15,-17)`}),createBaseVNode(`linearGradient`,{id:`linearGradient4357-0-3`},[createBaseVNode(`stop`,{style:{"stop-color":`#000000`,"stop-opacity":`0.65178573`},offset:`0`,id:`stop4359-9-8`}),createBaseVNode(`stop`,{style:{"stop-color":`#000000`,"stop-opacity":`0.24107143`},offset:`1`,id:`stop4361-4-01`})]),createBaseVNode(`clipPath`,{clipPathUnits:`userSpaceOnUse`,id:`clipPath4407-8-2`},[createBaseVNode(`path`,{"inkscape:connector-curvature":`0`,id:`path4409-8-5`,d:`m 480,-103.33 c -357.5105,0 -647.33,289.8195 -647.33,647.33 0,357.5105 289.8195,647.33 647.33,647.33 357.5105,0 647.33,-289.8195 647.33,-647.33 0,-357.5105 -289.8195,-647.33 -647.33,-647.33 z m 0,453.131 c 107.25316,0 194.199,86.94584 194.199,194.199 0,107.25316 -86.94584,194.199 -194.199,194.199 -107.25316,0 -194.199,-86.94584 -194.199,-194.199 0,-107.25316 86.94584,-194.199 194.199,-194.199 z`,style:{color:`#000000`,fill:`#ffffff`,"fill-opacity":`0.61375661`,"fill-rule":`nonzero`,stroke:`none`,"stroke-width":`16`,marker:`none`,visibility:`visible`,display:`inline`,overflow:`visible`,"enable-background":`accumulate`}})]),createBaseVNode(`radialGradient`,{r:`320`,fy:`544`,fx:`480`,cy:`544`,cx:`480`,gradientTransform:`matrix(1.03125,0,0,1.03125,-15,-17)`,gradientUnits:`userSpaceOnUse`,id:`radialGradient4401`,"xlink:href":`#linearGradient4357-0-3`,"inkscape:collect":`always`}),createBaseVNode(`radialGradient`,{r:`320`,fy:`544`,fx:`480`,cy:`544`,cx:`480`,gradientUnits:`userSpaceOnUse`,id:`radialGradient3997-4`,"xlink:href":`#linearGradient4365-4-7`,"inkscape:collect":`always`}),createBaseVNode(`linearGradient`,{id:`linearGradient4365-4-7`},[createBaseVNode(`stop`,{style:{"stop-color":`#000000`,"stop-opacity":`0.42857143`},offset:`0`,id:`stop4367-5-8`}),createBaseVNode(`stop`,{id:`stop4373-5-3`,offset:`0.5`,style:{"stop-color":`#000000`,"stop-opacity":`0.33035713`}}),createBaseVNode(`stop`,{style:{"stop-color":`#000000`,"stop-opacity":`0`},offset:`1`,id:`stop4369-1-5`})]),createBaseVNode(`radialGradient`,{r:`320`,fy:`544`,fx:`480`,cy:`544`,cx:`480`,gradientUnits:`userSpaceOnUse`,id:`radialGradient4458`,"xlink:href":`#linearGradient4365-4-7`,"inkscape:collect":`always`}),createBaseVNode(`clipPath`,{clipPathUnits:`userSpaceOnUse`,id:`clipPath3653`},[createBaseVNode(`path`,{style:{color:`#000000`,display:`inline`,overflow:`visible`,visibility:`visible`,fill:`#ffffff`,"fill-opacity":`0.61375661`,"fill-rule":`nonzero`,stroke:`none`,"stroke-width":`16`,marker:`none`,"enable-background":`accumulate`},d:`M 480,84 C 225.94901,84 20,289.94901 20,544 20,798.05099 225.94901,1004 480,1004 734.05099,1004 940,798.05099 940,544 940,289.94901 734.05099,84 480,84 Z m 0,322 c 76.21531,0 138,61.78469 138,138 0,76.21531 -61.78469,138 -138,138 -76.21531,0 -138,-61.78469 -138,-138 0,-76.21531 61.78469,-138 138,-138 z`,id:`path3655`,"inkscape:connector-curvature":`0`})]),createBaseVNode(`clipPath`,{clipPathUnits:`userSpaceOnUse`,id:`clipPath4490`},[createBaseVNode(`path`,{style:{color:`#000000`,"font-style":`normal`,"font-variant":`normal`,"font-weight":`normal`,"font-stretch":`normal`,"font-size":`medium`,"line-height":`normal`,"font-family":`sans-serif`,"text-indent":`0`,"text-align":`start`,"text-decoration":`none`,"text-decoration-line":`none`,"text-decoration-style":`solid`,"text-decoration-color":`#000000`,"letter-spacing":`normal`,"word-spacing":`normal`,"text-transform":`none`,direction:`ltr`,"block-progression":`tb`,"writing-mode":`lr-tb`,"baseline-shift":`baseline`,"text-anchor":`start`,"white-space":`normal`,"clip-rule":`nonzero`,display:`inline`,overflow:`visible`,visibility:`visible`,opacity:`1`,isolation:`auto`,"mix-blend-mode":`normal`,"color-interpolation":`sRGB`,"color-interpolation-filters":`linearRGB`,"solid-color":`#000000`,"solid-opacity":`1`,fill:`#000000`,"fill-opacity":`1`,"fill-rule":`evenodd`,stroke:`none`,"stroke-width":`96.91093445`,"stroke-linecap":`butt`,"stroke-linejoin":`miter`,"stroke-miterlimit":`4`,"stroke-dasharray":`none`,"stroke-dashoffset":`0`,"stroke-opacity":`1`,"color-rendering":`auto`,"image-rendering":`auto`,"shape-rendering":`auto`,"text-rendering":`auto`,"enable-background":`accumulate`},d:`m 330,10 c -176.15718,3e-6 -319.999997,143.84282 -320,320 0,88.07859 35.961054,168.07824 93.94141,226.05859 l 68.0957,-68.0957 C 131.73748,447.66326 106.91016,391.89131 106.91016,330 c 0,-123.78262 99.30722,-223.08984 223.08984,-223.08984 123.78262,0 223.08984,99.30722 223.08984,223.08984 0,61.89131 -24.82732,117.66326 -65.12695,157.96289 l 68.0957,68.0957 C 614.03895,498.07824 650,418.07859 650,330 650,153.84282 506.15718,10 330,10 Z`,id:`path4492`,"inkscape:connector-curvature":`0`})]),createBaseVNode(`clipPath`,{clipPathUnits:`userSpaceOnUse`,id:`clipPath4494`},[createBaseVNode(`path`,{style:{color:`#000000`,"font-style":`normal`,"font-variant":`normal`,"font-weight":`normal`,"font-stretch":`normal`,"font-size":`medium`,"line-height":`normal`,"font-family":`sans-serif`,"text-indent":`0`,"text-align":`start`,"text-decoration":`none`,"text-decoration-line":`none`,"text-decoration-style":`solid`,"text-decoration-color":`#000000`,"letter-spacing":`normal`,"word-spacing":`normal`,"text-transform":`none`,direction:`ltr`,"block-progression":`tb`,"writing-mode":`lr-tb`,"baseline-shift":`baseline`,"text-anchor":`start`,"white-space":`normal`,"clip-rule":`nonzero`,display:`inline`,overflow:`visible`,visibility:`visible`,opacity:`1`,isolation:`auto`,"mix-blend-mode":`normal`,"color-interpolation":`sRGB`,"color-interpolation-filters":`linearRGB`,"solid-color":`#000000`,"solid-opacity":`1`,fill:`#000000`,"fill-opacity":`1`,"fill-rule":`evenodd`,stroke:`none`,"stroke-width":`96.91093445`,"stroke-linecap":`butt`,"stroke-linejoin":`miter`,"stroke-miterlimit":`4`,"stroke-dasharray":`none`,"stroke-dashoffset":`0`,"stroke-opacity":`1`,"color-rendering":`auto`,"image-rendering":`auto`,"shape-rendering":`auto`,"text-rendering":`auto`,"enable-background":`accumulate`},d:`m 330,10 c -176.15718,3e-6 -319.999997,143.84282 -320,320 0,88.07859 35.961054,168.07824 93.94141,226.05859 l 68.0957,-68.0957 C 131.73748,447.66326 106.91016,391.89131 106.91016,330 c 0,-123.78262 99.30722,-223.08984 223.08984,-223.08984 123.78262,0 223.08984,99.30722 223.08984,223.08984 0,61.89131 -24.82732,117.66326 -65.12695,157.96289 l 68.0957,68.0957 C 614.03895,498.07824 650,418.07859 650,330 650,153.84282 506.15718,10 330,10 Z`,id:`path4496`,"inkscape:connector-curvature":`0`})]),createBaseVNode(`clipPath`,{clipPathUnits:`userSpaceOnUse`,id:`clipPath4498`},[createBaseVNode(`path`,{style:{color:`#000000`,"font-style":`normal`,"font-variant":`normal`,"font-weight":`normal`,"font-stretch":`normal`,"font-size":`medium`,"line-height":`normal`,"font-family":`sans-serif`,"text-indent":`0`,"text-align":`start`,"text-decoration":`none`,"text-decoration-line":`none`,"text-decoration-style":`solid`,"text-decoration-color":`#000000`,"letter-spacing":`normal`,"word-spacing":`normal`,"text-transform":`none`,direction:`ltr`,"block-progression":`tb`,"writing-mode":`lr-tb`,"baseline-shift":`baseline`,"text-anchor":`start`,"white-space":`normal`,"clip-rule":`nonzero`,display:`inline`,overflow:`visible`,visibility:`visible`,opacity:`1`,isolation:`auto`,"mix-blend-mode":`normal`,"color-interpolation":`sRGB`,"color-interpolation-filters":`linearRGB`,"solid-color":`#000000`,"solid-opacity":`1`,fill:`#000000`,"fill-opacity":`1`,"fill-rule":`evenodd`,stroke:`none`,"stroke-width":`96.91093445`,"stroke-linecap":`butt`,"stroke-linejoin":`miter`,"stroke-miterlimit":`4`,"stroke-dasharray":`none`,"stroke-dashoffset":`0`,"stroke-opacity":`1`,"color-rendering":`auto`,"image-rendering":`auto`,"shape-rendering":`auto`,"text-rendering":`auto`,"enable-background":`accumulate`},d:`m 240.41631,-226.27417 c -124.56194,124.56194 -124.56194,327.9864 0,452.54834 62.28096,62.28097 144.27756,93.42096 226.27417,93.42095 l 0,-96.30186 c -56.99229,0 -113.98458,-21.88116 -157.74834,-65.64492 -87.52753,-87.527531 -87.52753,-227.969149 0,-315.49668 87.52753,-87.52753 227.96915,-87.52753 315.49668,0 C 668.20258,-113.98457 690.08374,-56.992283 690.08374,0 l 96.30186,0 c 1e-5,-81.996605 -31.13998,-163.9932 -93.42095,-226.27417 -124.56194,-124.56194 -327.98641,-124.56194 -452.54834,0 z`,id:`path4500`,"inkscape:connector-curvature":`0`})])],-1),_cache[5]||=createBaseVNode(`g`,{"inkscape:label":`background`,"inkscape:groupmode":`layer`,id:`layer1`,transform:`translate(-150,-242.36218)`,style:{display:`none`,opacity:`1`}},[createBaseVNode(`rect`,{style:{fill:`#505050`,"fill-opacity":`1`,stroke:`none`},id:`rect4616`,width:`2175.3789`,height:`1458.4727`,x:`-727.47485`,y:`-115.47279`})],-1),createBaseVNode(`g`,_hoisted_2$140,[_cache[0]||=createBaseVNode(`circle`,{style:{color:`#000000`,display:`inline`,overflow:`visible`,visibility:`visible`,fill:`url(#radialGradient3997)`,"fill-opacity":`1`,"fill-rule":`nonzero`,stroke:`none`,"stroke-width":`16`,marker:`none`,"enable-background":`accumulate`},id:`path4281-5`,cx:`480`,cy:`544`,r:`320`,transform:`translate(-150,-214)`},null,-1),_cache[1]||=createBaseVNode(`path`,{style:{color:`#000000`,display:`inline`,overflow:`visible`,visibility:`visible`,fill:`url(#radialGradient4363-4)`,"fill-opacity":`1`,"fill-rule":`nonzero`,stroke:`none`,"stroke-width":`6`,marker:`none`,"enable-background":`accumulate`},d:`M 480,214 C 297.74603,214 150,361.74603 150,544 150,726.25397 297.74603,874 480,874 662.25397,874 810,726.25397 810,544 810,361.74603 662.25397,214 480,214 Z`,id:`path4281`,"inkscape:connector-curvature":`0`,"sodipodi:nodetypes":`sssss`,"clip-path":`url(#clipPath3653)`,transform:`translate(-150,-214)`},null,-1),createBaseVNode(`text`,_hoisted_3$126,[createBaseVNode(`tspan`,{ref_key:`pressureTextRef`,ref:pressureTextRef,"sodipodi:role":`line`,id:`pressureText`,x:`329.85437`,y:`328.48807`,style:{"font-style":`normal`,"font-variant":`normal`,"font-weight":`normal`,"font-stretch":`normal`,"font-size":`159.64709473px`,"line-height":`125%`,"font-family":`'Squada One'`,"-inkscape-font-specification":`'Squada One'`,"text-align":`center`,"writing-mode":`lr-tb`,"text-anchor":`middle`,fill:`#ffffff`,"fill-opacity":`1`}},` 0`,512)]),createBaseVNode(`text`,_hoisted_4$103,[createBaseVNode(`tspan`,{ref_key:`pressureUnitRef`,ref:pressureUnitRef,"sodipodi:role":`line`,id:`pressureunit`,x:`329.03198`,y:`413.62915`},`PSI`,512)]),(openBlock(!0),createElementBlock(Fragment,null,renderList(pressureTextAttrs.value,attrs=>(openBlock(),createElementBlock(`text`,{ref_for:!0,ref:el=>pressureTextRefs.value.push(el),"xml:space":`preserve`,class:`pressure-text`,id:attrs.id+`p`,x:attrs.x,y:attrs.y},[createBaseVNode(`tspan`,{ref_for:!0,ref:el2=>pressureTSpanRefs.value.push(el2),id:attrs.id,x:attrs.x,y:attrs.y},toDisplayString(attrs.text),9,_hoisted_6$74)],8,_hoisted_5$89))),256))]),createBaseVNode(`g`,_hoisted_7$64,[createBaseVNode(`g`,_hoisted_8$51,[_cache[2]||=createBaseVNode(`rect`,{style:{color:`#000000`,display:`inline`,overflow:`visible`,visibility:`visible`,fill:`#000000`,"fill-opacity":`0.37037036`,"fill-rule":`nonzero`,stroke:`none`,"stroke-width":`16`,marker:`none`,"enable-background":`accumulate`},id:`rect4001`,width:`683.79401`,height:`683.79401`,x:`127.97179`,y:`-340.09323`,transform:`matrix(0.70710678,0.70710678,-0.70710678,0.70710678,0,0)`,"clip-path":`url(#clipPath4498)`},null,-1),createBaseVNode(`path`,{ref_key:`pressureCurveRef`,ref:pressureCurveRef,style:{color:`#000000`,display:`inline`,overflow:`visible`,visibility:`visible`,fill:`none`,stroke:`#ffffff`,"stroke-width":`99.31034088`,"stroke-miterlimit":`4`,"stroke-dasharray":`2374.27468498, 2374.27468498`,"stroke-dashoffset":`0`,"stroke-opacity":`1`,marker:`none`,"enable-background":`accumulate`},d:`M 147.9957,528.59996 C 50,420 27.118653,298.1594 119.95323,156.00847 150,110 350,-30 532.60856,149.71493 c 74.5117,73.33098 97.08931,264.86379 -10.87668,369.15745`,id:`pressureCurve`,"clip-path":`url(#clipPath4494)`},null,512),createBaseVNode(`path`,{ref_key:`redLineRef`,ref:redLineRef,style:{color:`#000000`,overflow:`visible`,visibility:`visible`,fill:`none`,stroke:`#9c0000`,"stroke-width":`117.91827393`,"stroke-linecap":`butt`,"stroke-linejoin":`bevel`,"stroke-miterlimit":`4`,"stroke-dasharray":`none`,"stroke-dashoffset":`604.6484375`,"stroke-opacity":`0.66137564`,marker:`none`,"enable-background":`accumulate`},d:`M 147.99571,510.41274 C 33.434043,395.42128 59.279735,242.76116 138.14044,153.71911 230,50 387.77546,50.913502 485.67663,112.95746 c 165.77018,105.05531 132.03401,312.46382 37.32761,407.0596`,id:`pressure_redline`,"clip-path":`url(#clipPath4490)`},null,512)])]),createBaseVNode(`g`,_hoisted_9$45,[createBaseVNode(`path`,{ref_key:`pressureCurveDashesRef`,ref:pressureCurveDashesRef,style:{display:`inline`,fill:`none`,stroke:`#000000`,"stroke-width":`96.91100311`,"stroke-miterlimit":`0.40000001`,"stroke-dasharray":`48.4555, 48.4555`,"stroke-dashoffset":`0`,"stroke-opacity":`0.37566139`},d:`m 137.9887,522.0113 c -106.044908,-106.04491 -106.044903,-277.97769 1e-5,-384.0226 106.04491,-106.044917 277.97767,-106.044914 384.02259,0 106.04491,106.04491 106.04492,277.97769 10e-6,384.0226`,id:`pressureCurve_dashes`,"inkscape:connector-curvature":`0`,"sodipodi:nodetypes":`cssc`,"inkscape:label":`#path4531-4`},null,512),createBaseVNode(`path`,{ref_key:`pressureTextGuideLineRef`,ref:pressureTextGuideLineRef,style:{display:`inline`,fill:`none`,stroke:`#e90000`,"stroke-width":`2.86352348`,"stroke-miterlimit":`0.40000001`,"stroke-dasharray":`none`,"stroke-dashoffset":`0`,"stroke-opacity":`0.24404764`},d:`m 202.03513,457.96488 c -70.12576,-70.12575 -70.12576,-183.82209 0,-253.94784 70.12575,-70.12576 183.82208,-70.12576 253.94784,0 70.12575,70.12575 70.12575,183.82209 0,253.94784`,id:`pressuretextline`,"inkscape:connector-curvature":`0`,"sodipodi:nodetypes":`cssc`,"inkscape:label":`#path4531-4`},null,512)]),createBaseVNode(`g`,_hoisted_10$38,[createBaseVNode(`g`,{ref_key:`pressureNeedleRef`,ref:pressureNeedleRef,id:`pressure_needle_d`,"inkscape:label":`#g4147`,transform:`translate(-1.2852971e-6,1.993565e-6)`},[..._cache[3]||=[createBaseVNode(`rect`,{y:`7.0002151`,x:`322.0993`,height:`103.00317`,width:`12.038266`,id:`rect4625`,style:{color:`#000000`,display:`inline`,overflow:`visible`,visibility:`visible`,fill:`#d70000`,"fill-opacity":`1`,"fill-rule":`nonzero`,stroke:`none`,"stroke-width":`67.38899994`,marker:`none`,"enable-background":`accumulate`},transform:`matrix(1,0,0.00784004,0.99996927,0,0)`},null,-1),createBaseVNode(`rect`,{transform:`scale(1,-1)`,y:`-660`,x:`322.44037`,height:`660`,width:`15.11928`,id:`rect4625-1`,style:{color:`#000000`,display:`inline`,overflow:`visible`,visibility:`visible`,fill:`#008000`,"fill-opacity":`0`,"fill-rule":`nonzero`,stroke:`none`,"stroke-width":`67.38899994`,marker:`none`,"enable-background":`accumulate`}},null,-1)]],512)])]))}},forcedInduction_default=__plugin_vue_export_helper_default(_sfc_main$191,[[`__scopeId`,`data-v-a0f39cc4`]]),_sfc_main$190={__name:`app`,setup(__props){let{$game}=useLibStore(),forcedInductionRef=ref(null),fiContainerRef=ref(null),enabled=ref(!1);return onMounted(()=>{forcedInductionRef.value.wireThroughRoundDec(roundDec),forcedInductionRef.value.wireThroughUnitSystem((val,func)=>UiUnits[func](val)),$game.streams.add([`forcedInductionInfo`])}),onUnmounted(()=>{$game.streams.remove([`forcedInductionInfo`])}),$game.events.on(`VechicleChange`,()=>forcedInductionRef.value.reset()),$game.events.on(`VehicleFocusChanged`,data=>{data.mode==1&&forcedInductionRef.value!==null&&forcedInductionRef.value.reset()}),$game.events.on(`onStreamsUpdate`,streams=>{if(forcedInductionRef.value===null)return;let newEnabled=forcedInductionRef.value.isStreamValid(streams);newEnabled?(newEnabled&&!enabled.value&&(fiContainerRef.value.style.opacity=1),forcedInductionRef.value.update(streams)):!newEnabled&&enabled&&(fiContainerRef.value.style.opacity=0),enabled.value=newEnabled}),(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,{ref_key:`fiContainerRef`,ref:fiContainerRef,class:`fi-container`},[createVNode(forcedInduction_default,{ref_key:`forcedInductionRef`,ref:forcedInductionRef},null,512)],512))}},app_default$20=__plugin_vue_export_helper_default(_sfc_main$190,[[`__scopeId`,`data-v-3ea976f6`]]),_hoisted_1$170={class:`fi-debug`},_hoisted_2$139={class:`name`},_hoisted_3$125={class:`value`},_sfc_main$189={__name:`app`,setup(__props){let{$game}=useLibStore(),streamsList$1=[`forcedInductionInfo`],defaultMeasures=[{name:`RPM`,key:`rpm`},{name:`Boost`,key:`boost`,type:`pressure`},{name:`Power Coef`,key:`coef`},{name:`Pressure Pulses`,key:`pulses`},{name:`SC Loss`,key:`loss`},{name:`Exhaust Power`,key:`exhaustPower`},{name:`Friction`,key:`friction`},{name:`Backpressure`,key:`backpressure`},{name:`Wastegate Factor`,key:`wastegateFactor`},{name:`Turbo Temp`,key:`turboTemp`,type:`temperature`}],measures=ref([]),filteredMeasures=computed(()=>measures.value.filter(m=>m.val!==void 0));onMounted(()=>{$game.streams.add(streamsList$1),$game.events.on(`onStreamsUpdate`,onStreamsUpdate),$game.events.on(`VehicleReset`,init$3),$game.events.on(`VehicleFocusChanged`,init$3),init$3()}),onUnmounted(()=>{$game.streams.remove(streamsList$1),$game.events.off(`onStreamsUpdate`,onStreamsUpdate),$game.events.off(`VehicleReset`,init$3),$game.events.off(`VehicleFocusChanged`,init$3)});function onStreamsUpdate(streams){for(let stream of streamsList$1)if(!streams[stream])return;measures.value.forEach(x=>{let val=streams.forcedInductionInfo[x.key];val!==void 0&&(x.val=x.type===void 0?val.toFixed(2):$game.units.buildString(x.type,val,2))})}function init$3(){measures.value=defaultMeasures}return(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$170,[(openBlock(!0),createElementBlock(Fragment,null,renderList(filteredMeasures.value,m=>(openBlock(),createElementBlock(`div`,{class:`measure`,key:m.key},[createBaseVNode(`div`,_hoisted_2$139,toDisplayString(m.name),1),createBaseVNode(`div`,_hoisted_3$125,toDisplayString(m.val),1)]))),128))]))}},app_default$21=__plugin_vue_export_helper_default(_sfc_main$189,[[`__scopeId`,`data-v-8094d28b`]]),_sfc_main$188={},_hoisted_1$169={xmlns:`http://www.w3.org/2000/svg`,width:`60`,height:`100`,viewBox:`0 0 60 100`};function _sfc_render$2(_ctx,_cache){return openBlock(),createElementBlock(`svg`,_hoisted_1$169,[..._cache[0]||=[createBaseVNode(`rect`,{x:`4`,y:`4`,width:`52`,height:`92`,rx:`25`,ry:`25`,stroke:`black`,"stroke-width":`4`,fill:`none`},null,-1)]])}var accumulator_default=__plugin_vue_export_helper_default(_sfc_main$188,[[`render`,_sfc_render$2]]),_sfc_main$187={},_hoisted_1$168={xmlns:`http://www.w3.org/2000/svg`,width:`100`,height:`125`,viewBox:`0 0 100 125`,"stroke-width":`4`,stroke:`black`};function _sfc_render$1(_ctx,_cache){return openBlock(),createElementBlock(`svg`,_hoisted_1$168,[..._cache[0]||=[createBaseVNode(`circle`,{cx:`50`,cy:`32`,r:`30`,fill:`none`},null,-1),createBaseVNode(`path`,{d:`M50 6 L57 15 L43 15 Z`,fill:`black`},null,-1),createBaseVNode(`line`,{x1:`50`,y1:`61`,x2:`50`,y2:`90`,stroke:`black`},null,-1),createBaseVNode(`path`,{d:`M15 59 L15 115 L85 115 L85 59`,fill:`none`},null,-1)]])}var pump_default=__plugin_vue_export_helper_default(_sfc_main$187,[[`render`,_sfc_render$1]]),_sfc_main$186={},_hoisted_1$167={xmlns:`http://www.w3.org/2000/svg`,width:`100`,height:`130`,viewBox:`0 0 100 130`,"stroke-width":`4`,stroke:`black`};function _sfc_render(_ctx,_cache){return openBlock(),createElementBlock(`svg`,_hoisted_1$167,[..._cache[0]||=[createStaticVNode(``,6)]])}var reliefValve_default=__plugin_vue_export_helper_default(_sfc_main$186,[[`render`,_sfc_render]]),_hoisted_1$166={xmlns:`http://www.w3.org/2000/svg`,width:`100`,height:`210`,viewBox:`0 0 200 310`},_hoisted_2$138={transform:`translate(100, 0)`},_hoisted_3$124={transform:`translate(0, 110)`},_hoisted_4$102={transform:`translate(110, 190)`},_sfc_main$185={__name:`pumpAssembly`,setup(__props){return(_ctx,_cache)=>(openBlock(),createElementBlock(`svg`,_hoisted_1$166,[createBaseVNode(`g`,_hoisted_2$138,[createVNode(accumulator_default)]),createBaseVNode(`g`,_hoisted_3$124,[createVNode(reliefValve_default)]),createBaseVNode(`g`,_hoisted_4$102,[createVNode(pump_default)]),_cache[0]||=createBaseVNode(`path`,{d:`M56 122 L56 138 M54 120 L128 120 M130 122 L130 98 M130 120 L158 120 M160 118 L160 190`,stroke:`black`,"stroke-width":`4`},null,-1)]))}},pumpAssembly_default=_sfc_main$185,_hoisted_1$165={class:`hydraulics-debug`},_hoisted_2$137={width:`100%`,height:`100%`},_hoisted_3$123={id:`myGradient`,x1:`0%`,y1:`0%`,x2:`100%`,y2:`0%`},_hoisted_4$101=[`offset`],_hoisted_5$88={transform:`translate(0, 150)`,id:`pumpAssembly`},_hoisted_6$73=[`transform`],_hoisted_7$63=[`width`],_sfc_main$184={__name:`app`,setup(__props){let streamsList$1=[],{$game}=useLibStore(),offset$2=ref(0),offsetLeft=computed(()=>`${offset$2.value}%`),increase=()=>{offset$2.value<=100&&(offset$2.value+=10)},decrease=()=>{offset$2.value>0&&(offset$2.value-=10)},consumers=ref([{type:`hydraulicMotor`},{type:`cylinder`}]),addCylinder=function(){consumers.value.push({type:`cylinder`})},addhydraulicMotor=function(){consumers.value.push({type:`hydraulicMotor`})},removeConsumer=function(index=null){index===null?consumers.value.pop():consumers.value.splice(index,1)};onMounted(()=>{$game.events.on(`onStreamsUpdate`,onStreamsUpdate),$game.streams.add(streamsList$1)}),onUnmounted(()=>{$game.events.off(`onStreamsUpdate`,onStreamsUpdate),$game.streams.remove(streamsList$1)});function onStreamsUpdate(streams){for(let stream of streamsList$1)if(!streams[stream])return}return(_ctx,_cache)=>(openBlock(),createElementBlock(Fragment,null,[_cache[1]||=createBaseVNode(`h1`,null,`Hydraulics Debug`,-1),createBaseVNode(`button`,{onClick:decrease},`dec`),createBaseVNode(`button`,{onClick:increase},`inc`),createBaseVNode(`button`,{onClick:addhydraulicMotor},`motor`),createBaseVNode(`button`,{onClick:addCylinder},`cylinder`),createBaseVNode(`button`,{onClick:removeConsumer},`Remove Consumer`),createBaseVNode(`div`,null,` offset: `+toDisplayString(offset$2.value)+` left: `+toDisplayString(offsetLeft.value),1),createBaseVNode(`div`,_hoisted_1$165,[(openBlock(),createElementBlock(`svg`,_hoisted_2$137,[createBaseVNode(`defs`,null,[createBaseVNode(`linearGradient`,_hoisted_3$123,[createBaseVNode(`stop`,{offset:offsetLeft.value,"stop-color":`green`},null,8,_hoisted_4$101),_cache[0]||=createBaseVNode(`stop`,{offset:`0`,"stop-color":`black`},null,-1)])]),createBaseVNode(`g`,_hoisted_5$88,[createVNode(pumpAssembly_default)]),(openBlock(!0),createElementBlock(Fragment,null,renderList(consumers.value,(consumer,index)=>(openBlock(),createElementBlock(`g`,{transform:`translate(${(index+1)*100}, 95)`},[createVNode(consumer,{consumerType:consumer.type},null,8,[`consumerType`])],8,_hoisted_6$73))),256)),createBaseVNode(`rect`,{x:`80`,y:`236.5`,width:100*(consumers.value.length-1)+66,height:`2`,fill:`url(#myGradient)`},null,8,_hoisted_7$63)]))])],64))}},app_default$22=__plugin_vue_export_helper_default(_sfc_main$184,[[`__scopeId`,`data-v-a5aea534`]]),_hoisted_1$164={key:0,class:`bindings-app`},_hoisted_2$136={key:0,class:`toggle-icon`},_hoisted_3$122={key:1,class:`toggle-icon`},_hoisted_4$100={key:0,class:`players-binding`},_hoisted_5$87={key:0},_hoisted_6$72={key:1,class:`bindings-container`},_hoisted_7$62={class:`binding-item`},_sfc_main$183={__name:`app`,setup(__props){let{$game}=useLibStore(),bindings=ref([]),small=ref(!0),timeout=ref(null),show=ref(0),players=ref([]),forward=()=>{show.value=(show.value+1)%bindings.value.length},backward=()=>{show.value=show.value===0?bindings.value.length-1:show.value-1},toggleSmall=()=>{small.value=!small.value,clearTimeout(timeout)},goToBindings=(action,control)=>{$game.events.emit(`MenuHide`,!1),bngVue.gotoGameState(`menu.options.controls.bindings.edit`,{params:{action:action.actionName,oldBinding:{control:control.c,device:control.n}}})};onMounted(()=>{$game.events.on(`InputBindingsChanged`,onInputBindingsChanged),$game.events.on(`VehicleChange`,showBriefly),$game.events.on(`VehicleFocusChanged`,showBriefly),$game.api.engineLua(`extensions.core_input_bindings.notifyUI("keys app: link init")`),setTimeout(function(){$game.api.engineLua(`settings.notifyUI()`)},200)}),onUnmounted(()=>{$game.events.off(`InputBindingsChanged`,onInputBindingsChanged),$game.events.off(`VehicleChange`,showBriefly),$game.events.off(`VehicleFocusChanged`,showBriefly)});function showBriefly(){small.value&&(timeout.value=setTimeout(()=>small.value=!0,1e4)),small.value=!1}function onInputBindingsChanged(data){let specialKeys=[];players.value=[];for(let i=0;i=bindings.value.length&&(show.value=0)}function existsAt(arr,ac){return arr.map(function(elem,i){return elem.actionName===ac?i:-1}).filter(function(elem){return elem!==-1})}return(_ctx,_cache)=>players.value.length>1||bindings.value[show.value]&&bindings.value[show.value].length>0?(openBlock(),createElementBlock(`div`,_hoisted_1$164,[createBaseVNode(`div`,{onClick:_cache[0]||=$event=>toggleSmall(),class:`binding-show`},[small.value?(openBlock(),createElementBlock(`span`,_hoisted_2$136,[createVNode(unref(bngIcon_default),{class:`key-icon`,type:unref(icons).arrowSmallLeft},null,8,[`type`])])):(openBlock(),createElementBlock(`span`,_hoisted_3$122,[createVNode(unref(bngIcon_default),{class:`key-icon`,type:unref(icons).arrowSmallRight},null,8,[`type`])]))]),!small.value&&(players.value.length>1||bindings.value[show.value]&&bindings.value[show.value].length>0)?(openBlock(),createElementBlock(`div`,_hoisted_4$100,[!small.value&&players.value.length>1?(openBlock(),createElementBlock(`div`,_hoisted_5$87,[bindings.value.length>1?(openBlock(),createBlock(unref(bngButton_default),{key:0,onClick:_cache[1]||=$event=>backward()})):createCommentVNode(``,!0),createBaseVNode(`span`,null,`Player `+toDisplayString(show.value),1),bindings.value.length>1?(openBlock(),createBlock(unref(bngButton_default),{key:1,onClick:_cache[2]||=$event=>forward()})):createCommentVNode(``,!0)])):createCommentVNode(``,!0),bindings.value[show.value].length>0&&!small.value?(openBlock(),createElementBlock(`div`,_hoisted_6$72,[(openBlock(!0),createElementBlock(Fragment,null,renderList(bindings.value[show.value],entry=>(openBlock(),createElementBlock(`div`,_hoisted_7$62,[createBaseVNode(`div`,null,toDisplayString(_ctx.$t(entry.action)),1),createBaseVNode(`div`,null,[(openBlock(!0),createElementBlock(Fragment,null,renderList(entry.control,b=>(openBlock(),createBlock(unref(bngBinding_default),{deviceKey:b.c,device:b.d,"show-unassigned":!0,onClick:$event=>goToBindings(entry,b)},null,8,[`deviceKey`,`device`,`onClick`]))),256))])]))),256))])):createCommentVNode(``,!0)])):createCommentVNode(``,!0)])):createCommentVNode(``,!0)}},app_default$23=__plugin_vue_export_helper_default(_sfc_main$183,[[`__scopeId`,`data-v-b0d8eae9`]]),_hoisted_1$163={class:`bng-app log-vehicle-stats`},_hoisted_2$135={class:`update-period`},_hoisted_3$121={class:`settings-row`},_hoisted_4$99={class:`settings-row`},_hoisted_5$86={class:`settings-row`},_hoisted_6$71={class:`settings-row`},_hoisted_7$61={class:`log-btns`},_sfc_main$182={__name:`app`,setup(__props){const{$game}=useLibStore(),config=reactive({updateTime:5,moduleGeneral:!0,moduleWheels:!0,moduleEngine:!0,moduleInputs:!0,modulePowertrain:!0,outputFileName:`settings.json`,inputFileName:`settings.json`,outputDir:`VSL`}),configChanged=(configName,value)=>{switch(configName){case`moduleGeneral`:config.moduleGeneral=value;break;case`moduleWheels`:config.moduleWheels=value;break;case`moduleEngine`:config.moduleEngine=value;break;case`moduleInputs`:config.moduleInputs=value;break;case`modulePowertrain`:config.modulePowertrain=value;break}},applySettings=()=>{$game.api.activeObjectLua(`extensions.vehicleStatsLogger.updateTime = ${config.updateTime}`),$game.api.activeObjectLua(`extensions.vehicleStatsLogger.settings.useModule["General"] = ${config.moduleGeneral}`),$game.api.activeObjectLua(`extensions.vehicleStatsLogger.settings.useModule["Wheels"] = ${config.moduleWheels}`),$game.api.activeObjectLua(`extensions.vehicleStatsLogger.settings.useModule["Inputs"] = ${config.moduleInputs}`),$game.api.activeObjectLua(`extensions.vehicleStatsLogger.settings.useModule["Engine"] = ${config.moduleEngine}`),$game.api.activeObjectLua(`extensions.vehicleStatsLogger.settings.useModule["Powertrain"] = ${config.modulePowertrain}`)},useAsOutputDir=()=>{$game.api.activeObjectLua(`extensions.vehicleStatsLogger.settings.outputDir = "${config.outputDir}"`)},getNewOutputFilename=()=>{$game.api.activeObjectLua(`extensions.vehicleStatsLogger.suggestOutputFilename()`,function(data){config.outputFileName=data})},saveSettingsToJson=()=>{config.outputFileName!==``&&$game.api.activeObjectLua(`extensions.vehicleStatsLogger.writeSettingsToJSON("${config.outputFileName}")`)},importSettingsFromFile=()=>{scope.inputFileName!==``&&($game.api.activeObjectLua(`extensions.vehicleStatsLogger.applySettingsFromJSON("${config.inputFileName}")`),config.moduleGeneral=eval(`${extensions.vehicleStatsLogger.settings.useModule.General}`),config.moduleWheels=eval(`${extensions.vehicleStatsLogger.settings.useModule.Wheels}`),config.moduleInputs=eval(`${extensions.vehicleStatsLogger.settings.useModule.Inputs}`),config.moduleEngine=eval(`${extensions.vehicleStatsLogger.settings.useModule.Engine}`),config.modulePowertrain=eval(`${extensions.vehicleStatsLogger.settings.useModule.Powertrain}`))},startLogging=()=>{$game.api.activeObjectLua(`extensions.vehicleStatsLogger.startLogging()`)},stopLogging=()=>{$game.api.activeObjectLua(`extensions.vehicleStatsLogger.stopLogging()`)};return(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$163,[createBaseVNode(`div`,_hoisted_2$135,[_cache[20]||=createBaseVNode(`span`,{class:`label`},`Update Period:`,-1),createVNode(unref(bngInput_default),{type:`number`,min:1,max:360,step:1,modelValue:config.updateTime,"onUpdate:modelValue":_cache[0]||=$event=>config.updateTime=$event,suffix:`seconds`},null,8,[`modelValue`])]),createBaseVNode(`div`,null,[createVNode(unref(bngPillCheckbox_default),{modelValue:config.moduleGeneral,"onUpdate:modelValue":_cache[1]||=$event=>config.moduleGeneral=$event,onValueChanged:_cache[2]||=val=>configChanged(`moduleGeneral`,val)},{default:withCtx(()=>[..._cache[21]||=[createTextVNode(` General`,-1)]]),_:1},8,[`modelValue`]),createVNode(unref(bngPillCheckbox_default),{modelValue:config.moduleWheels,"onUpdate:modelValue":_cache[3]||=$event=>config.moduleWheels=$event,onValueChanged:_cache[4]||=val=>configChanged(`moduleWheels`,val)},{default:withCtx(()=>[..._cache[22]||=[createTextVNode(` Wheels`,-1)]]),_:1},8,[`modelValue`]),createVNode(unref(bngPillCheckbox_default),{modelValue:config.moduleEngine,"onUpdate:modelValue":_cache[5]||=$event=>config.moduleEngine=$event,onValueChanged:_cache[6]||=val=>configChanged(`moduleEngine`,val)},{default:withCtx(()=>[..._cache[23]||=[createTextVNode(` Engine`,-1)]]),_:1},8,[`modelValue`]),createVNode(unref(bngPillCheckbox_default),{modelValue:config.moduleInputs,"onUpdate:modelValue":_cache[7]||=$event=>config.moduleInputs=$event,onValueChanged:_cache[8]||=val=>configChanged(`moduleInputs`,val)},{default:withCtx(()=>[..._cache[24]||=[createTextVNode(` Inputs`,-1)]]),_:1},8,[`modelValue`]),createVNode(unref(bngPillCheckbox_default),{modelValue:config.modulePowertrain,"onUpdate:modelValue":_cache[9]||=$event=>config.modulePowertrain=$event,onValueChanged:_cache[10]||=val=>configChanged(`modulePowertrain`,val)},{default:withCtx(()=>[..._cache[25]||=[createTextVNode(`Powertrain`,-1)]]),_:1},8,[`modelValue`])]),createBaseVNode(`div`,_hoisted_3$121,[_cache[27]||=createBaseVNode(`label`,null,`Apply Settings:`,-1),createVNode(unref(bngButton_default),{class:`settings-btn`,onClick:_cache[11]||=$event=>applySettings()},{default:withCtx(()=>[..._cache[26]||=[createTextVNode(`Apply`,-1)]]),_:1})]),withDirectives((openBlock(),createElementBlock(`div`,_hoisted_4$99,[_cache[29]||=createBaseVNode(`label`,null,`Set Custom Output Directory:`,-1),createVNode(unref(bngInput_default),{modelValue:config.outputDir,"onUpdate:modelValue":_cache[12]||=$event=>config.outputDir=$event},null,8,[`modelValue`]),createVNode(unref(bngButton_default),{class:`settings-btn`,onClick:_cache[13]||=$event=>useAsOutputDir()},{default:withCtx(()=>[..._cache[28]||=[createTextVNode(`Use`,-1)]]),_:1})])),[[unref(BngTooltip_default),`Subdirectory of the BeamNG.drive/BeamNG.tech directory.`]]),withDirectives((openBlock(),createElementBlock(`div`,_hoisted_5$86,[_cache[31]||=createBaseVNode(`label`,null,`Settings Output Filename:`,-1),createVNode(unref(bngInput_default),{modelValue:config.outputFileName,"onUpdate:modelValue":_cache[14]||=$event=>config.outputFileName=$event},null,8,[`modelValue`]),createVNode(unref(bngButton_default),{class:`settings-btn`,onClick:_cache[15]||=$event=>saveSettingsToJson()},{default:withCtx(()=>[..._cache[30]||=[createTextVNode(`Write`,-1)]]),_:1})])),[[unref(BngTooltip_default),`Settings files are written to the BeamNG.drive/BeamNG.tech directory.`]]),withDirectives((openBlock(),createElementBlock(`div`,_hoisted_6$71,[_cache[33]||=createBaseVNode(`label`,null,`Settings Input Filename:`,-1),createVNode(unref(bngInput_default),{modelValue:config.inputFileName,"onUpdate:modelValue":_cache[16]||=$event=>config.inputFileName=$event},null,8,[`modelValue`]),createVNode(unref(bngButton_default),{class:`settings-btn`,onClick:_cache[17]||=$event=>importSettingsFromFile()},{default:withCtx(()=>[..._cache[32]||=[createTextVNode(`Load`,-1)]]),_:1})])),[[unref(BngTooltip_default),`Settings files are assumed to be in the BeamNG.drive/BeamNG.tech directory.`]]),createBaseVNode(`div`,_hoisted_7$61,[createVNode(unref(bngButton_default),{class:`start-btn`,onClick:_cache[18]||=$event=>startLogging()},{default:withCtx(()=>[..._cache[34]||=[createTextVNode(`Start Log`,-1)]]),_:1}),createVNode(unref(bngButton_default),{class:`stop-btn`,onClick:_cache[19]||=$event=>stopLogging()},{default:withCtx(()=>[..._cache[35]||=[createTextVNode(`Stop Log`,-1)]]),_:1})])]))}},app_default$24=__plugin_vue_export_helper_default(_sfc_main$182,[[`__scopeId`,`data-v-686c3ac5`]]),_hoisted_1$162={class:`replay-app-container`,ref:`appContainerRef`},_hoisted_2$134={class:`left-controls`},_hoisted_3$120={class:`filename-container`},_hoisted_4$98={key:1,class:`filename`},_hoisted_5$85={key:1,class:`filename`},_hoisted_6$70={class:`right-controls`},_hoisted_7$60={class:`replay-controls-container`},_hoisted_8$50={class:`play-controls`},_hoisted_9$44={key:0,class:`speed-controls`},_hoisted_10$37={class:`svg-time-container`},_hoisted_11$33={width:`100%`,height:`100%`,preserveAspectRatio:`xMidYMid meet`},_hoisted_12$26={viewBox:`0 0 200 50`,width:`100%`,height:`100%`,overflow:`visible`},_hoisted_13$23={transform:`translate(100, 25)`},_hoisted_14$22={"text-anchor":`middle`,"dominant-baseline":`middle`,class:`time-text`,"font-size":`40`,"line-height":`1`},_hoisted_15$21={class:`time-display-total`},_hoisted_16$21={class:`position-slider`},replayFolder=`replays/`,replayFileExtension=`.rpl`,_sfc_main$181={__name:`app`,props:{hideFileControls:{type:Boolean,default:!1}},setup(__props){let state=ref(`inactive`),speed=ref(1),paused=ref(!1),renaming=ref(!1),isSeeking=ref(!1),loadedFile=ref(``),positionSeconds=ref(0),totalSeconds=ref(0),positionPercent=ref(0),fpsRec=ref(0),fpsPlay=ref(0),originalFilename=``,lastSeek=0,events$3=useEvents(),resizeObserver=ref(null),replayControlsRef=ref(null),containerWidth=shallowRef(0),layoutState=computed(()=>{let width$1=containerWidth.value;return{isReplayControlsNarrow:width$1<301,isFileControlsNarrow:width$1<361}}),props=__props,formatTime$1=seconds=>new Date(seconds*1e3).toISOString().substr(14,8),debounce$1=(fn,delay)=>{let timer=null;return(...args)=>{timer&&clearTimeout(timer),timer=setTimeout(()=>{fn(...args),timer=null},delay)}},listRecordings=()=>{window.bngVue.gotoGameState(`menu.replay`)},startRenaming=()=>{renaming.value=!0,originalFilename=loadedFile.value},cancelRename=()=>{renaming.value=!1,loadedFile.value=originalFilename},acceptRename=()=>{if(loadedFile.value===originalFilename){cancelRename();return}renaming.value=!1,Lua_default.core_replay.acceptRename(replayFolder+originalFilename+replayFileExtension,replayFolder+loadedFile.value+replayFileExtension)},toggleSpeed=val=>{Lua_default.core_replay.toggleSpeed(val)},togglePlay=()=>{Lua_default.core_replay.togglePlay()},toggleRecording=()=>{Lua_default.core_replay.toggleRecording(!0)},cancelRecording=()=>{Lua_default.core_replay.cancelRecording()},stop$1=()=>{Lua_default.core_replay.stop()},seek=()=>{state.value===`playback`&&(lastSeek=Date.now(),Lua_default.core_replay.pause(!0),Lua_default.core_replay.seek(positionPercent.value))};watch(positionSeconds,(newVal,oldVal)=>{Date.now()-lastSeek>500&&totalSeconds.value>0&&(positionPercent.value=newVal/totalSeconds.value)});let setupResizeObserver=()=>{if(!replayControlsRef.value)return;let rafId=null,updateWidth=debounce$1(width$1=>{containerWidth.value=width$1},100);resizeObserver.value=new ResizeObserver(entries=>{rafId!==null&&cancelAnimationFrame(rafId),rafId=requestAnimationFrame(()=>{for(let entry of entries)updateWidth(entry.contentRect.width);rafId=null})}),resizeObserver.value.observe(replayControlsRef.value)};return onMounted(async()=>{try{Lua_default.core_replay.onInit()}catch(e){console.error(`Error initializing replay state:`,e)}events$3.on(`replayStateChanged`,val=>{renaming.value||(loadedFile.value=val.loadedFile.replace(replayFolder,``).replace(replayFileExtension,``)),positionSeconds.value=val.positionSeconds,totalSeconds.value=val.totalSeconds,speed.value=val.speed,paused.value=val.paused,fpsRec.value=val.fpsRec,fpsPlay.value=val.fpsPlay,state.value=val.state,isSeeking.value=val.jumpOffset!==0,Date.now()-lastSeek>500&&totalSeconds.value>0?positionPercent.value=positionSeconds.value/totalSeconds.value:isSeeking.value=!0}),await nextTick(),setupResizeObserver()}),onUnmounted(()=>{resizeObserver.value&&=(resizeObserver.value.disconnect(),null),events$3.off(`replayStateChanged`)}),(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$162,[props.hideFileControls?createCommentVNode(``,!0):(openBlock(),createElementBlock(`div`,{key:0,class:normalizeClass([`file-controls`,{narrow:layoutState.value.isFileControlsNarrow}])},[createBaseVNode(`div`,_hoisted_2$134,[createVNode(unref(bngButton_default),{class:`recordings-button`,onClick:listRecordings,icon:`folder`,tooltip:`Open recordings`,accent:unref(ACCENTS).text},null,8,[`accent`]),loadedFile.value&&state.value!==`recording`&&!renaming.value?(openBlock(),createBlock(unref(bngButton_default),{key:0,class:`recordings-button`,onClick:stop$1,icon:`xmark`,disabled:state.value!==`playback`,tooltip:`Close replay`,accent:unref(ACCENTS).text},null,8,[`disabled`,`accent`])):createCommentVNode(``,!0),state.value===`recording`?(openBlock(),createBlock(unref(bngButton_default),{key:1,class:`recordings-button`,onClick:cancelRecording,icon:`undo`,accent:unref(ACCENTS).attention,tooltip:`Cancel recording`},null,8,[`accent`])):createCommentVNode(``,!0)]),createBaseVNode(`div`,_hoisted_3$120,[loadedFile.value&&state.value!==`recording`?(openBlock(),createElementBlock(Fragment,{key:0},[renaming.value?(openBlock(),createElementBlock(Fragment,{key:0},[createVNode(unref(bngButton_default),{onClick:cancelRename,icon:`xmark`,accent:unref(ACCENTS).ghost,class:`cancel-rename-button`},null,8,[`accent`]),createVNode(unref(bngInput_default),{id:`replay-filename-input`,class:`filename-input`,prefix:replayFolder,suffix:replayFileExtension,modelValue:loadedFile.value,"onUpdate:modelValue":_cache[0]||=$event=>loadedFile.value=$event,placeholder:`(no file)`,disabled:state.value===`recording`||!loadedFile.value,onKeyup:withKeys(acceptRename,[`enter`])},null,8,[`modelValue`,`disabled`])],64)):(openBlock(),createElementBlock(`div`,_hoisted_4$98,toDisplayString(replayFolder)+toDisplayString(loadedFile.value)+toDisplayString(replayFileExtension),1)),createVNode(unref(bngButton_default),{onClick:_cache[1]||=$event=>renaming.value?acceptRename():startRenaming(),icon:renaming.value?`checkmark`:`edit`,accent:renaming.value?unref(ACCENTS).main:unref(ACCENTS).ghost},null,8,[`icon`,`accent`])],64)):(openBlock(),createElementBlock(`div`,_hoisted_5$85,` No File loaded `))]),createBaseVNode(`div`,_hoisted_6$70,[createVNode(unref(bngButton_default),{onClick:toggleRecording,icon:state.value===`recording`?`square`:`bigDot`,accent:unref(ACCENTS).text,disabled:state.value===`playback`,tooltip:state.value===`recording`?`Save recording`:`Record new replay`,class:`recordings-button record-button`},null,8,[`icon`,`accent`,`disabled`,`tooltip`])])],2)),createBaseVNode(`div`,_hoisted_7$60,[createBaseVNode(`div`,{class:normalizeClass([`replay-controls`,{narrow:layoutState.value.isReplayControlsNarrow}]),ref_key:`replayControlsRef`,ref:replayControlsRef},[createBaseVNode(`div`,_hoisted_8$50,[createVNode(unref(bngButton_default),{onClick:togglePlay,class:`play-button`,icon:state.value===`playback`&&!paused.value?`pause`:`play`,disabled:state.value===`recording`||!loadedFile.value,accent:unref(ACCENTS).ghost},null,8,[`icon`,`disabled`,`accent`]),state.value===`inactive`?createCommentVNode(``,!0):(openBlock(),createElementBlock(`div`,_hoisted_9$44,[createVNode(unref(bngButton_default),{class:`speed-button small`,onClick:_cache[2]||=$event=>toggleSpeed(-1),icon:`mathMinus`,disabled:!loadedFile.value,accent:unref(ACCENTS).text},null,8,[`disabled`,`accent`]),createBaseVNode(`div`,{class:normalizeClass([`playback-speed-display`,{disabled:!loadedFile.value}])},toDisplayString(speed.value.toFixed(2))+`x`,3),createVNode(unref(bngButton_default),{class:`speed-button small`,onClick:_cache[3]||=$event=>toggleSpeed(1),icon:`mathPlus`,disabled:!loadedFile.value,accent:unref(ACCENTS).text},null,8,[`disabled`,`accent`])]))]),createBaseVNode(`div`,{class:normalizeClass([`time-display`,{active:loadedFile.value,seeking:isSeeking.value}])},[createBaseVNode(`div`,_hoisted_10$37,[(openBlock(),createElementBlock(`svg`,_hoisted_11$33,[(openBlock(),createElementBlock(`svg`,_hoisted_12$26,[createBaseVNode(`g`,_hoisted_13$23,[createBaseVNode(`text`,_hoisted_14$22,toDisplayString(formatTime$1(positionSeconds.value)),1)])]))]))]),createBaseVNode(`span`,_hoisted_15$21,`(`+toDisplayString(formatTime$1(totalSeconds.value))+`)`,1)],2)],2),createBaseVNode(`div`,_hoisted_16$21,[createVNode(unref(bngSlider_default),{modelValue:positionPercent.value,"onUpdate:modelValue":_cache[4]||=$event=>positionPercent.value=$event,min:0,max:1,step:.001,onInput:seek,disabled:state.value!==`playback`||!loadedFile.value},null,8,[`modelValue`,`disabled`])])])],512))}},app_default$1=__plugin_vue_export_helper_default(_sfc_main$181,[[`__scopeId`,`data-v-bf84291a`]]),_hoisted_1$161={style:{width:`100%`,height:`100%`},class:`bng-app`,layout:`column`},_hoisted_2$133={style:{display:`flex`,"justify-content":`center`,"align-items":`baseline`}},_hoisted_3$119={style:{"font-size":`1.3em`,"font-weight":`bold`}},_hoisted_4$97={style:{color:`rgba(255, 255, 255, 0.8)`}},_hoisted_5$84={style:{"text-align":`center`,color:`rgba(255, 255, 255, 0.8)`,"font-size":`0.75em`}},_sfc_main$180={__name:`app`,setup(__props){let{$game}=useLibStore(),streamsList$1=[`engineInfo`];$game.streams.add(streamsList$1);let numToBig=ref(`1`);ref(NaN);let rpm=ref(0),leadingZeros=ref(null);onMounted(()=>{console.log(`simpleDigTacho mounted`),$game.events.on(`onStreamsUpdate`,onStreamsUpdate)}),onUnmounted(()=>{console.log(`simpleDigTacho unmounted`),$game.streams.remove(streamsList$1),$game.events.off(`onStreamsUpdate`,onStreamsUpdate)});function onStreamsUpdate(streams){for(let stream of streamsList$1)if(!streams[stream])return;if(rpm.value=Math.round(streams.engineInfo[4]),rpm.value.toString().length>4){let help=10**(rpm.value.toString().length-4);numToBig.value=help.toString(),rpm.value=Math.round(rpm.value/help)}else numToBig.value=`1`;rpm.value=rpm.value.toString().slice(-4),isNaN(rpm.value)||(leadingZeros.value=`0000`.slice(rpm.value.length))}return(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$161,[createBaseVNode(`div`,_hoisted_2$133,[createBaseVNode(`span`,_hoisted_3$119,[createBaseVNode(`span`,_hoisted_4$97,toDisplayString(leadingZeros.value),1),createBaseVNode(`span`,null,toDisplayString(rpm.value),1)]),_cache[0]||=createBaseVNode(`span`,{style:{"font-size":`0.9em`,"font-weight":`bold`,"margin-left":`2px`}},`RPM`,-1)]),createBaseVNode(`small`,_hoisted_5$84,[createTextVNode(toDisplayString(_ctx.$t(`ui.apps.digTacho.engine`))+` `,1),createBaseVNode(`span`,null,`(x`+toDisplayString(numToBig.value)+`)`,1)])]))}},app_default$25=_sfc_main$180,_hoisted_1$160={"xmlns:svg":`http://www.w3.org/2000/svg`,xmlns:`http://www.w3.org/2000/svg`,"xmlns:xlink":`http://www.w3.org/1999/xlink`,version:`1.1`,width:`100%`,height:`100%`,viewBox:`0 0 660 660`},_hoisted_2$132={"xml:space":`preserve`,class:`text1`,x:`329.88641`,y:`289.30463`,id:`tspan4449-43`},_hoisted_3$118={"xml:space":`preserve`,id:`speed_units`,class:`speed-units`,x:`330`,y:`348`},_hoisted_4$96={"xml:space":`preserve`,id:`tspan4449-4-3`,class:`tacho2-gear`,x:`386.67343`,y:`457.94861`,transform:`matrix(1,0,-0.13142611,1,0,0)`},_hoisted_5$83={"xml:space":`preserve`,x:`330.09229`,y:`498.18045`,id:`text4447-2-4`,class:`rpm-text-legend`},_hoisted_6$69={transform:`translate(-150,-214)`,id:`revcurvemask`,class:`revcurvemask`,"clip-path":`url(#clipPath4710)`},rpmTextSize=50,maxRpmTexts=13,tickMarkLength=64,tickInnerOffset=42,_sfc_main$179={__name:`tacho`,setup(__props,{expose:__expose}){let width$1=660,height$1=660,initialized=ref(!1),dashSize$1=5,computeGaugeFullRange=maxrpm=>Math.ceil((maxrpm||0)/1e3)*1e3+1e3,computeGaugeStep=maxrpm=>maxrpm<4e3?500:maxrpm>15e3?2e3:1e3,computeGaugeMarks=maxrpm=>{let fullRange=computeGaugeFullRange(maxrpm),step=computeGaugeStep(maxrpm);return Math.ceil(fullRange/step)+1},rpmTextRefs=ref([]),setRpmRef=(el,i)=>{el&&(rpmTextRefs.value[i]=el)},oilTempBarRef=ref(null),oilTempBarLen=computed(()=>oilTempBarRef.value.getTotalLength()),oilTempIcoOffRef=ref(null),oilTempIcoOnRef=ref(null),speedTextRef=ref(null),gearTextRef=ref(null),revcurveRef=ref(null),revCurveLen=computed(()=>revcurveRef.value.getTotalLength()),revcurveDashesRef=ref(null),revCurveDashesLen=computed(()=>revcurveDashesRef.value.getTotalLength()),fuelBarRef=ref(null),fuelBarLen=computed(()=>fuelBarRef.value.getTotalLength()),fuelWarnIcoOffRef=ref(null),fuelWarnIcoOnRef=ref(null),lastFuelLevel=0,shouldPlayFuelLowSound=!1,lowFuelSoundPlayed=!1,isCareer=!1,redLineRef=ref(null),redLineLen=computed(()=>redLineRef.value.getTotalLength()),rpmTextGuideLineRef=ref(null),rpmTextGuideLineLen=computed(()=>rpmTextGuideLineRef.value.getTotalLength()),tickMarkRefs=ref([]),setTickRef=(el,i)=>{el&&(tickMarkRefs.value[i]=el)},icoHandBrakeOffRef=ref(null),icoHandBrakeOnRef=ref(null),icoABSOffRef=ref(null),icoABSOnRef=ref(null),icoIndicatorLeftOffRef=ref(null),icoIndicatorLeftOnRef=ref(null),icoIndicatorRightOffRef=ref(null),icoIndicatorRightOnRef=ref(null),icoLightsOffRef=ref(null),icoLightsOnRef=ref(null),icoLightsHighRef=ref(null),layer3Ref=ref(null),layer4Ref=ref(null),layer6Ref=ref(null),layer7Ref=ref(null),layer10Ref=ref(null),layer11Ref=ref(null),layer12Ref=ref(null),tickLayerRef=ref(null),speedUnitTextRef=ref(null),rpm_max=ref(8e3),rpmLegendTextRef=ref(null),revNeedleRef=ref(null),displayMode=ref(2);onMounted(()=>{rpmLegendTextRef?.value&&(rpmLegendTextRef.value.textContent=`x1000 RPM`),oilTempBarRef.value.style.strokeDasharray=oilTempBarLen.value+` `+oilTempBarLen.value,speedTextRef.value.textContent=``,revcurveRef.value.style.strokeDasharray=revCurveLen.value+` `+revCurveLen.value,fuelBarRef.value.style.strokeDasharray=fuelBarLen.value+` `+fuelBarLen.value,rpmTextGuideLineRef.value.style.display=`none`;for(let k=0;kisCareer=isActive)});function applyData(data$1){speedTextRef.value.textContent=data$1.speedtext,(speedTextRef.value.textContent==`-Infinity`||speedTextRef.value.textContent==`Infinity`)&&(speedTextRef.value.textContent=`-`),gearTextRef.value.textContent=data$1.geartext,fuelBarRef.value.style[`stroke-dashoffset`]=(1-data$1.fuel)*fuelBarLen.value;let fuelLow=data$1.fuel<.1,fuelGoneLow=lastFuelLevel>=.1&&fuelLow;lastFuelLevel=data$1.fuel,fuelWarnIcoOffRef.value.style.visibility=fuelLow?`hidden`:`visible`,fuelWarnIcoOnRef.value.style.visibility=fuelLow?`visible`:`hidden`,data$1.ignition&&isCareer&&fuelGoneLow&&!shouldPlayFuelLowSound&&setTimeout(()=>shouldPlayFuelLowSound=!0,0),shouldPlayFuelLowSound&&!lowFuelSoundPlayed&&(lowFuelSoundPlayed=!0,Lua_default.ui_audio.playEventSound(`bng_career_fuel`,`low_fuel`)),icoHandBrakeOffRef.value.style.visibility=data$1.parkingBrake?`hidden`:`visible`,icoHandBrakeOnRef.value.style.visibility=data$1.parkingBrake?`visible`:`hidden`,icoABSOffRef.value.style.visibility=data$1.absWorking?`hidden`:`visible`,icoABSOnRef.value.style.visibility=data$1.absWorking?`visible`:`hidden`,icoIndicatorLeftOffRef.value.style.visibility=data$1.signalL?`hidden`:`visible`,icoIndicatorLeftOnRef.value.style.visibility=data$1.signalL?`visible`:`hidden`,icoIndicatorRightOffRef.value.style.visibility=data$1.signalR?`hidden`:`visible`,icoIndicatorRightOnRef.value.style.visibility=data$1.signalR?`visible`:`hidden`;let tempNormalized=Math.max(Math.min((data$1.waterTemp-50)/80,1),0);oilTempBarRef.value.style.strokeDashoffset=(1+tempNormalized)*oilTempBarLen.value;let oilTemp_warn=tempNormalized>.8125;if(oilTempIcoOffRef.value.style.visibility=oilTemp_warn?`hidden`:`visible`,oilTempIcoOnRef.value.style.visibility=oilTemp_warn?`visible`:`hidden`,data$1.lowBeam!==void 0&&data$1.highBeam!==void 0){let nb=!0,lb=data$1.lowBeam>.9,hb=data$1.highBeam>.9;lb&&(nb=!1),hb&&(nb=!1),icoLightsOffRef.value.style.visibility=nb?`visible`:`hidden`,icoLightsOnRef.value.style.visibility=lb?`visible`:`hidden`,icoLightsHighRef.value.style.visibility=hb?`visible`:`hidden`}else icoLightsOffRef.value.style.visibility=`hidden`,icoLightsOnRef.value.style.visibility=`hidden`,icoLightsHighRef.value.style.visibility=`hidden`;let rpm_rotation=data$1.rpm*270-180;rpm_rotation<-180&&(rpm_rotation=-180),rpm_rotation>90&&(rpm_rotation=90),revNeedleRef.value.setAttribute(`transform`,`rotate(`+rpm_rotation+`,330,330)`);let revCurveOffset=(1-data$1.rpm)*revCurveLen.value;revCurveOffset<0&&(revCurveOffset=0),revCurveOffset>revCurveLen.value&&(revCurveOffset=revCurveLen.value),revcurveRef.value.style.strokeDashoffset=revCurveOffset}let data=ref({}),layersVisible=!1;function setlayersVisible(v){if(layersVisible!=v){let val=v?`inline`:`none`;layer3Ref.value.style.display=val,layer4Ref.value.style.display=val,layer6Ref.value.style.display=val,layer7Ref.value.style.display=val,layer10Ref.value.style.display=val,layer11Ref.value.style.display=val,layer12Ref.value.style.display=val,tickLayerRef.value.style.display=val,layersVisible=v}}function reset$1(){setlayersVisible(!1),initialized.value=!1;for(let k=0;k=0?1:-1,inx=nx*sign,iny=ny*sign,x1=pt.x+inx*tickInnerOffset,y1=pt.y+iny*tickInnerOffset,x2=x1+inx*tickMarkLength,y2=y1+iny*tickMarkLength;line.setAttribute(`x1`,x1),line.setAttribute(`y1`,y1),line.setAttribute(`x2`,x2),line.setAttribute(`y2`,y2),line.style.visibility=`visible`}}for(let k=dashCount$1+1;k<=maxRpmTexts;k++){let rp=rpmTextRefs.value[k];rp&&(rp.style.visibility=`hidden`);let line=tickMarkRefs.value[k];line&&(line.style.visibility=`hidden`)}initialized.value=!0}if(!isStreamValid)return!1;if(setlayersVisible(!0),displayMode.value==2)streams.electrics.wheelspeed?(data.speedtext=UnitSpeed(streams.electrics.wheelspeed),streams.electrics.wheelspeed>9e3&&(speedUnitTextRef.value.textContent=`brrrr`)):streams.electrics.airspeed&&(data.speedtext=UnitSpeed(streams.electrics.airspeed)),(function(){if(streams.engineInfo[13]==`manual`){let gear=streams.engineInfo[5],gearStr=gear.toString();gear==0?gearStr=`N`:gear==-1?gearStr=`R`:-gear>1&&(gearStr=`R`+-gear),data.geartext=gearStr}else data.geartext=[`P`,`R`,`N`,`D`,`2`,`1`][Math.round(streams.electrics.gear_A*5)]})(),data.fuel=streams.engineInfo[11]/streams.engineInfo[12],data.parkingBrake=streams.electrics.parkingbrake,data.absWorking=streams.electrics.abs,data.signalL=streams.electrics.signal_L,data.signalR=streams.electrics.signal_R,data.waterTemp=streams.electrics.watertemp,data.lowBeam=streams.electrics.lowbeam,data.highBeam=streams.electrics.highbeam,data.rpm=(streams.electrics.rpmTacho||0)/rpm_max.value;else if(displayMode.value==0){testVar+=.04,testVar>1&&(testVar=1),data.speedtext=Math.round(testVar*100),data.geartext=Math.round(testVar*5),data.fuel=testVar;let boolTest=!0;data.parkingBrake=!0,data.absWorking=!0,data.signalL=!0,data.signalR=!0,data.oilTemp=testVar,data.lowBeam=!0,data.highBeam=!1,data.rpm=testVar,testVar>=1&&(testVar=0,displayMode.value=1)}else if(displayMode.value==1){streams.electrics.wheelspeed?data.speedtext=UnitSpeed(streams.electrics.wheelspeed):(data.speedtext=``,speedUnitTextRef.value.textContent=``),(function(){let gear=streams.engineInfo[5],gearStr=gear.toString();gear==0?gearStr=`N`:gear==-1&&(gearStr=`R`),data.geartext=gearStr})(),data.parkingBrake=streams.electrics.parkingbrake,data.absWorking=streams.electrics.abs,data.signalL=streams.electrics.signal_L,data.signalR=streams.electrics.signal_R,data.lowBeam=streams.electrics.lowbeam,data.highBeam=streams.electrics.highbeam;let oilok=Math.abs(data.oilTemp-streams.electrics.oiltemp)<.005;oilok||(data.oilTemp+=(streams.electrics.oiltemp-data.oilTemp)*.2);let rpmperc=streams.electrics.rpm/rpm_max.value,rpmok=Math.abs(data.rpm-rpmperc)<.005;rpmok||(data.rpm+=(rpmperc-data.rpm)*.2);let fuelperc=streams.engineInfo[11]/streams.engineInfo[12],fuelok=Math.abs(data.fuel-fuelperc)<.005;fuelok||(data.fuel+=(fuelperc-data.fuel)*.2),oilok&&rpmok&&fuelok&&(displayMode.value=2)}return data.engineRunning=streams.electrics.engineRunning,data.ignition=streams.electrics.ignition,applyData(data),!0}function vehicleChanged(){initialized.value=!1}let UiUnitscallback=ref(()=>null);function UnitSpeed(val){let convertedVal=UiUnitscallback.value(val,`speed`);return speedUnitTextRef.value.textContent=convertedVal.unit,Math.round(convertedVal.val)}function wireThroughUnitSystem(callback){UiUnitscallback.value=callback}return __expose({wireThroughUnitSystem,update:update$6,vehicleChanged}),(_ctx,_cache)=>(openBlock(),createElementBlock(`svg`,_hoisted_1$160,[_cache[17]||=createBaseVNode(`defs`,{id:`defs4`},[createBaseVNode(`linearGradient`,{id:`linearGradient3938`},[createBaseVNode(`stop`,{style:{"stop-color":`#ff0000`,"stop-opacity":`1`},offset:`0`,id:`stop3940`}),createBaseVNode(`stop`,{style:{"stop-color":`#00ff4b`,"stop-opacity":`1`},offset:`1`,id:`stop3942`})]),createBaseVNode(`linearGradient`,{id:`linearGradient4607`},[createBaseVNode(`stop`,{id:`stop4609`,offset:`0`,style:{"stop-color":`#e40000`,"stop-opacity":`1`}}),createBaseVNode(`stop`,{style:{"stop-color":`#e40000`,"stop-opacity":`1`},offset:`0.89960396`,id:`stop4611`}),createBaseVNode(`stop`,{id:`stop4613`,offset:`1`,style:{"stop-color":`#e40000`,"stop-opacity":`0`}}),createBaseVNode(`stop`,{id:`stop4615`,offset:`1`,style:{"stop-color":`#e40000`,"stop-opacity":`0`}})]),createBaseVNode(`linearGradient`,{id:`linearGradient4597`},[createBaseVNode(`stop`,{id:`stop4599`,offset:`0`,style:{"stop-color":`#e40000`,"stop-opacity":`1`}}),createBaseVNode(`stop`,{style:{"stop-color":`#e40000`,"stop-opacity":`1`},offset:`0.99812102`,id:`stop4601`}),createBaseVNode(`stop`,{id:`stop4603`,offset:`1`,style:{"stop-color":`#e40000`,"stop-opacity":`0`}}),createBaseVNode(`stop`,{id:`stop4605`,offset:`1`,style:{"stop-color":`#e40000`,"stop-opacity":`1`}})]),createBaseVNode(`linearGradient`,{id:`linearGradient4545`},[createBaseVNode(`stop`,{style:{"stop-color":`#e40000`,"stop-opacity":`1`},offset:`0`,id:`stop4547`}),createBaseVNode(`stop`,{id:`stop4553`,offset:`0.9861111`,style:{"stop-color":`#e40000`,"stop-opacity":`1`}}),createBaseVNode(`stop`,{style:{"stop-color":`#e40000`,"stop-opacity":`0`},offset:`1`,id:`stop4555`}),createBaseVNode(`stop`,{style:{"stop-color":`#e40000`,"stop-opacity":`0`},offset:`1`,id:`stop4549`})]),createBaseVNode(`linearGradient`,{id:`linearGradient4256`},[createBaseVNode(`stop`,{style:{"stop-color":`#6d0000`,"stop-opacity":`1`},offset:`0`,id:`stop4258`}),createBaseVNode(`stop`,{style:{"stop-color":`#6d0000`,"stop-opacity":`0`},offset:`1`,id:`stop4260`})]),createBaseVNode(`linearGradient`,{id:`linearGradient4365`},[createBaseVNode(`stop`,{style:{"stop-color":`#000000`,"stop-opacity":`0.42857143`},offset:`0`,id:`stop4367`}),createBaseVNode(`stop`,{id:`stop4373`,offset:`0.5`,style:{"stop-color":`#000000`,"stop-opacity":`0.33035713`}}),createBaseVNode(`stop`,{style:{"stop-color":`#000000`,"stop-opacity":`0`},offset:`1`,id:`stop4369`})]),createBaseVNode(`linearGradient`,{id:`linearGradient4357`},[createBaseVNode(`stop`,{style:{"stop-color":`#000000`,"stop-opacity":`1`},offset:`0`,id:`stop4359`}),createBaseVNode(`stop`,{style:{"stop-color":`#000000`,"stop-opacity":`0.19642857`},offset:`1`,id:`stop4361`})]),createBaseVNode(`marker`,{style:{overflow:`visible`},id:`DistanceStart`,refX:`0`,refY:`0`,orient:`auto`},[createBaseVNode(`g`,{id:`g2300`},[createBaseVNode(`path`,{style:{fill:`none`,stroke:`#ffffff`,"stroke-width":`1.14999998`,"stroke-linecap":`square`},d:`M 0,0 2,0`,id:`path2306`}),createBaseVNode(`path`,{style:{fill:`#000000`,"fill-rule":`evenodd`,stroke:`none`},d:`M 0,0 13,4 9,0 13,-4 0,0 z`,id:`path2302`}),createBaseVNode(`path`,{style:{fill:`none`,stroke:`#000000`,"stroke-width":`1`,"stroke-linecap":`square`},d:`M 0,-4 0,40`,id:`path2304`})])]),createBaseVNode(`radialGradient`,{"xlink:href":`#linearGradient4357`,id:`radialGradient4363`,cx:`480`,cy:`544`,fx:`480`,fy:`544`,r:`320`,gradientUnits:`userSpaceOnUse`,gradientTransform:`matrix(1.03125,0,0,1.03125,-15,-17)`}),createBaseVNode(`radialGradient`,{"xlink:href":`#linearGradient4365`,id:`radialGradient4371`,cx:`480`,cy:`544`,fx:`480`,fy:`544`,r:`320`,gradientUnits:`userSpaceOnUse`}),createBaseVNode(`clipPath`,{clipPathUnits:`userSpaceOnUse`,id:`clipPath4407`},[createBaseVNode(`path`,{id:`path4409`,d:`m 480,-103.33 c -357.5105,0 -647.33,289.8195 -647.33,647.33 0,357.5105 289.8195,647.33 647.33,647.33 357.5105,0 647.33,-289.8195 647.33,-647.33 0,-357.5105 -289.8195,-647.33 -647.33,-647.33 z m 0,453.131 c 107.25316,0 194.199,86.94584 194.199,194.199 0,107.25316 -86.94584,194.199 -194.199,194.199 -107.25316,0 -194.199,-86.94584 -194.199,-194.199 0,-107.25316 86.94584,-194.199 194.199,-194.199 z`,style:{color:`#000000`,fill:`#ffffff`,"fill-opacity":`0.61375661`,"fill-rule":`nonzero`,stroke:`none`,"stroke-width":`16`,marker:`none`,visibility:`visible`,display:`inline`,overflow:`visible`,"enable-background":`accumulate`}})]),createBaseVNode(`clipPath`,{clipPathUnits:`userSpaceOnUse`,id:`clipPath4321-9`},[createBaseVNode(`path`,{style:{color:`#000000`,fill:`#ffffff`,"fill-opacity":`1`,"fill-rule":`nonzero`,stroke:`none`,"stroke-width":`5`,marker:`none`,visibility:`visible`,display:`inline`,overflow:`visible`,"enable-background":`accumulate`},d:`m 480,224 c -20.28024,0 -40.11069,1.89279 -59.34375,5.5 l 12.0625,58.8125 C 448.05208,285.49499 463.85489,284 480,284 c 35.52728,0 69.40254,7.13112 100.25,20.03125 l 24.1875,-54.9375 C 566.18747,232.93508 524.13347,224 480,224 z m -69.0625,7.5 c -59.26533,13.0371 -112.35258,42.49901 -154.28125,83.375 l 42.53125,42.3125 c 24.37935,-23.60266 53.35266,-42.49216 85.46875,-55.15625 1.96795,-0.77601 3.94641,-1.52096 5.9375,-2.25 10.51172,-3.84886 21.33856,-7.01901 32.4375,-9.5 L 410.9375,231.5 z M 613.5,253.125 589.3125,308.03125 c 44.07702,20.45389 81.43119,52.91567 107.9375,93.15625 l 50.875,-31.875 C 715.25578,318.96815 668.59379,278.45303 613.5,253.125 z m -363.8125,68.75 c -41.23795,42.75016 -70.70543,96.92973 -83.125,157.34375 l 59.03125,11.0625 c 10.15322,-48.33557 33.70357,-91.7229 66.625,-126.09375 L 249.6875,321.875 z m 503.78125,55.8125 -50.90625,31.84375 C 726.31882,448.76688 740,494.78478 740,544 l 60,0 c 0,-60.90677 -16.99384,-117.84887 -46.53125,-166.3125 z m -588.75,111.25 C 161.61652,506.82573 160,525.2248 160,544 c 0,42.78463 8.42108,83.60181 23.65625,120.90625 L 238.84375,641.375 C 226.69144,611.30216 220,578.42944 220,544 c 0,-2.24366 0.0373,-4.48871 0.0937,-6.71875 0.3211,-12.67426 1.55282,-25.12039 3.625,-37.28125 l -59,-11.0625 z M 242.75,650.5 187.53125,674 c 23.4008,52.56805 60.5346,97.67196 106.875,130.71875 l 34.0625,-49.4375 C 291.42063,728.66516 261.6562,692.55546 242.75,650.5 z m 93.875,110.40625 -34.03125,49.40625 C 353.37348,844.20872 414.36502,864 480,864 l 0,-60 c -33.65485,0 -65.82451,-6.39115 -95.34375,-18.03125 -1.96795,-0.77601 -3.93088,-1.58396 -5.875,-2.40625 -14.80462,-6.26183 -28.90394,-13.88046 -42.15625,-22.65625 z`,id:`path4323-8`,"inkscape:connector-curvature":`0`})]),createBaseVNode(`radialGradient`,{"xlink:href":`#linearGradient4357`,id:`radialGradient4363-9`,cx:`480`,cy:`544`,fx:`480`,fy:`544`,r:`320`,gradientUnits:`userSpaceOnUse`,gradientTransform:`matrix(1.03125,0,0,1.03125,-15,-17)`}),createBaseVNode(`clipPath`,{clipPathUnits:`userSpaceOnUse`,id:`clipPath4407-3`},[createBaseVNode(`path`,{id:`path4409-5`,d:`m 480,-103.33 c -357.5105,0 -647.33,289.8195 -647.33,647.33 0,357.5105 289.8195,647.33 647.33,647.33 357.5105,0 647.33,-289.8195 647.33,-647.33 0,-357.5105 -289.8195,-647.33 -647.33,-647.33 z m 0,453.131 c 107.25316,0 194.199,86.94584 194.199,194.199 0,107.25316 -86.94584,194.199 -194.199,194.199 -107.25316,0 -194.199,-86.94584 -194.199,-194.199 0,-107.25316 86.94584,-194.199 194.199,-194.199 z`,style:{color:`#000000`,fill:`#ffffff`,"fill-opacity":`0.61375661`,"fill-rule":`nonzero`,stroke:`none`,"stroke-width":`16`,marker:`none`,visibility:`visible`,display:`inline`,overflow:`visible`,"enable-background":`accumulate`}})]),createBaseVNode(`radialGradient`,{gradientTransform:`matrix(0.37015162,0,0,0.37015162,685.90181,-270.76027)`,"xlink:href":`#linearGradient4365`,id:`radialGradient4371-4`,cx:`480`,cy:`544`,fx:`480`,fy:`544`,r:`320`,gradientUnits:`userSpaceOnUse`}),createBaseVNode(`linearGradient`,{"xlink:href":`#linearGradient4256`,id:`linearGradient4433`,gradientUnits:`userSpaceOnUse`,x1:`569.20557`,y1:`424.29861`,x2:`890.55139`,y2:`424.29861`}),createBaseVNode(`clipPath`,{clipPathUnits:`userSpaceOnUse`,id:`clipPath4321-4`},[createBaseVNode(`path`,{style:{color:`#000000`,fill:`#ffffff`,"fill-opacity":`1`,"fill-rule":`nonzero`,stroke:`none`,"stroke-width":`5`,marker:`none`,visibility:`visible`,display:`inline`,overflow:`visible`,"enable-background":`accumulate`},d:`m 480,224 c -20.28024,0 -40.11069,1.89279 -59.34375,5.5 l 12.0625,58.8125 C 448.05208,285.49499 463.85489,284 480,284 c 35.52728,0 69.40254,7.13112 100.25,20.03125 l 24.1875,-54.9375 C 566.18747,232.93508 524.13347,224 480,224 z m -69.0625,7.5 c -59.26533,13.0371 -112.35258,42.49901 -154.28125,83.375 l 42.53125,42.3125 c 24.37935,-23.60266 53.35266,-42.49216 85.46875,-55.15625 1.96795,-0.77601 3.94641,-1.52096 5.9375,-2.25 10.51172,-3.84886 21.33856,-7.01901 32.4375,-9.5 L 410.9375,231.5 z M 613.5,253.125 589.3125,308.03125 c 44.07702,20.45389 81.43119,52.91567 107.9375,93.15625 l 50.875,-31.875 C 715.25578,318.96815 668.59379,278.45303 613.5,253.125 z m -363.8125,68.75 c -41.23795,42.75016 -70.70543,96.92973 -83.125,157.34375 l 59.03125,11.0625 c 10.15322,-48.33557 33.70357,-91.7229 66.625,-126.09375 L 249.6875,321.875 z m 503.78125,55.8125 -50.90625,31.84375 C 726.31882,448.76688 740,494.78478 740,544 l 60,0 c 0,-60.90677 -16.99384,-117.84887 -46.53125,-166.3125 z m -588.75,111.25 C 161.61652,506.82573 160,525.2248 160,544 c 0,42.78463 8.42108,83.60181 23.65625,120.90625 L 238.84375,641.375 C 226.69144,611.30216 220,578.42944 220,544 c 0,-2.24366 0.0373,-4.48871 0.0937,-6.71875 0.3211,-12.67426 1.55282,-25.12039 3.625,-37.28125 l -59,-11.0625 z M 242.75,650.5 187.53125,674 c 23.4008,52.56805 60.5346,97.67196 106.875,130.71875 l 34.0625,-49.4375 C 291.42063,728.66516 261.6562,692.55546 242.75,650.5 z m 93.875,110.40625 -34.03125,49.40625 C 353.37348,844.20872 414.36502,864 480,864 l 0,-60 c -33.65485,0 -65.82451,-6.39115 -95.34375,-18.03125 -1.96795,-0.77601 -3.93088,-1.58396 -5.875,-2.40625 -14.80462,-6.26183 -28.90394,-13.88046 -42.15625,-22.65625 z`,id:`path4323-7`,"inkscape:connector-curvature":`0`})]),createBaseVNode(`radialGradient`,{"xlink:href":`#linearGradient4357`,id:`radialGradient4363-5`,cx:`480`,cy:`544`,fx:`480`,fy:`544`,r:`320`,gradientUnits:`userSpaceOnUse`,gradientTransform:`matrix(1.03125,0,0,1.03125,-15,-17)`}),createBaseVNode(`clipPath`,{clipPathUnits:`userSpaceOnUse`,id:`clipPath4407-6`},[createBaseVNode(`path`,{id:`path4409-1`,d:`m 480,-103.33 c -357.5105,0 -647.33,289.8195 -647.33,647.33 0,357.5105 289.8195,647.33 647.33,647.33 357.5105,0 647.33,-289.8195 647.33,-647.33 0,-357.5105 -289.8195,-647.33 -647.33,-647.33 z m 0,453.131 c 107.25316,0 194.199,86.94584 194.199,194.199 0,107.25316 -86.94584,194.199 -194.199,194.199 -107.25316,0 -194.199,-86.94584 -194.199,-194.199 0,-107.25316 86.94584,-194.199 194.199,-194.199 z`,style:{color:`#000000`,fill:`#ffffff`,"fill-opacity":`0.61375661`,"fill-rule":`nonzero`,stroke:`none`,"stroke-width":`16`,marker:`none`,visibility:`visible`,display:`inline`,overflow:`visible`,"enable-background":`accumulate`}})]),createBaseVNode(`radialGradient`,{gradientTransform:`matrix(0.36968813,0,0,0.36968813,1026.9451,-270.68256)`,"xlink:href":`#linearGradient4365`,id:`radialGradient4371-49`,cx:`480`,cy:`544`,fx:`480`,fy:`544`,r:`320`,gradientUnits:`userSpaceOnUse`}),createBaseVNode(`linearGradient`,{"xlink:href":`#linearGradient4256`,id:`linearGradient4746`,gradientUnits:`userSpaceOnUse`,x1:`569.20557`,y1:`424.29861`,x2:`890.55139`,y2:`424.29861`}),createBaseVNode(`clipPath`,{clipPathUnits:`userSpaceOnUse`,id:`clipPath3921`},[createBaseVNode(`path`,{"inkscape:connector-curvature":`0`,id:`path3923`,d:`m 480,224 c -20.95323,0 -41.43416,2.01857 -61.26367,5.86328 l 12.08008,58.80274 C 446.74495,285.61583 463.18224,284 480,284 c 36.22419,0 70.7135,7.41519 102.04492,20.79883 l 24.1836,-54.92188 C 567.49749,233.23259 524.82925,224 480,224 z m -67.13867,7.07812 c -60.69914,12.96113 -115.01734,43.12659 -157.60938,85.15821 l 42.54297,42.3125 c 34.42536,-33.82645 78.22177,-58.13556 127.14258,-68.68555 l -12.07617,-58.78516 z m 198.86328,21.20508 -24.1875,54.9336 c 45.44422,20.67199 83.88358,54.04459 110.80078,95.58008 l 50.87305,-31.84376 C 715.93577,319.29347 668.20331,277.82636 611.72461,252.2832 z m -360.70117,68.21094 c -42.37565,43.40627 -72.5223,98.80082 -84.8418,160.63281 l 58.99024,11.05664 c 10.06229,-49.7524 34.33605,-94.34359 68.39257,-129.3789 l -42.54101,-42.31055 z m 501.3789,55.54102 -50.86132,31.83398 C 725.92383,447.46544 740,494.08649 740,544 l 60,0 C 800,482.39079 782.57195,424.85952 752.40234,376.03516 z M 165.06055,487.02148 C 161.7373,505.51211 160,524.55271 160,544 c 0,43.47625 8.68492,84.91949 24.39062,122.71094 l 55.21485,-23.5293 C 226.98058,612.61583 220,579.12541 220,544 c 0,-15.6701 1.38639,-31.01527 4.04297,-45.92188 l -58.98242,-11.05664 z m 76.90039,161.67774 -55.20899,23.52734 c 23.61428,53.92719 61.65397,100.09134 109.25586,133.60352 l 34.03516,-49.41406 C 291.73258,729.3212 261.08736,692.12046 241.96094,648.69922 z m 93.01953,111.12695 -34.04102,49.42188 C 352.04051,843.81227 413.66249,864 480,864 l 0,-60 c -53.69777,0 -103.59151,-16.28243 -145.01953,-44.17383 z`,style:{color:`#000000`,fill:`#ffffff`,"fill-opacity":`1`,"fill-rule":`nonzero`,stroke:`none`,"stroke-width":`5`,marker:`none`,visibility:`visible`,display:`inline`,overflow:`visible`,"enable-background":`accumulate`}})]),createBaseVNode(`clipPath`,{clipPathUnits:`userSpaceOnUse`,id:`clipPath3925-1`},[createBaseVNode(`path`,{"inkscape:connector-curvature":`0`,id:`path3927-7`,d:`m 330,10 c -20.95323,0 -41.43416,2.01857 -61.26367,5.86328 l 12.08008,58.80274 C 296.74495,71.61583 313.18224,70 330,70 c 36.22419,0 70.7135,7.41519 102.04492,20.79883 l 24.1836,-54.92188 C 417.49749,19.23259 374.82925,10 330,10 z m -67.13867,7.07812 C 202.16219,30.03925 147.84399,60.20471 105.25195,102.23633 l 42.54297,42.3125 C 182.22028,110.72238 226.01669,86.41327 274.9375,75.86328 L 262.86133,17.07812 z m 198.86328,21.20508 -24.1875,54.9336 c 45.44422,20.67199 83.88358,54.04459 110.80078,95.58008 l 50.87305,-31.84376 C 565.93577,105.29347 518.20331,63.82636 461.72461,38.2832 z m -360.70117,68.21094 c -42.37565,43.40627 -72.5223,98.80082 -84.8418,160.63281 l 58.99024,11.05664 c 10.06229,-49.7524 34.33605,-94.34359 68.39257,-129.3789 l -42.54101,-42.31055 z m 501.3789,55.54102 -50.86132,31.83398 C 575.92383,233.46544 590,280.08649 590,330 l 60,0 C 650,268.39079 632.57195,210.85952 602.40234,162.03516 z M 15.06055,273.02148 C 11.7373,291.51211 10,310.55271 10,330 c 0,43.47625 8.68492,84.91949 24.39062,122.71094 l 55.21485,-23.5293 C 76.98058,398.61583 70,365.12541 70,330 c 0,-15.6701 1.38639,-31.01527 4.04297,-45.92188 L 15.06055,273.02148 z m 76.90039,161.67774 -55.20899,23.52734 c 23.61428,53.92719 61.65397,100.09134 109.25586,133.60352 l 34.03516,-49.41406 C 141.73258,515.3212 111.08736,478.12046 91.96094,434.69922 z m 93.01953,111.12695 -34.04102,49.42188 C 202.04051,629.81227 263.66249,650 330,650 l 0,-60 c -53.69777,0 -103.59151,-16.28243 -145.01953,-44.17383 z`,style:{color:`#000000`,fill:`#ffffff`,"fill-opacity":`1`,"fill-rule":`nonzero`,stroke:`none`,"stroke-width":`5`,marker:`none`,visibility:`visible`,display:`inline`,overflow:`visible`,"enable-background":`accumulate`}})]),createBaseVNode(`clipPath`,{clipPathUnits:`userSpaceOnUse`,id:`clipPath4036`},[createBaseVNode(`path`,{style:{color:`#000000`,fill:`#ffffff`,"fill-opacity":`1`,"fill-rule":`nonzero`,stroke:`none`,"stroke-width":`5`,marker:`none`,visibility:`visible`,display:`inline`,overflow:`visible`,"enable-background":`accumulate`},d:`m 480,224 c -20.95323,0 -41.43416,2.01857 -61.26367,5.86328 l 12.08008,58.80274 C 446.74495,285.61583 463.18224,284 480,284 c 36.22419,0 70.7135,7.41519 102.04492,20.79883 l 24.1836,-54.92188 C 567.49749,233.23259 524.82925,224 480,224 z m -67.13867,7.07812 c -60.69914,12.96113 -115.01734,43.12659 -157.60938,85.15821 l 42.54297,42.3125 c 34.42536,-33.82645 78.22177,-58.13556 127.14258,-68.68555 l -12.07617,-58.78516 z m 198.86328,21.20508 -24.1875,54.9336 c 45.44422,20.67199 83.88358,54.04459 110.80078,95.58008 l 50.87305,-31.84376 C 715.93577,319.29347 668.20331,277.82636 611.72461,252.2832 z m -360.70117,68.21094 c -42.37565,43.40627 -72.5223,98.80082 -84.8418,160.63281 l 58.99024,11.05664 c 10.06229,-49.7524 34.33605,-94.34359 68.39257,-129.3789 l -42.54101,-42.31055 z m 501.3789,55.54102 -50.86132,31.83398 C 725.92383,447.46544 740,494.08649 740,544 l 60,0 C 800,482.39079 782.57195,424.85952 752.40234,376.03516 z M 165.06055,487.02148 C 161.7373,505.51211 160,524.55271 160,544 c 0,43.47625 8.68492,84.91949 24.39062,122.71094 l 55.21485,-23.5293 C 226.98058,612.61583 220,579.12541 220,544 c 0,-15.6701 1.38639,-31.01527 4.04297,-45.92188 l -58.98242,-11.05664 z m 76.90039,161.67774 -55.20899,23.52734 c 23.61428,53.92719 61.65397,100.09134 109.25586,133.60352 l 34.03516,-49.41406 C 291.73258,729.3212 261.08736,692.12046 241.96094,648.69922 z m 93.01953,111.12695 -34.04102,49.42188 C 352.04051,843.81227 413.66249,864 480,864 l 0,-60 c -53.69777,0 -103.59151,-16.28243 -145.01953,-44.17383 z`,id:`path4038`,"inkscape:connector-curvature":`0`})]),createBaseVNode(`linearGradient`,{"inkscape:collect":`always`,"xlink:href":`#linearGradient4545`,id:`linearGradient4551`,x1:`480`,y1:`214`,x2:`480`,y2:`474`,gradientUnits:`userSpaceOnUse`}),createBaseVNode(`linearGradient`,{"inkscape:collect":`always`,"xlink:href":`#linearGradient4545-2`,id:`linearGradient4551-8`,x1:`480`,y1:`214`,x2:`480`,y2:`474`,gradientUnits:`userSpaceOnUse`}),createBaseVNode(`linearGradient`,{id:`linearGradient4545-2`},[createBaseVNode(`stop`,{style:{"stop-color":`#e40000`,"stop-opacity":`1`},offset:`0`,id:`stop4547-4`}),createBaseVNode(`stop`,{id:`stop4553-5`,offset:`0.99000001`,style:{"stop-color":`#e40000`,"stop-opacity":`0`}}),createBaseVNode(`stop`,{style:{"stop-color":`#000000`,"stop-opacity":`0`},offset:`1`,id:`stop4555-5`}),createBaseVNode(`stop`,{style:{"stop-color":`#000000`,"stop-opacity":`0`},offset:`1`,id:`stop4549-1`})]),createBaseVNode(`linearGradient`,{y2:`282.59341`,x2:`474.60886`,y1:`211.1199`,x1:`480`,gradientUnits:`userSpaceOnUse`,id:`linearGradient4574`,"xlink:href":`#linearGradient4607`,"inkscape:collect":`always`,gradientTransform:`matrix(1,0,0,0.9882541,0,10.359887)`}),createBaseVNode(`clipPath`,{clipPathUnits:`userSpaceOnUse`,id:`clipPath4036-1`},[createBaseVNode(`path`,{style:{color:`#000000`,fill:`#ffffff`,"fill-opacity":`1`,"fill-rule":`nonzero`,stroke:`none`,"stroke-width":`5`,marker:`none`,visibility:`visible`,display:`inline`,overflow:`visible`,"enable-background":`accumulate`},d:`m 480,224 c -20.95323,0 -41.43416,2.01857 -61.26367,5.86328 l 12.08008,58.80274 C 446.74495,285.61583 463.18224,284 480,284 c 36.22419,0 70.7135,7.41519 102.04492,20.79883 l 24.1836,-54.92188 C 567.49749,233.23259 524.82925,224 480,224 z m -67.13867,7.07812 c -60.69914,12.96113 -115.01734,43.12659 -157.60938,85.15821 l 42.54297,42.3125 c 34.42536,-33.82645 78.22177,-58.13556 127.14258,-68.68555 l -12.07617,-58.78516 z m 198.86328,21.20508 -24.1875,54.9336 c 45.44422,20.67199 83.88358,54.04459 110.80078,95.58008 l 50.87305,-31.84376 C 715.93577,319.29347 668.20331,277.82636 611.72461,252.2832 z m -360.70117,68.21094 c -42.37565,43.40627 -72.5223,98.80082 -84.8418,160.63281 l 58.99024,11.05664 c 10.06229,-49.7524 34.33605,-94.34359 68.39257,-129.3789 l -42.54101,-42.31055 z m 501.3789,55.54102 -50.86132,31.83398 C 725.92383,447.46544 740,494.08649 740,544 l 60,0 C 800,482.39079 782.57195,424.85952 752.40234,376.03516 z M 165.06055,487.02148 C 161.7373,505.51211 160,524.55271 160,544 c 0,43.47625 8.68492,84.91949 24.39062,122.71094 l 55.21485,-23.5293 C 226.98058,612.61583 220,579.12541 220,544 c 0,-15.6701 1.38639,-31.01527 4.04297,-45.92188 l -58.98242,-11.05664 z m 76.90039,161.67774 -55.20899,23.52734 c 23.61428,53.92719 61.65397,100.09134 109.25586,133.60352 l 34.03516,-49.41406 C 291.73258,729.3212 261.08736,692.12046 241.96094,648.69922 z m 93.01953,111.12695 -34.04102,49.42188 C 352.04051,843.81227 413.66249,864 480,864 l 0,-60 c -53.69777,0 -103.59151,-16.28243 -145.01953,-44.17383 z`,id:`path4038-7`,"inkscape:connector-curvature":`0`})]),createBaseVNode(`radialGradient`,{"xlink:href":`#linearGradient4357-0`,id:`radialGradient4363-4`,cx:`480`,cy:`544`,fx:`480`,fy:`544`,r:`320`,gradientUnits:`userSpaceOnUse`,gradientTransform:`matrix(1.03125,0,0,1.03125,-15,-17)`}),createBaseVNode(`linearGradient`,{id:`linearGradient4357-0`},[createBaseVNode(`stop`,{style:{"stop-color":`#000000`,"stop-opacity":`0.65178573`},offset:`0`,id:`stop4359-9`}),createBaseVNode(`stop`,{style:{"stop-color":`#000000`,"stop-opacity":`0.24107143`},offset:`1`,id:`stop4361-4`})]),createBaseVNode(`clipPath`,{clipPathUnits:`userSpaceOnUse`,id:`clipPath4407-8`},[createBaseVNode(`path`,{id:`path4409-8`,d:`m 480,-103.33 c -357.5105,0 -647.33,289.8195 -647.33,647.33 0,357.5105 289.8195,647.33 647.33,647.33 357.5105,0 647.33,-289.8195 647.33,-647.33 0,-357.5105 -289.8195,-647.33 -647.33,-647.33 z m 0,453.131 c 107.25316,0 194.199,86.94584 194.199,194.199 0,107.25316 -86.94584,194.199 -194.199,194.199 -107.25316,0 -194.199,-86.94584 -194.199,-194.199 0,-107.25316 86.94584,-194.199 194.199,-194.199 z`,style:{color:`#000000`,fill:`#ffffff`,"fill-opacity":`0.61375661`,"fill-rule":`nonzero`,stroke:`none`,"stroke-width":`16`,marker:`none`,visibility:`visible`,display:`inline`,overflow:`visible`,"enable-background":`accumulate`}})]),createBaseVNode(`radialGradient`,{"xlink:href":`#linearGradient4365-4`,id:`radialGradient4371-2`,cx:`480`,cy:`544`,fx:`480`,fy:`544`,r:`320`,gradientUnits:`userSpaceOnUse`}),createBaseVNode(`linearGradient`,{id:`linearGradient4365-4`},[createBaseVNode(`stop`,{style:{"stop-color":`#000000`,"stop-opacity":`0.42857143`},offset:`0`,id:`stop4367-5`}),createBaseVNode(`stop`,{id:`stop4373-5`,offset:`0.5`,style:{"stop-color":`#000000`,"stop-opacity":`0.33035713`}}),createBaseVNode(`stop`,{style:{"stop-color":`#000000`,"stop-opacity":`0`},offset:`1`,id:`stop4369-1`})]),createBaseVNode(`radialGradient`,{r:`320`,fy:`544`,fx:`480`,cy:`544`,cx:`480`,gradientUnits:`userSpaceOnUse`,id:`radialGradient3997`,"xlink:href":`#linearGradient4365-4`}),createBaseVNode(`radialGradient`,{"xlink:href":`#linearGradient4357-0-7`,id:`radialGradient4363-4-1`,cx:`480`,cy:`544`,fx:`480`,fy:`544`,r:`320`,gradientUnits:`userSpaceOnUse`,gradientTransform:`matrix(1.03125,0,0,1.03125,-15,-17)`}),createBaseVNode(`linearGradient`,{id:`linearGradient4357-0-7`},[createBaseVNode(`stop`,{style:{"stop-color":`#000000`,"stop-opacity":`0.51785713`},offset:`0`,id:`stop4359-9-4`}),createBaseVNode(`stop`,{style:{"stop-color":`#000000`,"stop-opacity":`0.11607143`},offset:`1`,id:`stop4361-4-0`})]),createBaseVNode(`radialGradient`,{r:`320`,fy:`544`,fx:`480`,cy:`544`,cx:`480`,gradientTransform:`matrix(1.03125,0,0,1.03125,-15,-17)`,gradientUnits:`userSpaceOnUse`,id:`radialGradient4001`,"xlink:href":`#linearGradient4357-0-7`}),createBaseVNode(`radialGradient`,{"xlink:href":`#linearGradient4357-0-7`,id:`radialGradient4040`,gradientUnits:`userSpaceOnUse`,gradientTransform:`matrix(1.03125,0,0,1.03125,-885,-231)`,cx:`480`,cy:`544`,fx:`480`,fy:`544`,r:`320`}),createBaseVNode(`radialGradient`,{"xlink:href":`#linearGradient4357-0-7`,id:`radialGradient4045`,gradientUnits:`userSpaceOnUse`,gradientTransform:`matrix(1.03125,0,0,1.03125,-885,-231)`,cx:`480`,cy:`544`,fx:`480`,fy:`544`,r:`320`}),createBaseVNode(`radialGradient`,{"inkscape:collect":`always`,"xlink:href":`#linearGradient4357-0-7-2`,id:`radialGradient4045-8`,gradientUnits:`userSpaceOnUse`,gradientTransform:`matrix(1.03125,0,0,1.03125,-885,-231)`,cx:`480`,cy:`544`,fx:`480`,fy:`544`,r:`320`}),createBaseVNode(`linearGradient`,{id:`linearGradient4357-0-7-2`},[createBaseVNode(`stop`,{style:{"stop-color":`#000000`,"stop-opacity":`0.51785713`},offset:`0`,id:`stop4359-9-4-4`}),createBaseVNode(`stop`,{style:{"stop-color":`#000000`,"stop-opacity":`0.11607143`},offset:`1`,id:`stop4361-4-0-5`})]),createBaseVNode(`radialGradient`,{r:`320`,fy:`544`,fx:`480`,cy:`544`,cx:`480`,gradientTransform:`matrix(1.03125,0,0,1.03125,-758.53125,-231)`,gradientUnits:`userSpaceOnUse`,id:`radialGradient4063`,"xlink:href":`#linearGradient4357-0-7-2`,"inkscape:collect":`always`}),createBaseVNode(`radialGradient`,{"inkscape:collect":`always`,"xlink:href":`#linearGradient4357-0-7`,id:`radialGradient4082`,gradientUnits:`userSpaceOnUse`,gradientTransform:`matrix(1.03125,0,0,1.03125,-885,-231)`,cx:`480`,cy:`544`,fx:`480`,fy:`544`,r:`320`}),createBaseVNode(`radialGradient`,{"inkscape:collect":`always`,"xlink:href":`#linearGradient4357-0-8`,id:`radialGradient4363-4-9`,cx:`480`,cy:`544`,fx:`480`,fy:`544`,r:`320`,gradientUnits:`userSpaceOnUse`,gradientTransform:`matrix(1.03125,0,0,1.03125,-15,-17)`}),createBaseVNode(`linearGradient`,{id:`linearGradient4357-0-8`},[createBaseVNode(`stop`,{style:{"stop-color":`#000000`,"stop-opacity":`0.51785713`},offset:`0`,id:`stop4359-9-40`}),createBaseVNode(`stop`,{style:{"stop-color":`#000000`,"stop-opacity":`0.11607143`},offset:`1`,id:`stop4361-4-7`})]),createBaseVNode(`radialGradient`,{r:`320`,fy:`544`,fx:`480`,cy:`544`,cx:`480`,gradientTransform:`matrix(1.03125,0,0,1.03125,-15,-17)`,gradientUnits:`userSpaceOnUse`,id:`radialGradient4031-1`,"xlink:href":`#linearGradient4357-0-8-5`,"inkscape:collect":`always`}),createBaseVNode(`linearGradient`,{id:`linearGradient4357-0-8-5`},[createBaseVNode(`stop`,{style:{"stop-color":`#000000`,"stop-opacity":`0.51785713`},offset:`0`,id:`stop4359-9-40-4`}),createBaseVNode(`stop`,{style:{"stop-color":`#000000`,"stop-opacity":`0.11607143`},offset:`1`,id:`stop4361-4-7-2`})]),createBaseVNode(`radialGradient`,{"inkscape:collect":`always`,"xlink:href":`#linearGradient4357-0-3`,id:`radialGradient4363-4-0`,cx:`480`,cy:`544`,fx:`480`,fy:`544`,r:`320`,gradientUnits:`userSpaceOnUse`,gradientTransform:`matrix(1.03125,0,0,1.03125,-15,-17)`}),createBaseVNode(`linearGradient`,{id:`linearGradient4357-0-3`},[createBaseVNode(`stop`,{style:{"stop-color":`#000000`,"stop-opacity":`0.65178573`},offset:`0`,id:`stop4359-9-8`}),createBaseVNode(`stop`,{style:{"stop-color":`#000000`,"stop-opacity":`0.24107143`},offset:`1`,id:`stop4361-4-01`})]),createBaseVNode(`clipPath`,{clipPathUnits:`userSpaceOnUse`,id:`clipPath4407-8-2`},[createBaseVNode(`path`,{"inkscape:connector-curvature":`0`,id:`path4409-8-5`,d:`m 480,-103.33 c -357.5105,0 -647.33,289.8195 -647.33,647.33 0,357.5105 289.8195,647.33 647.33,647.33 357.5105,0 647.33,-289.8195 647.33,-647.33 0,-357.5105 -289.8195,-647.33 -647.33,-647.33 z m 0,453.131 c 107.25316,0 194.199,86.94584 194.199,194.199 0,107.25316 -86.94584,194.199 -194.199,194.199 -107.25316,0 -194.199,-86.94584 -194.199,-194.199 0,-107.25316 86.94584,-194.199 194.199,-194.199 z`,style:{color:`#000000`,fill:`#ffffff`,"fill-opacity":`0.61375661`,"fill-rule":`nonzero`,stroke:`none`,"stroke-width":`16`,marker:`none`,visibility:`visible`,display:`inline`,overflow:`visible`,"enable-background":`accumulate`}})]),createBaseVNode(`radialGradient`,{r:`320`,fy:`544`,fx:`480`,cy:`544`,cx:`480`,gradientTransform:`matrix(1.03125,0,0,1.03125,-15,-17)`,gradientUnits:`userSpaceOnUse`,id:`radialGradient4401`,"xlink:href":`#linearGradient4357-0-3`,"inkscape:collect":`always`}),createBaseVNode(`radialGradient`,{r:`320`,fy:`544`,fx:`480`,cy:`544`,cx:`480`,gradientUnits:`userSpaceOnUse`,id:`radialGradient3997-4`,"xlink:href":`#linearGradient4365-4-7`,"inkscape:collect":`always`}),createBaseVNode(`linearGradient`,{id:`linearGradient4365-4-7`},[createBaseVNode(`stop`,{style:{"stop-color":`#000000`,"stop-opacity":`0.42857143`},offset:`0`,id:`stop4367-5-8`}),createBaseVNode(`stop`,{id:`stop4373-5-3`,offset:`0.5`,style:{"stop-color":`#000000`,"stop-opacity":`0.33035713`}}),createBaseVNode(`stop`,{style:{"stop-color":`#000000`,"stop-opacity":`0`},offset:`1`,id:`stop4369-1-5`})]),createBaseVNode(`radialGradient`,{r:`320`,fy:`544`,fx:`480`,cy:`544`,cx:`480`,gradientUnits:`userSpaceOnUse`,id:`radialGradient4458`,"xlink:href":`#linearGradient4365-4-7`,"inkscape:collect":`always`}),createBaseVNode(`clipPath`,{clipPathUnits:`userSpaceOnUse`,id:`clipPath4710`},[createBaseVNode(`path`,{style:{color:`#000000`,"font-style":`normal`,"font-variant":`normal`,"font-weight":`normal`,"font-stretch":`normal`,"font-size":`medium`,"line-height":`normal`,"font-family":`sans-serif`,"text-indent":`0`,"text-align":`start`,"text-decoration":`none`,"text-decoration-line":`none`,"text-decoration-style":`solid`,"text-decoration-color":`#000000`,"letter-spacing":`normal`,"word-spacing":`normal`,"text-transform":`none`,direction:`ltr`,"block-progression":`tb`,"writing-mode":`lr-tb`,"baseline-shift":`baseline`,"text-anchor":`start`,"white-space":`normal`,"clip-rule":`nonzero`,display:`inline`,overflow:`visible`,visibility:`visible`,opacity:`1`,isolation:`auto`,"mix-blend-mode":`normal`,"color-interpolation":`sRGB`,"color-interpolation-filters":`linearRGB`,"solid-color":`#000000`,"solid-opacity":`1`,fill:`#000000`,"fill-opacity":`1`,"fill-rule":`nonzero`,stroke:`none`,"stroke-width":`66.66205597`,"stroke-linecap":`butt`,"stroke-linejoin":`miter`,"stroke-miterlimit":`0.40000001`,"stroke-dasharray":`none`,"stroke-dashoffset":`0`,"stroke-opacity":`1`,"color-rendering":`auto`,"image-rendering":`auto`,"shape-rendering":`auto`,"text-rendering":`auto`,"enable-background":`accumulate`},d:`m 480,224 c -176.33633,0 -320,143.66367 -320,320 0,176.33633 143.66368,320 320,320 l 0,-66.66211 C 339.69052,797.33789 226.66211,684.30947 226.66211,544 226.66211,403.69051 339.69051,290.66211 480,290.66211 620.30948,290.66211 733.33789,403.69052 733.33789,544 L 800,544 C 800,367.66368 656.33632,224 480,224 Z`,id:`path4712`,"inkscape:connector-curvature":`0`})])],-1),createBaseVNode(`g`,{ref_key:`layer6Ref`,ref:layer6Ref,id:`layer6`,class:`layer6`},[_cache[1]||=createBaseVNode(`circle`,{transform:`translate(-150,-214)`,id:`path4281-5`,class:`circle1`,cx:`480`,cy:`544`,r:`320`,d:`M 800,544 C 800,720.73112 656.73112,864 480,864 303.26888,864 160,720.73112 160,544 160,367.26888 303.26888,224 480,224 c 176.73112,0 320,143.26888 320,320 z`},null,-1),_cache[2]||=createBaseVNode(`path`,{transform:`translate(-150,-214)`,id:`path4281`,class:`path1`,d:`M 480,214 C 297.74603,214 150,361.74603 150,544 150,726.25397 297.74603,874 480,874 662.25397,874 810,726.25397 810,544 810,361.74603 662.25397,214 480,214 z`,"clip-path":`url(#clipPath4407-8)`},null,-1),createBaseVNode(`text`,_hoisted_2$132,[createBaseVNode(`tspan`,{ref_key:`speedTextRef`,ref:speedTextRef,id:`tacho2speed`,class:`tacho2-speed`,x:`329.88641`,y:`289.30463`},`0`,512)]),createBaseVNode(`text`,_hoisted_3$118,[createBaseVNode(`tspan`,{ref_key:`speedUnitTextRef`,ref:speedUnitTextRef,id:`speedunit`,x:`330`,y:`348`},`mph`,512)]),createBaseVNode(`text`,_hoisted_4$96,[createBaseVNode(`tspan`,{ref_key:`gearTextRef`,ref:gearTextRef,id:`tacho2gear`,class:`text`,x:`386.67343`,y:`457.94861`},`4`,512)]),(openBlock(),createElementBlock(Fragment,null,renderList(maxRpmTexts,k=>createBaseVNode(`text`,{ref_for:!0,ref:el=>setRpmRef(el,k),"xml:space":`preserve`,x:`0`,y:`0`,class:`rpm-text`},[..._cache[0]||=[createBaseVNode(`tspan`,{x:`0`,y:`0`},null,-1)]],512)),64)),createBaseVNode(`text`,_hoisted_5$83,[createBaseVNode(`tspan`,{ref_key:`rpmLegendTextRef`,ref:rpmLegendTextRef,id:`tspan4449-3-1`,x:`330.09229`,y:`498.18045`},`x1000 RPM`,512)]),_cache[3]||=createBaseVNode(`path`,{"clip-path":`none`,id:`path4258`,class:`path-oil-fuel`,d:`M 462.44226,446.99523 C 489.99031,415.832 506.71155,374.86426 506.71155,330 c 0,-44.86426 -16.72124,-85.832 -44.26929,-116.99523 m -264.88452,0 C 170.00969,244.168 153.28845,285.13574 153.28845,330 c 0,44.86426 16.72124,85.832 44.26929,116.99523`},null,-1),createBaseVNode(`path`,{ref_key:`fuelBarRef`,ref:fuelBarRef,id:`fuel`,class:`fuel-bar`,d:`M 462.44226,446.99523 C 489.99031,415.832 506.71155,374.86426 506.71155,330 c 0,-44.86426 -16.72124,-85.832 -44.26929,-116.99523`},null,512),createBaseVNode(`path`,{ref_key:`oilTempBarRef`,ref:oilTempBarRef,id:`temp`,class:`oil-temp-bar`,d:`M 197.55774,213.00477 C 170.00969,244.168 153.28845,285.13574 153.28845,330 c 0,44.86426 16.72124,85.832 44.26929,116.99523`},null,512)],512),createBaseVNode(`g`,{ref_key:`layer3Ref`,ref:layer3Ref,id:`layer3`,class:`layer3`},[createBaseVNode(`g`,_hoisted_6$69,[_cache[4]||=createBaseVNode(`rect`,{y:`203.90677`,x:`141.28131`,height:`683.79401`,width:`683.79401`,id:`rect4001`,class:`layer3-rect`},null,-1),createBaseVNode(`path`,{ref_key:`revcurveRef`,ref:revcurveRef,class:`revcurve`,id:`revcurve`,"clip-path":`none`,d:`M 330,690 C 131.17749,690 -30,528.82251 -30,330 -30,131.17749 131.17749,-30 330,-30 c 198.82251,0 360,161.17749 360,360`,transform:`matrix(0.80555556,0,0,0.80555556,214.16667,278.16667)`},null,512),createBaseVNode(`path`,{ref_key:`redLineRef`,ref:redLineRef,class:`redline`,id:`rpm_redline`,d:`M 330,610 C 175.36027,610 50,484.63973 50,330 50,175.36027 175.36027,50 330,50 484.63973,50 610,175.36027 610,330`,transform:`matrix(1.038252,0,0,1.038252,137.37687,201.37687)`},null,512)])],512),createBaseVNode(`g`,{ref_key:`layer11Ref`,ref:layer11Ref,id:`layer11`,class:`layer11`},[createBaseVNode(`path`,{ref_key:`revcurveDashesRef`,ref:revcurveDashesRef,id:`revcurve_dashes`,class:`revcurve-dashes`,d:`M 330,616.66897 C 171.6771,616.66897 43.331027,488.3229 43.331027,330 43.331026,171.67709 171.67709,43.33103 330,43.331031 488.3229,43.331031 616.66897,171.6771 616.66897,330`},null,512),createBaseVNode(`path`,{ref_key:`rpmTextGuideLineRef`,ref:rpmTextGuideLineRef,id:`rpmtextline`,class:`rpm-textline`,d:`M 329,550 C 204.73594,550 104,449.26406 104,325 104,200.73593 204.73593,100 329,100 c 124.26406,0 225,100.73594 225,225`},null,512)],512),_cache[18]||=createBaseVNode(`g`,{id:`layer2`,style:{display:`none`}},[createBaseVNode(`g`,{style:{display:`inline`},id:`ico_handbrake_12343525ron`,transform:`translate(-4.2182737e-6,-2.0000051)`},[createBaseVNode(`path`,{transform:`matrix(0.43850147,2.6141077e-4,-2.6141077e-4,0.43850147,320.9902,18.916914)`,style:{display:`inline`,fill:`#ff7900`,"fill-opacity":`1`,stroke:`#ffffff`,"stroke-width":`12`,"stroke-miterlimit":`4`,"stroke-dasharray":`none`,"stroke-opacity":`1`},d:`m 631.44636,979.59082 a 65.760933,65.760933 0 0 1 -65.76094,65.76098 65.760933,65.760933 0 0 1 -65.76093,-65.76098 65.760933,65.760933 0 0 1 65.76093,-65.76093 65.760933,65.760933 0 0 1 65.76094,65.76093 z`,id:`path4551-2-7`}),createBaseVNode(`path`,{"sodipodi:nodetypes":`csc`,id:`path4551-7-7-3`,d:`m 546.9327,480.53664 c -10.16748,-6.97507 -16.83385,-18.68164 -16.82592,-31.94291 0.008,-13.00305 6.43054,-24.50375 16.27369,-31.51076`,style:{display:`inline`,fill:`none`,stroke:`#ffffff`,"stroke-width":`5.26201868`,"stroke-linecap":`round`,"stroke-linejoin":`round`,"stroke-miterlimit":`4`,"stroke-opacity":`1`}}),createBaseVNode(`path`,{"sodipodi:nodetypes":`csc`,id:`path4551-7-4-7-72`,d:`m 590.24076,480.56245 c 10.17587,-6.96293 16.8562,-18.66157 16.86414,-31.92282 0.008,-13.00303 -6.40141,-24.51142 -16.23624,-31.5301`,style:{display:`inline`,fill:`none`,stroke:`#ffffff`,"stroke-width":`5.26201868`,"stroke-linecap":`round`,"stroke-linejoin":`round`,"stroke-miterlimit":`4`,"stroke-opacity":`1`}}),createBaseVNode(`g`,{id:`flowRoot5902-7-4`,style:{"font-style":`normal`,"font-variant":`normal`,"font-weight":`bold`,"font-stretch":`normal`,"font-size":`55px`,"line-height":`125%`,"font-family":`'Open Sans'`,"-inkscape-font-specification":`'Open Sans Bold'`,"letter-spacing":`-3.45999861px`,"word-spacing":`0px`,display:`inline`,fill:`#ffffff`,"fill-opacity":`1`,stroke:`none`},transform:`matrix(0.43849858,-0.00161469,0.00161469,0.43849858,259.17408,95.334998)`},[createBaseVNode(`path`,{id:`path3978-3-5`,style:{"-inkscape-font-specification":`'Open Sans Bold'`},d:`m 548.35205,1001.1788 -2.84668,-9.34567 -14.31396,0 -2.84668,9.34567 -8.96973,0 13.85742,-39.4238 10.17822,0 13.91114,39.4238 z m -4.83398,-16.32809 c -2.63186,-8.4684 -4.11339,-13.25762 -4.44458,-14.36768 -0.33124,-1.10999 -0.56846,-1.98727 -0.71167,-2.63183 -0.59084,2.29169 -2.28274,7.95819 -5.07569,16.99951 z`}),createBaseVNode(`path`,{id:`path3980-3-4`,style:{"-inkscape-font-specification":`'Open Sans Bold'`},d:`m 558.77633,961.91614 12.21924,0 c 5.56801,4e-5 9.60975,0.79227 12.12524,2.37671 2.51543,1.5845 3.77316,4.10444 3.77319,7.55981 -3e-5,2.3454 -0.55056,4.27004 -1.65161,5.77393 -1.1011,1.50392 -2.56472,2.40806 -4.39087,2.7124 l 0,0.26855 c 2.48858,0.55504 4.28342,1.59345 5.38453,3.11524 1.10104,1.52182 1.65157,3.54493 1.65161,6.06933 -4e-5,3.58074 -1.29357,6.37371 -3.88062,8.37891 -2.5871,2.00518 -6.10069,3.00778 -10.54077,3.00778 l -14.68994,0 z m 8.32519,15.54931 4.83399,0 c 2.25584,3e-5 3.88954,-0.34909 4.90112,-1.04736 1.01153,-0.69822 1.51731,-1.853 1.51734,-3.46436 -3e-5,-1.50387 -0.55057,-2.58257 -1.65162,-3.23608 -1.10109,-0.65345 -2.84222,-0.98019 -5.22338,-0.98022 l -4.37745,0 z m 0,6.60645 0,10.23193 5.42481,0 c 2.29164,1e-5 3.98354,-0.43863 5.07568,-1.31592 1.0921,-0.87727 1.63816,-2.22004 1.63819,-4.02832 -3e-5,-3.25844 -2.3275,-4.88767 -6.98243,-4.88769 z`}),createBaseVNode(`path`,{id:`path3982-5-4`,style:{"-inkscape-font-specification":`'Open Sans Bold'`},d:`m 615.44572,990.27551 c -2e-5,3.54493 -1.27566,6.3379 -3.8269,8.37891 -2.55129,2.04098 -6.10069,3.06148 -10.64819,3.06148 -4.18947,0 -7.89552,-0.7877 -11.11817,-2.36324 l 0,-7.73437 c 2.64974,1.18164 4.89217,2.01416 6.7273,2.49755 1.83511,0.48341 3.51358,0.72511 5.0354,0.7251 1.82615,10e-6 3.22711,-0.34911 4.20288,-1.04736 0.97573,-0.69824 1.4636,-1.73665 1.46362,-3.11524 -2e-5,-0.76984 -0.21486,-1.45466 -0.64453,-2.05444 -0.42971,-0.59976 -1.06081,-1.17715 -1.89331,-1.73218 -0.83254,-0.555 -2.5289,-1.44123 -5.08911,-2.65869 -2.3991,-1.12791 -4.19841,-2.21108 -5.39795,-3.24951 -1.19955,-1.03839 -2.15739,-2.24689 -2.87354,-3.62549 -0.71614,-1.37855 -1.07422,-2.98988 -1.07421,-4.83398 -10e-6,-3.47328 1.17716,-6.20358 3.53149,-8.19092 2.35432,-1.98727 5.6083,-2.98092 9.76196,-2.98096 2.041,4e-5 3.98802,0.24174 5.84107,0.7251 1.853,0.48344 3.79107,1.16377 5.81421,2.04102 l -2.68555,6.47216 c -2.09475,-0.85934 -3.82693,-1.45911 -5.19653,-1.79931 -1.36965,-0.34014 -2.7169,-0.51022 -4.04175,-0.51026 -1.57554,4e-5 -2.78403,0.36706 -3.62549,1.10108 -0.84148,0.73408 -1.26222,1.69192 -1.26221,2.87353 -10e-6,0.73408 0.17008,1.37413 0.51026,1.92017 0.34015,0.54609 0.88174,1.07424 1.62475,1.58447 0.74299,0.51028 2.50202,1.42784 5.2771,2.75269 3.67023,1.75457 6.18569,3.51361 7.54639,5.2771 1.36065,1.76352 2.04099,3.92538 2.04101,6.48559 z`})]),createBaseVNode(`g`,{id:`flowRoot5902-7-5`,style:{"font-style":`normal`,"font-variant":`normal`,"font-weight":`bold`,"font-stretch":`normal`,"font-size":`55px`,"line-height":`125%`,"font-family":`'Open Sans'`,"-inkscape-font-specification":`'Open Sans Bold'`,"letter-spacing":`-3.45999861px`,"word-spacing":`0px`,display:`inline`,fill:`#ffffff`,"fill-opacity":`1`,stroke:`none`},transform:`matrix(0.43849858,-0.00161469,0.00161469,0.43849858,317.47869,20.439182)`},[createBaseVNode(`g`,{transform:`matrix(0.99999322,0.00368229,-0.00368229,0.99999322,0,0)`,style:{"font-style":`normal`,"font-weight":`normal`,"font-size":`94.63018036px`,"line-height":`125%`,"font-family":`sans-serif`,"letter-spacing":`0px`,"word-spacing":`0px`,fill:`#ffffff`,"fill-opacity":`1`,stroke:`none`,"stroke-width":`1px`,"stroke-linecap":`butt`,"stroke-linejoin":`miter`,"stroke-opacity":`1`},id:`text4455`},[createBaseVNode(`path`,{d:`m 607.02483,962.46092 q 0,4.62062 -1.61722,9.05641 -1.61721,4.38958 -4.62061,7.39298 -4.11235,4.06614 -9.19502,6.14542 -5.03647,2.07927 -12.56807,2.07927 l -11.04327,0 0,22.41 -17.74316,0 0,-68.80096 29.20228,0 q 6.56127,0 11.04327,1.15515 4.5282,1.10895 7.99366,3.37305 4.15856,2.72616 6.33024,6.97713 2.2179,4.25096 2.2179,10.21155 z m -18.34384,0.41586 q 0,-2.91099 -1.57101,-4.99026 -1.57101,-2.12549 -3.65028,-2.9572 -2.77237,-1.10895 -5.40612,-1.20136 -2.63375,-0.13862 -7.02334,-0.13862 l -3.0496,0 0,20.60794 5.08267,0 q 4.52821,0 7.43919,-0.55447 2.9572,-0.55447 4.94406,-2.21789 1.70963,-1.4786 2.44893,-3.51167 0.7855,-2.07928 0.7855,-5.03647 z`,style:{"font-style":`normal`,"font-variant":`normal`,"font-weight":`bold`,"font-stretch":`normal`,"font-size":`94.63018036px`,"line-height":`125%`,"font-family":`'Open Sans Extrabold'`,"-inkscape-font-specification":`'Open Sans Extrabold, Bold'`,"text-align":`start`,"writing-mode":`lr-tb`,"text-anchor":`start`,fill:`#ffffff`,"fill-opacity":`1`},id:`path4527`,"inkscape:connector-curvature":`0`})]),createBaseVNode(`path`,{transform:`matrix(0.99999322,0.00368229,-0.00368229,0.99999322,0,0)`,style:{fill:`none`,"fill-opacity":`1`,stroke:`#000000`,"stroke-width":`5.69782162`,"stroke-miterlimit":`4`,"stroke-dasharray":`none`,"stroke-opacity":`1`},d:`m 28.554777,1230.2663 c -137.847287,0 -270.048717,-54.7596 -367.521467,-152.2324 -97.47276,-97.47273 -152.23238,-229.67416 -152.23238,-367.52145 0,-137.84729 54.75963,-270.04871 152.23238,-367.52146 97.47275,-97.47276 229.67418,-152.23238 367.521467,-152.23238 137.847293,0 270.048713,54.75962 367.521463,152.23238 97.47275,97.47275 152.23238,229.67417 152.23238,367.52146 0,137.84729 -54.75962,270.04871 -152.23238,367.52145 -97.47275,97.4728 -229.67417,152.2324 -367.521463,152.2324`,id:`text_path`,"inkscape:connector-curvature":`0`,"sodipodi:nodetypes":`csssssssc`,"inkscape:label":`#path4459`})])])],-1),createBaseVNode(`g`,{ref_key:`layer7Ref`,ref:layer7Ref,"inkscape:groupmode":`layer`,id:`layer7`,class:`layer7`,"inkscape:label":`new2`},[createBaseVNode(`g`,{ref_key:`revNeedleRef`,ref:revNeedleRef,id:`revneedle`,"inkscape:label":`#g4147`},[..._cache[5]||=[createBaseVNode(`rect`,{y:`7`,x:`322.44037`,height:`72`,width:`12`,id:`rect4625`,class:`rev-needle-rect`},null,-1)]],512)],512),createBaseVNode(`g`,{ref_key:`layer4Ref`,ref:layer4Ref,"inkscape:groupmode":`layer`,id:`layer4`,class:`layer4`,"inkscape:label":`Icons bottom right`},[createBaseVNode(`path`,{ref_key:`icoIndicatorLeftOffRef`,ref:icoIndicatorLeftOffRef,id:`ico_indicatorl`,class:`ico-indicator-l`,d:`m 386.4512,577.16251 0.0556,17.08797 15.45962,0.24613 0,10.03868 0,10.03869 -15.45962,0.24608 -0.0556,17.08797 -35.33627,-27.37274 z`,"inkscape:connector-curvature":`0`,"sodipodi:nodetypes":`ccccccccc`,"inkscape:label":`#rect4655-9`},null,512),createBaseVNode(`path`,{ref_key:`icoIndicatorRightOffRef`,ref:icoIndicatorRightOffRef,id:`ico_indicatorr`,class:`ico-indicator-r`,d:`m 442.9256,554.57416 -0.0557,17.08798 -15.45965,0.24611 0,10.03869 0,10.03869 15.45965,0.24608 0.0557,17.08796 35.33627,-27.37273 z`,"inkscape:connector-curvature":`0`,"sodipodi:nodetypes":`ccccccccc`,"inkscape:label":`#rect4655-9-3`},null,512),createBaseVNode(`g`,{ref_key:`icoLightsOffRef`,ref:icoLightsOffRef,id:`ico_lights`,class:`ico-lights`,"inkscape:label":`#g4122`,transform:`translate(-12,-2)`},[..._cache[6]||=[createBaseVNode(`path`,{"inkscape:connector-curvature":`0`,id:`rect5824`,class:`light-source`,d:`m 611.67051,352.21188 19.61837,0 c 0,0 13.56687,7.61647 13.56687,22.35122 0,14.73475 -13.56687,21.08238 -13.56687,21.08238 l -19.61837,0 c 0,0 -1.90879,-4.49141 -1.95206,-21.08238 -0.0435,-16.59097 1.95206,-22.35122 1.95206,-22.35122 z`},null,-1),createBaseVNode(`path`,{class:`light-dash`,"inkscape:connector-curvature":`0`,d:`m 600.68152,355.88611 -13.21963,0`},null,-1),createBaseVNode(`path`,{class:`light-dash`,"inkscape:connector-curvature":`0`,d:`m 600.68152,365.4103 -13.21963,0`},null,-1),createBaseVNode(`path`,{class:`light-dash`,"inkscape:connector-curvature":`0`,d:`m 600.68152,374.58946 -13.21963,0`},null,-1),createBaseVNode(`path`,{class:`light-dash`,"inkscape:connector-curvature":`0`,d:`m 600.68152,384.11369 -13.21963,0`},null,-1),createBaseVNode(`path`,{class:`light-dash`,"inkscape:connector-curvature":`0`,d:`m 600.68152,393.43089 -13.21963,0`},null,-1)]],512),createBaseVNode(`g`,{ref_key:`icoABSOffRef`,ref:icoABSOffRef,id:`ico_abs`,class:`ico-abs-off`,"inkscape:label":`#g4111`},[..._cache[7]||=[createBaseVNode(`path`,{transform:`matrix(0.43849858,-0.00161469,0.00161469,0.43849858,260.26675,95.346428)`,id:`path4551dd`,class:`main`,d:`m 631.44636,979.59082 c 0,36.31878 -29.44217,65.76098 -65.76094,65.76098 -36.31876,0 -65.76093,-29.4422 -65.76093,-65.76098 0,-36.31876 29.44217,-65.76093 65.76093,-65.76093 36.31877,0 65.76094,29.44217 65.76094,65.76093 z`,"inkscape:connector-curvature":`0`},null,-1),createBaseVNode(`path`,{"inkscape:connector-curvature":`0`,id:`path4551-7`,class:`curve-l`,d:`m 488.18221,555.99526 c -10.19731,-6.9315 -16.91369,-18.60946 -16.96251,-31.87062 -0.0478,-13.00297 6.32573,-24.53106 16.1388,-31.5801`},null,-1),createBaseVNode(`path`,{"inkscape:connector-curvature":`0`,id:`path4551-7-4`,class:`curve-r`,d:`m 531.48996,555.83579 c 10.14597,-7.00643 16.77617,-18.73351 16.72734,-31.99467 -0.0478,-13.00299 -6.50623,-24.48382 -16.37094,-31.4604`},null,-1),createBaseVNode(`path`,{"inkscape:connector-curvature":`0`,id:`path3978`,class:`text-a`,d:`m 501.24227,531.46506 -1.26336,-4.09346 -6.27665,0.0231 -1.23317,4.10266 -3.93322,0.0145 6.01281,-17.30965 4.46313,-0.0164 6.16367,17.26482 z m -2.14606,-7.15204 c -1.16774,-3.70913 -1.82512,-5.8068 -1.97214,-6.29303 -0.14704,-0.48619 -0.25248,-0.87049 -0.31632,-1.1529 -0.25538,1.00586 -0.98812,3.49334 -2.19823,7.46246 z`},null,-1),createBaseVNode(`path`,{"inkscape:connector-curvature":`0`,id:`path3980`,class:`text-b`,d:`m 505.7499,514.23161 5.35812,-0.0197 c 2.44157,-0.009 4.21514,0.33189 5.32074,1.02261 1.10557,0.69074 1.66115,1.79369 1.66675,3.30887 0.004,1.02845 -0.23453,1.87329 -0.71491,2.53453 -0.4804,0.66124 -1.12074,1.06007 -1.92101,1.19647 l 4.3e-4,0.11776 c 1.09214,0.23936 1.88085,0.69181 2.36614,1.35733 0.48526,0.66554 0.72994,1.55178 0.73403,2.65873 0.006,1.57015 -0.55694,2.79695 -1.68812,3.6804 -1.1312,0.88345 -2.67028,1.32876 -4.61725,1.33593 l -6.44152,0.0237 z m 3.67569,6.80491 2.1197,-0.008 c 0.98919,-0.004 1.705,-0.15935 2.14745,-0.46718 0.44242,-0.3078 0.66234,-0.81498 0.65975,-1.52156 -0.002,-0.65945 -0.24559,-1.13157 -0.72946,-1.41635 -0.48388,-0.28476 -1.24789,-0.42523 -2.29202,-0.42139 l -1.91951,0.007 z m 0.0107,2.89692 0.0165,4.48668 2.37878,-0.009 c 1.00488,-0.004 1.74606,-0.19878 2.22355,-0.58523 0.47747,-0.38644 0.71474,-0.97613 0.71184,-1.76906 -0.005,-1.42882 -1.0285,-2.13948 -3.06968,-2.13197 z`},null,-1),createBaseVNode(`path`,{"inkscape:connector-curvature":`0`,id:`path3982`,class:`text-s`,d:`m 530.64514,526.57565 c 0.006,1.55445 -0.54914,2.78122 -1.66456,3.68032 -1.11544,0.89909 -2.6702,1.35231 -4.66427,1.35965 -1.83708,0.007 -3.46345,-0.33266 -4.87912,-1.01833 l -0.0125,-3.39151 c 1.16382,0.51387 2.14846,0.87531 2.95395,1.08431 0.80547,0.20901 1.54187,0.31229 2.20918,0.30983 0.80077,-0.003 1.41452,-0.1583 1.84127,-0.46605 0.42673,-0.30776 0.63898,-0.76389 0.63676,-1.3684 -10e-4,-0.33757 -0.0966,-0.63752 -0.28594,-0.89982 -0.18939,-0.2623 -0.46706,-0.51447 -0.83301,-0.75651 -0.36596,-0.24202 -1.11125,-0.62789 -2.23586,-1.15761 -1.05382,-0.49071 -1.84457,-0.96278 -2.37224,-1.41619 -0.52768,-0.4534 -0.94964,-0.98177 -1.2659,-1.58513 -0.31625,-0.60334 -0.47587,-1.30933 -0.47884,-2.11796 -0.006,-1.52303 0.50616,-2.72216 1.53533,-3.59741 1.02915,-0.87522 2.45441,-1.31619 4.27579,-1.32291 0.89497,-0.003 1.74913,0.0996 2.56247,0.30852 0.81332,0.209 1.66426,0.50419 2.55282,0.8856 l -1.16716,2.84237 c -0.91993,-0.37344 -1.68046,-0.63364 -2.28158,-0.7806 -0.60114,-0.14694 -1.19218,-0.21935 -1.77312,-0.21723 -0.69088,0.003 -1.2202,0.16545 -1.588,0.48868 -0.3678,0.32325 -0.55075,0.74394 -0.54884,1.26208 10e-4,0.32189 0.0768,0.60228 0.22685,0.84116 0.15004,0.23892 0.38838,0.46963 0.71501,0.69217 0.32663,0.22256 1.09944,0.62206 2.31845,1.19853 1.61222,0.76345 2.71809,1.53072 3.3176,2.30181 0.59949,0.77111 0.90131,1.71798 0.90545,2.84063 z`},null,-1)]],512),createBaseVNode(`g`,{ref_key:`icoHandBrakeOffRef`,ref:icoHandBrakeOffRef,class:`ico-handbrake-off`,id:`ico_handbrake`,"inkscape:label":`#g4115`,transform:`translate(-3.5925881e-6,-2.0000007)`},[..._cache[8]||=[createBaseVNode(`path`,{transform:`matrix(0.43850147,2.6141077e-4,-2.6141077e-4,0.43850147,320.9902,18.916914)`,id:`path4551-2-74-7`,class:`main`,d:`m 631.44636,979.59082 c 0,36.31878 -29.44217,65.76098 -65.76094,65.76098 -36.31876,0 -65.76093,-29.4422 -65.76093,-65.76098 0,-36.31876 29.44217,-65.76093 65.76093,-65.76093 36.31877,0 65.76094,29.44217 65.76094,65.76093 z`,"inkscape:connector-curvature":`0`},null,-1),createBaseVNode(`path`,{class:`curve-l`,id:`path4551-7-7-0-4`,"inkscape:connector-curvature":`0`,d:`m 546.9327,480.53664 c -10.16748,-6.97507 -16.83385,-18.68164 -16.82592,-31.94291 0.008,-13.00305 6.43054,-24.50375 16.27369,-31.51076`},null,-1),createBaseVNode(`path`,{"inkscape:connector-curvature":`0`,id:`path4551-7-4-7-9-0`,class:`curve-r`,d:`m 590.24076,480.56245 c 10.17587,-6.96293 16.8562,-18.66157 16.86414,-31.92282 0.008,-13.00303 -6.40141,-24.51142 -16.23624,-31.5301`},null,-1),createBaseVNode(`g`,{class:`text-p`,id:`text4055-4-9`},[createBaseVNode(`path`,{"inkscape:connector-curvature":`0`,id:`path3269-4`,d:`m 566.88168,447.27286 2.26429,0 c 2.11628,2e-5 3.6998,-0.41806 4.75057,-1.25424 1.05073,-0.83614 1.57611,-2.05338 1.57612,-3.65172 -10e-6,-1.6131 -0.44029,-2.80444 -1.32083,-3.57403 -0.88058,-0.76954 -2.26061,-1.15432 -4.1401,-1.15435 l -3.13005,0 z m 15.53925,-5.15015 c -3e-5,3.49265 -1.09147,6.16392 -3.27434,8.01381 -2.18292,1.84993 -5.28707,2.77488 -9.31245,2.77487 l -2.95246,0 0,11.54344 -6.88167,0 0,-32.45483 10.3669,0 c 3.93659,3e-5 6.92975,0.84729 8.97947,2.54177 2.04967,1.69455 3.07452,4.22153 3.07455,7.58094 z`})],-1)]],512),createBaseVNode(`g`,{ref_key:`oilTempIcoOffRef`,ref:oilTempIcoOffRef,style:{display:`inline`},id:`ico_temp`,class:`ico-temp`,transform:`matrix(0.82879177,0,0,0.82879177,40.706638,69.281349)`,"inkscape:label":`#g4374`},[..._cache[9]||=[createBaseVNode(`path`,{"inkscape:connector-curvature":`0`,id:`path4347`,class:`path1`,d:`m 199.61025,285.93078 2e-5,37.83129`},null,-1),createBaseVNode(`path`,{"inkscape:connector-curvature":`0`,id:`path4347-5`,class:`path2`,d:`m 208.85791,292.09588 -7.00577,0`},null,-1),createBaseVNode(`path`,{"inkscape:connector-curvature":`0`,id:`path4347-5-4`,class:`path3`,d:`m 208.8579,301.06329 -7.00578,0`},null,-1),createBaseVNode(`path`,{"inkscape:connector-curvature":`0`,id:`path4347-5-3`,class:`path4`,d:`m 208.85793,309.75049 -7.00583,-1e-5`},null,-1),createBaseVNode(`circle`,{transform:`matrix(0.72059621,0,0,0.72059621,-1146.435,-0.73321691)`,id:`path4392`,class:`path5`,cx:`1867.8225`,cy:`454.9176`,r:`14.849242`,d:`m 1882.6718,454.9176 c 0,8.20101 -6.6483,14.84924 -14.8493,14.84924 -8.201,0 -14.8492,-6.64823 -14.8492,-14.84924 0,-8.20101 6.6482,-14.84924 14.8492,-14.84924 8.201,0 14.8493,6.64823 14.8493,14.84924 z`},null,-1),createBaseVNode(`path`,{"inkscape:connector-curvature":`0`,id:`path4347-5-1-2`,class:`path6`,d:`m 183.69241,332.71741 -7.00578,0`},null,-1),createBaseVNode(`path`,{"inkscape:connector-curvature":`0`,id:`path4347-5-1-2-3`,class:`path7`,d:`m 223.32319,343.08941 -46.63658,-10e-6`},null,-1),createBaseVNode(`path`,{"inkscape:connector-curvature":`0`,id:`path4347-5-1-2-34`,class:`path8`,d:`m 222.33239,332.7174 -7.00578,0`},null,-1)]],512),createBaseVNode(`g`,{ref_key:`fuelWarnIcoOffRef`,ref:fuelWarnIcoOffRef,id:`ico_fuel`,class:`ico-fuel`,transform:`matrix(0.88747678,0,0,0.88747678,64.601263,56.302973)`,"inkscape:label":`#g4368`},[..._cache[10]||=[createBaseVNode(`rect`,{id:`rect4466`,class:`rect1`,y:`284.07593`,x:`420.99237`,height:`38.905876`,width:`22.650679`},null,-1),createBaseVNode(`rect`,{id:`rect4466-1`,class:`rect2`,y:`298.80991`,x:`420.99237`,height:`24.171896`,width:`22.650679`},null,-1),createBaseVNode(`path`,{"inkscape:connector-curvature":`0`,id:`path4347-5-1-2-3-3`,class:`path1`,d:`m 448.00445,330.93084 -30.96928,0`},null,-1),createBaseVNode(`path`,{"inkscape:connector-curvature":`0`,id:`path4347-5-1-2-3-3-8`,class:`path2`,d:`m 460.25266,299.90863 0.0166,18.02062 c 0,0 -0.41583,2.18743 -4.92393,2.16693 -4.50811,-0.0205 -4.80496,-2.16693 -4.80496,-2.16693 l 0.0579,-17.71243 -7.25174,-0.0941`},null,-1)]],512)],512),createBaseVNode(`g`,{ref_key:`layer10Ref`,ref:layer10Ref,"inkscape:groupmode":`layer`,id:`layer10`,class:`layer10`,"inkscape:label":`icons bottom right activated`},[createBaseVNode(`path`,{ref_key:`icoIndicatorLeftOnRef`,ref:icoIndicatorLeftOnRef,class:`ico-indicator-l-on`,d:`m 386.4512,577.16251 0.0556,17.08797 15.45962,0.24613 0,10.03868 0,10.03869 -15.45962,0.24608 -0.0556,17.08797 -35.33627,-27.37274 z`,id:`ico_indicatorl_on`,"inkscape:connector-curvature":`0`,"inkscape:label":`#rect4655-9`},null,512),createBaseVNode(`path`,{ref_key:`icoIndicatorRightOnRef`,ref:icoIndicatorRightOnRef,id:`ico_indicatorr_on`,class:`ico-indicator-r-on`,d:`m 442.9256,554.57416 -0.0557,17.08798 -15.45965,0.24611 0,10.03869 0,10.03869 15.45965,0.24608 0.0557,17.08796 35.33627,-27.37273 z`,"inkscape:connector-curvature":`0`,"inkscape:label":`#rect4655-9-3`},null,512),createBaseVNode(`g`,{ref_key:`icoLightsOnRef`,ref:icoLightsOnRef,id:`ico_lights_on`,class:`ico-lights-on`,"inkscape:label":`#g4122`,transform:`translate(-12,-2.0000028)`},[..._cache[11]||=[createBaseVNode(`path`,{"inkscape:connector-curvature":`0`,id:`rect5824-4`,class:`path1`,d:`m 611.67051,352.21188 19.61837,0 c 0,0 13.56687,7.61647 13.56687,22.35122 0,14.73475 -13.56687,21.08238 -13.56687,21.08238 l -19.61837,0 c 0,0 -1.90879,-4.49141 -1.95206,-21.08238 -0.0435,-16.59097 1.95206,-22.35122 1.95206,-22.35122 z`},null,-1),createBaseVNode(`path`,{"inkscape:connector-curvature":`0`,id:`path4347-5-1-2-3-1-1`,class:`path2`,d:`m 600.68152,355.88611 -13.21963,0`},null,-1),createBaseVNode(`path`,{"inkscape:connector-curvature":`0`,id:`path4347-5-1-2-3-1-9-20`,class:`path3`,d:`m 600.68152,365.4103 -13.21963,0`},null,-1),createBaseVNode(`path`,{"inkscape:connector-curvature":`0`,id:`path4347-5-1-2-3-1-8-0`,class:`path4`,d:`m 600.68152,374.58946 -13.21963,0`},null,-1),createBaseVNode(`path`,{"inkscape:connector-curvature":`0`,id:`path4347-5-1-2-3-1-9-6-1`,class:`path5`,d:`m 600.68152,384.11369 -13.21963,0`},null,-1),createBaseVNode(`path`,{"inkscape:connector-curvature":`0`,id:`path4347-5-1-2-3-1-9-6-5-4`,class:`path6`,d:`m 600.68152,393.43089 -13.21963,0`},null,-1)]],512),createBaseVNode(`g`,{ref_key:`icoABSOnRef`,ref:icoABSOnRef,transform:`translate(0,-2.8038025e-6)`,id:`ico_abs_on`,class:`ico-abs-on`,"inkscape:label":`#g4106`},[..._cache[12]||=[createBaseVNode(`path`,{id:`path4551-0`,class:`path1`,"inkscape:connector-curvature":`0`,transform:`matrix(0.43849858,-0.00161469,0.00161469,0.43849858,260.26675,95.34643)`,d:`m 631.44636,979.59082 c 0,36.31878 -29.44217,65.76098 -65.76094,65.76098 -36.31876,0 -65.76093,-29.4422 -65.76093,-65.76098 0,-36.31876 29.44217,-65.76093 65.76093,-65.76093 36.31877,0 65.76094,29.44217 65.76094,65.76093 z`},null,-1),createBaseVNode(`path`,{"inkscape:connector-curvature":`0`,id:`path4551-7-717`,class:`path2`,d:`m 488.18221,555.99526 c -10.19731,-6.9315 -16.91369,-18.60946 -16.96251,-31.87062 -0.0478,-13.00297 6.32573,-24.53106 16.1388,-31.5801`},null,-1),createBaseVNode(`path`,{"inkscape:connector-curvature":`0`,id:`path4551-7-4-77`,class:`path3`,d:`m 531.48996,555.83579 c 10.14597,-7.00643 16.77617,-18.73351 16.72734,-31.99467 -0.0478,-13.00299 -6.50623,-24.48382 -16.37094,-31.4604`},null,-1),createBaseVNode(`g`,{id:`flowRoot5902-7`,class:`text-path`,transform:`matrix(0.43849858,-0.00161469,0.00161469,0.43849858,259.17408,93.335)`},[createBaseVNode(`path`,{id:`path3978-3`,class:`text-path1`,"inkscape:connector-curvature":`0`,d:`m 548.35205,1001.1788 -2.84668,-9.34567 -14.31396,0 -2.84668,9.34567 -8.96973,0 13.85742,-39.4238 10.17822,0 13.91114,39.4238 z m -4.83398,-16.32809 c -2.63186,-8.4684 -4.11339,-13.25762 -4.44458,-14.36768 -0.33124,-1.10999 -0.56846,-1.98727 -0.71167,-2.63183 -0.59084,2.29169 -2.28274,7.95819 -5.07569,16.99951 z`}),createBaseVNode(`path`,{id:`path3980-3`,class:`text-path2`,"inkscape:connector-curvature":`0`,d:`m 558.77633,961.91614 12.21924,0 c 5.56801,4e-5 9.60975,0.79227 12.12524,2.37671 2.51543,1.5845 3.77316,4.10444 3.77319,7.55981 -3e-5,2.3454 -0.55056,4.27004 -1.65161,5.77393 -1.1011,1.50392 -2.56472,2.40806 -4.39087,2.7124 l 0,0.26855 c 2.48858,0.55504 4.28342,1.59345 5.38453,3.11524 1.10104,1.52182 1.65157,3.54493 1.65161,6.06933 -4e-5,3.58074 -1.29357,6.37371 -3.88062,8.37891 -2.5871,2.00518 -6.10069,3.00778 -10.54077,3.00778 l -14.68994,0 z m 8.32519,15.54931 4.83399,0 c 2.25584,3e-5 3.88954,-0.34909 4.90112,-1.04736 1.01153,-0.69822 1.51731,-1.853 1.51734,-3.46436 -3e-5,-1.50387 -0.55057,-2.58257 -1.65162,-3.23608 -1.10109,-0.65345 -2.84222,-0.98019 -5.22338,-0.98022 l -4.37745,0 z m 0,6.60645 0,10.23193 5.42481,0 c 2.29164,1e-5 3.98354,-0.43863 5.07568,-1.31592 1.0921,-0.87727 1.63816,-2.22004 1.63819,-4.02832 -3e-5,-3.25844 -2.3275,-4.88767 -6.98243,-4.88769 z`}),createBaseVNode(`path`,{id:`path3982-5`,class:`text-path3`,"inkscape:connector-curvature":`0`,d:`m 615.44572,990.27551 c -2e-5,3.54493 -1.27566,6.3379 -3.8269,8.37891 -2.55129,2.04098 -6.10069,3.06148 -10.64819,3.06148 -4.18947,0 -7.89552,-0.7877 -11.11817,-2.36324 l 0,-7.73437 c 2.64974,1.18164 4.89217,2.01416 6.7273,2.49755 1.83511,0.48341 3.51358,0.72511 5.0354,0.7251 1.82615,10e-6 3.22711,-0.34911 4.20288,-1.04736 0.97573,-0.69824 1.4636,-1.73665 1.46362,-3.11524 -2e-5,-0.76984 -0.21486,-1.45466 -0.64453,-2.05444 -0.42971,-0.59976 -1.06081,-1.17715 -1.89331,-1.73218 -0.83254,-0.555 -2.5289,-1.44123 -5.08911,-2.65869 -2.3991,-1.12791 -4.19841,-2.21108 -5.39795,-3.24951 -1.19955,-1.03839 -2.15739,-2.24689 -2.87354,-3.62549 -0.71614,-1.37855 -1.07422,-2.98988 -1.07421,-4.83398 -10e-6,-3.47328 1.17716,-6.20358 3.53149,-8.19092 2.35432,-1.98727 5.6083,-2.98092 9.76196,-2.98096 2.041,4e-5 3.98802,0.24174 5.84107,0.7251 1.853,0.48344 3.79107,1.16377 5.81421,2.04102 l -2.68555,6.47216 c -2.09475,-0.85934 -3.82693,-1.45911 -5.19653,-1.79931 -1.36965,-0.34014 -2.7169,-0.51022 -4.04175,-0.51026 -1.57554,4e-5 -2.78403,0.36706 -3.62549,1.10108 -0.84148,0.73408 -1.26222,1.69192 -1.26221,2.87353 -10e-6,0.73408 0.17008,1.37413 0.51026,1.92017 0.34015,0.54609 0.88174,1.07424 1.62475,1.58447 0.74299,0.51028 2.50202,1.42784 5.2771,2.75269 3.67023,1.75457 6.18569,3.51361 7.54639,5.2771 1.36065,1.76352 2.04099,3.92538 2.04101,6.48559 z`})],-1)]],512),createBaseVNode(`g`,{ref_key:`icoHandBrakeOnRef`,ref:icoHandBrakeOnRef,id:`ico_handbrake_on`,class:`ico-handbrake-on`,"inkscape:label":`#g4115`,transform:`translate(-3.5925881e-6,-2.0000007)`},[..._cache[13]||=[createBaseVNode(`path`,{id:`path4551-2-74`,class:`path1`,transform:`matrix(0.43850147,2.6141077e-4,-2.6141077e-4,0.43850147,320.9902,18.916914)`,d:`m 631.44636,979.59082 c 0,36.31878 -29.44217,65.76098 -65.76094,65.76098 -36.31876,0 -65.76093,-29.4422 -65.76093,-65.76098 0,-36.31876 29.44217,-65.76093 65.76093,-65.76093 36.31877,0 65.76094,29.44217 65.76094,65.76093 z`,"inkscape:connector-curvature":`0`},null,-1),createBaseVNode(`path`,{"inkscape:connector-curvature":`0`,id:`path4551-7-7-0`,class:`path2`,d:`m 546.9327,480.53664 c -10.16748,-6.97507 -16.83385,-18.68164 -16.82592,-31.94291 0.008,-13.00305 6.43054,-24.50375 16.27369,-31.51076`},null,-1),createBaseVNode(`path`,{"inkscape:connector-curvature":`0`,id:`path4551-7-4-7-9`,class:`path3`,d:`m 590.24076,480.56245 c 10.17587,-6.96293 16.8562,-18.66157 16.86414,-31.92282 0.008,-13.00303 -6.40141,-24.51142 -16.23624,-31.5301`},null,-1),createBaseVNode(`g`,{class:`text-p`,id:`text4055-4`},[createBaseVNode(`path`,{d:`m 566.88168,447.27286 2.26429,0 c 2.11628,2e-5 3.6998,-0.41806 4.75057,-1.25424 1.05073,-0.83614 1.57611,-2.05338 1.57612,-3.65172 -10e-6,-1.6131 -0.44029,-2.80444 -1.32083,-3.57403 -0.88058,-0.76954 -2.26061,-1.15432 -4.1401,-1.15435 l -3.13005,0 z m 15.53925,-5.15015 c -3e-5,3.49265 -1.09147,6.16392 -3.27434,8.01381 -2.18292,1.84993 -5.28707,2.77488 -9.31245,2.77487 l -2.95246,0 0,11.54344 -6.88167,0 0,-32.45483 10.3669,0 c 3.93659,3e-5 6.92975,0.84729 8.97947,2.54177 2.04967,1.69455 3.07452,4.22153 3.07455,7.58094 z`,id:`path3269`,"inkscape:connector-curvature":`0`})],-1)]],512),createBaseVNode(`g`,{ref_key:`oilTempIcoOnRef`,ref:oilTempIcoOnRef,id:`ico_temp_on`,class:`ico-temp-on`,transform:`matrix(0.82879177,0,0,0.82879177,40.706638,69.281349)`,"inkscape:label":`#g4374`},[..._cache[14]||=[createBaseVNode(`path`,{"inkscape:connector-curvature":`0`,id:`path4347-7`,class:`path1`,d:`m 199.61025,285.93078 2e-5,37.83129`},null,-1),createBaseVNode(`path`,{"inkscape:connector-curvature":`0`,id:`path4347-5-40`,class:`path2`,d:`m 208.85791,292.09588 -7.00577,0`},null,-1),createBaseVNode(`path`,{"inkscape:connector-curvature":`0`,id:`path4347-5-4-9`,class:`path3`,d:`m 208.8579,301.06329 -7.00578,0`},null,-1),createBaseVNode(`path`,{"inkscape:connector-curvature":`0`,id:`path4347-5-3-4`,class:`path4`,d:`m 208.85793,309.75049 -7.00583,-1e-5`},null,-1),createBaseVNode(`circle`,{id:`path4392-8`,class:`circle1`,transform:`matrix(0.72059621,0,0,0.72059621,-1146.435,-0.73321691)`,cx:`1867.8225`,cy:`454.9176`,r:`14.849242`,d:`m 1882.6718,454.9176 c 0,8.20101 -6.6483,14.84924 -14.8493,14.84924 -8.201,0 -14.8492,-6.64823 -14.8492,-14.84924 0,-8.20101 6.6482,-14.84924 14.8492,-14.84924 8.201,0 14.8493,6.64823 14.8493,14.84924 z`},null,-1),createBaseVNode(`path`,{"inkscape:connector-curvature":`0`,id:`path4347-5-1-2-8`,class:`path5`,d:`m 183.69241,332.71741 -7.00578,0`},null,-1),createBaseVNode(`path`,{"inkscape:connector-curvature":`0`,id:`path4347-5-1-2-3-2`,class:`path6`,d:`m 223.32319,343.08941 -46.63658,-10e-6`},null,-1),createBaseVNode(`path`,{"inkscape:connector-curvature":`0`,id:`path4347-5-1-2-34-4`,class:`path7`,d:`m 222.33239,332.7174 -7.00578,0`},null,-1)]],512),createBaseVNode(`g`,{ref_key:`fuelWarnIcoOnRef`,ref:fuelWarnIcoOnRef,id:`ico_fuel_on`,class:`ico-fuel-on`,transform:`matrix(0.88747678,0,0,0.88747678,64.601263,56.302973)`,"inkscape:label":`#g4368-5`},[..._cache[15]||=[createBaseVNode(`rect`,{id:`rect4466-5`,class:`rect1`,y:`284.07593`,x:`420.99237`,height:`38.905876`,width:`22.650679`},null,-1),createBaseVNode(`rect`,{id:`rect4466-1-1`,class:`rect2`,y:`298.80991`,x:`420.99237`,height:`24.171896`,width:`22.650679`},null,-1),createBaseVNode(`path`,{"inkscape:connector-curvature":`0`,id:`path4347-5-1-2-3-3-7`,class:`path1`,d:`m 448.00445,330.93084 -30.96928,0`},null,-1),createBaseVNode(`path`,{"inkscape:connector-curvature":`0`,id:`path4347-5-1-2-3-3-8-1`,class:`path2`,d:`m 460.25266,299.90863 0.0166,18.02062 c 0,0 -0.41583,2.18743 -4.92393,2.16693 -4.50811,-0.0205 -4.80496,-2.16693 -4.80496,-2.16693 l 0.0579,-17.71243 -7.25174,-0.0941`},null,-1)]],512)],512),createBaseVNode(`g`,{ref_key:`layer12Ref`,ref:layer12Ref,"inkscape:groupmode":`layer`,id:`layer12`,class:`layer12`,"inkscape:label":`icons bottom right 2`},[createBaseVNode(`g`,{ref_key:`icoLightsHighRef`,ref:icoLightsHighRef,id:`ico_lights_high`,class:`ico-lights-high`,"inkscape:label":`#g4122`,transform:`translate(-12.000003,-2.0000028)`},[..._cache[16]||=[createBaseVNode(`path`,{"inkscape:connector-curvature":`0`,id:`rect5824-4-9`,class:`path1`,d:`m 611.67051,352.21188 19.61837,0 c 0,0 13.56687,7.61647 13.56687,22.35122 0,14.73475 -13.56687,21.08238 -13.56687,21.08238 l -19.61837,0 c 0,0 -1.90879,-4.49141 -1.95206,-21.08238 -0.0435,-16.59097 1.95206,-22.35122 1.95206,-22.35122 z`},null,-1),createBaseVNode(`path`,{"inkscape:connector-curvature":`0`,id:`path4347-5-1-2-3-1-1-8`,class:`path2`,d:`m 600.68152,355.88611 -13.21963,0`},null,-1),createBaseVNode(`path`,{"inkscape:connector-curvature":`0`,id:`path4347-5-1-2-3-1-9-20-1`,class:`path3`,d:`m 600.68152,365.4103 -13.21963,0`},null,-1),createBaseVNode(`path`,{"inkscape:connector-curvature":`0`,id:`path4347-5-1-2-3-1-8-0-8`,class:`path4`,d:`m 600.68152,374.58946 -13.21963,0`},null,-1),createBaseVNode(`path`,{"inkscape:connector-curvature":`0`,id:`path4347-5-1-2-3-1-9-6-1-2`,class:`path5`,d:`m 600.68152,384.11369 -13.21963,0`},null,-1),createBaseVNode(`path`,{"inkscape:connector-curvature":`0`,id:`path4347-5-1-2-3-1-9-6-5-4-6`,class:`path6`,d:`m 600.68152,393.43089 -13.21963,0`},null,-1)]],512)],512),createBaseVNode(`g`,{ref_key:`tickLayerRef`,ref:tickLayerRef,id:`tickLayer`,class:`tick-layer`},[(openBlock(),createElementBlock(Fragment,null,renderList(maxRpmTexts,k=>createBaseVNode(`line`,{ref_for:!0,ref:el=>setTickRef(el,k),x1:`0`,y1:`0`,x2:`0`,y2:`0`,class:`tick-line`},null,512)),64))],512)]))}},tacho_default=__plugin_vue_export_helper_default(_sfc_main$179,[[`__scopeId`,`data-v-310c7a2d`]]),_hoisted_1$159={class:`tacho-container`},_sfc_main$178={__name:`app`,setup(__props){let{$game}=useLibStore(),tachoRef=ref(null),visible=ref(!1);ref(!1),onMounted(()=>{tachoRef.value.wireThroughUnitSystem((val,func)=>UiUnits[func](val)),$game.streams.add([`electrics`,`engineInfo`]),$game.events.on(`onStreamsUpdate`,onStreamsUpdate),$game.events.on(`VehicleChange`,onVehicleChange),$game.events.on(`VehicleFocusChanged`,onVehicleFocusChanged)}),onUnmounted(()=>{$game.streams.remove([`electrics`,`engineInfo`]),$game.events.off(`onStreamsUpdate`,onStreamsUpdate),$game.events.off(`VehicleChange`,onVehicleChange),$game.events.off(`VehicleFocusChanged`,onVehicleFocusChanged)});let _done=!1;function onStreamsUpdate(streams){tachoRef.value!==null&&(_done||=!0,tachoRef.value.update(streams)?visible.value||=!0:visible&&(visible.value=!1))}function onVehicleChange(){tachoRef.value!==null&&tachoRef.value.vehicleChanged()}function onVehicleFocusChanged(data){tachoRef.value!==null&&data.mode===!0&&tachoRef.value.vehicleChanged()}return(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$159,[createVNode(tacho_default,{ref_key:`tachoRef`,ref:tachoRef},null,512)]))}},app_default$26=__plugin_vue_export_helper_default(_sfc_main$178,[[`__scopeId`,`data-v-57c978c8`]]),_sfc_main$177={__name:`app`,setup(__props){let{$game}=useLibStore(),store$1=useTasksStore();provide(`animationSettings`,{animate:!0,animateOnMount:!1,animateOnMountIntervalDelay:.2,animateOnEmptyIntervalDelay:.1,animateOnEmpty:!0,animateNextTask:!0,successCallback:playAudio});function playAudio(){$game.lua.Engine.Audio.playOnce(`AudioGui`,`event:>UI>Career>Checkbox`)}return(_ctx,_cache)=>(openBlock(),createBlock(unref(TaskList_default),{header:unref(store$1).header,tasks:unref(store$1).tasks},null,8,[`header`,`tasks`]))}},app_default$27=_sfc_main$177,_hoisted_1$158={class:`pacenote`},_hoisted_2$131=[`id`],_hoisted_3$117=[`fill`,`stroke`],_hoisted_4$95=[`id`],_hoisted_5$82=[`fill`,`stroke`],_hoisted_6$68=[`fill`],_hoisted_7$59={class:`content`},_hoisted_8$49={class:`instruction`},_hoisted_9$43={key:0,class:`modifier`},_hoisted_10$36={key:1,class:`add-note`},_hoisted_11$32={key:0,class:`distance`},_sfc_main$176={__name:`PaceNote`,props:{note:{type:Object,required:!0,validator(value){return value.type===`empty`?!0:typeof value.type==`string`},default:()=>({type:`empty`,typeExt:null,turnModifier:null,background:{color:`var(--bng-cool-gray-600)`,strokeColor:`var(--bng-cool-gray-500)`,opacity:.6},isInto:!1,isLeft:!1,size:5,turnTypeValue:null,distance:null,additionalNote:{color:`#fff`,icon:null,text:null}})}},setup(__props){useCssVars(_ctx=>({v5d4f1806:props.note.size,v654d2548:backgroundColor.value,v7d5e0455:colorNoteIcon.value,v7d630d09:colorNoteText.value,v305678bf:colorDistance.value}));let bgId=uniqueId(``,`_`),props=__props,noteUrl=computed(()=>{if(props.note.typeExt)return props.note.typeExt;let assetPath=noteTypes[props.note.type];return assetPath?getAssetURL(assetPath):null}),backgroundColor=computed(()=>props.note.background&&props.note.background.color?props.note.background.color:`var(--bng-cool-gray-600)`),strokeColor=computed(()=>props.note.background&&props.note.background.strokeColor?props.note.background.strokeColor:`var(--bng-cool-gray-500)`),backgroundOpacity=computed(()=>props.note.background&&props.note.background.opacity?props.note.background.opacity:.6),colorNoteIcon=computed(()=>props.note.colorNoteIcon?props.note.colorNoteIcon:`#fff`),colorNoteText=computed(()=>props.note.colorNoteText?props.note.colorNoteText:`#fff`),intoColor=computed(()=>props.note.intoColor?props.note.intoColor:`#fff`),colorDistance=computed(()=>props.note.colorDistance?props.note.colorDistance:`#ececec`);return(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$158,[createBaseVNode(`div`,{class:`background`,style:normalizeStyle({opacity:backgroundOpacity.value})},[__props.note.isInto?(openBlock(),createElementBlock(`svg`,{key:1,id:`note_${unref(bgId)}`,style:{width:`var(--note-size)`,height:`var(--note-size)`},viewBox:`0 0 56 56`,fill:`none`,xmlns:`http://www.w3.org/2000/svg`},[createBaseVNode(`path`,{d:`M5 47.75H5.54967L5.71519 47.2258L11.3348 29.4304C11.6288 28.4994 11.6288 27.5006 11.3348 26.5696L5.95963 9.54823C5.82856 9.13317 5.7822 8.69601 5.8233 8.26269L6.25669 3.69314C6.41494 2.02457 7.81612 0.75 9.49217 0.75H51.4137C53.3423 0.75 54.8466 2.41974 54.6461 4.33788L49.631 52.3157C49.4572 53.9784 48.0504 55.238 46.3787 55.2278L4.46341 54.9706C2.52935 54.9587 1.03362 53.2707 1.25464 51.3493L1.66867 47.75H5Z`,fill:backgroundColor.value,stroke:strokeColor.value,"stroke-width":`1.5`},null,8,_hoisted_5$82),createBaseVNode(`path`,{d:`M4 11H1L6 28L1 45H4L9.5 28L4 11Z`,fill:intoColor.value},null,8,_hoisted_6$68)],8,_hoisted_4$95)):(openBlock(),createElementBlock(`svg`,{key:0,id:`note_${unref(bgId)}`,style:{width:`var(--note-size)`,height:`var(--note-size)`},viewBox:`0 0 56 56`,fill:`none`,xmlns:`http://www.w3.org/2000/svg`},[createBaseVNode(`path`,{d:`M9.45521 0.75H51.4137C53.3423 0.75 54.8466 2.41974 54.6461 4.33788L49.631 52.3157C49.4572 53.9784 48.0504 55.238 46.3787 55.2278L4.41965 54.9703C2.49833 54.9585 1.00656 53.2915 1.2074 51.3807L6.22301 3.66028C6.39689 2.00598 7.7918 0.75 9.45521 0.75Z`,fill:backgroundColor.value,stroke:strokeColor.value,"stroke-width":`1.5`},null,8,_hoisted_3$117)],8,_hoisted_2$131))],4),createBaseVNode(`div`,_hoisted_7$59,[createBaseVNode(`div`,_hoisted_8$49,[unref(icons)[__props.note.type]?(openBlock(),createBlock(unref(bngIcon_default),{key:0,class:normalizeClass([`note-icon`,{left:__props.note.isLeft}]),type:__props.note.type},null,8,[`type`,`class`])):__props.note.typeExt&¬eUrl.value?(openBlock(),createElementBlock(`div`,{key:1,class:normalizeClass([`note-icon svg-used`,[__props.note.type,{left:__props.note.isLeft}]]),style:normalizeStyle(noteUrl.value?{maskImage:`url(${noteUrl.value})`,WebkitMaskImage:`url(${noteUrl.value})`}:null)},null,6)):createCommentVNode(``,!0),__props.note.turnTypeValue?(openBlock(),createElementBlock(`div`,{key:2,class:normalizeClass([`turn-value`,{left:__props.note.isLeft,"is-into":__props.note.isInto,"text-2-chars":__props.note.turnTypeValue.length===2}])},toDisplayString(__props.note.turnTypeValue),3)):createCommentVNode(``,!0)]),__props.note.turnModifier?(openBlock(),createElementBlock(`div`,_hoisted_9$43,[createVNode(unref(bngIcon_default),{type:__props.note.turnModifier,class:`icon-small`,color:colorNoteIcon.value},null,8,[`type`,`color`])])):createCommentVNode(``,!0),__props.note.additionalNote&&(__props.note.additionalNote.icon||__props.note.additionalNote.text)?(openBlock(),createElementBlock(`div`,_hoisted_10$36,[__props.note.additionalNote.icon?(openBlock(),createBlock(unref(bngIcon_default),{key:0,type:__props.note.additionalNote.icon,color:__props.note.additionalNote.color,class:`icon-small`},null,8,[`type`,`color`])):__props.note.additionalNote.text?(openBlock(),createElementBlock(`span`,{key:1,class:`add-text`,style:normalizeStyle(__props.note.additionalNote.color?{color:__props.note.additionalNote.color}:null)},toDisplayString(__props.note.additionalNote.text),5)):createCommentVNode(``,!0)])):createCommentVNode(``,!0)]),__props.note.distance?(openBlock(),createElementBlock(`div`,_hoisted_11$32,toDisplayString(__props.note.distance),1)):createCommentVNode(``,!0)]))}},PaceNote_default=__plugin_vue_export_helper_default(_sfc_main$176,[[`__scopeId`,`data-v-8c4cf384`]]),_hoisted_1$157={class:`pacenotes-app`},_hoisted_2$130={class:`notes-container`},FADE_DURATION=250,TOTAL_SLOTS=4,DEFAULT_NOTE_SIZE=1.8,_sfc_main$175={__name:`app`,setup(__props){useCssVars(_ctx=>({v492216b0:noteSize.value}));let incomingQueue=ref([]),noteSize=ref(DEFAULT_NOTE_SIZE),events$3=useEvents(),{lua}=useBridge(),devEnv=reactive({env:window.beamng&&!window.beamng.shipping,vue:!1}),debugSlots=computed(()=>incomingQueue.value.map(slot=>slot?`id=${slot.note.id} pnId=${slot.pacenoteId} ts=${slot.serialNo} type=${slot.note.type} isFading=${slot.isFading} isCurrent=${slot.isCurrent}`:null)),firstFourFromQueue=computed(()=>{let result=[...incomingQueue.value.slice(0,TOTAL_SLOTS)];for(;result.length<4;)result.push({id:-1,type:`empty`});return result});function getNoteKey(slot,index){return!slot||!slot.note?`empty-${index}`:`${slot.note.id}-${index}`}function getNoteWithSize(slot){return!slot||!slot.note?{type:`empty`,size:noteSize.value}:{...slot.note,size:noteSize.value}}let mockNotes=[{id:`q1`,pnId:`1`,type:`turn3`,isLeft:!1,turnTypeValue:`3`,distance:`140`,background:{color:`var(--bng-ter-yellow-300)`,strokeColor:`var(--bng-ter-yellow-200)`,opacity:.8}},{id:`q2`,pnId:`2`,type:`turnHp`,isLeft:!0,isInto:!0,background:{color:`var(--bng-add-red-500)`,strokeColor:`var(--bng-add-red-400)`,opacity:.8},additionalNote:{icon:`scissorsSlashed`,color:`var(--bng-add-red-400)`}},{id:`q3`,pnId:`2`,type:`jumpOverBump`,isLeft:!1,turnModifier:`mathLessThan`,additionalNote:{icon:`circleSlashed`,color:`var(--bng-ter-yellow-100)`}},{id:`q4`,pnId:`3`,type:`turn6`,isLeft:!0,turnTypeValue:`6`,distance:`140`,background:{color:`var(--bng-ter-yellow-300)`,strokeColor:`var(--bng-ter-yellow-200)`,opacity:.8}},{id:`q5`,pnId:`3`,type:`rocks`,isLeft:!0,distance:`50`}];function updateCurrent(){if(incomingQueue.value.length===0||(incomingQueue.value=incomingQueue.value.filter(item=>item!==null),incomingQueue.value.length===0))return;let firstPacenoteId=incomingQueue.value[0].pacenoteId;incomingQueue.value.forEach(slot=>{slot&&!slot.isFading&&(slot.isCurrent=slot.pacenoteId===firstPacenoteId)})}function addToQueue(newItems,serialNo){try{(Array.isArray(newItems)?newItems:[newItems]).forEach(note=>{if(!note.id||!note.type){console.warn(`Invalid note format:`,JSON.stringify(note,null,2));return}let val={note,isVisible:!0,isFading:!1,isCurrent:!1,pacenoteId:note.pnId,serialNo};incomingQueue.value.push(val)}),updateCurrent()}catch(error){console.error(`Error adding to queue:`,error)}}onMounted(()=>{lua.pacenotes&&lua.pacenotes.onPaceNotesAppMounted&&lua.pacenotes.onPaceNotesAppMounted(),events$3.on(`showVisualPacenote2`,pacenoteEvent=>{let serialNo=pacenoteEvent.serialNo,notes=pacenoteEvent.visualPacenotes;addToQueue(notes,serialNo)}),events$3.on(`clearOneVisualPacenote`,serialNo=>{clearOne(serialNo)}),events$3.on(`clearAllVisualPacenotes`,()=>{clearAll()})}),onUnmounted(()=>{lua.pacenotes&&lua.pacenotes.onPaceNotesAppUnmounted&&lua.pacenotes.onPaceNotesAppUnmounted()});let testAddSequence=()=>{console.log(`Adding sequence...`);let fakeSerialNo=666,lastPnid=0;mockNotes.forEach(note=>{note.pnId!==lastPnid&&(fakeSerialNo++,lastPnid=note.pnId),addToQueue(note,fakeSerialNo)}),console.log(`Current queue:`,incomingQueue.value)},clearAll=()=>{incomingQueue.value=[]},clearOne=serialNo=>{let fadeCount=0,fadeExpected=0;incomingQueue.value.forEach((item,index)=>{item.serialNo<=serialNo&&(item.isFading=!0,item.isVisible=!1,item.isCurrent=!1,fadeExpected++),setTimeout(()=>{item&&item.isFading&&(incomingQueue.value[index]=null,fadeCount++,fadeCount===fadeExpected&&updateCurrent())},FADE_DURATION)})},testClearAll=()=>{clearAll()},testClearOne=()=>{let serialNo=incomingQueue.value[0].serialNo;clearOne(serialNo)};(devEnv.env||devEnv.vue)&&(window.testPaceNotes={addSequence:testAddSequence,clearAll:testClearAll,clearOne:testClearOne,getState:()=>({queue:incomingQueue.value,slots:debugSlots.value})});function onAnimationEnd(index){let slot=incomingQueue.value[index];slot&&slot.isVisible&&!slot.isFading&&(slot.hasAnimated=!0)}return ref(null),(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$157,[createBaseVNode(`div`,_hoisted_2$130,[_cache[1]||=createBaseVNode(`div`,{class:`spacer`},null,-1),(openBlock(!0),createElementBlock(Fragment,null,renderList(firstFourFromQueue.value,(slot,index)=>(openBlock(),createBlock(PaceNote_default,{key:getNoteKey(slot,index),class:normalizeClass({"pacenote-initial":!slot?.hasAnimated,[`position-${index}`]:!0,"fade-out":slot&&slot.isFading,"fade-in":slot&&slot.isVisible&&!slot.isFading&&!slot.hasAnimated,hidden:!slot||!slot.isVisible&&!slot.isFading,current:slot&&slot.isCurrent}),note:getNoteWithSize(slot),onAnimationend:$event=>onAnimationEnd(index)},null,8,[`class`,`note`,`onAnimationend`]))),128))]),createCommentVNode(``,!0)]))}},app_default$28=__plugin_vue_export_helper_default(_sfc_main$175,[[`__scopeId`,`data-v-13adc0e2`]]),_hoisted_1$156={class:`countdown-top`},_hoisted_2$129={key:0,class:`countdown-go`},_hoisted_3$116={class:`countdown-bottom`},_hoisted_4$94={class:`rally-loop-manager-text`},_hoisted_5$81={class:`time-main`},_hoisted_6$67={key:0,class:`time-period`},_sfc_main$174={__name:`CountdownWidget`,props:{rallyLoopManager:{type:String,default:`--:--:--`},period:{type:String,default:null},countdown:{type:Number,default:10}},setup(__props){let props=__props,stage=computed(()=>props.countdown<=0?6:props.countdown>5?0:6-props.countdown);return(_ctx,_cache)=>(openBlock(),createElementBlock(Fragment,null,[createBaseVNode(`div`,_hoisted_1$156,[stage.value===6?(openBlock(),createElementBlock(`div`,_hoisted_2$129)):(openBlock(),createElementBlock(Fragment,{key:1},[createBaseVNode(`div`,{class:normalizeClass([`countdown-square`,{visible:stage.value>=1}])},null,2),createBaseVNode(`div`,{class:normalizeClass([`countdown-square`,{visible:stage.value>=2}])},null,2),createBaseVNode(`div`,{class:normalizeClass([`countdown-square`,{visible:stage.value>=3}])},null,2),createBaseVNode(`div`,{class:normalizeClass([`countdown-square`,{visible:stage.value>=4}])},null,2),createBaseVNode(`div`,{class:normalizeClass([`countdown-square`,{visible:stage.value>=5}])},null,2)],64))]),createBaseVNode(`div`,_hoisted_3$116,[createBaseVNode(`div`,_hoisted_4$94,[createBaseVNode(`span`,_hoisted_5$81,toDisplayString(__props.rallyLoopManager),1),__props.period?(openBlock(),createElementBlock(`span`,_hoisted_6$67,toDisplayString(__props.period),1)):createCommentVNode(``,!0)])])],64))}},CountdownWidget_default=__plugin_vue_export_helper_default(_sfc_main$174,[[`__scopeId`,`data-v-a0ececba`]]),_hoisted_1$155={class:`vehicle-proximity`},_hoisted_2$128={class:`top-row`},_hoisted_3$115={class:`proximity-status`},_hoisted_4$93={key:2},_sfc_main$173={__name:`VehicleProximity`,props:{vehicleProximity:{type:Object,required:!0},stage:{type:String,required:!0},precision:{type:Number,default:0,validator:value=>value>=0&&value<=2},badgeText:{type:String,default:``},instruction:{type:Object,required:!1,default:()=>({text:``,type:`notice`}),validator:value=>value?typeof value.text==`string`&&[`alert`,`alert-sm`,`notice`].includes(value.type):!0},instruction2:{type:Object,required:!1,default:()=>({structuredText:null})}},setup(__props){let props=__props,distanceDimmed=computed(()=>props.stage===`stop`||props.stage===`staged`),hasLabel=computed(()=>props.stage===`approaching`&&props.badgeText),formattedDistance=computed(()=>{let dist=props.vehicleProximity.distance;if(Math.abs(dist)>200)return`${(dist/1e3).toFixed(2)}km`;if(dist<0){let multiplier=10**props.precision,flooredDist=Math.floor(dist*multiplier)/multiplier;return`${(flooredDist===0?0:flooredDist).toFixed(props.precision)}m`}return`${dist.toFixed(props.precision)}m`});return(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$155,[createBaseVNode(`div`,_hoisted_2$128,[createBaseVNode(`div`,_hoisted_3$115,[createBaseVNode(`div`,{class:normalizeClass([`proximity-status-badge`,[__props.stage,{"has-label":hasLabel.value}]])},[__props.stage===`stop`?(openBlock(),createElementBlock(Fragment,{key:0},[createTextVNode(`STOP`)],64)):__props.stage===`goback`?(openBlock(),createElementBlock(Fragment,{key:1},[createTextVNode(`BACK`)],64)):__props.stage===`slow`?(openBlock(),createElementBlock(Fragment,{key:2},[createTextVNode(`SLOW`)],64)):__props.stage===`staged`?(openBlock(),createElementBlock(Fragment,{key:3},[createTextVNode(`STAGED`)],64)):__props.stage===`approaching`?(openBlock(),createElementBlock(Fragment,{key:4},[createTextVNode(toDisplayString(__props.badgeText),1)],64)):createCommentVNode(``,!0)],2)]),createBaseVNode(`div`,{class:normalizeClass([`proximity-distance`,{dimmed:distanceDimmed.value}])},toDisplayString(formattedDistance.value),3)]),__props.instruction?.text?(openBlock(),createElementBlock(`div`,{key:0,class:normalizeClass([`instruction-row`,__props.instruction?.type||`notice`])},toDisplayString(__props.instruction?.text),3)):createCommentVNode(``,!0),__props.instruction2?.structuredText?(openBlock(),createElementBlock(`div`,{key:1,class:normalizeClass([`instruction-row`,[__props.instruction2?.type||`notice`,{flash:__props.instruction2?.flash}]])},[(openBlock(!0),createElementBlock(Fragment,null,renderList(__props.instruction2?.structuredText,item=>(openBlock(),createElementBlock(Fragment,{key:item.id},[item.type===`clock`?(openBlock(),createElementBlock(`span`,{key:0,class:normalizeClass(item.class)},toDisplayString(item.val),3)):item.type===`penalty`?(openBlock(),createElementBlock(`span`,{key:1,class:normalizeClass(item.class)},toDisplayString(item.val),3)):(openBlock(),createElementBlock(`span`,_hoisted_4$93,toDisplayString(item),1))],64))),128))],2)):createCommentVNode(``,!0)]))}},VehicleProximity_default=__plugin_vue_export_helper_default(_sfc_main$173,[[`__scopeId`,`data-v-871af6e6`]]),_hoisted_1$154={class:`rally-countdown-app-container`},_hoisted_2$127={class:`panel-countdown`},_hoisted_3$114={key:2,class:`section-interact-hint`},_sfc_main$172={__name:`appCountdown`,setup(__props){useCssVars(_ctx=>({v730cc8f6:themeColor.value}));let{lua}=useBridge(),devEnv=reactive({env:window.beamng&&!window.beamng.shipping,vue:!1}),showDebugInfo=ref(!1),ActiveState={INACTIVE:`inactive`,VEHICLE_PROXIMITY:`vehicleProximity`,STAGE_ACTIVE:`stageActive`,COUNTDOWN:`countdown`},rallyClockData=reactive({wallClockTime:null,day:null,totalTime:0,canSkipTimeControls:!1,isTimeControlSkipAvailable:!1,canSkipCountdown:!1,isNgrcMode:!1}),activeState=ref(ActiveState.INACTIVE),vehicleProximityData=reactive({isNear:!1,distance:0,distanceToPlane:0,isStopped:!1,isFrozen:!1,usingGroundMarkerDistance:!1}),scheduleData=reactive({label:null,eventType:null,ssLabel:null,eventWallClockStart:null,eventWallClockEnd:null,timeDiff:null,timeDiffWithEnd:null,lateness:null,penalty:0,hasPenalty:!1,canIncurLatePenalty:!1,speedLimit:null,speedLimitDisplay:null,speedUnit:`km/h`,isSpeeding:!1}),stageData=reactive({currentSSTime:null,isActive:!1,isComplete:!1,splits:[],label:null,completion:{distM:0,distPct:0}}),countdownData=reactive({countdown:null,state:null}),themeColor=computed(()=>`#07ff00`),canInteract=computed(()=>rallyClockData.canSkipTimeControls||rallyClockData.canSkipCountdown),interactLabel=computed(()=>rallyClockData.canSkipCountdown||rallyClockData.canSkipTimeControls?`[action=gameplay_interact]Skip Clock`:``),proximityStage=computed(()=>{scheduleData.eventType;let distance=vehicleProximityData.distance;return scheduleData.eventType===`ss_start`?vehicleProximityData.isNear&&vehicleProximityData.isStopped?`staged`:distance<0?`goback`:vehicleProximityData.isNear&&!vehicleProximityData.isStopped?`stop`:!vehicleProximityData.isNear&&distance>=0&&distance<=25?`slow`:`approaching`:distance<0?`goback`:vehicleProximityData.isNear?`stop`:!vehicleProximityData.isNear&&distance>=0&&distance<=25||scheduleData.eventType===`ss_stop`?`slow`:`approaching`}),distancePrecision=computed(()=>{let distAbs=Math.abs(vehicleProximityData.distance),closenessThreshold=5;if(scheduleData.eventType===`ss_start`){if(distAbs<5)return proximityStage.value===`stop`||proximityStage.value===`goback`||proximityStage.value===`staged`||proximityStage.value===`slow`?2:0}else if((scheduleData.eventType===`tc`||scheduleData.eventType===`ss_stop`)&&distAbs<5)return proximityStage.value===`stop`||proximityStage.value===`goback`?1:0;return 0}),badgeText=computed(()=>scheduleData.eventType===`ss_start`?`SS${scheduleData.ssLabel}`:scheduleData.eventType===`tc`?scheduleData.label:scheduleData.eventType===`ss_stop`?`SLOW`:scheduleData.eventType===`service_in`?`SERVICE`:``),proximityInstruction2=computed(()=>{let stage=proximityStage.value;if(scheduleData.eventType===`ss_start`)return{structuredText:[`Start in `,{type:`clock`,val:scheduleData.timeDiff,class:`clock-badge`}],flash:!1};if(stage===`approaching`){if(rallyClockData.isTimeControlSkipAvailable&&scheduleData.eventType===`tc`)return{structuredText:[`Slow Down for `,{type:`clock`,val:`Clock Skip`,class:`clock-badge`}],flash:!1};if(scheduleData.eventType===`service_in`||scheduleData.label===`TC0`||scheduleData.eventType===`tc`)return{structuredText:[`Limit `,{type:`penalty`,val:`${scheduleData.speedLimitDisplay}${scheduleData.speedUnit}`,class:`penalty-badge`}],flash:scheduleData.isSpeeding}}else return null}),proximityInstruction=computed(()=>{let stage=proximityStage.value,text=``,type=`notice`;return stage===`slow`?scheduleData.eventType===`ss_start`?text=`Stage vehicle at start line.`:scheduleData.eventType===`tc`||scheduleData.eventType:stage===`stop`?scheduleData.eventType:stage===`goback`||(stage===`staged`?vehicleProximityData.isFrozen:stage===`approaching`&&(scheduleData.eventType===`ss_start`?text=`Stage vehicle at start line.`:scheduleData.eventType===`tc`||scheduleData.eventType===`service_in`||scheduleData.eventType)),{text,type:`notice`}}),streamsList$1=[`rallyLoop`],streamBuffer={rallyLoop:null},rafId=null;function processStreamUpdates(){if(streamBuffer.rallyLoop){let data=streamBuffer.rallyLoop;activeState.value=data.activeState||ActiveState.INACTIVE,data.rallyClock&&Object.assign(rallyClockData,data.rallyClock),data.scheduleData&&Object.assign(scheduleData,data.scheduleData),data.stageData&&Object.assign(stageData,data.stageData),data.countdownData&&Object.assign(countdownData,data.countdownData),data.vehicleProximity&&Object.assign(vehicleProximityData,data.vehicleProximity),data.showDebugInfo!==void 0&&(showDebugInfo.value=data.showDebugInfo),streamBuffer.rallyLoop=null}rafId=requestAnimationFrame(processStreamUpdates)}rafId=requestAnimationFrame(processStreamUpdates),useStreams(streamsList$1,streams=>{streams.rallyLoop&&(streamBuffer.rallyLoop=streams.rallyLoop)}),onMounted(()=>{}),onUnmounted(()=>{rafId&&cancelAnimationFrame(rafId)});function isStageActive(){return activeState.value===ActiveState.STAGE_ACTIVE}return(devEnv.env||devEnv.vue)&&(window.rallyLoopApp={activeState,vehicleProximityData,rallyClockData,scheduleData,stageData,countdownData,proximityStage,distancePrecision,badgeText}),(_ctx,_cache)=>(openBlock(),createBlock(Transition,{name:`fade`},{default:withCtx(()=>[createBaseVNode(`div`,_hoisted_1$154,[isStageActive()?createCommentVNode(``,!0):(openBlock(),createElementBlock(`div`,{key:0,class:normalizeClass([`rally-countdown-app`,{"show-active-stage":isStageActive()}])},[activeState.value===ActiveState.VEHICLE_PROXIMITY?(openBlock(),createElementBlock(`div`,{key:0,class:normalizeClass([`section-vehicle-positioning`,{"has-interact-hint":canInteract.value}])},[createVNode(VehicleProximity_default,{"vehicle-proximity":vehicleProximityData,stage:proximityStage.value,precision:distancePrecision.value,"badge-text":badgeText.value,instruction:proximityInstruction.value,instruction2:proximityInstruction2.value},null,8,[`vehicle-proximity`,`stage`,`precision`,`badge-text`,`instruction`,`instruction2`])],2)):createCommentVNode(``,!0),activeState.value===ActiveState.COUNTDOWN?(openBlock(),createElementBlock(`div`,{key:1,class:normalizeClass([`section-vehicle-positioning`,{"has-interact-hint":canInteract.value}])},[createBaseVNode(`div`,_hoisted_2$127,[createVNode(CountdownWidget_default,{"rally-loop-manager":rallyClockData.wallClockTime?.time||`--:--:--`,period:rallyClockData.wallClockTime?.ampm||``,countdown:countdownData.countdown},null,8,[`rally-loop-manager`,`period`,`countdown`])])],2)):createCommentVNode(``,!0),canInteract.value?(openBlock(),createElementBlock(`div`,_hoisted_3$114,[createVNode(unref(dynamicComponent_default),{template:interactLabel.value,bbcode:``},null,8,[`template`])])):createCommentVNode(``,!0)],2))])]),_:1}))}},appCountdown_default=__plugin_vue_export_helper_default(_sfc_main$172,[[`__scopeId`,`data-v-bde5d1a7`]]),_hoisted_1$153={class:`rally-timecard-app-container`},_hoisted_2$126={key:0,class:`rally-timecard-app`},_hoisted_3$113={class:`interact-label-on-timecard`},_hoisted_4$92={class:`time-card`},_hoisted_5$80={class:`rally-card-header`},_hoisted_6$66={class:`header-top`},_hoisted_7$58=[`src`],_hoisted_8$48={key:0,class:`mission-name`},_hoisted_9$42={class:`rally-card-content`},_hoisted_10$35={key:0,class:`group-divider`},_hoisted_11$31={class:`col-label`},_hoisted_12$25={class:`event-label`},_hoisted_13$22={class:`event-data-container`},_hoisted_14$21={key:0,class:`time-widget`},_hoisted_15$20={class:`col-recorded-time time-widget-value time-taken-value`},_hoisted_16$20={key:0,class:`stage-time`},_hoisted_17$16={key:0,class:`ampm`},_hoisted_18$14={class:`time-widget time-widget-due`},_hoisted_19$11={class:`col-due-time time-widget-value`},_hoisted_20$10={key:0,class:`scheduled-time`},_hoisted_21$10={key:0,class:`ampm`},_hoisted_22$8={class:`time-widget-combined`},_hoisted_23$7={class:`time-widget`},_hoisted_24$6={class:`col-recorded-time time-widget-value actual-value`},_hoisted_25$5={key:0,class:`recorded-time`},_hoisted_26$4={key:0,class:`ampm`},_hoisted_27$4={class:`time-widget`},_hoisted_28$3={class:`col-status time-widget-value status-value`},_hoisted_29$3={key:0,class:`status-text early`},_hoisted_30$3={key:1,class:`status-text late`},_hoisted_31$3={key:2,class:`status-text ok`},_hoisted_32$3={key:0,class:`penalty-card`},_hoisted_33$3={class:`rally-card-header penalty-card-header`},_hoisted_34$3={class:`header-top`},_hoisted_35$2={class:`penalty-total-header`},_hoisted_36$2={class:`total-value`},_hoisted_37$1={class:`penalty-card-content`},_hoisted_38$1={class:`penalty-group-header`},_hoisted_39$1={class:`group-name`},_hoisted_40$1={class:`group-total`},_hoisted_41$1={class:`penalty-list`},_hoisted_42$1={class:`penalty-type`},_hoisted_43$1={class:`penalty-amount`},_hoisted_44$1={key:1,class:`interact-label`},_hoisted_45$1={class:`interact-label-text`},_sfc_main$171={__name:`appTimecard`,setup(__props){useCssVars(_ctx=>({a6aff4e0:themeColor.value}));let{lua}=useBridge(),events$3=useEvents(),penaltyData=ref({totalPenalty:0,groups:[]}),displayMode=ref(1);reactive({env:window.beamng&&!window.beamng.shipping,vue:!1}),events$3.on(`RallyGameplayInteract`,data=>{data&&data.forceShowTimecard?displayMode.value=1:displayMode.value===1?displayMode.value=0:displayMode.value=1});let toggleLabel=computed(()=>displayMode.value===1?`Hide`:`Show`),interactLabel=computed(()=>`[action=gameplay_interact]`),ActiveState={INACTIVE:`inactive`,VEHICLE_PROXIMITY:`vehicleProximity`,STAGE_ACTIVE:`stageActive`,COUNTDOWN:`countdown`},showDebugInfo=ref(!1),missionName=ref(``),activeState=ref(ActiveState.INACTIVE),timecardData=ref([]),rallyClockData=reactive({}),vehicleProximityData=reactive({}),scheduleData=reactive({}),stageData=reactive({}),countdownData=reactive({}),themeColor=computed(()=>`#07ff00`);function shouldShowApp(){return displayMode.value===1}function formatPenaltyType(type){return type?type.replace(/_/g,` `):``}let streamsList$1=[`rallyLoop`],streamBuffer={rallyLoop:null},rafId=null;function processStreamUpdates(){if(streamBuffer.rallyLoop){let data=streamBuffer.rallyLoop;activeState.value=data.activeState||ActiveState.INACTIVE,data.rallyClock&&Object.assign(rallyClockData,data.rallyClock),data.scheduleData&&Object.assign(scheduleData,data.scheduleData),data.timecardData&&(timecardData.value=data.timecardData),data.penaltyData&&(penaltyData.value=data.penaltyData),data.stageData&&Object.assign(stageData,data.stageData),data.countdownData&&Object.assign(countdownData,data.countdownData),data.vehicleProximity&&Object.assign(vehicleProximityData,data.vehicleProximity),data.showDebugInfo!==void 0&&(showDebugInfo.value=data.showDebugInfo),data.missionName!==void 0&&(missionName.value=data.missionName||``),streamBuffer.rallyLoop=null}rafId=requestAnimationFrame(processStreamUpdates)}return rafId=requestAnimationFrame(processStreamUpdates),useStreams(streamsList$1,streams=>{streams.rallyLoop&&(streamBuffer.rallyLoop=streams.rallyLoop)}),onMounted(()=>{}),onUnmounted(()=>{rafId&&cancelAnimationFrame(rafId)}),(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$153,[createVNode(Transition,{name:`slide`},{default:withCtx(()=>[shouldShowApp()?(openBlock(),createElementBlock(`div`,_hoisted_2$126,[createBaseVNode(`div`,null,[createBaseVNode(`div`,_hoisted_3$113,[createVNode(unref(dynamicComponent_default),{template:`[action=gameplay_interact]${toggleLabel.value} Time Card`,bbcode:``},null,8,[`template`])]),createBaseVNode(`div`,_hoisted_4$92,[createBaseVNode(`div`,_hoisted_5$80,[createBaseVNode(`div`,_hoisted_6$66,[_cache[0]||=createBaseVNode(`span`,{class:`rally-card-title`},`TIME CARD`,-1),createBaseVNode(`img`,{class:`header-beamng-logo`,src:unref(getAssetURL)(`images/beamng-logo-mono_189x174.png`)},null,8,_hoisted_7$58)]),missionName.value?(openBlock(),createElementBlock(`div`,_hoisted_8$48,`Event: `+toDisplayString(missionName.value),1)):createCommentVNode(``,!0)]),createBaseVNode(`div`,_hoisted_9$42,[(openBlock(!0),createElementBlock(Fragment,null,renderList(timecardData.value,(entry,idx)=>(openBlock(),createElementBlock(Fragment,{key:idx},[idx>0&&entry.group!==timecardData.value[idx-1].group?(openBlock(),createElementBlock(`div`,_hoisted_10$35)):createCommentVNode(``,!0),createBaseVNode(`div`,{class:normalizeClass([`checklist-row`,{completed:entry.recordedTime||entry.stageTime,"stage-entry":entry.isStageEntry,early:entry.status===`early`,late:entry.status===`late`,"on-time":entry.status===`on-time`,pending:!entry.recordedTime&&!entry.stageTime}])},[createBaseVNode(`div`,_hoisted_11$31,[_cache[1]||=createBaseVNode(`div`,{class:`event-label-top`},`\xA0`,-1),createBaseVNode(`div`,_hoisted_12$25,toDisplayString(entry.label),1)]),createBaseVNode(`div`,_hoisted_13$22,[entry.isStageEntry?(openBlock(),createElementBlock(`div`,_hoisted_14$21,[_cache[2]||=createBaseVNode(`div`,{class:`time-widget-label`},`Time Taken`,-1),createBaseVNode(`div`,_hoisted_15$20,[entry.stageTime?(openBlock(),createElementBlock(`div`,_hoisted_16$20,[createTextVNode(toDisplayString(entry.stageTime),1),entry.stageTime.ampm?(openBlock(),createElementBlock(`span`,_hoisted_17$16,toDisplayString(entry.stageTime.ampm),1)):createCommentVNode(``,!0)])):createCommentVNode(``,!0)])])):(openBlock(),createElementBlock(Fragment,{key:1},[createBaseVNode(`div`,_hoisted_18$14,[_cache[3]||=createBaseVNode(`div`,{class:`time-widget-label`},`Due`,-1),createBaseVNode(`div`,_hoisted_19$11,[entry.scheduledTime?(openBlock(),createElementBlock(`div`,_hoisted_20$10,[createTextVNode(toDisplayString(entry.scheduledTime.time),1),entry.scheduledTime.ampm?(openBlock(),createElementBlock(`span`,_hoisted_21$10,toDisplayString(entry.scheduledTime.ampm),1)):createCommentVNode(``,!0)])):createCommentVNode(``,!0)])]),createBaseVNode(`div`,_hoisted_22$8,[createBaseVNode(`div`,_hoisted_23$7,[_cache[4]||=createBaseVNode(`div`,{class:`time-widget-label`},`Actual`,-1),createBaseVNode(`div`,_hoisted_24$6,[entry.recordedTime?(openBlock(),createElementBlock(`div`,_hoisted_25$5,[createTextVNode(toDisplayString(entry.recordedTime.time),1),entry.recordedTime.ampm?(openBlock(),createElementBlock(`span`,_hoisted_26$4,toDisplayString(entry.recordedTime.ampm),1)):createCommentVNode(``,!0)])):createCommentVNode(``,!0)])]),createBaseVNode(`div`,_hoisted_27$4,[_cache[5]||=createBaseVNode(`div`,{class:`time-widget-label`},`Status`,-1),createBaseVNode(`div`,_hoisted_28$3,[entry.status===`early`?(openBlock(),createElementBlock(`span`,_hoisted_29$3,`EARLY`)):entry.status===`late`?(openBlock(),createElementBlock(`span`,_hoisted_30$3,`LATE`)):entry.recordedTime||entry.status===`on-time`?(openBlock(),createElementBlock(`span`,_hoisted_31$3,`OK`)):createCommentVNode(``,!0)])])])],64))])],2)],64))),128))])]),penaltyData.value&&penaltyData.value.totalPenalty>0?(openBlock(),createElementBlock(`div`,_hoisted_32$3,[createBaseVNode(`div`,_hoisted_33$3,[createBaseVNode(`div`,_hoisted_34$3,[_cache[7]||=createBaseVNode(`span`,{class:`rally-card-title`},`PENALTIES`,-1),createBaseVNode(`div`,_hoisted_35$2,[_cache[6]||=createBaseVNode(`span`,{class:`total-label`},`Total`,-1),createBaseVNode(`span`,_hoisted_36$2,toDisplayString(penaltyData.value.totalPenalty)+`s`,1)])])]),createBaseVNode(`div`,_hoisted_37$1,[(openBlock(!0),createElementBlock(Fragment,null,renderList(penaltyData.value.groups,(group,idx)=>withDirectives((openBlock(),createElementBlock(`div`,{key:idx,class:`penalty-group`},[createBaseVNode(`div`,_hoisted_38$1,[createBaseVNode(`span`,_hoisted_39$1,toDisplayString(group.eventGroup),1),_cache[8]||=createBaseVNode(`span`,{class:`group-mid`},null,-1),createBaseVNode(`span`,_hoisted_40$1,toDisplayString(group.totalPenalty)+`s`,1)]),createBaseVNode(`div`,_hoisted_41$1,[(openBlock(!0),createElementBlock(Fragment,null,renderList(group.penalties,(penalty,pidx)=>(openBlock(),createElementBlock(`div`,{key:pidx,class:`penalty-item`},[createBaseVNode(`span`,_hoisted_42$1,toDisplayString(formatPenaltyType(penalty.type)),1),createBaseVNode(`span`,_hoisted_43$1,toDisplayString(penalty.amount)+`s (x`+toDisplayString(penalty.count)+`)`,1)]))),128))])])),[[vShow,group.totalPenalty>0]])),128))])])):createCommentVNode(``,!0)])])):(openBlock(),createElementBlock(`div`,_hoisted_44$1,[createBaseVNode(`div`,null,[createVNode(unref(dynamicComponent_default),{template:interactLabel.value,bbcode:``},null,8,[`template`]),createBaseVNode(`div`,_hoisted_45$1,[createBaseVNode(`div`,null,toDisplayString(toggleLabel.value),1),_cache[9]||=createBaseVNode(`div`,null,`Time Card`,-1)])])]))]),_:1})]))}},appTimecard_default=__plugin_vue_export_helper_default(_sfc_main$171,[[`__scopeId`,`data-v-216504fd`]]),_hoisted_1$152={class:`rally-dashboard-app-container`},_hoisted_2$125={class:`dashboard-widget widget-rally-clock`},_hoisted_3$112={key:0,class:`period`},_hoisted_4$91={class:`dashboard-widget widget-rally-sstime`},_hoisted_5$79={class:`widget-value`},_hoisted_6$65={class:`dashboard-widget widget-rally-objective`},_hoisted_7$57={class:`widget-value`},_hoisted_8$47={key:2},_sfc_main$170={__name:`appDashboard`,setup(__props){let{lua}=useBridge(),events$3=useEvents(),recoverVehicleTemplate=computed(()=>` Press [action=reset_physics] to recover vehicle.`),ActiveState={INACTIVE:`inactive`,VEHICLE_PROXIMITY:`vehicleProximity`,STAGE_ACTIVE:`stageActive`,COUNTDOWN:`countdown`},rallyClockData=reactive({wallClockTime:null,day:null,totalTime:0,canSkipTimeControls:!1,canSkipCountdown:!1,isNgrcMode:!1}),activeState=ref(ActiveState.INACTIVE),clockFlash=ref(!1);events$3.on(`RallyClockSkipped`,()=>{clockFlash.value=!1,setTimeout(()=>{clockFlash.value=!0},0),setTimeout(()=>{clockFlash.value=!1},1e3)});let scheduleData=reactive({label:null,eventType:null,ssLabel:null,eventWallClockStart:null,eventWallClockEnd:null,timeDiff:null,timeDiffWithEnd:null,lateness:null,penalty:0,hasPenalty:!1,canIncurLatePenalty:!1,speedLimit:null,speedLimitDisplay:null,speedUnit:`km/h`}),formattedWallClock=computed(()=>rallyClockData.wallClockTime?{time:rallyClockData.wallClockTime.time||`--:--:--`,period:rallyClockData.wallClockTime.ampm||``}:{time:`--:--:--`,period:``}),objectiveText=computed(()=>{let obj=scheduleData;return!obj||!obj.eventType?[]:obj.eventType===`service_in`?[`Drive to your `,{type:`badge`,val:`service bay`,class:`tc-badge`},`.`]:obj.eventType===`tc`&&obj.label===`TC0`?[`Reverse out and reach `,{type:`badge`,val:obj.label,class:`tc-badge`},` between `,{type:`clock`,val:obj.eventWallClockStart,class:`clock-badge`},` - `,{type:`clock`,val:obj.eventWallClockEnd,class:`clock-badge`},`. Penalty for each minute early or late: `,{type:`badge`,val:`+10s`,class:`penalty-badge`},`.`]:obj.eventType===`tc`?[`Reach `,{type:`badge`,val:obj.label,class:`tc-badge`},` between `,{type:`clock`,val:obj.eventWallClockStart,class:`clock-badge`},` - `,{type:`clock`,val:obj.eventWallClockEnd,class:`clock-badge`},`. Penalty for each minute early or late: `,{type:`badge`,val:`10sec`,class:`penalty-badge`},`.`]:[]}),streamsList$1=[`rallyLoop`],streamBuffer={rallyLoop:null},rafId=null;function processStreamUpdates(){if(streamBuffer.rallyLoop){let data=streamBuffer.rallyLoop;activeState.value=data.activeState||ActiveState.INACTIVE,data.rallyClock&&Object.assign(rallyClockData,data.rallyClock),data.scheduleData&&Object.assign(scheduleData,data.scheduleData),streamBuffer.rallyLoop=null}rafId=requestAnimationFrame(processStreamUpdates)}rafId=requestAnimationFrame(processStreamUpdates),useStreams(streamsList$1,streams=>{streams.rallyLoop&&(streamBuffer.rallyLoop=streams.rallyLoop)}),onMounted(()=>{}),onUnmounted(()=>{rafId&&cancelAnimationFrame(rafId)});function isStageActive(){return activeState.value===ActiveState.STAGE_ACTIVE}return(_ctx,_cache)=>(openBlock(),createBlock(Transition,{name:`fade`},{default:withCtx(()=>[createBaseVNode(`div`,_hoisted_1$152,[isStageActive()?createCommentVNode(``,!0):(openBlock(),createElementBlock(`div`,{key:0,class:normalizeClass([`rally-dashboard-app`,{"show-active-stage":isStageActive()}])},[createBaseVNode(`div`,_hoisted_2$125,[_cache[0]||=createBaseVNode(`div`,{class:`widget-label`},`Event Clock`,-1),createBaseVNode(`div`,{class:normalizeClass([`widget-value clock-value`,{"flash-pink":clockFlash.value}])},[createTextVNode(toDisplayString(formattedWallClock.value.time),1),formattedWallClock.value.period?(openBlock(),createElementBlock(`span`,_hoisted_3$112,toDisplayString(formattedWallClock.value.period),1)):createCommentVNode(``,!0)],2)]),createBaseVNode(`div`,_hoisted_4$91,[_cache[1]||=createBaseVNode(`div`,{class:`widget-label`},`Your Time`,-1),createBaseVNode(`div`,_hoisted_5$79,toDisplayString(rallyClockData.totalTime),1)]),createBaseVNode(`div`,_hoisted_6$65,[_cache[2]||=createBaseVNode(`div`,{class:`widget-label`},`Instructions`,-1),createBaseVNode(`div`,_hoisted_7$57,[(openBlock(!0),createElementBlock(Fragment,null,renderList(objectiveText.value,item=>(openBlock(),createElementBlock(`span`,{key:item},[item.type===`badge`?(openBlock(),createElementBlock(`span`,{key:0,class:normalizeClass(item.class)},toDisplayString(item.val),3)):item.type===`clock`?(openBlock(),createElementBlock(`span`,{key:1,class:normalizeClass(item.class)},toDisplayString(item.val.time)+toDisplayString(item.val.period),3)):(openBlock(),createElementBlock(`span`,_hoisted_8$47,toDisplayString(item),1))]))),128)),createVNode(unref(dynamicComponent_default),{template:recoverVehicleTemplate.value,bbcode:``},null,8,[`template`])])])],2))])]),_:1}))}},appDashboard_default=__plugin_vue_export_helper_default(_sfc_main$170,[[`__scopeId`,`data-v-a3bb6c18`]]),_hoisted_1$151={class:`rally-debug-app-container`},_hoisted_2$124={key:0,class:`debug-info`},_sfc_main$169={__name:`appDebug`,setup(__props){let{lua}=useBridge(),ActiveState={INACTIVE:`inactive`,VEHICLE_PROXIMITY:`vehicleProximity`,STAGE_ACTIVE:`stageActive`,COUNTDOWN:`countdown`},showDebugInfo=ref(!0),activeState=ref(ActiveState.INACTIVE),timecardData=ref([]),penaltyData=ref({totalPenalty:0,groups:[]}),rallyClockData=reactive({}),vehicleProximityData=reactive({}),scheduleData=reactive({}),stageData=reactive({}),countdownData=reactive({}),streamsList$1=[`rallyLoop`],streamBuffer={rallyLoop:null},rafId=null;function processStreamUpdates(){if(streamBuffer.rallyLoop){let data=streamBuffer.rallyLoop;activeState.value=data.activeState||ActiveState.INACTIVE,data.rallyClock&&Object.assign(rallyClockData,data.rallyClock),data.scheduleData&&Object.assign(scheduleData,data.scheduleData),data.timecardData&&(timecardData.value=data.timecardData),data.penaltyData&&(penaltyData.value=data.penaltyData),data.stageData&&Object.assign(stageData,data.stageData),data.countdownData&&Object.assign(countdownData,data.countdownData),data.vehicleProximity&&Object.assign(vehicleProximityData,data.vehicleProximity),streamBuffer.rallyLoop=null}rafId=requestAnimationFrame(processStreamUpdates)}return rafId=requestAnimationFrame(processStreamUpdates),useStreams(streamsList$1,streams=>{streams.rallyLoop&&(streamBuffer.rallyLoop=streams.rallyLoop)}),onMounted(()=>{}),onUnmounted(()=>{rafId&&cancelAnimationFrame(rafId)}),(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$151,[showDebugInfo.value?(openBlock(),createElementBlock(`div`,_hoisted_2$124,[createBaseVNode(`div`,null,`activeState: "`+toDisplayString(activeState.value)+`"`,1),createBaseVNode(`div`,null,`rallyClock: `+toDisplayString(rallyClockData),1),createBaseVNode(`div`,null,`countdownData: `+toDisplayString(countdownData),1),createBaseVNode(`div`,null,`vehicleProximityData: `+toDisplayString(vehicleProximityData),1),createBaseVNode(`div`,null,`scheduleData: `+toDisplayString(scheduleData),1),createBaseVNode(`div`,null,`timecardData: `+toDisplayString(timecardData.value),1),createBaseVNode(`div`,null,`penaltyData: `+toDisplayString(penaltyData.value),1),createBaseVNode(`div`,null,`stageData: `+toDisplayString(stageData),1)])):createCommentVNode(``,!0)]))}},appDebug_default=__plugin_vue_export_helper_default(_sfc_main$169,[[`__scopeId`,`data-v-c2c6bfeb`]]),_hoisted_1$150={class:`distance-widget-svg`},_hoisted_2$123=[`x`,`y`,`height`],_hoisted_3$111=[`x`,`y`,`width`,`height`],_hoisted_4$90=[`x`,`y`,`width`,`height`],_hoisted_5$78=[`x`,`y`,`width`,`height`],_hoisted_6$64={x:0,y:`90%`,"text-anchor":`middle`},_hoisted_7$56={class:`tick-label`},_hoisted_8$46={class:`tick-label-unit`,dx:`2`},_hoisted_9$41=[`x`,`y`,`width`,`height`],_hoisted_10$34={x:0,y:`90%`,dx:`20`,"text-anchor":`end`},_hoisted_11$30={key:0,class:`tick-label-bold`},_hoisted_12$24={class:`tick-label-unit`,dx:`2`},_hoisted_13$21=[`x`,`y`,`width`,`height`],PAD_PX=20,PADRIGHT_PX=26,barHeightPct=8,barCenterY=50,tickStrokeWidth=2,tickSize=12,trackingRectSize=14,_sfc_main$168={__name:`DistanceWidgetSVGRect`,props:{distPct:{type:Number,required:!0},totalDistM:{type:Number,required:!0},splits:{type:Array,default:()=>[]},splitPrecision:{type:Number,default:1},themeColor:{type:String,required:!0},unit:{type:String,default:`km`}},setup(__props){useCssVars(_ctx=>({v94238812:__props.themeColor}));let props=__props,barStartX=PAD_PX,barY=barCenterY-barHeightPct/2;100-PADRIGHT_PX,computed(()=>PAD_PX+(100-PAD_PX-PADRIGHT_PX)*props.distPct);let currentX=computed(()=>`calc(${PAD_PX}px + (100% - ${PAD_PX+PADRIGHT_PX}px) * ${props.distPct})`),barWidth=`calc(100% - ${PAD_PX+PADRIGHT_PX}px)`,progressWidth=computed(()=>`calc((100% - ${PAD_PX+PADRIGHT_PX}px) * ${props.distPct})`),barEndX=`calc(100% - ${PADRIGHT_PX}px)`,splitMarkers=computed(()=>props.splits?props.splits.filter(s=>typeof s?.pathnodeType==`string`&&s.pathnodeType.startsWith(`split_`)).map((s,idx)=>{let pct=s.distPct||0,x=`calc(${PAD_PX}px + (100% - ${PAD_PX+PADRIGHT_PX}px) * ${pct})`;return{key:s.pathnodeId??idx,x,label:{val:s.splitLabel,unit:props.unit}}}):[]),finalSplitLabel=computed(()=>!props.splits||props.splits.length===0?{val:null,unit:null}:{val:props.splits[props.splits.length-1]?.splitLabel,unit:props.unit});return(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$150,[(openBlock(),createElementBlock(`svg`,null,[createBaseVNode(`rect`,{x:unref(barStartX)+`px`,y:barY+`%`,width:barWidth,height:barHeightPct+`%`,fill:`white`},null,8,_hoisted_2$123),createBaseVNode(`rect`,{x:unref(barStartX)+`px`,y:barY-1+`%`,width:progressWidth.value,height:barHeightPct+2+`%`,fill:`var(--theme-color)`},null,8,_hoisted_3$111),createBaseVNode(`rect`,{x:unref(barStartX)-tickSize/2+`px`,y:`calc(`+barCenterY+`% - `+tickSize/2+`px)`,width:tickSize+`px`,height:tickSize+`px`,fill:`var(--theme-color)`},null,8,_hoisted_4$90),(openBlock(!0),createElementBlock(Fragment,null,renderList(splitMarkers.value,split=>(openBlock(),createElementBlock(`g`,{key:split.key,style:normalizeStyle(`transform: translateX(${split.x})`)},[createBaseVNode(`rect`,{x:-(tickSize/2)+`px`,y:`calc(`+barCenterY+`% - `+tickSize/2+`px)`,width:tickSize+`px`,height:tickSize+`px`,"stroke-width":tickStrokeWidth,fill:`#202020`,stroke:`#ffffff`},null,8,_hoisted_5$78),createBaseVNode(`text`,_hoisted_6$64,[createBaseVNode(`tspan`,_hoisted_7$56,toDisplayString(split.label.val),1),createBaseVNode(`tspan`,_hoisted_8$46,toDisplayString(split.label.unit),1)])],4))),128)),createBaseVNode(`g`,{style:normalizeStyle(`transform: translateX(${barEndX})`)},[createBaseVNode(`rect`,{x:-(tickSize/2)+`px`,y:`calc(`+barCenterY+`% - `+tickSize/2+`px)`,width:tickSize+`px`,height:tickSize+`px`,"stroke-width":tickStrokeWidth,fill:`#202020`,stroke:`#ffffff`},null,8,_hoisted_9$41),createBaseVNode(`text`,_hoisted_10$34,[finalSplitLabel.value?(openBlock(),createElementBlock(`tspan`,_hoisted_11$30,toDisplayString(finalSplitLabel.value.val),1)):createCommentVNode(``,!0),createBaseVNode(`tspan`,_hoisted_12$24,toDisplayString(finalSplitLabel.value.unit),1)])],4),createBaseVNode(`g`,{style:normalizeStyle(`transform: translateX(${currentX.value})`)},[createBaseVNode(`rect`,{x:-(trackingRectSize/2)+`px`,y:`calc(`+barCenterY+`% - `+trackingRectSize/2+`px)`,width:trackingRectSize+`px`,height:trackingRectSize+`px`,fill:`var(--theme-color)`},null,8,_hoisted_13$21)],4)]))]))}},DistanceWidgetSVGRect_default=__plugin_vue_export_helper_default(_sfc_main$168,[[`__scopeId`,`data-v-9c6ef477`]]);function rallyStageThemeColor(withAlpha=null){return`#009a1a${withAlpha===!0?`a0`:``}`}var _hoisted_1$149={key:0,class:`rally-stage-timing-app`},_sfc_main$167={__name:`appStageProgress`,setup(__props){useCssVars(_ctx=>({v708a5eb2:themeColor.value}));let{lua}=useBridge();reactive({env:window.beamng&&!window.beamng.shipping,vue:!1});let ActiveState={INACTIVE:`inactive`,VEHICLE_PROXIMITY:`vehicleProximity`,STAGE_ACTIVE:`stageActive`,COUNTDOWN:`countdown`},rallyClockData=reactive({wallClockSecs:null,epochTime:null,day:null,totalPenalty:0,totalTime:0,use24hFormat:!0,canSkipTimeControls:!1,canSkipCountdown:!1,isNgrcMode:!1}),activeState=ref(ActiveState.INACTIVE),vehicleProximityData=reactive({isNear:!1,distance:0,distanceToPlane:0,isStopped:!1,isFrozen:!1,usingGroundMarkerDistance:!1}),scheduleData=reactive({label:null,eventType:null,ssLabel:null,eventWallClockStart:null,eventWallClockEnd:null,timeDiff:null,timeDiffWithEnd:null,lateness:null,penalty:0,hasPenalty:!1,canIncurLatePenalty:!1}),stageData=reactive({currentSSTime:null,isActive:!1,isComplete:!1,splits:[],label:null,completion:{distPct:0},unit:`km`}),themeColor=computed(()=>rallyStageThemeColor()),streamsList$1=[`rallyLoop`],streamBuffer={rallyLoop:null},rafId=null;function processStreamUpdates(){if(streamBuffer.rallyLoop){let data=streamBuffer.rallyLoop;activeState.value=data.activeState||ActiveState.INACTIVE,data.rallyClock&&Object.assign(rallyClockData,data.rallyClock),data.scheduleData&&Object.assign(scheduleData,data.scheduleData),data.stageData&&Object.assign(stageData,data.stageData),data.vehicleProximity&&Object.assign(vehicleProximityData,data.vehicleProximity),streamBuffer.rallyLoop=null}rafId=requestAnimationFrame(processStreamUpdates)}rafId=requestAnimationFrame(processStreamUpdates),useStreams(streamsList$1,streams=>{streams.rallyLoop&&(streamBuffer.rallyLoop=streams.rallyLoop)}),onMounted(()=>{}),onUnmounted(()=>{rafId&&cancelAnimationFrame(rafId)});function shouldShowApp(){return!0}return(_ctx,_cache)=>(openBlock(),createBlock(Transition,{name:`fade`},{default:withCtx(()=>[shouldShowApp()?(openBlock(),createElementBlock(`div`,_hoisted_1$149,[createVNode(DistanceWidgetSVGRect_default,{"dist-pct":stageData.completion.distPct,"total-dist-m":stageData.completion.totalDistM,splits:stageData.splits,"theme-color":themeColor.value,unit:stageData.unit},null,8,[`dist-pct`,`total-dist-m`,`splits`,`theme-color`,`unit`])])):createCommentVNode(``,!0)]),_:1}))}},appStageProgress_default=__plugin_vue_export_helper_default(_sfc_main$167,[[`__scopeId`,`data-v-a8eba296`]]);function formatSSTime(seconds,activeState){if(activeState===`inactive`)return`--:--:--`;let roundedSeconds=Math.round(seconds*10)/10,hours=Math.floor(roundedSeconds/3600),minutes=Math.floor(roundedSeconds%3600/60),secs=Math.floor(roundedSeconds%60),tenths=Math.round(roundedSeconds%1*10)%10;return hours>0?`${hours}:${String(minutes).padStart(2,`0`)}:${String(secs).padStart(2,`0`)}.${tenths}`:minutes>0?`${minutes}:${String(secs).padStart(2,`0`)}.${tenths}`:`${secs}.${tenths}`}var _hoisted_1$148={key:0,class:`rally-stage-timing-app`},_hoisted_2$122={class:`section-active-stage`},_hoisted_3$110={class:`stage-header`},_hoisted_4$89={class:`stage-time`},_hoisted_5$77={key:0,class:`splits-header`},_hoisted_6$63={key:1,class:`stage-splits`},_hoisted_7$55={class:`stage-split-label`},_hoisted_8$45={class:`stage-split-label-unit`},_hoisted_9$40={class:`stage-split-time`},_hoisted_10$33=[`src`],_sfc_main$166={__name:`appStageTiming`,setup(__props){let{lua}=useBridge(),ActiveState={INACTIVE:`inactive`,VEHICLE_PROXIMITY:`vehicleProximity`,STAGE_ACTIVE:`stageActive`,COUNTDOWN:`countdown`},rallyClockData=reactive({wallClockSecs:null,epochTime:null,day:null,totalPenalty:0,totalTime:0,use24hFormat:!0,canSkipTimeControls:!1,canSkipCountdown:!1,isNgrcMode:!1}),activeState=ref(ActiveState.INACTIVE),vehicleProximityData=reactive({isNear:!1,distance:0,distanceToPlane:0,isStopped:!1,isFrozen:!1,usingGroundMarkerDistance:!1}),scheduleData=reactive({label:null,eventType:null,ssLabel:null,eventWallClockStart:null,eventWallClockEnd:null,timeDiff:null,timeDiffWithEnd:null,lateness:null,penalty:0,hasPenalty:!1,canIncurLatePenalty:!1}),stageData=reactive({currentSSTime:null,isActive:!1,isComplete:!1,splits:[],label:null,completion:{distM:0,distPct:0}});computed(()=>rallyStageThemeColor(!0));let completedSplits=computed(()=>stageData.splits?.filter(split=>split.time!=null)||[]),splitUnit=computed(()=>`km`),streamsList$1=[`rallyLoop`],streamBuffer={rallyLoop:null},rafId=null;function processStreamUpdates(){if(streamBuffer.rallyLoop){let data=streamBuffer.rallyLoop;activeState.value=data.activeState||ActiveState.INACTIVE,data.rallyClock&&Object.assign(rallyClockData,data.rallyClock),data.scheduleData&&Object.assign(scheduleData,data.scheduleData),data.stageData&&Object.assign(stageData,data.stageData),data.vehicleProximity&&Object.assign(vehicleProximityData,data.vehicleProximity),streamBuffer.rallyLoop=null}rafId=requestAnimationFrame(processStreamUpdates)}rafId=requestAnimationFrame(processStreamUpdates),useStreams(streamsList$1,streams=>{streams.rallyLoop&&(streamBuffer.rallyLoop=streams.rallyLoop)}),onMounted(()=>{}),onUnmounted(()=>{rafId&&cancelAnimationFrame(rafId)});function shouldShowApp(){return!0}return(_ctx,_cache)=>(openBlock(),createBlock(Transition,{name:`fade`},{default:withCtx(()=>[shouldShowApp()?(openBlock(),createElementBlock(`div`,_hoisted_1$148,[createBaseVNode(`div`,_hoisted_2$122,[createBaseVNode(`div`,_hoisted_3$110,`STAGE `+toDisplayString(stageData.label)+` / `+toDisplayString(scheduleData.totalSSCount),1),createBaseVNode(`div`,_hoisted_4$89,toDisplayString(unref(formatSSTime)(stageData.currentSSTime,activeState.value)),1),completedSplits.value.length>0?(openBlock(),createElementBlock(`div`,_hoisted_5$77,`SPLITS`)):createCommentVNode(``,!0),completedSplits.value.length>0?(openBlock(),createElementBlock(`div`,_hoisted_6$63,[(openBlock(!0),createElementBlock(Fragment,null,renderList(completedSplits.value,split=>(openBlock(),createElementBlock(`div`,{class:`stage-split`,key:split.pathnodeId},[createBaseVNode(`div`,_hoisted_7$55,[createBaseVNode(`span`,null,toDisplayString(split.splitLabel),1),createBaseVNode(`span`,_hoisted_8$45,toDisplayString(splitUnit.value),1)]),createBaseVNode(`div`,_hoisted_9$40,toDisplayString(unref(formatSSTime)(split.time,activeState.value)),1)]))),128))])):createCommentVNode(``,!0),rallyClockData.isNgrcMode?(openBlock(),createElementBlock(`img`,{key:2,class:`stage-ngrc-badge`,src:unref(getAssetURL)(`images/ngrc_logo_dark_128x40.png`),alt:`NGRC`},null,8,_hoisted_10$33)):createCommentVNode(``,!0)])])):createCommentVNode(``,!0)]),_:1}))}},appStageTiming_default=__plugin_vue_export_helper_default(_sfc_main$166,[[`__scopeId`,`data-v-cea09957`]]),_hoisted_1$147={class:`gameplay-apps`},gameplayAppsFlashMessage=`GameplayAppsFlashMessage`,_sfc_main$165={__name:`gameplayApps`,setup(__props){let{lua}=useBridge(),events$3=useEvents(),isDrift=ref(!1),isDragStaging=ref(!1),isRally=ref(!1),isPointsBar=ref(!1),isFlashMessage=ref(!1),isCountdown=ref(!1),appStates={drift:isDrift,drag:isDragStaging,rally:isRally,pointsBar:isPointsBar,flashMessage:isFlashMessage,countdown:isCountdown},setAppVisibility=data=>{data.appId&&appStates[data.appId]&&(appStates[data.appId].value=data.visible),data.hideAll&&Object.values(appStates).forEach(state=>state.value=!1)},loadInitialVisibility=async()=>{try{let visibleApps=await lua.ui_gameplayAppContainers.getVisibleApps(`gameplayApps`);Object.values(appStates).forEach(state=>state.value=!1),Array.isArray(visibleApps)&&visibleApps.forEach(appId=>{appStates[appId]&&(appStates[appId].value=!0)})}catch{}};return onMounted(()=>{events$3.on(`setGameplayAppVisibility`,setAppVisibility),lua.ui_gameplayAppContainers.onGameplayAppContainerMounted(),loadInitialVisibility()}),onUnmounted(()=>{events$3.off(`setGameplayAppVisibility`,setAppVisibility),lua.ui_gameplayAppContainers.onGameplayAppContainerUnmounted()}),(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$147,[withDirectives((openBlock(),createBlock(resolveDynamicComponent(unref(app_default)),mergeProps({class:`app`},_ctx.$attrs),null,16)),[[vShow,isPointsBar.value]]),withDirectives((openBlock(),createBlock(resolveDynamicComponent(unref(app_default$28)),mergeProps({class:`app rally`},_ctx.$attrs),null,16)),[[vShow,isRally.value]]),withDirectives((openBlock(),createBlock(resolveDynamicComponent(unref(app_default$13)),mergeProps({class:`app`,showFlash:!1},_ctx.$attrs),null,16)),[[vShow,isDrift.value]]),withDirectives((openBlock(),createBlock(resolveDynamicComponent(unref(app_default$11)),mergeProps({class:`app`,showFlash:!1},_ctx.$attrs),null,16)),[[vShow,isDragStaging.value]]),withDirectives((openBlock(),createBlock(resolveDynamicComponent(unref(flashMessageApp_default)),mergeProps({class:`app flash-message`,"message-source":gameplayAppsFlashMessage},_ctx.$attrs),null,16)),[[vShow,isFlashMessage.value]]),withDirectives((openBlock(),createBlock(resolveDynamicComponent(unref(countdownApp_default)),mergeProps({class:`countdown`},_ctx.$attrs),null,16)),[[vShow,isCountdown.value]])]))}},gameplayApps_default=__plugin_vue_export_helper_default(_sfc_main$165,[[`__scopeId`,`data-v-8ac28a96`]]),_hoisted_1$146={class:`messages-tasks-apps`},_sfc_main$164={__name:`messagesTasksApps`,setup(__props){let{lua}=useBridge(),events$3=useEvents(),isMessages=ref(!1),isTasks=ref(!1),appStates={messages:isMessages,tasks:isTasks},setAppVisibility=data=>{data.appId&&appStates[data.appId]&&(appStates[data.appId].value=data.visible),data.hideAll&&Object.values(appStates).forEach(state=>{state.value=!1})},loadInitialVisibility=async()=>{try{let visibleApps=await lua.ui_messagesTasksAppContainers.getVisibleApps(`messagesTasksApps`);Object.values(appStates).forEach(state=>{state.value=!1}),Array.isArray(visibleApps)&&visibleApps.forEach(appId=>{appStates[appId]&&(appStates[appId].value=!0)})}catch{}};return onMounted(()=>{events$3.on(`setMessagesTasksAppVisibility`,setAppVisibility),lua.ui_messagesTasksAppContainers.onMessagesTasksAppContainerMounted(),loadInitialVisibility()}),onUnmounted(()=>{events$3.off(`setMessagesTasksAppVisibility`,setAppVisibility),lua.ui_messagesTasksAppContainers.onMessagesTasksAppContainerUnmounted()}),(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$146,[withDirectives((openBlock(),createBlock(resolveDynamicComponent(unref(app_default$27)),mergeProps({class:`app`},_ctx.$attrs),null,16)),[[vShow,isTasks.value]]),withDirectives((openBlock(),createBlock(resolveDynamicComponent(unref(app_default$32)),mergeProps({class:`app`},_ctx.$attrs),null,16)),[[vShow,isMessages.value]])]))}},messagesTasksApps_default=__plugin_vue_export_helper_default(_sfc_main$164,[[`__scopeId`,`data-v-0ac32403`]]),_sfc_main$163={__name:`countdownApp`,setup(__props){let events$3=useEvents();function convertLegacyMessage(data){return Array.isArray(data)?data.map(item=>({msg:typeof item[0]==`object`?item[0].txt:item[0],ttl:item[1],luaCall:typeof item[2]==`string`?item[2]:void 0,jsCallback:typeof item[2]==`function`?item[2]:void 0,big:item[3]??!1})):data}return onMounted(()=>{events$3.on(`ScenarioFlashMessage`,data=>{let convertedData=convertLegacyMessage(data);if(Array.isArray(convertedData)&&convertedData.length>0){let lastMessage=convertedData[convertedData.length-1];lastMessage.msg===`GO!`&&(lastMessage.jsCallback=()=>{events$3.emit(`CountdownEnded`)})}events$3.emit(`CountdownMessage`,convertedData)}),events$3.on(`ScenarioNotRunning`,()=>{events$3.emit(`CountdownMessage`,{msg:``,ttl:0})})}),(_ctx,_cache)=>(openBlock(),createBlock(bngFlashMessage_default,{"message-source":`CountdownMessage`}))}},countdownApp_default=__plugin_vue_export_helper_default(_sfc_main$163,[[`__scopeId`,`data-v-8ddc025c`]]),_sfc_main$162={__name:`flashMessageApp`,setup(__props){let events$3=useEvents();return onMounted(()=>{events$3.on(`ScenarioFlashMessage`,data=>{let convertedData=Array.isArray(data)?data.map(item=>({msg:typeof item[0]==`object`?item[0].txt:item[0],ttl:item[1],luaCall:typeof item[2]==`string`?item[2]:void 0,jsCallback:typeof item[2]==`function`?item[2]:void 0,big:item[3]??!1})):data;events$3.emit(`SimpleFlashMessage`,convertedData)}),events$3.on(`ScenarioNotRunning`,()=>{events$3.emit(`SimpleFlashMessage`,{msg:``,ttl:0})})}),(_ctx,_cache)=>(openBlock(),createBlock(bngFlashMessage_default,{"message-source":`SimpleFlashMessage`}))}},flashMessageApp_default=__plugin_vue_export_helper_default(_sfc_main$162,[[`__scopeId`,`data-v-48db34d3`]]),_hoisted_1$145={class:`generic-mission-data`},_sfc_main$161={__name:`bngGenericMissionData`,setup(__props){let events$3=useEvents(),{lua}=useBridge(),displayElements=ref([]),getElementValue=element=>element.minutes||element.seconds?``:typeof element.txt==`number`?element.txt:element.style===`text`||element.style===void 0?$translate.instant(element.txt):`Error: Unsupported style`,handleMissionDataChanged=data=>{if(data){for(;displayElements.value.length<=data.index;)displayElements.value.push(null);displayElements.value[data.index]=data.element}},handleMissionDataReset=()=>{displayElements.value=[]};return onMounted(()=>{events$3.on(`SetGenericMissionData`,handleMissionDataChanged),events$3.on(`SetGenericMissionDataResetAll`,handleMissionDataReset),lua.extensions.load(`ui_apps_genericMissionData`),lua.ui_apps_genericMissionData.sendAllData()}),(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$145,[(openBlock(!0),createElementBlock(Fragment,null,renderList(displayElements.value,(element,index)=>(openBlock(),createElementBlock(Fragment,{key:index},[element?(openBlock(),createBlock(bngSimpleDataDisplay_default,{key:0,label:_ctx.$tt(element.title),value:getElementValue(element),icon:element.icon,minutes:element.minutes,seconds:element.seconds,milliseconds:element.milliseconds,class:`mission-data-item`},null,8,[`label`,`value`,`icon`,`minutes`,`seconds`,`milliseconds`])):createCommentVNode(``,!0)],64))),128))]))}},bngGenericMissionData_default=__plugin_vue_export_helper_default(_sfc_main$161,[[`__scopeId`,`data-v-1cdb0dd5`]]),_hoisted_1$144={class:`controls-container`},_sfc_main$160={__name:`app`,setup(__props){let{$game}=useLibStore();return ref(!0),(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$144,[createVNode(unref(bngAppBindingDisplay_default))]))}},app_default$29=__plugin_vue_export_helper_default(_sfc_main$160,[[`__scopeId`,`data-v-66fafb5f`]]),_hoisted_1$143={class:`main-container-grid`},_hoisted_2$121={class:`points-display`},_hoisted_3$109={class:`star-wrapper`},_sfc_main$159={__name:`app`,setup(__props){let{lua}=useBridge(),fillPercent=ref(0),pointsLabel=ref(`0`),thresholdPercentages=ref([]),thresholdsReached=ref([]),thresholdCount=ref(0),thresholdIndices=computed(()=>Array.from({length:thresholdCount.value},(_,index)=>index));onMounted(()=>{lua.extensions.load(`ui_apps_pointsBar`),lua.ui_apps_pointsBar.requestAllData()}),onUnmounted(()=>{});let streamsList$1=[`pointsBar`];return useStreams(streamsList$1,streams=>{for(let stream of streamsList$1)if(!streams[stream])return;fillPercent.value=streams.pointsBar.fillPercent,pointsLabel.value=streams.pointsBar.pointsLabel,streams.pointsBar.thresholdPercentages&&Array.isArray(streams.pointsBar.thresholdPercentages)&&(thresholdPercentages.value=streams.pointsBar.thresholdPercentages),streams.pointsBar.thresholdsReached&&Array.isArray(streams.pointsBar.thresholdsReached)&&(thresholdsReached.value=streams.pointsBar.thresholdsReached),thresholdCount.value=streams.pointsBar.thresholdCount}),(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$143,[createBaseVNode(`div`,{class:`progress-bar-container`,style:normalizeStyle({"--threshold-percentage":thresholdPercentages.value[0]||0})},[createBaseVNode(`div`,_hoisted_2$121,toDisplayString(_ctx.$t(pointsLabel.value)),1),createBaseVNode(`div`,{class:`progress-bar`,style:normalizeStyle({width:`${fillPercent.value*100}%`})},null,4),(openBlock(!0),createElementBlock(Fragment,null,renderList(thresholdIndices.value,i=>(openBlock(),createElementBlock(`div`,{key:i,class:normalizeClass([`limit-marker`,{passed:thresholdsReached.value[i]}]),style:normalizeStyle({left:`${thresholdPercentages.value[i]}%`})},[createBaseVNode(`div`,_hoisted_3$109,[createVNode(unref(bngIcon_default),{type:thresholdsReached.value[i]?unref(icons).star:unref(icons).starSecondary,class:normalizeClass([`star-icon`,{passed:thresholdsReached.value[i]}])},null,8,[`type`,`class`])])],6))),128))],4)]))}},app_default=__plugin_vue_export_helper_default(_sfc_main$159,[[`__scopeId`,`data-v-4e2c4ac3`]]),_hoisted_1$142={key:0,class:`minimap-container-additional-info top`},_hoisted_2$120={key:0},_hoisted_3$108={key:1,class:`minimap-container-additional-info bottom`},_hoisted_4$88={key:2},_hoisted_5$76={key:0,class:`minimap-container-additional-info top round`},_hoisted_6$62={key:0},_hoisted_7$54={key:1,class:`minimap-container-additional-info bottom round`},_hoisted_8$44={key:2},transformUpdateAttempts=15,_sfc_main$158={__name:`app`,setup(__props){useCssVars(_ctx=>({v01db66c6:squareSize.value,v32146572:minimapSize.value}));let{lua}=useBridge(),events$3=useEvents(),route=useRoute(),$globalStore=inject(`$globalStore`),uiVisible=ref(!0),initialising=ref(!1),initialised=ref(!1),minimapMode=ref(`circle`),minimapContainerRef=ref(null),containerRef=ref(null);ref(null),ref(null);let resizeObserver=ref(null),mapMetrics=reactive({x:0,y:0,width:0,height:0,xRel:0,yRel:0,widthRel:0,heightRel:0}),allowedRoutes=[`/play`,``],showMinimap=computed(()=>uiVisible.value&&!loadingScreen.shown&&$globalStore.__uiAppsShown&&!$globalStore.__introPopupShown&&!popupsView.popups&&!popupsView.activities&&allowedRoutes.includes(route.path)),additionalInfo=reactive({distToTarget:null,locationName:null,policeMode:`disabled`}),hasTopInfo=computed(()=>!!additionalInfo.locationName),hasBottomInfo=computed(()=>!!(additionalInfo.distToTarget||additionalInfo.policeMode===`visibleToPolice`||additionalInfo.policeMode===`hiddenFromPolice`));watch(hasTopInfo,val=>{showMinimap.value&&requestAnimationFrame(updateDrawTransform)}),watch(hasBottomInfo,val=>{showMinimap.value&&requestAnimationFrame(updateDrawTransform)});let transformUpdateAttempt=0,minimapSize=ref(`100%`),minimapShift=ref(`0px`),squareSize=ref(`100%`);async function updateDrawTransform(){if(minimapMode.value===`circle`&&minimapContainerRef.value){let rect$1=minimapContainerRef.value.getBoundingClientRect(),size$3=Math.min(rect$1.width,rect$1.height),sizepx=size$3+`px`;minimapSize.value!==sizepx&&(minimapSize.value=sizepx,rect$1.width>rect$1.height?minimapShift.value=-(rect$1.width-size$3)/2+`px`:minimapShift.value=`0px`,await nextTick())}if(!initialised.value||!showMinimap.value||!containerRef.value)return;let screen$1={width:window.innerWidth,height:window.innerHeight,scrollX:window.scrollX,scrollY:window.scrollY},rect=containerRef.value.getBoundingClientRect();mapMetrics.x=rect.left+screen$1.scrollX,mapMetrics.y=rect.top+screen$1.scrollY,mapMetrics.width=rect.width,mapMetrics.height=rect.height,mapMetrics.xRel=mapMetrics.x/screen$1.width,mapMetrics.yRel=mapMetrics.y/screen$1.height,mapMetrics.widthRel=mapMetrics.width/screen$1.width,mapMetrics.heightRel=mapMetrics.height/screen$1.height;let keys=[`xRel`,`yRel`,`widthRel`,`heightRel`];if(keys.some(key=>mapMetrics[key]<0||mapMetrics[key]>1)||keys.every(key=>mapMetrics[key]===0)){transformUpdateAttempt++,transformUpdateAttempt{val?updateDrawTransform():initialised.value&&sendTransformToLua(!1)}),watch([initialised,containerRef],()=>{updateDrawTransform(),containerRef.value&&!resizeObserver.value&&(resizeObserver.value=new ResizeObserver(()=>{updateDrawTransform()}),resizeObserver.value.observe(containerRef.value))},{immediate:!0}),onMounted(()=>{window.addEventListener(`scroll`,updateDrawTransform),window.addEventListener(`resize`,updateDrawTransform),events$3.on(`onCefVisibilityChanged`,visible=>{uiVisible.value=visible,nextTick(updateDrawTransform)}),initMinimap()}),onUnmounted(()=>{let wasInitialised=initialised.value;initialised.value=!1,window.removeEventListener(`scroll`,updateDrawTransform),window.removeEventListener(`resize`,updateDrawTransform),resizeObserver.value&&=(resizeObserver.value.disconnect(),null),wasInitialised&&sendTransformToLua(!1)}),useStreams([`minimap`],streams=>{streams.minimap&&(additionalInfo.distToTarget=streams.minimap.distToTarget,additionalInfo.locationName=streams.minimap.locationName,additionalInfo.policeMode=streams.minimap.policeMode)}),(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,{ref_key:`minimapContainerRef`,ref:minimapContainerRef,class:normalizeClass([`minimap-container-wrapper`,{[`police-`+additionalInfo.policeMode]:minimapMode.value===`rect`,round:minimapMode.value===`circle`}]),onClick:updateDrawTransform},[minimapMode.value===`rect`?(openBlock(),createElementBlock(Fragment,{key:0},[hasTopInfo.value?(openBlock(),createElementBlock(`div`,_hoisted_1$142,[additionalInfo.locationName?(openBlock(),createElementBlock(`span`,_hoisted_2$120,toDisplayString(additionalInfo.locationName),1)):createCommentVNode(``,!0)])):createCommentVNode(``,!0),createBaseVNode(`div`,{class:normalizeClass([`minimap-container`,{"round-bottom":!hasBottomInfo.value,"round-top":!hasTopInfo.value}]),ref_key:`containerRef`,ref:containerRef},null,2),hasBottomInfo.value?(openBlock(),createElementBlock(`div`,_hoisted_3$108,[additionalInfo.policeMode===`visibleToPolice`?(openBlock(),createBlock(unref(bngIcon_default),{key:0,type:`eyeSolidOpened`})):createCommentVNode(``,!0),additionalInfo.policeMode===`hiddenFromPolice`?(openBlock(),createBlock(unref(bngIcon_default),{key:1,type:`eyeSolidClosed`})):createCommentVNode(``,!0),additionalInfo.distToTarget?(openBlock(),createElementBlock(`span`,_hoisted_4$88,toDisplayString(additionalInfo.distToTarget),1)):createCommentVNode(``,!0),additionalInfo.distToTarget?(openBlock(),createBlock(unref(bngIcon_default),{key:3,class:``,type:`mapPoint`})):createCommentVNode(``,!0)])):createCommentVNode(``,!0)],64)):minimapMode.value===`circle`?(openBlock(),createElementBlock(Fragment,{key:1},[hasTopInfo.value?(openBlock(),createElementBlock(`div`,_hoisted_5$76,[additionalInfo.locationName?(openBlock(),createElementBlock(`span`,_hoisted_6$62,toDisplayString(additionalInfo.locationName),1)):createCommentVNode(``,!0)])):createCommentVNode(``,!0),createBaseVNode(`div`,{class:normalizeClass([`minimap-container round`,{[`police-`+additionalInfo.policeMode]:!0}]),ref_key:`containerRef`,ref:containerRef},null,2),hasBottomInfo.value?(openBlock(),createElementBlock(`div`,_hoisted_7$54,[additionalInfo.policeMode===`visibleToPolice`?(openBlock(),createBlock(unref(bngIcon_default),{key:0,type:`eyeSolidOpened`})):createCommentVNode(``,!0),additionalInfo.policeMode===`hiddenFromPolice`?(openBlock(),createBlock(unref(bngIcon_default),{key:1,type:`eyeSolidClosed`})):createCommentVNode(``,!0),additionalInfo.distToTarget?(openBlock(),createElementBlock(`span`,_hoisted_8$44,toDisplayString(additionalInfo.distToTarget),1)):createCommentVNode(``,!0),additionalInfo.distToTarget?(openBlock(),createBlock(unref(bngIcon_default),{key:3,class:``,type:`mapPoint`})):createCommentVNode(``,!0)])):createCommentVNode(``,!0)],64)):createCommentVNode(``,!0)],2))}},app_default$30=__plugin_vue_export_helper_default(_sfc_main$158,[[`__scopeId`,`data-v-4d3d3a71`]]),_hoisted_1$141={class:`hotlapping-app`},_hoisted_2$119={class:`hotlapping-header`},_hoisted_3$107={class:`header-flex`},_hoisted_4$87={class:`hotlapping-content`},_hoisted_5$75={key:0,class:`grid-header`},_hoisted_6$61={class:`grid-item current-item`},_hoisted_7$53={class:`grid-item current-item`},_hoisted_8$43={class:`grid-item current-item`},_sfc_main$157={__name:`app`,setup(__props){useEvents();let fastData=ref({}),slowData=ref({}),staticData=ref({}),placementData=ref({}),displayMode=ref(`combined`);onMounted(()=>{useStreams([`lapTimes_fast`,`lapTimes_slow`,`lapTimes_static`,`lapTimes_placement`],streams=>{streams.lapTimes_fast&&(fastData.value=streams.lapTimes_fast),streams.lapTimes_slow&&(slowData.value=streams.lapTimes_slow),streams.lapTimes_static&&(staticData.value=streams.lapTimes_static),streams.lapTimes_placement&&(placementData.value=streams.lapTimes_placement)})}),onUnmounted(()=>{});let getLapValue=()=>`${slowData.value?.currentLap||0}/${staticData.value?.totalLaps||0}`,getSegmentValue=()=>`${slowData.value?.currentSegment||0}/${staticData.value?.totalSegments||0}`,getTotalRaceTime=()=>fastData.value?.currentTimeFormatted||`00:00.000`,parseTimeString=timeStr=>{if(!timeStr)return{minutes:`00`,seconds:`00`,milliseconds:`000`};let parts=timeStr.split(`:`);if(parts.length===2){let minutes=parts[0].padStart(2,`0`),secondsParts=parts[1].split(`.`);return{minutes,seconds:secondsParts[0].padStart(2,`0`),milliseconds:secondsParts[1]?secondsParts[1].padEnd(3,`0`):`000`}}else{let secondsParts=parts[0].split(`.`);return{minutes:`00`,seconds:secondsParts[0].padStart(2,`0`),milliseconds:secondsParts[1]?secondsParts[1].padEnd(3,`0`):`000`}}},getTotalRaceTimeMinutes=()=>parseTimeString(getTotalRaceTime()).minutes,getTotalRaceTimeSeconds=()=>parseTimeString(getTotalRaceTime()).seconds,getTotalRaceTimeMilliseconds=()=>parseTimeString(getTotalRaceTime()).milliseconds,isRacing=()=>slowData.value?.status===`started`||slowData.value?.status===`paused`,getCurrentLapDiffClass=()=>{let flavor=fastData.value?.currentLapDiffToBestFlavor;return flavor===`better`?`diff-better`:flavor===`worse`?`diff-worse`:`diff-neutral`},getDiffClass=(flavor,value)=>!value||value===``||value===`N/A`?`diff-neutral`:flavor===`better`?`diff-better`:flavor===`worse`?`diff-worse`:`diff-neutral`,shouldShowToggleIcon=()=>(staticData.value?.totalLaps||0)>1,shouldShowSegmentsByDefault=()=>(staticData.value?.totalLaps||0)<=1,cycleDisplayMode=()=>{if(shouldShowToggleIcon()){let modes=[`combined`,`laps`,`segments`];displayMode.value=modes[(modes.indexOf(displayMode.value)+1)%modes.length]}},getTableHeaderLabel=()=>displayMode.value===`combined`?`Combined`:displayMode.value===`segments`?`Split`:`Lap`,shouldHideVsPrevBest=()=>(staticData.value?.totalLaps||0)<=1,getCurrentTimeFormatted=()=>displayMode.value===`segments`||shouldShowSegmentsByDefault()&&displayMode.value===`combined`?fastData.value?.currentSegmentTimeFormatted:fastData.value?.currentLapTimeFormatted,getCurrentItemNumber=()=>displayMode.value===`segments`||shouldShowSegmentsByDefault()&&displayMode.value===`combined`?`${slowData.value?.currentLap||1}-${slowData.value?.currentSegment||1}`:slowData.value?.currentLap||1,getCurrentDiff=()=>displayMode.value===`segments`||shouldShowSegmentsByDefault()&&displayMode.value===`combined`?fastData.value?.currentSegmentDiffToBestFormatted||``:fastData.value?.currentLapDiffToBestFormatted||``,getCurrentTotalTime=()=>fastData.value?.currentTimeFormatted||``,getFilteredCombinedItems=()=>{if(!slowData.value||!slowData.value.combinedTimes||!Array.isArray(slowData.value.combinedTimes))return[];let filtered=[];return displayMode.value===`combined`?filtered=[...slowData.value.combinedTimes]:displayMode.value===`laps`?filtered=slowData.value.combinedTimes.filter(item=>item.type===`lap`):displayMode.value===`segments`&&(filtered=slowData.value.combinedTimes.filter(item=>item.type===`segment`)),filtered.reverse()},getItemKey=item=>`${item.type}-${item.identifier}`,getItemNumber=item=>item.identifier;return(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$141,[createBaseVNode(`div`,_hoisted_2$119,[createBaseVNode(`div`,_hoisted_3$107,[staticData.value.totalLaps>1?(openBlock(),createBlock(bngSimpleDataDisplay_default,{key:0,class:`header-cell`,label:`Lap`,value:getLapValue()},null,8,[`value`])):createCommentVNode(``,!0),staticData.value.totalSegments>1?(openBlock(),createBlock(bngSimpleDataDisplay_default,{key:1,class:`header-cell`,label:`Split`,value:getSegmentValue()},null,8,[`value`])):createCommentVNode(``,!0),createVNode(bngSimpleDataDisplay_default,{class:`header-cell`,label:`Race Clock`,minutes:getTotalRaceTimeMinutes(),seconds:getTotalRaceTimeSeconds(),milliseconds:getTotalRaceTimeMilliseconds()},null,8,[`minutes`,`seconds`,`milliseconds`])])]),createBaseVNode(`div`,_hoisted_4$87,[createBaseVNode(`div`,{class:normalizeClass([`times-grid`,{"single-lap":shouldHideVsPrevBest()}])},[createBaseVNode(`div`,{class:normalizeClass([`grid-header clickable-header`,{"has-toggle":shouldShowToggleIcon()}]),onClick:_cache[0]||=$event=>shouldShowToggleIcon()?cycleDisplayMode():null},toDisplayString(getTableHeaderLabel()),3),_cache[1]||=createBaseVNode(`div`,{class:`grid-header`},`Duration`,-1),shouldHideVsPrevBest()?createCommentVNode(``,!0):(openBlock(),createElementBlock(`div`,_hoisted_5$75,`Vs prev`)),_cache[2]||=createBaseVNode(`div`,{class:`grid-header`},`Total`,-1),isRacing()&&getCurrentTimeFormatted()?(openBlock(),createElementBlock(Fragment,{key:1},[createBaseVNode(`div`,_hoisted_6$61,toDisplayString(getCurrentItemNumber()),1),createBaseVNode(`div`,_hoisted_7$53,toDisplayString(getCurrentTimeFormatted()),1),shouldHideVsPrevBest()?createCommentVNode(``,!0):(openBlock(),createElementBlock(`div`,{key:0,class:normalizeClass([`grid-item current-item`,getCurrentLapDiffClass()])},toDisplayString(getCurrentDiff()),3)),createBaseVNode(`div`,_hoisted_8$43,toDisplayString(getCurrentTotalTime()),1)],64)):createCommentVNode(``,!0),(openBlock(!0),createElementBlock(Fragment,null,renderList(getFilteredCombinedItems(),item=>(openBlock(),createElementBlock(Fragment,{key:getItemKey(item)},[createBaseVNode(`div`,{class:normalizeClass([`grid-item`,{"best-item left-indicator":item.flavor===`best`,"is-lap":item.type===`lap`}])},toDisplayString(getItemNumber(item)),3),createBaseVNode(`div`,{class:normalizeClass([`grid-item`,{"best-item":item.flavor===`best`}])},toDisplayString(item.durationFormatted),3),shouldHideVsPrevBest()?createCommentVNode(``,!0):(openBlock(),createElementBlock(`div`,{key:0,class:normalizeClass([`grid-item`,[{"best-item":item.flavor===`best`},getDiffClass(item.diffToPreviousFlavor,item.diffToPreviousFormatted)]])},toDisplayString(item.diffToPreviousFormatted||``),3)),createBaseVNode(`div`,{class:normalizeClass([`grid-item`,{"best-item":item.flavor===`best`}])},toDisplayString(item.endTimeFormatted||``),3)],64))),128))],2)])]))}},app_default$31=__plugin_vue_export_helper_default(_sfc_main$157,[[`__scopeId`,`data-v-a9e5d83a`]]),_hoisted_1$140={class:`laptimes-section`},_hoisted_2$118={class:`collapse-icon`},_hoisted_3$106={class:`collapsible-content`},_hoisted_4$86={class:`laptimes-data-grid`},_hoisted_5$74={key:0,class:`data-item`},_hoisted_6$60={class:`value`},_hoisted_7$52={key:1,class:`data-item`},_hoisted_8$42={class:`data-item`},_hoisted_9$39={class:`value`},_hoisted_10$32={class:`data-item`},_hoisted_11$29={class:`value`},_hoisted_12$23={class:`data-item`},_hoisted_13$20={class:`value`},_hoisted_14$20={class:`data-item`},_hoisted_15$19={class:`value`},_hoisted_16$19={key:0,class:`laptimes-data-grid`,style:{"margin-top":`1rem`}},_hoisted_17$15={key:0,class:`data-item`},_hoisted_18$13={key:1,class:`data-item`},_hoisted_19$10={key:1,class:`laptimes-data-grid`,style:{"margin-top":`1rem`}},_hoisted_20$9={key:0,class:`data-item`},_hoisted_21$9={key:1,class:`data-item`},_sfc_main$156={__name:`BasicInfo`,props:{fastData:{type:Object,required:!0},staticData:{type:Object,required:!0},slowData:{type:Object,required:!0}},setup(__props){let isCollapsed=ref(!1),toggleCollapse=()=>{isCollapsed.value=!isCollapsed.value};return(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$140,[createBaseVNode(`h3`,{onClick:toggleCollapse,class:`collapsible-header`},[createBaseVNode(`span`,_hoisted_2$118,toDisplayString(isCollapsed.value?`▶`:`▼`),1),_cache[0]||=createTextVNode(` Race Info `,-1)]),withDirectives(createBaseVNode(`div`,_hoisted_3$106,[createBaseVNode(`div`,_hoisted_4$86,[__props.slowData.status===`started`||__props.slowData.status===`paused`?(openBlock(),createElementBlock(`div`,_hoisted_5$74,[_cache[1]||=createBaseVNode(`span`,{class:`label`},`Current Time:`,-1),createBaseVNode(`span`,_hoisted_6$60,toDisplayString(__props.fastData.currentTimeFormatted||`00:00.000`),1)])):(openBlock(),createElementBlock(`div`,_hoisted_7$52,[_cache[2]||=createBaseVNode(`span`,{class:`label`},`Status:`,-1),createBaseVNode(`span`,{class:normalizeClass([`value`,{active:__props.slowData.status===`started`,paused:__props.slowData.status===`paused`}])},toDisplayString(__props.slowData.status?.toUpperCase()||`STOPPED`),3)])),createBaseVNode(`div`,_hoisted_8$42,[_cache[3]||=createBaseVNode(`span`,{class:`label`},`Lap:`,-1),createBaseVNode(`span`,_hoisted_9$39,toDisplayString(__props.slowData.currentLap||0)+`/`+toDisplayString(__props.staticData.totalLaps||0),1)]),createBaseVNode(`div`,_hoisted_10$32,[_cache[4]||=createBaseVNode(`span`,{class:`label`},`Segment:`,-1),createBaseVNode(`span`,_hoisted_11$29,toDisplayString(__props.slowData.currentSegment||0)+`/`+toDisplayString(__props.staticData.totalSegments||0),1)]),createBaseVNode(`div`,_hoisted_12$23,[_cache[5]||=createBaseVNode(`span`,{class:`label`},`Current Lap Time:`,-1),createBaseVNode(`span`,_hoisted_13$20,toDisplayString(__props.fastData.currentLapTimeFormatted||`00:00.000`),1)]),createBaseVNode(`div`,_hoisted_14$20,[_cache[6]||=createBaseVNode(`span`,{class:`label`},`Current Segment Time:`,-1),createBaseVNode(`span`,_hoisted_15$19,toDisplayString(__props.fastData.currentSegmentTimeFormatted||`00:00.000`),1)])]),__props.fastData.currentLapDiffToBestFormatted||__props.fastData.currentLapDiffToPreviousFormatted?(openBlock(),createElementBlock(`div`,_hoisted_16$19,[__props.fastData.currentLapDiffToBestFormatted?(openBlock(),createElementBlock(`div`,_hoisted_17$15,[_cache[7]||=createBaseVNode(`span`,{class:`label`},`Lap Diff to Best:`,-1),createBaseVNode(`span`,{class:normalizeClass([`value`,`diff-`+(__props.fastData.currentLapDiffToBestFlavor||`default`)])},toDisplayString(__props.fastData.currentLapDiffToBestFormatted),3)])):createCommentVNode(``,!0),__props.fastData.currentLapDiffToPreviousFormatted?(openBlock(),createElementBlock(`div`,_hoisted_18$13,[_cache[8]||=createBaseVNode(`span`,{class:`label`},`Lap Diff to Previous:`,-1),createBaseVNode(`span`,{class:normalizeClass([`value`,`diff-`+(__props.fastData.currentLapDiffToPreviousFlavor||`default`)])},toDisplayString(__props.fastData.currentLapDiffToPreviousFormatted),3)])):createCommentVNode(``,!0)])):createCommentVNode(``,!0),__props.fastData.currentSegmentDiffToBestFormatted||__props.fastData.currentSegmentDiffToPreviousFormatted?(openBlock(),createElementBlock(`div`,_hoisted_19$10,[__props.fastData.currentSegmentDiffToBestFormatted?(openBlock(),createElementBlock(`div`,_hoisted_20$9,[_cache[9]||=createBaseVNode(`span`,{class:`label`},`Segment Diff to Best:`,-1),createBaseVNode(`span`,{class:normalizeClass([`value`,`diff-`+(__props.fastData.currentSegmentDiffToBestFlavor||`default`)])},toDisplayString(__props.fastData.currentSegmentDiffToBestFormatted),3)])):createCommentVNode(``,!0),__props.fastData.currentSegmentDiffToPreviousFormatted?(openBlock(),createElementBlock(`div`,_hoisted_21$9,[_cache[10]||=createBaseVNode(`span`,{class:`label`},`Segment Diff to Previous:`,-1),createBaseVNode(`span`,{class:normalizeClass([`value`,`diff-`+(__props.fastData.currentSegmentDiffToPreviousFlavor||`default`)])},toDisplayString(__props.fastData.currentSegmentDiffToPreviousFormatted),3)])):createCommentVNode(``,!0)])):createCommentVNode(``,!0)],512),[[vShow,!isCollapsed.value]])]))}},BasicInfo_default=__plugin_vue_export_helper_default(_sfc_main$156,[[`__scopeId`,`data-v-4329fa2c`]]),_hoisted_1$139={class:`laptimes-section`},_hoisted_2$117={class:`collapse-icon`},_hoisted_3$105={class:`collapsible-content`},_hoisted_4$85={class:`laptimes-data-grid`,style:{"margin-bottom":`1rem`}},_hoisted_5$73={class:`data-item`},_hoisted_6$59={class:`value`},_hoisted_7$51={key:0,class:`laptimes-data-grid`},_hoisted_8$41={class:`label`},_hoisted_9$38={class:`value`},_sfc_main$155={__name:`BestTimes`,props:{slowData:{type:Object,required:!0}},setup(__props){let props=__props,isCollapsed=ref(!1),toggleCollapse=()=>{isCollapsed.value=!isCollapsed.value},getBestLapDisplay=()=>{let bestTime=props.slowData.bestLapTimeFormatted||`N/A`,bestIndex=props.slowData.bestLapIndex===-1?null:props.slowData.bestLapIndex;return bestTime===`N/A`||bestIndex===null?`N/A`:`${bestTime} in Lap ${bestIndex}`},getBestSegmentDisplayFromData=segmentData=>{if(!segmentData||typeof segmentData!=`object`)return`N/A`;let time=segmentData.time||`N/A`,lap=segmentData.lap;return lap?`${time} in Lap ${lap}`:time};return(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$139,[createBaseVNode(`h3`,{onClick:toggleCollapse,class:`collapsible-header`},[createBaseVNode(`span`,_hoisted_2$117,toDisplayString(isCollapsed.value?`▶`:`▼`),1),_cache[0]||=createTextVNode(` Best Times `,-1)]),withDirectives(createBaseVNode(`div`,_hoisted_3$105,[createBaseVNode(`div`,_hoisted_4$85,[createBaseVNode(`div`,_hoisted_5$73,[_cache[1]||=createBaseVNode(`span`,{class:`label`},`Best Lap:`,-1),createBaseVNode(`span`,_hoisted_6$59,toDisplayString(getBestLapDisplay()),1)])]),__props.slowData.bestSegmentTimesFormatted&&Object.keys(__props.slowData.bestSegmentTimesFormatted).length>0?(openBlock(),createElementBlock(`div`,_hoisted_7$51,[(openBlock(!0),createElementBlock(Fragment,null,renderList(__props.slowData.bestSegmentTimesFormatted,(segmentData,segment)=>(openBlock(),createElementBlock(`div`,{class:`data-item`,key:segment},[createBaseVNode(`span`,_hoisted_8$41,`Best Segment `+toDisplayString(parseInt(segment)+1)+`:`,1),createBaseVNode(`span`,_hoisted_9$38,toDisplayString(getBestSegmentDisplayFromData(segmentData)),1)]))),128))])):createCommentVNode(``,!0)],512),[[vShow,!isCollapsed.value]])]))}},BestTimes_default=__plugin_vue_export_helper_default(_sfc_main$155,[[`__scopeId`,`data-v-3cd1750d`]]),_hoisted_1$138={class:`laptimes-section`},_hoisted_2$116={class:`collapse-icon`},_hoisted_3$104={class:`collapsible-content`},_hoisted_4$84={class:`table-header`},_hoisted_5$72={key:0},_hoisted_6$58={key:1},_hoisted_7$50={key:0,class:`table-row current-lap-row`},_sfc_main$154={__name:`LapTimes`,props:{fastData:{type:Object,required:!0},slowData:{type:Object,required:!0},staticData:{type:Object,required:!0}},setup(__props){let isCollapsed=ref(!1),toggleCollapse=()=>{isCollapsed.value=!isCollapsed.value},getDiffFlavorClass=flavor=>flavor?{"diff-better":flavor===`better`,"diff-worse":flavor===`worse`,"diff-same":flavor===`same`}:``;return(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$138,[createBaseVNode(`h3`,{onClick:toggleCollapse,class:`collapsible-header`},[createBaseVNode(`span`,_hoisted_2$116,toDisplayString(isCollapsed.value?`▶`:`▼`),1),_cache[0]||=createTextVNode(` Lap Times `,-1)]),withDirectives(createBaseVNode(`div`,_hoisted_3$104,[__props.slowData.lapTimes&&__props.slowData.lapTimes.length>0||__props.slowData.status===`started`||__props.slowData.status===`paused`?(openBlock(),createElementBlock(`div`,{key:0,class:normalizeClass([`laptimes-table`,{"single-lap":__props.staticData.totalLaps<=1}])},[createBaseVNode(`div`,_hoisted_4$84,[_cache[1]||=createBaseVNode(`span`,null,`Lap`,-1),_cache[2]||=createBaseVNode(`span`,null,`Time`,-1),_cache[3]||=createBaseVNode(`span`,null,`Duration`,-1),__props.staticData.totalLaps>1?(openBlock(),createElementBlock(`span`,_hoisted_5$72,`Diff to Best`)):createCommentVNode(``,!0),__props.staticData.totalLaps>1?(openBlock(),createElementBlock(`span`,_hoisted_6$58,`Diff to Prev`)):createCommentVNode(``,!0)]),(openBlock(!0),createElementBlock(Fragment,null,renderList(__props.slowData.lapTimes,lap=>(openBlock(),createElementBlock(`div`,{key:lap.lap,class:normalizeClass([`table-row`,{"best-lap":lap.lapFlavor===`best`,"current-lap":lap.isCurrent}])},[createBaseVNode(`span`,null,toDisplayString(lap.lap),1),createBaseVNode(`span`,null,toDisplayString(lap.timeFormatted||lap.endTimeFormatted||`N/A`),1),createBaseVNode(`span`,null,toDisplayString(lap.durationFormatted),1),__props.staticData.totalLaps>1?(openBlock(),createElementBlock(`span`,{key:0,class:normalizeClass(getDiffFlavorClass(lap.diffToBestFlavor))},toDisplayString(lap.diffToBestFormatted||`N/A`),3)):createCommentVNode(``,!0),__props.staticData.totalLaps>1?(openBlock(),createElementBlock(`span`,{key:1,class:normalizeClass(getDiffFlavorClass(lap.diffToPreviousFlavor))},toDisplayString(lap.diffToPreviousFormatted||`N/A`),3)):createCommentVNode(``,!0)],2))),128)),(__props.slowData.status===`started`||__props.slowData.status===`paused`)&&__props.fastData.currentLapTimeFormatted?(openBlock(),createElementBlock(`div`,_hoisted_7$50,[createBaseVNode(`span`,null,toDisplayString(__props.slowData.currentLap||1),1),createBaseVNode(`span`,null,toDisplayString(__props.fastData.currentTimeFormatted),1),createBaseVNode(`span`,null,toDisplayString(__props.fastData.currentLapTimeFormatted),1),__props.staticData.totalLaps>1?(openBlock(),createElementBlock(`span`,{key:0,class:normalizeClass(getDiffFlavorClass(__props.fastData.currentLapDiffToBestFlavor))},toDisplayString(__props.fastData.currentLapDiffToBestFormatted||`N/A`),3)):createCommentVNode(``,!0),__props.staticData.totalLaps>1?(openBlock(),createElementBlock(`span`,{key:1,class:normalizeClass(getDiffFlavorClass(__props.fastData.currentLapDiffToPreviousFlavor))},toDisplayString(__props.fastData.currentLapDiffToPreviousFormatted||`N/A`),3)):createCommentVNode(``,!0)])):createCommentVNode(``,!0)],2)):createCommentVNode(``,!0)],512),[[vShow,!isCollapsed.value]])]))}},LapTimes_default=__plugin_vue_export_helper_default(_sfc_main$154,[[`__scopeId`,`data-v-ed892fc5`]]),_hoisted_1$137={class:`laptimes-section`},_hoisted_2$115={class:`collapse-icon`},_hoisted_3$103={class:`collapsible-content`},_hoisted_4$83={class:`table-header`},_hoisted_5$71={key:0},_hoisted_6$57={key:1},_hoisted_7$49={key:0,class:`table-row current-segment-row`},_sfc_main$153={__name:`SegmentTimes`,props:{fastData:{type:Object,required:!0},slowData:{type:Object,required:!0},staticData:{type:Object,required:!0}},setup(__props){let isCollapsed=ref(!1),toggleCollapse=()=>{isCollapsed.value=!isCollapsed.value},getDiffFlavorClass=flavor=>flavor?{"diff-better":flavor===`better`,"diff-worse":flavor===`worse`,"diff-same":flavor===`same`}:``;return(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$137,[createBaseVNode(`h3`,{onClick:toggleCollapse,class:`collapsible-header`},[createBaseVNode(`span`,_hoisted_2$115,toDisplayString(isCollapsed.value?`▶`:`▼`),1),_cache[0]||=createTextVNode(` Segment Times `,-1)]),withDirectives(createBaseVNode(`div`,_hoisted_3$103,[__props.slowData.segmentTimes&&__props.slowData.segmentTimes.length>0||__props.slowData.status===`started`||__props.slowData.status===`paused`?(openBlock(),createElementBlock(`div`,{key:0,class:normalizeClass([`laptimes-table`,{"single-lap":__props.staticData.totalLaps<=1}])},[createBaseVNode(`div`,_hoisted_4$83,[_cache[1]||=createBaseVNode(`span`,null,`Segment`,-1),_cache[2]||=createBaseVNode(`span`,null,`Time`,-1),_cache[3]||=createBaseVNode(`span`,null,`Duration`,-1),__props.staticData.totalLaps>1?(openBlock(),createElementBlock(`span`,_hoisted_5$71,`Diff to Best`)):createCommentVNode(``,!0),__props.staticData.totalLaps>1?(openBlock(),createElementBlock(`span`,_hoisted_6$57,`Diff to Prev`)):createCommentVNode(``,!0)]),(openBlock(!0),createElementBlock(Fragment,null,renderList(__props.slowData.segmentTimes,segment=>(openBlock(),createElementBlock(`div`,{key:segment.segment,class:normalizeClass([`table-row`,{"best-segment":segment.segmentFlavor===`best`,"current-segment":segment.isCurrent}])},[createBaseVNode(`span`,null,toDisplayString(segment.segment),1),createBaseVNode(`span`,null,toDisplayString(segment.timeFormatted||segment.endTimeFormatted||`N/A`),1),createBaseVNode(`span`,null,toDisplayString(segment.durationFormatted),1),__props.staticData.totalLaps>1?(openBlock(),createElementBlock(`span`,{key:0,class:normalizeClass(getDiffFlavorClass(segment.diffToBestFlavor))},toDisplayString(segment.diffToBestFormatted||`N/A`),3)):createCommentVNode(``,!0),__props.staticData.totalLaps>1?(openBlock(),createElementBlock(`span`,{key:1,class:normalizeClass(getDiffFlavorClass(segment.diffToPreviousFlavor))},toDisplayString(segment.diffToPreviousFormatted||`N/A`),3)):createCommentVNode(``,!0)],2))),128)),(__props.slowData.status===`started`||__props.slowData.status===`paused`)&&__props.fastData.currentSegmentTimeFormatted?(openBlock(),createElementBlock(`div`,_hoisted_7$49,[createBaseVNode(`span`,null,toDisplayString(__props.slowData.currentLap||1)+`-`+toDisplayString(__props.slowData.currentSegment||1),1),createBaseVNode(`span`,null,toDisplayString(__props.fastData.currentTimeFormatted),1),createBaseVNode(`span`,null,toDisplayString(__props.fastData.currentSegmentTimeFormatted),1),__props.staticData.totalLaps>1?(openBlock(),createElementBlock(`span`,{key:0,class:normalizeClass(getDiffFlavorClass(__props.fastData.currentSegmentDiffToBestFlavor))},toDisplayString(__props.fastData.currentSegmentDiffToBestFormatted||`N/A`),3)):createCommentVNode(``,!0),__props.staticData.totalLaps>1?(openBlock(),createElementBlock(`span`,{key:1,class:normalizeClass(getDiffFlavorClass(__props.fastData.currentSegmentDiffToPreviousFlavor))},toDisplayString(__props.fastData.currentSegmentDiffToPreviousFormatted||`N/A`),3)):createCommentVNode(``,!0)])):createCommentVNode(``,!0)],2)):createCommentVNode(``,!0)],512),[[vShow,!isCollapsed.value]])]))}},SegmentTimes_default=__plugin_vue_export_helper_default(_sfc_main$153,[[`__scopeId`,`data-v-3801fbed`]]),_hoisted_1$136={key:0,class:`laptimes-section`},_hoisted_2$114={class:`collapse-icon`},_hoisted_3$102={class:`collapsible-content`},_hoisted_4$82={class:`laptimes-data-grid`,style:{"margin-bottom":`1rem`}},_hoisted_5$70={class:`data-item`},_hoisted_6$56={class:`value`},_hoisted_7$48={class:`data-item`},_hoisted_8$40={class:`value`},_hoisted_9$37={class:`laptimes-table`},_hoisted_10$31={class:`table-header`},_hoisted_11$28={key:0},_hoisted_12$22={key:1},_hoisted_13$19={key:0},_hoisted_14$19={key:1},_sfc_main$152={__name:`Placement`,props:{fastData:{type:Object,required:!0},slowData:{type:Object,required:!0},staticData:{type:Object,required:!0},placementData:{type:Object,required:!0}},setup(__props){let props=__props,isCollapsed=ref(!1),toggleCollapse=()=>{isCollapsed.value=!isCollapsed.value},playerVehicleId=computed(()=>{if(props.placementData.vehicleStates){let vehicleIds=Object.keys(props.placementData.vehicleStates);return vehicleIds.length>0?parseInt(vehicleIds[0]):null}return null}),playerPlacement=computed(()=>!playerVehicleId.value||!props.placementData.placements?null:props.placementData.placements[playerVehicleId.value]),totalRacers=computed(()=>props.placementData.placements?Object.keys(props.placementData.placements).length:0),shouldShowLapColumn=computed(()=>{if(!props.staticData.pathConfig)return!1;let pathConfig=props.staticData.pathConfig;return pathConfig.isClosed&&pathConfig.lapCount>1}),shouldShowSegmentColumn=computed(()=>{if(!props.staticData.pathConfig)return!1;let pathConfig=props.staticData.pathConfig;return!pathConfig.isClosed||pathConfig.isClosed&&pathConfig.lapCount>1}),sortedRacers=computed(()=>{if(!props.placementData.placements||!props.placementData.vehicleStates)return[];let racers=[];return Object.entries(props.placementData.placements).forEach(([vehicleId,placement])=>{let vehicleIdNum=parseInt(vehicleId),vehicleState=props.placementData.vehicleStates[vehicleId],timeDiffData=props.placementData.timeDifferencesToFirst?.[vehicleId],timeDiff=timeDiffData?.timeDifference||0;racers.push({vehicleId:vehicleIdNum,placement,currentLap:vehicleState?.currentLap||0,currentSegment:vehicleState?.currentSegment||0,isPlayer:vehicleIdNum===playerVehicleId.value,timeDiff,timeDiffFormatted:timeDiffData?.timeDifferenceFormatted||`0.000`})}),racers.sort((a$1,b)=>a$1.placement-b.placement)}),getTimeDiffClass=timeDiff=>timeDiff==null?``:{"diff-red":timeDiff>0,"diff-green":timeDiff<0,"diff-neutral":timeDiff===0};return(_ctx,_cache)=>__props.placementData.placements&&Object.keys(__props.placementData.placements).length>1?(openBlock(),createElementBlock(`div`,_hoisted_1$136,[createBaseVNode(`h3`,{onClick:toggleCollapse,class:`collapsible-header`},[createBaseVNode(`span`,_hoisted_2$114,toDisplayString(isCollapsed.value?`▶`:`▼`),1),_cache[0]||=createTextVNode(` Race Positions `,-1)]),withDirectives(createBaseVNode(`div`,_hoisted_3$102,[createBaseVNode(`div`,_hoisted_4$82,[createBaseVNode(`div`,_hoisted_5$70,[_cache[1]||=createBaseVNode(`span`,{class:`label`},`Your Position:`,-1),createBaseVNode(`span`,_hoisted_6$56,toDisplayString(playerPlacement.value||`N/A`),1)]),createBaseVNode(`div`,_hoisted_7$48,[_cache[2]||=createBaseVNode(`span`,{class:`label`},`Total Racers:`,-1),createBaseVNode(`span`,_hoisted_8$40,toDisplayString(totalRacers.value),1)])]),createBaseVNode(`div`,_hoisted_9$37,[createBaseVNode(`div`,_hoisted_10$31,[_cache[3]||=createBaseVNode(`span`,null,`Pos`,-1),_cache[4]||=createBaseVNode(`span`,null,`Vehicle`,-1),shouldShowLapColumn.value?(openBlock(),createElementBlock(`span`,_hoisted_11$28,`Lap`)):createCommentVNode(``,!0),shouldShowSegmentColumn.value?(openBlock(),createElementBlock(`span`,_hoisted_12$22,`Segment`)):createCommentVNode(``,!0),_cache[5]||=createBaseVNode(`span`,null,`Time Diff`,-1)]),(openBlock(!0),createElementBlock(Fragment,null,renderList(sortedRacers.value,(racer,index)=>(openBlock(),createElementBlock(`div`,{key:racer.vehicleId,class:normalizeClass([`table-row`,{"player-row":racer.isPlayer,"leader-row":index===0}])},[createBaseVNode(`span`,null,toDisplayString(racer.placement),1),createBaseVNode(`span`,null,toDisplayString(racer.vehicleId===playerVehicleId.value?`You`:`Vehicle ${racer.vehicleId}`),1),shouldShowLapColumn.value?(openBlock(),createElementBlock(`span`,_hoisted_13$19,toDisplayString(racer.currentLap||0),1)):createCommentVNode(``,!0),shouldShowSegmentColumn.value?(openBlock(),createElementBlock(`span`,_hoisted_14$19,toDisplayString(racer.currentSegment||0),1)):createCommentVNode(``,!0),createBaseVNode(`span`,{class:normalizeClass(getTimeDiffClass(racer.timeDiff))},toDisplayString(racer.timeDiffFormatted),3)],2))),128))])],512),[[vShow,!isCollapsed.value]])])):createCommentVNode(``,!0)}},Placement_default=__plugin_vue_export_helper_default(_sfc_main$152,[[`__scopeId`,`data-v-c2373a09`]]),_hoisted_1$135={class:`laptimes-section`},_hoisted_2$113={class:`collapse-icon`},_hoisted_3$101={class:`collapsible-content`},_hoisted_4$81={class:`raw-data-container`},_hoisted_5$69={key:0,class:`data-stream`},_hoisted_6$55={class:`data-content`},_hoisted_7$47={key:1,class:`data-stream`},_hoisted_8$39={class:`data-content`},_hoisted_9$36={key:2,class:`data-stream`},_hoisted_10$30={class:`data-content`},_hoisted_11$27={key:3,class:`data-stream`},_hoisted_12$21={class:`data-content`},_sfc_main$151={__name:`RawData`,props:{fastData:{type:Object,required:!0},slowData:{type:Object,required:!0},staticData:{type:Object,required:!0},placementData:{type:Object,required:!0}},setup(__props){let isCollapsed=ref(!0),toggleCollapse=()=>{isCollapsed.value=!isCollapsed.value};return(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$135,[createBaseVNode(`h3`,{onClick:toggleCollapse,class:`collapsible-header`},[createBaseVNode(`span`,_hoisted_2$113,toDisplayString(isCollapsed.value?`▶`:`▼`),1),_cache[0]||=createTextVNode(` Raw Stream Data `,-1)]),withDirectives(createBaseVNode(`div`,_hoisted_3$101,[createBaseVNode(`div`,_hoisted_4$81,[__props.fastData?(openBlock(),createElementBlock(`div`,_hoisted_5$69,[createBaseVNode(`h4`,null,`Fast Stream Data `+toDisplayString(__props.fastData.timestamp),1),createBaseVNode(`pre`,_hoisted_6$55,toDisplayString(JSON.stringify(__props.fastData,null,1)),1)])):createCommentVNode(``,!0),__props.slowData?(openBlock(),createElementBlock(`div`,_hoisted_7$47,[createBaseVNode(`h4`,null,`Slow Stream Data `+toDisplayString(__props.slowData.timestamp),1),createBaseVNode(`pre`,_hoisted_8$39,toDisplayString(JSON.stringify(__props.slowData,null,1)),1)])):createCommentVNode(``,!0),__props.staticData?(openBlock(),createElementBlock(`div`,_hoisted_9$36,[createBaseVNode(`h4`,null,`Static Stream Data `+toDisplayString(__props.staticData.timestamp),1),createBaseVNode(`pre`,_hoisted_10$30,toDisplayString(JSON.stringify(__props.staticData,null,1)),1)])):createCommentVNode(``,!0),__props.placementData?(openBlock(),createElementBlock(`div`,_hoisted_11$27,[createBaseVNode(`h4`,null,`Placement Stream Data `+toDisplayString(__props.placementData.timestamp),1),createBaseVNode(`pre`,_hoisted_12$21,toDisplayString(JSON.stringify(__props.placementData,null,1)),1)])):createCommentVNode(``,!0)])],512),[[vShow,!isCollapsed.value]])]))}},RawData_default=__plugin_vue_export_helper_default(_sfc_main$151,[[`__scopeId`,`data-v-7bc3ab60`]]),_hoisted_1$134={class:`laptimes-app`,style:{"overflow-y":`scroll`}},_sfc_main$150={__name:`appDebug`,setup(__props){useEvents();let fastData=ref({}),slowData=ref({}),staticData=ref({}),placementData=ref({});return onMounted(()=>{useStreams([`lapTimes_fast`,`lapTimes_slow`,`lapTimes_static`,`lapTimes_placement`],streams=>{streams.lapTimes_fast&&(fastData.value=streams.lapTimes_fast),streams.lapTimes_slow&&(slowData.value=streams.lapTimes_slow),streams.lapTimes_static&&(staticData.value=streams.lapTimes_static),streams.lapTimes_placement&&(placementData.value=streams.lapTimes_placement)})}),onUnmounted(()=>{}),(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$134,[_cache[0]||=createBaseVNode(`div`,{class:`laptimes-header`},[createBaseVNode(`h2`,null,`Lap Times Debug`)],-1),createVNode(BasicInfo_default,{fastData:fastData.value,slowData:slowData.value,staticData:staticData.value},null,8,[`fastData`,`slowData`,`staticData`]),createVNode(BestTimes_default,{slowData:slowData.value},null,8,[`slowData`]),createVNode(LapTimes_default,{fastData:fastData.value,slowData:slowData.value,staticData:staticData.value},null,8,[`fastData`,`slowData`,`staticData`]),createVNode(SegmentTimes_default,{fastData:fastData.value,slowData:slowData.value,staticData:staticData.value},null,8,[`fastData`,`slowData`,`staticData`]),createVNode(Placement_default,{fastData:fastData.value,slowData:slowData.value,staticData:staticData.value,placementData:placementData.value},null,8,[`fastData`,`slowData`,`staticData`,`placementData`]),createVNode(RawData_default,{fastData:fastData.value,slowData:slowData.value,staticData:staticData.value,placementData:placementData.value},null,8,[`fastData`,`slowData`,`staticData`,`placementData`])]))}},appDebug_default$1=__plugin_vue_export_helper_default(_sfc_main$150,[[`__scopeId`,`data-v-49102eaf`]]),_hoisted_1$133={class:`messages-app`},_hoisted_2$112={key:0,class:`icon-cell`},_hoisted_3$100={class:`text-cell`},_hoisted_4$80={key:0},timerIntervalMs=300,_sfc_main$149={__name:`app`,props:{maxMessages:{type:Number,default:void 0},dense:{type:Boolean,default:!1},wrap:{type:Boolean,default:!0},showIcons:{type:Boolean,default:!0}},setup(__props){let props=__props,events$3=useEvents(),messagesByCategory=reactive({}),bypassTtl=ref(!1),getIconProps=item=>{let icon=resolvedType(item.icon);if(icon)return{type:icon};let externalImage=resolvedExternalImage(item.icon);return externalImage?{externalImage}:{type:`info`}},timerId,isAssetPath=icon=>typeof icon==`string`&&icon.startsWith(`/`),resolvedType=icon=>typeof icon==`string`&&!isAssetPath(icon)?icon:void 0,resolvedExternalImage=icon=>typeof icon==`string`&&isAssetPath(icon)?icon:void 0,messagesList=computed(()=>{let list=Object.values(messagesByCategory);return typeof props.maxMessages==`number`&&props.maxMessages>0?list.slice(0,props.maxMessages):list});function resolveTranslation(val){return val==null?``:typeof val==`string`?$translate.instant(val):Array.isArray(val)?$translate.multiContextTranslate(val):typeof val==`object`?$translate.contextTranslate(val):String(val)}function htmlToPlainText(html){if(typeof html!=`string`)return String(html??``);let h$1=html.replace(//gi,` `),el=document.createElement(`div`);el.innerHTML=h$1;let text=el.textContent??el.innerText??h$1;return text=text.replace(/<[^>]*>/g,``),text}function sanitizeTextSegment(text){return text?htmlToPlainText(parse$1?parse$1(text):text):``}function getParts(item){let raw=resolveTranslation(item.text);if(typeof raw!=`string`)return[{t:`text`,v:sanitizeTextSegment(String(raw))}];let parts=[],rgx=/\[action=([^\]]+)\]/gi,lastIndex=0,match;for(;(match=rgx.exec(raw))!==null;){let head=raw.slice(lastIndex,match.index);head&&parts.push({t:`text`,v:sanitizeTextSegment(head)});let actionName=match[1].trim();parts.push({t:`binding`,action:actionName}),lastIndex=match.index+match[0].length}let tail=raw.slice(lastIndex);return tail&&parts.push({t:`text`,v:sanitizeTextSegment(tail)}),parts.length?parts:[{t:`text`,v:sanitizeTextSegment(raw)}]}function normalizePayload(args){let category=args?.category??`default`,clear=!!args?.clear,text=args&&`text`in args?args.text:args&&`msg`in args?args.msg:``,icon=typeof args?.icon==`string`?args.icon:void 0,ttlMs=typeof args?.ttlMs==`number`?args.ttlMs:typeof args?.ttl==`number`?args.ttl*1e3:void 0;return ttlMs??=5e3,{category,clear,text,icon,ttlMs}}let CATEGORY_ICONS=[{match:`vehicle.absBehavior`,icon:`ABSIndicator`},{match:`vehicle.brakingdistance`,icon:`carsFollow`},{prefix:`vehicle.compressionBrake.`,icon:`engine`},{prefix:`vehicle.damage.exhaust`,icon:`exhaustMuffler`},{prefix:`vehicle.damage.deflated.`,icon:`tireDeflated`},{prefix:`vehicle.beamstate.tireDeflated`,icon:`tireDeflated`},{match:`vehicle.damage.mildOverrev`,icon:`powerGauge05`},{match:`vehicle.damage.catastrophicOverrev`,icon:`powerGauge05`},{match:`vehicle.damage.catastrophicOverTorque`,icon:`cogDamaged`},{match:`vehicle.damage.flood`,icon:`water`},{match:`vehicle.engine.isStalling`,icon:`powerGauge01`},{match:`vehicle.ignition.ignitionLevel`,icon:`keys1`},{match:`vehicle.lightbar.mode`,icon:`wigwags`},{match:`vehicle.linelock.status`,icon:`wheelDisc`},{match:`vehicle.postCrashBrake.impact`,icon:`hazardLights`},{prefix:`vehicle.powertrain.diffmode.`,icon:`drivetrainGeneric`},{match:`vehicle.powertrain.nitrousOxideInjection`,icon:`N2OHoriz`},{match:`vehicle.shiftLogic.cannotShift`,icon:`cogsDamaged`},{match:`vehicle.shiftermode`,icon:`transmissionM`},{match:`vehicle.transbrake.status`,icon:`cogs`},{match:`vehicle.twoStep.status`,icon:`signal04a`},{match:`vehicle.tirePressureControl.inflateDeflate`,icon:`tirePressureGaugeOutlined03`},{prefix:`vehicle.wheels.tirePunctured.`,icon:`tireAirPuff`},{prefix:`vehicle.damage.device.`,icon:`cogDamaged`},{match:`vehicle.driveModes`,icon:`ESC`},{prefix:`vehicle.driveModes.`,icon:`ESC`},{match:`vehicle.engine.oilOverheating.true`,icon:`coolantTemp`},{match:`vehicle.engine.blockMelted.true`,icon:`coolantTemp`},{match:`vehicle.engine.headGasketDamaged.true`,icon:`coolantTemp`},{match:`vehicle.engine.coolantOverheating.true`,icon:`coolantTemp`},{match:`vehicle.engine.radiatorLeak.true`,icon:`coolantTemp`},{prefix:`vehicle.engine.`,icon:`engine`},{prefix:`vehicle.recovery.`,icon:`tow`},{match:`rally`,icon:`rallyHelmet`},{match:`fill`,icon:`import`},{match:`align`,icon:`flag`},{match:`delivery`,icon:`boxTruckFast`},{match:`refueling`,icon:`fuelPumpFilling`},{prefix:`refueling-`,icon:`fuelPumpFilling`},{prefix:`ui.camera.`,icon:`movieCamera`},{match:`input`,icon:`gamepad`},{prefix:`ui.apps.damage_app_vehicle_simple.component.`,icon:`cogsDamaged`},{match:`AI debug`,icon:`AIMicrochip`},{match:`debug`,icon:`code`},{match:`hydros`,icon:`steeringWheelCommon`},{match:`GLTFexport`,icon:`loadMesh`},{match:`bigmap.info.reachedTarget`,icon:`raceFlag`}];function deriveIconForCategory(category){if(!category)return`info`;console.debug(`[messages] deriveIconForCategory`,category);for(let{match,prefix:prefix$1,icon}of CATEGORY_ICONS){if(match&&category===match)return console.debug(` -> match:`,match,icon),icon;if(prefix$1&&category.startsWith(prefix$1))return console.debug(` -> prefix:`,prefix$1,icon),icon}return console.debug(` -> no match, fallback to info`),`info`}function onMessage(args){let{category,clear,text,icon,ttlMs}=normalizePayload(args),matched=[];try{let re=new RegExp(category);matched=Object.keys(messagesByCategory).filter(k=>re.test(k))}catch{}matched.length===0&&(matched=[category]);for(let cat of matched){if(clear||typeof text==`string`&&text===``){delete messagesByCategory[cat];continue}let offset$2=Object.keys(messagesByCategory).length*timerIntervalMs*2;messagesByCategory[cat]={_key:cat,text,icon:icon||deriveIconForCategory(cat),ttl:ttlMs+offset$2}}}function onClearAll(){for(let k in messagesByCategory)delete messagesByCategory[k]}function tick(){for(let k in messagesByCategory){let m=messagesByCategory[k];bypassTtl.value||(m.ttl-=timerIntervalMs),m.ttl<=0&&delete messagesByCategory[k]}}return onMounted(()=>{events$3.on(`Message`,onMessage),events$3.on(`ClearAllMessages`,onClearAll),events$3.on(`MessagesDebug`,data=>{data&&typeof data.bypassTtl==`boolean`&&(bypassTtl.value=!!data.bypassTtl)}),timerId=window.setInterval(tick,timerIntervalMs)}),onUnmounted(()=>{timerId&&window.clearInterval(timerId)}),(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$133,[(openBlock(!0),createElementBlock(Fragment,null,renderList(messagesList.value,item=>(openBlock(),createElementBlock(`div`,{key:item._key,class:`message-row`},[__props.showIcons&&item.icon?(openBlock(),createElementBlock(`div`,_hoisted_2$112,[createVNode(unref(bngIcon_default),mergeProps({class:`msg-icon`,fallbackType:`info`},{ref_for:!0},getIconProps(item)),null,16)])):createCommentVNode(``,!0),createBaseVNode(`div`,_hoisted_3$100,[(openBlock(!0),createElementBlock(Fragment,null,renderList(getParts(item),(part,i)=>(openBlock(),createElementBlock(Fragment,{key:i},[part.t===`text`?(openBlock(),createElementBlock(`span`,_hoisted_4$80,toDisplayString(part.v),1)):(openBlock(),createBlock(unref(bngBinding_default),{key:1,action:part.action,"show-unassigned":``},null,8,[`action`]))],64))),128))])]))),128))]))}},app_default$32=__plugin_vue_export_helper_default(_sfc_main$149,[[`__scopeId`,`data-v-ddfd9832`]]),apps_exports=__export({advancedWheelsDebug:()=>app_default$2,brakeTorqueGraph:()=>app_default$3,busLine:()=>app_default$4,cameraDistance:()=>app_default$5,clutchThermalDebug:()=>app_default$6,compass:()=>app_default$7,compassPrecise:()=>app_default$8,countdown:()=>countdownApp_default,crashTestNextStep:()=>app_default$15,damageApp:()=>app_default$9,dragRace:()=>app_default$10,dragRaceStage:()=>app_default$12,dragRaceTree:()=>app_default$11,driftCurrentDrift:()=>app_default$13,driftScores:()=>app_default$14,engineDebug:()=>app_default$16,engineDynamometer:()=>app_default$17,engineHeatDebugGraph:()=>app_default$18,engineThermalDebug:()=>app_default$19,forcedInduction:()=>app_default$20,forcedInductionDebug:()=>app_default$21,gameplayApps:()=>gameplayApps_default,genericMissionData:()=>bngGenericMissionData_default,hydraulicsDebug:()=>app_default$22,inputHints:()=>app_default$29,keyList:()=>app_default$23,lapTimes:()=>app_default$31,lapTimesDebug:()=>appDebug_default$1,logvehiclestats:()=>app_default$24,messages:()=>app_default$32,messagesTasksApps:()=>messagesTasksApps_default,navigation:()=>app_default$30,pointsBar:()=>app_default,rallyCountdown:()=>appCountdown_default,rallyDashboard:()=>appDashboard_default,rallyDebug:()=>appDebug_default,rallyStageProgress:()=>appStageProgress_default,rallyStageTiming:()=>appStageTiming_default,rallyTimecard:()=>appTimecard_default,rallyVisualPacenotes:()=>app_default$28,replayAppV2:()=>app_default$1,simpleDigTacho:()=>app_default$25,simpleFlashMessage:()=>flashMessageApp_default,tacho2:()=>app_default$26,tasklist:()=>app_default$27});const useTuningStore=defineStore(`tuning`,()=>{let{lua,events:events$3}=useBridge(),buckets=ref({}),tuningVariables=ref({}),editedTuningVars={},isCareer=!1,shoppingData=ref({}),noapi=()=>{throw Error(`Tuning store must be initialised first`)},api$1={request:noapi,apply:noapi,reset:noapi,close:()=>{},menuClose:()=>{}};async function init$3(){for(let name in editedTuningVars={},isCareer=await lua.career_career.isActive(),isCareer?(api$1.request=async()=>processTuningData(await lua.career_modules_tuning.getTuningData()),api$1.apply=(values,edited)=>{let res={};for(let[varName,_]of Object.entries(edited))res[varName]=valDisToVal(values[varName]);lua.career_modules_tuning.apply(res)},api$1.reset=()=>{},api$1.close=()=>{events$3.off(`sendTuningShoppingData`,setShoppingData),events$3.off(`updateTuningVariable`,updateTuningVariable),shoppingData.value={}},events$3.on(`sendTuningShoppingData`,setShoppingData),events$3.on(`updateTuningVariable`,updateTuningVariable)):(api$1.request=async()=>await lua.extensions.core_vehicle_partmgmt.sendDataToUI(),api$1.apply=(values,edited)=>{let res={};for(let varName in values)res[varName]=valDisToVal(values[varName]);lua.extensions.core_vehicle_partmgmt.setConfigVars(res)},api$1.reset=async()=>await lua.extensions.core_vehicle_partmgmt.resetVarsToLoadedConfig(),api$1.close=()=>{events$3.off(`VehicleFocusChanged`,api$1.request),events$3.off(`VehicleConfigChange`,processTuningData)},api$1.menuClose=api$1.close,events$3.on(`VehicleFocusChanged`,api$1.request),events$3.on(`VehicleConfigChange`,processTuningData)),api$1)api$1[name]===noapi&&(api$1[name]=()=>{})}function apply$1(){api$1.apply(tuningVariables.value,editedTuningVars),editedTuningVars={}}function setShoppingData(data){shoppingData.value=data}function updateTuningVariable(tuningVar){tuningVariables.value[tuningVar.name].valDis=Number(valToValDis(tuningVar))}let processTuningData=data=>{data.variables&&(data=data.variables),isCareer&&(delete data.$fuel,delete data.$fuel_R,delete data.$fuel_L),buckets.value=[],tuningVariables.value={};for(let varData of Object.values(data)){if(isCareer&&varData.category===`Cargo`||varData.hideInUI)continue;varData.category||=`Other`,varData.subCategory||=`Other`;let cat=(buckets.value.find(cat$1=>cat$1.name===varData.category)||buckets.value[buckets.value.push({name:varData.category,items:[]})-1]).items;(cat.find(sub=>sub.name===varData.subCategory)||cat[cat.push({name:varData.subCategory,items:[]})-1]).items.push(varData),tuningVariables.value[varData.name]={valDis:Number(valToValDis(varData)),minDis:varData.minDis,maxDis:varData.maxDis,min:varData.min,max:varData.max,default:Number(valToValDis(varData,!0))}}let sorter=(a$1,b)=>a$1.name.localeCompare(b.name);buckets.value.sort(sorter);for(let cat of buckets.value){cat.items.sort(sorter);for(let sub of cat.items)sub.items.sort(sorter)}};function countDecimals(num){return typeof num!=`number`||~~num===num?0:num.toString().split(`.`)[1].length||0}function valToValDis(varData,useDef=!1){return roundDec(round(((useDef?varData.default:varData.val)-varData.min)/(varData.max-varData.min)*(varData.maxDis-varData.minDis),varData.stepDis)+varData.minDis,countDecimals(varData.stepDis))}function valDisToVal(varData){return(varData.valDis-varData.minDis)/(varData.maxDis-varData.minDis)*(varData.max-varData.min)+varData.min}function tuningVarChanged(varName){editedTuningVars[varName]=!0}return{init:init$3,buckets,tuningVariables,shoppingData,apply:apply$1,requestInitialData:()=>api$1.request(),close:()=>api$1.close(),notifyOnMenuClosed:()=>api$1.menuClose(),tuningVarChanged,resetTuningData:()=>api$1.reset()}});var _hoisted_1$132={key:0,class:`tuning-form`},_hoisted_2$111={key:0,class:`extra-features`},_hoisted_3$99={class:`category-heading`},_hoisted_4$79={class:`category-name`},_hoisted_5$68={key:0,class:`subcategory-heading`},_hoisted_6$54={class:`subcategory-name`},_hoisted_7$46={class:`variable-title`},_hoisted_8$38={class:`variable-box`},_hoisted_9$35={class:`tuning-static`},_hoisted_10$29={class:`buttons`},_sfc_main$148={__name:`Tuning`,props:{withBackground:Boolean,buttonTarget:{type:Object},closeButton:Boolean},setup(__props,{expose:__expose}){useUINavBlocker().blockOnly([`context`]);let{lua}=useBridge(),tuningStore=useTuningStore(),awdApp=ref(),awdShow=ref(!1),apply$1=()=>{tuningStore.apply()},close=()=>{tuningStore.close()},mirrorsShown=ref(!0),mirrorsEnabled=ref(!1),mirrorsRoute=`menu.vehicleconfig.tuning.mirrors`,toMirrors=()=>{window.bngVue.gotoGameState(mirrorsRoute)},inputs=ref([]),isChanged=computed(()=>inputs.value.some(ipt=>ipt.dirty));__expose({apply:apply$1,close});let autoApply=ref(!1),applyDebounce=debounce(apply$1,1e3);function onChange(varName){tuningStore.tuningVarChanged(varName),autoApply.value&&applyDebounce()}let applySettingChanged=val=>localStorage.setItem(`applyTuningChangesAutomatically`,JSON.stringify(val));watch(()=>tuningStore.buckets,()=>nextTick(()=>{for(let ipt of inputs.value)ipt.markClean()}));async function resetVarsToLoadedConfig(){tuningStore.resetTuningData(),await tuningStore.requestInitialData(),await nextTick();for(let ipt of inputs.value)ipt.markClean()}onBeforeMount(async()=>{let optAutoApply=localStorage.getItem(`applyTuningChangesAutomatically`);if(optAutoApply)try{autoApply.value=!!JSON.parse(optAutoApply)}catch{}await lua.extensions.gameplay_garageMode.isActive()&&(mirrorsRoute=`menu.vehicleconfig.tuning.mirrors.in-garage`),await lua.career_career.isActive()?mirrorsShown.value=!1:mirrorsEnabled.value=(await useSettingsAsync()).values.GraphicDynMirrorsEnabled,await tuningStore.init(),await tuningStore.requestInitialData(),getUINavServiceInstance().setFilteredEvents(UI_EVENT_GROUPS.focusMoveScalar)});let extraFeatures=computed(()=>{let features=[];return mirrorsEnabled.value&&features.push({mirrorsEnabled:!0}),features});return onUnmounted(async()=>{await tuningStore.notifyOnMenuClosed(),tuningStore.close(),tuningStore.$dispose(),getUINavServiceInstance().clearFilteredEvents()}),(_ctx,_cache)=>withDirectives((openBlock(),createElementBlock(`div`,{class:normalizeClass({innerTuningCard:!0,"with-background":__props.withBackground})},[unref(tuningStore).buckets?(openBlock(),createElementBlock(`div`,_hoisted_1$132,[extraFeatures.value.length>0?(openBlock(),createElementBlock(`div`,_hoisted_2$111,[withDirectives((openBlock(),createBlock(unref(bngButton_default),{onClick:toMirrors,accent:`secondary`},{default:withCtx(()=>[createTextVNode(toDisplayString(_ctx.$t(`ui.mirrors.name`)),1)]),_:1})),[[unref(BngDisabled_default),!extraFeatures.value.find(f=>f.mirrorsEnabled)]])])):createCommentVNode(``,!0),(openBlock(!0),createElementBlock(Fragment,null,renderList(unref(tuningStore).buckets,category=>(openBlock(),createElementBlock(`div`,{class:`tuning-category`,key:category.name},[createBaseVNode(`h2`,_hoisted_3$99,[createBaseVNode(`span`,_hoisted_4$79,toDisplayString(category.name),1)]),(openBlock(!0),createElementBlock(Fragment,null,renderList(category.items,subCategory=>(openBlock(),createElementBlock(`div`,{class:`tuning-subcategory`,key:subCategory.name},[subCategory.name===`Other`?createCommentVNode(``,!0):(openBlock(),createElementBlock(`h3`,_hoisted_5$68,[createBaseVNode(`span`,_hoisted_6$54,toDisplayString(subCategory.name),1)])),(openBlock(!0),createElementBlock(Fragment,null,renderList(subCategory.items,varData=>withDirectives((openBlock(),createElementBlock(`div`,{key:category.name+subCategory.name+varData.name,class:normalizeClass({"input-container":!0,"variable-box":varData.type===`slider`})},[createBaseVNode(`div`,_hoisted_7$46,toDisplayString(varData.title),1),createBaseVNode(`div`,_hoisted_8$38,[createVNode(unref(bngSlider_default),{ref_for:!0,ref_key:`inputs`,ref:inputs,min:varData.minDis,max:varData.maxDis,step:varData.stepDis,unit:varData.unit,class:normalizeClass({"property-slider":!0}),"with-input":``,"with-reset":``,"orig-value":unref(tuningStore).tuningVariables[varData.name].default,modelValue:unref(tuningStore).tuningVariables[varData.name].valDis,"onUpdate:modelValue":$event=>unref(tuningStore).tuningVariables[varData.name].valDis=$event,onValueChanged:$event=>onChange(varData.name)},null,8,[`min`,`max`,`step`,`unit`,`orig-value`,`modelValue`,`onUpdate:modelValue`,`onValueChanged`])])],2)),[[unref(BngTooltip_default),varData.description,`top`]])),128))]))),128))]))),128))])):createCommentVNode(``,!0),createBaseVNode(`div`,_hoisted_9$35,[withDirectives(createVNode(unref(app_default$2),{class:normalizeClass({"awd-app":awdApp.value}),ref_key:`awdApp`,ref:awdApp},null,8,[`class`]),[[vShow,awdShow.value]]),awdApp.value&&awdApp.value.hasData?(openBlock(),createBlock(unref(bngSwitch_default),{key:0,modelValue:awdShow.value,"onUpdate:modelValue":_cache[0]||=$event=>awdShow.value=$event},{default:withCtx(()=>[createTextVNode(toDisplayString(_ctx.$t(`ui.garage.tune.advWheel`)),1)]),_:1},8,[`modelValue`])):createCommentVNode(``,!0),createVNode(unref(bngSwitch_default),{modelValue:autoApply.value,"onUpdate:modelValue":_cache[1]||=$event=>autoApply.value=$event,onValueChanged:applySettingChanged},{default:withCtx(()=>[createTextVNode(toDisplayString(_ctx.$t(`ui.garage.liveUpdates`)),1)]),_:1},8,[`modelValue`]),createBaseVNode(`div`,_hoisted_10$29,[withDirectives(createVNode(unref(bngButton_default),{"show-hold":``,icon:unref(icons).undo,accent:unref(ACCENTS).custom,class:`reset-button`},null,8,[`icon`,`accent`]),[[unref(BngOnUiNav_default),void 0,`ok`,{asMouse:!0,focusRequired:!0}],[unref(BngClick_default),{holdCallback:resetVarsToLoadedConfig,holdDelay:1e3,repeatInterval:0}],[unref(BngTooltip_default),`Reset to original config`]]),createVNode(unref(bngButton_default),{disabled:autoApply.value||!isChanged.value,onClick:apply$1},{default:withCtx(()=>[createTextVNode(toDisplayString(_ctx.$t(`ui.common.apply`)),1)]),_:1},8,[`disabled`]),__props.closeButton?(openBlock(),createBlock(unref(bngButton_default),{key:0,onClick:close,accent:unref(ACCENTS).attention},{default:withCtx(()=>[createVNode(unref(bngBinding_default),{"ui-event":`back`,deviceMask:`xinput`}),createTextVNode(toDisplayString(_ctx.$t(`ui.common.close`)),1)]),_:1},8,[`accent`])):createCommentVNode(``,!0)])])],2)),[[unref(BngBlur_default),__props.withBackground]])}},Tuning_default=__plugin_vue_export_helper_default(_sfc_main$148,[[`__scopeId`,`data-v-907bf291`]]),CANCEL_MESSAGE=`Are you sure you want to cancel?
    All changes to your vehicle will be reversed`,_sfc_main$147={__name:`TuningMain`,setup(__props){useComputerStore();let tuningStore=useTuningStore(),CONFIRM_BUTTONS=[{label:$translate.instant(`ui.common.yes`),value:!0},{label:$translate.instant(`ui.common.no`),value:!1,extras:{accent:ACCENTS.secondary}}],confirmCancel=async()=>{(!(tuningStore.shoppingData.shoppingCart&&tuningStore.shoppingData.shoppingCart.items.length)||await openConfirmation(null,CANCEL_MESSAGE,CONFIRM_BUTTONS))&&cancelShopping()},cartData=computed(()=>{let cart=tuningStore.shoppingData?tuningStore.shoppingData.shoppingCart:null,res={total:0,taxes:0,items:[]};return cart&&(res.total=cart.total,res.taxes=cart.taxes,Array.isArray(cart.items)&&(res.items=cart.items.map(item=>({type:item.type||item.level===1&&`item`,level:item.level,name:item.title,price:item.price,priceHide:!item.price,removeShow:!!item.varName,remove:()=>Lua_default.career_modules_tuning.removeVarFromShoppingCart(item.varName)})))),res}),elCard=ref(),applyShopping=()=>Lua_default.career_modules_tuning.applyShopping(),cancelShopping=()=>Lua_default.career_modules_tuning.cancelShopping();return(_ctx,_cache)=>(openBlock(),createBlock(ComputerWrapper_default,{path:[`Tuning`],title:`Tuning`,back:``,onBack:confirmCancel},{side:withCtx(()=>[createVNode(ShoppingCart_default,{"cart-data":cartData.value,"player-money":unref(tuningStore).shoppingData.playerMoney,"confirm-button-text":`Confirm`,apply:applyShopping,cancel:confirmCancel},null,8,[`cart-data`,`player-money`])]),default:withCtx(()=>[withDirectives((openBlock(),createBlock(unref(bngCard_default),{class:`tuningCard`,ref_key:`elCard`,ref:elCard},{buttons:withCtx(()=>[..._cache[0]||=[]]),default:withCtx(()=>[createVNode(Tuning_default,{"button-target":elCard.value&&elCard.value.buttonsContainer,"close-button":!1},null,8,[`button-target`])]),_:1})),[[unref(BngBlur_default),1]])]),_:1}))}},TuningMain_default=__plugin_vue_export_helper_default(_sfc_main$147,[[`__scopeId`,`data-v-60311783`]]);const useVehicleInventoryStore=defineStore(`vehicleInventory`,()=>{let{events:events$3}=useBridge(),vehicleInventoryData=ref({}),vehIdToChooseAfterRepairPopup=ref(0),filteredVehicles=computed(()=>{let data=vehicleInventoryData.value;return data.vehicles?Object.values(data.vehicles):[]}),menuOpen=!1;function requestInitialData(){Lua_default.career_modules_inventory.sendDataToUi()}function closeMenu(){Lua_default.career_modules_inventory.closeMenu()}let getExpediteRepairCost=vehicle=>Math.max(vehicle.quickRepairExtraPrice*(vehicle.timeToAccess/vehicle.initialRepairTime),50);function countDownVehicleDelays(){if(menuOpen){for(let vehicle of filteredVehicles.value)vehicle.timeToAccess&&(--vehicle.timeToAccess,vehicle.delayReason==`repair`&&(vehicle.expediteRepairCost=getExpediteRepairCost(vehicle)),vehicle.timeToAccess<=0&&Lua_default.career_modules_inventory.sendDataToUi());setTimeout(countDownVehicleDelays,1e3)}}events$3.on(`vehicleInventoryData`,data=>{Object.values(data.vehicles).forEach(vehicle=>{data.currentVehicleId===vehicle.id&&(vehicle.niceName+=` (Current Vehicle)`),vehicle.owned||(vehicle.niceName+=` (Not owned)`)}),vehicleInventoryData.value=data,vehIdToChooseAfterRepairPopup.value=0,menuOpen||(menuOpen=!0,countDownVehicleDelays())});function menuClosed(){menuOpen=!1}function repairPopupAccept(){Lua_default.career_modules_inventory.chooseVehicleFromMenu(vehIdToChooseAfterRepairPopup.value,1,!0),vehIdToChooseAfterRepairPopup.value=0}function repairPopupDecline(){Lua_default.career_modules_inventory.chooseVehicleFromMenu(vehIdToChooseAfterRepairPopup.value,1,!1),vehIdToChooseAfterRepairPopup.value=0}function chooseVehicle(vehId,buttonIndex){let showRepairPopup=!1,data=vehicleInventoryData.value;if(data.currentVehicleId!==void 0&&vehId!==data.currentVehicleId&&(showRepairPopup=data.vehicles[data.currentVehicleId].needsRepair),showRepairPopup){vehIdToChooseAfterRepairPopup.value=vehId;return}Lua_default.career_modules_inventory.chooseVehicleFromMenu(vehId,buttonIndex+1,!1)}function dispose$2(){events$3.off(`vehicleInventoryData`)}return{filteredVehicles,vehIdToChooseAfterRepairPopup,vehicleInventoryData,requestInitialData,chooseVehicle,repairPopupAccept,repairPopupDecline,menuClosed,closeMenu,dispose:dispose$2}});var _hoisted_1$131={class:`list-vehicle-dialog`},_hoisted_2$110={class:`vehicle-info`},_hoisted_3$98={class:`name`},_hoisted_4$78={key:0,class:`meta`},_hoisted_5$67={key:1,class:`meta`},_hoisted_6$53={class:`price-box`},_hoisted_7$45={class:`price-content`},_hoisted_8$37={class:`price-row`},_hoisted_9$34={class:`step-buttons-group`},_hoisted_10$28={class:`price`},_hoisted_11$26={class:`step-buttons-group`},_sfc_main$146={__name:`ListVehicleDialog`,props:{modelValue:{type:Object,required:!0}},emits:[`update:modelValue`],setup(__props,{emit:__emit}){let props=__props,emit$1=__emit,{units}=useBridge(),formModel=computed({get:()=>props.modelValue,set:newValue=>emit$1(`update:modelValue`,newValue)});function adjustPrice(amount){let price=Math.max(0,Math.round(((formModel.value.price||0)+amount)/50)*50);emit$1(`update:modelValue`,{...formModel.value,price})}let priceHint=computed(()=>{let mv=Number(formModel.value.marketValue||0),p$1=Number(formModel.value.price||0);if(!mv||!p$1)return{text:``,class:``};let diff=(p$1-mv)/mv,percent=Math.round(Math.abs(diff)*100);return percent<1?{text:`Fair market value`,class:`ok`}:diff>0?{text:`${percent}% above market value`,class:`high`}:{text:`${percent}% below market value`,class:`low`}}),offerHint=computed(()=>{let mv=Number(formModel.value.marketValue||0),p$1=Number(formModel.value.price||0);if(!mv||!p$1)return{text:`Regular offers expected`,class:`regular`};let ratio=p$1/mv;return ratio<=.9?{text:`More offers expected`,class:`more`}:ratio>=1.2?{text:`Fewer offers expected`,class:`fewer`}:{text:`Regular offers expected`,class:`regular`}}),formModelText=computed(()=>formModel.value.odometerKm?new Intl.NumberFormat().format(Math.round(formModel.value.odometerKm))+` km`:``);return(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$131,[createBaseVNode(`div`,_hoisted_2$110,[createBaseVNode(`div`,_hoisted_3$98,toDisplayString(formModel.value.vehicleName),1),formModelText.value?(openBlock(),createElementBlock(`div`,_hoisted_4$78,toDisplayString(formModelText.value)+` — Market Value: `+toDisplayString(unref(units).beamBucks(formModel.value.marketValue||0)),1)):(openBlock(),createElementBlock(`div`,_hoisted_5$67,` Market Value: `+toDisplayString(unref(units).beamBucks(formModel.value.marketValue||0)),1))]),createBaseVNode(`div`,_hoisted_6$53,[createBaseVNode(`div`,_hoisted_7$45,[_cache[12]||=createBaseVNode(`div`,{class:`label`},`Your Asking Price`,-1),createBaseVNode(`div`,_hoisted_8$37,[createBaseVNode(`div`,_hoisted_9$34,[createVNode(unref(bngButton_default),{class:`step step-large`,accent:unref(ACCENTS).secondary,onClick:_cache[0]||=$event=>adjustPrice(-5e3)},{default:withCtx(()=>[..._cache[6]||=[createTextVNode(`-5000`,-1)]]),_:1},8,[`accent`]),createVNode(unref(bngButton_default),{class:`step step-medium`,accent:unref(ACCENTS).secondary,onClick:_cache[1]||=$event=>adjustPrice(-500)},{default:withCtx(()=>[..._cache[7]||=[createTextVNode(`-500`,-1)]]),_:1},8,[`accent`]),createVNode(unref(bngButton_default),{class:`step`,accent:unref(ACCENTS).secondary,onClick:_cache[2]||=$event=>adjustPrice(-50)},{default:withCtx(()=>[..._cache[8]||=[createTextVNode(`-50`,-1)]]),_:1},8,[`accent`])]),createBaseVNode(`div`,_hoisted_10$28,toDisplayString(unref(units).beamBucks(formModel.value.price||0)),1),createBaseVNode(`div`,_hoisted_11$26,[createVNode(unref(bngButton_default),{class:`step`,accent:unref(ACCENTS).secondary,onClick:_cache[3]||=$event=>adjustPrice(50)},{default:withCtx(()=>[..._cache[9]||=[createTextVNode(`+50`,-1)]]),_:1},8,[`accent`]),createVNode(unref(bngButton_default),{class:`step step-medium`,accent:unref(ACCENTS).secondary,onClick:_cache[4]||=$event=>adjustPrice(500)},{default:withCtx(()=>[..._cache[10]||=[createTextVNode(`+500`,-1)]]),_:1},8,[`accent`]),createVNode(unref(bngButton_default),{class:`step step-large`,accent:unref(ACCENTS).secondary,onClick:_cache[5]||=$event=>adjustPrice(5e3)},{default:withCtx(()=>[..._cache[11]||=[createTextVNode(`+5000`,-1)]]),_:1},8,[`accent`])])]),createBaseVNode(`div`,{class:normalizeClass([`hint`,[priceHint.value.class]])},toDisplayString(priceHint.value.text),3),createBaseVNode(`div`,{class:normalizeClass([`offer-hint`,[offerHint.value.class]])},toDisplayString(offerHint.value.text),3)])])]))}},ListVehicleDialog_default=__plugin_vue_export_helper_default(_sfc_main$146,[[`__scopeId`,`data-v-87a25af5`]]),_hoisted_1$130={class:`vehicle-list-container`},_sfc_main$145={__name:`VehicleList`,setup(__props){let{units}=useBridge(),{$game}=useLibStore(),popover=usePopover(),popId=uniqueId(`veh_options`),popHide=()=>popover.hide(popId),licensePlateTextValid=ref(!0),vehicleNameValid=ref(!0),vehicleInventoryStore=useVehicleInventoryStore(),selectedVehId=ref(),vehSelected=computed(()=>{if(typeof selectedVehId.value==`number`)return listView.value.find(v=>v.id===selectedVehId.value)}),careerStatusData=ref({}),updateCareerStatusData=()=>Lua_default.career_modules_uiUtils.getCareerStatusData().then(data=>careerStatusData.value=data),cantPayLicensePlate=computed(()=>!careerStatusData.value.money||300>careerStatusData.value.money),listStatus=computed(()=>vehicleInventoryStore?!Array.isArray(vehicleInventoryStore.filteredVehicles)||vehicleInventoryStore.filteredVehicles.length===0?`You don't currently own any vehicles`:null:`Please wait...`),listView=computed(()=>{if(!vehicleInventoryStore||!Array.isArray(vehicleInventoryStore.filteredVehicles)||vehicleInventoryStore.filteredVehicles.length===0)return[];let res=vehicleInventoryStore.filteredVehicles;if(singleFunction.value)for(let veh of res)veh.disabled=!isFunctionAvailable(veh,singleFunction.value);return res.sort((a$1,b)=>a$1.favorite?-1:b.favorite?1:a$1.niceName.localeCompare(b.niceName)),res}),itemLayout=ref({TILE:`tile`,LIST:`row`}.TILE),singleFunction=computed(()=>{if(!vehicleInventoryStore||!vehicleInventoryStore.vehicleInventoryData)return null;let data=vehicleInventoryStore.vehicleInventoryData;return Object.values(data.buttonsActive).includes(!0)||!Array.isArray(data.chooseButtonsData)||data.chooseButtonsData.length!==1?null:data.chooseButtonsData[0]});function select(vehicle,evt){let show=vehicleInventoryStore&&vehicleInventoryStore.vehicleInventoryData&&(Object.values(vehicleInventoryStore.vehicleInventoryData.buttonsActive).includes(!0)||vehicleInventoryStore.vehicleInventoryData.chooseButtonsData.length>0)&&vehicle&&(!vehSelected.value||vehSelected.value.id!==vehicle.id),popover$1;if(evt&&evt.target){let cur=evt.target;for(;popover$1=cur.__popover,!(popover$1||(cur=cur.parentNode,cur===document.body)););}if(vehicle&&singleFunction.value){selectedVehId.value=null,popover$1&&popover$1.hide(),vehicleInventoryStore.chooseVehicle(vehicle.id,0);return}show&&popover$1&&popover$1.hide(),nextTick(()=>{show?(selectedVehId.value=vehicle.id,popover$1&&popover$1.show()):(popover$1&&popover$1.hide(),selectedVehId.value=null)})}let isFunctionAvailable=(vehicle,buttonData)=>!(vehicle.timeToAccess||vehicle.missingFile||buttonData.requiredVehicleNotInGarage&&vehicle.inGarage||buttonData.requiredOtherVehicleInGarage&&!vehicle.otherVehicleInGarage||buttonData.ownedRequired&&!vehicle.owned||buttonData.repairRequired&&vehicle.needsRepair||buttonData.notForSaleRequired&&vehicle.listedForSale),lookAtVehicleListing=()=>{Lua_default.career_modules_marketplace.openMenu(vehicleInventoryStore.vehicleInventoryData.originComputerId)},confirmReturnVehicle=async()=>{let vehicle=vehSelected.value;popHide(),await openConfirmation(``,`Do you want to return this loaned vehicle to the owner?`,[{label:$translate.instant(`ui.common.yes`),value:!0,extras:{default:!0}},{label:$translate.instant(`ui.common.no`),value:!1,extras:{accent:ACCENTS.secondary}}])&&Lua_default.career_modules_inventory.returnLoanedVehicleFromInventory(vehicle.id)},personalizeLicensePlate=async()=>{let vehicle=vehSelected.value;popHide(),updateCareerStatusData();let res=await openPrompt(`Enter your new license plate text:`,`Personalize License Plate`,{maxLength:10,defaultValue:vehicle.config.licenseName,buttons:[{label:$translate.instant(`ui.common.cancel`),value:!1,extras:{cancel:!0,accent:ACCENTS.secondary}},{label:$translate.instant(`ui.common.okay`)+` (Cost: ${units.beamBucks(300)})`,value:text=>text,extras:{disabled:cantPayLicensePlate,accent:ACCENTS.primary}}],validate:text=>(Lua_default.career_modules_inventory.isLicensePlateValid(text).then(valid=>{licensePlateTextValid.value=valid}),licensePlateTextValid.value),errorMessage:`Invalid character in license plate text`,disableWhenInvalid:!0});res!=0&&(Lua_default.career_modules_inventory.purchaseLicensePlateText(vehicle.id,res,300),vehicle.config.licenseName=res)},confirmExpediteRepair=async()=>{let vehicle=vehSelected.value;popHide();let price=vehicle.expediteRepairCost;await openConfirmation(``,`Do you want to expedite the repair for ${units.beamBucks(price)}?`,[{label:$translate.instant(`ui.common.yes`),value:!0,extras:{default:!0}},{label:$translate.instant(`ui.common.no`),value:!1,extras:{accent:ACCENTS.secondary}}])&&Lua_default.career_modules_inventory.expediteRepairFromInventory(vehicle.id,price)},openRepairMenu=()=>{let vehicle=vehSelected.value;popHide(),Lua_default.career_modules_insurance_repairScreen.openRepairMenu(vehicle,vehicleInventoryStore.vehicleInventoryData.originComputerId)},setFavoriteVehicle=()=>{let vehicle=vehSelected.value;popHide(),Lua_default.career_modules_inventory.setFavoriteVehicle(vehicle.id),Lua_default.career_modules_inventory.sendDataToUi()},storeVehicle=()=>{let vehicle=vehSelected.value;popHide(),Lua_default.career_modules_inventory.removeVehicleObject(vehicle.id),Lua_default.career_modules_inventory.sendDataToUi()},renameVehicle=async()=>{let vehicle=vehSelected.value;popHide();let res=await openPrompt(`Enter new vehicle name:`,`Rename Vehicle`,{maxLength:30,defaultValue:vehicle.niceName,buttons:[{label:$translate.instant(`ui.common.cancel`),value:!1,extras:{cancel:!0,accent:ACCENTS.secondary}},{label:$translate.instant(`ui.common.okay`),value:text=>text,extras:{accent:ACCENTS.primary}}],validate:text=>(Lua_default.career_modules_inventory.isVehicleNameValid(text).then(valid=>{vehicleNameValid.value=valid}),vehicleNameValid.value),errorMessage:`Invalid characters in vehicle name`,disableWhenInvalid:!0});res!=0&&(Lua_default.career_modules_inventory.renameVehicle(vehicle.id,res),vehicle.niceName=res)},listVehicleForSale=async vehicle=>{popHide();let res=await openFormDialog(ListVehicleDialog_default,{vehicleName:vehicle.niceName,odometer:vehicle.odometer,marketValue:vehicle.value,price:Math.max(50,Math.round((vehicle.value||0)/50)*50)},model=>!Number.isFinite(model.price)||model.price<=0?{error:!0,message:`Enter a valid positive price`}:{error:!1},`List a Vehicle for Sale`,void 0,void 0,`90rem`);!res||!res.value||await Lua_default.career_modules_marketplace.listVehicles([{inventoryId:vehicle.id,value:res.formData.price}])},listVehicleForSaleFromContextMenu=async()=>{let vehicle=vehSelected.value;await listVehicleForSale(vehicle),Lua_default.career_modules_marketplace.openMenu(vehicleInventoryStore.vehicleInventoryData.originComputerId)},listVehicleForSaleFromMarketplaceMenu=async vehicle=>{await listVehicleForSale(vehicle),router_default.back()};return $game.events.on(`addListing`,data=>{listVehicleForSaleFromMarketplaceMenu(listView.value.find(v=>v.id===data.inventoryId))}),onUnmounted(()=>{$game.events.off(`addListing`)}),(_ctx,_cache)=>withDirectives((openBlock(),createElementBlock(`div`,_hoisted_1$130,[listStatus.value?withDirectives((openBlock(),createBlock(VehicleTileRow_default,{key:0,class:`vehicle-list-item`,data:{_message:listStatus.value},layout:itemLayout.value},null,8,[`data`,`layout`])),[[unref(BngDisabled_default)]]):(openBlock(!0),createElementBlock(Fragment,{key:1},renderList(listView.value,vehicle=>withDirectives((openBlock(),createBlock(VehicleTileRow_default,{class:`vehicle-list-item`,key:vehicle.id,data:vehicle,layout:itemLayout.value,selected:vehSelected.value&&vehSelected.value.id===vehicle.id,"is-tutorial":unref(vehicleInventoryStore)&&unref(vehicleInventoryStore).vehicleInventoryData.tutorialActive,money:unref(vehicleInventoryStore)?unref(vehicleInventoryStore).vehicleInventoryData.playerMoney:0,tabindex:`0`,"bng-nav-item":``,onClick:$event=>!vehicle.disabled&&select(vehicle,$event)},null,8,[`data`,`layout`,`selected`,`is-tutorial`,`money`,`onClick`])),[[unref(BngDisabled_default),vehicle.disabled],[unref(BngOnUiNav_default),void 0,`ok`,{asMouse:!0,focusRequired:!0}],[unref(BngPopover_default),unref(popId),`right-start`,{click:!0}]])),128)),createVNode(unref(bngPopoverMenu_default),{name:unref(popId),focus:``,onHide:_cache[9]||=$event=>selectedVehId.value=null},{default:withCtx(()=>[(openBlock(!0),createElementBlock(Fragment,null,renderList(unref(vehicleInventoryStore).vehicleInventoryData.chooseButtonsData,(buttonData,index)=>(openBlock(),createElementBlock(Fragment,{key:index},[buttonData.repairRequired&&vehSelected.value&&vehSelected.value.needsRepair&&!unref(vehicleInventoryStore).vehicleInventoryData.tutorialActive?(openBlock(),createBlock(unref(bngButton_default),{key:0,accent:unref(ACCENTS).menu,disabled:``},{default:withCtx(()=>[createTextVNode(toDisplayString(buttonData.buttonText)+` (Needs repair) `,1)]),_:2},1032,[`accent`])):vehSelected.value&&isFunctionAvailable(vehSelected.value,buttonData)?withDirectives((openBlock(),createBlock(unref(bngButton_default),{key:1,accent:unref(ACCENTS).menu,onClick:$event=>unref(vehicleInventoryStore).chooseVehicle(vehSelected.value.id,index)},{default:withCtx(()=>[createTextVNode(toDisplayString(buttonData.buttonText),1)]),_:2},1032,[`accent`,`onClick`])),[[unref(BngOnUiNav_default),void 0,`ok`,{focusRequired:!0,asMouse:!0}]]):createCommentVNode(``,!0)],64))),128)),vehSelected.value&&unref(vehicleInventoryStore).vehicleInventoryData.buttonsActive.returnLoanerEnabled&&vehSelected.value.returnLoanerPermission.allow?withDirectives((openBlock(),createBlock(unref(bngButton_default),{key:0,accent:unref(ACCENTS).menu,onClick:_cache[0]||=$event=>confirmReturnVehicle()},{default:withCtx(()=>[..._cache[10]||=[createTextVNode(` Return loaned vehicle `,-1)]]),_:1},8,[`accent`])),[[unref(BngOnUiNav_default),void 0,`ok`,{focusRequired:!0,asMouse:!0}]]):createCommentVNode(``,!0),vehSelected.value&&vehSelected.value.delayReason===`repair`?withDirectives((openBlock(),createBlock(unref(bngButton_default),{key:1,accent:unref(ACCENTS).menu,disabled:vehSelected.value.expediteRepairCost>unref(vehicleInventoryStore).vehicleInventoryData.playerMoney,onClick:_cache[1]||=$event=>confirmExpediteRepair(vehSelected.value)},{default:withCtx(()=>[_cache[11]||=createTextVNode(` Expedite Repair `,-1),createVNode(unref(bngUnit_default),{money:vehSelected.value.expediteRepairCost},null,8,[`money`])]),_:1},8,[`accent`,`disabled`])),[[unref(BngOnUiNav_default),void 0,`ok`,{focusRequired:!0,asMouse:!0}]]):createCommentVNode(``,!0),vehSelected.value&&vehSelected.value.delayReason!==`repair`&&unref(vehicleInventoryStore).vehicleInventoryData.buttonsActive.repairEnabled?withDirectives((openBlock(),createBlock(unref(bngButton_default),{key:2,accent:unref(ACCENTS).menu,disabled:!vehSelected.value.repairPermission.allow,onClick:_cache[2]||=$event=>openRepairMenu()},{default:withCtx(()=>[..._cache[12]||=[createTextVNode(` Repair `,-1)]]),_:1},8,[`accent`,`disabled`])),[[unref(BngOnUiNav_default),void 0,`ok`,{focusRequired:!0,asMouse:!0}]]):createCommentVNode(``,!0),vehSelected.value&&unref(vehicleInventoryStore).vehicleInventoryData.buttonsActive.storingEnabled&&!vehSelected.value.inStorage?withDirectives((openBlock(),createBlock(unref(bngButton_default),{key:3,accent:unref(ACCENTS).menu,disabled:!vehSelected.value.storePermission.allow,onClick:_cache[3]||=$event=>storeVehicle()},{default:withCtx(()=>[..._cache[13]||=[createTextVNode(` Put in storage `,-1)]]),_:1},8,[`accent`,`disabled`])),[[unref(BngOnUiNav_default),void 0,`ok`,{focusRequired:!0,asMouse:!0}]]):createCommentVNode(``,!0),vehSelected.value&&unref(vehicleInventoryStore).vehicleInventoryData.buttonsActive.favoriteEnabled?withDirectives((openBlock(),createBlock(unref(bngButton_default),{key:4,accent:unref(ACCENTS).menu,disabled:!vehSelected.value.favoritePermission.allow||vehSelected.value.favorite,onClick:_cache[4]||=$event=>setFavoriteVehicle()},{default:withCtx(()=>[..._cache[14]||=[createTextVNode(` Set as Favorite `,-1)]]),_:1},8,[`accent`,`disabled`])),[[unref(BngOnUiNav_default),void 0,`ok`,{focusRequired:!0,asMouse:!0}]]):createCommentVNode(``,!0),vehSelected.value?withDirectives((openBlock(),createBlock(unref(bngButton_default),{key:5,accent:unref(ACCENTS).menu,disabled:!vehSelected.value.licensePlateChangePermission.allow,onClick:_cache[5]||=$event=>personalizeLicensePlate(vehSelected.value)},{default:withCtx(()=>[..._cache[15]||=[createTextVNode(` Personalize license plate `,-1)]]),_:1},8,[`accent`,`disabled`])),[[unref(BngOnUiNav_default),void 0,`ok`,{focusRequired:!0,asMouse:!0}]]):createCommentVNode(``,!0),vehSelected.value?withDirectives((openBlock(),createBlock(unref(bngButton_default),{key:6,accent:unref(ACCENTS).menu,onClick:_cache[6]||=$event=>renameVehicle()},{default:withCtx(()=>[..._cache[16]||=[createTextVNode(` Rename vehicle `,-1)]]),_:1},8,[`accent`])),[[unref(BngOnUiNav_default),void 0,`ok`,{focusRequired:!0,asMouse:!0}]]):createCommentVNode(``,!0),vehSelected.value&&unref(vehicleInventoryStore).vehicleInventoryData.buttonsActive.sellEnabled&&!vehSelected.value.listedForSale?withDirectives((openBlock(),createBlock(unref(bngButton_default),{key:7,accent:unref(ACCENTS).menu,disabled:!vehSelected.value.sellPermission.allow,onClick:_cache[7]||=$event=>listVehicleForSaleFromContextMenu()},{default:withCtx(()=>[..._cache[17]||=[createTextVNode(` List vehicle for sale `,-1)]]),_:1},8,[`accent`,`disabled`])),[[unref(BngOnUiNav_default),void 0,`ok`,{focusRequired:!0,asMouse:!0}]]):createCommentVNode(``,!0),vehSelected.value&&unref(vehicleInventoryStore).vehicleInventoryData.buttonsActive.sellEnabled&&vehSelected.value.listedForSale?withDirectives((openBlock(),createBlock(unref(bngButton_default),{key:8,accent:unref(ACCENTS).menu,disabled:!vehSelected.value.sellPermission.allow,onClick:_cache[8]||=$event=>lookAtVehicleListing()},{default:withCtx(()=>[..._cache[18]||=[createTextVNode(` Go to vehicle listing `,-1)]]),_:1},8,[`accent`,`disabled`])),[[unref(BngOnUiNav_default),void 0,`ok`,{focusRequired:!0,asMouse:!0}]]):createCommentVNode(``,!0)]),_:1},8,[`name`])])),[[unref(BngDisabled_default),!unref(vehicleInventoryStore)]])}},VehicleList_default$1=__plugin_vue_export_helper_default(_sfc_main$145,[[`__scopeId`,`data-v-5a84a046`]]),_sfc_main$144=Object.assign({inheritAttrs:!1},{__name:`VehicleInventory`,setup(__props,{expose:__expose}){let vehicleInventoryStore=useVehicleInventoryStore(),attrs=useAttrs();return __expose({closeMenu:vehicleInventoryStore.closeMenu}),onBeforeMount(()=>{vehicleInventoryStore.requestInitialData()}),onUnmounted(()=>{Lua_default.extensions.hook(`onExitVehicleInventory`),vehicleInventoryStore.menuClosed(),vehicleInventoryStore.$dispose()}),(_ctx,_cache)=>(openBlock(),createBlock(VehicleList_default$1,normalizeProps(guardReactiveProps(unref(attrs))),null,16))}}),VehicleInventory_default=_sfc_main$144,_sfc_main$143={__name:`VehicleInventoryMain`,setup(__props){let vehicleInventoryStore=useVehicleInventoryStore(),router$1=useRouter(),title=computed(()=>vehicleInventoryStore.vehicleInventoryData.header||`My vehicles`);watch(()=>vehicleInventoryStore.vehIdToChooseAfterRepairPopup,(newId,oldId)=>{!oldId&&newId&&confirmRepair()});let confirmRepair=async vehicle=>{await openConfirmation(``,`Do you want to repair your previous vehicle?`,[{label:$translate.instant(`ui.common.yes`),value:!0,extras:{default:!0}},{label:$translate.instant(`ui.common.no`),value:!1,extras:{accent:ACCENTS.secondary}}])?vehicleInventoryStore.repairPopupAccept():vehicleInventoryStore.repairPopupDecline()},elInventory=ref(),close=()=>router$1.back();return onUnmounted(()=>{vehicleInventoryStore.$dispose()}),(_ctx,_cache)=>(openBlock(),createBlock(ComputerWrapper_default,{ref:`wrapper`,title:title.value,back:``,onBack:close},{default:withCtx(()=>[createVNode(VehicleInventory_default,{ref_key:`elInventory`,ref:elInventory,class:`vehicle-inventory`},null,512)]),_:1},8,[`title`]))}},VehicleInventoryMain_default=__plugin_vue_export_helper_default(_sfc_main$143,[[`__scopeId`,`data-v-88176408`]]);const useVehiclePurchaseStore=defineStore(`vehiclePurchase`,()=>{let{events:events$3}=useBridge(),purchaseType=ref(``),vehicleInfo=ref({}),playerMoney=ref(0),alreadyDidTestDrive=ref(!1),inventoryHasFreeSlot=ref(!1),tradeInVehicleInfo=ref({}),tradeInEnabled=ref(!1),forceTradeIn=ref(!1),locationSelectionEnabled=ref(!1),forceNoDelivery=ref(!1),makeDelivery=ref(!1),buyCustomLicensePlate=ref(!1),customLicensePlateText=ref(``),prices=ref({}),insuranceOptions=ref({}),finalPackagePrice=computed(()=>{let price=prices.value.finalPrice;return buyCustomLicensePlate.value&&(price+=prices.value.customLicensePlate),insuranceOptions.value.insuranceId>0&&(price+=insuranceOptions.value.priceMoney),price}),handlePurchaseData=data=>{vehicleInfo.value=data.vehicleInfo,playerMoney.value=data.playerMoney,inventoryHasFreeSlot.value=data.inventoryHasFreeSlot,purchaseType.value=data.purchaseType,tradeInEnabled.value=data.tradeInEnabled,locationSelectionEnabled.value=data.locationSelectionEnabled,forceNoDelivery.value=data.forceNoDelivery,prices.value=data.prices,makeDelivery.value=!1,buyCustomLicensePlate.value=!1,customLicensePlateText.value=``,alreadyDidTestDrive.value=data.alreadyDidTestDrive,forceTradeIn.value=data.forceTradeIn,insuranceOptions.value=data.insuranceOptions,data.tradeInVehicleInfo===void 0?tradeInVehicleInfo.value={}:tradeInVehicleInfo.value=data.tradeInVehicleInfo};function requestPurchaseData(){Lua_default.career_modules_vehicleShopping.sendPurchaseDataToUi()}function buyVehicle(makeDelivery$1){let options={makeDelivery:makeDelivery$1,insuranceId:insuranceOptions.value.insuranceId};buyCustomLicensePlate.value&&(options.licensePlateText=customLicensePlateText.value),Lua_default.career_modules_vehicleShopping.buyFromPurchaseMenu(purchaseType.value,options)}function inventoryIsEmpty(){return Lua_default.career_modules_inventory.isEmpty()}function chooseTradeInVehicle(){Lua_default.career_modules_vehicleShopping.openInventoryMenuForTradeIn()}function removeTradeInVehicle(){Lua_default.career_modules_vehicleShopping.removeTradeInVehicle()}function cancel(){Lua_default.career_modules_vehicleShopping.cancelPurchase(purchaseType.value)}function startTestDrive(){Lua_default.career_modules_inspectVehicle.startTestDrive()}function dispose$2(){listen(!1)}let listen=state=>{events$3[state?`on`:`off`](`vehiclePurchaseData`,handlePurchaseData)};return listen(!0),{buyVehicle,cancel,chooseTradeInVehicle,purchaseType,startTestDrive,dispose:dispose$2,forceNoDelivery,forceTradeIn,inventoryIsEmpty,inventoryHasFreeSlot,locationSelectionEnabled,makeDelivery,playerMoney,prices,finalPackagePrice,removeTradeInVehicle,requestPurchaseData,tradeInEnabled,tradeInVehicleInfo,vehicleInfo,buyCustomLicensePlate,customLicensePlateText,alreadyDidTestDrive,insuranceOptions}});var _hoisted_1$129={class:`header-row`},_hoisted_2$109={class:`header-seller-info`},_hoisted_3$97={class:`purchase-list`},_hoisted_4$77={class:`purchase-row`},_hoisted_5$66={class:`label`},_hoisted_6$52={class:`sub-info`},_hoisted_7$44={class:`price`},_hoisted_8$36={class:`current-price-line`},_hoisted_9$33={key:0,class:`old-price`},_hoisted_10$27={class:`sub-info`},_hoisted_11$25={key:0,class:`purchase-row thin light-blue`},_hoisted_12$20={class:`label category`},_hoisted_13$18={class:`price category`},_hoisted_14$18={class:`purchase-row thin light-blue`},_hoisted_15$18={class:`price`},_hoisted_16$18={key:1,class:`purchase-divider`},_hoisted_17$14={key:2,class:`purchase-row thin green`},_hoisted_18$12={class:`label`},_hoisted_19$9={class:`price`},_hoisted_20$8={class:`purchase-row`},_hoisted_21$8={class:`price`},_hoisted_22$7={class:`purchase-row thin yellow`},_hoisted_23$6={class:`price`},_hoisted_24$5={key:3,class:`purchase-row thin`},_hoisted_25$4={class:`price`},_hoisted_26$3={class:`purchase-row`},_hoisted_27$3={class:`price highlight-category`},_hoisted_28$2={key:4,class:`purchase-row money-warning red`},_hoisted_29$2={class:`label`},_hoisted_30$2={class:`price`},_hoisted_31$2={class:`purchase-customization-group`},_hoisted_32$2={class:`button-group`},_hoisted_33$2={key:0},_hoisted_34$2={key:1},_hoisted_35$1={key:2},_hoisted_36$1={class:`right-side`},_sfc_main$142={__name:`VehiclePurchaseMain`,setup(__props){useUINavScope(`vehiclePurchase`);let{showIfController}=storeToRefs(controls_default()),{units}=useBridge(),router$1=useRouter(),hasVehicle=ref(!1),licensePlateTextValid=ref(!0),vehiclePurchaseStore=useVehiclePurchaseStore(),store$1=useTasksStore(),tradeInButtonMessage=computed(()=>vehiclePurchaseStore.tradeInEnabled?hasVehicle.value?void 0:`You don't own any vehicles`:`Trade in only possible in person at a dealership`),testDriveButtonMessage=computed(()=>{if(vehiclePurchaseStore.purchaseType!==`inspect`)return`Test drive only available for inspect purchases`;if(vehiclePurchaseStore.alreadyDidTestDrive)return`You have already done a test drive`}),vehicleFitsInventory=computed(()=>vehiclePurchaseStore.vehicleInfo.takesNoInventorySpace?!0:vehiclePurchaseStore.inventoryHasFreeSlot||vehiclePurchaseStore.tradeInVehicleInfo.niceName&&!vehiclePurchaseStore.tradeInVehicleInfo.takesNoInventorySpace);vehiclePurchaseStore.inventoryIsEmpty().then(empty=>{hasVehicle.value=!empty});let buy=()=>buyVehicle(!vehiclePurchaseStore.locationSelectionEnabled||vehiclePurchaseStore.makeDelivery),cancel=()=>{router$1.back()},startTestDrive=()=>{vehiclePurchaseStore.startTestDrive()},chooseTradeInVehicle=()=>{vehiclePurchaseStore.chooseTradeInVehicle()},chooseInsurance=()=>{addPopup(ChooseInsuranceMain_default,{menuMode:`purchase`,params:{purchaseType:vehiclePurchaseStore.purchaseType,shopId:vehiclePurchaseStore.vehicleInfo.shopId,insuranceId:vehiclePurchaseStore.insuranceOptions.insuranceId}})},negotiatePrice=()=>{Lua_default.career_modules_marketplace.startNegotiateSellingOffer(vehiclePurchaseStore.vehicleInfo.shopId)},removeTradeInVehicle=()=>{vehiclePurchaseStore.removeTradeInVehicle()},buyVehicle=_makeDelivery=>{vehiclePurchaseStore.buyVehicle(_makeDelivery)};return onMounted(()=>{vehiclePurchaseStore.requestPurchaseData()}),onUnmounted(async()=>{await Lua_default.career_modules_inspectVehicle.onPurchaseMenuClosed(),vehiclePurchaseStore.$dispose()}),(_ctx,_cache)=>(openBlock(),createBlock(unref(layoutSingle_default),{class:`purchase-layout`},{default:withCtx(()=>[unref(vehiclePurchaseStore).vehicleInfo.niceName?withDirectives((openBlock(),createBlock(unref(bngCard_default),{key:0,"bng-ui-scope":`vehiclePurchase`,class:`purchase-screen`},{buttons:withCtx(()=>[createBaseVNode(`div`,_hoisted_32$2,[withDirectives((openBlock(),createBlock(unref(bngButton_default),{disabled:unref(vehiclePurchaseStore).purchaseType!==`inspect`||unref(vehiclePurchaseStore).alreadyDidTestDrive,onClick:startTestDrive,accent:unref(ACCENTS).secondary},{default:withCtx(()=>[..._cache[16]||=[createTextVNode(`Test Drive`,-1)]]),_:1},8,[`disabled`,`accent`])),[[unref(BngTooltip_default),testDriveButtonMessage.value,`top`]]),withDirectives((openBlock(),createBlock(unref(bngButton_default),{disabled:unref(vehiclePurchaseStore).finalPackagePrice>unref(vehiclePurchaseStore).playerMoney||!vehicleFitsInventory.value||unref(vehiclePurchaseStore).forceTradeIn&&!unref(vehiclePurchaseStore).tradeInVehicleInfo.niceName||unref(vehiclePurchaseStore).buyCustomLicensePlate&&!licensePlateTextValid.value,"show-hold":``},{default:withCtx(()=>[unref(vehiclePurchaseStore).finalPackagePrice>unref(vehiclePurchaseStore).playerMoney?(openBlock(),createElementBlock(`div`,_hoisted_33$2,`Insufficient Funds`)):vehicleFitsInventory.value?(openBlock(),createElementBlock(`div`,_hoisted_35$1,`Purchase`)):(openBlock(),createElementBlock(`div`,_hoisted_34$2,`No free inventory slots`))]),_:1},8,[`disabled`])),[[unref(BngOnUiNav_default),void 0,`ok`,{asMouse:!0,focusRequired:!0}],[unref(BngClick_default),{holdCallback:buy,holdDelay:1e3,repeatInterval:0}]])])]),default:withCtx(()=>[createBaseVNode(`div`,_hoisted_1$129,[createVNode(unref(bngCardHeading_default),{type:`ribbon`},{default:withCtx(()=>[_cache[0]||=createTextVNode(` Purchase Information `,-1),createBaseVNode(`div`,_hoisted_2$109,` Purchasing from: `+toDisplayString(unref(vehiclePurchaseStore).vehicleInfo.sellerName),1)]),_:1}),createVNode(unref(bngButton_default),{class:`close-button`,onClick:cancel,accent:unref(ACCENTS).attention,"bng-no-nav":`true`,tabindex:`-1`},{default:withCtx(()=>[createVNode(unref(bngBinding_default),{"ui-event":`menu`,controller:``}),createVNode(unref(bngIcon_default),{type:`xmarkBold`,color:`var(--bng-cool-gray-100)`})]),_:1},8,[`accent`])]),createBaseVNode(`div`,_hoisted_3$97,[createBaseVNode(`div`,_hoisted_4$77,[createBaseVNode(`div`,_hoisted_5$66,[createBaseVNode(`div`,null,toDisplayString(unref(vehiclePurchaseStore).vehicleInfo.year)+` `+toDisplayString(unref(vehiclePurchaseStore).vehicleInfo.niceName),1),createBaseVNode(`div`,_hoisted_6$52,`(`+toDisplayString(unref(units).buildString(`length`,unref(vehiclePurchaseStore).vehicleInfo.Mileage,0))+`)`,1)]),createBaseVNode(`div`,_hoisted_7$44,[createBaseVNode(`div`,_hoisted_8$36,[unref(vehiclePurchaseStore).vehicleInfo.originalSellValue?(openBlock(),createElementBlock(`span`,_hoisted_9$33,[createVNode(unref(bngUnit_default),{money:unref(vehiclePurchaseStore).vehicleInfo.originalSellValue},null,8,[`money`])])):createCommentVNode(``,!0),createVNode(unref(bngUnit_default),{class:`money`,money:unref(vehiclePurchaseStore).vehicleInfo.Value},null,8,[`money`])]),createBaseVNode(`div`,_hoisted_10$27,[createBaseVNode(`div`,null,[_cache[1]||=createTextVNode(` Est. Market: `,-1),createVNode(unref(bngUnit_default),{class:`money`,money:unref(vehiclePurchaseStore).vehicleInfo.marketValue},null,8,[`money`])])])])]),_cache[13]||=createBaseVNode(`div`,{class:`purchase-divider`},null,-1),unref(vehiclePurchaseStore).insuranceOptions.insuranceId>0?(openBlock(),createElementBlock(`div`,_hoisted_11$25,[createBaseVNode(`div`,_hoisted_12$20,toDisplayString(unref(vehiclePurchaseStore).insuranceOptions.spendingReason),1),createBaseVNode(`div`,_hoisted_13$18,[createVNode(unref(bngUnit_default),{class:`money`,money:unref(vehiclePurchaseStore).insuranceOptions.priceMoney},null,8,[`money`])])])):createCommentVNode(``,!0),createBaseVNode(`div`,_hoisted_14$18,[_cache[2]||=createBaseVNode(`div`,{class:`label`},`Dealership Fees`,-1),createBaseVNode(`div`,_hoisted_15$18,[createVNode(unref(bngUnit_default),{class:`money`,money:unref(vehiclePurchaseStore).vehicleInfo.fees},null,8,[`money`])])]),unref(vehiclePurchaseStore).tradeInVehicleInfo?.niceName?(openBlock(),createElementBlock(`div`,_hoisted_16$18)):createCommentVNode(``,!0),unref(vehiclePurchaseStore).tradeInVehicleInfo.niceName?(openBlock(),createElementBlock(`div`,_hoisted_17$14,[createBaseVNode(`div`,_hoisted_18$12,`Trade-in: `+toDisplayString(unref(vehiclePurchaseStore).tradeInVehicleInfo.niceName),1),createBaseVNode(`div`,_hoisted_19$9,[createVNode(unref(bngUnit_default),{class:`money`,money:-unref(vehiclePurchaseStore).tradeInVehicleInfo.Value},null,8,[`money`])])])):createCommentVNode(``,!0),_cache[14]||=createBaseVNode(`div`,{class:`purchase-divider`},null,-1),createBaseVNode(`div`,_hoisted_20$8,[_cache[3]||=createBaseVNode(`div`,{class:`label`},`Subtotal`,-1),createBaseVNode(`div`,_hoisted_21$8,[createVNode(unref(bngUnit_default),{class:`money`,money:unref(vehiclePurchaseStore).finalPackagePrice-unref(vehiclePurchaseStore).prices.taxes-(unref(vehiclePurchaseStore).buyCustomLicensePlate?unref(vehiclePurchaseStore).prices.customLicensePlate:0)},null,8,[`money`])])]),createBaseVNode(`div`,_hoisted_22$7,[_cache[4]||=createBaseVNode(`div`,{class:`label`},`Sales Tax (7%)`,-1),createBaseVNode(`div`,_hoisted_23$6,[createVNode(unref(bngUnit_default),{class:`money`,money:unref(vehiclePurchaseStore).prices.taxes},null,8,[`money`])])]),unref(vehiclePurchaseStore).buyCustomLicensePlate?(openBlock(),createElementBlock(`div`,_hoisted_24$5,[_cache[5]||=createBaseVNode(`div`,{class:`label`},`Custom License Plate`,-1),createBaseVNode(`div`,_hoisted_25$4,[createVNode(unref(bngUnit_default),{class:`money`,money:unref(vehiclePurchaseStore).prices.customLicensePlate},null,8,[`money`])])])):createCommentVNode(``,!0),_cache[15]||=createBaseVNode(`div`,{class:`purchase-divider`},null,-1),createBaseVNode(`div`,_hoisted_26$3,[_cache[6]||=createBaseVNode(`div`,{class:`label highlight-category`},`Total`,-1),createBaseVNode(`div`,_hoisted_27$3,[createVNode(unref(bngUnit_default),{class:`money`,money:unref(vehiclePurchaseStore).finalPackagePrice},null,8,[`money`])])]),unref(vehiclePurchaseStore).finalPackagePrice>unref(vehiclePurchaseStore).playerMoney?(openBlock(),createElementBlock(`div`,_hoisted_28$2,[createBaseVNode(`div`,_hoisted_29$2,[createVNode(unref(bngIcon_default),{type:`danger`}),_cache[7]||=createTextVNode(` Additional funds required`,-1)]),createBaseVNode(`div`,_hoisted_30$2,[createVNode(unref(bngUnit_default),{class:`money`,money:unref(vehiclePurchaseStore).finalPackagePrice-unref(vehiclePurchaseStore).playerMoney},null,8,[`money`])])])):createCommentVNode(``,!0),createBaseVNode(`div`,_hoisted_31$2,[_cache[12]||=createBaseVNode(`h4`,null,`Purchase Options`,-1),createVNode(unref(bngButton_default),{disabled:!unref(vehiclePurchaseStore).vehicleInfo.negotiationPossible,accent:`secondary`,onClick:negotiatePrice},{default:withCtx(()=>[..._cache[8]||=[createTextVNode(` Negotiate Price `,-1)]]),_:1},8,[`disabled`]),withDirectives((openBlock(),createBlock(unref(bngButton_default),{disabled:!unref(vehiclePurchaseStore).tradeInEnabled||!hasVehicle.value,accent:`secondary`,onClick:chooseTradeInVehicle},{default:withCtx(()=>[..._cache[9]||=[createTextVNode(`Choose Trade-In`,-1)]]),_:1},8,[`disabled`])),[[unref(BngTooltip_default),tradeInButtonMessage.value,`top`]]),unref(vehiclePurchaseStore).tradeInEnabled&&unref(vehiclePurchaseStore).tradeInVehicleInfo.niceName?(openBlock(),createBlock(unref(bngButton_default),{key:0,onClick:removeTradeInVehicle,accent:unref(ACCENTS).attention},{default:withCtx(()=>[..._cache[10]||=[createTextVNode(`Remove Trade-In`,-1)]]),_:1},8,[`accent`])):createCommentVNode(``,!0),createVNode(unref(bngButton_default),{onClick:chooseInsurance,accent:unref(ACCENTS).secondary},{default:withCtx(()=>[..._cache[11]||=[createTextVNode(`Choose Insurance`,-1)]]),_:1},8,[`accent`])])])]),_:1})),[[unref(BngBlur_default),1]]):createCommentVNode(``,!0),createBaseVNode(`div`,_hoisted_36$1,[createVNode(unref(bngCard_default),{class:`status-container`},{default:withCtx(()=>[createVNode(unref(careerStatus_default),{class:`profile-status`})]),_:1}),createVNode(TaskList_default,{class:`task-list`,header:unref(store$1).header,tasks:unref(store$1).tasks},null,8,[`header`,`tasks`])])]),_:1}))}},VehiclePurchaseMain_default=__plugin_vue_export_helper_default(_sfc_main$142,[[`__scopeId`,`data-v-b2028538`]]);const useVehicleShoppingStore=defineStore(`vehicleShopping`,()=>{let selectedSellerId=ref(``),currentSeller=ref({}),vehicleShoppingData=ref({}),filteredVehicles=ref([]),filteredSoldVehicles=ref([]),buildFilteredListByKey=(data,key)=>{if(!data||!data[key])return[];let filteredList=Object.keys(data[key]).reduce((result,itemKey)=>{let item=data[key][itemKey];return selectedSellerId.value?item.sellerId===selectedSellerId.value&&result.push(item):result.push(item),result},[]);return filteredList.length&&filteredList.sort((a$1,b)=>a$1.Value-b.Value),filteredList},updateListsFromData=()=>{filteredVehicles.value=buildFilteredListByKey(vehicleShoppingData.value,`vehiclesInShop`),filteredSoldVehicles.value=buildFilteredListByKey(vehicleShoppingData.value,`soldVehicles`)};return{vehicleShoppingData,filteredVehicles,filteredSoldVehicles,currentSeller,requestVehicleShoppingData:async()=>{vehicleShoppingData.value=await Lua_default.career_modules_vehicleShopping.getShoppingData(),updateListsFromData()},setSelectedSellerId:sellerId=>{selectedSellerId.value=sellerId,updateListsFromData(),currentSeller.value=vehicleShoppingData.value.uiDealershipsData.find(dealership=>dealership.id===sellerId)}}});var _hoisted_1$128={class:`cover-container`},_hoisted_2$108={key:0,class:`sold-overlay`},_hoisted_3$96={class:`car-details`},_hoisted_4$76={class:`car-value`},_hoisted_5$65={class:`name`},_hoisted_6$51={class:`brand`},_hoisted_7$43={class:`main-data`},_hoisted_8$35={key:0,class:`price`},_hoisted_9$32={class:`was`},_hoisted_10$26={class:`sold`},_hoisted_11$24={key:0,class:`market`},_hoisted_12$19={key:1,class:`price`},_hoisted_13$17={key:0},_hoisted_14$17={key:1,style:{color:`rgb(245, 29, 29)`}},_hoisted_15$17={key:2,class:`market`},_hoisted_16$17={class:`car-data`},_hoisted_17$13={style:{width:`100%`}},_hoisted_18$11={key:0,style:{flex:`1 0 auto`,"justify-content":`flex-end`,padding:`0.5em 0.75em`,"font-weight":`400`,"font-family":`var(--fnt-defs)`}},DRIVE_TRAIN_ICONS={AWD:icons.AWD,"4WD":icons[`4WD`],FWD:icons.FWD,RWD:icons.RWD,drivetrain_special:icons.drivetrainSpecial,drivetrain_generic:icons.drivetrainGeneric,defaultMissing:icons.drivetrainGeneric,defaultUnknown:icons.drivetrainGeneric},FUEL_TYPE_ICONS={Battery:icons.charge,Gasoline:icons.fuelPump,Diesel:icons.fuelPump,defaultMissing:icons.fuelPump,defaultUnknown:icons.fuelPump},TRANSMISSION_ICONS={Automatic:icons.transmissionA,Manual:icons.transmissionM,defaultMissing:icons.transmissionM,defaultUnknown:icons.transmissionM},_sfc_main$141={__name:`VehicleCard`,props:{vehicleShoppingData:Object,vehicle:Object},setup(__props){let{units}=useBridge(),props=__props,soldPercent=computed(()=>{let asking=props.vehicle?.Value,sold=props.vehicle?.soldFor;return!asking||!sold?0:(sold-asking)/asking*100}),soldDeltaPrefix=computed(()=>soldPercent.value>=0?`+`:``),soldDeltaClass=computed(()=>soldPercent.value>0?`up`:soldPercent.value<0?`down`:`flat`),confirmTaxi=async vehicle=>{await openConfirmation(``,`Do you want to taxi to this vehicle for ${units.beamBucks(vehicle.quickTravelPrice)}?`,[{label:$translate.instant(`ui.common.yes`),value:!0,extras:{default:!0}},{label:$translate.instant(`ui.common.no`),value:!1,extras:{accent:ACCENTS.secondary}}])&&quickTravelToVehicle(vehicle)},showVehicle=shopId=>{Lua_default.career_modules_vehicleShopping.showVehicle(shopId)},quickTravelToVehicle=vehicle=>{Lua_default.career_modules_vehicleShopping.quickTravelToVehicle(vehicle.shopId)},openPurchaseMenu=(purchaseType,shopId)=>{Lua_default.career_modules_vehicleShopping.openPurchaseMenu(purchaseType,shopId)},getAttributeIcon=(vehicle,attribute)=>{let iconDict;return attribute==`Drivetrain`?iconDict=DRIVE_TRAIN_ICONS:attribute==`Fuel Type`?iconDict=FUEL_TYPE_ICONS:attribute==`Transmission`&&(iconDict=TRANSMISSION_ICONS),vehicle[attribute]?iconDict[vehicle[attribute]]||iconDict.defaultUnknown:iconDict.defaultMissing};return(_ctx,_cache)=>(openBlock(),createBlock(unref(bngCard_default),{class:normalizeClass(`vehicle-card row`)},{buttons:withCtx(()=>[createBaseVNode(`div`,_hoisted_17$13,[__props.vehicleShoppingData.currentSeller?createCommentVNode(``,!0):(openBlock(),createBlock(unref(bngPropVal_default),{key:0,style:{float:`left`},keyLabel:`Seller:`,valueLabel:__props.vehicle.sellerName},null,8,[`valueLabel`])),__props.vehicleShoppingData.currentSeller?createCommentVNode(``,!0):(openBlock(),createBlock(unref(bngPropVal_default),{key:1,style:{float:`left`},keyLabel:`Distance:`,valueLabel:unref(units).buildString(`length`,__props.vehicle.distance,1)},null,8,[`valueLabel`])),createVNode(unref(bngPropVal_default),{style:{float:`left`},keyLabel:`Insurance Class:`,valueLabel:__props.vehicle.insuranceClass?.name??`Unknown`},null,8,[`valueLabel`])]),__props.vehicleShoppingData.disableShopping?(openBlock(),createElementBlock(`span`,_hoisted_18$11,toDisplayString(__props.vehicleShoppingData.disableShoppingReason),1)):createCommentVNode(``,!0),__props.vehicle.sellerId===__props.vehicleShoppingData.currentSeller?(openBlock(),createBlock(unref(bngButton_default),{key:1,onClick:_cache[0]||=$event=>showVehicle(__props.vehicle.shopId),accent:unref(ACCENTS).secondary,disabled:__props.vehicleShoppingData.disableShopping||!!__props.vehicle.soldViewCounter},{default:withCtx(()=>[..._cache[10]||=[createTextVNode(`Inspect Vehicle`,-1)]]),_:1},8,[`accent`,`disabled`])):(openBlock(),createBlock(unref(bngButton_default),{key:2,onClick:_cache[1]||=$event=>showVehicle(__props.vehicle.shopId),accent:unref(ACCENTS).secondary,disabled:__props.vehicleShoppingData.disableShopping||!!__props.vehicle.soldViewCounter},{default:withCtx(()=>[..._cache[11]||=[createTextVNode(`Set Route`,-1)]]),_:1},8,[`accent`,`disabled`])),__props.vehicleShoppingData.currentSeller?createCommentVNode(``,!0):(openBlock(),createBlock(unref(bngButton_default),{key:3,disabled:__props.vehicleShoppingData.playerAttributes.money.value<__props.vehicle.quickTravelPrice||__props.vehicleShoppingData.disableShopping||!!__props.vehicle.soldViewCounter,onClick:_cache[2]||=$event=>confirmTaxi(__props.vehicle),accent:__props.vehicle.sellerId===`private`?unref(ACCENTS).main:unref(ACCENTS).secondary},{default:withCtx(()=>[..._cache[12]||=[createBaseVNode(`span`,{style:{flex:`1 0 auto`}},`Take Taxi`,-1)]]),_:1},8,[`disabled`,`accent`])),__props.vehicle.sellerId===`private`?createCommentVNode(``,!0):(openBlock(),createBlock(unref(bngButton_default),{key:4,disabled:__props.vehicleShoppingData.tutorialPurchase||__props.vehicleShoppingData.disableShopping||!!__props.vehicle.soldViewCounter,onClick:_cache[3]||=$event=>openPurchaseMenu(`instant`,__props.vehicle.shopId)},{default:withCtx(()=>[..._cache[13]||=[createTextVNode(`Purchase`,-1)]]),_:1},8,[`disabled`]))]),default:withCtx(()=>[createBaseVNode(`div`,_hoisted_1$128,[createVNode(unref(aspectRatio_default),{class:`cover`,ratio:`16:9`,"external-image":__props.vehicle.preview},null,8,[`external-image`]),__props.vehicle.soldViewCounter>0?(openBlock(),createElementBlock(`div`,_hoisted_2$108,`SOLD`)):createCommentVNode(``,!0)]),createBaseVNode(`div`,_hoisted_3$96,[createBaseVNode(`div`,_hoisted_4$76,[createBaseVNode(`div`,{class:normalizeClass([`car-name`,{sold:__props.vehicle.soldViewCounter>0}])},[createBaseVNode(`h3`,_hoisted_5$65,toDisplayString(__props.vehicle.year)+` `+toDisplayString(__props.vehicle.Name)+` `+toDisplayString(__props.vehicle.soldViewCounter>0?` (Sold)`:``),1),createBaseVNode(`div`,_hoisted_6$51,toDisplayString(__props.vehicle.Brand),1)],2),createBaseVNode(`div`,_hoisted_7$43,[createVNode(unref(bngPropVal_default),{class:`prop-small`,iconColor:`var(--bng-cool-gray-300)`,iconType:unref(icons).bus,valueLabel:unref(units).buildString(`length`,__props.vehicle.Mileage,0)},null,8,[`iconType`,`valueLabel`]),createVNode(unref(bngPropVal_default),{class:`prop-small`,style:{flex:`1 0 auto`},iconColor:`var(--bng-cool-gray-300)`,iconType:unref(icons).bus,valueLabel:__props.vehicle.Drivetrain},null,8,[`iconType`,`valueLabel`]),__props.vehicle.soldFor?(openBlock(),createElementBlock(`div`,_hoisted_8$35,[createBaseVNode(`div`,_hoisted_9$32,[_cache[4]||=createTextVNode(`Was: `,-1),createVNode(unref(bngUnit_default),{money:__props.vehicle.Value},null,8,[`money`])]),createBaseVNode(`div`,_hoisted_10$26,[_cache[5]||=createTextVNode(`Sold for: `,-1),createVNode(unref(bngUnit_default),{class:`car-price`,money:__props.vehicle.soldFor},null,8,[`money`])]),createBaseVNode(`div`,{class:normalizeClass([`delta`,soldDeltaClass.value])},toDisplayString(soldDeltaPrefix.value)+toDisplayString(soldPercent.value.toFixed(1))+`% from asking`,3),__props.vehicle.marketValue?(openBlock(),createElementBlock(`div`,_hoisted_11$24,[_cache[6]||=createTextVNode(`Market: `,-1),createVNode(unref(bngUnit_default),{money:__props.vehicle.marketValue},null,8,[`money`])])):createCommentVNode(``,!0)])):(openBlock(),createElementBlock(`div`,_hoisted_12$19,[__props.vehicle.Value<=__props.vehicleShoppingData.playerAttributes.money.value?(openBlock(),createElementBlock(`div`,_hoisted_13$17,[createVNode(unref(bngUnit_default),{class:`car-price`,money:__props.vehicle.Value},null,8,[`money`]),_cache[7]||=createTextVNode(`*`,-1)])):(openBlock(),createElementBlock(`div`,_hoisted_14$17,[createVNode(unref(bngUnit_default),{class:`car-price`,money:__props.vehicle.Value},null,8,[`money`]),_cache[8]||=createTextVNode(`* Insufficient Funds`,-1)])),__props.vehicle.marketValue?(openBlock(),createElementBlock(`div`,_hoisted_15$17,[_cache[9]||=createTextVNode(`Market: `,-1),createVNode(unref(bngUnit_default),{money:__props.vehicle.marketValue},null,8,[`money`])])):createCommentVNode(``,!0)]))])]),createBaseVNode(`div`,_hoisted_16$17,[__props.vehicle.Power==null?createCommentVNode(``,!0):(openBlock(),createBlock(unref(bngPropVal_default),{key:0,iconType:unref(icons).powerGauge04,keyLabel:`Power:`,valueLabel:unref(units).buildString(`power`,__props.vehicle.Power,0)},null,8,[`iconType`,`valueLabel`])),__props.vehicle.Mileage==null?createCommentVNode(``,!0):(openBlock(),createBlock(unref(bngPropVal_default),{key:1,iconType:unref(icons).odometer,keyLabel:`Mileage:`,valueLabel:unref(units).buildString(`length`,__props.vehicle.Mileage,0)},null,8,[`iconType`,`valueLabel`])),__props.vehicle.Transmission==null?createCommentVNode(``,!0):(openBlock(),createBlock(unref(bngPropVal_default),{key:2,iconType:getAttributeIcon(__props.vehicle,`Transmission`),keyLabel:`Transmission:`,valueLabel:__props.vehicle.Transmission},null,8,[`iconType`,`valueLabel`])),__props.vehicle[`Fuel Type`]==null?createCommentVNode(``,!0):(openBlock(),createBlock(unref(bngPropVal_default),{key:3,iconType:getAttributeIcon(__props.vehicle,`Fuel Type`),keyLabel:`Fuel type:`,valueLabel:__props.vehicle[`Fuel Type`]},null,8,[`iconType`,`valueLabel`])),__props.vehicle.Drivetrain==null?createCommentVNode(``,!0):(openBlock(),createBlock(unref(bngPropVal_default),{key:4,iconType:getAttributeIcon(__props.vehicle,`Drivetrain`),keyLabel:`Drivetrain:`,valueLabel:__props.vehicle.Drivetrain},null,8,[`iconType`,`valueLabel`])),__props.vehicle.Weight==null?createCommentVNode(``,!0):(openBlock(),createBlock(unref(bngPropVal_default),{key:5,iconType:unref(icons).weight,keyLabel:`Weight:`,valueLabel:unref(units).buildString(`weight`,__props.vehicle.Weight,0)},null,8,[`iconType`,`valueLabel`]))])])]),_:1}))}},VehicleCard_default=__plugin_vue_export_helper_default(_sfc_main$141,[[`__scopeId`,`data-v-dea06661`]]),_hoisted_1$127={class:`site-body`,"bng-nav-scroll":``,"bng-nav-scroll-force":``},_hoisted_2$107={class:`heading`},_hoisted_3$95={class:`header-text`},_hoisted_4$75={key:0,class:`vehicle-list`},_hoisted_5$64={key:1,class:`vehicle-list sold-list`},_hoisted_6$50={class:`list-section-title`},_sfc_main$140={__name:`VehicleList`,setup(__props){useUINavScope(`vehicleList`);let vehicleShoppingStore=useVehicleShoppingStore(),getHeaderText=()=>vehicleShoppingStore?.currentSeller?.name||`BeamCar24`;return reactive([{name:`switch`,selected:!0,class:``},{name:`me`,selected:!1,class:``},{name:`please`,selected:!1,class:``}]),(_ctx,_cache)=>withDirectives((openBlock(),createBlock(unref(bngCard_default),{class:`vehicle-shop-wrapper`,"bng-ui-scope":`vehicleList`},{default:withCtx(()=>[createBaseVNode(`div`,_hoisted_1$127,[createBaseVNode(`div`,_hoisted_2$107,[createBaseVNode(`span`,_hoisted_3$95,toDisplayString(getHeaderText()),1),_cache[0]||=createBaseVNode(`span`,{class:`price-notice`},[createBaseVNode(`span`,null,`*\xA0`),createBaseVNode(`span`,null,`Additional taxes and fees are applicable`)],-1)]),unref(vehicleShoppingStore)?(openBlock(),createElementBlock(`div`,_hoisted_4$75,[(openBlock(!0),createElementBlock(Fragment,null,renderList(unref(vehicleShoppingStore).filteredVehicles,(vehicle,key)=>(openBlock(),createBlock(VehicleCard_default,{key,vehicleShoppingData:unref(vehicleShoppingStore).vehicleShoppingData,vehicle},null,8,[`vehicleShoppingData`,`vehicle`]))),128))])):createCommentVNode(``,!0),unref(vehicleShoppingStore)&&unref(vehicleShoppingStore).filteredSoldVehicles&&unref(vehicleShoppingStore).filteredSoldVehicles.length>0?(openBlock(),createElementBlock(`div`,_hoisted_5$64,[createBaseVNode(`div`,_hoisted_6$50,`Recently Sold Vehicles You Viewed (`+toDisplayString(unref(vehicleShoppingStore).filteredSoldVehicles.length)+`)`,1),(openBlock(!0),createElementBlock(Fragment,null,renderList(unref(vehicleShoppingStore).filteredSoldVehicles,(vehicle,key)=>(openBlock(),createBlock(VehicleCard_default,{key,vehicleShoppingData:unref(vehicleShoppingStore).vehicleShoppingData,vehicle},null,8,[`vehicleShoppingData`,`vehicle`]))),128))])):createCommentVNode(``,!0)])]),_:1})),[[unref(BngBlur_default)]])}},VehicleList_default=__plugin_vue_export_helper_default(_sfc_main$140,[[`__scopeId`,`data-v-5045aa89`]]),_hoisted_1$126={class:`veh-part-caption`},_hoisted_2$106={class:`veh-name`},_hoisted_3$94={class:`veh-name-count`},_hoisted_4$74={class:`veh-price`},_hoisted_5$63={class:`veh-remove`},_hoisted_6$49={key:0,class:`offer-card red`},_hoisted_7$42=[`onMouseover`,`onMouseleave`,`onActivate`,`onDeactivate`],_hoisted_8$34={class:`offer-info`},_hoisted_9$31={class:`offer-header`},_hoisted_10$25={class:`buyer-name`},_hoisted_11$23={key:0,class:`expired-badge`},_hoisted_12$18={class:`offer-details`},_hoisted_13$16={class:`detail-row`},_hoisted_14$16={class:`detail-row`},_hoisted_15$16={class:`spec-actions`},_hoisted_16$16={key:1,class:`offer-card`},_sfc_main$139={__name:`VehicleMarketplace`,setup(__props){useComputerStore();let listings=ref([]),confirmRemoveListingScreen=async listingId=>{await openConfirmation(``,`Do you want to remove this listing?`,[{label:$translate.instant(`ui.common.yes`),value:!0,extras:{default:!0}},{label:$translate.instant(`ui.common.no`),value:!1,extras:{accent:ACCENTS.secondary}}])&&removeVehicleListing(listingId)},onActivated$1=offer=>{offer.active=!0},onDeactivated$1=offer=>{offer.active=!1},onOfferHovered=offer=>{offer.hovered=!0},onOfferUnhovered=offer=>{offer.hovered=!1},handleListings=data=>{listings.value=data},getNewData=()=>{Lua_default.career_modules_marketplace.getListings().then(handleListings)},acceptOffer=(inventoryId,offerIndex)=>{Lua_default.career_modules_marketplace.acceptOffer(inventoryId,offerIndex+1).then(getNewData)},declineOffer=(inventoryId,offerIndex)=>{Lua_default.career_modules_marketplace.declineOffer(inventoryId,offerIndex+1).then(getNewData)},startNegotiateBuyingOffer=(inventoryId,offerIndex)=>{Lua_default.career_modules_marketplace.startNegotiateBuyingOffer(inventoryId,offerIndex+1).then(getNewData)},removeVehicleListing=inventoryId=>{Lua_default.career_modules_marketplace.removeVehicleListing(inventoryId).then(getNewData)},listVehicle=()=>{Lua_default.career_modules_inventory.openInventoryMenuForChoosingListing()};return onMounted(()=>{Lua_default.career_modules_marketplace.menuOpened(!0),getNewData()}),onUnmounted(()=>{Lua_default.career_modules_marketplace.menuOpened(!1)}),(_ctx,_cache)=>(openBlock(),createElementBlock(Fragment,null,[createVNode(unref(accordion_default),{class:`part-groups`,items:listings.value},{default:withCtx(()=>[(openBlock(!0),createElementBlock(Fragment,null,renderList(listings.value,listing=>(openBlock(),createBlock(unref(accordionItem_default),{key:listing.id,expanded:!0,class:normalizeClass([`marketplace-listing`,{disabled:listing.disabled}])},{caption:withCtx(()=>[createBaseVNode(`div`,_hoisted_1$126,[listing.thumbnail?(openBlock(),createElementBlock(`div`,{key:0,class:`veh-preview`,style:normalizeStyle({backgroundImage:`url('${listing.thumbnail}')`})},null,4)):createCommentVNode(``,!0),createBaseVNode(`span`,_hoisted_2$106,[createTextVNode(toDisplayString(listing.niceName)+` `,1),createBaseVNode(`span`,_hoisted_3$94,`(`+toDisplayString(listing.offers.length||0)+`)`,1)]),createBaseVNode(`span`,_hoisted_4$74,[createBaseVNode(`div`,null,[_cache[0]||=createTextVNode(` Asking Price: `,-1),createVNode(unref(bngUnit_default),{money:listing.value},null,8,[`money`])]),createBaseVNode(`div`,null,[_cache[1]||=createTextVNode(` Estimated Market Value: `,-1),createVNode(unref(bngUnit_default),{money:listing.marketValue},null,8,[`money`])])]),createBaseVNode(`span`,_hoisted_5$63,[createVNode(unref(bngButton_default),{onClick:withModifiers($event=>confirmRemoveListingScreen(listing.id),[`stop`]),icon:unref(icons).trashBin1,accent:unref(ACCENTS).attentionghost},null,8,[`onClick`,`icon`,`accent`])])])]),default:withCtx(()=>[listing.disabled?(openBlock(),createElementBlock(`div`,_hoisted_6$49,toDisplayString(listing.disableReason),1)):createCommentVNode(``,!0),(openBlock(!0),createElementBlock(Fragment,null,renderList(listing.offers,(offer,index)=>withDirectives((openBlock(),createElementBlock(`div`,{class:normalizeClass([`offer-card`,{expired:offer.expiredViewCounter==1}]),onMouseover:$event=>onOfferHovered(offer),onMouseleave:$event=>onOfferUnhovered(offer),onActivate:$event=>onActivated$1(offer),onDeactivate:$event=>onDeactivated$1(offer)},[createBaseVNode(`div`,_hoisted_8$34,[createBaseVNode(`div`,_hoisted_9$31,[createBaseVNode(`span`,_hoisted_10$25,toDisplayString(offer.buyerPersonality.name),1),offer.expiredViewCounter?(openBlock(),createElementBlock(`span`,_hoisted_11$23,`EXPIRED`)):createCommentVNode(``,!0)]),createBaseVNode(`div`,_hoisted_12$18,[createBaseVNode(`div`,_hoisted_13$16,[_cache[3]||=createBaseVNode(`span`,{class:`detail-label`},`Offer:`,-1),createVNode(unref(bngUnit_default),{money:offer.value},null,8,[`money`]),createBaseVNode(`span`,{class:normalizeClass([`delta`,{up:offer.value>listing.value,down:offer.valuelisting.value?`+`:`-`),1),createVNode(unref(bngUnit_default),{money:Math.abs(offer.value-listing.value)},null,8,[`money`]),_cache[2]||=createTextVNode(`) `,-1)],2)]),createBaseVNode(`div`,_hoisted_14$16,[_cache[4]||=createBaseVNode(`span`,{class:`detail-label`},`Vehicle:`,-1),createBaseVNode(`span`,null,toDisplayString(listing.niceName),1)])])]),createBaseVNode(`div`,_hoisted_15$16,[createVNode(unref(bngButton_default),{class:`part-button`,onClick:$event=>declineOffer(listing.id,index),accent:unref(ACCENTS).attention},{default:withCtx(()=>[createTextVNode(toDisplayString(offer.expiredViewCounter?`Discard`:`Deny`),1)]),_:2},1032,[`onClick`,`accent`]),offer.expiredViewCounter?createCommentVNode(``,!0):(openBlock(),createBlock(unref(bngButton_default),{key:0,class:`part-button negotiate-button`,onClick:$event=>startNegotiateBuyingOffer(listing.id,index),accent:unref(ACCENTS).secondary,disabled:!offer.negotiationPossible||offer.value>=listing.value||listing.disabled},{default:withCtx(()=>[..._cache[5]||=[createTextVNode(` Negotiate `,-1)]]),_:1},8,[`onClick`,`accent`,`disabled`])),offer.expiredViewCounter?createCommentVNode(``,!0):(openBlock(),createBlock(unref(bngButton_default),{key:1,class:`part-button`,onClick:$event=>acceptOffer(listing.id,index),disabled:listing.disabled||offer.disabled,accent:unref(ACCENTS).main},{default:withCtx(()=>[..._cache[6]||=[createTextVNode(` Accept Offer `,-1)]]),_:1},8,[`onClick`,`disabled`,`accent`]))])],42,_hoisted_7$42)),[[unref(BngScopedNav_default)]])),256)),Object.keys(listing.offers||{}).length===0?(openBlock(),createElementBlock(`div`,_hoisted_16$16,toDisplayString(unref($translate).instant(`ui.career.vehicleMarketplace.noOffers`)),1)):createCommentVNode(``,!0)]),_:2},1032,[`class`]))),128))]),_:1},8,[`items`]),createVNode(unref(bngButton_default),{class:`add-listing-button`,onClick:listVehicle,accent:unref(ACCENTS).custom},{default:withCtx(()=>[..._cache[7]||=[createBaseVNode(`span`,{class:`add-listing-button-icon`},`+`,-1),createTextVNode(` Add Listing `,-1)]]),_:1},8,[`accent`])],64))}},VehicleMarketplace_default=__plugin_vue_export_helper_default(_sfc_main$139,[[`__scopeId`,`data-v-468e550d`]]),_hoisted_1$125={class:`flex-container`},_hoisted_2$105={class:`content`},_hoisted_3$93={key:0},_hoisted_4$73={class:`seller-grid`},_hoisted_5$62={class:`seller-card__label`},_hoisted_6$48={class:`seller-card__header`},_hoisted_7$41={class:`seller-card__title`},_hoisted_8$33={key:0,class:`seller-card__subtitle`},_hoisted_9$30={class:`seller-card__vehicle-thumbnails`},_hoisted_10$24={class:`seller-card__vehicle-thumbnail`},_hoisted_11$22={key:0,class:`more-label`},_hoisted_12$17={key:1},buyVehicleTitle=`Buy Vehicles`,sellVehicleTitle=`Sell Vehicles`,_sfc_main$138={__name:`VehicleShoppingMain`,props:{screenTag:{type:String,default:``},buyingAvailable:{type:String,default:`true`},marketplaceAvailable:{type:String,default:`true`},selectedSellerId:{type:String,default:``}},setup(__props){useUINavScope(`vehicleShopping`),useComputerStore();let vehicleShoppingStore=useVehicleShoppingStore(),selectedTab=ref(0),selectedSellerId=ref(``),router$1=useRouter(),loaded=ref(!1),selectSeller=sellerId=>{setSelectedSellerId(sellerId),updateRouteScreenTag()},tabs=computed(()=>{let tabs$1=[];return props.buyingAvailable===`true`&&tabs$1.push(buyVehicleTitle),props.marketplaceAvailable===`true`&&tabs$1.push(sellVehicleTitle),tabs$1}),props=__props,processTabInput=event=>{event.detail.name===`tab_l`?selectedTab.value=(selectedTab.value-1+tabs.value.length)%tabs.value.length:event.detail.name===`tab_r`&&(selectedTab.value=(selectedTab.value+1)%tabs.value.length)},onTabsChange=(tab,old)=>{let idx=tabs.value.indexOf(tab&&tab.heading?tab.heading:``);idx!==-1&&(selectedTab.value=idx),selectedTab.value===tabs.value.indexOf(buyVehicleTitle)&&(selectedSellerId.value=``)},headerTitle=computed(()=>{switch(tabs.value[selectedTab.value]){case buyVehicleTitle:return`Buy Vehicles`;case sellVehicleTitle:return`Sell Vehicles`;default:return`Available Vehicles`}}),updateRouteScreenTag=()=>{let screenTag=selectedTab.value===tabs.value.indexOf(sellVehicleTitle)?`marketplace`:`buying`;router$1.replace({name:`vehicleShopping`,params:{screenTag,buyingAvailable:props.buyingAvailable,marketplaceAvailable:props.marketplaceAvailable,selectedSellerId:selectedSellerId.value}})};watch(selectedTab,()=>{updateRouteScreenTag()});let setSelectedSellerId=sellerId=>{selectedSellerId.value=sellerId,vehicleShoppingStore.setSelectedSellerId(selectedSellerId.value)},dealershipVehiclesMap=computed(()=>{let map=new Map;return vehicleShoppingStore.vehicleShoppingData.vehiclesInShop&&vehicleShoppingStore.vehicleShoppingData.vehiclesInShop.filter(vehicle=>vehicle.preview).forEach(vehicle=>{map.has(vehicle.sellerId)||map.set(vehicle.sellerId,[]),map.get(vehicle.sellerId).push(vehicle)}),map}),getDealershipVehicles=dealershipId=>dealershipVehiclesMap.value.get(dealershipId)||[],start=()=>{nextTick(async()=>{await vehicleShoppingStore.requestVehicleShoppingData(),loaded.value=!0,vehicleShoppingStore.vehicleShoppingData.currentSeller?setSelectedSellerId(vehicleShoppingStore.vehicleShoppingData.currentSeller):setSelectedSellerId(props.selectedSellerId),props.screenTag==`buying`?selectedTab.value=tabs.value.indexOf(buyVehicleTitle):props.screenTag==`marketplace`?selectedTab.value=tabs.value.indexOf(sellVehicleTitle):selectedTab.value=0,updateRouteScreenTag()})},kill=async()=>{await Lua_default.career_modules_vehicleShopping.onShoppingMenuClosed(),vehicleShoppingStore.$dispose()},close=()=>{!vehicleShoppingStore.vehicleShoppingData.currentSeller&&selectedTab.value===tabs.value.indexOf(buyVehicleTitle)&&selectedSellerId.value?selectedSellerId.value=``:router$1.back()};return onMounted(start),onUnmounted(kill),(_ctx,_cache)=>withDirectives((openBlock(),createBlock(ComputerWrapper_default,{path:[unref(vehicleShoppingStore).vehicleShoppingData.currentSellerNiceName||`Vehicle Marketplace`],title:headerTitle.value,"bng-ui-scope":`vehicleShopping`,back:``,onBack:close},{status:withCtx(()=>[createTextVNode(` Free Inventory Slots: `+toDisplayString(unref(vehicleShoppingStore)?unref(vehicleShoppingStore).vehicleShoppingData.numberOfFreeSlots:0),1)]),default:withCtx(()=>[createBaseVNode(`div`,_hoisted_1$125,[withDirectives((openBlock(),createElementBlock(`div`,_hoisted_2$105,[createVNode(unref(tabs_default),{class:normalizeClass([`bng-tabs`,{"single-tab":tabs.value.length===1}]),selectedIndex:selectedTab.value,onChange:onTabsChange},{default:withCtx(()=>[createVNode(unref(tabList_default)),props.buyingAvailable===`true`?(openBlock(),createElementBlock(`div`,{key:0,"tab-heading":buyVehicleTitle,class:`buying-tab-content`},[loaded.value&&!selectedSellerId.value?(openBlock(),createBlock(unref(bngCard_default),{key:0,class:`buying-card`},{default:withCtx(()=>[unref(vehicleShoppingStore).vehicleShoppingData.uiDealershipsData&&Object.keys(unref(vehicleShoppingStore).vehicleShoppingData.uiDealershipsData).length?(openBlock(),createElementBlock(`div`,_hoisted_3$93,[createBaseVNode(`div`,_hoisted_4$73,[(openBlock(!0),createElementBlock(Fragment,null,renderList(unref(vehicleShoppingStore).vehicleShoppingData.uiDealershipsData,dealership=>(openBlock(),createBlock(unref(bngTile_default),{key:dealership.id,class:`seller-card`,style:normalizeStyle({backgroundImage:`linear-gradient(180deg, rgba(0,0,0,0.9), rgba(0,0,0,0)), url(`+(dealership.preview&&dealership.preview[0]===`/`?dealership.preview:`/`+dealership.preview)+`)`}),onClick:$event=>dealership.vehicleCount&&selectSeller(dealership.id)},{label:withCtx(()=>[createBaseVNode(`div`,_hoisted_5$62,[createBaseVNode(`div`,_hoisted_6$48,[createBaseVNode(`div`,_hoisted_7$41,[createVNode(unref(bngIcon_default),{type:dealership.icon},null,8,[`type`]),createTextVNode(toDisplayString(dealership.name),1)]),dealership.description?(openBlock(),createElementBlock(`div`,_hoisted_8$33,toDisplayString(dealership.description),1)):createCommentVNode(``,!0)]),createBaseVNode(`div`,_hoisted_9$30,[(openBlock(!0),createElementBlock(Fragment,null,renderList(getDealershipVehicles(dealership.id).slice(0,5),(vehicle,index)=>(openBlock(),createElementBlock(`div`,_hoisted_10$24,[createVNode(unref(aspectRatio_default),{ratio:`16:9`,class:`seller-card__vehicle-thumbnail-image`,"external-image":vehicle.preview},{default:withCtx(()=>[index==0&&getDealershipVehicles(dealership.id).length>5?(openBlock(),createElementBlock(`div`,_hoisted_11$22,` +`+toDisplayString(getDealershipVehicles(dealership.id).length-4),1)):createCommentVNode(``,!0)]),_:2},1032,[`external-image`])]))),256))])])]),_:2},1032,[`style`,`onClick`]))),128))])])):(openBlock(),createElementBlock(`div`,_hoisted_12$17,[..._cache[0]||=[createBaseVNode(`span`,null,`No sellers available.`,-1)]]))]),_:1})):loaded.value?(openBlock(),createBlock(VehicleList_default,{key:1})):(openBlock(),createBlock(unref(bngCard_default),{key:2},{default:withCtx(()=>[createVNode(unref(bngCardHeading_default),{style:{color:`#fff`}},{default:withCtx(()=>[..._cache[1]||=[createTextVNode(`Please wait...`,-1)]]),_:1})]),_:1}))])):createCommentVNode(``,!0),props.marketplaceAvailable===`true`?(openBlock(),createElementBlock(`div`,{key:1,"tab-heading":sellVehicleTitle,class:`marketplace-tab-content`},[createVNode(VehicleMarketplace_default)])):createCommentVNode(``,!0)]),_:1},8,[`class`,`selectedIndex`])])),[[unref(BngBlur_default),1]])])]),_:1},8,[`path`,`title`])),[[unref(BngOnUiNav_default),processTabInput,`tab_l,tab_r`]])}},VehicleShoppingMain_default=__plugin_vue_export_helper_default(_sfc_main$138,[[`__scopeId`,`data-v-83009aa9`]]),_hoisted_1$124={style:{padding:`1em`,overflow:`auto`}},_hoisted_2$104={class:`performance-class-container`},_hoisted_3$92={key:0,class:`performance-class-wrapper`},_hoisted_4$72={class:`class-badge`},_hoisted_5$61={class:`certification-container`},_hoisted_6$47={class:`specs-section`},_hoisted_7$40={key:0},_hoisted_8$32={key:1,class:`specs-grid`},_hoisted_9$29={class:`spec-row`},_hoisted_10$23={class:`spec-label`},_hoisted_11$21={class:`spec-value`},_hoisted_12$16={class:`spec-row`},_hoisted_13$15={class:`spec-value`},_hoisted_14$15={class:`spec-row`},_hoisted_15$15={class:`spec-label`},_hoisted_16$15={class:`spec-value`},_hoisted_17$12={class:`spec-row`},_hoisted_18$10={class:`spec-label`},_hoisted_19$8={class:`spec-value`},_hoisted_20$7={class:`spec-row`},_hoisted_21$7={class:`spec-label`},_hoisted_22$6={class:`spec-value`},_hoisted_23$5={class:`spec-row`},_hoisted_24$4={class:`spec-value`},_hoisted_25$3={class:`spec-row`},_hoisted_26$2={class:`spec-value`},_hoisted_27$2={class:`specs-section`},_hoisted_28$1={key:0,class:`metrics-grid`},_hoisted_29$1={key:3,class:`performance-index-container`},_hoisted_30$1={class:`progress-wrapper`},_hoisted_31$1={class:`class-markers`},_hoisted_32$1={class:`marker-label`},_hoisted_33$1={class:`history-dropdown-container`},_hoisted_34$1={class:`dropdown`},_sfc_main$137={__name:`VehiclePerformanceTile`,props:{vehicleData:Object},setup(__props){let{units}=useBridge(),props=__props;computed(()=>props.vehicleData.niceName||`No Name`);let startTestTitle=computed(()=>props.vehicleData.needsRepair?`Assess Performance (Repair Required)`:`Assess Performance Now`),startTest=function(){Lua_default.career_modules_vehiclePerformance.startDragTest(props.vehicleData.id)},getColorForValue=(value,min$1=0,max$1=1)=>{let normalizedValue=(value-min$1)/(max$1-min$1),adjustedValue=Math.max(0,normalizedValue-.1)*(1/.9),red,green;return adjustedValue<.5?(red=200,green=Math.round(200*(adjustedValue*2))):(red=Math.round(200*(2-adjustedValue*2)),green=200),`rgb(${red}, ${green}, 0)`},selectedHistoryIndex=ref(0),allCertificationData=computed(()=>[props.vehicleData.certificationData||{noPerformanceData:!0},...props.vehicleData.performanceHistory||[]]),historyOptions=computed(()=>allCertificationData.value.length?allCertificationData.value.map((item,index)=>({value:index,label:index===0?item.noPerformanceData?`Current Test Results: No data`:`Current Test Results - `+new Date(item.timeStamp).toLocaleString():`Previous Test Results - ${new Date(item.timeStamp).toLocaleString()}`})):[]),selectedCertificationData=computed(()=>allCertificationData.value[selectedHistoryIndex.value]);return watch(()=>props.vehicleData,newVal=>{},{immediate:!0}),(_ctx,_cache)=>withDirectives((openBlock(),createBlock(unref(bngCard_default),{class:`card`},{footer:withCtx(()=>[createBaseVNode(`div`,_hoisted_33$1,[createBaseVNode(`div`,_hoisted_34$1,[_cache[8]||=createBaseVNode(`div`,{class:`dropdown-label`},`Previous Assessments`,-1),createVNode(unref(bngDropdown_default),{modelValue:selectedHistoryIndex.value,"onUpdate:modelValue":_cache[0]||=$event=>selectedHistoryIndex.value=$event,items:historyOptions.value,class:`history-select`},{default:withCtx(()=>[createTextVNode(toDisplayString(historyOptions.value[selectedHistoryIndex.value].text),1)]),_:1},8,[`modelValue`,`items`])]),createVNode(unref(bngButton_default),{onClick:_cache[1]||=$event=>startTest(),disabled:__props.vehicleData.needsRepair||!__props.vehicleData.owned},{default:withCtx(()=>[createTextVNode(toDisplayString(startTestTitle.value),1)]),_:1},8,[`disabled`])])]),default:withCtx(()=>[createBaseVNode(`div`,_hoisted_1$124,[createBaseVNode(`div`,null,[createVNode(VehicleTileRow_default,{class:`vehicle-tile-row`,data:__props.vehicleData,enableHover:!1,small:!0},null,8,[`data`]),createBaseVNode(`div`,_hoisted_2$104,[selectedCertificationData.value&&selectedCertificationData.value.vehicleClass?(openBlock(),createElementBlock(`div`,_hoisted_3$92,[createBaseVNode(`span`,_hoisted_4$72,` Class `+toDisplayString(selectedCertificationData.value.vehicleClass.class.name)+` | PI `+toDisplayString(selectedCertificationData.value.vehicleClass.performanceIndex.toFixed(0)),1)])):createCommentVNode(``,!0)])]),createBaseVNode(`div`,_hoisted_5$61,[createBaseVNode(`div`,_hoisted_6$47,[_cache[5]||=createBaseVNode(`div`,{class:`section-header`},[createBaseVNode(`h2`,null,`Technical Specifications`)],-1),selectedCertificationData.value.vehicleClass?(openBlock(),createElementBlock(`div`,_hoisted_8$32,[createBaseVNode(`div`,_hoisted_9$29,[createBaseVNode(`div`,_hoisted_10$23,toDisplayString(_ctx.$t(`ui.options.units.weight`)),1),createBaseVNode(`div`,_hoisted_11$21,toDisplayString(_ctx.$game.units.buildString(`weight`,selectedCertificationData.value.weight,0)),1)]),createBaseVNode(`div`,_hoisted_12$16,[_cache[2]||=createBaseVNode(`div`,{class:`spec-label`},`Power/Weight`,-1),createBaseVNode(`div`,_hoisted_13$15,toDisplayString(selectedCertificationData.value.powerPerTon.toFixed(0))+`hp/1000kg`,1)]),createBaseVNode(`div`,_hoisted_14$15,[createBaseVNode(`div`,_hoisted_15$15,toDisplayString(_ctx.$t(`vehicle.info.Drivetrain`)),1),createBaseVNode(`div`,_hoisted_16$15,toDisplayString(selectedCertificationData.value.drivetrain),1)]),createBaseVNode(`div`,_hoisted_17$12,[createBaseVNode(`div`,_hoisted_18$10,toDisplayString(_ctx.$t(`vehicle.info.Fuel Type`)),1),createBaseVNode(`div`,_hoisted_19$8,toDisplayString(selectedCertificationData.value.fuelType),1)]),createBaseVNode(`div`,_hoisted_20$7,[createBaseVNode(`div`,_hoisted_21$7,toDisplayString(_ctx.$t(`vehicle.info.Induction Type`)),1),createBaseVNode(`div`,_hoisted_22$6,toDisplayString(selectedCertificationData.value.inductionType),1)]),createBaseVNode(`div`,_hoisted_23$5,[_cache[3]||=createBaseVNode(`div`,{class:`spec-label`},`Mileage`,-1),createBaseVNode(`div`,_hoisted_24$4,toDisplayString(unref(units).buildString(`length`,selectedCertificationData.value.mileage,0)),1)]),createBaseVNode(`div`,_hoisted_25$3,[_cache[4]||=createBaseVNode(`div`,{class:`spec-label`},`Lateral G-Force`,-1),createBaseVNode(`div`,_hoisted_26$2,toDisplayString(selectedCertificationData.value.lateralGForce.toFixed(2))+` G`,1)])])):(openBlock(),createElementBlock(`div`,_hoisted_7$40,` Vehicle has not been assessed yet. `))]),createBaseVNode(`div`,_hoisted_27$2,[_cache[7]||=createBaseVNode(`div`,{class:`section-header`},[createBaseVNode(`h2`,null,`Metrics`)],-1),selectedCertificationData.value.vehicleClass?(openBlock(),createElementBlock(`div`,_hoisted_28$1,[selectedCertificationData.value.power?(openBlock(),createBlock(unref(bngProgressBar_default),{key:0,headerLeft:`Power Output`,headerRight:_ctx.$game.units.buildString(`power`,selectedCertificationData.value.power,0),value:selectedCertificationData.value.power,min:0,max:1e3,showValueLabel:!1,valueColor:getColorForValue(selectedCertificationData.value.power,0,1e3),class:`score-progress`},null,8,[`headerRight`,`value`,`valueColor`])):createCommentVNode(``,!0),createVNode(unref(bngProgressBar_default),{headerLeft:`0-60 mph time (prepped surface)`,headerRight:selectedCertificationData.value.time_0_60?selectedCertificationData.value.time_0_60.toFixed(2)+` s`:`N/A`,value:selectedCertificationData.value.time_0_60?-selectedCertificationData.value.time_0_60:-25,min:-25,max:-2,showValueLabel:!1,valueColor:getColorForValue(selectedCertificationData.value.time_0_60?-selectedCertificationData.value.time_0_60:-25,-25,-2),class:`score-progress`},null,8,[`headerRight`,`value`,`valueColor`]),selectedCertificationData.value.time_1_4?(openBlock(),createBlock(unref(bngProgressBar_default),{key:1,headerLeft:`Quarter Mile`,headerRight:selectedCertificationData.value.time_1_4.toFixed(2)+` s @ `+_ctx.$game.units.buildString(`speed`,selectedCertificationData.value.velAt_1_4,0),value:selectedCertificationData.value.time_1_4?-selectedCertificationData.value.time_1_4:-35,min:-35,max:-8.1,showValueLabel:!1,valueColor:getColorForValue(selectedCertificationData.value.time_1_4?-selectedCertificationData.value.time_1_4:-35,-35,-8.1),class:`score-progress`},null,8,[`headerRight`,`value`,`valueColor`])):createCommentVNode(``,!0),selectedCertificationData.value.performanceAggregateScores.brakingGForceScore?(openBlock(),createBlock(unref(bngProgressBar_default),{key:2,headerLeft:`Braking Force`,headerRight:selectedCertificationData.value.brakingG?selectedCertificationData.value.brakingG.toFixed(2)+` G`:`N/A`,value:selectedCertificationData.value.brakingG||0,min:.5,max:1.9,showValueLabel:!1,valueColor:getColorForValue(selectedCertificationData.value.brakingG||0,.5,1.9),class:`score-progress`},null,8,[`headerRight`,`value`,`valueColor`])):createCommentVNode(``,!0),selectedCertificationData.value&&selectedCertificationData.value.vehicleClass?(openBlock(),createElementBlock(`div`,_hoisted_29$1,[createBaseVNode(`div`,_hoisted_30$1,[createVNode(unref(bngProgressBar_default),{headerLeft:`Performance Index`,headerRight:`Class: `+selectedCertificationData.value.vehicleClass.class.name,value:selectedCertificationData.value.vehicleClass.performanceIndex,min:0,max:110,showValueLabel:!1,valueColor:getColorForValue(selectedCertificationData.value.vehicleClass.performanceIndex/110),class:`score-progress performance-index`},null,8,[`headerRight`,`value`,`valueColor`]),createBaseVNode(`div`,_hoisted_31$1,[(openBlock(),createElementBlock(Fragment,null,renderList([{pi:101,name:`X`},{pi:86,name:`S`},{pi:66,name:`A`},{pi:41,name:`B`},{pi:21,name:`C`}],(classInfo,index)=>createBaseVNode(`div`,{key:index,class:`class-marker`,style:normalizeStyle({left:`${classInfo.pi/110*100}%`})},[_cache[6]||=createBaseVNode(`div`,{class:`marker-line`},null,-1),createBaseVNode(`div`,_hoisted_32$1,toDisplayString(classInfo.name),1)],4)),64))])])])):createCommentVNode(``,!0)])):createCommentVNode(``,!0)])])])]),_:1})),[[unref(BngBlur_default),!0]])}},VehiclePerformanceTile_default=__plugin_vue_export_helper_default(_sfc_main$137,[[`__scopeId`,`data-v-ca2efe1a`]]),_hoisted_1$123={key:0,class:`certification-test-in-progress`},_hoisted_2$103={class:`certification-content`},_hoisted_3$91={class:`certification-icon`},_hoisted_4$71={class:`cancelButton`},_hoisted_5$60={key:1},_sfc_main$136={__name:`VehiclePerformanceMain`,props:{inventoryId:String},setup(__props){let router$1=useRouter(),vehicleData=ref({}),assessmentProgressMessage=ref(`Performance Assessment in progress...`),cancellingTest=ref(!1),testInProgress=ref(!1),{$game}=useLibStore(),title=computed(()=>vehicleData.value.niceName?`Performance Index: `+vehicleData.value.niceName:`Performance Index`),props=__props;$game.events.on(`PerformanceTestMessage`,data=>{assessmentProgressMessage.value=data.message,cancellingTest.value=!0}),$game.events.on(`PerformanceTestStarted`,data=>{testInProgress.value=data.testInProgress,getVehicleData()});let close=()=>{router$1.back()},kill=()=>{$game.events.off(`PerformanceTestMessage`),$game.events.off(`PerformanceTestStarted`)},getVehicleData=()=>{Lua_default.career_modules_inventory.getVehicleUiData(Number(props.inventoryId)).then(data=>{vehicleData.value=data})},start=()=>{getVehicleData()},cancelTest=()=>{Lua_default.career_modules_vehiclePerformance.cancelTest()};return onUnmounted(kill),onMounted(start),(_ctx,_cache)=>testInProgress.value?(openBlock(),createElementBlock(`div`,_hoisted_1$123,[createVNode(unref(bngCard_default),{class:`certification-card`},{default:withCtx(()=>[createBaseVNode(`div`,_hoisted_2$103,[createBaseVNode(`div`,null,[createBaseVNode(`div`,{class:normalizeClass([`certificationTestText`,{cancelling:cancellingTest.value}])},toDisplayString(assessmentProgressMessage.value),3)]),createBaseVNode(`div`,_hoisted_3$91,[createVNode(unref(bngIcon_default),{type:unref(icons).timeUnlockOutline},null,8,[`type`])])]),createBaseVNode(`div`,_hoisted_4$71,[withDirectives((openBlock(),createBlock(unref(bngButton_default),{accent:unref(ACCENTS).RED,onClick:cancelTest,tabindex:`0`},{default:withCtx(()=>[..._cache[0]||=[createTextVNode(` Cancel Test `,-1)]]),_:1},8,[`accent`])),[[unref(BngOnUiNav_default),void 0,`back,menu`,{asMouse:!0}]])])]),_:1})])):(openBlock(),createElementBlock(`div`,_hoisted_5$60,[createVNode(ComputerWrapper_default,{ref:`wrapper`,path:[`Performance Index`],title:title.value,back:``,onBack:close},{default:withCtx(()=>[createVNode(VehiclePerformanceTile_default,{"vehicle-data":vehicleData.value},null,8,[`vehicle-data`])]),_:1},8,[`title`])]))}},VehiclePerformanceMain_default=__plugin_vue_export_helper_default(_sfc_main$136,[[`__scopeId`,`data-v-ea737c56`]]),_hoisted_1$122={class:`offer-chat-container-wrapper`},_hoisted_2$102={key:0,class:`above`},_hoisted_3$90={key:1,class:`red`},_hoisted_4$70={key:2,class:`green`},_hoisted_5$59={key:3,class:`above`},_hoisted_6$46={key:4,class:`above`},_hoisted_7$39={key:5,class:`price`},_sfc_main$135={__name:`NegotiationChat`,props:{offerHistory:{type:Array,default:()=>[]},negotiationStatus:{type:String,default:``},startingPrice:{type:Number,default:0},amISelling:{type:Boolean,default:!1}},setup(__props,{expose:__expose}){let props=__props,offerChatContainer=ref(null),statusTextFromStatus=status=>{switch(String(status||``)){case`counterOffer`:return`Counter offer`;case`counterOfferLastChance`:return`Last chance counter offer`;case`accepted`:return`Accepted`;case`failed`:return`Negotiation failed`;case`refused`:return`Offer refused`;case`initial`:return props.amISelling?`Initial offer`:`Asking Price`;case`thinking`:return`Thinking`;default:return``}},fillInOfferHistory=history$1=>{if(!history$1||!Array.isArray(history$1))return[];let hasSeenMyOffer=!1,isFirstInitialOffer=!0;return history$1.map(item=>{let isMyOffer=item.myOffer!=null,isTheirOffer=item.theirOffer!=null,currentOffer=isMyOffer?item.myOffer:item.theirOffer,difference=null;isTheirOffer&&isFirstInitialOffer?isFirstInitialOffer=!1:difference=currentOffer-props.startingPrice;let offerStatus=null;return isMyOffer&&(hasSeenMyOffer?offerStatus=`counterOffer`:(offerStatus=`initial`,hasSeenMyOffer=!0)),isMyOffer?item.myOffer:isTheirOffer&&item.theirOffer,{theirOffer:item.theirOffer,myOffer:item.myOffer,negotiationStatus:item.negotiationStatus,messageClass:isMyOffer?`sent-message`:`received-message`,difference,offerStatus}})},typingMessageId=ref(null),previousOfferHistoryLength=ref(0);watch(()=>props.negotiationStatus,newStatus=>{newStatus===`typing`&&typingMessageId.value===null&&(typingMessageId.value=`typing-${Date.now()}`)});let processedOfferHistory=computed(()=>{let history$1=fillInOfferHistory(props.offerHistory),currentHistoryLength=(props.offerHistory||[]).length;if(currentHistoryLength>previousOfferHistoryLength.value&&typingMessageId.value!==null){let responseId=typingMessageId.value,responseData=history$1[history$1.length-1],result=[...history$1];return result[result.length-1]={...responseData,typingId:responseId,isTyping:!1},typingMessageId.value=null,previousOfferHistoryLength.value=currentHistoryLength,result}return currentHistoryLength!==previousOfferHistoryLength.value&&(previousOfferHistoryLength.value=currentHistoryLength),props.negotiationStatus===`typing`&&typingMessageId.value!==null?[...history$1,{theirOffer:null,myOffer:null,negotiationStatus:`typing`,messageClass:`received-message`,difference:null,isTyping:!0,typingId:typingMessageId.value}]:history$1});watch(processedOfferHistory,()=>{nextTick(()=>{if(offerChatContainer.value){let container=offerChatContainer.value;container.scrollHeight-container.scrollTop-container.clientHeight<100&&(container.scrollTop=container.scrollHeight)}})},{deep:!0});let scrollToBottom=()=>{nextTick(()=>{offerChatContainer.value&&(offerChatContainer.value.scrollTop=offerChatContainer.value.scrollHeight)})},reset$1=()=>{typingMessageId.value=null,previousOfferHistoryLength.value=(props.offerHistory||[]).length};return onMounted(()=>{reset$1(),scrollToBottom()}),__expose({scrollToBottom,reset:reset$1}),(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$122,[createBaseVNode(`div`,{ref_key:`offerChatContainer`,ref:offerChatContainer,class:`offer-chat-container`},[createVNode(TransitionGroup,{name:`message`,tag:`div`},{default:withCtx(()=>[(openBlock(!0),createElementBlock(Fragment,null,renderList(processedOfferHistory.value,(item,index)=>(openBlock(),createElementBlock(`div`,{key:item.typingId||`${item.myOffer||item.theirOffer||`message`}-${index}`,class:normalizeClass([`message`,item.messageClass])},[item.isTyping?(openBlock(),createElementBlock(`div`,_hoisted_2$102,[..._cache[0]||=[createBaseVNode(`span`,{class:`spinner`,"aria-label":`Typing`},null,-1),createTextVNode(` Typing... `,-1)]])):item.negotiationStatus===`failed`?(openBlock(),createElementBlock(`div`,_hoisted_3$90,[createVNode(unref(bngIcon_default),{type:`abandon`}),_cache[1]||=createTextVNode(` Negotiation failed! `,-1)])):item.negotiationStatus===`accepted`?(openBlock(),createElementBlock(`div`,_hoisted_4$70,[createVNode(unref(bngIcon_default),{type:`checkmark`,color:`var(--bng-add-green-400)`}),_cache[2]||=createTextVNode(` Accepted! `,-1)])):item.offerStatus?(openBlock(),createElementBlock(`div`,_hoisted_5$59,[item.offerStatus===`initial`?(openBlock(),createElementBlock(Fragment,{key:0},[createTextVNode(toDisplayString(props.amISelling?`Asking Price`:`Initial offer`),1)],64)):(openBlock(),createElementBlock(Fragment,{key:1},[createTextVNode(` Counter offer `)],64))])):item.negotiationStatus?(openBlock(),createElementBlock(`div`,_hoisted_6$46,toDisplayString(statusTextFromStatus(item.negotiationStatus)),1)):createCommentVNode(``,!0),!item.isTyping&&item.negotiationStatus!==`failed`&&item.negotiationStatus!==`accepted`?(openBlock(),createElementBlock(`div`,_hoisted_7$39,[createVNode(unref(bngUnit_default),{class:`money`,money:item.myOffer||item.theirOffer||0},null,8,[`money`])])):createCommentVNode(``,!0)],2))),128))]),_:1})],512)]))}},NegotiationChat_default=__plugin_vue_export_helper_default(_sfc_main$135,[[`__scopeId`,`data-v-c4558f29`]]),_hoisted_1$121={class:`price-finder-label right`},_hoisted_2$101={class:`price-finder-track`},_hoisted_3$89={key:0,class:`tick-label`},_hoisted_4$69={class:`price-finder-label left`},_sfc_main$134={__name:`PriceFinder`,props:{offerHistory:{type:Array,default:()=>[]},negotiationStatus:{type:String,default:``},startingPrice:{type:Number,default:0},offerPreview:{type:Number,default:0},actualVehicleValue:{type:Number,default:null},amISelling:{type:Boolean,default:!1}},setup(__props){let{units}=useBridge(),props=__props,priceFinderData=computed(()=>{let history$1=props.offerHistory||[];if(history$1.length===0)return null;let initialTheirOffer=null,initialMyOffer=null;for(let item of history$1)if(initialTheirOffer===null&&item.theirOffer!=null&&(initialTheirOffer=item.theirOffer),initialMyOffer===null&&item.myOffer!=null&&(initialMyOffer=item.myOffer),initialTheirOffer!==null&&initialMyOffer!==null)break;let hasBothInitialOffers=initialTheirOffer!==null&&initialMyOffer!==null;initialTheirOffer===null&&(initialTheirOffer=props.startingPrice),initialMyOffer===null&&(initialMyOffer=props.offerPreview||props.startingPrice);let offers=[],offerIndex=0,lastMyOfferIndex=-1,lastTheirOfferIndex=-1;for(let item of history$1)item.myOffer==null?item.theirOffer!=null&&(offers.push({price:item.theirOffer,isMyOffer:!1,index:offerIndex++,isUnsent:!1}),lastTheirOfferIndex=offers.length-1):(offers.push({price:item.myOffer,isMyOffer:!0,index:offerIndex++,isUnsent:!1}),lastMyOfferIndex=offers.length-1);props.negotiationStatus!==`failed`&&props.negotiationStatus!==`accepted`&&props.offerPreview>0&&(offers.push({price:props.offerPreview,isMyOffer:!0,index:offerIndex++,isUnsent:!0}),lastMyOfferIndex=offers.length-1);let leftPrice=Math.min(initialTheirOffer,initialMyOffer),rightPrice=Math.max(initialTheirOffer,initialMyOffer),topIsTheir=props.amISelling,range=rightPrice-leftPrice||1,{majorTicks,minorTicks}=((min$1,max$1,priceRange)=>{let niceNumbers=[1,2,5,10,20,50,100,200,500,1e3,2e3,5e3,1e4],tickRange=max$1-min$1;if(tickRange===0)return{majorTicks:[],minorTicks:[]};let roughStep=tickRange/4,magnitude=10**Math.floor(Math.log10(roughStep)),normalizedStep=roughStep/magnitude,closestNice=niceNumbers[0],minDiff=Math.abs(normalizedStep-closestNice);for(let nice of niceNumbers){let diff=Math.abs(normalizedStep-nice);diff=min$1&&price<=max$1){let position=(price-leftPrice)/priceRange*100;majorTicks$1.push({price,position:Math.max(0,Math.min(100,position))})}let minorStep=step/5,minorTicks$1=[];for(let price=niceMin;price<=niceMax;price+=minorStep)if(price>=min$1&&price<=max$1&&Math.abs(price%step)>.01){let position=(price-leftPrice)/priceRange*100;minorTicks$1.push({price,position:Math.max(0,Math.min(100,position))})}return{majorTicks:majorTicks$1,minorTicks:minorTicks$1}})(leftPrice,rightPrice,range),hasVisibleTicks=range>0&&majorTicks.length>0,offerPositions=offers.map((offer,index)=>{let position=(offer.price-leftPrice)/range*100,isMostRecent=offer.isMyOffer&&index===lastMyOfferIndex||!offer.isMyOffer&&index===lastTheirOfferIndex;return{...offer,position:Math.max(0,Math.min(100,position)),isMostRecent}}),marketValuePosition=null;if(hasVisibleTicks&&props.actualVehicleValue!=null&&props.actualVehicleValue>0&&props.actualVehicleValue>=leftPrice&&props.actualVehicleValue<=rightPrice){let position=(props.actualVehicleValue-leftPrice)/range*100;marketValuePosition=Math.max(0,Math.min(100,position))}let initialMarkers=[];if(hasVisibleTicks){let theirPosition=initialTheirOffer===leftPrice?0:100;initialMarkers.push({price:initialTheirOffer,isMyOffer:!1,position:theirPosition,isInitial:!0});let myPosition=initialMyOffer===leftPrice?0:100;initialMarkers.push({price:initialMyOffer,isMyOffer:!0,position:myPosition,isInitial:!0})}return{initialTheirOffer,initialMyOffer,leftPrice,rightPrice,topIsTheir,hasBothInitialOffers,majorTicks,minorTicks,offers:offerPositions,marketValuePosition,initialMarkers}});return(_ctx,_cache)=>priceFinderData.value?(openBlock(),createElementBlock(`div`,{key:0,class:normalizeClass([`price-finder-container`,{selling:__props.amISelling,buying:!__props.amISelling}])},[createBaseVNode(`div`,_hoisted_1$121,[createTextVNode(toDisplayString(priceFinderData.value.topIsTheir?`Your`:`Their`)+` Asking Price: `,1),createVNode(unref(bngUnit_default),{class:`money`,money:priceFinderData.value.rightPrice},null,8,[`money`])]),createBaseVNode(`div`,_hoisted_2$101,[(openBlock(!0),createElementBlock(Fragment,null,renderList(priceFinderData.value.minorTicks,(tick,index)=>(openBlock(),createElementBlock(`div`,{key:`minor-`+index,class:`price-finder-tick minor`,style:normalizeStyle({top:100-tick.position+`%`})},null,4))),128)),(openBlock(!0),createElementBlock(Fragment,null,renderList(priceFinderData.value.majorTicks,(tick,index)=>(openBlock(),createElementBlock(`div`,{key:`major-`+index,class:`price-finder-tick major`,style:normalizeStyle({top:100-tick.position+`%`})},[tick.position>5&&tick.position<95?(openBlock(),createElementBlock(`div`,_hoisted_3$89,toDisplayString(unref(units).beamBucks(tick.price)),1)):createCommentVNode(``,!0)],4))),128)),priceFinderData.value.hasBothInitialOffers?(openBlock(!0),createElementBlock(Fragment,{key:0},renderList(priceFinderData.value.offers,(offer,index)=>(openBlock(),createElementBlock(`div`,{key:index,class:normalizeClass([`price-finder-marker`,{"my-offer":offer.isMyOffer,"their-offer":!offer.isMyOffer,"most-recent":offer.isMostRecent,unsent:offer.isUnsent}]),style:normalizeStyle({top:100-offer.position+`%`})},[..._cache[0]||=[createBaseVNode(`div`,{class:`marker-triangle`},null,-1)]],6))),128)):createCommentVNode(``,!0),priceFinderData.value.marketValuePosition===null?createCommentVNode(``,!0):(openBlock(),createElementBlock(`div`,{key:1,class:`price-finder-marker market-value`,style:normalizeStyle({top:100-priceFinderData.value.marketValuePosition+`%`,bottom:`0`})},[..._cache[1]||=[createBaseVNode(`div`,{class:`marker-dot`},null,-1)]],4)),(openBlock(!0),createElementBlock(Fragment,null,renderList(priceFinderData.value.initialMarkers,(marker$1,index)=>(openBlock(),createElementBlock(`div`,{key:`initial-`+index,class:normalizeClass([`price-finder-marker`,{"my-offer":marker$1.isMyOffer,"their-offer":!marker$1.isMyOffer,initial:!0}]),style:normalizeStyle({top:100-marker$1.position+`%`})},[..._cache[2]||=[createBaseVNode(`div`,{class:`marker-triangle`},null,-1)]],6))),128))]),createBaseVNode(`div`,_hoisted_4$69,[createTextVNode(toDisplayString(priceFinderData.value.topIsTheir?`Their`:`Your`)+` initial offer: `,1),createVNode(unref(bngUnit_default),{class:`money`,money:priceFinderData.value.leftPrice},null,8,[`money`])])],2)):createCommentVNode(``,!0)}},PriceFinder_default=__plugin_vue_export_helper_default(_sfc_main$134,[[`__scopeId`,`data-v-ba044f86`]]),_hoisted_1$120={class:`center-wrap`},_hoisted_2$100={class:`header-row`},_hoisted_3$88={key:0,class:`header-seller-info`},_hoisted_4$68={class:`main-content`},_hoisted_5$58={class:`summary`},_hoisted_6$45={key:0,class:`vehicle-info`},_hoisted_7$38={class:`purchase-row`},_hoisted_8$31={class:`label`},_hoisted_9$28={class:`sub-info`},_hoisted_10$22={class:`price`},_hoisted_11$20={class:`offer-container`},_hoisted_12$15={class:`patience`},_hoisted_13$14={class:`label-row`},_hoisted_14$14={class:`offer-controls`},_hoisted_15$14={key:0,class:`offer-controls-row`},_hoisted_16$14={class:`step-buttons-group`},_hoisted_17$11={class:`resolved-negotiation-message`},_hoisted_18$9={class:`price-column`},_hoisted_19$7={key:0,class:`price`},_hoisted_20$6={key:1,class:`price`},_hoisted_21$6={class:`action-buttons wide`},_sfc_main$133={__name:`VehicleNegotiationMain`,setup(__props){useUINavScope(`vehicleNegotiation`);let{units}=useBridge(),events$3=useEvents(),router$1=useRouter(),state=ref({active:!1,startingPrice:0,patience:0,myOffer:null,theirOffer:0,thinking:!1,status:``,negotiationStatus:``,opponentName:``,vehicleNiceName:``,vehicleThumbnail:``,amISelling:!1}),opponent=computed(()=>state.value.amISelling?`Buyer`:`Seller`),biggerIsBetter=computed(()=>!!state.value.amISelling),increaseOfferDisabled=computed(()=>state.value.amISelling?state.value.myOffer!=null&&offerPreview.value>=state.value.myOffer:offerPreview.value>=state.value.theirOffer),decreaseOfferDisabled=computed(()=>state.value.amISelling?(console.log(`decreaseOfferDisabled`,offerPreview.value,state.value.theirOffer),offerPreview.value<=state.value.theirOffer):state.value.myOffer!=null&&offerPreview.value<=state.value.myOffer),offerPreview=ref(0);computed(()=>{let baseStep=state.value.startingPrice/500;return Math.round(baseStep/5)*5}),computed(()=>{let diff=(offerPreview.value-state.value.startingPrice)/state.value.startingPrice*100;return Math.round(diff)});let diffOfferPreviewToStarting=computed(()=>offerPreview.value-state.value.startingPrice),isDiffOfferPreviewToStartingGood=computed(()=>biggerIsBetter.value?diffOfferPreviewToStarting.value>=0:diffOfferPreviewToStarting.value<=0),diffPercentOfferPreviewToMarket=computed(()=>{if(!state.value.actualVehicleValue||state.value.actualVehicleValue===0)return null;let diff=(offerPreview.value-state.value.actualVehicleValue)/state.value.actualVehicleValue*100;return Math.round(diff)}),isDiffPercentOfferPreviewToMarketGood=computed(()=>diffPercentOfferPreviewToMarket.value===null?null:biggerIsBetter.value?diffPercentOfferPreviewToMarket.value>=0:diffPercentOfferPreviewToMarket.value<=0),diffTheirOfferToStarting=computed(()=>state.value.theirOffer-state.value.startingPrice);computed(()=>biggerIsBetter.value?diffTheirOfferToStarting.value>=0:diffTheirOfferToStarting.value<=0);let nudgeOffer=delta=>{let roundedOfferPreview=Math.max(0,Math.round((offerPreview.value+delta)/50)*50),min$1=0,max$1=1/0;state.value.amISelling?(min$1=state.value.theirOffer,state.value.myOffer!=null&&(max$1=state.value.myOffer)):(max$1=state.value.theirOffer,state.value.myOffer!=null&&(min$1=state.value.myOffer)),offerPreview.value=Math.min(max$1,Math.max(min$1,roundedOfferPreview))},offerDisabled=computed(()=>state.value.negotiationStatus===`thinking`||state.value.negotiationStatus===`typing`||state.value.negotiationStatus===`accepted`||state.value.negotiationStatus===`failed`),patienceClass=computed(()=>{let m=state.value.patience??0;return m>.66?`patience-good`:m>.33?`patience-mid`:`patience-bad`}),noDeal=computed(()=>state.value.negotiationStatus===`failed`&&state.value.amISelling);computed(()=>state.value.negotiationStatus===`failed`),computed(()=>{switch(String(state.value.negotiationStatus||``)){case`counterOffer`:return`Counter offer`;case`counterOfferLastChance`:return`Last chance counter offer`;case`accepted`:return`Accepted`;case`failed`:return`Negotiation failed`;case`refused`:return`Offer refused`;case`initial`:return`Initial offer`;case`thinking`:return`Thinking`;case`typing`:return`Typing...`;default:return``}});let resolvedStatusText=computed(()=>state.value.negotiationStatus===`failed`?state.value.amISelling?`The other party ran out of patience and does not want to buy this vehicle.`:`The other party ran out of patience. You can still buy the vehicle at the starting price: `:state.value.negotiationStatus===`accepted`?`Congratulations! You've successfully negotiatied a deal with `+state.value.opponentName+`.`:``),negotiationChat=ref(null),refresh$1=async()=>{state.value=await Lua_default.career_modules_marketplace.getNegotiationState()||state.value;let base=state.value.myOffer==null?state.value.startingPrice:state.value.myOffer;Number.isNaN(Number(base))||(offerPreview.value=Number(base)),state.value.negotiationStatus===`failed`&&(offerPreview.value=state.value.startingPrice)},submitOffer=async()=>{let price=Number(offerPreview.value);Number.isFinite(price)&&await Lua_default.career_modules_marketplace.makeNegotiationOffer(price)},takeOffer=async()=>{await Lua_default.career_modules_marketplace.takeTheirOffer(),state.value.negotiationStatus=`accepted`,state.value.status=`accepted`,offerPreview.value=state.value.theirOffer,state.value.iAccepted=!0,state.value.offerHistory.push({myOffer:state.value.theirOffer,negotiationStatus:`accepted`})},cancel=async()=>{state.value.negotiationStatus!==`accepted`&&await Lua_default.career_modules_marketplace.cancelNegotiation()},goBack=event=>{router$1.back(),state.value.negotiationStatus===`accepted`&&!state.value.iAccepted&&Lua_default.career_modules_marketplace.takeTheirOffer(),cancel(),event&&event.stopPropagation&&event.stopPropagation()};return events$3.on(`negotiationData`,data=>{refresh$1()}),onMounted(async()=>{await refresh$1(),nextTick(()=>{negotiationChat.value&&(negotiationChat.value.reset(),negotiationChat.value.scrollToBottom())})}),onUnmounted(async()=>{events$3.off(`negotiationData`)}),(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$120,[withDirectives((openBlock(),createBlock(unref(bngCard_default),{"bng-ui-scope":`vehicleNegotiation`,class:`negotiation-screen`},{buttons:withCtx(()=>[createBaseVNode(`div`,_hoisted_21$6,[state.value.negotiationStatus!==`accepted`&&state.value.negotiationStatus!==`failed`?(openBlock(),createBlock(unref(bngButton_default),{key:0,class:`submit-offer`,disabled:state.value.negotiationStatus===`counterOfferLastChance`||offerPreview.value==state.value.theirOffer||offerPreview.value==state.value.myOffer||offerDisabled.value,onClick:_cache[6]||=$event=>submitOffer(),accent:unref(ACCENTS).secondary},{default:withCtx(()=>[..._cache[16]||=[createTextVNode(` Submit This Offer `,-1)]]),_:1},8,[`disabled`,`accent`])):createCommentVNode(``,!0),state.value.negotiationStatus!==`accepted`&&state.value.negotiationStatus!==`failed`?withDirectives((openBlock(),createBlock(unref(bngButton_default),{key:1,class:`submit-offer`,disabled:state.value.negotiationStatus===`counterOfferLastChance`||offerDisabled.value,"show-hold":``},{default:withCtx(()=>[..._cache[17]||=[createTextVNode(` Agree to their Price `,-1)]]),_:1},8,[`disabled`])),[[unref(BngClick_default),{holdCallback:takeOffer,holdDelay:1e3,repeatInterval:0}]]):createCommentVNode(``,!0),state.value.negotiationStatus===`failed`||state.value.negotiationStatus===`accepted`?(openBlock(),createBlock(unref(bngButton_default),{key:2,class:`go-back`,accent:unref(ACCENTS).primary,onClick:goBack},{default:withCtx(()=>[createTextVNode(toDisplayString(state.value.amISelling?`Continue`:`Go to Purchase Screen`),1)]),_:1},8,[`accent`])):createCommentVNode(``,!0)])]),default:withCtx(()=>[createBaseVNode(`div`,_hoisted_2$100,[createVNode(unref(bngCardHeading_default),{type:`ribbon`},{default:withCtx(()=>[createTextVNode(` Negotiation with `+toDisplayString(state.value.opponentName||opponent.value)+` `,1),state.value.opponentQuote?(openBlock(),createElementBlock(`div`,_hoisted_3$88,` "`+toDisplayString(state.value.opponentQuote)+`" `,1)):createCommentVNode(``,!0)]),_:1}),createVNode(unref(bngButton_default),{class:`close-button`,onClick:goBack,accent:unref(ACCENTS).attention,"bng-no-nav":`true`,tabindex:`-1`},{default:withCtx(()=>[createVNode(unref(bngBinding_default),{"ui-event":`menu`,controller:``}),createVNode(unref(bngIcon_default),{type:`xmarkBold`,color:`var(--bng-cool-gray-100)`})]),_:1},8,[`accent`])]),createBaseVNode(`div`,_hoisted_4$68,[createBaseVNode(`div`,_hoisted_5$58,[state.value.vehicleNiceName||state.value.vehicleThumbnail?(openBlock(),createElementBlock(`div`,_hoisted_6$45,[createBaseVNode(`div`,_hoisted_7$38,[createBaseVNode(`div`,_hoisted_8$31,[createBaseVNode(`div`,null,toDisplayString(state.value.vehicleNiceName||`Vehicle`),1),createBaseVNode(`div`,_hoisted_9$28,toDisplayString(unref(units).buildString(`length`,state.value.vehicleMileage,0)),1)]),createBaseVNode(`div`,_hoisted_10$22,[_cache[7]||=createTextVNode(` Est. Market: `,-1),createBaseVNode(`div`,null,[createVNode(unref(bngUnit_default),{class:`money`,money:state.value.actualVehicleValue||0},null,8,[`money`])])])])])):createCommentVNode(``,!0)]),createBaseVNode(`div`,_hoisted_11$20,[createVNode(NegotiationChat_default,{ref_key:`negotiationChat`,ref:negotiationChat,"offer-history":state.value.offerHistory||[],"negotiation-status":state.value.negotiationStatus,"starting-price":state.value.startingPrice||0,"am-i-selling":state.value.amISelling},null,8,[`offer-history`,`negotiation-status`,`starting-price`,`am-i-selling`]),createVNode(PriceFinder_default,{"offer-history":state.value.offerHistory||[],"negotiation-status":state.value.negotiationStatus,"starting-price":state.value.startingPrice||0,"offer-preview":offerPreview.value||0,"actual-vehicle-value":state.value.actualVehicleValue,"am-i-selling":state.value.amISelling},null,8,[`offer-history`,`negotiation-status`,`starting-price`,`offer-preview`,`actual-vehicle-value`,`am-i-selling`])]),createBaseVNode(`div`,_hoisted_12$15,[createBaseVNode(`div`,{class:normalizeClass([`bar`,patienceClass.value])},[_cache[8]||=createBaseVNode(`div`,{class:`separator`,style:{left:`33.0%`}},null,-1),_cache[9]||=createBaseVNode(`div`,{class:`separator`,style:{left:`66.0%`}},null,-1),createBaseVNode(`div`,{class:normalizeClass([`fill`,patienceClass.value]),style:normalizeStyle({width:Math.max(0,Math.min(1,state.value.patience||0))*100+`%`})},null,6)],2),createBaseVNode(`div`,_hoisted_13$14,[createBaseVNode(`span`,null,toDisplayString(opponent.value)+`'s Patience`,1)])]),createBaseVNode(`div`,_hoisted_14$14,[state.value.negotiationStatus!==`failed`&&state.value.negotiationStatus!==`accepted`?(openBlock(),createElementBlock(`div`,_hoisted_15$14,[createBaseVNode(`div`,_hoisted_16$14,[createVNode(unref(bngButton_default),{class:`step step-large`,disabled:offerDisabled.value||decreaseOfferDisabled.value,onClick:_cache[0]||=$event=>nudgeOffer(-5e3)},{default:withCtx(()=>[..._cache[10]||=[createTextVNode(`-5000`,-1)]]),_:1},8,[`disabled`]),createVNode(unref(bngButton_default),{class:`step step-medium`,disabled:offerDisabled.value||decreaseOfferDisabled.value,onClick:_cache[1]||=$event=>nudgeOffer(-500)},{default:withCtx(()=>[..._cache[11]||=[createTextVNode(`-500`,-1)]]),_:1},8,[`disabled`]),createVNode(unref(bngButton_default),{class:`step`,disabled:offerDisabled.value||decreaseOfferDisabled.value,onClick:_cache[2]||=$event=>nudgeOffer(-50)},{default:withCtx(()=>[..._cache[12]||=[createTextVNode(`-50`,-1)]]),_:1},8,[`disabled`]),createVNode(unref(bngButton_default),{class:`step`,disabled:offerDisabled.value||increaseOfferDisabled.value,onClick:_cache[3]||=$event=>nudgeOffer(50)},{default:withCtx(()=>[..._cache[13]||=[createTextVNode(`+50`,-1)]]),_:1},8,[`disabled`]),createVNode(unref(bngButton_default),{class:`step step-medium`,disabled:offerDisabled.value||increaseOfferDisabled.value,onClick:_cache[4]||=$event=>nudgeOffer(500)},{default:withCtx(()=>[..._cache[14]||=[createTextVNode(`+500`,-1)]]),_:1},8,[`disabled`]),createVNode(unref(bngButton_default),{class:`step step-large`,disabled:offerDisabled.value||increaseOfferDisabled.value,onClick:_cache[5]||=$event=>nudgeOffer(5e3)},{default:withCtx(()=>[..._cache[15]||=[createTextVNode(`+5000`,-1)]]),_:1},8,[`disabled`])])])):createCommentVNode(``,!0),state.value.negotiationStatus===`failed`||state.value.negotiationStatus===`accepted`?(openBlock(),createElementBlock(`div`,{key:1,class:normalizeClass([`offer-controls-row`,{accepted:state.value.negotiationStatus===`accepted`,failed:state.value.negotiationStatus===`failed`}])},[createVNode(unref(bngIcon_default),{type:state.value.negotiationStatus===`accepted`?`checkmark`:`abandon`,class:`resolved-negotiation-icon`},null,8,[`type`]),createBaseVNode(`div`,_hoisted_17$11,toDisplayString(resolvedStatusText.value),1)],2)):createCommentVNode(``,!0),createBaseVNode(`div`,_hoisted_18$9,[noDeal.value?(openBlock(),createElementBlock(`div`,_hoisted_19$7,` NO DEAL `)):(openBlock(),createElementBlock(`div`,_hoisted_20$6,toDisplayString(unref(units).beamBucks(offerPreview.value||0)),1)),diffOfferPreviewToStarting.value===null?createCommentVNode(``,!0):(openBlock(),createElementBlock(`div`,{key:2,class:normalizeClass([`diff-percent-offer-preview-to-starting`,{positive:isDiffOfferPreviewToStartingGood.value&&diffOfferPreviewToStarting.value!==0,negative:!isDiffOfferPreviewToStartingGood.value&&diffOfferPreviewToStarting.value!==0,zero:diffOfferPreviewToStarting.value===0,hidden:noDeal.value}])},[diffOfferPreviewToStarting.value===0?createCommentVNode(``,!0):(openBlock(),createBlock(unref(bngUnit_default),{key:0,class:`money`,money:Math.abs(diffOfferPreviewToStarting.value)},null,8,[`money`])),createTextVNode(` `+toDisplayString(diffOfferPreviewToStarting.value<0?`under`:diffOfferPreviewToStarting.value>0?`over`:`Same as`)+` starting price `,1)],2)),diffPercentOfferPreviewToMarket.value===null?createCommentVNode(``,!0):(openBlock(),createElementBlock(`div`,{key:3,class:normalizeClass([`diff-percent-offer-preview-to-market`,{positive:isDiffPercentOfferPreviewToMarketGood.value,negative:!isDiffPercentOfferPreviewToMarketGood.value,hidden:noDeal.value}])},toDisplayString(Math.abs(diffPercentOfferPreviewToMarket.value))+`% `+toDisplayString(diffPercentOfferPreviewToMarket.value<0?`under`:`over`)+` Est. Market value `,3))])])])]),_:1})),[[unref(BngBlur_default),1]])]))}},VehicleNegotiationMain_default=__plugin_vue_export_helper_default(_sfc_main$133,[[`__scopeId`,`data-v-29ff8ba1`]]),routes_default$3=[{path:`/menu.careerPause`,name:`menu.careerPause`,component:Pause_default,props:!0,meta:{clickThrough:!0,infoBar:{withAngular:!0,visible:!0,showSysInfo:!0},uiApps:{shown:!1},topBar:{visible:!0}}},{path:`/career`,children:[{path:`chooseInsurance`,name:`chooseInsurance`,component:ChooseInsuranceMain_default},{path:`pauseBigMiddlePanel`,name:`pauseBigMiddlePanel`,component:PauseBigMiddlePanel_default,props:!0},{path:`logbook/:id(\\*?.*?)?`,name:`logbook`,component:Logbook_default,meta:{uiApps:{shown:!1}},props:!0},{path:`milestones/:id(\\*?.*?)?`,name:`milestones`,component:Milestones_default,props:!0,meta:{uiApps:{shown:!1}}},{path:`computer`,name:`computer`,component:ComputerMain_default,props:!0,meta:{uiApps:{shown:!1}}},{path:`vehicleInventory`,name:`vehicleInventory`,component:VehicleInventoryMain_default},{path:`vehiclePerformance/:inventoryId?`,name:`vehiclePerformance`,component:VehiclePerformanceMain_default,props:!0},{path:`tuning`,name:`tuning`,component:TuningMain_default},{path:`painting`,name:`painting`,component:PaintingMain_default},{path:`repair/:header?`,name:`repair`,component:RepairMain_default,props:!0},{path:`partShopping`,name:`partShopping`,component:PartShoppingMain_default,meta:{uiApps:{shown:!1}}},{path:`partInventory`,name:`partInventory`,component:PartInventoryMain_default},{path:`vehiclePurchase/:vehicleInfo?/:playerMoney?/:inventoryHasFreeSlot?/:lastVehicleInfo?`,name:`vehiclePurchase`,component:VehiclePurchaseMain_default,props:!0,meta:{uiApps:{shown:!1}}},{path:`negotiation`,name:`negotiation`,component:VehicleNegotiationMain_default},{path:`vehicleShopping/:screenTag?/:buyingAvailable?/:marketplaceAvailable?/:selectedSellerId?`,name:`vehicleShopping`,component:VehicleShoppingMain_default,props:!0,meta:{uiApps:{shown:!1}}},{path:`insurances`,name:`insurances`,component:InsurancesMain_default},{path:`playerAbstract`,name:`playerAbstract`,component:DriverAbstract_default},{path:`cargoDeliveryReward`,name:`cargoDeliveryReward`,component:CargoDeliveryReward_default,props:!0},{path:`cargoDropOff/:facilityId?/:parkingSpotPath(\\*?.*?)?`,name:`cargoDropOff`,component:CargoDropOff_default,props:!0},{path:`cargoOverview/:facilityId?/:parkingSpotPath(\\*?.*?)?`,name:`cargoOverview`,component:CargoOverviewMain_default,props:!0,meta:{uiApps:{shown:!1}}},{path:`myCargo`,name:`myCargo`,component:MyCargo_default,props:!0,meta:{uiApps:{shown:!1}}},{path:`progressLanding/:pathId?/:comesFromBigMap?`,name:`progressLanding`,component:ProgressLanding_default,props:route=>({pathId:route.params.pathId,comesFromBigMap:route.params.comesFromBigMap===`true`||route.params.comesFromBigMap===!0}),meta:{uiApps:{shown:!1},infoBar:{visible:!0}}},{path:`domainSelection`,name:`domainSelection`,component:ProgressLanding_default,props:!0,meta:{uiApps:{shown:!1},infoBar:{visible:!0}}},{path:`profiles`,name:`profiles`,component:Profiles_default,meta:{uiApps:{shown:!1},infoBar:{visible:!0,showSysInfo:!0}}}]}],data_default=[{translateId:`ui.credits.programmers`,members:[{first:`Thomas`,last:`Fischer`,aka:`tdev`,title:`CEO`},{first:`Lefteris`,last:`Stamatogiannakis`,aka:`estama`,title:`CTO / Physics / Sound / AI`},{first:`Luis`,last:`Anton Rebollo`,aka:`Souga`,title:`Lead Render Developer`},{first:`Alex`,last:`Spodheim`,aka:`CrankyCleric`,title:`Developer`},{first:`Ananda Neelam`,last:`Thathayya`,aka:`Nadeox1`,title:`Technical Artist`},{first:`Andrew`,last:`Kabakwu`,aka:``,title:`Developer`},{first:`Bruno`,last:`Gonzalez Campo`,aka:`stenyak`,title:`Lead Game Engine Developer`},{first:`Cosmin`,last:`Traian`,aka:``,title:`Developer`},{first:`Emre`,last:`Kut`,aka:``,title:`Developer`},{first:`Felix`,last:`Unger`,aka:``,title:`Developer`},{first:`George`,last:`Troulitakis`,aka:`AtmanB`,title:`Developer`},{first:`Guillem`,last:`Ortega`,aka:``,title:`Developer`},{first:`Logane`,last:`Ramez`,aka:`Gadoy`,title:`Developer`},{first:`Lorenzo`,last:`Bartali`,aka:``,title:`AI Developer`},{first:`Ludger`,last:`Meyer-Wülfing`,aka:`meywue`,title:`Developer`},{first:`Nicusor`,last:`Nedelcu`,aka:``,title:`Tools Developer`},{first:`Panos`,last:`Karabelas`,aka:``,title:`Developer`},{first:`Patrick `,last:`Schrangl`,aka:``,title:`Simulation Software Engineer`},{first:`Petros`,last:`Kondylis`,aka:``,title:`AI Developer`},{first:`Ronny`,last:`Nowak`,aka:``,title:`Developer`},{first:`Thomas`,last:`Portassau`,aka:`thomatoes50`,title:`Developer`},{first:`Thomas`,last:`Wilczynski`,aka:`Gamergull`,title:`Developer`},{first:`Timo`,last:`Stabbert`,aka:``,title:`Gameplay Dev Lead`},{first:`Valery`,last:`Dolotin`,aka:``,title:`AI Developer`},{first:`Daniel`,last:`Wakefield`,aka:``,title:`Developer`}]},{translateId:`ui.credits.vehiclePhysics`,members:[{first:`Fabian`,last:`Enkler`,aka:`Diamondback`,title:`Vehicle Systems Lead`},{first:`Angelo`,last:`Matteo`,aka:`angelo234`,title:`Tools Developer`},{first:`Aubrey`,last:`Percival`,aka:``,title:`Vehicle Physics Engineer`},{first:`Bobby`,last:`Villeneuve`,aka:`Binkey`,title:`Vehicle Physics Engineer`},{first:`Brian`,last:`Rickets`,aka:``,title:`Vehicle Systems Engineer`},{first:`Corey`,last:`Bergerud`,aka:`Goosah`,title:`Vehicle Physics Engineer`},{first:`Davide`,last:`Serpi`,aka:``,title:`Vehicle Dynamics Control Intern`},{first:`Efe Can`,last:`Kiraz`,aka:`RenAzuma66`,title:`Vehicle Physics Engineer`},{first:`Grzegorz`,last:`Węgrzyn`,aka:`AiTorror`,title:`Vehicle Physics Engineer / QA`},{first:`Jack`,last:`Jermany`,aka:``,title:`Vehicle Physics Engineer / QA`},{first:`Oliver`,last:`Čajka`,aka:`MRcrash`,title:`Vehicle Physics Engineer`},{first:`Piotr`,last:`Gajek`,aka:`Agent_Y`,title:`Vehicle Physics Engineer / QA`},{first:`Toma Ioan`,last:` Turcu`,aka:``,title:`Vehicle Physics Engineer`},{first:`Quinn`,last:`Howling`,aka:`SpeedHero`,title:`Vehicle Physics Designer`}]},{translateId:`ui.credits.vehicleArt`,members:[{first:`Gabriel`,last:`Fink`,aka:`gabester`,title:`Vehicle Art Director`},{first:`Jared`,last:`Samuelson`,aka:``,title:`Vehicle Team Lead / Subaru Expert`},{first:`Alexandr`,last:`Shesternin`,aka:``,title:`3D Vehicle Artist`},{first:`Andreas`,last:`Focht`,aka:``,title:`Vehicle Concept Artist`},{first:`Daniel`,last:`Russo`,aka:`A3DR`,title:`3D Vehicle Artist`},{first:`Dennis`,last:`Mateja`,aka:`NinetyNine`,title:`Vehicle Designer`},{first:`Manish`,last:`Rawat`,aka:``,title:`3D Vehicle Artist`}]},{translateId:`ui.credits.environmentArtists`,members:[{first:`Sam`,last:`Hutchinson`,aka:`LJFHutch`,title:`Environment Art Director`},{first:`Luca`,last:`Brighi`,aka:``,title:`Lead 3D Environment Artist`},{first:`Huiqin`,last:`Li`,aka:``,title:`3D Environment Artist`},{first:`Sebastien`,last:`Pelletier`,aka:`DoullPepper`,title:`3D Environment Artist`}]},{translateId:`ui.credits.conceptArtists`,members:[{first:`Mary Jane`,last:`Pajaron`,aka:``,title:`2D Concept Artist`}]},{translateId:`ui.credits.gameDesigners`,members:[{first:`James`,last:`Heslop`,aka:`Krallopian`,title:`Game Design Lead`},{first:`Alex`,last:`Bird`,aka:``,title:`Gameplay Developer`},{first:`Rob`,last:`Herridge`,aka:`HighDef`,title:`Gameplay Developer / QA`}]},{translateId:`ui.credits.ui`,members:[{first:`Pavel`,last:`Tiunov`,aka:`Dizboosta`,title:`UI Lead`},{first:`Destiny`,last:`Abellana`,aka:``,title:`Developer`},{first:`Stani`,last:`Tolmacheva`,aka:`Snowly`,title:`Developer`}]},{translateId:`ui.credits.sound`,members:[{first:`Mark`,last:`Knight`,aka:`TDK`,title:`Audio Designer`},{first:`Sebastian`,last:`Emling`,aka:``,title:`Audio Designer`},{first:`Jethro`,last:`Dunn`,aka:``,title:`Audio Outsourcer`},{first:`Max`,last:`Schumann`,aka:``,title:`Audio Outsourcer`}]},{translateId:`ui.credits.qa`,members:[{first:`Colin`,last:`Wenz`,aka:`synsol`,title:`QA Lead`},{first:`Przemysław`,last:`Wolny`,aka:`Car_Killer`,title:`QA / Mod Support`}]},{translateId:`ui.credits.production`,members:[{first:`Ryan`,last:`Dunne`,aka:``,title:`Producer`}]},{translateId:`ui.credits.sysops`,members:[{first:`Charalampos`,last:`Tsipizidis`,aka:``,title:`System Administrator`},{first:`Dimitrios`,last:`Folias`,aka:``,title:`System Administrator`}]},{translateId:`ui.credits.comms`,members:[{first:`Nataliia`,last:`Dmytriievska`,aka:`Leeloo`,title:`Communications & Marketing Lead`},{first:`Bernice`,last:`Mills`,aka:`Bee`,title:`Community Support & Marketing Specialist`},{first:`Mariia`,last:`Gumarova`,aka:`Fluffy Panda`,title:`Customer Support & Marketing Specialist`},{first:`Slawomir`,last:`Niemczyk`,aka:`Sedricoo`,title:`Community Coordinator`},{first:`Vincent`,last:`Liu`,aka:``,title:`Community & Marketing Specialist (APAC)`}]},{translateId:`ui.credits.research`,members:[{first:`Chrysanthi`,last:`Papamichail`,aka:``,title:`Lead Research Software Engineer`},{first:`Abdulrahman`,last:`Saeed`,aka:``,title:`Research Software Engineer`},{first:`Adam`,last:`Ivora`,aka:``,title:`Research Software Engineer`},{first:`David`,last:`Stark`,aka:``,title:`Research Software Engineer`},{first:`Florian`,last:`Faistauer`,aka:``,title:`Vehicle Simulation Expert`},{first:`Gabriel Puretas`,last:`Moral`,aka:``,title:`UX Intern`},{first:`Sayali`,last:`Rajhans`,aka:``,title:`Research Software Engineer`},{first:`Iskren`,last:`Rusimov`,aka:``,title:`Research Software Engineer Intern`}]},{translateId:`ui.credits.organization`,members:[{first:`Christoforos`,last:`Lambrianidis`,aka:``,title:`CFO`},{first:`Joseph`,last:`Inba Raj`,aka:``,title:`HR & Talent Acquisition Lead`},{first:`Cecilia`,last:`Sari`,aka:``,title:`Recruitment Specialist`},{first:`Dimitra`,last:`Litsardou`,aka:`Thamy`,title:`EU / Co-funding Advisory Specialist`},{first:`Eva`,last:`Pigova`,aka:``,title:`Senior Program Manager`},{first:`Maria`,last:`Kosmachevskaya`,aka:``,title:`Business Development Intern`},{first:`Özge`,last:`Altinkaya Erkok`,aka:``,title:`Communication Consultant`},{first:`Renars`,last:`Skesteris`,aka:``,title:`Business Development Intern`},{first:`Sabrina`,last:`Wee`,aka:``,title:`Business Development Manager`},{first:`Sandra`,last:`Campos`,aka:``,title:`Accounting Assistant`},{first:`Ulrike`,last:`Lentz`,aka:``,title:`Executive Assistant`}]},{translateId:`ui.credits.additionalVehiclePhysics`,members:[{first:`Will`,last:`Leader`,aka:``,title:`Off-road Suspension Development and Vehicle Dynamics`}]},{translateId:`ui.credits.additionalVehicleArt`,members:[{first:`Ashish`,last:`Singh`,aka:``,title:`Freelance 3D Vehicle Artist`},{first:`Juan Manuel`,last:`Orcellet`,aka:``,title:`Freelance 3D Vehicle Artist`},{first:`M. Yusuf`,last:`Bolukbasi`,aka:``,title:`Freelance Vehicle Artist`},{first:`Naman`,last:`Deep`,aka:``,title:`Freelance 3D Vehicle Artist`}]},{translateId:`ui.credits.externalContributors`,members:[{first:`Da`,last:`Li`,aka:``,title:``},{first:`Ruhmit`,last:`Sahu `,aka:``,title:``}]},{translateId:`ui.credits.formerEmployee`,members:[{first:`Aaron`,last:`Sutcliffe`,aka:``,title:`Developer / Vehicle Creation`},{first:`Alex`,last:`Raskin`,aka:``,title:`DevOps Engineer`},{first:`Artem`,last:`Arbatskii`,aka:``,title:`Developer`},{first:`Arturo`,last:`Campos`,aka:``,title:`Developer`},{first:`Ben`,last:`Payne`,aka:``,title:`Developer`},{first:`Boluwatife`,last:`Falaye`,aka:``,title:`Developer`},{first:`Clément`,last:`Roche`,aka:``,title:`Developer`},{first:`Edelmar`,last:`Schneider`,aka:``,title:`Developer`},{first:`Eike`,last:`Externest`,aka:``,title:`Developer`},{first:`Jali`,last:`Hautala`,aka:`Jalkku`,title:`Developer`},{first:`Jeremy`,last:`Lu`,aka:``,title:`Developer`},{first:`John`,last:`Beinecke`,aka:``,title:`Developer`},{first:`Juan`,last:`Mendez`,aka:``,title:`Developer`},{first:`Leander`,last:`Beernaert`,aka:``,title:`Game Engine Developer`},{first:`Marc`,last:`Müller`,aka:``,title:`Developer`},{first:`Mark`,last:`Vince`,aka:``,title:`Developer`},{first:`Matti`,last:`Yrjänheikki`,aka:`Masa`,title:`Developer`},{first:`Max`,last:`Razer`,aka:``,title:`Developer`},{first:`Mayowa David`,last:`Abogunrin`,aka:``,title:`Developer`},{first:`Moncef`,last:`Slimane`,aka:``,title:`Developer`},{first:`Nourelhoda`,last:`Mohamed`,aka:``,title:`Developer`},{first:`Pascale`,last:`Maul`,aka:``,title:`Developer`},{first:`Paul`,last:`De Almeida`,aka:``,title:`AI Developer`},{first:`Paul`,last:`Görs`,aka:``,title:`Developer`},{first:`Peter`,last:`Landwehr`,aka:``,title:`Developer`},{first:`Petteri`,last:`Koivumäki`,aka:``,title:`Developer`},{first:`Vasilis`,last:`Douvaras`,aka:``,title:`Developer`},{first:`Vatroslav `,last:`Bodrozic`,aka:``,title:`Developer`},{first:`Waldemar`,last:`Zeitler`,aka:``,title:`Developer`},{first:`Xiaoyi`,last:`Wang`,aka:``,title:`Developer`},{first:``,last:``,aka:``,title:``},{first:`Adrian`,last:`Baboi`,aka:``,title:`Vehicle Creation`},{first:`Brandon`,last:`Proulx`,aka:`Hondune`,title:`Vehicle Creation`},{first:`Carlos`,last:`Bergillos Varela`,aka:`CarlosAir`,title:`Content Creation`},{first:`David`,last:`Thurlbeck`,aka:``,title:`Vehicle Creation`},{first:`Janne`,last:`Nummela`,aka:``,title:`Vehicle Creation`},{first:`Jukka`,last:`Muikkula`,aka:`Miura`,title:`Vehicle Creation`},{first:`Karol`,last:`Miklas`,aka:``,title:`Freelance 3D Vehicle Artist`},{first:`Mardem`,last:`Pires das Dores`,aka:``,title:`Vehicle Creation`},{first:`Mikko`,last:`Lesonen`,aka:``,title:`Vehicle Creation`},{first:`Renju`,last:`Therakathu`,aka:``,title:`Vehicle Creation`},{first:`Sam`,last:`Millington`,aka:`DrowsySam`,title:`Vehicle Creation / Support`},{first:`Sebastian`,last:`Wessel`,aka:``,title:`Vehicle Creation`},{first:`Virtual Mechanix`,last:``,aka:``,title:`Vehicle Creation - Outsourcing Agency`},{first:`Winston`,last:`Broderick`,aka:``,title:`Vehicle Creation`},{first:`Mitchell`,last:`Sahl`,aka:`B25Mitch`,title:`3D Vehicle / Environment Artist`},{first:``,last:``,aka:``,title:``},{first:`Christin`,last:`Walther`,aka:``,title:`Lead 3D Artist`},{first:`Justin`,last:`Roczniak`,aka:`Donoteat`,title:`Environment Artist`},{first:`Lisa`,last:`Steinberg`,aka:``,title:`2D Artist`},{first:`Moses`,last:`Mulinge`,aka:``,title:`2D Artist`},{first:``,last:``,aka:``,title:``},{first:`Barend`,last:`van der Meulen`,aka:``,title:`Content Creator`},{first:`Matthias`,last:`Niebergall`,aka:``,title:`Game Designer`},{first:`SanityCheckMyGame`,last:``,aka:``,title:`Additional Design`},{first:``,last:``,aka:``,title:``},{first:`Georgios`,last:`Siantikos`,aka:`gntikos`,title:`User Interface`},{first:`Jonathan`,last:`Randy`,aka:``,title:`Lead Developer`},{first:`Mirco`,last:`Weigel`,aka:`theshark`,title:`User Interface`},{first:`Svetlozar`,last:`Valchev`,aka:``,title:`User Interface`},{first:`Theodoros`,last:`Manouilidis`,aka:``,title:`User Interface`},{first:`Yale`,last:`Hartmann`,aka:``,title:`User Interface`},{first:``,last:``,aka:``,title:``},{first:`Arend`,last:`Stührmann`,aka:``,title:`Producer`},{first:`Marie Cécile`,last:`Jacq`,aka:``,title:`Producer`},{first:`Nhung Van`,last:`Ho`,aka:``,title:`Project Management`},{first:``,last:``,aka:``,title:``},{first:`Bhavinkumar Babulal`,last:`Arya`,aka:``,title:`Research Software Engineer`},{first:`Carol`,last:`Halim`,aka:`Carotte`,title:`Research Software Engineer`},{first:`Elmar`,last:`Berghöfer`,aka:``,title:`Research`},{first:`Mattia`,last:`Vicari`,aka:``,title:`Research Software Engineer`},{first:``,last:``,aka:``,title:``},{first:`Camila`,last:`Navia`,aka:``,title:`Operations Assistant`},{first:`Danish`,last:`Abbasi`,aka:``,title:`Business Development Intern`},{first:`Lucien`,last:`Frei`,aka:``,title:`Business Development Intern`},{first:`Weiwei`,last:`Kong`,aka:``,title:`Business Development Intern`},{first:`Özgen`,last:`Saatçilar`,aka:``,title:`Communications Consultant`},{first:`Saskia`,last:`Opitz`,aka:``,title:`Administration`},{first:``,last:``,aka:``,title:``},{first:`Hala`,last:`Mahmoud`,aka:``,title:`Quality Assurance`},{first:`Jan Niklas`,last:`Hasse`,aka:``,title:`Quality Assurance`},{first:`Kamil`,last:`Kozak`,aka:``,title:`Quality Assurance`},{first:`Kemisola`,last:`Adeniyi`,aka:``,title:`Quality Assurance`},{first:`Kaja`,last:`Jambrek`,aka:``,title:`Quality Assurance`},{first:`Rajinder`,last:`Rajinder`,aka:``,title:`Quality Assurance`},{first:`Safdar`,last:`Mahmood`,aka:``,title:`Quality Assurance`},{first:`Uros`,last:`Sakic`,aka:`Uki`,title:`QA / Mod Support / Tools QA`},{first:``,last:``,aka:``,title:``},{first:`Konstantinos`,last:`Stamou`,aka:``,title:`System Administrator`},{first:``,last:``,aka:``,title:``},{first:`Erik`,last:`Heldt`,aka:``,title:`Documentation`},{first:`Maxime`,last:`Desharnais`,aka:``,title:`Documentation`},{first:`Harm`,last:`Schulz`,aka:``,title:`Student Assistant`},{first:`Annisa`,last:`Utami`,aka:``,title:`Student Assistant`},{first:`Brandon`,last:`Lynch`,aka:`Chuck_Norris_`,title:`Community Coordinator`},{first:`Monica`,last:`Huang`,aka:``,title:`Community Coordinator`}]},{translateId:`ui.credits.ourAwesomeCommunity`,members:[{first:`Daniel`,last:`Jones`,aka:`daniel_j`},{first:`Dennis`,last:`Wrekenhorst`,aka:`Dennis-W`},{first:`Dustin`,last:`Kutchara`,aka:`dkutch`},{first:`Kristian`,last:`Fagerland`,aka:``},{first:`Richard`,last:`Sixsmith`,aka:`Metalmuncher`},{first:`Sergy`,last:`Karpowicz`,aka:`0xsergy`},{first:`Sven`,last:`Nabeck`,aka:`sputnik_1`},{first:`Tom`,last:`Verhoeve`,aka:`Mythbuster`},{first:`Yannis`,last:`Vaiopoulos`,aka:`JohnV`},{first:``,last:``,aka:`Fufsgfen`}]},{translateId:`ui.credits.specialThanksTo`,members:[{first:`Luis`,last:`Placid`,aka:``,title:`VFX Developer`},{first:`Pierre-Michel`,last:`Ricordel`,aka:`pricorde`}]},{translateId:`ui.credits.soundtrack`,members:[{first:`Gabriel "gabester" Fink`,last:`Copyright 2014`,aka:`Lonle`},{first:`Mark "TDK" Knight`,last:`Copyright 2018`,aka:`Element No. 10`},{first:`Mark "TDK" Knight`,last:`Copyright 2018`,aka:`Getting Away`},{first:`Mark "TDK" Knight`,last:`Copyright 2018`,aka:`Juno Rocks`},{first:`Mark "TDK" Knight`,last:`Copyright 2018`,aka:`Neon Night Racer`},{first:`Mark "TDK" Knight`,last:`Copyright 2018`,aka:`Night Driver`}]},{translateId:`ui.credits.madePossibleWith`,members:[{first:`FMOD Studio by Firelight Technologies Pty Ltd.`,last:``,aka:``},{first:`LuaJIT`,last:``,aka:``},{first:`lua-intf, LuaBridge`,last:``,aka:``},{first:`Chromium Embedded Framework`,last:``,aka:``},{first:`AngularJS`,last:``,aka:``},{first:`Vue.js`,last:``,aka:``},{first:`Material Design`,last:``,aka:``},{first:`LuaSocket`,last:``,aka:``},{first:`Dear ImGui`,last:``,aka:``},{first:`Blender ®`,last:`www.blender.org`,aka:``}]},{translateId:``,members:[{first:`“DUALSHOCK” and “DualSense” are registered trademarks or trademarks of Sony Interactive Entertainment Inc. Library programs for DUALSHOCK®4 and DualSense™ wireless controllers © 2022 Sony Interactive Entertainment Inc.`,last:``,aka:``}]}],_hoisted_1$119={class:`bng-credits-content`},_hoisted_2$99=[`src`],_hoisted_3$87={class:`category`},_hoisted_4$67={class:`credits-table`},_hoisted_5$57={class:`member-cell member-name`},_hoisted_6$44={key:0,class:`aka`},_hoisted_7$37={key:1},_hoisted_8$30={key:0,class:`member-cell member-dot`},_hoisted_9$27={key:1},_hoisted_10$21={key:2,class:`member-cell member-role`},_hoisted_11$19={key:3},_sfc_main$132={__name:`CreditsScroller`,setup(__props){useUINavScope(`credits`);let imageURL=getAssetURL(`images/logos.svg#bng-drive-white`),wrapper=ref(),running=!0,exit=()=>{running=!1,Lua_default.extensions.unload(`ui_credits`),Lua_default.scenetree[`maincef:setMaxFPSLimit`](30),window.bngVue.gotoAngularState(`menu.mainmenu`)};onMounted(()=>{Lua_default.extensions.load(`ui_credits`),Lua_default.scenetree[`maincef:setMaxFPSLimit`](60),wrapper.value.focus(),scrollContainer(wrapper.value,65,exit)}),onUnmounted(()=>{exit()});function scrollContainer(container,pxPerSecond){let scrollSpeed=pxPerSecond/1e3,currentPos=0,lastTime=0,smoother=0;window.requestAnimationFrame(function step(timestamp){let delta=Math.min(150,Math.max(0,timestamp-lastTime));smoother+=(delta-smoother)*.02;let moveDelta=smoother*scrollSpeed;lastTime=timestamp,currentPos+=moveDelta;let targetPos=container.scrollHeight-container.clientHeight;running&¤tPoswithDirectives((openBlock(),createElementBlock(`div`,{ref_key:`wrapper`,ref:wrapper,class:`bng-credits-wrapper`,tabindex:`0`,onKeypress:exit,"bng-ui-scope":`credits`},[createBaseVNode(`div`,_hoisted_1$119,[createBaseVNode(`img`,{class:`logo`,src:unref(imageURL),alt:``},null,8,_hoisted_2$99),(openBlock(!0),createElementBlock(Fragment,null,renderList(unref(data_default),(category,cIndex)=>(openBlock(),createElementBlock(`div`,{key:cIndex},[createBaseVNode(`div`,_hoisted_3$87,[createBaseVNode(`span`,null,toDisplayString(_ctx.$t(category.translateId)),1)]),createBaseVNode(`div`,_hoisted_4$67,[(openBlock(!0),createElementBlock(Fragment,null,renderList(category.members,(member,mIndex)=>(openBlock(),createElementBlock(`div`,{class:`member-row`,key:mIndex},[createBaseVNode(`span`,_hoisted_5$57,[createTextVNode(toDisplayString(member.first)+` `,1),member.aka?(openBlock(),createElementBlock(`span`,_hoisted_6$44,toDisplayString(`<`+member.aka+`>`),1)):(openBlock(),createElementBlock(`span`,_hoisted_7$37,`\xA0`)),createTextVNode(` `+toDisplayString(member.last),1)]),member.title?(openBlock(),createElementBlock(`span`,_hoisted_8$30,` . `)):(openBlock(),createElementBlock(`span`,_hoisted_9$27,`\xA0`)),member.title?(openBlock(),createElementBlock(`span`,_hoisted_10$21,toDisplayString(_ctx.$t(member.title)),1)):(openBlock(),createElementBlock(`span`,_hoisted_11$19,`\xA0`))]))),128))])]))),128)),_cache[0]||=createBaseVNode(`div`,{style:{"padding-top":`70vh`}},null,-1)])],32)),[[unref(BngOnUiNav_default),exit,`menu,back`]])}},CreditsScroller_default=__plugin_vue_export_helper_default(_sfc_main$132,[[`__scopeId`,`data-v-9c2fdcd3`]]),routes_default$4=[{path:`/credits`,name:`credits`,component:CreditsScroller_default}],_hoisted_1$118={class:`details`,"bng-nav-scroll":``},_hoisted_2$98={key:0,class:`header-content`},_hoisted_3$86={key:1,class:`preview`},_hoisted_4$66={key:2,class:`tags-section`},_hoisted_5$56={class:`tags-container`},_hoisted_6$43=[`onClick`],_hoisted_7$36=[`src`],_hoisted_8$29={key:3,class:`description`},_hoisted_9$26={key:0,class:`specs-grid`},_hoisted_10$20={class:`specs-grid-container`},_hoisted_11$18={class:`spec-content`},_hoisted_12$14={class:`spec-label`},_hoisted_13$13={class:`spec-value`},_hoisted_14$13={key:0,class:`bottom-section`},_hoisted_15$13={class:`buttons-section`},_hoisted_16$13={key:1,class:`button-container`},_sfc_main$131={__name:`GameplayDetails`,props:{activeItem:{type:Object,default:null},activeItemDetails:{type:Object,default:null},executeButton:{type:Function,default:()=>{}},toggleFavourite:{type:Function,default:()=>{}},exploreFolder:{type:Function,default:()=>{}},goToMod:{type:Function,default:()=>{}},showHeaderTitle:{type:Boolean,default:!0},inline:{type:Boolean,default:!1},buttonOverride:{type:Object,default:null}},setup(__props){let props=__props,handleButtonClick=buttonId=>{props.executeButton(buttonId)};return(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,{class:normalizeClass([`gameplay-details`,{inline:__props.inline}])},[withDirectives((openBlock(),createElementBlock(`div`,_hoisted_1$118,[__props.activeItemDetails?.headerTitle?(openBlock(),createElementBlock(`div`,_hoisted_2$98,[__props.showHeaderTitle?(openBlock(),createBlock(unref(bngCardHeading_default),{key:0,type:`none`,class:`header-title`},{default:withCtx(()=>[createTextVNode(toDisplayString(__props.activeItemDetails.headerTitle),1)]),_:1})):createCommentVNode(``,!0),__props.activeItemDetails?.preview?(openBlock(),createElementBlock(`div`,_hoisted_3$86,[createVNode(unref(aspectRatio_default),{class:normalizeClass([`preview-image`,{"has-header-title":__props.showHeaderTitle}]),ratio:`16:8`,"external-image":__props.activeItemDetails.preview},{default:withCtx(()=>[__props.inline?createCommentVNode(``,!0):(openBlock(),createBlock(unref(bngIcon_default),{key:0,class:`favourite-icon`,type:__props.activeItemDetails?.isFavourite?`star`:`starSecondary`,onClick:_cache[0]||=$event=>__props.toggleFavourite(__props.activeItem),color:__props.activeItemDetails?.isFavourite?`var(--bng-ter-yellow-50)`:`var(--bng-cool-gray-100)`},null,8,[`type`,`color`]))]),_:1},8,[`external-image`,`class`])])):createCommentVNode(``,!0),__props.activeItemDetails?.tags?.length>0?(openBlock(),createElementBlock(`div`,_hoisted_4$66,[createBaseVNode(`div`,_hoisted_5$56,[(openBlock(!0),createElementBlock(Fragment,null,renderList(__props.activeItemDetails.tags,tag=>(openBlock(),createElementBlock(`div`,{key:tag.key||tag.label,class:normalizeClass([`tag-item`,{clickable:tag.goToMod}]),onClick:$event=>tag.goToMod?__props.goToMod(tag.goToMod):null},[tag.icon?(openBlock(),createBlock(unref(bngIcon_default),{key:0,type:tag.icon},null,8,[`type`])):createCommentVNode(``,!0),tag.svg?(openBlock(),createElementBlock(`img`,{key:1,class:`svg-icon`,src:tag.svg},null,8,_hoisted_7$36)):createCommentVNode(``,!0),createTextVNode(` `+toDisplayString(tag.label),1)],10,_hoisted_6$43))),128))])])):createCommentVNode(``,!0),__props.activeItemDetails?.description?(openBlock(),createElementBlock(`div`,_hoisted_8$29,toDisplayString(__props.activeItemDetails.description),1)):createCommentVNode(``,!0)])):createCommentVNode(``,!0),__props.activeItemDetails?.buttonInfo?.length>0||__props.activeItemDetails?.bottomTags?.length>0?(openBlock(!0),createElementBlock(Fragment,{key:1},renderList(__props.activeItemDetails?.specifications,(specList,specListIndex)=>(openBlock(),createElementBlock(Fragment,{key:specListIndex},[specList.length>0?(openBlock(),createElementBlock(`div`,_hoisted_9$26,[createBaseVNode(`div`,_hoisted_10$20,[(openBlock(!0),createElementBlock(Fragment,null,renderList(specList,specification=>(openBlock(),createElementBlock(`div`,{key:specification.key,class:`spec-cell`},[specification.icon?(openBlock(),createBlock(unref(bngIcon_default),{key:0,type:specification.icon,class:`spec-icon`},null,8,[`type`])):createCommentVNode(``,!0),createBaseVNode(`div`,_hoisted_11$18,[createBaseVNode(`div`,_hoisted_12$14,toDisplayString(specification.label)+`:`,1),createBaseVNode(`div`,_hoisted_13$13,[createBaseVNode(`span`,null,toDisplayString(specification.value),1)])])]))),128))])])):createCommentVNode(``,!0)],64))),128)):createCommentVNode(``,!0)])),[[unref(BngUiNavScroll_default),void 0,void 0,{force:!0}]]),__props.activeItemDetails?.buttonInfo?.length>0||__props.buttonOverride?(openBlock(),createElementBlock(`div`,_hoisted_14$13,[createBaseVNode(`div`,_hoisted_15$13,[__props.buttonOverride?createCommentVNode(``,!0):(openBlock(!0),createElementBlock(Fragment,{key:0},renderList(__props.activeItemDetails.buttonInfo,button=>(openBlock(),createElementBlock(`div`,{key:button.buttonId,class:`button-container`},[createVNode(unref(bngButton_default),{"bng-scoped-nav-autofocus":button.primary,accent:button.primary?`main`:`secondary`,label:button.label,icon:button.icon,onClick:$event=>handleButtonClick(button.buttonId)},null,8,[`bng-scoped-nav-autofocus`,`accent`,`label`,`icon`,`onClick`])]))),128)),__props.buttonOverride?(openBlock(),createElementBlock(`div`,_hoisted_16$13,[createVNode(unref(bngButton_default),{"bng-scoped-nav-autofocus":!0,accent:`main`,label:__props.buttonOverride.label,icon:__props.buttonOverride.icon,onClick:_cache[1]||=$event=>__props.buttonOverride.click(__props.activeItem)},null,8,[`label`,`icon`])])):createCommentVNode(``,!0)])])):createCommentVNode(``,!0)],2))}},GameplayDetails_default=__plugin_vue_export_helper_default(_sfc_main$131,[[`__scopeId`,`data-v-7baeb809`]]),_hoisted_1$117=[`bng-ui-scope`],_hoisted_2$97={class:`popup-content`},_hoisted_3$85={class:`modal-header`},_hoisted_4$65={class:`vehicle-selector-section`},_hoisted_5$55={class:`vehicle-tile-wrapper`},_hoisted_6$42={class:`modal-content`},_hoisted_7$35={class:`spawnpoint-section`},_hoisted_8$28={class:`spawnpoint-info`},_hoisted_9$25={key:0,class:`spawnpoint-preview`},_hoisted_10$19=[`src`],_hoisted_11$17={class:`spawnpoint-name`},_hoisted_12$13={key:0,class:`config-section`},_hoisted_13$12={class:`group-title`},_hoisted_14$12={key:0},_hoisted_15$12={class:`always-show-section`},_hoisted_16$12={key:0,class:`modal-footer`},_sfc_main$130={__name:`LevelConfigurationModal`,props:{levelData:{type:Object,required:!0}},emits:[`return`],setup(__props,{emit:__emit}){useUINavBlocker().allowNavigationOnly();let{lua,events:events$3}=useBridge(),props=__props,emit$1=__emit,scopeName=usePopupUINavScopeName(`_levelConfigPopup`,props);provide(`gridSelectionState`,ref(null));let spawningOptions=ref([]),config=reactive({}),alwaysShowDialogue=ref(!1),vehicleTile=ref({}),loadSpawningOptions=async()=>{try{let levelName=props.levelData?.levelName,backendName=props.levelData?.backendName,result=await lua.ui_gameplaySelector_tileGenerators_levelTiles.getSpawningOptions(levelName,backendName);if(result){let options=result.options||[];spawningOptions.value=options,alwaysShowDialogue.value=result.alwaysShowDialogue||!1,result.vehicleTile?vehicleTile.value={key:`vehicle-selector`,name:result.vehicleTile.name||`Select Vehicle`,preview:result.vehicleTile.preview||`/ui/modules/vehicleSelector/placeholder.png`,sourceIcons:result.vehicleTile.sourceIcons||[]}:vehicleTile.value={key:`vehicle-selector`,name:`Select Vehicle`,preview:`/ui/modules/vehicleSelector/placeholder.png`,sourceIcons:[]},options.forEach(group=>{group.options&&Array.isArray(group.options)&&group.options.forEach(option=>{option.key&&option.value!==void 0&&(config[option.key]=option.value)})})}}catch(error){console.error(`Failed to load spawning options:`,error)}},handleOptionChange=async(key,newValue)=>{try{await lua.ui_gameplaySelector_tileGenerators_levelTiles.changeSpawningOption(key,newValue),events$3.emit(`gridSelectorRefreshCurrentItemDetails`,`freeroamSelector`)}catch(error){console.error(`Failed to update ${key} option:`,error)}},handleAlwaysShowDialogueChange=async newValue=>{try{let backendName=props.levelData?.backendName;await lua.ui_gameplaySelector_tileGenerators_levelTiles.setAlwaysShowDialogue(backendName,newValue),events$3.emit(`gridSelectorRefreshCurrentItemDetails`,`freeroamSelector`)}catch(error){console.error(`Failed to save default action preference:`,error)}},openVehicleSelector=async()=>{try{await lua.ui_vehicleSelector_general.openVehicleSelectorForFreeroamModal(),emit$1(`return`,!0)}catch(e){console.error(`Failed to open vehicle selector:`,e)}};onMounted(()=>{loadSpawningOptions()});let closeModal=()=>{emit$1(`return`,!1)},handleButtonClick=buttonId=>{closeModal(),events$3.emit(`gridSelectorExecuteButton`,`freeroamSelector`,buttonId)},handleCancelWithBack=()=>{closeModal()};return(_ctx,_cache)=>withDirectives((openBlock(),createElementBlock(`div`,{class:`level-configuration-modal popup`,"bng-ui-scope":unref(scopeName)},[createBaseVNode(`div`,_hoisted_2$97,[createBaseVNode(`div`,_hoisted_3$85,[_cache[1]||=createBaseVNode(`h2`,null,`Freeroam Spawning Options`,-1),createVNode(unref(bngIcon_default),{type:`xmarkBold`,class:`close-button`,onClick:closeModal,color:`var(--bng-cool-gray-100)`})]),createBaseVNode(`div`,_hoisted_4$65,[_cache[2]||=createBaseVNode(`h3`,{class:`group-title`},`Vehicle`,-1),createBaseVNode(`div`,_hoisted_5$55,[createTextVNode(toDisplayString(vehicleTile.value)+` `,1),createVNode(Tile_default,{tile:vehicleTile.value,displaySize:`small`,isConfig:!0,onClick:openVehicleSelector},null,8,[`tile`])])]),createBaseVNode(`div`,_hoisted_6$42,[createBaseVNode(`div`,_hoisted_7$35,[_cache[3]||=createBaseVNode(`h3`,null,`Selected Spawnpoint`,-1),createBaseVNode(`div`,_hoisted_8$28,[__props.levelData?.spawnPoint?.previews?.[0]?(openBlock(),createElementBlock(`div`,_hoisted_9$25,[createBaseVNode(`img`,{src:__props.levelData.spawnPoint.previews[0],alt:`Spawnpoint preview`},null,8,_hoisted_10$19)])):createCommentVNode(``,!0),createBaseVNode(`div`,_hoisted_11$17,toDisplayString(_ctx.$tt(__props.levelData?.spawnPoint?.translationId||`No Name?`)),1)])]),spawningOptions.value.length>0?(openBlock(),createElementBlock(`div`,_hoisted_12$13,[(openBlock(!0),createElementBlock(Fragment,null,renderList(spawningOptions.value,group=>(openBlock(),createElementBlock(`div`,{class:`config-group`,key:group.name},[createBaseVNode(`h3`,_hoisted_13$12,toDisplayString(group.name),1),(openBlock(!0),createElementBlock(Fragment,null,renderList(group.options,option=>(openBlock(),createElementBlock(`div`,{class:`config-item`,key:option.key},[option.label?(openBlock(),createElementBlock(`label`,_hoisted_14$12,[option.icon?(openBlock(),createBlock(unref(bngIcon_default),{key:0,type:option.icon,class:`option-icon`},null,8,[`type`])):createCommentVNode(``,!0),createTextVNode(` `+toDisplayString(option.label)+`: `,1)])):createCommentVNode(``,!0),createVNode(unref(bngSelect_default),{modelValue:config[option.key],"onUpdate:modelValue":[$event=>config[option.key]=$event,newValue=>handleOptionChange(option.key,newValue)],options:option.options,loop:``,config:{value:opt=>opt.value,label:opt=>opt.label}},null,8,[`modelValue`,`onUpdate:modelValue`,`options`,`config`])]))),128))]))),128))])):createCommentVNode(``,!0)]),createBaseVNode(`div`,_hoisted_15$12,[createVNode(unref(bngSwitch_default),{modelValue:alwaysShowDialogue.value,"onUpdate:modelValue":[_cache[0]||=$event=>alwaysShowDialogue.value=$event,handleAlwaysShowDialogueChange],label:`Always show this dialogue`,labelBefore:``},null,8,[`modelValue`])]),spawningOptions.value.length>0||__props.levelData?.buttonInfo&&__props.levelData.buttonInfo.length>0?(openBlock(),createElementBlock(`div`,_hoisted_16$12,[__props.levelData?.buttonInfo&&__props.levelData.buttonInfo.length>0?(openBlock(!0),createElementBlock(Fragment,{key:0},renderList(__props.levelData.buttonInfo,button=>(openBlock(),createBlock(unref(bngButton_default),{key:button.buttonId,label:button.label,icon:button.icon,accent:button.primary?`main`:`secondary`,onClick:$event=>handleButtonClick(button.buttonId)},null,8,[`label`,`icon`,`accent`,`onClick`]))),128)):createCommentVNode(``,!0)])):createCommentVNode(``,!0)])],8,_hoisted_1$117)),[[unref(BngOnUiNav_default),handleCancelWithBack,`back,menu`]])}},LevelConfigurationModal_default=__plugin_vue_export_helper_default(_sfc_main$130,[[`__scopeId`,`data-v-ec35f32c`]]),_sfc_main$129={__name:`FreeroamSelector`,setup(__props){let{events:events$3}=useBridge(),handleOpenLevelConfigPopup=data=>{addPopup(LevelConfigurationModal_default,{levelData:data}).promise};return onMounted(()=>{events$3.on(`openLevelConfigurationPopup`,handleOpenLevelConfigPopup)}),onUnmounted(()=>{events$3.off(`openLevelConfigurationPopup`,handleOpenLevelConfigPopup)}),(_ctx,_cache)=>(openBlock(),createBlock(GridSelector_default,{backendName:`freeroamSelector`,routePath:`/freeroam-selector`,defaultPath:{keys:[`allFreeroam`]},defaultDetailsMode:`detail`,hiddenTabs:[`filter`]},{"item-details":withCtx(({activeItem,activeItemDetails,executeButton,toggleFavourite,exploreFolder,goToMod})=>[createVNode(GameplayDetails_default,{activeItem,activeItemDetails,executeButton,toggleFavourite,exploreFolder,goToMod},null,8,[`activeItem`,`activeItemDetails`,`executeButton`,`toggleFavourite`,`exploreFolder`,`goToMod`])]),_:1}))}},FreeroamSelector_default=_sfc_main$129,_hoisted_1$116={class:`preview`},_hoisted_2$96={key:0,class:`general-tags`},_hoisted_3$84={key:1,class:`icon-text-tag`},_hoisted_4$64={class:`vehicle-text-header`},_hoisted_5$54={key:0,class:`general-specs`},_hoisted_6$41={key:1,class:`divider`},_hoisted_7$34={class:`vehicle-tags`},_hoisted_8$27=[`onClick`],_hoisted_9$24=[`src`],_hoisted_10$18={key:0,class:`source-icon-container`},_hoisted_11$16={key:1,class:`source-icon-container`},_hoisted_12$12={key:2,class:`source-icon-container auxiliary-icon`},_hoisted_13$11={key:2,class:`vehicle-description`},_hoisted_14$11={class:`specs-grid-container`},_hoisted_15$11={key:0,class:`spec-label`},_hoisted_16$11={class:`spec-value`},_hoisted_17$10={key:1,class:`spec-value`},_hoisted_18$8={key:0,class:`bottom-section`},_hoisted_19$6={class:`paint-list expanded`},_sfc_main$128={__name:`VehicleDetails`,props:{activeItem:{type:Object,default:null},activeItemDetails:{type:Object,default:null},executeButton:{type:Function,default:()=>{}},toggleFavourite:{type:Function,default:()=>{}},exploreFolder:{type:Function,default:()=>{}},goToMod:{type:Function,default:()=>{}},showHeaderTitle:{type:Boolean,default:!0},hideDetailsAndButtons:{type:Boolean,default:!1},inline:{type:Boolean,default:!1},buttonOverride:{type:Object,default:null}},emits:[`focus-item`],setup(__props,{emit:__emit}){let{showIfController}=storeToRefs(controls_default()),props=__props,emit$1=__emit,handleButtonClick=buttonId=>{let additionalData={};selectedMultiPaint.value&&(additionalData.paint=selectedMultiPaint.value.paintNames[0],additionalData.paint2=selectedMultiPaint.value.paintNames[1],additionalData.paint3=selectedMultiPaint.value.paintNames[2]),selectedPaint.value&&(additionalData.paint=selectedPaint.value.name),props.executeButton(buttonId,additionalData),emit$1(`button-click`,buttonId)},toggleFavourite=()=>{props.activeItem&&props.toggleFavourite(props.activeItem)},openFolder=path=>{props.exploreFolder(path)},goToMod=modId=>{props.goToMod(modId)},sortedFactoryPaints=computed(()=>{let factoryPaints=props.activeItemDetails?.paints?.factoryPaints;return Array.isArray(factoryPaints)?sortColors(factoryPaints).filter(paint=>paint&&paint.name):[]}),multiPaints=computed(()=>{let res=[],multiPaintSetups=props.activeItemDetails?.paints?.multiPaintSetups,factoryPaints=props.activeItemDetails?.paints?.factoryPaints;if(!Array.isArray(multiPaintSetups)||!Array.isArray(factoryPaints))return res;for(let i=0;iname&&factoryPaints.find(paint=>paint.name===name)||null).filter(paint=>paint!==null);paints.length>0&&res.push({id:paintNames.join(`|`),name:setup$3.name,paintNames,paints,applyAll:()=>applyMultipaint(setup$3)})}return res}),hasPaintData=computed(()=>props.activeItemDetails?.additionalData?.paint&&props.activeItemDetails?.paints?.factoryPaints),paintData=computed(()=>{if(!hasPaintData.value)return null;let additionalData=props.activeItemDetails.additionalData,factoryPaints=props.activeItemDetails.paints.factoryPaints,paintNames=[additionalData.paint,additionalData.paint2,additionalData.paint3].filter(name=>name),paints=paintNames.map(name=>{let paint=factoryPaints.find(p$1=>p$1.name===name);return paint?convertPaintToTileFormat(paint):null}).filter(paint=>paint!==null);return paints.length===0?null:{paint:paintNames[0],paintNames,paints}});function applyMultipaint(setup$3){selectedMultiPaint.value=setup$3,selectedPaint.value=null}let selectedMultiPaint=ref(null),selectedPaint=ref(null);ref(!1);let handleMultiPaintClick=(multiPaint,focus$1=!0)=>{selectedMultiPaint.value=multiPaints.value.find(mp=>mp.name===multiPaint.name),selectedPaint.value=null,focus$1&&emit$1(`focus-item`,`multiPaints`)},handlePaintClick=paint=>{selectedPaint.value=paint,selectedMultiPaint.value=null,emit$1(`focus-item`,`paints`)},convertPaintToTileFormat=paint=>{if(!paint)return null;if(paint.baseColor&&paint.paintString)return paint;try{let paintObj=new Paint;return paintObj.paint=paint,paintObj.paintObject}catch(error){return console.warn(`Failed to convert paint:`,paint,error),null}},selectDefaultMultiPaint=()=>{if(!props.activeItemDetails?.paints)return;let multiPaintSetups=props.activeItemDetails?.paints.multiPaintSetups;if(Array.isArray(multiPaintSetups)&&multiPaintSetups.length>0){let defaultMultiPaintSetup=multiPaintSetups.find(setup$3=>setup$3.isDefault);if(defaultMultiPaintSetup){let multiPaintsObj=multiPaints.value.find(mp=>mp.name===defaultMultiPaintSetup.name);if(multiPaintsObj){handleMultiPaintClick(multiPaintsObj,!1);return}}}};watch(()=>props.activeItemDetails,()=>{selectDefaultMultiPaint()}),onMounted(()=>{selectDefaultMultiPaint()});function average(arr){return arr.reduce((a$1,b)=>a$1+b)/arr.length}function valComparable(col,thres=.05){let bool=!0,av=average(col);for(let i=0;i=col[i];return bool&&=av>.8||av<.2,bool}function colorHigherHelper(itm){if(!itm||!itm.orig||!itm.orig.baseColor||!Array.isArray(itm.orig.baseColor)||itm.orig.baseColor.length<4)return 0;let av=average(itm.orig.baseColor.slice(0,3)),al=itm.orig.baseColor[3]/2,res=Math.abs(av-1)*al;return res===0?(av+al)/2:res+1}function colorHigher(a$1,b){if(!a$1||!b||!a$1.orig||!b.orig||!a$1.orig.baseColor||!b.orig.baseColor)return 0;let aColor=valComparable(a$1.orig.baseColor.slice(0,3)),bColor=valComparable(b.orig.baseColor.slice(0,3));if(aColor&&bColor)return colorHigherHelper(b)-colorHigherHelper(a$1);if(aColor&&!bColor)return 1;if(!aColor&&bColor)return-1;for(let i=0;i<3;i++)if(a$1.val[i]!==b.val[i])return a$1.val[i]-b.val[i];return 0}function colorValue(arr){if(!Array.isArray(arr)||arr.length<4)return[0,0,0,0];let repitions=8,rgb=[];for(let i=0;i<3;i++)rgb[i]=(1-arr[3]/2)*arr[i]+arr[3]/2*arr[i];let lum=Math.sqrt(.241*rgb[0]+.691*rgb[1]+.068*rgb[2]),hsl=Paint.rgbToHsl(rgb),out=[hsl[0],lum,hsl[1]].map(elem=>elem*8);return out[0]%2==1&&(out[1]=8-out[1],out[2]=8-out[2]),out.push(arr[3]),out}function sortColors(list){return Array.isArray(list)?list.filter(elem=>elem&&elem.baseColor&&Array.isArray(elem.baseColor)&&elem.baseColor.length>=4).map(elem=>({val:colorValue(elem.baseColor),orig:elem})).sort(colorHigher).map(elem=>elem.orig):[]}return(_ctx,_cache)=>(openBlock(),createElementBlock(Fragment,null,[withDirectives((openBlock(),createElementBlock(`div`,{class:normalizeClass([`details`,{inline:__props.inline}]),"bng-nav-scroll":``},[createBaseVNode(`div`,_hoisted_1$116,[__props.showHeaderTitle?(openBlock(),createBlock(bngCardHeading_default,{key:0,type:`none`,class:`header-title`},{default:withCtx(()=>[createTextVNode(toDisplayString(__props.activeItemDetails.headerTitle),1)]),_:1})):createCommentVNode(``,!0),createBaseVNode(`div`,{class:normalizeClass([`tags-and-preview`,{"has-header-title":__props.showHeaderTitle}])},[__props.activeItemDetails?.iconTags?.length>0?(openBlock(),createElementBlock(`div`,_hoisted_2$96,[(openBlock(!0),createElementBlock(Fragment,null,renderList(__props.activeItemDetails?.iconTags,icon=>(openBlock(),createBlock(bngTooltip_default,{key:icon.icon,text:icon.label,position:`left`},{default:withCtx(()=>[icon.icon?(openBlock(),createBlock(unref(bngIcon_default),{key:0,type:icon.icon,label:icon.label,onClick:$event=>goToMod(icon.goToMod),class:normalizeClass({"favourite-icon":icon.goToMod})},null,8,[`type`,`label`,`onClick`,`class`])):createCommentVNode(``,!0),icon.iconText?(openBlock(),createElementBlock(`span`,_hoisted_3$84,toDisplayString(icon.iconText),1)):createCommentVNode(``,!0)]),_:2},1032,[`text`]))),128))])):createCommentVNode(``,!0),createVNode(unref(aspectRatio_default),{class:normalizeClass([`preview-image`,{"has-header-title":__props.showHeaderTitle}]),ratio:`16:8`,"external-image":__props.activeItemDetails?.preview},{default:withCtx(()=>[__props.inline?createCommentVNode(``,!0):(openBlock(),createBlock(unref(bngIcon_default),{key:0,class:`favourite-icon`,type:__props.activeItemDetails?.isFavourite?`star`:`starSecondary`,onClick:toggleFavourite,color:__props.activeItemDetails?.isFavourite?`var(--bng-ter-yellow-50)`:`var(--bng-cool-gray-100)`},null,8,[`type`,`color`])),hasPaintData.value?(openBlock(),createBlock(unref(bngPaintTile_default),{key:1,"paint-id":`${__props.activeItem?.id||`vehicle`}:${paintData.value.paint}`,paint:paintData.value.paints,"paint-name":paintData.value.paintNames.join(`, `),width:56,height:24,class:`preview-paint-tile`,"bng-no-nav":`true`,tabindex:`-1`},null,8,[`paint-id`,`paint`,`paint-name`])):createCommentVNode(``,!0)]),_:1},8,[`class`,`external-image`])],2)]),createBaseVNode(`div`,_hoisted_4$64,[__props.activeItemDetails?.generalSpecs?.length>0?(openBlock(),createElementBlock(`div`,_hoisted_5$54,[(openBlock(!0),createElementBlock(Fragment,null,renderList(__props.activeItemDetails?.generalSpecs,spec=>(openBlock(),createElementBlock(`div`,{class:`spec-value`,key:spec.key},[Array.isArray(spec.value)?(openBlock(),createElementBlock(Fragment,{key:0},[createTextVNode(toDisplayString(_ctx.$tt(spec.value[0].text)),1)],64)):(openBlock(),createElementBlock(Fragment,{key:1},[createTextVNode(toDisplayString(spec.value),1)],64))]))),128))])):createCommentVNode(``,!0),__props.activeItemDetails?.generalSpecs.length>0?(openBlock(),createElementBlock(`div`,_hoisted_6$41)):createCommentVNode(``,!0),createBaseVNode(`div`,_hoisted_7$34,[(openBlock(!0),createElementBlock(Fragment,null,renderList(__props.activeItemDetails?.tags,tag=>(openBlock(),createElementBlock(`div`,{key:tag.key,class:normalizeClass([`source-icon-container`,{"auxiliary-icon":tag.auxiliary}]),onClick:$event=>_ctx.tagClicked(tag)},[tag.icon?(openBlock(),createBlock(unref(bngIcon_default),{key:0,type:tag.icon},null,8,[`type`])):createCommentVNode(``,!0),tag.svg?(openBlock(),createElementBlock(`img`,{key:1,class:`svg-icon`,src:tag.svg},null,8,_hoisted_9$24)):createCommentVNode(``,!0),createTextVNode(` `+toDisplayString(tag.label),1)],10,_hoisted_8$27))),128)),__props.activeItemDetails?.sourceIcon?(openBlock(),createElementBlock(`div`,_hoisted_10$18,[createVNode(unref(bngIcon_default),{type:__props.activeItemDetails?.sourceIcon.icon,onClick:_cache[0]||=$event=>goToMod(__props.activeItemDetails?.sourceIcon.goToMod)},null,8,[`type`]),createTextVNode(` `+toDisplayString(__props.activeItemDetails?.sourceIcon.label),1)])):createCommentVNode(``,!0),__props.activeItemDetails?.isFavourite?(openBlock(),createElementBlock(`div`,_hoisted_11$16,[createVNode(unref(bngIcon_default),{type:`star`,onClick:toggleFavourite}),_cache[2]||=createTextVNode(` Favourite`,-1)])):createCommentVNode(``,!0),__props.activeItemDetails?.configDetails.isAuxiliary?(openBlock(),createElementBlock(`div`,_hoisted_12$12,[createVNode(unref(bngIcon_default),{type:`bug`}),_cache[3]||=createTextVNode(` Auxiliary`,-1)])):createCommentVNode(``,!0)]),__props.activeItemDetails?.configDetails?.Description?(openBlock(),createElementBlock(`div`,_hoisted_13$11,toDisplayString(__props.activeItemDetails?.configDetails?.Description),1)):createCommentVNode(``,!0)]),__props.activeItemDetails?.configDetails&&!__props.hideDetailsAndButtons?(openBlock(!0),createElementBlock(Fragment,{key:0},renderList(__props.activeItemDetails?.specificationsList,(value,key)=>(openBlock(),createElementBlock(`div`,{key,class:`specs-grid`},[createBaseVNode(`div`,_hoisted_14$11,[(openBlock(!0),createElementBlock(Fragment,null,renderList(value.specifications,specification=>(openBlock(),createElementBlock(`div`,{key:specification.key,class:normalizeClass([`spec-cell`,{"full-width":!specification.key}])},[specification.key?(openBlock(),createElementBlock(`div`,_hoisted_15$11,toDisplayString(specification.key)+`:`,1)):createCommentVNode(``,!0),createBaseVNode(`div`,_hoisted_16$11,[Array.isArray(specification.value)?(openBlock(!0),createElementBlock(Fragment,{key:0},renderList(specification.value,(item,index)=>(openBlock(),createElementBlock(`div`,{key:index,class:normalizeClass([`spec-value-item`,{italic:item.italic}])},[createBaseVNode(`span`,null,toDisplayString(item.text),1),specification.postIcon?(openBlock(),createBlock(unref(bngIcon_default),{key:0,class:`spec-post-icon`,type:specification.postIcon},null,8,[`type`])):createCommentVNode(``,!0),specification.openFolder?(openBlock(),createBlock(unref(bngIcon_default),{key:1,class:`spec-post-icon`,type:`folder`,onClick:$event=>openFolder(specification.value)},null,8,[`onClick`])):createCommentVNode(``,!0)],2))),128)):(openBlock(),createElementBlock(`div`,_hoisted_17$10,[createBaseVNode(`span`,null,toDisplayString(specification.value),1),specification.postIcon?(openBlock(),createBlock(unref(bngIcon_default),{key:0,class:`spec-post-icon`,type:specification.postIcon},null,8,[`type`])):createCommentVNode(``,!0),specification.openFolder?(openBlock(),createBlock(unref(bngIcon_default),{key:1,class:`spec-post-icon`,type:`folder`,onClick:$event=>openFolder(specification.value)},null,8,[`onClick`])):createCommentVNode(``,!0)]))])],2))),128))])]))),128)):createCommentVNode(``,!0)],2)),[[unref(BngUiNavScroll_default),void 0,void 0,{force:!0}]]),__props.hideDetailsAndButtons?createCommentVNode(``,!0):(openBlock(),createElementBlock(`div`,_hoisted_18$8,[createBaseVNode(`div`,_hoisted_19$6,[(openBlock(!0),createElementBlock(Fragment,null,renderList(multiPaints.value,multiPaint=>(openBlock(),createBlock(unref(bngPaintTile_default),{key:multiPaint.name,"paint-id":`${__props.activeItem?.id||`vehicle`}:${multiPaint.name}`,paint:multiPaint.paints,"paint-name":multiPaint.name,"paint-names":multiPaint.paintNames,width:56,height:24,class:normalizeClass([`multi-paint-item`,{selected:selectedMultiPaint.value?.name===multiPaint.name}]),onClick:$event=>handleMultiPaintClick(multiPaint)},null,8,[`paint-id`,`paint`,`paint-name`,`paint-names`,`class`,`onClick`]))),128)),(openBlock(!0),createElementBlock(Fragment,null,renderList(sortedFactoryPaints.value,paint=>(openBlock(),createElementBlock(Fragment,{key:paint.name},[paint&&paint.class===`factory`&&paint.name?(openBlock(),createBlock(unref(bngPaintTile_default),{key:0,"paint-id":`${__props.activeItem?.id||`vehicle`}:${paint.name}`,paint:convertPaintToTileFormat(paint),"vehicle-name":`factory`,"paint-name":paint.name,width:24,height:24,class:normalizeClass([`paint-item`,{selected:selectedPaint.value===paint}]),onClick:$event=>handlePaintClick(paint)},null,8,[`paint-id`,`paint`,`paint-name`,`class`,`onClick`])):createCommentVNode(``,!0)],64))),128))]),__props.activeItemDetails?.buttonInfo&&!__props.buttonOverride?(openBlock(!0),createElementBlock(Fragment,{key:0},renderList(__props.activeItemDetails?.buttonInfo,button=>(openBlock(),createBlock(unref(bngButton_default),{key:button.buttonId,"bng-scoped-nav-autofocus":button.primary,accent:button.primary?`main`:`secondary`,label:button.label,icon:button.icon,onClick:$event=>handleButtonClick(button.buttonId)},null,8,[`bng-scoped-nav-autofocus`,`accent`,`label`,`icon`,`onClick`]))),128)):createCommentVNode(``,!0),__props.buttonOverride?(openBlock(),createBlock(unref(bngButton_default),{key:1,"bng-scoped-nav-autofocus":!0,accent:`main`,label:__props.buttonOverride.label,icon:__props.buttonOverride.icon,onClick:_cache[1]||=$event=>__props.buttonOverride.click(__props.activeItem,selectedPaint.value,selectedMultiPaint.value)},null,8,[`label`,`icon`])):createCommentVNode(``,!0)]))],64))}},VehicleDetails_default=__plugin_vue_export_helper_default(_sfc_main$128,[[`__scopeId`,`data-v-58d013e3`]]);function useFreeroamConfigurator(){let{events:events$3}=useBridge(),configData=ref(null),button=ref(null),error=ref(null),isInitializing=ref(!1),refreshConfigHandler=()=>{logger_default.debug(`freeroamConfiguratorRefreshConfig`),loadConfiguration()},refreshButtonHandler=()=>{logger_default.debug(`freeroamConfiguratorRefreshButton`),loadButtons()};events$3.on(`freeroamConfiguratorRefreshConfig`,refreshConfigHandler),events$3.on(`freeroamConfiguratorRefreshButton`,refreshButtonHandler);let loadButtons=async()=>{try{let buttonData=await Lua_default.freeroam_freeroamConfigurator.getButtons();button.value=buttonData||null,logger_default.debug(`Loaded button:`,buttonData)}catch(err){logger_default.error(`Failed to load button:`,err),error.value=err}},loadConfiguration=async()=>{try{error.value=null;let data=await Lua_default.freeroam_freeroamConfigurator.getConfiguration();data?.options&&processOptionsTree(data.options),configData.value=data,logger_default.debug(`Loaded configuration:`,data),await loadButtons()}catch(err){logger_default.error(`Failed to load freeroam configuration:`,err),error.value=err}},processOptionsTree=options=>{!options||!Array.isArray(options)||options.forEach(group=>{group.key&&(group.onChange=val=>{group.value=val,handleOptionChange(group.key,val)}),Object.defineProperty(group,`enabled`,{get(){return!this.key||!!this.value},enumerable:!0,configurable:!0}),group.options&&Array.isArray(group.options)&&group.options.forEach(option=>{option.key&&(option.onChange=val=>{option.value=val,handleOptionChange(option.key,val)})})})},onSpawnPointTileClick=async()=>{try{await Lua_default.freeroam_freeroamConfigurator.onSpawnPointTileClick(),logger_default.debug(`Spawn point tile clicked`)}catch(err){logger_default.error(`Failed to handle spawnpoint tile click:`,err),error.value=err}},onVehicleTileClick=async()=>{try{await Lua_default.freeroam_freeroamConfigurator.onVehicleTileClick(),logger_default.debug(`Vehicle tile clicked`)}catch(err){logger_default.error(`Failed to handle vehicle tile click:`,err),error.value=err}},updateOption=async(key,value)=>{try{await Lua_default.freeroam_freeroamConfigurator.updateOption(key,value),logger_default.debug(`Updated option ${key}:`,value)}catch(err){logger_default.error(`Failed to update option ${key}:`,err),error.value=err}},handleOptionChange=async(key,newValue)=>{try{await Lua_default.freeroam_freeroamConfigurator.updateOption(key,newValue),await loadButtons(),logger_default.debug(`Handled option change ${key}:`,newValue)}catch(err){logger_default.error(`Failed to update ${key} option:`,err),error.value=err}},handleButtonClick=async buttonId=>{try{await Lua_default.freeroam_freeroamConfigurator.triggerButton(buttonId),logger_default.debug(`Button clicked:`,buttonId)}catch(err){logger_default.error(`Failed to trigger button:`,err),error.value=err}},selectSpawnPoint=async(levelName,spawnPointObjectName,key)=>{try{if(!levelName)throw logger_default.error(`selectSpawnPoint: levelName is required`),Error(`levelName is required`);return await Lua_default.freeroam_freeroamConfigurator.setSpawnPoint(levelName,spawnPointObjectName,key),configData.value.currentSpawnPoint=await Lua_default.freeroam_freeroamConfigurator.getCurrentSpawnPointTile(),logger_default.debug(`Selected spawn point:`,{levelName,spawnPointObjectName}),!0}catch(err){return logger_default.error(`Failed to select spawn point:`,err),error.value=err,!1}},selectVehicle=async(model,config,additionalData,key)=>{try{if(!model||!config)throw logger_default.error(`selectVehicle: model and config are required`),Error(`model and config are required`);return await Lua_default.freeroam_freeroamConfigurator.setVehicle(model,config,additionalData||{},key),configData.value.currentVehicle=await Lua_default.freeroam_freeroamConfigurator.getCurrentVehicleTile(),logger_default.debug(`Selected vehicle:`,{model,config,additionalData}),!0}catch(err){return logger_default.error(`Failed to select vehicle:`,err),error.value=err,!1}},gotoHeaderItem=item=>{item.gotoPath&&(window.bngVue.gotoGameState(item.gotoPath.path,{params:item.gotoPath.props}),logger_default.debug(`Navigated to path:`,item.gotoPath)),item.gotoAngularState&&(window.bngVue.gotoAngularState(item.gotoAngularState),logger_default.debug(`Navigated to angular state:`,item.gotoAngularState)),item.click&&(item.click(),logger_default.debug(`Navigated to click:`,item.click))},goBack=()=>{logger_default.debug(`goBack called`),gotoHeaderItem({gotoAngularState:`menu.mainmenu`})},hasOptions=computed(()=>configData.value?.options&&configData.value.options.length>0),hasSpawnPoint=computed(()=>!!configData.value?.currentSpawnPoint),hasVehicle=computed(()=>!!configData.value?.currentVehicle),canConfigureOptions=computed(()=>hasSpawnPoint.value&&hasVehicle.value),isGroupEnabled=group=>!group.key||!!group.value,initialize=async()=>{if(isInitializing.value){logger_default.debug(`Already initializing, skipping...`);return}try{isInitializing.value=!0,logger_default.debug(`Initializing FreeroamConfigurator composable...`),await loadConfiguration(),logger_default.debug(`FreeroamConfigurator composable initialized successfully`)}catch(err){logger_default.error(`Failed to initialize FreeroamConfigurator composable:`,err),error.value=err}finally{isInitializing.value=!1}},cleanup=()=>{logger_default.debug(`FreeroamConfigurator composable cleanup`),events$3.off(`freeroamConfiguratorRefreshConfig`,refreshConfigHandler),events$3.off(`freeroamConfiguratorRefreshButton`,refreshButtonHandler)};return onUnmounted(()=>{cleanup()}),{configData,config:configData,button,error,isInitializing,hasOptions,hasSpawnPoint,hasVehicle,canConfigureOptions,initialize,loadConfiguration,loadButtons,onSpawnPointTileClick,onVehicleTileClick,updateOption,handleOptionChange,handleButtonClick,selectSpawnPoint,selectVehicle,gotoHeaderItem,goBack,isGroupEnabled}}var _hoisted_1$115={class:`configurator-content`},_hoisted_2$95={key:0,class:`error-state`},_hoisted_3$83={class:`error-content`},_hoisted_4$63={key:1,class:`configurator-sections`,"bng-nav-item":``},_hoisted_5$53={class:`three-column-layout`},_hoisted_6$40={class:`config-section`,"bng-nav-item":``},_hoisted_7$33={class:`section-header`},_hoisted_8$26={class:`section-title-value`},_hoisted_9$23={class:`section-content`},_hoisted_10$17={key:0,class:`clickable`},_hoisted_11$15={key:1,class:`placeholder-content`},_hoisted_12$11={class:`config-section`,"bng-nav-item":``},_hoisted_13$10={class:`section-header`},_hoisted_14$10={class:`section-title-value`},_hoisted_15$10={class:`section-content`},_hoisted_16$10={key:0,class:`clickable`},_hoisted_17$9={key:1,class:`placeholder-content`},_hoisted_18$7={class:`config-section`,"bng-nav-item":``},_hoisted_19$5={class:`section-header`},_hoisted_20$5={key:0,class:`options-scope`},_hoisted_21$5={key:0,class:`section-header`},_hoisted_22$5=[`bng-scoped-nav-autofocus`],_hoisted_23$4={class:`option-label`},_hoisted_24$3={key:1,class:`placeholder-content`},_hoisted_25$2={class:`action-button-container`},_hoisted_26$1={class:`button-content`},_hoisted_27$1={key:1,class:`placeholder-content row`},_sfc_main$127={__name:`FreeroamConfigurator`,setup(__props){let{lua}=useBridge(),{configData,config,button,error,hasOptions,hasSpawnPoint,hasVehicle,canConfigureOptions,initialize,onSpawnPointTileClick,onVehicleTileClick,handleOptionChange,handleButtonClick,gotoHeaderItem,goBack,isGroupEnabled}=useFreeroamConfigurator();return onBeforeMount(()=>{lua.simTimeAuthority.pushPauseRequest(`freeroamConfigurator`)}),onMounted(()=>{initialize()}),onUnmounted(()=>{lua.simTimeAuthority.popPauseRequest(`freeroamConfigurator`)}),(_ctx,_cache)=>withDirectives((openBlock(),createBlock(unref(layoutSingle_default),{class:`freeroam-configurator`},{default:withCtx(()=>[createBaseVNode(`div`,_hoisted_1$115,[createVNode(unref(bngScreenHeadingV2_default),{class:`configurator-heading`},{preheadings:withCtx(()=>[createVNode(unref(bngBreadcrumbs_default),{"show-back-button":!0,simple:``,"disable-last-item":``,class:`configurator-breadcrumbs`,onBack:unref(goBack),onClick:unref(gotoHeaderItem),items:[{label:`Menu`,gotoAngularState:`menu.mainmenu`},{label:`Freeroam Configurator`}]},null,8,[`onBack`,`onClick`])]),default:withCtx(()=>[_cache[3]||=createTextVNode(` Freeroam `,-1)]),_:1}),unref(error)?(openBlock(),createElementBlock(`div`,_hoisted_2$95,[createVNode(BlurBackground_default),createBaseVNode(`div`,_hoisted_3$83,[createVNode(unref(bngIcon_default),{type:`warning`,class:`error-icon`}),_cache[5]||=createBaseVNode(`p`,null,`Failed to load configuration`,-1),createVNode(unref(bngButton_default),{onClick:unref(initialize),accent:unref(ACCENTS).secondary},{default:withCtx(()=>[..._cache[4]||=[createTextVNode(`Retry`,-1)]]),_:1},8,[`onClick`,`accent`])])])):withDirectives((openBlock(),createElementBlock(`div`,_hoisted_4$63,[createBaseVNode(`div`,_hoisted_5$53,[withDirectives((openBlock(),createElementBlock(`div`,_hoisted_6$40,[createVNode(BlurBackground_default),createBaseVNode(`div`,_hoisted_7$33,[createVNode(unref(bngCardHeading_default),{type:`ribbon`,class:`section-title`},{default:withCtx(()=>[_cache[6]||=createBaseVNode(`span`,{class:`section-title-label`},`Location:`,-1),createBaseVNode(`span`,_hoisted_8$26,toDisplayString(unref(configData)?.currentSpawnPoint?.headerTitle||`Select location...`),1)]),_:1})]),createBaseVNode(`div`,_hoisted_9$23,[createBaseVNode(`div`,{class:`selectable-component`,onClick:_cache[0]||=()=>unref(onSpawnPointTileClick)()},[unref(configData)?.currentSpawnPoint?(openBlock(),createElementBlock(`div`,_hoisted_10$17,[createVNode(GameplayDetails_default,{"active-item":{levelName:unref(configData).currentSpawnPoint.levelName,spawnPointObjectName:unref(configData).currentSpawnPoint.spawnPointObjectName},"active-item-details":unref(configData).currentSpawnPoint,inline:``},null,8,[`active-item`,`active-item-details`])])):(openBlock(),createElementBlock(`div`,_hoisted_11$15,[createVNode(unref(bngIcon_default),{type:`road`,class:`placeholder-icon`}),_cache[7]||=createBaseVNode(`p`,{class:`placeholder-text`},`Click to select location`,-1)]))])])])),[[unref(BngBlur_default)],[unref(BngOnUiNav_default),()=>unref(onSpawnPointTileClick)(),`ok`,{focusRequired:!0}]]),withDirectives((openBlock(),createElementBlock(`div`,_hoisted_12$11,[createVNode(BlurBackground_default),createBaseVNode(`div`,_hoisted_13$10,[createVNode(unref(bngCardHeading_default),{type:`ribbon`,class:`section-title`},{default:withCtx(()=>[_cache[8]||=createBaseVNode(`span`,{class:`section-title-label`},`Vehicle:`,-1),createBaseVNode(`span`,_hoisted_14$10,toDisplayString(unref(configData)?.currentVehicle?.headerTitle||`Select vehicle...`),1)]),_:1})]),createBaseVNode(`div`,_hoisted_15$10,[createBaseVNode(`div`,{class:`selectable-component`,onClick:_cache[1]||=()=>unref(onVehicleTileClick)()},[unref(configData)?.currentVehicle?(openBlock(),createElementBlock(`div`,_hoisted_16$10,[createVNode(VehicleDetails_default,{"active-item":{model:unref(configData).currentVehicle.model,config:unref(configData).currentVehicle.config},"active-item-details":unref(configData).currentVehicle,"hide-details-and-buttons":``,inline:``},null,8,[`active-item`,`active-item-details`])])):(openBlock(),createElementBlock(`div`,_hoisted_17$9,[createVNode(unref(bngIcon_default),{type:`car`,class:`placeholder-icon`}),_cache[9]||=createBaseVNode(`p`,{class:`placeholder-text`},`Click to select vehicle`,-1)]))])])])),[[unref(BngBlur_default)],[unref(BngOnUiNav_default),()=>unref(onVehicleTileClick)(),`ok`,{focusRequired:!0}]]),withDirectives((openBlock(),createElementBlock(`div`,_hoisted_18$7,[createVNode(BlurBackground_default),createBaseVNode(`div`,_hoisted_19$5,[createVNode(unref(bngCardHeading_default),{type:`ribbon`,class:`section-title`},{default:withCtx(()=>[..._cache[10]||=[createTextVNode(`Options`,-1)]]),_:1})]),createBaseVNode(`div`,{class:normalizeClass([`section-content`,{disabled:!unref(canConfigureOptions)}])},[unref(hasOptions)?(openBlock(),createElementBlock(`div`,_hoisted_20$5,[(openBlock(!0),createElementBlock(Fragment,null,renderList(unref(configData).options,group=>(openBlock(),createElementBlock(`div`,{class:`config-group`,key:group.name},[group.name?(openBlock(),createElementBlock(`div`,_hoisted_21$5,[createVNode(unref(bngCardHeading_default),{outline:!unref(isGroupEnabled)(group),type:`ribbon`,class:`section-title`},{default:withCtx(()=>[group.type===`switch`?(openBlock(),createBlock(unref(bngSwitch_default),{key:0,class:`group-switch`,modelValue:unref(config)[group.key],"onUpdate:modelValue":[$event=>unref(config)[group.key]=$event,newValue=>unref(handleOptionChange)(group.key,newValue)],label:group.name,labelBefore:``,inline:``,alwaysTransparent:``},null,8,[`modelValue`,`onUpdate:modelValue`,`label`])):createCommentVNode(``,!0)]),_:2},1032,[`outline`])])):createCommentVNode(``,!0),unref(isGroupEnabled)(group)?(openBlock(!0),createElementBlock(Fragment,{key:1},renderList(group.options,(option,optionIndex)=>(openBlock(),createElementBlock(`div`,{class:`config-item`,key:option.key,"bng-scoped-nav-autofocus":optionIndex===0},[createBaseVNode(`div`,{class:normalizeClass([`option-row`,{disabled:option.disabled}])},[createBaseVNode(`label`,_hoisted_23$4,[option.icon?(openBlock(),createBlock(unref(bngIcon_default),{key:0,type:option.icon,class:`option-icon`},null,8,[`type`])):createCommentVNode(``,!0),createTextVNode(` `+toDisplayString(option.label),1)]),option.type===`select`?(openBlock(),createBlock(unref(bngSmartSelect_default),{key:0,modelValue:unref(config)[option.key],items:option.options||[],threshold:80,"onUpdate:modelValue":newValue=>unref(handleOptionChange)(option.key,newValue)},null,8,[`modelValue`,`items`,`onUpdate:modelValue`])):option.type===`switch`?(openBlock(),createBlock(unref(bngSwitch_default),{key:1,modelValue:unref(config)[option.key],"onUpdate:modelValue":[$event=>unref(config)[option.key]=$event,newValue=>unref(handleOptionChange)(option.key,newValue)],label:option.label,labelBefore:``},null,8,[`modelValue`,`onUpdate:modelValue`,`label`])):option.type===`string`?(openBlock(),createBlock(unref(bngInput_default),{key:2,modelValue:unref(config)[option.key],"onUpdate:modelValue":$event=>unref(config)[option.key]=$event,placeholder:option.placeholder,"char-max":option.maxLength,onValueChanged:newValue=>unref(handleOptionChange)(option.key,newValue)},null,8,[`modelValue`,`onUpdate:modelValue`,`placeholder`,`char-max`,`onValueChanged`])):option.type===`number`?(openBlock(),createBlock(unref(bngInput_default),{key:3,modelValue:unref(config)[option.key],"onUpdate:modelValue":$event=>unref(config)[option.key]=$event,type:`number`,"num-min":option.min,"num-max":option.max,"num-step":option.step,onValueChanged:newValue=>unref(handleOptionChange)(option.key,newValue)},null,8,[`modelValue`,`onUpdate:modelValue`,`num-min`,`num-max`,`num-step`,`onValueChanged`])):createCommentVNode(``,!0)],2)],8,_hoisted_22$5))),128)):createCommentVNode(``,!0)]))),128))])):(openBlock(),createElementBlock(`div`,_hoisted_24$3,[createVNode(unref(bngIcon_default),{type:`adjust`,class:`placeholder-icon`}),_cache[11]||=createBaseVNode(`p`,{class:`placeholder-text`},`No options available`,-1)]))],2)])),[[unref(BngBlur_default)],[unref(BngScopedNav_default),{type:unref(SCOPED_NAV_TYPES).normal}]])]),createBaseVNode(`div`,_hoisted_25$2,[createVNode(BlurBackground_default),unref(button)?withDirectives((openBlock(),createBlock(unref(bngButton_default),{key:0,class:`action-button`,accent:unref(ACCENTS).custom,onClick:_cache[2]||=()=>unref(handleButtonClick)(unref(button).meta.buttonId),"bng-scoped-nav-autofocus":``},{default:withCtx(()=>[createBaseVNode(`div`,_hoisted_26$1,[unref(button).meta.icon?(openBlock(),createBlock(unref(bngIcon_default),{key:0,type:unref(button).meta.icon,class:`button-icon`},null,8,[`type`])):createCommentVNode(``,!0),createTextVNode(` `+toDisplayString(unref(button).meta.label),1)])]),_:1},8,[`accent`])),[[unref(BngBlur_default)]]):(openBlock(),createElementBlock(`div`,_hoisted_27$1,[createVNode(unref(bngIcon_default),{type:`play`,class:`placeholder-icon`}),_cache[12]||=createBaseVNode(`p`,{class:`placeholder-text`},`Select location and vehicle to start`,-1)]))])])),[[unref(BngScopedNav_default),{canDeactivate:()=>!1,activateOnMount:!0}],[unref(BngOnUiNav_default),unref(goBack),`back,menu`]])])]),_:1})),[[unref(BngOnUiNav_default),unref(goBack),`back,menu`]])}},FreeroamConfigurator_default=__plugin_vue_export_helper_default(_sfc_main$127,[[`__scopeId`,`data-v-14f15b24`]]),_hoisted_1$114={class:`options-panel-content`},_hoisted_2$94={class:`header-row`},_hoisted_3$82={key:0,class:`options-scope`},_hoisted_4$62={key:0,class:`section-header`},_hoisted_5$52={class:`option-label`},_hoisted_6$39={key:1,class:`placeholder-content`},_sfc_main$126={__name:`OptionsPanel`,props:{options:{type:Array,default:()=>[]},hasOptions:{type:Boolean,default:!1},canConfigureOptions:{type:Boolean,default:!0}},setup(__props){return(_ctx,_cache)=>withDirectives((openBlock(),createElementBlock(`div`,_hoisted_1$114,[createVNode(BlurBackground_default),createBaseVNode(`div`,_hoisted_2$94,[createVNode(unref(bngScreenHeadingV2_default),{type:`2`,class:`header-title-v2`},{default:withCtx(()=>[..._cache[0]||=[createTextVNode(` Options `,-1)]]),_:1})]),createBaseVNode(`div`,{class:normalizeClass([`section-content`,{disabled:!__props.canConfigureOptions}])},[__props.hasOptions?(openBlock(),createElementBlock(`div`,_hoisted_3$82,[(openBlock(!0),createElementBlock(Fragment,null,renderList(__props.options,group=>(openBlock(),createElementBlock(`div`,{class:`config-group`,key:group.name},[group.name?(openBlock(),createElementBlock(`div`,_hoisted_4$62,[createVNode(unref(bngCardHeading_default),{outline:!group.enabled,type:`ribbon`,class:`section-title`},{default:withCtx(()=>[group.type===`switch`?(openBlock(),createBlock(unref(bngSwitch_default),{key:0,class:`group-switch`,modelValue:group.value,"onUpdate:modelValue":[$event=>group.value=$event,group.onChange],label:group.name,labelBefore:``,inline:``,alwaysTransparent:``},null,8,[`modelValue`,`onUpdate:modelValue`,`label`])):createCommentVNode(``,!0)]),_:2},1032,[`outline`])])):createCommentVNode(``,!0),group.enabled?(openBlock(!0),createElementBlock(Fragment,{key:1},renderList(group.options,(option,optionIndex)=>(openBlock(),createElementBlock(`div`,{class:`config-item`,key:option.key},[createBaseVNode(`div`,{class:normalizeClass([`option-row`,{disabled:option.disabled}])},[createBaseVNode(`label`,_hoisted_5$52,[option.icon?(openBlock(),createBlock(unref(bngIcon_default),{key:0,type:option.icon,class:`option-icon`},null,8,[`type`])):createCommentVNode(``,!0),createTextVNode(` `+toDisplayString(option.label),1)]),option.type===`select`?(openBlock(),createBlock(unref(bngSmartSelect_default),{key:0,modelValue:option.value,"onUpdate:modelValue":[$event=>option.value=$event,option.onChange],items:option.options||[],threshold:80},null,8,[`modelValue`,`onUpdate:modelValue`,`items`])):option.type===`switch`?(openBlock(),createBlock(unref(bngSwitch_default),{key:1,modelValue:option.value,"onUpdate:modelValue":[$event=>option.value=$event,option.onChange],label:option.label,labelBefore:``},null,8,[`modelValue`,`onUpdate:modelValue`,`label`])):option.type===`string`?(openBlock(),createBlock(unref(bngInput_default),{key:2,modelValue:option.value,"onUpdate:modelValue":$event=>option.value=$event,placeholder:option.placeholder,"char-max":option.maxLength,onValueChanged:option.onChange},null,8,[`modelValue`,`onUpdate:modelValue`,`placeholder`,`char-max`,`onValueChanged`])):option.type===`number`?(openBlock(),createBlock(unref(bngInput_default),{key:3,modelValue:option.value,"onUpdate:modelValue":$event=>option.value=$event,type:`number`,"num-min":option.min,"num-max":option.max,"num-step":option.step,onValueChanged:option.onChange},null,8,[`modelValue`,`onUpdate:modelValue`,`num-min`,`num-max`,`num-step`,`onValueChanged`])):createCommentVNode(``,!0)],2)]))),128)):createCommentVNode(``,!0)]))),128))])):(openBlock(),createElementBlock(`div`,_hoisted_6$39,[createVNode(unref(bngIcon_default),{type:`adjust`,class:`placeholder-icon`}),_cache[1]||=createBaseVNode(`p`,{class:`placeholder-text`},`No options available`,-1)]))],2),renderSlot(_ctx.$slots,`buttons`,{},void 0,!0)])),[[unref(BngBlur_default)]])}},OptionsPanel_default=__plugin_vue_export_helper_default(_sfc_main$126,[[`__scopeId`,`data-v-c933da42`]]),_hoisted_1$113={class:`icon-wrapper`},_sfc_main$125={__name:`wizardStepButton`,props:{first:{type:Boolean,default:!1},title:{type:String,required:!0},tooltip:{type:String},active:{type:Boolean,default:!1},completed:{type:Boolean,default:!1},preview:{type:String,default:``},icon:{type:String,default:``},ratio:{type:String,default:`2:1`},showPaintTile:{type:Boolean,default:!1},paintId:{type:String,default:``},paints:{type:Array,default:()=>[]},paintName:{type:String,default:``},paintWidth:{type:Number,default:45},paintHeight:{type:Number,default:20}},emits:[`activate`],setup(__props,{emit:__emit}){let emit$1=__emit;function handleActivate(){emit$1(`activate`)}return(_ctx,_cache)=>withDirectives((openBlock(),createElementBlock(`div`,{class:normalizeClass([`step-tab`,{"first-tab":__props.first,"active-tab":__props.active,"completed-tab":__props.completed,"no-thumbnail":!__props.preview}]),onClick:handleActivate},[createBaseVNode(`div`,_hoisted_1$113,[createVNode(unref(bngIcon_default),{class:`step-icon`,type:__props.icon},null,8,[`type`])]),__props.preview?(openBlock(),createBlock(unref(aspectRatio_default),{key:0,class:`thumbnail-image`,ratio:__props.ratio,"external-image":__props.preview},{default:withCtx(()=>[renderSlot(_ctx.$slots,`overlay`,{},void 0,!0),__props.showPaintTile&&__props.paints&&__props.paints.length>0?(openBlock(),createBlock(unref(bngPaintTile_default),{key:0,"paint-id":__props.paintId,paint:__props.paints,"paint-name":__props.paintName,width:__props.paintWidth,height:__props.paintHeight,onClick:handleActivate,class:`preview-paint-tile`,"bng-no-nav":`true`,tabindex:`-1`},null,8,[`paint-id`,`paint`,`paint-name`,`width`,`height`])):createCommentVNode(``,!0)]),_:3},8,[`ratio`,`external-image`])):createCommentVNode(``,!0)],2)),[[unref(BngOnUiNav_default),handleActivate,`ok`,{focusRequired:!0}],[unref(BngTooltip_default),__props.tooltip,`bottom`]])}},wizardStepButton_default=__plugin_vue_export_helper_default(_sfc_main$125,[[`__scopeId`,`data-v-475a9f52`]]),_hoisted_1$112={class:`configurator-heading`},_hoisted_2$93={class:`configurator-body`},_hoisted_3$81={key:0,class:`grid-section`},_hoisted_4$61={key:1,class:`option-summary-panel`},_hoisted_5$51={class:`section-header`},_hoisted_6$38={class:`section-title-value`},_hoisted_7$32={class:`section-content`},_hoisted_8$25={key:0,class:`clickable`},_hoisted_9$22={key:1,class:`placeholder-content`},_hoisted_10$16={class:`section-header`},_hoisted_11$14={class:`section-title-value`},_hoisted_12$10={class:`section-content`},_hoisted_13$9={key:0,class:`clickable`},_hoisted_14$9={key:1,class:`placeholder-content`},_hoisted_15$9={class:`configurator-heading`},_hoisted_16$9={key:0,class:`error-state`},_hoisted_17$8={class:`error-content`},_hoisted_18$6={key:1,class:`configurator-sections`},_hoisted_19$4={class:`steps-container`},_hoisted_20$4={class:`background-bar`},_hoisted_21$4={class:`label`},_hoisted_22$4={class:`hold-binding`},WIZARD_SCOPE_ID=`freeroam-wizard`,_sfc_main$124={__name:`FreeroamWizard`,props:{step:{type:String,default:``},pathMatch:{type:[String,Array],default:``},itemDetails:{type:[String,Array],default:``}},setup(__props){let{lua,events:events$3}=useBridge(),router$1=useRouter(),scopedNav=useScopedNav(),steps={level:{title:`Location`,backendName:`freeroamSelector`,path:`/freeroam-wizard/level`,defaultPath:{keys:[`allFreeroam`]},defaultDetailsMode:`detail`,hiddenTabs:[`filter`,`advanced`]},vehicle:{title:`Vehicle`,backendName:`vehicleSelector`,path:`/freeroam-wizard/vehicle`,defaultPath:{keys:[`allModels`]},defaultDetailsMode:`detail`,hiddenTabs:[`advanced`]},options:{title:`Options`,path:`/freeroam-wizard/options`}},stepCompleted=computed(()=>({level:props.step===`vehicle`||props.step===`options`,vehicle:props.step===`options`,options:!1})),gridSelectorProps=computed(()=>{let stepConfig=steps[props.step];return stepConfig&&stepConfig.backendName&&stepConfig.path?{backendName:stepConfig.backendName,routePath:stepConfig.path,defaultPath:stepConfig.defaultPath||{keys:[]},defaultDetailsMode:stepConfig.defaultDetailsMode||`detail`,hiddenTabs:stepConfig.hiddenTabs||[]}:null}),props=__props,gridSelectorRef=ref(null),holdBindingRef=ref(null),isLoading=ref(!1),breadcrumbItems=computed(()=>{let items$2=[{label:`Menu`,gotoAngularState:`menu.mainmenu`},{label:`Freeroam Configurator`,dividerType:`arrowSmallRight`}];props.step===`level`?items$2.push({label:`Location`,click:()=>{onSpawnPointTileClick(!0)}}):props.step===`vehicle`?items$2.push({label:`Vehicle`,click:()=>{onVehicleTileClick(!0)}}):props.step===`options`&&items$2.push({label:`Options`,click:onOptionsTileClick});let screenHeaderPath=gridSelectorRef.value?.screenHeaderPath,pathValue=screenHeaderPath?.value||screenHeaderPath;return pathValue&&Array.isArray(pathValue)&&pathValue.length>2&&(pathValue.length>3?(items$2.push({label:pathValue[2].label,click:()=>{gridSelectorRef.value.setCurrentPath({keys:pathValue[2].gotoPath}),onSpawnPointTileClick()}}),items$2.push(pathValue[3])):items$2.push(pathValue[2])),items$2}),{configData,button,error,hasOptions,hasSpawnPoint,hasVehicle,canConfigureOptions,initialize,handleButtonClick,selectSpawnPoint,selectVehicle,gotoHeaderItem,loadConfiguration}=useFreeroamConfigurator();watch(()=>props.step,step=>{step===`options`&&(loadConfiguration(),scopedNav.resumeScope(WIZARD_SCOPE_ID))});let overrideSelectItem=async(step,...args)=>{if(props.step===`level`){let item=args[0];if(!item?.showDetails?.levelName)return logger_default.error(`overrideSelectItem: Invalid item data for level selection`),null;await selectSpawnPoint(item.showDetails.levelName,item.showDetails.spawnPointObjectName,item.key)&&router$1.push(steps.vehicle.path)}else if(props.step===`vehicle`){let item=args[0];if(!item?.showDetails?.model||!item?.showDetails?.config)return logger_default.error(`overrideSelectItem: Invalid item data for vehicle selection`),null;let selectedPaint=args[1],selectedMultiPaint=args[2],additionalData={};selectedMultiPaint?.paintNames?(additionalData.paint=selectedMultiPaint.paintNames[0],additionalData.paint2=selectedMultiPaint.paintNames[1],additionalData.paint3=selectedMultiPaint.paintNames[2]):selectedPaint?.name&&(additionalData.paint=selectedPaint.name),await selectVehicle(item.showDetails.model,item.showDetails.config,additionalData,item.key)&&router$1.push(steps.options.path)}return null},onSelectCallback=async(item,doNavigation)=>{if(doNavigation){if(props.step===`level`){if(!item?.doubleClickDetails?.levelName)return logger_default.error(`overrideSelectItem: Invalid item data for level selection`),null;await selectSpawnPoint(item.doubleClickDetails.levelName,item.doubleClickDetails.spawnPointObjectName,item.key)}else if(props.step===`vehicle`){if(!item?.doubleClickDetails?.model||!item?.doubleClickDetails?.config)return logger_default.error(`overrideSelectItem: Invalid item data for vehicle selection`),null;await selectVehicle(item.doubleClickDetails.model,item.doubleClickDetails.config,{},item.key)}}return null},doubleClickOverride=async item=>{if(!item?.doubleClickDetails){logger_default.error(`doubleClickOverride: Invalid item data`);return}let details=item.doubleClickDetails;details.levelName?await selectSpawnPoint(details.levelName,details.spawnPointObjectName,item.key)&&router$1.push(steps.vehicle.path):details.model&&details.config&&await selectVehicle(details.model,details.config,{},item.key)&&router$1.push(steps.options.path)},goBack=()=>{logger_default.debug(`goBack called`);let gridSelectorPath=gridSelectorRef.value?.screenHeaderPath;props.step===`level`?gridSelectorPath&&gridSelectorPath.length>2?onSpawnPointTileClick():window.bngVue.gotoAngularState(`menu.mainmenu`):props.step===`vehicle`?gridSelectorPath&&gridSelectorPath.length>2?onVehicleTileClick():onSpawnPointTileClick():props.step===`options`&&onVehicleTileClick()},onSpawnPointTileClick=async()=>{router$1.replace(steps.level.path)},onVehicleTileClick=async(clearSearch=!1)=>{clearSearch&&gridSelectorRef.value&&(gridSelectorRef.value.clearSearch(),gridSelectorRef.value.clearFilters()),router$1.replace(steps.vehicle.path)},onOptionsTileClick=async()=>{router$1.replace(steps.options.path)},onStartButtonClick=async buttonId=>{isLoading.value=!0,events$3.emit(`LoadingScreen`,{active:!0}),await startLoading$1(async()=>{await waitForLoadingScreenFadeIn$1(),await handleButtonClick(buttonId)})};function convertPaintToTileFormat(paint){if(!paint)return null;if(paint.baseColor&&paint.paintString)return paint;try{let paintObj=new Paint;return paintObj.paint=paint,paintObj.paintObject}catch(error$1){return console.warn(`Failed to convert paint:`,paint,error$1),null}}let vehiclePaintData=computed(()=>{let vehicle=configData.value?.currentVehicle;if(!vehicle?.additionalData?.paint||!vehicle?.paints?.factoryPaints)return null;let additionalData=vehicle.additionalData,factoryPaints=vehicle.paints.factoryPaints,paintNames=[additionalData.paint,additionalData.paint2,additionalData.paint3].filter(name=>name),paints=paintNames.map(name=>{let paint=factoryPaints.find(p$1=>p$1.name===name);return paint?convertPaintToTileFormat(paint):null}).filter(paint=>paint!==null);return paints.length===0?null:{paint:paintNames[0],paintNames,paints}});return onBeforeMount(()=>{lua.simTimeAuthority.pushPauseRequest(`freeroamConfigurator`)}),onMounted(()=>{initialize()}),onUnmounted(()=>{lua.simTimeAuthority.popPauseRequest(`freeroamConfigurator`)}),(_ctx,_cache)=>(openBlock(),createBlock(unref(layoutSingle_default),{class:`freeroam-configurator`},{default:withCtx(()=>[withDirectives((openBlock(),createElementBlock(`div`,{class:normalizeClass([`configurator-content`,{"options-step":__props.step===`options`}])},[createBaseVNode(`div`,_hoisted_1$112,[withDirectives(createVNode(unref(bngBreadcrumbs_default),{class:`configurator-breadcrumbs`,simple:``,"show-back-button":``,"disable-last-item":``,onBack:goBack,onClick:unref(gotoHeaderItem),limit:`15`,items:breadcrumbItems.value},null,8,[`onClick`,`items`]),[[unref(BngBlur_default)]])]),createBaseVNode(`div`,_hoisted_2$93,[__props.step!==`options`&&gridSelectorProps.value?(openBlock(),createElementBlock(`div`,_hoisted_3$81,[(openBlock(),createBlock(GridSelector_default,{ref_key:`gridSelectorRef`,ref:gridSelectorRef,key:`grid-selector-${__props.step}`,"backend-name":gridSelectorProps.value.backendName,"route-path":gridSelectorProps.value.routePath,"default-path":gridSelectorProps.value.defaultPath,"default-details-mode":gridSelectorProps.value.defaultDetailsMode,"hidden-tabs":gridSelectorProps.value.hiddenTabs,"no-breadcrumbs":``,"select-callback":onSelectCallback,"double-click-override":doubleClickOverride,"override-back-from-grid":goBack,"inline-header-container":``,"bubble-events":[`ok`]},{"item-details":withCtx(({activeItem,activeItemDetails,executeButton,toggleFavourite,exploreFolder,goToMod})=>[__props.step===`level`?(openBlock(),createBlock(GameplayDetails_default,{key:0,activeItem,activeItemDetails,toggleFavourite,exploreFolder,goToMod,buttonOverride:{icon:`fastTravel`,label:`Next Step`,click:(...args)=>overrideSelectItem(`level`,...args)},showHeaderTitle:!0},null,8,[`activeItem`,`activeItemDetails`,`toggleFavourite`,`exploreFolder`,`goToMod`,`buttonOverride`])):createCommentVNode(``,!0),__props.step===`vehicle`?(openBlock(),createBlock(VehicleDetails_default,{key:1,activeItem,activeItemDetails,toggleFavourite,exploreFolder,goToMod,buttonOverride:{icon:`fastTravel`,label:`Next Step`,click:(...args)=>overrideSelectItem(`vehicle`,...args)},showHeaderTitle:!0},null,8,[`activeItem`,`activeItemDetails`,`toggleFavourite`,`exploreFolder`,`goToMod`,`buttonOverride`])):createCommentVNode(``,!0)]),_:1},8,[`backend-name`,`route-path`,`default-path`,`default-details-mode`,`hidden-tabs`]))])):createCommentVNode(``,!0),__props.step===`options`&&unref(configData)?(openBlock(),createElementBlock(`div`,_hoisted_4$61,[withDirectives((openBlock(),createElementBlock(`div`,{class:`config-section selectable-component`,onClick:onSpawnPointTileClick},[createVNode(BlurBackground_default),createBaseVNode(`div`,_hoisted_5$51,[createVNode(unref(bngCardHeading_default),{type:`ribbon`,class:`section-title`},{default:withCtx(()=>[_cache[1]||=createBaseVNode(`span`,{class:`section-title-label`},`Location:`,-1),createBaseVNode(`span`,_hoisted_6$38,toDisplayString(unref(configData)?.currentSpawnPoint?.headerTitle||`Select location...`),1)]),_:1})]),createBaseVNode(`div`,_hoisted_7$32,[createBaseVNode(`div`,null,[unref(configData)?.currentSpawnPoint?(openBlock(),createElementBlock(`div`,_hoisted_8$25,[createVNode(GameplayDetails_default,{"active-item":{levelName:unref(configData).currentSpawnPoint.levelName,spawnPointObjectName:unref(configData).currentSpawnPoint.spawnPointObjectName},"active-item-details":unref(configData).currentSpawnPoint,inline:``,"show-header-title":!1},null,8,[`active-item`,`active-item-details`])])):(openBlock(),createElementBlock(`div`,_hoisted_9$22,[createVNode(unref(bngIcon_default),{type:`road`,class:`placeholder-icon`}),_cache[2]||=createBaseVNode(`p`,{class:`placeholder-text`},`Click to select location`,-1)]))])])])),[[unref(BngBlur_default)]]),withDirectives((openBlock(),createElementBlock(`div`,{class:`config-section selectable-component`,onClick:onVehicleTileClick},[createVNode(BlurBackground_default),createBaseVNode(`div`,_hoisted_10$16,[createVNode(unref(bngCardHeading_default),{type:`ribbon`,class:`section-title`},{default:withCtx(()=>[_cache[3]||=createBaseVNode(`span`,{class:`section-title-label`},`Vehicle:`,-1),createBaseVNode(`span`,_hoisted_11$14,toDisplayString(unref(configData)?.currentVehicle?.headerTitle||`Select vehicle...`),1)]),_:1})]),createBaseVNode(`div`,_hoisted_12$10,[createBaseVNode(`div`,null,[unref(configData)?.currentVehicle?(openBlock(),createElementBlock(`div`,_hoisted_13$9,[createVNode(VehicleDetails_default,{"active-item":{model:unref(configData).currentVehicle.model,config:unref(configData).currentVehicle.config},"active-item-details":unref(configData).currentVehicle,"hide-details-and-buttons":``,inline:``,"show-header-title":!1},null,8,[`active-item`,`active-item-details`])])):(openBlock(),createElementBlock(`div`,_hoisted_14$9,[createVNode(unref(bngIcon_default),{type:`car`,class:`placeholder-icon`}),_cache[4]||=createBaseVNode(`p`,{class:`placeholder-text`},`Click to select vehicle`,-1)]))])])])),[[unref(BngBlur_default)]]),withDirectives(createVNode(OptionsPanel_default,{class:`config-section`,options:unref(configData)?.options||[],"has-options":unref(hasOptions),"can-configure-options":unref(canConfigureOptions)},null,8,[`options`,`has-options`,`can-configure-options`]),[[unref(BngOnUiNav_default),goBack,`back`],[unref(BngOnUiNav_default),goBack,`menu`]])])):createCommentVNode(``,!0)]),createBaseVNode(`div`,_hoisted_15$9,[unref(error)?(openBlock(),createElementBlock(`div`,_hoisted_16$9,[createVNode(BlurBackground_default),createBaseVNode(`div`,_hoisted_17$8,[createVNode(unref(bngIcon_default),{type:`warning`,class:`error-icon`}),_cache[6]||=createBaseVNode(`p`,null,`Failed to load configuration`,-1),createVNode(unref(bngButton_default),{onClick:unref(initialize),accent:unref(ACCENTS).secondary},{default:withCtx(()=>[..._cache[5]||=[createTextVNode(`Retry`,-1)]]),_:1},8,[`onClick`,`accent`])])])):(openBlock(),createElementBlock(`div`,_hoisted_18$6,[withDirectives((openBlock(),createElementBlock(`div`,_hoisted_19$4,[createBaseVNode(`div`,_hoisted_20$4,[createVNode(BlurBackground_default)]),createVNode(wizardStepButton_default,{first:``,active:__props.step===`level`,completed:stepCompleted.value.level,title:`Location`,tooltip:unref(configData)?.currentSpawnPoint?.headerTitle,preview:unref(configData)?.currentSpawnPoint?.preview,icon:`road`,onActivate:onSpawnPointTileClick},null,8,[`active`,`completed`,`tooltip`,`preview`]),createVNode(wizardStepButton_default,{active:__props.step===`vehicle`,completed:stepCompleted.value.vehicle,title:`Vehicle`,tooltip:unref(configData)?.currentVehicle?.headerTitle,preview:unref(configData)?.currentVehicle?.preview,icon:`car`,"show-paint-tile":!!vehiclePaintData.value,"paint-id":`${unref(configData)?.currentVehicle?.key||`vehicle`}:${vehiclePaintData.value?.paint}`,paints:vehiclePaintData.value?.paints||[],"paint-name":vehiclePaintData.value?vehiclePaintData.value.paintNames.join(`, `):``,onActivate:onVehicleTileClick},null,8,[`active`,`completed`,`tooltip`,`preview`,`show-paint-tile`,`paint-id`,`paints`,`paint-name`]),createVNode(wizardStepButton_default,{active:__props.step===`options`,completed:stepCompleted.value.options,title:`Options`,tooltip:`Options`,icon:`adjust`,onActivate:onOptionsTileClick},null,8,[`active`,`completed`])])),[[unref(BngBlur_default)]]),withDirectives((openBlock(),createElementBlock(`div`,{class:`play-button`,onClick:_cache[0]||=$event=>onStartButtonClick(unref(button)?.meta?.buttonId),"bng-nav-item":``,tabindex:`1`},[_cache[8]||=createBaseVNode(`div`,{class:`background`},null,-1),createBaseVNode(`div`,_hoisted_21$4,[withDirectives(createBaseVNode(`div`,_hoisted_22$4,[createVNode(unref(bngBinding_default),{ref_key:`holdBindingRef`,ref:holdBindingRef,class:`binding`,"ui-event":`ok`,controller:``},null,512),_cache[7]||=createBaseVNode(`svg`,{class:`hold-arrow`,xmlns:`http://www.w3.org/2000/svg`,viewBox:`0 0 16 12`,preserveAspectRatio:`xMidYMid`},[createBaseVNode(`path`,{d:`M1,1 L8,2 L16,1 L8,11 z`})],-1)],512),[[vShow,holdBindingRef.value?.displayed]]),createTextVNode(` `+toDisplayString(unref(button)?.meta?.label||`Start`),1)])])),[[unref(BngOnUiNav_default),void 0,`ok`,{asMouse:!0}],[unref(BngSoundClass_default),`bng_click_hover_generic`]])]))])],2)),[[unref(BngScopedNav_default),{scopeId:WIZARD_SCOPE_ID,canDeactivate:()=>!1,activateOnMount:!0,bubbleBlacklistEvents:[`back`,`menu`]}],[unref(BngClick_default),{holdCallback:()=>onStartButtonClick(unref(button)?.meta?.buttonId),holdDelay:2e3,repeatInterval:0},void 0,{controller:!0}],[unref(BngOnUiNav_default),void 0,`ok`,{asMouse:!0}]])]),_:1}))}},FreeroamWizard_default=__plugin_vue_export_helper_default(_sfc_main$124,[[`__scopeId`,`data-v-6c942499`]]),routes_default$5=[{name:`menu.freeroamselector`,path:`/freeroam-selector/:pathMatch(.*)*/:itemDetails(.*)*`,component:FreeroamSelector_default,props:!0,meta:{clickThrough:!0,infoBar:{visible:!0,showSysInfo:!1},uiApps:{shown:!1},topBar:{visible:!0}}},{name:`menu.freeroamconfigurator`,path:`/freeroam-configurator`,component:FreeroamConfigurator_default,meta:{clickThrough:!0,infoBar:{visible:!0,showSysInfo:!1},uiApps:{shown:!1},topBar:{visible:!1}}},{name:`menu.freeroamWizard`,path:`/freeroam-wizard/:step/:pathMatch(.*)*/:itemDetails(.*)*`,component:FreeroamWizard_default,props:!0,meta:{clickThrough:!0,infoBar:{visible:!0,showSysInfo:!1},uiApps:{shown:!1},topBar:{visible:!1}}}],_sfc_main$123={__name:`GameplaySelector`,setup(__props){return(_ctx,_cache)=>(openBlock(),createBlock(GridSelector_default,{backendName:`gameplaySelector`,routePath:`/gameplay-selector`,defaultPath:{keys:[`allGameplay`]},defaultDetailsMode:`detail`,hiddenTabs:[`filter`]},{"item-details":withCtx(({activeItem,activeItemDetails,executeButton,toggleFavourite,exploreFolder,goToMod})=>[createVNode(GameplayDetails_default,{activeItem,activeItemDetails,executeButton,toggleFavourite,exploreFolder,goToMod,showHeaderTitle:!0},null,8,[`activeItem`,`activeItemDetails`,`executeButton`,`toggleFavourite`,`exploreFolder`,`goToMod`])]),_:1}))}},GameplaySelector_default=_sfc_main$123,routes_default$6=[{name:`menu.gameplayselector`,path:`/gameplay-selector/:pathMatch(.*)*`,component:GameplaySelector_default,props:!0,meta:{clickThrough:!0,infoBar:{visible:!0,showSysInfo:!1},uiApps:{shown:!1},topBar:{visible:!0}}}],_hoisted_1$111={key:0,class:`garage-button-content`},_sfc_main$122={__name:`GarageButton`,props:{icon:[Object,String],externalIcon:String,disabled:Boolean,active:Boolean,type:{type:String,validator:val=>[`drawer-toggle`,`drawer-button`,``].includes(val)||val===void 0}},setup(__props){let props=__props,slots=useSlots(),hasContent=computed(()=>slots.default),showContent=computed(()=>hasContent.value&&!(props.type===`drawer-toggle`&&!props.active)),btnRef=ref(null);return onUpdated(()=>ensureFocus(btnRef.value?.getElement?.())),(_ctx,_cache)=>(openBlock(),createBlock(unref(bngButton_default),mergeProps({ref_key:`btnRef`,ref:btnRef,accent:unref(ACCENTS).custom,disabled:__props.disabled,icon:__props.icon,externalIcon:__props.externalIcon,class:[`garage-button`,{[`garage-button-${__props.type}`]:!!__props.type,"garage-button-with-content":hasContent.value,"garage-button-active":__props.active}]},_ctx.$attrs),{default:withCtx(()=>[showContent.value?(openBlock(),createElementBlock(`div`,_hoisted_1$111,[renderSlot(_ctx.$slots,`default`,{},void 0,!0)])):createCommentVNode(``,!0)]),_:3},16,[`accent`,`disabled`,`icon`,`externalIcon`,`class`]))}},GarageButton_default=__plugin_vue_export_helper_default(_sfc_main$122,[[`__scopeId`,`data-v-8b374028`]]),_hoisted_1$110={class:`paint-preview`},_hoisted_2$92=[`onClick`],_hoisted_3$80={key:0,class:`empty-slot-indicator`},refpad=25,_sfc_main$121={__name:`PaintPreview`,props:{paints:Array,paintNames:{type:Array,default:()=>[]}},emits:[`select`],setup(__props,{emit:__emit}){let props=__props,emit$1=__emit,previews=computed(()=>{let res=[];if(!props.paints||!Array.isArray(props.paints))return res;let paints=props.paints,len=paints.length;for(let idx=0;idx1?refpad+(100-refpad*2)/(len-1)*idx:50}%`,"--paint-color":isEmpty?`rgba(128, 128, 128, 0.3)`:`rgb(${paint.rgb255.join(`, `)})`,"--paint-metallic":isEmpty?0:Math.max(0,paint.metallic-paint.roughness/.5),"--paint-roughness":isEmpty?1:paint.roughness,"--paint-clearcoat":isEmpty?0:paint.clearcoat,"--paint-clearcoat-roughness":isEmpty?0:paint.clearcoatRoughness,isEmpty,tooltipText};res.push(vars)}return res});return(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$110,[(openBlock(!0),createElementBlock(Fragment,null,renderList(previews.value,(preview,idx)=>withDirectives((openBlock(),createElementBlock(`div`,{key:idx,class:normalizeClass([`paint-preview-item`,{"empty-slot":preview.isEmpty}]),style:normalizeStyle(preview),onClick:$event=>preview.isEmpty?null:emit$1(`select`,idx)},[_cache[0]||=createStaticVNode(`
    `,5),preview.isEmpty?(openBlock(),createElementBlock(`div`,_hoisted_3$80)):createCommentVNode(``,!0)],14,_hoisted_2$92)),[[unref(BngTooltip_default),preview.tooltipText,`bottom`]])),128))]))}},PaintPreview_default=__plugin_vue_export_helper_default(_sfc_main$121,[[`__scopeId`,`data-v-38e5e63f`]]),_hoisted_1$109={class:`paint-preview-container`},_hoisted_2$91={class:`multi-paint-setups-content`},_hoisted_3$79={key:0},colorDefault=`1 1 1 1 0 1 1 0`,previewAnimTime=400,_sfc_main$120={__name:`Paint`,props:{withBackground:Boolean,tabbed:{type:Boolean,default:!0},legacy:{type:Boolean,default:!0}},setup(__props){useUINavBlocker().blockOnly([`context`]);let paintPreviews=usePaintPreviews(),props=__props,events$3=useEvents(),configId=ref(`none`),vehiclePaintPresets=ref({}),multiPaintSetups=ref({}),tabsState=ref([!0,!1,!1]);function tabExpand(idx){for(let i=0;i{tabsState.value[idx]=!0})}let color=ref([colorDefault,colorDefault,colorDefault]),updateColor=(index,preview=!0)=>nextTick(()=>{Lua_default.core_vehicle_colors.setVehicleColor(index,color.value[index]),paints[index].paint=color.value[index],preview&&updatePaint(index)});function resetScroll(){let elm=document.activeElement.closest(`.bng-accitem-content`);elm&&(elm.scrollTop=0)}let paints=Array.from({length:color.value.length},()=>reactive(new Paint({legacy:props.legacy}))),paintImgs=ref(Array(color.value.length).fill(null)),previewStyles=ref(Array(color.value.length).fill(null).map(()=>({"--paint-url":`none`,"--paint-prev-url":`none`,"--paint-prev-transition":`none`,"--paint-prev-opacity":0}))),previewAnimating=Array(color.value.length).fill(0),updatePaintPreview=async(index,url)=>{if(previewAnimating[index]===1)for(previewAnimating[index]=-1;previewAnimating[index]===-1;)await sleep(50);if(previewAnimating[index]=1,previewStyles.value[index][`--paint-prev-transition`]=`none`,paintImgs.value[index]=url,previewAnimTime===0){if(previewAnimating[index]===-1)return previewAnimating[index]=0;previewStyles.value[index][`--paint-url`]=`url(${url})`,previewAnimating[index]=0;return}let currentUrl=previewStyles.value[index][`--paint-url`];if(currentUrl===`none`||!currentUrl){if(previewAnimating[index]===-1)return previewAnimating[index]=0;previewStyles.value[index][`--paint-url`]=`url(${url})`,previewAnimating[index]=0;return}previewStyles.value[index][`--paint-prev-url`]=currentUrl,previewStyles.value[index][`--paint-url`]=`url(${url})`,previewStyles.value[index][`--paint-prev-opacity`]=1,previewStyles.value[index][`--paint-prev-transition`]=`none`,requestAnimationFrame(()=>{if(previewAnimating[index]===-1)return previewAnimating[index]=0;previewStyles.value[index][`--paint-prev-transition`]=`opacity ${previewAnimTime}ms ease-in-out`,previewStyles.value[index][`--paint-prev-opacity`]=0,setTimeout(()=>{if(previewAnimating[index]===-1)return previewAnimating[index]=0;previewStyles.value[index][`--paint-prev-transition`]=`none`,previewAnimating[index]=0},previewAnimTime)})},updatePaint=debounce(async index=>{let paintData=color.value[index];paintPreviews.getBlobPreview(paintData,{paintId:`${configId.value}:single-${index}`,width:80,height:24}).then(url=>{url&&updatePaintPreview(index,url)}).catch(()=>{})},30),updateAllPaints=async()=>{let urls=await Promise.all(paints.map(async(paint,idx)=>await paintPreviews.getBlobPreview(paint.paint,{paintId:`${configId.value}:single-${idx}`,width:80,height:24})));for(let i=0;i{let res=[];for(let i=0;ivehiclePaintPresets.value[name]);res.push({id:paintNames.join(`|`),name:setup$3.name,paintNames,paints:paints$1,apply:idx=>applyMultipaint(setup$3,idx)})}return res});function applyMultipaint(setup$3,index=-1){console.log(`applyMultipaint`,index);let paintNames=[setup$3.paintName1,setup$3.paintName2,setup$3.paintName3];for(let i=0;i-1&&i!==index)continue;let paintName=paintNames[i];if(paintName&&paintName.trim()!==``&&vehiclePaintPresets.value[paintName]){let paintData=vehiclePaintPresets.value[paintName],paint=new Paint({legacy:props.legacy});paint.paint=paintData,color.value[i]=paint.paintString,updateColor(i,!1)}}nextTick(updateAllPaints)}async function fetchDefinedColors(){for(let i=0;i__props.tabbed?(openBlock(),createElementBlock(`div`,{key:0,class:normalizeClass([`paint-acc-wrapper`,{"with-background":__props.withBackground}])},[createBaseVNode(`div`,_hoisted_1$109,[createVNode(PaintPreview_default,{paints:unref(paints),onSelect:tabExpand},null,8,[`paints`])]),withDirectives((openBlock(),createBlock(unref(accordion_default),{class:`paint-acc-container`,singular:``},{default:withCtx(()=>[createVNode(unref(accordionItem_default),{key:`multi-paint-setups`,class:`paint-acc-content`,navigable:``},{caption:withCtx(()=>[..._cache[0]||=[createTextVNode(` Multi Paint Setups `,-1)]]),default:withCtx(()=>[createBaseVNode(`div`,_hoisted_2$91,[(openBlock(!0),createElementBlock(Fragment,null,renderList(multipaint.value,paint=>(openBlock(),createBlock(unref(bngPaintTile_default),{key:paint.name,class:`multi-paint-setup-item`,"paint-id":`${configId.value}:${paint.id}`,paint:paint.paints,"paint-name":paint.name,"paint-names":paint.paintNames,width:72,height:24,"with-menu":``,onClick:paint.apply,onMenuClick:paint.apply},null,8,[`paint-id`,`paint`,`paint-name`,`paint-names`,`onClick`,`onMenuClick`]))),128))])]),_:1}),(openBlock(!0),createElementBlock(Fragment,null,renderList(color.value.length,idx=>(openBlock(),createBlock(unref(accordionItem_default),{key:idx,class:`paint-acc-content`,navigable:``,expanded:tabsState.value[idx-1],style:normalizeStyle(previewStyles.value[idx-1])},{caption:withCtx(()=>[createTextVNode(toDisplayString(_ctx.$t(`ui.trackBuilder.matEditor.paint`)+` `+idx),1)]),default:withCtx(()=>[withDirectives((openBlock(),createElementBlock(`div`,{class:`paint-picker-wrapper`,onDeactivate:resetScroll},[createVNode(PaintPicker_default,{class:`paint-picker`,"picker-mode":`compact_luminosity`,modelValue:color.value[idx-1],"onUpdate:modelValue":$event=>color.value[idx-1]=$event,onChange:$event=>updateColor(idx-1),"show-preview":!1,"presets-editable":``,presets:vehiclePaintPresets.value,legacy:__props.legacy},null,8,[`modelValue`,`onUpdate:modelValue`,`onChange`,`presets`,`legacy`])],32)),[[unref(BngScopedNav_default),{bubbleWhitelistEvents:[`menu`]}]])]),_:2},1032,[`expanded`,`style`]))),128))]),_:1})),[[unref(BngBlur_default),__props.withBackground]])],2)):withDirectives((openBlock(),createElementBlock(`div`,{key:1,class:normalizeClass([`paint-container`,{"with-background":__props.withBackground}])},[(openBlock(!0),createElementBlock(Fragment,null,renderList(color.value.length,idx=>(openBlock(),createBlock(PaintPicker_default,{key:idx,modelValue:color.value[idx-1],"onUpdate:modelValue":$event=>color.value[idx-1]=$event,onChange:$event=>updateColor(idx-1),"show-preview":!1,"presets-editable":``,presets:vehiclePaintPresets.value,legacy:__props.legacy},{default:withCtx(()=>[createTextVNode(toDisplayString(_ctx.$t(`ui.trackBuilder.matEditor.paint`))+` `+toDisplayString(idx),1)]),_:2},1032,[`modelValue`,`onUpdate:modelValue`,`onChange`,`presets`,`legacy`]))),128)),color.value.length%2==1?(openBlock(),createElementBlock(`div`,_hoisted_3$79)):createCommentVNode(``,!0)],2)),[[unref(BngBlur_default),__props.withBackground]])}},Paint_default=__plugin_vue_export_helper_default(_sfc_main$120,[[`__scopeId`,`data-v-956741b3`]]),rgxWheel=/^(\d+(?:\.\d+)?)(x)(\d+(?:\.\d+)?)/i,rgxTire=/^(\d+(?:\.\d+)?)(\/)(\d+(?:\.\d+)?)(R)(\d+(?:\.\d+)?)/i,rgxNum=/(^| )(\d+)($| )/,zeroPad=num=>String(~~(num*1e3)).padStart(10,`0`);function partOptionSorter(...ab){let cmp=[``,``];for(let i=0;i<2;i++){let label=ab[i].label;if(typeof label!=`string`)return 0;rgxWheel.test(label)?cmp[i]=label.replace(rgxWheel,(_,a$1,s,b)=>[a$1,b].map(zeroPad).join(`x`)):rgxTire.test(label)?cmp[i]=label.replace(rgxTire,(_,a$1,s1,b,s2,c)=>[a$1,b,c].map(zeroPad).join(`x`)):rgxNum.test(label)?cmp[i]=label.replace(rgxNum,(_,a$1,num,b)=>a$1+zeroPad(num)+b):cmp[i]=label,label.startsWith(`40x4`)&&console.log(cmp[i])}return cmp[0].localeCompare(cmp[1])}function partOptionGrouper(list){let seq=[],groups={},grouping=!1;for(let itm of list){let group,match=itm.label.match(rgxWheel)||itm.label.match(rgxTire);group=match&&match.length>0?match.slice(1).map(s=>s===`R`?s:s+` `).join(``).trim():itm.label,groups[group]?grouping=!0:(groups[group]=[],seq.push(group)),groups[group].push(itm)}if(!grouping)return list;let res=[];for(let group of seq){let list$1=groups[group];list$1.length===1?res.push(...list$1):(res.push({label:group,group:!0}),res.push(...list$1.map(itm=>({...itm,grouped:!0}))))}return res}var _hoisted_1$108={key:1},_sfc_main$119={__name:`PartsBranch`,props:{rootSlot:Boolean,children:Object,child:Object,info:Object,treeState:Object,treeStateKey:String,flatEntry:Boolean,displayNames:Boolean,showAuxiliary:Boolean,separateSort:Boolean,alwaysSort:Boolean,showEmpty:Boolean,highlighter:[String,Array,RegExp]},emits:[`select`,`deselect`,`highlight`,`change`,`dropdown`],setup(__props,{emit:__emit}){let props=__props,accordionItem=ref(),partsDropdown=ref(),openPartsDropdown=()=>partsDropdown.value&&partsDropdown.value.open(),emit$1=__emit,select=(slot,mouse=!1)=>(!props.child||highlightable.value)&&emit$1(`select`,slot,mouse),deselect=(slot,mouse=!1)=>emit$1(`deselect`,slot,mouse),highlight=slot=>emit$1(`highlight`,slot),change=slot=>emit$1(`change`,slot),dropdown=val=>emit$1(`dropdown`,val),focusReturn=()=>nextTick(()=>accordionItem.value.focus()),accItemUnwatch=watch(accordionItem,()=>{let elm=accordionItem.value?.captionElement;elm&&(accItemUnwatch(),elm.partSelect=()=>props.child&&select(props.child))});function toggleHighlight(slot){slot.highlight=!slot.highlight,highlight(slot)}let toggleHighlightCurrent=()=>toggleHighlight(props.child),highlightable=computed(()=>typeof props.child?.highlight==`boolean`),expanded=ref(!1);if(!props.flatEntry){let unwatchTreeState;unwatchTreeState=watch(()=>props.treeState,()=>setTimeout(()=>{unwatchTreeState(),expanded.value=props.treeStateKey&&props.treeState[props.treeStateKey]&&props.treeState[props.treeStateKey]||!1,watch(()=>expanded.value,val=>{props.treeStateKey&&(val?props.treeState[props.treeStateKey]=val:props.treeStateKey in props.treeState&&delete props.treeState[props.treeStateKey])})},50),{immediate:!0})}let childrenSorter=(a$1,b)=>{if(props.separateSort){if(a$1.children&&!b.children)return 1;if(b.children&&!a$1.children)return-1}if(props.displayNames||!props.alwaysSort)return a$1.slotName.localeCompare(b.slotName);{let info=props.info[a$1.parentSlotName]?.slotInfoUi||{};return getSlotName(a$1,info).localeCompare(getSlotName(b,info))}},slotInfo=computed(()=>props.displayNames?{}:props.info[props.child?.parentSlotName]?.slotInfoUi||{}),isCoreSlot=computed(()=>!!props.info[props.child?.parentSlotName]?.slotInfoUi?.[props.child?.slotName]?.coreSlot),getSlotName=(slot,info={})=>props.displayNames?slot.slotName:info[slot.slotName]?.description||slot.slotName,displayName=computed(()=>getSlotName(props.child,slotInfo.value)),hasPartList=computed(()=>{let list=props.child?.suitablePartNames||[];return list.length===0&&(list=props.child?.chosenPartName?[props.child.chosenPartName]:(props.child?.unsuitablePartNames||[]).map(({partName})=>partName)),props.showAuxiliary||(list=list.filter(partName=>!props.info[partName]?.isAuxiliary)),list.length>0}),partsList=computed(()=>{if(!hasPartList.value)return[];let addEmpty=!0,list=props.child?.suitablePartNames||[];list.length===0&&props.child?.chosenPartName&&(list=[props.child.chosenPartName],addEmpty=!1);let unsuitable=(props.child?.unsuitablePartNames||[]).reduce((res,{partName,reason})=>({...res,[partName]:reason}),{});return list.push(...Object.keys(unsuitable)),list.length===0||(list=list.map(partName=>({value:partName,label:(props.info[partName]?.isAuxiliary?`[!] `:``)+(props.displayNames?partName:props.info[partName]?.description||partName),disabled:partName in unsuitable,tooltip:partName in unsuitable?{text:unsuitable[partName],position:`right`}:void 0,isAuxiliary:props.info[partName]?.isAuxiliary})).filter(opt=>!opt.isAuxiliary||props.showAuxiliary||props.child?.chosenPartName===opt.value),!props.showAuxiliary&&list.length===1&&list[0].isAuxiliary&&isCoreSlot.value)?[]:(list.sort(partOptionSorter),list=partOptionGrouper(list),addEmpty&&!isCoreSlot.value&&list.unshift({value:``,label:`Empty`}),list)}),parentAllChildren=computed(()=>props.children?Object.values(props.children||{}):[]),parentHasChildren=computed(()=>parentAllChildren.value.length>0),parentChildren=computed(()=>[...parentAllChildren.value].sort(childrenSorter)),childAllChildren=computed(()=>props.child?.children?Object.values(props.child.children||{}):[]),childHasChildren=computed(()=>childAllChildren.value.length>0),childChildren=computed(()=>[...childAllChildren.value].sort(childrenSorter)),shouldShow=computed(()=>childHasChildren.value||hasPartList.value||props.showEmpty);return(_ctx,_cache)=>__props.treeState&&parentHasChildren.value?(openBlock(),createBlock(unref(accordion_default),{key:0,class:`branch-category`},{default:withCtx(()=>[(openBlock(!0),createElementBlock(Fragment,null,renderList(parentChildren.value,child=>(openBlock(),createBlock(PartsBranch_default,{key:child.slotName,"root-slot":__props.rootSlot,child,info:__props.info,"tree-state":__props.treeState,"tree-state-key":child.slotName,"display-names":__props.displayNames,"show-auxiliary":__props.showAuxiliary,"separate-sort":__props.separateSort,"always-sort":__props.alwaysSort,"show-empty":__props.showEmpty,"flat-entry":__props.flatEntry,highlighter:__props.highlighter,onSelect:select,onDeselect:deselect,onHighlight:highlight,onChange:change,onDropdown:dropdown},null,8,[`root-slot`,`child`,`info`,`tree-state`,`tree-state-key`,`display-names`,`show-auxiliary`,`separate-sort`,`always-sort`,`show-empty`,`flat-entry`,`highlighter`]))),128))]),_:1})):__props.treeState&&shouldShow.value?(openBlock(),createBlock(unref(accordionItem_default),{key:1,ref_key:`accordionItem`,ref:accordionItem,static:__props.flatEntry||!childHasChildren.value,expanded:expanded.value,onExpanded:_cache[6]||=$event=>expanded.value=$event,class:normalizeClass({"item-changed":__props.child.changed}),"arrow-big":``,navigable:``,onMouseover:_cache[7]||=withModifiers($event=>select(__props.child,!0),[`stop`]),onMouseleave:_cache[8]||=withModifiers($event=>deselect(__props.child,!0),[`stop`]),onFocusin:_cache[9]||=withModifiers($event=>select(__props.child,!1),[`stop`]),onFocusout:_cache[10]||=withModifiers($event=>deselect(__props.child,!1),[`stop`]),"primary-action":partsList.value.length>0?openPartsDropdown:void 0,"secondary-action":highlightable.value?toggleHighlightCurrent:void 0,"primary-label":`ui.inputActions.menu.menu_item_select.title`,"secondary-label":`ui.vehicleconfig.highlight`,"expand-hint-inline":``,"secondary-hint-inline":``},{caption:withCtx(()=>[withDirectives((openBlock(),createElementBlock(`span`,null,[createTextVNode(toDisplayString(displayName.value),1)])),[[unref(BngHighlighter_default),__props.highlighter]])]),controls:withCtx(()=>[createVNode(unref(bngDropdown_default),{ref_key:`partsDropdown`,ref:partsDropdown,modelValue:__props.child.chosenPartName,"onUpdate:modelValue":_cache[0]||=$event=>__props.child.chosenPartName=$event,items:partsList.value,disabled:!hasPartList.value,highlight:__props.highlighter,"show-search":partsList.value.length>5,"long-names":`cut`,onValueChanged:_cache[1]||=$event=>change(__props.child),onFocus:focusReturn,onOpen:_cache[2]||=$event=>dropdown(!0),onClose:_cache[3]||=$event=>dropdown(!1),"bng-no-nav":``},null,8,[`modelValue`,`items`,`disabled`,`highlight`,`show-search`]),createVNode(unref(bngButton_default),{accent:unref(ACCENTS).text,class:normalizeClass({"visibility-toggle":!0,"visibility-toggle-on":__props.child.highlight}),icon:__props.child.highlight?unref(icons).eyeSolidOpened:unref(icons).eyeSolidClosed,disabled:!highlightable.value,onClick:_cache[4]||=$event=>toggleHighlight(__props.child),onFocus:_cache[5]||=$event=>accordionItem.value.focus(),"bng-no-nav":``},null,8,[`accent`,`class`,`icon`,`disabled`])]),default:withCtx(()=>[!__props.flatEntry&&__props.treeState&&childHasChildren.value?(openBlock(),createBlock(PartsBranch_default,{key:0,children:childChildren.value,info:__props.info,"tree-state":__props.treeState,"display-names":__props.displayNames,"show-auxiliary":__props.showAuxiliary,"separate-sort":__props.separateSort,"always-sort":__props.alwaysSort,"show-empty":__props.showEmpty,highlighter:__props.highlighter,onSelect:select,onDeselect:deselect,onHighlight:highlight,onChange:change,onDropdown:dropdown},null,8,[`children`,`info`,`tree-state`,`display-names`,`show-auxiliary`,`separate-sort`,`always-sort`,`show-empty`,`highlighter`])):!__props.flatEntry&&__props.treeState?(openBlock(),createElementBlock(`div`,_hoisted_1$108,`—`)):createCommentVNode(``,!0)]),_:1},8,[`static`,`expanded`,`class`,`primary-action`,`secondary-action`])):createCommentVNode(``,!0)}},PartsBranch_default=__plugin_vue_export_helper_default(_sfc_main$119,[[`__scopeId`,`data-v-a5433800`]]),SearchHistory=class{list=[];index=-1;browsing=!1;saveKey=`partSearchHistory`;constructor(search$1){this.search=search$1,this.load()}load(){let res=localStorage.getItem(this.saveKey);res&&(this.list=JSON.parse(res)||[])}save(){localStorage.setItem(this.saveKey,JSON.stringify(this.list))}update(){if(this.search.query.length===0)return;let text=(isRef(this.search.text)?this.search.text.value:this.search.text).trim().replace(/ +/g,` `),textLC=text.toLowerCase(),idx=this.list.findIndex(txt=>textLC===txt.toLowerCase());if(idx>-1){this.index=idx;return}idx=this.list.findIndex(txt=>txt.toLowerCase().startsWith(textLC)),!(idx>-1)&&(idx=this.list.findIndex(txt=>textLC.startsWith(txt.toLowerCase())),idx>-1?(this.list[idx]=text,this.index=idx):(this.index=this.list.length,this.list.push(text)),this.save())}onKeyDown(event){if(this.list.length!==0){switch(event.key){case`ArrowUp`:this.browsing=!0,this.index--;break;case`ArrowDown`:this.browsing=!0,this.index++;break;case`k`:if(event.ctrlKey)console.log(`Search history cleaned`),localStorage.removeItem(`partSearchHistory`),this.list=[],this.index=0,event.preventDefault();else return;default:event.ctrlKey||(this.browsing=!1);return}this.browsing&&(this.index=Math.abs(this.index+this.list.length)%this.list.length,this.search.text=this.list[this.index]),event.preventDefault()}}},isOfficial=info=>info.authors!==`BeamNG`,PartsSearch=class{active=!1;text=ref(``);query={};message=ref(``);highlight=ref([]);minText=3;history=null;currentConfig=[];richPartInfo=[];opts={};constructor(currentConfig,richPartInfo,opts=null){if(!isRef(currentConfig))throw Error(`currentConfig must be ref`);if(!isRef(richPartInfo))throw Error(`richPartInfo must be ref`);this.currentConfig=currentConfig,this.richPartInfo=richPartInfo,opts&&(this.opts=opts),this.history=new SearchHistory(this),this.result=computed(()=>this.generateResult()),this.messages={noResults:$translate.instant(`ui.common.search.noResults`),tooShort:$translate.instant(`ui.common.search.queryTooShort`),invalidFormat:$translate.instant(`ui.common.search.invalidFormat`),unknownArgument:$translate.instant(`ui.common.search.unknownArgument`)}}generateResult(){let queryArgs=this.parseQuery(isRef(this.text)?this.text.value:this.text);if(this.query=queryArgs,this.highlight.value=queryArgs.highlight,!queryArgs.good)return this.message.value=queryArgs.reason,{};this.message.value=``;let res={},currentConfig=isRef(this.currentConfig)?this.currentConfig.value:this.currentConfig,cnt=0,dive=node=>{if(node.children)for(let child of Object.values(node.children)){let match=this.matchSlot(child);match.matched&&(child.search=match,res[child.slotName+`?`+ ++cnt]=child),dive(child)}};return dive(currentConfig),Object.keys(res).length>0?this.history.update():this.message.value=this.messages.noResults,res}parseQuery(text){let queryString=text.trim().toLowerCase().replace(/ +/g,` `),queryArgs={mode:`or`,reason:``,highlight:[]},ignoreKeys=Object.keys(queryArgs);if(queryString.length-1){let args2=arg.split(/:/);args2.length===2&&args2[1].trim()!==``?(queryArgs[args2[0]]=args2[1],parsedargs++):queryArgs.reason+=this.messages.invalidFormat+`: ${arg}\n`}else queryArgs.reason+=this.messages.unknownArgument+`: ${arg}\n`;parsedargs>1&&(queryArgs.mode=`and`)}return queryArgs.good=!queryArgs.reason,queryArgs.highlight=queryArgs.good?Object.entries(queryArgs).filter(([key])=>!ignoreKeys.includes(key)).map(([_,value])=>value):[],queryArgs}matchSlot(slot){let opts=this.opts,query=this.query,queryMode={or:(a$1,b)=>a$1||b,and:(a$1,b)=>a$1&&b}[query.mode],queryOr=query.mode===`or`,matched=!queryOr,matchDetails={slot:!1,part:!1,mod:!1},info=isRef(this.richPartInfo)?this.richPartInfo.value:this.richPartInfo,match=(string,query$1)=>matched=queryMode(matched,(string?string.toLowerCase():`empty`).indexOf(query$1)>-1);function*pairs(){query.name&&(yield[`slot`,slot.chosenPartName,query.name]),query.slot&&(yield[`slot`,slot.slotName,query.slot]),query.description&&(yield[`slot`,(slot.parentSlotName&&info[slot.parentSlotName]?.slotInfoUi?.[slot.slotName]||{}).description,query.description]);let part=slot.chosenPartName?info[slot.chosenPartName]:null;if(part?(query.description&&(yield[`slot`,part.description,query.description]),query.author&&(yield[`slot`,part.authors,query.author,!isOfficial(part)]),query.mod&&!isOfficial(part)&&(yield[`slot`,part.description,query.mod,!0])):query.description&&(yield[`slot`,null,query.description]),query.partname||query.description||query.mod||query.author)for(let partNames of[slot.suitablePartNames,slot.unsuitablePartNames.map(({partName})=>partName)])for(let partName of partNames){let part$1=info[partName];!part$1||!opts.showAux&&part$1.isAuxiliary||(query.partname&&(yield[`part`,partName,query.partname]),query.description&&(yield[`part`,part$1.description,query.description]),query.author&&(yield[`part`,part$1.authors,query.author,!isOfficial(part$1)]),query.mod&&part$1&&!isOfficial(part$1)&&(yield[`part`,part$1.description,query.mod,!0]))}}let lastType;for(let[type,string,query$1,isMod=!1]of pairs()){if(query$1&&match(string,query$1)&&(queryOr||lastType!==type)){matchDetails[type]=!0,isMod&&(matchDetails.mod=!0);break}lastType=type}return{matched,matchedSlot:matchDetails.slot,matchedOptions:matchDetails.part,matchedMod:matchDetails.mod}}onChange(){let text=isRef(this.text)?this.text.value:this.text;!this.active&&text&&this.start()}start(){this.active=!0}stop(){this.active=!1,isRef(this.text)?this.text.value=``:this.text=``,this.query={},this.history.index=-1}},_hoisted_1$107={class:`parts-browser-content`},_hoisted_2$90={key:1},_hoisted_3$78={style:{padding:`0.5em`,display:`inline-block`}},_hoisted_4$60={class:`search-help`},_hoisted_5$50={key:0},_hoisted_6$37={class:`parts-options-row parts-options-row-separator`},_hoisted_7$31={class:`parts-options-left`},_hoisted_8$24={class:`popover-contents-wrapper`},_hoisted_9$21={class:`parts-options-right`},_hoisted_10$15={class:`parts-options-row`},_hoisted_11$13={class:`license-plate`},_hoisted_12$9={class:`parts-options-right parts-options-buttons`},treeStateKey=`partsTreeState`,_sfc_main$118={__name:`Parts`,props:{withBackground:Boolean},setup(__props){let events$3=useEvents(),queue$2=new ExecQueue,currentVehID=-1,currentConfig=ref({}),richPartInfo=ref({}),partsHighlighted={},treeState=ref({}),isDev=window.beamng&&!window.beamng.shipping,savedOptions=[`applyPartChangesAutomatically`,`selectSubParts`,`showNames`,`showAux`,`separateSort`,`alwaysSort`],opts=reactive({stickyPartSelection:!1,selectSubParts:!0,applyPartChangesAutomatically:!0,simple:!1,showNames:!1,showAux:!beamng.shipping,separateSort:!1,alwaysSort:!1,showEmpty:!1}),waitingForData=ref(!0),waitForData=async()=>{for(;waitingForData.value;)await sleep(100)},search$1=reactive(new PartsSearch(currentConfig,richPartInfo,opts)),partsChanged=ref(!1),vehChange=()=>Lua_default.extensions.core_vehicle_partmgmt.sendDataToUI();events$3.on(`VehicleFocusChanged`,vehChange),events$3.on(`VehicleJbeamIoChanged`,vehChange);function iterateChildren(slot,func){func(slot),slot.children&&Object.values(slot.children).forEach(child=>iterateChildren(child,func))}async function highlightPart(part){waitingForData.value||(iterateChildren(part,child=>typeof child.highlight==`boolean`?partsHighlighted[child.partPath]=child.highlight=part.highlight:void 0),Lua_default.extensions.core_vehicle_partmgmt.highlightParts(partsHighlighted,currentVehID))}let mouseUsedLast=!0,tmrSelect,selectPart=queue$2.wrap(`selectPart`,async(slot,mouse=!1)=>{if(mouseUsedLast=mouse,tmrSelect&&clearTimeout(tmrSelect),waitingForData.value||opts.stickyPartSelection)return;let parts={};for(let part in opts.selectSubParts?iterateChildren(slot,child=>child.partPath&&(parts[child.partPath]=!0)):parts[slot.partPath]=!0,parts)part in partsHighlighted||delete parts[part];Object.keys(parts).length!==0&&await Lua_default.extensions.core_vehicle_partmgmt.selectParts(parts,currentVehID)},{selectPart:queue$2.resolution.replaceWithResolve,deselectPart:queue$2.resolution.resolveOthers,write:queue$2.resolution.resolveThis,reset:queue$2.resolution.resolveThis,resetAllToLoadedConfig:queue$2.resolution.resolveThis,restoreHighlight:queue$2.resolution.resolveThis}),deselectPart=queue$2.wrap(`deselectPart`,(slot,mouse=!1)=>{mouseUsedLast=mouse,tmrSelect&&clearTimeout(tmrSelect),!waitingForData.value&&(tmrSelect=setTimeout(async()=>{tmrSelect=null,!(opts.stickyPartSelection||Object.keys(currentConfig.value).length===0)&&await Lua_default.extensions.core_vehicle_partmgmt.showHighlightedParts(currentVehID)},100))},{deselectPart:queue$2.resolution.replaceWithResolve,write:queue$2.resolution.resolveThis,reset:queue$2.resolution.resolveThis,resetAllToLoadedConfig:queue$2.resolution.resolveThis,restoreHighlight:queue$2.resolution.resolveThis,restoreSelection:queue$2.resolution.resolveThis}),restoreHighlight=queue$2.wrap(`restoreHighlight`,()=>{tmrSelect&&clearTimeout(tmrSelect),tmrSelect=setTimeout(async()=>{tmrSelect=null,await Lua_default.extensions.core_vehicle_partmgmt.highlightParts(partsHighlighted,currentVehID)},100)},{selectPart:queue$2.resolution.replaceWithResolve,deselectPart:queue$2.resolution.replaceWithResolve,restoreHighlight:queue$2.resolution.replaceWithResolve}),restoreSelection=queue$2.wrap(`restoreSelection`,element=>{element?.partSelect?.()},{selectPart:queue$2.resolution.replaceWithResolve,deselectPart:queue$2.resolution.replaceWithResolve,restoreSelection:queue$2.resolution.replaceWithResolve}),dropdownOpened=val=>opts.stickyPartSelection=val,skipLicGen=ref(!1),licensePlate=ref(``),licensePlateTextValid=ref(!0),settingsChanged=async()=>skipLicGen.value=await Lua_default.settings.getValue(`SkipGenerateLicencePlate`),getLicensePlate=()=>bngApi.engineLua(`core_vehicles.getVehicleLicenseText(getPlayerVehicle(0))`,str=>licensePlate.value=str),applyLicensePlateDebounced=debounce(()=>{opts.applyPartChangesAutomatically&&applyLicensePlate()},500);function applyLicensePlate(){applyLicensePlateDebounced.cancel(),licensePlateTextValid.value&&Lua_default.core_vehicles.setPlateText(licensePlate.value)}function applyRandomLicensePlate(){bngApi.engineLua(`core_vehicles.setPlateText(core_vehicles.regenerateVehicleLicenseText(getPlayerVehicle(0)),nil,nil,nil)`),getLicensePlate()}let isLicensePlateTextValid=text=>(Lua_default.core_vehicles.isLicensePlateValid(text).then(valid=>{licensePlateTextValid.value=valid}),licensePlateTextValid.value),changedPart=null;async function partConfigChanged(part){changedPart=part,opts.applyPartChangesAutomatically?await write():(part.changed=!0,partsChanged.value=!0)}let write=queue$2.wrap(`write`,async()=>{waitingForData.value=!0,await Lua_default.extensions.core_vehicle_partmgmt.setPartsTreeConfig(currentConfig.value),await waitForData()},{write:queue$2.resolution.merge,reset:queue$2.resolution.resolveThis,resetAllToLoadedConfig:queue$2.resolution.resolveThis});queue$2.wrap(`reset`,async()=>{waitingForData.value=!0,await Lua_default.extensions.core_vehicle_partmgmt.resetPartsToLoadedConfig(),await waitForData()},{write:queue$2.resolution.resolveThis,reset:queue$2.resolution.merge,resetAllToLoadedConfig:queue$2.resolution.resolveThis});let resetAllToLoadedConfig=queue$2.wrap(`resetAllToLoadedConfig`,async()=>{waitingForData.value=!0,await Lua_default.extensions.core_vehicle_partmgmt.resetAllToLoadedConfig(),await waitForData()},{write:queue$2.resolution.resolveThis,reset:queue$2.resolution.resolveThis,resetAllToLoadedConfig:queue$2.resolution.merge});function processConfig(config){treeStateSave(),waitingForData.value=!0,richPartInfo.value=Object.fromEntries(Object.entries(config.richPartInfo).map(([name,info])=>[name,info.information])),partsHighlighted=config.partsHighlighted;let processSlot=(slot,slotName,parentSlotName=void 0)=>{if(slot.slotName=slotName,slot.parentSlotName=parentSlotName,changedPart&&changedPart.chosenPartName===slot.chosenPartName&&(changedPart=slot),slot.highlight=config.partsHighlighted[slot.partPath],typeof slot.children==`object`)if(Object.keys(slot.children).length===0)delete slot.children;else for(let childSlotName in slot.children)slot.children[childSlotName]=processSlot(slot.children[childSlotName],childSlotName,slot.chosenPartName);return(typeof slot.suitablePartNames!=`object`||!Array.isArray(slot.suitablePartNames))&&(slot.suitablePartNames=[]),(typeof slot.unsuitablePartNames!=`object`||!Array.isArray(slot.unsuitablePartNames))&&(slot.unsuitablePartNames=[]),slot};currentVehID=config.vehID,currentConfig.value=processSlot(config.chosenPartsTree,config.chosenPartsTree.chosenPartName),partsChanged.value=!1,waitingForData.value=!1,nextTick(()=>{opts.stickyPartSelection=!1,deselectPart(),treeStateLoad(),changedPart=null,opts.applyPartChangesAutomatically&&!mouseUsedLast?restoreSelection(document.activeElement):restoreHighlight()})}events$3.on(`VehicleConfigChange`,processConfig);let readOption=(name,val=null)=>JSON.parse(localStorage.getItem(name)||JSON.stringify(val)),saveOption=(name,val)=>localStorage.setItem(name,JSON.stringify(val)),treeStateStorage=sessionStorage,treeStateSave=()=>currentConfig.value.chosenPartName&&treeStateStorage.setItem(`${treeStateKey}_${currentConfig.value.chosenPartName}`,JSON.stringify(treeState.value)),treeStateLoad=()=>{if(!currentConfig.value.chosenPartName)return;let state=treeStateStorage.getItem(`${treeStateKey}_${currentConfig.value.chosenPartName}`);if(state)try{treeState.value=JSON.parse(state)}catch{treeState.value={}}else treeState.value={}};return onMounted(()=>{settingsChanged(),getLicensePlate(),Lua_default.extensions.core_vehicle_partmgmt.sendDataToUI();for(let name of savedOptions)opts[name]=readOption(name,opts[name])}),onUnmounted(()=>{treeStateSave(),deselectPart(!1)}),(_ctx,_cache)=>withDirectives((openBlock(),createElementBlock(`div`,{class:normalizeClass({"parts-browser":!0,"with-background":__props.withBackground})},[withDirectives((openBlock(),createElementBlock(`div`,{class:`parts-browser-search`,onActivate:_cache[5]||=(...args)=>search$1.start&&search$1.start(...args),onDeactivate:_cache[6]||=()=>!search$1.text&&search$1.stop()},[createVNode(unref(bngInput_default),{modelValue:search$1.text,"onUpdate:modelValue":_cache[0]||=$event=>search$1.text=$event,modelModifiers:{trim:!0},"leading-icon":unref(icons).search,"floating-label":`Search`,onClick:_cache[1]||=$event=>search$1.start(),onValueChanged:_cache[2]||=$event=>search$1.onChange(),onKeydown:_cache[3]||=$event=>search$1.history.onKeyDown($event)},null,8,[`modelValue`,`leading-icon`]),withDirectives(createVNode(unref(bngButton_default),{icon:unref(icons).mathMultiply,style:`font-size: 0.75rem`,accent:unref(ACCENTS).text,onClick:_cache[4]||=$event=>search$1.stop()},null,8,[`icon`,`accent`]),[[unref(BngDisabled_default),!search$1.active]])],32)),[[unref(BngScopedNav_default),{bubbleWhitelistEvents:[`menu`]}]]),withDirectives((openBlock(),createElementBlock(`div`,{class:`parts-browser-content-wrapper`,onMouseleave:_cache[7]||=(...args)=>unref(deselectPart)&&unref(deselectPart)(...args),onDeactivate:_cache[8]||=(...args)=>unref(deselectPart)&&unref(deselectPart)(...args)},[createBaseVNode(`div`,_hoisted_1$107,[!search$1.active&¤tConfig.value?.children&&Object.keys(currentConfig.value.children).length>0?(openBlock(),createBlock(PartsBranch_default,{key:0,"root-slot":``,children:currentConfig.value.children,info:richPartInfo.value,"tree-state":treeState.value,"display-names":opts.showNames,"show-auxiliary":opts.showAux,"separate-sort":opts.separateSort,"always-sort":opts.alwaysSort,"show-empty":opts.showEmpty,onSelect:unref(selectPart),onDeselect:unref(deselectPart),onHighlight:highlightPart,onChange:partConfigChanged,onDropdown:dropdownOpened},null,8,[`children`,`info`,`tree-state`,`display-names`,`show-auxiliary`,`separate-sort`,`always-sort`,`show-empty`,`onSelect`,`onDeselect`])):search$1.active?(openBlock(),createElementBlock(`div`,_hoisted_2$90,[createVNode(PartsBranch_default,{children:search$1.result,info:richPartInfo.value,"tree-state":treeState.value,"flat-entry":``,"display-names":opts.showNames,"show-auxiliary":opts.showAux,"separate-sort":opts.separateSort,"always-sort":opts.alwaysSort,"show-empty":opts.showEmpty,highlighter:search$1.highlight,onSelect:unref(selectPart),onDeselect:unref(deselectPart),onHighlight:highlightPart,onChange:partConfigChanged,onDropdown:dropdownOpened},null,8,[`children`,`info`,`tree-state`,`display-names`,`show-auxiliary`,`separate-sort`,`always-sort`,`show-empty`,`highlighter`,`onSelect`,`onDeselect`]),withDirectives(createBaseVNode(`div`,null,[createVNode(unref(bngIcon_default),{type:unref(icons).danger,color:`#d60`},null,8,[`type`]),createBaseVNode(`span`,_hoisted_3$78,toDisplayString(search$1.message),1)],512),[[vShow,search$1.message!==``]]),withDirectives(createBaseVNode(`div`,_hoisted_4$60,[_cache[37]||=createBaseVNode(`hr`,null,null,-1),_cache[38]||=createTextVNode(` Examples: `,-1),createBaseVNode(`ul`,null,[createBaseVNode(`li`,null,[_cache[23]||=createBaseVNode(`span`,{class:`search-example`},`left`,-1),_cache[24]||=createBaseVNode(`br`,null,null,-1),createTextVNode(` `+toDisplayString(_ctx.$t(`ui.vehicleconfig.searchHelp.example1`)),1)]),createBaseVNode(`li`,null,[_cache[25]||=createBaseVNode(`span`,{class:`search-example`},`slot:_fr`,-1),_cache[26]||=createBaseVNode(`br`,null,null,-1),createTextVNode(` `+toDisplayString(_ctx.$t(`ui.vehicleconfig.searchHelp.example2`)),1)]),createBaseVNode(`li`,null,[_cache[27]||=createBaseVNode(`span`,{class:`search-example`},`name:frame`,-1),_cache[28]||=createBaseVNode(`br`,null,null,-1),createTextVNode(` `+toDisplayString(_ctx.$t(`ui.vehicleconfig.searchHelp.example3`)),1)]),createBaseVNode(`li`,null,[_cache[29]||=createBaseVNode(`span`,{class:`search-example`},`slot:_fr name:signal`,-1),_cache[30]||=createBaseVNode(`br`,null,null,-1),createTextVNode(` `+toDisplayString(_ctx.$t(`ui.vehicleconfig.searchHelp.example4`)),1)]),createBaseVNode(`li`,null,[_cache[31]||=createBaseVNode(`span`,{class:`search-example`},`partname:pickup_fr`,-1),_cache[32]||=createBaseVNode(`br`,null,null,-1),createTextVNode(` `+toDisplayString(_ctx.$t(`ui.vehicleconfig.searchHelp.example5`)),1)]),createBaseVNode(`li`,null,[_cache[33]||=createBaseVNode(`span`,{class:`search-example`},`author:bob`,-1),_cache[34]||=createBaseVNode(`br`,null,null,-1),createTextVNode(` `+toDisplayString(_ctx.$t(`ui.vehicleconfig.searchHelp.example6`)),1)]),createBaseVNode(`li`,null,[_cache[35]||=createBaseVNode(`span`,{class:`search-example`},`mod:super`,-1),_cache[36]||=createBaseVNode(`br`,null,null,-1),createTextVNode(` `+toDisplayString(_ctx.$t(`ui.vehicleconfig.searchHelp.example7`)),1)])]),_cache[39]||=createBaseVNode(`hr`,null,null,-1),createTextVNode(` `+toDisplayString(_ctx.$t(`ui.vehicleconfig.searchHelp.notes`))+`: `,1),createBaseVNode(`ul`,null,[createBaseVNode(`li`,null,toDisplayString(_ctx.$t(`ui.vehicleconfig.searchHelp.notes1`)),1),createBaseVNode(`li`,null,toDisplayString(_ctx.$t(`ui.vehicleconfig.searchHelp.notes3`)),1)])],512),[[vShow,Object.keys(search$1.result).length===0]]),search$1.history.browsing&&search$1.history.list.length>0?(openBlock(),createElementBlock(`div`,_hoisted_5$50,[_cache[40]||=createBaseVNode(`hr`,null,null,-1),createTextVNode(` `+toDisplayString(_ctx.$t(`ui.vehicleconfig.searchHelp.history`))+`: `,1),_cache[41]||=createBaseVNode(`br`,null,null,-1),_cache[42]||=createBaseVNode(`br`,null,null,-1),(openBlock(!0),createElementBlock(Fragment,null,renderList(search$1.history.list,(historyEntry,idx)=>(openBlock(),createElementBlock(`span`,{class:normalizeClass({"history-entry":!0,"history-indicator":idx===search$1.history.index})},toDisplayString(historyEntry),3))),256)),_cache[43]||=createBaseVNode(`br`,null,null,-1),createTextVNode(` `+toDisplayString(_ctx.$t(`ui.vehicleconfig.searchHelp.historyClear`)),1)])):createCommentVNode(``,!0)])):createCommentVNode(``,!0)])],32)),[[unref(BngScopedNav_default),{bubbleWhitelistEvents:[`menu`]}]]),createBaseVNode(`div`,_hoisted_6$37,[createBaseVNode(`div`,_hoisted_7$31,[withDirectives(createVNode(unref(bngButton_default),{accent:unref(ACCENTS).secondary,icon:unref(icons).sortAsc,disabled:waitingForData.value},null,8,[`accent`,`icon`,`disabled`]),[[unref(BngPopover_default),`parts-options-menu`,`top-start`,{click:!0}],[unref(BngTooltip_default),_ctx.$t(`ui.garage.optionsSwitch`),`right`]]),createVNode(unref(bngPopoverMenu_default),{name:`parts-options-menu`,focus:``},{default:withCtx(()=>[createBaseVNode(`div`,_hoisted_8$24,[withDirectives((openBlock(),createBlock(unref(bngButton_default),{accent:unref(ACCENTS).menu,icon:opts.showAux?unref(icons).checkmark:unref(icons)._empty,onClick:_cache[9]||=$event=>saveOption(`showAux`,opts.showAux=!opts.showAux)},{default:withCtx(()=>[createTextVNode(toDisplayString(_ctx.$t(`ui.showAuxiliary`)),1)]),_:1},8,[`accent`,`icon`])),[[unref(BngOnUiNav_default),void 0,`ok`,{focusRequired:!0,asMouse:!0}]]),withDirectives((openBlock(),createBlock(unref(bngButton_default),{accent:unref(ACCENTS).menu,icon:opts.showNames?unref(icons).checkmark:unref(icons)._empty,onClick:_cache[10]||=$event=>saveOption(`showNames`,opts.showNames=!opts.showNames)},{default:withCtx(()=>[createTextVNode(toDisplayString(_ctx.$t(`ui.vehicleconfig.displayNames`)),1)]),_:1},8,[`accent`,`icon`])),[[unref(BngOnUiNav_default),void 0,`ok`,{focusRequired:!0,asMouse:!0}]]),withDirectives((openBlock(),createBlock(unref(bngButton_default),{accent:unref(ACCENTS).menu,icon:opts.selectSubParts?unref(icons).checkmark:unref(icons)._empty,onClick:_cache[11]||=$event=>saveOption(`selectSubParts`,opts.selectSubParts=!opts.selectSubParts)},{default:withCtx(()=>[createTextVNode(toDisplayString(_ctx.$t(`ui.vehicleconfig.subparts`)),1)]),_:1},8,[`accent`,`icon`])),[[unref(BngOnUiNav_default),void 0,`ok`,{focusRequired:!0,asMouse:!0}]]),withDirectives((openBlock(),createBlock(unref(bngButton_default),{accent:unref(ACCENTS).menu,icon:opts.separateSort?unref(icons).checkmark:unref(icons)._empty,onClick:_cache[12]||=$event=>saveOption(`separateSort`,opts.separateSort=!opts.separateSort)},{default:withCtx(()=>[..._cache[44]||=[createTextVNode(`Sort sublists separately`,-1)]]),_:1},8,[`accent`,`icon`])),[[unref(BngOnUiNav_default),void 0,`ok`,{focusRequired:!0,asMouse:!0}]]),withDirectives((openBlock(),createBlock(unref(bngButton_default),{accent:unref(ACCENTS).menu,icon:opts.alwaysSort?unref(icons).checkmark:unref(icons)._empty,onClick:_cache[13]||=$event=>saveOption(`alwaysSort`,opts.alwaysSort=!opts.alwaysSort)},{default:withCtx(()=>[..._cache[45]||=[createTextVNode(`Always sort by name`,-1)]]),_:1},8,[`accent`,`icon`])),[[unref(BngOnUiNav_default),void 0,`ok`,{focusRequired:!0,asMouse:!0}]]),unref(isDev)?withDirectives((openBlock(),createBlock(unref(bngButton_default),{key:0,accent:unref(ACCENTS).menu,icon:opts.showEmpty?unref(icons).checkmark:unref(icons)._empty,onClick:_cache[14]||=$event=>opts.showEmpty=!opts.showEmpty},{default:withCtx(()=>[..._cache[46]||=[createTextVNode(`Show empty slots 🐞`,-1)]]),_:1},8,[`accent`,`icon`])),[[unref(BngOnUiNav_default),void 0,`ok`,{focusRequired:!0,asMouse:!0}]]):createCommentVNode(``,!0)])]),_:1})]),createBaseVNode(`div`,_hoisted_9$21,[createVNode(unref(bngSwitch_default),{disabled:partsChanged.value||waitingForData.value,modelValue:opts.applyPartChangesAutomatically,"onUpdate:modelValue":_cache[15]||=$event=>opts.applyPartChangesAutomatically=$event,onValueChanged:_cache[16]||=$event=>saveOption(`applyPartChangesAutomatically`,opts.applyPartChangesAutomatically)},{default:withCtx(()=>[createTextVNode(toDisplayString(_ctx.$t(`ui.garage.liveUpdates`)),1)]),_:1},8,[`disabled`,`modelValue`])])]),createBaseVNode(`div`,_hoisted_10$15,[withDirectives((openBlock(),createElementBlock(`div`,_hoisted_11$13,[createVNode(unref(bngInput_default),{modelValue:licensePlate.value,"onUpdate:modelValue":_cache[17]||=$event=>licensePlate.value=$event,"floating-label":_ctx.$t(`ui.vehicleconfig.licensePlate`),maxlength:`50`,onValueChanged:_cache[18]||=$event=>unref(applyLicensePlateDebounced)(),onKeyup:_cache[19]||=withKeys($event=>applyLicensePlate(),[`enter`]),validate:isLicensePlateTextValid},null,8,[`modelValue`,`floating-label`]),withDirectives(createVNode(unref(bngButton_default),{accent:unref(ACCENTS).outlined,icon:unref(icons).sync,onClick:_cache[20]||=$event=>applyRandomLicensePlate()},null,8,[`accent`,`icon`]),[[unref(BngTooltip_default),_ctx.$t(`ui.vehicleconfig.licensePlateGen`),`top`]]),opts.applyPartChangesAutomatically?createCommentVNode(``,!0):withDirectives((openBlock(),createBlock(unref(bngButton_default),{key:0,disabled:!licensePlateTextValid.value,icon:unref(icons).checkmark,onClick:_cache[21]||=$event=>applyLicensePlate()},null,8,[`disabled`,`icon`])),[[unref(BngTooltip_default),_ctx.$t(`ui.vehicleconfig.applyLicensePlate`),`top`]])])),[[unref(BngDisabled_default),skipLicGen.value||waitingForData.value],[unref(BngScopedNav_default),{bubbleWhitelistEvents:[`menu`]}]]),createBaseVNode(`div`,_hoisted_12$9,[withDirectives(createVNode(unref(bngButton_default),{"show-hold":``,icon:unref(icons).undo,accent:unref(ACCENTS).custom,class:`reset-button`,disabled:waitingForData.value},null,8,[`icon`,`accent`,`disabled`]),[[unref(BngOnUiNav_default),void 0,`ok`,{asMouse:!0,focusRequired:!0}],[unref(BngClick_default),{holdCallback:unref(resetAllToLoadedConfig),holdDelay:1e3,repeatInterval:0}],[unref(BngTooltip_default),`Reset to original config`]]),createVNode(unref(bngButton_default),{class:`parts-apply-button`,icon:unref(icons).checkmark,onClick:_cache[22]||=$event=>unref(write)(),disabled:opts.applyPartChangesAutomatically||!partsChanged.value||waitingForData.value},{default:withCtx(()=>[createTextVNode(toDisplayString(_ctx.$t(`ui.common.apply`)),1)]),_:1},8,[`icon`,`disabled`])])])],2)),[[unref(BngBlur_default),__props.withBackground]])}},Parts_default=__plugin_vue_export_helper_default(_sfc_main$118,[[`__scopeId`,`data-v-13e05ae0`]]),_hoisted_1$106={key:0,class:`saveload-static`},_hoisted_2$89={class:`saveload-row saveload-filename`},_hoisted_3$77={class:`saveload-list`},_hoisted_4$59=[`onClick`],_hoisted_5$49={class:`saveload-list-item-label`},_hoisted_6$36={class:`saveload-static saveload-row saveload-controls`},_sfc_main$117={__name:`Save`,props:{withBackground:Boolean},setup(__props){useUINavBlocker().blockOnly([`context`]);let{api:api$1}=useBridge(),events$3=useEvents(),saveThumbnail=ref(!0),configList=ref([]),configFiltered=computed(()=>{let res=configList.value;return saveName.value&&(res=res.filter(itm=>itm.name.toLowerCase().includes(saveName.value.toLowerCase()))),res=res.slice().sort((a$1,b)=>a$1.player&&!b.player?-1:!a$1.player&&b.player?1:a$1.name.localeCompare(b.name)),res}),saveDisabled=computed(()=>!saveName.value||/^\.|[<>:"/\\|?*]/.test(saveName.value)),saveName=ref(``),configExists=computed(()=>!!configList.value.some(itm=>itm.name.toLowerCase()===saveName.value.toLowerCase()));async function openConfigFolderInExplorer(){await Lua_default.extensions.core_vehicle_partmgmt.openConfigFolderInExplorer()}async function save(configName){configExists.value&&!await openConfirmation(`Are you sure?`,$translate.instant(`ui.garage.save.overwrite`),[{label:`Overwrite`,value:!0},{label:`Cancel`,value:!1,extras:{accent:ACCENTS.secondary}}])||(await Lua_default.extensions.core_vehicle_partmgmt.saveLocal(configName+`.pc`),saveThumbnail.value&&api$1.engineLua(`extensions.load('util_screenshotCreator'); util_screenshotCreator.startWork({selection="${configName}"})`))}async function load(configName){await Lua_default.extensions.core_vehicle_partmgmt.loadLocal(configName+`.pc`)}async function remove$3(configName){await openConfirmation(`Are you sure?`,`This will permanently remove the configuration. You will not be able to recover it.`,[{label:`Delete permanently`,value:!0,extras:{accent:ACCENTS.attention}},{label:`Cancel`,value:!1,extras:{accent:ACCENTS.secondary}}])&&(await Lua_default.extensions.core_vehicle_partmgmt.removeLocal(configName),await getConfigList())}async function getConfigList(){let configs$1=await Lua_default.extensions.core_vehicle_partmgmt.getConfigList();configList.value=Array.isArray(configs$1)?configs$1:[]}return events$3.on(`VehicleChange`,getConfigList),events$3.on(`VehicleFocusChanged`,getConfigList),events$3.on(`VehicleconfigSaved`,getConfigList),getConfigList(),(_ctx,_cache)=>withDirectives((openBlock(),createElementBlock(`div`,{class:normalizeClass({saveload:!0,"with-background":__props.withBackground})},[configList.value?(openBlock(),createElementBlock(`div`,_hoisted_1$106,[createBaseVNode(`div`,_hoisted_2$89,[createVNode(unref(bngInput_default),{modelValue:saveName.value,"onUpdate:modelValue":_cache[0]||=$event=>saveName.value=$event,modelModifiers:{trim:!0},"leading-icon":unref(icons).saveAs1,"floating-label":_ctx.$t(`ui.vehicleconfig.filename`)},null,8,[`modelValue`,`leading-icon`,`floating-label`]),withDirectives(createVNode(unref(bngButton_default),{icon:unref(icons).mathMultiply,style:`font-size: 0.75rem`,accent:unref(ACCENTS).text,onClick:_cache[1]||=$event=>saveName.value=``},null,8,[`icon`,`accent`]),[[unref(BngDisabled_default),!saveName.value]]),withDirectives((openBlock(),createBlock(unref(bngButton_default),{accent:configExists.value?unref(ACCENTS).attention:unref(ACCENTS).main,onClick:_cache[2]||=$event=>save(saveName.value)},{default:withCtx(()=>[createTextVNode(toDisplayString(configExists.value?_ctx.$t(`ui.common.overwrite`):_ctx.$t(`ui.common.save`)),1)]),_:1},8,[`accent`])),[[unref(BngDisabled_default),saveDisabled.value]])])])):createCommentVNode(``,!0),createBaseVNode(`div`,_hoisted_3$77,[(openBlock(!0),createElementBlock(Fragment,null,renderList(configFiltered.value,config=>(openBlock(),createElementBlock(`div`,{class:`saveload-list-item`,onClick:$event=>saveName.value=config.name,tabindex:`1`},[config.official?withDirectives((openBlock(),createBlock(unref(bngIcon_default),{key:0,type:unref(icons).beamNG},null,8,[`type`])),[[unref(BngTooltip_default),_ctx.$t(`ui.vehicleconfig.sourceOfficial`),`top`]]):config.player?withDirectives((openBlock(),createBlock(unref(bngIcon_default),{key:1,type:unref(icons).personSolid},null,8,[`type`])),[[unref(BngTooltip_default),_ctx.$t(`ui.vehicleconfig.sourceUser`),`top`]]):withDirectives((openBlock(),createBlock(unref(bngIcon_default),{key:2,type:unref(icons).puzzleModule},null,8,[`type`])),[[unref(BngTooltip_default),_ctx.$t(`ui.vehicleconfig.sourceMod`),`top`]]),createBaseVNode(`div`,_hoisted_5$49,toDisplayString(config.name),1),withDirectives((openBlock(),createBlock(unref(bngButton_default),{class:`saveload-list-item-load`,accent:unref(ACCENTS).outlined,icon:unref(icons).BNGFolder,onClick:withModifiers($event=>load(config.name),[`stop`])},{default:withCtx(()=>[createTextVNode(toDisplayString(_ctx.$t(`ui.vehicleconfig.load`)),1)]),_:1},8,[`accent`,`icon`,`onClick`])),[[unref(BngTooltip_default),_ctx.$t(`ui.vehicleconfig.loadTooltip`),`top`]]),config.player?withDirectives((openBlock(),createBlock(unref(bngButton_default),{key:3,class:`saveload-list-item-delete`,accent:unref(ACCENTS).outlined,icon:unref(icons).trashBin2,onClick:withModifiers($event=>remove$3(config.name),[`stop`])},null,8,[`accent`,`icon`,`onClick`])),[[unref(BngTooltip_default),`Remove configuration`,`top`]]):createCommentVNode(``,!0)],8,_hoisted_4$59))),256))]),createBaseVNode(`div`,_hoisted_6$36,[createVNode(unref(bngSwitch_default),{modelValue:saveThumbnail.value,"onUpdate:modelValue":_cache[3]||=$event=>saveThumbnail.value=$event},{default:withCtx(()=>[createTextVNode(toDisplayString(_ctx.$t(`ui.vehicleconfig.saveThumbnail`)),1)]),_:1},8,[`modelValue`]),createVNode(unref(bngButton_default),{accent:unref(ACCENTS).main,onClick:_cache[4]||=$event=>openConfigFolderInExplorer()},{default:withCtx(()=>[createTextVNode(toDisplayString(_ctx.$t(`ui.vehicleconfig.openConfigFolder`)),1)]),_:1},8,[`accent`])])],2)),[[unref(BngBlur_default),__props.withBackground]])}},Save_default=__plugin_vue_export_helper_default(_sfc_main$117,[[`__scopeId`,`data-v-31dd4dbb`]]),_hoisted_1$105={class:`garage-row-title`},_hoisted_2$88={class:`headingContainer`},_hoisted_3$76={class:`garage-title-sup`},_hoisted_4$58={class:`garage-title-main`},_hoisted_5$48={class:`garage-row-main`},_hoisted_6$35={class:`garage-menu-container garage-menu-main`},_hoisted_7$30={key:0,class:`garage-menu garage-menu-primary`},_hoisted_8$23={key:1,class:`garage-menu garage-menu-secondary`},_hoisted_9$20={key:2,class:`garage-content`},_hoisted_10$14={class:`garage-sidemenu-title`},_hoisted_11$12={class:`garage-drawer-header`},_hoisted_12$8={class:`garage-drawer-content`},_hoisted_13$8={class:`garage-drawer-header`},_hoisted_14$8={class:`garage-drawer-content`},_hoisted_15$8={class:`garage-drawer-header`},_hoisted_16$8={class:`garage-drawer-content`},_hoisted_17$7={class:`garage-row-bottom`},ownerId=`garage`,_sfc_main$116={__name:`Garage`,props:{component:String},setup(__props){let components={paint:Paint_default,parts:Parts_default,tuning:Tuning_default,save:Save_default},uiNavTracker=useUINavTracker(),{showIfController}=storeToRefs(controls_default()),{lua,api:api$1}=useBridge(),events$3=useEvents(),bngVue$1=window.bngVue||{gotoGameState(){}},backBinding=ref(null),streamsList$1=[`electrics`];useStreams(streamsList$1,onStreamsUpdate);let drawerCamera=ref(!1),drawerVehicle=ref(!1),drawerGarage=ref(!1);watch(()=>showIfController,val=>val?uiNavTracker.addIgnore(`action_4`,ownerId):uiNavTracker.removeIgnore(`action_4`,ownerId),{immediate:!0});let launchLiveryEditor=async()=>{await runRaw(`extensions.core_vehicle_partmgmt.hasAvailablePart(be:getPlayerVehicle(0).JBeam .. "_skin_dynamicTextures")`)?await openExperimental(`Dynamic Decals`,`This is an early highly experimental preview of the Decal Editor. Please be aware that anything created with this feature may be lost in future hotfixes and updates. Do you wish to proceed?`,[{label:$translate.instant(`ui.common.no`),value:!1,extras:{accent:ACCENTS.secondary}},{label:`Yes, I'm buckled up and ready to go!`,value:!0,extras:{default:!0}}])&&bngVue$1.gotoGameState(`livery-manager`):openMessage(``,$translate.instant(`ui.garage.decals.notAvailableForVehicle`))},props=__props,sidemenuActive=ref(!1);function activateSidemenu(){sidemenuActive.value=!0}function deactivateSidemenu(){sidemenuActive.value=!1,nextTick(()=>{drawerCamera.value=!1,drawerVehicle.value=!1,drawerGarage.value=!1})}function toggleSidemenu(){sidemenuActive.value=!sidemenuActive.value}let canSidemenuDeactivate=()=>!drawerCamera.value&&!drawerVehicle.value&&!drawerGarage.value,lightState=ref([!1,!1,!1]);async function lightToggle(idx){lightState.value[idx]=!lightState.value[idx],await lua.extensions.gameplay_garageMode.setLighting(lightState.value)}async function setCamera(view){await lua.extensions.gameplay_garageMode.setCamera(view)}let switches=reactive({lowbeam:{func:`setLightsState`,value:`lights_state`,on:1,off:0,state:!1},highbeam:{func:`setLightsState`,value:`lights_state`,on:2,off:0,state:!1},fog:{func:`set_fog_lights`,value:`fog`,on:1,off:0,state:!1},lightbar:{func:`set_lightbar_signal`,value:`lightbar`,on:1,off:0,state:!1},hazard:{func:`set_warn_signal`,value:`hazard_enabled`,on:1,off:0,state:!1}});function vehSwitch(key,on){if(!(key in switches))return;let svc=switches[key];if(on===void 0)on=!svc.state;else if(on===svc.state)return;api$1.activeObjectLua(`electrics.${svc.func}(${on?svc.on:svc.off})`)}let loaded=reactive({init:!1,vehicle:!1,status:!1}),vehicle=reactive({name:`Unknown`,vehicle:null,electrics:{},state:{}}),blackscreen=ref(!1),vehcomp=ref(``),vehcompview=ref(null),tmrInit;async function menuOpen(mode){vehcomp.value=vehcomp.value===mode?``:mode;let component=null;switch(mode){case`paint`:lua.extensions.gameplay_garageMode.setGarageMenuState(`paint`),component=components.paint;break;case`decals`:bngVue$1.gotoGameState(`decals-loader`);break;case`parts`:lua.extensions.gameplay_garageMode.setGarageMenuState(`parts`),component=components.parts;break;case`tuning`:lua.extensions.gameplay_garageMode.setGarageMenuState(`tuning`),component=components.tuning;break;case`vehicles`:lua.extensions.gameplay_garageMode.setGarageMenuState(`vehicles`),bngVue$1.gotoGameState(`menu.vehicles`,{params:{mode:`garageMode`,garage:`all`}});break;case`mycars`:lua.extensions.gameplay_garageMode.setGarageMenuState(`myCars`),bngVue$1.gotoGameState(`menu.vehicles`,{params:{mode:`garageMode`,garage:`own`}});break;case`photo`:bngVue$1.gotoGameState(`menu.photomode`);break;case`save`:component=components.save;break;case`savedefault`:console.log(`TODO: save as default`);break;case`test`:vehcomp.value=``,lua.extensions.gameplay_garageMode.testVehicle();break;default:vehcomp.value=``;break}component&&(vehcompview.value=markRaw(component))}function exit(event){event.detail.force||(vehcomp.value?menuOpen():window.bngVue.gotoAngularState(`menu.mainmenu`))}async function vehChange(){loaded.vehicle=!1,loaded.status=!1,vehicle.name=`Unknown`,vehicle.vehicle=null,vehicle.electrics={},await api$1.activeObjectLua(`electrics.setIgnitionLevel(1)`);let data=await lua.core_vehicles.getCurrentVehicleDetails();tmrInit&&=(loaded.init=!0,clearTimeout(tmrInit),null),data&&(loaded.vehicle=!0,vehicle.vehicle=data,data.model.Brand?vehicle.name=`${data.model.Brand} ${data.model.Name}`:vehicle.name=data.configs.Name,data.configs.Configuration&&(data.configs.Source===`BeamNG - Official`?vehicle.name+=` - ${data.configs.Configuration}`:vehicle.name+=` - Custom`))}function onStreamsUpdate(streams){if(typeof streams!=`object`||!streamsList$1.every(name=>name in streams))return;let data=streams.electrics;for(let key in loaded.status=data.ignitionLevel>0,switches){let svc=switches[key];svc.state=svc.value in data&&data[svc.value]===svc.on,vehicle.electrics[key]=svc.state}}let canScopeDeactivate=()=>!vehcomp.value;return onBeforeMount(async()=>{tmrInit=setTimeout(()=>{console.log(`Unable to get vehicle details in time. Forcing to init...`),loaded.init=!0,tmrInit=null},3e3),events$3.on(`VehicleChange`,vehChange),api$1.activeObjectLua(`electrics.setIgnitionLevel(1)`),events$3.on(`GarageModeBlackscreen`,data=>blackscreen.value=data.active),vehChange(),lightState.value=await lua.extensions.gameplay_garageMode.getLighting(),props.component&&menuOpen(props.component)}),onUnmounted(()=>{tmrInit&&clearTimeout(tmrInit)}),(_ctx,_cache)=>(openBlock(),createElementBlock(Fragment,null,[withDirectives(createBaseVNode(`div`,{class:normalizeClass([`garage-blackscreen`,{"garage-blackscreen-active":blackscreen.value}])},null,2),[[unref(BngBlur_default),blackscreen.value]]),loaded.init?withDirectives((openBlock(),createElementBlock(`div`,{key:0,class:`garage-view`,onDeactivate:exit},[createBaseVNode(`div`,_hoisted_1$105,[createBaseVNode(`div`,_hoisted_2$88,[withDirectives((openBlock(),createElementBlock(`div`,_hoisted_3$76,[createBaseVNode(`h4`,null,[createTextVNode(toDisplayString(_ctx.$t(`ui.mainmenu.garage`))+` `,1),vehcomp.value?(openBlock(),createElementBlock(Fragment,{key:0},[createTextVNode(`/ `+toDisplayString(vehicle.name),1)],64)):createCommentVNode(``,!0)])])),[[unref(BngBlur_default)]]),withDirectives((openBlock(),createElementBlock(`h2`,_hoisted_4$58,[vehcomp.value?withDirectives((openBlock(),createBlock(unref(bngButton_default),{key:0,class:normalizeClass([`garage-back-button`,{"garage-back-binding-shown":backBinding.value?.displayed}]),accent:backBinding.value?.displayed?unref(ACCENTS).ghost:unref(ACCENTS).outlined,icon:unref(icons).arrowLargeLeft,"bng-no-nav":`true`,onClick:exit},{default:withCtx(()=>[withDirectives(createVNode(unref(bngBinding_default),{ref_key:`backBinding`,ref:backBinding,class:`back-binding`,"ui-event":`back`,controller:``,"track-ignore":``},null,512),[[vShow,!sidemenuActive.value]]),createTextVNode(` `+toDisplayString(backBinding.value?.displayed?``:_ctx.$t(`ui.common.back`)),1)]),_:1},8,[`class`,`accent`,`icon`])),[[unref(BngTooltip_default),!backBinding.value||backBinding.value?.displayed?_ctx.$t(`ui.common.back`):void 0,`top`]]):createCommentVNode(``,!0),createBaseVNode(`span`,null,toDisplayString(vehcomp.value?_ctx.$t(`ui.garage.tabs.`+(vehcomp.value===`tuning`?`tune`:vehcomp.value)):vehicle.name),1)])),[[unref(BngBlur_default)]])])]),createBaseVNode(`div`,_hoisted_5$48,[createBaseVNode(`div`,_hoisted_6$35,[vehcomp.value?createCommentVNode(``,!0):(openBlock(),createElementBlock(`div`,_hoisted_7$30,[withDirectives((openBlock(),createBlock(GarageButton_default,{icon:unref(icons).engine,active:vehcomp.value===`parts`,onClick:_cache[0]||=$event=>menuOpen(`parts`),"bng-scoped-nav-autofocus":loaded.vehicle&&!sidemenuActive.value&&unref(showIfController)},{default:withCtx(()=>[createTextVNode(toDisplayString(_ctx.$t(`ui.garage.tabs.parts`)),1)]),_:1},8,[`icon`,`active`,`bng-scoped-nav-autofocus`])),[[unref(BngDisabled_default),!loaded.vehicle],[unref(BngBlur_default)]]),withDirectives((openBlock(),createBlock(GarageButton_default,{icon:unref(icons).wrench,active:vehcomp.value===`tuning`,onClick:_cache[1]||=$event=>menuOpen(`tuning`)},{default:withCtx(()=>[createTextVNode(toDisplayString(_ctx.$t(`ui.garage.tabs.tune`)),1)]),_:1},8,[`icon`,`active`])),[[unref(BngDisabled_default),!loaded.vehicle],[unref(BngBlur_default)]]),withDirectives((openBlock(),createBlock(GarageButton_default,{icon:unref(icons).sprayCan,active:vehcomp.value===`paint`,onClick:_cache[2]||=$event=>menuOpen(`paint`)},{default:withCtx(()=>[createTextVNode(toDisplayString(_ctx.$t(`ui.garage.tabs.paint`)),1)]),_:1},8,[`icon`,`active`])),[[unref(BngDisabled_default),!loaded.vehicle],[unref(BngBlur_default)]]),withDirectives((openBlock(),createBlock(GarageButton_default,{icon:unref(icons).star,active:vehcomp.value===`decals`,onClick:launchLiveryEditor},{default:withCtx(()=>[createTextVNode(toDisplayString(_ctx.$t(`ui.garage.tabs.decals`)),1)]),_:1},8,[`icon`,`active`])),[[unref(BngDisabled_default),!loaded.vehicle],[unref(BngBlur_default)]])])),vehcomp.value?createCommentVNode(``,!0):(openBlock(),createElementBlock(`div`,_hoisted_8$23,[withDirectives((openBlock(),createBlock(GarageButton_default,{icon:unref(icons).car,active:vehcomp.value===`vehicles`,onClick:_cache[3]||=$event=>menuOpen(`vehicles`)},{default:withCtx(()=>[createTextVNode(toDisplayString(_ctx.$t(`ui.garage.tabs.vehicles`)),1)]),_:1},8,[`icon`,`active`])),[[unref(BngDisabled_default),!loaded.vehicle],[unref(BngBlur_default)]]),withDirectives((openBlock(),createBlock(GarageButton_default,{icon:unref(icons).keys1,active:vehcomp.value===`mycars`,onClick:_cache[4]||=$event=>menuOpen(`mycars`)},{default:withCtx(()=>[createTextVNode(toDisplayString(_ctx.$t(`ui.garage.tabs.load`)),1)]),_:1},8,[`icon`,`active`])),[[unref(BngDisabled_default),!loaded.vehicle],[unref(BngBlur_default)]]),withDirectives((openBlock(),createBlock(GarageButton_default,{icon:unref(icons).photo,onClick:_cache[5]||=$event=>menuOpen(`photo`)},{default:withCtx(()=>[createTextVNode(toDisplayString(_ctx.$t(`ui.garage.tabs.photo`)),1)]),_:1},8,[`icon`])),[[unref(BngDisabled_default),!loaded.vehicle],[unref(BngBlur_default)]])])),vehcomp.value&&vehcompview.value?withDirectives((openBlock(),createElementBlock(`div`,_hoisted_9$20,[(openBlock(),createBlock(resolveDynamicComponent(vehcompview.value),{"with-background":``,"with-padding":!1}))])),[[unref(BngOnUiNav_default),exit,`menu,back`],[unref(BngFrustumMover_default),!0,`left`]]):createCommentVNode(``,!0)]),withDirectives((openBlock(),createElementBlock(`div`,{class:`garage-sidemenu`,onActivate:activateSidemenu,onDeactivate:deactivateSidemenu},[withDirectives((openBlock(),createElementBlock(`h4`,_hoisted_10$14,[createVNode(unref(bngBinding_default),{class:`back-binding`,"ui-event":`action_4`,controller:``}),createTextVNode(` `+toDisplayString(_ctx.$t(`ui.garage2.features`)),1)])),[[unref(BngBlur_default)]]),createVNode(unref(drawer_default),{modelValue:drawerCamera.value,"onUpdate:modelValue":_cache[12]||=$event=>drawerCamera.value=$event,position:`left`,class:`garage-menugroup`},{header:withCtx(()=>[withDirectives((openBlock(),createElementBlock(`div`,_hoisted_11$12,[withDirectives((openBlock(),createBlock(GarageButton_default,{type:`drawer-toggle`,icon:unref(icons).movieCamera,active:drawerCamera.value,"bng-scoped-nav-autofocus":sidemenuActive.value&&unref(showIfController),onClick:_cache[6]||=$event=>drawerCamera.value=!drawerCamera.value},{default:withCtx(()=>[createTextVNode(toDisplayString(_ctx.$t(`ui.garage.photo.camera`)),1)]),_:1},8,[`icon`,`active`,`bng-scoped-nav-autofocus`])),[[unref(BngDisabled_default),!loaded.init]])])),[[unref(BngBlur_default)]])]),"expanded-content":withCtx(()=>[withDirectives((openBlock(),createElementBlock(`div`,_hoisted_12$8,[createVNode(GarageButton_default,{type:`drawer-button`,icon:unref(icons).camera3Fourth1,onClick:_cache[7]||=$event=>setCamera(`default`)},{default:withCtx(()=>[createTextVNode(toDisplayString(_ctx.$t(`engine.editor.menu.standartCamera`)),1)]),_:1},8,[`icon`]),createVNode(GarageButton_default,{type:`drawer-button`,icon:unref(icons).cameraFront1,onClick:_cache[8]||=$event=>setCamera(`front`)},{default:withCtx(()=>[createTextVNode(toDisplayString(_ctx.$t(`engine.editor.menu.camera.front`)),1)]),_:1},8,[`icon`]),createVNode(GarageButton_default,{type:`drawer-button`,icon:unref(icons).cameraBack1,onClick:_cache[9]||=$event=>setCamera(`back`)},{default:withCtx(()=>[createTextVNode(toDisplayString(_ctx.$t(`engine.editor.menu.camera.back`)),1)]),_:1},8,[`icon`]),createVNode(GarageButton_default,{type:`drawer-button`,icon:unref(icons).cameraSideRight,onClick:_cache[10]||=$event=>setCamera(`side`)},{default:withCtx(()=>[createTextVNode(toDisplayString(_ctx.$t(`engine.editor.menu.camera.right`)),1)]),_:1},8,[`icon`]),createVNode(GarageButton_default,{type:`drawer-button`,icon:unref(icons).cameraTop1,onClick:_cache[11]||=$event=>setCamera(`top`)},{default:withCtx(()=>[createTextVNode(toDisplayString(_ctx.$t(`engine.editor.menu.camera.top`)),1)]),_:1},8,[`icon`])])),[[unref(BngOnUiNav_default),toggleSidemenu,`menu,back`],[unref(BngBlur_default)]])]),_:1},8,[`modelValue`]),createVNode(unref(drawer_default),{modelValue:drawerVehicle.value,"onUpdate:modelValue":_cache[19]||=$event=>drawerVehicle.value=$event,position:`left`,class:`garage-menugroup`},{header:withCtx(()=>[withDirectives((openBlock(),createElementBlock(`div`,_hoisted_13$8,[withDirectives((openBlock(),createBlock(GarageButton_default,{type:`drawer-toggle`,icon:unref(icons).electronicSchemeOutline,active:drawerVehicle.value,onClick:_cache[13]||=$event=>drawerVehicle.value=!drawerVehicle.value},{default:withCtx(()=>[createTextVNode(toDisplayString(_ctx.$t(`ui.radialmenu2.electrics`)),1)]),_:1},8,[`icon`,`active`])),[[unref(BngDisabled_default),!loaded.vehicle||!loaded.status]])])),[[unref(BngBlur_default)]])]),"expanded-content":withCtx(()=>[withDirectives((openBlock(),createElementBlock(`div`,_hoisted_14$8,[withDirectives((openBlock(),createBlock(GarageButton_default,{type:`drawer-button`,icon:unref(icons).lowBeam,active:vehicle.electrics.lowbeam,onClick:_cache[14]||=$event=>vehSwitch(`lowbeam`)},{default:withCtx(()=>[createTextVNode(toDisplayString(_ctx.$t(`ui.radialmenu2.electrics.headlights.low`)),1)]),_:1},8,[`icon`,`active`])),[[unref(BngDisabled_default),!loaded.vehicle]]),withDirectives((openBlock(),createBlock(GarageButton_default,{type:`drawer-button`,icon:unref(icons).highBeam,active:vehicle.electrics.highbeam,onClick:_cache[15]||=$event=>vehSwitch(`highbeam`)},{default:withCtx(()=>[createTextVNode(toDisplayString(_ctx.$t(`ui.radialmenu2.electrics.headlights.high`)),1)]),_:1},8,[`icon`,`active`])),[[unref(BngDisabled_default),!loaded.vehicle]]),withDirectives((openBlock(),createBlock(GarageButton_default,{type:`drawer-button`,icon:unref(icons).fogLight,active:vehicle.electrics.fog_lights,onClick:_cache[16]||=$event=>vehSwitch(`fog`)},{default:withCtx(()=>[createTextVNode(toDisplayString(_ctx.$t(`ui.radialmenu2.electrics.fog_lights`)),1)]),_:1},8,[`icon`,`active`])),[[unref(BngDisabled_default),!loaded.vehicle]]),withDirectives((openBlock(),createBlock(GarageButton_default,{type:`drawer-button`,icon:unref(icons).hazardLights,active:vehicle.electrics.hazard,onClick:_cache[17]||=$event=>vehSwitch(`hazard`)},{default:withCtx(()=>[createTextVNode(toDisplayString(_ctx.$t(`ui.radialmenu2.electrics.hazard_lights`)),1)]),_:1},8,[`icon`,`active`])),[[unref(BngDisabled_default),!loaded.vehicle]]),withDirectives((openBlock(),createBlock(GarageButton_default,{type:`drawer-button`,icon:unref(icons).wigwags,active:vehicle.electrics.lightbar,onClick:_cache[18]||=$event=>vehSwitch(`lightbar`)},{default:withCtx(()=>[createTextVNode(toDisplayString(_ctx.$t(`ui.radialmenu2.electrics.lightbar`)),1)]),_:1},8,[`icon`,`active`])),[[unref(BngDisabled_default),!loaded.vehicle]])])),[[unref(BngOnUiNav_default),toggleSidemenu,`menu,back`],[unref(BngBlur_default)]])]),_:1},8,[`modelValue`]),createVNode(unref(drawer_default),{modelValue:drawerGarage.value,"onUpdate:modelValue":_cache[24]||=$event=>drawerGarage.value=$event,position:`left`,class:`garage-menugroup`},{header:withCtx(()=>[withDirectives((openBlock(),createElementBlock(`div`,_hoisted_15$8,[withDirectives((openBlock(),createBlock(GarageButton_default,{type:`drawer-toggle`,icon:unref(icons).garage01,active:drawerGarage.value,onClick:_cache[20]||=$event=>drawerGarage.value=!drawerGarage.value},{default:withCtx(()=>[createTextVNode(toDisplayString(_ctx.$t(`ui.garage2.features`)),1)]),_:1},8,[`icon`,`active`])),[[unref(BngDisabled_default),!loaded.init]])])),[[unref(BngBlur_default)]])]),"expanded-content":withCtx(()=>[withDirectives((openBlock(),createElementBlock(`div`,_hoisted_16$8,[createVNode(GarageButton_default,{type:`drawer-button`,icon:unref(icons).lightGarageG32,active:lightState.value[0],onClick:_cache[21]||=$event=>lightToggle(0)},{default:withCtx(()=>[createTextVNode(toDisplayString(_ctx.$t(`ui.garage2.lights.west`)),1)]),_:1},8,[`icon`,`active`]),createVNode(GarageButton_default,{type:`drawer-button`,icon:unref(icons).lightGarageG22,active:lightState.value[1],onClick:_cache[22]||=$event=>lightToggle(1)},{default:withCtx(()=>[createTextVNode(toDisplayString(_ctx.$t(`ui.garage2.lights.middle`)),1)]),_:1},8,[`icon`,`active`]),createVNode(GarageButton_default,{type:`drawer-button`,icon:unref(icons).lightGarageG12,active:lightState.value[2],onClick:_cache[23]||=$event=>lightToggle(2)},{default:withCtx(()=>[createTextVNode(toDisplayString(_ctx.$t(`ui.garage2.lights.east`)),1)]),_:1},8,[`icon`,`active`])])),[[unref(BngOnUiNav_default),toggleSidemenu,`menu,back`],[unref(BngBlur_default)]])]),_:1},8,[`modelValue`])],32)),[[unref(BngScopedNav_default),{activated:sidemenuActive.value,type:`container`,bubbleWhitelistEvents:[`menu`],canDeactivate:canSidemenuDeactivate}],[unref(BngOnUiNav_default),toggleSidemenu,`action_4`]])]),createBaseVNode(`div`,_hoisted_17$7,[withDirectives(createVNode(GarageButton_default,{active:vehcomp.value===`save`,onClick:_cache[25]||=$event=>menuOpen(`save`),icon:unref(icons).saveAs1},null,8,[`active`,`icon`]),[[unref(BngDisabled_default),!loaded.vehicle],[unref(BngBlur_default)],[unref(BngTooltip_default),_ctx.$t(`ui.vehicleconfig.save`),`top`]]),withDirectives(createVNode(GarageButton_default,{onClick:_cache[26]||=$event=>menuOpen(`test`),icon:unref(icons).trafficCone},null,8,[`icon`]),[[unref(BngDisabled_default),!loaded.vehicle],[unref(BngBlur_default)],[unref(BngTooltip_default),_ctx.$t(`ui.common.test`),`top`]])])],32)),[[unref(BngScopedNav_default),{activateOnMount:!0,bubbleWhitelistEvents:[`menu`],canDeactivate:canScopeDeactivate}],[unref(BngOnUiNav_default),toggleSidemenu,`action_4`]]):createCommentVNode(``,!0)],64))}},Garage_default=__plugin_vue_export_helper_default(_sfc_main$116,[[`__scopeId`,`data-v-b5f03823`]]),routes_default$7=[{path:`/garagemode/:component?`,name:`garagemode`,component:Garage_default,props:!0,meta:{infoBar:{visible:!0,showSysInfo:!1},uiApps:{shown:!0}}},{path:`/garagemode/tuning`,name:`garagemode.tuning`,component:Garage_default,props:{component:`tuning`},meta:{infoBar:{visible:!0,showSysInfo:!1},uiApps:{shown:!0}}}],_hoisted_1$104={class:`edit-form`},_sfc_main$115={__name:`FileEditForm`,props:{modelValue:{type:[Object,String,Number,Boolean],required:!0}},emits:[`update:modelValue`],setup(__props,{emit:__emit}){let props=__props,emit$1=__emit,formModel=computed({get:()=>props.modelValue,set:newValue=>{emit$1(`update:modelValue`,newValue)}});return(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$104,[createVNode(unref(bngInput_default),{modelValue:formModel.value.name,"onUpdate:modelValue":_cache[0]||=$event=>formModel.value.name=$event,suffix:`.dyndecals.json`},null,8,[`modelValue`])]))}},FileEditForm_default=__plugin_vue_export_helper_default(_sfc_main$115,[[`__scopeId`,`data-v-c94cd7bf`]]),_sfc_main$114={__name:`RenameLayerForm`,props:{modelValue:{type:[Object,String,Number,Boolean],required:!0}},emits:[`update:modelValue`],setup(__props,{emit:__emit}){let props=__props,emit$1=__emit,formModel=computed({get:()=>props.modelValue,set:newValue=>{emit$1(`update:modelValue`,newValue)}});return(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,null,[createVNode(unref(bngInput_default),{modelValue:formModel.value.name,"onUpdate:modelValue":_cache[0]||=$event=>formModel.value.name=$event},null,8,[`modelValue`])]))}},RenameLayerForm_default=_sfc_main$114,_hoisted_1$103={class:`exit-editor-dialog`},_hoisted_2$87={class:`apply-skin-wrapper`},_sfc_main$113={__name:`ExitEditorDialog`,props:{modelValue:{type:[Object,String,Number,Boolean],required:!0}},emits:[`update:modelValue`],setup(__props,{emit:__emit}){let props=__props,emit$1=__emit,formModel=computed({get:()=>props.modelValue,set:newValue=>{emit$1(`update:modelValue`,newValue)}});return(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$103,[createVNode(unref(bngInput_default),{modelValue:formModel.value.name,"onUpdate:modelValue":_cache[0]||=$event=>formModel.value.name=$event,suffix:`.dyndecals.json`},null,8,[`modelValue`]),createBaseVNode(`div`,_hoisted_2$87,[createVNode(unref(bngPillCheckbox_default),{modelValue:formModel.value.applySkin,"onUpdate:modelValue":_cache[1]||=$event=>formModel.value.applySkin=$event,disabled:!formModel.value.name},{default:withCtx(()=>[..._cache[2]||=[createTextVNode(`Apply Skin`,-1)]]),_:1},8,[`modelValue`,`disabled`])])]))}},ExitEditorDialog_default=__plugin_vue_export_helper_default(_sfc_main$113,[[`__scopeId`,`data-v-b4897c9e`]]);const openEditFileDialog=(title,description,formModel,formValidator)=>openFormDialog(FileEditForm_default,formModel,formValidator,title,description),openRenameLayerDialog=(title,description,formModel,formValidator)=>openFormDialog(RenameLayerForm_default,formModel,formValidator,title,description);var SELECTION_LUA$1=Lua_default.extensions.ui_liveryEditor_selection;const useLayerActionsStore=defineStore(`createLayer`,()=>{async function onActionItemSelected(action){if(!action.items)if(console.log(`[onActionItemSelected] do action`),action.value===`group`)await Lua_default.extensions.ui_liveryEditor_tools_group.groupLayers();else if(action.value===`ungroup`)await Lua_default.extensions.ui_liveryEditor_tools_group.ungroupLayer();else if(action.value===`delete`)await openConfirmation(`Delete Layer`,`Are you sure you want to delete ${singleSelectedLayer.value.name}?`)&&await Lua_default.extensions.ui_liveryEditor_tools_settings.deleteLayer();else if(action.value===`rename`){let res=await openRenameLayerDialog(`Rename Layer`,``,{name:singleSelectedLayer.value.name},model=>model.name!==null&&model.name!==void 0&&model.name!==``&&model.name!==singleSelectedLayer.value.name);res.value&&await Lua_default.extensions.ui_liveryEditor_tools_settings.rename(res.formData.name)}else action.value===`duplicate`?await SELECTION_LUA$1.duplicateSelectedLayer():await Lua_default.extensions.ui_liveryEditor_tools.useTool(action.value)}return{onActionItemSelected}});var EDIT_MODE=Lua_default.extensions.ui_liveryEditor_editMode,DECAL_LAYER=Lua_default.extensions.ui_liveryEditor_layers_decals,TRANSFORM_TOOL=Lua_default.extensions.ui_liveryEditor_tools_transform,MATERIAL_TOOL=Lua_default.extensions.ui_liveryEditor_tools_material,SETTINGS_TOOL=Lua_default.extensions.ui_liveryEditor_tools_settings;const useLayerSettingsStore=defineStore(`layerSettings`,()=>{let{events:events$3}=useBridge(),rootStore=useLiveryEditorStore(),active=ref(!1),targetLayer=ref({}),currentTool=ref(null),toolsData=ref(null),requestApplyActive=ref(!1),decalTexture=ref(null),isChangeDecal=ref(null),activeSettings=ref(null),editModeState=reactive({lockScaling:!1}),isStampMode=computed(()=>toolsData.value&&toolsData.value.mode===`stamp`),_reapplyActive=ref(!1),cursorData=ref(null),_appliedLayers=ref(null),activeLayerUid=ref(null),reapplyActive=computed({get:()=>_reapplyActive.value,set:async newValue=>{newValue?await Lua_default.extensions.ui_liveryEditor_editMode.requestReapply():await Lua_default.extensions.ui_liveryEditor_editMode.cancelReapply()}}),appliedLayers=computed(()=>!_appliedLayers.value||!Array.isArray(_appliedLayers.value)?null:_appliedLayers.value);events$3.on(`liveryEditor_EditMode_OnActiveStatusChanged`,async data=>{console.log(`liveryEditor_EditMode_OnActiveStatusChanged`,data),active.value=data}),events$3.on(`LiveryEditor_CursorUpdated`,async data=>{console.log(`LiveryEditor_CursorUpdated`,data),cursorData.value=data}),events$3.on(`LiveryEditor_SelectedLayersDataUpdated`,async data=>{console.log(`LiveryEditor_SelectedLayersDataUpdated`,data),data&&Array.isArray(data)&&data.length>0&&(targetLayer.value=data[0])}),events$3.on(`liveryEditor_OnSettingsChanged_UseMousePos`,data=>{console.log(`liveryEditor_OnSettingsChanged_UseMousePos`,data),cursorData.value&&(cursorData.value.isUseMousePos=data)}),events$3.on(`liveryEditor_OnEditMode_ReapplyChanged`,data=>{console.log(`liveryEditor_OnEditMode_ReapplyChanged`,data),_reapplyActive.value=data}),events$3.on(`LiveryEditorToolChanged`,data=>{console.log(`LiverEditorToolChanged`,data),currentTool.value=data}),events$3.on(`LiveryEditor_ToolDataUpdated`,async data=>{console.log(`LiveryEditor_ToolDataUpdated`,data),toolsData.value=data}),events$3.on(`liveryEditor_EditMode_OnRequestApplyChanged`,async data=>{console.log(`liveryEditor_EditMode_OnRequestApplyChanged`,data),requestApplyActive.value=data}),events$3.on(`liveryEditor_EditMode_OnAppliedLayersUpdated`,async data=>{console.log(`liveryEditor_EditMode_OnAppliedLayersUpdated`,data),_appliedLayers.value=data}),events$3.on(`liveryEditor_EditMode_OnActiveLayerChanged`,async data=>{console.log(`liveryEditor_EditMode_OnActiveLayerChanged`,data),activeLayerUid.value=data}),events$3.on(`liveryEditor_onDecalTextureChanged`,async data=>{console.log(`liveryEditor_onDecalTextureChanged`,data),console.log(`liveryEditor_onDecalTextureChanged active value`,active.value),active.value?!isChangeDecal.value&&!requestApplyActive.value&&await requestApply():await EDIT_MODE.activate(),await MATERIAL_TOOL.setDecal(data),rootStore.toggleShowDecalSelector(),isChangeDecal.value=null}),events$3.on(`liveryEditor_onDecalSelectorCancelled`,async data=>{console.log(`liveryEditor_onDecalSelectorCancelled`,data),active.value?rootStore.toggleShowDecalSelector():rootStore.toggleEditModeLayout(),isChangeDecal.value=null});function init$3(){active.value?EDIT_MODE.resetCursorProperties([]):rootStore.toggleShowDecalSelector()}let deactivate=async()=>{await Lua_default.extensions.ui_liveryEditor_editMode.deactivate(),rootStore.currentContext=EDITOR_CONTEXT.default,rootStore.editorView=EDITOR_VIEWS.default},toggleRequestApply=async()=>await Lua_default.extensions.ui_liveryEditor_editMode.toggleRequestApply(),requestApply=async()=>await Lua_default.extensions.ui_liveryEditor_editMode.requestApply(),cancelRequestApply=async()=>await Lua_default.extensions.ui_liveryEditor_editMode.cancelRequestApply(),getInitialData=async()=>await Lua_default.extensions.ui_liveryEditor_layers_cursor.requestData(),toggleStamp=async()=>{toolsData.value&&toolsData.value.mode===`stamp`?await Lua_default.extensions.ui_liveryEditor_tools_transform.cancelStamp():await Lua_default.extensions.ui_liveryEditor_tools_transform.useStamp()},setActiveLayer=async layerUid=>{await Lua_default.extensions.ui_liveryEditor_editMode.setActiveLayer(layerUid)},requestReapply=async()=>{await Lua_default.extensions.ui_liveryEditor_editMode.requestReapply()},cancelReapply=async()=>{await Lua_default.extensions.ui_liveryEditor_editMode.cancelReapply()},cancelChanges=async()=>{await Lua_default.extensions.ui_liveryEditor_editMode.cancelChanges(),await Lua_default.extensions.ui_liveryEditor_editMode.deactivate(),await Lua_default.extensions.ui_liveryEditor_tools.closeCurrentTool()},requestChangeDecal=async()=>{isChangeDecal.value=!0,rootStore.toggleShowDecalSelector()},toggleReapply=()=>reapplyActive.value=!reapplyActive.value,apply$1=async()=>await Lua_default.extensions.ui_liveryEditor_editMode.apply(),saveChanges=async params=>{await Lua_default.extensions.ui_liveryEditor_editMode.saveChanges(params),await Lua_default.extensions.ui_liveryEditor_editMode.deactivate(),rootStore.currentContext=EDITOR_CONTEXT.default,rootStore.editorView=EDITOR_VIEWS.default},closeCurrentTool=async()=>{await Lua_default.extensions.ui_liveryEditor_tools.closeCurrentTool()};return{...EDIT_MODE,...TRANSFORM_TOOL,...MATERIAL_TOOL,...SETTINGS_TOOL,...DECAL_LAYER,active,cursorData,appliedLayers,activeLayerUid,requestApplyActive,reapplyActive,decalTexture,editModeState,activeSettings,init:init$3,deactivate,getInitialData,toolsData,targetLayer,isStampMode,toggleStamp,requestReapply,cancelReapply,cancelChanges,requestApply,cancelRequestApply,toggleRequestApply,toggleReapply,setActiveLayer,saveChanges,requestChangeDecal,apply:apply$1,closeCurrentTool}}),useLayersManagerStore=defineStore(`layersManager`,()=>{let{events:events$3}=useBridge(),multipleSelection=ref(!1),_selection=ref([]),selectedLayers=computed({get(){return _selection.value},set(newValue){sendUpdatedSelection(newValue)}});events$3.on(`LiveryEditor_SelectedLayersChanged`,data=>{console.log(`selected Layer Updated`,data),_selection.value=data&&Array.isArray(data)&&data.length>0?data:[]});let sendUpdatedSelection=async selection=>{console.log(`sendUpdatedSelection`,selection),selection.length===0?await Lua_default.extensions.ui_liveryEditor_selection.clearSelection():multipleSelection.value?await Lua_default.extensions.ui_liveryEditor_selection.setMultipleSelected(selection):await Lua_default.extensions.ui_liveryEditor_selection.setSelected(selection)},canSort=data=>{let item=getItemByPath(data.targetDataset.draggablePath);return!(data.intersectionType===INTERSECTION_TYPES.sub&&item.type!==3)};async function clearSelection(){multipleSelection.value=!1,selectedLayers.value=[]}function getItemByPath(path){let pathSegments=path?path.split(`/`):void 0;if(!pathSegments)throw Error(`Path not defined`);let index=parseInt(pathSegments[0]),currentItem=layers.value[index];for(let i=1;i{Lua_default.extensions.ui_liveryEditor_tools_group.changeOrder(oldIndex+1,oldParentUid||``,newIndex+1,newParentUid||``)},clearSelection}});var FIRST_LAYER_ACTIONS=[{value:`edit`,label:`Edit`,icon:icons.edit,validator:()=>!0},{value:`order`,label:`Change Order`,icon:icons.order},{value:`rename`,label:`Rename`,icon:icons.rename},{value:`highlight`,label:`Highlight On`,icon:icons.eyeSolidOpened,toggleAction:!0,inactiveLabel:`Highlight Off`,inactiveIcon:icons.eyeSolidClosed},{value:`visibility`,label:`Enabled`,icon:icons.eyeOutlineOpened,toggleAction:!0,inactiveLabel:`Hidden`,inactiveIcon:icons.eyeOutlineClosed},{value:`delete`,label:`Delete`,icon:icons.trashBin2}],SELECTION_LUA=Lua_default.extensions.ui_liveryEditor_selection,SETTINGS_LUA=Lua_default.extensions.ui_liveryEditor_tools_settings,CAMERA_LUA=Lua_default.extensions.ui_liveryEditor_camera,EDITOR_LUA=Lua_default.extensions.ui_liveryEditor_editor;const EDITOR_CONTEXT={default:`default`,editMode:`editMode`,newLayer:`newLayer`};var SELECT_MODE={single:`single`,multi:`multi`};const EDITOR_VIEWS={default:`default`,decalSelector:`decalSelector`,editMode:`editMode`},useLiveryEditorStore=defineStore(`liveryEditor`,()=>{let{events:events$3}=useBridge(),layers$1=ref(null),visibleLayersCount=ref(null),selectedTool=ref(null),currentFile=ref(null),currentContext=ref(null),history$1=ref(null),selectMode=ref(SELECT_MODE.single),selectedLayers=ref([]),layerActions=ref(null),categories=ref(null),textures=ref(null),editorView=ref(EDITOR_VIEWS.main),cameraView=ref(null),showLayersManager=computed(()=>!(selectedTool.value&¤tContext.value===EDITOR_CONTEXT.editMode)),showLayerActions=computed(()=>selectedLayers.value),selectedLayerUids=computed(()=>selectedLayers.value?selectedLayers.value.map(x=>x.uid):void 0);events$3.on(`liveryEditor_OnLayersUpdated`,data=>{console.log(`liveryEditor_OnLayersUpdated`,data),layers$1.value=data}),events$3.on(`liveryEditor_Layers_OnVisibleCountChanged`,data=>{console.log(`liveryEditor_Layers_OnVisibleCountChanged`,data),visibleLayersCount.value=data}),events$3.on(`LiveryEditor_onSaveFileLoaded`,data=>{console.log(`LiveryEditor_onSaveFileLoaded`,data),currentFile.value=data}),events$3.on(`LiveryEditorLayersUpdate`,data=>{console.log(`LiveryEditorLayersUpdated`,data),layers$1.value=data}),events$3.on(`LiveryEditor_SelectedLayersDataUpdated`,async data=>{console.log(`LiveryEditor_SelectedLayersDataUpdated`,data),selectedLayers.value=data&&Array.isArray(data)?data:void 0}),events$3.on(`LiverEditorLayerActionsUpdated`,async data=>{console.log(`LiverEditorLayerActionsUpdated`,data)}),events$3.on(`LiveryEditor_onHistoryUpdated`,data=>{console.log(`LiveryEditor_onHistoryUpdated`,data),history$1.value=data}),events$3.on(`LiveryEditor_SelectedLayersChanged`,data=>{console.log(`selected Layer Updated`,data),currentContext.value=data&&data.length>0?EDITOR_CONTEXT.selectedLayer:null}),events$3.on(`LiveryEditorToolChanged`,data=>{console.log(`LiverEditorToolChanged`,data),selectedTool.value=data}),events$3.on(`LiveryEditor_OnCameraChanged`,data=>{console.log(`LiverEditorToolChanged`,data),cameraView.value=data});let dismissLayerActions=async()=>{await Lua_default.extensions.ui_liveryEditor_selection.clearSelection()},toggleEditModeLayout=async enable=>{enable=typeof enable==`boolean`?enable:currentContext.value===EDITOR_CONTEXT.default,enable?(currentContext.value=EDITOR_CONTEXT.editMode,editorView.value=EDITOR_VIEWS.editMode):(currentContext.value=EDITOR_CONTEXT.default,editorView.value=EDITOR_VIEWS.default)};function toggleShowDecalSelector(){editorView.value===EDITOR_VIEWS.decalSelector?editorView.value=EDITOR_VIEWS.editMode:editorView.value=EDITOR_VIEWS.decalSelector}let requestDismissLayerActions=()=>{currentContext.value===EDITOR_CONTEXT.newLayer?currentContext.value=null:currentContext.value===EDITOR_CONTEXT.selectedLayer&&(selectedLayers.value=[])},selectSingle=async layerUid=>{await Lua_default.extensions.ui_liveryEditor_selection.setSelected(layerUid)},toggleVisibility=async layer=>await Lua_default.extensions.ui_liveryEditor_tools_settings.toggleVisibilityById(layer.id),toggleLock=async layer=>await Lua_default.extensions.ui_liveryEditor_tools_settings.toggleLockById(layer.id),changeOrder=async(layer,direction$1)=>{direction$1===-1?await Lua_default.extensions.ui_liveryEditor_tools_group.moveOrderUpById(layer.uid):direction$1===1&&await Lua_default.extensions.ui_liveryEditor_tools_group.moveOrderDownById(layer.uid)},startEditor=async()=>{if(await Lua_default.extensions.ui_liveryEditor_editor.startEditor(),await Lua_default.extensions.ui_liveryEditor_editor.startSession(),currentContext.value=EDITOR_CONTEXT.default,editorView.value=EDITOR_VIEWS.default,await CAMERA_LUA.setOrthographicView(`right`),categories.value=await Lua_default.extensions.ui_liveryEditor_resources.getTextureCategories(),categories.value&&categories.value.length>0){let firstCategory=categories.value[0];setTexturesByCategory(firstCategory.value)}};async function setTexturesByCategory(category){textures.value=(await Lua_default.extensions.ui_liveryEditor_resources.getTexturesByCategory(category)).items}let createSaveFile=async filename=>{await Lua_default.extensions.ui_liveryEditor_userData.createSaveFile(filename)},useTool=async(toolName,params)=>{await Lua_default.extensions.ui_liveryEditor_tools.useTool(toolName)};async function onActionItemSelected(action){if(!action.items){let firstSelected=selectedLayers.value&&selectedLayers.value.length>0?selectedLayers.value[0]:null;if(action.value===`delete`)await openConfirmation(`Delete Layer`,`Are you sure you want to delete ${firstSelected.name}?`)&&await Lua_default.extensions.ui_liveryEditor_tools_settings.deleteLayer();else if(action.value===`rename`){let res=await openRenameLayerDialog(`Rename Layer`,``,{name:firstSelected.name},model=>model.name!==null&&model.name!==void 0&&model.name!==``&&model.name!==firstSelected.name);res.value&&await Lua_default.extensions.ui_liveryEditor_tools_settings.rename(res.formData.name)}else action.value===`duplicate`?await SELECTION_LUA.duplicateSelectedLayer():action.value===`visibility`?await SETTINGS_LUA.toggleVisibility():action.value===`highlight`?await SELECTION_LUA.toggleHighlightSelectedLayer():await Lua_default.extensions.ui_liveryEditor_tools.useTool(action.value)}}let editorState=reactive({isOpenExitDialog:!1,exitDialogResult:null,saving:!1});async function openExitDialog(){let res=await openFormDialog(ExitEditorDialog_default,ref({name:currentFile.value?currentFile.value.name:void 0,applySkin:!!(currentFile.value&¤tFile.value.name)}),form=>!form||!form.name?{error:!0,message:`Invalid Save Name`}:{error:!1},`Exit Editor`,null,[{label:`Cancel`,value:-1,extras:{cancel:!0,accent:ACCENTS.secondary}},{label:`Save and Exit`,value:1,emitData:!0,disableIfInvalid:!0,extras:{icon:icons.saveAs1}},{label:`Exit`,value:0,emitData:!0,extras:{accent:ACCENTS.attention,icon:icons.exit}}]);return res.value===-1?!1:(res.value===1&&await EDITOR_LUA.save(res.formData.name),res.formData.applySkin&&await EDITOR_LUA.applySkin(),await exit(),!0)}async function save(forceOpenPopup=!1){if(!currentFile.value||!currentFile.value.name||forceOpenPopup){editorState.isOpenExitDialog=!0;let res=await openEditFileDialog(`Save file`,`Enter name of your new save file`,{name:currentFile.value?currentFile.value.name:createFilename()},model=>model.name!==null&&model.name!==void 0&&model.name!==``);return res.value&&(editorState.saving=!0,await Lua_default.extensions.ui_liveryEditor_editor.save(res.formData.name),editorState.saving=!1),editorState.isOpenExitDialog=!1,res.value}else await Lua_default.extensions.ui_liveryEditor_editor.save(currentFile.value.name)}async function exit(){router_default.replace({name:`garagemode`}),await Lua_default.extensions.ui_liveryEditor_editor.exitEditor()}function createFilename(){let currentDate=new Date;return`${currentDate.getFullYear()}-${String(currentDate.getMonth()+1).padStart(2,`0`)}-${String(currentDate.getDate()).padStart(2,`0`)}_${String(currentDate.getHours()).padStart(2,`0`)}-${String(currentDate.getMinutes()).padStart(2,`0`)}-${String(currentDate.getSeconds()).padStart(2,`0`)}`}return{...SELECTION_LUA,...CAMERA_LUA,...SETTINGS_LUA,layers:layers$1,visibleLayersCount,layerActions,selectedTool,currentFile,currentContext,textures,categories,editorView,showLayersManager,showLayerActions,cameraView,editorState,dismissLayerActions,setTexturesByCategory,toggleEditModeLayout,toggleShowDecalSelector,requestDismissLayerActions,onActionItemSelected,selectMode,selectedLayers,selectedLayerUids,createSaveFile,toggleVisibility,toggleLock,startEditor,save,useTool,selectSingle,changeOrder,openExitDialog}}),SORT_OPTIONS=Object.freeze({name:`name`,modified:`modified`}),useLiveryFileStore=defineStore(`liveryFile`,()=>{let{events:events$3}=useBridge(),dataFiles=ref(null),sortKey=ref(SORT_OPTIONS.modified),sortDesc=ref(!0),files=computed(()=>{if(!dataFiles.value)return[];let sortOrder=sortDesc.value?-1:1;return dataFiles.value.sort((a$1,b)=>a$1[sortKey.value]b[sortKey.value]?1*sortOrder:0)}),init$3=async()=>{await Lua_default.extensions.ui_liveryEditor_userData.requestUpdatedData()},loadFile=async file$1=>await Lua_default.extensions.ui_liveryEditor_editor.loadFile(file$1.location),renameFile=async(file$1,newFilename)=>{await Lua_default.extensions.ui_liveryEditor_userData.renameFile(file$1.name,newFilename)},deleteFile=async file$1=>{await Lua_default.extensions.ui_liveryEditor_userData.deleteSaveFile(file$1.name)};events$3.on(`LiverySaveFilesUpdated`,data=>{data&&Array.isArray(data)&&data.length>0?(data.forEach(x=>{x.modifiedFormatted=formatDateTime(x.modified),x.fileSizeFormatted=formatSize(x.fileSize)}),dataFiles.value=data):dataFiles.value=[]});function formatDateTime(unixTime){let datetime=new Date(unixTime*1e3);return`${datetime.toLocaleDateString()} ${datetime.toLocaleTimeString()}`}function formatSize(bytes){return`${(bytes/1024).toFixed(2)} KB`}return{files,sortKey,sortDesc,init:init$3,loadFile,renameFile,deleteFile}});var EDITOR_RESOURCES_LUA=Lua_default.extensions.ui_liveryEditor_resources;const useDecalSelectorStore=defineStore(`liveryEditorDecalSelector`,()=>{let{events:events$3}=useBridge(),categories=ref(null),currentCategory=ref(null),isShow=ref(!1),textures=computed(()=>{if(!categories.value)return;let category=categories.value.find(x=>x.value===currentCategory.value);return category?category.items:void 0});async function init$3(){if(categories.value=await EDITOR_RESOURCES_LUA.getTextureCategories(),categories.value&&Array.isArray(categories.value)&&categories.value.length>0){let first=categories.value[0].value;await setCategory(first)}}async function setCategory(category){await fetchTextures(category),currentCategory.value=category}async function fetchTextures(category){let index=categories.value.findIndex(x=>x.value===category);if(index===-1)return;let textures$1=categories.value[index].items;if(index>=0&&(!textures$1||!textures$1.length===0)){let categoryWithTextures=await EDITOR_RESOURCES_LUA.getTexturesByCategory(category);categories.value[index].items=categoryWithTextures.items}}async function toggle(){isShow.value=!isShow.value,events$3.emit(`liveryEditor_onDecalStateChanged`,{show:isShow.value})}async function selectDecalItem(texturePath){await Lua_default.extensions.ui_liveryEditor_layerEdit.setup(),await Lua_default.extensions.ui_liveryEditor_layerEdit.editNewDecal({texturePath})}async function cancelSelection(){events$3.emit(`liveryEditor_onDecalSelectorCancelled`)}return{categories,currentCategory,textures,isShow,init:init$3,toggle,setCategory,selectDecalItem,cancelSelection}});var DEFAULT_ACCELERATION_RATE=.75,DEFAULT_ACCELERATION_NATURE=1.75,DEFAULT_ACTION_INTERVAL_MS=150,FOCUS_LD_TRIGGER_VALUE$2=-.5,FOCUS_RU_TRIGGER_VALUE$2=.5;const ACTION_PARAMS_TYPE={xyPoints:`xyPoints`,xPoint:`xPoint`},useActionHoldService=defineStore(`actionHoldService`,()=>{let data=ref({}),start=id=>{if(!data.value[id])throw Error(`Error starting hold action ${id}. Id not found.`);data.value[id].holdFn=setInterval(createHoldFn(id),data.value[id].actionInterval)},reset$1=id=>{let action=data.value[id];action&&(action.holdFn&&clearInterval(action.holdFn),data.value[id].holdFn=null,data.value[id].holdTimeMs=0)},add$2=(id,actionFn,immediateStart=!1,options={actionInterval:DEFAULT_ACTION_INTERVAL_MS,accelerationRate:DEFAULT_ACCELERATION_RATE,accelerationNature:DEFAULT_ACCELERATION_NATURE})=>{if(data.value[id])throw Error(`Error adding hold action for ${id}. Id already exists.`);data.value[id]={actionFn,...options,holdTimeMs:0,holdFn:null},immediateStart&&start(id)},remove$3=id=>{data.value[id]&&(reset$1(id),delete data.value[id])},removeAll=id=>{remove$3(id),remove$3(getFocusScalarName(id)),remove$3(getFocusScalarXName(id)),remove$3(getFocusScalarYName(id))},clear=()=>{let keys=Object.keys(data.value);for(let i=0;i{data.value[id]&&remove$3(id),add$2(id,actionFn,immediateStart,options)},onFocus=(id,actionFn,element,actionParamsType=ACTION_PARAMS_TYPE.xyPoints)=>{if(remove$3(getFocusScalarXName(id)),remove$3(getFocusScalarYName(id)),element.detail.value===0){remove$3(id);return}let eventName=element.detail.name,xDirection=0,yDirection=0;switch(eventName){case`focus_l`:xDirection=-1;break;case`focus_r`:xDirection=1;break;case`focus_d`:yDirection=-1;break;case`focus_u`:yDirection=1;break}switch(actionParamsType){case ACTION_PARAMS_TYPE.xyPoints:actionFn(xDirection,yDirection),addOrUpdate(id,multiplier=>actionFn(xDirection*multiplier,yDirection*multiplier),!0);break;case ACTION_PARAMS_TYPE.xPoint:let xValue=xDirection===0?yDirection:xDirection;xValue!==0&&(actionFn(xValue),addOrUpdate(id,multiplier=>actionFn(xValue*multiplier),!0));break}},inputNavStates=reactive({xLatestValue:0,yLatestValue:0,latestEventName:null}),onFocusScalar=(id,actionFn,element,actionParamsType=ACTION_PARAMS_TYPE.xyPoints)=>{console.log(`onFocusScalar`,{id,name:element.detail.name,value:element.detail.value}),remove$3(id);let eventName=element.detail.name,eventValue=element.detail.value;if(inputNavStates.latestEventName===eventName&&((eventName===`focus_lr`||eventName===`rotate_h_cam`)&&eventValue===inputNavStates.xLatestValue||(eventName===`focus_ud`||eventName===`rotate_v_cam`)&&eventValue===inputNavStates.yLatestValue))return;let xDirection=0,yDirection=0;if(eventName===`focus_lr`||eventName===`rotate_h_cam`){if(eventValue>FOCUS_RU_TRIGGER_VALUE$2&&eventValue>inputNavStates.xLatestValue?xDirection=1:eventValueactionFn(xDirection*multiplier,0),!0);break;case ACTION_PARAMS_TYPE.xPoint:actionFn(xDirection),addOrUpdate(getFocusScalarXName(id),multiplier=>actionFn(xDirection*multiplier),!0);break}inputNavStates.latestEventName=eventName}else remove$3(getFocusScalarXName(id));inputNavStates.xLatestValue=eventValue}else (eventName===`focus_ud`||eventName===`rotate_v_cam`)&&actionParamsType!==ACTION_PARAMS_TYPE.xPoint&&(eventValue>FOCUS_RU_TRIGGER_VALUE$2&&eventValue>inputNavStates.yLatestValue?yDirection=1:eventValueactionFn(0,yDirection*multiplier),!0),inputNavStates.latestEventName=eventName),inputNavStates.yLatestValue=eventValue)};function createHoldFn(id){let action=data.value[id];return()=>{let multiplier=1+action.accelerationRate*(action.holdTimeMs/1e3)**action.accelerationNature;action.actionFn(multiplier),data.value[id].holdTimeMs=action.holdTimeMs+action.actionInterval}}function getFocusScalarName(id){return`${id}_scalar`}function getFocusScalarXName(id){return`${getFocusScalarName(id)}_x`}function getFocusScalarYName(id){return`${getFocusScalarName(id)}_y`}return{onFocus,onFocusScalar,add:add$2,addOrUpdate,remove:remove$3,removeAll,clear,start,reset:reset$1}}),HEADER_SECTION_TYPE={start:`start`,center:`center`,end:`end`},useEditorHeaderStore=defineStore(`editorHeader`,()=>{let header=reactive({heading:null,preheading:[],type:`line`}),headerItems=ref([]),startSectionItems=computed(()=>headerItems.value.filter(x=>x.section===HEADER_SECTION_TYPE.start)),centerSectionItems=computed(()=>headerItems.value.filter(x=>x.section===HEADER_SECTION_TYPE.center)),endSectionItems=computed(()=>headerItems.value.filter(x=>x.section===HEADER_SECTION_TYPE.end)),headerHidden=ref(!1),itemsHidden=ref(!1),setHeader=(heading,headerType=`line`)=>{header.heading=heading,header.type=headerType},setPreheader=text=>{typeof text==`string`?header.preheading=[text]:header.preheading=text},addItems=(items$2,prepend=!1)=>{prepend?headerItems.value.unshift(...items$2):headerItems.value.push(...items$2)},addItem=(item,prepend=!1)=>{prepend?headerItems.value.unshift(item):headerItems.value.push(item)},addOrUpdateItem=(item,prepend=!1,prependIdOrIndex=0)=>{let existingIndex=-1;if(headerItems.value&&(existingIndex=headerItems.value.findIndex(x=>x.id===item.id)),existingIndex>-1)headerItems.value[existingIndex]={...item};else if(prepend){let preprendIdIndex=findIdOrIndex(prependIdOrIndex);headerItems.value.splice(preprendIdIndex,0,item)}else headerItems.value.push(item)},removeItem=itemOrId=>{let id=itemOrId.hasOwnProperty(`id`)?itemOrId.id:itemOrId,index=headerItems.value.findIndex(x=>x.id===id);index>-1&&headerItems.value.splice(index,1)},removeItems=itemsOrIds=>itemsOrIds.forEach(x=>removeItem(x)),removeItemsExcept=itemsOrIds=>{let ids=itemsOrIds.map(x=>x.hasOwnProperty(`id`)?x.id:x);removeItems(items.value.filter(x=>!ids.includes(x.id)))},showItem=itemOrId=>{let index=findIdOrIndex(itemOrId);index>-1&&(headerItems.value[index].hidden=!1)},hideItem=itemOrId=>{let index=findIdOrIndex(itemOrId);index>-1&&(headerItems.value[index].hidden=!0)},clearItems=()=>headerItems.value=[],getItem=id=>items.value.find(x=>x.id===id);function findIdOrIndex(idOrIndex){let prependIdIndex=headerItems.value.findIndex(x=>x.id===idOrIndex);return prependIdIndex===-1&&typeof idOrIndex==`number`&&idOrIndex>-1&&idOrIndex{let Controls=controls_default(),{events:events$3}=useBridge(),isSetupDone=ref(!1),{isControllerAvailable}=storeToRefs(Controls),currentSave=ref(initCurrentSave()),isLayerEditInitialized=ref(!1);watch(isControllerAvailable,async available=>{available&&await Lua_default.extensions.ui_liveryEditor.useMousePosition(!1)},{immediate:!0});async function onSetupDone(){isControllerAvailable.value&&await Lua_default.extensions.ui_liveryEditor.useMousePosition(!1)}function load(file$1){currentSave.value=file$1,isSetupDone.value=!1}function onChangeView(view){console.log(`onChangeView`,view),router_default.push({name:view})}async function setup$3(){isSetupDone.value||=(events$3.on(`liveryEditor_SetupSuccess`,onSetupDone),events$3.on(`liveryEditor_changeView`,onChangeView),await Lua_default.extensions.ui_liveryEditor.setup(currentSave.value.location),!0)}async function save(){await Lua_default.extensions.ui_liveryEditor.save(currentSave.value.name)}async function exit(){isSetupDone.value=!1,resetSave(),await Lua_default.extensions.ui_liveryEditor.deactivate()}async function setupLayerEdit(){isLayerEditInitialized.value||=(await Lua_default.extensions.ui_liveryEditor_camera.setOrthographicView(`right`),!0)}async function exitLayerEdit(){isLayerEditInitialized.value=!1}function resetSave(){currentSave.value=initCurrentSave()}function initCurrentSave(){return{name:createFilename(),location:null}}function dispose$2(){events$3.off(`liveryEditor_SetupSuccess`,onSetupDone)}function createFilename(){let currentDate=new Date;return`${currentDate.getFullYear()}-${String(currentDate.getMonth()+1).padStart(2,`0`)}-${String(currentDate.getDate()).padStart(2,`0`)}_${String(currentDate.getHours()).padStart(2,`0`)}-${String(currentDate.getMinutes()).padStart(2,`0`)}-${String(currentDate.getSeconds()).padStart(2,`0`)}`}return{currentSave,isSetupDone,load,setupLayerEdit,exitLayerEdit,save,exit,setup:setup$3,resetSave,dispose:dispose$2}});var _sfc_main$112=Object.assign({width:8,height:8,margin:.25},{__name:`DecalSelectorItem`,props:{externalImage:String},setup(__props){let props=__props;return(_ctx,_cache)=>(openBlock(),createBlock(unref(bngImageTile_default),normalizeProps(guardReactiveProps(props)),null,16))}}),DecalSelectorItem_default=_sfc_main$112,_hoisted_1$102={"bng-ui-scope":`liveryeditor-decal-selector`,class:`decal-selector`},_hoisted_2$86={class:`header-wrapper`},_hoisted_3$75={key:0,class:`filters-wrapper`},_sfc_main$111={__name:`DecalSelector`,setup(__props){useUINavScope(`liveryeditor-decal-selector`);let store$1=useDecalSelectorStore(),headerStore=useEditorHeaderStore(),selectedCategory=computed({get:()=>[store$1.currentCategory],async set(values){await store$1.setCategory(values[0])}}),switchCategory=direction$1=>{let index=store$1.categories.findIndex(x=>x.value===store$1.currentCategory);index!==-1&&(direction$1===-1?index>0?--index:index=store$1.categories.length-1:index{await store$1.init(),getUINavServiceInstance().useCrossfire=!0});let headerItemsHiddenValue=null;return onMounted(()=>{headerItemsHiddenValue=headerStore.itemsHidden,headerStore.itemsHidden||=!0}),onUnmounted(()=>{headerStore.itemsHidden=headerItemsHiddenValue}),(_ctx,_cache)=>withDirectives((openBlock(),createElementBlock(`div`,_hoisted_1$102,[createBaseVNode(`div`,_hoisted_2$86,[createVNode(unref(bngCardHeading_default),{class:`decal-selector-heading`,type:`ribbon`},{default:withCtx(()=>[..._cache[1]||=[createTextVNode(`Select Decal`,-1)]]),_:1}),createVNode(unref(bngButton_default),{"bng-no-nav":!0,accent:`attention`,label:`Close`,onClick:unref(store$1).cancelSelection},{default:withCtx(()=>[createVNode(unref(bngBinding_default),{action:`menu_item_back`})]),_:1},8,[`onClick`])]),unref(store$1).categories?(openBlock(),createElementBlock(`div`,_hoisted_3$75,[createBaseVNode(`div`,null,[createVNode(unref(bngIcon_default),{type:unref(icons).arrowSmallLeft},null,8,[`type`]),createVNode(unref(bngBinding_default),{action:`menu_tab_left`})]),createVNode(bngPillFilters_default,{modelValue:selectedCategory.value,"onUpdate:modelValue":_cache[0]||=$event=>selectedCategory.value=$event,"bng-no-child-nav":!0,options:unref(store$1).categories,required:``},null,8,[`modelValue`,`options`]),createBaseVNode(`div`,null,[createVNode(unref(bngBinding_default),{action:`menu_tab_right`}),createVNode(unref(bngIcon_default),{type:unref(icons).arrowSmallRight},null,8,[`type`])])])):createCommentVNode(``,!0),unref(store$1).textures&&unref(store$1).textures.length>0?(openBlock(),createBlock(unref(bngList_default),{key:1,noBackground:``},{default:withCtx(()=>[(openBlock(!0),createElementBlock(Fragment,null,renderList(unref(store$1).textures,(item,index)=>withDirectives((openBlock(),createBlock(DecalSelectorItem_default,{"bng-nav-item":``,key:item.preview,externalImage:item.preview,"data-decal-item":index,onClick:()=>unref(store$1).selectDecalItem(item.preview)},null,8,[`externalImage`,`data-decal-item`,`onClick`])),[[unref(BngOnUiNav_default),void 0,`ok`,{asMouse:!0,focusRequired:!0}]])),128))]),_:1})):createCommentVNode(``,!0)])),[[unref(BngBlur_default)],[unref(BngOnUiNav_default),()=>unref(store$1).cancelSelection(),`menu`],[unref(BngOnUiNav_default),()=>unref(store$1).cancelSelection(),`back`],[unref(BngOnUiNav_default),()=>switchCategory(-1),`tab_l`],[unref(BngOnUiNav_default),()=>switchCategory(1),`tab_r`]])}},DecalSelector_default=__plugin_vue_export_helper_default(_sfc_main$111,[[`__scopeId`,`data-v-e09a2ff1`]]),_hoisted_1$101={class:`decal-preview-tile`},_sfc_main$110={__name:`DecalPreviewTile`,props:{textureImage:{type:String,required:!0},textureColor:{type:Array,default:[255,255,255,1]},backgroundImage:String},setup(__props){useCssVars(_ctx=>({v036f09bc:alphaTextureBackground.value,v06c06c52:imgColor.value,v174dbaea:imageUrl.value}));let props=__props,alphaTextureBackground=computed(()=>`url(${props.backgroundImage?props.backgroundImage:getAssetURL(`images/alpha_texture.png`)}`),imageUrl=computed(()=>`url(${props.textureImage})`),imgColor=computed(()=>{let isDecimalFormat=props.textureColor.every(x=>x>=0&&x<=1),red=props.textureColor[0],green=props.textureColor[1],blue=props.textureColor[2],alpha=props.textureColor[3];return isDecimalFormat&&(red=Math.floor(red*255),green=Math.floor(green*255),blue=Math.floor(blue*255)),`rgba(${red}, ${green}, ${blue}, ${alpha})`});return(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$101,[..._cache[0]||=[createBaseVNode(`div`,{class:`image`},null,-1)]]))}},DecalPreviewTile_default=__plugin_vue_export_helper_default(_sfc_main$110,[[`__scopeId`,`data-v-8377c081`]]),_hoisted_1$100=[`disabled`],_sfc_main$109={__name:`EditModeLayersPreview`,props:{contextMenuName:String},setup(__props){let store$1=useLayerSettingsStore(),scroller=ref(null),tiles=ref({}),disabled=computed(()=>store$1.requestApplyActive||store$1.reapplyActive),onLayerClicked=async layer=>{store$1.activeLayerUid===layer.uid&&store$1.appliedLayers.length>1||await store$1.setActiveLayer(layer.uid)};watch(()=>store$1.activeLayerUid,layerUid=>{layerUid&&scrollTo(layerUid)});function setTileRef(layerUid,el){tiles.value[layerUid]=el}function scrollTo(layerUid){let tileEl=tiles.value[layerUid];if(!tileEl)return;let scrollerOffsetBottom=scroller.value.offsetTop+scroller.value.offsetHeight,scrollerOffsetTop=scroller.value.offsetTop+scroller.value.scrollTop,tileElOffsetBottom=tileEl.offsetTop+tileEl.offsetHeight,overflowsTop=tileEl.offsetTopscrollerOffsetBottom;!overflowsTop&&!overflowsBottom||window.requestAnimationFrame(()=>{overflowsTop?scroller.value.scrollBy({top:-(scrollerOffsetTop-tileEl.offsetTop)}):overflowsBottom&&(scroller.value.scrollTop=tileElOffsetBottom-scrollerOffsetBottom)})}return(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,{class:`layers-preview`,disabled:disabled.value},[createBaseVNode(`div`,{class:`item-navigation navigation-up`,onClick:_cache[0]||=$event=>unref(store$1).setActiveLayerDirection(-1)},[createVNode(unref(bngIcon_default),{type:unref(icons).arrowSmallUp},null,8,[`type`]),createVNode(unref(bngBinding_default),{action:`activate_previous_layer`,deviceMask:`xinput`,class:`navigation-icon`})]),createBaseVNode(`div`,{ref_key:`scroller`,ref:scroller,class:`preview-scroller`},[(openBlock(!0),createElementBlock(Fragment,null,renderList(unref(store$1).appliedLayers,layer=>(openBlock(),createElementBlock(`div`,{ref_for:!0,ref:el=>setTileRef(layer.uid,el),key:layer.uid,class:normalizeClass([{active:unref(store$1).activeLayerUid===layer.uid},`layer-item`])},[unref(store$1).activeLayerUid===layer.uid?withDirectives((openBlock(),createBlock(DecalPreviewTile_default,{key:0,class:`preview-img`,textureImage:layer.preview,textureColor:layer.color},null,8,[`textureImage`,`textureColor`])),[[unref(BngPopover_default),`context-menu`,`right`,{click:!0}]]):(openBlock(),createBlock(DecalPreviewTile_default,{key:1,class:`preview-img`,textureImage:layer.preview,textureColor:layer.color,onClick:()=>onLayerClicked(layer)},null,8,[`textureImage`,`textureColor`,`onClick`])),unref(store$1).activeLayerUid===layer.uid?(openBlock(),createBlock(unref(bngIcon_default),{key:2,class:`contextmenu-icon`,type:unref(icons).edit},null,8,[`type`])):createCommentVNode(``,!0)],2))),128))],512),createBaseVNode(`div`,{class:`item-navigation navigation-down`,onClick:_cache[1]||=$event=>unref(store$1).setActiveLayerDirection(1)},[createVNode(unref(bngBinding_default),{action:`activate_next_layer`,deviceMask:`xinput`,class:`navigation-icon`}),createVNode(unref(bngIcon_default),{type:unref(icons).arrowSmallDown},null,8,[`type`])])],8,_hoisted_1$100))}},EditModeLayersPreview_default=__plugin_vue_export_helper_default(_sfc_main$109,[[`__scopeId`,`data-v-9ede6133`]]),_hoisted_1$99={class:`material-settings`,"bng-ui-scope":`material-settings`},_hoisted_2$85={class:`subsettings-selector`},_hoisted_3$74=[`onClick`],_hoisted_4$57={class:`settings-content`},_hoisted_5$47={key:0,class:`setting-item color-setting`},_hoisted_6$34={key:1,class:`setting-item item-column`},_hoisted_7$29={class:`slider-text-container`},_hoisted_8$22={key:2,class:`setting-item item-column`},_hoisted_9$19={class:`slider-text-container`},_hoisted_10$13={key:3,class:`setting-item item-column`},_hoisted_11$11={class:`slider-text-container`},INPUT_CONTROL_STEPS$4=.01,INPUT_CONTROL_MIN$4=0,INPUT_CONTROL_MAX$4=1,CONTROLLER_SLIDER_BINDING=`focus_lr`,CONTROLLER_CHANGE_SUBSETTINGS_HINTS=[{id:`activate_previous_subsettings`,content:{type:`binding`,props:{uiEvent:`focus_u`},label:`Previous Setting`}},{id:`activate_next_subsettings`,content:{type:`binding`,props:{uiEvent:`focus_d`},label:`Next Setting`}}],subSettings=[{label:`Color`,icon:icons.colorCirclePalette,value:`color`},{label:`Saturation`,icon:icons.colorSaturation,value:`saturation`},{label:`Metalness`,icon:icons.materialMetal,value:`metallicIntensity`},{label:`Roughness`,icon:icons.materialRoughness,value:`roughnessIntensity`}],_sfc_main$108={__name:`LayerMaterialSettings`,emits:[`subSettingChanged`],setup(__props,{emit:__emit}){let emit$1=__emit,store$1=useLayerSettingsStore(),actionHoldService=useActionHoldService(),{showIfController}=storeToRefs(controls_default()),infoBar=useInfoBar(),activeSubSettingsIndex=ref(0),_color=reactive({hue:.5,saturation:1,luminosity:.5}),color=computed({get:()=>_color,set:async newValue=>{let paint=new Paint;paint.hsl=[newValue.hue,newValue.saturation,newValue.luminosity],await store$1.setColor([paint.red,paint.green,paint.blue,paint.alpha])}}),saturation=computed({get:()=>_color.saturation,set:async newValue=>{let sat=parseFloat(newValue.toFixed(2));color.value={hue:color.value.hue,saturation:sat,luminosity:color.value.luminosity},_color.saturation=sat}}),metallicIntensity=computed({get:()=>store$1.cursorData?store$1.cursorData.metallicIntensity:void 0,set:async newValue=>{await store$1.setMetallicIntensity(newValue)}}),roughnessIntensity=computed({get:()=>store$1.cursorData?store$1.cursorData.roughnessIntensity:void 0,set:async newValue=>{await store$1.setRoughnessIntensity(newValue)}}),activeSubSetting=computed(()=>subSettings[activeSubSettingsIndex.value]);watch(()=>store$1.activeLayerUid,(newValue,oldValue)=>{newValue&&oldValue&&initColorPicker(store$1.cursorData.color)},{deep:!0}),watch(activeSubSetting,(value,oldValue)=>{oldValue&&actionHoldService.remove(oldValue),setHints(),emit$1(`subSettingChanged`,value)},{immediate:!0}),onBeforeUnmount(()=>{actionHoldService.removeAll(`color`),actionHoldService.removeAll(`saturation`),actionHoldService.removeAll(`metallicIntensity`),actionHoldService.removeAll(`roughnessIntensity`),emit$1(`subSettingChanged`,void 0)}),onMounted(()=>{store$1.cursorData.color&&initColorPicker(store$1.cursorData.color)});let goPreviousSubSetting=()=>{activeSubSettingsIndex.value>0?--activeSubSettingsIndex.value:activeSubSettingsIndex.value=subSettings.length-1},goNextSubSetting=()=>{activeSubSettingsIndex.valuechangeColor(hue,luminosity,0);break;case`saturation`:actionFn=saturation$1=>changeColor(0,0,saturation$1);break;case`metallicIntensity`:actionFn=changeMetallicIntensity,actionParamsType=ACTION_PARAMS_TYPE.xPoint;break;case`roughnessIntensity`:actionFn=changeRoughnessIntensity,actionParamsType=ACTION_PARAMS_TYPE.xPoint;break}scalar?actionHoldService.onFocusScalar(subsettingValue,actionFn,element,actionParamsType):actionHoldService.onFocus(subsettingValue,actionFn,element,actionParamsType)}}async function changeColor(h$1,l,s){let newHue=color.value.hue+.01*h$1,newLuminosity=color.value.luminosity+.01*l,newSaturation=parseFloat((color.value.saturation+.1*s).toFixed(2));(newHue<0||newHue>1)&&(newHue=color.value.hue),(newLuminosity<0||newLuminosity>1)&&(newLuminosity=color.value.luminosity),(newSaturation<0||newSaturation>1)&&(newSaturation=color.value.saturation),_color.hue=newHue,_color.saturation=newSaturation,_color.luminosity=newLuminosity;let paint=new Paint;paint.hsl=[newHue,newSaturation,newLuminosity],store$1.setColor([paint.red,paint.green,paint.blue,paint.alpha])}let changeMetallicIntensity=direction$1=>{let newValue=metallicIntensity.value+.1*direction$1;newValue>=0&&newValue<=1&&(metallicIntensity.value=newValue)},changeRoughnessIntensity=direction$1=>{let newValue=roughnessIntensity.value+.1*direction$1;newValue>=0&&newValue<=1&&(roughnessIntensity.value=newValue)};function updateColorPickerModel(rgba){let paint=new Paint;paint.rgba=rgba,_color.hue=paint.hue,_color.saturation=paint.saturation,_color.luminosity=paint.luminosity}store$1.$onAction(({name,store:store$2,args,after,onError})=>{after(result=>{name===`resetCursorProperties`&&args[0].includes(`material`)&&initColorPicker(store$2.cursorData.color)})});function onReset(){let defaultColor=[1,1,1,1];switch(activeSubSetting.value.value){case`color`:store$1.setColor(defaultColor),updateColorPickerModel(defaultColor),saturation.value=1;break;case`saturation`:saturation.value=1;break;case`metallicIntensity`:metallicIntensity.value=0;break;case`roughnessIntensity`:roughnessIntensity.value=0;break}}function onTertiaryAction(){if(store$1.reapplyActive||store$1.requestApplyActive)onReset();else return!0}function initColorPicker(color$1){let isWhite=color$1.every(x=>x===1),paint=new Paint;paint.rgba=color$1,_color.hue=paint.hue,_color.saturation=isWhite?1:paint.saturation,_color.luminosity=paint.luminosity}useUINavScope(`material-settings`);let useCrossfireValue;onBeforeMount(()=>{useCrossfireValue=getUINavServiceInstance().useCrossfire,getUINavServiceInstance().useCrossfire=!1}),onBeforeUnmount(()=>{getUINavServiceInstance().useCrossfire=useCrossfireValue});let unwatchGamepad;onBeforeMount(()=>{unwatchGamepad=watch(showIfController,async()=>{await nextTick(()=>setHints())},{immediate:!0})}),onUnmounted(()=>{unwatchGamepad&&unwatchGamepad(),removeHints()});function setHints(){removeHints(),showIfController.value&&infoBar.addHints(CONTROLLER_CHANGE_SUBSETTINGS_HINTS)}function removeHints(){infoBar.removeHints(...CONTROLLER_CHANGE_SUBSETTINGS_HINTS.map(x=>x.id))}return(_ctx,_cache)=>withDirectives((openBlock(),createElementBlock(`div`,_hoisted_1$99,[createBaseVNode(`div`,_hoisted_2$85,[(openBlock(),createElementBlock(Fragment,null,renderList(subSettings,(subtab,index)=>withDirectives(createBaseVNode(`div`,{key:subtab.value,class:normalizeClass([{active:index===activeSubSettingsIndex.value},`subsettings-selector-item`]),onClick:()=>activeSubSettingsIndex.value=index},[createVNode(unref(bngIcon_default),{type:subtab.icon,class:`selector-item-icon`},null,8,[`type`])],10,_hoisted_3$74),[[unref(BngTooltip_default),index===activeSubSettingsIndex.value?void 0:subtab.label,`left`]])),64))]),createBaseVNode(`div`,_hoisted_4$57,[activeSubSetting.value.value===`color`?(openBlock(),createElementBlock(`div`,_hoisted_5$47,[createVNode(unref(bngColorPicker_default),{modelValue:color.value,"onUpdate:modelValue":_cache[0]||=$event=>color.value=$event,view:`luminosity`},null,8,[`modelValue`])])):createCommentVNode(``,!0),activeSubSetting.value.value===`saturation`?(openBlock(),createElementBlock(`div`,_hoisted_6$34,[createBaseVNode(`div`,_hoisted_7$29,[createVNode(unref(bngSlider_default),{modelValue:saturation.value,"onUpdate:modelValue":_cache[1]||=$event=>saturation.value=$event,min:INPUT_CONTROL_MIN$4,max:INPUT_CONTROL_MAX$4,step:INPUT_CONTROL_STEPS$4},null,8,[`modelValue`]),createVNode(unref(bngInput_default),{modelValue:saturation.value,"onUpdate:modelValue":_cache[2]||=$event=>saturation.value=$event,type:`number`,min:INPUT_CONTROL_MIN$4,max:INPUT_CONTROL_MAX$4,step:INPUT_CONTROL_STEPS$4},null,8,[`modelValue`]),createVNode(unref(bngBinding_default),{uiEvent:CONTROLLER_SLIDER_BINDING,deviceMask:`xinput`})])])):activeSubSetting.value.value===`metallicIntensity`?(openBlock(),createElementBlock(`div`,_hoisted_8$22,[createBaseVNode(`div`,_hoisted_9$19,[createVNode(unref(bngSlider_default),{modelValue:metallicIntensity.value,"onUpdate:modelValue":_cache[3]||=$event=>metallicIntensity.value=$event,min:INPUT_CONTROL_MIN$4,max:INPUT_CONTROL_MAX$4,step:INPUT_CONTROL_STEPS$4},null,8,[`modelValue`]),createVNode(unref(bngInput_default),{modelValue:metallicIntensity.value,"onUpdate:modelValue":_cache[4]||=$event=>metallicIntensity.value=$event,type:`number`,min:INPUT_CONTROL_MIN$4,max:INPUT_CONTROL_MAX$4,step:INPUT_CONTROL_STEPS$4},null,8,[`modelValue`]),createVNode(unref(bngBinding_default),{uiEvent:CONTROLLER_SLIDER_BINDING,deviceMask:`xinput`})])])):activeSubSetting.value.value===`roughnessIntensity`?(openBlock(),createElementBlock(`div`,_hoisted_10$13,[createBaseVNode(`div`,_hoisted_11$11,[createVNode(unref(bngSlider_default),{modelValue:roughnessIntensity.value,"onUpdate:modelValue":_cache[5]||=$event=>roughnessIntensity.value=$event,min:INPUT_CONTROL_MIN$4,max:INPUT_CONTROL_MAX$4,step:INPUT_CONTROL_STEPS$4},null,8,[`modelValue`]),createVNode(unref(bngInput_default),{modelValue:roughnessIntensity.value,"onUpdate:modelValue":_cache[6]||=$event=>roughnessIntensity.value=$event,type:`number`,min:INPUT_CONTROL_MIN$4,max:INPUT_CONTROL_MAX$4,step:INPUT_CONTROL_STEPS$4},null,8,[`modelValue`]),createVNode(unref(bngBinding_default),{uiEvent:CONTROLLER_SLIDER_BINDING,deviceMask:`xinput`})])])):createCommentVNode(``,!0)])])),[[unref(BngOnUiNav_default),goNextSubSetting,`action_2`],[unref(BngOnUiNav_default),onTertiaryAction,`action_3`],[unref(BngOnUiNav_default),onFocus,`focus_l`,{up:!0}],[unref(BngOnUiNav_default),onFocus,`focus_l`,{down:!0}],[unref(BngOnUiNav_default),onFocus,`focus_r`,{down:!0}],[unref(BngOnUiNav_default),onFocus,`focus_r`,{up:!0}],[unref(BngOnUiNav_default),onFocus,`focus_u`,{up:!0}],[unref(BngOnUiNav_default),onFocus,`focus_u`,{down:!0}],[unref(BngOnUiNav_default),onFocus,`focus_d`,{down:!0}],[unref(BngOnUiNav_default),onFocus,`focus_d`,{up:!0}],[unref(BngOnUiNav_default),el=>onFocus(el,!0),`focus_lr`],[unref(BngOnUiNav_default),el=>onFocus(el,!0),`focus_ud`]])}},LayerMaterialSettings_default=__plugin_vue_export_helper_default(_sfc_main$108,[[`__scopeId`,`data-v-ffe74e63`]]),_hoisted_1$98={class:`mirror-settings`,"bng-ui-scope":`mirror-settings`},_hoisted_2$84={class:`setting-item`},_hoisted_3$73={class:`setting-item offset-item`},_hoisted_4$56={class:`setting-item offset-item`},FOCUS_LD_TRIGGER_VALUE$1=-.999,FOCUS_RU_TRIGGER_VALUE$1=.999,FOCUS_HOLD_INTERVAL_MS=250,MIRROR_BINDING=`focus_l`,FLIP_BINDING=`focus_r`,CONTROLLER_OFFSET_BINDING=`focus_ud`,CONTROLLER_HINTS$4=[],KEYBOARD_HINTS$4=[],_sfc_main$107={__name:`LayerMirrorSettings`,setup(__props){let store$1=useLayerSettingsStore(),{showIfController}=storeToRefs(controls_default()),infoBar=useInfoBar(),inputNavStates=reactive({focusXLatestValue:0,focusYLatestValue:0,holdEventLatest:null,holdInterval:null}),mirror=computed({get:()=>store$1.cursorData?store$1.cursorData.mirrored:void 0,set:async newValue=>await store$1.setMirrored(newValue,store$1.cursorData.flipMirroredDecal)}),flip$2=computed({get:()=>store$1.cursorData?store$1.cursorData.flipMirroredDecal:void 0,set:async newValue=>await store$1.setMirrored(store$1.cursorData.mirrored,newValue)}),offset$2=computed({get:()=>store$1.cursorData?store$1.cursorData.mirrorOffset:void 0,set:async newValue=>await store$1.setMirrorOffset(newValue)}),toggleMirror=()=>mirror.value=!mirror.value,toggleFlipped=()=>{mirror.value&&(flip$2.value=!flip$2.value)},changeOffset=element=>{if(!mirror.value)return;let eventName=element.detail.name,direction$1=eventName===`focus_d`?-1:1,isPressed=element.detail.value;inputNavStates.holdEventLatest===eventName&&!isPressed&&inputNavStates.holdInterval&&(clearInterval(inputNavStates.holdInterval),inputNavStates.holdInterval=null),direction$1>0&&isPressed?doHoldAction(()=>store$1.setMirrorOffset(offset$2.value+1),eventName):direction$1<0&&isPressed&&doHoldAction(()=>store$1.setMirrorOffset(offset$2.value-1),eventName)},changeOffsetScalar=element=>{if(!mirror.value)return;let eventName=element.detail.name,direction$1=element.detail.value;inputNavStates.holdEventLatest===eventName&&inputNavStates.holdInterval&&clearInterval(inputNavStates.holdInterval),direction$1>FOCUS_RU_TRIGGER_VALUE$1&&direction$1>inputNavStates.focusXLatestValue?doHoldAction(()=>store$1.setMirrorOffset(offset$2.value+1),eventName):direction$1store$1.setMirrorOffset(offset$2.value-1),eventName),inputNavStates.focusXLatestValue=direction$1};function onReset(){store$1.setMirrored(!1,!1),store$1.setMirrorOffset(0)}function onTertiaryAction(){if(store$1.reapplyActive||store$1.requestApplyActive)onReset();else return!0}function doHoldAction(callbackFn,eventName){inputNavStates.holdInterval&&=(clearInterval(inputNavStates.holdInterval),null),callbackFn(),inputNavStates.holdInterval=setInterval(callbackFn,FOCUS_HOLD_INTERVAL_MS),inputNavStates.holdEventLatest=eventName}useUINavScope(`mirror-settings`);let useCrossfireValue;onBeforeMount(()=>{useCrossfireValue=getUINavServiceInstance().useCrossfire,getUINavServiceInstance().useCrossfire=!1}),onBeforeUnmount(()=>{getUINavServiceInstance().useCrossfire=useCrossfireValue});let unwatchGamepad;onBeforeMount(()=>{unwatchGamepad=watch(showIfController,async()=>{await nextTick(()=>setHints())},{immediate:!0})}),onUnmounted(()=>{unwatchGamepad&&unwatchGamepad(),removeHints()});function setHints(){let hints;removeHints(),hints=showIfController.value?CONTROLLER_HINTS$4:KEYBOARD_HINTS$4;for(let i=hints.length-1;i>=0;i--)infoBar.addHints(hints[i],0,!0)}function removeHints(){infoBar.removeHints(...KEYBOARD_HINTS$4.map(x=>x.id)),infoBar.removeHints(...CONTROLLER_HINTS$4.map(x=>x.id))}return(_ctx,_cache)=>withDirectives((openBlock(),createElementBlock(`div`,_hoisted_1$98,[createBaseVNode(`div`,_hoisted_2$84,[createVNode(unref(bngSwitch_default),{modelValue:mirror.value,"onUpdate:modelValue":_cache[0]||=$event=>mirror.value=$event},{default:withCtx(()=>[..._cache[3]||=[createTextVNode(`Mirror`,-1)]]),_:1},8,[`modelValue`]),createVNode(unref(bngBinding_default),{uiEvent:MIRROR_BINDING,deviceMask:`xinput`})]),createBaseVNode(`div`,_hoisted_3$73,[createVNode(unref(bngSwitch_default),{modelValue:flip$2.value,"onUpdate:modelValue":_cache[1]||=$event=>flip$2.value=$event,disabled:!mirror.value},{default:withCtx(()=>[..._cache[4]||=[createTextVNode(`Flip`,-1)]]),_:1},8,[`modelValue`,`disabled`]),createVNode(unref(bngBinding_default),{uiEvent:FLIP_BINDING,deviceMask:`xinput`,class:normalizeClass({disabled:!mirror.value})},null,8,[`class`])]),createBaseVNode(`div`,_hoisted_4$56,[createVNode(unref(bngInput_default),{modelValue:offset$2.value,"onUpdate:modelValue":_cache[2]||=$event=>offset$2.value=$event,step:.1,disabled:!mirror.value,type:`number`,prefix:`Offset`,class:`setting-input`},null,8,[`modelValue`,`disabled`]),createVNode(unref(bngBinding_default),{uiEvent:CONTROLLER_OFFSET_BINDING,deviceMask:`xinput`,class:normalizeClass({disabled:!mirror.value})},null,8,[`class`])])])),[[unref(BngOnUiNav_default),onTertiaryAction,`action_3`],[unref(BngOnUiNav_default),toggleMirror,`focus_l`],[unref(BngOnUiNav_default),toggleFlipped,`focus_r`],[unref(BngOnUiNav_default),changeOffset,`focus_u`,{up:!0}],[unref(BngOnUiNav_default),changeOffset,`focus_u`,{down:!0}],[unref(BngOnUiNav_default),changeOffset,`focus_d`,{up:!0}],[unref(BngOnUiNav_default),changeOffset,`focus_d`,{down:!0}],[unref(BngOnUiNav_default),changeOffsetScalar,`focus_ud`]])}},LayerMirrorSettings_default=__plugin_vue_export_helper_default(_sfc_main$107,[[`__scopeId`,`data-v-5ae7bab5`]]),_hoisted_1$97={"bng-ui-scope":`rotate-settings`},_hoisted_2$83={class:`setting-item item-column`},_hoisted_3$72={class:`slider-text-container`},INPUT_CONTROL_STEPS$3=.1,INPUT_CONTROL_MIN$3=0,INPUT_CONTROL_MAX$3=359.9,INPUT_DEFAULT_VALUE$3=0,CONTROLLER_ROTATE_BINDING=`focus_lr`,CONTROLLER_HINTS$3=[],KEYBOARD_HINTS$3=[],_sfc_main$106={__name:`LayerRotateSettings`,setup(__props){let store$1=useLayerSettingsStore(),actionHoldService=useActionHoldService(),{showIfController}=storeToRefs(controls_default()),infoBar=useInfoBar(),rotation=computed({get:()=>store$1.cursorData?parseFloat(store$1.cursorData.rotation.toFixed(1)):void 0,set:async newValue=>{await store$1.setRotation(newValue)}});function onReset(){rotation.value=INPUT_DEFAULT_VALUE$3}function onTertiaryAction(){if(store$1.reapplyActive||store$1.requestApplyActive)onReset();else return!0}useUINavScope(`rotate-settings`);let useCrossfireValue;onBeforeMount(()=>{useCrossfireValue=getUINavServiceInstance().useCrossfire,getUINavServiceInstance().useCrossfire=!1}),onBeforeUnmount(()=>{getUINavServiceInstance().useCrossfire=useCrossfireValue});let unwatchGamepad;onBeforeMount(()=>{unwatchGamepad=watch(showIfController,async()=>{await nextTick(()=>setHints())},{immediate:!0})}),onUnmounted(()=>{actionHoldService.removeAll(`rotate`),unwatchGamepad&&unwatchGamepad(),removeHints()});function setHints(){let hints=showIfController.value?CONTROLLER_HINTS$3:KEYBOARD_HINTS$3;removeHints();for(let i=hints.length-1;i>=0;i--)infoBar.addHints(hints[i],0,!0)}function removeHints(){infoBar.removeHints(...KEYBOARD_HINTS$3.map(x=>x.id)),infoBar.removeHints(...CONTROLLER_HINTS$3.map(x=>x.id))}return(_ctx,_cache)=>withDirectives((openBlock(),createElementBlock(`div`,_hoisted_1$97,[createBaseVNode(`div`,_hoisted_2$83,[createBaseVNode(`div`,_hoisted_3$72,[createVNode(unref(bngInput_default),{modelValue:rotation.value,"onUpdate:modelValue":_cache[0]||=$event=>rotation.value=$event,min:INPUT_CONTROL_MIN$3,max:INPUT_CONTROL_MAX$3,step:INPUT_CONTROL_STEPS$3,type:`number`,prefix:`X`,class:`slider-text-textinput`},null,8,[`modelValue`]),createVNode(unref(bngSlider_default),{modelValue:rotation.value,"onUpdate:modelValue":_cache[1]||=$event=>rotation.value=$event,min:INPUT_CONTROL_MIN$3,max:INPUT_CONTROL_MAX$3,step:INPUT_CONTROL_STEPS$3,class:`slider-text-sliderinput`},null,8,[`modelValue`]),createVNode(unref(bngBinding_default),{uiEvent:CONTROLLER_ROTATE_BINDING,deviceMask:`xinput`})])])])),[[unref(BngOnUiNav_default),onTertiaryAction,`action_3`],[unref(BngOnUiNav_default),element=>unref(actionHoldService).onFocus(`rotate`,unref(store$1).rotate,element,unref(ACTION_PARAMS_TYPE).xPoint),`focus_l`,{up:!0}],[unref(BngOnUiNav_default),element=>unref(actionHoldService).onFocus(`rotate`,unref(store$1).rotate,element,unref(ACTION_PARAMS_TYPE).xPoint),`focus_l`,{down:!0}],[unref(BngOnUiNav_default),element=>unref(actionHoldService).onFocus(`rotate`,unref(store$1).rotate,element,unref(ACTION_PARAMS_TYPE).xPoint),`focus_r`,{down:!0}],[unref(BngOnUiNav_default),element=>unref(actionHoldService).onFocus(`rotate`,unref(store$1).rotate,element,unref(ACTION_PARAMS_TYPE).xPoint),`focus_r`,{up:!0}],[unref(BngOnUiNav_default),element=>unref(actionHoldService).onFocus(`rotate`,unref(store$1).rotate,element,unref(ACTION_PARAMS_TYPE).xPoint),`focus_u`,{up:!0}],[unref(BngOnUiNav_default),element=>unref(actionHoldService).onFocus(`rotate`,unref(store$1).rotate,element,unref(ACTION_PARAMS_TYPE).xPoint),`focus_u`,{down:!0}],[unref(BngOnUiNav_default),element=>unref(actionHoldService).onFocus(`rotate`,unref(store$1).rotate,element,unref(ACTION_PARAMS_TYPE).xPoint),`focus_d`,{down:!0}],[unref(BngOnUiNav_default),element=>unref(actionHoldService).onFocus(`rotate`,unref(store$1).rotate,element,unref(ACTION_PARAMS_TYPE).xPoint),`focus_d`,{up:!0}],[unref(BngOnUiNav_default),element=>unref(actionHoldService).onFocusScalar(`rotate`,unref(store$1).rotate,element,unref(ACTION_PARAMS_TYPE).xPoint),`focus_lr`],[unref(BngOnUiNav_default),element=>unref(actionHoldService).onFocusScalar(`rotate`,unref(store$1).rotate,element,unref(ACTION_PARAMS_TYPE).xPoint),`focus_ud`]])}},LayerRotateSettings_default=__plugin_vue_export_helper_default(_sfc_main$106,[[`__scopeId`,`data-v-d8deaac6`]]),_sfc_main$105={__name:`BindingButton`,props:{uiEvent:String,deviceMask:String,action:String,label:String,showBinding:{type:Boolean,default:!0}},setup(__props){return(_ctx,_cache)=>(openBlock(),createBlock(unref(bngButton_default),{label:void 0},{default:withCtx(()=>[createBaseVNode(`span`,null,toDisplayString(__props.label),1),__props.showBinding?(openBlock(),createBlock(unref(bngBinding_default),{key:0,uiEvent:__props.uiEvent,deviceMask:__props.deviceMask,class:`button-binding`},null,8,[`uiEvent`,`deviceMask`])):createCommentVNode(``,!0)]),_:1}))}},BindingButton_default=__plugin_vue_export_helper_default(_sfc_main$105,[[`__scopeId`,`data-v-e77d3865`]]),_hoisted_1$96={class:`camera-popovermenu`},CONTROLLER_CAMERA_BINDING=`rotate_h_cam`,CAMERA_BUTTONS$2=[{label:`Right`,icon:icons.cameraSideRight,value:`right`},{label:`Front`,icon:icons.cameraFront1,value:`front`},{label:`Left`,icon:icons.cameraSideLeft,value:`left`},{label:`Back`,icon:icons.cameraBack1,value:`back`},{label:`Top Right`,icon:icons.cameraTop1,value:`topright`},{label:`Top Left`,icon:icons.cameraTop1,value:`topleft`},{label:`Top Front`,icon:icons.cameraTop1,value:`topfront`},{label:`Top Back`,icon:icons.cameraTop1,value:`topback`}],_sfc_main$104={__name:`CameraViewButton`,setup(__props){let store$1=useLiveryEditorStore(),popover=usePopover(),expand=ref(!1),currentCamera=computed(()=>{if(store$1.cameraView){let curr=CAMERA_BUTTONS$2.find(x=>x.value===store$1.cameraView);if(curr)return curr}return{icon:icons.movieCamera,label:`View`}}),onCameraViewClicked=view=>{popover.hide(`camera-popovermenu`),store$1.setOrthographicView(view)};return(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,null,[withDirectives((openBlock(),createBlock(unref(bngButton_default),{icon:currentCamera.value.icon,accent:unref(ACCENTS).secondary},{default:withCtx(()=>[createBaseVNode(`span`,null,toDisplayString(currentCamera.value.label),1),createVNode(unref(bngBinding_default),{uiEvent:CONTROLLER_CAMERA_BINDING,deviceMask:`xinput`})]),_:1},8,[`icon`,`accent`])),[[unref(BngPopover_default),`camera-popovermenu`,`bottom`,{click:!0}]]),createVNode(unref(bngPopoverContent_default),{name:`camera-popovermenu`,onShow:_cache[0]||=$event=>expand.value=!0,onHide:_cache[1]||=$event=>expand.value=!1},{default:withCtx(()=>[createBaseVNode(`div`,_hoisted_1$96,[(openBlock(),createElementBlock(Fragment,null,renderList(CAMERA_BUTTONS$2,cameraItem=>createVNode(unref(bngImageTile_default),{key:cameraItem.value,label:cameraItem.label,icon:cameraItem.icon,class:normalizeClass({active:cameraItem.value===currentCamera.value.value}),onClick:$event=>onCameraViewClicked(cameraItem.value)},null,8,[`label`,`icon`,`class`,`onClick`])),64))])]),_:1})]))}},CameraViewButton_default=__plugin_vue_export_helper_default(_sfc_main$104,[[`__scopeId`,`data-v-be949a44`]]),_hoisted_1$95={key:0,class:`liveryeditor-header`},_hoisted_2$82={key:0,class:`header-items`},_sfc_main$103={__name:`LiveryEditorHeader`,setup(__props){let store$1=useEditorHeaderStore(),{startSectionItems,centerSectionItems,endSectionItems}=storeToRefs(store$1),sections=ref({start:startSectionItems,center:centerSectionItems,end:endSectionItems});return(_ctx,_cache)=>unref(store$1).headerHidden?createCommentVNode(``,!0):(openBlock(),createElementBlock(`div`,_hoisted_1$95,[createVNode(unref(bngScreenHeading_default),{type:unref(store$1).header.type,preheadings:unref(store$1).header.preheading},{default:withCtx(()=>[createTextVNode(toDisplayString(unref(store$1).header.heading),1)]),_:1},8,[`type`,`preheadings`]),unref(store$1).itemsHidden?createCommentVNode(``,!0):(openBlock(),createElementBlock(`div`,_hoisted_2$82,[(openBlock(!0),createElementBlock(Fragment,null,renderList(sections.value,(items$2,section)=>(openBlock(),createElementBlock(`div`,{class:normalizeClass([[`section-${section}`],`header-section`])},[(openBlock(!0),createElementBlock(Fragment,null,renderList(items$2,item=>(openBlock(),createElementBlock(`div`,{key:item.id},[withDirectives((openBlock(),createBlock(resolveDynamicComponent(item.component),mergeProps({ref_for:!0},item.props,toHandlers(item.events)),null,16)),[[vShow,!item.hidden]])]))),128))],2))),256))]))]))}},LiveryEditorHeader_default=__plugin_vue_export_helper_default(_sfc_main$103,[[`__scopeId`,`data-v-b0fff070`]]),_hoisted_1$94={class:`transform-settings`,"bng-ui-scope":`transform-settings`},_hoisted_2$81={class:`setting-item item-column`},_hoisted_3$71={class:`slider-text-container`},_hoisted_4$55={class:`setting-item item-column`},_hoisted_5$46={class:`slider-text-container`},_hoisted_6$33={key:0,class:`setting-item`},_hoisted_7$28={class:`setting-item actions-container`},INPUT_CONTROL_STEPS$2=.001,INPUT_CONTROL_MIN$2=0,INPUT_CONTROL_MAX$2=1,INPUT_DEFAULT_VALUE$2=.5,APPLIED_CONTROLLER_HINTS=[],CONTROLLER_MOVE_Y_BINDING=`focus_ud`,CONTROLLER_MOVE_X_BINDING=`focus_lr`,CONTROLLER_SURFACE_NORMAL_BINDING=`action_2`,CONTROLLER_APPLY_BINDING=`ok`,CONTROLLER_CANCEL_REAPPLY_BINDING=`back`,CONTROLLER_HINTS$2=[],KEYBOARD_HINTS$2=[],MOUSE_HINTS=[{id:`stamp_decal`,content:{type:`binding`,props:{action:`stamp_decal`},label:`Apply`}}],_sfc_main$102={__name:`LayerTransformSettingsOld`,setup(__props){let store$1=useLayerSettingsStore(),{showIfController}=storeToRefs(controls_default()),infoBar=useInfoBar(),actionHoldService=useActionHoldService(),positionX=computed({get:()=>store$1.cursorData&&store$1.cursorData.position?store$1.cursorData.position.x:void 0,set:async newValue=>await store$1.setPosition(newValue,store$1.cursorData.position.y)}),positionY=computed({get:()=>store$1.cursorData&&store$1.cursorData.position?store$1.cursorData.position.y:void 0,set:async newValue=>await store$1.setPosition(store$1.cursorData.position.x,newValue)}),positionMaxX=computed(()=>store$1.cursorData&&store$1.cursorData.position?store$1.cursorData.position.maxX:INPUT_CONTROL_MAX$2),positionMaxY=computed(()=>store$1.cursorData&&store$1.cursorData.position?store$1.cursorData.position.maxY:INPUT_CONTROL_MAX$2),surfaceNormal=computed({get:()=>store$1.cursorData?store$1.cursorData.isProjectSurfaceNormal:void 0,set:async newValue=>await store$1.setProjectSurfaceNormal(newValue)}),mouseMode=computed(()=>store$1.cursorData?store$1.cursorData.isUseMousePos:void 0),applied=computed(()=>store$1.cursorData?store$1.cursorData.applied:void 0);computed(()=>store$1.active);let isShowControls=computed(()=>!store$1.cursorData.applied&&!mouseMode.value),toggleUseSurfaceNormal=()=>{if(console.log(`toggleUseSurfaceNormal`),!store$1.cursorData.applied)surfaceNormal.value=!surfaceNormal.value;else return console.log(`toggleUseSurfaceNormal returning true`),!0};function cancelApply(){store$1.requestApplyActive?store$1.cancelRequestApply():store$1.reapplyActive&&store$1.cancelReapply()}function onReset(){store$1.setPosition(INPUT_DEFAULT_VALUE$2,INPUT_DEFAULT_VALUE$2)}function onOk(){if(!store$1.requestApplyActive&&!store$1.reapplyActive)store$1.toggleReapply();else return!0}function onTertiaryAction(){if(store$1.reapplyActive||store$1.requestApplyActive)onReset();else return!0}useUINavScope(`transform-settings`);let useCrossfireValue;onBeforeMount(()=>{useCrossfireValue=getUINavServiceInstance().useCrossfire,getUINavServiceInstance().useCrossfire=!1}),onBeforeUnmount(()=>{getUINavServiceInstance().useCrossfire=useCrossfireValue}),watch(mouseMode,async()=>{await nextTick(()=>setHints())}),watch(applied,async()=>{await nextTick(()=>setHints())});function setHints(){let hints;removeHints(),hints=applied.value?showIfController.value?APPLIED_CONTROLLER_HINTS:KEYBOARD_HINTS$2:mouseMode.value?MOUSE_HINTS:showIfController.value?CONTROLLER_HINTS$2:KEYBOARD_HINTS$2;for(let i=hints.length-1;i>=0;i--)infoBar.addHints(hints[i],0,!0)}let unwatchGamepad;onBeforeMount(()=>{unwatchGamepad=watch(showIfController,async()=>{await nextTick(()=>{setHints()})},{immediate:!0})}),onUnmounted(()=>{actionHoldService.removeAll(`transform`),unwatchGamepad&&unwatchGamepad(),removeHints()});function removeHints(){infoBar.removeHints(...KEYBOARD_HINTS$2.map(x=>x.id)),infoBar.removeHints(...CONTROLLER_HINTS$2.map(x=>x.id)),infoBar.removeHints(...APPLIED_CONTROLLER_HINTS.map(x=>x.id)),infoBar.removeHints(...MOUSE_HINTS.map(x=>x.id))}return(_ctx,_cache)=>withDirectives((openBlock(),createElementBlock(`div`,_hoisted_1$94,[createBaseVNode(`div`,_hoisted_2$81,[withDirectives(createBaseVNode(`div`,_hoisted_3$71,[createVNode(unref(bngInput_default),{modelValue:positionX.value,"onUpdate:modelValue":_cache[0]||=$event=>positionX.value=$event,min:INPUT_CONTROL_MIN$2,max:positionMaxX.value,step:INPUT_CONTROL_STEPS$2,type:`number`,prefix:`X`,class:`slider-text-textinput`},null,8,[`modelValue`,`max`]),createVNode(unref(bngSlider_default),{modelValue:positionX.value,"onUpdate:modelValue":_cache[1]||=$event=>positionX.value=$event,min:INPUT_CONTROL_MIN$2,max:positionMaxX.value,step:INPUT_CONTROL_STEPS$2,class:`slider-text-sliderinput`},null,8,[`modelValue`,`max`]),createVNode(unref(bngBinding_default),{uiEvent:CONTROLLER_MOVE_X_BINDING,deviceMask:`xinput`})],512),[[vShow,isShowControls.value]])]),withDirectives(createBaseVNode(`div`,_hoisted_4$55,[createBaseVNode(`div`,_hoisted_5$46,[createVNode(unref(bngInput_default),{modelValue:positionY.value,"onUpdate:modelValue":_cache[2]||=$event=>positionY.value=$event,type:`number`,prefix:`Y`,min:INPUT_CONTROL_MIN$2,max:positionMaxY.value,step:INPUT_CONTROL_STEPS$2,class:`slider-text-textinput`},null,8,[`modelValue`,`max`]),createVNode(unref(bngSlider_default),{modelValue:positionY.value,"onUpdate:modelValue":_cache[3]||=$event=>positionY.value=$event,min:INPUT_CONTROL_MIN$2,max:positionMaxY.value,step:INPUT_CONTROL_STEPS$2,class:`slider-text-sliderinput`},null,8,[`modelValue`,`max`]),createVNode(unref(bngBinding_default),{uiEvent:CONTROLLER_MOVE_Y_BINDING,deviceMask:`xinput`})])],512),[[vShow,isShowControls.value]]),unref(store$1).cursorData.applied?createCommentVNode(``,!0):(openBlock(),createElementBlock(`div`,_hoisted_6$33,[createVNode(unref(bngSwitch_default),{modelValue:surfaceNormal.value,"onUpdate:modelValue":_cache[4]||=$event=>surfaceNormal.value=$event,disabled:!(unref(store$1).reapplyActive||!applied.value)},{default:withCtx(()=>[..._cache[5]||=[createTextVNode(`Use Surface Normal`,-1)]]),_:1},8,[`modelValue`,`disabled`]),createVNode(unref(bngBinding_default),{uiEvent:CONTROLLER_SURFACE_NORMAL_BINDING,deviceMask:`xinput`})])),createBaseVNode(`div`,_hoisted_7$28,[unref(store$1).requestApplyActive||unref(store$1).reapplyActive?(openBlock(),createElementBlock(Fragment,{key:0},[unref(store$1).appliedLayers&&unref(store$1).appliedLayers.length>0?(openBlock(),createBlock(unref(BindingButton_default),{key:0,icon:unref(store$1).reapplyActive?unref(icons).undo:``,uiEvent:CONTROLLER_CANCEL_REAPPLY_BINDING,label:unref(store$1).reapplyActive?`Undo`:`Cancel`,accent:`attention`,onClick:cancelApply},null,8,[`icon`,`label`])):createCommentVNode(``,!0),mouseMode.value?createCommentVNode(``,!0):(openBlock(),createBlock(unref(BindingButton_default),{key:1,uiEvent:CONTROLLER_APPLY_BINDING,label:`Apply`,accent:`primary`,onClick:unref(store$1).apply},null,8,[`onClick`]))],64)):(openBlock(),createBlock(unref(BindingButton_default),{key:1,uiEvent:CONTROLLER_APPLY_BINDING,label:`Reapply`,onClick:unref(store$1).requestReapply},null,8,[`onClick`]))])])),[[unref(BngOnUiNav_default),onOk,`ok`],[unref(BngOnUiNav_default),toggleUseSurfaceNormal,`action_2`],[unref(BngOnUiNav_default),onTertiaryAction,`action_3`],[unref(BngOnUiNav_default),element=>unref(actionHoldService).onFocus(`transform`,unref(store$1).translate,element),`focus_l`,{up:!0}],[unref(BngOnUiNav_default),element=>unref(actionHoldService).onFocus(`transform`,unref(store$1).translate,element),`focus_l`,{down:!0}],[unref(BngOnUiNav_default),element=>unref(actionHoldService).onFocus(`transform`,unref(store$1).translate,element),`focus_r`,{down:!0}],[unref(BngOnUiNav_default),element=>unref(actionHoldService).onFocus(`transform`,unref(store$1).translate,element),`focus_r`,{up:!0}],[unref(BngOnUiNav_default),element=>unref(actionHoldService).onFocus(`transform`,unref(store$1).translate,element),`focus_u`,{up:!0}],[unref(BngOnUiNav_default),element=>unref(actionHoldService).onFocus(`transform`,unref(store$1).translate,element),`focus_u`,{down:!0}],[unref(BngOnUiNav_default),element=>unref(actionHoldService).onFocus(`transform`,unref(store$1).translate,element),`focus_d`,{down:!0}],[unref(BngOnUiNav_default),element=>unref(actionHoldService).onFocus(`transform`,unref(store$1).translate,element),`focus_d`,{up:!0}],[unref(BngOnUiNav_default),element=>unref(actionHoldService).onFocusScalar(`transform`,unref(store$1).translate,element),`focus_lr`],[unref(BngOnUiNav_default),element=>unref(actionHoldService).onFocusScalar(`transform`,unref(store$1).translate,element),`focus_ud`]])}},LayerTransformSettingsOld_default=__plugin_vue_export_helper_default(_sfc_main$102,[[`__scopeId`,`data-v-79d0fe46`]]),_hoisted_1$93={class:`scale-settings`,"bng-ui-scope":`scale-settings`},_hoisted_2$80={class:`setting-item item-column`},_hoisted_3$70={class:`slider-text-container`},_hoisted_4$54={class:`setting-item item-column`},_hoisted_5$45={class:`slider-text-container`},_hoisted_6$32={class:`setting-item`},INPUT_CONTROL_STEPS$1=.01,INPUT_CONTROL_MIN$1=0,INPUT_CONTROL_MAX$1=6,INPUT_DEFAULT_VALUE$1=.5,CONTROLLER_SCALE_Y_BINDING=`focus_ud`,CONTROLLER_SCALE_X_BINDING=`focus_lr`,CONTROLLER_LOCK_BINDING=`action_2`,CONTROLLER_HINTS$1=[],KEYBOARD_HINTS$1=[],_sfc_main$101={__name:`LayerScaleSettings`,setup(__props){let store$1=useLayerSettingsStore(),actionHoldService=useActionHoldService(),{showIfController}=storeToRefs(controls_default()),infoBar=useInfoBar(),{editModeState}=storeToRefs(store$1),scaleX=computed({get:()=>store$1.cursorData&&store$1.cursorData.scale?store$1.cursorData.scale.x:void 0,set:async newValue=>{if(newValue===store$1.cursorData.scale.x)return;let scaleY$1=store$1.cursorData.scale.y;if(editModeState.value.lockScaling){let diff=newValue-store$1.cursorData.scale.x;scaleY$1+=diff}await store$1.setScale(newValue,scaleY$1)}}),scaleY=computed({get:()=>store$1.cursorData&&store$1.cursorData.scale?store$1.cursorData.scale.y:void 0,set:async newValue=>{if(newValue===store$1.cursorData.scale.y)return;let scaleX$1=store$1.cursorData.scale.x;if(editModeState.value.lockScaling){let diff=newValue-store$1.cursorData.scale.y;scaleX$1+=diff}await store$1.setScale(scaleX$1,newValue)}}),toggleLockScaling=()=>{editModeState.value.lockScaling=!editModeState.value.lockScaling};function onReset(){store$1.setScale(INPUT_DEFAULT_VALUE$1,INPUT_DEFAULT_VALUE$1)}function onTertiaryAction(){if(store$1.reapplyActive||store$1.requestApplyActive)onReset();else return!0}function onFocus(element,scalar=!1){let actionFn=(xDirection,yDirection)=>{xDirection!==0&&(scaleX.value=xDirection*INPUT_CONTROL_STEPS$1+scaleX.value),yDirection!==0&&(scaleY.value=yDirection*INPUT_CONTROL_STEPS$1+scaleY.value)};scalar?actionHoldService.onFocusScalar(`scale`,actionFn,element):actionHoldService.onFocus(`scale`,actionFn,element)}useUINavScope(`scale-settings`);let useCrossfireValue;onBeforeMount(()=>{useCrossfireValue=getUINavServiceInstance().useCrossfire,getUINavServiceInstance().useCrossfire=!1}),onBeforeUnmount(()=>{getUINavServiceInstance().useCrossfire=useCrossfireValue});let unwatchGamepad;onBeforeMount(()=>{unwatchGamepad=watch(showIfController,async()=>{await nextTick(()=>setHints())},{immediate:!0})}),onUnmounted(()=>{actionHoldService.removeAll(`scale`),unwatchGamepad&&unwatchGamepad(),removeHints()});function setHints(){let hints=showIfController.value?CONTROLLER_HINTS$1:KEYBOARD_HINTS$1;removeHints();for(let i=hints.length-1;i>=0;i--)infoBar.addHints(hints[i],0,!0)}function removeHints(){infoBar.removeHints(...KEYBOARD_HINTS$1.map(x=>x.id)),infoBar.removeHints(...CONTROLLER_HINTS$1.map(x=>x.id))}return(_ctx,_cache)=>withDirectives((openBlock(),createElementBlock(`div`,_hoisted_1$93,[createBaseVNode(`div`,_hoisted_2$80,[createBaseVNode(`div`,_hoisted_3$70,[createVNode(unref(bngInput_default),{modelValue:scaleX.value,"onUpdate:modelValue":_cache[0]||=$event=>scaleX.value=$event,min:INPUT_CONTROL_MIN$1,max:INPUT_CONTROL_MAX$1,step:INPUT_CONTROL_STEPS$1,type:`number`,prefix:`X`,class:`slider-text-textinput`},null,8,[`modelValue`]),createVNode(unref(bngSlider_default),{modelValue:scaleX.value,"onUpdate:modelValue":_cache[1]||=$event=>scaleX.value=$event,min:INPUT_CONTROL_MIN$1,max:INPUT_CONTROL_MAX$1,step:INPUT_CONTROL_STEPS$1,class:`slider-text-sliderinput`},null,8,[`modelValue`]),createVNode(unref(bngBinding_default),{uiEvent:CONTROLLER_SCALE_X_BINDING,deviceMask:`xinput`})])]),createBaseVNode(`div`,_hoisted_4$54,[createBaseVNode(`div`,_hoisted_5$45,[createVNode(unref(bngInput_default),{modelValue:scaleY.value,"onUpdate:modelValue":_cache[2]||=$event=>scaleY.value=$event,type:`number`,prefix:`Y`,min:INPUT_CONTROL_MIN$1,max:INPUT_CONTROL_MAX$1,step:INPUT_CONTROL_STEPS$1,class:`slider-text-textinput`},null,8,[`modelValue`]),createVNode(unref(bngSlider_default),{modelValue:scaleY.value,"onUpdate:modelValue":_cache[3]||=$event=>scaleY.value=$event,min:INPUT_CONTROL_MIN$1,max:INPUT_CONTROL_MAX$1,step:INPUT_CONTROL_STEPS$1,class:`slider-text-sliderinput`},null,8,[`modelValue`]),createVNode(unref(bngBinding_default),{uiEvent:CONTROLLER_SCALE_Y_BINDING,deviceMask:`xinput`})])]),createBaseVNode(`div`,_hoisted_6$32,[createVNode(unref(bngSwitch_default),{modelValue:unref(editModeState).lockScaling,"onUpdate:modelValue":_cache[4]||=$event=>unref(editModeState).lockScaling=$event},{default:withCtx(()=>[..._cache[5]||=[createTextVNode(`Lock Scaling`,-1)]]),_:1},8,[`modelValue`]),createVNode(unref(bngBinding_default),{uiEvent:CONTROLLER_LOCK_BINDING,deviceMask:`xinput`})])])),[[unref(BngOnUiNav_default),toggleLockScaling,`action_2`],[unref(BngOnUiNav_default),onTertiaryAction,`action_3`],[unref(BngOnUiNav_default),onFocus,`focus_l`,{up:!0}],[unref(BngOnUiNav_default),onFocus,`focus_l`,{down:!0}],[unref(BngOnUiNav_default),onFocus,`focus_r`,{down:!0}],[unref(BngOnUiNav_default),onFocus,`focus_r`,{up:!0}],[unref(BngOnUiNav_default),onFocus,`focus_u`,{up:!0}],[unref(BngOnUiNav_default),onFocus,`focus_u`,{down:!0}],[unref(BngOnUiNav_default),onFocus,`focus_d`,{down:!0}],[unref(BngOnUiNav_default),onFocus,`focus_d`,{up:!0}],[unref(BngOnUiNav_default),el=>onFocus(el,!0),`focus_lr`],[unref(BngOnUiNav_default),el=>onFocus(el,!0),`focus_ud`]])}},LayerScaleSettings_default=__plugin_vue_export_helper_default(_sfc_main$101,[[`__scopeId`,`data-v-56a383d1`]]),_hoisted_1$92={class:`sort-settings`,"bng-ui-scope":`sort-settings`},_hoisted_2$79={class:`setting-item`},_hoisted_3$69={class:`icon-binding-wrapper`},_hoisted_4$53={class:`icon-binding-wrapper`},_hoisted_5$44={class:`icon-binding-wrapper`},_hoisted_6$31={class:`stacked-arrows`},_hoisted_7$27={class:`icon-binding-wrapper`},_hoisted_8$21={class:`stacked-arrows`},_hoisted_9$18={key:0},ORDER_TOOL=Lua_default.extensions.ui_liveryEditor_tools_group,_sfc_main$100={__name:`LayerSortSettings`,setup(__props){let store$1=useLiveryEditorStore();useUINavScope(`sort-settings`);let order=computed({get:()=>store$1.selectedLayers[0].order,set(newValue){ORDER_TOOL.setOrder(newValue)}}),orderMax=computed(()=>store$1.selectedLayers[0].siblingCount),multiSelected=computed(()=>store$1.selectedLayerUids.length>1),orderOptions=computed(()=>Array.from({length:store$1.layers.length-1},(_,i)=>({label:`${i+1}`,value:i+2})));return onMounted(()=>{getUINavServiceInstance().useCrossfire=!1}),(_ctx,_cache)=>withDirectives((openBlock(),createElementBlock(`div`,_hoisted_1$92,[createBaseVNode(`div`,_hoisted_2$79,[createVNode(unref(bngButton_default),{onClick:_cache[0]||=()=>unref(ORDER_TOOL).moveOrderUp(),disabled:order.value===orderMax.value},{default:withCtx(()=>[createBaseVNode(`div`,_hoisted_3$69,[createVNode(unref(bngIcon_default),{type:unref(icons).arrowLargeUp},null,8,[`type`]),createVNode(unref(bngBinding_default),{action:`menu_item_up`})])]),_:1},8,[`disabled`]),createVNode(unref(bngButton_default),{onClick:_cache[1]||=()=>unref(ORDER_TOOL).moveOrderDown(),disabled:order.value===2},{default:withCtx(()=>[createBaseVNode(`div`,_hoisted_4$53,[createVNode(unref(bngIcon_default),{type:unref(icons).arrowLargeDown},null,8,[`type`]),createVNode(unref(bngBinding_default),{action:`menu_item_down`})])]),_:1},8,[`disabled`]),multiSelected.value?createCommentVNode(``,!0):(openBlock(),createBlock(unref(bngButton_default),{key:0,onClick:_cache[2]||=()=>unref(ORDER_TOOL).changeOrderToTop(),disabled:order.value===orderMax.value},{default:withCtx(()=>[createBaseVNode(`div`,_hoisted_5$44,[createBaseVNode(`div`,_hoisted_6$31,[createVNode(unref(bngIcon_default),{type:unref(icons).arrowLargeUp},null,8,[`type`]),createVNode(unref(bngIcon_default),{type:unref(icons).arrowLargeUp},null,8,[`type`])]),createVNode(unref(bngBinding_default),{action:`menu_item_right`})])]),_:1},8,[`disabled`])),multiSelected.value?createCommentVNode(``,!0):(openBlock(),createBlock(unref(bngButton_default),{key:1,onClick:_cache[3]||=()=>unref(ORDER_TOOL).changeOrderToBottom(),disabled:order.value===2},{default:withCtx(()=>[createBaseVNode(`div`,_hoisted_7$27,[createBaseVNode(`div`,_hoisted_8$21,[createVNode(unref(bngIcon_default),{type:unref(icons).arrowLargeDown,disabled:unref(store$1).selectedLayers.length>1},null,8,[`type`,`disabled`]),createVNode(unref(bngIcon_default),{type:unref(icons).arrowLargeDown,disabled:unref(store$1).selectedLayers.length>1},null,8,[`type`,`disabled`])]),createVNode(unref(bngBinding_default),{action:`menu_item_left`})])]),_:1},8,[`disabled`]))]),multiSelected.value?createCommentVNode(``,!0):(openBlock(),createElementBlock(`div`,_hoisted_9$18,[createVNode(unref(bngDropdown_default),{modelValue:order.value,"onUpdate:modelValue":_cache[4]||=$event=>order.value=$event,items:orderOptions.value},null,8,[`modelValue`,`items`])]))])),[[unref(BngOnUiNav_default),()=>unref(ORDER_TOOL).changeOrderToBottom(),`focus_l`],[unref(BngOnUiNav_default),()=>unref(ORDER_TOOL).changeOrderToTop(),`focus_r`],[unref(BngOnUiNav_default),()=>unref(ORDER_TOOL).moveOrderUp(),`focus_u`],[unref(BngOnUiNav_default),()=>unref(ORDER_TOOL).moveOrderDown(),`focus_d`]])}},LayerSortSettings_default=__plugin_vue_export_helper_default(_sfc_main$100,[[`__scopeId`,`data-v-1d4969be`]]),_hoisted_1$91={class:`skew-settings`,"bng-ui-scope":`skew-settings`},_hoisted_2$78={class:`setting-item item-column`},_hoisted_3$68={class:`slider-text-container`},_hoisted_4$52={class:`setting-item item-column`},_hoisted_5$43={class:`slider-text-container`},INPUT_CONTROL_STEPS=.01,INPUT_CONTROL_MIN=-2,INPUT_CONTROL_MAX=2,INPUT_DEFAULT_VALUE=0,CONTROLLER_SKEW_Y_BINDING=`focus_ud`,CONTROLLER_SKEW_X_BINDING=`focus_lr`,CONTROLLER_HINTS=[],KEYBOARD_HINTS=[],_sfc_main$99={__name:`LayerDeformSettings`,setup(__props){let store$1=useLayerSettingsStore(),actionHoldService=useActionHoldService(),{showIfController}=storeToRefs(controls_default()),infoBar=useInfoBar(),skewX=computed({get:()=>store$1.cursorData&&store$1.cursorData.skew?store$1.cursorData.skew.x:void 0,set:async newValue=>await store$1.setSkew(newValue,store$1.cursorData.skew.y)}),skewY=computed({get:()=>store$1.cursorData&&store$1.cursorData.skew?store$1.cursorData.skew.y:void 0,set:async newValue=>await store$1.setSkew(store$1.cursorData.skew.x,newValue)});function onReset(){store$1.setSkew(INPUT_DEFAULT_VALUE,INPUT_DEFAULT_VALUE)}function onTertiaryAction(){if(store$1.reapplyActive||store$1.requestApplyActive)onReset();else return!0}useUINavScope(`skew-settings`);let useCrossfireValue;onBeforeMount(()=>{useCrossfireValue=getUINavServiceInstance().useCrossfire,getUINavServiceInstance().useCrossfire=!1}),onBeforeUnmount(()=>{getUINavServiceInstance().useCrossfire=useCrossfireValue});let unwatchGamepad;onBeforeMount(()=>{unwatchGamepad=watch(showIfController,async()=>{await nextTick(()=>setHints())},{immediate:!0})}),onUnmounted(()=>{actionHoldService.removeAll(`skew`),unwatchGamepad&&unwatchGamepad(),removeHints()});function setHints(){let hints=showIfController.value?CONTROLLER_HINTS:KEYBOARD_HINTS;removeHints();for(let i=hints.length-1;i>=0;i--)infoBar.addHints(hints[i],0,!0)}function removeHints(){infoBar.removeHints(...KEYBOARD_HINTS.map(x=>x.id)),infoBar.removeHints(...CONTROLLER_HINTS.map(x=>x.id))}return(_ctx,_cache)=>withDirectives((openBlock(),createElementBlock(`div`,_hoisted_1$91,[createBaseVNode(`div`,_hoisted_2$78,[createBaseVNode(`div`,_hoisted_3$68,[createVNode(unref(bngInput_default),{modelValue:skewX.value,"onUpdate:modelValue":_cache[0]||=$event=>skewX.value=$event,min:INPUT_CONTROL_MIN,max:INPUT_CONTROL_MAX,step:INPUT_CONTROL_STEPS,type:`number`,prefix:`X`,class:`slider-text-textinput`},null,8,[`modelValue`]),createVNode(unref(bngSlider_default),{modelValue:skewX.value,"onUpdate:modelValue":_cache[1]||=$event=>skewX.value=$event,min:INPUT_CONTROL_MIN,max:INPUT_CONTROL_MAX,step:INPUT_CONTROL_STEPS,class:`slider-text-sliderinput`},null,8,[`modelValue`]),createVNode(unref(bngBinding_default),{uiEvent:CONTROLLER_SKEW_X_BINDING,deviceMask:`xinput`})])]),createBaseVNode(`div`,_hoisted_4$52,[createBaseVNode(`div`,_hoisted_5$43,[createVNode(unref(bngInput_default),{modelValue:skewY.value,"onUpdate:modelValue":_cache[2]||=$event=>skewY.value=$event,type:`number`,prefix:`Y`,min:INPUT_CONTROL_MIN,max:INPUT_CONTROL_MAX,step:INPUT_CONTROL_STEPS,class:`slider-text-textinput`},null,8,[`modelValue`]),createVNode(unref(bngSlider_default),{modelValue:skewY.value,"onUpdate:modelValue":_cache[3]||=$event=>skewY.value=$event,min:INPUT_CONTROL_MIN,max:INPUT_CONTROL_MAX,step:INPUT_CONTROL_STEPS,class:`slider-text-sliderinput`},null,8,[`modelValue`]),createVNode(unref(bngBinding_default),{uiEvent:CONTROLLER_SKEW_Y_BINDING,deviceMask:`xinput`})])])])),[[unref(BngOnUiNav_default),onTertiaryAction,`action_3`],[unref(BngOnUiNav_default),element=>unref(actionHoldService).onFocus(`skew`,unref(store$1).skew,element),`focus_l`,{up:!0}],[unref(BngOnUiNav_default),element=>unref(actionHoldService).onFocus(`skew`,unref(store$1).skew,element),`focus_l`,{down:!0}],[unref(BngOnUiNav_default),element=>unref(actionHoldService).onFocus(`skew`,unref(store$1).skew,element),`focus_r`,{down:!0}],[unref(BngOnUiNav_default),element=>unref(actionHoldService).onFocus(`skew`,unref(store$1).skew,element),`focus_r`,{up:!0}],[unref(BngOnUiNav_default),element=>unref(actionHoldService).onFocus(`skew`,unref(store$1).skew,element),`focus_u`,{up:!0}],[unref(BngOnUiNav_default),element=>unref(actionHoldService).onFocus(`skew`,unref(store$1).skew,element),`focus_u`,{down:!0}],[unref(BngOnUiNav_default),element=>unref(actionHoldService).onFocus(`skew`,unref(store$1).skew,element),`focus_d`,{down:!0}],[unref(BngOnUiNav_default),element=>unref(actionHoldService).onFocus(`skew`,unref(store$1).skew,element),`focus_d`,{up:!0}],[unref(BngOnUiNav_default),element=>unref(actionHoldService).onFocusScalar(`skew`,unref(store$1).skew,element),`focus_lr`],[unref(BngOnUiNav_default),element=>unref(actionHoldService).onFocusScalar(`skew`,unref(store$1).skew,element),`focus_ud`]])}},LayerDeformSettings_default=__plugin_vue_export_helper_default(_sfc_main$99,[[`__scopeId`,`data-v-b2c32ce6`]]),_hoisted_1$90={class:`layer-settings-base`},_hoisted_2$77={class:`settings-heading`},_hoisted_3$67={class:`settings-content`},_sfc_main$98={__name:`LayerSettingsBase`,props:{heading:{type:String}},emits:[`close`],setup(__props){let slots=useSlots();return(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$90,[createBaseVNode(`div`,_hoisted_2$77,[createVNode(unref(bngCardHeading_default),{type:`ribbon`},{default:withCtx(()=>[unref(slots).heading?renderSlot(_ctx.$slots,`heading`,{key:0},()=>[createBaseVNode(`span`,null,toDisplayString(__props.heading),1)],!0):createCommentVNode(``,!0)]),_:3})]),createBaseVNode(`div`,_hoisted_3$67,[renderSlot(_ctx.$slots,`default`,{},void 0,!0)])]))}},LayerSettingsBase_default=__plugin_vue_export_helper_default(_sfc_main$98,[[`__scopeId`,`data-v-c5fed92f`]]),_hoisted_1$89={class:`setting-item item-column`},_hoisted_2$76={class:`slider-text-container`},_hoisted_3$66={class:`setting-item item-column`},_hoisted_4$51={class:`slider-text-container`},_sfc_main$97={__name:`TransformSettings`,setup(__props){let scaleX=ref(.5),scaleY=ref(.5);return(_ctx,_cache)=>(openBlock(),createBlock(unref(LayerSettingsBase_default),null,{heading:withCtx(()=>[..._cache[2]||=[createTextVNode(`Transform`,-1)]]),default:withCtx(()=>[createBaseVNode(`template`,null,[createBaseVNode(`div`,_hoisted_1$89,[createBaseVNode(`div`,_hoisted_2$76,[createVNode(unref(bngInput_default),{modelValue:scaleX.value,"onUpdate:modelValue":_cache[0]||=$event=>scaleX.value=$event,min:0,max:6,step:.01,type:`number`,prefix:`X`},null,8,[`modelValue`])])]),createBaseVNode(`div`,_hoisted_3$66,[createBaseVNode(`div`,_hoisted_4$51,[createVNode(unref(bngInput_default),{modelValue:scaleY.value,"onUpdate:modelValue":_cache[1]||=$event=>scaleY.value=$event,type:`number`,prefix:`Y`,min:0,max:6,step:.01},null,8,[`modelValue`])])])])]),_:1}))}},TransformSettings_default=_sfc_main$97,_hoisted_1$88={class:`settings-container`},_hoisted_2$75={class:`setting-types-selector`},_hoisted_3$65={class:`setting-types`},_hoisted_4$50=[`onClick`],_hoisted_5$42={class:`heading-content-wrapper`},_hoisted_6$30={class:`heading-content-text`},_hoisted_7$26={key:0},_hoisted_8$20={key:0,class:`subheading`},CONTROLLER_RESET_BINDING=`advanced`,SETTING_TYPES=[{value:`transform`,label:`Transform`,icon:icons.transform,component:markRaw(TransformSettings_default)},{value:`transformold`,label:`Position`,icon:icons.transform,component:markRaw(LayerTransformSettingsOld_default)},{value:`scale`,label:`Scale`,icon:icons.scale,component:markRaw(LayerScaleSettings_default)},{value:`skew`,label:`Skew`,icon:icons.deform,component:markRaw(LayerDeformSettings_default)},{value:`rotate`,label:`Rotate`,icon:icons.rotationL,component:markRaw(LayerRotateSettings_default)},{value:`material`,label:`Material`,icon:icons.material,component:markRaw(LayerMaterialSettings_default)},{value:`mirror`,label:`Mirror`,icon:icons.reflect,component:markRaw(LayerMirrorSettings_default)}],_sfc_main$96={__name:`LayerSettings`,props:{settingTypes:Array,activeSetting:String,excludeSettingTypes:Array},setup(__props){let store$1=useLayerSettingsStore(),props=__props,currentIndex=ref(0),settingTypes=computed(()=>{let filtered=SETTING_TYPES;return props.settingTypes&&(filtered=filtered.filter(x=>props.settingTypes.includes(x.value))),props.excludeSettingTypes&&(filtered=filtered.filter(x=>!props.excludeSettingTypes.includes(x.value))),filtered}),activeSubSetting=ref(null),activeSettingType=computed(()=>settingTypes.value[currentIndex.value]),mouseMode=computed(()=>store$1.cursorData?store$1.cursorData.isUseMousePos:void 0);watch(()=>props.activeSetting,()=>{let index=settingTypes.value.findIndex(x=>x.value===props.activeSetting);index>-1?currentIndex.value=index:console.warn(`Error finding setting ${props.activeSetting}`)},{immediate:!0}),watch(activeSettingType,value=>store$1.activeSetting=value.value,{immediate:!0}),watch(activeSettingType,(newValue,oldValue)=>{newValue.value&&oldValue.value}),onMounted(()=>{getUINavServiceInstance().useCrossfire=!1}),onUnmounted(async()=>{getUINavServiceInstance().useCrossfire=!0});let setTool=settingType=>{currentIndex.value=settingTypes.value.findIndex(x=>x.value===settingType.value)},goPreviousTab=()=>{currentIndex.value=currentIndex.value>0?currentIndex.value-1:settingTypes.value.length-1},goNextTab=()=>{currentIndex.value=currentIndex.value(openBlock(),createElementBlock(`div`,_hoisted_1$88,[withDirectives((openBlock(),createElementBlock(`div`,_hoisted_2$75,[createBaseVNode(`div`,{onClick:goPreviousTab},[createVNode(unref(bngIcon_default),{type:unref(icons).arrowSmallLeft},null,8,[`type`]),createVNode(unref(bngBinding_default),{action:`menu_tab_left`,deviceMask:`xinput`})]),createBaseVNode(`div`,_hoisted_3$65,[(openBlock(!0),createElementBlock(Fragment,null,renderList(settingTypes.value,settingType=>withDirectives((openBlock(),createElementBlock(`div`,{key:settingType.value,class:normalizeClass([{active:activeSettingType.value.value===settingType.value},`setting-type`]),onClick:$event=>setTool(settingType)},[createVNode(unref(bngIcon_default),{type:settingType.icon,class:`setting-type-icon`},null,8,[`type`])],10,_hoisted_4$50)),[[unref(BngTooltip_default),activeSettingType.value.value===settingType.value?void 0:settingType.label,`top`]])),128))]),createBaseVNode(`div`,{onClick:goNextTab},[createVNode(unref(bngBinding_default),{action:`menu_tab_right`,deviceMask:`xinput`}),createVNode(unref(bngIcon_default),{type:unref(icons).arrowSmallRight},null,8,[`type`])])])),[[unref(BngBlur_default)],[unref(BngOnUiNav_default),goPreviousTab,`tab_l`],[unref(BngOnUiNav_default),goNextTab,`tab_r`]]),withDirectives((openBlock(),createBlock(LayerSettingsBase_default,null,{heading:withCtx(()=>[createBaseVNode(`div`,_hoisted_5$42,[createBaseVNode(`span`,_hoisted_6$30,[createBaseVNode(`span`,null,[createTextVNode(toDisplayString(activeSettingType.value.label)+` `,1),activeSubSetting.value?(openBlock(),createElementBlock(`span`,_hoisted_7$26,`/`)):createCommentVNode(``,!0)]),activeSubSetting.value?(openBlock(),createElementBlock(`span`,_hoisted_8$20,toDisplayString(activeSubSetting.value.label),1)):createCommentVNode(``,!0)]),(unref(store$1).reapplyActive||unref(store$1).requestApplyActive)&&(activeSettingType.value.value!==`transform`||!mouseMode.value)?(openBlock(),createBlock(unref(BindingButton_default),{key:0,icon:unref(icons).restart,accent:`text`,label:`Reset`,uiEvent:CONTROLLER_RESET_BINDING,onClick:resetSettings},null,8,[`icon`])):createCommentVNode(``,!0)])]),default:withCtx(()=>[(openBlock(),createBlock(resolveDynamicComponent(activeSettingType.value.component),{onSubSettingChanged},null,32))]),_:1})),[[unref(BngOnUiNav_default),onAdvanced,`advanced`],[unref(BngBlur_default)]])]))}},LayerSettings_default=__plugin_vue_export_helper_default(_sfc_main$96,[[`__scopeId`,`data-v-ca9ed9d2`]]),_hoisted_1$87={key:0,"bng-ui-scope":`liveryeditor-editmode`,class:`liveryeditor-editmode-layout`},_hoisted_2$74={class:`layers-preview-container`},_hoisted_3$64={class:`layer-settings-wrapper`},SAVE_TYPES={default:1,asGroup:2},FOCUS_LD_TRIGGER_VALUE=-.999,FOCUS_RU_TRIGGER_VALUE=.999,HEADER_TEXT$1=`Edit Mode`,CONTEXT_MENU_NAME=`context-menu`,CONTROLLER_EXIT_BINDING=`back`,CONTROLLER_SAVE_BINDING=`menu`,APPLY_DEFAULT_HINTS=[{id:`apply`,content:{type:`binding`,props:{uiEvent:`ok`},label:`Apply`}},{id:`cancel`,content:{type:`binding`,props:{uiEvent:`back`},label:`Cancel`}}],APPLY_MOUSE_HINTS=[{id:`cancel`,content:{type:`binding`,props:{uiEvent:`back`},label:`Cancel`}}],FREECAM_CONTROLLER_HINTS=[{id:`toggle_freecam`,content:{type:`binding`,props:{uiEvent:`action_4`},label:`Toggle View Point`}}],VIEWPOINT_CONTROLLER_HINTS=[{id:`toggle_freecam`,content:{type:`binding`,props:{uiEvent:`action_4`},label:`Toggle Free Cam`}}],DELETE_LAYER_HINT={id:`delete`,content:{type:`binding`,props:{uiEvent:`advanced`},label:`Delete`}},_sfc_main$95={__name:`EditModeLayout`,setup(__props){useCssVars(_ctx=>({ff7f3326:alphaTextureBackground.value}));let infoBar=useInfoBar(),{showIfController}=storeToRefs(controls_default()),actionHoldService=useActionHoldService(),rootStore=useLiveryEditorStore(),store$1=useLayerSettingsStore(),popover=usePopover(),freecam=ref(!1),CONTEXT_MENU_STYLES=ref({display:`flex`,"flex-direction":`column`}),contextMenuName=ref(`context-menu`),alphaTextureBackground=computed(()=>`url(${getAssetURL(`images/alpha_texture.png`)}`);onBeforeMount(async()=>{await store$1.getInitialData(),watch(showIfController,()=>{actionHoldService.clear()})}),onMounted(()=>{store$1.init(),infoBar.clearHints()}),onUnmounted(()=>{infoBar.clearHints()});async function onAddOrChangeDecal(){await rootStore.toggleShowDecalSelector()}function onBack(){popover.isShown(CONTEXT_MENU_NAME)?popover.hide(CONTEXT_MENU_NAME):store$1.appliedLayers&&store$1.appliedLayers.length>0&&store$1.requestApplyActive?store$1.cancelRequestApply():store$1.appliedLayers&&store$1.reapplyActive?store$1.cancelReapply():confirmCancelChanges()}function onContextMenu(){store$1.reapplyActive?store$1.requestChangeDecal():store$1.requestApplyActive?rootStore.toggleShowDecalSelector():store$1.duplicateActiveLayer()}function onAdvanced(){!store$1.requestApplyActive&&!store$1.reapplyActive&&store$1.activeLayerUid&&store$1.appliedLayers.length>1&&(getUINavServiceInstance().useCrossfire=!0,openConfirmation(`Delete Decal`).then(res=>{res&&store$1.removeAppliedLayer(store$1.activeLayerUid),getUINavServiceInstance().useCrossfire=!0}))}function onOk(){(store$1.requestApplyActive||store$1.reapplyActive)&&store$1.apply()}function confirmSaveChanges(){!store$1.appliedLayers||store$1.appliedLayers.length===0||(getUINavServiceInstance().useCrossfire=!0,openConfirmation(`Save`,`Save changes and exit edit mode?`,[{label:$translate.instant(`ui.common.cancel`),value:void 0,extras:{cancel:!0,accent:ACCENTS.secondary}},{label:$translate.instant(`ui.common.save`),value:SAVE_TYPES.default,extras:{default:!0}}]).then(res=>{res?store$1.saveChanges():getUINavServiceInstance().useCrossfire=!1}))}async function confirmCancelChanges(){getUINavServiceInstance().useCrossfire=!0;let hasChanges=store$1.appliedLayers&&store$1.appliedLayers.length>0;await openConfirmation(`Exit`,hasChanges?`Exit edit mode and lose all changes?`:`Exit Edit Mode?`)?(hasChanges&&await store$1.cancelChanges(),await store$1.deactivate()):getUINavServiceInstance().useCrossfire=!1}let removeLayer=()=>{store$1.removeAppliedLayer(store$1.activeLayerUid),popover.hide(CONTEXT_MENU_NAME)};function onSecondaryAction(element){!store$1.reapplyActive&&!store$1.requestApplyActive&&store$1.requestApply()}function onTertiaryAction(element){store$1.cursorData.applied&&!store$1.reapplyActive&&store$1.toggleHighlightActive()}function onQuaternaryAction(element){freecam.value=!freecam.value}function onRotateHCam(element){if(freecam.value)return!0;let direction$1=element.detail.value;(direction$1>=FOCUS_RU_TRIGGER_VALUE||direction$1<=FOCUS_LD_TRIGGER_VALUE)&&rootStore.switchOrthographicViewByDirection(direction$1>0?-1:1,0)}function onRotateVCam(element){if(freecam.value)return!0;let direction$1=element.detail.value;(direction$1>=FOCUS_RU_TRIGGER_VALUE||direction$1<=FOCUS_LD_TRIGGER_VALUE)&&rootStore.switchOrthographicViewByDirection(0,direction$1>0?-1:1)}let APPLY_CONTROLLER_HINTS=[{id:`change_decal`,content:{type:`binding`,props:{uiEvent:`context`},label:`Change Decal`},action:store$1.requestChangeDecal}],DEFAULT_HINTS=[{id:`duplicate_decal`,content:{type:`binding`,props:{action:`duplicate_active_layer`},label:`Duplicate Decal`,action:store$1.duplicateActiveLayer}},{id:`activate_previous_decal`,content:{type:`binding`,props:{action:`activate_previous_layer`},label:`Edit Previous Decal`}},{id:`activate_next_decal`,content:{type:`binding`,props:{action:`activate_next_layer`},label:`Edit Next Decal`}},{id:`save`,content:{type:`binding`,props:{uiEvent:`menu`},label:`Save`}},{id:`exit`,content:{type:`binding`,props:{uiEvent:`back`},label:`Exit`}}],DEFAULT_CONTROLLER_HINTS=[{id:`apply_or_new`,content:{type:`binding`,props:{uiEvent:`action_2`},label:`New Decal`}},{id:`delete_decal`,content:{type:`binding`,props:{uiEvent:`advanced`},label:`Delete Decal`,action:()=>store$1.removeAppliedLayer(store$1.activeLayerUid)}},{id:`duplicate_decal`,content:{type:`binding`,props:{uiEvent:`context`},label:`Duplicate Decal`},action:()=>store$1.duplicateActiveLayer()},{id:`highlight_decal`,content:{type:`binding`,props:{uiEvent:`action_3`},label:`Toggle Highlight`},action:()=>store$1.toggleHighlightActive()}];watchEffect(()=>{let isController$2=showIfController.value,defaultControllerHints=!1,hints;removeHints(),store$1.requestApplyActive||store$1.reapplyActive?hints=store$1.cursorData.isUseMousePos?APPLY_MOUSE_HINTS:isController$2?APPLY_CONTROLLER_HINTS:APPLY_DEFAULT_HINTS:isController$2?(hints=DEFAULT_CONTROLLER_HINTS,defaultControllerHints=!0):hints=DEFAULT_HINTS;for(let i=0;i1&&infoBar.addHints(DELETE_LAYER_HINT,`change_decal`,!0),(!store$1.appliedLayers||store$1.appliedLayers.length<=1)&&infoBar.removeHints(`delete_decal`)}),watch(()=>freecam.value,async()=>{freecam.value?rootStore.cameraView=`free`:await rootStore.setOrthographicView(`right`)});function removeHints(){APPLY_MOUSE_HINTS.forEach(x=>infoBar.removeHints(x.id)),APPLY_CONTROLLER_HINTS.forEach(x=>infoBar.removeHints(x.id)),APPLY_DEFAULT_HINTS.forEach(x=>infoBar.removeHints(x.id)),DEFAULT_HINTS.forEach(x=>infoBar.removeHints(x.id)),DEFAULT_CONTROLLER_HINTS.forEach(x=>infoBar.removeHints(x.id)),FREECAM_CONTROLLER_HINTS.forEach(x=>infoBar.removeHints(x.id)),VIEWPOINT_CONTROLLER_HINTS.forEach(x=>infoBar.removeHints(x.id)),infoBar.removeHints(DELETE_LAYER_HINT.id)}let headerStore=useEditorHeaderStore(),resetDisabled=ref(!1),saveDisabled=ref(!0),useMouse=computed(()=>store$1.cursorData?store$1.cursorData.isUseMousePos:void 0),changeMouseMode=async newValue=>await store$1.setUseMousePos(newValue),HEADER_APPLY_ITEMS=[{id:`cancel_apply`,section:`end`,component:shallowRef(bngButton_default),props:{label:`Cancel Apply`,accent:ACCENTS.attention},events:{click:()=>{store$1.requestApplyActive&&store$1.cancelRequestApply()}},hidden:!0},{id:`undo_reapply`,section:`end`,component:shallowRef(bngButton_default),props:{label:`Undo Reapply`,accent:ACCENTS.attention},events:{click:()=>{store$1.reapplyActive&&store$1.cancelReapply()}},hidden:!0},{id:`use_mouse`,section:`end`,component:shallowRef(bngSwitch_default),props:{modelValue:useMouse,label:`Use Mouse`,uncheckedWithBackground:!0},events:{"update:modelValue":changeMouseMode}}],showBinding=computed(()=>!store$1.active||!store$1.appliedLayers||store$1.appliedLayers.length===0||!(store$1.reapplyActive||store$1.requestApplyActive)),HEADER_GLOBAL_ITEMS=[{id:`save_changes`,section:`start`,component:shallowRef(BindingButton_default),props:{icon:icons.saveAs1,accent:ACCENTS.main,label:`Save and Exit`,disabled:saveDisabled,uiEvent:CONTROLLER_SAVE_BINDING,deviceMask:`xinput`},events:{click:confirmSaveChanges}},{id:`exit_edit_mode`,section:`start`,component:shallowRef(BindingButton_default),props:{icon:icons.exit,accent:ACCENTS.attention,label:`Exit Edit Mode`,uiEvent:CONTROLLER_EXIT_BINDING,deviceMask:`xinput`,showBinding},events:{click:confirmCancelChanges}}];return watch(()=>store$1.active,active=>{active&&(headerStore.setHeader(HEADER_TEXT$1,`ribbon`),headerStore.setPreheader(void 0))},{immediate:!0}),watchEffect(()=>{store$1.appliedLayers&&store$1.appliedLayers.length>0&&store$1.requestApplyActive?headerStore.showItem(`cancel_apply`):headerStore.hideItem(`cancel_apply`)}),watch(()=>store$1.reapplyActive,value=>{value?headerStore.showItem(`undo_reapply`):headerStore.hideItem(`undo_reapply`)}),watchEffect(()=>{saveDisabled.value=!store$1.appliedLayers||store$1.appliedLayers.length===0,resetDisabled.value=!store$1.requestApplyActive&&!store$1.reapplyActive}),onMounted(()=>{headerStore.removeItems(HEADER_APPLY_ITEMS),headerStore.removeItem(HEADER_GLOBAL_ITEMS),store$1.active&&(headerStore.addItems(HEADER_APPLY_ITEMS,!0),headerStore.addItems(HEADER_GLOBAL_ITEMS))}),onUnmounted(()=>{headerStore.removeItems(HEADER_APPLY_ITEMS),headerStore.removeItems(HEADER_GLOBAL_ITEMS)}),(_ctx,_cache)=>unref(store$1).active?withDirectives((openBlock(),createElementBlock(`div`,_hoisted_1$87,[createBaseVNode(`div`,_hoisted_2$74,[unref(store$1).appliedLayers&&!unref(store$1).requestApplyActive?withDirectives((openBlock(),createBlock(unref(bngImageTile_default),{key:0,icon:unref(icons).decal,class:normalizeClass([{cancel:unref(store$1).requestApplyActive},`add-item`]),disabled:unref(store$1).reapplyActive?`disabled`:``,ratio:`1:1`,onClick:onAddOrChangeDecal},{default:withCtx(()=>[..._cache[0]||=[createBaseVNode(`label`,null,`Add`,-1)]]),_:1},8,[`icon`,`class`,`disabled`])),[[unref(BngBlur_default)]]):withDirectives((openBlock(),createElementBlock(`div`,{key:1,class:`layer-ghost-wrapper`,onClick:onAddOrChangeDecal},[createVNode(DecalPreviewTile_default,{textureImage:unref(store$1).cursorData.decalTexturePath,textureColor:unref(store$1).cursorData.color},null,8,[`textureImage`,`textureColor`]),createVNode(unref(bngIcon_default),{class:`hover-icon`,type:unref(icons).edit},null,8,[`type`])])),[[unref(BngBlur_default)]]),unref(store$1).appliedLayers&&unref(store$1).appliedLayers.length>0?withDirectives((openBlock(),createBlock(EditModeLayersPreview_default,{key:2,contextMenuName:contextMenuName.value},null,8,[`contextMenuName`])),[[unref(BngBlur_default)]]):createCommentVNode(``,!0)]),createBaseVNode(`div`,_hoisted_3$64,[createVNode(unref(LayerSettings_default))]),unref(store$1).appliedLayers&&unref(store$1).appliedLayers.length>0&&unref(store$1).activeLayerUid!==null&&unref(store$1).activeLayerUid!==void 0?(openBlock(),createBlock(unref(bngPopoverContent_default),{key:0,name:contextMenuName.value},{default:withCtx(()=>[createBaseVNode(`div`,{class:`layer-context-menu`,style:normalizeStyle(CONTEXT_MENU_STYLES.value)},[createVNode(unref(bngButton_default),{onClick:withModifiers(unref(store$1).requestChangeDecal,[`stop`])},{default:withCtx(()=>[..._cache[1]||=[createTextVNode(`Change Decal`,-1)]]),_:1},8,[`onClick`]),createVNode(unref(bngButton_default),{disabled:unref(store$1).appliedLayers.length<=1,accent:`attention`,onClick:withModifiers(removeLayer,[`stop`])},{default:withCtx(()=>[..._cache[2]||=[createTextVNode(`Delete`,-1)]]),_:1},8,[`disabled`])],4)]),_:1},8,[`name`])):createCommentVNode(``,!0)])),[[unref(BngOnUiNav_default),onOk,`ok`],[unref(BngOnUiNav_default),onContextMenu,`context`],[unref(BngOnUiNav_default),onAdvanced,`advanced`],[unref(BngOnUiNav_default),onBack,`back`],[unref(BngOnUiNav_default),confirmSaveChanges,`menu`],[unref(BngOnUiNav_default),onSecondaryAction,`action_2`],[unref(BngOnUiNav_default),onTertiaryAction,`action_3`],[unref(BngOnUiNav_default),onQuaternaryAction,`action_4`],[unref(BngOnUiNav_default),onRotateHCam,`rotate_h_cam`],[unref(BngOnUiNav_default),onRotateVCam,`rotate_v_cam`]]):createCommentVNode(``,!0)}},EditModeLayout_default=__plugin_vue_export_helper_default(_sfc_main$95,[[`__scopeId`,`data-v-9b377f5e`]]),_hoisted_1$86={class:`layer-content`},_hoisted_2$73={class:`layer-name`},_hoisted_3$63={key:0,class:`layer-actions`},_hoisted_4$49={class:`layer-preview`},_hoisted_5$41={key:1,class:`group-preview`},_sfc_main$94={__name:`LayerTile`,props:{layer:Object,isTargeted:Boolean,forceShowActions:Boolean,disableMoveUp:Boolean,disableMoveDown:Boolean},emits:[`lockClicked`,`hideClicked`,`moveClicked`,`enableClicked`],setup(__props){let isHovered=ref(!1),toRgba255Styles=colors=>`rgba(${colors[0]*255}, ${colors[1]*255}, ${colors[2]*255}, ${colors[3]})`;return(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,{class:`layer-tile`,onMouseover:_cache[1]||=$event=>isHovered.value=!0,onMouseleave:_cache[2]||=$event=>isHovered.value=!1},[createBaseVNode(`div`,_hoisted_1$86,[renderSlot(_ctx.$slots,`content`,{},()=>[createBaseVNode(`div`,_hoisted_2$73,toDisplayString(__props.layer.name),1),__props.forceShowActions||!__props.layer.enabled?(openBlock(),createElementBlock(`div`,_hoisted_3$63,[__props.forceShowActions?(openBlock(),createBlock(unref(bngBinding_default),{key:0,"track-ignore":!0,uiEvent:`action_2`,deviceMask:`xinput`})):createCommentVNode(``,!0),createVNode(unref(bngButton_default),{accent:`outlined`,onClick:_cache[0]||=$event=>_ctx.$emit(`enableClicked`),icon:__props.layer.enabled?unref(icons).eyeSolidOpened:unref(icons).eyeSolidClosed},null,8,[`icon`])])):createCommentVNode(``,!0)],!0)]),createBaseVNode(`div`,_hoisted_4$49,[__props.layer.type===1?(openBlock(),createElementBlock(`div`,{key:0,class:`fill-preview`,style:normalizeStyle({"--layer-color":toRgba255Styles(__props.layer.color)})},null,4)):__props.layer.type===3?(openBlock(),createElementBlock(`div`,_hoisted_5$41,[createVNode(unref(bngIcon_default),{type:unref(icons).group},null,8,[`type`])])):__props.layer.type===0?(openBlock(),createBlock(DecalPreviewTile_default,{key:2,textureImage:__props.layer.preview,textureColor:__props.layer.color},null,8,[`textureImage`,`textureColor`])):createCommentVNode(``,!0)])],32))}},LayerTile_default=__plugin_vue_export_helper_default(_sfc_main$94,[[`__scopeId`,`data-v-87650a01`]]),_hoisted_1$85={class:`layers-manager`},_hoisted_2$72={class:`layers-manager-header`},_hoisted_3$62=[`onFocusin`];const VIEW_MODES={DEFAULT:`default`,COMPACT:`compact`};var _sfc_main$93={__name:`LayersManager`,props:mergeModels({layers:{type:Array,required:!0},view:{type:String,default:`default`,validator(value){return Object.values(VIEW_MODES).find(x=>x===value)}}},{selectedKeys:{},selectedKeysModifiers:{}}),emits:mergeModels([`focusedLayer`],[`update:selectedKeys`]),setup(__props,{emit:__emit}){let emit$1=__emit,rootStore=useLiveryEditorStore(),expandedKeys=ref([]),selectedKeys=useModel(__props,`selectedKeys`),focusLayer=ref(null),layersScrollable=ref(null);ref(!1);let isFocusFirstLayer=ref(!1);watch(()=>rootStore.selectedLayers,()=>{(!rootStore.selectedLayers||rootStore.selectedLayers.length===0)&&(rootStore.selectMode=`single`)}),watch(()=>selectedKeys.value,(newValue,oldValue)=>{(!newValue||newValue.length===0&&oldValue&&oldValue.length>0)&&(isFocusFirstLayer.value=!0)});let setMultiSelect=async node=>{rootStore.selectMode!==`multi`&&(rootStore.selectMode=`multi`,rootStore.toggleSelection(node.id,!1))},toggleEnabled=layer=>{Lua_default.extensions.ui_liveryEditor_layerAction.performAction(`enabled`).then(luaRes=>{layer.enabled=luaRes})},onClickItem=node=>{Lua_default.extensions.ui_liveryEditor_selection.select(node.id,!0),setFocusLayer(null)},setFocusLayer=layer=>{isFocusFirstLayer.value&&=!1,focusLayer.value=layer,emit$1(`focusedLayer`,layer)},handleFocusOut=event=>{setFocusLayer(null)};return(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$85,[createBaseVNode(`div`,_hoisted_2$72,[renderSlot(_ctx.$slots,`header`,{},void 0,!0)]),__props.layers?(openBlock(),createElementBlock(`div`,{key:0,ref_key:`layersScrollable`,ref:layersScrollable,class:`layers-scrollable`,onFocusout:handleFocusOut},[createVNode(unref(tree_default),{expandedKeys:expandedKeys.value,"onUpdate:expandedKeys":_cache[2]||=$event=>expandedKeys.value=$event,selectedKeys:selectedKeys.value,"onUpdate:selectedKeys":_cache[3]||=$event=>selectedKeys.value=$event,nodes:__props.layers,selectMode:unref(rootStore).selectMode,keyName:`id`,class:`layers-tree`},{node:withCtx(({node,parentNode,expanded,selected,expand})=>[node.hidden?createCommentVNode(``,!0):withDirectives((openBlock(),createElementBlock(`div`,{key:0,onFocusin:withModifiers($event=>setFocusLayer(node),[`self`]),"bng-nav-item":``,class:`layer-node`},[createVNode(LayerTile_default,{layer:node,forceShowActions:focusLayer.value&&focusLayer.value.uid===node.uid,onEnableClicked:()=>toggleEnabled(node)},null,8,[`layer`,`forceShowActions`,`onEnableClicked`]),node.children?(openBlock(),createBlock(unref(bngIcon_default),{key:0,type:expanded?unref(icons).arrowSmallUp:unref(icons).arrowSmallDown,class:`expand-icon`,onMousedown:_cache[0]||=withModifiers(()=>{},[`stop`]),onMouseup:_cache[1]||=withModifiers(()=>{},[`stop`]),onClick:withModifiers(expand,[`stop`])},null,8,[`type`,`onClick`])):createCommentVNode(``,!0)],40,_hoisted_3$62)),[[unref(BngClick_default),{clickCallback:()=>onClickItem(node),holdCallback:()=>setMultiSelect(node),repeatInterval:0}],[unref(BngUiNavFocus_default),isFocusFirstLayer.value&&__props.layers[0].uid===node.uid?0:void 0],[unref(BngFocusIf_default),isFocusFirstLayer.value&&__props.layers[0].uid===node.uid],[unref(BngOnUiNav_default),void 0,`ok`,{asMouse:!0,focusRequired:!0}]])]),_:1},8,[`expandedKeys`,`selectedKeys`,`nodes`,`selectMode`])],544)):createCommentVNode(``,!0)]))}},LayersManager_default=__plugin_vue_export_helper_default(_sfc_main$93,[[`__scopeId`,`data-v-1bc4f03d`]]),_hoisted_1$84={class:`paint-settings`},_sfc_main$92={__name:`PaintSettings`,setup(__props){let LUA_FILL_LAYER=Lua_default.extensions.ui_liveryEditor_layers_fill,paint=new Paint,color=ref({hue:.5,saturation:1,luminosity:.5});function setColor(){paint.hsl=[color.value.hue,color.value.saturation,color.value.luminosity],LUA_FILL_LAYER.updateLayer({color:paint.rgba})}return(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$84,[createVNode(unref(bngColorPicker_default),{modelValue:color.value,"onUpdate:modelValue":_cache[0]||=$event=>color.value=$event,view:`luminosity`},null,8,[`modelValue`]),createBaseVNode(`div`,null,[createVNode(unref(bngButton_default),{onClick:setColor},{default:withCtx(()=>[..._cache[1]||=[createTextVNode(`Save`,-1)]]),_:1})])]))}},PaintSettings_default=__plugin_vue_export_helper_default(_sfc_main$92,[[`__scopeId`,`data-v-66a34a99`]]),_hoisted_1$83={class:`liveryeditor-default-layout`,"bng-ui-scope":`default-layout`},_hoisted_2$71={class:`layers-manager-wrapper`},_hoisted_3$61={key:0,class:`multiselect-header`},_hoisted_4$48={class:`message`},_hoisted_5$40={class:`add-content-wrapper`},_hoisted_6$29={class:`action-tile`},_hoisted_7$25={key:1,class:`layer-settings-wrapper`,"bng-ui-scope":`layer-settings`},SETTINGS_VIEWS={edit:{label:`Edit`,value:`edit`,hideActions:!0,propertySettings:!0,disableLayersManager:!0,props:{excludeSettingTypes:[`transform`]}},order:{label:`Change Order`,value:`order`,component:LayerSortSettings_default,hideActions:!0,disableLayersManager:!0},paint:{label:`Paint`,value:`paint`,component:PaintSettings_default,hideActions:!0,disableLayersManager:!0}},HEADER_TEXT=`Livery Editor`,_sfc_main$91={__name:`DefaultLayout`,setup(__props){useUINavScope(`default-layout`);let rootStore=useLiveryEditorStore(),infoBar=useInfoBar(),{layers:layers$1}=storeToRefs(rootStore),actionsDrawer=ref(null),settingType=shallowRef(null),layerActions=computed(()=>rootStore.layerActions?{label:rootStore.selectedLayers.length===1?`${rootStore.selectedLayers[0].name} Actions`:`${rootStore.selectedLayers.length} Layers Actions`,items:rootStore.layerActions,allowOpenDrawer:!1}:void 0),headerLabel=computed(()=>rootStore.visibleLayersCount===0?`No Layers`:rootStore.visibleLayersCount+` Layer`+rootStore.visibleLayersCount>1?`s`:``),multiSelectMessage=computed(()=>{if(rootStore.selectedLayers)return rootStore.selectedLayers.length+`Layer${rootStore.selectedLayers.length>1?`s`:``}`});onMounted(()=>{getUINavServiceInstance().useCrossfire=!0});function onBack(){settingType.value?(console.log(`onBack > closed settings`),closeSettings()):rootStore.selectedLayers&&rootStore.selectedLayers.length>0?(console.log(`onBack > closed actions`),rootStore.dismissLayerActions().then()):(console.log(`onBack > catch all`),openExitDialog().then())}function onMenu(){settingType.value?closeActions():rootStore.selectedLayers&&rootStore.selectedLayers.length>0||openSaveDialog()}function closeActions(){settingType.value&&closeSettings(),rootStore.dismissLayerActions().then()}function closeSettings(){settingType.value=null}function onActionTriggered(actionItem){let setting=SETTINGS_VIEWS[actionItem.value];setting?settingType.value=setting:rootStore.onActionItemSelected(actionItem).then()}let saving=ref(!1),dialogStates=reactive({isDialogOpen:!1});async function openExitDialog(){if(dialogStates.isDialogOpen)return!0;dialogStates.isDialogOpen=!0,await rootStore.openExitDialog(),dialogStates.isDialogOpen=!1}function openSaveDialog(){if(dialogStates.isDialogOpen)return!0;saving.value=!0,dialogStates.isDialogOpen=!0,rootStore.save().then(()=>{saving.value=!1,dialogStates.isDialogOpen=!1})}function openPaintSettings(){settingType.value=SETTINGS_VIEWS.paint}let saveLabel=computed(()=>saving.value?`Saving...`:`Save`),HEADER_ITEMS=[{id:`save_editor`,section:`start`,component:shallowRef(bngButton_default),props:{icon:icons.saveAs1,accent:ACCENTS.main,label:saveLabel,disabled:saving},events:{click:openSaveDialog}},{id:`exit_editor`,section:`start`,component:shallowRef(bngButton_default),props:{icon:icons.exit,accent:ACCENTS.attention,label:`Exit`},events:{click:openExitDialog}},{id:`paint_settings`,section:`start`,component:shallowRef(bngButton_default),props:{icon:icons.exit,accent:ACCENTS.secondary,label:`Paint`},events:{click:openPaintSettings}}],headerStore=useEditorHeaderStore();watchEffect(()=>{rootStore.currentFile&&rootStore.currentFile.name&&headerStore.setPreheader(rootStore.currentFile.name)}),onMounted(()=>{headerStore.setHeader(HEADER_TEXT),headerStore.addItems(HEADER_ITEMS)}),onUnmounted(()=>{headerStore.removeItems(HEADER_ITEMS)});let NAV_HINTS=[{id:`save`,content:{type:`binding`,props:{uiEvent:`menu`},label:`Save`},action:async()=>await rootStore.save(!1)},{id:`exit`,content:{type:`binding`,props:{uiEvent:`back`},label:`Exit`},action:async()=>rootStore.openExitDialog}],ACTIONS_DRAWER_HINTS=[{id:`actions_back`,content:{type:`binding`,props:{uiEvent:`back`},label:`Back`}}],SETTINGS_NAV_HINTS=[{id:`selected_done`,content:{type:`binding`,props:{uiEvent:`menu`},label:`Done`}},{id:`selected_back`,content:{type:`binding`,props:{uiEvent:`back`},label:`Done (Return to Actions)`}}];return watchEffect(()=>{infoBar.clearHints(),settingType.value?infoBar.addHints(SETTINGS_NAV_HINTS):layerActions.value?infoBar.addHints(ACTIONS_DRAWER_HINTS):infoBar.addHints(NAV_HINTS)}),onMounted(()=>{infoBar.addHints(NAV_HINTS)}),onUnmounted(()=>{infoBar.removeHints(...NAV_HINTS.map(x=>x.id))}),(_ctx,_cache)=>withDirectives((openBlock(),createElementBlock(`div`,_hoisted_1$83,[createBaseVNode(`div`,_hoisted_2$71,[withDirectives((openBlock(),createBlock(unref(LayersManager_default),{selectedKeys:unref(rootStore).selectedLayerUids,"onUpdate:selectedKeys":_cache[0]||=$event=>unref(rootStore).selectedLayerUids=$event,layers:unref(layers$1),class:normalizeClass({inactive:settingType.value&&settingType.value.disableLayersManager})},{header:withCtx(()=>[createVNode(unref(bngCardHeading_default),{type:`ribbon`},{default:withCtx(()=>[createTextVNode(toDisplayString(headerLabel.value),1)]),_:1}),unref(rootStore).selectMode===`multi`?(openBlock(),createElementBlock(`div`,_hoisted_3$61,[withDirectives((openBlock(),createBlock(unref(bngButton_default),{accent:unref(ACCENTS).attention,onClick:closeActions,class:`cancel-btn`},{default:withCtx(()=>[..._cache[1]||=[createTextVNode(`Cancel`,-1)]]),_:1},8,[`accent`])),[[unref(BngOnUiNav_default),void 0,`ok`,{asMouse:!0,focusRequired:!0}]]),createBaseVNode(`span`,_hoisted_4$48,toDisplayString(multiSelectMessage.value),1)])):withDirectives((openBlock(),createBlock(unref(bngButton_default),{key:1,accent:unref(ACCENTS).outlined,disabled:unref(rootStore).selectedLayers&&unref(rootStore).selectedLayers.length>0,onClick:unref(rootStore).toggleEditModeLayout},{default:withCtx(()=>[createBaseVNode(`span`,_hoisted_5$40,[createVNode(unref(bngIcon_default),{type:unref(icons).plus},null,8,[`type`]),_cache[2]||=createBaseVNode(`span`,{class:`add-label`},`Add Decal`,-1)])]),_:1},8,[`accent`,`disabled`,`onClick`])),[[unref(BngOnUiNav_default),void 0,`ok`,{asMouse:!0,focusRequired:!0}]])]),_:1},8,[`selectedKeys`,`layers`,`class`])),[[unref(BngBlur_default)]])]),layerActions.value&&(!settingType.value||!settingType.value.hideActions)?(openBlock(),createBlock(unref(bngActionDrawer_default),{key:0,ref_key:`actionsDrawer`,ref:actionsDrawer,actions:layerActions.value,"item-width":10,"item-margin":1,class:`actions-drawer`,onSelect:onActionTriggered},{controls:withCtx(()=>[withDirectives(createVNode(unref(bngButton_default),{accent:unref(ACCENTS).outlined,icon:unref(icons).abandon,onClick:closeActions},null,8,[`accent`,`icon`]),[[unref(BngOnUiNav_default),void 0,`ok`,{asMouse:!0,focusRequired:!0}]])]),action:withCtx(({item,isLoading,select})=>[createBaseVNode(`div`,_hoisted_6$29,[withDirectives(createVNode(unref(bngImageTile_default),{label:item.toggleAction&&!item.active?item.inactiveLabel:item.label,icon:item.toggleAction&&!item.active?item.inactiveIcon:item.icon,externalImage:item.preview,"bng-nav-item":``,class:`action-tile`,onClick:$event=>select(item)},null,8,[`label`,`icon`,`externalImage`,`onClick`]),[[unref(BngOnUiNav_default),void 0,`ok`,{asMouse:!0,focusRequired:!0}]])])]),_:1},8,[`actions`])):createCommentVNode(``,!0),settingType.value?(openBlock(),createElementBlock(`div`,_hoisted_7$25,[settingType.value.propertySettings?(openBlock(),createBlock(unref(LayerSettings_default),normalizeProps(mergeProps({key:0},settingType.value.props)),null,16)):withDirectives((openBlock(),createBlock(unref(LayerSettingsBase_default),{key:1,heading:settingType.value.label},{default:withCtx(()=>[(openBlock(),createBlock(resolveDynamicComponent(settingType.value.component)))]),_:1},8,[`heading`])),[[unref(BngBlur_default)]])])):createCommentVNode(``,!0)])),[[unref(BngOnUiNav_default),onBack,`back`],[unref(BngOnUiNav_default),onMenu,`menu`]])}},DefaultLayout_default=__plugin_vue_export_helper_default(_sfc_main$91,[[`__scopeId`,`data-v-6dca75f9`]]),_hoisted_1$82={class:`editor`,"bng-ui-scope":`livery-editor`},_hoisted_2$70={class:`editor-header-wrapper`},EDITOR_VIEWS_COMPONENT={[EDITOR_VIEWS.decalSelector]:DecalSelector_default,[EDITOR_VIEWS.editMode]:EditModeLayout_default,[EDITOR_VIEWS.default]:DefaultLayout_default},_sfc_main$90={__name:`LiveryEditor`,setup(__props){let store$1=useLiveryEditorStore(),infobar=useInfoBar(),{showIfController}=storeToRefs(controls_default());infobar.visible=!0;let currentView=computed(()=>EDITOR_VIEWS_COMPONENT[store$1.editorView]),minimizedMode=ref(!1);watch(showIfController,value=>{store$1.setUseMousePos(!value)}),onBeforeMount(async()=>{await store$1.startEditor(),store$1.setUseMousePos(!showIfController.value)});let HEADER_ITEMS=[{id:`camera_view`,section:`end`,component:shallowRef(CameraViewButton_default)}],headerStore=useEditorHeaderStore();return onMounted(()=>{headerStore.setPreheader(store$1.currentFile?store$1.currentFile:`New Save`),headerStore.addItems(HEADER_ITEMS)}),onUnmounted(()=>{headerStore.removeItems(HEADER_ITEMS)}),(_ctx,_cache)=>withDirectives((openBlock(),createElementBlock(`div`,_hoisted_1$82,[createBaseVNode(`div`,_hoisted_2$70,[createVNode(unref(LiveryEditorHeader_default))]),createBaseVNode(`div`,{class:normalizeClass([`editor-content`,{"layers-collapse":minimizedMode.value}])},[(openBlock(),createBlock(resolveDynamicComponent(currentView.value)))],2)])),[[unref(BngOnUiNav_default),()=>{},`menu,back,ok`]])}},LiveryEditor_default=__plugin_vue_export_helper_default(_sfc_main$90,[[`__scopeId`,`data-v-27ec64b0`]]),_hoisted_1$81={class:`livery-main-view`,"bng-ui-scope":`livery-main-scope`},_hoisted_2$69={key:0,class:`loading-overlay`},_hoisted_3$60={class:`header`},_hoisted_4$47={class:`main-view-content`},_hoisted_5$39={class:`menu-container`},MENU_ITEMS$2=[{label:`Paint`,value:`paint`,icon:icons.colorPalette},{label:`Decals`,value:`decals`,icon:icons.decal},{label:`Settings`,value:`settings`,icon:icons.gearTuningOutline}],blockedEvents=[`tab_l`,`tab_r`],_sfc_main$89={__name:`LiveryMainNew`,setup(__props){let infobar=useInfoBar(),uiNavBlocker=useUINavBlocker(),store$1=useLiveryMainStore(),headerStore=useEditorHeaderStore();useUINavScope(`livery-main-scope`);function onMenuItemClicked(item){switch(item){case`paint`:window.bngVue.gotoGameState(`LiveryPaint`);break;case`decals`:window.bngVue.gotoGameState(`LiveryDecals`);break;case`settings`:window.bngVue.gotoGameState(`LiverySettings`);break}}let openedDialog=ref(null);onBeforeMount(async()=>{await store$1.setup(),headerStore.setHeader(`Livery Editor`),headerStore.setPreheader(null)}),onMounted(()=>{infobar.visible=!0,infobar.showSysInfo=!0,uiNavBlocker.blockOnly(blockedEvents)}),onUnmounted(()=>{uiNavBlocker.clear()});function exit(){store$1.exit().then(()=>{window.bngVue.gotoGameState(`garagemode`)})}function promptSave(){openedDialog.value||(openedDialog.value=`save`,openPrompt(`Enter save name`,`Save`,{buttons:[{label:`Save`,value:text=>({value:1,text}),extras:{default:!0}},{label:`Save and Exit`,value:text=>({value:-1,text}),extras:{accent:ACCENTS.secondary}},{label:`Cancel`,value:text=>({value:0,text}),extras:{cancel:!0,accent:ACCENTS.attention}}],defaultValue:store$1.currentSave.name}).then(res=>{let{value,text}=res;value!==0&&(store$1.currentSave.name=text,store$1.save().then(()=>{value===-1&&openProgress(`Saving and exporting skin...`,`Save`,{cancellable:!1,indeterminate:!0,timeout:1}).promise.then(()=>exit())}),openedDialog.value=null)}))}function promptBack(event){if(openedDialog.value){event.stopPropagation();return}openedDialog.value=`back`,openConfirmation(`Save`,`Save your changes`,[{label:`Save`,value:1,extras:{default:!0}},{label:`Exit (discard changes)`,value:-1,extras:{accent:ACCENTS.attention}},{label:`Cancel`,value:0,extras:{cancel:!0,accent:ACCENTS.secondary}}]).then(res=>{openedDialog.value=null,res===1?promptSave():res===-1&&exit()}),event.stopPropagation()}return(_ctx,_cache)=>withDirectives((openBlock(),createElementBlock(`div`,_hoisted_1$81,[unref(store$1).isSetupDone?createCommentVNode(``,!0):(openBlock(),createElementBlock(`div`,_hoisted_2$69,[..._cache[0]||=[createBaseVNode(`h1`,{class:`text`},`Loading...`,-1)]])),createBaseVNode(`div`,_hoisted_3$60,[createVNode(unref(LiveryEditorHeader_default))]),createBaseVNode(`div`,_hoisted_4$47,[createBaseVNode(`div`,_hoisted_5$39,[(openBlock(),createElementBlock(Fragment,null,renderList(MENU_ITEMS$2,(item,index)=>withDirectives(createVNode(unref(bngImageTile_default),{"bng-nav-item":``,key:item.value,label:item.label,icon:item.icon,onClick:$event=>onMenuItemClicked(item.value)},null,8,[`label`,`icon`,`onClick`]),[[unref(BngBlur_default)],[unref(BngUiNavFocus_default),MENU_ITEMS$2.length-index]])),64))])])])),[[unref(BngOnUiNav_default),promptBack,`menu`],[unref(BngOnUiNav_default),promptBack,`back`],[unref(BngUiNavLabel_default),`Save/Exit`,`menu,back`]])}},LiveryMainNew_default=__plugin_vue_export_helper_default(_sfc_main$89,[[`__scopeId`,`data-v-a9fbf094`]]),_hoisted_1$80={class:`save-info-container`},_hoisted_2$68={class:`file-name`},_hoisted_3$59={class:`file-modified`},_hoisted_4$46={class:`file-size`},_hoisted_5$38={key:0,class:`save-file-actions`},_sfc_main$88=Object.assign({width:14,height:6,margin:.25},{__name:`FileListItem`,props:{name:{type:String,required:!0},location:{type:String,required:!0},modifiedFormatted:String,fileSizeFormatted:String,selected:Boolean},setup(__props){let store$1=useLiveryFileStore(),mainStore=useLiveryMainStore(),props=__props,activated=ref(!1),openedDialog=ref(null);function load(){mainStore.load(props),window.bngVue.gotoGameState(`LiveryMain`)}function rename(){let model={name:props.name};nextTick(()=>{openedDialog.value=`rename`}),openFormDialog(FileEditForm_default,model,model$1=>model$1.name!==null&&model$1.name!==void 0&&model$1.name!==``,`Rename file`,`Enter new name`).then(res=>{res.value&&store$1.renameFile(props,res.formData.name),forceActivateScope()})}function deleteSave(){openConfirmation(`Delete`,`Are you sure you want to delete ${props.name}`).then(res=>{res?store$1.deleteFile(props):forceActivateScope()})}function onActivate$1(activate){activated.value=activate,nextTick(()=>{activate&&openedDialog.value&&(openedDialog.value=null)})}function forceActivateScope(){nextTick(()=>{activated.value=!0})}return(_ctx,_cache)=>withDirectives((openBlock(),createElementBlock(`div`,{class:`file-list-item`,onActivate:_cache[0]||=$event=>onActivate$1(!0),onDeactivate:_cache[1]||=$event=>onActivate$1(!1)},[createBaseVNode(`div`,_hoisted_1$80,[createBaseVNode(`div`,_hoisted_2$68,toDisplayString(__props.name),1),createBaseVNode(`div`,_hoisted_3$59,toDisplayString(__props.modifiedFormatted),1),createBaseVNode(`div`,_hoisted_4$46,toDisplayString(__props.fileSizeFormatted),1)]),__props.selected?(openBlock(),createElementBlock(`div`,_hoisted_5$38,[createVNode(unref(bngButton_default),{icon:unref(icons).import,onClick:load},null,8,[`icon`]),createVNode(unref(bngButton_default),{icon:unref(icons).rename,accent:unref(ACCENTS).secondary,onClick:rename},null,8,[`icon`,`accent`]),createVNode(unref(bngButton_default),{icon:unref(icons).trashBin2,accent:unref(ACCENTS).attention,onClick:deleteSave},null,8,[`icon`,`accent`])])):createCommentVNode(``,!0)],32)),[[unref(BngScopedNav_default),{activated:activated.value}]])}}),FileListItem_default=__plugin_vue_export_helper_default(_sfc_main$88,[[`__scopeId`,`data-v-46a472ab`]]),_hoisted_1$79={class:`livery-manager-view`,"bng-ui-scope":`livery-manager-scope`},_hoisted_2$67={class:`header`},_hoisted_3$58={class:`main-view-content`},_hoisted_4$45={key:1,class:`empty-save-container`},_hoisted_5$37={class:`empty-save-message`},_hoisted_6$28={key:1,class:`menu-container`},_sfc_main$87={__name:`LiveryManager`,setup(__props){let store$1=useLiveryFileStore(),mainStore=useLiveryMainStore(),headerStore=useEditorHeaderStore(),infobar=useInfoBar(),uiNavBlocker=useUINavBlocker();useUINavScope(`livery-manager-scope`);let{files}=storeToRefs(store$1),selectedSave=ref(null),screenState=reactive({isOpenLiveries:!1}),MENU_ITEMS$4=[{label:`New Livery`,value:`new`,icon:icons.plus,action:onCreateNew},{label:`Open Liveries`,value:`load`,icon:icons.decal,action:onOpenLiveries}];watch(()=>files.value,()=>selectedSave.value=null,{deep:!0}),onBeforeMount(()=>{store$1.init()}),onMounted(()=>{headerStore.setHeader(`Livery Editor`),headerStore.setPreheader(null),uiNavBlocker.blockOnly([`tab_l`,`tab_r`]),infobar.visible=!0}),onUnmounted(()=>{uiNavBlocker.clear()});function onCreateNew(){mainStore.isSetupDone=!1,window.bngVue.gotoGameState(`LiveryMain`)}function onOpenLiveries(){screenState.isOpenLiveries=!0,headerStore.setPreheader(`Liveries`)}function goBack(event){screenState.isOpenLiveries?(screenState.isOpenLiveries=!1,selectedSave.value=null):window.bngVue.gotoGameState(`garagemode`),event.stopPropagation()}return(_ctx,_cache)=>withDirectives((openBlock(),createElementBlock(`div`,_hoisted_1$79,[createBaseVNode(`div`,_hoisted_2$67,[createVNode(unref(LiveryEditorHeader_default))]),createBaseVNode(`div`,_hoisted_3$58,[screenState.isOpenLiveries?(openBlock(),createElementBlock(Fragment,{key:0},[unref(files)&&unref(files).length>0?withDirectives((openBlock(),createBlock(unref(bngList_default),{key:0,layout:unref(LIST_LAYOUTS).LIST,"target-width":14,"target-height":6,"target-margin":.25,big:!0,class:`files-list`},{default:withCtx(()=>[(openBlock(!0),createElementBlock(Fragment,null,renderList(unref(files),(file$1,index)=>withDirectives((openBlock(),createBlock(FileListItem_default,mergeProps({ref_for:!0},file$1,{key:file$1.name,selected:selectedSave.value===index,onFocus:$event=>selectedSave.value=index,onClick:$event=>selectedSave.value=index}),null,16,[`selected`,`onFocus`,`onClick`])),[[unref(BngFocusIf_default),selectedSave.value===null&&index===0]])),128))]),_:1},8,[`layout`])),[[unref(BngBlur_default)]]):(openBlock(),createElementBlock(`div`,_hoisted_4$45,[withDirectives((openBlock(),createElementBlock(`div`,_hoisted_5$37,[..._cache[0]||=[createTextVNode(`No saved liveries`,-1)]])),[[unref(BngBlur_default)]])]))],64)):(openBlock(),createElementBlock(`div`,_hoisted_6$28,[(openBlock(),createElementBlock(Fragment,null,renderList(MENU_ITEMS$4,(item,index)=>withDirectives(createVNode(unref(bngImageTile_default),{key:item.value,label:item.label,icon:item.icon,onClick:item.action},null,8,[`label`,`icon`,`onClick`]),[[unref(BngUiNavFocus_default),MENU_ITEMS$4.length-index],[unref(BngBlur_default)]])),64))]))])])),[[unref(BngOnUiNav_default),goBack,`back,menu`],[unref(BngUiNavLabel_default),`Back`,`back,menu`]])}},LiveryManager_default=__plugin_vue_export_helper_default(_sfc_main$87,[[`__scopeId`,`data-v-8e7dbe60`]]),_hoisted_1$78={class:`material-settings-content`},_hoisted_2$66={class:`color-values-container`,"bng-no-child-nav":``},_sfc_main$86={__name:`MaterialSettings`,props:{initialColor:Array},emits:[`change`],setup(__props,{emit:__emit}){let props=__props,emit$1=__emit,paint=new Paint,color=ref({hue:.5,saturation:1,luminosity:.5}),inputHue=computed({get:()=>color.value.hue.toFixed(3),set:newValue=>{color.value.hue=typeof newValue==`string`?+newValue:newValue,notifyListeners()}}),inputSat=computed({get:()=>color.value.saturation.toFixed(3),set:newValue=>{color.value.saturation=typeof newValue==`string`?+newValue:newValue,notifyListeners()}}),inputLum=computed({get:()=>color.value.luminosity.toFixed(3),set:newValue=>{color.value.luminosity=typeof newValue==`string`?+newValue:newValue,notifyListeners()}}),isPreciseActive=ref(!1),colorPickerStep=computed(()=>isPreciseActive.value?.001:.01);watch(()=>props.initialColor,()=>{props.initialColor&&(paint.rgba=props.initialColor,color.value.hue=paint.hsl[0],color.value.saturation=paint.hsl[1],color.value.luminosity=paint.hsl[2])},{deep:!0,immediate:!0});function notifyListeners(){let hsl=[color.value.hue,color.value.saturation,color.value.luminosity];paint.hsl=hsl,emit$1(`change`,{colorHsl:hsl,colorRgb:paint.rgb})}function handleAction2(element){isPreciseActive.value=element.detail.value===1}return(_ctx,_cache)=>withDirectives((openBlock(),createBlock(unref(LayerSettingsBase_default),{class:`material-settings`},{heading:withCtx(()=>[..._cache[4]||=[createTextVNode(`Color`,-1)]]),default:withCtx(()=>[createBaseVNode(`div`,_hoisted_1$78,[createVNode(unref(bngColorPicker_default),{modelValue:color.value,"onUpdate:modelValue":_cache[0]||=$event=>color.value=$event,step:colorPickerStep.value,onChange:notifyListeners},null,8,[`modelValue`,`step`]),createBaseVNode(`div`,_hoisted_2$66,[createVNode(unref(bngInput_default),{prefix:`h`,modelValue:inputHue.value,"onUpdate:modelValue":_cache[1]||=$event=>inputHue.value=$event},null,8,[`modelValue`]),createVNode(unref(bngInput_default),{prefix:`s`,modelValue:inputSat.value,"onUpdate:modelValue":_cache[2]||=$event=>inputSat.value=$event},null,8,[`modelValue`]),createVNode(unref(bngInput_default),{prefix:`b`,modelValue:inputLum.value,"onUpdate:modelValue":_cache[3]||=$event=>inputLum.value=$event},null,8,[`modelValue`])])])]),_:1})),[[unref(BngUiNavLabel_default),`[Hold] Precise`,`action_2`],[unref(BngOnUiNav_default),handleAction2,`action_2`,{up:!0}],[unref(BngOnUiNav_default),handleAction2,`action_2`,{down:!0}]])}},MaterialSettings_default=__plugin_vue_export_helper_default(_sfc_main$86,[[`__scopeId`,`data-v-45b64f6e`]]),_hoisted_1$77={class:`paint-main-view`,"bng-ui-scope":`paint-main-scope`},_hoisted_2$65={class:`header`},_hoisted_3$57={class:`paint-content-container`},_hoisted_4$44={class:`paint-content`},_sfc_main$85={__name:`LiveryPaintMain`,setup(__props){let store$1=useLiveryMainStore(),headerStore=useEditorHeaderStore(),infobar=useInfoBar(),uiNavBlocker=useUINavBlocker(),{events:events$3}=useBridge();useUINavScope(`paint-main-scope`);let initialColor=ref(null),blockedEvents$1=[`tab_r`,`tab_l`];onMounted(()=>{headerStore.setPreheader([`Paint`]),store$1.setup(),infobar.visible=!0,infobar.showSysInfo=!0,uiNavBlocker.blockOnly(blockedEvents$1),events$3.on(`liveryEditor_fill_layerData`,onLayerData),Lua_default.extensions.ui_liveryEditor_layers_fill.requestLayerData()}),onUnmounted(()=>{uiNavBlocker.clear(),events$3.off(`liveryEditor_fill_layerData`)});function onLayerData(data){console.log(`layer data changed`,data),initialColor.value=data.color}function saveChanges(){Lua_default.extensions.ui_liveryEditor_layers_fill.saveChanges().then(()=>{window.bngVue.gotoGameState(`LiveryMain`)})}function restoreDefault(){Lua_default.extensions.ui_liveryEditor_layers_fill.restoreDefault()}function cancelChanges(){openConfirmation(`Undo Changes`,`Lose unsaved changes?`).then(res=>{res&&(Lua_default.extensions.ui_liveryEditor_layers_fill.restoreLayer(),window.bngVue.gotoGameState(`LiveryMain`))})}function onMaterialValueChanged(data){Lua_default.extensions.ui_liveryEditor_layers_fill.updateLayer({color:data.colorRgb})}return(_ctx,_cache)=>withDirectives((openBlock(),createElementBlock(`div`,_hoisted_1$77,[createBaseVNode(`div`,_hoisted_2$65,[createVNode(unref(LiveryEditorHeader_default))]),createBaseVNode(`div`,_hoisted_3$57,[createBaseVNode(`div`,_hoisted_4$44,[withDirectives(createVNode(MaterialSettings_default,{"initial-color":initialColor.value,onChange:onMaterialValueChanged},null,8,[`initial-color`]),[[unref(BngBlur_default)]]),withDirectives((openBlock(),createBlock(unref(bngButton_default),{onClick:saveChanges},{default:withCtx(()=>[createVNode(unref(bngBinding_default),{controller:``,"ui-event":`context`}),_cache[0]||=createBaseVNode(`span`,null,`Apply`,-1)]),_:1})),[[unref(BngOnUiNav_default),void 0,`context`,{asMouse:!0}]]),withDirectives((openBlock(),createBlock(unref(bngButton_default),{accent:`secondary`,onClick:restoreDefault},{default:withCtx(()=>[createVNode(unref(bngBinding_default),{controller:``,"ui-event":`action_3`}),_cache[1]||=createBaseVNode(`span`,null,`Restore Default`,-1)]),_:1})),[[unref(BngOnUiNav_default),void 0,`action_3`,{asMouse:!0}]])])])])),[[unref(BngOnUiNav_default),cancelChanges,`back,menu`],[unref(BngUiNavLabel_default),`Back`,`back,menu`]])}},LiveryPaintMain_default=__plugin_vue_export_helper_default(_sfc_main$85,[[`__scopeId`,`data-v-74e232cb`]]),_hoisted_1$76={class:`layer-inspector-base`},_hoisted_2$64={class:`inspector-heading`},_hoisted_3$56={class:`inspector-content`},_sfc_main$84={__name:`LayerInspectorBase`,props:{heading:{type:String}},setup(__props){return useSlots(),(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$76,[createBaseVNode(`div`,_hoisted_2$64,[createVNode(unref(bngCardHeading_default),{type:`ribbon`},{default:withCtx(()=>[renderSlot(_ctx.$slots,`heading`,{},()=>[createBaseVNode(`span`,null,toDisplayString(__props.heading),1)],!0)]),_:3})]),createBaseVNode(`div`,_hoisted_3$56,[renderSlot(_ctx.$slots,`default`,{},void 0,!0)])]))}},LayerInspectorBase_default=__plugin_vue_export_helper_default(_sfc_main$84,[[`__scopeId`,`data-v-c60f30a4`]]),_hoisted_1$75={class:`direction-buttons-row`},_hoisted_2$63={class:`icon-binding-wrapper`},_hoisted_3$55={class:`icon-binding-wrapper`},_hoisted_4$43={class:`direction-buttons-row`},_hoisted_5$36={class:`icon-binding-wrapper`},_hoisted_6$27={class:`stacked-arrows`},_hoisted_7$24={class:`icon-binding-wrapper`},_hoisted_8$19={class:`stacked-arrows`},_hoisted_9$17={class:`dropdown-container`},_sfc_main$83={__name:`LayerOrder`,setup(__props){let ORDER_TOOL$1=Lua_default.extensions.ui_liveryEditor_tools_group,store$1=useLiveryEditorStore(),_order=ref(2),order=computed({get:()=>_order.value,set(newValue){_order.value=newValue,ORDER_TOOL$1.setOrder(newValue)}});computed(()=>store$1.selectedLayers[0].siblingCount);let orderOptions=computed(()=>Array.from({length:store$1.layers.length-1},(_,i)=>({label:`${i+1}`,value:i+2})));onMounted(()=>{store$1.selectedLayers&&store$1.selectedLayers.length>0&&(_order.value=store$1.selectedLayers[0].order)});let moveUp=()=>{ORDER_TOOL$1.moveOrderUp().then(value=>_order.value=value)},moveDown=()=>{ORDER_TOOL$1.moveOrderDown().then(value=>_order.value=value)},moveToTop=()=>{ORDER_TOOL$1.changeOrderToTop().then(value=>_order.value=value)},moveToBottom=()=>{ORDER_TOOL$1.changeOrderToBottom().then(value=>_order.value=value)};return(_ctx,_cache)=>withDirectives((openBlock(),createBlock(LayerInspectorBase_default,{heading:`Order`},{default:withCtx(()=>[createBaseVNode(`div`,_hoisted_1$75,[withDirectives((openBlock(),createBlock(unref(bngTile_default),{"bng-nav-item":``,label:`Move Up`,onClick:moveUp},{default:withCtx(()=>[createBaseVNode(`div`,_hoisted_2$63,[createVNode(unref(bngIcon_default),{type:unref(icons).arrowLargeUp},null,8,[`type`])])]),_:1})),[[unref(BngOnUiNav_default),moveUp,`ok`,{focusRequired:!0}]]),withDirectives((openBlock(),createBlock(unref(bngTile_default),{"bng-nav-item":``,label:`Move Down`,onClick:moveDown},{default:withCtx(()=>[createBaseVNode(`div`,_hoisted_3$55,[createVNode(unref(bngIcon_default),{type:unref(icons).arrowLargeDown},null,8,[`type`])])]),_:1})),[[unref(BngOnUiNav_default),moveDown,`ok`,{focusRequired:!0}]])]),createBaseVNode(`div`,_hoisted_4$43,[withDirectives((openBlock(),createBlock(unref(bngTile_default),{"bng-nav-item":``,label:`Move to Top`,onClick:moveToTop},{default:withCtx(()=>[createBaseVNode(`div`,_hoisted_5$36,[createBaseVNode(`div`,_hoisted_6$27,[createVNode(unref(bngIcon_default),{type:unref(icons).arrowLargeUp},null,8,[`type`]),createVNode(unref(bngIcon_default),{type:unref(icons).arrowLargeUp},null,8,[`type`])])])]),_:1})),[[unref(BngOnUiNav_default),moveToTop,`ok`,{focusRequired:!0}]]),withDirectives((openBlock(),createBlock(unref(bngTile_default),{"bng-nav-item":``,label:`Move to Bottom`,onClick:moveToBottom},{default:withCtx(()=>[createBaseVNode(`div`,_hoisted_7$24,[createBaseVNode(`div`,_hoisted_8$19,[createVNode(unref(bngIcon_default),{type:unref(icons).arrowLargeDown,disabled:unref(store$1).selectedLayers.length>1},null,8,[`type`,`disabled`]),createVNode(unref(bngIcon_default),{type:unref(icons).arrowLargeDown,disabled:unref(store$1).selectedLayers.length>1},null,8,[`type`,`disabled`])])])]),_:1})),[[unref(BngOnUiNav_default),moveToBottom,`ok`,{focusRequired:!0}]])]),createBaseVNode(`div`,_hoisted_9$17,[createVNode(unref(bngDropdown_default),{modelValue:order.value,"onUpdate:modelValue":_cache[0]||=$event=>order.value=$event,items:orderOptions.value},null,8,[`modelValue`,`items`])])]),_:1})),[[unref(BngBlur_default)]])}},LayerOrder_default=__plugin_vue_export_helper_default(_sfc_main$83,[[`__scopeId`,`data-v-d8fda3d9`]]),_hoisted_1$74={class:`decals-main-view`,"bng-ui-scope":`decals-main-scope`},_hoisted_2$62={class:`header`},_hoisted_3$54={class:`main-view-content`},_hoisted_4$42={class:`add-content-wrapper`},_hoisted_5$35={class:`action-tile`},_hoisted_6$26={key:1,class:`popup-settings`},CAMERA_BUTTONS$1=[{label:`Right`,icon:icons.cameraSideRight,value:`right`},{label:`Front`,icon:icons.cameraFront1,value:`front`},{label:`Left`,icon:icons.cameraSideLeft,value:`left`},{label:`Back`,icon:icons.cameraBack1,value:`back`},{label:`Top Right`,icon:icons.cameraTop1,value:`topright`},{label:`Top Left`,icon:icons.cameraTop1,value:`topleft`},{label:`Top Front`,icon:icons.cameraTop1,value:`topfront`},{label:`Top Back`,icon:icons.cameraTop1,value:`topback`}],BLOCKED_UINAV_EVENTS$1=[`tab_l`,`tab_r`],SHOW_HIDE_DECAL_EVENT=`action_2`,_sfc_main$82={__name:`LiveryDecalsMain`,setup(__props){let ACTION_ITEM_ICON={requestReproject:icons.view,transform:icons.transform,materials:icons.colorPalette,highlight:icons.lightGarageG11,requestMirror:icons.reflect,order:icons.sortAscDown,enabled:icons.eyeOutlineOpened,"enabled-off":icons.eyeOutlineClosed,delete:icons.trashBin1,duplicate:icons.copy},layerActionsState=reactive({mirrored:!1,mirrorFlipped:!1,highlight:!0,enabled:!0}),MIRROR_ITEMS=[{label:`Mirror`,value:`mirror`,isSwitch:!0,switchValue:toRef(layerActionsState,`mirrored`)},{label:`Flip Mirrored`,value:`flipMirrored`,isSwitch:!0,switchValue:toRef(layerActionsState,`mirrorFlipped`),disabled:computed(()=>!layerActionsState.mirrored)}],headerStore=useEditorHeaderStore(),infobar=useInfoBar();useUINavScope(`decals-main-scope`);let uiNavBlocker=useUINavBlocker(),{events:events$3}=useBridge(),layers$1=ref([]),selectedLayers=ref([]),layerActions=ref([]),allowActionsDrawerShow=ref(!0),actionDrawer=ref(null),currentActionDrawerLevel=ref(null),popupSettings=ref(null),isReprojectActive=ref(!1),focusedLayer=ref(null),selectedLayerKeys=computed(()=>selectedLayers.value?selectedLayers.value.map(x=>x.uid):null),actionsDrawerData=computed(()=>{let layerName=selectedLayers.value&&selectedLayers.value.length>0?selectedLayers.value[0].name:null;return layerActions.value&&layerActions.value.length>0?{label:layerName,items:layerActions.value,allowOpenDrawer:!1}:void 0}),contextUIEventLabel=computed(()=>isReprojectActive.value?`Reproject`:`Add Decal`),action2UIEventLabel=computed(()=>focusedLayer.value||selectedLayers.value&&selectedLayers.value.length>0?`Enable/Disable Decal`:void 0);watchEffect(()=>{let eventsToBlock=[...BLOCKED_UINAV_EVENTS$1];uiNavBlocker.clear(),(isReprojectActive.value||!focusedLayer.value&&(!selectedLayers.value||selectedLayers.value.length===0))&&eventsToBlock.push(SHOW_HIDE_DECAL_EVENT),uiNavBlocker.blockOnly(eventsToBlock)}),onBeforeMount(()=>{headerStore.setPreheader([`Decals`])}),onMounted(()=>{infobar.visible=!0,infobar.showSysInfo=!0,events$3.on(`liveryEditor_OnLayersUpdated`,onLayersUpdated),events$3.on(`liveryEditor_selection_actionsUpdated`,onActionsUpdated),events$3.on(`liveryEditor_selection_selectedChanged`,onSelectedChanged),Lua_default.extensions.ui_liveryEditor_layers.requestInitialData(),Lua_default.extensions.ui_liveryEditor_selection.requestInitialData()}),onBeforeUnmount(()=>{events$3.off(`liveryEditor_OnLayersUpdated`,onLayersUpdated),events$3.off(`liveryEditor_selection_actionsUpdated`,onActionsUpdated),events$3.off(`liveryEditor_selection_selectedChanged`,onSelectedChanged)});function onBack(event){popupSettings.value?(popupSettings.value=null,allowActionsDrawerShow.value=!0):actionsDrawerData.value?handleDrawerBack():window.bngVue.gotoGameState(`LiveryMain`),event.stopPropagation()}function addDecal(){window.bngVue.gotoGameState(`LiveryDecalSelector`)}let isReproject;async function onActionSwitchClicked(item){item.switchValue=await Lua_default.extensions.ui_liveryEditor_layerAction.performAction(item.value)}async function onActionTriggered(item){if(!item.value){currentActionDrawerLevel.value===`requestReproject`&&!isReproject&&await Lua_default.extensions.ui_liveryEditor_layerAction.performAction(`cancelReproject`),isReprojectActive.value=!1,isReproject=!1,currentActionDrawerLevel.value=null;return}if((item.lazyLoadItems||item.items)&&(currentActionDrawerLevel.value=item.value),item.value===`requestReproject`){if(!item.items){let timeoutid=setTimeout(()=>{item.items=CAMERA_BUTTONS$1,clearTimeout(timeoutid)},500)}isReprojectActive.value=!0}else if(item.value===`requestMirror`){item.items=MIRROR_ITEMS;return}else if(item.value===`order`){allowActionsDrawerShow.value=!1,popupSettings.value=markRaw(LayerOrder_default);return}else if(CAMERA_BUTTONS$1.find(x=>x.value===item.value)){await Lua_default.extensions.ui_liveryEditor_camera.setOrthographicView(item.value);return}await Lua_default.extensions.ui_liveryEditor_layerAction.performAction(item.value)}function onLayersUpdated(data){layers$1.value=data}function onActionsUpdated(data){if(layerActions.value=data,data&&Array.isArray(data)&&data.length>0){let highlightAction=layerActions.value.find(x=>x.value===`highlight`);highlightAction.switchValue=toRef(layerActionsState,`highlight`)}}function onSelectedChanged(data){if(selectedLayers.value=data,data&&Array.isArray(data)&&data.length>0){let first=data[0];layerActionsState.highlight=first.highlighted,layerActionsState.mirrored=first.mirrored,layerActionsState.mirrorFlipped=first.mirrorFlipped}}let closeActionDrawer=()=>{currentActionDrawerLevel.value&¤tActionDrawerLevel.value===`requestReproject`&&(Lua_default.extensions.ui_liveryEditor_layerAction.performAction(`cancelReproject`).then(()=>{}),currentActionDrawerLevel.value=null),Lua_default.extensions.ui_liveryEditor_selection.clearSelection()};function handleDrawerBack(){currentActionDrawerLevel.value?actionDrawer.value.goBack():closeActionDrawer()}function onFocusedLayer(layer){focusedLayer.value=layer}let toggleEnabled=()=>{if(focusedLayer.value)Lua_default.extensions.ui_liveryEditor_layerAction.toggleEnabledByLayerUid(focusedLayer.value.uid);else if(selectedLayers.value&&selectedLayers.value.length>0){let layer=selectedLayers.value[0];Lua_default.extensions.ui_liveryEditor_layerAction.performAction(`enabled`).then(luaRes=>{layer.enabled=luaRes})}},handleContext=()=>{isReprojectActive.value?Lua_default.extensions.ui_liveryEditor_layerAction.performAction(`reproject`).then(()=>{isReproject=!0,isReprojectActive.value=!1,actionDrawer.value.goBack()}):popupSettings.value||addDecal()},handleAction2=()=>{if(isReprojectActive.value)return!1;toggleEnabled()};return(_ctx,_cache)=>withDirectives((openBlock(),createElementBlock(`div`,_hoisted_1$74,[createBaseVNode(`div`,_hoisted_2$62,[createVNode(unref(LiveryEditorHeader_default))]),createBaseVNode(`div`,_hoisted_3$54,[withDirectives((openBlock(),createBlock(unref(LayersManager_default),{selectedKeys:selectedLayerKeys.value,"onUpdate:selectedKeys":_cache[0]||=$event=>selectedLayerKeys.value=$event,layers:layers$1.value,class:`layers-manager`,onFocusedLayer},{header:withCtx(()=>[createVNode(unref(bngCardHeading_default),{type:`ribbon`},{default:withCtx(()=>[..._cache[1]||=[createTextVNode(`Layers`,-1)]]),_:1}),withDirectives((openBlock(),createBlock(unref(bngButton_default),{"bng-no-nav":`true`,accent:unref(ACCENTS).outlined,onClick:addDecal},{default:withCtx(()=>[createBaseVNode(`span`,_hoisted_4$42,[createVNode(unref(bngBinding_default),{trackIgnore:!0,uiEvent:`context`,deviceMask:`xinput`}),_cache[2]||=createBaseVNode(`span`,{class:`add-label`},`Add Decal`,-1)])]),_:1},8,[`accent`])),[[unref(BngDisabled_default),isReprojectActive.value]])]),_:1},8,[`selectedKeys`,`layers`])),[[unref(BngBlur_default)]]),actionsDrawerData.value&&allowActionsDrawerShow.value?(openBlock(),createBlock(unref(bngActionDrawer_default),{key:0,ref_key:`actionDrawer`,ref:actionDrawer,blur:``,alwaysShowBack:!1,actions:actionsDrawerData.value,"item-width":10,"item-margin":1,class:`actions-drawer`,onSelect:onActionTriggered},{controls:withCtx(()=>[withDirectives(createVNode(unref(bngButton_default),{accent:unref(ACCENTS).outlined,icon:unref(icons).exit,onClick:closeActionDrawer},null,8,[`accent`,`icon`]),[[unref(BngOnUiNav_default),void 0,`ok`,{asMouse:!0,focusRequired:!0}]])]),action:withCtx(({item,select,order})=>[createBaseVNode(`div`,_hoisted_5$35,[item.isSwitch?withDirectives((openBlock(),createBlock(unref(bngTile_default),{key:0,"bng-nav-item":``,label:item.label,onClick:$event=>onActionSwitchClicked(item)},{default:withCtx(()=>[createVNode(unref(bngSwitch_default),{modelValue:item.switchValue,"onUpdate:modelValue":$event=>item.switchValue=$event},null,8,[`modelValue`,`onUpdate:modelValue`])]),_:2},1032,[`label`,`onClick`])),[[unref(BngUiNavFocus_default),order===0?0:void 0],[unref(BngFocusIf_default),order===0],[unref(BngDisabled_default),item.disabled],[unref(BngOnUiNav_default),void 0,`ok`,{asMouse:!0,focusRequired:!0}]]):withDirectives((openBlock(),createBlock(unref(bngImageTile_default),{key:1,"bng-nav-item":``,label:item.label,icon:item.icon?item.icon:ACTION_ITEM_ICON[item.value],class:`action-tile`,onClick:$event=>select(item)},null,8,[`label`,`icon`,`onClick`])),[[unref(BngUiNavFocus_default),order===0?0:void 0],[unref(BngFocusIf_default),order===0],[unref(BngOnUiNav_default),void 0,`ok`,{asMouse:!0,focusRequired:!0}]])])]),_:1},8,[`actions`])):createCommentVNode(``,!0),popupSettings.value?(openBlock(),createElementBlock(`div`,_hoisted_6$26,[(openBlock(),createBlock(resolveDynamicComponent(popupSettings.value)))])):createCommentVNode(``,!0)])])),[[unref(BngUiNavLabel_default),contextUIEventLabel.value,`context`],[unref(BngUiNavLabel_default),action2UIEventLabel.value,`action_2`],[unref(BngUiNavLabel_default),`Back`,`menu,back`],[unref(BngOnUiNav_default),onBack,`menu,back`],[unref(BngOnUiNav_default),handleContext,`context`],[unref(BngOnUiNav_default),handleAction2,`action_2`]])}},LiveryDecalsMain_default=__plugin_vue_export_helper_default(_sfc_main$82,[[`__scopeId`,`data-v-b9d45c3c`]]),_hoisted_1$73={class:`decal-selector-view`,"bng-ui-scope":`decal-selector-scope`},_hoisted_2$61={class:`header`},_hoisted_3$53={class:`main-view-content`},_hoisted_4$41={key:0,class:`side-menu`},_hoisted_5$34={class:`list-container`},BLOCKED_UINAV_EVENTS=[`tab_l`,`tab_r`],_sfc_main$81={__name:`LiveryDecalSelector`,setup(__props){let headerStore=useEditorHeaderStore(),infobar=useInfoBar(),uiNavBlocker=useUINavBlocker(),{events:events$3}=useBridge();useUINavScope(`decal-selector-scope`);let categorizedTextures=ref([]),selectedCategory=ref(null),textures=computed(()=>{if(categorizedTextures.value&&categorizedTextures.value.length>0&&selectedCategory.value){let cat=categorizedTextures.value.find(x=>x.value===selectedCategory.value);if(cat)return cat.items}return null});async function select(item){let layer=await Lua_default.extensions.ui_liveryEditor_layers_decal.addLayerCentered({texturePath:item.preview});await Lua_default.extensions.ui_liveryEditor_selection.select(layer.uid,!0),window.bngVue.gotoGameState(`LiveryDecals`)}function goBack(event){window.bngVue.gotoGameState(`LiveryDecals`),event.stopPropagation()}function onData(data){categorizedTextures.value=data,!data||data.length===0?selectedCategory.value=null:selectedCategory.value||=data[0].value}return onBeforeMount(()=>{headerStore.setPreheader([`Decals`,`Textures`])}),onMounted(()=>{infobar.visible=!0,infobar.showSysInfo=!0,Lua_default.extensions.ui_liveryEditor_resources.requestData(),events$3.on(`liveryEditor_resources_data`,onData),uiNavBlocker.blockOnly(BLOCKED_UINAV_EVENTS)}),onBeforeMount(()=>{events$3.off(`liveryEditor_resources_data`,onData),uiNavBlocker.clear()}),(_ctx,_cache)=>withDirectives((openBlock(),createElementBlock(`div`,_hoisted_1$73,[createBaseVNode(`div`,_hoisted_2$61,[createVNode(unref(LiveryEditorHeader_default))]),createBaseVNode(`div`,_hoisted_3$53,[categorizedTextures.value?withDirectives((openBlock(),createElementBlock(`div`,_hoisted_4$41,[(openBlock(!0),createElementBlock(Fragment,null,renderList(categorizedTextures.value,category=>(openBlock(),createBlock(unref(bngButton_default),{key:category.value,label:category.label,accent:`text`,onClick:$event=>selectedCategory.value=category.value},null,8,[`label`,`onClick`]))),128))])),[[unref(BngBlur_default)]]):createCommentVNode(``,!0),createBaseVNode(`div`,_hoisted_5$34,[textures.value?withDirectives((openBlock(),createBlock(unref(bngList_default),{key:0,layout:unref(LIST_LAYOUTS).TILES,"target-width":8,"target-height":8,"target-margin":.25,big:!0,class:`textures-list`},{default:withCtx(()=>[(openBlock(!0),createElementBlock(Fragment,null,renderList(textures.value,(item,index)=>withDirectives((openBlock(),createBlock(DecalSelectorItem_default,{"bng-nav-item":``,key:item.preview,externalImage:item.preview,"data-decal-item":index,onClick:$event=>select(item)},null,8,[`externalImage`,`data-decal-item`,`onClick`])),[[unref(BngOnUiNav_default),void 0,`ok`,{asMouse:!0,focusRequired:!0}],[unref(BngUiNavFocus_default),index===0?0:void 0],[unref(BngFocusIf_default),index===0]])),128))]),_:1},8,[`layout`])),[[unref(BngBlur_default)]]):createCommentVNode(``,!0)])])])),[[unref(BngOnUiNav_default),goBack,`back,menu`],[unref(BngUiNavLabel_default),`Back`,`back,menu`]])}},LiveryDecalSelector_default=__plugin_vue_export_helper_default(_sfc_main$81,[[`__scopeId`,`data-v-fc11228e`]]),_hoisted_1$72={class:`layer-edit-view`,"bng-ui-scope":`layer-edit-scope`},_hoisted_2$60={class:`header`},_hoisted_3$52={class:`main-view-content`},_hoisted_4$40={class:`menu-container`},MENU_ITEMS$1=[{label:`Projection`,value:`projection`,icon:icons.decal},{label:`Transform`,value:`transform`,icon:icons.colorPalette},{label:`Materials`,value:`materials`,icon:icons.decal}],noop=()=>{},_sfc_main$80={__name:`LiveryLayerEdit`,setup(__props){useEditorHeaderStore(),useDecalSelectorStore();let mainStore=useLiveryMainStore(),infobar=useInfoBar();useUINavScope(`layer-edit-scope`);function onMenuItemClicked(item){switch(item.value){case`transform`:router_default.push({name:`LayerTransform`});break;case`materials`:router_default.push({name:`LayerMaterials`});break;case`projection`:router_default.push({name:`LayerProjection`});break}}function goBack(){router_default.replace({name:`LiveryDecals`}),mainStore.exitLayerEdit()}function saveChanges(){Lua_default.extensions.ui_liveryEditor_layerEdit.saveChanges(!0).then(()=>goBack())}onBeforeMount(()=>{infobar.clearHints(),infobar.addHints(NAV_HINTS)}),onMounted(async()=>{infobar.visible=!0,infobar.showSysInfo=!0,await mainStore.setupLayerEdit(),await Lua_default.extensions.ui_liveryEditor_layerEdit.showCursorOrLayer(!0)}),onBeforeUnmount(async()=>{await Lua_default.extensions.ui_liveryEditor_layerEdit.showCursorOrLayer(!1)});let NAV_HINTS=[{id:`apply`,content:{type:`binding`,props:{uiEvent:`ok`},label:`Done`},action:saveChanges},{id:`back`,content:{type:`binding`,props:{uiEvent:`back`},label:`Back`},action:goBack}];return(_ctx,_cache)=>withDirectives((openBlock(),createElementBlock(`div`,_hoisted_1$72,[createBaseVNode(`div`,_hoisted_2$60,[createVNode(unref(LiveryEditorHeader_default))]),createBaseVNode(`div`,_hoisted_3$52,[createBaseVNode(`div`,_hoisted_4$40,[(openBlock(),createElementBlock(Fragment,null,renderList(MENU_ITEMS$1,item=>withDirectives(createVNode(unref(bngImageTile_default),{"bng-nav-item":``,key:item.value,label:item.label,icon:item.icon,class:`menu-item`,onClick:$event=>onMenuItemClicked(item)},null,8,[`label`,`icon`,`onClick`]),[[unref(BngBlur_default)]])),64))])])])),[[unref(BngOnUiNav_default),goBack,`back`],[unref(BngOnUiNav_default),saveChanges,`menu`],[unref(BngOnUiNav_default),noop,`rotate_h_cam`],[unref(BngOnUiNav_default),noop,`rotate_v_cam`]])}},LiveryLayerEdit_default=__plugin_vue_export_helper_default(_sfc_main$80,[[`__scopeId`,`data-v-c339e1a6`]]),_hoisted_1$71={class:`camera-settings-view`,"bng-ui-scope":`camera-settings-scope`},_hoisted_2$59={class:`header`},_hoisted_3$51={class:`main-view-content`},_hoisted_4$39={class:`menu-container`},MENU_ITEMS=[{label:`Right`,icon:icons.cameraSideRight,value:`right`},{label:`Front`,icon:icons.cameraFront1,value:`front`},{label:`Left`,icon:icons.cameraSideLeft,value:`left`},{label:`Back`,icon:icons.cameraBack1,value:`back`},{label:`Top Right`,icon:icons.cameraTop1,value:`topright`},{label:`Top Left`,icon:icons.cameraTop1,value:`topleft`},{label:`Top Front`,icon:icons.cameraTop1,value:`topfront`},{label:`Top Back`,icon:icons.cameraTop1,value:`topback`}],_sfc_main$79={__name:`LiveryCameraSettings`,setup(__props){let CAMERA_LUA$1=Lua_default.extensions.ui_liveryEditor_camera,headerStore=useEditorHeaderStore();useDecalSelectorStore();let infobar=useInfoBar();useUINavScope(`camera-settings-scope`);function onMenuItemClicked(item){CAMERA_LUA$1.setOrthographicView(item.value)}function goBack(){router_default.replace({name:`LiveryDecals`})}function done(){router_default.replace({name:`LiveryDecalSelector`})}onBeforeMount(()=>{infobar.clearHints(),infobar.addHints(NAV_HINTS),headerStore.setPreheader([`Select Camera`])}),onMounted(()=>{infobar.visible=!0,infobar.showSysInfo=!0});let NAV_HINTS=[{id:`apply`,content:{type:`binding`,props:{uiEvent:`menu`},label:`Done`}},{id:`back`,content:{type:`binding`,props:{uiEvent:`back`},label:`Back`},action:goBack}];return(_ctx,_cache)=>withDirectives((openBlock(),createElementBlock(`div`,_hoisted_1$71,[createBaseVNode(`div`,_hoisted_2$59,[createVNode(unref(LiveryEditorHeader_default))]),createBaseVNode(`div`,_hoisted_3$51,[createBaseVNode(`div`,_hoisted_4$39,[(openBlock(),createElementBlock(Fragment,null,renderList(MENU_ITEMS,item=>withDirectives(createVNode(unref(bngImageTile_default),{"bng-nav-item":``,key:item.value,label:item.label,icon:item.icon,onClick:$event=>onMenuItemClicked(item)},null,8,[`label`,`icon`,`onClick`]),[[unref(BngBlur_default)]])),64))])])])),[[unref(BngOnUiNav_default),goBack,`back`],[unref(BngOnUiNav_default),done,`menu`]])}},LiveryCameraSettings_default=__plugin_vue_export_helper_default(_sfc_main$79,[[`__scopeId`,`data-v-376ce11c`]]),_hoisted_1$70={class:`layer-transform-view`,"bng-ui-scope":`layer-transform-scope`},_hoisted_2$58={class:`header`},_hoisted_3$50={class:`main-view-content`},_hoisted_4$38={class:`inspector-container`},_hoisted_5$33={class:`transform-setting-item`},_hoisted_6$25={key:0},_hoisted_7$23={key:1,class:`transform-setting-inputs`},_hoisted_8$18={class:`slider-text-container`},_hoisted_9$16={class:`slider-text-container`},_hoisted_10$12={key:2,class:`display-values-container`},_hoisted_11$10={key:1,class:`transform-setting-item`},_hoisted_12$7={key:0,class:`transform-setting-inputs`},_hoisted_13$7={class:`slider-text-container`},_hoisted_14$7={class:`slider-text-container`},_hoisted_15$7={key:1,class:`display-values-container`},_hoisted_16$7={key:3,class:`transform-setting-item`},_hoisted_17$6={key:0,class:`transform-setting-inputs`},_hoisted_18$5={class:`slider-text-container`},_hoisted_19$3={key:1,class:`display-values-container`},_hoisted_20$3={key:5,class:`transform-setting-item`},_hoisted_21$3={key:0,class:`transform-setting-inputs`},_hoisted_22$3={class:`slider-text-container`},_hoisted_23$3={class:`slider-text-container`},_hoisted_24$2={key:1,class:`display-values-container`},_hoisted_25$1={class:`edit-button-label`},INPUT_MIN=0,INPUT_MAX=1,_sfc_main$78={__name:`LayerTransform`,setup(__props){let headerStore=useEditorHeaderStore(),infobar=useInfoBar(),navBlocker=useUINavBlocker(),{events:events$3}=useBridge();useUINavScope(`layer-transform-scope`);let transformState=reactive({positionX:0,positionY:0,scaleX:0,scaleY:0,skewX:0,skewY:0,rotation:0}),isHoldModifier=ref(!1),isPreciseActive=ref(!1),isTabRightActive=ref(!1),stateData=ref(null),isEdit=ref(!1),isReapplying=ref(!1),isRepositionActive=ref(!1),isUseMouse=ref(!1),positionX=computed({get:()=>transformState.positionX,set:newValue=>{let value=assertInt(newValue);transformState.positionX=value,isEdit.value&&Lua_default.extensions.ui_liveryEditor_layerEdit.setPosition(value,transformState.positionY)}}),positionY=computed({get:()=>transformState.positionY,set:newValue=>{let value=assertInt(newValue);transformState.positionY=value,isEdit.value&&Lua_default.extensions.ui_liveryEditor_layerEdit.setPosition(transformState.positionX,value)}}),scaleX=computed({get:()=>transformState.scaleX,set:newValue=>{let value=assertInt(newValue);transformState.scaleX=value,isEdit.value&&Lua_default.extensions.ui_liveryEditor_layerEdit.setScale(value,transformState.scaleY)}}),scaleY=computed({get:()=>transformState.scaleY,set:newValue=>{let value=assertInt(newValue);transformState.scaleY=value,isEdit.value&&Lua_default.extensions.ui_liveryEditor_layerEdit.setScale(transformState.scaleX,value)}}),skewX=computed({get:()=>transformState.skewX,set:newValue=>{let value=assertInt(newValue);transformState.skewX=value,isEdit.value&&Lua_default.extensions.ui_liveryEditor_layerEdit.setSkew(value,transformState.skewY)}}),skewY=computed({get:()=>transformState.skewY,set:newValue=>{let value=assertInt(newValue);transformState.skewY=value,isEdit.value&&Lua_default.extensions.ui_liveryEditor_layerEdit.setSkew(transformState.skewX,value)}}),rotation=computed({get:()=>transformState.rotation,set:newValue=>{let value=assertInt(newValue);transformState.rotation=value,isEdit.value&&Lua_default.extensions.ui_liveryEditor_layerEdit.setRotation(value)}}),hintLabels=computed(()=>{let labels={},focusLabel=`Move`,focusEvents=[`focus_l`,`focus_u`,`focus_r`,`focus_d`,`focus_lr`,`focus_ud`],rotateCamLabel=`Scale`;return isTabRightActive.value?rotateCamLabel=`Pan`:isHoldModifier.value&&(rotateCamLabel=`Skew`),!isTabRightActive.value&&!isHoldModifier.value&&focusEvents.forEach(uiEvent=>labels[uiEvent]=`Move`),[`rotate_h_cam`,`rotate_v_cam`].forEach(uiEvent=>labels[uiEvent]=rotateCamLabel),labels.tab_l=isTabRightActive.value?void 0:`[Hold] Skew`,labels.tab_r=isHoldModifier.value?void 0:`[Hold] Camera`,labels.action_2=isTabRightActive.value?void 0:`[Hold] Precise`,labels});watchEffect(()=>{navBlocker.clear(),isTabRightActive.value&&navBlocker.allowOnly([`rotate_h_cam`,`rotate_v_cam`,`tab_r`]),isHoldModifier.value&&navBlocker.allowOnly([`rotate_h_cam`,`rotate_v_cam`,`action_2`,`tab_l`])}),onBeforeMount(()=>{headerStore.setPreheader([`Transform`])}),onMounted(async()=>{infobar.visible=!0,infobar.showSysInfo=!0,events$3.on(`liveryEditor_layerEdit_state`,onStateData),events$3.on(`liveryEditor_layerEdit_initialLayerData`,onInitialLayerData),events$3.on(`liveryEditor_layerEdit_repositionSuccess`,onRepositionSuccess),events$3.on(`liveryEditor_layerEdit_rotationChanged`,onRotationChanged),events$3.on(`liveryEditor_layerEdit_positionChanged`,onPositionChanged),events$3.on(`liveryEditor_layerEdit_scaleChanged`,onScaleChanged),events$3.on(`liveryEditor_layerEdit_skewChanged`,onSkewChanged),await Lua_default.extensions.ui_liveryEditor_layerEdit.requestStateData(),await Lua_default.extensions.ui_liveryEditor_layerEdit.requestInitialLayerData()}),onBeforeUnmount(async()=>{events$3.off(`liveryEditor_layerEdit_state`,onStateData),events$3.off(`liveryEditor_layerEdit_initialLayerData`,onInitialLayerData),events$3.off(`liveryEditor_layerEdit_repositionSuccess`,onRepositionSuccess),events$3.off(`liveryEditor_layerEdit_rotationChanged`,onRotationChanged),events$3.off(`liveryEditor_layerEdit_positionChanged`,onPositionChanged),events$3.off(`liveryEditor_layerEdit_scaleChanged`,onScaleChanged),events$3.off(`liveryEditor_layerEdit_skewChanged`,onSkewChanged)});function onPositionChanged(position){positionX.value=position.x,positionY.value=position.y}function onRotationChanged(value){transformState.rotation=value}function onSkewChanged(skew){skewX.value=skew.x,skewY.value=skew.y}function onScaleChanged(scale){scaleX.value=scale.x,scaleY.value=scale.y}function onRepositionSuccess(){isRepositionActive.value=!isRepositionActive.value}function handleModifier(element){isHoldModifier.value=element.detail.value===1}function handlePrecise(element){let isPrecise=element.detail.value===1;isPreciseActive.value=isPrecise,Lua_default.extensions.ui_liveryEditor_layerEdit.holdPrecise(isPrecise)}function handleTabRight(element){isTabRightActive.value=element.detail.value===1}function handleAction3(element){isRepositionActive.value?toggleUseMouseOrCursor(element):toggleReposition(element)}function toggleReposition(element){let isReposition=isRepositionActive.value;isReposition?Lua_default.extensions.ui_liveryEditor_layerEdit.cancelReposition():Lua_default.extensions.ui_liveryEditor_layerEdit.requestReposition(),isRepositionActive.value=!isReposition}function toggleUseMouseOrCursor(element){if(!isRepositionActive.value)return!0;Lua_default.extensions.ui_liveryEditor_layerEdit.toggleUseMouseOrCursor().then(data=>{isUseMouse.value=data.isUseMouse})}function toggleEdit(element){if(isRepositionActive.value&&isUseMouse.value)return;let newValue=!isEdit.value;isEdit.value=newValue,Lua_default.extensions.ui_liveryEditor_layerEdit.setAllowRotationAction(!newValue).then(()=>{})}function handleFocusLinear(element){if(isEdit.value)return;let name=element.detail.name,value=element.detail.value,axis=name===`focus_d`||name===`focus_u`?`y`:`x`,direction$1=name===`focus_d`||name===`focus_l`?-1:1;Lua_default.extensions.ui_liveryEditor_layerEdit.holdTranslate(axis,direction$1*value)}function handleTranslateScalar(element){if(isEdit.value)return!0;let name=element.detail.name,value=element.detail.value,axis=name===`focus_lr`?`x`:`y`;Lua_default.extensions.ui_liveryEditor_layerEdit.holdTranslateScalar(axis,value)}function handleRotateCam(element){if(isRepositionActive.value||isTabRightActive.value)return!0;let name=element.detail.name,value=element.detail.value,axis=name===`rotate_h_cam`?`x`:`y`;isHoldModifier.value?Lua_default.extensions.ui_liveryEditor_layerEdit.holdSkew(axis,value):Lua_default.extensions.ui_liveryEditor_layerEdit.holdScale(axis,value)}function goBack(event){isRepositionActive.value?toggleReposition():isEdit.value?toggleEdit():openConfirmation(`Exit`,`Exit and lose unsaved changes?`).then(res=>{res&&(Lua_default.extensions.ui_liveryEditor_layerEdit.endTransform(),Lua_default.extensions.ui_liveryEditor_layerEdit.cancelChanges().then(()=>{window.bngVue.gotoGameState(`LiveryDecals`)}))}),event.stopPropagation()}function handleOk(){isRepositionActive.value?Lua_default.extensions.ui_liveryEditor_layerEdit.applyReposition():(Lua_default.extensions.ui_liveryEditor_layerEdit.endTransform(),Lua_default.extensions.ui_liveryEditor_layerEdit.saveChanges(!1).then(()=>{window.bngVue.gotoGameState(`LiveryDecals`)}))}function saveChanges(){Lua_default.extensions.ui_liveryEditor_layerEdit.saveChanges(!1).then(()=>{window.bngVue.gotoGameState(`LiveryDecals`)})}function onStateData(data){stateData.value=data,isReapplying.value=data.isStampReapplying}function onInitialLayerData(data){positionX.value=data.position.x,positionY.value=data.position.y,scaleX.value=data.scale.x,scaleY.value=data.scale.y,skewX.value=data.skew.x,skewY.value=data.skew.y,rotation.value=data.rotation}function assertInt(value){return typeof value==`string`?+value:value}return(_ctx,_cache)=>withDirectives((openBlock(),createElementBlock(`div`,_hoisted_1$70,[createBaseVNode(`div`,_hoisted_2$58,[createVNode(unref(LiveryEditorHeader_default))]),createBaseVNode(`div`,_hoisted_3$50,[createBaseVNode(`div`,_hoisted_4$38,[withDirectives((openBlock(),createBlock(LayerInspectorBase_default,{heading:`Transform`},{default:withCtx(()=>[createBaseVNode(`div`,{class:normalizeClass([`transform-inspector`,{"inspector-editing":isEdit.value}])},[createBaseVNode(`div`,_hoisted_5$33,[_cache[17]||=createBaseVNode(`div`,{class:`setting-item-name`},`Position`,-1),isRepositionActive.value&&isUseMouse.value?(openBlock(),createElementBlock(`div`,_hoisted_6$25,[..._cache[15]||=[createBaseVNode(`span`,null,`Using mouse position`,-1)]])):isEdit.value?(openBlock(),createElementBlock(`div`,_hoisted_7$23,[createBaseVNode(`div`,_hoisted_8$18,[createVNode(unref(bngInput_default),{modelValue:positionX.value,"onUpdate:modelValue":_cache[0]||=$event=>positionX.value=$event,type:`number`,step:.001,min:INPUT_MIN,max:1,prefix:`X`},null,8,[`modelValue`]),createVNode(unref(bngSlider_default),{modelValue:positionX.value,"onUpdate:modelValue":_cache[1]||=$event=>positionX.value=$event,step:.001,min:INPUT_MIN,max:1},null,8,[`modelValue`])]),createBaseVNode(`div`,_hoisted_9$16,[createVNode(unref(bngInput_default),{modelValue:positionY.value,"onUpdate:modelValue":_cache[2]||=$event=>positionY.value=$event,type:`number`,step:.001,min:INPUT_MIN,max:1,prefix:`Y`},null,8,[`modelValue`]),createVNode(unref(bngSlider_default),{modelValue:positionY.value,"onUpdate:modelValue":_cache[3]||=$event=>positionY.value=$event,step:.001,min:INPUT_MIN,max:1},null,8,[`modelValue`])])])):(openBlock(),createElementBlock(`div`,_hoisted_10$12,[createVNode(unref(bngPropVal_default),{keyLabel:`X`,valueLabel:positionX.value},null,8,[`valueLabel`]),createVNode(unref(bngPropVal_default),{keyLabel:`Y`,valueLabel:positionY.value},null,8,[`valueLabel`])])),isRepositionActive.value?createCommentVNode(``,!0):(openBlock(),createBlock(unref(bngButton_default),{key:3,accent:`outlined`,class:`reposition-button`,onClick:toggleReposition},{default:withCtx(()=>[createVNode(unref(bngBinding_default),{uiEvent:`action_3`}),_cache[16]||=createBaseVNode(`span`,{class:`reposition-button-label`},`Reproject and Position`,-1)]),_:1}))]),isRepositionActive.value?createCommentVNode(``,!0):(openBlock(),createBlock(unref(bngDivider_default),{key:0})),isRepositionActive.value?createCommentVNode(``,!0):(openBlock(),createElementBlock(`div`,_hoisted_11$10,[_cache[18]||=createBaseVNode(`div`,{class:`setting-item-name`},`Scale`,-1),isEdit.value?(openBlock(),createElementBlock(`div`,_hoisted_12$7,[createBaseVNode(`div`,_hoisted_13$7,[createVNode(unref(bngInput_default),{modelValue:scaleX.value,"onUpdate:modelValue":_cache[4]||=$event=>scaleX.value=$event,type:`number`,prefix:`X`,step:.01,min:INPUT_MIN,max:15},null,8,[`modelValue`]),createVNode(unref(bngSlider_default),{modelValue:scaleX.value,"onUpdate:modelValue":_cache[5]||=$event=>scaleX.value=$event,step:.01,min:INPUT_MIN,max:15},null,8,[`modelValue`])]),createBaseVNode(`div`,_hoisted_14$7,[createVNode(unref(bngInput_default),{modelValue:scaleY.value,"onUpdate:modelValue":_cache[6]||=$event=>scaleY.value=$event,type:`number`,step:.01,min:INPUT_MIN,max:15,prefix:`Y`},null,8,[`modelValue`]),createVNode(unref(bngSlider_default),{modelValue:scaleY.value,"onUpdate:modelValue":_cache[7]||=$event=>scaleY.value=$event,step:.01,min:INPUT_MIN,max:15},null,8,[`modelValue`])])])):(openBlock(),createElementBlock(`div`,_hoisted_15$7,[createVNode(unref(bngPropVal_default),{keyLabel:`X`,valueLabel:scaleX.value},null,8,[`valueLabel`]),createVNode(unref(bngPropVal_default),{keyLabel:`Y`,valueLabel:scaleY.value},null,8,[`valueLabel`])]))])),isRepositionActive.value?createCommentVNode(``,!0):(openBlock(),createBlock(unref(bngDivider_default),{key:2})),isRepositionActive.value?createCommentVNode(``,!0):(openBlock(),createElementBlock(`div`,_hoisted_16$7,[_cache[19]||=createBaseVNode(`div`,{class:`setting-item-name`},`Rotate`,-1),isEdit.value?(openBlock(),createElementBlock(`div`,_hoisted_17$6,[createBaseVNode(`div`,_hoisted_18$5,[createVNode(unref(bngInput_default),{modelValue:rotation.value,"onUpdate:modelValue":_cache[8]||=$event=>rotation.value=$event,type:`number`,step:.1,min:INPUT_MIN,max:359.9,suffix:`deg`},null,8,[`modelValue`]),createVNode(unref(bngSlider_default),{modelValue:rotation.value,"onUpdate:modelValue":_cache[9]||=$event=>rotation.value=$event,step:.1,min:INPUT_MIN,max:359.9},null,8,[`modelValue`])])])):(openBlock(),createElementBlock(`div`,_hoisted_19$3,[createVNode(unref(bngPropVal_default),{keyLabel:`deg`,valueLabel:rotation.value},null,8,[`valueLabel`])]))])),isRepositionActive.value?createCommentVNode(``,!0):(openBlock(),createBlock(unref(bngDivider_default),{key:4})),isRepositionActive.value?createCommentVNode(``,!0):(openBlock(),createElementBlock(`div`,_hoisted_20$3,[_cache[20]||=createBaseVNode(`div`,{class:`setting-item-name`},`Skew`,-1),isEdit.value?(openBlock(),createElementBlock(`div`,_hoisted_21$3,[createBaseVNode(`div`,_hoisted_22$3,[createVNode(unref(bngInput_default),{modelValue:skewX.value,"onUpdate:modelValue":_cache[10]||=$event=>skewX.value=$event,type:`number`,step:.01,min:INPUT_MIN,max:INPUT_MAX,prefix:`X`},null,8,[`modelValue`]),createVNode(unref(bngSlider_default),{modelValue:skewX.value,"onUpdate:modelValue":_cache[11]||=$event=>skewX.value=$event,step:.01,min:INPUT_MIN,max:INPUT_MAX},null,8,[`modelValue`])]),createBaseVNode(`div`,_hoisted_23$3,[createVNode(unref(bngInput_default),{modelValue:skewY.value,"onUpdate:modelValue":_cache[12]||=$event=>skewY.value=$event,type:`number`,step:.01,min:INPUT_MIN,max:INPUT_MAX,prefix:`Y`},null,8,[`modelValue`]),createVNode(unref(bngSlider_default),{modelValue:skewY.value,"onUpdate:modelValue":_cache[13]||=$event=>skewY.value=$event,step:.01,min:INPUT_MIN,max:INPUT_MAX},null,8,[`modelValue`])])])):(openBlock(),createElementBlock(`div`,_hoisted_24$2,[createVNode(unref(bngPropVal_default),{keyLabel:`X`,valueLabel:skewX.value},null,8,[`valueLabel`]),createVNode(unref(bngPropVal_default),{keyLabel:`Y`,valueLabel:skewY.value},null,8,[`valueLabel`])]))])),!isRepositionActive.value||!isUseMouse.value?withDirectives((openBlock(),createBlock(unref(bngButton_default),{key:6,accent:`text`,class:`inspector-edit-button`,onClick:_cache[14]||=$event=>isEdit.value=!isEdit.value},{default:withCtx(()=>[createVNode(unref(bngBinding_default),{uiEvent:`context`}),createBaseVNode(`span`,_hoisted_25$1,` Toggle `+toDisplayString(isEdit.value?`Simple`:`Advance`),1)]),_:1})),[[unref(BngOnUiNav_default),()=>isEdit.value=!isEdit.value,`ok`,{focusRequired:!0}]]):createCommentVNode(``,!0)],2)]),_:1})),[[unref(BngBlur_default)]]),!isRepositionActive.value||!isUseMouse.value?withDirectives((openBlock(),createBlock(unref(bngButton_default),{key:0,class:`apply-button`,onClick:handleOk},{default:withCtx(()=>[createVNode(unref(bngBinding_default),{uiEvent:`ok`}),_cache[21]||=createBaseVNode(`span`,null,`Apply`,-1)]),_:1})),[[unref(BngOnUiNav_default),handleOk,`ok`,{focusRequired:!0}]]):createCommentVNode(``,!0)])])])),[[unref(BngOnUiNav_default),handleOk,`ok`],[unref(BngOnUiNav_default),goBack,`back`],[unref(BngOnUiNav_default),saveChanges,`menu`],[unref(BngOnUiNav_default),handleTranslateScalar,`focus_lr`],[unref(BngOnUiNav_default),handleTranslateScalar,`focus_ud`],[unref(BngOnUiNav_default),handleFocusLinear,`focus_l`,{up:!0}],[unref(BngOnUiNav_default),handleFocusLinear,`focus_l`,{down:!0}],[unref(BngOnUiNav_default),handleFocusLinear,`focus_r`,{up:!0}],[unref(BngOnUiNav_default),handleFocusLinear,`focus_r`,{down:!0}],[unref(BngOnUiNav_default),handleFocusLinear,`focus_u`,{up:!0}],[unref(BngOnUiNav_default),handleFocusLinear,`focus_u`,{down:!0}],[unref(BngOnUiNav_default),handleFocusLinear,`focus_d`,{up:!0}],[unref(BngOnUiNav_default),handleFocusLinear,`focus_d`,{down:!0}],[unref(BngOnUiNav_default),handleFocusLinear,`focus_l`,{up:!0,modified:!0}],[unref(BngOnUiNav_default),handleFocusLinear,`focus_l`,{down:!0,modified:!0}],[unref(BngOnUiNav_default),handleFocusLinear,`focus_r`,{up:!0,modified:!0}],[unref(BngOnUiNav_default),handleFocusLinear,`focus_r`,{down:!0,modified:!0}],[unref(BngOnUiNav_default),handleFocusLinear,`focus_u`,{up:!0,modified:!0}],[unref(BngOnUiNav_default),handleFocusLinear,`focus_u`,{down:!0,modified:!0}],[unref(BngOnUiNav_default),handleFocusLinear,`focus_d`,{up:!0,modified:!0}],[unref(BngOnUiNav_default),handleFocusLinear,`focus_d`,{down:!0,modified:!0}],[unref(BngOnUiNav_default),handleRotateCam,`rotate_h_cam`],[unref(BngOnUiNav_default),handleRotateCam,`rotate_v_cam`],[unref(BngOnUiNav_default),handleRotateCam,`rotate_h_cam`,{modified:!0}],[unref(BngOnUiNav_default),handleRotateCam,`rotate_v_cam`,{modified:!0}],[unref(BngOnUiNav_default),handlePrecise,`action_2`,{up:!0}],[unref(BngOnUiNav_default),handlePrecise,`action_2`,{down:!0}],[unref(BngOnUiNav_default),handlePrecise,`action_2`,{up:!0,modified:!0}],[unref(BngOnUiNav_default),handlePrecise,`action_2`,{down:!0,modified:!0}],[unref(BngOnUiNav_default),handleModifier,`tab_l`,{up:!0}],[unref(BngOnUiNav_default),handleModifier,`tab_l`,{down:!0}],[unref(BngOnUiNav_default),handleTabRight,`tab_r`,{up:!0}],[unref(BngOnUiNav_default),handleTabRight,`tab_r`,{down:!0}],[unref(BngOnUiNav_default),handleAction3,`action_3`],[unref(BngOnUiNav_default),toggleEdit,`context`],[unref(BngUiNavLabel_default),hintLabels.value.focus_lr,`focus_lr`],[unref(BngUiNavLabel_default),hintLabels.value.focus_ud,`focus_ud`],[unref(BngUiNavLabel_default),hintLabels.value.focus_l,`focus_l`],[unref(BngUiNavLabel_default),hintLabels.value.focus_r,`focus_r`],[unref(BngUiNavLabel_default),hintLabels.value.focus_u,`focus_u`],[unref(BngUiNavLabel_default),hintLabels.value.focus_d,`focus_d`],[unref(BngUiNavLabel_default),hintLabels.value.rotate_h_cam,`rotate_h_cam`],[unref(BngUiNavLabel_default),hintLabels.value.rotate_v_cam,`rotate_v_cam`],[unref(BngUiNavLabel_default),hintLabels.value.action_2,`action_2`],[unref(BngUiNavLabel_default),hintLabels.value.action_3,`action_3`],[unref(BngUiNavLabel_default),hintLabels.value.tab_r,`tab_r`],[unref(BngUiNavLabel_default),hintLabels.value.tab_l,`tab_l`],[unref(BngUiNavLabel_default),hintLabels.value.ok,`ok`],[unref(BngUiNavLabel_default),hintLabels.value.back,`back`]])}},LayerTransform_default=__plugin_vue_export_helper_default(_sfc_main$78,[[`__scopeId`,`data-v-a4399a23`]]),_hoisted_1$69={class:`layer-materials-view`,"bng-ui-scope":`layer-materials-scope`},_hoisted_2$57={class:`header`},_hoisted_3$49={class:`main-view-content`},_hoisted_4$37={class:`inspector-container`},_hoisted_5$32={class:`materials-inspector`},_hoisted_6$24={class:`materials-setting-item`},_hoisted_7$22={class:`color-values-container`,"bng-no-child-nav":``},_hoisted_8$17={class:`materials-setting-item`},_hoisted_9$15={class:`slider-text-container`},_hoisted_10$11={class:`materials-setting-item`},_hoisted_11$9={class:`slider-text-container`},BLOCKED_UI_EVENTS=[`tab_l`,`tab_r`,`action_2`,`rotate_h_cam`,`rotate_v_cam`,`focus_lr`,`focus_ud`],_sfc_main$77={__name:`LayerMaterials`,setup(__props){let headerStore=useEditorHeaderStore(),infobar=useInfoBar(),uiNavBlocker=useUINavBlocker();useUINavScope(`layer-materials-scope`);let{events:events$3}=useBridge(),screenState=reactive({openedDialog:null}),color=ref({hue:.5,saturation:1,luminosity:.5}),inputHue=computed({get:()=>color.value.hue.toFixed(3),set:newValue=>{color.value.hue=typeof newValue==`string`?+newValue:newValue,onColorChanged()}}),inputSat=computed({get:()=>color.value.saturation.toFixed(3),set:newValue=>{color.value.saturation=typeof newValue==`string`?+newValue:newValue,onColorChanged()}}),inputLum=computed({get:()=>color.value.luminosity.toFixed(3),set:newValue=>{color.value.luminosity=typeof newValue==`string`?+newValue:newValue,onColorChanged()}}),metallicIntensity=ref(0),roughnessIntensity=ref(0),stateData=ref(),colorInitialized=ref(!1),isPreciseActive=ref(!1),colorPickerStep=computed(()=>isPreciseActive.value?.001:.01),slidersStep=computed(()=>isPreciseActive.value?.1:1),updateMaterialProperties=properties=>Lua_default.extensions.ui_liveryEditor_layerEdit.setLayerMaterials(properties);function onColorChanged(){if(!colorInitialized.value)return;let paint=new Paint;paint.hsl=[color.value.hue,color.value.saturation,color.value.luminosity],updateMaterialProperties({color:paint.rgba})}watch(()=>metallicIntensity.value,value=>updateMaterialProperties({metallicIntensity:value})),watch(()=>roughnessIntensity.value,value=>updateMaterialProperties({roughnessIntensity:value})),onBeforeMount(()=>{headerStore.setPreheader([`Materials`])}),onMounted(async()=>{infobar.visible=!0,infobar.showSysInfo=!0,uiNavBlocker.blockOnly(BLOCKED_UI_EVENTS),events$3.on(`liveryEditor_layerEdit_state`,onStateData),events$3.on(`liveryEditor_layerEdit_layerMaterialsData`,onMaterialPropertiesData),await Lua_default.extensions.ui_liveryEditor_layerEdit.requestStateData(),await Lua_default.extensions.ui_liveryEditor_layerEdit.requestLayerMaterials()}),onBeforeUnmount(async()=>{events$3.off(`liveryEditor_layerEdit_layerMaterialsData`,onMaterialPropertiesData),events$3.off(`liveryEditor_layerEdit_state`,onStateData),uiNavBlocker.clear()});async function onStateData(data){stateData.value=data}function onMaterialPropertiesData(data){colorInitialized.value=!1;let paint=new Paint;data.color[3]=1;let isWhite=data.color.every(num=>num===1);paint.rgba=data.color,color.value.hue=paint.hue,color.value.saturation=isWhite?.5:paint.saturation,color.value.luminosity=paint.luminosity,colorInitialized.value=!0,metallicIntensity.value=data.metallicIntensity,roughnessIntensity.value=data.roughnessIntensity}function handleAction2(element){isPreciseActive.value=element.detail.value===1}function goBack(event){screenState.openedDialog||(screenState.openedDialog=`exit`,openConfirmation(`Exit`,`Exit and lose changes?`).then(res=>{res&&Lua_default.extensions.ui_liveryEditor_layerEdit.cancelChanges().then(()=>{window.bngVue.gotoGameState(`LiveryDecals`)}),screenState.openedDialog=null}),event.stopPropagation())}function saveChanges(){Lua_default.extensions.ui_liveryEditor_layerEdit.saveChanges().then(()=>{window.bngVue.gotoGameState(`LiveryDecals`)})}return(_ctx,_cache)=>withDirectives((openBlock(),createElementBlock(`div`,_hoisted_1$69,[createBaseVNode(`div`,_hoisted_2$57,[createVNode(unref(LiveryEditorHeader_default))]),createBaseVNode(`div`,_hoisted_3$49,[createBaseVNode(`div`,_hoisted_4$37,[withDirectives((openBlock(),createBlock(LayerInspectorBase_default,{heading:`Materials`,class:``},{default:withCtx(()=>[createBaseVNode(`div`,_hoisted_5$32,[createBaseVNode(`div`,_hoisted_6$24,[_cache[8]||=createBaseVNode(`div`,{class:`setting-item-name`},`Color`,-1),withDirectives(createVNode(unref(bngColorPicker_default),{modelValue:color.value,"onUpdate:modelValue":_cache[0]||=$event=>color.value=$event,step:colorPickerStep.value,onChange:onColorChanged},null,8,[`modelValue`,`step`]),[[unref(BngUiNavFocus_default),0]]),createBaseVNode(`div`,_hoisted_7$22,[createVNode(unref(bngInput_default),{prefix:`h`,modelValue:inputHue.value,"onUpdate:modelValue":_cache[1]||=$event=>inputHue.value=$event,type:`number`},null,8,[`modelValue`]),createVNode(unref(bngInput_default),{prefix:`s`,modelValue:inputSat.value,"onUpdate:modelValue":_cache[2]||=$event=>inputSat.value=$event,type:`number`},null,8,[`modelValue`]),createVNode(unref(bngInput_default),{prefix:`b`,modelValue:inputLum.value,"onUpdate:modelValue":_cache[3]||=$event=>inputLum.value=$event,type:`number`},null,8,[`modelValue`])])]),createVNode(unref(bngDivider_default)),createBaseVNode(`div`,_hoisted_8$17,[_cache[9]||=createBaseVNode(`div`,{class:`setting-item-name`},`Metallic Intensity`,-1),createBaseVNode(`div`,_hoisted_9$15,[createVNode(unref(bngInput_default),{"bng-no-nav":``,modelValue:metallicIntensity.value,"onUpdate:modelValue":_cache[4]||=$event=>metallicIntensity.value=$event,type:`number`,min:0,max:100,step:slidersStep.value},null,8,[`modelValue`,`step`]),createVNode(unref(bngSlider_default),{modelValue:metallicIntensity.value,"onUpdate:modelValue":_cache[5]||=$event=>metallicIntensity.value=$event,min:0,max:100,step:slidersStep.value},null,8,[`modelValue`,`step`])])]),createVNode(unref(bngDivider_default)),createBaseVNode(`div`,_hoisted_10$11,[_cache[10]||=createBaseVNode(`div`,{class:`setting-item-name`},`Roughness Intensity`,-1),createBaseVNode(`div`,_hoisted_11$9,[createVNode(unref(bngInput_default),{"bng-no-nav":``,modelValue:roughnessIntensity.value,"onUpdate:modelValue":_cache[6]||=$event=>roughnessIntensity.value=$event,type:`number`,min:0,max:100,step:slidersStep.value},null,8,[`modelValue`,`step`]),createVNode(unref(bngSlider_default),{modelValue:roughnessIntensity.value,"onUpdate:modelValue":_cache[7]||=$event=>roughnessIntensity.value=$event,min:0,max:100,step:slidersStep.value},null,8,[`modelValue`,`step`])])])])]),_:1})),[[unref(BngBlur_default)]])])])])),[[unref(BngUiNavLabel_default),`Apply`,`context`],[unref(BngUiNavLabel_default),`[Hold]Precise`,`action_2`],[unref(BngUiNavLabel_default),`Back`,`back,menu`],[unref(BngOnUiNav_default),handleAction2,`action_2`,{up:!0}],[unref(BngOnUiNav_default),handleAction2,`action_2`,{down:!0}],[unref(BngOnUiNav_default),goBack,`back,menu`],[unref(BngOnUiNav_default),saveChanges,`context`]])}},LayerMaterials_default=__plugin_vue_export_helper_default(_sfc_main$77,[[`__scopeId`,`data-v-4b3730e9`]]),_hoisted_1$68={class:`layer-projection-view`,"bng-ui-scope":`layer-projection-scope`},_hoisted_2$56={class:`header`},_hoisted_3$48={class:`main-view-content`},_hoisted_4$36={class:`camera-views-container`},_hoisted_5$31={class:`mirror-settings-container`},CAMERA_BUTTONS=[{label:`Right`,icon:icons.cameraSideRight,value:`right`},{label:`Front`,icon:icons.cameraFront1,value:`front`},{label:`Left`,icon:icons.cameraSideLeft,value:`left`},{label:`Back`,icon:icons.cameraBack1,value:`back`},{label:`Top Right`,icon:icons.cameraTop1,value:`topright`},{label:`Top Left`,icon:icons.cameraTop1,value:`topleft`},{label:`Top Front`,icon:icons.cameraTop1,value:`topfront`},{label:`Top Back`,icon:icons.cameraTop1,value:`topback`}],_sfc_main$76={__name:`LayerProjection`,setup(__props){let{events:events$3}=useBridge(),headerStore=useEditorHeaderStore(),store$1=useLiveryEditorStore(),infobar=useInfoBar(),popover=usePopover(),uiNav=useUINavScope(`layer-projection-scope`),stateData=ref(null),mirrorState=reactive({mirrored:!1,mirrorFipped:!1,mirrorOffset:0}),mirrored=computed({get:()=>mirrorState.mirrored,set:async newValue=>{mirrorState.mirrored=newValue,await Lua_default.extensions.ui_liveryEditor_layerEdit.setMirrored(newValue,mirrorState.mirrorFipped,mirrorState.mirrorOffset)}}),mirrorFipped=computed({get:()=>mirrorState.mirrorFipped,set:async newValue=>{mirrorState.mirrorFipped=newValue,await Lua_default.extensions.ui_liveryEditor_layerEdit.setMirrored(mirrorState.mirrored,newValue,mirrorState.mirrorOffset)}}),mirrorOffset=computed({get:()=>mirrorState.mirrorOffset,set:async newValue=>{mirrorState.mirrorOffset=newValue,await Lua_default.extensions.ui_liveryEditor_layerEdit.setMirrored(mirrorState.mirrored,mirrorState.mirrorFipped,newValue)}}),NAV_HINTS=[{id:`apply`,content:{type:`binding`,props:{uiEvent:`menu`},label:`Done`},action:saveChanges},{id:`back`,content:{type:`binding`,props:{uiEvent:`back`},label:`Back`},action:goBack}];onBeforeMount(()=>{infobar.clearHints(),infobar.addHints(NAV_HINTS),headerStore.setPreheader([`Projection`]),headerStore.setHeader(`Decals`)}),onMounted(async()=>{infobar.visible=!0,infobar.showSysInfo=!0,events$3.on(`liveryEditor_layerEdit_state`,onStateData),events$3.on(`liveryEditor_layerEdit_initialLayerData`,onInitialLayerData),await Lua_default.extensions.ui_liveryEditor_layerEdit.requestStateData(),await Lua_default.extensions.ui_liveryEditor_layerEdit.requestInitialLayerData()}),onBeforeUnmount(()=>{events$3.off(`liveryEditor_layerEdit_state`,onStateData),events$3.off(`liveryEditor_layerEdit_initialLayerData`,onInitialLayerData)});function changeCameraView(view){popover.hide(`camera-views-menu`),console.log(`changeCameraView`,view),store$1.setOrthographicView(view)}function onStateData(data){console.log(`onStateData`,data),stateData.value=data}function onInitialLayerData(data){mirrorState.mirrored=data.mirrored,mirrorState.mirrorFipped=data.mirrorFipped,mirrorState.mirrorOffset=data.mirrorOffset}function goBack(){window.bngVue.gotoGameState(`LiveryLayerEdit`)}function saveChanges(){window.bngVue.gotoGameState(`LiveryLayerEdit`)}function onPopoverMenuHide(){uiNav.set(`layer-projection-scope`)}return(_ctx,_cache)=>withDirectives((openBlock(),createElementBlock(`div`,_hoisted_1$68,[createBaseVNode(`div`,_hoisted_2$56,[createVNode(unref(LiveryEditorHeader_default))]),createBaseVNode(`div`,_hoisted_3$48,[withDirectives(createVNode(unref(bngImageTile_default),{"bng-nav-item":``,icon:unref(icons).movieCamera,label:`Side`},null,8,[`icon`]),[[unref(BngBlur_default)],[unref(BngPopover_default),`camera-views-menu`,`right-start`,{click:!0}]]),withDirectives(createVNode(unref(bngImageTile_default),{"bng-nav-item":``,icon:unref(icons).reflect,label:`Mirror`},null,8,[`icon`]),[[unref(BngBlur_default)],[unref(BngPopover_default),`mirror-settings-menu`,`right-start`,{click:!0}]])]),createVNode(unref(bngPopoverMenu_default),{name:`camera-views-menu`,onHide:onPopoverMenuHide},{default:withCtx(()=>[createBaseVNode(`div`,_hoisted_4$36,[createVNode(unref(bngList_default),{targetWidth:8,targetMargin:.5,noBackground:``},{default:withCtx(()=>[(openBlock(),createElementBlock(Fragment,null,renderList(CAMERA_BUTTONS,view=>createVNode(unref(bngImageTile_default),{key:view.value,"bng-nav-item":``,label:view.label,icon:view.icon,onClick:$event=>changeCameraView(view.value)},null,8,[`label`,`icon`,`onClick`])),64))]),_:1})])]),_:1}),createVNode(unref(bngPopoverMenu_default),{name:`mirror-settings-menu`,onHide:onPopoverMenuHide},{default:withCtx(()=>[createBaseVNode(`div`,_hoisted_5$31,[createVNode(unref(bngPillCheckbox_default),{modelValue:mirrored.value,"onUpdate:modelValue":_cache[0]||=$event=>mirrored.value=$event},{default:withCtx(()=>[..._cache[3]||=[createTextVNode(`Mirrored`,-1)]]),_:1},8,[`modelValue`]),withDirectives((openBlock(),createBlock(unref(bngPillCheckbox_default),{modelValue:mirrorFipped.value,"onUpdate:modelValue":_cache[1]||=$event=>mirrorFipped.value=$event},{default:withCtx(()=>[..._cache[4]||=[createTextVNode(`Mirror Flipped`,-1)]]),_:1},8,[`modelValue`])),[[unref(BngDisabled_default),!mirrored.value]]),createVNode(unref(bngInput_default),{modelValue:mirrorOffset.value,"onUpdate:modelValue":_cache[2]||=$event=>mirrorOffset.value=$event,externalLabel:`Offset`,type:`number`,disabled:!mirrored.value},null,8,[`modelValue`,`disabled`])])]),_:1})])),[[unref(BngOnUiNav_default),goBack,`back`],[unref(BngOnUiNav_default),goBack,`menu`]])}},LayerProjection_default=__plugin_vue_export_helper_default(_sfc_main$76,[[`__scopeId`,`data-v-19e531c7`]]),_hoisted_1$67={class:`settings-main-view`,"bng-ui-scope":`settings-main-scope`},_hoisted_2$55={class:`header`},_hoisted_3$47={class:`main-view-content`},_hoisted_4$35={class:`settings-container`},_hoisted_5$30={class:`settings-item`},_sfc_main$75={__name:`LiverySettingsMain`,setup(__props){let headerStore=useEditorHeaderStore(),infobar=useInfoBar();useUINavScope(`settings-main-scope`);let{events:events$3}=useBridge(),stateData=ref(null),useSurfaceNormal=ref(!1);watch(()=>useSurfaceNormal.value,async value=>{await Lua_default.extensions.ui_liveryEditor.useSurfaceNormal(value)});let NAV_HINTS=[{id:`back`,content:{type:`binding`,props:{uiEvent:`back`},label:`Back`},action:goBack}];onBeforeMount(()=>{infobar.clearHints(),infobar.addHints(NAV_HINTS),headerStore.setHeader(`Decals`),headerStore.setPreheader([`Settings`])}),onMounted(async()=>{infobar.visible=!0,infobar.showSysInfo=!0,events$3.on(`liveryEditor_settingsData`,onSettingsData),await Lua_default.extensions.ui_liveryEditor.requestSettingsData()}),onBeforeUnmount(()=>{events$3.off(`liveryEditor_settingsData`,onSettingsData)});function onSettingsData(data){console.log(`onSettingsData`,data),stateData.value=data,useSurfaceNormal.value=data.useSurfaceNormal}function goBack(event){window.bngVue.gotoGameState(`LiveryMain`),event.stopPropagation()}return(_ctx,_cache)=>withDirectives((openBlock(),createElementBlock(`div`,_hoisted_1$67,[createBaseVNode(`div`,_hoisted_2$55,[createVNode(unref(LiveryEditorHeader_default))]),createBaseVNode(`div`,_hoisted_3$47,[withDirectives((openBlock(),createBlock(unref(bngCard_default),null,{default:withCtx(()=>[createVNode(unref(bngCardHeading_default),null,{default:withCtx(()=>[..._cache[1]||=[createTextVNode(`Settings`,-1)]]),_:1}),createBaseVNode(`div`,_hoisted_4$35,[createBaseVNode(`div`,_hoisted_5$30,[_cache[2]||=createBaseVNode(`div`,{class:`settings-item-name`},`Use Surface Normal`,-1),withDirectives(createVNode(unref(bngSwitch_default),{modelValue:useSurfaceNormal.value,"onUpdate:modelValue":_cache[0]||=$event=>useSurfaceNormal.value=$event,label:useSurfaceNormal.value?`Yes`:`No`},null,8,[`modelValue`,`label`]),[[unref(BngUiNavFocus_default),0],[unref(BngFocusIf_default),!0]])])])]),_:1})),[[unref(BngBlur_default)]])])])),[[unref(BngOnUiNav_default),goBack,`back,menu`]])}},LiverySettingsMain_default=__plugin_vue_export_helper_default(_sfc_main$75,[[`__scopeId`,`data-v-ad4291e2`]]),routes_default$8=[{path:`/livery-editor`,name:`LiveryEditor`,component:LiveryEditor_default},{path:`/livery-main`,name:`LiveryMain`,component:LiveryMainNew_default},{path:`/livery-paint`,name:`LiveryPaint`,component:LiveryPaintMain_default},{path:`/livery-decals`,name:`LiveryDecals`,component:LiveryDecalsMain_default},{path:`/livery-settings`,name:`LiverySettings`,component:LiverySettingsMain_default},{path:`/livery-camera-settings`,name:`LiveryCameraSettings`,component:LiveryCameraSettings_default},{path:`/livery-decal-selector`,name:`LiveryDecalSelector`,component:LiveryDecalSelector_default},{path:`/livery-layer-edit`,name:`LiveryLayerEdit`,component:LiveryLayerEdit_default},{path:`/layer-transform`,name:`LayerTransform`,component:LayerTransform_default},{path:`/layer-materials`,name:`LayerMaterials`,component:LayerMaterials_default},{path:`/layer-projection`,name:`LayerProjection`,component:LayerProjection_default},{path:`/livery-manager`,name:`LiveryManager`,component:LiveryManager_default}],_hoisted_1$66={class:`logo-wrapper`},_sfc_main$74={__name:`Logo`,setup(__props){let logos={beamng:getAssetURL(`images/logos.svg#bng-beamng`),tech:getAssetURL(`images/logos.svg#bng-tech`),drive:getAssetURL(`images/logos.svg#bng-drive`),research:getAssetURL(`images/logos.svg#bng-research`)},productLogo=ref(logos.drive);return onMounted(async()=>{if(await Lua_default.extensions.tech_license.isValid())productLogo.value=logos.tech;else if(window.beamng){let name=window.beamng.product.replace(`BeamNG.`,``);name in logos&&(productLogo.value=logos[name])}else productLogo.value=logos.drive}),(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$66,[createBaseVNode(`div`,{class:`logo`,style:normalizeStyle({"--logo":`url('${productLogo.value}')`})},null,4)]))}},Logo_default=__plugin_vue_export_helper_default(_sfc_main$74,[[`__scopeId`,`data-v-69adfd8c`]]),_hoisted_1$65={class:`main-view`},_hoisted_2$54={class:`dev-info-content`},_hoisted_3$46={class:`dev-info-text`},_hoisted_4$34={class:`mainmenu-title`},_hoisted_5$29={key:1,class:`bottom-buttons`},_hoisted_6$23={class:`btn-content`},_hoisted_7$21={class:`label`},_hoisted_8$16={key:0,class:`small`},_hoisted_9$14={class:`btn-content`},_hoisted_10$10={class:`label`},_hoisted_11$8={key:0,class:`small`},_hoisted_12$6={class:`btn-content`},_hoisted_13$6={class:`label`},_hoisted_14$6={class:`btn-content`},_hoisted_15$6={class:`label`},_hoisted_16$6={class:`btn-content`},_hoisted_17$5={class:`label`},_sfc_main$73={__name:`MainMenu`,setup(__props){let events$3=useEvents(),infoBar=useInfoBar();useUINavScope(`mainmenuUI`);let withAngular=computed(()=>!sysInfo_default.mainMenuBackgroundRequired.value),firstTime=ref(sysInfo_default.mainMenuFirstTime.value),bgRequired=sysInfo_default.mainMenuBackgroundRequired,parentImageCarousel=inject(`mainBackground`),modCounts$1=sysInfo_default.modCounts,devEnv=reactive({env:window.beamng&&!window.beamng.shipping,vue:!1,simplemenu:window.beamng&&window.beamng.simplemenu,videoApi:null,UIEngine:null}),quickLoadLevel=()=>Lua_default.core_levels.startLevel(`/levels/smallgrid/main.level.json`),addons=ref({}),addButton=({translateid,icon,targetState,title,iconId,action})=>{let newButton;newButton=translateid||icon||targetState?{title:$translate.instant(translateid),icon,action:targetState}:{title,iconId,action},addons.value[newButton.title]=newButton},viewName=ref(),changeView=name=>{viewName.value=name,router_default.push(`/menu.mainmenu`+(name?`/`+name:``))};watch(()=>viewName.value,val=>{val&&infoBar.flashHints(`back`),parentImageCarousel.value&&nextTick(parentImageCarousel.value.carousel.showNext)});let route=useRoute();watch(()=>route.name,name=>{if(typeof name!=`string`){viewName.value=null;return}name.startsWith(`menu.mainmenu`)&&(viewName.value=name===`menu.mainmenu`?null:name.slice(14))},{immediate:!0});let navigate$1=(...state)=>window.bngVue.gotoGameState(...state);function quitGame(){Lua_default.quit(),runRaw(`TorqueScript.eval('quit();')`,!1)}let handleBack=event=>{event.detail.force||(viewName.value?(viewName.value=null,changeView(null)):(event.detail.name===`back`||event.detail.name===`menu`)&&window.globalAngularRootScope?.$broadcast(`MenuToggle`))},canDeactivateScope=()=>!viewName.value,canBubbleEvent=event=>{if(event.detail.value!==1)return!1;let eventName=event.detail.name;return eventName===`tab_l`||eventName===`tab_r`?!viewName.value:!1};function displayToast(type,title,titleContext,msg,messageContext){let msgTxt=$translate.contextTranslate({txt:msg,context:messageContext}),titleTxt=$translate.contextTranslate({txt:title,context:titleContext}),msgHtml=window.angularParseBBCode(msgTxt),titleHtml=window.angularParseBBCode(titleTxt);window.globalAngularRootScope.$broadcast(`toastrMsg`,{type,msg:msgHtml,title:titleHtml,config:{positionClass:`toast-top-right`,timeOut:0,extendedTimeOut:0,onTap(){window.bngVue.gotoGameState(`menu.options.performance`)}}})}async function checkHardware(){Lua_default.checkFSErrors();let info=await Lua_default.core_hardwareinfo.getInfo();if(info.globalState!==`ok`){for(let key in info)if(!(!info[key].warnings||!Array.isArray(info[key].warnings)))for(let warning of info[key].warnings)warning.ack||displayToast(info.globalState===`warn`?`warning`:`error`,`ui.performance.warnings.`+warning.msg,warning.context,`ui.mainmenu.warningdetails`,null)}}let repoEnabled=ref(!1),modsAfterUpdate=ref(!1),onSettingsChanged=data=>{modsAfterUpdate.value=data.values.disableModsAfterUpdate,repoEnabled.value=data.values.onlineFeatures===`enable`&&!data.values.disableModsAfterUpdate};return onMounted(async()=>{function advertMainMenu(){events$3.emit(`MainMenuButtons`,addButton),window.globalAngularRootScope.$broadcast(`MainMenuButtons`,addButton)}advertMainMenu(),events$3.on(`UiModsChanged`,advertMainMenu),events$3.on(`BroadcastMainMenuButtons`,advertMainMenu),events$3.on(`SettingsChanged`,onSettingsChanged),Lua_default.settings.notifyUI(),devEnv.env&&(devEnv.videoApi=await Lua_default.Engine.Render.getAdapterType(),devEnv.UIEngine=await Lua_default.Engine.UI.getUIEngine()),sysInfo_default.mainMenuFirstTime.value&&checkHardware();let settings$1=await useSettingsAsync();await Lua_default.extensions.tech_license.isValid()||(settings$1.values.onlineFeatures===`ask`||settings$1.values.telemetry===`ask`?window.bngVue.gotoGameState(`menu.onlineFeatures`):Lua_default.settings.getValue(`showedInputLayoutPopupV37`).then(value=>{value===!1&&window.bngVue.gotoGameState(`buttonLayout`)})),sysInfo_default.mainMenuFirstTime.value=!1}),onUnmounted(()=>{events$3.off(`SettingsChanged`,onSettingsChanged)}),(_ctx,_cache)=>{let _component_router_view=resolveComponent(`router-view`);return withDirectives((openBlock(),createElementBlock(`div`,{class:normalizeClass({"mainmenu-container":!0,"mainmenu-with-angular":withAngular.value,"mainmenu-fadein":firstTime.value&&!withAngular.value}),onDeactivate:handleBack},[withDirectives((openBlock(),createElementBlock(`div`,_hoisted_1$65,[devEnv.env?(openBlock(),createBlock(unref(bngCard_default),{key:0,class:`dev-info`},{default:withCtx(()=>[createVNode(unref(bngCardHeading_default),{type:`ribbon`},{default:withCtx(()=>[..._cache[5]||=[createTextVNode(`Developer Release`,-1)]]),_:1}),createBaseVNode(`div`,_hoisted_2$54,[withDirectives(createVNode(unref(bngIcon_default),{class:`dev-info-icon`,type:unref(icons).bug,"bng-all-clicks-no-nav":``},null,8,[`type`]),[[unref(BngDoubleClick_default),quickLoadLevel]]),createBaseVNode(`div`,_hoisted_3$46,[createBaseVNode(`div`,null,` Graphics API: `+toDisplayString(devEnv.videoApi||`requesting...`),1),createBaseVNode(`div`,null,` UI Engine: `+toDisplayString(devEnv.UIEngine||`requesting...`),1)])])]),_:1})):createCommentVNode(``,!0),createBaseVNode(`div`,_hoisted_4$34,[createVNode(Logo_default)]),createVNode(_component_router_view,{"first-time":firstTime.value&&!withAngular.value,addons:addons.value,onChangeView:changeView},null,8,[`first-time`,`addons`]),viewName.value?createCommentVNode(``,!0):(openBlock(),createElementBlock(`div`,_hoisted_5$29,[repoEnabled.value?withDirectives((openBlock(),createBlock(unref(bngButton_default),{key:0,class:`btn-mods`,accent:unref(ACCENTS).text,onClick:_cache[0]||=$event=>navigate$1(`menu.mods.repository`)},{default:withCtx(()=>[unref(bgRequired)?(openBlock(),createBlock(BlurBackground_default,{key:0})):createCommentVNode(``,!0),createBaseVNode(`div`,_hoisted_6$23,[createBaseVNode(`span`,_hoisted_7$21,toDisplayString(_ctx.$tt(`ui.mainmenu.repo`)),1),unref(modCounts$1).total>0?(openBlock(),createElementBlock(`span`,_hoisted_8$16,`\xA0(`+toDisplayString(unref(modCounts$1).active)+` / `+toDisplayString(unref(modCounts$1).total)+`)`,1)):createCommentVNode(``,!0)])]),_:1},8,[`accent`])),[[unref(BngBlur_default),!unref(bgRequired)],[unref(BngSoundClass_default),`bng_click_hover_generic`]]):withDirectives((openBlock(),createBlock(unref(bngButton_default),{key:1,class:normalizeClass([`btn-mods`,{"mods-after-update":modsAfterUpdate.value}]),accent:unref(ACCENTS).text,onClick:_cache[1]||=$event=>navigate$1(`menu.mods.local`)},{default:withCtx(()=>[unref(bgRequired)?(openBlock(),createBlock(BlurBackground_default,{key:0})):createCommentVNode(``,!0),createBaseVNode(`div`,_hoisted_9$14,[createBaseVNode(`span`,_hoisted_10$10,[modsAfterUpdate.value?(openBlock(),createBlock(unref(bngIcon_default),{key:0,type:`danger`,style:{"font-size":`1.1em`},color:`#ff2d00`})):createCommentVNode(``,!0),createTextVNode(toDisplayString(_ctx.$tt(`ui.mainmenu.mods`)),1)]),unref(modCounts$1).total>0?(openBlock(),createElementBlock(`span`,_hoisted_11$8,`\xA0(`+toDisplayString(unref(modCounts$1).active)+` / `+toDisplayString(unref(modCounts$1).total)+`)`,1)):createCommentVNode(``,!0)])]),_:1},8,[`class`,`accent`])),[[unref(BngBlur_default),!unref(bgRequired)],[unref(BngSoundClass_default),`bng_click_hover_generic`]]),withDirectives((openBlock(),createBlock(unref(bngButton_default),{accent:unref(ACCENTS).text,onClick:_cache[2]||=$event=>navigate$1(`credits`)},{default:withCtx(()=>[unref(bgRequired)?(openBlock(),createBlock(BlurBackground_default,{key:0})):createCommentVNode(``,!0),createBaseVNode(`div`,_hoisted_12$6,[createBaseVNode(`span`,_hoisted_13$6,toDisplayString(_ctx.$tt(`ui.mainmenu.credits`)),1)])]),_:1},8,[`accent`])),[[unref(BngBlur_default),!unref(bgRequired)],[unref(BngSoundClass_default),`bng_click_hover_generic`]]),withDirectives((openBlock(),createBlock(unref(bngButton_default),{accent:unref(ACCENTS).text,onClick:_cache[3]||=$event=>navigate$1(`menu.options.display`)},{default:withCtx(()=>[unref(bgRequired)?(openBlock(),createBlock(BlurBackground_default,{key:0})):createCommentVNode(``,!0),createBaseVNode(`div`,_hoisted_14$6,[createBaseVNode(`span`,_hoisted_15$6,toDisplayString(_ctx.$tt(`ui.mainmenu.options`)),1)])]),_:1},8,[`accent`])),[[unref(BngBlur_default),!unref(bgRequired)],[unref(BngSoundClass_default),`bng_click_hover_generic`]]),devEnv.simplemenu?createCommentVNode(``,!0):withDirectives((openBlock(),createBlock(unref(bngButton_default),{key:2,class:`btn-quit`,accent:unref(ACCENTS).attention,icon:unref(icons).exit,onClick:_cache[4]||=$event=>quitGame()},{default:withCtx(()=>[unref(bgRequired)?(openBlock(),createBlock(BlurBackground_default,{key:0})):createCommentVNode(``,!0),createBaseVNode(`div`,_hoisted_16$6,[createBaseVNode(`span`,_hoisted_17$5,toDisplayString(_ctx.$tt(`ui.inputActions.general.quit.title`)),1)])]),_:1},8,[`accent`,`icon`])),[[unref(BngBlur_default),!unref(bgRequired)],[unref(BngSoundClass_default),`bng_click_hover_generic`]])]))])),[[unref(BngOnUiNav_default),handleBack,`back`]])],34)),[[unref(BngScopedNav_default),{activateOnMount:!0,canDeactivate:canDeactivateScope,canBubbleEvent}],[unref(BngOnUiNav_default),handleBack,`menu`]])}}},MainMenu_default=__plugin_vue_export_helper_default(_sfc_main$73,[[`__scopeId`,`data-v-1c7a0195`]]),_hoisted_1$64={key:1,class:`fancy-bg-wrap`},_hoisted_2$53={class:`mask-container`},_hoisted_3$45={key:0,class:`icon-text`},_hoisted_4$33={key:2,class:`tag`},_hoisted_5$28={key:3,class:`icon`},_hoisted_6$22={key:4,class:`icon`},_hoisted_7$20={key:5,class:`label-container`},_hoisted_8$15={class:`text`},_hoisted_9$13={key:6,class:`text`},_sfc_main$72={__name:`MenuButton`,props:{size:{type:String,default:`normal`},iconId:String,icon:String,highlighted:Boolean,disabled:Boolean,appearDisabled:Boolean,bgImg:String,bgImgAbs:String,tag:String,noBlur:Boolean},setup(__props,{expose:__expose}){let props=__props,btnRef=ref(null);__expose({getElement(){return btnRef.value}});let bgImgUrl=computed(()=>props.bgImgAbs?props.bgImgAbs:getAssetURL(props.bgImg)),hasBgImg=computed(()=>props.bgImgAbs||props.bgImg);return(_ctx,_cache)=>withDirectives((openBlock(),createElementBlock(`div`,{ref_key:`btnRef`,ref:btnRef,class:normalizeClass({"mainmenu-button":!0,[`size-${__props.size}`]:!0,"fancy-bg":!!hasBgImg.value,"with-icon":!!__props.iconId,"semi-disabled":__props.appearDisabled}),style:normalizeStyle({"--fancy-bg-img":`url('${bgImgUrl.value}')`}),"bng-nav-item":``},[__props.noBlur?createCommentVNode(``,!0):(openBlock(),createBlock(BlurBackground_default,{key:0,class:normalizeClass(`corners-${__props.size}`)},null,8,[`class`])),createBaseVNode(`div`,{class:normalizeClass([`button-background`,{stack:__props.size===`big-stacked`,highlighted:__props.highlighted}])},null,2),hasBgImg.value?(openBlock(),createElementBlock(`div`,_hoisted_1$64,[createBaseVNode(`div`,{class:normalizeClass([`bg-container`,{"with-icon":!!__props.iconId}])},[_cache[0]||=createBaseVNode(`div`,{class:`bg-image`},null,-1),createBaseVNode(`div`,_hoisted_2$53,[__props.iconId?(openBlock(),createElementBlock(`div`,_hoisted_3$45,toDisplayString(unref(icons)[__props.iconId].glyph),1)):createCommentVNode(``,!0)])],2)])):createCommentVNode(``,!0),__props.tag?(openBlock(),createElementBlock(`div`,_hoisted_4$33,toDisplayString(__props.tag),1)):createCommentVNode(``,!0),__props.iconId&&!hasBgImg.value?(openBlock(),createElementBlock(`div`,_hoisted_5$28,[createVNode(unref(bngIcon_default),{type:unref(icons)[__props.iconId],color:hasBgImg.value?`transparent`:void 0},null,8,[`type`,`color`])])):__props.icon?(openBlock(),createElementBlock(`div`,_hoisted_6$22,[createVNode(unref(bngImageAsset_default),{externalSrc:__props.icon},null,8,[`externalSrc`])])):createCommentVNode(``,!0),__props.size==`big`||__props.size==`big-stacked`?(openBlock(),createElementBlock(`div`,_hoisted_7$20,[createBaseVNode(`span`,_hoisted_8$15,[renderSlot(_ctx.$slots,`default`,{},void 0,!0)])])):(openBlock(),createElementBlock(`span`,_hoisted_9$13,[renderSlot(_ctx.$slots,`default`,{},void 0,!0)]))],6)),[[unref(BngSoundClass_default),!(__props.disabled||__props.appearDisabled)&&`bng_click_hover_generic`],[unref(BngDisabled_default),__props.disabled],[unref(BngBlur_default),!__props.noBlur]])}},MenuButton_default=__plugin_vue_export_helper_default(_sfc_main$72,[[`__scopeId`,`data-v-932e6a9a`]]),_hoisted_1$63={class:`center-wrap`},_hoisted_2$52={class:`primary`},IMG_PATH=`images/mainmenu/`,_sfc_main$71={__name:`MainView`,props:{firstTime:Boolean},emits:[`changeView`],setup(__props,{emit:__emit}){let props=__props,emit$1=__emit;ref(null);let settings$1=useSettings(),defaultWizardStep=computed(()=>settings$1.getValue(`freeroamSetupDefaultStep`)||`level`),firstTime=ref(props.firstTime);onMounted(()=>{firstTime.value&&setTimeout(()=>firstTime.value=!1,1500)});let navigate$1=(state,params=void 0)=>nextTick(()=>window.bngVue.gotoGameState(state,{params}));async function careerPrompt(){await openExperimental($translate.instant(`ui.career.experimentalTitle`),$translate.instant(`ui.career.experimentalPrompt`),[{label:$translate.instant(`ui.common.no`),value:!1,isCancel:!0,extras:{accent:ACCENTS.secondary}},{label:$translate.instant(`ui.career.experimentalAgree`),value:!0,default:!0}])&&navigate$1(`profiles`)}return(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$63,[createBaseVNode(`div`,_hoisted_2$52,[createVNode(MenuButton_default,{"bng-scoped-nav-autofocus":``,size:`big`,"icon-id":`keys1`,"bg-img":IMG_PATH+`experiences.jpg`,onClick:_cache[0]||=$event=>emit$1(`changeView`,`discover`),tag:_ctx.$t(`ui.playmodes.new`)},{default:withCtx(()=>[createTextVNode(toDisplayString(_ctx.$tt(`ui.playmodes.quickStartExperiences`)),1)]),_:1},8,[`bg-img`,`tag`]),createVNode(MenuButton_default,{size:`big`,"icon-id":`road`,"bg-img":IMG_PATH+`freeroam.jpg`,onClick:_cache[1]||=$event=>navigate$1(`menu.freeroamWizard`,{step:defaultWizardStep.value})},{default:withCtx(()=>[createTextVNode(toDisplayString(_ctx.$tt(`ui.playmodes.freeroam`)),1)]),_:1},8,[`bg-img`]),_ctx.$simplemenu.value?createCommentVNode(``,!0):(openBlock(),createBlock(MenuButton_default,{key:0,"appear-disabled":``,size:`big`,"icon-id":`cup`,"bg-img":IMG_PATH+`career.jpg`,onClick:_cache[2]||=$event=>careerPrompt(),tag:_ctx.$t(`ui.playmodes.comingSoon`),"tag-orange":``},{default:withCtx(()=>[createTextVNode(toDisplayString(_ctx.$tt(`ui.playmodes.career`)),1)]),_:1},8,[`bg-img`,`tag`])),createVNode(MenuButton_default,{size:`big-stacked`,"icon-id":`BNGFolder`,"bg-img":IMG_PATH+`others.jpg`,onClick:_cache[3]||=$event=>emit$1(`changeView`,`others`)},{default:withCtx(()=>[createTextVNode(toDisplayString(_ctx.$tt(`ui.mainmenu.more`)),1)]),_:1},8,[`bg-img`])])]))}},MainView_default=__plugin_vue_export_helper_default(_sfc_main$71,[[`__scopeId`,`data-v-0baa6516`]]),_hoisted_1$62={class:`center-wrap`},_hoisted_2$51={class:`others`},_hoisted_3$44={class:`buttons`},htmlBody=`
          `,overlayDiv.textContent=count$1.toString(),overlayElement.appendChild(overlayDiv),overlayDivs.set(element,overlayDiv)}catch{}}function updateOverlayText(){if(!overlayActive||overlayDivs.size===0)return;let appsStats=getUIAppsStats(),counts=appsStats.sortedList.map(item=>item.count),maxCount=Math.max(...counts,1),minCount=Math.min(...counts,0);for(let{element,count:count$1}of appsStats.sortedList){let overlayDiv=overlayDivs.get(element);overlayDiv&&(overlayDiv.textContent=count$1.toString(),overlayDiv.style.opacity=getOverlayOpacity(count$1,minCount,maxCount))}}function destroyOverlay(){overlayUpdateTimer&&=(clearInterval(overlayUpdateTimer),null),overlayDivs.forEach(overlayDiv=>overlayDiv.remove()),overlayDivs.clear(),overlayElement&&=(overlayElement.remove(),null),overlayActive=!1}function toggleOverlay(){return overlayActive?(destroyOverlay(),!1):(overlayActive=!0,createOverlay(),updateOverlayDivs(),overlayUpdateTimer=setInterval(updateOverlayText,500),!0)}function refreshOverlay(){overlayActive&&updateOverlayDivs()}var isBrowser=typeof document<`u`;function isRouteComponent(component){return typeof component==`object`||`displayName`in component||`props`in component||`__vccOpts`in component}function isESModule(obj){return obj.__esModule||obj[Symbol.toStringTag]===`Module`||obj.default&&isRouteComponent(obj.default)}var assign=Object.assign;function applyToParams(fn,params){let newParams={};for(let key in params){let value=params[key];newParams[key]=isArray(value)?value.map(fn):fn(value)}return newParams}var noop$1=()=>{},isArray=Array.isArray;function mergeOptions(defaults,partialOptions){let options={};for(let key in defaults)options[key]=key in partialOptions?partialOptions[key]:defaults[key];return options}var HASH_RE=/#/g,AMPERSAND_RE=/&/g,SLASH_RE=/\//g,EQUAL_RE=/=/g,IM_RE=/\?/g,PLUS_RE=/\+/g,ENC_BRACKET_OPEN_RE=/%5B/g,ENC_BRACKET_CLOSE_RE=/%5D/g,ENC_CARET_RE=/%5E/g,ENC_BACKTICK_RE=/%60/g,ENC_CURLY_OPEN_RE=/%7B/g,ENC_PIPE_RE=/%7C/g,ENC_CURLY_CLOSE_RE=/%7D/g,ENC_SPACE_RE=/%20/g;function commonEncode(text){return text==null?``:encodeURI(``+text).replace(ENC_PIPE_RE,`|`).replace(ENC_BRACKET_OPEN_RE,`[`).replace(ENC_BRACKET_CLOSE_RE,`]`)}function encodeHash(text){return commonEncode(text).replace(ENC_CURLY_OPEN_RE,`{`).replace(ENC_CURLY_CLOSE_RE,`}`).replace(ENC_CARET_RE,`^`)}function encodeQueryValue(text){return commonEncode(text).replace(PLUS_RE,`%2B`).replace(ENC_SPACE_RE,`+`).replace(HASH_RE,`%23`).replace(AMPERSAND_RE,`%26`).replace(ENC_BACKTICK_RE,"`").replace(ENC_CURLY_OPEN_RE,`{`).replace(ENC_CURLY_CLOSE_RE,`}`).replace(ENC_CARET_RE,`^`)}function encodeQueryKey(text){return encodeQueryValue(text).replace(EQUAL_RE,`%3D`)}function encodePath(text){return commonEncode(text).replace(HASH_RE,`%23`).replace(IM_RE,`%3F`)}function encodeParam(text){return encodePath(text).replace(SLASH_RE,`%2F`)}function decode(text){if(text==null)return null;try{return decodeURIComponent(``+text)}catch{}return``+text}var TRAILING_SLASH_RE=/\/$/,removeTrailingSlash=path=>path.replace(TRAILING_SLASH_RE,``);function parseURL(parseQuery$1,location$1,currentLocation=`/`){let path,query={},searchString=``,hash=``,hashPos=location$1.indexOf(`#`),searchPos=location$1.indexOf(`?`);return searchPos=hashPos>=0&&searchPos>hashPos?-1:searchPos,searchPos>=0&&(path=location$1.slice(0,searchPos),searchString=location$1.slice(searchPos,hashPos>0?hashPos:location$1.length),query=parseQuery$1(searchString.slice(1))),hashPos>=0&&(path||=location$1.slice(0,hashPos),hash=location$1.slice(hashPos,location$1.length)),path=resolveRelativePath(path??location$1,currentLocation),{fullPath:path+searchString+hash,path,query,hash:decode(hash)}}function stringifyURL(stringifyQuery$1,location$1){let query=location$1.query?stringifyQuery$1(location$1.query):``;return location$1.path+(query&&`?`)+query+(location$1.hash||``)}function stripBase(pathname,base){return!base||!pathname.toLowerCase().startsWith(base.toLowerCase())?pathname:pathname.slice(base.length)||`/`}function isSameRouteLocation(stringifyQuery$1,a$1,b){let aLastIndex=a$1.matched.length-1,bLastIndex=b.matched.length-1;return aLastIndex>-1&&aLastIndex===bLastIndex&&isSameRouteRecord(a$1.matched[aLastIndex],b.matched[bLastIndex])&&isSameRouteLocationParams(a$1.params,b.params)&&stringifyQuery$1(a$1.query)===stringifyQuery$1(b.query)&&a$1.hash===b.hash}function isSameRouteRecord(a$1,b){return(a$1.aliasOf||a$1)===(b.aliasOf||b)}function isSameRouteLocationParams(a$1,b){if(Object.keys(a$1).length!==Object.keys(b).length)return!1;for(let key in a$1)if(!isSameRouteLocationParamsValue(a$1[key],b[key]))return!1;return!0}function isSameRouteLocationParamsValue(a$1,b){return isArray(a$1)?isEquivalentArray(a$1,b):isArray(b)?isEquivalentArray(b,a$1):a$1===b}function isEquivalentArray(a$1,b){return isArray(b)?a$1.length===b.length&&a$1.every((value,i)=>value===b[i]):a$1.length===1&&a$1[0]===b}function resolveRelativePath(to,from){if(to.startsWith(`/`))return to;if(!to)return from;let fromSegments=from.split(`/`),toSegments=to.split(`/`),lastToSegment=toSegments[toSegments.length-1];(lastToSegment===`..`||lastToSegment===`.`)&&toSegments.push(``);let position=fromSegments.length-1,toPosition,segment;for(toPosition=0;toPosition1&&position--;else break;return fromSegments.slice(0,position).join(`/`)+`/`+toSegments.slice(toPosition).join(`/`)}var START_LOCATION_NORMALIZED={path:`/`,name:void 0,params:{},query:{},hash:``,fullPath:`/`,matched:[],meta:{},redirectedFrom:void 0},NavigationType=function(NavigationType$1){return NavigationType$1.pop=`pop`,NavigationType$1.push=`push`,NavigationType$1}({}),NavigationDirection=function(NavigationDirection$1){return NavigationDirection$1.back=`back`,NavigationDirection$1.forward=`forward`,NavigationDirection$1.unknown=``,NavigationDirection$1}({});function normalizeBase(base){if(!base)if(isBrowser){let baseEl=document.querySelector(`base`);base=baseEl&&baseEl.getAttribute(`href`)||`/`,base=base.replace(/^\w+:\/\/[^\/]+/,``)}else base=`/`;return base[0]!==`/`&&base[0]!==`#`&&(base=`/`+base),removeTrailingSlash(base)}var BEFORE_HASH_RE=/^[^#]+#/;function createHref(base,location$1){return base.replace(BEFORE_HASH_RE,`#`)+location$1}function getElementPosition(el,offset$2){let docRect=document.documentElement.getBoundingClientRect(),elRect=el.getBoundingClientRect();return{behavior:offset$2.behavior,left:elRect.left-docRect.left-(offset$2.left||0),top:elRect.top-docRect.top-(offset$2.top||0)}}var computeScrollPosition=()=>({left:window.scrollX,top:window.scrollY});function scrollToPosition(position){let scrollToOptions;if(`el`in position){let positionEl=position.el,isIdSelector=typeof positionEl==`string`&&positionEl.startsWith(`#`),el=typeof positionEl==`string`?isIdSelector?document.getElementById(positionEl.slice(1)):document.querySelector(positionEl):positionEl;if(!el)return;scrollToOptions=getElementPosition(el,position)}else scrollToOptions=position;`scrollBehavior`in document.documentElement.style?window.scrollTo(scrollToOptions):window.scrollTo(scrollToOptions.left==null?window.scrollX:scrollToOptions.left,scrollToOptions.top==null?window.scrollY:scrollToOptions.top)}function getScrollKey(path,delta){return(history.state?history.state.position-delta:-1)+path}var scrollPositions=new Map;function saveScrollPosition(key,scrollPosition){scrollPositions.set(key,scrollPosition)}function getSavedScrollPosition(key){let scroll$1=scrollPositions.get(key);return scrollPositions.delete(key),scroll$1}function isRouteLocation(route){return typeof route==`string`||route&&typeof route==`object`}function isRouteName(name){return typeof name==`string`||typeof name==`symbol`}var ErrorTypes=function(ErrorTypes$1){return ErrorTypes$1[ErrorTypes$1.MATCHER_NOT_FOUND=1]=`MATCHER_NOT_FOUND`,ErrorTypes$1[ErrorTypes$1.NAVIGATION_GUARD_REDIRECT=2]=`NAVIGATION_GUARD_REDIRECT`,ErrorTypes$1[ErrorTypes$1.NAVIGATION_ABORTED=4]=`NAVIGATION_ABORTED`,ErrorTypes$1[ErrorTypes$1.NAVIGATION_CANCELLED=8]=`NAVIGATION_CANCELLED`,ErrorTypes$1[ErrorTypes$1.NAVIGATION_DUPLICATED=16]=`NAVIGATION_DUPLICATED`,ErrorTypes$1}({}),NavigationFailureSymbol=Symbol(``);ErrorTypes.MATCHER_NOT_FOUND,ErrorTypes.NAVIGATION_GUARD_REDIRECT,ErrorTypes.NAVIGATION_ABORTED,ErrorTypes.NAVIGATION_CANCELLED,ErrorTypes.NAVIGATION_DUPLICATED;function createRouterError(type,params){return assign(Error(),{type,[NavigationFailureSymbol]:!0},params)}function isNavigationFailure(error,type){return error instanceof Error&&NavigationFailureSymbol in error&&(type==null||!!(error.type&type))}function parseQuery(search$1){let query={};if(search$1===``||search$1===`?`)return query;let searchParams=(search$1[0]===`?`?search$1.slice(1):search$1).split(`&`);for(let i=0;iv&&encodeQueryValue(v)):[value&&encodeQueryValue(value)]).forEach(value$1=>{value$1!==void 0&&(search$1+=(search$1.length?`&`:``)+key,value$1!=null&&(search$1+=`=`+value$1))})}return search$1}function normalizeQuery(query){let normalizedQuery={};for(let key in query){let value=query[key];value!==void 0&&(normalizedQuery[key]=isArray(value)?value.map(v=>v==null?null:``+v):value==null?value:``+value)}return normalizedQuery}var matchedRouteKey=Symbol(``),viewDepthKey=Symbol(``),routerKey=Symbol(``),routeLocationKey=Symbol(``),routerViewLocationKey=Symbol(``);function useCallbacks(){let handlers$1=[];function add$2(handler$1){return handlers$1.push(handler$1),()=>{let i=handlers$1.indexOf(handler$1);i>-1&&handlers$1.splice(i,1)}}function reset$1(){handlers$1=[]}return{add:add$2,list:()=>handlers$1.slice(),reset:reset$1}}function guardToPromiseFn(guard,to,from,record,name,runWithContext=fn=>fn()){let enterCallbackArray=record&&(record.enterCallbacks[name]=record.enterCallbacks[name]||[]);return()=>new Promise((resolve$1,reject)=>{let next=valid=>{valid===!1?reject(createRouterError(ErrorTypes.NAVIGATION_ABORTED,{from,to})):valid instanceof Error?reject(valid):isRouteLocation(valid)?reject(createRouterError(ErrorTypes.NAVIGATION_GUARD_REDIRECT,{from:to,to:valid})):(enterCallbackArray&&record.enterCallbacks[name]===enterCallbackArray&&typeof valid==`function`&&enterCallbackArray.push(valid),resolve$1())},guardReturn=runWithContext(()=>guard.call(record&&record.instances[name],to,from,next)),guardCall=Promise.resolve(guardReturn);guard.length<3&&(guardCall=guardCall.then(next)),guardCall.catch(err=>reject(err))})}function extractComponentsGuards(matched,guardType,to,from,runWithContext=fn=>fn()){let guards=[];for(let record of matched)for(let name in record.components){let rawComponent=record.components[name];if(!(guardType!==`beforeRouteEnter`&&!record.instances[name]))if(isRouteComponent(rawComponent)){let guard=(rawComponent.__vccOpts||rawComponent)[guardType];guard&&guards.push(guardToPromiseFn(guard,to,from,record,name,runWithContext))}else{let componentPromise=rawComponent();guards.push(()=>componentPromise.then(resolved=>{if(!resolved)throw Error(`Couldn't resolve component "${name}" at "${record.path}"`);let resolvedComponent=isESModule(resolved)?resolved.default:resolved;record.mods[name]=resolved,record.components[name]=resolvedComponent;let guard=(resolvedComponent.__vccOpts||resolvedComponent)[guardType];return guard&&guardToPromiseFn(guard,to,from,record,name,runWithContext)()}))}}return guards}function extractChangingRecords(to,from){let leavingRecords=[],updatingRecords=[],enteringRecords=[],len=Math.max(from.matched.length,to.matched.length);for(let i=0;iisSameRouteRecord(record,recordFrom))?updatingRecords.push(recordFrom):leavingRecords.push(recordFrom));let recordTo=to.matched[i];recordTo&&(from.matched.find(record=>isSameRouteRecord(record,recordTo))||enteringRecords.push(recordTo))}return[leavingRecords,updatingRecords,enteringRecords]}var createBaseLocation=()=>location.protocol+`//`+location.host;function createCurrentLocation(base,location$1){let{pathname,search:search$1,hash}=location$1,hashPos=base.indexOf(`#`);if(hashPos>-1){let slicePos=hash.includes(base.slice(hashPos))?base.slice(hashPos).length:1,pathFromHash=hash.slice(slicePos);return pathFromHash[0]!==`/`&&(pathFromHash=`/`+pathFromHash),stripBase(pathFromHash,``)}return stripBase(pathname,base)+search$1+hash}function useHistoryListeners(base,historyState,currentLocation,replace){let listeners=[],teardowns=[],pauseState=null,popStateHandler=({state})=>{let to=createCurrentLocation(base,location),from=currentLocation.value,fromState=historyState.value,delta=0;if(state){if(currentLocation.value=to,historyState.value=state,pauseState&&pauseState===from){pauseState=null;return}delta=fromState?state.position-fromState.position:0}else replace(to);listeners.forEach(listener=>{listener(currentLocation.value,from,{delta,type:NavigationType.pop,direction:delta?delta>0?NavigationDirection.forward:NavigationDirection.back:NavigationDirection.unknown})})};function pauseListeners(){pauseState=currentLocation.value}function listen(callback){listeners.push(callback);let teardown=()=>{let index=listeners.indexOf(callback);index>-1&&listeners.splice(index,1)};return teardowns.push(teardown),teardown}function beforeUnloadListener(){if(document.visibilityState===`hidden`){let{history:history$1}=window;if(!history$1.state)return;history$1.replaceState(assign({},history$1.state,{scroll:computeScrollPosition()}),``)}}function destroy$1(){for(let teardown of teardowns)teardown();teardowns=[],window.removeEventListener(`popstate`,popStateHandler),window.removeEventListener(`pagehide`,beforeUnloadListener),document.removeEventListener(`visibilitychange`,beforeUnloadListener)}return window.addEventListener(`popstate`,popStateHandler),window.addEventListener(`pagehide`,beforeUnloadListener),document.addEventListener(`visibilitychange`,beforeUnloadListener),{pauseListeners,listen,destroy:destroy$1}}function buildState(back,current,forward,replaced=!1,computeScroll=!1){return{back,current,forward,replaced,position:window.history.length,scroll:computeScroll?computeScrollPosition():null}}function useHistoryStateNavigation(base){let{history:history$1,location:location$1}=window,currentLocation={value:createCurrentLocation(base,location$1)},historyState={value:history$1.state};historyState.value||changeLocation(currentLocation.value,{back:null,current:currentLocation.value,forward:null,position:history$1.length-1,replaced:!0,scroll:null},!0);function changeLocation(to,state,replace$1){let hashIndex=base.indexOf(`#`),url=hashIndex>-1?(location$1.host&&document.querySelector(`base`)?base:base.slice(hashIndex))+to:createBaseLocation()+base+to;try{history$1[replace$1?`replaceState`:`pushState`](state,``,url),historyState.value=state}catch(err){console.error(err),location$1[replace$1?`replace`:`assign`](url)}}function replace(to,data){changeLocation(to,assign({},history$1.state,buildState(historyState.value.back,to,historyState.value.forward,!0),data,{position:historyState.value.position}),!0),currentLocation.value=to}function push(to,data){let currentState=assign({},historyState.value,history$1.state,{forward:to,scroll:computeScrollPosition()});changeLocation(currentState.current,currentState,!0),changeLocation(to,assign({},buildState(currentLocation.value,to,null),{position:currentState.position+1},data),!1),currentLocation.value=to}return{location:currentLocation,state:historyState,push,replace}}function createWebHistory(base){base=normalizeBase(base);let historyNavigation=useHistoryStateNavigation(base),historyListeners=useHistoryListeners(base,historyNavigation.state,historyNavigation.location,historyNavigation.replace);function go(delta,triggerListeners=!0){triggerListeners||historyListeners.pauseListeners(),history.go(delta)}let routerHistory=assign({location:``,base,go,createHref:createHref.bind(null,base)},historyNavigation,historyListeners);return Object.defineProperty(routerHistory,`location`,{enumerable:!0,get:()=>historyNavigation.location.value}),Object.defineProperty(routerHistory,`state`,{enumerable:!0,get:()=>historyNavigation.state.value}),routerHistory}function createWebHashHistory(base){return base=location.host?base||location.pathname+location.search:``,base.includes(`#`)||(base+=`#`),createWebHistory(base)}var TokenType=function(TokenType$1){return TokenType$1[TokenType$1.Static=0]=`Static`,TokenType$1[TokenType$1.Param=1]=`Param`,TokenType$1[TokenType$1.Group=2]=`Group`,TokenType$1}({}),TokenizerState=function(TokenizerState$1){return TokenizerState$1[TokenizerState$1.Static=0]=`Static`,TokenizerState$1[TokenizerState$1.Param=1]=`Param`,TokenizerState$1[TokenizerState$1.ParamRegExp=2]=`ParamRegExp`,TokenizerState$1[TokenizerState$1.ParamRegExpEnd=3]=`ParamRegExpEnd`,TokenizerState$1[TokenizerState$1.EscapeNext=4]=`EscapeNext`,TokenizerState$1}(TokenizerState||{}),ROOT_TOKEN={type:TokenType.Static,value:``},VALID_PARAM_RE=/[a-zA-Z0-9_]/;function tokenizePath(path){if(!path)return[[]];if(path===`/`)return[[ROOT_TOKEN]];if(!path.startsWith(`/`))throw Error(`Invalid path "${path}"`);function crash(message){throw Error(`ERR (${state})/"${buffer$1}": ${message}`)}let state=TokenizerState.Static,previousState=state,tokens=[],segment;function finalizeSegment(){segment&&tokens.push(segment),segment=[]}let i=0,char,buffer$1=``,customRe=``;function consumeBuffer(){buffer$1&&=(state===TokenizerState.Static?segment.push({type:TokenType.Static,value:buffer$1}):state===TokenizerState.Param||state===TokenizerState.ParamRegExp||state===TokenizerState.ParamRegExpEnd?(segment.length>1&&(char===`*`||char===`+`)&&crash(`A repeatable param (${buffer$1}) must be alone in its segment. eg: '/:ids+.`),segment.push({type:TokenType.Param,value:buffer$1,regexp:customRe,repeatable:char===`*`||char===`+`,optional:char===`*`||char===`?`})):crash(`Invalid state to consume buffer`),``)}function addCharToBuffer(){buffer$1+=char}for(;ib.length?b.length===1&&b[0]===PathScore.Static+PathScore.Segment?1:-1:0}function comparePathParserScore(a$1,b){let i=0,aScore=a$1.score,bScore=b.score;for(;i0&&last[last.length-1]<0}var PATH_PARSER_OPTIONS_DEFAULTS={strict:!1,end:!0,sensitive:!1};function createRouteRecordMatcher(record,parent,options){let matcher=assign(tokensToParser(tokenizePath(record.path),options),{record,parent,children:[],alias:[]});return parent&&!matcher.record.aliasOf==!parent.record.aliasOf&&parent.children.push(matcher),matcher}function createRouterMatcher(routes,globalOptions){let matchers=[],matcherMap=new Map;globalOptions=mergeOptions(PATH_PARSER_OPTIONS_DEFAULTS,globalOptions);function getRecordMatcher(name){return matcherMap.get(name)}function addRoute(record,parent,originalRecord){let isRootAdd=!originalRecord,mainNormalizedRecord=normalizeRouteRecord(record);mainNormalizedRecord.aliasOf=originalRecord&&originalRecord.record;let options=mergeOptions(globalOptions,record),normalizedRecords=[mainNormalizedRecord];if(`alias`in record){let aliases=typeof record.alias==`string`?[record.alias]:record.alias;for(let alias of aliases)normalizedRecords.push(normalizeRouteRecord(assign({},mainNormalizedRecord,{components:originalRecord?originalRecord.record.components:mainNormalizedRecord.components,path:alias,aliasOf:originalRecord?originalRecord.record:mainNormalizedRecord})))}let matcher,originalMatcher;for(let normalizedRecord of normalizedRecords){let{path}=normalizedRecord;if(parent&&path[0]!==`/`){let parentPath=parent.record.path,connectingSlash=parentPath[parentPath.length-1]===`/`?``:`/`;normalizedRecord.path=parent.record.path+(path&&connectingSlash+path)}if(matcher=createRouteRecordMatcher(normalizedRecord,parent,options),originalRecord?originalRecord.alias.push(matcher):(originalMatcher||=matcher,originalMatcher!==matcher&&originalMatcher.alias.push(matcher),isRootAdd&&record.name&&!isAliasRecord(matcher)&&removeRoute(record.name)),isMatchable(matcher)&&insertMatcher(matcher),mainNormalizedRecord.children){let children=mainNormalizedRecord.children;for(let i=0;i{removeRoute(originalMatcher)}:noop$1}function removeRoute(matcherRef){if(isRouteName(matcherRef)){let matcher=matcherMap.get(matcherRef);matcher&&(matcherMap.delete(matcherRef),matchers.splice(matchers.indexOf(matcher),1),matcher.children.forEach(removeRoute),matcher.alias.forEach(removeRoute))}else{let index=matchers.indexOf(matcherRef);index>-1&&(matchers.splice(index,1),matcherRef.record.name&&matcherMap.delete(matcherRef.record.name),matcherRef.children.forEach(removeRoute),matcherRef.alias.forEach(removeRoute))}}function getRoutes(){return matchers}function insertMatcher(matcher){let index=findInsertionIndex(matcher,matchers);matchers.splice(index,0,matcher),matcher.record.name&&!isAliasRecord(matcher)&&matcherMap.set(matcher.record.name,matcher)}function resolve$1(location$1,currentLocation){let matcher,params={},path,name;if(`name`in location$1&&location$1.name){if(matcher=matcherMap.get(location$1.name),!matcher)throw createRouterError(ErrorTypes.MATCHER_NOT_FOUND,{location:location$1});name=matcher.record.name,params=assign(pickParams(currentLocation.params,matcher.keys.filter(k=>!k.optional).concat(matcher.parent?matcher.parent.keys.filter(k=>k.optional):[]).map(k=>k.name)),location$1.params&&pickParams(location$1.params,matcher.keys.map(k=>k.name))),path=matcher.stringify(params)}else if(location$1.path!=null)path=location$1.path,matcher=matchers.find(m=>m.re.test(path)),matcher&&(params=matcher.parse(path),name=matcher.record.name);else{if(matcher=currentLocation.name?matcherMap.get(currentLocation.name):matchers.find(m=>m.re.test(currentLocation.path)),!matcher)throw createRouterError(ErrorTypes.MATCHER_NOT_FOUND,{location:location$1,currentLocation});name=matcher.record.name,params=assign({},currentLocation.params,location$1.params),path=matcher.stringify(params)}let matched=[],parentMatcher=matcher;for(;parentMatcher;)matched.unshift(parentMatcher.record),parentMatcher=parentMatcher.parent;return{name,path,params,matched,meta:mergeMetaFields(matched)}}routes.forEach(route=>addRoute(route));function clearRoutes(){matchers.length=0,matcherMap.clear()}return{addRoute,resolve:resolve$1,removeRoute,clearRoutes,getRoutes,getRecordMatcher}}function pickParams(params,keys){let newParams={};for(let key of keys)key in params&&(newParams[key]=params[key]);return newParams}function normalizeRouteRecord(record){let normalized={path:record.path,redirect:record.redirect,name:record.name,meta:record.meta||{},aliasOf:record.aliasOf,beforeEnter:record.beforeEnter,props:normalizeRecordProps(record),children:record.children||[],instances:{},leaveGuards:new Set,updateGuards:new Set,enterCallbacks:{},components:`components`in record?record.components||null:record.component&&{default:record.component}};return Object.defineProperty(normalized,`mods`,{value:{}}),normalized}function normalizeRecordProps(record){let propsObject={},props=record.props||!1;if(`component`in record)propsObject.default=props;else for(let name in record.components)propsObject[name]=typeof props==`object`?props[name]:props;return propsObject}function isAliasRecord(record){for(;record;){if(record.record.aliasOf)return!0;record=record.parent}return!1}function mergeMetaFields(matched){return matched.reduce((meta,record)=>assign(meta,record.meta),{})}function findInsertionIndex(matcher,matchers){let lower=0,upper=matchers.length;for(;lower!==upper;){let mid=lower+upper>>1;comparePathParserScore(matcher,matchers[mid])<0?upper=mid:lower=mid+1}let insertionAncestor=getInsertionAncestor(matcher);return insertionAncestor&&(upper=matchers.lastIndexOf(insertionAncestor,upper-1)),upper}function getInsertionAncestor(matcher){let ancestor=matcher;for(;ancestor=ancestor.parent;)if(isMatchable(ancestor)&&comparePathParserScore(matcher,ancestor)===0)return ancestor}function isMatchable({record}){return!!(record.name||record.components&&Object.keys(record.components).length||record.redirect)}function useLink(props){let router$1=inject(routerKey),currentRoute=inject(routeLocationKey),route=computed(()=>{let to=unref(props.to);return router$1.resolve(to)}),activeRecordIndex=computed(()=>{let{matched}=route.value,{length}=matched,routeMatched=matched[length-1],currentMatched=currentRoute.matched;if(!routeMatched||!currentMatched.length)return-1;let index=currentMatched.findIndex(isSameRouteRecord.bind(null,routeMatched));if(index>-1)return index;let parentRecordPath=getOriginalPath(matched[length-2]);return length>1&&getOriginalPath(routeMatched)===parentRecordPath&¤tMatched[currentMatched.length-1].path!==parentRecordPath?currentMatched.findIndex(isSameRouteRecord.bind(null,matched[length-2])):index}),isActive=computed(()=>activeRecordIndex.value>-1&&includesParams(currentRoute.params,route.value.params)),isExactActive=computed(()=>activeRecordIndex.value>-1&&activeRecordIndex.value===currentRoute.matched.length-1&&isSameRouteLocationParams(currentRoute.params,route.value.params));function navigate$1(e={}){if(guardEvent(e)){let p$1=router$1[unref(props.replace)?`replace`:`push`](unref(props.to)).catch(noop$1);return props.viewTransition&&typeof document<`u`&&`startViewTransition`in document&&document.startViewTransition(()=>p$1),p$1}return Promise.resolve()}return{route,href:computed(()=>route.value.href),isActive,isExactActive,navigate:navigate$1}}function preferSingleVNode(vnodes){return vnodes.length===1?vnodes[0]:vnodes}var RouterLink=defineComponent({name:`RouterLink`,compatConfig:{MODE:3},props:{to:{type:[String,Object],required:!0},replace:Boolean,activeClass:String,exactActiveClass:String,custom:Boolean,ariaCurrentValue:{type:String,default:`page`},viewTransition:Boolean},useLink,setup(props,{slots}){let link=reactive(useLink(props)),{options}=inject(routerKey),elClass=computed(()=>({[getLinkClass(props.activeClass,options.linkActiveClass,`router-link-active`)]:link.isActive,[getLinkClass(props.exactActiveClass,options.linkExactActiveClass,`router-link-exact-active`)]:link.isExactActive}));return()=>{let children=slots.default&&preferSingleVNode(slots.default(link));return props.custom?children:h(`a`,{"aria-current":link.isExactActive?props.ariaCurrentValue:null,href:link.href,onClick:link.navigate,class:elClass.value},children)}}});function guardEvent(e){if(!(e.metaKey||e.altKey||e.ctrlKey||e.shiftKey)&&!e.defaultPrevented&&!(e.button!==void 0&&e.button!==0)){if(e.currentTarget&&e.currentTarget.getAttribute){let target=e.currentTarget.getAttribute(`target`);if(/\b_blank\b/i.test(target))return}return e.preventDefault&&e.preventDefault(),!0}}function includesParams(outer,inner){for(let key in inner){let innerValue=inner[key],outerValue=outer[key];if(typeof innerValue==`string`){if(innerValue!==outerValue)return!1}else if(!isArray(outerValue)||outerValue.length!==innerValue.length||innerValue.some((value,i)=>value!==outerValue[i]))return!1}return!0}function getOriginalPath(record){return record?record.aliasOf?record.aliasOf.path:record.path:``}var getLinkClass=(propClass,globalClass,defaultClass)=>propClass??globalClass??defaultClass,RouterViewImpl=defineComponent({name:`RouterView`,inheritAttrs:!1,props:{name:{type:String,default:`default`},route:Object},compatConfig:{MODE:3},setup(props,{attrs,slots}){let injectedRoute=inject(routerViewLocationKey),routeToDisplay=computed(()=>props.route||injectedRoute.value),injectedDepth=inject(viewDepthKey,0),depth=computed(()=>{let initialDepth=unref(injectedDepth),{matched}=routeToDisplay.value,matchedRoute;for(;(matchedRoute=matched[initialDepth])&&!matchedRoute.components;)initialDepth++;return initialDepth}),matchedRouteRef=computed(()=>routeToDisplay.value.matched[depth.value]);provide(viewDepthKey,computed(()=>depth.value+1)),provide(matchedRouteKey,matchedRouteRef),provide(routerViewLocationKey,routeToDisplay);let viewRef=ref();return watch(()=>[viewRef.value,matchedRouteRef.value,props.name],([instance$1,to,name],[oldInstance,from,oldName])=>{to&&(to.instances[name]=instance$1,from&&from!==to&&instance$1&&instance$1===oldInstance&&(to.leaveGuards.size||(to.leaveGuards=from.leaveGuards),to.updateGuards.size||(to.updateGuards=from.updateGuards))),instance$1&&to&&(!from||!isSameRouteRecord(to,from)||!oldInstance)&&(to.enterCallbacks[name]||[]).forEach(callback=>callback(instance$1))},{flush:`post`}),()=>{let route=routeToDisplay.value,currentName=props.name,matchedRoute=matchedRouteRef.value,ViewComponent=matchedRoute&&matchedRoute.components[currentName];if(!ViewComponent)return normalizeSlot(slots.default,{Component:ViewComponent,route});let routePropsOption=matchedRoute.props[currentName],component=h(ViewComponent,assign({},routePropsOption?routePropsOption===!0?route.params:typeof routePropsOption==`function`?routePropsOption(route):routePropsOption:null,attrs,{onVnodeUnmounted:vnode=>{vnode.component.isUnmounted&&(matchedRoute.instances[currentName]=null)},ref:viewRef}));return normalizeSlot(slots.default,{Component:component,route})||component}}});function normalizeSlot(slot,data){if(!slot)return null;let slotContent=slot(data);return slotContent.length===1?slotContent[0]:slotContent}var RouterView=RouterViewImpl;function createRouter(options){let matcher=createRouterMatcher(options.routes,options),parseQuery$1=options.parseQuery||parseQuery,stringifyQuery$1=options.stringifyQuery||stringifyQuery,routerHistory=options.history,beforeGuards=useCallbacks(),beforeResolveGuards=useCallbacks(),afterGuards=useCallbacks(),currentRoute=shallowRef(START_LOCATION_NORMALIZED),pendingLocation=START_LOCATION_NORMALIZED;isBrowser&&options.scrollBehavior&&`scrollRestoration`in history&&(history.scrollRestoration=`manual`);let normalizeParams=applyToParams.bind(null,paramValue=>``+paramValue),encodeParams=applyToParams.bind(null,encodeParam),decodeParams=applyToParams.bind(null,decode);function addRoute(parentOrRoute,route){let parent,record;return isRouteName(parentOrRoute)?(parent=matcher.getRecordMatcher(parentOrRoute),record=route):record=parentOrRoute,matcher.addRoute(record,parent)}function removeRoute(name){let recordMatcher=matcher.getRecordMatcher(name);recordMatcher&&matcher.removeRoute(recordMatcher)}function getRoutes(){return matcher.getRoutes().map(routeMatcher=>routeMatcher.record)}function hasRoute(name){return!!matcher.getRecordMatcher(name)}function resolve$1(rawLocation,currentLocation){if(currentLocation=assign({},currentLocation||currentRoute.value),typeof rawLocation==`string`){let locationNormalized=parseURL(parseQuery$1,rawLocation,currentLocation.path),matchedRoute$1=matcher.resolve({path:locationNormalized.path},currentLocation),href$1=routerHistory.createHref(locationNormalized.fullPath);return assign(locationNormalized,matchedRoute$1,{params:decodeParams(matchedRoute$1.params),hash:decode(locationNormalized.hash),redirectedFrom:void 0,href:href$1})}let matcherLocation;if(rawLocation.path!=null)matcherLocation=assign({},rawLocation,{path:parseURL(parseQuery$1,rawLocation.path,currentLocation.path).path});else{let targetParams=assign({},rawLocation.params);for(let key in targetParams)targetParams[key]??delete targetParams[key];matcherLocation=assign({},rawLocation,{params:encodeParams(targetParams)}),currentLocation.params=encodeParams(currentLocation.params)}let matchedRoute=matcher.resolve(matcherLocation,currentLocation),hash=rawLocation.hash||``;matchedRoute.params=normalizeParams(decodeParams(matchedRoute.params));let fullPath=stringifyURL(stringifyQuery$1,assign({},rawLocation,{hash:encodeHash(hash),path:matchedRoute.path})),href=routerHistory.createHref(fullPath);return assign({fullPath,hash,query:stringifyQuery$1===stringifyQuery?normalizeQuery(rawLocation.query):rawLocation.query||{}},matchedRoute,{redirectedFrom:void 0,href})}function locationAsObject(to){return typeof to==`string`?parseURL(parseQuery$1,to,currentRoute.value.path):assign({},to)}function checkCanceledNavigation(to,from){if(pendingLocation!==to)return createRouterError(ErrorTypes.NAVIGATION_CANCELLED,{from,to})}function push(to){return pushWithRedirect(to)}function replace(to){return push(assign(locationAsObject(to),{replace:!0}))}function handleRedirectRecord(to,from){let lastMatched=to.matched[to.matched.length-1];if(lastMatched&&lastMatched.redirect){let{redirect}=lastMatched,newTargetLocation=typeof redirect==`function`?redirect(to,from):redirect;return typeof newTargetLocation==`string`&&(newTargetLocation=newTargetLocation.includes(`?`)||newTargetLocation.includes(`#`)?newTargetLocation=locationAsObject(newTargetLocation):{path:newTargetLocation},newTargetLocation.params={}),assign({query:to.query,hash:to.hash,params:newTargetLocation.path==null?to.params:{}},newTargetLocation)}}function pushWithRedirect(to,redirectedFrom){let targetLocation=pendingLocation=resolve$1(to),from=currentRoute.value,data=to.state,force=to.force,replace$1=to.replace===!0,shouldRedirect=handleRedirectRecord(targetLocation,from);if(shouldRedirect)return pushWithRedirect(assign(locationAsObject(shouldRedirect),{state:typeof shouldRedirect==`object`?assign({},data,shouldRedirect.state):data,force,replace:replace$1}),redirectedFrom||targetLocation);let toLocation=targetLocation;toLocation.redirectedFrom=redirectedFrom;let failure;return!force&&isSameRouteLocation(stringifyQuery$1,from,targetLocation)&&(failure=createRouterError(ErrorTypes.NAVIGATION_DUPLICATED,{to:toLocation,from}),handleScroll(from,from,!0,!1)),(failure?Promise.resolve(failure):navigate$1(toLocation,from)).catch(error=>isNavigationFailure(error)?isNavigationFailure(error,ErrorTypes.NAVIGATION_GUARD_REDIRECT)?error:markAsReady(error):triggerError(error,toLocation,from)).then(failure$1=>{if(failure$1){if(isNavigationFailure(failure$1,ErrorTypes.NAVIGATION_GUARD_REDIRECT))return pushWithRedirect(assign({replace:replace$1},locationAsObject(failure$1.to),{state:typeof failure$1.to==`object`?assign({},data,failure$1.to.state):data,force}),redirectedFrom||toLocation)}else failure$1=finalizeNavigation(toLocation,from,!0,replace$1,data);return triggerAfterEach(toLocation,from,failure$1),failure$1})}function checkCanceledNavigationAndReject(to,from){let error=checkCanceledNavigation(to,from);return error?Promise.reject(error):Promise.resolve()}function runWithContext(fn){let app$1=installedApps.values().next().value;return app$1&&typeof app$1.runWithContext==`function`?app$1.runWithContext(fn):fn()}function navigate$1(to,from){let guards,[leavingRecords,updatingRecords,enteringRecords]=extractChangingRecords(to,from);guards=extractComponentsGuards(leavingRecords.reverse(),`beforeRouteLeave`,to,from);for(let record of leavingRecords)record.leaveGuards.forEach(guard=>{guards.push(guardToPromiseFn(guard,to,from))});let canceledNavigationCheck=checkCanceledNavigationAndReject.bind(null,to,from);return guards.push(canceledNavigationCheck),runGuardQueue(guards).then(()=>{guards=[];for(let guard of beforeGuards.list())guards.push(guardToPromiseFn(guard,to,from));return guards.push(canceledNavigationCheck),runGuardQueue(guards)}).then(()=>{guards=extractComponentsGuards(updatingRecords,`beforeRouteUpdate`,to,from);for(let record of updatingRecords)record.updateGuards.forEach(guard=>{guards.push(guardToPromiseFn(guard,to,from))});return guards.push(canceledNavigationCheck),runGuardQueue(guards)}).then(()=>{guards=[];for(let record of enteringRecords)if(record.beforeEnter)if(isArray(record.beforeEnter))for(let beforeEnter of record.beforeEnter)guards.push(guardToPromiseFn(beforeEnter,to,from));else guards.push(guardToPromiseFn(record.beforeEnter,to,from));return guards.push(canceledNavigationCheck),runGuardQueue(guards)}).then(()=>(to.matched.forEach(record=>record.enterCallbacks={}),guards=extractComponentsGuards(enteringRecords,`beforeRouteEnter`,to,from,runWithContext),guards.push(canceledNavigationCheck),runGuardQueue(guards))).then(()=>{guards=[];for(let guard of beforeResolveGuards.list())guards.push(guardToPromiseFn(guard,to,from));return guards.push(canceledNavigationCheck),runGuardQueue(guards)}).catch(err=>isNavigationFailure(err,ErrorTypes.NAVIGATION_CANCELLED)?err:Promise.reject(err))}function triggerAfterEach(to,from,failure){afterGuards.list().forEach(guard=>runWithContext(()=>guard(to,from,failure)))}function finalizeNavigation(toLocation,from,isPush,replace$1,data){let error=checkCanceledNavigation(toLocation,from);if(error)return error;let isFirstNavigation=from===START_LOCATION_NORMALIZED,state=isBrowser?history.state:{};isPush&&(replace$1||isFirstNavigation?routerHistory.replace(toLocation.fullPath,assign({scroll:isFirstNavigation&&state&&state.scroll},data)):routerHistory.push(toLocation.fullPath,data)),currentRoute.value=toLocation,handleScroll(toLocation,from,isPush,isFirstNavigation),markAsReady()}let removeHistoryListener;function setupListeners(){removeHistoryListener||=routerHistory.listen((to,_from,info)=>{if(!router$1.listening)return;let toLocation=resolve$1(to),shouldRedirect=handleRedirectRecord(toLocation,router$1.currentRoute.value);if(shouldRedirect){pushWithRedirect(assign(shouldRedirect,{replace:!0,force:!0}),toLocation).catch(noop$1);return}pendingLocation=toLocation;let from=currentRoute.value;isBrowser&&saveScrollPosition(getScrollKey(from.fullPath,info.delta),computeScrollPosition()),navigate$1(toLocation,from).catch(error=>isNavigationFailure(error,ErrorTypes.NAVIGATION_ABORTED|ErrorTypes.NAVIGATION_CANCELLED)?error:isNavigationFailure(error,ErrorTypes.NAVIGATION_GUARD_REDIRECT)?(pushWithRedirect(assign(locationAsObject(error.to),{force:!0}),toLocation).then(failure=>{isNavigationFailure(failure,ErrorTypes.NAVIGATION_ABORTED|ErrorTypes.NAVIGATION_DUPLICATED)&&!info.delta&&info.type===NavigationType.pop&&routerHistory.go(-1,!1)}).catch(noop$1),Promise.reject()):(info.delta&&routerHistory.go(-info.delta,!1),triggerError(error,toLocation,from))).then(failure=>{failure||=finalizeNavigation(toLocation,from,!1),failure&&(info.delta&&!isNavigationFailure(failure,ErrorTypes.NAVIGATION_CANCELLED)?routerHistory.go(-info.delta,!1):info.type===NavigationType.pop&&isNavigationFailure(failure,ErrorTypes.NAVIGATION_ABORTED|ErrorTypes.NAVIGATION_DUPLICATED)&&routerHistory.go(-1,!1)),triggerAfterEach(toLocation,from,failure)}).catch(noop$1)})}let readyHandlers=useCallbacks(),errorListeners=useCallbacks(),ready;function triggerError(error,to,from){markAsReady(error);let list=errorListeners.list();return list.length?list.forEach(handler$1=>handler$1(error,to,from)):console.error(error),Promise.reject(error)}function isReady(){return ready&¤tRoute.value!==START_LOCATION_NORMALIZED?Promise.resolve():new Promise((resolve$1$1,reject)=>{readyHandlers.add([resolve$1$1,reject])})}function markAsReady(err){return ready||(ready=!err,setupListeners(),readyHandlers.list().forEach(([resolve$1$1,reject])=>err?reject(err):resolve$1$1()),readyHandlers.reset()),err}function handleScroll(to,from,isPush,isFirstNavigation){let{scrollBehavior}=options;if(!isBrowser||!scrollBehavior)return Promise.resolve();let scrollPosition=!isPush&&getSavedScrollPosition(getScrollKey(to.fullPath,0))||(isFirstNavigation||!isPush)&&history.state&&history.state.scroll||null;return nextTick().then(()=>scrollBehavior(to,from,scrollPosition)).then(position=>position&&scrollToPosition(position)).catch(err=>triggerError(err,to,from))}let go=delta=>routerHistory.go(delta),started,installedApps=new Set,router$1={currentRoute,listening:!0,addRoute,removeRoute,clearRoutes:matcher.clearRoutes,hasRoute,getRoutes,resolve:resolve$1,options,push,replace,go,back:()=>go(-1),forward:()=>go(1),beforeEach:beforeGuards.add,beforeResolve:beforeResolveGuards.add,afterEach:afterGuards.add,onError:errorListeners.add,isReady,install(app$1){app$1.component(`RouterLink`,RouterLink),app$1.component(`RouterView`,RouterView),app$1.config.globalProperties.$router=router$1,Object.defineProperty(app$1.config.globalProperties,`$route`,{enumerable:!0,get:()=>unref(currentRoute)}),isBrowser&&!started&¤tRoute.value===START_LOCATION_NORMALIZED&&(started=!0,push(routerHistory.location).catch(err=>{}));let reactiveRoute={};for(let key in START_LOCATION_NORMALIZED)Object.defineProperty(reactiveRoute,key,{get:()=>currentRoute.value[key],enumerable:!0});app$1.provide(routerKey,router$1),app$1.provide(routeLocationKey,shallowReactive(reactiveRoute)),app$1.provide(routerViewLocationKey,currentRoute);let unmountApp=app$1.unmount;installedApps.add(app$1),app$1.unmount=function(){installedApps.delete(app$1),installedApps.size<1&&(pendingLocation=START_LOCATION_NORMALIZED,removeHistoryListener&&removeHistoryListener(),removeHistoryListener=null,currentRoute.value=START_LOCATION_NORMALIZED,started=!1,ready=!1),unmountApp()}}};function runGuardQueue(guards){return guards.reduce((promise,guard)=>promise.then(()=>runWithContext(guard)),Promise.resolve())}return router$1}function useRouter(){return inject(routerKey)}function useRoute(_name){return inject(routeLocationKey)}function spawnUiApp(appName,appId,params,apps){let props=params?params.props:null,appKey=`${appName}${appId}`;apps.push({name:appName,appId,appKey,comp:appName,props,teleport:`#${appName+appId}`})}function destroyUiApp(appName,apps){let index=apps.findIndex(x=>x.name===appName);index>-1&&apps.splice(index,1)}function registerApps(app$1,componentsMap){Object.keys(componentsMap).forEach(key=>app$1.component(key,componentsMap[key]))}var _sfc_main$325={};function _sfc_render$5(_ctx,_cache){return null}var layoutEmpty_default=__plugin_vue_export_helper_default(_sfc_main$325,[[`render`,_sfc_render$5]]);const LAYOUT_ALIGNMENTS={left:`flex-start`,right:`flex-end`,center:`center`};var _sfc_main$324={},_hoisted_1$287={class:`layout-wrapper layout-safezones`},_hoisted_2$235={class:`layout-content`};function _sfc_render$4(_ctx,_cache,$props,$setup,$data,$options){return openBlock(),createElementBlock(`div`,_hoisted_1$287,[createBaseVNode(`div`,_hoisted_2$235,[renderSlot(_ctx.$slots,`default`,{},()=>[_cache[0]||=createTextVNode(`Content here`,-1)])])])}var layoutSingle_default=__plugin_vue_export_helper_default(_sfc_main$324,[[`render`,_sfc_render$4]]);const useEvents=(onDispose=onBeforeUnmount)=>{let bridge$4=useBridge(),events$3={_on:{},_once:{},on(name,func){name in events$3._on||(events$3._on[name]=[]),events$3._on[name].indexOf(func)===-1&&(bridge$4.events.on(name,func),events$3._on[name].push(func))},once(name,func){name in events$3._once||(events$3._once[name]=[]),events$3._once[name].indexOf(func)===-1&&(bridge$4.events.once(name,()=>{let idx=events$3._once[name].indexOf(func);idx>-1&&events$3._once[name].splice(idx,1)}),bridge$4.events.once(name,func),events$3._once[name].push(func))},off(name=void 0,func=void 0){if(!name){for(let name$1 in events$3._on){for(let func$1 of events$3._on[name$1])bridge$4.events.off(name$1,func$1);delete events$3._on[name$1]}return}if(name in events$3._on)if(func){let idx=events$3._on[name].indexOf(func);idx>-1&&(bridge$4.events.off(name,func),events$3._on[name].splice(idx,1)),events$3._on[name].length===0&&delete events$3._on[name]}else{for(let func$1 of events$3._on[name])bridge$4.events.off(name,func$1);delete events$3._on[name]}},emit(name,...values){bridge$4.events.emit(name,...values)}};return onDispose(()=>{for(let type of[`_on`,`_once`])for(let name in events$3[type]){for(let func of events$3[type][name])bridge$4.events.off(name,func);delete events$3[type][name]}}),events$3},useStreams=(names,callback,onDispose=onBeforeUnmount)=>{let bridge$4=useBridge(),enabled=!1,streams={on(){enabled||(enabled=!0,bridge$4.streams.add(names),bridge$4.events.on(`onStreamsUpdate`,callback))},off(){enabled&&(enabled=!1,bridge$4.streams.remove(names),bridge$4.events.off(`onStreamsUpdate`,callback))}};return streams.on(),onDispose(streams.off),streams};var hints_default=`ui.hints.quickSteerResponse,ui.hints.raceBrakesEffectiveness,ui.hints.quickCameraMovement,ui.hints.grabVehicleParts,ui.hints.funStabilityControl,ui.hints.recoverVehicle,ui.hints.oldCarsBurn,ui.hints.smokingWheels,ui.hints.carsBurnFuel,ui.hints.delicateCars,ui.hints.stabilityControlPresent,ui.hints.absWasOptional,ui.hints.installRollCage,ui.hints.spatialNavigation,ui.hints.repairHood,ui.hints.slowMotionPhysics,ui.hints.removeRearSeats,ui.hints.tuning,ui.hints.customLicensePlate,ui.hints.driveAtNight,ui.hints.moonGravity,ui.hints.unlockExtraFunctionality,ui.hints.playMultiseat,ui.hints.increaseGroundClearance,ui.hints.tiresBurstOnBumps,ui.hints.blueSmokeIsPistonDamage,ui.hints.keepTheEngineUpright,ui.hints.thermalDebugApp,ui.hints.rollPitchApps,ui.hints.cruiseControlApp,ui.hints.driveTheCanon,ui.hints.vehicleSkins,ui.hints.toggleMods,ui.hints.importveFramerate,ui.hints.photoModeMenu,ui.hints.publishScreenshots,ui.hints.towTrailer,ui.hints.brakesAndSteeringVary,ui.hints.countersteerEarly,ui.hints.startSlow,ui.hints.parkingbrakeForTurning,ui.hints.carefulWithOldSportsCars,ui.hints.corneringWithKeyboard,ui.hints.adaptToBadRoads,ui.hints.notAllCarsCanRace,ui.hints.changeBrakePads,ui.hints.useTurnSignals,ui.hints.showStandalonePcs,ui.hints.tweakFOV,ui.hints.driveWithMouse,ui.hints.liftOffOversteer,ui.hints.snapOversteer,ui.hints.slideBackWithParkingBrake,ui.hints.customizeSpecializedBindings,ui.hints.toggleFogLights,ui.hints.toggleLightBars,ui.hints.TrackIRSupported,ui.hints.chooseShiftingMode,ui.hints.saveRestoreVehicleHome,ui.hints.switchVehicle,ui.hints.coolantVaporizes,ui.hints.dontRunIntoTheCar`.split(`,`),_hoisted_1$286={key:0,class:`progress-box`},_hoisted_2$234={class:`progress-icon-group`},_hoisted_3$208={class:`progress-bar-container`},_hoisted_4$178={class:`progress-status`},_hoisted_5$153={class:`progress-history`},_hoisted_6$132={class:`custom-left-container`},_hoisted_7$118={key:0,class:`custom-text-panel`},_hoisted_8$99={key:1,class:`text`},_hoisted_9$89={key:1,class:`custom-indeterminate-panel`},_hoisted_10$77={class:`custom-right-container`},_hoisted_11$69={key:2,class:`tips-bar`},_hoisted_12$57={class:`tips-bar-title`},_hoisted_13$49={class:`tips-bar-tip`},_hoisted_14$44={key:0,class:`loading-cache`},_hoisted_15$42=[`src`],imagesAmount=18,activeRepeatTime=1e4,fadeInDefault=1e3,fadeOutDefault=2e3,_sfc_main$323={__name:`LoadingScreen`,setup(__props){useCssVars(_ctx=>({v79c091d8:fadeInTimeVar.value,v07559aed:fadeOutTimeVar.value}));let events$3=useEvents(),{lua}=useBridge(),navBlocker=useUINavBlocker(),lastImageNum=-1,repeatTimer=null,customTimer=null,iconsList=[{id:`terrain`,icon:icons.terrain},{id:`environment`,icon:icons.water},{id:`forest`,icon:icons.trafficCone},{id:`meshes`,icon:icons.garage01},{id:`roads`,icon:icons.road},{id:`beamng`,icon:icons.beamNG}],state=reactive({active:!1,visible:!1,fading:!1,shown:!1,autoActivate:!0,highSeas:!1,mode:`progress`,image:null,iconState:{},currentEntries:[],historyEntriesDisplay:[],customContent:null,fadeInTime:fadeInDefault,fadeOutTime:fadeOutDefault,customPause:-1});function resetState(){state.mode=`progress`,state.customContent=null,state.iconState={},state.currentEntries=[],state.historyEntriesDisplay=[],state.fadeInTime=fadeInDefault,state.fadeOutTime=fadeOutDefault,state.customPause=-1}let tip=ref(``),setTip=(txt=void 0,_retrying=!1)=>{let idx=~~(Math.random()*hints_default.length);tip.value=txt||hints_default[idx],(!tip.value||tip.value===`undefined`)&&(logger_default.debug(`Loading Screen tip is undefined!\nARG: ${JSON.stringify(txt)} TIP: ${JSON.stringify(tip.value)} IDX: ${idx}/${hints_default.length}`),_retrying?tip.value=``:setTip(void 0,!0))},fadeInTimeVar=computed(()=>state.fadeInTime+`ms`),fadeOutTimeVar=computed(()=>state.fadeOutTime+`ms`),progressValue=computed(()=>state.currentEntries[0]?.progress||0),currentStatus=computed(()=>state.currentEntries[0]?.message||``);events$3.on(`LoadingScreen`,data=>{if(window.beamng?.ingame){if((!data||typeof data!=`object`)&&(data={}),state.autoActivate=!1,state.active=!!data.active,data.custom&&(state.mode=`custom`,state.fadeInTime=data.custom.fadeIn>0?data.custom.fadeIn*1e3:state.fadeInTime||0,state.fadeOutTime=data.custom.fadeOut>0?data.custom.fadeOut*1e3:state.fadeOutTime||0),state.active)data.custom?(state.customPause=data.custom.pause?data.custom.pause*1e3:-1,state.customContent=data.custom.data,state.customContent?.image&&(state.image=state.customContent.image)):(resetState(),window.bngVue.gotoAngularState(`blank`)),setTip(state.customContent?.tips);else if(state.mode===`progress`&&`gotoMainMenu`in data){let args=[];data.gotoMainMenu?args.push(`menu.mainmenu`):args.push(`menu`,[`loading`]),window.globalAngularRootScope?.$broadcast(`ChangeState`,...args),window.vueEventBus?.emit(`onChangeState`,...args)}}}),events$3.on(`UpdateLoadingProgressV2`,data=>{if(!window.beamng?.ingame||!state.autoActivate&&!state.active)return;let{currentEntries,historyEntries}=data;(!currentEntries||!Array.isArray(currentEntries))&&(currentEntries=[]),(!historyEntries||!Array.isArray(historyEntries))&&(historyEntries=[]),state.currentEntries=currentEntries,state.historyEntriesDisplay=historyEntries.slice(Math.max(historyEntries.length-3,1)),state.iconState={};for(let{name,progress}of currentEntries)state.iconState[name.toLowerCase()]=progress;for(let{name}of historyEntries)state.iconState[name.toLowerCase()]=100;state.autoActivate&&(state.active=currentEntries.length>0||historyEntries.length>0)});let onFadeIn=()=>{state.fading=!1,state.mode===`progress`?(lua.core_gamestate.loadingScreenActive(),repeatTimer=setTimeout(()=>{lua.core_gamestate.loadingScreenActive()},activeRepeatTime)):state.mode===`custom`&&(lua.extensions.ui_fadeScreen.onScreenFadeStateDelayed(1),state.customPause!==-1&&(customTimer=setTimeout(()=>{lua.extensions.ui_fadeScreen.onScreenFadeStateDelayed(2)},state.customPause*1e3)))},onFadeOut=()=>{state.fading=!1,state.shown=!1,state.mode===`custom`&&lua.extensions.ui_fadeScreen.onScreenFadeStateDelayed(3),resetState(),loadNextImage()};watch(()=>state.active,(newActive,oldActive)=>{window.beamng?.ingame&&(newActive&&!oldActive?activateLoading():!newActive&&oldActive&&deactivateLoading())});let activateLoading=()=>{state.active&&(deactivateLoading.cancel(),navBlocker.allowOnly([]),nextTick(()=>{state.visible=!0,state.fading=!0,state.shown=!0}))},deactivateLoading=debounce(()=>{state.active||(clearTimers(),navBlocker.clear(),nextTick(()=>{state.visible=!1,state.fading=!0}))},100),getRandomImageNum=()=>{let rnd=~~(Math.random()*imagesAmount)+1;return rnd===lastImageNum?getRandomImageNum():(lastImageNum=rnd,rnd)},getNextImageUrl=()=>{let url;return url=state.highSeas?`images/mainmenu/unofficial_version.jpg`:`images/loading/drive/${getRandomImageNum()}.jpg`,getAssetURL(url)},loadNextImage=async()=>{let url=getNextImageUrl();state.image!==url&&(await loadImage$1(url),state.image=url)},loadImage$1=url=>new Promise((resolve$1,reject)=>{let img=new Image;img.onload=()=>resolve$1(url),img.onerror=()=>reject(url),img.src=url}),clearTimers=()=>{repeatTimer&&=(clearTimeout(repeatTimer),null),customTimer&&=(clearTimeout(customTimer),null)},initLoadingScreen=()=>bngApi.engineLua(`sailingTheHighSeas`,async ahoy=>{state.highSeas=ahoy===!0,await loadNextImage(),setTip(),lua.core_gamestate.loadingScreenActive(),window.loadingTest=active=>{events$3.emit(`LoadingScreen`,{active})}});return onMounted(()=>{linkLoadingScreenState(state),initLoadingScreen()}),onUnmounted(()=>clearTimers()),(_ctx,_cache)=>(openBlock(),createElementBlock(Fragment,null,[createVNode(Transition,{name:`loading-fade`,onAfterEnter:onFadeIn,onAfterLeave:onFadeOut},{default:withCtx(()=>[state.visible?(openBlock(),createElementBlock(`dialog`,{key:0,open:``,class:normalizeClass([`loading-screen`,`loading-screen-${state.mode}`])},[createBaseVNode(`div`,{class:`loading-background`,style:normalizeStyle({backgroundImage:state.image?`url('${state.image}')`:`none`})},null,4),state.mode===`progress`?(openBlock(),createElementBlock(`div`,_hoisted_1$286,[createBaseVNode(`div`,_hoisted_2$234,[(openBlock(),createElementBlock(Fragment,null,renderList(iconsList,iconInfo=>createBaseVNode(`div`,{key:iconInfo.id,class:`progress-icon-box`,style:normalizeStyle({backgroundPosition:`0 ${state.iconState[iconInfo.id]||0}%`})},[createVNode(unref(bngIcon_default),{type:iconInfo.icon,color:`#fff`,class:`progress-icon`},null,8,[`type`])],4)),64))]),createBaseVNode(`div`,_hoisted_3$208,[createVNode(unref(bngProgressBar_default),{class:`progress-bar`,gradient:``,"show-value-label":!1,min:0,max:100,value:progressValue.value},null,8,[`value`])]),createBaseVNode(`div`,_hoisted_4$178,toDisplayString(currentStatus.value||_ctx.$tt(`ui.common.loading`)),1),createBaseVNode(`div`,_hoisted_5$153,[(openBlock(!0),createElementBlock(Fragment,null,renderList(state.historyEntriesDisplay,(item,idx)=>(openBlock(),createElementBlock(`div`,{key:idx},toDisplayString(item.message),1))),128))])])):createCommentVNode(``,!0),state.mode===`custom`?(openBlock(),createElementBlock(`div`,{key:1,class:normalizeClass([`custom-box`,{"custom-with-tips":state.customContent?.tips}])},[createBaseVNode(`div`,_hoisted_6$132,[state.customContent&&(state.customContent.title||state.customContent.text)?(openBlock(),createElementBlock(`div`,_hoisted_7$118,[state.customContent.title?(openBlock(),createBlock(unref(bngScreenHeading_default),{key:0,preheadings:[_ctx.$tt(state.customContent.subtitle)]},{default:withCtx(()=>[createTextVNode(toDisplayString(_ctx.$tt(state.customContent.title)),1)]),_:1},8,[`preheadings`])):createCommentVNode(``,!0),state.customContent.text?(openBlock(),createElementBlock(`p`,_hoisted_8$99,[createVNode(unref(dynamicComponent_default),{"translate-id":state.customContent.text,bbcode:``,"translate-context":``},null,8,[`translate-id`])])):createCommentVNode(``,!0)])):(openBlock(),createElementBlock(`div`,_hoisted_9$89,[createVNode(unref(bngScreenHeading_default),null,{default:withCtx(()=>[createTextVNode(toDisplayString(_ctx.$tt(`ui.common.loading.short`)),1)]),_:1}),createVNode(unref(bngProgressBar_default),{class:`progress-bar`,gradient:``,"show-value-label":!1,min:0,max:100,indeterminate:``})]))]),createBaseVNode(`div`,_hoisted_10$77,[state.customContent&&state.customContent.image?(openBlock(),createElementBlock(`div`,{key:0,class:`custom-image-panel`,style:normalizeStyle({backgroundImage:`url('${state.customContent.image}')`})},null,4)):createCommentVNode(``,!0)])],2)):createCommentVNode(``,!0),state.mode===`progress`||state.customContent?.tips?(openBlock(),createElementBlock(`div`,_hoisted_11$69,[createBaseVNode(`div`,_hoisted_12$57,toDisplayString(_ctx.$tt(`ui.loadingScreen.tips`))+`:`,1),createBaseVNode(`div`,_hoisted_13$49,[createVNode(unref(dynamicComponent_default),{"translate-id":tip.value,bbcode:``},null,8,[`translate-id`])])])):createCommentVNode(``,!0)],2)):createCommentVNode(``,!0)]),_:1}),state.image?(openBlock(),createElementBlock(`div`,_hoisted_14$44,[createBaseVNode(`img`,{src:state.image,alt:``},null,8,_hoisted_15$42)])):createCommentVNode(``,!0)],64))}},LoadingScreen_default=__plugin_vue_export_helper_default(_sfc_main$323,[[`__scopeId`,`data-v-2f135df0`]]),_hoisted_1$285={class:`pause-button-wrapper`},_sfc_main$322={__name:`pauseButton`,props:{teleportTo:[String,Object]},setup(__props){let route=useRoute(),events$3=useEvents(),gameContext=useGameContextStore(),isGamePaused=ref(!1),physicsMaybePaused=ref(!1),replayActive=ref(!1),replayPaused=ref(!1);events$3.on(`physicsStateChanged`,state=>{physicsMaybePaused.value=!state}),events$3.on(`replayStateChanged`,core_replay=>{replayActive.value=core_replay.state===`playback`,replayPaused.value=replayActive.value&&core_replay.paused}),events$3.on(`simTimeAuthority.pauseStateChanged`,data=>{isGamePaused.value=data.paused});let isInMenu=computed(()=>route.name?.startsWith(`menu`)&&!gameContext.activities?.length&&sysInfo_default.gameState.value!==void 0&&sysInfo_default.gameState.value!==`loading`),isPhysicsPaused=computed(()=>physicsMaybePaused.value),isReplayPaused=computed(()=>replayActive.value&&replayPaused.value),showPauseButton=computed(()=>isInMenu.value||isPhysicsPaused.value||isReplayPaused.value),isPaused=computed(()=>isGamePaused.value||isPhysicsPaused.value||isReplayPaused.value),buttonState=computed(()=>isInMenu.value&&isPaused.value?`menu-paused`:isInMenu.value?`menu`:isPaused.value?`paused`:`default`),togglePause=()=>{Lua_default.simTimeAuthority.togglePause()};return(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$285,[(openBlock(),createBlock(Teleport,{disabled:!__props.teleportTo,to:__props.teleportTo},[withDirectives((openBlock(),createBlock(unref(bngButton_default),{class:normalizeClass([`pause-button`,buttonState.value]),accent:unref(ACCENTS).custom,"no-sound":``,onClick:togglePause,"bng-no-nav":``},{default:withCtx(()=>[createVNode(unref(bngBinding_default),{class:`pause-button-binding-bg`,action:`pause`}),createVNode(unref(bngIcon_default),{class:`pause-button-icon`,type:isPaused.value?unref(icons).pause:unref(icons).play},null,8,[`type`])]),_:1},8,[`class`,`accent`])),[[vShow,showPauseButton.value],[unref(BngTooltip_default),_ctx.$tt(`ui.inputActions.general.pause.title`),void 0,{bottom:!0}]])],8,[`disabled`,`to`]))]))}},pauseButton_default=__plugin_vue_export_helper_default(_sfc_main$322,[[`__scopeId`,`data-v-ea9a26b4`]]),UIAppStorage,setupDone;const useUIApps=()=>(setupDone||setup(),service);var setup=()=>{UIAppStorage||=window.UIAppStorage,setupDone=!!UIAppStorage},setLayout=layoutName=>{layoutName==`blank`?_broadcast(`appContainer:clear`):_broadcast(`appContainer:loadLayoutByType`,layoutName)},setVisible=state=>{_broadcast(`ShowApps`,!!state)},service={setLayout,setVisible,get currentLayout(){return UIAppStorage.currentLayout}},_broadcast=(...params)=>{window.globalAngularRootScope&&window.globalAngularRootScope.$broadcast(...params)},_sfc_main$321={};function _sfc_render$3(_ctx,_cache){return openBlock(),createElementBlock(`span`)}var NotFound_default=__plugin_vue_export_helper_default(_sfc_main$321,[[`render`,_sfc_render$3]]);function useGridSelector(backendName=`gridSelector`,defaultPath={keys:[`missions`]},defaultDetailsMode=`detail`){let currentPath=ref(defaultPath),previousPath=ref(null),groups=ref([]),filterList=ref([]),filterByProp=ref([]),commonFilters=ref([]),lockedFiltersByProp=ref([]),activeFilters=ref([]),onlyCommonFilters=ref(!0),detailsMode=ref(defaultDetailsMode),selectedItem=ref(null),selectedItemDetails=ref(null),prevSelectedItem=ref(null),previewItem=ref(null),previewItemDetails=ref(null),managementDetails=ref(null),autoFocusKey=ref(null),showScreenHeader=ref(!0),screenHeaderTitle=ref(`Grid Selector`),screenHeaderPath=ref([{text:`Menu`,gotoAngularState:`menu`}]),{events:events$3}=useBridge(),backFromDetailsCallback=null,refreshAllHandler=backendName$1=>{backendName$1===backendName$1&&(logger_default.debug(`gridSelectorRefreshAll`),loadTiles(),loadFilters(),loadManagementDetails())},refreshCurrentItemDetailsHandler=backendName$1=>{backendName$1===backendName$1&&(logger_default.debug(`gridSelectorRefreshCurrentItemDetails`),setSelectedItem(selectedItem.value))};events$3.on(`gridSelectorRefreshAll`,refreshAllHandler),events$3.on(`gridSelectorRefreshCurrentItemDetails`,refreshCurrentItemDetailsHandler);let log=(...args)=>{},displayData=ref([]),searchText$1=ref(``);async function getSearchText(){try{let data=await Lua_default.ui_gridSelector.getSearchText(backendName);return searchText$1.value=data||``,data||``}catch(error){return logger_default.error(`Failed to get search text:`,error),``}}async function setSearchText(value){try{await Lua_default.ui_gridSelector.setSearchText(backendName,value),searchText$1.value=value||``,await loadTiles(),await loadFilters(),await updateScreenHeaderData()}catch(error){logger_default.error(`Failed to set search text:`,error)}}let isInitializing=ref(!1),safeArray=arr=>Array.isArray(arr)?arr:[];async function setCurrentPath(path){currentPath.value=path,await loadTiles()}async function loadTiles(){currentPath.value;try{let data=await Lua_default.ui_gridSelector.getTiles(backendName,currentPath.value,previousPath.value!==currentPath.value);if(Lua_default.ui_gridSelector.profilerFinish(backendName,`received lua data on UI`),groups.value=safeArray(data),groups.value,!selectedItem.value&&(detailsMode.value===`advanced`||detailsMode.value===`detail`)&&previousPath.value!==currentPath.value)for(let group of groups.value)for(let tile of group.tiles)tile.isDefaultSelected&&(autoFocusKey.value=tile.key,tile.name,tile.forceAutoFocus&&backFromDetailsCallback());previousPath.value=currentPath.value,Lua_default.ui_gridSelector.profilerFinish(backendName,`loaded tiles into reactive state`)}catch(error){logger_default.error(`Failed to load tiles:`,error)}}async function loadFilters(){try{let data=await Lua_default.ui_gridSelector.getFilters(backendName);filterList.value=safeArray(data.filterList),filterByProp.value=data.filterByProp,commonFilters.value=safeArray(data.commonFilters)||[],lockedFiltersByProp.value=data.lockedFiltersByProp||[],activeFilters.value=safeArray(data.activeFilters),onlyCommonFilters.value=data.onlyCommonFilters,filterList.value,filterByProp.value,activeFilters.value,onlyCommonFilters.value}catch(error){logger_default.error(`Failed to load filters:`,error)}}async function loadManagementDetails(){try{managementDetails.value=await Lua_default.ui_gridSelector.getManagementDetails(backendName),managementDetails.value}catch(error){logger_default.error(`Failed to load management details:`,error)}}async function toggleFilter(propName,option){try{await Lua_default.ui_gridSelector.toggleFilter(backendName,propName,option),await loadFilters(),await loadTiles(),await updateScreenHeaderData()}catch(error){logger_default.error(`Failed to toggle filter:`,error)}}async function updateRangeFilter(propName,min$1,max$1){try{await Lua_default.ui_gridSelector.updateRangeFilter(backendName,propName,min$1,max$1),await loadFilters(),await loadTiles(),await updateScreenHeaderData()}catch(error){logger_default.error(`Failed to update range filter:`,error)}}async function resetRangeFilter(propName){console.log(`Resetting range filter:`,propName);try{await Lua_default.ui_gridSelector.resetRangeFilter(backendName,propName),await loadFilters(),await loadTiles(),await updateScreenHeaderData()}catch(error){logger_default.error(`Failed to reset range filter:`,error)}}async function resetSetFilter(propName){try{await Lua_default.ui_gridSelector.resetSetFilter(backendName,propName),await loadFilters(),await loadTiles(),await updateScreenHeaderData()}catch(error){logger_default.error(`Failed to reset set filter:`,error)}}async function loadDisplayData(){try{displayData.value=safeArray(await Lua_default.ui_gridSelector.getDisplayDataOptions(backendName));let searchOption=displayData.value.find(option=>option.key===`searchText`);searchOption&&(searchText$1.value=searchOption.value||``),displayData.value}catch(error){logger_default.error(`Failed to load display data:`,error)}}async function updateDisplayData(key,value){try{await Lua_default.ui_gridSelector.setDisplayDataOption(backendName,key,value),await loadDisplayData(),await loadTiles(),await updateScreenHeaderData()}catch(error){logger_default.error(`Failed to update display data:`,error)}}async function resetDisplayDataToDefaults(){try{await Lua_default.ui_gridSelector.resetDisplayDataToDefaults(backendName),await loadDisplayData(),await loadTiles(),await updateScreenHeaderData()}catch(error){logger_default.error(`Failed to reset display data to defaults:`,error)}}function setDetailsMode(mode){detailsMode.value=mode}async function setSelectedItem(item){if(!item||!item.showDetails){autoFocusKey.value=null,selectedItem.value=null,selectedItemDetails.value=null,await loadManagementDetails();return}try{item.showDetails;let details=await Lua_default.ui_gridSelector.getDetails(backendName,item.showDetails);autoFocusKey.value=item.key,selectedItem.value=item,selectedItemDetails.value=details,details?.paintData&&details?.paints&&selectedItemDetails.value?.paints&&(selectedItemDetails.value.paints.multiPaintSetups=safeArray(selectedItemDetails.value.paints.multiPaintSetups),selectedItemDetails.value.paints.factoryPaints=safeArray(selectedItemDetails.value.paints.factoryPaints)),setDetailsMode(`detail`)}catch(error){logger_default.error(`Failed to get item details:`,error),autoFocusKey.value=null,selectedItem.value=item,selectedItemDetails.value=null}}async function clearSelectedItem(){selectedItem.value=null,selectedItemDetails.value=null,await loadManagementDetails()}async function setPreviewItem(item){if(!item||!item.showDetails){previewItem.value=null,previewItemDetails.value=null;return}try{let details=await Lua_default.ui_gridSelector.getDetails(backendName,item.showDetails);previewItem.value=item,previewItemDetails.value=details,setDetailsMode(`detail`)}catch{previewItem.value=item,previewItemDetails.value=null}}function clearPreviewItem(){previewItem.value=null,previewItemDetails.value=null}let activeItem=computed(()=>selectedItem.value||previewItem.value),activeItemDetails=computed(()=>selectedItem.value?selectedItemDetails.value:previewItemDetails.value);async function executeButton(buttonId,additionalData){try{if(additionalData?.waitForLoadingScreen)window.vueEventBus?.emit(`LoadingScreen`,{active:!0}),await startLoading(async()=>{await waitForLoadingScreenFadeIn();let data=await Lua_default.ui_gridSelector.executeButton(backendName,buttonId,additionalData);data&&data.gotoPath&&setCurrentPath(data.gotoPath)});else{let data=await Lua_default.ui_gridSelector.executeButton(backendName,buttonId,additionalData);data&&data.gotoPath&&setCurrentPath(data.gotoPath)}}catch(error){logger_default.error(`Failed to execute button:`,error)}}let executeButtonHandler=(backendName$1,buttonId,additionalData)=>{backendName$1===backendName$1&&executeButton(buttonId,additionalData)};events$3.on(`gridSelectorExecuteButton`,executeButtonHandler);async function toggleFavourite(item){await Lua_default.ui_gridSelector.toggleFavourite(backendName,item.showDetails);let details=await Lua_default.ui_gridSelector.getDetails(backendName,item.showDetails);selectedItem.value=item,selectedItemDetails.value=details,await loadTiles()}function clearSearch(){setSearchText(``)}function updateSearch(newSearchText){setSearchText(newSearchText||``)}function commitSearch(){setSearchText(searchText$1.value||``)}function isFilterLocked(propName,option=null){return lockedFiltersByProp.value[propName]?option?lockedFiltersByProp.value[propName][option]!==void 0:Object.keys(lockedFiltersByProp.value[propName]).length>0:!1}async function updateScreenHeaderData(){try{let headerData=await Lua_default.ui_gridSelector.getScreenHeaderTitleAndPath(backendName,currentPath.value);screenHeaderTitle.value=headerData.title||`Grid Selector`,screenHeaderPath.value=headerData.pathSegments}catch(error){logger_default.error(`Failed to update screen header title:`,error),screenHeaderTitle.value=`Grid Selector`,screenHeaderPath.value=[{text:`Menu`,gotoAngularState:`menu`}]}}function isFilterOptionLocked(propName,option){return isFilterLocked(propName,option)}function isRangeFilterLocked(propName){return isFilterLocked(propName)}watch(currentPath,()=>{clearSelectedItem(),clearPreviewItem(),updateScreenHeaderData()}),watch([filterByProp,activeFilters],()=>{clearSelectedItem(),clearPreviewItem(),updateScreenHeaderData()}),watch(displayData,()=>{updateScreenHeaderData()},{deep:!0});function notifyUIReady(tag){Lua_default.ui_gridSelector.profilerFinish(backendName,tag)}function setOnBackFromDetailsCallback(callback){backFromDetailsCallback=callback}async function initialize(){if(!isInitializing.value)try{isInitializing.value=!0,await Promise.all([loadFilters(),loadDisplayData(),loadManagementDetails(),getSearchText()])}catch(error){logger_default.error(`Failed to initialize GridSelector composable:`,error)}finally{isInitializing.value=!1}}return onUnmounted(()=>{logger_default.debug(`GridSelector composable unmounting`),events$3.off(`gridSelectorRefreshAll`,refreshAllHandler),events$3.off(`gridSelectorRefreshCurrentItemDetails`,refreshCurrentItemDetailsHandler),events$3.off(`gridSelectorExecuteButton`,executeButtonHandler)}),{groups,filterList,filterByProp,lockedFiltersByProp,commonFilters,activeFilters,onlyCommonFilters,displayData,currentPath,detailsMode,selectedItem,selectedItemDetails,prevSelectedItem,previewItem,previewItemDetails,activeItem,activeItemDetails,managementDetails,isInitializing,searchText:searchText$1,getSearchText,setSearchText,autoFocusKey,showScreenHeader,screenHeaderTitle,screenHeaderPath,initialize,setCurrentPath,loadTiles,loadFilters,loadManagementDetails,toggleFilter,updateRangeFilter,resetRangeFilter,resetSetFilter,loadDisplayData,updateDisplayData,resetDisplayDataToDefaults,setDetailsMode,setSelectedItem,clearSelectedItem,setPreviewItem,clearPreviewItem,executeButton,notifyUIReady,isFilterLocked,isFilterOptionLocked,isRangeFilterLocked,toggleFavourite,clearSearch,updateSearch,commitSearch,updateScreenHeaderData,exploreFolder:function(path){Lua_default.ui_gridSelector.exploreFolder(backendName,path)},goToMod:function(modId){Lua_default.ui_gridSelector.goToMod(backendName,modId)},setOnBackFromDetailsCallback}}var _hoisted_1$284=[`bng-scoped-nav-autofocus`],_hoisted_2$233={class:`image-container`},_hoisted_3$207={key:0,class:`sub-element-count-badge`},_hoisted_4$177={class:`item-label`},_hoisted_5$152={class:`item-name`},_hoisted_6$131={class:`icons-container`},_hoisted_7$117=[`src`],_hoisted_8$98={key:0,class:`sub-element-count-badge`},_hoisted_9$88={key:1},sizes={tiny:{width:7.5,margin:.5,fontSize:.8},small:{width:9.5,margin:.5,fontSize:1},medium:{width:12,margin:.5,fontSize:1},large:{width:16,margin:.5,fontSize:1},huge:{width:20,margin:.5,fontSize:1.5},list:{width:22,height:3,margin:.5,fontSize:.9}},thumbAspectRatio=16/9.5,captionHeightEm=2,getSizeCalc=displaySize=>ctx=>{let size$3=sizes[displaySize]||sizes.medium;if(displaySize===`list`)return{width:size$3.width,height:size$3.height,margin:size$3.margin};let height$1=size$3.width/thumbAspectRatio+size$3.fontSize*captionHeightEm-size$3.margin*2;return{width:size$3.width,height:height$1,margin:size$3.margin}},__default__$6={getSizeCalc},_sfc_main$320=Object.assign(__default__$6,{__name:`Tile`,props:{tile:{type:Object,required:!0},isFavourite:Boolean,isConfig:Boolean,displaySize:String,tileImagesTopAligned:{type:Boolean,default:!1}},emits:[`focus`,`blur`,`click`,`dblclick`],setup(__props,{expose:__expose,emit:__emit}){let{showIfController}=storeToRefs(controls_default()),props=__props,gridSelectionState=inject(`gridSelectionState`,null),state=computed(()=>{let res={selected:!1,dimmed:!1,isAutoFocused:!1};return gridSelectionState&&gridSelectionState.value&&(res.selected=gridSelectionState.value.inDetails&&gridSelectionState.value.activeItemKey===props.tile.key,res.dimmed=showIfController.value&&gridSelectionState.value.inDetails&&gridSelectionState.value.activeItemKey!==props.tile.key,res.isAutoFocused=gridSelectionState.value.autoFocusKey===props.tile.key),res}),emit$1=__emit,elTile=ref(null);__expose({getElement:()=>elTile.value});let isListItem=computed(()=>props.displaySize===`list`);function onClick(){emit$1(`click`)}function onFocus(){emit$1(`focus`)}function onBlur(){emit$1(`blur`)}return(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,{class:normalizeClass([`tile-wrapper`,`tile-size-${__props.displaySize}`]),style:normalizeStyle({"--tile-font-size":sizes[__props.displaySize].fontSize+`em`})},[_cache[0]||=createBaseVNode(`div`,{class:`tile-bg`},null,-1),withDirectives((openBlock(),createElementBlock(`div`,{ref_key:`elTile`,ref:elTile,"bng-scoped-nav-autofocus":state.value.isAutoFocused,class:normalizeClass({tile:!0,selected:state.value.selected,dimmed:state.value.dimmed,auxiliary:__props.tile.isAuxiliary,"is-career-only":__props.tile.isCareerOnly}),onClick:withModifiers(onClick,[`stop`]),onFocus,onBlur,"bng-nav-item":``},[createBaseVNode(`div`,_hoisted_2$233,[createVNode(unref(bngImage_default),{class:normalizeClass([`item-image`,{"top-aligned":__props.tileImagesTopAligned}]),src:__props.tile.preview},null,8,[`class`,`src`]),isListItem.value?createCommentVNode(``,!0):(openBlock(),createElementBlock(Fragment,{key:0},[!__props.isConfig&&__props.tile.subElementCount>=1?(openBlock(),createElementBlock(`div`,_hoisted_3$207,toDisplayString(__props.tile.subElementCount),1)):createCommentVNode(``,!0),__props.isFavourite||__props.tile.showFavouriteIconPercent>=1?(openBlock(),createBlock(unref(bngIcon_default),{key:1,class:`favorite-indicator`,type:`star`})):createCommentVNode(``,!0)],64))]),createBaseVNode(`div`,_hoisted_4$177,[createBaseVNode(`span`,_hoisted_5$152,toDisplayString(__props.tile.name),1),createBaseVNode(`div`,_hoisted_6$131,[__props.tile.sourceIcons?(openBlock(!0),createElementBlock(Fragment,{key:0},renderList(__props.tile.sourceIcons,sourceIcon=>(openBlock(),createElementBlock(Fragment,{key:sourceIcon},[sourceIcon.icon?(openBlock(),createBlock(unref(bngIcon_default),{key:0,type:sourceIcon.icon,class:`source-icon`,color:`var(--bng-cool-gray-100)`},null,8,[`type`])):createCommentVNode(``,!0),sourceIcon.svg?(openBlock(),createElementBlock(`img`,{key:1,class:`svg-icon`,src:sourceIcon.svg,alt:``},null,8,_hoisted_7$117)):createCommentVNode(``,!0)],64))),128)):createCommentVNode(``,!0),isListItem.value&&__props.tile.showFavouriteIconPercent>0?(openBlock(),createBlock(unref(bngIcon_default),{key:1,class:`favorite-indicator`,type:__props.tile.showFavouriteIconPercent>=1?`star`:`starSecondary`},null,8,[`type`])):createCommentVNode(``,!0)]),isListItem.value&&!__props.isConfig&&__props.tile.subElementCount>=1?(openBlock(),createElementBlock(`span`,_hoisted_8$98,toDisplayString(__props.tile.subElementCount),1)):isListItem.value?(openBlock(),createElementBlock(`span`,_hoisted_9$88)):createCommentVNode(``,!0)])],42,_hoisted_1$284)),[[unref(BngOnUiNav_default),void 0,`ok`,{focusRequired:!0,asMouse:!0,bubble:!0}],[unref(BngSoundClass_default),`bng_click_hover_generic`],[unref(BngDoubleClick_default),__props.tile.doubleClickDetails?()=>emit$1(`dblclick`):null,__props.tile.doubleClickMode]])],6))}}),Tile_default=__plugin_vue_export_helper_default(_sfc_main$320,[[`__scopeId`,`data-v-51fd3377`]]),_hoisted_1$283={class:`group-header`,"bng-list-title":``},_sfc_main$319={__name:`GroupHeader`,props:{label:{type:String,required:!0}},setup(__props){return(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$283,[createVNode(bngCardHeading_default,{class:`header-label`},{default:withCtx(()=>[createTextVNode(toDisplayString(__props.label),1)]),_:1}),_cache[0]||=createBaseVNode(`div`,{class:`header-line`},null,-1)]))}},GroupHeader_default=__plugin_vue_export_helper_default(_sfc_main$319,[[`__scopeId`,`data-v-28596ef8`]]),_sfc_main$318={__name:`Grid`,props:{autoFocusKey:{type:String,default:null},activeItem:{type:Object,default:null},groups:{type:Array,required:!0},isConfig:{type:Boolean,default:!1},displaySize:{type:String,default:`medium`,validator:value=>[`tiny`,`small`,`medium`,`large`,`huge`,`list`].includes(value)},inDetails:{type:Boolean,default:!1},backendName:{type:String,default:`gridSelector`},tileImagesTopAligned:{type:Boolean,default:!1},doubleClickOverride:{type:Function,default:null}},emits:[`select-item`,`deselect-item`,`focus-item`],setup(__props,{emit:__emit}){let{showIfController}=storeToRefs(controls_default()),props=__props,emit$1=__emit,gridListRef=ref(),containerWidth=ref(0),baseFontSize=ref(16),tileSizeCalc=ctx=>Tile_default.getSizeCalc(props.displaySize)(ctx),maxTilesPerRow=computed(()=>{if(!containerWidth.value)return 1/0;let size$3=Tile_default.getSizeCalc(props.displaySize)({}),tileWidthPx=(size$3.width+size$3.margin)*baseFontSize.value;return(Math.floor(containerWidth.value/tileWidthPx)||1)*(props.displaySize===`list`?2:1)}),limitedGroups=computed(()=>props.groups.map(group=>({...group,tiles:group.isRecentGroup?group.tiles.slice(0,maxTilesPerRow.value):group.tiles}))),updateContainerWidth=()=>{gridListRef.value?.$el&&(containerWidth.value=gridListRef.value.$el.clientWidth,baseFontSize.value=parseFloat(getComputedStyle(document.documentElement).fontSize)||16)},resizeObserver;onMounted(()=>{updateContainerWidth(),gridListRef.value?.$el&&(resizeObserver=new ResizeObserver(debounce(updateContainerWidth,100)),resizeObserver.observe(gridListRef.value.$el))}),onUnmounted(()=>{resizeObserver&&resizeObserver.disconnect()}),provide(`gridSelectionState`,computed(()=>({inDetails:props.inDetails,activeItemKey:props.activeItem?.key||null,autoFocusKey:props.autoFocusKey})));let focusItem=tile=>{props.inDetails||(showIfController.value&&preselectItem(tile),emit$1(`focus-item`,tile))},selectItem=tile=>{preselectItem.cancel(),emit$1(`select-item`,tile)},preselectItem=debounce(tile=>emit$1(`select-item`,tile,!1),200),handleDoubleClick=async item=>{if(console.log(`handleDoubleClick`,item),item.doubleClickDetails)try{props.doubleClickOverride?props.doubleClickOverride(item):await Lua_default.ui_gridSelector.executeDoubleClick(props.backendName,item.doubleClickDetails)}catch(error){console.error(`Failed to execute double click:`,error)}};return(_ctx,_cache)=>(openBlock(),createBlock(unref(bngList_default),{ref_key:`gridListRef`,ref:gridListRef,class:`grid-list`,layout:unref(LIST_LAYOUTS).TILES,"no-background":``,big:``,immediate:``,"keep-alive":500,"title-width":20,"title-height":1.5,"title-margin":.5,"tile-size-calc":tileSizeCalc},{default:withCtx(()=>[(openBlock(!0),createElementBlock(Fragment,null,renderList(limitedGroups.value,group=>(openBlock(),createElementBlock(Fragment,{key:group.label},[group.label?(openBlock(),createBlock(GroupHeader_default,{key:0,label:group.label,"bng-list-title":``},null,8,[`label`])):createCommentVNode(``,!0),(openBlock(!0),createElementBlock(Fragment,null,renderList(group.tiles,tile=>(openBlock(),createBlock(Tile_default,{key:tile.key,tile,"is-config":__props.isConfig,"display-size":__props.displaySize,"is-favourite":group.label===`Favourites`,"tile-images-top-aligned":__props.tileImagesTopAligned,onFocus:$event=>focusItem(tile),onClick:$event=>selectItem(tile),onDblclick:$event=>handleDoubleClick(tile)},null,8,[`tile`,`is-config`,`display-size`,`is-favourite`,`tile-images-top-aligned`,`onFocus`,`onClick`,`onDblclick`]))),128))],64))),128))]),_:1},8,[`layout`]))}},Grid_default$1=__plugin_vue_export_helper_default(_sfc_main$318,[[`__scopeId`,`data-v-efa73a51`]]),_hoisted_1$282={class:`display-controls-container`},_hoisted_2$232={class:`control-group-label`},_hoisted_3$206={key:0,class:`reset-button-container`},_sfc_main$317={__name:`DisplayControls`,props:{displayData:{type:Array,required:!0},detailsMode:{type:String,required:!0},updateDisplayData:{type:Function,required:!0},resetDisplayDataToDefaults:{type:Function,required:!0},setDetailsMode:{type:Function,required:!0}},emits:[`focus-item`],setup(__props,{emit:__emit}){let props=__props,emit$1=__emit,booleanToStringByKey=computed(()=>{let valuesByKey={};for(let option of props.displayData)if(option.type===`checkbox`){valuesByKey[option.key]={};for(let checkboxOption of option.options)valuesByKey[option.key][checkboxOption.value]=checkboxOption.label||(checkboxOption.value?`Yes`:`No`)}return valuesByKey}),controls$1=computed(()=>props.displayData.filter(x=>x.showInModes?.[props.detailsMode]).map(x=>({...x,checkboxLabel:x.type===`checkbox`?booleanToStringByKey.value[x.key]?.[x.value]:void 0}))),onOptionChanged=(key,newValue)=>{props.updateDisplayData(key,newValue),emit$1(`focus-item`,key)},resetToDefaults=()=>{props.resetDisplayDataToDefaults()};return(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$282,[createBaseVNode(`div`,{class:normalizeClass([`display-controls`,{"display-controls-list":__props.detailsMode===`displayControls`||__props.detailsMode===`default`}])},[(openBlock(!0),createElementBlock(Fragment,null,renderList(controls$1.value,option=>(openBlock(),createElementBlock(`div`,{key:option.key,class:normalizeClass([`control-group`,{"force-full-width":__props.detailsMode===`default`}])},[createBaseVNode(`div`,_hoisted_2$232,toDisplayString(option.label),1),createVNode(bngTooltip_default,{text:option.description||`No description available`,position:`top`},{default:withCtx(()=>[option.type===`dropdown`?(openBlock(),createBlock(unref(bngSmartSelect_default),{key:0,modelValue:option.value,items:option.options||[],"onUpdate:modelValue":newValue=>onOptionChanged(option.key,newValue),threshold:8},null,8,[`modelValue`,`items`,`onUpdate:modelValue`])):option.type===`checkbox`?(openBlock(),createBlock(unref(bngSwitch_default),{key:1,class:normalizeClass([`full-width-checkbox`,{active:option.value}]),modelValue:option.value,"onUpdate:modelValue":newValue=>onOptionChanged(option.key,newValue),labelBefore:``,alwaysTransparent:``},{default:withCtx(()=>[createTextVNode(toDisplayString(option.checkboxLabel),1)]),_:2},1032,[`class`,`modelValue`,`onUpdate:modelValue`])):option.type===`number`?(openBlock(),createBlock(unref(bngInputNew_default),{key:2,modelValue:option.value,min:option.min,max:option.max,showExternalButton:!1,type:`number`,"onUpdate:modelValue":newValue=>onOptionChanged(option.key,newValue)},null,8,[`modelValue`,`min`,`max`,`onUpdate:modelValue`])):createCommentVNode(``,!0)]),_:2},1032,[`text`])],2))),128))],2),__props.detailsMode===`displayControls`?(openBlock(),createElementBlock(`div`,_hoisted_3$206,[createVNode(unref(bngButton_default),{onClick:resetToDefaults,accent:`attention`,iconLeft:`trashBin1`,class:`reset-button`},{default:withCtx(()=>[..._cache[0]||=[createTextVNode(` Reset to Defaults `,-1)]]),_:1})])):createCommentVNode(``,!0)]))}},DisplayControls_default=__plugin_vue_export_helper_default(_sfc_main$317,[[`__scopeId`,`data-v-863e411a`]]),_sfc_main$316={__name:`SearchBar`,props:{searchText:{type:String,required:!0},setSearchText:{type:Function,required:!0},placeholder:{type:String,default:`Search...`},fullWidth:{type:Boolean,default:!1},showClearAllButton:{type:Boolean,default:!1}},emits:[`focus-item`,`clear-all`],setup(__props,{emit:__emit}){let props=__props,emit$1=__emit,clearSearch=()=>{props.setSearchText(``),emit$1(`focus-item`,`search`)},commitSearch=()=>{},onSearchChanged=value=>{props.setSearchText(value),emit$1(`focus-item`,`search`)};return(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,{class:normalizeClass([`search-container`,{"full-width":__props.fullWidth}])},[createVNode(unref(bngInput_default),{class:`search-input`,modelValue:__props.searchText,placeholder:__props.placeholder,onValueChanged:onSearchChanged,onKeydown:withKeys(commitSearch,[`enter`]),onBlur:commitSearch,onFocus:_cache[0]||=$event=>emit$1(`focus-item`,`search`)},null,8,[`modelValue`,`placeholder`]),createBaseVNode(`div`,{class:normalizeClass([`search-icon-container`,{active:__props.searchText}]),onClick:clearSearch},[createVNode(unref(bngIcon_default),{type:unref(icons).search,class:`search-icon show-unhovered`},null,8,[`type`]),createVNode(unref(bngIcon_default),{type:unref(icons).trashBin2,class:`search-icon show-hovered`},null,8,[`type`])],2)],2))}},SearchBar_default=__plugin_vue_export_helper_default(_sfc_main$316,[[`__scopeId`,`data-v-67aff9c0`]]),_hoisted_1$281={class:`filters`},_hoisted_2$231={key:0,class:`search-section`},_hoisted_3$205={key:1,class:`filter-options-grid`},_hoisted_4$176={class:`option-label`},_hoisted_5$151={class:`option-icon`},_hoisted_6$130={key:2,class:`filters-container`},_hoisted_7$116={class:`filter-container`,navigable:``,tabindex:`0`},_hoisted_8$97={class:`filter-content`},_hoisted_9$87={key:0,class:`filter-options`},_hoisted_10$76={class:`filter-options-grid`},_hoisted_11$68={class:`option-label`},_hoisted_12$56={class:`option-icon`},_hoisted_13$48={key:1,class:`filter-options`},_hoisted_14$43={class:`range-bar-container`},_hoisted_15$41={class:`range-bar`},_hoisted_16$39={class:`range-inputs`},_hoisted_17$32={class:`range-input-group`},_hoisted_18$29={class:`range-input-group`},_sfc_main$315={__name:`DetailedFilters`,props:{filterList:{type:Array,required:!0},filterByProp:{type:Object,required:!0},searchText:{type:String,default:``},commonFilters:{type:Array,default:()=>[]},detailsMode:{type:String,required:!0},onlyCommonFilters:{type:Boolean,default:!0},isFilterLocked:{type:Function,required:!0},isFilterOptionLocked:{type:Function,required:!0},isRangeFilterLocked:{type:Function,required:!0},toggleFilter:{type:Function,required:!0},updateRangeFilter:{type:Function,required:!0},resetRangeFilter:{type:Function,required:!0},setSearchText:{type:Function,required:!0},setDetailsMode:{type:Function,required:!0}},emits:[`focus-item`],setup(__props,{emit:__emit}){let props=__props,emit$1=__emit,expandedAccordions=ref({}),pendingRangeUpdates=ref({}),debouncedUpdateFunctions=ref({}),getDebouncedUpdate=propName=>(debouncedUpdateFunctions.value[propName]||(debouncedUpdateFunctions.value[propName]=debounce(()=>{if(pendingRangeUpdates.value[propName]){let{min:min$1,max:max$1}=pendingRangeUpdates.value[propName];props.updateRangeFilter(propName,min$1,max$1),delete pendingRangeUpdates.value[propName]}},300)),debouncedUpdateFunctions.value[propName]);onUnmounted(()=>{Object.values(debouncedUpdateFunctions.value).forEach(debouncedFn=>{debouncedFn&&debouncedFn.cancel&&debouncedFn.cancel()}),debouncedUpdateFunctions.value={},pendingRangeUpdates.value={}});let formatFilterName=key=>key,getFilterOptionClass=(propName,option)=>{let filter=props.filterList.find(f=>f.propName===propName);if(!filter||!filter.options)return``;let allEnabled=filter.options.every(opt=>props.filterByProp[propName]?.[opt]===!0),currentOptionEnabled=props.filterByProp[propName]?.[option]===!0;return allEnabled?`filter-neutral`:currentOptionEnabled?`filter-active`:`filter-inactive`},hasActiveFilters=propName=>{if(!props.filterList)return!1;let filter=props.filterList.find(f=>f.propName===propName);if(!filter)return!1;if(filter.type===`range`){let filterData=props.filterByProp[propName];if(!filterData)return!1;let currentMin=filterData.min,currentMax=filterData.max,defaultMin=filter.min,defaultMax=filter.max;return currentMin>defaultMin||currentMaxprops.filterByProp[propName]?.[option]===!1)},toggleFilter=(propName,option,event)=>{if(props.isFilterOptionLocked(propName,option)){console.log(`Cannot toggle locked filter:`,propName,option);return}event&&(event.preventDefault(),event.stopPropagation()),emit$1(`focus-item`,`filters`),props.toggleFilter(propName,option)},onRangeFilterChanged=(propName,newValue,field)=>{if(props.isRangeFilterLocked(propName)){console.log(`Cannot update locked range filter:`,propName);return}let filter=props.filterList.find(f=>f.propName===propName);if(!filter||filter.type!==`range`)return;let filterData=props.filterByProp[propName];if(!filterData)return;let currentPending=pendingRangeUpdates.value[propName],min$1=currentPending?currentPending.min:filterData.min,max$1=currentPending?currentPending.max:filterData.max;field===`min`?min$1=newValue:field===`max`&&(max$1=newValue),min$1=Math.max(filter.min,Math.min(filter.max,min$1)),max$1=Math.max(filter.min,Math.min(filter.max,max$1)),min$1>max$1&&([min$1,max$1]=[max$1,min$1]),pendingRangeUpdates.value[propName]={min:min$1,max:max$1},getDebouncedUpdate(propName)(),emit$1(`focus-item`,propName)},isFilterActive=filter=>hasActiveFilters(filter.propName),getRangeBarStyle=propName=>{let filter=props.filterList.find(f=>f.propName===propName);if(!filter||filter.type!==`range`)return{};let filterData=props.filterByProp[propName];if(!filterData)return{};let currentMin=filterData.min,currentMax=filterData.max,totalRange=filter.max-filter.min,leftPosition=(currentMin-filter.min)/totalRange*100,width$1=(currentMax-currentMin)/totalRange*100;return{left:`${leftPosition}%`,width:`${width$1}%`,backgroundColor:`var(--bng-orange-500)`}};return onMounted(()=>{props.filterList&&props.filterList.forEach(filter=>{hasActiveFilters(filter.propName)&&(expandedAccordions.value[filter.propName]=!0)})}),(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$281,[__props.detailsMode===`filter`?(openBlock(),createElementBlock(`div`,_hoisted_2$231,[createVNode(SearchBar_default,{searchText:__props.searchText,setSearchText:__props.setSearchText,placeholder:`Search items...`,"full-width":!0,onFocusItem:_cache[0]||=$event=>emit$1(`focus-item`,$event)},null,8,[`searchText`,`setSearchText`])])):createCommentVNode(``,!0),__props.detailsMode===`filter`?createCommentVNode(``,!0):(openBlock(),createElementBlock(`div`,_hoisted_3$205,[(openBlock(!0),createElementBlock(Fragment,null,renderList(__props.commonFilters,(filter,index)=>(openBlock(),createBlock(unref(bngPill_default),{key:index,class:normalizeClass([[getFilterOptionClass(filter[0],filter[1]),{"filter-locked":props.isFilterOptionLocked(filter[0],filter[1])}],`filter-option-chip`]),style:normalizeStyle({cursor:props.isFilterOptionLocked(filter[0],filter[1])?`not-allowed`:`pointer`}),"bng-nav-item":``,onClick:$event=>toggleFilter(filter[0],filter[1])},{default:withCtx(()=>[createBaseVNode(`span`,_hoisted_4$176,toDisplayString(filter[1]),1),createBaseVNode(`span`,_hoisted_5$151,[__props.filterByProp&&__props.filterByProp[filter[0]]&&__props.filterByProp[filter[0]][filter[1]]?(openBlock(),createBlock(unref(bngIcon_default),{key:0,type:unref(icons).checkmark},null,8,[`type`])):(openBlock(),createBlock(unref(bngIcon_default),{key:1,type:unref(icons).xmark},null,8,[`type`])),props.isFilterOptionLocked(filter[0],filter[1])?(openBlock(),createBlock(unref(bngIcon_default),{key:2,type:unref(icons).lockClosed,class:`lock-icon`},null,8,[`type`])):createCommentVNode(``,!0)])]),_:2},1032,[`class`,`style`,`onClick`]))),128))])),__props.detailsMode===`filter`?(openBlock(),createElementBlock(`div`,_hoisted_6$130,[createVNode(unref(accordion_default),{class:`filters-accordion`},{default:withCtx(()=>[(openBlock(!0),createElementBlock(Fragment,null,renderList(__props.filterList,filter=>(openBlock(),createElementBlock(`div`,{key:filter.propName,class:`filter-wrapper`},[createVNode(unref(accordionItem_default),{navigable:``,static:!filter.options||filter.options.length===0,"arrow-big":``,"expand-hint-inline":``,expanded:expandedAccordions.value[filter.propName],class:normalizeClass({"has-active-filters":isFilterActive(filter)}),onFocus:$event=>emit$1(`focus-item`,filter.propName)},{caption:withCtx(()=>[createBaseVNode(`div`,_hoisted_7$116,[createBaseVNode(`div`,_hoisted_8$97,toDisplayString(formatFilterName(filter.propName)),1)])]),default:withCtx(()=>[filter.type===`set`&&filter.options?(openBlock(),createElementBlock(`div`,_hoisted_9$87,[createBaseVNode(`div`,_hoisted_10$76,[(openBlock(!0),createElementBlock(Fragment,null,renderList(filter.options,(option,index)=>(openBlock(),createBlock(unref(bngPill_default),{key:index,class:normalizeClass([[getFilterOptionClass(filter.propName,option),{"filter-locked":props.isFilterOptionLocked(filter.propName,option)}],`filter-option-chip`]),style:normalizeStyle({cursor:props.isFilterOptionLocked(filter.propName,option)?`not-allowed`:`pointer`}),onClick:$event=>toggleFilter(filter.propName,option)},{default:withCtx(()=>[createBaseVNode(`span`,_hoisted_11$68,toDisplayString(option),1),createBaseVNode(`span`,_hoisted_12$56,[__props.filterByProp[filter.propName][option]?(openBlock(),createBlock(unref(bngIcon_default),{key:0,type:unref(icons).checkmark},null,8,[`type`])):(openBlock(),createBlock(unref(bngIcon_default),{key:1,type:unref(icons).abandon},null,8,[`type`])),props.isFilterOptionLocked(filter.propName,option)?(openBlock(),createBlock(unref(bngIcon_default),{key:2,type:unref(icons).lockClosed,class:`lock-icon`},null,8,[`type`])):createCommentVNode(``,!0)])]),_:2},1032,[`class`,`style`,`onClick`]))),128))])])):createCommentVNode(``,!0),filter.type===`range`?(openBlock(),createElementBlock(`div`,_hoisted_13$48,[createBaseVNode(`div`,_hoisted_14$43,[createBaseVNode(`div`,_hoisted_15$41,[createBaseVNode(`div`,{class:`range-selection`,style:normalizeStyle(getRangeBarStyle(filter.propName))},null,4)])]),createBaseVNode(`div`,_hoisted_16$39,[createBaseVNode(`div`,_hoisted_17$32,[_cache[1]||=createBaseVNode(`label`,{class:`range-label`},`Min:`,-1),(openBlock(),createBlock(unref(bngInput_default),{key:filter.propName+`min`,modelValue:__props.filterByProp[filter.propName].min,type:`number`,min:filter.min,max:filter.max,step:filter.step||1,disabled:props.isRangeFilterLocked(filter.propName),onValueChanged:val=>onRangeFilterChanged(filter.propName,val,`min`)},null,8,[`modelValue`,`min`,`max`,`step`,`disabled`,`onValueChanged`]))]),createBaseVNode(`div`,_hoisted_18$29,[_cache[2]||=createBaseVNode(`label`,{class:`range-label`},`Max:`,-1),(openBlock(),createBlock(unref(bngInput_default),{key:filter.propName+`max`,modelValue:__props.filterByProp[filter.propName].max,type:`number`,min:filter.min,max:filter.max,step:filter.step||1,disabled:props.isRangeFilterLocked(filter.propName),onValueChanged:val=>onRangeFilterChanged(filter.propName,val,`max`)},null,8,[`modelValue`,`min`,`max`,`step`,`disabled`,`onValueChanged`]))])])])):createCommentVNode(``,!0)]),_:2},1032,[`static`,`expanded`,`class`,`onFocus`])]))),128))]),_:1})])):createCommentVNode(``,!0)]))}},DetailedFilters_default=__plugin_vue_export_helper_default(_sfc_main$315,[[`__scopeId`,`data-v-a4758924`]]),_hoisted_1$280={key:1},_hoisted_2$230={key:1},_hoisted_3$204={key:1},_hoisted_4$175={key:1},_sfc_main$314={__name:`HeaderButtons`,props:{canSwitchDetails:{type:Boolean,default:!1},hiddenTabs:{type:Array,default:()=>[]},detailsMode:{type:String,required:!0},slim:{type:Boolean,default:!1}},emits:[`switch-details-mode`],setup(__props){return(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,{class:normalizeClass([`header-buttons`,{slim:__props.slim}])},[withDirectives(createVNode(unref(bngBinding_default),{class:`header-buttons-binding`,"ui-event":`context`,controller:``,"track-ignore":``},null,512),[[vShow,__props.canSwitchDetails]]),__props.hiddenTabs.includes(`detail`)?createCommentVNode(``,!0):withDirectives((openBlock(),createBlock(unref(bngButton_default),{key:0,class:normalizeClass([`header-button`,{selected:__props.detailsMode===`detail`}]),accent:unref(ACCENTS).text,onClick:_cache[0]||=$event=>_ctx.$emit(`switch-details-mode`,`detail`)},{default:withCtx(()=>[__props.slim?(openBlock(),createBlock(unref(bngIcon_default),{key:0,type:unref(icons).info},null,8,[`type`])):(openBlock(),createElementBlock(`span`,_hoisted_1$280,`Details`))]),_:1},8,[`class`,`accent`])),[[unref(BngTooltip_default),`Details`,`top`]]),__props.hiddenTabs.includes(`advanced`)?createCommentVNode(``,!0):withDirectives((openBlock(),createBlock(unref(bngButton_default),{key:1,class:normalizeClass([`header-button`,{selected:__props.detailsMode===`advanced`}]),accent:unref(ACCENTS).text,onClick:_cache[1]||=$event=>_ctx.$emit(`switch-details-mode`,`advanced`)},{default:withCtx(()=>[__props.slim?(openBlock(),createBlock(unref(bngIcon_default),{key:0,type:unref(icons).laneProperties},null,8,[`type`])):(openBlock(),createElementBlock(`span`,_hoisted_2$230,`Advanced`))]),_:1},8,[`class`,`accent`])),[[unref(BngTooltip_default),`Advanced`,`top`]]),__props.hiddenTabs.includes(`filter`)?createCommentVNode(``,!0):withDirectives((openBlock(),createBlock(unref(bngButton_default),{key:2,class:normalizeClass([`header-button`,{selected:__props.detailsMode===`filter`}]),accent:unref(ACCENTS).text,onClick:_cache[2]||=$event=>_ctx.$emit(`switch-details-mode`,`filter`)},{default:withCtx(()=>[__props.slim?(openBlock(),createBlock(unref(bngIcon_default),{key:0,type:unref(icons).filter},null,8,[`type`])):(openBlock(),createElementBlock(`span`,_hoisted_3$204,`Filters`))]),_:1},8,[`class`,`accent`])),[[unref(BngTooltip_default),`Filters`,`top`]]),__props.hiddenTabs.includes(`displayControls`)?createCommentVNode(``,!0):withDirectives((openBlock(),createBlock(unref(bngButton_default),{key:3,class:normalizeClass([`header-button`,{selected:__props.detailsMode===`displayControls`}]),accent:unref(ACCENTS).text,onClick:_cache[3]||=$event=>_ctx.$emit(`switch-details-mode`,`displayControls`)},{default:withCtx(()=>[__props.slim?(openBlock(),createBlock(unref(bngIcon_default),{key:0,type:unref(icons).adjust},null,8,[`type`])):(openBlock(),createElementBlock(`span`,_hoisted_4$175,`Display`))]),_:1},8,[`class`,`accent`])),[[unref(BngTooltip_default),`Display`,`top`]])],2))}},HeaderButtons_default=__plugin_vue_export_helper_default(_sfc_main$314,[[`__scopeId`,`data-v-157cdc63`]]),_sfc_main$313={__name:`Slideshow`,props:{images:Array,transition:Boolean,delay:{type:Number,default:1e4},parent:Object,shuffle:Boolean},setup(__props,{expose:__expose}){useCssVars(_ctx=>({v095d52f4:imgPrev.value,v095f8174:imgNext.value}));let props=__props,anim=ref(!1),imgPrev=ref(``),imgNext=ref(``),imgIndex=ref(-1),sequence=[],sequenceIndex=-1,tmrMain,tmrAnim,wImages,wParent;__expose({imgIndex,nextImage,carousel:{showNext:nextImage}}),onUnmounted(stopTimers);function stopTimers(){tmrMain&&=(clearTimeout(tmrMain),null),tmrAnim&&=(clearTimeout(tmrAnim),null)}watch(()=>props.parent,parent=>{wImages&&=(wImages(),null),wParent&&=(wParent(),null),parent?wParent=watch([()=>props.images,()=>parent.imgIndex],([images,index])=>{images&&(imgIndex.value=index,images.length>0&&nextTick(nextImage))},{immediate:!0}):wImages=watch([()=>props.images,()=>props.shuffle],([images,shuffle])=>{images&&(imgIndex.value=-1,images.length>0&&(shuffle&&(sequenceIndex=-1,sequence=Array.from(images).map((_,i)=>i).sort(()=>Math.random()-.5)),nextTick(nextImage)))},{immediate:!0})},{immediate:!0});function nextImage(){stopTimers(),props.parent||(props.shuffle&&sequence.length>0?(sequenceIndex=++sequenceIndex%props.images.length,imgIndex.value=sequence[sequenceIndex]):imgIndex.value=++imgIndex.value%props.images.length);let img=`url("${getAssetURL(props.images[imgIndex.value])}")`;props.transition?(imgNext.value=img,anim.value=!0,tmrAnim=setTimeout(()=>{tmrAnim=null,anim.value=!1,imgPrev.value=imgNext.value,imgNext.value=``},1e3)):imgPrev.value=img,!props.parent&&props.images.length>1&&(tmrMain=setTimeout(nextImage,props.delay))}return(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,{class:normalizeClass({anim:anim.value})},null,2))}},Slideshow_default=__plugin_vue_export_helper_default(_sfc_main$313,[[`__scopeId`,`data-v-f788946d`]]),_hoisted_1$279={key:0,class:`blur-wrap`},_sfc_main$312={__name:`BlurBackground`,setup(__props){let parentCarousel=inject(`mainBackground`),backgroundsBlur=inject(`mainBackgroundBlur`),bgRequired=sysInfo_default.mainMenuBackgroundRequired;return(_ctx,_cache)=>unref(bgRequired)?(openBlock(),createElementBlock(`div`,_hoisted_1$279,[createVNode(Slideshow_default,{class:`blur-carousel`,images:unref(backgroundsBlur),parent:unref(parentCarousel),transition:``},null,8,[`images`,`parent`])])):createCommentVNode(``,!0)}},BlurBackground_default=__plugin_vue_export_helper_default(_sfc_main$312,[[`__scopeId`,`data-v-cc1c4815`]]),_hoisted_1$278={class:`header-container`},_hoisted_2$229={key:1},_hoisted_3$203={class:`content-container`},_hoisted_4$174={class:`header-back-button`},_hoisted_5$150={key:0,class:`header-title-container`},_hoisted_6$129={class:`header-back-button`},_hoisted_7$115={class:`header-back-button`},_hoisted_8$96={key:0,class:`scrollable-content`},_hoisted_9$86={class:`details-mode-buttons`},_hoisted_10$75={key:1,class:`scrollable-content`},_hoisted_11$67={key:0,class:`details-content`},_hoisted_12$55={key:1,class:`scrollable-content`},_sfc_main$311={__name:`GridSelector`,props:{backendName:{type:String,default:`gridSelector`},routePath:{type:String,default:`/grid-selector`},defaultPath:{type:Object,default:()=>({keys:[`allModels`]})},defaultDetailsMode:{type:String,default:`detail`},hiddenTabs:{type:Array,default:()=>[]},tileImagesTopAligned:{type:Boolean,default:!1},doubleClickOverride:{type:Function,default:null},noBreadcrumbs:{type:Boolean,default:!1},overrideBackFromGrid:{type:Function,default:null},inlineHeaderContainer:{type:Boolean,default:!0},selectCallback:{type:Function,default:null},bubbleEvents:{type:Array,default:()=>[]}},setup(__props,{expose:__expose}){let props=__props,{showIfController}=storeToRefs(controls_default()),store$1=useGridSelector(props.backendName,props.defaultPath,props.defaultDetailsMode),{groups,displayData,detailsMode,selectedItem,showScreenHeader,screenHeaderTitle,screenHeaderPath,activeItemDetails,activeItem,activeFilters}=store$1,route=useRoute(),router$1=useRouter(),detailsModeTitles={detail:`Details`,advanced:`Advanced`,filter:`Filters`,displayControls:`Display`},detailsModeBackTo={filter:`advanced`,displayControls:`advanced`};watch(()=>[props.backendName,props.defaultPath,props.defaultDetailsMode],([newBackendName,newDefaultPath,newDefaultDetailsMode],[oldBackendName,oldDefaultPath,oldDefaultDetailsMode])=>{newBackendName!==oldBackendName&&newDefaultPath&&newDefaultPath.keys&&store$1.setCurrentPath(newDefaultPath),newDefaultDetailsMode!==oldDefaultDetailsMode&&store$1.setDetailsMode(newDefaultDetailsMode)},{deep:!0});let scopedNavState=reactive({isGridActive:!1,isDetailsActive:!1}),setBack=inject(`setBack`),showTopbarTabBindings=inject(`showTopbarTabBindings`),showTopbarBackBinding=inject(`showTopbarBackBinding`),showBreadcrumbsBack=ref(!1),canUseTopbar=ref(!0);watch(()=>scopedNavState.isDetailsActive,val=>{canUseTopbar.value=!val,showTopbarTabBindings(canUseTopbar.value)}),watch(screenHeaderPath,val=>{showBreadcrumbsBack.value=val&&val.length>2,showTopbarBackBinding(!showBreadcrumbsBack.value)});let switchSeq=computed(()=>[`detail`,`advanced`,`displayControls`].filter(tab=>!props.hiddenTabs.includes(tab))),getNextSwitchSeq=mode=>{mode||=detailsMode.value,mode===`filter`&&(mode=`advanced`);let seq=switchSeq.value;if(seq.length===0)return`detail`;let currentIndex=seq.indexOf(mode);return currentIndex===-1?seq[0]:seq[(currentIndex+1)%seq.length]},canSeeDetails=ref(!0),hasSelectedItem=computed(()=>!!store$1.selectedItem.value),canSwitchDetails=computed(()=>activeSectionScope.value!==`default`||detailsMode.value===`advanced`);function switchDetailsMode(mode){console.log(`switchDetailsMode`,mode),typeof mode!=`string`&&(mode=getNextSwitchSeq(mode)),mode===`detail`&&!canSeeDetails.value&&(mode=getNextSwitchSeq(mode)),console.log(`switchDetailsMode`,mode),store$1.setDetailsMode(mode),switchScope(`details`)}function onToggleSectionScope(){activeSectionScope.value===`grid`?switchScope(`details`):switchDetailsMode()}let activeSectionScope=ref(`grid`);function switchScope(name,force=!1){name||=activeSectionScope.value===`grid`?`details`:`grid`,name===`details`?(scopedNavState.isGridActive=!1,force&&(scopedNavState.isDetailsActive=!1),nextTick(()=>{activeSectionScope.value=name,scopedNavState.isDetailsActive=!0})):(scopedNavState.isDetailsActive=!1,force&&(scopedNavState.isGridActive=!1),nextTick(()=>{activeSectionScope.value=name,scopedNavState.isGridActive=!0}))}let onGridActivate=()=>{scopedNavState.isGridActive=!0},onGridDeactivate=event=>{scopedNavState.isGridActive=!1},onDetailsActivate=()=>{scopedNavState.isDetailsActive=!0},onDetailsDeactivate=event=>{scopedNavState.isDetailsActive=!1},setDetailsScope=info=>{switchScope(`details`)},canBubbleGridEvent=event=>!!(event.detail.name===`rotate_v_cam`||event.detail.name===`menu`||canUseTopbar.value&&(event.detail.name===`tab_l`||event.detail.name===`tab_r`)||props.bubbleEvents.includes(event.detail.name)),canBubbleDetailsEvent=event=>!!(event.detail.name===`rotate_v_cam`||props.bubbleEvents.includes(event.detail.name)),canDeactivateGrid=()=>screenHeaderPath.value.length<=1,onBackFromDetails=()=>{if(detailsMode.value===`displayControls`||detailsMode.value===`filter`){toggleDetailsMode(`advanced`);return}switchScope(`grid`)},onToggleFavorite=()=>{store$1.toggleFavourite(activeItem.value)},gridContentRef=ref(null),scrollPositions$1=ref(new Map),scrollTimeout=null,displaySize=computed(()=>{let option=displayData.value.find(option$1=>option$1.key===`displaySize`);return option?option.value:`medium`});store$1.initialize(),store$1.setOnBackFromDetailsCallback(()=>{onBackFromDetails()}),props.defaultPath.keys;let currentPathSegments=computed(()=>{let pathMatch=route.params.pathMatch;if(!pathMatch)return props.defaultPath?.keys||(Array.isArray(props.defaultPath)?props.defaultPath:[]);let segments=Array.isArray(pathMatch)?pathMatch.map(segment=>decodeURIComponent(segment)):[decodeURIComponent(pathMatch)];if(route.params.itemDetails){let itemDetails=Array.isArray(route.params.itemDetails)?route.params.itemDetails.map(segment=>decodeURIComponent(segment)):[decodeURIComponent(route.params.itemDetails)];segments.push(...itemDetails)}return segments}),saveScrollPosition$1=()=>{if(!gridContentRef.value)return;let pathKey=currentPathSegments.value.join(`/`),scrollTop=gridContentRef.value.scrollTop;scrollPositions$1.value.set(pathKey,scrollTop)},debouncedSaveScrollPosition=()=>{scrollTimeout&&clearTimeout(scrollTimeout),scrollTimeout=setTimeout(()=>{saveScrollPosition$1()},100)},restoreScrollPosition=()=>{if(!gridContentRef.value)return;let pathKey=currentPathSegments.value.join(`/`),savedPosition=scrollPositions$1.value.get(pathKey);savedPosition!==void 0&&nextTick(()=>{gridContentRef.value.scrollTop=savedPosition})};watch(groups,async newGroups=>{newGroups&&(await nextTick(),await nextTick(),store$1.notifyUIReady(),restoreScrollPosition())},{immediate:!0}),watch([currentPathSegments],async([segments],[oldSegments])=>{if(oldSegments&&gridContentRef.value){let oldPathKey=oldSegments.join(`/`),currentScrollTop=gridContentRef.value.scrollTop;scrollPositions$1.value.set(oldPathKey,currentScrollTop)}let path={keys:segments};await store$1.setCurrentPath(path)},{immediate:!0}),watch(gridContentRef,newElement=>{if(newElement){let handleScroll=()=>{debouncedSaveScrollPosition()};newElement.addEventListener(`scroll`,handleScroll),newElement._scrollHandler=handleScroll}},{immediate:!0}),onBeforeMount(()=>{Lua_default.simTimeAuthority.pushPauseRequest(`gridSelector`)}),onMounted(()=>{setBack(props.backendName,onBackFromGrid),nextTick(()=>{scopedNavState.isGridActive=!0})}),onUnmounted(()=>{setBack(props.backendName),gridContentRef.value&&gridContentRef.value._scrollHandler&&gridContentRef.value.removeEventListener(`scroll`,gridContentRef.value._scrollHandler),scrollTimeout&&clearTimeout(scrollTimeout),Lua_default.ui_gridSelector.closedFromUI(props.backendName),Lua_default.simTimeAuthority.popPauseRequest(`gridSelector`)});let onItemFocus=item=>{item&&item.showDetails&&store$1.setPreviewItem(item)},onItemSelect=async(item,doNavigation=!0)=>{if(item.gotoPath&&Array.isArray(item.gotoPath))store$1.prevSelectedItem.value=item.key,doNavigation&&routeNav(item),store$1.clearSelectedItem(),doNavigation&&switchScope(`grid`),props.selectCallback&&await props.selectCallback(item,doNavigation);else if(item.showDetails){item.key,selectedItem.value?.key;let consumed=!1;props.selectCallback&&(consumed=await props.selectCallback(item,doNavigation)),consumed||(await store$1.setSelectedItem(item),doNavigation&&switchScope(`details`))}},onGridWrapperClick=event=>{store$1.clearSelectedItem(),switchScope(`grid`,!0)},onDetailsWrapperClick=event=>{switchScope(`details`,!0)},onItemDeselect=()=>{store$1.clearSelectedItem()},toggleDetailsMode=mode=>{store$1.setDetailsMode(mode)};function routeNav(item){if(item.gotoAngularState)return;let encodedPath=item.gotoPath.map(segment=>encodeURIComponent(segment)).join(`/`);router$1.push(`${props.routePath}/${encodedPath}`)}let onBackFromGrid=()=>{if(console.log(`onBackFromGrid`,screenHeaderPath.value),props.overrideBackFromGrid&&screenHeaderPath.value.length<=2)return props.overrideBackFromGrid();if(screenHeaderPath.value.length>1){let item=screenHeaderPath.value[screenHeaderPath.value.length-2];return store$1.prevSelectedItem.value&&(store$1.autoFocusKey.value=store$1.prevSelectedItem.value),gotoHeaderItem(item),!1}return!0},onBreadBack=()=>nextTick(onBackFromGrid),clearSearch=()=>{store$1.setSearchText(``)},clearFilters=()=>{console.log(`clearFilters`,activeFilters.value);for(let filter of activeFilters.value)console.log(`clearFilter`,filter),filter&&filter.type===`range`?store$1.resetRangeFilter(filter.propName):store$1.resetSetFilter(filter.propName)},setCurrentPath=path=>{store$1.setCurrentPath(path)},gotoHeaderItem=item=>{console.log(`gotoHeaderItem`,item),item.gotoAngularState?window.bngVue.gotoAngularState(item.gotoAngularState):item.gotoPath&&(item.clearSearch&&clearSearch(),item.clearFilters&&clearFilters(),setCurrentPath({keys:item.gotoPath}),routeNav(item),switchScope(`grid`))};return __expose({screenHeaderPath,clearSearch,clearFilters,setCurrentPath}),(_ctx,_cache)=>withDirectives((openBlock(),createBlock(unref(layoutSingle_default),{class:`grid-selector`},{default:withCtx(()=>[createBaseVNode(`div`,_hoisted_1$278,[__props.noBreadcrumbs?(openBlock(),createElementBlock(`div`,_hoisted_2$229)):(openBlock(),createBlock(unref(bngBreadcrumbs_default),{key:0,class:`header-breadcrumbs`,items:unref(screenHeaderPath),limit:`5`,simple:``,"disable-last-item":``,"show-back-button":showBreadcrumbsBack.value,onClick:gotoHeaderItem,onBack:onBreadBack},null,8,[`items`,`show-back-button`])),__props.inlineHeaderContainer?createCommentVNode(``,!0):(openBlock(),createBlock(HeaderButtons_default,{key:2,"can-switch-details":canSwitchDetails.value,"hidden-tabs":props.hiddenTabs,"details-mode":unref(detailsMode),onSwitchDetailsMode:switchDetailsMode},null,8,[`can-switch-details`,`hidden-tabs`,`details-mode`]))]),createBaseVNode(`div`,_hoisted_3$203,[createBaseVNode(`div`,{class:normalizeClass([`grid-wrapper`,{active:activeSectionScope.value===`grid`}])},[createVNode(BlurBackground_default),unref(showScreenHeader)?(openBlock(),createElementBlock(`div`,{key:0,class:normalizeClass([`header-row`,{active:activeSectionScope.value===`grid`&&unref(showIfController),"no-controller":!unref(showIfController)}])},[createVNode(unref(bngScreenHeadingV2_default),{type:`2`,class:`header-title-v2`},{default:withCtx(()=>[createTextVNode(toDisplayString(unref(screenHeaderTitle)),1)]),_:1}),withDirectives(createBaseVNode(`div`,_hoisted_4$174,[createVNode(unref(bngBinding_default),{"ui-event":`back`,controller:``}),createVNode(unref(bngIcon_default),{type:unref(icons).undo},null,8,[`type`])],512),[[vShow,activeSectionScope.value===`grid`&&unref(showIfController)&¤tPathSegments.value.length>1]])],2)):createCommentVNode(``,!0),withDirectives((openBlock(),createElementBlock(`div`,{class:`grid-content`,ref_key:`gridContentRef`,ref:gridContentRef,"bng-nav-scroll":``,"bng-no-nav":`true`,tabindex:`-1`,onActivate:onGridActivate,onDeactivate:onGridDeactivate,onClick:onGridWrapperClick},[createVNode(Grid_default$1,{"in-details":activeSectionScope.value===`details`&&unref(detailsMode)===`detail`,"display-size":displaySize.value,"backend-name":props.backendName,"auto-focus-key":unref(store$1).autoFocusKey.value,"active-item":unref(store$1).activeItem.value,groups:unref(groups),"tile-images-top-aligned":__props.tileImagesTopAligned,onFocusItem:onItemFocus,onSelectItem:onItemSelect,onDeselectItem:onItemDeselect,"double-click-override":__props.doubleClickOverride},null,8,[`in-details`,`display-size`,`backend-name`,`auto-focus-key`,`active-item`,`groups`,`tile-images-top-aligned`,`double-click-override`])],32)),[[unref(BngScopedNav_default),{activated:scopedNavState.isGridActive,canBubbleEvent:canBubbleGridEvent,canDeactivate:canDeactivateGrid,preferAutoFocus:!0,autoFocusDelay:400}],[unref(BngOnUiNav_default),onToggleSectionScope,`context`],[unref(BngUiNavLabel_default),`Filters and more`,`context`],[unref(BngOnUiNav_default),onBackFromGrid,`back`],[unref(BngUiNavScroll_default)]])],2),withDirectives((openBlock(),createElementBlock(`div`,{class:normalizeClass([`details-wrapper wide`,{active:activeSectionScope.value===`details`,"no-controller":!unref(showIfController)}]),tabindex:`-1`,"bng-no-nav":`true`,onActivate:onDetailsActivate,onDeactivate:onDetailsDeactivate,onClick:onDetailsWrapperClick},[createVNode(BlurBackground_default),createBaseVNode(`div`,{class:normalizeClass([`header-row`,{active:activeSectionScope.value===`details`&&unref(showIfController),"no-controller":!unref(showIfController)}]),"bng-no-child-nav":`true`},[createVNode(HeaderButtons_default,{slim:``,"can-switch-details":canSwitchDetails.value,"hidden-tabs":props.hiddenTabs,"details-mode":unref(detailsMode),onSwitchDetailsMode:switchDetailsMode},null,8,[`can-switch-details`,`hidden-tabs`,`details-mode`]),__props.inlineHeaderContainer?createCommentVNode(``,!0):(openBlock(),createElementBlock(`div`,_hoisted_5$150,[createVNode(unref(bngCardHeading_default),{type:`ribbon`,class:`header-title`},{default:withCtx(()=>[createTextVNode(toDisplayString(detailsModeTitles[unref(detailsMode)]),1)]),_:1}),detailsModeBackTo[unref(detailsMode)]?(openBlock(),createBlock(unref(bngButton_default),{key:0,"bng-no-nav":`true`,onClick:_cache[0]||=$event=>toggleDetailsMode(detailsModeBackTo[unref(detailsMode)]),accent:unref(ACCENTS).outlined,iconRight:`undo`},{default:withCtx(()=>[createVNode(unref(bngBinding_default),{"ui-event":`back`,controller:``})]),_:1},8,[`accent`])):createCommentVNode(``,!0),withDirectives(createBaseVNode(`div`,_hoisted_6$129,[createVNode(unref(bngIcon_default),{type:unref(icons).adjust},null,8,[`type`]),createVNode(unref(bngBinding_default),{"ui-event":`context`,controller:``})],512),[[vShow,activeSectionScope.value===`grid`||!unref(showIfController)]]),withDirectives(createBaseVNode(`div`,_hoisted_7$115,[createVNode(unref(bngBinding_default),{"ui-event":`back`,controller:``}),createVNode(unref(bngIcon_default),{type:unref(icons).undo},null,8,[`type`])],512),[[vShow,activeSectionScope.value===`details`&&unref(showIfController)]])]))],2),unref(detailsMode)===`advanced`?(openBlock(),createElementBlock(`div`,_hoisted_8$96,[createVNode(SearchBar_default,{searchText:unref(store$1).searchText.value,setSearchText:unref(store$1).setSearchText},null,8,[`searchText`,`setSearchText`]),createVNode(DetailedFilters_default,{filterList:unref(store$1).filterList.value,filterByProp:unref(store$1).filterByProp.value,searchText:unref(store$1).searchText.value,commonFilters:unref(store$1).commonFilters.value,detailsMode:unref(store$1).detailsMode.value,onlyCommonFilters:unref(store$1).onlyCommonFilters.value,isFilterLocked:unref(store$1).isFilterLocked,isFilterOptionLocked:unref(store$1).isFilterOptionLocked,isRangeFilterLocked:unref(store$1).isRangeFilterLocked,toggleFilter:unref(store$1).toggleFilter,updateRangeFilter:unref(store$1).updateRangeFilter,resetRangeFilter:unref(store$1).resetRangeFilter,setSearchText:unref(store$1).setSearchText,setDetailsMode:unref(store$1).setDetailsMode},null,8,[`filterList`,`filterByProp`,`searchText`,`commonFilters`,`detailsMode`,`onlyCommonFilters`,`isFilterLocked`,`isFilterOptionLocked`,`isRangeFilterLocked`,`toggleFilter`,`updateRangeFilter`,`resetRangeFilter`,`setSearchText`,`setDetailsMode`]),createVNode(DisplayControls_default,{displayData:unref(store$1).displayData.value,detailsMode:unref(store$1).detailsMode.value,updateDisplayData:unref(store$1).updateDisplayData,resetDisplayDataToDefaults:unref(store$1).resetDisplayDataToDefaults,setDetailsMode:unref(store$1).setDetailsMode},null,8,[`displayData`,`detailsMode`,`updateDisplayData`,`resetDisplayDataToDefaults`,`setDetailsMode`]),createBaseVNode(`div`,_hoisted_9$86,[createVNode(unref(bngButton_default),{onClick:_cache[1]||=$event=>toggleDetailsMode(`filter`),accent:unref(ACCENTS).secondary,iconLeft:`filter`},{default:withCtx(()=>[..._cache[3]||=[createTextVNode(` More filters... `,-1)]]),_:1},8,[`accent`]),createVNode(unref(bngButton_default),{onClick:_cache[2]||=$event=>toggleDetailsMode(`displayControls`),accent:unref(ACCENTS).secondary,iconLeft:`adjust`},{default:withCtx(()=>[..._cache[4]||=[createTextVNode(` Display Options `,-1)]]),_:1},8,[`accent`])]),createVNode(unref(bngCardHeading_default),{type:`line`,class:`heading`},{default:withCtx(()=>[..._cache[5]||=[createTextVNode(`Management`,-1)]]),_:1}),renderSlot(_ctx.$slots,`management-details`,{managementDetails:unref(store$1).managementDetails.value,executeButton:unref(store$1).executeButton},void 0,!0)])):unref(detailsMode)===`filter`?(openBlock(),createElementBlock(`div`,_hoisted_10$75,[createVNode(DetailedFilters_default,{filterList:unref(store$1).filterList.value,filterByProp:unref(store$1).filterByProp.value,searchText:unref(store$1).searchText.value,commonFilters:unref(store$1).commonFilters.value,detailsMode:unref(store$1).detailsMode.value,onlyCommonFilters:unref(store$1).onlyCommonFilters.value,isFilterLocked:unref(store$1).isFilterLocked,isFilterOptionLocked:unref(store$1).isFilterOptionLocked,isRangeFilterLocked:unref(store$1).isRangeFilterLocked,toggleFilter:unref(store$1).toggleFilter,updateRangeFilter:unref(store$1).updateRangeFilter,resetRangeFilter:unref(store$1).resetRangeFilter,setSearchText:unref(store$1).setSearchText,setDetailsMode:unref(store$1).setDetailsMode},null,8,[`filterList`,`filterByProp`,`searchText`,`commonFilters`,`detailsMode`,`onlyCommonFilters`,`isFilterLocked`,`isFilterOptionLocked`,`isRangeFilterLocked`,`toggleFilter`,`updateRangeFilter`,`resetRangeFilter`,`setSearchText`,`setDetailsMode`])])):unref(detailsMode)===`displayControls`?(openBlock(),createBlock(DisplayControls_default,{key:2,class:`scrollable-content`,displayData:unref(store$1).displayData.value,detailsMode:unref(store$1).detailsMode.value,updateDisplayData:unref(store$1).updateDisplayData,resetDisplayDataToDefaults:unref(store$1).resetDisplayDataToDefaults,setDetailsMode:unref(store$1).setDetailsMode},null,8,[`displayData`,`detailsMode`,`updateDisplayData`,`resetDisplayDataToDefaults`,`setDetailsMode`])):unref(detailsMode)===`detail`?(openBlock(),createElementBlock(Fragment,{key:3},[hasSelectedItem.value?(openBlock(),createElementBlock(`div`,_hoisted_11$67,[renderSlot(_ctx.$slots,`item-details`,{activeItem:unref(store$1).activeItem.value,activeItemDetails:unref(store$1).activeItemDetails.value,executeButton:unref(store$1).executeButton,toggleFavourite:unref(store$1).toggleFavourite,exploreFolder:unref(store$1).exploreFolder,goToMod:unref(store$1).goToMod,onFocusItem:setDetailsScope},void 0,!0)])):(openBlock(),createElementBlock(`div`,_hoisted_12$55,[createVNode(SearchBar_default,{searchText:unref(store$1).searchText.value,setSearchText:unref(store$1).setSearchText},null,8,[`searchText`,`setSearchText`]),createVNode(DetailedFilters_default,{filterList:unref(store$1).filterList.value,filterByProp:unref(store$1).filterByProp.value,searchText:unref(store$1).searchText.value,commonFilters:unref(store$1).commonFilters.value,detailsMode:unref(store$1).detailsMode.value,onlyCommonFilters:unref(store$1).onlyCommonFilters.value,isFilterLocked:unref(store$1).isFilterLocked,isFilterOptionLocked:unref(store$1).isFilterOptionLocked,isRangeFilterLocked:unref(store$1).isRangeFilterLocked,toggleFilter:unref(store$1).toggleFilter,updateRangeFilter:unref(store$1).updateRangeFilter,resetRangeFilter:unref(store$1).resetRangeFilter,setSearchText:unref(store$1).setSearchText,setDetailsMode:unref(store$1).setDetailsMode},null,8,[`filterList`,`filterByProp`,`searchText`,`commonFilters`,`detailsMode`,`onlyCommonFilters`,`isFilterLocked`,`isFilterOptionLocked`,`isRangeFilterLocked`,`toggleFilter`,`updateRangeFilter`,`resetRangeFilter`,`setSearchText`,`setDetailsMode`]),createVNode(DisplayControls_default,{displayData:unref(store$1).displayData.value,detailsMode:unref(store$1).detailsMode.value,updateDisplayData:unref(store$1).updateDisplayData,resetDisplayDataToDefaults:unref(store$1).resetDisplayDataToDefaults,setDetailsMode:unref(store$1).setDetailsMode},null,8,[`displayData`,`detailsMode`,`updateDisplayData`,`resetDisplayDataToDefaults`,`setDetailsMode`]),createVNode(unref(bngCardHeading_default),{type:`line`,class:`heading`},{default:withCtx(()=>[..._cache[6]||=[createTextVNode(`Info`,-1)]]),_:1}),_cache[7]||=createBaseVNode(`div`,{class:`scrollable-content`},` Please select an item to see details. `,-1)]))],64)):createCommentVNode(``,!0)],34)),[[unref(BngScopedNav_default),{activated:scopedNavState.isDetailsActive,canDeactivate:()=>!1,canBubbleEvent:canBubbleDetailsEvent,bubbleWhitelistEvents:[`menu`]}],[unref(BngOnUiNav_default),onToggleSectionScope,`context`],[unref(BngUiNavLabel_default),`Filters and more`,`context`],[unref(BngOnUiNav_default),onToggleFavorite,`action_2`],[unref(BngUiNavLabel_default),`Toggle favorite`,`action_2`],[unref(BngOnUiNav_default),onBackFromDetails,`back`,{focusRequired:!0}]])])]),_:3})),[[unref(BngBlur_default)],[unref(BngOnUiNav_default),()=>{},`rotate_h_cam,rotate_v_cam`]])}},GridSelector_default=__plugin_vue_export_helper_default(_sfc_main$311,[[`__scopeId`,`data-v-d340d12f`]]),_hoisted_1$277={class:`details`,"bng-nav-scroll":``},_hoisted_2$228={key:0,class:`preview`},_hoisted_3$202={key:1,class:`content-header`},_hoisted_4$173={key:0,class:`description`},_hoisted_5$149={key:0,class:`specs-grid`},_hoisted_6$128={class:`specs-grid-container`},_hoisted_7$114={class:`spec-content`},_hoisted_8$95={class:`spec-label`},_hoisted_9$85={class:`spec-value`},_hoisted_10$74={key:2,class:`buttons-section`},_sfc_main$310={__name:`AppDetails`,props:{activeItem:{type:Object,default:null},activeItemDetails:{type:Object,default:null},executeButton:{type:Function,required:!0},toggleFavourite:{type:Function,required:!0}},setup(__props){let props=__props,handleButtonClick=buttonId=>{props.executeButton(buttonId)};return(_ctx,_cache)=>withDirectives((openBlock(),createElementBlock(`div`,_hoisted_1$277,[__props.activeItemDetails?.preview?(openBlock(),createElementBlock(`div`,_hoisted_2$228,[createVNode(unref(aspectRatio_default),{class:`preview-image`,ratio:`16:8`,"external-image":__props.activeItemDetails.preview},null,8,[`external-image`])])):createCommentVNode(``,!0),__props.activeItemDetails?.headerTitle?(openBlock(),createElementBlock(`div`,_hoisted_3$202,[__props.activeItemDetails?.description?(openBlock(),createElementBlock(`div`,_hoisted_4$173,toDisplayString(__props.activeItemDetails.description),1)):createCommentVNode(``,!0)])):createCommentVNode(``,!0),(openBlock(!0),createElementBlock(Fragment,null,renderList(__props.activeItemDetails?.specifications,(specList,specListIndex)=>(openBlock(),createElementBlock(Fragment,{key:specListIndex},[specList.length>0?(openBlock(),createElementBlock(`div`,_hoisted_5$149,[createBaseVNode(`div`,_hoisted_6$128,[(openBlock(!0),createElementBlock(Fragment,null,renderList(specList,specification=>(openBlock(),createElementBlock(`div`,{key:specification.key,class:`spec-cell`},[specification.icon?(openBlock(),createBlock(unref(bngIcon_default),{key:0,type:specification.icon,class:`spec-icon`},null,8,[`type`])):createCommentVNode(``,!0),createBaseVNode(`div`,_hoisted_7$114,[createBaseVNode(`div`,_hoisted_8$95,toDisplayString(specification.label)+`:`,1),createBaseVNode(`div`,_hoisted_9$85,[createBaseVNode(`span`,null,toDisplayString(specification.value),1)])])]))),128))])])):createCommentVNode(``,!0)],64))),128)),__props.activeItemDetails?.buttonInfo?.length>0?(openBlock(),createElementBlock(`div`,_hoisted_10$74,[(openBlock(!0),createElementBlock(Fragment,null,renderList(__props.activeItemDetails.buttonInfo,button=>(openBlock(),createBlock(unref(bngButton_default),{key:button.buttonId,"bng-scoped-nav-autofocus":button.primary,accent:button.primary?`main`:`secondary`,label:button.label,icon:button.icon,onClick:$event=>handleButtonClick(button.buttonId)},null,8,[`bng-scoped-nav-autofocus`,`accent`,`label`,`icon`,`onClick`]))),128))])):createCommentVNode(``,!0)])),[[unref(BngUiNavScroll_default),void 0,void 0,{force:!0}]])}},AppDetails_default=__plugin_vue_export_helper_default(_sfc_main$310,[[`__scopeId`,`data-v-c8fb13f2`]]),_sfc_main$309={__name:`AppSelector`,setup(__props){return(_ctx,_cache)=>(openBlock(),createBlock(GridSelector_default,{backendName:`appSelector`,routePath:`/app-selector`,defaultPath:{keys:[`allApps`]},defaultDetailsMode:`advanced`},{"item-details":withCtx(({activeItem,activeItemDetails,executeButton,toggleFavourite})=>[createVNode(AppDetails_default,{activeItem,activeItemDetails,executeButton,toggleFavourite},null,8,[`activeItem`,`activeItemDetails`,`executeButton`,`toggleFavourite`])]),_:1}))}},AppSelector_default=_sfc_main$309,routes_default=[{name:`menu.appselector`,path:`/app-selector/:pathMatch(.*)*`,component:AppSelector_default,props:!0,meta:{clickThrough:!1,infoBar:{visible:!0,showSysInfo:!1},uiApps:{shown:!1},topBar:{visible:!0}}},{name:`menu.appedit`,path:`/app-edit/`,component:NotFound_default,meta:{clickThrough:!0,infoBar:{visible:!0,showSysInfo:!1},uiApps:{shown:!0},topBar:{visible:!0}}}],_hoisted_1$276={class:`main-info`},_hoisted_2$227={class:`heading`},_hoisted_3$201={key:0,class:`stars`},_hoisted_4$172={key:1,class:`aggregate-primary`},_hoisted_5$148={class:`label`},_hoisted_6$127={class:`value`},_hoisted_7$113={key:2,class:`empty-gap`},_sfc_main$308={__name:`PoiCard`,props:{poi:{type:Object,required:!0},shown:{type:Boolean,default:!0}},emits:[`select`,`hover`],setup(__props,{emit:__emit}){let debugLog$1=(message,data)=>{},props=__props,emit$1=__emit,onSelect=()=>{props.poi.id,props.poi.name,emit$1(`select`,props.poi.id)},thumbLoaded=props.shown&&!!props.poi?.thumbnail,thumbShown=ref(thumbLoaded),thumb=ref(thumbLoaded?`url("${props.poi?.thumbnail}")`:`none`),lastThumb=thumbLoaded?props.poi?.thumbnail:void 0;return watch([()=>props.shown,()=>props.poi],()=>{if(props.shown&&props.poi?.thumbnail){let url=props.poi.thumbnail;if(lastThumb!==url){lastThumb=url,thumbLoaded=!1;let img=new Image;img.src=url,img.onload=()=>{lastThumb===url&&(thumbLoaded=!0,thumb.value=`url("${url}")`,thumbShown.value=!0)}}}else props.poi?.thumbnail||(lastThumb=void 0,thumbLoaded=!1,thumb.value=`none`,thumbShown.value=!1)},{immediate:!0}),(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,{class:normalizeClass([`poi-item`,{highlighted:__props.poi.isSelected}]),onClick:onSelect,"bng-nav-item":``},[createBaseVNode(`div`,{class:normalizeClass([`card-info`,{"content-shown":__props.shown,"thumb-show":thumbShown.value&&!!thumb.value}]),style:normalizeStyle({"--poi-image":thumb.value})},[__props.poi.icon?(openBlock(),createBlock(unref(bngIcon_default),{key:0,class:`mission-icon`,type:__props.poi.icon,color:`white`},null,8,[`type`])):createCommentVNode(``,!0),createBaseVNode(`div`,_hoisted_1$276,[createBaseVNode(`div`,_hoisted_2$227,toDisplayString(__props.poi.name),1),__props.poi.formattedProgress?(openBlock(),createElementBlock(`div`,_hoisted_3$201,[__props.poi.formattedProgress.unlockedStars?(openBlock(),createBlock(unref(bngMainStars_default),{key:0,"individual-stars":__props.poi.formattedProgress.unlockedStars.defaults,class:`main-stars`,scale:.6,reverse:``},null,8,[`individual-stars`])):createCommentVNode(``,!0),__props.poi.formattedProgress.unlockedStars&&__props.poi.formattedProgress.unlockedStars.totalBonusStarCount>0?(openBlock(),createBlock(unref(bngMainStars_default),{key:1,"individual-stars":__props.poi.formattedProgress.unlockedStars.bonus,class:`bonus-stars`,scale:.6},null,8,[`individual-stars`])):createCommentVNode(``,!0)])):__props.poi.aggregatePrimary?(openBlock(),createElementBlock(`div`,_hoisted_4$172,[createBaseVNode(`span`,_hoisted_5$148,toDisplayString(__props.poi.aggregatePrimary.label)+`:`,1),createBaseVNode(`span`,_hoisted_6$127,toDisplayString(__props.poi.aggregatePrimary.value),1)])):(openBlock(),createElementBlock(`div`,_hoisted_7$113))]),createVNode(unref(bngBinding_default),{class:`input-icon`,"ui-event":`ok`,controller:``})],6)],2))}},PoiCard_default=__plugin_vue_export_helper_default(_sfc_main$308,[[`__scopeId`,`data-v-cd49bd11`]]),_hoisted_1$275={class:`poi-list`},_hoisted_2$226={class:`filter-header`},_hoisted_3$200={class:`poi-list-items`},_sfc_main$307={__name:`PoiList`,props:{store:{type:Object,required:!0}},setup(__props){let props=__props,poiListContainer=ref(null),shownCards=ref(new Set),{groupData,poiData,selectedPoi,selectPoi,onHover,debugLog:debugLog$1}=props.store,processedPoiData=computed(()=>{let processed={};if(!poiData.value)return processed;for(let[poiId,poi]of Object.entries(poiData.value))poi&&(processed[poiId]={id:poi.id||poiId,name:poi.name?$translate.instant(poi.name):``,icon:poi.icon?icons[poi.icon]:icons._empty,thumbnail:poi.thumbnailFile,formattedProgress:poi.formattedProgress,aggregatePrimary:poi.aggregatePrimary?.label&&poi.aggregatePrimary?.value?{label:$translate.instant(poi.aggregatePrimary.label),value:$translate.instant(poi.aggregatePrimary.value)}:null,isSelected:selectedPoi.value?.id===poi.id});return processed});debugLog$1(`PoiList`,`Component initialized`,{groupDataCount:groupData.value?.length||0,poiDataCount:Object.keys(poiData.value||{}).length,processedPoiCount:Object.keys(processedPoiData.value).length});let observer$2=new IntersectionObserver(entries=>{for(let entry of entries){let poiId=entry.target.getAttribute(`data-poi-id`);poiId&&entry.isIntersecting?shownCards.value.add(poiId):shownCards.value.delete(poiId)}},{threshold:.1,rootMargin:`10px`}),setupObserver=()=>{if(!poiListContainer.value)return;let elms$4=poiListContainer.value.querySelectorAll(`[data-poi-id]`),ids=[];for(let elm of elms$4){let poiId=elm.getAttribute(`data-poi-id`);poiId&&(ids.push(poiId),observer$2.observe(elm))}for(let id of shownCards.value)ids.includes(id)||shownCards.value.delete(id)};return watch(poiListContainer,cont=>cont&&nextTick(setupObserver),{immediate:!0}),watch([groupData,processedPoiData],()=>{nextTick(()=>{observer$2.disconnect(),setupObserver()})},{immediate:!1}),onUnmounted(()=>{shownCards.value.clear(),observer$2.disconnect()}),(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$275,[createBaseVNode(`div`,{class:`poi-list-content`,ref_key:`poiListContainer`,ref:poiListContainer},[(openBlock(!0),createElementBlock(Fragment,null,renderList(unref(groupData),section=>(openBlock(),createElementBlock(`div`,{key:section.key,class:`filter-section`},[createBaseVNode(`div`,_hoisted_2$226,[createVNode(unref(bngIcon_default),{type:section.icon},null,8,[`type`]),createBaseVNode(`span`,null,toDisplayString(section.title?_ctx.$tt(section.title):``),1)]),(openBlock(!0),createElementBlock(Fragment,null,renderList(section.groups,group=>(openBlock(),createElementBlock(`div`,{key:group.key,class:`mission-group`},[createVNode(unref(bngCardHeading_default),{class:`mission-group-header`,type:`ribbon`,outline:``},{default:withCtx(()=>[createTextVNode(toDisplayString(_ctx.$t(group.label)),1)]),_:2},1024),createBaseVNode(`div`,_hoisted_3$200,[(openBlock(!0),createElementBlock(Fragment,null,renderList(group.elementIds,poiId=>(openBlock(),createBlock(PoiCard_default,{key:poiId,"data-poi-id":poiId,shown:shownCards.value.has(poiId),poi:processedPoiData.value[poiId],onSelect:unref(selectPoi),onHover:unref(onHover)},null,8,[`data-poi-id`,`shown`,`poi`,`onSelect`,`onHover`]))),128))])]))),128))]))),128))],512)]))}},PoiList_default=__plugin_vue_export_helper_default(_sfc_main$307,[[`__scopeId`,`data-v-0ccba230`]]),_hoisted_1$274={class:`header`},_sfc_main$306={__name:`bngAdvCardHeading`,props:{blurDelay:Number,preheadings:Array,divider:Boolean,icon:String,type:{type:String,default:`line`,validator:v=>[`line`,`ribbon`].includes(v)||v===``}},setup(__props){let blurVal=ref(!1);onMounted(()=>window.setTimeout(()=>blurVal.value=!0,~~+props.blurDelay));let props=__props;return(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,{class:normalizeClass([`bng-screen-header`,{[`heading-style-${__props.type}`]:!0,prehead:__props.preheadings}])},[_cache[0]||=createBaseVNode(`div`,{class:`decorator`},null,-1),__props.preheadings?(openBlock(),createElementBlock(`span`,{key:0,class:normalizeClass([`pre-header`,{"with-divider":__props.divider}])},[__props.icon?(openBlock(),createBlock(unref(bngIcon_default),{key:0,type:__props.icon,class:`pre-header-icon`},null,8,[`type`])):createCommentVNode(``,!0),(openBlock(!0),createElementBlock(Fragment,null,renderList(__props.preheadings,preheading=>(openBlock(),createElementBlock(`span`,{class:`location`,key:preheading},toDisplayString(preheading),1))),128))],2)):createCommentVNode(``,!0),createBaseVNode(`h1`,_hoisted_1$274,[renderSlot(_ctx.$slots,`default`,{},void 0,!0)])],2))}},bngAdvCardHeading_default=__plugin_vue_export_helper_default(_sfc_main$306,[[`__scopeId`,`data-v-16619e8d`]]),_hoisted_1$273={key:0,class:`poi-icons`},_hoisted_2$225=[`onClick`],_hoisted_3$199={key:1,class:`poi-details`},_hoisted_4$171={class:`poi-content`},_hoisted_5$147={class:`poi-scrollable`},_hoisted_6$126={key:0,class:`poi-aggregate-display`},_hoisted_7$112={key:0,class:`poi-stars`},_hoisted_8$94={class:`stars`},_hoisted_9$84={key:1,class:`aggregate-primary`},_hoisted_10$73={class:`label`},_hoisted_11$66={class:`value`},_hoisted_12$54={key:1,class:`poi-description`},_hoisted_13$47={class:`poi-actions`},_sfc_main$305={__name:`PoiDetails`,props:{store:{type:Object,required:!0}},emits:[`setRoute`,`teleport`],setup(__props,{emit:__emit}){let props=__props,{selectedPoi,selectedPoiIds,poiData,debugLog:debugLog$1}=props.store;debugLog$1(`PoiDetails`,`Component initialized`,{selectedPoiId:selectedPoi.value?.id,selectedPoiIdsCount:selectedPoiIds.value?.length||0});let selectedPoisList=computed(()=>{if(!selectedPoiIds.value||selectedPoiIds.value.length===0)return selectedPoi.value?[selectedPoi.value]:[];let pois=[];for(let poiId of selectedPoiIds.value){let poi=poiData.value[poiId];poi&&pois.push(poi)}return debugLog$1(`PoiDetails`,`Final pois list`,pois),pois}),currentPoiIndex=computed(()=>{if(selectedPoisList.value.length<=1)return 0;let index=selectedPoisList.value.findIndex(poi=>poi.id===selectedPoi.value?.id);return index>=0?index:0}),selectPoi=index=>{index>=0&&index{let headings=[];return selectedPoi.value?.label&&headings.push($translate.instant(selectedPoi.value.label)),headings}),preview=computed(()=>selectedPoi.value?.previewFiles?.length>0?selectedPoi.value.previewFiles[0]:selectedPoi.value?.thumbnailFile||null),safeTranslate=key=>{if(!key)return``;try{return typeof key==`string`?$translate.instant(key):(typeof key==`object`&&key.txt,$translate.contextTranslate(key))}catch(e){return console.warn(`Translation failed for key:`,key,e),typeof key==`string`?key:key?.txt||``}},aggregatePrimary=computed(()=>{let poi=selectedPoi.value;return poi?.aggregatePrimary?.label&&poi?.aggregatePrimary?.value?poi.aggregatePrimary:null}),onAction=action=>{props.store.executePoiAction(action.actionId)};return(_ctx,_cache)=>(openBlock(),createElementBlock(Fragment,null,[selectedPoisList.value.length>=1?withDirectives((openBlock(),createElementBlock(`div`,_hoisted_1$273,[(openBlock(!0),createElementBlock(Fragment,null,renderList(selectedPoisList.value,(poi,index)=>(openBlock(),createElementBlock(`div`,{key:poi.id||index,class:normalizeClass([`poi-icon`,{active:index===currentPoiIndex.value}]),onClick:$event=>selectPoi(index)},[createVNode(unref(bngSpriteIcon_default),{src:`map_`+poi.spriteIcon,style:{width:`100%`,height:`100%`}},null,8,[`src`])],10,_hoisted_2$225))),128))])),[[unref(BngBlur_default),!0]]):createCommentVNode(``,!0),unref(selectedPoi)?withDirectives((openBlock(),createElementBlock(`div`,_hoisted_3$199,[createBaseVNode(`div`,_hoisted_4$171,[createVNode(bngAdvCardHeading_default,{class:`poi-details-header`,type:`line`,preheadings:preheadings.value},{default:withCtx(()=>[createTextVNode(toDisplayString(safeTranslate(unref(selectedPoi).name)),1)]),_:1},8,[`preheadings`]),createBaseVNode(`div`,_hoisted_5$147,[preview.value?(openBlock(),createBlock(aspectRatio_default,{key:0,class:`poi-thumbnail`,ratio:`16:9`,externalImage:preview.value,imageMode:`cover`},{default:withCtx(()=>[aggregatePrimary.value||unref(selectedPoi).formattedProgress?(openBlock(),createElementBlock(`div`,_hoisted_6$126,[unref(selectedPoi).formattedProgress?(openBlock(),createElementBlock(`div`,_hoisted_7$112,[createBaseVNode(`div`,_hoisted_8$94,[unref(selectedPoi).formattedProgress.unlockedStars?(openBlock(),createBlock(unref(bngMainStars_default),{key:0,individualStars:unref(selectedPoi).formattedProgress.unlockedStars.defaults,class:`main-stars`,scale:.8,reverse:``},null,8,[`individualStars`])):createCommentVNode(``,!0),unref(selectedPoi).formattedProgress.unlockedStars&&unref(selectedPoi).formattedProgress.unlockedStars.totalBonusStarCount>0?(openBlock(),createBlock(unref(bngMainStars_default),{key:1,individualStars:unref(selectedPoi).formattedProgress.unlockedStars.bonus,class:`bonus-stars`,scale:.8},null,8,[`individualStars`])):createCommentVNode(``,!0)])])):aggregatePrimary.value?(openBlock(),createElementBlock(`div`,_hoisted_9$84,[createBaseVNode(`span`,_hoisted_10$73,toDisplayString(_ctx.$t(aggregatePrimary.value.label))+`:`,1),createBaseVNode(`span`,_hoisted_11$66,toDisplayString(_ctx.$t(aggregatePrimary.value.value)),1)])):createCommentVNode(``,!0)])):createCommentVNode(``,!0)]),_:1},8,[`externalImage`])):createCommentVNode(``,!0),unref(selectedPoi).description?(openBlock(),createElementBlock(`div`,_hoisted_12$54,toDisplayString(safeTranslate(unref(selectedPoi).description)),1)):createCommentVNode(``,!0)]),createBaseVNode(`div`,_hoisted_13$47,[(openBlock(!0),createElementBlock(Fragment,null,renderList(unref(selectedPoi).actions,action=>(openBlock(),createBlock(unref(bngButton_default),{key:action.id,accent:unref(ACCENTS).secondary,"icon-right":action.icon,label:action.label,onClick:$event=>onAction(action)},null,8,[`accent`,`icon-right`,`label`,`onClick`]))),128))])])])),[[unref(BngBlur_default),!0]]):createCommentVNode(``,!0)],64))}},PoiDetails_default=__plugin_vue_export_helper_default(_sfc_main$305,[[`__scopeId`,`data-v-35e47e7e`]]),_hoisted_1$272={class:`poi-filters`},_hoisted_2$224={key:0,class:`filter-row`},_hoisted_3$198=[`onClick`],_hoisted_4$170=[`onClick`],_sfc_main$304={__name:`PoiFilters`,props:{store:{type:Object,required:!0}},setup(__props){let props=__props,{filterData,debugLog:debugLog$1}=props.store;debugLog$1(`PoiFilters`,`Component initialized`,{filterDataCount:filterData.value?.length||0});let getGroupVisualState=(filter,group)=>{if(!filter||!group||!filter.groups||!Array.isArray(filter.groups))return`inactive`;let visibleGroups=0,totalGroups=0;for(let filterGroup of filter.groups)filterGroup&&filterGroup.elementCount>0&&(totalGroups++,filterGroup.visible&&visibleGroups++);let isAllGroupsActive=visibleGroups===totalGroups,isGroupActive=group.visible;return isAllGroupsActive?`neutral`:isGroupActive?`active`:`inactive`},getGroupColor=(filter,group)=>{switch(getGroupVisualState(filter,group)){case`neutral`:return`var(--bng-off-white)`;case`active`:return`var(--bng-add-green-100)`;case`inactive`:default:return`var(--bng-add-red-300)`}},hasActiveFilters=filter=>{if(!filter||!filter.groups||!Array.isArray(filter.groups))return!1;let visibleGroups=0,totalGroups=0;for(let group of filter.groups)group&&group.elementCount>0&&(totalGroups++,group.visible&&visibleGroups++);return visibleGroups{debugLog$1(`PoiFilters`,`Toggling group visibility`,groupKey),props.store.toggleGroupVisibility(groupKey)},toggleFilterSectionVisibility=filterKey=>{debugLog$1(`PoiFilters`,`Toggling filter section visibility`,filterKey),props.store.toggleFilterSectionVisibility(filterKey)};return(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$272,[(openBlock(!0),createElementBlock(Fragment,null,renderList(unref(filterData),filterSection=>(openBlock(),createElementBlock(Fragment,{key:filterSection.key},[filterSection&&filterSection.groups?withDirectives((openBlock(),createElementBlock(`div`,_hoisted_2$224,[createBaseVNode(`div`,{class:normalizeClass([`filter-icon`,{"has-active-filters":hasActiveFilters(filterSection)}]),onClick:$event=>toggleFilterSectionVisibility(filterSection.key)},[createVNode(bngTooltip_default,{text:_ctx.$tt(filterSection.title)},{default:withCtx(()=>[createVNode(unref(bngIcon_default),{type:filterSection.icon},null,8,[`type`])]),_:2},1032,[`text`])],10,_hoisted_3$198),_cache[0]||=createBaseVNode(`div`,{class:`filter-separator`},null,-1),(openBlock(!0),createElementBlock(Fragment,null,renderList(filterSection.groups,group=>(openBlock(),createElementBlock(Fragment,{key:group.key},[group&&group.elementCount>0?(openBlock(),createElementBlock(`div`,{key:0,class:normalizeClass([`filter-group`,{inactive:!group.visible}]),onClick:$event=>toggleGroupVisibility(group.key)},[createVNode(bngTooltip_default,{text:_ctx.$tt(group.label)+` ×`+group.elementCount},{default:withCtx(()=>[createVNode(unref(bngIcon_default),{type:group.icon||`info`,color:getGroupColor(filterSection,group)},null,8,[`type`,`color`])]),_:2},1032,[`text`])],10,_hoisted_4$170)):createCommentVNode(``,!0)],64))),128))])),[[unref(BngBlur_default),!0]]):createCommentVNode(``,!0)],64))),128))]))}},PoiFilters_default=__plugin_vue_export_helper_default(_sfc_main$304,[[`__scopeId`,`data-v-43aa27ac`]]);const debugLog=(component,message,data)=>{};function useBigMap(){let selectedPoi=ref(null),selectedPoiIds=ref([]),filterData=ref([]),groupData=ref([]),poiData=ref({}),gameMode=ref(``),levelData=ref({title:``}),isPoiListVisible=ref(!1),isDetailsVisible=ref(!1),{events:events$3}=useBridge(),translatedPreheadings=computed(()=>{let preheadings=[];return gameMode.value&&preheadings.push($translate.instant(`ui.playmodes.${gameMode.value}`)),levelData.value?.title&&preheadings.push($translate.instant(levelData.value.title)),preheadings}),currentFilterTitle=computed(()=>$translate.instant(`bigMap.sideMenu.pois`)),getStaticDataFromLua=async()=>{try{poiData.value=await Lua_default.freeroam_vueBigMap.getPoiData()||{};let gameStateResult=await Lua_default.freeroam_vueBigMap.getGameStateInfo();gameStateResult&&(gameMode.value=gameStateResult.gameMode||``,levelData.value=gameStateResult.levelData||{title:``}),poiData.value,gameMode.value}catch(error){console.error(`Error getting static data from Lua:`,error)}},getDynamicDataFromLua=async()=>{try{filterData.value=await Lua_default.freeroam_vueBigMap.getFilters()||[],groupData.value=await Lua_default.freeroam_vueBigMap.getGroups()||[],filterData.value,groupData.value}catch(error){console.error(`Error getting dynamic data from Lua:`,error)}},handleShowPoiDetails=data=>{let poiIds=data?.poiIds||[];if(selectedPoiIds.value=poiIds,poiIds.length===0){selectedPoi.value=null,isDetailsVisible.value=!1;return}let selectedPoiId=poiIds[0];selectedPoiId&&poiData.value[selectedPoiId]?(selectedPoi.value=poiData.value[selectedPoiId],isDetailsVisible.value=!0):(selectedPoi.value=null,isDetailsVisible.value=!1)},toggleGroupVisibility=async groupKey=>{try{let filterIds=[groupKey];await Lua_default.freeroam_vueBigMap.toggleFiltersByIds(filterIds),await getDynamicDataFromLua()}catch(error){console.error(`Error toggling group visibility:`,error)}},toggleFilterSectionVisibility=async filterKey=>{try{await Lua_default.freeroam_vueBigMap.toggleFilterSectionById(filterKey),await getDynamicDataFromLua()}catch(error){console.error(`Error toggling filter visibility:`,error)}},selectPoi=async poiId=>{try{let result=await Lua_default.freeroam_vueBigMap.selectPoiFromList(poiId);result===`success`?poiId?(selectedPoi.value=poiData.value[poiId],isDetailsVisible.value=!0):(selectedPoi.value=null,isDetailsVisible.value=!1):console.error(`Failed to select POI:`,result)}catch(error){console.error(`Error selecting POI:`,error)}};return{selectedPoi,selectedPoiIds,filterData,groupData,poiData,gameMode,levelData,isPoiListVisible,isDetailsVisible,translatedPreheadings,currentFilterTitle,initialize:async()=>{try{await Lua_default.freeroam_vueBigMap.enterBigMap(),await getStaticDataFromLua(),await getDynamicDataFromLua(),events$3.on(`showPoiDetails`,handleShowPoiDetails)}catch(error){console.error(`Error initializing bigmap:`,error)}},cleanup:async()=>{try{await Lua_default.freeroam_vueBigMap.exitBigMap(),events$3.off(`showPoiDetails`)}catch(error){console.error(`Error cleaning up bigmap:`,error)}},selectPoi,showPoiList:()=>{isPoiListVisible.value=!0},hidePoiList:()=>{isPoiListVisible.value=!1,selectedPoi.value&&selectPoi(null)},onHover:async(poiId,active)=>{try{await Lua_default.freeroam_vueBigMap.hoverPoiFromList(poiId,active)}catch(error){console.error(`Error hovering POI:`,error)}},executePoiAction:async actionId=>{try{await Lua_default.freeroam_vueBigMap.executePoiAction(actionId)}catch(error){console.error(`Error executing POI action:`,error)}},toggleGroupVisibility,toggleFilterSectionVisibility,debugLog}}var _hoisted_1$271={class:`bigmap-container`},_hoisted_2$223={class:`bigmap-content`},_hoisted_3$197={class:`bigmap-left-content`},_hoisted_4$169={class:`bigmap-poilist-outline`},_hoisted_5$146={key:0,class:`bigmap-details-outline`},_sfc_main$303={__name:`BigMap`,setup(__props){let store$1=useBigMap(),{isPoiListVisible,isDetailsVisible,translatedPreheadings,currentFilterTitle,onSetRoute,onTeleport,toggleGroupVisibility,initialize,cleanup,debugLog:debugLog$1}=store$1,handleToggleGroupVisibility=groupKey=>{debugLog$1(`BigMap`,`Toggle group visibility`,groupKey),toggleGroupVisibility(groupKey)};return onMounted(()=>{debugLog$1(`BigMap`,`Component mounted, initializing bigmap`),initialize()}),onUnmounted(()=>{debugLog$1(`BigMap`,`Component unmounted, cleaning up bigmap`),cleanup()}),(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$271,[createVNode(unref(bngScreenHeading_default),{class:`bigmap-heading`,preheadings:unref(translatedPreheadings),divider:!0,type:`line`},{default:withCtx(()=>[createTextVNode(toDisplayString(unref(currentFilterTitle)),1)]),_:1},8,[`preheadings`]),createBaseVNode(`div`,_hoisted_2$223,[createBaseVNode(`div`,_hoisted_3$197,[createVNode(PoiFilters_default,{store:unref(store$1),onToggleGroupVisibility:handleToggleGroupVisibility},null,8,[`store`]),createBaseVNode(`div`,_hoisted_4$169,[createVNode(unref(bngDrawer_default),{modelValue:unref(isPoiListVisible),"onUpdate:modelValue":_cache[0]||=$event=>isRef(isPoiListVisible)?isPoiListVisible.value=$event:null,position:`left`,blur:``,header:_ctx.$tt(`bigMap.sideMenu.pois`)},{default:withCtx(()=>[createVNode(PoiList_default,{class:`bigmap-poilist`,store:unref(store$1)},null,8,[`store`])]),_:1},8,[`modelValue`,`header`])])]),_cache[1]||=createBaseVNode(`div`,{class:`bigmap-center-outline`},null,-1),unref(isDetailsVisible)?(openBlock(),createElementBlock(`div`,_hoisted_5$146,[createVNode(PoiDetails_default,{store:unref(store$1),onSetRoute:unref(onSetRoute),onTeleport:unref(onTeleport)},null,8,[`store`,`onSetRoute`,`onTeleport`])])):createCommentVNode(``,!0)])]))}},BigMap_default=__plugin_vue_export_helper_default(_sfc_main$303,[[`__scopeId`,`data-v-e6716bb0`]]),_hoisted_1$270={class:`bigmap-view`},_sfc_main$302={__name:`BigMapView`,setup(__props){return(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$270,[createVNode(BigMap_default)]))}},BigMapView_default=__plugin_vue_export_helper_default(_sfc_main$302,[[`__scopeId`,`data-v-044f4742`]]),routes_default$1=[{path:`/bigmap`,name:`bigmap`,component:BigMapView_default,meta:{uiApps:{shown:!1},infoBar:{visible:!0,showSysInfo:!0}}}],_hoisted_1$269={class:`progress-steps`},_hoisted_2$222={class:`step-container`},_hoisted_3$196={class:`step-header`},_hoisted_4$168={class:`step-number`},_hoisted_5$145={class:`step-icon`},_hoisted_6$125={class:`step-label`},_sfc_main$301={__name:`ProgressSteps`,props:{steps:{type:Array,required:!0,validator:steps=>steps.every(step=>step.label&&typeof step.label==`string`||step.title&&typeof step.title==`string`)},currentStep:{type:Number,required:!0,validator:step=>step>=0}},setup(__props){let props=__props,styles={answeredYes:{class:`answered-yes`,icon:`checkboxOn`},answeredNo:{class:`answered-no`,icon:`missionCheckboxCross`},current:{class:`not-answered current`,icon:`arrowLargeRight`},next:{class:`not-answered`,icon:`checkboxOff`}},steps=computed(()=>props.steps.map((step,idx)=>{let answer=step.isAnswered?step.answerType||`yes`:null,status=`next`;return idx(openBlock(),createElementBlock(`div`,_hoisted_1$269,[createBaseVNode(`div`,_hoisted_2$222,[(openBlock(!0),createElementBlock(Fragment,null,renderList(steps.value,(step,index)=>(openBlock(),createElementBlock(`div`,{key:index,class:normalizeClass([`step`,step.class])},[createBaseVNode(`div`,_hoisted_3$196,[createBaseVNode(`div`,_hoisted_4$168,toDisplayString(index+1),1),step.isLastStep?createCommentVNode(``,!0):(openBlock(),createElementBlock(Fragment,{key:0},[_cache[0]||=createBaseVNode(`div`,{class:`step-connector`},null,-1),createBaseVNode(`div`,_hoisted_5$145,[createVNode(unref(bngIcon_default),{type:step.icon},null,8,[`type`])])],64))]),createBaseVNode(`div`,_hoisted_6$125,toDisplayString(_ctx.$tt(step.label)),1)],2))),128))])]))}},ProgressSteps_default=__plugin_vue_export_helper_default(_sfc_main$301,[[`__scopeId`,`data-v-d5d29cd2`]]);function useWizard(options={}){let{allowSkip=!1,validateSteps=!0}=options,stepRegistry=ref(new Map),currentStepIndex=ref(0),completedSteps=ref(new Set),isFinished=ref(!1),steps=computed(()=>{if(stepRegistry.value.size===0)return[];let res=Array.from(stepRegistry.value.values());for(let step of res)if(!(!step.enabledWhen||step.enabledWhen.length===0)){for(let condition of step.enabledWhen)if(condition.step){let dependencyStep=res.find(s=>s.id===condition.step);if(!dependencyStep)continue;dependencyStep.requiredFor||=[],dependencyStep.requiredFor.includes(step.id)||dependencyStep.requiredFor.push(step.id)}}return res}),registerStep=stepConfig=>stepRegistry.value.set(stepConfig.id,stepConfig),unregisterStep=stepId=>stepRegistry.value.delete(stepId);provide(`registerWizardStep`,registerStep),provide(`unregisterWizardStep`,unregisterStep);let currentStep=computed(()=>steps.value[currentStepIndex.value]||null),isFirstStep=computed(()=>currentStepIndex.value===0),isLastStep=computed(()=>currentStepIndex.value===steps.value.length-1),canGoNext=computed(()=>{if(!validateSteps)return!0;let step=currentStep.value;return!step||!isStepEnabled(step)||step.advanceDisabled?!1:typeof step.validate==`function`?step.validate(step.modelValue||{}):step.type===`choice`&&step.required!==!1?step.modelValue?.choice!==void 0:(step.type,!0)}),isStepEnabled=step=>!step.enabledWhen||step.enabledWhen.length===0?!0:step.enabledWhen.every(condition=>{if(condition.step){let dependencyStepData=steps.value.find(s=>s.id===condition.step)?.modelValue||{};if(condition.value!==void 0)return dependencyStepData?.choice===condition.value||dependencyStepData?.[Object.keys(dependencyStepData)[0]]===condition.value;if(typeof condition.condition==`function`)return condition.condition(dependencyStepData)}return typeof condition.condition==`function`?condition.condition():!0}),canGoBack=computed(()=>!isFirstStep.value),canFinish=computed(()=>validateSteps?isLastStep.value&&canGoNext.value:isLastStep.value),goToStep=index=>{index<=0&&(currentStepIndex.value=0),index>=steps.value.length&&(currentStepIndex.value=steps.value.length-1),currentStepIndex.value=index},nextStep=async()=>{if(await nextTick(),!canGoNext.value)return!1;if(currentStep.value&&completedSteps.value.add(currentStepIndex.value),isLastStep.value)return!0;for(currentStepIndex.value++;currentStepIndex.value=steps.value.length&&(currentStepIndex.value=steps.value.length-1),!0};return{currentStepIndex,currentStep,completedSteps,isFinished,steps,stepRegistry,isFirstStep,isLastStep,canGoNext,canGoBack,canFinish,progress:computed(()=>steps.value.length===0?0:Math.round((currentStepIndex.value+1)/steps.value.length*100)),stepProgress:computed(()=>steps.value.map((step,index)=>{let data=step.modelValue||{},choiceAnalysis=null;if(step.type===`choice`&&step.choices&&data.choice!==void 0){let selectedChoice=step.choices.find(c=>c.value===data.choice),yesChoice=step.choices.find(c=>c.isYes),noChoice=step.choices.find(c=>c.isNo),answerType=null;selectedChoice&&(answerType=selectedChoice.isYes||yesChoice&&selectedChoice.value===yesChoice.value?`yes`:selectedChoice.isNo||noChoice&&selectedChoice.value===noChoice.value?`no`:!yesChoice&&!noChoice?`yes`:step.choices.length===2&&!selectedChoice.isYes&&!selectedChoice.isNo?`no`:`yes`),choiceAnalysis={selectedValue:data.choice,selectedChoice,answerType,hasYesFlag:!!yesChoice,hasNoFlag:!!noChoice}}return{...step,index,isCompleted:completedSteps.value.has(index),isCurrent:index===currentStepIndex.value,isAccessible:index<=currentStepIndex.value,isEnabled:isStepEnabled(step),data,hasData:Object.keys(data).length>0,isAnswered:step.type===`choice`?data.choice!==void 0:Object.keys(data).length>0,answerType:choiceAnalysis?.answerType||null,choiceAnalysis}})),goToStep,nextStep,previousStep:async()=>{if(await nextTick(),!canGoBack.value)return!1;for(currentStepIndex.value--;currentStepIndex.value>=0;){let targetStep=steps.value[currentStepIndex.value];if(isStepEnabled(targetStep)||targetStep.autoSkip===!1)break;currentStepIndex.value--}return currentStepIndex.value<0&&(currentStepIndex.value=0),!0},finish:()=>canFinish.value?(isFinished.value=!0,{success:!0,completedSteps:Array.from(completedSteps.value)}):{success:!1},reset:()=>{currentStepIndex.value=0,completedSteps.value.clear(),isFinished.value=!1},skip:()=>allowSkip?nextStep():!1,isStepEnabled,registerStep,unregisterStep}}var _hoisted_1$268={class:`wizard-container`},_hoisted_2$221={class:`wizard-content`},_hoisted_3$195={class:`wizard-step-content`},_hoisted_4$167={key:0,class:`wizard-validation`},_hoisted_5$144={class:`validation-message`},_hoisted_6$124={class:`wizard-navigation`},_hoisted_7$111={key:2,class:`switch-buttons`};const wizardProps={wizardOptions:{type:Object,default:()=>({})},title:String,preheadings:Array,showDivider:{type:Boolean,default:!0},showProgress:{type:Boolean,default:!0},showBackButton:{type:Boolean,default:!0},allowSkip:{type:Boolean,default:!1},backButtonText:{type:String,default:`ui.common.back`},nextButtonText:{type:String,default:`ui.common.next`},finishButtonText:{type:String,default:`ui.common.finish`},skipButtonText:{type:String,default:`ui.common.skip`},validationMessage:String};var _sfc_main$300={__name:`Wizard`,props:mergeModels(wizardProps,{modelValue:{default:()=>({})},modelModifiers:{}}),emits:mergeModels([`step-change`,`step-complete`,`wizard-finish`,`validation-error`],[`update:modelValue`]),setup(__props,{expose:__expose,emit:__emit}){let props=__props,modelValue=useModel(__props,`modelValue`),emit$1=__emit,{currentStepIndex,currentStep,isFirstStep,isLastStep,canGoNext,canGoBack,canFinish,progress,stepProgress,nextStep:wizardNextStep,previousStep:wizardPreviousStep,skip:wizardSkip,steps,registerStep:originalRegisterStep}=useWizard({...props.wizardOptions,allowSkip:props.allowSkip}),instance$1=getCurrentInstance(),hasCentralizedModel=computed(()=>!!(instance$1&&instance$1.attrs&&`onUpdate:modelValue`in instance$1.attrs));provide(`currentWizardStep`,currentStep),provide(`wizardNext`,()=>nextStep()),provide(`wizardSteps`,steps),provide(`registerWizardStep`,stepConfig=>hasCentralizedModel.value?originalRegisterStep({...stepConfig,get modelValue(){return modelValue.value?.[stepConfig.id]||{}},updateModelValue:newValue=>{modelValue.value={...modelValue.value,[stepConfig.id]:newValue}}}):originalRegisterStep(stepConfig)),provide(`unregisterWizardStep`,stepId=>{if(hasCentralizedModel.value&&props.modelValue[stepId]){let updatedData={...props.modelValue};delete updatedData[stepId],emit$1(`update:modelValue`,updatedData)}});let currentStepChoices=computed(()=>currentStep.value?.choices||[]),getChoiceButtonClass=(choiceValue,selectedChoice)=>selectedChoice?selectedChoice===choiceValue?`answered-selected`:`answered-not-selected`:`unanswered`,handleChoiceClick=choice=>{currentStep.value?.updateModelValue&&(currentStep.value.updateModelValue({...currentStep.value.modelValue,choice:choice.value}),nextTick(()=>!currentStep.value?.advanceDisabled&&nextStep()))},nextStep=()=>{let stepId=currentStep.value?.id,currentData=currentStep.value?.modelValue||{};emit$1(`step-complete`,{stepId,stepIndex:currentStepIndex.value,step:currentStep.value,data:currentData}),wizardNextStep()&&emit$1(`step-change`,{from:currentStepIndex.value-1,to:currentStepIndex.value,step:currentStep.value})},previousStep=()=>{let prevIndex=currentStepIndex.value;wizardPreviousStep()&&emit$1(`step-change`,{from:prevIndex,to:currentStepIndex.value,step:currentStep.value})},skip=()=>{wizardSkip()&&emit$1(`step-complete`,{stepId:currentStep.value?.id,stepIndex:currentStepIndex.value-1,skipped:!0,data:currentStep.value?.modelValue||{}})},handleFinish=()=>{let allStepData={};steps.value.forEach(step=>{step.modelValue&&Object.keys(step.modelValue).length>0&&(allStepData[step.id]=step.modelValue)}),canFinish.value?emit$1(`wizard-finish`,{success:!0,data:allStepData,completedSteps:Array.from({length:steps.value.length},(_,i)=>i)}):emit$1(`validation-error`,{step:currentStep.value,message:`Cannot finish wizard - validation failed`})};return __expose({currentStepIndex,currentStep,progress,stepProgress,nextStep,previousStep,finish:handleFinish,skip,steps}),(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$268,[createBaseVNode(`div`,_hoisted_2$221,[_ctx.title?(openBlock(),createBlock(unref(bngScreenHeading_default),{key:0,preheadings:_ctx.preheadings,"show-divider":_ctx.showDivider},{default:withCtx(()=>[createTextVNode(toDisplayString(_ctx.$tt(_ctx.title)),1)]),_:1},8,[`preheadings`,`show-divider`])):createCommentVNode(``,!0),_ctx.showProgress?(openBlock(),createBlock(unref(bngCard_default),{key:1,class:`wizard-progress-card`},{default:withCtx(()=>[createVNode(ProgressSteps_default,{steps:unref(stepProgress),"current-step":unref(currentStepIndex)},null,8,[`steps`,`current-step`])]),_:1})):createCommentVNode(``,!0),createVNode(unref(bngCard_default),{class:`wizard-main-card`},{buttons:withCtx(()=>[createBaseVNode(`div`,_hoisted_6$124,[_ctx.showBackButton&&!unref(isFirstStep)?(openBlock(),createBlock(unref(bngButton_default),{key:0,disabled:!unref(canGoBack),accent:unref(ACCENTS).secondary,onClick:previousStep},{default:withCtx(()=>[createTextVNode(toDisplayString(_ctx.$tt(_ctx.backButtonText)),1)]),_:1},8,[`disabled`,`accent`])):createCommentVNode(``,!0),_ctx.allowSkip&&!unref(isLastStep)&&unref(currentStep)?.type!==`choice`?(openBlock(),createBlock(unref(bngButton_default),{key:1,accent:unref(ACCENTS).secondary,onClick:skip},{default:withCtx(()=>[createTextVNode(toDisplayString(_ctx.$tt(_ctx.skipButtonText)),1)]),_:1},8,[`accent`])):createCommentVNode(``,!0),_cache[0]||=createBaseVNode(`div`,{class:`spacer`},null,-1),unref(currentStep)?.type===`choice`?(openBlock(),createElementBlock(`div`,_hoisted_7$111,[(openBlock(!0),createElementBlock(Fragment,null,renderList(currentStepChoices.value,choice=>(openBlock(),createBlock(unref(bngButton_default),{key:choice.value,class:normalizeClass(getChoiceButtonClass(choice.value,unref(currentStep)?.modelValue?.choice||null)),accent:unref(ACCENTS).custom,icon:unref(currentStep)?.modelValue?.choice===choice.value?unref(icons).checkmark:null,disabled:unref(currentStep)?.advanceDisabled,onClick:$event=>handleChoiceClick(choice)},{default:withCtx(()=>[createTextVNode(toDisplayString(_ctx.$tt(choice.label)),1)]),_:2},1032,[`class`,`accent`,`icon`,`disabled`,`onClick`]))),128))])):createCommentVNode(``,!0),!unref(isLastStep)&&unref(currentStep)?.type!==`choice`?(openBlock(),createBlock(unref(bngButton_default),{key:3,disabled:!unref(canGoNext),accent:unref(ACCENTS).primary,onClick:nextStep},{default:withCtx(()=>[createTextVNode(toDisplayString(_ctx.$tt(_ctx.nextButtonText)),1)]),_:1},8,[`disabled`,`accent`])):unref(isLastStep)?(openBlock(),createBlock(unref(bngButton_default),{key:4,disabled:!unref(canFinish),accent:unref(ACCENTS).primary,onClick:handleFinish},{default:withCtx(()=>[createTextVNode(toDisplayString(_ctx.$tt(_ctx.finishButtonText)),1)]),_:1},8,[`disabled`,`accent`])):createCommentVNode(``,!0)])]),default:withCtx(()=>[unref(currentStep)?.title?(openBlock(),createBlock(unref(bngCardHeading_default),{key:0,type:`ribbon`},{default:withCtx(()=>[renderSlot(_ctx.$slots,`step-title`,{step:unref(currentStep)},()=>[createTextVNode(toDisplayString(_ctx.$tt(unref(currentStep).title)),1)],!0)]),_:3})):createCommentVNode(``,!0),withDirectives((openBlock(),createElementBlock(`div`,_hoisted_3$195,[renderSlot(_ctx.$slots,`step`,{step:unref(currentStep),stepData:unref(currentStep)?.modelValue,updateStepData:unref(currentStep)?.updateModelValue,stepIndex:unref(currentStepIndex),isFirst:unref(isFirstStep),isLast:unref(isLastStep)},()=>[renderSlot(_ctx.$slots,`default`,{},void 0,!0)],!0),_ctx.validationMessage?(openBlock(),createElementBlock(`div`,_hoisted_4$167,[createBaseVNode(`div`,_hoisted_5$144,toDisplayString(_ctx.validationMessage),1)])):createCommentVNode(``,!0)])),[[unref(BngUiNavScroll_default)]])]),_:3})])]))}},Wizard_default=__plugin_vue_export_helper_default(_sfc_main$300,[[`__scopeId`,`data-v-69c7b9c4`]]),_sfc_main$299={__name:`WizardView`,props:mergeModels({...wizardProps},{modelValue:{},modelModifiers:{}}),emits:mergeModels([`step-change`,`step-complete`,`wizard-finish`,`validation-error`],[`update:modelValue`]),setup(__props,{expose:__expose}){let props=__props,slots=useSlots(),wizardRef=ref(),wizardModel=useModel(__props,`modelValue`);return __expose({wizard:wizardRef,get currentStepIndex(){return wizardRef.value?.currentStepIndex},get currentStep(){return wizardRef.value?.currentStep},get progress(){return wizardRef.value?.progress},get stepProgress(){return wizardRef.value?.stepProgress},get steps(){return wizardRef.value?.steps},nextStep:()=>wizardRef.value?.nextStep(),previousStep:()=>wizardRef.value?.previousStep(),finish:()=>wizardRef.value?.finish(),skip:()=>wizardRef.value?.skip()}),(_ctx,_cache)=>withDirectives((openBlock(),createBlock(unref(layoutSingle_default),{class:`layout-content-full content-center layout-paddings wizard-view`},{default:withCtx(()=>[createVNode(Wizard_default,mergeProps({ref_key:`wizardRef`,ref:wizardRef},props,{modelValue:wizardModel.value,"onUpdate:modelValue":_cache[0]||=$event=>wizardModel.value=$event,onStepChange:_cache[1]||=$event=>_ctx.$emit(`step-change`,$event),onStepComplete:_cache[2]||=$event=>_ctx.$emit(`step-complete`,$event),onWizardFinish:_cache[3]||=$event=>_ctx.$emit(`wizard-finish`,$event),onValidationError:_cache[4]||=$event=>_ctx.$emit(`validation-error`,$event)}),createSlots({_:2},[renderList(unref(slots),(slot,name)=>({name,fn:withCtx(props$1=>[renderSlot(_ctx.$slots,name,normalizeProps(guardReactiveProps(props$1)),void 0,!0)])}))]),1040,[`modelValue`])]),_:3})),[[unref(BngBlur_default)]])}},WizardView_default=__plugin_vue_export_helper_default(_sfc_main$299,[[`__scopeId`,`data-v-e47281c4`]]),_hoisted_1$267={key:0,class:`wizard-summary`},_sfc_main$298={__name:`WizardSummary`,props:{custom:{type:Array,default:()=>[],validator:items$2=>items$2.every(item=>item.label&&item.value!==void 0)},replace:{type:Boolean,default:!1}},setup(__props){let props=__props,steps=inject(`wizardSteps`,ref([])),summaryItems=computed(()=>{let customItems=props.custom.map(item=>({stepId:uniqueId(),title:item.label,selectedLabel:item.value,hasSelection:!item.disabled}));if(props.replace)return customItems;let stepsList=steps.value||[],automaticItems=[];return Array.isArray(stepsList)&&(automaticItems=stepsList.filter(step=>step.type===`choice`&&step.choices&&step.choices.length>0).map(step=>{let selectedChoice=step.modelValue?.choice,choiceOption=step.choices.find(choice=>choice.value===selectedChoice);return{stepId:step.id,title:step.title,selectedLabel:choiceOption?.label||null,hasSelection:!!selectedChoice}}).filter(item=>item.hasSelection)),[...automaticItems,...customItems]});return(_ctx,_cache)=>summaryItems.value.length>0?(openBlock(),createElementBlock(`div`,_hoisted_1$267,[(openBlock(!0),createElementBlock(Fragment,null,renderList(summaryItems.value,item=>(openBlock(),createElementBlock(`div`,{key:item.stepId,class:`summary-item`},[createBaseVNode(`strong`,null,toDisplayString(_ctx.$tt(item.title))+`:`,1),createBaseVNode(`span`,{class:normalizeClass({enabled:item.hasSelection,disabled:!item.hasSelection})},toDisplayString(_ctx.$tt(item.selectedLabel||`ui.common.unknown`)),3)]))),128))])):createCommentVNode(``,!0)}},WizardSummary_default=__plugin_vue_export_helper_default(_sfc_main$298,[[`__scopeId`,`data-v-69c45791`]]),_hoisted_1$266={key:0,class:`wizard-step-container`},_hoisted_2$220={key:0,class:`step-description`},_hoisted_3$194=[`innerHTML`],_hoisted_4$166={class:`step-content`},_hoisted_5$143={key:0,class:`wizard-choice-step`},_hoisted_6$123={key:1,class:`wizard-form-step`},_hoisted_7$110={key:2,class:`wizard-confirmation-step`},_hoisted_8$93={key:3,class:`wizard-custom-step`},_hoisted_9$83={class:`custom-placeholder`},_sfc_main$297={__name:`WizardStep`,props:mergeModels({id:{type:String,required:!0},title:String,description:String,type:{type:String,default:`custom`,validator:value=>[`choice`,`form`,`confirmation`,`custom`].includes(value)},autoSkip:{type:Boolean,default:!0},advanceDisabled:{type:Boolean,default:!1},advanceDelay:{type:Number,default:300},required:{type:Boolean,default:!0},validator:{type:Function,default:null},enabledWhen:{type:Array,default:()=>[]},choices:{type:Array,default:()=>[]},component:{type:[String,Object],default:null},componentProps:{type:Object,default:()=>({})}},{modelValue:{default:()=>({})},modelModifiers:{}}),emits:[`update:modelValue`],setup(__props,{expose:__expose}){let props=__props,modelValue=useModel(__props,`modelValue`),registerStep=inject(`registerWizardStep`,null),unregisterStep=inject(`unregisterWizardStep`,null),currentStep=inject(`currentWizardStep`,null),slots=useSlots(),stepContext={stepId:props.id,stepType:props.type};provide(`wizardStepContext`,stepContext),__expose({stepId:props.id,stepContext});let isCurrentStep=computed(()=>currentStep?.value?.id===props.id);return onMounted(()=>{registerStep?.({id:props.id,title:props.title,description:props.description,type:props.type,autoSkip:props.autoSkip,get advanceDisabled(){return props.advanceDisabled},advanceDelay:props.advanceDelay,required:props.required,enabledWhen:props.enabledWhen,validate:props.validator,component:props.component,componentProps:props.componentProps,choices:props.choices,get modelValue(){return modelValue.value},updateModelValue:value=>{modelValue.value=value},hasDefaultSlot:!!slots.default,hasDescriptionSlot:!!slots.description})}),onUnmounted(()=>{unregisterStep?.(props.id)}),(_ctx,_cache)=>isCurrentStep.value?(openBlock(),createElementBlock(`div`,_hoisted_1$266,[__props.description||_ctx.$slots.description?(openBlock(),createElementBlock(`div`,_hoisted_2$220,[renderSlot(_ctx.$slots,`description`,{},()=>[__props.description?(openBlock(),createElementBlock(`div`,{key:0,innerHTML:__props.description},null,8,_hoisted_3$194)):createCommentVNode(``,!0)],!0)])):createCommentVNode(``,!0),createBaseVNode(`div`,_hoisted_4$166,[__props.type===`choice`?(openBlock(),createElementBlock(`div`,_hoisted_5$143,[renderSlot(_ctx.$slots,`default`,{},void 0,!0)])):__props.type===`form`?(openBlock(),createElementBlock(`div`,_hoisted_6$123,[renderSlot(_ctx.$slots,`default`,{},()=>[_cache[0]||=createBaseVNode(`div`,{class:`form-placeholder`},[createBaseVNode(`p`,null,`Add your form content here using BngInput, BngDropdown, etc.`),createBaseVNode(`p`,{class:`form-note`},`Use v-model bindings to connect to step data.`)],-1)],!0)])):__props.type===`confirmation`?(openBlock(),createElementBlock(`div`,_hoisted_7$110,[renderSlot(_ctx.$slots,`default`,{},()=>[createVNode(WizardSummary_default)],!0)])):(openBlock(),createElementBlock(`div`,_hoisted_8$93,[renderSlot(_ctx.$slots,`default`,{},()=>[createBaseVNode(`div`,_hoisted_9$83,[createBaseVNode(`p`,null,`Custom step content for: `+toDisplayString(__props.title),1),_cache[1]||=createBaseVNode(`p`,{class:`custom-note`},`Add your custom content in the WizardStep default slot`,-1)])],!0)]))])])):createCommentVNode(``,!0)}},WizardStep_default=__plugin_vue_export_helper_default(_sfc_main$297,[[`__scopeId`,`data-v-ede4abc3`]]),_hoisted_1$265={class:`description`},_hoisted_2$219={class:`image-section`},_hoisted_3$193={class:`image-row`},_hoisted_4$165=[`src`],_hoisted_5$142=[`src`],_sfc_main$296={__name:`ButtonLayoutView`,setup(__props){let settings$1=useSettings(),handleFinish=async()=>{await settings$1.apply({showedInputLayoutPopupV37:!0}),window.bngVue.gotoGameState(`menu.mainmenu`)},goToControls=async()=>{await settings$1.apply({showedInputLayoutPopupV37:!0}),window.bngVue.gotoGameState(`menu.options.controls.bindings`)};return onMounted(async()=>{await settings$1.waitForData()}),(_ctx,_cache)=>(openBlock(),createBlock(unref(WizardView_default),{title:`Input Changes`,class:`wizard-view`,"show-progress":!1,"finish-button-text":`ui.common.continue`,onWizardFinish:handleFinish},{default:withCtx(()=>[createVNode(unref(WizardStep_default),{id:`buttonLayout`,title:`Extended Modifier Buttons`,type:`confirmation`},{default:withCtx(()=>[withDirectives((openBlock(),createElementBlock(`div`,_hoisted_1$265,[_cache[1]||=createBaseVNode(`p`,null,` We updated the default button layout for Xbox and Playstation controllers using modifier buttons. Below you see the new default layout. `,-1),_cache[2]||=createBaseVNode(`p`,null,[createBaseVNode(`strong`,{class:`warning-text`},`If you made any changes to the default layout on Xbox or Playstation, we suggest you review your current layout and then either edit it or reset to the default if needed.`)],-1),createVNode(unref(bngButton_default),{accent:unref(ACCENTS).primary,onClick:goToControls},{default:withCtx(()=>[..._cache[0]||=[createTextVNode(` Go to Controls `,-1)]]),_:1},8,[`accent`])])),[[unref(BngUiNavScroll_default)]]),createBaseVNode(`div`,_hoisted_2$219,[_cache[3]||=createBaseVNode(`h4`,null,`New Button Layout`,-1),createBaseVNode(`div`,_hoisted_3$193,[createBaseVNode(`img`,{src:unref(getAssetURL)(`images/buttonLayout1.jpg`),alt:`Button Layout`,class:`button-layout-image`},null,8,_hoisted_4$165),createBaseVNode(`img`,{src:unref(getAssetURL)(`images/buttonLayout2.jpg`),alt:`Button Layout`,class:`button-layout-image`},null,8,_hoisted_5$142)])])]),_:1})]),_:1}))}},ButtonLayoutView_default=__plugin_vue_export_helper_default(_sfc_main$296,[[`__scopeId`,`data-v-ff98d0e0`]]),routes_default$2=[{path:`/buttonLayout`,name:`buttonLayout`,component:ButtonLayoutView_default,meta:{infoBar:{visible:!0,showSysInfo:!0},uiApps:{shown:!1}}}],_hoisted_1$264={class:`left`},_hoisted_2$218={class:`branch-icon-assembly`},_hoisted_3$192=[`innerHTML`],_hoisted_4$164=[`innerHTML`],_sfc_main$295={__name:`BranchSkillProgressBar`,props:{skill:Object,mode:{type:String,default:`long`,validator:value=>[`long`,`short`,`simple`,`with-value-label`].includes(value)},showLevel:{type:Boolean,default:!1},showLockedIcon:{type:Boolean,default:!1},isMainProgress:{type:Boolean,default:!1}},setup(__props){let props=__props,headerLeft=computed(()=>props.skill.name),headerRightLevelOrStars=computed(()=>props.skill.isInDevelopment?``:props.skill.unlocked?(props.showLevel&&props.skill.unlocked,props.skill.showProgressAsStars?$translate.contextTranslate({txt:`ui.career.slashStars`,context:{cur:props.skill.value,max:props.skill.max}}):props.skill.levelLabel?props.skill.levelLabel:props.skill.level?$translate.contextTranslate({txt:`ui.career.lvlLabel`,context:{lvl:props.skill.level}}):`Level ${props.skill.level}`):$translate.contextTranslate(`ui.career.locked`)),value=computed(()=>props.skill.max===-1?1:props.skill.value-props.skill.min),max$1=computed(()=>props.skill.max===-1?1:props.skill.max-props.skill.min),valueLabelFormat=computed(()=>{if(props.skill.isInDevelopment)return $translate.contextTranslate(`ui.career.inDevelopment`);if(!props.skill.unlocked)return $translate.contextTranslate(`ui.career.locked`);if(props.mode===`simple`)return props.skill.showProgressAsStars?$translate.contextTranslate({txt:`ui.career.slashStars`,context:{cur:value.value,max:max$1.value}}):$translate.contextTranslate({txt:`ui.career.lvlLabel`,context:{lvl:props.skill.level}});let unit=props.skill.showProgressAsStars?`Stars`:`XP`;return props.skill.max===-1?$translate.contextTranslate({txt:`ui.career.just`+unit,context:{cur:value.value}}):$translate.contextTranslate({txt:`ui.career.slashXP`,context:{cur:value.value,max:max$1.value}})}),skillIcon=computed(()=>props.skill.isInDevelopment?icons.roadblockL:props.skill.unlocked?props.skill.icon||`info`:`lockClosed`),belowValueLabelFormat=computed(()=>{if(!props.skill.unlocked&&props.skill.lockedReason)return $translate.contextTranslate(props.skill.lockedReason?.label||`ui.career.locked`);if(props.skill.isInDevelopment)return $translate.contextTranslate(`ui.career.inDevelopment`);if(props.skill.isMaxLevel)return`​`;if(!props.skill.showProgressAsStars)return $translate.contextTranslate({txt:`ui.career.justXP`,context:{cur:props.skill.value}})}),branchBackgroundStyle=computed(()=>{let color=props.skill.accentColor;return color?color.startsWith(`--`)?{"background-color":`var(${color})`}:color.startsWith(`#`)?{"background-color":color}:{"background-color":`rgb(${color})`}:{"background-color":`#555555`}});return(_ctx,_cache)=>__props.mode===`simple`?(openBlock(),createElementBlock(`div`,{key:0,class:normalizeClass([`simple-progress`,{"is-locked":!props.skill.unlocked}])},[createBaseVNode(`div`,_hoisted_1$264,[createBaseVNode(`div`,_hoisted_2$218,[!__props.skill.isSkill&&!__props.skill.isBranch?(openBlock(),createElementBlock(`div`,{key:0,class:`branch-background`,style:normalizeStyle(branchBackgroundStyle.value)},null,4)):createCommentVNode(``,!0),createVNode(unref(bngIcon_default),{type:skillIcon.value,class:`assembly-icon`},null,8,[`type`])]),createTextVNode(` `+toDisplayString(_ctx.$ctx_t(headerLeft.value)),1)]),createBaseVNode(`div`,{class:`right`,innerHTML:valueLabelFormat.value},null,8,_hoisted_3$192)],2)):(openBlock(),createElementBlock(`div`,{key:1,class:normalizeClass([`flex-column`,{"is-locked":!props.skill.unlocked}])},[createVNode(unref(bngProgressBar_default),{class:normalizeClass([`stat-progress-bar`,{short:__props.mode===`short`,isMainProgress:__props.isMainProgress}]),headerLeft:_ctx.$ctx_t(headerLeft.value),headerRight:_ctx.$ctx_t(headerRightLevelOrStars.value),value:value.value,max:max$1.value+.001,showValueLabel:!0,valueLabelFormat:``,valueColor:`#eeeeee`},null,8,[`class`,`headerLeft`,`headerRight`,`value`,`max`]),!props.skill.unlocked&&__props.mode===`with-value-label`&&props.showLockedIcon?(openBlock(),createElementBlock(Fragment,{key:0},[],64)):createCommentVNode(``,!0),__props.mode===`with-value-label`?(openBlock(),createElementBlock(`div`,{key:1,class:`below-progress-bar`,innerHTML:belowValueLabelFormat.value},null,8,_hoisted_4$164)):createCommentVNode(``,!0)],2))}},BranchSkillProgressBar_default=__plugin_vue_export_helper_default(_sfc_main$295,[[`__scopeId`,`data-v-2f641a65`]]);function hexToRgb(hex){hex=hex.replace(/^#/,``);let bigint=parseInt(hex,16);return`${bigint>>16&255}, ${bigint>>8&255}, ${bigint&255}`}function getBranchColorStyle({color,accentColor}){let style={};color&&(color.startsWith(`#`)?style[`--branch-color`]=hexToRgb(color):color.startsWith(`var(--`)&&(style[`--branch-color`]=color));let accent=accentColor||color;return accent&&(accent.startsWith(`#`)?style[`--branch-accent-color`]=hexToRgb(accent):accent.startsWith(`var(--`)&&(style[`--branch-accent-color`]=accent)),style}function getIconBackgroundStyle(color){return color?color.startsWith(`--`)?{"background-color":`var(${color})`}:color.startsWith(`#`)?{"background-color":color}:{"background-color":`rgb(${color})`}:{"background-color":`#555555`}}var _hoisted_1$263={class:`branch-details`},_hoisted_2$217={class:`backdrop`},_hoisted_3$191={class:`skill-levels-wrapper`},_hoisted_4$163={key:0,class:`branch-name-container`},_hoisted_5$141={key:2,class:`branch-footer`},_hoisted_6$122={key:0,class:`branch-description`},_hoisted_7$109={key:0,class:`branch-description`},_hoisted_8$92={class:`branch-footer-content`},_hoisted_9$82={class:`certification-text`},_hoisted_10$72={class:`status`},_hoisted_11$65={class:`unlock-info-row`},_hoisted_12$53={class:`icon-box`},_hoisted_13$46={class:`certification-text`},_sfc_main$294={__name:`BranchSkillCard`,props:{branchKey:String,displayMode:{type:String,default:`card`}},emits:[`openBranchPage`],setup(__props,{emit:__emit}){let props=__props,emit$1=__emit,branchData=ref();computed(()=>branchData.value&&`url(${getAssetURL(branchData.value.icon)})`);let branchColor=computed(()=>{let color=branchData.value&&branchData.value.color;return color?color.startsWith(`#`)?hexToRgb(color):color.startsWith(`var(--`)?`${color}`:`transparent`:``}),branchAccentColor=computed(()=>{let color=branchData.value&&(branchData.value.accentColor||branchData.value.color);return color?color.startsWith(`#`)?hexToRgb(color):color.startsWith(`var(--`)?`${color}`:`transparent`:``}),branchIconType=computed(()=>branchData.value&&branchData.value.isInDevelopment?icons.roadblockL:branchData.value&&branchData.value.unlocked?icons[branchData.value.glyphIcon]:icons.lockClosed),isHalf=computed(()=>{if(!branchData.value)return!1;let hasSkills=branchData.value.skills&&branchData.value.skills.length>0,hasDescription=branchData.value.shortDescription;return!hasSkills&&!hasDescription}),safeArray=arr=>Array.isArray(arr)?arr:[],openBranchPage=branchKey=>emit$1(`openBranchPage`,branchKey);function setup$3(data){branchData.value=data,branchData.value.skills=safeArray(data.skills)}let formatColor=color=>color?color.startsWith(`#`)?hexToRgb(color):color.startsWith(`var(--`)?`${color}`:`rgb(255, 255, 255)`:``;return onMounted(async()=>{setup$3(await Lua_default.career_modules_branches_landing.getBranchSkillCardData(props.branchKey))}),(_ctx,_cache)=>branchData.value?(openBlock(),createBlock(unref(bngCard_default),{key:0,class:normalizeClass([`branch-skill-card`,{"row-mode":__props.displayMode===`row`,locked:!branchData.value.unlocked,half:isHalf.value}]),onClick:_cache[0]||=$event=>openBranchPage(__props.branchKey),style:normalizeStyle({"--branch-color":branchColor.value,"--branch-accent-color":branchAccentColor.value})},{default:withCtx(()=>[createBaseVNode(`div`,_hoisted_1$263,[_cache[2]||=createBaseVNode(`div`,{class:`indicator left`},null,-1),_cache[3]||=createBaseVNode(`div`,{class:`indicator right`},null,-1),branchData.value.isDomain?createCommentVNode(``,!0):(openBlock(),createElementBlock(`div`,{key:0,class:normalizeClass([`branch-progress`,{"in-development":branchData.value.isInDevelopment}])},[branchData.value.isDomain?createCommentVNode(``,!0):(openBlock(),createElementBlock(`div`,{key:0,class:normalizeClass([`badge`,{"row-badge":__props.displayMode===`row`}])},[createBaseVNode(`div`,_hoisted_2$217,toDisplayString(branchData.value.value.color),1),createVNode(unref(bngIcon_default),{class:`icon-branch`,type:branchIconType.value},null,8,[`type`])],2))],2)),branchData.value.isDomain?(openBlock(),createBlock(unref(aspectRatio_default),{key:1,"external-image":branchData.value.cover,ratio:`16:9`,class:`image-container aspect-ratio`},null,8,[`external-image`])):createCommentVNode(``,!0),createBaseVNode(`div`,_hoisted_3$191,[__props.displayMode===`row`?(openBlock(),createElementBlock(`div`,_hoisted_4$163,[branchData.value?(openBlock(),createBlock(BranchSkillProgressBar_default,{key:0,class:`main-stat-progress-bar`,skill:branchData.value,showLevel:!0,mode:(branchData.value.isInDevelopment&&isHalf.value,``)},null,8,[`skill`,`mode`])):createCommentVNode(``,!0)])):createCommentVNode(``,!0)]),isHalf.value?createCommentVNode(``,!0):(openBlock(),createElementBlock(`div`,_hoisted_5$141,[branchData.value.isInDevelopment?(openBlock(),createElementBlock(`div`,_hoisted_6$122,toDisplayString(_ctx.$ctx_t(`ui.career.inDevelopment`)),1)):(openBlock(),createElementBlock(Fragment,{key:1},[branchData.value.shortDescription?(openBlock(),createElementBlock(`div`,_hoisted_7$109,toDisplayString(_ctx.$ctx_t(branchData.value.shortDescription)),1)):createCommentVNode(``,!0),createBaseVNode(`div`,_hoisted_8$92,[branchData.value.skills?(openBlock(!0),createElementBlock(Fragment,{key:0},renderList(branchData.value.skills,skill=>(openBlock(),createElementBlock(`div`,null,[branchData.value?(openBlock(),createBlock(BranchSkillProgressBar_default,{key:0,skill,mode:`simple`},null,8,[`skill`])):createCommentVNode(``,!0)]))),256)):createCommentVNode(``,!0),(openBlock(!0),createElementBlock(Fragment,null,renderList(branchData.value.certifications,certification=>(openBlock(),createElementBlock(`div`,{class:normalizeClass([`certification-container`,certification.status])},[createVNode(unref(bngIcon_default),{type:unref(icons).badgeRoundStar,style:normalizeStyle({color:certification.status===`completed`?`white`:certification.status===`available`?`rgba(255, 255, 255, 0.6)`:`rgba(255, 255, 255, 0.5)`})},null,8,[`type`,`style`]),createBaseVNode(`div`,_hoisted_9$82,[createTextVNode(toDisplayString(_ctx.$ctx_t(`ui.career.certification.name`))+` `,1),createBaseVNode(`span`,_hoisted_10$72,toDisplayString(_ctx.$ctx_t(certification.statusLabel)),1)])],2))),256)),branchData.value.unlockInfos?(openBlock(),createElementBlock(Fragment,{key:1},[_cache[1]||=createBaseVNode(`div`,{class:`unlock-info-title`},`Required Certifications:`,-1),createBaseVNode(`div`,_hoisted_11$65,[(openBlock(!0),createElementBlock(Fragment,null,renderList(branchData.value.unlockInfos,unlockInfo=>(openBlock(),createElementBlock(`div`,{class:normalizeClass([`unlock-info-item`,unlockInfo.status]),style:normalizeStyle({"--unlock-color":formatColor(unlockInfo.color?unlockInfo.color:`var(--bng-cool-gray-500-rgb)`)})},[createBaseVNode(`div`,_hoisted_12$53,[createVNode(unref(bngIcon_default),{type:unref(icons).badgeRoundStar,class:`certification-icon`},null,8,[`type`])]),createBaseVNode(`div`,_hoisted_13$46,toDisplayString(_ctx.$ctx_t(unlockInfo.label)),1)],6))),256))])],64)):createCommentVNode(``,!0)])],64))]))])]),_:1},8,[`class`,`style`])):createCommentVNode(``,!0)}},BranchSkillCard_default=__plugin_vue_export_helper_default(_sfc_main$294,[[`__scopeId`,`data-v-4321db2f`]]),_hoisted_1$262={class:`condensed`},_hoisted_2$216={key:3,class:`dev-icon-container`},_hoisted_3$190={class:`main-info`},_hoisted_4$162={key:1,class:`stars`},_sfc_main$293={__name:`MissionCard`,props:{mission:Object,isSkeleton:Boolean,showStartableIcons:Boolean},emits:[`clicked`],setup(__props,{emit:__emit}){let props=__props,emit$1=__emit,clicked=()=>emit$1(`clicked`,props.mission),backgroundImageStyle=computed(()=>({backgroundImage:`url(${props.mission.thumbnail})`,maskImage:`linear-gradient(to left, rgba(0, 0, 0, ${props.mission.startable?.75:.2}) 50%, rgba(0, 0, 0, 0.1) 100%)`,filter:props.mission.startable?`none`:`grayscale(100%)`})),iconType$1=computed(()=>props.isSkeleton?icons.medal:icons[props.mission.icon]||icons.medal),iconColor=computed(()=>props.isSkeleton||!props.mission.startable?`var(--bng-cool-gray-600)`:`#fff`),showStartableIcons=computed(()=>!props.isSkeleton&&props.showStartableIcons);return(_ctx,_cache)=>(openBlock(),createBlock(unref(bngCard_default),{"bng-nav-item":``,onClick:clicked,class:normalizeClass({"card-wrapper":!0,"click-startable":__props.mission&&__props.mission.startable})},{default:withCtx(()=>[createBaseVNode(`div`,_hoisted_1$262,[__props.isSkeleton?createCommentVNode(``,!0):(openBlock(),createBlock(unref(aspectRatio_default),{key:0,class:`image`,style:normalizeStyle(backgroundImageStyle.value)},null,8,[`style`])),!__props.isSkeleton&&!__props.mission.startable?(openBlock(),createBlock(unref(bngIcon_default),{key:1,class:`locked-icon`,type:unref(icons).lockClosed,color:iconColor.value},null,8,[`type`,`color`])):createCommentVNode(``,!0),!__props.isSkeleton&&showStartableIcons.value?(openBlock(),createElementBlock(Fragment,{key:2},[__props.mission.canStartFromProgressScreen&&__props.mission.startable?(openBlock(),createBlock(unref(bngIcon_default),{key:0,class:`locked-icon`,type:unref(icons).play,color:iconColor.value},null,8,[`type`,`color`])):createCommentVNode(``,!0),!__props.mission.canStartFromProgressScreen&&__props.mission.startable?(openBlock(),createBlock(unref(bngIcon_default),{key:1,class:`locked-icon`,type:unref(icons).mapPoint,color:iconColor.value},null,8,[`type`,`color`])):createCommentVNode(``,!0)],64)):createCommentVNode(``,!0),!__props.isSkeleton&&__props.mission.devMission?(openBlock(),createElementBlock(`div`,_hoisted_2$216,[createVNode(unref(bngIcon_default),{class:`dev-icon`,type:unref(icons).bug,color:`white`},null,8,[`type`]),_cache[0]||=createBaseVNode(`div`,{class:`dev-text`},` DEV MISSION `,-1)])):createCommentVNode(``,!0),_cache[1]||=createBaseVNode(`div`,{class:`highlight-marker`},null,-1),createVNode(unref(bngIcon_default),{class:`mission-icon`,type:iconType$1.value,color:iconColor.value},null,8,[`type`,`color`]),createVNode(unref(bngBinding_default),{class:`input-icon`,"ui-event":`ok`,controller:``}),createBaseVNode(`div`,_hoisted_3$190,[__props.isSkeleton?createCommentVNode(``,!0):(openBlock(),createElementBlock(`div`,{key:0,class:normalizeClass([`heading`,{locked:!__props.mission.startable}])},toDisplayString(_ctx.$tt(__props.mission.label)),3)),!__props.isSkeleton&&__props.mission.startable&&__props.mission.formattedProgress?(openBlock(),createElementBlock(`div`,_hoisted_4$162,[__props.mission.formattedProgress.unlockedStars&&__props.mission.formattedProgress.unlockedStars.totalDefaultStarCount?(openBlock(),createBlock(unref(bngMainStars_default),{key:0,individualStars:__props.mission.formattedProgress.unlockedStars.defaults,class:`main-stars`,scale:.6},null,8,[`individualStars`])):createCommentVNode(``,!0),__props.mission.formattedProgress.unlockedStars&&__props.mission.formattedProgress.unlockedStars.totalBonusStarCount>0?(openBlock(),createBlock(unref(bngMainStars_default),{key:1,individualStars:__props.mission.formattedProgress.unlockedStars.bonus,class:`bonus-stars`,scale:.6},null,8,[`individualStars`])):createCommentVNode(``,!0)])):createCommentVNode(``,!0)])])]),_:1},8,[`class`]))}},MissionCard_default=__plugin_vue_export_helper_default(_sfc_main$293,[[`__scopeId`,`data-v-52ea67db`]]),_hoisted_1$261={class:`rewards-pills-container`},_sfc_main$292={__name:`RewardPill`,props:{icon:String,attributeKey:String,rewardAmount:Number,highlight:Boolean,hideNumbers:Boolean,backgroundColor:{type:String,default:`rgba(var(--bng-cool-gray-900-rgb), 0.5)`}},setup(__props){return(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$261,[createBaseVNode(`div`,{class:`pill`,style:normalizeStyle({backgroundColor:__props.backgroundColor,filter:__props.highlight?`brightness(350%)`:``})},[createVNode(unref(bngUnit_default),mergeProps({[__props.icon?`beamXP`:__props.attributeKey]:__props.rewardAmount},{options:__props.hideNumbers?{formatter:x=>null}:null,iconType:__props.icon?unref(icons)[__props.icon]:null,formatter:__props.attributeKey}),null,16,[`options`,`iconType`,`formatter`])],4)]))}},RewardPill_default=__plugin_vue_export_helper_default(_sfc_main$292,[[`__scopeId`,`data-v-7719e2fc`]]),_hoisted_1$260={class:`rewards-pills-container`},_sfc_main$291={__name:`RewardsPills`,props:{rewards:Object,hideNumbers:Boolean,negativeBackground:{type:Boolean,default:!0}},setup(__props){return(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$260,[(openBlock(!0),createElementBlock(Fragment,null,renderList(__props.rewards,reward=>(openBlock(),createBlock(RewardPill_default,{icon:reward.icon,hideNumbers:__props.hideNumbers,attributeKey:reward.attributeKey,rewardAmount:reward.rewardAmount,highlight:reward.highlight,backgroundColor:__props.negativeBackground&&reward.rewardAmount<0?`rgba(var(--bng-add-red-700-rgb), 0.5)`:void 0},null,8,[`icon`,`hideNumbers`,`attributeKey`,`rewardAmount`,`highlight`,`backgroundColor`]))),256))]))}},RewardsPills_default=__plugin_vue_export_helper_default(_sfc_main$291,[[`__scopeId`,`data-v-40e5103d`]]),_hoisted_1$259={key:0,class:`animated-border claimable`},_hoisted_2$215={key:1,class:`complete`},_hoisted_3$189={key:0,class:`complete`},_hoisted_4$161={key:1,class:`complete-badge`},_hoisted_5$140={key:2,class:`step`},_hoisted_6$121={key:3,class:`step`},_hoisted_7$108={class:`content`},_hoisted_8$91={class:`heading`},_hoisted_9$81={key:0,class:`middle-content`},_hoisted_10$71={key:1,class:`middle-content`},_hoisted_11$64={key:3,class:`progress`},_sfc_main$290={__name:`MilestoneCard`,props:{milestone:Object,isCondensed:Boolean},emits:[`claim`],setup(__props,{emit:__emit}){let props=__props,emit$1=__emit,claimMilestone=()=>{console.log(`claimMilestone`,props.milestone),props.milestone.claimable&&(emit$1(`claim`,props.milestone),console.log(props.milestone))},milestoneColor=computed(()=>{let color=props.milestone.color;return color?color.startsWith(`#`)?hexToRgb$1(color):color.startsWith(`var(--`)?`${color}`:`transparent`:``});function hexToRgb$1(hex){return`${parseInt(hex.slice(1,3),16)}, ${parseInt(hex.slice(3,5),16)}, ${parseInt(hex.slice(5,7),16)}`}return(_ctx,_cache)=>withDirectives((openBlock(),createElementBlock(`div`,{"bng-nav-item":``,onClick:claimMilestone,class:`condensed`},[__props.milestone.claimable?(openBlock(),createElementBlock(`div`,_hoisted_1$259)):createCommentVNode(``,!0),__props.milestone.completed?(openBlock(),createElementBlock(`div`,_hoisted_2$215)):createCommentVNode(``,!0),createVNode(unref(aspectRatio_default),{class:`image`,style:normalizeStyle({backgroundColor:`rgb(`+milestoneColor.value+`)`}),ratio:`21:9`},{default:withCtx(()=>[__props.milestone.completed?(openBlock(),createElementBlock(`div`,_hoisted_3$189)):createCommentVNode(``,!0),__props.milestone.completed?(openBlock(),createElementBlock(`div`,_hoisted_4$161,[createVNode(unref(bngIcon_default),{class:`glyph small`,type:unref(icons).checkmark},null,8,[`type`])])):createCommentVNode(``,!0),createVNode(unref(bngIcon_default),{class:`glyph`,type:unref(icons)[__props.milestone.icon]},null,8,[`type`]),__props.milestone.step!==void 0&&__props.milestone.maxStep!==void 0?(openBlock(),createElementBlock(`div`,_hoisted_5$140,toDisplayString(__props.milestone.step)+`/`+toDisplayString(__props.milestone.maxStep),1)):createCommentVNode(``,!0),__props.milestone.step!==void 0&&__props.milestone.maxStep===void 0?(openBlock(),createElementBlock(`div`,_hoisted_6$121,toDisplayString(__props.milestone.step),1)):createCommentVNode(``,!0)]),_:1},8,[`style`]),createBaseVNode(`div`,_hoisted_7$108,[createBaseVNode(`div`,_hoisted_8$91,toDisplayString(_ctx.$ctx_t(__props.milestone.label)),1),__props.milestone.description?(openBlock(),createElementBlock(`div`,_hoisted_9$81,toDisplayString(_ctx.$ctx_t(__props.milestone.description)),1)):createCommentVNode(``,!0),__props.milestone.rewards?(openBlock(),createElementBlock(`div`,_hoisted_10$71,[createVNode(RewardsPills_default,{rewards:__props.milestone.rewards},null,8,[`rewards`])])):createCommentVNode(``,!0),__props.milestone.completed?(openBlock(),createBlock(unref(bngProgressBar_default),{key:2,value:1,max:1,min:0,valueLabelFormat:`Complete!`,class:`progress`})):createCommentVNode(``,!0),__props.milestone.progress?(openBlock(),createElementBlock(`div`,_hoisted_11$64,[(openBlock(!0),createElementBlock(Fragment,null,renderList(__props.milestone.progress,prog=>(openBlock(),createBlock(unref(bngProgressBar_default),{class:normalizeClass({claimProgressBar:__props.milestone.claimable}),value:prog.currValue,max:prog.maxValue,min:prog.minValue,valueLabelFormat:__props.milestone.claimable?`Click to claim!`:_ctx.$ctx_t(prog.label)},null,8,[`class`,`value`,`max`,`min`,`valueLabelFormat`]))),256))])):createCommentVNode(``,!0)])])),[[unref(BngOnUiNav_default),void 0,`ok`,{focusRequired:!0,asMouse:!0}]])}},MilestoneCard_default=__plugin_vue_export_helper_default(_sfc_main$290,[[`__scopeId`,`data-v-8fc3424a`]]),_hoisted_1$258={class:`progress-track`},_hoisted_2$214={key:0,class:`progress-fill`,style:{height:`100%`}},_hoisted_3$188={class:`header`},_hoisted_4$160={class:`name`},_hoisted_5$139={key:0,class:`stars`},_hoisted_6$120={key:1,class:`stars`},_hoisted_7$107={class:`info`},_hoisted_8$90={class:`unlock-condition`},_hoisted_9$80={class:`info`},_hoisted_10$70={class:`label`},_hoisted_11$63={class:`description`},_hoisted_12$52={key:0,class:`cards-container`},_hoisted_13$45={class:`basic-card locked coming-soon`},_hoisted_14$42={class:`label`},_hoisted_15$40={key:1,class:`right`},_sfc_main$289={__name:`LeagueRow`,props:{league:Object,leagueMissionClicked:Function,condensed:Boolean,vertical:Boolean,nowUnlocked:Boolean},setup(__props){let props=__props;function hexToRgb$1(hex){hex=hex.replace(/^#/,``);let bigint=parseInt(hex,16);return`${bigint>>16&255}, ${bigint>>8&255}, ${bigint&255}`}let leagueStyle=computed(()=>{if(!props.league.accentColor)return{};let style={};return props.league.accentColor.startsWith(`#`)?style[`--league-accent-color`]=hexToRgb$1(props.league.accentColor):props.league.accentColor.startsWith(`var(--`)&&(style[`--league-accent-color`]=props.league.accentColor),style});return(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,{class:normalizeClass([`league-row`,{locked:!__props.league._unlocked,condensed:__props.condensed}]),style:normalizeStyle(leagueStyle.value)},[createBaseVNode(`div`,_hoisted_1$258,[__props.league._unlocked?(openBlock(),createElementBlock(`div`,_hoisted_2$214)):createCommentVNode(``,!0)]),createBaseVNode(`div`,_hoisted_3$188,[createBaseVNode(`div`,_hoisted_4$160,[createVNode(unref(bngIcon_default),{type:unref(icons)[__props.league.icon],class:`skill-icon`,color:__props.league._unlocked?`white`:`gray`},null,8,[`type`,`color`]),createTextVNode(` `+toDisplayString(_ctx.$ctx_t(__props.league.name)),1)]),__props.nowUnlocked?(openBlock(),createElementBlock(`div`,_hoisted_6$120,[createVNode(unref(bngIcon_default),{type:unref(icons).lockOpened},null,8,[`type`])])):(openBlock(),createElementBlock(`div`,_hoisted_5$139,[__props.league._unlocked?(openBlock(),createBlock(unref(bngMainStars_default),{key:0,"unlocked-stars":__props.league.totalStarsObtained,"total-stars":__props.league.totalStarsAvailable,class:`main-stars`,scale:.8,reverse:``,numerical:``},null,8,[`unlocked-stars`,`total-stars`])):createCommentVNode(``,!0)]))]),createBaseVNode(`div`,{class:normalizeClass([`content-row`,{vertical:__props.vertical}])},[createBaseVNode(`div`,_hoisted_7$107,[(openBlock(!0),createElementBlock(Fragment,null,renderList(__props.league.unlock,cond=>(openBlock(),createElementBlock(Fragment,null,[cond.hidden?createCommentVNode(``,!0):(openBlock(),createBlock(unref(bngCard_default),{key:0},{default:withCtx(()=>[createBaseVNode(`div`,_hoisted_8$90,[createBaseVNode(`div`,_hoisted_9$80,[createVNode(unref(bngIcon_default),{class:`icon`,type:cond.met?unref(icons).lockOpened:unref(icons).lockClosed,color:cond.met?`white`:`gray`},null,8,[`type`,`color`]),createBaseVNode(`div`,_hoisted_10$70,toDisplayString(cond.label),1)]),cond.progress?(openBlock(),createBlock(unref(bngProgressBar_default),{key:0,value:cond.progress.cur,min:cond.progress.min,max:cond.progress.max,valueLabelFormat:``,class:`progress`},null,8,[`value`,`min`,`max`])):createCommentVNode(``,!0)])]),_:2},1024))],64))),256)),createBaseVNode(`div`,_hoisted_11$63,toDisplayString(_ctx.$ctx_t(__props.league.description)),1)]),__props.condensed?(openBlock(),createElementBlock(`div`,_hoisted_15$40,toDisplayString(__props.league.missions.length)+` Challenges `,1)):(openBlock(),createElementBlock(`div`,_hoisted_12$52,[(openBlock(!0),createElementBlock(Fragment,null,renderList(__props.league.missions,mission=>(openBlock(),createBlock(MissionCard_default,{class:`clickable-card`,key:mission.id,mission,onClicked:__props.leagueMissionClicked,showStartableIcons:!0},null,8,[`mission`,`onClicked`]))),128)),(openBlock(!0),createElementBlock(Fragment,null,renderList(__props.league.driftSpots,driftSpot=>(openBlock(),createBlock(MissionCard_default,{class:`clickable-card`,key:driftSpot.id,mission:driftSpot,onClicked:__props.leagueMissionClicked},null,8,[`mission`,`onClicked`]))),128)),__props.league.comingSoon?(openBlock(!0),createElementBlock(Fragment,{key:0},renderList(__props.league.comingSoon,info=>(openBlock(),createBlock(unref(bngCard_default),{class:`card-height`},{default:withCtx(()=>[createBaseVNode(`div`,_hoisted_13$45,[createVNode(unref(bngIcon_default),{class:`icon`,type:unref(icons)[info.icon],color:`gray`},null,8,[`type`]),createBaseVNode(`div`,_hoisted_14$42,toDisplayString(info.label),1)])]),_:2},1024))),256)):createCommentVNode(``,!0)]))],2)],6))}},LeagueRow_default=__plugin_vue_export_helper_default(_sfc_main$289,[[`__scopeId`,`data-v-f92a650f`]]),_hoisted_1$257={class:`label`},_hoisted_2$213={class:`text`},_hoisted_3$187={class:`description`},_sfc_main$288={__name:`TaskGoal`,props:{label:[String,Object],description:[String,Object],complete:Boolean,success:Boolean,settings:{type:Object,default:{animate:!1,animateOnMount:!1,successCallback:Function}}},setup(__props){let props=__props,slots=useSlots(),animationSettings=inject(`animationSettings`,props.settings),animate=ref(!1),labelParsed=computed(()=>parse$1($translate.contextTranslate(props.label,!0))),descriptionParsed=computed(()=>parse$1($translate.contextTranslate(props.description,!0))),checkboxSvgs=computed(()=>({"--checkbox-empty":`url(${getAssetURL(`icons/general/checkbox-empty.svg`)})`,"--checkbox-ok":`url(${getAssetURL(`icons/general/checkbox-ok.svg`)})`,"--checkbox-nope":`url(${getAssetURL(`icons/general/checkbox-nope.svg`)})`}));return watch(()=>[props.complete,props.success],(newValues,oldValues)=>{let isComplete=newValues[0],isSuccess=newValues[1];animate.value=animationSettings.animate&&isComplete,isSuccess&&animationSettings.successCallback()}),onBeforeMount(()=>{animate.value=props.settings.animate&&props.settings.animateOnMount}),(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,{class:normalizeClass([`task-goal`,{success:__props.complete&&__props.success,fail:__props.complete&&!__props.success,animate:animate.value}])},[createBaseVNode(`div`,_hoisted_1$257,[createBaseVNode(`span`,{class:`checkbox`,style:normalizeStyle(checkboxSvgs.value)},null,4),createBaseVNode(`span`,_hoisted_2$213,[unref(slots).label?renderSlot(_ctx.$slots,`label`,{key:0},void 0,!0):__props.label?(openBlock(),createBlock(unref(dynamicComponent_default),{key:1,template:labelParsed.value},null,8,[`template`])):createCommentVNode(``,!0)])]),createBaseVNode(`span`,_hoisted_3$187,[unref(slots).description?renderSlot(_ctx.$slots,`description`,{key:0},void 0,!0):__props.description?(openBlock(),createBlock(unref(dynamicComponent_default),{key:1,template:descriptionParsed.value},null,8,[`template`])):createCommentVNode(``,!0)])],2))}},TaskGoal_default=__plugin_vue_export_helper_default(_sfc_main$288,[[`__scopeId`,`data-v-5a381682`]]),_hoisted_1$256={key:0,class:`wrapper`},_hoisted_2$212={class:`heading`},_hoisted_3$186={class:`description`},_hoisted_4$159={key:1,class:`tasklist wrapper`},_hoisted_5$138={class:`task-content`},_hoisted_6$119={class:`heading`},_hoisted_7$106={class:`description`},_sfc_main$287={__name:`UnlockCard`,props:{data:Object},setup(__props){return(_ctx,_cache)=>(openBlock(),createElementBlock(Fragment,null,[__props.data.type==`tasklist`?createCommentVNode(``,!0):(openBlock(),createElementBlock(`div`,_hoisted_1$256,[createVNode(unref(bngIcon_default),{class:`icon`,type:unref(icons)[__props.data.icon]},null,8,[`type`]),createBaseVNode(`div`,_hoisted_2$212,toDisplayString(__props.data.heading),1),createBaseVNode(`div`,_hoisted_3$186,toDisplayString(__props.data.description),1)])),__props.data.type==`tasklist`?(openBlock(),createElementBlock(`div`,_hoisted_4$159,[(openBlock(!0),createElementBlock(Fragment,null,renderList(__props.data.tasklistData.tasks,task=>(openBlock(),createElementBlock(`div`,{class:`task`,key:task.label},[createVNode(unref(bngIcon_default),{class:`icon`,type:unref(icons)[task.done?`checkboxOn`:`checkboxOff`]},null,8,[`type`]),createBaseVNode(`div`,_hoisted_5$138,[createBaseVNode(`div`,_hoisted_6$119,toDisplayString(task.label),1),createBaseVNode(`div`,_hoisted_7$106,toDisplayString(task.description),1)])]))),128))])):createCommentVNode(``,!0)],64))}},UnlockCard_default=__plugin_vue_export_helper_default(_sfc_main$287,[[`__scopeId`,`data-v-c5fa6ca1`]]),_hoisted_1$255={class:`unlock-rows`},_hoisted_2$211={class:`rows-container`},_hoisted_3$185={class:`progress-track`},_hoisted_4$158={key:0,class:`progress-fill`,style:{height:`100%`}},_hoisted_5$137={class:`header`},_hoisted_6$118={class:`level-name-and-heading`},_hoisted_7$105={class:`level-label`},_hoisted_8$89={key:0,class:`description-heading`},_hoisted_9$79={class:`content-row`},_hoisted_10$69={class:`description-column`},_hoisted_11$62={class:`unlock-condition`},_hoisted_12$51={class:`info`},_hoisted_13$44={class:`label`},_hoisted_14$41={key:1,class:`description-text`},_hoisted_15$39={class:`unlocks-column`},_hoisted_16$38={key:0,class:`unlocks-list`},_sfc_main$286={__name:`UnlockRows`,props:{value:{type:Number,default:0},min:{type:Number,default:0},max:{type:Number,required:!0},maxRequiredValue:{type:Number,required:!1},tiers:Array,currentTier:Number,unlocked:Boolean,progressFillColor:{type:String,default:`#ff6600`}},setup(__props){useCssVars(_ctx=>({v1b3c87f1:props.progressFillColor.startsWith(`var(--`)&&props.progressFillColor.endsWith(`-rgb)`)?`rgb(${props.progressFillColor})`:props.progressFillColor}));let props=__props;function hexToRgb$1(hex){hex=hex.replace(/^#/,``);let bigint=parseInt(hex,16);return`${bigint>>16&255}, ${bigint>>8&255}, ${bigint&255}`}let progressStyle=computed(()=>{if(!props.progressFillColor)return{};let style={};return props.progressFillColor.startsWith(`#`)?style[`--progress-fill-color`]=hexToRgb$1(props.progressFillColor):props.progressFillColor.startsWith(`var(--`)&&(style[`--progress-fill-color`]=props.progressFillColor),style});return(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$255,[createBaseVNode(`div`,_hoisted_2$211,[(openBlock(!0),createElementBlock(Fragment,null,renderList(__props.tiers,(tier,idx)=>(openBlock(),createElementBlock(`div`,{key:tier.index,class:normalizeClass({"tier-row":!0,"grayed-out":__props.currentTier<=tier.index-1,completed:__props.currentTier+1>tier.index,"in-development":tier.isInDevelopment,"first-tier":idx===0,"last-tier":idx===__props.tiers.length-1})},[createBaseVNode(`div`,_hoisted_3$185,[__props.currentTier+1>tier.index?(openBlock(),createElementBlock(`div`,_hoisted_4$158)):createCommentVNode(``,!0)]),createBaseVNode(`div`,_hoisted_5$137,[createBaseVNode(`div`,_hoisted_6$118,[createBaseVNode(`span`,_hoisted_7$105,`Level `+toDisplayString(tier.label?tier.label:tier.index),1),tier.description&&tier.description.heading?(openBlock(),createElementBlock(`span`,_hoisted_8$89,`: `+toDisplayString(tier.description.heading),1)):createCommentVNode(``,!0)])]),createBaseVNode(`div`,_hoisted_9$79,[createBaseVNode(`div`,_hoisted_10$69,[tier.isInDevelopment||__props.currentTier+1<=tier.index||!__props.unlocked?(openBlock(),createBlock(unref(bngCard_default),{key:0,class:`unlock-condition-card`,style:normalizeStyle(progressStyle.value)},{default:withCtx(()=>[createBaseVNode(`div`,_hoisted_11$62,[createBaseVNode(`div`,_hoisted_12$51,[createVNode(unref(bngIcon_default),{class:`icon`,type:tier.isInDevelopment?unref(icons).roadblockL:unref(icons).lockClosed,color:`gray`},null,8,[`type`]),createBaseVNode(`div`,_hoisted_13$44,[tier.isInDevelopment?(openBlock(),createElementBlock(Fragment,{key:0},[createTextVNode(` Coming Soon! `)],64)):(openBlock(),createElementBlock(Fragment,{key:1},[createTextVNode(toDisplayString(tier.xpCurrent)+` / `+toDisplayString(tier.xpRequired)+` XP `,1)],64))])]),!tier.isInDevelopment&&tier.currentValue&&tier.requiredValue?(openBlock(),createBlock(unref(bngProgressBar_default),{key:0,value:tier.xpCurrent,min:0,max:tier.xpRequired,valueLabelFormat:``,class:`progress`},null,8,[`value`,`max`])):createCommentVNode(``,!0)])]),_:2},1032,[`style`])):createCommentVNode(``,!0),tier.description&&tier.description.description?(openBlock(),createElementBlock(`div`,_hoisted_14$41,toDisplayString(tier.description.description),1)):createCommentVNode(``,!0)]),createBaseVNode(`div`,_hoisted_15$39,[tier.list&&tier.list.length>0?(openBlock(),createElementBlock(`div`,_hoisted_16$38,[(openBlock(!0),createElementBlock(Fragment,null,renderList(tier.list,(item,idx$1)=>(openBlock(),createBlock(UnlockCard_default,{key:idx$1,class:`unlock-item`,data:item},null,8,[`data`]))),128))])):createCommentVNode(``,!0)])])],2))),128))])]))}},UnlockRows_default=__plugin_vue_export_helper_default(_sfc_main$286,[[`__scopeId`,`data-v-ec31f890`]]),_hoisted_1$254={class:`flex-row`},_hoisted_2$210={class:`player-content`},_hoisted_3$184={class:`stats-row`},_hoisted_4$157={class:`stat-content`},_sfc_main$285={__name:`careerSimpleStats`,setup(__props,{expose:__expose}){let careerStatsData=ref({}),handleCareerSimpleStats=data=>{data.branches.forEach(entry=>{entry.hasOwnProperty(`levelLabel`)&&(entry.name=$translate.contextTranslate(entry.name,!0),entry.levelLabel=$translate.contextTranslate(entry.levelLabel,!0))}),careerStatsData.value=data},updateDisplay=()=>{Lua_default.career_modules_uiUtils.getCareerSimpleStats().then(handleCareerSimpleStats)};return onMounted(()=>{updateDisplay()}),__expose({updateDisplay}),(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$254,[createBaseVNode(`div`,_hoisted_2$210,toDisplayString(careerStatsData.value.saveSlotName),1),createBaseVNode(`div`,_hoisted_3$184,[(openBlock(!0),createElementBlock(Fragment,null,renderList(careerStatsData.value.branches,branch=>(openBlock(),createElementBlock(`div`,_hoisted_4$157,[createVNode(unref(bngProgressBar_default),{class:`stat-progress-bar`,headerLeft:branch.name,headerRight:branch.levelLabel,min:branch.min,value:branch.value,max:branch.max},null,8,[`headerLeft`,`headerRight`,`min`,`value`,`max`])]))),256))])]))}},careerSimpleStats_default=__plugin_vue_export_helper_default(_sfc_main$285,[[`__scopeId`,`data-v-94a9390d`]]),_sfc_main$284={__name:`careerStatus`,props:{slim:{type:Boolean,default:!1}},setup(__props,{expose:__expose}){let careerStatusData=ref({}),handleCareerStatusData=data=>careerStatusData.value=data,updateDisplay=()=>Lua_default.career_modules_uiUtils.getCareerStatusData().then(handleCareerStatusData);return onMounted(updateDisplay),__expose({updateDisplay}),(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,null,[createBaseVNode(`div`,{class:normalizeClass([`career-status-progress`,{slim:__props.slim}])},[createVNode(unref(bngUnit_default),{class:`career-status-value`,insuranceScore:careerStatusData.value.insuranceScore},null,8,[`insuranceScore`]),createVNode(unref(bngDivider_default)),createVNode(unref(bngUnit_default),{class:`career-status-value`,vouchers:careerStatusData.value.vouchers},null,8,[`vouchers`]),createVNode(unref(bngDivider_default)),createVNode(unref(bngUnit_default),{class:`career-status-value`,money:careerStatusData.value.money},null,8,[`money`])],2)]))}},careerStatus_default=__plugin_vue_export_helper_default(_sfc_main$284,[[`__scopeId`,`data-v-0446c53b`]]),_hoisted_1$253={key:0},_sfc_main$283={__name:`TutorialButton`,props:{text:{type:String,default:``},icon:{type:Object,default:()=>icons.questionmark},pages:{type:Object,default:[]}},setup(__props){let props=__props,buttonRef=ref(null),seen$3=ref(!0);function clickHandler(){for(let key of props.pages)Lua_default.career_modules_linearTutorial.introPopup(key,!0);seen$3.value=!0}return onMounted(()=>{}),onUnmounted(()=>{}),(_ctx,_cache)=>withDirectives((openBlock(),createBlock(unref(bngButton_default),{ref_key:`buttonRef`,ref:buttonRef,class:normalizeClass([`tut-btn`,{blink:!seen$3.value}]),icon:__props.icon,onClick:withModifiers(clickHandler,[`stop`])},{default:withCtx(()=>[__props.text?(openBlock(),createElementBlock(`span`,_hoisted_1$253,toDisplayString(__props.text),1)):createCommentVNode(``,!0)]),_:1},8,[`icon`,`class`])),[[unref(BngTooltip_default),__props.text?void 0:`View tutorial for this section`]])}},TutorialButton_default=__plugin_vue_export_helper_default(_sfc_main$283,[[`__scopeId`,`data-v-3e539b42`]]),_hoisted_1$252={class:`content`},_hoisted_2$209={class:`insurance-perks-div`},_hoisted_3$183={key:0,class:`leaving-insurance-wrapper`},_hoisted_4$156={class:`breakdown-items-wrapper`},_hoisted_5$136={class:`breakdown-item`},_hoisted_6$117={class:`orange-price`},_hoisted_7$104={class:`breakdown-item`},_hoisted_8$88={class:`red-price`},_hoisted_9$78={class:`breakdown-item total`},_hoisted_10$68={class:`breakdown-item-value-total green-price`},_hoisted_11$61={key:1,class:`no-insurance-wrapper`},_hoisted_12$50={key:2,class:`group-discount-wrapper`},_hoisted_13$43={class:`group-discount-icon-wrapper`},_hoisted_14$40={class:`group-discount-main-text`},_hoisted_15$38={class:`tier-text`},_hoisted_16$37={class:`tier-text`},_hoisted_17$31={class:`discount-text`},_hoisted_18$28={class:`grey-small-text`},_hoisted_19$24={key:3,class:`price-details-wrapper`},_hoisted_20$20={class:`price-tile`},_hoisted_21$18={key:0,class:`old-price-wrapper`},_hoisted_22$16={class:`old-price`},_hoisted_23$15={class:`price-tile-value-wrapper`},_hoisted_24$14={key:1,class:`deductible-discount`},_hoisted_25$13={class:`price-tile`},_hoisted_26$11={class:`price-tile-title`},_hoisted_27$11={class:`price-tile-value-wrapper`},_hoisted_28$10={class:`premium-extra-info`},_hoisted_29$10={class:`renewal-distance`},_sfc_main$282={__name:`insuranceCard`,props:{insuranceData:Object,isSelected:Boolean,isCurrentProvider:{type:Boolean,default:!1}},emits:[`select`],setup(__props,{emit:__emit}){let props=__props,{units}=useBridge(),emit$1=__emit,hasNoInsurance=computed(()=>props.insuranceData?.id===-1),pillText=computed(()=>{if(props.isCurrentProvider)return`CURRENT PROVIDER`;if(props.insuranceData.groupDiscountData){if(props.insuranceData.groupDiscountData?.willHaveGroupDiscountForTheFirstTime)return`MULTI-VEHICLE DISCOUNT AVAILABLE`;if(props.insuranceData.groupDiscountData?.willBumpTheirDiscount)return`BIGGER DISCOUNT AVAILABLE`;if(props.insuranceData.groupDiscountData?.currentTierData&&props.insuranceData.groupDiscountData?.currentTierData.id>0)return`MULTI-VEHICLE DISCOUNT ACTIVE`}return null}),renewsInFormatted=computed(()=>props.insuranceData?.renewsIn?units.buildString(`length`,props.insuranceData.renewsIn*1e3,0):``),leavingInsuranceRenewsInFormatted=computed(()=>props.insuranceData?.leavingInsuranceInfo?.renewsIn?units.buildString(`length`,props.insuranceData.leavingInsuranceInfo.renewsIn*1e3,0):``),selectCard=()=>{emit$1(`select`,props.insuranceData.id)},cardStyles=computed(()=>{let styles={};return!hasNoInsurance.value&&props.insuranceData.color&&(styles[`--insurance-card-rgb`]=hexToRgb(props.insuranceData.color)),styles});return(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,{class:normalizeClass([`insurance-card-container`,{selected:__props.isSelected,"no-insurance-card":hasNoInsurance.value,"current-provider":__props.isCurrentProvider}]),style:normalizeStyle(cardStyles.value),onClick:selectCard,"bng-nav-item":``},[pillText.value===null?createCommentVNode(``,!0):(openBlock(),createElementBlock(`div`,{key:0,class:normalizeClass([`top-pill`,{"no-insurance":hasNoInsurance.value,"orange-pill":__props.insuranceData.groupDiscountData?.willHaveGroupDiscountForTheFirstTime,"current-provider-pill":__props.isCurrentProvider}])},[createBaseVNode(`div`,null,toDisplayString(pillText.value),1)],2)),createBaseVNode(`div`,_hoisted_1$252,[createVNode(unref(insuranceIdentity_default),{class:`insurance-identity`,insuranceData:__props.insuranceData},null,8,[`insuranceData`]),_cache[13]||=createBaseVNode(`div`,{class:`separator`},null,-1),createBaseVNode(`div`,_hoisted_2$209,[hasNoInsurance.value?(openBlock(),createElementBlock(`div`,{key:0,class:normalizeClass([`perks-header`,{"no-insurance":hasNoInsurance.value}])},toDisplayString(hasNoInsurance.value?`Consequences`:`Included Benefits`),3)):createCommentVNode(``,!0),createVNode(unref(insurancePerks_default),{insuranceData:__props.insuranceData},null,8,[`insuranceData`])]),_cache[14]||=createBaseVNode(`div`,{class:`separator`},null,-1),hasNoInsurance.value&&__props.insuranceData.leavingInsuranceInfo&&!__props.isCurrentProvider?(openBlock(),createElementBlock(`div`,_hoisted_3$183,[_cache[4]||=createBaseVNode(`div`,{class:`leaving-insurance-title`},`Cancellation Refund`,-1),createBaseVNode(`div`,_hoisted_4$156,[createBaseVNode(`div`,_hoisted_5$136,[createBaseVNode(`span`,null,` Unused coverage (`+toDisplayString(leavingInsuranceRenewsInFormatted.value)+`) `,1),createBaseVNode(`span`,_hoisted_6$117,[_cache[0]||=createTextVNode(` + `,-1),createVNode(unref(bngUnit_default),{money:__props.insuranceData.leavingInsuranceInfo.coverageRefundPrice},null,8,[`money`])])]),createBaseVNode(`div`,_hoisted_7$104,[_cache[2]||=createBaseVNode(`span`,null,` Early Cancellation Fee (25%) `,-1),createBaseVNode(`span`,_hoisted_8$88,[_cache[1]||=createTextVNode(` - `,-1),createVNode(unref(bngUnit_default),{money:__props.insuranceData.leavingInsuranceInfo.earlyTerminationPenalty},null,8,[`money`])])]),createBaseVNode(`div`,_hoisted_9$78,[_cache[3]||=createBaseVNode(`span`,{class:`breakdown-item-label-total`},` You'll receive `,-1),createBaseVNode(`span`,_hoisted_10$68,[createVNode(unref(bngUnit_default),{money:__props.insuranceData.leavingInsuranceInfo.netRefundPrice},null,8,[`money`])])])])])):createCommentVNode(``,!0),hasNoInsurance.value?(openBlock(),createElementBlock(`div`,_hoisted_11$61,[..._cache[5]||=[createBaseVNode(`span`,{class:`no-insurance-warning`},` You will pay full repair costs `,-1),createBaseVNode(`span`,null,` No coverage or benefits included `,-1)]])):createCommentVNode(``,!0),!hasNoInsurance.value&&__props.insuranceData.groupDiscountData?.mainText?(openBlock(),createElementBlock(`div`,_hoisted_12$50,[createBaseVNode(`div`,null,[createBaseVNode(`span`,_hoisted_13$43,[createVNode(unref(bngIcon_default),{type:unref(icons).checkmark},null,8,[`type`])]),createBaseVNode(`span`,_hoisted_14$40,toDisplayString(__props.insuranceData.groupDiscountData?.mainText),1)]),createBaseVNode(`div`,null,[_cache[7]||=createBaseVNode(`span`,{class:`grey-small-text`},` Currently Insured : `,-1),createBaseVNode(`span`,null,[createVNode(unref(bngIcon_default),{class:`vehicles-icon`,type:unref(icons).car},null,8,[`type`])]),createBaseVNode(`span`,_hoisted_15$38,toDisplayString(__props.insuranceData.carsInsuredCount),1),__props.insuranceData.groupDiscountData?.currentTierData?.id>0?(openBlock(),createElementBlock(Fragment,{key:0},[_cache[6]||=createBaseVNode(`span`,{class:`vertical-separator`},` | `,-1),createBaseVNode(`span`,_hoisted_16$37,` Tier `+toDisplayString(__props.insuranceData.groupDiscountData?.currentTierData?.id),1),createBaseVNode(`span`,_hoisted_17$31,` - `+toDisplayString(__props.insuranceData.groupDiscountData?.currentTierData?.discount*100)+`% off `,1)],64)):createCommentVNode(``,!0)]),createBaseVNode(`div`,_hoisted_18$28,toDisplayString(__props.insuranceData.groupDiscountData?.secondaryText),1)])):createCommentVNode(``,!0),hasNoInsurance.value?createCommentVNode(``,!0):(openBlock(),createElementBlock(`div`,_hoisted_19$24,[createBaseVNode(`div`,_hoisted_20$20,[_cache[9]||=createBaseVNode(`span`,{class:`price-tile-title`},`Deductible`,-1),__props.insuranceData.baseDeductibledData?.oldPrice?(openBlock(),createElementBlock(`div`,_hoisted_21$18,[createBaseVNode(`div`,_hoisted_22$16,[createVNode(unref(bngUnit_default),{money:__props.insuranceData.baseDeductibledData.oldPrice},null,8,[`money`]),_cache[8]||=createBaseVNode(`div`,{class:`strike`},null,-1)])])):createCommentVNode(``,!0),createBaseVNode(`div`,_hoisted_23$15,[createVNode(unref(bngUnit_default),{money:__props.insuranceData.baseDeductibledData.price,class:normalizeClass(__props.insuranceData.baseDeductibledData.oldPrice?`green-price`:`orange-price`)},null,8,[`money`,`class`])]),_cache[10]||=createBaseVNode(`div`,{class:`deductible-tips`},[createBaseVNode(`div`,null,` - You pay your deductible for each crash repair `),createBaseVNode(`div`,null,` - Customize this value after purchase `)],-1),__props.insuranceData.baseDeductibledData.perkData?(openBlock(),createElementBlock(`div`,_hoisted_24$14,toDisplayString(__props.insuranceData.baseDeductibledData.perkData.discount*100)+`% discount applied `,1)):createCommentVNode(``,!0)]),createBaseVNode(`div`,_hoisted_25$13,[createBaseVNode(`span`,_hoisted_26$11,toDisplayString(__props.insuranceData.amountDue>0?`Amount Due`:`Credit Received`),1),createBaseVNode(`div`,_hoisted_27$11,[createVNode(unref(bngUnit_default),{money:Math.abs(__props.insuranceData.amountDue),class:`green-price`},null,8,[`money`])]),createBaseVNode(`div`,_hoisted_28$10,[createBaseVNode(`div`,null,[_cache[11]||=createTextVNode(` Total policy : `,-1),createVNode(unref(bngUnit_default),{money:__props.insuranceData.futurePremiumDetails.totalPriceWithDriverScore},null,8,[`money`])]),createBaseVNode(`div`,null,[_cache[12]||=createBaseVNode(`span`,null,`Renews in : `,-1),createBaseVNode(`span`,_hoisted_29$10,toDisplayString(renewsInFormatted.value),1)])])])]))]),createBaseVNode(`div`,{class:normalizeClass([`background`,{"no-insurance":hasNoInsurance.value}])},null,2)],6))}},insuranceCard_default=__plugin_vue_export_helper_default(_sfc_main$282,[[`__scopeId`,`data-v-e481fbef`]]),_hoisted_1$251={class:`premium-wrapper`},_hoisted_2$208={class:`breakdown-item`},_hoisted_3$182={class:`breakdown-item-value`},_hoisted_4$155={class:`premium-value-wrapper`},_hoisted_5$135={class:`breakdown-item`},_hoisted_6$116={class:`breakdown-item-value`},_hoisted_7$103={class:`breakdown-item`},_hoisted_8$87={class:`breakdown-item-value`},_hoisted_9$77={class:`breakdown-item`},_hoisted_10$67={class:`breakdown-item-value orange-text`},_hoisted_11$60={class:`perks`},_hoisted_12$49={key:0,class:`grey-text`},_hoisted_13$42={key:1,class:`grey-text`},_hoisted_14$39={class:`group-discount-savings`},_hoisted_15$37={class:`breakdown-item`},_hoisted_16$36={key:0,class:`grey-text`},_hoisted_17$30={key:1,class:`grey-text`},_hoisted_18$27={class:`buttons`},_sfc_main$281={__name:`smallInsuranceCard`,props:{insuranceData:{type:Object,required:!0},driverScoreData:{type:Object,required:!0}},setup(__props){let{units}=useBridge(),props=__props,renewsEveryFormatted=computed(()=>units.buildString(`length`,props.insuranceData.renewsEvery*1e3,0)),renewsInFormatted=computed(()=>units.buildString(`length`,props.insuranceData.renewsIn*1e3,0)),buttonsDisabled=computed(()=>props.insuranceData.carsInsuredCount===0),openVehicleList=()=>{addPopup(vehicleInsuranceList_default,{insuranceData:props.insuranceData,driverScoreData:props.driverScoreData})},openEditPolicy=()=>{addPopup(editPolicy_default,{insuranceData:props.insuranceData,driverScoreData:props.driverScoreData})},tierToDisplay=computed(()=>props.insuranceData.groupDiscountData.currentTierData.id>0?props.insuranceData.groupDiscountData.currentTierData:props.insuranceData.groupDiscountData.groupDiscountTiers[0]);return(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,{class:normalizeClass([`small-insurance-card`,{"no-vehicles":buttonsDisabled.value}]),style:normalizeStyle({"border-top":`0.7rem solid ${props.insuranceData.color}`,background:`linear-gradient(180deg, ${props.insuranceData.color}80 0%, ${props.insuranceData.color}30 10%, ${props.insuranceData.color}10 35%, var(--bng-cool-gray-800) 50%, var(--blue-shade-100) 100%)`})},[createVNode(unref(insuranceIdentity_default),{class:`insurance-identity`,insuranceData:props.insuranceData},null,8,[`insuranceData`]),createBaseVNode(`div`,_hoisted_1$251,[createBaseVNode(`div`,_hoisted_2$208,[createBaseVNode(`span`,null,`Premium / `+toDisplayString(renewsEveryFormatted.value),1),createBaseVNode(`span`,_hoisted_3$182,[createBaseVNode(`div`,_hoisted_4$155,[createVNode(unref(bngUnit_default),{money:props.insuranceData.currentPremiumDetails.totalPriceWithDriverScore},null,8,[`money`])])])]),createBaseVNode(`div`,_hoisted_5$135,[_cache[0]||=createBaseVNode(`span`,null,`Renews in `,-1),createBaseVNode(`span`,_hoisted_6$116,[props.insuranceData.carsInsuredCount===0?(openBlock(),createElementBlock(Fragment,{key:0},[createTextVNode(` - `)],64)):(openBlock(),createElementBlock(Fragment,{key:1},[createTextVNode(toDisplayString(renewsInFormatted.value),1)],64))])]),createBaseVNode(`div`,_hoisted_7$103,[_cache[1]||=createBaseVNode(`span`,null,`Vehicle Coverage`,-1),createBaseVNode(`span`,_hoisted_8$87,[createVNode(unref(bngUnit_default),{money:props.insuranceData.totalInsuranceVehsValue},null,8,[`money`])])]),createBaseVNode(`div`,_hoisted_9$77,[_cache[2]||=createBaseVNode(`span`,null,`Vehicles`,-1),createBaseVNode(`span`,_hoisted_10$67,toDisplayString(props.insuranceData.carsInsuredCount),1)])]),createBaseVNode(`div`,_hoisted_11$60,[createVNode(unref(insurancePerks_default),{insuranceData:props.insuranceData,noDescription:!0},null,8,[`insuranceData`])]),createBaseVNode(`div`,{class:normalizeClass([`group-discount-wrapper`,{disabled:props.insuranceData.groupDiscountData.currentTierData.id===-1}])},[props.insuranceData.carsInsuredCount===0?(openBlock(),createElementBlock(`div`,_hoisted_12$49,` No vehicles insured under this policy `)):props.insuranceData.carsInsuredCount===1?(openBlock(),createElementBlock(`div`,_hoisted_13$42,` Add a second vehicle to unlock Tier 1 (`+toDisplayString(props.insuranceData.groupDiscountData.groupDiscountTiers[0].discount*100)+`%) coverage savings. `,1)):(openBlock(),createElementBlock(Fragment,{key:2},[_cache[4]||=createBaseVNode(`div`,{class:`group-discount`},` MULTI-VEHICLE DISCOUNT `,-1),createBaseVNode(`div`,_hoisted_14$39,[_cache[3]||=createTextVNode(` Savings :`,-1),createVNode(unref(bngUnit_default),{money:props.insuranceData.currentPremiumDetails.groupDiscountSavings},null,8,[`money`])]),createBaseVNode(`div`,_hoisted_15$37,[tierToDisplay.value.max?(openBlock(),createElementBlock(`span`,_hoisted_16$36,` Your coverage falls in the `+toDisplayString(tierToDisplay.value.min/1e3)+`k - `+toDisplayString(tierToDisplay.value.max/1e3)+`k range `,1)):(openBlock(),createElementBlock(`span`,_hoisted_17$30,` Your coverage falls in the `+toDisplayString(tierToDisplay.value.min/1e3)+`k+ range `,1))]),createBaseVNode(`div`,null,[createVNode(unref(insuranceTiers_default),{showTier:!0,tiers:props.insuranceData.groupDiscountData.groupDiscountTiers},null,8,[`tiers`])])],64))],2),createBaseVNode(`div`,_hoisted_18$27,[createVNode(unref(bngButton_default),{class:`edit-policy-button bigger-button`,accent:`custom`,onClick:openEditPolicy,disabled:buttonsDisabled.value},{default:withCtx(()=>[createVNode(unref(bngIcon_default),{class:normalizeClass([`button-icon`,{disabled:buttonsDisabled.value}]),type:unref(icons).adjust},null,8,[`type`,`class`]),createBaseVNode(`span`,{class:normalizeClass([`button-text`,{disabled:buttonsDisabled.value}])},`Edit Policy`,2)]),_:1},8,[`disabled`]),createVNode(unref(bngButton_default),{class:`see-vehicles-button bigger-button`,accent:`custom`,onClick:openVehicleList,disabled:buttonsDisabled.value},{default:withCtx(()=>[createVNode(unref(bngIcon_default),{class:normalizeClass([`button-icon`,{disabled:buttonsDisabled.value}]),type:unref(icons).car},null,8,[`type`,`class`]),createBaseVNode(`span`,{class:normalizeClass([`button-text`,{disabled:buttonsDisabled.value}])},`See Vehicles`,2)]),_:1},8,[`disabled`])])],6))}},smallInsuranceCard_default=__plugin_vue_export_helper_default(_sfc_main$281,[[`__scopeId`,`data-v-38392c0c`]]),_hoisted_1$250={class:`insurance-details-wrapper`,"bng-ui-scope":`insuranceDetailsPopup`},_hoisted_2$207={class:`card-content`},_hoisted_3$181={class:`header`},_hoisted_4$154={class:`header-left`},_hoisted_5$134={class:`insurance-identity`},_hoisted_6$115={class:`insurance-name`},_hoisted_7$102={class:`insurance-slogan`},_hoisted_8$86={class:`covers-renew-info`},_hoisted_9$76={class:`header-right`},_hoisted_10$66={class:`vehicle-name`},_hoisted_11$59={class:`vehicle-value blue-price`},_hoisted_12$48={key:0,class:`group-discount-wrapper`},_hoisted_13$41={class:`group-discount-header`},_hoisted_14$38={class:`group-discount-icon-wrapper`},_hoisted_15$36={class:`group-discount-text-wrapper`},_hoisted_16$35={class:`group-discount-main-text`},_hoisted_17$29={class:`tiers-wrapper`},_hoisted_18$26={class:`textual-tiers-wrapper`},_hoisted_19$23={class:`tier-number`},_hoisted_20$19={class:`money-bracket`},_hoisted_21$17={key:0},_hoisted_22$15={key:1},_hoisted_23$14={class:`current-after-discount-price`},_hoisted_24$13={class:`tier-discount-price`},_hoisted_25$12={class:`policy-value`},_hoisted_26$10={class:`policy-tier`},_hoisted_27$10={class:`tier-discount-price isFutureTier`},_hoisted_28$9={class:`policy-value`},_hoisted_29$9={class:`policy-tier isFuture`},_hoisted_30$9={class:`price-breakdown-wrapper`},_hoisted_31$9={class:`prices-breakdown-header`},_hoisted_32$9={class:`breakdown-item`},_hoisted_33$9={class:`breakdown-details`},_hoisted_34$9={class:`breakdown-item-value`},_hoisted_35$8={class:`breakdown-value`},_hoisted_36$8={class:`breakdown-item-value orange`},_hoisted_37$7={class:`breakdown-value`},_hoisted_38$6={key:0,class:`breakdown-item-value orange`},_hoisted_39$6={class:`breakdown-label`},_hoisted_40$5={class:`breakdown-value`},_hoisted_41$5={class:`breakdown-item-value result`},_hoisted_42$4={class:`breakdown-value result`},_hoisted_43$4={class:`breakdown-item`},_hoisted_44$4={class:`breakdown-details`},_hoisted_45$4={key:0,class:`breakdown-item-value`},_hoisted_46$2={key:0,class:`strikethrough-line`},_hoisted_47$2={key:1,class:`breakdown-item-value`},_hoisted_48$2={class:`breakdown-label`},_hoisted_49$2={class:`tier-discount-badge`},_hoisted_50$2={class:`breakdown-value green-price`},_hoisted_51$2={key:0,class:`breakdown-item-value`},_hoisted_52$2={class:`breakdown-label`},_hoisted_53$2={class:`breakdown-value`},_hoisted_54$2={class:`breakdown-item-value subtotal`},_hoisted_55$2={class:`breakdown-value`},_hoisted_56$2={class:`breakdown-item-value`},_hoisted_57$1={class:`breakdown-item-value result`},_hoisted_58$1={class:`breakdown-value`},_hoisted_59$1={class:`sum-to-pay`},_hoisted_60$1={class:`sum-to-pay-value`},_hoisted_61$1={class:`closeButton`},__default__$5={wrapper:{fade:!0,blur:!0,style:popupContainer.default},position:[popupPosition.center,popupPosition.center]},_sfc_main$280=Object.assign(__default__$5,{__name:`purchaseInsuranceDetails`,props:{insuranceData:Object,vehicleInfo:Object,driverScoreData:Object},emits:[`return`],setup(__props,{emit:__emit}){let{units}=useBridge();useUINavScope(`insuranceDetailsPopup`);let props=__props,emit$1=__emit,closePopup=()=>{emit$1(`return`,!0)},driverScoreAdjustmentText=computed(()=>{let multiplier=props.driverScoreData.tier.multiplier;return multiplier<1?`↓${((1-multiplier)*100).toFixed(0)}%`:multiplier>1?`↑${((multiplier-1)*100).toFixed(0)}%`:`0%`}),driverScoreClass=computed(()=>{let multiplier=props.driverScoreData.tier.multiplier;return multiplier<1?`driver-score-discount`:multiplier>1?`driver-score-penalty`:``}),groupDiscountText=computed(()=>{if(props.insuranceData.groupDiscountData){if(props.insuranceData.groupDiscountData.willHaveGroupDiscountForTheFirstTime)return`Multi-vehicle discount available`;if(props.insuranceData.groupDiscountData.willBumpTheirDiscount)return`Bigger discount available`;if(props.insuranceData.groupDiscountData.currentTierData&&props.insuranceData.groupDiscountData.currentTierData.id>0)return`Multi-vehicle discount active`}return null}),renewsEveryFormatted=computed(()=>props.insuranceData?.renewsEvery?units.buildString(`length`,props.insuranceData.renewsEvery*1e3,0):``);return(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$250,[createBaseVNode(`div`,_hoisted_2$207,[createBaseVNode(`div`,_hoisted_3$181,[createBaseVNode(`div`,_hoisted_4$154,[_cache[2]||=createBaseVNode(`div`,{class:`policy-details`},` Policy details `,-1),createBaseVNode(`div`,_hoisted_5$134,[createBaseVNode(`span`,_hoisted_6$115,toDisplayString(props.insuranceData.name),1),_cache[0]||=createBaseVNode(`span`,{class:`name-slogan-seperator`},null,-1),createBaseVNode(`span`,_hoisted_7$102,toDisplayString(props.insuranceData.slogan),1)]),createBaseVNode(`div`,_hoisted_8$86,[createBaseVNode(`span`,null,`Covers `+toDisplayString(props.insuranceData.carsInsuredCount)+` Vehicles`,1),_cache[1]||=createBaseVNode(`span`,{class:`covers-renew-seperator`},null,-1),createBaseVNode(`span`,null,`Renews every `+toDisplayString(renewsEveryFormatted.value),1)])]),createBaseVNode(`div`,_hoisted_9$76,[_cache[4]||=createBaseVNode(`div`,{class:`action-type`},`Adding vehicle`,-1),createBaseVNode(`div`,_hoisted_10$66,toDisplayString(props.vehicleInfo.Name),1),createBaseVNode(`div`,_hoisted_11$59,[_cache[3]||=createTextVNode(`Value : `,-1),createVNode(unref(bngUnit_default),{money:props.vehicleInfo.Value},null,8,[`money`])])])]),props.insuranceData.groupDiscountData.willHaveGroupDiscountForTheFirstTime||props.insuranceData.groupDiscountData.willBumpTheirDiscount||props.insuranceData.groupDiscountData.currentTierData.id>0?(openBlock(),createElementBlock(`div`,_hoisted_12$48,[createBaseVNode(`div`,_hoisted_13$41,[createBaseVNode(`div`,_hoisted_14$38,[createVNode(unref(bngIcon_default),{type:unref(icons).checkmark},null,8,[`type`])]),createBaseVNode(`div`,_hoisted_15$36,[createBaseVNode(`div`,_hoisted_16$35,toDisplayString(groupDiscountText.value),1),_cache[5]||=createBaseVNode(`div`,{class:`group-discount-secondary-text`},` Insurance discounts are based on the total value of your fleet. `,-1)])]),createBaseVNode(`div`,_hoisted_17$29,[createBaseVNode(`div`,_hoisted_18$26,[(openBlock(!0),createElementBlock(Fragment,null,renderList(props.insuranceData.groupDiscountData.groupDiscountTiers,tier=>(openBlock(),createElementBlock(`div`,{class:`tier`,key:tier.id},[createBaseVNode(`div`,_hoisted_19$23,` Tier `+toDisplayString(tier.id),1),createBaseVNode(`div`,_hoisted_20$19,[createBaseVNode(`span`,null,toDisplayString(tier.min/1e3)+`k`,1),tier.max?(openBlock(),createElementBlock(`span`,_hoisted_21$17,`-`+toDisplayString(tier.max/1e3)+`k`,1)):(openBlock(),createElementBlock(`span`,_hoisted_22$15,`+`))])]))),128))]),createVNode(unref(insuranceTiers_default),{tiers:props.insuranceData.groupDiscountData.groupDiscountTiers},null,8,[`tiers`])]),createBaseVNode(`div`,_hoisted_23$14,[createBaseVNode(`div`,_hoisted_24$13,[_cache[7]||=createBaseVNode(`div`,{class:`section-label deactivated`},` Current Tier `,-1),createBaseVNode(`div`,_hoisted_25$12,[_cache[6]||=createTextVNode(` Policy Value : `,-1),createVNode(unref(bngUnit_default),{money:props.insuranceData.totalInsuranceVehsValue},null,8,[`money`])]),createBaseVNode(`div`,_hoisted_26$10,` Tier `+toDisplayString(Math.max(props.insuranceData.groupDiscountData.currentTierData.id,0))+` - `+toDisplayString(props.insuranceData.groupDiscountData.currentTierData.discount*100)+`% off `,1)]),createBaseVNode(`div`,_hoisted_27$10,[_cache[9]||=createBaseVNode(`div`,{class:`section-label`},` After Purchase `,-1),createBaseVNode(`div`,_hoisted_28$9,[_cache[8]||=createTextVNode(` Policy Value : `,-1),createVNode(unref(bngUnit_default),{money:props.insuranceData.totalInsuranceVehsValue+props.insuranceData.vehicleValue},null,8,[`money`])]),createBaseVNode(`div`,_hoisted_29$9,` Tier `+toDisplayString(props.insuranceData.groupDiscountData.futureTierData.id)+` - `+toDisplayString(props.insuranceData.groupDiscountData.futureTierData.discount*100)+`% off `,1)])])])):createCommentVNode(``,!0),createBaseVNode(`div`,_hoisted_30$9,[createBaseVNode(`div`,_hoisted_31$9,[createBaseVNode(`div`,_hoisted_32$9,[_cache[13]||=createBaseVNode(`div`,{class:`section-label`},` Vehicle `,-1),createBaseVNode(`div`,_hoisted_33$9,[createBaseVNode(`div`,_hoisted_34$9,[_cache[10]||=createBaseVNode(`span`,{class:`breakdown-label`},` Coverage Cost `,-1),createBaseVNode(`span`,_hoisted_35$8,[createVNode(unref(bngUnit_default),{money:props.insuranceData.nonProRatedVehiclePremium},null,8,[`money`])])]),createBaseVNode(`div`,_hoisted_36$8,[_cache[11]||=createBaseVNode(`span`,{class:`breakdown-label`},` Pro-rated Renewal `,-1),createBaseVNode(`span`,_hoisted_37$7,` × `+toDisplayString(props.insuranceData.proRatedPercentage)+`% `,1)]),props.insuranceData.groupDiscountData?.currentTierData.id>0?(openBlock(),createElementBlock(`div`,_hoisted_38$6,[createBaseVNode(`span`,_hoisted_39$6,` Tier `+toDisplayString(props.insuranceData.groupDiscountData?.currentTierData.id)+` discount `,1),createBaseVNode(`span`,_hoisted_40$5,` - `+toDisplayString(props.insuranceData.groupDiscountData?.currentTierData.discount*100)+`% `,1)])):createCommentVNode(``,!0),createBaseVNode(`div`,_hoisted_41$5,[_cache[12]||=createBaseVNode(`span`,{class:`breakdown-label`},` Policy Add-On Cost `,-1),createBaseVNode(`span`,_hoisted_42$4,[createVNode(unref(bngUnit_default),{money:props.insuranceData.proRatedVehiclePremium},null,8,[`money`])])])])]),createBaseVNode(`div`,_hoisted_43$4,[_cache[18]||=createBaseVNode(`div`,{class:`section-label`},` New Premium `,-1),createBaseVNode(`div`,_hoisted_44$4,[props.insuranceData.futurePremiumDetails.items.vehsCoverage?(openBlock(),createElementBlock(`div`,_hoisted_45$4,[_cache[14]||=createBaseVNode(`div`,{class:`breakdown-label`},` Vehicles Coverage `,-1),createBaseVNode(`div`,{class:normalizeClass([`breakdown-value strikethrough-container`,{"strikethrough-grey":props.insuranceData.futurePremiumDetails.groupDiscountSavings>0}])},[createVNode(unref(bngUnit_default),{money:props.insuranceData.futurePremiumDetails.items.vehsCoverage.priceWithoutGroupDiscount},null,8,[`money`]),props.insuranceData.futurePremiumDetails.groupDiscountSavings>0?(openBlock(),createElementBlock(`div`,_hoisted_46$2)):createCommentVNode(``,!0)],2)])):createCommentVNode(``,!0),props.insuranceData.futurePremiumDetails.items.vehsCoverage&&props.insuranceData.futurePremiumDetails.groupDiscountSavings>0?(openBlock(),createElementBlock(`div`,_hoisted_47$2,[createBaseVNode(`div`,_hoisted_48$2,[createTextVNode(toDisplayString(props.insuranceData.futurePremiumDetails.items.vehsCoverage.name)+` `,1),createBaseVNode(`span`,null,[createTextVNode(`: Tier `+toDisplayString(props.insuranceData.groupDiscountData.currentTierData.id)+` `,1),createBaseVNode(`span`,_hoisted_49$2,`(`+toDisplayString(props.insuranceData.groupDiscountData.currentTierData.discount*100)+`% off)`,1)])]),createBaseVNode(`div`,_hoisted_50$2,[createVNode(unref(bngUnit_default),{money:props.insuranceData.futurePremiumDetails.items.vehsCoverage.price},null,8,[`money`])])])):createCommentVNode(``,!0),(openBlock(!0),createElementBlock(Fragment,null,renderList(props.insuranceData.futurePremiumDetails.items,(item,key)=>(openBlock(),createElementBlock(Fragment,{key},[key===`vehsCoverage`?createCommentVNode(``,!0):(openBlock(),createElementBlock(`div`,_hoisted_51$2,[createBaseVNode(`div`,_hoisted_52$2,toDisplayString(item.name),1),createBaseVNode(`div`,_hoisted_53$2,[createVNode(unref(bngUnit_default),{money:item.price},null,8,[`money`])])]))],64))),128)),createBaseVNode(`div`,_hoisted_54$2,[_cache[15]||=createBaseVNode(`div`,{class:`breakdown-label`},` Subtotal `,-1),createBaseVNode(`div`,_hoisted_55$2,[createVNode(unref(bngUnit_default),{money:props.insuranceData.futurePremiumDetails.totalPrice},null,8,[`money`])])]),createBaseVNode(`div`,_hoisted_56$2,[_cache[16]||=createBaseVNode(`div`,{class:`breakdown-label`},` Driver Score Adjustment `,-1),createBaseVNode(`div`,{class:normalizeClass([`breakdown-value`,driverScoreClass.value])},toDisplayString(driverScoreAdjustmentText.value),3)]),createBaseVNode(`div`,_hoisted_57$1,[_cache[17]||=createBaseVNode(`div`,{class:`breakdown-label`},` Total Premium `,-1),createBaseVNode(`div`,_hoisted_58$1,[createVNode(unref(bngUnit_default),{money:props.insuranceData.futurePremiumDetails.totalPriceWithDriverScore},null,8,[`money`])])])])])]),createBaseVNode(`div`,_hoisted_59$1,[_cache[19]||=createBaseVNode(`span`,null,`Amount due today`,-1),createBaseVNode(`span`,_hoisted_60$1,[createVNode(unref(bngUnit_default),{class:`green-price`,money:props.insuranceData.addVehiclePrice},null,8,[`money`])])])]),createBaseVNode(`div`,_hoisted_61$1,[createVNode(unref(bngButton_default),{accent:unref(ACCENTS).primary,onClick:closePopup},{default:withCtx(()=>[..._cache[20]||=[createTextVNode(` Close `,-1)]]),_:1},8,[`accent`])])])]))}}),purchaseInsuranceDetails_default=__plugin_vue_export_helper_default(_sfc_main$280,[[`__scopeId`,`data-v-9f20c127`]]),_hoisted_1$249={class:`content`},_hoisted_2$206={class:`top-banner`},_hoisted_3$180={class:`top-banner-left`},_hoisted_4$153={class:`insurance-details`},_hoisted_5$133={class:`insurance-name`},_hoisted_6$114={class:`insurance-slogan`},_hoisted_7$101={class:`small-grey-text`},_hoisted_8$85={class:`small-grey-text`},_hoisted_9$75={class:`top-banner-right`},_hoisted_10$65={class:`information-wrapper`},_hoisted_11$58={class:`information-value`},_hoisted_12$47={class:`driver-score-tier`},_hoisted_13$40={class:`premium-effect`},_hoisted_14$37={class:`switching-details-wrapper`},_hoisted_15$35={class:`three-columns-grid`},_hoisted_16$34={class:`switching-column column-leaving`},_hoisted_17$28={class:`column-header`},_hoisted_18$25={class:`column-details`},_hoisted_19$22={class:`detail-item`},_hoisted_20$18={class:`detail-value`},_hoisted_21$16={class:`detail-item`},_hoisted_22$14={class:`detail-item divider-above`},_hoisted_23$13={class:`detail-value-positive`},_hoisted_24$12={class:`detail-item`},_hoisted_25$11={class:`detail-value-negative`},_hoisted_26$9={class:`detail-item divider-above`},_hoisted_27$9={class:`detail-value-positive-bold`},_hoisted_28$8={class:`detail-note`},_hoisted_29$8={class:`switching-column column-vehicle`},_hoisted_30$8={class:`vehicle-display-box`},_hoisted_31$8=[`src`],_hoisted_32$8={class:`column-details`},_hoisted_33$8={class:`detail-item`},_hoisted_34$8={class:`detail-value-bold`},_hoisted_35$7={class:`detail-item`},_hoisted_36$7={class:`detail-value-bold`},_hoisted_37$6={class:`detail-item divider-above`},_hoisted_38$5={class:`detail-value-highlight`},_hoisted_39$5={class:`detail-note`},_hoisted_40$4={class:`switching-column column-joining`},_hoisted_41$4={class:`column-header`},_hoisted_42$3={class:`column-details`},_hoisted_43$3={class:`detail-item`},_hoisted_44$3={class:`detail-value`},_hoisted_45$3={class:`detail-item`},_hoisted_46$1={class:`detail-item divider-above`},_hoisted_47$1={class:`detail-value-negative`},_hoisted_48$1={class:`detail-item divider-above`},_hoisted_49$1={class:`detail-item divider-above`},_hoisted_50$1={class:`detail-value-bold`},_hoisted_51$1={class:`detail-note`},_hoisted_52$1={class:`final-amount-content-row`},_hoisted_53$1={class:`final-amount-label`},_hoisted_54$1={class:`final-amount-breakdown`},_hoisted_55$1={class:`buttons`},_hoisted_56$1={key:0},_sfc_main$279={__name:`changeInsuranceDetails`,props:{insuranceData:{type:Object,required:!0},vehicleInfo:{type:Object,default:()=>({})},driverScoreData:{type:Object,default:()=>({})}},emits:[`return`,`switch`],setup(__props,{emit:__emit}){let{units}=useBridge(),props=__props,emit$1=__emit,premiumSavingPercent=computed(()=>(1-(props.driverScoreData?.tier?.multiplier||1))*100),leavingInfo=computed(()=>props.insuranceData.leavingInsuranceInfo||null),leavingInsuranceName=computed(()=>leavingInfo.value?.currentInsuranceName||`Current Insurance`),tierDropped=computed(()=>leavingInfo.value?leavingInfo.value.discountTierData?.id>leavingInfo.value.newDiscountTierData?.id:!1),tierIncreased=computed(()=>{let current=props.insuranceData.groupDiscountData?.currentTierData?.id||0;return(props.insuranceData.groupDiscountData?.futureTierData?.id||current)>current}),currentTierId=computed(()=>props.insuranceData.groupDiscountData?.currentTierData?.id||0),futureTierId=computed(()=>props.insuranceData.groupDiscountData?.futureTierData?.id||props.insuranceData.groupDiscountData?.currentTierData?.id||0),proRatedPercentage=computed(()=>Math.round(props.insuranceData.proRatedPercentage||100)),driverScoreImpactPercent=computed(()=>(1-(props.driverScoreData?.tier?.multiplier||1))*100),driverScoreImpactClass=computed(()=>driverScoreImpactPercent.value>0?`saving`:driverScoreImpactPercent.value<0?`increase`:`neutral`),driverScoreImpactText=computed(()=>driverScoreImpactPercent.value>0?`↓${driverScoreImpactPercent.value.toFixed(0)}%`:driverScoreImpactPercent.value<0?`↑${Math.abs(driverScoreImpactPercent.value).toFixed(0)}%`:`0%`),renewsEveryFormatted=computed(()=>props.insuranceData?.renewsEvery?units.buildString(`length`,props.insuranceData.renewsEvery*1e3,0):``),renewsInFormatted=computed(()=>props.insuranceData?.renewsIn?units.buildString(`length`,props.insuranceData.renewsIn*1e3,0):``),leavingRenewsInFormatted=computed(()=>leavingInfo.value?.renewsIn?units.buildString(`length`,leavingInfo.value.renewsIn*1e3,0):``),closePopup=()=>{emit$1(`return`,!0)},onSwitchClick=()=>{Lua_default.career_modules_insurance_insurance.changeInvVehInsurance(props.vehicleInfo.invVehId,props.insuranceData.id),emit$1(`return`,!0)};return(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$249,[createBaseVNode(`div`,_hoisted_2$206,[createBaseVNode(`div`,_hoisted_3$180,[_cache[2]||=createBaseVNode(`div`,{class:`title`},` Change Insurance `,-1),createBaseVNode(`div`,_hoisted_4$153,[createBaseVNode(`span`,_hoisted_5$133,toDisplayString(props.insuranceData.name),1),_cache[0]||=createBaseVNode(`span`,{class:`name-slogan-seperator`},null,-1),createBaseVNode(`span`,_hoisted_6$114,` "`+toDisplayString(props.insuranceData.slogan)+`" `,1)]),createBaseVNode(`div`,null,[createBaseVNode(`span`,_hoisted_7$101,` Covers `+toDisplayString(props.insuranceData.carsInsuredCount)+` Vehicles `,1),_cache[1]||=createBaseVNode(`span`,{class:`dot-seperator`},null,-1),createBaseVNode(`span`,_hoisted_8$85,` Renews every `+toDisplayString(renewsEveryFormatted.value),1)])]),createBaseVNode(`div`,_hoisted_9$75,[createBaseVNode(`div`,_hoisted_10$65,[_cache[4]||=createBaseVNode(`div`,{class:`small-grey-text`},` Driver Score `,-1),createBaseVNode(`div`,_hoisted_11$58,toDisplayString(props.driverScoreData.score)+`: `+toDisplayString(props.driverScoreData.tier.risk),1),createBaseVNode(`div`,_hoisted_12$47,toDisplayString(props.driverScoreData.tier.name),1),createBaseVNode(`div`,_hoisted_13$40,[_cache[3]||=createBaseVNode(`span`,{class:`small-grey-text`},` Premium Effect : `,-1),createBaseVNode(`span`,{class:normalizeClass([`premium-effect-value`,{saving:premiumSavingPercent.value>0,increase:premiumSavingPercent.value<0}])},toDisplayString(premiumSavingPercent.value>0?`${premiumSavingPercent.value.toFixed(0)}% saving`:premiumSavingPercent.value<0?`${Math.abs(premiumSavingPercent.value).toFixed(0)}% increase`:`No change`),3)])])])]),createBaseVNode(`div`,_hoisted_14$37,[createBaseVNode(`div`,_hoisted_15$35,[createBaseVNode(`div`,_hoisted_16$34,[createBaseVNode(`div`,_hoisted_17$28,[_cache[5]||=createBaseVNode(`span`,null,`←`,-1),createTextVNode(` Leaving `+toDisplayString(leavingInsuranceName.value),1)]),createBaseVNode(`div`,_hoisted_18$25,[createBaseVNode(`div`,_hoisted_19$22,[_cache[6]||=createBaseVNode(`span`,{class:`detail-label`},`Vehicles:`,-1),createBaseVNode(`span`,_hoisted_20$18,toDisplayString(leavingInfo.value.vehicleCount)+` → `+toDisplayString(leavingInfo.value.newVehicleCount),1)]),createBaseVNode(`div`,_hoisted_21$16,[_cache[7]||=createBaseVNode(`span`,{class:`detail-label`},`Discount Tier:`,-1),createBaseVNode(`span`,{class:normalizeClass([`detail-value`,{"tier-change-down":tierDropped.value}])},toDisplayString(leavingInfo.value.discountTierData.id)+` → `+toDisplayString(leavingInfo.value.newDiscountTierData.id),3)]),createBaseVNode(`div`,_hoisted_22$14,[_cache[9]||=createBaseVNode(`span`,{class:`detail-label`},`Coverage refund:`,-1),createBaseVNode(`span`,_hoisted_23$13,[_cache[8]||=createTextVNode(`+`,-1),createVNode(unref(bngUnit_default),{money:leavingInfo.value.coverageRefundPrice},null,8,[`money`])])]),createBaseVNode(`div`,_hoisted_24$12,[_cache[11]||=createBaseVNode(`span`,{class:`detail-label`},`Cancellation fee (25%):`,-1),createBaseVNode(`span`,_hoisted_25$11,[_cache[10]||=createTextVNode(`-`,-1),createVNode(unref(bngUnit_default),{money:leavingInfo.value.earlyTerminationPenalty},null,8,[`money`])])]),createBaseVNode(`div`,_hoisted_26$9,[_cache[12]||=createBaseVNode(`span`,{class:`detail-label-bold`},`Net Refund:`,-1),createBaseVNode(`span`,_hoisted_27$9,[createVNode(unref(bngUnit_default),{money:leavingInfo.value.netRefundPrice},null,8,[`money`])])]),createBaseVNode(`div`,_hoisted_28$8,toDisplayString(leavingRenewsInFormatted.value)+` unused `,1)])]),createBaseVNode(`div`,_hoisted_29$8,[_cache[16]||=createBaseVNode(`div`,{class:`column-header column-header-center`},`Moving Vehicle`,-1),createBaseVNode(`div`,_hoisted_30$8,[createBaseVNode(`img`,{src:props.vehicleInfo?.thumbnail,alt:``,class:`vehicle-thumbnail`},null,8,_hoisted_31$8)]),createBaseVNode(`div`,_hoisted_32$8,[createBaseVNode(`div`,_hoisted_33$8,[_cache[13]||=createBaseVNode(`span`,{class:`detail-label`},`Vehicle:`,-1),createBaseVNode(`span`,_hoisted_34$8,toDisplayString(props.vehicleInfo.Name),1)]),createBaseVNode(`div`,_hoisted_35$7,[_cache[14]||=createBaseVNode(`span`,{class:`detail-label`},`Value:`,-1),createBaseVNode(`span`,_hoisted_36$7,[createVNode(unref(bngUnit_default),{money:props.vehicleInfo.Value},null,8,[`money`])])]),createBaseVNode(`div`,_hoisted_37$6,[_cache[15]||=createBaseVNode(`span`,{class:`detail-label`},`Joining mid-cycle:`,-1),createBaseVNode(`span`,_hoisted_38$5,`× `+toDisplayString(proRatedPercentage.value)+`%`,1)]),createBaseVNode(`div`,_hoisted_39$5,toDisplayString(renewsInFormatted.value)+` remaining in cycle `,1)])]),createBaseVNode(`div`,_hoisted_40$4,[createBaseVNode(`div`,_hoisted_41$4,[createTextVNode(` Joining `+toDisplayString(props.insuranceData.name)+` `,1),_cache[17]||=createBaseVNode(`span`,null,`→`,-1)]),createBaseVNode(`div`,_hoisted_42$3,[createBaseVNode(`div`,_hoisted_43$3,[_cache[18]||=createBaseVNode(`span`,{class:`detail-label`},`Vehicles:`,-1),createBaseVNode(`span`,_hoisted_44$3,toDisplayString(props.insuranceData.carsInsuredCount)+` → `+toDisplayString(props.insuranceData.carsInsuredCount+1),1)]),createBaseVNode(`div`,_hoisted_45$3,[_cache[19]||=createBaseVNode(`span`,{class:`detail-label`},`Discount Tier:`,-1),createBaseVNode(`span`,{class:normalizeClass([`detail-value`,{"tier-change-up":tierIncreased.value}])},toDisplayString(currentTierId.value)+` → `+toDisplayString(futureTierId.value),3)]),createBaseVNode(`div`,_hoisted_46$1,[_cache[21]||=createBaseVNode(`span`,{class:`detail-label`},`Add vehicle cost:`,-1),createBaseVNode(`span`,_hoisted_47$1,[_cache[20]||=createTextVNode(`+`,-1),createVNode(unref(bngUnit_default),{money:props.insuranceData.addVehiclePrice},null,8,[`money`])])]),createBaseVNode(`div`,_hoisted_48$1,[_cache[22]||=createBaseVNode(`span`,{class:`detail-label`},`Driver Score Impact:`,-1),createBaseVNode(`span`,{class:normalizeClass([`detail-value-impact`,driverScoreImpactClass.value])},toDisplayString(driverScoreImpactText.value),3)]),createBaseVNode(`div`,_hoisted_49$1,[_cache[23]||=createBaseVNode(`span`,{class:`detail-label-bold`},`New Policy Premium:`,-1),createBaseVNode(`span`,_hoisted_50$1,[createVNode(unref(bngUnit_default),{money:props.insuranceData.futurePremiumDetails.totalPriceWithDriverScore},null,8,[`money`])])]),createBaseVNode(`div`,_hoisted_51$1,toDisplayString(renewsInFormatted.value)+` until renewal `,1)])])]),createBaseVNode(`div`,{class:normalizeClass([`final-amount-box`,props.insuranceData.netSwitchingCost>0?`amount-credit`:`amount-payment`])},[createBaseVNode(`div`,_hoisted_52$1,[createBaseVNode(`div`,null,[createBaseVNode(`div`,_hoisted_53$1,toDisplayString(props.insuranceData.netSwitchingCost>0?`Credit Received Today`:`Amount Due Today`),1),createBaseVNode(`div`,_hoisted_54$1,[createVNode(unref(bngUnit_default),{money:leavingInfo.value.netRefundPrice},null,8,[`money`]),_cache[24]||=createTextVNode(` refund - `,-1),createVNode(unref(bngUnit_default),{money:props.insuranceData.addVehiclePrice},null,8,[`money`]),_cache[25]||=createTextVNode(` new cost `,-1)])]),createBaseVNode(`div`,{class:normalizeClass([`final-amount-total`,props.insuranceData.netSwitchingCost<0?`negative`:`positive`])},[createVNode(unref(bngUnit_default),{money:Math.abs(props.insuranceData.netSwitchingCost)},null,8,[`money`])],2)])],2)]),createBaseVNode(`div`,_hoisted_55$1,[createVNode(unref(bngButton_default),{class:`gray-button bigger-button`,accent:`custom`,onClick:closePopup},{default:withCtx(()=>[..._cache[26]||=[createTextVNode(` Cancel `,-1)]]),_:1}),createVNode(unref(bngButton_default),{class:`save-button bigger-button`,accent:`custom`,onClick:onSwitchClick},{default:withCtx(()=>[_cache[27]||=createTextVNode(` Switch for `,-1),props.insuranceData.netSwitchingCost<0?(openBlock(),createElementBlock(`div`,_hoisted_56$1,[createVNode(unref(bngUnit_default),{money:Math.abs(props.insuranceData.netSwitchingCost)},null,8,[`money`])])):createCommentVNode(``,!0)]),_:1})])]))}},changeInsuranceDetails_default=__plugin_vue_export_helper_default(_sfc_main$279,[[`__scopeId`,`data-v-9624a106`]]),_hoisted_1$248={class:`insurance-tiers`},_hoisted_2$205={key:0},_sfc_main$278={__name:`insuranceTiers`,props:{tiers:{type:Array,required:!0},showTier:{type:Boolean,default:!1}},setup(__props){let props=__props;return(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$248,[(openBlock(!0),createElementBlock(Fragment,null,renderList(props.tiers,tier=>(openBlock(),createElementBlock(`div`,{class:`tier`,key:tier.id},[createBaseVNode(`div`,{class:normalizeClass([`tier-discount`,{isCurrent:tier.isCurrent}])},[props.showTier?(openBlock(),createElementBlock(`div`,_hoisted_2$205,` Tier `+toDisplayString(tier.id),1)):createCommentVNode(``,!0),createBaseVNode(`div`,null,toDisplayString(tier.discount*100)+`% `,1)],2)]))),128))]))}},insuranceTiers_default=__plugin_vue_export_helper_default(_sfc_main$278,[[`__scopeId`,`data-v-ccd1e875`]]),_hoisted_1$247={class:`popup-content`},_hoisted_2$204={class:`top-banner`},_hoisted_3$179={class:`top-info`},_hoisted_4$152={class:`top-info-title`},_hoisted_5$132={class:`top-info-policy-name`},_hoisted_6$113={class:`customize-coverage section`},_hoisted_7$100={class:`premium-details section`},_hoisted_8$84={class:`premium-details-content`},_hoisted_9$74={class:`premium-details-left`},_hoisted_10$64={class:`premium-details-label`},_hoisted_11$57={class:`premium-details-right`},_hoisted_12$46={key:0,class:`price-diff-container`},_hoisted_13$39={class:`premium-details-total premium-details-item`},_hoisted_14$36={class:`premium-details-left`},_hoisted_15$34={class:`driver-score-details-wrapper`},_hoisted_16$33={class:`driver-score-details`},_hoisted_17$27={class:`premium-details-right`},_hoisted_18$24={key:0,class:`price-diff-container`},_hoisted_19$21={class:`buttons`},_sfc_main$277={__name:`editPolicy`,props:{insuranceData:{type:Object,required:!0},driverScoreData:{type:Object,required:!0}},emits:[`return`],setup(__props,{emit:__emit}){let props=__props,changedCoverageOptions=ref({}),newPremiumDetails=ref({}),computedNewPremiumDiffs=computed(()=>{if(!newPremiumDetails.value?.items)return{};let diffs={};for(let key in newPremiumDetails.value.items){let newPrice=newPremiumDetails.value.items[key]?.price||0,oldPrice=props.insuranceData.currentPremiumDetails.items[key]?.price||0;diffs[key]={priceDiff:newPrice-oldPrice,newPrice,oldPrice}}return diffs}),computedTotalPriceDiff=computed(()=>newPremiumDetails.value?.totalPrice?newPremiumDetails.value.totalPrice-props.insuranceData.currentPremiumDetails.totalPrice:0),driverScoreColorClass=computed(()=>{let multiplier=props.driverScoreData?.tier?.multiplier;return multiplier?multiplier<1?`driver-score-good`:multiplier>1?`driver-score-bad`:``:``}),hasChangedCoverageOptions=computed(()=>props.insuranceData?.coverageOptionsData?props.insuranceData.coverageOptionsData.some(option=>changedCoverageOptions.value[option.key]!==option.currentValueId):!1);onMounted(()=>{props.insuranceData?.coverageOptionsData&&props.insuranceData.coverageOptionsData.forEach(option=>{changedCoverageOptions.value[option.key]=option.currentValueId})});let emit$1=__emit,closePopup=()=>{emit$1(`return`,!0)},openVehicleList=()=>{addPopup(vehicleInsuranceList_default,{insuranceData:props.insuranceData,driverScoreData:props.driverScoreData}),closePopup()},onSaveClick=()=>{Lua_default.career_modules_insurance_insurance.saveNewInsuranceCoverageOptions(props.insuranceData.id,changedCoverageOptions.value),emit$1(`return`,!0)},updatePremiumDetails=async()=>{newPremiumDetails.value=await Lua_default.career_modules_insurance_insurance.calculateInsurancePremium(props.insuranceData.id,changedCoverageOptions.value,null)},onToggleChange=(coverageOption,newValue)=>{let targetChoiceIndex=coverageOption.choices.findIndex(choice=>choice.value===newValue);targetChoiceIndex!==-1&&(changedCoverageOptions.value[coverageOption.key]=targetChoiceIndex+1,updatePremiumDetails())},onChoiceClick=(coverageOption,choice)=>{changedCoverageOptions.value[coverageOption.key]=choice.id,updatePremiumDetails()};return(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$247,[createBaseVNode(`div`,_hoisted_2$204,[createBaseVNode(`div`,_hoisted_3$179,[createBaseVNode(`div`,_hoisted_4$152,[_cache[0]||=createTextVNode(` Edit Policy: `,-1),createBaseVNode(`span`,_hoisted_5$132,toDisplayString(props.insuranceData.name),1)]),_cache[1]||=createBaseVNode(`div`,{class:`top-info-description`},` These settings apply to all vehicles under this policy. Set deductibles per vehicle by clicking "Edit Vehicles" `,-1)]),createVNode(unref(bngButton_default),{class:`edit-vehicles-button`,accent:`custom`,onClick:openVehicleList},{default:withCtx(()=>[..._cache[2]||=[createTextVNode(` Edit Vehicles `,-1)]]),_:1})]),createBaseVNode(`div`,_hoisted_6$113,[(openBlock(!0),createElementBlock(Fragment,null,renderList(props.insuranceData.coverageOptionsData,coverageOption=>(openBlock(),createBlock(unref(coverageOption_default),{key:coverageOption.name,coverageOption,changedCoverageOptions:changedCoverageOptions.value,onChoiceClick,onToggleChange},null,8,[`coverageOption`,`changedCoverageOptions`]))),128))]),createBaseVNode(`div`,_hoisted_7$100,[_cache[5]||=createBaseVNode(`div`,{class:`premium-details-header`},` Premium Breakdown `,-1),createBaseVNode(`div`,_hoisted_8$84,[(openBlock(!0),createElementBlock(Fragment,null,renderList(props.insuranceData.currentPremiumDetails.items,(detail,key)=>(openBlock(),createElementBlock(`div`,{class:`premium-details-item`,key},[createBaseVNode(`div`,_hoisted_9$74,[createBaseVNode(`div`,_hoisted_10$64,toDisplayString(detail.name),1)]),createBaseVNode(`div`,_hoisted_11$57,[computedNewPremiumDiffs.value[key]&&computedNewPremiumDiffs.value[key].priceDiff!==0?(openBlock(),createElementBlock(`div`,_hoisted_12$46,[createBaseVNode(`span`,{class:normalizeClass([`arrow`,{"green-price":computedNewPremiumDiffs.value[key].priceDiff<0,"red-price":computedNewPremiumDiffs.value[key].priceDiff>0}])},toDisplayString(computedNewPremiumDiffs.value[key].priceDiff>0?`↑`:`↓`),3),createVNode(unref(bngUnit_default),{class:normalizeClass([`price-diff`,{"green-price":computedNewPremiumDiffs.value[key].priceDiff<0,"red-price":computedNewPremiumDiffs.value[key].priceDiff>0}]),money:computedNewPremiumDiffs.value[key].priceDiff},null,8,[`class`,`money`])])):createCommentVNode(``,!0),createVNode(unref(bngUnit_default),{money:newPremiumDetails.value?.items?.[key]?.price||detail.price},null,8,[`money`])])]))),128)),createBaseVNode(`div`,_hoisted_13$39,[createBaseVNode(`div`,_hoisted_14$36,[_cache[4]||=createBaseVNode(`div`,null,` Final Premium `,-1),createBaseVNode(`div`,_hoisted_15$34,[createBaseVNode(`span`,_hoisted_16$33,[_cache[3]||=createTextVNode(` Base Premium : `,-1),createVNode(unref(bngUnit_default),{money:props.insuranceData.currentPremiumDetails.totalPrice},null,8,[`money`]),createTextVNode(` × Driver Score `+toDisplayString(props.driverScoreData.score)+` @ `,1)]),createBaseVNode(`span`,{class:normalizeClass([`driver-score`,driverScoreColorClass.value])},toDisplayString(Math.round(props.driverScoreData.tier.multiplier*100))+`% `,3)])]),createBaseVNode(`div`,_hoisted_17$27,[computedTotalPriceDiff.value===0?createCommentVNode(``,!0):(openBlock(),createElementBlock(`div`,_hoisted_18$24,[createBaseVNode(`span`,{class:normalizeClass([`arrow`,{"green-price":computedTotalPriceDiff.value<0,"red-price":computedTotalPriceDiff.value>0}])},toDisplayString(computedTotalPriceDiff.value>0?`↑`:`↓`),3),createVNode(unref(bngUnit_default),{class:normalizeClass([`price-diff`,{"green-price":computedTotalPriceDiff.value<0,"red-price":computedTotalPriceDiff.value>0}]),money:computedTotalPriceDiff.value},null,8,[`class`,`money`])])),createVNode(unref(bngUnit_default),{money:newPremiumDetails.value?.totalPriceWithDriverScore||props.insuranceData.currentPremiumDetails.totalPriceWithDriverScore},null,8,[`money`])])])])]),createBaseVNode(`div`,_hoisted_19$21,[createVNode(unref(bngButton_default),{class:`cancel-button bigger-button`,accent:`custom`,onClick:closePopup},{default:withCtx(()=>[..._cache[6]||=[createTextVNode(` Cancel `,-1)]]),_:1}),createVNode(unref(bngButton_default),{class:`save-button bigger-button`,accent:`custom`,onClick:onSaveClick,disabled:!props.insuranceData.canPayPaperworkFees||!hasChangedCoverageOptions.value},{default:withCtx(()=>[props.insuranceData.canPayPaperworkFees?(openBlock(),createElementBlock(Fragment,{key:1},[_cache[7]||=createTextVNode(` Apply for `,-1),createVNode(unref(bngUnit_default),{money:props.insuranceData.paperworkFees},null,8,[`money`])],64)):(openBlock(),createElementBlock(Fragment,{key:0},[createTextVNode(` Insufficient funds `)],64))]),_:1},8,[`disabled`])])]))}},editPolicy_default=__plugin_vue_export_helper_default(_sfc_main$277,[[`__scopeId`,`data-v-081fecf3`]]),_sfc_main$276={__name:`insurancePerkIcon`,props:{perkIconData:{type:Object,required:!0}},setup(__props){let props=__props,computedColor=computed(()=>props.perkIconData.isSignaturePerk===void 0?props.perkIconData.color:props.perkIconData.isSignaturePerk?`green`:`blue`);return(_ctx,_cache)=>withDirectives((openBlock(),createElementBlock(`div`,{class:normalizeClass({"insurance-perk-icon":!__props.perkIconData.iconOnly,[computedColor.value]:computedColor.value})},[createVNode(unref(bngIcon_default),{type:unref(icons).shieldCheckmark,class:normalizeClass({"glowing-icon":!0,[computedColor.value]:computedColor.value})},null,8,[`type`,`class`]),__props.perkIconData.iconOnly?createCommentVNode(``,!0):(openBlock(),createElementBlock(`span`,{key:0,class:normalizeClass({"small-text":!0,[computedColor.value]:computedColor.value})},toDisplayString(__props.perkIconData.smallText),3))],2)),[[unref(BngTooltip_default),__props.perkIconData.iconOnly?null:__props.perkIconData.tooltipText,`top`]])}},insurancePerkIcon_default=__plugin_vue_export_helper_default(_sfc_main$276,[[`__scopeId`,`data-v-d2b025b6`]]),_hoisted_1$246={class:`insurance-perks-container`},_hoisted_2$203={class:`left`},_hoisted_3$178={class:`insurance-perk-icon-wrapper`},_hoisted_4$151={key:1},_hoisted_5$131={class:`insurance-perk-texts`},_hoisted_6$112={class:`insurance-perk-intro`},_hoisted_7$99={key:0,class:`insurance-perk-description`},_hoisted_8$83={key:0,class:`signature-perk-wrapper`},_sfc_main$275={__name:`insurancePerks`,props:{insuranceData:Object,noDescription:Boolean},setup(__props){let props=__props,sortedPerks=computed(()=>props.insuranceData.perks?[...Array.isArray(props.insuranceData.perks)?props.insuranceData.perks:Object.values(props.insuranceData.perks)].sort((a$1,b)=>Number(b.isSignaturePerk||!1)-Number(a$1.isSignaturePerk||!1)):[]);return(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$246,[(openBlock(!0),createElementBlock(Fragment,null,renderList(sortedPerks.value,perk=>(openBlock(),createElementBlock(`div`,{key:perk.id,class:normalizeClass([`insurance-perk`,{highlighted:perk.isSignaturePerk,"no-insurance":__props.insuranceData.id===-1}])},[createBaseVNode(`div`,_hoisted_2$203,[createBaseVNode(`div`,_hoisted_3$178,[__props.insuranceData.id===-1?(openBlock(),createElementBlock(`span`,_hoisted_4$151,`-`)):(openBlock(),createBlock(insurancePerkIcon_default,{key:0,perkIconData:{iconOnly:!0,isSignaturePerk:perk.isSignaturePerk&&perk.isSignaturePerk||!1}},null,8,[`perkIconData`]))]),createBaseVNode(`div`,_hoisted_5$131,[createBaseVNode(`div`,_hoisted_6$112,toDisplayString(perk.intro),1),__props.noDescription?createCommentVNode(``,!0):(openBlock(),createElementBlock(`div`,_hoisted_7$99,toDisplayString(perk.description),1))])]),perk.isSignaturePerk?(openBlock(),createElementBlock(`div`,_hoisted_8$83,[..._cache[0]||=[createBaseVNode(`div`,{class:`signature-perk`},` SIGNATURE PERK `,-1)]])):createCommentVNode(``,!0)],2))),128))]))}},insurancePerks_default=__plugin_vue_export_helper_default(_sfc_main$275,[[`__scopeId`,`data-v-75e74910`]]),_hoisted_1$245={class:`insurance-perk-notice`},_sfc_main$274={__name:`insurancePerkNotice`,props:{perkText:{type:String,required:!0}},setup(__props){let props=__props;return(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$245,[createVNode(insurancePerkIcon_default,{perkIconData:{iconOnly:!0}}),createTextVNode(` `+toDisplayString(props.perkText),1)]))}},insurancePerkNotice_default=__plugin_vue_export_helper_default(_sfc_main$274,[[`__scopeId`,`data-v-a98b3238`]]),_hoisted_1$244={class:`popup-content`},_hoisted_2$202={class:`top-info`},_hoisted_3$177={class:`top-info-title`},_hoisted_4$150={class:`top-info-veh-name`},_hoisted_5$130={class:`top-info-value-and-insurance`},_hoisted_6$111={class:`section`},_hoisted_7$98={class:`section`},_hoisted_8$82={class:`contribution-wrapper`},_hoisted_9$73={class:`contribution-item-value`},_hoisted_10$63={key:0,class:`price-diff-container`},_hoisted_11$56={class:`contribution-item-value`},_hoisted_12$45={key:0,class:`price-diff-container`},_hoisted_13$38={class:`buttons`},_sfc_main$273={__name:`editVehicleCoverage`,props:{insuranceData:{type:Object,required:!0},vehicleData:{type:Object,required:!0}},emits:[`return`],setup(__props,{emit:__emit}){let props=__props,newPremiumPrice=ref(0),newInsurancePremiumDetails=ref({totalPriceWithDriverScore:0}),computedNewPremiumDiff=computed(()=>newPremiumPrice.value-props.vehicleData.insuranceData.currentPremiumPrice),computedNewInsurancePremiumDiff=computed(()=>newInsurancePremiumDetails.value.totalPriceWithDriverScore-props.insuranceData.currentPremiumDetails.totalPriceWithDriverScore),hasChangedCoverageOptions=computed(()=>props.vehicleData?.insuranceData?.coverageOptionsData?.currentCoverageOptionsSanitized?props.vehicleData.insuranceData.coverageOptionsData.currentCoverageOptionsSanitized.some(option=>changedCoverageOptions.value[option.key]!==option.currentValueId):!1),emit$1=__emit,closePopup=()=>{emit$1(`return`,!0)},changedCoverageOptions=ref({}),updatePremiumPrice=async()=>{newPremiumPrice.value=(await Lua_default.career_modules_insurance_insurance.calculateVehiclePremium(props.vehicleData.id,null,changedCoverageOptions.value)).cost,newInsurancePremiumDetails.value=await Lua_default.career_modules_insurance_insurance.calculateInsurancePremium(props.insuranceData.id,null,{[props.vehicleData.id]:changedCoverageOptions.value})},onChoiceClick=(coverageOption,choice)=>{changedCoverageOptions.value[coverageOption.key]=choice.id,updatePremiumPrice()},onToggleChange=(coverageOption,newValue)=>{let targetChoiceIndex=coverageOption.choices.findIndex(choice=>choice.value===newValue);targetChoiceIndex!==-1&&(changedCoverageOptions.value[coverageOption.key]=targetChoiceIndex+1),updatePremiumPrice()},onSaveClick=()=>{Lua_default.career_modules_insurance_insurance.saveNewVehicleCoverageOptions(props.vehicleData.id,changedCoverageOptions.value),emit$1(`return`,!0)},openSwitchProvider=()=>{addPopup(ChooseInsuranceMain_default,{menuMode:`change`,params:{vehicleId:props.vehicleData.id}})};return onMounted(()=>{props.vehicleData.insuranceData.coverageOptionsData.currentCoverageOptionsSanitized.forEach(option=>{changedCoverageOptions.value[option.key]=option.currentValueId}),updatePremiumPrice()}),(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$244,[createBaseVNode(`div`,_hoisted_2$202,[createBaseVNode(`div`,_hoisted_3$177,[_cache[0]||=createTextVNode(` Select Deductible: `,-1),createBaseVNode(`span`,_hoisted_4$150,toDisplayString(props.vehicleData.name),1)]),createBaseVNode(`div`,_hoisted_5$130,[_cache[1]||=createTextVNode(` Value: `,-1),createVNode(unref(bngUnit_default),{money:props.vehicleData.initialValue},null,8,[`money`]),createTextVNode(` • Policy: `+toDisplayString(props.insuranceData.name),1)]),_cache[2]||=createBaseVNode(`div`,{class:`top-info-description`},` Choose how much you'll pay out-of-pocket when repairing this vehicle. Lower deductibles cost more per km. `,-1)]),createBaseVNode(`div`,_hoisted_6$111,[_cache[3]||=createBaseVNode(`div`,null,[createBaseVNode(`div`,{class:`header title`},` Choose Your Deductible `),createBaseVNode(`div`,{class:`under-title`},` You pay this amount per repair. `)],-1),createBaseVNode(`div`,null,[(openBlock(!0),createElementBlock(Fragment,null,renderList(props.vehicleData.insuranceData.coverageOptionsData.currentCoverageOptionsSanitized,coverageOption=>(openBlock(),createBlock(unref(coverageOption_default),{class:`coverage-option`,key:coverageOption.name,coverageOption,onlyShowMainText:!0,changedCoverageOptions:changedCoverageOptions.value,dontShowName:!0,onChoiceClick,onToggleChange},null,8,[`coverageOption`,`changedCoverageOptions`]))),128))])]),createBaseVNode(`div`,_hoisted_7$98,[_cache[6]||=createBaseVNode(`div`,{class:`title`},` Policy Impact `,-1),createBaseVNode(`div`,_hoisted_8$82,[createBaseVNode(`div`,{class:normalizeClass([`contribution-item`,{green:computedNewInsurancePremiumDiff.value<0,red:computedNewInsurancePremiumDiff.value>0}])},[_cache[4]||=createBaseVNode(`div`,{class:`contribution-item-title`},` Insurance Premium `,-1),createBaseVNode(`div`,_hoisted_9$73,[createVNode(unref(bngUnit_default),{money:props.insuranceData.currentPremiumDetails.totalPriceWithDriverScore},null,8,[`money`]),computedNewInsurancePremiumDiff.value!==0&&!isNaN(computedNewInsurancePremiumDiff.value)?(openBlock(),createElementBlock(`div`,_hoisted_10$63,` → `)):createCommentVNode(``,!0),computedNewInsurancePremiumDiff.value!==0&&!isNaN(computedNewInsurancePremiumDiff.value)?(openBlock(),createBlock(unref(bngUnit_default),{key:1,money:newInsurancePremiumDetails.value.totalPriceWithDriverScore},null,8,[`money`])):createCommentVNode(``,!0)])],2),createBaseVNode(`div`,{class:normalizeClass([`contribution-item`,{green:computedNewInsurancePremiumDiff.value<0,red:computedNewInsurancePremiumDiff.value>0}])},[_cache[5]||=createBaseVNode(`div`,{class:`contribution-item-title`},` Vehicle Contribution `,-1),createBaseVNode(`div`,_hoisted_11$56,[createVNode(unref(bngUnit_default),{money:props.vehicleData.insuranceData.currentPremiumPrice},null,8,[`money`]),computedNewPremiumDiff.value!==0&&!isNaN(computedNewPremiumDiff.value)?(openBlock(),createElementBlock(`div`,_hoisted_12$45,` → `)):createCommentVNode(``,!0),computedNewPremiumDiff.value!==0&&!isNaN(computedNewPremiumDiff.value)?(openBlock(),createBlock(unref(bngUnit_default),{key:1,money:newPremiumPrice.value},null,8,[`money`])):createCommentVNode(``,!0)])],2)])]),createBaseVNode(`div`,_hoisted_13$38,[createVNode(unref(bngButton_default),{class:`gray-button bigger-button`,accent:`custom`,onClick:closePopup},{default:withCtx(()=>[..._cache[7]||=[createTextVNode(` Cancel `,-1)]]),_:1}),createVNode(unref(bngButton_default),{class:`save-button bigger-button`,accent:`custom`,onClick:onSaveClick,disabled:!props.insuranceData.canPayPaperworkFees||!hasChangedCoverageOptions.value},{default:withCtx(()=>[props.insuranceData.canPayPaperworkFees?(openBlock(),createElementBlock(Fragment,{key:1},[_cache[8]||=createTextVNode(` Apply for `,-1),createVNode(unref(bngUnit_default),{money:props.insuranceData.paperworkFees},null,8,[`money`])],64)):(openBlock(),createElementBlock(Fragment,{key:0},[createTextVNode(` Insufficient funds `)],64))]),_:1},8,[`disabled`]),createVNode(unref(bngButton_default),{class:`gray-button bigger-button`,accent:`custom`,onClick:openSwitchProvider},{default:withCtx(()=>[..._cache[9]||=[createTextVNode(` Switch Provider `,-1)]]),_:1})])]))}},editVehicleCoverage_default=__plugin_vue_export_helper_default(_sfc_main$273,[[`__scopeId`,`data-v-9f014d2d`]]),_hoisted_1$243=[`innerHTML`],_hoisted_2$201={key:2,class:`insurance-icon`},_hoisted_3$176={class:`insurance-name`},_hoisted_4$149={key:3,class:`insurance-slogan`},_sfc_main$272={__name:`insuranceIdentity`,props:{insuranceData:{type:Object,required:!0}},setup(__props){let props=__props,hasInsurance=computed(()=>svgContent.value||props.insuranceData.image),hasNoInsurance=computed(()=>props.insuranceData?.id===-1),svgContent=ref(null);return watch(()=>props.insuranceData.image,async newPath=>{if(newPath&&newPath.endsWith(`.svg`))try{let rawSvg=await getFile(`/${newPath}`);rawSvg?svgContent.value=rawSvg.replace(/]*>([\s\S]*?)<\/script>/gim,``).replace(/ on\w+="[^"]*"/g,``):svgContent.value=null}catch(e){console.warn(`Failed to load SVG inline:`,newPath,e),svgContent.value=null}else svgContent.value=null},{immediate:!0}),(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,{class:normalizeClass([`insurance-identity`,{"no-insurance":!hasInsurance.value}])},[svgContent.value?(openBlock(),createElementBlock(`div`,{key:0,class:`insurance-icon`,innerHTML:svgContent.value},null,8,_hoisted_1$243)):props.insuranceData.image?(openBlock(),createBlock(unref(bngImage_default),{key:1,class:`insurance-icon`,src:`/${props.insuranceData.image}`,alt:props.insuranceData.name},null,8,[`src`,`alt`])):(openBlock(),createElementBlock(`div`,_hoisted_2$201,[createBaseVNode(`div`,_hoisted_3$176,[createVNode(unref(bngIcon_default),{class:`insurance-no-icon`,type:unref(icons).danger},null,8,[`type`]),createTextVNode(` `+toDisplayString(hasNoInsurance.value?_ctx.$t(`ui.career.insurance.noInsurance`):props.insuranceData.name),1)])])),hasNoInsurance.value?createCommentVNode(``,!0):(openBlock(),createElementBlock(`div`,_hoisted_4$149,` "`+toDisplayString(props.insuranceData.slogan)+`" `,1))],2))}},insuranceIdentity_default=__plugin_vue_export_helper_default(_sfc_main$272,[[`__scopeId`,`data-v-689b89ea`]]),_hoisted_1$242={key:1,class:`coverage-option-name`},_hoisted_2$200={key:2,class:`choices`},_hoisted_3$175=[`onClick`],_hoisted_4$148={class:`choice-label`},_hoisted_5$129={key:0},_hoisted_6$110={key:0,class:`choice-secondary-text`},_hoisted_7$97={key:1,class:`choice-price`},_hoisted_8$81={key:3,class:`toggle-container`},_hoisted_9$72={class:`toggle-price`},_sfc_main$271={__name:`coverageOption`,props:{coverageOption:{type:Object,required:!0},changedCoverageOptions:{type:Object,required:!1,default:()=>({})},onlyShowMainText:{type:Boolean,default:!1},simpleSelect:{type:Boolean},modelValue:{type:Number,required:!1},showPerkMode:{type:String,default:`deportedLabel`},dontShowName:{type:Boolean,default:!1}},emits:[`choiceClick`,`toggleChange`,`update:modelValue`],setup(__props,{emit:__emit}){let props=__props,emit$1=__emit;watch(()=>props.coverageOption?.choices,newChoices=>{if(props.modelValue!==void 0&&props.modelValue!==null&&newChoices){let maxValidId=newChoices.length;props.modelValue>maxValidId&&emit$1(`update:modelValue`,1)}},{immediate:!0});let getSelectedValueId=()=>props.modelValue!==void 0&&props.modelValue!==null?Math.min(props.modelValue,props.coverageOption.choices.length):props.changedCoverageOptions[props.coverageOption.key],getToggleValue=coverageOption=>(props.changedCoverageOptions[coverageOption.key]??coverageOption.currentValueId)===coverageOption.choices.findIndex(choice=>choice.value===!0)+1,getTogglePrice=coverageOption=>{let selectedValueId=props.changedCoverageOptions[coverageOption.key]??coverageOption.currentValueId;return coverageOption.choices[selectedValueId-1]?.premiumInfluence||0},onToggleChange=(coverageOption,newValue)=>{emit$1(`toggleChange`,coverageOption,newValue)},onChoiceClick=(coverageOption,choice)=>{choice.disabled||(props.simpleSelect&&(coverageOption.currentValueId=choice.id),props.modelValue!==void 0&&props.modelValue!==null&&emit$1(`update:modelValue`,choice.id),emit$1(`choiceClick`,coverageOption,choice))};return(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,{class:normalizeClass([`coverage-options`,{"in-row":__props.coverageOption.choiceType===`toggle`}])},[__props.coverageOption.perkText&&__props.showPerkMode===`deportedLabel`?(openBlock(),createBlock(unref(insurancePerkNotice_default),{key:0,perkText:__props.coverageOption.perkText},null,8,[`perkText`])):createCommentVNode(``,!0),__props.dontShowName?createCommentVNode(``,!0):(openBlock(),createElementBlock(`div`,_hoisted_1$242,toDisplayString(__props.coverageOption.name),1)),__props.coverageOption.choiceType===`multiple`?(openBlock(),createElementBlock(`div`,_hoisted_2$200,[(openBlock(!0),createElementBlock(Fragment,null,renderList(__props.coverageOption.choices,choice=>(openBlock(),createElementBlock(`div`,{class:normalizeClass([`choice`,{selected:choice.id===__props.changedCoverageOptions[__props.coverageOption.key],current:choice.id===getSelectedValueId(),disabled:choice.disabled}]),key:choice,onClick:()=>onChoiceClick(__props.coverageOption,choice)},[createBaseVNode(`div`,_hoisted_4$148,toDisplayString(choice.choiceText),1),__props.onlyShowMainText?createCommentVNode(``,!0):(openBlock(),createElementBlock(`div`,_hoisted_5$129,[choice.secondaryText?(openBlock(),createElementBlock(`div`,_hoisted_6$110,toDisplayString(choice.secondaryText),1)):(openBlock(),createElementBlock(`div`,_hoisted_7$97,[createVNode(unref(bngUnit_default),{money:choice.premiumInfluence},null,8,[`money`])]))]))],10,_hoisted_3$175))),128))])):__props.coverageOption.choiceType===`toggle`?(openBlock(),createElementBlock(`div`,_hoisted_8$81,[createVNode(unref(bngSwitch_default),{class:`toggle-switch`,"model-value":getToggleValue(__props.coverageOption),onChange:_cache[0]||=newValue=>onToggleChange(__props.coverageOption,newValue)},null,8,[`model-value`]),createBaseVNode(`div`,_hoisted_9$72,[createVNode(unref(bngUnit_default),{money:getTogglePrice(__props.coverageOption)},null,8,[`money`])])])):createCommentVNode(``,!0)],2))}},coverageOption_default=__plugin_vue_export_helper_default(_sfc_main$271,[[`__scopeId`,`data-v-4921f4f0`]]),_hoisted_1$241={class:`popup-content`},_hoisted_2$199={class:`popup-header`},_hoisted_3$174={class:`top-info`},_hoisted_4$147={class:`top-info-title`},_hoisted_5$128={class:`top-info-policy-name`},_hoisted_6$109={class:`top-info-description`},_hoisted_7$96={class:`vehicle-list`},_hoisted_8$80={class:`closeButton`},_sfc_main$270={__name:`vehicleInsuranceList`,props:{insuranceData:{type:Object,required:!0},driverScoreData:{type:Object,required:!0}},emits:[`return`],setup(__props,{emit:__emit}){let props=__props,emit$1=__emit,closePopup=()=>{emit$1(`return`,!0)},openEditVehicleCoverage=vehicle=>{addPopup(editVehicleCoverage_default,{insuranceData:props.insuranceData,vehicleData:vehicle})},openEditPolicy=()=>{addPopup(editPolicy_default,{insuranceData:props.insuranceData,driverScoreData:props.driverScoreData}),closePopup()};return(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$241,[createBaseVNode(`div`,_hoisted_2$199,[createBaseVNode(`div`,_hoisted_3$174,[createBaseVNode(`div`,_hoisted_4$147,[_cache[0]||=createTextVNode(` Vehicles Insured By `,-1),createBaseVNode(`span`,_hoisted_5$128,toDisplayString(props.insuranceData.name),1)]),createBaseVNode(`div`,_hoisted_6$109,[_cache[1]||=createTextVNode(` Click any vehicle to adjust its deductible • Total Value: `,-1),createVNode(unref(bngUnit_default),{money:props.insuranceData.totalInsuranceVehsValue},null,8,[`money`])])]),createVNode(unref(bngButton_default),{class:`policy-coverage-button`,accent:`custom`,onClick:openEditPolicy},{default:withCtx(()=>[..._cache[2]||=[createTextVNode(` Policy Coverage `,-1)]]),_:1})]),createBaseVNode(`div`,_hoisted_7$96,[(openBlock(!0),createElementBlock(Fragment,null,renderList(props.insuranceData.carsInsured,(vehicle,index)=>(openBlock(),createBlock(unref(insuranceVehTile_default),{key:index,vehicle},{rightContent:withCtx(()=>[createVNode(unref(bngButton_default),{class:`edit-coverage-button bigger-button`,accent:`custom`,disabled:vehicle.needsRepair,onClick:$event=>!vehicle.needsRepair&&openEditVehicleCoverage(vehicle)},{default:withCtx(()=>[createTextVNode(toDisplayString(vehicle.needsRepair?`Edit Coverage (Needs repair)`:`Edit Coverage`),1)]),_:2},1032,[`disabled`,`onClick`])]),_:2},1032,[`vehicle`]))),128))]),createBaseVNode(`div`,_hoisted_8$80,[createVNode(unref(bngButton_default),{class:`close-button`,accent:`custom`,onClick:closePopup},{default:withCtx(()=>[..._cache[3]||=[createTextVNode(` Cancel `,-1)]]),_:1})])]))}},vehicleInsuranceList_default=__plugin_vue_export_helper_default(_sfc_main$270,[[`__scopeId`,`data-v-2bd92225`]]),_hoisted_1$240={class:`vehicle-item`},_hoisted_2$198={class:`left`},_hoisted_3$173={class:`vehicle-thumbnail-wrapper`},_hoisted_4$146=[`src`],_hoisted_5$127={class:`name-value-wrapper`},_hoisted_6$108={class:`vehicle-name`},_hoisted_7$95={class:`vehicle-value`},_hoisted_8$79={class:`right`},_sfc_main$269={__name:`insuranceVehTile`,props:{vehicle:{type:Object,required:!0}},setup(__props){return(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$240,[createBaseVNode(`div`,_hoisted_2$198,[createBaseVNode(`div`,_hoisted_3$173,[createBaseVNode(`img`,{src:__props.vehicle.thumbnail,alt:``,class:`vehicle-thumbnail`},null,8,_hoisted_4$146)]),createBaseVNode(`div`,_hoisted_5$127,[createBaseVNode(`div`,_hoisted_6$108,toDisplayString(__props.vehicle.name),1),createBaseVNode(`div`,_hoisted_7$95,[_cache[0]||=createTextVNode(`Value : `,-1),createVNode(unref(bngUnit_default),{money:__props.vehicle.initialValue},null,8,[`money`])]),renderSlot(_ctx.$slots,`extra-info`,{},void 0,!0)])]),createBaseVNode(`div`,_hoisted_8$79,[renderSlot(_ctx.$slots,`rightContent`,{},void 0,!0)])]))}},insuranceVehTile_default=__plugin_vue_export_helper_default(_sfc_main$269,[[`__scopeId`,`data-v-b4076016`]]),_hoisted_1$239={class:`popup-content`},_hoisted_2$197={key:0,class:`vehicle-list`},_hoisted_3$172={key:1,class:`no-vehicles-wrapper`},_hoisted_4$145={class:`closeButton`},_sfc_main$268={__name:`uninsuredVehicles`,props:{uninsuredData:{type:Object,required:!0}},emits:[`return`],setup(__props,{emit:__emit}){let props=__props,emit$1=__emit,closePopup=()=>{emit$1(`return`,!0)},openAddCoverage=vehicle=>{addPopup(ChooseInsuranceMain_default,{menuMode:`change`,params:{vehicleId:vehicle.id}})};return(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$239,[_cache[5]||=createBaseVNode(`div`,{class:`popup-header`},[createBaseVNode(`span`,{class:`header-title`},`Uninsured Vehicles`)],-1),_cache[6]||=createBaseVNode(`div`,{class:`warning-message`},` These vehicles have no insurance coverage. Add coverage to protect against repair costs. `,-1),props.uninsuredData.carsUninsured&&props.uninsuredData.carsUninsured.length>0?(openBlock(),createElementBlock(`div`,_hoisted_2$197,[(openBlock(!0),createElementBlock(Fragment,null,renderList(props.uninsuredData.carsUninsured,(vehicle,index)=>(openBlock(),createBlock(unref(insuranceVehTile_default),{key:index,vehicle,class:`uninsured-vehicle-item`},{"extra-info":withCtx(()=>[..._cache[0]||=[createBaseVNode(`div`,{class:`no-coverage-warning`},` No coverage - you pay full repair costs `,-1)]]),rightContent:withCtx(()=>[createVNode(unref(bngButton_default),{class:`add-coverage-button bigger-button`,accent:`custom`,onClick:$event=>openAddCoverage(vehicle)},{default:withCtx(()=>[createVNode(unref(bngIcon_default),{class:`button-icon`,type:unref(icons).shieldCheckmark},null,8,[`type`]),_cache[1]||=createTextVNode(` Add Coverage `,-1)]),_:1},8,[`onClick`])]),_:2},1032,[`vehicle`]))),128))])):(openBlock(),createElementBlock(`div`,_hoisted_3$172,[createVNode(unref(bngIcon_default),{class:`success-icon`,type:unref(icons).checkmark},null,8,[`type`]),_cache[2]||=createBaseVNode(`div`,{class:`success-title`},`All Vehicles Insured`,-1),_cache[3]||=createBaseVNode(`div`,{class:`success-message`},`You don't have any uninsured vehicles.`,-1)])),createBaseVNode(`div`,_hoisted_4$145,[createVNode(unref(bngButton_default),{class:`close-button`,accent:`custom`,onClick:closePopup},{default:withCtx(()=>[..._cache[4]||=[createTextVNode(` Back `,-1)]]),_:1})])]))}},uninsuredVehicles_default=__plugin_vue_export_helper_default(_sfc_main$268,[[`__scopeId`,`data-v-f51ead8e`]]),sharedMode=ref(null),sharedContext=ref(null);function useChooseInsurance(){let{events:events$3}=useBridge(),insurancesData=ref([]),purchaseData=ref({}),vehicleInfo=ref({}),defaultInsuranceId=ref(null),firstSelectedInsuranceId=ref(null),driverScoreData=ref({}),currentInsuranceId=ref(null),handleChooseInsuranceData=data=>{insurancesData.value=data.applicableInsurancesData,purchaseData.value=data.purchaseData,vehicleInfo.value=data.vehicleInfo,driverScoreData.value=data.driverScoreData,defaultInsuranceId.value=data.defaultInsuranceId,firstSelectedInsuranceId.value=data.defaultInsuranceId,currentInsuranceId.value=data.currentInsuranceId};function openChooseInsuranceMenu(menuMode,params){sharedMode.value=menuMode,sharedContext.value=params,Lua_default.career_modules_insurance_insurance.openChooseInsuranceScreen()}function requestDataForCurrentContext(){sharedMode.value===`purchase`&&sharedContext.value?Lua_default.career_modules_insurance_insurance.sendChooseInsuranceDataToTheUI(sharedContext.value.purchaseType,sharedContext.value.shopId,sharedContext.value.insuranceId):sharedMode.value===`change`&&sharedContext.value&&Lua_default.career_modules_insurance_insurance.sendChangeInsuranceDataToTheUI(sharedContext.value.vehicleId)}return events$3.on(`chooseInsuranceData`,handleChooseInsuranceData),onUnmounted(()=>{events$3.off(`chooseInsuranceData`,handleChooseInsuranceData)}),{openChooseInsuranceMenu,requestDataForCurrentContext,insurancesData,purchaseData,vehicleInfo,defaultInsuranceId,firstSelectedInsuranceId,driverScoreData,currentInsuranceId,mode:sharedMode,context:sharedContext}}var _hoisted_1$238={class:`popup-content`},_hoisted_2$196={class:`popup-header`},_hoisted_3$171={class:`content-wrapper`},_hoisted_4$144={class:`buttons-wrapper`},_hoisted_5$126={class:`button-container`},_sfc_main$267={__name:`ChooseInsuranceMain`,props:{menuMode:{type:String,required:!0},params:{type:Object,required:!0}},emits:[`return`],setup(__props,{emit:__emit}){useUINavBlocker().ensureNoBlock([`tab_l`,`tab_r`]);let overflowRef=ref(null),onTabNav=evt=>{evt.detail.value===1&&(console.log(`onTabNav`,evt.detail),console.log(`overflowRef`,overflowRef.value),evt.detail.name===`tab_l`&&overflowRef.value?.activatePrev(),evt.detail.name===`tab_r`&&overflowRef.value?.activateNext())},props=__props,emit$1=__emit,{units}=useBridge(),selectedInsuranceId=ref(null),selectedShelfIndex=ref(0),{insurancesData,purchaseData,defaultInsuranceId,firstSelectedInsuranceId,vehicleInfo,requestDataForCurrentContext,mode,context,driverScoreData,currentInsuranceId}=useChooseInsurance();onMounted(()=>{window.addEventListener(DOM_UI_NAVIGATION_EVENT,onTabNav),mode.value=props.menuMode,context.value=props.params,props.menuMode===`purchase`&&props.params?Lua_default.career_modules_insurance_insurance.sendChooseInsuranceDataToTheUI(props.params.purchaseType,props.params.shopId,props.params.insuranceId):props.menuMode===`change`&&props.params&&Lua_default.career_modules_insurance_insurance.sendChangeInsuranceDataToTheUI(props.params.vehicleId)}),watch(selectedShelfIndex,newIndex=>{insurancesData.value[newIndex]&&(selectedInsuranceId.value=insurancesData.value[newIndex].id)}),watch(defaultInsuranceId,defaultId=>{if(defaultId!==null){selectedInsuranceId.value=defaultId;let index=insurancesData.value.findIndex(ins=>ins.id===defaultId);index!==-1&&(selectedShelfIndex.value=index)}},{immediate:!0});let onShelfClick=(insuranceId,index)=>{selectedInsuranceId.value=insuranceId,selectedShelfIndex.value=index},buttonText=computed(()=>mode.value===`change`?selectedInsuranceId.value===-1?`Remove Coverage`:selectedInsuranceId.value===currentInsuranceId.value?`Current Provider`:`Move vehicle here`:`Select this option`),viewCostBreakdown=()=>{mode.value===`purchase`?addPopup(purchaseInsuranceDetails_default,{insuranceData:insurancesData.value[selectedShelfIndex.value],vehicleInfo:vehicleInfo.value,driverScoreData:driverScoreData.value}):addPopup(changeInsuranceDetails_default,{insuranceData:insurancesData.value[selectedShelfIndex.value],vehicleInfo:vehicleInfo.value,driverScoreData:driverScoreData.value})},continueWithInsurance=()=>{mode.value===`purchase`?(selectedInsuranceId.value!==null&&selectedInsuranceId.value!==void 0&&Lua_default.career_modules_vehicleShopping.updateInsuranceSelection(selectedInsuranceId.value),emit$1(`return`,!0)):mode.value===`change`&&(selectedInsuranceId.value&&context.value?.vehicleId&&Lua_default.career_modules_insurance_insurance.changeInvVehInsurance(context.value.vehicleId,selectedInsuranceId.value),closeLastPopups(3))},cancel=()=>{emit$1(`return`,!0)};return onUnmounted(()=>{window.removeEventListener(DOM_UI_NAVIGATION_EVENT,onTabNav),mode.value=null,context.value=null}),(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$238,[createBaseVNode(`div`,_hoisted_2$196,[createVNode(unref(bngCardHeading_default),{type:`ribbon`},{default:withCtx(()=>[createTextVNode(toDisplayString(unref(mode)===`purchase`?`Insure your `:`Switch insurance for your `)+` `+toDisplayString(unref(vehicleInfo).Name),1)]),_:1})]),createBaseVNode(`div`,_hoisted_3$171,[createVNode(unref(bngOverflowContainer_default),{ref_key:`overflowRef`,ref:overflowRef,class:`insurance-shelf`,"scroll-speed":10,"initial-index":selectedShelfIndex.value,"use-bindings-only":``,"show-arrows":``,"no-wheel":``},{default:withCtx(()=>[(openBlock(!0),createElementBlock(Fragment,null,renderList(unref(insurancesData),(insurance,index)=>(openBlock(),createBlock(unref(insuranceCard_default),{key:insurance.id,insuranceData:insurance,isSelected:selectedInsuranceId.value===insurance.id,vehicleInfo:unref(vehicleInfo),isCurrentProvider:unref(mode)===`change`&&unref(currentInsuranceId)===insurance.id,class:`insurance-card`,onClick:$event=>onShelfClick(insurance.id,index)},null,8,[`insuranceData`,`isSelected`,`vehicleInfo`,`isCurrentProvider`,`onClick`]))),128))]),_:1},8,[`initial-index`])]),createBaseVNode(`div`,_hoisted_4$144,[createBaseVNode(`div`,_hoisted_5$126,[createVNode(unref(bngButton_default),{onClick:cancel,accent:unref(ACCENTS).attention},{default:withCtx(()=>[..._cache[0]||=[createTextVNode(`Cancel`,-1)]]),_:1},8,[`accent`]),createVNode(unref(bngButton_default),{onClick:viewCostBreakdown,disabled:selectedShelfIndex.value===0||unref(mode)===`change`&&selectedInsuranceId.value===unref(currentInsuranceId),accent:unref(ACCENTS).secondary},{default:withCtx(()=>[..._cache[1]||=[createTextVNode(`View Cost Breakdown`,-1)]]),_:1},8,[`disabled`,`accent`]),createVNode(unref(bngButton_default),{disabled:!selectedInsuranceId.value||unref(mode)===`change`&&selectedInsuranceId.value===unref(currentInsuranceId),onClick:continueWithInsurance},{default:withCtx(()=>[createTextVNode(toDisplayString(buttonText.value),1)]),_:1},8,[`disabled`])])])]))}},ChooseInsuranceMain_default=__plugin_vue_export_helper_default(_sfc_main$267,[[`__scopeId`,`data-v-7bb3e442`]]),_hoisted_1$237={class:`progress-view-actions`},_hoisted_2$195={class:`progress-view-page`},_hoisted_3$170={class:`progress-view-header`},_hoisted_4$143={class:`branch-icon-assembly large`},_hoisted_5$125={key:0,class:`reward-multiplier`},_hoisted_6$107={class:`reward-multiplier-label`},_hoisted_7$94={class:`reward-multiplier-value`},_hoisted_8$78={class:`progress-view-contents`},_hoisted_9$71={class:`progress-view-description`},_hoisted_10$62={class:`progress-view-scrollable`},_sfc_main$266={__name:`ProgressView`,props:{skillInfo:{type:Object,default:null},headingText:{type:String,default:``},breadcrumbItems:{type:Array,required:!0},branchStyle:{type:Object,required:!0},showBackButton:{type:Boolean,default:!0}},emits:[`breadcrumb-click`,`breadcrumb-back`,`exit`,`skill-click`],setup(__props,{emit:__emit}){let emit$1=__emit,handleBreadcrumbClick=item=>{emit$1(`breadcrumb-click`,item)},handleBreadcrumbBack=()=>{emit$1(`breadcrumb-back`)},handleExit=()=>{emit$1(`exit`)};return(_ctx,_cache)=>withDirectives((openBlock(),createBlock(unref(layoutSingle_default),{class:`progress-view-layout`},{default:withCtx(()=>[withDirectives((openBlock(),createElementBlock(`div`,{class:`progress-view-wrapper`,style:normalizeStyle(__props.branchStyle),"bng-ui-scope":`progressView`},[createBaseVNode(`div`,_hoisted_1$237,[createVNode(unref(bngBreadcrumbs_default),{class:`progress-view-breadcrumbs`,items:__props.breadcrumbItems,limit:`5`,simple:``,"disable-last-item":``,"show-back-button":__props.showBackButton,onClick:handleBreadcrumbClick,onBack:handleBreadcrumbBack},null,8,[`items`,`show-back-button`]),createVNode(unref(careerStatus_default),{class:`progress-view-career-status`,slim:``})]),createBaseVNode(`div`,_hoisted_2$195,[createBaseVNode(`div`,_hoisted_3$170,[__props.skillInfo?(openBlock(),createElementBlock(Fragment,{key:0},[createBaseVNode(`div`,{class:normalizeClass([`header-skill`,{"is-locked":!__props.skillInfo.unlocked}]),onClick:_cache[0]||=$event=>_ctx.$emit(`skill-click`,__props.skillInfo.id)},[createBaseVNode(`div`,_hoisted_4$143,[createBaseVNode(`div`,{class:`branch-background`,style:normalizeStyle(unref(getIconBackgroundStyle)(__props.skillInfo.color))},null,4),createVNode(unref(bngIcon_default),{type:unref(icons)[__props.skillInfo.unlocked?__props.skillInfo.icon:`lockClosed`],class:`assembly-icon large`},null,8,[`type`])]),createVNode(BranchSkillProgressBar_default,{class:`main-stat-progress-bar skill-progress-bar`,skill:__props.skillInfo,showLevel:!1,mode:`with-value-label`,showLockedIcon:!0,isMainProgress:!0},null,8,[`skill`])],2),__props.skillInfo.rewardMultiplier?(openBlock(),createElementBlock(`div`,_hoisted_5$125,[createBaseVNode(`div`,_hoisted_6$107,[createVNode(unref(bngIcon_default),{type:__props.skillInfo.rewardMultiplierSourceIcon},null,8,[`type`]),_cache[1]||=createTextVNode(` Reward Multiplier: `,-1)]),createBaseVNode(`div`,_hoisted_7$94,[createVNode(unref(bngIcon_default),{type:unref(icons).beamCurrency},null,8,[`type`]),createTextVNode(` ×`+toDisplayString(__props.skillInfo.rewardMultiplier.toFixed(2)),1)])])):createCommentVNode(``,!0)],64)):(openBlock(),createBlock(unref(bngScreenHeadingV2_default),{key:1,type:`2`,class:`header-title-v2`},{default:withCtx(()=>[createTextVNode(toDisplayString(__props.headingText),1)]),_:1}))]),createBaseVNode(`div`,_hoisted_8$78,[createBaseVNode(`div`,_hoisted_9$71,[renderSlot(_ctx.$slots,`description`,{},void 0,!0)]),_cache[2]||=createBaseVNode(`div`,{class:`progress-view-divider`},null,-1),createBaseVNode(`div`,_hoisted_10$62,[renderSlot(_ctx.$slots,`default`,{},void 0,!0)])])])],4)),[[unref(BngOnUiNav_default),handleExit,`back,menu`]])]),_:3})),[[unref(BngOnUiNav_default),handleExit,`back,menu`],[unref(BngBlur_default)]])}},ProgressView_default=__plugin_vue_export_helper_default(_sfc_main$266,[[`__scopeId`,`data-v-3fa921dc`]]),_hoisted_1$236={class:`description-text`},_hoisted_2$194={key:0,class:`cards-container grid-view`},_hoisted_3$169={key:1,class:`page-progress`},_hoisted_4$142={key:2,class:`facility-rows`},_hoisted_5$124={key:3,class:`buttons-container`},_hoisted_6$106={class:`content`},_hoisted_7$93={key:0,class:`indicator`},_sfc_main$265={__name:`ProgressLanding`,props:{pathId:String,comesFromBigMap:{type:Boolean,default:!1}},setup(__props){let props=__props,landingData=ref({heading:`ui.career.landingPage.name`,description:`ui.career.landingPage.description`,branches:[],showMilestones:!0,showOrganizations:!0}),leagues=ref([]),fetchLandingData=async()=>{landingData.value={heading:`ui.career.landingPage.name`,description:`ui.career.landingPage.description`,branches:[],showMilestones:!0,showOrganizations:!0};let data=await Lua_default.career_modules_branches_landing.getLandingPageData(props.pathId);landingData.value=data,leagues.value=data.leagues||[],console.log(`data`,data),data.breadcrumbs&&(screenHeaderPath.value=data.breadcrumbs,console.log(`screenHeaderPath`,screenHeaderPath.value))},hasUnclaimedMilestones=ref(!1);onMounted(async()=>{await fetchLandingData(),Lua_default.career_modules_milestones_milestones.unclaimedMilestonesCount().then(c=>hasUnclaimedMilestones.value=c)}),onBeforeMount(()=>{Lua_default.simTimeAuthority.pushPauseRequest(`progressLanding`)}),onUnmounted(()=>{Lua_default.simTimeAuthority.popPauseRequest(`progressLanding`)}),watch(()=>props.pathId,async(newPathId,oldPathId)=>{newPathId!==oldPathId&&(await fetchLandingData(),Lua_default.career_modules_milestones_milestones.unclaimedMilestonesCount().then(c=>hasUnclaimedMilestones.value=c))});let leagueMissionClicked=mission=>{mission.canStartFromProgressScreen?(Lua_default.extensions.gameplay_missions_missionScreen.setPreselectedMissionId(mission.id),Lua_default.extensions.gameplay_missions_missionScreen.openAPMChallenges(props.pathId,mission.skill[0])):Lua_default.extensions.gameplay_missions_missionScreen.navigateToMission(mission.id)},branchStyle=computed(()=>landingData.value.skillInfo?getBranchColorStyle({color:landingData.value.skillInfo.color,accentColor:landingData.value.skillInfo.accentColor}):{"--branch-accent-color":`var(--bng-cool-gray-500-rgb)`,"--branch-color":`var(--bng-cool-gray-500-rgb)`}),pageHeading=computed(()=>landingData.value.branchHeading||landingData.value.heading),currentDescription=ref(null),pageDescription=computed(()=>currentDescription.value||landingData.value.description),BRANCHES=computed(()=>landingData.value.branches),openBranchPage=branchKey=>{let target=landingData.value.branches.find(b=>b.id===branchKey).target;console.log(`openBranchPage`,branchKey),window.bngVue.gotoGameState(`progressLanding`,{params:{pathId:branchKey}})},exit=()=>{props.pathId&&!props.comesFromBigMap?router_default.back():window.bngVue.gotoAngularState(`menu.careerPause`)},openMilestonesScreen=()=>window.bngVue.gotoGameState(`milestones`),onBranchFocus=branch=>{currentDescription.value=branch.description},onBranchBlur=()=>{currentDescription.value=null},isHalfBranch=branch=>{let hasSkills=branch.skills&&branch.skills.length>0,hasDescription=branch.shortDescription;return!hasSkills&&!hasDescription},currentSkillToShow=computed(()=>landingData.value.skillInfo||null),screenHeaderPath=ref([{label:`Career`,path:`/career`},{label:landingData.value.heading,path:`/career/${landingData.value.id}`}]),gotoHeaderItem=item=>{item.gotoPath&&(window.bngVue.gotoGameState(item.gotoPath.path,{params:item.gotoPath.props}),console.log(`gotoPath`,item.gotoPath)),item.gotoAngularState&&window.bngVue.gotoAngularState(item.gotoAngularState)},onBreadBack=()=>{gotoHeaderItem(screenHeaderPath.value[screenHeaderPath.value.length-2])};return(_ctx,_cache)=>(openBlock(),createBlock(ProgressView_default,{"skill-info":landingData.value.skillInfo,"heading-text":_ctx.$t(pageHeading.value),"breadcrumb-items":screenHeaderPath.value,"branch-style":branchStyle.value,"show-back-button":!0,onBreadcrumbClick:gotoHeaderItem,onBreadcrumbBack:onBreadBack,onExit:exit},{description:withCtx(()=>[createBaseVNode(`div`,_hoisted_1$236,toDisplayString(_ctx.$t(pageDescription.value)),1)]),default:withCtx(()=>[BRANCHES.value.length>0?(openBlock(),createElementBlock(`div`,_hoisted_2$194,[(openBlock(!0),createElementBlock(Fragment,null,renderList(BRANCHES.value,branch=>withDirectives((openBlock(),createBlock(BranchSkillCard_default,{tabindex:`1`,branchKey:branch.id,onOpenBranchPage:openBranchPage,onMouseenter:$event=>onBranchFocus(branch),onMouseleave:onBranchBlur,onFocus:$event=>onBranchFocus(branch),onBlur:onBranchBlur,"bng-nav-item":``,"display-mode":`row`,class:normalizeClass({"full-width":!isHalfBranch(branch)})},null,8,[`branchKey`,`onMouseenter`,`onFocus`,`class`])),[[unref(BngSoundClass_default),`bng_click_hover_generic`]])),256))])):createCommentVNode(``,!0),currentSkillToShow.value&¤tSkillToShow.value.hasLevels&¤tSkillToShow.value.unlockInfo&¤tSkillToShow.value.unlockInfo.length?(openBlock(),createElementBlock(`div`,_hoisted_3$169,[currentSkillToShow.value.hasUnlocks?(openBlock(),createBlock(UnlockRows_default,{key:0,class:`stat-progress-bar bng-progress-bar progress-bar`,headerLeft:_ctx.$ctx_t(currentSkillToShow.value.name),headerRight:_ctx.$ctx_t(currentSkillToShow.value.levelLabel),value:currentSkillToShow.value.value,max:currentSkillToShow.value.max,min:currentSkillToShow.value.min,maxRequiredValue:currentSkillToShow.value.maxRequiredValue,tiers:currentSkillToShow.value.unlockInfo,currentTier:currentSkillToShow.value.unlocked?currentSkillToShow.value.level:-1,unlocked:currentSkillToShow.value.unlocked,progressFillColor:currentSkillToShow.value.accentColor},null,8,[`headerLeft`,`headerRight`,`value`,`max`,`min`,`maxRequiredValue`,`tiers`,`currentTier`,`unlocked`,`progressFillColor`])):createCommentVNode(``,!0)])):createCommentVNode(``,!0),leagues.value&&leagues.value.length>0?(openBlock(),createElementBlock(`div`,_hoisted_4$142,[(openBlock(!0),createElementBlock(Fragment,null,renderList(leagues.value,league=>(openBlock(),createBlock(LeagueRow_default,{key:league.id,league,leagueMissionClicked},null,8,[`league`]))),128))])):createCommentVNode(``,!0),landingData.value.showMilestones?(openBlock(),createElementBlock(`div`,_hoisted_5$124,[withDirectives((openBlock(),createBlock(unref(bngCard_default),{"bng-nav-item":``,class:`button milestone-button`,onClick:openMilestonesScreen},{default:withCtx(()=>[createBaseVNode(`div`,_hoisted_6$106,[createVNode(unref(bngIcon_default),{class:`icon`,type:unref(icons).checkboxOn},null,8,[`type`]),_cache[0]||=createBaseVNode(`div`,{class:`label`},` Milestones `,-1),hasUnclaimedMilestones.value>0?(openBlock(),createElementBlock(`div`,_hoisted_7$93)):createCommentVNode(``,!0)])]),_:1})),[[unref(BngSoundClass_default),`bng_click_hover_generic`]])])):createCommentVNode(``,!0)]),_:1},8,[`skill-info`,`heading-text`,`breadcrumb-items`,`branch-style`]))}},ProgressLanding_default=__plugin_vue_export_helper_default(_sfc_main$265,[[`__scopeId`,`data-v-cbe0bb9d`]]),_hoisted_1$235={class:`reward-wrapper`},_hoisted_2$193={class:`card-content`},_hoisted_3$168={class:`rewards-breakdown-container padding-bottom`},_hoisted_4$141={class:`grid-wrapper`},_hoisted_5$123={class:`grid-row grid`},_hoisted_6$105={class:`label primary`},_hoisted_7$92={class:`rewards primary`},_hoisted_8$77={class:`grid-wrapper wide`},_hoisted_9$70={class:`grid`},_hoisted_10$61={class:`label secondary`},_hoisted_11$55={class:`rewards secondary`},_hoisted_12$44={class:`grid-row grid`},_hoisted_13$37={class:`rewards primary`},_hoisted_14$35={class:`padding-bottom`},_hoisted_15$33={key:0,class:`unlocks-wrapper`},__default__$4={wrapper:{fade:!0,blur:!0,style:popupContainer.transparent},position:[popupPosition.center,popupPosition.center]},_sfc_main$264=Object.assign(__default__$4,{__name:`CargoDeliveryReward`,emits:[`return`],setup(__props,{emit:__emit}){useCssVars(_ctx=>({v4c61e8a8:ANIM_DURATION_CSS})),useUINavScope(`deliveryReward`);let ANIMATION_START_DELAY=1e3,ANIMATION_DURATION=2e3,ANIM_DURATION_CSS=ANIMATION_DURATION+`ms`,showBarAnimations=ref(!1),data=storeToRefs(useGameContextStore()).deliveryRewardData,exit=()=>{window.bngVue.gotoGameState(`play`)};function stopAnimations(){showBarAnimations.value=!1}function startProgressBarAnimation(){if(data.value){showBarAnimations.value=!0;for(let[key,value]of Object.entries(data.value.summary.rewards))value.branchInfo&&(value.branchInfo.animValue=value.branchInfo.value);setTimeout(stopAnimations,ANIMATION_DURATION)}}return onBeforeMount(()=>{Lua_default.simTimeAuthority.pushPauseRequest(`cargoDeliveryReward`)}),onMounted(()=>{getUINavServiceInstance().activate(),getUINavServiceInstance().clearFilteredEvents(),showBarAnimations.value=!1,setTimeout(startProgressBarAnimation,1e3)}),onUnmounted(()=>{Lua_default.career_modules_delivery_cargoScreen.unloadCargoPopupClosed(),Lua_default.simTimeAuthority.popPauseRequest(`cargoDeliveryReward`)}),(_ctx,_cache)=>unref(data)?withDirectives((openBlock(),createBlock(unref(layoutSingle_default),{key:0,class:`layout-content-full flex-column layout-paddings layout-align-center`,"bng-ui-scope":`deliveryReward`},{default:withCtx(()=>[createBaseVNode(`div`,_hoisted_1$235,[createVNode(unref(bngCard_default),null,{buttons:withCtx(()=>[createVNode(unref(bngButton_default),{onClick:exit},{default:withCtx(()=>[createVNode(unref(bngBinding_default),{"ui-event":`ok`,deviceMask:`xinput`}),_cache[5]||=createBaseVNode(`span`,null,`Continue`,-1)]),_:1})]),default:withCtx(()=>[createVNode(unref(careerStatus_default),{class:`career-status`}),createVNode(unref(bngCardHeading_default),{type:`ribbon`},{default:withCtx(()=>[..._cache[0]||=[createTextVNode(` Delivery Complete! `,-1)]]),_:1}),createBaseVNode(`div`,_hoisted_2$193,[createBaseVNode(`div`,_hoisted_3$168,[_cache[3]||=createBaseVNode(`span`,{class:`span2-heading`},` Reward Breakdown `,-1),createBaseVNode(`div`,_hoisted_4$141,[_cache[2]||=createBaseVNode(`div`,{class:`grid-row grid`},[createBaseVNode(`div`,{class:`label primary`},`Item`),createBaseVNode(`div`,{class:`rewards primary`},`Rewards`)],-1),(openBlock(!0),createElementBlock(Fragment,null,renderList(unref(data).sortedResults,result=>(openBlock(),createElementBlock(`div`,_hoisted_5$123,[createBaseVNode(`div`,_hoisted_6$105,toDisplayString(result.label),1),createBaseVNode(`div`,_hoisted_7$92,[createVNode(RewardsPills_default,{rewards:result.rewards},null,8,[`rewards`])]),createBaseVNode(`div`,_hoisted_8$77,[(openBlock(!0),createElementBlock(Fragment,null,renderList(result.breakdown,breakdown=>(openBlock(),createElementBlock(`div`,_hoisted_9$70,[createBaseVNode(`div`,_hoisted_10$61,toDisplayString(breakdown.label),1),createBaseVNode(`div`,_hoisted_11$55,[createVNode(RewardsPills_default,{rewards:breakdown.rewards},null,8,[`rewards`])])]))),256))])]))),256)),createVNode(unref(bngDivider_default)),createBaseVNode(`div`,_hoisted_12$44,[_cache[1]||=createBaseVNode(`div`,{class:`label primary`},`Summary`,-1),createBaseVNode(`div`,_hoisted_13$37,[createVNode(RewardsPills_default,{rewards:unref(data).summary.rewards},null,8,[`rewards`])])])])]),createBaseVNode(`div`,_hoisted_14$35,[(openBlock(!0),createElementBlock(Fragment,null,renderList(unref(data).summary.rewards,reward=>(openBlock(),createElementBlock(`div`,null,[reward.branchInfo?(openBlock(),createBlock(unref(bngProgressBar_default),{key:0,class:normalizeClass({"stat-progress-bar":!0,"animate-progress":showBarAnimations.value}),headerLeft:_ctx.$ctx_t(reward.branchInfo.name),headerRight:_ctx.$ctx_t(reward.branchInfo.level),min:reward.branchInfo.max==-1?0:reward.branchInfo.min,value:reward.branchInfo.max==-1?1:reward.branchInfo.animValue,max:reward.branchInfo.max==-1?1:reward.branchInfo.max,"value-label-format":reward.branchInfo.max==-1?`Max Level Reached`:void 0},null,8,[`class`,`headerLeft`,`headerRight`,`min`,`value`,`max`,`value-label-format`])):createCommentVNode(``,!0)]))),256))]),unref(data).summary.unlocks.length?(openBlock(),createElementBlock(`div`,_hoisted_15$33,[_cache[4]||=createBaseVNode(`span`,{class:`span2-heading`},` Unlocks`,-1),(openBlock(!0),createElementBlock(Fragment,null,renderList(unref(data).summary.unlocks,unlock=>(openBlock(),createBlock(UnlockCard_default,{class:`unlock-item`,data:unlock},null,8,[`data`]))),256))])):createCommentVNode(``,!0)])]),_:1})])]),_:1})),[[unref(BngBlur_default)],[unref(BngOnUiNav_default),exit,`back,menu,ok`]]):createCommentVNode(``,!0)}}),CargoDeliveryReward_default=__plugin_vue_export_helper_default(_sfc_main$264,[[`__scopeId`,`data-v-e964374f`]]),_hoisted_1$234={key:0,class:`context`},_hoisted_2$192={key:0,class:`card-label`},_hoisted_3$167={key:1,class:`card-label`},_hoisted_4$140={class:`simple-props-wrapper`},_hoisted_5$122={key:1,class:`to-load`},_hoisted_6$104={class:`chevron-arrow`},_hoisted_7$91={class:`chevron-outer`,width:`100%`,height:`100%`,xmlns:`http://www.w3.org/2000/svg`},_hoisted_8$76={class:`chevron-inner`,viewBox:`4 2 12 60`,preserveAspectRatio:`xMaxYMid slice`},_hoisted_9$69={key:0,d:`M-11 -2H1L14 32L1 66H-11V-2Z`,fill:`rgb(var(--chevron-color))`,"fill-opacity":`var(--chevron-alpha)`,stroke:`rgb(var(--chevron-color))`,"stroke-width":`3`,"vector-effect":`non-scaling-stroke`},_hoisted_10$60={key:1,d:`M-11 -2H1L14 32L1 66H-11V-2Z`,fill:`rgb(var(--chevron-color))`,"fill-opacity":`var(--chevron-alpha)`,stroke:`var(--bng-orange-500)`,"stroke-width":`3`,"vector-effect":`non-scaling-stroke`},_hoisted_11$54={key:2},_hoisted_12$43={key:0,class:`modifiers`},_hoisted_13$36={key:1,class:`timer-value`},_hoisted_14$34={key:0,class:`orange`},_sfc_main$263={__name:`CargoCard`,props:{card:{type:Object,required:!1},hideProps:Boolean,hideModsAndTimer:Boolean,focus:String,detailed:Boolean,showButtons:{type:Boolean,default:!0},alwaysShowLoadingWrapper:Boolean,ribbon:{type:Boolean,default:!0}},emits:[`cargoHovered`,`onAmountSelectorChanged`],setup(__props,{emit:__emit}){let emit$1=__emit;function onAmountSelectorChanged(value){emit$1(`onAmountSelectorChanged`,value)}let props=__props,cargoOverviewStore=useCargoOverviewStore(),{units}=useBridge(),getCargoCardClass=card=>({cardRow:!0,"bg-available":card.isFacilityCard&&card.enabled,"bg-available-selected":card.isFacilityCard&&card.enabled&&cargoOverviewStore.selectedCargo===card,"bg-assigned":card.transientMove,"bg-assigned-selected":card.transientMove&&cargoOverviewStore.selectedCargo===card,"bg-locked":card.isFacilityCard&&!card.enabled,"bg-locked-selected":card.isFacilityCard&&!card.enabled&&cargoOverviewStore.selectedCargo===card,"bg-loaded":card.isPlayerCard&&!card.transientMove,"bg-loaded-selected":card.isPlayerCard&&!card.transientMove&&cargoOverviewStore.selectedCargo===card,"highlight-poi-selected":!!(!props.detailed&&cargoOverviewStore.highlightedCards[card.cardId]),"card-disabled":!card.enabled,"with-thumbnail":card.thumbnail}),rewardMoney=computed(()=>props.card.rewardMoney||props.card.rewardMoneyPerLiter||(props.card.loanerCut?-(props.card.loanerCut.value*100-props.card.loanerCut.value*100%1)+`%`:void 0)),hasIds=computed(()=>props.card.rewardMoney&&props.card.ids&&props.card.ids.length>0&&!props.card.materialType),isPerLiter=computed(()=>props.card.rewardMoneyPerLiter),isLoadingFacilityCard=computed(()=>props.card.transientMoveCounts>0||props.card.spawnWhenCommitingCargo||props.card._transientMaterialMoveAmount>0),context=computed(()=>props.card.enabled?props.card.isFacilityCard?`Available`:props.card.transientMoveCounts>0||props.card.spawnWhenCommitingCargo||props.card._transientMaterialMoveAmount?`Assigned`:`Loaded`:`Locked`),isMoving=computed(()=>cargoOverviewStore.cargoData.player.isMoving),chevronProp=computed(()=>{let card=props.card;if(!card.isPlayerCard){if(card.cardType===`parcelGroup`)return card.materialType?card.transientMoveCounts>0||props.alwaysShowLoadingWrapper?{class:card.transientMoveCounts==0?`amount-load no-load`:`amount-load`,valueLabel:card.slots+`L`}:void 0:card.transientMoveCounts>0||props.alwaysShowLoadingWrapper?{class:card.transientMoveCounts==0?`amount-load no-load`:`amount-load`,valueLabel:card.transientMoveCounts+` / `+card.ids.length}:void 0;if(card.cardType===`vehicleOffer`)return card.spawnWhenCommitingCargo?{class:`amount-load`,valueLabel:`Accepted`,iconType:icons.fastTravel}:void 0;if(card.cardType===`storage`)return card._transientMaterialMoveAmount>0||props.alwaysShowLoadingWrapper?{class:card._transientMaterialMoveAmount==0?`amount-load no-load`:`amount-load`,valueLabel:card._transientMaterialMoveAmount+`L / `+card.storage.storedVolume+`L`}:void 0}}),propIcons=computed(()=>{let res=[],card=props.card;if(props.detailed)return res;if(card.enabled&&card.modifiers&&card.modifiers.length)for(let mod of card.modifiers)mod.important&&res.push({type:icons[mod.icon],color:`var(--bng-orange-300)`});return card.disableReason&&card.disableReason.type===`locked`&&res.push({type:icons.lockClosed,color:`var(--bng-add-red-300)`}),res}),cargoProps=computed(()=>{let res=[],card=props.card,detailed=props.detailed,focus$1=props.focus,$tt=$translate.instant,$ctx_t=$translate.contextTranslate,hideProps=props.hideProps;if(card.isFacilityCard&&!card.enabled&&(!card.transientMoveCounts||card.transientMoveCounts<=0)&&(card.disableReason?(card.disableReason.type===`noSpace`&&res.push({iconType:icons.info,keyLabel:detailed?`No Space`:``,valueLabel:detailed?card.disableReason.label?card.disableReason.label:`Not enough space to load this.`:`No Space`,class:`full-width red`,iconColor:`var(--bng-add-red-300)`}),card.disableReason.type===`expired`&&res.push({iconType:icons.info,keyLabel:detailed?`Expired`:``,valueLabel:detailed?card.disableReason.label?card.disableReason.label:`This offer is already expired.`:`Expired`,class:`full-width `}),card.disableReason.type===`limit`&&res.push({iconType:icons.info,keyLabel:detailed?`Limit reached`:``,valueLabel:detailed?card.disableReason.label?card.disableReason.label:`You cannot deliver more cars at the same time.`:`Limit reached`,class:`full-width red`,iconColor:`var(--bng-add-red-300)`})):res.push({iconType:icons.lockClosed,keyLabel:detailed?`Locked..?`:``,valueLabel:detailed?`Not enabled but no disablereason given!`:`Locked..?`,class:`full-width`,iconColor:`var(--bng-add-red-300)`})),card.unlockInfo){let locked=card.disableReason&&card.disableReason.type==`locked`;(detailed||locked)&&res.push({iconType:icons[card.unlockInfo.icon],valueLabel:detailed?$ctx_t(card.unlockInfo.longLabel):``,keyLabel:detailed?locked?`Locked`:``:$ctx_t(card.unlockInfo.shortLabel),class:`full-width `+(locked?`red`:``),iconColor:locked?`var(--bng-add-red-300)`:``})}if(hideProps)return res;if(card.nextTasks&&card.nextTasks.length>0&&(!focus$1||focus$1===`nextTasks`||detailed))for(let task of card.nextTasks)res.push({iconType:icons[task.checked?`checkboxOn`:`checkboxOff`],keyLabel:detailed?`Next Task`:``,valueLabel:task.label,class:`full-width`});if(card.locationName&&(!focus$1||focus$1===`location`||detailed)&&res.push({iconType:icons.locationSource,keyLabel:detailed?`Location`:``,valueLabel:detailed?card.locationNameLong:card.locationName,class:`full-width`}),card.destinationName&&(!focus$1||focus$1===`destination`||detailed)&&res.push({iconType:icons.locationDestination,keyLabel:detailed?`Destination`:``,valueLabel:detailed?card.destinationNameLong:card.destinationName,class:`full-width`}),card.locations&&(!focus$1||focus$1===`destination`)&&!detailed&&res.push({iconType:icons.mapPoint,valueLabel:card.locations.length+` possible Destinations`,class:`full-width`}),card.locations&&detailed)if(card.locations.length==1)res.push({iconType:icons.locationDestination,keyLabel:`Destination`,valueLabel:card.locations[0].name,class:`full-width`});else{res.push({iconType:icons.location2,keyLabel:`Multiple Destinations`,valueLabel:`Deliver this cargo to any of the possible destinations.`,class:`full-width`});let destinationsList=[];for(let location$1 of card.locations)destinationsList.push($tt(location$1.name));destinationsList=destinationsList.map(str=>str.replace(/ /g,` `)),res.push({iconType:icons.mapPoint,keyLabel:`Possible Destinations`,valueLabel:destinationsList.join(`, `),class:`full-width`})}if(card.distance&&(!focus$1||focus$1===`distance`||detailed)&&res.push({iconType:icons.routeSimple,keyLabel:detailed?`Distance`:``,valueLabel:units.buildString(`distance`,card.distance,1),class:``}),card.vehMileage&&(!focus$1||focus$1===`vehMileage`||detailed)&&res.push({iconType:icons.odometer,keyLabel:detailed?`Mileage`:``,valueLabel:units.buildString(`distance`,card.vehMileage,1),class:``}),card.weight&&(!focus$1||focus$1===`weight`||detailed)&&res.push({iconType:icons.weight,keyLabel:detailed?`Weight`:``,valueLabel:units.buildString(`weight`,card.weight,1),class:``}),card.density&&(!focus$1||focus$1===`density`||detailed)&&res.push({iconType:icons.weight,keyLabel:detailed?`Density`:``,valueLabel:units.buildString(`weight`,card.density,2),class:``}),card.storage&&(!focus$1||focus$1===`storage`||detailed)&&res.push({iconType:icons.boxDropOff01,keyLabel:detailed?`Available Volume`:``,valueLabel:(card.storage.storedVolume+(detailed?` / `+card.storage.capacity:``)).replace(/ /g,` `),class:``}),card.slots&&(!focus$1||focus$1===`slots`||detailed)&&res.push({iconType:icons.boxDropOff01,keyLabel:detailed?`Slots`:``,valueLabel:card.slots,class:``}),card.task&&(!focus$1||focus$1===`task`||detailed)&&res.push({iconType:icons.checkboxOff,keyLabel:detailed?`Task`:``,valueLabel:card.task,class:`full-width`}),card.cardType==`loaner`&&(!focus$1||detailed)&&res.push({iconType:icons.steeringWheelSporty,keyLabel:detailed?`Loaner`:``,valueLabel:detailed?card.isFacilityCard?`This vehicle can be loaned for delivery.`:`This vehicle can be used for delivery.`:`Loaner`,class:`full-width`}),card.cardType==`loaner`&&card.loanerCut&&!focus$1&&detailed&&res.push({iconType:icons.carCoins,keyLabel:detailed?`Loaner Cut`:``,valueLabel:detailed?`Organization takes `+(card.loanerCut.value*100-card.loanerCut.value*100%1)+`% of rewards earned with this loaner.`:card.loanerCut.value*100-card.loanerCut.value*100%1+`%`,class:`full-width`}),card.organizationName&&(!focus$1||detailed)&&res.push({iconType:icons.peopleOutline,keyLabel:detailed?`Organization`:``,valueLabel:$tt(card.organizationName),class:``}),card.capacity&&card.capacity.length)for(let cap of card.capacity)res.push({iconType:icons[cap.icon],keyLabel:detailed?`Capacity`:``,valueLabel:detailed?cap.labelLong:cap.labelShort,class:``});if(detailed&&card.modifiers&&card.modifiers.length>0)for(let mod of card.modifiers)res.push({iconType:icons[mod.icon],keyLabel:mod.label,valueLabel:mod.description,class:`full-width`+(mod.important?` orange`:``),iconColor:mod.important?`var(--bng-orange-300)`:``});return res});return(_ctx,_cache)=>(openBlock(),createBlock(unref(bngCard_default),mergeProps({class:[`card-item`,getCargoCardClass(__props.card)]},!__props.detailed&&{"bng-nav-item":!0,tabindex:1},{onClick:_cache[15]||=withModifiers(()=>{},[`stop`])}),{default:withCtx(()=>[!__props.detailed&&__props.card.thumbnail?(openBlock(),createBlock(unref(aspectRatio_default),{key:0,class:`image`,ratio:`4:3`,"external-image":__props.card.thumbnail},{default:withCtx(()=>[!__props.card.enabled&&__props.card.disableReason.type==`locked`?(openBlock(),createBlock(unref(bngIcon_default),{key:0,type:unref(icons).lockClosed,class:`icon`},null,8,[`type`])):createCommentVNode(``,!0)]),_:1},8,[`external-image`])):createCommentVNode(``,!0),createBaseVNode(`div`,{class:normalizeClass({"card-content-flex":!0,"with-actions":!__props.detailed})},[createBaseVNode(`div`,{class:normalizeClass([`heading-wrapper`,{"heading-detailed":__props.detailed}])},[__props.detailed?(openBlock(),createBlock(unref(bngCardHeading_default),{key:0,type:__props.ribbon?`ribbon`:`none`,class:`card-heading`},{default:withCtx(()=>[context.value===``?createCommentVNode(``,!0):(openBlock(),createElementBlock(`span`,_hoisted_1$234,toDisplayString(context.value),1)),createBaseVNode(`div`,null,[__props.card.vehName?(openBlock(),createElementBlock(Fragment,{key:1},[createTextVNode(toDisplayString(__props.card.vehName),1)],64)):(openBlock(),createElementBlock(Fragment,{key:0},[createTextVNode(toDisplayString(__props.card.name),1)],64))])]),_:1},8,[`type`])):(openBlock(),createElementBlock(Fragment,{key:1},[__props.card.vehName?(openBlock(),createElementBlock(`div`,_hoisted_3$167,toDisplayString(__props.card.vehName),1)):(openBlock(),createElementBlock(`div`,_hoisted_2$192,toDisplayString(__props.card.name),1))],64)),createBaseVNode(`div`,{class:normalizeClass([`pill pill-blue`,{"pill-orange":isLoadingFacilityCard.value}])},[typeof rewardMoney.value==`number`?(openBlock(),createBlock(unref(bngUnit_default),{key:0,class:`reward-money`,money:rewardMoney.value},null,8,[`money`])):(openBlock(),createBlock(unref(bngPropVal_default),{key:1,class:`reward-money`,iconType:unref(icons).beamCurrency,valueLabel:rewardMoney.value},null,8,[`iconType`,`valueLabel`])),hasIds.value&&!__props.card.transientMove?(openBlock(),createBlock(unref(bngPropVal_default),{key:2,class:`amount-avail`,valueLabel:`×`+__props.card.ids.length},null,8,[`valueLabel`])):createCommentVNode(``,!0),hasIds.value&&__props.card.transientMove?(openBlock(),createBlock(unref(bngPropVal_default),{key:3,class:`amount-avail`,valueLabel:`×`+__props.card.transientMoveCounts},null,8,[`valueLabel`])):createCommentVNode(``,!0),isPerLiter.value?(openBlock(),createBlock(unref(bngPropVal_default),{key:4,class:`amount-avail`,valueLabel:`/L`})):createCommentVNode(``,!0),__props.card.materialType?(openBlock(),createBlock(unref(bngPropVal_default),{key:5,class:`amount-avail`,valueLabel:__props.card.slots+` L`},null,8,[`valueLabel`])):createCommentVNode(``,!0)],2)],2),!__props.card.showAmountSelector&&cargoProps.value.length>0&&__props.detailed?(openBlock(),createElementBlock(`div`,{key:0,class:normalizeClass({"body-grid":__props.detailed,"body-list-wrapped":!__props.detailed,"content-detailed":__props.detailed})},[(openBlock(!0),createElementBlock(Fragment,null,renderList(cargoProps.value,props$1=>(openBlock(),createBlock(unref(bngPropVal_default),mergeProps({ref_for:!0},props$1),null,16))),256))],2)):createCommentVNode(``,!0),__props.detailed&&isMoving.value?(openBlock(),createElementBlock(`div`,{key:1,class:normalizeClass([`buttons-disabled-reason`,{"disabled-load-actions":!__props.card.enabled||!__props.showButtons,"footer-detailed":__props.detailed}])},[createVNode(unref(bngPropVal_default),{class:`prop`,iconType:unref(icons).info,keyLabel:``,valueLabel:`Cannot modify cargo while any vehicle is moving.`},null,8,[`iconType`])],2)):createCommentVNode(``,!0),createBaseVNode(`div`,{class:normalizeClass([`load-actions-wrapper`,{"disabled-load-actions":!__props.card.enabled||!__props.showButtons,"footer-detailed":__props.detailed,"chevrons-bg":__props.card.transientMoveCounts>0||__props.card.spawnWhenCommitingCargo||__props.card._transientMaterialMoveAmount>0}])},[createBaseVNode(`div`,_hoisted_4$140,[__props.detailed?createCommentVNode(``,!0):(openBlock(),createElementBlock(Fragment,{key:0},[(openBlock(!0),createElementBlock(Fragment,null,renderList(propIcons.value,icon=>(openBlock(),createBlock(unref(bngIcon_default),mergeProps({class:`icon`},{ref_for:!0},icon),null,16))),256)),(openBlock(!0),createElementBlock(Fragment,null,renderList(cargoProps.value,props$1=>(openBlock(),createBlock(unref(bngPropVal_default),mergeProps({class:`prop`},{ref_for:!0},props$1),null,16))),256))],64))]),__props.card.enabled&&__props.showButtons?(openBlock(),createElementBlock(`div`,{key:0,class:normalizeClass([`load-actions-buttons`,{undetailed:!__props.detailed}])},[__props.card.cardType==`parcelGroup`?(openBlock(),createElementBlock(Fragment,{key:0},[__props.card.isFacilityCard?(openBlock(),createElementBlock(Fragment,{key:0},[__props.card.transientMoveCounts==0?createCommentVNode(``,!0):(openBlock(),createBlock(unref(bngButton_default),{key:0,class:normalizeClass(__props.detailed?``:`button-load`),accent:unref(ACCENTS).secondary,"icon-right":unref(icons).undo,label:__props.detailed?`Clear load`:``,onClick:_cache[0]||=$event=>unref(cargoOverviewStore).clearLoad(__props.card),disabled:isMoving.value,tabindex:`0`},null,8,[`class`,`accent`,`icon-right`,`label`,`disabled`])),__props.card.autoLoadLocations&&__props.card.autoLoadLocations.length==0?createCommentVNode(``,!0):(openBlock(),createBlock(unref(bngButton_default),{key:1,class:normalizeClass(__props.detailed?``:`button-load`),accent:unref(ACCENTS).secondary,"icon-right":unref(icons).wrench,label:__props.detailed?`Custom load`:``,onClick:_cache[1]||=$event=>unref(cargoOverviewStore).loadCargoCustom(__props.card),disabled:isMoving.value,tabindex:`0`},null,8,[`class`,`accent`,`icon-right`,`label`,`disabled`])),__props.card.transientMoveCounts==__props.card.ids.length||__props.card.autoLoadLocations.length==0||!__props.card.autoLoadLocations.length?createCommentVNode(``,!0):(openBlock(),createBlock(unref(bngButton_default),{key:2,class:normalizeClass(__props.detailed?``:`button-load`),accent:unref(ACCENTS).main,"icon-right":unref(icons).arrowLargeRight,label:__props.detailed?`Load all`:``,onClick:_cache[2]||=$event=>unref(cargoOverviewStore).loadCargoAuto(__props.card),disabled:isMoving.value,tabindex:`0`},null,8,[`class`,`accent`,`icon-right`,`label`,`disabled`]))],64)):(openBlock(),createElementBlock(Fragment,{key:1},[__props.card.transientMoveCounts>0?(openBlock(),createBlock(unref(bngButton_default),{key:0,class:normalizeClass(__props.detailed?``:`button-load`),accent:unref(ACCENTS).attention,"icon-right":unref(icons).undo,label:__props.detailed?`Clear Load`:``,onClick:_cache[3]||=$event=>unref(cargoOverviewStore).clearLoad(__props.card),disabled:isMoving.value,tabindex:`0`},null,8,[`class`,`accent`,`icon-right`,`label`,`disabled`])):(openBlock(),createBlock(unref(bngButton_default),{key:1,class:normalizeClass(__props.detailed?``:`button-load`),accent:unref(ACCENTS).attention,"icon-right":unref(icons).trashBin1,label:__props.detailed?`Throw Away`:``,onClick:_cache[4]||=$event=>unref(cargoOverviewStore).throwAway(__props.card),disabled:isMoving.value,tabindex:`0`},null,8,[`class`,`accent`,`icon-right`,`label`,`disabled`])),__props.card.materialType===void 0?(openBlock(),createBlock(unref(bngButton_default),{key:2,class:normalizeClass(__props.detailed?``:`button-load`),accent:unref(ACCENTS).primary,"icon-right":unref(icons).wrench,label:__props.detailed?`Custom load`:``,onClick:_cache[5]||=$event=>unref(cargoOverviewStore).loadCargoCustom(__props.card),disabled:isMoving.value,tabindex:`0`},null,8,[`class`,`accent`,`icon-right`,`label`,`disabled`])):createCommentVNode(``,!0),__props.card.materialType!==void 0&&__props.card.transientMove?(openBlock(),createBlock(unref(bngButton_default),{key:3,class:normalizeClass(__props.detailed?``:`button-load`),accent:unref(ACCENTS).primary,"icon-right":unref(icons).wrench,label:__props.detailed?`Custom Load`:``,onClick:_cache[6]||=$event=>unref(cargoOverviewStore).modifyMaterialLoad(__props.card),disabled:isMoving.value,tabindex:`0`},null,8,[`class`,`accent`,`icon-right`,`label`,`disabled`])):createCommentVNode(``,!0)],64))],64)):createCommentVNode(``,!0),__props.card.isFacilityCard?(openBlock(),createElementBlock(Fragment,{key:1},[__props.card.cardType==`storage`?(openBlock(),createBlock(unref(bngButton_default),{key:0,class:normalizeClass(__props.detailed?``:`button-load`),accent:unref(ACCENTS).main,icon:unref(icons).wrench,label:__props.detailed?`Custom load`:``,onClick:_cache[7]||=$event=>unref(cargoOverviewStore).loadStorageCustom(__props.card),disabled:isMoving.value,tabindex:`0`},null,8,[`class`,`accent`,`icon`,`label`,`disabled`])):createCommentVNode(``,!0),__props.card.cardType==`vehicleOffer`&&!__props.card.spawnWhenCommitingCargo?(openBlock(),createBlock(unref(bngButton_default),{key:1,class:normalizeClass(__props.detailed?``:`button-load`),accent:unref(ACCENTS).main,icon:unref(icons).keys1,label:__props.detailed?`Accept Job`:``,onClick:_cache[8]||=$event=>unref(cargoOverviewStore).loadOffer(__props.card),disabled:isMoving.value,tabindex:`0`},null,8,[`class`,`accent`,`icon`,`label`,`disabled`])):createCommentVNode(``,!0),__props.card.cardType==`vehicleOffer`&&__props.card.spawnWhenCommitingCargo?(openBlock(),createBlock(unref(bngButton_default),{key:2,class:normalizeClass(__props.detailed?``:`button-load`),accent:unref(ACCENTS).attention,icon:unref(icons).undo,label:__props.detailed?`Decline Job`:``,onClick:_cache[9]||=$event=>unref(cargoOverviewStore).loadOffer(__props.card),disabled:isMoving.value,tabindex:`0`},null,8,[`class`,`accent`,`icon`,`label`,`disabled`])):createCommentVNode(``,!0),__props.card.cardType==`loaner`&&!__props.card.spawnWhenCommitingCargo?(openBlock(),createBlock(unref(bngButton_default),{key:3,class:normalizeClass(__props.detailed?``:`button-load`),accent:unref(ACCENTS).main,icon:unref(icons).keys1,label:__props.detailed?`Accept Loaner`:``,onClick:_cache[10]||=$event=>unref(cargoOverviewStore).loadLoaner(__props.card),disabled:isMoving.value,tabindex:`0`},null,8,[`class`,`accent`,`icon`,`label`,`disabled`])):createCommentVNode(``,!0),__props.card.cardType==`loaner`&&__props.card.spawnWhenCommitingCargo?(openBlock(),createBlock(unref(bngButton_default),{key:4,class:normalizeClass(__props.detailed?``:`button-load`),accent:unref(ACCENTS).attention,icon:unref(icons).undo,label:__props.detailed?`Decline Loaner`:``,onClick:_cache[11]||=$event=>unref(cargoOverviewStore).loadLoaner(__props.card),disabled:isMoving.value,tabindex:`0`},null,8,[`class`,`accent`,`icon`,`label`,`disabled`])):createCommentVNode(``,!0)],64)):(openBlock(),createElementBlock(Fragment,{key:2},[__props.card.cardType==`vehicleOffer`&&!__props.card.spawnWhenCommitingCargo?(openBlock(),createBlock(unref(bngButton_default),{key:0,class:normalizeClass(__props.detailed?``:`button-load`),accent:unref(ACCENTS).attention,icon:unref(icons).trashBin1,label:__props.detailed?`Abandon Job`:``,onClick:_cache[12]||=$event=>unref(cargoOverviewStore).abandonOffer(__props.card),disabled:isMoving.value,tabindex:`0`},null,8,[`class`,`accent`,`icon`,`label`,`disabled`])):createCommentVNode(``,!0),__props.card.cardType==`loaner`&&__props.card.isSpawnedLoaner?(openBlock(),createBlock(unref(bngButton_default),{key:1,class:normalizeClass(__props.detailed?``:`button-load`),accent:unref(ACCENTS).attention,icon:unref(icons).trashBin1,label:__props.detailed?`Return Loaner`:``,onClick:_cache[13]||=$event=>unref(cargoOverviewStore).returnLoaner(__props.card.id),disabled:isMoving.value,tabindex:`0`},null,8,[`class`,`accent`,`icon`,`label`,`disabled`])):createCommentVNode(``,!0)],64))],2)):createCommentVNode(``,!0),chevronProp.value?(openBlock(),createElementBlock(`div`,_hoisted_5$122,[createVNode(unref(bngPropVal_default),mergeProps({class:`amount-load`},chevronProp.value),null,16),createBaseVNode(`div`,_hoisted_6$104,[(openBlock(),createElementBlock(`svg`,_hoisted_7$91,[(openBlock(),createElementBlock(`svg`,_hoisted_8$76,[__props.card.transientMoveCounts===0?(openBlock(),createElementBlock(`path`,_hoisted_9$69)):(openBlock(),createElementBlock(`path`,_hoisted_10$60))]))]))])])):createCommentVNode(``,!0)],2),__props.card.showAmountSelector?(openBlock(),createElementBlock(`div`,_hoisted_11$54,[createTextVNode(` Selected Amount: `+toDisplayString(__props.card.amountSelector)+` `,1),createVNode(unref(bngSlider_default),{class:`slider`,min:0,max:__props.card.maxCount,step:1,modelValue:__props.card.amountSelector,"onUpdate:modelValue":_cache[14]||=$event=>__props.card.amountSelector=$event,onValueChanged:onAmountSelectorChanged},null,8,[`max`,`modelValue`])])):createCommentVNode(``,!0),createBaseVNode(`div`,{class:normalizeClass([`footer-grid`,{"footer-detailed":__props.detailed}])},[__props.detailed?(openBlock(),createElementBlock(Fragment,{key:0},[(__props.focus===`none`||!__props.focus)&&!__props.hideModsAndTimer?(openBlock(),createElementBlock(`div`,_hoisted_12$43,[__props.detailed?createCommentVNode(``,!0):(openBlock(!0),createElementBlock(Fragment,{key:0},renderList(__props.card.modifiers,mod=>(openBlock(),createBlock(unref(bngIcon_default),{type:unref(icons)[mod.icon]},null,8,[`type`]))),256))])):createCommentVNode(``,!0),__props.card.remainingTime&&(__props.focus===`none`||!__props.focus)&&!__props.hideModsAndTimer?(openBlock(),createElementBlock(`div`,_hoisted_13$36,[__props.card.remainingTime.type===`preLoad`?(openBlock(),createElementBlock(`div`,_hoisted_14$34,`Time for delivery: `+toDisplayString(unref(formatTime)(__props.card.remainingTime.time,2)),1)):createCommentVNode(``,!0),__props.card.remainingTime.type===`untilDelayed`?(openBlock(),createElementBlock(Fragment,{key:1},[createTextVNode(` Time until delivery is Delayed: `+toDisplayString(unref(formatTime)(__props.card.remainingTime.time,2)),1)],64)):createCommentVNode(``,!0),__props.card.remainingTime.type===`untilLate`?(openBlock(),createElementBlock(Fragment,{key:2},[createTextVNode(` Time until delivery is Late: `+toDisplayString(unref(formatTime)(__props.card.remainingTime.time,2)),1)],64)):createCommentVNode(``,!0),__props.card.remainingTime.type===`late`?(openBlock(),createElementBlock(Fragment,{key:3},[createTextVNode(` Delivery is late `)],64)):createCommentVNode(``,!0)])):createCommentVNode(``,!0)],64)):createCommentVNode(``,!0),__props.card.remainingTime&&__props.card.remainingTime.percent&&__props.card.isPlayerCard?(openBlock(),createElementBlock(`div`,{key:1,class:normalizeClass([`timer-progress-bar`,{slim:!__props.detailed}])},[createBaseVNode(`div`,{class:`progress-bar-fill`,style:normalizeStyle({width:__props.card.remainingTime.percent*100+`%`})},null,4)],2)):createCommentVNode(``,!0)],2)],2)]),_:1},16,[`class`]))}},CargoCard_default=__plugin_vue_export_helper_default(_sfc_main$263,[[`__scopeId`,`data-v-bafe8e5e`]]),_hoisted_1$233={class:`info-container`},_hoisted_2$191={key:0,class:`header`},_hoisted_3$166={key:0,class:`label`},_hoisted_4$139={class:`props`},_hoisted_5$121={key:4,class:`prop pill`},_sfc_main$262={__name:`CargoInfo`,props:{label:String,fillInfo:Object,meta:Object},setup(__props){let{units}=useBridge(),props=__props;return(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$233,[__props.meta.type===`hidden`?createCommentVNode(``,!0):(openBlock(),createElementBlock(`div`,_hoisted_2$191,[__props.label?(openBlock(),createElementBlock(`div`,_hoisted_3$166,[__props.meta.type==`task`?(openBlock(),createBlock(unref(bngIcon_default),{key:0,class:`icon`,type:unref(icons).checkboxOff},null,8,[`type`])):createCommentVNode(``,!0),__props.label?(openBlock(),createElementBlock(Fragment,{key:1},[createTextVNode(toDisplayString(_ctx.$tt(__props.label)),1)],64)):createCommentVNode(``,!0)])):createCommentVNode(``,!0),createBaseVNode(`div`,_hoisted_4$139,[__props.meta.type==`container`||__props.meta.type==`totalStorage`?(openBlock(),createBlock(unref(bngPropVal_default),{key:0,iconType:unref(icons)[__props.meta.icon],valueLabel:__props.meta.usedCargoSlots+` / `+__props.meta.totalCargoSlots},null,8,[`iconType`,`valueLabel`])):createCommentVNode(``,!0),__props.meta.type==`location`?(openBlock(),createBlock(unref(bngPropVal_default),{key:1,iconType:unref(icons).mapPoint,valueLabel:unref(units).buildString(`distance`,__props.meta.distance,1),style:{"--icon-size":`1.25em`}},null,8,[`iconType`,`valueLabel`])):createCommentVNode(``,!0),__props.meta.type==`trash`?(openBlock(),createBlock(unref(bngIcon_default),{key:2,class:`icon`,type:unref(icons).trashBin1},null,8,[`type`])):createCommentVNode(``,!0),props&&props.length?(openBlock(!0),createElementBlock(Fragment,{key:3},renderList(props,prop=>(openBlock(),createBlock(unref(bngPropVal_default),{iconType:unref(icons)[prop.icon],valueLabel:prop.label},null,8,[`iconType`,`valueLabel`]))),256)):createCommentVNode(``,!0),__props.fillInfo?(openBlock(),createElementBlock(`div`,_hoisted_5$121,[createVNode(unref(bngPropVal_default),{iconType:unref(icons)[__props.fillInfo.icon],valueLabel:__props.fillInfo.usedSlots+` / `+__props.fillInfo.availableSlots},null,8,[`iconType`,`valueLabel`])])):createCommentVNode(``,!0)]),__props.meta.fillPercent||__props.meta.fillPercent==0?(openBlock(),createElementBlock(`div`,{key:1,class:normalizeClass([`progress-bar`,{trash:__props.meta.type==`trash`}])},[__props.meta.fillPercentHighlight>0?(openBlock(),createElementBlock(`div`,{key:0,class:`progress-bar-fill highlight`,style:normalizeStyle({width:`${__props.meta.fillPercentHighlight*100}%`})},null,4)):createCommentVNode(``,!0),createBaseVNode(`div`,{class:`progress-bar-fill`,style:normalizeStyle({width:`${__props.meta.fillPercent*100}%`})},null,4)],2)):createCommentVNode(``,!0)]))]))}},CargoInfo_default=__plugin_vue_export_helper_default(_sfc_main$262,[[`__scopeId`,`data-v-ba3be877`]]),_hoisted_1$232={class:`group`},_hoisted_2$190={class:`cards`},_sfc_main$261={__name:`CardGroup`,props:{label:String,fillInfo:Object,meta:Object},setup(__props){return(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$232,[createVNode(CargoInfo_default,{label:__props.label,"fill-info":__props.fillInfo,meta:__props.meta},null,8,[`label`,`fill-info`,`meta`]),createBaseVNode(`div`,_hoisted_2$190,[renderSlot(_ctx.$slots,`default`,{},void 0,!0)])]))}},CardGroup_default=__plugin_vue_export_helper_default(_sfc_main$261,[[`__scopeId`,`data-v-f21d8701`]]),_hoisted_1$231={class:`customload-wrapper`,"bng-ui-scope":`cargoLoadPopup`},_hoisted_2$189={class:`card-container`},_hoisted_3$165={class:`content target-grid`},_hoisted_4$138={key:0,class:`target-tile`},_hoisted_5$120={class:`loading-controls amount-load`},_hoisted_6$103={class:`amount`},_hoisted_7$90={class:`chevron-arrow`},_hoisted_8$75={class:`chevron-outer`,width:`100%`,height:`100%`,xmlns:`http://www.w3.org/2000/svg`},_hoisted_9$68={class:`chevron-inner`,viewBox:`4 2 12 60`,preserveAspectRatio:`xMaxYMid slice`},_hoisted_10$59={key:0,d:`M-11 -2H1L14 32L1 66H-11V-2Z`,fill:`rgb(var(--chevron-color))`,"fill-opacity":`var(--chevron-alpha)`,stroke:`rgb(var(--chevron-color))`,"stroke-width":`3`,"vector-effect":`non-scaling-stroke`},_hoisted_11$53={key:1,d:`M-11 -2H1L14 32L1 66H-11V-2Z`,fill:`rgb(var(--chevron-color))`,"fill-opacity":`var(--chevron-alpha)`,stroke:`var(--bng-orange-500)`,"stroke-width":`3`,"vector-effect":`non-scaling-stroke`},_hoisted_12$42={key:1,class:`target-tile trash`},_hoisted_13$35={class:`loading-controls amount-load`},_hoisted_14$33={class:`amount`},_hoisted_15$32={class:`chevron-arrow`},_hoisted_16$32={class:`chevron-outer`,width:`100%`,height:`100%`,xmlns:`http://www.w3.org/2000/svg`},_hoisted_17$26={class:`chevron-inner`,viewBox:`4 2 12 60`,preserveAspectRatio:`xMaxYMid slice`},_hoisted_18$23={key:0,d:`M-11 -2H1L14 32L1 66H-11V-2Z`,fill:`rgb(var(--chevron-color))`,"fill-opacity":`var(--chevron-alpha)`,stroke:`rgb(var(--chevron-color))`,"stroke-width":`3`,"vector-effect":`non-scaling-stroke`},_hoisted_19$20={key:1,d:`M-11 -2H1L14 32L1 66H-11V-2Z`,fill:`rgb(var(--chevron-color))`,"fill-opacity":`var(--chevron-alpha)`,stroke:`var(--bng-add-red-500)`,"stroke-width":`3`,"vector-effect":`non-scaling-stroke`},_hoisted_20$17={class:`buttons content`},__default__$3={wrapper:{fade:!0,blur:!0,style:popupContainer.default},position:[popupPosition.center,popupPosition.center]},_sfc_main$260=Object.assign(__default__$3,{__name:`CargoLoadPopup`,props:{cargo:Object,storageData:Object,throwAway:Boolean},emits:[`return`],setup(__props,{emit:__emit}){let cargoOverviewStore=useCargoOverviewStore(),{events:events$3}=useBridge(),{units}=useBridge();useUINavScope(`cargoLoadPopup`);let emit$1=__emit,props=__props,isFacilityCard=ref(!1),vehicleFilterModel=ref([]),vehicleFilterOptions=ref([]),vehicleFilterChanged=function(filter){for(let target of targetLocations.value)target.hidden=target.containerVehicleInfo&&!filter.includes(target.containerVehicleInfo.vehId)},originalTransientMoveCounts=0,original_transientMaterialMoveAmount=0,card=ref({});ref(0);let throwAwayValue=ref(0),trashMeta=ref({}),loadingName=ref(``),slotsPerItem=ref(0),weightPerItem=ref(0),moneyRewardPerItem=ref(0),targetLocations=ref({}),less=function(target){target?(target.loadSliderValue=Math.max(0,target.loadSliderValue-1),updateSliderAmounts(target)):(throwAwayValue.value=Math.max(0,throwAwayValue.value-1),updateThrowAwayAmount())},more=function(target){target?(target.loadSliderValue=Math.min(target.loadSliderMax,target.loadSliderValue+1),updateSliderAmounts(target)):(throwAwayValue.value=Math.min(totalAvailableAmount.value,throwAwayValue.value+1),updateThrowAwayAmount())},acceptClickHandler=()=>{let loadIdx=0;if(props.cargo)for(let id of props.cargo.ids)Lua_default.career_modules_delivery_cargoScreen.clearTransientMoveForCargo(id);if(props.storageData&&Lua_default.career_modules_delivery_cargoScreen.clearTransientMovesForStorage(props.storageData.material.id),!props.throwAway)for(let target of targetLocations.value){if(props.cargo)for(let i=0;i{isFacilityCard.value&&(card.value.transientMoveCounts=originalTransientMoveCounts,card.value._transientMaterialMoveAmount=0),emit$1(`return`,!0)},totalAvailableAmount=ref(0),loadedAmount=ref(0),updateSliderAmounts=changedItem=>{loadedAmount.value=0;for(let target of targetLocations.value)target.maxAmount&&(loadedAmount.value+=target.loadSliderValue);let tooMuch=loadedAmount.value-totalAvailableAmount.value;if(tooMuch>0){for(let target of targetLocations.value)if(target.maxAmount&&target!==changedItem){let before=target.loadSliderValue;target.loadSliderValue=Math.max(0,target.loadSliderValue-tooMuch);let diff=target.loadSliderValue-before;tooMuch+=diff}loadedAmount.value=totalAvailableAmount.value}for(let target of targetLocations.value)target.meta.usedCargoSlots=target.usedCargoSlots+target.loadSliderValue*slotsPerItem.value,target.meta.fillPercentHighlight=target.meta.usedCargoSlots/target.meta.totalCargoSlots;isFacilityCard.value&&(throwAwayValue.value=totalAvailableAmount.value-loadedAmount.value,card.value.transientMoveCounts=loadedAmount.value,card.value._transientMaterialMoveAmount=loadedAmount.value,trashMeta.value.fillPercent=throwAwayValue.value/totalAvailableAmount.value)},updateThrowAwayAmount=()=>{loadedAmount.value=0;for(let target of targetLocations.value)target.maxAmount&&(loadedAmount.value+=target.loadSliderValue);let tooMuch=loadedAmount.value-totalAvailableAmount.value+throwAwayValue.value;for(let target of targetLocations.value){if(target.maxAmount){let before=target.loadSliderValue;target.loadSliderValue=Math.min(target.loadSliderMax,Math.max(0,target.loadSliderValue-tooMuch));let diff=target.loadSliderValue-before;tooMuch+=diff}loadedAmount.value=totalAvailableAmount.value}updateSliderAmounts()},splittable=ref(!1);return onMounted(()=>{if(getUINavServiceInstance().activate(),getUINavServiceInstance().clearFilteredEvents(),props.cargo){if(loadingName.value=props.cargo.name,slotsPerItem.value=props.cargo.slots,weightPerItem.value=props.cargo.weight,moneyRewardPerItem.value=props.cargo.rewardMoney,targetLocations.value=props.cargo.targetLocations,totalAvailableAmount.value=props.cargo.ids.length,props.cargo.splittable){splittable.value=!0,totalAvailableAmount.value=props.cargo.slots,slotsPerItem.value=1;for(let target of targetLocations.value)target.maxAmount=target.totalCargoSlots-target.usedCargoSlots}card.value=props.cargo,isFacilityCard.value=card.value.isFacilityCard,originalTransientMoveCounts=card.value.transientMoveCounts}props.storageData&&(console.log(props.storageData),loadingName.value=props.storageData.material.name,slotsPerItem.value=1,weightPerItem.value=props.storageData.material.density,moneyRewardPerItem.value=1,targetLocations.value=props.storageData.targetLocations,totalAvailableAmount.value=props.storageData.storage.storedVolume,card.value=props.storageData,isFacilityCard.value=card.value.isFacilityCard),targetLocations.value.length||(targetLocations.value=[]);for(let target of targetLocations.value)target.loadSliderValue=ref(target.selectedAmount),target.loadSliderMax=ref(Math.min(target.maxAmount,totalAvailableAmount.value)),target.meta={type:`container`,usedCargoSlots:target.usedCargoSlots,totalCargoSlots:target.totalCargoSlots,icon:`cardboardBox`,fillPercent:target.usedCargoSlots/target.totalCargoSlots};updateSliderAmounts();let vehicles={};for(let target of targetLocations.value)target.containerVehicleInfo&&(vehicles[target.containerVehicleInfo.vehId]=target.containerVehicleInfo);for(let vehId in vehicleFilterOptions.value=[],vehicles){let veh=vehicles[vehId];vehicleFilterOptions.value.push({value:veh.vehId,label:veh.vehName})}for(let vehId in vehicleFilterOptions.value.sort((a$1,b)=>a$1.name{window.bngVue.getCurrentRoute().name==`unknown`&&getUINavServiceInstance().setFilteredEventsAllExcept(UI_EVENTS.menu,UI_EVENTS.pause,UI_EVENTS.center_cam)}),(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$231,[createVNode(unref(bngCard_default),null,{default:withCtx(()=>[__props.throwAway?(openBlock(),createBlock(unref(bngCardHeading_default),{key:1,type:`ribbon`},{default:withCtx(()=>[createTextVNode(` Throwing away `+toDisplayString(loadingName.value),1)]),_:1})):(openBlock(),createBlock(unref(bngCardHeading_default),{key:0,type:`ribbon`},{default:withCtx(()=>[..._cache[4]||=[createTextVNode(`Custom Loading`,-1)]]),_:1})),createBaseVNode(`div`,_hoisted_2$189,[createVNode(CargoCard_default,{ribbon:!1,card:card.value,hideProps:!1,hideModsAndTimer:!0,showButtons:!1,detailed:!0,alwaysShowLoadingWrapper:isFacilityCard.value},null,8,[`card`,`alwaysShowLoadingWrapper`])]),_ctx.vehicles&&_ctx.vehicles.length>1?(openBlock(),createElementBlock(Fragment,{key:2},[_cache[5]||=createBaseVNode(`span`,null,`Vehicles`,-1),__props.throwAway?createCommentVNode(``,!0):(openBlock(),createBlock(unref(bngPillFilters_default),{key:0,modelValue:vehicleFilterModel.value,"onUpdate:modelValue":_cache[0]||=$event=>vehicleFilterModel.value=$event,selectMany:``,options:vehicleFilterOptions.value,showCheckIcon:!1,onValueChanged:vehicleFilterChanged},null,8,[`modelValue`,`options`]))],64)):createCommentVNode(``,!0),createBaseVNode(`div`,_hoisted_3$165,[targetLocations.value&&!__props.throwAway?(openBlock(!0),createElementBlock(Fragment,{key:0},renderList(targetLocations.value,(target,targetIndex)=>(openBlock(),createElementBlock(Fragment,null,[target.hidden?createCommentVNode(``,!0):(openBlock(),createElementBlock(`div`,_hoisted_4$138,[createVNode(CardGroup_default,{label:target.label,meta:target.meta},{default:withCtx(()=>[createBaseVNode(`div`,{class:normalizeClass([`to-load`,{"none-assigned":target.loadSliderValue==0}])},[createBaseVNode(`div`,_hoisted_5$120,[createVNode(unref(bngButton_default),{class:`less`,iconLeft:unref(icons).minus,accent:`text`,onClick:$event=>less(target)},null,8,[`iconLeft`,`onClick`]),createVNode(unref(bngSlider_default),{"bng-no-nav":``,class:`slider`,min:0,max:target.loadSliderMax,step:1,modelValue:target.loadSliderValue,"onUpdate:modelValue":$event=>target.loadSliderValue=$event,onValueChanged:$event=>updateSliderAmounts(target)},null,8,[`max`,`modelValue`,`onUpdate:modelValue`,`onValueChanged`]),createVNode(unref(bngButton_default),{class:`more`,iconLeft:unref(icons).plus,accent:`text`,onClick:$event=>more(target)},null,8,[`iconLeft`,`onClick`]),createBaseVNode(`div`,_hoisted_6$103,`×`+toDisplayString(target.loadSliderValue),1)]),createBaseVNode(`div`,_hoisted_7$90,[(openBlock(),createElementBlock(`svg`,_hoisted_8$75,[(openBlock(),createElementBlock(`svg`,_hoisted_9$68,[target.loadSliderValue===0?(openBlock(),createElementBlock(`path`,_hoisted_10$59)):(openBlock(),createElementBlock(`path`,_hoisted_11$53))]))]))])],2)]),_:2},1032,[`label`,`meta`])]))],64))),256)):createCommentVNode(``,!0),__props.cargo&&__props.cargo.throwAwayInfo&&unref(totalAvailableAmount)?(openBlock(),createElementBlock(`div`,_hoisted_12$42,[createVNode(CardGroup_default,{label:`Trash`,meta:trashMeta.value},{default:withCtx(()=>[createBaseVNode(`div`,{class:normalizeClass([`to-load`,{"none-assigned":throwAwayValue.value==0}])},[createBaseVNode(`div`,_hoisted_13$35,[createVNode(unref(bngButton_default),{class:`less`,iconLeft:unref(icons).minus,accent:`text`,onClick:_cache[1]||=$event=>less()},null,8,[`iconLeft`]),createVNode(unref(bngSlider_default),{"bng-no-nav":``,class:`slider`,min:0,max:unref(totalAvailableAmount),step:1,modelValue:throwAwayValue.value,"onUpdate:modelValue":_cache[2]||=$event=>throwAwayValue.value=$event,onValueChanged:updateThrowAwayAmount},null,8,[`max`,`modelValue`]),createVNode(unref(bngButton_default),{class:`more`,iconLeft:unref(icons).plus,accent:`text`,onClick:_cache[3]||=$event=>more()},null,8,[`iconLeft`]),createBaseVNode(`div`,_hoisted_14$33,`×`+toDisplayString(throwAwayValue.value),1)]),createBaseVNode(`div`,_hoisted_15$32,[(openBlock(),createElementBlock(`svg`,_hoisted_16$32,[(openBlock(),createElementBlock(`svg`,_hoisted_17$26,[throwAwayValue.value===0?(openBlock(),createElementBlock(`path`,_hoisted_18$23)):(openBlock(),createElementBlock(`path`,_hoisted_19$20))]))]))])],2)]),_:1},8,[`meta`])])):createCommentVNode(``,!0)]),createBaseVNode(`div`,_hoisted_20$17,[withDirectives(createVNode(unref(bngButton_default),{class:`button`,label:`Cancel`,accent:`secondary`,onClick:cancelClickHandler},null,512),[[unref(BngOnUiNav_default),void 0,`back,menu`,{asMouse:!0}]]),__props.cargo&&__props.cargo.throwAwayInfo&&throwAwayValue.value>0?withDirectives((openBlock(),createBlock(unref(bngButton_default),{key:0,class:`button`,accent:`attention`,onClick:acceptClickHandler},{default:withCtx(()=>[createTextVNode(toDisplayString(__props.throwAway?`Throw Away`:`Accept`)+` (`,1),createVNode(unref(bngUnit_default),{money:-__props.cargo.throwAwayInfo.penalty*throwAwayValue.value},null,8,[`money`]),_cache[6]||=createTextVNode(`) `,-1)]),_:1})),[[unref(BngFocusIf_default),!0],[unref(BngOnUiNav_default),void 0,`back,menu`,{asMouse:!0}]]):withDirectives((openBlock(),createBlock(unref(bngButton_default),{key:1,class:`button`,label:`Accept`,accent:`main`,onClick:acceptClickHandler},null,512)),[[unref(BngFocusIf_default),!0],[unref(BngOnUiNav_default),void 0,`back,menu`,{asMouse:!0}]])])]),_:1})]))}}),CargoLoadPopup_default=__plugin_vue_export_helper_default(_sfc_main$260,[[`__scopeId`,`data-v-0d30652e`]]),_hoisted_1$230={class:`settings-wrapper`,"bng-ui-scope":`cargoScreenSettings`},_hoisted_2$188={class:`cardContent`},_hoisted_3$164={class:`content`},_hoisted_4$137={class:`acceptButton`},__default__$2={wrapper:{fade:!0,blur:!0,style:popupContainer.default},position:[popupPosition.center,popupPosition.center]},_sfc_main$259=Object.assign(__default__$2,{__name:`CargoScreenSettings`,emits:[`return`],setup(__props,{emit:__emit}){useUINavScope(`cargoScreenSettings`);let emit$1=__emit,cargoOverviewStore=useCargoOverviewStore();ref();let facilityGroupingItems=[{label:`Item one`,value:1},{label:`Item two`,value:2},{label:`Item three`,value:3},{label:`Item four`,value:4},{label:`Item five`,value:5},{label:`Item six`,value:6},{label:`Item seven`,value:7},{label:`Item eight`,value:8},{label:`Item nine`,value:9},{label:`Item ten`,value:10},{label:`Item eleven`,value:11},{label:`Item twelve`,value:12},{label:`Item thirteen`,value:13},{label:`Item fourteen`,value:14},{label:`Item fifteen`,value:15},{label:`Item sixteen`,value:16},{label:`Item seventeen`,value:17},{label:`Item eighteen`,value:18},{label:`Item nineteen`,value:19},{label:`Item twenty`,value:20}];ref(),ref(),ref();let setFacilityGroupKey=key=>{cargoOverviewStore.facilityGroupingKey=key},setFacilitySortKey=key=>{cargoOverviewStore.facilitySortingKey=key},setPlayerGroupKey=key=>{cargoOverviewStore.playerGroupingKey=key},setPlayerSortKey=key=>{cargoOverviewStore.playerSortingKey=key};onMounted(()=>{console.log(facilityGroupingItems)});let acceptClickHandler=()=>{emit$1(`return`,!0)};return(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$230,[createVNode(unref(bngCard_default),null,{default:withCtx(()=>[createVNode(unref(bngCardHeading_default),{type:`ribbon`},{default:withCtx(()=>[..._cache[1]||=[createTextVNode(`Settings`,-1)]]),_:1}),createVNode(unref(bngCardHeading_default),null,{default:withCtx(()=>[..._cache[2]||=[createTextVNode(`Facility Display`,-1)]]),_:1}),createBaseVNode(`div`,_hoisted_2$188,[createBaseVNode(`div`,null,[_cache[3]||=createTextVNode(` Group By: `,-1),(openBlock(!0),createElementBlock(Fragment,null,renderList(unref(cargoOverviewStore).selectedFilter.groupings,gKey=>(openBlock(),createBlock(unref(bngButton_default),{onClick:$event=>setFacilityGroupKey(gKey)},{default:withCtx(()=>[createTextVNode(toDisplayString(unref(cargoOverviewStore).cargoData.facilityCardGroupSets[gKey].label),1)]),_:2},1032,[`onClick`]))),256))]),createBaseVNode(`div`,null,[_cache[4]||=createTextVNode(` Sorting: `,-1),(openBlock(!0),createElementBlock(Fragment,null,renderList(unref(cargoOverviewStore).cargoData.facilityCardGroupSets[unref(cargoOverviewStore).facilityGroupingKey].sortings,sKey=>(openBlock(),createBlock(unref(bngButton_default),{onClick:$event=>setFacilitySortKey(sKey)},{default:withCtx(()=>[createTextVNode(toDisplayString(unref(cargoOverviewStore).cargoData.sortingSets[sKey].label),1)]),_:2},1032,[`onClick`]))),256))])]),createBaseVNode(`div`,_hoisted_3$164,[createVNode(unref(bngCardHeading_default),null,{default:withCtx(()=>[..._cache[5]||=[createTextVNode(`My Cargo Display`,-1)]]),_:1}),createVNode(unref(bngSwitch_default),{modelValue:unref(cargoOverviewStore).automaticRoute,"onUpdate:modelValue":_cache[0]||=$event=>unref(cargoOverviewStore).automaticRoute=$event},{default:withCtx(()=>[..._cache[6]||=[createTextVNode(` Automatic route `,-1)]]),_:1},8,[`modelValue`]),createBaseVNode(`div`,null,[_cache[7]||=createTextVNode(` Group By: `,-1),(openBlock(!0),createElementBlock(Fragment,null,renderList(unref(cargoOverviewStore).playerGroupings,gKey=>(openBlock(),createBlock(unref(bngButton_default),{onClick:$event=>setPlayerGroupKey(gKey)},{default:withCtx(()=>[createTextVNode(toDisplayString(unref(cargoOverviewStore).cargoData.playerCardGroupSets[gKey].label),1)]),_:2},1032,[`onClick`]))),256))]),createBaseVNode(`div`,null,[_cache[8]||=createTextVNode(` Sorting: `,-1),(openBlock(!0),createElementBlock(Fragment,null,renderList(unref(cargoOverviewStore).cargoData.playerCardGroupSets[unref(cargoOverviewStore).facilityGroupingKey].sortings,sKey=>(openBlock(),createBlock(unref(bngButton_default),{onClick:$event=>setPlayerSortKey(sKey)},{default:withCtx(()=>[createTextVNode(toDisplayString(unref(cargoOverviewStore).cargoData.sortingSets[sKey].label),1)]),_:2},1032,[`onClick`]))),256))]),createBaseVNode(`div`,_hoisted_4$137,[withDirectives(createVNode(unref(bngButton_default),{label:`Continue`,accent:unref(ACCENTS).primary,onClick:acceptClickHandler},null,8,[`accent`]),[[unref(BngOnUiNav_default),void 0,`back,menu`,{asMouse:!0}]])])])]),_:1})]))}}),CargoScreenSettings_default=__plugin_vue_export_helper_default(_sfc_main$259,[[`__scopeId`,`data-v-9dd4f12f`]]),_forEach=(arr,func)=>Array.isArray(arr)&&arr.length>0&&arr.forEach(func);const useCargoOverviewStore=defineStore(`cargoOverview`,()=>{let{events:events$3}=useBridge(),cargoData=ref(),dropDownData=ref({}),newCargoAvailable=ref(!1),cargoHighlighted=ref(!1),automaticRoute=ref(!1),detailedDropOff=ref(!1),tutorialInfo=ref(),facilityGroupingKey=ref(`destinations`),facilitySortingKey=ref(`rewardMoney`),playerGroupings=[`containers`,`tasklist`,`ungrouped`],playerGroupingKey=ref(`tasklist`),playerSortingKey=ref(`cardId`),facilityId,parkingSpotPath,facilityFilter={value:`facility-info`,label:`Facility Info`,showInFilterTabs:!0,isFacilityPage:!0},filterSets=ref({}),filterSetsByValue=ref({}),selectedFilterRef=ref(),selectedFilter=ref(facilityFilter),selectFilter=f=>{Lua_default.career_modules_delivery_general.setSetting(`selectedFilterKey`,f),Lua_default.career_modules_delivery_cargoScreen.setCargoScreenTab(f);for(let filter of filterSets.value)if(filter.value==f[0]){let prevGrouping=facilityGroupingKey.value,prevSorting=facilitySortingKey.value;if(selectedFilter.value=filter,!filter.isFacilityPage&&(filter.groupings.includes(prevGrouping)||(facilityGroupingKey.value=filter.groupings[0]),cargoData.value.facilityCardGroupSets[facilityGroupingKey.value].sortings.includes(prevSorting)||(facilitySortingKey.value=cargoData.value.facilityCardGroupSets[facilityGroupingKey.value].sortings[0]),selectedCargo.value&&selectedCargo.value.isFacilityCard)){let contained=selectedCargo.value.filterTags[filter.value];if(contained)for(let groupKey of filter.groupings)for(let group of cargoData.value.facilityCardGroupSets[groupKey].groups)contained||=group.cardIdsUnsorted.includes(selectedCargo.value.cardId);contained||(selectedCargo.value=void 0)}}},facilityGroupings=computed(()=>selectedFilter.value?selectedFilter.value.groupings:[]),nextFacilityGrouping=()=>{let groups=facilityGroupings.value;facilityGroupingKey.value=groups[(groups.indexOf(facilityGroupingKey.value)+1)%groups.length]},facilitySortings=computed(()=>cargoData.value&&facilityGroupingKey.value&&cargoData.value.facilityCardGroupSets&&cargoData.value.facilityCardGroupSets[facilityGroupingKey.value]?cargoData.value.facilityCardGroupSets[facilityGroupingKey.value].sortings:[]),nextFacilitySorting=()=>{let group=facilitySortings.value;facilitySortingKey.value=group[(group.indexOf(facilitySortingKey.value)+1)%group.length]},nextPlayerGrouping=()=>{let groups=playerGroupings;playerGroupingKey.value=groups[(groups.indexOf(playerGroupingKey.value)+1)%groups.length]},playerSortings=computed(()=>cargoData.value&&facilityGroupingKey.value&&cargoData.value.playerCardGroupSets&&cargoData.value.playerCardGroupSets[facilityGroupingKey.value]?cargoData.value.playerCardGroupSets[facilityGroupingKey.value].sortings:[]),nextPlayerSorting=()=>{let group=cargoData.value.playerCardGroupSets[facilityGroupingKey.value];playerSortingKey.value=group[(group.indexOf(playerSortingKey.value)+1)%group.length]},currentFilterTutorialInfo=computed(()=>{if(!tutorialInfo.value||!selectedFilter.value)return null;let info=tutorialInfo.value[selectedFilter.value.value];return!info||!info.unlocked||!info.isActive?null:info}),openCargoScreenSettings=()=>{addPopup(CargoScreenSettings_default)},sortedParcelOffersByCargoType=computed(()=>{if(!cargoData.value||!cargoData.value.facility||!cargoData.value.facility.outgoingCargo)return{};let sorted={};for(let cargoType in _forEach(cargoData.value.facility.outgoingCargo,cargo=>{sorted[cargo.type]||(sorted[cargo.type]=[]),sorted[cargo.type].push(cargo)}),sorted)sorted[cargoType]=sortByProperty(sorted[cargoType]);return sorted}),sortedVehicleOffers=computed(()=>!cargoData.value||!cargoData.value.facility?[]:sortByProperty(cargoData.value.facility.vehicleOffers)),sortedTrailerOffers=computed(()=>!cargoData.value||!cargoData.value.facility?[]:sortByProperty(cargoData.value.facility.trailerOffers)),sortedAcceptedOffers=computed(()=>cargoData.value?sortByProperty(cargoData.value.player.acceptedOffers):[]),loanerOffers=computed(()=>{if(!cargoData.value||!cargoData.value.facility||!cargoData.value.facility.loanableVehicles)return[];let result=[];return result=result.concat(cargoData.value.facility.loanableVehicles),result}),menuClosed=()=>{cargoData.value=void 0,dropDownData.value={},selectedFilter.value=facilityFilter,selectedCargo.value=void 0,Lua_default.career_modules_delivery_cargoScreen.showCargoRoutePreview(void 0),loadingPrompt&&loadingPrompt.close(null)},requestCargoData=(_facilityId,_parkingSpotPath,updateMaxTimeStamp)=>{facilityId=_facilityId,parkingSpotPath=_parkingSpotPath,Lua_default.career_modules_delivery_cargoScreen.requestCargoDataForUi(facilityId,parkingSpotPath,updateMaxTimeStamp),updateMaxTimeStamp!=0&&(newCargoAvailable.value=!1)},requestCargoDataSimple=()=>{requestCargoData(facilityId,parkingSpotPath,!1)},moveCargoToLocation=(cargoId,targetLocation,skipRequest)=>{Lua_default.career_modules_delivery_cargoScreen.moveCargoFromUi(cargoId,targetLocation),skipRequest||requestCargoData(facilityId,parkingSpotPath,!1)},requestMoveCargoToLocation=(cargoId,moveData,skipRequest)=>{moveData.extraData?openThrowAwayPopup(cargoId,moveData.location,`Throw this cargo away with a `+moveData.extraData.penalty.toFixed(2)+` penalty?`):moveCargoToLocation(cargoId,moveData.location,skipRequest)};async function openThrowAwayPopup(cargoId,targetLocation,message){await openConfirmation(null,message)?moveCargoToLocation(cargoId,targetLocation):setCargoData()}let setCargoData=data=>{let previousCardId;if(selectedCargo.value&&(previousCardId=selectedCargo.value.cardId),data&&(cargoData.value=data),dropDownData.value={},cargoData.value.player&&cargoData.value.player.vehicles){getAutomaticRoute(data.settings.automaticRoute),getDetailedDropOff(data.settings.detailedDropOff),automaticRoute.value&&setAutomaticRoute(automaticRoute.value),filterSets.value=data.filterSets,filterSets.value.unshift(facilityFilter);for(let filter of filterSets.value)filterSetsByValue.value[filter.value]=filter;selectedFilter.value||=filterSets.value[0],previousCardId&&onCargoSelected(cargoData.value.cardsById[previousCardId]),tutorialInfo.value=data.tutorialInfo}},highlightedCards=ref({}),highlightCardIds=highlightedIdMap=>{highlightedCards.value=highlightedIdMap},focusedCargo=ref();ref();let selectedCargo=ref(),onCargoHovered=cargo=>{focusedCargo.value=cargo,highlightRoute(focusedCargo.value)},onCargoSelected=cargo=>{selectedCargo.value=cargo},highlightRoute=card=>{card?Lua_default.career_modules_delivery_cargoScreen.showRoutePreview(card.route):Lua_default.career_modules_delivery_cargoScreen.showRoutePreview(void 0)},setAutomaticRoute=(newValue,oldValue)=>{newValue!=oldValue&&Lua_default.career_modules_delivery_general.setAutomaticRoute(newValue)};watch(()=>automaticRoute.value,setAutomaticRoute);let getAutomaticRoute=enabled=>{automaticRoute.value=enabled};watch(()=>detailedDropOff.value,(newValue,oldValue)=>{newValue!=oldValue&&Lua_default.career_modules_delivery_general.setDetailedDropOff(newValue)});let getDetailedDropOff=enabled=>{detailedDropOff.value=enabled},setGroupingAndSorting=()=>{},cardClicked=card=>{switch(card.cardType){case`parcelGroup`:loadCargoAuto(card);break;case`vehicleOffer`:loadOffer(card);break;case`storage`:loadStorageCustom(card);break}},cardDeselect=()=>onCargoSelected(),cardHovered=card=>{onCargoHovered(card)},clearLoad=cargo=>{for(let id of cargo.ids)Lua_default.career_modules_delivery_cargoScreen.clearTransientMoveForCargo(id);requestCargoDataSimple()},throwAway=card=>{loadingPrompt=addPopup(CargoLoadPopup_default,{cargo:card,throwAway:!0}).promise},changeDistribution=cargo=>{for(let[id,card]of Object.entries(cargoData.value.cardsById))if(card.isFacilityCard&&card.cardType==`parcelGroup`&&card.ids.includes(cargo.ids[0])){loadCargoCustom(card);return}},modifyMaterialLoad=cargo=>{for(let[id,card]of Object.entries(cargoData.value.cardsById))if(card.isFacilityCard&&card.cardType==`storage`&&card.storage.materialType==cargo.materialType){loadStorageCustom(card);return}},loadCargoAuto=cargo=>{for(let id of cargo.ids)Lua_default.career_modules_delivery_cargoScreen.clearTransientMoveForCargo(id);let idx=0;for(let loc of cargo.autoLoadLocations)Lua_default.career_modules_delivery_cargoScreen.moveCargoFromUi(cargo.ids[idx],loc),idx++;requestCargoDataSimple()},loadingPrompt=null,loadCargoCustom=card=>{if(card.transientMove){let cargoId=card.ids[0];for(let[id,otherCard]of Object.entries(cargoData.value.cardsById))if(otherCard.isFacilityCard&&otherCard.cardType==`parcelGroup`&&otherCard.ids.includes(cargoId)){loadingPrompt=addPopup(CargoLoadPopup_default,{cargo:otherCard}).promise;return}}else loadingPrompt=addPopup(CargoLoadPopup_default,{cargo:card}).promise},loadStorageCustom=storageData=>{loadingPrompt=addPopup(CargoLoadPopup_default,{storageData}).promise},loadOffer=offer=>{Lua_default.career_modules_delivery_cargoScreen.toggleOfferForSpawning(offer.id),requestCargoDataSimple()},loadLoaner=offer=>{Lua_default.career_modules_loanerVehicles.markForSpawning(offer),requestCargoDataSimple()},returnLoaner=vehId=>{Lua_default.career_modules_loanerVehicles.returnVehicle(vehId).then(()=>{requestCargoDataSimple()})};async function abandonOffer(card){await openConfirmation(null,`Abandon `+card.name+`? There is a `+card.abandonInfo.penaltyMoney+`$ penalty.`)&&(Lua_default.career_modules_delivery_cargoScreen.abandonAcceptedOffer(card.abandonInfo.vehId),requestCargoDataSimple())}return events$3.on(`automaticRouteSet`,getAutomaticRoute),events$3.on(`cargoDataForUiReady`,setCargoData),events$3.on(`newCargoAvailable`,()=>newCargoAvailable.value=!0),events$3.on(`sendHighlightedCardIds`,highlightCardIds),events$3.on(`requestCargoDataSimple`,requestCargoDataSimple),{cargoData,tutorialInfo,sortedParcelOffersByCargoType,sortedVehicleOffers,sortedTrailerOffers,sortedAcceptedOffers,onCargoHovered,onCargoSelected,loanerOffers,dropDownData,newCargoAvailable,cargoHighlighted,automaticRoute,detailedDropOff,setGroupingAndSorting,requestCargoData,requestCargoDataSimple,requestMoveCargoToLocation,menuClosed,dispose:()=>{events$3.off(`cargoDataForUiReady`),events$3.off(`newCargoAvailable`),events$3.off(`sendHighlightedCardIds`),events$3.on(`requestCargoDataSimple`)},focusedCargo,selectedCargo,cardClicked,cardHovered,cardDeselect,clearLoad,changeDistribution,loadCargoAuto,loadCargoCustom,throwAway,loadStorageCustom,loadOffer,abandonOffer,loadLoaner,returnLoaner,modifyMaterialLoad,filterSets,filterSetsByValue,selectedFilterRef,selectedFilter,selectFilter,highlightedCards,openCargoScreenSettings,nextFacilityGrouping,nextFacilitySorting,nextPlayerGrouping,nextPlayerSorting,facilityGroupingKey,facilitySortingKey,playerGroupingKey,playerSortingKey,facilityGroupings,facilitySortings,playerGroupings,playerSortings,currentFilterTutorialInfo}});var _hoisted_1$229={class:`fill-panel`},_hoisted_2$187={key:1,class:`groupGrid`},_sfc_main$258={__name:`ProvidedOrdersPanel`,props:{groupSets:Object,groupIdx:[Number,String],sortingSets:Object,sortIdx:[Number,String],sortAsc:{type:Boolean,default:!0},ignoreFilter:Boolean},setup(__props){let cargoOverviewStore=useCargoOverviewStore(),props=__props;computed(()=>props.groupSets&&props.groupSets[props.groupIdx]&&props.groupSets[props.groupIdx].groups?props.groupSets[props.groupIdx].groups:[]);let sortedGroups=computed(()=>{let groupSet=props.groupSets[props.groupIdx];if(!cargoOverviewStore.cargoData||!cargoOverviewStore.cargoData.cardsById||!groupSet.groups||!groupSet.groups.length)return[];let groups=groupSet.groups,sortKey=props.sortingSets[props.sortIdx].key;function getHighestSortValue(group){let maxSortValue=-1/0;return group.cardIdsUnsorted&&group.cardIdsUnsorted.length&&group.cardIdsUnsorted.forEach(cardId=>{let card=cargoOverviewStore.cargoData.cardsById[cardId];if(card.filterTags[cargoOverviewStore.selectedFilter.value]||group.ignoreFilter||props.ignoreFilter){let sortValue=card.sortValues&&card.sortValues[sortKey]!==void 0?card.sortValues[sortKey]:1/0;sortValue>maxSortValue&&(maxSortValue=sortValue)}}),maxSortValue}return groups.sort((a$1,b)=>{let minValueA=getHighestSortValue(a$1),minValueB=getHighestSortValue(b);return props.sortAsc?minValueA-minValueB:minValueB-minValueA}),groups}),getSortedCardIds=group=>{if(!cargoOverviewStore.cargoData||!cargoOverviewStore.cargoData.cardsById||!group.cardIdsUnsorted)return[];let cardsById=cargoOverviewStore.cargoData.cardsById,sortKey=props.sortingSets[props.sortIdx].key;return group.cardIdsUnsorted&&group.cardIdsUnsorted.length?group.cardIdsUnsorted.slice().sort((a$1,b)=>{let cardA=cardsById[a$1],cardB=cardsById[b],valueA=cardA&&cardA.sortValues&&cardA.sortValues[sortKey]!==void 0?cardA.sortValues[sortKey]:0,valueB=cardB&&cardB.sortValues&&cardB.sortValues[sortKey]!==void 0?cardB.sortValues[sortKey]:0;return props.sortAsc?valueA-valueB:valueB-valueA}):[]};return(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$229,[unref(cargoOverviewStore).cargoData?unref(cargoOverviewStore).cargoData.cardsById?(openBlock(),createElementBlock(`div`,_hoisted_2$187,[(openBlock(!0),createElementBlock(Fragment,null,renderList(sortedGroups.value,group=>(openBlock(),createElementBlock(Fragment,{key:group.label},[(group.cardIdsUnsorted.length>0||group.showEmpty)&&(group.filterTags[unref(cargoOverviewStore).selectedFilter.value]||group.ignoreFilter||__props.ignoreFilter)?(openBlock(),createBlock(CardGroup_default,{key:0,label:group.label,meta:group.meta},{default:withCtx(()=>[(openBlock(!0),createElementBlock(Fragment,null,renderList(getSortedCardIds(group),cardId=>(openBlock(),createElementBlock(Fragment,{key:cardId},[unref(cargoOverviewStore).cargoData.cardsById[cardId].filterTags[unref(cargoOverviewStore).selectedFilter.value]||group.ignoreFilter||__props.ignoreFilter?(openBlock(),createBlock(CargoCard_default,{key:0,card:unref(cargoOverviewStore).cargoData.cardsById[cardId],onClick:withModifiers($event=>unref(cargoOverviewStore).onCargoSelected(unref(cargoOverviewStore).cargoData.cardsById[cardId]),[`stop`]),onMouseover:$event=>unref(cargoOverviewStore).onCargoHovered(unref(cargoOverviewStore).cargoData.cardsById[cardId]),onMouseleave:_cache[0]||=$event=>unref(cargoOverviewStore).onCargoHovered(),hideProps:__props.groupSets[__props.groupIdx].hideProps,hideModsAndTimer:__props.groupSets[__props.groupIdx].hideModsAndTimer},null,8,[`card`,`onClick`,`onMouseover`,`hideProps`,`hideModsAndTimer`])):createCommentVNode(``,!0)],64))),128))]),_:2},1032,[`label`,`meta`])):createCommentVNode(``,!0)],64))),128))])):createCommentVNode(``,!0):(openBlock(),createElementBlock(Fragment,{key:0},[createTextVNode(` No data yet... `)],64))]))}},ProvidedOrdersPanel_default=__plugin_vue_export_helper_default(_sfc_main$258,[[`__scopeId`,`data-v-877d97e8`]]),_hoisted_1$228={class:`header-text`},_hoisted_2$186={key:0,class:`disabled-reason noOffers`},_sfc_main$257={__name:`FilterCard`,props:{filter:Object},setup(__props){let props=__props,cargoOverviewStore=useCargoOverviewStore(),disabled=computed(()=>{if(props.filter){if(!props.filter.hasAvailableOffers)return{disabled:!0};if(props.filter.unavailableAtThisFacility)return{disabled:!0,reason:`Unavailable`};if(props.filter.lockedInfo)return{disabled:!0,reason:props.filter.lockedInfo.shortLabel}}return{disabled:!1}});return onMounted(()=>{}),(_ctx,_cache)=>(openBlock(),createBlock(unref(bngCard_default),{class:normalizeClass([`filterCard`,{disabled:disabled.value.disabled}]),onClick:_cache[0]||=withModifiers($event=>unref(cargoOverviewStore).selectFilter([__props.filter.value]),[`stop`])},{default:withCtx(()=>[createVNode(unref(bngCardHeading_default),{class:`card-heading`},{default:withCtx(()=>[createBaseVNode(`span`,_hoisted_1$228,toDisplayString(__props.filter.label),1)]),_:1}),createVNode(unref(aspectRatio_default),{class:`image`,ratio:`8:3`},{default:withCtx(()=>[createVNode(unref(bngIcon_default),{class:`glyph`,type:unref(icons)[__props.filter.icon]},null,8,[`type`]),createBaseVNode(`div`,{class:normalizeClass([`step`,{none:__props.filter.facilityCards===0}])},[createVNode(unref(bngPropVal_default),{class:`amount-avail`,valueLabel:`× `+__props.filter.facilityCards},null,8,[`valueLabel`])],2)]),_:1}),disabled.value.reason?(openBlock(),createElementBlock(`div`,_hoisted_2$186,[createVNode(unref(bngPropVal_default),{class:`amount-avail`,iconType:unref(icons).lockClosed,valueLabel:disabled.value.reason},null,8,[`iconType`,`valueLabel`])])):createCommentVNode(``,!0)]),_:1},8,[`class`]))}},FilterCard_default=__plugin_vue_export_helper_default(_sfc_main$257,[[`__scopeId`,`data-v-85dcf2d5`]]),_hoisted_1$227={key:0,class:`heading-container`},_hoisted_2$185={class:`status-add`},_hoisted_3$163={class:`controls-row`},_hoisted_4$136={key:1,class:`content-container`},_hoisted_5$119={class:`header-container`},_hoisted_6$102={class:`info-line`},_hoisted_7$89={class:`header-flex padding`},_hoisted_8$74={class:`groupSortButtons`},_hoisted_9$67={class:`scroll-panel`},_hoisted_10$58={key:0,class:`tasklist`},_hoisted_11$52={class:`tasklist-header`},_hoisted_12$41={class:`task-content`},_hoisted_13$34={class:`heading`},_hoisted_14$32={class:`description`},_hoisted_15$31={key:1,class:`empty-cargo-card`},_hoisted_16$31={class:`header-container`},_hoisted_17$25={class:`header-flex`},_hoisted_18$22={key:0,class:`map-overlay`},_hoisted_19$19={key:1,class:`empty-cargo-card`},_hoisted_20$16={class:`header-container`},_hoisted_21$15={class:`info-line`},_hoisted_22$13={class:`header-flex wrap padding`},_hoisted_23$12={class:`groupSortButtons`},_hoisted_24$11={class:`cargohold-info`},_hoisted_25$10={class:`scroll-panel padding`},_hoisted_26$8={class:`content`},_hoisted_27$8={key:0,class:`buttons-wrapper`},_hoisted_28$7={class:`content flex-container`},_hoisted_29$7={key:1,class:`header-flex progress-bar-padding`},_hoisted_30$7={key:0,class:`progress-bar-wrapper wide`},_hoisted_31$7=[`innerHTML`],_hoisted_32$7={class:`info-right`},_hoisted_33$7={key:0},_hoisted_34$7={key:0,class:`header-flex progress-bar-padding`},_hoisted_35$6={class:`progress-bar-wrapper wide`},_hoisted_36$6={class:`content`},_hoisted_37$5={class:`filterSelectGrid`},_sfc_main$256={__name:`CargoOverviewMain`,props:{facilityId:String,parkingSpotPath:String},setup(__props){let tabPills=ref();useUINavScope(`delivery`);let props=__props,cargoOverviewStore=useCargoOverviewStore();async function openDiscardPopup(){await openConfirmation(null,`Discard Changes?`)&&(Lua_default.career_modules_delivery_cargoScreen.cancelDeliveryConfiguration(),Lua_default.career_modules_delivery_cargoScreen.exitCargoOverviewScreen(),window.bngVue.gotoGameState(`play`))}let close=()=>{cargoOverviewStore.cargoData.confirmButtonInfo.itemCount>0&&props.facilityId?openDiscardPopup():(Lua_default.career_modules_delivery_cargoScreen.exitCargoOverviewScreen(),window.bngVue.gotoGameState(`play`))},acceptLoad=()=>{Lua_default.career_modules_delivery_cargoScreen.commitDeliveryConfiguration(),Lua_default.career_modules_delivery_cargoScreen.exitCargoOverviewScreen(),window.bngVue.gotoGameState(`play`)};async function openExitModePopup(){await openConfirmation(null,`Throw away all cargo and exit delivery mode?`)&&(Lua_default.career_modules_delivery_cargoScreen.exitDeliveryMode(),Lua_default.career_modules_delivery_cargoScreen.exitCargoOverviewScreen(),window.bngVue.gotoGameState(`play`))}let exitMode=()=>{openExitModePopup()};async function gotoSkillProgress(panel){cargoOverviewStore.cargoData.confirmButtonInfo.itemCount>0||window.bngVue.gotoGameState(`branchPage`,{params:{branchKey:panel.branchId,skillKey:panel.skillId}})}async function gotoOrganizations(id){cargoOverviewStore.cargoData.confirmButtonInfo.itemCount>0||window.bngVue.gotoGameState(`organizations`,{params:{orgId:id}})}let facilitySortAsc=ref(!1),playerSortAsc=ref(!0),activePopovers={},popShown=pop=>nextTick(()=>activePopovers[pop.name]=pop),popHidden=pop=>nextTick(()=>delete activePopovers[pop.name]);function popHideAll(){for(let pop of Object.values(activePopovers))pop.hide()}let screenCover=ref(),mapPanel=ref(null),observer$2,mapClipChanged;function resizer(){let elScreen=screenCover.value?.$el||screenCover.value;if(!mapPanel.value||!elScreen){mapClipChanged&&(mapClipChanged=!1,screenCover.value.style.setProperty(`--map-clip`,`unset`));return}let pad=3,{width:width$1,height:height$1}=elScreen.getBoundingClientRect(),rect=mapPanel.value.getBoundingClientRect(),percentile=[(rect.x+3)/width$1,(rect.y+3)/height$1,(rect.x+rect.width-3)/width$1,(rect.y+rect.height-3)/height$1].map(n=>`${n*100}%`);elScreen.style.setProperty(`--map-clip`,`polygon(0% 0%, 100% 0%, 100% 100%, 0% 100%, 0% 0%, ${percentile[0]} ${percentile[1]}, ${percentile[0]} ${percentile[3]}, ${percentile[2]} ${percentile[3]}, ${percentile[2]} ${percentile[1]}, ${percentile[0]} ${percentile[1]})`),mapClipChanged=!0,Lua_default.freeroam_bigMapMode.setBigmapScreenBounds({width:width$1,height:height$1},rect)}watch(()=>mapPanel.value,(elm,prev)=>{prev&&observer$2.unobserve(prev),elm&&observer$2.observe(elm)},{immediate:!0}),watch(()=>cargoOverviewStore.selectedFilter?.isFacilityPage,()=>nextTick(resizer));let selectedFilters=ref([]);return watch(()=>cargoOverviewStore.selectedFilter,filter=>{selectedFilters.value=[filter.value],cargoOverviewStore.focusedCargo=null}),onMounted(()=>{observer$2=new ResizeObserver(resizer),resizer(),cargoOverviewStore.requestCargoData(props.facilityId,props.parkingSpotPath),selectedFilters.value=[cargoOverviewStore.selectedFilter.value]}),onBeforeUnmount(()=>{observer$2?.disconnect()}),onUnmounted(()=>{Lua_default.career_modules_delivery_cargoScreen.exitCargoOverviewScreen(),cargoOverviewStore.menuClosed()}),(_ctx,_cache)=>(openBlock(),createBlock(unref(layoutSingle_default),{class:`cargo-overview-main-layout`,"bng-ui-scope":`delivery`,ref_key:`screenCover`,ref:screenCover},{default:withCtx(()=>[createBaseVNode(`div`,{class:`screen`,onClick:_cache[10]||=$event=>unref(cargoOverviewStore).cardDeselect(),onClickCapture:popHideAll},[unref(cargoOverviewStore).cargoData?(openBlock(),createElementBlock(`div`,_hoisted_1$227,[createVNode(unref(bngScreenHeading_default),{preheadings:[`Delivery Mode`],divider:``},{default:withCtx(()=>[createTextVNode(toDisplayString(unref(cargoOverviewStore).cargoData.facility?unref(cargoOverviewStore).cargoData.facility.name:`My Cargo`),1)]),_:1}),createVNode(unref(bngCard_default),{class:`status-container`},{default:withCtx(()=>[createVNode(unref(careerStatus_default)),createBaseVNode(`div`,_hoisted_2$185,[(openBlock(!0),createElementBlock(Fragment,null,renderList(unref(cargoOverviewStore).cargoData.skillLevels,(skill,index)=>(openBlock(),createBlock(unref(bngPropVal_default),{key:index,iconType:unref(icons)[skill.icon],valueLabel:_ctx.$ctx_t(skill.levelLabel)},null,8,[`iconType`,`valueLabel`]))),128)),unref(cargoOverviewStore).cargoData.facility&&unref(cargoOverviewStore).cargoData.facility.organization?(openBlock(),createBlock(unref(bngPropVal_default),{key:0,iconType:unref(icons).peopleOutline,valueLabel:_ctx.$ctx_t(unref(cargoOverviewStore).cargoData.facility.organization.reputation.label)},null,8,[`iconType`,`valueLabel`])):createCommentVNode(``,!0)])]),_:1})])):createCommentVNode(``,!0),createBaseVNode(`div`,_hoisted_3$163,[withDirectives((openBlock(),createBlock(unref(bngButton_default),{class:`back-button`,accent:unref(ACCENTS).attention,onClick:close},{default:withCtx(()=>[createVNode(unref(bngBinding_default),{"ui-event":`back`,deviceMask:`xinput`}),createTextVNode(` `+toDisplayString(_ctx.$t(`ui.common.close`)),1)]),_:1},8,[`accent`])),[[unref(BngOnUiNav_default),void 0,`back,menu`,{asMouse:!0}]]),unref(cargoOverviewStore).cargoData&&unref(cargoOverviewStore).filterSets&&__props.facilityId?(openBlock(),createBlock(unref(bngPillFilters_default),{key:0,ref_key:`tabPills`,ref:tabPills,required:``,modelValue:selectedFilters.value,"onUpdate:modelValue":_cache[0]||=$event=>selectedFilters.value=$event,options:unref(cargoOverviewStore).filterSets,onValueChanged:unref(cargoOverviewStore).selectFilter},null,8,[`modelValue`,`options`,`onValueChanged`])):createCommentVNode(``,!0),!__props.facilityId&&unref(cargoOverviewStore).cargoData&&unref(cargoOverviewStore).cargoData.player.penaltyForAbandon.money<0?(openBlock(),createBlock(unref(bngButton_default),{key:1,accent:`attention`,iconLeft:unref(icons).trashBin1,onClick:exitMode,class:`right-button`},{default:withCtx(()=>[..._cache[11]||=[createTextVNode(` Abandon all deliveries `,-1)]]),_:1},8,[`iconLeft`])):createCommentVNode(``,!0)]),unref(cargoOverviewStore).cargoData?(openBlock(),createElementBlock(`div`,_hoisted_4$136,[!unref(cargoOverviewStore).selectedFilter.isFacilityPage||!__props.facilityId?(openBlock(),createElementBlock(`div`,{key:0,class:normalizeClass([`panel-flex`,{reverse:!__props.facilityId}])},[__props.facilityId?(openBlock(),createBlock(unref(bngCard_default),{key:0,class:`content-row provided-orders-panel`},{default:withCtx(()=>[createBaseVNode(`div`,_hoisted_5$119,[unref(cargoOverviewStore).selectedFilter?(openBlock(),createBlock(unref(bngCardHeading_default),{key:0,type:`ribbon`,class:`cardHeadingFlex wide`},{default:withCtx(()=>[createBaseVNode(`span`,null,toDisplayString(unref(cargoOverviewStore).selectedFilter.label),1),unref(cargoOverviewStore).selectedFilter.howTo?(openBlock(),createBlock(TutorialButton_default,{key:0,class:`howto-button right`,accent:`secondary`,icon:unref(icons).help,pages:unref(cargoOverviewStore).selectedFilter.howTo.pages},null,8,[`icon`,`pages`])):createCommentVNode(``,!0)]),_:1})):createCommentVNode(``,!0),createBaseVNode(`div`,_hoisted_6$102,[createVNode(unref(bngIcon_default),{type:unref(icons).info},null,8,[`type`]),createBaseVNode(`span`,null,toDisplayString(unref(cargoOverviewStore).selectedFilter.shortDescription),1)]),createBaseVNode(`div`,_hoisted_7$89,[withDirectives((openBlock(),createBlock(unref(bngButton_default),{class:`groupSortButton`,accent:unref(ACCENTS).text,icon:unref(icons).group,onClick:_cache[1]||=withModifiers(()=>{},[`stop`])},{default:withCtx(()=>[createTextVNode(` Grouping: `+toDisplayString(unref(cargoOverviewStore).cargoData.facilityCardGroupSets[unref(cargoOverviewStore).facilityGroupingKey].label),1)]),_:1},8,[`accent`,`icon`])),[[unref(BngPopover_default),`facility-grouping`,`bottom`,{click:!0}]]),createVNode(unref(bngPopoverMenu_default),{name:`facility-grouping`,focus:``,onShow:popShown,onHide:popHidden},{default:withCtx(({hide:hide$2})=>[(openBlock(!0),createElementBlock(Fragment,null,renderList(unref(cargoOverviewStore).facilityGroupings,key=>withDirectives((openBlock(),createBlock(unref(bngButton_default),{key,accent:unref(ACCENTS).menu,class:normalizeClass({selected:unref(cargoOverviewStore).facilityGroupingKey===key}),onClick:withModifiers(()=>{unref(cargoOverviewStore).facilityGroupingKey=key,hide$2()},[`stop`])},{default:withCtx(()=>[createTextVNode(toDisplayString(unref(cargoOverviewStore).cargoData.facilityCardGroupSets[key].label),1)]),_:2},1032,[`accent`,`class`,`onClick`])),[[unref(BngOnUiNav_default),void 0,`ok`,{focusRequired:!0,asMouse:!0}]])),128))]),_:1}),createBaseVNode(`div`,_hoisted_8$74,[withDirectives((openBlock(),createBlock(unref(bngButton_default),{class:`groupSortButton`,accent:unref(ACCENTS).text,icon:unref(icons).order,onClick:_cache[2]||=withModifiers(()=>{},[`stop`])},{default:withCtx(()=>[createTextVNode(` Sorting: `+toDisplayString(unref(cargoOverviewStore).cargoData.sortingSets[unref(cargoOverviewStore).facilitySortingKey].label),1)]),_:1},8,[`accent`,`icon`])),[[unref(BngPopover_default),`facility-sorting`,`bottom`,{click:!0}]]),withDirectives(createVNode(unref(bngButton_default),{class:`groupSortButtonSmall`,accent:unref(ACCENTS).text,icon:facilitySortAsc.value?unref(icons).sortAsc:unref(icons).sortDesc,onClick:_cache[3]||=withModifiers($event=>facilitySortAsc.value=!facilitySortAsc.value,[`stop`])},null,8,[`accent`,`icon`]),[[unref(BngTooltip_default),facilitySortAsc.value?`Ascending order`:`Descending order`,`top`]])]),createVNode(unref(bngPopoverMenu_default),{name:`facility-sorting`,focus:``,onShow:popShown,onHide:popHidden},{default:withCtx(({hide:hide$2})=>[(openBlock(!0),createElementBlock(Fragment,null,renderList(unref(cargoOverviewStore).facilitySortings,key=>withDirectives((openBlock(),createBlock(unref(bngButton_default),{key,accent:unref(ACCENTS).menu,class:normalizeClass({selected:unref(cargoOverviewStore).facilitySortingKey===key}),onClick:()=>{unref(cargoOverviewStore).facilitySortingKey=key,hide$2()}},{default:withCtx(()=>[createTextVNode(toDisplayString(unref(cargoOverviewStore).cargoData.sortingSets[key].label),1)]),_:2},1032,[`accent`,`class`,`onClick`])),[[unref(BngOnUiNav_default),void 0,`ok`,{focusRequired:!0,asMouse:!0}]])),128))]),_:1})])]),_cache[12]||=createBaseVNode(`div`,{class:`separator`},null,-1),createBaseVNode(`div`,_hoisted_9$67,[unref(cargoOverviewStore).currentFilterTutorialInfo?.tasks?(openBlock(),createElementBlock(`div`,_hoisted_10$58,[createBaseVNode(`div`,_hoisted_11$52,toDisplayString(unref(cargoOverviewStore).selectedFilter.label)+` Tutorial `,1),(openBlock(!0),createElementBlock(Fragment,null,renderList(unref(cargoOverviewStore).currentFilterTutorialInfo.tasks,task=>(openBlock(),createElementBlock(`div`,{class:`task`,key:task.label},[createVNode(unref(bngIcon_default),{class:`icon`,type:unref(icons)[task.done?`checkboxOn`:`checkboxOff`]},null,8,[`type`]),createBaseVNode(`div`,_hoisted_12$41,[createBaseVNode(`div`,_hoisted_13$34,toDisplayString(task.label),1),createBaseVNode(`div`,_hoisted_14$32,toDisplayString(task.description),1)])]))),128))])):createCommentVNode(``,!0),createVNode(ProvidedOrdersPanel_default,{groupSets:unref(cargoOverviewStore).cargoData.facilityCardGroupSets,groupIdx:unref(cargoOverviewStore).facilityGroupingKey,sortingSets:unref(cargoOverviewStore).cargoData.sortingSets,sortIdx:unref(cargoOverviewStore).facilitySortingKey,sortAsc:facilitySortAsc.value,onCardHovered:unref(cargoOverviewStore).cardHovered,onCardClicked:unref(cargoOverviewStore).cardClicked},null,8,[`groupSets`,`groupIdx`,`sortingSets`,`sortIdx`,`sortAsc`,`onCardHovered`,`onCardClicked`])])]),_:1})):createCommentVNode(``,!0),createBaseVNode(`div`,{class:normalizeClass([`content-row selected-and-map-panel`,{wide:!__props.facilityId}])},[__props.facilityId?(openBlock(),createBlock(unref(bngCard_default),{key:0,class:`cargo-detail`},{default:withCtx(()=>[unref(cargoOverviewStore).focusedCargo||unref(cargoOverviewStore).selectedCargo?(openBlock(),createBlock(CargoCard_default,{key:0,card:unref(cargoOverviewStore).focusedCargo||unref(cargoOverviewStore).selectedCargo,detailed:``,"show-buttons":!unref(cargoOverviewStore).focusedCargo&&unref(cargoOverviewStore).selectedCargo||unref(cargoOverviewStore).focusedCargo===unref(cargoOverviewStore).selectedCargo},null,8,[`card`,`show-buttons`])):(openBlock(),createElementBlock(`div`,_hoisted_15$31,`Select a card to view details.`))]),_:1})):createCommentVNode(``,!0),createBaseVNode(`div`,{class:`map`,ref_key:`mapPanel`,ref:mapPanel},[createBaseVNode(`div`,_hoisted_16$31,[createBaseVNode(`div`,_hoisted_17$25,[createVNode(unref(bngCardHeading_default),{type:`ribbon`,class:`cardHeading wide`},{default:withCtx(()=>[createTextVNode(toDisplayString(_ctx.$t(unref(cargoOverviewStore).cargoData.levelInfo.name)),1)]),_:1}),createVNode(unref(bngSwitch_default),{modelValue:unref(cargoOverviewStore).automaticRoute,"onUpdate:modelValue":_cache[4]||=$event=>unref(cargoOverviewStore).automaticRoute=$event,onClick:_cache[5]||=withModifiers(()=>{},[`stop`])},{default:withCtx(()=>[..._cache[13]||=[createTextVNode(` Automatic route `,-1)]]),_:1},8,[`modelValue`])])]),__props.facilityId?createCommentVNode(``,!0):(openBlock(),createElementBlock(`div`,_hoisted_18$22,[createVNode(unref(bngCard_default),{class:`cargo-detail`},{default:withCtx(()=>[unref(cargoOverviewStore).focusedCargo||unref(cargoOverviewStore).selectedCargo?(openBlock(),createBlock(CargoCard_default,{key:0,card:unref(cargoOverviewStore).focusedCargo||unref(cargoOverviewStore).selectedCargo,detailed:``,"show-buttons":!unref(cargoOverviewStore).focusedCargo&&unref(cargoOverviewStore).selectedCargo||unref(cargoOverviewStore).focusedCargo===unref(cargoOverviewStore).selectedCargo},null,8,[`card`,`show-buttons`])):(openBlock(),createElementBlock(`div`,_hoisted_19$19,` Select a card to view details. `))]),_:1})]))],512)],2),createVNode(unref(bngCard_default),{class:`content-row my-cargo-panel`},{default:withCtx(()=>[createBaseVNode(`div`,_hoisted_20$16,[createVNode(unref(bngCardHeading_default),{type:`ribbon`,class:`cardHeadingFlex wide`},{default:withCtx(()=>[_cache[14]||=createBaseVNode(`span`,null,`My Cargo`,-1),createVNode(TutorialButton_default,{class:`howto-button right`,accent:`secondary`,icon:unref(icons).help,pages:[`delivery/myCargo`,`delivery/parcelDelivery`]},null,8,[`icon`])]),_:1}),createBaseVNode(`div`,_hoisted_21$15,[createVNode(unref(bngIcon_default),{type:unref(icons).info},null,8,[`type`]),_cache[15]||=createBaseVNode(`span`,null,`Check your loaded cargo and other delivery-related tasks.`,-1)]),createBaseVNode(`div`,_hoisted_22$13,[withDirectives((openBlock(),createBlock(unref(bngButton_default),{class:`groupSortButton`,accent:unref(ACCENTS).text,icon:unref(icons).group,onClick:_cache[6]||=withModifiers(()=>{},[`stop`])},{default:withCtx(()=>[createTextVNode(` Grouping: `+toDisplayString(unref(cargoOverviewStore).cargoData.playerCardGroupSets[unref(cargoOverviewStore).playerGroupingKey].label),1)]),_:1},8,[`accent`,`icon`])),[[unref(BngPopover_default),`player-grouping`,`bottom`,{click:!0}]]),createVNode(unref(bngPopoverMenu_default),{name:`player-grouping`,focus:``,onShow:popShown,onHide:popHidden},{default:withCtx(({hide:hide$2})=>[(openBlock(!0),createElementBlock(Fragment,null,renderList(unref(cargoOverviewStore).playerGroupings,key=>withDirectives((openBlock(),createBlock(unref(bngButton_default),{key,accent:unref(ACCENTS).menu,class:normalizeClass({selected:unref(cargoOverviewStore).playerGroupingKey===key}),onClick:()=>{unref(cargoOverviewStore).playerGroupingKey=key,hide$2()}},{default:withCtx(()=>[createTextVNode(toDisplayString(unref(cargoOverviewStore).cargoData.playerCardGroupSets[key].label),1)]),_:2},1032,[`accent`,`class`,`onClick`])),[[unref(BngOnUiNav_default),void 0,`ok`,{focusRequired:!0,asMouse:!0}]])),128))]),_:1}),createBaseVNode(`div`,_hoisted_23$12,[withDirectives((openBlock(),createBlock(unref(bngButton_default),{class:`groupSortButton`,accent:unref(ACCENTS).text,icon:unref(icons).order,onClick:_cache[7]||=withModifiers(()=>{},[`stop`])},{default:withCtx(()=>[createTextVNode(` Sorting: `+toDisplayString(unref(cargoOverviewStore).cargoData.sortingSets[unref(cargoOverviewStore).playerSortingKey].label),1)]),_:1},8,[`accent`,`icon`])),[[unref(BngPopover_default),`player-sorting`,`bottom`,{click:!0}]]),withDirectives(createVNode(unref(bngButton_default),{class:`groupSortButtonSmall`,accent:unref(ACCENTS).text,icon:playerSortAsc.value?unref(icons).sortAsc:unref(icons).sortDesc,onClick:_cache[8]||=withModifiers($event=>playerSortAsc.value=!playerSortAsc.value,[`stop`])},null,8,[`accent`,`icon`]),[[unref(BngTooltip_default),playerSortAsc.value?`Ascending order`:`Descending order`,`top`]])]),createVNode(unref(bngPopoverMenu_default),{name:`player-sorting`,focus:``,onShow:popShown,onHide:popHidden},{default:withCtx(({hide:hide$2})=>[(openBlock(!0),createElementBlock(Fragment,null,renderList(unref(cargoOverviewStore).playerSortings,key=>withDirectives((openBlock(),createBlock(unref(bngButton_default),{key,accent:unref(ACCENTS).menu,class:normalizeClass({selected:unref(cargoOverviewStore).playerSortingKey===key}),onClick:withModifiers(()=>{unref(cargoOverviewStore).playerSortingKey=key,hide$2()},[`stop`])},{default:withCtx(()=>[createTextVNode(toDisplayString(unref(cargoOverviewStore).cargoData.sortingSets[key].label),1)]),_:2},1032,[`accent`,`class`,`onClick`])),[[unref(BngOnUiNav_default),void 0,`ok`,{focusRequired:!0,asMouse:!0}]])),128))]),_:1}),createBaseVNode(`div`,_hoisted_24$11,[(openBlock(!0),createElementBlock(Fragment,null,renderList(unref(cargoOverviewStore).cargoData.playerCardGroupSets.totalStorages.groups,(group,index)=>(openBlock(),createElementBlock(Fragment,{key:index},[group.meta.totalCargoSlots?(openBlock(),createBlock(CargoInfo_default,{key:0,class:`info-with-gradient`,meta:group.meta},null,8,[`meta`])):createCommentVNode(``,!0)],64))),128))])])]),_cache[17]||=createBaseVNode(`div`,{class:`separator`},null,-1),createBaseVNode(`div`,_hoisted_25$10,[unref(cargoOverviewStore).selectedFilter.noContainers?(openBlock(),createBlock(unref(bngCard_default),{key:0,class:`no-container-card`},{default:withCtx(()=>[createBaseVNode(`div`,_hoisted_26$8,[createBaseVNode(`span`,null,[createVNode(unref(bngIcon_default),{type:unref(icons).info},null,8,[`type`]),_cache[16]||=createTextVNode(` You do not have any containers installed that can load this type of cargo. `,-1)]),createVNode(TutorialButton_default,{class:`button`,accent:`secondary`,icon:unref(icons).help,pages:[`delivery/cargoContainerHowTo`],text:`How do I install cargo containers?`},null,8,[`icon`])])]),_:1})):createCommentVNode(``,!0),createVNode(ProvidedOrdersPanel_default,{groupSets:unref(cargoOverviewStore).cargoData.playerCardGroupSets,groupIdx:unref(cargoOverviewStore).playerGroupingKey,sortingSets:unref(cargoOverviewStore).cargoData.sortingSets,sortIdx:unref(cargoOverviewStore).playerSortingKey,sortAsc:playerSortAsc.value,ignoreFilter:!0,onCardHovered:unref(cargoOverviewStore).cardHovered,onCardClicked:unref(cargoOverviewStore).cardClicked},null,8,[`groupSets`,`groupIdx`,`sortingSets`,`sortIdx`,`sortAsc`,`onCardHovered`,`onCardClicked`])]),unref(cargoOverviewStore).cargoData&&__props.facilityId?(openBlock(),createElementBlock(`div`,_hoisted_27$8,[unref(cargoOverviewStore).cargoData.confirmButtonInfo.itemCount>0?(openBlock(),createBlock(unref(bngButton_default),{key:0,class:`accept-button`,icon:unref(icons).checkmark,onClick:withModifiers(acceptLoad,[`stop`])},{default:withCtx(()=>[createTextVNode(` Continue (`+toDisplayString(unref(cargoOverviewStore).cargoData.confirmButtonInfo.itemCount)+` items) `,1)]),_:1},8,[`icon`])):createCommentVNode(``,!0)])):createCommentVNode(``,!0)]),_:1})],2)):(openBlock(),createBlock(unref(bngCard_default),{key:1,class:`detailedFilterSelector`},{default:withCtx(()=>[createBaseVNode(`div`,_hoisted_28$7,[createVNode(unref(bngCard_default),{class:`info-left`},{default:withCtx(()=>[unref(cargoOverviewStore).cargoData.facility.organization?(openBlock(),createBlock(unref(bngCardHeading_default),{key:0,type:`ribbon`,class:`cardHeadingFlex`},{default:withCtx(()=>[createBaseVNode(`span`,null,[_cache[18]||=createBaseVNode(`span`,null,`Reputation:\xA0`,-1),createBaseVNode(`span`,null,toDisplayString(unref(cargoOverviewStore).cargoData.facility.organization.reputation.label+` (lvl `+unref(cargoOverviewStore).cargoData.facility.organization.reputation.level+`)`),1)]),createVNode(unref(bngButton_default),{icon:unref(icons).signal05a,accent:`secondary`,onClick:_cache[9]||=$event=>gotoOrganizations(unref(cargoOverviewStore).cargoData.facility.organization.id)},{default:withCtx(()=>[..._cache[19]||=[createTextVNode(`Progress`,-1)]]),_:1},8,[`icon`])]),_:1})):createCommentVNode(``,!0),unref(cargoOverviewStore).cargoData.facility.organization?(openBlock(),createElementBlock(`div`,_hoisted_29$7,[createVNode(unref(bngIcon_default),{class:`progress-icon`,type:unref(icons).peopleOutline},null,8,[`type`]),unref(cargoOverviewStore).cargoData.facility.organization?(openBlock(),createElementBlock(`div`,_hoisted_30$7,[createVNode(unref(bngProgressBar_default),{class:`bar`,gradient:``,value:unref(cargoOverviewStore).cargoData.facility.organization.reputation.value,max:unref(cargoOverviewStore).cargoData.facility.organization.reputation.nextThreshold,min:unref(cargoOverviewStore).cargoData.facility.organization.prevThreshold,showValueLabel:!1},null,8,[`value`,`max`,`min`])])):createCommentVNode(``,!0)])):createCommentVNode(``,!0),createVNode(unref(aspectRatio_default),{class:`image`,ratio:`5:3`,"external-image":unref(cargoOverviewStore).cargoData.facility.preview},null,8,[`external-image`]),createVNode(unref(bngCardHeading_default),{type:`ribbon`,class:`cardHeading`},{default:withCtx(()=>[..._cache[20]||=[createTextVNode(` Facility Information `,-1)]]),_:1}),createBaseVNode(`div`,{class:`content text-justify`,innerHTML:unref(content_exports).bbcode.parse(unref(cargoOverviewStore).cargoData.facility.longDescription)},null,8,_hoisted_31$7)]),_:1}),createBaseVNode(`div`,_hoisted_32$7,[(openBlock(!0),createElementBlock(Fragment,null,renderList(unref(cargoOverviewStore).cargoData.facilityPanels,(panel,index)=>(openBlock(),createBlock(unref(bngCard_default),{key:index,class:`panel`},{default:withCtx(()=>[createVNode(unref(bngCardHeading_default),{type:`ribbon`,class:`cardHeadingFlex`},{default:withCtx(()=>[createBaseVNode(`span`,null,[createBaseVNode(`span`,null,toDisplayString(panel.heading)+`:\xA0`,1),panel.skillInfo?(openBlock(),createElementBlock(`span`,_hoisted_33$7,toDisplayString(panel.skillInfo.unlocked?_ctx.$ctx_t(panel.skillInfo.levelLabel):``),1)):createCommentVNode(``,!0)]),panel.skillInfo?(openBlock(),createBlock(unref(bngButton_default),{key:0,icon:unref(icons).signal05a,accent:`secondary`,onClick:$event=>gotoSkillProgress(panel)},{default:withCtx(()=>[..._cache[21]||=[createTextVNode(`Progress`,-1)]]),_:1},8,[`icon`,`onClick`])):createCommentVNode(``,!0)]),_:2},1024),panel.skillInfo?(openBlock(),createElementBlock(`div`,_hoisted_34$7,[createVNode(unref(bngIcon_default),{class:`progress-icon`,type:unref(icons)[panel.skillInfo.icon]},null,8,[`type`]),createBaseVNode(`div`,_hoisted_35$6,[createVNode(unref(bngProgressBar_default),{class:`bar`,gradient:``,value:panel.skillInfo.max==-1?1:panel.skillInfo.value-panel.skillInfo.min,max:panel.skillInfo.max==-1?1:panel.skillInfo.max-panel.skillInfo.min,showValueLabel:!0,valueLabelFormat:panel.skillInfo.max===-1?`Max`:panel.skillInfo.value+` XP`},null,8,[`value`,`max`,`valueLabelFormat`])])])):createCommentVNode(``,!0),createBaseVNode(`div`,_hoisted_36$6,[createBaseVNode(`span`,null,[createVNode(unref(bngIcon_default),{type:unref(icons).info},null,8,[`type`]),createTextVNode(` `+toDisplayString(panel.description),1)]),createBaseVNode(`div`,_hoisted_37$5,[(openBlock(!0),createElementBlock(Fragment,null,renderList(panel.filterValueButtons,filterKey=>(openBlock(),createBlock(FilterCard_default,{key:filterKey,filter:unref(cargoOverviewStore).filterSetsByValue[filterKey]},null,8,[`filter`]))),128))])])]),_:2},1024))),128))])])]),_:1}))])):createCommentVNode(``,!0)],32)]),_:1},512))}},CargoOverviewMain_default=__plugin_vue_export_helper_default(_sfc_main$256,[[`__scopeId`,`data-v-719883ab`]]),_hoisted_1$226={class:`unlock-wrapper`,"bng-ui-scope":`cargoUnlockPopup`},_hoisted_2$184={class:`cardContent`},_hoisted_3$162={class:`acceptButton`},__default__$1={wrapper:{fade:!0,blur:!0,style:popupContainer.default},position:[popupPosition.center,popupPosition.center]},_sfc_main$255=Object.assign(__default__$1,{__name:`UnlockPopup`,props:{reward:Object},emits:[`return`],setup(__props,{emit:__emit}){useUINavScope(`cargoUnlockPopup`);let emit$1=__emit,acceptClickHandler=()=>{emit$1(`return`,!0)};return(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$226,[createVNode(unref(bngCard_default),null,{default:withCtx(()=>[createVNode(unref(bngCardHeading_default),{type:`ribbon`},{default:withCtx(()=>[..._cache[0]||=[createTextVNode(` Level Up! `,-1)]]),_:1}),createBaseVNode(`div`,_hoisted_2$184,[createBaseVNode(`h3`,null,toDisplayString(__props.reward.unlockPopupHeader),1),_cache[2]||=createTextVNode(` Unlocks: `,-1),(openBlock(!0),createElementBlock(Fragment,null,renderList(__props.reward.branchLevels[__props.reward.animationData.level-1].unlocks,item=>(openBlock(),createBlock(UnlockCard_default,{class:`tier-unlocks-item`,data:item},null,8,[`data`]))),256)),createBaseVNode(`div`,_hoisted_3$162,[withDirectives((openBlock(),createBlock(unref(bngButton_default),{accent:unref(ACCENTS).primary,onClick:acceptClickHandler},{default:withCtx(()=>[createVNode(unref(bngBinding_default),{"ui-event":`ok`,deviceMask:`xinput`}),_cache[1]||=createBaseVNode(`span`,null,`Continue`,-1)]),_:1},8,[`accent`])),[[unref(BngOnUiNav_default),acceptClickHandler,`ok`]])])])]),_:1})]))}}),UnlockPopup_default=__plugin_vue_export_helper_default(_sfc_main$255,[[`__scopeId`,`data-v-127ed650`]]),_hoisted_1$225={class:`reward-wrapper`},_hoisted_2$183={class:`card-content`},_hoisted_3$161={class:`scroll-wrapper`},_hoisted_4$135={key:0},_hoisted_5$118={class:`cargo-wrapper`},_hoisted_6$101={class:`header`},_hoisted_7$88={class:`amount-controls`},_hoisted_8$73={class:`amount`},_hoisted_9$66={class:`card-content`},_hoisted_10$57={style:{display:`flex`}},_hoisted_11$51={style:{float:`left`}},_hoisted_12$40={key:0,class:`rewards-breakdown-container padding-bottom`},_hoisted_13$33={class:`grid-wrapper`},_hoisted_14$31={class:`grid-row grid`},_hoisted_15$30={class:`label primary`},_hoisted_16$30={class:`rewards primary`},_hoisted_17$24={class:`grid-wrapper wide`},_hoisted_18$21={class:`grid`},_hoisted_19$18={class:`label secondary`},_hoisted_20$15={class:`rewards secondary`},_hoisted_21$14={class:`grid-row grid`},_hoisted_22$12={class:`rewards primary`},_hoisted_23$11={key:1,class:`rewards-breakdown-container padding-bottom`},_hoisted_24$10={class:`grid-wrapper`},_hoisted_25$9={key:0,class:`grid-row grid`},_hoisted_26$7={class:`rewards primary`},_hoisted_27$7={key:1,class:`grid-row grid`},_hoisted_28$6={class:`rewards primary`},_hoisted_29$6={key:2,class:`grid-row grid`},_hoisted_30$6={class:`rewards primary`},_hoisted_31$6={key:3,class:`grid-row grid`},_hoisted_32$6={class:`rewards primary`},_hoisted_33$6={class:`grid-row grid`},_hoisted_34$6={class:`rewards primary`},_hoisted_35$5={style:{float:`left`}},_hoisted_36$5={key:0,style:{float:`left`}},_hoisted_37$4={key:0,class:`numberReward`},_hoisted_38$4={key:1,class:`numberReward`},_hoisted_39$4={key:2},_hoisted_40$3={key:1,style:{float:`left`,width:`100%`,padding:`0.2em`}},_hoisted_41$3={key:2},__default__={wrapper:{fade:!0,blur:!0,style:popupContainer.transparent},position:[popupPosition.center,popupPosition.center]},_sfc_main$254=Object.assign(__default__,{__name:`CargoDropOff`,props:{facilityId:String,parkingSpotPath:String},setup(__props){let ANIMATION_START_DELAY=400,ANIMATION_DURATION=3e3,ANIMATION_UPDATE_RATE=30,BAR_COLOR_DEFAULT=`#ff6600`,BAR_COLOR_ADDITION=`#ff6600`,BAR_COLOR_SUBTRACTION=`#c00000`,MODES={wait:`wait`,cargoSelection:`cargoSelection`,results:`results`},cargoOverviewStore=useCargoOverviewStore();useUINavScope(`cargoDropOff`);let props=__props,{events:events$3}=useBridge(),mode=ref(MODES.wait),data=ref({}),summary=ref([]),showConfirmDelay=ref(!1),confirmButtonEnabled=ref(!1),confirmButtonTimer=ref(0),confirmButtonTimerId=0,rewardAnimationIndex=ref(-1),animationSkipped=!1,showUnloadingDelay=!0,getLevelFromValue=(value,reward)=>{let branchLevels=reward.branchLevels,levelIndex=-1;for(let i=0;i=levelData.requiredValue&&(levelIndex=i)}let maxLevel=!(branchLevels[levelIndex+1]&&branchLevels[levelIndex+1].requiredValue!=null),displayValue=value-branchLevels[levelIndex].requiredValue;return{min:0,max:maxLevel?displayValue:branchLevels[levelIndex+1].requiredValue-branchLevels[levelIndex].requiredValue,displayValue,levelLabel:reward.type==`reputation`?branchLevels[levelIndex].label+` (Level `+(levelIndex-1)+`)`:branchLevels[levelIndex].levelLabel,level:levelIndex+1,maxLevel}},confirm=()=>{rewardAnimationIndex.value<0?confirmButtonEnabled.value&&confirmDropOff():skipAnimations()},getDeliveryList=()=>summary.value.detailledList.map(delivery=>delivery.label).join(`, `),getNiceTime=()=>confirmButtonTimer.value>0?confirmButtonTimer.value.toFixed(1)+`s remaining...`:`Done!`,exit=()=>{window.bngVue.gotoGameState(`play`)};function updateDisplayValue(reward){if(reward.branchLevels&&reward.branchLevels.length){let displayData=getLevelFromValue(reward.animationData.smoothedValue,reward);reward.animationData.max=displayData.max,reward.animationData.displayValue=displayData.displayValue,reward.animationData.levelLabel=displayData.levelLabel,reward.animationData.level=displayData.level,reward.animationData.maxLevel=displayData.maxLevel;let displayDataBefore=getLevelFromValue(reward.animationData.value-reward.rewardAmount,reward);displayData.level==displayDataBefore.level?(reward.animationData.displayValueBefore=displayDataBefore.displayValue,displayData.displayValue>=displayDataBefore.displayValue?(reward.valueColor=BAR_COLOR_ADDITION,reward.valueBeforeColor=BAR_COLOR_DEFAULT):(reward.valueBeforeColor=BAR_COLOR_SUBTRACTION,reward.valueColor=BAR_COLOR_DEFAULT)):displayData.level>displayDataBefore.level?(reward.animationData.displayValueBefore=0,reward.valueColor=BAR_COLOR_ADDITION,reward.valueBeforeColor=BAR_COLOR_DEFAULT):(reward.animationData.displayValueBefore=displayData.max,reward.valueColor=BAR_COLOR_DEFAULT,reward.valueBeforeColor=BAR_COLOR_SUBTRACTION)}}let startSmoothingValue=(reward,duration)=>{reward.animationData.numStep=(reward.animationData.value-reward.animationData.smoothedValue)/duration*30,clearInterval(reward.animationData.numTimer),reward.animationData.numTimer=setInterval(()=>{reward.animationData.smoothedValue+=reward.animationData.numStep,(reward.animationData.numStep>0?reward.animationData.smoothedValue>=reward.animationData.value:reward.animationData.smoothedValue<=reward.animationData.value)&&(Lua_default.career_modules_delivery_progress.activateSound(``,!1),reward.animationData.smoothedValue=reward.animationData.value,reward.animationData.numStep=0,clearInterval(reward.animationData.numTimer)),reward.highlight=reward.animationData.numStep!=0,updateDisplayValue(reward)},30)};async function openNewLevelPopup(reward){Lua_default.Engine.Audio.playOnce(`AudioGui`,`event:>UI>Career>Progress_LevelUp`),await addPopup(UnlockPopup_default,{reward}).promise,startProgressBarAnimation()}function didPlayerLevelUp(reward){let levelBefore=0,levelAfter=0;return reward.branchLevels&&reward.branchLevels.length&&(levelBefore=getLevelFromValue(reward.animationData.value-reward.rewardAmount,reward).level,levelAfter=getLevelFromValue(reward.animationData.value,reward).level),levelBeforeopenNewLevelPopup(reward),duration):setTimeout(startProgressBarAnimation,duration+400);return}rewardAnimationIndex.value=-1}}let start=()=>{getUINavServiceInstance().activate(),getUINavServiceInstance().clearFilteredEvents(),Lua_default.career_modules_delivery_general.setDeliveryTimePaused(!0),Lua_default.career_modules_delivery_cargoScreen.requestDropOffData(props.facilityId,props.parkingSpotPath)},kill=()=>{Lua_default.career_modules_delivery_general.setDeliveryTimePaused(!1),events$3.off(`SetDeliveryDropOffCargoSelection`),events$3.off(`SetDeliveryDropOffRewardResult`),clearInterval(confirmButtonTimerId),Lua_default.career_modules_delivery_cargoScreen.dropOffPopupClosed(mode.value)},confirmSelection=()=>{let confirmedCargoIds=[];data.value.customAmountPerMaterialType.forEach(info=>{info.items.forEach(item=>{item.amountSelector>0&&confirmedCargoIds.push({id:item.ids[0],amount:item.amountSelector})})});let confirmedDropOffs={confirmedCargoIds,confirmedOfferIds:[]};console.log(confirmedDropOffs),Lua_default.career_modules_delivery_cargoScreen.confirmDropOffData(confirmedDropOffs,props.facilityId,props.parkingSpotPath)},confirmDropOff=()=>{exit()},branchInfo;function rewardMapToRewardList(rewards){let newRewards=[];for(let key in rewards){let rewardInfo={attributeKey:key,rewardAmount:rewards[key],order:branchInfo[key].order,animationData:branchInfo[key].animationData,branchLevels:branchInfo[key].branchLevels,showLevelUpPopup:branchInfo[key].showLevelUpPopup,unlockPopupHeader:branchInfo[key].unlockPopupHeader,type:branchInfo[key].type};branchInfo[key].icon&&(rewardInfo.icon=branchInfo[key].icon),newRewards.push(rewardInfo)}return newRewards.sort((a$1,b)=>a$1.order-b.order),newRewards}let cargoBySummaryId=[],calculateSummary=()=>{let simpleBreakdownRewardsByType={base:[],bonus:[],loaner:[],branch:[]};summary.value={detailledList:[],total:{label:`Total`,rewards:{}}};let totalRewards={};for(let id in cargoBySummaryId){let group=cargoBySummaryId[id],first=group.list[0],totalCount=0;for(let cargo of group.list)totalCount+=1;let sum={label:first.name,rewards:rewardMapToRewardList(first.originalRewards),breakdown:[]};for(let i=0;i0&&summary.value.detailledList.push(sum)}if(data.value.rewardOffers.length)for(let veh of data.value.rewardOffers){let sum={label:veh.offer.name,rewards:rewardMapToRewardList(veh.originalRewards),breakdown:[]};if(simpleBreakdownRewardsByType.base.push(veh.originalRewards),veh.breakdown.length)for(let bd of veh.breakdown)sum.breakdown.push({label:bd.label,rewards:rewardMapToRewardList(bd.rewards)}),bd.simpleBreakdownType&&(simpleBreakdownRewardsByType[bd.simpleBreakdownType]||(simpleBreakdownRewardsByType[bd.simpleBreakdownType]=[]),simpleBreakdownRewardsByType[bd.simpleBreakdownType].push(bd.rewards));summary.value.detailledList.push(sum)}for(let type in simpleBreakdownRewardsByType){let sum={};for(let elem of simpleBreakdownRewardsByType[type])for(let attKey in elem)sum[attKey]||(sum[attKey]=0),sum[attKey]+=elem[attKey];simpleBreakdownRewardsByType[type]=rewardMapToRewardList(sum)}summary.value.simpleBreakdown=simpleBreakdownRewardsByType;for(let row of summary.value.detailledList){for(let elem of row.rewards)totalRewards[elem.attributeKey]||(totalRewards[elem.attributeKey]=0),totalRewards[elem.attributeKey]+=elem.rewardAmount;for(let bd of row.breakdown)for(let elem of bd.rewards)totalRewards[elem.attributeKey]||(totalRewards[elem.attributeKey]=0),totalRewards[elem.attributeKey]+=elem.rewardAmount}summary.value.total.rewards=rewardMapToRewardList(totalRewards);let counter$1=0;for(let reward of summary.value.total.rewards)reward.animationData.id!=`missing`&&(reward.animationOrderIndex=counter$1,reward.animationData.smoothedValue=reward.animationData.value-reward.rewardAmount,reward.animationData.numStep=0,reward.highlight=!1,updateDisplayValue(reward),counter$1++);rewardAnimationIndex.value=-1,animationSkipped=!1};events$3.on(`SetDeliveryDropOffCargoSelection`,dd=>{data.value=dd,mode.value=MODES.cargoSelection,branchInfo=dd.branchInfo,showUnloadingDelay=dd.unloadingDelay>.1,data.value.playerVehicleData.length&&data.value.customAmountPerMaterialType.forEach(info=>{let remainingFreeAmount=info.storage.capacity-info.storage.storedVolume;info.items.sort((a$1,b)=>a$1.slots-b.slots),info.items.forEach(item=>{item.amountSelectorPerSlot=item.type===`fluid`||item.type===`dryBulk`,item.maxCount=item.ids.length,item.amountSelectorPerSlot&&(item.maxCount=item.slots),item.amountSelector=ref(Math.max(0,Math.min(item.maxCount,remainingFreeAmount))),remainingFreeAmount-=item.amountSelector,item.showAmountSelector=!0,item.loadSliderMax=Math.min(item.maxCount,info.storage.capacity-info.storage.storedVolume)}),info.meta={type:`container`,usedCargoSlots:info.storage.storedVolume,totalCargoSlots:info.storage.capacity,fillPercent:info.storage.storedVolume/info.storage.capacity,icon:info.material.icon},info.meta.usedCargoSlots=info.storage.storedVolume,info.items.forEach(item=>{info.meta.usedCargoSlots+=item.amountSelector}),info.meta.fillPercentHighlight=info.meta.usedCargoSlots/info.storage.capacity,info.storage.capacity<=info.storage.storedVolume&&(info.isFull=!0)})});let updateSliderAmounts=(info,changedItem)=>{info.meta.usedCargoSlots=info.storage.storedVolume,info.items.forEach(item=>{info.meta.usedCargoSlots+=item.amountSelector});let tooMuch=info.meta.usedCargoSlots-info.meta.totalCargoSlots;tooMuch>0&&(info.items.reverse(),info.items.forEach(item=>{if(item!==changedItem){let before=item.amountSelector;item.amountSelector=Math.max(0,item.amountSelector-tooMuch);let diff=item.amountSelector-before;tooMuch+=diff}}),info.items.reverse()),info.meta.usedCargoSlots=info.storage.storedVolume,info.items.forEach(item=>{info.meta.usedCargoSlots+=item.amountSelector}),info.meta.fillPercentHighlight=info.meta.usedCargoSlots/info.storage.capacity};return events$3.on(`SetDeliveryDropOffRewardResult`,dd=>{if(console.log(`setDropOffRewardResult`,dd),data.value=dd,branchInfo=dd.branchInfo,mode.value=MODES.results,confirmButtonEnabled.value=!0,showConfirmDelay.value=!1,dd.unloadingDelay>.1){confirmButtonEnabled.value=!1,confirmButtonTimer.value=dd.unloadingDelay,showConfirmDelay.value=!0;let endTime=Date.now()+confirmButtonTimer.value*1e3,countdown=()=>{let timeLeft=(endTime-Date.now())/1e3;timeLeft>0?(confirmButtonTimer.value=timeLeft,confirmButtonTimerId=requestAnimationFrame(countdown)):(confirmButtonTimer.value=0,confirmButtonEnabled.value=!0)};confirmButtonTimerId=requestAnimationFrame(countdown),showUnloadingDelay=!0}else showUnloadingDelay=!1;if(dd.rewardParcels.length)for(let cargo of dd.rewardParcels)cargoBySummaryId[cargo.summaryId]||(cargoBySummaryId[cargo.summaryId]={list:[],display:{}}),cargoBySummaryId[cargo.summaryId].list.push(cargo);calculateSummary(),setTimeout(startProgressBarAnimation,400)}),onMounted(start),onUnmounted(kill),(_ctx,_cache)=>mode.value===MODES.wait?createCommentVNode(``,!0):withDirectives((openBlock(),createBlock(unref(layoutSingle_default),{key:0,class:`cargo-drop-off-wrapper`,"bng-ui-scope":`cargoDropOff`},{default:withCtx(()=>[createBaseVNode(`div`,_hoisted_1$225,[mode.value===MODES.cargoSelection?(openBlock(),createBlock(unref(bngCard_default),{key:0},{buttons:withCtx(()=>[createVNode(unref(bngButton_default),{onClick:confirmSelection},{default:withCtx(()=>[createVNode(unref(bngBinding_default),{"ui-event":`ok`,deviceMask:`xinput`}),_cache[4]||=createBaseVNode(`span`,null,`Confirm Selection`,-1)]),_:1})]),default:withCtx(()=>[createVNode(unref(careerStatus_default),{class:`career-status`}),createVNode(unref(bngCardHeading_default),{type:`ribbon`},{default:withCtx(()=>[..._cache[3]||=[createTextVNode(`Dropping off...`,-1)]]),_:1}),createBaseVNode(`div`,_hoisted_2$183,[createVNode(unref(bngPropVal_default),{class:`limited-capacity-info`,valueLabel:`This facility has limited capacity for cargo.`,iconType:unref(icons).info},null,8,[`iconType`]),createBaseVNode(`div`,_hoisted_3$161,[(openBlock(!0),createElementBlock(Fragment,null,renderList(data.value.customAmountPerMaterialType,info=>(openBlock(),createBlock(CardGroup_default,{class:`fullwidth-group`,label:info.material.name,meta:info.meta},{default:withCtx(()=>[info.isFull?(openBlock(),createElementBlock(`div`,_hoisted_4$135,[createVNode(unref(bngPropVal_default),{valueLabel:`The storage for this material is completely filled. Come back later.`,iconType:unref(icons).abandon},null,8,[`iconType`])])):createCommentVNode(``,!0),(openBlock(!0),createElementBlock(Fragment,null,renderList(info.items,item=>(openBlock(),createElementBlock(`div`,_hoisted_5$118,[createBaseVNode(`div`,_hoisted_6$101,[createVNode(unref(bngPropVal_default),{valueLabel:item.originName,keyLabel:`Origin`,iconType:unref(icons).locationSource},null,8,[`valueLabel`,`iconType`]),createVNode(unref(bngPropVal_default),{valueLabel:item.containerName,keyLabel:`Container`,iconType:unref(icons).cardboardBox},null,8,[`valueLabel`,`iconType`])]),createBaseVNode(`div`,_hoisted_7$88,[createVNode(unref(bngButton_default),{disabled:info.isFull,class:`less`,iconLeft:unref(icons).minus,accent:`text`,onClick:_cache[0]||=$event=>_ctx.less(_ctx.target)},null,8,[`disabled`,`iconLeft`]),createVNode(unref(bngSlider_default),{disabled:info.isFull,class:`slider`,min:0,max:item.loadSliderMax,modelValue:item.amountSelector,"onUpdate:modelValue":$event=>item.amountSelector=$event,step:1,onChange:$event=>updateSliderAmounts(info,item)},null,8,[`disabled`,`max`,`modelValue`,`onUpdate:modelValue`,`onChange`]),createVNode(unref(bngButton_default),{disabled:info.isFull,class:`more`,iconLeft:unref(icons).plus,accent:`text`,onClick:_cache[1]||=$event=>_ctx.more(_ctx.target)},null,8,[`disabled`,`iconLeft`]),createBaseVNode(`div`,_hoisted_8$73,toDisplayString(item.amountSelector)+` / `+toDisplayString(item.slots),1)])]))),256))]),_:2},1032,[`label`,`meta`]))),256))])])]),_:1})):createCommentVNode(``,!0),mode.value===MODES.results?(openBlock(),createBlock(unref(bngCard_default),{key:1},{buttons:withCtx(()=>[withDirectives((openBlock(),createBlock(unref(bngButton_default),{disabled:rewardAnimationIndex.value<0&&!confirmButtonEnabled.value,onClick:confirm},{default:withCtx(()=>[createVNode(unref(bngBinding_default),{deviceMask:`xinput`}),createBaseVNode(`span`,null,toDisplayString(rewardAnimationIndex.value<0?`Continue`:`Skip`),1)]),_:1},8,[`disabled`])),[[unref(BngFocusIf_default),rewardAnimationIndex.value==0]])]),default:withCtx(()=>[createVNode(unref(bngCardHeading_default),{type:`ribbon`},{default:withCtx(()=>[..._cache[5]||=[createTextVNode(`Delivery Complete!`,-1)]]),_:1}),createBaseVNode(`div`,_hoisted_9$66,[createBaseVNode(`div`,_hoisted_10$57,[createBaseVNode(`h3`,_hoisted_11$51,`Delivered: `+toDisplayString(getDeliveryList()),1),summary.value.detailledList.length>1?(openBlock(),createBlock(unref(bngSwitch_default),{key:0,style:{float:`right`},modelValue:unref(cargoOverviewStore).detailedDropOff,"onUpdate:modelValue":_cache[2]||=$event=>unref(cargoOverviewStore).detailedDropOff=$event},{default:withCtx(()=>[..._cache[6]||=[createTextVNode(`Detailed`,-1)]]),_:1},8,[`modelValue`])):createCommentVNode(``,!0)]),summary.value.detailledList.length<=1||unref(cargoOverviewStore).detailedDropOff?(openBlock(),createElementBlock(`div`,_hoisted_12$40,[createBaseVNode(`div`,_hoisted_13$33,[(openBlock(!0),createElementBlock(Fragment,null,renderList(summary.value.detailledList,result=>(openBlock(),createElementBlock(`div`,_hoisted_14$31,[createBaseVNode(`div`,_hoisted_15$30,toDisplayString(result.label),1),createBaseVNode(`div`,_hoisted_16$30,[createVNode(RewardsPills_default,{rewards:result.rewards},null,8,[`rewards`])]),createBaseVNode(`div`,_hoisted_17$24,[(openBlock(!0),createElementBlock(Fragment,null,renderList(result.breakdown,breakdown=>(openBlock(),createElementBlock(`div`,_hoisted_18$21,[createBaseVNode(`div`,_hoisted_19$18,toDisplayString(breakdown.label),1),createBaseVNode(`div`,_hoisted_20$15,[createVNode(RewardsPills_default,{rewards:breakdown.rewards},null,8,[`rewards`])])]))),256))])]))),256)),createVNode(unref(bngDivider_default)),createBaseVNode(`div`,_hoisted_21$14,[_cache[7]||=createBaseVNode(`div`,{class:`label primary`},`Summary`,-1),createBaseVNode(`div`,_hoisted_22$12,[createVNode(RewardsPills_default,{rewards:summary.value.total.rewards},null,8,[`rewards`])])])])])):(openBlock(),createElementBlock(`div`,_hoisted_23$11,[createBaseVNode(`div`,_hoisted_24$10,[summary.value.simpleBreakdown.base.length?(openBlock(),createElementBlock(`div`,_hoisted_25$9,[_cache[8]||=createBaseVNode(`div`,{class:`label primary`},`Base Rewards`,-1),createBaseVNode(`div`,_hoisted_26$7,[createVNode(RewardsPills_default,{rewards:summary.value.simpleBreakdown.base},null,8,[`rewards`])])])):createCommentVNode(``,!0),summary.value.simpleBreakdown.bonus.length?(openBlock(),createElementBlock(`div`,_hoisted_27$7,[_cache[9]||=createBaseVNode(`div`,{class:`label primary`},`Bonuses`,-1),createBaseVNode(`div`,_hoisted_28$6,[createVNode(RewardsPills_default,{rewards:summary.value.simpleBreakdown.bonus},null,8,[`rewards`])])])):createCommentVNode(``,!0),summary.value.simpleBreakdown.loaner.length?(openBlock(),createElementBlock(`div`,_hoisted_29$6,[_cache[10]||=createBaseVNode(`div`,{class:`label primary`},`Loaner Cuts`,-1),createBaseVNode(`div`,_hoisted_30$6,[createVNode(RewardsPills_default,{rewards:summary.value.simpleBreakdown.loaner},null,8,[`rewards`])])])):createCommentVNode(``,!0),summary.value.simpleBreakdown.branch.length?(openBlock(),createElementBlock(`div`,_hoisted_31$6,[_cache[11]||=createBaseVNode(`div`,{class:`label primary`},`Logistics Level Multiplier`,-1),createBaseVNode(`div`,_hoisted_32$6,[createVNode(RewardsPills_default,{rewards:summary.value.simpleBreakdown.branch},null,8,[`rewards`])])])):createCommentVNode(``,!0),createVNode(unref(bngDivider_default)),createBaseVNode(`div`,_hoisted_33$6,[_cache[12]||=createBaseVNode(`div`,{class:`label primary`},`Summary`,-1),createBaseVNode(`div`,_hoisted_34$6,[createVNode(RewardsPills_default,{rewards:summary.value.total.rewards},null,8,[`rewards`])])])])])),(openBlock(!0),createElementBlock(Fragment,null,renderList(summary.value.total.rewards,reward=>(openBlock(),createElementBlock(`div`,null,[reward.animationData.id==`missing`?createCommentVNode(``,!0):(openBlock(),createElementBlock(`div`,{key:0,class:normalizeClass(reward.animationData.numStep==0?``:`animate-progress-background`),style:{display:`flex`,"padding-bottom":`0.5em`,"padding-left":`0.2em`,"padding-right":`0.2em`}},[createBaseVNode(`div`,_hoisted_35$5,[reward.icon?(openBlock(),createBlock(unref(bngIcon_default),{key:0,style:{"padding-top":`0.5em`,"padding-right":`0.3em`},type:unref(icons)[reward.icon]},null,8,[`type`])):createCommentVNode(``,!0)]),reward.animationData.type==`number`?(openBlock(),createElementBlock(`div`,_hoisted_36$5,[reward.attributeKey==`money`?(openBlock(),createElementBlock(`div`,_hoisted_37$4,[createVNode(unref(bngUnit_default),{money:reward.animationData.smoothedValue,"no-icon":``},null,8,[`money`])])):reward.attributeKey==`beamXP`?(openBlock(),createElementBlock(`div`,_hoisted_38$4,[createVNode(unref(bngUnit_default),{beamXP:reward.animationData.smoothedValue,"no-icon":``},null,8,[`beamXP`])])):(openBlock(),createElementBlock(`div`,_hoisted_39$4,toDisplayString(reward.animationData.smoothedValue.toFixed(2)),1))])):(openBlock(),createElementBlock(`div`,_hoisted_40$3,[createVNode(unref(bngProgressBar_default),{headerLeft:_ctx.$t(reward.animationData.name),headerRight:reward.animationData.levelLabel,value:~~reward.animationData.displayValue,"old-value":~~reward.animationData.displayValueBefore,max:reward.animationData.max,showValueLabel:!0,valueColor:reward.valueColor,oldValueColor:reward.valueBeforeColor,valueLabelFormat:reward.animationData.maxLevel?~~reward.animationData.displayValue+`\xA0XP`:`#value#\xA0XP`,"animate-difference":!0},null,8,[`headerLeft`,`headerRight`,`value`,`old-value`,`max`,`valueColor`,`oldValueColor`,`valueLabelFormat`])]))],2))]))),256)),unref(showUnloadingDelay)?(openBlock(),createElementBlock(`div`,_hoisted_41$3,[createVNode(unref(bngDivider_default)),_cache[13]||=createTextVNode(` Unloading Delay `,-1),createVNode(unref(bngProgressBar_default),{class:`timer`,value:data.value.unloadingDelay-confirmButtonTimer.value,max:data.value.unloadingDelay,min:0,valueLabelFormat:getNiceTime()},null,8,[`value`,`max`,`valueLabelFormat`])])):createCommentVNode(``,!0)])]),_:1})):createCommentVNode(``,!0)])]),_:1})),[[unref(BngBlur_default)],[unref(BngOnUiNav_default),confirm,`back,menu`]])}}),CargoDropOff_default=__plugin_vue_export_helper_default(_sfc_main$254,[[`__scopeId`,`data-v-698d9552`]]);const useComputerStore=defineStore(`computer`,()=>{let computerData=ref({}),activeVehicleIndex=ref(0),activeInventoryId=computed(()=>computerData.value.vehicles&&computerData.value.vehicles[activeVehicleIndex.value]?computerData.value.vehicles[activeVehicleIndex.value].inventoryId:`0`),generalComputerFunctions=computed(()=>{if(!computerData.value.computerFunctions)return[];let result=[];return result=Object.values(computerData.value.computerFunctions.general),result.sort((a$1,b)=>a$1.order!=null&&b.order!=null?a$1.order{if(!computerData.value.computerFunctions)return{};let result={};for(let[inventoryId,computerFunctions]of Object.entries(computerData.value.computerFunctions.vehicleSpecific)){let sortedFunctions=Object.values(computerFunctions);sortedFunctions.sort((a$1,b)=>a$1.order!=null&&b.order!=null?a$1.order{computerData.value=data,(computerData.value.vehicles&&computerData.value.vehicles.length<=activeVehicleIndex.value||computerData.value.resetActiveVehicleIndex)&&(activeVehicleIndex.value=0)};return{activeVehicleIndex,activeInventoryId,computerData,generalComputerFunctions,vehicleSpecificComputerFunctions,requestComputerData:()=>{Lua_default.career_modules_computer.getComputerUIData().then(setComputerData)},computerButtonCallback:async(computerFunctionId,inventoryId)=>{await Lua_default.career_modules_computer.computerButtonCallback(computerFunctionId,inventoryId?Number(inventoryId):void 0)},switchActiveVehicle:offset$2=>{activeVehicleIndex.value=(activeVehicleIndex.value+offset$2+computerData.value.vehicles.length)%computerData.value.vehicles.length},onMenuClosed:()=>{Lua_default.career_modules_computer.onMenuClosed()}}});var _hoisted_1$224={class:`task-header`},_hoisted_2$182={class:`description`},_sfc_main$253={__name:`TaskHeader`,props:{title:[String,Object],description:[String,Object]},setup(__props){let props=__props,slots=useSlots(),titleParsed=computed(()=>parse$1($translate.contextTranslate(props.title,!0))),descriptionParsed=computed(()=>parse$1($translate.contextTranslate(props.description)));return(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$224,[createBaseVNode(`div`,null,[unref(slots).title?renderSlot(_ctx.$slots,`title`,{key:0},void 0,!0):__props.title?(openBlock(),createBlock(unref(dynamicComponent_default),{key:1,template:titleParsed.value},null,8,[`template`])):createCommentVNode(``,!0)]),createBaseVNode(`div`,_hoisted_2$182,[unref(slots).description?renderSlot(_ctx.$slots,`description`,{key:0},void 0,!0):__props.description?(openBlock(),createBlock(unref(dynamicComponent_default),{key:1,template:descriptionParsed.value},null,8,[`template`])):createCommentVNode(``,!0)])]))}},TaskHeader_default=__plugin_vue_export_helper_default(_sfc_main$253,[[`__scopeId`,`data-v-ae9fa7fe`]]),_hoisted_1$223={class:`task-message`},_hoisted_2$181={class:`label`},_hoisted_3$160={class:`description`},_sfc_main$252={__name:`TaskMessage`,props:{label:String,description:String},setup(__props){let props=__props,slots=useSlots(),labelParsed=computed(()=>parse$1($translate.contextTranslate(props.label,!0))),descriptionParsed=computed(()=>parse$1($translate.contextTranslate(props.description)));return(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$223,[createBaseVNode(`div`,_hoisted_2$181,[unref(slots).label?renderSlot(_ctx.$slots,`label`,{key:0},void 0,!0):__props.label?(openBlock(),createBlock(unref(dynamicComponent_default),{key:1,template:labelParsed.value},null,8,[`template`])):createCommentVNode(``,!0)]),createBaseVNode(`div`,_hoisted_3$160,[unref(slots).description?renderSlot(_ctx.$slots,`description`,{key:0},void 0,!0):__props.description?(openBlock(),createBlock(unref(dynamicComponent_default),{key:1,template:descriptionParsed.value},null,8,[`template`])):createCommentVNode(``,!0)])]))}},TaskMessage_default=__plugin_vue_export_helper_default(_sfc_main$252,[[`__scopeId`,`data-v-657447b0`]]),_hoisted_1$222=[`data-id`],_sfc_main$251={__name:`TaskList`,props:{header:Object,tasks:Array,settings:{type:Object,default:{animate:!1,animateOnMount:!1,animateOnMountIntervalDelay:.2,animateOnEmpty:!1,animateOnEmptyIntervalDelay:.2,animateNextTask:!1,taskCompleteCallback:{type:Function,required:!1}}}},setup(__props){let props=__props,animationSettings=inject(`animationSettings`,props.settings),previousTasks=ref(null),internalTasks=ref(null),tasksScroller=ref(null),canAnimate=computed(()=>!(!animationSettings.animate||previousTasks.value===null&&!animationSettings.animateOnMount)),nextTask=computed(()=>internalTasks.value.find(x=>x.type===`goal`&&!x.complete&&x.attention)),onBeforeHeaderLeave=el=>{el.style.animationDelay=`0s`},onBeforeLeave=(el,done)=>{el.style.animationDelay=`0s`},onBeforeEnterTask=el=>{let dataId=el.getAttribute(`data-id`),offset$2=props.header?1:0,delay=previousTasks.value===null||previousTasks.value.length===0?animationSettings.animateOnMountIntervalDelay*(Number(dataId)+offset$2):0;el.style.animationDelay=delay+`s`,requestAnimationFrame(()=>{tasksScroller.value&&(tasksScroller.value.scrollTop=tasksScroller.value.scrollHeight)})};onBeforeMount(()=>{(!internalTasks.value||internalTasks.value.length===0)&&(internalTasks.value=unwrapProxy(props.tasks))}),watch(()=>props.tasks,async(newValue,oldValue)=>{internalTasks.value!==null&&(previousTasks.value=internalTasks.value&&internalTasks.value.length>0?unwrapProxy([...internalTasks.value]):[]),internalTasks.value=unwrapProxy(props.tasks)},{deep:!0});function unwrapProxy(reactiveList){return reactiveList.map(x=>Object.assign({},x))}return(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,{class:normalizeClass([`tasks-container`,{animate:unref(animationSettings).animate}])},[createVNode(Transition,{"enter-active-class":`show`,"leave-active-class":`remove`,css:unref(animationSettings).animate,onBeforeLeave:onBeforeHeaderLeave},{default:withCtx(()=>[__props.header?(openBlock(),createElementBlock(`div`,{key:0,class:normalizeClass([`header-wrapper`,{"show-animate":canAnimate.value}])},[createVNode(TaskHeader_default,mergeProps(__props.header,{class:`header`}),null,16)],2)):createCommentVNode(``,!0)]),_:1},8,[`css`]),createBaseVNode(`div`,{class:`tasks-content`,ref_key:`tasksScroller`,ref:tasksScroller},[createVNode(TransitionGroup,{"enter-active-class":`show`,"leave-active-class":`remove`,css:unref(animationSettings).animate,onBeforeLeave,onBeforeEnter:onBeforeEnterTask},{default:withCtx(()=>[(openBlock(!0),createElementBlock(Fragment,null,renderList(internalTasks.value,(task,index)=>(openBlock(),createElementBlock(`div`,{key:task.id,class:normalizeClass([`task-wrapper`,{"show-animate":canAnimate.value,"remove-animate":canAnimate.value}]),"data-id":index},[task.type===`message`?(openBlock(),createBlock(TaskMessage_default,mergeProps({key:0,ref_for:!0},task,{class:`task-card`}),null,16)):task.type===`goal`?(openBlock(),createBlock(TaskGoal_default,mergeProps({key:1,ref_for:!0},task,{class:[`task-card`,{glow:unref(animationSettings).animateNextTask&&nextTask.value&&nextTask.value.id===task.id}]}),null,16,[`class`])):createCommentVNode(``,!0)],10,_hoisted_1$222))),128))]),_:1},8,[`css`])],512)],2))}},TaskList_default=__plugin_vue_export_helper_default(_sfc_main$251,[[`__scopeId`,`data-v-5118e548`]]);const useTasksStore=defineStore(`tasks`,()=>{let header=ref(null),tasks=ref([]),{$game}=useLibStore();$game.events.on(`SetTasklistHeader`,setTasklistHeader),$game.events.on(`SetTasklistTask`,setTasklistTask),$game.events.on(`UpdateTasklistItem`,updateTasklistItem),$game.events.on(`SortTasklistItems`,sortTasklistItems),$game.events.on(`CompleteTasklistGoal`,id=>updateTasklistItem(id,{complete:!0,success:!0})),$game.events.on(`FailTasklistGoal`,id=>updateTasklistItem(id,{complete:!0,success:!1})),$game.events.on(`DiscardTasklistItem`,discardTasklistItem),$game.events.on(`HighlightTasklistItem`,highlightTasklistItem),$game.events.on(`HideCareerTasklist`,hideCareerTasklist),$game.events.on(`ClearTasklist`,clearTasklist);function setTasklistHeader(data){data==null||data==``?header.value=null:header.value={title:data.label,description:data.subtext}}function setTasklistTask(data){let id=data.id===null||data.id===void 0?`default`:data.id,index=tasks.value.findIndex(x=>x.id===id);if(index===-1&&data.clear)return;if(data.clear){tasks.value.splice(index,1);return}let isComplete=data.done!==void 0&&data.done||data.fail!==void 0&&data.fail,isSuccess=data.done!==void 0&&data.done||data.fail!==void 0&&!data.fail,description=data.subtext===0?``:data.subtext;index===-1?tasks.value.push({id:data.id,label:data.label,description,type:data.type,attention:data.attention,complete:isComplete,success:isSuccess}):(tasks.value[index].attention=data.attention,tasks.value[index].complete=isComplete,tasks.value[index].success=isSuccess,data.subtext!==void 0&&(tasks.value[index].description=description),data.label!==void 0&&(tasks.value[index].label=data.label),data.type!==void 0&&(tasks.value[index].type=data.type))}function updateTasklistItem(id,data){let index=tasks.value.findIndex(task=>task.id===id);index!==-1&&Object.keys(data).forEach(key=>{tasks.value[index][key]!==void 0&&(tasks.value[index][key]=data[key])})}function sortTasklistItems(order){let inOrderTasks=[],notInOrderTasks=[];tasks.value.forEach(task=>{order.includes(task.id)?inOrderTasks.push(task):notInOrderTasks.push(task)}),inOrderTasks.sort((a$1,b)=>order.indexOf(a$1.id)-order.indexOf(b.id)),tasks.value=[...inOrderTasks,...notInOrderTasks]}function discardTasklistItem(id,delay){delay!==void 0&&delay>0?setTimeout(()=>{setTasklistTask({id,clear:!0})},delay*1e3):setTasklistTask({id,clear:!0})}function highlightTasklistItem(id,duration){setTasklistTask({id,attention:!0}),duration!==void 0&&duration>0&&setTimeout(()=>{setTasklistTask({id,attention:!1})},duration*1e3)}function hideCareerTasklist(){}function clearTasklist(){header.value=null,tasks.value=[]}return{header,tasks,hasItems:computed(()=>tasks.value.length>0||header.value!==null)}});var _hoisted_1$221={class:`heading-container`},_hoisted_2$180={key:0,class:`status-add`},_hoisted_3$159={class:`content-container`},_hoisted_4$134={class:`main-content`},_hoisted_5$117={class:`main-content-slotted`},_hoisted_6$100={class:`side-content-slotted`},_sfc_main$250={__name:`ComputerWrapper`,props:{title:{type:String,default:`My Computer`},path:Array,wallpaperFull:Boolean,wallpaperHalf:Boolean,back:Boolean,close:Boolean},emits:[`back`,`close`],setup(__props,{expose:__expose,emit:__emit}){useUINavScope(`computer`);let{$game}=useLibStore(),computerStore=useComputerStore(),props=__props,breadcrumbItems=computed(()=>[{label:`Career`,closeAllMenus:!0},{label:computerStore.computerData.facilityName},...(props.path||[]).map(path=>({label:path}))]),elStatus=ref(),store$1=useTasksStore();provide(`animationSettings`,{animate:!0,animateOnMount:!1,animateOnMountIntervalDelay:.2,animateOnEmptyIntervalDelay:.1,animateOnEmpty:!0,animateNextTask:!0,successCallback:playAudio});function playAudio(){$game.lua.Engine.Audio.playOnce(`AudioGui`,`event:>UI>Career>Checkbox`)}__expose({statusUpdate:()=>elStatus.value.updateDisplay()});function breadcrumbClick(item){item.closeAllMenus&&$game.lua.career_career.closeAllMenus()}let emit$1=__emit;return(_ctx,_cache)=>withDirectives((openBlock(),createBlock(unref(layoutSingle_default),{"bng-ui-scope":`computer`,class:`computer-wrapper-layout`},{default:withCtx(()=>[createBaseVNode(`div`,_hoisted_1$221,[createVNode(unref(bngScreenHeadingV2_default),{type:`2`},{preheadings:withCtx(()=>[createVNode(bngBreadcrumbs_default,{class:`breadcrumbs`,simple:``,"disable-last-item":``,"show-back-button":``,navigable:!1,onClick:breadcrumbClick,onBack:_cache[0]||=$event=>emit$1(`back`),items:breadcrumbItems.value},null,8,[`items`])]),default:withCtx(()=>[renderSlot(_ctx.$slots,`title`,{},()=>[createTextVNode(toDisplayString(__props.title),1)],!0)]),_:3}),withDirectives((openBlock(),createBlock(unref(bngCard_default),{class:`status-container`},{default:withCtx(()=>[createVNode(unref(careerStatus_default),{ref_key:`elStatus`,ref:elStatus},null,512),_ctx.$slots.status?(openBlock(),createElementBlock(`div`,_hoisted_2$180,[renderSlot(_ctx.$slots,`status`,{},void 0,!0)])):createCommentVNode(``,!0)]),_:3})),[[unref(BngBlur_default),!0]])]),createBaseVNode(`div`,_hoisted_3$159,[createBaseVNode(`div`,_hoisted_4$134,[createBaseVNode(`div`,_hoisted_5$117,[renderSlot(_ctx.$slots,`default`,{},void 0,!0)]),createBaseVNode(`div`,_hoisted_6$100,[createVNode(unref(TaskList_default),{class:`task-list`,header:unref(store$1).header,tasks:unref(store$1).tasks},null,8,[`header`,`tasks`]),renderSlot(_ctx.$slots,`side`,{},void 0,!0)])])])]),_:3})),[[unref(BngOnUiNav_default),()=>emit$1(`back`),`back`]])}},ComputerWrapper_default=__plugin_vue_export_helper_default(_sfc_main$250,[[`__scopeId`,`data-v-b7460ee1`]]),_hoisted_1$220={class:`indicators-overlay`},_hoisted_2$179={class:`performance-index`},_hoisted_3$158={key:0,class:`lock-reason`},_hoisted_4$133={key:1,class:`lock-time`},_hoisted_5$116={key:1,class:`valueReduced`},_hoisted_6$99={key:0,class:`content`},_hoisted_7$87={class:`header`},_hoisted_8$72={class:`title-section`},_hoisted_9$65={class:`name`},_hoisted_10$56={class:`details`},_hoisted_11$50={class:`location-section`},_hoisted_12$39={class:`location-value`},_hoisted_13$32={key:0,class:`value-section`},_hoisted_14$30={key:0,class:`value-label reduced`},_hoisted_15$29={key:1,class:`value-label`},_hoisted_16$29={key:2,class:`total-value`},_hoisted_17$23={class:`insurance-section`},_hoisted_18$20={class:`insurance-value`},_hoisted_19$17={key:0,class:`warn`},_sfc_main$249=Object.assign({width:100,margin:.25},{__name:`VehicleTileRow`,props:{data:Object,isTutorial:Boolean,selected:Boolean,enableHover:{type:Boolean,default:!0},small:Boolean},setup(__props){let{units}=useBridge(),props=__props,partConditionAvg=computed(()=>{if(!props.data)return 1;if(props.data.partConditions){let conds=Object.values(props.data.partConditions);return conds.reduce((i,c)=>i+c.integrityValue,0)/conds.length}return 1}),colour=computed(()=>props.data?.config?.paints?.[0]?.baseColor??`#ccc`),thumbUrl=computed(()=>props.data.thumbnail?`${props.data.thumbnail}?${props.data.dirtyDate}`:null),location$1=computed(()=>{let res;return res=locked.value&&!locked.value.location?locked.value.reason:props.data.inGarage?`In garage`:props.data.distance?`${units.buildString(`length`,props.data.distance,0)} away`:`Storage`,res}),locked=computed(()=>{let res;if(props.data._message)res={reason:props.data._message};else if(props.data.missingFile)res={reason:`Missing File!`};else if(props.data.timeToAccess){let eta=`${~~(props.data.timeToAccess/60)}:${String(~~props.data.timeToAccess%60).padStart(2,`0`)}`;res=props.data.delayReason===`bought`?{reason:`Out for delivery`,eta}:props.data.delayReason===`repair`?{reason:`Being repaired`,eta}:{reason:`Available in`,eta}}else props.data.needsRepair&&(res={reason:`Needs repair`,location:!0});return res});return(_ctx,_cache)=>__props.data?withDirectives((openBlock(),createElementBlock(`div`,{key:0,class:normalizeClass({"vehicle-tile-row":!0,selected:__props.selected,"hover-enabled":__props.enableHover}),role:`button`},[createBaseVNode(`div`,{class:normalizeClass({preview:!0,locked:locked.value,small:__props.small})},[thumbUrl.value?(openBlock(),createBlock(unref(aspectRatio_default),{key:0,ratio:`16:9`,"external-image":thumbUrl.value,class:`preview-image`},{default:withCtx(()=>[createBaseVNode(`div`,_hoisted_1$220,[__props.data.favorite?withDirectives((openBlock(),createBlock(unref(bngIcon_default),{key:0,type:unref(icons).star,color:`#fd0`},null,8,[`type`])),[[unref(BngTooltip_default),`Favourite`]]):createCommentVNode(``,!0),__props.data.delayReason===`repair`?(openBlock(),createBlock(unref(bngIcon_default),{key:1,type:unref(icons).wrench,color:`#fff`},null,8,[`type`])):(openBlock(),createBlock(unref(bngCondition_default),{key:2,integrity:partConditionAvg.value,"integrity-warning":__props.data.needsRepair,color:colour.value,"show-tooltip":``},null,8,[`integrity`,`integrity-warning`,`color`])),createBaseVNode(`div`,_hoisted_2$179,toDisplayString(__props.data.certificationData&&__props.data.certificationData.vehicleClass?__props.data.certificationData.vehicleClass.performanceIndex.toFixed(0):`N/A`),1)]),locked.value?(openBlock(),createElementBlock(`span`,_hoisted_3$158,toDisplayString(locked.value.reason),1)):createCommentVNode(``,!0),locked.value&&locked.value.eta?(openBlock(),createElementBlock(`span`,_hoisted_4$133,toDisplayString(locked.value.eta),1)):createCommentVNode(``,!0)]),_:1},8,[`external-image`])):createCommentVNode(``,!0),!(__props.data.returnLoanerPermission&&__props.data.returnLoanerPermission.allow)&&__props.data.partConditionAvg<1?(openBlock(),createElementBlock(`span`,_hoisted_5$116,`Value reduced!`)):createCommentVNode(``,!0),__props.data.isInsured?createCommentVNode(``,!0):(openBlock(),createBlock(insurancePerkIcon_default,{key:2,class:`not-insured-overlay`,perkIconData:{iconOnly:__props.data.isInsured,color:`red`,smallText:`Not insured`}},null,8,[`perkIconData`]))],2),__props.data._message?createCommentVNode(``,!0):(openBlock(),createElementBlock(`div`,_hoisted_6$99,[createBaseVNode(`div`,_hoisted_7$87,[createBaseVNode(`div`,_hoisted_8$72,[createBaseVNode(`div`,_hoisted_9$65,toDisplayString(__props.data.niceName),1)])]),createBaseVNode(`div`,_hoisted_10$56,[createBaseVNode(`div`,_hoisted_11$50,[_cache[0]||=createBaseVNode(`span`,{class:`location-label`},`Location:`,-1),createBaseVNode(`span`,_hoisted_12$39,toDisplayString(location$1.value),1)]),__props.data.returnLoanerPermission?.allow?createCommentVNode(``,!0):(openBlock(),createElementBlock(`div`,_hoisted_13$32,[partConditionAvg.value<1?(openBlock(),createElementBlock(`span`,_hoisted_14$30,`Current Value:`)):(openBlock(),createElementBlock(`span`,_hoisted_15$29,`Value:`)),createVNode(unref(bngUnit_default),{money:__props.data.value},null,8,[`money`]),partConditionAvg.value<1?(openBlock(),createElementBlock(`div`,_hoisted_16$29,[_cache[1]||=createTextVNode(` Total Value: `,-1),createVNode(unref(bngUnit_default),{money:__props.data.valueRepaired},null,8,[`money`])])):createCommentVNode(``,!0)])),createBaseVNode(`div`,_hoisted_17$23,[_cache[2]||=createBaseVNode(`span`,{class:`insurance-label`},`Insurance:`,-1),createBaseVNode(`span`,_hoisted_18$20,toDisplayString(__props.data.insuranceInfo?__props.data.insuranceInfo.name:`n/a`),1),__props.data.isInsured?createCommentVNode(``,!0):(openBlock(),createElementBlock(`div`,_hoisted_19$17,`Not Insured!`))])])]))],2)),[[unref(BngDisabled_default),__props.data.disabled]]):createCommentVNode(``,!0)}}),VehicleTileRow_default=__plugin_vue_export_helper_default(_sfc_main$249,[[`__scopeId`,`data-v-777a3003`]]),_hoisted_1$219={key:1,class:`computer-actions`},_hoisted_2$178={key:0,class:`vehicle-select-container`},_hoisted_3$157={class:`vehicle-select`},_hoisted_4$132={key:0,class:`actions-list`},_hoisted_5$115=[`onClick`,`onMouseover`,`onFocus`],_hoisted_6$98={class:`label`},_hoisted_7$86={key:1,class:`no-vehicle-container`},_hoisted_8$71={key:2,class:`action-header`},_hoisted_9$64={key:3,class:`general-functions-container`},_hoisted_10$55={class:`actions-list`},_hoisted_11$49=[`onClick`,`onMouseover`,`onFocus`],_hoisted_12$38={class:`label`},_hoisted_13$31={key:0,class:`disable-reason`},_hoisted_14$29=[`innerHTML`],_hoisted_15$28={key:1,class:`disable-reason`},_hoisted_16$28=[`innerHTML`],_sfc_main$248={__name:`ComputerMain`,setup(__props){let computerStore=useComputerStore(),currentVehicleData=ref(null);watch(()=>computerStore.activeInventoryId,newId=>{Number(newId)&&Lua_default.career_modules_inventory.getVehicleUiData(newId).then(data=>{currentVehicleData.value=data})});let showVehicleSelectorButtons=computed(()=>computerStore.computerData.vehicles&&computerStore.computerData.vehicles.length>1),hasVehicles=computed(()=>computerStore.computerData.vehicles&&computerStore.computerData.vehicles.length);computed(()=>hasVehicles.value?computerStore.computerData.vehicles[computerStore.activeVehicleIndex].vehicleName:``),computed(()=>hasVehicles.value?computerStore.computerData.vehicles[computerStore.activeVehicleIndex].thumbnail:``),computed(()=>hasVehicles.value?computerStore.computerData.vehicles[computerStore.activeVehicleIndex].needsRepair?`Assess Performance (Repair Required)`:`Assess Performance`:``);let slowFunctions=[`vehicleShop`,`partInventory`],computerLoading=ref(!1),computerButtonCallback=(computerFunction,inventoryId=void 0)=>{computerFunction.disabled||(slowFunctions.includes(computerFunction.id)?(computerLoading.value=!0,setTimeout(()=>computerStore.computerButtonCallback(computerFunction.id,inventoryId),100)):computerStore.computerButtonCallback(computerFunction.id,inventoryId))},switchActiveVehicle=computerStore.switchActiveVehicle,iconById={painting:icons.sprayCan,partShop:icons.doorFrontCoins,repair:icons.wrench,tuning:icons.cogs,insurances:icons.shieldHandCheckmark,playerAbstract:icons.personSolid,vehicleInventory:icons.keys1,partInventory:icons.engine,vehicleShop:icons.carCoins,performanceIndex:icons.raceFlag},infoById=computed(()=>[...computerStore.generalComputerFunctions,...(computerStore.activeInventoryId?computerStore.vehicleSpecificComputerFunctions[computerStore.activeInventoryId]:void 0)||[]].reduce((res,func)=>(res[func.id]={icon:iconById[func.id]||icons.bug,label:func.label,reason:void 0},func.reason&&(res[func.id].label+=` *`,res[func.id].reason=func.reason.label),res),{})),isTutorialActive=ref(!1),disableReason=ref([null,null]),setReason=(idx,reason=null)=>{disableReason.value[idx]=reason,disableReason.value[(idx+1)%2]=null},close=()=>{computerLoading.value||Lua_default.career_career.closeAllMenus()};return onMounted(async()=>{getUINavServiceInstance().setFilteredEvents(UI_EVENT_GROUPS.focusMoveScalar),computerStore.requestComputerData(),Number(computerStore.activeInventoryId)&&Lua_default.career_modules_inventory.getVehicleUiData(computerStore.activeInventoryId).then(data=>{currentVehicleData.value=data}),Lua_default.career_modules_linearTutorial.isLinearTutorialActive().then(data=>{isTutorialActive.value=data})}),onUnmounted(()=>{computerStore.onMenuClosed(),getUINavServiceInstance().clearFilteredEvents(),computerStore.$dispose()}),(_ctx,_cache)=>(openBlock(),createBlock(ComputerWrapper_default,{title:unref(computerStore).computerData.facilityName+` - Home screen`,close:``,onBack:close},{default:withCtx(()=>[withDirectives((openBlock(),createBlock(unref(bngCard_default),{class:`card-content`},{default:withCtx(()=>[computerLoading.value?(openBlock(),createBlock(unref(bngCardHeading_default),{key:0},{default:withCtx(()=>[..._cache[6]||=[createTextVNode(` Loading... `,-1)]]),_:1})):createCommentVNode(``,!0),computerLoading.value?createCommentVNode(``,!0):(openBlock(),createElementBlock(`div`,_hoisted_1$219,[_cache[9]||=createBaseVNode(`div`,{class:`action-header`},[createBaseVNode(`div`,{class:`line left`}),createBaseVNode(`div`,{class:`title`},`Vehicle Management`),createBaseVNode(`div`,{class:`line right`})],-1),hasVehicles.value?(openBlock(),createElementBlock(`div`,_hoisted_2$178,[createBaseVNode(`div`,_hoisted_3$157,[showVehicleSelectorButtons.value?withDirectives((openBlock(),createBlock(unref(bngButton_default),{key:0,style:{height:`3em`},accent:unref(ACCENTS).ghost,onClick:_cache[0]||=$event=>unref(switchActiveVehicle)(-1),icon:unref(icons).arrowLargeLeft},{default:withCtx(()=>[createVNode(unref(bngBinding_default),{"ui-event":`tab_l`,deviceMask:`xinput`})]),_:1},8,[`accent`,`icon`])),[[unref(BngOnUiNav_default),void 0,`tab_l`,{asMouse:!0}]]):createCommentVNode(``,!0),createVNode(VehicleTileRow_default,{class:normalizeClass([`vehicle-tile-row`,{hasButtons:showVehicleSelectorButtons.value}]),data:currentVehicleData.value,enableHover:!1,small:!0},null,8,[`class`,`data`]),showVehicleSelectorButtons.value?withDirectives((openBlock(),createBlock(unref(bngButton_default),{key:1,style:{height:`3em`},accent:unref(ACCENTS).ghost,onClick:_cache[1]||=$event=>unref(switchActiveVehicle)(1),icon:unref(icons).arrowLargeRight},{default:withCtx(()=>[createVNode(unref(bngBinding_default),{"ui-event":`tab_r`,deviceMask:`xinput`})]),_:1},8,[`accent`,`icon`])),[[unref(BngOnUiNav_default),void 0,`tab_r`,{asMouse:!0}]]):createCommentVNode(``,!0)]),unref(computerStore).activeInventoryId&&unref(computerStore).vehicleSpecificComputerFunctions[unref(computerStore).activeInventoryId]?(openBlock(),createElementBlock(`div`,_hoisted_4$132,[(openBlock(!0),createElementBlock(Fragment,null,renderList(unref(computerStore).vehicleSpecificComputerFunctions[unref(computerStore).activeInventoryId],(computerFunction,index)=>withDirectives((openBlock(),createElementBlock(`div`,{class:normalizeClass([`computer-function-tile`,{"action-disabled":computerFunction.disabled}]),key:computerFunction.id,tabindex:`0`,"bng-nav-item":``,onClick:$event=>computerButtonCallback(computerFunction,unref(computerStore).activeInventoryId),onMouseover:$event=>setReason(0,infoById.value[computerFunction.id].reason),onFocus:$event=>setReason(0,infoById.value[computerFunction.id].reason),onMouseleave:_cache[2]||=$event=>setReason(0),onBlur:_cache[3]||=$event=>setReason(0)},[createVNode(unref(bngIcon_default),{class:`icon`,type:infoById.value[computerFunction.id].icon},null,8,[`type`]),createBaseVNode(`span`,_hoisted_6$98,toDisplayString(infoById.value[computerFunction.id].label),1)],42,_hoisted_5$115)),[[unref(BngOnUiNav_default),void 0,`ok`,{asMouse:!0,focusRequired:!0}],[unref(BngUiNavFocus_default),index==0?0:void 0]])),128))])):createCommentVNode(``,!0)])):(openBlock(),createElementBlock(`div`,_hoisted_7$86,[..._cache[7]||=[createBaseVNode(`span`,null,`No vehicles in garage.`,-1),createBaseVNode(`p`,null,` Place a vehicle in your garage to access modify and manage it.`,-1)]])),unref(computerStore).generalComputerFunctions?(openBlock(),createElementBlock(`div`,_hoisted_8$71,[..._cache[8]||=[createBaseVNode(`div`,{class:`line left`},null,-1),createBaseVNode(`div`,{class:`title`},`General Computer Functions`,-1),createBaseVNode(`div`,{class:`line right`},null,-1)]])):createCommentVNode(``,!0),unref(computerStore).generalComputerFunctions?(openBlock(),createElementBlock(`div`,_hoisted_9$64,[createBaseVNode(`div`,_hoisted_10$55,[(openBlock(!0),createElementBlock(Fragment,null,renderList(unref(computerStore).generalComputerFunctions,(computerFunction,index)=>(openBlock(),createElementBlock(Fragment,{key:computerFunction.id},[computerFunction.type?createCommentVNode(``,!0):withDirectives((openBlock(),createElementBlock(`div`,{key:0,class:normalizeClass([`computer-function-tile`,{"action-disabled":computerFunction.disabled}]),tabindex:`0`,"bng-nav-item":``,onClick:$event=>computerButtonCallback(computerFunction),onMouseover:$event=>setReason(1,infoById.value[computerFunction.id].reason),onFocus:$event=>setReason(1,infoById.value[computerFunction.id].reason),onMouseleave:_cache[4]||=$event=>setReason(1),onBlur:_cache[5]||=$event=>setReason(1)},[createVNode(unref(bngIcon_default),{class:`icon`,type:infoById.value[computerFunction.id].icon},null,8,[`type`]),createBaseVNode(`span`,_hoisted_12$38,toDisplayString(infoById.value[computerFunction.id].label),1)],42,_hoisted_11$49)),[[unref(BngOnUiNav_default),void 0,`ok`,{asMouse:!0,focusRequired:!0}],[unref(BngUiNavFocus_default),!hasVehicles.value&&index==0?0:void 0]])],64))),128))]),disableReason.value[0]?(openBlock(),createElementBlock(`div`,_hoisted_13$31,[withDirectives(createVNode(unref(bngIcon_default),{class:`disable-icon`,type:unref(icons).info},null,8,[`type`]),[[vShow,disableReason.value[0]]]),createBaseVNode(`span`,{innerHTML:disableReason.value[0]||`\xA0`},null,8,_hoisted_14$29)])):createCommentVNode(``,!0),disableReason.value[1]?(openBlock(),createElementBlock(`div`,_hoisted_15$28,[createVNode(unref(bngIcon_default),{class:`disable-icon`,type:unref(icons).info},null,8,[`type`]),createBaseVNode(`span`,{innerHTML:disableReason.value[1]||`\xA0`},null,8,_hoisted_16$28)])):createCommentVNode(``,!0)])):createCommentVNode(``,!0)]))]),_:1})),[[unref(BngBlur_default),1]])]),_:1},8,[`title`]))}},ComputerMain_default=__plugin_vue_export_helper_default(_sfc_main$248,[[`__scopeId`,`data-v-10a4ce58`]]);const useInsurancesStore=defineStore(`insurances`,()=>{let{events:events$3}=useBridge(),invVehsInsurancesData=ref({}),plClassesData=ref({}),uninsuredVehsData=ref({}),driverScoreData=ref({});function requestInitialData(){Lua_default.career_modules_insurance_insurance.sendUIData()}return events$3.on(`insurancesData`,data=>{invVehsInsurancesData.value=data.invVehsInsurancesData,plClassesData.value=data.plClassesData,uninsuredVehsData.value=data.uninsuredVehsData,driverScoreData.value=data.driverScoreData}),{dispose:()=>{events$3.off(`insurancesData`)},requestInitialData,closeMenu:Lua_default.career_modules_insurance_insurance.closeMenu,invVehsInsurancesData,plClassesData,uninsuredVehsData,driverScoreData}});var _hoisted_1$218={key:0,class:`cards-wrapper blue-background`},_hoisted_2$177={class:`insurance-tiers-wrapper`},_hoisted_3$156=[`onClick`],_hoisted_4$131={class:`insurance-tier-card-name`},_hoisted_5$114={class:`insurance-tier-card-description`},_hoisted_6$97={class:`insurance-tier-card-cars-insured`},_hoisted_7$85={class:`left-no-insurance`},_hoisted_8$70={class:`no-insurance-text-wrapper`},_hoisted_9$63={class:`no-insurance-title`},_hoisted_10$54={class:`no-insurance-description`},_hoisted_11$48={class:`uninsured-count`},_hoisted_12$37={key:1,class:`small-insurance-cards-wrapper blue-background`},_sfc_main$247={__name:`InsurancesMain`,setup(__props){useComputerStore();let insurancesStore=useInsurancesStore(),selectedInsuranceClassId=ref(null),selectInsuranceClass=classId=>{selectedInsuranceClassId.value=classId},sortedInsuranceClasses=computed(()=>{let classes=insurancesStore.plClassesData;return classes?Object.entries(classes).map(([classId,classData])=>({classId,classData})).sort((a$1,b)=>a$1.classData.priority-b.classData.priority):[]});onBeforeMount(()=>{insurancesStore.requestInitialData()}),onUnmounted(()=>{Lua_default.extensions.hook(`onExitInsurancesComputerScreen`),insurancesStore.$dispose()});let close=()=>{selectedInsuranceClassId.value?selectedInsuranceClassId.value=null:insurancesStore.closeMenu()},openUninsuredVehicles=()=>{addPopup(uninsuredVehicles_default,{uninsuredData:insurancesStore.uninsuredVehsData})};return(_ctx,_cache)=>(openBlock(),createBlock(ComputerWrapper_default,{ref:`wrapper`,path:[`Insurance`],title:`Insurance`,back:``,onBack:close},{default:withCtx(()=>[createVNode(unref(bngCard_default),{class:`insurances-card blue-background`},{default:withCtx(()=>[selectedInsuranceClassId.value?createCommentVNode(``,!0):(openBlock(),createElementBlock(`div`,_hoisted_1$218,[createBaseVNode(`div`,_hoisted_2$177,[(openBlock(!0),createElementBlock(Fragment,null,renderList(sortedInsuranceClasses.value,({classId,classData})=>(openBlock(),createElementBlock(`div`,{class:`insurance-tier-card`,key:classId,onClick:$event=>selectInsuranceClass(classId)},[createVNode(unref(bngIcon_default),{class:`insurance-icon`,type:unref(icons)[classData.icon]},null,8,[`type`]),createBaseVNode(`div`,_hoisted_4$131,toDisplayString(classData.name),1),createBaseVNode(`div`,_hoisted_5$114,toDisplayString(classData.description),1),createBaseVNode(`div`,_hoisted_6$97,toDisplayString(classData.carsInsured)+` VEHICLES INSURED `,1)],8,_hoisted_3$156))),128))]),createBaseVNode(`div`,{class:`no-insurance-card`,onClick:openUninsuredVehicles},[createBaseVNode(`div`,_hoisted_7$85,[createVNode(unref(bngIcon_default),{class:`no-insurance-icon`,type:unref(icons).checkmark},null,8,[`type`]),createBaseVNode(`div`,_hoisted_8$70,[createBaseVNode(`div`,_hoisted_9$63,toDisplayString(unref(insurancesStore).uninsuredVehsData.title),1),createBaseVNode(`div`,_hoisted_10$54,toDisplayString(unref(insurancesStore).uninsuredVehsData.description),1)])]),createBaseVNode(`div`,_hoisted_11$48,toDisplayString(unref(insurancesStore).uninsuredVehsData.carsUninsuredCount)+` vehicles `,1)])])),selectedInsuranceClassId.value?(openBlock(),createElementBlock(`div`,_hoisted_12$37,[(openBlock(!0),createElementBlock(Fragment,null,renderList(unref(insurancesStore).plClassesData[selectedInsuranceClassId.value].insurances,insurance=>(openBlock(),createBlock(unref(smallInsuranceCard_default),{key:insurance.id,insuranceData:insurance,driverScoreData:unref(insurancesStore).driverScoreData},null,8,[`insuranceData`,`driverScoreData`]))),128))])):createCommentVNode(``,!0)]),_:1})]),_:1},512))}},InsurancesMain_default=__plugin_vue_export_helper_default(_sfc_main$247,[[`__scopeId`,`data-v-a9e49ad5`]]),_hoisted_1$217={key:0,class:`content`},_hoisted_2$176={class:`stats-grid-3`},_hoisted_3$155={class:`score-header`},_hoisted_4$130={class:`score-content`},_hoisted_5$113={class:`score-info`},_hoisted_6$96={class:`score-description`},_hoisted_7$84={class:`stat-card`},_hoisted_8$69={class:`stat-value blue`},_hoisted_9$62={class:`stat-card`},_hoisted_10$53={class:`stats-grid-2`},_hoisted_11$47={class:`info-card`},_hoisted_12$36={class:`info-rows`},_hoisted_13$30={class:`info-row`},_hoisted_14$28={class:`info-value orange`},_hoisted_15$27={class:`info-row`},_hoisted_16$27={class:`info-value green`},_hoisted_17$22={class:`info-row total`},_hoisted_18$19={class:`info-value`},_hoisted_19$16={class:`info-card`},_hoisted_20$14={class:`info-rows`},_hoisted_21$13={class:`info-row bottom-border`},_hoisted_22$11={class:`info-value blue`},_hoisted_23$10={class:`info-row`},_hoisted_24$9={class:`info-value red`},_hoisted_25$8={class:`info-row`},_hoisted_26$6={class:`info-value orange`},_hoisted_27$6={class:`info-row`},_hoisted_28$5={class:`info-value yellow`},_hoisted_29$5={class:`info-row total`},_hoisted_30$5={class:`info-value`},_hoisted_31$5={class:`info-summary`},_hoisted_32$5={class:`info-row small`},_hoisted_33$5={class:`info-value green bold`},_hoisted_34$5={class:`reset-card`},_hoisted_35$4={class:`reset-content`},_hoisted_36$4={class:`reset-description`},_hoisted_37$3={class:`highlight`},_hoisted_38$3={class:`reset-details`},_hoisted_39$3={class:`reset-row`},_hoisted_40$2={class:`reset-row`},_hoisted_41$2={class:`reset-value green`},_hoisted_42$2={class:`reset-row cost`},_hoisted_43$2={class:`reset-value yellow large`},_hoisted_44$2={key:0,class:`reset-payback`},_hoisted_45$2=[`disabled`],_sfc_main$246={__name:`DriverAbstract`,setup(__props){let{units}=useBridge(),abstractData=ref(null),driverTier=computed(()=>abstractData.value?.driverScoreTier),totalDistanceFormatted=computed(()=>abstractData.value?units.buildString(`length`,abstractData.value.totalDistanceDriven,0):``),premiumEffectClass=computed(()=>{if(!driverTier.value)return``;let multiplier=driverTier.value.multiplier;return multiplier<1?`green`:multiplier>1?`red`:`neutral`}),premiumEffectText=computed(()=>{if(!driverTier.value)return`Standard Rate`;let multiplier=driverTier.value.multiplier;return multiplier<1?`${Math.round((1-multiplier)*100)}% Savings`:multiplier>1?`${Math.round((multiplier-1)*100)}% Penalty`:`Standard Rate`}),canResetScore=computed(()=>abstractData.value?abstractData.value.driverScore{if(!driverTier.value)return`green`;let multiplier=driverTier.value.multiplier;return multiplier<1?`blue`:multiplier<1.1?`green`:multiplier<1.3?`yellow`:multiplier<1.5?`orange`:`red`},getDriverColor=()=>({blue:`var(--blue-200)`,green:`var(--green-300)`,yellow:`var(--yellow-400)`,orange:`var(--orange-shade-10)`,red:`var(--red-400)`})[getDriverColorClass()]||`var(--green-300)`,loadData=async()=>{try{abstractData.value=await Lua_default.career_modules_playerAbstract.getPlayerAbstractData()}catch(error){console.error(`Failed to load driver abstract data:`,error)}},resetDriverScore=async()=>{try{await Lua_default.career_modules_insurance_insurance.resetDriverScore(),await loadData()}catch(error){console.error(`Failed to reset driver score:`,error)}},close=()=>{Lua_default.career_modules_playerAbstract.closePlayerAbstractMenu()};return onBeforeMount(loadData),(_ctx,_cache)=>(openBlock(),createBlock(ComputerWrapper_default,{ref:`wrapper`,path:[`Driver's Abstract`],title:`Driver's Abstract`,back:``,onBack:close},{default:withCtx(()=>[createVNode(unref(bngCard_default),{class:`driver-abstract-card`},{default:withCtx(()=>[abstractData.value?(openBlock(),createElementBlock(`div`,_hoisted_1$217,[createBaseVNode(`div`,_hoisted_2$176,[createBaseVNode(`div`,{class:`score-card`,style:normalizeStyle({borderColor:getDriverColor()})},[createBaseVNode(`div`,_hoisted_3$155,[_cache[0]||=createBaseVNode(`div`,{class:`section-title`},`Driver Score: Out of 100`,-1),createVNode(unref(TutorialButton_default),{icon:unref(icons).help,pages:[`driverScore`]},null,8,[`icon`])]),createBaseVNode(`div`,_hoisted_4$130,[createBaseVNode(`div`,{class:normalizeClass([`score-value`,getDriverColorClass()])},toDisplayString(abstractData.value.driverScore),3),createBaseVNode(`div`,_hoisted_5$113,[createBaseVNode(`div`,{class:normalizeClass([`score-risk`,getDriverColorClass()])},toDisplayString(abstractData.value.driverScoreTier.risk),3),createBaseVNode(`div`,_hoisted_6$96,toDisplayString(abstractData.value.driverScoreTier.description),1)])])],4),createBaseVNode(`div`,_hoisted_7$84,[_cache[1]||=createBaseVNode(`div`,{class:`section-title`},`Total Distance Driven`,-1),createBaseVNode(`div`,_hoisted_8$69,toDisplayString(totalDistanceFormatted.value),1)]),createBaseVNode(`div`,_hoisted_9$62,[_cache[2]||=createBaseVNode(`div`,{class:`section-title`},`Premium Effect`,-1),createBaseVNode(`div`,{class:normalizeClass([`stat-value`,premiumEffectClass.value])},toDisplayString(premiumEffectText.value),3),_cache[3]||=createBaseVNode(`div`,{class:`stat-note`},` Applies to every insurance provider when premiums renew `,-1)])]),createBaseVNode(`div`,_hoisted_10$53,[createBaseVNode(`div`,_hoisted_11$47,[_cache[7]||=createBaseVNode(`div`,{class:`section-title`},`Repair History`,-1),createBaseVNode(`div`,_hoisted_12$36,[createBaseVNode(`div`,_hoisted_13$30,[_cache[4]||=createBaseVNode(`span`,{class:`info-label`},`Insurance Claims:`,-1),createBaseVNode(`span`,_hoisted_14$28,toDisplayString(abstractData.value.repairHistory.insuranceRepairs),1)]),createBaseVNode(`div`,_hoisted_15$27,[_cache[5]||=createBaseVNode(`span`,{class:`info-label`},`Private Repairs:`,-1),createBaseVNode(`span`,_hoisted_16$27,toDisplayString(abstractData.value.repairHistory.privateRepairs),1)]),createBaseVNode(`div`,_hoisted_17$22,[_cache[6]||=createBaseVNode(`span`,{class:`info-label`},`Total Repairs:`,-1),createBaseVNode(`span`,_hoisted_18$19,toDisplayString(abstractData.value.repairHistory.insuranceRepairs+abstractData.value.repairHistory.privateRepairs),1)])]),_cache[8]||=createBaseVNode(`div`,{class:`info-tip`},` Private repairs don't affect your record `,-1)]),createBaseVNode(`div`,_hoisted_19$16,[_cache[16]||=createBaseVNode(`div`,{class:`section-title`},`Financial Summary`,-1),createBaseVNode(`div`,_hoisted_20$14,[createBaseVNode(`div`,_hoisted_21$13,[_cache[9]||=createBaseVNode(`span`,{class:`info-label`},`Vehicles Currently Insured:`,-1),createBaseVNode(`span`,_hoisted_22$11,toDisplayString(abstractData.value.financialSummary.vehiclesInsuredCount),1)]),createBaseVNode(`div`,_hoisted_23$10,[_cache[10]||=createBaseVNode(`span`,{class:`info-label`},`Premiums Paid:`,-1),createBaseVNode(`span`,_hoisted_24$9,[createVNode(unref(bngUnit_default),{class:`no-margin`,money:abstractData.value.financialSummary.totalPremiumPaid},null,8,[`money`])])]),createBaseVNode(`div`,_hoisted_25$8,[_cache[11]||=createBaseVNode(`span`,{class:`info-label`},`Deductibles Paid:`,-1),createBaseVNode(`span`,_hoisted_26$6,[createVNode(unref(bngUnit_default),{class:`no-margin`,money:abstractData.value.financialSummary.totalDeductiblePaid},null,8,[`money`])])]),createBaseVNode(`div`,_hoisted_27$6,[_cache[12]||=createBaseVNode(`span`,{class:`info-label`},`Private Repairs:`,-1),createBaseVNode(`span`,_hoisted_28$5,[createVNode(unref(bngUnit_default),{class:`no-margin`,money:abstractData.value.financialSummary.totalPrivateRepairsPaid},null,8,[`money`])])]),createBaseVNode(`div`,_hoisted_29$5,[_cache[13]||=createBaseVNode(`span`,{class:`info-label`},`Total Spent:`,-1),createBaseVNode(`span`,_hoisted_30$5,[createVNode(unref(bngUnit_default),{class:`no-margin`,money:abstractData.value.financialSummary.totalPaid},null,8,[`money`])])])]),createBaseVNode(`div`,_hoisted_31$5,[createBaseVNode(`div`,_hoisted_32$5,[_cache[14]||=createBaseVNode(`span`,{class:`info-label`},`Damage Covered by Insurance:`,-1),createBaseVNode(`span`,_hoisted_33$5,[createVNode(unref(bngUnit_default),{class:`no-margin`,money:abstractData.value.financialSummary.damageCoveredByInsurance},null,8,[`money`])])]),_cache[15]||=createBaseVNode(`div`,{class:`info-tip blue italic`},` Insurance saved you from paying full repair costs `,-1)])])]),createBaseVNode(`div`,_hoisted_34$5,[_cache[22]||=createBaseVNode(`div`,{class:`section-title`},`Driver Score Reset`,-1),createBaseVNode(`div`,_hoisted_35$4,[createBaseVNode(`p`,_hoisted_36$4,[_cache[17]||=createTextVNode(` Reset your driver score to `,-1),createBaseVNode(`span`,_hoisted_37$3,toDisplayString(abstractData.value.driverScoreReset.resetTo),1),_cache[18]||=createTextVNode(` to remove premium penalties. `,-1)]),createBaseVNode(`div`,_hoisted_38$3,[createBaseVNode(`div`,_hoisted_39$3,[_cache[19]||=createBaseVNode(`span`,{class:`reset-label`},`Current Score:`,-1),createBaseVNode(`span`,{class:normalizeClass([`reset-value`,canResetScore.value?`red`:`green`])},toDisplayString(abstractData.value.driverScore),3)]),createBaseVNode(`div`,_hoisted_40$2,[_cache[20]||=createBaseVNode(`span`,{class:`reset-label`},`Reset To:`,-1),createBaseVNode(`span`,_hoisted_41$2,toDisplayString(abstractData.value.driverScoreReset.resetTo),1)]),createBaseVNode(`div`,_hoisted_42$2,[_cache[21]||=createBaseVNode(`span`,{class:`reset-label`},`Reset Cost:`,-1),createBaseVNode(`span`,_hoisted_43$2,[createVNode(unref(bngUnit_default),{class:`no-margin`,money:abstractData.value.driverScoreReset.resetCost},null,8,[`money`])])]),canResetScore.value&&_ctx.resetSavingsPer100km>0?(openBlock(),createElementBlock(`div`,_hoisted_44$2,` Pays for itself after xxx km `)):createCommentVNode(``,!0)]),createBaseVNode(`button`,{onClick:resetDriverScore,disabled:!canResetScore.value,class:normalizeClass([`reset-button`,{disabled:!canResetScore.value}])},toDisplayString(canResetScore.value?`Reset Score`:`Not Available (Score Already at or Higher than `+abstractData.value.driverScoreReset.resetTo+`)`),11,_hoisted_45$2)])])])):createCommentVNode(``,!0)]),_:1})]),_:1},512))}},DriverAbstract_default=__plugin_vue_export_helper_default(_sfc_main$246,[[`__scopeId`,`data-v-8041df87`]]),_hoisted_1$216={"bng-ui-scope":`logbook`,class:`career-logbook-wrapper`},_hoisted_2$175={class:`career-logbook-container`},_hoisted_3$154={class:`career-logbook-list`},_hoisted_4$129={class:`logbook-list-wrapper`},_hoisted_5$112=[`onClick`],_hoisted_6$95={class:`career-logbook-item-content`},_hoisted_7$83={class:`career-logbook-meta`},_hoisted_8$68={class:`career-logbook-newmark`},_hoisted_9$61={class:`career-logbook-item-label`},_hoisted_10$52={class:`career-logbook-details`},_hoisted_11$46={class:`career-logbook-title-newmark`},_hoisted_12$35={class:`career-logbook-meta`},_hoisted_13$29={key:0},_hoisted_14$27={class:`logbook-description`},_hoisted_15$26={key:1,class:`logbook-description logbook-table`},_hoisted_16$26={key:2},_hoisted_17$21={key:3,class:`logbook-description quest-status`},_hoisted_18$18={class:`quest-stats-wrapper`},_hoisted_19$15={class:`quest-labels`},_hoisted_20$13={class:`progress-label`},_hoisted_21$12={key:0,class:`progressbar-background`},_hoisted_22$10={class:`rewards-wrapper flex-row`},_hoisted_23$9={class:`label`},_hoisted_24$8={class:`rewards-section flex-row`},_hoisted_25$7={class:`flex-row`},_sfc_main$245={__name:`Logbook`,props:{id:String},setup(__props){useUINavScope(`logbook`);let rewardUnitTypes={money:`beambucks`,beamXP:`xp`},props=__props,sectionTabs=ref(),entryId=computed(()=>props.id===void 0?void 0:(``+props.id).replace(/%/g,`/`)),logbookTabs=ref([{id:`info`,name:`Info`,entries:[],filter:i=>i.type===`info`},{id:`history`,name:`History`,entries:[],filter:i=>i.type===`progress`}]),checkForNewLogEntries=()=>logbookTabs.value.forEach(tab=>tab.hasNew=!!tab.entries.some(i=>i.isNew));function setup$3(data){if(data.forEach(entry=>{Object.hasOwn(entry,`text`)&&(entry.text=parse$1($translate.contextTranslate(entry.text,!0)),entry._ready=!0)}),logbookTabs.value.forEach(tab=>tab.entries=data.filter(tab.filter)),checkForNewLogEntries(),entryId.value){for(let tab of logbookTabs.value)for(let entry of tab.entries)if(``+entry.entryId===entryId.value){toggleExpand(entry),tab.isPreselected=!0;return}}logbookTabs.value[0].entries.length&&toggleExpand(logbookTabs.value[0].entries[0])}ref({});let selectedEntry=ref({});ref({});let readTimer,toggleExpand=entry=>setTimeout(()=>{readTimer&&clearTimeout(readTimer),selectedEntry.value=entry,readTimer=window.setTimeout(()=>{selectedEntry.value.isNew=!1,checkForNewLogEntries(),entry.type===`quest`?Lua_default.career_modules_questManager.setQuestAsNotNew(entry.questId):Lua_default.career_modules_logbook.setLogbookEntryRead(entry.entryId,!0)},1e3)},0),tabChange=newTab=>{if(entryId.value){entryId.value=void 0;return}let tab=logbookTabs.value[newTab.id];!tab||!tab.entries||tab.entries.length===0||toggleExpand(tab.entries[0])},claimRewards=entry=>{Lua_default.career_modules_questManager.claimRewardsById(entry.questId),entry.claimable=!1,entry.claimed=!0},exit=()=>setTimeout(()=>window.bngVue.gotoAngularState(`menu.careerPause`),0);return onBeforeMount(()=>{Lua_default.simTimeAuthority.pushPauseRequest(`logbook`)}),onMounted(()=>{Lua_default.career_modules_logbook.getLogbook().then(setup$3)}),onUnmounted(()=>{Lua_default.simTimeAuthority.popPauseRequest(`logbook`)}),(_ctx,_cache)=>withDirectives((openBlock(),createBlock(unref(layoutSingle_default),{class:`logbook-layout`},{default:withCtx(()=>[createVNode(unref(bngScreenHeading_default),null,{default:withCtx(()=>[createTextVNode(toDisplayString(_ctx.$t(`ui.career.logbook.subHeading`)),1)]),_:1}),withDirectives((openBlock(),createElementBlock(`div`,_hoisted_1$216,[createBaseVNode(`div`,_hoisted_2$175,[createBaseVNode(`div`,_hoisted_3$154,[createVNode(unref(tabs_default),{ref_key:`sectionTabs`,ref:sectionTabs,onChange:tabChange,class:`bng-tabs`,"make-tab-header-classes":tabDetails=>({flagged:tabDetails.data.hasNew})},{default:withCtx(()=>[(openBlock(!0),createElementBlock(Fragment,null,renderList(logbookTabs.value,tabDetail=>(openBlock(),createBlock(unref(tab_default),{key:tabDetail.id,heading:_ctx.$t(tabDetail.name),active:tabDetail.isPreselected,data:tabDetail},{default:withCtx(()=>[withDirectives((openBlock(),createElementBlock(`div`,_hoisted_4$129,[(openBlock(!0),createElementBlock(Fragment,null,renderList(tabDetail.entries,(entry,index)=>withDirectives((openBlock(),createElementBlock(`div`,{key:entry.entryId,"bng-nav-item":``,class:normalizeClass([`career-logbook-item`,{selected:selectedEntry.value!==void 0&&selectedEntry.value.entryId==entry.entryId}]),onClick:$event=>toggleExpand(entry)},[createBaseVNode(`div`,_hoisted_6$95,[createBaseVNode(`div`,_hoisted_7$83,[createBaseVNode(`div`,null,toDisplayString(_ctx.$ctx_t(entry.cardTypeLabel)),1),createVNode(unref(bngDivider_default),{class:`vertical-divider`}),withDirectives(createBaseVNode(`div`,null,null,512),[[unref(BngRelativeTime_default),entry.time]]),withDirectives(createBaseVNode(`div`,_hoisted_8$68,null,512),[[vShow,entry.isNew]])]),createBaseVNode(`div`,_hoisted_9$61,toDisplayString(_ctx.$ctx_t(entry.title)),1)])],10,_hoisted_5$112)),[[unref(BngUiNavFocus_default),tabDetail.entries.length-index],[unref(BngSoundClass_default),`bng_click_generic_small`]])),128))])),[[unref(BngUiNavScroll_default)]])]),_:2},1032,[`heading`,`active`,`data`]))),128))]),_:1},8,[`make-tab-header-classes`])]),createBaseVNode(`div`,_hoisted_10$52,[withDirectives(createVNode(unref(bngCard_default),{class:`career-logbook-content-card`},createSlots({default:withCtx(()=>[createVNode(unref(bngCardHeading_default),{class:`logbook-entry-heading`,type:`ribbon`},{default:withCtx(()=>[createTextVNode(toDisplayString(selectedEntry.value&&_ctx.$ctx_t(selectedEntry.value.title))+` `,1),withDirectives(createBaseVNode(`div`,_hoisted_11$46,null,512),[[vShow,selectedEntry.value.isNew]]),withDirectives((openBlock(),createBlock(unref(bngButton_default),{class:`exitButton`,onClick:exit,accent:unref(ACCENTS).attention},{default:withCtx(()=>[createVNode(unref(bngBinding_default),{"ui-event":`back`,deviceMask:`xinput`}),_cache[1]||=createTextVNode(`Back`,-1)]),_:1},8,[`accent`])),[[unref(BngSoundClass_default),`bng_back_generic`]])]),_:1}),createBaseVNode(`div`,_hoisted_12$35,[createBaseVNode(`div`,null,toDisplayString(_ctx.$ctx_t(selectedEntry.value.cardTypeLabel)),1),createVNode(unref(bngDivider_default),{class:`vertical-divider`}),withDirectives(createBaseVNode(`div`,null,null,512),[[unref(BngRelativeTime_default),selectedEntry.value.time]])]),createBaseVNode(`div`,{class:normalizeClass({"card-body":!0,"with-rewards":selectedEntry.value.type===`quest`&&selectedEntry.value.rewards.length})},[selectedEntry.value.cover?(openBlock(),createElementBlock(`div`,{key:0,class:`logbook-cover-image`,style:normalizeStyle({backgroundImage:`url(${selectedEntry.value.cover})`})},[selectedEntry.value.coverText?(openBlock(),createElementBlock(`h1`,_hoisted_13$29,toDisplayString(selectedEntry.value.coverText),1)):createCommentVNode(``,!0)],4)):createCommentVNode(``,!0),createBaseVNode(`div`,_hoisted_14$27,[selectedEntry.value._ready?(openBlock(),createBlock(unref(dynamicComponent_default),{key:0,template:_ctx.$ctx_t(selectedEntry.value.text)},null,8,[`template`])):createCommentVNode(``,!0)]),selectedEntry.value.tables?(openBlock(),createElementBlock(`div`,_hoisted_15$26,[(openBlock(!0),createElementBlock(Fragment,null,renderList(selectedEntry.value.tables,(table,keyT)=>(openBlock(),createElementBlock(`table`,{key:keyT},[createBaseVNode(`tbody`,null,[createBaseVNode(`tr`,null,[(openBlock(!0),createElementBlock(Fragment,null,renderList(table.headers,(header,keyH)=>(openBlock(),createElementBlock(`th`,{key:keyH},toDisplayString(header),1))),128))]),(openBlock(!0),createElementBlock(Fragment,null,renderList(table.rows,(row,keyR)=>(openBlock(),createElementBlock(`tr`,{key:keyR},[(openBlock(!0),createElementBlock(Fragment,null,renderList(row,(data,keyD)=>(openBlock(),createElementBlock(`td`,{key:keyD},[typeof data==`object`&&data&&data.hasOwnProperty(`type`)&&data.type===`rewards`?(openBlock(),createBlock(RewardsPills_default,{key:0,rewards:data.rewards,hideNumbers:!1},null,8,[`rewards`])):(openBlock(),createBlock(unref(dynamicComponent_default),{key:1,template:_ctx.$ctx_t(data)},null,8,[`template`]))]))),128))]))),128))])]))),128))])):createCommentVNode(``,!0),selectedEntry.value.type===`quest`?(openBlock(),createElementBlock(`hr`,_hoisted_16$26)):createCommentVNode(``,!0),selectedEntry.value.type===`quest`?(openBlock(),createElementBlock(`div`,_hoisted_17$21,[_cache[2]||=createBaseVNode(`h4`,null,`Milestone Status`,-1),(openBlock(!0),createElementBlock(Fragment,null,renderList(selectedEntry.value.progress,prog=>(openBlock(),createElementBlock(`div`,null,[createBaseVNode(`div`,_hoisted_18$18,[createBaseVNode(`div`,_hoisted_19$15,[prog.done?(openBlock(),createBlock(unref(bngIcon_default),{key:0,class:`check-icon`,type:prog.failed?unref(icons).missionCheckboxCross:prog.done?unref(icons).checkboxOn:unref(icons).checkboxOff},null,8,[`type`])):createCommentVNode(``,!0),createBaseVNode(`div`,_hoisted_20$13,toDisplayString(_ctx.$ctx_t(prog.label)),1)]),prog.type===`progressBar`?(openBlock(),createElementBlock(`div`,_hoisted_21$12,[createBaseVNode(`div`,{class:`progressbar-fill`,style:normalizeStyle({width:(prog.currValue>0?prog.currValue/(prog.maxValue-prog.minValue)*100:0)+`%`})},null,4)])):createCommentVNode(``,!0)])]))),256))])):createCommentVNode(``,!0)],2)]),_:2},[selectedEntry.value.type===`quest`&&selectedEntry.value.rewards.length?{name:`footer`,fn:withCtx(()=>[createBaseVNode(`div`,_hoisted_22$10,[createBaseVNode(`div`,_hoisted_23$9,toDisplayString(_ctx.$t(`ui.career.logbook.rewards`))+`:`,1),createBaseVNode(`div`,_hoisted_24$8,[(openBlock(!0),createElementBlock(Fragment,null,renderList(selectedEntry.value.rewards,reward=>(openBlock(),createElementBlock(`div`,_hoisted_25$7,[createVNode(unref(bngUnit_default),mergeProps({class:`reward-icon`},{ref_for:!0},{[rewardUnitTypes[reward.attributeKey]]:reward.rewardAmount},{options:{formatter:x=>~~x}}),null,16,[`options`])]))),256))]),withDirectives((openBlock(),createBlock(unref(bngButton_default),{onClick:_cache[0]||=$event=>claimRewards(selectedEntry.value),disabled:!selectedEntry.value.claimable},{default:withCtx(()=>[createTextVNode(toDisplayString(_ctx.$t(`ui.career.logbook.claimRewards`)),1)]),_:1},8,[`disabled`])),[[vShow,!selectedEntry.value.claimed],[unref(BngSoundClass_default),`bng_click_generic`]]),withDirectives(createVNode(unref(bngButton_default),{disabled:!0},{default:withCtx(()=>[createTextVNode(toDisplayString(_ctx.$t(`ui.career.logbook.rewardsClaimed`)),1)]),_:1},512),[[vShow,selectedEntry.value.claimed]])])]),key:`0`}:void 0]),1536),[[vShow,selectedEntry.value!==void 0]])])])])),[[unref(BngOnUiNav_default),exit,`back,menu`],[unref(BngOnUiNav_default),sectionTabs.value&§ionTabs.value.goPrev,`tab_l`],[unref(BngOnUiNav_default),sectionTabs.value&§ionTabs.value.goNext,`tab_r`]])]),_:1})),[[unref(BngBlur_default)]])}},Logbook_default=__plugin_vue_export_helper_default(_sfc_main$245,[[`__scopeId`,`data-v-e8139034`]]),_hoisted_1$215={class:`milestones-wrapper`},_hoisted_2$174={"bng-ui-scope":`milestones`,class:`career-milestones-card`},_hoisted_3$153={class:`career-milestones-container`},_hoisted_4$128={class:`actions`},_hoisted_5$111={class:`filters`},_hoisted_6$94={class:`scrollable-container`,"bng-nav-scroll-force":``},_hoisted_7$82={class:`cards-container`},_sfc_main$244={__name:`Milestones`,props:{id:String},setup(__props){useUINavScope(`milestones`);let careerStatusRef=ref(),allEntries=[],entries=ref([]),selectOneFilters=ref(),selectedFilters=ref([`general`]),FILTER_OPTIONS=[{value:`general`,label:`General`},{value:`all`,label:`All`},{value:`mission`,label:`Challenges`},{value:`branch`,label:`Branches`},{value:`delivery`,label:`Delivery`},{value:`money`,label:`Money`},{value:`speedTrap`,label:`Speed Traps`},{value:`insurance`,label:`Insurance`}];function sortMilestones(){entries.value.sort(function(a$1,b){return a$1.claimable&&!b.claimable?-1:b.claimable&&!a$1.claimable?1:!a$1.completed&&b.completed?-1:a$1.completed&&!b.completed?1:a$1.claimId!0):entries.value=allEntries.filter(e=>e.filter[currentFilter]),sortMilestones()}function filterChanged(filterList){filterList&&(currentFilter=filterList[0]),filterEntries()}function setup$3(data){allEntries=data.list;let hasClaimable=!1;data.list.forEach(x=>{x.claimable&&(hasClaimable=!0)}),hasClaimable&&(selectedFilters.value=[`all`],filterChanged(selectedFilters.value)),filterEntries()}Lua_default.career_modules_milestones_milestones.getMilestones().then(setup$3);let claimMilestone=entry=>{Lua_default.career_modules_milestones_milestones.claim(entry.claimId).then(replacementEntry=>{careerStatusRef.value.updateDisplay();let replacementId=allEntries.findIndex(item=>item.claimId===entry.claimId);if(replacementEntry!=null&&replacementId!==-1){allEntries[replacementId]=replacementEntry,filterEntries();return}allEntries[replacementId].claimable=!1,filterEntries()})},exit=()=>{window.bngVue.gotoGameState(`progressLanding`)};return onUnmounted(()=>{Lua_default.simTimeAuthority.popPauseRequest(`milestones`)}),onBeforeMount(()=>{Lua_default.simTimeAuthority.pushPauseRequest(`milestones`)}),(_ctx,_cache)=>withDirectives((openBlock(),createBlock(unref(layoutSingle_default),{class:`milestones-layout`},{default:withCtx(()=>[createBaseVNode(`div`,_hoisted_1$215,[createVNode(unref(bngScreenHeading_default),null,{default:withCtx(()=>[..._cache[1]||=[createTextVNode(`Milestones`,-1)]]),_:1}),withDirectives((openBlock(),createElementBlock(`div`,_hoisted_2$174,[createBaseVNode(`div`,_hoisted_3$153,[createBaseVNode(`div`,_hoisted_4$128,[createVNode(unref(bngButton_default),{class:`exitButton`,onClick:exit,accent:unref(ACCENTS).attention},{default:withCtx(()=>[createVNode(unref(bngBinding_default),{tabindex:`1`,"ui-event":`back`,deviceMask:`xinput`}),_cache[2]||=createTextVNode(`Back`,-1)]),_:1},8,[`accent`]),createVNode(unref(careerStatus_default),{class:`career-page-status`,ref_key:`careerStatusRef`,ref:careerStatusRef},null,512)]),createBaseVNode(`div`,_hoisted_5$111,[createVNode(unref(bngIcon_default),{class:`career-filter-icon`,type:unref(icons).filter},null,8,[`type`]),createVNode(unref(bngPillFilters_default),{required:``,ref_key:`selectOneFilters`,ref:selectOneFilters,modelValue:selectedFilters.value,"onUpdate:modelValue":_cache[0]||=$event=>selectedFilters.value=$event,options:FILTER_OPTIONS,onValueChanged:filterChanged},null,8,[`modelValue`])]),createBaseVNode(`div`,_hoisted_6$94,[createBaseVNode(`div`,_hoisted_7$82,[(openBlock(!0),createElementBlock(Fragment,null,renderList(entries.value,entry=>withDirectives((openBlock(),createBlock(MilestoneCard_default,{tabindex:`1`,milestone:entry,isCondensed:!1,onClaim:claimMilestone},null,8,[`milestone`])),[[unref(BngSoundClass_default),entry.claimable?`bng_click_hover_generic`:`bng_hover_generic`]])),256))])])])])),[[unref(BngOnUiNav_default),exit,`back,menu`],[unref(BngOnUiNav_default),selectOneFilters.value&&selectOneFilters.value.focusPrevious,`tab_l`],[unref(BngOnUiNav_default),selectOneFilters.value&&selectOneFilters.value.focusNext,`tab_r`]])])]),_:1})),[[unref(BngOnUiNav_default),exit,`back,menu`],[unref(BngBlur_default)]])}},Milestones_default=__plugin_vue_export_helper_default(_sfc_main$244,[[`__scopeId`,`data-v-798d8c2a`]]),_hoisted_1$214={class:`panel-flex`},_hoisted_2$173={style:{"overflow-y":`scroll`}},_hoisted_3$152={class:`content-row selected-and-map-panel`},_hoisted_4$127={key:0,class:`content`},TAB_HEADINGS={parcels:`Parcels`,smallFluids:`Fluid Orders`,largeFluids:`Fluid Custom`,smallDryBulk:`Dry Bulk Orders`,largeDryBulk:`Dry Bulk Custom`,vehicles:`Vehicles`,trailers:`Trailers`,loaners:`Loaners`},_sfc_main$243={__name:`MyCargo`,props:{facilityId:String,parkingSpotPath:String},setup(__props){ref(3),ref(1);let{events:events$3}=useBridge();useUINavScope(`myCargo`);let props=__props;ref(null),ref(),ref(TAB_HEADINGS.parcels),ref(),ref();let cargoOverviewStore=useCargoOverviewStore(),updateCargoDataAll=()=>{cargoOverviewStore.requestCargoData(props.facilityId,props.parkingSpotPath)},close=()=>{Lua_default.career_modules_delivery_cargoScreen.exitCargoOverviewScreen()};return events$3.on(`updateCargoData`,updateCargoDataAll),onMounted(()=>{Lua_default.career_modules_delivery_cargoScreen.setCargoScreenTab(`all`),updateCargoDataAll()}),onUnmounted(()=>{cargoOverviewStore.menuClosed(),events$3.off(`updateCargoData`,updateCargoDataAll)}),(_ctx,_cache)=>(openBlock(),createElementBlock(Fragment,null,[_cache[22]||=createBaseVNode(`div`,{style:{color:`white`}},`#Hello`,-1),unref(cargoOverviewStore).cargoData?(openBlock(),createBlock(ComputerWrapper_default,{key:0,path:[`My Cargo`],title:`My Cargo 2`,back:``,onBack:close},{status:withCtx(()=>[..._cache[10]||=[createTextVNode(` Delivery Lvl 2 | Car Jockey Lvl 3 | Facility Reputation: Good `,-1)]]),top:withCtx(()=>[..._cache[11]||=[createBaseVNode(`div`,{style:{width:`100%`,padding:`0.3em`,background:`#8888ff`}},` FILTERTABS `,-1)]]),default:withCtx(()=>[createBaseVNode(`div`,_hoisted_1$214,[createVNode(unref(bngCard_default),{class:`content-row provided-orders-panel`},{default:withCtx(()=>[createVNode(unref(bngCardHeading_default),{type:`ribbon`,class:`cardHeading`},{default:withCtx(()=>[..._cache[12]||=[createTextVNode(` My Cargo `,-1)]]),_:1}),createVNode(unref(bngSwitch_default),{modelValue:unref(cargoOverviewStore).automaticRoute,"onUpdate:modelValue":_cache[0]||=$event=>unref(cargoOverviewStore).automaticRoute=$event},{default:withCtx(()=>[..._cache[13]||=[createTextVNode(` Automatic route `,-1)]]),_:1},8,[`modelValue`]),createVNode(unref(bngSlider_default),{min:0,max:unref(cargoOverviewStore).cargoData.playerCardGroupSets.length-1,step:1,modelValue:unref(cargoOverviewStore).playerGroupingIdx,"onUpdate:modelValue":_cache[1]||=$event=>unref(cargoOverviewStore).playerGroupingIdx=$event,onChange:unref(cargoOverviewStore).setGroupingAndSorting},null,8,[`max`,`modelValue`,`onChange`]),createVNode(unref(bngSlider_default),{min:0,max:unref(cargoOverviewStore).cargoData.sortingSets.length-1,step:1,modelValue:unref(cargoOverviewStore).playerSortingIdx,"onUpdate:modelValue":_cache[2]||=$event=>unref(cargoOverviewStore).playerSortingIdx=$event,onChange:unref(cargoOverviewStore).setGroupingAndSorting},null,8,[`max`,`modelValue`,`onChange`]),createVNode(unref(bngCardHeading_default),{type:`ribbon`,class:`cardHeading`},{default:withCtx(()=>[createTextVNode(` Grouped `+toDisplayString(unref(cargoOverviewStore).cargoData.playerCardGroupSets[unref(cargoOverviewStore).playerGroupingIdx].label)+`, Sorted `+toDisplayString(unref(cargoOverviewStore).cargoData.sortingSets[unref(cargoOverviewStore).playerSortingIdx].label),1)]),_:1}),createBaseVNode(`div`,_hoisted_2$173,[createVNode(ProvidedOrdersPanel_default,{groupSets:unref(cargoOverviewStore).cargoData.playerCardGroupSets,groupIdx:unref(cargoOverviewStore).playerGroupingIdx,sortingSets:unref(cargoOverviewStore).cargoData.sortingSets,sortIdx:unref(cargoOverviewStore).playerSortingIdx,onCardHovered:unref(cargoOverviewStore).cardHovered,onCardClicked:unref(cargoOverviewStore).cardClicked},null,8,[`groupSets`,`groupIdx`,`sortingSets`,`sortIdx`,`onCardHovered`,`onCardClicked`])])]),_:1}),createBaseVNode(`div`,_hoisted_3$152,[createVNode(unref(bngCard_default),{class:`cargo-detail`},createSlots({default:withCtx(()=>[createVNode(unref(bngCardHeading_default),{type:`ribbon`,class:`cardHeading`},{default:withCtx(()=>[..._cache[14]||=[createTextVNode(` Details View `,-1)]]),_:1}),unref(cargoOverviewStore).focusedCargo?(openBlock(),createElementBlock(`div`,_hoisted_4$127,[createVNode(CargoCard_default,{card:unref(cargoOverviewStore).focusedCargo,detailed:``},null,8,[`card`])])):createCommentVNode(``,!0)]),_:2},[unref(cargoOverviewStore).focusedCargo?{name:`buttons`,fn:withCtx(()=>[unref(cargoOverviewStore).focusedCargo.cardType==`parcelGroup`?(openBlock(),createElementBlock(Fragment,{key:0},[unref(cargoOverviewStore).focusedCargo.isFacilityCard?(openBlock(),createElementBlock(Fragment,{key:0},[createVNode(unref(bngButton_default),{disabled:!unref(cargoOverviewStore).focusedCargo.enabled||unref(cargoOverviewStore).focusedCargo.transientMoveCounts==0,accent:`text`,onClick:_cache[3]||=$event=>unref(cargoOverviewStore).clearLoad(unref(cargoOverviewStore).focusedCargo)},{default:withCtx(()=>[..._cache[15]||=[createTextVNode(` Clear Load `,-1)]]),_:1},8,[`disabled`]),createVNode(unref(bngButton_default),{disabled:!unref(cargoOverviewStore).focusedCargo.enabled||unref(cargoOverviewStore).focusedCargo.autoLoadLocations&&unref(cargoOverviewStore).focusedCargo.autoLoadLocations.length==0,accent:`text`,onClick:_cache[4]||=$event=>unref(cargoOverviewStore).loadCargoCustom(unref(cargoOverviewStore).focusedCargo)},{default:withCtx(()=>[..._cache[16]||=[createTextVNode(` Custom Load `,-1)]]),_:1},8,[`disabled`]),createVNode(unref(bngButton_default),{disabled:!unref(cargoOverviewStore).focusedCargo.enabled||unref(cargoOverviewStore).focusedCargo.autoLoadLocations&&unref(cargoOverviewStore).focusedCargo.autoLoadLocations.length<=unref(cargoOverviewStore).focusedCargo.transientMoveCounts,onClick:_cache[5]||=$event=>unref(cargoOverviewStore).loadCargoAuto(unref(cargoOverviewStore).focusedCargo)},{default:withCtx(()=>[..._cache[17]||=[createTextVNode(` Auto Load `,-1)]]),_:1},8,[`disabled`])],64)):createCommentVNode(``,!0),unref(cargoOverviewStore).focusedCargo.isPlayerCard?(openBlock(),createElementBlock(Fragment,{key:1},[createVNode(unref(bngButton_default),{accent:`text`,disabled:unref(cargoOverviewStore).focusedCargo.transientCargo,onClick:_cache[6]||=$event=>unref(cargoOverviewStore).changeDistribution(unref(cargoOverviewStore).focusedCargo)},{default:withCtx(()=>[..._cache[18]||=[createTextVNode(` Change Distribution `,-1)]]),_:1},8,[`disabled`]),createVNode(unref(bngButton_default),{disabled:unref(cargoOverviewStore).focusedCargo.transientCargo,onClick:_cache[7]||=$event=>unref(cargoOverviewStore).clearLoad(unref(cargoOverviewStore).focusedCargo)},{default:withCtx(()=>[..._cache[19]||=[createTextVNode(` Clear Load `,-1)]]),_:1},8,[`disabled`])],64)):createCommentVNode(``,!0)],64)):createCommentVNode(``,!0),unref(cargoOverviewStore).focusedCargo.cardType==`storage`?(openBlock(),createElementBlock(Fragment,{key:1},[unref(cargoOverviewStore).focusedCargo.isFacilityCard?(openBlock(),createBlock(unref(bngButton_default),{key:0,disabled:!unref(cargoOverviewStore).focusedCargo.enabled,onClick:_cache[8]||=$event=>unref(cargoOverviewStore).loadStorageCustom(unref(cargoOverviewStore).focusedCargo)},{default:withCtx(()=>[..._cache[20]||=[createTextVNode(` Load Custom `,-1)]]),_:1},8,[`disabled`])):createCommentVNode(``,!0)],64)):createCommentVNode(``,!0),unref(cargoOverviewStore).focusedCargo.cardType==`vehicleOffer`?(openBlock(),createBlock(unref(bngButton_default),{key:2,disabled:!unref(cargoOverviewStore).focusedCargo.enabled,onClick:_cache[9]||=$event=>unref(cargoOverviewStore).loadOffer(unref(cargoOverviewStore).focusedCargo)},{default:withCtx(()=>[createTextVNode(toDisplayString(unref(cargoOverviewStore).focusedCargo.spawnWhenCommitingCargo?`Don't bring out`:`Bring Out`),1)]),_:1},8,[`disabled`])):createCommentVNode(``,!0)]),key:`0`}:void 0]),1024),createVNode(unref(bngCard_default),{class:`map`},{default:withCtx(()=>[..._cache[21]||=[createTextVNode(` Map Screen `,-1)]]),_:1})])])]),_:1})):createCommentVNode(``,!0)],64))}},MyCargo_default=__plugin_vue_export_helper_default(_sfc_main$243,[[`__scopeId`,`data-v-9a756c16`]]),_hoisted_1$213={class:`paint-presets`},_hoisted_2$172={class:`paint-presets-group`},_hoisted_3$151={class:`paint-presets-name`},_hoisted_4$126={class:`presets-items`},_sfc_main$242={__name:`PaintPresets`,props:{presets:{type:Object,required:!0},showText:{type:Boolean,default:!1},editable:{type:Boolean,default:!1},current:{type:Object}},emits:[`apply`],setup(__props,{emit:__emit}){let settings$1=useSettings(),props=__props,emit$1=__emit,factoryPresets=computed(()=>{let presets=props.presets,factoryRes={},customRes={};if(typeof presets==`object`&&!Array.isArray(presets)){let paint=new Paint;for(let name in presets)try{paint.paint=presets[name];let paintObject=paint.paintObject;presets[name]&&typeof presets[name]==`object`&&presets[name].class===`custom`?customRes[name]=paintObject:factoryRes[name]=paintObject}catch{}}return{factory:factoryRes,custom:customRes}}),userPresets=ref({}),presetGroups=computed(()=>{let res=[];Object.keys(factoryPresets.value.factory).length&&res.push({name:`factory`,showTooltip:!0,editable:!1,presets:factoryPresets.value.factory}),Object.keys(factoryPresets.value.custom).length&&res.push({name:`custom`,showTooltip:!0,editable:!1,presets:factoryPresets.value.custom}),props.editable&&res.push({name:`user`,showTooltip:!1,editable:!0,presets:userPresets.value||{}});for(let group of res){let presets=Object.keys(group.presets).map(colname=>({name:colname,...group.presets[colname],css:`rgb(${group.presets[colname].baseColor.slice(0,3).map(val=>val*255)})`}));group.name!==`user`&&(presets=sortColors(presets)),group.presets=presets}return res});function average(arr){return arr.reduce((a$1,b)=>a$1+b)/arr.length}function valComparable(col,thres=.05){let bool=!0,av=average(col);for(let i=0;i=col[i];return bool&&=av>.8||av<.2,bool}function colorHigherHelper(itm){let av=average(itm.orig.baseColor.slice(0,3)),al=itm.orig.baseColor[3]/2,res=Math.abs(av-1)*al;return res===0?(av+al)/2:res+1}function colorHigher(a$1,b){let aColor=valComparable(a$1.orig.baseColor.slice(0,3)),bColor=valComparable(b.orig.baseColor.slice(0,3));if(aColor&&bColor)return colorHigherHelper(b)-colorHigherHelper(a$1);if(aColor&&!bColor)return 1;if(!aColor&&bColor)return-1;for(let i=0;i<3;i++)if(a$1.val[i]!==b.val[i])return a$1.val[i]-b.val[i];return 0}function colorValue(arr){let repitions=8,rgb=[];for(let i=0;i<3;i++)rgb[i]=(1-arr[3]/2)*arr[i]+arr[3]/2*arr[i];let lum=Math.sqrt(.241*rgb[0]+.691*rgb[1]+.068*rgb[2]),hsl=Paint.rgbToHsl(rgb),out=[hsl[0],lum,hsl[1]].map(elem=>elem*8);return out[0]%2==1&&(out[1]=8-out[1],out[2]=8-out[2]),out.push(arr[3]),out}function sortColors(list){return list.map(elem=>({val:colorValue(elem.baseColor),orig:elem})).sort(colorHigher).map(elem=>elem.orig)}function addPreset(){if(!props.current)return;let colour={...props.current,baseColor:toRaw(props.current.baseColor)},idx=1;for(;`Custom ${idx}`in userPresets.value;)idx++;let presetName=`Custom ${idx}`;userPresets.value[presetName]=colour,savePresets(),nextTick(()=>{let presetElements=document.querySelectorAll(`.paint-presets-item`),newPreset=Array.from(presetElements).find(el=>el.getAttribute(`data-preset-name`)===presetName);newPreset&&setFocusExternal(newPreset)})}function removePreset(name){let presetElements=document.querySelectorAll(`.paint-presets-item`),currentIndex=Array.from(presetElements).findIndex(el=>el.getAttribute(`data-preset-name`)===name);delete userPresets.value[name],savePresets(),nextTick(()=>{let group=presetGroups.value.find(g=>g.name===`user`);if(group)if(group.presets.length>0){let newPresetElements=document.querySelectorAll(`.paint-presets-item`);setFocusExternal(newPresetElements[Math.min(currentIndex,newPresetElements.length-1)])}else{let addButton=document.querySelector(`.presets-empty`);addButton&&setFocusExternal(addButton)}})}function savePresets(){settings$1.apply({userPaintPresets:JSON.stringify(Object.values(userPresets.value))})}return onMounted(async()=>{await settings$1.waitForData();let paints={};if(settings$1.values.userPaintPresets&&(paints=JSON.parse(settings$1.values.userPaintPresets.replace(/'/g,`"`)),typeof paints==`object`)){Array.isArray(paints)&&(paints=paints.reduce((res,paint,idx)=>({...res,[`Custom ${idx}`]:paint}),{}));let test=new Paint;for(let name in paints)try{test.paint=paints[name],paints[name]=test.paintObject}catch{delete paints[name]}}userPresets.value=paints}),(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$213,[(openBlock(!0),createElementBlock(Fragment,null,renderList(presetGroups.value,group=>(openBlock(),createElementBlock(`div`,_hoisted_2$172,[createBaseVNode(`span`,_hoisted_3$151,toDisplayString(_ctx.$t(`ui.color.${group.name}`))+`: `,1),createBaseVNode(`div`,_hoisted_4$126,[(openBlock(!0),createElementBlock(Fragment,null,renderList(group.presets,(preset,index)=>(openBlock(),createBlock(unref(bngPaintTile_default),{key:`${index}#${preset.name}`,size:24,paint:preset,"vehicle-name":`factory`,"paint-name":preset.name,"tooltip-position":`top`,class:`paint-presets-item`,"data-preset-name":preset.name,"with-menu":__props.editable&&group.editable,"custom-menu":[{label:`ui.common.delete`,action:()=>removePreset(preset.name)}],onClick:$event=>emit$1(`apply`,preset)},null,8,[`paint`,`paint-name`,`data-preset-name`,`with-menu`,`custom-menu`,`onClick`]))),128)),!group.presets||Object.keys(group.presets).length===0?withDirectives((openBlock(),createBlock(unref(bngButton_default),{key:0,class:`presets-empty`,accent:unref(ACCENTS).text,onClick:addPreset,"bng-nav-item":``},{default:withCtx(()=>[createTextVNode(toDisplayString(_ctx.$t(`ui.colorpicker.noPresets`)),1)]),_:1},8,[`accent`])),[[unref(BngOnUiNav_default),void 0,`ok`,{asMouse:!0,focusRequired:!0}]]):createCommentVNode(``,!0),group.presets&&Object.keys(group.presets).length>0&&__props.editable&&group.editable?withDirectives((openBlock(),createBlock(unref(bngButton_default),{key:1,class:`paint-presets-button`,accent:unref(ACCENTS).text,onClick:addPreset,icon:unref(icons).mathPlus,"bng-nav-item":``},null,8,[`accent`,`icon`])),[[unref(BngTooltip_default),_ctx.$t(`ui.colorpicker.colToPre`),`top`],[unref(BngOnUiNav_default),void 0,`ok`,{asMouse:!0,focusRequired:!0}]]):createCommentVNode(``,!0)])]))),256))]))}},PaintPresets_default=__plugin_vue_export_helper_default(_sfc_main$242,[[`__scopeId`,`data-v-469b2f89`]]),_hoisted_1$212={class:`paint-picker`},_hoisted_2$171={key:0,class:`paint-flex`},_hoisted_3$150={key:0,class:`paint-preview`,xmlns:`http://www.w3.org/2000/svg`,viewBox:`0 0 1 1`,preserveAspectRatio:`xMidYMid meet`},_hoisted_4$125={id:`light`,cy:`0.28`,cx:`0.35`,r:`0.3`,spreadMethod:`pad`},_hoisted_5$110=[`offset`],_hoisted_6$93=[`offset`],_hoisted_7$81={id:`colPreview`,x:`0`,y:`0`,width:`1`,height:`1`,patternUnits:`userSpaceOnUse`},_hoisted_8$67=[`fill`],_hoisted_9$60={key:1},_hoisted_10$51={key:0},_hoisted_11$45={key:2},_hoisted_12$34={key:0},_sfc_main$241={__name:`PaintPicker`,props:{modelValue:{type:[String,Object]},legacy:{type:Boolean,default:!1},presets:{type:Object,default:{}},presetsEditable:{type:Boolean,default:!1},showPresets:{type:Boolean,default:!0},showMain:{type:Boolean,default:!0},pickerMode:{type:String,default:`full_luminosity`},showText:{type:Boolean,default:!0},showPreview:{type:Boolean,default:!1},advancedOpen:{type:Boolean,default:!1},showAdvancedSwitch:{type:Boolean,default:!0}},emits:[`update:modelValue`,`change`],setup(__props,{expose:__expose,emit:__emit}){let props=__props;__expose({paintUpdated,setAdvancedVisible}),watch(()=>props.modelValue,init$3);let emitter=__emit,advanced=ref(props.advancedOpen),paint=reactive(new Paint({legacy:props.legacy}));watch(()=>props.legacy,val=>paint.legacy=val);let paintPicker=ref(paint),isPaintObject=!1,factoryPresets=computed(()=>props.presets||{}),hslColour=computed(()=>Paint.hslCssStr(paint.hsl));function init$3(){let defPaint=[1,1,1,1,0,1,1,0];if(!props.modelValue){paint.paint=defPaint;return}if(isPaintObject=props.modelValue instanceof Paint,isPaintObject){paint.paint=props.modelValue.paintObject;return}let newpaint=new Paint({legacy:props.legacy});try{newpaint.paint=props.modelValue}catch{newpaint.paint=defPaint}newpaint.paintString!==paint.paintString&&(paint.paint=newpaint.paintObject)}function returnPaint(){let res;isPaintObject?(res=props.modelValue,res.paint=paint.paintObject):res=paint.paintString,emitter(`change`,res),emitter(`update:modelValue`,res)}function paintUpdated(){init$3(),returnPaint()}function setAdvancedVisible(visible){advanced.value=visible}function applyPreset(preset){paint.paint=preset,returnPaint()}return init$3(),(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$212,[__props.showPreview||__props.showPresets?(openBlock(),createElementBlock(`div`,_hoisted_2$171,[__props.showPreview?(openBlock(),createElementBlock(`svg`,_hoisted_3$150,[createBaseVNode(`defs`,null,[createBaseVNode(`radialGradient`,_hoisted_4$125,[createBaseVNode(`stop`,mergeProps({offset:.1+.2*(1-paint.roughness)},{"stop-opacity":.4+.2*paint.roughness},{"stop-color":`#fff`}),null,16,_hoisted_5$110),createBaseVNode(`stop`,{offset:1-paint.roughness*.5,"stop-opacity":`0.0`,"stop-color":`#fff`},null,8,_hoisted_6$93)]),_cache[16]||=createBaseVNode(`radialGradient`,{id:`shadow`,cy:`0.43`,cx:`0.45`,r:`0.55`,spreadMethod:`pad`},[createBaseVNode(`stop`,{offset:`0.7`,"stop-opacity":`0.0`,"stop-color":`#000`}),createBaseVNode(`stop`,{offset:`0.85`,"stop-opacity":`0.2`,"stop-color":`#000`}),createBaseVNode(`stop`,{offset:`1.0`,"stop-opacity":`0.5`,"stop-color":`#000`})],-1),createBaseVNode(`pattern`,_hoisted_7$81,[_cache[13]||=createBaseVNode(`image`,{x:`0`,y:`0`,height:`1`,width:`1`,"xlink:href":`/ui/lib/int/colorpicker/color-chrome.png`},null,-1),createBaseVNode(`rect`,mergeProps({y:`0`,x:`0`,width:`1`,height:`1`,fill:`hsl(${hslColour.value})`},{"fill-opacity":paint.alpha/2},{stroke:`transparent`}),null,16,_hoisted_8$67),_cache[14]||=createBaseVNode(`rect`,{y:`0`,x:`0`,width:`1`,height:`1`,fill:`url(#light)`,stroke:`transparent`},null,-1),_cache[15]||=createBaseVNode(`rect`,{y:`0`,x:`0`,width:`1`,height:`1`,fill:`url(#shadow)`,stroke:`transparent`},null,-1)])]),_cache[17]||=createBaseVNode(`circle`,{cy:`0.5`,cx:`0.5`,r:`0.5`,fill:`url(#colPreview)`,stroke:`transparent`},null,-1)])):createCommentVNode(``,!0),__props.showPresets?(openBlock(),createBlock(PaintPresets_default,{key:1,presets:factoryPresets.value,"show-text":__props.showText,editable:__props.presetsEditable,current:paint.paintObject,onApply:applyPreset},null,8,[`presets`,`show-text`,`editable`,`current`])):createCommentVNode(``,!0)])):createCommentVNode(``,!0),__props.showMain?(openBlock(),createElementBlock(`div`,_hoisted_9$60,[__props.showText&&_ctx.$slots.default?(openBlock(),createElementBlock(`span`,_hoisted_10$51,[renderSlot(_ctx.$slots,`default`,{},void 0,!0)])):createCommentVNode(``,!0),createVNode(unref(bngColorPicker_default),{modelValue:paintPicker.value,"onUpdate:modelValue":_cache[0]||=$event=>paintPicker.value=$event,onChange:_cache[1]||=$event=>returnPaint(),view:__props.pickerMode,"show-text":__props.showText},null,8,[`modelValue`,`view`,`show-text`])])):createCommentVNode(``,!0),__props.showMain?(openBlock(),createElementBlock(`div`,_hoisted_11$45,[__props.showAdvancedSwitch?(openBlock(),createElementBlock(`h3`,_hoisted_12$34,[createVNode(unref(bngSwitch_default),{modelValue:advanced.value,"onUpdate:modelValue":_cache[2]||=$event=>advanced.value=$event},{default:withCtx(()=>[createTextVNode(toDisplayString(_ctx.$t(`ui.color.configurations`)),1)]),_:1},8,[`modelValue`])])):createCommentVNode(``,!0),advanced.value?(openBlock(),createElementBlock(`div`,{key:1,class:normalizeClass([`paint-slider-group`,{"paint-slider-group-fullrow":_ctx.$simplemenu.value}])},[__props.legacy?(openBlock(),createBlock(unref(bngColorSlider_default),{key:0,modelValue:paint.alpha,"onUpdate:modelValue":_cache[3]||=$event=>paint.alpha=$event,max:2,onChange:_cache[4]||=$event=>returnPaint(),fill:[`hsla(${hslColour.value}, 0)`,`hsla(${hslColour.value}, 2)`]},{default:withCtx(()=>[createTextVNode(toDisplayString(__props.showText?`${_ctx.$t(`ui.color.chrominess`)} (${paint.alphaPercent}%)`:null),1)]),_:1},8,[`modelValue`,`fill`])):createCommentVNode(``,!0),createVNode(unref(bngColorSlider_default),{modelValue:paint.metallic,"onUpdate:modelValue":_cache[5]||=$event=>paint.metallic=$event,onChange:_cache[6]||=$event=>returnPaint()},{default:withCtx(()=>[createTextVNode(toDisplayString(__props.showText?`${_ctx.$t(`ui.color.metallic`)} (${paint.metallicPercent}%)`:null),1)]),_:1},8,[`modelValue`]),createVNode(unref(bngColorSlider_default),{modelValue:paint.roughness,"onUpdate:modelValue":_cache[7]||=$event=>paint.roughness=$event,onChange:_cache[8]||=$event=>returnPaint()},{default:withCtx(()=>[createTextVNode(toDisplayString(__props.showText?`${_ctx.$t(`ui.color.roughness`)} (${paint.roughnessPercent}%)`:null),1)]),_:1},8,[`modelValue`]),createVNode(unref(bngColorSlider_default),{modelValue:paint.clearcoat,"onUpdate:modelValue":_cache[9]||=$event=>paint.clearcoat=$event,onChange:_cache[10]||=$event=>returnPaint()},{default:withCtx(()=>[createTextVNode(toDisplayString(__props.showText?`${_ctx.$t(`ui.color.clearCoat`)} (${paint.clearcoatPercent}%)`:null),1)]),_:1},8,[`modelValue`]),createVNode(unref(bngColorSlider_default),{modelValue:paint.clearcoatRoughness,"onUpdate:modelValue":_cache[11]||=$event=>paint.clearcoatRoughness=$event,onChange:_cache[12]||=$event=>returnPaint()},{default:withCtx(()=>[createTextVNode(toDisplayString(__props.showText?`${_ctx.$t(`ui.color.clearCoatRoughness`)} (${paint.clearcoatRoughnessPercent}%)`:null),1)]),_:1},8,[`modelValue`])],2)):createCommentVNode(``,!0)])):createCommentVNode(``,!0)]))}},PaintPicker_default=__plugin_vue_export_helper_default(_sfc_main$241,[[`__scopeId`,`data-v-2d18c0ad`]]),_hoisted_1$211={class:`paintingWrapper`},_hoisted_2$170={style:{overflow:`auto`}},_hoisted_3$149=[`tab-heading`],_hoisted_4$124={class:`paintPicker`},_hoisted_5$109={key:0,class:`clearCoatSection`},_hoisted_6$92={key:0,class:`innerShoppingCart`},_hoisted_7$80={class:`shoppingCartTable`},_hoisted_8$66={class:`price`},_hoisted_9$59={class:`price--total`},_hoisted_10$50={class:`purchase-button-container`},_sfc_main$240={__name:`Painting`,props:{noHeader:Boolean},setup(__props,{expose:__expose}){let{units,events:events$3}=useBridge(),presets=ref({});Lua_default.career_modules_painting.getFactoryPaint().then(data=>presets.value=data);let colorClass=ref(`factory`),paintIndex=ref(0),chosenPackage=ref([{},{},{}]),changedPaint=ref(!1),totalPrice=ref(0),clearCoatActive=ref(!1),clearCoatPolish=ref(0),paints=ref([]),originalPaints=ref([]),prices=ref({}),colorClassData=ref({}),canPay=ref(!1),paintPicker=ref(null),paintClassTabInfo=[{title:`Factory`},{title:`Gloss`,paintClasses:[{id:`matte`,title:`Matte`},{id:`semiGloss`,title:`Semi Gloss`},{id:`gloss`,title:`Full Gloss`}]},{title:`Metallic`,paintClasses:[{id:`semiMetallic`,title:`Semi Metallic`},{id:`metallic`,title:`Metallic`},{id:`chrome`,title:`Chrome`}]},{title:`Custom`}],clearCoatUpdateCallback=newValue=>{clearCoatPolish.value=0,changeClearCoatPolish(0),enableClearCoat(newValue)},enableClearCoat=enabled=>{paints.value[paintIndex.value]._clearcoat=enabled?1:0,paintPicker.value.paintUpdated()},changeClearCoatPolish=value=>{paints.value[paintIndex.value]._clearcoatRoughness=-.13*value+.13,paintPicker.value.paintUpdated()},getShoppingCartTable=()=>{let res=[];for(let[index,paintOptions]of chosenPackage.value.entries())Object.keys(paintOptions).length&&(res.push({name:`Paint `+(index+1)+`: `+getNicePaintClassName(paintOptions.paintClass),price:prices.value.basePrices[paintOptions.paintClass].money.amount,topLevel:!0,index}),paintOptions.clearCoat&&(res.push({name:`Clearcoat`,price:prices.value.clearcoatBase.money.amount}),res.push({name:`Extra Clearcoat Polish`,price:prices.value.clearcoatPolishFactor.money.amount*paintOptions.clearCoatPolish})));return res};events$3.on(`sendPaintingShoppingCartData`,data=>{canPay.value=data.canPay,totalPrice.value=data.totalPrice.money.amount}),Lua_default.career_modules_painting.getPaintData().then(data=>{if(prices.value=data.prices,!data||!Array.isArray(data.colors)){paints.value=[];return}paints.value=data.colors.map(val=>new Paint({paint:val})),originalPaints.value=data.colors.map(val=>new Paint({paint:val})),colorClassData.value=data.colorClassData});let getPickerShowPresets=()=>colorClass.value==`factory`,getPickerPresetsEditable=()=>colorClass.value==`custom`,showPickerMain=()=>colorClass.value!=`factory`,showClearCoatOption=()=>colorClass.value!=`factory`&&colorClass.value!=`custom`,setCurrentColorClass=()=>{paintPicker.value.setAdvancedVisible(!1),paints.value[paintIndex.value]._metallic=colorClassData.value[colorClass.value].metallic,paints.value[paintIndex.value]._roughness=colorClassData.value[colorClass.value].roughness,clearCoatActive.value=!1,enableClearCoat(!1)},changedPaintIndexTab=tab=>{paintIndex.value=tab.index,colorClass.value=chosenPackage.value[paintIndex.value].paintClass||`factory`,paintPicker.value.setAdvancedVisible(colorClass.value==`custom`),clearCoatActive.value=chosenPackage.value[paintIndex.value].clearCoat,clearCoatPolish.value=chosenPackage.value[paintIndex.value].clearCoatPolish},changedTopLevelPaintClassTab=tab=>{let classTab={Factory:`factory`,Custom:`custom`,Gloss:`semiGloss`,Metallic:`metallic`}[tab.heading];classTab&&changedPaintClassTab(classTab)},changedPaintClassTab=paintClass=>{if(paintClass==`factory`){colorClass.value=`factory`;return}if(paintClass==`custom`){colorClass.value=`custom`,paintPicker.value.setAdvancedVisible(!0),clearCoatActive.value=!1;return}colorClass.value=paintClass,setCurrentColorClass()};function resetPaint(index){chosenPackage.value[index]={},Object.assign(paints.value[index],originalPaints.value[index]);let chosenPackageEmpty=!0;for(let[index$1,color]of Object.entries(chosenPackage.value))Object.keys(color).length!==0&&(chosenPackageEmpty=!1);chosenPackageEmpty&&(changedPaint.value=!1),Lua_default.career_modules_painting.setPaints(paints.value.map(paint=>paint.paintObject),chosenPackage.value)}function onChange(){colorClass.value==`factory`&&(clearCoatActive.value=!1),chosenPackage.value[paintIndex.value].paintClass=colorClass.value,chosenPackage.value[paintIndex.value].clearCoat=clearCoatActive.value,chosenPackage.value[paintIndex.value].clearCoatPolish=clearCoatPolish.value,changedPaint.value=!0,Lua_default.career_modules_painting.setPaints(paints.value.map(paint=>paint.paintObject),chosenPackage.value)}let NICE_PAINT_CLASS_NAMES={factory:`Factory`,semiGloss:`Semi Gloss`,gloss:`Gloss`,semiMetallic:`Semi Metallic`,metallic:`Metallic`,matte:`Matte`,chrome:`Chrome`,custom:`Custom`},getNicePaintClassName=paintClass=>NICE_PAINT_CLASS_NAMES[paintClass];function headerClass(tab){return{"painting-tab":!0,[`painting-tab-${tab.index}`]:!0}}let headerVars=computed(()=>paints.value.reduce((res,paint,idx)=>({...res,[`--painting-dot-${idx}`]:`hsl(${Paint.hslCssStr(paint.hsl)})`}),{})),apply$1=()=>Lua_default.career_modules_painting.apply(),close=()=>Lua_default.career_modules_painting.close();return onMounted(()=>{Lua_default.career_modules_painting.onUIOpened()}),onUnmounted(close),__expose({apply:apply$1,close}),(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$211,[withDirectives((openBlock(),createBlock(unref(bngCard_default),{class:`paintingPage`},{default:withCtx(()=>[createBaseVNode(`div`,_hoisted_2$170,[__props.noHeader?createCommentVNode(``,!0):(openBlock(),createBlock(unref(bngCardHeading_default),{key:0},{default:withCtx(()=>[..._cache[3]||=[createTextVNode(` Painting `,-1)]]),_:1})),createVNode(unref(tabs_default),{class:`bng-tabs`,"selected-index":0,"make-tab-header-classes":headerClass,style:normalizeStyle(headerVars.value),onChange:changedPaintIndexTab},{default:withCtx(()=>[(openBlock(!0),createElementBlock(Fragment,null,renderList(paints.value,(paint,idx)=>(openBlock(),createBlock(unref(tabs_default),{key:idx,"tab-heading":_ctx.$t(`ui.trackBuilder.matEditor.paint`)+` `+(idx+1),class:`bng-tabs`,"selected-index":0,onChange:changedTopLevelPaintClassTab},{default:withCtx(()=>[(openBlock(),createElementBlock(Fragment,null,renderList(paintClassTabInfo,(paintClassTab,idx$1)=>createBaseVNode(`div`,{key:idx$1,"tab-heading":paintClassTab.title,style:{margin:`0.3em`,"background-color":`#00000000`}},[(openBlock(!0),createElementBlock(Fragment,null,renderList(paintClassTab.paintClasses,(paintClass,idx$2)=>(openBlock(),createBlock(unref(bngButton_default),{key:idx$2,onClick:$event=>changedPaintClassTab(paintClass.id),accent:colorClass.value==paintClass.id?void 0:unref(ACCENTS).secondary,class:`paint-class-button`},{default:withCtx(()=>[createTextVNode(toDisplayString(paintClass.title),1)]),_:2},1032,[`onClick`,`accent`]))),128))],8,_hoisted_3$149)),64))]),_:2},1032,[`tab-heading`]))),128))]),_:1},8,[`style`]),createVNode(unref(bngCard_default),null,{default:withCtx(()=>[createBaseVNode(`div`,_hoisted_4$124,[createVNode(PaintPicker_default,{ref_key:`paintPicker`,ref:paintPicker,modelValue:paints.value[paintIndex.value],"onUpdate:modelValue":_cache[0]||=$event=>paints.value[paintIndex.value]=$event,"show-main":showPickerMain(),presets:getPickerShowPresets()?presets.value:void 0,"presets-editable":getPickerPresetsEditable(),"advanced-open":!1,"show-advanced-switch":!1,onChange},null,8,[`modelValue`,`show-main`,`presets`,`presets-editable`]),showClearCoatOption()?(openBlock(),createElementBlock(`div`,_hoisted_5$109,[createVNode(unref(bngSwitch_default),{modelValue:clearCoatActive.value,"onUpdate:modelValue":_cache[1]||=$event=>clearCoatActive.value=$event,onValueChanged:clearCoatUpdateCallback},{default:withCtx(()=>[createTextVNode(` Add Clear Coat (Baseprice: `+toDisplayString(unref(units).beamBucks(prices.value.clearcoatBase.money.amount))+`) `,1)]),_:1},8,[`modelValue`]),clearCoatActive.value?(openBlock(),createBlock(unref(bngColorSlider_default),{key:0,style:{"margin-top":`0.7em`},modelValue:clearCoatPolish.value,"onUpdate:modelValue":_cache[2]||=$event=>clearCoatPolish.value=$event,onChange:changeClearCoatPolish},{default:withCtx(()=>[..._cache[4]||=[createTextVNode(` Clear Coat Polish `,-1)]]),_:1},8,[`modelValue`])):createCommentVNode(``,!0)])):createCommentVNode(``,!0)])]),_:1})])]),_:1})),[[unref(BngBlur_default),1]]),createVNode(unref(bngCard_default),{class:`shoppingCart`},{default:withCtx(()=>[createVNode(unref(bngCardHeading_default),null,{default:withCtx(()=>[..._cache[5]||=[createTextVNode(`Shopping Cart`,-1)]]),_:1}),changedPaint.value?(openBlock(),createElementBlock(`div`,_hoisted_6$92,[createBaseVNode(`table`,_hoisted_7$80,[_cache[9]||=createBaseVNode(`thead`,null,[createBaseVNode(`tr`,null,[createBaseVNode(`th`),createBaseVNode(`th`,{class:`article`},`Option`),createBaseVNode(`th`,{class:`price`},`Price`)])],-1),createBaseVNode(`tbody`,null,[(openBlock(!0),createElementBlock(Fragment,null,renderList(getShoppingCartTable(),(date,idx)=>(openBlock(),createElementBlock(`tr`,null,[createBaseVNode(`th`,null,[date.topLevel?(openBlock(),createBlock(unref(bngButton_default),{key:0,onClick:$event=>resetPaint(date.index)},{default:withCtx(()=>[..._cache[6]||=[createTextVNode(`remove`,-1)]]),_:1},8,[`onClick`])):createCommentVNode(``,!0)]),createBaseVNode(`th`,{class:normalizeClass(date.topLevel?`article`:`article--subLevel`)},toDisplayString(date.name),3),createBaseVNode(`th`,_hoisted_8$66,toDisplayString(unref(units).beamBucks(date.price)),1)]))),256)),createBaseVNode(`tr`,null,[_cache[7]||=createBaseVNode(`th`,null,null,-1),_cache[8]||=createBaseVNode(`th`,{class:`article--total`},`Total`,-1),createBaseVNode(`th`,_hoisted_9$59,toDisplayString(unref(units).beamBucks(totalPrice.value)),1)])])])])):createCommentVNode(``,!0),createBaseVNode(`div`,_hoisted_10$50,[withDirectives((openBlock(),createBlock(unref(bngButton_default),{class:`purchase-button`,disabled:!canPay.value||!changedPaint.value,"show-hold":``},{default:withCtx(()=>[..._cache[10]||=[createTextVNode(` Purchase and Apply `,-1)]]),_:1},8,[`disabled`])),[[unref(BngOnUiNav_default),void 0,`ok`,{asMouse:!0,focusRequired:!0}],[unref(BngClick_default),{holdCallback:()=>apply$1(),holdDelay:1e3,repeatInterval:0}]])])]),_:1})]))}},Painting_default=__plugin_vue_export_helper_default(_sfc_main$240,[[`__scopeId`,`data-v-9dc00fbe`]]),_sfc_main$239={__name:`PaintingMain`,setup(__props){useComputerStore();let elPainting=ref(),close=()=>elPainting.value.close();return(_ctx,_cache)=>(openBlock(),createBlock(ComputerWrapper_default,{path:[`Painting`],title:`Painting`,back:``,onBack:close},{default:withCtx(()=>[createVNode(Painting_default,{ref_key:`elPainting`,ref:elPainting,"no-header":``},null,512)]),_:1}))}},PaintingMain_default=_sfc_main$239;const usePartInventoryStore=defineStore(`partInventory`,()=>{let{events:events$3}=useBridge(),partInventoryData=ref({}),newPartsPopupOpen=ref(!1),newParts=ref([]),searchString=ref(``);function requestInitialData(){Lua_default.career_modules_partInventory.sendUIData()}function closeNewPartsPopup(){newPartsPopupOpen.value=!1}function closeMenu(){searchString.value=``,Lua_default.career_modules_partInventory.closeMenu()}function partInventoryClosed(){Lua_default.career_modules_partInventory.partInventoryClosed()}function dispose$2(){events$3.off(`partInventoryData`)}function openNewPartsPopup(newPartIds){newPartsPopupOpen.value=!0,newParts.value=[];for(let i=0;ipart.description.description.toLowerCase().includes(searchString.value.toLowerCase())||part.name.toLowerCase().includes(searchString.value.toLowerCase()),searchValueChanged=()=>{partInventoryData.value.partList.filter?partInventoryData.value.filteredPartList=partInventoryData.value.partList.filter(doesPartPassFilter):partInventoryData.value.filteredPartList={}};return watch(()=>searchString.value,searchValueChanged),events$3.on(`partInventoryData`,data=>{partInventoryData.value=data,searchValueChanged()}),{closeMenu,closeNewPartsPopup,dispose:dispose$2,newParts,newPartsPopupOpen,openNewPartsPopup,partInventoryClosed,partInventoryData,requestInitialData,searchString}});var _hoisted_1$210={style:{padding:`1em`}},_hoisted_2$169={class:`selectButtons`},_hoisted_3$148={class:`part-info-row`},_hoisted_4$123={class:`partList`},_hoisted_5$108=[`onClick`],_hoisted_6$91={class:`part-info-col`},_hoisted_7$79={class:`part-name`},_hoisted_8$65={class:`part-info-row`},_hoisted_9$58={class:`right`},_hoisted_10$49={class:`right`},_hoisted_11$44={class:`center`},_hoisted_12$33={class:`popup-buttons`},_sfc_main$238={__name:`PartSellingPopup`,props:{parts:{type:Array,default:[]}},emits:[`return`],setup(__props,{emit:__emit}){useUINavScope(`partSelling`);let{units}=useBridge(),partsChecked=ref([]),emit$1=__emit,props=__props,saleData=computed(()=>{let total=0,numberOfSelected=0;for(let[index,isChecked]of Object.entries(partsChecked.value))if(isChecked){let part=props.parts[index];total+=part.data.finalValue,numberOfSelected+=1}return{price:total,numberOfSelected}}),buildRefList=()=>{for(let i=0;i{for(let i=0;i{let partIds=[];for(let[index,isChecked]of Object.entries(partsChecked.value))if(isChecked){let part=props.parts[index];partIds.push(part.data.id)}Lua_default.career_modules_partInventory.sellParts(partIds),close()},close=()=>{emit$1(`return`,!0)};return onMounted(buildRefList),(_ctx,_cache)=>withDirectives((openBlock(),createBlock(unref(bngCard_default),{"bng-ui-scope":`partSelling`,class:`sellingCard`},{default:withCtx(()=>[createVNode(unref(bngCardHeading_default),null,{default:withCtx(()=>[..._cache[2]||=[createTextVNode(`Sell Parts`,-1)]]),_:1}),createBaseVNode(`div`,_hoisted_1$210,[createBaseVNode(`div`,_hoisted_2$169,[_cache[5]||=createTextVNode(` Select: `,-1),createBaseVNode(`div`,_hoisted_3$148,[createVNode(unref(bngButton_default),{accent:unref(ACCENTS).secondary,onClick:_cache[0]||=$event=>selectAll(!0)},{default:withCtx(()=>[..._cache[3]||=[createTextVNode(` All `,-1)]]),_:1},8,[`accent`]),createVNode(unref(bngButton_default),{accent:unref(ACCENTS).secondary,onClick:_cache[1]||=$event=>selectAll(!1)},{default:withCtx(()=>[..._cache[4]||=[createTextVNode(` None `,-1)]]),_:1},8,[`accent`])])]),createBaseVNode(`div`,_hoisted_4$123,[(openBlock(!0),createElementBlock(Fragment,null,renderList(__props.parts,(part,index)=>(openBlock(),createElementBlock(`div`,{class:normalizeClass([`part-item`,partsChecked.value[index]?`partSelected`:``]),"bng-nav-item":``,onClick:$event=>partsChecked.value[index]=!partsChecked.value[index]},[createVNode(unref(bngIcon_default),{class:`selectionCheckbox`,type:partsChecked.value[index]?unref(icons).checkboxOn:unref(icons).checkboxOff},null,8,[`type`]),createBaseVNode(`div`,_hoisted_6$91,[createBaseVNode(`div`,null,[createBaseVNode(`span`,_hoisted_7$79,toDisplayString(part.name),1)]),createBaseVNode(`div`,_hoisted_8$65,[createBaseVNode(`span`,_hoisted_9$58,toDisplayString(part.mileage),1),createBaseVNode(`span`,_hoisted_10$49,[createVNode(unref(bngPropVal_default),{iconType:unref(icons).beamCurrency,valueLabel:part.valueFormatted},null,8,[`iconType`,`valueLabel`])]),createBaseVNode(`span`,_hoisted_11$44,toDisplayString(part.model),1)])])],10,_hoisted_5$108))),256))]),createBaseVNode(`div`,_hoisted_12$33,[withDirectives((openBlock(),createBlock(unref(bngButton_default),{disabled:saleData.value.numberOfSelected<=0,"show-hold":``},{default:withCtx(()=>[createTextVNode(` Sell `+toDisplayString(saleData.value.numberOfSelected)+` parts for `,1),createVNode(unref(bngUnit_default),{money:saleData.value.price},null,8,[`money`])]),_:1},8,[`disabled`])),[[unref(BngClick_default),{holdCallback:sellSelectedParts,holdDelay:1e3,repeatInterval:0}]]),createVNode(unref(bngButton_default),{accent:unref(ACCENTS).attention,onClick:close},{default:withCtx(()=>[..._cache[6]||=[createTextVNode(` Cancel `,-1)]]),_:1},8,[`accent`])])])]),_:1})),[[unref(BngOnUiNav_default),close,`back,menu`]])}},PartSellingPopup_default=__plugin_vue_export_helper_default(_sfc_main$238,[[`__scopeId`,`data-v-c325ab7a`]]),_hoisted_1$209={style:{height:`100%`,color:`white`}},_hoisted_2$168={key:0},_hoisted_3$147={class:`veh-part-caption`},_hoisted_4$122={class:`veh-name`},_hoisted_5$107={class:`veh-name-count`},_hoisted_6$90={class:`part-item`,"bng-ui-scope":`veh-part-inv`},_hoisted_7$78={key:0,class:`part-info-col`},_hoisted_8$64={class:`part-name`},_hoisted_9$57={class:`part-info-row`},_hoisted_10$48={class:`right`},_hoisted_11$43={class:`right`},_hoisted_12$32={key:0,class:`center`},_hoisted_13$28={key:1,class:`center`},_hoisted_14$26={class:`center`},_hoisted_15$25={key:0},_hoisted_16$25={class:`center`},_hoisted_17$20={key:0},immediateLimit=15,_sfc_main$237={__name:`PartList`,emits:[`partSold`],setup(__props,{emit:__emit}){let{units}=useBridge(),emit$1=__emit,partInventoryStore=usePartInventoryStore(),groupBy=ref(`location`),groups=ref([]),accordionItems=ref([]),disableInstallButtons=ref(!1),addExpandedFuncToGroup=group=>{group.onExpanded=state=>{let grp=groups.value.find(g=>g.id===group.id);if(grp.expanded=state,!state){delete grp.ready;let elm=document.querySelector(`[data-groupid="${group.id}"] > .bng-accitem-caption`);elm&&elm.focus();return}`ready`in grp||(grp.ready=!1,setTimeout(()=>{let grp$1=groups.value.find(g=>g.id===group.id);grp$1&&typeof grp$1.ready==`boolean`&&(grp$1.ready=!0)},100))}},openSellPopup=async()=>{await addPopup(PartSellingPopup_default,{parts:groups.value[0].parts}).promise&&emit$1(`partSold`)};watchEffect(()=>{if(disableInstallButtons.value=!1,!partInventoryStore||!Array.isArray(partInventoryStore.partInventoryData.partList)||partInventoryStore.partInventoryData.partList.length===0)return[];let res=[];if(groupBy.value==`location`){let group={id:0,name:` Inventory`,parts:[],expanded:!1,icon:icons.BNGFolder};addExpandedFuncToGroup(group),res.push(group);for(let[vehId,vehicle]of Object.entries(partInventoryStore.partInventoryData.vehicles)){let group$1={id:vehId,name:vehicle.niceName,parts:[],expanded:!1,thumbnail:partInventoryStore.partInventoryData.vehicles[vehId].thumbnail};addExpandedFuncToGroup(group$1),res.push(group$1)}}for(let part of partInventoryStore.partInventoryData.filteredPartList){let item={name:part.missingFile?`Missing File`:part.description.description,model:part.vehicleModel,mileage:units.buildString(`length`,part.partCondition.odometer,0),valueFormatted:units.beamBucks(part.finalValue),location:part.location,locationName:part.location===0?` Inventory`:partInventoryStore.partInventoryData.vehicles[part.location].niceName,functions:{install:!1,uninstall:!1,sell:!1},data:part};!part.missingFile&&part.accessible&&(item.functions.install=part.fitsCurrentVehicle&&part.location!==partInventoryStore.partInventoryData.currentVehicle&&(part.location===0||!partInventoryStore.partInventoryData.brokenVehicleInventoryIds[part.location])&&!partInventoryStore.partInventoryData.brokenVehicleInventoryIds[partInventoryStore.partInventoryData.currentVehicle],item.functions.uninstall=part.location!==0&&!part.isInCoreSlot&&!partInventoryStore.partInventoryData.brokenVehicleInventoryIds[part.location],item.functions.sell=part.location===0);let groupId=item[groupBy.value],group=res.find(g=>g.id==groupId);group||(group={id:groupId,name:item[`${groupBy.value}Name`]||item[groupBy.value],parts:[],expanded:!1},part.location>0?group.thumbnail=partInventoryStore.partInventoryData.vehicles[part.location].thumbnail:group.icon=icons.BNGFolder,addExpandedFuncToGroup(group),res.push(group)),group.parts.push(item)}if(res.length>0){let sorter=(a$1,b)=>a$1.name.localeCompare(b.name);res.sort(sorter);for(let group of res)group.parts.sort(sorter)}for(let group of groups.value)if(group.ready){let grp=res.find(g=>g.name===group.name);grp&&(grp.expanded=!0,grp.ready=!0)}groups.value=res});let confirmSellPart=async partToSell=>{await openConfirmation(partToSell.description.description,`Do you want to sell this part for ${units.beamBucks(partToSell.finalValue)}?`,[{label:$translate.instant(`ui.common.yes`),value:!0,extras:{default:!0}},{label:$translate.instant(`ui.common.no`),value:!1,extras:{accent:ACCENTS.secondary}}])&&sellPart(partToSell)},sellPart=part=>{Lua_default.career_modules_partInventory.sellParts([part.id]),emit$1(`partSold`)};return(_ctx,_cache)=>withDirectives((openBlock(),createElementBlock(`div`,_hoisted_1$209,[createVNode(unref(bngInput_default),{class:`searchField`,"floating-label":`Search`,"leading-icon":unref(icons).search,modelValue:unref(partInventoryStore).searchString,"onUpdate:modelValue":_cache[0]||=$event=>unref(partInventoryStore).searchString=$event,modelModifiers:{trim:!0}},null,8,[`leading-icon`,`modelValue`]),withDirectives((openBlock(),createBlock(unref(bngCard_default),{style:{"max-height":`90%`}},{default:withCtx(()=>[unref(partInventoryStore)?(openBlock(),createBlock(unref(accordion_default),{key:1,class:`part-groups`,singular:``},{default:withCtx(()=>[(openBlock(!0),createElementBlock(Fragment,null,renderList(groups.value,(group,index)=>(openBlock(),createBlock(unref(accordionItem_default),{key:group.id,"data-groupid":group.id,ref_for:!0,ref_key:`accordionItems`,ref:accordionItems,navigable:``,onExpanded:group.onExpanded,onSelected:$event=>accordionItems.value[index]?accordionItems.value[index].captionClick():void 0},{caption:withCtx(()=>[createBaseVNode(`div`,_hoisted_3$147,[group.icon?(openBlock(),createBlock(unref(bngIcon_default),{key:0,class:`veh-icon`,type:group.icon},null,8,[`type`])):createCommentVNode(``,!0),group.thumbnail?(openBlock(),createElementBlock(`div`,{key:1,class:`veh-preview`,style:normalizeStyle({backgroundImage:`url('${group.thumbnail}')`})},null,4)):createCommentVNode(``,!0),createBaseVNode(`span`,_hoisted_4$122,[createTextVNode(toDisplayString(group.name)+` `,1),createBaseVNode(`span`,_hoisted_5$107,`(`+toDisplayString(group.parts.length)+`)`,1)])])]),default:withCtx(()=>[group.name==` Inventory`?(openBlock(),createBlock(unref(bngButton_default),{key:0,accent:unref(ACCENTS).outlined,onClick:_cache[1]||=$event=>openSellPopup()},{default:withCtx(()=>[..._cache[2]||=[createTextVNode(` Sell Parts `,-1)]]),_:1},8,[`accent`])):createCommentVNode(``,!0),(openBlock(!0),createElementBlock(Fragment,null,renderList(group.parts,(part,index$1)=>withDirectives((openBlock(),createElementBlock(`div`,_hoisted_6$90,[group.ready||index$1confirmSellPart(part.data)},{default:withCtx(()=>[..._cache[3]||=[createTextVNode(` Sell `,-1)]]),_:1},8,[`accent`,`onClick`])):createCommentVNode(``,!0)])),[[unref(BngOnUiNav_default),()=>group.onExpanded(!1),`back`]])),256))]),_:2},1032,[`data-groupid`,`onExpanded`,`onSelected`]))),128))]),_:1})):(openBlock(),createElementBlock(`div`,_hoisted_2$168,` Please wait... `))]),_:1})),[[unref(BngDisabled_default),!unref(partInventoryStore)]])])),[[unref(BngBlur_default)]])}},PartList_default=__plugin_vue_export_helper_default(_sfc_main$237,[[`__scopeId`,`data-v-7c222f4e`]]),_hoisted_1$208={style:{width:`100%`}},_sfc_main$236={__name:`PartInventoryAddedParts`,props:{parts:{type:Object,default:{}}},setup(__props){let{units}=useBridge(),getLocationName=part=>part.location?`Vehicle No. `+part.location+` (`+part.vehicleModel+`)`:`Inventory`;return(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,null,[_cache[1]||=createTextVNode(` The following additional parts have been added to the vehicle from your inventory to fill the core slots: `,-1),createBaseVNode(`table`,_hoisted_1$208,[_cache[0]||=createBaseVNode(`thead`,null,[createBaseVNode(`tr`,null,[createBaseVNode(`th`,null,`id`),createBaseVNode(`th`,null,`Description`),createBaseVNode(`th`,null,`Location`),createBaseVNode(`th`,null,`Mileage`),createBaseVNode(`th`,null,`Part Value`)])],-1),createBaseVNode(`tbody`,null,[(openBlock(!0),createElementBlock(Fragment,null,renderList(__props.parts,(part,key)=>(openBlock(),createElementBlock(`tr`,{key},[createBaseVNode(`td`,null,toDisplayString(part.id),1),createBaseVNode(`td`,null,toDisplayString(part.description.description),1),createBaseVNode(`td`,null,toDisplayString(getLocationName(part)),1),createBaseVNode(`td`,null,toDisplayString(unref(units).buildString(`length`,part.partCondition.odometer,0)),1),createBaseVNode(`td`,null,toDisplayString(unref(units).beamBucks(part.finalValue)),1)]))),128))])])]))}},PartInventoryAddedParts_default=__plugin_vue_export_helper_default(_sfc_main$236,[[`__scopeId`,`data-v-8dbd3a82`]]),_sfc_main$235={__name:`PartInventoryMain`,setup(__props){useComputerStore();let wrapper=ref(),partInventoryStore=usePartInventoryStore();watch(()=>partInventoryStore.newPartsPopupOpen,(newVal,oldVal)=>newVal&&confirmAddedParts());let confirmAddedParts=async vehicle=>{await openMessage(``,{component:markRaw(PartInventoryAddedParts_default),props:{parts:partInventoryStore.newParts}}),closeNewPartsPopup()},updateCareerStatus=()=>{wrapper.value.statusUpdate()};onBeforeMount(()=>{partInventoryStore.requestInitialData()}),onUnmounted(()=>{partInventoryStore.partInventoryClosed(),partInventoryStore.$dispose()});let close=()=>{partInventoryStore.closeMenu()},closeNewPartsPopup=()=>{partInventoryStore.closeNewPartsPopup()};return(_ctx,_cache)=>(openBlock(),createBlock(ComputerWrapper_default,{ref_key:`wrapper`,ref:wrapper,path:[`Part Inventory`],title:`Part Inventory`,back:``,onBack:close},{default:withCtx(()=>[createVNode(PartList_default,{class:`part-inventory`,onPartSold:updateCareerStatus})]),_:1},512))}},PartInventoryMain_default=__plugin_vue_export_helper_default(_sfc_main$235,[[`__scopeId`,`data-v-54c60dea`]]);const usePartShoppingStore=defineStore(`partShopping`,()=>{let{events:events$3}=useBridge(),partShoppingData=ref({}),filteredSlots=ref([]),path=ref(``),filteredParts=ref([]),category=ref(``),expandedSlots=ref({}),searchString=``,slotToScrollTo=ref(),backAction=()=>{},slotsDict={},partFilter;function doesNameContainString(name,searchStrings){for(let searchString$1 of searchStrings)if(name.includes(searchString$1))return!0;return!1}function filterParts(){if(filteredParts.value=[],slotsDict={},partShoppingData.value.partsInShop){for(let[_,part]of Object.entries(partShoppingData.value.partsInShop)){if(!part.slot)continue;partFilter?doesNameContainString(part.name,partFilter)&&filteredParts.value.push(part):part.containingSlot===path.value&&filteredParts.value.push(part);let niceName=partShoppingData.value.slotsNiceName[part.slot];niceName==null?slotsDict[part.slot]=part.slot:slotsDict[part.slot]=niceName}filteredParts.value.sort((a$1,b)=>a$1.emptyPlaceholder?-1:b.emptyPlaceholder?1:a$1.partId&&!b.partId?-1:!a$1.partId&&b.partId?1:a$1.description.description0?(filteredSlotsDict=getSlotsFromSearchString(),filteredSlots.value=partShoppingData.value.searchSlotList.filter(doesSlotPassFilter)):filteredSlots.value=[]}function setSlotExpanded(path$1,expanded){expandedSlots.value[path$1]=expanded}function setSlot(_slot){_slot==``&&(slotToScrollTo.value=path.value),path.value=_slot,partFilter=void 0,filterParts()}function setCategory(_category){category.value=_category,filterSlots(),category.value==`everything`||category.value==``?setSlot(``):category.value==`cargo`&&(path.value=`Blablabla`,partFilter=[`cargo_load`],filterParts())}let requestInitialData=()=>{Lua_default.career_modules_partShopping.sendShoppingDataToUI()},cancelShopping=()=>{expandedSlots.value={},Lua_default.career_modules_partShopping.cancelShopping(),setCategory(``)};function fixSlots(slot){if(`children`in slot){Array.isArray(slot.children)||(slot.children=Object.values(slot.children).filter(Boolean)),slot.children.sort((a$1,b)=>(a$1.slotNiceName||a$1.slot)<(b.slotNiceName||b.slot)?-1:1);for(let childSlot of slot.children)fixSlots(childSlot)}}let handleShoppingData=data=>{data.partTree&&fixSlots(data.partTree),partShoppingData.value=data,filterParts(),filterSlots()},searchValueChanged=_searchString=>{searchString=_searchString,filterSlots()},listen=state=>{events$3[state?`on`:`off`](`partShoppingData`,handleShoppingData)};listen(!0);function dispose$2(){listen(!1)}return{partShoppingData,slot:path,filteredSlots,filteredParts,category,expandedSlots,slotToScrollTo,searchValueChanged,setSlot,setCategory,requestInitialData,cancelShopping,dispose:dispose$2,setSlotExpanded,set backAction(actionFunc){backAction=actionFunc},get backAction(){return backAction}}});var _hoisted_1$207={class:`cart-main`},_hoisted_2$167={class:`cart-list`,"bng-nav-scroll":``},_hoisted_3$146={key:0,class:`extra-info-text`},_hoisted_4$121={key:0},_hoisted_5$106={key:1},_hoisted_6$89={class:`cart-row cart-subtotal`},_hoisted_7$77={class:`cart-row cart-tax`},_hoisted_8$63={class:`cart-row cart-total`},_sfc_main$234={__name:`ShoppingCart`,props:{cartData:Object,playerMoney:Number,apply:Function,cancel:Function,confirmButtonText:String},setup(__props){let props=__props,{units}=useBridge(),expanded=ref(!1),subtotal=computed(()=>props.cartData&&props.cartData.total&&props.cartData.taxes?props.cartData.total-props.cartData.taxes:0),salesTax=computed(()=>props.cartData&&props.cartData.taxes?props.cartData.taxes:0);return(_ctx,_cache)=>(openBlock(),createBlock(unref(bngCard_default),{class:normalizeClass([`cart`,{expanded:expanded.value}])},{buttons:withCtx(()=>[withDirectives((openBlock(),createBlock(unref(bngButton_default),{"show-hold":``,disabled:!__props.apply||!__props.cartData||__props.cartData.items.length===0||__props.cartData.total>0&&__props.cartData.total>__props.playerMoney},{default:withCtx(()=>[createTextVNode(toDisplayString(__props.confirmButtonText||`Purchase`),1)]),_:1},8,[`disabled`])),[[unref(BngOnUiNav_default),void 0,`ok`,{asMouse:!0,focusRequired:!0}],[unref(BngClick_default),{holdCallback:__props.apply,holdDelay:1e3,repeatInterval:0}]]),createVNode(unref(bngButton_default),{disabled:!__props.cancel,onClick:_cache[1]||=$event=>props.cancel(),accent:unref(ACCENTS).secondary},{default:withCtx(()=>[..._cache[10]||=[createTextVNode(` Cancel `,-1)]]),_:1},8,[`disabled`,`accent`])]),default:withCtx(()=>[createVNode(unref(bngCardHeading_default),null,{default:withCtx(()=>[..._cache[2]||=[createTextVNode(` Shopping Cart `,-1)]]),_:1}),createVNode(unref(bngButton_default),{class:`cart-expand`,accent:unref(ACCENTS).outlined,icon:expanded.value?unref(icons).arrowLargeDown:unref(icons).arrowLargeUp,onClick:_cache[0]||=$event=>expanded.value=!expanded.value},null,8,[`accent`,`icon`]),createBaseVNode(`div`,_hoisted_1$207,[_cache[9]||=createBaseVNode(`div`,{class:`cart-row cart-header`},[createBaseVNode(`div`),createBaseVNode(`div`,null,`Part`),createBaseVNode(`div`,null,`Price`)],-1),createBaseVNode(`div`,_hoisted_2$167,[__props.cartData?(openBlock(!0),createElementBlock(Fragment,{key:0},renderList(__props.cartData.items,item=>(openBlock(),createElementBlock(`div`,{class:normalizeClass([`cart-row`,item.type?[`type-${item.type}`]:null])},[createBaseVNode(`div`,null,[item.removeShow?(openBlock(),createBlock(unref(bngButton_default),{key:0,accent:`attention`,icon:unref(icons).abandon,disabled:item.removeDisabled,onClick:$event=>item.remove()},null,8,[`icon`,`disabled`,`onClick`])):createCommentVNode(``,!0)]),createBaseVNode(`div`,{style:normalizeStyle({paddingLeft:item.level?`${item.level-1}em`:void 0})},[createTextVNode(toDisplayString(item.name)+` `,1),item.extraInfo?(openBlock(),createElementBlock(`div`,_hoisted_3$146,toDisplayString(item.extraInfo),1)):createCommentVNode(``,!0)],4),item.priceHide?(openBlock(),createElementBlock(`div`,_hoisted_5$106)):(openBlock(),createElementBlock(`div`,_hoisted_4$121,toDisplayString(unref(units).beamBucks(item.price)),1))],2))),256)):createCommentVNode(``,!0),createBaseVNode(`div`,_hoisted_6$89,[_cache[3]||=createBaseVNode(`div`,null,null,-1),_cache[4]||=createBaseVNode(`div`,null,`Subtotal`,-1),createBaseVNode(`div`,null,toDisplayString(unref(units).beamBucks(subtotal.value)),1)]),createBaseVNode(`div`,_hoisted_7$77,[_cache[5]||=createBaseVNode(`div`,null,null,-1),_cache[6]||=createBaseVNode(`div`,null,`Sales Tax (7%)`,-1),createBaseVNode(`div`,null,toDisplayString(unref(units).beamBucks(salesTax.value)),1)])]),createBaseVNode(`div`,_hoisted_8$63,[_cache[7]||=createBaseVNode(`div`,null,null,-1),_cache[8]||=createBaseVNode(`div`,null,`Total`,-1),createBaseVNode(`div`,null,[createVNode(unref(bngUnit_default),{money:__props.cartData?__props.cartData.total:0},null,8,[`money`])])])])]),_:1},8,[`class`]))}},ShoppingCart_default=__plugin_vue_export_helper_default(_sfc_main$234,[[`__scopeId`,`data-v-e9392f36`]]),_hoisted_1$206={class:`parts-wrapper`},_hoisted_2$166={key:2,class:`parts-list`},_hoisted_3$145={class:`part-info-col`},_hoisted_4$120={class:`part-name`},_hoisted_5$105={key:0},_hoisted_6$88={key:1},_hoisted_7$76={key:2},_hoisted_8$62={class:`part-info-row`},_hoisted_9$56={key:0,class:`mileage-text`},_hoisted_10$47={key:1},_hoisted_11$42={key:2,class:`disabled-reason`},_hoisted_12$31={key:3,class:`right`},_hoisted_13$27={key:0},_sfc_main$233={__name:`PartsList`,setup(__props){let partShoppingStore=usePartShoppingStore(),{units}=useBridge(),oldBack,isPartInShoppingCart=part=>{if(!partShoppingStore.partShoppingData||!partShoppingStore.partShoppingData.shoppingCart)return!1;let partList=partShoppingStore.partShoppingData.shoppingCart.partsInList;for(let i=0;i{oldBack=partShoppingStore.backAction,partShoppingStore.backAction=()=>partShoppingStore.setSlot(``)}),onUnmounted(()=>{partShoppingStore.backAction=oldBack}),(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$206,[unref(partShoppingStore).category===`cargo`?(openBlock(),createBlock(unref(bngCardHeading_default),{key:0},{default:withCtx(()=>[..._cache[0]||=[createTextVNode(` Cargo `,-1)]]),_:1})):unref(partShoppingStore).filteredParts[0]?(openBlock(),createBlock(unref(bngCardHeading_default),{key:1},{default:withCtx(()=>[createTextVNode(toDisplayString(unref(partShoppingStore).partShoppingData.slotsNiceName[unref(partShoppingStore).filteredParts[0].containingSlot]),1)]),_:1})):createCommentVNode(``,!0),unref(partShoppingStore).filteredParts?(openBlock(),createElementBlock(`div`,_hoisted_2$166,[(openBlock(!0),createElementBlock(Fragment,null,renderList(unref(partShoppingStore).filteredParts,part=>(openBlock(),createElementBlock(`div`,{class:normalizeClass([`part-item`,{"part-installed":unref(partShoppingStore).partShoppingData.vehicleSlotToPartMap[part.containingSlot]&&unref(partShoppingStore).partShoppingData.vehicleSlotToPartMap[part.containingSlot].description.description===part.description.description,disabled:part.disabled}])},[createBaseVNode(`div`,_hoisted_3$145,[createBaseVNode(`div`,null,[createBaseVNode(`span`,_hoisted_4$120,[part.partId?(openBlock(),createElementBlock(`div`,_hoisted_5$105,toDisplayString(part.description.description)+` (Inventory) `,1)):part.emptyPlaceholder?(openBlock(),createElementBlock(`div`,_hoisted_6$88,` Remove current part `)):(openBlock(),createElementBlock(`div`,_hoisted_7$76,toDisplayString(part.description.description),1))])]),createBaseVNode(`div`,_hoisted_8$62,[part.partId?(openBlock(),createElementBlock(`span`,_hoisted_9$56,` Mileage: `+toDisplayString(unref(units).buildString(`length`,part.partCondition.odometer,0)),1)):createCommentVNode(``,!0),unref(partShoppingStore).category===`cargo`?(openBlock(),createElementBlock(`span`,_hoisted_10$47,toDisplayString(unref(partShoppingStore).partShoppingData.slotsNiceName[part.containingSlot]),1)):createCommentVNode(``,!0),part.disabled&&part.disabledReason?(openBlock(),createElementBlock(`span`,_hoisted_11$42,toDisplayString(part.disabledReason),1)):createCommentVNode(``,!0),!part.partId&&!part.emptyPlaceholder?(openBlock(),createElementBlock(`span`,_hoisted_12$31,[createVNode(unref(bngPropVal_default),{iconType:unref(icons).beamCurrency,valueLabel:unref(units).beamBucks(part.finalValue)},null,8,[`iconType`,`valueLabel`])])):createCommentVNode(``,!0)])]),createVNode(unref(bngButton_default),{accent:isPartInShoppingCart(part)?unref(ACCENTS).attention:unref(ACCENTS).outlined,class:`part-button`,disabled:part.disabled||unref(partShoppingStore).partShoppingData.tutorialPartNames!==void 0&&(!unref(partShoppingStore).partShoppingData.tutorialPartNames[part.name]||isPartInShoppingCart(part)),onClick:$event=>isPartInShoppingCart(part)?unref(Lua_default).career_modules_partShopping.removePartBySlot(part.containingSlot):unref(Lua_default).career_modules_partShopping.installPartByPartShopId(part.partShopId),icon:isPartInShoppingCart(part)?unref(icons).undo:``},{default:withCtx(()=>[isPartInShoppingCart(part)?createCommentVNode(``,!0):(openBlock(),createElementBlock(`div`,_hoisted_13$27,toDisplayString(part.emptyPlaceholder?`Remove`:`Install`),1))]),_:2},1032,[`accent`,`disabled`,`onClick`,`icon`])],2))),256))])):createCommentVNode(``,!0)]))}},PartsList_default=__plugin_vue_export_helper_default(_sfc_main$233,[[`__scopeId`,`data-v-c224fcea`]]),_hoisted_1$205={key:0,class:`highlighted`},_hoisted_2$165={key:1,class:`slot-path`},_hoisted_3$144={class:`buy-button-label`},_sfc_main$232={__name:`SlotItem`,props:{static:Boolean,expanded:Boolean,path:String,nicePath:String,slotNiceName:String,partNiceName:String},setup(__props){let slotItem=ref(),focused$1=ref(!1),props=__props;onMounted(()=>{partShoppingStore.slotToScrollTo&&props.path===partShoppingStore.slotToScrollTo&&slotItem.value.scrollIntoView({block:`center`})});let partShoppingStore=usePartShoppingStore(),itemExpanded=val=>{partShoppingStore.setSlotExpanded(props.path,val)},onFocus=val=>{focused$1.value=!0},onUnfocus=val=>{focused$1.value=!1},selectSlot=val=>{partShoppingStore.setSlot(props.path)};return(_ctx,_cache)=>(openBlock(),createBlock(unref(accordionItem_default),{static:__props.static,expanded:__props.expanded,onExpanded:itemExpanded,onFocus,onUnfocus,onSelected:selectSlot,navigable:``,"primary-action":()=>unref(partShoppingStore).setSlot(__props.path),"expand-hint-inline":``,"primary-hint-inline":``},{caption:withCtx(()=>[unref(partShoppingStore).slotToScrollTo===__props.path?(openBlock(),createElementBlock(`div`,_hoisted_1$205)):createCommentVNode(``,!0),__props.nicePath?(openBlock(),createElementBlock(`span`,_hoisted_2$165,toDisplayString(__props.nicePath),1)):createCommentVNode(``,!0),createBaseVNode(`span`,{ref_key:`slotItem`,ref:slotItem,class:`slot-name`},toDisplayString(__props.slotNiceName),513)]),controls:withCtx(()=>[withDirectives((openBlock(),createBlock(unref(bngButton_default),{"bng-no-nav":`true`,class:`buy-button`,accent:unref(ACCENTS).outlined,onClick:_cache[0]||=$event=>unref(partShoppingStore).setSlot(__props.path),style:normalizeStyle({backgroundColor:unref(partShoppingStore).slotToScrollTo&&unref(partShoppingStore).slotToScrollTo==__props.path?`rgba(75,75,75,0.8)`:``})},{default:withCtx(()=>[createBaseVNode(`span`,_hoisted_3$144,toDisplayString(__props.partNiceName?__props.partNiceName:`-`),1)]),_:1},8,[`accent`,`style`])),[[unref(BngTooltip_default),__props.partNiceName,`top`]])]),default:withCtx(()=>[renderSlot(_ctx.$slots,`default`,{},void 0,!0)]),_:3},8,[`static`,`expanded`,`primary-action`]))}},SlotItem_default=__plugin_vue_export_helper_default(_sfc_main$232,[[`__scopeId`,`data-v-3223c56d`]]),_sfc_main$231={__name:`PartSubTree`,props:{children:Object},setup(__props){let slotItemRefs=ref([]),partShoppingStore=usePartShoppingStore();return(_ctx,_cache)=>(openBlock(),createBlock(unref(accordion_default),null,{default:withCtx(()=>[(openBlock(!0),createElementBlock(Fragment,null,renderList(__props.children,childSlot=>(openBlock(),createBlock(SlotItem_default,{ref_for:!0,ref_key:`slotItemRefs`,ref:slotItemRefs,static:!childSlot.chosenPartName||!childSlot.children||Object.keys(childSlot.children).length===0,expanded:unref(partShoppingStore).expandedSlots[childSlot.path],path:childSlot.path,slotNiceName:childSlot.slotNiceName,partNiceName:childSlot.chosenPartNiceName},{default:withCtx(()=>[childSlot.children&&Object.keys(childSlot.children).length>0?(openBlock(),createBlock(PartSubTree_default,{key:0,children:childSlot.children},null,8,[`children`])):createCommentVNode(``,!0)]),_:2},1032,[`static`,`expanded`,`path`,`slotNiceName`,`partNiceName`]))),256))]),_:1}))}},PartSubTree_default=_sfc_main$231,_hoisted_1$204={class:`innerList`},_sfc_main$230={__name:`SlotList`,props:{cancel:Function},setup(__props){let partShoppingStore=usePartShoppingStore(),props=__props,searchValue=ref(``),searchValueChanged=()=>{partShoppingStore.searchValueChanged(searchValue.value)};return onMounted(()=>{partShoppingStore.backAction,partShoppingStore.backAction=()=>partShoppingStore.setCategory(``)}),onUnmounted(()=>{partShoppingStore.backAction=()=>props.cancel()}),(_ctx,_cache)=>unref(partShoppingStore).slot===``?(openBlock(),createElementBlock(Fragment,{key:1},[createVNode(unref(bngInput_default),{"floating-label":`Search`,"leading-icon":unref(icons).search,modelValue:searchValue.value,"onUpdate:modelValue":_cache[0]||=$event=>searchValue.value=$event,modelModifiers:{trim:!0},onValueChanged:searchValueChanged},null,8,[`leading-icon`,`modelValue`]),createBaseVNode(`div`,_hoisted_1$204,[searchValue.value.length>0?(openBlock(),createBlock(unref(accordion_default),{key:0,class:`slot-flat-view`},{default:withCtx(()=>[(openBlock(!0),createElementBlock(Fragment,null,renderList(unref(partShoppingStore).filteredSlots,slotInfo=>(openBlock(),createBlock(SlotItem_default,{static:!0,path:slotInfo.path,nicePath:slotInfo.nicePath,slotNiceName:slotInfo.slotNiceName,partNiceName:slotInfo.partNiceName?slotInfo.partNiceName:null},null,8,[`path`,`nicePath`,`slotNiceName`,`partNiceName`]))),256))]),_:1})):unref(partShoppingStore).partShoppingData.partTree.children?(openBlock(),createBlock(PartSubTree_default,{key:1,class:`slot-tree-view`,children:unref(partShoppingStore).partShoppingData.partTree.children},null,8,[`children`])):createCommentVNode(``,!0)])],64)):(openBlock(),createBlock(PartsList_default,{key:0}))}},SlotList_default=__plugin_vue_export_helper_default(_sfc_main$230,[[`__scopeId`,`data-v-f602b7c1`]]),_hoisted_1$203={key:0,class:`mainCategories`},_hoisted_2$164=[`disabled`],_sfc_main$229={__name:`Categories`,props:{cancel:Function},setup(__props){let partShoppingStore=usePartShoppingStore(),props=__props;return onMounted(()=>{partShoppingStore.backAction=()=>props.cancel()}),(_ctx,_cache)=>(openBlock(),createBlock(unref(bngCard_default),{class:`categoryList`},{default:withCtx(()=>[unref(partShoppingStore).category===``?(openBlock(),createElementBlock(`div`,_hoisted_1$203,[withDirectives((openBlock(),createElementBlock(`div`,{class:`computer-function-tile`,"bng-nav-item":``,tabindex:`0`,disabled:unref(partShoppingStore).partShoppingData.tutorialPartNames===void 0?void 0:!0,onClick:_cache[0]||=$event=>unref(partShoppingStore).partShoppingData.tutorialPartNames===void 0?unref(partShoppingStore).setCategory(`everything`):void 0},[createVNode(unref(bngIcon_default),{class:`icon`,type:unref(icons).doorFrontCoins},null,8,[`type`]),_cache[2]||=createBaseVNode(`span`,{class:`label`},`All Parts`,-1)],8,_hoisted_2$164)),[[unref(BngFocusIf_default),!0]]),createBaseVNode(`div`,{class:`computer-function-tile`,"bng-nav-item":``,tabindex:`0`,onClick:_cache[1]||=$event=>unref(partShoppingStore).setCategory(`cargo`)},[createVNode(unref(bngIcon_default),{class:`icon`,type:unref(icons).boxPickUp03},null,8,[`type`]),_cache[3]||=createBaseVNode(`span`,{class:`label`},`Cargo Parts`,-1)])])):(openBlock(),createBlock(SlotList_default,{key:1,cancel:props.cancel},null,8,[`cancel`]))]),_:1}))}},Categories_default=__plugin_vue_export_helper_default(_sfc_main$229,[[`__scopeId`,`data-v-70c591df`]]),CANCEL_MESSAGE$1=`Are you sure you want to cancel?
    All changes to your vehicle will be reversed`,_sfc_main$228={__name:`PartShoppingMain`,setup(__props){let{$game}=useLibStore();useComputerStore();let partShoppingStore=usePartShoppingStore(),CONFIRM_BUTTONS=[{label:$translate.instant(`ui.common.yes`),value:!0},{label:$translate.instant(`ui.common.no`),value:!1,extras:{accent:ACCENTS.secondary}}],confirmCancel=async()=>{(!partShoppingStore.partShoppingData.shoppingCart.partsInList.length||await openConfirmation(null,CANCEL_MESSAGE$1,CONFIRM_BUTTONS))&&cancelShopping()},getPartName=item=>item.description.description+(item.partId?` (Inventory)`:``),cartData=computed(()=>{let cart=partShoppingStore.partShoppingData?partShoppingStore.partShoppingData.shoppingCart:null,res={total:0,taxes:0,items:[]};return cart&&(res.total=cart.total,res.taxes=cart.taxes,Array.isArray(cart.partsInList)&&(res.items=cart.partsInList.map(item=>({name:getPartName(item),price:item.finalValue,extraInfo:item.partCondition?.odometer?`Mileage: `+$game.units.buildString(`length`,item.partCondition.odometer,0):void 0,removeShow:!!item.sourcePart,removeDisabled:!!partShoppingStore.partShoppingData.tutorialPartNames,remove:()=>Lua_default.career_modules_partShopping.removePartBySlot(item.containingSlot)})))),res}),applyShopping=()=>Lua_default.career_modules_partShopping.applyShopping(),cancelShopping=()=>Lua_default.career_modules_partShopping.cancelShopping(),start=()=>{partShoppingStore.setSlot(``),partShoppingStore.requestInitialData(),getUINavServiceInstance().setFilteredEvents(UI_EVENT_GROUPS.focusMoveScalar)},kill=()=>{partShoppingStore.cancelShopping(),getUINavServiceInstance().clearFilteredEvents(),partShoppingStore.$dispose()},close=()=>{partShoppingStore.backAction()};return onBeforeMount(start),onUnmounted(kill),(_ctx,_cache)=>(openBlock(),createBlock(ComputerWrapper_default,{path:[`Part Customization`],title:`Parts`,back:``,onBack:close},{side:withCtx(()=>[createVNode(ShoppingCart_default,{partShoppingData:unref(partShoppingStore).partShoppingData,"cart-data":cartData.value,"player-money":unref(partShoppingStore).partShoppingData.playerMoney,apply:applyShopping,cancel:confirmCancel,"confirm-button-text":`Confirm`},null,8,[`partShoppingData`,`cart-data`,`player-money`])]),default:withCtx(()=>[withDirectives(createVNode(Categories_default,{cancel:confirmCancel},null,512),[[unref(BngBlur_default),1]])]),_:1}))}},PartShoppingMain_default=__plugin_vue_export_helper_default(_sfc_main$228,[[`__scopeId`,`data-v-871a3a9f`]]),_hoisted_1$202={class:`profile-status`},_hoisted_2$163={class:`profile-status-progress`},_hoisted_3$143={class:`status-progress-item`},_hoisted_4$119={class:`status-progress-item`},_hoisted_5$104={class:`status-progress-item`},_hoisted_6$87={key:0,class:`profile-status-levels`},_hoisted_7$75={class:`profile-status-level`},_hoisted_8$61={class:`branch-icon-assembly`},_hoisted_9$55={class:`level-content-wrapper`},_sfc_main$227={__name:`ProfileStatus`,props:{beamXP:{type:Object,required:!0},vouchers:{type:Object,required:!0},money:{type:Object,required:!0},insuranceScore:{type:Object,required:!0},branches:{type:Array,required:!0},expanded:Boolean},setup(__props){let props=__props,formatterFn=num=>shrinkNum(num,1),moneyFormatter=computed(()=>props.money&&props.money>1e5?formatterFn:void 0);computed(()=>props.beamXP&&props.beamXP>1e5?formatterFn:void 0);let vouchersFormatter=computed(()=>props.vouchers&&props.vouchers>1e5?formatterFn:void 0);function getBranchStyle(color){return getIconBackgroundStyle(color)}return(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$202,[createBaseVNode(`div`,_hoisted_2$163,[createBaseVNode(`div`,_hoisted_3$143,[createVNode(unref(bngUnit_default),{insuranceScore:__props.insuranceScore?.value||0},null,8,[`insuranceScore`])]),createVNode(unref(bngDivider_default)),createBaseVNode(`div`,_hoisted_4$119,[createVNode(unref(bngUnit_default),{vouchers:__props.vouchers?.value||0,formatter:vouchersFormatter.value},null,8,[`vouchers`,`formatter`])]),createVNode(unref(bngDivider_default)),createBaseVNode(`div`,_hoisted_5$104,[createVNode(unref(bngUnit_default),{money:__props.money?.value||0,formatter:moneyFormatter.value},null,8,[`money`,`formatter`])])]),createVNode(Transition,{name:`expand-height`},{default:withCtx(()=>[__props.branches?withDirectives((openBlock(),createElementBlock(`div`,_hoisted_6$87,[(openBlock(!0),createElementBlock(Fragment,null,renderList(__props.branches,branch=>(openBlock(),createElementBlock(`div`,_hoisted_7$75,[createBaseVNode(`div`,_hoisted_8$61,[createBaseVNode(`div`,{class:`branch-background`,style:normalizeStyle(getBranchStyle(branch.color))},null,4),createVNode(unref(bngIcon_default),{type:branch.icon,class:`assembly-icon`},null,8,[`type`])]),createBaseVNode(`div`,_hoisted_9$55,[createVNode(unref(bngProgressBar_default),{class:`slim`,value:branch.curLvlProgress,min:0,max:branch.neededForNext,headerLeft:_ctx.$ctx_t(branch.label),headerRight:`${_ctx.$ctx_t(branch.levelLabel)} `,valueColor:`white`,showValueLabel:!1},null,8,[`value`,`max`,`headerLeft`,`headerRight`])])]))),256))],512)),[[vShow,__props.expanded]]):createCommentVNode(``,!0)]),_:1})]))}},ProfileStatus_default=__plugin_vue_export_helper_default(_sfc_main$227,[[`__scopeId`,`data-v-26c35504`]]),_hoisted_1$201={style:{position:`absolute`,left:`0`,right:`0`,top:`0`,bottom:`0`,background:`rgba(0,0,0,0.5)`}},_sfc_main$226={__name:`PauseMapPreview`,setup(__props){let levelTitle=ref(``),levelImage=ref(``);function setup$3(data){levelTitle.value=$translate.contextTranslate(data.title,!0),levelImage.value=data.previews[0]}let start=()=>{Lua_default.career_modules_uiUtils.getCareerCurrentLevelName().then(setup$3)};function goToBigMap(){Lua_default.freeroam_bigMapMode.enterBigMap()}return onMounted(start),(_ctx,_cache)=>{let _directive_bng_sound_class=resolveDirective(`bng-sound-class`);return withDirectives((openBlock(),createBlock(unref(aspectRatio_default),{"external-image":`/levels/west_coast_usa/spawns_quarry.jpg`,ratio:`4:3`,onClick:_cache[1]||=$event=>goToBigMap()},{default:withCtx(()=>[createBaseVNode(`div`,_hoisted_1$201,[createVNode(unref(bngCardHeading_default),{style:{color:`white`},type:`ribbon`},{default:withCtx(()=>[createTextVNode(toDisplayString(levelTitle.value),1)]),_:1}),createVNode(unref(bngButton_default),{style:{position:`absolute`,bottom:`1em`,right:`1em`},tabindex:`1`,accent:unref(ACCENTS).text,onClick:_cache[0]||=$event=>goToBigMap()},{default:withCtx(()=>[..._cache[2]||=[createTextVNode(`Open Map`,-1)]]),_:1},8,[`accent`])])]),_:1})),[[_directive_bng_sound_class,`bng_click_generic`]])}}},PauseMapPreview_default=__plugin_vue_export_helper_default(_sfc_main$226,[[`__scopeId`,`data-v-5a91faef`]]),_hoisted_1$200={class:`content-wrapper`},_hoisted_2$162={class:`cards-container`},_sfc_main$225={__name:`PauseMilestonesPreview`,setup(__props){let milestones=ref([]);function setup$3(data){milestones.value=data.list}let start=()=>{Lua_default.career_modules_milestones_milestones.getMilestones().then(setup$3)};function goToMilestones(){window.bngVue.gotoGameState(`milestones`)}return onMounted(start),(_ctx,_cache)=>{let _directive_bng_sound_class=resolveDirective(`bng-sound-class`);return withDirectives((openBlock(),createBlock(unref(aspectRatio_default),{onClick:_cache[1]||=$event=>goToMilestones(),ratio:`4:3`},{default:withCtx(()=>[createBaseVNode(`div`,_hoisted_1$200,[createVNode(unref(bngCardHeading_default),{style:{color:`white`},type:`ribbon`},{default:withCtx(()=>[..._cache[2]||=[createTextVNode(`Recent Milestones`,-1)]]),_:1}),createBaseVNode(`div`,_hoisted_2$162,[(openBlock(!0),createElementBlock(Fragment,null,renderList(milestones.value.slice(0,5),entry=>(openBlock(),createBlock(MilestoneCard_default,{milestone:entry,isCondensed:!0},null,8,[`milestone`]))),256))]),createVNode(unref(bngButton_default),{style:{position:`absolute`,bottom:`1em`,right:`1em`},tabindex:`1`,accent:unref(ACCENTS).text,onClick:_cache[0]||=$event=>goToMilestones()},{default:withCtx(()=>[..._cache[3]||=[createTextVNode(`Go to Milestones`,-1)]]),_:1},8,[`accent`])])]),_:1})),[[_directive_bng_sound_class,`bng_click_generic`]])}}},PauseMilestonesPreview_default=__plugin_vue_export_helper_default(_sfc_main$225,[[`__scopeId`,`data-v-7fcfd236`]]),_hoisted_1$199={class:`pause-body-wrapper`},_hoisted_2$161={class:`heading-container`},_hoisted_3$142={class:`buttons-and-status`},_hoisted_4$118={key:0,class:`indicator`},_hoisted_5$103={class:`save-load-row`},_hoisted_6$86={class:`status-container`},_hoisted_7$74={key:2,class:`vehicle-name`},_sfc_main$224={__name:`Pause`,setup(__props){useUINavScope(`pause`),ref({value:0,label:`Map`,type:`Map`}.type),ref(null),ref(.5);let contextButtons=ref({});function setupContextButtons(data){contextButtons.value=data.buttons}Lua_default.career_modules_uiUtils.getCareerPauseContextButtons().then(setupContextButtons);function onContextButtonClicked(btn){Lua_default.career_modules_uiUtils.callCareerPauseContextButtons(btn.functionId)}function onSaveButtonClicked(){Lua_default.career_saveSystem.saveCurrent(),exit()}async function onLoadButtonClicked(){await openConfirmation(`Load Profile`,`Are you sure you want to load a different profile? Any unsaved progress will be lost.`)&&window.bngVue.gotoGameState(`profiles`)}let exit=()=>window.bngVue.gotoGameState(`play`),saveSlotData=ref(null),currentVehicleName=ref(``);function makeVehicleName(data){return!data||data.key===`unicycle`?`Walking`:data.niceName}return onMounted(async()=>{let data=await Lua_default.career_career.sendCurrentSaveSlotData();saveSlotData.value=data,currentVehicleName.value=makeVehicleName(data.currentVehicle)}),onBeforeMount(()=>{Lua_default.simTimeAuthority.pushPauseRequest(`careerPause`)}),onUnmounted(()=>{Lua_default.simTimeAuthority.popPauseRequest(`careerPause`)}),(_ctx,_cache)=>withDirectives((openBlock(),createBlock(unref(layoutSingle_default),{class:`career-pause-layout`,"bng-ui-scope":`pause`},{default:withCtx(()=>[createBaseVNode(`div`,_hoisted_1$199,[createBaseVNode(`div`,_hoisted_2$161,[createVNode(unref(bngCardHeading_default),{class:`pause-heading`,type:`ribbon`},{default:withCtx(()=>[..._cache[0]||=[createTextVNode(`Career: Paused`,-1)]]),_:1})]),createBaseVNode(`div`,_hoisted_3$142,[createVNode(unref(bngCard_default),{class:`system-buttons`},{default:withCtx(()=>[createVNode(unref(bngButton_default),{class:`button`,tabindex:`1`,accent:unref(ACCENTS).text,onClick:exit},{default:withCtx(()=>[..._cache[1]||=[createTextVNode(`Resume`,-1)]]),_:1},8,[`accent`]),contextButtons.value.length>0?(openBlock(!0),createElementBlock(Fragment,{key:0},renderList(contextButtons.value,btn=>(openBlock(),createBlock(unref(bngButton_default),{class:`button`,tabindex:`1`,accent:unref(ACCENTS).text,onClick:$event=>onContextButtonClicked(btn)},{default:withCtx(()=>[createTextVNode(toDisplayString(_ctx.$ctx_t(btn.label))+` `,1),btn.showIndicator?(openBlock(),createElementBlock(`div`,_hoisted_4$118)):createCommentVNode(``,!0)]),_:2},1032,[`accent`,`onClick`]))),256)):createCommentVNode(``,!0),createBaseVNode(`div`,_hoisted_5$103,[createVNode(unref(bngButton_default),{class:`button`,tabindex:`1`,accent:unref(ACCENTS).text,onClick:onSaveButtonClicked},{default:withCtx(()=>[..._cache[2]||=[createTextVNode(`Save`,-1)]]),_:1},8,[`accent`]),createVNode(unref(bngButton_default),{class:`button`,tabindex:`1`,accent:unref(ACCENTS).text,onClick:onLoadButtonClicked},{default:withCtx(()=>[..._cache[3]||=[createTextVNode(`Load`,-1)]]),_:1},8,[`accent`])])]),_:1}),createBaseVNode(`div`,_hoisted_6$86,[saveSlotData.value?(openBlock(),createBlock(unref(bngCardHeading_default),{key:0,class:`profile-name`,type:`ribbon`},{default:withCtx(()=>[createTextVNode(toDisplayString(saveSlotData.value.id),1)]),_:1})):createCommentVNode(``,!0),saveSlotData.value?(openBlock(),createBlock(ProfileStatus_default,{key:1,class:`pause-profile-status`,expanded:!0,beamXP:saveSlotData.value.beamXP,vouchers:saveSlotData.value.vouchers,money:saveSlotData.value.money,insuranceScore:saveSlotData.value.insuranceScore,branches:saveSlotData.value.branches},null,8,[`beamXP`,`vouchers`,`money`,`insuranceScore`,`branches`])):createCommentVNode(``,!0),saveSlotData.value?(openBlock(),createElementBlock(`div`,_hoisted_7$74,[createVNode(unref(bngIcon_default),{type:unref(icons).car},null,8,[`type`]),createTextVNode(` `+toDisplayString(currentVehicleName.value),1)])):createCommentVNode(``,!0)])])])]),_:1})),[[unref(BngOnUiNav_default),exit,`menu,back`],[unref(BngBlur_default),!0]])}},Pause_default=__plugin_vue_export_helper_default(_sfc_main$224,[[`__scopeId`,`data-v-c6f22d14`]]),_hoisted_1$198={class:`career-pause-wrapper`},_hoisted_2$160={class:`layout-center-wrapper`},_hoisted_3$141={class:`pause-body-wrapper`},_hoisted_4$117={class:`left-content`},_hoisted_5$102={class:`tabs-group`},_hoisted_6$85={class:`tab-content`},_hoisted_7$73={style:{position:`absolute`,left:`0`,right:`0`,top:`0`,bottom:`0`,background:`rgba(0, 0, 0, 0.5)`}},_hoisted_8$60={class:`right-content`},_hoisted_9$54={class:`bottom-content`},ICON_RATIO=`2.25:1`,_sfc_main$223={__name:`PauseBigMiddlePanel`,setup(__props){useUINavScope(`pause`);let MIDDLE_PILL_OPTIONS=[{value:0,label:`Map`,type:`Map`},{value:1,label:`Milestones`,type:`Milestones`},{value:2,label:`Engine`},{value:3,label:`Transmission`},{value:4,label:`Suspension`},{value:5,label:`Electrics`},{value:6,label:`Electrics1`},{value:7,label:`Electrics2`},{value:8,label:`Electrics3`}],currentPillTypeSelected=ref(MIDDLE_PILL_OPTIONS[0].type),middlePillsContainerRef=ref(null);function onMiddlePillsSelectPrevious(){middlePillsContainerRef.value.selectPrevious()}function onMiddlePillsSelectNext(){middlePillsContainerRef.value.selectNext()}function middlePillsValueChanged(selectedValues){let pillId=selectedValues[0],selectedPill=MIDDLE_PILL_OPTIONS.find(pill=>pill.value===pillId);console.log(selectedPill),currentPillTypeSelected.value=selectedPill.type}let todSliderValue=ref(.5),onTODChanged=v=>{console.log(v)},contextButtons=ref({});function setupContextButtons(data){console.log(data),contextButtons.value=data.buttons}Lua_default.career_modules_uiUtils.getCareerPauseContextButtons().then(setupContextButtons);function onContextButtonClicked(btn){console.log(btn),Lua_default.career_modules_uiUtils.callCareerPauseContextButtons(btn.functionId)}function onExitCareerButtonClicked(){console.log(`onExitCareerButtonClicked`)}function onSaveButtonClicked(){career_saveSystem.saveCurrent()}function onLoadButtonClicked(){console.log(`onLoadButtonClicked`)}function onSettingsButtonClicked(){console.log(`onSettingsButtonClicked`)}return(_ctx,_cache)=>withDirectives((openBlock(),createElementBlock(`div`,_hoisted_1$198,[createVNode(unref(careerSimpleStats_default)),createBaseVNode(`div`,_hoisted_2$160,[createBaseVNode(`div`,_hoisted_3$141,[createVNode(unref(careerStatus_default),{class:`pause-profile-status`}),createBaseVNode(`div`,_hoisted_4$117,[createVNode(unref(bngImageTile_default),{label:`Exit Career`,icon:unref(icons).abandon,onClick:onExitCareerButtonClicked,ratio:ICON_RATIO},null,8,[`icon`]),createVNode(unref(bngCard_default),{class:`system-buttons`},{default:withCtx(()=>[createVNode(unref(bngButton_default),{tabindex:`1`,accent:unref(ACCENTS).text,onClick:onSaveButtonClicked},{default:withCtx(()=>[..._cache[1]||=[createTextVNode(`Save`,-1)]]),_:1},8,[`accent`]),createVNode(unref(bngButton_default),{tabindex:`1`,accent:unref(ACCENTS).text,onClick:onLoadButtonClicked},{default:withCtx(()=>[..._cache[2]||=[createTextVNode(`Load`,-1)]]),_:1},8,[`accent`]),createVNode(unref(bngButton_default),{tabindex:`1`,accent:unref(ACCENTS).text,onClick:onSettingsButtonClicked},{default:withCtx(()=>[..._cache[3]||=[createTextVNode(`Settings`,-1)]]),_:1},8,[`accent`])]),_:1})]),createVNode(unref(bngCard_default),{class:`main-content grid`},{default:withCtx(()=>[createBaseVNode(`div`,_hoisted_5$102,[createVNode(unref(bngButton_default),{class:`button prev-button`,onClick:onMiddlePillsSelectPrevious,tabindex:`0`,accent:unref(ACCENTS).text},{default:withCtx(()=>[..._cache[4]||=[createTextVNode(`Previous`,-1)]]),_:1},8,[`accent`]),createVNode(unref(bngPillFiltersContainer_default),{class:`tabs-track`,ref_key:`middlePillsContainerRef`,ref:middlePillsContainerRef,"html-id":`middle-pills-container-ref`,options:MIDDLE_PILL_OPTIONS,"select-on-navigation":!1,onValueChanged:middlePillsValueChanged,required:!0,"has-checked-icon":!1},null,512),createVNode(unref(bngButton_default),{class:`button next-button`,onClick:onMiddlePillsSelectNext,tabindex:`0`,accent:unref(ACCENTS).text},{default:withCtx(()=>[..._cache[5]||=[createTextVNode(`Next`,-1)]]),_:1},8,[`accent`])]),createBaseVNode(`div`,_hoisted_6$85,[currentPillTypeSelected.value==`Map`?(openBlock(),createBlock(PauseMapPreview_default,{key:0})):createCommentVNode(``,!0),currentPillTypeSelected.value==`Milestones`?(openBlock(),createBlock(PauseMilestonesPreview_default,{key:1})):createCommentVNode(``,!0),currentPillTypeSelected.value===void 0?withDirectives((openBlock(),createBlock(unref(aspectRatio_default),{key:2,style:{background:`red`},ratio:`4:3`},{default:withCtx(()=>[createBaseVNode(`div`,_hoisted_7$73,[createVNode(unref(bngCardHeading_default),{style:{color:`white`},type:`ribbon`},{default:withCtx(()=>[..._cache[6]||=[createTextVNode(`Undefined Pill Type!`,-1)]]),_:1})])]),_:1})),[[unref(BngSoundClass_default),`bng_click_generic`]]):createCommentVNode(``,!0)])]),_:1}),createBaseVNode(`div`,_hoisted_8$60,[(openBlock(!0),createElementBlock(Fragment,null,renderList(contextButtons.value,btn=>(openBlock(),createBlock(unref(bngImageTile_default),{label:btn.label,icon:unref(icons)[btn.icon],onClick:$event=>onContextButtonClicked(btn),ratio:ICON_RATIO},null,8,[`label`,`icon`,`onClick`]))),256))]),createBaseVNode(`div`,_hoisted_9$54,[createVNode(unref(bngImageTile_default),{class:`photo-mode`,label:`Photo Mode`,icon:unref(icons).photo,ratio:ICON_RATIO},null,8,[`icon`]),createVNode(unref(bngCard_default),{class:`tod`},{default:withCtx(()=>[_cache[7]||=createBaseVNode(`div`,{class:`icon-box`},`I'm an icon box!`,-1),createVNode(unref(bngSlider_default),{ref:`iptChanged`,min:0,max:1,step:.1,modelValue:todSliderValue.value,"onUpdate:modelValue":_cache[0]||=$event=>todSliderValue.value=$event,onValueChanged:onTODChanged},null,8,[`modelValue`]),createVNode(unref(bngInput_default),{class:`tod-value`})]),_:1})])])]),_cache[8]||=createBaseVNode(`div`,{style:{background:`green`,height:`5em`}},`FOOTER`,-1)])),[[unref(BngBlur_default)]])}},PauseBigMiddlePanel_default=__plugin_vue_export_helper_default(_sfc_main$223,[[`__scopeId`,`data-v-7b3f120b`]]),_hoisted_1$197={class:`back-text`},_sfc_main$222={__name:`BackAside`,emits:[`click`],setup(__props,{emit:__emit}){let emit$1=__emit;return(_ctx,_cache)=>withDirectives((openBlock(),createElementBlock(`div`,{class:`back-aside`,onClick:_cache[0]||=$event=>emit$1(`click`)},[createVNode(unref(bngIcon_default),{class:`back-arrow`,type:unref(icons).arrowLargeLeft},null,8,[`type`]),createBaseVNode(`span`,_hoisted_1$197,[createVNode(unref(bngBinding_default),{class:`back-binding`,"ui-event":`back`,controller:``,"track-ignore":``}),createTextVNode(` `+toDisplayString(_ctx.$tt(`ui.common.back`)),1)])])),[[unref(BngSoundClass_default),`bng_click_hover_generic`]])}},BackAside_default=__plugin_vue_export_helper_default(_sfc_main$222,[[`__scopeId`,`data-v-2fa47f3c`]]);const PROFILE_NAME_MAX_LENGTH=100,useProfilesStore=defineStore(`profiles`,()=>{async function loadProfile(profileName,tutorialEnabled,isAdd=!1){if(console.log(`profileStore.loadProfile`,profileName,tutorialEnabled,isAdd),!profileName)return console.warn(`profileStore.loadProfile: profileName is required. Not loading profile.`),!1;if(profileName.length>100&&isAdd)return console.warn(`profileStore.loadProfile: profileName is too long. Not loading profile.`),!1;console.log(`profileStore.loadProfile: creating or loading career and starting`,profileName),/^ +| +$/.test(profileName)&&(profileName=profileName.replace(/^ +| +$/g,``));let createOrLoadCareerAndStartResult=await Lua_default.career_career.createOrLoadCareerAndStart(profileName,null,tutorialEnabled);console.log(`profileStore.loadProfile: createOrLoadCareerAndStartResult`,createOrLoadCareerAndStartResult);let toastrMessage=isAdd?`added`:`loaded`;window.globalAngularRootScope.$broadcast(`toastrMsg`,{type:`info`,msg:$translate.contextTranslate(`ui.career.notification.${toastrMessage}`),config:{positionClass:`toast-top-right`,toastClass:`beamng-message-toast`,timeOut:5e3,extendedTimeOut:1e3}})}return{loadProfile}});var _hoisted_1$196={class:`profile-card-cover`},_hoisted_2$159={class:`profile-card-container`},_hoisted_3$140={class:`profile-card-title`},_hoisted_4$116={key:0,class:`profile-card-date`},_hoisted_5$101={key:0},_hoisted_6$84={key:1},_hoisted_7$72={class:`profile-card-content`},_hoisted_8$59={key:0,class:`profile-manage`},_hoisted_9$53={key:0,class:`profile-manage-rename`},_hoisted_10$46={key:1,class:`profile-manage-delete`},_hoisted_11$41={key:2,class:`profile-manage-main`},MENU_ITEMS$3={RENAME:`rename`,DELETE:`delete`},_sfc_main$221={__name:`ProfileCard`,props:{id:{type:String,required:!0},date:{type:String,required:!0},creationDate:{type:String,required:!0},incompatibleVersion:Boolean,outdatedVersion:{type:Boolean,required:!0},preview:{type:String,default:`/ui/modules/career/profilePreview_WCUSA.jpg`},beamXP:Object,vouchers:Object,vehicleCount:Number,money:Object,insuranceScore:Object,active:Boolean,branches:Array,disabled:Boolean},emits:[`card:activate`,`load`,`rename`],setup(__props,{emit:__emit}){let props=__props,emit$1=__emit,isActivated=ref(!1),isManage=ref(!1),currentMenu=ref(null),expanded=ref(!1),internalDisabled=ref(!1),cardStates=reactive({focused:!1,hovered:!1}),validateName=inject(`validateName`),nameError=ref(null),lastPlayedDescription=computed(()=>timeSpan(props.date));watch(()=>props.disabled,value=>{nextTick(()=>{internalDisabled.value=value,value&&(expanded.value=!1)})});let onScopeChanged=value=>{isActivated.value=value},cardFooterStyles$1={"background-color":`hsla(217, 22%, 12%, 1)`},validateFn=name=>{let res=validateName(name);return name===props.id&&(res=null),res?nameError.value=res:nameError.value=null,!res},canDeactivate=()=>!isManage.value,canBubbleEvent=e=>e.detail.name===`menu`&&!isManage.value;function onFocused(focused$1){cardStates.focused=focused$1,updatedExpanded()}function onHover(hover){cardStates.hovered=hover,updatedExpanded()}function updatedExpanded(){let enable=cardStates.focused||cardStates.hovered;!enable&&(isActivated.value||isManage.value)||(expanded.value=enable)}function enableManage(enable=!0){nextTick(()=>isManage.value=enable),enable&&!isActivated.value&&(isActivated.value=!0),emit$1(`card:activate`,enable)}function goBack(){if(saveName.value=props.id,currentMenu.value)currentMenu.value=null;else if(isManage.value)enableManage(!1);else return!0}let saveName=ref(props.id),deleteProfile=()=>{Lua_default.career_saveSystem.removeSaveSlot(props.id),Lua_default.career_career.sendAllCareerSaveSlotsData()},updateProfileName=()=>emit$1(`rename`,saveName.value);return(_ctx,_cache)=>withDirectives((openBlock(),createBlock(unref(bngCard_default),{backgroundImage:__props.preview,footerStyles:cardFooterStyles$1,hideFooter:!expanded.value&&!isManage.value,class:normalizeClass([{"profile-card-active":__props.active,"manage-active":isManage.value,"profile-outdated":__props.incompatibleVersion},`profile-card`]),animateFooterDelay:expanded.value?`0s`:`0.1s`,animateFooterType:`slide`,onActivate:_cache[5]||=$event=>onScopeChanged(!0),onDeactivate:_cache[6]||=$event=>onScopeChanged(!1),onFocusin:_cache[7]||=withModifiers($event=>onFocused(!0),[`self`]),onFocusout:_cache[8]||=withModifiers($event=>onFocused(!1),[`self`]),onMouseover:_cache[9]||=$event=>onHover(!0),onMouseleave:_cache[10]||=$event=>onHover(!1)},{buttons:withCtx(()=>[isManage.value?(openBlock(),createElementBlock(Fragment,{key:0},[currentMenu.value===MENU_ITEMS$3.RENAME?withDirectives((openBlock(),createBlock(unref(bngButton_default),{key:0,disabled:nameError.value!==null||saveName.value===props.id,onClick:updateProfileName},{default:withCtx(()=>[..._cache[11]||=[createTextVNode(` Save `,-1)]]),_:1},8,[`disabled`])),[[unref(BngOnUiNav_default),void 0,`ok`,{asMouse:!0,focusRequired:!0}],[unref(BngSoundClass_default),`bng_click_generic`]]):createCommentVNode(``,!0),withDirectives((openBlock(),createBlock(unref(bngButton_default),{accent:`outlined`,onClick:goBack},{default:withCtx(()=>[..._cache[12]||=[createTextVNode(` Back `,-1)]]),_:1})),[[unref(BngOnUiNav_default),void 0,`ok`,{asMouse:!0,focusRequired:!0}],[unref(BngSoundClass_default),`bng_cancel_generic`]])],64)):(openBlock(),createElementBlock(Fragment,{key:1},[withDirectives((openBlock(),createBlock(unref(bngButton_default),{accent:`outlined`,onClick:enableManage},{default:withCtx(()=>[..._cache[13]||=[createTextVNode(`Manage `,-1)]]),_:1})),[[unref(BngOnUiNav_default),void 0,`ok`,{asMouse:!0,focusRequired:!0}],[unref(BngSoundClass_default),`bng_click_generic`]]),withDirectives((openBlock(),createBlock(unref(bngButton_default),{onClick:_cache[4]||=$event=>_ctx.$emit(`load`,__props.id),disabled:__props.active||__props.incompatibleVersion},{default:withCtx(()=>[..._cache[14]||=[createTextVNode(`Load `,-1)]]),_:1},8,[`disabled`])),[[unref(BngOnUiNav_default),void 0,`ok`,{asMouse:!0,focusRequired:!0}],[unref(BngSoundClass_default),`bng_click_generic`]])],64))]),default:withCtx(()=>[createBaseVNode(`div`,_hoisted_1$196,[createBaseVNode(`div`,_hoisted_2$159,[createBaseVNode(`div`,_hoisted_3$140,toDisplayString(_ctx.$ctx_t(__props.id)),1),isManage.value?createCommentVNode(``,!0):(openBlock(),createElementBlock(`div`,_hoisted_4$116,[__props.active?(openBlock(),createElementBlock(`span`,_hoisted_5$101,toDisplayString(_ctx.$ctx_t(`ui.career.nowplaying`)),1)):(openBlock(),createElementBlock(`span`,_hoisted_6$84,toDisplayString(_ctx.$ctx_t(`ui.career.lastplayed`))+` `+toDisplayString(lastPlayedDescription.value),1))]))])]),withDirectives((openBlock(),createElementBlock(`div`,_hoisted_7$72,[isManage.value?(openBlock(),createElementBlock(`div`,_hoisted_8$59,[currentMenu.value===MENU_ITEMS$3.RENAME?(openBlock(),createElementBlock(`div`,_hoisted_9$53,[createVNode(unref(bngInput_default),{modelValue:saveName.value,"onUpdate:modelValue":_cache[0]||=$event=>saveName.value=$event,maxlength:unref(100),validate:validateFn,errorMessage:nameError.value,externalLabel:`Save Name`,onKeydown:_cache[1]||=withKeys(withModifiers(()=>{},[`prevent`]),[`enter`])},null,8,[`modelValue`,`maxlength`,`errorMessage`])])):currentMenu.value===MENU_ITEMS$3.DELETE?(openBlock(),createElementBlock(`div`,_hoisted_10$46,[createBaseVNode(`span`,null,toDisplayString(_ctx.$ctx_t(`ui.career.deletePrompt`)),1),withDirectives(createVNode(unref(bngButton_default),{label:_ctx.$ctx_t(`ui.common.yes`),accent:`attention`,onClick:deleteProfile},null,8,[`label`]),[[unref(BngOnUiNav_default),void 0,`ok`,{asMouse:!0,focusRequired:!0}],[unref(BngSoundClass_default),`bng_click_generic`]]),withDirectives(createVNode(unref(bngButton_default),{label:_ctx.$ctx_t(`ui.common.no`),accent:`secondary`,onClick:goBack},null,8,[`label`]),[[unref(BngOnUiNav_default),void 0,`ok`,{asMouse:!0,focusRequired:!0}],[unref(BngSoundClass_default),`bng_cancel_generic`]])])):(openBlock(),createElementBlock(`div`,_hoisted_11$41,[withDirectives(createVNode(unref(bngButton_default),{accent:`secondary`,label:_ctx.$ctx_t(`ui.career.rename`),disabled:__props.active,onClick:_cache[2]||=()=>currentMenu.value=MENU_ITEMS$3.RENAME},null,8,[`label`,`disabled`]),[[unref(BngOnUiNav_default),void 0,`ok`,{asMouse:!0,focusRequired:!0}],[unref(BngSoundClass_default),`bng_click_generic`]]),withDirectives(createVNode(unref(bngButton_default),{accent:`secondary`,label:_ctx.$ctx_t(`ui.career.delete`),disabled:__props.active,onClick:_cache[3]||=()=>currentMenu.value=MENU_ITEMS$3.DELETE},null,8,[`label`,`disabled`]),[[unref(BngOnUiNav_default),void 0,`ok`,{asMouse:!0,focusRequired:!0}],[unref(BngSoundClass_default),`bng_click_generic`]]),createVNode(unref(bngButton_default),{label:_ctx.$ctx_t(`ui.career.mods`),accent:`secondary`,disabled:``},null,8,[`label`]),createVNode(unref(bngButton_default),{label:_ctx.$ctx_t(`ui.career.backup`),accent:`secondary`,disabled:``},null,8,[`label`])]))])):(openBlock(),createBlock(ProfileStatus_default,{key:1,branches:__props.branches,beamXP:__props.beamXP,vouchers:__props.vouchers,vehicleCount:__props.vehicleCount,money:__props.money,insuranceScore:__props.insuranceScore},null,8,[`branches`,`beamXP`,`vouchers`,`vehicleCount`,`money`,`insuranceScore`]))])),[[unref(BngOnUiNav_default),goBack,`menu,back`]])]),_:1},8,[`backgroundImage`,`hideFooter`,`class`,`animateFooterDelay`])),[[unref(BngScopedNav_default),{canDeactivate,canBubbleEvent}],[unref(BngSoundClass_default),`bng_hover_generic`],[unref(BngDisabled_default),internalDisabled.value]])}},ProfileCard_default=__plugin_vue_export_helper_default(_sfc_main$221,[[`__scopeId`,`data-v-16215408`]]),cardFooterStyles={"background-color":`hsla(217, 22%, 12%, 1)`},_sfc_main$220={__name:`ProfileCreateCard`,props:{profileName:{required:!0},profileNameModifiers:{}},emits:mergeModels([`card:activate`,`load`],[`update:profileName`]),setup(__props,{emit:__emit}){let emit$1=__emit,profileName=useModel(__props,`profileName`),tutorialChecked=ref(!0),isActive=ref(!1),validateName=inject(`validateName`),nameError=ref(null),startButton=ref(null),cancelButton=ref(null),validateFn=name=>{let res=validateName(name);return res?nameError.value=res:nameError.value=null,!res},load=()=>emit$1(`load`,profileName.value,tutorialChecked.value);function setActive(value){isActive.value=value,emit$1(`card:activate`,value)}function onCancel(event){setTimeout(()=>{isActive.value=!1,emit$1(`card:activate`,!1)},200)}function onEnter(event){event.preventDefault();let focusButton=nameError.value?cancelButton:startButton;focusButton.value&&nextTick(()=>setFocusExternal(focusButton.value.$el))}function onMenu(){setActive(!1)}return(_ctx,_cache)=>withDirectives((openBlock(),createBlock(unref(bngCard_default),{hideFooter:!isActive.value,footerStyles:cardFooterStyles,class:`profile-create-card`,onActivate:_cache[3]||=()=>setActive(!0),onDeactivate:_cache[4]||=()=>setActive(!1)},{buttons:withCtx(()=>[withDirectives((openBlock(),createBlock(unref(bngButton_default),{ref_key:`startButton`,ref:startButton,disabled:nameError.value!==null,onClick:withModifiers(load,[`stop`])},{default:withCtx(()=>[..._cache[6]||=[createTextVNode(`Start`,-1)]]),_:1},8,[`disabled`])),[[unref(BngOnUiNav_default),void 0,`ok`,{asMouse:!0,focusRequired:!0}]]),withDirectives((openBlock(),createBlock(unref(bngButton_default),{ref_key:`cancelButton`,ref:cancelButton,accent:`outlined`,onClick:withModifiers(onCancel,[`stop`])},{default:withCtx(()=>[..._cache[7]||=[createTextVNode(`Cancel`,-1)]]),_:1})),[[unref(BngOnUiNav_default),void 0,`ok`,{asMouse:!0,focusRequired:!0}]])]),default:withCtx(()=>[withDirectives((openBlock(),createElementBlock(`div`,{class:normalizeClass([{"create-active":isActive.value},`create-content-container`])},[isActive.value?(openBlock(),createElementBlock(Fragment,{key:0},[createVNode(unref(bngInput_default),{modelValue:profileName.value,"onUpdate:modelValue":_cache[0]||=$event=>profileName.value=$event,maxlength:unref(100),validate:validateFn,errorMessage:nameError.value,externalLabel:`Save Name`,onKeydown:withKeys(onEnter,[`enter`])},null,8,[`modelValue`,`maxlength`,`errorMessage`]),createVNode(unref(bngSwitch_default),{modelValue:tutorialChecked.value,"onUpdate:modelValue":_cache[1]||=$event=>tutorialChecked.value=$event,"label-before":``,inline:!1,"label-alignment":unref(LABEL_ALIGNMENTS).START},{default:withCtx(()=>[createTextVNode(toDisplayString(_ctx.$ctx_t(`ui.career.tutorialCheckDesc`)),1)]),_:1},8,[`modelValue`,`label-alignment`]),createBaseVNode(`span`,{class:normalizeClass([`tutorial-desc`,{checked:tutorialChecked.value}])},toDisplayString(_ctx.$ctx_t(`ui.career.tutorialOnDesc`)),3)],64)):(openBlock(),createElementBlock(`div`,{key:1,"bng-nav-item":``,class:`create-content-cover`,onClick:_cache[2]||=withModifiers($event=>setActive(!0),[`stop`])},[..._cache[5]||=[createBaseVNode(`div`,{class:`cover-plus-container`},[createBaseVNode(`div`,{class:`cover-plus-button`},`+`)],-1)]]))],2)),[[unref(BngOnUiNav_default),onMenu,`menu`]])]),_:1},8,[`hideFooter`])),[[unref(BngScopedNav_default),{activated:isActive.value}],[unref(BngBlur_default)],[unref(BngSoundClass_default),`bng_hover_generic`]])}},ProfileCreateCard_default=__plugin_vue_export_helper_default(_sfc_main$220,[[`__scopeId`,`data-v-1524a2bb`]]),_sfc_main$219={__name:`Profiles`,setup(__props){let store$1=useProfilesStore(),{events:events$3}=useBridge(),profiles=ref([]),activeProfileId=ref(null),selectedCard=ref(null),newProfileName=ref(null),onLoad=async id=>{await store$1.loadProfile(id)},onRename=async(profile,newName)=>{await Lua_default.career_saveSystem.renameSaveSlot(profile.id,newName)&&(profile.id=newName)},onCreateSave=async(profileName,tutorialChecked)=>{await store$1.loadProfile(profileName,tutorialChecked,!0)};function onCardActivated(active,index){active?(selectedCard.value=index,index===-1&&(newProfileName.value=getNewName())):selectedCard.value=null}onMounted(()=>{events$3.on(`allCareerSaveSlots`,onProfilesReceived),Lua_default.career_career.sendAllCareerSaveSlotsData()}),onBeforeUnmount(()=>{events$3.off(`allCareerSaveSlots`,onProfilesReceived)}),provide(`validateName`,validateName);let navigateToMainMenu=e=>{activeProfileId.value?window.bngVue.gotoAngularState(`menu.careerPause`):window.bngVue.gotoGameState(`menu.mainmenu`)};function onDeactivate$1(event){event.detail.force||navigateToMainMenu()}async function onProfilesReceived(data){selectedCard.value=null,activeProfileId.value=null,profiles.value=[],!(!data||!Array.isArray(data)||data.length===0)&&(profiles.value=(await updateActiveProfile(data)).map(p$1=>({id:p$1.id,date:p$1.date,creationDate:p$1.creationDate,incompatibleVersion:p$1.incompatibleVersion,outdatedVersion:p$1.outdatedVersion,preview:p$1.preview,beamXP:p$1.beamXP,vouchers:p$1.vouchers,vehicleCount:p$1.vehicleCount,money:p$1.money,insuranceScore:p$1.insuranceScore,branches:p$1.branches})))}async function updateActiveProfile(data){let currentSave=await Lua_default.career_career.sendCurrentSaveSlotData();if(data.sort((a$1,b)=>new Date(b.date)-new Date(a$1.date)),currentSave){activeProfileId.value=currentSave.id;let current=data.find(x=>x.id===currentSave.id);current||=currentSave,data=data.filter(x=>x.id!==currentSave.id),data.splice(0,0,current)}return data}function validateName(newName){return newName?newName.length>100?`Save name cannot be longer than 100 characters`:/[<>:"/\\|?*]/.test(newName)?`Save name cannot contain invalid characters`:profiles.value&&profiles.value.find(profile=>profile.id.toLowerCase()===newName.toLowerCase())?`Save name already exists`:null:`Save name cannot be empty`}function getNewName(){let prefix$1=$translate.contextTranslate(`ui.career.profile`),id;for(let i=1;i<1e3&&(id=`${prefix$1} ${i}`,!(!profiles.value||!profiles.value.find(profile=>profile.id===id)));i++);return id}return onBeforeMount(()=>{Lua_default.simTimeAuthority.pushPauseRequest(`profiles`)}),onUnmounted(()=>{Lua_default.simTimeAuthority.popPauseRequest(`profiles`)}),(_ctx,_cache)=>(openBlock(),createElementBlock(Fragment,null,[withDirectives((openBlock(),createElementBlock(`div`,{class:`profiles-container`,onDeactivate:onDeactivate$1},[createVNode(unref(bngScreenHeading_default),{class:`profiles-title`,preheadings:[_ctx.$ctx_t(`ui.playmodes.career`)]},{default:withCtx(()=>[createTextVNode(toDisplayString(_ctx.$ctx_t(`ui.career.savedProgress`)),1)]),_:1},8,[`preheadings`]),withDirectives(createVNode(BackAside_default,{class:`profiles-back`,onClick:navigateToMainMenu},null,512),[[unref(BngOnUiNav_default),navigateToMainMenu,`back,menu`]]),createVNode(unref(bngList_default),{layout:unref(LIST_LAYOUTS).RIBBON,"target-width":22,"target-height":28,"target-margin":1,"no-background":``},{default:withCtx(()=>[createVNode(ProfileCreateCard_default,{profileName:newProfileName.value,"onUpdate:profileName":_cache[0]||=$event=>newProfileName.value=$event,class:`profile-card`,"onCard:activate":_cache[1]||=value=>onCardActivated(value,-1),onLoad:onCreateSave},null,8,[`profileName`]),(openBlock(!0),createElementBlock(Fragment,null,renderList(profiles.value,(profile,index)=>withDirectives((openBlock(),createBlock(ProfileCard_default,{key:index,id:profile.id,date:profile.date,creationDate:profile.creationDate,incompatibleVersion:profile.incompatibleVersion,outdatedVersion:profile.outdatedVersion,preview:profile.preview,beamXP:profile.beamXP,vouchers:profile.vouchers,vehicleCount:profile.vehicleCount,money:profile.money,insuranceScore:profile.insuranceScore,branches:profile.branches,active:activeProfileId.value===profile.id,disabled:selectedCard.value!==null&&selectedCard.value!==index,class:`profile-card`,"onCard:activate":value=>onCardActivated(value,index),onLoad,onRename:newName=>onRename(profile,newName)},null,8,[`id`,`date`,`creationDate`,`incompatibleVersion`,`outdatedVersion`,`preview`,`beamXP`,`vouchers`,`vehicleCount`,`money`,`insuranceScore`,`branches`,`active`,`disabled`,`onCard:activate`,`onRename`])),[[unref(BngPopover_default),profile.incompatibleVersion?`tooltip-outdated-message`:null,`top`]])),128))]),_:1},8,[`layout`])],32)),[[unref(BngScopedNav_default),{activateOnMount:!0}]]),createVNode(unref(bngPopoverContent_default),{name:`tooltip-outdated-message`},{default:withCtx(()=>[..._cache[2]||=[createBaseVNode(`div`,{class:`tooltip-outdated-message`},`This profile was saved with an old version of the game. It can no longer be loaded.`,-1)]]),_:1})],64))}},Profiles_default=__plugin_vue_export_helper_default(_sfc_main$219,[[`__scopeId`,`data-v-6aef0f62`]]);const useRepairStore=defineStore(`repair`,()=>{let repairOptions=ref({}),vehicleData=ref({}),playerAttributes=ref({}),driverScoreTierData=ref({}),futureDriverScore=ref(0),driverScore=ref(0),resetStore=()=>{repairOptions.value={},vehicleData.value={},playerAttributes.value={},driverScoreTierData.value={},futureDriverScore.value=0,driverScore.value=0};return{repairOptions,vehicleData,playerAttributes,getRepairData:()=>{resetStore(),Lua_default.career_modules_insurance_repairScreen.getRepairData().then(data=>{repairOptions.value=data.repairOptions,vehicleData.value=data.vehicleData,playerAttributes.value=data.playerAttributes,driverScoreTierData.value=data.driverScoreTierData,futureDriverScore.value=data.futureDriverScore,driverScore.value=data.driverScore})},driverScoreTierData,futureDriverScore,driverScore,resetStore}});var _hoisted_1$195={class:`content blue-background`},_hoisted_2$158={class:`vehicle-info`},_hoisted_3$139={class:`right-info-wrapper`},_hoisted_4$115={class:`damage-estimate-wrapper`},_hoisted_5$100={class:`damage-estimate-value`},_hoisted_6$83={key:0},_hoisted_7$71={class:`repair-options`},_hoisted_8$58=[`onClick`],_hoisted_9$52={class:`icon-wrapper`},_hoisted_10$45={key:0,class:`option-text-wrapper`},_hoisted_11$40={class:`smaller-text`},_hoisted_12$30={class:`bigger-text`,style:{"margin-top":`-5px`}},_hoisted_13$26={key:1,class:`option-text-wrapper`},_hoisted_14$25={key:0},_hoisted_15$24={class:`details-wrapper`},_hoisted_16$24={class:`detail-wrapper`},_hoisted_17$19={class:`item`},_hoisted_18$17={key:0,class:`accident-forgivenesses-text`},_hoisted_19$14={key:0,class:`item`},_hoisted_20$12={class:`item-value`},_hoisted_21$11={key:1,class:`renews-in-wrapper`},_hoisted_22$9={class:`renews-in-name`},_hoisted_23$8={class:`renews-in-value`},_hoisted_24$7={class:`detail-wrapper`},_hoisted_25$6={class:`item`},_hoisted_26$5={class:`item-value`},_hoisted_27$5={class:`item`},_hoisted_28$4={class:`item-value`},_hoisted_29$4={key:0,class:`item`},_hoisted_30$4={class:`item-value`},_hoisted_31$4={key:1,class:`item`},_hoisted_32$4={class:`item-value`},_hoisted_33$4={class:`item total-cost`},_hoisted_34$4={class:`item-value`},_hoisted_35$3={key:0},_hoisted_36$3={key:1},_hoisted_37$2={class:`confirm-repair-money-wrapper`},_hoisted_38$2={key:2},_hoisted_39$2={class:`confirm-repair-money-wrapper`},_sfc_main$218={__name:`RepairMain`,setup(__props){let{units}=useBridge();useComputerStore();let repairStore=useRepairStore(),selectedRepairOptionKey=ref(null),selectedRepairTimeOptionIndex=ref(1),currentRepairOption=computed(()=>!selectedRepairOptionKey.value||!repairStore.repairOptions?null:repairStore.repairOptions[selectedRepairOptionKey.value]),accidentForgivenessesText=computed(()=>!repairStore.repairOptions.insuranceRepairData.accidentForgivenesses>0?`(No Accident Forgivenesses left)`:`(`+repairStore.repairOptions.insuranceRepairData.accidentForgivenesses+` Accident Forgivenesses left)`),selectedRepairTimeOption=computed(()=>currentRepairOption.value?.repairTimeOptions?.choices?currentRepairOption.value.repairTimeOptions.choices.find(choice=>choice.id===selectedRepairTimeOptionIndex.value):null),renewsInFormatted=computed(()=>currentRepairOption.value?.renewsIn?units.buildString(`length`,currentRepairOption.value.renewsIn*1e3,0):``);watch(()=>repairStore.repairOptions,newOptions=>{if(newOptions&&Object.keys(newOptions).length>0&&!selectedRepairOptionKey.value){let selectedKey=Object.keys(newOptions).find(key=>newOptions[key].useInsurance)||Object.keys(newOptions)[0];selectedRepairOptionKey.value=selectedKey,newOptions[selectedKey]?.repairTimeOptions?.currentValueId&&(selectedRepairTimeOptionIndex.value=newOptions[selectedKey].repairTimeOptions.currentValueId)}},{immediate:!0}),watch(()=>selectedRepairOptionKey.value,newKey=>{newKey&&repairStore.repairOptions[newKey]?.repairTimeOptions?.currentValueId?selectedRepairTimeOptionIndex.value=repairStore.repairOptions[newKey].repairTimeOptions.currentValueId:selectedRepairTimeOptionIndex.value=1});let onRepairOptionClick=key=>{selectedRepairOptionKey.value=key},close=()=>{Lua_default.career_modules_insurance_repairScreen.closeMenu()},startRepair=(repairOptionKey,repairTimeOptionIndex)=>{selectedRepairTimeOption.value&&Lua_default.career_modules_insurance_repairScreen.startRepairInGarage(repairStore.vehicleData.invVehId,{repairTime:selectedRepairTimeOption.value.value,isInsuranceRepair:currentRepairOption.value.useInsurance,cost:{repairTimeCost:selectedRepairTimeOption.value.premiumInfluence,deductible:currentRepairOption.value.useInsurance?repairStore.repairOptions.insuranceRepairData.deductible:repairStore.vehicleData.damageCost}})};return onMounted(()=>{repairStore.getRepairData()}),onUnmounted(()=>{repairStore.resetStore()}),(_ctx,_cache)=>(openBlock(),createBlock(ComputerWrapper_default,{path:[`Repair`],title:`Repair ${unref(repairStore).vehicleData.name}`,back:``,onBack:close},{default:withCtx(()=>[unref(repairStore).vehicleData.name?(openBlock(),createBlock(unref(bngCard_default),{key:0,class:`repairMain blue-background`},{default:withCtx(()=>[createBaseVNode(`div`,_hoisted_1$195,[_cache[23]||=createBaseVNode(`div`,{class:`title`},`Vehicle Repair`,-1),createBaseVNode(`div`,_hoisted_2$158,[createVNode(unref(insuranceVehTile_default),{class:`vehicle-tile`,vehicle:unref(repairStore).vehicleData},{rightContent:withCtx(()=>[createBaseVNode(`div`,_hoisted_3$139,[createBaseVNode(`div`,_hoisted_4$115,[_cache[2]||=createBaseVNode(`span`,{class:`damage-estimate-text`},` Damage Estimate: `,-1),createBaseVNode(`span`,_hoisted_5$100,[createVNode(unref(bngUnit_default),{class:`red-price`,money:unref(repairStore).vehicleData.damageCost},null,8,[`money`])])]),unref(repairStore).vehicleData.isInsured?createCommentVNode(``,!0):(openBlock(),createElementBlock(`div`,_hoisted_6$83,[..._cache[3]||=[createBaseVNode(`span`,{class:`not-insured-text`},` Not Insured! `,-1)]]))])]),_:1},8,[`vehicle`])]),createBaseVNode(`div`,null,[_cache[7]||=createBaseVNode(`div`,{class:`repair-options-title`},`Repair Options`,-1),createBaseVNode(`div`,_hoisted_7$71,[(openBlock(!0),createElementBlock(Fragment,null,renderList(unref(repairStore).repairOptions,(repairOption,key)=>(openBlock(),createElementBlock(`div`,{key,class:normalizeClass([`repair-option`,{selected:selectedRepairOptionKey.value===key}]),onClick:$event=>onRepairOptionClick(key)},[createBaseVNode(`div`,_hoisted_9$52,[createVNode(unref(bngIcon_default),{type:repairOption.useInsurance?unref(icons).shieldCheckmark:unref(icons).wrench},null,8,[`type`])]),createBaseVNode(`div`,null,[repairOption.useInsurance?(openBlock(),createElementBlock(`div`,_hoisted_10$45,[_cache[5]||=createBaseVNode(`div`,{class:`bigger-text`},` Insurance Claim `,-1),createBaseVNode(`div`,_hoisted_11$40,toDisplayString(repairOption.insuranceName),1),createBaseVNode(`div`,_hoisted_12$30,[_cache[4]||=createTextVNode(` Deductible : `,-1),createVNode(unref(bngUnit_default),{class:`unit-no-padding`,money:unref(repairStore).repairOptions.insuranceRepairData.deductible},null,8,[`money`])])])):(openBlock(),createElementBlock(`div`,_hoisted_13$26,[..._cache[6]||=[createBaseVNode(`div`,{class:`bigger-text`},` Private Repair `,-1),createBaseVNode(`div`,{class:`smaller-text`},` No Policy Impact `,-1),createBaseVNode(`div`,{class:`bigger-text`},` Full Damage Cost `,-1)]]))])],10,_hoisted_8$58))),128))])]),currentRepairOption.value?(openBlock(),createElementBlock(`div`,_hoisted_14$25,[(openBlock(),createBlock(unref(coverageOption_default),{coverageOption:currentRepairOption.value.repairTimeOptions,key:`repairTime-${selectedRepairOptionKey.value}`,modelValue:selectedRepairTimeOptionIndex.value,"onUpdate:modelValue":_cache[0]||=$event=>selectedRepairTimeOptionIndex.value=$event,simpleSelect:!0,showPerkMode:`none`},null,8,[`coverageOption`,`modelValue`]))])):createCommentVNode(``,!0),createBaseVNode(`div`,_hoisted_15$24,[createBaseVNode(`div`,_hoisted_16$24,[_cache[13]||=createBaseVNode(`h3`,null,`Insurance Impact`,-1),createBaseVNode(`div`,_hoisted_17$19,[createBaseVNode(`span`,null,[_cache[8]||=createBaseVNode(`div`,{class:`item-label`},`Driver Score Change`,-1),currentRepairOption.value.useInsurance?(openBlock(),createElementBlock(`div`,_hoisted_18$17,toDisplayString(accidentForgivenessesText.value),1)):createCommentVNode(``,!0)]),createBaseVNode(`span`,{class:normalizeClass([`item-value`,{"red-text":currentRepairOption.value.useInsurance&&unref(repairStore).futureDriverScorestartRepair(selectedRepairOptionKey.value,selectedRepairTimeOptionIndex.value)},{default:withCtx(()=>[unref(repairStore).vehicleData.needsRepair?selectedRepairTimeOption.value?.canPay?(openBlock(),createElementBlock(`div`,_hoisted_38$2,[_cache[22]||=createTextVNode(` Confirm Repair `,-1),createBaseVNode(`div`,_hoisted_39$2,[createVNode(unref(bngUnit_default),{money:selectedRepairTimeOption.value?.totalPrice},null,8,[`money`])])])):(openBlock(),createElementBlock(`div`,_hoisted_36$3,[_cache[21]||=createTextVNode(` Insufficient funds `,-1),createBaseVNode(`div`,_hoisted_37$2,[createVNode(unref(bngUnit_default),{money:selectedRepairTimeOption.value?.totalPrice},null,8,[`money`])])])):(openBlock(),createElementBlock(`div`,_hoisted_35$3,` Vehicle doesn't need repair `))]),_:1},8,[`disabled`])])]),_:1})):createCommentVNode(``,!0)]),_:1},8,[`title`]))}},RepairMain_default=__plugin_vue_export_helper_default(_sfc_main$218,[[`__scopeId`,`data-v-19ad91be`]]),_hoisted_1$194={class:`awd-container bng-app`},_hoisted_2$157={key:0,class:`awd-table`},_hoisted_3$138={class:`data-name`},_sfc_main$217={__name:`app`,setup(__props,{expose:__expose}){let{$game}=useLibStore(),streamList=[`advancedWheelDebugData`],data=ref([]),hasData=computed(()=>Array.isArray(data.value)&&data.value.length>0),orderedData=computed(()=>Array.isArray(data.value)?data.value.sort((a$1,b)=>a$1.name.toLowerCase().localeCompare(b.name.toLowerCase())):[]);__expose({hasData}),onMounted(()=>{$game.streams.add(streamList),register()}),onUnmounted(()=>{$game.streams.remove(streamList),$game.api.activeObjectLua(`extensions.advancedwheeldebug.registerDebugUser("advancedWheelDebugApp", false)`)});let register=()=>$game.api.activeObjectLua(`extensions.advancedwheeldebug.registerDebugUser("advancedWheelDebugApp", true)`),format$2=value=>value?parseFloat(value).toFixed(3):``;return $game.events.on(`onStreamsUpdate`,streams=>data.value=streams.advancedWheelDebugData),$game.events.on(`VehicleReset`,register),$game.events.on(`VehicleChange`,register),(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$194,[orderedData.value&&orderedData.value.length>0?(openBlock(),createElementBlock(`table`,_hoisted_2$157,[_cache[0]||=createBaseVNode(`thead`,null,[createBaseVNode(`tr`,null,[createBaseVNode(`th`,null,`Name`),createBaseVNode(`th`,null,`Camber`),createBaseVNode(`th`,null,`Toe`),createBaseVNode(`th`,null,`Caster`),createBaseVNode(`th`,null,`SAI`)])],-1),(openBlock(!0),createElementBlock(Fragment,null,renderList(orderedData.value,w=>(openBlock(),createElementBlock(`tr`,null,[createBaseVNode(`td`,_hoisted_3$138,toDisplayString(w.name),1),createBaseVNode(`td`,null,toDisplayString(format$2(w.camber)),1),createBaseVNode(`td`,null,toDisplayString(format$2(w.toe)),1),createBaseVNode(`td`,null,toDisplayString(format$2(w.caster)),1),createBaseVNode(`td`,null,toDisplayString(format$2(w.sai)),1)]))),256))])):createCommentVNode(``,!0)]))}},app_default$2=__plugin_vue_export_helper_default(_sfc_main$217,[[`__scopeId`,`data-v-5eb5aaaa`]]),_hoisted_1$193={class:`legends-container`},TAG=`[beamng.apps:brakeTorqueGraph]`,_sfc_main$216={__name:`app`,setup(__props){let{$game}=useLibStore(),app$1=ref(null),canvas=ref(null),graphList=ref([]),streamsList$1=[`wheelInfo`,`electrics`],colors=[],chart=new SmoothieChart({minValue:0,millisPerPixel:20,interpolation:`linear`,grid:{fillStyle:`rgba(250, 250, 250, 0.8)`,strokeStyle:`rgba(0,0,0,0.3)`,verticalSections:6,millisPerLine:1e3,sharpLines:!0},labels:{fillStyle:`black`}}),speedGraph=new TimeSeries,appResizeObserver=new ResizeObserver(entries=>{let entry=entries[0];canvas.value.width=entry.target.offsetWidth,canvas.value.height=entry.target.offsetHeight}),graphs={},globalMax=2e3;onMounted(()=>{initColors(),initChart(),appResizeObserver.observe(app$1.value),graphList.value=[{title:`ui.apps.brake_torque_graph.speed`,color:colors[0]}],$game.streams.add(streamsList$1),$game.events.on(`onStreamsUpdate`,onStreamsUpdate),$game.events.on(`VehicleReset`,onVehicleReset),$game.events.on(`VehicleChange`,onVehicleChange)}),onBeforeUnmount(()=>{appResizeObserver.unobserve(app$1.value)}),onUnmounted(()=>{$game.events.off(`onStreamsUpdate`,onStreamsUpdate),$game.events.off(`VehicleReset`,onVehicleReset),$game.events.off(`VehicleChange`,onVehicleChange),$game.streams.remove(streamsList$1)});function onStreamsUpdate(streams){for(let stream of streamsList$1)if(!streams[stream])return;globalMax=Math.max(globalMax,streams.electrics.airspeed*15);let xPoint=new Date;for(let w in speedGraph.append(xPoint,streams.electrics.airspeed*15),streams.wheelInfo){let wheelName=streams.wheelInfo[w][0];if(!graphs.hasOwnProperty(wheelName)){graphs[wheelName]=new TimeSeries,logger_default.debug(`${TAG} adding graph for ${wheelName}`);let wheelColor=colors[graphList.value.length%colors.length];graphList.value.push({title:wheelName,color:wheelColor}),chart.addTimeSeries(graphs[wheelName],{strokeStyle:wheelColor,lineWidth:2});return}graphs[wheelName].append(xPoint,streams.wheelInfo[w][8]),globalMax=Math.max(globalMax,streams.wheelInfo[w][8])}chart.options.maxValue=globalMax}function onVehicleReset(data){graphs={},graphList.value=[{title:`Speed`,color:colors[0]}]}function onVehicleChange(data){graphs={},graphList.value=[{title:`Speed`,color:colors[0]}]}function initChart(){chart.addTimeSeries(speedGraph,{strokeStyle:colors[0],lineWidth:2}),chart.streamTo(canvas.value,40)}function initColors(){for(let i=15;i>0;i--){let c=rainbow(15,i);colors.push(`rgb(${Math.round(255*c[0])}, ${Math.round(255*c[1])}, ${Math.round(255*c[2])})`)}}return(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,{class:`btg-app`,ref_key:`app`,ref:app$1},[createBaseVNode(`div`,_hoisted_1$193,[(openBlock(!0),createElementBlock(Fragment,null,renderList(graphList.value,graph=>(openBlock(),createElementBlock(`small`,{class:`legend`,style:normalizeStyle({color:graph.color})},toDisplayString(_ctx.$t(graph.title)),5))),256))]),createBaseVNode(`canvas`,{ref_key:`canvas`,ref:canvas},null,512)],512))}},app_default$3=__plugin_vue_export_helper_default(_sfc_main$216,[[`__scopeId`,`data-v-642d2338`]]),_hoisted_1$192={class:`bus-line bng-app`},_hoisted_2$156={class:`header`},_hoisted_3$137={class:`time`},_hoisted_4$114={class:`logo`},_hoisted_5$99=[`src`],_hoisted_6$82={class:`route-id`},_hoisted_7$70={class:`text`},_hoisted_8$57={class:`destination`},_hoisted_9$51={key:0,class:`display-stops`},_hoisted_10$44={class:`title`},_hoisted_11$39={key:1,class:`next-stop`},_hoisted_12$29={class:`title`},defaultRouteId=`00`,defaultDestination=`Not in service`,defaultRouteColor=`#FFA200`,totalRoutesDisplayed=4,_sfc_main$215={__name:`app`,setup(__props){let{$game}=useLibStore(),timerInterval,navDisplay=reactive({time:``,stopRequested:!1}),localBusRoute=ref(null),routeId=computed(()=>localBusRoute.value&&localBusRoute.value.routeId?localBusRoute.value.routeId.substring(0,3):defaultRouteId),destination=computed(()=>localBusRoute.value&&localBusRoute.value.destination?localBusRoute.value.destination.substring(0,20):defaultDestination),routeColor=computed(()=>localBusRoute.value&&localBusRoute.value.routeColor?localBusRoute.value.routeColor:defaultRouteColor),stops=computed(()=>{if(!localBusRoute.value||!localBusRoute.value.stops)return null;let data=localBusRoute.value.stops.slice(0,-1);return data.length>totalRoutesDisplayed&&(data=data.slice(1).slice(0,totalRoutesDisplayed)),data.reverse()}),nextStop=computed(()=>localBusRoute.value&&localBusRoute.value.stops&&localBusRoute.value.stops.length-1>totalRoutesDisplayed?localBusRoute.value.stops[0]:null);onBeforeMount(()=>{updateTime(),timerInterval=setInterval(()=>{updateTime()},1e3)}),onMounted(()=>{$game.events.on(`BusDisplayUpdate`,onBusDisplayUpdate),$game.events.on(`SetStopRequest`,onSetStopRequest),$game.api.engineLua(`if scenario_busdriver then scenario_busdriver.requestState() end`)}),onUnmounted(()=>{clearInterval(timerInterval),$game.events.off(`BusDisplayUpdate`,onBusDisplayUpdate),$game.events.off(`SetStopRequest`,onSetStopRequest)});function onBusDisplayUpdate(data){console.log(`onBusDisplayUpdate`,data),localBusRoute.value?(localBusRoute.value.routeId=data.routeId,localBusRoute.value.stops=localBusRoute.value.stops.filter(x=>data.tasklist.find(y=>y[0]===x.id))):localBusRoute.value=parseBusData(data)}function onSetStopRequest(data){console.log(`onSetStopRequest`,data),data&&data.stopRequested!==null&&(navDisplay.stopRequested=data.stopRequested)}function updateTime(){let date=new Date;navDisplay.time=`${date.getHours()}:${date.getMinutes()<10?`0`+date.getMinutes():date.getMinutes()}`}function parseBusData(data){return{destination:data.direction,routeId:data.routeId,routeColor:data.routeColor,stops:data.tasklist.map(x=>({id:x[0],name:x[1]}))}}return(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$192,[createBaseVNode(`div`,{class:`content`,style:normalizeStyle({"--routeColor":routeColor.value})},[createBaseVNode(`div`,_hoisted_2$156,[createBaseVNode(`div`,_hoisted_3$137,toDisplayString(navDisplay.time),1),createBaseVNode(`div`,_hoisted_4$114,[createBaseVNode(`img`,{src:unref(getAssetURL)(`images/beamng_logo_50x50.png`)},null,8,_hoisted_5$99)])]),createBaseVNode(`div`,{class:normalizeClass([`route`,{highlight:!stops.value||stops.value.length===0}])},[createBaseVNode(`div`,_hoisted_6$82,[createBaseVNode(`span`,_hoisted_7$70,toDisplayString(routeId.value),1),_cache[0]||=createBaseVNode(`span`,{class:`chevron`},null,-1)]),createBaseVNode(`div`,_hoisted_8$57,toDisplayString(destination.value),1)],2),stops.value?(openBlock(),createElementBlock(`div`,_hoisted_9$51,[(openBlock(!0),createElementBlock(Fragment,null,renderList(stops.value,stop$1=>(openBlock(),createElementBlock(`div`,{class:`stop`,key:stop$1.id},[_cache[1]||=createBaseVNode(`div`,{class:`chevron`},null,-1),createBaseVNode(`div`,_hoisted_10$44,toDisplayString(stop$1.name),1)]))),128))])):createCommentVNode(``,!0),nextStop.value?(openBlock(),createElementBlock(`div`,_hoisted_11$39,[_cache[2]||=createBaseVNode(`div`,{class:`chevron`},null,-1),createBaseVNode(`div`,_hoisted_12$29,toDisplayString(nextStop.value.name),1)])):createCommentVNode(``,!0)],4),createBaseVNode(`div`,{class:normalizeClass([`stop-request`,{requested:navDisplay.stopRequested}])},[createBaseVNode(`div`,{class:normalizeClass([`text`,{glow:navDisplay.stopRequested}])},toDisplayString(_ctx.$t(`ui.busRoute.stopRequested`)),3)],2)]))}},app_default$4=__plugin_vue_export_helper_default(_sfc_main$215,[[`__scopeId`,`data-v-7731db49`]]),_hoisted_1$191={class:`bng-app cd-container`,layout:`column`,"layout-align":`center center`},_sfc_main$214={__name:`app`,setup(__props){let{$game}=useLibStore(),cameraDistance=ref(null);return onMounted(()=>{$game.api.engineLua(`extensions.load("ui_cameraDistanceApp")`)}),onUnmounted(()=>{$game.api.engineLua(`extensions.unload("ui_cameraDistanceApp")`)}),$game.events.on(`cameraDistance`,function(distance,errMsg){distance<0?cameraDistance.value=errMsg:cameraDistance.value=$game.units.buildString(`length`,distance,2)}),(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$191,[createBaseVNode(`span`,null,toDisplayString(cameraDistance.value),1)]))}},app_default$5=__plugin_vue_export_helper_default(_sfc_main$214,[[`__scopeId`,`data-v-d72a4879`]]),_hoisted_1$190={key:0,class:`bng-app thermal-clutch-debug`},_hoisted_2$155={class:`set-name`},_sfc_main$213={__name:`app`,setup(__props){let{$game}=useLibStore(),streamsList$1=[`clutchThermalData`],data=ref([]);onMounted(()=>{$game.streams.add(streamsList$1)}),onUnmounted(()=>{$game.streams.remove(streamsList$1)}),$game.events.on(`onStreamsUpdate`,streams=>{streams.clutchThermalData?data.value=parseData(streams.clutchThermalData):data.value=null});function parseData(data$1){return[{str:$game.units.buildString(`temperature`,data$1.clutchTemperature,0),name:`Clutch temperature`,warn:data$1.clutchTemperature>data$1.maxSafeTemp&&data$1.clutchTemperature<=data$1.efficiencyScaleEnd,error:data$1.clutchTemperature>data$1.efficiencyScaleEnd},{str:$game.units.buildString(`temperature`,data$1.maxSafeTemp,0),name:`Max safe temperature`},{str:$game.units.buildString(`temperature`,data$1.efficiencyScaleEnd,0),name:`Efficiency scale end`},{str:data$1.thermalEfficiency.toFixed(3),name:`Clutch efficiency`,warn:data$1.thermalEfficiency<1&&data$1.thermalEfficiency>=.5,error:data$1.thermalEfficiency<.5},{str:$game.units.buildString(`energy`,data$1.energyToClutch,0),name:`Q to clutch`},{str:$game.units.buildString(`energy`,data$1.energyClutchToBellHousing,0),name:`Q clutch to bell housing`}]}return(_ctx,_cache)=>data.value?(openBlock(),createElementBlock(`div`,_hoisted_1$190,[(openBlock(!0),createElementBlock(Fragment,null,renderList(data.value,(set,index)=>(openBlock(),createElementBlock(`div`,{key:index,class:`set`},[createBaseVNode(`div`,_hoisted_2$155,toDisplayString(set.name),1),createBaseVNode(`div`,{class:normalizeClass([`set-value`,{"thermal-warning":set.warn,"thermal-error":set.error}])},toDisplayString(set.str),3)]))),128))])):createCommentVNode(``,!0)}},app_default$6=__plugin_vue_export_helper_default(_sfc_main$213,[[`__scopeId`,`data-v-c0f00383`]]),_hoisted_1$189={width:`100%`,height:`100%`,viewBox:`0 0 244 244`},_hoisted_2$154=[`transform`],_sfc_main$212={__name:`app`,setup(__props){let streamsList$1=[`sensors`],{$game}=useLibStore(),arrow$3=ref(null),circle=ref(null),yawDegrees=ref(0),bbox=computed(()=>arrow$3.value?arrow$3.value.getBBox():null),rotateOrigin=computed(()=>bbox.value?`${yawDegrees.value} ${bbox.value.x+bbox.value.width/2} ${bbox.value.y+bbox.value.height/2}`:0);onMounted(()=>{$game.events.on(`onStreamsUpdate`,onStreamsUpdate),$game.streams.add(streamsList$1)}),onUnmounted(()=>{$game.events.off(`onStreamsUpdate`,onStreamsUpdate),$game.streams.remove(streamsList$1)});function onStreamsUpdate(streams){for(let stream of streamsList$1)if(!streams[stream])return;yawDegrees.value=streams.sensors.yaw*180/Math.PI+180}return(_ctx,_cache)=>(openBlock(),createElementBlock(`svg`,_hoisted_1$189,[createBaseVNode(`g`,{ref_key:`circle`,ref:circle,transform:`rotate(${rotateOrigin.value})`},[..._cache[0]||=[createStaticVNode(`NESW`,5)]],8,_hoisted_2$154),createBaseVNode(`path`,{d:`M122 90 L105 154 L139 154 Z`,ref_key:`arrow`,ref:arrow$3,class:`arrow`},null,512)]))}},app_default$7=__plugin_vue_export_helper_default(_sfc_main$212,[[`__scopeId`,`data-v-4a5918e7`]]),compassWidth=2e3,_sfc_main$211={__name:`app`,setup(__props){let streamsList$1=[`sensors`],{$game}=useLibStore(),app$1=ref(null),canvas=ref(null),osCanvas=ref(null),widthLess=computed(()=>(compassWidth-canvas.value.width)/2),appResizeObserver=new ResizeObserver(entries=>{let entry=entries[0];canvas.value.width=entry.target.offsetWidth,canvas.value.height=entry.target.offsetHeight});onMounted(()=>{initOsCanvas(),appResizeObserver.observe(app$1.value),$game.events.on(`onStreamsUpdate`,onStreamsUpdate),$game.streams.add(streamsList$1)}),onBeforeUnmount(()=>{appResizeObserver.unobserve(app$1.value)}),onUnmounted(()=>{$game.events.off(`onStreamsUpdate`,onStreamsUpdate),$game.streams.remove(streamsList$1)});function onStreamsUpdate(streams){for(let stream of streamsList$1)if(!streams[stream])return;let canvasCtx=canvas.value.getContext(`2d`);canvasCtx.clearRect(0,0,canvas.value.width,canvas.value.height),canvasCtx.fillStyle=`rgba(255,255,255,0.8)`,canvasCtx.strokeStyle=`rgba(255,255,255,0.6)`;let heading=streams.sensors.yaw,posX=heading*compassWidth/(2*Math.PI)-widthLess.value;canvasCtx.drawImage(osCanvas.value,posX,0),heading*compassWidth/(2*Math.PI)-widthLess.value>0?canvasCtx.drawImage(osCanvas.value,posX-compassWidth,0):posX+compassWidth(openBlock(),createElementBlock(`div`,{class:`container`,ref_key:`app`,ref:app$1},[createBaseVNode(`canvas`,{ref_key:`canvas`,ref:canvas,width:`280`,height:`56`},null,512),createBaseVNode(`canvas`,{ref_key:`osCanvas`,ref:osCanvas,class:`os-canvas`},null,512)],512))}},app_default$8=__plugin_vue_export_helper_default(_sfc_main$211,[[`__scopeId`,`data-v-e608df6a`]]),_hoisted_1$188={transform:`translate(-13.701535,-283.48656)`,style:{display:`inline`},id:`carGroup`},_hoisted_2$153={y:`255.49614`,x:`142.73175`,style:{"font-style":`normal`,"font-variant":`normal`,"font-weight":`normal`,"font-stretch":`normal`,"font-size":`18.66665649px`,"line-height":`1.25`,"font-family":`roboto`,"-inkscape-font-specification":`roboto`,"letter-spacing":`0px`,"word-spacing":`0px`,fill:`#ffffff`},"xml:space":`preserve`},componentDamageMap={body:{FL:{svgId:`bodyFL`,priority:2,tempDamage:!1},FR:{svgId:`bodyFR`,priority:2,tempDamage:!1},ML:{svgId:`bodyML`,priority:2,tempDamage:!1},MR:{svgId:`bodyMR`,priority:2,tempDamage:!1},RL:{svgId:`bodyRL`,priority:2,tempDamage:!1},RR:{svgId:`bodyRR`,priority:2,tempDamage:!1}},engine:{oilStarvation:{svgId:`engine`,priority:0,damageText:`Oil Starvation`,tempDamage:!0},coolantHot:{svgId:`engine`,priority:0,damageText:`Coolant Overheating`,tempDamage:!1},oilHot:{svgId:`engine`,priority:0,damageText:`Oil Overheating`,tempDamage:!1},pistonRingsDamaged:{svgId:`engine`,priority:0,damageText:`Piston Rings Damaged`,tempDamage:!1},rodBearingsDamaged:{svgId:`engine`,priority:0,damageText:`Rod Bearings Damaged`,tempDamage:!1},headGasketDamaged:{svgId:`engine`,priority:0,damageText:`Head Gasket Damaged`,tempDamage:!1},turbochargerHot:{svgId:`engine`,priority:0,damageText:`Turbocharger Overheating`,tempDamage:!1},engineIsHydrolocking:{svgId:`engine`,priority:0,damageText:`Engine is Hydrolocking`,tempDamage:!1},engineReducedTorque:{svgId:`engine`,priority:0,damageText:`Engine Torque Reduced`,tempDamage:!1},mildOverrevDamage:{svgId:`engine`,priority:0,damageText:`Mild Over Rev Damage`,tempDamage:!1},overRevDanger:{svgId:`engine`,priority:0,damageText:`Over Rev Risk`,tempDamage:!1},overTorqueDanger:{svgId:`engine`,priority:0,damageText:`Over Torque Risk`,tempDamage:!1},engineHydrolocked:{svgId:`engine`,priority:1,damageText:`Engine is Hydrolocked`,tempDamage:!1},engineDisabled:{svgId:`engine`,priority:1,damageText:`Engine Disabled`,tempDamage:!1},blockMelted:{svgId:`engine`,priority:1,damageText:`Block Melted`,tempDamage:!1},engineLockedUp:{svgId:`engine`,priority:1,damageText:`Engine Locked Up`,tempDamage:!1},radiatorLeak:{svgId:`radiator`,priority:1,damageText:`Radiator Leaking`,tempDamage:!1}},powertrain:{wheelaxleFL:{svgId:`wheelaxleFL`,priority:1,damageText:`Front Left Axle Broken`,tempDamage:!1},wheelaxleFR:{svgId:`wheelaxleFR`,priority:1,damageText:`Front Right Axle Broken`,tempDamage:!1},wheelaxleRL:{svgId:`wheelaxleRL`,priority:1,damageText:`Rear Left Axle Broken`,tempDamage:!1},wheelaxleRR:{svgId:`wheelaxleRR`,priority:1,damageText:`Rear Right Axle Broken`,tempDamage:!1},driveshaft:{svgId:`driveshaft`,priority:1,damageText:`Driveshaft Broken`,tempDamage:!1},driveshaft_F:{svgId:`driveshaft`,priority:1,damageText:`Front Driveshaft Broken`,tempDamage:!1},mainEngine:{svgId:`engine`,priority:1,damageText:`Engine Broken`,tempDamage:!1}},energyStorage:{mainTank:{svgId:`fueltank`,priority:1,damageText:`Fuel Tank Damaged`,tempDamage:!1}},wheels:{tireFL:{svgId:`tireFL`,priority:0,damageText:`Front Left Tire Burst`,tempDamage:!1},tireFR:{svgId:`tireFR`,priority:0,damageText:`Front Right Tire Burst`,tempDamage:!1},tireRL:{svgId:`tireRL`,priority:0,damageText:`Rear Left Tire Burst`,tempDamage:!1},tireRR:{svgId:`tireRR`,priority:0,damageText:`Rear Right Tire Burst`,tempDamage:!1},brakeFL:{svgId:`brakeFL`,priority:1,damageText:`FL Brake Damaged`,tempDamage:!1},brakeFR:{svgId:`brakeFR`,priority:1,damageText:`FR Brake Damaged`,tempDamage:!1},brakeRL:{svgId:`brakeRL`,priority:1,damageText:`RL Brake Damaged`,tempDamage:!1},brakeRR:{svgId:`brakeRR`,priority:1,damageText:`RR Brake Damaged`,tempDamage:!1},brakeOverHeatFL:{svgId:`brakeFL`,priority:0,damageText:`FL Brake Fading`,tempDamage:!0},brakeOverHeatFR:{svgId:`brakeFR`,priority:0,damageText:`FR Brake Fading`,tempDamage:!0},brakeOverHeatRL:{svgId:`brakeRL`,priority:0,damageText:`RL Brake Fading`,tempDamage:!0},brakeOverHeatRR:{svgId:`brakeRR`,priority:0,damageText:`RR Brake Fading`,tempDamage:!0},FL:{svgId:`tireFL`,priority:1,damageText:`Front Left Tire Broken`,tempDamage:!1},FR:{svgId:`tireFR`,priority:1,damageText:`Front Right Tire Broken`,tempDamage:!1},RL:{svgId:`tireRL`,priority:1,damageText:`Rear Left Tire Broken`,tempDamage:!1},RR:{svgId:`tireRR`,priority:1,damageText:`Rear Right Tire Broken`,tempDamage:!1}}},textDisplayTime=2e3,orangeColor=`rgba(255, 132, 0, 0.6)`,redColor=`rgba(255, 0, 0, 0.6)`,noDataColor=`rgba(0, 0, 0, 0 )`,streamsList=[`wheelThermalData`,`engineInfo`],_sfc_main$210={__name:`app`,setup(__props){let{$game}=useLibStore(),svg=ref(null),tireFL=ref(null),tireFR=ref(null),tireRL=ref(null),tireRR=ref(null),bodyFL=ref(null),bodyML=ref(null),bodyMR=ref(null),driveShaft=ref(null),engine=ref(null),fueltank=ref(null),radiator=ref(null),wheelaxleFL=ref(null),wheelaxleFR=ref(null),brakeFL=ref(null),brakeFR=ref(null),bodyFR=ref(null),bodyRL=ref(null),bodyRR=ref(null),brakeRL=ref(null),brakeRR=ref(null),wheelaxleRL=ref(null),wheelaxleRR=ref(null),damageContainer=ref(null),damageBox=ref(null),damageText=ref(null),appState=reactive({isAppDisplayed:!1,hasDamage:!1,permanentDamagedParts:0,isProcessingMessages:!1}),damageTextQueue=ref([]),componentDamage=ref({body:{FL:{damageDisplayed:!1,reference:bodyFL},FR:{damageDisplayed:!1,reference:bodyFR},ML:{damageDisplayed:!1,reference:bodyML},MR:{damageDisplayed:!1,reference:bodyMR},RL:{damageDisplayed:!1,reference:bodyRL},RR:{damageDisplayed:!1,reference:bodyRR}},engine:{oilStarvation:{damageDisplayed:!1,reference:engine},coolantHot:{damageDisplayed:!1,reference:engine},oilHot:{damageDisplayed:!1,reference:engine},pistonRingsDamaged:{damageDisplayed:!1,reference:engine},rodBearingsDamaged:{damageDisplayed:!1,reference:engine},headGasketDamaged:{damageDisplayed:!1,reference:engine},turbochargerHot:{damageDisplayed:!1,reference:engine},engineIsHydrolocking:{damageDisplayed:!1,reference:engine},engineReducedTorque:{damageDisplayed:!1,reference:engine},mildOverrevDamage:{damageDisplayed:!1,reference:engine},overRevDanger:{damageDisplayed:!1,reference:engine},overTorqueDanger:{damageDisplayed:!1,reference:engine},engineHydrolocked:{damageDisplayed:!1,reference:engine},engineDisabled:{damageDisplayed:!1,reference:engine},blockMelted:{damageDisplayed:!1,reference:engine},engineLockedUp:{damageDisplayed:!1,reference:engine},radiatorLeak:{damageDisplayed:!1,reference:radiator}},powertrain:{wheelaxleFL:{damageDisplayed:!1,reference:wheelaxleFL},wheelaxleFR:{damageDisplayed:!1,reference:wheelaxleFR},wheelaxleRL:{damageDisplayed:!1,reference:wheelaxleRL},wheelaxleRR:{damageDisplayed:!1,reference:wheelaxleRR},driveshaft:{damageDisplayed:!1,reference:driveShaft},driveshaft_F:{damageDisplayed:!1,reference:driveShaft},mainEngine:{damageDisplayed:!1,reference:engine}},energyStorage:{mainTank:{damageDisplayed:!1,reference:fueltank}},wheels:{tireFL:{damageDisplayed:!1,reference:tireFL},tireFR:{damageDisplayed:!1,reference:tireFR},tireRL:{damageDisplayed:!1,reference:tireRL},tireRR:{damageDisplayed:!1,reference:tireRR},brakeFL:{damageDisplayed:!1,reference:brakeFL},brakeFR:{damageDisplayed:!1,reference:brakeFR},brakeRL:{damageDisplayed:!1,reference:brakeRL},brakeRR:{damageDisplayed:!1,reference:brakeRR},brakeOverHeatFL:{damageDisplayed:!1,reference:brakeFL},brakeOverHeatFR:{damageDisplayed:!1,reference:brakeFR},brakeOverHeatRL:{damageDisplayed:!1,reference:brakeRL},brakeOverHeatRR:{damageDisplayed:!1,reference:brakeRR},FL:{damageDisplayed:!1,reference:tireFL},FR:{damageDisplayed:!1,reference:tireFR},RL:{damageDisplayed:!1,reference:tireRL},RR:{damageDisplayed:!1,reference:tireRR}}}),damageTimeout=ref(null),animTimeout=ref(null);onMounted(()=>{$game.events.on(`DamageData`,onDamageData),$game.events.on(`VehicleReset`,onReset),$game.events.on(`VehicleChange`,onReset),$game.events.on(`VehicleFocusChanged`,onVehicleFocusChanged),$game.streams.add(streamsList)}),onUnmounted(()=>{$game.events.off(`DamageData`,onDamageData),$game.events.off(`VehicleReset`,onReset),$game.events.off(`VehicleChange`,onReset),$game.events.off(`VehicleFocusChanged`,onVehicleFocusChanged),$game.streams.remove(streamsList)});function onDamageData(data){for(let type in data)for(let component in data[type]){if(componentDamageMap[type]===void 0||componentDamageMap[type][component]===void 0)continue;let damagedComponent=componentDamage.value[type][component],damageComponentProps=componentDamageMap[type][component];if(!damagedComponent.damageDisplayed&&(data[type][component]===!0||data[type][component]>0)){if(damageComponentProps.priority===1)appState.permanentDamagedParts+=1,clearTimeout(damageTimeout.value),setComponentDamageStyles(damagedComponent.reference,redColor,`flashAnim`);else if(damageComponentProps.priority===0)appState.permanentDamagedParts+=1,clearTimeout(damageTimeout.value),setComponentDamageStyles(damagedComponent.reference,orangeColor,`flashAnim`);else if(damageComponentProps.priority===2){let damageAmount=Math.round(data[type][component]*1e3),bodyColor=`rgba(${150+damageAmount}, ${150-damageAmount}, 0, 0.6)`;setComponentDamageStyles(damagedComponent.reference,bodyColor,``)}appState.hasDamage=!0,damageComponentProps.damageText!==void 0&&(damageTextQueue.value.push(damageComponentProps.damageText),damagedComponent.damageDisplayed=!0)}else damageComponentProps.tempDamage&&(data[type][component]===!0||data[type][component]>0?setComponentDamageStyles(damagedComponent.reference,orangeColor,`flashAnim`):(damagedComponent.damageDisplayed=!1,appState.permanentDamagedParts=-1,setComponentDamageStyles(damagedComponent.reference,noDataColor,``)))}!appState.isAppDisplayed&&appState.hasDamage&&(appState.isAppDisplayed=!0,processDamageText(),appState.permanentDamagedParts===0?showAppTimed():clearTimeout(damageTimeout.value))}function processDamageText(){damageTextQueue.value&&damageTextQueue.value.length>0?(damageContainer.value.style.opacity=1,damageText.value.textContent=damageTextQueue.value[0],damageTextQueue.value.splice(0,1),animTimeout.value=setTimeout(processDamageText,textDisplayTime)):(damageContainer.value.style.opacity=0,damageText.value.textContent=``,clearTimeout(animTimeout.value))}function onReset(){for(let type in componentDamage.value)for(let component in componentDamage.value[type])componentDamage.value[type][component].reference.style.fill=noDataColor;appState.isAppDisplayed=!1,appState.hasDamage=!1,appState.permanentDamagedParts=0,damageTextQueue.value=[],showAppTimed()}function onVehicleFocusChanged(data){data.mode===!0&&onReset()}function showAppTimed(){damageTimeout.value&&clearTimeout(damageTimeout.value),appState.isAppDisplayed=!0,damageTimeout.value=setTimeout(function(){appState.isAppDisplayed=!1},2700)}function setComponentDamageStyles(componentRef,color,anim){componentRef.style.fill=color,anim===``?componentRef.classList=[]:componentRef.classList.add(anim)}return(_ctx,_cache)=>(openBlock(),createElementBlock(`svg`,{ref_key:`svg`,ref:svg,class:`svg-app`,viewBox:`-20 -50 300 527`,style:normalizeStyle({opacity:appState.isAppDisplayed?1:0})},[createBaseVNode(`g`,_hoisted_1$188,[createBaseVNode(`path`,{ref_key:`tireFL`,ref:tireFL,d:`m 40.219516,385.93366 0.0893,-35.49107 c 0,0 0.44642,-5.22322 5.08928,-5.22322 4.64286,0 22.41072,-0.13394 22.41072,-0.13394 0,0 5.44643,-10e-6 5.49107,5.22321 0.0534,6.25041 -0.0447,34.64286 -0.0447,34.64286 l 0.0893,36.25 c 0,0 -0.0446,5.35714 -5.53571,5.44643 -3.12586,0.0508 -21.47322,-10e-6 -21.47322,-10e-6 0,0 -5.98214,10e-6 -6.02678,-5.3125 -0.0375,-4.46412 -0.0893,-35.40178 -0.0893,-35.40178 z`,style:{fill:`none`,"fill-rule":`evenodd`,stroke:`#000000`,"stroke-width":`1px`,"stroke-linecap":`butt`,"stroke-linejoin":`miter`,"stroke-opacity":`1`}},null,512),createBaseVNode(`path`,{style:{fill:`none`,"fill-rule":`evenodd`,stroke:`#000000`,"stroke-width":`1px`,"stroke-linecap":`butt`,"stroke-linejoin":`miter`,"stroke-opacity":`1`},d:`m 212.19799,385.43366 0.0893,-35.49107 c 0,0 0.44642,-5.22322 5.08928,-5.22322 4.64286,0 22.41072,-0.13394 22.41072,-0.13394 0,0 5.44643,-10e-6 5.49107,5.22321 0.0534,6.25041 -0.0447,34.64286 -0.0447,34.64286 l 0.0893,36.25 c 0,0 -0.0446,5.35714 -5.53571,5.44643 -3.12586,0.0508 -21.47322,-10e-6 -21.47322,-10e-6 0,0 -5.98214,10e-6 -6.02678,-5.3125 -0.0375,-4.46412 -0.0893,-35.40178 -0.0893,-35.40178 z`,ref_key:`tireFR`,ref:tireFR},null,512),createBaseVNode(`path`,{ref_key:`tireRR`,ref:tireRR,d:`m 212.19799,654.14795 0.0893,-35.49107 c 0,0 0.44642,-5.22322 5.08928,-5.22322 4.64286,0 22.41072,-0.13394 22.41072,-0.13394 0,0 5.44643,-10e-6 5.49107,5.22321 0.0534,6.25041 -0.0447,34.64286 -0.0447,34.64286 l 0.0893,36.25 c 0,0 -0.0446,5.35714 -5.53571,5.44643 -3.12586,0.0508 -21.47322,-10e-6 -21.47322,-10e-6 0,0 -5.98214,10e-6 -6.02678,-5.3125 -0.0375,-4.46412 -0.0893,-35.40178 -0.0893,-35.40178 z`,style:{fill:`none`,"fill-rule":`evenodd`,stroke:`#000000`,"stroke-width":`1px`,"stroke-linecap":`butt`,"stroke-linejoin":`miter`,"stroke-opacity":`1`}},null,512),createBaseVNode(`path`,{style:{fill:`none`,"fill-rule":`evenodd`,stroke:`#000000`,"stroke-width":`1px`,"stroke-linecap":`butt`,"stroke-linejoin":`miter`,"stroke-opacity":`1`},d:`m 40.219516,654.14795 0.0893,-35.49107 c 0,0 0.44642,-5.22322 5.08928,-5.22322 4.64286,0 22.41072,-0.13394 22.41072,-0.13394 0,0 5.44643,-10e-6 5.49107,5.22321 0.0534,6.25041 -0.0447,34.64286 -0.0447,34.64286 l 0.0893,36.25 c 0,0 -0.0446,5.35714 -5.53571,5.44643 -3.12586,0.0508 -21.47322,-10e-6 -21.47322,-10e-6 0,0 -5.98214,10e-6 -6.02678,-5.3125 -0.0375,-4.46412 -0.0893,-35.40178 -0.0893,-35.40178 z`,ref_key:`tireRL`,ref:tireRL},null,512),createBaseVNode(`path`,{ref_key:`bodyFL`,ref:bodyFL,d:`m 139.30351,268.73244 c 0,0 -20.06962,-0.0115 -32.7295,1.35397 -11.849388,1.27802 -23.33457,5.11217 -35.698872,11.89174 -11.963689,6.55991 -22.259598,16.59274 -27.506842,31.58729 -3.060137,8.74465 -3.902495,25.39725 -3.902495,25.39725 l 9.609942,-0.14814 c 0,0 1.636978,-16.52695 5.208997,-24.93149 3.978738,-9.3615 11.635356,-19.52025 21.213285,-24.53523 10.627835,-5.56471 18.689453,-8.01564 32.759185,-10.2291 11.61143,-1.82671 31.13813,-1.14019 31.13813,-1.14019 z`,style:{fill:`none`,"fill-rule":`evenodd`,stroke:`#000000`,"stroke-width":`1px`,"stroke-linecap":`butt`,"stroke-linejoin":`miter`,"stroke-opacity":`1`}},null,512),createBaseVNode(`path`,{ref_key:`bodyML`,ref:bodyML,d:`m 46.365238,434.85859 c 0,0 -4.37766,0.0905 -6.56641,0.125 -0.0234,2.215 -0.08,17.90873 -0.125,26.86328 0,0 -20.45068,7.80958 -22.22461,10.85938 -1.79329,3.0831 -4.63644,8.09161 -2.46289,8.46094 0,0 25.14091,-3.55661 25.60352,-3.40821 0.0618,2.25563 -0.62153,126.52252 -0.59375,127.77539 1.21285,-0.002 9.6289,0.0312 9.6289,0.0312 l -0.01,-170.70703 z`,style:{fill:`none`,"fill-rule":`evenodd`,stroke:`#000000`,"stroke-width":`1px`,"stroke-linecap":`butt`,"stroke-linejoin":`miter`,"stroke-opacity":`1`}},null,512),createBaseVNode(`path`,{ref_key:`bodyMR`,ref:bodyMR,d:`m 236.6054,434.90159 -0.0117,170.70899 c 0,0 7.91605,-0.0352 9.1289,-0.0332 0.0278,-1.25287 -0.65555,-125.51976 -0.59375,-127.77539 0.46261,-0.1484 25.60352,3.40821 25.60352,3.40821 2.17355,-0.36933 -0.6696,-5.37589 -2.46289,-8.45899 -1.77393,-3.0498 -22.22266,-10.85937 -22.22266,-10.85937 -0.045,-8.95456 -0.10355,-24.64828 -0.12695,-26.86328 -2.18875,-0.0345 -9.31447,-0.12697 -9.31447,-0.12697 z`,style:{fill:`none`,"fill-rule":`evenodd`,stroke:`#000000`,"stroke-width":`1px`,"stroke-linecap":`butt`,"stroke-linejoin":`miter`,"stroke-opacity":`1`}},null,512),createBaseVNode(`path`,{ref_key:`driveShaft`,ref:driveShaft,d:`m 146.88019,519.13977 0.34682,-126.1992 c 0,0 14.81582,-18.06715 -4.26439,-17.94569 -19.92,0.12681 -4.95719,17.95354 -4.95719,17.95354 l 0.0408,126.25385 c -0.48292,33.8145 0.52349,126.53492 0.52349,126.53492 -3.70809,6.93305 -6.96405,16.59296 4.6368,16.4848 11.45601,-0.10682 8.66714,-8.10662 4.65438,-16.55312 -1.97544,-4.15814 -0.98066,-126.5291 -0.98066,-126.5291 z`,style:{fill:`none`,"fill-rule":`evenodd`,stroke:`#000000`,"stroke-width":`0.99999976`,"stroke-linecap":`butt`,"stroke-linejoin":`miter`,"stroke-miterlimit":`4`,"stroke-dasharray":`none`,"stroke-opacity":`1`}},null,512),createBaseVNode(`path`,{ref_key:`engine`,ref:engine,d:`m 122.07373,314.95322 h 33.63152 v 5.9272 h -13.25677 v 5.34505 h 12.93926 l 6.08594,9.31416 h 5.37155 v 4.97461 h 6.00656 v -5.05399 h 8.22927 c 0,0 2.66605,2.98563 3.2282,4.8423 1.71505,5.66443 1.56492,12.04739 0,17.75512 -0.61276,2.23494 -3.54572,5.98011 -3.54572,5.98011 h -7.93821 v -5.39797 h -6.29763 v 11.32517 h -34.98103 l -6.50934,-7.93822 H 113.0771 v -16.51145 h -5.98011 v 15.87643 h -5.1863 v -28.89508 h 4.97462 v 7.62066 h 6.29764 v -7.72651 h 8.99664 v -5.98013 h 14.12999 v -6.19179 h -14.23585 z`,style:{display:`inline`,fill:`none`,"fill-rule":`evenodd`,stroke:`#000000`,"stroke-width":`1.00000012`,"stroke-linecap":`butt`,"stroke-linejoin":`miter`,"stroke-miterlimit":`4`,"stroke-dasharray":`none`,"stroke-opacity":`1`}},null,512),createBaseVNode(`path`,{d:`m 117.17264,721.33809 -7.7414,-9.05075 c 0,0 -1.6874,1.50785 -2.481,2.29715 -0.685,0.6814 -1.3051,1.5911 0.2757,3.6525 0.5444,0.7098 3.2227,3.9338 3.7903,4.5024 1.6325,1.6355 2.5754,1.6201 3.3309,1.0108 0.9517,-0.7675 2.8255,-2.4121 2.8255,-2.4121 z m -5.4902,-9.02777 c -0.2639,-0.33031 -0.3782,-0.42184 0.023,-0.78103 0.2875,-0.31046 1.9506,-1.87788 2.2512,-2.13637 0.2218,-0.19078 0.3561,-0.42492 0.1149,-0.7236 -0.2412,-0.33308 -2.1908,-2.68012 -2.4982,-3.06097 -0.2198,-0.27232 -0.2732,-0.32108 -0.2732,-0.50554 0,-0.75917 0.011,-34.43177 0.015,-35.00437 0,-0.2149 0.056,-0.3086 0.5162,-0.3086 h 51.67845 c 2.0683,0 3.0251,0.3486 4.3679,1.4435 1.1871,0.9678 2.1659,2.0917 2.17,4.6095 0,0 0.065,37.07605 0.065,38.41705 0,1.2398 -0.1967,4.1364 -1.6325,5.5294 -1.0614,1.0299 -3.8532,1.8924 -4.9438,1.8924 -1.5414,0 -37.80368,-0.016 -38.25553,-0.016 -0.32906,0 -0.70707,-0.079 -0.93514,-0.3163 -0.27185,-0.2826 -2.9151,-3.0777 -3.22317,-3.371 -0.15862,-0.151 -0.25989,-0.4548 -0.64972,-0.097 -0.3899,0.3574 -1.73649,1.4573 -2.04669,1.7218 -0.1403,0.1197 -0.2841,0.2357 -0.5523,-0.032 -0.4136,-0.4769 -5.8261,-6.80285 -6.191,-7.25968 z m 20.26835,-10.96158 c -0.003,-4.55255 -0.0326,-8.19817 0,-12.74562 0,-0.7695 -0.32724,-0.97794 -1.30987,-1.85445 -0.76302,-0.68063 -1.41614,-1.23286 -1.90915,-1.69336 -0.36587,-0.34178 -0.85706,-0.80537 -0.84008,-1.1791 0.0258,-0.56967 0.59396,-1.0422 0.93428,-1.21472 0.54578,-0.27667 0.94727,-0.0528 1.23375,0.23366 0.30382,0.30381 1.84818,1.77993 2.58906,2.39496 0.44759,0.37156 0.58562,0.67733 1.67741,0.67733 5.46749,-0.0217 12.23023,-0.18415 18.32732,0 1.09189,0 1.22992,-0.30577 1.67737,-0.67733 0.74089,-0.61503 2.28521,-2.09115 2.58911,-2.39496 0.2865,-0.28643 0.688,-0.51033 1.2338,-0.23366 0.3404,0.17252 0.9085,0.64505 0.9344,1.21472 0.017,0.37373 -0.4743,0.83732 -0.8402,1.1791 -0.493,0.4605 -1.1461,1.01273 -1.909,1.69336 -0.98279,0.87651 -1.30997,1.08495 -1.30997,1.85445 0,4.55255 0.0323,8.19817 0,12.74562 0,0.76951 0.32718,0.97793 1.30997,1.85447 0.7629,0.68062 1.416,1.23285 1.909,1.69335 0.3659,0.34177 0.857,0.80537 0.8402,1.1791 -0.026,0.56967 -0.594,1.04219 -0.9344,1.21472 -0.5458,0.27667 -0.9473,0.0528 -1.2338,-0.23366 -0.3039,-0.30382 -1.84822,-1.77992 -2.58911,-2.39497 -0.44745,-0.37154 -0.58548,-0.67731 -1.67737,-0.67731 -6.55155,0.019 -11.82218,0.18501 -18.32732,0 -1.09179,0 -1.22982,0.30577 -1.67741,0.67731 -0.74088,0.61505 -2.28524,2.09115 -2.58906,2.39497 -0.28648,0.28644 -0.68797,0.51033 -1.23375,0.23366 -0.34032,-0.17253 -0.90842,-0.64505 -0.93428,-1.21472 -0.017,-0.37373 0.47421,-0.83733 0.84008,-1.1791 0.49301,-0.4605 1.14613,-1.01273 1.90915,-1.69335 0.98263,-0.87654 1.30987,-1.08496 1.30987,-1.85447 z m 2.56799,-10.35082 c 0,2.40538 0,5.36454 0,8.01339 0,0.63296 -0.0236,1.4238 0.45482,1.90048 0.45132,0.44967 1.08277,0.42233 1.81926,0.42233 h 13.2426 c 0.7365,0 1.36798,0.0273 1.81926,-0.42233 0.47837,-0.47668 0.45477,-1.26752 0.45477,-1.90048 v -3.94714 c 0,-1.35542 0,-2.71084 0,-4.06625 0,-0.63296 0.0233,-1.42381 -0.45477,-1.90047 -0.45128,-0.44969 -1.08276,-0.42234 -1.81926,-0.42234 h -13.2426 c -0.73649,0 -1.36794,-0.0273 -1.81926,0.42234 -0.47842,0.47666 -0.45482,1.26751 -0.45482,1.90047 z`,style:{fill:`none`,"fill-opacity":`1`,"fill-rule":`evenodd`,stroke:`#000000`,"stroke-width":`1.00000012`,"stroke-linecap":`butt`,"stroke-linejoin":`miter`,"stroke-miterlimit":`4`,"stroke-dasharray":`none`,"stroke-opacity":`1`},ref_key:`fueltank`,ref:fueltank},null,512),createBaseVNode(`path`,{d:`m 162.19586,303.74311 v 1.62868 c 0,0 -0.0239,0.60243 0.40384,0.86252 0.36641,0.22282 3.17759,0.31545 3.59707,-0.042 0.34847,-0.29691 0.34658,-0.78069 0.34658,-0.78069 v -4.32093 c 0,0 -0.004,-0.63642 -0.53018,-0.91858 -0.27049,-0.14492 -2.81926,2.15048 -3.22871,2.49847 -0.49791,0.42318 -0.5886,0.94557 -0.5886,0.94557 z m -8.74296,-2.37979 v 4.00847 c 0,0 -0.0239,0.60243 0.40383,0.86252 0.36641,0.22282 3.17759,0.31545 3.59708,-0.042 0.34846,-0.29691 0.34657,-0.78069 0.34657,-0.78069 v -3.43014 c 0,0 -0.004,-0.63642 -0.53018,-0.91857 -0.27049,-0.14493 -2.94617,-0.75348 -3.2287,-0.64521 -0.61019,0.23381 -0.5886,0.94557 -0.5886,0.94557 z m -8.57375,1.15667 v 2.8518 c 0,0 -0.0239,0.60243 0.40383,0.86252 0.36641,0.22282 3.17759,0.31545 3.59708,-0.042 0.34846,-0.29691 0.34657,-0.78069 0.34657,-0.78069 v -3.78911 c 0,0 -0.002,-0.37799 -0.24416,-0.68051 -0.072,-0.09 -0.16527,-0.17335 -0.28602,-0.23806 -0.27049,-0.14492 -2.94617,0.76217 -3.2287,0.87043 -0.61019,0.23381 -0.5886,0.94557 -0.5886,0.94557 z m -8.63016,2.23357 v 0.61823 c 0,0 -0.0239,0.60243 0.40383,0.86252 0.36642,0.22282 3.17759,0.31545 3.59707,-0.042 0.34847,-0.29691 0.34658,-0.78069 0.34658,-0.78069 v -1.35611 c 0,0 -0.004,-0.63641 -0.53017,-0.91857 -0.2705,-0.14492 -2.94617,0.56274 -3.22871,0.671 -0.61019,0.23381 -0.5886,0.94557 -0.5886,0.94557 z m -8.50835,1.48075 c 0.36641,0.22282 3.17758,0.31545 3.59707,-0.042 0.34847,-0.29691 0.34658,-0.50066 0.34658,-0.50066 0,0 -0.004,-1.03528 -0.53018,-1.31744 -0.27049,-0.14492 -2.94617,-0.0851 -3.22871,0.0232 -0.61018,0.23381 -0.5886,1.10014 -0.5886,1.10014 0,0 -0.0239,0.47668 0.40384,0.73676 z m -9.0904,-2.1588 v 1.29628 c 0,0 -0.0239,0.60243 0.40383,0.86252 0.36642,0.22282 3.17759,0.31545 3.59707,-0.042 0.34847,-0.29691 0.34658,-0.78069 0.34658,-0.78069 v -0.5584 c 0,0 -0.004,-0.63642 -0.53017,-0.91858 -0.2705,-0.14492 -2.94617,-0.91301 -3.22871,-0.80474 -0.61019,0.23381 -0.5886,0.94556 -0.5886,0.94556 z m 52.345,1.37742 v -16.61221 c 0,0 -0.0239,-0.60242 0.40383,-0.86252 0.36642,-0.22281 3.17759,-0.31544 3.59707,0.042 0.34847,0.29692 0.34658,0.78069 0.34658,0.78069 v 16.63216 c 0,0 -0.004,0.63642 -0.53017,0.91857 -0.2705,0.14493 -2.94617,0.1552 -3.22871,0.0469 -0.61019,-0.23381 -0.5886,-0.94556 -0.5886,-0.94556 z m -8.79938,-16.61221 c 0,0 -0.0239,-0.60242 0.40384,-0.86252 0.36641,-0.22281 3.17759,-0.31544 3.59707,0.042 0.34847,0.29692 0.34658,0.78069 0.34658,0.78069 v 3.32029 c 0,0 -0.004,0.63641 -0.53018,0.91857 -0.27049,0.14492 -2.60773,-2.10106 -3.22871,-2.63237 -0.4965,-0.42482 -0.5886,-0.97378 -0.5886,-0.97378 z m -8.74296,0 c 0,0 -0.0239,-0.60242 0.40383,-0.86252 0.36641,-0.22281 3.17759,-0.31544 3.59708,0.042 0.34846,0.29692 0.34657,0.78069 0.34657,0.78069 v 1.74529 c 0,0 -0.004,0.63642 -0.53018,0.91857 -0.27049,0.14493 -2.94617,-0.12683 -3.2287,-0.2351 -0.61019,-0.23381 -0.5886,-0.77636 -0.5886,-0.77636 z m -8.57375,0 c 0,0 -0.0239,-0.60242 0.40383,-0.86252 0.36641,-0.22281 3.17759,-0.31544 3.59708,0.042 0.34846,0.29692 0.34657,0.78069 0.34657,0.78069 v 1.80688 c 0,0 -0.002,0.378 -0.24416,0.68052 -0.072,0.09 -0.16527,0.17335 -0.28602,0.23805 -0.27049,0.14493 -2.94617,1.1141 -3.2287,1.00584 -0.61019,-0.23381 -0.5886,-0.81866 -0.5886,-0.81866 z m -8.63016,0 c 0,0 -0.0239,-0.60242 0.40383,-0.86252 0.36642,-0.22281 3.17759,-0.31544 3.59707,0.042 0.34847,0.29692 0.34658,0.78069 0.34658,0.78069 v 4.46516 c 0,0 -0.004,0.63641 -0.53017,0.91857 -0.2705,0.14493 -2.94617,0.97309 -3.22871,0.86482 -0.61019,-0.23381 -0.6027,-0.81866 -0.6027,-0.81866 z m -8.91219,0 c 0,0 -0.0239,-0.60242 0.40384,-0.86252 0.36641,-0.22281 3.17758,-0.31544 3.59707,0.042 0.34847,0.29692 0.34658,0.78069 0.34658,0.78069 v 6.04004 c 0,0 -0.004,0.63641 -0.53018,0.91857 -0.27049,0.14493 -2.94617,-0.0986 -3.22871,-0.2069 -0.61018,-0.23381 -0.5886,-0.90327 -0.5886,-0.90327 z m -8.68656,4.20791 v -4.20791 c 0,0 -0.0239,-0.60242 0.40383,-0.86252 0.36642,-0.22281 3.17759,-0.31544 3.59707,0.042 0.34847,0.29692 0.34658,0.78069 0.34658,0.78069 v 4.90473 c 0,0 -0.004,0.63641 -0.53017,0.91857 -0.2705,0.14492 -2.94617,-0.52168 -3.22871,-0.62994 -0.61019,-0.23382 -0.5886,-0.94557 -0.5886,-0.94557 z m 0.0383,3.38266 0.0424,3.80682 c 4.76147,1.58463 12.44208,1.37115 18.62715,0.76876 4.9084,-0.47805 9.46499,-3.13968 14.38678,-3.45098 2.56844,-0.16246 7.67481,0.84058 7.67481,0.84058 l 0.018,4.52569 c 0,0 4.30181,-3.85868 6.85434,-6.08209 0.23182,-0.21672 0.26026,-0.28202 -0.0588,-0.61036 -2.4793,-2.37833 -6.8878,-6.08125 -6.8878,-6.08125 l 0.0141,4.90206 c 0,0 -5.19129,-1.89571 -12.24908,-0.16859 -3.96245,1.32729 -6.76872,2.21825 -10.27188,2.769 -2.7191,0.42749 -5.4997,0.55723 -8.24775,0.4009 -3.33921,-0.18995 -6.69491,-0.50286 -9.90211,-1.62054 z m -15.25121,10.1713 c 0,0.39543 -0.18036,1.62226 1.45209,3.25472 1.40638,1.19302 2.9727,1.1712 3.41028,1.1712 23.19944,0.0992 44.97243,0.0226 68.7019,0 0.43758,0 2.0039,0.0218 3.41029,-1.1712 1.63245,-1.63246 1.45208,-2.85929 1.45208,-3.25472 0.12422,-16.06162 0.0264,-3.05893 0,-19.25937 0,-0.39543 0.18037,-1.62225 -1.45208,-3.25471 -1.40639,-1.19302 -2.97271,-1.1712 -3.41029,-1.1712 -23.19944,-0.0992 -44.97243,-0.0226 -68.7019,0 -0.43758,0 -2.0039,-0.0218 -3.41028,1.1712 -1.63245,1.63246 -1.45209,2.85928 -1.45209,3.25471 -0.11802,17.21566 -0.0338,3.97954 0,19.25937 z m 1.90997,-17.51991 c 0,-0.36657 -0.12323,-2.09175 1.14118,-3.35617 1.05214,-0.89259 3.06543,-0.74668 3.48144,-0.74668 22.55947,-0.021 43.30609,-0.0919 65.36168,0 1.3185,0 2.52269,-0.19776 3.66518,0.74727 1.05732,1.05732 0.95743,2.19932 0.95743,3.35558 0.0252,15.01782 0.11812,0.8913 0,15.78046 0,1.5229 -0.0428,2.46913 -0.90102,3.32738 -1.06456,0.88061 -2.31847,0.77547 -3.72159,0.77547 -22.55947,0.021 -43.30609,0.0919 -65.36168,0 -1.7721,0 -2.45712,0.11664 -3.44156,-0.68686 -1.36393,-1.36393 -1.18106,-1.95258 -1.18106,-3.41599 0.12429,-15.20955 -0.092,-2.68107 0,-15.78046 z m 4.56001,16.37025 v -16.61221 c 0,0 -0.0239,-0.60242 0.40383,-0.86252 0.36641,-0.22281 3.1776,-0.31544 3.59708,0.042 0.34846,0.29692 0.34658,0.78069 0.34658,0.78069 v 16.63216 c 0,0 -0.004,0.63642 -0.53019,0.91857 -0.27048,0.14493 -2.94617,0.1552 -3.2287,0.0469 -0.61019,-0.23381 -0.5886,-0.94556 -0.5886,-0.94556 z`,style:{display:`inline`,fill:`none`,"fill-opacity":`1`,"fill-rule":`evenodd`,stroke:`#000000`,"stroke-width":`0.75000012`,"stroke-linecap":`butt`,"stroke-linejoin":`miter`,"stroke-miterlimit":`4`,"stroke-dasharray":`none`,"stroke-opacity":`1`},ref_key:`radiator`,ref:radiator},null,512),createBaseVNode(`path`,{ref_key:`wheelaxleFL`,ref:wheelaxleFL,d:`m 91.691145,389.0121 c 0,0 -2.43068,0.29676 -2.43068,-4.28053 0,-4.0406 2.22866,-4.30576 2.22866,-4.30576 9.222155,-0.11908 21.694875,-0.0585 30.917405,-0.0594 3.70837,-9.1e-4 6.85841,-0.28274 8.24298,0.90893 0.51207,0.44072 0.75871,1.92799 1.01166,3.17533 0.35371,1.74427 0.74974,2.96105 0.32477,3.71154 -0.50969,0.90009 -2.57006,0.96141 -2.57006,0.96141 -11.49186,0.003 -26.23329,-0.0229 -37.724735,-0.11152 z`,style:{display:`inline`,opacity:`1`,fill:`none`,"fill-rule":`evenodd`,stroke:`#000000`,"stroke-width":`1px`,"stroke-linecap":`butt`,"stroke-linejoin":`miter`,"stroke-opacity":`1`}},null,512),createBaseVNode(`path`,{style:{display:`inline`,opacity:`1`,fill:`none`,"fill-rule":`evenodd`,stroke:`#000000`,"stroke-width":`1px`,"stroke-linecap":`butt`,"stroke-linejoin":`miter`,"stroke-opacity":`1`},d:`m 193.49174,389.0121 c 0,0 2.43068,0.29676 2.43068,-4.28053 0,-4.0406 -2.22865,-4.30576 -2.22865,-4.30576 -9.22216,-0.11908 -21.44488,-0.0585 -30.66742,-0.0594 -3.70837,-9.1e-4 -6.85841,-0.28274 -8.24298,0.90893 -0.51207,0.44072 -0.75871,1.92799 -1.01166,3.17533 -0.35371,1.74427 -0.74974,2.96105 -0.32477,3.71154 0.50969,0.90009 2.57006,0.96141 2.57006,0.96141 11.49186,0.003 25.98329,-0.0229 37.47474,-0.11152 z`,ref_key:`wheelaxleFR`,ref:wheelaxleFR},null,512),createBaseVNode(`path`,{ref_key:`brakeFR`,ref:brakeFR,d:`m 210.35279,373.43366 h -5.22322 l -0.0446,-11.25 c 0,0 -0.0446,-1.02679 -1.51786,-1.16071 -0.91518,-0.15626 -3.83928,-0.067 -3.83928,-0.067 0,0 -2.04238,-0.11866 -2.0759,1.22768 -0.0626,2.51339 -0.0446,47.43304 -0.0446,47.43304 0,0 -0.0431,1.36663 1.7634,1.40625 1.21935,0.0262 3.83928,0.005 3.83928,0.005 0,0 1.86958,0.12132 1.96428,-1.61256 0.073,-1.33729 -0.0207,-10.46221 -0.0207,-10.46221 l 5.24395,-0.12581 z`,style:{display:`inline`,opacity:`1`,fill:`none`,"fill-opacity":`1`,"fill-rule":`evenodd`,stroke:`#000000`,"stroke-width":`1px`,"stroke-linecap":`butt`,"stroke-linejoin":`miter`,"stroke-opacity":`1`}},null,512),createBaseVNode(`path`,{ref_key:`brakeFL`,ref:brakeFL,d:`m 74.826658,373.43366 h 5.22322 l 0.0446,-11.25 c 0,0 0.0446,-1.02679 1.51786,-1.16071 0.91518,-0.15626 3.83928,-0.067 3.83928,-0.067 0,0 2.04238,-0.11866 2.0759,1.22768 0.0626,2.51339 0.0446,47.43304 0.0446,47.43304 0,0 0.0431,1.36663 -1.7634,1.40625 -1.21935,0.0262 -3.83928,0.005 -3.83928,0.005 0,0 -1.86958,0.12132 -1.96428,-1.61256 -0.073,-1.33729 0.0207,-10.46221 0.0207,-10.46221 l -5.24395,-0.12581 z`,style:{display:`inline`,opacity:`1`,fill:`none`,"fill-opacity":`1`,"fill-rule":`evenodd`,stroke:`#000000`,"stroke-width":`1px`,"stroke-linecap":`butt`,"stroke-linejoin":`miter`,"stroke-opacity":`1`}},null,512),createBaseVNode(`path`,{style:{fill:`none`,"fill-rule":`evenodd`,stroke:`#000000`,"stroke-width":`1px`,"stroke-linecap":`butt`,"stroke-linejoin":`miter`,"stroke-opacity":`1`},d:`m 145.98404,268.73244 c 0,0 19.06962,-0.0115 31.7295,1.35397 11.84939,1.27802 23.33457,5.11217 35.69887,11.89174 11.96369,6.55991 22.2596,16.59274 27.50684,31.58729 3.06014,8.74465 3.9025,25.39725 3.9025,25.39725 l -9.60995,-0.14814 c 0,0 -1.63697,-16.52695 -5.20899,-24.93149 -3.97874,-9.3615 -11.63536,-19.52025 -21.21329,-24.53523 -10.62783,-5.56471 -18.68945,-8.01564 -32.75918,-10.2291 -11.61143,-1.82671 -30.13813,-1.14019 -30.13813,-1.14019 z`,ref_key:`bodyFR`,ref:bodyFR},null,512),createBaseVNode(`path`,{style:{fill:`none`,"fill-rule":`evenodd`,stroke:`#000000`,"stroke-width":`1.00000012`,"stroke-linecap":`butt`,"stroke-linejoin":`miter`,"stroke-miterlimit":`4`,"stroke-dasharray":`none`,"stroke-opacity":`1`},d:`m 139.36946,758.05809 c 0,0 -20.14699,0.01 -32.81319,-1.1024 -11.855294,-1.0405 -23.346203,-4.162 -35.716671,-9.6818 -11.969654,-5.3407 -20.679708,-11.5646 -25.929569,-23.7724 -3.061663,-7.1197 -5.495432,-24.34913 -5.495432,-24.34913 l 9.614735,0.12066 c 0,0 1.637794,15.18257 5.211595,22.02527 3.980722,7.6218 11.817934,15.0086 21.40064,19.0916 10.633134,4.5306 18.345219,5.9957 32.421962,7.798 11.61723,1.487 31.39781,0.9282 31.39781,0.9282 z`,ref_key:`bodyRL`,ref:bodyRL},null,512),createBaseVNode(`path`,{ref_key:`bodyRR`,ref:bodyRR,d:`m 145.99795,758.05809 c 0,0 19.59077,0.01 32.25697,-1.1024 11.8553,-1.0405 23.34621,-4.162 35.71668,-9.6818 11.96965,-5.3407 20.67971,-11.5646 25.92957,-23.7724 3.06166,-7.1197 5.49543,-24.34913 5.49543,-24.34913 l -9.61473,0.12066 c 0,0 -1.6378,15.18257 -5.2116,22.02527 -3.98072,7.6218 -11.81793,15.0086 -21.40064,19.0916 -10.63314,4.5306 -18.34522,5.9957 -32.42197,7.798 -11.61723,1.487 -30.84159,0.9282 -30.84159,0.9282 z`,style:{fill:`none`,"fill-rule":`evenodd`,stroke:`#000000`,"stroke-width":`1.00000012`,"stroke-linecap":`butt`,"stroke-linejoin":`miter`,"stroke-miterlimit":`4`,"stroke-dasharray":`none`,"stroke-opacity":`1`}},null,512),createBaseVNode(`path`,{style:{display:`inline`,opacity:`1`,fill:`none`,"fill-rule":`evenodd`,stroke:`#000000`,"stroke-width":`1.00000012`,"stroke-linecap":`butt`,"stroke-linejoin":`miter`,"stroke-miterlimit":`4`,"stroke-dasharray":`none`,"stroke-opacity":`1`},d:`m 75.326658,641.12409 h 5.22322 l 0.0446,-11.25 c 0,0 0.0446,-1.02679 1.51786,-1.16071 0.91518,-0.15626 3.83928,-0.067 3.83928,-0.067 0,0 2.04238,-0.11866 2.0759,1.22768 0.0626,2.51339 0.0446,47.43304 0.0446,47.43304 0,0 0.0431,1.36663 -1.7634,1.40625 -1.21935,0.0262 -3.83928,0.005 -3.83928,0.005 0,0 -1.86958,0.12132 -1.96428,-1.61256 -0.073,-1.33729 0.0207,-10.46221 0.0207,-10.46221 l -5.24395,-0.12581 z`,ref_key:`brakeRL`,ref:brakeRL},null,512),createBaseVNode(`path`,{ref_key:`brakeRR`,ref:brakeRR,d:`m 209.87792,642.37917 h -5.22322 l -0.0446,-11.25 c 0,0 -0.0446,-1.02679 -1.51786,-1.16071 -0.91518,-0.15626 -3.83928,-0.067 -3.83928,-0.067 0,0 -2.04238,-0.11866 -2.0759,1.22768 -0.0626,2.51339 -0.0446,47.43304 -0.0446,47.43304 0,0 -0.0431,1.36663 1.7634,1.40625 1.21935,0.0262 3.83928,0.005 3.83928,0.005 0,0 1.86958,0.12132 1.96428,-1.61256 0.073,-1.33729 -0.0207,-10.46221 -0.0207,-10.46221 l 5.24395,-0.12581 z`,style:{display:`inline`,opacity:`1`,fill:`none`,"fill-rule":`evenodd`,stroke:`#000000`,"stroke-width":`1.00000012`,"stroke-linecap":`butt`,"stroke-linejoin":`miter`,"stroke-miterlimit":`4`,"stroke-dasharray":`none`,"stroke-opacity":`1`}},null,512),createBaseVNode(`path`,{style:{display:`inline`,opacity:`1`,fill:`none`,"fill-rule":`evenodd`,stroke:`#000000`,"stroke-width":`1.00000012`,"stroke-linecap":`butt`,"stroke-linejoin":`miter`,"stroke-miterlimit":`4`,"stroke-dasharray":`none`,"stroke-opacity":`1`},d:`m 92.206308,649.46453 c 0,0 -2.43068,-0.29676 -2.43068,4.28053 0,4.0406 2.22866,4.30576 2.22866,4.30576 9.222162,0.11908 21.444882,0.0585 30.667412,0.0594 3.70837,9.1e-4 8.80295,0.28274 10.18752,-0.90893 0.51207,-0.44072 0.6941,-2.38196 0.90117,-3.66147 0.26289,-1.62435 0.42635,-2.41047 0.26953,-3.25855 -0.21138,-1.14316 -2.40433,-0.92826 -2.40433,-0.92826 -12.14004,-6.2e-4 -27.27967,0.0179 -39.419282,0.11152 z`,ref_key:`wheelaxleRL`,ref:wheelaxleRL},null,512),createBaseVNode(`path`,{ref_key:`wheelaxleRR`,ref:wheelaxleRR,d:`m 192.84519,649.46453 c 0,0 2.43068,-0.29676 2.43068,4.28053 0,4.0406 -2.22866,4.30576 -2.22866,4.30576 -9.22216,0.11908 -20.31988,0.0585 -29.54242,0.0594 -3.70837,9.1e-4 -8.80295,0.28274 -10.18752,-0.90893 -0.51207,-0.44072 -0.6941,-2.38196 -0.90117,-3.66147 -0.26289,-1.62435 -0.42635,-2.41047 -0.26953,-3.25855 0.21138,-1.14316 2.40433,-0.92826 2.40433,-0.92826 12.14004,-6.2e-4 26.15468,0.0179 38.29429,0.11152 z`,style:{display:`inline`,opacity:`1`,fill:`none`,"fill-rule":`evenodd`,stroke:`#000000`,"stroke-width":`1.00000012`,"stroke-linecap":`butt`,"stroke-linejoin":`miter`,"stroke-miterlimit":`4`,"stroke-dasharray":`none`,"stroke-opacity":`1`}},null,512),createBaseVNode(`g`,{style:{opacity:`0`},ref_key:`damageContainer`,ref:damageContainer},[createBaseVNode(`rect`,{style:{opacity:`0.77399998`,fill:`#3e3e3e`,"stroke-width":`1.99999893`,"stroke-miterlimit":`4`,"stroke-dasharray":`none`,"stroke-dashoffset":`0`},ref_key:`damageBox`,ref:damageBox,width:`206.75557`,height:`28.991379`,x:`39.481575`,y:`234.25491`},null,512),_cache[0]||=createBaseVNode(`path`,{style:{opacity:`1`,fill:`none`,stroke:`#ffffff`,"stroke-width":`1.99999893`,"stroke-linecap":`butt`,"stroke-linejoin":`miter`,"stroke-miterlimit":`4`,"stroke-dasharray":`none`,"stroke-opacity":`1`},d:`m 39.48159,263.2463 206.75556,-2e-5`},null,-1),createBaseVNode(`text`,_hoisted_2$153,[createBaseVNode(`tspan`,{ref_key:`damageText`,ref:damageText,style:{"text-align":`center`,"text-anchor":`middle`,fill:`#ffffff`},y:`255.49614`,x:`142.73175`},` Driveshaft Broken `,512)])],512)])],4))}},app_default$9=__plugin_vue_export_helper_default(_sfc_main$210,[[`__scopeId`,`data-v-f6aa177d`]]),_hoisted_1$187={class:`timeslip`,id:`slip`},_hoisted_2$152={class:`paper`},_hoisted_3$136={class:`header`},_hoisted_4$113={class:`table-wrapper`},_hoisted_5$98={class:`custom-table`},_hoisted_6$81={class:`left-align`},_hoisted_7$69={class:`right-align`},_hoisted_8$56={class:`right-align`},_hoisted_9$50={key:0},_hoisted_10$43={class:`right-align`},_hoisted_11$38={class:`right-align`},_hoisted_12$28={class:`header`},_hoisted_13$25={class:`left`},_hoisted_14$24={class:`right`},_hoisted_15$23={class:`name`},_hoisted_16$23={key:0,class:`rewards`},_hoisted_17$18={class:`reward`},_hoisted_18$16={class:`header`},_hoisted_19$13={key:0},_sfc_main$209={__name:`Timeslip`,props:{slip:Object},setup(__props){let{units}=useBridge(),props=__props,TIMER_ROWS_INFO=[{key:`laneName`,label:`Lane`},{key:null,label:``},{key:`dial`,label:`DIAL`},{key:`reactionTime`,label:`R/T`},{key:`time_60`,label:`60'`},{key:`time_330`,label:`330'`},{key:`time_1_8`,label:`1/8`},{key:`velAt_1_8_kmh`,label:`KM/H`},{key:`velAt_1_8_mph`,label:`MPH`},{key:`time_1000`,label:`1000'`},{key:`time_1_4`,label:`1/4`},{key:`velAt_1_4_kmh`,label:`KM/H`},{key:`velAt_1_4_mph`,label:`MPH`},{key:`dialDiff`,label:`DIFF`}],getRacerByLane=laneNum=>props.slip.racerInfos.find(racer=>racer.laneNum===laneNum),getTimerValue=(laneNum,timerKey)=>{let racer=getRacerByLane(laneNum);if(!racer)return`-`;if(timerKey===null)return``;if(timerKey===`laneName`)return racer.lane||`-`;if(timerKey===`dial`){if(props.slip.dragType!==`bracketRace`)return`-`;let racer$1=getRacerByLane(laneNum);if(!racer$1)return`-`;let value=racer$1.timers.dial;if(value==null)return`-`;let num=parseFloat(value);return isNaN(num)?`-`:num.toFixed(3)}if(timerKey===`dialDiff`){if(props.slip.dragType!==`bracketRace`)return`-`;let racer$1=getRacerByLane(laneNum);if(!racer$1)return`-`;let value=racer$1.dialDiff;return value==null?`-`:formatDialDiff(value)}if(timerKey.includes(`velAt_`)){if(timerKey.includes(`_kmh`)){let baseKey=timerKey.replace(`_kmh`,``);return racer.velocities[baseKey+`_km/h`]||`-`}else if(timerKey.includes(`_mph`)){let baseKey=timerKey.replace(`_mph`,``);return racer.velocities[baseKey+`_mph`]||`-`}}return racer.timers[timerKey]||`-`},formatDialDiff=value=>{if(value===`-`)return`-`;let num=parseFloat(value);return isNaN(num)?`-`:(num>0?`+`:``)+num.toFixed(3)},getWinnerResult=laneNum=>{let racer=getRacerByLane(laneNum);if(!racer)return`-`;if(racer.disqualification)return`DQ`;if(props.slip.racerInfos.length===1)return`-`;let otherRacer=getRacerByLane(laneNum===1?2:1);if(!otherRacer)return`-`;if(otherRacer.disqualification)return`WINNER`;if(props.slip.dragType===`bracketRace`){let thisDiff=parseFloat(racer.dialDiff),otherDiff=parseFloat(otherRacer.dialDiff);return thisDiff===otherDiff?`TIE`:thisDiff>0&&otherDiff>0?thisDiffotherDiff?`WINNER`:`Break Out`}else{let thisTime=parseFloat(racer.finalTime),otherTime=parseFloat(otherRacer.finalTime);return thisTime>otherTime?`+${(thisTime-otherTime).toFixed(3)}`:`WINNER`}};return(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$187,[_cache[3]||=createBaseVNode(`div`,{class:`rip reverse top`},null,-1),createBaseVNode(`div`,_hoisted_2$152,[createBaseVNode(`div`,_hoisted_3$136,[(openBlock(!0),createElementBlock(Fragment,null,renderList(__props.slip.stripInfo,info=>(openBlock(),createElementBlock(`div`,{key:info},toDisplayString(_ctx.$tt(info)),1))),128))]),createBaseVNode(`div`,_hoisted_4$113,[createBaseVNode(`table`,_hoisted_5$98,[createBaseVNode(`tbody`,null,[(openBlock(),createElementBlock(Fragment,null,renderList(TIMER_ROWS_INFO,(rowInfo,rowIndex)=>createBaseVNode(`tr`,{key:`timer-`+rowIndex,class:normalizeClass({"quarter-mile-row":rowInfo.key===`time_1_4`})},[createBaseVNode(`td`,_hoisted_6$81,toDisplayString(rowInfo.label),1),createBaseVNode(`td`,_hoisted_7$69,toDisplayString(getTimerValue(2,rowInfo.key)),1),createBaseVNode(`td`,_hoisted_8$56,toDisplayString(getTimerValue(1,rowInfo.key)),1)],2)),64)),__props.slip.racerInfos.length>1?(openBlock(),createElementBlock(`tr`,_hoisted_9$50,[_cache[0]||=createBaseVNode(`td`,{class:`left-align`},null,-1),createBaseVNode(`td`,_hoisted_10$43,toDisplayString(getWinnerResult(2)),1),createBaseVNode(`td`,_hoisted_11$38,toDisplayString(getWinnerResult(1)),1)])):createCommentVNode(``,!0)])])]),(openBlock(!0),createElementBlock(Fragment,null,renderList(__props.slip.racerInfos,racer=>(openBlock(),createElementBlock(`div`,{key:racer.name,class:`racer`},[createBaseVNode(`div`,_hoisted_12$28,[createBaseVNode(`div`,_hoisted_13$25,toDisplayString(racer.lane),1),createBaseVNode(`div`,_hoisted_14$24,toDisplayString(racer.licenseText),1)]),createBaseVNode(`div`,_hoisted_15$23,toDisplayString(racer.name),1),Object.keys(racer.rewards).length===0?createCommentVNode(``,!0):(openBlock(),createElementBlock(`div`,_hoisted_16$23,[_cache[1]||=createTextVNode(` Rewards... `,-1),(openBlock(!0),createElementBlock(Fragment,null,renderList(racer.rewards,reward=>(openBlock(),createElementBlock(`div`,_hoisted_17$18,[createTextVNode(toDisplayString(reward)+` BMRA-XP `,1),createVNode(unref(bngIcon_default),{class:`reward-icon`,type:unref(icons).wheelOutline,color:`black`},null,8,[`type`])]))),256)),_cache[2]||=createBaseVNode(`template`,null,[createTextVNode(` ... `)],-1)]))]))),128)),createBaseVNode(`div`,_hoisted_18$16,[createBaseVNode(`div`,null,toDisplayString(unref(units).buildString(`temperature`,__props.slip.env.tempC,1,`c`))+` / `+toDisplayString(unref(units).buildString(`temperature`,__props.slip.env.tempC,1,`f`)),1),__props.slip.env.customGrav?(openBlock(),createElementBlock(`div`,_hoisted_19$13,toDisplayString(_ctx.$tt(`ui.environment.gravity`))+`: `+toDisplayString(__props.slip.env.gravity),1)):createCommentVNode(``,!0)])]),_cache[4]||=createBaseVNode(`div`,{class:`rip bottom`},null,-1)]))}},Timeslip_default=__plugin_vue_export_helper_default(_sfc_main$209,[[`__scopeId`,`data-v-4b627404`]]),_hoisted_1$186={key:0,class:`bng-app`,id:`container`},_hoisted_2$151={class:`slide`},_sfc_main$208={__name:`app`,setup(__props){let{$game}=useLibStore(),slip=ref({});onMounted(()=>{$game.events.on(`onDragRaceTimeslipData`,onDragRaceTimeslipData)}),onUnmounted(()=>{$game.events.off(`onDragRaceTimeslipData`,onDragRaceTimeslipData)});function onDragRaceTimeslipData(rawData){slip.value=rawData,rawData&&(console.log(rawData),Lua_default.Engine.Audio.playOnce(`AudioGui`,`event:>UI>Missions>Timeslip`))}let screenshot=function(){Lua_default.gameplay_drag_dragBridge.screenshotTimeslip()},clear=function(){slip.value=null};return(_ctx,_cache)=>slip.value&&slip.value.stripInfo?(openBlock(),createElementBlock(`div`,_hoisted_1$186,[createBaseVNode(`div`,_hoisted_2$151,[createVNode(Timeslip_default,{slip:slip.value,save:``,clear:``},null,8,[`slip`]),createVNode(unref(bngIcon_default),{class:`clear`,type:unref(icons).trashBin1,onClick:clear},null,8,[`type`]),createVNode(unref(bngIcon_default),{class:`save`,type:unref(icons).floppyDisk,onClick:screenshot},null,8,[`type`])])])):createCommentVNode(``,!0)}},app_default$10=__plugin_vue_export_helper_default(_sfc_main$208,[[`__scopeId`,`data-v-84d60911`]]),_hoisted_1$185={key:0},_hoisted_2$150={class:`lights-container`},_hoisted_3$135={class:`circles-wrapper`},_hoisted_4$112={class:`stage-circle`},_hoisted_5$97={class:`stage-top`},_hoisted_6$80={class:`stage-middle`},_hoisted_7$68={class:`stage-bottom`},_hoisted_8$55={class:`circles-wrapper`},_hoisted_9$49={class:`circles-wrapper`},_hoisted_10$42={class:`circles-wrapper`},_hoisted_11$37={class:`circles-wrapper`},_sfc_main$207={__name:`Treelights`,setup(__props){let events$3=useEvents(),isStaging=ref(!1),stageLights=ref([{stageLights:{prestageLight:!1,stageLight:!1},countDownLights:{amberLight1:!1,amberLight2:!1,amberLight3:!1,greenLight:!1,redLight:!1},globalLights:{blueLight:!1}}]),updateLights=changes=>{changes.stageLights&&(stageLights.value[0].stageLights={...stageLights.value[0].stageLights,...changes.stageLights}),changes.countDownLights&&(stageLights.value[0].countDownLights={...stageLights.value[0].countDownLights,...changes.countDownLights},(changes.countDownLights.greenLight||changes.countDownLights.redLight)&&setTimeout(()=>{isStaging.value=!1},2e3))},updateStaging=isNearby=>{isStaging.value=isNearby};return onMounted(()=>{events$3.on(`updateTreeLightApp`,updateLights),events$3.on(`updateTreeLightStaging`,updateStaging)}),onUnmounted(()=>{events$3.off(`updateTreeLightApp`,updateLights),events$3.off(`updateTreeLightStaging`,updateStaging)}),(_ctx,_cache)=>isStaging.value.valueOf==0?createCommentVNode(``,!0):(openBlock(),createElementBlock(`div`,_hoisted_1$185,[createBaseVNode(`div`,_hoisted_2$150,[createBaseVNode(`div`,_hoisted_3$135,[createBaseVNode(`div`,{class:normalizeClass([`light-circle black`,{blue:stageLights.value[0].globalLights.blueLight,red:stageLights.value[0].countDownLights.redLight}])},[withDirectives(createBaseVNode(`div`,_hoisted_4$112,[withDirectives(createBaseVNode(`div`,_hoisted_5$97,[..._cache[0]||=[createStaticVNode(``,1)]],512),[[vShow,stageLights.value[0].stageLights.prestageLight]]),withDirectives(createBaseVNode(`div`,_hoisted_6$80,[..._cache[1]||=[createStaticVNode(``,1)]],512),[[vShow,stageLights.value[0].stageLights.prestageLight&&stageLights.value[0].stageLights.stageLight]]),withDirectives(createBaseVNode(`div`,_hoisted_7$68,[..._cache[2]||=[createStaticVNode(``,1)]],512),[[vShow,stageLights.value[0].stageLights.stageLight]])],512),[[vShow,!stageLights.value[0].countDownLights.redLight]])],2)]),createBaseVNode(`div`,_hoisted_8$55,[createBaseVNode(`div`,{class:normalizeClass([`light-circle black`,{amber:stageLights.value[0].countDownLights.amberLight1,red:stageLights.value[0].countDownLights.redLight}])},null,2)]),createBaseVNode(`div`,_hoisted_9$49,[createBaseVNode(`div`,{class:normalizeClass([`light-circle black`,{amber:stageLights.value[0].countDownLights.amberLight2,red:stageLights.value[0].countDownLights.redLight}])},null,2)]),createBaseVNode(`div`,_hoisted_10$42,[createBaseVNode(`div`,{class:normalizeClass([`light-circle black`,{amber:stageLights.value[0].countDownLights.amberLight3,red:stageLights.value[0].countDownLights.redLight}])},null,2)]),createBaseVNode(`div`,_hoisted_11$37,[createBaseVNode(`div`,{class:normalizeClass([`light-circle black go`,{green:stageLights.value[0].countDownLights.greenLight,red:stageLights.value[0].countDownLights.redLight}])},null,2)])])]))}},Treelights_default=__plugin_vue_export_helper_default(_sfc_main$207,[[`__scopeId`,`data-v-c2ff1007`]]),_sfc_main$206={__name:`bngModifierTiles`,props:{modifierActionInfos:{type:Object,required:!0}},setup(__props){let{isControllerUsed}=storeToRefs(controls_default()),props=__props,controllerActions=computed(()=>{let mod1Active=props.modifierActionInfos.customModifier1?.active,mod2Active=props.modifierActionInfos.customModifier2?.active,mod1Disabled=props.modifierActionInfos.customModifier1?.disabled,mod2Disabled=props.modifierActionInfos.customModifier2?.disabled,mod1modifier2Disabled=props.modifierActionInfos.modifier1modifier2?.disabled;return[{actions:[{actionName:`customModifier2`}],active:!mod2Disabled&&mod2Active&&!mod1Active,disabled:mod2Disabled},{actions:[{actionName:`customModifier2`},{actionName:`customModifier1`}],active:!mod1modifier2Disabled&&mod1Active&&mod2Active,disabled:mod1modifier2Disabled},{actions:[{actionName:`customModifier1`}],active:!mod1Disabled&&mod1Active&&!mod2Active,disabled:mod1Disabled}]}),kbmActions=computed(()=>{props.modifierActionInfos.shift?.active;let ctrlActive=props.modifierActionInfos.ctrl?.active!==void 0,altActive=props.modifierActionInfos.alt?.active!==void 0;return[{active:ctrlActive,actions:[{actionName:`kbmModifier1`,device:`keyboard0`,deviceKey:`ctrl`}]},{active:altActive,actions:[{actionName:`kbmModifier3`,device:`keyboard0`,deviceKey:`alt`}]}]}),entries=computed(()=>isControllerUsed.value?controllerActions.value:kbmActions.value),getModifierClass=entry=>{let cls=`modifier-tile`;return entry.active&&(cls+=` active`),entry.disabled&&(cls+=` disabled`),cls};return(_ctx,_cache)=>(openBlock(!0),createElementBlock(Fragment,null,renderList(entries.value,entry=>(openBlock(),createElementBlock(`div`,{class:normalizeClass(getModifierClass(entry))},[(openBlock(!0),createElementBlock(Fragment,null,renderList(entry.actions,(action,actionIdx)=>(openBlock(),createElementBlock(`div`,{key:actionIdx},[actionIdx>0?(openBlock(),createBlock(unref(bngIcon_default),{key:0,type:`mathPlus`})):createCommentVNode(``,!0),createVNode(unref(bngBinding_default),{action:action.actionName,device:action.device,"device-key":action.deviceKey,"show-unassigned":!1},null,8,[`action`,`device`,`device-key`])]))),128))],2))),256))}},bngModifierTiles_default=__plugin_vue_export_helper_default(_sfc_main$206,[[`__scopeId`,`data-v-ea01b9d8`]]),_hoisted_1$184={key:0,class:`bng-app-binding-display`},_hoisted_2$149={key:0,class:`modifier-bindings`},_hoisted_3$134={class:`label-column`},_hoisted_4$111={key:0,class:`label-text`},_hoisted_5$96={class:`binding-column`},_hoisted_6$79={class:`flexible-area`},_hoisted_7$67={class:`label-column`},_hoisted_8$54={key:0,class:`label-text`},_hoisted_9$48={class:`binding-column`},_hoisted_10$41={key:0,class:`tile-flex`},_hoisted_11$36={key:1,class:`bottom-left-group`},_sfc_main$205={__name:`bngAppBindingDisplay`,setup(__props){let events$3=useEvents(),actions=shallowRef([]),tileActions=shallowRef([]),constantActions=shallowRef([]),modifierActionInfos=shallowRef([]),additionalData=shallowRef({}),isFaded=ref(!1),isHovered=ref(!1),mouseDownAction=ref(``),actionOpacity=ref(1),fadeOutTimeout=null,isFadingOut=ref(!1),showApp=ref(!0),tileRefs=ref([]),isWide=ref([]),narrowSpan=ref(4),setActions=data=>{let newActions=Array.isArray(data.actions)?data.actions:[];showApp.value=data.showApp,constantActions.value=Array.isArray(data.constantActions)?data.constantActions:[],modifierActionInfos.value=data.modifierActionInfos?{...data.modifierActionInfos}:{},additionalData.value=data.additionalData?{...data.additionalData}:{},fadeOutTimeout&&(clearTimeout(fadeOutTimeout),fadeOutTimeout=null,isFadingOut.value=!1),actions.value.length>0&&newActions.length===0?(isFadingOut.value=!0,actionOpacity.value=0,fadeOutTimeout=setTimeout(()=>{actions.value=newActions,actionOpacity.value=1,isFadingOut.value=!1,fadeOutTimeout=null},0)):newActions.length>0&&actions.value.length===0?(actions.value=newActions,actionOpacity.value=0,nextTick(()=>{actionOpacity.value=1})):(actions.value=newActions,actionOpacity.value=1),tileActions.value=actions.value.filter(action=>action.icon),actions.value=actions.value.filter(action=>!action.icon)},getActionClass=(action,isConstant)=>{let cls=`binding-row`;return isConstant?cls+=` is-constant`:isFadingOut.value&&(cls+=` is-fading-out`),!action.onClick&&!action.inputActionOnClick&&(cls+=` no-hover`),action.highlighted&&(cls+=` highlighted`),cls},onActionClickDown=action=>{action.onClick?runRaw(action.onClick):action.inputActionOnClick&&(mouseDownAction.value=action.action,Lua_default.ui_bindingsLegend.triggerInputAction(action.action,1))},onMouseEnter=()=>{isHovered.value=!0},onMouseLeave=()=>{isHovered.value=!1},onGlobalMouseUp=event=>{mouseDownAction.value&&=(Lua_default.ui_bindingsLegend.triggerInputAction(mouseDownAction.value,0),``)};onMounted(()=>{events$3.on(`setActionsForLegend`,setActions),events$3.on(`setBindingsLegendFade`,value=>{isFaded.value=!!value}),Lua_default.ui_bindingsLegend.sendDataToUI(!0),listenFilteredInputEvents(!0),document.addEventListener(`mouseup`,onGlobalMouseUp)}),onBeforeUnmount(()=>{document.removeEventListener(`mouseup`,onGlobalMouseUp),fadeOutTimeout&&=(clearTimeout(fadeOutTimeout),null),actionOpacity.value=1,listenFilteredInputEvents(!1)});function listenFilteredInputEvents(listen){events$3[listen?`on`:`off`](`FilteredInputChanged`,onFilteredInputChanged),Lua_default.WinInput.setForwardFilteredEvents(listen)}function onFilteredInputChanged(data){let updated$2=!1;for(let action of tileActions.value)action.action===data.bindingAction&&(action.value=data.value,updated$2=!0);updated$2&&triggerRef(tileActions)}function setTileRef(i,compOrEl){tileRefs.value[i]=compOrEl&&compOrEl.$el?compOrEl.$el:compOrEl}function classifyTiles(){isWide.value=tileRefs.value.map(el=>!!el?.querySelector?.(`.combo-binding`))}function pickNarrowSpanByCount(n){let options=[{cols:4,span:3},{cols:3,span:4},{cols:2,span:6}],best=options[0],bestR=n%best.cols;for(let opt of options){let r=n%opt.cols;r{await nextTick(),tileRefs.value.length=tileActions.value.length,classifyTiles(),recomputeLayout()}),onMounted(async()=>{await nextTick(),classifyTiles(),recomputeLayout()}),(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,{class:normalizeClass([`bng-app-binding-display-wrapper`,{"is-faded":isFaded.value&&!isHovered.value}]),onMouseenter:onMouseEnter,onMouseleave:onMouseLeave},[showApp.value?(openBlock(),createElementBlock(`div`,_hoisted_1$184,[modifierActionInfos.value&&additionalData.value.vehicleSpecificStatus!==`enabled`?(openBlock(),createElementBlock(`div`,_hoisted_2$149,[createVNode(bngModifierTiles_default,{"modifier-action-infos":modifierActionInfos.value},null,8,[`modifier-action-infos`])])):createCommentVNode(``,!0),(openBlock(!0),createElementBlock(Fragment,null,renderList(constantActions.value,action=>(openBlock(),createBlock(unref(bngButton_default),{accent:unref(ACCENTS).custom,onMousedown:$event=>onActionClickDown(action),tabindex:`-1`,class:normalizeClass(getActionClass(action,!0))},{default:withCtx(()=>[createBaseVNode(`div`,_hoisted_3$134,[action.label?(openBlock(),createElementBlock(`span`,_hoisted_4$111,toDisplayString(_ctx.$t(action.label)),1)):createCommentVNode(``,!0)]),createBaseVNode(`div`,_hoisted_5$96,[action.bindings?(openBlock(!0),createElementBlock(Fragment,{key:0},renderList(action.bindings,binding=>(openBlock(),createBlock(unref(bngBinding_default),{key:binding.device+`:`+binding.control,action:action.action,device:binding.device,"device-key":binding.control,"show-unassigned":``,"action-variants":``},null,8,[`action`,`device`,`device-key`]))),128)):(openBlock(),createBlock(unref(bngBinding_default),{key:1,action:action.action,"show-unassigned":``,"action-variants":``},null,8,[`action`]))])]),_:2},1032,[`accent`,`onMousedown`,`class`]))),256)),createBaseVNode(`div`,_hoisted_6$79,[(openBlock(!0),createElementBlock(Fragment,null,renderList(actions.value,(action,index)=>(openBlock(),createBlock(unref(bngButton_default),{key:action.action||action.label,accent:unref(ACCENTS).custom,onMousedown:$event=>onActionClickDown(action),tabindex:`-1`,ref_for:!0,ref:index===0?`actionButton`:void 0,class:normalizeClass(getActionClass(action,!1))},{default:withCtx(()=>[createBaseVNode(`div`,_hoisted_7$67,[action.label?(openBlock(),createElementBlock(`span`,_hoisted_8$54,toDisplayString(_ctx.$t(action.label)),1)):createCommentVNode(``,!0)]),createBaseVNode(`div`,_hoisted_9$48,[action.bindings?(openBlock(!0),createElementBlock(Fragment,{key:0},renderList(action.bindings,binding=>(openBlock(),createBlock(unref(bngBinding_default),{key:binding.device+`:`+binding.control,action:action.action,device:binding.device,"device-key":binding.control,"show-unassigned":``,"action-variants":``},null,8,[`action`,`device`,`device-key`]))),128)):(openBlock(),createBlock(unref(bngBinding_default),{key:1,action:action.action,"show-unassigned":``,"action-variants":``},null,8,[`action`]))])]),_:2},1032,[`accent`,`onMousedown`,`class`]))),128)),tileActions.value.length>0?(openBlock(),createElementBlock(`div`,_hoisted_10$41,[(openBlock(!0),createElementBlock(Fragment,null,renderList(tileActions.value,(action,i)=>(openBlock(),createBlock(unref(bngBindingTileButton_default),{class:normalizeClass([`tile-grid-item`,{highlighted:action.highlighted}]),action,icon:action.icon,label:_ctx.$t(action.label),layout:action.direction,showValueBar:action.direction!==void 0,isBidirectional:action.isCentered,value:action.value,style:{"--tile-span":4},ref_for:!0,ref:el=>setTileRef(i,el),"show-unassigned":``,"action-variants":``,"bng-no-nav":``,tabindex:`-1`},{default:withCtx(()=>[action.bindings?(openBlock(!0),createElementBlock(Fragment,{key:0},renderList(action.bindings,binding=>(openBlock(),createBlock(unref(bngBinding_default),{key:binding.device+`:`+binding.control,action:action.action,device:binding.device,"device-key":binding.control,"show-unassigned":``,"action-variants":``},null,8,[`action`,`device`,`device-key`]))),128)):(openBlock(),createBlock(unref(bngBinding_default),{key:1,action:action.action,"show-unassigned":``,"action-variants":``},null,8,[`action`]))]),_:2},1032,[`class`,`action`,`icon`,`label`,`layout`,`showValueBar`,`isBidirectional`,`value`]))),256))])):createCommentVNode(``,!0)])])):createCommentVNode(``,!0),showApp.value?(openBlock(),createElementBlock(`div`,_hoisted_11$36,[withDirectives((openBlock(),createBlock(unref(bngButton_default),{class:`bottom-left-button`,disabled:additionalData.value.vehicleSpecificStatus===`inactive`,accent:additionalData.value.vehicleSpecificStatus===`enabled`||additionalData.value.vehicleSpecificStatus===`fleeting`?unref(ACCENTS).main:unref(ACCENTS).text,onClick:_cache[0]||=$event=>unref(Lua_default).ui_bindingsLegend.toggleShowVehicleSpecificActions(),"bng-no-nav":``,tabindex:`-1`},{default:withCtx(()=>[createVNode(unref(bngIcon_default),{type:unref(icons).car},null,8,[`type`]),additionalData.value.vehicleSpecificStatus===`enabled`?(openBlock(),createBlock(unref(bngIcon_default),{key:0,class:`bottom-left-lock`,type:unref(icons).lockClosed},null,8,[`type`])):createCommentVNode(``,!0)]),_:1},8,[`disabled`,`accent`])),[[unref(BngTooltip_default),`Press to show/hide vehicle specific actions`,`right`]])])):createCommentVNode(``,!0),createVNode(unref(bngButton_default),{class:`bottom-left-button`,accent:unref(ACCENTS).text,icon:unref(icons).eyeSolidOpened,onClick:_cache[1]||=$event=>unref(Lua_default).ui_bindingsLegend.toggleShowApp(),"bng-no-nav":``,tabindex:`-1`},null,8,[`accent`,`icon`])],34))}},bngAppBindingDisplay_default=__plugin_vue_export_helper_default(_sfc_main$205,[[`__scopeId`,`data-v-cf4052e5`]]),_hoisted_1$183={class:`action`},_hoisted_2$148={key:0,class:`indicators`},_hoisted_3$133={class:`icon-wrapper`},_hoisted_4$110={key:2,class:`tile-fallback-label`},_hoisted_5$95={key:0,class:`value-bar`},_hoisted_6$78={class:`bindings-wrapper`},_sfc_main$204={__name:`bngBindingTileButton`,props:{label:String,icon:[Object,String],showIndicators:{type:Boolean,default:!1},layout:{type:String,default:`horizontal`,validator:v=>[`horizontal`,`vertical`].includes(v)},dark:Boolean,disabled:Boolean,action:{type:Object,required:!0},bindings:{type:Array,default:()=>void 0},actionVariants:Boolean,showValueBar:{type:Boolean,default:!0},value:{type:Number,default:0},targetValue:{type:Number,default:0},isBidirectional:{type:Boolean,default:!1}},emits:[`click`],setup(__props,{expose:__expose}){let props=__props,layoutClass=computed(()=>props.layout===`vertical`?`layout-vertical`:`layout-horizontal`);__expose({icons});let isLikelyImagePath=val=>typeof val==`string`&&(val.includes(`/`)||val.startsWith(`.`)||val.includes(`\\`)),candidateIcon=computed(()=>props.icon??null),useGlyphIcon=computed(()=>{let c=candidateIcon.value;return c?typeof c==`object`?!!c.glyph:typeof c==`string`?!isLikelyImagePath(c)&&c in icons:!1:!1}),resolvedGlyphType=computed(()=>useGlyphIcon.value?candidateIcon.value:null),resolvedImagePath=computed(()=>{let c=candidateIcon.value;return typeof c==`string`&&isLikelyImagePath(c)?c:null});return(_ctx,_cache)=>(openBlock(),createBlock(unref(bngButton_default),{class:`bng-binding-tile-button`,accent:unref(ACCENTS).custom,disabled:__props.disabled,onClick:_cache[0]||=$event=>_ctx.$emit(`click`)},{default:withCtx(()=>[createBaseVNode(`div`,{class:normalizeClass([`content`,layoutClass.value])},[createBaseVNode(`div`,_hoisted_1$183,[__props.showIndicators?(openBlock(),createElementBlock(`div`,_hoisted_2$148,[(openBlock(),createElementBlock(Fragment,null,renderList(5,i=>createBaseVNode(`div`,{class:normalizeClass([`indicator`,{active:i===2}]),key:i},null,2)),64))])):createCommentVNode(``,!0),createBaseVNode(`div`,_hoisted_3$133,[useGlyphIcon.value?(openBlock(),createBlock(unref(bngIcon_default),{key:0,class:`icon-glyph`,type:resolvedGlyphType.value},null,8,[`type`])):resolvedImagePath.value?(openBlock(),createBlock(unref(bngImageAsset_default),{key:1,externalSrc:resolvedImagePath.value,class:`icon-img`,mask:``},null,8,[`externalSrc`])):__props.label?(openBlock(),createElementBlock(`div`,_hoisted_4$110,toDisplayString(__props.label),1)):createCommentVNode(``,!0)])]),__props.showValueBar?(openBlock(),createElementBlock(`div`,_hoisted_5$95,[createVNode(unref(bngInputBar_default),{value:__props.value,"target-value":__props.targetValue,"is-bidirectional":__props.isBidirectional,vertical:__props.layout==`vertical`},null,8,[`value`,`target-value`,`is-bidirectional`,`vertical`])])):createCommentVNode(``,!0),createBaseVNode(`div`,_hoisted_6$78,[renderSlot(_ctx.$slots,`binding`,{},()=>[__props.action&&__props.action.bindings?(openBlock(!0),createElementBlock(Fragment,{key:0},renderList(__props.action.bindings,binding=>(openBlock(),createBlock(unref(bngBinding_default),{key:binding.device+`:`+binding.control,action:__props.action.action,device:binding.device,"device-key":binding.control,dark:__props.dark,"show-unassigned":``,"action-variants":__props.actionVariants,vertical:__props.layout===`vertical`},null,8,[`action`,`device`,`device-key`,`dark`,`action-variants`,`vertical`]))),128)):(openBlock(),createBlock(unref(bngBinding_default),{key:1,vertical:__props.layout===`vertical`,action:__props.action&&__props.action.action,dark:__props.dark,"show-unassigned":``,"action-variants":__props.actionVariants},null,8,[`vertical`,`action`,`dark`,`action-variants`]))],!0)])],2)]),_:3},8,[`accent`,`disabled`]))}},bngBindingTileButton_default=__plugin_vue_export_helper_default(_sfc_main$204,[[`__scopeId`,`data-v-db243a30`]]),_hoisted_1$182={class:`message-container`},_sfc_main$203={__name:`bngFlashMessage`,props:{messageSource:{type:String,default:`ScenarioFlashMessage`}},setup(__props){let props=__props,events$3=useEvents(),{api:api$1}=useBridge(),txt=ref(``),messageQueue=ref([]),stepTimeout=ref(null),animationClass=ref(``),fontSizeClass=ref(`font-small`),paused=ref(!1);onMounted(()=>{events$3.on(props.messageSource,data=>{if(Array.isArray(data))data.forEach(item=>{let messageObject={msg:item[0],ttl:item[1],luaCall:item[2]&&typeof item[2]==`string`?item[2]:void 0,jsCallback:item[2]&&typeof item[2]==`function`?item[2]:void 0,big:item[3]===void 0?!1:item[3]};messageQueue.value.push(messageObject)}),messageQueue.value.length>0&&!stepTimeout.value&&playMessagesAnimation();else if(typeof data==`object`){let messageObject={msg:data.msg,ttl:data.ttl,luaCall:data.luaCall||void 0,jsCallback:data.jsCallback||void 0,big:data.big===void 0?!1:data.big};messageQueue.value.push(messageObject),stepTimeout.value||playMessagesAnimation()}else console.warn(`Unexpected data format received for FlashMessage`)}),events$3.on(`physicsStateChanged`,state=>{paused.value=!state,paused.value?stepTimeout.value&&=(clearTimeout(stepTimeout.value),null):state&&playMessagesAnimation()})}),onUnmounted(()=>{stepTimeout.value&&=(clearTimeout(stepTimeout.value),null)});function playMessagesAnimation(){if(messageQueue.value.length===0){resetCountdown();return}animationClass.value=`fade-in`,setTimeout(()=>{animationClass.value=``},200);let msg=messageQueue.value[0];txt.value=msg.msg,fontSizeClass.value=msg.big?`font-large`:`font-small`,msg.luaCall&&typeof msg.luaCall==`string`&&api$1.engineLua(msg.luaCall),msg.jsCallback&&typeof msg.jsCallback==`function`&&msg.jsCallback(),messageQueue.value.shift(),setTimeout(()=>{animationClass.value=`fade-out`},msg.ttl*1e3-200),stepTimeout.value=setTimeout(()=>{playMessagesAnimation()},msg.ttl*1e3)}function resetCountdown(){stepTimeout.value&&clearTimeout(stepTimeout.value),messageQueue.value=[],txt.value=``,stepTimeout.value=null}return(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$182,[createBaseVNode(`div`,{class:normalizeClass([`message`,[`message`,animationClass.value,fontSizeClass.value]])},toDisplayString(txt.value),3)]))}},bngFlashMessage_default=__plugin_vue_export_helper_default(_sfc_main$203,[[`__scopeId`,`data-v-02941c3f`]]),_hoisted_1$181={class:`track`},_sfc_main$202={__name:`bngInputBar`,props:{value:{type:Number,default:0},targetValue:{type:Number,default:0},isBidirectional:{type:Boolean,default:!1},vertical:{type:Boolean,default:!1}},setup(__props){let props=__props,isVertical=computed(()=>props.vertical),clamp$2=(v,min$1,max$1)=>Math.min(max$1,Math.max(min$1,v)),toUnits=(v,bidir)=>{let vv=clamp$2(v,bidir?-1:0,1);return bidir?(vv+1)/2:vv},zeroUnits=computed(()=>props.isBidirectional?.5:0),actualUnits=computed(()=>toUnits(props.value,props.isBidirectional)),targetUnits=computed(()=>toUnits(props.targetValue,props.isBidirectional)),makeFillStyle=units=>{if(!isVertical.value){if(props.isBidirectional){let start=Math.min(units,zeroUnits.value),end=Math.max(units,zeroUnits.value);return{left:`${start*100}%`,right:`${(1-end)*100}%`}}return{left:`0%`,right:`${(1-units)*100}%`}}if(props.isBidirectional){let start=Math.min(units,zeroUnits.value),end=Math.max(units,zeroUnits.value);return{bottom:`${start*100}%`,top:`${(1-end)*100}%`}}return{bottom:`0%`,top:`${(1-units)*100}%`}},actualStyle=computed(()=>makeFillStyle(actualUnits.value)),targetStyle=computed(()=>makeFillStyle(targetUnits.value)),showTarget=computed(()=>props.targetValue!==void 0&&props.targetValue!==null),knobStyle=computed(()=>isVertical.value?{bottom:`calc(${actualUnits.value*100}% - 2px)`}:{left:`calc(${actualUnits.value*100}% - 2px)`});return(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,{class:normalizeClass([`bng-input-bar`,{bidirectional:__props.isBidirectional,vertical:isVertical.value}])},[createBaseVNode(`div`,_hoisted_1$181,[showTarget.value?(openBlock(),createElementBlock(`div`,{key:0,class:`fill target`,style:normalizeStyle(targetStyle.value)},null,4)):createCommentVNode(``,!0),createBaseVNode(`div`,{class:`fill actual`,style:normalizeStyle(actualStyle.value)},null,4)]),createBaseVNode(`div`,{class:`knob`,style:normalizeStyle(knobStyle.value)},null,4)],2))}},bngInputBar_default=__plugin_vue_export_helper_default(_sfc_main$202,[[`__scopeId`,`data-v-30b04794`]]),_hoisted_1$180={key:1,class:`data-label`},_hoisted_2$147={key:2,class:`data-value`},_hoisted_3$132={key:3,class:`time-container`},_hoisted_4$109={class:`time-seconds`},_hoisted_5$94={class:`time-milliseconds`},_hoisted_6$77={key:4,class:`data-value-extra`},_sfc_main$201={__name:`bngSimpleDataDisplay`,props:{label:{type:String,default:``},value:{type:[String,Number,Object,Array],default:``},icon:{type:String,default:``},minutes:{type:String},seconds:{type:String},milliseconds:{type:String}},setup(__props){let props=__props,iconType$1=computed(()=>props.icon);return(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,{class:normalizeClass([`simple-data-display`,{"with-icon":__props.icon}])},[__props.icon?(openBlock(),createBlock(unref(bngIcon_default),{key:0,type:iconType$1.value,class:`icon`},null,8,[`type`])):createCommentVNode(``,!0),__props.label&&!__props.icon?(openBlock(),createElementBlock(`div`,_hoisted_1$180,toDisplayString(__props.label),1)):createCommentVNode(``,!0),_ctx.$slots.default?createCommentVNode(``,!0):(openBlock(),createElementBlock(`div`,_hoisted_2$147,toDisplayString(__props.value),1)),props.minutes||props.seconds?(openBlock(),createElementBlock(`div`,_hoisted_3$132,[createBaseVNode(`span`,{class:normalizeClass({"time-minutes":!0,zero:__props.minutes===`00`})},toDisplayString(props.minutes),3),_cache[1]||=createTextVNode(` :`,-1),createBaseVNode(`span`,_hoisted_4$109,toDisplayString(props.seconds),1),props.milliseconds?(openBlock(),createElementBlock(Fragment,{key:0},[_cache[0]||=createTextVNode(` .`,-1),createBaseVNode(`span`,_hoisted_5$94,toDisplayString(props.milliseconds),1)],64)):createCommentVNode(``,!0)])):createCommentVNode(``,!0),_ctx.$slots.default?(openBlock(),createElementBlock(`div`,_hoisted_6$77,[renderSlot(_ctx.$slots,`default`,{},void 0,!0)])):createCommentVNode(``,!0)],2))}},bngSimpleDataDisplay_default=__plugin_vue_export_helper_default(_sfc_main$201,[[`__scopeId`,`data-v-f2b79846`]]),_sfc_main$200={__name:`app`,props:{showFlash:{type:Boolean,default:!0}},setup(__props){let props=__props;return(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,null,[createVNode(Treelights_default),props.showFlash?(openBlock(),createBlock(unref(bngFlashMessage_default),{key:0,"message-source":`DragRaceTreeFlashMessage`})):createCommentVNode(``,!0)]))}},app_default$11=_sfc_main$200,_hoisted_1$179={class:`stage-indicator-container`},_hoisted_2$146={class:`stage-bar`},_hoisted_3$131={key:0,class:`segment grey-segment top`},_hoisted_4$108={key:1,class:`segment grey-segment bottom`},_hoisted_5$93={class:`indicator-line`},THROTTLE_MS=1,HIDE_DELAY_MS=5e3,_sfc_main$199={__name:`app`,setup(__props){let events$3=useEvents(),stageDistance=ref(-100),isVisible$1=ref(!0),hideTimeout,isDetailedView=computed(()=>stageDistance.value>-1&&stageDistance.value<1),indicatorPosition=computed(()=>isDetailedView?70-(stageDistance.value+1)*20:stageDistance.value<-1?10-stageDistance.value:30-(stageDistance.value-1)*(30/3)),lastUpdate=0;function updateStageApp(distance){let now$1=performance.now();now$1-lastUpdate{isVisible$1.value=!1},HIDE_DELAY_MS))}return onMounted(()=>{events$3.on(`updateStageApp`,updateStageApp)}),onUnmounted(()=>{lastUpdate=0,clearTimeout(hideTimeout),events$3.off(`updateStageApp`,updateStageApp)}),(_ctx,_cache)=>(openBlock(),createElementBlock(Fragment,null,[createBaseVNode(`div`,null,toDisplayString(stageDistance.value),1),withDirectives(createBaseVNode(`div`,_hoisted_1$179,[createBaseVNode(`div`,_hoisted_2$146,[isDetailedView.value?(openBlock(),createElementBlock(`div`,_hoisted_3$131)):createCommentVNode(``,!0),createBaseVNode(`div`,{class:normalizeClass([`middle-section`,{"align-top":!isDetailedView.value&&stageDistance.value<-1,"align-bottom":!isDetailedView.value&&stageDistance.value>1}])},[isDetailedView.value?(openBlock(),createElementBlock(Fragment,{key:0},[_cache[0]||=createBaseVNode(`div`,{class:`segment deep-stage`,style:{height:`20px`}},null,-1),_cache[1]||=createBaseVNode(`div`,{class:`segment stage`,style:{height:`40px`}},null,-1),_cache[2]||=createBaseVNode(`div`,{class:`segment pre-stage`,style:{height:`40px`}},null,-1)],64)):(openBlock(),createElementBlock(`div`,{key:1,class:normalizeClass([`segment green-segment`,{top:stageDistance.value<-1,bottom:stageDistance.value>1}])},null,2))],2),stageDistance.value<=1?(openBlock(),createElementBlock(`div`,_hoisted_4$108)):createCommentVNode(``,!0)]),createBaseVNode(`div`,{class:`distance-indicator`,style:normalizeStyle({top:indicatorPosition.value+`%`})},[createBaseVNode(`div`,_hoisted_5$93,[createBaseVNode(`div`,{class:normalizeClass([`car-icon`,{"car-icon-detailed":isDetailedView.value}])},null,2)])],4)],512),[[vShow,isVisible$1.value&&stageDistance.value>=-4&&stageDistance.value<=4]])],64))}},app_default$12=__plugin_vue_export_helper_default(_sfc_main$199,[[`__scopeId`,`data-v-5245723d`]]),_hoisted_1$178={class:`main-container drift-app`},_hoisted_2$145={class:`cached-score-wrapper`},_hoisted_3$130={class:`added-score`},_hoisted_4$107={class:`cached-score`},_hoisted_5$92={class:`score-container`},_hoisted_6$76={class:`score`},_hoisted_7$66={class:`combo-wrapper`},_hoisted_8$53=[`id`],_hoisted_9$47=[`id`],_hoisted_10$40=[`stop-color`],_hoisted_11$35=[`stop-color`],_hoisted_12$27=[`id`],_hoisted_13$24={class:`multiplier`,x:`0`,y:`15.5`,fill:`#fff`,"dominant-baseline":`hanging`,"text-anchor":`start`,style:{fontSize:`1.9rem`}},_hoisted_14$23=[`mask`],_hoisted_15$22=[`fill`],_hoisted_16$22={class:`remaining-time`},_hoisted_17$17={class:`wrapper`},_hoisted_18$15={class:`drift-bar`},_hoisted_19$12={class:`drift-scale`},_hoisted_20$11={class:`drift-progress-bar`},FAIL_ANIMATION_DURATION=900,_sfc_main$198={__name:`app`,props:{showFlash:{type:Boolean,default:!0}},setup(__props){let props=__props,{lua}=useBridge(),bgId=uniqueId(``,`_`),events$3=useEvents(),realtimeScorePoints=ref(0),realtimeScoreCombo=ref(0),creep=ref(0),remainingComboTime=ref(0),centerIcon=ref(null),centerMessage=ref(null),centerFailMessage=ref(null),scoreToAdd=ref(0),countdownTimer=null,countdownStartTime=null,delayTimer=null,startTimer=null,centerMessageTimer=null,bonusDisplayAdd=null,bonusDisplayDispose=null,bonusQueue=ref([]),bonusDisplay=ref([]),realtimeAngle=ref(0),steppedPerformanceFactor=ref(1),isCenterMessageFading=ref(!1),isFailActive=ref(!1),isFailAnimating=ref(!1),failAnimationStartTime=null,failAnimationTimer=null,currentModifier=ref(null),isModifierFading=ref(!1),modifierTimer=null;onMounted(()=>{let rafScheduled=!1,buffered={points:0,combo:0,remaining:0,creep:0,angle:0},flushBuffered=()=>{realtimeScorePoints.value=buffered.points,realtimeScoreCombo.value=buffered.combo,remainingComboTime.value=buffered.remaining,creep.value=buffered.creep,realtimeAngle.value=buffered.angle,rafScheduled=!1},scheduleFlush=()=>{rafScheduled||(rafScheduled=!0,requestAnimationFrame(flushBuffered))},streamsList$1=[`drift`];useStreams(streamsList$1,streams=>{for(let stream of streamsList$1)if(!streams[stream])return;buffered.points=streams.drift.realtimeCachedScoreFloored,buffered.combo=streams.drift.realtimeCombo,buffered.points>0&&(centerMessage.value=null),buffered.remaining=streams.drift.realtimeRemainingComboTime,buffered.creep=streams.drift.realtimeCreep,buffered.angle=-streams.drift.realtimeAngle,steppedPerformanceFactor.value=streams.drift.realtimePerformanceFactor,scheduleFlush()}),events$3.on(`setDriftRealtimeFail`,(reason,icon)=>{cancelTimers(),isFailActive.value=!0,isFailAnimating.value=!0,isCenterMessageFading.value=!1,centerFailMessage.value=reason,centerIcon.value=icon||``,bonusDisplay.value=[],creep.value=0;let initialComboTime=remainingComboTime.value;failAnimationStartTime=performance.now();let animateFailBar=timestamp=>{let elapsed=timestamp-failAnimationStartTime,progress=Math.max(0,1-elapsed/FAIL_ANIMATION_DURATION);remainingComboTime.value=initialComboTime*progress,progress>0&&(failAnimationTimer=requestAnimationFrame(animateFailBar))};failAnimationTimer=requestAnimationFrame(animateFailBar),centerMessageTimer&&clearTimeout(centerMessageTimer),setTimeout(()=>{isFailActive.value=!1,isFailAnimating.value=!1,remainingComboTime.value=0,failAnimationTimer&&=(cancelAnimationFrame(failAnimationTimer),null)},FAIL_ANIMATION_DURATION),centerMessageTimer=setTimeout(()=>{isCenterMessageFading.value=!0},1e3),setTimeout(()=>{centerFailMessage.value=null,centerIcon.value=null,isCenterMessageFading.value=!1},1500)}),events$3.on(`setDriftPersistentDriftScored`,(final,score,combo)=>{centerMessage.value=`+ `,scoreToAdd.value=final,bonusDisplay.value=[],startCountdown()}),events$3.on(`displayDriftScoreModifier`,msg=>{modifierTimer&&clearTimeout(modifierTimer),isModifierFading.value=!1,currentModifier.value=msg,modifierTimer=setTimeout(()=>{isModifierFading.value=!0},1500)})}),onUnmounted(()=>{cancelTimers(),centerMessageTimer&&clearTimeout(centerMessageTimer),clearInterval(bonusDisplayAdd),clearInterval(bonusDisplayDispose),failAnimationTimer&&cancelAnimationFrame(failAnimationTimer),modifierTimer&&clearTimeout(modifierTimer),window.removeEventListener(`resize`,onResize)});let barClass=computed(()=>({"bar-good":!isFailAnimating.value&&steppedPerformanceFactor.value>=3,"bar-warn":!isFailAnimating.value&&steppedPerformanceFactor.value<3,"bar-fail":isFailAnimating.value})),barVarsStyle=computed(()=>({"--bar-scale":String(Math.max(0,Math.min(1,remainingComboTime.value))),"--bar-visible":remainingComboTime.value<=.01?`hidden`:`visible`})),driftProgressStyle=computed(()=>{let pos=Math.abs(calculatePosition(realtimeAngle.value,thresholds,positions))/100;return{left:`50%`,width:`50%`,transform:`scaleX(${((realtimeAngle.value>0?1:-1)>0?1:-1)*(pos/2)})`,opacity:Math.abs(realtimeAngle.value)<7?`0.65`:`1`}}),formattedCombo=computed(()=>parseFloat(realtimeScoreCombo.value).toFixed(1)),formattedRealtimeAngle=computed(()=>Math.abs(Math.round(realtimeAngle.value))),layoutVersion=ref(0),tickLefts=computed(()=>positions.map(p$1=>`${(p$1+100)/2}%`)),onResize=()=>{layoutVersion.value++};window.addEventListener(`resize`,onResize);function cancelTimers(){countdownTimer&&=(cancelAnimationFrame(countdownTimer),null),delayTimer&&=(clearTimeout(delayTimer),null),startTimer&&=(clearTimeout(startTimer),null),failAnimationTimer&&=(cancelAnimationFrame(failAnimationTimer),null)}function startCountdown(){cancelTimers(),startTimer=setTimeout(()=>{let initialScore=scoreToAdd.value,scoreDwindleAnimDuration=1e3;function countdown(timestamp){countdownStartTime||=timestamp;let elapsedTime=timestamp-countdownStartTime;elapsedTime>=scoreDwindleAnimDuration?(scoreToAdd.value=0,countdownStartTime=null,delayTimer=setTimeout(()=>{scoreToAdd.value=-1,centerMessage.value=null,realtimeScorePoints.value=0,realtimeScoreCombo.value=0,creep.value=0,delayTimer=null},1e3)):(scoreToAdd.value=Math.floor(initialScore*(1-elapsedTime/scoreDwindleAnimDuration)),countdownTimer=requestAnimationFrame(countdown))}countdownTimer=requestAnimationFrame(countdown)},1250)}let thresholds=[-110,-60,-20,0,20,60,110],positions=[-100,-70,-35,0,35,70,100],calculatePosition=(y,thresholds$1,positions$1)=>{let clampedY=Math.max(thresholds$1[0],Math.min(thresholds$1[thresholds$1.length-1],y));for(let i=0;i=thresholds$1[i]&&clampedY<=thresholds$1[i+1]){let t=(clampedY-thresholds$1[i])/(thresholds$1[i+1]-thresholds$1[i]);return positions$1[i]+t*(positions$1[i+1]-positions$1[i])}return 0},performanceBgClass=computed(()=>({"perf-good":steppedPerformanceFactor.value>=3,"perf-warn":steppedPerformanceFactor.value<3})),performanceTransformStyle=computed(()=>{let sRaw=Math.min(steppedPerformanceFactor.value/3,1);return{transform:`scale(${sRaw===0?.001:sRaw})`,transformOrigin:`center bottom`,opacity:sRaw===0?0:1}});function onModifierTransitionEnd(e){e.propertyName===`opacity`&&(isModifierFading.value&&=(currentModifier.value=null,!1))}let comboVarsStyle=computed(()=>({"--combo-glow-color":realtimeScoreCombo.value>=25?`210, 110, 0`:`255, 255, 0`,"--combo-glow-alpha":String(creep.value),"--combo-rect-translate":`${-creep.value*2}rem`}));function ensureBonusTimers(){!bonusDisplayAdd&&bonusQueue.value.length>0&&(bonusDisplayAdd=setInterval(()=>{if(bonusQueue.value.length===0)return;let item=bonusQueue.value.pop();bonusDisplay.value.unshift(item)},500)),!bonusDisplayDispose&&bonusDisplay.value.length>0&&(bonusDisplayDispose=setInterval(()=>{bonusDisplay.value.length>0&&bonusDisplay.value.pop()},1e4)),bonusQueue.value.length===0&&bonusDisplay.value.length===0&&(bonusDisplayAdd&&=(clearInterval(bonusDisplayAdd),null),bonusDisplayDispose&&=(clearInterval(bonusDisplayDispose),null))}return watch(bonusQueue,ensureBonusTimers,{deep:!0}),watch(bonusDisplay,ensureBonusTimers,{deep:!0}),onMounted(()=>{lua.extensions.gameplay_drift_general.onDriftAppMounted()}),onUnmounted(()=>{lua.extensions.gameplay_drift_general.onDriftAppUnmounted()}),(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$178,[createBaseVNode(`div`,_hoisted_2$145,[createBaseVNode(`div`,{class:normalizeClass([`fail-overlay`,{active:isFailActive.value}])},null,2),createBaseVNode(`div`,{class:normalizeClass([`performance-background`,performanceBgClass.value]),style:normalizeStyle(performanceTransformStyle.value)},null,6),centerFailMessage.value?(openBlock(),createElementBlock(`div`,{key:0,class:normalizeClass([`center`,{"fade-out":isCenterMessageFading.value}])},toDisplayString(centerFailMessage.value),3)):centerMessage.value?(openBlock(),createElementBlock(`div`,{key:1,class:normalizeClass([`center`,{"fade-out":isCenterMessageFading.value}])},[createTextVNode(toDisplayString(centerMessage.value)+` `,1),centerMessage.value&&scoreToAdd.value>=0?(openBlock(),createElementBlock(Fragment,{key:0},[createTextVNode(toDisplayString(scoreToAdd.value),1)],64)):createCommentVNode(``,!0)],2)):(openBlock(),createElementBlock(Fragment,{key:2},[createBaseVNode(`div`,_hoisted_3$130,[(openBlock(!0),createElementBlock(Fragment,null,renderList(bonusDisplay.value,(item,index)=>(openBlock(),createElementBlock(`div`,{key:index,class:`score-item`},` +`+toDisplayString(~~item.score),1))),128))]),createBaseVNode(`div`,_hoisted_4$107,[createBaseVNode(`div`,_hoisted_5$92,[(openBlock(),createElementBlock(`div`,{class:normalizeClass([`score-modifier`,{"fade-out":isModifierFading.value}]),key:currentModifier.value,onTransitionend:onModifierTransitionEnd},toDisplayString(currentModifier.value),35)),createBaseVNode(`div`,_hoisted_6$76,toDisplayString(realtimeScorePoints.value),1)]),createBaseVNode(`div`,_hoisted_7$66,[(openBlock(),createElementBlock(`svg`,{id:`svg_${unref(bgId)}`,class:`combo`,viewBox:`0 0 100 30`,style:normalizeStyle([{width:`100%`,height:`3rem`},comboVarsStyle.value]),preserveAspectRatio:`xMinYMid meet`},[createBaseVNode(`defs`,null,[createBaseVNode(`linearGradient`,{id:`grad_${unref(bgId)}`,x1:`0%`,y1:`0%`,x2:`0%`,y2:`100%`},[_cache[0]||=createBaseVNode(`stop`,{offset:`50%`,"stop-color":`var(--bng-ter-yellow-100)`},null,-1),createBaseVNode(`stop`,{offset:`51%`,"stop-color":realtimeScoreCombo.value>=25?`#ff8400`:`#fff`},null,8,_hoisted_10$40),createBaseVNode(`stop`,{offset:`75%`,"stop-color":realtimeScoreCombo.value>=25?`#ff8400`:`#fff`},null,8,_hoisted_11$35)],8,_hoisted_9$47),createBaseVNode(`mask`,{id:`mask_${unref(bgId)}`},[createBaseVNode(`text`,_hoisted_13$24,` ×`+toDisplayString(formattedCombo.value),1)],8,_hoisted_12$27)]),createBaseVNode(`g`,{mask:`url(#mask_${unref(bgId)})`},[createBaseVNode(`rect`,{width:`100%`,height:`4.2rem`,x:`0`,y:`15.5`,fill:`url(#grad_${unref(bgId)})`,class:`animated-rect`},null,8,_hoisted_15$22)],8,_hoisted_14$23)],12,_hoisted_8$53))])])],64))]),createBaseVNode(`div`,_hoisted_16$22,[createBaseVNode(`div`,_hoisted_17$17,[createBaseVNode(`div`,{class:normalizeClass([`bar`,barClass.value]),style:normalizeStyle(barVarsStyle.value)},null,6)])]),createBaseVNode(`div`,_hoisted_18$15,[createBaseVNode(`div`,_hoisted_19$12,[createBaseVNode(`div`,_hoisted_20$11,[createBaseVNode(`div`,{class:`progress-fill`,style:normalizeStyle(driftProgressStyle.value)},null,4)]),(openBlock(),createElementBlock(`div`,{class:`value-marks`,key:layoutVersion.value},[(openBlock(),createElementBlock(Fragment,null,renderList(thresholds,(threshold,index)=>createBaseVNode(`div`,{class:`line`,key:threshold,style:normalizeStyle({position:`absolute`,left:tickLefts.value[index],width:`0.125rem`,height:`0.24rem`,transform:threshold===0?`translateX(-50%)`:threshold>0?`translateX(-100%)`:`translateX(0%)`,backgroundColor:`white`})},null,4)),64))]))]),(openBlock(),createElementBlock(`div`,{class:`drift-labels`,key:layoutVersion.value},[(openBlock(),createElementBlock(Fragment,null,renderList(thresholds,(threshold,index)=>createBaseVNode(`span`,{key:threshold,style:normalizeStyle({position:`absolute`,left:tickLefts.value[index],transform:`translateX(-50%)`,textAlign:`center`})},toDisplayString(threshold===0?`${formattedRealtimeAngle.value}°`:`${Math.abs(threshold)}°`),5)),64))])),props.showFlash?(openBlock(),createBlock(unref(bngFlashMessage_default),{key:0,"message-source":`DriftFlashMessage`})):createCommentVNode(``,!0)])]))}},app_default$13=__plugin_vue_export_helper_default(_sfc_main$198,[[`__scopeId`,`data-v-aa80ede0`]]),_hoisted_1$177={class:`main-container-grid`},_hoisted_2$144={class:`scores-container`},_hoisted_3$129={class:`permanent`},_hoisted_4$106={class:`points-label`},_sfc_main$197={__name:`app`,setup(__props){let events$3=useEvents(),permanentScore=ref(0),potentialScore=ref(0),isAnimatingPotentialScore=ref(!1),dontUpdateScores=ref(!1),lastPotentialScore=ref(0);onMounted(()=>{events$3.on(`setDriftPersistentDriftScored`,(score,combo)=>{isAnimatingPotentialScore.value=!0,dontUpdateScores.value=!0,potentialScore.value=score,lastPotentialScore.value=potentialScore.value,setTimeout(()=>{isAnimatingPotentialScore.value=!1},1e3),setTimeout(()=>{dontUpdateScores.value=!1},900)})}),onUnmounted(()=>{events$3.off(`setDriftPersistentDriftScored`)});let streamsList$1=[`drift`];return useStreams(streamsList$1,streams=>{for(let stream of streamsList$1)if(!streams[stream])return;dontUpdateScores.value||(permanentScore.value=streams.drift.permanentScore,potentialScore.value=streams.drift.potentialScore)}),(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$177,[createBaseVNode(`div`,_hoisted_2$144,[createBaseVNode(`div`,_hoisted_3$129,[createBaseVNode(`span`,_hoisted_4$106,toDisplayString(unref($translate).instant(`missions.drift.general.pointsShort`))+`: `,1),createTextVNode(toDisplayString(permanentScore.value),1)]),createBaseVNode(`div`,{class:normalizeClass([`potential`,{"animate-potential-score":isAnimatingPotentialScore.value}])},` + `+toDisplayString(potentialScore.value),3)])]))}},app_default$14=__plugin_vue_export_helper_default(_sfc_main$197,[[`__scopeId`,`data-v-29f9fe6b`]]),_hoisted_1$176={class:`main-container-grid`},_sfc_main$196={__name:`app`,setup(__props){let{lua}=useBridge(),events$3=useEvents(),showButton=ref(!1),handleNextStep=()=>{lua.gameplay_crashTest_scenarioManager.nextStepFromUI(),showButton.value=!1};return onMounted(()=>{events$3.on(`onCrashTestStepFinished`,()=>{console.log(`onCrashTestStepFinished`),showButton.value=!0})}),onUnmounted(()=>{events$3.off(`onCrashTestStepFinished`)}),(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$176,[showButton.value?(openBlock(),createBlock(unref(bngButton_default),{key:0,onClick:handleNextStep,accent:unref(ACCENTS).text,icon:unref(icons).arrowSolidRight,class:normalizeClass({"next-step-button":!0})},{default:withCtx(()=>[createTextVNode(toDisplayString(unref($translate).instant(`missions.crashTest.general.nextStep`)),1)]),_:1},8,[`accent`,`icon`])):createCommentVNode(``,!0)]))}},app_default$15=__plugin_vue_export_helper_default(_sfc_main$196,[[`__scopeId`,`data-v-6d935866`]]),_hoisted_1$175={class:`bng-app`},_sfc_main$195={__name:`app`,setup(__props){let{$game}=useLibStore(),streamsList$1=[`engineInfo`],data=reactive({engineT:0,wheelT:0,rpm:0,gearText:``});onMounted(()=>$game.streams.add(streamsList$1)),onUnmounted(()=>$game.streams.remove(streamsList$1)),$game.events.on(`onStreamsUpdate`,streams=>{streams.engineInfo!==null&&(data.engineT=$game.units.buildString(`torque`,streams.engineInfo[8],0),data.wheelT=$game.units.buildString(`torque`,streams.engineInfo[19],0),data.rpm=streams.engineInfo[4].toFixed(),data.gearText=getGearText(streams.engineInfo[16],streams.engineInfo[6],streams.engineInfo[7]))});let getGearText=(gear,fGear,rGear)=>gear>0?`F `+gear+` / `+fGear:gear<0?`R `+Math.abs(gear)+` / `+rGear:`N`;return(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$175,[createTextVNode(toDisplayString(_ctx.$t(`ui.apps.engineinfo.rpm`))+`: `+toDisplayString(data.rpm),1),_cache[0]||=createBaseVNode(`br`,null,null,-1),createTextVNode(` `+toDisplayString(_ctx.$t(`ui.apps.engineinfo.gear`))+`: `+toDisplayString(data.gearText),1),_cache[1]||=createBaseVNode(`br`,null,null,-1),createTextVNode(` `+toDisplayString(_ctx.$t(`ui.apps.engineinfo.flywheelTorque`))+`: `+toDisplayString(data.engineT)+` `,1),_cache[2]||=createBaseVNode(`br`,null,null,-1),createTextVNode(` `+toDisplayString(_ctx.$t(`ui.apps.engineinfo.wheelTorque`))+`: `+toDisplayString(data.wheelT),1)]))}},app_default$16=_sfc_main$195,_hoisted_1$174={class:`legends`},_hoisted_2$143={class:`torque-flywheel`},_hoisted_3$128={class:`power-flywheel`},_hoisted_4$105={class:`power-wheels`},_hoisted_5$91={class:`rpm`},_hoisted_6$75={class:`content`},_hoisted_7$65={class:`power-label`},_hoisted_8$52={class:`label`},_hoisted_9$46={class:`canvas-container`},_hoisted_10$39={class:`torque-label`},_hoisted_11$34={class:`label`},tickLabels=21,torqueGraphColor=`#000000`,powerGraphColor=`#FF0000`,powerWheelGraphColor=`#FF4400`,rpmGraphColor=`#0000FF`,_sfc_main$194={__name:`app`,setup(__props){let{$game}=useLibStore(),streamsList$1=[`engineInfo`],app$1=ref(null),canvas=ref(null),globalMax=ref(0),torqueUnit=ref(null),powerUnit=ref(null),tickSpacing=ref(0),tickInterval=computed(()=>globalMax.value/10),appResizeObserver=new ResizeObserver(entries=>{let entry=entries[0];canvas.value.width=entry.target.offsetWidth-130,canvas.value.height=entry.target.offsetHeight-20,tickSpacing.value=canvas.value.height/10,console.log(`width`,entry.target.offsetWidth),console.log(`height`,entry.target.offsetHeight),console.log(`tickspacing`,tickSpacing.value),console.log(`canvas`,canvas.value.width,canvas.value.height)}),chart=new SmoothieChart({minValue:0,maxValue:1e3,millisPerPixel:20,interpolation:`bezier`,grid:{fillStyle:`rgba(250,250,250,0.2)`,strokeStyle:`grey`,verticalSections:20,millisPerLine:1e3,sharpLines:!0},labels:{disabled:!0}}),torqueGraph=new TimeSeries,powerGraph=new TimeSeries,powerWheelGraph=new TimeSeries,rpmGraph=new TimeSeries;onMounted(()=>{initChart(),appResizeObserver.observe(app$1.value),$game.events.on(`onStreamsUpdate`,onStreamsUpdate),$game.streams.add(streamsList$1)}),onBeforeUnmount(()=>{appResizeObserver.unobserve(app$1.value)}),onUnmounted(()=>{$game.events.off(`onStreamsUpdate`,onStreamsUpdate),$game.streams.remove(streamsList$1)});function onStreamsUpdate(streams){for(let stream of streamsList$1)if(!streams[stream])return;let xPoint=new Date,torque=$game.units.torque(streams.engineInfo[8]).val,power$1=$game.units.power(streams.engineInfo[4]*.104719755*streams.engineInfo[8]/1e3*1.34102).val,wheelPower=$game.units.power(streams.engineInfo[20]/1e3*1.34102).val,rpm=streams.engineInfo[4]/10;torqueUnit.value=$game.units.torque().unit,powerUnit.value=$game.units.power().unit,globalMax.value=Math.ceil(Math.max.apply(null,[globalMax.value,torque,power$1])/100)*100,chart.options.maxValue=globalMax.value,torqueGraph.append(xPoint,torque),powerGraph.append(xPoint,power$1),powerWheelGraph.append(xPoint,wheelPower),rpmGraph.append(xPoint,rpm)}function initChart(){chart.addTimeSeries(torqueGraph,{strokeStyle:torqueGraphColor,lineWidth:1.5}),chart.addTimeSeries(powerGraph,{strokeStyle:powerGraphColor,lineWidth:1.5}),chart.addTimeSeries(powerWheelGraph,{strokeStyle:powerWheelGraphColor,lineWidth:1.5}),chart.addTimeSeries(rpmGraph,{strokeStyle:rpmGraphColor,lineWidth:1.5}),chart.streamTo(canvas.value,40)}return(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,{ref_key:`app`,ref:app$1,class:`engine-dynamometer`},[createBaseVNode(`div`,_hoisted_1$174,[createBaseVNode(`small`,_hoisted_2$143,toDisplayString(_ctx.$t(`ui.apps.engine_dynamometer.torqueFlywheel`)),1),createBaseVNode(`small`,_hoisted_3$128,toDisplayString(_ctx.$t(`ui.apps.engine_dynamometer.powerFlywheel`)),1),createBaseVNode(`small`,_hoisted_4$105,toDisplayString(_ctx.$t(`ui.apps.engine_dynamometer.powerWheels`)),1),createBaseVNode(`small`,_hoisted_5$91,toDisplayString(_ctx.$t(`ui.apps.engine_dynamometer.rpm`)),1)]),createBaseVNode(`div`,_hoisted_6$75,[createBaseVNode(`div`,_hoisted_7$65,[createBaseVNode(`div`,_hoisted_8$52,toDisplayString(_ctx.$t(`ui.apps.engine_dynamometer.power`))+` (`+toDisplayString(powerUnit.value)+`) `,1),(openBlock(),createElementBlock(Fragment,null,renderList(tickLabels,(n,index)=>createBaseVNode(`div`,{class:`ruler`,style:normalizeStyle({top:index*tickSpacing.value+`px`})},toDisplayString((globalMax.value-index*tickInterval.value).toFixed(0)),5)),64))]),createBaseVNode(`div`,_hoisted_9$46,[createBaseVNode(`canvas`,{ref_key:`canvas`,ref:canvas,class:`canvas`},null,512)]),createBaseVNode(`div`,_hoisted_10$39,[createBaseVNode(`div`,_hoisted_11$34,toDisplayString(_ctx.$t(`ui.apps.engine_dynamometer.torque`))+` (`+toDisplayString(torqueUnit.value)+`) `,1),(openBlock(),createElementBlock(Fragment,null,renderList(tickLabels,(n,index)=>createBaseVNode(`div`,{class:`ruler`,style:normalizeStyle({top:index*tickSpacing.value+`px`})},toDisplayString((globalMax.value-index*tickInterval.value).toFixed(0)),5)),64))])])],512))}},app_default$17=__plugin_vue_export_helper_default(_sfc_main$194,[[`__scopeId`,`data-v-e025129d`]]),_hoisted_1$173={class:`legends`},_hoisted_2$142={class:`water`},_hoisted_3$127={class:`oil`},_hoisted_4$104={class:`block`},_hoisted_5$90={class:`exhaust`},coolantGraphColor=`#333676`,oilGraphColor=`#AA8C39`,blockGraphColor=`#378B2E`,exhaustGraphColor=`#A7383E`,_sfc_main$193={__name:`app`,setup(__props){let{$game}=useLibStore(),streamsList$1=[`engineThermalData`],app$1=ref(null),canvas=ref(null),isRunning=ref(!1),appResizeObserver=new ResizeObserver(entries=>{let entry=entries[0];canvas.value.width=entry.target.offsetWidth,canvas.value.height=entry.target.offsetHeight}),chart=new SmoothieChart({minValue:50,maxValue:150,millisPerPixel:40,interpolation:`bezier`,grid:{fillStyle:`rgba(250,250,250,0.8)`,strokeStyle:`black`,verticalSections:0,millisPerLine:0},labels:{fillStyle:`black`}}),coolantGraph=new TimeSeries,oilGraph=new TimeSeries,blockGraph=new TimeSeries,exhaustGraph=new TimeSeries;onMounted(()=>{initChart(),appResizeObserver.observe(app$1.value),$game.streams.add(streamsList$1),$game.events.on(`onStreamsUpdate`,onStreamsUpdate)}),onBeforeUnmount(()=>{appResizeObserver.unobserve(app$1.value)}),onUnmounted(()=>{$game.events.off(`onStreamsUpdate`,onStreamsUpdate),$game.streams.remove(streamsList$1)});function onStreamsUpdate(streams){if(streams.engineThermalData){isRunning.value||(isRunning.value=!0,chart.start());let xPoint=new Date;coolantGraph.append(xPoint,streams.engineThermalData.coolantTemperature),oilGraph.append(xPoint,streams.engineThermalData.oilTemperature),blockGraph.append(xPoint,streams.engineThermalData.engineBlockTemperature),exhaustGraph.append(xPoint,streams.engineThermalData.exhaustTemperature)}else isRunning.value&&(isRunning.value=!1,chart.stop())}function initChart(){chart.addTimeSeries(coolantGraph,{strokeStyle:coolantGraphColor,lineWidth:1}),chart.addTimeSeries(oilGraph,{strokeStyle:oilGraphColor,lineWidth:1}),chart.addTimeSeries(blockGraph,{strokeStyle:blockGraphColor,lineWidth:1}),chart.addTimeSeries(exhaustGraph,{strokeStyle:exhaustGraphColor,lineWidth:1}),chart.streamTo(canvas.value,40)}return(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,{ref_key:`app`,ref:app$1,class:`engine-hdg`},[createBaseVNode(`div`,_hoisted_1$173,[createBaseVNode(`small`,_hoisted_2$142,toDisplayString(_ctx.$t(`ui.apps.engine_heat_debug_graph.water`)),1),createBaseVNode(`small`,_hoisted_3$127,toDisplayString(_ctx.$t(`ui.apps.engine_heat_debug_graph.oil`)),1),createBaseVNode(`small`,_hoisted_4$104,toDisplayString(_ctx.$t(`ui.apps.engine_heat_debug_graph.block`)),1),createBaseVNode(`small`,_hoisted_5$90,toDisplayString(_ctx.$t(`ui.apps.engine_heat_debug_graph.exhaust`)),1)]),createBaseVNode(`canvas`,{ref_key:`canvas`,ref:canvas},null,512)],512))}},app_default$18=__plugin_vue_export_helper_default(_sfc_main$193,[[`__scopeId`,`data-v-ac69837e`]]),_hoisted_1$172={class:`bng-app thermal-clutch-debug`},_hoisted_2$141={class:`set-name`},_sfc_main$192={__name:`app`,setup(__props){let{$game}=useLibStore(),streamsList$1=[`engineThermalData`],data=ref(null);onMounted(()=>{$game.streams.add(streamsList$1)}),onUnmounted(()=>{$game.streams.remove(streamsList$1)}),$game.events.on(`onStreamsUpdate`,streams=>data.value=streams.engineThermalData?parseData(streams.engineThermalData):null);function parseData(data$1){return[{str:$game.units.buildString(`temperature`,data$1.coolantTemperature,0),name:`ui.apps.engine_thermal_debug.coolant`,warn:data$1.coolantTemperature>data$1.thermostatTemperature&&data$1.coolantTemperature<120&&data$1.thermostatStatus==1,error:data$1.coolantTemperature>120},{str:$game.units.buildString(`temperature`,data$1.oilTemperature,0),name:`ui.apps.engine_thermal_debug.oil`,warn:data$1.oilTemperature>140,error:data$1.oilTemperature>150},{str:$game.units.buildString(`temperature`,data$1.engineBlockTemperature,0),name:`ui.apps.engine_thermal_debug.block`},{str:$game.units.buildString(`temperature`,data$1.cylinderWallTemperature,0),name:`ui.apps.engine_thermal_debug.cylinderlWall`},{str:$game.units.buildString(`temperature`,data$1.exhaustTemperature,0),name:`ui.apps.engine_thermal_debug.exhaustManifold`},{str:data$1.thermostatStatus.toFixed(3),name:`ui.apps.engine_thermal_debug.coolantThermostat`,warn:data$1.thermostatStatus>.9},{str:data$1.airRegulatorStatus.toFixed(3),name:`ui.apps.engine_thermal_debug.airRegulator`,warn:data$1.airRegulatorStatus>.9},{str:$game.units.buildString(`speed`,data$1.radiatorAirSpeed,0),name:`ui.apps.engine_thermal_debug.radiatorAirSpeed`},{str:data$1.radiatorAirSpeedEfficiency.toFixed(4),name:`ui.apps.engine_thermal_debug.radiatorAirSpeedEfficiency`},{str:data$1.fanActive,name:`ui.apps.engine_thermal_debug.radiatorFanActive`},{str:data$1.coolantMass.toFixed(3),name:`ui.apps.engine_thermal_debug.coolantMass`},{str:data$1.coolantLeakRateOverpressure.toFixed(3),name:`ui.apps.engine_thermal_debug.coolantLeakRateOverpressure`,warn:data$1.coolantLeakRateOverpressure>0},{str:data$1.coolantLeakRateHeadGasket.toFixed(3),name:`ui.apps.engine_thermal_debug.coolantLeakRateHeadGasket`,warn:data$1.coolantLeakRateHeadGasket>0},{str:data$1.coolantLeakRateRadiator.toFixed(3),name:`ui.apps.engine_thermal_debug.coolantLeakRateRadiator`,warn:data$1.coolantLeakRateRadiator>0},{str:data$1.coolantLeakRateOverall.toFixed(3),name:`ui.apps.engine_thermal_debug.coolantLeakRateOverall`,warn:data$1.coolantLeakRateOverall>0},{str:data$1.coolantEfficiency.toFixed(3),name:`ui.apps.engine_thermal_debug.coolantEfficiency`,warn:data$1.coolantEfficiency<1,error:data$1.coolantEfficiency===0},{str:data$1.oilThermostatStatus.toFixed(3),name:`ui.apps.engine_thermal_debug.oilThermostat`,warn:data$1.oilThermostatStatus>.9},{str:data$1.oilMass.toFixed(3),name:`ui.apps.engine_thermal_debug.oilMass`,warn:data$1.oilMassdata$1.maximumSafeOilMass},{str:data$1.miniumSafeOilMass.toFixed(3),name:`ui.apps.engine_thermal_debug.miniumSafeOilMass`},{str:data$1.maximumSafeOilMass.toFixed(3),name:`ui.apps.engine_thermal_debug.maximumSafeOilMass`},{str:data$1.oilLeakRateOilpan.toFixed(3),name:`ui.apps.engine_thermal_debug.oilLeakRateOilpan`,warn:data$1.oilLeakRateOilpan>0},{str:data$1.oilLeakRateRadiator.toFixed(3),name:`ui.apps.engine_thermal_debug.oilLeakRateRadiator`,warn:data$1.oilLeakRateRadiator>0},{str:data$1.oilLeakRateGravity.toFixed(3),name:`ui.apps.engine_thermal_debug.oilLeakRateGravity`,warn:data$1.oilLeakRateGravity>0},{str:data$1.oilLeakRatePistonRingDamage.toFixed(3),name:`ui.apps.engine_thermal_debug.oilLeakRatePistonRingDamage`,warn:data$1.oilLeakRatePistonRingDamage>0},{str:data$1.oilLeakRateOverall.toFixed(3),name:`ui.apps.engine_thermal_debug.oilLeakRateOverall`,warn:data$1.oilLeakRateOverall>0},{str:data$1.oilStarvingSevernessXY.toFixed(3),name:`ui.apps.engine_thermal_debug.oilStarvingSevernessXY`,warn:data$1.oilStarvingSevernessXY>0},{str:data$1.oilStarvingSevernessZ.toFixed(3),name:`ui.apps.engine_thermal_debug.oilStarvingSevernessZ`,warn:data$1.oilStarvingSevernessZ>0},{str:data$1.maximumSafeG.toFixed(3),name:`ui.apps.engine_thermal_debug.maximumSafeG`},{str:data$1.oilLubricationCoef.toFixed(3),name:`ui.apps.engine_thermal_debug.oilLubricationCoef`,warn:data$1.oilLubricationCoef<1},{str:data$1.missingOilDamage.toFixed(3),name:`ui.apps.engine_thermal_debug.missingOilDamage`,warn:data$1.missingOilDamage>0},{str:data$1.engineEfficiency.toFixed(2),name:`ui.apps.engine_thermal_debug.engineEfficiency`},{str:$game.units.buildString(`energy`,data$1.energyToCylinderWall,0),name:`ui.apps.engine_thermal_debug.qtocylinderwall`},{str:$game.units.buildString(`energy`,data$1.energyCylinderWallToCoolant,0),name:`ui.apps.engine_thermal_debug.qcylinderwalltocoolant`},{str:$game.units.buildString(`energy`,data$1.energyCoolantToAir,0),name:`ui.apps.engine_thermal_debug.qcoolanttoair`},{str:$game.units.buildString(`energy`,data$1.energyCoolantToBlock,0),name:`ui.apps.engine_thermal_debug.qcoolanttoblock`},{str:$game.units.buildString(`energy`,data$1.energyCylinderWallToBlock,0),name:`ui.apps.engine_thermal_debug.qcylinderwalltoblock`},{str:$game.units.buildString(`energy`,data$1.energyBlockToAir,0),name:`ui.apps.engine_thermal_debug.qblocktoair`},{str:$game.units.buildString(`energy`,data$1.energyToOil,0),name:`ui.apps.engine_thermal_debug.qtooil`},{str:$game.units.buildString(`energy`,data$1.energyCylinderWallToOil,0),name:`ui.apps.engine_thermal_debug.qcylinderwalltooil`},{str:$game.units.buildString(`energy`,data$1.energyOilToAir,0),name:`ui.apps.engine_thermal_debug.qoilradiatortoair`},{str:$game.units.buildString(`energy`,data$1.energyOilSumpToAir,0),name:`ui.apps.engine_thermal_debug.qoilsumptoair`},{str:$game.units.buildString(`energy`,data$1.energyToExhaust,0),name:`ui.apps.engine_thermal_debug.qtoexhaust`},{str:$game.units.buildString(`energy`,data$1.energyExhaustToAir,0),name:`ui.apps.engine_thermal_debug.qexhausttoair`},{str:data$1.engineBlockOverheatDamage.toFixed(),name:`ui.apps.engine_thermal_debug.blockDamage`,warn:data$1.engineBlockOverheatDamage>0},{str:data$1.oilOverheatDamage.toFixed(),name:`ui.apps.engine_thermal_debug.oilDamage`,warn:data$1.oilOverheatDamage>0},{str:data$1.cylinderWallOverheatDamage.toFixed(),name:`ui.apps.engine_thermal_debug.cylinderwallDamage`,warn:data$1.cylinderWallOverheatDamage>0},{str:data$1.headGasketBlown,name:`ui.apps.engine_thermal_debug.headGasketBlown`,error:data$1.headGasketBlown},{str:data$1.pistonRingsDamaged,name:`ui.apps.engine_thermal_debug.pistonRingsDamaged`,error:data$1.pistonRingsDamaged},{str:data$1.connectingRodBearingsDamaged,name:`ui.apps.engine_thermal_debug.connectingRodBearingsDamaged`,error:data$1.connectingRodBearingsDamaged}]}return(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$172,[(openBlock(!0),createElementBlock(Fragment,null,renderList(data.value,(set,index)=>(openBlock(),createElementBlock(`div`,{key:index,class:`set`},[createBaseVNode(`div`,_hoisted_2$141,toDisplayString(_ctx.$t(set.name)),1),createBaseVNode(`div`,{class:normalizeClass([`set-value`,{"thermal-warning":set.warn,"thermal-error":set.error}])},toDisplayString(set.str),3)]))),128))]))}},app_default$19=__plugin_vue_export_helper_default(_sfc_main$192,[[`__scopeId`,`data-v-6de0b81a`]]),_hoisted_1$171={"xmlns:dc":`http://purl.org/dc/elements/1.1/`,"xmlns:cc":`http://creativecommons.org/ns#`,"xmlns:rdf":`http://www.w3.org/1999/02/22-rdf-syntax-ns#`,"xmlns:svg":`http://www.w3.org/2000/svg`,xmlns:`http://www.w3.org/2000/svg`,"xmlns:xlink":`http://www.w3.org/1999/xlink`,"xmlns:sodipodi":`http://sodipodi.sourceforge.net/DTD/sodipodi-0.dtd`,"xmlns:inkscape":`http://www.inkscape.org/namespaces/inkscape`,version:`1.1`,width:`100%`,height:`100%`,viewBox:`0 0 660 660`},_hoisted_2$140={"inkscape:groupmode":`layer`,id:`layer6`,class:`layer6`,"inkscape:label":`new`,style:{display:`inline`}},_hoisted_3$126={"xml:space":`preserve`,style:{"font-style":`normal`,"font-variant":`normal`,"font-weight":`normal`,"font-stretch":`normal`,"font-size":`159.64709473px`,"line-height":`125%`,"font-family":`'Squada One'`,"-inkscape-font-specification":`'Squada One'`,"text-align":`center`,"letter-spacing":`0px`,"word-spacing":`0px`,"writing-mode":`lr-tb`,"text-anchor":`middle`,display:`inline`,fill:`#ffffff`,"fill-opacity":`1`,stroke:`none`},x:`329.85437`,y:`328.48807`,id:`tspan4449-43`,"sodipodi:linespacing":`125%`,"inkscape:label":`#pressureText`},_hoisted_4$103={"xml:space":`preserve`,style:{"font-style":`normal`,"font-variant":`normal`,"font-weight":`normal`,"font-stretch":`normal`,"font-size":`65px`,"line-height":`125%`,"font-family":`'Squada One'`,"-inkscape-font-specification":`'Squada One'`,"text-align":`center`,"letter-spacing":`0px`,"word-spacing":`0px`,"writing-mode":`lr-tb`,"text-anchor":`middle`,display:`inline`,fill:`#ffffff`,"fill-opacity":`0.78835976`,stroke:`none`},x:`329.03198`,y:`413.62915`,id:`speed_units`,"sodipodi:linespacing":`125%`,"inkscape:label":`#speed_units`,"inkscape:transform-center-y":`-4.486084`},_hoisted_5$89=[`id`,`x`,`y`],_hoisted_6$74=[`id`,`x`,`y`],_hoisted_7$64={"inkscape:groupmode":`layer`,id:`layer3`,"inkscape:label":`FIX`,style:{display:`inline`}},_hoisted_8$51={id:`revcurvemask`,style:{display:`inline`}},_hoisted_9$45={"inkscape:groupmode":`layer`,id:`layer11`,"inkscape:label":`revs`,style:{display:`inline`}},_hoisted_10$38={"inkscape:groupmode":`layer`,id:`layer7`,"inkscape:label":`new2`,style:{display:`inline`}},width=660,height=660,dashSize=5,pressureTextSize=50,dashCount=5,PRESURE_MAX_CONST=150,PRESURE_MIN_CONST=-100,_sfc_main$191={__name:`forcedInduction`,setup(__props,{expose:__expose}){let initialized=ref(!1),pressureTextRef=ref(null),pressureCurveRef=ref(null),pressureCurveLen=computed(()=>pressureCurveRef.value.getTotalLength()),pressureCurveDashesRef=ref(null),pressureCurveDashesLen=computed(()=>pressureCurveDashesRef.value.getTotalLength()),redLineRef=ref(null),redLineLen=computed(()=>redLineRef.value.getTotalLength()),pressureTextGuideLineRef=ref(null),pressureTextGuideLineLen=computed(()=>pressureTextGuideLineRef.value.getTotalLength()),pressureTextRefs=ref([]),pressureTextAttrs=ref([{id:`pressuretext1`,x:197.49423,y:531.5639,text:1},{id:`pressuretext2`,x:124.71793,y:434.92328,text:2},{id:`pressuretext3`,x:110.04411,y:303.35791,text:3},{id:`pressuretext4`,x:165.89227,y:187.39682,text:4},{id:`pressuretext5`,x:284.48657,y:123.71478,text:5},{id:`pressuretext6`,x:419.43579,y:137.55835,text:6},{id:`pressuretext7`,x:520.0791,y:228.94992,text:7},{id:`pressuretext8`,x:520.0791,y:228.94992,text:8},{id:`pressuretext9`,x:520.0791,y:228.94992,text:9},{id:`pressuretext10`,x:520.0791,y:228.94992,text:10}]),pressureTSpanRefs=ref([]),pressureMax=ref(null),pressureMin=ref(null),pressureNeedleRef=ref(null),pressureUnitRef=ref(null),UiUnitscallback=ref(()=>null),roundDecCallback=ref(()=>0);onMounted(()=>{pressureTextRef.value.textContent=``,pressureCurveRef.value.style.strokeDasharray=pressureCurveLen.value+` `+pressureCurveLen.value,pressureTextGuideLineRef.value.style.display=`none`;for(let k=0;k10?0:1),rpSpan.style.visibility=`visible`}initialized.value=!0}applyData(streamData)}function reset$1(){initialized.value=!1;for(let k=0;k1&&(percPos=1),pressureNeedleRef.value.setAttribute(`transform`,`rotate(`+(percPos*270-135)+`,`+width/2+`,`+height/2+`)`),pressureCurveRef.value.style.strokeDashoffset=pressureCurveLen.value-pressureCurveLen.value*percPos}function UnitPressure(val){let convertedVal=UiUnitscallback.value(val,`pressure`);return pressureNeedleRef.value.textContent!==convertedVal.unit&&(pressureUnitRef.value.textContent=convertedVal.unit,initialized.value=!1),convertedVal.val}return(_ctx,_cache)=>(openBlock(),createElementBlock(`svg`,_hoisted_1$171,[_cache[4]||=createBaseVNode(`defs`,{id:`defs4`},[createBaseVNode(`linearGradient`,{id:`linearGradient3938`},[createBaseVNode(`stop`,{style:{"stop-color":`#ff0000`,"stop-opacity":`1`},offset:`0`,id:`stop3940`}),createBaseVNode(`stop`,{style:{"stop-color":`#00ff4b`,"stop-opacity":`1`},offset:`1`,id:`stop3942`})]),createBaseVNode(`linearGradient`,{id:`linearGradient4607`},[createBaseVNode(`stop`,{id:`stop4609`,offset:`0`,style:{"stop-color":`#e40000`,"stop-opacity":`1`}}),createBaseVNode(`stop`,{style:{"stop-color":`#e40000`,"stop-opacity":`1`},offset:`0.89960396`,id:`stop4611`}),createBaseVNode(`stop`,{id:`stop4613`,offset:`1`,style:{"stop-color":`#e40000`,"stop-opacity":`0`}}),createBaseVNode(`stop`,{id:`stop4615`,offset:`1`,style:{"stop-color":`#e40000`,"stop-opacity":`0`}})]),createBaseVNode(`linearGradient`,{id:`linearGradient4597`},[createBaseVNode(`stop`,{id:`stop4599`,offset:`0`,style:{"stop-color":`#e40000`,"stop-opacity":`1`}}),createBaseVNode(`stop`,{style:{"stop-color":`#e40000`,"stop-opacity":`1`},offset:`0.99812102`,id:`stop4601`}),createBaseVNode(`stop`,{id:`stop4603`,offset:`1`,style:{"stop-color":`#e40000`,"stop-opacity":`0`}}),createBaseVNode(`stop`,{id:`stop4605`,offset:`1`,style:{"stop-color":`#e40000`,"stop-opacity":`1`}})]),createBaseVNode(`linearGradient`,{id:`linearGradient4545`},[createBaseVNode(`stop`,{style:{"stop-color":`#e40000`,"stop-opacity":`1`},offset:`0`,id:`stop4547`}),createBaseVNode(`stop`,{id:`stop4553`,offset:`0.9861111`,style:{"stop-color":`#e40000`,"stop-opacity":`1`}}),createBaseVNode(`stop`,{style:{"stop-color":`#e40000`,"stop-opacity":`0`},offset:`1`,id:`stop4555`}),createBaseVNode(`stop`,{style:{"stop-color":`#e40000`,"stop-opacity":`0`},offset:`1`,id:`stop4549`})]),createBaseVNode(`linearGradient`,{"inkscape:collect":`always`,id:`linearGradient4256`},[createBaseVNode(`stop`,{style:{"stop-color":`#6d0000`,"stop-opacity":`1`},offset:`0`,id:`stop4258`}),createBaseVNode(`stop`,{style:{"stop-color":`#6d0000`,"stop-opacity":`0`},offset:`1`,id:`stop4260`})]),createBaseVNode(`linearGradient`,{id:`linearGradient4365`},[createBaseVNode(`stop`,{style:{"stop-color":`#000000`,"stop-opacity":`0.42857143`},offset:`0`,id:`stop4367`}),createBaseVNode(`stop`,{id:`stop4373`,offset:`0.5`,style:{"stop-color":`#000000`,"stop-opacity":`0.33035713`}}),createBaseVNode(`stop`,{style:{"stop-color":`#000000`,"stop-opacity":`0`},offset:`1`,id:`stop4369`})]),createBaseVNode(`linearGradient`,{id:`linearGradient4357`},[createBaseVNode(`stop`,{style:{"stop-color":`#000000`,"stop-opacity":`1`},offset:`0`,id:`stop4359`}),createBaseVNode(`stop`,{style:{"stop-color":`#000000`,"stop-opacity":`0.19642857`},offset:`1`,id:`stop4361`})]),createBaseVNode(`marker`,{style:{overflow:`visible`},id:`DistanceStart`,refX:`0`,refY:`0`,orient:`auto`,"inkscape:stockid":`DistanceStart`},[createBaseVNode(`g`,{id:`g2300`},[createBaseVNode(`path`,{style:{fill:`none`,stroke:`#ffffff`,"stroke-width":`1.14999998`,"stroke-linecap":`square`},d:`M 0,0 2,0`,id:`path2306`,"inkscape:connector-curvature":`0`}),createBaseVNode(`path`,{style:{fill:`#000000`,"fill-rule":`evenodd`,stroke:`none`},d:`M 0,0 13,4 9,0 13,-4 0,0 z`,id:`path2302`,"inkscape:connector-curvature":`0`}),createBaseVNode(`path`,{style:{fill:`none`,stroke:`#000000`,"stroke-width":`1`,"stroke-linecap":`square`},d:`M 0,-4 0,40`,id:`path2304`,"inkscape:connector-curvature":`0`})])]),createBaseVNode(`radialGradient`,{"inkscape:collect":`always`,"xlink:href":`#linearGradient4357`,id:`radialGradient4363`,cx:`480`,cy:`544`,fx:`480`,fy:`544`,r:`320`,gradientUnits:`userSpaceOnUse`,gradientTransform:`matrix(1.03125,0,0,1.03125,-15,-17)`}),createBaseVNode(`radialGradient`,{"inkscape:collect":`always`,"xlink:href":`#linearGradient4365`,id:`radialGradient4371`,cx:`480`,cy:`544`,fx:`480`,fy:`544`,r:`320`,gradientUnits:`userSpaceOnUse`}),createBaseVNode(`clipPath`,{clipPathUnits:`userSpaceOnUse`,id:`clipPath4407`},[createBaseVNode(`path`,{"inkscape:connector-curvature":`0`,id:`path4409`,d:`m 480,-103.33 c -357.5105,0 -647.33,289.8195 -647.33,647.33 0,357.5105 289.8195,647.33 647.33,647.33 357.5105,0 647.33,-289.8195 647.33,-647.33 0,-357.5105 -289.8195,-647.33 -647.33,-647.33 z m 0,453.131 c 107.25316,0 194.199,86.94584 194.199,194.199 0,107.25316 -86.94584,194.199 -194.199,194.199 -107.25316,0 -194.199,-86.94584 -194.199,-194.199 0,-107.25316 86.94584,-194.199 194.199,-194.199 z`,style:{color:`#000000`,fill:`#ffffff`,"fill-opacity":`0.61375661`,"fill-rule":`nonzero`,stroke:`none`,"stroke-width":`16`,marker:`none`,visibility:`visible`,display:`inline`,overflow:`visible`,"enable-background":`accumulate`}})]),createBaseVNode(`clipPath`,{clipPathUnits:`userSpaceOnUse`,id:`clipPath4321-9`},[createBaseVNode(`path`,{style:{color:`#000000`,fill:`#ffffff`,"fill-opacity":`1`,"fill-rule":`nonzero`,stroke:`none`,"stroke-width":`5`,marker:`none`,visibility:`visible`,display:`inline`,overflow:`visible`,"enable-background":`accumulate`},d:`m 480,224 c -20.28024,0 -40.11069,1.89279 -59.34375,5.5 l 12.0625,58.8125 C 448.05208,285.49499 463.85489,284 480,284 c 35.52728,0 69.40254,7.13112 100.25,20.03125 l 24.1875,-54.9375 C 566.18747,232.93508 524.13347,224 480,224 z m -69.0625,7.5 c -59.26533,13.0371 -112.35258,42.49901 -154.28125,83.375 l 42.53125,42.3125 c 24.37935,-23.60266 53.35266,-42.49216 85.46875,-55.15625 1.96795,-0.77601 3.94641,-1.52096 5.9375,-2.25 10.51172,-3.84886 21.33856,-7.01901 32.4375,-9.5 L 410.9375,231.5 z M 613.5,253.125 589.3125,308.03125 c 44.07702,20.45389 81.43119,52.91567 107.9375,93.15625 l 50.875,-31.875 C 715.25578,318.96815 668.59379,278.45303 613.5,253.125 z m -363.8125,68.75 c -41.23795,42.75016 -70.70543,96.92973 -83.125,157.34375 l 59.03125,11.0625 c 10.15322,-48.33557 33.70357,-91.7229 66.625,-126.09375 L 249.6875,321.875 z m 503.78125,55.8125 -50.90625,31.84375 C 726.31882,448.76688 740,494.78478 740,544 l 60,0 c 0,-60.90677 -16.99384,-117.84887 -46.53125,-166.3125 z m -588.75,111.25 C 161.61652,506.82573 160,525.2248 160,544 c 0,42.78463 8.42108,83.60181 23.65625,120.90625 L 238.84375,641.375 C 226.69144,611.30216 220,578.42944 220,544 c 0,-2.24366 0.0373,-4.48871 0.0937,-6.71875 0.3211,-12.67426 1.55282,-25.12039 3.625,-37.28125 l -59,-11.0625 z M 242.75,650.5 187.53125,674 c 23.4008,52.56805 60.5346,97.67196 106.875,130.71875 l 34.0625,-49.4375 C 291.42063,728.66516 261.6562,692.55546 242.75,650.5 z m 93.875,110.40625 -34.03125,49.40625 C 353.37348,844.20872 414.36502,864 480,864 l 0,-60 c -33.65485,0 -65.82451,-6.39115 -95.34375,-18.03125 -1.96795,-0.77601 -3.93088,-1.58396 -5.875,-2.40625 -14.80462,-6.26183 -28.90394,-13.88046 -42.15625,-22.65625 z`,id:`path4323-8`,"inkscape:connector-curvature":`0`})]),createBaseVNode(`radialGradient`,{"inkscape:collect":`always`,"xlink:href":`#linearGradient4357`,id:`radialGradient4363-9`,cx:`480`,cy:`544`,fx:`480`,fy:`544`,r:`320`,gradientUnits:`userSpaceOnUse`,gradientTransform:`matrix(1.03125,0,0,1.03125,-15,-17)`}),createBaseVNode(`clipPath`,{clipPathUnits:`userSpaceOnUse`,id:`clipPath4407-3`},[createBaseVNode(`path`,{"inkscape:connector-curvature":`0`,id:`path4409-5`,d:`m 480,-103.33 c -357.5105,0 -647.33,289.8195 -647.33,647.33 0,357.5105 289.8195,647.33 647.33,647.33 357.5105,0 647.33,-289.8195 647.33,-647.33 0,-357.5105 -289.8195,-647.33 -647.33,-647.33 z m 0,453.131 c 107.25316,0 194.199,86.94584 194.199,194.199 0,107.25316 -86.94584,194.199 -194.199,194.199 -107.25316,0 -194.199,-86.94584 -194.199,-194.199 0,-107.25316 86.94584,-194.199 194.199,-194.199 z`,style:{color:`#000000`,fill:`#ffffff`,"fill-opacity":`0.61375661`,"fill-rule":`nonzero`,stroke:`none`,"stroke-width":`16`,marker:`none`,visibility:`visible`,display:`inline`,overflow:`visible`,"enable-background":`accumulate`}})]),createBaseVNode(`radialGradient`,{gradientTransform:`matrix(0.37015162,0,0,0.37015162,685.90181,-270.76027)`,"inkscape:collect":`always`,"xlink:href":`#linearGradient4365`,id:`radialGradient4371-4`,cx:`480`,cy:`544`,fx:`480`,fy:`544`,r:`320`,gradientUnits:`userSpaceOnUse`}),createBaseVNode(`linearGradient`,{"inkscape:collect":`always`,"xlink:href":`#linearGradient4256`,id:`linearGradient4433`,gradientUnits:`userSpaceOnUse`,x1:`569.20557`,y1:`424.29861`,x2:`890.55139`,y2:`424.29861`}),createBaseVNode(`clipPath`,{clipPathUnits:`userSpaceOnUse`,id:`clipPath4321-4`},[createBaseVNode(`path`,{style:{color:`#000000`,fill:`#ffffff`,"fill-opacity":`1`,"fill-rule":`nonzero`,stroke:`none`,"stroke-width":`5`,marker:`none`,visibility:`visible`,display:`inline`,overflow:`visible`,"enable-background":`accumulate`},d:`m 480,224 c -20.28024,0 -40.11069,1.89279 -59.34375,5.5 l 12.0625,58.8125 C 448.05208,285.49499 463.85489,284 480,284 c 35.52728,0 69.40254,7.13112 100.25,20.03125 l 24.1875,-54.9375 C 566.18747,232.93508 524.13347,224 480,224 z m -69.0625,7.5 c -59.26533,13.0371 -112.35258,42.49901 -154.28125,83.375 l 42.53125,42.3125 c 24.37935,-23.60266 53.35266,-42.49216 85.46875,-55.15625 1.96795,-0.77601 3.94641,-1.52096 5.9375,-2.25 10.51172,-3.84886 21.33856,-7.01901 32.4375,-9.5 L 410.9375,231.5 z M 613.5,253.125 589.3125,308.03125 c 44.07702,20.45389 81.43119,52.91567 107.9375,93.15625 l 50.875,-31.875 C 715.25578,318.96815 668.59379,278.45303 613.5,253.125 z m -363.8125,68.75 c -41.23795,42.75016 -70.70543,96.92973 -83.125,157.34375 l 59.03125,11.0625 c 10.15322,-48.33557 33.70357,-91.7229 66.625,-126.09375 L 249.6875,321.875 z m 503.78125,55.8125 -50.90625,31.84375 C 726.31882,448.76688 740,494.78478 740,544 l 60,0 c 0,-60.90677 -16.99384,-117.84887 -46.53125,-166.3125 z m -588.75,111.25 C 161.61652,506.82573 160,525.2248 160,544 c 0,42.78463 8.42108,83.60181 23.65625,120.90625 L 238.84375,641.375 C 226.69144,611.30216 220,578.42944 220,544 c 0,-2.24366 0.0373,-4.48871 0.0937,-6.71875 0.3211,-12.67426 1.55282,-25.12039 3.625,-37.28125 l -59,-11.0625 z M 242.75,650.5 187.53125,674 c 23.4008,52.56805 60.5346,97.67196 106.875,130.71875 l 34.0625,-49.4375 C 291.42063,728.66516 261.6562,692.55546 242.75,650.5 z m 93.875,110.40625 -34.03125,49.40625 C 353.37348,844.20872 414.36502,864 480,864 l 0,-60 c -33.65485,0 -65.82451,-6.39115 -95.34375,-18.03125 -1.96795,-0.77601 -3.93088,-1.58396 -5.875,-2.40625 -14.80462,-6.26183 -28.90394,-13.88046 -42.15625,-22.65625 z`,id:`path4323-7`,"inkscape:connector-curvature":`0`})]),createBaseVNode(`radialGradient`,{"inkscape:collect":`always`,"xlink:href":`#linearGradient4357`,id:`radialGradient4363-5`,cx:`480`,cy:`544`,fx:`480`,fy:`544`,r:`320`,gradientUnits:`userSpaceOnUse`,gradientTransform:`matrix(1.03125,0,0,1.03125,-15,-17)`}),createBaseVNode(`clipPath`,{clipPathUnits:`userSpaceOnUse`,id:`clipPath4407-6`},[createBaseVNode(`path`,{"inkscape:connector-curvature":`0`,id:`path4409-1`,d:`m 480,-103.33 c -357.5105,0 -647.33,289.8195 -647.33,647.33 0,357.5105 289.8195,647.33 647.33,647.33 357.5105,0 647.33,-289.8195 647.33,-647.33 0,-357.5105 -289.8195,-647.33 -647.33,-647.33 z m 0,453.131 c 107.25316,0 194.199,86.94584 194.199,194.199 0,107.25316 -86.94584,194.199 -194.199,194.199 -107.25316,0 -194.199,-86.94584 -194.199,-194.199 0,-107.25316 86.94584,-194.199 194.199,-194.199 z`,style:{color:`#000000`,fill:`#ffffff`,"fill-opacity":`0.61375661`,"fill-rule":`nonzero`,stroke:`none`,"stroke-width":`16`,marker:`none`,visibility:`visible`,display:`inline`,overflow:`visible`,"enable-background":`accumulate`}})]),createBaseVNode(`radialGradient`,{gradientTransform:`matrix(0.36968813,0,0,0.36968813,1026.9451,-270.68256)`,"inkscape:collect":`always`,"xlink:href":`#linearGradient4365`,id:`radialGradient4371-49`,cx:`480`,cy:`544`,fx:`480`,fy:`544`,r:`320`,gradientUnits:`userSpaceOnUse`}),createBaseVNode(`linearGradient`,{"inkscape:collect":`always`,"xlink:href":`#linearGradient4256`,id:`linearGradient4746`,gradientUnits:`userSpaceOnUse`,x1:`569.20557`,y1:`424.29861`,x2:`890.55139`,y2:`424.29861`}),createBaseVNode(`clipPath`,{clipPathUnits:`userSpaceOnUse`,id:`clipPath3921`},[createBaseVNode(`path`,{"inkscape:connector-curvature":`0`,id:`path3923`,d:`m 480,224 c -20.95323,0 -41.43416,2.01857 -61.26367,5.86328 l 12.08008,58.80274 C 446.74495,285.61583 463.18224,284 480,284 c 36.22419,0 70.7135,7.41519 102.04492,20.79883 l 24.1836,-54.92188 C 567.49749,233.23259 524.82925,224 480,224 z m -67.13867,7.07812 c -60.69914,12.96113 -115.01734,43.12659 -157.60938,85.15821 l 42.54297,42.3125 c 34.42536,-33.82645 78.22177,-58.13556 127.14258,-68.68555 l -12.07617,-58.78516 z m 198.86328,21.20508 -24.1875,54.9336 c 45.44422,20.67199 83.88358,54.04459 110.80078,95.58008 l 50.87305,-31.84376 C 715.93577,319.29347 668.20331,277.82636 611.72461,252.2832 z m -360.70117,68.21094 c -42.37565,43.40627 -72.5223,98.80082 -84.8418,160.63281 l 58.99024,11.05664 c 10.06229,-49.7524 34.33605,-94.34359 68.39257,-129.3789 l -42.54101,-42.31055 z m 501.3789,55.54102 -50.86132,31.83398 C 725.92383,447.46544 740,494.08649 740,544 l 60,0 C 800,482.39079 782.57195,424.85952 752.40234,376.03516 z M 165.06055,487.02148 C 161.7373,505.51211 160,524.55271 160,544 c 0,43.47625 8.68492,84.91949 24.39062,122.71094 l 55.21485,-23.5293 C 226.98058,612.61583 220,579.12541 220,544 c 0,-15.6701 1.38639,-31.01527 4.04297,-45.92188 l -58.98242,-11.05664 z m 76.90039,161.67774 -55.20899,23.52734 c 23.61428,53.92719 61.65397,100.09134 109.25586,133.60352 l 34.03516,-49.41406 C 291.73258,729.3212 261.08736,692.12046 241.96094,648.69922 z m 93.01953,111.12695 -34.04102,49.42188 C 352.04051,843.81227 413.66249,864 480,864 l 0,-60 c -53.69777,0 -103.59151,-16.28243 -145.01953,-44.17383 z`,style:{color:`#000000`,fill:`#ffffff`,"fill-opacity":`1`,"fill-rule":`nonzero`,stroke:`none`,"stroke-width":`5`,marker:`none`,visibility:`visible`,display:`inline`,overflow:`visible`,"enable-background":`accumulate`}})]),createBaseVNode(`clipPath`,{clipPathUnits:`userSpaceOnUse`,id:`clipPath3925-1`},[createBaseVNode(`path`,{"inkscape:connector-curvature":`0`,id:`path3927-7`,d:`m 330,10 c -20.95323,0 -41.43416,2.01857 -61.26367,5.86328 l 12.08008,58.80274 C 296.74495,71.61583 313.18224,70 330,70 c 36.22419,0 70.7135,7.41519 102.04492,20.79883 l 24.1836,-54.92188 C 417.49749,19.23259 374.82925,10 330,10 z m -67.13867,7.07812 C 202.16219,30.03925 147.84399,60.20471 105.25195,102.23633 l 42.54297,42.3125 C 182.22028,110.72238 226.01669,86.41327 274.9375,75.86328 L 262.86133,17.07812 z m 198.86328,21.20508 -24.1875,54.9336 c 45.44422,20.67199 83.88358,54.04459 110.80078,95.58008 l 50.87305,-31.84376 C 565.93577,105.29347 518.20331,63.82636 461.72461,38.2832 z m -360.70117,68.21094 c -42.37565,43.40627 -72.5223,98.80082 -84.8418,160.63281 l 58.99024,11.05664 c 10.06229,-49.7524 34.33605,-94.34359 68.39257,-129.3789 l -42.54101,-42.31055 z m 501.3789,55.54102 -50.86132,31.83398 C 575.92383,233.46544 590,280.08649 590,330 l 60,0 C 650,268.39079 632.57195,210.85952 602.40234,162.03516 z M 15.06055,273.02148 C 11.7373,291.51211 10,310.55271 10,330 c 0,43.47625 8.68492,84.91949 24.39062,122.71094 l 55.21485,-23.5293 C 76.98058,398.61583 70,365.12541 70,330 c 0,-15.6701 1.38639,-31.01527 4.04297,-45.92188 L 15.06055,273.02148 z m 76.90039,161.67774 -55.20899,23.52734 c 23.61428,53.92719 61.65397,100.09134 109.25586,133.60352 l 34.03516,-49.41406 C 141.73258,515.3212 111.08736,478.12046 91.96094,434.69922 z m 93.01953,111.12695 -34.04102,49.42188 C 202.04051,629.81227 263.66249,650 330,650 l 0,-60 c -53.69777,0 -103.59151,-16.28243 -145.01953,-44.17383 z`,style:{color:`#000000`,fill:`#ffffff`,"fill-opacity":`1`,"fill-rule":`nonzero`,stroke:`none`,"stroke-width":`5`,marker:`none`,visibility:`visible`,display:`inline`,overflow:`visible`,"enable-background":`accumulate`}})]),createBaseVNode(`clipPath`,{clipPathUnits:`userSpaceOnUse`,id:`clipPath4036`},[createBaseVNode(`path`,{style:{color:`#000000`,fill:`#ffffff`,"fill-opacity":`1`,"fill-rule":`nonzero`,stroke:`none`,"stroke-width":`5`,marker:`none`,visibility:`visible`,display:`inline`,overflow:`visible`,"enable-background":`accumulate`},d:`m 480,224 c -20.95323,0 -41.43416,2.01857 -61.26367,5.86328 l 12.08008,58.80274 C 446.74495,285.61583 463.18224,284 480,284 c 36.22419,0 70.7135,7.41519 102.04492,20.79883 l 24.1836,-54.92188 C 567.49749,233.23259 524.82925,224 480,224 z m -67.13867,7.07812 c -60.69914,12.96113 -115.01734,43.12659 -157.60938,85.15821 l 42.54297,42.3125 c 34.42536,-33.82645 78.22177,-58.13556 127.14258,-68.68555 l -12.07617,-58.78516 z m 198.86328,21.20508 -24.1875,54.9336 c 45.44422,20.67199 83.88358,54.04459 110.80078,95.58008 l 50.87305,-31.84376 C 715.93577,319.29347 668.20331,277.82636 611.72461,252.2832 z m -360.70117,68.21094 c -42.37565,43.40627 -72.5223,98.80082 -84.8418,160.63281 l 58.99024,11.05664 c 10.06229,-49.7524 34.33605,-94.34359 68.39257,-129.3789 l -42.54101,-42.31055 z m 501.3789,55.54102 -50.86132,31.83398 C 725.92383,447.46544 740,494.08649 740,544 l 60,0 C 800,482.39079 782.57195,424.85952 752.40234,376.03516 z M 165.06055,487.02148 C 161.7373,505.51211 160,524.55271 160,544 c 0,43.47625 8.68492,84.91949 24.39062,122.71094 l 55.21485,-23.5293 C 226.98058,612.61583 220,579.12541 220,544 c 0,-15.6701 1.38639,-31.01527 4.04297,-45.92188 l -58.98242,-11.05664 z m 76.90039,161.67774 -55.20899,23.52734 c 23.61428,53.92719 61.65397,100.09134 109.25586,133.60352 l 34.03516,-49.41406 C 291.73258,729.3212 261.08736,692.12046 241.96094,648.69922 z m 93.01953,111.12695 -34.04102,49.42188 C 352.04051,843.81227 413.66249,864 480,864 l 0,-60 c -53.69777,0 -103.59151,-16.28243 -145.01953,-44.17383 z`,id:`path4038`,"inkscape:connector-curvature":`0`})]),createBaseVNode(`linearGradient`,{"inkscape:collect":`always`,"xlink:href":`#linearGradient4545`,id:`linearGradient4551`,x1:`480`,y1:`214`,x2:`480`,y2:`474`,gradientUnits:`userSpaceOnUse`}),createBaseVNode(`linearGradient`,{"inkscape:collect":`always`,"xlink:href":`#linearGradient4545-2`,id:`linearGradient4551-8`,x1:`480`,y1:`214`,x2:`480`,y2:`474`,gradientUnits:`userSpaceOnUse`}),createBaseVNode(`linearGradient`,{id:`linearGradient4545-2`},[createBaseVNode(`stop`,{style:{"stop-color":`#e40000`,"stop-opacity":`1`},offset:`0`,id:`stop4547-4`}),createBaseVNode(`stop`,{id:`stop4553-5`,offset:`0.99000001`,style:{"stop-color":`#e40000`,"stop-opacity":`0`}}),createBaseVNode(`stop`,{style:{"stop-color":`#000000`,"stop-opacity":`0`},offset:`1`,id:`stop4555-5`}),createBaseVNode(`stop`,{style:{"stop-color":`#000000`,"stop-opacity":`0`},offset:`1`,id:`stop4549-1`})]),createBaseVNode(`linearGradient`,{y2:`282.59341`,x2:`474.60886`,y1:`211.1199`,x1:`480`,gradientUnits:`userSpaceOnUse`,id:`linearGradient4574`,"xlink:href":`#linearGradient4607`,"inkscape:collect":`always`,gradientTransform:`matrix(1,0,0,0.9882541,0,10.359887)`}),createBaseVNode(`clipPath`,{clipPathUnits:`userSpaceOnUse`,id:`clipPath4036-1`},[createBaseVNode(`path`,{style:{color:`#000000`,fill:`#ffffff`,"fill-opacity":`1`,"fill-rule":`nonzero`,stroke:`none`,"stroke-width":`5`,marker:`none`,visibility:`visible`,display:`inline`,overflow:`visible`,"enable-background":`accumulate`},d:`m 480,224 c -20.95323,0 -41.43416,2.01857 -61.26367,5.86328 l 12.08008,58.80274 C 446.74495,285.61583 463.18224,284 480,284 c 36.22419,0 70.7135,7.41519 102.04492,20.79883 l 24.1836,-54.92188 C 567.49749,233.23259 524.82925,224 480,224 z m -67.13867,7.07812 c -60.69914,12.96113 -115.01734,43.12659 -157.60938,85.15821 l 42.54297,42.3125 c 34.42536,-33.82645 78.22177,-58.13556 127.14258,-68.68555 l -12.07617,-58.78516 z m 198.86328,21.20508 -24.1875,54.9336 c 45.44422,20.67199 83.88358,54.04459 110.80078,95.58008 l 50.87305,-31.84376 C 715.93577,319.29347 668.20331,277.82636 611.72461,252.2832 z m -360.70117,68.21094 c -42.37565,43.40627 -72.5223,98.80082 -84.8418,160.63281 l 58.99024,11.05664 c 10.06229,-49.7524 34.33605,-94.34359 68.39257,-129.3789 l -42.54101,-42.31055 z m 501.3789,55.54102 -50.86132,31.83398 C 725.92383,447.46544 740,494.08649 740,544 l 60,0 C 800,482.39079 782.57195,424.85952 752.40234,376.03516 z M 165.06055,487.02148 C 161.7373,505.51211 160,524.55271 160,544 c 0,43.47625 8.68492,84.91949 24.39062,122.71094 l 55.21485,-23.5293 C 226.98058,612.61583 220,579.12541 220,544 c 0,-15.6701 1.38639,-31.01527 4.04297,-45.92188 l -58.98242,-11.05664 z m 76.90039,161.67774 -55.20899,23.52734 c 23.61428,53.92719 61.65397,100.09134 109.25586,133.60352 l 34.03516,-49.41406 C 291.73258,729.3212 261.08736,692.12046 241.96094,648.69922 z m 93.01953,111.12695 -34.04102,49.42188 C 352.04051,843.81227 413.66249,864 480,864 l 0,-60 c -53.69777,0 -103.59151,-16.28243 -145.01953,-44.17383 z`,id:`path4038-7`,"inkscape:connector-curvature":`0`})]),createBaseVNode(`radialGradient`,{"inkscape:collect":`always`,"xlink:href":`#linearGradient4357-0`,id:`radialGradient4363-4`,cx:`480`,cy:`544`,fx:`480`,fy:`544`,r:`320`,gradientUnits:`userSpaceOnUse`,gradientTransform:`matrix(1.03125,0,0,1.03125,-15,-17)`}),createBaseVNode(`linearGradient`,{id:`linearGradient4357-0`},[createBaseVNode(`stop`,{style:{"stop-color":`#000000`,"stop-opacity":`0.65178573`},offset:`0`,id:`stop4359-9`}),createBaseVNode(`stop`,{style:{"stop-color":`#000000`,"stop-opacity":`0.24107143`},offset:`1`,id:`stop4361-4`})]),createBaseVNode(`radialGradient`,{"inkscape:collect":`always`,"xlink:href":`#linearGradient4365-4`,id:`radialGradient4371-2`,cx:`480`,cy:`544`,fx:`480`,fy:`544`,r:`320`,gradientUnits:`userSpaceOnUse`}),createBaseVNode(`linearGradient`,{id:`linearGradient4365-4`},[createBaseVNode(`stop`,{style:{"stop-color":`#000000`,"stop-opacity":`0.42857143`},offset:`0`,id:`stop4367-5`}),createBaseVNode(`stop`,{id:`stop4373-5`,offset:`0.5`,style:{"stop-color":`#000000`,"stop-opacity":`0.33035713`}}),createBaseVNode(`stop`,{style:{"stop-color":`#000000`,"stop-opacity":`0`},offset:`1`,id:`stop4369-1`})]),createBaseVNode(`radialGradient`,{r:`320`,fy:`544`,fx:`480`,cy:`544`,cx:`480`,gradientUnits:`userSpaceOnUse`,id:`radialGradient3997`,"xlink:href":`#linearGradient4365-4`,"inkscape:collect":`always`}),createBaseVNode(`radialGradient`,{"inkscape:collect":`always`,"xlink:href":`#linearGradient4357-0-7`,id:`radialGradient4363-4-1`,cx:`480`,cy:`544`,fx:`480`,fy:`544`,r:`320`,gradientUnits:`userSpaceOnUse`,gradientTransform:`matrix(1.03125,0,0,1.03125,-15,-17)`}),createBaseVNode(`linearGradient`,{id:`linearGradient4357-0-7`},[createBaseVNode(`stop`,{style:{"stop-color":`#000000`,"stop-opacity":`0.51785713`},offset:`0`,id:`stop4359-9-4`}),createBaseVNode(`stop`,{style:{"stop-color":`#000000`,"stop-opacity":`0.11607143`},offset:`1`,id:`stop4361-4-0`})]),createBaseVNode(`radialGradient`,{r:`320`,fy:`544`,fx:`480`,cy:`544`,cx:`480`,gradientTransform:`matrix(1.03125,0,0,1.03125,-15,-17)`,gradientUnits:`userSpaceOnUse`,id:`radialGradient4001`,"xlink:href":`#linearGradient4357-0-7`,"inkscape:collect":`always`}),createBaseVNode(`radialGradient`,{"inkscape:collect":`always`,"xlink:href":`#linearGradient4357-0-7`,id:`radialGradient4040`,gradientUnits:`userSpaceOnUse`,gradientTransform:`matrix(1.03125,0,0,1.03125,-885,-231)`,cx:`480`,cy:`544`,fx:`480`,fy:`544`,r:`320`}),createBaseVNode(`radialGradient`,{"inkscape:collect":`always`,"xlink:href":`#linearGradient4357-0-7`,id:`radialGradient4045`,gradientUnits:`userSpaceOnUse`,gradientTransform:`matrix(1.03125,0,0,1.03125,-885,-231)`,cx:`480`,cy:`544`,fx:`480`,fy:`544`,r:`320`}),createBaseVNode(`radialGradient`,{"inkscape:collect":`always`,"xlink:href":`#linearGradient4357-0-7-2`,id:`radialGradient4045-8`,gradientUnits:`userSpaceOnUse`,gradientTransform:`matrix(1.03125,0,0,1.03125,-885,-231)`,cx:`480`,cy:`544`,fx:`480`,fy:`544`,r:`320`}),createBaseVNode(`linearGradient`,{id:`linearGradient4357-0-7-2`},[createBaseVNode(`stop`,{style:{"stop-color":`#000000`,"stop-opacity":`0.51785713`},offset:`0`,id:`stop4359-9-4-4`}),createBaseVNode(`stop`,{style:{"stop-color":`#000000`,"stop-opacity":`0.11607143`},offset:`1`,id:`stop4361-4-0-5`})]),createBaseVNode(`radialGradient`,{r:`320`,fy:`544`,fx:`480`,cy:`544`,cx:`480`,gradientTransform:`matrix(1.03125,0,0,1.03125,-758.53125,-231)`,gradientUnits:`userSpaceOnUse`,id:`radialGradient4063`,"xlink:href":`#linearGradient4357-0-7-2`,"inkscape:collect":`always`}),createBaseVNode(`radialGradient`,{"inkscape:collect":`always`,"xlink:href":`#linearGradient4357-0-7`,id:`radialGradient4082`,gradientUnits:`userSpaceOnUse`,gradientTransform:`matrix(1.03125,0,0,1.03125,-885,-231)`,cx:`480`,cy:`544`,fx:`480`,fy:`544`,r:`320`}),createBaseVNode(`radialGradient`,{"inkscape:collect":`always`,"xlink:href":`#linearGradient4357-0-8`,id:`radialGradient4363-4-9`,cx:`480`,cy:`544`,fx:`480`,fy:`544`,r:`320`,gradientUnits:`userSpaceOnUse`,gradientTransform:`matrix(1.03125,0,0,1.03125,-15,-17)`}),createBaseVNode(`linearGradient`,{id:`linearGradient4357-0-8`},[createBaseVNode(`stop`,{style:{"stop-color":`#000000`,"stop-opacity":`0.51785713`},offset:`0`,id:`stop4359-9-40`}),createBaseVNode(`stop`,{style:{"stop-color":`#000000`,"stop-opacity":`0.11607143`},offset:`1`,id:`stop4361-4-7`})]),createBaseVNode(`radialGradient`,{r:`320`,fy:`544`,fx:`480`,cy:`544`,cx:`480`,gradientTransform:`matrix(1.03125,0,0,1.03125,-15,-17)`,gradientUnits:`userSpaceOnUse`,id:`radialGradient4031-1`,"xlink:href":`#linearGradient4357-0-8-5`,"inkscape:collect":`always`}),createBaseVNode(`linearGradient`,{id:`linearGradient4357-0-8-5`},[createBaseVNode(`stop`,{style:{"stop-color":`#000000`,"stop-opacity":`0.51785713`},offset:`0`,id:`stop4359-9-40-4`}),createBaseVNode(`stop`,{style:{"stop-color":`#000000`,"stop-opacity":`0.11607143`},offset:`1`,id:`stop4361-4-7-2`})]),createBaseVNode(`radialGradient`,{"inkscape:collect":`always`,"xlink:href":`#linearGradient4357-0-3`,id:`radialGradient4363-4-0`,cx:`480`,cy:`544`,fx:`480`,fy:`544`,r:`320`,gradientUnits:`userSpaceOnUse`,gradientTransform:`matrix(1.03125,0,0,1.03125,-15,-17)`}),createBaseVNode(`linearGradient`,{id:`linearGradient4357-0-3`},[createBaseVNode(`stop`,{style:{"stop-color":`#000000`,"stop-opacity":`0.65178573`},offset:`0`,id:`stop4359-9-8`}),createBaseVNode(`stop`,{style:{"stop-color":`#000000`,"stop-opacity":`0.24107143`},offset:`1`,id:`stop4361-4-01`})]),createBaseVNode(`clipPath`,{clipPathUnits:`userSpaceOnUse`,id:`clipPath4407-8-2`},[createBaseVNode(`path`,{"inkscape:connector-curvature":`0`,id:`path4409-8-5`,d:`m 480,-103.33 c -357.5105,0 -647.33,289.8195 -647.33,647.33 0,357.5105 289.8195,647.33 647.33,647.33 357.5105,0 647.33,-289.8195 647.33,-647.33 0,-357.5105 -289.8195,-647.33 -647.33,-647.33 z m 0,453.131 c 107.25316,0 194.199,86.94584 194.199,194.199 0,107.25316 -86.94584,194.199 -194.199,194.199 -107.25316,0 -194.199,-86.94584 -194.199,-194.199 0,-107.25316 86.94584,-194.199 194.199,-194.199 z`,style:{color:`#000000`,fill:`#ffffff`,"fill-opacity":`0.61375661`,"fill-rule":`nonzero`,stroke:`none`,"stroke-width":`16`,marker:`none`,visibility:`visible`,display:`inline`,overflow:`visible`,"enable-background":`accumulate`}})]),createBaseVNode(`radialGradient`,{r:`320`,fy:`544`,fx:`480`,cy:`544`,cx:`480`,gradientTransform:`matrix(1.03125,0,0,1.03125,-15,-17)`,gradientUnits:`userSpaceOnUse`,id:`radialGradient4401`,"xlink:href":`#linearGradient4357-0-3`,"inkscape:collect":`always`}),createBaseVNode(`radialGradient`,{r:`320`,fy:`544`,fx:`480`,cy:`544`,cx:`480`,gradientUnits:`userSpaceOnUse`,id:`radialGradient3997-4`,"xlink:href":`#linearGradient4365-4-7`,"inkscape:collect":`always`}),createBaseVNode(`linearGradient`,{id:`linearGradient4365-4-7`},[createBaseVNode(`stop`,{style:{"stop-color":`#000000`,"stop-opacity":`0.42857143`},offset:`0`,id:`stop4367-5-8`}),createBaseVNode(`stop`,{id:`stop4373-5-3`,offset:`0.5`,style:{"stop-color":`#000000`,"stop-opacity":`0.33035713`}}),createBaseVNode(`stop`,{style:{"stop-color":`#000000`,"stop-opacity":`0`},offset:`1`,id:`stop4369-1-5`})]),createBaseVNode(`radialGradient`,{r:`320`,fy:`544`,fx:`480`,cy:`544`,cx:`480`,gradientUnits:`userSpaceOnUse`,id:`radialGradient4458`,"xlink:href":`#linearGradient4365-4-7`,"inkscape:collect":`always`}),createBaseVNode(`clipPath`,{clipPathUnits:`userSpaceOnUse`,id:`clipPath3653`},[createBaseVNode(`path`,{style:{color:`#000000`,display:`inline`,overflow:`visible`,visibility:`visible`,fill:`#ffffff`,"fill-opacity":`0.61375661`,"fill-rule":`nonzero`,stroke:`none`,"stroke-width":`16`,marker:`none`,"enable-background":`accumulate`},d:`M 480,84 C 225.94901,84 20,289.94901 20,544 20,798.05099 225.94901,1004 480,1004 734.05099,1004 940,798.05099 940,544 940,289.94901 734.05099,84 480,84 Z m 0,322 c 76.21531,0 138,61.78469 138,138 0,76.21531 -61.78469,138 -138,138 -76.21531,0 -138,-61.78469 -138,-138 0,-76.21531 61.78469,-138 138,-138 z`,id:`path3655`,"inkscape:connector-curvature":`0`})]),createBaseVNode(`clipPath`,{clipPathUnits:`userSpaceOnUse`,id:`clipPath4490`},[createBaseVNode(`path`,{style:{color:`#000000`,"font-style":`normal`,"font-variant":`normal`,"font-weight":`normal`,"font-stretch":`normal`,"font-size":`medium`,"line-height":`normal`,"font-family":`sans-serif`,"text-indent":`0`,"text-align":`start`,"text-decoration":`none`,"text-decoration-line":`none`,"text-decoration-style":`solid`,"text-decoration-color":`#000000`,"letter-spacing":`normal`,"word-spacing":`normal`,"text-transform":`none`,direction:`ltr`,"block-progression":`tb`,"writing-mode":`lr-tb`,"baseline-shift":`baseline`,"text-anchor":`start`,"white-space":`normal`,"clip-rule":`nonzero`,display:`inline`,overflow:`visible`,visibility:`visible`,opacity:`1`,isolation:`auto`,"mix-blend-mode":`normal`,"color-interpolation":`sRGB`,"color-interpolation-filters":`linearRGB`,"solid-color":`#000000`,"solid-opacity":`1`,fill:`#000000`,"fill-opacity":`1`,"fill-rule":`evenodd`,stroke:`none`,"stroke-width":`96.91093445`,"stroke-linecap":`butt`,"stroke-linejoin":`miter`,"stroke-miterlimit":`4`,"stroke-dasharray":`none`,"stroke-dashoffset":`0`,"stroke-opacity":`1`,"color-rendering":`auto`,"image-rendering":`auto`,"shape-rendering":`auto`,"text-rendering":`auto`,"enable-background":`accumulate`},d:`m 330,10 c -176.15718,3e-6 -319.999997,143.84282 -320,320 0,88.07859 35.961054,168.07824 93.94141,226.05859 l 68.0957,-68.0957 C 131.73748,447.66326 106.91016,391.89131 106.91016,330 c 0,-123.78262 99.30722,-223.08984 223.08984,-223.08984 123.78262,0 223.08984,99.30722 223.08984,223.08984 0,61.89131 -24.82732,117.66326 -65.12695,157.96289 l 68.0957,68.0957 C 614.03895,498.07824 650,418.07859 650,330 650,153.84282 506.15718,10 330,10 Z`,id:`path4492`,"inkscape:connector-curvature":`0`})]),createBaseVNode(`clipPath`,{clipPathUnits:`userSpaceOnUse`,id:`clipPath4494`},[createBaseVNode(`path`,{style:{color:`#000000`,"font-style":`normal`,"font-variant":`normal`,"font-weight":`normal`,"font-stretch":`normal`,"font-size":`medium`,"line-height":`normal`,"font-family":`sans-serif`,"text-indent":`0`,"text-align":`start`,"text-decoration":`none`,"text-decoration-line":`none`,"text-decoration-style":`solid`,"text-decoration-color":`#000000`,"letter-spacing":`normal`,"word-spacing":`normal`,"text-transform":`none`,direction:`ltr`,"block-progression":`tb`,"writing-mode":`lr-tb`,"baseline-shift":`baseline`,"text-anchor":`start`,"white-space":`normal`,"clip-rule":`nonzero`,display:`inline`,overflow:`visible`,visibility:`visible`,opacity:`1`,isolation:`auto`,"mix-blend-mode":`normal`,"color-interpolation":`sRGB`,"color-interpolation-filters":`linearRGB`,"solid-color":`#000000`,"solid-opacity":`1`,fill:`#000000`,"fill-opacity":`1`,"fill-rule":`evenodd`,stroke:`none`,"stroke-width":`96.91093445`,"stroke-linecap":`butt`,"stroke-linejoin":`miter`,"stroke-miterlimit":`4`,"stroke-dasharray":`none`,"stroke-dashoffset":`0`,"stroke-opacity":`1`,"color-rendering":`auto`,"image-rendering":`auto`,"shape-rendering":`auto`,"text-rendering":`auto`,"enable-background":`accumulate`},d:`m 330,10 c -176.15718,3e-6 -319.999997,143.84282 -320,320 0,88.07859 35.961054,168.07824 93.94141,226.05859 l 68.0957,-68.0957 C 131.73748,447.66326 106.91016,391.89131 106.91016,330 c 0,-123.78262 99.30722,-223.08984 223.08984,-223.08984 123.78262,0 223.08984,99.30722 223.08984,223.08984 0,61.89131 -24.82732,117.66326 -65.12695,157.96289 l 68.0957,68.0957 C 614.03895,498.07824 650,418.07859 650,330 650,153.84282 506.15718,10 330,10 Z`,id:`path4496`,"inkscape:connector-curvature":`0`})]),createBaseVNode(`clipPath`,{clipPathUnits:`userSpaceOnUse`,id:`clipPath4498`},[createBaseVNode(`path`,{style:{color:`#000000`,"font-style":`normal`,"font-variant":`normal`,"font-weight":`normal`,"font-stretch":`normal`,"font-size":`medium`,"line-height":`normal`,"font-family":`sans-serif`,"text-indent":`0`,"text-align":`start`,"text-decoration":`none`,"text-decoration-line":`none`,"text-decoration-style":`solid`,"text-decoration-color":`#000000`,"letter-spacing":`normal`,"word-spacing":`normal`,"text-transform":`none`,direction:`ltr`,"block-progression":`tb`,"writing-mode":`lr-tb`,"baseline-shift":`baseline`,"text-anchor":`start`,"white-space":`normal`,"clip-rule":`nonzero`,display:`inline`,overflow:`visible`,visibility:`visible`,opacity:`1`,isolation:`auto`,"mix-blend-mode":`normal`,"color-interpolation":`sRGB`,"color-interpolation-filters":`linearRGB`,"solid-color":`#000000`,"solid-opacity":`1`,fill:`#000000`,"fill-opacity":`1`,"fill-rule":`evenodd`,stroke:`none`,"stroke-width":`96.91093445`,"stroke-linecap":`butt`,"stroke-linejoin":`miter`,"stroke-miterlimit":`4`,"stroke-dasharray":`none`,"stroke-dashoffset":`0`,"stroke-opacity":`1`,"color-rendering":`auto`,"image-rendering":`auto`,"shape-rendering":`auto`,"text-rendering":`auto`,"enable-background":`accumulate`},d:`m 240.41631,-226.27417 c -124.56194,124.56194 -124.56194,327.9864 0,452.54834 62.28096,62.28097 144.27756,93.42096 226.27417,93.42095 l 0,-96.30186 c -56.99229,0 -113.98458,-21.88116 -157.74834,-65.64492 -87.52753,-87.527531 -87.52753,-227.969149 0,-315.49668 87.52753,-87.52753 227.96915,-87.52753 315.49668,0 C 668.20258,-113.98457 690.08374,-56.992283 690.08374,0 l 96.30186,0 c 1e-5,-81.996605 -31.13998,-163.9932 -93.42095,-226.27417 -124.56194,-124.56194 -327.98641,-124.56194 -452.54834,0 z`,id:`path4500`,"inkscape:connector-curvature":`0`})])],-1),_cache[5]||=createBaseVNode(`g`,{"inkscape:label":`background`,"inkscape:groupmode":`layer`,id:`layer1`,transform:`translate(-150,-242.36218)`,style:{display:`none`,opacity:`1`}},[createBaseVNode(`rect`,{style:{fill:`#505050`,"fill-opacity":`1`,stroke:`none`},id:`rect4616`,width:`2175.3789`,height:`1458.4727`,x:`-727.47485`,y:`-115.47279`})],-1),createBaseVNode(`g`,_hoisted_2$140,[_cache[0]||=createBaseVNode(`circle`,{style:{color:`#000000`,display:`inline`,overflow:`visible`,visibility:`visible`,fill:`url(#radialGradient3997)`,"fill-opacity":`1`,"fill-rule":`nonzero`,stroke:`none`,"stroke-width":`16`,marker:`none`,"enable-background":`accumulate`},id:`path4281-5`,cx:`480`,cy:`544`,r:`320`,transform:`translate(-150,-214)`},null,-1),_cache[1]||=createBaseVNode(`path`,{style:{color:`#000000`,display:`inline`,overflow:`visible`,visibility:`visible`,fill:`url(#radialGradient4363-4)`,"fill-opacity":`1`,"fill-rule":`nonzero`,stroke:`none`,"stroke-width":`6`,marker:`none`,"enable-background":`accumulate`},d:`M 480,214 C 297.74603,214 150,361.74603 150,544 150,726.25397 297.74603,874 480,874 662.25397,874 810,726.25397 810,544 810,361.74603 662.25397,214 480,214 Z`,id:`path4281`,"inkscape:connector-curvature":`0`,"sodipodi:nodetypes":`sssss`,"clip-path":`url(#clipPath3653)`,transform:`translate(-150,-214)`},null,-1),createBaseVNode(`text`,_hoisted_3$126,[createBaseVNode(`tspan`,{ref_key:`pressureTextRef`,ref:pressureTextRef,"sodipodi:role":`line`,id:`pressureText`,x:`329.85437`,y:`328.48807`,style:{"font-style":`normal`,"font-variant":`normal`,"font-weight":`normal`,"font-stretch":`normal`,"font-size":`159.64709473px`,"line-height":`125%`,"font-family":`'Squada One'`,"-inkscape-font-specification":`'Squada One'`,"text-align":`center`,"writing-mode":`lr-tb`,"text-anchor":`middle`,fill:`#ffffff`,"fill-opacity":`1`}},` 0`,512)]),createBaseVNode(`text`,_hoisted_4$103,[createBaseVNode(`tspan`,{ref_key:`pressureUnitRef`,ref:pressureUnitRef,"sodipodi:role":`line`,id:`pressureunit`,x:`329.03198`,y:`413.62915`},`PSI`,512)]),(openBlock(!0),createElementBlock(Fragment,null,renderList(pressureTextAttrs.value,attrs=>(openBlock(),createElementBlock(`text`,{ref_for:!0,ref:el=>pressureTextRefs.value.push(el),"xml:space":`preserve`,class:`pressure-text`,id:attrs.id+`p`,x:attrs.x,y:attrs.y},[createBaseVNode(`tspan`,{ref_for:!0,ref:el2=>pressureTSpanRefs.value.push(el2),id:attrs.id,x:attrs.x,y:attrs.y},toDisplayString(attrs.text),9,_hoisted_6$74)],8,_hoisted_5$89))),256))]),createBaseVNode(`g`,_hoisted_7$64,[createBaseVNode(`g`,_hoisted_8$51,[_cache[2]||=createBaseVNode(`rect`,{style:{color:`#000000`,display:`inline`,overflow:`visible`,visibility:`visible`,fill:`#000000`,"fill-opacity":`0.37037036`,"fill-rule":`nonzero`,stroke:`none`,"stroke-width":`16`,marker:`none`,"enable-background":`accumulate`},id:`rect4001`,width:`683.79401`,height:`683.79401`,x:`127.97179`,y:`-340.09323`,transform:`matrix(0.70710678,0.70710678,-0.70710678,0.70710678,0,0)`,"clip-path":`url(#clipPath4498)`},null,-1),createBaseVNode(`path`,{ref_key:`pressureCurveRef`,ref:pressureCurveRef,style:{color:`#000000`,display:`inline`,overflow:`visible`,visibility:`visible`,fill:`none`,stroke:`#ffffff`,"stroke-width":`99.31034088`,"stroke-miterlimit":`4`,"stroke-dasharray":`2374.27468498, 2374.27468498`,"stroke-dashoffset":`0`,"stroke-opacity":`1`,marker:`none`,"enable-background":`accumulate`},d:`M 147.9957,528.59996 C 50,420 27.118653,298.1594 119.95323,156.00847 150,110 350,-30 532.60856,149.71493 c 74.5117,73.33098 97.08931,264.86379 -10.87668,369.15745`,id:`pressureCurve`,"clip-path":`url(#clipPath4494)`},null,512),createBaseVNode(`path`,{ref_key:`redLineRef`,ref:redLineRef,style:{color:`#000000`,overflow:`visible`,visibility:`visible`,fill:`none`,stroke:`#9c0000`,"stroke-width":`117.91827393`,"stroke-linecap":`butt`,"stroke-linejoin":`bevel`,"stroke-miterlimit":`4`,"stroke-dasharray":`none`,"stroke-dashoffset":`604.6484375`,"stroke-opacity":`0.66137564`,marker:`none`,"enable-background":`accumulate`},d:`M 147.99571,510.41274 C 33.434043,395.42128 59.279735,242.76116 138.14044,153.71911 230,50 387.77546,50.913502 485.67663,112.95746 c 165.77018,105.05531 132.03401,312.46382 37.32761,407.0596`,id:`pressure_redline`,"clip-path":`url(#clipPath4490)`},null,512)])]),createBaseVNode(`g`,_hoisted_9$45,[createBaseVNode(`path`,{ref_key:`pressureCurveDashesRef`,ref:pressureCurveDashesRef,style:{display:`inline`,fill:`none`,stroke:`#000000`,"stroke-width":`96.91100311`,"stroke-miterlimit":`0.40000001`,"stroke-dasharray":`48.4555, 48.4555`,"stroke-dashoffset":`0`,"stroke-opacity":`0.37566139`},d:`m 137.9887,522.0113 c -106.044908,-106.04491 -106.044903,-277.97769 1e-5,-384.0226 106.04491,-106.044917 277.97767,-106.044914 384.02259,0 106.04491,106.04491 106.04492,277.97769 10e-6,384.0226`,id:`pressureCurve_dashes`,"inkscape:connector-curvature":`0`,"sodipodi:nodetypes":`cssc`,"inkscape:label":`#path4531-4`},null,512),createBaseVNode(`path`,{ref_key:`pressureTextGuideLineRef`,ref:pressureTextGuideLineRef,style:{display:`inline`,fill:`none`,stroke:`#e90000`,"stroke-width":`2.86352348`,"stroke-miterlimit":`0.40000001`,"stroke-dasharray":`none`,"stroke-dashoffset":`0`,"stroke-opacity":`0.24404764`},d:`m 202.03513,457.96488 c -70.12576,-70.12575 -70.12576,-183.82209 0,-253.94784 70.12575,-70.12576 183.82208,-70.12576 253.94784,0 70.12575,70.12575 70.12575,183.82209 0,253.94784`,id:`pressuretextline`,"inkscape:connector-curvature":`0`,"sodipodi:nodetypes":`cssc`,"inkscape:label":`#path4531-4`},null,512)]),createBaseVNode(`g`,_hoisted_10$38,[createBaseVNode(`g`,{ref_key:`pressureNeedleRef`,ref:pressureNeedleRef,id:`pressure_needle_d`,"inkscape:label":`#g4147`,transform:`translate(-1.2852971e-6,1.993565e-6)`},[..._cache[3]||=[createBaseVNode(`rect`,{y:`7.0002151`,x:`322.0993`,height:`103.00317`,width:`12.038266`,id:`rect4625`,style:{color:`#000000`,display:`inline`,overflow:`visible`,visibility:`visible`,fill:`#d70000`,"fill-opacity":`1`,"fill-rule":`nonzero`,stroke:`none`,"stroke-width":`67.38899994`,marker:`none`,"enable-background":`accumulate`},transform:`matrix(1,0,0.00784004,0.99996927,0,0)`},null,-1),createBaseVNode(`rect`,{transform:`scale(1,-1)`,y:`-660`,x:`322.44037`,height:`660`,width:`15.11928`,id:`rect4625-1`,style:{color:`#000000`,display:`inline`,overflow:`visible`,visibility:`visible`,fill:`#008000`,"fill-opacity":`0`,"fill-rule":`nonzero`,stroke:`none`,"stroke-width":`67.38899994`,marker:`none`,"enable-background":`accumulate`}},null,-1)]],512)])]))}},forcedInduction_default=__plugin_vue_export_helper_default(_sfc_main$191,[[`__scopeId`,`data-v-a0f39cc4`]]),_sfc_main$190={__name:`app`,setup(__props){let{$game}=useLibStore(),forcedInductionRef=ref(null),fiContainerRef=ref(null),enabled=ref(!1);return onMounted(()=>{forcedInductionRef.value.wireThroughRoundDec(roundDec),forcedInductionRef.value.wireThroughUnitSystem((val,func)=>UiUnits[func](val)),$game.streams.add([`forcedInductionInfo`])}),onUnmounted(()=>{$game.streams.remove([`forcedInductionInfo`])}),$game.events.on(`VechicleChange`,()=>forcedInductionRef.value.reset()),$game.events.on(`VehicleFocusChanged`,data=>{data.mode==1&&forcedInductionRef.value!==null&&forcedInductionRef.value.reset()}),$game.events.on(`onStreamsUpdate`,streams=>{if(forcedInductionRef.value===null)return;let newEnabled=forcedInductionRef.value.isStreamValid(streams);newEnabled?(newEnabled&&!enabled.value&&(fiContainerRef.value.style.opacity=1),forcedInductionRef.value.update(streams)):!newEnabled&&enabled&&(fiContainerRef.value.style.opacity=0),enabled.value=newEnabled}),(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,{ref_key:`fiContainerRef`,ref:fiContainerRef,class:`fi-container`},[createVNode(forcedInduction_default,{ref_key:`forcedInductionRef`,ref:forcedInductionRef},null,512)],512))}},app_default$20=__plugin_vue_export_helper_default(_sfc_main$190,[[`__scopeId`,`data-v-3ea976f6`]]),_hoisted_1$170={class:`fi-debug`},_hoisted_2$139={class:`name`},_hoisted_3$125={class:`value`},_sfc_main$189={__name:`app`,setup(__props){let{$game}=useLibStore(),streamsList$1=[`forcedInductionInfo`],defaultMeasures=[{name:`RPM`,key:`rpm`},{name:`Boost`,key:`boost`,type:`pressure`},{name:`Power Coef`,key:`coef`},{name:`Pressure Pulses`,key:`pulses`},{name:`SC Loss`,key:`loss`},{name:`Exhaust Power`,key:`exhaustPower`},{name:`Friction`,key:`friction`},{name:`Backpressure`,key:`backpressure`},{name:`Wastegate Factor`,key:`wastegateFactor`},{name:`Turbo Temp`,key:`turboTemp`,type:`temperature`}],measures=ref([]),filteredMeasures=computed(()=>measures.value.filter(m=>m.val!==void 0));onMounted(()=>{$game.streams.add(streamsList$1),$game.events.on(`onStreamsUpdate`,onStreamsUpdate),$game.events.on(`VehicleReset`,init$3),$game.events.on(`VehicleFocusChanged`,init$3),init$3()}),onUnmounted(()=>{$game.streams.remove(streamsList$1),$game.events.off(`onStreamsUpdate`,onStreamsUpdate),$game.events.off(`VehicleReset`,init$3),$game.events.off(`VehicleFocusChanged`,init$3)});function onStreamsUpdate(streams){for(let stream of streamsList$1)if(!streams[stream])return;measures.value.forEach(x=>{let val=streams.forcedInductionInfo[x.key];val!==void 0&&(x.val=x.type===void 0?val.toFixed(2):$game.units.buildString(x.type,val,2))})}function init$3(){measures.value=defaultMeasures}return(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$170,[(openBlock(!0),createElementBlock(Fragment,null,renderList(filteredMeasures.value,m=>(openBlock(),createElementBlock(`div`,{class:`measure`,key:m.key},[createBaseVNode(`div`,_hoisted_2$139,toDisplayString(m.name),1),createBaseVNode(`div`,_hoisted_3$125,toDisplayString(m.val),1)]))),128))]))}},app_default$21=__plugin_vue_export_helper_default(_sfc_main$189,[[`__scopeId`,`data-v-8094d28b`]]),_sfc_main$188={},_hoisted_1$169={xmlns:`http://www.w3.org/2000/svg`,width:`60`,height:`100`,viewBox:`0 0 60 100`};function _sfc_render$2(_ctx,_cache){return openBlock(),createElementBlock(`svg`,_hoisted_1$169,[..._cache[0]||=[createBaseVNode(`rect`,{x:`4`,y:`4`,width:`52`,height:`92`,rx:`25`,ry:`25`,stroke:`black`,"stroke-width":`4`,fill:`none`},null,-1)]])}var accumulator_default=__plugin_vue_export_helper_default(_sfc_main$188,[[`render`,_sfc_render$2]]),_sfc_main$187={},_hoisted_1$168={xmlns:`http://www.w3.org/2000/svg`,width:`100`,height:`125`,viewBox:`0 0 100 125`,"stroke-width":`4`,stroke:`black`};function _sfc_render$1(_ctx,_cache){return openBlock(),createElementBlock(`svg`,_hoisted_1$168,[..._cache[0]||=[createBaseVNode(`circle`,{cx:`50`,cy:`32`,r:`30`,fill:`none`},null,-1),createBaseVNode(`path`,{d:`M50 6 L57 15 L43 15 Z`,fill:`black`},null,-1),createBaseVNode(`line`,{x1:`50`,y1:`61`,x2:`50`,y2:`90`,stroke:`black`},null,-1),createBaseVNode(`path`,{d:`M15 59 L15 115 L85 115 L85 59`,fill:`none`},null,-1)]])}var pump_default=__plugin_vue_export_helper_default(_sfc_main$187,[[`render`,_sfc_render$1]]),_sfc_main$186={},_hoisted_1$167={xmlns:`http://www.w3.org/2000/svg`,width:`100`,height:`130`,viewBox:`0 0 100 130`,"stroke-width":`4`,stroke:`black`};function _sfc_render(_ctx,_cache){return openBlock(),createElementBlock(`svg`,_hoisted_1$167,[..._cache[0]||=[createStaticVNode(``,6)]])}var reliefValve_default=__plugin_vue_export_helper_default(_sfc_main$186,[[`render`,_sfc_render]]),_hoisted_1$166={xmlns:`http://www.w3.org/2000/svg`,width:`100`,height:`210`,viewBox:`0 0 200 310`},_hoisted_2$138={transform:`translate(100, 0)`},_hoisted_3$124={transform:`translate(0, 110)`},_hoisted_4$102={transform:`translate(110, 190)`},_sfc_main$185={__name:`pumpAssembly`,setup(__props){return(_ctx,_cache)=>(openBlock(),createElementBlock(`svg`,_hoisted_1$166,[createBaseVNode(`g`,_hoisted_2$138,[createVNode(accumulator_default)]),createBaseVNode(`g`,_hoisted_3$124,[createVNode(reliefValve_default)]),createBaseVNode(`g`,_hoisted_4$102,[createVNode(pump_default)]),_cache[0]||=createBaseVNode(`path`,{d:`M56 122 L56 138 M54 120 L128 120 M130 122 L130 98 M130 120 L158 120 M160 118 L160 190`,stroke:`black`,"stroke-width":`4`},null,-1)]))}},pumpAssembly_default=_sfc_main$185,_hoisted_1$165={class:`hydraulics-debug`},_hoisted_2$137={width:`100%`,height:`100%`},_hoisted_3$123={id:`myGradient`,x1:`0%`,y1:`0%`,x2:`100%`,y2:`0%`},_hoisted_4$101=[`offset`],_hoisted_5$88={transform:`translate(0, 150)`,id:`pumpAssembly`},_hoisted_6$73=[`transform`],_hoisted_7$63=[`width`],_sfc_main$184={__name:`app`,setup(__props){let streamsList$1=[],{$game}=useLibStore(),offset$2=ref(0),offsetLeft=computed(()=>`${offset$2.value}%`),increase=()=>{offset$2.value<=100&&(offset$2.value+=10)},decrease=()=>{offset$2.value>0&&(offset$2.value-=10)},consumers=ref([{type:`hydraulicMotor`},{type:`cylinder`}]),addCylinder=function(){consumers.value.push({type:`cylinder`})},addhydraulicMotor=function(){consumers.value.push({type:`hydraulicMotor`})},removeConsumer=function(index=null){index===null?consumers.value.pop():consumers.value.splice(index,1)};onMounted(()=>{$game.events.on(`onStreamsUpdate`,onStreamsUpdate),$game.streams.add(streamsList$1)}),onUnmounted(()=>{$game.events.off(`onStreamsUpdate`,onStreamsUpdate),$game.streams.remove(streamsList$1)});function onStreamsUpdate(streams){for(let stream of streamsList$1)if(!streams[stream])return}return(_ctx,_cache)=>(openBlock(),createElementBlock(Fragment,null,[_cache[1]||=createBaseVNode(`h1`,null,`Hydraulics Debug`,-1),createBaseVNode(`button`,{onClick:decrease},`dec`),createBaseVNode(`button`,{onClick:increase},`inc`),createBaseVNode(`button`,{onClick:addhydraulicMotor},`motor`),createBaseVNode(`button`,{onClick:addCylinder},`cylinder`),createBaseVNode(`button`,{onClick:removeConsumer},`Remove Consumer`),createBaseVNode(`div`,null,` offset: `+toDisplayString(offset$2.value)+` left: `+toDisplayString(offsetLeft.value),1),createBaseVNode(`div`,_hoisted_1$165,[(openBlock(),createElementBlock(`svg`,_hoisted_2$137,[createBaseVNode(`defs`,null,[createBaseVNode(`linearGradient`,_hoisted_3$123,[createBaseVNode(`stop`,{offset:offsetLeft.value,"stop-color":`green`},null,8,_hoisted_4$101),_cache[0]||=createBaseVNode(`stop`,{offset:`0`,"stop-color":`black`},null,-1)])]),createBaseVNode(`g`,_hoisted_5$88,[createVNode(pumpAssembly_default)]),(openBlock(!0),createElementBlock(Fragment,null,renderList(consumers.value,(consumer,index)=>(openBlock(),createElementBlock(`g`,{transform:`translate(${(index+1)*100}, 95)`},[createVNode(consumer,{consumerType:consumer.type},null,8,[`consumerType`])],8,_hoisted_6$73))),256)),createBaseVNode(`rect`,{x:`80`,y:`236.5`,width:100*(consumers.value.length-1)+66,height:`2`,fill:`url(#myGradient)`},null,8,_hoisted_7$63)]))])],64))}},app_default$22=__plugin_vue_export_helper_default(_sfc_main$184,[[`__scopeId`,`data-v-a5aea534`]]),_hoisted_1$164={key:0,class:`bindings-app`},_hoisted_2$136={key:0,class:`toggle-icon`},_hoisted_3$122={key:1,class:`toggle-icon`},_hoisted_4$100={key:0,class:`players-binding`},_hoisted_5$87={key:0},_hoisted_6$72={key:1,class:`bindings-container`},_hoisted_7$62={class:`binding-item`},_sfc_main$183={__name:`app`,setup(__props){let{$game}=useLibStore(),bindings=ref([]),small=ref(!0),timeout=ref(null),show=ref(0),players=ref([]),forward=()=>{show.value=(show.value+1)%bindings.value.length},backward=()=>{show.value=show.value===0?bindings.value.length-1:show.value-1},toggleSmall=()=>{small.value=!small.value,clearTimeout(timeout)},goToBindings=(action,control)=>{$game.events.emit(`MenuHide`,!1),bngVue.gotoGameState(`menu.options.controls.bindings.edit`,{params:{action:action.actionName,oldBinding:{control:control.c,device:control.n}}})};onMounted(()=>{$game.events.on(`InputBindingsChanged`,onInputBindingsChanged),$game.events.on(`VehicleChange`,showBriefly),$game.events.on(`VehicleFocusChanged`,showBriefly),$game.api.engineLua(`extensions.core_input_bindings.notifyUI("keys app: link init")`),setTimeout(function(){$game.api.engineLua(`settings.notifyUI()`)},200)}),onUnmounted(()=>{$game.events.off(`InputBindingsChanged`,onInputBindingsChanged),$game.events.off(`VehicleChange`,showBriefly),$game.events.off(`VehicleFocusChanged`,showBriefly)});function showBriefly(){small.value&&(timeout.value=setTimeout(()=>small.value=!0,1e4)),small.value=!1}function onInputBindingsChanged(data){let specialKeys=[];players.value=[];for(let i=0;i=bindings.value.length&&(show.value=0)}function existsAt(arr,ac){return arr.map(function(elem,i){return elem.actionName===ac?i:-1}).filter(function(elem){return elem!==-1})}return(_ctx,_cache)=>players.value.length>1||bindings.value[show.value]&&bindings.value[show.value].length>0?(openBlock(),createElementBlock(`div`,_hoisted_1$164,[createBaseVNode(`div`,{onClick:_cache[0]||=$event=>toggleSmall(),class:`binding-show`},[small.value?(openBlock(),createElementBlock(`span`,_hoisted_2$136,[createVNode(unref(bngIcon_default),{class:`key-icon`,type:unref(icons).arrowSmallLeft},null,8,[`type`])])):(openBlock(),createElementBlock(`span`,_hoisted_3$122,[createVNode(unref(bngIcon_default),{class:`key-icon`,type:unref(icons).arrowSmallRight},null,8,[`type`])]))]),!small.value&&(players.value.length>1||bindings.value[show.value]&&bindings.value[show.value].length>0)?(openBlock(),createElementBlock(`div`,_hoisted_4$100,[!small.value&&players.value.length>1?(openBlock(),createElementBlock(`div`,_hoisted_5$87,[bindings.value.length>1?(openBlock(),createBlock(unref(bngButton_default),{key:0,onClick:_cache[1]||=$event=>backward()})):createCommentVNode(``,!0),createBaseVNode(`span`,null,`Player `+toDisplayString(show.value),1),bindings.value.length>1?(openBlock(),createBlock(unref(bngButton_default),{key:1,onClick:_cache[2]||=$event=>forward()})):createCommentVNode(``,!0)])):createCommentVNode(``,!0),bindings.value[show.value].length>0&&!small.value?(openBlock(),createElementBlock(`div`,_hoisted_6$72,[(openBlock(!0),createElementBlock(Fragment,null,renderList(bindings.value[show.value],entry=>(openBlock(),createElementBlock(`div`,_hoisted_7$62,[createBaseVNode(`div`,null,toDisplayString(_ctx.$t(entry.action)),1),createBaseVNode(`div`,null,[(openBlock(!0),createElementBlock(Fragment,null,renderList(entry.control,b=>(openBlock(),createBlock(unref(bngBinding_default),{deviceKey:b.c,device:b.d,"show-unassigned":!0,onClick:$event=>goToBindings(entry,b)},null,8,[`deviceKey`,`device`,`onClick`]))),256))])]))),256))])):createCommentVNode(``,!0)])):createCommentVNode(``,!0)])):createCommentVNode(``,!0)}},app_default$23=__plugin_vue_export_helper_default(_sfc_main$183,[[`__scopeId`,`data-v-b0d8eae9`]]),_hoisted_1$163={class:`bng-app log-vehicle-stats`},_hoisted_2$135={class:`update-period`},_hoisted_3$121={class:`settings-row`},_hoisted_4$99={class:`settings-row`},_hoisted_5$86={class:`settings-row`},_hoisted_6$71={class:`settings-row`},_hoisted_7$61={class:`log-btns`},_sfc_main$182={__name:`app`,setup(__props){const{$game}=useLibStore(),config=reactive({updateTime:5,moduleGeneral:!0,moduleWheels:!0,moduleEngine:!0,moduleInputs:!0,modulePowertrain:!0,outputFileName:`settings.json`,inputFileName:`settings.json`,outputDir:`VSL`}),configChanged=(configName,value)=>{switch(configName){case`moduleGeneral`:config.moduleGeneral=value;break;case`moduleWheels`:config.moduleWheels=value;break;case`moduleEngine`:config.moduleEngine=value;break;case`moduleInputs`:config.moduleInputs=value;break;case`modulePowertrain`:config.modulePowertrain=value;break}},applySettings=()=>{$game.api.activeObjectLua(`extensions.vehicleStatsLogger.updateTime = ${config.updateTime}`),$game.api.activeObjectLua(`extensions.vehicleStatsLogger.settings.useModule["General"] = ${config.moduleGeneral}`),$game.api.activeObjectLua(`extensions.vehicleStatsLogger.settings.useModule["Wheels"] = ${config.moduleWheels}`),$game.api.activeObjectLua(`extensions.vehicleStatsLogger.settings.useModule["Inputs"] = ${config.moduleInputs}`),$game.api.activeObjectLua(`extensions.vehicleStatsLogger.settings.useModule["Engine"] = ${config.moduleEngine}`),$game.api.activeObjectLua(`extensions.vehicleStatsLogger.settings.useModule["Powertrain"] = ${config.modulePowertrain}`)},useAsOutputDir=()=>{$game.api.activeObjectLua(`extensions.vehicleStatsLogger.settings.outputDir = "${config.outputDir}"`)},getNewOutputFilename=()=>{$game.api.activeObjectLua(`extensions.vehicleStatsLogger.suggestOutputFilename()`,function(data){config.outputFileName=data})},saveSettingsToJson=()=>{config.outputFileName!==``&&$game.api.activeObjectLua(`extensions.vehicleStatsLogger.writeSettingsToJSON("${config.outputFileName}")`)},importSettingsFromFile=()=>{scope.inputFileName!==``&&($game.api.activeObjectLua(`extensions.vehicleStatsLogger.applySettingsFromJSON("${config.inputFileName}")`),config.moduleGeneral=eval(`${extensions.vehicleStatsLogger.settings.useModule.General}`),config.moduleWheels=eval(`${extensions.vehicleStatsLogger.settings.useModule.Wheels}`),config.moduleInputs=eval(`${extensions.vehicleStatsLogger.settings.useModule.Inputs}`),config.moduleEngine=eval(`${extensions.vehicleStatsLogger.settings.useModule.Engine}`),config.modulePowertrain=eval(`${extensions.vehicleStatsLogger.settings.useModule.Powertrain}`))},startLogging=()=>{$game.api.activeObjectLua(`extensions.vehicleStatsLogger.startLogging()`)},stopLogging=()=>{$game.api.activeObjectLua(`extensions.vehicleStatsLogger.stopLogging()`)};return(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$163,[createBaseVNode(`div`,_hoisted_2$135,[_cache[20]||=createBaseVNode(`span`,{class:`label`},`Update Period:`,-1),createVNode(unref(bngInput_default),{type:`number`,min:1,max:360,step:1,modelValue:config.updateTime,"onUpdate:modelValue":_cache[0]||=$event=>config.updateTime=$event,suffix:`seconds`},null,8,[`modelValue`])]),createBaseVNode(`div`,null,[createVNode(unref(bngPillCheckbox_default),{modelValue:config.moduleGeneral,"onUpdate:modelValue":_cache[1]||=$event=>config.moduleGeneral=$event,onValueChanged:_cache[2]||=val=>configChanged(`moduleGeneral`,val)},{default:withCtx(()=>[..._cache[21]||=[createTextVNode(` General`,-1)]]),_:1},8,[`modelValue`]),createVNode(unref(bngPillCheckbox_default),{modelValue:config.moduleWheels,"onUpdate:modelValue":_cache[3]||=$event=>config.moduleWheels=$event,onValueChanged:_cache[4]||=val=>configChanged(`moduleWheels`,val)},{default:withCtx(()=>[..._cache[22]||=[createTextVNode(` Wheels`,-1)]]),_:1},8,[`modelValue`]),createVNode(unref(bngPillCheckbox_default),{modelValue:config.moduleEngine,"onUpdate:modelValue":_cache[5]||=$event=>config.moduleEngine=$event,onValueChanged:_cache[6]||=val=>configChanged(`moduleEngine`,val)},{default:withCtx(()=>[..._cache[23]||=[createTextVNode(` Engine`,-1)]]),_:1},8,[`modelValue`]),createVNode(unref(bngPillCheckbox_default),{modelValue:config.moduleInputs,"onUpdate:modelValue":_cache[7]||=$event=>config.moduleInputs=$event,onValueChanged:_cache[8]||=val=>configChanged(`moduleInputs`,val)},{default:withCtx(()=>[..._cache[24]||=[createTextVNode(` Inputs`,-1)]]),_:1},8,[`modelValue`]),createVNode(unref(bngPillCheckbox_default),{modelValue:config.modulePowertrain,"onUpdate:modelValue":_cache[9]||=$event=>config.modulePowertrain=$event,onValueChanged:_cache[10]||=val=>configChanged(`modulePowertrain`,val)},{default:withCtx(()=>[..._cache[25]||=[createTextVNode(`Powertrain`,-1)]]),_:1},8,[`modelValue`])]),createBaseVNode(`div`,_hoisted_3$121,[_cache[27]||=createBaseVNode(`label`,null,`Apply Settings:`,-1),createVNode(unref(bngButton_default),{class:`settings-btn`,onClick:_cache[11]||=$event=>applySettings()},{default:withCtx(()=>[..._cache[26]||=[createTextVNode(`Apply`,-1)]]),_:1})]),withDirectives((openBlock(),createElementBlock(`div`,_hoisted_4$99,[_cache[29]||=createBaseVNode(`label`,null,`Set Custom Output Directory:`,-1),createVNode(unref(bngInput_default),{modelValue:config.outputDir,"onUpdate:modelValue":_cache[12]||=$event=>config.outputDir=$event},null,8,[`modelValue`]),createVNode(unref(bngButton_default),{class:`settings-btn`,onClick:_cache[13]||=$event=>useAsOutputDir()},{default:withCtx(()=>[..._cache[28]||=[createTextVNode(`Use`,-1)]]),_:1})])),[[unref(BngTooltip_default),`Subdirectory of the BeamNG.drive/BeamNG.tech directory.`]]),withDirectives((openBlock(),createElementBlock(`div`,_hoisted_5$86,[_cache[31]||=createBaseVNode(`label`,null,`Settings Output Filename:`,-1),createVNode(unref(bngInput_default),{modelValue:config.outputFileName,"onUpdate:modelValue":_cache[14]||=$event=>config.outputFileName=$event},null,8,[`modelValue`]),createVNode(unref(bngButton_default),{class:`settings-btn`,onClick:_cache[15]||=$event=>saveSettingsToJson()},{default:withCtx(()=>[..._cache[30]||=[createTextVNode(`Write`,-1)]]),_:1})])),[[unref(BngTooltip_default),`Settings files are written to the BeamNG.drive/BeamNG.tech directory.`]]),withDirectives((openBlock(),createElementBlock(`div`,_hoisted_6$71,[_cache[33]||=createBaseVNode(`label`,null,`Settings Input Filename:`,-1),createVNode(unref(bngInput_default),{modelValue:config.inputFileName,"onUpdate:modelValue":_cache[16]||=$event=>config.inputFileName=$event},null,8,[`modelValue`]),createVNode(unref(bngButton_default),{class:`settings-btn`,onClick:_cache[17]||=$event=>importSettingsFromFile()},{default:withCtx(()=>[..._cache[32]||=[createTextVNode(`Load`,-1)]]),_:1})])),[[unref(BngTooltip_default),`Settings files are assumed to be in the BeamNG.drive/BeamNG.tech directory.`]]),createBaseVNode(`div`,_hoisted_7$61,[createVNode(unref(bngButton_default),{class:`start-btn`,onClick:_cache[18]||=$event=>startLogging()},{default:withCtx(()=>[..._cache[34]||=[createTextVNode(`Start Log`,-1)]]),_:1}),createVNode(unref(bngButton_default),{class:`stop-btn`,onClick:_cache[19]||=$event=>stopLogging()},{default:withCtx(()=>[..._cache[35]||=[createTextVNode(`Stop Log`,-1)]]),_:1})])]))}},app_default$24=__plugin_vue_export_helper_default(_sfc_main$182,[[`__scopeId`,`data-v-686c3ac5`]]),_hoisted_1$162={class:`replay-app-container`,ref:`appContainerRef`},_hoisted_2$134={class:`left-controls`},_hoisted_3$120={class:`filename-container`},_hoisted_4$98={key:1,class:`filename`},_hoisted_5$85={key:1,class:`filename`},_hoisted_6$70={class:`right-controls`},_hoisted_7$60={class:`replay-controls-container`},_hoisted_8$50={class:`play-controls`},_hoisted_9$44={key:0,class:`speed-controls`},_hoisted_10$37={class:`svg-time-container`},_hoisted_11$33={width:`100%`,height:`100%`,preserveAspectRatio:`xMidYMid meet`},_hoisted_12$26={viewBox:`0 0 200 50`,width:`100%`,height:`100%`,overflow:`visible`},_hoisted_13$23={transform:`translate(100, 25)`},_hoisted_14$22={"text-anchor":`middle`,"dominant-baseline":`middle`,class:`time-text`,"font-size":`40`,"line-height":`1`},_hoisted_15$21={class:`time-display-total`},_hoisted_16$21={class:`position-slider`},replayFolder=`replays/`,replayFileExtension=`.rpl`,_sfc_main$181={__name:`app`,props:{hideFileControls:{type:Boolean,default:!1}},setup(__props){let state=ref(`inactive`),speed=ref(1),paused=ref(!1),renaming=ref(!1),isSeeking=ref(!1),loadedFile=ref(``),positionSeconds=ref(0),totalSeconds=ref(0),positionPercent=ref(0),fpsRec=ref(0),fpsPlay=ref(0),originalFilename=``,lastSeek=0,events$3=useEvents(),resizeObserver=ref(null),replayControlsRef=ref(null),containerWidth=shallowRef(0),layoutState=computed(()=>{let width$1=containerWidth.value;return{isReplayControlsNarrow:width$1<301,isFileControlsNarrow:width$1<361}}),props=__props,formatTime$1=seconds=>new Date(seconds*1e3).toISOString().substr(14,8),debounce$1=(fn,delay)=>{let timer=null;return(...args)=>{timer&&clearTimeout(timer),timer=setTimeout(()=>{fn(...args),timer=null},delay)}},listRecordings=()=>{window.bngVue.gotoGameState(`menu.replay`)},startRenaming=()=>{renaming.value=!0,originalFilename=loadedFile.value},cancelRename=()=>{renaming.value=!1,loadedFile.value=originalFilename},acceptRename=()=>{if(loadedFile.value===originalFilename){cancelRename();return}renaming.value=!1,Lua_default.core_replay.acceptRename(replayFolder+originalFilename+replayFileExtension,replayFolder+loadedFile.value+replayFileExtension)},toggleSpeed=val=>{Lua_default.core_replay.toggleSpeed(val)},togglePlay=()=>{Lua_default.core_replay.togglePlay()},toggleRecording=()=>{Lua_default.core_replay.toggleRecording(!0)},cancelRecording=()=>{Lua_default.core_replay.cancelRecording()},stop$1=()=>{Lua_default.core_replay.stop()},seek=()=>{state.value===`playback`&&(lastSeek=Date.now(),Lua_default.core_replay.pause(!0),Lua_default.core_replay.seek(positionPercent.value))};watch(positionSeconds,(newVal,oldVal)=>{Date.now()-lastSeek>500&&totalSeconds.value>0&&(positionPercent.value=newVal/totalSeconds.value)});let setupResizeObserver=()=>{if(!replayControlsRef.value)return;let rafId=null,updateWidth=debounce$1(width$1=>{containerWidth.value=width$1},100);resizeObserver.value=new ResizeObserver(entries=>{rafId!==null&&cancelAnimationFrame(rafId),rafId=requestAnimationFrame(()=>{for(let entry of entries)updateWidth(entry.contentRect.width);rafId=null})}),resizeObserver.value.observe(replayControlsRef.value)};return onMounted(async()=>{try{Lua_default.core_replay.onInit()}catch(e){console.error(`Error initializing replay state:`,e)}events$3.on(`replayStateChanged`,val=>{renaming.value||(loadedFile.value=val.loadedFile.replace(replayFolder,``).replace(replayFileExtension,``)),positionSeconds.value=val.positionSeconds,totalSeconds.value=val.totalSeconds,speed.value=val.speed,paused.value=val.paused,fpsRec.value=val.fpsRec,fpsPlay.value=val.fpsPlay,state.value=val.state,isSeeking.value=val.jumpOffset!==0,Date.now()-lastSeek>500&&totalSeconds.value>0?positionPercent.value=positionSeconds.value/totalSeconds.value:isSeeking.value=!0}),await nextTick(),setupResizeObserver()}),onUnmounted(()=>{resizeObserver.value&&=(resizeObserver.value.disconnect(),null),events$3.off(`replayStateChanged`)}),(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$162,[props.hideFileControls?createCommentVNode(``,!0):(openBlock(),createElementBlock(`div`,{key:0,class:normalizeClass([`file-controls`,{narrow:layoutState.value.isFileControlsNarrow}])},[createBaseVNode(`div`,_hoisted_2$134,[createVNode(unref(bngButton_default),{class:`recordings-button`,onClick:listRecordings,icon:`folder`,tooltip:`Open recordings`,accent:unref(ACCENTS).text},null,8,[`accent`]),loadedFile.value&&state.value!==`recording`&&!renaming.value?(openBlock(),createBlock(unref(bngButton_default),{key:0,class:`recordings-button`,onClick:stop$1,icon:`xmark`,disabled:state.value!==`playback`,tooltip:`Close replay`,accent:unref(ACCENTS).text},null,8,[`disabled`,`accent`])):createCommentVNode(``,!0),state.value===`recording`?(openBlock(),createBlock(unref(bngButton_default),{key:1,class:`recordings-button`,onClick:cancelRecording,icon:`undo`,accent:unref(ACCENTS).attention,tooltip:`Cancel recording`},null,8,[`accent`])):createCommentVNode(``,!0)]),createBaseVNode(`div`,_hoisted_3$120,[loadedFile.value&&state.value!==`recording`?(openBlock(),createElementBlock(Fragment,{key:0},[renaming.value?(openBlock(),createElementBlock(Fragment,{key:0},[createVNode(unref(bngButton_default),{onClick:cancelRename,icon:`xmark`,accent:unref(ACCENTS).ghost,class:`cancel-rename-button`},null,8,[`accent`]),createVNode(unref(bngInput_default),{id:`replay-filename-input`,class:`filename-input`,prefix:replayFolder,suffix:replayFileExtension,modelValue:loadedFile.value,"onUpdate:modelValue":_cache[0]||=$event=>loadedFile.value=$event,placeholder:`(no file)`,disabled:state.value===`recording`||!loadedFile.value,onKeyup:withKeys(acceptRename,[`enter`])},null,8,[`modelValue`,`disabled`])],64)):(openBlock(),createElementBlock(`div`,_hoisted_4$98,toDisplayString(replayFolder)+toDisplayString(loadedFile.value)+toDisplayString(replayFileExtension),1)),createVNode(unref(bngButton_default),{onClick:_cache[1]||=$event=>renaming.value?acceptRename():startRenaming(),icon:renaming.value?`checkmark`:`edit`,accent:renaming.value?unref(ACCENTS).main:unref(ACCENTS).ghost},null,8,[`icon`,`accent`])],64)):(openBlock(),createElementBlock(`div`,_hoisted_5$85,` No File loaded `))]),createBaseVNode(`div`,_hoisted_6$70,[createVNode(unref(bngButton_default),{onClick:toggleRecording,icon:state.value===`recording`?`square`:`bigDot`,accent:unref(ACCENTS).text,disabled:state.value===`playback`,tooltip:state.value===`recording`?`Save recording`:`Record new replay`,class:`recordings-button record-button`},null,8,[`icon`,`accent`,`disabled`,`tooltip`])])],2)),createBaseVNode(`div`,_hoisted_7$60,[createBaseVNode(`div`,{class:normalizeClass([`replay-controls`,{narrow:layoutState.value.isReplayControlsNarrow}]),ref_key:`replayControlsRef`,ref:replayControlsRef},[createBaseVNode(`div`,_hoisted_8$50,[createVNode(unref(bngButton_default),{onClick:togglePlay,class:`play-button`,icon:state.value===`playback`&&!paused.value?`pause`:`play`,disabled:state.value===`recording`||!loadedFile.value,accent:unref(ACCENTS).ghost},null,8,[`icon`,`disabled`,`accent`]),state.value===`inactive`?createCommentVNode(``,!0):(openBlock(),createElementBlock(`div`,_hoisted_9$44,[createVNode(unref(bngButton_default),{class:`speed-button small`,onClick:_cache[2]||=$event=>toggleSpeed(-1),icon:`mathMinus`,disabled:!loadedFile.value,accent:unref(ACCENTS).text},null,8,[`disabled`,`accent`]),createBaseVNode(`div`,{class:normalizeClass([`playback-speed-display`,{disabled:!loadedFile.value}])},toDisplayString(speed.value.toFixed(2))+`x`,3),createVNode(unref(bngButton_default),{class:`speed-button small`,onClick:_cache[3]||=$event=>toggleSpeed(1),icon:`mathPlus`,disabled:!loadedFile.value,accent:unref(ACCENTS).text},null,8,[`disabled`,`accent`])]))]),createBaseVNode(`div`,{class:normalizeClass([`time-display`,{active:loadedFile.value,seeking:isSeeking.value}])},[createBaseVNode(`div`,_hoisted_10$37,[(openBlock(),createElementBlock(`svg`,_hoisted_11$33,[(openBlock(),createElementBlock(`svg`,_hoisted_12$26,[createBaseVNode(`g`,_hoisted_13$23,[createBaseVNode(`text`,_hoisted_14$22,toDisplayString(formatTime$1(positionSeconds.value)),1)])]))]))]),createBaseVNode(`span`,_hoisted_15$21,`(`+toDisplayString(formatTime$1(totalSeconds.value))+`)`,1)],2)],2),createBaseVNode(`div`,_hoisted_16$21,[createVNode(unref(bngSlider_default),{modelValue:positionPercent.value,"onUpdate:modelValue":_cache[4]||=$event=>positionPercent.value=$event,min:0,max:1,step:.001,onInput:seek,disabled:state.value!==`playback`||!loadedFile.value},null,8,[`modelValue`,`disabled`])])])],512))}},app_default$1=__plugin_vue_export_helper_default(_sfc_main$181,[[`__scopeId`,`data-v-bf84291a`]]),_hoisted_1$161={style:{width:`100%`,height:`100%`},class:`bng-app`,layout:`column`},_hoisted_2$133={style:{display:`flex`,"justify-content":`center`,"align-items":`baseline`}},_hoisted_3$119={style:{"font-size":`1.3em`,"font-weight":`bold`}},_hoisted_4$97={style:{color:`rgba(255, 255, 255, 0.8)`}},_hoisted_5$84={style:{"text-align":`center`,color:`rgba(255, 255, 255, 0.8)`,"font-size":`0.75em`}},_sfc_main$180={__name:`app`,setup(__props){let{$game}=useLibStore(),streamsList$1=[`engineInfo`];$game.streams.add(streamsList$1);let numToBig=ref(`1`);ref(NaN);let rpm=ref(0),leadingZeros=ref(null);onMounted(()=>{console.log(`simpleDigTacho mounted`),$game.events.on(`onStreamsUpdate`,onStreamsUpdate)}),onUnmounted(()=>{console.log(`simpleDigTacho unmounted`),$game.streams.remove(streamsList$1),$game.events.off(`onStreamsUpdate`,onStreamsUpdate)});function onStreamsUpdate(streams){for(let stream of streamsList$1)if(!streams[stream])return;if(rpm.value=Math.round(streams.engineInfo[4]),rpm.value.toString().length>4){let help=10**(rpm.value.toString().length-4);numToBig.value=help.toString(),rpm.value=Math.round(rpm.value/help)}else numToBig.value=`1`;rpm.value=rpm.value.toString().slice(-4),isNaN(rpm.value)||(leadingZeros.value=`0000`.slice(rpm.value.length))}return(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$161,[createBaseVNode(`div`,_hoisted_2$133,[createBaseVNode(`span`,_hoisted_3$119,[createBaseVNode(`span`,_hoisted_4$97,toDisplayString(leadingZeros.value),1),createBaseVNode(`span`,null,toDisplayString(rpm.value),1)]),_cache[0]||=createBaseVNode(`span`,{style:{"font-size":`0.9em`,"font-weight":`bold`,"margin-left":`2px`}},`RPM`,-1)]),createBaseVNode(`small`,_hoisted_5$84,[createTextVNode(toDisplayString(_ctx.$t(`ui.apps.digTacho.engine`))+` `,1),createBaseVNode(`span`,null,`(x`+toDisplayString(numToBig.value)+`)`,1)])]))}},app_default$25=_sfc_main$180,_hoisted_1$160={"xmlns:svg":`http://www.w3.org/2000/svg`,xmlns:`http://www.w3.org/2000/svg`,"xmlns:xlink":`http://www.w3.org/1999/xlink`,version:`1.1`,width:`100%`,height:`100%`,viewBox:`0 0 660 660`},_hoisted_2$132={"xml:space":`preserve`,class:`text1`,x:`329.88641`,y:`289.30463`,id:`tspan4449-43`},_hoisted_3$118={"xml:space":`preserve`,id:`speed_units`,class:`speed-units`,x:`330`,y:`348`},_hoisted_4$96={"xml:space":`preserve`,id:`tspan4449-4-3`,class:`tacho2-gear`,x:`386.67343`,y:`457.94861`,transform:`matrix(1,0,-0.13142611,1,0,0)`},_hoisted_5$83={"xml:space":`preserve`,x:`330.09229`,y:`498.18045`,id:`text4447-2-4`,class:`rpm-text-legend`},_hoisted_6$69={transform:`translate(-150,-214)`,id:`revcurvemask`,class:`revcurvemask`,"clip-path":`url(#clipPath4710)`},rpmTextSize=50,maxRpmTexts=13,tickMarkLength=64,tickInnerOffset=42,_sfc_main$179={__name:`tacho`,setup(__props,{expose:__expose}){let width$1=660,height$1=660,initialized=ref(!1),dashSize$1=5,computeGaugeFullRange=maxrpm=>Math.ceil((maxrpm||0)/1e3)*1e3+1e3,computeGaugeStep=maxrpm=>maxrpm<4e3?500:maxrpm>15e3?2e3:1e3,computeGaugeMarks=maxrpm=>{let fullRange=computeGaugeFullRange(maxrpm),step=computeGaugeStep(maxrpm);return Math.ceil(fullRange/step)+1},rpmTextRefs=ref([]),setRpmRef=(el,i)=>{el&&(rpmTextRefs.value[i]=el)},oilTempBarRef=ref(null),oilTempBarLen=computed(()=>oilTempBarRef.value.getTotalLength()),oilTempIcoOffRef=ref(null),oilTempIcoOnRef=ref(null),speedTextRef=ref(null),gearTextRef=ref(null),revcurveRef=ref(null),revCurveLen=computed(()=>revcurveRef.value.getTotalLength()),revcurveDashesRef=ref(null),revCurveDashesLen=computed(()=>revcurveDashesRef.value.getTotalLength()),fuelBarRef=ref(null),fuelBarLen=computed(()=>fuelBarRef.value.getTotalLength()),fuelWarnIcoOffRef=ref(null),fuelWarnIcoOnRef=ref(null),lastFuelLevel=0,shouldPlayFuelLowSound=!1,lowFuelSoundPlayed=!1,isCareer=!1,redLineRef=ref(null),redLineLen=computed(()=>redLineRef.value.getTotalLength()),rpmTextGuideLineRef=ref(null),rpmTextGuideLineLen=computed(()=>rpmTextGuideLineRef.value.getTotalLength()),tickMarkRefs=ref([]),setTickRef=(el,i)=>{el&&(tickMarkRefs.value[i]=el)},icoHandBrakeOffRef=ref(null),icoHandBrakeOnRef=ref(null),icoABSOffRef=ref(null),icoABSOnRef=ref(null),icoIndicatorLeftOffRef=ref(null),icoIndicatorLeftOnRef=ref(null),icoIndicatorRightOffRef=ref(null),icoIndicatorRightOnRef=ref(null),icoLightsOffRef=ref(null),icoLightsOnRef=ref(null),icoLightsHighRef=ref(null),layer3Ref=ref(null),layer4Ref=ref(null),layer6Ref=ref(null),layer7Ref=ref(null),layer10Ref=ref(null),layer11Ref=ref(null),layer12Ref=ref(null),tickLayerRef=ref(null),speedUnitTextRef=ref(null),rpm_max=ref(8e3),rpmLegendTextRef=ref(null),revNeedleRef=ref(null),displayMode=ref(2);onMounted(()=>{rpmLegendTextRef?.value&&(rpmLegendTextRef.value.textContent=`x1000 RPM`),oilTempBarRef.value.style.strokeDasharray=oilTempBarLen.value+` `+oilTempBarLen.value,speedTextRef.value.textContent=``,revcurveRef.value.style.strokeDasharray=revCurveLen.value+` `+revCurveLen.value,fuelBarRef.value.style.strokeDasharray=fuelBarLen.value+` `+fuelBarLen.value,rpmTextGuideLineRef.value.style.display=`none`;for(let k=0;kisCareer=isActive)});function applyData(data$1){speedTextRef.value.textContent=data$1.speedtext,(speedTextRef.value.textContent==`-Infinity`||speedTextRef.value.textContent==`Infinity`)&&(speedTextRef.value.textContent=`-`),gearTextRef.value.textContent=data$1.geartext,fuelBarRef.value.style[`stroke-dashoffset`]=(1-data$1.fuel)*fuelBarLen.value;let fuelLow=data$1.fuel<.1,fuelGoneLow=lastFuelLevel>=.1&&fuelLow;lastFuelLevel=data$1.fuel,fuelWarnIcoOffRef.value.style.visibility=fuelLow?`hidden`:`visible`,fuelWarnIcoOnRef.value.style.visibility=fuelLow?`visible`:`hidden`,data$1.ignition&&isCareer&&fuelGoneLow&&!shouldPlayFuelLowSound&&setTimeout(()=>shouldPlayFuelLowSound=!0,0),shouldPlayFuelLowSound&&!lowFuelSoundPlayed&&(lowFuelSoundPlayed=!0,Lua_default.ui_audio.playEventSound(`bng_career_fuel`,`low_fuel`)),icoHandBrakeOffRef.value.style.visibility=data$1.parkingBrake?`hidden`:`visible`,icoHandBrakeOnRef.value.style.visibility=data$1.parkingBrake?`visible`:`hidden`,icoABSOffRef.value.style.visibility=data$1.absWorking?`hidden`:`visible`,icoABSOnRef.value.style.visibility=data$1.absWorking?`visible`:`hidden`,icoIndicatorLeftOffRef.value.style.visibility=data$1.signalL?`hidden`:`visible`,icoIndicatorLeftOnRef.value.style.visibility=data$1.signalL?`visible`:`hidden`,icoIndicatorRightOffRef.value.style.visibility=data$1.signalR?`hidden`:`visible`,icoIndicatorRightOnRef.value.style.visibility=data$1.signalR?`visible`:`hidden`;let tempNormalized=Math.max(Math.min((data$1.waterTemp-50)/80,1),0);oilTempBarRef.value.style.strokeDashoffset=(1+tempNormalized)*oilTempBarLen.value;let oilTemp_warn=tempNormalized>.8125;if(oilTempIcoOffRef.value.style.visibility=oilTemp_warn?`hidden`:`visible`,oilTempIcoOnRef.value.style.visibility=oilTemp_warn?`visible`:`hidden`,data$1.lowBeam!==void 0&&data$1.highBeam!==void 0){let nb=!0,lb=data$1.lowBeam>.9,hb=data$1.highBeam>.9;lb&&(nb=!1),hb&&(nb=!1),icoLightsOffRef.value.style.visibility=nb?`visible`:`hidden`,icoLightsOnRef.value.style.visibility=lb?`visible`:`hidden`,icoLightsHighRef.value.style.visibility=hb?`visible`:`hidden`}else icoLightsOffRef.value.style.visibility=`hidden`,icoLightsOnRef.value.style.visibility=`hidden`,icoLightsHighRef.value.style.visibility=`hidden`;let rpm_rotation=data$1.rpm*270-180;rpm_rotation<-180&&(rpm_rotation=-180),rpm_rotation>90&&(rpm_rotation=90),revNeedleRef.value.setAttribute(`transform`,`rotate(`+rpm_rotation+`,330,330)`);let revCurveOffset=(1-data$1.rpm)*revCurveLen.value;revCurveOffset<0&&(revCurveOffset=0),revCurveOffset>revCurveLen.value&&(revCurveOffset=revCurveLen.value),revcurveRef.value.style.strokeDashoffset=revCurveOffset}let data=ref({}),layersVisible=!1;function setlayersVisible(v){if(layersVisible!=v){let val=v?`inline`:`none`;layer3Ref.value.style.display=val,layer4Ref.value.style.display=val,layer6Ref.value.style.display=val,layer7Ref.value.style.display=val,layer10Ref.value.style.display=val,layer11Ref.value.style.display=val,layer12Ref.value.style.display=val,tickLayerRef.value.style.display=val,layersVisible=v}}function reset$1(){setlayersVisible(!1),initialized.value=!1;for(let k=0;k=0?1:-1,inx=nx*sign,iny=ny*sign,x1=pt.x+inx*tickInnerOffset,y1=pt.y+iny*tickInnerOffset,x2=x1+inx*tickMarkLength,y2=y1+iny*tickMarkLength;line.setAttribute(`x1`,x1),line.setAttribute(`y1`,y1),line.setAttribute(`x2`,x2),line.setAttribute(`y2`,y2),line.style.visibility=`visible`}}for(let k=dashCount$1+1;k<=maxRpmTexts;k++){let rp=rpmTextRefs.value[k];rp&&(rp.style.visibility=`hidden`);let line=tickMarkRefs.value[k];line&&(line.style.visibility=`hidden`)}initialized.value=!0}if(!isStreamValid)return!1;if(setlayersVisible(!0),displayMode.value==2)streams.electrics.wheelspeed?(data.speedtext=UnitSpeed(streams.electrics.wheelspeed),streams.electrics.wheelspeed>9e3&&(speedUnitTextRef.value.textContent=`brrrr`)):streams.electrics.airspeed&&(data.speedtext=UnitSpeed(streams.electrics.airspeed)),(function(){if(streams.engineInfo[13]==`manual`){let gear=streams.engineInfo[5],gearStr=gear.toString();gear==0?gearStr=`N`:gear==-1?gearStr=`R`:-gear>1&&(gearStr=`R`+-gear),data.geartext=gearStr}else data.geartext=[`P`,`R`,`N`,`D`,`2`,`1`][Math.round(streams.electrics.gear_A*5)]})(),data.fuel=streams.engineInfo[11]/streams.engineInfo[12],data.parkingBrake=streams.electrics.parkingbrake,data.absWorking=streams.electrics.abs,data.signalL=streams.electrics.signal_L,data.signalR=streams.electrics.signal_R,data.waterTemp=streams.electrics.watertemp,data.lowBeam=streams.electrics.lowbeam,data.highBeam=streams.electrics.highbeam,data.rpm=(streams.electrics.rpmTacho||0)/rpm_max.value;else if(displayMode.value==0){testVar+=.04,testVar>1&&(testVar=1),data.speedtext=Math.round(testVar*100),data.geartext=Math.round(testVar*5),data.fuel=testVar;let boolTest=!0;data.parkingBrake=!0,data.absWorking=!0,data.signalL=!0,data.signalR=!0,data.oilTemp=testVar,data.lowBeam=!0,data.highBeam=!1,data.rpm=testVar,testVar>=1&&(testVar=0,displayMode.value=1)}else if(displayMode.value==1){streams.electrics.wheelspeed?data.speedtext=UnitSpeed(streams.electrics.wheelspeed):(data.speedtext=``,speedUnitTextRef.value.textContent=``),(function(){let gear=streams.engineInfo[5],gearStr=gear.toString();gear==0?gearStr=`N`:gear==-1&&(gearStr=`R`),data.geartext=gearStr})(),data.parkingBrake=streams.electrics.parkingbrake,data.absWorking=streams.electrics.abs,data.signalL=streams.electrics.signal_L,data.signalR=streams.electrics.signal_R,data.lowBeam=streams.electrics.lowbeam,data.highBeam=streams.electrics.highbeam;let oilok=Math.abs(data.oilTemp-streams.electrics.oiltemp)<.005;oilok||(data.oilTemp+=(streams.electrics.oiltemp-data.oilTemp)*.2);let rpmperc=streams.electrics.rpm/rpm_max.value,rpmok=Math.abs(data.rpm-rpmperc)<.005;rpmok||(data.rpm+=(rpmperc-data.rpm)*.2);let fuelperc=streams.engineInfo[11]/streams.engineInfo[12],fuelok=Math.abs(data.fuel-fuelperc)<.005;fuelok||(data.fuel+=(fuelperc-data.fuel)*.2),oilok&&rpmok&&fuelok&&(displayMode.value=2)}return data.engineRunning=streams.electrics.engineRunning,data.ignition=streams.electrics.ignition,applyData(data),!0}function vehicleChanged(){initialized.value=!1}let UiUnitscallback=ref(()=>null);function UnitSpeed(val){let convertedVal=UiUnitscallback.value(val,`speed`);return speedUnitTextRef.value.textContent=convertedVal.unit,Math.round(convertedVal.val)}function wireThroughUnitSystem(callback){UiUnitscallback.value=callback}return __expose({wireThroughUnitSystem,update:update$6,vehicleChanged}),(_ctx,_cache)=>(openBlock(),createElementBlock(`svg`,_hoisted_1$160,[_cache[17]||=createBaseVNode(`defs`,{id:`defs4`},[createBaseVNode(`linearGradient`,{id:`linearGradient3938`},[createBaseVNode(`stop`,{style:{"stop-color":`#ff0000`,"stop-opacity":`1`},offset:`0`,id:`stop3940`}),createBaseVNode(`stop`,{style:{"stop-color":`#00ff4b`,"stop-opacity":`1`},offset:`1`,id:`stop3942`})]),createBaseVNode(`linearGradient`,{id:`linearGradient4607`},[createBaseVNode(`stop`,{id:`stop4609`,offset:`0`,style:{"stop-color":`#e40000`,"stop-opacity":`1`}}),createBaseVNode(`stop`,{style:{"stop-color":`#e40000`,"stop-opacity":`1`},offset:`0.89960396`,id:`stop4611`}),createBaseVNode(`stop`,{id:`stop4613`,offset:`1`,style:{"stop-color":`#e40000`,"stop-opacity":`0`}}),createBaseVNode(`stop`,{id:`stop4615`,offset:`1`,style:{"stop-color":`#e40000`,"stop-opacity":`0`}})]),createBaseVNode(`linearGradient`,{id:`linearGradient4597`},[createBaseVNode(`stop`,{id:`stop4599`,offset:`0`,style:{"stop-color":`#e40000`,"stop-opacity":`1`}}),createBaseVNode(`stop`,{style:{"stop-color":`#e40000`,"stop-opacity":`1`},offset:`0.99812102`,id:`stop4601`}),createBaseVNode(`stop`,{id:`stop4603`,offset:`1`,style:{"stop-color":`#e40000`,"stop-opacity":`0`}}),createBaseVNode(`stop`,{id:`stop4605`,offset:`1`,style:{"stop-color":`#e40000`,"stop-opacity":`1`}})]),createBaseVNode(`linearGradient`,{id:`linearGradient4545`},[createBaseVNode(`stop`,{style:{"stop-color":`#e40000`,"stop-opacity":`1`},offset:`0`,id:`stop4547`}),createBaseVNode(`stop`,{id:`stop4553`,offset:`0.9861111`,style:{"stop-color":`#e40000`,"stop-opacity":`1`}}),createBaseVNode(`stop`,{style:{"stop-color":`#e40000`,"stop-opacity":`0`},offset:`1`,id:`stop4555`}),createBaseVNode(`stop`,{style:{"stop-color":`#e40000`,"stop-opacity":`0`},offset:`1`,id:`stop4549`})]),createBaseVNode(`linearGradient`,{id:`linearGradient4256`},[createBaseVNode(`stop`,{style:{"stop-color":`#6d0000`,"stop-opacity":`1`},offset:`0`,id:`stop4258`}),createBaseVNode(`stop`,{style:{"stop-color":`#6d0000`,"stop-opacity":`0`},offset:`1`,id:`stop4260`})]),createBaseVNode(`linearGradient`,{id:`linearGradient4365`},[createBaseVNode(`stop`,{style:{"stop-color":`#000000`,"stop-opacity":`0.42857143`},offset:`0`,id:`stop4367`}),createBaseVNode(`stop`,{id:`stop4373`,offset:`0.5`,style:{"stop-color":`#000000`,"stop-opacity":`0.33035713`}}),createBaseVNode(`stop`,{style:{"stop-color":`#000000`,"stop-opacity":`0`},offset:`1`,id:`stop4369`})]),createBaseVNode(`linearGradient`,{id:`linearGradient4357`},[createBaseVNode(`stop`,{style:{"stop-color":`#000000`,"stop-opacity":`1`},offset:`0`,id:`stop4359`}),createBaseVNode(`stop`,{style:{"stop-color":`#000000`,"stop-opacity":`0.19642857`},offset:`1`,id:`stop4361`})]),createBaseVNode(`marker`,{style:{overflow:`visible`},id:`DistanceStart`,refX:`0`,refY:`0`,orient:`auto`},[createBaseVNode(`g`,{id:`g2300`},[createBaseVNode(`path`,{style:{fill:`none`,stroke:`#ffffff`,"stroke-width":`1.14999998`,"stroke-linecap":`square`},d:`M 0,0 2,0`,id:`path2306`}),createBaseVNode(`path`,{style:{fill:`#000000`,"fill-rule":`evenodd`,stroke:`none`},d:`M 0,0 13,4 9,0 13,-4 0,0 z`,id:`path2302`}),createBaseVNode(`path`,{style:{fill:`none`,stroke:`#000000`,"stroke-width":`1`,"stroke-linecap":`square`},d:`M 0,-4 0,40`,id:`path2304`})])]),createBaseVNode(`radialGradient`,{"xlink:href":`#linearGradient4357`,id:`radialGradient4363`,cx:`480`,cy:`544`,fx:`480`,fy:`544`,r:`320`,gradientUnits:`userSpaceOnUse`,gradientTransform:`matrix(1.03125,0,0,1.03125,-15,-17)`}),createBaseVNode(`radialGradient`,{"xlink:href":`#linearGradient4365`,id:`radialGradient4371`,cx:`480`,cy:`544`,fx:`480`,fy:`544`,r:`320`,gradientUnits:`userSpaceOnUse`}),createBaseVNode(`clipPath`,{clipPathUnits:`userSpaceOnUse`,id:`clipPath4407`},[createBaseVNode(`path`,{id:`path4409`,d:`m 480,-103.33 c -357.5105,0 -647.33,289.8195 -647.33,647.33 0,357.5105 289.8195,647.33 647.33,647.33 357.5105,0 647.33,-289.8195 647.33,-647.33 0,-357.5105 -289.8195,-647.33 -647.33,-647.33 z m 0,453.131 c 107.25316,0 194.199,86.94584 194.199,194.199 0,107.25316 -86.94584,194.199 -194.199,194.199 -107.25316,0 -194.199,-86.94584 -194.199,-194.199 0,-107.25316 86.94584,-194.199 194.199,-194.199 z`,style:{color:`#000000`,fill:`#ffffff`,"fill-opacity":`0.61375661`,"fill-rule":`nonzero`,stroke:`none`,"stroke-width":`16`,marker:`none`,visibility:`visible`,display:`inline`,overflow:`visible`,"enable-background":`accumulate`}})]),createBaseVNode(`clipPath`,{clipPathUnits:`userSpaceOnUse`,id:`clipPath4321-9`},[createBaseVNode(`path`,{style:{color:`#000000`,fill:`#ffffff`,"fill-opacity":`1`,"fill-rule":`nonzero`,stroke:`none`,"stroke-width":`5`,marker:`none`,visibility:`visible`,display:`inline`,overflow:`visible`,"enable-background":`accumulate`},d:`m 480,224 c -20.28024,0 -40.11069,1.89279 -59.34375,5.5 l 12.0625,58.8125 C 448.05208,285.49499 463.85489,284 480,284 c 35.52728,0 69.40254,7.13112 100.25,20.03125 l 24.1875,-54.9375 C 566.18747,232.93508 524.13347,224 480,224 z m -69.0625,7.5 c -59.26533,13.0371 -112.35258,42.49901 -154.28125,83.375 l 42.53125,42.3125 c 24.37935,-23.60266 53.35266,-42.49216 85.46875,-55.15625 1.96795,-0.77601 3.94641,-1.52096 5.9375,-2.25 10.51172,-3.84886 21.33856,-7.01901 32.4375,-9.5 L 410.9375,231.5 z M 613.5,253.125 589.3125,308.03125 c 44.07702,20.45389 81.43119,52.91567 107.9375,93.15625 l 50.875,-31.875 C 715.25578,318.96815 668.59379,278.45303 613.5,253.125 z m -363.8125,68.75 c -41.23795,42.75016 -70.70543,96.92973 -83.125,157.34375 l 59.03125,11.0625 c 10.15322,-48.33557 33.70357,-91.7229 66.625,-126.09375 L 249.6875,321.875 z m 503.78125,55.8125 -50.90625,31.84375 C 726.31882,448.76688 740,494.78478 740,544 l 60,0 c 0,-60.90677 -16.99384,-117.84887 -46.53125,-166.3125 z m -588.75,111.25 C 161.61652,506.82573 160,525.2248 160,544 c 0,42.78463 8.42108,83.60181 23.65625,120.90625 L 238.84375,641.375 C 226.69144,611.30216 220,578.42944 220,544 c 0,-2.24366 0.0373,-4.48871 0.0937,-6.71875 0.3211,-12.67426 1.55282,-25.12039 3.625,-37.28125 l -59,-11.0625 z M 242.75,650.5 187.53125,674 c 23.4008,52.56805 60.5346,97.67196 106.875,130.71875 l 34.0625,-49.4375 C 291.42063,728.66516 261.6562,692.55546 242.75,650.5 z m 93.875,110.40625 -34.03125,49.40625 C 353.37348,844.20872 414.36502,864 480,864 l 0,-60 c -33.65485,0 -65.82451,-6.39115 -95.34375,-18.03125 -1.96795,-0.77601 -3.93088,-1.58396 -5.875,-2.40625 -14.80462,-6.26183 -28.90394,-13.88046 -42.15625,-22.65625 z`,id:`path4323-8`,"inkscape:connector-curvature":`0`})]),createBaseVNode(`radialGradient`,{"xlink:href":`#linearGradient4357`,id:`radialGradient4363-9`,cx:`480`,cy:`544`,fx:`480`,fy:`544`,r:`320`,gradientUnits:`userSpaceOnUse`,gradientTransform:`matrix(1.03125,0,0,1.03125,-15,-17)`}),createBaseVNode(`clipPath`,{clipPathUnits:`userSpaceOnUse`,id:`clipPath4407-3`},[createBaseVNode(`path`,{id:`path4409-5`,d:`m 480,-103.33 c -357.5105,0 -647.33,289.8195 -647.33,647.33 0,357.5105 289.8195,647.33 647.33,647.33 357.5105,0 647.33,-289.8195 647.33,-647.33 0,-357.5105 -289.8195,-647.33 -647.33,-647.33 z m 0,453.131 c 107.25316,0 194.199,86.94584 194.199,194.199 0,107.25316 -86.94584,194.199 -194.199,194.199 -107.25316,0 -194.199,-86.94584 -194.199,-194.199 0,-107.25316 86.94584,-194.199 194.199,-194.199 z`,style:{color:`#000000`,fill:`#ffffff`,"fill-opacity":`0.61375661`,"fill-rule":`nonzero`,stroke:`none`,"stroke-width":`16`,marker:`none`,visibility:`visible`,display:`inline`,overflow:`visible`,"enable-background":`accumulate`}})]),createBaseVNode(`radialGradient`,{gradientTransform:`matrix(0.37015162,0,0,0.37015162,685.90181,-270.76027)`,"xlink:href":`#linearGradient4365`,id:`radialGradient4371-4`,cx:`480`,cy:`544`,fx:`480`,fy:`544`,r:`320`,gradientUnits:`userSpaceOnUse`}),createBaseVNode(`linearGradient`,{"xlink:href":`#linearGradient4256`,id:`linearGradient4433`,gradientUnits:`userSpaceOnUse`,x1:`569.20557`,y1:`424.29861`,x2:`890.55139`,y2:`424.29861`}),createBaseVNode(`clipPath`,{clipPathUnits:`userSpaceOnUse`,id:`clipPath4321-4`},[createBaseVNode(`path`,{style:{color:`#000000`,fill:`#ffffff`,"fill-opacity":`1`,"fill-rule":`nonzero`,stroke:`none`,"stroke-width":`5`,marker:`none`,visibility:`visible`,display:`inline`,overflow:`visible`,"enable-background":`accumulate`},d:`m 480,224 c -20.28024,0 -40.11069,1.89279 -59.34375,5.5 l 12.0625,58.8125 C 448.05208,285.49499 463.85489,284 480,284 c 35.52728,0 69.40254,7.13112 100.25,20.03125 l 24.1875,-54.9375 C 566.18747,232.93508 524.13347,224 480,224 z m -69.0625,7.5 c -59.26533,13.0371 -112.35258,42.49901 -154.28125,83.375 l 42.53125,42.3125 c 24.37935,-23.60266 53.35266,-42.49216 85.46875,-55.15625 1.96795,-0.77601 3.94641,-1.52096 5.9375,-2.25 10.51172,-3.84886 21.33856,-7.01901 32.4375,-9.5 L 410.9375,231.5 z M 613.5,253.125 589.3125,308.03125 c 44.07702,20.45389 81.43119,52.91567 107.9375,93.15625 l 50.875,-31.875 C 715.25578,318.96815 668.59379,278.45303 613.5,253.125 z m -363.8125,68.75 c -41.23795,42.75016 -70.70543,96.92973 -83.125,157.34375 l 59.03125,11.0625 c 10.15322,-48.33557 33.70357,-91.7229 66.625,-126.09375 L 249.6875,321.875 z m 503.78125,55.8125 -50.90625,31.84375 C 726.31882,448.76688 740,494.78478 740,544 l 60,0 c 0,-60.90677 -16.99384,-117.84887 -46.53125,-166.3125 z m -588.75,111.25 C 161.61652,506.82573 160,525.2248 160,544 c 0,42.78463 8.42108,83.60181 23.65625,120.90625 L 238.84375,641.375 C 226.69144,611.30216 220,578.42944 220,544 c 0,-2.24366 0.0373,-4.48871 0.0937,-6.71875 0.3211,-12.67426 1.55282,-25.12039 3.625,-37.28125 l -59,-11.0625 z M 242.75,650.5 187.53125,674 c 23.4008,52.56805 60.5346,97.67196 106.875,130.71875 l 34.0625,-49.4375 C 291.42063,728.66516 261.6562,692.55546 242.75,650.5 z m 93.875,110.40625 -34.03125,49.40625 C 353.37348,844.20872 414.36502,864 480,864 l 0,-60 c -33.65485,0 -65.82451,-6.39115 -95.34375,-18.03125 -1.96795,-0.77601 -3.93088,-1.58396 -5.875,-2.40625 -14.80462,-6.26183 -28.90394,-13.88046 -42.15625,-22.65625 z`,id:`path4323-7`,"inkscape:connector-curvature":`0`})]),createBaseVNode(`radialGradient`,{"xlink:href":`#linearGradient4357`,id:`radialGradient4363-5`,cx:`480`,cy:`544`,fx:`480`,fy:`544`,r:`320`,gradientUnits:`userSpaceOnUse`,gradientTransform:`matrix(1.03125,0,0,1.03125,-15,-17)`}),createBaseVNode(`clipPath`,{clipPathUnits:`userSpaceOnUse`,id:`clipPath4407-6`},[createBaseVNode(`path`,{id:`path4409-1`,d:`m 480,-103.33 c -357.5105,0 -647.33,289.8195 -647.33,647.33 0,357.5105 289.8195,647.33 647.33,647.33 357.5105,0 647.33,-289.8195 647.33,-647.33 0,-357.5105 -289.8195,-647.33 -647.33,-647.33 z m 0,453.131 c 107.25316,0 194.199,86.94584 194.199,194.199 0,107.25316 -86.94584,194.199 -194.199,194.199 -107.25316,0 -194.199,-86.94584 -194.199,-194.199 0,-107.25316 86.94584,-194.199 194.199,-194.199 z`,style:{color:`#000000`,fill:`#ffffff`,"fill-opacity":`0.61375661`,"fill-rule":`nonzero`,stroke:`none`,"stroke-width":`16`,marker:`none`,visibility:`visible`,display:`inline`,overflow:`visible`,"enable-background":`accumulate`}})]),createBaseVNode(`radialGradient`,{gradientTransform:`matrix(0.36968813,0,0,0.36968813,1026.9451,-270.68256)`,"xlink:href":`#linearGradient4365`,id:`radialGradient4371-49`,cx:`480`,cy:`544`,fx:`480`,fy:`544`,r:`320`,gradientUnits:`userSpaceOnUse`}),createBaseVNode(`linearGradient`,{"xlink:href":`#linearGradient4256`,id:`linearGradient4746`,gradientUnits:`userSpaceOnUse`,x1:`569.20557`,y1:`424.29861`,x2:`890.55139`,y2:`424.29861`}),createBaseVNode(`clipPath`,{clipPathUnits:`userSpaceOnUse`,id:`clipPath3921`},[createBaseVNode(`path`,{"inkscape:connector-curvature":`0`,id:`path3923`,d:`m 480,224 c -20.95323,0 -41.43416,2.01857 -61.26367,5.86328 l 12.08008,58.80274 C 446.74495,285.61583 463.18224,284 480,284 c 36.22419,0 70.7135,7.41519 102.04492,20.79883 l 24.1836,-54.92188 C 567.49749,233.23259 524.82925,224 480,224 z m -67.13867,7.07812 c -60.69914,12.96113 -115.01734,43.12659 -157.60938,85.15821 l 42.54297,42.3125 c 34.42536,-33.82645 78.22177,-58.13556 127.14258,-68.68555 l -12.07617,-58.78516 z m 198.86328,21.20508 -24.1875,54.9336 c 45.44422,20.67199 83.88358,54.04459 110.80078,95.58008 l 50.87305,-31.84376 C 715.93577,319.29347 668.20331,277.82636 611.72461,252.2832 z m -360.70117,68.21094 c -42.37565,43.40627 -72.5223,98.80082 -84.8418,160.63281 l 58.99024,11.05664 c 10.06229,-49.7524 34.33605,-94.34359 68.39257,-129.3789 l -42.54101,-42.31055 z m 501.3789,55.54102 -50.86132,31.83398 C 725.92383,447.46544 740,494.08649 740,544 l 60,0 C 800,482.39079 782.57195,424.85952 752.40234,376.03516 z M 165.06055,487.02148 C 161.7373,505.51211 160,524.55271 160,544 c 0,43.47625 8.68492,84.91949 24.39062,122.71094 l 55.21485,-23.5293 C 226.98058,612.61583 220,579.12541 220,544 c 0,-15.6701 1.38639,-31.01527 4.04297,-45.92188 l -58.98242,-11.05664 z m 76.90039,161.67774 -55.20899,23.52734 c 23.61428,53.92719 61.65397,100.09134 109.25586,133.60352 l 34.03516,-49.41406 C 291.73258,729.3212 261.08736,692.12046 241.96094,648.69922 z m 93.01953,111.12695 -34.04102,49.42188 C 352.04051,843.81227 413.66249,864 480,864 l 0,-60 c -53.69777,0 -103.59151,-16.28243 -145.01953,-44.17383 z`,style:{color:`#000000`,fill:`#ffffff`,"fill-opacity":`1`,"fill-rule":`nonzero`,stroke:`none`,"stroke-width":`5`,marker:`none`,visibility:`visible`,display:`inline`,overflow:`visible`,"enable-background":`accumulate`}})]),createBaseVNode(`clipPath`,{clipPathUnits:`userSpaceOnUse`,id:`clipPath3925-1`},[createBaseVNode(`path`,{"inkscape:connector-curvature":`0`,id:`path3927-7`,d:`m 330,10 c -20.95323,0 -41.43416,2.01857 -61.26367,5.86328 l 12.08008,58.80274 C 296.74495,71.61583 313.18224,70 330,70 c 36.22419,0 70.7135,7.41519 102.04492,20.79883 l 24.1836,-54.92188 C 417.49749,19.23259 374.82925,10 330,10 z m -67.13867,7.07812 C 202.16219,30.03925 147.84399,60.20471 105.25195,102.23633 l 42.54297,42.3125 C 182.22028,110.72238 226.01669,86.41327 274.9375,75.86328 L 262.86133,17.07812 z m 198.86328,21.20508 -24.1875,54.9336 c 45.44422,20.67199 83.88358,54.04459 110.80078,95.58008 l 50.87305,-31.84376 C 565.93577,105.29347 518.20331,63.82636 461.72461,38.2832 z m -360.70117,68.21094 c -42.37565,43.40627 -72.5223,98.80082 -84.8418,160.63281 l 58.99024,11.05664 c 10.06229,-49.7524 34.33605,-94.34359 68.39257,-129.3789 l -42.54101,-42.31055 z m 501.3789,55.54102 -50.86132,31.83398 C 575.92383,233.46544 590,280.08649 590,330 l 60,0 C 650,268.39079 632.57195,210.85952 602.40234,162.03516 z M 15.06055,273.02148 C 11.7373,291.51211 10,310.55271 10,330 c 0,43.47625 8.68492,84.91949 24.39062,122.71094 l 55.21485,-23.5293 C 76.98058,398.61583 70,365.12541 70,330 c 0,-15.6701 1.38639,-31.01527 4.04297,-45.92188 L 15.06055,273.02148 z m 76.90039,161.67774 -55.20899,23.52734 c 23.61428,53.92719 61.65397,100.09134 109.25586,133.60352 l 34.03516,-49.41406 C 141.73258,515.3212 111.08736,478.12046 91.96094,434.69922 z m 93.01953,111.12695 -34.04102,49.42188 C 202.04051,629.81227 263.66249,650 330,650 l 0,-60 c -53.69777,0 -103.59151,-16.28243 -145.01953,-44.17383 z`,style:{color:`#000000`,fill:`#ffffff`,"fill-opacity":`1`,"fill-rule":`nonzero`,stroke:`none`,"stroke-width":`5`,marker:`none`,visibility:`visible`,display:`inline`,overflow:`visible`,"enable-background":`accumulate`}})]),createBaseVNode(`clipPath`,{clipPathUnits:`userSpaceOnUse`,id:`clipPath4036`},[createBaseVNode(`path`,{style:{color:`#000000`,fill:`#ffffff`,"fill-opacity":`1`,"fill-rule":`nonzero`,stroke:`none`,"stroke-width":`5`,marker:`none`,visibility:`visible`,display:`inline`,overflow:`visible`,"enable-background":`accumulate`},d:`m 480,224 c -20.95323,0 -41.43416,2.01857 -61.26367,5.86328 l 12.08008,58.80274 C 446.74495,285.61583 463.18224,284 480,284 c 36.22419,0 70.7135,7.41519 102.04492,20.79883 l 24.1836,-54.92188 C 567.49749,233.23259 524.82925,224 480,224 z m -67.13867,7.07812 c -60.69914,12.96113 -115.01734,43.12659 -157.60938,85.15821 l 42.54297,42.3125 c 34.42536,-33.82645 78.22177,-58.13556 127.14258,-68.68555 l -12.07617,-58.78516 z m 198.86328,21.20508 -24.1875,54.9336 c 45.44422,20.67199 83.88358,54.04459 110.80078,95.58008 l 50.87305,-31.84376 C 715.93577,319.29347 668.20331,277.82636 611.72461,252.2832 z m -360.70117,68.21094 c -42.37565,43.40627 -72.5223,98.80082 -84.8418,160.63281 l 58.99024,11.05664 c 10.06229,-49.7524 34.33605,-94.34359 68.39257,-129.3789 l -42.54101,-42.31055 z m 501.3789,55.54102 -50.86132,31.83398 C 725.92383,447.46544 740,494.08649 740,544 l 60,0 C 800,482.39079 782.57195,424.85952 752.40234,376.03516 z M 165.06055,487.02148 C 161.7373,505.51211 160,524.55271 160,544 c 0,43.47625 8.68492,84.91949 24.39062,122.71094 l 55.21485,-23.5293 C 226.98058,612.61583 220,579.12541 220,544 c 0,-15.6701 1.38639,-31.01527 4.04297,-45.92188 l -58.98242,-11.05664 z m 76.90039,161.67774 -55.20899,23.52734 c 23.61428,53.92719 61.65397,100.09134 109.25586,133.60352 l 34.03516,-49.41406 C 291.73258,729.3212 261.08736,692.12046 241.96094,648.69922 z m 93.01953,111.12695 -34.04102,49.42188 C 352.04051,843.81227 413.66249,864 480,864 l 0,-60 c -53.69777,0 -103.59151,-16.28243 -145.01953,-44.17383 z`,id:`path4038`,"inkscape:connector-curvature":`0`})]),createBaseVNode(`linearGradient`,{"inkscape:collect":`always`,"xlink:href":`#linearGradient4545`,id:`linearGradient4551`,x1:`480`,y1:`214`,x2:`480`,y2:`474`,gradientUnits:`userSpaceOnUse`}),createBaseVNode(`linearGradient`,{"inkscape:collect":`always`,"xlink:href":`#linearGradient4545-2`,id:`linearGradient4551-8`,x1:`480`,y1:`214`,x2:`480`,y2:`474`,gradientUnits:`userSpaceOnUse`}),createBaseVNode(`linearGradient`,{id:`linearGradient4545-2`},[createBaseVNode(`stop`,{style:{"stop-color":`#e40000`,"stop-opacity":`1`},offset:`0`,id:`stop4547-4`}),createBaseVNode(`stop`,{id:`stop4553-5`,offset:`0.99000001`,style:{"stop-color":`#e40000`,"stop-opacity":`0`}}),createBaseVNode(`stop`,{style:{"stop-color":`#000000`,"stop-opacity":`0`},offset:`1`,id:`stop4555-5`}),createBaseVNode(`stop`,{style:{"stop-color":`#000000`,"stop-opacity":`0`},offset:`1`,id:`stop4549-1`})]),createBaseVNode(`linearGradient`,{y2:`282.59341`,x2:`474.60886`,y1:`211.1199`,x1:`480`,gradientUnits:`userSpaceOnUse`,id:`linearGradient4574`,"xlink:href":`#linearGradient4607`,"inkscape:collect":`always`,gradientTransform:`matrix(1,0,0,0.9882541,0,10.359887)`}),createBaseVNode(`clipPath`,{clipPathUnits:`userSpaceOnUse`,id:`clipPath4036-1`},[createBaseVNode(`path`,{style:{color:`#000000`,fill:`#ffffff`,"fill-opacity":`1`,"fill-rule":`nonzero`,stroke:`none`,"stroke-width":`5`,marker:`none`,visibility:`visible`,display:`inline`,overflow:`visible`,"enable-background":`accumulate`},d:`m 480,224 c -20.95323,0 -41.43416,2.01857 -61.26367,5.86328 l 12.08008,58.80274 C 446.74495,285.61583 463.18224,284 480,284 c 36.22419,0 70.7135,7.41519 102.04492,20.79883 l 24.1836,-54.92188 C 567.49749,233.23259 524.82925,224 480,224 z m -67.13867,7.07812 c -60.69914,12.96113 -115.01734,43.12659 -157.60938,85.15821 l 42.54297,42.3125 c 34.42536,-33.82645 78.22177,-58.13556 127.14258,-68.68555 l -12.07617,-58.78516 z m 198.86328,21.20508 -24.1875,54.9336 c 45.44422,20.67199 83.88358,54.04459 110.80078,95.58008 l 50.87305,-31.84376 C 715.93577,319.29347 668.20331,277.82636 611.72461,252.2832 z m -360.70117,68.21094 c -42.37565,43.40627 -72.5223,98.80082 -84.8418,160.63281 l 58.99024,11.05664 c 10.06229,-49.7524 34.33605,-94.34359 68.39257,-129.3789 l -42.54101,-42.31055 z m 501.3789,55.54102 -50.86132,31.83398 C 725.92383,447.46544 740,494.08649 740,544 l 60,0 C 800,482.39079 782.57195,424.85952 752.40234,376.03516 z M 165.06055,487.02148 C 161.7373,505.51211 160,524.55271 160,544 c 0,43.47625 8.68492,84.91949 24.39062,122.71094 l 55.21485,-23.5293 C 226.98058,612.61583 220,579.12541 220,544 c 0,-15.6701 1.38639,-31.01527 4.04297,-45.92188 l -58.98242,-11.05664 z m 76.90039,161.67774 -55.20899,23.52734 c 23.61428,53.92719 61.65397,100.09134 109.25586,133.60352 l 34.03516,-49.41406 C 291.73258,729.3212 261.08736,692.12046 241.96094,648.69922 z m 93.01953,111.12695 -34.04102,49.42188 C 352.04051,843.81227 413.66249,864 480,864 l 0,-60 c -53.69777,0 -103.59151,-16.28243 -145.01953,-44.17383 z`,id:`path4038-7`,"inkscape:connector-curvature":`0`})]),createBaseVNode(`radialGradient`,{"xlink:href":`#linearGradient4357-0`,id:`radialGradient4363-4`,cx:`480`,cy:`544`,fx:`480`,fy:`544`,r:`320`,gradientUnits:`userSpaceOnUse`,gradientTransform:`matrix(1.03125,0,0,1.03125,-15,-17)`}),createBaseVNode(`linearGradient`,{id:`linearGradient4357-0`},[createBaseVNode(`stop`,{style:{"stop-color":`#000000`,"stop-opacity":`0.65178573`},offset:`0`,id:`stop4359-9`}),createBaseVNode(`stop`,{style:{"stop-color":`#000000`,"stop-opacity":`0.24107143`},offset:`1`,id:`stop4361-4`})]),createBaseVNode(`clipPath`,{clipPathUnits:`userSpaceOnUse`,id:`clipPath4407-8`},[createBaseVNode(`path`,{id:`path4409-8`,d:`m 480,-103.33 c -357.5105,0 -647.33,289.8195 -647.33,647.33 0,357.5105 289.8195,647.33 647.33,647.33 357.5105,0 647.33,-289.8195 647.33,-647.33 0,-357.5105 -289.8195,-647.33 -647.33,-647.33 z m 0,453.131 c 107.25316,0 194.199,86.94584 194.199,194.199 0,107.25316 -86.94584,194.199 -194.199,194.199 -107.25316,0 -194.199,-86.94584 -194.199,-194.199 0,-107.25316 86.94584,-194.199 194.199,-194.199 z`,style:{color:`#000000`,fill:`#ffffff`,"fill-opacity":`0.61375661`,"fill-rule":`nonzero`,stroke:`none`,"stroke-width":`16`,marker:`none`,visibility:`visible`,display:`inline`,overflow:`visible`,"enable-background":`accumulate`}})]),createBaseVNode(`radialGradient`,{"xlink:href":`#linearGradient4365-4`,id:`radialGradient4371-2`,cx:`480`,cy:`544`,fx:`480`,fy:`544`,r:`320`,gradientUnits:`userSpaceOnUse`}),createBaseVNode(`linearGradient`,{id:`linearGradient4365-4`},[createBaseVNode(`stop`,{style:{"stop-color":`#000000`,"stop-opacity":`0.42857143`},offset:`0`,id:`stop4367-5`}),createBaseVNode(`stop`,{id:`stop4373-5`,offset:`0.5`,style:{"stop-color":`#000000`,"stop-opacity":`0.33035713`}}),createBaseVNode(`stop`,{style:{"stop-color":`#000000`,"stop-opacity":`0`},offset:`1`,id:`stop4369-1`})]),createBaseVNode(`radialGradient`,{r:`320`,fy:`544`,fx:`480`,cy:`544`,cx:`480`,gradientUnits:`userSpaceOnUse`,id:`radialGradient3997`,"xlink:href":`#linearGradient4365-4`}),createBaseVNode(`radialGradient`,{"xlink:href":`#linearGradient4357-0-7`,id:`radialGradient4363-4-1`,cx:`480`,cy:`544`,fx:`480`,fy:`544`,r:`320`,gradientUnits:`userSpaceOnUse`,gradientTransform:`matrix(1.03125,0,0,1.03125,-15,-17)`}),createBaseVNode(`linearGradient`,{id:`linearGradient4357-0-7`},[createBaseVNode(`stop`,{style:{"stop-color":`#000000`,"stop-opacity":`0.51785713`},offset:`0`,id:`stop4359-9-4`}),createBaseVNode(`stop`,{style:{"stop-color":`#000000`,"stop-opacity":`0.11607143`},offset:`1`,id:`stop4361-4-0`})]),createBaseVNode(`radialGradient`,{r:`320`,fy:`544`,fx:`480`,cy:`544`,cx:`480`,gradientTransform:`matrix(1.03125,0,0,1.03125,-15,-17)`,gradientUnits:`userSpaceOnUse`,id:`radialGradient4001`,"xlink:href":`#linearGradient4357-0-7`}),createBaseVNode(`radialGradient`,{"xlink:href":`#linearGradient4357-0-7`,id:`radialGradient4040`,gradientUnits:`userSpaceOnUse`,gradientTransform:`matrix(1.03125,0,0,1.03125,-885,-231)`,cx:`480`,cy:`544`,fx:`480`,fy:`544`,r:`320`}),createBaseVNode(`radialGradient`,{"xlink:href":`#linearGradient4357-0-7`,id:`radialGradient4045`,gradientUnits:`userSpaceOnUse`,gradientTransform:`matrix(1.03125,0,0,1.03125,-885,-231)`,cx:`480`,cy:`544`,fx:`480`,fy:`544`,r:`320`}),createBaseVNode(`radialGradient`,{"inkscape:collect":`always`,"xlink:href":`#linearGradient4357-0-7-2`,id:`radialGradient4045-8`,gradientUnits:`userSpaceOnUse`,gradientTransform:`matrix(1.03125,0,0,1.03125,-885,-231)`,cx:`480`,cy:`544`,fx:`480`,fy:`544`,r:`320`}),createBaseVNode(`linearGradient`,{id:`linearGradient4357-0-7-2`},[createBaseVNode(`stop`,{style:{"stop-color":`#000000`,"stop-opacity":`0.51785713`},offset:`0`,id:`stop4359-9-4-4`}),createBaseVNode(`stop`,{style:{"stop-color":`#000000`,"stop-opacity":`0.11607143`},offset:`1`,id:`stop4361-4-0-5`})]),createBaseVNode(`radialGradient`,{r:`320`,fy:`544`,fx:`480`,cy:`544`,cx:`480`,gradientTransform:`matrix(1.03125,0,0,1.03125,-758.53125,-231)`,gradientUnits:`userSpaceOnUse`,id:`radialGradient4063`,"xlink:href":`#linearGradient4357-0-7-2`,"inkscape:collect":`always`}),createBaseVNode(`radialGradient`,{"inkscape:collect":`always`,"xlink:href":`#linearGradient4357-0-7`,id:`radialGradient4082`,gradientUnits:`userSpaceOnUse`,gradientTransform:`matrix(1.03125,0,0,1.03125,-885,-231)`,cx:`480`,cy:`544`,fx:`480`,fy:`544`,r:`320`}),createBaseVNode(`radialGradient`,{"inkscape:collect":`always`,"xlink:href":`#linearGradient4357-0-8`,id:`radialGradient4363-4-9`,cx:`480`,cy:`544`,fx:`480`,fy:`544`,r:`320`,gradientUnits:`userSpaceOnUse`,gradientTransform:`matrix(1.03125,0,0,1.03125,-15,-17)`}),createBaseVNode(`linearGradient`,{id:`linearGradient4357-0-8`},[createBaseVNode(`stop`,{style:{"stop-color":`#000000`,"stop-opacity":`0.51785713`},offset:`0`,id:`stop4359-9-40`}),createBaseVNode(`stop`,{style:{"stop-color":`#000000`,"stop-opacity":`0.11607143`},offset:`1`,id:`stop4361-4-7`})]),createBaseVNode(`radialGradient`,{r:`320`,fy:`544`,fx:`480`,cy:`544`,cx:`480`,gradientTransform:`matrix(1.03125,0,0,1.03125,-15,-17)`,gradientUnits:`userSpaceOnUse`,id:`radialGradient4031-1`,"xlink:href":`#linearGradient4357-0-8-5`,"inkscape:collect":`always`}),createBaseVNode(`linearGradient`,{id:`linearGradient4357-0-8-5`},[createBaseVNode(`stop`,{style:{"stop-color":`#000000`,"stop-opacity":`0.51785713`},offset:`0`,id:`stop4359-9-40-4`}),createBaseVNode(`stop`,{style:{"stop-color":`#000000`,"stop-opacity":`0.11607143`},offset:`1`,id:`stop4361-4-7-2`})]),createBaseVNode(`radialGradient`,{"inkscape:collect":`always`,"xlink:href":`#linearGradient4357-0-3`,id:`radialGradient4363-4-0`,cx:`480`,cy:`544`,fx:`480`,fy:`544`,r:`320`,gradientUnits:`userSpaceOnUse`,gradientTransform:`matrix(1.03125,0,0,1.03125,-15,-17)`}),createBaseVNode(`linearGradient`,{id:`linearGradient4357-0-3`},[createBaseVNode(`stop`,{style:{"stop-color":`#000000`,"stop-opacity":`0.65178573`},offset:`0`,id:`stop4359-9-8`}),createBaseVNode(`stop`,{style:{"stop-color":`#000000`,"stop-opacity":`0.24107143`},offset:`1`,id:`stop4361-4-01`})]),createBaseVNode(`clipPath`,{clipPathUnits:`userSpaceOnUse`,id:`clipPath4407-8-2`},[createBaseVNode(`path`,{"inkscape:connector-curvature":`0`,id:`path4409-8-5`,d:`m 480,-103.33 c -357.5105,0 -647.33,289.8195 -647.33,647.33 0,357.5105 289.8195,647.33 647.33,647.33 357.5105,0 647.33,-289.8195 647.33,-647.33 0,-357.5105 -289.8195,-647.33 -647.33,-647.33 z m 0,453.131 c 107.25316,0 194.199,86.94584 194.199,194.199 0,107.25316 -86.94584,194.199 -194.199,194.199 -107.25316,0 -194.199,-86.94584 -194.199,-194.199 0,-107.25316 86.94584,-194.199 194.199,-194.199 z`,style:{color:`#000000`,fill:`#ffffff`,"fill-opacity":`0.61375661`,"fill-rule":`nonzero`,stroke:`none`,"stroke-width":`16`,marker:`none`,visibility:`visible`,display:`inline`,overflow:`visible`,"enable-background":`accumulate`}})]),createBaseVNode(`radialGradient`,{r:`320`,fy:`544`,fx:`480`,cy:`544`,cx:`480`,gradientTransform:`matrix(1.03125,0,0,1.03125,-15,-17)`,gradientUnits:`userSpaceOnUse`,id:`radialGradient4401`,"xlink:href":`#linearGradient4357-0-3`,"inkscape:collect":`always`}),createBaseVNode(`radialGradient`,{r:`320`,fy:`544`,fx:`480`,cy:`544`,cx:`480`,gradientUnits:`userSpaceOnUse`,id:`radialGradient3997-4`,"xlink:href":`#linearGradient4365-4-7`,"inkscape:collect":`always`}),createBaseVNode(`linearGradient`,{id:`linearGradient4365-4-7`},[createBaseVNode(`stop`,{style:{"stop-color":`#000000`,"stop-opacity":`0.42857143`},offset:`0`,id:`stop4367-5-8`}),createBaseVNode(`stop`,{id:`stop4373-5-3`,offset:`0.5`,style:{"stop-color":`#000000`,"stop-opacity":`0.33035713`}}),createBaseVNode(`stop`,{style:{"stop-color":`#000000`,"stop-opacity":`0`},offset:`1`,id:`stop4369-1-5`})]),createBaseVNode(`radialGradient`,{r:`320`,fy:`544`,fx:`480`,cy:`544`,cx:`480`,gradientUnits:`userSpaceOnUse`,id:`radialGradient4458`,"xlink:href":`#linearGradient4365-4-7`,"inkscape:collect":`always`}),createBaseVNode(`clipPath`,{clipPathUnits:`userSpaceOnUse`,id:`clipPath4710`},[createBaseVNode(`path`,{style:{color:`#000000`,"font-style":`normal`,"font-variant":`normal`,"font-weight":`normal`,"font-stretch":`normal`,"font-size":`medium`,"line-height":`normal`,"font-family":`sans-serif`,"text-indent":`0`,"text-align":`start`,"text-decoration":`none`,"text-decoration-line":`none`,"text-decoration-style":`solid`,"text-decoration-color":`#000000`,"letter-spacing":`normal`,"word-spacing":`normal`,"text-transform":`none`,direction:`ltr`,"block-progression":`tb`,"writing-mode":`lr-tb`,"baseline-shift":`baseline`,"text-anchor":`start`,"white-space":`normal`,"clip-rule":`nonzero`,display:`inline`,overflow:`visible`,visibility:`visible`,opacity:`1`,isolation:`auto`,"mix-blend-mode":`normal`,"color-interpolation":`sRGB`,"color-interpolation-filters":`linearRGB`,"solid-color":`#000000`,"solid-opacity":`1`,fill:`#000000`,"fill-opacity":`1`,"fill-rule":`nonzero`,stroke:`none`,"stroke-width":`66.66205597`,"stroke-linecap":`butt`,"stroke-linejoin":`miter`,"stroke-miterlimit":`0.40000001`,"stroke-dasharray":`none`,"stroke-dashoffset":`0`,"stroke-opacity":`1`,"color-rendering":`auto`,"image-rendering":`auto`,"shape-rendering":`auto`,"text-rendering":`auto`,"enable-background":`accumulate`},d:`m 480,224 c -176.33633,0 -320,143.66367 -320,320 0,176.33633 143.66368,320 320,320 l 0,-66.66211 C 339.69052,797.33789 226.66211,684.30947 226.66211,544 226.66211,403.69051 339.69051,290.66211 480,290.66211 620.30948,290.66211 733.33789,403.69052 733.33789,544 L 800,544 C 800,367.66368 656.33632,224 480,224 Z`,id:`path4712`,"inkscape:connector-curvature":`0`})])],-1),createBaseVNode(`g`,{ref_key:`layer6Ref`,ref:layer6Ref,id:`layer6`,class:`layer6`},[_cache[1]||=createBaseVNode(`circle`,{transform:`translate(-150,-214)`,id:`path4281-5`,class:`circle1`,cx:`480`,cy:`544`,r:`320`,d:`M 800,544 C 800,720.73112 656.73112,864 480,864 303.26888,864 160,720.73112 160,544 160,367.26888 303.26888,224 480,224 c 176.73112,0 320,143.26888 320,320 z`},null,-1),_cache[2]||=createBaseVNode(`path`,{transform:`translate(-150,-214)`,id:`path4281`,class:`path1`,d:`M 480,214 C 297.74603,214 150,361.74603 150,544 150,726.25397 297.74603,874 480,874 662.25397,874 810,726.25397 810,544 810,361.74603 662.25397,214 480,214 z`,"clip-path":`url(#clipPath4407-8)`},null,-1),createBaseVNode(`text`,_hoisted_2$132,[createBaseVNode(`tspan`,{ref_key:`speedTextRef`,ref:speedTextRef,id:`tacho2speed`,class:`tacho2-speed`,x:`329.88641`,y:`289.30463`},`0`,512)]),createBaseVNode(`text`,_hoisted_3$118,[createBaseVNode(`tspan`,{ref_key:`speedUnitTextRef`,ref:speedUnitTextRef,id:`speedunit`,x:`330`,y:`348`},`mph`,512)]),createBaseVNode(`text`,_hoisted_4$96,[createBaseVNode(`tspan`,{ref_key:`gearTextRef`,ref:gearTextRef,id:`tacho2gear`,class:`text`,x:`386.67343`,y:`457.94861`},`4`,512)]),(openBlock(),createElementBlock(Fragment,null,renderList(maxRpmTexts,k=>createBaseVNode(`text`,{ref_for:!0,ref:el=>setRpmRef(el,k),"xml:space":`preserve`,x:`0`,y:`0`,class:`rpm-text`},[..._cache[0]||=[createBaseVNode(`tspan`,{x:`0`,y:`0`},null,-1)]],512)),64)),createBaseVNode(`text`,_hoisted_5$83,[createBaseVNode(`tspan`,{ref_key:`rpmLegendTextRef`,ref:rpmLegendTextRef,id:`tspan4449-3-1`,x:`330.09229`,y:`498.18045`},`x1000 RPM`,512)]),_cache[3]||=createBaseVNode(`path`,{"clip-path":`none`,id:`path4258`,class:`path-oil-fuel`,d:`M 462.44226,446.99523 C 489.99031,415.832 506.71155,374.86426 506.71155,330 c 0,-44.86426 -16.72124,-85.832 -44.26929,-116.99523 m -264.88452,0 C 170.00969,244.168 153.28845,285.13574 153.28845,330 c 0,44.86426 16.72124,85.832 44.26929,116.99523`},null,-1),createBaseVNode(`path`,{ref_key:`fuelBarRef`,ref:fuelBarRef,id:`fuel`,class:`fuel-bar`,d:`M 462.44226,446.99523 C 489.99031,415.832 506.71155,374.86426 506.71155,330 c 0,-44.86426 -16.72124,-85.832 -44.26929,-116.99523`},null,512),createBaseVNode(`path`,{ref_key:`oilTempBarRef`,ref:oilTempBarRef,id:`temp`,class:`oil-temp-bar`,d:`M 197.55774,213.00477 C 170.00969,244.168 153.28845,285.13574 153.28845,330 c 0,44.86426 16.72124,85.832 44.26929,116.99523`},null,512)],512),createBaseVNode(`g`,{ref_key:`layer3Ref`,ref:layer3Ref,id:`layer3`,class:`layer3`},[createBaseVNode(`g`,_hoisted_6$69,[_cache[4]||=createBaseVNode(`rect`,{y:`203.90677`,x:`141.28131`,height:`683.79401`,width:`683.79401`,id:`rect4001`,class:`layer3-rect`},null,-1),createBaseVNode(`path`,{ref_key:`revcurveRef`,ref:revcurveRef,class:`revcurve`,id:`revcurve`,"clip-path":`none`,d:`M 330,690 C 131.17749,690 -30,528.82251 -30,330 -30,131.17749 131.17749,-30 330,-30 c 198.82251,0 360,161.17749 360,360`,transform:`matrix(0.80555556,0,0,0.80555556,214.16667,278.16667)`},null,512),createBaseVNode(`path`,{ref_key:`redLineRef`,ref:redLineRef,class:`redline`,id:`rpm_redline`,d:`M 330,610 C 175.36027,610 50,484.63973 50,330 50,175.36027 175.36027,50 330,50 484.63973,50 610,175.36027 610,330`,transform:`matrix(1.038252,0,0,1.038252,137.37687,201.37687)`},null,512)])],512),createBaseVNode(`g`,{ref_key:`layer11Ref`,ref:layer11Ref,id:`layer11`,class:`layer11`},[createBaseVNode(`path`,{ref_key:`revcurveDashesRef`,ref:revcurveDashesRef,id:`revcurve_dashes`,class:`revcurve-dashes`,d:`M 330,616.66897 C 171.6771,616.66897 43.331027,488.3229 43.331027,330 43.331026,171.67709 171.67709,43.33103 330,43.331031 488.3229,43.331031 616.66897,171.6771 616.66897,330`},null,512),createBaseVNode(`path`,{ref_key:`rpmTextGuideLineRef`,ref:rpmTextGuideLineRef,id:`rpmtextline`,class:`rpm-textline`,d:`M 329,550 C 204.73594,550 104,449.26406 104,325 104,200.73593 204.73593,100 329,100 c 124.26406,0 225,100.73594 225,225`},null,512)],512),_cache[18]||=createBaseVNode(`g`,{id:`layer2`,style:{display:`none`}},[createBaseVNode(`g`,{style:{display:`inline`},id:`ico_handbrake_12343525ron`,transform:`translate(-4.2182737e-6,-2.0000051)`},[createBaseVNode(`path`,{transform:`matrix(0.43850147,2.6141077e-4,-2.6141077e-4,0.43850147,320.9902,18.916914)`,style:{display:`inline`,fill:`#ff7900`,"fill-opacity":`1`,stroke:`#ffffff`,"stroke-width":`12`,"stroke-miterlimit":`4`,"stroke-dasharray":`none`,"stroke-opacity":`1`},d:`m 631.44636,979.59082 a 65.760933,65.760933 0 0 1 -65.76094,65.76098 65.760933,65.760933 0 0 1 -65.76093,-65.76098 65.760933,65.760933 0 0 1 65.76093,-65.76093 65.760933,65.760933 0 0 1 65.76094,65.76093 z`,id:`path4551-2-7`}),createBaseVNode(`path`,{"sodipodi:nodetypes":`csc`,id:`path4551-7-7-3`,d:`m 546.9327,480.53664 c -10.16748,-6.97507 -16.83385,-18.68164 -16.82592,-31.94291 0.008,-13.00305 6.43054,-24.50375 16.27369,-31.51076`,style:{display:`inline`,fill:`none`,stroke:`#ffffff`,"stroke-width":`5.26201868`,"stroke-linecap":`round`,"stroke-linejoin":`round`,"stroke-miterlimit":`4`,"stroke-opacity":`1`}}),createBaseVNode(`path`,{"sodipodi:nodetypes":`csc`,id:`path4551-7-4-7-72`,d:`m 590.24076,480.56245 c 10.17587,-6.96293 16.8562,-18.66157 16.86414,-31.92282 0.008,-13.00303 -6.40141,-24.51142 -16.23624,-31.5301`,style:{display:`inline`,fill:`none`,stroke:`#ffffff`,"stroke-width":`5.26201868`,"stroke-linecap":`round`,"stroke-linejoin":`round`,"stroke-miterlimit":`4`,"stroke-opacity":`1`}}),createBaseVNode(`g`,{id:`flowRoot5902-7-4`,style:{"font-style":`normal`,"font-variant":`normal`,"font-weight":`bold`,"font-stretch":`normal`,"font-size":`55px`,"line-height":`125%`,"font-family":`'Open Sans'`,"-inkscape-font-specification":`'Open Sans Bold'`,"letter-spacing":`-3.45999861px`,"word-spacing":`0px`,display:`inline`,fill:`#ffffff`,"fill-opacity":`1`,stroke:`none`},transform:`matrix(0.43849858,-0.00161469,0.00161469,0.43849858,259.17408,95.334998)`},[createBaseVNode(`path`,{id:`path3978-3-5`,style:{"-inkscape-font-specification":`'Open Sans Bold'`},d:`m 548.35205,1001.1788 -2.84668,-9.34567 -14.31396,0 -2.84668,9.34567 -8.96973,0 13.85742,-39.4238 10.17822,0 13.91114,39.4238 z m -4.83398,-16.32809 c -2.63186,-8.4684 -4.11339,-13.25762 -4.44458,-14.36768 -0.33124,-1.10999 -0.56846,-1.98727 -0.71167,-2.63183 -0.59084,2.29169 -2.28274,7.95819 -5.07569,16.99951 z`}),createBaseVNode(`path`,{id:`path3980-3-4`,style:{"-inkscape-font-specification":`'Open Sans Bold'`},d:`m 558.77633,961.91614 12.21924,0 c 5.56801,4e-5 9.60975,0.79227 12.12524,2.37671 2.51543,1.5845 3.77316,4.10444 3.77319,7.55981 -3e-5,2.3454 -0.55056,4.27004 -1.65161,5.77393 -1.1011,1.50392 -2.56472,2.40806 -4.39087,2.7124 l 0,0.26855 c 2.48858,0.55504 4.28342,1.59345 5.38453,3.11524 1.10104,1.52182 1.65157,3.54493 1.65161,6.06933 -4e-5,3.58074 -1.29357,6.37371 -3.88062,8.37891 -2.5871,2.00518 -6.10069,3.00778 -10.54077,3.00778 l -14.68994,0 z m 8.32519,15.54931 4.83399,0 c 2.25584,3e-5 3.88954,-0.34909 4.90112,-1.04736 1.01153,-0.69822 1.51731,-1.853 1.51734,-3.46436 -3e-5,-1.50387 -0.55057,-2.58257 -1.65162,-3.23608 -1.10109,-0.65345 -2.84222,-0.98019 -5.22338,-0.98022 l -4.37745,0 z m 0,6.60645 0,10.23193 5.42481,0 c 2.29164,1e-5 3.98354,-0.43863 5.07568,-1.31592 1.0921,-0.87727 1.63816,-2.22004 1.63819,-4.02832 -3e-5,-3.25844 -2.3275,-4.88767 -6.98243,-4.88769 z`}),createBaseVNode(`path`,{id:`path3982-5-4`,style:{"-inkscape-font-specification":`'Open Sans Bold'`},d:`m 615.44572,990.27551 c -2e-5,3.54493 -1.27566,6.3379 -3.8269,8.37891 -2.55129,2.04098 -6.10069,3.06148 -10.64819,3.06148 -4.18947,0 -7.89552,-0.7877 -11.11817,-2.36324 l 0,-7.73437 c 2.64974,1.18164 4.89217,2.01416 6.7273,2.49755 1.83511,0.48341 3.51358,0.72511 5.0354,0.7251 1.82615,10e-6 3.22711,-0.34911 4.20288,-1.04736 0.97573,-0.69824 1.4636,-1.73665 1.46362,-3.11524 -2e-5,-0.76984 -0.21486,-1.45466 -0.64453,-2.05444 -0.42971,-0.59976 -1.06081,-1.17715 -1.89331,-1.73218 -0.83254,-0.555 -2.5289,-1.44123 -5.08911,-2.65869 -2.3991,-1.12791 -4.19841,-2.21108 -5.39795,-3.24951 -1.19955,-1.03839 -2.15739,-2.24689 -2.87354,-3.62549 -0.71614,-1.37855 -1.07422,-2.98988 -1.07421,-4.83398 -10e-6,-3.47328 1.17716,-6.20358 3.53149,-8.19092 2.35432,-1.98727 5.6083,-2.98092 9.76196,-2.98096 2.041,4e-5 3.98802,0.24174 5.84107,0.7251 1.853,0.48344 3.79107,1.16377 5.81421,2.04102 l -2.68555,6.47216 c -2.09475,-0.85934 -3.82693,-1.45911 -5.19653,-1.79931 -1.36965,-0.34014 -2.7169,-0.51022 -4.04175,-0.51026 -1.57554,4e-5 -2.78403,0.36706 -3.62549,1.10108 -0.84148,0.73408 -1.26222,1.69192 -1.26221,2.87353 -10e-6,0.73408 0.17008,1.37413 0.51026,1.92017 0.34015,0.54609 0.88174,1.07424 1.62475,1.58447 0.74299,0.51028 2.50202,1.42784 5.2771,2.75269 3.67023,1.75457 6.18569,3.51361 7.54639,5.2771 1.36065,1.76352 2.04099,3.92538 2.04101,6.48559 z`})]),createBaseVNode(`g`,{id:`flowRoot5902-7-5`,style:{"font-style":`normal`,"font-variant":`normal`,"font-weight":`bold`,"font-stretch":`normal`,"font-size":`55px`,"line-height":`125%`,"font-family":`'Open Sans'`,"-inkscape-font-specification":`'Open Sans Bold'`,"letter-spacing":`-3.45999861px`,"word-spacing":`0px`,display:`inline`,fill:`#ffffff`,"fill-opacity":`1`,stroke:`none`},transform:`matrix(0.43849858,-0.00161469,0.00161469,0.43849858,317.47869,20.439182)`},[createBaseVNode(`g`,{transform:`matrix(0.99999322,0.00368229,-0.00368229,0.99999322,0,0)`,style:{"font-style":`normal`,"font-weight":`normal`,"font-size":`94.63018036px`,"line-height":`125%`,"font-family":`sans-serif`,"letter-spacing":`0px`,"word-spacing":`0px`,fill:`#ffffff`,"fill-opacity":`1`,stroke:`none`,"stroke-width":`1px`,"stroke-linecap":`butt`,"stroke-linejoin":`miter`,"stroke-opacity":`1`},id:`text4455`},[createBaseVNode(`path`,{d:`m 607.02483,962.46092 q 0,4.62062 -1.61722,9.05641 -1.61721,4.38958 -4.62061,7.39298 -4.11235,4.06614 -9.19502,6.14542 -5.03647,2.07927 -12.56807,2.07927 l -11.04327,0 0,22.41 -17.74316,0 0,-68.80096 29.20228,0 q 6.56127,0 11.04327,1.15515 4.5282,1.10895 7.99366,3.37305 4.15856,2.72616 6.33024,6.97713 2.2179,4.25096 2.2179,10.21155 z m -18.34384,0.41586 q 0,-2.91099 -1.57101,-4.99026 -1.57101,-2.12549 -3.65028,-2.9572 -2.77237,-1.10895 -5.40612,-1.20136 -2.63375,-0.13862 -7.02334,-0.13862 l -3.0496,0 0,20.60794 5.08267,0 q 4.52821,0 7.43919,-0.55447 2.9572,-0.55447 4.94406,-2.21789 1.70963,-1.4786 2.44893,-3.51167 0.7855,-2.07928 0.7855,-5.03647 z`,style:{"font-style":`normal`,"font-variant":`normal`,"font-weight":`bold`,"font-stretch":`normal`,"font-size":`94.63018036px`,"line-height":`125%`,"font-family":`'Open Sans Extrabold'`,"-inkscape-font-specification":`'Open Sans Extrabold, Bold'`,"text-align":`start`,"writing-mode":`lr-tb`,"text-anchor":`start`,fill:`#ffffff`,"fill-opacity":`1`},id:`path4527`,"inkscape:connector-curvature":`0`})]),createBaseVNode(`path`,{transform:`matrix(0.99999322,0.00368229,-0.00368229,0.99999322,0,0)`,style:{fill:`none`,"fill-opacity":`1`,stroke:`#000000`,"stroke-width":`5.69782162`,"stroke-miterlimit":`4`,"stroke-dasharray":`none`,"stroke-opacity":`1`},d:`m 28.554777,1230.2663 c -137.847287,0 -270.048717,-54.7596 -367.521467,-152.2324 -97.47276,-97.47273 -152.23238,-229.67416 -152.23238,-367.52145 0,-137.84729 54.75963,-270.04871 152.23238,-367.52146 97.47275,-97.47276 229.67418,-152.23238 367.521467,-152.23238 137.847293,0 270.048713,54.75962 367.521463,152.23238 97.47275,97.47275 152.23238,229.67417 152.23238,367.52146 0,137.84729 -54.75962,270.04871 -152.23238,367.52145 -97.47275,97.4728 -229.67417,152.2324 -367.521463,152.2324`,id:`text_path`,"inkscape:connector-curvature":`0`,"sodipodi:nodetypes":`csssssssc`,"inkscape:label":`#path4459`})])])],-1),createBaseVNode(`g`,{ref_key:`layer7Ref`,ref:layer7Ref,"inkscape:groupmode":`layer`,id:`layer7`,class:`layer7`,"inkscape:label":`new2`},[createBaseVNode(`g`,{ref_key:`revNeedleRef`,ref:revNeedleRef,id:`revneedle`,"inkscape:label":`#g4147`},[..._cache[5]||=[createBaseVNode(`rect`,{y:`7`,x:`322.44037`,height:`72`,width:`12`,id:`rect4625`,class:`rev-needle-rect`},null,-1)]],512)],512),createBaseVNode(`g`,{ref_key:`layer4Ref`,ref:layer4Ref,"inkscape:groupmode":`layer`,id:`layer4`,class:`layer4`,"inkscape:label":`Icons bottom right`},[createBaseVNode(`path`,{ref_key:`icoIndicatorLeftOffRef`,ref:icoIndicatorLeftOffRef,id:`ico_indicatorl`,class:`ico-indicator-l`,d:`m 386.4512,577.16251 0.0556,17.08797 15.45962,0.24613 0,10.03868 0,10.03869 -15.45962,0.24608 -0.0556,17.08797 -35.33627,-27.37274 z`,"inkscape:connector-curvature":`0`,"sodipodi:nodetypes":`ccccccccc`,"inkscape:label":`#rect4655-9`},null,512),createBaseVNode(`path`,{ref_key:`icoIndicatorRightOffRef`,ref:icoIndicatorRightOffRef,id:`ico_indicatorr`,class:`ico-indicator-r`,d:`m 442.9256,554.57416 -0.0557,17.08798 -15.45965,0.24611 0,10.03869 0,10.03869 15.45965,0.24608 0.0557,17.08796 35.33627,-27.37273 z`,"inkscape:connector-curvature":`0`,"sodipodi:nodetypes":`ccccccccc`,"inkscape:label":`#rect4655-9-3`},null,512),createBaseVNode(`g`,{ref_key:`icoLightsOffRef`,ref:icoLightsOffRef,id:`ico_lights`,class:`ico-lights`,"inkscape:label":`#g4122`,transform:`translate(-12,-2)`},[..._cache[6]||=[createBaseVNode(`path`,{"inkscape:connector-curvature":`0`,id:`rect5824`,class:`light-source`,d:`m 611.67051,352.21188 19.61837,0 c 0,0 13.56687,7.61647 13.56687,22.35122 0,14.73475 -13.56687,21.08238 -13.56687,21.08238 l -19.61837,0 c 0,0 -1.90879,-4.49141 -1.95206,-21.08238 -0.0435,-16.59097 1.95206,-22.35122 1.95206,-22.35122 z`},null,-1),createBaseVNode(`path`,{class:`light-dash`,"inkscape:connector-curvature":`0`,d:`m 600.68152,355.88611 -13.21963,0`},null,-1),createBaseVNode(`path`,{class:`light-dash`,"inkscape:connector-curvature":`0`,d:`m 600.68152,365.4103 -13.21963,0`},null,-1),createBaseVNode(`path`,{class:`light-dash`,"inkscape:connector-curvature":`0`,d:`m 600.68152,374.58946 -13.21963,0`},null,-1),createBaseVNode(`path`,{class:`light-dash`,"inkscape:connector-curvature":`0`,d:`m 600.68152,384.11369 -13.21963,0`},null,-1),createBaseVNode(`path`,{class:`light-dash`,"inkscape:connector-curvature":`0`,d:`m 600.68152,393.43089 -13.21963,0`},null,-1)]],512),createBaseVNode(`g`,{ref_key:`icoABSOffRef`,ref:icoABSOffRef,id:`ico_abs`,class:`ico-abs-off`,"inkscape:label":`#g4111`},[..._cache[7]||=[createBaseVNode(`path`,{transform:`matrix(0.43849858,-0.00161469,0.00161469,0.43849858,260.26675,95.346428)`,id:`path4551dd`,class:`main`,d:`m 631.44636,979.59082 c 0,36.31878 -29.44217,65.76098 -65.76094,65.76098 -36.31876,0 -65.76093,-29.4422 -65.76093,-65.76098 0,-36.31876 29.44217,-65.76093 65.76093,-65.76093 36.31877,0 65.76094,29.44217 65.76094,65.76093 z`,"inkscape:connector-curvature":`0`},null,-1),createBaseVNode(`path`,{"inkscape:connector-curvature":`0`,id:`path4551-7`,class:`curve-l`,d:`m 488.18221,555.99526 c -10.19731,-6.9315 -16.91369,-18.60946 -16.96251,-31.87062 -0.0478,-13.00297 6.32573,-24.53106 16.1388,-31.5801`},null,-1),createBaseVNode(`path`,{"inkscape:connector-curvature":`0`,id:`path4551-7-4`,class:`curve-r`,d:`m 531.48996,555.83579 c 10.14597,-7.00643 16.77617,-18.73351 16.72734,-31.99467 -0.0478,-13.00299 -6.50623,-24.48382 -16.37094,-31.4604`},null,-1),createBaseVNode(`path`,{"inkscape:connector-curvature":`0`,id:`path3978`,class:`text-a`,d:`m 501.24227,531.46506 -1.26336,-4.09346 -6.27665,0.0231 -1.23317,4.10266 -3.93322,0.0145 6.01281,-17.30965 4.46313,-0.0164 6.16367,17.26482 z m -2.14606,-7.15204 c -1.16774,-3.70913 -1.82512,-5.8068 -1.97214,-6.29303 -0.14704,-0.48619 -0.25248,-0.87049 -0.31632,-1.1529 -0.25538,1.00586 -0.98812,3.49334 -2.19823,7.46246 z`},null,-1),createBaseVNode(`path`,{"inkscape:connector-curvature":`0`,id:`path3980`,class:`text-b`,d:`m 505.7499,514.23161 5.35812,-0.0197 c 2.44157,-0.009 4.21514,0.33189 5.32074,1.02261 1.10557,0.69074 1.66115,1.79369 1.66675,3.30887 0.004,1.02845 -0.23453,1.87329 -0.71491,2.53453 -0.4804,0.66124 -1.12074,1.06007 -1.92101,1.19647 l 4.3e-4,0.11776 c 1.09214,0.23936 1.88085,0.69181 2.36614,1.35733 0.48526,0.66554 0.72994,1.55178 0.73403,2.65873 0.006,1.57015 -0.55694,2.79695 -1.68812,3.6804 -1.1312,0.88345 -2.67028,1.32876 -4.61725,1.33593 l -6.44152,0.0237 z m 3.67569,6.80491 2.1197,-0.008 c 0.98919,-0.004 1.705,-0.15935 2.14745,-0.46718 0.44242,-0.3078 0.66234,-0.81498 0.65975,-1.52156 -0.002,-0.65945 -0.24559,-1.13157 -0.72946,-1.41635 -0.48388,-0.28476 -1.24789,-0.42523 -2.29202,-0.42139 l -1.91951,0.007 z m 0.0107,2.89692 0.0165,4.48668 2.37878,-0.009 c 1.00488,-0.004 1.74606,-0.19878 2.22355,-0.58523 0.47747,-0.38644 0.71474,-0.97613 0.71184,-1.76906 -0.005,-1.42882 -1.0285,-2.13948 -3.06968,-2.13197 z`},null,-1),createBaseVNode(`path`,{"inkscape:connector-curvature":`0`,id:`path3982`,class:`text-s`,d:`m 530.64514,526.57565 c 0.006,1.55445 -0.54914,2.78122 -1.66456,3.68032 -1.11544,0.89909 -2.6702,1.35231 -4.66427,1.35965 -1.83708,0.007 -3.46345,-0.33266 -4.87912,-1.01833 l -0.0125,-3.39151 c 1.16382,0.51387 2.14846,0.87531 2.95395,1.08431 0.80547,0.20901 1.54187,0.31229 2.20918,0.30983 0.80077,-0.003 1.41452,-0.1583 1.84127,-0.46605 0.42673,-0.30776 0.63898,-0.76389 0.63676,-1.3684 -10e-4,-0.33757 -0.0966,-0.63752 -0.28594,-0.89982 -0.18939,-0.2623 -0.46706,-0.51447 -0.83301,-0.75651 -0.36596,-0.24202 -1.11125,-0.62789 -2.23586,-1.15761 -1.05382,-0.49071 -1.84457,-0.96278 -2.37224,-1.41619 -0.52768,-0.4534 -0.94964,-0.98177 -1.2659,-1.58513 -0.31625,-0.60334 -0.47587,-1.30933 -0.47884,-2.11796 -0.006,-1.52303 0.50616,-2.72216 1.53533,-3.59741 1.02915,-0.87522 2.45441,-1.31619 4.27579,-1.32291 0.89497,-0.003 1.74913,0.0996 2.56247,0.30852 0.81332,0.209 1.66426,0.50419 2.55282,0.8856 l -1.16716,2.84237 c -0.91993,-0.37344 -1.68046,-0.63364 -2.28158,-0.7806 -0.60114,-0.14694 -1.19218,-0.21935 -1.77312,-0.21723 -0.69088,0.003 -1.2202,0.16545 -1.588,0.48868 -0.3678,0.32325 -0.55075,0.74394 -0.54884,1.26208 10e-4,0.32189 0.0768,0.60228 0.22685,0.84116 0.15004,0.23892 0.38838,0.46963 0.71501,0.69217 0.32663,0.22256 1.09944,0.62206 2.31845,1.19853 1.61222,0.76345 2.71809,1.53072 3.3176,2.30181 0.59949,0.77111 0.90131,1.71798 0.90545,2.84063 z`},null,-1)]],512),createBaseVNode(`g`,{ref_key:`icoHandBrakeOffRef`,ref:icoHandBrakeOffRef,class:`ico-handbrake-off`,id:`ico_handbrake`,"inkscape:label":`#g4115`,transform:`translate(-3.5925881e-6,-2.0000007)`},[..._cache[8]||=[createBaseVNode(`path`,{transform:`matrix(0.43850147,2.6141077e-4,-2.6141077e-4,0.43850147,320.9902,18.916914)`,id:`path4551-2-74-7`,class:`main`,d:`m 631.44636,979.59082 c 0,36.31878 -29.44217,65.76098 -65.76094,65.76098 -36.31876,0 -65.76093,-29.4422 -65.76093,-65.76098 0,-36.31876 29.44217,-65.76093 65.76093,-65.76093 36.31877,0 65.76094,29.44217 65.76094,65.76093 z`,"inkscape:connector-curvature":`0`},null,-1),createBaseVNode(`path`,{class:`curve-l`,id:`path4551-7-7-0-4`,"inkscape:connector-curvature":`0`,d:`m 546.9327,480.53664 c -10.16748,-6.97507 -16.83385,-18.68164 -16.82592,-31.94291 0.008,-13.00305 6.43054,-24.50375 16.27369,-31.51076`},null,-1),createBaseVNode(`path`,{"inkscape:connector-curvature":`0`,id:`path4551-7-4-7-9-0`,class:`curve-r`,d:`m 590.24076,480.56245 c 10.17587,-6.96293 16.8562,-18.66157 16.86414,-31.92282 0.008,-13.00303 -6.40141,-24.51142 -16.23624,-31.5301`},null,-1),createBaseVNode(`g`,{class:`text-p`,id:`text4055-4-9`},[createBaseVNode(`path`,{"inkscape:connector-curvature":`0`,id:`path3269-4`,d:`m 566.88168,447.27286 2.26429,0 c 2.11628,2e-5 3.6998,-0.41806 4.75057,-1.25424 1.05073,-0.83614 1.57611,-2.05338 1.57612,-3.65172 -10e-6,-1.6131 -0.44029,-2.80444 -1.32083,-3.57403 -0.88058,-0.76954 -2.26061,-1.15432 -4.1401,-1.15435 l -3.13005,0 z m 15.53925,-5.15015 c -3e-5,3.49265 -1.09147,6.16392 -3.27434,8.01381 -2.18292,1.84993 -5.28707,2.77488 -9.31245,2.77487 l -2.95246,0 0,11.54344 -6.88167,0 0,-32.45483 10.3669,0 c 3.93659,3e-5 6.92975,0.84729 8.97947,2.54177 2.04967,1.69455 3.07452,4.22153 3.07455,7.58094 z`})],-1)]],512),createBaseVNode(`g`,{ref_key:`oilTempIcoOffRef`,ref:oilTempIcoOffRef,style:{display:`inline`},id:`ico_temp`,class:`ico-temp`,transform:`matrix(0.82879177,0,0,0.82879177,40.706638,69.281349)`,"inkscape:label":`#g4374`},[..._cache[9]||=[createBaseVNode(`path`,{"inkscape:connector-curvature":`0`,id:`path4347`,class:`path1`,d:`m 199.61025,285.93078 2e-5,37.83129`},null,-1),createBaseVNode(`path`,{"inkscape:connector-curvature":`0`,id:`path4347-5`,class:`path2`,d:`m 208.85791,292.09588 -7.00577,0`},null,-1),createBaseVNode(`path`,{"inkscape:connector-curvature":`0`,id:`path4347-5-4`,class:`path3`,d:`m 208.8579,301.06329 -7.00578,0`},null,-1),createBaseVNode(`path`,{"inkscape:connector-curvature":`0`,id:`path4347-5-3`,class:`path4`,d:`m 208.85793,309.75049 -7.00583,-1e-5`},null,-1),createBaseVNode(`circle`,{transform:`matrix(0.72059621,0,0,0.72059621,-1146.435,-0.73321691)`,id:`path4392`,class:`path5`,cx:`1867.8225`,cy:`454.9176`,r:`14.849242`,d:`m 1882.6718,454.9176 c 0,8.20101 -6.6483,14.84924 -14.8493,14.84924 -8.201,0 -14.8492,-6.64823 -14.8492,-14.84924 0,-8.20101 6.6482,-14.84924 14.8492,-14.84924 8.201,0 14.8493,6.64823 14.8493,14.84924 z`},null,-1),createBaseVNode(`path`,{"inkscape:connector-curvature":`0`,id:`path4347-5-1-2`,class:`path6`,d:`m 183.69241,332.71741 -7.00578,0`},null,-1),createBaseVNode(`path`,{"inkscape:connector-curvature":`0`,id:`path4347-5-1-2-3`,class:`path7`,d:`m 223.32319,343.08941 -46.63658,-10e-6`},null,-1),createBaseVNode(`path`,{"inkscape:connector-curvature":`0`,id:`path4347-5-1-2-34`,class:`path8`,d:`m 222.33239,332.7174 -7.00578,0`},null,-1)]],512),createBaseVNode(`g`,{ref_key:`fuelWarnIcoOffRef`,ref:fuelWarnIcoOffRef,id:`ico_fuel`,class:`ico-fuel`,transform:`matrix(0.88747678,0,0,0.88747678,64.601263,56.302973)`,"inkscape:label":`#g4368`},[..._cache[10]||=[createBaseVNode(`rect`,{id:`rect4466`,class:`rect1`,y:`284.07593`,x:`420.99237`,height:`38.905876`,width:`22.650679`},null,-1),createBaseVNode(`rect`,{id:`rect4466-1`,class:`rect2`,y:`298.80991`,x:`420.99237`,height:`24.171896`,width:`22.650679`},null,-1),createBaseVNode(`path`,{"inkscape:connector-curvature":`0`,id:`path4347-5-1-2-3-3`,class:`path1`,d:`m 448.00445,330.93084 -30.96928,0`},null,-1),createBaseVNode(`path`,{"inkscape:connector-curvature":`0`,id:`path4347-5-1-2-3-3-8`,class:`path2`,d:`m 460.25266,299.90863 0.0166,18.02062 c 0,0 -0.41583,2.18743 -4.92393,2.16693 -4.50811,-0.0205 -4.80496,-2.16693 -4.80496,-2.16693 l 0.0579,-17.71243 -7.25174,-0.0941`},null,-1)]],512)],512),createBaseVNode(`g`,{ref_key:`layer10Ref`,ref:layer10Ref,"inkscape:groupmode":`layer`,id:`layer10`,class:`layer10`,"inkscape:label":`icons bottom right activated`},[createBaseVNode(`path`,{ref_key:`icoIndicatorLeftOnRef`,ref:icoIndicatorLeftOnRef,class:`ico-indicator-l-on`,d:`m 386.4512,577.16251 0.0556,17.08797 15.45962,0.24613 0,10.03868 0,10.03869 -15.45962,0.24608 -0.0556,17.08797 -35.33627,-27.37274 z`,id:`ico_indicatorl_on`,"inkscape:connector-curvature":`0`,"inkscape:label":`#rect4655-9`},null,512),createBaseVNode(`path`,{ref_key:`icoIndicatorRightOnRef`,ref:icoIndicatorRightOnRef,id:`ico_indicatorr_on`,class:`ico-indicator-r-on`,d:`m 442.9256,554.57416 -0.0557,17.08798 -15.45965,0.24611 0,10.03869 0,10.03869 15.45965,0.24608 0.0557,17.08796 35.33627,-27.37273 z`,"inkscape:connector-curvature":`0`,"inkscape:label":`#rect4655-9-3`},null,512),createBaseVNode(`g`,{ref_key:`icoLightsOnRef`,ref:icoLightsOnRef,id:`ico_lights_on`,class:`ico-lights-on`,"inkscape:label":`#g4122`,transform:`translate(-12,-2.0000028)`},[..._cache[11]||=[createBaseVNode(`path`,{"inkscape:connector-curvature":`0`,id:`rect5824-4`,class:`path1`,d:`m 611.67051,352.21188 19.61837,0 c 0,0 13.56687,7.61647 13.56687,22.35122 0,14.73475 -13.56687,21.08238 -13.56687,21.08238 l -19.61837,0 c 0,0 -1.90879,-4.49141 -1.95206,-21.08238 -0.0435,-16.59097 1.95206,-22.35122 1.95206,-22.35122 z`},null,-1),createBaseVNode(`path`,{"inkscape:connector-curvature":`0`,id:`path4347-5-1-2-3-1-1`,class:`path2`,d:`m 600.68152,355.88611 -13.21963,0`},null,-1),createBaseVNode(`path`,{"inkscape:connector-curvature":`0`,id:`path4347-5-1-2-3-1-9-20`,class:`path3`,d:`m 600.68152,365.4103 -13.21963,0`},null,-1),createBaseVNode(`path`,{"inkscape:connector-curvature":`0`,id:`path4347-5-1-2-3-1-8-0`,class:`path4`,d:`m 600.68152,374.58946 -13.21963,0`},null,-1),createBaseVNode(`path`,{"inkscape:connector-curvature":`0`,id:`path4347-5-1-2-3-1-9-6-1`,class:`path5`,d:`m 600.68152,384.11369 -13.21963,0`},null,-1),createBaseVNode(`path`,{"inkscape:connector-curvature":`0`,id:`path4347-5-1-2-3-1-9-6-5-4`,class:`path6`,d:`m 600.68152,393.43089 -13.21963,0`},null,-1)]],512),createBaseVNode(`g`,{ref_key:`icoABSOnRef`,ref:icoABSOnRef,transform:`translate(0,-2.8038025e-6)`,id:`ico_abs_on`,class:`ico-abs-on`,"inkscape:label":`#g4106`},[..._cache[12]||=[createBaseVNode(`path`,{id:`path4551-0`,class:`path1`,"inkscape:connector-curvature":`0`,transform:`matrix(0.43849858,-0.00161469,0.00161469,0.43849858,260.26675,95.34643)`,d:`m 631.44636,979.59082 c 0,36.31878 -29.44217,65.76098 -65.76094,65.76098 -36.31876,0 -65.76093,-29.4422 -65.76093,-65.76098 0,-36.31876 29.44217,-65.76093 65.76093,-65.76093 36.31877,0 65.76094,29.44217 65.76094,65.76093 z`},null,-1),createBaseVNode(`path`,{"inkscape:connector-curvature":`0`,id:`path4551-7-717`,class:`path2`,d:`m 488.18221,555.99526 c -10.19731,-6.9315 -16.91369,-18.60946 -16.96251,-31.87062 -0.0478,-13.00297 6.32573,-24.53106 16.1388,-31.5801`},null,-1),createBaseVNode(`path`,{"inkscape:connector-curvature":`0`,id:`path4551-7-4-77`,class:`path3`,d:`m 531.48996,555.83579 c 10.14597,-7.00643 16.77617,-18.73351 16.72734,-31.99467 -0.0478,-13.00299 -6.50623,-24.48382 -16.37094,-31.4604`},null,-1),createBaseVNode(`g`,{id:`flowRoot5902-7`,class:`text-path`,transform:`matrix(0.43849858,-0.00161469,0.00161469,0.43849858,259.17408,93.335)`},[createBaseVNode(`path`,{id:`path3978-3`,class:`text-path1`,"inkscape:connector-curvature":`0`,d:`m 548.35205,1001.1788 -2.84668,-9.34567 -14.31396,0 -2.84668,9.34567 -8.96973,0 13.85742,-39.4238 10.17822,0 13.91114,39.4238 z m -4.83398,-16.32809 c -2.63186,-8.4684 -4.11339,-13.25762 -4.44458,-14.36768 -0.33124,-1.10999 -0.56846,-1.98727 -0.71167,-2.63183 -0.59084,2.29169 -2.28274,7.95819 -5.07569,16.99951 z`}),createBaseVNode(`path`,{id:`path3980-3`,class:`text-path2`,"inkscape:connector-curvature":`0`,d:`m 558.77633,961.91614 12.21924,0 c 5.56801,4e-5 9.60975,0.79227 12.12524,2.37671 2.51543,1.5845 3.77316,4.10444 3.77319,7.55981 -3e-5,2.3454 -0.55056,4.27004 -1.65161,5.77393 -1.1011,1.50392 -2.56472,2.40806 -4.39087,2.7124 l 0,0.26855 c 2.48858,0.55504 4.28342,1.59345 5.38453,3.11524 1.10104,1.52182 1.65157,3.54493 1.65161,6.06933 -4e-5,3.58074 -1.29357,6.37371 -3.88062,8.37891 -2.5871,2.00518 -6.10069,3.00778 -10.54077,3.00778 l -14.68994,0 z m 8.32519,15.54931 4.83399,0 c 2.25584,3e-5 3.88954,-0.34909 4.90112,-1.04736 1.01153,-0.69822 1.51731,-1.853 1.51734,-3.46436 -3e-5,-1.50387 -0.55057,-2.58257 -1.65162,-3.23608 -1.10109,-0.65345 -2.84222,-0.98019 -5.22338,-0.98022 l -4.37745,0 z m 0,6.60645 0,10.23193 5.42481,0 c 2.29164,1e-5 3.98354,-0.43863 5.07568,-1.31592 1.0921,-0.87727 1.63816,-2.22004 1.63819,-4.02832 -3e-5,-3.25844 -2.3275,-4.88767 -6.98243,-4.88769 z`}),createBaseVNode(`path`,{id:`path3982-5`,class:`text-path3`,"inkscape:connector-curvature":`0`,d:`m 615.44572,990.27551 c -2e-5,3.54493 -1.27566,6.3379 -3.8269,8.37891 -2.55129,2.04098 -6.10069,3.06148 -10.64819,3.06148 -4.18947,0 -7.89552,-0.7877 -11.11817,-2.36324 l 0,-7.73437 c 2.64974,1.18164 4.89217,2.01416 6.7273,2.49755 1.83511,0.48341 3.51358,0.72511 5.0354,0.7251 1.82615,10e-6 3.22711,-0.34911 4.20288,-1.04736 0.97573,-0.69824 1.4636,-1.73665 1.46362,-3.11524 -2e-5,-0.76984 -0.21486,-1.45466 -0.64453,-2.05444 -0.42971,-0.59976 -1.06081,-1.17715 -1.89331,-1.73218 -0.83254,-0.555 -2.5289,-1.44123 -5.08911,-2.65869 -2.3991,-1.12791 -4.19841,-2.21108 -5.39795,-3.24951 -1.19955,-1.03839 -2.15739,-2.24689 -2.87354,-3.62549 -0.71614,-1.37855 -1.07422,-2.98988 -1.07421,-4.83398 -10e-6,-3.47328 1.17716,-6.20358 3.53149,-8.19092 2.35432,-1.98727 5.6083,-2.98092 9.76196,-2.98096 2.041,4e-5 3.98802,0.24174 5.84107,0.7251 1.853,0.48344 3.79107,1.16377 5.81421,2.04102 l -2.68555,6.47216 c -2.09475,-0.85934 -3.82693,-1.45911 -5.19653,-1.79931 -1.36965,-0.34014 -2.7169,-0.51022 -4.04175,-0.51026 -1.57554,4e-5 -2.78403,0.36706 -3.62549,1.10108 -0.84148,0.73408 -1.26222,1.69192 -1.26221,2.87353 -10e-6,0.73408 0.17008,1.37413 0.51026,1.92017 0.34015,0.54609 0.88174,1.07424 1.62475,1.58447 0.74299,0.51028 2.50202,1.42784 5.2771,2.75269 3.67023,1.75457 6.18569,3.51361 7.54639,5.2771 1.36065,1.76352 2.04099,3.92538 2.04101,6.48559 z`})],-1)]],512),createBaseVNode(`g`,{ref_key:`icoHandBrakeOnRef`,ref:icoHandBrakeOnRef,id:`ico_handbrake_on`,class:`ico-handbrake-on`,"inkscape:label":`#g4115`,transform:`translate(-3.5925881e-6,-2.0000007)`},[..._cache[13]||=[createBaseVNode(`path`,{id:`path4551-2-74`,class:`path1`,transform:`matrix(0.43850147,2.6141077e-4,-2.6141077e-4,0.43850147,320.9902,18.916914)`,d:`m 631.44636,979.59082 c 0,36.31878 -29.44217,65.76098 -65.76094,65.76098 -36.31876,0 -65.76093,-29.4422 -65.76093,-65.76098 0,-36.31876 29.44217,-65.76093 65.76093,-65.76093 36.31877,0 65.76094,29.44217 65.76094,65.76093 z`,"inkscape:connector-curvature":`0`},null,-1),createBaseVNode(`path`,{"inkscape:connector-curvature":`0`,id:`path4551-7-7-0`,class:`path2`,d:`m 546.9327,480.53664 c -10.16748,-6.97507 -16.83385,-18.68164 -16.82592,-31.94291 0.008,-13.00305 6.43054,-24.50375 16.27369,-31.51076`},null,-1),createBaseVNode(`path`,{"inkscape:connector-curvature":`0`,id:`path4551-7-4-7-9`,class:`path3`,d:`m 590.24076,480.56245 c 10.17587,-6.96293 16.8562,-18.66157 16.86414,-31.92282 0.008,-13.00303 -6.40141,-24.51142 -16.23624,-31.5301`},null,-1),createBaseVNode(`g`,{class:`text-p`,id:`text4055-4`},[createBaseVNode(`path`,{d:`m 566.88168,447.27286 2.26429,0 c 2.11628,2e-5 3.6998,-0.41806 4.75057,-1.25424 1.05073,-0.83614 1.57611,-2.05338 1.57612,-3.65172 -10e-6,-1.6131 -0.44029,-2.80444 -1.32083,-3.57403 -0.88058,-0.76954 -2.26061,-1.15432 -4.1401,-1.15435 l -3.13005,0 z m 15.53925,-5.15015 c -3e-5,3.49265 -1.09147,6.16392 -3.27434,8.01381 -2.18292,1.84993 -5.28707,2.77488 -9.31245,2.77487 l -2.95246,0 0,11.54344 -6.88167,0 0,-32.45483 10.3669,0 c 3.93659,3e-5 6.92975,0.84729 8.97947,2.54177 2.04967,1.69455 3.07452,4.22153 3.07455,7.58094 z`,id:`path3269`,"inkscape:connector-curvature":`0`})],-1)]],512),createBaseVNode(`g`,{ref_key:`oilTempIcoOnRef`,ref:oilTempIcoOnRef,id:`ico_temp_on`,class:`ico-temp-on`,transform:`matrix(0.82879177,0,0,0.82879177,40.706638,69.281349)`,"inkscape:label":`#g4374`},[..._cache[14]||=[createBaseVNode(`path`,{"inkscape:connector-curvature":`0`,id:`path4347-7`,class:`path1`,d:`m 199.61025,285.93078 2e-5,37.83129`},null,-1),createBaseVNode(`path`,{"inkscape:connector-curvature":`0`,id:`path4347-5-40`,class:`path2`,d:`m 208.85791,292.09588 -7.00577,0`},null,-1),createBaseVNode(`path`,{"inkscape:connector-curvature":`0`,id:`path4347-5-4-9`,class:`path3`,d:`m 208.8579,301.06329 -7.00578,0`},null,-1),createBaseVNode(`path`,{"inkscape:connector-curvature":`0`,id:`path4347-5-3-4`,class:`path4`,d:`m 208.85793,309.75049 -7.00583,-1e-5`},null,-1),createBaseVNode(`circle`,{id:`path4392-8`,class:`circle1`,transform:`matrix(0.72059621,0,0,0.72059621,-1146.435,-0.73321691)`,cx:`1867.8225`,cy:`454.9176`,r:`14.849242`,d:`m 1882.6718,454.9176 c 0,8.20101 -6.6483,14.84924 -14.8493,14.84924 -8.201,0 -14.8492,-6.64823 -14.8492,-14.84924 0,-8.20101 6.6482,-14.84924 14.8492,-14.84924 8.201,0 14.8493,6.64823 14.8493,14.84924 z`},null,-1),createBaseVNode(`path`,{"inkscape:connector-curvature":`0`,id:`path4347-5-1-2-8`,class:`path5`,d:`m 183.69241,332.71741 -7.00578,0`},null,-1),createBaseVNode(`path`,{"inkscape:connector-curvature":`0`,id:`path4347-5-1-2-3-2`,class:`path6`,d:`m 223.32319,343.08941 -46.63658,-10e-6`},null,-1),createBaseVNode(`path`,{"inkscape:connector-curvature":`0`,id:`path4347-5-1-2-34-4`,class:`path7`,d:`m 222.33239,332.7174 -7.00578,0`},null,-1)]],512),createBaseVNode(`g`,{ref_key:`fuelWarnIcoOnRef`,ref:fuelWarnIcoOnRef,id:`ico_fuel_on`,class:`ico-fuel-on`,transform:`matrix(0.88747678,0,0,0.88747678,64.601263,56.302973)`,"inkscape:label":`#g4368-5`},[..._cache[15]||=[createBaseVNode(`rect`,{id:`rect4466-5`,class:`rect1`,y:`284.07593`,x:`420.99237`,height:`38.905876`,width:`22.650679`},null,-1),createBaseVNode(`rect`,{id:`rect4466-1-1`,class:`rect2`,y:`298.80991`,x:`420.99237`,height:`24.171896`,width:`22.650679`},null,-1),createBaseVNode(`path`,{"inkscape:connector-curvature":`0`,id:`path4347-5-1-2-3-3-7`,class:`path1`,d:`m 448.00445,330.93084 -30.96928,0`},null,-1),createBaseVNode(`path`,{"inkscape:connector-curvature":`0`,id:`path4347-5-1-2-3-3-8-1`,class:`path2`,d:`m 460.25266,299.90863 0.0166,18.02062 c 0,0 -0.41583,2.18743 -4.92393,2.16693 -4.50811,-0.0205 -4.80496,-2.16693 -4.80496,-2.16693 l 0.0579,-17.71243 -7.25174,-0.0941`},null,-1)]],512)],512),createBaseVNode(`g`,{ref_key:`layer12Ref`,ref:layer12Ref,"inkscape:groupmode":`layer`,id:`layer12`,class:`layer12`,"inkscape:label":`icons bottom right 2`},[createBaseVNode(`g`,{ref_key:`icoLightsHighRef`,ref:icoLightsHighRef,id:`ico_lights_high`,class:`ico-lights-high`,"inkscape:label":`#g4122`,transform:`translate(-12.000003,-2.0000028)`},[..._cache[16]||=[createBaseVNode(`path`,{"inkscape:connector-curvature":`0`,id:`rect5824-4-9`,class:`path1`,d:`m 611.67051,352.21188 19.61837,0 c 0,0 13.56687,7.61647 13.56687,22.35122 0,14.73475 -13.56687,21.08238 -13.56687,21.08238 l -19.61837,0 c 0,0 -1.90879,-4.49141 -1.95206,-21.08238 -0.0435,-16.59097 1.95206,-22.35122 1.95206,-22.35122 z`},null,-1),createBaseVNode(`path`,{"inkscape:connector-curvature":`0`,id:`path4347-5-1-2-3-1-1-8`,class:`path2`,d:`m 600.68152,355.88611 -13.21963,0`},null,-1),createBaseVNode(`path`,{"inkscape:connector-curvature":`0`,id:`path4347-5-1-2-3-1-9-20-1`,class:`path3`,d:`m 600.68152,365.4103 -13.21963,0`},null,-1),createBaseVNode(`path`,{"inkscape:connector-curvature":`0`,id:`path4347-5-1-2-3-1-8-0-8`,class:`path4`,d:`m 600.68152,374.58946 -13.21963,0`},null,-1),createBaseVNode(`path`,{"inkscape:connector-curvature":`0`,id:`path4347-5-1-2-3-1-9-6-1-2`,class:`path5`,d:`m 600.68152,384.11369 -13.21963,0`},null,-1),createBaseVNode(`path`,{"inkscape:connector-curvature":`0`,id:`path4347-5-1-2-3-1-9-6-5-4-6`,class:`path6`,d:`m 600.68152,393.43089 -13.21963,0`},null,-1)]],512)],512),createBaseVNode(`g`,{ref_key:`tickLayerRef`,ref:tickLayerRef,id:`tickLayer`,class:`tick-layer`},[(openBlock(),createElementBlock(Fragment,null,renderList(maxRpmTexts,k=>createBaseVNode(`line`,{ref_for:!0,ref:el=>setTickRef(el,k),x1:`0`,y1:`0`,x2:`0`,y2:`0`,class:`tick-line`},null,512)),64))],512)]))}},tacho_default=__plugin_vue_export_helper_default(_sfc_main$179,[[`__scopeId`,`data-v-310c7a2d`]]),_hoisted_1$159={class:`tacho-container`},_sfc_main$178={__name:`app`,setup(__props){let{$game}=useLibStore(),tachoRef=ref(null),visible=ref(!1);ref(!1),onMounted(()=>{tachoRef.value.wireThroughUnitSystem((val,func)=>UiUnits[func](val)),$game.streams.add([`electrics`,`engineInfo`]),$game.events.on(`onStreamsUpdate`,onStreamsUpdate),$game.events.on(`VehicleChange`,onVehicleChange),$game.events.on(`VehicleFocusChanged`,onVehicleFocusChanged)}),onUnmounted(()=>{$game.streams.remove([`electrics`,`engineInfo`]),$game.events.off(`onStreamsUpdate`,onStreamsUpdate),$game.events.off(`VehicleChange`,onVehicleChange),$game.events.off(`VehicleFocusChanged`,onVehicleFocusChanged)});let _done=!1;function onStreamsUpdate(streams){tachoRef.value!==null&&(_done||=!0,tachoRef.value.update(streams)?visible.value||=!0:visible&&(visible.value=!1))}function onVehicleChange(){tachoRef.value!==null&&tachoRef.value.vehicleChanged()}function onVehicleFocusChanged(data){tachoRef.value!==null&&data.mode===!0&&tachoRef.value.vehicleChanged()}return(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$159,[createVNode(tacho_default,{ref_key:`tachoRef`,ref:tachoRef},null,512)]))}},app_default$26=__plugin_vue_export_helper_default(_sfc_main$178,[[`__scopeId`,`data-v-57c978c8`]]),_sfc_main$177={__name:`app`,setup(__props){let{$game}=useLibStore(),store$1=useTasksStore();provide(`animationSettings`,{animate:!0,animateOnMount:!1,animateOnMountIntervalDelay:.2,animateOnEmptyIntervalDelay:.1,animateOnEmpty:!0,animateNextTask:!0,successCallback:playAudio});function playAudio(){$game.lua.Engine.Audio.playOnce(`AudioGui`,`event:>UI>Career>Checkbox`)}return(_ctx,_cache)=>(openBlock(),createBlock(unref(TaskList_default),{header:unref(store$1).header,tasks:unref(store$1).tasks},null,8,[`header`,`tasks`]))}},app_default$27=_sfc_main$177,_hoisted_1$158={class:`pacenote`},_hoisted_2$131=[`id`],_hoisted_3$117=[`fill`,`stroke`],_hoisted_4$95=[`id`],_hoisted_5$82=[`fill`,`stroke`],_hoisted_6$68=[`fill`],_hoisted_7$59={class:`content`},_hoisted_8$49={class:`instruction`},_hoisted_9$43={key:0,class:`modifier`},_hoisted_10$36={key:1,class:`add-note`},_hoisted_11$32={key:0,class:`distance`},_sfc_main$176={__name:`PaceNote`,props:{note:{type:Object,required:!0,validator(value){return value.type===`empty`?!0:typeof value.type==`string`},default:()=>({type:`empty`,typeExt:null,turnModifier:null,background:{color:`var(--bng-cool-gray-600)`,strokeColor:`var(--bng-cool-gray-500)`,opacity:.6},isInto:!1,isLeft:!1,size:5,turnTypeValue:null,distance:null,additionalNote:{color:`#fff`,icon:null,text:null}})}},setup(__props){useCssVars(_ctx=>({v5d4f1806:props.note.size,v654d2548:backgroundColor.value,v7d5e0455:colorNoteIcon.value,v7d630d09:colorNoteText.value,v305678bf:colorDistance.value}));let bgId=uniqueId(``,`_`),props=__props,noteUrl=computed(()=>{if(props.note.typeExt)return props.note.typeExt;let assetPath=noteTypes[props.note.type];return assetPath?getAssetURL(assetPath):null}),backgroundColor=computed(()=>props.note.background&&props.note.background.color?props.note.background.color:`var(--bng-cool-gray-600)`),strokeColor=computed(()=>props.note.background&&props.note.background.strokeColor?props.note.background.strokeColor:`var(--bng-cool-gray-500)`),backgroundOpacity=computed(()=>props.note.background&&props.note.background.opacity?props.note.background.opacity:.6),colorNoteIcon=computed(()=>props.note.colorNoteIcon?props.note.colorNoteIcon:`#fff`),colorNoteText=computed(()=>props.note.colorNoteText?props.note.colorNoteText:`#fff`),intoColor=computed(()=>props.note.intoColor?props.note.intoColor:`#fff`),colorDistance=computed(()=>props.note.colorDistance?props.note.colorDistance:`#ececec`);return(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$158,[createBaseVNode(`div`,{class:`background`,style:normalizeStyle({opacity:backgroundOpacity.value})},[__props.note.isInto?(openBlock(),createElementBlock(`svg`,{key:1,id:`note_${unref(bgId)}`,style:{width:`var(--note-size)`,height:`var(--note-size)`},viewBox:`0 0 56 56`,fill:`none`,xmlns:`http://www.w3.org/2000/svg`},[createBaseVNode(`path`,{d:`M5 47.75H5.54967L5.71519 47.2258L11.3348 29.4304C11.6288 28.4994 11.6288 27.5006 11.3348 26.5696L5.95963 9.54823C5.82856 9.13317 5.7822 8.69601 5.8233 8.26269L6.25669 3.69314C6.41494 2.02457 7.81612 0.75 9.49217 0.75H51.4137C53.3423 0.75 54.8466 2.41974 54.6461 4.33788L49.631 52.3157C49.4572 53.9784 48.0504 55.238 46.3787 55.2278L4.46341 54.9706C2.52935 54.9587 1.03362 53.2707 1.25464 51.3493L1.66867 47.75H5Z`,fill:backgroundColor.value,stroke:strokeColor.value,"stroke-width":`1.5`},null,8,_hoisted_5$82),createBaseVNode(`path`,{d:`M4 11H1L6 28L1 45H4L9.5 28L4 11Z`,fill:intoColor.value},null,8,_hoisted_6$68)],8,_hoisted_4$95)):(openBlock(),createElementBlock(`svg`,{key:0,id:`note_${unref(bgId)}`,style:{width:`var(--note-size)`,height:`var(--note-size)`},viewBox:`0 0 56 56`,fill:`none`,xmlns:`http://www.w3.org/2000/svg`},[createBaseVNode(`path`,{d:`M9.45521 0.75H51.4137C53.3423 0.75 54.8466 2.41974 54.6461 4.33788L49.631 52.3157C49.4572 53.9784 48.0504 55.238 46.3787 55.2278L4.41965 54.9703C2.49833 54.9585 1.00656 53.2915 1.2074 51.3807L6.22301 3.66028C6.39689 2.00598 7.7918 0.75 9.45521 0.75Z`,fill:backgroundColor.value,stroke:strokeColor.value,"stroke-width":`1.5`},null,8,_hoisted_3$117)],8,_hoisted_2$131))],4),createBaseVNode(`div`,_hoisted_7$59,[createBaseVNode(`div`,_hoisted_8$49,[unref(icons)[__props.note.type]?(openBlock(),createBlock(unref(bngIcon_default),{key:0,class:normalizeClass([`note-icon`,{left:__props.note.isLeft}]),type:__props.note.type},null,8,[`type`,`class`])):__props.note.typeExt&¬eUrl.value?(openBlock(),createElementBlock(`div`,{key:1,class:normalizeClass([`note-icon svg-used`,[__props.note.type,{left:__props.note.isLeft}]]),style:normalizeStyle(noteUrl.value?{maskImage:`url(${noteUrl.value})`,WebkitMaskImage:`url(${noteUrl.value})`}:null)},null,6)):createCommentVNode(``,!0),__props.note.turnTypeValue?(openBlock(),createElementBlock(`div`,{key:2,class:normalizeClass([`turn-value`,{left:__props.note.isLeft,"is-into":__props.note.isInto,"text-2-chars":__props.note.turnTypeValue.length===2}])},toDisplayString(__props.note.turnTypeValue),3)):createCommentVNode(``,!0)]),__props.note.turnModifier?(openBlock(),createElementBlock(`div`,_hoisted_9$43,[createVNode(unref(bngIcon_default),{type:__props.note.turnModifier,class:`icon-small`,color:colorNoteIcon.value},null,8,[`type`,`color`])])):createCommentVNode(``,!0),__props.note.additionalNote&&(__props.note.additionalNote.icon||__props.note.additionalNote.text)?(openBlock(),createElementBlock(`div`,_hoisted_10$36,[__props.note.additionalNote.icon?(openBlock(),createBlock(unref(bngIcon_default),{key:0,type:__props.note.additionalNote.icon,color:__props.note.additionalNote.color,class:`icon-small`},null,8,[`type`,`color`])):__props.note.additionalNote.text?(openBlock(),createElementBlock(`span`,{key:1,class:`add-text`,style:normalizeStyle(__props.note.additionalNote.color?{color:__props.note.additionalNote.color}:null)},toDisplayString(__props.note.additionalNote.text),5)):createCommentVNode(``,!0)])):createCommentVNode(``,!0)]),__props.note.distance?(openBlock(),createElementBlock(`div`,_hoisted_11$32,toDisplayString(__props.note.distance),1)):createCommentVNode(``,!0)]))}},PaceNote_default=__plugin_vue_export_helper_default(_sfc_main$176,[[`__scopeId`,`data-v-8c4cf384`]]),_hoisted_1$157={class:`pacenotes-app`},_hoisted_2$130={class:`notes-container`},FADE_DURATION=250,TOTAL_SLOTS=4,DEFAULT_NOTE_SIZE=1.8,_sfc_main$175={__name:`app`,setup(__props){useCssVars(_ctx=>({v492216b0:noteSize.value}));let incomingQueue=ref([]),noteSize=ref(DEFAULT_NOTE_SIZE),events$3=useEvents(),{lua}=useBridge(),devEnv=reactive({env:window.beamng&&!window.beamng.shipping,vue:!1}),debugSlots=computed(()=>incomingQueue.value.map(slot=>slot?`id=${slot.note.id} pnId=${slot.pacenoteId} ts=${slot.serialNo} type=${slot.note.type} isFading=${slot.isFading} isCurrent=${slot.isCurrent}`:null)),firstFourFromQueue=computed(()=>{let result=[...incomingQueue.value.slice(0,TOTAL_SLOTS)];for(;result.length<4;)result.push({id:-1,type:`empty`});return result});function getNoteKey(slot,index){return!slot||!slot.note?`empty-${index}`:`${slot.note.id}-${index}`}function getNoteWithSize(slot){return!slot||!slot.note?{type:`empty`,size:noteSize.value}:{...slot.note,size:noteSize.value}}let mockNotes=[{id:`q1`,pnId:`1`,type:`turn3`,isLeft:!1,turnTypeValue:`3`,distance:`140`,background:{color:`var(--bng-ter-yellow-300)`,strokeColor:`var(--bng-ter-yellow-200)`,opacity:.8}},{id:`q2`,pnId:`2`,type:`turnHp`,isLeft:!0,isInto:!0,background:{color:`var(--bng-add-red-500)`,strokeColor:`var(--bng-add-red-400)`,opacity:.8},additionalNote:{icon:`scissorsSlashed`,color:`var(--bng-add-red-400)`}},{id:`q3`,pnId:`2`,type:`jumpOverBump`,isLeft:!1,turnModifier:`mathLessThan`,additionalNote:{icon:`circleSlashed`,color:`var(--bng-ter-yellow-100)`}},{id:`q4`,pnId:`3`,type:`turn6`,isLeft:!0,turnTypeValue:`6`,distance:`140`,background:{color:`var(--bng-ter-yellow-300)`,strokeColor:`var(--bng-ter-yellow-200)`,opacity:.8}},{id:`q5`,pnId:`3`,type:`rocks`,isLeft:!0,distance:`50`}];function updateCurrent(){if(incomingQueue.value.length===0||(incomingQueue.value=incomingQueue.value.filter(item=>item!==null),incomingQueue.value.length===0))return;let firstPacenoteId=incomingQueue.value[0].pacenoteId;incomingQueue.value.forEach(slot=>{slot&&!slot.isFading&&(slot.isCurrent=slot.pacenoteId===firstPacenoteId)})}function addToQueue(newItems,serialNo){try{(Array.isArray(newItems)?newItems:[newItems]).forEach(note=>{if(!note.id||!note.type){console.warn(`Invalid note format:`,JSON.stringify(note,null,2));return}let val={note,isVisible:!0,isFading:!1,isCurrent:!1,pacenoteId:note.pnId,serialNo};incomingQueue.value.push(val)}),updateCurrent()}catch(error){console.error(`Error adding to queue:`,error)}}onMounted(()=>{lua.pacenotes&&lua.pacenotes.onPaceNotesAppMounted&&lua.pacenotes.onPaceNotesAppMounted(),events$3.on(`showVisualPacenote2`,pacenoteEvent=>{let serialNo=pacenoteEvent.serialNo,notes=pacenoteEvent.visualPacenotes;addToQueue(notes,serialNo)}),events$3.on(`clearOneVisualPacenote`,serialNo=>{clearOne(serialNo)}),events$3.on(`clearAllVisualPacenotes`,()=>{clearAll()})}),onUnmounted(()=>{lua.pacenotes&&lua.pacenotes.onPaceNotesAppUnmounted&&lua.pacenotes.onPaceNotesAppUnmounted()});let testAddSequence=()=>{console.log(`Adding sequence...`);let fakeSerialNo=666,lastPnid=0;mockNotes.forEach(note=>{note.pnId!==lastPnid&&(fakeSerialNo++,lastPnid=note.pnId),addToQueue(note,fakeSerialNo)}),console.log(`Current queue:`,incomingQueue.value)},clearAll=()=>{incomingQueue.value=[]},clearOne=serialNo=>{let fadeCount=0,fadeExpected=0;incomingQueue.value.forEach((item,index)=>{item.serialNo<=serialNo&&(item.isFading=!0,item.isVisible=!1,item.isCurrent=!1,fadeExpected++),setTimeout(()=>{item&&item.isFading&&(incomingQueue.value[index]=null,fadeCount++,fadeCount===fadeExpected&&updateCurrent())},FADE_DURATION)})},testClearAll=()=>{clearAll()},testClearOne=()=>{let serialNo=incomingQueue.value[0].serialNo;clearOne(serialNo)};(devEnv.env||devEnv.vue)&&(window.testPaceNotes={addSequence:testAddSequence,clearAll:testClearAll,clearOne:testClearOne,getState:()=>({queue:incomingQueue.value,slots:debugSlots.value})});function onAnimationEnd(index){let slot=incomingQueue.value[index];slot&&slot.isVisible&&!slot.isFading&&(slot.hasAnimated=!0)}return ref(null),(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$157,[createBaseVNode(`div`,_hoisted_2$130,[_cache[1]||=createBaseVNode(`div`,{class:`spacer`},null,-1),(openBlock(!0),createElementBlock(Fragment,null,renderList(firstFourFromQueue.value,(slot,index)=>(openBlock(),createBlock(PaceNote_default,{key:getNoteKey(slot,index),class:normalizeClass({"pacenote-initial":!slot?.hasAnimated,[`position-${index}`]:!0,"fade-out":slot&&slot.isFading,"fade-in":slot&&slot.isVisible&&!slot.isFading&&!slot.hasAnimated,hidden:!slot||!slot.isVisible&&!slot.isFading,current:slot&&slot.isCurrent}),note:getNoteWithSize(slot),onAnimationend:$event=>onAnimationEnd(index)},null,8,[`class`,`note`,`onAnimationend`]))),128))]),createCommentVNode(``,!0)]))}},app_default$28=__plugin_vue_export_helper_default(_sfc_main$175,[[`__scopeId`,`data-v-13adc0e2`]]),_hoisted_1$156={class:`countdown-top`},_hoisted_2$129={key:0,class:`countdown-go`},_hoisted_3$116={class:`countdown-bottom`},_hoisted_4$94={class:`rally-loop-manager-text`},_hoisted_5$81={class:`time-main`},_hoisted_6$67={key:0,class:`time-period`},_sfc_main$174={__name:`CountdownWidget`,props:{rallyLoopManager:{type:String,default:`--:--:--`},period:{type:String,default:null},countdown:{type:Number,default:10}},setup(__props){let props=__props,stage=computed(()=>props.countdown<=0?6:props.countdown>5?0:6-props.countdown);return(_ctx,_cache)=>(openBlock(),createElementBlock(Fragment,null,[createBaseVNode(`div`,_hoisted_1$156,[stage.value===6?(openBlock(),createElementBlock(`div`,_hoisted_2$129)):(openBlock(),createElementBlock(Fragment,{key:1},[createBaseVNode(`div`,{class:normalizeClass([`countdown-square`,{visible:stage.value>=1}])},null,2),createBaseVNode(`div`,{class:normalizeClass([`countdown-square`,{visible:stage.value>=2}])},null,2),createBaseVNode(`div`,{class:normalizeClass([`countdown-square`,{visible:stage.value>=3}])},null,2),createBaseVNode(`div`,{class:normalizeClass([`countdown-square`,{visible:stage.value>=4}])},null,2),createBaseVNode(`div`,{class:normalizeClass([`countdown-square`,{visible:stage.value>=5}])},null,2)],64))]),createBaseVNode(`div`,_hoisted_3$116,[createBaseVNode(`div`,_hoisted_4$94,[createBaseVNode(`span`,_hoisted_5$81,toDisplayString(__props.rallyLoopManager),1),__props.period?(openBlock(),createElementBlock(`span`,_hoisted_6$67,toDisplayString(__props.period),1)):createCommentVNode(``,!0)])])],64))}},CountdownWidget_default=__plugin_vue_export_helper_default(_sfc_main$174,[[`__scopeId`,`data-v-a0ececba`]]),_hoisted_1$155={class:`vehicle-proximity`},_hoisted_2$128={class:`top-row`},_hoisted_3$115={class:`proximity-status`},_hoisted_4$93={key:2},_sfc_main$173={__name:`VehicleProximity`,props:{vehicleProximity:{type:Object,required:!0},stage:{type:String,required:!0},precision:{type:Number,default:0,validator:value=>value>=0&&value<=2},badgeText:{type:String,default:``},instruction:{type:Object,required:!1,default:()=>({text:``,type:`notice`}),validator:value=>value?typeof value.text==`string`&&[`alert`,`alert-sm`,`notice`].includes(value.type):!0},instruction2:{type:Object,required:!1,default:()=>({structuredText:null})}},setup(__props){let props=__props,distanceDimmed=computed(()=>props.stage===`stop`||props.stage===`staged`),hasLabel=computed(()=>props.stage===`approaching`&&props.badgeText),formattedDistance=computed(()=>{let dist=props.vehicleProximity.distance;if(Math.abs(dist)>200)return`${(dist/1e3).toFixed(2)}km`;if(dist<0){let multiplier=10**props.precision,flooredDist=Math.floor(dist*multiplier)/multiplier;return`${(flooredDist===0?0:flooredDist).toFixed(props.precision)}m`}return`${dist.toFixed(props.precision)}m`});return(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$155,[createBaseVNode(`div`,_hoisted_2$128,[createBaseVNode(`div`,_hoisted_3$115,[createBaseVNode(`div`,{class:normalizeClass([`proximity-status-badge`,[__props.stage,{"has-label":hasLabel.value}]])},[__props.stage===`stop`?(openBlock(),createElementBlock(Fragment,{key:0},[createTextVNode(`STOP`)],64)):__props.stage===`goback`?(openBlock(),createElementBlock(Fragment,{key:1},[createTextVNode(`BACK`)],64)):__props.stage===`slow`?(openBlock(),createElementBlock(Fragment,{key:2},[createTextVNode(`SLOW`)],64)):__props.stage===`staged`?(openBlock(),createElementBlock(Fragment,{key:3},[createTextVNode(`STAGED`)],64)):__props.stage===`approaching`?(openBlock(),createElementBlock(Fragment,{key:4},[createTextVNode(toDisplayString(__props.badgeText),1)],64)):createCommentVNode(``,!0)],2)]),createBaseVNode(`div`,{class:normalizeClass([`proximity-distance`,{dimmed:distanceDimmed.value}])},toDisplayString(formattedDistance.value),3)]),__props.instruction?.text?(openBlock(),createElementBlock(`div`,{key:0,class:normalizeClass([`instruction-row`,__props.instruction?.type||`notice`])},toDisplayString(__props.instruction?.text),3)):createCommentVNode(``,!0),__props.instruction2?.structuredText?(openBlock(),createElementBlock(`div`,{key:1,class:normalizeClass([`instruction-row`,[__props.instruction2?.type||`notice`,{flash:__props.instruction2?.flash}]])},[(openBlock(!0),createElementBlock(Fragment,null,renderList(__props.instruction2?.structuredText,item=>(openBlock(),createElementBlock(Fragment,{key:item.id},[item.type===`clock`?(openBlock(),createElementBlock(`span`,{key:0,class:normalizeClass(item.class)},toDisplayString(item.val),3)):item.type===`penalty`?(openBlock(),createElementBlock(`span`,{key:1,class:normalizeClass(item.class)},toDisplayString(item.val),3)):(openBlock(),createElementBlock(`span`,_hoisted_4$93,toDisplayString(item),1))],64))),128))],2)):createCommentVNode(``,!0)]))}},VehicleProximity_default=__plugin_vue_export_helper_default(_sfc_main$173,[[`__scopeId`,`data-v-871af6e6`]]),_hoisted_1$154={class:`rally-countdown-app-container`},_hoisted_2$127={class:`panel-countdown`},_hoisted_3$114={key:2,class:`section-interact-hint`},_sfc_main$172={__name:`appCountdown`,setup(__props){useCssVars(_ctx=>({v730cc8f6:themeColor.value}));let{lua}=useBridge(),devEnv=reactive({env:window.beamng&&!window.beamng.shipping,vue:!1}),showDebugInfo=ref(!1),ActiveState={INACTIVE:`inactive`,VEHICLE_PROXIMITY:`vehicleProximity`,STAGE_ACTIVE:`stageActive`,COUNTDOWN:`countdown`},rallyClockData=reactive({wallClockTime:null,day:null,totalTime:0,canSkipTimeControls:!1,isTimeControlSkipAvailable:!1,canSkipCountdown:!1,isNgrcMode:!1}),activeState=ref(ActiveState.INACTIVE),vehicleProximityData=reactive({isNear:!1,distance:0,distanceToPlane:0,isStopped:!1,isFrozen:!1,usingGroundMarkerDistance:!1}),scheduleData=reactive({label:null,eventType:null,ssLabel:null,eventWallClockStart:null,eventWallClockEnd:null,timeDiff:null,timeDiffWithEnd:null,lateness:null,penalty:0,hasPenalty:!1,canIncurLatePenalty:!1,speedLimit:null,speedLimitDisplay:null,speedUnit:`km/h`,isSpeeding:!1}),stageData=reactive({currentSSTime:null,isActive:!1,isComplete:!1,splits:[],label:null,completion:{distM:0,distPct:0}}),countdownData=reactive({countdown:null,state:null}),themeColor=computed(()=>`#07ff00`),canInteract=computed(()=>rallyClockData.canSkipTimeControls||rallyClockData.canSkipCountdown),interactLabel=computed(()=>rallyClockData.canSkipCountdown||rallyClockData.canSkipTimeControls?`[action=gameplay_interact]Skip Clock`:``),proximityStage=computed(()=>{scheduleData.eventType;let distance=vehicleProximityData.distance;return scheduleData.eventType===`ss_start`?vehicleProximityData.isNear&&vehicleProximityData.isStopped?`staged`:distance<0?`goback`:vehicleProximityData.isNear&&!vehicleProximityData.isStopped?`stop`:!vehicleProximityData.isNear&&distance>=0&&distance<=25?`slow`:`approaching`:distance<0?`goback`:vehicleProximityData.isNear?`stop`:!vehicleProximityData.isNear&&distance>=0&&distance<=25||scheduleData.eventType===`ss_stop`?`slow`:`approaching`}),distancePrecision=computed(()=>{let distAbs=Math.abs(vehicleProximityData.distance),closenessThreshold=5;if(scheduleData.eventType===`ss_start`){if(distAbs<5)return proximityStage.value===`stop`||proximityStage.value===`goback`||proximityStage.value===`staged`||proximityStage.value===`slow`?2:0}else if((scheduleData.eventType===`tc`||scheduleData.eventType===`ss_stop`)&&distAbs<5)return proximityStage.value===`stop`||proximityStage.value===`goback`?1:0;return 0}),badgeText=computed(()=>scheduleData.eventType===`ss_start`?`SS${scheduleData.ssLabel}`:scheduleData.eventType===`tc`?scheduleData.label:scheduleData.eventType===`ss_stop`?`SLOW`:scheduleData.eventType===`service_in`?`SERVICE`:``),proximityInstruction2=computed(()=>{let stage=proximityStage.value;if(scheduleData.eventType===`ss_start`)return{structuredText:[`Start in `,{type:`clock`,val:scheduleData.timeDiff,class:`clock-badge`}],flash:!1};if(stage===`approaching`){if(rallyClockData.isTimeControlSkipAvailable&&scheduleData.eventType===`tc`)return{structuredText:[`Slow Down for `,{type:`clock`,val:`Clock Skip`,class:`clock-badge`}],flash:!1};if(scheduleData.eventType===`service_in`||scheduleData.label===`TC0`||scheduleData.eventType===`tc`)return{structuredText:[`Limit `,{type:`penalty`,val:`${scheduleData.speedLimitDisplay}${scheduleData.speedUnit}`,class:`penalty-badge`}],flash:scheduleData.isSpeeding}}else return null}),proximityInstruction=computed(()=>{let stage=proximityStage.value,text=``,type=`notice`;return stage===`slow`?scheduleData.eventType===`ss_start`?text=`Stage vehicle at start line.`:scheduleData.eventType===`tc`||scheduleData.eventType:stage===`stop`?scheduleData.eventType:stage===`goback`||(stage===`staged`?vehicleProximityData.isFrozen:stage===`approaching`&&(scheduleData.eventType===`ss_start`?text=`Stage vehicle at start line.`:scheduleData.eventType===`tc`||scheduleData.eventType===`service_in`||scheduleData.eventType)),{text,type:`notice`}}),streamsList$1=[`rallyLoop`],streamBuffer={rallyLoop:null},rafId=null;function processStreamUpdates(){if(streamBuffer.rallyLoop){let data=streamBuffer.rallyLoop;activeState.value=data.activeState||ActiveState.INACTIVE,data.rallyClock&&Object.assign(rallyClockData,data.rallyClock),data.scheduleData&&Object.assign(scheduleData,data.scheduleData),data.stageData&&Object.assign(stageData,data.stageData),data.countdownData&&Object.assign(countdownData,data.countdownData),data.vehicleProximity&&Object.assign(vehicleProximityData,data.vehicleProximity),data.showDebugInfo!==void 0&&(showDebugInfo.value=data.showDebugInfo),streamBuffer.rallyLoop=null}rafId=requestAnimationFrame(processStreamUpdates)}rafId=requestAnimationFrame(processStreamUpdates),useStreams(streamsList$1,streams=>{streams.rallyLoop&&(streamBuffer.rallyLoop=streams.rallyLoop)}),onMounted(()=>{}),onUnmounted(()=>{rafId&&cancelAnimationFrame(rafId)});function isStageActive(){return activeState.value===ActiveState.STAGE_ACTIVE}return(devEnv.env||devEnv.vue)&&(window.rallyLoopApp={activeState,vehicleProximityData,rallyClockData,scheduleData,stageData,countdownData,proximityStage,distancePrecision,badgeText}),(_ctx,_cache)=>(openBlock(),createBlock(Transition,{name:`fade`},{default:withCtx(()=>[createBaseVNode(`div`,_hoisted_1$154,[isStageActive()?createCommentVNode(``,!0):(openBlock(),createElementBlock(`div`,{key:0,class:normalizeClass([`rally-countdown-app`,{"show-active-stage":isStageActive()}])},[activeState.value===ActiveState.VEHICLE_PROXIMITY?(openBlock(),createElementBlock(`div`,{key:0,class:normalizeClass([`section-vehicle-positioning`,{"has-interact-hint":canInteract.value}])},[createVNode(VehicleProximity_default,{"vehicle-proximity":vehicleProximityData,stage:proximityStage.value,precision:distancePrecision.value,"badge-text":badgeText.value,instruction:proximityInstruction.value,instruction2:proximityInstruction2.value},null,8,[`vehicle-proximity`,`stage`,`precision`,`badge-text`,`instruction`,`instruction2`])],2)):createCommentVNode(``,!0),activeState.value===ActiveState.COUNTDOWN?(openBlock(),createElementBlock(`div`,{key:1,class:normalizeClass([`section-vehicle-positioning`,{"has-interact-hint":canInteract.value}])},[createBaseVNode(`div`,_hoisted_2$127,[createVNode(CountdownWidget_default,{"rally-loop-manager":rallyClockData.wallClockTime?.time||`--:--:--`,period:rallyClockData.wallClockTime?.ampm||``,countdown:countdownData.countdown},null,8,[`rally-loop-manager`,`period`,`countdown`])])],2)):createCommentVNode(``,!0),canInteract.value?(openBlock(),createElementBlock(`div`,_hoisted_3$114,[createVNode(unref(dynamicComponent_default),{template:interactLabel.value,bbcode:``},null,8,[`template`])])):createCommentVNode(``,!0)],2))])]),_:1}))}},appCountdown_default=__plugin_vue_export_helper_default(_sfc_main$172,[[`__scopeId`,`data-v-bde5d1a7`]]),_hoisted_1$153={class:`rally-timecard-app-container`},_hoisted_2$126={key:0,class:`rally-timecard-app`},_hoisted_3$113={class:`interact-label-on-timecard`},_hoisted_4$92={class:`time-card`},_hoisted_5$80={class:`rally-card-header`},_hoisted_6$66={class:`header-top`},_hoisted_7$58=[`src`],_hoisted_8$48={key:0,class:`mission-name`},_hoisted_9$42={class:`rally-card-content`},_hoisted_10$35={key:0,class:`group-divider`},_hoisted_11$31={class:`col-label`},_hoisted_12$25={class:`event-label`},_hoisted_13$22={class:`event-data-container`},_hoisted_14$21={key:0,class:`time-widget`},_hoisted_15$20={class:`col-recorded-time time-widget-value time-taken-value`},_hoisted_16$20={key:0,class:`stage-time`},_hoisted_17$16={key:0,class:`ampm`},_hoisted_18$14={class:`time-widget time-widget-due`},_hoisted_19$11={class:`col-due-time time-widget-value`},_hoisted_20$10={key:0,class:`scheduled-time`},_hoisted_21$10={key:0,class:`ampm`},_hoisted_22$8={class:`time-widget-combined`},_hoisted_23$7={class:`time-widget`},_hoisted_24$6={class:`col-recorded-time time-widget-value actual-value`},_hoisted_25$5={key:0,class:`recorded-time`},_hoisted_26$4={key:0,class:`ampm`},_hoisted_27$4={class:`time-widget`},_hoisted_28$3={class:`col-status time-widget-value status-value`},_hoisted_29$3={key:0,class:`status-text early`},_hoisted_30$3={key:1,class:`status-text late`},_hoisted_31$3={key:2,class:`status-text ok`},_hoisted_32$3={key:0,class:`penalty-card`},_hoisted_33$3={class:`rally-card-header penalty-card-header`},_hoisted_34$3={class:`header-top`},_hoisted_35$2={class:`penalty-total-header`},_hoisted_36$2={class:`total-value`},_hoisted_37$1={class:`penalty-card-content`},_hoisted_38$1={class:`penalty-group-header`},_hoisted_39$1={class:`group-name`},_hoisted_40$1={class:`group-total`},_hoisted_41$1={class:`penalty-list`},_hoisted_42$1={class:`penalty-type`},_hoisted_43$1={class:`penalty-amount`},_hoisted_44$1={key:1,class:`interact-label`},_hoisted_45$1={class:`interact-label-text`},_sfc_main$171={__name:`appTimecard`,setup(__props){useCssVars(_ctx=>({a6aff4e0:themeColor.value}));let{lua}=useBridge(),events$3=useEvents(),penaltyData=ref({totalPenalty:0,groups:[]}),displayMode=ref(1);reactive({env:window.beamng&&!window.beamng.shipping,vue:!1}),events$3.on(`RallyGameplayInteract`,data=>{data&&data.forceShowTimecard?displayMode.value=1:displayMode.value===1?displayMode.value=0:displayMode.value=1});let toggleLabel=computed(()=>displayMode.value===1?`Hide`:`Show`),interactLabel=computed(()=>`[action=gameplay_interact]`),ActiveState={INACTIVE:`inactive`,VEHICLE_PROXIMITY:`vehicleProximity`,STAGE_ACTIVE:`stageActive`,COUNTDOWN:`countdown`},showDebugInfo=ref(!1),missionName=ref(``),activeState=ref(ActiveState.INACTIVE),timecardData=ref([]),rallyClockData=reactive({}),vehicleProximityData=reactive({}),scheduleData=reactive({}),stageData=reactive({}),countdownData=reactive({}),themeColor=computed(()=>`#07ff00`);function shouldShowApp(){return displayMode.value===1}function formatPenaltyType(type){return type?type.replace(/_/g,` `):``}let streamsList$1=[`rallyLoop`],streamBuffer={rallyLoop:null},rafId=null;function processStreamUpdates(){if(streamBuffer.rallyLoop){let data=streamBuffer.rallyLoop;activeState.value=data.activeState||ActiveState.INACTIVE,data.rallyClock&&Object.assign(rallyClockData,data.rallyClock),data.scheduleData&&Object.assign(scheduleData,data.scheduleData),data.timecardData&&(timecardData.value=data.timecardData),data.penaltyData&&(penaltyData.value=data.penaltyData),data.stageData&&Object.assign(stageData,data.stageData),data.countdownData&&Object.assign(countdownData,data.countdownData),data.vehicleProximity&&Object.assign(vehicleProximityData,data.vehicleProximity),data.showDebugInfo!==void 0&&(showDebugInfo.value=data.showDebugInfo),data.missionName!==void 0&&(missionName.value=data.missionName||``),streamBuffer.rallyLoop=null}rafId=requestAnimationFrame(processStreamUpdates)}return rafId=requestAnimationFrame(processStreamUpdates),useStreams(streamsList$1,streams=>{streams.rallyLoop&&(streamBuffer.rallyLoop=streams.rallyLoop)}),onMounted(()=>{}),onUnmounted(()=>{rafId&&cancelAnimationFrame(rafId)}),(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$153,[createVNode(Transition,{name:`slide`},{default:withCtx(()=>[shouldShowApp()?(openBlock(),createElementBlock(`div`,_hoisted_2$126,[createBaseVNode(`div`,null,[createBaseVNode(`div`,_hoisted_3$113,[createVNode(unref(dynamicComponent_default),{template:`[action=gameplay_interact]${toggleLabel.value} Time Card`,bbcode:``},null,8,[`template`])]),createBaseVNode(`div`,_hoisted_4$92,[createBaseVNode(`div`,_hoisted_5$80,[createBaseVNode(`div`,_hoisted_6$66,[_cache[0]||=createBaseVNode(`span`,{class:`rally-card-title`},`TIME CARD`,-1),createBaseVNode(`img`,{class:`header-beamng-logo`,src:unref(getAssetURL)(`images/beamng-logo-mono_189x174.png`)},null,8,_hoisted_7$58)]),missionName.value?(openBlock(),createElementBlock(`div`,_hoisted_8$48,`Event: `+toDisplayString(missionName.value),1)):createCommentVNode(``,!0)]),createBaseVNode(`div`,_hoisted_9$42,[(openBlock(!0),createElementBlock(Fragment,null,renderList(timecardData.value,(entry,idx)=>(openBlock(),createElementBlock(Fragment,{key:idx},[idx>0&&entry.group!==timecardData.value[idx-1].group?(openBlock(),createElementBlock(`div`,_hoisted_10$35)):createCommentVNode(``,!0),createBaseVNode(`div`,{class:normalizeClass([`checklist-row`,{completed:entry.recordedTime||entry.stageTime,"stage-entry":entry.isStageEntry,early:entry.status===`early`,late:entry.status===`late`,"on-time":entry.status===`on-time`,pending:!entry.recordedTime&&!entry.stageTime}])},[createBaseVNode(`div`,_hoisted_11$31,[_cache[1]||=createBaseVNode(`div`,{class:`event-label-top`},`\xA0`,-1),createBaseVNode(`div`,_hoisted_12$25,toDisplayString(entry.label),1)]),createBaseVNode(`div`,_hoisted_13$22,[entry.isStageEntry?(openBlock(),createElementBlock(`div`,_hoisted_14$21,[_cache[2]||=createBaseVNode(`div`,{class:`time-widget-label`},`Time Taken`,-1),createBaseVNode(`div`,_hoisted_15$20,[entry.stageTime?(openBlock(),createElementBlock(`div`,_hoisted_16$20,[createTextVNode(toDisplayString(entry.stageTime),1),entry.stageTime.ampm?(openBlock(),createElementBlock(`span`,_hoisted_17$16,toDisplayString(entry.stageTime.ampm),1)):createCommentVNode(``,!0)])):createCommentVNode(``,!0)])])):(openBlock(),createElementBlock(Fragment,{key:1},[createBaseVNode(`div`,_hoisted_18$14,[_cache[3]||=createBaseVNode(`div`,{class:`time-widget-label`},`Due`,-1),createBaseVNode(`div`,_hoisted_19$11,[entry.scheduledTime?(openBlock(),createElementBlock(`div`,_hoisted_20$10,[createTextVNode(toDisplayString(entry.scheduledTime.time),1),entry.scheduledTime.ampm?(openBlock(),createElementBlock(`span`,_hoisted_21$10,toDisplayString(entry.scheduledTime.ampm),1)):createCommentVNode(``,!0)])):createCommentVNode(``,!0)])]),createBaseVNode(`div`,_hoisted_22$8,[createBaseVNode(`div`,_hoisted_23$7,[_cache[4]||=createBaseVNode(`div`,{class:`time-widget-label`},`Actual`,-1),createBaseVNode(`div`,_hoisted_24$6,[entry.recordedTime?(openBlock(),createElementBlock(`div`,_hoisted_25$5,[createTextVNode(toDisplayString(entry.recordedTime.time),1),entry.recordedTime.ampm?(openBlock(),createElementBlock(`span`,_hoisted_26$4,toDisplayString(entry.recordedTime.ampm),1)):createCommentVNode(``,!0)])):createCommentVNode(``,!0)])]),createBaseVNode(`div`,_hoisted_27$4,[_cache[5]||=createBaseVNode(`div`,{class:`time-widget-label`},`Status`,-1),createBaseVNode(`div`,_hoisted_28$3,[entry.status===`early`?(openBlock(),createElementBlock(`span`,_hoisted_29$3,`EARLY`)):entry.status===`late`?(openBlock(),createElementBlock(`span`,_hoisted_30$3,`LATE`)):entry.recordedTime||entry.status===`on-time`?(openBlock(),createElementBlock(`span`,_hoisted_31$3,`OK`)):createCommentVNode(``,!0)])])])],64))])],2)],64))),128))])]),penaltyData.value&&penaltyData.value.totalPenalty>0?(openBlock(),createElementBlock(`div`,_hoisted_32$3,[createBaseVNode(`div`,_hoisted_33$3,[createBaseVNode(`div`,_hoisted_34$3,[_cache[7]||=createBaseVNode(`span`,{class:`rally-card-title`},`PENALTIES`,-1),createBaseVNode(`div`,_hoisted_35$2,[_cache[6]||=createBaseVNode(`span`,{class:`total-label`},`Total`,-1),createBaseVNode(`span`,_hoisted_36$2,toDisplayString(penaltyData.value.totalPenalty)+`s`,1)])])]),createBaseVNode(`div`,_hoisted_37$1,[(openBlock(!0),createElementBlock(Fragment,null,renderList(penaltyData.value.groups,(group,idx)=>withDirectives((openBlock(),createElementBlock(`div`,{key:idx,class:`penalty-group`},[createBaseVNode(`div`,_hoisted_38$1,[createBaseVNode(`span`,_hoisted_39$1,toDisplayString(group.eventGroup),1),_cache[8]||=createBaseVNode(`span`,{class:`group-mid`},null,-1),createBaseVNode(`span`,_hoisted_40$1,toDisplayString(group.totalPenalty)+`s`,1)]),createBaseVNode(`div`,_hoisted_41$1,[(openBlock(!0),createElementBlock(Fragment,null,renderList(group.penalties,(penalty,pidx)=>(openBlock(),createElementBlock(`div`,{key:pidx,class:`penalty-item`},[createBaseVNode(`span`,_hoisted_42$1,toDisplayString(formatPenaltyType(penalty.type)),1),createBaseVNode(`span`,_hoisted_43$1,toDisplayString(penalty.amount)+`s (x`+toDisplayString(penalty.count)+`)`,1)]))),128))])])),[[vShow,group.totalPenalty>0]])),128))])])):createCommentVNode(``,!0)])])):(openBlock(),createElementBlock(`div`,_hoisted_44$1,[createBaseVNode(`div`,null,[createVNode(unref(dynamicComponent_default),{template:interactLabel.value,bbcode:``},null,8,[`template`]),createBaseVNode(`div`,_hoisted_45$1,[createBaseVNode(`div`,null,toDisplayString(toggleLabel.value),1),_cache[9]||=createBaseVNode(`div`,null,`Time Card`,-1)])])]))]),_:1})]))}},appTimecard_default=__plugin_vue_export_helper_default(_sfc_main$171,[[`__scopeId`,`data-v-216504fd`]]),_hoisted_1$152={class:`rally-dashboard-app-container`},_hoisted_2$125={class:`dashboard-widget widget-rally-clock`},_hoisted_3$112={key:0,class:`period`},_hoisted_4$91={class:`dashboard-widget widget-rally-sstime`},_hoisted_5$79={class:`widget-value`},_hoisted_6$65={class:`dashboard-widget widget-rally-objective`},_hoisted_7$57={class:`widget-value`},_hoisted_8$47={key:2},_sfc_main$170={__name:`appDashboard`,setup(__props){let{lua}=useBridge(),events$3=useEvents(),recoverVehicleTemplate=computed(()=>` Press [action=reset_physics] to recover vehicle.`),ActiveState={INACTIVE:`inactive`,VEHICLE_PROXIMITY:`vehicleProximity`,STAGE_ACTIVE:`stageActive`,COUNTDOWN:`countdown`},rallyClockData=reactive({wallClockTime:null,day:null,totalTime:0,canSkipTimeControls:!1,canSkipCountdown:!1,isNgrcMode:!1}),activeState=ref(ActiveState.INACTIVE),clockFlash=ref(!1);events$3.on(`RallyClockSkipped`,()=>{clockFlash.value=!1,setTimeout(()=>{clockFlash.value=!0},0),setTimeout(()=>{clockFlash.value=!1},1e3)});let scheduleData=reactive({label:null,eventType:null,ssLabel:null,eventWallClockStart:null,eventWallClockEnd:null,timeDiff:null,timeDiffWithEnd:null,lateness:null,penalty:0,hasPenalty:!1,canIncurLatePenalty:!1,speedLimit:null,speedLimitDisplay:null,speedUnit:`km/h`}),formattedWallClock=computed(()=>rallyClockData.wallClockTime?{time:rallyClockData.wallClockTime.time||`--:--:--`,period:rallyClockData.wallClockTime.ampm||``}:{time:`--:--:--`,period:``}),objectiveText=computed(()=>{let obj=scheduleData;return!obj||!obj.eventType?[]:obj.eventType===`service_in`?[`Drive to your `,{type:`badge`,val:`service bay`,class:`tc-badge`},`.`]:obj.eventType===`tc`&&obj.label===`TC0`?[`Reverse out and reach `,{type:`badge`,val:obj.label,class:`tc-badge`},` between `,{type:`clock`,val:obj.eventWallClockStart,class:`clock-badge`},` - `,{type:`clock`,val:obj.eventWallClockEnd,class:`clock-badge`},`. Penalty for each minute early or late: `,{type:`badge`,val:`+10s`,class:`penalty-badge`},`.`]:obj.eventType===`tc`?[`Reach `,{type:`badge`,val:obj.label,class:`tc-badge`},` between `,{type:`clock`,val:obj.eventWallClockStart,class:`clock-badge`},` - `,{type:`clock`,val:obj.eventWallClockEnd,class:`clock-badge`},`. Penalty for each minute early or late: `,{type:`badge`,val:`10sec`,class:`penalty-badge`},`.`]:[]}),streamsList$1=[`rallyLoop`],streamBuffer={rallyLoop:null},rafId=null;function processStreamUpdates(){if(streamBuffer.rallyLoop){let data=streamBuffer.rallyLoop;activeState.value=data.activeState||ActiveState.INACTIVE,data.rallyClock&&Object.assign(rallyClockData,data.rallyClock),data.scheduleData&&Object.assign(scheduleData,data.scheduleData),streamBuffer.rallyLoop=null}rafId=requestAnimationFrame(processStreamUpdates)}rafId=requestAnimationFrame(processStreamUpdates),useStreams(streamsList$1,streams=>{streams.rallyLoop&&(streamBuffer.rallyLoop=streams.rallyLoop)}),onMounted(()=>{}),onUnmounted(()=>{rafId&&cancelAnimationFrame(rafId)});function isStageActive(){return activeState.value===ActiveState.STAGE_ACTIVE}return(_ctx,_cache)=>(openBlock(),createBlock(Transition,{name:`fade`},{default:withCtx(()=>[createBaseVNode(`div`,_hoisted_1$152,[isStageActive()?createCommentVNode(``,!0):(openBlock(),createElementBlock(`div`,{key:0,class:normalizeClass([`rally-dashboard-app`,{"show-active-stage":isStageActive()}])},[createBaseVNode(`div`,_hoisted_2$125,[_cache[0]||=createBaseVNode(`div`,{class:`widget-label`},`Event Clock`,-1),createBaseVNode(`div`,{class:normalizeClass([`widget-value clock-value`,{"flash-pink":clockFlash.value}])},[createTextVNode(toDisplayString(formattedWallClock.value.time),1),formattedWallClock.value.period?(openBlock(),createElementBlock(`span`,_hoisted_3$112,toDisplayString(formattedWallClock.value.period),1)):createCommentVNode(``,!0)],2)]),createBaseVNode(`div`,_hoisted_4$91,[_cache[1]||=createBaseVNode(`div`,{class:`widget-label`},`Your Time`,-1),createBaseVNode(`div`,_hoisted_5$79,toDisplayString(rallyClockData.totalTime),1)]),createBaseVNode(`div`,_hoisted_6$65,[_cache[2]||=createBaseVNode(`div`,{class:`widget-label`},`Instructions`,-1),createBaseVNode(`div`,_hoisted_7$57,[(openBlock(!0),createElementBlock(Fragment,null,renderList(objectiveText.value,item=>(openBlock(),createElementBlock(`span`,{key:item},[item.type===`badge`?(openBlock(),createElementBlock(`span`,{key:0,class:normalizeClass(item.class)},toDisplayString(item.val),3)):item.type===`clock`?(openBlock(),createElementBlock(`span`,{key:1,class:normalizeClass(item.class)},toDisplayString(item.val.time)+toDisplayString(item.val.period),3)):(openBlock(),createElementBlock(`span`,_hoisted_8$47,toDisplayString(item),1))]))),128)),createVNode(unref(dynamicComponent_default),{template:recoverVehicleTemplate.value,bbcode:``},null,8,[`template`])])])],2))])]),_:1}))}},appDashboard_default=__plugin_vue_export_helper_default(_sfc_main$170,[[`__scopeId`,`data-v-a3bb6c18`]]),_hoisted_1$151={class:`rally-debug-app-container`},_hoisted_2$124={key:0,class:`debug-info`},_sfc_main$169={__name:`appDebug`,setup(__props){let{lua}=useBridge(),ActiveState={INACTIVE:`inactive`,VEHICLE_PROXIMITY:`vehicleProximity`,STAGE_ACTIVE:`stageActive`,COUNTDOWN:`countdown`},showDebugInfo=ref(!0),activeState=ref(ActiveState.INACTIVE),timecardData=ref([]),penaltyData=ref({totalPenalty:0,groups:[]}),rallyClockData=reactive({}),vehicleProximityData=reactive({}),scheduleData=reactive({}),stageData=reactive({}),countdownData=reactive({}),streamsList$1=[`rallyLoop`],streamBuffer={rallyLoop:null},rafId=null;function processStreamUpdates(){if(streamBuffer.rallyLoop){let data=streamBuffer.rallyLoop;activeState.value=data.activeState||ActiveState.INACTIVE,data.rallyClock&&Object.assign(rallyClockData,data.rallyClock),data.scheduleData&&Object.assign(scheduleData,data.scheduleData),data.timecardData&&(timecardData.value=data.timecardData),data.penaltyData&&(penaltyData.value=data.penaltyData),data.stageData&&Object.assign(stageData,data.stageData),data.countdownData&&Object.assign(countdownData,data.countdownData),data.vehicleProximity&&Object.assign(vehicleProximityData,data.vehicleProximity),streamBuffer.rallyLoop=null}rafId=requestAnimationFrame(processStreamUpdates)}return rafId=requestAnimationFrame(processStreamUpdates),useStreams(streamsList$1,streams=>{streams.rallyLoop&&(streamBuffer.rallyLoop=streams.rallyLoop)}),onMounted(()=>{}),onUnmounted(()=>{rafId&&cancelAnimationFrame(rafId)}),(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$151,[showDebugInfo.value?(openBlock(),createElementBlock(`div`,_hoisted_2$124,[createBaseVNode(`div`,null,`activeState: "`+toDisplayString(activeState.value)+`"`,1),createBaseVNode(`div`,null,`rallyClock: `+toDisplayString(rallyClockData),1),createBaseVNode(`div`,null,`countdownData: `+toDisplayString(countdownData),1),createBaseVNode(`div`,null,`vehicleProximityData: `+toDisplayString(vehicleProximityData),1),createBaseVNode(`div`,null,`scheduleData: `+toDisplayString(scheduleData),1),createBaseVNode(`div`,null,`timecardData: `+toDisplayString(timecardData.value),1),createBaseVNode(`div`,null,`penaltyData: `+toDisplayString(penaltyData.value),1),createBaseVNode(`div`,null,`stageData: `+toDisplayString(stageData),1)])):createCommentVNode(``,!0)]))}},appDebug_default=__plugin_vue_export_helper_default(_sfc_main$169,[[`__scopeId`,`data-v-c2c6bfeb`]]),_hoisted_1$150={class:`distance-widget-svg`},_hoisted_2$123=[`x`,`y`,`height`],_hoisted_3$111=[`x`,`y`,`width`,`height`],_hoisted_4$90=[`x`,`y`,`width`,`height`],_hoisted_5$78=[`x`,`y`,`width`,`height`],_hoisted_6$64={x:0,y:`90%`,"text-anchor":`middle`},_hoisted_7$56={class:`tick-label`},_hoisted_8$46={class:`tick-label-unit`,dx:`2`},_hoisted_9$41=[`x`,`y`,`width`,`height`],_hoisted_10$34={x:0,y:`90%`,dx:`20`,"text-anchor":`end`},_hoisted_11$30={key:0,class:`tick-label-bold`},_hoisted_12$24={class:`tick-label-unit`,dx:`2`},_hoisted_13$21=[`x`,`y`,`width`,`height`],PAD_PX=20,PADRIGHT_PX=26,barHeightPct=8,barCenterY=50,tickStrokeWidth=2,tickSize=12,trackingRectSize=14,_sfc_main$168={__name:`DistanceWidgetSVGRect`,props:{distPct:{type:Number,required:!0},totalDistM:{type:Number,required:!0},splits:{type:Array,default:()=>[]},splitPrecision:{type:Number,default:1},themeColor:{type:String,required:!0},unit:{type:String,default:`km`}},setup(__props){useCssVars(_ctx=>({v94238812:__props.themeColor}));let props=__props,barStartX=PAD_PX,barY=barCenterY-barHeightPct/2;100-PADRIGHT_PX,computed(()=>PAD_PX+(100-PAD_PX-PADRIGHT_PX)*props.distPct);let currentX=computed(()=>`calc(${PAD_PX}px + (100% - ${PAD_PX+PADRIGHT_PX}px) * ${props.distPct})`),barWidth=`calc(100% - ${PAD_PX+PADRIGHT_PX}px)`,progressWidth=computed(()=>`calc((100% - ${PAD_PX+PADRIGHT_PX}px) * ${props.distPct})`),barEndX=`calc(100% - ${PADRIGHT_PX}px)`,splitMarkers=computed(()=>props.splits?props.splits.filter(s=>typeof s?.pathnodeType==`string`&&s.pathnodeType.startsWith(`split_`)).map((s,idx)=>{let pct=s.distPct||0,x=`calc(${PAD_PX}px + (100% - ${PAD_PX+PADRIGHT_PX}px) * ${pct})`;return{key:s.pathnodeId??idx,x,label:{val:s.splitLabel,unit:props.unit}}}):[]),finalSplitLabel=computed(()=>!props.splits||props.splits.length===0?{val:null,unit:null}:{val:props.splits[props.splits.length-1]?.splitLabel,unit:props.unit});return(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$150,[(openBlock(),createElementBlock(`svg`,null,[createBaseVNode(`rect`,{x:unref(barStartX)+`px`,y:barY+`%`,width:barWidth,height:barHeightPct+`%`,fill:`white`},null,8,_hoisted_2$123),createBaseVNode(`rect`,{x:unref(barStartX)+`px`,y:barY-1+`%`,width:progressWidth.value,height:barHeightPct+2+`%`,fill:`var(--theme-color)`},null,8,_hoisted_3$111),createBaseVNode(`rect`,{x:unref(barStartX)-tickSize/2+`px`,y:`calc(`+barCenterY+`% - `+tickSize/2+`px)`,width:tickSize+`px`,height:tickSize+`px`,fill:`var(--theme-color)`},null,8,_hoisted_4$90),(openBlock(!0),createElementBlock(Fragment,null,renderList(splitMarkers.value,split=>(openBlock(),createElementBlock(`g`,{key:split.key,style:normalizeStyle(`transform: translateX(${split.x})`)},[createBaseVNode(`rect`,{x:-(tickSize/2)+`px`,y:`calc(`+barCenterY+`% - `+tickSize/2+`px)`,width:tickSize+`px`,height:tickSize+`px`,"stroke-width":tickStrokeWidth,fill:`#202020`,stroke:`#ffffff`},null,8,_hoisted_5$78),createBaseVNode(`text`,_hoisted_6$64,[createBaseVNode(`tspan`,_hoisted_7$56,toDisplayString(split.label.val),1),createBaseVNode(`tspan`,_hoisted_8$46,toDisplayString(split.label.unit),1)])],4))),128)),createBaseVNode(`g`,{style:normalizeStyle(`transform: translateX(${barEndX})`)},[createBaseVNode(`rect`,{x:-(tickSize/2)+`px`,y:`calc(`+barCenterY+`% - `+tickSize/2+`px)`,width:tickSize+`px`,height:tickSize+`px`,"stroke-width":tickStrokeWidth,fill:`#202020`,stroke:`#ffffff`},null,8,_hoisted_9$41),createBaseVNode(`text`,_hoisted_10$34,[finalSplitLabel.value?(openBlock(),createElementBlock(`tspan`,_hoisted_11$30,toDisplayString(finalSplitLabel.value.val),1)):createCommentVNode(``,!0),createBaseVNode(`tspan`,_hoisted_12$24,toDisplayString(finalSplitLabel.value.unit),1)])],4),createBaseVNode(`g`,{style:normalizeStyle(`transform: translateX(${currentX.value})`)},[createBaseVNode(`rect`,{x:-(trackingRectSize/2)+`px`,y:`calc(`+barCenterY+`% - `+trackingRectSize/2+`px)`,width:trackingRectSize+`px`,height:trackingRectSize+`px`,fill:`var(--theme-color)`},null,8,_hoisted_13$21)],4)]))]))}},DistanceWidgetSVGRect_default=__plugin_vue_export_helper_default(_sfc_main$168,[[`__scopeId`,`data-v-9c6ef477`]]);function rallyStageThemeColor(withAlpha=null){return`#009a1a${withAlpha===!0?`a0`:``}`}var _hoisted_1$149={key:0,class:`rally-stage-timing-app`},_sfc_main$167={__name:`appStageProgress`,setup(__props){useCssVars(_ctx=>({v708a5eb2:themeColor.value}));let{lua}=useBridge();reactive({env:window.beamng&&!window.beamng.shipping,vue:!1});let ActiveState={INACTIVE:`inactive`,VEHICLE_PROXIMITY:`vehicleProximity`,STAGE_ACTIVE:`stageActive`,COUNTDOWN:`countdown`},rallyClockData=reactive({wallClockSecs:null,epochTime:null,day:null,totalPenalty:0,totalTime:0,use24hFormat:!0,canSkipTimeControls:!1,canSkipCountdown:!1,isNgrcMode:!1}),activeState=ref(ActiveState.INACTIVE),vehicleProximityData=reactive({isNear:!1,distance:0,distanceToPlane:0,isStopped:!1,isFrozen:!1,usingGroundMarkerDistance:!1}),scheduleData=reactive({label:null,eventType:null,ssLabel:null,eventWallClockStart:null,eventWallClockEnd:null,timeDiff:null,timeDiffWithEnd:null,lateness:null,penalty:0,hasPenalty:!1,canIncurLatePenalty:!1}),stageData=reactive({currentSSTime:null,isActive:!1,isComplete:!1,splits:[],label:null,completion:{distPct:0},unit:`km`}),themeColor=computed(()=>rallyStageThemeColor()),streamsList$1=[`rallyLoop`],streamBuffer={rallyLoop:null},rafId=null;function processStreamUpdates(){if(streamBuffer.rallyLoop){let data=streamBuffer.rallyLoop;activeState.value=data.activeState||ActiveState.INACTIVE,data.rallyClock&&Object.assign(rallyClockData,data.rallyClock),data.scheduleData&&Object.assign(scheduleData,data.scheduleData),data.stageData&&Object.assign(stageData,data.stageData),data.vehicleProximity&&Object.assign(vehicleProximityData,data.vehicleProximity),streamBuffer.rallyLoop=null}rafId=requestAnimationFrame(processStreamUpdates)}rafId=requestAnimationFrame(processStreamUpdates),useStreams(streamsList$1,streams=>{streams.rallyLoop&&(streamBuffer.rallyLoop=streams.rallyLoop)}),onMounted(()=>{}),onUnmounted(()=>{rafId&&cancelAnimationFrame(rafId)});function shouldShowApp(){return!0}return(_ctx,_cache)=>(openBlock(),createBlock(Transition,{name:`fade`},{default:withCtx(()=>[shouldShowApp()?(openBlock(),createElementBlock(`div`,_hoisted_1$149,[createVNode(DistanceWidgetSVGRect_default,{"dist-pct":stageData.completion.distPct,"total-dist-m":stageData.completion.totalDistM,splits:stageData.splits,"theme-color":themeColor.value,unit:stageData.unit},null,8,[`dist-pct`,`total-dist-m`,`splits`,`theme-color`,`unit`])])):createCommentVNode(``,!0)]),_:1}))}},appStageProgress_default=__plugin_vue_export_helper_default(_sfc_main$167,[[`__scopeId`,`data-v-a8eba296`]]);function formatSSTime(seconds,activeState){if(activeState===`inactive`)return`--:--:--`;let roundedSeconds=Math.round(seconds*10)/10,hours=Math.floor(roundedSeconds/3600),minutes=Math.floor(roundedSeconds%3600/60),secs=Math.floor(roundedSeconds%60),tenths=Math.round(roundedSeconds%1*10)%10;return hours>0?`${hours}:${String(minutes).padStart(2,`0`)}:${String(secs).padStart(2,`0`)}.${tenths}`:minutes>0?`${minutes}:${String(secs).padStart(2,`0`)}.${tenths}`:`${secs}.${tenths}`}var _hoisted_1$148={key:0,class:`rally-stage-timing-app`},_hoisted_2$122={class:`section-active-stage`},_hoisted_3$110={class:`stage-header`},_hoisted_4$89={class:`stage-time`},_hoisted_5$77={key:0,class:`splits-header`},_hoisted_6$63={key:1,class:`stage-splits`},_hoisted_7$55={class:`stage-split-label`},_hoisted_8$45={class:`stage-split-label-unit`},_hoisted_9$40={class:`stage-split-time`},_hoisted_10$33=[`src`],_sfc_main$166={__name:`appStageTiming`,setup(__props){let{lua}=useBridge(),ActiveState={INACTIVE:`inactive`,VEHICLE_PROXIMITY:`vehicleProximity`,STAGE_ACTIVE:`stageActive`,COUNTDOWN:`countdown`},rallyClockData=reactive({wallClockSecs:null,epochTime:null,day:null,totalPenalty:0,totalTime:0,use24hFormat:!0,canSkipTimeControls:!1,canSkipCountdown:!1,isNgrcMode:!1}),activeState=ref(ActiveState.INACTIVE),vehicleProximityData=reactive({isNear:!1,distance:0,distanceToPlane:0,isStopped:!1,isFrozen:!1,usingGroundMarkerDistance:!1}),scheduleData=reactive({label:null,eventType:null,ssLabel:null,eventWallClockStart:null,eventWallClockEnd:null,timeDiff:null,timeDiffWithEnd:null,lateness:null,penalty:0,hasPenalty:!1,canIncurLatePenalty:!1}),stageData=reactive({currentSSTime:null,isActive:!1,isComplete:!1,splits:[],label:null,completion:{distM:0,distPct:0}});computed(()=>rallyStageThemeColor(!0));let completedSplits=computed(()=>stageData.splits?.filter(split=>split.time!=null)||[]),splitUnit=computed(()=>`km`),streamsList$1=[`rallyLoop`],streamBuffer={rallyLoop:null},rafId=null;function processStreamUpdates(){if(streamBuffer.rallyLoop){let data=streamBuffer.rallyLoop;activeState.value=data.activeState||ActiveState.INACTIVE,data.rallyClock&&Object.assign(rallyClockData,data.rallyClock),data.scheduleData&&Object.assign(scheduleData,data.scheduleData),data.stageData&&Object.assign(stageData,data.stageData),data.vehicleProximity&&Object.assign(vehicleProximityData,data.vehicleProximity),streamBuffer.rallyLoop=null}rafId=requestAnimationFrame(processStreamUpdates)}rafId=requestAnimationFrame(processStreamUpdates),useStreams(streamsList$1,streams=>{streams.rallyLoop&&(streamBuffer.rallyLoop=streams.rallyLoop)}),onMounted(()=>{}),onUnmounted(()=>{rafId&&cancelAnimationFrame(rafId)});function shouldShowApp(){return!0}return(_ctx,_cache)=>(openBlock(),createBlock(Transition,{name:`fade`},{default:withCtx(()=>[shouldShowApp()?(openBlock(),createElementBlock(`div`,_hoisted_1$148,[createBaseVNode(`div`,_hoisted_2$122,[createBaseVNode(`div`,_hoisted_3$110,`STAGE `+toDisplayString(stageData.label)+` / `+toDisplayString(scheduleData.totalSSCount),1),createBaseVNode(`div`,_hoisted_4$89,toDisplayString(unref(formatSSTime)(stageData.currentSSTime,activeState.value)),1),completedSplits.value.length>0?(openBlock(),createElementBlock(`div`,_hoisted_5$77,`SPLITS`)):createCommentVNode(``,!0),completedSplits.value.length>0?(openBlock(),createElementBlock(`div`,_hoisted_6$63,[(openBlock(!0),createElementBlock(Fragment,null,renderList(completedSplits.value,split=>(openBlock(),createElementBlock(`div`,{class:`stage-split`,key:split.pathnodeId},[createBaseVNode(`div`,_hoisted_7$55,[createBaseVNode(`span`,null,toDisplayString(split.splitLabel),1),createBaseVNode(`span`,_hoisted_8$45,toDisplayString(splitUnit.value),1)]),createBaseVNode(`div`,_hoisted_9$40,toDisplayString(unref(formatSSTime)(split.time,activeState.value)),1)]))),128))])):createCommentVNode(``,!0),rallyClockData.isNgrcMode?(openBlock(),createElementBlock(`img`,{key:2,class:`stage-ngrc-badge`,src:unref(getAssetURL)(`images/ngrc_logo_dark_128x40.png`),alt:`NGRC`},null,8,_hoisted_10$33)):createCommentVNode(``,!0)])])):createCommentVNode(``,!0)]),_:1}))}},appStageTiming_default=__plugin_vue_export_helper_default(_sfc_main$166,[[`__scopeId`,`data-v-cea09957`]]),_hoisted_1$147={class:`gameplay-apps`},gameplayAppsFlashMessage=`GameplayAppsFlashMessage`,_sfc_main$165={__name:`gameplayApps`,setup(__props){let{lua}=useBridge(),events$3=useEvents(),isDrift=ref(!1),isDragStaging=ref(!1),isRally=ref(!1),isPointsBar=ref(!1),isFlashMessage=ref(!1),isCountdown=ref(!1),appStates={drift:isDrift,drag:isDragStaging,rally:isRally,pointsBar:isPointsBar,flashMessage:isFlashMessage,countdown:isCountdown},setAppVisibility=data=>{data.appId&&appStates[data.appId]&&(appStates[data.appId].value=data.visible),data.hideAll&&Object.values(appStates).forEach(state=>state.value=!1)},loadInitialVisibility=async()=>{try{let visibleApps=await lua.ui_gameplayAppContainers.getVisibleApps(`gameplayApps`);Object.values(appStates).forEach(state=>state.value=!1),Array.isArray(visibleApps)&&visibleApps.forEach(appId=>{appStates[appId]&&(appStates[appId].value=!0)})}catch{}};return onMounted(()=>{events$3.on(`setGameplayAppVisibility`,setAppVisibility),lua.ui_gameplayAppContainers.onGameplayAppContainerMounted(),loadInitialVisibility()}),onUnmounted(()=>{events$3.off(`setGameplayAppVisibility`,setAppVisibility),lua.ui_gameplayAppContainers.onGameplayAppContainerUnmounted()}),(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$147,[withDirectives((openBlock(),createBlock(resolveDynamicComponent(unref(app_default)),mergeProps({class:`app`},_ctx.$attrs),null,16)),[[vShow,isPointsBar.value]]),withDirectives((openBlock(),createBlock(resolveDynamicComponent(unref(app_default$28)),mergeProps({class:`app rally`},_ctx.$attrs),null,16)),[[vShow,isRally.value]]),withDirectives((openBlock(),createBlock(resolveDynamicComponent(unref(app_default$13)),mergeProps({class:`app`,showFlash:!1},_ctx.$attrs),null,16)),[[vShow,isDrift.value]]),withDirectives((openBlock(),createBlock(resolveDynamicComponent(unref(app_default$11)),mergeProps({class:`app`,showFlash:!1},_ctx.$attrs),null,16)),[[vShow,isDragStaging.value]]),withDirectives((openBlock(),createBlock(resolveDynamicComponent(unref(flashMessageApp_default)),mergeProps({class:`app flash-message`,"message-source":gameplayAppsFlashMessage},_ctx.$attrs),null,16)),[[vShow,isFlashMessage.value]]),withDirectives((openBlock(),createBlock(resolveDynamicComponent(unref(countdownApp_default)),mergeProps({class:`countdown`},_ctx.$attrs),null,16)),[[vShow,isCountdown.value]])]))}},gameplayApps_default=__plugin_vue_export_helper_default(_sfc_main$165,[[`__scopeId`,`data-v-8ac28a96`]]),_hoisted_1$146={class:`messages-tasks-apps`},_sfc_main$164={__name:`messagesTasksApps`,setup(__props){let{lua}=useBridge(),events$3=useEvents(),isMessages=ref(!1),isTasks=ref(!1),appStates={messages:isMessages,tasks:isTasks},setAppVisibility=data=>{data.appId&&appStates[data.appId]&&(appStates[data.appId].value=data.visible),data.hideAll&&Object.values(appStates).forEach(state=>{state.value=!1})},loadInitialVisibility=async()=>{try{let visibleApps=await lua.ui_messagesTasksAppContainers.getVisibleApps(`messagesTasksApps`);Object.values(appStates).forEach(state=>{state.value=!1}),Array.isArray(visibleApps)&&visibleApps.forEach(appId=>{appStates[appId]&&(appStates[appId].value=!0)})}catch{}};return onMounted(()=>{events$3.on(`setMessagesTasksAppVisibility`,setAppVisibility),lua.ui_messagesTasksAppContainers.onMessagesTasksAppContainerMounted(),loadInitialVisibility()}),onUnmounted(()=>{events$3.off(`setMessagesTasksAppVisibility`,setAppVisibility),lua.ui_messagesTasksAppContainers.onMessagesTasksAppContainerUnmounted()}),(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$146,[withDirectives((openBlock(),createBlock(resolveDynamicComponent(unref(app_default$27)),mergeProps({class:`app`},_ctx.$attrs),null,16)),[[vShow,isTasks.value]]),withDirectives((openBlock(),createBlock(resolveDynamicComponent(unref(app_default$32)),mergeProps({class:`app`},_ctx.$attrs),null,16)),[[vShow,isMessages.value]])]))}},messagesTasksApps_default=__plugin_vue_export_helper_default(_sfc_main$164,[[`__scopeId`,`data-v-0ac32403`]]),_sfc_main$163={__name:`countdownApp`,setup(__props){let events$3=useEvents();function convertLegacyMessage(data){return Array.isArray(data)?data.map(item=>({msg:typeof item[0]==`object`?item[0].txt:item[0],ttl:item[1],luaCall:typeof item[2]==`string`?item[2]:void 0,jsCallback:typeof item[2]==`function`?item[2]:void 0,big:item[3]??!1})):data}return onMounted(()=>{events$3.on(`ScenarioFlashMessage`,data=>{let convertedData=convertLegacyMessage(data);if(Array.isArray(convertedData)&&convertedData.length>0){let lastMessage=convertedData[convertedData.length-1];lastMessage.msg===`GO!`&&(lastMessage.jsCallback=()=>{events$3.emit(`CountdownEnded`)})}events$3.emit(`CountdownMessage`,convertedData)}),events$3.on(`ScenarioNotRunning`,()=>{events$3.emit(`CountdownMessage`,{msg:``,ttl:0})})}),(_ctx,_cache)=>(openBlock(),createBlock(bngFlashMessage_default,{"message-source":`CountdownMessage`}))}},countdownApp_default=__plugin_vue_export_helper_default(_sfc_main$163,[[`__scopeId`,`data-v-8ddc025c`]]),_sfc_main$162={__name:`flashMessageApp`,setup(__props){let events$3=useEvents();return onMounted(()=>{events$3.on(`ScenarioFlashMessage`,data=>{let convertedData=Array.isArray(data)?data.map(item=>({msg:typeof item[0]==`object`?item[0].txt:item[0],ttl:item[1],luaCall:typeof item[2]==`string`?item[2]:void 0,jsCallback:typeof item[2]==`function`?item[2]:void 0,big:item[3]??!1})):data;events$3.emit(`SimpleFlashMessage`,convertedData)}),events$3.on(`ScenarioNotRunning`,()=>{events$3.emit(`SimpleFlashMessage`,{msg:``,ttl:0})})}),(_ctx,_cache)=>(openBlock(),createBlock(bngFlashMessage_default,{"message-source":`SimpleFlashMessage`}))}},flashMessageApp_default=__plugin_vue_export_helper_default(_sfc_main$162,[[`__scopeId`,`data-v-48db34d3`]]),_hoisted_1$145={class:`generic-mission-data`},_sfc_main$161={__name:`bngGenericMissionData`,setup(__props){let events$3=useEvents(),{lua}=useBridge(),displayElements=ref([]),getElementValue=element=>element.minutes||element.seconds?``:typeof element.txt==`number`?element.txt:element.style===`text`||element.style===void 0?$translate.instant(element.txt):`Error: Unsupported style`,handleMissionDataChanged=data=>{if(data){for(;displayElements.value.length<=data.index;)displayElements.value.push(null);displayElements.value[data.index]=data.element}},handleMissionDataReset=()=>{displayElements.value=[]};return onMounted(()=>{events$3.on(`SetGenericMissionData`,handleMissionDataChanged),events$3.on(`SetGenericMissionDataResetAll`,handleMissionDataReset),lua.extensions.load(`ui_apps_genericMissionData`),lua.ui_apps_genericMissionData.sendAllData()}),(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$145,[(openBlock(!0),createElementBlock(Fragment,null,renderList(displayElements.value,(element,index)=>(openBlock(),createElementBlock(Fragment,{key:index},[element?(openBlock(),createBlock(bngSimpleDataDisplay_default,{key:0,label:_ctx.$tt(element.title),value:getElementValue(element),icon:element.icon,minutes:element.minutes,seconds:element.seconds,milliseconds:element.milliseconds,class:`mission-data-item`},null,8,[`label`,`value`,`icon`,`minutes`,`seconds`,`milliseconds`])):createCommentVNode(``,!0)],64))),128))]))}},bngGenericMissionData_default=__plugin_vue_export_helper_default(_sfc_main$161,[[`__scopeId`,`data-v-1cdb0dd5`]]),_hoisted_1$144={class:`controls-container`},_sfc_main$160={__name:`app`,setup(__props){let{$game}=useLibStore();return ref(!0),(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$144,[createVNode(unref(bngAppBindingDisplay_default))]))}},app_default$29=__plugin_vue_export_helper_default(_sfc_main$160,[[`__scopeId`,`data-v-66fafb5f`]]),_hoisted_1$143={class:`main-container-grid`},_hoisted_2$121={class:`points-display`},_hoisted_3$109={class:`star-wrapper`},_sfc_main$159={__name:`app`,setup(__props){let{lua}=useBridge(),fillPercent=ref(0),pointsLabel=ref(`0`),thresholdPercentages=ref([]),thresholdsReached=ref([]),thresholdCount=ref(0),thresholdIndices=computed(()=>Array.from({length:thresholdCount.value},(_,index)=>index));onMounted(()=>{lua.extensions.load(`ui_apps_pointsBar`),lua.ui_apps_pointsBar.requestAllData()}),onUnmounted(()=>{});let streamsList$1=[`pointsBar`];return useStreams(streamsList$1,streams=>{for(let stream of streamsList$1)if(!streams[stream])return;fillPercent.value=streams.pointsBar.fillPercent,pointsLabel.value=streams.pointsBar.pointsLabel,streams.pointsBar.thresholdPercentages&&Array.isArray(streams.pointsBar.thresholdPercentages)&&(thresholdPercentages.value=streams.pointsBar.thresholdPercentages),streams.pointsBar.thresholdsReached&&Array.isArray(streams.pointsBar.thresholdsReached)&&(thresholdsReached.value=streams.pointsBar.thresholdsReached),thresholdCount.value=streams.pointsBar.thresholdCount}),(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$143,[createBaseVNode(`div`,{class:`progress-bar-container`,style:normalizeStyle({"--threshold-percentage":thresholdPercentages.value[0]||0})},[createBaseVNode(`div`,_hoisted_2$121,toDisplayString(_ctx.$t(pointsLabel.value)),1),createBaseVNode(`div`,{class:`progress-bar`,style:normalizeStyle({width:`${fillPercent.value*100}%`})},null,4),(openBlock(!0),createElementBlock(Fragment,null,renderList(thresholdIndices.value,i=>(openBlock(),createElementBlock(`div`,{key:i,class:normalizeClass([`limit-marker`,{passed:thresholdsReached.value[i]}]),style:normalizeStyle({left:`${thresholdPercentages.value[i]}%`})},[createBaseVNode(`div`,_hoisted_3$109,[createVNode(unref(bngIcon_default),{type:thresholdsReached.value[i]?unref(icons).star:unref(icons).starSecondary,class:normalizeClass([`star-icon`,{passed:thresholdsReached.value[i]}])},null,8,[`type`,`class`])])],6))),128))],4)]))}},app_default=__plugin_vue_export_helper_default(_sfc_main$159,[[`__scopeId`,`data-v-4e2c4ac3`]]),_hoisted_1$142={key:0,class:`minimap-container-additional-info top`},_hoisted_2$120={key:0},_hoisted_3$108={key:1,class:`minimap-container-additional-info bottom`},_hoisted_4$88={key:2},_hoisted_5$76={key:0,class:`minimap-container-additional-info top round`},_hoisted_6$62={key:0},_hoisted_7$54={key:1,class:`minimap-container-additional-info bottom round`},_hoisted_8$44={key:2},transformUpdateAttempts=15,_sfc_main$158={__name:`app`,setup(__props){useCssVars(_ctx=>({v01db66c6:squareSize.value,v32146572:minimapSize.value}));let{lua}=useBridge(),events$3=useEvents(),route=useRoute(),$globalStore=inject(`$globalStore`),uiVisible=ref(!0),initialising=ref(!1),initialised=ref(!1),minimapMode=ref(`circle`),minimapContainerRef=ref(null),containerRef=ref(null);ref(null),ref(null);let resizeObserver=ref(null),mapMetrics=reactive({x:0,y:0,width:0,height:0,xRel:0,yRel:0,widthRel:0,heightRel:0}),allowedRoutes=[`/play`,``],showMinimap=computed(()=>uiVisible.value&&!loadingScreen.shown&&$globalStore.__uiAppsShown&&!$globalStore.__introPopupShown&&!popupsView.popups&&!popupsView.activities&&allowedRoutes.includes(route.path)),additionalInfo=reactive({distToTarget:null,locationName:null,policeMode:`disabled`}),hasTopInfo=computed(()=>!!additionalInfo.locationName),hasBottomInfo=computed(()=>!!(additionalInfo.distToTarget||additionalInfo.policeMode===`visibleToPolice`||additionalInfo.policeMode===`hiddenFromPolice`));watch(hasTopInfo,val=>{showMinimap.value&&requestAnimationFrame(updateDrawTransform)}),watch(hasBottomInfo,val=>{showMinimap.value&&requestAnimationFrame(updateDrawTransform)});let transformUpdateAttempt=0,minimapSize=ref(`100%`),minimapShift=ref(`0px`),squareSize=ref(`100%`);async function updateDrawTransform(){if(minimapMode.value===`circle`&&minimapContainerRef.value){let rect$1=minimapContainerRef.value.getBoundingClientRect(),size$3=Math.min(rect$1.width,rect$1.height),sizepx=size$3+`px`;minimapSize.value!==sizepx&&(minimapSize.value=sizepx,rect$1.width>rect$1.height?minimapShift.value=-(rect$1.width-size$3)/2+`px`:minimapShift.value=`0px`,await nextTick())}if(!initialised.value||!showMinimap.value||!containerRef.value)return;let screen$1={width:window.innerWidth,height:window.innerHeight,scrollX:window.scrollX,scrollY:window.scrollY},rect=containerRef.value.getBoundingClientRect();mapMetrics.x=rect.left+screen$1.scrollX,mapMetrics.y=rect.top+screen$1.scrollY,mapMetrics.width=rect.width,mapMetrics.height=rect.height,mapMetrics.xRel=mapMetrics.x/screen$1.width,mapMetrics.yRel=mapMetrics.y/screen$1.height,mapMetrics.widthRel=mapMetrics.width/screen$1.width,mapMetrics.heightRel=mapMetrics.height/screen$1.height;let keys=[`xRel`,`yRel`,`widthRel`,`heightRel`];if(keys.some(key=>mapMetrics[key]<0||mapMetrics[key]>1)||keys.every(key=>mapMetrics[key]===0)){transformUpdateAttempt++,transformUpdateAttempt{val?updateDrawTransform():initialised.value&&sendTransformToLua(!1)}),watch([initialised,containerRef],()=>{updateDrawTransform(),containerRef.value&&!resizeObserver.value&&(resizeObserver.value=new ResizeObserver(()=>{updateDrawTransform()}),resizeObserver.value.observe(containerRef.value))},{immediate:!0}),onMounted(()=>{window.addEventListener(`scroll`,updateDrawTransform),window.addEventListener(`resize`,updateDrawTransform),events$3.on(`onCefVisibilityChanged`,visible=>{uiVisible.value=visible,nextTick(updateDrawTransform)}),initMinimap()}),onUnmounted(()=>{let wasInitialised=initialised.value;initialised.value=!1,window.removeEventListener(`scroll`,updateDrawTransform),window.removeEventListener(`resize`,updateDrawTransform),resizeObserver.value&&=(resizeObserver.value.disconnect(),null),wasInitialised&&sendTransformToLua(!1)}),useStreams([`minimap`],streams=>{streams.minimap&&(additionalInfo.distToTarget=streams.minimap.distToTarget,additionalInfo.locationName=streams.minimap.locationName,additionalInfo.policeMode=streams.minimap.policeMode)}),(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,{ref_key:`minimapContainerRef`,ref:minimapContainerRef,class:normalizeClass([`minimap-container-wrapper`,{[`police-`+additionalInfo.policeMode]:minimapMode.value===`rect`,round:minimapMode.value===`circle`}]),onClick:updateDrawTransform},[minimapMode.value===`rect`?(openBlock(),createElementBlock(Fragment,{key:0},[hasTopInfo.value?(openBlock(),createElementBlock(`div`,_hoisted_1$142,[additionalInfo.locationName?(openBlock(),createElementBlock(`span`,_hoisted_2$120,toDisplayString(additionalInfo.locationName),1)):createCommentVNode(``,!0)])):createCommentVNode(``,!0),createBaseVNode(`div`,{class:normalizeClass([`minimap-container`,{"round-bottom":!hasBottomInfo.value,"round-top":!hasTopInfo.value}]),ref_key:`containerRef`,ref:containerRef},null,2),hasBottomInfo.value?(openBlock(),createElementBlock(`div`,_hoisted_3$108,[additionalInfo.policeMode===`visibleToPolice`?(openBlock(),createBlock(unref(bngIcon_default),{key:0,type:`eyeSolidOpened`})):createCommentVNode(``,!0),additionalInfo.policeMode===`hiddenFromPolice`?(openBlock(),createBlock(unref(bngIcon_default),{key:1,type:`eyeSolidClosed`})):createCommentVNode(``,!0),additionalInfo.distToTarget?(openBlock(),createElementBlock(`span`,_hoisted_4$88,toDisplayString(additionalInfo.distToTarget),1)):createCommentVNode(``,!0),additionalInfo.distToTarget?(openBlock(),createBlock(unref(bngIcon_default),{key:3,class:``,type:`mapPoint`})):createCommentVNode(``,!0)])):createCommentVNode(``,!0)],64)):minimapMode.value===`circle`?(openBlock(),createElementBlock(Fragment,{key:1},[hasTopInfo.value?(openBlock(),createElementBlock(`div`,_hoisted_5$76,[additionalInfo.locationName?(openBlock(),createElementBlock(`span`,_hoisted_6$62,toDisplayString(additionalInfo.locationName),1)):createCommentVNode(``,!0)])):createCommentVNode(``,!0),createBaseVNode(`div`,{class:normalizeClass([`minimap-container round`,{[`police-`+additionalInfo.policeMode]:!0}]),ref_key:`containerRef`,ref:containerRef},null,2),hasBottomInfo.value?(openBlock(),createElementBlock(`div`,_hoisted_7$54,[additionalInfo.policeMode===`visibleToPolice`?(openBlock(),createBlock(unref(bngIcon_default),{key:0,type:`eyeSolidOpened`})):createCommentVNode(``,!0),additionalInfo.policeMode===`hiddenFromPolice`?(openBlock(),createBlock(unref(bngIcon_default),{key:1,type:`eyeSolidClosed`})):createCommentVNode(``,!0),additionalInfo.distToTarget?(openBlock(),createElementBlock(`span`,_hoisted_8$44,toDisplayString(additionalInfo.distToTarget),1)):createCommentVNode(``,!0),additionalInfo.distToTarget?(openBlock(),createBlock(unref(bngIcon_default),{key:3,class:``,type:`mapPoint`})):createCommentVNode(``,!0)])):createCommentVNode(``,!0)],64)):createCommentVNode(``,!0)],2))}},app_default$30=__plugin_vue_export_helper_default(_sfc_main$158,[[`__scopeId`,`data-v-4d3d3a71`]]),_hoisted_1$141={class:`hotlapping-app`},_hoisted_2$119={class:`hotlapping-header`},_hoisted_3$107={class:`header-flex`},_hoisted_4$87={class:`hotlapping-content`},_hoisted_5$75={key:0,class:`grid-header`},_hoisted_6$61={class:`grid-item current-item`},_hoisted_7$53={class:`grid-item current-item`},_hoisted_8$43={class:`grid-item current-item`},_sfc_main$157={__name:`app`,setup(__props){useEvents();let fastData=ref({}),slowData=ref({}),staticData=ref({}),placementData=ref({}),displayMode=ref(`combined`);onMounted(()=>{useStreams([`lapTimes_fast`,`lapTimes_slow`,`lapTimes_static`,`lapTimes_placement`],streams=>{streams.lapTimes_fast&&(fastData.value=streams.lapTimes_fast),streams.lapTimes_slow&&(slowData.value=streams.lapTimes_slow),streams.lapTimes_static&&(staticData.value=streams.lapTimes_static),streams.lapTimes_placement&&(placementData.value=streams.lapTimes_placement)})}),onUnmounted(()=>{});let getLapValue=()=>`${slowData.value?.currentLap||0}/${staticData.value?.totalLaps||0}`,getSegmentValue=()=>`${slowData.value?.currentSegment||0}/${staticData.value?.totalSegments||0}`,getTotalRaceTime=()=>fastData.value?.currentTimeFormatted||`00:00.000`,parseTimeString=timeStr=>{if(!timeStr)return{minutes:`00`,seconds:`00`,milliseconds:`000`};let parts=timeStr.split(`:`);if(parts.length===2){let minutes=parts[0].padStart(2,`0`),secondsParts=parts[1].split(`.`);return{minutes,seconds:secondsParts[0].padStart(2,`0`),milliseconds:secondsParts[1]?secondsParts[1].padEnd(3,`0`):`000`}}else{let secondsParts=parts[0].split(`.`);return{minutes:`00`,seconds:secondsParts[0].padStart(2,`0`),milliseconds:secondsParts[1]?secondsParts[1].padEnd(3,`0`):`000`}}},getTotalRaceTimeMinutes=()=>parseTimeString(getTotalRaceTime()).minutes,getTotalRaceTimeSeconds=()=>parseTimeString(getTotalRaceTime()).seconds,getTotalRaceTimeMilliseconds=()=>parseTimeString(getTotalRaceTime()).milliseconds,isRacing=()=>slowData.value?.status===`started`||slowData.value?.status===`paused`,getCurrentLapDiffClass=()=>{let flavor=fastData.value?.currentLapDiffToBestFlavor;return flavor===`better`?`diff-better`:flavor===`worse`?`diff-worse`:`diff-neutral`},getDiffClass=(flavor,value)=>!value||value===``||value===`N/A`?`diff-neutral`:flavor===`better`?`diff-better`:flavor===`worse`?`diff-worse`:`diff-neutral`,shouldShowToggleIcon=()=>(staticData.value?.totalLaps||0)>1,shouldShowSegmentsByDefault=()=>(staticData.value?.totalLaps||0)<=1,cycleDisplayMode=()=>{if(shouldShowToggleIcon()){let modes=[`combined`,`laps`,`segments`];displayMode.value=modes[(modes.indexOf(displayMode.value)+1)%modes.length]}},getTableHeaderLabel=()=>displayMode.value===`combined`?`Combined`:displayMode.value===`segments`?`Split`:`Lap`,shouldHideVsPrevBest=()=>(staticData.value?.totalLaps||0)<=1,getCurrentTimeFormatted=()=>displayMode.value===`segments`||shouldShowSegmentsByDefault()&&displayMode.value===`combined`?fastData.value?.currentSegmentTimeFormatted:fastData.value?.currentLapTimeFormatted,getCurrentItemNumber=()=>displayMode.value===`segments`||shouldShowSegmentsByDefault()&&displayMode.value===`combined`?`${slowData.value?.currentLap||1}-${slowData.value?.currentSegment||1}`:slowData.value?.currentLap||1,getCurrentDiff=()=>displayMode.value===`segments`||shouldShowSegmentsByDefault()&&displayMode.value===`combined`?fastData.value?.currentSegmentDiffToBestFormatted||``:fastData.value?.currentLapDiffToBestFormatted||``,getCurrentTotalTime=()=>fastData.value?.currentTimeFormatted||``,getFilteredCombinedItems=()=>{if(!slowData.value||!slowData.value.combinedTimes||!Array.isArray(slowData.value.combinedTimes))return[];let filtered=[];return displayMode.value===`combined`?filtered=[...slowData.value.combinedTimes]:displayMode.value===`laps`?filtered=slowData.value.combinedTimes.filter(item=>item.type===`lap`):displayMode.value===`segments`&&(filtered=slowData.value.combinedTimes.filter(item=>item.type===`segment`)),filtered.reverse()},getItemKey=item=>`${item.type}-${item.identifier}`,getItemNumber=item=>item.identifier;return(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$141,[createBaseVNode(`div`,_hoisted_2$119,[createBaseVNode(`div`,_hoisted_3$107,[staticData.value.totalLaps>1?(openBlock(),createBlock(bngSimpleDataDisplay_default,{key:0,class:`header-cell`,label:`Lap`,value:getLapValue()},null,8,[`value`])):createCommentVNode(``,!0),staticData.value.totalSegments>1?(openBlock(),createBlock(bngSimpleDataDisplay_default,{key:1,class:`header-cell`,label:`Split`,value:getSegmentValue()},null,8,[`value`])):createCommentVNode(``,!0),createVNode(bngSimpleDataDisplay_default,{class:`header-cell`,label:`Race Clock`,minutes:getTotalRaceTimeMinutes(),seconds:getTotalRaceTimeSeconds(),milliseconds:getTotalRaceTimeMilliseconds()},null,8,[`minutes`,`seconds`,`milliseconds`])])]),createBaseVNode(`div`,_hoisted_4$87,[createBaseVNode(`div`,{class:normalizeClass([`times-grid`,{"single-lap":shouldHideVsPrevBest()}])},[createBaseVNode(`div`,{class:normalizeClass([`grid-header clickable-header`,{"has-toggle":shouldShowToggleIcon()}]),onClick:_cache[0]||=$event=>shouldShowToggleIcon()?cycleDisplayMode():null},toDisplayString(getTableHeaderLabel()),3),_cache[1]||=createBaseVNode(`div`,{class:`grid-header`},`Duration`,-1),shouldHideVsPrevBest()?createCommentVNode(``,!0):(openBlock(),createElementBlock(`div`,_hoisted_5$75,`Vs prev`)),_cache[2]||=createBaseVNode(`div`,{class:`grid-header`},`Total`,-1),isRacing()&&getCurrentTimeFormatted()?(openBlock(),createElementBlock(Fragment,{key:1},[createBaseVNode(`div`,_hoisted_6$61,toDisplayString(getCurrentItemNumber()),1),createBaseVNode(`div`,_hoisted_7$53,toDisplayString(getCurrentTimeFormatted()),1),shouldHideVsPrevBest()?createCommentVNode(``,!0):(openBlock(),createElementBlock(`div`,{key:0,class:normalizeClass([`grid-item current-item`,getCurrentLapDiffClass()])},toDisplayString(getCurrentDiff()),3)),createBaseVNode(`div`,_hoisted_8$43,toDisplayString(getCurrentTotalTime()),1)],64)):createCommentVNode(``,!0),(openBlock(!0),createElementBlock(Fragment,null,renderList(getFilteredCombinedItems(),item=>(openBlock(),createElementBlock(Fragment,{key:getItemKey(item)},[createBaseVNode(`div`,{class:normalizeClass([`grid-item`,{"best-item left-indicator":item.flavor===`best`,"is-lap":item.type===`lap`}])},toDisplayString(getItemNumber(item)),3),createBaseVNode(`div`,{class:normalizeClass([`grid-item`,{"best-item":item.flavor===`best`}])},toDisplayString(item.durationFormatted),3),shouldHideVsPrevBest()?createCommentVNode(``,!0):(openBlock(),createElementBlock(`div`,{key:0,class:normalizeClass([`grid-item`,[{"best-item":item.flavor===`best`},getDiffClass(item.diffToPreviousFlavor,item.diffToPreviousFormatted)]])},toDisplayString(item.diffToPreviousFormatted||``),3)),createBaseVNode(`div`,{class:normalizeClass([`grid-item`,{"best-item":item.flavor===`best`}])},toDisplayString(item.endTimeFormatted||``),3)],64))),128))],2)])]))}},app_default$31=__plugin_vue_export_helper_default(_sfc_main$157,[[`__scopeId`,`data-v-a9e5d83a`]]),_hoisted_1$140={class:`laptimes-section`},_hoisted_2$118={class:`collapse-icon`},_hoisted_3$106={class:`collapsible-content`},_hoisted_4$86={class:`laptimes-data-grid`},_hoisted_5$74={key:0,class:`data-item`},_hoisted_6$60={class:`value`},_hoisted_7$52={key:1,class:`data-item`},_hoisted_8$42={class:`data-item`},_hoisted_9$39={class:`value`},_hoisted_10$32={class:`data-item`},_hoisted_11$29={class:`value`},_hoisted_12$23={class:`data-item`},_hoisted_13$20={class:`value`},_hoisted_14$20={class:`data-item`},_hoisted_15$19={class:`value`},_hoisted_16$19={key:0,class:`laptimes-data-grid`,style:{"margin-top":`1rem`}},_hoisted_17$15={key:0,class:`data-item`},_hoisted_18$13={key:1,class:`data-item`},_hoisted_19$10={key:1,class:`laptimes-data-grid`,style:{"margin-top":`1rem`}},_hoisted_20$9={key:0,class:`data-item`},_hoisted_21$9={key:1,class:`data-item`},_sfc_main$156={__name:`BasicInfo`,props:{fastData:{type:Object,required:!0},staticData:{type:Object,required:!0},slowData:{type:Object,required:!0}},setup(__props){let isCollapsed=ref(!1),toggleCollapse=()=>{isCollapsed.value=!isCollapsed.value};return(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$140,[createBaseVNode(`h3`,{onClick:toggleCollapse,class:`collapsible-header`},[createBaseVNode(`span`,_hoisted_2$118,toDisplayString(isCollapsed.value?`▶`:`▼`),1),_cache[0]||=createTextVNode(` Race Info `,-1)]),withDirectives(createBaseVNode(`div`,_hoisted_3$106,[createBaseVNode(`div`,_hoisted_4$86,[__props.slowData.status===`started`||__props.slowData.status===`paused`?(openBlock(),createElementBlock(`div`,_hoisted_5$74,[_cache[1]||=createBaseVNode(`span`,{class:`label`},`Current Time:`,-1),createBaseVNode(`span`,_hoisted_6$60,toDisplayString(__props.fastData.currentTimeFormatted||`00:00.000`),1)])):(openBlock(),createElementBlock(`div`,_hoisted_7$52,[_cache[2]||=createBaseVNode(`span`,{class:`label`},`Status:`,-1),createBaseVNode(`span`,{class:normalizeClass([`value`,{active:__props.slowData.status===`started`,paused:__props.slowData.status===`paused`}])},toDisplayString(__props.slowData.status?.toUpperCase()||`STOPPED`),3)])),createBaseVNode(`div`,_hoisted_8$42,[_cache[3]||=createBaseVNode(`span`,{class:`label`},`Lap:`,-1),createBaseVNode(`span`,_hoisted_9$39,toDisplayString(__props.slowData.currentLap||0)+`/`+toDisplayString(__props.staticData.totalLaps||0),1)]),createBaseVNode(`div`,_hoisted_10$32,[_cache[4]||=createBaseVNode(`span`,{class:`label`},`Segment:`,-1),createBaseVNode(`span`,_hoisted_11$29,toDisplayString(__props.slowData.currentSegment||0)+`/`+toDisplayString(__props.staticData.totalSegments||0),1)]),createBaseVNode(`div`,_hoisted_12$23,[_cache[5]||=createBaseVNode(`span`,{class:`label`},`Current Lap Time:`,-1),createBaseVNode(`span`,_hoisted_13$20,toDisplayString(__props.fastData.currentLapTimeFormatted||`00:00.000`),1)]),createBaseVNode(`div`,_hoisted_14$20,[_cache[6]||=createBaseVNode(`span`,{class:`label`},`Current Segment Time:`,-1),createBaseVNode(`span`,_hoisted_15$19,toDisplayString(__props.fastData.currentSegmentTimeFormatted||`00:00.000`),1)])]),__props.fastData.currentLapDiffToBestFormatted||__props.fastData.currentLapDiffToPreviousFormatted?(openBlock(),createElementBlock(`div`,_hoisted_16$19,[__props.fastData.currentLapDiffToBestFormatted?(openBlock(),createElementBlock(`div`,_hoisted_17$15,[_cache[7]||=createBaseVNode(`span`,{class:`label`},`Lap Diff to Best:`,-1),createBaseVNode(`span`,{class:normalizeClass([`value`,`diff-`+(__props.fastData.currentLapDiffToBestFlavor||`default`)])},toDisplayString(__props.fastData.currentLapDiffToBestFormatted),3)])):createCommentVNode(``,!0),__props.fastData.currentLapDiffToPreviousFormatted?(openBlock(),createElementBlock(`div`,_hoisted_18$13,[_cache[8]||=createBaseVNode(`span`,{class:`label`},`Lap Diff to Previous:`,-1),createBaseVNode(`span`,{class:normalizeClass([`value`,`diff-`+(__props.fastData.currentLapDiffToPreviousFlavor||`default`)])},toDisplayString(__props.fastData.currentLapDiffToPreviousFormatted),3)])):createCommentVNode(``,!0)])):createCommentVNode(``,!0),__props.fastData.currentSegmentDiffToBestFormatted||__props.fastData.currentSegmentDiffToPreviousFormatted?(openBlock(),createElementBlock(`div`,_hoisted_19$10,[__props.fastData.currentSegmentDiffToBestFormatted?(openBlock(),createElementBlock(`div`,_hoisted_20$9,[_cache[9]||=createBaseVNode(`span`,{class:`label`},`Segment Diff to Best:`,-1),createBaseVNode(`span`,{class:normalizeClass([`value`,`diff-`+(__props.fastData.currentSegmentDiffToBestFlavor||`default`)])},toDisplayString(__props.fastData.currentSegmentDiffToBestFormatted),3)])):createCommentVNode(``,!0),__props.fastData.currentSegmentDiffToPreviousFormatted?(openBlock(),createElementBlock(`div`,_hoisted_21$9,[_cache[10]||=createBaseVNode(`span`,{class:`label`},`Segment Diff to Previous:`,-1),createBaseVNode(`span`,{class:normalizeClass([`value`,`diff-`+(__props.fastData.currentSegmentDiffToPreviousFlavor||`default`)])},toDisplayString(__props.fastData.currentSegmentDiffToPreviousFormatted),3)])):createCommentVNode(``,!0)])):createCommentVNode(``,!0)],512),[[vShow,!isCollapsed.value]])]))}},BasicInfo_default=__plugin_vue_export_helper_default(_sfc_main$156,[[`__scopeId`,`data-v-4329fa2c`]]),_hoisted_1$139={class:`laptimes-section`},_hoisted_2$117={class:`collapse-icon`},_hoisted_3$105={class:`collapsible-content`},_hoisted_4$85={class:`laptimes-data-grid`,style:{"margin-bottom":`1rem`}},_hoisted_5$73={class:`data-item`},_hoisted_6$59={class:`value`},_hoisted_7$51={key:0,class:`laptimes-data-grid`},_hoisted_8$41={class:`label`},_hoisted_9$38={class:`value`},_sfc_main$155={__name:`BestTimes`,props:{slowData:{type:Object,required:!0}},setup(__props){let props=__props,isCollapsed=ref(!1),toggleCollapse=()=>{isCollapsed.value=!isCollapsed.value},getBestLapDisplay=()=>{let bestTime=props.slowData.bestLapTimeFormatted||`N/A`,bestIndex=props.slowData.bestLapIndex===-1?null:props.slowData.bestLapIndex;return bestTime===`N/A`||bestIndex===null?`N/A`:`${bestTime} in Lap ${bestIndex}`},getBestSegmentDisplayFromData=segmentData=>{if(!segmentData||typeof segmentData!=`object`)return`N/A`;let time=segmentData.time||`N/A`,lap=segmentData.lap;return lap?`${time} in Lap ${lap}`:time};return(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$139,[createBaseVNode(`h3`,{onClick:toggleCollapse,class:`collapsible-header`},[createBaseVNode(`span`,_hoisted_2$117,toDisplayString(isCollapsed.value?`▶`:`▼`),1),_cache[0]||=createTextVNode(` Best Times `,-1)]),withDirectives(createBaseVNode(`div`,_hoisted_3$105,[createBaseVNode(`div`,_hoisted_4$85,[createBaseVNode(`div`,_hoisted_5$73,[_cache[1]||=createBaseVNode(`span`,{class:`label`},`Best Lap:`,-1),createBaseVNode(`span`,_hoisted_6$59,toDisplayString(getBestLapDisplay()),1)])]),__props.slowData.bestSegmentTimesFormatted&&Object.keys(__props.slowData.bestSegmentTimesFormatted).length>0?(openBlock(),createElementBlock(`div`,_hoisted_7$51,[(openBlock(!0),createElementBlock(Fragment,null,renderList(__props.slowData.bestSegmentTimesFormatted,(segmentData,segment)=>(openBlock(),createElementBlock(`div`,{class:`data-item`,key:segment},[createBaseVNode(`span`,_hoisted_8$41,`Best Segment `+toDisplayString(parseInt(segment)+1)+`:`,1),createBaseVNode(`span`,_hoisted_9$38,toDisplayString(getBestSegmentDisplayFromData(segmentData)),1)]))),128))])):createCommentVNode(``,!0)],512),[[vShow,!isCollapsed.value]])]))}},BestTimes_default=__plugin_vue_export_helper_default(_sfc_main$155,[[`__scopeId`,`data-v-3cd1750d`]]),_hoisted_1$138={class:`laptimes-section`},_hoisted_2$116={class:`collapse-icon`},_hoisted_3$104={class:`collapsible-content`},_hoisted_4$84={class:`table-header`},_hoisted_5$72={key:0},_hoisted_6$58={key:1},_hoisted_7$50={key:0,class:`table-row current-lap-row`},_sfc_main$154={__name:`LapTimes`,props:{fastData:{type:Object,required:!0},slowData:{type:Object,required:!0},staticData:{type:Object,required:!0}},setup(__props){let isCollapsed=ref(!1),toggleCollapse=()=>{isCollapsed.value=!isCollapsed.value},getDiffFlavorClass=flavor=>flavor?{"diff-better":flavor===`better`,"diff-worse":flavor===`worse`,"diff-same":flavor===`same`}:``;return(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$138,[createBaseVNode(`h3`,{onClick:toggleCollapse,class:`collapsible-header`},[createBaseVNode(`span`,_hoisted_2$116,toDisplayString(isCollapsed.value?`▶`:`▼`),1),_cache[0]||=createTextVNode(` Lap Times `,-1)]),withDirectives(createBaseVNode(`div`,_hoisted_3$104,[__props.slowData.lapTimes&&__props.slowData.lapTimes.length>0||__props.slowData.status===`started`||__props.slowData.status===`paused`?(openBlock(),createElementBlock(`div`,{key:0,class:normalizeClass([`laptimes-table`,{"single-lap":__props.staticData.totalLaps<=1}])},[createBaseVNode(`div`,_hoisted_4$84,[_cache[1]||=createBaseVNode(`span`,null,`Lap`,-1),_cache[2]||=createBaseVNode(`span`,null,`Time`,-1),_cache[3]||=createBaseVNode(`span`,null,`Duration`,-1),__props.staticData.totalLaps>1?(openBlock(),createElementBlock(`span`,_hoisted_5$72,`Diff to Best`)):createCommentVNode(``,!0),__props.staticData.totalLaps>1?(openBlock(),createElementBlock(`span`,_hoisted_6$58,`Diff to Prev`)):createCommentVNode(``,!0)]),(openBlock(!0),createElementBlock(Fragment,null,renderList(__props.slowData.lapTimes,lap=>(openBlock(),createElementBlock(`div`,{key:lap.lap,class:normalizeClass([`table-row`,{"best-lap":lap.lapFlavor===`best`,"current-lap":lap.isCurrent}])},[createBaseVNode(`span`,null,toDisplayString(lap.lap),1),createBaseVNode(`span`,null,toDisplayString(lap.timeFormatted||lap.endTimeFormatted||`N/A`),1),createBaseVNode(`span`,null,toDisplayString(lap.durationFormatted),1),__props.staticData.totalLaps>1?(openBlock(),createElementBlock(`span`,{key:0,class:normalizeClass(getDiffFlavorClass(lap.diffToBestFlavor))},toDisplayString(lap.diffToBestFormatted||`N/A`),3)):createCommentVNode(``,!0),__props.staticData.totalLaps>1?(openBlock(),createElementBlock(`span`,{key:1,class:normalizeClass(getDiffFlavorClass(lap.diffToPreviousFlavor))},toDisplayString(lap.diffToPreviousFormatted||`N/A`),3)):createCommentVNode(``,!0)],2))),128)),(__props.slowData.status===`started`||__props.slowData.status===`paused`)&&__props.fastData.currentLapTimeFormatted?(openBlock(),createElementBlock(`div`,_hoisted_7$50,[createBaseVNode(`span`,null,toDisplayString(__props.slowData.currentLap||1),1),createBaseVNode(`span`,null,toDisplayString(__props.fastData.currentTimeFormatted),1),createBaseVNode(`span`,null,toDisplayString(__props.fastData.currentLapTimeFormatted),1),__props.staticData.totalLaps>1?(openBlock(),createElementBlock(`span`,{key:0,class:normalizeClass(getDiffFlavorClass(__props.fastData.currentLapDiffToBestFlavor))},toDisplayString(__props.fastData.currentLapDiffToBestFormatted||`N/A`),3)):createCommentVNode(``,!0),__props.staticData.totalLaps>1?(openBlock(),createElementBlock(`span`,{key:1,class:normalizeClass(getDiffFlavorClass(__props.fastData.currentLapDiffToPreviousFlavor))},toDisplayString(__props.fastData.currentLapDiffToPreviousFormatted||`N/A`),3)):createCommentVNode(``,!0)])):createCommentVNode(``,!0)],2)):createCommentVNode(``,!0)],512),[[vShow,!isCollapsed.value]])]))}},LapTimes_default=__plugin_vue_export_helper_default(_sfc_main$154,[[`__scopeId`,`data-v-ed892fc5`]]),_hoisted_1$137={class:`laptimes-section`},_hoisted_2$115={class:`collapse-icon`},_hoisted_3$103={class:`collapsible-content`},_hoisted_4$83={class:`table-header`},_hoisted_5$71={key:0},_hoisted_6$57={key:1},_hoisted_7$49={key:0,class:`table-row current-segment-row`},_sfc_main$153={__name:`SegmentTimes`,props:{fastData:{type:Object,required:!0},slowData:{type:Object,required:!0},staticData:{type:Object,required:!0}},setup(__props){let isCollapsed=ref(!1),toggleCollapse=()=>{isCollapsed.value=!isCollapsed.value},getDiffFlavorClass=flavor=>flavor?{"diff-better":flavor===`better`,"diff-worse":flavor===`worse`,"diff-same":flavor===`same`}:``;return(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$137,[createBaseVNode(`h3`,{onClick:toggleCollapse,class:`collapsible-header`},[createBaseVNode(`span`,_hoisted_2$115,toDisplayString(isCollapsed.value?`▶`:`▼`),1),_cache[0]||=createTextVNode(` Segment Times `,-1)]),withDirectives(createBaseVNode(`div`,_hoisted_3$103,[__props.slowData.segmentTimes&&__props.slowData.segmentTimes.length>0||__props.slowData.status===`started`||__props.slowData.status===`paused`?(openBlock(),createElementBlock(`div`,{key:0,class:normalizeClass([`laptimes-table`,{"single-lap":__props.staticData.totalLaps<=1}])},[createBaseVNode(`div`,_hoisted_4$83,[_cache[1]||=createBaseVNode(`span`,null,`Segment`,-1),_cache[2]||=createBaseVNode(`span`,null,`Time`,-1),_cache[3]||=createBaseVNode(`span`,null,`Duration`,-1),__props.staticData.totalLaps>1?(openBlock(),createElementBlock(`span`,_hoisted_5$71,`Diff to Best`)):createCommentVNode(``,!0),__props.staticData.totalLaps>1?(openBlock(),createElementBlock(`span`,_hoisted_6$57,`Diff to Prev`)):createCommentVNode(``,!0)]),(openBlock(!0),createElementBlock(Fragment,null,renderList(__props.slowData.segmentTimes,segment=>(openBlock(),createElementBlock(`div`,{key:segment.segment,class:normalizeClass([`table-row`,{"best-segment":segment.segmentFlavor===`best`,"current-segment":segment.isCurrent}])},[createBaseVNode(`span`,null,toDisplayString(segment.segment),1),createBaseVNode(`span`,null,toDisplayString(segment.timeFormatted||segment.endTimeFormatted||`N/A`),1),createBaseVNode(`span`,null,toDisplayString(segment.durationFormatted),1),__props.staticData.totalLaps>1?(openBlock(),createElementBlock(`span`,{key:0,class:normalizeClass(getDiffFlavorClass(segment.diffToBestFlavor))},toDisplayString(segment.diffToBestFormatted||`N/A`),3)):createCommentVNode(``,!0),__props.staticData.totalLaps>1?(openBlock(),createElementBlock(`span`,{key:1,class:normalizeClass(getDiffFlavorClass(segment.diffToPreviousFlavor))},toDisplayString(segment.diffToPreviousFormatted||`N/A`),3)):createCommentVNode(``,!0)],2))),128)),(__props.slowData.status===`started`||__props.slowData.status===`paused`)&&__props.fastData.currentSegmentTimeFormatted?(openBlock(),createElementBlock(`div`,_hoisted_7$49,[createBaseVNode(`span`,null,toDisplayString(__props.slowData.currentLap||1)+`-`+toDisplayString(__props.slowData.currentSegment||1),1),createBaseVNode(`span`,null,toDisplayString(__props.fastData.currentTimeFormatted),1),createBaseVNode(`span`,null,toDisplayString(__props.fastData.currentSegmentTimeFormatted),1),__props.staticData.totalLaps>1?(openBlock(),createElementBlock(`span`,{key:0,class:normalizeClass(getDiffFlavorClass(__props.fastData.currentSegmentDiffToBestFlavor))},toDisplayString(__props.fastData.currentSegmentDiffToBestFormatted||`N/A`),3)):createCommentVNode(``,!0),__props.staticData.totalLaps>1?(openBlock(),createElementBlock(`span`,{key:1,class:normalizeClass(getDiffFlavorClass(__props.fastData.currentSegmentDiffToPreviousFlavor))},toDisplayString(__props.fastData.currentSegmentDiffToPreviousFormatted||`N/A`),3)):createCommentVNode(``,!0)])):createCommentVNode(``,!0)],2)):createCommentVNode(``,!0)],512),[[vShow,!isCollapsed.value]])]))}},SegmentTimes_default=__plugin_vue_export_helper_default(_sfc_main$153,[[`__scopeId`,`data-v-3801fbed`]]),_hoisted_1$136={key:0,class:`laptimes-section`},_hoisted_2$114={class:`collapse-icon`},_hoisted_3$102={class:`collapsible-content`},_hoisted_4$82={class:`laptimes-data-grid`,style:{"margin-bottom":`1rem`}},_hoisted_5$70={class:`data-item`},_hoisted_6$56={class:`value`},_hoisted_7$48={class:`data-item`},_hoisted_8$40={class:`value`},_hoisted_9$37={class:`laptimes-table`},_hoisted_10$31={class:`table-header`},_hoisted_11$28={key:0},_hoisted_12$22={key:1},_hoisted_13$19={key:0},_hoisted_14$19={key:1},_sfc_main$152={__name:`Placement`,props:{fastData:{type:Object,required:!0},slowData:{type:Object,required:!0},staticData:{type:Object,required:!0},placementData:{type:Object,required:!0}},setup(__props){let props=__props,isCollapsed=ref(!1),toggleCollapse=()=>{isCollapsed.value=!isCollapsed.value},playerVehicleId=computed(()=>{if(props.placementData.vehicleStates){let vehicleIds=Object.keys(props.placementData.vehicleStates);return vehicleIds.length>0?parseInt(vehicleIds[0]):null}return null}),playerPlacement=computed(()=>!playerVehicleId.value||!props.placementData.placements?null:props.placementData.placements[playerVehicleId.value]),totalRacers=computed(()=>props.placementData.placements?Object.keys(props.placementData.placements).length:0),shouldShowLapColumn=computed(()=>{if(!props.staticData.pathConfig)return!1;let pathConfig=props.staticData.pathConfig;return pathConfig.isClosed&&pathConfig.lapCount>1}),shouldShowSegmentColumn=computed(()=>{if(!props.staticData.pathConfig)return!1;let pathConfig=props.staticData.pathConfig;return!pathConfig.isClosed||pathConfig.isClosed&&pathConfig.lapCount>1}),sortedRacers=computed(()=>{if(!props.placementData.placements||!props.placementData.vehicleStates)return[];let racers=[];return Object.entries(props.placementData.placements).forEach(([vehicleId,placement])=>{let vehicleIdNum=parseInt(vehicleId),vehicleState=props.placementData.vehicleStates[vehicleId],timeDiffData=props.placementData.timeDifferencesToFirst?.[vehicleId],timeDiff=timeDiffData?.timeDifference||0;racers.push({vehicleId:vehicleIdNum,placement,currentLap:vehicleState?.currentLap||0,currentSegment:vehicleState?.currentSegment||0,isPlayer:vehicleIdNum===playerVehicleId.value,timeDiff,timeDiffFormatted:timeDiffData?.timeDifferenceFormatted||`0.000`})}),racers.sort((a$1,b)=>a$1.placement-b.placement)}),getTimeDiffClass=timeDiff=>timeDiff==null?``:{"diff-red":timeDiff>0,"diff-green":timeDiff<0,"diff-neutral":timeDiff===0};return(_ctx,_cache)=>__props.placementData.placements&&Object.keys(__props.placementData.placements).length>1?(openBlock(),createElementBlock(`div`,_hoisted_1$136,[createBaseVNode(`h3`,{onClick:toggleCollapse,class:`collapsible-header`},[createBaseVNode(`span`,_hoisted_2$114,toDisplayString(isCollapsed.value?`▶`:`▼`),1),_cache[0]||=createTextVNode(` Race Positions `,-1)]),withDirectives(createBaseVNode(`div`,_hoisted_3$102,[createBaseVNode(`div`,_hoisted_4$82,[createBaseVNode(`div`,_hoisted_5$70,[_cache[1]||=createBaseVNode(`span`,{class:`label`},`Your Position:`,-1),createBaseVNode(`span`,_hoisted_6$56,toDisplayString(playerPlacement.value||`N/A`),1)]),createBaseVNode(`div`,_hoisted_7$48,[_cache[2]||=createBaseVNode(`span`,{class:`label`},`Total Racers:`,-1),createBaseVNode(`span`,_hoisted_8$40,toDisplayString(totalRacers.value),1)])]),createBaseVNode(`div`,_hoisted_9$37,[createBaseVNode(`div`,_hoisted_10$31,[_cache[3]||=createBaseVNode(`span`,null,`Pos`,-1),_cache[4]||=createBaseVNode(`span`,null,`Vehicle`,-1),shouldShowLapColumn.value?(openBlock(),createElementBlock(`span`,_hoisted_11$28,`Lap`)):createCommentVNode(``,!0),shouldShowSegmentColumn.value?(openBlock(),createElementBlock(`span`,_hoisted_12$22,`Segment`)):createCommentVNode(``,!0),_cache[5]||=createBaseVNode(`span`,null,`Time Diff`,-1)]),(openBlock(!0),createElementBlock(Fragment,null,renderList(sortedRacers.value,(racer,index)=>(openBlock(),createElementBlock(`div`,{key:racer.vehicleId,class:normalizeClass([`table-row`,{"player-row":racer.isPlayer,"leader-row":index===0}])},[createBaseVNode(`span`,null,toDisplayString(racer.placement),1),createBaseVNode(`span`,null,toDisplayString(racer.vehicleId===playerVehicleId.value?`You`:`Vehicle ${racer.vehicleId}`),1),shouldShowLapColumn.value?(openBlock(),createElementBlock(`span`,_hoisted_13$19,toDisplayString(racer.currentLap||0),1)):createCommentVNode(``,!0),shouldShowSegmentColumn.value?(openBlock(),createElementBlock(`span`,_hoisted_14$19,toDisplayString(racer.currentSegment||0),1)):createCommentVNode(``,!0),createBaseVNode(`span`,{class:normalizeClass(getTimeDiffClass(racer.timeDiff))},toDisplayString(racer.timeDiffFormatted),3)],2))),128))])],512),[[vShow,!isCollapsed.value]])])):createCommentVNode(``,!0)}},Placement_default=__plugin_vue_export_helper_default(_sfc_main$152,[[`__scopeId`,`data-v-c2373a09`]]),_hoisted_1$135={class:`laptimes-section`},_hoisted_2$113={class:`collapse-icon`},_hoisted_3$101={class:`collapsible-content`},_hoisted_4$81={class:`raw-data-container`},_hoisted_5$69={key:0,class:`data-stream`},_hoisted_6$55={class:`data-content`},_hoisted_7$47={key:1,class:`data-stream`},_hoisted_8$39={class:`data-content`},_hoisted_9$36={key:2,class:`data-stream`},_hoisted_10$30={class:`data-content`},_hoisted_11$27={key:3,class:`data-stream`},_hoisted_12$21={class:`data-content`},_sfc_main$151={__name:`RawData`,props:{fastData:{type:Object,required:!0},slowData:{type:Object,required:!0},staticData:{type:Object,required:!0},placementData:{type:Object,required:!0}},setup(__props){let isCollapsed=ref(!0),toggleCollapse=()=>{isCollapsed.value=!isCollapsed.value};return(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$135,[createBaseVNode(`h3`,{onClick:toggleCollapse,class:`collapsible-header`},[createBaseVNode(`span`,_hoisted_2$113,toDisplayString(isCollapsed.value?`▶`:`▼`),1),_cache[0]||=createTextVNode(` Raw Stream Data `,-1)]),withDirectives(createBaseVNode(`div`,_hoisted_3$101,[createBaseVNode(`div`,_hoisted_4$81,[__props.fastData?(openBlock(),createElementBlock(`div`,_hoisted_5$69,[createBaseVNode(`h4`,null,`Fast Stream Data `+toDisplayString(__props.fastData.timestamp),1),createBaseVNode(`pre`,_hoisted_6$55,toDisplayString(JSON.stringify(__props.fastData,null,1)),1)])):createCommentVNode(``,!0),__props.slowData?(openBlock(),createElementBlock(`div`,_hoisted_7$47,[createBaseVNode(`h4`,null,`Slow Stream Data `+toDisplayString(__props.slowData.timestamp),1),createBaseVNode(`pre`,_hoisted_8$39,toDisplayString(JSON.stringify(__props.slowData,null,1)),1)])):createCommentVNode(``,!0),__props.staticData?(openBlock(),createElementBlock(`div`,_hoisted_9$36,[createBaseVNode(`h4`,null,`Static Stream Data `+toDisplayString(__props.staticData.timestamp),1),createBaseVNode(`pre`,_hoisted_10$30,toDisplayString(JSON.stringify(__props.staticData,null,1)),1)])):createCommentVNode(``,!0),__props.placementData?(openBlock(),createElementBlock(`div`,_hoisted_11$27,[createBaseVNode(`h4`,null,`Placement Stream Data `+toDisplayString(__props.placementData.timestamp),1),createBaseVNode(`pre`,_hoisted_12$21,toDisplayString(JSON.stringify(__props.placementData,null,1)),1)])):createCommentVNode(``,!0)])],512),[[vShow,!isCollapsed.value]])]))}},RawData_default=__plugin_vue_export_helper_default(_sfc_main$151,[[`__scopeId`,`data-v-7bc3ab60`]]),_hoisted_1$134={class:`laptimes-app`,style:{"overflow-y":`scroll`}},_sfc_main$150={__name:`appDebug`,setup(__props){useEvents();let fastData=ref({}),slowData=ref({}),staticData=ref({}),placementData=ref({});return onMounted(()=>{useStreams([`lapTimes_fast`,`lapTimes_slow`,`lapTimes_static`,`lapTimes_placement`],streams=>{streams.lapTimes_fast&&(fastData.value=streams.lapTimes_fast),streams.lapTimes_slow&&(slowData.value=streams.lapTimes_slow),streams.lapTimes_static&&(staticData.value=streams.lapTimes_static),streams.lapTimes_placement&&(placementData.value=streams.lapTimes_placement)})}),onUnmounted(()=>{}),(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$134,[_cache[0]||=createBaseVNode(`div`,{class:`laptimes-header`},[createBaseVNode(`h2`,null,`Lap Times Debug`)],-1),createVNode(BasicInfo_default,{fastData:fastData.value,slowData:slowData.value,staticData:staticData.value},null,8,[`fastData`,`slowData`,`staticData`]),createVNode(BestTimes_default,{slowData:slowData.value},null,8,[`slowData`]),createVNode(LapTimes_default,{fastData:fastData.value,slowData:slowData.value,staticData:staticData.value},null,8,[`fastData`,`slowData`,`staticData`]),createVNode(SegmentTimes_default,{fastData:fastData.value,slowData:slowData.value,staticData:staticData.value},null,8,[`fastData`,`slowData`,`staticData`]),createVNode(Placement_default,{fastData:fastData.value,slowData:slowData.value,staticData:staticData.value,placementData:placementData.value},null,8,[`fastData`,`slowData`,`staticData`,`placementData`]),createVNode(RawData_default,{fastData:fastData.value,slowData:slowData.value,staticData:staticData.value,placementData:placementData.value},null,8,[`fastData`,`slowData`,`staticData`,`placementData`])]))}},appDebug_default$1=__plugin_vue_export_helper_default(_sfc_main$150,[[`__scopeId`,`data-v-49102eaf`]]),_hoisted_1$133={class:`messages-app`},_hoisted_2$112={key:0,class:`icon-cell`},_hoisted_3$100={class:`text-cell`},_hoisted_4$80={key:0},timerIntervalMs=300,_sfc_main$149={__name:`app`,props:{maxMessages:{type:Number,default:void 0},dense:{type:Boolean,default:!1},wrap:{type:Boolean,default:!0},showIcons:{type:Boolean,default:!0}},setup(__props){let props=__props,events$3=useEvents(),messagesByCategory=reactive({}),bypassTtl=ref(!1),getIconProps=item=>{let icon=resolvedType(item.icon);if(icon)return{type:icon};let externalImage=resolvedExternalImage(item.icon);return externalImage?{externalImage}:{type:`info`}},timerId,isAssetPath=icon=>typeof icon==`string`&&icon.startsWith(`/`),resolvedType=icon=>typeof icon==`string`&&!isAssetPath(icon)?icon:void 0,resolvedExternalImage=icon=>typeof icon==`string`&&isAssetPath(icon)?icon:void 0,messagesList=computed(()=>{let list=Object.values(messagesByCategory);return typeof props.maxMessages==`number`&&props.maxMessages>0?list.slice(0,props.maxMessages):list});function resolveTranslation(val){return val==null?``:typeof val==`string`?$translate.instant(val):Array.isArray(val)?$translate.multiContextTranslate(val):typeof val==`object`?$translate.contextTranslate(val):String(val)}function htmlToPlainText(html){if(typeof html!=`string`)return String(html??``);let h$1=html.replace(//gi,` `),el=document.createElement(`div`);el.innerHTML=h$1;let text=el.textContent??el.innerText??h$1;return text=text.replace(/<[^>]*>/g,``),text}function sanitizeTextSegment(text){return text?htmlToPlainText(parse$1?parse$1(text):text):``}function getParts(item){let raw=resolveTranslation(item.text);if(typeof raw!=`string`)return[{t:`text`,v:sanitizeTextSegment(String(raw))}];let parts=[],rgx=/\[action=([^\]]+)\]/gi,lastIndex=0,match;for(;(match=rgx.exec(raw))!==null;){let head=raw.slice(lastIndex,match.index);head&&parts.push({t:`text`,v:sanitizeTextSegment(head)});let actionName=match[1].trim();parts.push({t:`binding`,action:actionName}),lastIndex=match.index+match[0].length}let tail=raw.slice(lastIndex);return tail&&parts.push({t:`text`,v:sanitizeTextSegment(tail)}),parts.length?parts:[{t:`text`,v:sanitizeTextSegment(raw)}]}function normalizePayload(args){let category=args?.category??`default`,clear=!!args?.clear,text=args&&`text`in args?args.text:args&&`msg`in args?args.msg:``,icon=typeof args?.icon==`string`?args.icon:void 0,ttlMs=typeof args?.ttlMs==`number`?args.ttlMs:typeof args?.ttl==`number`?args.ttl*1e3:void 0;return ttlMs??=5e3,{category,clear,text,icon,ttlMs}}let CATEGORY_ICONS=[{match:`vehicle.absBehavior`,icon:`ABSIndicator`},{match:`vehicle.brakingdistance`,icon:`carsFollow`},{prefix:`vehicle.compressionBrake.`,icon:`engine`},{prefix:`vehicle.damage.exhaust`,icon:`exhaustMuffler`},{prefix:`vehicle.damage.deflated.`,icon:`tireDeflated`},{prefix:`vehicle.beamstate.tireDeflated`,icon:`tireDeflated`},{match:`vehicle.damage.mildOverrev`,icon:`powerGauge05`},{match:`vehicle.damage.catastrophicOverrev`,icon:`powerGauge05`},{match:`vehicle.damage.catastrophicOverTorque`,icon:`cogDamaged`},{match:`vehicle.damage.flood`,icon:`water`},{match:`vehicle.engine.isStalling`,icon:`powerGauge01`},{match:`vehicle.ignition.ignitionLevel`,icon:`keys1`},{match:`vehicle.lightbar.mode`,icon:`wigwags`},{match:`vehicle.linelock.status`,icon:`wheelDisc`},{match:`vehicle.postCrashBrake.impact`,icon:`hazardLights`},{prefix:`vehicle.powertrain.diffmode.`,icon:`drivetrainGeneric`},{match:`vehicle.powertrain.nitrousOxideInjection`,icon:`N2OHoriz`},{match:`vehicle.shiftLogic.cannotShift`,icon:`cogsDamaged`},{match:`vehicle.shiftermode`,icon:`transmissionM`},{match:`vehicle.transbrake.status`,icon:`cogs`},{match:`vehicle.twoStep.status`,icon:`signal04a`},{match:`vehicle.tirePressureControl.inflateDeflate`,icon:`tirePressureGaugeOutlined03`},{prefix:`vehicle.wheels.tirePunctured.`,icon:`tireAirPuff`},{prefix:`vehicle.damage.device.`,icon:`cogDamaged`},{match:`vehicle.driveModes`,icon:`ESC`},{prefix:`vehicle.driveModes.`,icon:`ESC`},{match:`vehicle.engine.oilOverheating.true`,icon:`coolantTemp`},{match:`vehicle.engine.blockMelted.true`,icon:`coolantTemp`},{match:`vehicle.engine.headGasketDamaged.true`,icon:`coolantTemp`},{match:`vehicle.engine.coolantOverheating.true`,icon:`coolantTemp`},{match:`vehicle.engine.radiatorLeak.true`,icon:`coolantTemp`},{prefix:`vehicle.engine.`,icon:`engine`},{prefix:`vehicle.recovery.`,icon:`tow`},{match:`rally`,icon:`rallyHelmet`},{match:`fill`,icon:`import`},{match:`align`,icon:`flag`},{match:`delivery`,icon:`boxTruckFast`},{match:`refueling`,icon:`fuelPumpFilling`},{prefix:`refueling-`,icon:`fuelPumpFilling`},{prefix:`ui.camera.`,icon:`movieCamera`},{match:`input`,icon:`gamepad`},{prefix:`ui.apps.damage_app_vehicle_simple.component.`,icon:`cogsDamaged`},{match:`AI debug`,icon:`AIMicrochip`},{match:`debug`,icon:`code`},{match:`hydros`,icon:`steeringWheelCommon`},{match:`GLTFexport`,icon:`loadMesh`},{match:`bigmap.info.reachedTarget`,icon:`raceFlag`}];function deriveIconForCategory(category){if(!category)return`info`;console.debug(`[messages] deriveIconForCategory`,category);for(let{match,prefix:prefix$1,icon}of CATEGORY_ICONS){if(match&&category===match)return console.debug(` -> match:`,match,icon),icon;if(prefix$1&&category.startsWith(prefix$1))return console.debug(` -> prefix:`,prefix$1,icon),icon}return console.debug(` -> no match, fallback to info`),`info`}function onMessage(args){let{category,clear,text,icon,ttlMs}=normalizePayload(args),matched=[];try{let re=new RegExp(category);matched=Object.keys(messagesByCategory).filter(k=>re.test(k))}catch{}matched.length===0&&(matched=[category]);for(let cat of matched){if(clear||typeof text==`string`&&text===``){delete messagesByCategory[cat];continue}let offset$2=Object.keys(messagesByCategory).length*timerIntervalMs*2;messagesByCategory[cat]={_key:cat,text,icon:icon||deriveIconForCategory(cat),ttl:ttlMs+offset$2}}}function onClearAll(){for(let k in messagesByCategory)delete messagesByCategory[k]}function tick(){for(let k in messagesByCategory){let m=messagesByCategory[k];bypassTtl.value||(m.ttl-=timerIntervalMs),m.ttl<=0&&delete messagesByCategory[k]}}return onMounted(()=>{events$3.on(`Message`,onMessage),events$3.on(`ClearAllMessages`,onClearAll),events$3.on(`MessagesDebug`,data=>{data&&typeof data.bypassTtl==`boolean`&&(bypassTtl.value=!!data.bypassTtl)}),timerId=window.setInterval(tick,timerIntervalMs)}),onUnmounted(()=>{timerId&&window.clearInterval(timerId)}),(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$133,[(openBlock(!0),createElementBlock(Fragment,null,renderList(messagesList.value,item=>(openBlock(),createElementBlock(`div`,{key:item._key,class:`message-row`},[__props.showIcons&&item.icon?(openBlock(),createElementBlock(`div`,_hoisted_2$112,[createVNode(unref(bngIcon_default),mergeProps({class:`msg-icon`,fallbackType:`info`},{ref_for:!0},getIconProps(item)),null,16)])):createCommentVNode(``,!0),createBaseVNode(`div`,_hoisted_3$100,[(openBlock(!0),createElementBlock(Fragment,null,renderList(getParts(item),(part,i)=>(openBlock(),createElementBlock(Fragment,{key:i},[part.t===`text`?(openBlock(),createElementBlock(`span`,_hoisted_4$80,toDisplayString(part.v),1)):(openBlock(),createBlock(unref(bngBinding_default),{key:1,action:part.action,"show-unassigned":``},null,8,[`action`]))],64))),128))])]))),128))]))}},app_default$32=__plugin_vue_export_helper_default(_sfc_main$149,[[`__scopeId`,`data-v-ddfd9832`]]),apps_exports=__export({advancedWheelsDebug:()=>app_default$2,brakeTorqueGraph:()=>app_default$3,busLine:()=>app_default$4,cameraDistance:()=>app_default$5,clutchThermalDebug:()=>app_default$6,compass:()=>app_default$7,compassPrecise:()=>app_default$8,countdown:()=>countdownApp_default,crashTestNextStep:()=>app_default$15,damageApp:()=>app_default$9,dragRace:()=>app_default$10,dragRaceStage:()=>app_default$12,dragRaceTree:()=>app_default$11,driftCurrentDrift:()=>app_default$13,driftScores:()=>app_default$14,engineDebug:()=>app_default$16,engineDynamometer:()=>app_default$17,engineHeatDebugGraph:()=>app_default$18,engineThermalDebug:()=>app_default$19,forcedInduction:()=>app_default$20,forcedInductionDebug:()=>app_default$21,gameplayApps:()=>gameplayApps_default,genericMissionData:()=>bngGenericMissionData_default,hydraulicsDebug:()=>app_default$22,inputHints:()=>app_default$29,keyList:()=>app_default$23,lapTimes:()=>app_default$31,lapTimesDebug:()=>appDebug_default$1,logvehiclestats:()=>app_default$24,messages:()=>app_default$32,messagesTasksApps:()=>messagesTasksApps_default,navigation:()=>app_default$30,pointsBar:()=>app_default,rallyCountdown:()=>appCountdown_default,rallyDashboard:()=>appDashboard_default,rallyDebug:()=>appDebug_default,rallyStageProgress:()=>appStageProgress_default,rallyStageTiming:()=>appStageTiming_default,rallyTimecard:()=>appTimecard_default,rallyVisualPacenotes:()=>app_default$28,replayAppV2:()=>app_default$1,simpleDigTacho:()=>app_default$25,simpleFlashMessage:()=>flashMessageApp_default,tacho2:()=>app_default$26,tasklist:()=>app_default$27});const useTuningStore=defineStore(`tuning`,()=>{let{lua,events:events$3}=useBridge(),buckets=ref({}),tuningVariables=ref({}),editedTuningVars={},isCareer=!1,shoppingData=ref({}),noapi=()=>{throw Error(`Tuning store must be initialised first`)},api$1={request:noapi,apply:noapi,reset:noapi,close:()=>{},menuClose:()=>{}};async function init$3(){for(let name in editedTuningVars={},isCareer=await lua.career_career.isActive(),isCareer?(api$1.request=async()=>processTuningData(await lua.career_modules_tuning.getTuningData()),api$1.apply=(values,edited)=>{let res={};for(let[varName,_]of Object.entries(edited))res[varName]=valDisToVal(values[varName]);lua.career_modules_tuning.apply(res)},api$1.reset=()=>{},api$1.close=()=>{events$3.off(`sendTuningShoppingData`,setShoppingData),events$3.off(`updateTuningVariable`,updateTuningVariable),shoppingData.value={}},events$3.on(`sendTuningShoppingData`,setShoppingData),events$3.on(`updateTuningVariable`,updateTuningVariable)):(api$1.request=async()=>await lua.extensions.core_vehicle_partmgmt.sendDataToUI(),api$1.apply=(values,edited)=>{let res={};for(let varName in values)res[varName]=valDisToVal(values[varName]);lua.extensions.core_vehicle_partmgmt.setConfigVars(res)},api$1.reset=async()=>await lua.extensions.core_vehicle_partmgmt.resetVarsToLoadedConfig(),api$1.close=()=>{events$3.off(`VehicleFocusChanged`,api$1.request),events$3.off(`VehicleConfigChange`,processTuningData)},api$1.menuClose=api$1.close,events$3.on(`VehicleFocusChanged`,api$1.request),events$3.on(`VehicleConfigChange`,processTuningData)),api$1)api$1[name]===noapi&&(api$1[name]=()=>{})}function apply$1(){api$1.apply(tuningVariables.value,editedTuningVars),editedTuningVars={}}function setShoppingData(data){shoppingData.value=data}function updateTuningVariable(tuningVar){tuningVariables.value[tuningVar.name].valDis=Number(valToValDis(tuningVar))}let processTuningData=data=>{data.variables&&(data=data.variables),isCareer&&(delete data.$fuel,delete data.$fuel_R,delete data.$fuel_L),buckets.value=[],tuningVariables.value={};for(let varData of Object.values(data)){if(isCareer&&varData.category===`Cargo`||varData.hideInUI)continue;varData.category||=`Other`,varData.subCategory||=`Other`;let cat=(buckets.value.find(cat$1=>cat$1.name===varData.category)||buckets.value[buckets.value.push({name:varData.category,items:[]})-1]).items;(cat.find(sub=>sub.name===varData.subCategory)||cat[cat.push({name:varData.subCategory,items:[]})-1]).items.push(varData),tuningVariables.value[varData.name]={valDis:Number(valToValDis(varData)),minDis:varData.minDis,maxDis:varData.maxDis,min:varData.min,max:varData.max,default:Number(valToValDis(varData,!0))}}let sorter=(a$1,b)=>a$1.name.localeCompare(b.name);buckets.value.sort(sorter);for(let cat of buckets.value){cat.items.sort(sorter);for(let sub of cat.items)sub.items.sort(sorter)}};function countDecimals(num){return typeof num!=`number`||~~num===num?0:num.toString().split(`.`)[1].length||0}function valToValDis(varData,useDef=!1){return roundDec(round(((useDef?varData.default:varData.val)-varData.min)/(varData.max-varData.min)*(varData.maxDis-varData.minDis),varData.stepDis)+varData.minDis,countDecimals(varData.stepDis))}function valDisToVal(varData){return(varData.valDis-varData.minDis)/(varData.maxDis-varData.minDis)*(varData.max-varData.min)+varData.min}function tuningVarChanged(varName){editedTuningVars[varName]=!0}return{init:init$3,buckets,tuningVariables,shoppingData,apply:apply$1,requestInitialData:()=>api$1.request(),close:()=>api$1.close(),notifyOnMenuClosed:()=>api$1.menuClose(),tuningVarChanged,resetTuningData:()=>api$1.reset()}});var _hoisted_1$132={key:0,class:`tuning-form`},_hoisted_2$111={key:0,class:`extra-features`},_hoisted_3$99={class:`category-heading`},_hoisted_4$79={class:`category-name`},_hoisted_5$68={key:0,class:`subcategory-heading`},_hoisted_6$54={class:`subcategory-name`},_hoisted_7$46={class:`variable-title`},_hoisted_8$38={class:`variable-box`},_hoisted_9$35={class:`tuning-static`},_hoisted_10$29={class:`buttons`},_sfc_main$148={__name:`Tuning`,props:{withBackground:Boolean,buttonTarget:{type:Object},closeButton:Boolean},setup(__props,{expose:__expose}){useUINavBlocker().blockOnly([`context`]);let{lua}=useBridge(),tuningStore=useTuningStore(),awdApp=ref(),awdShow=ref(!1),apply$1=()=>{tuningStore.apply()},close=()=>{tuningStore.close()},mirrorsShown=ref(!0),mirrorsEnabled=ref(!1),mirrorsRoute=`menu.vehicleconfig.tuning.mirrors`,toMirrors=()=>{window.bngVue.gotoGameState(mirrorsRoute)},inputs=ref([]),isChanged=computed(()=>inputs.value.some(ipt=>ipt.dirty));__expose({apply:apply$1,close});let autoApply=ref(!1),applyDebounce=debounce(apply$1,1e3);function onChange(varName){tuningStore.tuningVarChanged(varName),autoApply.value&&applyDebounce()}let applySettingChanged=val=>localStorage.setItem(`applyTuningChangesAutomatically`,JSON.stringify(val));watch(()=>tuningStore.buckets,()=>nextTick(()=>{for(let ipt of inputs.value)ipt.markClean()}));async function resetVarsToLoadedConfig(){tuningStore.resetTuningData(),await tuningStore.requestInitialData(),await nextTick();for(let ipt of inputs.value)ipt.markClean()}onBeforeMount(async()=>{let optAutoApply=localStorage.getItem(`applyTuningChangesAutomatically`);if(optAutoApply)try{autoApply.value=!!JSON.parse(optAutoApply)}catch{}await lua.extensions.gameplay_garageMode.isActive()&&(mirrorsRoute=`menu.vehicleconfig.tuning.mirrors.in-garage`),await lua.career_career.isActive()?mirrorsShown.value=!1:mirrorsEnabled.value=(await useSettingsAsync()).values.GraphicDynMirrorsEnabled,await tuningStore.init(),await tuningStore.requestInitialData(),getUINavServiceInstance().setFilteredEvents(UI_EVENT_GROUPS.focusMoveScalar)});let extraFeatures=computed(()=>{let features=[];return mirrorsEnabled.value&&features.push({mirrorsEnabled:!0}),features});return onUnmounted(async()=>{await tuningStore.notifyOnMenuClosed(),tuningStore.close(),tuningStore.$dispose(),getUINavServiceInstance().clearFilteredEvents()}),(_ctx,_cache)=>withDirectives((openBlock(),createElementBlock(`div`,{class:normalizeClass({innerTuningCard:!0,"with-background":__props.withBackground})},[unref(tuningStore).buckets?(openBlock(),createElementBlock(`div`,_hoisted_1$132,[extraFeatures.value.length>0?(openBlock(),createElementBlock(`div`,_hoisted_2$111,[withDirectives((openBlock(),createBlock(unref(bngButton_default),{onClick:toMirrors,accent:`secondary`},{default:withCtx(()=>[createTextVNode(toDisplayString(_ctx.$t(`ui.mirrors.name`)),1)]),_:1})),[[unref(BngDisabled_default),!extraFeatures.value.find(f=>f.mirrorsEnabled)]])])):createCommentVNode(``,!0),(openBlock(!0),createElementBlock(Fragment,null,renderList(unref(tuningStore).buckets,category=>(openBlock(),createElementBlock(`div`,{class:`tuning-category`,key:category.name},[createBaseVNode(`h2`,_hoisted_3$99,[createBaseVNode(`span`,_hoisted_4$79,toDisplayString(category.name),1)]),(openBlock(!0),createElementBlock(Fragment,null,renderList(category.items,subCategory=>(openBlock(),createElementBlock(`div`,{class:`tuning-subcategory`,key:subCategory.name},[subCategory.name===`Other`?createCommentVNode(``,!0):(openBlock(),createElementBlock(`h3`,_hoisted_5$68,[createBaseVNode(`span`,_hoisted_6$54,toDisplayString(subCategory.name),1)])),(openBlock(!0),createElementBlock(Fragment,null,renderList(subCategory.items,varData=>withDirectives((openBlock(),createElementBlock(`div`,{key:category.name+subCategory.name+varData.name,class:normalizeClass({"input-container":!0,"variable-box":varData.type===`slider`})},[createBaseVNode(`div`,_hoisted_7$46,toDisplayString(varData.title),1),createBaseVNode(`div`,_hoisted_8$38,[createVNode(unref(bngSlider_default),{ref_for:!0,ref_key:`inputs`,ref:inputs,min:varData.minDis,max:varData.maxDis,step:varData.stepDis,unit:varData.unit,class:normalizeClass({"property-slider":!0}),"with-input":``,"with-reset":``,"orig-value":unref(tuningStore).tuningVariables[varData.name].default,modelValue:unref(tuningStore).tuningVariables[varData.name].valDis,"onUpdate:modelValue":$event=>unref(tuningStore).tuningVariables[varData.name].valDis=$event,onValueChanged:$event=>onChange(varData.name)},null,8,[`min`,`max`,`step`,`unit`,`orig-value`,`modelValue`,`onUpdate:modelValue`,`onValueChanged`])])],2)),[[unref(BngTooltip_default),varData.description,`top`]])),128))]))),128))]))),128))])):createCommentVNode(``,!0),createBaseVNode(`div`,_hoisted_9$35,[withDirectives(createVNode(unref(app_default$2),{class:normalizeClass({"awd-app":awdApp.value}),ref_key:`awdApp`,ref:awdApp},null,8,[`class`]),[[vShow,awdShow.value]]),awdApp.value&&awdApp.value.hasData?(openBlock(),createBlock(unref(bngSwitch_default),{key:0,modelValue:awdShow.value,"onUpdate:modelValue":_cache[0]||=$event=>awdShow.value=$event},{default:withCtx(()=>[createTextVNode(toDisplayString(_ctx.$t(`ui.garage.tune.advWheel`)),1)]),_:1},8,[`modelValue`])):createCommentVNode(``,!0),createVNode(unref(bngSwitch_default),{modelValue:autoApply.value,"onUpdate:modelValue":_cache[1]||=$event=>autoApply.value=$event,onValueChanged:applySettingChanged},{default:withCtx(()=>[createTextVNode(toDisplayString(_ctx.$t(`ui.garage.liveUpdates`)),1)]),_:1},8,[`modelValue`]),createBaseVNode(`div`,_hoisted_10$29,[withDirectives(createVNode(unref(bngButton_default),{"show-hold":``,icon:unref(icons).undo,accent:unref(ACCENTS).custom,class:`reset-button`},null,8,[`icon`,`accent`]),[[unref(BngOnUiNav_default),void 0,`ok`,{asMouse:!0,focusRequired:!0}],[unref(BngClick_default),{holdCallback:resetVarsToLoadedConfig,holdDelay:1e3,repeatInterval:0}],[unref(BngTooltip_default),`Reset to original config`]]),createVNode(unref(bngButton_default),{disabled:autoApply.value||!isChanged.value,onClick:apply$1},{default:withCtx(()=>[createTextVNode(toDisplayString(_ctx.$t(`ui.common.apply`)),1)]),_:1},8,[`disabled`]),__props.closeButton?(openBlock(),createBlock(unref(bngButton_default),{key:0,onClick:close,accent:unref(ACCENTS).attention},{default:withCtx(()=>[createVNode(unref(bngBinding_default),{"ui-event":`back`,deviceMask:`xinput`}),createTextVNode(toDisplayString(_ctx.$t(`ui.common.close`)),1)]),_:1},8,[`accent`])):createCommentVNode(``,!0)])])],2)),[[unref(BngBlur_default),__props.withBackground]])}},Tuning_default=__plugin_vue_export_helper_default(_sfc_main$148,[[`__scopeId`,`data-v-907bf291`]]),CANCEL_MESSAGE=`Are you sure you want to cancel?
    All changes to your vehicle will be reversed`,_sfc_main$147={__name:`TuningMain`,setup(__props){useComputerStore();let tuningStore=useTuningStore(),CONFIRM_BUTTONS=[{label:$translate.instant(`ui.common.yes`),value:!0},{label:$translate.instant(`ui.common.no`),value:!1,extras:{accent:ACCENTS.secondary}}],confirmCancel=async()=>{(!(tuningStore.shoppingData.shoppingCart&&tuningStore.shoppingData.shoppingCart.items.length)||await openConfirmation(null,CANCEL_MESSAGE,CONFIRM_BUTTONS))&&cancelShopping()},cartData=computed(()=>{let cart=tuningStore.shoppingData?tuningStore.shoppingData.shoppingCart:null,res={total:0,taxes:0,items:[]};return cart&&(res.total=cart.total,res.taxes=cart.taxes,Array.isArray(cart.items)&&(res.items=cart.items.map(item=>({type:item.type||item.level===1&&`item`,level:item.level,name:item.title,price:item.price,priceHide:!item.price,removeShow:!!item.varName,remove:()=>Lua_default.career_modules_tuning.removeVarFromShoppingCart(item.varName)})))),res}),elCard=ref(),applyShopping=()=>Lua_default.career_modules_tuning.applyShopping(),cancelShopping=()=>Lua_default.career_modules_tuning.cancelShopping();return(_ctx,_cache)=>(openBlock(),createBlock(ComputerWrapper_default,{path:[`Tuning`],title:`Tuning`,back:``,onBack:confirmCancel},{side:withCtx(()=>[createVNode(ShoppingCart_default,{"cart-data":cartData.value,"player-money":unref(tuningStore).shoppingData.playerMoney,"confirm-button-text":`Confirm`,apply:applyShopping,cancel:confirmCancel},null,8,[`cart-data`,`player-money`])]),default:withCtx(()=>[withDirectives((openBlock(),createBlock(unref(bngCard_default),{class:`tuningCard`,ref_key:`elCard`,ref:elCard},{buttons:withCtx(()=>[..._cache[0]||=[]]),default:withCtx(()=>[createVNode(Tuning_default,{"button-target":elCard.value&&elCard.value.buttonsContainer,"close-button":!1},null,8,[`button-target`])]),_:1})),[[unref(BngBlur_default),1]])]),_:1}))}},TuningMain_default=__plugin_vue_export_helper_default(_sfc_main$147,[[`__scopeId`,`data-v-60311783`]]);const useVehicleInventoryStore=defineStore(`vehicleInventory`,()=>{let{events:events$3}=useBridge(),vehicleInventoryData=ref({}),vehIdToChooseAfterRepairPopup=ref(0),filteredVehicles=computed(()=>{let data=vehicleInventoryData.value;return data.vehicles?Object.values(data.vehicles):[]}),menuOpen=!1;function requestInitialData(){Lua_default.career_modules_inventory.sendDataToUi()}function closeMenu(){Lua_default.career_modules_inventory.closeMenu()}let getExpediteRepairCost=vehicle=>Math.max(vehicle.quickRepairExtraPrice*(vehicle.timeToAccess/vehicle.initialRepairTime),50);function countDownVehicleDelays(){if(menuOpen){for(let vehicle of filteredVehicles.value)vehicle.timeToAccess&&(--vehicle.timeToAccess,vehicle.delayReason==`repair`&&(vehicle.expediteRepairCost=getExpediteRepairCost(vehicle)),vehicle.timeToAccess<=0&&Lua_default.career_modules_inventory.sendDataToUi());setTimeout(countDownVehicleDelays,1e3)}}events$3.on(`vehicleInventoryData`,data=>{Object.values(data.vehicles).forEach(vehicle=>{data.currentVehicleId===vehicle.id&&(vehicle.niceName+=` (Current Vehicle)`),vehicle.owned||(vehicle.niceName+=` (Not owned)`)}),vehicleInventoryData.value=data,vehIdToChooseAfterRepairPopup.value=0,menuOpen||(menuOpen=!0,countDownVehicleDelays())});function menuClosed(){menuOpen=!1}function repairPopupAccept(){Lua_default.career_modules_inventory.chooseVehicleFromMenu(vehIdToChooseAfterRepairPopup.value,1,!0),vehIdToChooseAfterRepairPopup.value=0}function repairPopupDecline(){Lua_default.career_modules_inventory.chooseVehicleFromMenu(vehIdToChooseAfterRepairPopup.value,1,!1),vehIdToChooseAfterRepairPopup.value=0}function chooseVehicle(vehId,buttonIndex){let showRepairPopup=!1,data=vehicleInventoryData.value;if(data.currentVehicleId!==void 0&&vehId!==data.currentVehicleId&&(showRepairPopup=data.vehicles[data.currentVehicleId].needsRepair),showRepairPopup){vehIdToChooseAfterRepairPopup.value=vehId;return}Lua_default.career_modules_inventory.chooseVehicleFromMenu(vehId,buttonIndex+1,!1)}function dispose$2(){events$3.off(`vehicleInventoryData`)}return{filteredVehicles,vehIdToChooseAfterRepairPopup,vehicleInventoryData,requestInitialData,chooseVehicle,repairPopupAccept,repairPopupDecline,menuClosed,closeMenu,dispose:dispose$2}});var _hoisted_1$131={class:`list-vehicle-dialog`},_hoisted_2$110={class:`vehicle-info`},_hoisted_3$98={class:`name`},_hoisted_4$78={key:0,class:`meta`},_hoisted_5$67={key:1,class:`meta`},_hoisted_6$53={class:`price-box`},_hoisted_7$45={class:`price-content`},_hoisted_8$37={class:`price-row`},_hoisted_9$34={class:`step-buttons-group`},_hoisted_10$28={class:`price`},_hoisted_11$26={class:`step-buttons-group`},_sfc_main$146={__name:`ListVehicleDialog`,props:{modelValue:{type:Object,required:!0}},emits:[`update:modelValue`],setup(__props,{emit:__emit}){let props=__props,emit$1=__emit,{units}=useBridge(),formModel=computed({get:()=>props.modelValue,set:newValue=>emit$1(`update:modelValue`,newValue)});function adjustPrice(amount){let price=Math.max(0,Math.round(((formModel.value.price||0)+amount)/50)*50);emit$1(`update:modelValue`,{...formModel.value,price})}let priceHint=computed(()=>{let mv=Number(formModel.value.marketValue||0),p$1=Number(formModel.value.price||0);if(!mv||!p$1)return{text:``,class:``};let diff=(p$1-mv)/mv,percent=Math.round(Math.abs(diff)*100);return percent<1?{text:`Fair market value`,class:`ok`}:diff>0?{text:`${percent}% above market value`,class:`high`}:{text:`${percent}% below market value`,class:`low`}}),offerHint=computed(()=>{let mv=Number(formModel.value.marketValue||0),p$1=Number(formModel.value.price||0);if(!mv||!p$1)return{text:`Regular offers expected`,class:`regular`};let ratio=p$1/mv;return ratio<=.9?{text:`More offers expected`,class:`more`}:ratio>=1.2?{text:`Fewer offers expected`,class:`fewer`}:{text:`Regular offers expected`,class:`regular`}}),formModelText=computed(()=>formModel.value.odometerKm?new Intl.NumberFormat().format(Math.round(formModel.value.odometerKm))+` km`:``);return(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$131,[createBaseVNode(`div`,_hoisted_2$110,[createBaseVNode(`div`,_hoisted_3$98,toDisplayString(formModel.value.vehicleName),1),formModelText.value?(openBlock(),createElementBlock(`div`,_hoisted_4$78,toDisplayString(formModelText.value)+` — Market Value: `+toDisplayString(unref(units).beamBucks(formModel.value.marketValue||0)),1)):(openBlock(),createElementBlock(`div`,_hoisted_5$67,` Market Value: `+toDisplayString(unref(units).beamBucks(formModel.value.marketValue||0)),1))]),createBaseVNode(`div`,_hoisted_6$53,[createBaseVNode(`div`,_hoisted_7$45,[_cache[12]||=createBaseVNode(`div`,{class:`label`},`Your Asking Price`,-1),createBaseVNode(`div`,_hoisted_8$37,[createBaseVNode(`div`,_hoisted_9$34,[createVNode(unref(bngButton_default),{class:`step step-large`,accent:unref(ACCENTS).secondary,onClick:_cache[0]||=$event=>adjustPrice(-5e3)},{default:withCtx(()=>[..._cache[6]||=[createTextVNode(`-5000`,-1)]]),_:1},8,[`accent`]),createVNode(unref(bngButton_default),{class:`step step-medium`,accent:unref(ACCENTS).secondary,onClick:_cache[1]||=$event=>adjustPrice(-500)},{default:withCtx(()=>[..._cache[7]||=[createTextVNode(`-500`,-1)]]),_:1},8,[`accent`]),createVNode(unref(bngButton_default),{class:`step`,accent:unref(ACCENTS).secondary,onClick:_cache[2]||=$event=>adjustPrice(-50)},{default:withCtx(()=>[..._cache[8]||=[createTextVNode(`-50`,-1)]]),_:1},8,[`accent`])]),createBaseVNode(`div`,_hoisted_10$28,toDisplayString(unref(units).beamBucks(formModel.value.price||0)),1),createBaseVNode(`div`,_hoisted_11$26,[createVNode(unref(bngButton_default),{class:`step`,accent:unref(ACCENTS).secondary,onClick:_cache[3]||=$event=>adjustPrice(50)},{default:withCtx(()=>[..._cache[9]||=[createTextVNode(`+50`,-1)]]),_:1},8,[`accent`]),createVNode(unref(bngButton_default),{class:`step step-medium`,accent:unref(ACCENTS).secondary,onClick:_cache[4]||=$event=>adjustPrice(500)},{default:withCtx(()=>[..._cache[10]||=[createTextVNode(`+500`,-1)]]),_:1},8,[`accent`]),createVNode(unref(bngButton_default),{class:`step step-large`,accent:unref(ACCENTS).secondary,onClick:_cache[5]||=$event=>adjustPrice(5e3)},{default:withCtx(()=>[..._cache[11]||=[createTextVNode(`+5000`,-1)]]),_:1},8,[`accent`])])]),createBaseVNode(`div`,{class:normalizeClass([`hint`,[priceHint.value.class]])},toDisplayString(priceHint.value.text),3),createBaseVNode(`div`,{class:normalizeClass([`offer-hint`,[offerHint.value.class]])},toDisplayString(offerHint.value.text),3)])])]))}},ListVehicleDialog_default=__plugin_vue_export_helper_default(_sfc_main$146,[[`__scopeId`,`data-v-87a25af5`]]),_hoisted_1$130={class:`vehicle-list-container`},_sfc_main$145={__name:`VehicleList`,setup(__props){let{units}=useBridge(),{$game}=useLibStore(),popover=usePopover(),popId=uniqueId(`veh_options`),popHide=()=>popover.hide(popId),licensePlateTextValid=ref(!0),vehicleNameValid=ref(!0),vehicleInventoryStore=useVehicleInventoryStore(),selectedVehId=ref(),vehSelected=computed(()=>{if(typeof selectedVehId.value==`number`)return listView.value.find(v=>v.id===selectedVehId.value)}),careerStatusData=ref({}),updateCareerStatusData=()=>Lua_default.career_modules_uiUtils.getCareerStatusData().then(data=>careerStatusData.value=data),cantPayLicensePlate=computed(()=>!careerStatusData.value.money||300>careerStatusData.value.money),listStatus=computed(()=>vehicleInventoryStore?!Array.isArray(vehicleInventoryStore.filteredVehicles)||vehicleInventoryStore.filteredVehicles.length===0?`You don't currently own any vehicles`:null:`Please wait...`),listView=computed(()=>{if(!vehicleInventoryStore||!Array.isArray(vehicleInventoryStore.filteredVehicles)||vehicleInventoryStore.filteredVehicles.length===0)return[];let res=vehicleInventoryStore.filteredVehicles;if(singleFunction.value)for(let veh of res)veh.disabled=!isFunctionAvailable(veh,singleFunction.value);return res.sort((a$1,b)=>a$1.favorite?-1:b.favorite?1:a$1.niceName.localeCompare(b.niceName)),res}),itemLayout=ref({TILE:`tile`,LIST:`row`}.TILE),singleFunction=computed(()=>{if(!vehicleInventoryStore||!vehicleInventoryStore.vehicleInventoryData)return null;let data=vehicleInventoryStore.vehicleInventoryData;return Object.values(data.buttonsActive).includes(!0)||!Array.isArray(data.chooseButtonsData)||data.chooseButtonsData.length!==1?null:data.chooseButtonsData[0]});function select(vehicle,evt){let show=vehicleInventoryStore&&vehicleInventoryStore.vehicleInventoryData&&(Object.values(vehicleInventoryStore.vehicleInventoryData.buttonsActive).includes(!0)||vehicleInventoryStore.vehicleInventoryData.chooseButtonsData.length>0)&&vehicle&&(!vehSelected.value||vehSelected.value.id!==vehicle.id),popover$1;if(evt&&evt.target){let cur=evt.target;for(;popover$1=cur.__popover,!(popover$1||(cur=cur.parentNode,cur===document.body)););}if(vehicle&&singleFunction.value){selectedVehId.value=null,popover$1&&popover$1.hide(),vehicleInventoryStore.chooseVehicle(vehicle.id,0);return}show&&popover$1&&popover$1.hide(),nextTick(()=>{show?(selectedVehId.value=vehicle.id,popover$1&&popover$1.show()):(popover$1&&popover$1.hide(),selectedVehId.value=null)})}let isFunctionAvailable=(vehicle,buttonData)=>!(vehicle.timeToAccess||vehicle.missingFile||buttonData.requiredVehicleNotInGarage&&vehicle.inGarage||buttonData.requiredOtherVehicleInGarage&&!vehicle.otherVehicleInGarage||buttonData.ownedRequired&&!vehicle.owned||buttonData.repairRequired&&vehicle.needsRepair||buttonData.notForSaleRequired&&vehicle.listedForSale),lookAtVehicleListing=()=>{Lua_default.career_modules_marketplace.openMenu(vehicleInventoryStore.vehicleInventoryData.originComputerId)},confirmReturnVehicle=async()=>{let vehicle=vehSelected.value;popHide(),await openConfirmation(``,`Do you want to return this loaned vehicle to the owner?`,[{label:$translate.instant(`ui.common.yes`),value:!0,extras:{default:!0}},{label:$translate.instant(`ui.common.no`),value:!1,extras:{accent:ACCENTS.secondary}}])&&Lua_default.career_modules_inventory.returnLoanedVehicleFromInventory(vehicle.id)},personalizeLicensePlate=async()=>{let vehicle=vehSelected.value;popHide(),updateCareerStatusData();let res=await openPrompt(`Enter your new license plate text:`,`Personalize License Plate`,{maxLength:10,defaultValue:vehicle.config.licenseName,buttons:[{label:$translate.instant(`ui.common.cancel`),value:!1,extras:{cancel:!0,accent:ACCENTS.secondary}},{label:$translate.instant(`ui.common.okay`)+` (Cost: ${units.beamBucks(300)})`,value:text=>text,extras:{disabled:cantPayLicensePlate,accent:ACCENTS.primary}}],validate:text=>(Lua_default.career_modules_inventory.isLicensePlateValid(text).then(valid=>{licensePlateTextValid.value=valid}),licensePlateTextValid.value),errorMessage:`Invalid character in license plate text`,disableWhenInvalid:!0});res!=0&&(Lua_default.career_modules_inventory.purchaseLicensePlateText(vehicle.id,res,300),vehicle.config.licenseName=res)},confirmExpediteRepair=async()=>{let vehicle=vehSelected.value;popHide();let price=vehicle.expediteRepairCost;await openConfirmation(``,`Do you want to expedite the repair for ${units.beamBucks(price)}?`,[{label:$translate.instant(`ui.common.yes`),value:!0,extras:{default:!0}},{label:$translate.instant(`ui.common.no`),value:!1,extras:{accent:ACCENTS.secondary}}])&&Lua_default.career_modules_inventory.expediteRepairFromInventory(vehicle.id,price)},openRepairMenu=()=>{let vehicle=vehSelected.value;popHide(),Lua_default.career_modules_insurance_repairScreen.openRepairMenu(vehicle,vehicleInventoryStore.vehicleInventoryData.originComputerId)},setFavoriteVehicle=()=>{let vehicle=vehSelected.value;popHide(),Lua_default.career_modules_inventory.setFavoriteVehicle(vehicle.id),Lua_default.career_modules_inventory.sendDataToUi()},storeVehicle=()=>{let vehicle=vehSelected.value;popHide(),Lua_default.career_modules_inventory.removeVehicleObject(vehicle.id),Lua_default.career_modules_inventory.sendDataToUi()},renameVehicle=async()=>{let vehicle=vehSelected.value;popHide();let res=await openPrompt(`Enter new vehicle name:`,`Rename Vehicle`,{maxLength:30,defaultValue:vehicle.niceName,buttons:[{label:$translate.instant(`ui.common.cancel`),value:!1,extras:{cancel:!0,accent:ACCENTS.secondary}},{label:$translate.instant(`ui.common.okay`),value:text=>text,extras:{accent:ACCENTS.primary}}],validate:text=>(Lua_default.career_modules_inventory.isVehicleNameValid(text).then(valid=>{vehicleNameValid.value=valid}),vehicleNameValid.value),errorMessage:`Invalid characters in vehicle name`,disableWhenInvalid:!0});res!=0&&(Lua_default.career_modules_inventory.renameVehicle(vehicle.id,res),vehicle.niceName=res)},listVehicleForSale=async vehicle=>{popHide();let res=await openFormDialog(ListVehicleDialog_default,{vehicleName:vehicle.niceName,odometer:vehicle.odometer,marketValue:vehicle.value,price:Math.max(50,Math.round((vehicle.value||0)/50)*50)},model=>!Number.isFinite(model.price)||model.price<=0?{error:!0,message:`Enter a valid positive price`}:{error:!1},`List a Vehicle for Sale`,void 0,void 0,`90rem`);!res||!res.value||await Lua_default.career_modules_marketplace.listVehicles([{inventoryId:vehicle.id,value:res.formData.price}])},listVehicleForSaleFromContextMenu=async()=>{let vehicle=vehSelected.value;await listVehicleForSale(vehicle),Lua_default.career_modules_marketplace.openMenu(vehicleInventoryStore.vehicleInventoryData.originComputerId)},listVehicleForSaleFromMarketplaceMenu=async vehicle=>{await listVehicleForSale(vehicle),router_default.back()};return $game.events.on(`addListing`,data=>{listVehicleForSaleFromMarketplaceMenu(listView.value.find(v=>v.id===data.inventoryId))}),onUnmounted(()=>{$game.events.off(`addListing`)}),(_ctx,_cache)=>withDirectives((openBlock(),createElementBlock(`div`,_hoisted_1$130,[listStatus.value?withDirectives((openBlock(),createBlock(VehicleTileRow_default,{key:0,class:`vehicle-list-item`,data:{_message:listStatus.value},layout:itemLayout.value},null,8,[`data`,`layout`])),[[unref(BngDisabled_default)]]):(openBlock(!0),createElementBlock(Fragment,{key:1},renderList(listView.value,vehicle=>withDirectives((openBlock(),createBlock(VehicleTileRow_default,{class:`vehicle-list-item`,key:vehicle.id,data:vehicle,layout:itemLayout.value,selected:vehSelected.value&&vehSelected.value.id===vehicle.id,"is-tutorial":unref(vehicleInventoryStore)&&unref(vehicleInventoryStore).vehicleInventoryData.tutorialActive,money:unref(vehicleInventoryStore)?unref(vehicleInventoryStore).vehicleInventoryData.playerMoney:0,tabindex:`0`,"bng-nav-item":``,onClick:$event=>!vehicle.disabled&&select(vehicle,$event)},null,8,[`data`,`layout`,`selected`,`is-tutorial`,`money`,`onClick`])),[[unref(BngDisabled_default),vehicle.disabled],[unref(BngOnUiNav_default),void 0,`ok`,{asMouse:!0,focusRequired:!0}],[unref(BngPopover_default),unref(popId),`right-start`,{click:!0}]])),128)),createVNode(unref(bngPopoverMenu_default),{name:unref(popId),focus:``,onHide:_cache[9]||=$event=>selectedVehId.value=null},{default:withCtx(()=>[(openBlock(!0),createElementBlock(Fragment,null,renderList(unref(vehicleInventoryStore).vehicleInventoryData.chooseButtonsData,(buttonData,index)=>(openBlock(),createElementBlock(Fragment,{key:index},[buttonData.repairRequired&&vehSelected.value&&vehSelected.value.needsRepair&&!unref(vehicleInventoryStore).vehicleInventoryData.tutorialActive?(openBlock(),createBlock(unref(bngButton_default),{key:0,accent:unref(ACCENTS).menu,disabled:``},{default:withCtx(()=>[createTextVNode(toDisplayString(buttonData.buttonText)+` (Needs repair) `,1)]),_:2},1032,[`accent`])):vehSelected.value&&isFunctionAvailable(vehSelected.value,buttonData)?withDirectives((openBlock(),createBlock(unref(bngButton_default),{key:1,accent:unref(ACCENTS).menu,onClick:$event=>unref(vehicleInventoryStore).chooseVehicle(vehSelected.value.id,index)},{default:withCtx(()=>[createTextVNode(toDisplayString(buttonData.buttonText),1)]),_:2},1032,[`accent`,`onClick`])),[[unref(BngOnUiNav_default),void 0,`ok`,{focusRequired:!0,asMouse:!0}]]):createCommentVNode(``,!0)],64))),128)),vehSelected.value&&unref(vehicleInventoryStore).vehicleInventoryData.buttonsActive.returnLoanerEnabled&&vehSelected.value.returnLoanerPermission.allow?withDirectives((openBlock(),createBlock(unref(bngButton_default),{key:0,accent:unref(ACCENTS).menu,onClick:_cache[0]||=$event=>confirmReturnVehicle()},{default:withCtx(()=>[..._cache[10]||=[createTextVNode(` Return loaned vehicle `,-1)]]),_:1},8,[`accent`])),[[unref(BngOnUiNav_default),void 0,`ok`,{focusRequired:!0,asMouse:!0}]]):createCommentVNode(``,!0),vehSelected.value&&vehSelected.value.delayReason===`repair`?withDirectives((openBlock(),createBlock(unref(bngButton_default),{key:1,accent:unref(ACCENTS).menu,disabled:vehSelected.value.expediteRepairCost>unref(vehicleInventoryStore).vehicleInventoryData.playerMoney,onClick:_cache[1]||=$event=>confirmExpediteRepair(vehSelected.value)},{default:withCtx(()=>[_cache[11]||=createTextVNode(` Expedite Repair `,-1),createVNode(unref(bngUnit_default),{money:vehSelected.value.expediteRepairCost},null,8,[`money`])]),_:1},8,[`accent`,`disabled`])),[[unref(BngOnUiNav_default),void 0,`ok`,{focusRequired:!0,asMouse:!0}]]):createCommentVNode(``,!0),vehSelected.value&&vehSelected.value.delayReason!==`repair`&&unref(vehicleInventoryStore).vehicleInventoryData.buttonsActive.repairEnabled?withDirectives((openBlock(),createBlock(unref(bngButton_default),{key:2,accent:unref(ACCENTS).menu,disabled:!vehSelected.value.repairPermission.allow,onClick:_cache[2]||=$event=>openRepairMenu()},{default:withCtx(()=>[..._cache[12]||=[createTextVNode(` Repair `,-1)]]),_:1},8,[`accent`,`disabled`])),[[unref(BngOnUiNav_default),void 0,`ok`,{focusRequired:!0,asMouse:!0}]]):createCommentVNode(``,!0),vehSelected.value&&unref(vehicleInventoryStore).vehicleInventoryData.buttonsActive.storingEnabled&&!vehSelected.value.inStorage?withDirectives((openBlock(),createBlock(unref(bngButton_default),{key:3,accent:unref(ACCENTS).menu,disabled:!vehSelected.value.storePermission.allow,onClick:_cache[3]||=$event=>storeVehicle()},{default:withCtx(()=>[..._cache[13]||=[createTextVNode(` Put in storage `,-1)]]),_:1},8,[`accent`,`disabled`])),[[unref(BngOnUiNav_default),void 0,`ok`,{focusRequired:!0,asMouse:!0}]]):createCommentVNode(``,!0),vehSelected.value&&unref(vehicleInventoryStore).vehicleInventoryData.buttonsActive.favoriteEnabled?withDirectives((openBlock(),createBlock(unref(bngButton_default),{key:4,accent:unref(ACCENTS).menu,disabled:!vehSelected.value.favoritePermission.allow||vehSelected.value.favorite,onClick:_cache[4]||=$event=>setFavoriteVehicle()},{default:withCtx(()=>[..._cache[14]||=[createTextVNode(` Set as Favorite `,-1)]]),_:1},8,[`accent`,`disabled`])),[[unref(BngOnUiNav_default),void 0,`ok`,{focusRequired:!0,asMouse:!0}]]):createCommentVNode(``,!0),vehSelected.value?withDirectives((openBlock(),createBlock(unref(bngButton_default),{key:5,accent:unref(ACCENTS).menu,disabled:!vehSelected.value.licensePlateChangePermission.allow,onClick:_cache[5]||=$event=>personalizeLicensePlate(vehSelected.value)},{default:withCtx(()=>[..._cache[15]||=[createTextVNode(` Personalize license plate `,-1)]]),_:1},8,[`accent`,`disabled`])),[[unref(BngOnUiNav_default),void 0,`ok`,{focusRequired:!0,asMouse:!0}]]):createCommentVNode(``,!0),vehSelected.value?withDirectives((openBlock(),createBlock(unref(bngButton_default),{key:6,accent:unref(ACCENTS).menu,onClick:_cache[6]||=$event=>renameVehicle()},{default:withCtx(()=>[..._cache[16]||=[createTextVNode(` Rename vehicle `,-1)]]),_:1},8,[`accent`])),[[unref(BngOnUiNav_default),void 0,`ok`,{focusRequired:!0,asMouse:!0}]]):createCommentVNode(``,!0),vehSelected.value&&unref(vehicleInventoryStore).vehicleInventoryData.buttonsActive.sellEnabled&&!vehSelected.value.listedForSale?withDirectives((openBlock(),createBlock(unref(bngButton_default),{key:7,accent:unref(ACCENTS).menu,disabled:!vehSelected.value.sellPermission.allow,onClick:_cache[7]||=$event=>listVehicleForSaleFromContextMenu()},{default:withCtx(()=>[..._cache[17]||=[createTextVNode(` List vehicle for sale `,-1)]]),_:1},8,[`accent`,`disabled`])),[[unref(BngOnUiNav_default),void 0,`ok`,{focusRequired:!0,asMouse:!0}]]):createCommentVNode(``,!0),vehSelected.value&&unref(vehicleInventoryStore).vehicleInventoryData.buttonsActive.sellEnabled&&vehSelected.value.listedForSale?withDirectives((openBlock(),createBlock(unref(bngButton_default),{key:8,accent:unref(ACCENTS).menu,disabled:!vehSelected.value.sellPermission.allow,onClick:_cache[8]||=$event=>lookAtVehicleListing()},{default:withCtx(()=>[..._cache[18]||=[createTextVNode(` Go to vehicle listing `,-1)]]),_:1},8,[`accent`,`disabled`])),[[unref(BngOnUiNav_default),void 0,`ok`,{focusRequired:!0,asMouse:!0}]]):createCommentVNode(``,!0)]),_:1},8,[`name`])])),[[unref(BngDisabled_default),!unref(vehicleInventoryStore)]])}},VehicleList_default$1=__plugin_vue_export_helper_default(_sfc_main$145,[[`__scopeId`,`data-v-5a84a046`]]),_sfc_main$144=Object.assign({inheritAttrs:!1},{__name:`VehicleInventory`,setup(__props,{expose:__expose}){let vehicleInventoryStore=useVehicleInventoryStore(),attrs=useAttrs();return __expose({closeMenu:vehicleInventoryStore.closeMenu}),onBeforeMount(()=>{vehicleInventoryStore.requestInitialData()}),onUnmounted(()=>{Lua_default.extensions.hook(`onExitVehicleInventory`),vehicleInventoryStore.menuClosed(),vehicleInventoryStore.$dispose()}),(_ctx,_cache)=>(openBlock(),createBlock(VehicleList_default$1,normalizeProps(guardReactiveProps(unref(attrs))),null,16))}}),VehicleInventory_default=_sfc_main$144,_sfc_main$143={__name:`VehicleInventoryMain`,setup(__props){let vehicleInventoryStore=useVehicleInventoryStore(),router$1=useRouter(),title=computed(()=>vehicleInventoryStore.vehicleInventoryData.header||`My vehicles`);watch(()=>vehicleInventoryStore.vehIdToChooseAfterRepairPopup,(newId,oldId)=>{!oldId&&newId&&confirmRepair()});let confirmRepair=async vehicle=>{await openConfirmation(``,`Do you want to repair your previous vehicle?`,[{label:$translate.instant(`ui.common.yes`),value:!0,extras:{default:!0}},{label:$translate.instant(`ui.common.no`),value:!1,extras:{accent:ACCENTS.secondary}}])?vehicleInventoryStore.repairPopupAccept():vehicleInventoryStore.repairPopupDecline()},elInventory=ref(),close=()=>router$1.back();return onUnmounted(()=>{vehicleInventoryStore.$dispose()}),(_ctx,_cache)=>(openBlock(),createBlock(ComputerWrapper_default,{ref:`wrapper`,title:title.value,back:``,onBack:close},{default:withCtx(()=>[createVNode(VehicleInventory_default,{ref_key:`elInventory`,ref:elInventory,class:`vehicle-inventory`},null,512)]),_:1},8,[`title`]))}},VehicleInventoryMain_default=__plugin_vue_export_helper_default(_sfc_main$143,[[`__scopeId`,`data-v-88176408`]]);const useVehiclePurchaseStore=defineStore(`vehiclePurchase`,()=>{let{events:events$3}=useBridge(),purchaseType=ref(``),vehicleInfo=ref({}),playerMoney=ref(0),alreadyDidTestDrive=ref(!1),inventoryHasFreeSlot=ref(!1),tradeInVehicleInfo=ref({}),tradeInEnabled=ref(!1),forceTradeIn=ref(!1),locationSelectionEnabled=ref(!1),forceNoDelivery=ref(!1),makeDelivery=ref(!1),buyCustomLicensePlate=ref(!1),customLicensePlateText=ref(``),prices=ref({}),insuranceOptions=ref({}),finalPackagePrice=computed(()=>{let price=prices.value.finalPrice;return buyCustomLicensePlate.value&&(price+=prices.value.customLicensePlate),insuranceOptions.value.insuranceId>0&&(price+=insuranceOptions.value.priceMoney),price}),handlePurchaseData=data=>{vehicleInfo.value=data.vehicleInfo,playerMoney.value=data.playerMoney,inventoryHasFreeSlot.value=data.inventoryHasFreeSlot,purchaseType.value=data.purchaseType,tradeInEnabled.value=data.tradeInEnabled,locationSelectionEnabled.value=data.locationSelectionEnabled,forceNoDelivery.value=data.forceNoDelivery,prices.value=data.prices,makeDelivery.value=!1,buyCustomLicensePlate.value=!1,customLicensePlateText.value=``,alreadyDidTestDrive.value=data.alreadyDidTestDrive,forceTradeIn.value=data.forceTradeIn,insuranceOptions.value=data.insuranceOptions,data.tradeInVehicleInfo===void 0?tradeInVehicleInfo.value={}:tradeInVehicleInfo.value=data.tradeInVehicleInfo};function requestPurchaseData(){Lua_default.career_modules_vehicleShopping.sendPurchaseDataToUi()}function buyVehicle(makeDelivery$1){let options={makeDelivery:makeDelivery$1,insuranceId:insuranceOptions.value.insuranceId};buyCustomLicensePlate.value&&(options.licensePlateText=customLicensePlateText.value),Lua_default.career_modules_vehicleShopping.buyFromPurchaseMenu(purchaseType.value,options)}function inventoryIsEmpty(){return Lua_default.career_modules_inventory.isEmpty()}function chooseTradeInVehicle(){Lua_default.career_modules_vehicleShopping.openInventoryMenuForTradeIn()}function removeTradeInVehicle(){Lua_default.career_modules_vehicleShopping.removeTradeInVehicle()}function cancel(){Lua_default.career_modules_vehicleShopping.cancelPurchase(purchaseType.value)}function startTestDrive(){Lua_default.career_modules_inspectVehicle.startTestDrive()}function dispose$2(){listen(!1)}let listen=state=>{events$3[state?`on`:`off`](`vehiclePurchaseData`,handlePurchaseData)};return listen(!0),{buyVehicle,cancel,chooseTradeInVehicle,purchaseType,startTestDrive,dispose:dispose$2,forceNoDelivery,forceTradeIn,inventoryIsEmpty,inventoryHasFreeSlot,locationSelectionEnabled,makeDelivery,playerMoney,prices,finalPackagePrice,removeTradeInVehicle,requestPurchaseData,tradeInEnabled,tradeInVehicleInfo,vehicleInfo,buyCustomLicensePlate,customLicensePlateText,alreadyDidTestDrive,insuranceOptions}});var _hoisted_1$129={class:`header-row`},_hoisted_2$109={class:`header-seller-info`},_hoisted_3$97={class:`purchase-list`},_hoisted_4$77={class:`purchase-row`},_hoisted_5$66={class:`label`},_hoisted_6$52={class:`sub-info`},_hoisted_7$44={class:`price`},_hoisted_8$36={class:`current-price-line`},_hoisted_9$33={key:0,class:`old-price`},_hoisted_10$27={class:`sub-info`},_hoisted_11$25={key:0,class:`purchase-row thin light-blue`},_hoisted_12$20={class:`label category`},_hoisted_13$18={class:`price category`},_hoisted_14$18={class:`purchase-row thin light-blue`},_hoisted_15$18={class:`price`},_hoisted_16$18={key:1,class:`purchase-divider`},_hoisted_17$14={key:2,class:`purchase-row thin green`},_hoisted_18$12={class:`label`},_hoisted_19$9={class:`price`},_hoisted_20$8={class:`purchase-row`},_hoisted_21$8={class:`price`},_hoisted_22$7={class:`purchase-row thin yellow`},_hoisted_23$6={class:`price`},_hoisted_24$5={key:3,class:`purchase-row thin`},_hoisted_25$4={class:`price`},_hoisted_26$3={class:`purchase-row`},_hoisted_27$3={class:`price highlight-category`},_hoisted_28$2={key:4,class:`purchase-row money-warning red`},_hoisted_29$2={class:`label`},_hoisted_30$2={class:`price`},_hoisted_31$2={class:`purchase-customization-group`},_hoisted_32$2={class:`button-group`},_hoisted_33$2={key:0},_hoisted_34$2={key:1},_hoisted_35$1={key:2},_hoisted_36$1={class:`right-side`},_sfc_main$142={__name:`VehiclePurchaseMain`,setup(__props){useUINavScope(`vehiclePurchase`);let{showIfController}=storeToRefs(controls_default()),{units}=useBridge(),router$1=useRouter(),hasVehicle=ref(!1),licensePlateTextValid=ref(!0),vehiclePurchaseStore=useVehiclePurchaseStore(),store$1=useTasksStore(),tradeInButtonMessage=computed(()=>vehiclePurchaseStore.tradeInEnabled?hasVehicle.value?void 0:`You don't own any vehicles`:`Trade in only possible in person at a dealership`),testDriveButtonMessage=computed(()=>{if(vehiclePurchaseStore.purchaseType!==`inspect`)return`Test drive only available for inspect purchases`;if(vehiclePurchaseStore.alreadyDidTestDrive)return`You have already done a test drive`}),vehicleFitsInventory=computed(()=>vehiclePurchaseStore.vehicleInfo.takesNoInventorySpace?!0:vehiclePurchaseStore.inventoryHasFreeSlot||vehiclePurchaseStore.tradeInVehicleInfo.niceName&&!vehiclePurchaseStore.tradeInVehicleInfo.takesNoInventorySpace);vehiclePurchaseStore.inventoryIsEmpty().then(empty=>{hasVehicle.value=!empty});let buy=()=>buyVehicle(!vehiclePurchaseStore.locationSelectionEnabled||vehiclePurchaseStore.makeDelivery),cancel=()=>{router$1.back()},startTestDrive=()=>{vehiclePurchaseStore.startTestDrive()},chooseTradeInVehicle=()=>{vehiclePurchaseStore.chooseTradeInVehicle()},chooseInsurance=()=>{addPopup(ChooseInsuranceMain_default,{menuMode:`purchase`,params:{purchaseType:vehiclePurchaseStore.purchaseType,shopId:vehiclePurchaseStore.vehicleInfo.shopId,insuranceId:vehiclePurchaseStore.insuranceOptions.insuranceId}})},negotiatePrice=()=>{Lua_default.career_modules_marketplace.startNegotiateSellingOffer(vehiclePurchaseStore.vehicleInfo.shopId)},removeTradeInVehicle=()=>{vehiclePurchaseStore.removeTradeInVehicle()},buyVehicle=_makeDelivery=>{vehiclePurchaseStore.buyVehicle(_makeDelivery)};return onMounted(()=>{vehiclePurchaseStore.requestPurchaseData()}),onUnmounted(async()=>{await Lua_default.career_modules_inspectVehicle.onPurchaseMenuClosed(),vehiclePurchaseStore.$dispose()}),(_ctx,_cache)=>(openBlock(),createBlock(unref(layoutSingle_default),{class:`purchase-layout`},{default:withCtx(()=>[unref(vehiclePurchaseStore).vehicleInfo.niceName?withDirectives((openBlock(),createBlock(unref(bngCard_default),{key:0,"bng-ui-scope":`vehiclePurchase`,class:`purchase-screen`},{buttons:withCtx(()=>[createBaseVNode(`div`,_hoisted_32$2,[withDirectives((openBlock(),createBlock(unref(bngButton_default),{disabled:unref(vehiclePurchaseStore).purchaseType!==`inspect`||unref(vehiclePurchaseStore).alreadyDidTestDrive,onClick:startTestDrive,accent:unref(ACCENTS).secondary},{default:withCtx(()=>[..._cache[16]||=[createTextVNode(`Test Drive`,-1)]]),_:1},8,[`disabled`,`accent`])),[[unref(BngTooltip_default),testDriveButtonMessage.value,`top`]]),withDirectives((openBlock(),createBlock(unref(bngButton_default),{disabled:unref(vehiclePurchaseStore).finalPackagePrice>unref(vehiclePurchaseStore).playerMoney||!vehicleFitsInventory.value||unref(vehiclePurchaseStore).forceTradeIn&&!unref(vehiclePurchaseStore).tradeInVehicleInfo.niceName||unref(vehiclePurchaseStore).buyCustomLicensePlate&&!licensePlateTextValid.value,"show-hold":``},{default:withCtx(()=>[unref(vehiclePurchaseStore).finalPackagePrice>unref(vehiclePurchaseStore).playerMoney?(openBlock(),createElementBlock(`div`,_hoisted_33$2,`Insufficient Funds`)):vehicleFitsInventory.value?(openBlock(),createElementBlock(`div`,_hoisted_35$1,`Purchase`)):(openBlock(),createElementBlock(`div`,_hoisted_34$2,`No free inventory slots`))]),_:1},8,[`disabled`])),[[unref(BngOnUiNav_default),void 0,`ok`,{asMouse:!0,focusRequired:!0}],[unref(BngClick_default),{holdCallback:buy,holdDelay:1e3,repeatInterval:0}]])])]),default:withCtx(()=>[createBaseVNode(`div`,_hoisted_1$129,[createVNode(unref(bngCardHeading_default),{type:`ribbon`},{default:withCtx(()=>[_cache[0]||=createTextVNode(` Purchase Information `,-1),createBaseVNode(`div`,_hoisted_2$109,` Purchasing from: `+toDisplayString(unref(vehiclePurchaseStore).vehicleInfo.sellerName),1)]),_:1}),createVNode(unref(bngButton_default),{class:`close-button`,onClick:cancel,accent:unref(ACCENTS).attention,"bng-no-nav":`true`,tabindex:`-1`},{default:withCtx(()=>[createVNode(unref(bngBinding_default),{"ui-event":`menu`,controller:``}),createVNode(unref(bngIcon_default),{type:`xmarkBold`,color:`var(--bng-cool-gray-100)`})]),_:1},8,[`accent`])]),createBaseVNode(`div`,_hoisted_3$97,[createBaseVNode(`div`,_hoisted_4$77,[createBaseVNode(`div`,_hoisted_5$66,[createBaseVNode(`div`,null,toDisplayString(unref(vehiclePurchaseStore).vehicleInfo.year)+` `+toDisplayString(unref(vehiclePurchaseStore).vehicleInfo.niceName),1),createBaseVNode(`div`,_hoisted_6$52,`(`+toDisplayString(unref(units).buildString(`length`,unref(vehiclePurchaseStore).vehicleInfo.Mileage,0))+`)`,1)]),createBaseVNode(`div`,_hoisted_7$44,[createBaseVNode(`div`,_hoisted_8$36,[unref(vehiclePurchaseStore).vehicleInfo.originalSellValue?(openBlock(),createElementBlock(`span`,_hoisted_9$33,[createVNode(unref(bngUnit_default),{money:unref(vehiclePurchaseStore).vehicleInfo.originalSellValue},null,8,[`money`])])):createCommentVNode(``,!0),createVNode(unref(bngUnit_default),{class:`money`,money:unref(vehiclePurchaseStore).vehicleInfo.Value},null,8,[`money`])]),createBaseVNode(`div`,_hoisted_10$27,[createBaseVNode(`div`,null,[_cache[1]||=createTextVNode(` Est. Market: `,-1),createVNode(unref(bngUnit_default),{class:`money`,money:unref(vehiclePurchaseStore).vehicleInfo.marketValue},null,8,[`money`])])])])]),_cache[13]||=createBaseVNode(`div`,{class:`purchase-divider`},null,-1),unref(vehiclePurchaseStore).insuranceOptions.insuranceId>0?(openBlock(),createElementBlock(`div`,_hoisted_11$25,[createBaseVNode(`div`,_hoisted_12$20,toDisplayString(unref(vehiclePurchaseStore).insuranceOptions.spendingReason),1),createBaseVNode(`div`,_hoisted_13$18,[createVNode(unref(bngUnit_default),{class:`money`,money:unref(vehiclePurchaseStore).insuranceOptions.priceMoney},null,8,[`money`])])])):createCommentVNode(``,!0),createBaseVNode(`div`,_hoisted_14$18,[_cache[2]||=createBaseVNode(`div`,{class:`label`},`Dealership Fees`,-1),createBaseVNode(`div`,_hoisted_15$18,[createVNode(unref(bngUnit_default),{class:`money`,money:unref(vehiclePurchaseStore).vehicleInfo.fees},null,8,[`money`])])]),unref(vehiclePurchaseStore).tradeInVehicleInfo?.niceName?(openBlock(),createElementBlock(`div`,_hoisted_16$18)):createCommentVNode(``,!0),unref(vehiclePurchaseStore).tradeInVehicleInfo.niceName?(openBlock(),createElementBlock(`div`,_hoisted_17$14,[createBaseVNode(`div`,_hoisted_18$12,`Trade-in: `+toDisplayString(unref(vehiclePurchaseStore).tradeInVehicleInfo.niceName),1),createBaseVNode(`div`,_hoisted_19$9,[createVNode(unref(bngUnit_default),{class:`money`,money:-unref(vehiclePurchaseStore).tradeInVehicleInfo.Value},null,8,[`money`])])])):createCommentVNode(``,!0),_cache[14]||=createBaseVNode(`div`,{class:`purchase-divider`},null,-1),createBaseVNode(`div`,_hoisted_20$8,[_cache[3]||=createBaseVNode(`div`,{class:`label`},`Subtotal`,-1),createBaseVNode(`div`,_hoisted_21$8,[createVNode(unref(bngUnit_default),{class:`money`,money:unref(vehiclePurchaseStore).finalPackagePrice-unref(vehiclePurchaseStore).prices.taxes-(unref(vehiclePurchaseStore).buyCustomLicensePlate?unref(vehiclePurchaseStore).prices.customLicensePlate:0)},null,8,[`money`])])]),createBaseVNode(`div`,_hoisted_22$7,[_cache[4]||=createBaseVNode(`div`,{class:`label`},`Sales Tax (7%)`,-1),createBaseVNode(`div`,_hoisted_23$6,[createVNode(unref(bngUnit_default),{class:`money`,money:unref(vehiclePurchaseStore).prices.taxes},null,8,[`money`])])]),unref(vehiclePurchaseStore).buyCustomLicensePlate?(openBlock(),createElementBlock(`div`,_hoisted_24$5,[_cache[5]||=createBaseVNode(`div`,{class:`label`},`Custom License Plate`,-1),createBaseVNode(`div`,_hoisted_25$4,[createVNode(unref(bngUnit_default),{class:`money`,money:unref(vehiclePurchaseStore).prices.customLicensePlate},null,8,[`money`])])])):createCommentVNode(``,!0),_cache[15]||=createBaseVNode(`div`,{class:`purchase-divider`},null,-1),createBaseVNode(`div`,_hoisted_26$3,[_cache[6]||=createBaseVNode(`div`,{class:`label highlight-category`},`Total`,-1),createBaseVNode(`div`,_hoisted_27$3,[createVNode(unref(bngUnit_default),{class:`money`,money:unref(vehiclePurchaseStore).finalPackagePrice},null,8,[`money`])])]),unref(vehiclePurchaseStore).finalPackagePrice>unref(vehiclePurchaseStore).playerMoney?(openBlock(),createElementBlock(`div`,_hoisted_28$2,[createBaseVNode(`div`,_hoisted_29$2,[createVNode(unref(bngIcon_default),{type:`danger`}),_cache[7]||=createTextVNode(` Additional funds required`,-1)]),createBaseVNode(`div`,_hoisted_30$2,[createVNode(unref(bngUnit_default),{class:`money`,money:unref(vehiclePurchaseStore).finalPackagePrice-unref(vehiclePurchaseStore).playerMoney},null,8,[`money`])])])):createCommentVNode(``,!0),createBaseVNode(`div`,_hoisted_31$2,[_cache[12]||=createBaseVNode(`h4`,null,`Purchase Options`,-1),createVNode(unref(bngButton_default),{disabled:!unref(vehiclePurchaseStore).vehicleInfo.negotiationPossible,accent:`secondary`,onClick:negotiatePrice},{default:withCtx(()=>[..._cache[8]||=[createTextVNode(` Negotiate Price `,-1)]]),_:1},8,[`disabled`]),withDirectives((openBlock(),createBlock(unref(bngButton_default),{disabled:!unref(vehiclePurchaseStore).tradeInEnabled||!hasVehicle.value,accent:`secondary`,onClick:chooseTradeInVehicle},{default:withCtx(()=>[..._cache[9]||=[createTextVNode(`Choose Trade-In`,-1)]]),_:1},8,[`disabled`])),[[unref(BngTooltip_default),tradeInButtonMessage.value,`top`]]),unref(vehiclePurchaseStore).tradeInEnabled&&unref(vehiclePurchaseStore).tradeInVehicleInfo.niceName?(openBlock(),createBlock(unref(bngButton_default),{key:0,onClick:removeTradeInVehicle,accent:unref(ACCENTS).attention},{default:withCtx(()=>[..._cache[10]||=[createTextVNode(`Remove Trade-In`,-1)]]),_:1},8,[`accent`])):createCommentVNode(``,!0),createVNode(unref(bngButton_default),{onClick:chooseInsurance,accent:unref(ACCENTS).secondary},{default:withCtx(()=>[..._cache[11]||=[createTextVNode(`Choose Insurance`,-1)]]),_:1},8,[`accent`])])])]),_:1})),[[unref(BngBlur_default),1]]):createCommentVNode(``,!0),createBaseVNode(`div`,_hoisted_36$1,[createVNode(unref(bngCard_default),{class:`status-container`},{default:withCtx(()=>[createVNode(unref(careerStatus_default),{class:`profile-status`})]),_:1}),createVNode(TaskList_default,{class:`task-list`,header:unref(store$1).header,tasks:unref(store$1).tasks},null,8,[`header`,`tasks`])])]),_:1}))}},VehiclePurchaseMain_default=__plugin_vue_export_helper_default(_sfc_main$142,[[`__scopeId`,`data-v-b2028538`]]);const useVehicleShoppingStore=defineStore(`vehicleShopping`,()=>{let selectedSellerId=ref(``),currentSeller=ref({}),vehicleShoppingData=ref({}),filteredVehicles=ref([]),filteredSoldVehicles=ref([]),buildFilteredListByKey=(data,key)=>{if(!data||!data[key])return[];let filteredList=Object.keys(data[key]).reduce((result,itemKey)=>{let item=data[key][itemKey];return selectedSellerId.value?item.sellerId===selectedSellerId.value&&result.push(item):result.push(item),result},[]);return filteredList.length&&filteredList.sort((a$1,b)=>a$1.Value-b.Value),filteredList},updateListsFromData=()=>{filteredVehicles.value=buildFilteredListByKey(vehicleShoppingData.value,`vehiclesInShop`),filteredSoldVehicles.value=buildFilteredListByKey(vehicleShoppingData.value,`soldVehicles`)};return{vehicleShoppingData,filteredVehicles,filteredSoldVehicles,currentSeller,requestVehicleShoppingData:async()=>{vehicleShoppingData.value=await Lua_default.career_modules_vehicleShopping.getShoppingData(),updateListsFromData()},setSelectedSellerId:sellerId=>{selectedSellerId.value=sellerId,updateListsFromData(),currentSeller.value=vehicleShoppingData.value.uiDealershipsData.find(dealership=>dealership.id===sellerId)}}});var _hoisted_1$128={class:`cover-container`},_hoisted_2$108={key:0,class:`sold-overlay`},_hoisted_3$96={class:`car-details`},_hoisted_4$76={class:`car-value`},_hoisted_5$65={class:`name`},_hoisted_6$51={class:`brand`},_hoisted_7$43={class:`main-data`},_hoisted_8$35={key:0,class:`price`},_hoisted_9$32={class:`was`},_hoisted_10$26={class:`sold`},_hoisted_11$24={key:0,class:`market`},_hoisted_12$19={key:1,class:`price`},_hoisted_13$17={key:0},_hoisted_14$17={key:1,style:{color:`rgb(245, 29, 29)`}},_hoisted_15$17={key:2,class:`market`},_hoisted_16$17={class:`car-data`},_hoisted_17$13={style:{width:`100%`}},_hoisted_18$11={key:0,style:{flex:`1 0 auto`,"justify-content":`flex-end`,padding:`0.5em 0.75em`,"font-weight":`400`,"font-family":`var(--fnt-defs)`}},DRIVE_TRAIN_ICONS={AWD:icons.AWD,"4WD":icons[`4WD`],FWD:icons.FWD,RWD:icons.RWD,drivetrain_special:icons.drivetrainSpecial,drivetrain_generic:icons.drivetrainGeneric,defaultMissing:icons.drivetrainGeneric,defaultUnknown:icons.drivetrainGeneric},FUEL_TYPE_ICONS={Battery:icons.charge,Gasoline:icons.fuelPump,Diesel:icons.fuelPump,defaultMissing:icons.fuelPump,defaultUnknown:icons.fuelPump},TRANSMISSION_ICONS={Automatic:icons.transmissionA,Manual:icons.transmissionM,defaultMissing:icons.transmissionM,defaultUnknown:icons.transmissionM},_sfc_main$141={__name:`VehicleCard`,props:{vehicleShoppingData:Object,vehicle:Object},setup(__props){let{units}=useBridge(),props=__props,soldPercent=computed(()=>{let asking=props.vehicle?.Value,sold=props.vehicle?.soldFor;return!asking||!sold?0:(sold-asking)/asking*100}),soldDeltaPrefix=computed(()=>soldPercent.value>=0?`+`:``),soldDeltaClass=computed(()=>soldPercent.value>0?`up`:soldPercent.value<0?`down`:`flat`),confirmTaxi=async vehicle=>{await openConfirmation(``,`Do you want to taxi to this vehicle for ${units.beamBucks(vehicle.quickTravelPrice)}?`,[{label:$translate.instant(`ui.common.yes`),value:!0,extras:{default:!0}},{label:$translate.instant(`ui.common.no`),value:!1,extras:{accent:ACCENTS.secondary}}])&&quickTravelToVehicle(vehicle)},showVehicle=shopId=>{Lua_default.career_modules_vehicleShopping.showVehicle(shopId)},quickTravelToVehicle=vehicle=>{Lua_default.career_modules_vehicleShopping.quickTravelToVehicle(vehicle.shopId)},openPurchaseMenu=(purchaseType,shopId)=>{Lua_default.career_modules_vehicleShopping.openPurchaseMenu(purchaseType,shopId)},getAttributeIcon=(vehicle,attribute)=>{let iconDict;return attribute==`Drivetrain`?iconDict=DRIVE_TRAIN_ICONS:attribute==`Fuel Type`?iconDict=FUEL_TYPE_ICONS:attribute==`Transmission`&&(iconDict=TRANSMISSION_ICONS),vehicle[attribute]?iconDict[vehicle[attribute]]||iconDict.defaultUnknown:iconDict.defaultMissing};return(_ctx,_cache)=>(openBlock(),createBlock(unref(bngCard_default),{class:normalizeClass(`vehicle-card row`)},{buttons:withCtx(()=>[createBaseVNode(`div`,_hoisted_17$13,[__props.vehicleShoppingData.currentSeller?createCommentVNode(``,!0):(openBlock(),createBlock(unref(bngPropVal_default),{key:0,style:{float:`left`},keyLabel:`Seller:`,valueLabel:__props.vehicle.sellerName},null,8,[`valueLabel`])),__props.vehicleShoppingData.currentSeller?createCommentVNode(``,!0):(openBlock(),createBlock(unref(bngPropVal_default),{key:1,style:{float:`left`},keyLabel:`Distance:`,valueLabel:unref(units).buildString(`length`,__props.vehicle.distance,1)},null,8,[`valueLabel`])),createVNode(unref(bngPropVal_default),{style:{float:`left`},keyLabel:`Insurance Class:`,valueLabel:__props.vehicle.insuranceClass?.name??`Unknown`},null,8,[`valueLabel`])]),__props.vehicleShoppingData.disableShopping?(openBlock(),createElementBlock(`span`,_hoisted_18$11,toDisplayString(__props.vehicleShoppingData.disableShoppingReason),1)):createCommentVNode(``,!0),__props.vehicle.sellerId===__props.vehicleShoppingData.currentSeller?(openBlock(),createBlock(unref(bngButton_default),{key:1,onClick:_cache[0]||=$event=>showVehicle(__props.vehicle.shopId),accent:unref(ACCENTS).secondary,disabled:__props.vehicleShoppingData.disableShopping||!!__props.vehicle.soldViewCounter},{default:withCtx(()=>[..._cache[10]||=[createTextVNode(`Inspect Vehicle`,-1)]]),_:1},8,[`accent`,`disabled`])):(openBlock(),createBlock(unref(bngButton_default),{key:2,onClick:_cache[1]||=$event=>showVehicle(__props.vehicle.shopId),accent:unref(ACCENTS).secondary,disabled:__props.vehicleShoppingData.disableShopping||!!__props.vehicle.soldViewCounter},{default:withCtx(()=>[..._cache[11]||=[createTextVNode(`Set Route`,-1)]]),_:1},8,[`accent`,`disabled`])),__props.vehicleShoppingData.currentSeller?createCommentVNode(``,!0):(openBlock(),createBlock(unref(bngButton_default),{key:3,disabled:__props.vehicleShoppingData.playerAttributes.money.value<__props.vehicle.quickTravelPrice||__props.vehicleShoppingData.disableShopping||!!__props.vehicle.soldViewCounter,onClick:_cache[2]||=$event=>confirmTaxi(__props.vehicle),accent:__props.vehicle.sellerId===`private`?unref(ACCENTS).main:unref(ACCENTS).secondary},{default:withCtx(()=>[..._cache[12]||=[createBaseVNode(`span`,{style:{flex:`1 0 auto`}},`Take Taxi`,-1)]]),_:1},8,[`disabled`,`accent`])),__props.vehicle.sellerId===`private`?createCommentVNode(``,!0):(openBlock(),createBlock(unref(bngButton_default),{key:4,disabled:__props.vehicleShoppingData.tutorialPurchase||__props.vehicleShoppingData.disableShopping||!!__props.vehicle.soldViewCounter,onClick:_cache[3]||=$event=>openPurchaseMenu(`instant`,__props.vehicle.shopId)},{default:withCtx(()=>[..._cache[13]||=[createTextVNode(`Purchase`,-1)]]),_:1},8,[`disabled`]))]),default:withCtx(()=>[createBaseVNode(`div`,_hoisted_1$128,[createVNode(unref(aspectRatio_default),{class:`cover`,ratio:`16:9`,"external-image":__props.vehicle.preview},null,8,[`external-image`]),__props.vehicle.soldViewCounter>0?(openBlock(),createElementBlock(`div`,_hoisted_2$108,`SOLD`)):createCommentVNode(``,!0)]),createBaseVNode(`div`,_hoisted_3$96,[createBaseVNode(`div`,_hoisted_4$76,[createBaseVNode(`div`,{class:normalizeClass([`car-name`,{sold:__props.vehicle.soldViewCounter>0}])},[createBaseVNode(`h3`,_hoisted_5$65,toDisplayString(__props.vehicle.year)+` `+toDisplayString(__props.vehicle.Name)+` `+toDisplayString(__props.vehicle.soldViewCounter>0?` (Sold)`:``),1),createBaseVNode(`div`,_hoisted_6$51,toDisplayString(__props.vehicle.Brand),1)],2),createBaseVNode(`div`,_hoisted_7$43,[createVNode(unref(bngPropVal_default),{class:`prop-small`,iconColor:`var(--bng-cool-gray-300)`,iconType:unref(icons).bus,valueLabel:unref(units).buildString(`length`,__props.vehicle.Mileage,0)},null,8,[`iconType`,`valueLabel`]),createVNode(unref(bngPropVal_default),{class:`prop-small`,style:{flex:`1 0 auto`},iconColor:`var(--bng-cool-gray-300)`,iconType:unref(icons).bus,valueLabel:__props.vehicle.Drivetrain},null,8,[`iconType`,`valueLabel`]),__props.vehicle.soldFor?(openBlock(),createElementBlock(`div`,_hoisted_8$35,[createBaseVNode(`div`,_hoisted_9$32,[_cache[4]||=createTextVNode(`Was: `,-1),createVNode(unref(bngUnit_default),{money:__props.vehicle.Value},null,8,[`money`])]),createBaseVNode(`div`,_hoisted_10$26,[_cache[5]||=createTextVNode(`Sold for: `,-1),createVNode(unref(bngUnit_default),{class:`car-price`,money:__props.vehicle.soldFor},null,8,[`money`])]),createBaseVNode(`div`,{class:normalizeClass([`delta`,soldDeltaClass.value])},toDisplayString(soldDeltaPrefix.value)+toDisplayString(soldPercent.value.toFixed(1))+`% from asking`,3),__props.vehicle.marketValue?(openBlock(),createElementBlock(`div`,_hoisted_11$24,[_cache[6]||=createTextVNode(`Market: `,-1),createVNode(unref(bngUnit_default),{money:__props.vehicle.marketValue},null,8,[`money`])])):createCommentVNode(``,!0)])):(openBlock(),createElementBlock(`div`,_hoisted_12$19,[__props.vehicle.Value<=__props.vehicleShoppingData.playerAttributes.money.value?(openBlock(),createElementBlock(`div`,_hoisted_13$17,[createVNode(unref(bngUnit_default),{class:`car-price`,money:__props.vehicle.Value},null,8,[`money`]),_cache[7]||=createTextVNode(`*`,-1)])):(openBlock(),createElementBlock(`div`,_hoisted_14$17,[createVNode(unref(bngUnit_default),{class:`car-price`,money:__props.vehicle.Value},null,8,[`money`]),_cache[8]||=createTextVNode(`* Insufficient Funds`,-1)])),__props.vehicle.marketValue?(openBlock(),createElementBlock(`div`,_hoisted_15$17,[_cache[9]||=createTextVNode(`Market: `,-1),createVNode(unref(bngUnit_default),{money:__props.vehicle.marketValue},null,8,[`money`])])):createCommentVNode(``,!0)]))])]),createBaseVNode(`div`,_hoisted_16$17,[__props.vehicle.Power==null?createCommentVNode(``,!0):(openBlock(),createBlock(unref(bngPropVal_default),{key:0,iconType:unref(icons).powerGauge04,keyLabel:`Power:`,valueLabel:unref(units).buildString(`power`,__props.vehicle.Power,0)},null,8,[`iconType`,`valueLabel`])),__props.vehicle.Mileage==null?createCommentVNode(``,!0):(openBlock(),createBlock(unref(bngPropVal_default),{key:1,iconType:unref(icons).odometer,keyLabel:`Mileage:`,valueLabel:unref(units).buildString(`length`,__props.vehicle.Mileage,0)},null,8,[`iconType`,`valueLabel`])),__props.vehicle.Transmission==null?createCommentVNode(``,!0):(openBlock(),createBlock(unref(bngPropVal_default),{key:2,iconType:getAttributeIcon(__props.vehicle,`Transmission`),keyLabel:`Transmission:`,valueLabel:__props.vehicle.Transmission},null,8,[`iconType`,`valueLabel`])),__props.vehicle[`Fuel Type`]==null?createCommentVNode(``,!0):(openBlock(),createBlock(unref(bngPropVal_default),{key:3,iconType:getAttributeIcon(__props.vehicle,`Fuel Type`),keyLabel:`Fuel type:`,valueLabel:__props.vehicle[`Fuel Type`]},null,8,[`iconType`,`valueLabel`])),__props.vehicle.Drivetrain==null?createCommentVNode(``,!0):(openBlock(),createBlock(unref(bngPropVal_default),{key:4,iconType:getAttributeIcon(__props.vehicle,`Drivetrain`),keyLabel:`Drivetrain:`,valueLabel:__props.vehicle.Drivetrain},null,8,[`iconType`,`valueLabel`])),__props.vehicle.Weight==null?createCommentVNode(``,!0):(openBlock(),createBlock(unref(bngPropVal_default),{key:5,iconType:unref(icons).weight,keyLabel:`Weight:`,valueLabel:unref(units).buildString(`weight`,__props.vehicle.Weight,0)},null,8,[`iconType`,`valueLabel`]))])])]),_:1}))}},VehicleCard_default=__plugin_vue_export_helper_default(_sfc_main$141,[[`__scopeId`,`data-v-dea06661`]]),_hoisted_1$127={class:`site-body`,"bng-nav-scroll":``,"bng-nav-scroll-force":``},_hoisted_2$107={class:`heading`},_hoisted_3$95={class:`header-text`},_hoisted_4$75={key:0,class:`vehicle-list`},_hoisted_5$64={key:1,class:`vehicle-list sold-list`},_hoisted_6$50={class:`list-section-title`},_sfc_main$140={__name:`VehicleList`,setup(__props){useUINavScope(`vehicleList`);let vehicleShoppingStore=useVehicleShoppingStore(),getHeaderText=()=>vehicleShoppingStore?.currentSeller?.name||`BeamCar24`;return reactive([{name:`switch`,selected:!0,class:``},{name:`me`,selected:!1,class:``},{name:`please`,selected:!1,class:``}]),(_ctx,_cache)=>withDirectives((openBlock(),createBlock(unref(bngCard_default),{class:`vehicle-shop-wrapper`,"bng-ui-scope":`vehicleList`},{default:withCtx(()=>[createBaseVNode(`div`,_hoisted_1$127,[createBaseVNode(`div`,_hoisted_2$107,[createBaseVNode(`span`,_hoisted_3$95,toDisplayString(getHeaderText()),1),_cache[0]||=createBaseVNode(`span`,{class:`price-notice`},[createBaseVNode(`span`,null,`*\xA0`),createBaseVNode(`span`,null,`Additional taxes and fees are applicable`)],-1)]),unref(vehicleShoppingStore)?(openBlock(),createElementBlock(`div`,_hoisted_4$75,[(openBlock(!0),createElementBlock(Fragment,null,renderList(unref(vehicleShoppingStore).filteredVehicles,(vehicle,key)=>(openBlock(),createBlock(VehicleCard_default,{key,vehicleShoppingData:unref(vehicleShoppingStore).vehicleShoppingData,vehicle},null,8,[`vehicleShoppingData`,`vehicle`]))),128))])):createCommentVNode(``,!0),unref(vehicleShoppingStore)&&unref(vehicleShoppingStore).filteredSoldVehicles&&unref(vehicleShoppingStore).filteredSoldVehicles.length>0?(openBlock(),createElementBlock(`div`,_hoisted_5$64,[createBaseVNode(`div`,_hoisted_6$50,`Recently Sold Vehicles You Viewed (`+toDisplayString(unref(vehicleShoppingStore).filteredSoldVehicles.length)+`)`,1),(openBlock(!0),createElementBlock(Fragment,null,renderList(unref(vehicleShoppingStore).filteredSoldVehicles,(vehicle,key)=>(openBlock(),createBlock(VehicleCard_default,{key,vehicleShoppingData:unref(vehicleShoppingStore).vehicleShoppingData,vehicle},null,8,[`vehicleShoppingData`,`vehicle`]))),128))])):createCommentVNode(``,!0)])]),_:1})),[[unref(BngBlur_default)]])}},VehicleList_default=__plugin_vue_export_helper_default(_sfc_main$140,[[`__scopeId`,`data-v-5045aa89`]]),_hoisted_1$126={class:`veh-part-caption`},_hoisted_2$106={class:`veh-name`},_hoisted_3$94={class:`veh-name-count`},_hoisted_4$74={class:`veh-price`},_hoisted_5$63={class:`veh-remove`},_hoisted_6$49={key:0,class:`offer-card red`},_hoisted_7$42=[`onMouseover`,`onMouseleave`,`onActivate`,`onDeactivate`],_hoisted_8$34={class:`offer-info`},_hoisted_9$31={class:`offer-header`},_hoisted_10$25={class:`buyer-name`},_hoisted_11$23={key:0,class:`expired-badge`},_hoisted_12$18={class:`offer-details`},_hoisted_13$16={class:`detail-row`},_hoisted_14$16={class:`detail-row`},_hoisted_15$16={class:`spec-actions`},_hoisted_16$16={key:1,class:`offer-card`},_sfc_main$139={__name:`VehicleMarketplace`,setup(__props){useComputerStore();let listings=ref([]),confirmRemoveListingScreen=async listingId=>{await openConfirmation(``,`Do you want to remove this listing?`,[{label:$translate.instant(`ui.common.yes`),value:!0,extras:{default:!0}},{label:$translate.instant(`ui.common.no`),value:!1,extras:{accent:ACCENTS.secondary}}])&&removeVehicleListing(listingId)},onActivated$1=offer=>{offer.active=!0},onDeactivated$1=offer=>{offer.active=!1},onOfferHovered=offer=>{offer.hovered=!0},onOfferUnhovered=offer=>{offer.hovered=!1},handleListings=data=>{listings.value=data},getNewData=()=>{Lua_default.career_modules_marketplace.getListings().then(handleListings)},acceptOffer=(inventoryId,offerIndex)=>{Lua_default.career_modules_marketplace.acceptOffer(inventoryId,offerIndex+1).then(getNewData)},declineOffer=(inventoryId,offerIndex)=>{Lua_default.career_modules_marketplace.declineOffer(inventoryId,offerIndex+1).then(getNewData)},startNegotiateBuyingOffer=(inventoryId,offerIndex)=>{Lua_default.career_modules_marketplace.startNegotiateBuyingOffer(inventoryId,offerIndex+1).then(getNewData)},removeVehicleListing=inventoryId=>{Lua_default.career_modules_marketplace.removeVehicleListing(inventoryId).then(getNewData)},listVehicle=()=>{Lua_default.career_modules_inventory.openInventoryMenuForChoosingListing()};return onMounted(()=>{Lua_default.career_modules_marketplace.menuOpened(!0),getNewData()}),onUnmounted(()=>{Lua_default.career_modules_marketplace.menuOpened(!1)}),(_ctx,_cache)=>(openBlock(),createElementBlock(Fragment,null,[createVNode(unref(accordion_default),{class:`part-groups`,items:listings.value},{default:withCtx(()=>[(openBlock(!0),createElementBlock(Fragment,null,renderList(listings.value,listing=>(openBlock(),createBlock(unref(accordionItem_default),{key:listing.id,expanded:!0,class:normalizeClass([`marketplace-listing`,{disabled:listing.disabled}])},{caption:withCtx(()=>[createBaseVNode(`div`,_hoisted_1$126,[listing.thumbnail?(openBlock(),createElementBlock(`div`,{key:0,class:`veh-preview`,style:normalizeStyle({backgroundImage:`url('${listing.thumbnail}')`})},null,4)):createCommentVNode(``,!0),createBaseVNode(`span`,_hoisted_2$106,[createTextVNode(toDisplayString(listing.niceName)+` `,1),createBaseVNode(`span`,_hoisted_3$94,`(`+toDisplayString(listing.offers.length||0)+`)`,1)]),createBaseVNode(`span`,_hoisted_4$74,[createBaseVNode(`div`,null,[_cache[0]||=createTextVNode(` Asking Price: `,-1),createVNode(unref(bngUnit_default),{money:listing.value},null,8,[`money`])]),createBaseVNode(`div`,null,[_cache[1]||=createTextVNode(` Estimated Market Value: `,-1),createVNode(unref(bngUnit_default),{money:listing.marketValue},null,8,[`money`])])]),createBaseVNode(`span`,_hoisted_5$63,[createVNode(unref(bngButton_default),{onClick:withModifiers($event=>confirmRemoveListingScreen(listing.id),[`stop`]),icon:unref(icons).trashBin1,accent:unref(ACCENTS).attentionghost},null,8,[`onClick`,`icon`,`accent`])])])]),default:withCtx(()=>[listing.disabled?(openBlock(),createElementBlock(`div`,_hoisted_6$49,toDisplayString(listing.disableReason),1)):createCommentVNode(``,!0),(openBlock(!0),createElementBlock(Fragment,null,renderList(listing.offers,(offer,index)=>withDirectives((openBlock(),createElementBlock(`div`,{class:normalizeClass([`offer-card`,{expired:offer.expiredViewCounter==1}]),onMouseover:$event=>onOfferHovered(offer),onMouseleave:$event=>onOfferUnhovered(offer),onActivate:$event=>onActivated$1(offer),onDeactivate:$event=>onDeactivated$1(offer)},[createBaseVNode(`div`,_hoisted_8$34,[createBaseVNode(`div`,_hoisted_9$31,[createBaseVNode(`span`,_hoisted_10$25,toDisplayString(offer.buyerPersonality.name),1),offer.expiredViewCounter?(openBlock(),createElementBlock(`span`,_hoisted_11$23,`EXPIRED`)):createCommentVNode(``,!0)]),createBaseVNode(`div`,_hoisted_12$18,[createBaseVNode(`div`,_hoisted_13$16,[_cache[3]||=createBaseVNode(`span`,{class:`detail-label`},`Offer:`,-1),createVNode(unref(bngUnit_default),{money:offer.value},null,8,[`money`]),createBaseVNode(`span`,{class:normalizeClass([`delta`,{up:offer.value>listing.value,down:offer.valuelisting.value?`+`:`-`),1),createVNode(unref(bngUnit_default),{money:Math.abs(offer.value-listing.value)},null,8,[`money`]),_cache[2]||=createTextVNode(`) `,-1)],2)]),createBaseVNode(`div`,_hoisted_14$16,[_cache[4]||=createBaseVNode(`span`,{class:`detail-label`},`Vehicle:`,-1),createBaseVNode(`span`,null,toDisplayString(listing.niceName),1)])])]),createBaseVNode(`div`,_hoisted_15$16,[createVNode(unref(bngButton_default),{class:`part-button`,onClick:$event=>declineOffer(listing.id,index),accent:unref(ACCENTS).attention},{default:withCtx(()=>[createTextVNode(toDisplayString(offer.expiredViewCounter?`Discard`:`Deny`),1)]),_:2},1032,[`onClick`,`accent`]),offer.expiredViewCounter?createCommentVNode(``,!0):(openBlock(),createBlock(unref(bngButton_default),{key:0,class:`part-button negotiate-button`,onClick:$event=>startNegotiateBuyingOffer(listing.id,index),accent:unref(ACCENTS).secondary,disabled:!offer.negotiationPossible||offer.value>=listing.value||listing.disabled},{default:withCtx(()=>[..._cache[5]||=[createTextVNode(` Negotiate `,-1)]]),_:1},8,[`onClick`,`accent`,`disabled`])),offer.expiredViewCounter?createCommentVNode(``,!0):(openBlock(),createBlock(unref(bngButton_default),{key:1,class:`part-button`,onClick:$event=>acceptOffer(listing.id,index),disabled:listing.disabled||offer.disabled,accent:unref(ACCENTS).main},{default:withCtx(()=>[..._cache[6]||=[createTextVNode(` Accept Offer `,-1)]]),_:1},8,[`onClick`,`disabled`,`accent`]))])],42,_hoisted_7$42)),[[unref(BngScopedNav_default)]])),256)),Object.keys(listing.offers||{}).length===0?(openBlock(),createElementBlock(`div`,_hoisted_16$16,toDisplayString(unref($translate).instant(`ui.career.vehicleMarketplace.noOffers`)),1)):createCommentVNode(``,!0)]),_:2},1032,[`class`]))),128))]),_:1},8,[`items`]),createVNode(unref(bngButton_default),{class:`add-listing-button`,onClick:listVehicle,accent:unref(ACCENTS).custom},{default:withCtx(()=>[..._cache[7]||=[createBaseVNode(`span`,{class:`add-listing-button-icon`},`+`,-1),createTextVNode(` Add Listing `,-1)]]),_:1},8,[`accent`])],64))}},VehicleMarketplace_default=__plugin_vue_export_helper_default(_sfc_main$139,[[`__scopeId`,`data-v-468e550d`]]),_hoisted_1$125={class:`flex-container`},_hoisted_2$105={class:`content`},_hoisted_3$93={key:0},_hoisted_4$73={class:`seller-grid`},_hoisted_5$62={class:`seller-card__label`},_hoisted_6$48={class:`seller-card__header`},_hoisted_7$41={class:`seller-card__title`},_hoisted_8$33={key:0,class:`seller-card__subtitle`},_hoisted_9$30={class:`seller-card__vehicle-thumbnails`},_hoisted_10$24={class:`seller-card__vehicle-thumbnail`},_hoisted_11$22={key:0,class:`more-label`},_hoisted_12$17={key:1},buyVehicleTitle=`Buy Vehicles`,sellVehicleTitle=`Sell Vehicles`,_sfc_main$138={__name:`VehicleShoppingMain`,props:{screenTag:{type:String,default:``},buyingAvailable:{type:String,default:`true`},marketplaceAvailable:{type:String,default:`true`},selectedSellerId:{type:String,default:``}},setup(__props){useUINavScope(`vehicleShopping`),useComputerStore();let vehicleShoppingStore=useVehicleShoppingStore(),selectedTab=ref(0),selectedSellerId=ref(``),router$1=useRouter(),loaded=ref(!1),selectSeller=sellerId=>{setSelectedSellerId(sellerId),updateRouteScreenTag()},tabs=computed(()=>{let tabs$1=[];return props.buyingAvailable===`true`&&tabs$1.push(buyVehicleTitle),props.marketplaceAvailable===`true`&&tabs$1.push(sellVehicleTitle),tabs$1}),props=__props,processTabInput=event=>{event.detail.name===`tab_l`?selectedTab.value=(selectedTab.value-1+tabs.value.length)%tabs.value.length:event.detail.name===`tab_r`&&(selectedTab.value=(selectedTab.value+1)%tabs.value.length)},onTabsChange=(tab,old)=>{let idx=tabs.value.indexOf(tab&&tab.heading?tab.heading:``);idx!==-1&&(selectedTab.value=idx),selectedTab.value===tabs.value.indexOf(buyVehicleTitle)&&(selectedSellerId.value=``)},headerTitle=computed(()=>{switch(tabs.value[selectedTab.value]){case buyVehicleTitle:return`Buy Vehicles`;case sellVehicleTitle:return`Sell Vehicles`;default:return`Available Vehicles`}}),updateRouteScreenTag=()=>{let screenTag=selectedTab.value===tabs.value.indexOf(sellVehicleTitle)?`marketplace`:`buying`;router$1.replace({name:`vehicleShopping`,params:{screenTag,buyingAvailable:props.buyingAvailable,marketplaceAvailable:props.marketplaceAvailable,selectedSellerId:selectedSellerId.value}})};watch(selectedTab,()=>{updateRouteScreenTag()});let setSelectedSellerId=sellerId=>{selectedSellerId.value=sellerId,vehicleShoppingStore.setSelectedSellerId(selectedSellerId.value)},dealershipVehiclesMap=computed(()=>{let map=new Map;return vehicleShoppingStore.vehicleShoppingData.vehiclesInShop&&vehicleShoppingStore.vehicleShoppingData.vehiclesInShop.filter(vehicle=>vehicle.preview).forEach(vehicle=>{map.has(vehicle.sellerId)||map.set(vehicle.sellerId,[]),map.get(vehicle.sellerId).push(vehicle)}),map}),getDealershipVehicles=dealershipId=>dealershipVehiclesMap.value.get(dealershipId)||[],start=()=>{nextTick(async()=>{await vehicleShoppingStore.requestVehicleShoppingData(),loaded.value=!0,vehicleShoppingStore.vehicleShoppingData.currentSeller?setSelectedSellerId(vehicleShoppingStore.vehicleShoppingData.currentSeller):setSelectedSellerId(props.selectedSellerId),props.screenTag==`buying`?selectedTab.value=tabs.value.indexOf(buyVehicleTitle):props.screenTag==`marketplace`?selectedTab.value=tabs.value.indexOf(sellVehicleTitle):selectedTab.value=0,updateRouteScreenTag()})},kill=async()=>{await Lua_default.career_modules_vehicleShopping.onShoppingMenuClosed(),vehicleShoppingStore.$dispose()},close=()=>{!vehicleShoppingStore.vehicleShoppingData.currentSeller&&selectedTab.value===tabs.value.indexOf(buyVehicleTitle)&&selectedSellerId.value?selectedSellerId.value=``:router$1.back()};return onMounted(start),onUnmounted(kill),(_ctx,_cache)=>withDirectives((openBlock(),createBlock(ComputerWrapper_default,{path:[unref(vehicleShoppingStore).vehicleShoppingData.currentSellerNiceName||`Vehicle Marketplace`],title:headerTitle.value,"bng-ui-scope":`vehicleShopping`,back:``,onBack:close},{status:withCtx(()=>[createTextVNode(` Free Inventory Slots: `+toDisplayString(unref(vehicleShoppingStore)?unref(vehicleShoppingStore).vehicleShoppingData.numberOfFreeSlots:0),1)]),default:withCtx(()=>[createBaseVNode(`div`,_hoisted_1$125,[withDirectives((openBlock(),createElementBlock(`div`,_hoisted_2$105,[createVNode(unref(tabs_default),{class:normalizeClass([`bng-tabs`,{"single-tab":tabs.value.length===1}]),selectedIndex:selectedTab.value,onChange:onTabsChange},{default:withCtx(()=>[createVNode(unref(tabList_default)),props.buyingAvailable===`true`?(openBlock(),createElementBlock(`div`,{key:0,"tab-heading":buyVehicleTitle,class:`buying-tab-content`},[loaded.value&&!selectedSellerId.value?(openBlock(),createBlock(unref(bngCard_default),{key:0,class:`buying-card`},{default:withCtx(()=>[unref(vehicleShoppingStore).vehicleShoppingData.uiDealershipsData&&Object.keys(unref(vehicleShoppingStore).vehicleShoppingData.uiDealershipsData).length?(openBlock(),createElementBlock(`div`,_hoisted_3$93,[createBaseVNode(`div`,_hoisted_4$73,[(openBlock(!0),createElementBlock(Fragment,null,renderList(unref(vehicleShoppingStore).vehicleShoppingData.uiDealershipsData,dealership=>(openBlock(),createBlock(unref(bngTile_default),{key:dealership.id,class:`seller-card`,style:normalizeStyle({backgroundImage:`linear-gradient(180deg, rgba(0,0,0,0.9), rgba(0,0,0,0)), url(`+(dealership.preview&&dealership.preview[0]===`/`?dealership.preview:`/`+dealership.preview)+`)`}),onClick:$event=>dealership.vehicleCount&&selectSeller(dealership.id)},{label:withCtx(()=>[createBaseVNode(`div`,_hoisted_5$62,[createBaseVNode(`div`,_hoisted_6$48,[createBaseVNode(`div`,_hoisted_7$41,[createVNode(unref(bngIcon_default),{type:dealership.icon},null,8,[`type`]),createTextVNode(toDisplayString(dealership.name),1)]),dealership.description?(openBlock(),createElementBlock(`div`,_hoisted_8$33,toDisplayString(dealership.description),1)):createCommentVNode(``,!0)]),createBaseVNode(`div`,_hoisted_9$30,[(openBlock(!0),createElementBlock(Fragment,null,renderList(getDealershipVehicles(dealership.id).slice(0,5),(vehicle,index)=>(openBlock(),createElementBlock(`div`,_hoisted_10$24,[createVNode(unref(aspectRatio_default),{ratio:`16:9`,class:`seller-card__vehicle-thumbnail-image`,"external-image":vehicle.preview},{default:withCtx(()=>[index==0&&getDealershipVehicles(dealership.id).length>5?(openBlock(),createElementBlock(`div`,_hoisted_11$22,` +`+toDisplayString(getDealershipVehicles(dealership.id).length-4),1)):createCommentVNode(``,!0)]),_:2},1032,[`external-image`])]))),256))])])]),_:2},1032,[`style`,`onClick`]))),128))])])):(openBlock(),createElementBlock(`div`,_hoisted_12$17,[..._cache[0]||=[createBaseVNode(`span`,null,`No sellers available.`,-1)]]))]),_:1})):loaded.value?(openBlock(),createBlock(VehicleList_default,{key:1})):(openBlock(),createBlock(unref(bngCard_default),{key:2},{default:withCtx(()=>[createVNode(unref(bngCardHeading_default),{style:{color:`#fff`}},{default:withCtx(()=>[..._cache[1]||=[createTextVNode(`Please wait...`,-1)]]),_:1})]),_:1}))])):createCommentVNode(``,!0),props.marketplaceAvailable===`true`?(openBlock(),createElementBlock(`div`,{key:1,"tab-heading":sellVehicleTitle,class:`marketplace-tab-content`},[createVNode(VehicleMarketplace_default)])):createCommentVNode(``,!0)]),_:1},8,[`class`,`selectedIndex`])])),[[unref(BngBlur_default),1]])])]),_:1},8,[`path`,`title`])),[[unref(BngOnUiNav_default),processTabInput,`tab_l,tab_r`]])}},VehicleShoppingMain_default=__plugin_vue_export_helper_default(_sfc_main$138,[[`__scopeId`,`data-v-83009aa9`]]),_hoisted_1$124={style:{padding:`1em`,overflow:`auto`}},_hoisted_2$104={class:`performance-class-container`},_hoisted_3$92={key:0,class:`performance-class-wrapper`},_hoisted_4$72={class:`class-badge`},_hoisted_5$61={class:`certification-container`},_hoisted_6$47={class:`specs-section`},_hoisted_7$40={key:0},_hoisted_8$32={key:1,class:`specs-grid`},_hoisted_9$29={class:`spec-row`},_hoisted_10$23={class:`spec-label`},_hoisted_11$21={class:`spec-value`},_hoisted_12$16={class:`spec-row`},_hoisted_13$15={class:`spec-value`},_hoisted_14$15={class:`spec-row`},_hoisted_15$15={class:`spec-label`},_hoisted_16$15={class:`spec-value`},_hoisted_17$12={class:`spec-row`},_hoisted_18$10={class:`spec-label`},_hoisted_19$8={class:`spec-value`},_hoisted_20$7={class:`spec-row`},_hoisted_21$7={class:`spec-label`},_hoisted_22$6={class:`spec-value`},_hoisted_23$5={class:`spec-row`},_hoisted_24$4={class:`spec-value`},_hoisted_25$3={class:`spec-row`},_hoisted_26$2={class:`spec-value`},_hoisted_27$2={class:`specs-section`},_hoisted_28$1={key:0,class:`metrics-grid`},_hoisted_29$1={key:3,class:`performance-index-container`},_hoisted_30$1={class:`progress-wrapper`},_hoisted_31$1={class:`class-markers`},_hoisted_32$1={class:`marker-label`},_hoisted_33$1={class:`history-dropdown-container`},_hoisted_34$1={class:`dropdown`},_sfc_main$137={__name:`VehiclePerformanceTile`,props:{vehicleData:Object},setup(__props){let{units}=useBridge(),props=__props;computed(()=>props.vehicleData.niceName||`No Name`);let startTestTitle=computed(()=>props.vehicleData.needsRepair?`Assess Performance (Repair Required)`:`Assess Performance Now`),startTest=function(){Lua_default.career_modules_vehiclePerformance.startDragTest(props.vehicleData.id)},getColorForValue=(value,min$1=0,max$1=1)=>{let normalizedValue=(value-min$1)/(max$1-min$1),adjustedValue=Math.max(0,normalizedValue-.1)*(1/.9),red,green;return adjustedValue<.5?(red=200,green=Math.round(200*(adjustedValue*2))):(red=Math.round(200*(2-adjustedValue*2)),green=200),`rgb(${red}, ${green}, 0)`},selectedHistoryIndex=ref(0),allCertificationData=computed(()=>[props.vehicleData.certificationData||{noPerformanceData:!0},...props.vehicleData.performanceHistory||[]]),historyOptions=computed(()=>allCertificationData.value.length?allCertificationData.value.map((item,index)=>({value:index,label:index===0?item.noPerformanceData?`Current Test Results: No data`:`Current Test Results - `+new Date(item.timeStamp).toLocaleString():`Previous Test Results - ${new Date(item.timeStamp).toLocaleString()}`})):[]),selectedCertificationData=computed(()=>allCertificationData.value[selectedHistoryIndex.value]);return watch(()=>props.vehicleData,newVal=>{},{immediate:!0}),(_ctx,_cache)=>withDirectives((openBlock(),createBlock(unref(bngCard_default),{class:`card`},{footer:withCtx(()=>[createBaseVNode(`div`,_hoisted_33$1,[createBaseVNode(`div`,_hoisted_34$1,[_cache[8]||=createBaseVNode(`div`,{class:`dropdown-label`},`Previous Assessments`,-1),createVNode(unref(bngDropdown_default),{modelValue:selectedHistoryIndex.value,"onUpdate:modelValue":_cache[0]||=$event=>selectedHistoryIndex.value=$event,items:historyOptions.value,class:`history-select`},{default:withCtx(()=>[createTextVNode(toDisplayString(historyOptions.value[selectedHistoryIndex.value].text),1)]),_:1},8,[`modelValue`,`items`])]),createVNode(unref(bngButton_default),{onClick:_cache[1]||=$event=>startTest(),disabled:__props.vehicleData.needsRepair||!__props.vehicleData.owned},{default:withCtx(()=>[createTextVNode(toDisplayString(startTestTitle.value),1)]),_:1},8,[`disabled`])])]),default:withCtx(()=>[createBaseVNode(`div`,_hoisted_1$124,[createBaseVNode(`div`,null,[createVNode(VehicleTileRow_default,{class:`vehicle-tile-row`,data:__props.vehicleData,enableHover:!1,small:!0},null,8,[`data`]),createBaseVNode(`div`,_hoisted_2$104,[selectedCertificationData.value&&selectedCertificationData.value.vehicleClass?(openBlock(),createElementBlock(`div`,_hoisted_3$92,[createBaseVNode(`span`,_hoisted_4$72,` Class `+toDisplayString(selectedCertificationData.value.vehicleClass.class.name)+` | PI `+toDisplayString(selectedCertificationData.value.vehicleClass.performanceIndex.toFixed(0)),1)])):createCommentVNode(``,!0)])]),createBaseVNode(`div`,_hoisted_5$61,[createBaseVNode(`div`,_hoisted_6$47,[_cache[5]||=createBaseVNode(`div`,{class:`section-header`},[createBaseVNode(`h2`,null,`Technical Specifications`)],-1),selectedCertificationData.value.vehicleClass?(openBlock(),createElementBlock(`div`,_hoisted_8$32,[createBaseVNode(`div`,_hoisted_9$29,[createBaseVNode(`div`,_hoisted_10$23,toDisplayString(_ctx.$t(`ui.options.units.weight`)),1),createBaseVNode(`div`,_hoisted_11$21,toDisplayString(_ctx.$game.units.buildString(`weight`,selectedCertificationData.value.weight,0)),1)]),createBaseVNode(`div`,_hoisted_12$16,[_cache[2]||=createBaseVNode(`div`,{class:`spec-label`},`Power/Weight`,-1),createBaseVNode(`div`,_hoisted_13$15,toDisplayString(selectedCertificationData.value.powerPerTon.toFixed(0))+`hp/1000kg`,1)]),createBaseVNode(`div`,_hoisted_14$15,[createBaseVNode(`div`,_hoisted_15$15,toDisplayString(_ctx.$t(`vehicle.info.Drivetrain`)),1),createBaseVNode(`div`,_hoisted_16$15,toDisplayString(selectedCertificationData.value.drivetrain),1)]),createBaseVNode(`div`,_hoisted_17$12,[createBaseVNode(`div`,_hoisted_18$10,toDisplayString(_ctx.$t(`vehicle.info.Fuel Type`)),1),createBaseVNode(`div`,_hoisted_19$8,toDisplayString(selectedCertificationData.value.fuelType),1)]),createBaseVNode(`div`,_hoisted_20$7,[createBaseVNode(`div`,_hoisted_21$7,toDisplayString(_ctx.$t(`vehicle.info.Induction Type`)),1),createBaseVNode(`div`,_hoisted_22$6,toDisplayString(selectedCertificationData.value.inductionType),1)]),createBaseVNode(`div`,_hoisted_23$5,[_cache[3]||=createBaseVNode(`div`,{class:`spec-label`},`Mileage`,-1),createBaseVNode(`div`,_hoisted_24$4,toDisplayString(unref(units).buildString(`length`,selectedCertificationData.value.mileage,0)),1)]),createBaseVNode(`div`,_hoisted_25$3,[_cache[4]||=createBaseVNode(`div`,{class:`spec-label`},`Lateral G-Force`,-1),createBaseVNode(`div`,_hoisted_26$2,toDisplayString(selectedCertificationData.value.lateralGForce.toFixed(2))+` G`,1)])])):(openBlock(),createElementBlock(`div`,_hoisted_7$40,` Vehicle has not been assessed yet. `))]),createBaseVNode(`div`,_hoisted_27$2,[_cache[7]||=createBaseVNode(`div`,{class:`section-header`},[createBaseVNode(`h2`,null,`Metrics`)],-1),selectedCertificationData.value.vehicleClass?(openBlock(),createElementBlock(`div`,_hoisted_28$1,[selectedCertificationData.value.power?(openBlock(),createBlock(unref(bngProgressBar_default),{key:0,headerLeft:`Power Output`,headerRight:_ctx.$game.units.buildString(`power`,selectedCertificationData.value.power,0),value:selectedCertificationData.value.power,min:0,max:1e3,showValueLabel:!1,valueColor:getColorForValue(selectedCertificationData.value.power,0,1e3),class:`score-progress`},null,8,[`headerRight`,`value`,`valueColor`])):createCommentVNode(``,!0),createVNode(unref(bngProgressBar_default),{headerLeft:`0-60 mph time (prepped surface)`,headerRight:selectedCertificationData.value.time_0_60?selectedCertificationData.value.time_0_60.toFixed(2)+` s`:`N/A`,value:selectedCertificationData.value.time_0_60?-selectedCertificationData.value.time_0_60:-25,min:-25,max:-2,showValueLabel:!1,valueColor:getColorForValue(selectedCertificationData.value.time_0_60?-selectedCertificationData.value.time_0_60:-25,-25,-2),class:`score-progress`},null,8,[`headerRight`,`value`,`valueColor`]),selectedCertificationData.value.time_1_4?(openBlock(),createBlock(unref(bngProgressBar_default),{key:1,headerLeft:`Quarter Mile`,headerRight:selectedCertificationData.value.time_1_4.toFixed(2)+` s @ `+_ctx.$game.units.buildString(`speed`,selectedCertificationData.value.velAt_1_4,0),value:selectedCertificationData.value.time_1_4?-selectedCertificationData.value.time_1_4:-35,min:-35,max:-8.1,showValueLabel:!1,valueColor:getColorForValue(selectedCertificationData.value.time_1_4?-selectedCertificationData.value.time_1_4:-35,-35,-8.1),class:`score-progress`},null,8,[`headerRight`,`value`,`valueColor`])):createCommentVNode(``,!0),selectedCertificationData.value.performanceAggregateScores.brakingGForceScore?(openBlock(),createBlock(unref(bngProgressBar_default),{key:2,headerLeft:`Braking Force`,headerRight:selectedCertificationData.value.brakingG?selectedCertificationData.value.brakingG.toFixed(2)+` G`:`N/A`,value:selectedCertificationData.value.brakingG||0,min:.5,max:1.9,showValueLabel:!1,valueColor:getColorForValue(selectedCertificationData.value.brakingG||0,.5,1.9),class:`score-progress`},null,8,[`headerRight`,`value`,`valueColor`])):createCommentVNode(``,!0),selectedCertificationData.value&&selectedCertificationData.value.vehicleClass?(openBlock(),createElementBlock(`div`,_hoisted_29$1,[createBaseVNode(`div`,_hoisted_30$1,[createVNode(unref(bngProgressBar_default),{headerLeft:`Performance Index`,headerRight:`Class: `+selectedCertificationData.value.vehicleClass.class.name,value:selectedCertificationData.value.vehicleClass.performanceIndex,min:0,max:110,showValueLabel:!1,valueColor:getColorForValue(selectedCertificationData.value.vehicleClass.performanceIndex/110),class:`score-progress performance-index`},null,8,[`headerRight`,`value`,`valueColor`]),createBaseVNode(`div`,_hoisted_31$1,[(openBlock(),createElementBlock(Fragment,null,renderList([{pi:101,name:`X`},{pi:86,name:`S`},{pi:66,name:`A`},{pi:41,name:`B`},{pi:21,name:`C`}],(classInfo,index)=>createBaseVNode(`div`,{key:index,class:`class-marker`,style:normalizeStyle({left:`${classInfo.pi/110*100}%`})},[_cache[6]||=createBaseVNode(`div`,{class:`marker-line`},null,-1),createBaseVNode(`div`,_hoisted_32$1,toDisplayString(classInfo.name),1)],4)),64))])])])):createCommentVNode(``,!0)])):createCommentVNode(``,!0)])])])]),_:1})),[[unref(BngBlur_default),!0]])}},VehiclePerformanceTile_default=__plugin_vue_export_helper_default(_sfc_main$137,[[`__scopeId`,`data-v-ca2efe1a`]]),_hoisted_1$123={key:0,class:`certification-test-in-progress`},_hoisted_2$103={class:`certification-content`},_hoisted_3$91={class:`certification-icon`},_hoisted_4$71={class:`cancelButton`},_hoisted_5$60={key:1},_sfc_main$136={__name:`VehiclePerformanceMain`,props:{inventoryId:String},setup(__props){let router$1=useRouter(),vehicleData=ref({}),assessmentProgressMessage=ref(`Performance Assessment in progress...`),cancellingTest=ref(!1),testInProgress=ref(!1),{$game}=useLibStore(),title=computed(()=>vehicleData.value.niceName?`Performance Index: `+vehicleData.value.niceName:`Performance Index`),props=__props;$game.events.on(`PerformanceTestMessage`,data=>{assessmentProgressMessage.value=data.message,cancellingTest.value=!0}),$game.events.on(`PerformanceTestStarted`,data=>{testInProgress.value=data.testInProgress,getVehicleData()});let close=()=>{router$1.back()},kill=()=>{$game.events.off(`PerformanceTestMessage`),$game.events.off(`PerformanceTestStarted`)},getVehicleData=()=>{Lua_default.career_modules_inventory.getVehicleUiData(Number(props.inventoryId)).then(data=>{vehicleData.value=data})},start=()=>{getVehicleData()},cancelTest=()=>{Lua_default.career_modules_vehiclePerformance.cancelTest()};return onUnmounted(kill),onMounted(start),(_ctx,_cache)=>testInProgress.value?(openBlock(),createElementBlock(`div`,_hoisted_1$123,[createVNode(unref(bngCard_default),{class:`certification-card`},{default:withCtx(()=>[createBaseVNode(`div`,_hoisted_2$103,[createBaseVNode(`div`,null,[createBaseVNode(`div`,{class:normalizeClass([`certificationTestText`,{cancelling:cancellingTest.value}])},toDisplayString(assessmentProgressMessage.value),3)]),createBaseVNode(`div`,_hoisted_3$91,[createVNode(unref(bngIcon_default),{type:unref(icons).timeUnlockOutline},null,8,[`type`])])]),createBaseVNode(`div`,_hoisted_4$71,[withDirectives((openBlock(),createBlock(unref(bngButton_default),{accent:unref(ACCENTS).RED,onClick:cancelTest,tabindex:`0`},{default:withCtx(()=>[..._cache[0]||=[createTextVNode(` Cancel Test `,-1)]]),_:1},8,[`accent`])),[[unref(BngOnUiNav_default),void 0,`back,menu`,{asMouse:!0}]])])]),_:1})])):(openBlock(),createElementBlock(`div`,_hoisted_5$60,[createVNode(ComputerWrapper_default,{ref:`wrapper`,path:[`Performance Index`],title:title.value,back:``,onBack:close},{default:withCtx(()=>[createVNode(VehiclePerformanceTile_default,{"vehicle-data":vehicleData.value},null,8,[`vehicle-data`])]),_:1},8,[`title`])]))}},VehiclePerformanceMain_default=__plugin_vue_export_helper_default(_sfc_main$136,[[`__scopeId`,`data-v-ea737c56`]]),_hoisted_1$122={class:`offer-chat-container-wrapper`},_hoisted_2$102={key:0,class:`above`},_hoisted_3$90={key:1,class:`red`},_hoisted_4$70={key:2,class:`green`},_hoisted_5$59={key:3,class:`above`},_hoisted_6$46={key:4,class:`above`},_hoisted_7$39={key:5,class:`price`},_sfc_main$135={__name:`NegotiationChat`,props:{offerHistory:{type:Array,default:()=>[]},negotiationStatus:{type:String,default:``},startingPrice:{type:Number,default:0},amISelling:{type:Boolean,default:!1}},setup(__props,{expose:__expose}){let props=__props,offerChatContainer=ref(null),statusTextFromStatus=status=>{switch(String(status||``)){case`counterOffer`:return`Counter offer`;case`counterOfferLastChance`:return`Last chance counter offer`;case`accepted`:return`Accepted`;case`failed`:return`Negotiation failed`;case`refused`:return`Offer refused`;case`initial`:return props.amISelling?`Initial offer`:`Asking Price`;case`thinking`:return`Thinking`;default:return``}},fillInOfferHistory=history$1=>{if(!history$1||!Array.isArray(history$1))return[];let hasSeenMyOffer=!1,isFirstInitialOffer=!0;return history$1.map(item=>{let isMyOffer=item.myOffer!=null,isTheirOffer=item.theirOffer!=null,currentOffer=isMyOffer?item.myOffer:item.theirOffer,difference=null;isTheirOffer&&isFirstInitialOffer?isFirstInitialOffer=!1:difference=currentOffer-props.startingPrice;let offerStatus=null;return isMyOffer&&(hasSeenMyOffer?offerStatus=`counterOffer`:(offerStatus=`initial`,hasSeenMyOffer=!0)),isMyOffer?item.myOffer:isTheirOffer&&item.theirOffer,{theirOffer:item.theirOffer,myOffer:item.myOffer,negotiationStatus:item.negotiationStatus,messageClass:isMyOffer?`sent-message`:`received-message`,difference,offerStatus}})},typingMessageId=ref(null),previousOfferHistoryLength=ref(0);watch(()=>props.negotiationStatus,newStatus=>{newStatus===`typing`&&typingMessageId.value===null&&(typingMessageId.value=`typing-${Date.now()}`)});let processedOfferHistory=computed(()=>{let history$1=fillInOfferHistory(props.offerHistory),currentHistoryLength=(props.offerHistory||[]).length;if(currentHistoryLength>previousOfferHistoryLength.value&&typingMessageId.value!==null){let responseId=typingMessageId.value,responseData=history$1[history$1.length-1],result=[...history$1];return result[result.length-1]={...responseData,typingId:responseId,isTyping:!1},typingMessageId.value=null,previousOfferHistoryLength.value=currentHistoryLength,result}return currentHistoryLength!==previousOfferHistoryLength.value&&(previousOfferHistoryLength.value=currentHistoryLength),props.negotiationStatus===`typing`&&typingMessageId.value!==null?[...history$1,{theirOffer:null,myOffer:null,negotiationStatus:`typing`,messageClass:`received-message`,difference:null,isTyping:!0,typingId:typingMessageId.value}]:history$1});watch(processedOfferHistory,()=>{nextTick(()=>{if(offerChatContainer.value){let container=offerChatContainer.value;container.scrollHeight-container.scrollTop-container.clientHeight<100&&(container.scrollTop=container.scrollHeight)}})},{deep:!0});let scrollToBottom=()=>{nextTick(()=>{offerChatContainer.value&&(offerChatContainer.value.scrollTop=offerChatContainer.value.scrollHeight)})},reset$1=()=>{typingMessageId.value=null,previousOfferHistoryLength.value=(props.offerHistory||[]).length};return onMounted(()=>{reset$1(),scrollToBottom()}),__expose({scrollToBottom,reset:reset$1}),(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$122,[createBaseVNode(`div`,{ref_key:`offerChatContainer`,ref:offerChatContainer,class:`offer-chat-container`},[createVNode(TransitionGroup,{name:`message`,tag:`div`},{default:withCtx(()=>[(openBlock(!0),createElementBlock(Fragment,null,renderList(processedOfferHistory.value,(item,index)=>(openBlock(),createElementBlock(`div`,{key:item.typingId||`${item.myOffer||item.theirOffer||`message`}-${index}`,class:normalizeClass([`message`,item.messageClass])},[item.isTyping?(openBlock(),createElementBlock(`div`,_hoisted_2$102,[..._cache[0]||=[createBaseVNode(`span`,{class:`spinner`,"aria-label":`Typing`},null,-1),createTextVNode(` Typing... `,-1)]])):item.negotiationStatus===`failed`?(openBlock(),createElementBlock(`div`,_hoisted_3$90,[createVNode(unref(bngIcon_default),{type:`abandon`}),_cache[1]||=createTextVNode(` Negotiation failed! `,-1)])):item.negotiationStatus===`accepted`?(openBlock(),createElementBlock(`div`,_hoisted_4$70,[createVNode(unref(bngIcon_default),{type:`checkmark`,color:`var(--bng-add-green-400)`}),_cache[2]||=createTextVNode(` Accepted! `,-1)])):item.offerStatus?(openBlock(),createElementBlock(`div`,_hoisted_5$59,[item.offerStatus===`initial`?(openBlock(),createElementBlock(Fragment,{key:0},[createTextVNode(toDisplayString(props.amISelling?`Asking Price`:`Initial offer`),1)],64)):(openBlock(),createElementBlock(Fragment,{key:1},[createTextVNode(` Counter offer `)],64))])):item.negotiationStatus?(openBlock(),createElementBlock(`div`,_hoisted_6$46,toDisplayString(statusTextFromStatus(item.negotiationStatus)),1)):createCommentVNode(``,!0),!item.isTyping&&item.negotiationStatus!==`failed`&&item.negotiationStatus!==`accepted`?(openBlock(),createElementBlock(`div`,_hoisted_7$39,[createVNode(unref(bngUnit_default),{class:`money`,money:item.myOffer||item.theirOffer||0},null,8,[`money`])])):createCommentVNode(``,!0)],2))),128))]),_:1})],512)]))}},NegotiationChat_default=__plugin_vue_export_helper_default(_sfc_main$135,[[`__scopeId`,`data-v-c4558f29`]]),_hoisted_1$121={class:`price-finder-label right`},_hoisted_2$101={class:`price-finder-track`},_hoisted_3$89={key:0,class:`tick-label`},_hoisted_4$69={class:`price-finder-label left`},_sfc_main$134={__name:`PriceFinder`,props:{offerHistory:{type:Array,default:()=>[]},negotiationStatus:{type:String,default:``},startingPrice:{type:Number,default:0},offerPreview:{type:Number,default:0},actualVehicleValue:{type:Number,default:null},amISelling:{type:Boolean,default:!1}},setup(__props){let{units}=useBridge(),props=__props,priceFinderData=computed(()=>{let history$1=props.offerHistory||[];if(history$1.length===0)return null;let initialTheirOffer=null,initialMyOffer=null;for(let item of history$1)if(initialTheirOffer===null&&item.theirOffer!=null&&(initialTheirOffer=item.theirOffer),initialMyOffer===null&&item.myOffer!=null&&(initialMyOffer=item.myOffer),initialTheirOffer!==null&&initialMyOffer!==null)break;let hasBothInitialOffers=initialTheirOffer!==null&&initialMyOffer!==null;initialTheirOffer===null&&(initialTheirOffer=props.startingPrice),initialMyOffer===null&&(initialMyOffer=props.offerPreview||props.startingPrice);let offers=[],offerIndex=0,lastMyOfferIndex=-1,lastTheirOfferIndex=-1;for(let item of history$1)item.myOffer==null?item.theirOffer!=null&&(offers.push({price:item.theirOffer,isMyOffer:!1,index:offerIndex++,isUnsent:!1}),lastTheirOfferIndex=offers.length-1):(offers.push({price:item.myOffer,isMyOffer:!0,index:offerIndex++,isUnsent:!1}),lastMyOfferIndex=offers.length-1);props.negotiationStatus!==`failed`&&props.negotiationStatus!==`accepted`&&props.offerPreview>0&&(offers.push({price:props.offerPreview,isMyOffer:!0,index:offerIndex++,isUnsent:!0}),lastMyOfferIndex=offers.length-1);let leftPrice=Math.min(initialTheirOffer,initialMyOffer),rightPrice=Math.max(initialTheirOffer,initialMyOffer),topIsTheir=props.amISelling,range=rightPrice-leftPrice||1,{majorTicks,minorTicks}=((min$1,max$1,priceRange)=>{let niceNumbers=[1,2,5,10,20,50,100,200,500,1e3,2e3,5e3,1e4],tickRange=max$1-min$1;if(tickRange===0)return{majorTicks:[],minorTicks:[]};let roughStep=tickRange/4,magnitude=10**Math.floor(Math.log10(roughStep)),normalizedStep=roughStep/magnitude,closestNice=niceNumbers[0],minDiff=Math.abs(normalizedStep-closestNice);for(let nice of niceNumbers){let diff=Math.abs(normalizedStep-nice);diff=min$1&&price<=max$1){let position=(price-leftPrice)/priceRange*100;majorTicks$1.push({price,position:Math.max(0,Math.min(100,position))})}let minorStep=step/5,minorTicks$1=[];for(let price=niceMin;price<=niceMax;price+=minorStep)if(price>=min$1&&price<=max$1&&Math.abs(price%step)>.01){let position=(price-leftPrice)/priceRange*100;minorTicks$1.push({price,position:Math.max(0,Math.min(100,position))})}return{majorTicks:majorTicks$1,minorTicks:minorTicks$1}})(leftPrice,rightPrice,range),hasVisibleTicks=range>0&&majorTicks.length>0,offerPositions=offers.map((offer,index)=>{let position=(offer.price-leftPrice)/range*100,isMostRecent=offer.isMyOffer&&index===lastMyOfferIndex||!offer.isMyOffer&&index===lastTheirOfferIndex;return{...offer,position:Math.max(0,Math.min(100,position)),isMostRecent}}),marketValuePosition=null;if(hasVisibleTicks&&props.actualVehicleValue!=null&&props.actualVehicleValue>0&&props.actualVehicleValue>=leftPrice&&props.actualVehicleValue<=rightPrice){let position=(props.actualVehicleValue-leftPrice)/range*100;marketValuePosition=Math.max(0,Math.min(100,position))}let initialMarkers=[];if(hasVisibleTicks){let theirPosition=initialTheirOffer===leftPrice?0:100;initialMarkers.push({price:initialTheirOffer,isMyOffer:!1,position:theirPosition,isInitial:!0});let myPosition=initialMyOffer===leftPrice?0:100;initialMarkers.push({price:initialMyOffer,isMyOffer:!0,position:myPosition,isInitial:!0})}return{initialTheirOffer,initialMyOffer,leftPrice,rightPrice,topIsTheir,hasBothInitialOffers,majorTicks,minorTicks,offers:offerPositions,marketValuePosition,initialMarkers}});return(_ctx,_cache)=>priceFinderData.value?(openBlock(),createElementBlock(`div`,{key:0,class:normalizeClass([`price-finder-container`,{selling:__props.amISelling,buying:!__props.amISelling}])},[createBaseVNode(`div`,_hoisted_1$121,[createTextVNode(toDisplayString(priceFinderData.value.topIsTheir?`Your`:`Their`)+` Asking Price: `,1),createVNode(unref(bngUnit_default),{class:`money`,money:priceFinderData.value.rightPrice},null,8,[`money`])]),createBaseVNode(`div`,_hoisted_2$101,[(openBlock(!0),createElementBlock(Fragment,null,renderList(priceFinderData.value.minorTicks,(tick,index)=>(openBlock(),createElementBlock(`div`,{key:`minor-`+index,class:`price-finder-tick minor`,style:normalizeStyle({top:100-tick.position+`%`})},null,4))),128)),(openBlock(!0),createElementBlock(Fragment,null,renderList(priceFinderData.value.majorTicks,(tick,index)=>(openBlock(),createElementBlock(`div`,{key:`major-`+index,class:`price-finder-tick major`,style:normalizeStyle({top:100-tick.position+`%`})},[tick.position>5&&tick.position<95?(openBlock(),createElementBlock(`div`,_hoisted_3$89,toDisplayString(unref(units).beamBucks(tick.price)),1)):createCommentVNode(``,!0)],4))),128)),priceFinderData.value.hasBothInitialOffers?(openBlock(!0),createElementBlock(Fragment,{key:0},renderList(priceFinderData.value.offers,(offer,index)=>(openBlock(),createElementBlock(`div`,{key:index,class:normalizeClass([`price-finder-marker`,{"my-offer":offer.isMyOffer,"their-offer":!offer.isMyOffer,"most-recent":offer.isMostRecent,unsent:offer.isUnsent}]),style:normalizeStyle({top:100-offer.position+`%`})},[..._cache[0]||=[createBaseVNode(`div`,{class:`marker-triangle`},null,-1)]],6))),128)):createCommentVNode(``,!0),priceFinderData.value.marketValuePosition===null?createCommentVNode(``,!0):(openBlock(),createElementBlock(`div`,{key:1,class:`price-finder-marker market-value`,style:normalizeStyle({top:100-priceFinderData.value.marketValuePosition+`%`,bottom:`0`})},[..._cache[1]||=[createBaseVNode(`div`,{class:`marker-dot`},null,-1)]],4)),(openBlock(!0),createElementBlock(Fragment,null,renderList(priceFinderData.value.initialMarkers,(marker$1,index)=>(openBlock(),createElementBlock(`div`,{key:`initial-`+index,class:normalizeClass([`price-finder-marker`,{"my-offer":marker$1.isMyOffer,"their-offer":!marker$1.isMyOffer,initial:!0}]),style:normalizeStyle({top:100-marker$1.position+`%`})},[..._cache[2]||=[createBaseVNode(`div`,{class:`marker-triangle`},null,-1)]],6))),128))]),createBaseVNode(`div`,_hoisted_4$69,[createTextVNode(toDisplayString(priceFinderData.value.topIsTheir?`Their`:`Your`)+` initial offer: `,1),createVNode(unref(bngUnit_default),{class:`money`,money:priceFinderData.value.leftPrice},null,8,[`money`])])],2)):createCommentVNode(``,!0)}},PriceFinder_default=__plugin_vue_export_helper_default(_sfc_main$134,[[`__scopeId`,`data-v-ba044f86`]]),_hoisted_1$120={class:`center-wrap`},_hoisted_2$100={class:`header-row`},_hoisted_3$88={key:0,class:`header-seller-info`},_hoisted_4$68={class:`main-content`},_hoisted_5$58={class:`summary`},_hoisted_6$45={key:0,class:`vehicle-info`},_hoisted_7$38={class:`purchase-row`},_hoisted_8$31={class:`label`},_hoisted_9$28={class:`sub-info`},_hoisted_10$22={class:`price`},_hoisted_11$20={class:`offer-container`},_hoisted_12$15={class:`patience`},_hoisted_13$14={class:`label-row`},_hoisted_14$14={class:`offer-controls`},_hoisted_15$14={key:0,class:`offer-controls-row`},_hoisted_16$14={class:`step-buttons-group`},_hoisted_17$11={class:`resolved-negotiation-message`},_hoisted_18$9={class:`price-column`},_hoisted_19$7={key:0,class:`price`},_hoisted_20$6={key:1,class:`price`},_hoisted_21$6={class:`action-buttons wide`},_sfc_main$133={__name:`VehicleNegotiationMain`,setup(__props){useUINavScope(`vehicleNegotiation`);let{units}=useBridge(),events$3=useEvents(),router$1=useRouter(),state=ref({active:!1,startingPrice:0,patience:0,myOffer:null,theirOffer:0,thinking:!1,status:``,negotiationStatus:``,opponentName:``,vehicleNiceName:``,vehicleThumbnail:``,amISelling:!1}),opponent=computed(()=>state.value.amISelling?`Buyer`:`Seller`),biggerIsBetter=computed(()=>!!state.value.amISelling),increaseOfferDisabled=computed(()=>state.value.amISelling?state.value.myOffer!=null&&offerPreview.value>=state.value.myOffer:offerPreview.value>=state.value.theirOffer),decreaseOfferDisabled=computed(()=>state.value.amISelling?(console.log(`decreaseOfferDisabled`,offerPreview.value,state.value.theirOffer),offerPreview.value<=state.value.theirOffer):state.value.myOffer!=null&&offerPreview.value<=state.value.myOffer),offerPreview=ref(0);computed(()=>{let baseStep=state.value.startingPrice/500;return Math.round(baseStep/5)*5}),computed(()=>{let diff=(offerPreview.value-state.value.startingPrice)/state.value.startingPrice*100;return Math.round(diff)});let diffOfferPreviewToStarting=computed(()=>offerPreview.value-state.value.startingPrice),isDiffOfferPreviewToStartingGood=computed(()=>biggerIsBetter.value?diffOfferPreviewToStarting.value>=0:diffOfferPreviewToStarting.value<=0),diffPercentOfferPreviewToMarket=computed(()=>{if(!state.value.actualVehicleValue||state.value.actualVehicleValue===0)return null;let diff=(offerPreview.value-state.value.actualVehicleValue)/state.value.actualVehicleValue*100;return Math.round(diff)}),isDiffPercentOfferPreviewToMarketGood=computed(()=>diffPercentOfferPreviewToMarket.value===null?null:biggerIsBetter.value?diffPercentOfferPreviewToMarket.value>=0:diffPercentOfferPreviewToMarket.value<=0),diffTheirOfferToStarting=computed(()=>state.value.theirOffer-state.value.startingPrice);computed(()=>biggerIsBetter.value?diffTheirOfferToStarting.value>=0:diffTheirOfferToStarting.value<=0);let nudgeOffer=delta=>{let roundedOfferPreview=Math.max(0,Math.round((offerPreview.value+delta)/50)*50),min$1=0,max$1=1/0;state.value.amISelling?(min$1=state.value.theirOffer,state.value.myOffer!=null&&(max$1=state.value.myOffer)):(max$1=state.value.theirOffer,state.value.myOffer!=null&&(min$1=state.value.myOffer)),offerPreview.value=Math.min(max$1,Math.max(min$1,roundedOfferPreview))},offerDisabled=computed(()=>state.value.negotiationStatus===`thinking`||state.value.negotiationStatus===`typing`||state.value.negotiationStatus===`accepted`||state.value.negotiationStatus===`failed`),patienceClass=computed(()=>{let m=state.value.patience??0;return m>.66?`patience-good`:m>.33?`patience-mid`:`patience-bad`}),noDeal=computed(()=>state.value.negotiationStatus===`failed`&&state.value.amISelling);computed(()=>state.value.negotiationStatus===`failed`),computed(()=>{switch(String(state.value.negotiationStatus||``)){case`counterOffer`:return`Counter offer`;case`counterOfferLastChance`:return`Last chance counter offer`;case`accepted`:return`Accepted`;case`failed`:return`Negotiation failed`;case`refused`:return`Offer refused`;case`initial`:return`Initial offer`;case`thinking`:return`Thinking`;case`typing`:return`Typing...`;default:return``}});let resolvedStatusText=computed(()=>state.value.negotiationStatus===`failed`?state.value.amISelling?`The other party ran out of patience and does not want to buy this vehicle.`:`The other party ran out of patience. You can still buy the vehicle at the starting price: `:state.value.negotiationStatus===`accepted`?`Congratulations! You've successfully negotiatied a deal with `+state.value.opponentName+`.`:``),negotiationChat=ref(null),refresh$1=async()=>{state.value=await Lua_default.career_modules_marketplace.getNegotiationState()||state.value;let base=state.value.myOffer==null?state.value.startingPrice:state.value.myOffer;Number.isNaN(Number(base))||(offerPreview.value=Number(base)),state.value.negotiationStatus===`failed`&&(offerPreview.value=state.value.startingPrice)},submitOffer=async()=>{let price=Number(offerPreview.value);Number.isFinite(price)&&await Lua_default.career_modules_marketplace.makeNegotiationOffer(price)},takeOffer=async()=>{await Lua_default.career_modules_marketplace.takeTheirOffer(),state.value.negotiationStatus=`accepted`,state.value.status=`accepted`,offerPreview.value=state.value.theirOffer,state.value.iAccepted=!0,state.value.offerHistory.push({myOffer:state.value.theirOffer,negotiationStatus:`accepted`})},cancel=async()=>{state.value.negotiationStatus!==`accepted`&&await Lua_default.career_modules_marketplace.cancelNegotiation()},goBack=event=>{router$1.back(),state.value.negotiationStatus===`accepted`&&!state.value.iAccepted&&Lua_default.career_modules_marketplace.takeTheirOffer(),cancel(),event&&event.stopPropagation&&event.stopPropagation()};return events$3.on(`negotiationData`,data=>{refresh$1()}),onMounted(async()=>{await refresh$1(),nextTick(()=>{negotiationChat.value&&(negotiationChat.value.reset(),negotiationChat.value.scrollToBottom())})}),onUnmounted(async()=>{events$3.off(`negotiationData`)}),(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$120,[withDirectives((openBlock(),createBlock(unref(bngCard_default),{"bng-ui-scope":`vehicleNegotiation`,class:`negotiation-screen`},{buttons:withCtx(()=>[createBaseVNode(`div`,_hoisted_21$6,[state.value.negotiationStatus!==`accepted`&&state.value.negotiationStatus!==`failed`?(openBlock(),createBlock(unref(bngButton_default),{key:0,class:`submit-offer`,disabled:state.value.negotiationStatus===`counterOfferLastChance`||offerPreview.value==state.value.theirOffer||offerPreview.value==state.value.myOffer||offerDisabled.value,onClick:_cache[6]||=$event=>submitOffer(),accent:unref(ACCENTS).secondary},{default:withCtx(()=>[..._cache[16]||=[createTextVNode(` Submit This Offer `,-1)]]),_:1},8,[`disabled`,`accent`])):createCommentVNode(``,!0),state.value.negotiationStatus!==`accepted`&&state.value.negotiationStatus!==`failed`?withDirectives((openBlock(),createBlock(unref(bngButton_default),{key:1,class:`submit-offer`,disabled:state.value.negotiationStatus===`counterOfferLastChance`||offerDisabled.value,"show-hold":``},{default:withCtx(()=>[..._cache[17]||=[createTextVNode(` Agree to their Price `,-1)]]),_:1},8,[`disabled`])),[[unref(BngClick_default),{holdCallback:takeOffer,holdDelay:1e3,repeatInterval:0}]]):createCommentVNode(``,!0),state.value.negotiationStatus===`failed`||state.value.negotiationStatus===`accepted`?(openBlock(),createBlock(unref(bngButton_default),{key:2,class:`go-back`,accent:unref(ACCENTS).primary,onClick:goBack},{default:withCtx(()=>[createTextVNode(toDisplayString(state.value.amISelling?`Continue`:`Go to Purchase Screen`),1)]),_:1},8,[`accent`])):createCommentVNode(``,!0)])]),default:withCtx(()=>[createBaseVNode(`div`,_hoisted_2$100,[createVNode(unref(bngCardHeading_default),{type:`ribbon`},{default:withCtx(()=>[createTextVNode(` Negotiation with `+toDisplayString(state.value.opponentName||opponent.value)+` `,1),state.value.opponentQuote?(openBlock(),createElementBlock(`div`,_hoisted_3$88,` "`+toDisplayString(state.value.opponentQuote)+`" `,1)):createCommentVNode(``,!0)]),_:1}),createVNode(unref(bngButton_default),{class:`close-button`,onClick:goBack,accent:unref(ACCENTS).attention,"bng-no-nav":`true`,tabindex:`-1`},{default:withCtx(()=>[createVNode(unref(bngBinding_default),{"ui-event":`menu`,controller:``}),createVNode(unref(bngIcon_default),{type:`xmarkBold`,color:`var(--bng-cool-gray-100)`})]),_:1},8,[`accent`])]),createBaseVNode(`div`,_hoisted_4$68,[createBaseVNode(`div`,_hoisted_5$58,[state.value.vehicleNiceName||state.value.vehicleThumbnail?(openBlock(),createElementBlock(`div`,_hoisted_6$45,[createBaseVNode(`div`,_hoisted_7$38,[createBaseVNode(`div`,_hoisted_8$31,[createBaseVNode(`div`,null,toDisplayString(state.value.vehicleNiceName||`Vehicle`),1),createBaseVNode(`div`,_hoisted_9$28,toDisplayString(unref(units).buildString(`length`,state.value.vehicleMileage,0)),1)]),createBaseVNode(`div`,_hoisted_10$22,[_cache[7]||=createTextVNode(` Est. Market: `,-1),createBaseVNode(`div`,null,[createVNode(unref(bngUnit_default),{class:`money`,money:state.value.actualVehicleValue||0},null,8,[`money`])])])])])):createCommentVNode(``,!0)]),createBaseVNode(`div`,_hoisted_11$20,[createVNode(NegotiationChat_default,{ref_key:`negotiationChat`,ref:negotiationChat,"offer-history":state.value.offerHistory||[],"negotiation-status":state.value.negotiationStatus,"starting-price":state.value.startingPrice||0,"am-i-selling":state.value.amISelling},null,8,[`offer-history`,`negotiation-status`,`starting-price`,`am-i-selling`]),createVNode(PriceFinder_default,{"offer-history":state.value.offerHistory||[],"negotiation-status":state.value.negotiationStatus,"starting-price":state.value.startingPrice||0,"offer-preview":offerPreview.value||0,"actual-vehicle-value":state.value.actualVehicleValue,"am-i-selling":state.value.amISelling},null,8,[`offer-history`,`negotiation-status`,`starting-price`,`offer-preview`,`actual-vehicle-value`,`am-i-selling`])]),createBaseVNode(`div`,_hoisted_12$15,[createBaseVNode(`div`,{class:normalizeClass([`bar`,patienceClass.value])},[_cache[8]||=createBaseVNode(`div`,{class:`separator`,style:{left:`33.0%`}},null,-1),_cache[9]||=createBaseVNode(`div`,{class:`separator`,style:{left:`66.0%`}},null,-1),createBaseVNode(`div`,{class:normalizeClass([`fill`,patienceClass.value]),style:normalizeStyle({width:Math.max(0,Math.min(1,state.value.patience||0))*100+`%`})},null,6)],2),createBaseVNode(`div`,_hoisted_13$14,[createBaseVNode(`span`,null,toDisplayString(opponent.value)+`'s Patience`,1)])]),createBaseVNode(`div`,_hoisted_14$14,[state.value.negotiationStatus!==`failed`&&state.value.negotiationStatus!==`accepted`?(openBlock(),createElementBlock(`div`,_hoisted_15$14,[createBaseVNode(`div`,_hoisted_16$14,[createVNode(unref(bngButton_default),{class:`step step-large`,disabled:offerDisabled.value||decreaseOfferDisabled.value,onClick:_cache[0]||=$event=>nudgeOffer(-5e3)},{default:withCtx(()=>[..._cache[10]||=[createTextVNode(`-5000`,-1)]]),_:1},8,[`disabled`]),createVNode(unref(bngButton_default),{class:`step step-medium`,disabled:offerDisabled.value||decreaseOfferDisabled.value,onClick:_cache[1]||=$event=>nudgeOffer(-500)},{default:withCtx(()=>[..._cache[11]||=[createTextVNode(`-500`,-1)]]),_:1},8,[`disabled`]),createVNode(unref(bngButton_default),{class:`step`,disabled:offerDisabled.value||decreaseOfferDisabled.value,onClick:_cache[2]||=$event=>nudgeOffer(-50)},{default:withCtx(()=>[..._cache[12]||=[createTextVNode(`-50`,-1)]]),_:1},8,[`disabled`]),createVNode(unref(bngButton_default),{class:`step`,disabled:offerDisabled.value||increaseOfferDisabled.value,onClick:_cache[3]||=$event=>nudgeOffer(50)},{default:withCtx(()=>[..._cache[13]||=[createTextVNode(`+50`,-1)]]),_:1},8,[`disabled`]),createVNode(unref(bngButton_default),{class:`step step-medium`,disabled:offerDisabled.value||increaseOfferDisabled.value,onClick:_cache[4]||=$event=>nudgeOffer(500)},{default:withCtx(()=>[..._cache[14]||=[createTextVNode(`+500`,-1)]]),_:1},8,[`disabled`]),createVNode(unref(bngButton_default),{class:`step step-large`,disabled:offerDisabled.value||increaseOfferDisabled.value,onClick:_cache[5]||=$event=>nudgeOffer(5e3)},{default:withCtx(()=>[..._cache[15]||=[createTextVNode(`+5000`,-1)]]),_:1},8,[`disabled`])])])):createCommentVNode(``,!0),state.value.negotiationStatus===`failed`||state.value.negotiationStatus===`accepted`?(openBlock(),createElementBlock(`div`,{key:1,class:normalizeClass([`offer-controls-row`,{accepted:state.value.negotiationStatus===`accepted`,failed:state.value.negotiationStatus===`failed`}])},[createVNode(unref(bngIcon_default),{type:state.value.negotiationStatus===`accepted`?`checkmark`:`abandon`,class:`resolved-negotiation-icon`},null,8,[`type`]),createBaseVNode(`div`,_hoisted_17$11,toDisplayString(resolvedStatusText.value),1)],2)):createCommentVNode(``,!0),createBaseVNode(`div`,_hoisted_18$9,[noDeal.value?(openBlock(),createElementBlock(`div`,_hoisted_19$7,` NO DEAL `)):(openBlock(),createElementBlock(`div`,_hoisted_20$6,toDisplayString(unref(units).beamBucks(offerPreview.value||0)),1)),diffOfferPreviewToStarting.value===null?createCommentVNode(``,!0):(openBlock(),createElementBlock(`div`,{key:2,class:normalizeClass([`diff-percent-offer-preview-to-starting`,{positive:isDiffOfferPreviewToStartingGood.value&&diffOfferPreviewToStarting.value!==0,negative:!isDiffOfferPreviewToStartingGood.value&&diffOfferPreviewToStarting.value!==0,zero:diffOfferPreviewToStarting.value===0,hidden:noDeal.value}])},[diffOfferPreviewToStarting.value===0?createCommentVNode(``,!0):(openBlock(),createBlock(unref(bngUnit_default),{key:0,class:`money`,money:Math.abs(diffOfferPreviewToStarting.value)},null,8,[`money`])),createTextVNode(` `+toDisplayString(diffOfferPreviewToStarting.value<0?`under`:diffOfferPreviewToStarting.value>0?`over`:`Same as`)+` starting price `,1)],2)),diffPercentOfferPreviewToMarket.value===null?createCommentVNode(``,!0):(openBlock(),createElementBlock(`div`,{key:3,class:normalizeClass([`diff-percent-offer-preview-to-market`,{positive:isDiffPercentOfferPreviewToMarketGood.value,negative:!isDiffPercentOfferPreviewToMarketGood.value,hidden:noDeal.value}])},toDisplayString(Math.abs(diffPercentOfferPreviewToMarket.value))+`% `+toDisplayString(diffPercentOfferPreviewToMarket.value<0?`under`:`over`)+` Est. Market value `,3))])])])]),_:1})),[[unref(BngBlur_default),1]])]))}},VehicleNegotiationMain_default=__plugin_vue_export_helper_default(_sfc_main$133,[[`__scopeId`,`data-v-29ff8ba1`]]),routes_default$3=[{path:`/menu.careerPause`,name:`menu.careerPause`,component:Pause_default,props:!0,meta:{clickThrough:!0,infoBar:{withAngular:!0,visible:!0,showSysInfo:!0},uiApps:{shown:!1},topBar:{visible:!0}}},{path:`/career`,children:[{path:`chooseInsurance`,name:`chooseInsurance`,component:ChooseInsuranceMain_default},{path:`pauseBigMiddlePanel`,name:`pauseBigMiddlePanel`,component:PauseBigMiddlePanel_default,props:!0},{path:`logbook/:id(\\*?.*?)?`,name:`logbook`,component:Logbook_default,meta:{uiApps:{shown:!1}},props:!0},{path:`milestones/:id(\\*?.*?)?`,name:`milestones`,component:Milestones_default,props:!0,meta:{uiApps:{shown:!1}}},{path:`computer`,name:`computer`,component:ComputerMain_default,props:!0,meta:{uiApps:{shown:!1}}},{path:`vehicleInventory`,name:`vehicleInventory`,component:VehicleInventoryMain_default},{path:`vehiclePerformance/:inventoryId?`,name:`vehiclePerformance`,component:VehiclePerformanceMain_default,props:!0},{path:`tuning`,name:`tuning`,component:TuningMain_default},{path:`painting`,name:`painting`,component:PaintingMain_default},{path:`repair/:header?`,name:`repair`,component:RepairMain_default,props:!0},{path:`partShopping`,name:`partShopping`,component:PartShoppingMain_default,meta:{uiApps:{shown:!1}}},{path:`partInventory`,name:`partInventory`,component:PartInventoryMain_default},{path:`vehiclePurchase/:vehicleInfo?/:playerMoney?/:inventoryHasFreeSlot?/:lastVehicleInfo?`,name:`vehiclePurchase`,component:VehiclePurchaseMain_default,props:!0,meta:{uiApps:{shown:!1}}},{path:`negotiation`,name:`negotiation`,component:VehicleNegotiationMain_default},{path:`vehicleShopping/:screenTag?/:buyingAvailable?/:marketplaceAvailable?/:selectedSellerId?`,name:`vehicleShopping`,component:VehicleShoppingMain_default,props:!0,meta:{uiApps:{shown:!1}}},{path:`insurances`,name:`insurances`,component:InsurancesMain_default},{path:`playerAbstract`,name:`playerAbstract`,component:DriverAbstract_default},{path:`cargoDeliveryReward`,name:`cargoDeliveryReward`,component:CargoDeliveryReward_default,props:!0},{path:`cargoDropOff/:facilityId?/:parkingSpotPath(\\*?.*?)?`,name:`cargoDropOff`,component:CargoDropOff_default,props:!0},{path:`cargoOverview/:facilityId?/:parkingSpotPath(\\*?.*?)?`,name:`cargoOverview`,component:CargoOverviewMain_default,props:!0,meta:{uiApps:{shown:!1}}},{path:`myCargo`,name:`myCargo`,component:MyCargo_default,props:!0,meta:{uiApps:{shown:!1}}},{path:`progressLanding/:pathId?/:comesFromBigMap?`,name:`progressLanding`,component:ProgressLanding_default,props:route=>({pathId:route.params.pathId,comesFromBigMap:route.params.comesFromBigMap===`true`||route.params.comesFromBigMap===!0}),meta:{uiApps:{shown:!1},infoBar:{visible:!0}}},{path:`domainSelection`,name:`domainSelection`,component:ProgressLanding_default,props:!0,meta:{uiApps:{shown:!1},infoBar:{visible:!0}}},{path:`profiles`,name:`profiles`,component:Profiles_default,meta:{uiApps:{shown:!1},infoBar:{visible:!0,showSysInfo:!0}}}]}],data_default=[{translateId:`ui.credits.programmers`,members:[{first:`Thomas`,last:`Fischer`,aka:`tdev`,title:`CEO`},{first:`Lefteris`,last:`Stamatogiannakis`,aka:`estama`,title:`CTO / Physics / Sound / AI`},{first:`Luis`,last:`Anton Rebollo`,aka:`Souga`,title:`Lead Render Developer`},{first:`Alex`,last:`Spodheim`,aka:`CrankyCleric`,title:`Developer`},{first:`Ananda Neelam`,last:`Thathayya`,aka:`Nadeox1`,title:`Technical Artist`},{first:`Andrew`,last:`Kabakwu`,aka:``,title:`Developer`},{first:`Bruno`,last:`Gonzalez Campo`,aka:`stenyak`,title:`Lead Game Engine Developer`},{first:`Cosmin`,last:`Traian`,aka:``,title:`Developer`},{first:`Emre`,last:`Kut`,aka:``,title:`Developer`},{first:`Felix`,last:`Unger`,aka:``,title:`Developer`},{first:`George`,last:`Troulitakis`,aka:`AtmanB`,title:`Developer`},{first:`Guillem`,last:`Ortega`,aka:``,title:`Developer`},{first:`Logane`,last:`Ramez`,aka:`Gadoy`,title:`Developer`},{first:`Lorenzo`,last:`Bartali`,aka:``,title:`AI Developer`},{first:`Ludger`,last:`Meyer-Wülfing`,aka:`meywue`,title:`Developer`},{first:`Nicusor`,last:`Nedelcu`,aka:``,title:`Tools Developer`},{first:`Panos`,last:`Karabelas`,aka:``,title:`Developer`},{first:`Patrick `,last:`Schrangl`,aka:``,title:`Simulation Software Engineer`},{first:`Petros`,last:`Kondylis`,aka:``,title:`AI Developer`},{first:`Ronny`,last:`Nowak`,aka:``,title:`Developer`},{first:`Thomas`,last:`Portassau`,aka:`thomatoes50`,title:`Developer`},{first:`Thomas`,last:`Wilczynski`,aka:`Gamergull`,title:`Developer`},{first:`Timo`,last:`Stabbert`,aka:``,title:`Gameplay Dev Lead`},{first:`Valery`,last:`Dolotin`,aka:``,title:`AI Developer`},{first:`Daniel`,last:`Wakefield`,aka:``,title:`Developer`}]},{translateId:`ui.credits.vehiclePhysics`,members:[{first:`Fabian`,last:`Enkler`,aka:`Diamondback`,title:`Vehicle Systems Lead`},{first:`Angelo`,last:`Matteo`,aka:`angelo234`,title:`Tools Developer`},{first:`Aubrey`,last:`Percival`,aka:``,title:`Vehicle Physics Engineer`},{first:`Bobby`,last:`Villeneuve`,aka:`Binkey`,title:`Vehicle Physics Engineer`},{first:`Brian`,last:`Rickets`,aka:``,title:`Vehicle Systems Engineer`},{first:`Corey`,last:`Bergerud`,aka:`Goosah`,title:`Vehicle Physics Engineer`},{first:`Davide`,last:`Serpi`,aka:``,title:`Vehicle Dynamics Control Intern`},{first:`Efe Can`,last:`Kiraz`,aka:`RenAzuma66`,title:`Vehicle Physics Engineer`},{first:`Grzegorz`,last:`Węgrzyn`,aka:`AiTorror`,title:`Vehicle Physics Engineer / QA`},{first:`Jack`,last:`Jermany`,aka:``,title:`Vehicle Physics Engineer / QA`},{first:`Oliver`,last:`Čajka`,aka:`MRcrash`,title:`Vehicle Physics Engineer`},{first:`Piotr`,last:`Gajek`,aka:`Agent_Y`,title:`Vehicle Physics Engineer / QA`},{first:`Toma Ioan`,last:` Turcu`,aka:``,title:`Vehicle Physics Engineer`},{first:`Quinn`,last:`Howling`,aka:`SpeedHero`,title:`Vehicle Physics Designer`}]},{translateId:`ui.credits.vehicleArt`,members:[{first:`Gabriel`,last:`Fink`,aka:`gabester`,title:`Vehicle Art Director`},{first:`Jared`,last:`Samuelson`,aka:``,title:`Vehicle Team Lead / Subaru Expert`},{first:`Alexandr`,last:`Shesternin`,aka:``,title:`3D Vehicle Artist`},{first:`Andreas`,last:`Focht`,aka:``,title:`Vehicle Concept Artist`},{first:`Daniel`,last:`Russo`,aka:`A3DR`,title:`3D Vehicle Artist`},{first:`Dennis`,last:`Mateja`,aka:`NinetyNine`,title:`Vehicle Designer`},{first:`Manish`,last:`Rawat`,aka:``,title:`3D Vehicle Artist`}]},{translateId:`ui.credits.environmentArtists`,members:[{first:`Sam`,last:`Hutchinson`,aka:`LJFHutch`,title:`Environment Art Director`},{first:`Luca`,last:`Brighi`,aka:``,title:`Lead 3D Environment Artist`},{first:`Huiqin`,last:`Li`,aka:``,title:`3D Environment Artist`},{first:`Sebastien`,last:`Pelletier`,aka:`DoullPepper`,title:`3D Environment Artist`}]},{translateId:`ui.credits.conceptArtists`,members:[{first:`Mary Jane`,last:`Pajaron`,aka:``,title:`2D Concept Artist`}]},{translateId:`ui.credits.gameDesigners`,members:[{first:`James`,last:`Heslop`,aka:`Krallopian`,title:`Game Design Lead`},{first:`Alex`,last:`Bird`,aka:``,title:`Gameplay Developer`},{first:`Rob`,last:`Herridge`,aka:`HighDef`,title:`Gameplay Developer / QA`}]},{translateId:`ui.credits.ui`,members:[{first:`Pavel`,last:`Tiunov`,aka:`Dizboosta`,title:`UI Lead`},{first:`Destiny`,last:`Abellana`,aka:``,title:`Developer`},{first:`Stani`,last:`Tolmacheva`,aka:`Snowly`,title:`Developer`}]},{translateId:`ui.credits.sound`,members:[{first:`Mark`,last:`Knight`,aka:`TDK`,title:`Audio Designer`},{first:`Sebastian`,last:`Emling`,aka:``,title:`Audio Designer`},{first:`Jethro`,last:`Dunn`,aka:``,title:`Audio Outsourcer`},{first:`Max`,last:`Schumann`,aka:``,title:`Audio Outsourcer`}]},{translateId:`ui.credits.qa`,members:[{first:`Colin`,last:`Wenz`,aka:`synsol`,title:`QA Lead`},{first:`Przemysław`,last:`Wolny`,aka:`Car_Killer`,title:`QA / Mod Support`}]},{translateId:`ui.credits.production`,members:[{first:`Ryan`,last:`Dunne`,aka:``,title:`Producer`}]},{translateId:`ui.credits.sysops`,members:[{first:`Charalampos`,last:`Tsipizidis`,aka:``,title:`System Administrator`},{first:`Dimitrios`,last:`Folias`,aka:``,title:`System Administrator`}]},{translateId:`ui.credits.comms`,members:[{first:`Nataliia`,last:`Dmytriievska`,aka:`Leeloo`,title:`Communications & Marketing Lead`},{first:`Bernice`,last:`Mills`,aka:`Bee`,title:`Community Support & Marketing Specialist`},{first:`Mariia`,last:`Gumarova`,aka:`Fluffy Panda`,title:`Customer Support & Marketing Specialist`},{first:`Slawomir`,last:`Niemczyk`,aka:`Sedricoo`,title:`Community Coordinator`},{first:`Vincent`,last:`Liu`,aka:``,title:`Community & Marketing Specialist (APAC)`}]},{translateId:`ui.credits.research`,members:[{first:`Chrysanthi`,last:`Papamichail`,aka:``,title:`Lead Research Software Engineer`},{first:`Abdulrahman`,last:`Saeed`,aka:``,title:`Research Software Engineer`},{first:`Adam`,last:`Ivora`,aka:``,title:`Research Software Engineer`},{first:`David`,last:`Stark`,aka:``,title:`Research Software Engineer`},{first:`Florian`,last:`Faistauer`,aka:``,title:`Vehicle Simulation Expert`},{first:`Gabriel Puretas`,last:`Moral`,aka:``,title:`UX Intern`},{first:`Sayali`,last:`Rajhans`,aka:``,title:`Research Software Engineer`},{first:`Iskren`,last:`Rusimov`,aka:``,title:`Research Software Engineer Intern`}]},{translateId:`ui.credits.organization`,members:[{first:`Christoforos`,last:`Lambrianidis`,aka:``,title:`CFO`},{first:`Joseph`,last:`Inba Raj`,aka:``,title:`HR & Talent Acquisition Lead`},{first:`Cecilia`,last:`Sari`,aka:``,title:`Recruitment Specialist`},{first:`Dimitra`,last:`Litsardou`,aka:`Thamy`,title:`EU / Co-funding Advisory Specialist`},{first:`Eva`,last:`Pigova`,aka:``,title:`Senior Program Manager`},{first:`Maria`,last:`Kosmachevskaya`,aka:``,title:`Business Development Intern`},{first:`Özge`,last:`Altinkaya Erkok`,aka:``,title:`Communication Consultant`},{first:`Renars`,last:`Skesteris`,aka:``,title:`Business Development Intern`},{first:`Sabrina`,last:`Wee`,aka:``,title:`Business Development Manager`},{first:`Sandra`,last:`Campos`,aka:``,title:`Accounting Assistant`},{first:`Ulrike`,last:`Lentz`,aka:``,title:`Executive Assistant`}]},{translateId:`ui.credits.additionalVehiclePhysics`,members:[{first:`Will`,last:`Leader`,aka:``,title:`Off-road Suspension Development and Vehicle Dynamics`}]},{translateId:`ui.credits.additionalVehicleArt`,members:[{first:`Ashish`,last:`Singh`,aka:``,title:`Freelance 3D Vehicle Artist`},{first:`Juan Manuel`,last:`Orcellet`,aka:``,title:`Freelance 3D Vehicle Artist`},{first:`M. Yusuf`,last:`Bolukbasi`,aka:``,title:`Freelance Vehicle Artist`},{first:`Naman`,last:`Deep`,aka:``,title:`Freelance 3D Vehicle Artist`}]},{translateId:`ui.credits.externalContributors`,members:[{first:`Da`,last:`Li`,aka:``,title:``},{first:`Ruhmit`,last:`Sahu `,aka:``,title:``}]},{translateId:`ui.credits.formerEmployee`,members:[{first:`Aaron`,last:`Sutcliffe`,aka:``,title:`Developer / Vehicle Creation`},{first:`Alex`,last:`Raskin`,aka:``,title:`DevOps Engineer`},{first:`Artem`,last:`Arbatskii`,aka:``,title:`Developer`},{first:`Arturo`,last:`Campos`,aka:``,title:`Developer`},{first:`Ben`,last:`Payne`,aka:``,title:`Developer`},{first:`Boluwatife`,last:`Falaye`,aka:``,title:`Developer`},{first:`Clément`,last:`Roche`,aka:``,title:`Developer`},{first:`Edelmar`,last:`Schneider`,aka:``,title:`Developer`},{first:`Eike`,last:`Externest`,aka:``,title:`Developer`},{first:`Jali`,last:`Hautala`,aka:`Jalkku`,title:`Developer`},{first:`Jeremy`,last:`Lu`,aka:``,title:`Developer`},{first:`John`,last:`Beinecke`,aka:``,title:`Developer`},{first:`Juan`,last:`Mendez`,aka:``,title:`Developer`},{first:`Leander`,last:`Beernaert`,aka:``,title:`Game Engine Developer`},{first:`Marc`,last:`Müller`,aka:``,title:`Developer`},{first:`Mark`,last:`Vince`,aka:``,title:`Developer`},{first:`Matti`,last:`Yrjänheikki`,aka:`Masa`,title:`Developer`},{first:`Max`,last:`Razer`,aka:``,title:`Developer`},{first:`Mayowa David`,last:`Abogunrin`,aka:``,title:`Developer`},{first:`Moncef`,last:`Slimane`,aka:``,title:`Developer`},{first:`Nourelhoda`,last:`Mohamed`,aka:``,title:`Developer`},{first:`Pascale`,last:`Maul`,aka:``,title:`Developer`},{first:`Paul`,last:`De Almeida`,aka:``,title:`AI Developer`},{first:`Paul`,last:`Görs`,aka:``,title:`Developer`},{first:`Peter`,last:`Landwehr`,aka:``,title:`Developer`},{first:`Petteri`,last:`Koivumäki`,aka:``,title:`Developer`},{first:`Vasilis`,last:`Douvaras`,aka:``,title:`Developer`},{first:`Vatroslav `,last:`Bodrozic`,aka:``,title:`Developer`},{first:`Waldemar`,last:`Zeitler`,aka:``,title:`Developer`},{first:`Xiaoyi`,last:`Wang`,aka:``,title:`Developer`},{first:``,last:``,aka:``,title:``},{first:`Adrian`,last:`Baboi`,aka:``,title:`Vehicle Creation`},{first:`Brandon`,last:`Proulx`,aka:`Hondune`,title:`Vehicle Creation`},{first:`Carlos`,last:`Bergillos Varela`,aka:`CarlosAir`,title:`Content Creation`},{first:`David`,last:`Thurlbeck`,aka:``,title:`Vehicle Creation`},{first:`Janne`,last:`Nummela`,aka:``,title:`Vehicle Creation`},{first:`Jukka`,last:`Muikkula`,aka:`Miura`,title:`Vehicle Creation`},{first:`Karol`,last:`Miklas`,aka:``,title:`Freelance 3D Vehicle Artist`},{first:`Mardem`,last:`Pires das Dores`,aka:``,title:`Vehicle Creation`},{first:`Mikko`,last:`Lesonen`,aka:``,title:`Vehicle Creation`},{first:`Renju`,last:`Therakathu`,aka:``,title:`Vehicle Creation`},{first:`Sam`,last:`Millington`,aka:`DrowsySam`,title:`Vehicle Creation / Support`},{first:`Sebastian`,last:`Wessel`,aka:``,title:`Vehicle Creation`},{first:`Virtual Mechanix`,last:``,aka:``,title:`Vehicle Creation - Outsourcing Agency`},{first:`Winston`,last:`Broderick`,aka:``,title:`Vehicle Creation`},{first:`Mitchell`,last:`Sahl`,aka:`B25Mitch`,title:`3D Vehicle / Environment Artist`},{first:``,last:``,aka:``,title:``},{first:`Christin`,last:`Walther`,aka:``,title:`Lead 3D Artist`},{first:`Justin`,last:`Roczniak`,aka:`Donoteat`,title:`Environment Artist`},{first:`Lisa`,last:`Steinberg`,aka:``,title:`2D Artist`},{first:`Moses`,last:`Mulinge`,aka:``,title:`2D Artist`},{first:``,last:``,aka:``,title:``},{first:`Barend`,last:`van der Meulen`,aka:``,title:`Content Creator`},{first:`Matthias`,last:`Niebergall`,aka:``,title:`Game Designer`},{first:`SanityCheckMyGame`,last:``,aka:``,title:`Additional Design`},{first:``,last:``,aka:``,title:``},{first:`Georgios`,last:`Siantikos`,aka:`gntikos`,title:`User Interface`},{first:`Jonathan`,last:`Randy`,aka:``,title:`Lead Developer`},{first:`Mirco`,last:`Weigel`,aka:`theshark`,title:`User Interface`},{first:`Svetlozar`,last:`Valchev`,aka:``,title:`User Interface`},{first:`Theodoros`,last:`Manouilidis`,aka:``,title:`User Interface`},{first:`Yale`,last:`Hartmann`,aka:``,title:`User Interface`},{first:``,last:``,aka:``,title:``},{first:`Arend`,last:`Stührmann`,aka:``,title:`Producer`},{first:`Marie Cécile`,last:`Jacq`,aka:``,title:`Producer`},{first:`Nhung Van`,last:`Ho`,aka:``,title:`Project Management`},{first:``,last:``,aka:``,title:``},{first:`Bhavinkumar Babulal`,last:`Arya`,aka:``,title:`Research Software Engineer`},{first:`Carol`,last:`Halim`,aka:`Carotte`,title:`Research Software Engineer`},{first:`Elmar`,last:`Berghöfer`,aka:``,title:`Research`},{first:`Mattia`,last:`Vicari`,aka:``,title:`Research Software Engineer`},{first:``,last:``,aka:``,title:``},{first:`Camila`,last:`Navia`,aka:``,title:`Operations Assistant`},{first:`Danish`,last:`Abbasi`,aka:``,title:`Business Development Intern`},{first:`Lucien`,last:`Frei`,aka:``,title:`Business Development Intern`},{first:`Weiwei`,last:`Kong`,aka:``,title:`Business Development Intern`},{first:`Özgen`,last:`Saatçilar`,aka:``,title:`Communications Consultant`},{first:`Saskia`,last:`Opitz`,aka:``,title:`Administration`},{first:``,last:``,aka:``,title:``},{first:`Hala`,last:`Mahmoud`,aka:``,title:`Quality Assurance`},{first:`Jan Niklas`,last:`Hasse`,aka:``,title:`Quality Assurance`},{first:`Kamil`,last:`Kozak`,aka:``,title:`Quality Assurance`},{first:`Kemisola`,last:`Adeniyi`,aka:``,title:`Quality Assurance`},{first:`Kaja`,last:`Jambrek`,aka:``,title:`Quality Assurance`},{first:`Rajinder`,last:`Rajinder`,aka:``,title:`Quality Assurance`},{first:`Safdar`,last:`Mahmood`,aka:``,title:`Quality Assurance`},{first:`Uros`,last:`Sakic`,aka:`Uki`,title:`QA / Mod Support / Tools QA`},{first:``,last:``,aka:``,title:``},{first:`Konstantinos`,last:`Stamou`,aka:``,title:`System Administrator`},{first:``,last:``,aka:``,title:``},{first:`Erik`,last:`Heldt`,aka:``,title:`Documentation`},{first:`Maxime`,last:`Desharnais`,aka:``,title:`Documentation`},{first:`Harm`,last:`Schulz`,aka:``,title:`Student Assistant`},{first:`Annisa`,last:`Utami`,aka:``,title:`Student Assistant`},{first:`Brandon`,last:`Lynch`,aka:`Chuck_Norris_`,title:`Community Coordinator`},{first:`Monica`,last:`Huang`,aka:``,title:`Community Coordinator`}]},{translateId:`ui.credits.ourAwesomeCommunity`,members:[{first:`Daniel`,last:`Jones`,aka:`daniel_j`},{first:`Dennis`,last:`Wrekenhorst`,aka:`Dennis-W`},{first:`Dustin`,last:`Kutchara`,aka:`dkutch`},{first:`Kristian`,last:`Fagerland`,aka:``},{first:`Richard`,last:`Sixsmith`,aka:`Metalmuncher`},{first:`Sergy`,last:`Karpowicz`,aka:`0xsergy`},{first:`Sven`,last:`Nabeck`,aka:`sputnik_1`},{first:`Tom`,last:`Verhoeve`,aka:`Mythbuster`},{first:`Yannis`,last:`Vaiopoulos`,aka:`JohnV`},{first:``,last:``,aka:`Fufsgfen`}]},{translateId:`ui.credits.specialThanksTo`,members:[{first:`Luis`,last:`Placid`,aka:``,title:`VFX Developer`},{first:`Pierre-Michel`,last:`Ricordel`,aka:`pricorde`}]},{translateId:`ui.credits.soundtrack`,members:[{first:`Gabriel "gabester" Fink`,last:`Copyright 2014`,aka:`Lonle`},{first:`Mark "TDK" Knight`,last:`Copyright 2018`,aka:`Element No. 10`},{first:`Mark "TDK" Knight`,last:`Copyright 2018`,aka:`Getting Away`},{first:`Mark "TDK" Knight`,last:`Copyright 2018`,aka:`Juno Rocks`},{first:`Mark "TDK" Knight`,last:`Copyright 2018`,aka:`Neon Night Racer`},{first:`Mark "TDK" Knight`,last:`Copyright 2018`,aka:`Night Driver`}]},{translateId:`ui.credits.madePossibleWith`,members:[{first:`FMOD Studio by Firelight Technologies Pty Ltd.`,last:``,aka:``},{first:`LuaJIT`,last:``,aka:``},{first:`lua-intf, LuaBridge`,last:``,aka:``},{first:`Chromium Embedded Framework`,last:``,aka:``},{first:`AngularJS`,last:``,aka:``},{first:`Vue.js`,last:``,aka:``},{first:`Material Design`,last:``,aka:``},{first:`LuaSocket`,last:``,aka:``},{first:`Dear ImGui`,last:``,aka:``},{first:`Blender ®`,last:`www.blender.org`,aka:``}]},{translateId:``,members:[{first:`“DUALSHOCK” and “DualSense” are registered trademarks or trademarks of Sony Interactive Entertainment Inc. Library programs for DUALSHOCK®4 and DualSense™ wireless controllers © 2022 Sony Interactive Entertainment Inc.`,last:``,aka:``}]}],_hoisted_1$119={class:`bng-credits-content`},_hoisted_2$99=[`src`],_hoisted_3$87={class:`category`},_hoisted_4$67={class:`credits-table`},_hoisted_5$57={class:`member-cell member-name`},_hoisted_6$44={key:0,class:`aka`},_hoisted_7$37={key:1},_hoisted_8$30={key:0,class:`member-cell member-dot`},_hoisted_9$27={key:1},_hoisted_10$21={key:2,class:`member-cell member-role`},_hoisted_11$19={key:3},_sfc_main$132={__name:`CreditsScroller`,setup(__props){useUINavScope(`credits`);let imageURL=getAssetURL(`images/logos.svg#bng-drive-white`),wrapper=ref(),running=!0,exit=()=>{running=!1,Lua_default.extensions.unload(`ui_credits`),Lua_default.scenetree[`maincef:setMaxFPSLimit`](30),window.bngVue.gotoAngularState(`menu.mainmenu`)};onMounted(()=>{Lua_default.extensions.load(`ui_credits`),Lua_default.scenetree[`maincef:setMaxFPSLimit`](60),wrapper.value.focus(),scrollContainer(wrapper.value,65,exit)}),onUnmounted(()=>{exit()});function scrollContainer(container,pxPerSecond){let scrollSpeed=pxPerSecond/1e3,currentPos=0,lastTime=0,smoother=0;window.requestAnimationFrame(function step(timestamp){let delta=Math.min(150,Math.max(0,timestamp-lastTime));smoother+=(delta-smoother)*.02;let moveDelta=smoother*scrollSpeed;lastTime=timestamp,currentPos+=moveDelta;let targetPos=container.scrollHeight-container.clientHeight;running&¤tPoswithDirectives((openBlock(),createElementBlock(`div`,{ref_key:`wrapper`,ref:wrapper,class:`bng-credits-wrapper`,tabindex:`0`,onKeypress:exit,"bng-ui-scope":`credits`},[createBaseVNode(`div`,_hoisted_1$119,[createBaseVNode(`img`,{class:`logo`,src:unref(imageURL),alt:``},null,8,_hoisted_2$99),(openBlock(!0),createElementBlock(Fragment,null,renderList(unref(data_default),(category,cIndex)=>(openBlock(),createElementBlock(`div`,{key:cIndex},[createBaseVNode(`div`,_hoisted_3$87,[createBaseVNode(`span`,null,toDisplayString(_ctx.$t(category.translateId)),1)]),createBaseVNode(`div`,_hoisted_4$67,[(openBlock(!0),createElementBlock(Fragment,null,renderList(category.members,(member,mIndex)=>(openBlock(),createElementBlock(`div`,{class:`member-row`,key:mIndex},[createBaseVNode(`span`,_hoisted_5$57,[createTextVNode(toDisplayString(member.first)+` `,1),member.aka?(openBlock(),createElementBlock(`span`,_hoisted_6$44,toDisplayString(`<`+member.aka+`>`),1)):(openBlock(),createElementBlock(`span`,_hoisted_7$37,`\xA0`)),createTextVNode(` `+toDisplayString(member.last),1)]),member.title?(openBlock(),createElementBlock(`span`,_hoisted_8$30,` . `)):(openBlock(),createElementBlock(`span`,_hoisted_9$27,`\xA0`)),member.title?(openBlock(),createElementBlock(`span`,_hoisted_10$21,toDisplayString(_ctx.$t(member.title)),1)):(openBlock(),createElementBlock(`span`,_hoisted_11$19,`\xA0`))]))),128))])]))),128)),_cache[0]||=createBaseVNode(`div`,{style:{"padding-top":`70vh`}},null,-1)])],32)),[[unref(BngOnUiNav_default),exit,`menu,back`]])}},CreditsScroller_default=__plugin_vue_export_helper_default(_sfc_main$132,[[`__scopeId`,`data-v-9c2fdcd3`]]),routes_default$4=[{path:`/credits`,name:`credits`,component:CreditsScroller_default}],_hoisted_1$118={class:`details`,"bng-nav-scroll":``},_hoisted_2$98={key:0,class:`header-content`},_hoisted_3$86={key:1,class:`preview`},_hoisted_4$66={key:2,class:`tags-section`},_hoisted_5$56={class:`tags-container`},_hoisted_6$43=[`onClick`],_hoisted_7$36=[`src`],_hoisted_8$29={key:3,class:`description`},_hoisted_9$26={key:0,class:`specs-grid`},_hoisted_10$20={class:`specs-grid-container`},_hoisted_11$18={class:`spec-content`},_hoisted_12$14={class:`spec-label`},_hoisted_13$13={class:`spec-value`},_hoisted_14$13={key:0,class:`bottom-section`},_hoisted_15$13={class:`buttons-section`},_hoisted_16$13={key:1,class:`button-container`},_sfc_main$131={__name:`GameplayDetails`,props:{activeItem:{type:Object,default:null},activeItemDetails:{type:Object,default:null},executeButton:{type:Function,default:()=>{}},toggleFavourite:{type:Function,default:()=>{}},exploreFolder:{type:Function,default:()=>{}},goToMod:{type:Function,default:()=>{}},showHeaderTitle:{type:Boolean,default:!0},inline:{type:Boolean,default:!1},buttonOverride:{type:Object,default:null}},setup(__props){let props=__props,handleButtonClick=buttonId=>{props.executeButton(buttonId)};return(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,{class:normalizeClass([`gameplay-details`,{inline:__props.inline}])},[withDirectives((openBlock(),createElementBlock(`div`,_hoisted_1$118,[__props.activeItemDetails?.headerTitle?(openBlock(),createElementBlock(`div`,_hoisted_2$98,[__props.showHeaderTitle?(openBlock(),createBlock(unref(bngCardHeading_default),{key:0,type:`none`,class:`header-title`},{default:withCtx(()=>[createTextVNode(toDisplayString(__props.activeItemDetails.headerTitle),1)]),_:1})):createCommentVNode(``,!0),__props.activeItemDetails?.preview?(openBlock(),createElementBlock(`div`,_hoisted_3$86,[createVNode(unref(aspectRatio_default),{class:normalizeClass([`preview-image`,{"has-header-title":__props.showHeaderTitle}]),ratio:`16:8`,"external-image":__props.activeItemDetails.preview},{default:withCtx(()=>[__props.inline?createCommentVNode(``,!0):(openBlock(),createBlock(unref(bngIcon_default),{key:0,class:`favourite-icon`,type:__props.activeItemDetails?.isFavourite?`star`:`starSecondary`,onClick:_cache[0]||=$event=>__props.toggleFavourite(__props.activeItem),color:__props.activeItemDetails?.isFavourite?`var(--bng-ter-yellow-50)`:`var(--bng-cool-gray-100)`},null,8,[`type`,`color`]))]),_:1},8,[`external-image`,`class`])])):createCommentVNode(``,!0),__props.activeItemDetails?.tags?.length>0?(openBlock(),createElementBlock(`div`,_hoisted_4$66,[createBaseVNode(`div`,_hoisted_5$56,[(openBlock(!0),createElementBlock(Fragment,null,renderList(__props.activeItemDetails.tags,tag=>(openBlock(),createElementBlock(`div`,{key:tag.key||tag.label,class:normalizeClass([`tag-item`,{clickable:tag.goToMod}]),onClick:$event=>tag.goToMod?__props.goToMod(tag.goToMod):null},[tag.icon?(openBlock(),createBlock(unref(bngIcon_default),{key:0,type:tag.icon},null,8,[`type`])):createCommentVNode(``,!0),tag.svg?(openBlock(),createElementBlock(`img`,{key:1,class:`svg-icon`,src:tag.svg},null,8,_hoisted_7$36)):createCommentVNode(``,!0),createTextVNode(` `+toDisplayString(tag.label),1)],10,_hoisted_6$43))),128))])])):createCommentVNode(``,!0),__props.activeItemDetails?.description?(openBlock(),createElementBlock(`div`,_hoisted_8$29,toDisplayString(__props.activeItemDetails.description),1)):createCommentVNode(``,!0)])):createCommentVNode(``,!0),__props.activeItemDetails?.buttonInfo?.length>0||__props.activeItemDetails?.bottomTags?.length>0?(openBlock(!0),createElementBlock(Fragment,{key:1},renderList(__props.activeItemDetails?.specifications,(specList,specListIndex)=>(openBlock(),createElementBlock(Fragment,{key:specListIndex},[specList.length>0?(openBlock(),createElementBlock(`div`,_hoisted_9$26,[createBaseVNode(`div`,_hoisted_10$20,[(openBlock(!0),createElementBlock(Fragment,null,renderList(specList,specification=>(openBlock(),createElementBlock(`div`,{key:specification.key,class:`spec-cell`},[specification.icon?(openBlock(),createBlock(unref(bngIcon_default),{key:0,type:specification.icon,class:`spec-icon`},null,8,[`type`])):createCommentVNode(``,!0),createBaseVNode(`div`,_hoisted_11$18,[createBaseVNode(`div`,_hoisted_12$14,toDisplayString(specification.label)+`:`,1),createBaseVNode(`div`,_hoisted_13$13,[createBaseVNode(`span`,null,toDisplayString(specification.value),1)])])]))),128))])])):createCommentVNode(``,!0)],64))),128)):createCommentVNode(``,!0)])),[[unref(BngUiNavScroll_default),void 0,void 0,{force:!0}]]),__props.activeItemDetails?.buttonInfo?.length>0||__props.buttonOverride?(openBlock(),createElementBlock(`div`,_hoisted_14$13,[createBaseVNode(`div`,_hoisted_15$13,[__props.buttonOverride?createCommentVNode(``,!0):(openBlock(!0),createElementBlock(Fragment,{key:0},renderList(__props.activeItemDetails.buttonInfo,button=>(openBlock(),createElementBlock(`div`,{key:button.buttonId,class:`button-container`},[createVNode(unref(bngButton_default),{"bng-scoped-nav-autofocus":button.primary,accent:button.primary?`main`:`secondary`,label:button.label,icon:button.icon,onClick:$event=>handleButtonClick(button.buttonId)},null,8,[`bng-scoped-nav-autofocus`,`accent`,`label`,`icon`,`onClick`])]))),128)),__props.buttonOverride?(openBlock(),createElementBlock(`div`,_hoisted_16$13,[createVNode(unref(bngButton_default),{"bng-scoped-nav-autofocus":!0,accent:`main`,label:__props.buttonOverride.label,icon:__props.buttonOverride.icon,onClick:_cache[1]||=$event=>__props.buttonOverride.click(__props.activeItem)},null,8,[`label`,`icon`])])):createCommentVNode(``,!0)])])):createCommentVNode(``,!0)],2))}},GameplayDetails_default=__plugin_vue_export_helper_default(_sfc_main$131,[[`__scopeId`,`data-v-7baeb809`]]),_hoisted_1$117=[`bng-ui-scope`],_hoisted_2$97={class:`popup-content`},_hoisted_3$85={class:`modal-header`},_hoisted_4$65={class:`vehicle-selector-section`},_hoisted_5$55={class:`vehicle-tile-wrapper`},_hoisted_6$42={class:`modal-content`},_hoisted_7$35={class:`spawnpoint-section`},_hoisted_8$28={class:`spawnpoint-info`},_hoisted_9$25={key:0,class:`spawnpoint-preview`},_hoisted_10$19=[`src`],_hoisted_11$17={class:`spawnpoint-name`},_hoisted_12$13={key:0,class:`config-section`},_hoisted_13$12={class:`group-title`},_hoisted_14$12={key:0},_hoisted_15$12={class:`always-show-section`},_hoisted_16$12={key:0,class:`modal-footer`},_sfc_main$130={__name:`LevelConfigurationModal`,props:{levelData:{type:Object,required:!0}},emits:[`return`],setup(__props,{emit:__emit}){useUINavBlocker().allowNavigationOnly();let{lua,events:events$3}=useBridge(),props=__props,emit$1=__emit,scopeName=usePopupUINavScopeName(`_levelConfigPopup`,props);provide(`gridSelectionState`,ref(null));let spawningOptions=ref([]),config=reactive({}),alwaysShowDialogue=ref(!1),vehicleTile=ref({}),loadSpawningOptions=async()=>{try{let levelName=props.levelData?.levelName,backendName=props.levelData?.backendName,result=await lua.ui_gameplaySelector_tileGenerators_levelTiles.getSpawningOptions(levelName,backendName);if(result){let options=result.options||[];spawningOptions.value=options,alwaysShowDialogue.value=result.alwaysShowDialogue||!1,result.vehicleTile?vehicleTile.value={key:`vehicle-selector`,name:result.vehicleTile.name||`Select Vehicle`,preview:result.vehicleTile.preview||`/ui/modules/vehicleSelector/placeholder.png`,sourceIcons:result.vehicleTile.sourceIcons||[]}:vehicleTile.value={key:`vehicle-selector`,name:`Select Vehicle`,preview:`/ui/modules/vehicleSelector/placeholder.png`,sourceIcons:[]},options.forEach(group=>{group.options&&Array.isArray(group.options)&&group.options.forEach(option=>{option.key&&option.value!==void 0&&(config[option.key]=option.value)})})}}catch(error){console.error(`Failed to load spawning options:`,error)}},handleOptionChange=async(key,newValue)=>{try{await lua.ui_gameplaySelector_tileGenerators_levelTiles.changeSpawningOption(key,newValue),events$3.emit(`gridSelectorRefreshCurrentItemDetails`,`freeroamSelector`)}catch(error){console.error(`Failed to update ${key} option:`,error)}},handleAlwaysShowDialogueChange=async newValue=>{try{let backendName=props.levelData?.backendName;await lua.ui_gameplaySelector_tileGenerators_levelTiles.setAlwaysShowDialogue(backendName,newValue),events$3.emit(`gridSelectorRefreshCurrentItemDetails`,`freeroamSelector`)}catch(error){console.error(`Failed to save default action preference:`,error)}},openVehicleSelector=async()=>{try{await lua.ui_vehicleSelector_general.openVehicleSelectorForFreeroamModal(),emit$1(`return`,!0)}catch(e){console.error(`Failed to open vehicle selector:`,e)}};onMounted(()=>{loadSpawningOptions()});let closeModal=()=>{emit$1(`return`,!1)},handleButtonClick=buttonId=>{closeModal(),events$3.emit(`gridSelectorExecuteButton`,`freeroamSelector`,buttonId)},handleCancelWithBack=()=>{closeModal()};return(_ctx,_cache)=>withDirectives((openBlock(),createElementBlock(`div`,{class:`level-configuration-modal popup`,"bng-ui-scope":unref(scopeName)},[createBaseVNode(`div`,_hoisted_2$97,[createBaseVNode(`div`,_hoisted_3$85,[_cache[1]||=createBaseVNode(`h2`,null,`Freeroam Spawning Options`,-1),createVNode(unref(bngIcon_default),{type:`xmarkBold`,class:`close-button`,onClick:closeModal,color:`var(--bng-cool-gray-100)`})]),createBaseVNode(`div`,_hoisted_4$65,[_cache[2]||=createBaseVNode(`h3`,{class:`group-title`},`Vehicle`,-1),createBaseVNode(`div`,_hoisted_5$55,[createTextVNode(toDisplayString(vehicleTile.value)+` `,1),createVNode(Tile_default,{tile:vehicleTile.value,displaySize:`small`,isConfig:!0,onClick:openVehicleSelector},null,8,[`tile`])])]),createBaseVNode(`div`,_hoisted_6$42,[createBaseVNode(`div`,_hoisted_7$35,[_cache[3]||=createBaseVNode(`h3`,null,`Selected Spawnpoint`,-1),createBaseVNode(`div`,_hoisted_8$28,[__props.levelData?.spawnPoint?.previews?.[0]?(openBlock(),createElementBlock(`div`,_hoisted_9$25,[createBaseVNode(`img`,{src:__props.levelData.spawnPoint.previews[0],alt:`Spawnpoint preview`},null,8,_hoisted_10$19)])):createCommentVNode(``,!0),createBaseVNode(`div`,_hoisted_11$17,toDisplayString(_ctx.$tt(__props.levelData?.spawnPoint?.translationId||`No Name?`)),1)])]),spawningOptions.value.length>0?(openBlock(),createElementBlock(`div`,_hoisted_12$13,[(openBlock(!0),createElementBlock(Fragment,null,renderList(spawningOptions.value,group=>(openBlock(),createElementBlock(`div`,{class:`config-group`,key:group.name},[createBaseVNode(`h3`,_hoisted_13$12,toDisplayString(group.name),1),(openBlock(!0),createElementBlock(Fragment,null,renderList(group.options,option=>(openBlock(),createElementBlock(`div`,{class:`config-item`,key:option.key},[option.label?(openBlock(),createElementBlock(`label`,_hoisted_14$12,[option.icon?(openBlock(),createBlock(unref(bngIcon_default),{key:0,type:option.icon,class:`option-icon`},null,8,[`type`])):createCommentVNode(``,!0),createTextVNode(` `+toDisplayString(option.label)+`: `,1)])):createCommentVNode(``,!0),createVNode(unref(bngSelect_default),{modelValue:config[option.key],"onUpdate:modelValue":[$event=>config[option.key]=$event,newValue=>handleOptionChange(option.key,newValue)],options:option.options,loop:``,config:{value:opt=>opt.value,label:opt=>opt.label}},null,8,[`modelValue`,`onUpdate:modelValue`,`options`,`config`])]))),128))]))),128))])):createCommentVNode(``,!0)]),createBaseVNode(`div`,_hoisted_15$12,[createVNode(unref(bngSwitch_default),{modelValue:alwaysShowDialogue.value,"onUpdate:modelValue":[_cache[0]||=$event=>alwaysShowDialogue.value=$event,handleAlwaysShowDialogueChange],label:`Always show this dialogue`,labelBefore:``},null,8,[`modelValue`])]),spawningOptions.value.length>0||__props.levelData?.buttonInfo&&__props.levelData.buttonInfo.length>0?(openBlock(),createElementBlock(`div`,_hoisted_16$12,[__props.levelData?.buttonInfo&&__props.levelData.buttonInfo.length>0?(openBlock(!0),createElementBlock(Fragment,{key:0},renderList(__props.levelData.buttonInfo,button=>(openBlock(),createBlock(unref(bngButton_default),{key:button.buttonId,label:button.label,icon:button.icon,accent:button.primary?`main`:`secondary`,onClick:$event=>handleButtonClick(button.buttonId)},null,8,[`label`,`icon`,`accent`,`onClick`]))),128)):createCommentVNode(``,!0)])):createCommentVNode(``,!0)])],8,_hoisted_1$117)),[[unref(BngOnUiNav_default),handleCancelWithBack,`back,menu`]])}},LevelConfigurationModal_default=__plugin_vue_export_helper_default(_sfc_main$130,[[`__scopeId`,`data-v-ec35f32c`]]),_sfc_main$129={__name:`FreeroamSelector`,setup(__props){let{events:events$3}=useBridge(),handleOpenLevelConfigPopup=data=>{addPopup(LevelConfigurationModal_default,{levelData:data}).promise};return onMounted(()=>{events$3.on(`openLevelConfigurationPopup`,handleOpenLevelConfigPopup)}),onUnmounted(()=>{events$3.off(`openLevelConfigurationPopup`,handleOpenLevelConfigPopup)}),(_ctx,_cache)=>(openBlock(),createBlock(GridSelector_default,{backendName:`freeroamSelector`,routePath:`/freeroam-selector`,defaultPath:{keys:[`allFreeroam`]},defaultDetailsMode:`detail`,hiddenTabs:[`filter`]},{"item-details":withCtx(({activeItem,activeItemDetails,executeButton,toggleFavourite,exploreFolder,goToMod})=>[createVNode(GameplayDetails_default,{activeItem,activeItemDetails,executeButton,toggleFavourite,exploreFolder,goToMod},null,8,[`activeItem`,`activeItemDetails`,`executeButton`,`toggleFavourite`,`exploreFolder`,`goToMod`])]),_:1}))}},FreeroamSelector_default=_sfc_main$129,_hoisted_1$116={class:`preview`},_hoisted_2$96={key:0,class:`general-tags`},_hoisted_3$84={key:1,class:`icon-text-tag`},_hoisted_4$64={class:`vehicle-text-header`},_hoisted_5$54={key:0,class:`general-specs`},_hoisted_6$41={key:1,class:`divider`},_hoisted_7$34={class:`vehicle-tags`},_hoisted_8$27=[`onClick`],_hoisted_9$24=[`src`],_hoisted_10$18={key:0,class:`source-icon-container`},_hoisted_11$16={key:1,class:`source-icon-container`},_hoisted_12$12={key:2,class:`source-icon-container auxiliary-icon`},_hoisted_13$11={key:2,class:`vehicle-description`},_hoisted_14$11={class:`specs-grid-container`},_hoisted_15$11={key:0,class:`spec-label`},_hoisted_16$11={class:`spec-value`},_hoisted_17$10={key:1,class:`spec-value`},_hoisted_18$8={key:0,class:`bottom-section`},_hoisted_19$6={class:`paint-list expanded`},_sfc_main$128={__name:`VehicleDetails`,props:{activeItem:{type:Object,default:null},activeItemDetails:{type:Object,default:null},executeButton:{type:Function,default:()=>{}},toggleFavourite:{type:Function,default:()=>{}},exploreFolder:{type:Function,default:()=>{}},goToMod:{type:Function,default:()=>{}},showHeaderTitle:{type:Boolean,default:!0},hideDetailsAndButtons:{type:Boolean,default:!1},inline:{type:Boolean,default:!1},buttonOverride:{type:Object,default:null}},emits:[`focus-item`],setup(__props,{emit:__emit}){let{showIfController}=storeToRefs(controls_default()),props=__props,emit$1=__emit,handleButtonClick=buttonId=>{let additionalData={};selectedMultiPaint.value&&(additionalData.paint=selectedMultiPaint.value.paintNames[0],additionalData.paint2=selectedMultiPaint.value.paintNames[1],additionalData.paint3=selectedMultiPaint.value.paintNames[2]),selectedPaint.value&&(additionalData.paint=selectedPaint.value.name),props.executeButton(buttonId,additionalData),emit$1(`button-click`,buttonId)},toggleFavourite=()=>{props.activeItem&&props.toggleFavourite(props.activeItem)},openFolder=path=>{props.exploreFolder(path)},goToMod=modId=>{props.goToMod(modId)},sortedFactoryPaints=computed(()=>{let factoryPaints=props.activeItemDetails?.paints?.factoryPaints;return Array.isArray(factoryPaints)?sortColors(factoryPaints).filter(paint=>paint&&paint.name):[]}),multiPaints=computed(()=>{let res=[],multiPaintSetups=props.activeItemDetails?.paints?.multiPaintSetups,factoryPaints=props.activeItemDetails?.paints?.factoryPaints;if(!Array.isArray(multiPaintSetups)||!Array.isArray(factoryPaints))return res;for(let i=0;iname&&factoryPaints.find(paint=>paint.name===name)||null).filter(paint=>paint!==null);paints.length>0&&res.push({id:paintNames.join(`|`),name:setup$3.name,paintNames,paints,applyAll:()=>applyMultipaint(setup$3)})}return res}),hasPaintData=computed(()=>props.activeItemDetails?.additionalData?.paint&&props.activeItemDetails?.paints?.factoryPaints),paintData=computed(()=>{if(!hasPaintData.value)return null;let additionalData=props.activeItemDetails.additionalData,factoryPaints=props.activeItemDetails.paints.factoryPaints,paintNames=[additionalData.paint,additionalData.paint2,additionalData.paint3].filter(name=>name),paints=paintNames.map(name=>{let paint=factoryPaints.find(p$1=>p$1.name===name);return paint?convertPaintToTileFormat(paint):null}).filter(paint=>paint!==null);return paints.length===0?null:{paint:paintNames[0],paintNames,paints}});function applyMultipaint(setup$3){selectedMultiPaint.value=setup$3,selectedPaint.value=null}let selectedMultiPaint=ref(null),selectedPaint=ref(null);ref(!1);let handleMultiPaintClick=(multiPaint,focus$1=!0)=>{selectedMultiPaint.value=multiPaints.value.find(mp=>mp.name===multiPaint.name),selectedPaint.value=null,focus$1&&emit$1(`focus-item`,`multiPaints`)},handlePaintClick=paint=>{selectedPaint.value=paint,selectedMultiPaint.value=null,emit$1(`focus-item`,`paints`)},convertPaintToTileFormat=paint=>{if(!paint)return null;if(paint.baseColor&&paint.paintString)return paint;try{let paintObj=new Paint;return paintObj.paint=paint,paintObj.paintObject}catch(error){return console.warn(`Failed to convert paint:`,paint,error),null}},selectDefaultMultiPaint=()=>{if(!props.activeItemDetails?.paints)return;let multiPaintSetups=props.activeItemDetails?.paints.multiPaintSetups;if(Array.isArray(multiPaintSetups)&&multiPaintSetups.length>0){let defaultMultiPaintSetup=multiPaintSetups.find(setup$3=>setup$3.isDefault);if(defaultMultiPaintSetup){let multiPaintsObj=multiPaints.value.find(mp=>mp.name===defaultMultiPaintSetup.name);if(multiPaintsObj){handleMultiPaintClick(multiPaintsObj,!1);return}}}};watch(()=>props.activeItemDetails,()=>{selectDefaultMultiPaint()}),onMounted(()=>{selectDefaultMultiPaint()});function average(arr){return arr.reduce((a$1,b)=>a$1+b)/arr.length}function valComparable(col,thres=.05){let bool=!0,av=average(col);for(let i=0;i=col[i];return bool&&=av>.8||av<.2,bool}function colorHigherHelper(itm){if(!itm||!itm.orig||!itm.orig.baseColor||!Array.isArray(itm.orig.baseColor)||itm.orig.baseColor.length<4)return 0;let av=average(itm.orig.baseColor.slice(0,3)),al=itm.orig.baseColor[3]/2,res=Math.abs(av-1)*al;return res===0?(av+al)/2:res+1}function colorHigher(a$1,b){if(!a$1||!b||!a$1.orig||!b.orig||!a$1.orig.baseColor||!b.orig.baseColor)return 0;let aColor=valComparable(a$1.orig.baseColor.slice(0,3)),bColor=valComparable(b.orig.baseColor.slice(0,3));if(aColor&&bColor)return colorHigherHelper(b)-colorHigherHelper(a$1);if(aColor&&!bColor)return 1;if(!aColor&&bColor)return-1;for(let i=0;i<3;i++)if(a$1.val[i]!==b.val[i])return a$1.val[i]-b.val[i];return 0}function colorValue(arr){if(!Array.isArray(arr)||arr.length<4)return[0,0,0,0];let repitions=8,rgb=[];for(let i=0;i<3;i++)rgb[i]=(1-arr[3]/2)*arr[i]+arr[3]/2*arr[i];let lum=Math.sqrt(.241*rgb[0]+.691*rgb[1]+.068*rgb[2]),hsl=Paint.rgbToHsl(rgb),out=[hsl[0],lum,hsl[1]].map(elem=>elem*8);return out[0]%2==1&&(out[1]=8-out[1],out[2]=8-out[2]),out.push(arr[3]),out}function sortColors(list){return Array.isArray(list)?list.filter(elem=>elem&&elem.baseColor&&Array.isArray(elem.baseColor)&&elem.baseColor.length>=4).map(elem=>({val:colorValue(elem.baseColor),orig:elem})).sort(colorHigher).map(elem=>elem.orig):[]}return(_ctx,_cache)=>(openBlock(),createElementBlock(Fragment,null,[withDirectives((openBlock(),createElementBlock(`div`,{class:normalizeClass([`details`,{inline:__props.inline}]),"bng-nav-scroll":``},[createBaseVNode(`div`,_hoisted_1$116,[__props.showHeaderTitle?(openBlock(),createBlock(bngCardHeading_default,{key:0,type:`none`,class:`header-title`},{default:withCtx(()=>[createTextVNode(toDisplayString(__props.activeItemDetails.headerTitle),1)]),_:1})):createCommentVNode(``,!0),createBaseVNode(`div`,{class:normalizeClass([`tags-and-preview`,{"has-header-title":__props.showHeaderTitle}])},[__props.activeItemDetails?.iconTags?.length>0?(openBlock(),createElementBlock(`div`,_hoisted_2$96,[(openBlock(!0),createElementBlock(Fragment,null,renderList(__props.activeItemDetails?.iconTags,icon=>(openBlock(),createBlock(bngTooltip_default,{key:icon.icon,text:icon.label,position:`left`},{default:withCtx(()=>[icon.icon?(openBlock(),createBlock(unref(bngIcon_default),{key:0,type:icon.icon,label:icon.label,onClick:$event=>goToMod(icon.goToMod),class:normalizeClass({"favourite-icon":icon.goToMod})},null,8,[`type`,`label`,`onClick`,`class`])):createCommentVNode(``,!0),icon.iconText?(openBlock(),createElementBlock(`span`,_hoisted_3$84,toDisplayString(icon.iconText),1)):createCommentVNode(``,!0)]),_:2},1032,[`text`]))),128))])):createCommentVNode(``,!0),createVNode(unref(aspectRatio_default),{class:normalizeClass([`preview-image`,{"has-header-title":__props.showHeaderTitle}]),ratio:`16:8`,"external-image":__props.activeItemDetails?.preview},{default:withCtx(()=>[__props.inline?createCommentVNode(``,!0):(openBlock(),createBlock(unref(bngIcon_default),{key:0,class:`favourite-icon`,type:__props.activeItemDetails?.isFavourite?`star`:`starSecondary`,onClick:toggleFavourite,color:__props.activeItemDetails?.isFavourite?`var(--bng-ter-yellow-50)`:`var(--bng-cool-gray-100)`},null,8,[`type`,`color`])),hasPaintData.value?(openBlock(),createBlock(unref(bngPaintTile_default),{key:1,"paint-id":`${__props.activeItem?.id||`vehicle`}:${paintData.value.paint}`,paint:paintData.value.paints,"paint-name":paintData.value.paintNames.join(`, `),width:56,height:24,class:`preview-paint-tile`,"bng-no-nav":`true`,tabindex:`-1`},null,8,[`paint-id`,`paint`,`paint-name`])):createCommentVNode(``,!0)]),_:1},8,[`class`,`external-image`])],2)]),createBaseVNode(`div`,_hoisted_4$64,[__props.activeItemDetails?.generalSpecs?.length>0?(openBlock(),createElementBlock(`div`,_hoisted_5$54,[(openBlock(!0),createElementBlock(Fragment,null,renderList(__props.activeItemDetails?.generalSpecs,spec=>(openBlock(),createElementBlock(`div`,{class:`spec-value`,key:spec.key},[Array.isArray(spec.value)?(openBlock(),createElementBlock(Fragment,{key:0},[createTextVNode(toDisplayString(_ctx.$tt(spec.value[0].text)),1)],64)):(openBlock(),createElementBlock(Fragment,{key:1},[createTextVNode(toDisplayString(spec.value),1)],64))]))),128))])):createCommentVNode(``,!0),__props.activeItemDetails?.generalSpecs.length>0?(openBlock(),createElementBlock(`div`,_hoisted_6$41)):createCommentVNode(``,!0),createBaseVNode(`div`,_hoisted_7$34,[(openBlock(!0),createElementBlock(Fragment,null,renderList(__props.activeItemDetails?.tags,tag=>(openBlock(),createElementBlock(`div`,{key:tag.key,class:normalizeClass([`source-icon-container`,{"auxiliary-icon":tag.auxiliary}]),onClick:$event=>_ctx.tagClicked(tag)},[tag.icon?(openBlock(),createBlock(unref(bngIcon_default),{key:0,type:tag.icon},null,8,[`type`])):createCommentVNode(``,!0),tag.svg?(openBlock(),createElementBlock(`img`,{key:1,class:`svg-icon`,src:tag.svg},null,8,_hoisted_9$24)):createCommentVNode(``,!0),createTextVNode(` `+toDisplayString(tag.label),1)],10,_hoisted_8$27))),128)),__props.activeItemDetails?.sourceIcon?(openBlock(),createElementBlock(`div`,_hoisted_10$18,[createVNode(unref(bngIcon_default),{type:__props.activeItemDetails?.sourceIcon.icon,onClick:_cache[0]||=$event=>goToMod(__props.activeItemDetails?.sourceIcon.goToMod)},null,8,[`type`]),createTextVNode(` `+toDisplayString(__props.activeItemDetails?.sourceIcon.label),1)])):createCommentVNode(``,!0),__props.activeItemDetails?.isFavourite?(openBlock(),createElementBlock(`div`,_hoisted_11$16,[createVNode(unref(bngIcon_default),{type:`star`,onClick:toggleFavourite}),_cache[2]||=createTextVNode(` Favourite`,-1)])):createCommentVNode(``,!0),__props.activeItemDetails?.configDetails.isAuxiliary?(openBlock(),createElementBlock(`div`,_hoisted_12$12,[createVNode(unref(bngIcon_default),{type:`bug`}),_cache[3]||=createTextVNode(` Auxiliary`,-1)])):createCommentVNode(``,!0)]),__props.activeItemDetails?.configDetails?.Description?(openBlock(),createElementBlock(`div`,_hoisted_13$11,toDisplayString(__props.activeItemDetails?.configDetails?.Description),1)):createCommentVNode(``,!0)]),__props.activeItemDetails?.configDetails&&!__props.hideDetailsAndButtons?(openBlock(!0),createElementBlock(Fragment,{key:0},renderList(__props.activeItemDetails?.specificationsList,(value,key)=>(openBlock(),createElementBlock(`div`,{key,class:`specs-grid`},[createBaseVNode(`div`,_hoisted_14$11,[(openBlock(!0),createElementBlock(Fragment,null,renderList(value.specifications,specification=>(openBlock(),createElementBlock(`div`,{key:specification.key,class:normalizeClass([`spec-cell`,{"full-width":!specification.key}])},[specification.key?(openBlock(),createElementBlock(`div`,_hoisted_15$11,toDisplayString(specification.key)+`:`,1)):createCommentVNode(``,!0),createBaseVNode(`div`,_hoisted_16$11,[Array.isArray(specification.value)?(openBlock(!0),createElementBlock(Fragment,{key:0},renderList(specification.value,(item,index)=>(openBlock(),createElementBlock(`div`,{key:index,class:normalizeClass([`spec-value-item`,{italic:item.italic}])},[createBaseVNode(`span`,null,toDisplayString(item.text),1),specification.postIcon?(openBlock(),createBlock(unref(bngIcon_default),{key:0,class:`spec-post-icon`,type:specification.postIcon},null,8,[`type`])):createCommentVNode(``,!0),specification.openFolder?(openBlock(),createBlock(unref(bngIcon_default),{key:1,class:`spec-post-icon`,type:`folder`,onClick:$event=>openFolder(specification.value)},null,8,[`onClick`])):createCommentVNode(``,!0)],2))),128)):(openBlock(),createElementBlock(`div`,_hoisted_17$10,[createBaseVNode(`span`,null,toDisplayString(specification.value),1),specification.postIcon?(openBlock(),createBlock(unref(bngIcon_default),{key:0,class:`spec-post-icon`,type:specification.postIcon},null,8,[`type`])):createCommentVNode(``,!0),specification.openFolder?(openBlock(),createBlock(unref(bngIcon_default),{key:1,class:`spec-post-icon`,type:`folder`,onClick:$event=>openFolder(specification.value)},null,8,[`onClick`])):createCommentVNode(``,!0)]))])],2))),128))])]))),128)):createCommentVNode(``,!0)],2)),[[unref(BngUiNavScroll_default),void 0,void 0,{force:!0}]]),__props.hideDetailsAndButtons?createCommentVNode(``,!0):(openBlock(),createElementBlock(`div`,_hoisted_18$8,[createBaseVNode(`div`,_hoisted_19$6,[(openBlock(!0),createElementBlock(Fragment,null,renderList(multiPaints.value,multiPaint=>(openBlock(),createBlock(unref(bngPaintTile_default),{key:multiPaint.name,"paint-id":`${__props.activeItem?.id||`vehicle`}:${multiPaint.name}`,paint:multiPaint.paints,"paint-name":multiPaint.name,"paint-names":multiPaint.paintNames,width:56,height:24,class:normalizeClass([`multi-paint-item`,{selected:selectedMultiPaint.value?.name===multiPaint.name}]),onClick:$event=>handleMultiPaintClick(multiPaint)},null,8,[`paint-id`,`paint`,`paint-name`,`paint-names`,`class`,`onClick`]))),128)),(openBlock(!0),createElementBlock(Fragment,null,renderList(sortedFactoryPaints.value,paint=>(openBlock(),createElementBlock(Fragment,{key:paint.name},[paint&&paint.class===`factory`&&paint.name?(openBlock(),createBlock(unref(bngPaintTile_default),{key:0,"paint-id":`${__props.activeItem?.id||`vehicle`}:${paint.name}`,paint:convertPaintToTileFormat(paint),"vehicle-name":`factory`,"paint-name":paint.name,width:24,height:24,class:normalizeClass([`paint-item`,{selected:selectedPaint.value===paint}]),onClick:$event=>handlePaintClick(paint)},null,8,[`paint-id`,`paint`,`paint-name`,`class`,`onClick`])):createCommentVNode(``,!0)],64))),128))]),__props.activeItemDetails?.buttonInfo&&!__props.buttonOverride?(openBlock(!0),createElementBlock(Fragment,{key:0},renderList(__props.activeItemDetails?.buttonInfo,button=>(openBlock(),createBlock(unref(bngButton_default),{key:button.buttonId,"bng-scoped-nav-autofocus":button.primary,accent:button.primary?`main`:`secondary`,label:button.label,icon:button.icon,onClick:$event=>handleButtonClick(button.buttonId)},null,8,[`bng-scoped-nav-autofocus`,`accent`,`label`,`icon`,`onClick`]))),128)):createCommentVNode(``,!0),__props.buttonOverride?(openBlock(),createBlock(unref(bngButton_default),{key:1,"bng-scoped-nav-autofocus":!0,accent:`main`,label:__props.buttonOverride.label,icon:__props.buttonOverride.icon,onClick:_cache[1]||=$event=>__props.buttonOverride.click(__props.activeItem,selectedPaint.value,selectedMultiPaint.value)},null,8,[`label`,`icon`])):createCommentVNode(``,!0)]))],64))}},VehicleDetails_default=__plugin_vue_export_helper_default(_sfc_main$128,[[`__scopeId`,`data-v-58d013e3`]]);function useFreeroamConfigurator(){let{events:events$3}=useBridge(),configData=ref(null),button=ref(null),error=ref(null),isInitializing=ref(!1),refreshConfigHandler=()=>{logger_default.debug(`freeroamConfiguratorRefreshConfig`),loadConfiguration()},refreshButtonHandler=()=>{logger_default.debug(`freeroamConfiguratorRefreshButton`),loadButtons()};events$3.on(`freeroamConfiguratorRefreshConfig`,refreshConfigHandler),events$3.on(`freeroamConfiguratorRefreshButton`,refreshButtonHandler);let loadButtons=async()=>{try{let buttonData=await Lua_default.freeroam_freeroamConfigurator.getButtons();button.value=buttonData||null,logger_default.debug(`Loaded button:`,buttonData)}catch(err){logger_default.error(`Failed to load button:`,err),error.value=err}},loadConfiguration=async()=>{try{error.value=null;let data=await Lua_default.freeroam_freeroamConfigurator.getConfiguration();data?.options&&processOptionsTree(data.options),configData.value=data,logger_default.debug(`Loaded configuration:`,data),await loadButtons()}catch(err){logger_default.error(`Failed to load freeroam configuration:`,err),error.value=err}},processOptionsTree=options=>{!options||!Array.isArray(options)||options.forEach(group=>{group.key&&(group.onChange=val=>{group.value=val,handleOptionChange(group.key,val)}),Object.defineProperty(group,`enabled`,{get(){return!this.key||!!this.value},enumerable:!0,configurable:!0}),group.options&&Array.isArray(group.options)&&group.options.forEach(option=>{option.key&&(option.onChange=val=>{option.value=val,handleOptionChange(option.key,val)})})})},onSpawnPointTileClick=async()=>{try{await Lua_default.freeroam_freeroamConfigurator.onSpawnPointTileClick(),logger_default.debug(`Spawn point tile clicked`)}catch(err){logger_default.error(`Failed to handle spawnpoint tile click:`,err),error.value=err}},onVehicleTileClick=async()=>{try{await Lua_default.freeroam_freeroamConfigurator.onVehicleTileClick(),logger_default.debug(`Vehicle tile clicked`)}catch(err){logger_default.error(`Failed to handle vehicle tile click:`,err),error.value=err}},updateOption=async(key,value)=>{try{await Lua_default.freeroam_freeroamConfigurator.updateOption(key,value),logger_default.debug(`Updated option ${key}:`,value)}catch(err){logger_default.error(`Failed to update option ${key}:`,err),error.value=err}},handleOptionChange=async(key,newValue)=>{try{await Lua_default.freeroam_freeroamConfigurator.updateOption(key,newValue),await loadButtons(),logger_default.debug(`Handled option change ${key}:`,newValue)}catch(err){logger_default.error(`Failed to update ${key} option:`,err),error.value=err}},handleButtonClick=async buttonId=>{try{await Lua_default.freeroam_freeroamConfigurator.triggerButton(buttonId),logger_default.debug(`Button clicked:`,buttonId)}catch(err){logger_default.error(`Failed to trigger button:`,err),error.value=err}},selectSpawnPoint=async(levelName,spawnPointObjectName,key)=>{try{if(!levelName)throw logger_default.error(`selectSpawnPoint: levelName is required`),Error(`levelName is required`);return await Lua_default.freeroam_freeroamConfigurator.setSpawnPoint(levelName,spawnPointObjectName,key),configData.value.currentSpawnPoint=await Lua_default.freeroam_freeroamConfigurator.getCurrentSpawnPointTile(),logger_default.debug(`Selected spawn point:`,{levelName,spawnPointObjectName}),!0}catch(err){return logger_default.error(`Failed to select spawn point:`,err),error.value=err,!1}},selectVehicle=async(model,config,additionalData,key)=>{try{if(!model||!config)throw logger_default.error(`selectVehicle: model and config are required`),Error(`model and config are required`);return await Lua_default.freeroam_freeroamConfigurator.setVehicle(model,config,additionalData||{},key),configData.value.currentVehicle=await Lua_default.freeroam_freeroamConfigurator.getCurrentVehicleTile(),logger_default.debug(`Selected vehicle:`,{model,config,additionalData}),!0}catch(err){return logger_default.error(`Failed to select vehicle:`,err),error.value=err,!1}},gotoHeaderItem=item=>{item.gotoPath&&(window.bngVue.gotoGameState(item.gotoPath.path,{params:item.gotoPath.props}),logger_default.debug(`Navigated to path:`,item.gotoPath)),item.gotoAngularState&&(window.bngVue.gotoAngularState(item.gotoAngularState),logger_default.debug(`Navigated to angular state:`,item.gotoAngularState)),item.click&&(item.click(),logger_default.debug(`Navigated to click:`,item.click))},goBack=()=>{logger_default.debug(`goBack called`),gotoHeaderItem({gotoAngularState:`menu.mainmenu`})},hasOptions=computed(()=>configData.value?.options&&configData.value.options.length>0),hasSpawnPoint=computed(()=>!!configData.value?.currentSpawnPoint),hasVehicle=computed(()=>!!configData.value?.currentVehicle),canConfigureOptions=computed(()=>hasSpawnPoint.value&&hasVehicle.value),isGroupEnabled=group=>!group.key||!!group.value,initialize=async()=>{if(isInitializing.value){logger_default.debug(`Already initializing, skipping...`);return}try{isInitializing.value=!0,logger_default.debug(`Initializing FreeroamConfigurator composable...`),await loadConfiguration(),logger_default.debug(`FreeroamConfigurator composable initialized successfully`)}catch(err){logger_default.error(`Failed to initialize FreeroamConfigurator composable:`,err),error.value=err}finally{isInitializing.value=!1}},cleanup=()=>{logger_default.debug(`FreeroamConfigurator composable cleanup`),events$3.off(`freeroamConfiguratorRefreshConfig`,refreshConfigHandler),events$3.off(`freeroamConfiguratorRefreshButton`,refreshButtonHandler)};return onUnmounted(()=>{cleanup()}),{configData,config:configData,button,error,isInitializing,hasOptions,hasSpawnPoint,hasVehicle,canConfigureOptions,initialize,loadConfiguration,loadButtons,onSpawnPointTileClick,onVehicleTileClick,updateOption,handleOptionChange,handleButtonClick,selectSpawnPoint,selectVehicle,gotoHeaderItem,goBack,isGroupEnabled}}var _hoisted_1$115={class:`configurator-content`},_hoisted_2$95={key:0,class:`error-state`},_hoisted_3$83={class:`error-content`},_hoisted_4$63={key:1,class:`configurator-sections`,"bng-nav-item":``},_hoisted_5$53={class:`three-column-layout`},_hoisted_6$40={class:`config-section`,"bng-nav-item":``},_hoisted_7$33={class:`section-header`},_hoisted_8$26={class:`section-title-value`},_hoisted_9$23={class:`section-content`},_hoisted_10$17={key:0,class:`clickable`},_hoisted_11$15={key:1,class:`placeholder-content`},_hoisted_12$11={class:`config-section`,"bng-nav-item":``},_hoisted_13$10={class:`section-header`},_hoisted_14$10={class:`section-title-value`},_hoisted_15$10={class:`section-content`},_hoisted_16$10={key:0,class:`clickable`},_hoisted_17$9={key:1,class:`placeholder-content`},_hoisted_18$7={class:`config-section`,"bng-nav-item":``},_hoisted_19$5={class:`section-header`},_hoisted_20$5={key:0,class:`options-scope`},_hoisted_21$5={key:0,class:`section-header`},_hoisted_22$5=[`bng-scoped-nav-autofocus`],_hoisted_23$4={class:`option-label`},_hoisted_24$3={key:1,class:`placeholder-content`},_hoisted_25$2={class:`action-button-container`},_hoisted_26$1={class:`button-content`},_hoisted_27$1={key:1,class:`placeholder-content row`},_sfc_main$127={__name:`FreeroamConfigurator`,setup(__props){let{lua}=useBridge(),{configData,config,button,error,hasOptions,hasSpawnPoint,hasVehicle,canConfigureOptions,initialize,onSpawnPointTileClick,onVehicleTileClick,handleOptionChange,handleButtonClick,gotoHeaderItem,goBack,isGroupEnabled}=useFreeroamConfigurator();return onBeforeMount(()=>{lua.simTimeAuthority.pushPauseRequest(`freeroamConfigurator`)}),onMounted(()=>{initialize()}),onUnmounted(()=>{lua.simTimeAuthority.popPauseRequest(`freeroamConfigurator`)}),(_ctx,_cache)=>withDirectives((openBlock(),createBlock(unref(layoutSingle_default),{class:`freeroam-configurator`},{default:withCtx(()=>[createBaseVNode(`div`,_hoisted_1$115,[createVNode(unref(bngScreenHeadingV2_default),{class:`configurator-heading`},{preheadings:withCtx(()=>[createVNode(unref(bngBreadcrumbs_default),{"show-back-button":!0,simple:``,"disable-last-item":``,class:`configurator-breadcrumbs`,onBack:unref(goBack),onClick:unref(gotoHeaderItem),items:[{label:`Menu`,gotoAngularState:`menu.mainmenu`},{label:`Freeroam Configurator`}]},null,8,[`onBack`,`onClick`])]),default:withCtx(()=>[_cache[3]||=createTextVNode(` Freeroam `,-1)]),_:1}),unref(error)?(openBlock(),createElementBlock(`div`,_hoisted_2$95,[createVNode(BlurBackground_default),createBaseVNode(`div`,_hoisted_3$83,[createVNode(unref(bngIcon_default),{type:`warning`,class:`error-icon`}),_cache[5]||=createBaseVNode(`p`,null,`Failed to load configuration`,-1),createVNode(unref(bngButton_default),{onClick:unref(initialize),accent:unref(ACCENTS).secondary},{default:withCtx(()=>[..._cache[4]||=[createTextVNode(`Retry`,-1)]]),_:1},8,[`onClick`,`accent`])])])):withDirectives((openBlock(),createElementBlock(`div`,_hoisted_4$63,[createBaseVNode(`div`,_hoisted_5$53,[withDirectives((openBlock(),createElementBlock(`div`,_hoisted_6$40,[createVNode(BlurBackground_default),createBaseVNode(`div`,_hoisted_7$33,[createVNode(unref(bngCardHeading_default),{type:`ribbon`,class:`section-title`},{default:withCtx(()=>[_cache[6]||=createBaseVNode(`span`,{class:`section-title-label`},`Location:`,-1),createBaseVNode(`span`,_hoisted_8$26,toDisplayString(unref(configData)?.currentSpawnPoint?.headerTitle||`Select location...`),1)]),_:1})]),createBaseVNode(`div`,_hoisted_9$23,[createBaseVNode(`div`,{class:`selectable-component`,onClick:_cache[0]||=()=>unref(onSpawnPointTileClick)()},[unref(configData)?.currentSpawnPoint?(openBlock(),createElementBlock(`div`,_hoisted_10$17,[createVNode(GameplayDetails_default,{"active-item":{levelName:unref(configData).currentSpawnPoint.levelName,spawnPointObjectName:unref(configData).currentSpawnPoint.spawnPointObjectName},"active-item-details":unref(configData).currentSpawnPoint,inline:``},null,8,[`active-item`,`active-item-details`])])):(openBlock(),createElementBlock(`div`,_hoisted_11$15,[createVNode(unref(bngIcon_default),{type:`road`,class:`placeholder-icon`}),_cache[7]||=createBaseVNode(`p`,{class:`placeholder-text`},`Click to select location`,-1)]))])])])),[[unref(BngBlur_default)],[unref(BngOnUiNav_default),()=>unref(onSpawnPointTileClick)(),`ok`,{focusRequired:!0}]]),withDirectives((openBlock(),createElementBlock(`div`,_hoisted_12$11,[createVNode(BlurBackground_default),createBaseVNode(`div`,_hoisted_13$10,[createVNode(unref(bngCardHeading_default),{type:`ribbon`,class:`section-title`},{default:withCtx(()=>[_cache[8]||=createBaseVNode(`span`,{class:`section-title-label`},`Vehicle:`,-1),createBaseVNode(`span`,_hoisted_14$10,toDisplayString(unref(configData)?.currentVehicle?.headerTitle||`Select vehicle...`),1)]),_:1})]),createBaseVNode(`div`,_hoisted_15$10,[createBaseVNode(`div`,{class:`selectable-component`,onClick:_cache[1]||=()=>unref(onVehicleTileClick)()},[unref(configData)?.currentVehicle?(openBlock(),createElementBlock(`div`,_hoisted_16$10,[createVNode(VehicleDetails_default,{"active-item":{model:unref(configData).currentVehicle.model,config:unref(configData).currentVehicle.config},"active-item-details":unref(configData).currentVehicle,"hide-details-and-buttons":``,inline:``},null,8,[`active-item`,`active-item-details`])])):(openBlock(),createElementBlock(`div`,_hoisted_17$9,[createVNode(unref(bngIcon_default),{type:`car`,class:`placeholder-icon`}),_cache[9]||=createBaseVNode(`p`,{class:`placeholder-text`},`Click to select vehicle`,-1)]))])])])),[[unref(BngBlur_default)],[unref(BngOnUiNav_default),()=>unref(onVehicleTileClick)(),`ok`,{focusRequired:!0}]]),withDirectives((openBlock(),createElementBlock(`div`,_hoisted_18$7,[createVNode(BlurBackground_default),createBaseVNode(`div`,_hoisted_19$5,[createVNode(unref(bngCardHeading_default),{type:`ribbon`,class:`section-title`},{default:withCtx(()=>[..._cache[10]||=[createTextVNode(`Options`,-1)]]),_:1})]),createBaseVNode(`div`,{class:normalizeClass([`section-content`,{disabled:!unref(canConfigureOptions)}])},[unref(hasOptions)?(openBlock(),createElementBlock(`div`,_hoisted_20$5,[(openBlock(!0),createElementBlock(Fragment,null,renderList(unref(configData).options,group=>(openBlock(),createElementBlock(`div`,{class:`config-group`,key:group.name},[group.name?(openBlock(),createElementBlock(`div`,_hoisted_21$5,[createVNode(unref(bngCardHeading_default),{outline:!unref(isGroupEnabled)(group),type:`ribbon`,class:`section-title`},{default:withCtx(()=>[group.type===`switch`?(openBlock(),createBlock(unref(bngSwitch_default),{key:0,class:`group-switch`,modelValue:unref(config)[group.key],"onUpdate:modelValue":[$event=>unref(config)[group.key]=$event,newValue=>unref(handleOptionChange)(group.key,newValue)],label:group.name,labelBefore:``,inline:``,alwaysTransparent:``},null,8,[`modelValue`,`onUpdate:modelValue`,`label`])):createCommentVNode(``,!0)]),_:2},1032,[`outline`])])):createCommentVNode(``,!0),unref(isGroupEnabled)(group)?(openBlock(!0),createElementBlock(Fragment,{key:1},renderList(group.options,(option,optionIndex)=>(openBlock(),createElementBlock(`div`,{class:`config-item`,key:option.key,"bng-scoped-nav-autofocus":optionIndex===0},[createBaseVNode(`div`,{class:normalizeClass([`option-row`,{disabled:option.disabled}])},[createBaseVNode(`label`,_hoisted_23$4,[option.icon?(openBlock(),createBlock(unref(bngIcon_default),{key:0,type:option.icon,class:`option-icon`},null,8,[`type`])):createCommentVNode(``,!0),createTextVNode(` `+toDisplayString(option.label),1)]),option.type===`select`?(openBlock(),createBlock(unref(bngSmartSelect_default),{key:0,modelValue:unref(config)[option.key],items:option.options||[],threshold:80,"onUpdate:modelValue":newValue=>unref(handleOptionChange)(option.key,newValue)},null,8,[`modelValue`,`items`,`onUpdate:modelValue`])):option.type===`switch`?(openBlock(),createBlock(unref(bngSwitch_default),{key:1,modelValue:unref(config)[option.key],"onUpdate:modelValue":[$event=>unref(config)[option.key]=$event,newValue=>unref(handleOptionChange)(option.key,newValue)],label:option.label,labelBefore:``},null,8,[`modelValue`,`onUpdate:modelValue`,`label`])):option.type===`string`?(openBlock(),createBlock(unref(bngInput_default),{key:2,modelValue:unref(config)[option.key],"onUpdate:modelValue":$event=>unref(config)[option.key]=$event,placeholder:option.placeholder,"char-max":option.maxLength,onValueChanged:newValue=>unref(handleOptionChange)(option.key,newValue)},null,8,[`modelValue`,`onUpdate:modelValue`,`placeholder`,`char-max`,`onValueChanged`])):option.type===`number`?(openBlock(),createBlock(unref(bngInput_default),{key:3,modelValue:unref(config)[option.key],"onUpdate:modelValue":$event=>unref(config)[option.key]=$event,type:`number`,"num-min":option.min,"num-max":option.max,"num-step":option.step,onValueChanged:newValue=>unref(handleOptionChange)(option.key,newValue)},null,8,[`modelValue`,`onUpdate:modelValue`,`num-min`,`num-max`,`num-step`,`onValueChanged`])):createCommentVNode(``,!0)],2)],8,_hoisted_22$5))),128)):createCommentVNode(``,!0)]))),128))])):(openBlock(),createElementBlock(`div`,_hoisted_24$3,[createVNode(unref(bngIcon_default),{type:`adjust`,class:`placeholder-icon`}),_cache[11]||=createBaseVNode(`p`,{class:`placeholder-text`},`No options available`,-1)]))],2)])),[[unref(BngBlur_default)],[unref(BngScopedNav_default),{type:unref(SCOPED_NAV_TYPES).normal}]])]),createBaseVNode(`div`,_hoisted_25$2,[createVNode(BlurBackground_default),unref(button)?withDirectives((openBlock(),createBlock(unref(bngButton_default),{key:0,class:`action-button`,accent:unref(ACCENTS).custom,onClick:_cache[2]||=()=>unref(handleButtonClick)(unref(button).meta.buttonId),"bng-scoped-nav-autofocus":``},{default:withCtx(()=>[createBaseVNode(`div`,_hoisted_26$1,[unref(button).meta.icon?(openBlock(),createBlock(unref(bngIcon_default),{key:0,type:unref(button).meta.icon,class:`button-icon`},null,8,[`type`])):createCommentVNode(``,!0),createTextVNode(` `+toDisplayString(unref(button).meta.label),1)])]),_:1},8,[`accent`])),[[unref(BngBlur_default)]]):(openBlock(),createElementBlock(`div`,_hoisted_27$1,[createVNode(unref(bngIcon_default),{type:`play`,class:`placeholder-icon`}),_cache[12]||=createBaseVNode(`p`,{class:`placeholder-text`},`Select location and vehicle to start`,-1)]))])])),[[unref(BngScopedNav_default),{canDeactivate:()=>!1,activateOnMount:!0}],[unref(BngOnUiNav_default),unref(goBack),`back,menu`]])])]),_:1})),[[unref(BngOnUiNav_default),unref(goBack),`back,menu`]])}},FreeroamConfigurator_default=__plugin_vue_export_helper_default(_sfc_main$127,[[`__scopeId`,`data-v-14f15b24`]]),_hoisted_1$114={class:`options-panel-content`},_hoisted_2$94={class:`header-row`},_hoisted_3$82={key:0,class:`options-scope`},_hoisted_4$62={key:0,class:`section-header`},_hoisted_5$52={class:`option-label`},_hoisted_6$39={key:1,class:`placeholder-content`},_sfc_main$126={__name:`OptionsPanel`,props:{options:{type:Array,default:()=>[]},hasOptions:{type:Boolean,default:!1},canConfigureOptions:{type:Boolean,default:!0}},setup(__props){return(_ctx,_cache)=>withDirectives((openBlock(),createElementBlock(`div`,_hoisted_1$114,[createVNode(BlurBackground_default),createBaseVNode(`div`,_hoisted_2$94,[createVNode(unref(bngScreenHeadingV2_default),{type:`2`,class:`header-title-v2`},{default:withCtx(()=>[..._cache[0]||=[createTextVNode(` Options `,-1)]]),_:1})]),createBaseVNode(`div`,{class:normalizeClass([`section-content`,{disabled:!__props.canConfigureOptions}])},[__props.hasOptions?(openBlock(),createElementBlock(`div`,_hoisted_3$82,[(openBlock(!0),createElementBlock(Fragment,null,renderList(__props.options,group=>(openBlock(),createElementBlock(`div`,{class:`config-group`,key:group.name},[group.name?(openBlock(),createElementBlock(`div`,_hoisted_4$62,[createVNode(unref(bngCardHeading_default),{outline:!group.enabled,type:`ribbon`,class:`section-title`},{default:withCtx(()=>[group.type===`switch`?(openBlock(),createBlock(unref(bngSwitch_default),{key:0,class:`group-switch`,modelValue:group.value,"onUpdate:modelValue":[$event=>group.value=$event,group.onChange],label:group.name,labelBefore:``,inline:``,alwaysTransparent:``},null,8,[`modelValue`,`onUpdate:modelValue`,`label`])):createCommentVNode(``,!0)]),_:2},1032,[`outline`])])):createCommentVNode(``,!0),group.enabled?(openBlock(!0),createElementBlock(Fragment,{key:1},renderList(group.options,(option,optionIndex)=>(openBlock(),createElementBlock(`div`,{class:`config-item`,key:option.key},[createBaseVNode(`div`,{class:normalizeClass([`option-row`,{disabled:option.disabled}])},[createBaseVNode(`label`,_hoisted_5$52,[option.icon?(openBlock(),createBlock(unref(bngIcon_default),{key:0,type:option.icon,class:`option-icon`},null,8,[`type`])):createCommentVNode(``,!0),createTextVNode(` `+toDisplayString(option.label),1)]),option.type===`select`?(openBlock(),createBlock(unref(bngSmartSelect_default),{key:0,modelValue:option.value,"onUpdate:modelValue":[$event=>option.value=$event,option.onChange],items:option.options||[],threshold:80},null,8,[`modelValue`,`onUpdate:modelValue`,`items`])):option.type===`switch`?(openBlock(),createBlock(unref(bngSwitch_default),{key:1,modelValue:option.value,"onUpdate:modelValue":[$event=>option.value=$event,option.onChange],label:option.label,labelBefore:``},null,8,[`modelValue`,`onUpdate:modelValue`,`label`])):option.type===`string`?(openBlock(),createBlock(unref(bngInput_default),{key:2,modelValue:option.value,"onUpdate:modelValue":$event=>option.value=$event,placeholder:option.placeholder,"char-max":option.maxLength,onValueChanged:option.onChange},null,8,[`modelValue`,`onUpdate:modelValue`,`placeholder`,`char-max`,`onValueChanged`])):option.type===`number`?(openBlock(),createBlock(unref(bngInput_default),{key:3,modelValue:option.value,"onUpdate:modelValue":$event=>option.value=$event,type:`number`,"num-min":option.min,"num-max":option.max,"num-step":option.step,onValueChanged:option.onChange},null,8,[`modelValue`,`onUpdate:modelValue`,`num-min`,`num-max`,`num-step`,`onValueChanged`])):createCommentVNode(``,!0)],2)]))),128)):createCommentVNode(``,!0)]))),128))])):(openBlock(),createElementBlock(`div`,_hoisted_6$39,[createVNode(unref(bngIcon_default),{type:`adjust`,class:`placeholder-icon`}),_cache[1]||=createBaseVNode(`p`,{class:`placeholder-text`},`No options available`,-1)]))],2),renderSlot(_ctx.$slots,`buttons`,{},void 0,!0)])),[[unref(BngBlur_default)]])}},OptionsPanel_default=__plugin_vue_export_helper_default(_sfc_main$126,[[`__scopeId`,`data-v-c933da42`]]),_hoisted_1$113={class:`icon-wrapper`},_sfc_main$125={__name:`wizardStepButton`,props:{first:{type:Boolean,default:!1},title:{type:String,required:!0},tooltip:{type:String},active:{type:Boolean,default:!1},completed:{type:Boolean,default:!1},preview:{type:String,default:``},icon:{type:String,default:``},ratio:{type:String,default:`2:1`},showPaintTile:{type:Boolean,default:!1},paintId:{type:String,default:``},paints:{type:Array,default:()=>[]},paintName:{type:String,default:``},paintWidth:{type:Number,default:45},paintHeight:{type:Number,default:20}},emits:[`activate`],setup(__props,{emit:__emit}){let emit$1=__emit;function handleActivate(){emit$1(`activate`)}return(_ctx,_cache)=>withDirectives((openBlock(),createElementBlock(`div`,{class:normalizeClass([`step-tab`,{"first-tab":__props.first,"active-tab":__props.active,"completed-tab":__props.completed,"no-thumbnail":!__props.preview}]),onClick:handleActivate},[createBaseVNode(`div`,_hoisted_1$113,[createVNode(unref(bngIcon_default),{class:`step-icon`,type:__props.icon},null,8,[`type`])]),__props.preview?(openBlock(),createBlock(unref(aspectRatio_default),{key:0,class:`thumbnail-image`,ratio:__props.ratio,"external-image":__props.preview},{default:withCtx(()=>[renderSlot(_ctx.$slots,`overlay`,{},void 0,!0),__props.showPaintTile&&__props.paints&&__props.paints.length>0?(openBlock(),createBlock(unref(bngPaintTile_default),{key:0,"paint-id":__props.paintId,paint:__props.paints,"paint-name":__props.paintName,width:__props.paintWidth,height:__props.paintHeight,onClick:handleActivate,class:`preview-paint-tile`,"bng-no-nav":`true`,tabindex:`-1`},null,8,[`paint-id`,`paint`,`paint-name`,`width`,`height`])):createCommentVNode(``,!0)]),_:3},8,[`ratio`,`external-image`])):createCommentVNode(``,!0)],2)),[[unref(BngOnUiNav_default),handleActivate,`ok`,{focusRequired:!0}],[unref(BngTooltip_default),__props.tooltip,`bottom`]])}},wizardStepButton_default=__plugin_vue_export_helper_default(_sfc_main$125,[[`__scopeId`,`data-v-475a9f52`]]),_hoisted_1$112={class:`configurator-heading`},_hoisted_2$93={class:`configurator-body`},_hoisted_3$81={key:0,class:`grid-section`},_hoisted_4$61={key:1,class:`option-summary-panel`},_hoisted_5$51={class:`section-header`},_hoisted_6$38={class:`section-title-value`},_hoisted_7$32={class:`section-content`},_hoisted_8$25={key:0,class:`clickable`},_hoisted_9$22={key:1,class:`placeholder-content`},_hoisted_10$16={class:`section-header`},_hoisted_11$14={class:`section-title-value`},_hoisted_12$10={class:`section-content`},_hoisted_13$9={key:0,class:`clickable`},_hoisted_14$9={key:1,class:`placeholder-content`},_hoisted_15$9={class:`configurator-heading`},_hoisted_16$9={key:0,class:`error-state`},_hoisted_17$8={class:`error-content`},_hoisted_18$6={key:1,class:`configurator-sections`},_hoisted_19$4={class:`steps-container`},_hoisted_20$4={class:`background-bar`},_hoisted_21$4={class:`label`},_hoisted_22$4={class:`hold-binding`},WIZARD_SCOPE_ID=`freeroam-wizard`,_sfc_main$124={__name:`FreeroamWizard`,props:{step:{type:String,default:``},pathMatch:{type:[String,Array],default:``},itemDetails:{type:[String,Array],default:``}},setup(__props){let{lua,events:events$3}=useBridge(),router$1=useRouter(),scopedNav=useScopedNav(),steps={level:{title:`Location`,backendName:`freeroamSelector`,path:`/freeroam-wizard/level`,defaultPath:{keys:[`allFreeroam`]},defaultDetailsMode:`detail`,hiddenTabs:[`filter`,`advanced`]},vehicle:{title:`Vehicle`,backendName:`vehicleSelector`,path:`/freeroam-wizard/vehicle`,defaultPath:{keys:[`allModels`]},defaultDetailsMode:`detail`,hiddenTabs:[`advanced`]},options:{title:`Options`,path:`/freeroam-wizard/options`}},stepCompleted=computed(()=>({level:props.step===`vehicle`||props.step===`options`,vehicle:props.step===`options`,options:!1})),gridSelectorProps=computed(()=>{let stepConfig=steps[props.step];return stepConfig&&stepConfig.backendName&&stepConfig.path?{backendName:stepConfig.backendName,routePath:stepConfig.path,defaultPath:stepConfig.defaultPath||{keys:[]},defaultDetailsMode:stepConfig.defaultDetailsMode||`detail`,hiddenTabs:stepConfig.hiddenTabs||[]}:null}),props=__props,gridSelectorRef=ref(null),holdBindingRef=ref(null),isLoading=ref(!1),breadcrumbItems=computed(()=>{let items$2=[{label:`Menu`,gotoAngularState:`menu.mainmenu`},{label:`Freeroam Configurator`,dividerType:`arrowSmallRight`}];props.step===`level`?items$2.push({label:`Location`,click:()=>{onSpawnPointTileClick(!0)}}):props.step===`vehicle`?items$2.push({label:`Vehicle`,click:()=>{onVehicleTileClick(!0)}}):props.step===`options`&&items$2.push({label:`Options`,click:onOptionsTileClick});let screenHeaderPath=gridSelectorRef.value?.screenHeaderPath,pathValue=screenHeaderPath?.value||screenHeaderPath;return pathValue&&Array.isArray(pathValue)&&pathValue.length>2&&(pathValue.length>3?(items$2.push({label:pathValue[2].label,click:()=>{gridSelectorRef.value.setCurrentPath({keys:pathValue[2].gotoPath}),onSpawnPointTileClick()}}),items$2.push(pathValue[3])):items$2.push(pathValue[2])),items$2}),{configData,button,error,hasOptions,hasSpawnPoint,hasVehicle,canConfigureOptions,initialize,handleButtonClick,selectSpawnPoint,selectVehicle,gotoHeaderItem,loadConfiguration}=useFreeroamConfigurator();watch(()=>props.step,step=>{step===`options`&&(loadConfiguration(),scopedNav.resumeScope(WIZARD_SCOPE_ID))});let overrideSelectItem=async(step,...args)=>{if(props.step===`level`){let item=args[0];if(!item?.showDetails?.levelName)return logger_default.error(`overrideSelectItem: Invalid item data for level selection`),null;await selectSpawnPoint(item.showDetails.levelName,item.showDetails.spawnPointObjectName,item.key)&&router$1.push(steps.vehicle.path)}else if(props.step===`vehicle`){let item=args[0];if(!item?.showDetails?.model||!item?.showDetails?.config)return logger_default.error(`overrideSelectItem: Invalid item data for vehicle selection`),null;let selectedPaint=args[1],selectedMultiPaint=args[2],additionalData={};selectedMultiPaint?.paintNames?(additionalData.paint=selectedMultiPaint.paintNames[0],additionalData.paint2=selectedMultiPaint.paintNames[1],additionalData.paint3=selectedMultiPaint.paintNames[2]):selectedPaint?.name&&(additionalData.paint=selectedPaint.name),await selectVehicle(item.showDetails.model,item.showDetails.config,additionalData,item.key)&&router$1.push(steps.options.path)}return null},onSelectCallback=async(item,doNavigation)=>{if(doNavigation){if(props.step===`level`){if(!item?.doubleClickDetails?.levelName)return logger_default.error(`overrideSelectItem: Invalid item data for level selection`),null;await selectSpawnPoint(item.doubleClickDetails.levelName,item.doubleClickDetails.spawnPointObjectName,item.key)}else if(props.step===`vehicle`){if(!item?.doubleClickDetails?.model||!item?.doubleClickDetails?.config)return logger_default.error(`overrideSelectItem: Invalid item data for vehicle selection`),null;await selectVehicle(item.doubleClickDetails.model,item.doubleClickDetails.config,{},item.key)}}return null},doubleClickOverride=async item=>{if(!item?.doubleClickDetails){logger_default.error(`doubleClickOverride: Invalid item data`);return}let details=item.doubleClickDetails;details.levelName?await selectSpawnPoint(details.levelName,details.spawnPointObjectName,item.key)&&router$1.push(steps.vehicle.path):details.model&&details.config&&await selectVehicle(details.model,details.config,{},item.key)&&router$1.push(steps.options.path)},goBack=()=>{logger_default.debug(`goBack called`);let gridSelectorPath=gridSelectorRef.value?.screenHeaderPath;props.step===`level`?gridSelectorPath&&gridSelectorPath.length>2?onSpawnPointTileClick():window.bngVue.gotoAngularState(`menu.mainmenu`):props.step===`vehicle`?gridSelectorPath&&gridSelectorPath.length>2?onVehicleTileClick():onSpawnPointTileClick():props.step===`options`&&onVehicleTileClick()},onSpawnPointTileClick=async()=>{router$1.replace(steps.level.path)},onVehicleTileClick=async(clearSearch=!1)=>{clearSearch&&gridSelectorRef.value&&(gridSelectorRef.value.clearSearch(),gridSelectorRef.value.clearFilters()),router$1.replace(steps.vehicle.path)},onOptionsTileClick=async()=>{router$1.replace(steps.options.path)},onStartButtonClick=async buttonId=>{isLoading.value=!0,events$3.emit(`LoadingScreen`,{active:!0}),await startLoading$1(async()=>{await waitForLoadingScreenFadeIn$1(),await handleButtonClick(buttonId)})};function convertPaintToTileFormat(paint){if(!paint)return null;if(paint.baseColor&&paint.paintString)return paint;try{let paintObj=new Paint;return paintObj.paint=paint,paintObj.paintObject}catch(error$1){return console.warn(`Failed to convert paint:`,paint,error$1),null}}let vehiclePaintData=computed(()=>{let vehicle=configData.value?.currentVehicle;if(!vehicle?.additionalData?.paint||!vehicle?.paints?.factoryPaints)return null;let additionalData=vehicle.additionalData,factoryPaints=vehicle.paints.factoryPaints,paintNames=[additionalData.paint,additionalData.paint2,additionalData.paint3].filter(name=>name),paints=paintNames.map(name=>{let paint=factoryPaints.find(p$1=>p$1.name===name);return paint?convertPaintToTileFormat(paint):null}).filter(paint=>paint!==null);return paints.length===0?null:{paint:paintNames[0],paintNames,paints}});return onBeforeMount(()=>{lua.simTimeAuthority.pushPauseRequest(`freeroamConfigurator`)}),onMounted(()=>{initialize()}),onUnmounted(()=>{lua.simTimeAuthority.popPauseRequest(`freeroamConfigurator`)}),(_ctx,_cache)=>(openBlock(),createBlock(unref(layoutSingle_default),{class:`freeroam-configurator`},{default:withCtx(()=>[withDirectives((openBlock(),createElementBlock(`div`,{class:normalizeClass([`configurator-content`,{"options-step":__props.step===`options`}])},[createBaseVNode(`div`,_hoisted_1$112,[withDirectives(createVNode(unref(bngBreadcrumbs_default),{class:`configurator-breadcrumbs`,simple:``,"show-back-button":``,"disable-last-item":``,onBack:goBack,onClick:unref(gotoHeaderItem),limit:`15`,items:breadcrumbItems.value},null,8,[`onClick`,`items`]),[[unref(BngBlur_default)]])]),createBaseVNode(`div`,_hoisted_2$93,[__props.step!==`options`&&gridSelectorProps.value?(openBlock(),createElementBlock(`div`,_hoisted_3$81,[(openBlock(),createBlock(GridSelector_default,{ref_key:`gridSelectorRef`,ref:gridSelectorRef,key:`grid-selector-${__props.step}`,"backend-name":gridSelectorProps.value.backendName,"route-path":gridSelectorProps.value.routePath,"default-path":gridSelectorProps.value.defaultPath,"default-details-mode":gridSelectorProps.value.defaultDetailsMode,"hidden-tabs":gridSelectorProps.value.hiddenTabs,"no-breadcrumbs":``,"select-callback":onSelectCallback,"double-click-override":doubleClickOverride,"override-back-from-grid":goBack,"inline-header-container":``,"bubble-events":[`ok`]},{"item-details":withCtx(({activeItem,activeItemDetails,executeButton,toggleFavourite,exploreFolder,goToMod})=>[__props.step===`level`?(openBlock(),createBlock(GameplayDetails_default,{key:0,activeItem,activeItemDetails,toggleFavourite,exploreFolder,goToMod,buttonOverride:{icon:`fastTravel`,label:`Next Step`,click:(...args)=>overrideSelectItem(`level`,...args)},showHeaderTitle:!0},null,8,[`activeItem`,`activeItemDetails`,`toggleFavourite`,`exploreFolder`,`goToMod`,`buttonOverride`])):createCommentVNode(``,!0),__props.step===`vehicle`?(openBlock(),createBlock(VehicleDetails_default,{key:1,activeItem,activeItemDetails,toggleFavourite,exploreFolder,goToMod,buttonOverride:{icon:`fastTravel`,label:`Next Step`,click:(...args)=>overrideSelectItem(`vehicle`,...args)},showHeaderTitle:!0},null,8,[`activeItem`,`activeItemDetails`,`toggleFavourite`,`exploreFolder`,`goToMod`,`buttonOverride`])):createCommentVNode(``,!0)]),_:1},8,[`backend-name`,`route-path`,`default-path`,`default-details-mode`,`hidden-tabs`]))])):createCommentVNode(``,!0),__props.step===`options`&&unref(configData)?(openBlock(),createElementBlock(`div`,_hoisted_4$61,[withDirectives((openBlock(),createElementBlock(`div`,{class:`config-section selectable-component`,onClick:onSpawnPointTileClick},[createVNode(BlurBackground_default),createBaseVNode(`div`,_hoisted_5$51,[createVNode(unref(bngCardHeading_default),{type:`ribbon`,class:`section-title`},{default:withCtx(()=>[_cache[1]||=createBaseVNode(`span`,{class:`section-title-label`},`Location:`,-1),createBaseVNode(`span`,_hoisted_6$38,toDisplayString(unref(configData)?.currentSpawnPoint?.headerTitle||`Select location...`),1)]),_:1})]),createBaseVNode(`div`,_hoisted_7$32,[createBaseVNode(`div`,null,[unref(configData)?.currentSpawnPoint?(openBlock(),createElementBlock(`div`,_hoisted_8$25,[createVNode(GameplayDetails_default,{"active-item":{levelName:unref(configData).currentSpawnPoint.levelName,spawnPointObjectName:unref(configData).currentSpawnPoint.spawnPointObjectName},"active-item-details":unref(configData).currentSpawnPoint,inline:``,"show-header-title":!1},null,8,[`active-item`,`active-item-details`])])):(openBlock(),createElementBlock(`div`,_hoisted_9$22,[createVNode(unref(bngIcon_default),{type:`road`,class:`placeholder-icon`}),_cache[2]||=createBaseVNode(`p`,{class:`placeholder-text`},`Click to select location`,-1)]))])])])),[[unref(BngBlur_default)]]),withDirectives((openBlock(),createElementBlock(`div`,{class:`config-section selectable-component`,onClick:onVehicleTileClick},[createVNode(BlurBackground_default),createBaseVNode(`div`,_hoisted_10$16,[createVNode(unref(bngCardHeading_default),{type:`ribbon`,class:`section-title`},{default:withCtx(()=>[_cache[3]||=createBaseVNode(`span`,{class:`section-title-label`},`Vehicle:`,-1),createBaseVNode(`span`,_hoisted_11$14,toDisplayString(unref(configData)?.currentVehicle?.headerTitle||`Select vehicle...`),1)]),_:1})]),createBaseVNode(`div`,_hoisted_12$10,[createBaseVNode(`div`,null,[unref(configData)?.currentVehicle?(openBlock(),createElementBlock(`div`,_hoisted_13$9,[createVNode(VehicleDetails_default,{"active-item":{model:unref(configData).currentVehicle.model,config:unref(configData).currentVehicle.config},"active-item-details":unref(configData).currentVehicle,"hide-details-and-buttons":``,inline:``,"show-header-title":!1},null,8,[`active-item`,`active-item-details`])])):(openBlock(),createElementBlock(`div`,_hoisted_14$9,[createVNode(unref(bngIcon_default),{type:`car`,class:`placeholder-icon`}),_cache[4]||=createBaseVNode(`p`,{class:`placeholder-text`},`Click to select vehicle`,-1)]))])])])),[[unref(BngBlur_default)]]),withDirectives(createVNode(OptionsPanel_default,{class:`config-section`,options:unref(configData)?.options||[],"has-options":unref(hasOptions),"can-configure-options":unref(canConfigureOptions)},null,8,[`options`,`has-options`,`can-configure-options`]),[[unref(BngOnUiNav_default),goBack,`back`],[unref(BngOnUiNav_default),goBack,`menu`]])])):createCommentVNode(``,!0)]),createBaseVNode(`div`,_hoisted_15$9,[unref(error)?(openBlock(),createElementBlock(`div`,_hoisted_16$9,[createVNode(BlurBackground_default),createBaseVNode(`div`,_hoisted_17$8,[createVNode(unref(bngIcon_default),{type:`warning`,class:`error-icon`}),_cache[6]||=createBaseVNode(`p`,null,`Failed to load configuration`,-1),createVNode(unref(bngButton_default),{onClick:unref(initialize),accent:unref(ACCENTS).secondary},{default:withCtx(()=>[..._cache[5]||=[createTextVNode(`Retry`,-1)]]),_:1},8,[`onClick`,`accent`])])])):(openBlock(),createElementBlock(`div`,_hoisted_18$6,[withDirectives((openBlock(),createElementBlock(`div`,_hoisted_19$4,[createBaseVNode(`div`,_hoisted_20$4,[createVNode(BlurBackground_default)]),createVNode(wizardStepButton_default,{first:``,active:__props.step===`level`,completed:stepCompleted.value.level,title:`Location`,tooltip:unref(configData)?.currentSpawnPoint?.headerTitle,preview:unref(configData)?.currentSpawnPoint?.preview,icon:`road`,onActivate:onSpawnPointTileClick},null,8,[`active`,`completed`,`tooltip`,`preview`]),createVNode(wizardStepButton_default,{active:__props.step===`vehicle`,completed:stepCompleted.value.vehicle,title:`Vehicle`,tooltip:unref(configData)?.currentVehicle?.headerTitle,preview:unref(configData)?.currentVehicle?.preview,icon:`car`,"show-paint-tile":!!vehiclePaintData.value,"paint-id":`${unref(configData)?.currentVehicle?.key||`vehicle`}:${vehiclePaintData.value?.paint}`,paints:vehiclePaintData.value?.paints||[],"paint-name":vehiclePaintData.value?vehiclePaintData.value.paintNames.join(`, `):``,onActivate:onVehicleTileClick},null,8,[`active`,`completed`,`tooltip`,`preview`,`show-paint-tile`,`paint-id`,`paints`,`paint-name`]),createVNode(wizardStepButton_default,{active:__props.step===`options`,completed:stepCompleted.value.options,title:`Options`,tooltip:`Options`,icon:`adjust`,onActivate:onOptionsTileClick},null,8,[`active`,`completed`])])),[[unref(BngBlur_default)]]),withDirectives((openBlock(),createElementBlock(`div`,{class:`play-button`,onClick:_cache[0]||=$event=>onStartButtonClick(unref(button)?.meta?.buttonId),"bng-nav-item":``,tabindex:`1`},[_cache[8]||=createBaseVNode(`div`,{class:`background`},null,-1),createBaseVNode(`div`,_hoisted_21$4,[withDirectives(createBaseVNode(`div`,_hoisted_22$4,[createVNode(unref(bngBinding_default),{ref_key:`holdBindingRef`,ref:holdBindingRef,class:`binding`,"ui-event":`ok`,controller:``},null,512),_cache[7]||=createBaseVNode(`svg`,{class:`hold-arrow`,xmlns:`http://www.w3.org/2000/svg`,viewBox:`0 0 16 12`,preserveAspectRatio:`xMidYMid`},[createBaseVNode(`path`,{d:`M1,1 L8,2 L16,1 L8,11 z`})],-1)],512),[[vShow,holdBindingRef.value?.displayed]]),createTextVNode(` `+toDisplayString(unref(button)?.meta?.label||`Start`),1)])])),[[unref(BngOnUiNav_default),void 0,`ok`,{asMouse:!0}],[unref(BngSoundClass_default),`bng_click_hover_generic`]])]))])],2)),[[unref(BngScopedNav_default),{scopeId:WIZARD_SCOPE_ID,canDeactivate:()=>!1,activateOnMount:!0,bubbleBlacklistEvents:[`back`,`menu`]}],[unref(BngClick_default),{holdCallback:()=>onStartButtonClick(unref(button)?.meta?.buttonId),holdDelay:2e3,repeatInterval:0},void 0,{controller:!0}],[unref(BngOnUiNav_default),void 0,`ok`,{asMouse:!0}]])]),_:1}))}},FreeroamWizard_default=__plugin_vue_export_helper_default(_sfc_main$124,[[`__scopeId`,`data-v-6c942499`]]),routes_default$5=[{name:`menu.freeroamselector`,path:`/freeroam-selector/:pathMatch(.*)*/:itemDetails(.*)*`,component:FreeroamSelector_default,props:!0,meta:{clickThrough:!0,infoBar:{visible:!0,showSysInfo:!1},uiApps:{shown:!1},topBar:{visible:!0}}},{name:`menu.freeroamconfigurator`,path:`/freeroam-configurator`,component:FreeroamConfigurator_default,meta:{clickThrough:!0,infoBar:{visible:!0,showSysInfo:!1},uiApps:{shown:!1},topBar:{visible:!1}}},{name:`menu.freeroamWizard`,path:`/freeroam-wizard/:step/:pathMatch(.*)*/:itemDetails(.*)*`,component:FreeroamWizard_default,props:!0,meta:{clickThrough:!0,infoBar:{visible:!0,showSysInfo:!1},uiApps:{shown:!1},topBar:{visible:!1}}}],_sfc_main$123={__name:`GameplaySelector`,setup(__props){return(_ctx,_cache)=>(openBlock(),createBlock(GridSelector_default,{backendName:`gameplaySelector`,routePath:`/gameplay-selector`,defaultPath:{keys:[`allGameplay`]},defaultDetailsMode:`detail`,hiddenTabs:[`filter`]},{"item-details":withCtx(({activeItem,activeItemDetails,executeButton,toggleFavourite,exploreFolder,goToMod})=>[createVNode(GameplayDetails_default,{activeItem,activeItemDetails,executeButton,toggleFavourite,exploreFolder,goToMod,showHeaderTitle:!0},null,8,[`activeItem`,`activeItemDetails`,`executeButton`,`toggleFavourite`,`exploreFolder`,`goToMod`])]),_:1}))}},GameplaySelector_default=_sfc_main$123,routes_default$6=[{name:`menu.gameplayselector`,path:`/gameplay-selector/:pathMatch(.*)*`,component:GameplaySelector_default,props:!0,meta:{clickThrough:!0,infoBar:{visible:!0,showSysInfo:!1},uiApps:{shown:!1},topBar:{visible:!0}}}],_hoisted_1$111={key:0,class:`garage-button-content`},_sfc_main$122={__name:`GarageButton`,props:{icon:[Object,String],externalIcon:String,disabled:Boolean,active:Boolean,type:{type:String,validator:val=>[`drawer-toggle`,`drawer-button`,``].includes(val)||val===void 0}},setup(__props){let props=__props,slots=useSlots(),hasContent=computed(()=>slots.default),showContent=computed(()=>hasContent.value&&!(props.type===`drawer-toggle`&&!props.active)),btnRef=ref(null);return onUpdated(()=>ensureFocus(btnRef.value?.getElement?.())),(_ctx,_cache)=>(openBlock(),createBlock(unref(bngButton_default),mergeProps({ref_key:`btnRef`,ref:btnRef,accent:unref(ACCENTS).custom,disabled:__props.disabled,icon:__props.icon,externalIcon:__props.externalIcon,class:[`garage-button`,{[`garage-button-${__props.type}`]:!!__props.type,"garage-button-with-content":hasContent.value,"garage-button-active":__props.active}]},_ctx.$attrs),{default:withCtx(()=>[showContent.value?(openBlock(),createElementBlock(`div`,_hoisted_1$111,[renderSlot(_ctx.$slots,`default`,{},void 0,!0)])):createCommentVNode(``,!0)]),_:3},16,[`accent`,`disabled`,`icon`,`externalIcon`,`class`]))}},GarageButton_default=__plugin_vue_export_helper_default(_sfc_main$122,[[`__scopeId`,`data-v-8b374028`]]),_hoisted_1$110={class:`paint-preview`},_hoisted_2$92=[`onClick`],_hoisted_3$80={key:0,class:`empty-slot-indicator`},refpad=25,_sfc_main$121={__name:`PaintPreview`,props:{paints:Array,paintNames:{type:Array,default:()=>[]}},emits:[`select`],setup(__props,{emit:__emit}){let props=__props,emit$1=__emit,previews=computed(()=>{let res=[];if(!props.paints||!Array.isArray(props.paints))return res;let paints=props.paints,len=paints.length;for(let idx=0;idx1?refpad+(100-refpad*2)/(len-1)*idx:50}%`,"--paint-color":isEmpty?`rgba(128, 128, 128, 0.3)`:`rgb(${paint.rgb255.join(`, `)})`,"--paint-metallic":isEmpty?0:Math.max(0,paint.metallic-paint.roughness/.5),"--paint-roughness":isEmpty?1:paint.roughness,"--paint-clearcoat":isEmpty?0:paint.clearcoat,"--paint-clearcoat-roughness":isEmpty?0:paint.clearcoatRoughness,isEmpty,tooltipText};res.push(vars)}return res});return(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$110,[(openBlock(!0),createElementBlock(Fragment,null,renderList(previews.value,(preview,idx)=>withDirectives((openBlock(),createElementBlock(`div`,{key:idx,class:normalizeClass([`paint-preview-item`,{"empty-slot":preview.isEmpty}]),style:normalizeStyle(preview),onClick:$event=>preview.isEmpty?null:emit$1(`select`,idx)},[_cache[0]||=createStaticVNode(`
    `,5),preview.isEmpty?(openBlock(),createElementBlock(`div`,_hoisted_3$80)):createCommentVNode(``,!0)],14,_hoisted_2$92)),[[unref(BngTooltip_default),preview.tooltipText,`bottom`]])),128))]))}},PaintPreview_default=__plugin_vue_export_helper_default(_sfc_main$121,[[`__scopeId`,`data-v-38e5e63f`]]),_hoisted_1$109={class:`paint-preview-container`},_hoisted_2$91={class:`multi-paint-setups-content`},_hoisted_3$79={key:0},colorDefault=`1 1 1 1 0 1 1 0`,previewAnimTime=400,_sfc_main$120={__name:`Paint`,props:{withBackground:Boolean,tabbed:{type:Boolean,default:!0},legacy:{type:Boolean,default:!0}},setup(__props){useUINavBlocker().blockOnly([`context`]);let paintPreviews=usePaintPreviews(),props=__props,events$3=useEvents(),configId=ref(`none`),vehiclePaintPresets=ref({}),multiPaintSetups=ref({}),tabsState=ref([!0,!1,!1]);function tabExpand(idx){for(let i=0;i{tabsState.value[idx]=!0})}let color=ref([colorDefault,colorDefault,colorDefault]),updateColor=(index,preview=!0)=>nextTick(()=>{Lua_default.core_vehicle_colors.setVehicleColor(index,color.value[index]),paints[index].paint=color.value[index],preview&&updatePaint(index)});function resetScroll(){let elm=document.activeElement.closest(`.bng-accitem-content`);elm&&(elm.scrollTop=0)}let paints=Array.from({length:color.value.length},()=>reactive(new Paint({legacy:props.legacy}))),paintImgs=ref(Array(color.value.length).fill(null)),previewStyles=ref(Array(color.value.length).fill(null).map(()=>({"--paint-url":`none`,"--paint-prev-url":`none`,"--paint-prev-transition":`none`,"--paint-prev-opacity":0}))),previewAnimating=Array(color.value.length).fill(0),updatePaintPreview=async(index,url)=>{if(previewAnimating[index]===1)for(previewAnimating[index]=-1;previewAnimating[index]===-1;)await sleep(50);if(previewAnimating[index]=1,previewStyles.value[index][`--paint-prev-transition`]=`none`,paintImgs.value[index]=url,previewAnimTime===0){if(previewAnimating[index]===-1)return previewAnimating[index]=0;previewStyles.value[index][`--paint-url`]=`url(${url})`,previewAnimating[index]=0;return}let currentUrl=previewStyles.value[index][`--paint-url`];if(currentUrl===`none`||!currentUrl){if(previewAnimating[index]===-1)return previewAnimating[index]=0;previewStyles.value[index][`--paint-url`]=`url(${url})`,previewAnimating[index]=0;return}previewStyles.value[index][`--paint-prev-url`]=currentUrl,previewStyles.value[index][`--paint-url`]=`url(${url})`,previewStyles.value[index][`--paint-prev-opacity`]=1,previewStyles.value[index][`--paint-prev-transition`]=`none`,requestAnimationFrame(()=>{if(previewAnimating[index]===-1)return previewAnimating[index]=0;previewStyles.value[index][`--paint-prev-transition`]=`opacity ${previewAnimTime}ms ease-in-out`,previewStyles.value[index][`--paint-prev-opacity`]=0,setTimeout(()=>{if(previewAnimating[index]===-1)return previewAnimating[index]=0;previewStyles.value[index][`--paint-prev-transition`]=`none`,previewAnimating[index]=0},previewAnimTime)})},updatePaint=debounce(async index=>{let paintData=color.value[index];paintPreviews.getBlobPreview(paintData,{paintId:`${configId.value}:single-${index}`,width:80,height:24}).then(url=>{url&&updatePaintPreview(index,url)}).catch(()=>{})},30),updateAllPaints=async()=>{let urls=await Promise.all(paints.map(async(paint,idx)=>await paintPreviews.getBlobPreview(paint.paint,{paintId:`${configId.value}:single-${idx}`,width:80,height:24})));for(let i=0;i{let res=[];for(let i=0;ivehiclePaintPresets.value[name]);res.push({id:paintNames.join(`|`),name:setup$3.name,paintNames,paints:paints$1,apply:idx=>applyMultipaint(setup$3,idx)})}return res});function applyMultipaint(setup$3,index=-1){console.log(`applyMultipaint`,index);let paintNames=[setup$3.paintName1,setup$3.paintName2,setup$3.paintName3];for(let i=0;i-1&&i!==index)continue;let paintName=paintNames[i];if(paintName&&paintName.trim()!==``&&vehiclePaintPresets.value[paintName]){let paintData=vehiclePaintPresets.value[paintName],paint=new Paint({legacy:props.legacy});paint.paint=paintData,color.value[i]=paint.paintString,updateColor(i,!1)}}nextTick(updateAllPaints)}async function fetchDefinedColors(){for(let i=0;i__props.tabbed?(openBlock(),createElementBlock(`div`,{key:0,class:normalizeClass([`paint-acc-wrapper`,{"with-background":__props.withBackground}])},[createBaseVNode(`div`,_hoisted_1$109,[createVNode(PaintPreview_default,{paints:unref(paints),onSelect:tabExpand},null,8,[`paints`])]),withDirectives((openBlock(),createBlock(unref(accordion_default),{class:`paint-acc-container`,singular:``},{default:withCtx(()=>[createVNode(unref(accordionItem_default),{key:`multi-paint-setups`,class:`paint-acc-content`,navigable:``},{caption:withCtx(()=>[..._cache[0]||=[createTextVNode(` Multi Paint Setups `,-1)]]),default:withCtx(()=>[createBaseVNode(`div`,_hoisted_2$91,[(openBlock(!0),createElementBlock(Fragment,null,renderList(multipaint.value,paint=>(openBlock(),createBlock(unref(bngPaintTile_default),{key:paint.name,class:`multi-paint-setup-item`,"paint-id":`${configId.value}:${paint.id}`,paint:paint.paints,"paint-name":paint.name,"paint-names":paint.paintNames,width:72,height:24,"with-menu":``,onClick:paint.apply,onMenuClick:paint.apply},null,8,[`paint-id`,`paint`,`paint-name`,`paint-names`,`onClick`,`onMenuClick`]))),128))])]),_:1}),(openBlock(!0),createElementBlock(Fragment,null,renderList(color.value.length,idx=>(openBlock(),createBlock(unref(accordionItem_default),{key:idx,class:`paint-acc-content`,navigable:``,expanded:tabsState.value[idx-1],style:normalizeStyle(previewStyles.value[idx-1])},{caption:withCtx(()=>[createTextVNode(toDisplayString(_ctx.$t(`ui.trackBuilder.matEditor.paint`)+` `+idx),1)]),default:withCtx(()=>[withDirectives((openBlock(),createElementBlock(`div`,{class:`paint-picker-wrapper`,onDeactivate:resetScroll},[createVNode(PaintPicker_default,{class:`paint-picker`,"picker-mode":`compact_luminosity`,modelValue:color.value[idx-1],"onUpdate:modelValue":$event=>color.value[idx-1]=$event,onChange:$event=>updateColor(idx-1),"show-preview":!1,"presets-editable":``,presets:vehiclePaintPresets.value,legacy:__props.legacy},null,8,[`modelValue`,`onUpdate:modelValue`,`onChange`,`presets`,`legacy`])],32)),[[unref(BngScopedNav_default),{bubbleWhitelistEvents:[`menu`]}]])]),_:2},1032,[`expanded`,`style`]))),128))]),_:1})),[[unref(BngBlur_default),__props.withBackground]])],2)):withDirectives((openBlock(),createElementBlock(`div`,{key:1,class:normalizeClass([`paint-container`,{"with-background":__props.withBackground}])},[(openBlock(!0),createElementBlock(Fragment,null,renderList(color.value.length,idx=>(openBlock(),createBlock(PaintPicker_default,{key:idx,modelValue:color.value[idx-1],"onUpdate:modelValue":$event=>color.value[idx-1]=$event,onChange:$event=>updateColor(idx-1),"show-preview":!1,"presets-editable":``,presets:vehiclePaintPresets.value,legacy:__props.legacy},{default:withCtx(()=>[createTextVNode(toDisplayString(_ctx.$t(`ui.trackBuilder.matEditor.paint`))+` `+toDisplayString(idx),1)]),_:2},1032,[`modelValue`,`onUpdate:modelValue`,`onChange`,`presets`,`legacy`]))),128)),color.value.length%2==1?(openBlock(),createElementBlock(`div`,_hoisted_3$79)):createCommentVNode(``,!0)],2)),[[unref(BngBlur_default),__props.withBackground]])}},Paint_default=__plugin_vue_export_helper_default(_sfc_main$120,[[`__scopeId`,`data-v-956741b3`]]),rgxWheel=/^(\d+(?:\.\d+)?)(x)(\d+(?:\.\d+)?)/i,rgxTire=/^(\d+(?:\.\d+)?)(\/)(\d+(?:\.\d+)?)(R)(\d+(?:\.\d+)?)/i,rgxNum=/(^| )(\d+)($| )/,zeroPad=num=>String(~~(num*1e3)).padStart(10,`0`);function partOptionSorter(...ab){let cmp=[``,``];for(let i=0;i<2;i++){let label=ab[i].label;if(typeof label!=`string`)return 0;rgxWheel.test(label)?cmp[i]=label.replace(rgxWheel,(_,a$1,s,b)=>[a$1,b].map(zeroPad).join(`x`)):rgxTire.test(label)?cmp[i]=label.replace(rgxTire,(_,a$1,s1,b,s2,c)=>[a$1,b,c].map(zeroPad).join(`x`)):rgxNum.test(label)?cmp[i]=label.replace(rgxNum,(_,a$1,num,b)=>a$1+zeroPad(num)+b):cmp[i]=label,label.startsWith(`40x4`)&&console.log(cmp[i])}return cmp[0].localeCompare(cmp[1])}function partOptionGrouper(list){let seq=[],groups={},grouping=!1;for(let itm of list){let group,match=itm.label.match(rgxWheel)||itm.label.match(rgxTire);group=match&&match.length>0?match.slice(1).map(s=>s===`R`?s:s+` `).join(``).trim():itm.label,groups[group]?grouping=!0:(groups[group]=[],seq.push(group)),groups[group].push(itm)}if(!grouping)return list;let res=[];for(let group of seq){let list$1=groups[group];list$1.length===1?res.push(...list$1):(res.push({label:group,group:!0}),res.push(...list$1.map(itm=>({...itm,grouped:!0}))))}return res}var _hoisted_1$108={key:1},_sfc_main$119={__name:`PartsBranch`,props:{rootSlot:Boolean,children:Object,child:Object,info:Object,treeState:Object,treeStateKey:String,flatEntry:Boolean,displayNames:Boolean,showAuxiliary:Boolean,separateSort:Boolean,alwaysSort:Boolean,showEmpty:Boolean,highlighter:[String,Array,RegExp]},emits:[`select`,`deselect`,`highlight`,`change`,`dropdown`],setup(__props,{emit:__emit}){let props=__props,accordionItem=ref(),partsDropdown=ref(),openPartsDropdown=()=>partsDropdown.value&&partsDropdown.value.open(),emit$1=__emit,select=(slot,mouse=!1)=>(!props.child||highlightable.value)&&emit$1(`select`,slot,mouse),deselect=(slot,mouse=!1)=>emit$1(`deselect`,slot,mouse),highlight=slot=>emit$1(`highlight`,slot),change=slot=>emit$1(`change`,slot),dropdown=val=>emit$1(`dropdown`,val),focusReturn=()=>nextTick(()=>accordionItem.value.focus()),accItemUnwatch=watch(accordionItem,()=>{let elm=accordionItem.value?.captionElement;elm&&(accItemUnwatch(),elm.partSelect=()=>props.child&&select(props.child))});function toggleHighlight(slot){slot.highlight=!slot.highlight,highlight(slot)}let toggleHighlightCurrent=()=>toggleHighlight(props.child),highlightable=computed(()=>typeof props.child?.highlight==`boolean`),expanded=ref(!1);if(!props.flatEntry){let unwatchTreeState;unwatchTreeState=watch(()=>props.treeState,()=>setTimeout(()=>{unwatchTreeState(),expanded.value=props.treeStateKey&&props.treeState[props.treeStateKey]&&props.treeState[props.treeStateKey]||!1,watch(()=>expanded.value,val=>{props.treeStateKey&&(val?props.treeState[props.treeStateKey]=val:props.treeStateKey in props.treeState&&delete props.treeState[props.treeStateKey])})},50),{immediate:!0})}let childrenSorter=(a$1,b)=>{if(props.separateSort){if(a$1.children&&!b.children)return 1;if(b.children&&!a$1.children)return-1}if(props.displayNames||!props.alwaysSort)return a$1.slotName.localeCompare(b.slotName);{let info=props.info[a$1.parentSlotName]?.slotInfoUi||{};return getSlotName(a$1,info).localeCompare(getSlotName(b,info))}},slotInfo=computed(()=>props.displayNames?{}:props.info[props.child?.parentSlotName]?.slotInfoUi||{}),isCoreSlot=computed(()=>!!props.info[props.child?.parentSlotName]?.slotInfoUi?.[props.child?.slotName]?.coreSlot),getSlotName=(slot,info={})=>props.displayNames?slot.slotName:info[slot.slotName]?.description||slot.slotName,displayName=computed(()=>getSlotName(props.child,slotInfo.value)),hasPartList=computed(()=>{let list=props.child?.suitablePartNames||[];return list.length===0&&(list=props.child?.chosenPartName?[props.child.chosenPartName]:(props.child?.unsuitablePartNames||[]).map(({partName})=>partName)),props.showAuxiliary||(list=list.filter(partName=>!props.info[partName]?.isAuxiliary)),list.length>0}),partsList=computed(()=>{if(!hasPartList.value)return[];let addEmpty=!0,list=props.child?.suitablePartNames||[];list.length===0&&props.child?.chosenPartName&&(list=[props.child.chosenPartName],addEmpty=!1);let unsuitable=(props.child?.unsuitablePartNames||[]).reduce((res,{partName,reason})=>({...res,[partName]:reason}),{});return list.push(...Object.keys(unsuitable)),list.length===0||(list=list.map(partName=>({value:partName,label:(props.info[partName]?.isAuxiliary?`[!] `:``)+(props.displayNames?partName:props.info[partName]?.description||partName),disabled:partName in unsuitable,tooltip:partName in unsuitable?{text:unsuitable[partName],position:`right`}:void 0,isAuxiliary:props.info[partName]?.isAuxiliary})).filter(opt=>!opt.isAuxiliary||props.showAuxiliary||props.child?.chosenPartName===opt.value),!props.showAuxiliary&&list.length===1&&list[0].isAuxiliary&&isCoreSlot.value)?[]:(list.sort(partOptionSorter),list=partOptionGrouper(list),addEmpty&&!isCoreSlot.value&&list.unshift({value:``,label:`Empty`}),list)}),parentAllChildren=computed(()=>props.children?Object.values(props.children||{}):[]),parentHasChildren=computed(()=>parentAllChildren.value.length>0),parentChildren=computed(()=>[...parentAllChildren.value].sort(childrenSorter)),childAllChildren=computed(()=>props.child?.children?Object.values(props.child.children||{}):[]),childHasChildren=computed(()=>childAllChildren.value.length>0),childChildren=computed(()=>[...childAllChildren.value].sort(childrenSorter)),shouldShow=computed(()=>childHasChildren.value||hasPartList.value||props.showEmpty);return(_ctx,_cache)=>__props.treeState&&parentHasChildren.value?(openBlock(),createBlock(unref(accordion_default),{key:0,class:`branch-category`},{default:withCtx(()=>[(openBlock(!0),createElementBlock(Fragment,null,renderList(parentChildren.value,child=>(openBlock(),createBlock(PartsBranch_default,{key:child.slotName,"root-slot":__props.rootSlot,child,info:__props.info,"tree-state":__props.treeState,"tree-state-key":child.slotName,"display-names":__props.displayNames,"show-auxiliary":__props.showAuxiliary,"separate-sort":__props.separateSort,"always-sort":__props.alwaysSort,"show-empty":__props.showEmpty,"flat-entry":__props.flatEntry,highlighter:__props.highlighter,onSelect:select,onDeselect:deselect,onHighlight:highlight,onChange:change,onDropdown:dropdown},null,8,[`root-slot`,`child`,`info`,`tree-state`,`tree-state-key`,`display-names`,`show-auxiliary`,`separate-sort`,`always-sort`,`show-empty`,`flat-entry`,`highlighter`]))),128))]),_:1})):__props.treeState&&shouldShow.value?(openBlock(),createBlock(unref(accordionItem_default),{key:1,ref_key:`accordionItem`,ref:accordionItem,static:__props.flatEntry||!childHasChildren.value,expanded:expanded.value,onExpanded:_cache[6]||=$event=>expanded.value=$event,class:normalizeClass({"item-changed":__props.child.changed}),"arrow-big":``,navigable:``,onMouseover:_cache[7]||=withModifiers($event=>select(__props.child,!0),[`stop`]),onMouseleave:_cache[8]||=withModifiers($event=>deselect(__props.child,!0),[`stop`]),onFocusin:_cache[9]||=withModifiers($event=>select(__props.child,!1),[`stop`]),onFocusout:_cache[10]||=withModifiers($event=>deselect(__props.child,!1),[`stop`]),"primary-action":partsList.value.length>0?openPartsDropdown:void 0,"secondary-action":highlightable.value?toggleHighlightCurrent:void 0,"primary-label":`ui.inputActions.menu.menu_item_select.title`,"secondary-label":`ui.vehicleconfig.highlight`,"expand-hint-inline":``,"secondary-hint-inline":``},{caption:withCtx(()=>[withDirectives((openBlock(),createElementBlock(`span`,null,[createTextVNode(toDisplayString(displayName.value),1)])),[[unref(BngHighlighter_default),__props.highlighter]])]),controls:withCtx(()=>[createVNode(unref(bngDropdown_default),{ref_key:`partsDropdown`,ref:partsDropdown,modelValue:__props.child.chosenPartName,"onUpdate:modelValue":_cache[0]||=$event=>__props.child.chosenPartName=$event,items:partsList.value,disabled:!hasPartList.value,highlight:__props.highlighter,"show-search":partsList.value.length>5,"long-names":`cut`,onValueChanged:_cache[1]||=$event=>change(__props.child),onFocus:focusReturn,onOpen:_cache[2]||=$event=>dropdown(!0),onClose:_cache[3]||=$event=>dropdown(!1),"bng-no-nav":``},null,8,[`modelValue`,`items`,`disabled`,`highlight`,`show-search`]),createVNode(unref(bngButton_default),{accent:unref(ACCENTS).text,class:normalizeClass({"visibility-toggle":!0,"visibility-toggle-on":__props.child.highlight}),icon:__props.child.highlight?unref(icons).eyeSolidOpened:unref(icons).eyeSolidClosed,disabled:!highlightable.value,onClick:_cache[4]||=$event=>toggleHighlight(__props.child),onFocus:_cache[5]||=$event=>accordionItem.value.focus(),"bng-no-nav":``},null,8,[`accent`,`class`,`icon`,`disabled`])]),default:withCtx(()=>[!__props.flatEntry&&__props.treeState&&childHasChildren.value?(openBlock(),createBlock(PartsBranch_default,{key:0,children:childChildren.value,info:__props.info,"tree-state":__props.treeState,"display-names":__props.displayNames,"show-auxiliary":__props.showAuxiliary,"separate-sort":__props.separateSort,"always-sort":__props.alwaysSort,"show-empty":__props.showEmpty,highlighter:__props.highlighter,onSelect:select,onDeselect:deselect,onHighlight:highlight,onChange:change,onDropdown:dropdown},null,8,[`children`,`info`,`tree-state`,`display-names`,`show-auxiliary`,`separate-sort`,`always-sort`,`show-empty`,`highlighter`])):!__props.flatEntry&&__props.treeState?(openBlock(),createElementBlock(`div`,_hoisted_1$108,`—`)):createCommentVNode(``,!0)]),_:1},8,[`static`,`expanded`,`class`,`primary-action`,`secondary-action`])):createCommentVNode(``,!0)}},PartsBranch_default=__plugin_vue_export_helper_default(_sfc_main$119,[[`__scopeId`,`data-v-a5433800`]]),SearchHistory=class{list=[];index=-1;browsing=!1;saveKey=`partSearchHistory`;constructor(search$1){this.search=search$1,this.load()}load(){let res=localStorage.getItem(this.saveKey);res&&(this.list=JSON.parse(res)||[])}save(){localStorage.setItem(this.saveKey,JSON.stringify(this.list))}update(){if(this.search.query.length===0)return;let text=(isRef(this.search.text)?this.search.text.value:this.search.text).trim().replace(/ +/g,` `),textLC=text.toLowerCase(),idx=this.list.findIndex(txt=>textLC===txt.toLowerCase());if(idx>-1){this.index=idx;return}idx=this.list.findIndex(txt=>txt.toLowerCase().startsWith(textLC)),!(idx>-1)&&(idx=this.list.findIndex(txt=>textLC.startsWith(txt.toLowerCase())),idx>-1?(this.list[idx]=text,this.index=idx):(this.index=this.list.length,this.list.push(text)),this.save())}onKeyDown(event){if(this.list.length!==0){switch(event.key){case`ArrowUp`:this.browsing=!0,this.index--;break;case`ArrowDown`:this.browsing=!0,this.index++;break;case`k`:if(event.ctrlKey)console.log(`Search history cleaned`),localStorage.removeItem(`partSearchHistory`),this.list=[],this.index=0,event.preventDefault();else return;default:event.ctrlKey||(this.browsing=!1);return}this.browsing&&(this.index=Math.abs(this.index+this.list.length)%this.list.length,this.search.text=this.list[this.index]),event.preventDefault()}}},isOfficial=info=>info.authors!==`BeamNG`,PartsSearch=class{active=!1;text=ref(``);query={};message=ref(``);highlight=ref([]);minText=3;history=null;currentConfig=[];richPartInfo=[];opts={};constructor(currentConfig,richPartInfo,opts=null){if(!isRef(currentConfig))throw Error(`currentConfig must be ref`);if(!isRef(richPartInfo))throw Error(`richPartInfo must be ref`);this.currentConfig=currentConfig,this.richPartInfo=richPartInfo,opts&&(this.opts=opts),this.history=new SearchHistory(this),this.result=computed(()=>this.generateResult()),this.messages={noResults:$translate.instant(`ui.common.search.noResults`),tooShort:$translate.instant(`ui.common.search.queryTooShort`),invalidFormat:$translate.instant(`ui.common.search.invalidFormat`),unknownArgument:$translate.instant(`ui.common.search.unknownArgument`)}}generateResult(){let queryArgs=this.parseQuery(isRef(this.text)?this.text.value:this.text);if(this.query=queryArgs,this.highlight.value=queryArgs.highlight,!queryArgs.good)return this.message.value=queryArgs.reason,{};this.message.value=``;let res={},currentConfig=isRef(this.currentConfig)?this.currentConfig.value:this.currentConfig,cnt=0,dive=node=>{if(node.children)for(let child of Object.values(node.children)){let match=this.matchSlot(child);match.matched&&(child.search=match,res[child.slotName+`?`+ ++cnt]=child),dive(child)}};return dive(currentConfig),Object.keys(res).length>0?this.history.update():this.message.value=this.messages.noResults,res}parseQuery(text){let queryString=text.trim().toLowerCase().replace(/ +/g,` `),queryArgs={mode:`or`,reason:``,highlight:[]},ignoreKeys=Object.keys(queryArgs);if(queryString.length-1){let args2=arg.split(/:/);args2.length===2&&args2[1].trim()!==``?(queryArgs[args2[0]]=args2[1],parsedargs++):queryArgs.reason+=this.messages.invalidFormat+`: ${arg}\n`}else queryArgs.reason+=this.messages.unknownArgument+`: ${arg}\n`;parsedargs>1&&(queryArgs.mode=`and`)}return queryArgs.good=!queryArgs.reason,queryArgs.highlight=queryArgs.good?Object.entries(queryArgs).filter(([key])=>!ignoreKeys.includes(key)).map(([_,value])=>value):[],queryArgs}matchSlot(slot){let opts=this.opts,query=this.query,queryMode={or:(a$1,b)=>a$1||b,and:(a$1,b)=>a$1&&b}[query.mode],queryOr=query.mode===`or`,matched=!queryOr,matchDetails={slot:!1,part:!1,mod:!1},info=isRef(this.richPartInfo)?this.richPartInfo.value:this.richPartInfo,match=(string,query$1)=>matched=queryMode(matched,(string?string.toLowerCase():`empty`).indexOf(query$1)>-1);function*pairs(){query.name&&(yield[`slot`,slot.chosenPartName,query.name]),query.slot&&(yield[`slot`,slot.slotName,query.slot]),query.description&&(yield[`slot`,(slot.parentSlotName&&info[slot.parentSlotName]?.slotInfoUi?.[slot.slotName]||{}).description,query.description]);let part=slot.chosenPartName?info[slot.chosenPartName]:null;if(part?(query.description&&(yield[`slot`,part.description,query.description]),query.author&&(yield[`slot`,part.authors,query.author,!isOfficial(part)]),query.mod&&!isOfficial(part)&&(yield[`slot`,part.description,query.mod,!0])):query.description&&(yield[`slot`,null,query.description]),query.partname||query.description||query.mod||query.author)for(let partNames of[slot.suitablePartNames,slot.unsuitablePartNames.map(({partName})=>partName)])for(let partName of partNames){let part$1=info[partName];!part$1||!opts.showAux&&part$1.isAuxiliary||(query.partname&&(yield[`part`,partName,query.partname]),query.description&&(yield[`part`,part$1.description,query.description]),query.author&&(yield[`part`,part$1.authors,query.author,!isOfficial(part$1)]),query.mod&&part$1&&!isOfficial(part$1)&&(yield[`part`,part$1.description,query.mod,!0]))}}let lastType;for(let[type,string,query$1,isMod=!1]of pairs()){if(query$1&&match(string,query$1)&&(queryOr||lastType!==type)){matchDetails[type]=!0,isMod&&(matchDetails.mod=!0);break}lastType=type}return{matched,matchedSlot:matchDetails.slot,matchedOptions:matchDetails.part,matchedMod:matchDetails.mod}}onChange(){let text=isRef(this.text)?this.text.value:this.text;!this.active&&text&&this.start()}start(){this.active=!0}stop(){this.active=!1,isRef(this.text)?this.text.value=``:this.text=``,this.query={},this.history.index=-1}},_hoisted_1$107={class:`parts-browser-content`},_hoisted_2$90={key:1},_hoisted_3$78={style:{padding:`0.5em`,display:`inline-block`}},_hoisted_4$60={class:`search-help`},_hoisted_5$50={key:0},_hoisted_6$37={class:`parts-options-row parts-options-row-separator`},_hoisted_7$31={class:`parts-options-left`},_hoisted_8$24={class:`popover-contents-wrapper`},_hoisted_9$21={class:`parts-options-right`},_hoisted_10$15={class:`parts-options-row`},_hoisted_11$13={class:`license-plate`},_hoisted_12$9={class:`parts-options-right parts-options-buttons`},treeStateKey=`partsTreeState`,_sfc_main$118={__name:`Parts`,props:{withBackground:Boolean},setup(__props){let events$3=useEvents(),queue$2=new ExecQueue,currentVehID=-1,currentConfig=ref({}),richPartInfo=ref({}),partsHighlighted={},treeState=ref({}),isDev=window.beamng&&!window.beamng.shipping,savedOptions=[`applyPartChangesAutomatically`,`selectSubParts`,`showNames`,`showAux`,`separateSort`,`alwaysSort`],opts=reactive({stickyPartSelection:!1,selectSubParts:!0,applyPartChangesAutomatically:!0,simple:!1,showNames:!1,showAux:!beamng.shipping,separateSort:!1,alwaysSort:!1,showEmpty:!1}),waitingForData=ref(!0),waitForData=async()=>{for(;waitingForData.value;)await sleep(100)},search$1=reactive(new PartsSearch(currentConfig,richPartInfo,opts)),partsChanged=ref(!1),vehChange=()=>Lua_default.extensions.core_vehicle_partmgmt.sendDataToUI();events$3.on(`VehicleFocusChanged`,vehChange),events$3.on(`VehicleJbeamIoChanged`,vehChange);function iterateChildren(slot,func){func(slot),slot.children&&Object.values(slot.children).forEach(child=>iterateChildren(child,func))}async function highlightPart(part){waitingForData.value||(iterateChildren(part,child=>typeof child.highlight==`boolean`?partsHighlighted[child.partPath]=child.highlight=part.highlight:void 0),Lua_default.extensions.core_vehicle_partmgmt.highlightParts(partsHighlighted,currentVehID))}let mouseUsedLast=!0,tmrSelect,selectPart=queue$2.wrap(`selectPart`,async(slot,mouse=!1)=>{if(mouseUsedLast=mouse,tmrSelect&&clearTimeout(tmrSelect),waitingForData.value||opts.stickyPartSelection)return;let parts={};for(let part in opts.selectSubParts?iterateChildren(slot,child=>child.partPath&&(parts[child.partPath]=!0)):parts[slot.partPath]=!0,parts)part in partsHighlighted||delete parts[part];Object.keys(parts).length!==0&&await Lua_default.extensions.core_vehicle_partmgmt.selectParts(parts,currentVehID)},{selectPart:queue$2.resolution.replaceWithResolve,deselectPart:queue$2.resolution.resolveOthers,write:queue$2.resolution.resolveThis,reset:queue$2.resolution.resolveThis,resetAllToLoadedConfig:queue$2.resolution.resolveThis,restoreHighlight:queue$2.resolution.resolveThis}),deselectPart=queue$2.wrap(`deselectPart`,(slot,mouse=!1)=>{mouseUsedLast=mouse,tmrSelect&&clearTimeout(tmrSelect),!waitingForData.value&&(tmrSelect=setTimeout(async()=>{tmrSelect=null,!(opts.stickyPartSelection||Object.keys(currentConfig.value).length===0)&&await Lua_default.extensions.core_vehicle_partmgmt.showHighlightedParts(currentVehID)},100))},{deselectPart:queue$2.resolution.replaceWithResolve,write:queue$2.resolution.resolveThis,reset:queue$2.resolution.resolveThis,resetAllToLoadedConfig:queue$2.resolution.resolveThis,restoreHighlight:queue$2.resolution.resolveThis,restoreSelection:queue$2.resolution.resolveThis}),restoreHighlight=queue$2.wrap(`restoreHighlight`,()=>{tmrSelect&&clearTimeout(tmrSelect),tmrSelect=setTimeout(async()=>{tmrSelect=null,await Lua_default.extensions.core_vehicle_partmgmt.highlightParts(partsHighlighted,currentVehID)},100)},{selectPart:queue$2.resolution.replaceWithResolve,deselectPart:queue$2.resolution.replaceWithResolve,restoreHighlight:queue$2.resolution.replaceWithResolve}),restoreSelection=queue$2.wrap(`restoreSelection`,element=>{element?.partSelect?.()},{selectPart:queue$2.resolution.replaceWithResolve,deselectPart:queue$2.resolution.replaceWithResolve,restoreSelection:queue$2.resolution.replaceWithResolve}),dropdownOpened=val=>opts.stickyPartSelection=val,skipLicGen=ref(!1),licensePlate=ref(``),licensePlateTextValid=ref(!0),settingsChanged=async()=>skipLicGen.value=await Lua_default.settings.getValue(`SkipGenerateLicencePlate`),getLicensePlate=()=>bngApi.engineLua(`core_vehicles.getVehicleLicenseText(getPlayerVehicle(0))`,str=>licensePlate.value=str),applyLicensePlateDebounced=debounce(()=>{opts.applyPartChangesAutomatically&&applyLicensePlate()},500);function applyLicensePlate(){applyLicensePlateDebounced.cancel(),licensePlateTextValid.value&&Lua_default.core_vehicles.setPlateText(licensePlate.value)}function applyRandomLicensePlate(){bngApi.engineLua(`core_vehicles.setPlateText(core_vehicles.regenerateVehicleLicenseText(getPlayerVehicle(0)),nil,nil,nil)`),getLicensePlate()}let isLicensePlateTextValid=text=>(Lua_default.core_vehicles.isLicensePlateValid(text).then(valid=>{licensePlateTextValid.value=valid}),licensePlateTextValid.value),changedPart=null;async function partConfigChanged(part){changedPart=part,opts.applyPartChangesAutomatically?await write():(part.changed=!0,partsChanged.value=!0)}let write=queue$2.wrap(`write`,async()=>{waitingForData.value=!0,await Lua_default.extensions.core_vehicle_partmgmt.setPartsTreeConfig(currentConfig.value),await waitForData()},{write:queue$2.resolution.merge,reset:queue$2.resolution.resolveThis,resetAllToLoadedConfig:queue$2.resolution.resolveThis});queue$2.wrap(`reset`,async()=>{waitingForData.value=!0,await Lua_default.extensions.core_vehicle_partmgmt.resetPartsToLoadedConfig(),await waitForData()},{write:queue$2.resolution.resolveThis,reset:queue$2.resolution.merge,resetAllToLoadedConfig:queue$2.resolution.resolveThis});let resetAllToLoadedConfig=queue$2.wrap(`resetAllToLoadedConfig`,async()=>{waitingForData.value=!0,await Lua_default.extensions.core_vehicle_partmgmt.resetAllToLoadedConfig(),await waitForData()},{write:queue$2.resolution.resolveThis,reset:queue$2.resolution.resolveThis,resetAllToLoadedConfig:queue$2.resolution.merge});function processConfig(config){treeStateSave(),waitingForData.value=!0,richPartInfo.value=Object.fromEntries(Object.entries(config.richPartInfo).map(([name,info])=>[name,info.information])),partsHighlighted=config.partsHighlighted;let processSlot=(slot,slotName,parentSlotName=void 0)=>{if(slot.slotName=slotName,slot.parentSlotName=parentSlotName,changedPart&&changedPart.chosenPartName===slot.chosenPartName&&(changedPart=slot),slot.highlight=config.partsHighlighted[slot.partPath],typeof slot.children==`object`)if(Object.keys(slot.children).length===0)delete slot.children;else for(let childSlotName in slot.children)slot.children[childSlotName]=processSlot(slot.children[childSlotName],childSlotName,slot.chosenPartName);return(typeof slot.suitablePartNames!=`object`||!Array.isArray(slot.suitablePartNames))&&(slot.suitablePartNames=[]),(typeof slot.unsuitablePartNames!=`object`||!Array.isArray(slot.unsuitablePartNames))&&(slot.unsuitablePartNames=[]),slot};currentVehID=config.vehID,currentConfig.value=processSlot(config.chosenPartsTree,config.chosenPartsTree.chosenPartName),partsChanged.value=!1,waitingForData.value=!1,nextTick(()=>{opts.stickyPartSelection=!1,deselectPart(),treeStateLoad(),changedPart=null,opts.applyPartChangesAutomatically&&!mouseUsedLast?restoreSelection(document.activeElement):restoreHighlight()})}events$3.on(`VehicleConfigChange`,processConfig);let readOption=(name,val=null)=>JSON.parse(localStorage.getItem(name)||JSON.stringify(val)),saveOption=(name,val)=>localStorage.setItem(name,JSON.stringify(val)),treeStateStorage=sessionStorage,treeStateSave=()=>currentConfig.value.chosenPartName&&treeStateStorage.setItem(`${treeStateKey}_${currentConfig.value.chosenPartName}`,JSON.stringify(treeState.value)),treeStateLoad=()=>{if(!currentConfig.value.chosenPartName)return;let state=treeStateStorage.getItem(`${treeStateKey}_${currentConfig.value.chosenPartName}`);if(state)try{treeState.value=JSON.parse(state)}catch{treeState.value={}}else treeState.value={}};return onMounted(()=>{settingsChanged(),getLicensePlate(),Lua_default.extensions.core_vehicle_partmgmt.sendDataToUI();for(let name of savedOptions)opts[name]=readOption(name,opts[name])}),onUnmounted(()=>{treeStateSave(),deselectPart(!1)}),(_ctx,_cache)=>withDirectives((openBlock(),createElementBlock(`div`,{class:normalizeClass({"parts-browser":!0,"with-background":__props.withBackground})},[withDirectives((openBlock(),createElementBlock(`div`,{class:`parts-browser-search`,onActivate:_cache[5]||=(...args)=>search$1.start&&search$1.start(...args),onDeactivate:_cache[6]||=()=>!search$1.text&&search$1.stop()},[createVNode(unref(bngInput_default),{modelValue:search$1.text,"onUpdate:modelValue":_cache[0]||=$event=>search$1.text=$event,modelModifiers:{trim:!0},"leading-icon":unref(icons).search,"floating-label":`Search`,onClick:_cache[1]||=$event=>search$1.start(),onValueChanged:_cache[2]||=$event=>search$1.onChange(),onKeydown:_cache[3]||=$event=>search$1.history.onKeyDown($event)},null,8,[`modelValue`,`leading-icon`]),withDirectives(createVNode(unref(bngButton_default),{icon:unref(icons).mathMultiply,style:`font-size: 0.75rem`,accent:unref(ACCENTS).text,onClick:_cache[4]||=$event=>search$1.stop()},null,8,[`icon`,`accent`]),[[unref(BngDisabled_default),!search$1.active]])],32)),[[unref(BngScopedNav_default),{bubbleWhitelistEvents:[`menu`]}]]),withDirectives((openBlock(),createElementBlock(`div`,{class:`parts-browser-content-wrapper`,onMouseleave:_cache[7]||=(...args)=>unref(deselectPart)&&unref(deselectPart)(...args),onDeactivate:_cache[8]||=(...args)=>unref(deselectPart)&&unref(deselectPart)(...args)},[createBaseVNode(`div`,_hoisted_1$107,[!search$1.active&¤tConfig.value?.children&&Object.keys(currentConfig.value.children).length>0?(openBlock(),createBlock(PartsBranch_default,{key:0,"root-slot":``,children:currentConfig.value.children,info:richPartInfo.value,"tree-state":treeState.value,"display-names":opts.showNames,"show-auxiliary":opts.showAux,"separate-sort":opts.separateSort,"always-sort":opts.alwaysSort,"show-empty":opts.showEmpty,onSelect:unref(selectPart),onDeselect:unref(deselectPart),onHighlight:highlightPart,onChange:partConfigChanged,onDropdown:dropdownOpened},null,8,[`children`,`info`,`tree-state`,`display-names`,`show-auxiliary`,`separate-sort`,`always-sort`,`show-empty`,`onSelect`,`onDeselect`])):search$1.active?(openBlock(),createElementBlock(`div`,_hoisted_2$90,[createVNode(PartsBranch_default,{children:search$1.result,info:richPartInfo.value,"tree-state":treeState.value,"flat-entry":``,"display-names":opts.showNames,"show-auxiliary":opts.showAux,"separate-sort":opts.separateSort,"always-sort":opts.alwaysSort,"show-empty":opts.showEmpty,highlighter:search$1.highlight,onSelect:unref(selectPart),onDeselect:unref(deselectPart),onHighlight:highlightPart,onChange:partConfigChanged,onDropdown:dropdownOpened},null,8,[`children`,`info`,`tree-state`,`display-names`,`show-auxiliary`,`separate-sort`,`always-sort`,`show-empty`,`highlighter`,`onSelect`,`onDeselect`]),withDirectives(createBaseVNode(`div`,null,[createVNode(unref(bngIcon_default),{type:unref(icons).danger,color:`#d60`},null,8,[`type`]),createBaseVNode(`span`,_hoisted_3$78,toDisplayString(search$1.message),1)],512),[[vShow,search$1.message!==``]]),withDirectives(createBaseVNode(`div`,_hoisted_4$60,[_cache[37]||=createBaseVNode(`hr`,null,null,-1),_cache[38]||=createTextVNode(` Examples: `,-1),createBaseVNode(`ul`,null,[createBaseVNode(`li`,null,[_cache[23]||=createBaseVNode(`span`,{class:`search-example`},`left`,-1),_cache[24]||=createBaseVNode(`br`,null,null,-1),createTextVNode(` `+toDisplayString(_ctx.$t(`ui.vehicleconfig.searchHelp.example1`)),1)]),createBaseVNode(`li`,null,[_cache[25]||=createBaseVNode(`span`,{class:`search-example`},`slot:_fr`,-1),_cache[26]||=createBaseVNode(`br`,null,null,-1),createTextVNode(` `+toDisplayString(_ctx.$t(`ui.vehicleconfig.searchHelp.example2`)),1)]),createBaseVNode(`li`,null,[_cache[27]||=createBaseVNode(`span`,{class:`search-example`},`name:frame`,-1),_cache[28]||=createBaseVNode(`br`,null,null,-1),createTextVNode(` `+toDisplayString(_ctx.$t(`ui.vehicleconfig.searchHelp.example3`)),1)]),createBaseVNode(`li`,null,[_cache[29]||=createBaseVNode(`span`,{class:`search-example`},`slot:_fr name:signal`,-1),_cache[30]||=createBaseVNode(`br`,null,null,-1),createTextVNode(` `+toDisplayString(_ctx.$t(`ui.vehicleconfig.searchHelp.example4`)),1)]),createBaseVNode(`li`,null,[_cache[31]||=createBaseVNode(`span`,{class:`search-example`},`partname:pickup_fr`,-1),_cache[32]||=createBaseVNode(`br`,null,null,-1),createTextVNode(` `+toDisplayString(_ctx.$t(`ui.vehicleconfig.searchHelp.example5`)),1)]),createBaseVNode(`li`,null,[_cache[33]||=createBaseVNode(`span`,{class:`search-example`},`author:bob`,-1),_cache[34]||=createBaseVNode(`br`,null,null,-1),createTextVNode(` `+toDisplayString(_ctx.$t(`ui.vehicleconfig.searchHelp.example6`)),1)]),createBaseVNode(`li`,null,[_cache[35]||=createBaseVNode(`span`,{class:`search-example`},`mod:super`,-1),_cache[36]||=createBaseVNode(`br`,null,null,-1),createTextVNode(` `+toDisplayString(_ctx.$t(`ui.vehicleconfig.searchHelp.example7`)),1)])]),_cache[39]||=createBaseVNode(`hr`,null,null,-1),createTextVNode(` `+toDisplayString(_ctx.$t(`ui.vehicleconfig.searchHelp.notes`))+`: `,1),createBaseVNode(`ul`,null,[createBaseVNode(`li`,null,toDisplayString(_ctx.$t(`ui.vehicleconfig.searchHelp.notes1`)),1),createBaseVNode(`li`,null,toDisplayString(_ctx.$t(`ui.vehicleconfig.searchHelp.notes3`)),1)])],512),[[vShow,Object.keys(search$1.result).length===0]]),search$1.history.browsing&&search$1.history.list.length>0?(openBlock(),createElementBlock(`div`,_hoisted_5$50,[_cache[40]||=createBaseVNode(`hr`,null,null,-1),createTextVNode(` `+toDisplayString(_ctx.$t(`ui.vehicleconfig.searchHelp.history`))+`: `,1),_cache[41]||=createBaseVNode(`br`,null,null,-1),_cache[42]||=createBaseVNode(`br`,null,null,-1),(openBlock(!0),createElementBlock(Fragment,null,renderList(search$1.history.list,(historyEntry,idx)=>(openBlock(),createElementBlock(`span`,{class:normalizeClass({"history-entry":!0,"history-indicator":idx===search$1.history.index})},toDisplayString(historyEntry),3))),256)),_cache[43]||=createBaseVNode(`br`,null,null,-1),createTextVNode(` `+toDisplayString(_ctx.$t(`ui.vehicleconfig.searchHelp.historyClear`)),1)])):createCommentVNode(``,!0)])):createCommentVNode(``,!0)])],32)),[[unref(BngScopedNav_default),{bubbleWhitelistEvents:[`menu`]}]]),createBaseVNode(`div`,_hoisted_6$37,[createBaseVNode(`div`,_hoisted_7$31,[withDirectives(createVNode(unref(bngButton_default),{accent:unref(ACCENTS).secondary,icon:unref(icons).sortAsc,disabled:waitingForData.value},null,8,[`accent`,`icon`,`disabled`]),[[unref(BngPopover_default),`parts-options-menu`,`top-start`,{click:!0}],[unref(BngTooltip_default),_ctx.$t(`ui.garage.optionsSwitch`),`right`]]),createVNode(unref(bngPopoverMenu_default),{name:`parts-options-menu`,focus:``},{default:withCtx(()=>[createBaseVNode(`div`,_hoisted_8$24,[withDirectives((openBlock(),createBlock(unref(bngButton_default),{accent:unref(ACCENTS).menu,icon:opts.showAux?unref(icons).checkmark:unref(icons)._empty,onClick:_cache[9]||=$event=>saveOption(`showAux`,opts.showAux=!opts.showAux)},{default:withCtx(()=>[createTextVNode(toDisplayString(_ctx.$t(`ui.showAuxiliary`)),1)]),_:1},8,[`accent`,`icon`])),[[unref(BngOnUiNav_default),void 0,`ok`,{focusRequired:!0,asMouse:!0}]]),withDirectives((openBlock(),createBlock(unref(bngButton_default),{accent:unref(ACCENTS).menu,icon:opts.showNames?unref(icons).checkmark:unref(icons)._empty,onClick:_cache[10]||=$event=>saveOption(`showNames`,opts.showNames=!opts.showNames)},{default:withCtx(()=>[createTextVNode(toDisplayString(_ctx.$t(`ui.vehicleconfig.displayNames`)),1)]),_:1},8,[`accent`,`icon`])),[[unref(BngOnUiNav_default),void 0,`ok`,{focusRequired:!0,asMouse:!0}]]),withDirectives((openBlock(),createBlock(unref(bngButton_default),{accent:unref(ACCENTS).menu,icon:opts.selectSubParts?unref(icons).checkmark:unref(icons)._empty,onClick:_cache[11]||=$event=>saveOption(`selectSubParts`,opts.selectSubParts=!opts.selectSubParts)},{default:withCtx(()=>[createTextVNode(toDisplayString(_ctx.$t(`ui.vehicleconfig.subparts`)),1)]),_:1},8,[`accent`,`icon`])),[[unref(BngOnUiNav_default),void 0,`ok`,{focusRequired:!0,asMouse:!0}]]),withDirectives((openBlock(),createBlock(unref(bngButton_default),{accent:unref(ACCENTS).menu,icon:opts.separateSort?unref(icons).checkmark:unref(icons)._empty,onClick:_cache[12]||=$event=>saveOption(`separateSort`,opts.separateSort=!opts.separateSort)},{default:withCtx(()=>[..._cache[44]||=[createTextVNode(`Sort sublists separately`,-1)]]),_:1},8,[`accent`,`icon`])),[[unref(BngOnUiNav_default),void 0,`ok`,{focusRequired:!0,asMouse:!0}]]),withDirectives((openBlock(),createBlock(unref(bngButton_default),{accent:unref(ACCENTS).menu,icon:opts.alwaysSort?unref(icons).checkmark:unref(icons)._empty,onClick:_cache[13]||=$event=>saveOption(`alwaysSort`,opts.alwaysSort=!opts.alwaysSort)},{default:withCtx(()=>[..._cache[45]||=[createTextVNode(`Always sort by name`,-1)]]),_:1},8,[`accent`,`icon`])),[[unref(BngOnUiNav_default),void 0,`ok`,{focusRequired:!0,asMouse:!0}]]),unref(isDev)?withDirectives((openBlock(),createBlock(unref(bngButton_default),{key:0,accent:unref(ACCENTS).menu,icon:opts.showEmpty?unref(icons).checkmark:unref(icons)._empty,onClick:_cache[14]||=$event=>opts.showEmpty=!opts.showEmpty},{default:withCtx(()=>[..._cache[46]||=[createTextVNode(`Show empty slots 🐞`,-1)]]),_:1},8,[`accent`,`icon`])),[[unref(BngOnUiNav_default),void 0,`ok`,{focusRequired:!0,asMouse:!0}]]):createCommentVNode(``,!0)])]),_:1})]),createBaseVNode(`div`,_hoisted_9$21,[createVNode(unref(bngSwitch_default),{disabled:partsChanged.value||waitingForData.value,modelValue:opts.applyPartChangesAutomatically,"onUpdate:modelValue":_cache[15]||=$event=>opts.applyPartChangesAutomatically=$event,onValueChanged:_cache[16]||=$event=>saveOption(`applyPartChangesAutomatically`,opts.applyPartChangesAutomatically)},{default:withCtx(()=>[createTextVNode(toDisplayString(_ctx.$t(`ui.garage.liveUpdates`)),1)]),_:1},8,[`disabled`,`modelValue`])])]),createBaseVNode(`div`,_hoisted_10$15,[withDirectives((openBlock(),createElementBlock(`div`,_hoisted_11$13,[createVNode(unref(bngInput_default),{modelValue:licensePlate.value,"onUpdate:modelValue":_cache[17]||=$event=>licensePlate.value=$event,"floating-label":_ctx.$t(`ui.vehicleconfig.licensePlate`),maxlength:`50`,onValueChanged:_cache[18]||=$event=>unref(applyLicensePlateDebounced)(),onKeyup:_cache[19]||=withKeys($event=>applyLicensePlate(),[`enter`]),validate:isLicensePlateTextValid},null,8,[`modelValue`,`floating-label`]),withDirectives(createVNode(unref(bngButton_default),{accent:unref(ACCENTS).outlined,icon:unref(icons).sync,onClick:_cache[20]||=$event=>applyRandomLicensePlate()},null,8,[`accent`,`icon`]),[[unref(BngTooltip_default),_ctx.$t(`ui.vehicleconfig.licensePlateGen`),`top`]]),opts.applyPartChangesAutomatically?createCommentVNode(``,!0):withDirectives((openBlock(),createBlock(unref(bngButton_default),{key:0,disabled:!licensePlateTextValid.value,icon:unref(icons).checkmark,onClick:_cache[21]||=$event=>applyLicensePlate()},null,8,[`disabled`,`icon`])),[[unref(BngTooltip_default),_ctx.$t(`ui.vehicleconfig.applyLicensePlate`),`top`]])])),[[unref(BngDisabled_default),skipLicGen.value||waitingForData.value],[unref(BngScopedNav_default),{bubbleWhitelistEvents:[`menu`]}]]),createBaseVNode(`div`,_hoisted_12$9,[withDirectives(createVNode(unref(bngButton_default),{"show-hold":``,icon:unref(icons).undo,accent:unref(ACCENTS).custom,class:`reset-button`,disabled:waitingForData.value},null,8,[`icon`,`accent`,`disabled`]),[[unref(BngOnUiNav_default),void 0,`ok`,{asMouse:!0,focusRequired:!0}],[unref(BngClick_default),{holdCallback:unref(resetAllToLoadedConfig),holdDelay:1e3,repeatInterval:0}],[unref(BngTooltip_default),`Reset to original config`]]),createVNode(unref(bngButton_default),{class:`parts-apply-button`,icon:unref(icons).checkmark,onClick:_cache[22]||=$event=>unref(write)(),disabled:opts.applyPartChangesAutomatically||!partsChanged.value||waitingForData.value},{default:withCtx(()=>[createTextVNode(toDisplayString(_ctx.$t(`ui.common.apply`)),1)]),_:1},8,[`icon`,`disabled`])])])],2)),[[unref(BngBlur_default),__props.withBackground]])}},Parts_default=__plugin_vue_export_helper_default(_sfc_main$118,[[`__scopeId`,`data-v-13e05ae0`]]),_hoisted_1$106={key:0,class:`saveload-static`},_hoisted_2$89={class:`saveload-row saveload-filename`},_hoisted_3$77={class:`saveload-list`},_hoisted_4$59=[`onClick`],_hoisted_5$49={class:`saveload-list-item-label`},_hoisted_6$36={class:`saveload-static saveload-row saveload-controls`},_sfc_main$117={__name:`Save`,props:{withBackground:Boolean},setup(__props){useUINavBlocker().blockOnly([`context`]);let{api:api$1}=useBridge(),events$3=useEvents(),saveThumbnail=ref(!0),configList=ref([]),configFiltered=computed(()=>{let res=configList.value;return saveName.value&&(res=res.filter(itm=>itm.name.toLowerCase().includes(saveName.value.toLowerCase()))),res=res.slice().sort((a$1,b)=>a$1.player&&!b.player?-1:!a$1.player&&b.player?1:a$1.name.localeCompare(b.name)),res}),saveDisabled=computed(()=>!saveName.value||/^\.|[<>:"/\\|?*]/.test(saveName.value)),saveName=ref(``),configExists=computed(()=>!!configList.value.some(itm=>itm.name.toLowerCase()===saveName.value.toLowerCase()));async function openConfigFolderInExplorer(){await Lua_default.extensions.core_vehicle_partmgmt.openConfigFolderInExplorer()}async function save(configName){configExists.value&&!await openConfirmation(`Are you sure?`,$translate.instant(`ui.garage.save.overwrite`),[{label:`Overwrite`,value:!0},{label:`Cancel`,value:!1,extras:{accent:ACCENTS.secondary}}])||(await Lua_default.extensions.core_vehicle_partmgmt.saveLocal(configName+`.pc`),saveThumbnail.value&&api$1.engineLua(`extensions.load('util_screenshotCreator'); util_screenshotCreator.startWork({selection="${configName}"})`))}async function load(configName){await Lua_default.extensions.core_vehicle_partmgmt.loadLocal(configName+`.pc`)}async function remove$3(configName){await openConfirmation(`Are you sure?`,`This will permanently remove the configuration. You will not be able to recover it.`,[{label:`Delete permanently`,value:!0,extras:{accent:ACCENTS.attention}},{label:`Cancel`,value:!1,extras:{accent:ACCENTS.secondary}}])&&(await Lua_default.extensions.core_vehicle_partmgmt.removeLocal(configName),await getConfigList())}async function getConfigList(){let configs$1=await Lua_default.extensions.core_vehicle_partmgmt.getConfigList();configList.value=Array.isArray(configs$1)?configs$1:[]}return events$3.on(`VehicleChange`,getConfigList),events$3.on(`VehicleFocusChanged`,getConfigList),events$3.on(`VehicleconfigSaved`,getConfigList),getConfigList(),(_ctx,_cache)=>withDirectives((openBlock(),createElementBlock(`div`,{class:normalizeClass({saveload:!0,"with-background":__props.withBackground})},[configList.value?(openBlock(),createElementBlock(`div`,_hoisted_1$106,[createBaseVNode(`div`,_hoisted_2$89,[createVNode(unref(bngInput_default),{modelValue:saveName.value,"onUpdate:modelValue":_cache[0]||=$event=>saveName.value=$event,modelModifiers:{trim:!0},"leading-icon":unref(icons).saveAs1,"floating-label":_ctx.$t(`ui.vehicleconfig.filename`)},null,8,[`modelValue`,`leading-icon`,`floating-label`]),withDirectives(createVNode(unref(bngButton_default),{icon:unref(icons).mathMultiply,style:`font-size: 0.75rem`,accent:unref(ACCENTS).text,onClick:_cache[1]||=$event=>saveName.value=``},null,8,[`icon`,`accent`]),[[unref(BngDisabled_default),!saveName.value]]),withDirectives((openBlock(),createBlock(unref(bngButton_default),{accent:configExists.value?unref(ACCENTS).attention:unref(ACCENTS).main,onClick:_cache[2]||=$event=>save(saveName.value)},{default:withCtx(()=>[createTextVNode(toDisplayString(configExists.value?_ctx.$t(`ui.common.overwrite`):_ctx.$t(`ui.common.save`)),1)]),_:1},8,[`accent`])),[[unref(BngDisabled_default),saveDisabled.value]])])])):createCommentVNode(``,!0),createBaseVNode(`div`,_hoisted_3$77,[(openBlock(!0),createElementBlock(Fragment,null,renderList(configFiltered.value,config=>(openBlock(),createElementBlock(`div`,{class:`saveload-list-item`,onClick:$event=>saveName.value=config.name,tabindex:`1`},[config.official?withDirectives((openBlock(),createBlock(unref(bngIcon_default),{key:0,type:unref(icons).beamNG},null,8,[`type`])),[[unref(BngTooltip_default),_ctx.$t(`ui.vehicleconfig.sourceOfficial`),`top`]]):config.player?withDirectives((openBlock(),createBlock(unref(bngIcon_default),{key:1,type:unref(icons).personSolid},null,8,[`type`])),[[unref(BngTooltip_default),_ctx.$t(`ui.vehicleconfig.sourceUser`),`top`]]):withDirectives((openBlock(),createBlock(unref(bngIcon_default),{key:2,type:unref(icons).puzzleModule},null,8,[`type`])),[[unref(BngTooltip_default),_ctx.$t(`ui.vehicleconfig.sourceMod`),`top`]]),createBaseVNode(`div`,_hoisted_5$49,toDisplayString(config.name),1),withDirectives((openBlock(),createBlock(unref(bngButton_default),{class:`saveload-list-item-load`,accent:unref(ACCENTS).outlined,icon:unref(icons).BNGFolder,onClick:withModifiers($event=>load(config.name),[`stop`])},{default:withCtx(()=>[createTextVNode(toDisplayString(_ctx.$t(`ui.vehicleconfig.load`)),1)]),_:1},8,[`accent`,`icon`,`onClick`])),[[unref(BngTooltip_default),_ctx.$t(`ui.vehicleconfig.loadTooltip`),`top`]]),config.player?withDirectives((openBlock(),createBlock(unref(bngButton_default),{key:3,class:`saveload-list-item-delete`,accent:unref(ACCENTS).outlined,icon:unref(icons).trashBin2,onClick:withModifiers($event=>remove$3(config.name),[`stop`])},null,8,[`accent`,`icon`,`onClick`])),[[unref(BngTooltip_default),`Remove configuration`,`top`]]):createCommentVNode(``,!0)],8,_hoisted_4$59))),256))]),createBaseVNode(`div`,_hoisted_6$36,[createVNode(unref(bngSwitch_default),{modelValue:saveThumbnail.value,"onUpdate:modelValue":_cache[3]||=$event=>saveThumbnail.value=$event},{default:withCtx(()=>[createTextVNode(toDisplayString(_ctx.$t(`ui.vehicleconfig.saveThumbnail`)),1)]),_:1},8,[`modelValue`]),createVNode(unref(bngButton_default),{accent:unref(ACCENTS).main,onClick:_cache[4]||=$event=>openConfigFolderInExplorer()},{default:withCtx(()=>[createTextVNode(toDisplayString(_ctx.$t(`ui.vehicleconfig.openConfigFolder`)),1)]),_:1},8,[`accent`])])],2)),[[unref(BngBlur_default),__props.withBackground]])}},Save_default=__plugin_vue_export_helper_default(_sfc_main$117,[[`__scopeId`,`data-v-31dd4dbb`]]),_hoisted_1$105={class:`garage-row-title`},_hoisted_2$88={class:`headingContainer`},_hoisted_3$76={class:`garage-title-sup`},_hoisted_4$58={class:`garage-title-main`},_hoisted_5$48={class:`garage-row-main`},_hoisted_6$35={class:`garage-menu-container garage-menu-main`},_hoisted_7$30={key:0,class:`garage-menu garage-menu-primary`},_hoisted_8$23={key:1,class:`garage-menu garage-menu-secondary`},_hoisted_9$20={key:2,class:`garage-content`},_hoisted_10$14={class:`garage-sidemenu-title`},_hoisted_11$12={class:`garage-drawer-header`},_hoisted_12$8={class:`garage-drawer-content`},_hoisted_13$8={class:`garage-drawer-header`},_hoisted_14$8={class:`garage-drawer-content`},_hoisted_15$8={class:`garage-drawer-header`},_hoisted_16$8={class:`garage-drawer-content`},_hoisted_17$7={class:`garage-row-bottom`},ownerId=`garage`,_sfc_main$116={__name:`Garage`,props:{component:String},setup(__props){let components={paint:Paint_default,parts:Parts_default,tuning:Tuning_default,save:Save_default},uiNavTracker=useUINavTracker(),{showIfController}=storeToRefs(controls_default()),{lua,api:api$1}=useBridge(),events$3=useEvents(),bngVue$1=window.bngVue||{gotoGameState(){}},backBinding=ref(null),streamsList$1=[`electrics`];useStreams(streamsList$1,onStreamsUpdate);let drawerCamera=ref(!1),drawerVehicle=ref(!1),drawerGarage=ref(!1);watch(()=>showIfController,val=>val?uiNavTracker.addIgnore(`action_4`,ownerId):uiNavTracker.removeIgnore(`action_4`,ownerId),{immediate:!0});let launchLiveryEditor=async()=>{await runRaw(`extensions.core_vehicle_partmgmt.hasAvailablePart(be:getPlayerVehicle(0).JBeam .. "_skin_dynamicTextures")`)?await openExperimental(`Dynamic Decals`,`This is an early highly experimental preview of the Decal Editor. Please be aware that anything created with this feature may be lost in future hotfixes and updates. Do you wish to proceed?`,[{label:$translate.instant(`ui.common.no`),value:!1,extras:{accent:ACCENTS.secondary}},{label:`Yes, I'm buckled up and ready to go!`,value:!0,extras:{default:!0}}])&&bngVue$1.gotoGameState(`livery-manager`):openMessage(``,$translate.instant(`ui.garage.decals.notAvailableForVehicle`))},props=__props,sidemenuActive=ref(!1);function activateSidemenu(){sidemenuActive.value=!0}function deactivateSidemenu(){sidemenuActive.value=!1,nextTick(()=>{drawerCamera.value=!1,drawerVehicle.value=!1,drawerGarage.value=!1})}function toggleSidemenu(){sidemenuActive.value=!sidemenuActive.value}let canSidemenuDeactivate=()=>!drawerCamera.value&&!drawerVehicle.value&&!drawerGarage.value,lightState=ref([!1,!1,!1]);async function lightToggle(idx){lightState.value[idx]=!lightState.value[idx],await lua.extensions.gameplay_garageMode.setLighting(lightState.value)}async function setCamera(view){await lua.extensions.gameplay_garageMode.setCamera(view)}let switches=reactive({lowbeam:{func:`setLightsState`,value:`lights_state`,on:1,off:0,state:!1},highbeam:{func:`setLightsState`,value:`lights_state`,on:2,off:0,state:!1},fog:{func:`set_fog_lights`,value:`fog`,on:1,off:0,state:!1},lightbar:{func:`set_lightbar_signal`,value:`lightbar`,on:1,off:0,state:!1},hazard:{func:`set_warn_signal`,value:`hazard_enabled`,on:1,off:0,state:!1}});function vehSwitch(key,on){if(!(key in switches))return;let svc=switches[key];if(on===void 0)on=!svc.state;else if(on===svc.state)return;api$1.activeObjectLua(`electrics.${svc.func}(${on?svc.on:svc.off})`)}let loaded=reactive({init:!1,vehicle:!1,status:!1}),vehicle=reactive({name:`Unknown`,vehicle:null,electrics:{},state:{}}),blackscreen=ref(!1),vehcomp=ref(``),vehcompview=ref(null),tmrInit;async function menuOpen(mode){vehcomp.value=vehcomp.value===mode?``:mode;let component=null;switch(mode){case`paint`:lua.extensions.gameplay_garageMode.setGarageMenuState(`paint`),component=components.paint;break;case`decals`:bngVue$1.gotoGameState(`decals-loader`);break;case`parts`:lua.extensions.gameplay_garageMode.setGarageMenuState(`parts`),component=components.parts;break;case`tuning`:lua.extensions.gameplay_garageMode.setGarageMenuState(`tuning`),component=components.tuning;break;case`vehicles`:lua.extensions.gameplay_garageMode.setGarageMenuState(`vehicles`),bngVue$1.gotoGameState(`menu.vehicles`,{params:{mode:`garageMode`,garage:`all`}});break;case`mycars`:lua.extensions.gameplay_garageMode.setGarageMenuState(`myCars`),bngVue$1.gotoGameState(`menu.vehicles`,{params:{mode:`garageMode`,garage:`own`}});break;case`photo`:bngVue$1.gotoGameState(`menu.photomode`);break;case`save`:component=components.save;break;case`savedefault`:console.log(`TODO: save as default`);break;case`test`:vehcomp.value=``,lua.extensions.gameplay_garageMode.testVehicle();break;default:vehcomp.value=``;break}component&&(vehcompview.value=markRaw(component))}function exit(event){event.detail.force||(vehcomp.value?menuOpen():window.bngVue.gotoAngularState(`menu.mainmenu`))}async function vehChange(){loaded.vehicle=!1,loaded.status=!1,vehicle.name=`Unknown`,vehicle.vehicle=null,vehicle.electrics={},await api$1.activeObjectLua(`electrics.setIgnitionLevel(1)`);let data=await lua.core_vehicles.getCurrentVehicleDetails();tmrInit&&=(loaded.init=!0,clearTimeout(tmrInit),null),data&&(loaded.vehicle=!0,vehicle.vehicle=data,data.model.Brand?vehicle.name=`${data.model.Brand} ${data.model.Name}`:vehicle.name=data.configs.Name,data.configs.Configuration&&(data.configs.Source===`BeamNG - Official`?vehicle.name+=` - ${data.configs.Configuration}`:vehicle.name+=` - Custom`))}function onStreamsUpdate(streams){if(typeof streams!=`object`||!streamsList$1.every(name=>name in streams))return;let data=streams.electrics;for(let key in loaded.status=data.ignitionLevel>0,switches){let svc=switches[key];svc.state=svc.value in data&&data[svc.value]===svc.on,vehicle.electrics[key]=svc.state}}let canScopeDeactivate=()=>!vehcomp.value;return onBeforeMount(async()=>{tmrInit=setTimeout(()=>{console.log(`Unable to get vehicle details in time. Forcing to init...`),loaded.init=!0,tmrInit=null},3e3),events$3.on(`VehicleChange`,vehChange),api$1.activeObjectLua(`electrics.setIgnitionLevel(1)`),events$3.on(`GarageModeBlackscreen`,data=>blackscreen.value=data.active),vehChange(),lightState.value=await lua.extensions.gameplay_garageMode.getLighting(),props.component&&menuOpen(props.component)}),onUnmounted(()=>{tmrInit&&clearTimeout(tmrInit)}),(_ctx,_cache)=>(openBlock(),createElementBlock(Fragment,null,[withDirectives(createBaseVNode(`div`,{class:normalizeClass([`garage-blackscreen`,{"garage-blackscreen-active":blackscreen.value}])},null,2),[[unref(BngBlur_default),blackscreen.value]]),loaded.init?withDirectives((openBlock(),createElementBlock(`div`,{key:0,class:`garage-view`,onDeactivate:exit},[createBaseVNode(`div`,_hoisted_1$105,[createBaseVNode(`div`,_hoisted_2$88,[withDirectives((openBlock(),createElementBlock(`div`,_hoisted_3$76,[createBaseVNode(`h4`,null,[createTextVNode(toDisplayString(_ctx.$t(`ui.mainmenu.garage`))+` `,1),vehcomp.value?(openBlock(),createElementBlock(Fragment,{key:0},[createTextVNode(`/ `+toDisplayString(vehicle.name),1)],64)):createCommentVNode(``,!0)])])),[[unref(BngBlur_default)]]),withDirectives((openBlock(),createElementBlock(`h2`,_hoisted_4$58,[vehcomp.value?withDirectives((openBlock(),createBlock(unref(bngButton_default),{key:0,class:normalizeClass([`garage-back-button`,{"garage-back-binding-shown":backBinding.value?.displayed}]),accent:backBinding.value?.displayed?unref(ACCENTS).ghost:unref(ACCENTS).outlined,icon:unref(icons).arrowLargeLeft,"bng-no-nav":`true`,onClick:exit},{default:withCtx(()=>[withDirectives(createVNode(unref(bngBinding_default),{ref_key:`backBinding`,ref:backBinding,class:`back-binding`,"ui-event":`back`,controller:``,"track-ignore":``},null,512),[[vShow,!sidemenuActive.value]]),createTextVNode(` `+toDisplayString(backBinding.value?.displayed?``:_ctx.$t(`ui.common.back`)),1)]),_:1},8,[`class`,`accent`,`icon`])),[[unref(BngTooltip_default),!backBinding.value||backBinding.value?.displayed?_ctx.$t(`ui.common.back`):void 0,`top`]]):createCommentVNode(``,!0),createBaseVNode(`span`,null,toDisplayString(vehcomp.value?_ctx.$t(`ui.garage.tabs.`+(vehcomp.value===`tuning`?`tune`:vehcomp.value)):vehicle.name),1)])),[[unref(BngBlur_default)]])])]),createBaseVNode(`div`,_hoisted_5$48,[createBaseVNode(`div`,_hoisted_6$35,[vehcomp.value?createCommentVNode(``,!0):(openBlock(),createElementBlock(`div`,_hoisted_7$30,[withDirectives((openBlock(),createBlock(GarageButton_default,{icon:unref(icons).engine,active:vehcomp.value===`parts`,onClick:_cache[0]||=$event=>menuOpen(`parts`),"bng-scoped-nav-autofocus":loaded.vehicle&&!sidemenuActive.value&&unref(showIfController)},{default:withCtx(()=>[createTextVNode(toDisplayString(_ctx.$t(`ui.garage.tabs.parts`)),1)]),_:1},8,[`icon`,`active`,`bng-scoped-nav-autofocus`])),[[unref(BngDisabled_default),!loaded.vehicle],[unref(BngBlur_default)]]),withDirectives((openBlock(),createBlock(GarageButton_default,{icon:unref(icons).wrench,active:vehcomp.value===`tuning`,onClick:_cache[1]||=$event=>menuOpen(`tuning`)},{default:withCtx(()=>[createTextVNode(toDisplayString(_ctx.$t(`ui.garage.tabs.tune`)),1)]),_:1},8,[`icon`,`active`])),[[unref(BngDisabled_default),!loaded.vehicle],[unref(BngBlur_default)]]),withDirectives((openBlock(),createBlock(GarageButton_default,{icon:unref(icons).sprayCan,active:vehcomp.value===`paint`,onClick:_cache[2]||=$event=>menuOpen(`paint`)},{default:withCtx(()=>[createTextVNode(toDisplayString(_ctx.$t(`ui.garage.tabs.paint`)),1)]),_:1},8,[`icon`,`active`])),[[unref(BngDisabled_default),!loaded.vehicle],[unref(BngBlur_default)]]),withDirectives((openBlock(),createBlock(GarageButton_default,{icon:unref(icons).star,active:vehcomp.value===`decals`,onClick:launchLiveryEditor},{default:withCtx(()=>[createTextVNode(toDisplayString(_ctx.$t(`ui.garage.tabs.decals`)),1)]),_:1},8,[`icon`,`active`])),[[unref(BngDisabled_default),!loaded.vehicle],[unref(BngBlur_default)]])])),vehcomp.value?createCommentVNode(``,!0):(openBlock(),createElementBlock(`div`,_hoisted_8$23,[withDirectives((openBlock(),createBlock(GarageButton_default,{icon:unref(icons).car,active:vehcomp.value===`vehicles`,onClick:_cache[3]||=$event=>menuOpen(`vehicles`)},{default:withCtx(()=>[createTextVNode(toDisplayString(_ctx.$t(`ui.garage.tabs.vehicles`)),1)]),_:1},8,[`icon`,`active`])),[[unref(BngDisabled_default),!loaded.vehicle],[unref(BngBlur_default)]]),withDirectives((openBlock(),createBlock(GarageButton_default,{icon:unref(icons).keys1,active:vehcomp.value===`mycars`,onClick:_cache[4]||=$event=>menuOpen(`mycars`)},{default:withCtx(()=>[createTextVNode(toDisplayString(_ctx.$t(`ui.garage.tabs.load`)),1)]),_:1},8,[`icon`,`active`])),[[unref(BngDisabled_default),!loaded.vehicle],[unref(BngBlur_default)]]),withDirectives((openBlock(),createBlock(GarageButton_default,{icon:unref(icons).photo,onClick:_cache[5]||=$event=>menuOpen(`photo`)},{default:withCtx(()=>[createTextVNode(toDisplayString(_ctx.$t(`ui.garage.tabs.photo`)),1)]),_:1},8,[`icon`])),[[unref(BngDisabled_default),!loaded.vehicle],[unref(BngBlur_default)]])])),vehcomp.value&&vehcompview.value?withDirectives((openBlock(),createElementBlock(`div`,_hoisted_9$20,[(openBlock(),createBlock(resolveDynamicComponent(vehcompview.value),{"with-background":``,"with-padding":!1}))])),[[unref(BngOnUiNav_default),exit,`menu,back`],[unref(BngFrustumMover_default),!0,`left`]]):createCommentVNode(``,!0)]),withDirectives((openBlock(),createElementBlock(`div`,{class:`garage-sidemenu`,onActivate:activateSidemenu,onDeactivate:deactivateSidemenu},[withDirectives((openBlock(),createElementBlock(`h4`,_hoisted_10$14,[createVNode(unref(bngBinding_default),{class:`back-binding`,"ui-event":`action_4`,controller:``}),createTextVNode(` `+toDisplayString(_ctx.$t(`ui.garage2.features`)),1)])),[[unref(BngBlur_default)]]),createVNode(unref(drawer_default),{modelValue:drawerCamera.value,"onUpdate:modelValue":_cache[12]||=$event=>drawerCamera.value=$event,position:`left`,class:`garage-menugroup`},{header:withCtx(()=>[withDirectives((openBlock(),createElementBlock(`div`,_hoisted_11$12,[withDirectives((openBlock(),createBlock(GarageButton_default,{type:`drawer-toggle`,icon:unref(icons).movieCamera,active:drawerCamera.value,"bng-scoped-nav-autofocus":sidemenuActive.value&&unref(showIfController),onClick:_cache[6]||=$event=>drawerCamera.value=!drawerCamera.value},{default:withCtx(()=>[createTextVNode(toDisplayString(_ctx.$t(`ui.garage.photo.camera`)),1)]),_:1},8,[`icon`,`active`,`bng-scoped-nav-autofocus`])),[[unref(BngDisabled_default),!loaded.init]])])),[[unref(BngBlur_default)]])]),"expanded-content":withCtx(()=>[withDirectives((openBlock(),createElementBlock(`div`,_hoisted_12$8,[createVNode(GarageButton_default,{type:`drawer-button`,icon:unref(icons).camera3Fourth1,onClick:_cache[7]||=$event=>setCamera(`default`)},{default:withCtx(()=>[createTextVNode(toDisplayString(_ctx.$t(`engine.editor.menu.standartCamera`)),1)]),_:1},8,[`icon`]),createVNode(GarageButton_default,{type:`drawer-button`,icon:unref(icons).cameraFront1,onClick:_cache[8]||=$event=>setCamera(`front`)},{default:withCtx(()=>[createTextVNode(toDisplayString(_ctx.$t(`engine.editor.menu.camera.front`)),1)]),_:1},8,[`icon`]),createVNode(GarageButton_default,{type:`drawer-button`,icon:unref(icons).cameraBack1,onClick:_cache[9]||=$event=>setCamera(`back`)},{default:withCtx(()=>[createTextVNode(toDisplayString(_ctx.$t(`engine.editor.menu.camera.back`)),1)]),_:1},8,[`icon`]),createVNode(GarageButton_default,{type:`drawer-button`,icon:unref(icons).cameraSideRight,onClick:_cache[10]||=$event=>setCamera(`side`)},{default:withCtx(()=>[createTextVNode(toDisplayString(_ctx.$t(`engine.editor.menu.camera.right`)),1)]),_:1},8,[`icon`]),createVNode(GarageButton_default,{type:`drawer-button`,icon:unref(icons).cameraTop1,onClick:_cache[11]||=$event=>setCamera(`top`)},{default:withCtx(()=>[createTextVNode(toDisplayString(_ctx.$t(`engine.editor.menu.camera.top`)),1)]),_:1},8,[`icon`])])),[[unref(BngOnUiNav_default),toggleSidemenu,`menu,back`],[unref(BngBlur_default)]])]),_:1},8,[`modelValue`]),createVNode(unref(drawer_default),{modelValue:drawerVehicle.value,"onUpdate:modelValue":_cache[19]||=$event=>drawerVehicle.value=$event,position:`left`,class:`garage-menugroup`},{header:withCtx(()=>[withDirectives((openBlock(),createElementBlock(`div`,_hoisted_13$8,[withDirectives((openBlock(),createBlock(GarageButton_default,{type:`drawer-toggle`,icon:unref(icons).electronicSchemeOutline,active:drawerVehicle.value,onClick:_cache[13]||=$event=>drawerVehicle.value=!drawerVehicle.value},{default:withCtx(()=>[createTextVNode(toDisplayString(_ctx.$t(`ui.radialmenu2.electrics`)),1)]),_:1},8,[`icon`,`active`])),[[unref(BngDisabled_default),!loaded.vehicle||!loaded.status]])])),[[unref(BngBlur_default)]])]),"expanded-content":withCtx(()=>[withDirectives((openBlock(),createElementBlock(`div`,_hoisted_14$8,[withDirectives((openBlock(),createBlock(GarageButton_default,{type:`drawer-button`,icon:unref(icons).lowBeam,active:vehicle.electrics.lowbeam,onClick:_cache[14]||=$event=>vehSwitch(`lowbeam`)},{default:withCtx(()=>[createTextVNode(toDisplayString(_ctx.$t(`ui.radialmenu2.electrics.headlights.low`)),1)]),_:1},8,[`icon`,`active`])),[[unref(BngDisabled_default),!loaded.vehicle]]),withDirectives((openBlock(),createBlock(GarageButton_default,{type:`drawer-button`,icon:unref(icons).highBeam,active:vehicle.electrics.highbeam,onClick:_cache[15]||=$event=>vehSwitch(`highbeam`)},{default:withCtx(()=>[createTextVNode(toDisplayString(_ctx.$t(`ui.radialmenu2.electrics.headlights.high`)),1)]),_:1},8,[`icon`,`active`])),[[unref(BngDisabled_default),!loaded.vehicle]]),withDirectives((openBlock(),createBlock(GarageButton_default,{type:`drawer-button`,icon:unref(icons).fogLight,active:vehicle.electrics.fog_lights,onClick:_cache[16]||=$event=>vehSwitch(`fog`)},{default:withCtx(()=>[createTextVNode(toDisplayString(_ctx.$t(`ui.radialmenu2.electrics.fog_lights`)),1)]),_:1},8,[`icon`,`active`])),[[unref(BngDisabled_default),!loaded.vehicle]]),withDirectives((openBlock(),createBlock(GarageButton_default,{type:`drawer-button`,icon:unref(icons).hazardLights,active:vehicle.electrics.hazard,onClick:_cache[17]||=$event=>vehSwitch(`hazard`)},{default:withCtx(()=>[createTextVNode(toDisplayString(_ctx.$t(`ui.radialmenu2.electrics.hazard_lights`)),1)]),_:1},8,[`icon`,`active`])),[[unref(BngDisabled_default),!loaded.vehicle]]),withDirectives((openBlock(),createBlock(GarageButton_default,{type:`drawer-button`,icon:unref(icons).wigwags,active:vehicle.electrics.lightbar,onClick:_cache[18]||=$event=>vehSwitch(`lightbar`)},{default:withCtx(()=>[createTextVNode(toDisplayString(_ctx.$t(`ui.radialmenu2.electrics.lightbar`)),1)]),_:1},8,[`icon`,`active`])),[[unref(BngDisabled_default),!loaded.vehicle]])])),[[unref(BngOnUiNav_default),toggleSidemenu,`menu,back`],[unref(BngBlur_default)]])]),_:1},8,[`modelValue`]),createVNode(unref(drawer_default),{modelValue:drawerGarage.value,"onUpdate:modelValue":_cache[24]||=$event=>drawerGarage.value=$event,position:`left`,class:`garage-menugroup`},{header:withCtx(()=>[withDirectives((openBlock(),createElementBlock(`div`,_hoisted_15$8,[withDirectives((openBlock(),createBlock(GarageButton_default,{type:`drawer-toggle`,icon:unref(icons).garage01,active:drawerGarage.value,onClick:_cache[20]||=$event=>drawerGarage.value=!drawerGarage.value},{default:withCtx(()=>[createTextVNode(toDisplayString(_ctx.$t(`ui.garage2.features`)),1)]),_:1},8,[`icon`,`active`])),[[unref(BngDisabled_default),!loaded.init]])])),[[unref(BngBlur_default)]])]),"expanded-content":withCtx(()=>[withDirectives((openBlock(),createElementBlock(`div`,_hoisted_16$8,[createVNode(GarageButton_default,{type:`drawer-button`,icon:unref(icons).lightGarageG32,active:lightState.value[0],onClick:_cache[21]||=$event=>lightToggle(0)},{default:withCtx(()=>[createTextVNode(toDisplayString(_ctx.$t(`ui.garage2.lights.west`)),1)]),_:1},8,[`icon`,`active`]),createVNode(GarageButton_default,{type:`drawer-button`,icon:unref(icons).lightGarageG22,active:lightState.value[1],onClick:_cache[22]||=$event=>lightToggle(1)},{default:withCtx(()=>[createTextVNode(toDisplayString(_ctx.$t(`ui.garage2.lights.middle`)),1)]),_:1},8,[`icon`,`active`]),createVNode(GarageButton_default,{type:`drawer-button`,icon:unref(icons).lightGarageG12,active:lightState.value[2],onClick:_cache[23]||=$event=>lightToggle(2)},{default:withCtx(()=>[createTextVNode(toDisplayString(_ctx.$t(`ui.garage2.lights.east`)),1)]),_:1},8,[`icon`,`active`])])),[[unref(BngOnUiNav_default),toggleSidemenu,`menu,back`],[unref(BngBlur_default)]])]),_:1},8,[`modelValue`])],32)),[[unref(BngScopedNav_default),{activated:sidemenuActive.value,type:`container`,bubbleWhitelistEvents:[`menu`],canDeactivate:canSidemenuDeactivate}],[unref(BngOnUiNav_default),toggleSidemenu,`action_4`]])]),createBaseVNode(`div`,_hoisted_17$7,[withDirectives(createVNode(GarageButton_default,{active:vehcomp.value===`save`,onClick:_cache[25]||=$event=>menuOpen(`save`),icon:unref(icons).saveAs1},null,8,[`active`,`icon`]),[[unref(BngDisabled_default),!loaded.vehicle],[unref(BngBlur_default)],[unref(BngTooltip_default),_ctx.$t(`ui.vehicleconfig.save`),`top`]]),withDirectives(createVNode(GarageButton_default,{onClick:_cache[26]||=$event=>menuOpen(`test`),icon:unref(icons).trafficCone},null,8,[`icon`]),[[unref(BngDisabled_default),!loaded.vehicle],[unref(BngBlur_default)],[unref(BngTooltip_default),_ctx.$t(`ui.common.test`),`top`]])])],32)),[[unref(BngScopedNav_default),{activateOnMount:!0,bubbleWhitelistEvents:[`menu`],canDeactivate:canScopeDeactivate}],[unref(BngOnUiNav_default),toggleSidemenu,`action_4`]]):createCommentVNode(``,!0)],64))}},Garage_default=__plugin_vue_export_helper_default(_sfc_main$116,[[`__scopeId`,`data-v-b5f03823`]]),routes_default$7=[{path:`/garagemode/:component?`,name:`garagemode`,component:Garage_default,props:!0,meta:{infoBar:{visible:!0,showSysInfo:!1},uiApps:{shown:!0}}},{path:`/garagemode/tuning`,name:`garagemode.tuning`,component:Garage_default,props:{component:`tuning`},meta:{infoBar:{visible:!0,showSysInfo:!1},uiApps:{shown:!0}}}],_hoisted_1$104={class:`edit-form`},_sfc_main$115={__name:`FileEditForm`,props:{modelValue:{type:[Object,String,Number,Boolean],required:!0}},emits:[`update:modelValue`],setup(__props,{emit:__emit}){let props=__props,emit$1=__emit,formModel=computed({get:()=>props.modelValue,set:newValue=>{emit$1(`update:modelValue`,newValue)}});return(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$104,[createVNode(unref(bngInput_default),{modelValue:formModel.value.name,"onUpdate:modelValue":_cache[0]||=$event=>formModel.value.name=$event,suffix:`.dyndecals.json`},null,8,[`modelValue`])]))}},FileEditForm_default=__plugin_vue_export_helper_default(_sfc_main$115,[[`__scopeId`,`data-v-c94cd7bf`]]),_sfc_main$114={__name:`RenameLayerForm`,props:{modelValue:{type:[Object,String,Number,Boolean],required:!0}},emits:[`update:modelValue`],setup(__props,{emit:__emit}){let props=__props,emit$1=__emit,formModel=computed({get:()=>props.modelValue,set:newValue=>{emit$1(`update:modelValue`,newValue)}});return(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,null,[createVNode(unref(bngInput_default),{modelValue:formModel.value.name,"onUpdate:modelValue":_cache[0]||=$event=>formModel.value.name=$event},null,8,[`modelValue`])]))}},RenameLayerForm_default=_sfc_main$114,_hoisted_1$103={class:`exit-editor-dialog`},_hoisted_2$87={class:`apply-skin-wrapper`},_sfc_main$113={__name:`ExitEditorDialog`,props:{modelValue:{type:[Object,String,Number,Boolean],required:!0}},emits:[`update:modelValue`],setup(__props,{emit:__emit}){let props=__props,emit$1=__emit,formModel=computed({get:()=>props.modelValue,set:newValue=>{emit$1(`update:modelValue`,newValue)}});return(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$103,[createVNode(unref(bngInput_default),{modelValue:formModel.value.name,"onUpdate:modelValue":_cache[0]||=$event=>formModel.value.name=$event,suffix:`.dyndecals.json`},null,8,[`modelValue`]),createBaseVNode(`div`,_hoisted_2$87,[createVNode(unref(bngPillCheckbox_default),{modelValue:formModel.value.applySkin,"onUpdate:modelValue":_cache[1]||=$event=>formModel.value.applySkin=$event,disabled:!formModel.value.name},{default:withCtx(()=>[..._cache[2]||=[createTextVNode(`Apply Skin`,-1)]]),_:1},8,[`modelValue`,`disabled`])])]))}},ExitEditorDialog_default=__plugin_vue_export_helper_default(_sfc_main$113,[[`__scopeId`,`data-v-b4897c9e`]]);const openEditFileDialog=(title,description,formModel,formValidator)=>openFormDialog(FileEditForm_default,formModel,formValidator,title,description),openRenameLayerDialog=(title,description,formModel,formValidator)=>openFormDialog(RenameLayerForm_default,formModel,formValidator,title,description);var SELECTION_LUA$1=Lua_default.extensions.ui_liveryEditor_selection;const useLayerActionsStore=defineStore(`createLayer`,()=>{async function onActionItemSelected(action){if(!action.items)if(console.log(`[onActionItemSelected] do action`),action.value===`group`)await Lua_default.extensions.ui_liveryEditor_tools_group.groupLayers();else if(action.value===`ungroup`)await Lua_default.extensions.ui_liveryEditor_tools_group.ungroupLayer();else if(action.value===`delete`)await openConfirmation(`Delete Layer`,`Are you sure you want to delete ${singleSelectedLayer.value.name}?`)&&await Lua_default.extensions.ui_liveryEditor_tools_settings.deleteLayer();else if(action.value===`rename`){let res=await openRenameLayerDialog(`Rename Layer`,``,{name:singleSelectedLayer.value.name},model=>model.name!==null&&model.name!==void 0&&model.name!==``&&model.name!==singleSelectedLayer.value.name);res.value&&await Lua_default.extensions.ui_liveryEditor_tools_settings.rename(res.formData.name)}else action.value===`duplicate`?await SELECTION_LUA$1.duplicateSelectedLayer():await Lua_default.extensions.ui_liveryEditor_tools.useTool(action.value)}return{onActionItemSelected}});var EDIT_MODE=Lua_default.extensions.ui_liveryEditor_editMode,DECAL_LAYER=Lua_default.extensions.ui_liveryEditor_layers_decals,TRANSFORM_TOOL=Lua_default.extensions.ui_liveryEditor_tools_transform,MATERIAL_TOOL=Lua_default.extensions.ui_liveryEditor_tools_material,SETTINGS_TOOL=Lua_default.extensions.ui_liveryEditor_tools_settings;const useLayerSettingsStore=defineStore(`layerSettings`,()=>{let{events:events$3}=useBridge(),rootStore=useLiveryEditorStore(),active=ref(!1),targetLayer=ref({}),currentTool=ref(null),toolsData=ref(null),requestApplyActive=ref(!1),decalTexture=ref(null),isChangeDecal=ref(null),activeSettings=ref(null),editModeState=reactive({lockScaling:!1}),isStampMode=computed(()=>toolsData.value&&toolsData.value.mode===`stamp`),_reapplyActive=ref(!1),cursorData=ref(null),_appliedLayers=ref(null),activeLayerUid=ref(null),reapplyActive=computed({get:()=>_reapplyActive.value,set:async newValue=>{newValue?await Lua_default.extensions.ui_liveryEditor_editMode.requestReapply():await Lua_default.extensions.ui_liveryEditor_editMode.cancelReapply()}}),appliedLayers=computed(()=>!_appliedLayers.value||!Array.isArray(_appliedLayers.value)?null:_appliedLayers.value);events$3.on(`liveryEditor_EditMode_OnActiveStatusChanged`,async data=>{console.log(`liveryEditor_EditMode_OnActiveStatusChanged`,data),active.value=data}),events$3.on(`LiveryEditor_CursorUpdated`,async data=>{console.log(`LiveryEditor_CursorUpdated`,data),cursorData.value=data}),events$3.on(`LiveryEditor_SelectedLayersDataUpdated`,async data=>{console.log(`LiveryEditor_SelectedLayersDataUpdated`,data),data&&Array.isArray(data)&&data.length>0&&(targetLayer.value=data[0])}),events$3.on(`liveryEditor_OnSettingsChanged_UseMousePos`,data=>{console.log(`liveryEditor_OnSettingsChanged_UseMousePos`,data),cursorData.value&&(cursorData.value.isUseMousePos=data)}),events$3.on(`liveryEditor_OnEditMode_ReapplyChanged`,data=>{console.log(`liveryEditor_OnEditMode_ReapplyChanged`,data),_reapplyActive.value=data}),events$3.on(`LiveryEditorToolChanged`,data=>{console.log(`LiverEditorToolChanged`,data),currentTool.value=data}),events$3.on(`LiveryEditor_ToolDataUpdated`,async data=>{console.log(`LiveryEditor_ToolDataUpdated`,data),toolsData.value=data}),events$3.on(`liveryEditor_EditMode_OnRequestApplyChanged`,async data=>{console.log(`liveryEditor_EditMode_OnRequestApplyChanged`,data),requestApplyActive.value=data}),events$3.on(`liveryEditor_EditMode_OnAppliedLayersUpdated`,async data=>{console.log(`liveryEditor_EditMode_OnAppliedLayersUpdated`,data),_appliedLayers.value=data}),events$3.on(`liveryEditor_EditMode_OnActiveLayerChanged`,async data=>{console.log(`liveryEditor_EditMode_OnActiveLayerChanged`,data),activeLayerUid.value=data}),events$3.on(`liveryEditor_onDecalTextureChanged`,async data=>{console.log(`liveryEditor_onDecalTextureChanged`,data),console.log(`liveryEditor_onDecalTextureChanged active value`,active.value),active.value?!isChangeDecal.value&&!requestApplyActive.value&&await requestApply():await EDIT_MODE.activate(),await MATERIAL_TOOL.setDecal(data),rootStore.toggleShowDecalSelector(),isChangeDecal.value=null}),events$3.on(`liveryEditor_onDecalSelectorCancelled`,async data=>{console.log(`liveryEditor_onDecalSelectorCancelled`,data),active.value?rootStore.toggleShowDecalSelector():rootStore.toggleEditModeLayout(),isChangeDecal.value=null});function init$3(){active.value?EDIT_MODE.resetCursorProperties([]):rootStore.toggleShowDecalSelector()}let deactivate=async()=>{await Lua_default.extensions.ui_liveryEditor_editMode.deactivate(),rootStore.currentContext=EDITOR_CONTEXT.default,rootStore.editorView=EDITOR_VIEWS.default},toggleRequestApply=async()=>await Lua_default.extensions.ui_liveryEditor_editMode.toggleRequestApply(),requestApply=async()=>await Lua_default.extensions.ui_liveryEditor_editMode.requestApply(),cancelRequestApply=async()=>await Lua_default.extensions.ui_liveryEditor_editMode.cancelRequestApply(),getInitialData=async()=>await Lua_default.extensions.ui_liveryEditor_layers_cursor.requestData(),toggleStamp=async()=>{toolsData.value&&toolsData.value.mode===`stamp`?await Lua_default.extensions.ui_liveryEditor_tools_transform.cancelStamp():await Lua_default.extensions.ui_liveryEditor_tools_transform.useStamp()},setActiveLayer=async layerUid=>{await Lua_default.extensions.ui_liveryEditor_editMode.setActiveLayer(layerUid)},requestReapply=async()=>{await Lua_default.extensions.ui_liveryEditor_editMode.requestReapply()},cancelReapply=async()=>{await Lua_default.extensions.ui_liveryEditor_editMode.cancelReapply()},cancelChanges=async()=>{await Lua_default.extensions.ui_liveryEditor_editMode.cancelChanges(),await Lua_default.extensions.ui_liveryEditor_editMode.deactivate(),await Lua_default.extensions.ui_liveryEditor_tools.closeCurrentTool()},requestChangeDecal=async()=>{isChangeDecal.value=!0,rootStore.toggleShowDecalSelector()},toggleReapply=()=>reapplyActive.value=!reapplyActive.value,apply$1=async()=>await Lua_default.extensions.ui_liveryEditor_editMode.apply(),saveChanges=async params=>{await Lua_default.extensions.ui_liveryEditor_editMode.saveChanges(params),await Lua_default.extensions.ui_liveryEditor_editMode.deactivate(),rootStore.currentContext=EDITOR_CONTEXT.default,rootStore.editorView=EDITOR_VIEWS.default},closeCurrentTool=async()=>{await Lua_default.extensions.ui_liveryEditor_tools.closeCurrentTool()};return{...EDIT_MODE,...TRANSFORM_TOOL,...MATERIAL_TOOL,...SETTINGS_TOOL,...DECAL_LAYER,active,cursorData,appliedLayers,activeLayerUid,requestApplyActive,reapplyActive,decalTexture,editModeState,activeSettings,init:init$3,deactivate,getInitialData,toolsData,targetLayer,isStampMode,toggleStamp,requestReapply,cancelReapply,cancelChanges,requestApply,cancelRequestApply,toggleRequestApply,toggleReapply,setActiveLayer,saveChanges,requestChangeDecal,apply:apply$1,closeCurrentTool}}),useLayersManagerStore=defineStore(`layersManager`,()=>{let{events:events$3}=useBridge(),multipleSelection=ref(!1),_selection=ref([]),selectedLayers=computed({get(){return _selection.value},set(newValue){sendUpdatedSelection(newValue)}});events$3.on(`LiveryEditor_SelectedLayersChanged`,data=>{console.log(`selected Layer Updated`,data),_selection.value=data&&Array.isArray(data)&&data.length>0?data:[]});let sendUpdatedSelection=async selection=>{console.log(`sendUpdatedSelection`,selection),selection.length===0?await Lua_default.extensions.ui_liveryEditor_selection.clearSelection():multipleSelection.value?await Lua_default.extensions.ui_liveryEditor_selection.setMultipleSelected(selection):await Lua_default.extensions.ui_liveryEditor_selection.setSelected(selection)},canSort=data=>{let item=getItemByPath(data.targetDataset.draggablePath);return!(data.intersectionType===INTERSECTION_TYPES.sub&&item.type!==3)};async function clearSelection(){multipleSelection.value=!1,selectedLayers.value=[]}function getItemByPath(path){let pathSegments=path?path.split(`/`):void 0;if(!pathSegments)throw Error(`Path not defined`);let index=parseInt(pathSegments[0]),currentItem=layers.value[index];for(let i=1;i{Lua_default.extensions.ui_liveryEditor_tools_group.changeOrder(oldIndex+1,oldParentUid||``,newIndex+1,newParentUid||``)},clearSelection}});var FIRST_LAYER_ACTIONS=[{value:`edit`,label:`Edit`,icon:icons.edit,validator:()=>!0},{value:`order`,label:`Change Order`,icon:icons.order},{value:`rename`,label:`Rename`,icon:icons.rename},{value:`highlight`,label:`Highlight On`,icon:icons.eyeSolidOpened,toggleAction:!0,inactiveLabel:`Highlight Off`,inactiveIcon:icons.eyeSolidClosed},{value:`visibility`,label:`Enabled`,icon:icons.eyeOutlineOpened,toggleAction:!0,inactiveLabel:`Hidden`,inactiveIcon:icons.eyeOutlineClosed},{value:`delete`,label:`Delete`,icon:icons.trashBin2}],SELECTION_LUA=Lua_default.extensions.ui_liveryEditor_selection,SETTINGS_LUA=Lua_default.extensions.ui_liveryEditor_tools_settings,CAMERA_LUA=Lua_default.extensions.ui_liveryEditor_camera,EDITOR_LUA=Lua_default.extensions.ui_liveryEditor_editor;const EDITOR_CONTEXT={default:`default`,editMode:`editMode`,newLayer:`newLayer`};var SELECT_MODE={single:`single`,multi:`multi`};const EDITOR_VIEWS={default:`default`,decalSelector:`decalSelector`,editMode:`editMode`},useLiveryEditorStore=defineStore(`liveryEditor`,()=>{let{events:events$3}=useBridge(),layers$1=ref(null),visibleLayersCount=ref(null),selectedTool=ref(null),currentFile=ref(null),currentContext=ref(null),history$1=ref(null),selectMode=ref(SELECT_MODE.single),selectedLayers=ref([]),layerActions=ref(null),categories=ref(null),textures=ref(null),editorView=ref(EDITOR_VIEWS.main),cameraView=ref(null),showLayersManager=computed(()=>!(selectedTool.value&¤tContext.value===EDITOR_CONTEXT.editMode)),showLayerActions=computed(()=>selectedLayers.value),selectedLayerUids=computed(()=>selectedLayers.value?selectedLayers.value.map(x=>x.uid):void 0);events$3.on(`liveryEditor_OnLayersUpdated`,data=>{console.log(`liveryEditor_OnLayersUpdated`,data),layers$1.value=data}),events$3.on(`liveryEditor_Layers_OnVisibleCountChanged`,data=>{console.log(`liveryEditor_Layers_OnVisibleCountChanged`,data),visibleLayersCount.value=data}),events$3.on(`LiveryEditor_onSaveFileLoaded`,data=>{console.log(`LiveryEditor_onSaveFileLoaded`,data),currentFile.value=data}),events$3.on(`LiveryEditorLayersUpdate`,data=>{console.log(`LiveryEditorLayersUpdated`,data),layers$1.value=data}),events$3.on(`LiveryEditor_SelectedLayersDataUpdated`,async data=>{console.log(`LiveryEditor_SelectedLayersDataUpdated`,data),selectedLayers.value=data&&Array.isArray(data)?data:void 0}),events$3.on(`LiverEditorLayerActionsUpdated`,async data=>{console.log(`LiverEditorLayerActionsUpdated`,data)}),events$3.on(`LiveryEditor_onHistoryUpdated`,data=>{console.log(`LiveryEditor_onHistoryUpdated`,data),history$1.value=data}),events$3.on(`LiveryEditor_SelectedLayersChanged`,data=>{console.log(`selected Layer Updated`,data),currentContext.value=data&&data.length>0?EDITOR_CONTEXT.selectedLayer:null}),events$3.on(`LiveryEditorToolChanged`,data=>{console.log(`LiverEditorToolChanged`,data),selectedTool.value=data}),events$3.on(`LiveryEditor_OnCameraChanged`,data=>{console.log(`LiverEditorToolChanged`,data),cameraView.value=data});let dismissLayerActions=async()=>{await Lua_default.extensions.ui_liveryEditor_selection.clearSelection()},toggleEditModeLayout=async enable=>{enable=typeof enable==`boolean`?enable:currentContext.value===EDITOR_CONTEXT.default,enable?(currentContext.value=EDITOR_CONTEXT.editMode,editorView.value=EDITOR_VIEWS.editMode):(currentContext.value=EDITOR_CONTEXT.default,editorView.value=EDITOR_VIEWS.default)};function toggleShowDecalSelector(){editorView.value===EDITOR_VIEWS.decalSelector?editorView.value=EDITOR_VIEWS.editMode:editorView.value=EDITOR_VIEWS.decalSelector}let requestDismissLayerActions=()=>{currentContext.value===EDITOR_CONTEXT.newLayer?currentContext.value=null:currentContext.value===EDITOR_CONTEXT.selectedLayer&&(selectedLayers.value=[])},selectSingle=async layerUid=>{await Lua_default.extensions.ui_liveryEditor_selection.setSelected(layerUid)},toggleVisibility=async layer=>await Lua_default.extensions.ui_liveryEditor_tools_settings.toggleVisibilityById(layer.id),toggleLock=async layer=>await Lua_default.extensions.ui_liveryEditor_tools_settings.toggleLockById(layer.id),changeOrder=async(layer,direction$1)=>{direction$1===-1?await Lua_default.extensions.ui_liveryEditor_tools_group.moveOrderUpById(layer.uid):direction$1===1&&await Lua_default.extensions.ui_liveryEditor_tools_group.moveOrderDownById(layer.uid)},startEditor=async()=>{if(await Lua_default.extensions.ui_liveryEditor_editor.startEditor(),await Lua_default.extensions.ui_liveryEditor_editor.startSession(),currentContext.value=EDITOR_CONTEXT.default,editorView.value=EDITOR_VIEWS.default,await CAMERA_LUA.setOrthographicView(`right`),categories.value=await Lua_default.extensions.ui_liveryEditor_resources.getTextureCategories(),categories.value&&categories.value.length>0){let firstCategory=categories.value[0];setTexturesByCategory(firstCategory.value)}};async function setTexturesByCategory(category){textures.value=(await Lua_default.extensions.ui_liveryEditor_resources.getTexturesByCategory(category)).items}let createSaveFile=async filename=>{await Lua_default.extensions.ui_liveryEditor_userData.createSaveFile(filename)},useTool=async(toolName,params)=>{await Lua_default.extensions.ui_liveryEditor_tools.useTool(toolName)};async function onActionItemSelected(action){if(!action.items){let firstSelected=selectedLayers.value&&selectedLayers.value.length>0?selectedLayers.value[0]:null;if(action.value===`delete`)await openConfirmation(`Delete Layer`,`Are you sure you want to delete ${firstSelected.name}?`)&&await Lua_default.extensions.ui_liveryEditor_tools_settings.deleteLayer();else if(action.value===`rename`){let res=await openRenameLayerDialog(`Rename Layer`,``,{name:firstSelected.name},model=>model.name!==null&&model.name!==void 0&&model.name!==``&&model.name!==firstSelected.name);res.value&&await Lua_default.extensions.ui_liveryEditor_tools_settings.rename(res.formData.name)}else action.value===`duplicate`?await SELECTION_LUA.duplicateSelectedLayer():action.value===`visibility`?await SETTINGS_LUA.toggleVisibility():action.value===`highlight`?await SELECTION_LUA.toggleHighlightSelectedLayer():await Lua_default.extensions.ui_liveryEditor_tools.useTool(action.value)}}let editorState=reactive({isOpenExitDialog:!1,exitDialogResult:null,saving:!1});async function openExitDialog(){let res=await openFormDialog(ExitEditorDialog_default,ref({name:currentFile.value?currentFile.value.name:void 0,applySkin:!!(currentFile.value&¤tFile.value.name)}),form=>!form||!form.name?{error:!0,message:`Invalid Save Name`}:{error:!1},`Exit Editor`,null,[{label:`Cancel`,value:-1,extras:{cancel:!0,accent:ACCENTS.secondary}},{label:`Save and Exit`,value:1,emitData:!0,disableIfInvalid:!0,extras:{icon:icons.saveAs1}},{label:`Exit`,value:0,emitData:!0,extras:{accent:ACCENTS.attention,icon:icons.exit}}]);return res.value===-1?!1:(res.value===1&&await EDITOR_LUA.save(res.formData.name),res.formData.applySkin&&await EDITOR_LUA.applySkin(),await exit(),!0)}async function save(forceOpenPopup=!1){if(!currentFile.value||!currentFile.value.name||forceOpenPopup){editorState.isOpenExitDialog=!0;let res=await openEditFileDialog(`Save file`,`Enter name of your new save file`,{name:currentFile.value?currentFile.value.name:createFilename()},model=>model.name!==null&&model.name!==void 0&&model.name!==``);return res.value&&(editorState.saving=!0,await Lua_default.extensions.ui_liveryEditor_editor.save(res.formData.name),editorState.saving=!1),editorState.isOpenExitDialog=!1,res.value}else await Lua_default.extensions.ui_liveryEditor_editor.save(currentFile.value.name)}async function exit(){router_default.replace({name:`garagemode`}),await Lua_default.extensions.ui_liveryEditor_editor.exitEditor()}function createFilename(){let currentDate=new Date;return`${currentDate.getFullYear()}-${String(currentDate.getMonth()+1).padStart(2,`0`)}-${String(currentDate.getDate()).padStart(2,`0`)}_${String(currentDate.getHours()).padStart(2,`0`)}-${String(currentDate.getMinutes()).padStart(2,`0`)}-${String(currentDate.getSeconds()).padStart(2,`0`)}`}return{...SELECTION_LUA,...CAMERA_LUA,...SETTINGS_LUA,layers:layers$1,visibleLayersCount,layerActions,selectedTool,currentFile,currentContext,textures,categories,editorView,showLayersManager,showLayerActions,cameraView,editorState,dismissLayerActions,setTexturesByCategory,toggleEditModeLayout,toggleShowDecalSelector,requestDismissLayerActions,onActionItemSelected,selectMode,selectedLayers,selectedLayerUids,createSaveFile,toggleVisibility,toggleLock,startEditor,save,useTool,selectSingle,changeOrder,openExitDialog}}),SORT_OPTIONS=Object.freeze({name:`name`,modified:`modified`}),useLiveryFileStore=defineStore(`liveryFile`,()=>{let{events:events$3}=useBridge(),dataFiles=ref(null),sortKey=ref(SORT_OPTIONS.modified),sortDesc=ref(!0),files=computed(()=>{if(!dataFiles.value)return[];let sortOrder=sortDesc.value?-1:1;return dataFiles.value.sort((a$1,b)=>a$1[sortKey.value]b[sortKey.value]?1*sortOrder:0)}),init$3=async()=>{await Lua_default.extensions.ui_liveryEditor_userData.requestUpdatedData()},loadFile=async file$1=>await Lua_default.extensions.ui_liveryEditor_editor.loadFile(file$1.location),renameFile=async(file$1,newFilename)=>{await Lua_default.extensions.ui_liveryEditor_userData.renameFile(file$1.name,newFilename)},deleteFile=async file$1=>{await Lua_default.extensions.ui_liveryEditor_userData.deleteSaveFile(file$1.name)};events$3.on(`LiverySaveFilesUpdated`,data=>{data&&Array.isArray(data)&&data.length>0?(data.forEach(x=>{x.modifiedFormatted=formatDateTime(x.modified),x.fileSizeFormatted=formatSize(x.fileSize)}),dataFiles.value=data):dataFiles.value=[]});function formatDateTime(unixTime){let datetime=new Date(unixTime*1e3);return`${datetime.toLocaleDateString()} ${datetime.toLocaleTimeString()}`}function formatSize(bytes){return`${(bytes/1024).toFixed(2)} KB`}return{files,sortKey,sortDesc,init:init$3,loadFile,renameFile,deleteFile}});var EDITOR_RESOURCES_LUA=Lua_default.extensions.ui_liveryEditor_resources;const useDecalSelectorStore=defineStore(`liveryEditorDecalSelector`,()=>{let{events:events$3}=useBridge(),categories=ref(null),currentCategory=ref(null),isShow=ref(!1),textures=computed(()=>{if(!categories.value)return;let category=categories.value.find(x=>x.value===currentCategory.value);return category?category.items:void 0});async function init$3(){if(categories.value=await EDITOR_RESOURCES_LUA.getTextureCategories(),categories.value&&Array.isArray(categories.value)&&categories.value.length>0){let first=categories.value[0].value;await setCategory(first)}}async function setCategory(category){await fetchTextures(category),currentCategory.value=category}async function fetchTextures(category){let index=categories.value.findIndex(x=>x.value===category);if(index===-1)return;let textures$1=categories.value[index].items;if(index>=0&&(!textures$1||!textures$1.length===0)){let categoryWithTextures=await EDITOR_RESOURCES_LUA.getTexturesByCategory(category);categories.value[index].items=categoryWithTextures.items}}async function toggle(){isShow.value=!isShow.value,events$3.emit(`liveryEditor_onDecalStateChanged`,{show:isShow.value})}async function selectDecalItem(texturePath){await Lua_default.extensions.ui_liveryEditor_layerEdit.setup(),await Lua_default.extensions.ui_liveryEditor_layerEdit.editNewDecal({texturePath})}async function cancelSelection(){events$3.emit(`liveryEditor_onDecalSelectorCancelled`)}return{categories,currentCategory,textures,isShow,init:init$3,toggle,setCategory,selectDecalItem,cancelSelection}});var DEFAULT_ACCELERATION_RATE=.75,DEFAULT_ACCELERATION_NATURE=1.75,DEFAULT_ACTION_INTERVAL_MS=150,FOCUS_LD_TRIGGER_VALUE$2=-.5,FOCUS_RU_TRIGGER_VALUE$2=.5;const ACTION_PARAMS_TYPE={xyPoints:`xyPoints`,xPoint:`xPoint`},useActionHoldService=defineStore(`actionHoldService`,()=>{let data=ref({}),start=id=>{if(!data.value[id])throw Error(`Error starting hold action ${id}. Id not found.`);data.value[id].holdFn=setInterval(createHoldFn(id),data.value[id].actionInterval)},reset$1=id=>{let action=data.value[id];action&&(action.holdFn&&clearInterval(action.holdFn),data.value[id].holdFn=null,data.value[id].holdTimeMs=0)},add$2=(id,actionFn,immediateStart=!1,options={actionInterval:DEFAULT_ACTION_INTERVAL_MS,accelerationRate:DEFAULT_ACCELERATION_RATE,accelerationNature:DEFAULT_ACCELERATION_NATURE})=>{if(data.value[id])throw Error(`Error adding hold action for ${id}. Id already exists.`);data.value[id]={actionFn,...options,holdTimeMs:0,holdFn:null},immediateStart&&start(id)},remove$3=id=>{data.value[id]&&(reset$1(id),delete data.value[id])},removeAll=id=>{remove$3(id),remove$3(getFocusScalarName(id)),remove$3(getFocusScalarXName(id)),remove$3(getFocusScalarYName(id))},clear=()=>{let keys=Object.keys(data.value);for(let i=0;i{data.value[id]&&remove$3(id),add$2(id,actionFn,immediateStart,options)},onFocus=(id,actionFn,element,actionParamsType=ACTION_PARAMS_TYPE.xyPoints)=>{if(remove$3(getFocusScalarXName(id)),remove$3(getFocusScalarYName(id)),element.detail.value===0){remove$3(id);return}let eventName=element.detail.name,xDirection=0,yDirection=0;switch(eventName){case`focus_l`:xDirection=-1;break;case`focus_r`:xDirection=1;break;case`focus_d`:yDirection=-1;break;case`focus_u`:yDirection=1;break}switch(actionParamsType){case ACTION_PARAMS_TYPE.xyPoints:actionFn(xDirection,yDirection),addOrUpdate(id,multiplier=>actionFn(xDirection*multiplier,yDirection*multiplier),!0);break;case ACTION_PARAMS_TYPE.xPoint:let xValue=xDirection===0?yDirection:xDirection;xValue!==0&&(actionFn(xValue),addOrUpdate(id,multiplier=>actionFn(xValue*multiplier),!0));break}},inputNavStates=reactive({xLatestValue:0,yLatestValue:0,latestEventName:null}),onFocusScalar=(id,actionFn,element,actionParamsType=ACTION_PARAMS_TYPE.xyPoints)=>{console.log(`onFocusScalar`,{id,name:element.detail.name,value:element.detail.value}),remove$3(id);let eventName=element.detail.name,eventValue=element.detail.value;if(inputNavStates.latestEventName===eventName&&((eventName===`focus_lr`||eventName===`rotate_h_cam`)&&eventValue===inputNavStates.xLatestValue||(eventName===`focus_ud`||eventName===`rotate_v_cam`)&&eventValue===inputNavStates.yLatestValue))return;let xDirection=0,yDirection=0;if(eventName===`focus_lr`||eventName===`rotate_h_cam`){if(eventValue>FOCUS_RU_TRIGGER_VALUE$2&&eventValue>inputNavStates.xLatestValue?xDirection=1:eventValueactionFn(xDirection*multiplier,0),!0);break;case ACTION_PARAMS_TYPE.xPoint:actionFn(xDirection),addOrUpdate(getFocusScalarXName(id),multiplier=>actionFn(xDirection*multiplier),!0);break}inputNavStates.latestEventName=eventName}else remove$3(getFocusScalarXName(id));inputNavStates.xLatestValue=eventValue}else (eventName===`focus_ud`||eventName===`rotate_v_cam`)&&actionParamsType!==ACTION_PARAMS_TYPE.xPoint&&(eventValue>FOCUS_RU_TRIGGER_VALUE$2&&eventValue>inputNavStates.yLatestValue?yDirection=1:eventValueactionFn(0,yDirection*multiplier),!0),inputNavStates.latestEventName=eventName),inputNavStates.yLatestValue=eventValue)};function createHoldFn(id){let action=data.value[id];return()=>{let multiplier=1+action.accelerationRate*(action.holdTimeMs/1e3)**action.accelerationNature;action.actionFn(multiplier),data.value[id].holdTimeMs=action.holdTimeMs+action.actionInterval}}function getFocusScalarName(id){return`${id}_scalar`}function getFocusScalarXName(id){return`${getFocusScalarName(id)}_x`}function getFocusScalarYName(id){return`${getFocusScalarName(id)}_y`}return{onFocus,onFocusScalar,add:add$2,addOrUpdate,remove:remove$3,removeAll,clear,start,reset:reset$1}}),HEADER_SECTION_TYPE={start:`start`,center:`center`,end:`end`},useEditorHeaderStore=defineStore(`editorHeader`,()=>{let header=reactive({heading:null,preheading:[],type:`line`}),headerItems=ref([]),startSectionItems=computed(()=>headerItems.value.filter(x=>x.section===HEADER_SECTION_TYPE.start)),centerSectionItems=computed(()=>headerItems.value.filter(x=>x.section===HEADER_SECTION_TYPE.center)),endSectionItems=computed(()=>headerItems.value.filter(x=>x.section===HEADER_SECTION_TYPE.end)),headerHidden=ref(!1),itemsHidden=ref(!1),setHeader=(heading,headerType=`line`)=>{header.heading=heading,header.type=headerType},setPreheader=text=>{typeof text==`string`?header.preheading=[text]:header.preheading=text},addItems=(items$2,prepend=!1)=>{prepend?headerItems.value.unshift(...items$2):headerItems.value.push(...items$2)},addItem=(item,prepend=!1)=>{prepend?headerItems.value.unshift(item):headerItems.value.push(item)},addOrUpdateItem=(item,prepend=!1,prependIdOrIndex=0)=>{let existingIndex=-1;if(headerItems.value&&(existingIndex=headerItems.value.findIndex(x=>x.id===item.id)),existingIndex>-1)headerItems.value[existingIndex]={...item};else if(prepend){let preprendIdIndex=findIdOrIndex(prependIdOrIndex);headerItems.value.splice(preprendIdIndex,0,item)}else headerItems.value.push(item)},removeItem=itemOrId=>{let id=itemOrId.hasOwnProperty(`id`)?itemOrId.id:itemOrId,index=headerItems.value.findIndex(x=>x.id===id);index>-1&&headerItems.value.splice(index,1)},removeItems=itemsOrIds=>itemsOrIds.forEach(x=>removeItem(x)),removeItemsExcept=itemsOrIds=>{let ids=itemsOrIds.map(x=>x.hasOwnProperty(`id`)?x.id:x);removeItems(items.value.filter(x=>!ids.includes(x.id)))},showItem=itemOrId=>{let index=findIdOrIndex(itemOrId);index>-1&&(headerItems.value[index].hidden=!1)},hideItem=itemOrId=>{let index=findIdOrIndex(itemOrId);index>-1&&(headerItems.value[index].hidden=!0)},clearItems=()=>headerItems.value=[],getItem=id=>items.value.find(x=>x.id===id);function findIdOrIndex(idOrIndex){let prependIdIndex=headerItems.value.findIndex(x=>x.id===idOrIndex);return prependIdIndex===-1&&typeof idOrIndex==`number`&&idOrIndex>-1&&idOrIndex{let Controls=controls_default(),{events:events$3}=useBridge(),isSetupDone=ref(!1),{isControllerAvailable}=storeToRefs(Controls),currentSave=ref(initCurrentSave()),isLayerEditInitialized=ref(!1);watch(isControllerAvailable,async available=>{available&&await Lua_default.extensions.ui_liveryEditor.useMousePosition(!1)},{immediate:!0});async function onSetupDone(){isControllerAvailable.value&&await Lua_default.extensions.ui_liveryEditor.useMousePosition(!1)}function load(file$1){currentSave.value=file$1,isSetupDone.value=!1}function onChangeView(view){console.log(`onChangeView`,view),router_default.push({name:view})}async function setup$3(){isSetupDone.value||=(events$3.on(`liveryEditor_SetupSuccess`,onSetupDone),events$3.on(`liveryEditor_changeView`,onChangeView),await Lua_default.extensions.ui_liveryEditor.setup(currentSave.value.location),!0)}async function save(){await Lua_default.extensions.ui_liveryEditor.save(currentSave.value.name)}async function exit(){isSetupDone.value=!1,resetSave(),await Lua_default.extensions.ui_liveryEditor.deactivate()}async function setupLayerEdit(){isLayerEditInitialized.value||=(await Lua_default.extensions.ui_liveryEditor_camera.setOrthographicView(`right`),!0)}async function exitLayerEdit(){isLayerEditInitialized.value=!1}function resetSave(){currentSave.value=initCurrentSave()}function initCurrentSave(){return{name:createFilename(),location:null}}function dispose$2(){events$3.off(`liveryEditor_SetupSuccess`,onSetupDone)}function createFilename(){let currentDate=new Date;return`${currentDate.getFullYear()}-${String(currentDate.getMonth()+1).padStart(2,`0`)}-${String(currentDate.getDate()).padStart(2,`0`)}_${String(currentDate.getHours()).padStart(2,`0`)}-${String(currentDate.getMinutes()).padStart(2,`0`)}-${String(currentDate.getSeconds()).padStart(2,`0`)}`}return{currentSave,isSetupDone,load,setupLayerEdit,exitLayerEdit,save,exit,setup:setup$3,resetSave,dispose:dispose$2}});var _sfc_main$112=Object.assign({width:8,height:8,margin:.25},{__name:`DecalSelectorItem`,props:{externalImage:String},setup(__props){let props=__props;return(_ctx,_cache)=>(openBlock(),createBlock(unref(bngImageTile_default),normalizeProps(guardReactiveProps(props)),null,16))}}),DecalSelectorItem_default=_sfc_main$112,_hoisted_1$102={"bng-ui-scope":`liveryeditor-decal-selector`,class:`decal-selector`},_hoisted_2$86={class:`header-wrapper`},_hoisted_3$75={key:0,class:`filters-wrapper`},_sfc_main$111={__name:`DecalSelector`,setup(__props){useUINavScope(`liveryeditor-decal-selector`);let store$1=useDecalSelectorStore(),headerStore=useEditorHeaderStore(),selectedCategory=computed({get:()=>[store$1.currentCategory],async set(values){await store$1.setCategory(values[0])}}),switchCategory=direction$1=>{let index=store$1.categories.findIndex(x=>x.value===store$1.currentCategory);index!==-1&&(direction$1===-1?index>0?--index:index=store$1.categories.length-1:index{await store$1.init(),getUINavServiceInstance().useCrossfire=!0});let headerItemsHiddenValue=null;return onMounted(()=>{headerItemsHiddenValue=headerStore.itemsHidden,headerStore.itemsHidden||=!0}),onUnmounted(()=>{headerStore.itemsHidden=headerItemsHiddenValue}),(_ctx,_cache)=>withDirectives((openBlock(),createElementBlock(`div`,_hoisted_1$102,[createBaseVNode(`div`,_hoisted_2$86,[createVNode(unref(bngCardHeading_default),{class:`decal-selector-heading`,type:`ribbon`},{default:withCtx(()=>[..._cache[1]||=[createTextVNode(`Select Decal`,-1)]]),_:1}),createVNode(unref(bngButton_default),{"bng-no-nav":!0,accent:`attention`,label:`Close`,onClick:unref(store$1).cancelSelection},{default:withCtx(()=>[createVNode(unref(bngBinding_default),{action:`menu_item_back`})]),_:1},8,[`onClick`])]),unref(store$1).categories?(openBlock(),createElementBlock(`div`,_hoisted_3$75,[createBaseVNode(`div`,null,[createVNode(unref(bngIcon_default),{type:unref(icons).arrowSmallLeft},null,8,[`type`]),createVNode(unref(bngBinding_default),{action:`menu_tab_left`})]),createVNode(bngPillFilters_default,{modelValue:selectedCategory.value,"onUpdate:modelValue":_cache[0]||=$event=>selectedCategory.value=$event,"bng-no-child-nav":!0,options:unref(store$1).categories,required:``},null,8,[`modelValue`,`options`]),createBaseVNode(`div`,null,[createVNode(unref(bngBinding_default),{action:`menu_tab_right`}),createVNode(unref(bngIcon_default),{type:unref(icons).arrowSmallRight},null,8,[`type`])])])):createCommentVNode(``,!0),unref(store$1).textures&&unref(store$1).textures.length>0?(openBlock(),createBlock(unref(bngList_default),{key:1,noBackground:``},{default:withCtx(()=>[(openBlock(!0),createElementBlock(Fragment,null,renderList(unref(store$1).textures,(item,index)=>withDirectives((openBlock(),createBlock(DecalSelectorItem_default,{"bng-nav-item":``,key:item.preview,externalImage:item.preview,"data-decal-item":index,onClick:()=>unref(store$1).selectDecalItem(item.preview)},null,8,[`externalImage`,`data-decal-item`,`onClick`])),[[unref(BngOnUiNav_default),void 0,`ok`,{asMouse:!0,focusRequired:!0}]])),128))]),_:1})):createCommentVNode(``,!0)])),[[unref(BngBlur_default)],[unref(BngOnUiNav_default),()=>unref(store$1).cancelSelection(),`menu`],[unref(BngOnUiNav_default),()=>unref(store$1).cancelSelection(),`back`],[unref(BngOnUiNav_default),()=>switchCategory(-1),`tab_l`],[unref(BngOnUiNav_default),()=>switchCategory(1),`tab_r`]])}},DecalSelector_default=__plugin_vue_export_helper_default(_sfc_main$111,[[`__scopeId`,`data-v-e09a2ff1`]]),_hoisted_1$101={class:`decal-preview-tile`},_sfc_main$110={__name:`DecalPreviewTile`,props:{textureImage:{type:String,required:!0},textureColor:{type:Array,default:[255,255,255,1]},backgroundImage:String},setup(__props){useCssVars(_ctx=>({v036f09bc:alphaTextureBackground.value,v06c06c52:imgColor.value,v174dbaea:imageUrl.value}));let props=__props,alphaTextureBackground=computed(()=>`url(${props.backgroundImage?props.backgroundImage:getAssetURL(`images/alpha_texture.png`)}`),imageUrl=computed(()=>`url(${props.textureImage})`),imgColor=computed(()=>{let isDecimalFormat=props.textureColor.every(x=>x>=0&&x<=1),red=props.textureColor[0],green=props.textureColor[1],blue=props.textureColor[2],alpha=props.textureColor[3];return isDecimalFormat&&(red=Math.floor(red*255),green=Math.floor(green*255),blue=Math.floor(blue*255)),`rgba(${red}, ${green}, ${blue}, ${alpha})`});return(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$101,[..._cache[0]||=[createBaseVNode(`div`,{class:`image`},null,-1)]]))}},DecalPreviewTile_default=__plugin_vue_export_helper_default(_sfc_main$110,[[`__scopeId`,`data-v-8377c081`]]),_hoisted_1$100=[`disabled`],_sfc_main$109={__name:`EditModeLayersPreview`,props:{contextMenuName:String},setup(__props){let store$1=useLayerSettingsStore(),scroller=ref(null),tiles=ref({}),disabled=computed(()=>store$1.requestApplyActive||store$1.reapplyActive),onLayerClicked=async layer=>{store$1.activeLayerUid===layer.uid&&store$1.appliedLayers.length>1||await store$1.setActiveLayer(layer.uid)};watch(()=>store$1.activeLayerUid,layerUid=>{layerUid&&scrollTo(layerUid)});function setTileRef(layerUid,el){tiles.value[layerUid]=el}function scrollTo(layerUid){let tileEl=tiles.value[layerUid];if(!tileEl)return;let scrollerOffsetBottom=scroller.value.offsetTop+scroller.value.offsetHeight,scrollerOffsetTop=scroller.value.offsetTop+scroller.value.scrollTop,tileElOffsetBottom=tileEl.offsetTop+tileEl.offsetHeight,overflowsTop=tileEl.offsetTopscrollerOffsetBottom;!overflowsTop&&!overflowsBottom||window.requestAnimationFrame(()=>{overflowsTop?scroller.value.scrollBy({top:-(scrollerOffsetTop-tileEl.offsetTop)}):overflowsBottom&&(scroller.value.scrollTop=tileElOffsetBottom-scrollerOffsetBottom)})}return(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,{class:`layers-preview`,disabled:disabled.value},[createBaseVNode(`div`,{class:`item-navigation navigation-up`,onClick:_cache[0]||=$event=>unref(store$1).setActiveLayerDirection(-1)},[createVNode(unref(bngIcon_default),{type:unref(icons).arrowSmallUp},null,8,[`type`]),createVNode(unref(bngBinding_default),{action:`activate_previous_layer`,deviceMask:`xinput`,class:`navigation-icon`})]),createBaseVNode(`div`,{ref_key:`scroller`,ref:scroller,class:`preview-scroller`},[(openBlock(!0),createElementBlock(Fragment,null,renderList(unref(store$1).appliedLayers,layer=>(openBlock(),createElementBlock(`div`,{ref_for:!0,ref:el=>setTileRef(layer.uid,el),key:layer.uid,class:normalizeClass([{active:unref(store$1).activeLayerUid===layer.uid},`layer-item`])},[unref(store$1).activeLayerUid===layer.uid?withDirectives((openBlock(),createBlock(DecalPreviewTile_default,{key:0,class:`preview-img`,textureImage:layer.preview,textureColor:layer.color},null,8,[`textureImage`,`textureColor`])),[[unref(BngPopover_default),`context-menu`,`right`,{click:!0}]]):(openBlock(),createBlock(DecalPreviewTile_default,{key:1,class:`preview-img`,textureImage:layer.preview,textureColor:layer.color,onClick:()=>onLayerClicked(layer)},null,8,[`textureImage`,`textureColor`,`onClick`])),unref(store$1).activeLayerUid===layer.uid?(openBlock(),createBlock(unref(bngIcon_default),{key:2,class:`contextmenu-icon`,type:unref(icons).edit},null,8,[`type`])):createCommentVNode(``,!0)],2))),128))],512),createBaseVNode(`div`,{class:`item-navigation navigation-down`,onClick:_cache[1]||=$event=>unref(store$1).setActiveLayerDirection(1)},[createVNode(unref(bngBinding_default),{action:`activate_next_layer`,deviceMask:`xinput`,class:`navigation-icon`}),createVNode(unref(bngIcon_default),{type:unref(icons).arrowSmallDown},null,8,[`type`])])],8,_hoisted_1$100))}},EditModeLayersPreview_default=__plugin_vue_export_helper_default(_sfc_main$109,[[`__scopeId`,`data-v-9ede6133`]]),_hoisted_1$99={class:`material-settings`,"bng-ui-scope":`material-settings`},_hoisted_2$85={class:`subsettings-selector`},_hoisted_3$74=[`onClick`],_hoisted_4$57={class:`settings-content`},_hoisted_5$47={key:0,class:`setting-item color-setting`},_hoisted_6$34={key:1,class:`setting-item item-column`},_hoisted_7$29={class:`slider-text-container`},_hoisted_8$22={key:2,class:`setting-item item-column`},_hoisted_9$19={class:`slider-text-container`},_hoisted_10$13={key:3,class:`setting-item item-column`},_hoisted_11$11={class:`slider-text-container`},INPUT_CONTROL_STEPS$4=.01,INPUT_CONTROL_MIN$4=0,INPUT_CONTROL_MAX$4=1,CONTROLLER_SLIDER_BINDING=`focus_lr`,CONTROLLER_CHANGE_SUBSETTINGS_HINTS=[{id:`activate_previous_subsettings`,content:{type:`binding`,props:{uiEvent:`focus_u`},label:`Previous Setting`}},{id:`activate_next_subsettings`,content:{type:`binding`,props:{uiEvent:`focus_d`},label:`Next Setting`}}],subSettings=[{label:`Color`,icon:icons.colorCirclePalette,value:`color`},{label:`Saturation`,icon:icons.colorSaturation,value:`saturation`},{label:`Metalness`,icon:icons.materialMetal,value:`metallicIntensity`},{label:`Roughness`,icon:icons.materialRoughness,value:`roughnessIntensity`}],_sfc_main$108={__name:`LayerMaterialSettings`,emits:[`subSettingChanged`],setup(__props,{emit:__emit}){let emit$1=__emit,store$1=useLayerSettingsStore(),actionHoldService=useActionHoldService(),{showIfController}=storeToRefs(controls_default()),infoBar=useInfoBar(),activeSubSettingsIndex=ref(0),_color=reactive({hue:.5,saturation:1,luminosity:.5}),color=computed({get:()=>_color,set:async newValue=>{let paint=new Paint;paint.hsl=[newValue.hue,newValue.saturation,newValue.luminosity],await store$1.setColor([paint.red,paint.green,paint.blue,paint.alpha])}}),saturation=computed({get:()=>_color.saturation,set:async newValue=>{let sat=parseFloat(newValue.toFixed(2));color.value={hue:color.value.hue,saturation:sat,luminosity:color.value.luminosity},_color.saturation=sat}}),metallicIntensity=computed({get:()=>store$1.cursorData?store$1.cursorData.metallicIntensity:void 0,set:async newValue=>{await store$1.setMetallicIntensity(newValue)}}),roughnessIntensity=computed({get:()=>store$1.cursorData?store$1.cursorData.roughnessIntensity:void 0,set:async newValue=>{await store$1.setRoughnessIntensity(newValue)}}),activeSubSetting=computed(()=>subSettings[activeSubSettingsIndex.value]);watch(()=>store$1.activeLayerUid,(newValue,oldValue)=>{newValue&&oldValue&&initColorPicker(store$1.cursorData.color)},{deep:!0}),watch(activeSubSetting,(value,oldValue)=>{oldValue&&actionHoldService.remove(oldValue),setHints(),emit$1(`subSettingChanged`,value)},{immediate:!0}),onBeforeUnmount(()=>{actionHoldService.removeAll(`color`),actionHoldService.removeAll(`saturation`),actionHoldService.removeAll(`metallicIntensity`),actionHoldService.removeAll(`roughnessIntensity`),emit$1(`subSettingChanged`,void 0)}),onMounted(()=>{store$1.cursorData.color&&initColorPicker(store$1.cursorData.color)});let goPreviousSubSetting=()=>{activeSubSettingsIndex.value>0?--activeSubSettingsIndex.value:activeSubSettingsIndex.value=subSettings.length-1},goNextSubSetting=()=>{activeSubSettingsIndex.valuechangeColor(hue,luminosity,0);break;case`saturation`:actionFn=saturation$1=>changeColor(0,0,saturation$1);break;case`metallicIntensity`:actionFn=changeMetallicIntensity,actionParamsType=ACTION_PARAMS_TYPE.xPoint;break;case`roughnessIntensity`:actionFn=changeRoughnessIntensity,actionParamsType=ACTION_PARAMS_TYPE.xPoint;break}scalar?actionHoldService.onFocusScalar(subsettingValue,actionFn,element,actionParamsType):actionHoldService.onFocus(subsettingValue,actionFn,element,actionParamsType)}}async function changeColor(h$1,l,s){let newHue=color.value.hue+.01*h$1,newLuminosity=color.value.luminosity+.01*l,newSaturation=parseFloat((color.value.saturation+.1*s).toFixed(2));(newHue<0||newHue>1)&&(newHue=color.value.hue),(newLuminosity<0||newLuminosity>1)&&(newLuminosity=color.value.luminosity),(newSaturation<0||newSaturation>1)&&(newSaturation=color.value.saturation),_color.hue=newHue,_color.saturation=newSaturation,_color.luminosity=newLuminosity;let paint=new Paint;paint.hsl=[newHue,newSaturation,newLuminosity],store$1.setColor([paint.red,paint.green,paint.blue,paint.alpha])}let changeMetallicIntensity=direction$1=>{let newValue=metallicIntensity.value+.1*direction$1;newValue>=0&&newValue<=1&&(metallicIntensity.value=newValue)},changeRoughnessIntensity=direction$1=>{let newValue=roughnessIntensity.value+.1*direction$1;newValue>=0&&newValue<=1&&(roughnessIntensity.value=newValue)};function updateColorPickerModel(rgba){let paint=new Paint;paint.rgba=rgba,_color.hue=paint.hue,_color.saturation=paint.saturation,_color.luminosity=paint.luminosity}store$1.$onAction(({name,store:store$2,args,after,onError})=>{after(result=>{name===`resetCursorProperties`&&args[0].includes(`material`)&&initColorPicker(store$2.cursorData.color)})});function onReset(){let defaultColor=[1,1,1,1];switch(activeSubSetting.value.value){case`color`:store$1.setColor(defaultColor),updateColorPickerModel(defaultColor),saturation.value=1;break;case`saturation`:saturation.value=1;break;case`metallicIntensity`:metallicIntensity.value=0;break;case`roughnessIntensity`:roughnessIntensity.value=0;break}}function onTertiaryAction(){if(store$1.reapplyActive||store$1.requestApplyActive)onReset();else return!0}function initColorPicker(color$1){let isWhite=color$1.every(x=>x===1),paint=new Paint;paint.rgba=color$1,_color.hue=paint.hue,_color.saturation=isWhite?1:paint.saturation,_color.luminosity=paint.luminosity}useUINavScope(`material-settings`);let useCrossfireValue;onBeforeMount(()=>{useCrossfireValue=getUINavServiceInstance().useCrossfire,getUINavServiceInstance().useCrossfire=!1}),onBeforeUnmount(()=>{getUINavServiceInstance().useCrossfire=useCrossfireValue});let unwatchGamepad;onBeforeMount(()=>{unwatchGamepad=watch(showIfController,async()=>{await nextTick(()=>setHints())},{immediate:!0})}),onUnmounted(()=>{unwatchGamepad&&unwatchGamepad(),removeHints()});function setHints(){removeHints(),showIfController.value&&infoBar.addHints(CONTROLLER_CHANGE_SUBSETTINGS_HINTS)}function removeHints(){infoBar.removeHints(...CONTROLLER_CHANGE_SUBSETTINGS_HINTS.map(x=>x.id))}return(_ctx,_cache)=>withDirectives((openBlock(),createElementBlock(`div`,_hoisted_1$99,[createBaseVNode(`div`,_hoisted_2$85,[(openBlock(),createElementBlock(Fragment,null,renderList(subSettings,(subtab,index)=>withDirectives(createBaseVNode(`div`,{key:subtab.value,class:normalizeClass([{active:index===activeSubSettingsIndex.value},`subsettings-selector-item`]),onClick:()=>activeSubSettingsIndex.value=index},[createVNode(unref(bngIcon_default),{type:subtab.icon,class:`selector-item-icon`},null,8,[`type`])],10,_hoisted_3$74),[[unref(BngTooltip_default),index===activeSubSettingsIndex.value?void 0:subtab.label,`left`]])),64))]),createBaseVNode(`div`,_hoisted_4$57,[activeSubSetting.value.value===`color`?(openBlock(),createElementBlock(`div`,_hoisted_5$47,[createVNode(unref(bngColorPicker_default),{modelValue:color.value,"onUpdate:modelValue":_cache[0]||=$event=>color.value=$event,view:`luminosity`},null,8,[`modelValue`])])):createCommentVNode(``,!0),activeSubSetting.value.value===`saturation`?(openBlock(),createElementBlock(`div`,_hoisted_6$34,[createBaseVNode(`div`,_hoisted_7$29,[createVNode(unref(bngSlider_default),{modelValue:saturation.value,"onUpdate:modelValue":_cache[1]||=$event=>saturation.value=$event,min:INPUT_CONTROL_MIN$4,max:INPUT_CONTROL_MAX$4,step:INPUT_CONTROL_STEPS$4},null,8,[`modelValue`]),createVNode(unref(bngInput_default),{modelValue:saturation.value,"onUpdate:modelValue":_cache[2]||=$event=>saturation.value=$event,type:`number`,min:INPUT_CONTROL_MIN$4,max:INPUT_CONTROL_MAX$4,step:INPUT_CONTROL_STEPS$4},null,8,[`modelValue`]),createVNode(unref(bngBinding_default),{uiEvent:CONTROLLER_SLIDER_BINDING,deviceMask:`xinput`})])])):activeSubSetting.value.value===`metallicIntensity`?(openBlock(),createElementBlock(`div`,_hoisted_8$22,[createBaseVNode(`div`,_hoisted_9$19,[createVNode(unref(bngSlider_default),{modelValue:metallicIntensity.value,"onUpdate:modelValue":_cache[3]||=$event=>metallicIntensity.value=$event,min:INPUT_CONTROL_MIN$4,max:INPUT_CONTROL_MAX$4,step:INPUT_CONTROL_STEPS$4},null,8,[`modelValue`]),createVNode(unref(bngInput_default),{modelValue:metallicIntensity.value,"onUpdate:modelValue":_cache[4]||=$event=>metallicIntensity.value=$event,type:`number`,min:INPUT_CONTROL_MIN$4,max:INPUT_CONTROL_MAX$4,step:INPUT_CONTROL_STEPS$4},null,8,[`modelValue`]),createVNode(unref(bngBinding_default),{uiEvent:CONTROLLER_SLIDER_BINDING,deviceMask:`xinput`})])])):activeSubSetting.value.value===`roughnessIntensity`?(openBlock(),createElementBlock(`div`,_hoisted_10$13,[createBaseVNode(`div`,_hoisted_11$11,[createVNode(unref(bngSlider_default),{modelValue:roughnessIntensity.value,"onUpdate:modelValue":_cache[5]||=$event=>roughnessIntensity.value=$event,min:INPUT_CONTROL_MIN$4,max:INPUT_CONTROL_MAX$4,step:INPUT_CONTROL_STEPS$4},null,8,[`modelValue`]),createVNode(unref(bngInput_default),{modelValue:roughnessIntensity.value,"onUpdate:modelValue":_cache[6]||=$event=>roughnessIntensity.value=$event,type:`number`,min:INPUT_CONTROL_MIN$4,max:INPUT_CONTROL_MAX$4,step:INPUT_CONTROL_STEPS$4},null,8,[`modelValue`]),createVNode(unref(bngBinding_default),{uiEvent:CONTROLLER_SLIDER_BINDING,deviceMask:`xinput`})])])):createCommentVNode(``,!0)])])),[[unref(BngOnUiNav_default),goNextSubSetting,`action_2`],[unref(BngOnUiNav_default),onTertiaryAction,`action_3`],[unref(BngOnUiNav_default),onFocus,`focus_l`,{up:!0}],[unref(BngOnUiNav_default),onFocus,`focus_l`,{down:!0}],[unref(BngOnUiNav_default),onFocus,`focus_r`,{down:!0}],[unref(BngOnUiNav_default),onFocus,`focus_r`,{up:!0}],[unref(BngOnUiNav_default),onFocus,`focus_u`,{up:!0}],[unref(BngOnUiNav_default),onFocus,`focus_u`,{down:!0}],[unref(BngOnUiNav_default),onFocus,`focus_d`,{down:!0}],[unref(BngOnUiNav_default),onFocus,`focus_d`,{up:!0}],[unref(BngOnUiNav_default),el=>onFocus(el,!0),`focus_lr`],[unref(BngOnUiNav_default),el=>onFocus(el,!0),`focus_ud`]])}},LayerMaterialSettings_default=__plugin_vue_export_helper_default(_sfc_main$108,[[`__scopeId`,`data-v-ffe74e63`]]),_hoisted_1$98={class:`mirror-settings`,"bng-ui-scope":`mirror-settings`},_hoisted_2$84={class:`setting-item`},_hoisted_3$73={class:`setting-item offset-item`},_hoisted_4$56={class:`setting-item offset-item`},FOCUS_LD_TRIGGER_VALUE$1=-.999,FOCUS_RU_TRIGGER_VALUE$1=.999,FOCUS_HOLD_INTERVAL_MS=250,MIRROR_BINDING=`focus_l`,FLIP_BINDING=`focus_r`,CONTROLLER_OFFSET_BINDING=`focus_ud`,CONTROLLER_HINTS$4=[],KEYBOARD_HINTS$4=[],_sfc_main$107={__name:`LayerMirrorSettings`,setup(__props){let store$1=useLayerSettingsStore(),{showIfController}=storeToRefs(controls_default()),infoBar=useInfoBar(),inputNavStates=reactive({focusXLatestValue:0,focusYLatestValue:0,holdEventLatest:null,holdInterval:null}),mirror=computed({get:()=>store$1.cursorData?store$1.cursorData.mirrored:void 0,set:async newValue=>await store$1.setMirrored(newValue,store$1.cursorData.flipMirroredDecal)}),flip$2=computed({get:()=>store$1.cursorData?store$1.cursorData.flipMirroredDecal:void 0,set:async newValue=>await store$1.setMirrored(store$1.cursorData.mirrored,newValue)}),offset$2=computed({get:()=>store$1.cursorData?store$1.cursorData.mirrorOffset:void 0,set:async newValue=>await store$1.setMirrorOffset(newValue)}),toggleMirror=()=>mirror.value=!mirror.value,toggleFlipped=()=>{mirror.value&&(flip$2.value=!flip$2.value)},changeOffset=element=>{if(!mirror.value)return;let eventName=element.detail.name,direction$1=eventName===`focus_d`?-1:1,isPressed=element.detail.value;inputNavStates.holdEventLatest===eventName&&!isPressed&&inputNavStates.holdInterval&&(clearInterval(inputNavStates.holdInterval),inputNavStates.holdInterval=null),direction$1>0&&isPressed?doHoldAction(()=>store$1.setMirrorOffset(offset$2.value+1),eventName):direction$1<0&&isPressed&&doHoldAction(()=>store$1.setMirrorOffset(offset$2.value-1),eventName)},changeOffsetScalar=element=>{if(!mirror.value)return;let eventName=element.detail.name,direction$1=element.detail.value;inputNavStates.holdEventLatest===eventName&&inputNavStates.holdInterval&&clearInterval(inputNavStates.holdInterval),direction$1>FOCUS_RU_TRIGGER_VALUE$1&&direction$1>inputNavStates.focusXLatestValue?doHoldAction(()=>store$1.setMirrorOffset(offset$2.value+1),eventName):direction$1store$1.setMirrorOffset(offset$2.value-1),eventName),inputNavStates.focusXLatestValue=direction$1};function onReset(){store$1.setMirrored(!1,!1),store$1.setMirrorOffset(0)}function onTertiaryAction(){if(store$1.reapplyActive||store$1.requestApplyActive)onReset();else return!0}function doHoldAction(callbackFn,eventName){inputNavStates.holdInterval&&=(clearInterval(inputNavStates.holdInterval),null),callbackFn(),inputNavStates.holdInterval=setInterval(callbackFn,FOCUS_HOLD_INTERVAL_MS),inputNavStates.holdEventLatest=eventName}useUINavScope(`mirror-settings`);let useCrossfireValue;onBeforeMount(()=>{useCrossfireValue=getUINavServiceInstance().useCrossfire,getUINavServiceInstance().useCrossfire=!1}),onBeforeUnmount(()=>{getUINavServiceInstance().useCrossfire=useCrossfireValue});let unwatchGamepad;onBeforeMount(()=>{unwatchGamepad=watch(showIfController,async()=>{await nextTick(()=>setHints())},{immediate:!0})}),onUnmounted(()=>{unwatchGamepad&&unwatchGamepad(),removeHints()});function setHints(){let hints;removeHints(),hints=showIfController.value?CONTROLLER_HINTS$4:KEYBOARD_HINTS$4;for(let i=hints.length-1;i>=0;i--)infoBar.addHints(hints[i],0,!0)}function removeHints(){infoBar.removeHints(...KEYBOARD_HINTS$4.map(x=>x.id)),infoBar.removeHints(...CONTROLLER_HINTS$4.map(x=>x.id))}return(_ctx,_cache)=>withDirectives((openBlock(),createElementBlock(`div`,_hoisted_1$98,[createBaseVNode(`div`,_hoisted_2$84,[createVNode(unref(bngSwitch_default),{modelValue:mirror.value,"onUpdate:modelValue":_cache[0]||=$event=>mirror.value=$event},{default:withCtx(()=>[..._cache[3]||=[createTextVNode(`Mirror`,-1)]]),_:1},8,[`modelValue`]),createVNode(unref(bngBinding_default),{uiEvent:MIRROR_BINDING,deviceMask:`xinput`})]),createBaseVNode(`div`,_hoisted_3$73,[createVNode(unref(bngSwitch_default),{modelValue:flip$2.value,"onUpdate:modelValue":_cache[1]||=$event=>flip$2.value=$event,disabled:!mirror.value},{default:withCtx(()=>[..._cache[4]||=[createTextVNode(`Flip`,-1)]]),_:1},8,[`modelValue`,`disabled`]),createVNode(unref(bngBinding_default),{uiEvent:FLIP_BINDING,deviceMask:`xinput`,class:normalizeClass({disabled:!mirror.value})},null,8,[`class`])]),createBaseVNode(`div`,_hoisted_4$56,[createVNode(unref(bngInput_default),{modelValue:offset$2.value,"onUpdate:modelValue":_cache[2]||=$event=>offset$2.value=$event,step:.1,disabled:!mirror.value,type:`number`,prefix:`Offset`,class:`setting-input`},null,8,[`modelValue`,`disabled`]),createVNode(unref(bngBinding_default),{uiEvent:CONTROLLER_OFFSET_BINDING,deviceMask:`xinput`,class:normalizeClass({disabled:!mirror.value})},null,8,[`class`])])])),[[unref(BngOnUiNav_default),onTertiaryAction,`action_3`],[unref(BngOnUiNav_default),toggleMirror,`focus_l`],[unref(BngOnUiNav_default),toggleFlipped,`focus_r`],[unref(BngOnUiNav_default),changeOffset,`focus_u`,{up:!0}],[unref(BngOnUiNav_default),changeOffset,`focus_u`,{down:!0}],[unref(BngOnUiNav_default),changeOffset,`focus_d`,{up:!0}],[unref(BngOnUiNav_default),changeOffset,`focus_d`,{down:!0}],[unref(BngOnUiNav_default),changeOffsetScalar,`focus_ud`]])}},LayerMirrorSettings_default=__plugin_vue_export_helper_default(_sfc_main$107,[[`__scopeId`,`data-v-5ae7bab5`]]),_hoisted_1$97={"bng-ui-scope":`rotate-settings`},_hoisted_2$83={class:`setting-item item-column`},_hoisted_3$72={class:`slider-text-container`},INPUT_CONTROL_STEPS$3=.1,INPUT_CONTROL_MIN$3=0,INPUT_CONTROL_MAX$3=359.9,INPUT_DEFAULT_VALUE$3=0,CONTROLLER_ROTATE_BINDING=`focus_lr`,CONTROLLER_HINTS$3=[],KEYBOARD_HINTS$3=[],_sfc_main$106={__name:`LayerRotateSettings`,setup(__props){let store$1=useLayerSettingsStore(),actionHoldService=useActionHoldService(),{showIfController}=storeToRefs(controls_default()),infoBar=useInfoBar(),rotation=computed({get:()=>store$1.cursorData?parseFloat(store$1.cursorData.rotation.toFixed(1)):void 0,set:async newValue=>{await store$1.setRotation(newValue)}});function onReset(){rotation.value=INPUT_DEFAULT_VALUE$3}function onTertiaryAction(){if(store$1.reapplyActive||store$1.requestApplyActive)onReset();else return!0}useUINavScope(`rotate-settings`);let useCrossfireValue;onBeforeMount(()=>{useCrossfireValue=getUINavServiceInstance().useCrossfire,getUINavServiceInstance().useCrossfire=!1}),onBeforeUnmount(()=>{getUINavServiceInstance().useCrossfire=useCrossfireValue});let unwatchGamepad;onBeforeMount(()=>{unwatchGamepad=watch(showIfController,async()=>{await nextTick(()=>setHints())},{immediate:!0})}),onUnmounted(()=>{actionHoldService.removeAll(`rotate`),unwatchGamepad&&unwatchGamepad(),removeHints()});function setHints(){let hints=showIfController.value?CONTROLLER_HINTS$3:KEYBOARD_HINTS$3;removeHints();for(let i=hints.length-1;i>=0;i--)infoBar.addHints(hints[i],0,!0)}function removeHints(){infoBar.removeHints(...KEYBOARD_HINTS$3.map(x=>x.id)),infoBar.removeHints(...CONTROLLER_HINTS$3.map(x=>x.id))}return(_ctx,_cache)=>withDirectives((openBlock(),createElementBlock(`div`,_hoisted_1$97,[createBaseVNode(`div`,_hoisted_2$83,[createBaseVNode(`div`,_hoisted_3$72,[createVNode(unref(bngInput_default),{modelValue:rotation.value,"onUpdate:modelValue":_cache[0]||=$event=>rotation.value=$event,min:INPUT_CONTROL_MIN$3,max:INPUT_CONTROL_MAX$3,step:INPUT_CONTROL_STEPS$3,type:`number`,prefix:`X`,class:`slider-text-textinput`},null,8,[`modelValue`]),createVNode(unref(bngSlider_default),{modelValue:rotation.value,"onUpdate:modelValue":_cache[1]||=$event=>rotation.value=$event,min:INPUT_CONTROL_MIN$3,max:INPUT_CONTROL_MAX$3,step:INPUT_CONTROL_STEPS$3,class:`slider-text-sliderinput`},null,8,[`modelValue`]),createVNode(unref(bngBinding_default),{uiEvent:CONTROLLER_ROTATE_BINDING,deviceMask:`xinput`})])])])),[[unref(BngOnUiNav_default),onTertiaryAction,`action_3`],[unref(BngOnUiNav_default),element=>unref(actionHoldService).onFocus(`rotate`,unref(store$1).rotate,element,unref(ACTION_PARAMS_TYPE).xPoint),`focus_l`,{up:!0}],[unref(BngOnUiNav_default),element=>unref(actionHoldService).onFocus(`rotate`,unref(store$1).rotate,element,unref(ACTION_PARAMS_TYPE).xPoint),`focus_l`,{down:!0}],[unref(BngOnUiNav_default),element=>unref(actionHoldService).onFocus(`rotate`,unref(store$1).rotate,element,unref(ACTION_PARAMS_TYPE).xPoint),`focus_r`,{down:!0}],[unref(BngOnUiNav_default),element=>unref(actionHoldService).onFocus(`rotate`,unref(store$1).rotate,element,unref(ACTION_PARAMS_TYPE).xPoint),`focus_r`,{up:!0}],[unref(BngOnUiNav_default),element=>unref(actionHoldService).onFocus(`rotate`,unref(store$1).rotate,element,unref(ACTION_PARAMS_TYPE).xPoint),`focus_u`,{up:!0}],[unref(BngOnUiNav_default),element=>unref(actionHoldService).onFocus(`rotate`,unref(store$1).rotate,element,unref(ACTION_PARAMS_TYPE).xPoint),`focus_u`,{down:!0}],[unref(BngOnUiNav_default),element=>unref(actionHoldService).onFocus(`rotate`,unref(store$1).rotate,element,unref(ACTION_PARAMS_TYPE).xPoint),`focus_d`,{down:!0}],[unref(BngOnUiNav_default),element=>unref(actionHoldService).onFocus(`rotate`,unref(store$1).rotate,element,unref(ACTION_PARAMS_TYPE).xPoint),`focus_d`,{up:!0}],[unref(BngOnUiNav_default),element=>unref(actionHoldService).onFocusScalar(`rotate`,unref(store$1).rotate,element,unref(ACTION_PARAMS_TYPE).xPoint),`focus_lr`],[unref(BngOnUiNav_default),element=>unref(actionHoldService).onFocusScalar(`rotate`,unref(store$1).rotate,element,unref(ACTION_PARAMS_TYPE).xPoint),`focus_ud`]])}},LayerRotateSettings_default=__plugin_vue_export_helper_default(_sfc_main$106,[[`__scopeId`,`data-v-d8deaac6`]]),_sfc_main$105={__name:`BindingButton`,props:{uiEvent:String,deviceMask:String,action:String,label:String,showBinding:{type:Boolean,default:!0}},setup(__props){return(_ctx,_cache)=>(openBlock(),createBlock(unref(bngButton_default),{label:void 0},{default:withCtx(()=>[createBaseVNode(`span`,null,toDisplayString(__props.label),1),__props.showBinding?(openBlock(),createBlock(unref(bngBinding_default),{key:0,uiEvent:__props.uiEvent,deviceMask:__props.deviceMask,class:`button-binding`},null,8,[`uiEvent`,`deviceMask`])):createCommentVNode(``,!0)]),_:1}))}},BindingButton_default=__plugin_vue_export_helper_default(_sfc_main$105,[[`__scopeId`,`data-v-e77d3865`]]),_hoisted_1$96={class:`camera-popovermenu`},CONTROLLER_CAMERA_BINDING=`rotate_h_cam`,CAMERA_BUTTONS$2=[{label:`Right`,icon:icons.cameraSideRight,value:`right`},{label:`Front`,icon:icons.cameraFront1,value:`front`},{label:`Left`,icon:icons.cameraSideLeft,value:`left`},{label:`Back`,icon:icons.cameraBack1,value:`back`},{label:`Top Right`,icon:icons.cameraTop1,value:`topright`},{label:`Top Left`,icon:icons.cameraTop1,value:`topleft`},{label:`Top Front`,icon:icons.cameraTop1,value:`topfront`},{label:`Top Back`,icon:icons.cameraTop1,value:`topback`}],_sfc_main$104={__name:`CameraViewButton`,setup(__props){let store$1=useLiveryEditorStore(),popover=usePopover(),expand=ref(!1),currentCamera=computed(()=>{if(store$1.cameraView){let curr=CAMERA_BUTTONS$2.find(x=>x.value===store$1.cameraView);if(curr)return curr}return{icon:icons.movieCamera,label:`View`}}),onCameraViewClicked=view=>{popover.hide(`camera-popovermenu`),store$1.setOrthographicView(view)};return(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,null,[withDirectives((openBlock(),createBlock(unref(bngButton_default),{icon:currentCamera.value.icon,accent:unref(ACCENTS).secondary},{default:withCtx(()=>[createBaseVNode(`span`,null,toDisplayString(currentCamera.value.label),1),createVNode(unref(bngBinding_default),{uiEvent:CONTROLLER_CAMERA_BINDING,deviceMask:`xinput`})]),_:1},8,[`icon`,`accent`])),[[unref(BngPopover_default),`camera-popovermenu`,`bottom`,{click:!0}]]),createVNode(unref(bngPopoverContent_default),{name:`camera-popovermenu`,onShow:_cache[0]||=$event=>expand.value=!0,onHide:_cache[1]||=$event=>expand.value=!1},{default:withCtx(()=>[createBaseVNode(`div`,_hoisted_1$96,[(openBlock(),createElementBlock(Fragment,null,renderList(CAMERA_BUTTONS$2,cameraItem=>createVNode(unref(bngImageTile_default),{key:cameraItem.value,label:cameraItem.label,icon:cameraItem.icon,class:normalizeClass({active:cameraItem.value===currentCamera.value.value}),onClick:$event=>onCameraViewClicked(cameraItem.value)},null,8,[`label`,`icon`,`class`,`onClick`])),64))])]),_:1})]))}},CameraViewButton_default=__plugin_vue_export_helper_default(_sfc_main$104,[[`__scopeId`,`data-v-be949a44`]]),_hoisted_1$95={key:0,class:`liveryeditor-header`},_hoisted_2$82={key:0,class:`header-items`},_sfc_main$103={__name:`LiveryEditorHeader`,setup(__props){let store$1=useEditorHeaderStore(),{startSectionItems,centerSectionItems,endSectionItems}=storeToRefs(store$1),sections=ref({start:startSectionItems,center:centerSectionItems,end:endSectionItems});return(_ctx,_cache)=>unref(store$1).headerHidden?createCommentVNode(``,!0):(openBlock(),createElementBlock(`div`,_hoisted_1$95,[createVNode(unref(bngScreenHeading_default),{type:unref(store$1).header.type,preheadings:unref(store$1).header.preheading},{default:withCtx(()=>[createTextVNode(toDisplayString(unref(store$1).header.heading),1)]),_:1},8,[`type`,`preheadings`]),unref(store$1).itemsHidden?createCommentVNode(``,!0):(openBlock(),createElementBlock(`div`,_hoisted_2$82,[(openBlock(!0),createElementBlock(Fragment,null,renderList(sections.value,(items$2,section)=>(openBlock(),createElementBlock(`div`,{class:normalizeClass([[`section-${section}`],`header-section`])},[(openBlock(!0),createElementBlock(Fragment,null,renderList(items$2,item=>(openBlock(),createElementBlock(`div`,{key:item.id},[withDirectives((openBlock(),createBlock(resolveDynamicComponent(item.component),mergeProps({ref_for:!0},item.props,toHandlers(item.events)),null,16)),[[vShow,!item.hidden]])]))),128))],2))),256))]))]))}},LiveryEditorHeader_default=__plugin_vue_export_helper_default(_sfc_main$103,[[`__scopeId`,`data-v-b0fff070`]]),_hoisted_1$94={class:`transform-settings`,"bng-ui-scope":`transform-settings`},_hoisted_2$81={class:`setting-item item-column`},_hoisted_3$71={class:`slider-text-container`},_hoisted_4$55={class:`setting-item item-column`},_hoisted_5$46={class:`slider-text-container`},_hoisted_6$33={key:0,class:`setting-item`},_hoisted_7$28={class:`setting-item actions-container`},INPUT_CONTROL_STEPS$2=.001,INPUT_CONTROL_MIN$2=0,INPUT_CONTROL_MAX$2=1,INPUT_DEFAULT_VALUE$2=.5,APPLIED_CONTROLLER_HINTS=[],CONTROLLER_MOVE_Y_BINDING=`focus_ud`,CONTROLLER_MOVE_X_BINDING=`focus_lr`,CONTROLLER_SURFACE_NORMAL_BINDING=`action_2`,CONTROLLER_APPLY_BINDING=`ok`,CONTROLLER_CANCEL_REAPPLY_BINDING=`back`,CONTROLLER_HINTS$2=[],KEYBOARD_HINTS$2=[],MOUSE_HINTS=[{id:`stamp_decal`,content:{type:`binding`,props:{action:`stamp_decal`},label:`Apply`}}],_sfc_main$102={__name:`LayerTransformSettingsOld`,setup(__props){let store$1=useLayerSettingsStore(),{showIfController}=storeToRefs(controls_default()),infoBar=useInfoBar(),actionHoldService=useActionHoldService(),positionX=computed({get:()=>store$1.cursorData&&store$1.cursorData.position?store$1.cursorData.position.x:void 0,set:async newValue=>await store$1.setPosition(newValue,store$1.cursorData.position.y)}),positionY=computed({get:()=>store$1.cursorData&&store$1.cursorData.position?store$1.cursorData.position.y:void 0,set:async newValue=>await store$1.setPosition(store$1.cursorData.position.x,newValue)}),positionMaxX=computed(()=>store$1.cursorData&&store$1.cursorData.position?store$1.cursorData.position.maxX:INPUT_CONTROL_MAX$2),positionMaxY=computed(()=>store$1.cursorData&&store$1.cursorData.position?store$1.cursorData.position.maxY:INPUT_CONTROL_MAX$2),surfaceNormal=computed({get:()=>store$1.cursorData?store$1.cursorData.isProjectSurfaceNormal:void 0,set:async newValue=>await store$1.setProjectSurfaceNormal(newValue)}),mouseMode=computed(()=>store$1.cursorData?store$1.cursorData.isUseMousePos:void 0),applied=computed(()=>store$1.cursorData?store$1.cursorData.applied:void 0);computed(()=>store$1.active);let isShowControls=computed(()=>!store$1.cursorData.applied&&!mouseMode.value),toggleUseSurfaceNormal=()=>{if(console.log(`toggleUseSurfaceNormal`),!store$1.cursorData.applied)surfaceNormal.value=!surfaceNormal.value;else return console.log(`toggleUseSurfaceNormal returning true`),!0};function cancelApply(){store$1.requestApplyActive?store$1.cancelRequestApply():store$1.reapplyActive&&store$1.cancelReapply()}function onReset(){store$1.setPosition(INPUT_DEFAULT_VALUE$2,INPUT_DEFAULT_VALUE$2)}function onOk(){if(!store$1.requestApplyActive&&!store$1.reapplyActive)store$1.toggleReapply();else return!0}function onTertiaryAction(){if(store$1.reapplyActive||store$1.requestApplyActive)onReset();else return!0}useUINavScope(`transform-settings`);let useCrossfireValue;onBeforeMount(()=>{useCrossfireValue=getUINavServiceInstance().useCrossfire,getUINavServiceInstance().useCrossfire=!1}),onBeforeUnmount(()=>{getUINavServiceInstance().useCrossfire=useCrossfireValue}),watch(mouseMode,async()=>{await nextTick(()=>setHints())}),watch(applied,async()=>{await nextTick(()=>setHints())});function setHints(){let hints;removeHints(),hints=applied.value?showIfController.value?APPLIED_CONTROLLER_HINTS:KEYBOARD_HINTS$2:mouseMode.value?MOUSE_HINTS:showIfController.value?CONTROLLER_HINTS$2:KEYBOARD_HINTS$2;for(let i=hints.length-1;i>=0;i--)infoBar.addHints(hints[i],0,!0)}let unwatchGamepad;onBeforeMount(()=>{unwatchGamepad=watch(showIfController,async()=>{await nextTick(()=>{setHints()})},{immediate:!0})}),onUnmounted(()=>{actionHoldService.removeAll(`transform`),unwatchGamepad&&unwatchGamepad(),removeHints()});function removeHints(){infoBar.removeHints(...KEYBOARD_HINTS$2.map(x=>x.id)),infoBar.removeHints(...CONTROLLER_HINTS$2.map(x=>x.id)),infoBar.removeHints(...APPLIED_CONTROLLER_HINTS.map(x=>x.id)),infoBar.removeHints(...MOUSE_HINTS.map(x=>x.id))}return(_ctx,_cache)=>withDirectives((openBlock(),createElementBlock(`div`,_hoisted_1$94,[createBaseVNode(`div`,_hoisted_2$81,[withDirectives(createBaseVNode(`div`,_hoisted_3$71,[createVNode(unref(bngInput_default),{modelValue:positionX.value,"onUpdate:modelValue":_cache[0]||=$event=>positionX.value=$event,min:INPUT_CONTROL_MIN$2,max:positionMaxX.value,step:INPUT_CONTROL_STEPS$2,type:`number`,prefix:`X`,class:`slider-text-textinput`},null,8,[`modelValue`,`max`]),createVNode(unref(bngSlider_default),{modelValue:positionX.value,"onUpdate:modelValue":_cache[1]||=$event=>positionX.value=$event,min:INPUT_CONTROL_MIN$2,max:positionMaxX.value,step:INPUT_CONTROL_STEPS$2,class:`slider-text-sliderinput`},null,8,[`modelValue`,`max`]),createVNode(unref(bngBinding_default),{uiEvent:CONTROLLER_MOVE_X_BINDING,deviceMask:`xinput`})],512),[[vShow,isShowControls.value]])]),withDirectives(createBaseVNode(`div`,_hoisted_4$55,[createBaseVNode(`div`,_hoisted_5$46,[createVNode(unref(bngInput_default),{modelValue:positionY.value,"onUpdate:modelValue":_cache[2]||=$event=>positionY.value=$event,type:`number`,prefix:`Y`,min:INPUT_CONTROL_MIN$2,max:positionMaxY.value,step:INPUT_CONTROL_STEPS$2,class:`slider-text-textinput`},null,8,[`modelValue`,`max`]),createVNode(unref(bngSlider_default),{modelValue:positionY.value,"onUpdate:modelValue":_cache[3]||=$event=>positionY.value=$event,min:INPUT_CONTROL_MIN$2,max:positionMaxY.value,step:INPUT_CONTROL_STEPS$2,class:`slider-text-sliderinput`},null,8,[`modelValue`,`max`]),createVNode(unref(bngBinding_default),{uiEvent:CONTROLLER_MOVE_Y_BINDING,deviceMask:`xinput`})])],512),[[vShow,isShowControls.value]]),unref(store$1).cursorData.applied?createCommentVNode(``,!0):(openBlock(),createElementBlock(`div`,_hoisted_6$33,[createVNode(unref(bngSwitch_default),{modelValue:surfaceNormal.value,"onUpdate:modelValue":_cache[4]||=$event=>surfaceNormal.value=$event,disabled:!(unref(store$1).reapplyActive||!applied.value)},{default:withCtx(()=>[..._cache[5]||=[createTextVNode(`Use Surface Normal`,-1)]]),_:1},8,[`modelValue`,`disabled`]),createVNode(unref(bngBinding_default),{uiEvent:CONTROLLER_SURFACE_NORMAL_BINDING,deviceMask:`xinput`})])),createBaseVNode(`div`,_hoisted_7$28,[unref(store$1).requestApplyActive||unref(store$1).reapplyActive?(openBlock(),createElementBlock(Fragment,{key:0},[unref(store$1).appliedLayers&&unref(store$1).appliedLayers.length>0?(openBlock(),createBlock(unref(BindingButton_default),{key:0,icon:unref(store$1).reapplyActive?unref(icons).undo:``,uiEvent:CONTROLLER_CANCEL_REAPPLY_BINDING,label:unref(store$1).reapplyActive?`Undo`:`Cancel`,accent:`attention`,onClick:cancelApply},null,8,[`icon`,`label`])):createCommentVNode(``,!0),mouseMode.value?createCommentVNode(``,!0):(openBlock(),createBlock(unref(BindingButton_default),{key:1,uiEvent:CONTROLLER_APPLY_BINDING,label:`Apply`,accent:`primary`,onClick:unref(store$1).apply},null,8,[`onClick`]))],64)):(openBlock(),createBlock(unref(BindingButton_default),{key:1,uiEvent:CONTROLLER_APPLY_BINDING,label:`Reapply`,onClick:unref(store$1).requestReapply},null,8,[`onClick`]))])])),[[unref(BngOnUiNav_default),onOk,`ok`],[unref(BngOnUiNav_default),toggleUseSurfaceNormal,`action_2`],[unref(BngOnUiNav_default),onTertiaryAction,`action_3`],[unref(BngOnUiNav_default),element=>unref(actionHoldService).onFocus(`transform`,unref(store$1).translate,element),`focus_l`,{up:!0}],[unref(BngOnUiNav_default),element=>unref(actionHoldService).onFocus(`transform`,unref(store$1).translate,element),`focus_l`,{down:!0}],[unref(BngOnUiNav_default),element=>unref(actionHoldService).onFocus(`transform`,unref(store$1).translate,element),`focus_r`,{down:!0}],[unref(BngOnUiNav_default),element=>unref(actionHoldService).onFocus(`transform`,unref(store$1).translate,element),`focus_r`,{up:!0}],[unref(BngOnUiNav_default),element=>unref(actionHoldService).onFocus(`transform`,unref(store$1).translate,element),`focus_u`,{up:!0}],[unref(BngOnUiNav_default),element=>unref(actionHoldService).onFocus(`transform`,unref(store$1).translate,element),`focus_u`,{down:!0}],[unref(BngOnUiNav_default),element=>unref(actionHoldService).onFocus(`transform`,unref(store$1).translate,element),`focus_d`,{down:!0}],[unref(BngOnUiNav_default),element=>unref(actionHoldService).onFocus(`transform`,unref(store$1).translate,element),`focus_d`,{up:!0}],[unref(BngOnUiNav_default),element=>unref(actionHoldService).onFocusScalar(`transform`,unref(store$1).translate,element),`focus_lr`],[unref(BngOnUiNav_default),element=>unref(actionHoldService).onFocusScalar(`transform`,unref(store$1).translate,element),`focus_ud`]])}},LayerTransformSettingsOld_default=__plugin_vue_export_helper_default(_sfc_main$102,[[`__scopeId`,`data-v-79d0fe46`]]),_hoisted_1$93={class:`scale-settings`,"bng-ui-scope":`scale-settings`},_hoisted_2$80={class:`setting-item item-column`},_hoisted_3$70={class:`slider-text-container`},_hoisted_4$54={class:`setting-item item-column`},_hoisted_5$45={class:`slider-text-container`},_hoisted_6$32={class:`setting-item`},INPUT_CONTROL_STEPS$1=.01,INPUT_CONTROL_MIN$1=0,INPUT_CONTROL_MAX$1=6,INPUT_DEFAULT_VALUE$1=.5,CONTROLLER_SCALE_Y_BINDING=`focus_ud`,CONTROLLER_SCALE_X_BINDING=`focus_lr`,CONTROLLER_LOCK_BINDING=`action_2`,CONTROLLER_HINTS$1=[],KEYBOARD_HINTS$1=[],_sfc_main$101={__name:`LayerScaleSettings`,setup(__props){let store$1=useLayerSettingsStore(),actionHoldService=useActionHoldService(),{showIfController}=storeToRefs(controls_default()),infoBar=useInfoBar(),{editModeState}=storeToRefs(store$1),scaleX=computed({get:()=>store$1.cursorData&&store$1.cursorData.scale?store$1.cursorData.scale.x:void 0,set:async newValue=>{if(newValue===store$1.cursorData.scale.x)return;let scaleY$1=store$1.cursorData.scale.y;if(editModeState.value.lockScaling){let diff=newValue-store$1.cursorData.scale.x;scaleY$1+=diff}await store$1.setScale(newValue,scaleY$1)}}),scaleY=computed({get:()=>store$1.cursorData&&store$1.cursorData.scale?store$1.cursorData.scale.y:void 0,set:async newValue=>{if(newValue===store$1.cursorData.scale.y)return;let scaleX$1=store$1.cursorData.scale.x;if(editModeState.value.lockScaling){let diff=newValue-store$1.cursorData.scale.y;scaleX$1+=diff}await store$1.setScale(scaleX$1,newValue)}}),toggleLockScaling=()=>{editModeState.value.lockScaling=!editModeState.value.lockScaling};function onReset(){store$1.setScale(INPUT_DEFAULT_VALUE$1,INPUT_DEFAULT_VALUE$1)}function onTertiaryAction(){if(store$1.reapplyActive||store$1.requestApplyActive)onReset();else return!0}function onFocus(element,scalar=!1){let actionFn=(xDirection,yDirection)=>{xDirection!==0&&(scaleX.value=xDirection*INPUT_CONTROL_STEPS$1+scaleX.value),yDirection!==0&&(scaleY.value=yDirection*INPUT_CONTROL_STEPS$1+scaleY.value)};scalar?actionHoldService.onFocusScalar(`scale`,actionFn,element):actionHoldService.onFocus(`scale`,actionFn,element)}useUINavScope(`scale-settings`);let useCrossfireValue;onBeforeMount(()=>{useCrossfireValue=getUINavServiceInstance().useCrossfire,getUINavServiceInstance().useCrossfire=!1}),onBeforeUnmount(()=>{getUINavServiceInstance().useCrossfire=useCrossfireValue});let unwatchGamepad;onBeforeMount(()=>{unwatchGamepad=watch(showIfController,async()=>{await nextTick(()=>setHints())},{immediate:!0})}),onUnmounted(()=>{actionHoldService.removeAll(`scale`),unwatchGamepad&&unwatchGamepad(),removeHints()});function setHints(){let hints=showIfController.value?CONTROLLER_HINTS$1:KEYBOARD_HINTS$1;removeHints();for(let i=hints.length-1;i>=0;i--)infoBar.addHints(hints[i],0,!0)}function removeHints(){infoBar.removeHints(...KEYBOARD_HINTS$1.map(x=>x.id)),infoBar.removeHints(...CONTROLLER_HINTS$1.map(x=>x.id))}return(_ctx,_cache)=>withDirectives((openBlock(),createElementBlock(`div`,_hoisted_1$93,[createBaseVNode(`div`,_hoisted_2$80,[createBaseVNode(`div`,_hoisted_3$70,[createVNode(unref(bngInput_default),{modelValue:scaleX.value,"onUpdate:modelValue":_cache[0]||=$event=>scaleX.value=$event,min:INPUT_CONTROL_MIN$1,max:INPUT_CONTROL_MAX$1,step:INPUT_CONTROL_STEPS$1,type:`number`,prefix:`X`,class:`slider-text-textinput`},null,8,[`modelValue`]),createVNode(unref(bngSlider_default),{modelValue:scaleX.value,"onUpdate:modelValue":_cache[1]||=$event=>scaleX.value=$event,min:INPUT_CONTROL_MIN$1,max:INPUT_CONTROL_MAX$1,step:INPUT_CONTROL_STEPS$1,class:`slider-text-sliderinput`},null,8,[`modelValue`]),createVNode(unref(bngBinding_default),{uiEvent:CONTROLLER_SCALE_X_BINDING,deviceMask:`xinput`})])]),createBaseVNode(`div`,_hoisted_4$54,[createBaseVNode(`div`,_hoisted_5$45,[createVNode(unref(bngInput_default),{modelValue:scaleY.value,"onUpdate:modelValue":_cache[2]||=$event=>scaleY.value=$event,type:`number`,prefix:`Y`,min:INPUT_CONTROL_MIN$1,max:INPUT_CONTROL_MAX$1,step:INPUT_CONTROL_STEPS$1,class:`slider-text-textinput`},null,8,[`modelValue`]),createVNode(unref(bngSlider_default),{modelValue:scaleY.value,"onUpdate:modelValue":_cache[3]||=$event=>scaleY.value=$event,min:INPUT_CONTROL_MIN$1,max:INPUT_CONTROL_MAX$1,step:INPUT_CONTROL_STEPS$1,class:`slider-text-sliderinput`},null,8,[`modelValue`]),createVNode(unref(bngBinding_default),{uiEvent:CONTROLLER_SCALE_Y_BINDING,deviceMask:`xinput`})])]),createBaseVNode(`div`,_hoisted_6$32,[createVNode(unref(bngSwitch_default),{modelValue:unref(editModeState).lockScaling,"onUpdate:modelValue":_cache[4]||=$event=>unref(editModeState).lockScaling=$event},{default:withCtx(()=>[..._cache[5]||=[createTextVNode(`Lock Scaling`,-1)]]),_:1},8,[`modelValue`]),createVNode(unref(bngBinding_default),{uiEvent:CONTROLLER_LOCK_BINDING,deviceMask:`xinput`})])])),[[unref(BngOnUiNav_default),toggleLockScaling,`action_2`],[unref(BngOnUiNav_default),onTertiaryAction,`action_3`],[unref(BngOnUiNav_default),onFocus,`focus_l`,{up:!0}],[unref(BngOnUiNav_default),onFocus,`focus_l`,{down:!0}],[unref(BngOnUiNav_default),onFocus,`focus_r`,{down:!0}],[unref(BngOnUiNav_default),onFocus,`focus_r`,{up:!0}],[unref(BngOnUiNav_default),onFocus,`focus_u`,{up:!0}],[unref(BngOnUiNav_default),onFocus,`focus_u`,{down:!0}],[unref(BngOnUiNav_default),onFocus,`focus_d`,{down:!0}],[unref(BngOnUiNav_default),onFocus,`focus_d`,{up:!0}],[unref(BngOnUiNav_default),el=>onFocus(el,!0),`focus_lr`],[unref(BngOnUiNav_default),el=>onFocus(el,!0),`focus_ud`]])}},LayerScaleSettings_default=__plugin_vue_export_helper_default(_sfc_main$101,[[`__scopeId`,`data-v-56a383d1`]]),_hoisted_1$92={class:`sort-settings`,"bng-ui-scope":`sort-settings`},_hoisted_2$79={class:`setting-item`},_hoisted_3$69={class:`icon-binding-wrapper`},_hoisted_4$53={class:`icon-binding-wrapper`},_hoisted_5$44={class:`icon-binding-wrapper`},_hoisted_6$31={class:`stacked-arrows`},_hoisted_7$27={class:`icon-binding-wrapper`},_hoisted_8$21={class:`stacked-arrows`},_hoisted_9$18={key:0},ORDER_TOOL=Lua_default.extensions.ui_liveryEditor_tools_group,_sfc_main$100={__name:`LayerSortSettings`,setup(__props){let store$1=useLiveryEditorStore();useUINavScope(`sort-settings`);let order=computed({get:()=>store$1.selectedLayers[0].order,set(newValue){ORDER_TOOL.setOrder(newValue)}}),orderMax=computed(()=>store$1.selectedLayers[0].siblingCount),multiSelected=computed(()=>store$1.selectedLayerUids.length>1),orderOptions=computed(()=>Array.from({length:store$1.layers.length-1},(_,i)=>({label:`${i+1}`,value:i+2})));return onMounted(()=>{getUINavServiceInstance().useCrossfire=!1}),(_ctx,_cache)=>withDirectives((openBlock(),createElementBlock(`div`,_hoisted_1$92,[createBaseVNode(`div`,_hoisted_2$79,[createVNode(unref(bngButton_default),{onClick:_cache[0]||=()=>unref(ORDER_TOOL).moveOrderUp(),disabled:order.value===orderMax.value},{default:withCtx(()=>[createBaseVNode(`div`,_hoisted_3$69,[createVNode(unref(bngIcon_default),{type:unref(icons).arrowLargeUp},null,8,[`type`]),createVNode(unref(bngBinding_default),{action:`menu_item_up`})])]),_:1},8,[`disabled`]),createVNode(unref(bngButton_default),{onClick:_cache[1]||=()=>unref(ORDER_TOOL).moveOrderDown(),disabled:order.value===2},{default:withCtx(()=>[createBaseVNode(`div`,_hoisted_4$53,[createVNode(unref(bngIcon_default),{type:unref(icons).arrowLargeDown},null,8,[`type`]),createVNode(unref(bngBinding_default),{action:`menu_item_down`})])]),_:1},8,[`disabled`]),multiSelected.value?createCommentVNode(``,!0):(openBlock(),createBlock(unref(bngButton_default),{key:0,onClick:_cache[2]||=()=>unref(ORDER_TOOL).changeOrderToTop(),disabled:order.value===orderMax.value},{default:withCtx(()=>[createBaseVNode(`div`,_hoisted_5$44,[createBaseVNode(`div`,_hoisted_6$31,[createVNode(unref(bngIcon_default),{type:unref(icons).arrowLargeUp},null,8,[`type`]),createVNode(unref(bngIcon_default),{type:unref(icons).arrowLargeUp},null,8,[`type`])]),createVNode(unref(bngBinding_default),{action:`menu_item_right`})])]),_:1},8,[`disabled`])),multiSelected.value?createCommentVNode(``,!0):(openBlock(),createBlock(unref(bngButton_default),{key:1,onClick:_cache[3]||=()=>unref(ORDER_TOOL).changeOrderToBottom(),disabled:order.value===2},{default:withCtx(()=>[createBaseVNode(`div`,_hoisted_7$27,[createBaseVNode(`div`,_hoisted_8$21,[createVNode(unref(bngIcon_default),{type:unref(icons).arrowLargeDown,disabled:unref(store$1).selectedLayers.length>1},null,8,[`type`,`disabled`]),createVNode(unref(bngIcon_default),{type:unref(icons).arrowLargeDown,disabled:unref(store$1).selectedLayers.length>1},null,8,[`type`,`disabled`])]),createVNode(unref(bngBinding_default),{action:`menu_item_left`})])]),_:1},8,[`disabled`]))]),multiSelected.value?createCommentVNode(``,!0):(openBlock(),createElementBlock(`div`,_hoisted_9$18,[createVNode(unref(bngDropdown_default),{modelValue:order.value,"onUpdate:modelValue":_cache[4]||=$event=>order.value=$event,items:orderOptions.value},null,8,[`modelValue`,`items`])]))])),[[unref(BngOnUiNav_default),()=>unref(ORDER_TOOL).changeOrderToBottom(),`focus_l`],[unref(BngOnUiNav_default),()=>unref(ORDER_TOOL).changeOrderToTop(),`focus_r`],[unref(BngOnUiNav_default),()=>unref(ORDER_TOOL).moveOrderUp(),`focus_u`],[unref(BngOnUiNav_default),()=>unref(ORDER_TOOL).moveOrderDown(),`focus_d`]])}},LayerSortSettings_default=__plugin_vue_export_helper_default(_sfc_main$100,[[`__scopeId`,`data-v-1d4969be`]]),_hoisted_1$91={class:`skew-settings`,"bng-ui-scope":`skew-settings`},_hoisted_2$78={class:`setting-item item-column`},_hoisted_3$68={class:`slider-text-container`},_hoisted_4$52={class:`setting-item item-column`},_hoisted_5$43={class:`slider-text-container`},INPUT_CONTROL_STEPS=.01,INPUT_CONTROL_MIN=-2,INPUT_CONTROL_MAX=2,INPUT_DEFAULT_VALUE=0,CONTROLLER_SKEW_Y_BINDING=`focus_ud`,CONTROLLER_SKEW_X_BINDING=`focus_lr`,CONTROLLER_HINTS=[],KEYBOARD_HINTS=[],_sfc_main$99={__name:`LayerDeformSettings`,setup(__props){let store$1=useLayerSettingsStore(),actionHoldService=useActionHoldService(),{showIfController}=storeToRefs(controls_default()),infoBar=useInfoBar(),skewX=computed({get:()=>store$1.cursorData&&store$1.cursorData.skew?store$1.cursorData.skew.x:void 0,set:async newValue=>await store$1.setSkew(newValue,store$1.cursorData.skew.y)}),skewY=computed({get:()=>store$1.cursorData&&store$1.cursorData.skew?store$1.cursorData.skew.y:void 0,set:async newValue=>await store$1.setSkew(store$1.cursorData.skew.x,newValue)});function onReset(){store$1.setSkew(INPUT_DEFAULT_VALUE,INPUT_DEFAULT_VALUE)}function onTertiaryAction(){if(store$1.reapplyActive||store$1.requestApplyActive)onReset();else return!0}useUINavScope(`skew-settings`);let useCrossfireValue;onBeforeMount(()=>{useCrossfireValue=getUINavServiceInstance().useCrossfire,getUINavServiceInstance().useCrossfire=!1}),onBeforeUnmount(()=>{getUINavServiceInstance().useCrossfire=useCrossfireValue});let unwatchGamepad;onBeforeMount(()=>{unwatchGamepad=watch(showIfController,async()=>{await nextTick(()=>setHints())},{immediate:!0})}),onUnmounted(()=>{actionHoldService.removeAll(`skew`),unwatchGamepad&&unwatchGamepad(),removeHints()});function setHints(){let hints=showIfController.value?CONTROLLER_HINTS:KEYBOARD_HINTS;removeHints();for(let i=hints.length-1;i>=0;i--)infoBar.addHints(hints[i],0,!0)}function removeHints(){infoBar.removeHints(...KEYBOARD_HINTS.map(x=>x.id)),infoBar.removeHints(...CONTROLLER_HINTS.map(x=>x.id))}return(_ctx,_cache)=>withDirectives((openBlock(),createElementBlock(`div`,_hoisted_1$91,[createBaseVNode(`div`,_hoisted_2$78,[createBaseVNode(`div`,_hoisted_3$68,[createVNode(unref(bngInput_default),{modelValue:skewX.value,"onUpdate:modelValue":_cache[0]||=$event=>skewX.value=$event,min:INPUT_CONTROL_MIN,max:INPUT_CONTROL_MAX,step:INPUT_CONTROL_STEPS,type:`number`,prefix:`X`,class:`slider-text-textinput`},null,8,[`modelValue`]),createVNode(unref(bngSlider_default),{modelValue:skewX.value,"onUpdate:modelValue":_cache[1]||=$event=>skewX.value=$event,min:INPUT_CONTROL_MIN,max:INPUT_CONTROL_MAX,step:INPUT_CONTROL_STEPS,class:`slider-text-sliderinput`},null,8,[`modelValue`]),createVNode(unref(bngBinding_default),{uiEvent:CONTROLLER_SKEW_X_BINDING,deviceMask:`xinput`})])]),createBaseVNode(`div`,_hoisted_4$52,[createBaseVNode(`div`,_hoisted_5$43,[createVNode(unref(bngInput_default),{modelValue:skewY.value,"onUpdate:modelValue":_cache[2]||=$event=>skewY.value=$event,type:`number`,prefix:`Y`,min:INPUT_CONTROL_MIN,max:INPUT_CONTROL_MAX,step:INPUT_CONTROL_STEPS,class:`slider-text-textinput`},null,8,[`modelValue`]),createVNode(unref(bngSlider_default),{modelValue:skewY.value,"onUpdate:modelValue":_cache[3]||=$event=>skewY.value=$event,min:INPUT_CONTROL_MIN,max:INPUT_CONTROL_MAX,step:INPUT_CONTROL_STEPS,class:`slider-text-sliderinput`},null,8,[`modelValue`]),createVNode(unref(bngBinding_default),{uiEvent:CONTROLLER_SKEW_Y_BINDING,deviceMask:`xinput`})])])])),[[unref(BngOnUiNav_default),onTertiaryAction,`action_3`],[unref(BngOnUiNav_default),element=>unref(actionHoldService).onFocus(`skew`,unref(store$1).skew,element),`focus_l`,{up:!0}],[unref(BngOnUiNav_default),element=>unref(actionHoldService).onFocus(`skew`,unref(store$1).skew,element),`focus_l`,{down:!0}],[unref(BngOnUiNav_default),element=>unref(actionHoldService).onFocus(`skew`,unref(store$1).skew,element),`focus_r`,{down:!0}],[unref(BngOnUiNav_default),element=>unref(actionHoldService).onFocus(`skew`,unref(store$1).skew,element),`focus_r`,{up:!0}],[unref(BngOnUiNav_default),element=>unref(actionHoldService).onFocus(`skew`,unref(store$1).skew,element),`focus_u`,{up:!0}],[unref(BngOnUiNav_default),element=>unref(actionHoldService).onFocus(`skew`,unref(store$1).skew,element),`focus_u`,{down:!0}],[unref(BngOnUiNav_default),element=>unref(actionHoldService).onFocus(`skew`,unref(store$1).skew,element),`focus_d`,{down:!0}],[unref(BngOnUiNav_default),element=>unref(actionHoldService).onFocus(`skew`,unref(store$1).skew,element),`focus_d`,{up:!0}],[unref(BngOnUiNav_default),element=>unref(actionHoldService).onFocusScalar(`skew`,unref(store$1).skew,element),`focus_lr`],[unref(BngOnUiNav_default),element=>unref(actionHoldService).onFocusScalar(`skew`,unref(store$1).skew,element),`focus_ud`]])}},LayerDeformSettings_default=__plugin_vue_export_helper_default(_sfc_main$99,[[`__scopeId`,`data-v-b2c32ce6`]]),_hoisted_1$90={class:`layer-settings-base`},_hoisted_2$77={class:`settings-heading`},_hoisted_3$67={class:`settings-content`},_sfc_main$98={__name:`LayerSettingsBase`,props:{heading:{type:String}},emits:[`close`],setup(__props){let slots=useSlots();return(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$90,[createBaseVNode(`div`,_hoisted_2$77,[createVNode(unref(bngCardHeading_default),{type:`ribbon`},{default:withCtx(()=>[unref(slots).heading?renderSlot(_ctx.$slots,`heading`,{key:0},()=>[createBaseVNode(`span`,null,toDisplayString(__props.heading),1)],!0):createCommentVNode(``,!0)]),_:3})]),createBaseVNode(`div`,_hoisted_3$67,[renderSlot(_ctx.$slots,`default`,{},void 0,!0)])]))}},LayerSettingsBase_default=__plugin_vue_export_helper_default(_sfc_main$98,[[`__scopeId`,`data-v-c5fed92f`]]),_hoisted_1$89={class:`setting-item item-column`},_hoisted_2$76={class:`slider-text-container`},_hoisted_3$66={class:`setting-item item-column`},_hoisted_4$51={class:`slider-text-container`},_sfc_main$97={__name:`TransformSettings`,setup(__props){let scaleX=ref(.5),scaleY=ref(.5);return(_ctx,_cache)=>(openBlock(),createBlock(unref(LayerSettingsBase_default),null,{heading:withCtx(()=>[..._cache[2]||=[createTextVNode(`Transform`,-1)]]),default:withCtx(()=>[createBaseVNode(`template`,null,[createBaseVNode(`div`,_hoisted_1$89,[createBaseVNode(`div`,_hoisted_2$76,[createVNode(unref(bngInput_default),{modelValue:scaleX.value,"onUpdate:modelValue":_cache[0]||=$event=>scaleX.value=$event,min:0,max:6,step:.01,type:`number`,prefix:`X`},null,8,[`modelValue`])])]),createBaseVNode(`div`,_hoisted_3$66,[createBaseVNode(`div`,_hoisted_4$51,[createVNode(unref(bngInput_default),{modelValue:scaleY.value,"onUpdate:modelValue":_cache[1]||=$event=>scaleY.value=$event,type:`number`,prefix:`Y`,min:0,max:6,step:.01},null,8,[`modelValue`])])])])]),_:1}))}},TransformSettings_default=_sfc_main$97,_hoisted_1$88={class:`settings-container`},_hoisted_2$75={class:`setting-types-selector`},_hoisted_3$65={class:`setting-types`},_hoisted_4$50=[`onClick`],_hoisted_5$42={class:`heading-content-wrapper`},_hoisted_6$30={class:`heading-content-text`},_hoisted_7$26={key:0},_hoisted_8$20={key:0,class:`subheading`},CONTROLLER_RESET_BINDING=`advanced`,SETTING_TYPES=[{value:`transform`,label:`Transform`,icon:icons.transform,component:markRaw(TransformSettings_default)},{value:`transformold`,label:`Position`,icon:icons.transform,component:markRaw(LayerTransformSettingsOld_default)},{value:`scale`,label:`Scale`,icon:icons.scale,component:markRaw(LayerScaleSettings_default)},{value:`skew`,label:`Skew`,icon:icons.deform,component:markRaw(LayerDeformSettings_default)},{value:`rotate`,label:`Rotate`,icon:icons.rotationL,component:markRaw(LayerRotateSettings_default)},{value:`material`,label:`Material`,icon:icons.material,component:markRaw(LayerMaterialSettings_default)},{value:`mirror`,label:`Mirror`,icon:icons.reflect,component:markRaw(LayerMirrorSettings_default)}],_sfc_main$96={__name:`LayerSettings`,props:{settingTypes:Array,activeSetting:String,excludeSettingTypes:Array},setup(__props){let store$1=useLayerSettingsStore(),props=__props,currentIndex=ref(0),settingTypes=computed(()=>{let filtered=SETTING_TYPES;return props.settingTypes&&(filtered=filtered.filter(x=>props.settingTypes.includes(x.value))),props.excludeSettingTypes&&(filtered=filtered.filter(x=>!props.excludeSettingTypes.includes(x.value))),filtered}),activeSubSetting=ref(null),activeSettingType=computed(()=>settingTypes.value[currentIndex.value]),mouseMode=computed(()=>store$1.cursorData?store$1.cursorData.isUseMousePos:void 0);watch(()=>props.activeSetting,()=>{let index=settingTypes.value.findIndex(x=>x.value===props.activeSetting);index>-1?currentIndex.value=index:console.warn(`Error finding setting ${props.activeSetting}`)},{immediate:!0}),watch(activeSettingType,value=>store$1.activeSetting=value.value,{immediate:!0}),watch(activeSettingType,(newValue,oldValue)=>{newValue.value&&oldValue.value}),onMounted(()=>{getUINavServiceInstance().useCrossfire=!1}),onUnmounted(async()=>{getUINavServiceInstance().useCrossfire=!0});let setTool=settingType=>{currentIndex.value=settingTypes.value.findIndex(x=>x.value===settingType.value)},goPreviousTab=()=>{currentIndex.value=currentIndex.value>0?currentIndex.value-1:settingTypes.value.length-1},goNextTab=()=>{currentIndex.value=currentIndex.value(openBlock(),createElementBlock(`div`,_hoisted_1$88,[withDirectives((openBlock(),createElementBlock(`div`,_hoisted_2$75,[createBaseVNode(`div`,{onClick:goPreviousTab},[createVNode(unref(bngIcon_default),{type:unref(icons).arrowSmallLeft},null,8,[`type`]),createVNode(unref(bngBinding_default),{action:`menu_tab_left`,deviceMask:`xinput`})]),createBaseVNode(`div`,_hoisted_3$65,[(openBlock(!0),createElementBlock(Fragment,null,renderList(settingTypes.value,settingType=>withDirectives((openBlock(),createElementBlock(`div`,{key:settingType.value,class:normalizeClass([{active:activeSettingType.value.value===settingType.value},`setting-type`]),onClick:$event=>setTool(settingType)},[createVNode(unref(bngIcon_default),{type:settingType.icon,class:`setting-type-icon`},null,8,[`type`])],10,_hoisted_4$50)),[[unref(BngTooltip_default),activeSettingType.value.value===settingType.value?void 0:settingType.label,`top`]])),128))]),createBaseVNode(`div`,{onClick:goNextTab},[createVNode(unref(bngBinding_default),{action:`menu_tab_right`,deviceMask:`xinput`}),createVNode(unref(bngIcon_default),{type:unref(icons).arrowSmallRight},null,8,[`type`])])])),[[unref(BngBlur_default)],[unref(BngOnUiNav_default),goPreviousTab,`tab_l`],[unref(BngOnUiNav_default),goNextTab,`tab_r`]]),withDirectives((openBlock(),createBlock(LayerSettingsBase_default,null,{heading:withCtx(()=>[createBaseVNode(`div`,_hoisted_5$42,[createBaseVNode(`span`,_hoisted_6$30,[createBaseVNode(`span`,null,[createTextVNode(toDisplayString(activeSettingType.value.label)+` `,1),activeSubSetting.value?(openBlock(),createElementBlock(`span`,_hoisted_7$26,`/`)):createCommentVNode(``,!0)]),activeSubSetting.value?(openBlock(),createElementBlock(`span`,_hoisted_8$20,toDisplayString(activeSubSetting.value.label),1)):createCommentVNode(``,!0)]),(unref(store$1).reapplyActive||unref(store$1).requestApplyActive)&&(activeSettingType.value.value!==`transform`||!mouseMode.value)?(openBlock(),createBlock(unref(BindingButton_default),{key:0,icon:unref(icons).restart,accent:`text`,label:`Reset`,uiEvent:CONTROLLER_RESET_BINDING,onClick:resetSettings},null,8,[`icon`])):createCommentVNode(``,!0)])]),default:withCtx(()=>[(openBlock(),createBlock(resolveDynamicComponent(activeSettingType.value.component),{onSubSettingChanged},null,32))]),_:1})),[[unref(BngOnUiNav_default),onAdvanced,`advanced`],[unref(BngBlur_default)]])]))}},LayerSettings_default=__plugin_vue_export_helper_default(_sfc_main$96,[[`__scopeId`,`data-v-ca9ed9d2`]]),_hoisted_1$87={key:0,"bng-ui-scope":`liveryeditor-editmode`,class:`liveryeditor-editmode-layout`},_hoisted_2$74={class:`layers-preview-container`},_hoisted_3$64={class:`layer-settings-wrapper`},SAVE_TYPES={default:1,asGroup:2},FOCUS_LD_TRIGGER_VALUE=-.999,FOCUS_RU_TRIGGER_VALUE=.999,HEADER_TEXT$1=`Edit Mode`,CONTEXT_MENU_NAME=`context-menu`,CONTROLLER_EXIT_BINDING=`back`,CONTROLLER_SAVE_BINDING=`menu`,APPLY_DEFAULT_HINTS=[{id:`apply`,content:{type:`binding`,props:{uiEvent:`ok`},label:`Apply`}},{id:`cancel`,content:{type:`binding`,props:{uiEvent:`back`},label:`Cancel`}}],APPLY_MOUSE_HINTS=[{id:`cancel`,content:{type:`binding`,props:{uiEvent:`back`},label:`Cancel`}}],FREECAM_CONTROLLER_HINTS=[{id:`toggle_freecam`,content:{type:`binding`,props:{uiEvent:`action_4`},label:`Toggle View Point`}}],VIEWPOINT_CONTROLLER_HINTS=[{id:`toggle_freecam`,content:{type:`binding`,props:{uiEvent:`action_4`},label:`Toggle Free Cam`}}],DELETE_LAYER_HINT={id:`delete`,content:{type:`binding`,props:{uiEvent:`advanced`},label:`Delete`}},_sfc_main$95={__name:`EditModeLayout`,setup(__props){useCssVars(_ctx=>({ff7f3326:alphaTextureBackground.value}));let infoBar=useInfoBar(),{showIfController}=storeToRefs(controls_default()),actionHoldService=useActionHoldService(),rootStore=useLiveryEditorStore(),store$1=useLayerSettingsStore(),popover=usePopover(),freecam=ref(!1),CONTEXT_MENU_STYLES=ref({display:`flex`,"flex-direction":`column`}),contextMenuName=ref(`context-menu`),alphaTextureBackground=computed(()=>`url(${getAssetURL(`images/alpha_texture.png`)}`);onBeforeMount(async()=>{await store$1.getInitialData(),watch(showIfController,()=>{actionHoldService.clear()})}),onMounted(()=>{store$1.init(),infoBar.clearHints()}),onUnmounted(()=>{infoBar.clearHints()});async function onAddOrChangeDecal(){await rootStore.toggleShowDecalSelector()}function onBack(){popover.isShown(CONTEXT_MENU_NAME)?popover.hide(CONTEXT_MENU_NAME):store$1.appliedLayers&&store$1.appliedLayers.length>0&&store$1.requestApplyActive?store$1.cancelRequestApply():store$1.appliedLayers&&store$1.reapplyActive?store$1.cancelReapply():confirmCancelChanges()}function onContextMenu(){store$1.reapplyActive?store$1.requestChangeDecal():store$1.requestApplyActive?rootStore.toggleShowDecalSelector():store$1.duplicateActiveLayer()}function onAdvanced(){!store$1.requestApplyActive&&!store$1.reapplyActive&&store$1.activeLayerUid&&store$1.appliedLayers.length>1&&(getUINavServiceInstance().useCrossfire=!0,openConfirmation(`Delete Decal`).then(res=>{res&&store$1.removeAppliedLayer(store$1.activeLayerUid),getUINavServiceInstance().useCrossfire=!0}))}function onOk(){(store$1.requestApplyActive||store$1.reapplyActive)&&store$1.apply()}function confirmSaveChanges(){!store$1.appliedLayers||store$1.appliedLayers.length===0||(getUINavServiceInstance().useCrossfire=!0,openConfirmation(`Save`,`Save changes and exit edit mode?`,[{label:$translate.instant(`ui.common.cancel`),value:void 0,extras:{cancel:!0,accent:ACCENTS.secondary}},{label:$translate.instant(`ui.common.save`),value:SAVE_TYPES.default,extras:{default:!0}}]).then(res=>{res?store$1.saveChanges():getUINavServiceInstance().useCrossfire=!1}))}async function confirmCancelChanges(){getUINavServiceInstance().useCrossfire=!0;let hasChanges=store$1.appliedLayers&&store$1.appliedLayers.length>0;await openConfirmation(`Exit`,hasChanges?`Exit edit mode and lose all changes?`:`Exit Edit Mode?`)?(hasChanges&&await store$1.cancelChanges(),await store$1.deactivate()):getUINavServiceInstance().useCrossfire=!1}let removeLayer=()=>{store$1.removeAppliedLayer(store$1.activeLayerUid),popover.hide(CONTEXT_MENU_NAME)};function onSecondaryAction(element){!store$1.reapplyActive&&!store$1.requestApplyActive&&store$1.requestApply()}function onTertiaryAction(element){store$1.cursorData.applied&&!store$1.reapplyActive&&store$1.toggleHighlightActive()}function onQuaternaryAction(element){freecam.value=!freecam.value}function onRotateHCam(element){if(freecam.value)return!0;let direction$1=element.detail.value;(direction$1>=FOCUS_RU_TRIGGER_VALUE||direction$1<=FOCUS_LD_TRIGGER_VALUE)&&rootStore.switchOrthographicViewByDirection(direction$1>0?-1:1,0)}function onRotateVCam(element){if(freecam.value)return!0;let direction$1=element.detail.value;(direction$1>=FOCUS_RU_TRIGGER_VALUE||direction$1<=FOCUS_LD_TRIGGER_VALUE)&&rootStore.switchOrthographicViewByDirection(0,direction$1>0?-1:1)}let APPLY_CONTROLLER_HINTS=[{id:`change_decal`,content:{type:`binding`,props:{uiEvent:`context`},label:`Change Decal`},action:store$1.requestChangeDecal}],DEFAULT_HINTS=[{id:`duplicate_decal`,content:{type:`binding`,props:{action:`duplicate_active_layer`},label:`Duplicate Decal`,action:store$1.duplicateActiveLayer}},{id:`activate_previous_decal`,content:{type:`binding`,props:{action:`activate_previous_layer`},label:`Edit Previous Decal`}},{id:`activate_next_decal`,content:{type:`binding`,props:{action:`activate_next_layer`},label:`Edit Next Decal`}},{id:`save`,content:{type:`binding`,props:{uiEvent:`menu`},label:`Save`}},{id:`exit`,content:{type:`binding`,props:{uiEvent:`back`},label:`Exit`}}],DEFAULT_CONTROLLER_HINTS=[{id:`apply_or_new`,content:{type:`binding`,props:{uiEvent:`action_2`},label:`New Decal`}},{id:`delete_decal`,content:{type:`binding`,props:{uiEvent:`advanced`},label:`Delete Decal`,action:()=>store$1.removeAppliedLayer(store$1.activeLayerUid)}},{id:`duplicate_decal`,content:{type:`binding`,props:{uiEvent:`context`},label:`Duplicate Decal`},action:()=>store$1.duplicateActiveLayer()},{id:`highlight_decal`,content:{type:`binding`,props:{uiEvent:`action_3`},label:`Toggle Highlight`},action:()=>store$1.toggleHighlightActive()}];watchEffect(()=>{let isController$2=showIfController.value,defaultControllerHints=!1,hints;removeHints(),store$1.requestApplyActive||store$1.reapplyActive?hints=store$1.cursorData.isUseMousePos?APPLY_MOUSE_HINTS:isController$2?APPLY_CONTROLLER_HINTS:APPLY_DEFAULT_HINTS:isController$2?(hints=DEFAULT_CONTROLLER_HINTS,defaultControllerHints=!0):hints=DEFAULT_HINTS;for(let i=0;i1&&infoBar.addHints(DELETE_LAYER_HINT,`change_decal`,!0),(!store$1.appliedLayers||store$1.appliedLayers.length<=1)&&infoBar.removeHints(`delete_decal`)}),watch(()=>freecam.value,async()=>{freecam.value?rootStore.cameraView=`free`:await rootStore.setOrthographicView(`right`)});function removeHints(){APPLY_MOUSE_HINTS.forEach(x=>infoBar.removeHints(x.id)),APPLY_CONTROLLER_HINTS.forEach(x=>infoBar.removeHints(x.id)),APPLY_DEFAULT_HINTS.forEach(x=>infoBar.removeHints(x.id)),DEFAULT_HINTS.forEach(x=>infoBar.removeHints(x.id)),DEFAULT_CONTROLLER_HINTS.forEach(x=>infoBar.removeHints(x.id)),FREECAM_CONTROLLER_HINTS.forEach(x=>infoBar.removeHints(x.id)),VIEWPOINT_CONTROLLER_HINTS.forEach(x=>infoBar.removeHints(x.id)),infoBar.removeHints(DELETE_LAYER_HINT.id)}let headerStore=useEditorHeaderStore(),resetDisabled=ref(!1),saveDisabled=ref(!0),useMouse=computed(()=>store$1.cursorData?store$1.cursorData.isUseMousePos:void 0),changeMouseMode=async newValue=>await store$1.setUseMousePos(newValue),HEADER_APPLY_ITEMS=[{id:`cancel_apply`,section:`end`,component:shallowRef(bngButton_default),props:{label:`Cancel Apply`,accent:ACCENTS.attention},events:{click:()=>{store$1.requestApplyActive&&store$1.cancelRequestApply()}},hidden:!0},{id:`undo_reapply`,section:`end`,component:shallowRef(bngButton_default),props:{label:`Undo Reapply`,accent:ACCENTS.attention},events:{click:()=>{store$1.reapplyActive&&store$1.cancelReapply()}},hidden:!0},{id:`use_mouse`,section:`end`,component:shallowRef(bngSwitch_default),props:{modelValue:useMouse,label:`Use Mouse`,uncheckedWithBackground:!0},events:{"update:modelValue":changeMouseMode}}],showBinding=computed(()=>!store$1.active||!store$1.appliedLayers||store$1.appliedLayers.length===0||!(store$1.reapplyActive||store$1.requestApplyActive)),HEADER_GLOBAL_ITEMS=[{id:`save_changes`,section:`start`,component:shallowRef(BindingButton_default),props:{icon:icons.saveAs1,accent:ACCENTS.main,label:`Save and Exit`,disabled:saveDisabled,uiEvent:CONTROLLER_SAVE_BINDING,deviceMask:`xinput`},events:{click:confirmSaveChanges}},{id:`exit_edit_mode`,section:`start`,component:shallowRef(BindingButton_default),props:{icon:icons.exit,accent:ACCENTS.attention,label:`Exit Edit Mode`,uiEvent:CONTROLLER_EXIT_BINDING,deviceMask:`xinput`,showBinding},events:{click:confirmCancelChanges}}];return watch(()=>store$1.active,active=>{active&&(headerStore.setHeader(HEADER_TEXT$1,`ribbon`),headerStore.setPreheader(void 0))},{immediate:!0}),watchEffect(()=>{store$1.appliedLayers&&store$1.appliedLayers.length>0&&store$1.requestApplyActive?headerStore.showItem(`cancel_apply`):headerStore.hideItem(`cancel_apply`)}),watch(()=>store$1.reapplyActive,value=>{value?headerStore.showItem(`undo_reapply`):headerStore.hideItem(`undo_reapply`)}),watchEffect(()=>{saveDisabled.value=!store$1.appliedLayers||store$1.appliedLayers.length===0,resetDisabled.value=!store$1.requestApplyActive&&!store$1.reapplyActive}),onMounted(()=>{headerStore.removeItems(HEADER_APPLY_ITEMS),headerStore.removeItem(HEADER_GLOBAL_ITEMS),store$1.active&&(headerStore.addItems(HEADER_APPLY_ITEMS,!0),headerStore.addItems(HEADER_GLOBAL_ITEMS))}),onUnmounted(()=>{headerStore.removeItems(HEADER_APPLY_ITEMS),headerStore.removeItems(HEADER_GLOBAL_ITEMS)}),(_ctx,_cache)=>unref(store$1).active?withDirectives((openBlock(),createElementBlock(`div`,_hoisted_1$87,[createBaseVNode(`div`,_hoisted_2$74,[unref(store$1).appliedLayers&&!unref(store$1).requestApplyActive?withDirectives((openBlock(),createBlock(unref(bngImageTile_default),{key:0,icon:unref(icons).decal,class:normalizeClass([{cancel:unref(store$1).requestApplyActive},`add-item`]),disabled:unref(store$1).reapplyActive?`disabled`:``,ratio:`1:1`,onClick:onAddOrChangeDecal},{default:withCtx(()=>[..._cache[0]||=[createBaseVNode(`label`,null,`Add`,-1)]]),_:1},8,[`icon`,`class`,`disabled`])),[[unref(BngBlur_default)]]):withDirectives((openBlock(),createElementBlock(`div`,{key:1,class:`layer-ghost-wrapper`,onClick:onAddOrChangeDecal},[createVNode(DecalPreviewTile_default,{textureImage:unref(store$1).cursorData.decalTexturePath,textureColor:unref(store$1).cursorData.color},null,8,[`textureImage`,`textureColor`]),createVNode(unref(bngIcon_default),{class:`hover-icon`,type:unref(icons).edit},null,8,[`type`])])),[[unref(BngBlur_default)]]),unref(store$1).appliedLayers&&unref(store$1).appliedLayers.length>0?withDirectives((openBlock(),createBlock(EditModeLayersPreview_default,{key:2,contextMenuName:contextMenuName.value},null,8,[`contextMenuName`])),[[unref(BngBlur_default)]]):createCommentVNode(``,!0)]),createBaseVNode(`div`,_hoisted_3$64,[createVNode(unref(LayerSettings_default))]),unref(store$1).appliedLayers&&unref(store$1).appliedLayers.length>0&&unref(store$1).activeLayerUid!==null&&unref(store$1).activeLayerUid!==void 0?(openBlock(),createBlock(unref(bngPopoverContent_default),{key:0,name:contextMenuName.value},{default:withCtx(()=>[createBaseVNode(`div`,{class:`layer-context-menu`,style:normalizeStyle(CONTEXT_MENU_STYLES.value)},[createVNode(unref(bngButton_default),{onClick:withModifiers(unref(store$1).requestChangeDecal,[`stop`])},{default:withCtx(()=>[..._cache[1]||=[createTextVNode(`Change Decal`,-1)]]),_:1},8,[`onClick`]),createVNode(unref(bngButton_default),{disabled:unref(store$1).appliedLayers.length<=1,accent:`attention`,onClick:withModifiers(removeLayer,[`stop`])},{default:withCtx(()=>[..._cache[2]||=[createTextVNode(`Delete`,-1)]]),_:1},8,[`disabled`])],4)]),_:1},8,[`name`])):createCommentVNode(``,!0)])),[[unref(BngOnUiNav_default),onOk,`ok`],[unref(BngOnUiNav_default),onContextMenu,`context`],[unref(BngOnUiNav_default),onAdvanced,`advanced`],[unref(BngOnUiNav_default),onBack,`back`],[unref(BngOnUiNav_default),confirmSaveChanges,`menu`],[unref(BngOnUiNav_default),onSecondaryAction,`action_2`],[unref(BngOnUiNav_default),onTertiaryAction,`action_3`],[unref(BngOnUiNav_default),onQuaternaryAction,`action_4`],[unref(BngOnUiNav_default),onRotateHCam,`rotate_h_cam`],[unref(BngOnUiNav_default),onRotateVCam,`rotate_v_cam`]]):createCommentVNode(``,!0)}},EditModeLayout_default=__plugin_vue_export_helper_default(_sfc_main$95,[[`__scopeId`,`data-v-9b377f5e`]]),_hoisted_1$86={class:`layer-content`},_hoisted_2$73={class:`layer-name`},_hoisted_3$63={key:0,class:`layer-actions`},_hoisted_4$49={class:`layer-preview`},_hoisted_5$41={key:1,class:`group-preview`},_sfc_main$94={__name:`LayerTile`,props:{layer:Object,isTargeted:Boolean,forceShowActions:Boolean,disableMoveUp:Boolean,disableMoveDown:Boolean},emits:[`lockClicked`,`hideClicked`,`moveClicked`,`enableClicked`],setup(__props){let isHovered=ref(!1),toRgba255Styles=colors=>`rgba(${colors[0]*255}, ${colors[1]*255}, ${colors[2]*255}, ${colors[3]})`;return(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,{class:`layer-tile`,onMouseover:_cache[1]||=$event=>isHovered.value=!0,onMouseleave:_cache[2]||=$event=>isHovered.value=!1},[createBaseVNode(`div`,_hoisted_1$86,[renderSlot(_ctx.$slots,`content`,{},()=>[createBaseVNode(`div`,_hoisted_2$73,toDisplayString(__props.layer.name),1),__props.forceShowActions||!__props.layer.enabled?(openBlock(),createElementBlock(`div`,_hoisted_3$63,[__props.forceShowActions?(openBlock(),createBlock(unref(bngBinding_default),{key:0,"track-ignore":!0,uiEvent:`action_2`,deviceMask:`xinput`})):createCommentVNode(``,!0),createVNode(unref(bngButton_default),{accent:`outlined`,onClick:_cache[0]||=$event=>_ctx.$emit(`enableClicked`),icon:__props.layer.enabled?unref(icons).eyeSolidOpened:unref(icons).eyeSolidClosed},null,8,[`icon`])])):createCommentVNode(``,!0)],!0)]),createBaseVNode(`div`,_hoisted_4$49,[__props.layer.type===1?(openBlock(),createElementBlock(`div`,{key:0,class:`fill-preview`,style:normalizeStyle({"--layer-color":toRgba255Styles(__props.layer.color)})},null,4)):__props.layer.type===3?(openBlock(),createElementBlock(`div`,_hoisted_5$41,[createVNode(unref(bngIcon_default),{type:unref(icons).group},null,8,[`type`])])):__props.layer.type===0?(openBlock(),createBlock(DecalPreviewTile_default,{key:2,textureImage:__props.layer.preview,textureColor:__props.layer.color},null,8,[`textureImage`,`textureColor`])):createCommentVNode(``,!0)])],32))}},LayerTile_default=__plugin_vue_export_helper_default(_sfc_main$94,[[`__scopeId`,`data-v-87650a01`]]),_hoisted_1$85={class:`layers-manager`},_hoisted_2$72={class:`layers-manager-header`},_hoisted_3$62=[`onFocusin`];const VIEW_MODES={DEFAULT:`default`,COMPACT:`compact`};var _sfc_main$93={__name:`LayersManager`,props:mergeModels({layers:{type:Array,required:!0},view:{type:String,default:`default`,validator(value){return Object.values(VIEW_MODES).find(x=>x===value)}}},{selectedKeys:{},selectedKeysModifiers:{}}),emits:mergeModels([`focusedLayer`],[`update:selectedKeys`]),setup(__props,{emit:__emit}){let emit$1=__emit,rootStore=useLiveryEditorStore(),expandedKeys=ref([]),selectedKeys=useModel(__props,`selectedKeys`),focusLayer=ref(null),layersScrollable=ref(null);ref(!1);let isFocusFirstLayer=ref(!1);watch(()=>rootStore.selectedLayers,()=>{(!rootStore.selectedLayers||rootStore.selectedLayers.length===0)&&(rootStore.selectMode=`single`)}),watch(()=>selectedKeys.value,(newValue,oldValue)=>{(!newValue||newValue.length===0&&oldValue&&oldValue.length>0)&&(isFocusFirstLayer.value=!0)});let setMultiSelect=async node=>{rootStore.selectMode!==`multi`&&(rootStore.selectMode=`multi`,rootStore.toggleSelection(node.id,!1))},toggleEnabled=layer=>{Lua_default.extensions.ui_liveryEditor_layerAction.performAction(`enabled`).then(luaRes=>{layer.enabled=luaRes})},onClickItem=node=>{Lua_default.extensions.ui_liveryEditor_selection.select(node.id,!0),setFocusLayer(null)},setFocusLayer=layer=>{isFocusFirstLayer.value&&=!1,focusLayer.value=layer,emit$1(`focusedLayer`,layer)},handleFocusOut=event=>{setFocusLayer(null)};return(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$85,[createBaseVNode(`div`,_hoisted_2$72,[renderSlot(_ctx.$slots,`header`,{},void 0,!0)]),__props.layers?(openBlock(),createElementBlock(`div`,{key:0,ref_key:`layersScrollable`,ref:layersScrollable,class:`layers-scrollable`,onFocusout:handleFocusOut},[createVNode(unref(tree_default),{expandedKeys:expandedKeys.value,"onUpdate:expandedKeys":_cache[2]||=$event=>expandedKeys.value=$event,selectedKeys:selectedKeys.value,"onUpdate:selectedKeys":_cache[3]||=$event=>selectedKeys.value=$event,nodes:__props.layers,selectMode:unref(rootStore).selectMode,keyName:`id`,class:`layers-tree`},{node:withCtx(({node,parentNode,expanded,selected,expand})=>[node.hidden?createCommentVNode(``,!0):withDirectives((openBlock(),createElementBlock(`div`,{key:0,onFocusin:withModifiers($event=>setFocusLayer(node),[`self`]),"bng-nav-item":``,class:`layer-node`},[createVNode(LayerTile_default,{layer:node,forceShowActions:focusLayer.value&&focusLayer.value.uid===node.uid,onEnableClicked:()=>toggleEnabled(node)},null,8,[`layer`,`forceShowActions`,`onEnableClicked`]),node.children?(openBlock(),createBlock(unref(bngIcon_default),{key:0,type:expanded?unref(icons).arrowSmallUp:unref(icons).arrowSmallDown,class:`expand-icon`,onMousedown:_cache[0]||=withModifiers(()=>{},[`stop`]),onMouseup:_cache[1]||=withModifiers(()=>{},[`stop`]),onClick:withModifiers(expand,[`stop`])},null,8,[`type`,`onClick`])):createCommentVNode(``,!0)],40,_hoisted_3$62)),[[unref(BngClick_default),{clickCallback:()=>onClickItem(node),holdCallback:()=>setMultiSelect(node),repeatInterval:0}],[unref(BngUiNavFocus_default),isFocusFirstLayer.value&&__props.layers[0].uid===node.uid?0:void 0],[unref(BngFocusIf_default),isFocusFirstLayer.value&&__props.layers[0].uid===node.uid],[unref(BngOnUiNav_default),void 0,`ok`,{asMouse:!0,focusRequired:!0}]])]),_:1},8,[`expandedKeys`,`selectedKeys`,`nodes`,`selectMode`])],544)):createCommentVNode(``,!0)]))}},LayersManager_default=__plugin_vue_export_helper_default(_sfc_main$93,[[`__scopeId`,`data-v-1bc4f03d`]]),_hoisted_1$84={class:`paint-settings`},_sfc_main$92={__name:`PaintSettings`,setup(__props){let LUA_FILL_LAYER=Lua_default.extensions.ui_liveryEditor_layers_fill,paint=new Paint,color=ref({hue:.5,saturation:1,luminosity:.5});function setColor(){paint.hsl=[color.value.hue,color.value.saturation,color.value.luminosity],LUA_FILL_LAYER.updateLayer({color:paint.rgba})}return(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$84,[createVNode(unref(bngColorPicker_default),{modelValue:color.value,"onUpdate:modelValue":_cache[0]||=$event=>color.value=$event,view:`luminosity`},null,8,[`modelValue`]),createBaseVNode(`div`,null,[createVNode(unref(bngButton_default),{onClick:setColor},{default:withCtx(()=>[..._cache[1]||=[createTextVNode(`Save`,-1)]]),_:1})])]))}},PaintSettings_default=__plugin_vue_export_helper_default(_sfc_main$92,[[`__scopeId`,`data-v-66a34a99`]]),_hoisted_1$83={class:`liveryeditor-default-layout`,"bng-ui-scope":`default-layout`},_hoisted_2$71={class:`layers-manager-wrapper`},_hoisted_3$61={key:0,class:`multiselect-header`},_hoisted_4$48={class:`message`},_hoisted_5$40={class:`add-content-wrapper`},_hoisted_6$29={class:`action-tile`},_hoisted_7$25={key:1,class:`layer-settings-wrapper`,"bng-ui-scope":`layer-settings`},SETTINGS_VIEWS={edit:{label:`Edit`,value:`edit`,hideActions:!0,propertySettings:!0,disableLayersManager:!0,props:{excludeSettingTypes:[`transform`]}},order:{label:`Change Order`,value:`order`,component:LayerSortSettings_default,hideActions:!0,disableLayersManager:!0},paint:{label:`Paint`,value:`paint`,component:PaintSettings_default,hideActions:!0,disableLayersManager:!0}},HEADER_TEXT=`Livery Editor`,_sfc_main$91={__name:`DefaultLayout`,setup(__props){useUINavScope(`default-layout`);let rootStore=useLiveryEditorStore(),infoBar=useInfoBar(),{layers:layers$1}=storeToRefs(rootStore),actionsDrawer=ref(null),settingType=shallowRef(null),layerActions=computed(()=>rootStore.layerActions?{label:rootStore.selectedLayers.length===1?`${rootStore.selectedLayers[0].name} Actions`:`${rootStore.selectedLayers.length} Layers Actions`,items:rootStore.layerActions,allowOpenDrawer:!1}:void 0),headerLabel=computed(()=>rootStore.visibleLayersCount===0?`No Layers`:rootStore.visibleLayersCount+` Layer`+rootStore.visibleLayersCount>1?`s`:``),multiSelectMessage=computed(()=>{if(rootStore.selectedLayers)return rootStore.selectedLayers.length+`Layer${rootStore.selectedLayers.length>1?`s`:``}`});onMounted(()=>{getUINavServiceInstance().useCrossfire=!0});function onBack(){settingType.value?(console.log(`onBack > closed settings`),closeSettings()):rootStore.selectedLayers&&rootStore.selectedLayers.length>0?(console.log(`onBack > closed actions`),rootStore.dismissLayerActions().then()):(console.log(`onBack > catch all`),openExitDialog().then())}function onMenu(){settingType.value?closeActions():rootStore.selectedLayers&&rootStore.selectedLayers.length>0||openSaveDialog()}function closeActions(){settingType.value&&closeSettings(),rootStore.dismissLayerActions().then()}function closeSettings(){settingType.value=null}function onActionTriggered(actionItem){let setting=SETTINGS_VIEWS[actionItem.value];setting?settingType.value=setting:rootStore.onActionItemSelected(actionItem).then()}let saving=ref(!1),dialogStates=reactive({isDialogOpen:!1});async function openExitDialog(){if(dialogStates.isDialogOpen)return!0;dialogStates.isDialogOpen=!0,await rootStore.openExitDialog(),dialogStates.isDialogOpen=!1}function openSaveDialog(){if(dialogStates.isDialogOpen)return!0;saving.value=!0,dialogStates.isDialogOpen=!0,rootStore.save().then(()=>{saving.value=!1,dialogStates.isDialogOpen=!1})}function openPaintSettings(){settingType.value=SETTINGS_VIEWS.paint}let saveLabel=computed(()=>saving.value?`Saving...`:`Save`),HEADER_ITEMS=[{id:`save_editor`,section:`start`,component:shallowRef(bngButton_default),props:{icon:icons.saveAs1,accent:ACCENTS.main,label:saveLabel,disabled:saving},events:{click:openSaveDialog}},{id:`exit_editor`,section:`start`,component:shallowRef(bngButton_default),props:{icon:icons.exit,accent:ACCENTS.attention,label:`Exit`},events:{click:openExitDialog}},{id:`paint_settings`,section:`start`,component:shallowRef(bngButton_default),props:{icon:icons.exit,accent:ACCENTS.secondary,label:`Paint`},events:{click:openPaintSettings}}],headerStore=useEditorHeaderStore();watchEffect(()=>{rootStore.currentFile&&rootStore.currentFile.name&&headerStore.setPreheader(rootStore.currentFile.name)}),onMounted(()=>{headerStore.setHeader(HEADER_TEXT),headerStore.addItems(HEADER_ITEMS)}),onUnmounted(()=>{headerStore.removeItems(HEADER_ITEMS)});let NAV_HINTS=[{id:`save`,content:{type:`binding`,props:{uiEvent:`menu`},label:`Save`},action:async()=>await rootStore.save(!1)},{id:`exit`,content:{type:`binding`,props:{uiEvent:`back`},label:`Exit`},action:async()=>rootStore.openExitDialog}],ACTIONS_DRAWER_HINTS=[{id:`actions_back`,content:{type:`binding`,props:{uiEvent:`back`},label:`Back`}}],SETTINGS_NAV_HINTS=[{id:`selected_done`,content:{type:`binding`,props:{uiEvent:`menu`},label:`Done`}},{id:`selected_back`,content:{type:`binding`,props:{uiEvent:`back`},label:`Done (Return to Actions)`}}];return watchEffect(()=>{infoBar.clearHints(),settingType.value?infoBar.addHints(SETTINGS_NAV_HINTS):layerActions.value?infoBar.addHints(ACTIONS_DRAWER_HINTS):infoBar.addHints(NAV_HINTS)}),onMounted(()=>{infoBar.addHints(NAV_HINTS)}),onUnmounted(()=>{infoBar.removeHints(...NAV_HINTS.map(x=>x.id))}),(_ctx,_cache)=>withDirectives((openBlock(),createElementBlock(`div`,_hoisted_1$83,[createBaseVNode(`div`,_hoisted_2$71,[withDirectives((openBlock(),createBlock(unref(LayersManager_default),{selectedKeys:unref(rootStore).selectedLayerUids,"onUpdate:selectedKeys":_cache[0]||=$event=>unref(rootStore).selectedLayerUids=$event,layers:unref(layers$1),class:normalizeClass({inactive:settingType.value&&settingType.value.disableLayersManager})},{header:withCtx(()=>[createVNode(unref(bngCardHeading_default),{type:`ribbon`},{default:withCtx(()=>[createTextVNode(toDisplayString(headerLabel.value),1)]),_:1}),unref(rootStore).selectMode===`multi`?(openBlock(),createElementBlock(`div`,_hoisted_3$61,[withDirectives((openBlock(),createBlock(unref(bngButton_default),{accent:unref(ACCENTS).attention,onClick:closeActions,class:`cancel-btn`},{default:withCtx(()=>[..._cache[1]||=[createTextVNode(`Cancel`,-1)]]),_:1},8,[`accent`])),[[unref(BngOnUiNav_default),void 0,`ok`,{asMouse:!0,focusRequired:!0}]]),createBaseVNode(`span`,_hoisted_4$48,toDisplayString(multiSelectMessage.value),1)])):withDirectives((openBlock(),createBlock(unref(bngButton_default),{key:1,accent:unref(ACCENTS).outlined,disabled:unref(rootStore).selectedLayers&&unref(rootStore).selectedLayers.length>0,onClick:unref(rootStore).toggleEditModeLayout},{default:withCtx(()=>[createBaseVNode(`span`,_hoisted_5$40,[createVNode(unref(bngIcon_default),{type:unref(icons).plus},null,8,[`type`]),_cache[2]||=createBaseVNode(`span`,{class:`add-label`},`Add Decal`,-1)])]),_:1},8,[`accent`,`disabled`,`onClick`])),[[unref(BngOnUiNav_default),void 0,`ok`,{asMouse:!0,focusRequired:!0}]])]),_:1},8,[`selectedKeys`,`layers`,`class`])),[[unref(BngBlur_default)]])]),layerActions.value&&(!settingType.value||!settingType.value.hideActions)?(openBlock(),createBlock(unref(bngActionDrawer_default),{key:0,ref_key:`actionsDrawer`,ref:actionsDrawer,actions:layerActions.value,"item-width":10,"item-margin":1,class:`actions-drawer`,onSelect:onActionTriggered},{controls:withCtx(()=>[withDirectives(createVNode(unref(bngButton_default),{accent:unref(ACCENTS).outlined,icon:unref(icons).abandon,onClick:closeActions},null,8,[`accent`,`icon`]),[[unref(BngOnUiNav_default),void 0,`ok`,{asMouse:!0,focusRequired:!0}]])]),action:withCtx(({item,isLoading,select})=>[createBaseVNode(`div`,_hoisted_6$29,[withDirectives(createVNode(unref(bngImageTile_default),{label:item.toggleAction&&!item.active?item.inactiveLabel:item.label,icon:item.toggleAction&&!item.active?item.inactiveIcon:item.icon,externalImage:item.preview,"bng-nav-item":``,class:`action-tile`,onClick:$event=>select(item)},null,8,[`label`,`icon`,`externalImage`,`onClick`]),[[unref(BngOnUiNav_default),void 0,`ok`,{asMouse:!0,focusRequired:!0}]])])]),_:1},8,[`actions`])):createCommentVNode(``,!0),settingType.value?(openBlock(),createElementBlock(`div`,_hoisted_7$25,[settingType.value.propertySettings?(openBlock(),createBlock(unref(LayerSettings_default),normalizeProps(mergeProps({key:0},settingType.value.props)),null,16)):withDirectives((openBlock(),createBlock(unref(LayerSettingsBase_default),{key:1,heading:settingType.value.label},{default:withCtx(()=>[(openBlock(),createBlock(resolveDynamicComponent(settingType.value.component)))]),_:1},8,[`heading`])),[[unref(BngBlur_default)]])])):createCommentVNode(``,!0)])),[[unref(BngOnUiNav_default),onBack,`back`],[unref(BngOnUiNav_default),onMenu,`menu`]])}},DefaultLayout_default=__plugin_vue_export_helper_default(_sfc_main$91,[[`__scopeId`,`data-v-6dca75f9`]]),_hoisted_1$82={class:`editor`,"bng-ui-scope":`livery-editor`},_hoisted_2$70={class:`editor-header-wrapper`},EDITOR_VIEWS_COMPONENT={[EDITOR_VIEWS.decalSelector]:DecalSelector_default,[EDITOR_VIEWS.editMode]:EditModeLayout_default,[EDITOR_VIEWS.default]:DefaultLayout_default},_sfc_main$90={__name:`LiveryEditor`,setup(__props){let store$1=useLiveryEditorStore(),infobar=useInfoBar(),{showIfController}=storeToRefs(controls_default());infobar.visible=!0;let currentView=computed(()=>EDITOR_VIEWS_COMPONENT[store$1.editorView]),minimizedMode=ref(!1);watch(showIfController,value=>{store$1.setUseMousePos(!value)}),onBeforeMount(async()=>{await store$1.startEditor(),store$1.setUseMousePos(!showIfController.value)});let HEADER_ITEMS=[{id:`camera_view`,section:`end`,component:shallowRef(CameraViewButton_default)}],headerStore=useEditorHeaderStore();return onMounted(()=>{headerStore.setPreheader(store$1.currentFile?store$1.currentFile:`New Save`),headerStore.addItems(HEADER_ITEMS)}),onUnmounted(()=>{headerStore.removeItems(HEADER_ITEMS)}),(_ctx,_cache)=>withDirectives((openBlock(),createElementBlock(`div`,_hoisted_1$82,[createBaseVNode(`div`,_hoisted_2$70,[createVNode(unref(LiveryEditorHeader_default))]),createBaseVNode(`div`,{class:normalizeClass([`editor-content`,{"layers-collapse":minimizedMode.value}])},[(openBlock(),createBlock(resolveDynamicComponent(currentView.value)))],2)])),[[unref(BngOnUiNav_default),()=>{},`menu,back,ok`]])}},LiveryEditor_default=__plugin_vue_export_helper_default(_sfc_main$90,[[`__scopeId`,`data-v-27ec64b0`]]),_hoisted_1$81={class:`livery-main-view`,"bng-ui-scope":`livery-main-scope`},_hoisted_2$69={key:0,class:`loading-overlay`},_hoisted_3$60={class:`header`},_hoisted_4$47={class:`main-view-content`},_hoisted_5$39={class:`menu-container`},MENU_ITEMS$2=[{label:`Paint`,value:`paint`,icon:icons.colorPalette},{label:`Decals`,value:`decals`,icon:icons.decal},{label:`Settings`,value:`settings`,icon:icons.gearTuningOutline}],blockedEvents=[`tab_l`,`tab_r`],_sfc_main$89={__name:`LiveryMainNew`,setup(__props){let infobar=useInfoBar(),uiNavBlocker=useUINavBlocker(),store$1=useLiveryMainStore(),headerStore=useEditorHeaderStore();useUINavScope(`livery-main-scope`);function onMenuItemClicked(item){switch(item){case`paint`:window.bngVue.gotoGameState(`LiveryPaint`);break;case`decals`:window.bngVue.gotoGameState(`LiveryDecals`);break;case`settings`:window.bngVue.gotoGameState(`LiverySettings`);break}}let openedDialog=ref(null);onBeforeMount(async()=>{await store$1.setup(),headerStore.setHeader(`Livery Editor`),headerStore.setPreheader(null)}),onMounted(()=>{infobar.visible=!0,infobar.showSysInfo=!0,uiNavBlocker.blockOnly(blockedEvents)}),onUnmounted(()=>{uiNavBlocker.clear()});function exit(){store$1.exit().then(()=>{window.bngVue.gotoGameState(`garagemode`)})}function promptSave(){openedDialog.value||(openedDialog.value=`save`,openPrompt(`Enter save name`,`Save`,{buttons:[{label:`Save`,value:text=>({value:1,text}),extras:{default:!0}},{label:`Save and Exit`,value:text=>({value:-1,text}),extras:{accent:ACCENTS.secondary}},{label:`Cancel`,value:text=>({value:0,text}),extras:{cancel:!0,accent:ACCENTS.attention}}],defaultValue:store$1.currentSave.name}).then(res=>{let{value,text}=res;value!==0&&(store$1.currentSave.name=text,store$1.save().then(()=>{value===-1&&openProgress(`Saving and exporting skin...`,`Save`,{cancellable:!1,indeterminate:!0,timeout:1}).promise.then(()=>exit())}),openedDialog.value=null)}))}function promptBack(event){if(openedDialog.value){event.stopPropagation();return}openedDialog.value=`back`,openConfirmation(`Save`,`Save your changes`,[{label:`Save`,value:1,extras:{default:!0}},{label:`Exit (discard changes)`,value:-1,extras:{accent:ACCENTS.attention}},{label:`Cancel`,value:0,extras:{cancel:!0,accent:ACCENTS.secondary}}]).then(res=>{openedDialog.value=null,res===1?promptSave():res===-1&&exit()}),event.stopPropagation()}return(_ctx,_cache)=>withDirectives((openBlock(),createElementBlock(`div`,_hoisted_1$81,[unref(store$1).isSetupDone?createCommentVNode(``,!0):(openBlock(),createElementBlock(`div`,_hoisted_2$69,[..._cache[0]||=[createBaseVNode(`h1`,{class:`text`},`Loading...`,-1)]])),createBaseVNode(`div`,_hoisted_3$60,[createVNode(unref(LiveryEditorHeader_default))]),createBaseVNode(`div`,_hoisted_4$47,[createBaseVNode(`div`,_hoisted_5$39,[(openBlock(),createElementBlock(Fragment,null,renderList(MENU_ITEMS$2,(item,index)=>withDirectives(createVNode(unref(bngImageTile_default),{"bng-nav-item":``,key:item.value,label:item.label,icon:item.icon,onClick:$event=>onMenuItemClicked(item.value)},null,8,[`label`,`icon`,`onClick`]),[[unref(BngBlur_default)],[unref(BngUiNavFocus_default),MENU_ITEMS$2.length-index]])),64))])])])),[[unref(BngOnUiNav_default),promptBack,`menu`],[unref(BngOnUiNav_default),promptBack,`back`],[unref(BngUiNavLabel_default),`Save/Exit`,`menu,back`]])}},LiveryMainNew_default=__plugin_vue_export_helper_default(_sfc_main$89,[[`__scopeId`,`data-v-a9fbf094`]]),_hoisted_1$80={class:`save-info-container`},_hoisted_2$68={class:`file-name`},_hoisted_3$59={class:`file-modified`},_hoisted_4$46={class:`file-size`},_hoisted_5$38={key:0,class:`save-file-actions`},_sfc_main$88=Object.assign({width:14,height:6,margin:.25},{__name:`FileListItem`,props:{name:{type:String,required:!0},location:{type:String,required:!0},modifiedFormatted:String,fileSizeFormatted:String,selected:Boolean},setup(__props){let store$1=useLiveryFileStore(),mainStore=useLiveryMainStore(),props=__props,activated=ref(!1),openedDialog=ref(null);function load(){mainStore.load(props),window.bngVue.gotoGameState(`LiveryMain`)}function rename(){let model={name:props.name};nextTick(()=>{openedDialog.value=`rename`}),openFormDialog(FileEditForm_default,model,model$1=>model$1.name!==null&&model$1.name!==void 0&&model$1.name!==``,`Rename file`,`Enter new name`).then(res=>{res.value&&store$1.renameFile(props,res.formData.name),forceActivateScope()})}function deleteSave(){openConfirmation(`Delete`,`Are you sure you want to delete ${props.name}`).then(res=>{res?store$1.deleteFile(props):forceActivateScope()})}function onActivate$1(activate){activated.value=activate,nextTick(()=>{activate&&openedDialog.value&&(openedDialog.value=null)})}function forceActivateScope(){nextTick(()=>{activated.value=!0})}return(_ctx,_cache)=>withDirectives((openBlock(),createElementBlock(`div`,{class:`file-list-item`,onActivate:_cache[0]||=$event=>onActivate$1(!0),onDeactivate:_cache[1]||=$event=>onActivate$1(!1)},[createBaseVNode(`div`,_hoisted_1$80,[createBaseVNode(`div`,_hoisted_2$68,toDisplayString(__props.name),1),createBaseVNode(`div`,_hoisted_3$59,toDisplayString(__props.modifiedFormatted),1),createBaseVNode(`div`,_hoisted_4$46,toDisplayString(__props.fileSizeFormatted),1)]),__props.selected?(openBlock(),createElementBlock(`div`,_hoisted_5$38,[createVNode(unref(bngButton_default),{icon:unref(icons).import,onClick:load},null,8,[`icon`]),createVNode(unref(bngButton_default),{icon:unref(icons).rename,accent:unref(ACCENTS).secondary,onClick:rename},null,8,[`icon`,`accent`]),createVNode(unref(bngButton_default),{icon:unref(icons).trashBin2,accent:unref(ACCENTS).attention,onClick:deleteSave},null,8,[`icon`,`accent`])])):createCommentVNode(``,!0)],32)),[[unref(BngScopedNav_default),{activated:activated.value}]])}}),FileListItem_default=__plugin_vue_export_helper_default(_sfc_main$88,[[`__scopeId`,`data-v-46a472ab`]]),_hoisted_1$79={class:`livery-manager-view`,"bng-ui-scope":`livery-manager-scope`},_hoisted_2$67={class:`header`},_hoisted_3$58={class:`main-view-content`},_hoisted_4$45={key:1,class:`empty-save-container`},_hoisted_5$37={class:`empty-save-message`},_hoisted_6$28={key:1,class:`menu-container`},_sfc_main$87={__name:`LiveryManager`,setup(__props){let store$1=useLiveryFileStore(),mainStore=useLiveryMainStore(),headerStore=useEditorHeaderStore(),infobar=useInfoBar(),uiNavBlocker=useUINavBlocker();useUINavScope(`livery-manager-scope`);let{files}=storeToRefs(store$1),selectedSave=ref(null),screenState=reactive({isOpenLiveries:!1}),MENU_ITEMS$4=[{label:`New Livery`,value:`new`,icon:icons.plus,action:onCreateNew},{label:`Open Liveries`,value:`load`,icon:icons.decal,action:onOpenLiveries}];watch(()=>files.value,()=>selectedSave.value=null,{deep:!0}),onBeforeMount(()=>{store$1.init()}),onMounted(()=>{headerStore.setHeader(`Livery Editor`),headerStore.setPreheader(null),uiNavBlocker.blockOnly([`tab_l`,`tab_r`]),infobar.visible=!0}),onUnmounted(()=>{uiNavBlocker.clear()});function onCreateNew(){mainStore.isSetupDone=!1,window.bngVue.gotoGameState(`LiveryMain`)}function onOpenLiveries(){screenState.isOpenLiveries=!0,headerStore.setPreheader(`Liveries`)}function goBack(event){screenState.isOpenLiveries?(screenState.isOpenLiveries=!1,selectedSave.value=null):window.bngVue.gotoGameState(`garagemode`),event.stopPropagation()}return(_ctx,_cache)=>withDirectives((openBlock(),createElementBlock(`div`,_hoisted_1$79,[createBaseVNode(`div`,_hoisted_2$67,[createVNode(unref(LiveryEditorHeader_default))]),createBaseVNode(`div`,_hoisted_3$58,[screenState.isOpenLiveries?(openBlock(),createElementBlock(Fragment,{key:0},[unref(files)&&unref(files).length>0?withDirectives((openBlock(),createBlock(unref(bngList_default),{key:0,layout:unref(LIST_LAYOUTS).LIST,"target-width":14,"target-height":6,"target-margin":.25,big:!0,class:`files-list`},{default:withCtx(()=>[(openBlock(!0),createElementBlock(Fragment,null,renderList(unref(files),(file$1,index)=>withDirectives((openBlock(),createBlock(FileListItem_default,mergeProps({ref_for:!0},file$1,{key:file$1.name,selected:selectedSave.value===index,onFocus:$event=>selectedSave.value=index,onClick:$event=>selectedSave.value=index}),null,16,[`selected`,`onFocus`,`onClick`])),[[unref(BngFocusIf_default),selectedSave.value===null&&index===0]])),128))]),_:1},8,[`layout`])),[[unref(BngBlur_default)]]):(openBlock(),createElementBlock(`div`,_hoisted_4$45,[withDirectives((openBlock(),createElementBlock(`div`,_hoisted_5$37,[..._cache[0]||=[createTextVNode(`No saved liveries`,-1)]])),[[unref(BngBlur_default)]])]))],64)):(openBlock(),createElementBlock(`div`,_hoisted_6$28,[(openBlock(),createElementBlock(Fragment,null,renderList(MENU_ITEMS$4,(item,index)=>withDirectives(createVNode(unref(bngImageTile_default),{key:item.value,label:item.label,icon:item.icon,onClick:item.action},null,8,[`label`,`icon`,`onClick`]),[[unref(BngUiNavFocus_default),MENU_ITEMS$4.length-index],[unref(BngBlur_default)]])),64))]))])])),[[unref(BngOnUiNav_default),goBack,`back,menu`],[unref(BngUiNavLabel_default),`Back`,`back,menu`]])}},LiveryManager_default=__plugin_vue_export_helper_default(_sfc_main$87,[[`__scopeId`,`data-v-8e7dbe60`]]),_hoisted_1$78={class:`material-settings-content`},_hoisted_2$66={class:`color-values-container`,"bng-no-child-nav":``},_sfc_main$86={__name:`MaterialSettings`,props:{initialColor:Array},emits:[`change`],setup(__props,{emit:__emit}){let props=__props,emit$1=__emit,paint=new Paint,color=ref({hue:.5,saturation:1,luminosity:.5}),inputHue=computed({get:()=>color.value.hue.toFixed(3),set:newValue=>{color.value.hue=typeof newValue==`string`?+newValue:newValue,notifyListeners()}}),inputSat=computed({get:()=>color.value.saturation.toFixed(3),set:newValue=>{color.value.saturation=typeof newValue==`string`?+newValue:newValue,notifyListeners()}}),inputLum=computed({get:()=>color.value.luminosity.toFixed(3),set:newValue=>{color.value.luminosity=typeof newValue==`string`?+newValue:newValue,notifyListeners()}}),isPreciseActive=ref(!1),colorPickerStep=computed(()=>isPreciseActive.value?.001:.01);watch(()=>props.initialColor,()=>{props.initialColor&&(paint.rgba=props.initialColor,color.value.hue=paint.hsl[0],color.value.saturation=paint.hsl[1],color.value.luminosity=paint.hsl[2])},{deep:!0,immediate:!0});function notifyListeners(){let hsl=[color.value.hue,color.value.saturation,color.value.luminosity];paint.hsl=hsl,emit$1(`change`,{colorHsl:hsl,colorRgb:paint.rgb})}function handleAction2(element){isPreciseActive.value=element.detail.value===1}return(_ctx,_cache)=>withDirectives((openBlock(),createBlock(unref(LayerSettingsBase_default),{class:`material-settings`},{heading:withCtx(()=>[..._cache[4]||=[createTextVNode(`Color`,-1)]]),default:withCtx(()=>[createBaseVNode(`div`,_hoisted_1$78,[createVNode(unref(bngColorPicker_default),{modelValue:color.value,"onUpdate:modelValue":_cache[0]||=$event=>color.value=$event,step:colorPickerStep.value,onChange:notifyListeners},null,8,[`modelValue`,`step`]),createBaseVNode(`div`,_hoisted_2$66,[createVNode(unref(bngInput_default),{prefix:`h`,modelValue:inputHue.value,"onUpdate:modelValue":_cache[1]||=$event=>inputHue.value=$event},null,8,[`modelValue`]),createVNode(unref(bngInput_default),{prefix:`s`,modelValue:inputSat.value,"onUpdate:modelValue":_cache[2]||=$event=>inputSat.value=$event},null,8,[`modelValue`]),createVNode(unref(bngInput_default),{prefix:`b`,modelValue:inputLum.value,"onUpdate:modelValue":_cache[3]||=$event=>inputLum.value=$event},null,8,[`modelValue`])])])]),_:1})),[[unref(BngUiNavLabel_default),`[Hold] Precise`,`action_2`],[unref(BngOnUiNav_default),handleAction2,`action_2`,{up:!0}],[unref(BngOnUiNav_default),handleAction2,`action_2`,{down:!0}]])}},MaterialSettings_default=__plugin_vue_export_helper_default(_sfc_main$86,[[`__scopeId`,`data-v-45b64f6e`]]),_hoisted_1$77={class:`paint-main-view`,"bng-ui-scope":`paint-main-scope`},_hoisted_2$65={class:`header`},_hoisted_3$57={class:`paint-content-container`},_hoisted_4$44={class:`paint-content`},_sfc_main$85={__name:`LiveryPaintMain`,setup(__props){let store$1=useLiveryMainStore(),headerStore=useEditorHeaderStore(),infobar=useInfoBar(),uiNavBlocker=useUINavBlocker(),{events:events$3}=useBridge();useUINavScope(`paint-main-scope`);let initialColor=ref(null),blockedEvents$1=[`tab_r`,`tab_l`];onMounted(()=>{headerStore.setPreheader([`Paint`]),store$1.setup(),infobar.visible=!0,infobar.showSysInfo=!0,uiNavBlocker.blockOnly(blockedEvents$1),events$3.on(`liveryEditor_fill_layerData`,onLayerData),Lua_default.extensions.ui_liveryEditor_layers_fill.requestLayerData()}),onUnmounted(()=>{uiNavBlocker.clear(),events$3.off(`liveryEditor_fill_layerData`)});function onLayerData(data){console.log(`layer data changed`,data),initialColor.value=data.color}function saveChanges(){Lua_default.extensions.ui_liveryEditor_layers_fill.saveChanges().then(()=>{window.bngVue.gotoGameState(`LiveryMain`)})}function restoreDefault(){Lua_default.extensions.ui_liveryEditor_layers_fill.restoreDefault()}function cancelChanges(){openConfirmation(`Undo Changes`,`Lose unsaved changes?`).then(res=>{res&&(Lua_default.extensions.ui_liveryEditor_layers_fill.restoreLayer(),window.bngVue.gotoGameState(`LiveryMain`))})}function onMaterialValueChanged(data){Lua_default.extensions.ui_liveryEditor_layers_fill.updateLayer({color:data.colorRgb})}return(_ctx,_cache)=>withDirectives((openBlock(),createElementBlock(`div`,_hoisted_1$77,[createBaseVNode(`div`,_hoisted_2$65,[createVNode(unref(LiveryEditorHeader_default))]),createBaseVNode(`div`,_hoisted_3$57,[createBaseVNode(`div`,_hoisted_4$44,[withDirectives(createVNode(MaterialSettings_default,{"initial-color":initialColor.value,onChange:onMaterialValueChanged},null,8,[`initial-color`]),[[unref(BngBlur_default)]]),withDirectives((openBlock(),createBlock(unref(bngButton_default),{onClick:saveChanges},{default:withCtx(()=>[createVNode(unref(bngBinding_default),{controller:``,"ui-event":`context`}),_cache[0]||=createBaseVNode(`span`,null,`Apply`,-1)]),_:1})),[[unref(BngOnUiNav_default),void 0,`context`,{asMouse:!0}]]),withDirectives((openBlock(),createBlock(unref(bngButton_default),{accent:`secondary`,onClick:restoreDefault},{default:withCtx(()=>[createVNode(unref(bngBinding_default),{controller:``,"ui-event":`action_3`}),_cache[1]||=createBaseVNode(`span`,null,`Restore Default`,-1)]),_:1})),[[unref(BngOnUiNav_default),void 0,`action_3`,{asMouse:!0}]])])])])),[[unref(BngOnUiNav_default),cancelChanges,`back,menu`],[unref(BngUiNavLabel_default),`Back`,`back,menu`]])}},LiveryPaintMain_default=__plugin_vue_export_helper_default(_sfc_main$85,[[`__scopeId`,`data-v-74e232cb`]]),_hoisted_1$76={class:`layer-inspector-base`},_hoisted_2$64={class:`inspector-heading`},_hoisted_3$56={class:`inspector-content`},_sfc_main$84={__name:`LayerInspectorBase`,props:{heading:{type:String}},setup(__props){return useSlots(),(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$76,[createBaseVNode(`div`,_hoisted_2$64,[createVNode(unref(bngCardHeading_default),{type:`ribbon`},{default:withCtx(()=>[renderSlot(_ctx.$slots,`heading`,{},()=>[createBaseVNode(`span`,null,toDisplayString(__props.heading),1)],!0)]),_:3})]),createBaseVNode(`div`,_hoisted_3$56,[renderSlot(_ctx.$slots,`default`,{},void 0,!0)])]))}},LayerInspectorBase_default=__plugin_vue_export_helper_default(_sfc_main$84,[[`__scopeId`,`data-v-c60f30a4`]]),_hoisted_1$75={class:`direction-buttons-row`},_hoisted_2$63={class:`icon-binding-wrapper`},_hoisted_3$55={class:`icon-binding-wrapper`},_hoisted_4$43={class:`direction-buttons-row`},_hoisted_5$36={class:`icon-binding-wrapper`},_hoisted_6$27={class:`stacked-arrows`},_hoisted_7$24={class:`icon-binding-wrapper`},_hoisted_8$19={class:`stacked-arrows`},_hoisted_9$17={class:`dropdown-container`},_sfc_main$83={__name:`LayerOrder`,setup(__props){let ORDER_TOOL$1=Lua_default.extensions.ui_liveryEditor_tools_group,store$1=useLiveryEditorStore(),_order=ref(2),order=computed({get:()=>_order.value,set(newValue){_order.value=newValue,ORDER_TOOL$1.setOrder(newValue)}});computed(()=>store$1.selectedLayers[0].siblingCount);let orderOptions=computed(()=>Array.from({length:store$1.layers.length-1},(_,i)=>({label:`${i+1}`,value:i+2})));onMounted(()=>{store$1.selectedLayers&&store$1.selectedLayers.length>0&&(_order.value=store$1.selectedLayers[0].order)});let moveUp=()=>{ORDER_TOOL$1.moveOrderUp().then(value=>_order.value=value)},moveDown=()=>{ORDER_TOOL$1.moveOrderDown().then(value=>_order.value=value)},moveToTop=()=>{ORDER_TOOL$1.changeOrderToTop().then(value=>_order.value=value)},moveToBottom=()=>{ORDER_TOOL$1.changeOrderToBottom().then(value=>_order.value=value)};return(_ctx,_cache)=>withDirectives((openBlock(),createBlock(LayerInspectorBase_default,{heading:`Order`},{default:withCtx(()=>[createBaseVNode(`div`,_hoisted_1$75,[withDirectives((openBlock(),createBlock(unref(bngTile_default),{"bng-nav-item":``,label:`Move Up`,onClick:moveUp},{default:withCtx(()=>[createBaseVNode(`div`,_hoisted_2$63,[createVNode(unref(bngIcon_default),{type:unref(icons).arrowLargeUp},null,8,[`type`])])]),_:1})),[[unref(BngOnUiNav_default),moveUp,`ok`,{focusRequired:!0}]]),withDirectives((openBlock(),createBlock(unref(bngTile_default),{"bng-nav-item":``,label:`Move Down`,onClick:moveDown},{default:withCtx(()=>[createBaseVNode(`div`,_hoisted_3$55,[createVNode(unref(bngIcon_default),{type:unref(icons).arrowLargeDown},null,8,[`type`])])]),_:1})),[[unref(BngOnUiNav_default),moveDown,`ok`,{focusRequired:!0}]])]),createBaseVNode(`div`,_hoisted_4$43,[withDirectives((openBlock(),createBlock(unref(bngTile_default),{"bng-nav-item":``,label:`Move to Top`,onClick:moveToTop},{default:withCtx(()=>[createBaseVNode(`div`,_hoisted_5$36,[createBaseVNode(`div`,_hoisted_6$27,[createVNode(unref(bngIcon_default),{type:unref(icons).arrowLargeUp},null,8,[`type`]),createVNode(unref(bngIcon_default),{type:unref(icons).arrowLargeUp},null,8,[`type`])])])]),_:1})),[[unref(BngOnUiNav_default),moveToTop,`ok`,{focusRequired:!0}]]),withDirectives((openBlock(),createBlock(unref(bngTile_default),{"bng-nav-item":``,label:`Move to Bottom`,onClick:moveToBottom},{default:withCtx(()=>[createBaseVNode(`div`,_hoisted_7$24,[createBaseVNode(`div`,_hoisted_8$19,[createVNode(unref(bngIcon_default),{type:unref(icons).arrowLargeDown,disabled:unref(store$1).selectedLayers.length>1},null,8,[`type`,`disabled`]),createVNode(unref(bngIcon_default),{type:unref(icons).arrowLargeDown,disabled:unref(store$1).selectedLayers.length>1},null,8,[`type`,`disabled`])])])]),_:1})),[[unref(BngOnUiNav_default),moveToBottom,`ok`,{focusRequired:!0}]])]),createBaseVNode(`div`,_hoisted_9$17,[createVNode(unref(bngDropdown_default),{modelValue:order.value,"onUpdate:modelValue":_cache[0]||=$event=>order.value=$event,items:orderOptions.value},null,8,[`modelValue`,`items`])])]),_:1})),[[unref(BngBlur_default)]])}},LayerOrder_default=__plugin_vue_export_helper_default(_sfc_main$83,[[`__scopeId`,`data-v-d8fda3d9`]]),_hoisted_1$74={class:`decals-main-view`,"bng-ui-scope":`decals-main-scope`},_hoisted_2$62={class:`header`},_hoisted_3$54={class:`main-view-content`},_hoisted_4$42={class:`add-content-wrapper`},_hoisted_5$35={class:`action-tile`},_hoisted_6$26={key:1,class:`popup-settings`},CAMERA_BUTTONS$1=[{label:`Right`,icon:icons.cameraSideRight,value:`right`},{label:`Front`,icon:icons.cameraFront1,value:`front`},{label:`Left`,icon:icons.cameraSideLeft,value:`left`},{label:`Back`,icon:icons.cameraBack1,value:`back`},{label:`Top Right`,icon:icons.cameraTop1,value:`topright`},{label:`Top Left`,icon:icons.cameraTop1,value:`topleft`},{label:`Top Front`,icon:icons.cameraTop1,value:`topfront`},{label:`Top Back`,icon:icons.cameraTop1,value:`topback`}],BLOCKED_UINAV_EVENTS$1=[`tab_l`,`tab_r`],SHOW_HIDE_DECAL_EVENT=`action_2`,_sfc_main$82={__name:`LiveryDecalsMain`,setup(__props){let ACTION_ITEM_ICON={requestReproject:icons.view,transform:icons.transform,materials:icons.colorPalette,highlight:icons.lightGarageG11,requestMirror:icons.reflect,order:icons.sortAscDown,enabled:icons.eyeOutlineOpened,"enabled-off":icons.eyeOutlineClosed,delete:icons.trashBin1,duplicate:icons.copy},layerActionsState=reactive({mirrored:!1,mirrorFlipped:!1,highlight:!0,enabled:!0}),MIRROR_ITEMS=[{label:`Mirror`,value:`mirror`,isSwitch:!0,switchValue:toRef(layerActionsState,`mirrored`)},{label:`Flip Mirrored`,value:`flipMirrored`,isSwitch:!0,switchValue:toRef(layerActionsState,`mirrorFlipped`),disabled:computed(()=>!layerActionsState.mirrored)}],headerStore=useEditorHeaderStore(),infobar=useInfoBar();useUINavScope(`decals-main-scope`);let uiNavBlocker=useUINavBlocker(),{events:events$3}=useBridge(),layers$1=ref([]),selectedLayers=ref([]),layerActions=ref([]),allowActionsDrawerShow=ref(!0),actionDrawer=ref(null),currentActionDrawerLevel=ref(null),popupSettings=ref(null),isReprojectActive=ref(!1),focusedLayer=ref(null),selectedLayerKeys=computed(()=>selectedLayers.value?selectedLayers.value.map(x=>x.uid):null),actionsDrawerData=computed(()=>{let layerName=selectedLayers.value&&selectedLayers.value.length>0?selectedLayers.value[0].name:null;return layerActions.value&&layerActions.value.length>0?{label:layerName,items:layerActions.value,allowOpenDrawer:!1}:void 0}),contextUIEventLabel=computed(()=>isReprojectActive.value?`Reproject`:`Add Decal`),action2UIEventLabel=computed(()=>focusedLayer.value||selectedLayers.value&&selectedLayers.value.length>0?`Enable/Disable Decal`:void 0);watchEffect(()=>{let eventsToBlock=[...BLOCKED_UINAV_EVENTS$1];uiNavBlocker.clear(),(isReprojectActive.value||!focusedLayer.value&&(!selectedLayers.value||selectedLayers.value.length===0))&&eventsToBlock.push(SHOW_HIDE_DECAL_EVENT),uiNavBlocker.blockOnly(eventsToBlock)}),onBeforeMount(()=>{headerStore.setPreheader([`Decals`])}),onMounted(()=>{infobar.visible=!0,infobar.showSysInfo=!0,events$3.on(`liveryEditor_OnLayersUpdated`,onLayersUpdated),events$3.on(`liveryEditor_selection_actionsUpdated`,onActionsUpdated),events$3.on(`liveryEditor_selection_selectedChanged`,onSelectedChanged),Lua_default.extensions.ui_liveryEditor_layers.requestInitialData(),Lua_default.extensions.ui_liveryEditor_selection.requestInitialData()}),onBeforeUnmount(()=>{events$3.off(`liveryEditor_OnLayersUpdated`,onLayersUpdated),events$3.off(`liveryEditor_selection_actionsUpdated`,onActionsUpdated),events$3.off(`liveryEditor_selection_selectedChanged`,onSelectedChanged)});function onBack(event){popupSettings.value?(popupSettings.value=null,allowActionsDrawerShow.value=!0):actionsDrawerData.value?handleDrawerBack():window.bngVue.gotoGameState(`LiveryMain`),event.stopPropagation()}function addDecal(){window.bngVue.gotoGameState(`LiveryDecalSelector`)}let isReproject;async function onActionSwitchClicked(item){item.switchValue=await Lua_default.extensions.ui_liveryEditor_layerAction.performAction(item.value)}async function onActionTriggered(item){if(!item.value){currentActionDrawerLevel.value===`requestReproject`&&!isReproject&&await Lua_default.extensions.ui_liveryEditor_layerAction.performAction(`cancelReproject`),isReprojectActive.value=!1,isReproject=!1,currentActionDrawerLevel.value=null;return}if((item.lazyLoadItems||item.items)&&(currentActionDrawerLevel.value=item.value),item.value===`requestReproject`){if(!item.items){let timeoutid=setTimeout(()=>{item.items=CAMERA_BUTTONS$1,clearTimeout(timeoutid)},500)}isReprojectActive.value=!0}else if(item.value===`requestMirror`){item.items=MIRROR_ITEMS;return}else if(item.value===`order`){allowActionsDrawerShow.value=!1,popupSettings.value=markRaw(LayerOrder_default);return}else if(CAMERA_BUTTONS$1.find(x=>x.value===item.value)){await Lua_default.extensions.ui_liveryEditor_camera.setOrthographicView(item.value);return}await Lua_default.extensions.ui_liveryEditor_layerAction.performAction(item.value)}function onLayersUpdated(data){layers$1.value=data}function onActionsUpdated(data){if(layerActions.value=data,data&&Array.isArray(data)&&data.length>0){let highlightAction=layerActions.value.find(x=>x.value===`highlight`);highlightAction.switchValue=toRef(layerActionsState,`highlight`)}}function onSelectedChanged(data){if(selectedLayers.value=data,data&&Array.isArray(data)&&data.length>0){let first=data[0];layerActionsState.highlight=first.highlighted,layerActionsState.mirrored=first.mirrored,layerActionsState.mirrorFlipped=first.mirrorFlipped}}let closeActionDrawer=()=>{currentActionDrawerLevel.value&¤tActionDrawerLevel.value===`requestReproject`&&(Lua_default.extensions.ui_liveryEditor_layerAction.performAction(`cancelReproject`).then(()=>{}),currentActionDrawerLevel.value=null),Lua_default.extensions.ui_liveryEditor_selection.clearSelection()};function handleDrawerBack(){currentActionDrawerLevel.value?actionDrawer.value.goBack():closeActionDrawer()}function onFocusedLayer(layer){focusedLayer.value=layer}let toggleEnabled=()=>{if(focusedLayer.value)Lua_default.extensions.ui_liveryEditor_layerAction.toggleEnabledByLayerUid(focusedLayer.value.uid);else if(selectedLayers.value&&selectedLayers.value.length>0){let layer=selectedLayers.value[0];Lua_default.extensions.ui_liveryEditor_layerAction.performAction(`enabled`).then(luaRes=>{layer.enabled=luaRes})}},handleContext=()=>{isReprojectActive.value?Lua_default.extensions.ui_liveryEditor_layerAction.performAction(`reproject`).then(()=>{isReproject=!0,isReprojectActive.value=!1,actionDrawer.value.goBack()}):popupSettings.value||addDecal()},handleAction2=()=>{if(isReprojectActive.value)return!1;toggleEnabled()};return(_ctx,_cache)=>withDirectives((openBlock(),createElementBlock(`div`,_hoisted_1$74,[createBaseVNode(`div`,_hoisted_2$62,[createVNode(unref(LiveryEditorHeader_default))]),createBaseVNode(`div`,_hoisted_3$54,[withDirectives((openBlock(),createBlock(unref(LayersManager_default),{selectedKeys:selectedLayerKeys.value,"onUpdate:selectedKeys":_cache[0]||=$event=>selectedLayerKeys.value=$event,layers:layers$1.value,class:`layers-manager`,onFocusedLayer},{header:withCtx(()=>[createVNode(unref(bngCardHeading_default),{type:`ribbon`},{default:withCtx(()=>[..._cache[1]||=[createTextVNode(`Layers`,-1)]]),_:1}),withDirectives((openBlock(),createBlock(unref(bngButton_default),{"bng-no-nav":`true`,accent:unref(ACCENTS).outlined,onClick:addDecal},{default:withCtx(()=>[createBaseVNode(`span`,_hoisted_4$42,[createVNode(unref(bngBinding_default),{trackIgnore:!0,uiEvent:`context`,deviceMask:`xinput`}),_cache[2]||=createBaseVNode(`span`,{class:`add-label`},`Add Decal`,-1)])]),_:1},8,[`accent`])),[[unref(BngDisabled_default),isReprojectActive.value]])]),_:1},8,[`selectedKeys`,`layers`])),[[unref(BngBlur_default)]]),actionsDrawerData.value&&allowActionsDrawerShow.value?(openBlock(),createBlock(unref(bngActionDrawer_default),{key:0,ref_key:`actionDrawer`,ref:actionDrawer,blur:``,alwaysShowBack:!1,actions:actionsDrawerData.value,"item-width":10,"item-margin":1,class:`actions-drawer`,onSelect:onActionTriggered},{controls:withCtx(()=>[withDirectives(createVNode(unref(bngButton_default),{accent:unref(ACCENTS).outlined,icon:unref(icons).exit,onClick:closeActionDrawer},null,8,[`accent`,`icon`]),[[unref(BngOnUiNav_default),void 0,`ok`,{asMouse:!0,focusRequired:!0}]])]),action:withCtx(({item,select,order})=>[createBaseVNode(`div`,_hoisted_5$35,[item.isSwitch?withDirectives((openBlock(),createBlock(unref(bngTile_default),{key:0,"bng-nav-item":``,label:item.label,onClick:$event=>onActionSwitchClicked(item)},{default:withCtx(()=>[createVNode(unref(bngSwitch_default),{modelValue:item.switchValue,"onUpdate:modelValue":$event=>item.switchValue=$event},null,8,[`modelValue`,`onUpdate:modelValue`])]),_:2},1032,[`label`,`onClick`])),[[unref(BngUiNavFocus_default),order===0?0:void 0],[unref(BngFocusIf_default),order===0],[unref(BngDisabled_default),item.disabled],[unref(BngOnUiNav_default),void 0,`ok`,{asMouse:!0,focusRequired:!0}]]):withDirectives((openBlock(),createBlock(unref(bngImageTile_default),{key:1,"bng-nav-item":``,label:item.label,icon:item.icon?item.icon:ACTION_ITEM_ICON[item.value],class:`action-tile`,onClick:$event=>select(item)},null,8,[`label`,`icon`,`onClick`])),[[unref(BngUiNavFocus_default),order===0?0:void 0],[unref(BngFocusIf_default),order===0],[unref(BngOnUiNav_default),void 0,`ok`,{asMouse:!0,focusRequired:!0}]])])]),_:1},8,[`actions`])):createCommentVNode(``,!0),popupSettings.value?(openBlock(),createElementBlock(`div`,_hoisted_6$26,[(openBlock(),createBlock(resolveDynamicComponent(popupSettings.value)))])):createCommentVNode(``,!0)])])),[[unref(BngUiNavLabel_default),contextUIEventLabel.value,`context`],[unref(BngUiNavLabel_default),action2UIEventLabel.value,`action_2`],[unref(BngUiNavLabel_default),`Back`,`menu,back`],[unref(BngOnUiNav_default),onBack,`menu,back`],[unref(BngOnUiNav_default),handleContext,`context`],[unref(BngOnUiNav_default),handleAction2,`action_2`]])}},LiveryDecalsMain_default=__plugin_vue_export_helper_default(_sfc_main$82,[[`__scopeId`,`data-v-b9d45c3c`]]),_hoisted_1$73={class:`decal-selector-view`,"bng-ui-scope":`decal-selector-scope`},_hoisted_2$61={class:`header`},_hoisted_3$53={class:`main-view-content`},_hoisted_4$41={key:0,class:`side-menu`},_hoisted_5$34={class:`list-container`},BLOCKED_UINAV_EVENTS=[`tab_l`,`tab_r`],_sfc_main$81={__name:`LiveryDecalSelector`,setup(__props){let headerStore=useEditorHeaderStore(),infobar=useInfoBar(),uiNavBlocker=useUINavBlocker(),{events:events$3}=useBridge();useUINavScope(`decal-selector-scope`);let categorizedTextures=ref([]),selectedCategory=ref(null),textures=computed(()=>{if(categorizedTextures.value&&categorizedTextures.value.length>0&&selectedCategory.value){let cat=categorizedTextures.value.find(x=>x.value===selectedCategory.value);if(cat)return cat.items}return null});async function select(item){let layer=await Lua_default.extensions.ui_liveryEditor_layers_decal.addLayerCentered({texturePath:item.preview});await Lua_default.extensions.ui_liveryEditor_selection.select(layer.uid,!0),window.bngVue.gotoGameState(`LiveryDecals`)}function goBack(event){window.bngVue.gotoGameState(`LiveryDecals`),event.stopPropagation()}function onData(data){categorizedTextures.value=data,!data||data.length===0?selectedCategory.value=null:selectedCategory.value||=data[0].value}return onBeforeMount(()=>{headerStore.setPreheader([`Decals`,`Textures`])}),onMounted(()=>{infobar.visible=!0,infobar.showSysInfo=!0,Lua_default.extensions.ui_liveryEditor_resources.requestData(),events$3.on(`liveryEditor_resources_data`,onData),uiNavBlocker.blockOnly(BLOCKED_UINAV_EVENTS)}),onBeforeMount(()=>{events$3.off(`liveryEditor_resources_data`,onData),uiNavBlocker.clear()}),(_ctx,_cache)=>withDirectives((openBlock(),createElementBlock(`div`,_hoisted_1$73,[createBaseVNode(`div`,_hoisted_2$61,[createVNode(unref(LiveryEditorHeader_default))]),createBaseVNode(`div`,_hoisted_3$53,[categorizedTextures.value?withDirectives((openBlock(),createElementBlock(`div`,_hoisted_4$41,[(openBlock(!0),createElementBlock(Fragment,null,renderList(categorizedTextures.value,category=>(openBlock(),createBlock(unref(bngButton_default),{key:category.value,label:category.label,accent:`text`,onClick:$event=>selectedCategory.value=category.value},null,8,[`label`,`onClick`]))),128))])),[[unref(BngBlur_default)]]):createCommentVNode(``,!0),createBaseVNode(`div`,_hoisted_5$34,[textures.value?withDirectives((openBlock(),createBlock(unref(bngList_default),{key:0,layout:unref(LIST_LAYOUTS).TILES,"target-width":8,"target-height":8,"target-margin":.25,big:!0,class:`textures-list`},{default:withCtx(()=>[(openBlock(!0),createElementBlock(Fragment,null,renderList(textures.value,(item,index)=>withDirectives((openBlock(),createBlock(DecalSelectorItem_default,{"bng-nav-item":``,key:item.preview,externalImage:item.preview,"data-decal-item":index,onClick:$event=>select(item)},null,8,[`externalImage`,`data-decal-item`,`onClick`])),[[unref(BngOnUiNav_default),void 0,`ok`,{asMouse:!0,focusRequired:!0}],[unref(BngUiNavFocus_default),index===0?0:void 0],[unref(BngFocusIf_default),index===0]])),128))]),_:1},8,[`layout`])),[[unref(BngBlur_default)]]):createCommentVNode(``,!0)])])])),[[unref(BngOnUiNav_default),goBack,`back,menu`],[unref(BngUiNavLabel_default),`Back`,`back,menu`]])}},LiveryDecalSelector_default=__plugin_vue_export_helper_default(_sfc_main$81,[[`__scopeId`,`data-v-fc11228e`]]),_hoisted_1$72={class:`layer-edit-view`,"bng-ui-scope":`layer-edit-scope`},_hoisted_2$60={class:`header`},_hoisted_3$52={class:`main-view-content`},_hoisted_4$40={class:`menu-container`},MENU_ITEMS$1=[{label:`Projection`,value:`projection`,icon:icons.decal},{label:`Transform`,value:`transform`,icon:icons.colorPalette},{label:`Materials`,value:`materials`,icon:icons.decal}],noop=()=>{},_sfc_main$80={__name:`LiveryLayerEdit`,setup(__props){useEditorHeaderStore(),useDecalSelectorStore();let mainStore=useLiveryMainStore(),infobar=useInfoBar();useUINavScope(`layer-edit-scope`);function onMenuItemClicked(item){switch(item.value){case`transform`:router_default.push({name:`LayerTransform`});break;case`materials`:router_default.push({name:`LayerMaterials`});break;case`projection`:router_default.push({name:`LayerProjection`});break}}function goBack(){router_default.replace({name:`LiveryDecals`}),mainStore.exitLayerEdit()}function saveChanges(){Lua_default.extensions.ui_liveryEditor_layerEdit.saveChanges(!0).then(()=>goBack())}onBeforeMount(()=>{infobar.clearHints(),infobar.addHints(NAV_HINTS)}),onMounted(async()=>{infobar.visible=!0,infobar.showSysInfo=!0,await mainStore.setupLayerEdit(),await Lua_default.extensions.ui_liveryEditor_layerEdit.showCursorOrLayer(!0)}),onBeforeUnmount(async()=>{await Lua_default.extensions.ui_liveryEditor_layerEdit.showCursorOrLayer(!1)});let NAV_HINTS=[{id:`apply`,content:{type:`binding`,props:{uiEvent:`ok`},label:`Done`},action:saveChanges},{id:`back`,content:{type:`binding`,props:{uiEvent:`back`},label:`Back`},action:goBack}];return(_ctx,_cache)=>withDirectives((openBlock(),createElementBlock(`div`,_hoisted_1$72,[createBaseVNode(`div`,_hoisted_2$60,[createVNode(unref(LiveryEditorHeader_default))]),createBaseVNode(`div`,_hoisted_3$52,[createBaseVNode(`div`,_hoisted_4$40,[(openBlock(),createElementBlock(Fragment,null,renderList(MENU_ITEMS$1,item=>withDirectives(createVNode(unref(bngImageTile_default),{"bng-nav-item":``,key:item.value,label:item.label,icon:item.icon,class:`menu-item`,onClick:$event=>onMenuItemClicked(item)},null,8,[`label`,`icon`,`onClick`]),[[unref(BngBlur_default)]])),64))])])])),[[unref(BngOnUiNav_default),goBack,`back`],[unref(BngOnUiNav_default),saveChanges,`menu`],[unref(BngOnUiNav_default),noop,`rotate_h_cam`],[unref(BngOnUiNav_default),noop,`rotate_v_cam`]])}},LiveryLayerEdit_default=__plugin_vue_export_helper_default(_sfc_main$80,[[`__scopeId`,`data-v-c339e1a6`]]),_hoisted_1$71={class:`camera-settings-view`,"bng-ui-scope":`camera-settings-scope`},_hoisted_2$59={class:`header`},_hoisted_3$51={class:`main-view-content`},_hoisted_4$39={class:`menu-container`},MENU_ITEMS=[{label:`Right`,icon:icons.cameraSideRight,value:`right`},{label:`Front`,icon:icons.cameraFront1,value:`front`},{label:`Left`,icon:icons.cameraSideLeft,value:`left`},{label:`Back`,icon:icons.cameraBack1,value:`back`},{label:`Top Right`,icon:icons.cameraTop1,value:`topright`},{label:`Top Left`,icon:icons.cameraTop1,value:`topleft`},{label:`Top Front`,icon:icons.cameraTop1,value:`topfront`},{label:`Top Back`,icon:icons.cameraTop1,value:`topback`}],_sfc_main$79={__name:`LiveryCameraSettings`,setup(__props){let CAMERA_LUA$1=Lua_default.extensions.ui_liveryEditor_camera,headerStore=useEditorHeaderStore();useDecalSelectorStore();let infobar=useInfoBar();useUINavScope(`camera-settings-scope`);function onMenuItemClicked(item){CAMERA_LUA$1.setOrthographicView(item.value)}function goBack(){router_default.replace({name:`LiveryDecals`})}function done(){router_default.replace({name:`LiveryDecalSelector`})}onBeforeMount(()=>{infobar.clearHints(),infobar.addHints(NAV_HINTS),headerStore.setPreheader([`Select Camera`])}),onMounted(()=>{infobar.visible=!0,infobar.showSysInfo=!0});let NAV_HINTS=[{id:`apply`,content:{type:`binding`,props:{uiEvent:`menu`},label:`Done`}},{id:`back`,content:{type:`binding`,props:{uiEvent:`back`},label:`Back`},action:goBack}];return(_ctx,_cache)=>withDirectives((openBlock(),createElementBlock(`div`,_hoisted_1$71,[createBaseVNode(`div`,_hoisted_2$59,[createVNode(unref(LiveryEditorHeader_default))]),createBaseVNode(`div`,_hoisted_3$51,[createBaseVNode(`div`,_hoisted_4$39,[(openBlock(),createElementBlock(Fragment,null,renderList(MENU_ITEMS,item=>withDirectives(createVNode(unref(bngImageTile_default),{"bng-nav-item":``,key:item.value,label:item.label,icon:item.icon,onClick:$event=>onMenuItemClicked(item)},null,8,[`label`,`icon`,`onClick`]),[[unref(BngBlur_default)]])),64))])])])),[[unref(BngOnUiNav_default),goBack,`back`],[unref(BngOnUiNav_default),done,`menu`]])}},LiveryCameraSettings_default=__plugin_vue_export_helper_default(_sfc_main$79,[[`__scopeId`,`data-v-376ce11c`]]),_hoisted_1$70={class:`layer-transform-view`,"bng-ui-scope":`layer-transform-scope`},_hoisted_2$58={class:`header`},_hoisted_3$50={class:`main-view-content`},_hoisted_4$38={class:`inspector-container`},_hoisted_5$33={class:`transform-setting-item`},_hoisted_6$25={key:0},_hoisted_7$23={key:1,class:`transform-setting-inputs`},_hoisted_8$18={class:`slider-text-container`},_hoisted_9$16={class:`slider-text-container`},_hoisted_10$12={key:2,class:`display-values-container`},_hoisted_11$10={key:1,class:`transform-setting-item`},_hoisted_12$7={key:0,class:`transform-setting-inputs`},_hoisted_13$7={class:`slider-text-container`},_hoisted_14$7={class:`slider-text-container`},_hoisted_15$7={key:1,class:`display-values-container`},_hoisted_16$7={key:3,class:`transform-setting-item`},_hoisted_17$6={key:0,class:`transform-setting-inputs`},_hoisted_18$5={class:`slider-text-container`},_hoisted_19$3={key:1,class:`display-values-container`},_hoisted_20$3={key:5,class:`transform-setting-item`},_hoisted_21$3={key:0,class:`transform-setting-inputs`},_hoisted_22$3={class:`slider-text-container`},_hoisted_23$3={class:`slider-text-container`},_hoisted_24$2={key:1,class:`display-values-container`},_hoisted_25$1={class:`edit-button-label`},INPUT_MIN=0,INPUT_MAX=1,_sfc_main$78={__name:`LayerTransform`,setup(__props){let headerStore=useEditorHeaderStore(),infobar=useInfoBar(),navBlocker=useUINavBlocker(),{events:events$3}=useBridge();useUINavScope(`layer-transform-scope`);let transformState=reactive({positionX:0,positionY:0,scaleX:0,scaleY:0,skewX:0,skewY:0,rotation:0}),isHoldModifier=ref(!1),isPreciseActive=ref(!1),isTabRightActive=ref(!1),stateData=ref(null),isEdit=ref(!1),isReapplying=ref(!1),isRepositionActive=ref(!1),isUseMouse=ref(!1),positionX=computed({get:()=>transformState.positionX,set:newValue=>{let value=assertInt(newValue);transformState.positionX=value,isEdit.value&&Lua_default.extensions.ui_liveryEditor_layerEdit.setPosition(value,transformState.positionY)}}),positionY=computed({get:()=>transformState.positionY,set:newValue=>{let value=assertInt(newValue);transformState.positionY=value,isEdit.value&&Lua_default.extensions.ui_liveryEditor_layerEdit.setPosition(transformState.positionX,value)}}),scaleX=computed({get:()=>transformState.scaleX,set:newValue=>{let value=assertInt(newValue);transformState.scaleX=value,isEdit.value&&Lua_default.extensions.ui_liveryEditor_layerEdit.setScale(value,transformState.scaleY)}}),scaleY=computed({get:()=>transformState.scaleY,set:newValue=>{let value=assertInt(newValue);transformState.scaleY=value,isEdit.value&&Lua_default.extensions.ui_liveryEditor_layerEdit.setScale(transformState.scaleX,value)}}),skewX=computed({get:()=>transformState.skewX,set:newValue=>{let value=assertInt(newValue);transformState.skewX=value,isEdit.value&&Lua_default.extensions.ui_liveryEditor_layerEdit.setSkew(value,transformState.skewY)}}),skewY=computed({get:()=>transformState.skewY,set:newValue=>{let value=assertInt(newValue);transformState.skewY=value,isEdit.value&&Lua_default.extensions.ui_liveryEditor_layerEdit.setSkew(transformState.skewX,value)}}),rotation=computed({get:()=>transformState.rotation,set:newValue=>{let value=assertInt(newValue);transformState.rotation=value,isEdit.value&&Lua_default.extensions.ui_liveryEditor_layerEdit.setRotation(value)}}),hintLabels=computed(()=>{let labels={},focusLabel=`Move`,focusEvents=[`focus_l`,`focus_u`,`focus_r`,`focus_d`,`focus_lr`,`focus_ud`],rotateCamLabel=`Scale`;return isTabRightActive.value?rotateCamLabel=`Pan`:isHoldModifier.value&&(rotateCamLabel=`Skew`),!isTabRightActive.value&&!isHoldModifier.value&&focusEvents.forEach(uiEvent=>labels[uiEvent]=`Move`),[`rotate_h_cam`,`rotate_v_cam`].forEach(uiEvent=>labels[uiEvent]=rotateCamLabel),labels.tab_l=isTabRightActive.value?void 0:`[Hold] Skew`,labels.tab_r=isHoldModifier.value?void 0:`[Hold] Camera`,labels.action_2=isTabRightActive.value?void 0:`[Hold] Precise`,labels});watchEffect(()=>{navBlocker.clear(),isTabRightActive.value&&navBlocker.allowOnly([`rotate_h_cam`,`rotate_v_cam`,`tab_r`]),isHoldModifier.value&&navBlocker.allowOnly([`rotate_h_cam`,`rotate_v_cam`,`action_2`,`tab_l`])}),onBeforeMount(()=>{headerStore.setPreheader([`Transform`])}),onMounted(async()=>{infobar.visible=!0,infobar.showSysInfo=!0,events$3.on(`liveryEditor_layerEdit_state`,onStateData),events$3.on(`liveryEditor_layerEdit_initialLayerData`,onInitialLayerData),events$3.on(`liveryEditor_layerEdit_repositionSuccess`,onRepositionSuccess),events$3.on(`liveryEditor_layerEdit_rotationChanged`,onRotationChanged),events$3.on(`liveryEditor_layerEdit_positionChanged`,onPositionChanged),events$3.on(`liveryEditor_layerEdit_scaleChanged`,onScaleChanged),events$3.on(`liveryEditor_layerEdit_skewChanged`,onSkewChanged),await Lua_default.extensions.ui_liveryEditor_layerEdit.requestStateData(),await Lua_default.extensions.ui_liveryEditor_layerEdit.requestInitialLayerData()}),onBeforeUnmount(async()=>{events$3.off(`liveryEditor_layerEdit_state`,onStateData),events$3.off(`liveryEditor_layerEdit_initialLayerData`,onInitialLayerData),events$3.off(`liveryEditor_layerEdit_repositionSuccess`,onRepositionSuccess),events$3.off(`liveryEditor_layerEdit_rotationChanged`,onRotationChanged),events$3.off(`liveryEditor_layerEdit_positionChanged`,onPositionChanged),events$3.off(`liveryEditor_layerEdit_scaleChanged`,onScaleChanged),events$3.off(`liveryEditor_layerEdit_skewChanged`,onSkewChanged)});function onPositionChanged(position){positionX.value=position.x,positionY.value=position.y}function onRotationChanged(value){transformState.rotation=value}function onSkewChanged(skew){skewX.value=skew.x,skewY.value=skew.y}function onScaleChanged(scale){scaleX.value=scale.x,scaleY.value=scale.y}function onRepositionSuccess(){isRepositionActive.value=!isRepositionActive.value}function handleModifier(element){isHoldModifier.value=element.detail.value===1}function handlePrecise(element){let isPrecise=element.detail.value===1;isPreciseActive.value=isPrecise,Lua_default.extensions.ui_liveryEditor_layerEdit.holdPrecise(isPrecise)}function handleTabRight(element){isTabRightActive.value=element.detail.value===1}function handleAction3(element){isRepositionActive.value?toggleUseMouseOrCursor(element):toggleReposition(element)}function toggleReposition(element){let isReposition=isRepositionActive.value;isReposition?Lua_default.extensions.ui_liveryEditor_layerEdit.cancelReposition():Lua_default.extensions.ui_liveryEditor_layerEdit.requestReposition(),isRepositionActive.value=!isReposition}function toggleUseMouseOrCursor(element){if(!isRepositionActive.value)return!0;Lua_default.extensions.ui_liveryEditor_layerEdit.toggleUseMouseOrCursor().then(data=>{isUseMouse.value=data.isUseMouse})}function toggleEdit(element){if(isRepositionActive.value&&isUseMouse.value)return;let newValue=!isEdit.value;isEdit.value=newValue,Lua_default.extensions.ui_liveryEditor_layerEdit.setAllowRotationAction(!newValue).then(()=>{})}function handleFocusLinear(element){if(isEdit.value)return;let name=element.detail.name,value=element.detail.value,axis=name===`focus_d`||name===`focus_u`?`y`:`x`,direction$1=name===`focus_d`||name===`focus_l`?-1:1;Lua_default.extensions.ui_liveryEditor_layerEdit.holdTranslate(axis,direction$1*value)}function handleTranslateScalar(element){if(isEdit.value)return!0;let name=element.detail.name,value=element.detail.value,axis=name===`focus_lr`?`x`:`y`;Lua_default.extensions.ui_liveryEditor_layerEdit.holdTranslateScalar(axis,value)}function handleRotateCam(element){if(isRepositionActive.value||isTabRightActive.value)return!0;let name=element.detail.name,value=element.detail.value,axis=name===`rotate_h_cam`?`x`:`y`;isHoldModifier.value?Lua_default.extensions.ui_liveryEditor_layerEdit.holdSkew(axis,value):Lua_default.extensions.ui_liveryEditor_layerEdit.holdScale(axis,value)}function goBack(event){isRepositionActive.value?toggleReposition():isEdit.value?toggleEdit():openConfirmation(`Exit`,`Exit and lose unsaved changes?`).then(res=>{res&&(Lua_default.extensions.ui_liveryEditor_layerEdit.endTransform(),Lua_default.extensions.ui_liveryEditor_layerEdit.cancelChanges().then(()=>{window.bngVue.gotoGameState(`LiveryDecals`)}))}),event.stopPropagation()}function handleOk(){isRepositionActive.value?Lua_default.extensions.ui_liveryEditor_layerEdit.applyReposition():(Lua_default.extensions.ui_liveryEditor_layerEdit.endTransform(),Lua_default.extensions.ui_liveryEditor_layerEdit.saveChanges(!1).then(()=>{window.bngVue.gotoGameState(`LiveryDecals`)}))}function saveChanges(){Lua_default.extensions.ui_liveryEditor_layerEdit.saveChanges(!1).then(()=>{window.bngVue.gotoGameState(`LiveryDecals`)})}function onStateData(data){stateData.value=data,isReapplying.value=data.isStampReapplying}function onInitialLayerData(data){positionX.value=data.position.x,positionY.value=data.position.y,scaleX.value=data.scale.x,scaleY.value=data.scale.y,skewX.value=data.skew.x,skewY.value=data.skew.y,rotation.value=data.rotation}function assertInt(value){return typeof value==`string`?+value:value}return(_ctx,_cache)=>withDirectives((openBlock(),createElementBlock(`div`,_hoisted_1$70,[createBaseVNode(`div`,_hoisted_2$58,[createVNode(unref(LiveryEditorHeader_default))]),createBaseVNode(`div`,_hoisted_3$50,[createBaseVNode(`div`,_hoisted_4$38,[withDirectives((openBlock(),createBlock(LayerInspectorBase_default,{heading:`Transform`},{default:withCtx(()=>[createBaseVNode(`div`,{class:normalizeClass([`transform-inspector`,{"inspector-editing":isEdit.value}])},[createBaseVNode(`div`,_hoisted_5$33,[_cache[17]||=createBaseVNode(`div`,{class:`setting-item-name`},`Position`,-1),isRepositionActive.value&&isUseMouse.value?(openBlock(),createElementBlock(`div`,_hoisted_6$25,[..._cache[15]||=[createBaseVNode(`span`,null,`Using mouse position`,-1)]])):isEdit.value?(openBlock(),createElementBlock(`div`,_hoisted_7$23,[createBaseVNode(`div`,_hoisted_8$18,[createVNode(unref(bngInput_default),{modelValue:positionX.value,"onUpdate:modelValue":_cache[0]||=$event=>positionX.value=$event,type:`number`,step:.001,min:INPUT_MIN,max:1,prefix:`X`},null,8,[`modelValue`]),createVNode(unref(bngSlider_default),{modelValue:positionX.value,"onUpdate:modelValue":_cache[1]||=$event=>positionX.value=$event,step:.001,min:INPUT_MIN,max:1},null,8,[`modelValue`])]),createBaseVNode(`div`,_hoisted_9$16,[createVNode(unref(bngInput_default),{modelValue:positionY.value,"onUpdate:modelValue":_cache[2]||=$event=>positionY.value=$event,type:`number`,step:.001,min:INPUT_MIN,max:1,prefix:`Y`},null,8,[`modelValue`]),createVNode(unref(bngSlider_default),{modelValue:positionY.value,"onUpdate:modelValue":_cache[3]||=$event=>positionY.value=$event,step:.001,min:INPUT_MIN,max:1},null,8,[`modelValue`])])])):(openBlock(),createElementBlock(`div`,_hoisted_10$12,[createVNode(unref(bngPropVal_default),{keyLabel:`X`,valueLabel:positionX.value},null,8,[`valueLabel`]),createVNode(unref(bngPropVal_default),{keyLabel:`Y`,valueLabel:positionY.value},null,8,[`valueLabel`])])),isRepositionActive.value?createCommentVNode(``,!0):(openBlock(),createBlock(unref(bngButton_default),{key:3,accent:`outlined`,class:`reposition-button`,onClick:toggleReposition},{default:withCtx(()=>[createVNode(unref(bngBinding_default),{uiEvent:`action_3`}),_cache[16]||=createBaseVNode(`span`,{class:`reposition-button-label`},`Reproject and Position`,-1)]),_:1}))]),isRepositionActive.value?createCommentVNode(``,!0):(openBlock(),createBlock(unref(bngDivider_default),{key:0})),isRepositionActive.value?createCommentVNode(``,!0):(openBlock(),createElementBlock(`div`,_hoisted_11$10,[_cache[18]||=createBaseVNode(`div`,{class:`setting-item-name`},`Scale`,-1),isEdit.value?(openBlock(),createElementBlock(`div`,_hoisted_12$7,[createBaseVNode(`div`,_hoisted_13$7,[createVNode(unref(bngInput_default),{modelValue:scaleX.value,"onUpdate:modelValue":_cache[4]||=$event=>scaleX.value=$event,type:`number`,prefix:`X`,step:.01,min:INPUT_MIN,max:15},null,8,[`modelValue`]),createVNode(unref(bngSlider_default),{modelValue:scaleX.value,"onUpdate:modelValue":_cache[5]||=$event=>scaleX.value=$event,step:.01,min:INPUT_MIN,max:15},null,8,[`modelValue`])]),createBaseVNode(`div`,_hoisted_14$7,[createVNode(unref(bngInput_default),{modelValue:scaleY.value,"onUpdate:modelValue":_cache[6]||=$event=>scaleY.value=$event,type:`number`,step:.01,min:INPUT_MIN,max:15,prefix:`Y`},null,8,[`modelValue`]),createVNode(unref(bngSlider_default),{modelValue:scaleY.value,"onUpdate:modelValue":_cache[7]||=$event=>scaleY.value=$event,step:.01,min:INPUT_MIN,max:15},null,8,[`modelValue`])])])):(openBlock(),createElementBlock(`div`,_hoisted_15$7,[createVNode(unref(bngPropVal_default),{keyLabel:`X`,valueLabel:scaleX.value},null,8,[`valueLabel`]),createVNode(unref(bngPropVal_default),{keyLabel:`Y`,valueLabel:scaleY.value},null,8,[`valueLabel`])]))])),isRepositionActive.value?createCommentVNode(``,!0):(openBlock(),createBlock(unref(bngDivider_default),{key:2})),isRepositionActive.value?createCommentVNode(``,!0):(openBlock(),createElementBlock(`div`,_hoisted_16$7,[_cache[19]||=createBaseVNode(`div`,{class:`setting-item-name`},`Rotate`,-1),isEdit.value?(openBlock(),createElementBlock(`div`,_hoisted_17$6,[createBaseVNode(`div`,_hoisted_18$5,[createVNode(unref(bngInput_default),{modelValue:rotation.value,"onUpdate:modelValue":_cache[8]||=$event=>rotation.value=$event,type:`number`,step:.1,min:INPUT_MIN,max:359.9,suffix:`deg`},null,8,[`modelValue`]),createVNode(unref(bngSlider_default),{modelValue:rotation.value,"onUpdate:modelValue":_cache[9]||=$event=>rotation.value=$event,step:.1,min:INPUT_MIN,max:359.9},null,8,[`modelValue`])])])):(openBlock(),createElementBlock(`div`,_hoisted_19$3,[createVNode(unref(bngPropVal_default),{keyLabel:`deg`,valueLabel:rotation.value},null,8,[`valueLabel`])]))])),isRepositionActive.value?createCommentVNode(``,!0):(openBlock(),createBlock(unref(bngDivider_default),{key:4})),isRepositionActive.value?createCommentVNode(``,!0):(openBlock(),createElementBlock(`div`,_hoisted_20$3,[_cache[20]||=createBaseVNode(`div`,{class:`setting-item-name`},`Skew`,-1),isEdit.value?(openBlock(),createElementBlock(`div`,_hoisted_21$3,[createBaseVNode(`div`,_hoisted_22$3,[createVNode(unref(bngInput_default),{modelValue:skewX.value,"onUpdate:modelValue":_cache[10]||=$event=>skewX.value=$event,type:`number`,step:.01,min:INPUT_MIN,max:INPUT_MAX,prefix:`X`},null,8,[`modelValue`]),createVNode(unref(bngSlider_default),{modelValue:skewX.value,"onUpdate:modelValue":_cache[11]||=$event=>skewX.value=$event,step:.01,min:INPUT_MIN,max:INPUT_MAX},null,8,[`modelValue`])]),createBaseVNode(`div`,_hoisted_23$3,[createVNode(unref(bngInput_default),{modelValue:skewY.value,"onUpdate:modelValue":_cache[12]||=$event=>skewY.value=$event,type:`number`,step:.01,min:INPUT_MIN,max:INPUT_MAX,prefix:`Y`},null,8,[`modelValue`]),createVNode(unref(bngSlider_default),{modelValue:skewY.value,"onUpdate:modelValue":_cache[13]||=$event=>skewY.value=$event,step:.01,min:INPUT_MIN,max:INPUT_MAX},null,8,[`modelValue`])])])):(openBlock(),createElementBlock(`div`,_hoisted_24$2,[createVNode(unref(bngPropVal_default),{keyLabel:`X`,valueLabel:skewX.value},null,8,[`valueLabel`]),createVNode(unref(bngPropVal_default),{keyLabel:`Y`,valueLabel:skewY.value},null,8,[`valueLabel`])]))])),!isRepositionActive.value||!isUseMouse.value?withDirectives((openBlock(),createBlock(unref(bngButton_default),{key:6,accent:`text`,class:`inspector-edit-button`,onClick:_cache[14]||=$event=>isEdit.value=!isEdit.value},{default:withCtx(()=>[createVNode(unref(bngBinding_default),{uiEvent:`context`}),createBaseVNode(`span`,_hoisted_25$1,` Toggle `+toDisplayString(isEdit.value?`Simple`:`Advance`),1)]),_:1})),[[unref(BngOnUiNav_default),()=>isEdit.value=!isEdit.value,`ok`,{focusRequired:!0}]]):createCommentVNode(``,!0)],2)]),_:1})),[[unref(BngBlur_default)]]),!isRepositionActive.value||!isUseMouse.value?withDirectives((openBlock(),createBlock(unref(bngButton_default),{key:0,class:`apply-button`,onClick:handleOk},{default:withCtx(()=>[createVNode(unref(bngBinding_default),{uiEvent:`ok`}),_cache[21]||=createBaseVNode(`span`,null,`Apply`,-1)]),_:1})),[[unref(BngOnUiNav_default),handleOk,`ok`,{focusRequired:!0}]]):createCommentVNode(``,!0)])])])),[[unref(BngOnUiNav_default),handleOk,`ok`],[unref(BngOnUiNav_default),goBack,`back`],[unref(BngOnUiNav_default),saveChanges,`menu`],[unref(BngOnUiNav_default),handleTranslateScalar,`focus_lr`],[unref(BngOnUiNav_default),handleTranslateScalar,`focus_ud`],[unref(BngOnUiNav_default),handleFocusLinear,`focus_l`,{up:!0}],[unref(BngOnUiNav_default),handleFocusLinear,`focus_l`,{down:!0}],[unref(BngOnUiNav_default),handleFocusLinear,`focus_r`,{up:!0}],[unref(BngOnUiNav_default),handleFocusLinear,`focus_r`,{down:!0}],[unref(BngOnUiNav_default),handleFocusLinear,`focus_u`,{up:!0}],[unref(BngOnUiNav_default),handleFocusLinear,`focus_u`,{down:!0}],[unref(BngOnUiNav_default),handleFocusLinear,`focus_d`,{up:!0}],[unref(BngOnUiNav_default),handleFocusLinear,`focus_d`,{down:!0}],[unref(BngOnUiNav_default),handleFocusLinear,`focus_l`,{up:!0,modified:!0}],[unref(BngOnUiNav_default),handleFocusLinear,`focus_l`,{down:!0,modified:!0}],[unref(BngOnUiNav_default),handleFocusLinear,`focus_r`,{up:!0,modified:!0}],[unref(BngOnUiNav_default),handleFocusLinear,`focus_r`,{down:!0,modified:!0}],[unref(BngOnUiNav_default),handleFocusLinear,`focus_u`,{up:!0,modified:!0}],[unref(BngOnUiNav_default),handleFocusLinear,`focus_u`,{down:!0,modified:!0}],[unref(BngOnUiNav_default),handleFocusLinear,`focus_d`,{up:!0,modified:!0}],[unref(BngOnUiNav_default),handleFocusLinear,`focus_d`,{down:!0,modified:!0}],[unref(BngOnUiNav_default),handleRotateCam,`rotate_h_cam`],[unref(BngOnUiNav_default),handleRotateCam,`rotate_v_cam`],[unref(BngOnUiNav_default),handleRotateCam,`rotate_h_cam`,{modified:!0}],[unref(BngOnUiNav_default),handleRotateCam,`rotate_v_cam`,{modified:!0}],[unref(BngOnUiNav_default),handlePrecise,`action_2`,{up:!0}],[unref(BngOnUiNav_default),handlePrecise,`action_2`,{down:!0}],[unref(BngOnUiNav_default),handlePrecise,`action_2`,{up:!0,modified:!0}],[unref(BngOnUiNav_default),handlePrecise,`action_2`,{down:!0,modified:!0}],[unref(BngOnUiNav_default),handleModifier,`tab_l`,{up:!0}],[unref(BngOnUiNav_default),handleModifier,`tab_l`,{down:!0}],[unref(BngOnUiNav_default),handleTabRight,`tab_r`,{up:!0}],[unref(BngOnUiNav_default),handleTabRight,`tab_r`,{down:!0}],[unref(BngOnUiNav_default),handleAction3,`action_3`],[unref(BngOnUiNav_default),toggleEdit,`context`],[unref(BngUiNavLabel_default),hintLabels.value.focus_lr,`focus_lr`],[unref(BngUiNavLabel_default),hintLabels.value.focus_ud,`focus_ud`],[unref(BngUiNavLabel_default),hintLabels.value.focus_l,`focus_l`],[unref(BngUiNavLabel_default),hintLabels.value.focus_r,`focus_r`],[unref(BngUiNavLabel_default),hintLabels.value.focus_u,`focus_u`],[unref(BngUiNavLabel_default),hintLabels.value.focus_d,`focus_d`],[unref(BngUiNavLabel_default),hintLabels.value.rotate_h_cam,`rotate_h_cam`],[unref(BngUiNavLabel_default),hintLabels.value.rotate_v_cam,`rotate_v_cam`],[unref(BngUiNavLabel_default),hintLabels.value.action_2,`action_2`],[unref(BngUiNavLabel_default),hintLabels.value.action_3,`action_3`],[unref(BngUiNavLabel_default),hintLabels.value.tab_r,`tab_r`],[unref(BngUiNavLabel_default),hintLabels.value.tab_l,`tab_l`],[unref(BngUiNavLabel_default),hintLabels.value.ok,`ok`],[unref(BngUiNavLabel_default),hintLabels.value.back,`back`]])}},LayerTransform_default=__plugin_vue_export_helper_default(_sfc_main$78,[[`__scopeId`,`data-v-a4399a23`]]),_hoisted_1$69={class:`layer-materials-view`,"bng-ui-scope":`layer-materials-scope`},_hoisted_2$57={class:`header`},_hoisted_3$49={class:`main-view-content`},_hoisted_4$37={class:`inspector-container`},_hoisted_5$32={class:`materials-inspector`},_hoisted_6$24={class:`materials-setting-item`},_hoisted_7$22={class:`color-values-container`,"bng-no-child-nav":``},_hoisted_8$17={class:`materials-setting-item`},_hoisted_9$15={class:`slider-text-container`},_hoisted_10$11={class:`materials-setting-item`},_hoisted_11$9={class:`slider-text-container`},BLOCKED_UI_EVENTS=[`tab_l`,`tab_r`,`action_2`,`rotate_h_cam`,`rotate_v_cam`,`focus_lr`,`focus_ud`],_sfc_main$77={__name:`LayerMaterials`,setup(__props){let headerStore=useEditorHeaderStore(),infobar=useInfoBar(),uiNavBlocker=useUINavBlocker();useUINavScope(`layer-materials-scope`);let{events:events$3}=useBridge(),screenState=reactive({openedDialog:null}),color=ref({hue:.5,saturation:1,luminosity:.5}),inputHue=computed({get:()=>color.value.hue.toFixed(3),set:newValue=>{color.value.hue=typeof newValue==`string`?+newValue:newValue,onColorChanged()}}),inputSat=computed({get:()=>color.value.saturation.toFixed(3),set:newValue=>{color.value.saturation=typeof newValue==`string`?+newValue:newValue,onColorChanged()}}),inputLum=computed({get:()=>color.value.luminosity.toFixed(3),set:newValue=>{color.value.luminosity=typeof newValue==`string`?+newValue:newValue,onColorChanged()}}),metallicIntensity=ref(0),roughnessIntensity=ref(0),stateData=ref(),colorInitialized=ref(!1),isPreciseActive=ref(!1),colorPickerStep=computed(()=>isPreciseActive.value?.001:.01),slidersStep=computed(()=>isPreciseActive.value?.1:1),updateMaterialProperties=properties=>Lua_default.extensions.ui_liveryEditor_layerEdit.setLayerMaterials(properties);function onColorChanged(){if(!colorInitialized.value)return;let paint=new Paint;paint.hsl=[color.value.hue,color.value.saturation,color.value.luminosity],updateMaterialProperties({color:paint.rgba})}watch(()=>metallicIntensity.value,value=>updateMaterialProperties({metallicIntensity:value})),watch(()=>roughnessIntensity.value,value=>updateMaterialProperties({roughnessIntensity:value})),onBeforeMount(()=>{headerStore.setPreheader([`Materials`])}),onMounted(async()=>{infobar.visible=!0,infobar.showSysInfo=!0,uiNavBlocker.blockOnly(BLOCKED_UI_EVENTS),events$3.on(`liveryEditor_layerEdit_state`,onStateData),events$3.on(`liveryEditor_layerEdit_layerMaterialsData`,onMaterialPropertiesData),await Lua_default.extensions.ui_liveryEditor_layerEdit.requestStateData(),await Lua_default.extensions.ui_liveryEditor_layerEdit.requestLayerMaterials()}),onBeforeUnmount(async()=>{events$3.off(`liveryEditor_layerEdit_layerMaterialsData`,onMaterialPropertiesData),events$3.off(`liveryEditor_layerEdit_state`,onStateData),uiNavBlocker.clear()});async function onStateData(data){stateData.value=data}function onMaterialPropertiesData(data){colorInitialized.value=!1;let paint=new Paint;data.color[3]=1;let isWhite=data.color.every(num=>num===1);paint.rgba=data.color,color.value.hue=paint.hue,color.value.saturation=isWhite?.5:paint.saturation,color.value.luminosity=paint.luminosity,colorInitialized.value=!0,metallicIntensity.value=data.metallicIntensity,roughnessIntensity.value=data.roughnessIntensity}function handleAction2(element){isPreciseActive.value=element.detail.value===1}function goBack(event){screenState.openedDialog||(screenState.openedDialog=`exit`,openConfirmation(`Exit`,`Exit and lose changes?`).then(res=>{res&&Lua_default.extensions.ui_liveryEditor_layerEdit.cancelChanges().then(()=>{window.bngVue.gotoGameState(`LiveryDecals`)}),screenState.openedDialog=null}),event.stopPropagation())}function saveChanges(){Lua_default.extensions.ui_liveryEditor_layerEdit.saveChanges().then(()=>{window.bngVue.gotoGameState(`LiveryDecals`)})}return(_ctx,_cache)=>withDirectives((openBlock(),createElementBlock(`div`,_hoisted_1$69,[createBaseVNode(`div`,_hoisted_2$57,[createVNode(unref(LiveryEditorHeader_default))]),createBaseVNode(`div`,_hoisted_3$49,[createBaseVNode(`div`,_hoisted_4$37,[withDirectives((openBlock(),createBlock(LayerInspectorBase_default,{heading:`Materials`,class:``},{default:withCtx(()=>[createBaseVNode(`div`,_hoisted_5$32,[createBaseVNode(`div`,_hoisted_6$24,[_cache[8]||=createBaseVNode(`div`,{class:`setting-item-name`},`Color`,-1),withDirectives(createVNode(unref(bngColorPicker_default),{modelValue:color.value,"onUpdate:modelValue":_cache[0]||=$event=>color.value=$event,step:colorPickerStep.value,onChange:onColorChanged},null,8,[`modelValue`,`step`]),[[unref(BngUiNavFocus_default),0]]),createBaseVNode(`div`,_hoisted_7$22,[createVNode(unref(bngInput_default),{prefix:`h`,modelValue:inputHue.value,"onUpdate:modelValue":_cache[1]||=$event=>inputHue.value=$event,type:`number`},null,8,[`modelValue`]),createVNode(unref(bngInput_default),{prefix:`s`,modelValue:inputSat.value,"onUpdate:modelValue":_cache[2]||=$event=>inputSat.value=$event,type:`number`},null,8,[`modelValue`]),createVNode(unref(bngInput_default),{prefix:`b`,modelValue:inputLum.value,"onUpdate:modelValue":_cache[3]||=$event=>inputLum.value=$event,type:`number`},null,8,[`modelValue`])])]),createVNode(unref(bngDivider_default)),createBaseVNode(`div`,_hoisted_8$17,[_cache[9]||=createBaseVNode(`div`,{class:`setting-item-name`},`Metallic Intensity`,-1),createBaseVNode(`div`,_hoisted_9$15,[createVNode(unref(bngInput_default),{"bng-no-nav":``,modelValue:metallicIntensity.value,"onUpdate:modelValue":_cache[4]||=$event=>metallicIntensity.value=$event,type:`number`,min:0,max:100,step:slidersStep.value},null,8,[`modelValue`,`step`]),createVNode(unref(bngSlider_default),{modelValue:metallicIntensity.value,"onUpdate:modelValue":_cache[5]||=$event=>metallicIntensity.value=$event,min:0,max:100,step:slidersStep.value},null,8,[`modelValue`,`step`])])]),createVNode(unref(bngDivider_default)),createBaseVNode(`div`,_hoisted_10$11,[_cache[10]||=createBaseVNode(`div`,{class:`setting-item-name`},`Roughness Intensity`,-1),createBaseVNode(`div`,_hoisted_11$9,[createVNode(unref(bngInput_default),{"bng-no-nav":``,modelValue:roughnessIntensity.value,"onUpdate:modelValue":_cache[6]||=$event=>roughnessIntensity.value=$event,type:`number`,min:0,max:100,step:slidersStep.value},null,8,[`modelValue`,`step`]),createVNode(unref(bngSlider_default),{modelValue:roughnessIntensity.value,"onUpdate:modelValue":_cache[7]||=$event=>roughnessIntensity.value=$event,min:0,max:100,step:slidersStep.value},null,8,[`modelValue`,`step`])])])])]),_:1})),[[unref(BngBlur_default)]])])])])),[[unref(BngUiNavLabel_default),`Apply`,`context`],[unref(BngUiNavLabel_default),`[Hold]Precise`,`action_2`],[unref(BngUiNavLabel_default),`Back`,`back,menu`],[unref(BngOnUiNav_default),handleAction2,`action_2`,{up:!0}],[unref(BngOnUiNav_default),handleAction2,`action_2`,{down:!0}],[unref(BngOnUiNav_default),goBack,`back,menu`],[unref(BngOnUiNav_default),saveChanges,`context`]])}},LayerMaterials_default=__plugin_vue_export_helper_default(_sfc_main$77,[[`__scopeId`,`data-v-4b3730e9`]]),_hoisted_1$68={class:`layer-projection-view`,"bng-ui-scope":`layer-projection-scope`},_hoisted_2$56={class:`header`},_hoisted_3$48={class:`main-view-content`},_hoisted_4$36={class:`camera-views-container`},_hoisted_5$31={class:`mirror-settings-container`},CAMERA_BUTTONS=[{label:`Right`,icon:icons.cameraSideRight,value:`right`},{label:`Front`,icon:icons.cameraFront1,value:`front`},{label:`Left`,icon:icons.cameraSideLeft,value:`left`},{label:`Back`,icon:icons.cameraBack1,value:`back`},{label:`Top Right`,icon:icons.cameraTop1,value:`topright`},{label:`Top Left`,icon:icons.cameraTop1,value:`topleft`},{label:`Top Front`,icon:icons.cameraTop1,value:`topfront`},{label:`Top Back`,icon:icons.cameraTop1,value:`topback`}],_sfc_main$76={__name:`LayerProjection`,setup(__props){let{events:events$3}=useBridge(),headerStore=useEditorHeaderStore(),store$1=useLiveryEditorStore(),infobar=useInfoBar(),popover=usePopover(),uiNav=useUINavScope(`layer-projection-scope`),stateData=ref(null),mirrorState=reactive({mirrored:!1,mirrorFipped:!1,mirrorOffset:0}),mirrored=computed({get:()=>mirrorState.mirrored,set:async newValue=>{mirrorState.mirrored=newValue,await Lua_default.extensions.ui_liveryEditor_layerEdit.setMirrored(newValue,mirrorState.mirrorFipped,mirrorState.mirrorOffset)}}),mirrorFipped=computed({get:()=>mirrorState.mirrorFipped,set:async newValue=>{mirrorState.mirrorFipped=newValue,await Lua_default.extensions.ui_liveryEditor_layerEdit.setMirrored(mirrorState.mirrored,newValue,mirrorState.mirrorOffset)}}),mirrorOffset=computed({get:()=>mirrorState.mirrorOffset,set:async newValue=>{mirrorState.mirrorOffset=newValue,await Lua_default.extensions.ui_liveryEditor_layerEdit.setMirrored(mirrorState.mirrored,mirrorState.mirrorFipped,newValue)}}),NAV_HINTS=[{id:`apply`,content:{type:`binding`,props:{uiEvent:`menu`},label:`Done`},action:saveChanges},{id:`back`,content:{type:`binding`,props:{uiEvent:`back`},label:`Back`},action:goBack}];onBeforeMount(()=>{infobar.clearHints(),infobar.addHints(NAV_HINTS),headerStore.setPreheader([`Projection`]),headerStore.setHeader(`Decals`)}),onMounted(async()=>{infobar.visible=!0,infobar.showSysInfo=!0,events$3.on(`liveryEditor_layerEdit_state`,onStateData),events$3.on(`liveryEditor_layerEdit_initialLayerData`,onInitialLayerData),await Lua_default.extensions.ui_liveryEditor_layerEdit.requestStateData(),await Lua_default.extensions.ui_liveryEditor_layerEdit.requestInitialLayerData()}),onBeforeUnmount(()=>{events$3.off(`liveryEditor_layerEdit_state`,onStateData),events$3.off(`liveryEditor_layerEdit_initialLayerData`,onInitialLayerData)});function changeCameraView(view){popover.hide(`camera-views-menu`),console.log(`changeCameraView`,view),store$1.setOrthographicView(view)}function onStateData(data){console.log(`onStateData`,data),stateData.value=data}function onInitialLayerData(data){mirrorState.mirrored=data.mirrored,mirrorState.mirrorFipped=data.mirrorFipped,mirrorState.mirrorOffset=data.mirrorOffset}function goBack(){window.bngVue.gotoGameState(`LiveryLayerEdit`)}function saveChanges(){window.bngVue.gotoGameState(`LiveryLayerEdit`)}function onPopoverMenuHide(){uiNav.set(`layer-projection-scope`)}return(_ctx,_cache)=>withDirectives((openBlock(),createElementBlock(`div`,_hoisted_1$68,[createBaseVNode(`div`,_hoisted_2$56,[createVNode(unref(LiveryEditorHeader_default))]),createBaseVNode(`div`,_hoisted_3$48,[withDirectives(createVNode(unref(bngImageTile_default),{"bng-nav-item":``,icon:unref(icons).movieCamera,label:`Side`},null,8,[`icon`]),[[unref(BngBlur_default)],[unref(BngPopover_default),`camera-views-menu`,`right-start`,{click:!0}]]),withDirectives(createVNode(unref(bngImageTile_default),{"bng-nav-item":``,icon:unref(icons).reflect,label:`Mirror`},null,8,[`icon`]),[[unref(BngBlur_default)],[unref(BngPopover_default),`mirror-settings-menu`,`right-start`,{click:!0}]])]),createVNode(unref(bngPopoverMenu_default),{name:`camera-views-menu`,onHide:onPopoverMenuHide},{default:withCtx(()=>[createBaseVNode(`div`,_hoisted_4$36,[createVNode(unref(bngList_default),{targetWidth:8,targetMargin:.5,noBackground:``},{default:withCtx(()=>[(openBlock(),createElementBlock(Fragment,null,renderList(CAMERA_BUTTONS,view=>createVNode(unref(bngImageTile_default),{key:view.value,"bng-nav-item":``,label:view.label,icon:view.icon,onClick:$event=>changeCameraView(view.value)},null,8,[`label`,`icon`,`onClick`])),64))]),_:1})])]),_:1}),createVNode(unref(bngPopoverMenu_default),{name:`mirror-settings-menu`,onHide:onPopoverMenuHide},{default:withCtx(()=>[createBaseVNode(`div`,_hoisted_5$31,[createVNode(unref(bngPillCheckbox_default),{modelValue:mirrored.value,"onUpdate:modelValue":_cache[0]||=$event=>mirrored.value=$event},{default:withCtx(()=>[..._cache[3]||=[createTextVNode(`Mirrored`,-1)]]),_:1},8,[`modelValue`]),withDirectives((openBlock(),createBlock(unref(bngPillCheckbox_default),{modelValue:mirrorFipped.value,"onUpdate:modelValue":_cache[1]||=$event=>mirrorFipped.value=$event},{default:withCtx(()=>[..._cache[4]||=[createTextVNode(`Mirror Flipped`,-1)]]),_:1},8,[`modelValue`])),[[unref(BngDisabled_default),!mirrored.value]]),createVNode(unref(bngInput_default),{modelValue:mirrorOffset.value,"onUpdate:modelValue":_cache[2]||=$event=>mirrorOffset.value=$event,externalLabel:`Offset`,type:`number`,disabled:!mirrored.value},null,8,[`modelValue`,`disabled`])])]),_:1})])),[[unref(BngOnUiNav_default),goBack,`back`],[unref(BngOnUiNav_default),goBack,`menu`]])}},LayerProjection_default=__plugin_vue_export_helper_default(_sfc_main$76,[[`__scopeId`,`data-v-19e531c7`]]),_hoisted_1$67={class:`settings-main-view`,"bng-ui-scope":`settings-main-scope`},_hoisted_2$55={class:`header`},_hoisted_3$47={class:`main-view-content`},_hoisted_4$35={class:`settings-container`},_hoisted_5$30={class:`settings-item`},_sfc_main$75={__name:`LiverySettingsMain`,setup(__props){let headerStore=useEditorHeaderStore(),infobar=useInfoBar();useUINavScope(`settings-main-scope`);let{events:events$3}=useBridge(),stateData=ref(null),useSurfaceNormal=ref(!1);watch(()=>useSurfaceNormal.value,async value=>{await Lua_default.extensions.ui_liveryEditor.useSurfaceNormal(value)});let NAV_HINTS=[{id:`back`,content:{type:`binding`,props:{uiEvent:`back`},label:`Back`},action:goBack}];onBeforeMount(()=>{infobar.clearHints(),infobar.addHints(NAV_HINTS),headerStore.setHeader(`Decals`),headerStore.setPreheader([`Settings`])}),onMounted(async()=>{infobar.visible=!0,infobar.showSysInfo=!0,events$3.on(`liveryEditor_settingsData`,onSettingsData),await Lua_default.extensions.ui_liveryEditor.requestSettingsData()}),onBeforeUnmount(()=>{events$3.off(`liveryEditor_settingsData`,onSettingsData)});function onSettingsData(data){console.log(`onSettingsData`,data),stateData.value=data,useSurfaceNormal.value=data.useSurfaceNormal}function goBack(event){window.bngVue.gotoGameState(`LiveryMain`),event.stopPropagation()}return(_ctx,_cache)=>withDirectives((openBlock(),createElementBlock(`div`,_hoisted_1$67,[createBaseVNode(`div`,_hoisted_2$55,[createVNode(unref(LiveryEditorHeader_default))]),createBaseVNode(`div`,_hoisted_3$47,[withDirectives((openBlock(),createBlock(unref(bngCard_default),null,{default:withCtx(()=>[createVNode(unref(bngCardHeading_default),null,{default:withCtx(()=>[..._cache[1]||=[createTextVNode(`Settings`,-1)]]),_:1}),createBaseVNode(`div`,_hoisted_4$35,[createBaseVNode(`div`,_hoisted_5$30,[_cache[2]||=createBaseVNode(`div`,{class:`settings-item-name`},`Use Surface Normal`,-1),withDirectives(createVNode(unref(bngSwitch_default),{modelValue:useSurfaceNormal.value,"onUpdate:modelValue":_cache[0]||=$event=>useSurfaceNormal.value=$event,label:useSurfaceNormal.value?`Yes`:`No`},null,8,[`modelValue`,`label`]),[[unref(BngUiNavFocus_default),0],[unref(BngFocusIf_default),!0]])])])]),_:1})),[[unref(BngBlur_default)]])])])),[[unref(BngOnUiNav_default),goBack,`back,menu`]])}},LiverySettingsMain_default=__plugin_vue_export_helper_default(_sfc_main$75,[[`__scopeId`,`data-v-ad4291e2`]]),routes_default$8=[{path:`/livery-editor`,name:`LiveryEditor`,component:LiveryEditor_default},{path:`/livery-main`,name:`LiveryMain`,component:LiveryMainNew_default},{path:`/livery-paint`,name:`LiveryPaint`,component:LiveryPaintMain_default},{path:`/livery-decals`,name:`LiveryDecals`,component:LiveryDecalsMain_default},{path:`/livery-settings`,name:`LiverySettings`,component:LiverySettingsMain_default},{path:`/livery-camera-settings`,name:`LiveryCameraSettings`,component:LiveryCameraSettings_default},{path:`/livery-decal-selector`,name:`LiveryDecalSelector`,component:LiveryDecalSelector_default},{path:`/livery-layer-edit`,name:`LiveryLayerEdit`,component:LiveryLayerEdit_default},{path:`/layer-transform`,name:`LayerTransform`,component:LayerTransform_default},{path:`/layer-materials`,name:`LayerMaterials`,component:LayerMaterials_default},{path:`/layer-projection`,name:`LayerProjection`,component:LayerProjection_default},{path:`/livery-manager`,name:`LiveryManager`,component:LiveryManager_default}],_hoisted_1$66={class:`logo-wrapper`},_sfc_main$74={__name:`Logo`,setup(__props){let logos={beamng:getAssetURL(`images/logos.svg#bng-beamng`),tech:getAssetURL(`images/logos.svg#bng-tech`),drive:getAssetURL(`images/logos.svg#bng-drive`),research:getAssetURL(`images/logos.svg#bng-research`)},productLogo=ref(logos.drive);return onMounted(async()=>{if(await Lua_default.extensions.tech_license.isValid())productLogo.value=logos.tech;else if(window.beamng){let name=window.beamng.product.replace(`BeamNG.`,``);name in logos&&(productLogo.value=logos[name])}else productLogo.value=logos.drive}),(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$66,[createBaseVNode(`div`,{class:`logo`,style:normalizeStyle({"--logo":`url('${productLogo.value}')`})},null,4)]))}},Logo_default=__plugin_vue_export_helper_default(_sfc_main$74,[[`__scopeId`,`data-v-69adfd8c`]]),_hoisted_1$65={class:`main-view`},_hoisted_2$54={class:`dev-info-content`},_hoisted_3$46={class:`dev-info-text`},_hoisted_4$34={class:`mainmenu-title`},_hoisted_5$29={key:1,class:`bottom-buttons`},_hoisted_6$23={class:`btn-content`},_hoisted_7$21={class:`label`},_hoisted_8$16={key:0,class:`small`},_hoisted_9$14={class:`btn-content`},_hoisted_10$10={class:`label`},_hoisted_11$8={key:0,class:`small`},_hoisted_12$6={class:`btn-content`},_hoisted_13$6={class:`label`},_hoisted_14$6={class:`btn-content`},_hoisted_15$6={class:`label`},_hoisted_16$6={class:`btn-content`},_hoisted_17$5={class:`label`},_sfc_main$73={__name:`MainMenu`,setup(__props){let events$3=useEvents(),infoBar=useInfoBar();useUINavScope(`mainmenuUI`);let withAngular=computed(()=>!sysInfo_default.mainMenuBackgroundRequired.value),firstTime=ref(sysInfo_default.mainMenuFirstTime.value),bgRequired=sysInfo_default.mainMenuBackgroundRequired,parentImageCarousel=inject(`mainBackground`),modCounts$1=sysInfo_default.modCounts,devEnv=reactive({env:window.beamng&&!window.beamng.shipping,vue:!1,simplemenu:window.beamng&&window.beamng.simplemenu,videoApi:null,UIEngine:null}),quickLoadLevel=()=>Lua_default.core_levels.startLevel(`/levels/smallgrid/main.level.json`),addons=ref({}),addButton=({translateid,icon,targetState,title,iconId,action})=>{let newButton;newButton=translateid||icon||targetState?{title:$translate.instant(translateid),icon,action:targetState}:{title,iconId,action},addons.value[newButton.title]=newButton},viewName=ref(),changeView=name=>{viewName.value=name,router_default.push(`/menu.mainmenu`+(name?`/`+name:``))};watch(()=>viewName.value,val=>{val&&infoBar.flashHints(`back`),parentImageCarousel.value&&nextTick(parentImageCarousel.value.carousel.showNext)});let route=useRoute();watch(()=>route.name,name=>{if(typeof name!=`string`){viewName.value=null;return}name.startsWith(`menu.mainmenu`)&&(viewName.value=name===`menu.mainmenu`?null:name.slice(14))},{immediate:!0});let navigate$1=(...state)=>window.bngVue.gotoGameState(...state);function quitGame(){Lua_default.quit(),runRaw(`TorqueScript.eval('quit();')`,!1)}let handleBack=event=>{event.detail.force||(viewName.value?(viewName.value=null,changeView(null)):(event.detail.name===`back`||event.detail.name===`menu`)&&window.globalAngularRootScope?.$broadcast(`MenuToggle`))},canDeactivateScope=()=>!viewName.value,canBubbleEvent=event=>{if(event.detail.value!==1)return!1;let eventName=event.detail.name;return eventName===`tab_l`||eventName===`tab_r`?!viewName.value:!1};function displayToast(type,title,titleContext,msg,messageContext){let msgTxt=$translate.contextTranslate({txt:msg,context:messageContext}),titleTxt=$translate.contextTranslate({txt:title,context:titleContext}),msgHtml=window.angularParseBBCode(msgTxt),titleHtml=window.angularParseBBCode(titleTxt);window.globalAngularRootScope.$broadcast(`toastrMsg`,{type,msg:msgHtml,title:titleHtml,config:{positionClass:`toast-top-right`,timeOut:0,extendedTimeOut:0,onTap(){window.bngVue.gotoGameState(`menu.options.performance`)}}})}async function checkHardware(){Lua_default.checkFSErrors();let info=await Lua_default.core_hardwareinfo.getInfo();if(info.globalState!==`ok`){for(let key in info)if(!(!info[key].warnings||!Array.isArray(info[key].warnings)))for(let warning of info[key].warnings)warning.ack||displayToast(info.globalState===`warn`?`warning`:`error`,`ui.performance.warnings.`+warning.msg,warning.context,`ui.mainmenu.warningdetails`,null)}}let repoEnabled=ref(!1),modsAfterUpdate=ref(!1),onSettingsChanged=data=>{modsAfterUpdate.value=data.values.disableModsAfterUpdate,repoEnabled.value=data.values.onlineFeatures===`enable`&&!data.values.disableModsAfterUpdate};return onMounted(async()=>{function advertMainMenu(){events$3.emit(`MainMenuButtons`,addButton),window.globalAngularRootScope.$broadcast(`MainMenuButtons`,addButton)}advertMainMenu(),events$3.on(`UiModsChanged`,advertMainMenu),events$3.on(`BroadcastMainMenuButtons`,advertMainMenu),events$3.on(`SettingsChanged`,onSettingsChanged),Lua_default.settings.notifyUI(),devEnv.env&&(devEnv.videoApi=await Lua_default.Engine.Render.getAdapterType(),devEnv.UIEngine=await Lua_default.Engine.UI.getUIEngine()),sysInfo_default.mainMenuFirstTime.value&&checkHardware();let settings$1=await useSettingsAsync();await Lua_default.extensions.tech_license.isValid()||(settings$1.values.onlineFeatures===`ask`||settings$1.values.telemetry===`ask`?window.bngVue.gotoGameState(`menu.onlineFeatures`):Lua_default.settings.getValue(`showedInputLayoutPopupV37`).then(value=>{value===!1&&window.bngVue.gotoGameState(`buttonLayout`)})),sysInfo_default.mainMenuFirstTime.value=!1}),onUnmounted(()=>{events$3.off(`SettingsChanged`,onSettingsChanged)}),(_ctx,_cache)=>{let _component_router_view=resolveComponent(`router-view`);return withDirectives((openBlock(),createElementBlock(`div`,{class:normalizeClass({"mainmenu-container":!0,"mainmenu-with-angular":withAngular.value,"mainmenu-fadein":firstTime.value&&!withAngular.value}),onDeactivate:handleBack},[withDirectives((openBlock(),createElementBlock(`div`,_hoisted_1$65,[devEnv.env?(openBlock(),createBlock(unref(bngCard_default),{key:0,class:`dev-info`},{default:withCtx(()=>[createVNode(unref(bngCardHeading_default),{type:`ribbon`},{default:withCtx(()=>[..._cache[5]||=[createTextVNode(`Developer Release`,-1)]]),_:1}),createBaseVNode(`div`,_hoisted_2$54,[withDirectives(createVNode(unref(bngIcon_default),{class:`dev-info-icon`,type:unref(icons).bug,"bng-all-clicks-no-nav":``},null,8,[`type`]),[[unref(BngDoubleClick_default),quickLoadLevel]]),createBaseVNode(`div`,_hoisted_3$46,[createBaseVNode(`div`,null,` Graphics API: `+toDisplayString(devEnv.videoApi||`requesting...`),1),createBaseVNode(`div`,null,` UI Engine: `+toDisplayString(devEnv.UIEngine||`requesting...`),1)])])]),_:1})):createCommentVNode(``,!0),createBaseVNode(`div`,_hoisted_4$34,[createVNode(Logo_default)]),createVNode(_component_router_view,{"first-time":firstTime.value&&!withAngular.value,addons:addons.value,onChangeView:changeView},null,8,[`first-time`,`addons`]),viewName.value?createCommentVNode(``,!0):(openBlock(),createElementBlock(`div`,_hoisted_5$29,[repoEnabled.value?withDirectives((openBlock(),createBlock(unref(bngButton_default),{key:0,class:`btn-mods`,accent:unref(ACCENTS).text,onClick:_cache[0]||=$event=>navigate$1(`menu.mods.repository`)},{default:withCtx(()=>[unref(bgRequired)?(openBlock(),createBlock(BlurBackground_default,{key:0})):createCommentVNode(``,!0),createBaseVNode(`div`,_hoisted_6$23,[createBaseVNode(`span`,_hoisted_7$21,toDisplayString(_ctx.$tt(`ui.mainmenu.repo`)),1),unref(modCounts$1).total>0?(openBlock(),createElementBlock(`span`,_hoisted_8$16,`\xA0(`+toDisplayString(unref(modCounts$1).active)+` / `+toDisplayString(unref(modCounts$1).total)+`)`,1)):createCommentVNode(``,!0)])]),_:1},8,[`accent`])),[[unref(BngBlur_default),!unref(bgRequired)],[unref(BngSoundClass_default),`bng_click_hover_generic`]]):withDirectives((openBlock(),createBlock(unref(bngButton_default),{key:1,class:normalizeClass([`btn-mods`,{"mods-after-update":modsAfterUpdate.value}]),accent:unref(ACCENTS).text,onClick:_cache[1]||=$event=>navigate$1(`menu.mods.local`)},{default:withCtx(()=>[unref(bgRequired)?(openBlock(),createBlock(BlurBackground_default,{key:0})):createCommentVNode(``,!0),createBaseVNode(`div`,_hoisted_9$14,[createBaseVNode(`span`,_hoisted_10$10,[modsAfterUpdate.value?(openBlock(),createBlock(unref(bngIcon_default),{key:0,type:`danger`,style:{"font-size":`1.1em`},color:`#ff2d00`})):createCommentVNode(``,!0),createTextVNode(toDisplayString(_ctx.$tt(`ui.mainmenu.mods`)),1)]),unref(modCounts$1).total>0?(openBlock(),createElementBlock(`span`,_hoisted_11$8,`\xA0(`+toDisplayString(unref(modCounts$1).active)+` / `+toDisplayString(unref(modCounts$1).total)+`)`,1)):createCommentVNode(``,!0)])]),_:1},8,[`class`,`accent`])),[[unref(BngBlur_default),!unref(bgRequired)],[unref(BngSoundClass_default),`bng_click_hover_generic`]]),withDirectives((openBlock(),createBlock(unref(bngButton_default),{accent:unref(ACCENTS).text,onClick:_cache[2]||=$event=>navigate$1(`credits`)},{default:withCtx(()=>[unref(bgRequired)?(openBlock(),createBlock(BlurBackground_default,{key:0})):createCommentVNode(``,!0),createBaseVNode(`div`,_hoisted_12$6,[createBaseVNode(`span`,_hoisted_13$6,toDisplayString(_ctx.$tt(`ui.mainmenu.credits`)),1)])]),_:1},8,[`accent`])),[[unref(BngBlur_default),!unref(bgRequired)],[unref(BngSoundClass_default),`bng_click_hover_generic`]]),withDirectives((openBlock(),createBlock(unref(bngButton_default),{accent:unref(ACCENTS).text,onClick:_cache[3]||=$event=>navigate$1(`menu.options.display`)},{default:withCtx(()=>[unref(bgRequired)?(openBlock(),createBlock(BlurBackground_default,{key:0})):createCommentVNode(``,!0),createBaseVNode(`div`,_hoisted_14$6,[createBaseVNode(`span`,_hoisted_15$6,toDisplayString(_ctx.$tt(`ui.mainmenu.options`)),1)])]),_:1},8,[`accent`])),[[unref(BngBlur_default),!unref(bgRequired)],[unref(BngSoundClass_default),`bng_click_hover_generic`]]),devEnv.simplemenu?createCommentVNode(``,!0):withDirectives((openBlock(),createBlock(unref(bngButton_default),{key:2,class:`btn-quit`,accent:unref(ACCENTS).attention,icon:unref(icons).exit,onClick:_cache[4]||=$event=>quitGame()},{default:withCtx(()=>[unref(bgRequired)?(openBlock(),createBlock(BlurBackground_default,{key:0})):createCommentVNode(``,!0),createBaseVNode(`div`,_hoisted_16$6,[createBaseVNode(`span`,_hoisted_17$5,toDisplayString(_ctx.$tt(`ui.inputActions.general.quit.title`)),1)])]),_:1},8,[`accent`,`icon`])),[[unref(BngBlur_default),!unref(bgRequired)],[unref(BngSoundClass_default),`bng_click_hover_generic`]])]))])),[[unref(BngOnUiNav_default),handleBack,`back`]])],34)),[[unref(BngScopedNav_default),{activateOnMount:!0,canDeactivate:canDeactivateScope,canBubbleEvent}],[unref(BngOnUiNav_default),handleBack,`menu`]])}}},MainMenu_default=__plugin_vue_export_helper_default(_sfc_main$73,[[`__scopeId`,`data-v-1c7a0195`]]),_hoisted_1$64={key:1,class:`fancy-bg-wrap`},_hoisted_2$53={class:`mask-container`},_hoisted_3$45={key:0,class:`icon-text`},_hoisted_4$33={key:2,class:`tag`},_hoisted_5$28={key:3,class:`icon`},_hoisted_6$22={key:4,class:`icon`},_hoisted_7$20={key:5,class:`label-container`},_hoisted_8$15={class:`text`},_hoisted_9$13={key:6,class:`text`},_sfc_main$72={__name:`MenuButton`,props:{size:{type:String,default:`normal`},iconId:String,icon:String,highlighted:Boolean,disabled:Boolean,appearDisabled:Boolean,bgImg:String,bgImgAbs:String,tag:String,noBlur:Boolean},setup(__props,{expose:__expose}){let props=__props,btnRef=ref(null);__expose({getElement(){return btnRef.value}});let bgImgUrl=computed(()=>props.bgImgAbs?props.bgImgAbs:getAssetURL(props.bgImg)),hasBgImg=computed(()=>props.bgImgAbs||props.bgImg);return(_ctx,_cache)=>withDirectives((openBlock(),createElementBlock(`div`,{ref_key:`btnRef`,ref:btnRef,class:normalizeClass({"mainmenu-button":!0,[`size-${__props.size}`]:!0,"fancy-bg":!!hasBgImg.value,"with-icon":!!__props.iconId,"semi-disabled":__props.appearDisabled}),style:normalizeStyle({"--fancy-bg-img":`url('${bgImgUrl.value}')`}),"bng-nav-item":``},[__props.noBlur?createCommentVNode(``,!0):(openBlock(),createBlock(BlurBackground_default,{key:0,class:normalizeClass(`corners-${__props.size}`)},null,8,[`class`])),createBaseVNode(`div`,{class:normalizeClass([`button-background`,{stack:__props.size===`big-stacked`,highlighted:__props.highlighted}])},null,2),hasBgImg.value?(openBlock(),createElementBlock(`div`,_hoisted_1$64,[createBaseVNode(`div`,{class:normalizeClass([`bg-container`,{"with-icon":!!__props.iconId}])},[_cache[0]||=createBaseVNode(`div`,{class:`bg-image`},null,-1),createBaseVNode(`div`,_hoisted_2$53,[__props.iconId?(openBlock(),createElementBlock(`div`,_hoisted_3$45,toDisplayString(unref(icons)[__props.iconId].glyph),1)):createCommentVNode(``,!0)])],2)])):createCommentVNode(``,!0),__props.tag?(openBlock(),createElementBlock(`div`,_hoisted_4$33,toDisplayString(__props.tag),1)):createCommentVNode(``,!0),__props.iconId&&!hasBgImg.value?(openBlock(),createElementBlock(`div`,_hoisted_5$28,[createVNode(unref(bngIcon_default),{type:unref(icons)[__props.iconId],color:hasBgImg.value?`transparent`:void 0},null,8,[`type`,`color`])])):__props.icon?(openBlock(),createElementBlock(`div`,_hoisted_6$22,[createVNode(unref(bngImageAsset_default),{externalSrc:__props.icon},null,8,[`externalSrc`])])):createCommentVNode(``,!0),__props.size==`big`||__props.size==`big-stacked`?(openBlock(),createElementBlock(`div`,_hoisted_7$20,[createBaseVNode(`span`,_hoisted_8$15,[renderSlot(_ctx.$slots,`default`,{},void 0,!0)])])):(openBlock(),createElementBlock(`span`,_hoisted_9$13,[renderSlot(_ctx.$slots,`default`,{},void 0,!0)]))],6)),[[unref(BngSoundClass_default),!(__props.disabled||__props.appearDisabled)&&`bng_click_hover_generic`],[unref(BngDisabled_default),__props.disabled],[unref(BngBlur_default),!__props.noBlur]])}},MenuButton_default=__plugin_vue_export_helper_default(_sfc_main$72,[[`__scopeId`,`data-v-932e6a9a`]]),_hoisted_1$63={class:`center-wrap`},_hoisted_2$52={class:`primary`},IMG_PATH=`images/mainmenu/`,_sfc_main$71={__name:`MainView`,props:{firstTime:Boolean},emits:[`changeView`],setup(__props,{emit:__emit}){let props=__props,emit$1=__emit;ref(null);let settings$1=useSettings(),defaultWizardStep=computed(()=>settings$1.getValue(`freeroamSetupDefaultStep`)||`level`),firstTime=ref(props.firstTime);onMounted(()=>{firstTime.value&&setTimeout(()=>firstTime.value=!1,1500)});let navigate$1=(state,params=void 0)=>nextTick(()=>window.bngVue.gotoGameState(state,{params}));async function careerPrompt(){await openExperimental($translate.instant(`ui.career.experimentalTitle`),$translate.instant(`ui.career.experimentalPrompt`),[{label:$translate.instant(`ui.common.no`),value:!1,isCancel:!0,extras:{accent:ACCENTS.secondary}},{label:$translate.instant(`ui.career.experimentalAgree`),value:!0,default:!0}])&&navigate$1(`profiles`)}return(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$63,[createBaseVNode(`div`,_hoisted_2$52,[createVNode(MenuButton_default,{"bng-scoped-nav-autofocus":``,size:`big`,"icon-id":`keys1`,"bg-img":IMG_PATH+`experiences.jpg`,onClick:_cache[0]||=$event=>emit$1(`changeView`,`discover`),tag:_ctx.$t(`ui.playmodes.new`)},{default:withCtx(()=>[createTextVNode(toDisplayString(_ctx.$tt(`ui.playmodes.quickStartExperiences`)),1)]),_:1},8,[`bg-img`,`tag`]),createVNode(MenuButton_default,{size:`big`,"icon-id":`road`,"bg-img":IMG_PATH+`freeroam.jpg`,onClick:_cache[1]||=$event=>navigate$1(`menu.freeroamWizard`,{step:defaultWizardStep.value})},{default:withCtx(()=>[createTextVNode(toDisplayString(_ctx.$tt(`ui.playmodes.freeroam`)),1)]),_:1},8,[`bg-img`]),_ctx.$simplemenu.value?createCommentVNode(``,!0):(openBlock(),createBlock(MenuButton_default,{key:0,"appear-disabled":``,size:`big`,"icon-id":`cup`,"bg-img":IMG_PATH+`career.jpg`,onClick:_cache[2]||=$event=>careerPrompt(),tag:_ctx.$t(`ui.playmodes.comingSoon`),"tag-orange":``},{default:withCtx(()=>[createTextVNode(toDisplayString(_ctx.$tt(`ui.playmodes.career`)),1)]),_:1},8,[`bg-img`,`tag`])),createVNode(MenuButton_default,{size:`big-stacked`,"icon-id":`BNGFolder`,"bg-img":IMG_PATH+`others.jpg`,onClick:_cache[3]||=$event=>emit$1(`changeView`,`others`)},{default:withCtx(()=>[createTextVNode(toDisplayString(_ctx.$tt(`ui.mainmenu.more`)),1)]),_:1},8,[`bg-img`])])]))}},MainView_default=__plugin_vue_export_helper_default(_sfc_main$71,[[`__scopeId`,`data-v-0baa6516`]]),_hoisted_1$62={class:`center-wrap`},_hoisted_2$51={class:`others`},_hoisted_3$44={class:`buttons`},htmlBody=`
        if core_camera then core_camera.requestConfig() end    -- cameraConfig
      `);async function init$3(){for(let key in active=!0,(window.beamng&&!window.beamng.shipping||editor)&&(watchers$1.push(watch(()=>settingsValues.value,updateSettingsList)),watchers$1.push(watch(()=>layout.value,async()=>{await settings$1.waitForData(),updateSettingsList()}))),events$3.on(`SettingsChanged`,()=>settingsTimestamp.value=Date.now()),watchers$1.push(watch(customValues,()=>settingsTimestamp.value=Date.now(),{deep:!0})),events$3.on(`externalUIURL`,data=>customValues.externalUIURL=data||``),events$3.on(`OpenXRStateChanged`,data=>customValues.openXRstate=data),events$3.on(`CameraConfigChanged`,data=>{customValues.cameraConfigList=Array.isArray(data.cameraConfig)?data.cameraConfig:[],customValues.cameraConfigFocused=data.focusedCamName}),updateCustom(),await settings$1.waitForData(),settings$1.values)initialValues[key]=settings$1.values[key];settingsTimestamp.value=Date.now(),setupSearch(layout,settingsValues,settingsOptions,settingsTimestamp,conditions)}let settingsValues=computed(()=>{if(!active||!settings$1.values)return{};let res={...settings$1.values};for(let key in valueFormatters)res[key]=valueFormatters[key](res[key],settings$1.values,customValues);for(let key in valueExtensions)res[key]=valueExtensions[key](settings$1.values,customValues);return res}),settingsOptions=computed(()=>{let res={};if(!active||!settings$1.options||!settings$1.values)return res;for(let key in settings$1.options)key in optionFormatters?res[key]=optionFormatters[key](settings$1.options[key],settings$1.options,settings$1.values):res[key]=guessOptionFormat(settings$1.options[key]);for(let key in optionExtensions)res[key]=optionExtensions[key](settings$1.options,settings$1.values);return res}),editor=null,layout=ref(layout_default);function updateSettingsList(){if(!active)return;settingsList.value=Object.keys(settingsValues.value).reduce((res,name)=>({...res,[name]:{assigned:!1,assignedIn:[],value:settingsValues.value[name],options:settingsOptions.value[name],elementId:name.split(`.`)}}),{});function dive(items$2,cat,catIndex,level$1=0,parentId=``){for(let i=0;i{let values=name in applyValueFormatters?applyValueFormatters[name](value):{[name]:value};for(let key in name.startsWith(`debug_`)&&(customValues.debug[name.substring(6)]=value,name===`debug_visualization`&&(customValues.debug.visualization_prev&&api$1.engineLua(customValues.debug.visualization_prev),customValues.debug.visualization_prev=value,api$1.engineLua(value))),values)key in settings$1.values||delete values[key];Object.keys(values).length>0&&(logger_default.debug(`Applying:`,JSON.stringify(values)),settings$1.apply(values),updateCustom())};function dispose$2(){active=!1,settingsList.value={};for(let unwatch of watchers$1)unwatch();watchers$1.splice(0),settingsTimestamp.value=0,disposeSearch(),null?.dispose()}return provide(`settingsValues`,settingsValues),provide(`settingsOptions`,settingsOptions),provide(`settingsTimestamp`,settingsTimestamp),provide(`settingsList`,settingsList),provide(`conditions`,conditions),provide(`buildItemId`,buildItemId),{init:init$3,dispose:dispose$2,versions:VERSIONS,version:VERSIONS[0],settings:settings$1,settingsList,settingsValues,settingsOptions,settingsTimestamp,applySetting,buildItemId,layout,conditions,editable:!1,editor:null,searchText,searchResults,searchTemplates:{message:(...args)=>searchTemplates.message(layout,...args),headers:(...args)=>searchTemplates.headers(layout,...args),group:(...args)=>searchTemplates.group(layout,...args)}}}var _hoisted_1$19={class:`options-wrapper`,"bng-ui-scope":`options`},_hoisted_2$13={class:`options-heading`},_hoisted_3$12={key:0,class:`options-container`},_hoisted_4$9={class:`background`},_hoisted_5$8={class:`options-content-wrapper`},_hoisted_6$5={class:`options-message`},_hoisted_7$5={class:`message-content`},_hoisted_8$3={key:1,class:`options-categories`},_hoisted_9$2={key:0,class:`categories-divider`},_hoisted_10$1={key:2,class:`options-container`},_hoisted_11$1={class:`options-subcategories`},_hoisted_12$1={class:`background`},_hoisted_13$1={key:0,class:`categories-divider`},_hoisted_14$1={key:1,class:`categories-spacer`},_hoisted_15$1={key:0,class:`categories-spacer`},_hoisted_16$1={key:1,class:`categories-divider`},_hoisted_17$1={class:`options-content-wrapper`},_hoisted_18$1={key:0,class:`options-add-item`},_hoisted_19$1={key:1,class:`options-content`,"bng-ui-scope":`options-content`},_hoisted_20$1={key:2,class:`options-content`,"bng-ui-scope":`options-content`},_hoisted_21$1={class:`background`},_hoisted_22$1=[`innerHTML`],_hoisted_23$1={key:0,class:`options-info-fps`},_sfc_main$23={__name:`OptionsView`,props:{category:String},setup(__props){useUINavScope(`options`);let router$1=useRouter(),route=useRoute(),{api:api$1}=useBridge(),options=useOptions(),loaded=ref(!1),itemsContainer=ref(null),activeScope=ref(``),props=__props;provide(`version`,options.version);let EditUI=ref(null),itemEdit=(...args)=>EditUI.value?.functions.itemEdit?.(...args),categoryEdit=(...args)=>EditUI.value?.functions.categoryEdit?.(...args),catItemsPaste=(...args)=>EditUI.value?.functions.catItemsPaste?.(...args);provide(`EditUI`,EditUI);let editable=ref(!1);provide(`editable`,editable);let categories=computed(()=>options.layout.value.items||[]),categoryIds=computed(()=>categories.value.map(cat=>cat.categoryId)),categoryIndex=ref(-1);provide(`categoryIndex`,categoryIndex);let allCategories=computed(()=>{let cats=[...categories.value].map(cat=>({...cat})),startIndex=0;for(let i=0;istartIndex&&(cats[ri].subcategoryMode=hadSpacer?`none`:ri===i?`last`:ri===startIndex+1?`first`:`middle`)}}else startIndex=i,cat.indexRange=[i,i]}let hidden=[];for(let cat of cats)if(!(!cat.condition_visible||cat.condition_visible in options.conditions&&options.conditions[cat.condition_visible](options.settingsValues.value)))if(cat.subcategory)hidden.push(cat.categoryIndex);else for(let i=cat.indexRange[0];i<=cat.indexRange[1];i++)hidden.push(i);return options.editable?cats.map(cat=>(cat.hiddenByCondition=hidden.includes(cat.categoryIndex),cat.debugSettings=cat.condition_visible===`__notForShipping`,cat)):hidden.length>0?cats.filter(cat=>!hidden.includes(cat.categoryIndex)):cats}),categoriesView=computed(()=>allCategories.value.filter(cat=>!cat.subcategory&&!cat.persistent&&!cat.spacer)),categoryRange=computed(()=>categoriesView.value.find(cat=>categoryIndex.value>=cat.indexRange[0]&&categoryIndex.value<=cat.indexRange[1])?.indexRange||[categoryIndex.value,categoryIndex.value]),subcategoriesView=computed(()=>{let res=categoryIndex.value===-1?[]:allCategories.value.filter(cat=>!cat.persistent&&cat.categoryIndex>=categoryRange.value[0]&&cat.categoryIndex<=categoryRange.value[1]);return res.length>0&&(res[0]={...res[0],label:`ui.options.general`}),res}),persistentView=computed(()=>allCategories.value.filter(cat=>cat.persistent)),itemsNew=ref([]),itemsNewShow=ref(!1),itemsNewView=computed(()=>itemsNewShow.value?itemsNew.value:[]);options.editor&&watch(options.layout,()=>itemsNew.value.splice(0));function renderNewOptions(doRender=!0){if(itemsNewShow.value=doRender,!doRender||itemsNew.value.length>0)return;function dive(parent){if(parent.version!==options.version)for(let i=parent.items.length-1;i>=0;i--){let item=parent.items[i];item.items&&(item.items.length>0&&dive(item),item.items.length>0)||item.version!==options.version&&parent.items.splice(i,1)}}let layout=JSON.parse(JSON.stringify(options.layout.value.items));for(let i=layout.length-1;i>=0;i--){let cat=layout[i];dive(cat),cat.items.length>0&&itemsNew.value.push(options.searchTemplates.group(cat.label,cat.icon,cat.items))}}provide(`renderNewOptions`,renderNewOptions);let itemsView=computed(()=>[...categoryIndex.value>-1&&categoryIndex.value{renderNewOptions(!1),categoryIndex.value>-1&&(special.value=null,searchActive.value=!1,options.searchText.value=``),itemsContainer.value&&itemsContainer.value.scrollTo({top:0,behavior:`instant`})}),watch(special,()=>{special.value&&(categoryIndex.value=-1,searchActive.value=!1,options.searchText.value=``)});let searchActive=ref(!1),searchFocused=ref(!1);watch(searchFocused,focused$1=>{focused$1?(searchActive.value=!0,categoryIndex.value=-1,special.value=null):options.searchText.value.length===0&&(searchActive.value=!1,categoryIndex.value=0)});let elCategories=ref(null),elSearch=ref(null),elSearchBinding=ref(null);watch(()=>elSearch.value?.scopeActivated,active=>{activeScope.value=active?``:`content`});function toSearchAndBack(){elSearch.value&&(elSearch.value.scopeActivated=!elSearch.value.scopeActivated)}function fromContent(){searchActive.value?elSearch.value.scopeActivated=!0:activeScope.value=`subcategories`}function mainCatNav(evt){!elCategories.value||!evt.detail||(options.searchText.value=``,elSearch.value.scopeActivated=!1,searchActive.value=!1,activeScope.value=`subcategories`,evt.detail.name===`tab_l`?elCategories.value.activatePrev():evt.detail.name===`tab_r`&&elCategories.value.activateNext(),evt.stopPropagation())}function catNavigate(cat){cat.reroute?window.bngVue.gotoAngularState(cat.reroute):categoryIndex.value!==cat.categoryIndex&&(categoryIndex.value=cat.categoryIndex)}provide(`goToSetting`,(catIndex,itemId)=>{categoryIndex.value=catIndex,nextTick(()=>{let elm=document.getElementById(itemId);elm?(elm.scrollIntoView({behavior:`smooth`,block:`center`}),elm.classList.add(`options-setting-highlight`),setTimeout(()=>elm?.classList.remove(`options-setting-highlight`),5e3)):logger_default.warn(`Setting item not found: ${itemId}`)})});function onChange(data,value){options.applySetting(data.setting,value);let lua;switch(data.itemType){case`checkbox`:value===!0||value===`enable`?lua=data.lua:(value===!1||value===`disable`)&&(lua=data.luaOff);break;default:lua=data.lua}lua&&runLua(lua,value)}function onClick(data){data.lua&&runLua(data.lua)}function runLua(code,value=void 0){code.toLowerCase().includes(`%value%`)&&value!==void 0&&(code=code.replace(/%value%/gi,api$1.serializeToLua(value))),code.toLowerCase().includes(`%values%`)&&(code=code.replace(/%values%/gi,api$1.serializeToLua(options.settings.values)));let isLua=!code.startsWith(`$`);logger_default.log(`Running ${isLua?`lua`:`script`}: ${code}`),isLua?api$1.engineLua(code):api$1.engineScript(code)}function updateRoute(){if(!loaded.value||route.path!==`/options`&&!route.path.startsWith(`/options/`))return;let newRoute={name:`options`};categoryIndex.value>-1&&categoryIndex.valuecategoryIndex.value,(index,oldIndex)=>{index>-1?(special.value=null,updateRoute(),options.editor?.clearSelection(),showCategoryInfo(index,categories.value[index]?.categoryInfo),showCategoryInfo(oldIndex)):showCategoryInfo(oldIndex)}),watch(()=>special.value,val=>{val&&(categoryIndex.value=-1,updateRoute())});function selectDefaultCategory(){if(categories.value.length===0)return!1;if(props.category){let catIndex=categoryIds.value.indexOf(props.category);catIndex>-1?categoryIndex.value=catIndex:special.value=props.category}else categoryIndex.value=0;return!0}let elInfo=ref(),infos=new Map,infoHidden=ref(!1),infoView=ref([]);function showInfo(id,text=void 0){if(infos.has(id))if(text){if(infos.get(id)===text)return}else infos.delete(id);else if(!text)return;text&&infos.set(id,text),infos.size===0?infoView.value=[]:infoView.value=Array.from(infos.entries()).sort((a$1,b)=>a$1[0]-b[0]).map(tip=>({id:tip[0],text:tip[1]}))}function onResize(){elInfo.value&&(infoHidden.value=window.getComputedStyle(elInfo.value).display===`none`)}let unwatchResize=watch(elInfo,()=>{elInfo.value&&(unwatchResize(),onResize())});provide(`showInfo`,showInfo),provide(`infoHidden`,infoHidden);let fps=ref(`?`),fpsShown=ref(!1),fpsTimer;function showFps(show=!0){if(fpsShown.value=show,fpsTimer)show||(clearInterval(fpsTimer),fps.value=`?`,fpsTimer=null);else if(show){let fpsUpdate=()=>{infoHidden.value||api$1.engineLua(`getConsoleVariable("fps::avg")`,val=>fps.value=val?Number(val).toFixed(1):`?`)};fpsTimer=setInterval(fpsUpdate,500),fpsUpdate()}}let catInfoFuncs={fps:showFps},catInfoStack=new Map;function showCategoryInfo(id,info=void 0){if(!id)return;catInfoStack.has(id)&&!info?catInfoStack.delete(id):info&&catInfoStack.set(id,info);let infos$1=Array.from(catInfoStack.values()).reduce((res,name)=>res.includes(name)?res:[...res,name],[]);for(let[name,func]of Object.entries(catInfoFuncs))func(infos$1.includes(name))}function disposeCategoryInfo(){for(let func of Object.values(catInfoFuncs))func(!1)}function back(){editable.value?editable.value=!1:window.bngVue.gotoAngularState(`menu.mainmenu`)}return onBeforeMount(async()=>{api$1.engineLua(`if getCurrentLevelIdentifier() then simTimeAuthority.pushPauseRequest('options') end`)}),onMounted(()=>{if(options.init().then(()=>{loaded.value=!0,nextTick(()=>activeScope.value=`subcategories`)}),!selectDefaultCategory()){let unwatchCats=watch(categories,()=>selectDefaultCategory()&&unwatchCats())}window.addEventListener(`resize`,onResize)}),onUnmounted(()=>{options.searchText.value=``,window.removeEventListener(`resize`,onResize),disposeCategoryInfo(),options.dispose(),api$1.engineLua(`if getCurrentLevelIdentifier() then simTimeAuthority.popPauseRequest('options') end`)}),(_ctx,_cache)=>withDirectives((openBlock(),createElementBlock(`div`,_hoisted_1$19,[createBaseVNode(`div`,_hoisted_2$13,[createVNode(unref(bngScreenHeading_default),null,{default:withCtx(()=>[createTextVNode(toDisplayString(_ctx.$tt(`ui.options.options`)),1)]),_:1}),unref(options).editor&&EditUI.value?(openBlock(),createBlock(resolveDynamicComponent(EditUI.value.default),{key:0,options:unref(options),categories:categories.value,"category-index":categoryIndex.value,"onUpdate:categoryIndex":_cache[0]||=$event=>categoryIndex.value=$event,special:special.value,"onUpdate:special":_cache[1]||=$event=>special.value=$event,editable:editable.value,"onUpdate:editable":_cache[2]||=$event=>editable.value=$event},null,40,[`options`,`categories`,`category-index`,`special`,`editable`])):createCommentVNode(``,!0)]),loaded.value?createCommentVNode(``,!0):(openBlock(),createElementBlock(`div`,_hoisted_3$12,[createVNode(BlurBackground_default),withDirectives(createBaseVNode(`div`,_hoisted_4$9,null,512),[[unref(BngBlur_default)]]),createBaseVNode(`div`,_hoisted_5$8,[createBaseVNode(`div`,_hoisted_6$5,[createBaseVNode(`div`,_hoisted_7$5,toDisplayString(_ctx.$t(`ui.repository.loading`)),1)])])])),loaded.value?(openBlock(),createElementBlock(`div`,_hoisted_8$3,[createVNode(unref(bngOverflowContainer_default),{ref_key:`elCategories`,ref:elCategories,class:`categories-container`,"initial-index":0,"use-bindings-only":``},{default:withCtx(()=>[(openBlock(!0),createElementBlock(Fragment,null,renderList(categoriesView.value,cat=>(openBlock(),createElementBlock(Fragment,{key:`cat-`+cat.categoryIndex},[cat.divider?(openBlock(),createElementBlock(`div`,_hoisted_9$2)):(openBlock(),createBlock(CategoryTop_default,{key:1,id:`options-cat-`+cat.categoryIndex,index:cat.categoryIndex,"has-subcategories":cat.hasSubcategories,selected:cat.categoryIndex>=categoryRange.value[0]&&cat.categoryIndex<=categoryRange.value[1],icon:cat.icon,onClick:$event=>catNavigate(cat,!1),"hidden-by-condition":cat.hiddenByCondition,"debug-settings":cat.debugSettings,editable:editable.value,onEditCmd:categoryEdit},{default:withCtx(()=>[createTextVNode(toDisplayString(_ctx.$tt(cat.label)),1)]),_:2},1032,[`id`,`index`,`has-subcategories`,`selected`,`icon`,`onClick`,`hidden-by-condition`,`debug-settings`,`editable`]))],64))),128))]),_:1},512),createBaseVNode(`div`,{class:normalizeClass([`options-search-input`,{"search-active":searchActive.value}])},[createVNode(unref(bngBinding_default),{ref_key:`elSearchBinding`,ref:elSearchBinding,class:`search-binding`,"ui-event":`context`,controller:``},null,512),createVNode(unref(bngInputNew_default),{ref_key:`elSearch`,ref:elSearch,class:`search-input`,modelValue:unref(options).searchText.value,"onUpdate:modelValue":_cache[3]||=$event=>unref(options).searchText.value=$event,modelModifiers:{trim:!0},"leading-icon":elSearchBinding.value?.displayed?null:unref(icons).search,"floating-label":_ctx.$tt(`ui.common.search`),"show-external-button":searchActive.value,onFocus:_cache[4]||=$event=>searchFocused.value=!0,onBlur:_cache[5]||=$event=>searchFocused.value=!1},null,8,[`modelValue`,`leading-icon`,`floating-label`,`show-external-button`])],2)])):createCommentVNode(``,!0),loaded.value?(openBlock(),createElementBlock(`div`,_hoisted_10$1,[withDirectives((openBlock(),createElementBlock(`div`,_hoisted_11$1,[createVNode(BlurBackground_default),withDirectives(createBaseVNode(`div`,_hoisted_12$1,null,512),[[unref(BngBlur_default)]]),(openBlock(!0),createElementBlock(Fragment,null,renderList(subcategoriesView.value,cat=>(openBlock(),createElementBlock(Fragment,{key:`cat-`+cat.categoryIndex},[cat.divider?(openBlock(),createElementBlock(`div`,_hoisted_13$1)):cat.spacer?(openBlock(),createElementBlock(`div`,_hoisted_14$1)):(openBlock(),createBlock(CategorySide_default,{key:2,id:`options-cat-`+cat.categoryIndex,index:cat.categoryIndex,"has-subcategories":cat.hasSubcategories,selected:cat.categoryIndex===categoryIndex.value,subcategory:cat.subcategoryMode,icon:cat.icon,"hidden-by-condition":cat.hiddenByCondition,"debug-settings":cat.debugSettings,onClick:$event=>catNavigate(cat),onFocus:$event=>catNavigate(cat,!1)},{default:withCtx(()=>[createTextVNode(toDisplayString(_ctx.$tt(cat.label)),1)]),_:2},1032,[`id`,`index`,`has-subcategories`,`selected`,`subcategory`,`icon`,`hidden-by-condition`,`debug-settings`,`onClick`,`onFocus`]))],64))),128)),subcategoriesView.value.length===0&&allCategories.value[categoryIndex.value]?.persistent?(openBlock(),createBlock(CategorySide_default,{key:0,icon:allCategories.value[categoryIndex.value].icon,selected:``},{default:withCtx(()=>[createTextVNode(toDisplayString(_ctx.$tt(allCategories.value[categoryIndex.value].label)),1)]),_:1},8,[`icon`])):createCommentVNode(``,!0),searchActive.value?(openBlock(),createBlock(CategorySide_default,{key:1,icon:`search`,selected:``},{default:withCtx(()=>[createTextVNode(toDisplayString(_ctx.$tt(`ui.common.search`)),1)]),_:1})):special.value===`categories-edit`?(openBlock(),createBlock(CategorySide_default,{key:2,icon:`listIndented`,selected:``},{default:withCtx(()=>[..._cache[11]||=[createTextVNode(`Edit categories`,-1)]]),_:1})):createCommentVNode(``,!0),persistentView.value.length>0?(openBlock(),createElementBlock(Fragment,{key:3},[_cache[13]||=createBaseVNode(`div`,{class:`categories-spacer`},null,-1),editable.value&&special.value===`categories-edit`?(openBlock(),createElementBlock(Fragment,{key:0},[(openBlock(!0),createElementBlock(Fragment,null,renderList(persistentView.value,cat=>(openBlock(),createBlock(CategorySide_default,{key:`cat-`+cat.categoryIndex,id:`options-cat-`+cat.categoryIndex,"has-subcategories":cat.hasSubcategories,subcategory:cat.subcategoryMode,icon:cat.icon,index:cat.categoryIndex,"hidden-by-condition":cat.hiddenByCondition,"debug-settings":cat.debugSettings,editable:``,onClick:$event=>categoryEdit(`edit`,cat.categoryIndex),onEditCmd:categoryEdit},{default:withCtx(()=>[createTextVNode(toDisplayString(cat.spacer||cat.divider?`---`:_ctx.$tt(cat.label)),1)]),_:2},1032,[`id`,`has-subcategories`,`subcategory`,`icon`,`index`,`hidden-by-condition`,`debug-settings`,`onClick`]))),128)),createVNode(CategorySide_default,{icon:`plus`,onClick:_cache[6]||=$event=>categoryEdit(`add`,!0),style:normalizeStyle(editable.value?{}:{opacity:0,pointerEvents:`none`})},{default:withCtx(()=>[..._cache[12]||=[createTextVNode(`New category`,-1)]]),_:1},8,[`style`])],64)):(openBlock(!0),createElementBlock(Fragment,{key:1},renderList(persistentView.value,cat=>(openBlock(),createElementBlock(Fragment,{key:`cat-`+cat.categoryIndex},[cat.spacer?(openBlock(),createElementBlock(`div`,_hoisted_15$1)):cat.divider?(openBlock(),createElementBlock(`div`,_hoisted_16$1)):(openBlock(),createBlock(CategorySide_default,{key:2,id:`options-cat-`+cat.categoryIndex,"has-subcategories":cat.hasSubcategories,selected:cat.categoryIndex===categoryIndex.value,subcategory:cat.subcategoryMode,icon:cat.icon,index:cat.categoryIndex,"hidden-by-condition":cat.hiddenByCondition,"debug-settings":cat.debugSettings,onClick:$event=>catNavigate(cat)},{default:withCtx(()=>[createTextVNode(toDisplayString(_ctx.$tt(cat.label)),1)]),_:2},1032,[`id`,`has-subcategories`,`selected`,`subcategory`,`icon`,`index`,`hidden-by-condition`,`debug-settings`,`onClick`]))],64))),128))],64)):createCommentVNode(``,!0)])),[[unref(BngScopedNav_default),{activated:!searchActive.value&&activeScope.value===`subcategories`,bubbleWhitelistEvents:[`context`]}],[unref(BngOnUiNav_default),mainCatNav,`tab_l,tab_r`],[unref(BngOnUiNav_default),back,`back,menu`],[unref(BngOnUiNav_default),()=>activeScope.value=`content`,`ok`,{focusRequired:!0}]]),withDirectives((openBlock(),createElementBlock(`div`,_hoisted_17$1,[createVNode(BlurBackground_default,{class:normalizeClass([`background`,{"background-no-info":infoHidden.value}])},null,8,[`class`]),withDirectives(createBaseVNode(`div`,{class:normalizeClass([`background`,{"background-no-info":infoHidden.value}])},null,2),[[unref(BngBlur_default)]]),categoryIndex.value>-1?withDirectives((openBlock(),createElementBlock(`div`,{key:0,ref_key:`itemsContainer`,ref:itemsContainer,class:`options-content`,"bng-ui-scope":`options-content`},[(openBlock(!0),createElementBlock(Fragment,null,renderList(itemsView.value,(item,index)=>(openBlock(),createBlock(Item_default,{key:`item-`+categoryIndex.value*1e5+`-`+index,parent:categories.value[categoryIndex.value],index,level:0,data:item,onClick,onChange,onEditCmd:itemEdit},null,8,[`parent`,`index`,`data`]))),128)),editable.value?(openBlock(),createElementBlock(`div`,_hoisted_18$1,[createVNode(unref(bngButton_default),{accent:unref(ACCENTS).outlined,icon:unref(icons).plus,onClick:_cache[7]||=$event=>unref(options).editor.itemAdd(categories.value[categoryIndex.value])},{default:withCtx(()=>[..._cache[14]||=[createTextVNode(`Add new item`,-1)]]),_:1},8,[`accent`,`icon`]),createVNode(unref(bngButton_default),{accent:unref(ACCENTS).outlined,icon:unref(icons).addListItem,disabled:!unref(options).editor.clipItems.value.length,onClick:_cache[8]||=$event=>catItemsPaste()},{default:withCtx(()=>[createTextVNode(`Paste `+toDisplayString(unref(options).editor.clipTitle.value),1)]),_:1},8,[`accent`,`icon`,`disabled`]),createVNode(unref(bngButton_default),{accent:unref(ACCENTS).outlined,icon:unref(options).editor.selectedItems.value.size>0?unref(icons).checkboxOn:unref(icons).checkboxOff,onClick:_cache[9]||=$event=>unref(options).editor.itemSelectAll(categories.value[categoryIndex.value])},{default:withCtx(()=>[createTextVNode(toDisplayString(unref(options).editor.selectedItems.value.size>0?`Deselect all`:`Select all`),1)]),_:1},8,[`accent`,`icon`])])):createCommentVNode(``,!0)])),[[unref(BngUiNavScroll_default),void 0,void 0,{force:!0}]]):searchActive.value?withDirectives((openBlock(),createElementBlock(`div`,_hoisted_19$1,[(openBlock(!0),createElementBlock(Fragment,null,renderList(unref(options).searchResults.value,(item,index)=>(openBlock(),createBlock(Item_default,{key:`search-`+index,index,level:0,data:item,onClick,onChange},null,8,[`index`,`data`]))),128))])),[[unref(BngUiNavScroll_default),void 0,void 0,{force:!0}]]):special.value===`categories-edit`?(openBlock(),createElementBlock(`div`,_hoisted_20$1,[(openBlock(!0),createElementBlock(Fragment,null,renderList(allCategories.value,cat=>(openBlock(),createElementBlock(Fragment,{key:`cat-`+cat.categoryIndex},[cat.persistent?createCommentVNode(``,!0):(openBlock(),createBlock(CategorySide_default,{key:0,id:`options-cat-`+cat.categoryIndex,"has-subcategories":cat.hasSubcategories,subcategory:cat.subcategoryMode,icon:cat.icon,index:cat.categoryIndex,"hidden-by-condition":cat.hiddenByCondition,"debug-settings":cat.debugSettings,editable:editable.value,onClick:$event=>categoryEdit(`edit`,cat.categoryIndex),onEditCmd:categoryEdit},{default:withCtx(()=>[createTextVNode(toDisplayString(cat.spacer||cat.divider?`---`:_ctx.$tt(cat.label)),1)]),_:2},1032,[`id`,`has-subcategories`,`subcategory`,`icon`,`index`,`hidden-by-condition`,`debug-settings`,`editable`,`onClick`]))],64))),128)),editable.value?(openBlock(),createBlock(CategorySide_default,{key:0,icon:`plus`,onClick:_cache[10]||=$event=>categoryEdit(`add`),style:normalizeStyle(editable.value?{}:{opacity:0,pointerEvents:`none`})},{default:withCtx(()=>[..._cache[15]||=[createTextVNode(`New category`,-1)]]),_:1},8,[`style`])):createCommentVNode(``,!0)])):createCommentVNode(``,!0),createBaseVNode(`div`,{ref_key:`elInfo`,ref:elInfo,class:normalizeClass([`options-info`,{"info-hidden":!!special.value}])},[createVNode(BlurBackground_default),withDirectives(createBaseVNode(`div`,_hoisted_21$1,null,512),[[unref(BngBlur_default)]]),(openBlock(!0),createElementBlock(Fragment,null,renderList(infoView.value,tip=>(openBlock(),createElementBlock(`span`,{key:tip.id,innerHTML:tip.text},null,8,_hoisted_22$1))),128)),_cache[17]||=createBaseVNode(`div`,{class:`options-spacer`},null,-1),fpsShown.value?(openBlock(),createElementBlock(`div`,_hoisted_23$1,[_cache[16]||=createTextVNode(`FPS: `,-1),createBaseVNode(`span`,null,toDisplayString(fps.value),1)])):createCommentVNode(``,!0)],2)])),[[unref(BngScopedNav_default),{activated:activeScope.value===`content`,bubbleWhitelistEvents:[`context`]}],[unref(BngOnUiNav_default),mainCatNav,`tab_l,tab_r`],[unref(BngOnUiNav_default),fromContent,`back`],[unref(BngOnUiNav_default),back,`menu`]])])):createCommentVNode(``,!0)])),[[unref(BngOnUiNav_default),mainCatNav,`tab_l,tab_r`],[unref(BngOnUiNav_default),back,`back,menu`],[unref(BngOnUiNav_default),toSearchAndBack,`context`],[unref(BngUiNavLabel_default),`ui.common.search`,`context`]])}},OptionsView_default=__plugin_vue_export_helper_default(_sfc_main$23,[[`__scopeId`,`data-v-206a0fb3`]]),routes_default$12=[{path:`/options/:category?`,name:`options`,component:OptionsView_default,props:!0,meta:{infoBar:{visible:!0,showSysInfo:!0},uiApps:{shown:!1}}}],cfg={background:[`var(--bng-black-o8)`,`var(--bng-black-o4)`],info:{icon:`var(--bng-cool-gray-500)`,iconSize:.15,label:`var(--bng-off-white)`,labelSize:.05,line:`var(--bng-cool-gray-700)`,lineSize:.0025,hotkey:`#aaa`,hotkeySize:.04,unfocusedColor:`var(--bng-cool-gray-500)`,focusedColor:`var(--bng-off-white)`},button:{top:.45,height:.175,margin:.004,corners:.03,background:`var(--bng-black)`,highlight:`var(--bng-ter-blue-gray-700)`,border:`var(--bng-cool-gray-700)`,borderHighlight:`var(--bng-cool-gray-500)`,borderSize:.0025,folder:`var(--bng-ter-blue-gray-900)`,folderTop:.45,folderHeight:.015,markerTop:.3,markerHeight:.025,marker:`var(--bng-orange)`,icon:`var(--bng-off-white)`,iconSize:.1,majorBackground:[`var(--bng-black)`,`var(--bng-ter-blue-gray-850)`],majorHighlight:[`var(--bng-ter-blue-gray-600)`,`var(--bng-ter-blue-gray-700)`],pinnedDotInvisible:{fill:`transparent`,stroke:`transparent`,r:4},markDotSolid:{fill:`rgba(var(--bng-cool-gray-100-rgb),0.7)`,stroke:`transparent`,r:4},markDotOutline:{fill:`transparent`,stroke:`rgba(var(--bng-cool-gray-100-rgb),0.7)`,r:3},markStar:{fill:`rgba(var(--bng-cool-gray-100-rgb),0.7)`,stroke:`rgba(var(--bng-cool-gray-100-rgb),0.7)`,"stroke-width":2,r:3,isStar:!0,starPoints:5,innerRadius:1.5,outerRadius:3}},pointer:{color:`var(--bng-orange)`,size:6}},size=500,pointerRadius=125,controlsHotkey=``,getHotkey=action=>{let viewerObj=controls_default().makeViewerObj({action});return viewerObj?icons[viewerObj.icon].glyph+` `+viewerObj.control.split(/[ -]/).map(s=>s.substring(0,1).toUpperCase()+s.substring(1)).join(`+`):``},RadialSVG=class{parent;svg;config;events;itemsCont;info;buttons;pointer;menuIcon=``;constructor(events$3={},config=cfg,element=void 0){this.events=events$3,this.config=config,element&&this.create(element)}create(element){this.parent!==element&&(this.parent=element,this.svg||([this.svg,this.itemsCont,this.info,this.pointer]=createSvg(this.config)),this.parent.appendChild(this.svg))}update(items$2=[]){!this.itemsCont||!this.info||(controlsHotkey=getHotkey(`menu_item_focus_ud`),this.buttons=updateSvg(this.itemsCont,this.info,items$2,this.events,this.config,this.buttons||[],this))}dispose(){this.parent&&(this.parent.removeChild(this.svg),this.parent=null,this.svg=null,this.itemsCont=null,this.info=null,this.buttons=null)}setPointer(x,y){if(!this.pointer)return;let magnitude=Math.sqrt(x*x+y*y);magnitude>.1?(x/=magnitude,y/=magnitude,this.pointer.setAttribute(`cx`,x*pointerRadius+size/2),this.pointer.setAttribute(`cy`,-y*pointerRadius+size/2),this.pointer.setAttribute(`display`,`block`)):this.pointer.setAttribute(`display`,`none`)}setMenuIcon(iconName){if(this.menuIcon=iconName,this.info){let iconGlyph=getIconGlyph(this.menuIcon);this.info.icon.textContent=iconGlyph}}},svgns=`http://www.w3.org/2000/svg`,xhtmlns=`http://www.w3.org/1999/xhtml`,pid=Math.PI*2,getIconGlyph=iconName=>(iconName&&iconName in icons?icons[iconName]:icons.beamNG).glyph,setAttrs=(elm,attrs)=>Object.entries(attrs).forEach(attr=>elm.setAttribute(...attr)),setStyles=(elm,styles)=>Object.entries(styles).forEach(rule=>elm.style.setProperty(...rule)),f2size=f=>f*size,getPoint=(turn,radius,center=[.5,.5])=>[center[0]+radius*Math.cos(turn*pid),center[1]+radius*Math.sin(turn*pid)].map(n=>f2size(n).toFixed(5)),drawLine=to=>` L ${to.join(`,`)} `,drawBezier=(control,to)=>` S ${control.join(`,`)} ${to.join(` `)} `,drawArc=(to,radius,invert=!1)=>` A ${radius} ${radius}, 0, 0, ${invert?`0`:`1`}, ${to.join(` `)} `;function createSimplePath(pos,rad,width$1,height$1){let d=`M ${getPoint(pos,rad).join(`,`)} `;return d+=drawArc(getPoint(pos+width$1,rad),f2size(rad),!1),d+=drawLine(getPoint(pos+width$1,rad-height$1)),d+=drawArc(getPoint(pos,rad-height$1),f2size(rad-height$1),!0),d+=drawLine(getPoint(pos,rad)),d+=`Z`,d}function createPath({pos,rad,width:width$1,height:height$1,corner,padout,padin}){corner>height$1&&(corner=height$1);let corh=corner*rad/Math.PI,corv=corner*rad,d=`M ${getPoint(pos+padout+corh,rad).join(`,`)} `;return d+=drawArc(getPoint(pos+width$1-padout-corh,rad),f2size(rad),!1),d+=drawBezier(getPoint(pos+width$1-padout,rad),getPoint(pos+width$1-padout,rad-corv)),d+=drawLine(getPoint(pos+width$1-padout-padin,rad-height$1+corv)),d+=drawBezier(getPoint(pos+width$1-padout-padin,rad-height$1),getPoint(pos+width$1-padout-corh-padin,rad-height$1)),d+=drawArc(getPoint(pos+padout+corh+padin,rad-height$1),f2size(rad-height$1),!0),d+=drawBezier(getPoint(pos+padout+padin,rad-height$1),getPoint(pos+padout+padin,rad-height$1+corv)),d+=drawLine(getPoint(pos+padout,rad-corv)),d+=drawBezier(getPoint(pos+padout,rad),getPoint(pos+padout+corh,rad)),d+=`Z`,d}function updateSvg(cont,info,items$2,events$3,config=cfg,buttons=[],radialInstance=null){let btns=[...buttons||[]],elmsRem=btns.splice(items$2.length);for(let elm of elmsRem)cont.removeChild(elm.element);if(items$2.length<1)return null;for(let index=btns.length;indexicon,file:icon=>`/ui/modules/apps/RadialMenu/mods_icons/`+icon,symbol:icon=>`#`+({radial_Drift_ESC:`radial_drift_ESC`,radial_Sport_ESC:`radial_sport_ESC`,radial_Regular_ESC:`radial_regular_ESC`,radial_ESC:`radial_regular_ESC`}[icon]||icon)};function createButton(index,info,config,item){let btn={index},majorGradId=uniqueSafeId(),majorHighlightGradId=uniqueSafeId(),control=document.createElementNS(svgns,`g`);btn.element=control;function createGradient(id,colors){let grad=document.createElementNS(svgns,`radialGradient`);return setAttrs(grad,{id,cx:`0.5`,cy:`0.5`,r:`0.5`,fx:`0.5`,fy:`0.5`}),colors.forEach((color,index$1)=>{let stop$1=document.createElementNS(svgns,`stop`);setAttrs(stop$1,{offset:index$1/(colors.length-1),"stop-color":color}),grad.appendChild(stop$1)}),grad}let defs=document.createElementNS(svgns,`defs`);defs.appendChild(createGradient(majorGradId,config.button.majorBackground)),defs.appendChild(createGradient(majorHighlightGradId,config.button.majorHighlight)),control.appendChild(defs);let button=document.createElementNS(svgns,`path`);config.button.border&&config.button.borderSize>0&&setAttrs(button,{stroke:config.button.border,"stroke-width":f2size(config.button.borderSize)}),control.appendChild(button);let folder=document.createElementNS(svgns,`path`);folder.setAttribute(`fill`,config.button.folder),control.appendChild(folder);let marker$1=document.createElementNS(svgns,`path`);marker$1.setAttribute(`fill`,`none`),control.appendChild(marker$1);let pinnedDot=document.createElementNS(svgns,`circle`);setAttrs(pinnedDot,config.button.markDotSolid),pinnedDot.setAttribute(`style`,`display: none`),control.appendChild(pinnedDot);let starPath=document.createElementNS(svgns,`path`),starConfig=config.button.markStar,points=starConfig.starPoints||5,innerRadius=starConfig.innerRadius||1.5,outerRadius=starConfig.outerRadius||3,starPathData=``;for(let i=0;ion?iconRect.removeAttribute(`style`):iconRect.setAttribute(`style`,`display: none`),setGlyph=glyph=>iconText.textContent=glyph||``,setImage=path=>{path?(iconImage.setAttribute(`href`,path),iconImage.removeAttribute(`style`)):(iconImage.removeAttribute(`href`),iconImage.setAttribute(`style`,`display: none`))},setSymbol=id=>{id?(iconMask.setAttribute(`mask-type`,`luminocity`),iconSymbol.setAttribute(`href`,id),iconSymbol.removeAttribute(`style`)):(iconMask.setAttribute(`mask-type`,`alpha`),iconSymbol.removeAttribute(`href`),iconSymbol.setAttribute(`style`,`display: none`))},itype=iconType(item$1.icon);switch(itype){case`glyph`:setGlyph(getIconGlyph(item$1.icon)),setRect(!1),setImage(),setSymbol();break;case`symbol`:setImage(),setSymbol(iconGet[itype](item$1.icon)),setRect(!0),setGlyph();break;default:setImage(iconGet[itype](item$1.icon)),setSymbol(),setRect(!0),setGlyph();break}}let hitzone=document.createElementNS(svgns,`path`);setAttrs(hitzone,{fill:`transparent`,style:`pointer-events: fill`}),control.appendChild(hitzone);function updateHitzone(position,length,config$1){hitzone.setAttribute(`d`,createSimplePath(position-length/2,config$1.button.top,length,config$1.button.height))}function updateEvents$1(events$3,radialInstance){btn._handlers&&(hitzone.removeEventListener(`mouseover`,btn._handlers.focus),hitzone.removeEventListener(`mouseleave`,btn._handlers.blur),hitzone.removeEventListener(`click`,btn._handlers.click),hitzone.removeEventListener(`mousedown`,btn._handlers.down),hitzone.removeEventListener(`mouseup`,btn._handlers.up),hitzone.removeEventListener(`contextmenu`,btn._handlers.contextMenu));let item$1=btn.item,index$1=btn.index;return btn.menuIcon=radialInstance?.menuIcon||``,btn._handlers={focus(){if(item$1.focused&&btn._focused)return;let highlightFill=item$1.majorButton?`url(#${majorHighlightGradId})`:config.button.highlight;button.setAttribute(`fill`,highlightFill),button.setAttribute(`stroke`,config.button.borderHighlight),marker$1.setAttribute(`fill`,config.button.marker);let itype=iconType(item$1.icon);itype===`glyph`?(setStyles(info.icon,{"background-color":`transparent`,"-webkit-mask-image":`none`,color:config.info.focusedColor}),info.icon.textContent=getIconGlyph(item$1.icon)):(info.icon.textContent=``,itype===`symbol`&&info.iconSymbol.setAttribute(`href`,iconGet[itype](item$1.icon)),setStyles(info.icon,{"background-color":config.info.icon,"-webkit-mask-image":itype===`symbol`?`url('#${info.iconMaskId}')`:`url('${iconGet[itype](item$1.icon)}')`})),info.label.textContent=typeof item$1.title==`string`?$translate.contextTranslate({txt:item$1.title,context:item$1.context}):$translate.contextTranslate(item$1.title),info.label.style.color=config.info.focusedColor,info.price.textContent=item$1?.price?.money?.amount===void 0?``:item$1.price.money.amount+` `,info.hotkey.textContent=item$1.hotkey||``,info.cont.removeAttribute(`style`),item$1.focused=!0,btn._focused=!0,typeof events$3.focus==`function`&&events$3.focus(item$1,index$1)},blur(){if(!item$1.focused&&!btn._focused)return;let normalFill=item$1.majorButton?`url(#${majorGradId})`:config.button.background;button.setAttribute(`fill`,normalFill),button.setAttribute(`stroke`,config.button.border),marker$1.setAttribute(`fill`,`none`),setStyles(info.icon,{"background-color":`transparent`,"-webkit-mask-image":`none`,color:config.info.unfocusedColor});let iconGlyph=getIconGlyph(btn.menuIcon);info.icon.textContent=iconGlyph,info.label.textContent=`Select an option`,info.price.textContent=``,info.hotkey.textContent=controlsHotkey,info.label.style.color=config.info.unfocusedColor,item$1.focused=!1,btn._focused=!1,typeof events$3.blur==`function`&&events$3.blur(item$1,index$1)},click(evt){evt&&evt.stopPropagation(),!(!item$1.enabled||!events$3||evt&&!evt.fromController&&evt.type!==`ui_nav`)&&(btn._handlers.isDown=!1,typeof events$3.click==`function`&&events$3.click(item$1,index$1))},down(evt){!item$1.enabled||!events$3||evt.button!==0||(btn._handlers.isDown=!0,typeof events$3.down==`function`&&events$3.down(item$1,index$1))},up(evt){!btn._handlers.isDown||!item$1.enabled||!events$3||evt.button!==0||(btn._handlers.isDown=!1,typeof events$3.up==`function`&&events$3.up(item$1,index$1))},contextMenu(evt){evt&&evt.stopPropagation(),events$3&&typeof events$3.contextAction==`function`&&events$3.contextAction(item$1,index$1)}},hitzone.addEventListener(`mouseover`,btn._handlers.focus),hitzone.addEventListener(`mouseleave`,btn._handlers.blur),hitzone.addEventListener(`click`,btn._handlers.click,!0),hitzone.addEventListener(`mousedown`,btn._handlers.down),hitzone.addEventListener(`mouseup`,btn._handlers.up),hitzone.addEventListener(`contextmenu`,btn._handlers.contextMenu),btn._handlers}function updateEnable(item$1){item$1.enabled?(hitzone.setAttribute(`cursor`,`pointer`),control.removeAttribute(`opacity`)):(hitzone.removeAttribute(`cursor`),control.setAttribute(`opacity`,`0.5`))}return btn.update=(item$1,events$3=void 0,radialInstance=null)=>{btn.item=item$1;let length=Math.min(item$1.size,.5),position=(item$1.position-.5)%1;updateButton(position,length,config,item$1),updateHitzone(position,length,config),updateIcon(position,length,config,item$1),updateEnable(item$1),btn._handlers=updateEvents$1(events$3,radialInstance),Object.assign(btn,btn._handlers),(item$1.focused||btn._focused)&&btn._handlers.focus()},btn}function createSvg(config=cfg){let svg=document.createElementNS(svgns,`svg`);setAttrs(svg,{viewBox:`0 0 ${size} ${size}`,width:`100%`,height:`100%`,preserveAspectRatio:`xMidYMid meet`,style:`pointer-events: none`});let gradId=Array.isArray(config.background)?uniqueSafeId():null;if(gradId){let grad=document.createElementNS(svgns,`radialGradient`);grad.setAttribute(`id`,gradId);for(let i=0;i{evt.stopPropagation()},!0),svg.appendChild(bg);let nfo={cont:document.createElementNS(svgns,`foreignObject`),body:document.createElementNS(xhtmlns,`body`),wrap:document.createElementNS(xhtmlns,`div`),icon:document.createElementNS(xhtmlns,`div`),iconSymbol:document.createElementNS(svgns,`use`),iconMaskId:uniqueSafeId(),label:document.createElementNS(xhtmlns,`div`),price:document.createElementNS(xhtmlns,`div`),hotkey:document.createElementNS(xhtmlns,`div`)},foMinSize=200,nfoSize=size>=200?size:200;setAttrs(nfo.cont,{style:`display: none`,width:nfoSize,height:nfoSize}),size<200&&nfo.cont.setAttribute(`transform`,`scale(${size*.005})`),nfo.body.setAttribute(`xmlns`,xhtmlns),setStyles(nfo.body,{width:`100%`,height:`100%`}),setStyles(nfo.wrap,{width:`${nfoSize*.5}px`,height:`${nfoSize*.4}px`,margin:`${nfoSize*.3}px ${nfoSize*.25}px`,display:`flex`,"flex-direction":`column`,"align-items":`center`,"justify-content":`space-between`,"font-family":`var(--fnt-defs)`}),setStyles(nfo.icon,{color:config.info.icon,"font-size":`${config.info.iconSize*nfoSize}px`,"font-family":`bngIcons`,width:`${config.info.iconSize*nfoSize}px`,height:`${config.info.iconSize*nfoSize}px`,"-webkit-mask-image":`none`,"-webkit-mask-size":`contain`,"-webkit-mask-position":`50% 50%`,"-webkit-mask-repeat":`no-repeat`,"background-color":`transparent`});let iconSvg=document.createElementNS(svgns,`svg`);setAttrs(iconSvg,{viewBox:`0 0 ${config.info.iconSize*nfoSize} ${config.info.iconSize*nfoSize}`,width:`0`,height:`0`,style:`position: absolute;`});let iconMask=document.createElementNS(svgns,`mask`);setAttrs(iconMask,{id:nfo.iconMaskId,maskUnits:`userSpaceOnUse`,maskContentUnits:`userSpaceOnUse`,"mask-type":`luminocity`}),setAttrs(nfo.iconSymbol,{x:`0`,y:`0`,width:config.info.iconSize*nfoSize,height:config.info.iconSize*nfoSize,fill:`#fff`}),iconMask.appendChild(nfo.iconSymbol),iconSvg.appendChild(iconMask),setStyles(nfo.label,{"min-height":`2em`,width:`100%`,"text-align":`center`,color:config.info.label,"font-size":`${config.info.labelSize*nfoSize}px`,"font-family":`var(--fnt-defs)`}),setStyles(nfo.price,{width:`100%`,"text-align":`center`,color:config.info.label,"font-size":`${config.info.labelSize*.8*nfoSize}px`,"font-family":`bngIcons, var(--fnt-defs)`}),setStyles(nfo.hotkey,{width:`80%`,"text-align":`center`,"padding-top":`1px`,"min-height":`${config.info.hotkeySize*nfoSize+10}px`,"border-top":`${config.info.lineSize*nfoSize}px solid ${config.info.line}`,color:config.info.hotkey,"font-size":`${config.info.hotkeySize*nfoSize}px`,"font-family":`bngIcons, "Noto Sans Mono", var(--fnt-defs)`}),nfo.wrap.appendChild(iconSvg),nfo.wrap.appendChild(nfo.icon),nfo.wrap.appendChild(nfo.label),nfo.wrap.appendChild(nfo.price),nfo.wrap.appendChild(nfo.hotkey),nfo.body.appendChild(nfo.wrap),nfo.cont.appendChild(nfo.body),svg.appendChild(nfo.cont);let cont=document.createElementNS(svgns,`g`);svg.appendChild(cont);let pointer=document.createElementNS(svgns,`circle`);return setAttrs(pointer,{r:config.pointer.size,fill:config.pointer.color,display:`none`}),svg.appendChild(pointer),nfo.icon.textContent=getIconGlyph(svg.menuIcon),nfo.label.textContent=`Select an option`,nfo.price.textContent=``,nfo.label.style.color=config.info.unfocusedColor,controlsHotkey=getHotkey(`menu_item_focus_ud`),nfo.hotkey.textContent=controlsHotkey,nfo.cont.removeAttribute(`style`),[svg,cont,nfo,pointer]}var _hoisted_1$18={class:`radial-infos`},_hoisted_2$12={class:`radial-breadcrumbs`},_hoisted_3$11={key:0,class:`radial-categories`},_hoisted_4$8={class:`radial-plate`},_hoisted_5$7={class:`radial-category-label`},_hoisted_6$4={key:0,class:`radial-quick-tabs`},_hoisted_7$4={key:1,class:`radial-description`},sensivity=.5,_sfc_main$22={__name:`Radial`,setup(__props){useUINavScope(`radialMenu`);let infobar=useInfoBar(),controls$1=controls_default(),events$3=useEvents(),radialData=ref({}),temporaryHidden=ref(!1),breadcrumbs=computed(()=>radialData.value&&radialData.value.breadcrumbs&&Array.isArray(radialData.value.breadcrumbs)?radialData.value.breadcrumbs.map(str=>$translate.instant(str)).join(` / `):``),focusedItem=computed(()=>{let items$2=radialData?.value?.items;return items$2&&Array.isArray(items$2)?items$2.find(item=>item.focused):null}),hasLRShoulderButtons=computed(()=>radialData.value&&radialData.value.hasLRShoulderButtons),radialSvg=new RadialSVG({click:(item,index)=>{Lua_default.ui_audio.playEventSound(`bng_click_hover_generic`,`click`),Lua_default.core_quickAccess.selectItem(index+1,!0,1)},down:(item,index)=>{Lua_default.ui_audio.playEventSound(`bng_click_hover_generic`,`click`),Lua_default.core_quickAccess.selectItem(index+1,!0,1)},focus:(item,index)=>{Lua_default.ui_audio.playEventSound(`bng_click_hover_generic`,`focus`)},contextAction:(item,index)=>{Lua_default.ui_audio.playEventSound(`bng_click_hover_generic`,`focus`),Lua_default.core_quickAccess.contextAction(index+1,!0,1)}}),radialCont=ref(),requestData=async()=>{radialData.value=await Lua_default.core_quickAccess.getUiData();let items$2=Array.isArray(radialData.value.items)?radialData.value.items:[];for(let item of items$2)item.hotkey=getHotkey$1(item.action);radialSvg.setMenuIcon(radialData.value.menuIcon||`beamNG`),radialSvg.update(items$2)},getHotkey$1=action=>{let viewerObj=controls$1.makeViewerObj({action});return viewerObj?icons[viewerObj.icon].glyph+` `+viewerObj.control.split(/[ -]/).map(s=>s.substring(0,1).toUpperCase()+s.substring(1)).join(``):``},setLevel=level$1=>{Lua_default.ui_audio.playEventSound(`bng_click_hover_generic`,`focus`),Lua_default.core_quickAccess.setEnabled(!0,level$1,!1)},close=()=>{Lua_default.core_quickAccess.setEnabled(!1,``,!1)},back=()=>{radialData.value.backButtonIndex?Lua_default.core_quickAccess.back():close()},switchCategory=left=>{let indexOffset=left?-1:1;for(let i=0;i{let actions=radialData.value.items;for(let i=0;i{if(radialData.value.categories.length>0){switchCategory(evt.detail.name===`tab_l`);return}LRAction(evt.detail.name)},processMouseClick=evt=>{if(!radialSvg.buttons)return;let elm=radialSvg?.buttons?.find(elm$1=>elm$1._focused)||radialSvg?.buttons?.find(elm$1=>elm$1.item.focused);return evt.detail.name===`context`?elm&&elm.contextMenu(evt):elm&&elm.click(evt),elm},isStickActive=(x,y)=>Math.sqrt(x**2+y**2)>sensivity,pointToItem=(x,y)=>{if(!radialSvg.buttons)return;let len=radialSvg.buttons.length,idx=-1;if(radialSvg.setPointer(x,y),x!==0||y!==0){let cursorPos=.5-Math.atan2(y,x)/Math.PI/2;for(let i=0;i=startPos&&cursorPos=startPos||cursorPos-1&&idx{evt.detail.name===`focus_ud`?stickY=evt.detail.value:stickX=evt.detail.value;let stickActiveBefore=stickActive;stickActive=isStickActive(stickX,stickY),stickActive&&pointToItem(stickX,stickY),!stickActive&&stickActiveBefore&&pointToItem(0,0)},dpadX=0,dpadY=0,processDpadInput=evt=>{switch(evt.detail.name){case`focus_l`:dpadX=-evt.detail.value;break;case`focus_r`:dpadX=evt.detail.value;break;case`focus_u`:dpadY=evt.detail.value;break;case`focus_d`:dpadY=-evt.detail.value;break}dpadX=0+ +dpadX,dpadY=0+ +dpadY,pointToItem(dpadX,dpadY)},openFavoriteSelector=()=>{if(radialData.value.pathBeforeCategory===`favorites`){for(let i=0;i{let isOnComponents=event.target.closest(`.radial-categories, .radial-svg, .radial-tab-left, .radial-tab-right`);event.isTrusted&&event.sourceCapabilities?.firesTouchEvents===!1&&!isOnComponents&&(event.button===0?close():event.button===2&&back())};events$3.on(`radialMenuUpdated`,requestData),events$3.on(`RadialTemporaryHide`,hide$2=>{temporaryHidden.value=hide$2}),onBeforeMount(()=>{infobar.clearHints()}),onMounted(()=>{infobar.visible=!0,radialSvg.create(radialCont.value),requestData()});let headingTitle=computed(()=>radialData.value?.breadcrumbs?.[0]?$translate.instant(radialData.value.breadcrumbs[0]):radialData.value?.items?.length?`Radial Menu`:`No Actions Available`),hasCategories=computed(()=>radialData.value?.categories&&(Array.isArray(radialData.value.categories)?radialData.value.categories.length>0:Object.keys(radialData.value.categories).length>0));return(_ctx,_cache)=>withDirectives((openBlock(),createElementBlock(`div`,{class:normalizeClass([`radial-menu`,{temporaryHidden:temporaryHidden.value}]),"bng-ui-scope":`radialMenu`,onMousedown:handleMouseDown},[createBaseVNode(`div`,_hoisted_1$18,[createVNode(bngCardHeading_default,{class:`radial-title`},{default:withCtx(()=>[createTextVNode(toDisplayString(headingTitle.value),1)]),_:1}),createBaseVNode(`div`,_hoisted_2$12,toDisplayString(breadcrumbs.value),1),hasCategories.value?(openBlock(),createElementBlock(`div`,_hoisted_3$11,[createVNode(unref(bngBinding_default),{class:`radial-plate radial-tab-left`,"ui-event":`tab_l`,style:normalizeStyle({"--rad-tab-icon":`'${unref(icons).arrowSmallLeft.glyph}'`}),controller:``,onClick:_cache[0]||=$event=>switchCategory(!0)},null,8,[`style`]),createBaseVNode(`div`,_hoisted_4$8,[(openBlock(!0),createElementBlock(Fragment,null,renderList(radialData.value.categories,category=>withDirectives((openBlock(),createBlock(unref(bngImageTile_default),{key:category.id,onClick:$event=>setLevel(category.goto),tabindex:`0`,"bng-nav-item":``,class:normalizeClass([`radial-category`,{selected:category.id===radialData.value.selectedCategory}]),icon:unref(icons)[category.icon||`beamNG`]},{default:withCtx(()=>[createBaseVNode(`div`,_hoisted_5$7,toDisplayString(unref($translate).instant(category.title)),1)]),_:2},1032,[`onClick`,`class`,`icon`])),[[unref(BngOnUiNav_default),void 0,`ok`,{asMouse:!0,focusRequired:!0}]])),128)),_cache[4]||=createBaseVNode(`div`,{class:`background-plate`},null,-1)]),createVNode(unref(bngBinding_default),{class:`radial-plate radial-tab-right`,"ui-event":`tab_r`,controller:``,style:normalizeStyle({"--rad-tab-icon":`'${unref(icons).arrowSmallRight.glyph}'`}),onClick:_cache[1]||=$event=>switchCategory(!1)},null,8,[`style`])])):createCommentVNode(``,!0)]),hasLRShoulderButtons.value?(openBlock(),createElementBlock(`div`,_hoisted_6$4,[createVNode(unref(bngBinding_default),{class:`radial-plate radial-tab-left`,style:normalizeStyle({"--rad-tab-icon":`'${unref(icons).arrowSmallLeft.glyph}'`}),"ui-event":`tab_l`,controller:``,onClick:_cache[2]||=$event=>LRAction(`tab_l`)},null,8,[`style`]),createVNode(unref(bngBinding_default),{class:`radial-plate radial-tab-right`,style:normalizeStyle({"--rad-tab-icon":`'${unref(icons).arrowSmallRight.glyph}'`}),"ui-event":`tab_r`,controller:``,onClick:_cache[3]||=$event=>LRAction(`tab_r`)},null,8,[`style`])])):createCommentVNode(``,!0),createBaseVNode(`div`,{ref_key:`radialCont`,ref:radialCont,class:`radial-svg`},null,512),focusedItem.value?.desc?(openBlock(),createElementBlock(`div`,_hoisted_7$4,toDisplayString(unref(content_exports).bbcode.parse(unref($translate).contextTranslate(focusedItem.value.desc,!0))),1)):createCommentVNode(``,!0)],34)),[[unref(BngBlur_default),!temporaryHidden.value],[unref(BngOnUiNav_default),openFavoriteSelector,`context`],[unref(BngOnUiNav_default),back,`menu,back`],[unref(BngOnUiNav_default),processTabInput,`tab_l,tab_r`],[unref(BngOnUiNav_default),processStickInput,`focus_lr,focus_ud`],[unref(BngOnUiNav_default),processDpadInput,`focus_l,focus_r,focus_u,focus_d`,{down:!0}],[unref(BngOnUiNav_default),processDpadInput,`focus_l,focus_r,focus_u,focus_d`,{up:!0}],[unref(BngOnUiNav_default),processMouseClick,`ok,context`],[unref(BngUiNavLabel_default),radialData.value.backButtonIndex?`ui.common.back`:`ui.common.close`,`menu,back`],[unref(BngUiNavLabel_default),`Radial menu navigation`,`focus_lr,focus_ud,focus_l,focus_r,focus_u,focus_d`],[unref(BngUiNavLabel_default),`Select`,`ok`],[unref(BngUiNavLabel_default),`Configure Slot`,`context`],[unref(BngUiNavLabel_default),`Switch Category`,`tab_l,tab_r`]])}},Radial_default=__plugin_vue_export_helper_default(_sfc_main$22,[[`__scopeId`,`data-v-9330a4cb`]]),routes_default$13=[{path:`/radial`,name:`radial`,component:Radial_default,meta:{uiApps:{shown:!1}}}],routes_default$14=[{path:`/recovery`,name:`recovery`,component:Recovery_default,props:!0}],isFuelEnergyType=type=>[`gasoline`,`diesel`].includes(type);const useRefuelStore=defineStore(`refuel`,()=>{let{events:events$3}=useBridge(),minSlider=23,maxSlider=80,minEnergy=0,fuelOptions=[{id:1,value:0,name:`FuelType-1`},{id:2,value:1,name:`FuelType-2`},{id:3,value:2,name:`FuelType-3`}],energyTypes=ref([]),fuelTanks=ref([]),overallPrice=ref(0),flowRate=ref(0),currentEnergyType=ref(null),showFuelTypeSettings=ref(!1),showAmountSettings=ref(!1),energyTypesToLocalUnits=ref({}),gasStationName=ref(``),fuelDiscountData=ref({}),isFuelling=computed(()=>flowRate.value>0),currentFuelData=computed(()=>fuelTanks.value.filter(f=>f.energyType===currentEnergyType.value)[0]),currentFuelType=computed(()=>currentEnergyType.value===``?``:isFuelEnergyType(currentEnergyType.value)?`fuel`:`charge`),currentFuelLevel=computed(()=>currentFuelData.value?currentFuelData.value.currentEnergy/currentFuelData.value.maxEnergy:0),canRefuel=computed(()=>currentFuelData.value?currentFuelData.value.currentEnergycanRefuel.value===!0?isFuelling.value===!0?`on`:`off`:`disabled`),canPay=computed(()=>currentFuelData.value.price>0),canStartFuelling=computed(()=>isFuelling.value===!1&&canRefuel.value===!0),canStopFuelling=computed(()=>isFuelling.value===!0),minEnergyLabel=computed(()=>`0 `+getUnitLabel(currentEnergyType.value)),maxEnergyLabel=computed(()=>currentFuelData.value?(isFuelEnergyType(currentEnergyType.value)?convertToLocalUnit(currentFuelData.value.maxEnergy,currentEnergyType.value).toFixed(2):`100`)+` `+getUnitLabel(currentEnergyType.value):``);function getUnitLabel(energyType){return isFuelEnergyType(energyType)?getLocalUnitLabel(energyType):`%`}function getLocalUnit(energyType){return energyTypesToLocalUnits.value[energyType]?energyTypesToLocalUnits.value[energyType]:`L`}let unitToLabel={gallonUS:`gal`},factorSIToLocalUnit={gallonUS:.26417};function getLocalUnitLabel(energyType){let localUnit=getLocalUnit(energyType);return localUnit&&unitToLabel[localUnit]?unitToLabel[localUnit]:`L`}function convertToLocalUnit(valueSI,energyType){let localUnit=getLocalUnit(energyType);return localUnit?valueSI*(factorSIToLocalUnit[localUnit]||1):valueSI}function convertToPricePerLocalUnit(pricePerSI,energyType){let localUnit=getLocalUnit(energyType);return localUnit?pricePerSI/(factorSIToLocalUnit[localUnit]||1):pricePerSI}function startFuelling(){Lua_default.career_modules_fuel.uiButtonStartFueling(currentEnergyType.value)}function stopFuelling(){Lua_default.career_modules_fuel.uiButtonStopFueling(currentEnergyType.value)}function changeFlowRate(newFlowRate){flowRate.value=newFlowRate,Lua_default.career_modules_fuel.onChangeFlowRate(flowRate.value)}function payPrice(){Lua_default.career_modules_fuel.payPrice()}function requestFuelingData(){Lua_default.career_modules_fuel.requestRefuelingTransactionData(),runInBrowser(()=>getMockedData(`career.initialFuelingData`).then(data=>events$3.emit(`initialFuelingData`,data)))}function cancelTransaction(){console.log(`cancelTransaction`),Lua_default.career_modules_fuel.uiCancelTransaction()}function dispose$2(){events$3.off(`initialFuelingData`),events$3.off(`updateFuelData`)}return events$3.on(`initialFuelingData`,data=>{({fuelData:fuelTanks.value,energyTypes:energyTypes.value}=data),currentEnergyType.value=energyTypes.value[0],energyTypesToLocalUnits.value=data.energyTypesToLocalUnits,factorSIToLocalUnit.value=data.factorSIToLocalUnit,gasStationName.value=data.gasStationName,fuelDiscountData.value=data.fuelDiscountData||{},Lua_default.career_modules_fuel.sendUpdateDataToUI()}),events$3.on(`updateFuelData`,data=>{fuelTanks.value.length!==0&&(fuelTanks.value[0].currentEnergy=data.fuelData[0].currentEnergy,fuelTanks.value[0].fueledEnergy=data.fuelData[0].fueledEnergy,fuelTanks.value[0].price=data.fuelData[0].price,overallPrice.value=data.overallPrice,flowRate.value=data.fuelData[0].fuelingActive===!0?1:0)}),{currentFuelData,currentFuelLevel,currentFuelType,currentEnergyType,nozzleMode,overallPrice,isFuelling,energyTypes,canPay,canStartFuelling,canStopFuelling,fuelDiscountData,showFuelTypeSettings,showAmountSettings,gasStationName,startFuelling,stopFuelling,changeFlowRate,payPrice,requestFuelingData,cancelTransaction,getUnitLabel,convertToPricePerLocalUnit,dispose:dispose$2,minEnergyLabel,maxEnergyLabel,minSlider:23,maxSlider:80,fuelOptions}});var _hoisted_1$17={class:`full`,xmlns:`http://www.w3.org/2000/svg`,"xmlns:xlink":`http://www.w3.org/1999/xlink`,x:`0`,y:`0`,viewBox:`6 0 280 280`,width:`280`,height:`280`},_hoisted_2$11={id:`glow`,x:`-40%`,y:`-40%`,width:`180%`,height:`180%`},_hoisted_3$10=[`flood-color`],_hoisted_4$7={class:`gauge-label`},_hoisted_5$6={class:`info`},DASH_ARR_LENGTH=455,GAUGE_TYPES=[`refuel`,`recharge`],GAUGE_DEFAULTS={refuel:{cssColour:`var(--bng-orange-b400)`,gradientColour:`255,102,0`,icon:icons.fuelPumpFilling},recharge:{cssColour:`var(--bng-add-blue-600)`,gradientColour:`95,157,249`,icon:icons.charging}},_sfc_main$21={__name:`FuelGauge`,props:{value:{type:Number,default:0},type:{type:String,default:`refuel`,validator:v=>GAUGE_TYPES.includes(v)||v===``},fuelling:{type:Boolean,default:!1},label:String,maxLabel:String,minLabel:String},setup(__props){window.bngVue.isProd;let props=__props,gaugeLevelStyle=computed(()=>({stroke:GAUGE_DEFAULTS[props.type].cssColour,fill:`none`,strokeDasharray:DASH_ARR_LENGTH,strokeDashoffset:DASH_ARR_LENGTH-props.value*DASH_ARR_LENGTH})),gaugeStyle=computed(()=>({background:`radial-gradient(22% 22% at 50% 53%, rgba(${GAUGE_DEFAULTS[props.type].gradientColour}, 0.76) 0%, rgba(${GAUGE_DEFAULTS[props.type].gradientColour}, 0.18) 64.06%, rgba(${GAUGE_DEFAULTS[props.type].gradientColour}, 0) 100%)`}));return(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,{class:normalizeClass({"gauge-wrapper":!0,[__props.type]:!0})},[createBaseVNode(`div`,{class:normalizeClass({"pulse-container":!0,pulsing:__props.fuelling})},[createBaseVNode(`div`,{class:`pulser`,style:normalizeStyle(gaugeStyle.value)},null,4)],2),(openBlock(),createElementBlock(`svg`,_hoisted_1$17,[createBaseVNode(`defs`,null,[createBaseVNode(`filter`,_hoisted_2$11,[createBaseVNode(`feFlood`,{"flood-color":GAUGE_DEFAULTS[__props.type].cssColour,result:`flood1`},null,8,_hoisted_3$10),_cache[0]||=createStaticVNode(``,4)])]),_cache[1]||=createBaseVNode(`path`,{class:`gauge-back`,d:`M50,210 A110,110 0 1,1 244,210`,style:{fill:`none`}},null,-1),createBaseVNode(`path`,{class:`gauge-level blur`,d:`M50,210 A110,110 0 1,1 244,210`,style:normalizeStyle(gaugeLevelStyle.value)},null,4),createBaseVNode(`path`,{class:`gauge-level`,d:`M50,210 A110,110 0 1,1 244,210`,style:normalizeStyle(gaugeLevelStyle.value)},null,4)])),createVNode(unref(bngIcon_default),{class:`icon refill-icon`,type:GAUGE_DEFAULTS[__props.type].icon,color:`#fff`},null,8,[`type`]),createBaseVNode(`div`,_hoisted_4$7,[createBaseVNode(`span`,null,toDisplayString(__props.minLabel),1),createBaseVNode(`span`,_hoisted_5$6,toDisplayString(__props.label||`\xA0`),1),createBaseVNode(`span`,null,toDisplayString(__props.maxLabel),1)])],2))}},FuelGauge_default=__plugin_vue_export_helper_default(_sfc_main$21,[[`__scopeId`,`data-v-04de51fb`]]),_hoisted_1$16={class:`fuel-type`},_sfc_main$20={__name:`FuelTypeSettings`,props:{fuelOptions:{type:Array,required:!0}},emits:[`previousClick`,`nextClick`,`fuelTypeSelect`],setup(__props,{emit:__emit}){let emit$1=__emit;return(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$16,[createVNode(unref(bngButton_default),{class:`arrow empty`,accent:unref(ACCENTS).text,"data-testid":`previous-btn`,icon:unref(icons).arrowLargeLeft,onClick:_cache[0]||=$event=>emit$1(`previousClick`)},{default:withCtx(()=>[createVNode(unref(bngBinding_default),{class:`controller`,"ui-event":`tab_l`,deviceMask:`xinput`})]),_:1},8,[`accent`,`icon`]),createVNode(unref(bngPillFilters_default),{options:__props.fuelOptions},null,8,[`options`]),createVNode(unref(bngButton_default),{class:`arrow empty`,accent:unref(ACCENTS).text,"data-testid":`next-btn`,iconRight:unref(icons).arrowLargeRight,onClick:_cache[1]||=$event=>emit$1(`nextClick`)},{default:withCtx(()=>[createVNode(unref(bngBinding_default),{class:`controller`,"ui-event":`tab_r`,deviceMask:`xinput`})]),_:1},8,[`accent`,`iconRight`])]))}},FuelTypeSettings_default=__plugin_vue_export_helper_default(_sfc_main$20,[[`__scopeId`,`data-v-bf968fb2`]]),nozzleModes={on:{color:`var(--bng-orange-b400)`,buttonEnabled:!0},off:{color:`var(--bng-black-o6)`,buttonEnabled:!0},disabled:{color:`var(--bng-black-o2)`,buttonEnabled:!1}},fuellingModes$1={fuel:{nozzleIconType:icons$1.general.fuel_nozzle},charge:{nozzleIconType:icons$1.general.recharge_connector}},_sfc_main$19={__name:`FuelNozzle`,props:{refuelType:{type:String,required:!0},nozzleMode:{type:String,default:`off`}},emits:[`triggerDown`,`triggerUp`],setup(__props,{emit:__emit}){let{showIfController}=storeToRefs(controls_default()),props=__props,emit$1=__emit,nozzleImageURL=computed(()=>`icons/${typeSettings.value.nozzleIconType}.svg`),typeSettings=computed(()=>fuellingModes$1[props.refuelType]),modeSettings=computed(()=>nozzleModes[props.nozzleMode]),nozzleClass=computed(()=>({nozzle:!0,[props.refuelType]:!0}));return(_ctx,_cache)=>(openBlock(),createBlock(unref(bngImageAsset_default),{mask:``,class:normalizeClass(nozzleClass.value),src:nozzleImageURL.value,"bg-color":modeSettings.value.color},{default:withCtx(()=>[createVNode(unref(bngButton_default),{"bng-no-nav":`true`,class:normalizeClass({empty:!0,gamepad:unref(showIfController)}),disabled:!modeSettings.value.buttonEnabled,onMousedown:_cache[0]||=$event=>emit$1(`triggerDown`),onMouseup:_cache[1]||=$event=>emit$1(`triggerUp`),accent:unref(ACCENTS).text},{default:withCtx(()=>[createVNode(unref(bngBinding_default),{action:`fuelVehicle`,deviceMask:`xinput`,disabled:!modeSettings.value.buttonEnabled,accent:unref(ACCENTS).text},null,8,[`disabled`,`accent`]),unref(showIfController)?createCommentVNode(``,!0):(openBlock(),createBlock(unref(bngIcon_default),{key:0,type:unref(icons).plus,title:`Activate`},null,8,[`type`]))]),_:1},8,[`class`,`disabled`,`accent`])]),_:1},8,[`class`,`src`,`bg-color`]))}},FuelNozzle_default=__plugin_vue_export_helper_default(_sfc_main$19,[[`__scopeId`,`data-v-3a31f67d`]]),_hoisted_1$15={class:`cost`},_hoisted_2$10={class:`price`},_hoisted_3$9={class:`per-unit`},_hoisted_4$6={class:`value`},_hoisted_5$5={class:`unit`},_sfc_main$18={__name:`FuelInfo`,props:{totalCost:{type:Number,required:!0},pricePerUnit:{type:Number,required:!0},unitLabel:{type:String,required:!0},fuelDiscountData:{type:Object,required:!1}},setup(__props){let refuelStore=useRefuelStore(),displayPrice=computed(()=>Math.floor(refuelStore.convertToPricePerLocalUnit(props.pricePerUnit,refuelStore.currentEnergyType)*100)+.9),props=__props;return(_ctx,_cache)=>(openBlock(),createElementBlock(Fragment,null,[createBaseVNode(`div`,_hoisted_1$15,[createVNode(unref(bngUnit_default),{money:__props.totalCost},null,8,[`money`]),__props.fuelDiscountData.hasFuelDiscount?(openBlock(),createBlock(insurancePerkIcon_default,{key:0,class:`perk-icon`,perkIconData:__props.fuelDiscountData.perkData},null,8,[`perkIconData`])):createCommentVNode(``,!0)]),createBaseVNode(`div`,_hoisted_2$10,[createBaseVNode(`span`,_hoisted_3$9,[createBaseVNode(`span`,_hoisted_4$6,toDisplayString(displayPrice.value),1),_cache[0]||=createBaseVNode(`span`,{class:`divider`},null,-1),createBaseVNode(`span`,_hoisted_5$5,toDisplayString(unref(refuelStore).getUnitLabel(unref(refuelStore).currentEnergyType)),1)])])],64))}},FuelInfo_default=__plugin_vue_export_helper_default(_sfc_main$18,[[`__scopeId`,`data-v-c4955aba`]]),_hoisted_1$14={class:`amount`},_hoisted_2$9={class:`slider-labels`},_hoisted_3$8={class:`amount-value`},_sfc_main$17={__name:`FuelAmountSettings`,props:{minSlider:{type:Number,default:23},maxSlider:{type:Number,default:80},unitLabel:String},setup(__props){return(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$14,[createVNode(unref(bngButton_default),{class:`top-up`,accent:`text`},{default:withCtx(()=>[createVNode(unref(bngBinding_default),{class:`controller`,"ui-event":`focus_u`,deviceMask:`xinput`}),_cache[0]||=createTextVNode(`Top-up`,-1)]),_:1}),createBaseVNode(`div`,_hoisted_2$9,[createBaseVNode(`span`,null,toDisplayString(`${__props.minSlider}${__props.unitLabel}`),1),createBaseVNode(`span`,null,toDisplayString(`${__props.maxSlider}${__props.unitLabel}`),1)]),createVNode(unref(bngSlider_default),{min:__props.minSlider,max:__props.maxSlider,onValueChanged:()=>{}},null,8,[`min`,`max`]),createBaseVNode(`div`,_hoisted_3$8,[createVNode(unref(bngButton_default),{accent:unref(ACCENTS).text,class:`empty`},{default:withCtx(()=>[createVNode(unref(bngBinding_default),{class:`controller`,"ui-event":`focus_l`,deviceMask:`xinput`})]),_:1},8,[`accent`]),createVNode(unref(bngInput_default),{class:`value`,suffix:`L`,"initial-value":`1234567`}),createVNode(unref(bngButton_default),{accent:unref(ACCENTS).text,class:`empty`},{default:withCtx(()=>[createVNode(unref(bngBinding_default),{class:`controller`,"ui-event":`focus_r`,deviceMask:`xinput`})]),_:1},8,[`accent`])])]))}},FuelAmountSettings_default=__plugin_vue_export_helper_default(_sfc_main$17,[[`__scopeId`,`data-v-9de32e0e`]]),_hoisted_1$13={class:`gauge`},_hoisted_2$8={key:0,class:`settings content`},_hoisted_3$7={class:`status-container`},fuellingModes={fuel:{title:`ui.career.refuelling.modes.fuel.title`,gaugeType:`refuel`,nozzleIconType:icons$1.general.fuel_nozzle,fuellingOngoingLabel:`ui.career.refuelling.modes.fuel.ongoing`,startLabel:`ui.career.refuelling.modes.fuel.start`,unitLabel:`L`},charge:{title:`ui.career.refuelling.modes.charge.title`,gaugeType:`recharge`,nozzleIconType:icons$1.general.recharge_connector,fuellingOngoingLabel:`ui.career.refuelling.modes.charge.ongoing`,startLabel:`ui.career.refuelling.modes.charge.start`,unitLabel:`kWh`}},_sfc_main$16={__name:`RefuelMain`,setup(__props){let{$game}=useLibStore(),refuelStore=useRefuelStore(),mainSettings=computed(()=>fuellingModes[refuelStore.currentFuelType]);onBeforeMount(()=>{refuelStore.requestFuelingData()}),onBeforeUnmount(()=>{refuelStore.cancelTransaction()}),onUnmounted(()=>{refuelStore.$dispose()});let store$1=useTasksStore();provide(`animationSettings`,{animate:!0,animateOnMount:!1,animateOnMountIntervalDelay:.2,animateOnEmptyIntervalDelay:.1,animateOnEmpty:!0,animateNextTask:!0,successCallback:playAudio});function playAudio(){$game.lua.Engine.Audio.playOnce(`AudioGui`,`event:>UI>Career>Checkbox`)}return(_ctx,_cache)=>(openBlock(),createElementBlock(Fragment,null,[unref(refuelStore).currentFuelData?(openBlock(),createBlock(unref(layoutSingle_default),{key:0},{default:withCtx(()=>[createVNode(unref(bngCard_default),{class:`refuel-card`},{buttons:withCtx(()=>[unref(refuelStore).canPay?(openBlock(),createBlock(unref(bngButton_default),{key:0,onClick:_cache[2]||=$event=>unref(refuelStore).payPrice()},{default:withCtx(()=>[..._cache[5]||=[createTextVNode(`Pay`,-1)]]),_:1})):createCommentVNode(``,!0),unref(refuelStore).canStartFuelling?(openBlock(),createBlock(unref(bngButton_default),{key:1,onClick:_cache[3]||=$event=>unref(refuelStore).startFuelling()},{default:withCtx(()=>[createTextVNode(toDisplayString(_ctx.$t(mainSettings.value.startLabel)),1)]),_:1})):unref(refuelStore).canStopFuelling?(openBlock(),createBlock(unref(bngButton_default),{key:2,onClick:_cache[4]||=$event=>unref(refuelStore).stopFuelling()},{default:withCtx(()=>[..._cache[6]||=[createTextVNode(`Stop`,-1)]]),_:1})):createCommentVNode(``,!0)]),default:withCtx(()=>[createVNode(unref(bngCardHeading_default),{type:`ribbon`},{default:withCtx(()=>[createTextVNode(toDisplayString(_ctx.$t(unref(refuelStore).gasStationName)),1)]),_:1}),createBaseVNode(`div`,_hoisted_1$13,[createVNode(FuelGauge_default,{class:`main-gauge`,fuelling:unref(refuelStore).isFuelling,type:mainSettings.value.gaugeType,value:unref(refuelStore).currentFuelLevel,label:unref(refuelStore).isFuelling?_ctx.$t(mainSettings.value.fuellingOngoingLabel):``,minLabel:unref(refuelStore).minEnergyLabel,maxLabel:unref(refuelStore).maxEnergyLabel},null,8,[`fuelling`,`type`,`value`,`label`,`minLabel`,`maxLabel`])]),createVNode(FuelNozzle_default,{"refuel-type":unref(refuelStore).currentFuelType,"nozzle-mode":unref(refuelStore).nozzleMode,onTriggerDown:_cache[0]||=$event=>unref(refuelStore).changeFlowRate(1),onTriggerUp:_cache[1]||=$event=>unref(refuelStore).changeFlowRate(0)},null,8,[`refuel-type`,`nozzle-mode`]),createVNode(FuelInfo_default,{"total-cost":unref(refuelStore).overallPrice,"price-per-unit":unref(refuelStore).currentFuelData.pricePerUnit,"unit-label":mainSettings.value.unitLabel,"fuel-discount-data":unref(refuelStore).fuelDiscountData},null,8,[`total-cost`,`price-per-unit`,`unit-label`,`fuel-discount-data`]),unref(refuelStore).showFuelTypeSettings||unref(refuelStore).showAmountSettings?(openBlock(),createElementBlock(`div`,_hoisted_2$8,[unref(refuelStore).showFuelTypeSettings?(openBlock(),createBlock(FuelTypeSettings_default,{key:0,"fuel-options":unref(refuelStore).fuelOptions},null,8,[`fuel-options`])):createCommentVNode(``,!0),unref(refuelStore).showAmountSettings?(openBlock(),createBlock(FuelAmountSettings_default,{key:1,"min-slider":unref(refuelStore).minSlider,"max-slider":unref(refuelStore).maxSlider,"unit-label":mainSettings.value.unitLabel},null,8,[`min-slider`,`max-slider`,`unit-label`])):createCommentVNode(``,!0)])):createCommentVNode(``,!0)]),_:1})]),_:1})):createCommentVNode(``,!0),createBaseVNode(`div`,_hoisted_3$7,[createVNode(unref(careerStatus_default),{class:`profileStatus`}),createVNode(unref(TaskList_default),{class:`tasklist`,header:unref(store$1).header,tasks:unref(store$1).tasks},null,8,[`header`,`tasks`])])],64))}},RefuelMain_default=__plugin_vue_export_helper_default(_sfc_main$16,[[`__scopeId`,`data-v-d87fd4e5`]]),routes_default$15=[{path:`/refueling`,name:`refueling`,component:RefuelMain_default,meta:{uiApps:{shown:!1}}}],_hoisted_1$12=[`innerHTML`],_sfc_main$15={__name:`ReleaseInfo`,setup(__props){useUINavScope(`releaseInfo`);let settings$1=useSettings(),parseDescription=descKey=>parse$1($translate.instant(descKey)),descriptionHtml=computed(()=>parseDescription(`ui.releaseInfo.description`)),onFinish=async()=>{backToMenu()},backToMenu=()=>window.bngVue.gotoAngularState(`menu.mainmenu`);return onMounted(async()=>{await settings$1.waitForData()}),(_ctx,_cache)=>withDirectives((openBlock(),createBlock(unref(WizardView_default),{title:`ui.releaseInfo.title`,preheadings:[`v.${unref(sysInfo_default).versionSimple}`],style:{"--wizard-height":`45rem`},"bng-ui-scope":`releaseInfo`,onWizardFinish:onFinish},{default:withCtx(()=>[createVNode(unref(WizardStep_default),{id:`releaseInfo`,title:`ui.releaseInfo.stepTitle`},{default:withCtx(()=>[createBaseVNode(`div`,{innerHTML:descriptionHtml.value},null,8,_hoisted_1$12)]),_:1})]),_:1},8,[`preheadings`])),[[unref(BngBlur_default)],[unref(BngOnUiNav_default),backToMenu,`menu,back`]])}},ReleaseInfo_default=_sfc_main$15,routes_default$16=[{name:`menu.release-info`,path:`/release-info`,component:ReleaseInfo_default,meta:{infoBar:{visible:!0,showSysInfo:!0},uiApps:{shown:!1}}}],_hoisted_1$11={class:`veh-debug`},_hoisted_2$7={class:`buttons`},_hoisted_3$6={class:`buttons`},_hoisted_4$5={class:`bng-short-select-item`},_hoisted_5$4={class:`label-width`},_hoisted_6$3={key:0},_hoisted_7$3={class:`parts-switch-label`},_hoisted_8$2={class:`control-row`},_hoisted_9$1={class:`control-label`},_hoisted_10={class:`control-row`},_hoisted_11={class:`control-label`},_hoisted_12={key:0},_hoisted_13={class:`control-row`},_hoisted_14={class:`control-label indented`},_hoisted_15={class:`control-group`},_hoisted_16={class:`control-row`},_hoisted_17={class:`control-label indented`},_hoisted_18={class:`control-group`},_hoisted_19={class:`control-row`},_hoisted_20={class:`control-label indented`},_hoisted_21={class:`control-row`},_hoisted_22={class:`control-label indented`},_hoisted_23={class:`control-row`},_hoisted_24={class:`control-label indented`},_hoisted_25={class:`control-group`},_hoisted_26={class:`control-row`},_hoisted_27={class:`control-label indented`},_hoisted_28={class:`control-group`},_hoisted_29={class:`control-row`},_hoisted_30={class:`control-label indented`},_hoisted_31={class:`control-group`},_hoisted_32={class:`control-row`},_hoisted_33={class:`control-label`},_hoisted_34={key:2},_hoisted_35={class:`control-row`},_hoisted_36={class:`control-label indented`},_hoisted_37={class:`control-group`},_hoisted_38={class:`control-row`},_hoisted_39={class:`control-label indented`},_hoisted_40={class:`control-group`},_hoisted_41={class:`control-row`},_hoisted_42={class:`control-label indented`},_hoisted_43={class:`control-row`},_hoisted_44={class:`control-label indented`},_hoisted_45={key:3,class:`control-row`},_hoisted_46={class:`control-label indented`},_hoisted_47={class:`control-group`},_hoisted_48={key:4,class:`control-row`},_hoisted_49={class:`control-label indented`},_hoisted_50={class:`control-row`},_hoisted_51={class:`control-label`},_hoisted_52={key:5},_hoisted_53={class:`control-row`},_hoisted_54={class:`control-label indented`},_hoisted_55={class:`control-group`},_hoisted_56={class:`control-row`},_hoisted_57={class:`control-label indented`},_hoisted_58={class:`control-group`},_hoisted_59={class:`control-row`},_hoisted_60={class:`control-label indented`},_hoisted_61={class:`control-row`},_hoisted_62={class:`control-label indented`},_hoisted_63={class:`control-row`},_hoisted_64={class:`control-label indented`},_hoisted_65={class:`control-group`},_hoisted_66={class:`control-row`},_hoisted_67={class:`control-label indented`},_hoisted_68={class:`control-group`},_hoisted_69={class:`control-row`},_hoisted_70={class:`control-label indented`},_hoisted_71={class:`control-group`},_hoisted_72={class:`control-row`},_hoisted_73={class:`control-label`},_hoisted_74={class:`control-row`},_hoisted_75={class:`control-label indented`},_hoisted_76={class:`control-group`},_hoisted_77={class:`control-row`},_hoisted_78={class:`control-label indented`},_hoisted_79={class:`control-group`},_hoisted_80={class:`control-row`},_hoisted_81={class:`control-label indented`},_hoisted_82={class:`control-row`},_hoisted_83={class:`control-label indented`},_hoisted_84={class:`control-row`},_hoisted_85={class:`control-label indented`},_hoisted_86={class:`control-group`},_hoisted_87={class:`control-row`},_hoisted_88={class:`control-label indented`},_hoisted_89={class:`control-group`},_hoisted_90={class:`control-row`},_hoisted_91={class:`control-label`},_hoisted_92={class:`control-row`},_hoisted_93={class:`control-label indented`},_hoisted_94={class:`control-group`},_hoisted_95={class:`control-row`},_hoisted_96={class:`control-label indented`},_hoisted_97={class:`control-group`},_hoisted_98={class:`control-row`},_hoisted_99={class:`control-label`},_hoisted_100={class:`control-row`},_hoisted_101={class:`control-label`},_hoisted_102={key:10,class:`control-row`},_hoisted_103={class:`control-label indented`},_hoisted_104={class:`control-group`},_hoisted_105={class:`control-row`},_hoisted_106={class:`control-label`},_hoisted_107={key:11,class:`control-row`},_hoisted_108={class:`control-label indented`},_hoisted_109={class:`control-group`},_hoisted_110={class:`control-row`},_hoisted_111={class:`control-label`},_hoisted_112={class:`control-row`},_hoisted_113={class:`control-label`},_hoisted_114={key:12,class:`control-row`},_hoisted_115={class:`control-label indented`},_hoisted_116={class:`control-group`},_hoisted_117={key:13,class:`control-row`},_hoisted_118={class:`control-label`},_hoisted_119={class:`mesh-visibility`},_hoisted_120={class:`control-row`},_hoisted_121={class:`control-label`},_hoisted_122={class:`mesh-buttons`},_hoisted_123={class:`buttons`},_sfc_main$14={__name:`Debug`,setup(__props){useUINavBlocker().blockOnly([`context`]);let{lua,api:api$1}=useBridge(),events$3=useEvents(),state=reactive({}),stateNoReset=reactive({vehicle:{parts:[],partNameToIdx:{},partsSelected:{},partsSelectedIdxs:[]}}),partsState=reactive({partsSorted:[],partsHighlightedIdxs:[]}),partsFiltered=computed(()=>{let res=partsState.partsSorted;return Array.isArray(res)?(partsSelectedSearchTerm.value&&(res=res.filter(part=>part.includes(partsSelectedSearchTerm.value))),res.map(p$1=>{let segments=p$1.split(`/`);return{label:segments[segments.length-1],reversePath:segments.slice(0,-1).reverse().join(`\\`),value:p$1,selected:Array.isArray(partsState.partsHighlightedIdxs)&&partsState.partsHighlightedIdxs.includes(partsState.partsSorted.indexOf(p$1)+1)}})):[]}),shipping=computed(()=>window.beamng&&window.beamng.shipping),geState=reactive({physicsEnabled:!0,debugSpawnEnabled:!1}),partsSelectedSearchTerm=ref(``),disableVehicleButtons=ref(!1),controls$1={vehicle:{buttonGroup_1:[{label:`ui.debug.vehicle.loadDefault`,action:()=>lua.core_vehicles.loadDefault()},{label:`ui.debug.vehicle.spawnNew`,action:()=>lua.core_vehicles.spawnDefault()},{label:`ui.debug.vehicle.removeCurrent`,action:()=>lua.core_vehicles.removeCurrent()},{label:`ui.debug.vehicle.cloneCurrent`,action:()=>lua.core_vehicles.cloneCurrent()},{label:`ui.debug.vehicle.removeAll`,action:()=>lua.core_vehicles.removeAll()},{label:`ui.debug.vehicle.removeOthers`,action:()=>lua.core_vehicles.removeAllExceptCurrent()},{label:`ui.debug.vehicle.resetAll`,action:()=>lua.resetGameplay(-1)},{label:`ui.debug.vehicle.reloadAll`,action:()=>lua.core_vehicle_manager.reloadAllVehicles()}],toggleGroup_1:[{label:`ui.debug.activatePhysics`,key:`physicsEnabled`,onChange:()=>lua.simTimeAuthority.togglePause()},{label:`ui.debug.debugSpawnEnabled`,key:`debugSpawnEnabled`,onChange:()=>lua.core_vehicle_manager.toggleDebug()}]},jbeamvis:{buttonGroup_1:[{label:`ui.debug.vehicle.toggleVis`,action:()=>api$1.activeObjectLua(`bdebug.toggleEnabled()`)},{label:`ui.debug.vehicle.clearSettings`,action:()=>api$1.activeObjectLua(`bdebug.resetModes()`)}],meshVisButtonGroup:[{label:`0%`,action:()=>lua.core_vehicles.setMeshVisibility(0)},{label:`25%`,action:()=>lua.core_vehicles.setMeshVisibility(.25)},{label:`50%`,action:()=>lua.core_vehicles.setMeshVisibility(.5)},{label:`75%`,action:()=>lua.core_vehicles.setMeshVisibility(.75)},{label:`100%`,action:()=>lua.core_vehicles.setMeshVisibility(1)}]},terrain:{buttonGroup_1:[{label:`ui.debug.terrain.groundmodel`,action:()=>api$1.engineLua(`extensions.load("util_groundModelDebug") util_groundModelDebug.openWindow()`)}]}};onMounted(async()=>{geState.physicsEnabled=!await lua.simTimeAuthority.getPause(),geState.debugSpawnEnabled=await lua.core_vehicle_manager.getDebug(),api$1.activeObjectLua(`bdebug.requestState()`),lua.core_gamestate.requestGameState(),lua.extensions.core_vehicle_partmgmt.sendPartsSelectorStateToUI()});let applyState=(notSendBack=!1)=>{notSendBack=!!notSendBack,api$1.activeObjectLua(`bdebug.setState(${api$1.serializeToLua(state)}, ${api$1.serializeToLua(stateNoReset)}, ${notSendBack})`)},partsSelectedChanged=(part,value)=>{Array.isArray(partsState.partsHighlightedIdxs)||(partsState.partsHighlightedIdxs=[]);let idx=partsState.partsSorted.indexOf(part)+1,idxInArray=partsState.partsHighlightedIdxs.indexOf(idx);value&&idxInArray===-1?partsState.partsHighlightedIdxs.push(idx):!value&&idxInArray!==-1&&partsState.partsHighlightedIdxs.splice(idxInArray,1),applyState(!0),lua.extensions.core_vehicle_partmgmt.partsSelectorChanged(partsState)},partsSelectedChecked=()=>partsState.partsHighlightedIdxs.length===partsState.partsSorted.length,partsSelectedIndeterminate=()=>partsState.partsHighlightedIdxs.length!==0&&partsState.partsHighlightedIdxs.length!==partsState.partsSorted.length,partsSelectedClicked=()=>{partsState.partsHighlightedIdxs.length===partsState.partsSorted.length?partsState.partsHighlightedIdxs=[]:partsState.partsHighlightedIdxs=Array.from({length:partsState.partsSorted.length},(_,i)=>i+1),applyState(),lua.extensions.core_vehicle_partmgmt.partsSelectorChanged(partsState)},selectAllParts=computed({get:()=>partsSelectedChecked(),set:()=>partsSelectedClicked()}),beamTextModeItems=computed(()=>state.vehicle?.beamTextModes?state.vehicle.beamTextModes.map((mode,index)=>({value:index+1,label:mode.name?$translate.instant(`vehicle.bdebug.beamTextMode.${mode.name}`):``})):[]),beamVisModeItems=computed(()=>state.vehicle?.beamVisModes?state.vehicle.beamVisModes.map((mode,index)=>({value:index+1,label:mode.name?$translate.instant(`vehicle.bdebug.beamVisMode.${mode.name}`):``})):[]),currentBeamVisMode=computed(()=>state.vehicle?.beamVisModes?state.vehicle.beamVisModes[state.vehicle.beamVisMode-1]:null),nodeTextModeItems=computed(()=>state.vehicle?.nodeTextModes?state.vehicle.nodeTextModes.map((mode,index)=>({value:index+1,label:mode.name?$translate.instant(`vehicle.bdebug.nodeTextMode.${mode.name}`):``})):[]),currentNodeTextMode=computed(()=>state.vehicle?.nodeTextModes?state.vehicle.nodeTextModes[state.vehicle.nodeTextMode-1]:null),nodeVisModeItems=computed(()=>state.vehicle?.nodeVisModes?state.vehicle.nodeVisModes.map((mode,index)=>({value:index+1,label:mode.name?$translate.instant(`vehicle.bdebug.nodeVisMode.${mode.name}`):``})):[]),currentNodeVisMode=computed(()=>state.vehicle?.nodeVisModes?state.vehicle.nodeVisModes[state.vehicle.nodeVisMode-1]:null),torsionBarVisModeItems=computed(()=>state.vehicle?.torsionBarVisModes?state.vehicle.torsionBarVisModes.map((mode,index)=>({value:index+1,label:mode.name?$translate.instant(`vehicle.bdebug.torsionBarVisMode.${mode.name}`):``})):[]),currentTorsionBarVisMode=computed(()=>state.vehicle?.torsionBarVisModes?state.vehicle.torsionBarVisModes[state.vehicle.torsionBarVisMode-1]:null),railsSlideNodesModeItems=computed(()=>state.vehicle?.railsSlideNodesVisModes?state.vehicle.railsSlideNodesVisModes.map((mode,index)=>({value:index+1,label:mode.name?$translate.instant(`vehicle.bdebug.railsSlideNodesVisMode.${mode.name}`):``})):[]),cogModeItems=computed(()=>state.vehicle?.cogModes?state.vehicle.cogModes.map((mode,index)=>({value:index+1,label:mode.name?$translate.instant(`vehicle.bdebug.cogMode.${mode.name}`):``})):[]),collisionTriangleModeItems=computed(()=>state.vehicle?.collisionTriangleVisModes?state.vehicle.collisionTriangleVisModes.map((mode,index)=>({value:index+1,label:mode.name?$translate.instant(`vehicle.bdebug.collisionTriangleVisMode.${mode.name}`):``})):[]),aeroModeItems=computed(()=>state.vehicle?.aeroModes?state.vehicle.aeroModes.map((mode,index)=>({value:index+1,label:mode.name?$translate.instant(`vehicle.bdebug.aeroMode.${mode.name}`):``})):[]);return events$3.on(`BdebugUpdate`,(debugState,newStateNoReset)=>{Object.assign(state,debugState),Object.assign(stateNoReset,newStateNoReset)}),events$3.on(`PartsSelectorUpdate`,state$1=>{Object.assign(partsState,state$1)}),events$3.on(`VehicleFocusChanged`,()=>{api$1.activeObjectLua(`bdebug.requestState()`),lua.extensions.core_vehicle_partmgmt.sendPartsSelectorStateToUI()}),events$3.on(`physicsStateChanged`,state$1=>geState.physicsEnabled=!!state$1),events$3.on(`debugSpawnChanged`,state$1=>geState.debugSpawnEnabled=!!state$1),events$3.on(`GameStateUpdate`,gamestate=>disableVehicleButtons.value=gamestate.state.toLowerCase().indexOf(`scenario`)>-1),(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$11,[createBaseVNode(`h3`,null,toDisplayString(_ctx.$tt(`ui.debug.vehicle`)),1),(openBlock(!0),createElementBlock(Fragment,null,renderList(controls$1.vehicle.toggleGroup_1,toggle=>(openBlock(),createElementBlock(`div`,{key:toggle.key},[createVNode(unref(bngSwitch_default),{modelValue:geState[toggle.key],"onUpdate:modelValue":$event=>geState[toggle.key]=$event,onValueChanged:$event=>toggle.onChange()},{default:withCtx(()=>[createTextVNode(toDisplayString(_ctx.$tt(toggle.label)),1)]),_:2},1032,[`modelValue`,`onUpdate:modelValue`,`onValueChanged`])]))),128)),createBaseVNode(`div`,_hoisted_2$7,[(openBlock(!0),createElementBlock(Fragment,null,renderList(controls$1.vehicle.buttonGroup_1,btn=>(openBlock(),createBlock(unref(bngButton_default),{key:btn.label,onClick:$event=>btn.action(),disabled:disableVehicleButtons.value,accent:unref(ACCENTS).secondary},{default:withCtx(()=>[createTextVNode(toDisplayString(_ctx.$tt(btn.label)),1)]),_:2},1032,[`onClick`,`disabled`,`accent`]))),128))]),_cache[74]||=createBaseVNode(`hr`,null,null,-1),createBaseVNode(`h4`,null,toDisplayString(_ctx.$tt(`ui.debug.vehicle.jbeamVis`)),1),createBaseVNode(`div`,_hoisted_3$6,[(openBlock(!0),createElementBlock(Fragment,null,renderList(controls$1.jbeamvis.buttonGroup_1,btn=>(openBlock(),createBlock(unref(bngButton_default),{key:btn.label,onClick:$event=>btn.action(),accent:unref(ACCENTS).secondary},{default:withCtx(()=>[createTextVNode(toDisplayString(_ctx.$tt(btn.label)),1)]),_:2},1032,[`onClick`,`accent`]))),128))]),createBaseVNode(`div`,_hoisted_4$5,[createBaseVNode(`span`,_hoisted_5$4,toDisplayString(_ctx.$tt(`ui.debug.vehicle.partsSelected`)),1),createVNode(unref(bngDropdownContainer_default),{class:`bng-select-fullwidth dropdown-width`},{default:withCtx(()=>[createVNode(unref(bngList_default),{layout:unref(LIST_LAYOUTS).LIST,"target-width":31},{default:withCtx(()=>[createVNode(unref(bngInput_default),{modelValue:partsSelectedSearchTerm.value,"onUpdate:modelValue":_cache[0]||=$event=>partsSelectedSearchTerm.value=$event,modelModifiers:{trim:!0},"floating-label":_ctx.$t(`ui.debug.vehicle.partsSelectedSearchText`)},null,8,[`modelValue`,`floating-label`]),partsFiltered.value&&partsFiltered.value.length>0?(openBlock(),createElementBlock(`div`,_hoisted_6$3,[(openBlock(!0),createElementBlock(Fragment,null,renderList(partsFiltered.value,part=>withDirectives((openBlock(),createBlock(unref(bngSwitch_default),{"model-value":part.selected,key:part.value,"label-alignment":unref(LABEL_ALIGNMENTS).START,inline:!1,class:`parts-switch`,onChange:value=>partsSelectedChanged(part.value,value)},{default:withCtx(()=>[createBaseVNode(`span`,_hoisted_7$3,[createBaseVNode(`strong`,null,toDisplayString(part.label),1),createTextVNode(` `+toDisplayString(part.reversePath?`\\`+part.reversePath:``),1)])]),_:2},1032,[`model-value`,`label-alignment`,`onChange`])),[[unref(BngTooltip_default),part.label+` \\ `+part.reversePath,`right`]])),128))])):createCommentVNode(``,!0)]),_:1},8,[`layout`])]),_:1}),createVNode(unref(bngSwitch_default),{modelValue:selectAllParts.value,"onUpdate:modelValue":_cache[1]||=$event=>selectAllParts.value=$event,class:normalizeClass({"switch-indeterminate":partsSelectedIndeterminate(),"switch-width":!0}),onOnClicked:partsSelectedClicked},null,8,[`modelValue`,`class`])]),state.vehicle?(openBlock(),createElementBlock(Fragment,{key:0},[createBaseVNode(`div`,_hoisted_8$2,[createBaseVNode(`span`,_hoisted_9$1,toDisplayString(_ctx.$tt(`ui.debug.vehicle.beamText`)),1),createVNode(unref(bngDropdown_default),{modelValue:state.vehicle.beamTextMode,"onUpdate:modelValue":_cache[2]||=$event=>state.vehicle.beamTextMode=$event,items:beamTextModeItems.value,onValueChanged:applyState,class:`control-input`},null,8,[`modelValue`,`items`])]),createBaseVNode(`div`,_hoisted_10,[createBaseVNode(`span`,_hoisted_11,toDisplayString(_ctx.$tt(`ui.debug.vehicle.beamVis`)),1),createVNode(unref(bngDropdown_default),{modelValue:state.vehicle.beamVisMode,"onUpdate:modelValue":_cache[3]||=$event=>state.vehicle.beamVisMode=$event,items:beamVisModeItems.value,onValueChanged:applyState,class:`control-input`},null,8,[`modelValue`,`items`])]),currentBeamVisMode.value&¤tBeamVisMode.value.usesRange?(openBlock(),createElementBlock(`div`,_hoisted_12,[createBaseVNode(`div`,_hoisted_13,[createBaseVNode(`span`,_hoisted_14,toDisplayString(_ctx.$tt(`ui.debug.vehicle.visRangeMin`)),1),createBaseVNode(`div`,_hoisted_15,[createVNode(unref(bngSlider_default),{modelValue:currentBeamVisMode.value.rangeMin,"onUpdate:modelValue":_cache[4]||=$event=>currentBeamVisMode.value.rangeMin=$event,min:currentBeamVisMode.value.rangeMinCap,max:currentBeamVisMode.value.rangeMaxCap,step:(currentBeamVisMode.value.rangeMaxCap-currentBeamVisMode.value.rangeMinCap)/100,onValueChanged:applyState},null,8,[`modelValue`,`min`,`max`,`step`]),createVNode(unref(bngInput_default),{modelValue:currentBeamVisMode.value.rangeMin,"onUpdate:modelValue":_cache[5]||=$event=>currentBeamVisMode.value.rangeMin=$event,type:`number`,min:currentBeamVisMode.value.rangeMinCap,max:currentBeamVisMode.value.rangeMaxCap,step:(currentBeamVisMode.value.rangeMaxCap-currentBeamVisMode.value.rangeMinCap)/1e3,onValueChanged:applyState},null,8,[`modelValue`,`min`,`max`,`step`]),createVNode(unref(bngSwitch_default),{modelValue:currentBeamVisMode.value.rangeMinEnabled,"onUpdate:modelValue":_cache[6]||=$event=>currentBeamVisMode.value.rangeMinEnabled=$event,onValueChanged:applyState},null,8,[`modelValue`])])]),createBaseVNode(`div`,_hoisted_16,[createBaseVNode(`span`,_hoisted_17,toDisplayString(_ctx.$tt(`ui.debug.vehicle.visRangeMax`)),1),createBaseVNode(`div`,_hoisted_18,[createVNode(unref(bngSlider_default),{modelValue:currentBeamVisMode.value.rangeMax,"onUpdate:modelValue":_cache[7]||=$event=>currentBeamVisMode.value.rangeMax=$event,min:currentBeamVisMode.value.rangeMinCap,max:currentBeamVisMode.value.rangeMaxCap,step:(currentBeamVisMode.value.rangeMaxCap-currentBeamVisMode.value.rangeMinCap)/100,onValueChanged:applyState},null,8,[`modelValue`,`min`,`max`,`step`]),createVNode(unref(bngInput_default),{modelValue:currentBeamVisMode.value.rangeMax,"onUpdate:modelValue":_cache[8]||=$event=>currentBeamVisMode.value.rangeMax=$event,type:`number`,min:currentBeamVisMode.value.rangeMinCap,max:currentBeamVisMode.value.rangeMaxCap,step:(currentBeamVisMode.value.rangeMaxCap-currentBeamVisMode.value.rangeMinCap)/1e3,onValueChanged:applyState},null,8,[`modelValue`,`min`,`max`,`step`]),createVNode(unref(bngSwitch_default),{modelValue:currentBeamVisMode.value.rangeMaxEnabled,"onUpdate:modelValue":_cache[9]||=$event=>currentBeamVisMode.value.rangeMaxEnabled=$event,onValueChanged:applyState},null,8,[`modelValue`])])]),createBaseVNode(`div`,_hoisted_19,[createBaseVNode(`span`,_hoisted_20,toDisplayString(_ctx.$tt(`ui.debug.vehicle.useInclusiveRange`)),1),createVNode(unref(bngSwitch_default),{modelValue:currentBeamVisMode.value.usesInclusiveRange,"onUpdate:modelValue":_cache[10]||=$event=>currentBeamVisMode.value.usesInclusiveRange=$event,onValueChanged:applyState},null,8,[`modelValue`])]),createBaseVNode(`div`,_hoisted_21,[createBaseVNode(`span`,_hoisted_22,toDisplayString(_ctx.$tt(`ui.debug.vehicle.showInf`)),1),createVNode(unref(bngSwitch_default),{modelValue:currentBeamVisMode.value.showInfinity,"onUpdate:modelValue":_cache[11]||=$event=>currentBeamVisMode.value.showInfinity=$event,onValueChanged:applyState},null,8,[`modelValue`])])])):createCommentVNode(``,!0),state.vehicle.beamVisMode===1?createCommentVNode(``,!0):(openBlock(),createElementBlock(Fragment,{key:1},[createBaseVNode(`div`,_hoisted_23,[createBaseVNode(`span`,_hoisted_24,toDisplayString(_ctx.$tt(`ui.debug.vehicle.showHighlighted`)),1),createBaseVNode(`div`,_hoisted_25,[createVNode(unref(bngSwitch_default),{modelValue:state.vehicle.beamVisShowHighlighted,"onUpdate:modelValue":_cache[12]||=$event=>state.vehicle.beamVisShowHighlighted=$event,disabled:state.vehicle.beamVisMode===3,onValueChanged:applyState},null,8,[`modelValue`,`disabled`])])]),createBaseVNode(`div`,_hoisted_26,[createBaseVNode(`span`,_hoisted_27,toDisplayString(_ctx.$tt(`ui.debug.vehicle.width`)),1),createBaseVNode(`div`,_hoisted_28,[createVNode(unref(bngSlider_default),{modelValue:state.vehicle.beamVisWidthScale,"onUpdate:modelValue":_cache[13]||=$event=>state.vehicle.beamVisWidthScale=$event,min:.1,max:5,step:.1,onValueChanged:applyState},null,8,[`modelValue`]),createVNode(unref(bngInput_default),{modelValue:state.vehicle.beamVisWidthScale,"onUpdate:modelValue":_cache[14]||=$event=>state.vehicle.beamVisWidthScale=$event,type:`number`,min:.1,max:5,step:.1,onValueChanged:applyState},null,8,[`modelValue`])])]),createBaseVNode(`div`,_hoisted_29,[createBaseVNode(`span`,_hoisted_30,toDisplayString(_ctx.$tt(`ui.debug.vehicle.transparency`)),1),createBaseVNode(`div`,_hoisted_31,[createVNode(unref(bngSlider_default),{modelValue:state.vehicle.beamVisAlpha,"onUpdate:modelValue":_cache[15]||=$event=>state.vehicle.beamVisAlpha=$event,min:0,max:1,step:.01,onValueChanged:applyState},null,8,[`modelValue`]),createVNode(unref(bngInput_default),{modelValue:state.vehicle.beamVisAlpha,"onUpdate:modelValue":_cache[16]||=$event=>state.vehicle.beamVisAlpha=$event,type:`number`,min:0,max:1,step:.01,onValueChanged:applyState},null,8,[`modelValue`])])])],64)),createBaseVNode(`div`,_hoisted_32,[createBaseVNode(`span`,_hoisted_33,toDisplayString(_ctx.$tt(`ui.debug.vehicle.nodeText`)),1),createVNode(unref(bngDropdown_default),{modelValue:state.vehicle.nodeTextMode,"onUpdate:modelValue":_cache[17]||=$event=>state.vehicle.nodeTextMode=$event,items:nodeTextModeItems.value,onValueChanged:applyState,class:`control-input`},null,8,[`modelValue`,`items`])]),currentNodeTextMode.value&¤tNodeTextMode.value.usesRange?(openBlock(),createElementBlock(`div`,_hoisted_34,[createBaseVNode(`div`,_hoisted_35,[createBaseVNode(`span`,_hoisted_36,toDisplayString(_ctx.$tt(`ui.debug.vehicle.visRangeMin`)),1),createBaseVNode(`div`,_hoisted_37,[createVNode(unref(bngSlider_default),{modelValue:currentNodeTextMode.value.rangeMin,"onUpdate:modelValue":_cache[18]||=$event=>currentNodeTextMode.value.rangeMin=$event,min:currentNodeTextMode.value.rangeMinCap,max:currentNodeTextMode.value.rangeMaxCap,step:(currentNodeTextMode.value.rangeMaxCap-currentNodeTextMode.value.rangeMinCap)/100,onValueChanged:applyState},null,8,[`modelValue`,`min`,`max`,`step`]),createVNode(unref(bngInput_default),{modelValue:currentNodeTextMode.value.rangeMin,"onUpdate:modelValue":_cache[19]||=$event=>currentNodeTextMode.value.rangeMin=$event,type:`number`,min:currentNodeTextMode.value.rangeMinCap,max:currentNodeTextMode.value.rangeMaxCap,step:(currentNodeTextMode.value.rangeMaxCap-currentNodeTextMode.value.rangeMinCap)/1e3,onValueChanged:applyState},null,8,[`modelValue`,`min`,`max`,`step`]),createVNode(unref(bngSwitch_default),{modelValue:currentNodeTextMode.value.rangeMinEnabled,"onUpdate:modelValue":_cache[20]||=$event=>currentNodeTextMode.value.rangeMinEnabled=$event,onValueChanged:applyState},null,8,[`modelValue`])])]),createBaseVNode(`div`,_hoisted_38,[createBaseVNode(`span`,_hoisted_39,toDisplayString(_ctx.$tt(`ui.debug.vehicle.visRangeMax`)),1),createBaseVNode(`div`,_hoisted_40,[createVNode(unref(bngSlider_default),{modelValue:currentNodeTextMode.value.rangeMax,"onUpdate:modelValue":_cache[21]||=$event=>currentNodeTextMode.value.rangeMax=$event,min:currentNodeTextMode.value.rangeMinCap,max:currentNodeTextMode.value.rangeMaxCap,step:(currentNodeTextMode.value.rangeMaxCap-currentNodeTextMode.value.rangeMinCap)/100,onValueChanged:applyState},null,8,[`modelValue`,`min`,`max`,`step`]),createVNode(unref(bngInput_default),{modelValue:currentNodeTextMode.value.rangeMax,"onUpdate:modelValue":_cache[22]||=$event=>currentNodeTextMode.value.rangeMax=$event,type:`number`,min:currentNodeTextMode.value.rangeMinCap,max:currentNodeTextMode.value.rangeMaxCap,step:(currentNodeTextMode.value.rangeMaxCap-currentNodeTextMode.value.rangeMinCap)/1e3,onValueChanged:applyState},null,8,[`modelValue`,`min`,`max`,`step`]),createVNode(unref(bngSwitch_default),{modelValue:currentNodeTextMode.value.rangeMaxEnabled,"onUpdate:modelValue":_cache[23]||=$event=>currentNodeTextMode.value.rangeMaxEnabled=$event,onValueChanged:applyState},null,8,[`modelValue`])])]),createBaseVNode(`div`,_hoisted_41,[createBaseVNode(`span`,_hoisted_42,toDisplayString(_ctx.$tt(`ui.debug.vehicle.useInclusiveRange`)),1),createVNode(unref(bngSwitch_default),{modelValue:currentNodeTextMode.value.usesInclusiveRange,"onUpdate:modelValue":_cache[24]||=$event=>currentNodeTextMode.value.usesInclusiveRange=$event,onValueChanged:applyState},null,8,[`modelValue`])]),createBaseVNode(`div`,_hoisted_43,[createBaseVNode(`span`,_hoisted_44,toDisplayString(_ctx.$tt(`ui.debug.vehicle.showInf`)),1),createVNode(unref(bngSwitch_default),{modelValue:currentNodeTextMode.value.showInfinity,"onUpdate:modelValue":_cache[25]||=$event=>currentNodeTextMode.value.showInfinity=$event,onValueChanged:applyState},null,8,[`modelValue`])])])):createCommentVNode(``,!0),state.vehicle.nodeTextMode===1?createCommentVNode(``,!0):(openBlock(),createElementBlock(`div`,_hoisted_45,[createBaseVNode(`span`,_hoisted_46,toDisplayString(_ctx.$tt(`ui.debug.vehicle.maxDist`)),1),createBaseVNode(`div`,_hoisted_47,[createVNode(unref(bngSlider_default),{modelValue:state.vehicle.nodeTextMaxDist,"onUpdate:modelValue":_cache[26]||=$event=>state.vehicle.nodeTextMaxDist=$event,min:.1,max:state.vehicle.nodeTextMaxDistCap,step:.1,onValueChanged:applyState},null,8,[`modelValue`,`max`]),createVNode(unref(bngInput_default),{modelValue:state.vehicle.nodeTextMaxDist,"onUpdate:modelValue":_cache[27]||=$event=>state.vehicle.nodeTextMaxDist=$event,type:`number`,min:.1,max:state.vehicle.nodeTextMaxDistCap,step:.1,onValueChanged:applyState},null,8,[`modelValue`,`max`])])])),state.vehicle.nodeTextMode===1?createCommentVNode(``,!0):(openBlock(),createElementBlock(`div`,_hoisted_48,[createBaseVNode(`span`,_hoisted_49,toDisplayString(_ctx.$tt(`ui.debug.vehicle.showWheels`)),1),createVNode(unref(bngSwitch_default),{modelValue:state.vehicle.nodeTextShowWheels,"onUpdate:modelValue":_cache[28]||=$event=>state.vehicle.nodeTextShowWheels=$event,onValueChanged:applyState},null,8,[`modelValue`])])),createBaseVNode(`div`,_hoisted_50,[createBaseVNode(`span`,_hoisted_51,toDisplayString(_ctx.$tt(`ui.debug.vehicle.nodeVis`)),1),createVNode(unref(bngDropdown_default),{modelValue:state.vehicle.nodeVisMode,"onUpdate:modelValue":_cache[29]||=$event=>state.vehicle.nodeVisMode=$event,items:nodeVisModeItems.value,onValueChanged:applyState,class:`control-input`},null,8,[`modelValue`,`items`])]),currentNodeVisMode.value&¤tNodeVisMode.value.usesRange?(openBlock(),createElementBlock(`div`,_hoisted_52,[createBaseVNode(`div`,_hoisted_53,[createBaseVNode(`span`,_hoisted_54,toDisplayString(_ctx.$tt(`ui.debug.vehicle.visRangeMin`)),1),createBaseVNode(`div`,_hoisted_55,[createVNode(unref(bngSlider_default),{modelValue:currentNodeVisMode.value.rangeMin,"onUpdate:modelValue":_cache[30]||=$event=>currentNodeVisMode.value.rangeMin=$event,min:currentNodeVisMode.value.rangeMinCap,max:currentNodeVisMode.value.rangeMaxCap,step:(currentNodeVisMode.value.rangeMaxCap-currentNodeVisMode.value.rangeMinCap)/100,onValueChanged:applyState},null,8,[`modelValue`,`min`,`max`,`step`]),createVNode(unref(bngInput_default),{modelValue:currentNodeVisMode.value.rangeMin,"onUpdate:modelValue":_cache[31]||=$event=>currentNodeVisMode.value.rangeMin=$event,type:`number`,min:currentNodeVisMode.value.rangeMinCap,max:currentNodeVisMode.value.rangeMaxCap,step:(currentNodeVisMode.value.rangeMaxCap-currentNodeVisMode.value.rangeMinCap)/1e3,onValueChanged:applyState},null,8,[`modelValue`,`min`,`max`,`step`]),createVNode(unref(bngSwitch_default),{modelValue:currentNodeVisMode.value.rangeMinEnabled,"onUpdate:modelValue":_cache[32]||=$event=>currentNodeVisMode.value.rangeMinEnabled=$event,onValueChanged:applyState},null,8,[`modelValue`])])]),createBaseVNode(`div`,_hoisted_56,[createBaseVNode(`span`,_hoisted_57,toDisplayString(_ctx.$tt(`ui.debug.vehicle.visRangeMax`)),1),createBaseVNode(`div`,_hoisted_58,[createVNode(unref(bngSlider_default),{modelValue:currentNodeVisMode.value.rangeMax,"onUpdate:modelValue":_cache[33]||=$event=>currentNodeVisMode.value.rangeMax=$event,min:currentNodeVisMode.value.rangeMinCap,max:currentNodeVisMode.value.rangeMaxCap,step:(currentNodeVisMode.value.rangeMaxCap-currentNodeVisMode.value.rangeMinCap)/100,onValueChanged:applyState},null,8,[`modelValue`,`min`,`max`,`step`]),createVNode(unref(bngInput_default),{modelValue:currentNodeVisMode.value.rangeMax,"onUpdate:modelValue":_cache[34]||=$event=>currentNodeVisMode.value.rangeMax=$event,type:`number`,min:currentNodeVisMode.value.rangeMinCap,max:currentNodeVisMode.value.rangeMaxCap,step:(currentNodeVisMode.value.rangeMaxCap-currentNodeVisMode.value.rangeMinCap)/1e3,onValueChanged:applyState},null,8,[`modelValue`,`min`,`max`,`step`]),createVNode(unref(bngSwitch_default),{modelValue:currentNodeVisMode.value.rangeMaxEnabled,"onUpdate:modelValue":_cache[35]||=$event=>currentNodeVisMode.value.rangeMaxEnabled=$event,onValueChanged:applyState},null,8,[`modelValue`])])]),createBaseVNode(`div`,_hoisted_59,[createBaseVNode(`span`,_hoisted_60,toDisplayString(_ctx.$tt(`ui.debug.vehicle.useInclusiveRange`)),1),createVNode(unref(bngSwitch_default),{modelValue:currentNodeVisMode.value.usesInclusiveRange,"onUpdate:modelValue":_cache[36]||=$event=>currentNodeVisMode.value.usesInclusiveRange=$event,onValueChanged:applyState},null,8,[`modelValue`])]),createBaseVNode(`div`,_hoisted_61,[createBaseVNode(`span`,_hoisted_62,toDisplayString(_ctx.$tt(`ui.debug.vehicle.showInf`)),1),createVNode(unref(bngSwitch_default),{modelValue:currentNodeVisMode.value.showInfinity,"onUpdate:modelValue":_cache[37]||=$event=>currentNodeVisMode.value.showInfinity=$event,onValueChanged:applyState},null,8,[`modelValue`])])])):createCommentVNode(``,!0),state.vehicle.nodeVisMode===1?createCommentVNode(``,!0):(openBlock(),createElementBlock(Fragment,{key:6},[createBaseVNode(`div`,_hoisted_63,[createBaseVNode(`span`,_hoisted_64,toDisplayString(_ctx.$tt(`ui.debug.vehicle.showHighlighted`)),1),createBaseVNode(`div`,_hoisted_65,[createVNode(unref(bngSwitch_default),{modelValue:state.vehicle.nodeVisShowHighlighted,"onUpdate:modelValue":_cache[38]||=$event=>state.vehicle.nodeVisShowHighlighted=$event,disabled:state.vehicle.nodeVisMode===3,onValueChanged:applyState},null,8,[`modelValue`,`disabled`])])]),createBaseVNode(`div`,_hoisted_66,[createBaseVNode(`span`,_hoisted_67,toDisplayString(_ctx.$tt(`ui.debug.vehicle.width`)),1),createBaseVNode(`div`,_hoisted_68,[createVNode(unref(bngSlider_default),{modelValue:state.vehicle.nodeVisWidthScale,"onUpdate:modelValue":_cache[39]||=$event=>state.vehicle.nodeVisWidthScale=$event,min:.3,max:5,step:.1,onValueChanged:applyState},null,8,[`modelValue`]),createVNode(unref(bngInput_default),{modelValue:state.vehicle.nodeVisWidthScale,"onUpdate:modelValue":_cache[40]||=$event=>state.vehicle.nodeVisWidthScale=$event,type:`number`,min:.3,max:5,step:.1,onValueChanged:applyState},null,8,[`modelValue`])])]),createBaseVNode(`div`,_hoisted_69,[createBaseVNode(`span`,_hoisted_70,toDisplayString(_ctx.$tt(`ui.debug.vehicle.transparency`)),1),createBaseVNode(`div`,_hoisted_71,[createVNode(unref(bngSlider_default),{modelValue:state.vehicle.nodeVisAlpha,"onUpdate:modelValue":_cache[41]||=$event=>state.vehicle.nodeVisAlpha=$event,min:0,max:1,step:.01,onValueChanged:applyState},null,8,[`modelValue`]),createVNode(unref(bngInput_default),{modelValue:state.vehicle.nodeVisAlpha,"onUpdate:modelValue":_cache[42]||=$event=>state.vehicle.nodeVisAlpha=$event,type:`number`,min:0,max:1,step:.01,onValueChanged:applyState},null,8,[`modelValue`])])])],64)),createBaseVNode(`div`,_hoisted_72,[createBaseVNode(`span`,_hoisted_73,toDisplayString(_ctx.$tt(`ui.debug.vehicle.torsionBarVis`)),1),createVNode(unref(bngDropdown_default),{modelValue:state.vehicle.torsionBarVisMode,"onUpdate:modelValue":_cache[43]||=$event=>state.vehicle.torsionBarVisMode=$event,items:torsionBarVisModeItems.value,onValueChanged:_cache[44]||=value=>{console.log(`change triggered`,value),applyState()},class:`control-input`},null,8,[`modelValue`,`items`])]),currentTorsionBarVisMode.value?.usesRange?(openBlock(),createElementBlock(Fragment,{key:7},[createBaseVNode(`div`,_hoisted_74,[createBaseVNode(`span`,_hoisted_75,toDisplayString(_ctx.$tt(`ui.debug.vehicle.visRangeMin`)),1),createBaseVNode(`div`,_hoisted_76,[createVNode(unref(bngSlider_default),{modelValue:currentTorsionBarVisMode.value.rangeMin,"onUpdate:modelValue":_cache[45]||=$event=>currentTorsionBarVisMode.value.rangeMin=$event,min:currentTorsionBarVisMode.value.rangeMinCap,max:currentTorsionBarVisMode.value.rangeMaxCap,step:(currentTorsionBarVisMode.value.rangeMaxCap-currentTorsionBarVisMode.value.rangeMinCap)/100,onValueChanged:applyState},null,8,[`modelValue`,`min`,`max`,`step`]),createVNode(unref(bngInput_default),{modelValue:currentTorsionBarVisMode.value.rangeMin,"onUpdate:modelValue":_cache[46]||=$event=>currentTorsionBarVisMode.value.rangeMin=$event,type:`number`,min:currentTorsionBarVisMode.value.rangeMinCap,max:currentTorsionBarVisMode.value.rangeMaxCap,step:(currentTorsionBarVisMode.value.rangeMaxCap-currentTorsionBarVisMode.value.rangeMinCap)/1e3,onValueChanged:applyState},null,8,[`modelValue`,`min`,`max`,`step`]),createVNode(unref(bngSwitch_default),{modelValue:currentTorsionBarVisMode.value.rangeMinEnabled,"onUpdate:modelValue":_cache[47]||=$event=>currentTorsionBarVisMode.value.rangeMinEnabled=$event,onValueChanged:applyState},null,8,[`modelValue`])])]),createBaseVNode(`div`,_hoisted_77,[createBaseVNode(`span`,_hoisted_78,toDisplayString(_ctx.$tt(`ui.debug.vehicle.visRangeMax`)),1),createBaseVNode(`div`,_hoisted_79,[createVNode(unref(bngSlider_default),{modelValue:currentTorsionBarVisMode.value.rangeMax,"onUpdate:modelValue":_cache[48]||=$event=>currentTorsionBarVisMode.value.rangeMax=$event,min:currentTorsionBarVisMode.value.rangeMinCap,max:currentTorsionBarVisMode.value.rangeMaxCap,step:(currentTorsionBarVisMode.value.rangeMaxCap-currentTorsionBarVisMode.value.rangeMinCap)/100,onValueChanged:applyState},null,8,[`modelValue`,`min`,`max`,`step`]),createVNode(unref(bngInput_default),{modelValue:currentTorsionBarVisMode.value.rangeMax,"onUpdate:modelValue":_cache[49]||=$event=>currentTorsionBarVisMode.value.rangeMax=$event,type:`number`,min:currentTorsionBarVisMode.value.rangeMinCap,max:currentTorsionBarVisMode.value.rangeMaxCap,step:(currentTorsionBarVisMode.value.rangeMaxCap-currentTorsionBarVisMode.value.rangeMinCap)/1e3,onValueChanged:applyState},null,8,[`modelValue`,`min`,`max`,`step`]),createVNode(unref(bngSwitch_default),{modelValue:currentTorsionBarVisMode.value.rangeMaxEnabled,"onUpdate:modelValue":_cache[50]||=$event=>currentTorsionBarVisMode.value.rangeMaxEnabled=$event,onValueChanged:applyState},null,8,[`modelValue`])])]),createBaseVNode(`div`,_hoisted_80,[createBaseVNode(`span`,_hoisted_81,toDisplayString(_ctx.$tt(`ui.debug.vehicle.useInclusiveRange`)),1),createVNode(unref(bngSwitch_default),{modelValue:currentTorsionBarVisMode.value.usesInclusiveRange,"onUpdate:modelValue":_cache[51]||=$event=>currentTorsionBarVisMode.value.usesInclusiveRange=$event,onValueChanged:applyState},null,8,[`modelValue`])]),createBaseVNode(`div`,_hoisted_82,[createBaseVNode(`span`,_hoisted_83,toDisplayString(_ctx.$tt(`ui.debug.vehicle.showInf`)),1),createVNode(unref(bngSwitch_default),{modelValue:currentTorsionBarVisMode.value.showInfinity,"onUpdate:modelValue":_cache[52]||=$event=>currentTorsionBarVisMode.value.showInfinity=$event,onValueChanged:applyState},null,8,[`modelValue`])])],64)):createCommentVNode(``,!0),state.vehicle.torsionBarVisMode===1?createCommentVNode(``,!0):(openBlock(),createElementBlock(Fragment,{key:8},[createBaseVNode(`div`,_hoisted_84,[createBaseVNode(`span`,_hoisted_85,toDisplayString(_ctx.$tt(`ui.debug.vehicle.width`)),1),createBaseVNode(`div`,_hoisted_86,[createVNode(unref(bngSlider_default),{modelValue:state.vehicle.torsionBarVisWidthScale,"onUpdate:modelValue":_cache[53]||=$event=>state.vehicle.torsionBarVisWidthScale=$event,min:.1,max:5,step:.1,onValueChanged:applyState},null,8,[`modelValue`]),createVNode(unref(bngInput_default),{modelValue:state.vehicle.torsionBarVisWidthScale,"onUpdate:modelValue":_cache[54]||=$event=>state.vehicle.torsionBarVisWidthScale=$event,type:`number`,min:.1,max:5,step:.1,onValueChanged:applyState},null,8,[`modelValue`])])]),createBaseVNode(`div`,_hoisted_87,[createBaseVNode(`span`,_hoisted_88,toDisplayString(_ctx.$tt(`ui.debug.vehicle.transparency`)),1),createBaseVNode(`div`,_hoisted_89,[createVNode(unref(bngSlider_default),{modelValue:state.vehicle.torsionBarVisAlpha,"onUpdate:modelValue":_cache[55]||=$event=>state.vehicle.torsionBarVisAlpha=$event,min:0,max:1,step:.01,onValueChanged:applyState},null,8,[`modelValue`]),createVNode(unref(bngInput_default),{modelValue:state.vehicle.torsionBarVisAlpha,"onUpdate:modelValue":_cache[56]||=$event=>state.vehicle.torsionBarVisAlpha=$event,type:`number`,min:0,max:1,step:.01,onValueChanged:applyState},null,8,[`modelValue`])])])],64)),createBaseVNode(`div`,_hoisted_90,[createBaseVNode(`span`,_hoisted_91,toDisplayString(_ctx.$tt(`ui.debug.vehicle.railsSlideNodesVis`)),1),createVNode(unref(bngDropdown_default),{modelValue:state.vehicle.railsSlideNodesVisMode,"onUpdate:modelValue":_cache[57]||=$event=>state.vehicle.railsSlideNodesVisMode=$event,items:railsSlideNodesModeItems.value,onValueChanged:applyState,class:`control-input`},null,8,[`modelValue`,`items`])]),state.vehicle.railsSlideNodesVisMode===1?createCommentVNode(``,!0):(openBlock(),createElementBlock(Fragment,{key:9},[createBaseVNode(`div`,_hoisted_92,[createBaseVNode(`span`,_hoisted_93,toDisplayString(_ctx.$tt(`ui.debug.vehicle.width`)),1),createBaseVNode(`div`,_hoisted_94,[createVNode(unref(bngSlider_default),{modelValue:state.vehicle.railsSlideNodesVisWidthScale,"onUpdate:modelValue":_cache[58]||=$event=>state.vehicle.railsSlideNodesVisWidthScale=$event,min:.1,max:5,step:.1,onValueChanged:applyState},null,8,[`modelValue`]),createVNode(unref(bngInput_default),{modelValue:state.vehicle.railsSlideNodesVisWidthScale,"onUpdate:modelValue":_cache[59]||=$event=>state.vehicle.railsSlideNodesVisWidthScale=$event,type:`number`,min:.1,max:5,step:.1,onValueChanged:applyState},null,8,[`modelValue`])])]),createBaseVNode(`div`,_hoisted_95,[createBaseVNode(`span`,_hoisted_96,toDisplayString(_ctx.$tt(`ui.debug.vehicle.transparency`)),1),createBaseVNode(`div`,_hoisted_97,[createVNode(unref(bngSlider_default),{modelValue:state.vehicle.railsSlideNodesVisAlpha,"onUpdate:modelValue":_cache[60]||=$event=>state.vehicle.railsSlideNodesVisAlpha=$event,min:0,max:1,step:.01,onValueChanged:applyState},null,8,[`modelValue`]),createVNode(unref(bngInput_default),{modelValue:state.vehicle.railsSlideNodesVisAlpha,"onUpdate:modelValue":_cache[61]||=$event=>state.vehicle.railsSlideNodesVisAlpha=$event,type:`number`,min:0,max:1,step:.01,onValueChanged:applyState},null,8,[`modelValue`])])])],64)),createBaseVNode(`div`,_hoisted_98,[createBaseVNode(`span`,_hoisted_99,toDisplayString(_ctx.$tt(`ui.debug.vehicle.centerOfGravity`)),1),createVNode(unref(bngDropdown_default),{modelValue:state.vehicle.cogMode,"onUpdate:modelValue":_cache[62]||=$event=>state.vehicle.cogMode=$event,items:cogModeItems.value,onValueChanged:applyState,class:`control-input`},null,8,[`modelValue`,`items`])]),createBaseVNode(`div`,_hoisted_100,[createBaseVNode(`span`,_hoisted_101,toDisplayString(_ctx.$tt(`ui.debug.vehicle.collisionTriangle`)),1),createVNode(unref(bngDropdown_default),{modelValue:state.vehicle.collisionTriangleVisMode,"onUpdate:modelValue":_cache[63]||=$event=>state.vehicle.collisionTriangleVisMode=$event,items:collisionTriangleModeItems.value,onValueChanged:applyState,class:`control-input`},null,8,[`modelValue`,`items`])]),state.vehicle.collisionTriangleVisMode===1?createCommentVNode(``,!0):(openBlock(),createElementBlock(`div`,_hoisted_102,[createBaseVNode(`span`,_hoisted_103,toDisplayString(_ctx.$tt(`ui.debug.vehicle.transparency`)),1),createBaseVNode(`div`,_hoisted_104,[createVNode(unref(bngSlider_default),{modelValue:state.vehicle.collisionTriangleVisAlpha,"onUpdate:modelValue":_cache[64]||=$event=>state.vehicle.collisionTriangleVisAlpha=$event,min:0,max:1,step:.01,onValueChanged:applyState},null,8,[`modelValue`]),createVNode(unref(bngInput_default),{modelValue:state.vehicle.collisionTriangleVisAlpha,"onUpdate:modelValue":_cache[65]||=$event=>state.vehicle.collisionTriangleVisAlpha=$event,type:`number`,min:0,max:1,step:.01,onValueChanged:applyState},null,8,[`modelValue`])])])),createBaseVNode(`div`,_hoisted_105,[createBaseVNode(`span`,_hoisted_106,toDisplayString(_ctx.$tt(`ui.debug.vehicle.aerodynamics`)),1),createVNode(unref(bngDropdown_default),{modelValue:state.vehicle.aeroMode,"onUpdate:modelValue":_cache[66]||=$event=>state.vehicle.aeroMode=$event,items:aeroModeItems.value,onValueChanged:applyState,class:`control-input`},null,8,[`modelValue`,`items`])]),state.vehicle.aeroMode===1?createCommentVNode(``,!0):(openBlock(),createElementBlock(`div`,_hoisted_107,[createBaseVNode(`span`,_hoisted_108,toDisplayString(_ctx.$tt(`ui.debug.vehicle.aerodynamicsScale`)),1),createBaseVNode(`div`,_hoisted_109,[createVNode(unref(bngSlider_default),{modelValue:state.vehicle.aerodynamicsScale,"onUpdate:modelValue":_cache[67]||=$event=>state.vehicle.aerodynamicsScale=$event,min:0,max:.2,step:.01,onValueChanged:applyState},null,8,[`modelValue`]),createVNode(unref(bngInput_default),{modelValue:state.vehicle.aerodynamicsScale,"onUpdate:modelValue":_cache[68]||=$event=>state.vehicle.aerodynamicsScale=$event,type:`number`,min:0,max:.2,step:.01,onValueChanged:applyState},null,8,[`modelValue`])])])),createBaseVNode(`div`,_hoisted_110,[createBaseVNode(`span`,_hoisted_111,toDisplayString(_ctx.$tt(`ui.debug.vehicle.tireContactPoint`)),1),createVNode(unref(bngSwitch_default),{modelValue:state.vehicle.tireContactPoint,"onUpdate:modelValue":_cache[69]||=$event=>state.vehicle.tireContactPoint=$event,onValueChanged:applyState},null,8,[`modelValue`])]),createBaseVNode(`div`,_hoisted_112,[createBaseVNode(`span`,_hoisted_113,toDisplayString(_ctx.$tt(`ui.debug.vehicle.steeringGeometry`)),1),createVNode(unref(bngSwitch_default),{modelValue:state.vehicle.steeringGeometry,"onUpdate:modelValue":_cache[70]||=$event=>state.vehicle.steeringGeometry=$event,onValueChanged:applyState},null,8,[`modelValue`])]),state.vehicle.steeringGeometry?(openBlock(),createElementBlock(`div`,_hoisted_114,[createBaseVNode(`span`,_hoisted_115,toDisplayString(_ctx.$tt(`ui.debug.vehicle.steeringGeometryLineLength`)),1),createBaseVNode(`div`,_hoisted_116,[createVNode(unref(bngSlider_default),{modelValue:state.vehicle.steeringGeometryLineLength,"onUpdate:modelValue":_cache[71]||=$event=>state.vehicle.steeringGeometryLineLength=$event,min:0,max:50,step:.1,onValueChanged:applyState},null,8,[`modelValue`]),createVNode(unref(bngInput_default),{modelValue:state.vehicle.steeringGeometryLineLength,"onUpdate:modelValue":_cache[72]||=$event=>state.vehicle.steeringGeometryLineLength=$event,type:`number`,min:0,max:50,step:.1,onValueChanged:applyState},null,8,[`modelValue`])])])):createCommentVNode(``,!0),shipping.value?createCommentVNode(``,!0):(openBlock(),createElementBlock(`div`,_hoisted_117,[createBaseVNode(`span`,_hoisted_118,toDisplayString(_ctx.$tt(`ui.debug.vehicle.wheelThermals`))+` 🐞`,1),createVNode(unref(bngSwitch_default),{modelValue:state.vehicle.wheelThermals,"onUpdate:modelValue":_cache[73]||=$event=>state.vehicle.wheelThermals=$event,onValueChanged:applyState},null,8,[`modelValue`])]))],64)):createCommentVNode(``,!0),createBaseVNode(`div`,_hoisted_119,[createBaseVNode(`div`,_hoisted_120,[createBaseVNode(`span`,_hoisted_121,toDisplayString(_ctx.$tt(`ui.debug.vehicle.meshVisibility`)),1),createBaseVNode(`div`,_hoisted_122,[(openBlock(!0),createElementBlock(Fragment,null,renderList(controls$1.jbeamvis.meshVisButtonGroup,btn=>(openBlock(),createBlock(unref(bngButton_default),{key:btn.label,onClick:$event=>btn.action(),disabled:disableVehicleButtons.value,accent:unref(ACCENTS).outlined,class:`mesh-button`},{default:withCtx(()=>[createTextVNode(toDisplayString(btn.label),1)]),_:2},1032,[`onClick`,`disabled`,`accent`]))),128))])])]),_cache[75]||=createBaseVNode(`hr`,null,null,-1),createBaseVNode(`h4`,null,toDisplayString(_ctx.$tt(`ui.debug.terrain`)),1),createBaseVNode(`div`,_hoisted_123,[(openBlock(!0),createElementBlock(Fragment,null,renderList(controls$1.terrain.buttonGroup_1,btn=>(openBlock(),createBlock(unref(bngButton_default),{key:btn.label,onClick:$event=>btn.action(),accent:unref(ACCENTS).secondary},{default:withCtx(()=>[createTextVNode(toDisplayString(_ctx.$tt(btn.label)),1)]),_:2},1032,[`onClick`,`accent`]))),128))])]))}},Debug_default=__plugin_vue_export_helper_default(_sfc_main$14,[[`__scopeId`,`data-v-8c471ede`]]),_sfc_main$13={__name:`VehicleConfig`,props:{tab:{type:String,default:`parts`,validator:val=>!val||[`parts`,`tuning`,`color`,`save`,`debug`].includes(val)}},setup(__props){let exit=event=>{event.detail.force||window.bngVue.gotoAngularState(`menu.mainmenu`)};function syncWithStates(tab){window.bngVue&&(tab=[`parts`,`tuning`,`color`,`save`,`debug`][tab.index]||`parts`,window.bngVue.gotoAngularState(`menu.vehicleconfig.${tab}`))}return(_ctx,_cache)=>withDirectives((openBlock(),createBlock(unref(layoutSingle_default),{class:`vehcfg`,onDeactivate:exit},{default:withCtx(()=>[withDirectives((openBlock(),createBlock(unref(tabs_default),{class:`bng-tabs`,onChange:syncWithStates},{default:withCtx(()=>[withDirectives(createVNode(unref(tabList_default),null,null,512),[[unref(BngBlur_default)]]),withDirectives(createVNode(Parts_default,{"tab-selected":__props.tab===`parts`,"tab-heading":_ctx.$t(`ui.vehicleconfig.parts`)},null,8,[`tab-selected`,`tab-heading`]),[[unref(BngBlur_default)]]),withDirectives(createVNode(Tuning_default,{"tab-selected":__props.tab===`tuning`,"tab-heading":_ctx.$t(`ui.vehicleconfig.tuning`)},null,8,[`tab-selected`,`tab-heading`]),[[unref(BngBlur_default)]]),withDirectives(createVNode(Paint_default,{"tab-selected":__props.tab===`color`,"tab-heading":_ctx.$t(`ui.vehicleconfig.color`)},null,8,[`tab-selected`,`tab-heading`]),[[unref(BngBlur_default)]]),withDirectives(createVNode(Save_default,{"tab-selected":__props.tab===`save`,"tab-heading":_ctx.$t(`ui.vehicleconfig.save`)+` & `+_ctx.$t(`ui.vehicleconfig.load`)},null,8,[`tab-selected`,`tab-heading`]),[[unref(BngBlur_default)]]),withDirectives(createVNode(Debug_default,{"tab-selected":__props.tab===`debug`,"tab-heading":_ctx.$tt(`ui.debug.vehicle`)},null,8,[`tab-selected`,`tab-heading`]),[[unref(BngBlur_default)]])]),_:1})),[[unref(BngFrustumMover_default),!0,void 0,{left:!0}]])]),_:1})),[[unref(BngScopedNav_default),{activateOnMount:!0,bubbleWhitelistEvents:[`tab_l`,`tab_r`,`menu`]}]])}},VehicleConfig_default=__plugin_vue_export_helper_default(_sfc_main$13,[[`__scopeId`,`data-v-e5f4e51f`]]),_hoisted_1$10={class:`adjustment-container`},_hoisted_2$6={class:`y-controls`},_hoisted_3$5={class:`slider-container`},_hoisted_4$4={class:`value-input`},_hoisted_5$3={class:`x-controls`},_hoisted_6$2={class:`slider-container`},_hoisted_7$2={class:`value-input`},_hoisted_8$1={class:`reset-cont`},MIRROR_RANGE_DEFAULTS={min:-20,max:20,step:.01},_sfc_main$12={__name:`MirrorAdjust`,props:{mirror:Object},setup(__props){let props=__props,uiScopeName=`vehicle-config-mirrors`,uiNavScope$1=useUINavScope(uiScopeName),reactivateUIScope=event=>{(event.type===`deactivate`||event.type===`focusout`)&&uiNavScope$1.set(uiScopeName)},range={x:{min:props.mirror.clampX?props.mirror.clampX[0]:MIRROR_RANGE_DEFAULTS.min,max:props.mirror.clampX?props.mirror.clampX[1]:MIRROR_RANGE_DEFAULTS.max,step:MIRROR_RANGE_DEFAULTS.step},y:{min:props.mirror.clampY?props.mirror.clampY[0]:MIRROR_RANGE_DEFAULTS.min,max:props.mirror.clampY?props.mirror.clampY[1]:MIRROR_RANGE_DEFAULTS.max,step:MIRROR_RANGE_DEFAULTS.step}},[inpX,inpY]=[ref(),ref()],isChanged=computed(()=>inpX.value&&inpX.value.dirty||inpY.value&&inpY.value.dirty),mover={x:0,y:0,drift:.2,tmr:null,tmrInterval:100};function move(evt){let val=evt.detail.value>mover.drift?evt.detail.value-mover.drift:evt.detail.value<-mover.drift?evt.detail.value+mover.drift:0;evt.detail.name===`focus_lr`?mover.x=val:evt.detail.name===`focus_ud`&&(mover.y=val)}let precision=10**(MIRROR_RANGE_DEFAULTS.step+`.`).split(/[.,]/)[1].length,clamp$2=(val,axis=`x`)=>Math.round(Math.max(range[axis].min,Math.min(val,range[axis].max))*precision)/precision;function resetValues(){props.mirror.x=inpX.value.currentCleanValue,props.mirror.y=inpY.value.currentCleanValue,onValueChanged()}function onValueChanged(){Lua_default.extensions.core_vehicle_mirror.setAngleOffset(props.mirror.name,-props.mirror.y,-props.mirror.x,!1,!1)}return onMounted(()=>{getUINavServiceInstance().useCrossfire=!1,Lua_default.extensions.core_vehicle_mirror.focusOnMirror(props.mirror.name),mover.tmr=setInterval(()=>{mover.x===0&&mover.y===0||(props.mirror.x=clamp$2(props.mirror.x+mover.x,`x`),props.mirror.y=clamp$2(props.mirror.y+mover.y,`y`),onValueChanged())},mover.tmrInterval)}),onUnmounted(()=>{getUINavServiceInstance().useCrossfire=!0,clearInterval(mover.tmr)}),(_ctx,_cache)=>withDirectives((openBlock(),createElementBlock(`div`,_hoisted_1$10,[createVNode(unref(bngImageTile_default),{class:`mirror-tile`,icon:unref(icons)[__props.mirror.mirrorIcon],label:__props.mirror.description,ratio:`1:1`},null,8,[`icon`,`label`]),createBaseVNode(`div`,_hoisted_2$6,[createBaseVNode(`div`,_hoisted_3$5,[createVNode(unref(bngSlider_default),mergeProps({"bng-no-nav":`true`,ref_key:`inpY`,ref:inpY,class:`slider-y`},range.y,{uiNavFocus:!1,modelValue:__props.mirror.y,"onUpdate:modelValue":_cache[0]||=$event=>__props.mirror.y=$event,onFocusout:reactivateUIScope,onValueChanged,onDeactivate:reactivateUIScope}),null,16,[`modelValue`])]),createBaseVNode(`div`,_hoisted_4$4,[createVNode(unref(bngBinding_default),{class:`keybinding`,action:`menu_item_focus_ud`,deviceMask:`xinput`,dark:!1}),createVNode(unref(bngInput_default),mergeProps({class:`value`,modelValue:__props.mirror.y,"onUpdate:modelValue":_cache[1]||=$event=>__props.mirror.y=$event,type:`number`},range.y,{prefix:`Y`,suffix:`°`}),null,16,[`modelValue`])])]),createBaseVNode(`div`,_hoisted_5$3,[createBaseVNode(`div`,_hoisted_6$2,[createVNode(unref(bngSlider_default),mergeProps({"bng-no-nav":`true`,ref_key:`inpX`,ref:inpX,class:`slider-x`},range.x,{uiNavFocus:!1,modelValue:__props.mirror.x,"onUpdate:modelValue":_cache[2]||=$event=>__props.mirror.x=$event,onFocusout:reactivateUIScope,onValueChanged,onDeactivate:reactivateUIScope}),null,16,[`modelValue`])]),createBaseVNode(`div`,_hoisted_7$2,[createVNode(unref(bngBinding_default),{class:`keybinding`,action:`menu_item_focus_lr`,deviceMask:`xinput`,dark:!1}),createVNode(unref(bngInput_default),mergeProps({class:`value`,modelValue:__props.mirror.x,"onUpdate:modelValue":_cache[3]||=$event=>__props.mirror.x=$event,type:`number`},range.x,{prefix:`X`,suffix:`°`}),null,16,[`modelValue`])])]),createBaseVNode(`div`,_hoisted_8$1,[createVNode(unref(bngButton_default),{accent:unref(ACCENTS).attention,disabled:!isChanged.value,onClick:_cache[4]||=$event=>resetValues()},{default:withCtx(()=>[createVNode(unref(bngBinding_default),{controller:``,"ui-event":`action_3`}),createTextVNode(` `+toDisplayString(_ctx.$t(`ui.common.reset`)),1)]),_:1},8,[`accent`,`disabled`])])])),[[unref(BngOnUiNav_default),move,`focus_lr,focus_ud`],[unref(BngOnUiNav_default),resetValues,`action_3`]])}},MirrorAdjust_default=__plugin_vue_export_helper_default(_sfc_main$12,[[`__scopeId`,`data-v-14ab0128`]]),_hoisted_1$9={key:0,class:`content buttons-grid`},_sfc_main$11={__name:`Mirrors`,props:{exitRoute:{type:String,default:`menu.vehicleconfig.tuning`}},setup(__props){useUINavScope(`vehicle-config-mirrors`);let comp=ref(null),{lua,events:events$3}=useBridge(),mirrors=ref([]),selectedMirror=ref(null),props=__props;async function exitAdjustmentMode(){selectedMirror.value?(lua.extensions.core_vehicle_mirror.setAngleOffset(selectedMirror.value.name,-selectedMirror.value.y,-selectedMirror.value.x,!1,!0),selectedMirror.value=null,comp.value=null,await lua.extensions.core_vehicle_mirror.focusOnMirror(!1)):bngVue.gotoAngularState(props.exitRoute)}async function getVehicleMirrors(){let data=await lua.extensions.core_vehicle_mirror.getAnglesOffset();for(let key in mirrors.value.splice(0),data){let position=data[key].position,mirrorIcon=data[key].icon,description=data[key].label;if(position||(/_L$|_L_/.test(key)?(position=`left`,mirrorIcon||=`mirrorLeftDefault`):/_R$|_R_/.test(key)?(position=`right`,mirrorIcon||=`mirrorRightDefault`):position=`mid`),!description)description=$translate.instant(`ui.mirrors.position.`+position),key.endsWith(`_spot`)&&(description+=` (${$translate.instant(`ui.mirrors.spot`)})`);else{let tr=$translate.instant(`ui.mirrors.`+description);tr.startsWith(`ui.mirrors.`)||(description=tr)}mirrors.value.push({name:data[key].name,description,position,x:data[key].angleOffset.x,y:data[key].angleOffset.z,clampX:data[key].clampX,clampY:data[key].clampZ,mirrorIcon:mirrorIcon||`mirrorInteriorMiddle`,row:data[key].row||0})}mirrors.value.sort((a$1,b)=>a$1.row-b.row)}return onMounted(async()=>{await getVehicleMirrors(),events$3.on(`VehicleChange`,getVehicleMirrors),lua.extensions.core_input_bindings.setMenuActionEnabled(!0,`menu_item_focus_lr`),lua.extensions.core_input_bindings.setMenuActionEnabled(!0,`menu_item_focus_ud`)}),onUnmounted(()=>{events$3.off(`VehicleChange`,getVehicleMirrors)}),(_ctx,_cache)=>withDirectives((openBlock(),createBlock(unref(layoutSingle_default),{class:`layout-content-full layout-align-hstart`,"bng-ui-scope":`vehicle-config-mirrors`},{default:withCtx(()=>[withDirectives((openBlock(),createBlock(unref(bngCard_default),{class:`mirrors-card`},{buttons:withCtx(()=>[createVNode(unref(bngButton_default),{onClick:exitAdjustmentMode},{default:withCtx(()=>[selectedMirror.value?(openBlock(),createBlock(unref(bngBinding_default),{key:0,controller:``,"ui-event":`action_2`})):(openBlock(),createBlock(unref(bngBinding_default),{key:1,controller:``,"ui-event":`back`})),createTextVNode(` `+toDisplayString(_ctx.$t(selectedMirror.value?`ui.common.apply`:`ui.common.close`)),1)]),_:1})]),default:withCtx(()=>[createVNode(unref(bngCardHeading_default),null,{default:withCtx(()=>[createTextVNode(toDisplayString(_ctx.$t(`ui.mirrors.name`)),1)]),_:1}),selectedMirror.value?(openBlock(),createBlock(MirrorAdjust_default,{key:1,class:`content`,mirror:selectedMirror.value},null,8,[`mirror`])):(openBlock(),createElementBlock(`div`,_hoisted_1$9,[(openBlock(!0),createElementBlock(Fragment,null,renderList(mirrors.value,mirror=>(openBlock(),createBlock(unref(bngImageTile_default),{onClick:$event=>selectedMirror.value=mirror,class:normalizeClass([`mirror-button`,[mirror.position]]),icon:unref(icons)[mirror.mirrorIcon]||unref(icons).placeholder,label:mirror.description,"bng-nav-item":``},null,8,[`onClick`,`class`,`icon`,`label`]))),256))]))]),_:1})),[[unref(BngBlur_default),!0]])]),_:1})),[[unref(BngOnUiNav_default),exitAdjustmentMode,`menu,back`],[unref(BngOnUiNav_default),()=>selectedMirror.value&&exitAdjustmentMode(),`action_2`]])}},Mirrors_default=__plugin_vue_export_helper_default(_sfc_main$11,[[`__scopeId`,`data-v-28f8b633`]]),routes_default$17=[{path:`/vehicle-config`,name:`menu.vehicleconfig`,redirect:`/vehicle-config/parts`,meta:{clickThrough:!0,infoBar:{withAngular:!1,visible:!0,showSysInfo:!1},uiApps:{shown:!0},topBar:{visible:!0}},children:[{path:`parts`,name:`menu.vehicleconfig.parts`,component:VehicleConfig_default,props:{tab:`parts`}},{path:`tuning`,name:`menu.vehicleconfig.tuning`,component:VehicleConfig_default,props:{tab:`tuning`}},{path:`color`,name:`menu.vehicleconfig.color`,component:VehicleConfig_default,props:{tab:`color`},meta:{uiApps:{shown:!1}}},{path:`save`,name:`menu.vehicleconfig.save`,component:VehicleConfig_default,props:{tab:`save`},meta:{uiApps:{shown:!1}}},{path:`debug`,name:`menu.vehicleconfig.debug`,component:VehicleConfig_default,props:{tab:`debug`}}]},{path:`/vehicle-config/tuning/mirrors/:exitRoute?/`,name:`menu.vehicleconfig.tuning.mirrors`,component:Mirrors_default,props:!0},{path:`/vehicle-config/tuning/mirrors-angular`,name:`menu.vehicleconfig.tuning.mirrors.with-angular`,component:Mirrors_default,props:{exitRoute:`menu.vehicleconfigold.tuning`}},{path:`/vehicle-config/tuning/mirrors-garage`,name:`menu.vehicleconfig.tuning.mirrors.in-garage`,component:Mirrors_default,props:{exitRoute:`garagemode.tuning`}}],_hoisted_1$8={key:0,class:`management-details`},_hoisted_2$5={key:0,class:`current-vehicle-info`},_hoisted_3$4={class:`info-row`},_hoisted_4$3={class:`value`},_hoisted_5$2={class:`buttons-section`},_sfc_main$10={__name:`ManagementDetails`,props:{managementDetails:{type:Object,default:null},executeButton:{type:Function,required:!0}},emits:[`button-click`],setup(__props,{emit:__emit}){let props=__props,emit$1=__emit,handleButtonClick=buttonId=>{props.executeButton(buttonId),emit$1(`button-click`,buttonId)};return(_ctx,_cache)=>__props.managementDetails&&__props.managementDetails.buttonInfo&&__props.managementDetails.buttonInfo.length>0?(openBlock(),createElementBlock(`div`,_hoisted_1$8,[__props.managementDetails.details?(openBlock(),createElementBlock(`div`,_hoisted_2$5,[createBaseVNode(`div`,_hoisted_3$4,[_cache[0]||=createBaseVNode(`span`,{class:`label`},`Current Vehicle:`,-1),createBaseVNode(`span`,_hoisted_4$3,toDisplayString(__props.managementDetails.details.currentVehicleName),1)])])):createCommentVNode(``,!0),createBaseVNode(`div`,_hoisted_5$2,[(openBlock(!0),createElementBlock(Fragment,null,renderList(__props.managementDetails.buttonInfo,button=>(openBlock(),createElementBlock(`div`,{key:button.buttonId,class:`button-container`},[createVNode(unref(bngButton_default),{accent:button.accent||`secondary`,label:button.label,icon:button.icon,onClick:$event=>handleButtonClick(button.buttonId)},null,8,[`accent`,`label`,`icon`,`onClick`])]))),128))])])):createCommentVNode(``,!0)}},ManagementDetails_default=__plugin_vue_export_helper_default(_sfc_main$10,[[`__scopeId`,`data-v-b0128491`]]),_sfc_main$9={__name:`VehicleSelector`,setup(__props){return(_ctx,_cache)=>(openBlock(),createBlock(GridSelector_default,{backendName:`vehicleSelector`,routePath:`/vehicle-selector`,defaultPath:{keys:[`allModels`]},defaultDetailsMode:`advanced`,tileImagesTopAligned:``},{"item-details":withCtx(({activeItem,activeItemDetails,executeButton,toggleFavourite,exploreFolder,goToMod})=>[createVNode(VehicleDetails_default,{activeItem,activeItemDetails,executeButton,toggleFavourite,exploreFolder,goToMod,showHeaderTitle:!0},null,8,[`activeItem`,`activeItemDetails`,`executeButton`,`toggleFavourite`,`exploreFolder`,`goToMod`])]),"management-details":withCtx(({managementDetails,executeButton})=>[createVNode(ManagementDetails_default,{managementDetails,executeButton},null,8,[`managementDetails`,`executeButton`])]),_:1}))}},VehicleSelector_default=_sfc_main$9,routes_default$18=[{name:`menu.vehiclesnew`,path:`/vehicle-selector/:pathMatch(.*)*`,component:VehicleSelector_default,props:!0,meta:{clickThrough:!0,infoBar:{visible:!0,showSysInfo:!1},uiApps:{shown:!1},topBar:{visible:!0}}}],router=createRouter({history:createWebHashHistory(),routes:[...Object.values([routes_default,routes_default$1,routes_default$2,routes_default$3,routes_default$4,routes_default$5,routes_default$6,routes_default$7,routes_default$8,routes_default$9,routes_default$10,routes_default$11,routes_default$12,routes_default$13,routes_default$14,routes_default$15,routes_default$16,routes_default$17,routes_default$18]).flatMap(routes=>routes||[]),{path:`/:catchAll(.*)*`,name:`unknown`,component:NotFound_default}]});router.bngUpdateMeta=to=>{to.meta&&(to.meta.uiApps&&handelUIAppsSettings(to.meta.uiApps),handleInfoBarSettings(to.meta.infoBar||{}),handleTopBarSettings(to))},router.afterEach((to,from)=>{reportState(to.path,!0,from.path),window.bridge.api.engineLua(`extensions.hook("onUiChangedState", "${to.name}", "${from.name}")`),router.bngUpdateMeta(to)});var handelUIAppsSettings=settings$1=>{let appsAPI=useUIApps();settings$1.layout&&appsAPI.setLayout(settings$1.layout),`shown`in settings$1&&appsAPI.setVisible(settings$1.shown)},handleInfoBarSettings=settings$1=>{let infoBar=useInfoBar();infoBar.visible=settings$1.visible,infoBar.showSysInfo=settings$1.showSysInfo,infoBar.withAngular=settings$1.withAngular,settings$1.hints&&(infoBar.clearHints(),infoBar.addHints(settings$1.hints))},handleTopBarSettings=to=>{let topBar=useTopBar(),meta=to.meta.topBar||{};meta.visible?meta.visible&&!topBar.visible&&topBar.show():topBar.hide(),topBar.onUIStateChanged(to)},router_default=router,_hoisted_1$7={key:0,id:`vue-debug`},_hoisted_2$4={class:`heading-wrapper`},_hoisted_3$3={class:`label`},_hoisted_4$2={key:0,class:`route-info`},_hoisted_5$1={class:`main`},_hoisted_6$1={class:`controls`},_hoisted_7$1={key:0},_hoisted_8=[`label`],_hoisted_9=[`value`,`selected`],_sfc_main$8={__name:`VueDebug`,setup(__props){let{lua}=useBridge(),EXTRA_ROUTE,routeGroups=router_default.getRoutes().map(r=>r.name).filter(n=>n!==`routelist`).sort((a$1,b)=>a$1.localeCompare(b)).reduce((res,n)=>{if(!n)return res;let g=n.substring(0,1);return res[g]||(res[g]={name:g.toUpperCase(),routes:[]}),res[g].routes.push(n),res},{}),route=useRoute(),hash=ref(location.hash.split(`#`)[1]),path=computed(()=>route.path),routeName=computed(()=>route.name),showDebug=ref(window._VueDebugState),isOpen=ref(window._VueDebugOpen),showComponents=router_default.hasRoute(`components`),bngVue$1=window.bngVue||{};bngVue$1.debug=(state=!0)=>showDebug.value=window._VueDebugState=state,bngVue$1.reset=()=>bngVue$1.gotoGameState(`menu.mainmenu`);function toggleOpen(){isOpen.value=window._VueDebugOpen=!isOpen.value}function selectRoute(e){e.target.value&&bngVue$1.gotoGameState(e.target.value)}function icons$3(){bngVue$1.gotoGameState(`components/IconBrowser`),toggleOpen()}function colours(){bngVue$1.gotoGameState(`components/Colours`),toggleOpen()}function extra(){bngVue$1.gotoGameState(void 0),toggleOpen()}function components(){bngVue$1.showComponents(),toggleOpen()}function menu(){bngVue$1.reset(),toggleOpen()}function mainmenu(){toggleOpen(),lua.returnToMainMenu()}let closeDebug=e=>{e.stopPropagation(),bngVue$1.debug(!1)};return addEventListener(`hashchange`,e=>{hash.value=e.newURL.split(`#`)[1]}),(_ctx,_cache)=>(openBlock(),createBlock(Teleport,{to:`body`},[showDebug.value?(openBlock(),createElementBlock(`div`,_hoisted_1$7,[createBaseVNode(`div`,{class:`handle`,onClick:toggleOpen},[createBaseVNode(`div`,_hoisted_2$4,[createBaseVNode(`span`,_hoisted_3$3,[_cache[1]||=createBaseVNode(`strong`,null,`Vue`,-1),isOpen.value?createCommentVNode(``,!0):(openBlock(),createElementBlock(`span`,_hoisted_4$2,`: `+toDisplayString(path.value)+` [ `+toDisplayString(routeName.value)+` ]`,1))]),createBaseVNode(`a`,{onClick:closeDebug},`x`)])]),withDirectives(createBaseVNode(`div`,_hoisted_5$1,[createBaseVNode(`div`,null,[createTextVNode(` Current hash: `+toDisplayString(hash.value),1),_cache[2]||=createBaseVNode(`br`,null,null,-1),createTextVNode(` Route name: `+toDisplayString(routeName.value),1)]),_cache[4]||=createBaseVNode(`hr`,null,null,-1),createBaseVNode(`div`,_hoisted_6$1,[unref(showComponents)?(openBlock(),createElementBlock(`div`,_hoisted_7$1,[withDirectives((openBlock(),createElementBlock(`a`,{href:`#`,onClick:menu},[..._cache[3]||=[createTextVNode(`Main Menu`,-1)]])),[[unref(BngDoubleClick_default),mainmenu,void 0,{capture:!0}],[unref(BngTooltip_default),`Doubleclick to unload level`]]),unref(void 0)?(openBlock(),createElementBlock(`a`,{key:0,href:`#`,onClick:extra},`⏩`)):createCommentVNode(``,!0),createBaseVNode(`a`,{href:`#`,onClick:_cache[0]||=$event=>_ctx.$simplemenu.value=!_ctx.$simplemenu.value},toDisplayString(_ctx.$simplemenu.value?`✓`:`☐`)+` SimpleMenu`,1),createBaseVNode(`a`,{href:`#`,onClick:components},`Components`),createBaseVNode(`a`,{href:`#`,onClick:icons$3},`Icons`),createBaseVNode(`a`,{href:`#`,onClick:colours},`Colours`)])):createCommentVNode(``,!0),createBaseVNode(`select`,{multiple:``,onClick:selectRoute},[(openBlock(!0),createElementBlock(Fragment,null,renderList(unref(routeGroups),group=>(openBlock(),createElementBlock(`optgroup`,{key:group.name,label:group.name},[(openBlock(!0),createElementBlock(Fragment,null,renderList(group.routes,route$1=>(openBlock(),createElementBlock(`option`,{key:route$1,value:route$1,selected:route$1===routeName.value},toDisplayString(route$1),9,_hoisted_9))),128))],8,_hoisted_8))),128))])])],512),[[vShow,isOpen.value]])])):createCommentVNode(``,!0)]))}},VueDebug_default=__plugin_vue_export_helper_default(_sfc_main$8,[[`__scopeId`,`data-v-669cde99`]]),_hoisted_1$6={class:`hint-content`},_hoisted_2$3={key:0,class:`binding-container`},_hoisted_3$2={key:1,class:`text`},_hoisted_4$1={key:1,class:`hint-text`},_sfc_main$7={__name:`Hint`,props:{data:Object},setup(__props){let Controls=controls_default(),props=__props,PROP_DEFAULTS={icon:{color:`white`},binding:{showUnassigned:!0,dark:!1}},hintRef=ref(null),bindingRefs=ref([]),hintContent=computed(()=>{let hints=props.data?[props.data.content].flat():[],res=[],label;for(let hint of hints)typeof hint==`string`?label=hint:(hint.label&&(label=hint.label),res.push({...hint,label:void 0}));return label&&res.push(label),res}),bindingView=computed(()=>{let res=hintContent.value.filter(item=>typeof item!=`string`);for(let item of res)if(item.type===`binding`){if(item.props?.viewerObj){item.viewerObjs=[item.props.viewerObj];continue}let viewerObjs=Controls.makeViewerObj({...PROP_DEFAULTS[item.type],...item.props,actionVariants:!0,useLastDevice:!0});viewerObjs?.variants?item.viewerObjs=viewerObjs.variants:item.viewerObjs=[viewerObjs]}return res}),labelView=computed(()=>hintContent.value.find(item=>typeof item==`string`)||bindingView.value.find(item=>item.label)?.label),bindingDisplayed=computed(()=>!!(bindingRefs.value.some(ref$1=>ref$1.displayed)||bindingView.value.some(item=>item.type===`icon`)||labelView.value));function onClick(evt){if(lastFocused&&document.body.contains(lastFocused)&&!setFocusExternal(lastFocused,!0,!1))try{lastFocused.focus?.()}catch{}props.data.action?.(evt)}let lastFocused;function trackFocus(evt){let target=evt?.detail?.target||evt?.target||document.activeElement;if(!target){lastFocused=null;return}if(target=target.closest(NAVIGABLE_ELEMENTS_SELECTOR),!target){lastFocused=null;return}if(target===lastFocused)return;let button=hintRef.value?.getElement?.();target!==button&&!button.contains(target)&&(lastFocused=target)}return onMounted(()=>window.addEventListener(`uinav-focus`,trackFocus)),onBeforeUnmount(()=>window.removeEventListener(`uinav-focus`,trackFocus)),(_ctx,_cache)=>withDirectives((openBlock(),createBlock(unref(bngButton_default),{ref_key:`hintRef`,ref:hintRef,class:normalizeClass([`hint`,{"flash-on":__props.data.flash}]),accent:unref(ACCENTS).text,disabled:!__props.data.action,onClick:withModifiers(onClick,[`stop`]),"bng-no-nav":``,tabindex:`-1`},{default:withCtx(()=>[createBaseVNode(`div`,_hoisted_1$6,[bindingView.value.length>0?(openBlock(),createElementBlock(`div`,_hoisted_2$3,[(openBlock(!0),createElementBlock(Fragment,null,renderList(bindingView.value,(item,idx)=>(openBlock(),createElementBlock(`span`,{key:idx,class:`rich`},[item.type===`icon`?(openBlock(),createBlock(unref(bngIcon_default),mergeProps({key:0,class:`icon`},{ref_for:!0},{...PROP_DEFAULTS[item.type],...item.props}),null,16)):createCommentVNode(``,!0),(openBlock(!0),createElementBlock(Fragment,null,renderList(item.viewerObjs,(viewerObj,index)=>(openBlock(),createBlock(unref(bngBinding_default),mergeProps({key:index,ref_for:!0,ref_key:`bindingRefs`,ref:bindingRefs,class:`binding`},{ref_for:!0},{...PROP_DEFAULTS[item.type],...item.props,viewerObj},{"track-ignore":``}),null,16))),128)),item.hold?(openBlock(),createElementBlock(`span`,_hoisted_3$2,toDisplayString(item.hold?`[hold]`:``),1)):createCommentVNode(``,!0)]))),128))])):createCommentVNode(``,!0),labelView.value?(openBlock(),createElementBlock(`span`,_hoisted_4$1,toDisplayString(_ctx.$tt(labelView.value)),1)):createCommentVNode(``,!0)])]),_:1},8,[`class`,`accent`,`disabled`])),[[vShow,bindingDisplayed.value]])}},Hint_default=__plugin_vue_export_helper_default(_sfc_main$7,[[`__scopeId`,`data-v-29a63ba0`]]),_hoisted_1$5={key:0,class:`info-bar-stats`},_hoisted_2$2={key:0},_hoisted_3$1={key:0,class:`divider`},_hoisted_4={key:0},_hoisted_5={class:`sysinfo`},_hoisted_6={class:`sysinfo`},_hoisted_7={key:1,class:`info-bar-buttons`,"bng-no-child-nav":`true`},_sfc_main$6={__name:`InfoBar`,setup(__props){let{visible,showSysInfo,withAngular,hints}=storeToRefs(useInfoBar()),showBuildInfo=ref(!1),toggleBuildInfo=()=>showBuildInfo.value=!showBuildInfo.value,route=useRoute(),solidBar=computed(()=>route.name===`menu.mainmenu`?!sysInfo_default.mainMenuBackgroundRequired.value:withAngular.value);return(_ctx,_cache)=>withDirectives((openBlock(),createElementBlock(`div`,{class:normalizeClass([`info-bar`,{"info-bar-solid":solidBar.value}]),"bng-no-nav":`true`},[unref(showSysInfo)?(openBlock(),createElementBlock(`div`,_hoisted_1$5,[withDirectives(createVNode(unref(bngIcon_default),{style:{"--bng-icon-size":`1.25em`,padding:`0`},type:unref(sysInfo_default).online?unref(icons).globeSimplified:unref(icons).globeSimpleNotSign},null,8,[`type`]),[[unref(BngTooltip_default),unref(sysInfo_default).online?`Online`:`Offline`,`top`]]),(openBlock(!0),createElementBlock(Fragment,null,renderList(unref(sysInfo_default).serviceProviders.value,(info,key)=>(openBlock(),createElementBlock(Fragment,null,[unref(sysInfo_default).serviceProvidersOnline.value[key]?(openBlock(),createElementBlock(`span`,_hoisted_2$2,[createVNode(unref(bngImageAsset_default),{src:`images/mainmenu/${key}icon.png`},null,8,[`src`]),createTextVNode(` `+toDisplayString(info.playerName)+` `,1),info.branch&&info.branch!==`public`?withDirectives((openBlock(),createBlock(unref(bngIcon_default),{key:0,style:{"--bng-icon-size":`1.25em`,padding:`0`},type:unref(icons).branch},null,8,[`type`])),[[unref(BngTooltip_default),`Branch: `+info.branch,`top`]]):createCommentVNode(``,!0),createTextVNode(` `+toDisplayString(info.branch&&info.branch!==`public`?info.branch:``),1)])):createCommentVNode(``,!0)],64))),256)),unref(sysInfo_default).online||unref(sysInfo_default).serviceProvidersOnline.value.any?(openBlock(),createElementBlock(`span`,_hoisted_3$1)):createCommentVNode(``,!0),createBaseVNode(`span`,{onClick:toggleBuildInfo},[showBuildInfo.value?(openBlock(),createElementBlock(Fragment,{key:1},[createBaseVNode(`span`,_hoisted_5,`Alpha v.`+toDisplayString(unref(sysInfo_default).version),1),createBaseVNode(`span`,_hoisted_6,toDisplayString(unref(sysInfo_default).buildInfo),1)],64)):(openBlock(),createElementBlock(`span`,_hoisted_4,`Alpha v.`+toDisplayString(unref(sysInfo_default).versionSimple),1))])])):createCommentVNode(``,!0),_cache[0]||=createBaseVNode(`div`,{class:`spacer`},null,-1),unref(hints).length?(openBlock(),createElementBlock(`div`,_hoisted_7,[(openBlock(!0),createElementBlock(Fragment,null,renderList(unref(hints),item=>(openBlock(),createBlock(Hint_default,{key:item.id,data:item},null,8,[`data`]))),128))])):createCommentVNode(``,!0)],2)),[[vShow,unref(visible)],[unref(BngBlur_default),solidBar.value&&!unref(sysInfo_default).mainMenuBackgroundRequired.value]])}},InfoBar_default=__plugin_vue_export_helper_default(_sfc_main$6,[[`__scopeId`,`data-v-cb5f8971`]]),_hoisted_1$4=[`accent`],_sfc_main$5={__name:`TopBarItem`,props:{icon:{type:String,required:!0},active:{type:Boolean,default:void 0},label:String,iconOnly:Boolean,iconPosition:{type:String,default:`left`},accent:{type:String,default:`default`}},setup(__props){let props=__props,item=ref(null);return watch(()=>props.active,value=>{typeof value==`boolean`&&(value?(item.value.setAttribute(`active`,`true`),item.value.removeAttribute(NO_NAV_ATTR)):(item.value.removeAttribute(`active`),item.value.setAttribute(NO_NAV_ATTR,`true`)))}),(_ctx,_cache)=>withDirectives((openBlock(),createElementBlock(`div`,{ref_key:`item`,ref:item,class:normalizeClass([`topbar-item`,{"icon-only":__props.iconOnly}]),accent:__props.accent,"bng-nav-item":``,"bng-no-nav":`true`,tabindex:`-1`},[createVNode(unref(bngIcon_default),{class:`topbar-item-icon`,type:__props.icon},null,8,[`type`]),__props.label&&!__props.iconOnly?(openBlock(),createBlock(unref(textScroller_default),{key:0,class:`topbar-item-text`},{default:withCtx(()=>[createTextVNode(toDisplayString(_ctx.$t(__props.label)),1)]),_:1})):createCommentVNode(``,!0)],10,_hoisted_1$4)),[[unref(BngSoundClass_default),`bng_click_hover_generic`]])}},TopBarItem_default=__plugin_vue_export_helper_default(_sfc_main$5,[[`__scopeId`,`data-v-2c3015cd`]]),_hoisted_1$3={class:`topbar`},_hoisted_2$1={class:`topbar-section topbar-left`},_hoisted_3={class:`topbar-section topbar-center`},_sfc_main$4={__name:`TopBar`,setup(__props,{expose:__expose}){let topBar=useTopBar(),{visible,items:items$2,activeItem,gameState:gameState$1}=storeToRefs(topBar),overflowContainer=ref(null),pauseButtonTarget=ref(null),showTabBindings=ref(!0),showBackBinding=ref(!0),onItemClicked=item=>{activeItem.value!==item.id&&(activeItem.value=item.id,topBar.selectEntry(item.id))},backStack=new Map,customBack=null;function setBack(id,fn){if(!id)throw Error("Usage: TopBar.setBack(id, [fn]), where `id` is your unique id and `fn` is a custom back function that will fire and expected to return `true` or `false` (undefined return means `true`), which will dis-/allow the base back functionality.");typeof fn==`function`?backStack.set(id,fn):backStack.delete(id),customBack=Array.from(backStack.values()).at(-1)||null}let onBack=()=>{let res=customBack?.();res===void 0&&(res=!0),res&&(gameState$1.isInGame?window.bngVue.gotoGameState(`play`):window.globalAngularRootScope?.$broadcast(`MenuToggle`))},onContinue=()=>{window.bngVue.gotoAngularState(`play`)};return watch(()=>activeItem.value,val=>{if(activeItem.value!==null&&items$2.value.length>0){let idx=items$2.value.findIndex(item=>item.id===val);overflowContainer.value.activate(idx)}else overflowContainer.value.deactivate()}),__expose({pauseButtonTarget:computed(()=>visible.value?pauseButtonTarget.value:null),setBack,showTabBindings,showBackBinding}),onMounted(()=>{}),onUnmounted(()=>{}),(_ctx,_cache)=>withDirectives((openBlock(),createElementBlock(`div`,_hoisted_1$3,[createBaseVNode(`div`,_hoisted_2$1,[unref(gameState$1).isInGame?withDirectives((openBlock(),createBlock(unref(bngButton_default),{key:0,"track-ignore":``,accent:`custom`,class:`topbar-button`,"bng-no-nav":`true`,tabindex:`-1`,onClick:onContinue},{default:withCtx(()=>[createVNode(unref(bngIcon_default),{type:unref(icons).play},null,8,[`type`]),createVNode(unref(bngBinding_default),{"ui-event":`menu`,controller:``})]),_:1})),[[unref(BngTooltip_default),`Back to gameplay`,`right`]]):createCommentVNode(``,!0),withDirectives((openBlock(),createBlock(unref(bngButton_default),{"track-ignore":``,accent:`custom`,class:`topbar-button back-button`,"bng-no-nav":`true`,tabindex:`-1`,onClick:onBack},{default:withCtx(()=>[createVNode(unref(bngIcon_default),{type:unref(icons).undo},null,8,[`type`]),withDirectives(createVNode(unref(bngBinding_default),{"ui-event":`back`,controller:``},null,512),[[vShow,showBackBinding.value]])]),_:1})),[[unref(BngTooltip_default),`Back one level`,`right`]])]),createBaseVNode(`div`,_hoisted_3,[withDirectives(createVNode(unref(bngOverflowContainer_default),{ref_key:`overflowContainer`,ref:overflowContainer,class:`topbar-overflow-container`,"use-bindings-only":``,"show-bindings":showTabBindings.value},{default:withCtx(()=>[(openBlock(!0),createElementBlock(Fragment,null,renderList(unref(items$2),item=>(openBlock(),createBlock(TopBarItem_default,{key:item.id,icon:item.icon,label:item.label,onClick:$event=>onItemClicked(item)},null,8,[`icon`,`label`,`onClick`]))),128))]),_:1},8,[`show-bindings`]),[[vShow,unref(items$2).length>0]])]),createBaseVNode(`div`,{ref_key:`pauseButtonTarget`,ref:pauseButtonTarget,class:`topbar-section topbar-right`},null,512)])),[[vShow,unref(visible)],[unref(BngBlur_default)]])}},TopBar_default=__plugin_vue_export_helper_default(_sfc_main$4,[[`__scopeId`,`data-v-c4d95c66`]]),_sfc_main$3={__name:`Popup`,props:{type:{type:String,default:`default`,validator:val=>[`default`,`activity`].includes(val)}},setup(__props){let props=__props,popups=computed(()=>popupsView[props.type===`default`?`popups`:`activities`]),popupsWrapper=computed(()=>popupsView[props.type===`default`?`popupsWrapper`:`activitiesWrapper`]),wrapper=ref(),innerWrapper=ref(),shown=reactive({wrapper:!1,popups:!1}),tmr;watch(()=>!!popups.value,cur=>{if(cur===shown.wrapper)return;let body=document.body;cur&&popupsWrapper.value.fade?body.classList.add(`popup-all-hide`):body.classList.remove(`popup-all-hide`),tmr&&clearTimeout(tmr),cur?(shown.wrapper=!0,nextTick(()=>{props.type===`default`&&wrapper.value&&typeof wrapper.value.showModal==`function`&&wrapper.value.showModal(),nextTick(()=>shown.popups=!0)}),popupsWrapper.value.fade&&body.classList.add(`popup-show-hide`)):tmr=setTimeout(()=>{tmr=null,!popups.value&&(body.classList.remove(`popup-show-hide`),shown.popups=!1,shown.wrapper=!1,nextTick(()=>priorityFocus()))},200)});function handleUINavEvents(event){console.log(`POPUP handleUINavEvents stopPropagation`,event),event.stopPropagation()}return(_ctx,_cache)=>(openBlock(),createElementBlock(Fragment,null,[shown.wrapper?withDirectives((openBlock(),createBlock(resolveDynamicComponent(__props.type===`default`?`dialog`:`div`),{key:0,ref_key:`wrapper`,ref:wrapper,class:normalizeClass([`popup-wrapper`,`popup-type-${__props.type}`])},{default:withCtx(()=>[createVNode(Transition,{name:`popup-background`},{default:withCtx(()=>[shown.popups?(openBlock(),createElementBlock(`div`,{key:0,class:normalizeClass([`popup-background`,...popupsWrapper.value.style.map(name=>`background-style-`+name)])},null,2)):createCommentVNode(``,!0)]),_:1}),createVNode(TransitionGroup,{name:`popup-fade`},{default:withCtx(()=>[shown.popups?(openBlock(!0),createElementBlock(Fragment,{key:0},renderList(popups.value,popup=>(openBlock(),createElementBlock(`div`,{key:popup.id,class:normalizeClass([`popup-container`,...popup.position.map(name=>`content-position-`+name),popup.animated?`popup-animated`:`popup-notanimated`,popup.active?`popup-active`:`popup-inactive`])},[(openBlock(),createBlock(resolveDynamicComponent(popup.component.ref),mergeProps({ref_for:!0},popup.props,{popupActive:popup.active,class:[`popup-content`,popup.active?`popup-active`:`popup-inactive`],onReturn:popup.return}),null,16,[`popupActive`,`class`,`onReturn`]))],2))),128)):createCommentVNode(``,!0)]),_:1}),createBaseVNode(`div`,{ref_key:`innerWrapper`,ref:innerWrapper},null,512)]),_:1},8,[`class`])),[[unref(BngBlur_default),popupsWrapper.value.blur],[unref(BngOnUiNav_default),handleUINavEvents,`back,menu`]]):createCommentVNode(``,!0),(openBlock(),createBlock(Teleport,{to:innerWrapper.value,disabled:!innerWrapper.value},[renderSlot(_ctx.$slots,`default`,{},void 0,!0)],8,[`to`,`disabled`]))],64))}},Popup_default=__plugin_vue_export_helper_default(_sfc_main$3,[[`__scopeId`,`data-v-c0bb08d7`]]),_hoisted_1$2={class:`popover-container`},_sfc_main$2={__name:`Popover`,setup(__props){return usePopover(),(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$2))}},Popover_default=__plugin_vue_export_helper_default(_sfc_main$2,[[`__scopeId`,`data-v-86205238`]]),_hoisted_1$1={class:`backgrounds-cache`},_hoisted_2=[`src`],DRIVE=8,TECH=1,_sfc_main$1={__name:`MainBackground`,setup(__props,{expose:__expose}){let bgPathResolve=(product,name,blur$1=!1)=>`images/mainmenu/${product?product+`/`:``}${name}${blur$1?`_blur`:``}.jpg`,_backgrounds={drive:Array.from({length:DRIVE},(_,i)=>bgPathResolve(`drive`,i+1)),drive_blur:Array.from({length:DRIVE},(_,i)=>bgPathResolve(`drive`,i+1,!0)),tech:Array.from({length:TECH},(_,i)=>bgPathResolve(`tech`,i+1)),tech_blur:Array.from({length:TECH},(_,i)=>bgPathResolve(`tech`,i+1,!0)),unofficial:[bgPathResolve(null,`unofficial_version`)],unofficial_blur:[bgPathResolve(null,`unofficial_version`,!0)]},backgroundId=ref(`drive`),backgrounds=computed(()=>({normal:_backgrounds[backgroundId.value],blur:_backgrounds[backgroundId.value+`_blur`]})),carousel=ref();return __expose({carousel:computed(()=>carousel.value),backgrounds:computed(()=>backgrounds.value)}),onMounted(async()=>{let isTech=await Lua_default.extensions.tech_license.isValid();backgroundId.value=isTech?`tech`:`drive`,bngApi.engineLua(`sailingTheHighSeas`,ahoy=>{backgroundId.value=ahoy?`unofficial`:isTech?`tech`:`drive`})}),(_ctx,_cache)=>(openBlock(),createElementBlock(Fragment,null,[createVNode(Slideshow_default,{class:`background-image`,ref_key:`carousel`,ref:carousel,images:backgrounds.value.normal,delay:1e4,transition:``,shuffle:``},null,8,[`images`]),(openBlock(!0),createElementBlock(Fragment,null,renderList(backgrounds.value,list=>(openBlock(),createElementBlock(`div`,_hoisted_1$1,[(openBlock(!0),createElementBlock(Fragment,null,renderList(list,src=>(openBlock(),createElementBlock(`img`,{src:unref(getAssetURL)(src)},null,8,_hoisted_2))),256))]))),256))],64))}},MainBackground_default=__plugin_vue_export_helper_default(_sfc_main$1,[[`__scopeId`,`data-v-6c1f834b`]]),_hoisted_1={id:`vue-app-container`},_sfc_main={__name:`App`,setup(__props){let route=useRoute(),settings$1=useSettings(),bngVue$1=window.bngVue||{},apps=ref([]),appContCnt=ref(0),appTargets=computed(()=>apps.value.reduce((res,{teleport})=>({...res,[teleport]:document.getElementById(teleport.substring(1)),cnt:appContCnt.value}),{}));bngVue$1.updateAppContainer=()=>window.requestAnimationFrame(()=>appContCnt.value=++appContCnt.value%1e5);let contClickThrough=ref(!1);bngVue$1.gotoAngularState=(state=`blank`,params=void 0)=>window.angular&&window.angular.element(document.querySelector(`body`)).controller().changeAngularStateFromVue(state,params),bngVue$1.gotoGameState=(state=`ui-test`,{params=!1,tryAngularJS=!0,blankAngularJS=!0,clickThrough=!1,uiAppsShown=!1}={})=>{let a$1=history.state;if(!router_default.hasRoute(state))window.location.hash=`#/`+state,route&&(handleUiAppsMeta(route,uiAppsShown),router_default.bngUpdateMeta(route)),tryAngularJS&&bngVue$1.gotoAngularState(state,params);else{blankAngularJS&&bngVue$1.gotoAngularState(`blank`);let newroute=router_default.resolve({name:state,params});handleUiAppsMeta(newroute,uiAppsShown),newroute.name===route.name&&router_default.bngUpdateMeta(route),window.location.hash=newroute.href,router_default.replace({name:state,params})}history.replaceState(a$1,``,window.location.toString()),contClickThrough.value=clickThrough};function handleUiAppsMeta(route$1,uiAppsShown){route$1.meta?route$1.meta.uiApps||(route$1.meta.uiApps={}):route$1.meta={uiApps:{}},typeof route$1.meta.uiApps.shown!=`boolean`&&(route$1.meta.uiApps.shown=uiAppsShown)}bngVue$1.getCurrentRoute=()=>router_default.currentRoute.value,bngVue$1.spawnApp=(appName,appId,params=null)=>spawnUiApp(appName,appId,params,apps.value),bngVue$1.destroyApp=appName=>destroyUiApp(appName,apps.value),useFocusManager();let topBar=ref();provide(`setBack`,(id,fn)=>topBar.value?.setBack(id,fn)),provide(`showTopbarTabBindings`,val=>topBar.value&&(topBar.value.showTabBindings=val)),provide(`showTopbarBackBinding`,val=>topBar.value&&(topBar.value.showBackBinding=val));let bgRequired=sysInfo_default.mainMenuBackgroundRequired,mainBackground=ref();return provide(`mainBackground`,computed(()=>mainBackground.value?.carousel)),provide(`mainBackgroundBlur`,computed(()=>mainBackground.value?.backgrounds.blur)),watch([()=>settings$1.values.uiLayoutContentAlignment,()=>settings$1.values.uiLayoutContentWidth],([alignment,width$1])=>{let rootStyle=document.documentElement.style;alignment=LAYOUT_ALIGNMENTS[alignment||`center`],width$1=width$1?`${width$1}px`:`100vw`,window.requestAnimationFrame(()=>{rootStyle.setProperty(`--layout-content-alignment`,alignment),rootStyle.setProperty(`--layout-content-width`,width$1)})},{immediate:!0}),(_ctx,_cache)=>{let _component_router_view=resolveComponent(`router-view`);return openBlock(),createElementBlock(Fragment,null,[unref(bgRequired)?(openBlock(),createBlock(MainBackground_default,{key:0,ref_key:`mainBackground`,ref:mainBackground},null,512)):createCommentVNode(``,!0),unref(route).name===`unknown`?createCommentVNode(``,!0):(openBlock(),createElementBlock(`div`,{key:1,class:normalizeClass({"vue-app-main":!0,"click-through":contClickThrough.value||unref(route).meta&&unref(route).meta.clickThrough})},[createVNode(TopBar_default,{ref_key:`topBar`,ref:topBar},null,512),createVNode(_component_router_view),createVNode(InfoBar_default)],2)),createVNode(pauseButton_default,{"teleport-to":topBar.value?.pauseButtonTarget},null,8,[`teleport-to`]),unref(route).name===`unknown`?(openBlock(),createBlock(Popup_default,{key:2,type:`activity`})):createCommentVNode(``,!0),createVNode(Popup_default,null,{default:withCtx(()=>[createVNode(Popover_default)]),_:1}),createVNode(LoadingScreen_default),createVNode(VueDebug_default),createBaseVNode(`div`,_hoisted_1,[(openBlock(!0),createElementBlock(Fragment,null,renderList(apps.value,(app$1,index)=>(openBlock(),createElementBlock(Fragment,{key:app$1.appKey},[appTargets.value[app$1.teleport]?(openBlock(),createBlock(Teleport,{key:0,to:app$1.teleport},[(openBlock(),createBlock(resolveDynamicComponent(app$1.comp),mergeProps({ref_for:!0},app$1.props),null,16))],8,[`to`])):createCommentVNode(``,!0)],64))),128))])],64)}}},App_default=__plugin_vue_export_helper_default(_sfc_main,[[`__scopeId`,`data-v-eef28b65`]]);function customDisposePlugin(context){let store$1=context.store,{$dispose,dispose:dispose$2}=store$1;store$1.$dispose=()=>{$dispose(),dispose$2&&typeof dispose$2==`function`&&dispose$2()}}window.watchdogInit=init,window.Vue=vue_esm_bundler_exports;var deps={Emitter:eventemitter3_default,beamng:window.beamng};window.bngApi&&(deps.overrideAPI=window.bngApi),setBridgeDependencies(deps);var bridge=useBridge();window.bridge=bridge,sysInfo_default.init(),initFocusVisible(),bridge.uiNavService=new UINavService(bridge.events),setUINavServiceInstance(bridge.uiNavService),bridge.uiNavService.initialize();var pinia=createPinia().use(()=>({$game:bridge})).use(customDisposePlugin),app=createApp(App_default).use(router_default).use(pinia).use(registerApps,apps_exports);useGameContextStore(),window.bngVue={start:()=>{window.vueGlobalStore||(window.vueGlobalStore=reactive({}));let globals={$game:bridge,$console:logger_default,$logger:logger_default,$simplemenu:ref(!!window.beamng?.simplemenu),$globalStore:window.vueGlobalStore},{i18n,plugin:translationPlugin$1}=initTranslation();app.use(i18n).use(translationPlugin$1());for(let[key,value]of Object.entries(globals))app.config.globalProperties[key]=value,app.provide(key,value);app.mount(`#vue-app`);let controlsStore=controls_default();window.bngVue.controls={getControllers:()=>controlsStore.controllers,getPlayers:()=>controlsStore.players,getCategories:()=>controlsStore.categories,getCategoriesList:()=>controlsStore.categoriesList,findBindingForAction:controlsStore.findBindingForAction,getActionDetails:controlsStore.getActionDetails,getBindingDetails:controlsStore.getBindingDetails,getAllBindingsForAction:controlsStore.getAllBindingsForAction,addNewBinding:controlsStore.addNewBinding,updateBinding:controlsStore.updateBinding,deleteBinding:controlsStore.deleteBinding,deleteBindings:controlsStore.deleteBindings,deviceIcon:controlsStore.deviceIcon,isFFBBound:controlsStore.isFFBBound,isFFBEnabled:controlsStore.isFFBEnabled,isFFBCapable:controlsStore.isFFBCapable,isGamepadAvailable:controlsStore.isGamepadAvailable,captureBinding:controlsStore.captureBinding,makeViewerObj:controlsStore.makeViewerObj,isControllerAvailable:controlsStore.isControllerAvailable,isControllerUsed:controlsStore.isControllerUsed,showIfController:controlsStore.showIfController,focusIfController:controlsStore.focusIfController,refreshData:()=>bridge.lua.extensions.core_input_bindings.notifyUI(`Vue exposed controls service needs the data`)},window.bngVue.uiNavTracker=useUINavTracker(),window.bngVue.topBar=useTopBar()},startTest:()=>{app.mount(`#vue-app`)},isProd:!0,icons},window.beamng||window.bngVue.start({i18n:window.i18n});
        if core_camera then core_camera.requestConfig() end    -- cameraConfig
      `);async function init$3(){for(let key in active=!0,(window.beamng&&!window.beamng.shipping||editor)&&(watchers$1.push(watch(()=>settingsValues.value,updateSettingsList)),watchers$1.push(watch(()=>layout.value,async()=>{await settings$1.waitForData(),updateSettingsList()}))),events$3.on(`SettingsChanged`,()=>settingsTimestamp.value=Date.now()),watchers$1.push(watch(customValues,()=>settingsTimestamp.value=Date.now(),{deep:!0})),events$3.on(`externalUIURL`,data=>customValues.externalUIURL=data||``),events$3.on(`OpenXRStateChanged`,data=>customValues.openXRstate=data),events$3.on(`CameraConfigChanged`,data=>{customValues.cameraConfigList=Array.isArray(data.cameraConfig)?data.cameraConfig:[],customValues.cameraConfigFocused=data.focusedCamName}),updateCustom(),await settings$1.waitForData(),settings$1.values)initialValues[key]=settings$1.values[key];settingsTimestamp.value=Date.now(),setupSearch(layout,settingsValues,settingsOptions,settingsTimestamp,conditions)}let settingsValues=computed(()=>{if(!active||!settings$1.values)return{};let res={...settings$1.values};for(let key in valueFormatters)res[key]=valueFormatters[key](res[key],settings$1.values,customValues);for(let key in valueExtensions)res[key]=valueExtensions[key](settings$1.values,customValues);return res}),settingsOptions=computed(()=>{let res={};if(!active||!settings$1.options||!settings$1.values)return res;for(let key in settings$1.options)key in optionFormatters?res[key]=optionFormatters[key](settings$1.options[key],settings$1.options,settings$1.values):res[key]=guessOptionFormat(settings$1.options[key]);for(let key in optionExtensions)res[key]=optionExtensions[key](settings$1.options,settings$1.values);return res}),editor=null,layout=ref(layout_default);function updateSettingsList(){if(!active)return;settingsList.value=Object.keys(settingsValues.value).reduce((res,name)=>({...res,[name]:{assigned:!1,assignedIn:[],value:settingsValues.value[name],options:settingsOptions.value[name],elementId:name.split(`.`)}}),{});function dive(items$2,cat,catIndex,level$1=0,parentId=``){for(let i=0;i{let values=name in applyValueFormatters?applyValueFormatters[name](value):{[name]:value};for(let key in name.startsWith(`debug_`)&&(customValues.debug[name.substring(6)]=value,name===`debug_visualization`&&(customValues.debug.visualization_prev&&api$1.engineLua(customValues.debug.visualization_prev),customValues.debug.visualization_prev=value,api$1.engineLua(value))),values)key in settings$1.values||delete values[key];Object.keys(values).length>0&&(logger_default.debug(`Applying:`,JSON.stringify(values)),settings$1.apply(values),updateCustom())};function dispose$2(){active=!1,settingsList.value={};for(let unwatch of watchers$1)unwatch();watchers$1.splice(0),settingsTimestamp.value=0,disposeSearch(),null?.dispose()}return provide(`settingsValues`,settingsValues),provide(`settingsOptions`,settingsOptions),provide(`settingsTimestamp`,settingsTimestamp),provide(`settingsList`,settingsList),provide(`conditions`,conditions),provide(`buildItemId`,buildItemId),{init:init$3,dispose:dispose$2,versions:VERSIONS,version:VERSIONS[0],settings:settings$1,settingsList,settingsValues,settingsOptions,settingsTimestamp,applySetting,buildItemId,layout,conditions,editable:!1,editor:null,searchText,searchResults,searchTemplates:{message:(...args)=>searchTemplates.message(layout,...args),headers:(...args)=>searchTemplates.headers(layout,...args),group:(...args)=>searchTemplates.group(layout,...args)}}}var _hoisted_1$19={class:`options-wrapper`,"bng-ui-scope":`options`},_hoisted_2$13={class:`options-heading`},_hoisted_3$12={key:0,class:`options-container`},_hoisted_4$9={class:`background`},_hoisted_5$8={class:`options-content-wrapper`},_hoisted_6$5={class:`options-message`},_hoisted_7$5={class:`message-content`},_hoisted_8$3={key:1,class:`options-categories`},_hoisted_9$2={key:0,class:`categories-divider`},_hoisted_10$1={key:2,class:`options-container`},_hoisted_11$1={class:`options-subcategories`},_hoisted_12$1={class:`background`},_hoisted_13$1={key:0,class:`categories-divider`},_hoisted_14$1={key:1,class:`categories-spacer`},_hoisted_15$1={key:0,class:`categories-spacer`},_hoisted_16$1={key:1,class:`categories-divider`},_hoisted_17$1={class:`options-content-wrapper`},_hoisted_18$1={key:0,class:`options-add-item`},_hoisted_19$1={key:1,class:`options-content`,"bng-ui-scope":`options-content`},_hoisted_20$1={key:2,class:`options-content`,"bng-ui-scope":`options-content`},_hoisted_21$1={class:`background`},_hoisted_22$1=[`innerHTML`],_hoisted_23$1={key:0,class:`options-info-fps`},_sfc_main$23={__name:`OptionsView`,props:{category:String},setup(__props){useUINavScope(`options`);let router$1=useRouter(),route=useRoute(),{api:api$1}=useBridge(),options=useOptions(),loaded=ref(!1),itemsContainer=ref(null),activeScope=ref(``),props=__props;provide(`version`,options.version);let EditUI=ref(null),itemEdit=(...args)=>EditUI.value?.functions.itemEdit?.(...args),categoryEdit=(...args)=>EditUI.value?.functions.categoryEdit?.(...args),catItemsPaste=(...args)=>EditUI.value?.functions.catItemsPaste?.(...args);provide(`EditUI`,EditUI);let editable=ref(!1);provide(`editable`,editable);let categories=computed(()=>options.layout.value.items||[]),categoryIds=computed(()=>categories.value.map(cat=>cat.categoryId)),categoryIndex=ref(-1);provide(`categoryIndex`,categoryIndex);let allCategories=computed(()=>{let cats=[...categories.value].map(cat=>({...cat})),startIndex=0;for(let i=0;istartIndex&&(cats[ri].subcategoryMode=hadSpacer?`none`:ri===i?`last`:ri===startIndex+1?`first`:`middle`)}}else startIndex=i,cat.indexRange=[i,i]}let hidden=[];for(let cat of cats)if(!(!cat.condition_visible||cat.condition_visible in options.conditions&&options.conditions[cat.condition_visible](options.settingsValues.value)))if(cat.subcategory)hidden.push(cat.categoryIndex);else for(let i=cat.indexRange[0];i<=cat.indexRange[1];i++)hidden.push(i);return options.editable?cats.map(cat=>(cat.hiddenByCondition=hidden.includes(cat.categoryIndex),cat.debugSettings=cat.condition_visible===`__notForShipping`,cat)):hidden.length>0?cats.filter(cat=>!hidden.includes(cat.categoryIndex)):cats}),categoriesView=computed(()=>allCategories.value.filter(cat=>!cat.subcategory&&!cat.persistent&&!cat.spacer)),categoryRange=computed(()=>categoriesView.value.find(cat=>categoryIndex.value>=cat.indexRange[0]&&categoryIndex.value<=cat.indexRange[1])?.indexRange||[categoryIndex.value,categoryIndex.value]),subcategoriesView=computed(()=>{let res=categoryIndex.value===-1?[]:allCategories.value.filter(cat=>!cat.persistent&&cat.categoryIndex>=categoryRange.value[0]&&cat.categoryIndex<=categoryRange.value[1]);return res.length>0&&(res[0]={...res[0],label:`ui.options.general`}),res}),persistentView=computed(()=>allCategories.value.filter(cat=>cat.persistent)),itemsNew=ref([]),itemsNewShow=ref(!1),itemsNewView=computed(()=>itemsNewShow.value?itemsNew.value:[]);options.editor&&watch(options.layout,()=>itemsNew.value.splice(0));function renderNewOptions(doRender=!0){if(itemsNewShow.value=doRender,!doRender||itemsNew.value.length>0)return;function dive(parent){if(parent.version!==options.version)for(let i=parent.items.length-1;i>=0;i--){let item=parent.items[i];item.items&&(item.items.length>0&&dive(item),item.items.length>0)||item.version!==options.version&&parent.items.splice(i,1)}}let layout=JSON.parse(JSON.stringify(options.layout.value.items));for(let i=layout.length-1;i>=0;i--){let cat=layout[i];dive(cat),cat.items.length>0&&itemsNew.value.push(options.searchTemplates.group(cat.label,cat.icon,cat.items))}}provide(`renderNewOptions`,renderNewOptions);let itemsView=computed(()=>[...categoryIndex.value>-1&&categoryIndex.value{renderNewOptions(!1),categoryIndex.value>-1&&(special.value=null,searchActive.value=!1,options.searchText.value=``),itemsContainer.value&&itemsContainer.value.scrollTo({top:0,behavior:`instant`})}),watch(special,()=>{special.value&&(categoryIndex.value=-1,searchActive.value=!1,options.searchText.value=``)});let searchActive=ref(!1),searchFocused=ref(!1);watch(searchFocused,focused$1=>{focused$1?(searchActive.value=!0,categoryIndex.value=-1,special.value=null):options.searchText.value.length===0&&(searchActive.value=!1,categoryIndex.value=0)});let elCategories=ref(null),elSearch=ref(null),elSearchBinding=ref(null);watch(()=>elSearch.value?.scopeActivated,active=>{activeScope.value=active?``:`content`});function toSearchAndBack(){elSearch.value&&(elSearch.value.scopeActivated=!elSearch.value.scopeActivated)}function fromContent(){searchActive.value?elSearch.value.scopeActivated=!0:activeScope.value=`subcategories`}function mainCatNav(evt){!elCategories.value||!evt.detail||(options.searchText.value=``,elSearch.value.scopeActivated=!1,searchActive.value=!1,activeScope.value=`subcategories`,evt.detail.name===`tab_l`?elCategories.value.activatePrev():evt.detail.name===`tab_r`&&elCategories.value.activateNext(),evt.stopPropagation())}function catNavigate(cat){cat.reroute?window.bngVue.gotoAngularState(cat.reroute):categoryIndex.value!==cat.categoryIndex&&(categoryIndex.value=cat.categoryIndex)}provide(`goToSetting`,(catIndex,itemId)=>{categoryIndex.value=catIndex,nextTick(()=>{let elm=document.getElementById(itemId);elm?(elm.scrollIntoView({behavior:`smooth`,block:`center`}),elm.classList.add(`options-setting-highlight`),setTimeout(()=>elm?.classList.remove(`options-setting-highlight`),5e3)):logger_default.warn(`Setting item not found: ${itemId}`)})});function onChange(data,value){options.applySetting(data.setting,value);let lua;switch(data.itemType){case`checkbox`:value===!0||value===`enable`?lua=data.lua:(value===!1||value===`disable`)&&(lua=data.luaOff);break;default:lua=data.lua}lua&&runLua(lua,value)}function onClick(data){data.lua&&runLua(data.lua)}function runLua(code,value=void 0){code.toLowerCase().includes(`%value%`)&&value!==void 0&&(code=code.replace(/%value%/gi,api$1.serializeToLua(value))),code.toLowerCase().includes(`%values%`)&&(code=code.replace(/%values%/gi,api$1.serializeToLua(options.settings.values)));let isLua=!code.startsWith(`$`);logger_default.log(`Running ${isLua?`lua`:`script`}: ${code}`),isLua?api$1.engineLua(code):api$1.engineScript(code)}function updateRoute(){if(!loaded.value||route.path!==`/options`&&!route.path.startsWith(`/options/`))return;let newRoute={name:`options`};categoryIndex.value>-1&&categoryIndex.valuecategoryIndex.value,(index,oldIndex)=>{index>-1?(special.value=null,updateRoute(),options.editor?.clearSelection(),showCategoryInfo(index,categories.value[index]?.categoryInfo),showCategoryInfo(oldIndex)):showCategoryInfo(oldIndex)}),watch(()=>special.value,val=>{val&&(categoryIndex.value=-1,updateRoute())});function selectDefaultCategory(){if(categories.value.length===0)return!1;if(props.category){let catIndex=categoryIds.value.indexOf(props.category);catIndex>-1?categoryIndex.value=catIndex:special.value=props.category}else categoryIndex.value=0;return!0}let elInfo=ref(),infos=new Map,infoHidden=ref(!1),infoView=ref([]);function showInfo(id,text=void 0){if(infos.has(id))if(text){if(infos.get(id)===text)return}else infos.delete(id);else if(!text)return;text&&infos.set(id,text),infos.size===0?infoView.value=[]:infoView.value=Array.from(infos.entries()).sort((a$1,b)=>a$1[0]-b[0]).map(tip=>({id:tip[0],text:tip[1]}))}function onResize(){elInfo.value&&(infoHidden.value=window.getComputedStyle(elInfo.value).display===`none`)}let unwatchResize=watch(elInfo,()=>{elInfo.value&&(unwatchResize(),onResize())});provide(`showInfo`,showInfo),provide(`infoHidden`,infoHidden);let fps=ref(`?`),fpsShown=ref(!1),fpsTimer;function showFps(show=!0){if(fpsShown.value=show,fpsTimer)show||(clearInterval(fpsTimer),fps.value=`?`,fpsTimer=null);else if(show){let fpsUpdate=()=>{infoHidden.value||api$1.engineLua(`getConsoleVariable("fps::avg")`,val=>fps.value=val?Number(val).toFixed(1):`?`)};fpsTimer=setInterval(fpsUpdate,500),fpsUpdate()}}let catInfoFuncs={fps:showFps},catInfoStack=new Map;function showCategoryInfo(id,info=void 0){if(!id)return;catInfoStack.has(id)&&!info?catInfoStack.delete(id):info&&catInfoStack.set(id,info);let infos$1=Array.from(catInfoStack.values()).reduce((res,name)=>res.includes(name)?res:[...res,name],[]);for(let[name,func]of Object.entries(catInfoFuncs))func(infos$1.includes(name))}function disposeCategoryInfo(){for(let func of Object.values(catInfoFuncs))func(!1)}function back(){editable.value?editable.value=!1:window.bngVue.gotoAngularState(`menu.mainmenu`)}return onBeforeMount(async()=>{api$1.engineLua(`if getCurrentLevelIdentifier() then simTimeAuthority.pushPauseRequest('options') end`)}),onMounted(()=>{if(options.init().then(()=>{loaded.value=!0,nextTick(()=>activeScope.value=`subcategories`)}),!selectDefaultCategory()){let unwatchCats=watch(categories,()=>selectDefaultCategory()&&unwatchCats())}window.addEventListener(`resize`,onResize)}),onUnmounted(()=>{options.searchText.value=``,window.removeEventListener(`resize`,onResize),disposeCategoryInfo(),options.dispose(),api$1.engineLua(`if getCurrentLevelIdentifier() then simTimeAuthority.popPauseRequest('options') end`)}),(_ctx,_cache)=>withDirectives((openBlock(),createElementBlock(`div`,_hoisted_1$19,[createBaseVNode(`div`,_hoisted_2$13,[createVNode(unref(bngScreenHeading_default),null,{default:withCtx(()=>[createTextVNode(toDisplayString(_ctx.$tt(`ui.options.options`)),1)]),_:1}),unref(options).editor&&EditUI.value?(openBlock(),createBlock(resolveDynamicComponent(EditUI.value.default),{key:0,options:unref(options),categories:categories.value,"category-index":categoryIndex.value,"onUpdate:categoryIndex":_cache[0]||=$event=>categoryIndex.value=$event,special:special.value,"onUpdate:special":_cache[1]||=$event=>special.value=$event,editable:editable.value,"onUpdate:editable":_cache[2]||=$event=>editable.value=$event},null,40,[`options`,`categories`,`category-index`,`special`,`editable`])):createCommentVNode(``,!0)]),loaded.value?createCommentVNode(``,!0):(openBlock(),createElementBlock(`div`,_hoisted_3$12,[createVNode(BlurBackground_default),withDirectives(createBaseVNode(`div`,_hoisted_4$9,null,512),[[unref(BngBlur_default)]]),createBaseVNode(`div`,_hoisted_5$8,[createBaseVNode(`div`,_hoisted_6$5,[createBaseVNode(`div`,_hoisted_7$5,toDisplayString(_ctx.$t(`ui.repository.loading`)),1)])])])),loaded.value?(openBlock(),createElementBlock(`div`,_hoisted_8$3,[createVNode(unref(bngOverflowContainer_default),{ref_key:`elCategories`,ref:elCategories,class:`categories-container`,"initial-index":0,"use-bindings-only":``},{default:withCtx(()=>[(openBlock(!0),createElementBlock(Fragment,null,renderList(categoriesView.value,cat=>(openBlock(),createElementBlock(Fragment,{key:`cat-`+cat.categoryIndex},[cat.divider?(openBlock(),createElementBlock(`div`,_hoisted_9$2)):(openBlock(),createBlock(CategoryTop_default,{key:1,id:`options-cat-`+cat.categoryIndex,index:cat.categoryIndex,"has-subcategories":cat.hasSubcategories,selected:cat.categoryIndex>=categoryRange.value[0]&&cat.categoryIndex<=categoryRange.value[1],icon:cat.icon,onClick:$event=>catNavigate(cat,!1),"hidden-by-condition":cat.hiddenByCondition,"debug-settings":cat.debugSettings,editable:editable.value,onEditCmd:categoryEdit},{default:withCtx(()=>[createTextVNode(toDisplayString(_ctx.$tt(cat.label)),1)]),_:2},1032,[`id`,`index`,`has-subcategories`,`selected`,`icon`,`onClick`,`hidden-by-condition`,`debug-settings`,`editable`]))],64))),128))]),_:1},512),createBaseVNode(`div`,{class:normalizeClass([`options-search-input`,{"search-active":searchActive.value}])},[createVNode(unref(bngBinding_default),{ref_key:`elSearchBinding`,ref:elSearchBinding,class:`search-binding`,"ui-event":`context`,controller:``},null,512),createVNode(unref(bngInputNew_default),{ref_key:`elSearch`,ref:elSearch,class:`search-input`,modelValue:unref(options).searchText.value,"onUpdate:modelValue":_cache[3]||=$event=>unref(options).searchText.value=$event,modelModifiers:{trim:!0},"leading-icon":elSearchBinding.value?.displayed?null:unref(icons).search,"floating-label":_ctx.$tt(`ui.common.search`),"show-external-button":searchActive.value,onFocus:_cache[4]||=$event=>searchFocused.value=!0,onBlur:_cache[5]||=$event=>searchFocused.value=!1},null,8,[`modelValue`,`leading-icon`,`floating-label`,`show-external-button`])],2)])):createCommentVNode(``,!0),loaded.value?(openBlock(),createElementBlock(`div`,_hoisted_10$1,[withDirectives((openBlock(),createElementBlock(`div`,_hoisted_11$1,[createVNode(BlurBackground_default),withDirectives(createBaseVNode(`div`,_hoisted_12$1,null,512),[[unref(BngBlur_default)]]),(openBlock(!0),createElementBlock(Fragment,null,renderList(subcategoriesView.value,cat=>(openBlock(),createElementBlock(Fragment,{key:`cat-`+cat.categoryIndex},[cat.divider?(openBlock(),createElementBlock(`div`,_hoisted_13$1)):cat.spacer?(openBlock(),createElementBlock(`div`,_hoisted_14$1)):(openBlock(),createBlock(CategorySide_default,{key:2,id:`options-cat-`+cat.categoryIndex,index:cat.categoryIndex,"has-subcategories":cat.hasSubcategories,selected:cat.categoryIndex===categoryIndex.value,subcategory:cat.subcategoryMode,icon:cat.icon,"hidden-by-condition":cat.hiddenByCondition,"debug-settings":cat.debugSettings,onClick:$event=>catNavigate(cat),onFocus:$event=>catNavigate(cat,!1)},{default:withCtx(()=>[createTextVNode(toDisplayString(_ctx.$tt(cat.label)),1)]),_:2},1032,[`id`,`index`,`has-subcategories`,`selected`,`subcategory`,`icon`,`hidden-by-condition`,`debug-settings`,`onClick`,`onFocus`]))],64))),128)),subcategoriesView.value.length===0&&allCategories.value[categoryIndex.value]?.persistent?(openBlock(),createBlock(CategorySide_default,{key:0,icon:allCategories.value[categoryIndex.value].icon,selected:``},{default:withCtx(()=>[createTextVNode(toDisplayString(_ctx.$tt(allCategories.value[categoryIndex.value].label)),1)]),_:1},8,[`icon`])):createCommentVNode(``,!0),searchActive.value?(openBlock(),createBlock(CategorySide_default,{key:1,icon:`search`,selected:``},{default:withCtx(()=>[createTextVNode(toDisplayString(_ctx.$tt(`ui.common.search`)),1)]),_:1})):special.value===`categories-edit`?(openBlock(),createBlock(CategorySide_default,{key:2,icon:`listIndented`,selected:``},{default:withCtx(()=>[..._cache[11]||=[createTextVNode(`Edit categories`,-1)]]),_:1})):createCommentVNode(``,!0),persistentView.value.length>0?(openBlock(),createElementBlock(Fragment,{key:3},[_cache[13]||=createBaseVNode(`div`,{class:`categories-spacer`},null,-1),editable.value&&special.value===`categories-edit`?(openBlock(),createElementBlock(Fragment,{key:0},[(openBlock(!0),createElementBlock(Fragment,null,renderList(persistentView.value,cat=>(openBlock(),createBlock(CategorySide_default,{key:`cat-`+cat.categoryIndex,id:`options-cat-`+cat.categoryIndex,"has-subcategories":cat.hasSubcategories,subcategory:cat.subcategoryMode,icon:cat.icon,index:cat.categoryIndex,"hidden-by-condition":cat.hiddenByCondition,"debug-settings":cat.debugSettings,editable:``,onClick:$event=>categoryEdit(`edit`,cat.categoryIndex),onEditCmd:categoryEdit},{default:withCtx(()=>[createTextVNode(toDisplayString(cat.spacer||cat.divider?`---`:_ctx.$tt(cat.label)),1)]),_:2},1032,[`id`,`has-subcategories`,`subcategory`,`icon`,`index`,`hidden-by-condition`,`debug-settings`,`onClick`]))),128)),createVNode(CategorySide_default,{icon:`plus`,onClick:_cache[6]||=$event=>categoryEdit(`add`,!0),style:normalizeStyle(editable.value?{}:{opacity:0,pointerEvents:`none`})},{default:withCtx(()=>[..._cache[12]||=[createTextVNode(`New category`,-1)]]),_:1},8,[`style`])],64)):(openBlock(!0),createElementBlock(Fragment,{key:1},renderList(persistentView.value,cat=>(openBlock(),createElementBlock(Fragment,{key:`cat-`+cat.categoryIndex},[cat.spacer?(openBlock(),createElementBlock(`div`,_hoisted_15$1)):cat.divider?(openBlock(),createElementBlock(`div`,_hoisted_16$1)):(openBlock(),createBlock(CategorySide_default,{key:2,id:`options-cat-`+cat.categoryIndex,"has-subcategories":cat.hasSubcategories,selected:cat.categoryIndex===categoryIndex.value,subcategory:cat.subcategoryMode,icon:cat.icon,index:cat.categoryIndex,"hidden-by-condition":cat.hiddenByCondition,"debug-settings":cat.debugSettings,onClick:$event=>catNavigate(cat)},{default:withCtx(()=>[createTextVNode(toDisplayString(_ctx.$tt(cat.label)),1)]),_:2},1032,[`id`,`has-subcategories`,`selected`,`subcategory`,`icon`,`index`,`hidden-by-condition`,`debug-settings`,`onClick`]))],64))),128))],64)):createCommentVNode(``,!0)])),[[unref(BngScopedNav_default),{activated:!searchActive.value&&activeScope.value===`subcategories`,bubbleWhitelistEvents:[`context`]}],[unref(BngOnUiNav_default),mainCatNav,`tab_l,tab_r`],[unref(BngOnUiNav_default),back,`back,menu`],[unref(BngOnUiNav_default),()=>activeScope.value=`content`,`ok`,{focusRequired:!0}]]),withDirectives((openBlock(),createElementBlock(`div`,_hoisted_17$1,[createVNode(BlurBackground_default,{class:normalizeClass([`background`,{"background-no-info":infoHidden.value}])},null,8,[`class`]),withDirectives(createBaseVNode(`div`,{class:normalizeClass([`background`,{"background-no-info":infoHidden.value}])},null,2),[[unref(BngBlur_default)]]),categoryIndex.value>-1?withDirectives((openBlock(),createElementBlock(`div`,{key:0,ref_key:`itemsContainer`,ref:itemsContainer,class:`options-content`,"bng-ui-scope":`options-content`},[(openBlock(!0),createElementBlock(Fragment,null,renderList(itemsView.value,(item,index)=>(openBlock(),createBlock(Item_default,{key:`item-`+categoryIndex.value*1e5+`-`+index,parent:categories.value[categoryIndex.value],index,level:0,data:item,onClick,onChange,onEditCmd:itemEdit},null,8,[`parent`,`index`,`data`]))),128)),editable.value?(openBlock(),createElementBlock(`div`,_hoisted_18$1,[createVNode(unref(bngButton_default),{accent:unref(ACCENTS).outlined,icon:unref(icons).plus,onClick:_cache[7]||=$event=>unref(options).editor.itemAdd(categories.value[categoryIndex.value])},{default:withCtx(()=>[..._cache[14]||=[createTextVNode(`Add new item`,-1)]]),_:1},8,[`accent`,`icon`]),createVNode(unref(bngButton_default),{accent:unref(ACCENTS).outlined,icon:unref(icons).addListItem,disabled:!unref(options).editor.clipItems.value.length,onClick:_cache[8]||=$event=>catItemsPaste()},{default:withCtx(()=>[createTextVNode(`Paste `+toDisplayString(unref(options).editor.clipTitle.value),1)]),_:1},8,[`accent`,`icon`,`disabled`]),createVNode(unref(bngButton_default),{accent:unref(ACCENTS).outlined,icon:unref(options).editor.selectedItems.value.size>0?unref(icons).checkboxOn:unref(icons).checkboxOff,onClick:_cache[9]||=$event=>unref(options).editor.itemSelectAll(categories.value[categoryIndex.value])},{default:withCtx(()=>[createTextVNode(toDisplayString(unref(options).editor.selectedItems.value.size>0?`Deselect all`:`Select all`),1)]),_:1},8,[`accent`,`icon`])])):createCommentVNode(``,!0)])),[[unref(BngUiNavScroll_default),void 0,void 0,{force:!0}]]):searchActive.value?withDirectives((openBlock(),createElementBlock(`div`,_hoisted_19$1,[(openBlock(!0),createElementBlock(Fragment,null,renderList(unref(options).searchResults.value,(item,index)=>(openBlock(),createBlock(Item_default,{key:`search-`+index,index,level:0,data:item,onClick,onChange},null,8,[`index`,`data`]))),128))])),[[unref(BngUiNavScroll_default),void 0,void 0,{force:!0}]]):special.value===`categories-edit`?(openBlock(),createElementBlock(`div`,_hoisted_20$1,[(openBlock(!0),createElementBlock(Fragment,null,renderList(allCategories.value,cat=>(openBlock(),createElementBlock(Fragment,{key:`cat-`+cat.categoryIndex},[cat.persistent?createCommentVNode(``,!0):(openBlock(),createBlock(CategorySide_default,{key:0,id:`options-cat-`+cat.categoryIndex,"has-subcategories":cat.hasSubcategories,subcategory:cat.subcategoryMode,icon:cat.icon,index:cat.categoryIndex,"hidden-by-condition":cat.hiddenByCondition,"debug-settings":cat.debugSettings,editable:editable.value,onClick:$event=>categoryEdit(`edit`,cat.categoryIndex),onEditCmd:categoryEdit},{default:withCtx(()=>[createTextVNode(toDisplayString(cat.spacer||cat.divider?`---`:_ctx.$tt(cat.label)),1)]),_:2},1032,[`id`,`has-subcategories`,`subcategory`,`icon`,`index`,`hidden-by-condition`,`debug-settings`,`editable`,`onClick`]))],64))),128)),editable.value?(openBlock(),createBlock(CategorySide_default,{key:0,icon:`plus`,onClick:_cache[10]||=$event=>categoryEdit(`add`),style:normalizeStyle(editable.value?{}:{opacity:0,pointerEvents:`none`})},{default:withCtx(()=>[..._cache[15]||=[createTextVNode(`New category`,-1)]]),_:1},8,[`style`])):createCommentVNode(``,!0)])):createCommentVNode(``,!0),createBaseVNode(`div`,{ref_key:`elInfo`,ref:elInfo,class:normalizeClass([`options-info`,{"info-hidden":!!special.value}])},[createVNode(BlurBackground_default),withDirectives(createBaseVNode(`div`,_hoisted_21$1,null,512),[[unref(BngBlur_default)]]),(openBlock(!0),createElementBlock(Fragment,null,renderList(infoView.value,tip=>(openBlock(),createElementBlock(`span`,{key:tip.id,innerHTML:tip.text},null,8,_hoisted_22$1))),128)),_cache[17]||=createBaseVNode(`div`,{class:`options-spacer`},null,-1),fpsShown.value?(openBlock(),createElementBlock(`div`,_hoisted_23$1,[_cache[16]||=createTextVNode(`FPS: `,-1),createBaseVNode(`span`,null,toDisplayString(fps.value),1)])):createCommentVNode(``,!0)],2)])),[[unref(BngScopedNav_default),{activated:activeScope.value===`content`,bubbleWhitelistEvents:[`context`]}],[unref(BngOnUiNav_default),mainCatNav,`tab_l,tab_r`],[unref(BngOnUiNav_default),fromContent,`back`],[unref(BngOnUiNav_default),back,`menu`]])])):createCommentVNode(``,!0)])),[[unref(BngOnUiNav_default),mainCatNav,`tab_l,tab_r`],[unref(BngOnUiNav_default),back,`back,menu`],[unref(BngOnUiNav_default),toSearchAndBack,`context`],[unref(BngUiNavLabel_default),`ui.common.search`,`context`]])}},OptionsView_default=__plugin_vue_export_helper_default(_sfc_main$23,[[`__scopeId`,`data-v-206a0fb3`]]),routes_default$12=[{path:`/options/:category?`,name:`options`,component:OptionsView_default,props:!0,meta:{infoBar:{visible:!0,showSysInfo:!0},uiApps:{shown:!1}}}],cfg={background:[`var(--bng-black-o8)`,`var(--bng-black-o4)`],info:{icon:`var(--bng-cool-gray-500)`,iconSize:.15,label:`var(--bng-off-white)`,labelSize:.05,line:`var(--bng-cool-gray-700)`,lineSize:.0025,hotkey:`#aaa`,hotkeySize:.04,unfocusedColor:`var(--bng-cool-gray-500)`,focusedColor:`var(--bng-off-white)`},button:{top:.45,height:.175,margin:.004,corners:.03,background:`var(--bng-black)`,highlight:`var(--bng-ter-blue-gray-700)`,border:`var(--bng-cool-gray-700)`,borderHighlight:`var(--bng-cool-gray-500)`,borderSize:.0025,folder:`var(--bng-ter-blue-gray-900)`,folderTop:.45,folderHeight:.015,markerTop:.3,markerHeight:.025,marker:`var(--bng-orange)`,icon:`var(--bng-off-white)`,iconSize:.1,majorBackground:[`var(--bng-black)`,`var(--bng-ter-blue-gray-850)`],majorHighlight:[`var(--bng-ter-blue-gray-600)`,`var(--bng-ter-blue-gray-700)`],pinnedDotInvisible:{fill:`transparent`,stroke:`transparent`,r:4},markDotSolid:{fill:`rgba(var(--bng-cool-gray-100-rgb),0.7)`,stroke:`transparent`,r:4},markDotOutline:{fill:`transparent`,stroke:`rgba(var(--bng-cool-gray-100-rgb),0.7)`,r:3},markStar:{fill:`rgba(var(--bng-cool-gray-100-rgb),0.7)`,stroke:`rgba(var(--bng-cool-gray-100-rgb),0.7)`,"stroke-width":2,r:3,isStar:!0,starPoints:5,innerRadius:1.5,outerRadius:3}},pointer:{color:`var(--bng-orange)`,size:6}},size=500,pointerRadius=125,controlsHotkey=``,getHotkey=action=>{let viewerObj=controls_default().makeViewerObj({action});return viewerObj?icons[viewerObj.icon].glyph+` `+viewerObj.control.split(/[ -]/).map(s=>s.substring(0,1).toUpperCase()+s.substring(1)).join(`+`):``},RadialSVG=class{parent;svg;config;events;itemsCont;info;buttons;pointer;menuIcon=``;constructor(events$3={},config=cfg,element=void 0){this.events=events$3,this.config=config,element&&this.create(element)}create(element){this.parent!==element&&(this.parent=element,this.svg||([this.svg,this.itemsCont,this.info,this.pointer]=createSvg(this.config)),this.parent.appendChild(this.svg))}update(items$2=[]){!this.itemsCont||!this.info||(controlsHotkey=getHotkey(`menu_item_focus_ud`),this.buttons=updateSvg(this.itemsCont,this.info,items$2,this.events,this.config,this.buttons||[],this))}dispose(){this.parent&&(this.parent.removeChild(this.svg),this.parent=null,this.svg=null,this.itemsCont=null,this.info=null,this.buttons=null)}setPointer(x,y){if(!this.pointer)return;let magnitude=Math.sqrt(x*x+y*y);magnitude>.1?(x/=magnitude,y/=magnitude,this.pointer.setAttribute(`cx`,x*pointerRadius+size/2),this.pointer.setAttribute(`cy`,-y*pointerRadius+size/2),this.pointer.setAttribute(`display`,`block`)):this.pointer.setAttribute(`display`,`none`)}setMenuIcon(iconName){if(this.menuIcon=iconName,this.info){let iconGlyph=getIconGlyph(this.menuIcon);this.info.icon.textContent=iconGlyph}}},svgns=`http://www.w3.org/2000/svg`,xhtmlns=`http://www.w3.org/1999/xhtml`,pid=Math.PI*2,getIconGlyph=iconName=>(iconName&&iconName in icons?icons[iconName]:icons.beamNG).glyph,setAttrs=(elm,attrs)=>Object.entries(attrs).forEach(attr=>elm.setAttribute(...attr)),setStyles=(elm,styles)=>Object.entries(styles).forEach(rule=>elm.style.setProperty(...rule)),f2size=f=>f*size,getPoint=(turn,radius,center=[.5,.5])=>[center[0]+radius*Math.cos(turn*pid),center[1]+radius*Math.sin(turn*pid)].map(n=>f2size(n).toFixed(5)),drawLine=to=>` L ${to.join(`,`)} `,drawBezier=(control,to)=>` S ${control.join(`,`)} ${to.join(` `)} `,drawArc=(to,radius,invert=!1)=>` A ${radius} ${radius}, 0, 0, ${invert?`0`:`1`}, ${to.join(` `)} `;function createSimplePath(pos,rad,width$1,height$1){let d=`M ${getPoint(pos,rad).join(`,`)} `;return d+=drawArc(getPoint(pos+width$1,rad),f2size(rad),!1),d+=drawLine(getPoint(pos+width$1,rad-height$1)),d+=drawArc(getPoint(pos,rad-height$1),f2size(rad-height$1),!0),d+=drawLine(getPoint(pos,rad)),d+=`Z`,d}function createPath({pos,rad,width:width$1,height:height$1,corner,padout,padin}){corner>height$1&&(corner=height$1);let corh=corner*rad/Math.PI,corv=corner*rad,d=`M ${getPoint(pos+padout+corh,rad).join(`,`)} `;return d+=drawArc(getPoint(pos+width$1-padout-corh,rad),f2size(rad),!1),d+=drawBezier(getPoint(pos+width$1-padout,rad),getPoint(pos+width$1-padout,rad-corv)),d+=drawLine(getPoint(pos+width$1-padout-padin,rad-height$1+corv)),d+=drawBezier(getPoint(pos+width$1-padout-padin,rad-height$1),getPoint(pos+width$1-padout-corh-padin,rad-height$1)),d+=drawArc(getPoint(pos+padout+corh+padin,rad-height$1),f2size(rad-height$1),!0),d+=drawBezier(getPoint(pos+padout+padin,rad-height$1),getPoint(pos+padout+padin,rad-height$1+corv)),d+=drawLine(getPoint(pos+padout,rad-corv)),d+=drawBezier(getPoint(pos+padout,rad),getPoint(pos+padout+corh,rad)),d+=`Z`,d}function updateSvg(cont,info,items$2,events$3,config=cfg,buttons=[],radialInstance=null){let btns=[...buttons||[]],elmsRem=btns.splice(items$2.length);for(let elm of elmsRem)cont.removeChild(elm.element);if(items$2.length<1)return null;for(let index=btns.length;indexicon,file:icon=>`/ui/modules/apps/RadialMenu/mods_icons/`+icon,symbol:icon=>`#`+({radial_Drift_ESC:`radial_drift_ESC`,radial_Sport_ESC:`radial_sport_ESC`,radial_Regular_ESC:`radial_regular_ESC`,radial_ESC:`radial_regular_ESC`}[icon]||icon)};function createButton(index,info,config,item){let btn={index},majorGradId=uniqueSafeId(),majorHighlightGradId=uniqueSafeId(),control=document.createElementNS(svgns,`g`);btn.element=control;function createGradient(id,colors){let grad=document.createElementNS(svgns,`radialGradient`);return setAttrs(grad,{id,cx:`0.5`,cy:`0.5`,r:`0.5`,fx:`0.5`,fy:`0.5`}),colors.forEach((color,index$1)=>{let stop$1=document.createElementNS(svgns,`stop`);setAttrs(stop$1,{offset:index$1/(colors.length-1),"stop-color":color}),grad.appendChild(stop$1)}),grad}let defs=document.createElementNS(svgns,`defs`);defs.appendChild(createGradient(majorGradId,config.button.majorBackground)),defs.appendChild(createGradient(majorHighlightGradId,config.button.majorHighlight)),control.appendChild(defs);let button=document.createElementNS(svgns,`path`);config.button.border&&config.button.borderSize>0&&setAttrs(button,{stroke:config.button.border,"stroke-width":f2size(config.button.borderSize)}),control.appendChild(button);let folder=document.createElementNS(svgns,`path`);folder.setAttribute(`fill`,config.button.folder),control.appendChild(folder);let marker$1=document.createElementNS(svgns,`path`);marker$1.setAttribute(`fill`,`none`),control.appendChild(marker$1);let pinnedDot=document.createElementNS(svgns,`circle`);setAttrs(pinnedDot,config.button.markDotSolid),pinnedDot.setAttribute(`style`,`display: none`),control.appendChild(pinnedDot);let starPath=document.createElementNS(svgns,`path`),starConfig=config.button.markStar,points=starConfig.starPoints||5,innerRadius=starConfig.innerRadius||1.5,outerRadius=starConfig.outerRadius||3,starPathData=``;for(let i=0;ion?iconRect.removeAttribute(`style`):iconRect.setAttribute(`style`,`display: none`),setGlyph=glyph=>iconText.textContent=glyph||``,setImage=path=>{path?(iconImage.setAttribute(`href`,path),iconImage.removeAttribute(`style`)):(iconImage.removeAttribute(`href`),iconImage.setAttribute(`style`,`display: none`))},setSymbol=id=>{id?(iconMask.setAttribute(`mask-type`,`luminocity`),iconSymbol.setAttribute(`href`,id),iconSymbol.removeAttribute(`style`)):(iconMask.setAttribute(`mask-type`,`alpha`),iconSymbol.removeAttribute(`href`),iconSymbol.setAttribute(`style`,`display: none`))},itype=iconType(item$1.icon);switch(itype){case`glyph`:setGlyph(getIconGlyph(item$1.icon)),setRect(!1),setImage(),setSymbol();break;case`symbol`:setImage(),setSymbol(iconGet[itype](item$1.icon)),setRect(!0),setGlyph();break;default:setImage(iconGet[itype](item$1.icon)),setSymbol(),setRect(!0),setGlyph();break}}let hitzone=document.createElementNS(svgns,`path`);setAttrs(hitzone,{fill:`transparent`,style:`pointer-events: fill`}),control.appendChild(hitzone);function updateHitzone(position,length,config$1){hitzone.setAttribute(`d`,createSimplePath(position-length/2,config$1.button.top,length,config$1.button.height))}function updateEvents$1(events$3,radialInstance){btn._handlers&&(hitzone.removeEventListener(`mouseover`,btn._handlers.focus),hitzone.removeEventListener(`mouseleave`,btn._handlers.blur),hitzone.removeEventListener(`click`,btn._handlers.click),hitzone.removeEventListener(`mousedown`,btn._handlers.down),hitzone.removeEventListener(`mouseup`,btn._handlers.up),hitzone.removeEventListener(`contextmenu`,btn._handlers.contextMenu));let item$1=btn.item,index$1=btn.index;return btn.menuIcon=radialInstance?.menuIcon||``,btn._handlers={focus(){if(item$1.focused&&btn._focused)return;let highlightFill=item$1.majorButton?`url(#${majorHighlightGradId})`:config.button.highlight;button.setAttribute(`fill`,highlightFill),button.setAttribute(`stroke`,config.button.borderHighlight),marker$1.setAttribute(`fill`,config.button.marker);let itype=iconType(item$1.icon);itype===`glyph`?(setStyles(info.icon,{"background-color":`transparent`,"-webkit-mask-image":`none`,color:config.info.focusedColor}),info.icon.textContent=getIconGlyph(item$1.icon)):(info.icon.textContent=``,itype===`symbol`&&info.iconSymbol.setAttribute(`href`,iconGet[itype](item$1.icon)),setStyles(info.icon,{"background-color":config.info.icon,"-webkit-mask-image":itype===`symbol`?`url('#${info.iconMaskId}')`:`url('${iconGet[itype](item$1.icon)}')`})),info.label.textContent=typeof item$1.title==`string`?$translate.contextTranslate({txt:item$1.title,context:item$1.context}):$translate.contextTranslate(item$1.title),info.label.style.color=config.info.focusedColor,info.price.textContent=item$1?.price?.money?.amount===void 0?``:item$1.price.money.amount+` `,info.hotkey.textContent=item$1.hotkey||``,info.cont.removeAttribute(`style`),item$1.focused=!0,btn._focused=!0,typeof events$3.focus==`function`&&events$3.focus(item$1,index$1)},blur(){if(!item$1.focused&&!btn._focused)return;let normalFill=item$1.majorButton?`url(#${majorGradId})`:config.button.background;button.setAttribute(`fill`,normalFill),button.setAttribute(`stroke`,config.button.border),marker$1.setAttribute(`fill`,`none`),setStyles(info.icon,{"background-color":`transparent`,"-webkit-mask-image":`none`,color:config.info.unfocusedColor});let iconGlyph=getIconGlyph(btn.menuIcon);info.icon.textContent=iconGlyph,info.label.textContent=`Select an option`,info.price.textContent=``,info.hotkey.textContent=controlsHotkey,info.label.style.color=config.info.unfocusedColor,item$1.focused=!1,btn._focused=!1,typeof events$3.blur==`function`&&events$3.blur(item$1,index$1)},click(evt){evt&&evt.stopPropagation(),!(!item$1.enabled||!events$3||evt&&!evt.fromController&&evt.type!==`ui_nav`)&&(btn._handlers.isDown=!1,typeof events$3.click==`function`&&events$3.click(item$1,index$1))},down(evt){!item$1.enabled||!events$3||evt.button!==0||(btn._handlers.isDown=!0,typeof events$3.down==`function`&&events$3.down(item$1,index$1))},up(evt){!btn._handlers.isDown||!item$1.enabled||!events$3||evt.button!==0||(btn._handlers.isDown=!1,typeof events$3.up==`function`&&events$3.up(item$1,index$1))},contextMenu(evt){evt&&evt.stopPropagation(),events$3&&typeof events$3.contextAction==`function`&&events$3.contextAction(item$1,index$1)}},hitzone.addEventListener(`mouseover`,btn._handlers.focus),hitzone.addEventListener(`mouseleave`,btn._handlers.blur),hitzone.addEventListener(`click`,btn._handlers.click,!0),hitzone.addEventListener(`mousedown`,btn._handlers.down),hitzone.addEventListener(`mouseup`,btn._handlers.up),hitzone.addEventListener(`contextmenu`,btn._handlers.contextMenu),btn._handlers}function updateEnable(item$1){item$1.enabled?(hitzone.setAttribute(`cursor`,`pointer`),control.removeAttribute(`opacity`)):(hitzone.removeAttribute(`cursor`),control.setAttribute(`opacity`,`0.5`))}return btn.update=(item$1,events$3=void 0,radialInstance=null)=>{btn.item=item$1;let length=Math.min(item$1.size,.5),position=(item$1.position-.5)%1;updateButton(position,length,config,item$1),updateHitzone(position,length,config),updateIcon(position,length,config,item$1),updateEnable(item$1),btn._handlers=updateEvents$1(events$3,radialInstance),Object.assign(btn,btn._handlers),(item$1.focused||btn._focused)&&btn._handlers.focus()},btn}function createSvg(config=cfg){let svg=document.createElementNS(svgns,`svg`);setAttrs(svg,{viewBox:`0 0 ${size} ${size}`,width:`100%`,height:`100%`,preserveAspectRatio:`xMidYMid meet`,style:`pointer-events: none`});let gradId=Array.isArray(config.background)?uniqueSafeId():null;if(gradId){let grad=document.createElementNS(svgns,`radialGradient`);grad.setAttribute(`id`,gradId);for(let i=0;i{evt.stopPropagation()},!0),svg.appendChild(bg);let nfo={cont:document.createElementNS(svgns,`foreignObject`),body:document.createElementNS(xhtmlns,`body`),wrap:document.createElementNS(xhtmlns,`div`),icon:document.createElementNS(xhtmlns,`div`),iconSymbol:document.createElementNS(svgns,`use`),iconMaskId:uniqueSafeId(),label:document.createElementNS(xhtmlns,`div`),price:document.createElementNS(xhtmlns,`div`),hotkey:document.createElementNS(xhtmlns,`div`)},foMinSize=200,nfoSize=size>=200?size:200;setAttrs(nfo.cont,{style:`display: none`,width:nfoSize,height:nfoSize}),size<200&&nfo.cont.setAttribute(`transform`,`scale(${size*.005})`),nfo.body.setAttribute(`xmlns`,xhtmlns),setStyles(nfo.body,{width:`100%`,height:`100%`}),setStyles(nfo.wrap,{width:`${nfoSize*.5}px`,height:`${nfoSize*.4}px`,margin:`${nfoSize*.3}px ${nfoSize*.25}px`,display:`flex`,"flex-direction":`column`,"align-items":`center`,"justify-content":`space-between`,"font-family":`var(--fnt-defs)`}),setStyles(nfo.icon,{color:config.info.icon,"font-size":`${config.info.iconSize*nfoSize}px`,"font-family":`bngIcons`,width:`${config.info.iconSize*nfoSize}px`,height:`${config.info.iconSize*nfoSize}px`,"-webkit-mask-image":`none`,"-webkit-mask-size":`contain`,"-webkit-mask-position":`50% 50%`,"-webkit-mask-repeat":`no-repeat`,"background-color":`transparent`});let iconSvg=document.createElementNS(svgns,`svg`);setAttrs(iconSvg,{viewBox:`0 0 ${config.info.iconSize*nfoSize} ${config.info.iconSize*nfoSize}`,width:`0`,height:`0`,style:`position: absolute;`});let iconMask=document.createElementNS(svgns,`mask`);setAttrs(iconMask,{id:nfo.iconMaskId,maskUnits:`userSpaceOnUse`,maskContentUnits:`userSpaceOnUse`,"mask-type":`luminocity`}),setAttrs(nfo.iconSymbol,{x:`0`,y:`0`,width:config.info.iconSize*nfoSize,height:config.info.iconSize*nfoSize,fill:`#fff`}),iconMask.appendChild(nfo.iconSymbol),iconSvg.appendChild(iconMask),setStyles(nfo.label,{"min-height":`2em`,width:`100%`,"text-align":`center`,color:config.info.label,"font-size":`${config.info.labelSize*nfoSize}px`,"font-family":`var(--fnt-defs)`}),setStyles(nfo.price,{width:`100%`,"text-align":`center`,color:config.info.label,"font-size":`${config.info.labelSize*.8*nfoSize}px`,"font-family":`bngIcons, var(--fnt-defs)`}),setStyles(nfo.hotkey,{width:`80%`,"text-align":`center`,"padding-top":`1px`,"min-height":`${config.info.hotkeySize*nfoSize+10}px`,"border-top":`${config.info.lineSize*nfoSize}px solid ${config.info.line}`,color:config.info.hotkey,"font-size":`${config.info.hotkeySize*nfoSize}px`,"font-family":`bngIcons, "Noto Sans Mono", var(--fnt-defs)`}),nfo.wrap.appendChild(iconSvg),nfo.wrap.appendChild(nfo.icon),nfo.wrap.appendChild(nfo.label),nfo.wrap.appendChild(nfo.price),nfo.wrap.appendChild(nfo.hotkey),nfo.body.appendChild(nfo.wrap),nfo.cont.appendChild(nfo.body),svg.appendChild(nfo.cont);let cont=document.createElementNS(svgns,`g`);svg.appendChild(cont);let pointer=document.createElementNS(svgns,`circle`);return setAttrs(pointer,{r:config.pointer.size,fill:config.pointer.color,display:`none`}),svg.appendChild(pointer),nfo.icon.textContent=getIconGlyph(svg.menuIcon),nfo.label.textContent=`Select an option`,nfo.price.textContent=``,nfo.label.style.color=config.info.unfocusedColor,controlsHotkey=getHotkey(`menu_item_focus_ud`),nfo.hotkey.textContent=controlsHotkey,nfo.cont.removeAttribute(`style`),[svg,cont,nfo,pointer]}var _hoisted_1$18={class:`radial-infos`},_hoisted_2$12={class:`radial-breadcrumbs`},_hoisted_3$11={key:0,class:`radial-categories`},_hoisted_4$8={class:`radial-plate`},_hoisted_5$7={class:`radial-category-label`},_hoisted_6$4={key:0,class:`radial-quick-tabs`},_hoisted_7$4={key:1,class:`radial-description`},sensivity=.5,_sfc_main$22={__name:`Radial`,setup(__props){useUINavScope(`radialMenu`);let infobar=useInfoBar(),controls$1=controls_default(),events$3=useEvents(),radialData=ref({}),temporaryHidden=ref(!1),breadcrumbs=computed(()=>radialData.value&&radialData.value.breadcrumbs&&Array.isArray(radialData.value.breadcrumbs)?radialData.value.breadcrumbs.map(str=>$translate.instant(str)).join(` / `):``),focusedItem=computed(()=>{let items$2=radialData?.value?.items;return items$2&&Array.isArray(items$2)?items$2.find(item=>item.focused):null}),hasLRShoulderButtons=computed(()=>radialData.value&&radialData.value.hasLRShoulderButtons),radialSvg=new RadialSVG({click:(item,index)=>{Lua_default.ui_audio.playEventSound(`bng_click_hover_generic`,`click`),Lua_default.core_quickAccess.selectItem(index+1,!0,1)},down:(item,index)=>{Lua_default.ui_audio.playEventSound(`bng_click_hover_generic`,`click`),Lua_default.core_quickAccess.selectItem(index+1,!0,1)},focus:(item,index)=>{Lua_default.ui_audio.playEventSound(`bng_click_hover_generic`,`focus`)},contextAction:(item,index)=>{Lua_default.ui_audio.playEventSound(`bng_click_hover_generic`,`focus`),Lua_default.core_quickAccess.contextAction(index+1,!0,1)}}),radialCont=ref(),requestData=async()=>{radialData.value=await Lua_default.core_quickAccess.getUiData();let items$2=Array.isArray(radialData.value.items)?radialData.value.items:[];for(let item of items$2)item.hotkey=getHotkey$1(item.action);radialSvg.setMenuIcon(radialData.value.menuIcon||`beamNG`),radialSvg.update(items$2)},getHotkey$1=action=>{let viewerObj=controls$1.makeViewerObj({action});return viewerObj?icons[viewerObj.icon].glyph+` `+viewerObj.control.split(/[ -]/).map(s=>s.substring(0,1).toUpperCase()+s.substring(1)).join(``):``},setLevel=level$1=>{Lua_default.ui_audio.playEventSound(`bng_click_hover_generic`,`focus`),Lua_default.core_quickAccess.setEnabled(!0,level$1,!1)},close=()=>{Lua_default.core_quickAccess.setEnabled(!1,``,!1)},back=()=>{radialData.value.backButtonIndex?Lua_default.core_quickAccess.back():close()},switchCategory=left=>{let indexOffset=left?-1:1;for(let i=0;i{let actions=radialData.value.items;for(let i=0;i{if(radialData.value.categories.length>0){switchCategory(evt.detail.name===`tab_l`);return}LRAction(evt.detail.name)},processMouseClick=evt=>{if(!radialSvg.buttons)return;let elm=radialSvg?.buttons?.find(elm$1=>elm$1._focused)||radialSvg?.buttons?.find(elm$1=>elm$1.item.focused);return evt.detail.name===`context`?elm&&elm.contextMenu(evt):elm&&elm.click(evt),elm},isStickActive=(x,y)=>Math.sqrt(x**2+y**2)>sensivity,pointToItem=(x,y)=>{if(!radialSvg.buttons)return;let len=radialSvg.buttons.length,idx=-1;if(radialSvg.setPointer(x,y),x!==0||y!==0){let cursorPos=.5-Math.atan2(y,x)/Math.PI/2;for(let i=0;i=startPos&&cursorPos=startPos||cursorPos-1&&idx{evt.detail.name===`focus_ud`?stickY=evt.detail.value:stickX=evt.detail.value;let stickActiveBefore=stickActive;stickActive=isStickActive(stickX,stickY),stickActive&&pointToItem(stickX,stickY),!stickActive&&stickActiveBefore&&pointToItem(0,0)},dpadX=0,dpadY=0,processDpadInput=evt=>{switch(evt.detail.name){case`focus_l`:dpadX=-evt.detail.value;break;case`focus_r`:dpadX=evt.detail.value;break;case`focus_u`:dpadY=evt.detail.value;break;case`focus_d`:dpadY=-evt.detail.value;break}dpadX=0+ +dpadX,dpadY=0+ +dpadY,pointToItem(dpadX,dpadY)},openFavoriteSelector=()=>{if(radialData.value.pathBeforeCategory===`favorites`){for(let i=0;i{let isOnComponents=event.target.closest(`.radial-categories, .radial-svg, .radial-tab-left, .radial-tab-right`);event.isTrusted&&event.sourceCapabilities?.firesTouchEvents===!1&&!isOnComponents&&(event.button===0?close():event.button===2&&back())};events$3.on(`radialMenuUpdated`,requestData),events$3.on(`RadialTemporaryHide`,hide$2=>{temporaryHidden.value=hide$2}),onBeforeMount(()=>{infobar.clearHints()}),onMounted(()=>{infobar.visible=!0,radialSvg.create(radialCont.value),requestData()});let headingTitle=computed(()=>radialData.value?.breadcrumbs?.[0]?$translate.instant(radialData.value.breadcrumbs[0]):radialData.value?.items?.length?`Radial Menu`:`No Actions Available`),hasCategories=computed(()=>radialData.value?.categories&&(Array.isArray(radialData.value.categories)?radialData.value.categories.length>0:Object.keys(radialData.value.categories).length>0));return(_ctx,_cache)=>withDirectives((openBlock(),createElementBlock(`div`,{class:normalizeClass([`radial-menu`,{temporaryHidden:temporaryHidden.value}]),"bng-ui-scope":`radialMenu`,onMousedown:handleMouseDown},[createBaseVNode(`div`,_hoisted_1$18,[createVNode(bngCardHeading_default,{class:`radial-title`},{default:withCtx(()=>[createTextVNode(toDisplayString(headingTitle.value),1)]),_:1}),createBaseVNode(`div`,_hoisted_2$12,toDisplayString(breadcrumbs.value),1),hasCategories.value?(openBlock(),createElementBlock(`div`,_hoisted_3$11,[createVNode(unref(bngBinding_default),{class:`radial-plate radial-tab-left`,"ui-event":`tab_l`,style:normalizeStyle({"--rad-tab-icon":`'${unref(icons).arrowSmallLeft.glyph}'`}),controller:``,onClick:_cache[0]||=$event=>switchCategory(!0)},null,8,[`style`]),createBaseVNode(`div`,_hoisted_4$8,[(openBlock(!0),createElementBlock(Fragment,null,renderList(radialData.value.categories,category=>withDirectives((openBlock(),createBlock(unref(bngImageTile_default),{key:category.id,onClick:$event=>setLevel(category.goto),tabindex:`0`,"bng-nav-item":``,class:normalizeClass([`radial-category`,{selected:category.id===radialData.value.selectedCategory}]),icon:unref(icons)[category.icon||`beamNG`]},{default:withCtx(()=>[createBaseVNode(`div`,_hoisted_5$7,toDisplayString(unref($translate).instant(category.title)),1)]),_:2},1032,[`onClick`,`class`,`icon`])),[[unref(BngOnUiNav_default),void 0,`ok`,{asMouse:!0,focusRequired:!0}]])),128)),_cache[4]||=createBaseVNode(`div`,{class:`background-plate`},null,-1)]),createVNode(unref(bngBinding_default),{class:`radial-plate radial-tab-right`,"ui-event":`tab_r`,controller:``,style:normalizeStyle({"--rad-tab-icon":`'${unref(icons).arrowSmallRight.glyph}'`}),onClick:_cache[1]||=$event=>switchCategory(!1)},null,8,[`style`])])):createCommentVNode(``,!0)]),hasLRShoulderButtons.value?(openBlock(),createElementBlock(`div`,_hoisted_6$4,[createVNode(unref(bngBinding_default),{class:`radial-plate radial-tab-left`,style:normalizeStyle({"--rad-tab-icon":`'${unref(icons).arrowSmallLeft.glyph}'`}),"ui-event":`tab_l`,controller:``,onClick:_cache[2]||=$event=>LRAction(`tab_l`)},null,8,[`style`]),createVNode(unref(bngBinding_default),{class:`radial-plate radial-tab-right`,style:normalizeStyle({"--rad-tab-icon":`'${unref(icons).arrowSmallRight.glyph}'`}),"ui-event":`tab_r`,controller:``,onClick:_cache[3]||=$event=>LRAction(`tab_r`)},null,8,[`style`])])):createCommentVNode(``,!0),createBaseVNode(`div`,{ref_key:`radialCont`,ref:radialCont,class:`radial-svg`},null,512),focusedItem.value?.desc?(openBlock(),createElementBlock(`div`,_hoisted_7$4,toDisplayString(unref(content_exports).bbcode.parse(unref($translate).contextTranslate(focusedItem.value.desc,!0))),1)):createCommentVNode(``,!0)],34)),[[unref(BngBlur_default),!temporaryHidden.value],[unref(BngOnUiNav_default),openFavoriteSelector,`context`],[unref(BngOnUiNav_default),back,`menu,back`],[unref(BngOnUiNav_default),processTabInput,`tab_l,tab_r`],[unref(BngOnUiNav_default),processStickInput,`focus_lr,focus_ud`],[unref(BngOnUiNav_default),processDpadInput,`focus_l,focus_r,focus_u,focus_d`,{down:!0}],[unref(BngOnUiNav_default),processDpadInput,`focus_l,focus_r,focus_u,focus_d`,{up:!0}],[unref(BngOnUiNav_default),processMouseClick,`ok,context`],[unref(BngUiNavLabel_default),radialData.value.backButtonIndex?`ui.common.back`:`ui.common.close`,`menu,back`],[unref(BngUiNavLabel_default),`Radial menu navigation`,`focus_lr,focus_ud,focus_l,focus_r,focus_u,focus_d`],[unref(BngUiNavLabel_default),`Select`,`ok`],[unref(BngUiNavLabel_default),`Configure Slot`,`context`],[unref(BngUiNavLabel_default),`Switch Category`,`tab_l,tab_r`]])}},Radial_default=__plugin_vue_export_helper_default(_sfc_main$22,[[`__scopeId`,`data-v-9330a4cb`]]),routes_default$13=[{path:`/radial`,name:`radial`,component:Radial_default,meta:{uiApps:{shown:!1}}}],routes_default$14=[{path:`/recovery`,name:`recovery`,component:Recovery_default,props:!0}],isFuelEnergyType=type=>[`gasoline`,`diesel`].includes(type);const useRefuelStore=defineStore(`refuel`,()=>{let{events:events$3}=useBridge(),minSlider=23,maxSlider=80,minEnergy=0,fuelOptions=[{id:1,value:0,name:`FuelType-1`},{id:2,value:1,name:`FuelType-2`},{id:3,value:2,name:`FuelType-3`}],energyTypes=ref([]),fuelTanks=ref([]),overallPrice=ref(0),flowRate=ref(0),currentEnergyType=ref(null),showFuelTypeSettings=ref(!1),showAmountSettings=ref(!1),energyTypesToLocalUnits=ref({}),gasStationName=ref(``),fuelDiscountData=ref({}),isFuelling=computed(()=>flowRate.value>0),currentFuelData=computed(()=>fuelTanks.value.filter(f=>f.energyType===currentEnergyType.value)[0]),currentFuelType=computed(()=>currentEnergyType.value===``?``:isFuelEnergyType(currentEnergyType.value)?`fuel`:`charge`),currentFuelLevel=computed(()=>currentFuelData.value?currentFuelData.value.currentEnergy/currentFuelData.value.maxEnergy:0),canRefuel=computed(()=>currentFuelData.value?currentFuelData.value.currentEnergycanRefuel.value===!0?isFuelling.value===!0?`on`:`off`:`disabled`),canPay=computed(()=>currentFuelData.value.price>0),canStartFuelling=computed(()=>isFuelling.value===!1&&canRefuel.value===!0),canStopFuelling=computed(()=>isFuelling.value===!0),minEnergyLabel=computed(()=>`0 `+getUnitLabel(currentEnergyType.value)),maxEnergyLabel=computed(()=>currentFuelData.value?(isFuelEnergyType(currentEnergyType.value)?convertToLocalUnit(currentFuelData.value.maxEnergy,currentEnergyType.value).toFixed(2):`100`)+` `+getUnitLabel(currentEnergyType.value):``);function getUnitLabel(energyType){return isFuelEnergyType(energyType)?getLocalUnitLabel(energyType):`%`}function getLocalUnit(energyType){return energyTypesToLocalUnits.value[energyType]?energyTypesToLocalUnits.value[energyType]:`L`}let unitToLabel={gallonUS:`gal`},factorSIToLocalUnit={gallonUS:.26417};function getLocalUnitLabel(energyType){let localUnit=getLocalUnit(energyType);return localUnit&&unitToLabel[localUnit]?unitToLabel[localUnit]:`L`}function convertToLocalUnit(valueSI,energyType){let localUnit=getLocalUnit(energyType);return localUnit?valueSI*(factorSIToLocalUnit[localUnit]||1):valueSI}function convertToPricePerLocalUnit(pricePerSI,energyType){let localUnit=getLocalUnit(energyType);return localUnit?pricePerSI/(factorSIToLocalUnit[localUnit]||1):pricePerSI}function startFuelling(){Lua_default.career_modules_fuel.uiButtonStartFueling(currentEnergyType.value)}function stopFuelling(){Lua_default.career_modules_fuel.uiButtonStopFueling(currentEnergyType.value)}function changeFlowRate(newFlowRate){flowRate.value=newFlowRate,Lua_default.career_modules_fuel.onChangeFlowRate(flowRate.value)}function payPrice(){Lua_default.career_modules_fuel.payPrice()}function requestFuelingData(){Lua_default.career_modules_fuel.requestRefuelingTransactionData(),runInBrowser(()=>getMockedData(`career.initialFuelingData`).then(data=>events$3.emit(`initialFuelingData`,data)))}function cancelTransaction(){console.log(`cancelTransaction`),Lua_default.career_modules_fuel.uiCancelTransaction()}function dispose$2(){events$3.off(`initialFuelingData`),events$3.off(`updateFuelData`)}return events$3.on(`initialFuelingData`,data=>{({fuelData:fuelTanks.value,energyTypes:energyTypes.value}=data),currentEnergyType.value=energyTypes.value[0],energyTypesToLocalUnits.value=data.energyTypesToLocalUnits,factorSIToLocalUnit.value=data.factorSIToLocalUnit,gasStationName.value=data.gasStationName,fuelDiscountData.value=data.fuelDiscountData||{},Lua_default.career_modules_fuel.sendUpdateDataToUI()}),events$3.on(`updateFuelData`,data=>{fuelTanks.value.length!==0&&(fuelTanks.value[0].currentEnergy=data.fuelData[0].currentEnergy,fuelTanks.value[0].fueledEnergy=data.fuelData[0].fueledEnergy,fuelTanks.value[0].price=data.fuelData[0].price,overallPrice.value=data.overallPrice,flowRate.value=data.fuelData[0].fuelingActive===!0?1:0)}),{currentFuelData,currentFuelLevel,currentFuelType,currentEnergyType,nozzleMode,overallPrice,isFuelling,energyTypes,canPay,canStartFuelling,canStopFuelling,fuelDiscountData,showFuelTypeSettings,showAmountSettings,gasStationName,startFuelling,stopFuelling,changeFlowRate,payPrice,requestFuelingData,cancelTransaction,getUnitLabel,convertToPricePerLocalUnit,dispose:dispose$2,minEnergyLabel,maxEnergyLabel,minSlider:23,maxSlider:80,fuelOptions}});var _hoisted_1$17={class:`full`,xmlns:`http://www.w3.org/2000/svg`,"xmlns:xlink":`http://www.w3.org/1999/xlink`,x:`0`,y:`0`,viewBox:`6 0 280 280`,width:`280`,height:`280`},_hoisted_2$11={id:`glow`,x:`-40%`,y:`-40%`,width:`180%`,height:`180%`},_hoisted_3$10=[`flood-color`],_hoisted_4$7={class:`gauge-label`},_hoisted_5$6={class:`info`},DASH_ARR_LENGTH=455,GAUGE_TYPES=[`refuel`,`recharge`],GAUGE_DEFAULTS={refuel:{cssColour:`var(--bng-orange-b400)`,gradientColour:`255,102,0`,icon:icons.fuelPumpFilling},recharge:{cssColour:`var(--bng-add-blue-600)`,gradientColour:`95,157,249`,icon:icons.charging}},_sfc_main$21={__name:`FuelGauge`,props:{value:{type:Number,default:0},type:{type:String,default:`refuel`,validator:v=>GAUGE_TYPES.includes(v)||v===``},fuelling:{type:Boolean,default:!1},label:String,maxLabel:String,minLabel:String},setup(__props){window.bngVue.isProd;let props=__props,gaugeLevelStyle=computed(()=>({stroke:GAUGE_DEFAULTS[props.type].cssColour,fill:`none`,strokeDasharray:DASH_ARR_LENGTH,strokeDashoffset:DASH_ARR_LENGTH-props.value*DASH_ARR_LENGTH})),gaugeStyle=computed(()=>({background:`radial-gradient(22% 22% at 50% 53%, rgba(${GAUGE_DEFAULTS[props.type].gradientColour}, 0.76) 0%, rgba(${GAUGE_DEFAULTS[props.type].gradientColour}, 0.18) 64.06%, rgba(${GAUGE_DEFAULTS[props.type].gradientColour}, 0) 100%)`}));return(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,{class:normalizeClass({"gauge-wrapper":!0,[__props.type]:!0})},[createBaseVNode(`div`,{class:normalizeClass({"pulse-container":!0,pulsing:__props.fuelling})},[createBaseVNode(`div`,{class:`pulser`,style:normalizeStyle(gaugeStyle.value)},null,4)],2),(openBlock(),createElementBlock(`svg`,_hoisted_1$17,[createBaseVNode(`defs`,null,[createBaseVNode(`filter`,_hoisted_2$11,[createBaseVNode(`feFlood`,{"flood-color":GAUGE_DEFAULTS[__props.type].cssColour,result:`flood1`},null,8,_hoisted_3$10),_cache[0]||=createStaticVNode(``,4)])]),_cache[1]||=createBaseVNode(`path`,{class:`gauge-back`,d:`M50,210 A110,110 0 1,1 244,210`,style:{fill:`none`}},null,-1),createBaseVNode(`path`,{class:`gauge-level blur`,d:`M50,210 A110,110 0 1,1 244,210`,style:normalizeStyle(gaugeLevelStyle.value)},null,4),createBaseVNode(`path`,{class:`gauge-level`,d:`M50,210 A110,110 0 1,1 244,210`,style:normalizeStyle(gaugeLevelStyle.value)},null,4)])),createVNode(unref(bngIcon_default),{class:`icon refill-icon`,type:GAUGE_DEFAULTS[__props.type].icon,color:`#fff`},null,8,[`type`]),createBaseVNode(`div`,_hoisted_4$7,[createBaseVNode(`span`,null,toDisplayString(__props.minLabel),1),createBaseVNode(`span`,_hoisted_5$6,toDisplayString(__props.label||`\xA0`),1),createBaseVNode(`span`,null,toDisplayString(__props.maxLabel),1)])],2))}},FuelGauge_default=__plugin_vue_export_helper_default(_sfc_main$21,[[`__scopeId`,`data-v-04de51fb`]]),_hoisted_1$16={class:`fuel-type`},_sfc_main$20={__name:`FuelTypeSettings`,props:{fuelOptions:{type:Array,required:!0}},emits:[`previousClick`,`nextClick`,`fuelTypeSelect`],setup(__props,{emit:__emit}){let emit$1=__emit;return(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$16,[createVNode(unref(bngButton_default),{class:`arrow empty`,accent:unref(ACCENTS).text,"data-testid":`previous-btn`,icon:unref(icons).arrowLargeLeft,onClick:_cache[0]||=$event=>emit$1(`previousClick`)},{default:withCtx(()=>[createVNode(unref(bngBinding_default),{class:`controller`,"ui-event":`tab_l`,deviceMask:`xinput`})]),_:1},8,[`accent`,`icon`]),createVNode(unref(bngPillFilters_default),{options:__props.fuelOptions},null,8,[`options`]),createVNode(unref(bngButton_default),{class:`arrow empty`,accent:unref(ACCENTS).text,"data-testid":`next-btn`,iconRight:unref(icons).arrowLargeRight,onClick:_cache[1]||=$event=>emit$1(`nextClick`)},{default:withCtx(()=>[createVNode(unref(bngBinding_default),{class:`controller`,"ui-event":`tab_r`,deviceMask:`xinput`})]),_:1},8,[`accent`,`iconRight`])]))}},FuelTypeSettings_default=__plugin_vue_export_helper_default(_sfc_main$20,[[`__scopeId`,`data-v-bf968fb2`]]),nozzleModes={on:{color:`var(--bng-orange-b400)`,buttonEnabled:!0},off:{color:`var(--bng-black-o6)`,buttonEnabled:!0},disabled:{color:`var(--bng-black-o2)`,buttonEnabled:!1}},fuellingModes$1={fuel:{nozzleIconType:icons$1.general.fuel_nozzle},charge:{nozzleIconType:icons$1.general.recharge_connector}},_sfc_main$19={__name:`FuelNozzle`,props:{refuelType:{type:String,required:!0},nozzleMode:{type:String,default:`off`}},emits:[`triggerDown`,`triggerUp`],setup(__props,{emit:__emit}){let{showIfController}=storeToRefs(controls_default()),props=__props,emit$1=__emit,nozzleImageURL=computed(()=>`icons/${typeSettings.value.nozzleIconType}.svg`),typeSettings=computed(()=>fuellingModes$1[props.refuelType]),modeSettings=computed(()=>nozzleModes[props.nozzleMode]),nozzleClass=computed(()=>({nozzle:!0,[props.refuelType]:!0}));return(_ctx,_cache)=>(openBlock(),createBlock(unref(bngImageAsset_default),{mask:``,class:normalizeClass(nozzleClass.value),src:nozzleImageURL.value,"bg-color":modeSettings.value.color},{default:withCtx(()=>[createVNode(unref(bngButton_default),{"bng-no-nav":`true`,class:normalizeClass({empty:!0,gamepad:unref(showIfController)}),disabled:!modeSettings.value.buttonEnabled,onMousedown:_cache[0]||=$event=>emit$1(`triggerDown`),onMouseup:_cache[1]||=$event=>emit$1(`triggerUp`),accent:unref(ACCENTS).text},{default:withCtx(()=>[createVNode(unref(bngBinding_default),{action:`fuelVehicle`,deviceMask:`xinput`,disabled:!modeSettings.value.buttonEnabled,accent:unref(ACCENTS).text},null,8,[`disabled`,`accent`]),unref(showIfController)?createCommentVNode(``,!0):(openBlock(),createBlock(unref(bngIcon_default),{key:0,type:unref(icons).plus,title:`Activate`},null,8,[`type`]))]),_:1},8,[`class`,`disabled`,`accent`])]),_:1},8,[`class`,`src`,`bg-color`]))}},FuelNozzle_default=__plugin_vue_export_helper_default(_sfc_main$19,[[`__scopeId`,`data-v-3a31f67d`]]),_hoisted_1$15={class:`cost`},_hoisted_2$10={class:`price`},_hoisted_3$9={class:`per-unit`},_hoisted_4$6={class:`value`},_hoisted_5$5={class:`unit`},_sfc_main$18={__name:`FuelInfo`,props:{totalCost:{type:Number,required:!0},pricePerUnit:{type:Number,required:!0},unitLabel:{type:String,required:!0},fuelDiscountData:{type:Object,required:!1}},setup(__props){let refuelStore=useRefuelStore(),displayPrice=computed(()=>Math.floor(refuelStore.convertToPricePerLocalUnit(props.pricePerUnit,refuelStore.currentEnergyType)*100)+.9),props=__props;return(_ctx,_cache)=>(openBlock(),createElementBlock(Fragment,null,[createBaseVNode(`div`,_hoisted_1$15,[createVNode(unref(bngUnit_default),{money:__props.totalCost},null,8,[`money`]),__props.fuelDiscountData.hasFuelDiscount?(openBlock(),createBlock(insurancePerkIcon_default,{key:0,class:`perk-icon`,perkIconData:__props.fuelDiscountData.perkData},null,8,[`perkIconData`])):createCommentVNode(``,!0)]),createBaseVNode(`div`,_hoisted_2$10,[createBaseVNode(`span`,_hoisted_3$9,[createBaseVNode(`span`,_hoisted_4$6,toDisplayString(displayPrice.value),1),_cache[0]||=createBaseVNode(`span`,{class:`divider`},null,-1),createBaseVNode(`span`,_hoisted_5$5,toDisplayString(unref(refuelStore).getUnitLabel(unref(refuelStore).currentEnergyType)),1)])])],64))}},FuelInfo_default=__plugin_vue_export_helper_default(_sfc_main$18,[[`__scopeId`,`data-v-c4955aba`]]),_hoisted_1$14={class:`amount`},_hoisted_2$9={class:`slider-labels`},_hoisted_3$8={class:`amount-value`},_sfc_main$17={__name:`FuelAmountSettings`,props:{minSlider:{type:Number,default:23},maxSlider:{type:Number,default:80},unitLabel:String},setup(__props){return(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$14,[createVNode(unref(bngButton_default),{class:`top-up`,accent:`text`},{default:withCtx(()=>[createVNode(unref(bngBinding_default),{class:`controller`,"ui-event":`focus_u`,deviceMask:`xinput`}),_cache[0]||=createTextVNode(`Top-up`,-1)]),_:1}),createBaseVNode(`div`,_hoisted_2$9,[createBaseVNode(`span`,null,toDisplayString(`${__props.minSlider}${__props.unitLabel}`),1),createBaseVNode(`span`,null,toDisplayString(`${__props.maxSlider}${__props.unitLabel}`),1)]),createVNode(unref(bngSlider_default),{min:__props.minSlider,max:__props.maxSlider,onValueChanged:()=>{}},null,8,[`min`,`max`]),createBaseVNode(`div`,_hoisted_3$8,[createVNode(unref(bngButton_default),{accent:unref(ACCENTS).text,class:`empty`},{default:withCtx(()=>[createVNode(unref(bngBinding_default),{class:`controller`,"ui-event":`focus_l`,deviceMask:`xinput`})]),_:1},8,[`accent`]),createVNode(unref(bngInput_default),{class:`value`,suffix:`L`,"initial-value":`1234567`}),createVNode(unref(bngButton_default),{accent:unref(ACCENTS).text,class:`empty`},{default:withCtx(()=>[createVNode(unref(bngBinding_default),{class:`controller`,"ui-event":`focus_r`,deviceMask:`xinput`})]),_:1},8,[`accent`])])]))}},FuelAmountSettings_default=__plugin_vue_export_helper_default(_sfc_main$17,[[`__scopeId`,`data-v-9de32e0e`]]),_hoisted_1$13={class:`gauge`},_hoisted_2$8={key:0,class:`settings content`},_hoisted_3$7={class:`status-container`},fuellingModes={fuel:{title:`ui.career.refuelling.modes.fuel.title`,gaugeType:`refuel`,nozzleIconType:icons$1.general.fuel_nozzle,fuellingOngoingLabel:`ui.career.refuelling.modes.fuel.ongoing`,startLabel:`ui.career.refuelling.modes.fuel.start`,unitLabel:`L`},charge:{title:`ui.career.refuelling.modes.charge.title`,gaugeType:`recharge`,nozzleIconType:icons$1.general.recharge_connector,fuellingOngoingLabel:`ui.career.refuelling.modes.charge.ongoing`,startLabel:`ui.career.refuelling.modes.charge.start`,unitLabel:`kWh`}},_sfc_main$16={__name:`RefuelMain`,setup(__props){let{$game}=useLibStore(),refuelStore=useRefuelStore(),mainSettings=computed(()=>fuellingModes[refuelStore.currentFuelType]);onBeforeMount(()=>{refuelStore.requestFuelingData()}),onBeforeUnmount(()=>{refuelStore.cancelTransaction()}),onUnmounted(()=>{refuelStore.$dispose()});let store$1=useTasksStore();provide(`animationSettings`,{animate:!0,animateOnMount:!1,animateOnMountIntervalDelay:.2,animateOnEmptyIntervalDelay:.1,animateOnEmpty:!0,animateNextTask:!0,successCallback:playAudio});function playAudio(){$game.lua.Engine.Audio.playOnce(`AudioGui`,`event:>UI>Career>Checkbox`)}return(_ctx,_cache)=>(openBlock(),createElementBlock(Fragment,null,[unref(refuelStore).currentFuelData?(openBlock(),createBlock(unref(layoutSingle_default),{key:0},{default:withCtx(()=>[createVNode(unref(bngCard_default),{class:`refuel-card`},{buttons:withCtx(()=>[unref(refuelStore).canPay?(openBlock(),createBlock(unref(bngButton_default),{key:0,onClick:_cache[2]||=$event=>unref(refuelStore).payPrice()},{default:withCtx(()=>[..._cache[5]||=[createTextVNode(`Pay`,-1)]]),_:1})):createCommentVNode(``,!0),unref(refuelStore).canStartFuelling?(openBlock(),createBlock(unref(bngButton_default),{key:1,onClick:_cache[3]||=$event=>unref(refuelStore).startFuelling()},{default:withCtx(()=>[createTextVNode(toDisplayString(_ctx.$t(mainSettings.value.startLabel)),1)]),_:1})):unref(refuelStore).canStopFuelling?(openBlock(),createBlock(unref(bngButton_default),{key:2,onClick:_cache[4]||=$event=>unref(refuelStore).stopFuelling()},{default:withCtx(()=>[..._cache[6]||=[createTextVNode(`Stop`,-1)]]),_:1})):createCommentVNode(``,!0)]),default:withCtx(()=>[createVNode(unref(bngCardHeading_default),{type:`ribbon`},{default:withCtx(()=>[createTextVNode(toDisplayString(_ctx.$t(unref(refuelStore).gasStationName)),1)]),_:1}),createBaseVNode(`div`,_hoisted_1$13,[createVNode(FuelGauge_default,{class:`main-gauge`,fuelling:unref(refuelStore).isFuelling,type:mainSettings.value.gaugeType,value:unref(refuelStore).currentFuelLevel,label:unref(refuelStore).isFuelling?_ctx.$t(mainSettings.value.fuellingOngoingLabel):``,minLabel:unref(refuelStore).minEnergyLabel,maxLabel:unref(refuelStore).maxEnergyLabel},null,8,[`fuelling`,`type`,`value`,`label`,`minLabel`,`maxLabel`])]),createVNode(FuelNozzle_default,{"refuel-type":unref(refuelStore).currentFuelType,"nozzle-mode":unref(refuelStore).nozzleMode,onTriggerDown:_cache[0]||=$event=>unref(refuelStore).changeFlowRate(1),onTriggerUp:_cache[1]||=$event=>unref(refuelStore).changeFlowRate(0)},null,8,[`refuel-type`,`nozzle-mode`]),createVNode(FuelInfo_default,{"total-cost":unref(refuelStore).overallPrice,"price-per-unit":unref(refuelStore).currentFuelData.pricePerUnit,"unit-label":mainSettings.value.unitLabel,"fuel-discount-data":unref(refuelStore).fuelDiscountData},null,8,[`total-cost`,`price-per-unit`,`unit-label`,`fuel-discount-data`]),unref(refuelStore).showFuelTypeSettings||unref(refuelStore).showAmountSettings?(openBlock(),createElementBlock(`div`,_hoisted_2$8,[unref(refuelStore).showFuelTypeSettings?(openBlock(),createBlock(FuelTypeSettings_default,{key:0,"fuel-options":unref(refuelStore).fuelOptions},null,8,[`fuel-options`])):createCommentVNode(``,!0),unref(refuelStore).showAmountSettings?(openBlock(),createBlock(FuelAmountSettings_default,{key:1,"min-slider":unref(refuelStore).minSlider,"max-slider":unref(refuelStore).maxSlider,"unit-label":mainSettings.value.unitLabel},null,8,[`min-slider`,`max-slider`,`unit-label`])):createCommentVNode(``,!0)])):createCommentVNode(``,!0)]),_:1})]),_:1})):createCommentVNode(``,!0),createBaseVNode(`div`,_hoisted_3$7,[createVNode(unref(careerStatus_default),{class:`profileStatus`}),createVNode(unref(TaskList_default),{class:`tasklist`,header:unref(store$1).header,tasks:unref(store$1).tasks},null,8,[`header`,`tasks`])])],64))}},RefuelMain_default=__plugin_vue_export_helper_default(_sfc_main$16,[[`__scopeId`,`data-v-d87fd4e5`]]),routes_default$15=[{path:`/refueling`,name:`refueling`,component:RefuelMain_default,meta:{uiApps:{shown:!1}}}],_hoisted_1$12=[`innerHTML`],_sfc_main$15={__name:`ReleaseInfo`,setup(__props){useUINavScope(`releaseInfo`);let settings$1=useSettings(),parseDescription=descKey=>parse$1($translate.instant(descKey)),descriptionHtml=computed(()=>parseDescription(`ui.releaseInfo.description`)),onFinish=async()=>{backToMenu()},backToMenu=()=>window.bngVue.gotoAngularState(`menu.mainmenu`);return onMounted(async()=>{await settings$1.waitForData()}),(_ctx,_cache)=>withDirectives((openBlock(),createBlock(unref(WizardView_default),{title:`ui.releaseInfo.title`,preheadings:[`v.${unref(sysInfo_default).versionSimple}`],style:{"--wizard-height":`45rem`},"bng-ui-scope":`releaseInfo`,onWizardFinish:onFinish},{default:withCtx(()=>[createVNode(unref(WizardStep_default),{id:`releaseInfo`,title:`ui.releaseInfo.stepTitle`},{default:withCtx(()=>[createBaseVNode(`div`,{innerHTML:descriptionHtml.value},null,8,_hoisted_1$12)]),_:1})]),_:1},8,[`preheadings`])),[[unref(BngBlur_default)],[unref(BngOnUiNav_default),backToMenu,`menu,back`]])}},ReleaseInfo_default=_sfc_main$15,routes_default$16=[{name:`menu.release-info`,path:`/release-info`,component:ReleaseInfo_default,meta:{infoBar:{visible:!0,showSysInfo:!0},uiApps:{shown:!1}}}],_hoisted_1$11={class:`veh-debug`},_hoisted_2$7={class:`buttons`},_hoisted_3$6={class:`buttons`},_hoisted_4$5={class:`bng-short-select-item`},_hoisted_5$4={class:`label-width`},_hoisted_6$3={key:0},_hoisted_7$3={class:`parts-switch-label`},_hoisted_8$2={class:`control-row`},_hoisted_9$1={class:`control-label`},_hoisted_10={class:`control-row`},_hoisted_11={class:`control-label`},_hoisted_12={key:0},_hoisted_13={class:`control-row`},_hoisted_14={class:`control-label indented`},_hoisted_15={class:`control-group`},_hoisted_16={class:`control-row`},_hoisted_17={class:`control-label indented`},_hoisted_18={class:`control-group`},_hoisted_19={class:`control-row`},_hoisted_20={class:`control-label indented`},_hoisted_21={class:`control-row`},_hoisted_22={class:`control-label indented`},_hoisted_23={class:`control-row`},_hoisted_24={class:`control-label indented`},_hoisted_25={class:`control-group`},_hoisted_26={class:`control-row`},_hoisted_27={class:`control-label indented`},_hoisted_28={class:`control-group`},_hoisted_29={class:`control-row`},_hoisted_30={class:`control-label indented`},_hoisted_31={class:`control-group`},_hoisted_32={class:`control-row`},_hoisted_33={class:`control-label`},_hoisted_34={key:2},_hoisted_35={class:`control-row`},_hoisted_36={class:`control-label indented`},_hoisted_37={class:`control-group`},_hoisted_38={class:`control-row`},_hoisted_39={class:`control-label indented`},_hoisted_40={class:`control-group`},_hoisted_41={class:`control-row`},_hoisted_42={class:`control-label indented`},_hoisted_43={class:`control-row`},_hoisted_44={class:`control-label indented`},_hoisted_45={key:3,class:`control-row`},_hoisted_46={class:`control-label indented`},_hoisted_47={class:`control-group`},_hoisted_48={key:4,class:`control-row`},_hoisted_49={class:`control-label indented`},_hoisted_50={class:`control-row`},_hoisted_51={class:`control-label`},_hoisted_52={key:5},_hoisted_53={class:`control-row`},_hoisted_54={class:`control-label indented`},_hoisted_55={class:`control-group`},_hoisted_56={class:`control-row`},_hoisted_57={class:`control-label indented`},_hoisted_58={class:`control-group`},_hoisted_59={class:`control-row`},_hoisted_60={class:`control-label indented`},_hoisted_61={class:`control-row`},_hoisted_62={class:`control-label indented`},_hoisted_63={class:`control-row`},_hoisted_64={class:`control-label indented`},_hoisted_65={class:`control-group`},_hoisted_66={class:`control-row`},_hoisted_67={class:`control-label indented`},_hoisted_68={class:`control-group`},_hoisted_69={class:`control-row`},_hoisted_70={class:`control-label indented`},_hoisted_71={class:`control-group`},_hoisted_72={class:`control-row`},_hoisted_73={class:`control-label`},_hoisted_74={class:`control-row`},_hoisted_75={class:`control-label indented`},_hoisted_76={class:`control-group`},_hoisted_77={class:`control-row`},_hoisted_78={class:`control-label indented`},_hoisted_79={class:`control-group`},_hoisted_80={class:`control-row`},_hoisted_81={class:`control-label indented`},_hoisted_82={class:`control-row`},_hoisted_83={class:`control-label indented`},_hoisted_84={class:`control-row`},_hoisted_85={class:`control-label indented`},_hoisted_86={class:`control-group`},_hoisted_87={class:`control-row`},_hoisted_88={class:`control-label indented`},_hoisted_89={class:`control-group`},_hoisted_90={class:`control-row`},_hoisted_91={class:`control-label`},_hoisted_92={class:`control-row`},_hoisted_93={class:`control-label indented`},_hoisted_94={class:`control-group`},_hoisted_95={class:`control-row`},_hoisted_96={class:`control-label indented`},_hoisted_97={class:`control-group`},_hoisted_98={class:`control-row`},_hoisted_99={class:`control-label`},_hoisted_100={class:`control-row`},_hoisted_101={class:`control-label`},_hoisted_102={key:10,class:`control-row`},_hoisted_103={class:`control-label indented`},_hoisted_104={class:`control-group`},_hoisted_105={class:`control-row`},_hoisted_106={class:`control-label`},_hoisted_107={key:11,class:`control-row`},_hoisted_108={class:`control-label indented`},_hoisted_109={class:`control-group`},_hoisted_110={class:`control-row`},_hoisted_111={class:`control-label`},_hoisted_112={class:`control-row`},_hoisted_113={class:`control-label`},_hoisted_114={key:12,class:`control-row`},_hoisted_115={class:`control-label indented`},_hoisted_116={class:`control-group`},_hoisted_117={key:13,class:`control-row`},_hoisted_118={class:`control-label`},_hoisted_119={class:`mesh-visibility`},_hoisted_120={class:`control-row`},_hoisted_121={class:`control-label`},_hoisted_122={class:`mesh-buttons`},_hoisted_123={class:`buttons`},_sfc_main$14={__name:`Debug`,setup(__props){useUINavBlocker().blockOnly([`context`]);let{lua,api:api$1}=useBridge(),events$3=useEvents(),state=reactive({}),stateNoReset=reactive({vehicle:{parts:[],partNameToIdx:{},partsSelected:{},partsSelectedIdxs:[]}}),partsState=reactive({partsSorted:[],partsHighlightedIdxs:[]}),partsFiltered=computed(()=>{let res=partsState.partsSorted;return Array.isArray(res)?(partsSelectedSearchTerm.value&&(res=res.filter(part=>part.includes(partsSelectedSearchTerm.value))),res.map(p$1=>{let segments=p$1.split(`/`);return{label:segments[segments.length-1],reversePath:segments.slice(0,-1).reverse().join(`\\`),value:p$1,selected:Array.isArray(partsState.partsHighlightedIdxs)&&partsState.partsHighlightedIdxs.includes(partsState.partsSorted.indexOf(p$1)+1)}})):[]}),shipping=computed(()=>window.beamng&&window.beamng.shipping),geState=reactive({physicsEnabled:!0,debugSpawnEnabled:!1}),partsSelectedSearchTerm=ref(``),disableVehicleButtons=ref(!1),controls$1={vehicle:{buttonGroup_1:[{label:`ui.debug.vehicle.loadDefault`,action:()=>lua.core_vehicles.loadDefault()},{label:`ui.debug.vehicle.spawnNew`,action:()=>lua.core_vehicles.spawnDefault()},{label:`ui.debug.vehicle.removeCurrent`,action:()=>lua.core_vehicles.removeCurrent()},{label:`ui.debug.vehicle.cloneCurrent`,action:()=>lua.core_vehicles.cloneCurrent()},{label:`ui.debug.vehicle.removeAll`,action:()=>lua.core_vehicles.removeAll()},{label:`ui.debug.vehicle.removeOthers`,action:()=>lua.core_vehicles.removeAllExceptCurrent()},{label:`ui.debug.vehicle.resetAll`,action:()=>lua.resetGameplay(-1)},{label:`ui.debug.vehicle.reloadAll`,action:()=>lua.core_vehicle_manager.reloadAllVehicles()}],toggleGroup_1:[{label:`ui.debug.activatePhysics`,key:`physicsEnabled`,onChange:()=>lua.simTimeAuthority.togglePause()},{label:`ui.debug.debugSpawnEnabled`,key:`debugSpawnEnabled`,onChange:()=>lua.core_vehicle_manager.toggleDebug()}]},jbeamvis:{buttonGroup_1:[{label:`ui.debug.vehicle.toggleVis`,action:()=>api$1.activeObjectLua(`bdebug.toggleEnabled()`)},{label:`ui.debug.vehicle.clearSettings`,action:()=>api$1.activeObjectLua(`bdebug.resetModes()`)}],meshVisButtonGroup:[{label:`0%`,action:()=>lua.core_vehicles.setMeshVisibility(0)},{label:`25%`,action:()=>lua.core_vehicles.setMeshVisibility(.25)},{label:`50%`,action:()=>lua.core_vehicles.setMeshVisibility(.5)},{label:`75%`,action:()=>lua.core_vehicles.setMeshVisibility(.75)},{label:`100%`,action:()=>lua.core_vehicles.setMeshVisibility(1)}]},terrain:{buttonGroup_1:[{label:`ui.debug.terrain.groundmodel`,action:()=>api$1.engineLua(`extensions.load("util_groundModelDebug") util_groundModelDebug.openWindow()`)}]}};onMounted(async()=>{geState.physicsEnabled=!await lua.simTimeAuthority.getPause(),geState.debugSpawnEnabled=await lua.core_vehicle_manager.getDebug(),api$1.activeObjectLua(`bdebug.requestState()`),lua.core_gamestate.requestGameState(),lua.extensions.core_vehicle_partmgmt.sendPartsSelectorStateToUI()});let applyState=(notSendBack=!1)=>{notSendBack=!!notSendBack,api$1.activeObjectLua(`bdebug.setState(${api$1.serializeToLua(state)}, ${api$1.serializeToLua(stateNoReset)}, ${notSendBack})`)},partsSelectedChanged=(part,value)=>{Array.isArray(partsState.partsHighlightedIdxs)||(partsState.partsHighlightedIdxs=[]);let idx=partsState.partsSorted.indexOf(part)+1,idxInArray=partsState.partsHighlightedIdxs.indexOf(idx);value&&idxInArray===-1?partsState.partsHighlightedIdxs.push(idx):!value&&idxInArray!==-1&&partsState.partsHighlightedIdxs.splice(idxInArray,1),applyState(!0),lua.extensions.core_vehicle_partmgmt.partsSelectorChanged(partsState)},partsSelectedChecked=()=>partsState.partsHighlightedIdxs.length===partsState.partsSorted.length,partsSelectedIndeterminate=()=>partsState.partsHighlightedIdxs.length!==0&&partsState.partsHighlightedIdxs.length!==partsState.partsSorted.length,partsSelectedClicked=()=>{partsState.partsHighlightedIdxs.length===partsState.partsSorted.length?partsState.partsHighlightedIdxs=[]:partsState.partsHighlightedIdxs=Array.from({length:partsState.partsSorted.length},(_,i)=>i+1),applyState(),lua.extensions.core_vehicle_partmgmt.partsSelectorChanged(partsState)},selectAllParts=computed({get:()=>partsSelectedChecked(),set:()=>partsSelectedClicked()}),beamTextModeItems=computed(()=>state.vehicle?.beamTextModes?state.vehicle.beamTextModes.map((mode,index)=>({value:index+1,label:mode.name?$translate.instant(`vehicle.bdebug.beamTextMode.${mode.name}`):``})):[]),beamVisModeItems=computed(()=>state.vehicle?.beamVisModes?state.vehicle.beamVisModes.map((mode,index)=>({value:index+1,label:mode.name?$translate.instant(`vehicle.bdebug.beamVisMode.${mode.name}`):``})):[]),currentBeamVisMode=computed(()=>state.vehicle?.beamVisModes?state.vehicle.beamVisModes[state.vehicle.beamVisMode-1]:null),nodeTextModeItems=computed(()=>state.vehicle?.nodeTextModes?state.vehicle.nodeTextModes.map((mode,index)=>({value:index+1,label:mode.name?$translate.instant(`vehicle.bdebug.nodeTextMode.${mode.name}`):``})):[]),currentNodeTextMode=computed(()=>state.vehicle?.nodeTextModes?state.vehicle.nodeTextModes[state.vehicle.nodeTextMode-1]:null),nodeVisModeItems=computed(()=>state.vehicle?.nodeVisModes?state.vehicle.nodeVisModes.map((mode,index)=>({value:index+1,label:mode.name?$translate.instant(`vehicle.bdebug.nodeVisMode.${mode.name}`):``})):[]),currentNodeVisMode=computed(()=>state.vehicle?.nodeVisModes?state.vehicle.nodeVisModes[state.vehicle.nodeVisMode-1]:null),torsionBarVisModeItems=computed(()=>state.vehicle?.torsionBarVisModes?state.vehicle.torsionBarVisModes.map((mode,index)=>({value:index+1,label:mode.name?$translate.instant(`vehicle.bdebug.torsionBarVisMode.${mode.name}`):``})):[]),currentTorsionBarVisMode=computed(()=>state.vehicle?.torsionBarVisModes?state.vehicle.torsionBarVisModes[state.vehicle.torsionBarVisMode-1]:null),railsSlideNodesModeItems=computed(()=>state.vehicle?.railsSlideNodesVisModes?state.vehicle.railsSlideNodesVisModes.map((mode,index)=>({value:index+1,label:mode.name?$translate.instant(`vehicle.bdebug.railsSlideNodesVisMode.${mode.name}`):``})):[]),cogModeItems=computed(()=>state.vehicle?.cogModes?state.vehicle.cogModes.map((mode,index)=>({value:index+1,label:mode.name?$translate.instant(`vehicle.bdebug.cogMode.${mode.name}`):``})):[]),collisionTriangleModeItems=computed(()=>state.vehicle?.collisionTriangleVisModes?state.vehicle.collisionTriangleVisModes.map((mode,index)=>({value:index+1,label:mode.name?$translate.instant(`vehicle.bdebug.collisionTriangleVisMode.${mode.name}`):``})):[]),aeroModeItems=computed(()=>state.vehicle?.aeroModes?state.vehicle.aeroModes.map((mode,index)=>({value:index+1,label:mode.name?$translate.instant(`vehicle.bdebug.aeroMode.${mode.name}`):``})):[]);return events$3.on(`BdebugUpdate`,(debugState,newStateNoReset)=>{Object.assign(state,debugState),Object.assign(stateNoReset,newStateNoReset)}),events$3.on(`PartsSelectorUpdate`,state$1=>{Object.assign(partsState,state$1)}),events$3.on(`VehicleFocusChanged`,()=>{api$1.activeObjectLua(`bdebug.requestState()`),lua.extensions.core_vehicle_partmgmt.sendPartsSelectorStateToUI()}),events$3.on(`physicsStateChanged`,state$1=>geState.physicsEnabled=!!state$1),events$3.on(`debugSpawnChanged`,state$1=>geState.debugSpawnEnabled=!!state$1),events$3.on(`GameStateUpdate`,gamestate=>disableVehicleButtons.value=gamestate.state.toLowerCase().indexOf(`scenario`)>-1),(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$11,[createBaseVNode(`h3`,null,toDisplayString(_ctx.$tt(`ui.debug.vehicle`)),1),(openBlock(!0),createElementBlock(Fragment,null,renderList(controls$1.vehicle.toggleGroup_1,toggle=>(openBlock(),createElementBlock(`div`,{key:toggle.key},[createVNode(unref(bngSwitch_default),{modelValue:geState[toggle.key],"onUpdate:modelValue":$event=>geState[toggle.key]=$event,onValueChanged:$event=>toggle.onChange()},{default:withCtx(()=>[createTextVNode(toDisplayString(_ctx.$tt(toggle.label)),1)]),_:2},1032,[`modelValue`,`onUpdate:modelValue`,`onValueChanged`])]))),128)),createBaseVNode(`div`,_hoisted_2$7,[(openBlock(!0),createElementBlock(Fragment,null,renderList(controls$1.vehicle.buttonGroup_1,btn=>(openBlock(),createBlock(unref(bngButton_default),{key:btn.label,onClick:$event=>btn.action(),disabled:disableVehicleButtons.value,accent:unref(ACCENTS).secondary},{default:withCtx(()=>[createTextVNode(toDisplayString(_ctx.$tt(btn.label)),1)]),_:2},1032,[`onClick`,`disabled`,`accent`]))),128))]),_cache[74]||=createBaseVNode(`hr`,null,null,-1),createBaseVNode(`h4`,null,toDisplayString(_ctx.$tt(`ui.debug.vehicle.jbeamVis`)),1),createBaseVNode(`div`,_hoisted_3$6,[(openBlock(!0),createElementBlock(Fragment,null,renderList(controls$1.jbeamvis.buttonGroup_1,btn=>(openBlock(),createBlock(unref(bngButton_default),{key:btn.label,onClick:$event=>btn.action(),accent:unref(ACCENTS).secondary},{default:withCtx(()=>[createTextVNode(toDisplayString(_ctx.$tt(btn.label)),1)]),_:2},1032,[`onClick`,`accent`]))),128))]),createBaseVNode(`div`,_hoisted_4$5,[createBaseVNode(`span`,_hoisted_5$4,toDisplayString(_ctx.$tt(`ui.debug.vehicle.partsSelected`)),1),createVNode(unref(bngDropdownContainer_default),{class:`bng-select-fullwidth dropdown-width`},{default:withCtx(()=>[createVNode(unref(bngList_default),{layout:unref(LIST_LAYOUTS).LIST,"target-width":31},{default:withCtx(()=>[createVNode(unref(bngInput_default),{modelValue:partsSelectedSearchTerm.value,"onUpdate:modelValue":_cache[0]||=$event=>partsSelectedSearchTerm.value=$event,modelModifiers:{trim:!0},"floating-label":_ctx.$t(`ui.debug.vehicle.partsSelectedSearchText`)},null,8,[`modelValue`,`floating-label`]),partsFiltered.value&&partsFiltered.value.length>0?(openBlock(),createElementBlock(`div`,_hoisted_6$3,[(openBlock(!0),createElementBlock(Fragment,null,renderList(partsFiltered.value,part=>withDirectives((openBlock(),createBlock(unref(bngSwitch_default),{"model-value":part.selected,key:part.value,"label-alignment":unref(LABEL_ALIGNMENTS).START,inline:!1,class:`parts-switch`,onChange:value=>partsSelectedChanged(part.value,value)},{default:withCtx(()=>[createBaseVNode(`span`,_hoisted_7$3,[createBaseVNode(`strong`,null,toDisplayString(part.label),1),createTextVNode(` `+toDisplayString(part.reversePath?`\\`+part.reversePath:``),1)])]),_:2},1032,[`model-value`,`label-alignment`,`onChange`])),[[unref(BngTooltip_default),part.label+` \\ `+part.reversePath,`right`]])),128))])):createCommentVNode(``,!0)]),_:1},8,[`layout`])]),_:1}),createVNode(unref(bngSwitch_default),{modelValue:selectAllParts.value,"onUpdate:modelValue":_cache[1]||=$event=>selectAllParts.value=$event,class:normalizeClass({"switch-indeterminate":partsSelectedIndeterminate(),"switch-width":!0}),onOnClicked:partsSelectedClicked},null,8,[`modelValue`,`class`])]),state.vehicle?(openBlock(),createElementBlock(Fragment,{key:0},[createBaseVNode(`div`,_hoisted_8$2,[createBaseVNode(`span`,_hoisted_9$1,toDisplayString(_ctx.$tt(`ui.debug.vehicle.beamText`)),1),createVNode(unref(bngDropdown_default),{modelValue:state.vehicle.beamTextMode,"onUpdate:modelValue":_cache[2]||=$event=>state.vehicle.beamTextMode=$event,items:beamTextModeItems.value,onValueChanged:applyState,class:`control-input`},null,8,[`modelValue`,`items`])]),createBaseVNode(`div`,_hoisted_10,[createBaseVNode(`span`,_hoisted_11,toDisplayString(_ctx.$tt(`ui.debug.vehicle.beamVis`)),1),createVNode(unref(bngDropdown_default),{modelValue:state.vehicle.beamVisMode,"onUpdate:modelValue":_cache[3]||=$event=>state.vehicle.beamVisMode=$event,items:beamVisModeItems.value,onValueChanged:applyState,class:`control-input`},null,8,[`modelValue`,`items`])]),currentBeamVisMode.value&¤tBeamVisMode.value.usesRange?(openBlock(),createElementBlock(`div`,_hoisted_12,[createBaseVNode(`div`,_hoisted_13,[createBaseVNode(`span`,_hoisted_14,toDisplayString(_ctx.$tt(`ui.debug.vehicle.visRangeMin`)),1),createBaseVNode(`div`,_hoisted_15,[createVNode(unref(bngSlider_default),{modelValue:currentBeamVisMode.value.rangeMin,"onUpdate:modelValue":_cache[4]||=$event=>currentBeamVisMode.value.rangeMin=$event,min:currentBeamVisMode.value.rangeMinCap,max:currentBeamVisMode.value.rangeMaxCap,step:(currentBeamVisMode.value.rangeMaxCap-currentBeamVisMode.value.rangeMinCap)/100,onValueChanged:applyState},null,8,[`modelValue`,`min`,`max`,`step`]),createVNode(unref(bngInput_default),{modelValue:currentBeamVisMode.value.rangeMin,"onUpdate:modelValue":_cache[5]||=$event=>currentBeamVisMode.value.rangeMin=$event,type:`number`,min:currentBeamVisMode.value.rangeMinCap,max:currentBeamVisMode.value.rangeMaxCap,step:(currentBeamVisMode.value.rangeMaxCap-currentBeamVisMode.value.rangeMinCap)/1e3,onValueChanged:applyState},null,8,[`modelValue`,`min`,`max`,`step`]),createVNode(unref(bngSwitch_default),{modelValue:currentBeamVisMode.value.rangeMinEnabled,"onUpdate:modelValue":_cache[6]||=$event=>currentBeamVisMode.value.rangeMinEnabled=$event,onValueChanged:applyState},null,8,[`modelValue`])])]),createBaseVNode(`div`,_hoisted_16,[createBaseVNode(`span`,_hoisted_17,toDisplayString(_ctx.$tt(`ui.debug.vehicle.visRangeMax`)),1),createBaseVNode(`div`,_hoisted_18,[createVNode(unref(bngSlider_default),{modelValue:currentBeamVisMode.value.rangeMax,"onUpdate:modelValue":_cache[7]||=$event=>currentBeamVisMode.value.rangeMax=$event,min:currentBeamVisMode.value.rangeMinCap,max:currentBeamVisMode.value.rangeMaxCap,step:(currentBeamVisMode.value.rangeMaxCap-currentBeamVisMode.value.rangeMinCap)/100,onValueChanged:applyState},null,8,[`modelValue`,`min`,`max`,`step`]),createVNode(unref(bngInput_default),{modelValue:currentBeamVisMode.value.rangeMax,"onUpdate:modelValue":_cache[8]||=$event=>currentBeamVisMode.value.rangeMax=$event,type:`number`,min:currentBeamVisMode.value.rangeMinCap,max:currentBeamVisMode.value.rangeMaxCap,step:(currentBeamVisMode.value.rangeMaxCap-currentBeamVisMode.value.rangeMinCap)/1e3,onValueChanged:applyState},null,8,[`modelValue`,`min`,`max`,`step`]),createVNode(unref(bngSwitch_default),{modelValue:currentBeamVisMode.value.rangeMaxEnabled,"onUpdate:modelValue":_cache[9]||=$event=>currentBeamVisMode.value.rangeMaxEnabled=$event,onValueChanged:applyState},null,8,[`modelValue`])])]),createBaseVNode(`div`,_hoisted_19,[createBaseVNode(`span`,_hoisted_20,toDisplayString(_ctx.$tt(`ui.debug.vehicle.useInclusiveRange`)),1),createVNode(unref(bngSwitch_default),{modelValue:currentBeamVisMode.value.usesInclusiveRange,"onUpdate:modelValue":_cache[10]||=$event=>currentBeamVisMode.value.usesInclusiveRange=$event,onValueChanged:applyState},null,8,[`modelValue`])]),createBaseVNode(`div`,_hoisted_21,[createBaseVNode(`span`,_hoisted_22,toDisplayString(_ctx.$tt(`ui.debug.vehicle.showInf`)),1),createVNode(unref(bngSwitch_default),{modelValue:currentBeamVisMode.value.showInfinity,"onUpdate:modelValue":_cache[11]||=$event=>currentBeamVisMode.value.showInfinity=$event,onValueChanged:applyState},null,8,[`modelValue`])])])):createCommentVNode(``,!0),state.vehicle.beamVisMode===1?createCommentVNode(``,!0):(openBlock(),createElementBlock(Fragment,{key:1},[createBaseVNode(`div`,_hoisted_23,[createBaseVNode(`span`,_hoisted_24,toDisplayString(_ctx.$tt(`ui.debug.vehicle.showHighlighted`)),1),createBaseVNode(`div`,_hoisted_25,[createVNode(unref(bngSwitch_default),{modelValue:state.vehicle.beamVisShowHighlighted,"onUpdate:modelValue":_cache[12]||=$event=>state.vehicle.beamVisShowHighlighted=$event,disabled:state.vehicle.beamVisMode===3,onValueChanged:applyState},null,8,[`modelValue`,`disabled`])])]),createBaseVNode(`div`,_hoisted_26,[createBaseVNode(`span`,_hoisted_27,toDisplayString(_ctx.$tt(`ui.debug.vehicle.width`)),1),createBaseVNode(`div`,_hoisted_28,[createVNode(unref(bngSlider_default),{modelValue:state.vehicle.beamVisWidthScale,"onUpdate:modelValue":_cache[13]||=$event=>state.vehicle.beamVisWidthScale=$event,min:.1,max:5,step:.1,onValueChanged:applyState},null,8,[`modelValue`]),createVNode(unref(bngInput_default),{modelValue:state.vehicle.beamVisWidthScale,"onUpdate:modelValue":_cache[14]||=$event=>state.vehicle.beamVisWidthScale=$event,type:`number`,min:.1,max:5,step:.1,onValueChanged:applyState},null,8,[`modelValue`])])]),createBaseVNode(`div`,_hoisted_29,[createBaseVNode(`span`,_hoisted_30,toDisplayString(_ctx.$tt(`ui.debug.vehicle.transparency`)),1),createBaseVNode(`div`,_hoisted_31,[createVNode(unref(bngSlider_default),{modelValue:state.vehicle.beamVisAlpha,"onUpdate:modelValue":_cache[15]||=$event=>state.vehicle.beamVisAlpha=$event,min:0,max:1,step:.01,onValueChanged:applyState},null,8,[`modelValue`]),createVNode(unref(bngInput_default),{modelValue:state.vehicle.beamVisAlpha,"onUpdate:modelValue":_cache[16]||=$event=>state.vehicle.beamVisAlpha=$event,type:`number`,min:0,max:1,step:.01,onValueChanged:applyState},null,8,[`modelValue`])])])],64)),createBaseVNode(`div`,_hoisted_32,[createBaseVNode(`span`,_hoisted_33,toDisplayString(_ctx.$tt(`ui.debug.vehicle.nodeText`)),1),createVNode(unref(bngDropdown_default),{modelValue:state.vehicle.nodeTextMode,"onUpdate:modelValue":_cache[17]||=$event=>state.vehicle.nodeTextMode=$event,items:nodeTextModeItems.value,onValueChanged:applyState,class:`control-input`},null,8,[`modelValue`,`items`])]),currentNodeTextMode.value&¤tNodeTextMode.value.usesRange?(openBlock(),createElementBlock(`div`,_hoisted_34,[createBaseVNode(`div`,_hoisted_35,[createBaseVNode(`span`,_hoisted_36,toDisplayString(_ctx.$tt(`ui.debug.vehicle.visRangeMin`)),1),createBaseVNode(`div`,_hoisted_37,[createVNode(unref(bngSlider_default),{modelValue:currentNodeTextMode.value.rangeMin,"onUpdate:modelValue":_cache[18]||=$event=>currentNodeTextMode.value.rangeMin=$event,min:currentNodeTextMode.value.rangeMinCap,max:currentNodeTextMode.value.rangeMaxCap,step:(currentNodeTextMode.value.rangeMaxCap-currentNodeTextMode.value.rangeMinCap)/100,onValueChanged:applyState},null,8,[`modelValue`,`min`,`max`,`step`]),createVNode(unref(bngInput_default),{modelValue:currentNodeTextMode.value.rangeMin,"onUpdate:modelValue":_cache[19]||=$event=>currentNodeTextMode.value.rangeMin=$event,type:`number`,min:currentNodeTextMode.value.rangeMinCap,max:currentNodeTextMode.value.rangeMaxCap,step:(currentNodeTextMode.value.rangeMaxCap-currentNodeTextMode.value.rangeMinCap)/1e3,onValueChanged:applyState},null,8,[`modelValue`,`min`,`max`,`step`]),createVNode(unref(bngSwitch_default),{modelValue:currentNodeTextMode.value.rangeMinEnabled,"onUpdate:modelValue":_cache[20]||=$event=>currentNodeTextMode.value.rangeMinEnabled=$event,onValueChanged:applyState},null,8,[`modelValue`])])]),createBaseVNode(`div`,_hoisted_38,[createBaseVNode(`span`,_hoisted_39,toDisplayString(_ctx.$tt(`ui.debug.vehicle.visRangeMax`)),1),createBaseVNode(`div`,_hoisted_40,[createVNode(unref(bngSlider_default),{modelValue:currentNodeTextMode.value.rangeMax,"onUpdate:modelValue":_cache[21]||=$event=>currentNodeTextMode.value.rangeMax=$event,min:currentNodeTextMode.value.rangeMinCap,max:currentNodeTextMode.value.rangeMaxCap,step:(currentNodeTextMode.value.rangeMaxCap-currentNodeTextMode.value.rangeMinCap)/100,onValueChanged:applyState},null,8,[`modelValue`,`min`,`max`,`step`]),createVNode(unref(bngInput_default),{modelValue:currentNodeTextMode.value.rangeMax,"onUpdate:modelValue":_cache[22]||=$event=>currentNodeTextMode.value.rangeMax=$event,type:`number`,min:currentNodeTextMode.value.rangeMinCap,max:currentNodeTextMode.value.rangeMaxCap,step:(currentNodeTextMode.value.rangeMaxCap-currentNodeTextMode.value.rangeMinCap)/1e3,onValueChanged:applyState},null,8,[`modelValue`,`min`,`max`,`step`]),createVNode(unref(bngSwitch_default),{modelValue:currentNodeTextMode.value.rangeMaxEnabled,"onUpdate:modelValue":_cache[23]||=$event=>currentNodeTextMode.value.rangeMaxEnabled=$event,onValueChanged:applyState},null,8,[`modelValue`])])]),createBaseVNode(`div`,_hoisted_41,[createBaseVNode(`span`,_hoisted_42,toDisplayString(_ctx.$tt(`ui.debug.vehicle.useInclusiveRange`)),1),createVNode(unref(bngSwitch_default),{modelValue:currentNodeTextMode.value.usesInclusiveRange,"onUpdate:modelValue":_cache[24]||=$event=>currentNodeTextMode.value.usesInclusiveRange=$event,onValueChanged:applyState},null,8,[`modelValue`])]),createBaseVNode(`div`,_hoisted_43,[createBaseVNode(`span`,_hoisted_44,toDisplayString(_ctx.$tt(`ui.debug.vehicle.showInf`)),1),createVNode(unref(bngSwitch_default),{modelValue:currentNodeTextMode.value.showInfinity,"onUpdate:modelValue":_cache[25]||=$event=>currentNodeTextMode.value.showInfinity=$event,onValueChanged:applyState},null,8,[`modelValue`])])])):createCommentVNode(``,!0),state.vehicle.nodeTextMode===1?createCommentVNode(``,!0):(openBlock(),createElementBlock(`div`,_hoisted_45,[createBaseVNode(`span`,_hoisted_46,toDisplayString(_ctx.$tt(`ui.debug.vehicle.maxDist`)),1),createBaseVNode(`div`,_hoisted_47,[createVNode(unref(bngSlider_default),{modelValue:state.vehicle.nodeTextMaxDist,"onUpdate:modelValue":_cache[26]||=$event=>state.vehicle.nodeTextMaxDist=$event,min:.1,max:state.vehicle.nodeTextMaxDistCap,step:.1,onValueChanged:applyState},null,8,[`modelValue`,`max`]),createVNode(unref(bngInput_default),{modelValue:state.vehicle.nodeTextMaxDist,"onUpdate:modelValue":_cache[27]||=$event=>state.vehicle.nodeTextMaxDist=$event,type:`number`,min:.1,max:state.vehicle.nodeTextMaxDistCap,step:.1,onValueChanged:applyState},null,8,[`modelValue`,`max`])])])),state.vehicle.nodeTextMode===1?createCommentVNode(``,!0):(openBlock(),createElementBlock(`div`,_hoisted_48,[createBaseVNode(`span`,_hoisted_49,toDisplayString(_ctx.$tt(`ui.debug.vehicle.showWheels`)),1),createVNode(unref(bngSwitch_default),{modelValue:state.vehicle.nodeTextShowWheels,"onUpdate:modelValue":_cache[28]||=$event=>state.vehicle.nodeTextShowWheels=$event,onValueChanged:applyState},null,8,[`modelValue`])])),createBaseVNode(`div`,_hoisted_50,[createBaseVNode(`span`,_hoisted_51,toDisplayString(_ctx.$tt(`ui.debug.vehicle.nodeVis`)),1),createVNode(unref(bngDropdown_default),{modelValue:state.vehicle.nodeVisMode,"onUpdate:modelValue":_cache[29]||=$event=>state.vehicle.nodeVisMode=$event,items:nodeVisModeItems.value,onValueChanged:applyState,class:`control-input`},null,8,[`modelValue`,`items`])]),currentNodeVisMode.value&¤tNodeVisMode.value.usesRange?(openBlock(),createElementBlock(`div`,_hoisted_52,[createBaseVNode(`div`,_hoisted_53,[createBaseVNode(`span`,_hoisted_54,toDisplayString(_ctx.$tt(`ui.debug.vehicle.visRangeMin`)),1),createBaseVNode(`div`,_hoisted_55,[createVNode(unref(bngSlider_default),{modelValue:currentNodeVisMode.value.rangeMin,"onUpdate:modelValue":_cache[30]||=$event=>currentNodeVisMode.value.rangeMin=$event,min:currentNodeVisMode.value.rangeMinCap,max:currentNodeVisMode.value.rangeMaxCap,step:(currentNodeVisMode.value.rangeMaxCap-currentNodeVisMode.value.rangeMinCap)/100,onValueChanged:applyState},null,8,[`modelValue`,`min`,`max`,`step`]),createVNode(unref(bngInput_default),{modelValue:currentNodeVisMode.value.rangeMin,"onUpdate:modelValue":_cache[31]||=$event=>currentNodeVisMode.value.rangeMin=$event,type:`number`,min:currentNodeVisMode.value.rangeMinCap,max:currentNodeVisMode.value.rangeMaxCap,step:(currentNodeVisMode.value.rangeMaxCap-currentNodeVisMode.value.rangeMinCap)/1e3,onValueChanged:applyState},null,8,[`modelValue`,`min`,`max`,`step`]),createVNode(unref(bngSwitch_default),{modelValue:currentNodeVisMode.value.rangeMinEnabled,"onUpdate:modelValue":_cache[32]||=$event=>currentNodeVisMode.value.rangeMinEnabled=$event,onValueChanged:applyState},null,8,[`modelValue`])])]),createBaseVNode(`div`,_hoisted_56,[createBaseVNode(`span`,_hoisted_57,toDisplayString(_ctx.$tt(`ui.debug.vehicle.visRangeMax`)),1),createBaseVNode(`div`,_hoisted_58,[createVNode(unref(bngSlider_default),{modelValue:currentNodeVisMode.value.rangeMax,"onUpdate:modelValue":_cache[33]||=$event=>currentNodeVisMode.value.rangeMax=$event,min:currentNodeVisMode.value.rangeMinCap,max:currentNodeVisMode.value.rangeMaxCap,step:(currentNodeVisMode.value.rangeMaxCap-currentNodeVisMode.value.rangeMinCap)/100,onValueChanged:applyState},null,8,[`modelValue`,`min`,`max`,`step`]),createVNode(unref(bngInput_default),{modelValue:currentNodeVisMode.value.rangeMax,"onUpdate:modelValue":_cache[34]||=$event=>currentNodeVisMode.value.rangeMax=$event,type:`number`,min:currentNodeVisMode.value.rangeMinCap,max:currentNodeVisMode.value.rangeMaxCap,step:(currentNodeVisMode.value.rangeMaxCap-currentNodeVisMode.value.rangeMinCap)/1e3,onValueChanged:applyState},null,8,[`modelValue`,`min`,`max`,`step`]),createVNode(unref(bngSwitch_default),{modelValue:currentNodeVisMode.value.rangeMaxEnabled,"onUpdate:modelValue":_cache[35]||=$event=>currentNodeVisMode.value.rangeMaxEnabled=$event,onValueChanged:applyState},null,8,[`modelValue`])])]),createBaseVNode(`div`,_hoisted_59,[createBaseVNode(`span`,_hoisted_60,toDisplayString(_ctx.$tt(`ui.debug.vehicle.useInclusiveRange`)),1),createVNode(unref(bngSwitch_default),{modelValue:currentNodeVisMode.value.usesInclusiveRange,"onUpdate:modelValue":_cache[36]||=$event=>currentNodeVisMode.value.usesInclusiveRange=$event,onValueChanged:applyState},null,8,[`modelValue`])]),createBaseVNode(`div`,_hoisted_61,[createBaseVNode(`span`,_hoisted_62,toDisplayString(_ctx.$tt(`ui.debug.vehicle.showInf`)),1),createVNode(unref(bngSwitch_default),{modelValue:currentNodeVisMode.value.showInfinity,"onUpdate:modelValue":_cache[37]||=$event=>currentNodeVisMode.value.showInfinity=$event,onValueChanged:applyState},null,8,[`modelValue`])])])):createCommentVNode(``,!0),state.vehicle.nodeVisMode===1?createCommentVNode(``,!0):(openBlock(),createElementBlock(Fragment,{key:6},[createBaseVNode(`div`,_hoisted_63,[createBaseVNode(`span`,_hoisted_64,toDisplayString(_ctx.$tt(`ui.debug.vehicle.showHighlighted`)),1),createBaseVNode(`div`,_hoisted_65,[createVNode(unref(bngSwitch_default),{modelValue:state.vehicle.nodeVisShowHighlighted,"onUpdate:modelValue":_cache[38]||=$event=>state.vehicle.nodeVisShowHighlighted=$event,disabled:state.vehicle.nodeVisMode===3,onValueChanged:applyState},null,8,[`modelValue`,`disabled`])])]),createBaseVNode(`div`,_hoisted_66,[createBaseVNode(`span`,_hoisted_67,toDisplayString(_ctx.$tt(`ui.debug.vehicle.width`)),1),createBaseVNode(`div`,_hoisted_68,[createVNode(unref(bngSlider_default),{modelValue:state.vehicle.nodeVisWidthScale,"onUpdate:modelValue":_cache[39]||=$event=>state.vehicle.nodeVisWidthScale=$event,min:.3,max:5,step:.1,onValueChanged:applyState},null,8,[`modelValue`]),createVNode(unref(bngInput_default),{modelValue:state.vehicle.nodeVisWidthScale,"onUpdate:modelValue":_cache[40]||=$event=>state.vehicle.nodeVisWidthScale=$event,type:`number`,min:.3,max:5,step:.1,onValueChanged:applyState},null,8,[`modelValue`])])]),createBaseVNode(`div`,_hoisted_69,[createBaseVNode(`span`,_hoisted_70,toDisplayString(_ctx.$tt(`ui.debug.vehicle.transparency`)),1),createBaseVNode(`div`,_hoisted_71,[createVNode(unref(bngSlider_default),{modelValue:state.vehicle.nodeVisAlpha,"onUpdate:modelValue":_cache[41]||=$event=>state.vehicle.nodeVisAlpha=$event,min:0,max:1,step:.01,onValueChanged:applyState},null,8,[`modelValue`]),createVNode(unref(bngInput_default),{modelValue:state.vehicle.nodeVisAlpha,"onUpdate:modelValue":_cache[42]||=$event=>state.vehicle.nodeVisAlpha=$event,type:`number`,min:0,max:1,step:.01,onValueChanged:applyState},null,8,[`modelValue`])])])],64)),createBaseVNode(`div`,_hoisted_72,[createBaseVNode(`span`,_hoisted_73,toDisplayString(_ctx.$tt(`ui.debug.vehicle.torsionBarVis`)),1),createVNode(unref(bngDropdown_default),{modelValue:state.vehicle.torsionBarVisMode,"onUpdate:modelValue":_cache[43]||=$event=>state.vehicle.torsionBarVisMode=$event,items:torsionBarVisModeItems.value,onValueChanged:_cache[44]||=value=>{console.log(`change triggered`,value),applyState()},class:`control-input`},null,8,[`modelValue`,`items`])]),currentTorsionBarVisMode.value?.usesRange?(openBlock(),createElementBlock(Fragment,{key:7},[createBaseVNode(`div`,_hoisted_74,[createBaseVNode(`span`,_hoisted_75,toDisplayString(_ctx.$tt(`ui.debug.vehicle.visRangeMin`)),1),createBaseVNode(`div`,_hoisted_76,[createVNode(unref(bngSlider_default),{modelValue:currentTorsionBarVisMode.value.rangeMin,"onUpdate:modelValue":_cache[45]||=$event=>currentTorsionBarVisMode.value.rangeMin=$event,min:currentTorsionBarVisMode.value.rangeMinCap,max:currentTorsionBarVisMode.value.rangeMaxCap,step:(currentTorsionBarVisMode.value.rangeMaxCap-currentTorsionBarVisMode.value.rangeMinCap)/100,onValueChanged:applyState},null,8,[`modelValue`,`min`,`max`,`step`]),createVNode(unref(bngInput_default),{modelValue:currentTorsionBarVisMode.value.rangeMin,"onUpdate:modelValue":_cache[46]||=$event=>currentTorsionBarVisMode.value.rangeMin=$event,type:`number`,min:currentTorsionBarVisMode.value.rangeMinCap,max:currentTorsionBarVisMode.value.rangeMaxCap,step:(currentTorsionBarVisMode.value.rangeMaxCap-currentTorsionBarVisMode.value.rangeMinCap)/1e3,onValueChanged:applyState},null,8,[`modelValue`,`min`,`max`,`step`]),createVNode(unref(bngSwitch_default),{modelValue:currentTorsionBarVisMode.value.rangeMinEnabled,"onUpdate:modelValue":_cache[47]||=$event=>currentTorsionBarVisMode.value.rangeMinEnabled=$event,onValueChanged:applyState},null,8,[`modelValue`])])]),createBaseVNode(`div`,_hoisted_77,[createBaseVNode(`span`,_hoisted_78,toDisplayString(_ctx.$tt(`ui.debug.vehicle.visRangeMax`)),1),createBaseVNode(`div`,_hoisted_79,[createVNode(unref(bngSlider_default),{modelValue:currentTorsionBarVisMode.value.rangeMax,"onUpdate:modelValue":_cache[48]||=$event=>currentTorsionBarVisMode.value.rangeMax=$event,min:currentTorsionBarVisMode.value.rangeMinCap,max:currentTorsionBarVisMode.value.rangeMaxCap,step:(currentTorsionBarVisMode.value.rangeMaxCap-currentTorsionBarVisMode.value.rangeMinCap)/100,onValueChanged:applyState},null,8,[`modelValue`,`min`,`max`,`step`]),createVNode(unref(bngInput_default),{modelValue:currentTorsionBarVisMode.value.rangeMax,"onUpdate:modelValue":_cache[49]||=$event=>currentTorsionBarVisMode.value.rangeMax=$event,type:`number`,min:currentTorsionBarVisMode.value.rangeMinCap,max:currentTorsionBarVisMode.value.rangeMaxCap,step:(currentTorsionBarVisMode.value.rangeMaxCap-currentTorsionBarVisMode.value.rangeMinCap)/1e3,onValueChanged:applyState},null,8,[`modelValue`,`min`,`max`,`step`]),createVNode(unref(bngSwitch_default),{modelValue:currentTorsionBarVisMode.value.rangeMaxEnabled,"onUpdate:modelValue":_cache[50]||=$event=>currentTorsionBarVisMode.value.rangeMaxEnabled=$event,onValueChanged:applyState},null,8,[`modelValue`])])]),createBaseVNode(`div`,_hoisted_80,[createBaseVNode(`span`,_hoisted_81,toDisplayString(_ctx.$tt(`ui.debug.vehicle.useInclusiveRange`)),1),createVNode(unref(bngSwitch_default),{modelValue:currentTorsionBarVisMode.value.usesInclusiveRange,"onUpdate:modelValue":_cache[51]||=$event=>currentTorsionBarVisMode.value.usesInclusiveRange=$event,onValueChanged:applyState},null,8,[`modelValue`])]),createBaseVNode(`div`,_hoisted_82,[createBaseVNode(`span`,_hoisted_83,toDisplayString(_ctx.$tt(`ui.debug.vehicle.showInf`)),1),createVNode(unref(bngSwitch_default),{modelValue:currentTorsionBarVisMode.value.showInfinity,"onUpdate:modelValue":_cache[52]||=$event=>currentTorsionBarVisMode.value.showInfinity=$event,onValueChanged:applyState},null,8,[`modelValue`])])],64)):createCommentVNode(``,!0),state.vehicle.torsionBarVisMode===1?createCommentVNode(``,!0):(openBlock(),createElementBlock(Fragment,{key:8},[createBaseVNode(`div`,_hoisted_84,[createBaseVNode(`span`,_hoisted_85,toDisplayString(_ctx.$tt(`ui.debug.vehicle.width`)),1),createBaseVNode(`div`,_hoisted_86,[createVNode(unref(bngSlider_default),{modelValue:state.vehicle.torsionBarVisWidthScale,"onUpdate:modelValue":_cache[53]||=$event=>state.vehicle.torsionBarVisWidthScale=$event,min:.1,max:5,step:.1,onValueChanged:applyState},null,8,[`modelValue`]),createVNode(unref(bngInput_default),{modelValue:state.vehicle.torsionBarVisWidthScale,"onUpdate:modelValue":_cache[54]||=$event=>state.vehicle.torsionBarVisWidthScale=$event,type:`number`,min:.1,max:5,step:.1,onValueChanged:applyState},null,8,[`modelValue`])])]),createBaseVNode(`div`,_hoisted_87,[createBaseVNode(`span`,_hoisted_88,toDisplayString(_ctx.$tt(`ui.debug.vehicle.transparency`)),1),createBaseVNode(`div`,_hoisted_89,[createVNode(unref(bngSlider_default),{modelValue:state.vehicle.torsionBarVisAlpha,"onUpdate:modelValue":_cache[55]||=$event=>state.vehicle.torsionBarVisAlpha=$event,min:0,max:1,step:.01,onValueChanged:applyState},null,8,[`modelValue`]),createVNode(unref(bngInput_default),{modelValue:state.vehicle.torsionBarVisAlpha,"onUpdate:modelValue":_cache[56]||=$event=>state.vehicle.torsionBarVisAlpha=$event,type:`number`,min:0,max:1,step:.01,onValueChanged:applyState},null,8,[`modelValue`])])])],64)),createBaseVNode(`div`,_hoisted_90,[createBaseVNode(`span`,_hoisted_91,toDisplayString(_ctx.$tt(`ui.debug.vehicle.railsSlideNodesVis`)),1),createVNode(unref(bngDropdown_default),{modelValue:state.vehicle.railsSlideNodesVisMode,"onUpdate:modelValue":_cache[57]||=$event=>state.vehicle.railsSlideNodesVisMode=$event,items:railsSlideNodesModeItems.value,onValueChanged:applyState,class:`control-input`},null,8,[`modelValue`,`items`])]),state.vehicle.railsSlideNodesVisMode===1?createCommentVNode(``,!0):(openBlock(),createElementBlock(Fragment,{key:9},[createBaseVNode(`div`,_hoisted_92,[createBaseVNode(`span`,_hoisted_93,toDisplayString(_ctx.$tt(`ui.debug.vehicle.width`)),1),createBaseVNode(`div`,_hoisted_94,[createVNode(unref(bngSlider_default),{modelValue:state.vehicle.railsSlideNodesVisWidthScale,"onUpdate:modelValue":_cache[58]||=$event=>state.vehicle.railsSlideNodesVisWidthScale=$event,min:.1,max:5,step:.1,onValueChanged:applyState},null,8,[`modelValue`]),createVNode(unref(bngInput_default),{modelValue:state.vehicle.railsSlideNodesVisWidthScale,"onUpdate:modelValue":_cache[59]||=$event=>state.vehicle.railsSlideNodesVisWidthScale=$event,type:`number`,min:.1,max:5,step:.1,onValueChanged:applyState},null,8,[`modelValue`])])]),createBaseVNode(`div`,_hoisted_95,[createBaseVNode(`span`,_hoisted_96,toDisplayString(_ctx.$tt(`ui.debug.vehicle.transparency`)),1),createBaseVNode(`div`,_hoisted_97,[createVNode(unref(bngSlider_default),{modelValue:state.vehicle.railsSlideNodesVisAlpha,"onUpdate:modelValue":_cache[60]||=$event=>state.vehicle.railsSlideNodesVisAlpha=$event,min:0,max:1,step:.01,onValueChanged:applyState},null,8,[`modelValue`]),createVNode(unref(bngInput_default),{modelValue:state.vehicle.railsSlideNodesVisAlpha,"onUpdate:modelValue":_cache[61]||=$event=>state.vehicle.railsSlideNodesVisAlpha=$event,type:`number`,min:0,max:1,step:.01,onValueChanged:applyState},null,8,[`modelValue`])])])],64)),createBaseVNode(`div`,_hoisted_98,[createBaseVNode(`span`,_hoisted_99,toDisplayString(_ctx.$tt(`ui.debug.vehicle.centerOfGravity`)),1),createVNode(unref(bngDropdown_default),{modelValue:state.vehicle.cogMode,"onUpdate:modelValue":_cache[62]||=$event=>state.vehicle.cogMode=$event,items:cogModeItems.value,onValueChanged:applyState,class:`control-input`},null,8,[`modelValue`,`items`])]),createBaseVNode(`div`,_hoisted_100,[createBaseVNode(`span`,_hoisted_101,toDisplayString(_ctx.$tt(`ui.debug.vehicle.collisionTriangle`)),1),createVNode(unref(bngDropdown_default),{modelValue:state.vehicle.collisionTriangleVisMode,"onUpdate:modelValue":_cache[63]||=$event=>state.vehicle.collisionTriangleVisMode=$event,items:collisionTriangleModeItems.value,onValueChanged:applyState,class:`control-input`},null,8,[`modelValue`,`items`])]),state.vehicle.collisionTriangleVisMode===1?createCommentVNode(``,!0):(openBlock(),createElementBlock(`div`,_hoisted_102,[createBaseVNode(`span`,_hoisted_103,toDisplayString(_ctx.$tt(`ui.debug.vehicle.transparency`)),1),createBaseVNode(`div`,_hoisted_104,[createVNode(unref(bngSlider_default),{modelValue:state.vehicle.collisionTriangleVisAlpha,"onUpdate:modelValue":_cache[64]||=$event=>state.vehicle.collisionTriangleVisAlpha=$event,min:0,max:1,step:.01,onValueChanged:applyState},null,8,[`modelValue`]),createVNode(unref(bngInput_default),{modelValue:state.vehicle.collisionTriangleVisAlpha,"onUpdate:modelValue":_cache[65]||=$event=>state.vehicle.collisionTriangleVisAlpha=$event,type:`number`,min:0,max:1,step:.01,onValueChanged:applyState},null,8,[`modelValue`])])])),createBaseVNode(`div`,_hoisted_105,[createBaseVNode(`span`,_hoisted_106,toDisplayString(_ctx.$tt(`ui.debug.vehicle.aerodynamics`)),1),createVNode(unref(bngDropdown_default),{modelValue:state.vehicle.aeroMode,"onUpdate:modelValue":_cache[66]||=$event=>state.vehicle.aeroMode=$event,items:aeroModeItems.value,onValueChanged:applyState,class:`control-input`},null,8,[`modelValue`,`items`])]),state.vehicle.aeroMode===1?createCommentVNode(``,!0):(openBlock(),createElementBlock(`div`,_hoisted_107,[createBaseVNode(`span`,_hoisted_108,toDisplayString(_ctx.$tt(`ui.debug.vehicle.aerodynamicsScale`)),1),createBaseVNode(`div`,_hoisted_109,[createVNode(unref(bngSlider_default),{modelValue:state.vehicle.aerodynamicsScale,"onUpdate:modelValue":_cache[67]||=$event=>state.vehicle.aerodynamicsScale=$event,min:0,max:.2,step:.01,onValueChanged:applyState},null,8,[`modelValue`]),createVNode(unref(bngInput_default),{modelValue:state.vehicle.aerodynamicsScale,"onUpdate:modelValue":_cache[68]||=$event=>state.vehicle.aerodynamicsScale=$event,type:`number`,min:0,max:.2,step:.01,onValueChanged:applyState},null,8,[`modelValue`])])])),createBaseVNode(`div`,_hoisted_110,[createBaseVNode(`span`,_hoisted_111,toDisplayString(_ctx.$tt(`ui.debug.vehicle.tireContactPoint`)),1),createVNode(unref(bngSwitch_default),{modelValue:state.vehicle.tireContactPoint,"onUpdate:modelValue":_cache[69]||=$event=>state.vehicle.tireContactPoint=$event,onValueChanged:applyState},null,8,[`modelValue`])]),createBaseVNode(`div`,_hoisted_112,[createBaseVNode(`span`,_hoisted_113,toDisplayString(_ctx.$tt(`ui.debug.vehicle.steeringGeometry`)),1),createVNode(unref(bngSwitch_default),{modelValue:state.vehicle.steeringGeometry,"onUpdate:modelValue":_cache[70]||=$event=>state.vehicle.steeringGeometry=$event,onValueChanged:applyState},null,8,[`modelValue`])]),state.vehicle.steeringGeometry?(openBlock(),createElementBlock(`div`,_hoisted_114,[createBaseVNode(`span`,_hoisted_115,toDisplayString(_ctx.$tt(`ui.debug.vehicle.steeringGeometryLineLength`)),1),createBaseVNode(`div`,_hoisted_116,[createVNode(unref(bngSlider_default),{modelValue:state.vehicle.steeringGeometryLineLength,"onUpdate:modelValue":_cache[71]||=$event=>state.vehicle.steeringGeometryLineLength=$event,min:0,max:50,step:.1,onValueChanged:applyState},null,8,[`modelValue`]),createVNode(unref(bngInput_default),{modelValue:state.vehicle.steeringGeometryLineLength,"onUpdate:modelValue":_cache[72]||=$event=>state.vehicle.steeringGeometryLineLength=$event,type:`number`,min:0,max:50,step:.1,onValueChanged:applyState},null,8,[`modelValue`])])])):createCommentVNode(``,!0),shipping.value?createCommentVNode(``,!0):(openBlock(),createElementBlock(`div`,_hoisted_117,[createBaseVNode(`span`,_hoisted_118,toDisplayString(_ctx.$tt(`ui.debug.vehicle.wheelThermals`))+` 🐞`,1),createVNode(unref(bngSwitch_default),{modelValue:state.vehicle.wheelThermals,"onUpdate:modelValue":_cache[73]||=$event=>state.vehicle.wheelThermals=$event,onValueChanged:applyState},null,8,[`modelValue`])]))],64)):createCommentVNode(``,!0),createBaseVNode(`div`,_hoisted_119,[createBaseVNode(`div`,_hoisted_120,[createBaseVNode(`span`,_hoisted_121,toDisplayString(_ctx.$tt(`ui.debug.vehicle.meshVisibility`)),1),createBaseVNode(`div`,_hoisted_122,[(openBlock(!0),createElementBlock(Fragment,null,renderList(controls$1.jbeamvis.meshVisButtonGroup,btn=>(openBlock(),createBlock(unref(bngButton_default),{key:btn.label,onClick:$event=>btn.action(),disabled:disableVehicleButtons.value,accent:unref(ACCENTS).outlined,class:`mesh-button`},{default:withCtx(()=>[createTextVNode(toDisplayString(btn.label),1)]),_:2},1032,[`onClick`,`disabled`,`accent`]))),128))])])]),_cache[75]||=createBaseVNode(`hr`,null,null,-1),createBaseVNode(`h4`,null,toDisplayString(_ctx.$tt(`ui.debug.terrain`)),1),createBaseVNode(`div`,_hoisted_123,[(openBlock(!0),createElementBlock(Fragment,null,renderList(controls$1.terrain.buttonGroup_1,btn=>(openBlock(),createBlock(unref(bngButton_default),{key:btn.label,onClick:$event=>btn.action(),accent:unref(ACCENTS).secondary},{default:withCtx(()=>[createTextVNode(toDisplayString(_ctx.$tt(btn.label)),1)]),_:2},1032,[`onClick`,`accent`]))),128))])]))}},Debug_default=__plugin_vue_export_helper_default(_sfc_main$14,[[`__scopeId`,`data-v-8c471ede`]]),_sfc_main$13={__name:`VehicleConfig`,props:{tab:{type:String,default:`parts`,validator:val=>!val||[`parts`,`tuning`,`color`,`save`,`debug`].includes(val)}},setup(__props){let exit=event=>{event.detail.force||window.bngVue.gotoAngularState(`menu.mainmenu`)};function syncWithStates(tab){window.bngVue&&(tab=[`parts`,`tuning`,`color`,`save`,`debug`][tab.index]||`parts`,window.bngVue.gotoAngularState(`menu.vehicleconfig.${tab}`))}return(_ctx,_cache)=>withDirectives((openBlock(),createBlock(unref(layoutSingle_default),{class:`vehcfg`,onDeactivate:exit},{default:withCtx(()=>[withDirectives((openBlock(),createBlock(unref(tabs_default),{class:`bng-tabs`,onChange:syncWithStates},{default:withCtx(()=>[withDirectives(createVNode(unref(tabList_default),null,null,512),[[unref(BngBlur_default)]]),withDirectives(createVNode(Parts_default,{"tab-selected":__props.tab===`parts`,"tab-heading":_ctx.$t(`ui.vehicleconfig.parts`)},null,8,[`tab-selected`,`tab-heading`]),[[unref(BngBlur_default)]]),withDirectives(createVNode(Tuning_default,{"tab-selected":__props.tab===`tuning`,"tab-heading":_ctx.$t(`ui.vehicleconfig.tuning`)},null,8,[`tab-selected`,`tab-heading`]),[[unref(BngBlur_default)]]),withDirectives(createVNode(Paint_default,{"tab-selected":__props.tab===`color`,"tab-heading":_ctx.$t(`ui.vehicleconfig.color`)},null,8,[`tab-selected`,`tab-heading`]),[[unref(BngBlur_default)]]),withDirectives(createVNode(Save_default,{"tab-selected":__props.tab===`save`,"tab-heading":_ctx.$t(`ui.vehicleconfig.save`)+` & `+_ctx.$t(`ui.vehicleconfig.load`)},null,8,[`tab-selected`,`tab-heading`]),[[unref(BngBlur_default)]]),withDirectives(createVNode(Debug_default,{"tab-selected":__props.tab===`debug`,"tab-heading":_ctx.$tt(`ui.debug.vehicle`)},null,8,[`tab-selected`,`tab-heading`]),[[unref(BngBlur_default)]])]),_:1})),[[unref(BngFrustumMover_default),!0,void 0,{left:!0}]])]),_:1})),[[unref(BngScopedNav_default),{activateOnMount:!0,bubbleWhitelistEvents:[`tab_l`,`tab_r`,`menu`]}]])}},VehicleConfig_default=__plugin_vue_export_helper_default(_sfc_main$13,[[`__scopeId`,`data-v-e5f4e51f`]]),_hoisted_1$10={class:`adjustment-container`},_hoisted_2$6={class:`y-controls`},_hoisted_3$5={class:`slider-container`},_hoisted_4$4={class:`value-input`},_hoisted_5$3={class:`x-controls`},_hoisted_6$2={class:`slider-container`},_hoisted_7$2={class:`value-input`},_hoisted_8$1={class:`reset-cont`},MIRROR_RANGE_DEFAULTS={min:-20,max:20,step:.01},_sfc_main$12={__name:`MirrorAdjust`,props:{mirror:Object},setup(__props){let props=__props,uiScopeName=`vehicle-config-mirrors`,uiNavScope$1=useUINavScope(uiScopeName),reactivateUIScope=event=>{(event.type===`deactivate`||event.type===`focusout`)&&uiNavScope$1.set(uiScopeName)},range={x:{min:props.mirror.clampX?props.mirror.clampX[0]:MIRROR_RANGE_DEFAULTS.min,max:props.mirror.clampX?props.mirror.clampX[1]:MIRROR_RANGE_DEFAULTS.max,step:MIRROR_RANGE_DEFAULTS.step},y:{min:props.mirror.clampY?props.mirror.clampY[0]:MIRROR_RANGE_DEFAULTS.min,max:props.mirror.clampY?props.mirror.clampY[1]:MIRROR_RANGE_DEFAULTS.max,step:MIRROR_RANGE_DEFAULTS.step}},[inpX,inpY]=[ref(),ref()],isChanged=computed(()=>inpX.value&&inpX.value.dirty||inpY.value&&inpY.value.dirty),mover={x:0,y:0,drift:.2,tmr:null,tmrInterval:100};function move(evt){let val=evt.detail.value>mover.drift?evt.detail.value-mover.drift:evt.detail.value<-mover.drift?evt.detail.value+mover.drift:0;evt.detail.name===`focus_lr`?mover.x=val:evt.detail.name===`focus_ud`&&(mover.y=val)}let precision=10**(MIRROR_RANGE_DEFAULTS.step+`.`).split(/[.,]/)[1].length,clamp$2=(val,axis=`x`)=>Math.round(Math.max(range[axis].min,Math.min(val,range[axis].max))*precision)/precision;function resetValues(){props.mirror.x=inpX.value.currentCleanValue,props.mirror.y=inpY.value.currentCleanValue,onValueChanged()}function onValueChanged(){Lua_default.extensions.core_vehicle_mirror.setAngleOffset(props.mirror.name,-props.mirror.y,-props.mirror.x,!1,!1)}return onMounted(()=>{getUINavServiceInstance().useCrossfire=!1,Lua_default.extensions.core_vehicle_mirror.focusOnMirror(props.mirror.name),mover.tmr=setInterval(()=>{mover.x===0&&mover.y===0||(props.mirror.x=clamp$2(props.mirror.x+mover.x,`x`),props.mirror.y=clamp$2(props.mirror.y+mover.y,`y`),onValueChanged())},mover.tmrInterval)}),onUnmounted(()=>{getUINavServiceInstance().useCrossfire=!0,clearInterval(mover.tmr)}),(_ctx,_cache)=>withDirectives((openBlock(),createElementBlock(`div`,_hoisted_1$10,[createVNode(unref(bngImageTile_default),{class:`mirror-tile`,icon:unref(icons)[__props.mirror.mirrorIcon],label:__props.mirror.description,ratio:`1:1`},null,8,[`icon`,`label`]),createBaseVNode(`div`,_hoisted_2$6,[createBaseVNode(`div`,_hoisted_3$5,[createVNode(unref(bngSlider_default),mergeProps({"bng-no-nav":`true`,ref_key:`inpY`,ref:inpY,class:`slider-y`},range.y,{uiNavFocus:!1,modelValue:__props.mirror.y,"onUpdate:modelValue":_cache[0]||=$event=>__props.mirror.y=$event,onFocusout:reactivateUIScope,onValueChanged,onDeactivate:reactivateUIScope}),null,16,[`modelValue`])]),createBaseVNode(`div`,_hoisted_4$4,[createVNode(unref(bngBinding_default),{class:`keybinding`,action:`menu_item_focus_ud`,deviceMask:`xinput`,dark:!1}),createVNode(unref(bngInput_default),mergeProps({class:`value`,modelValue:__props.mirror.y,"onUpdate:modelValue":_cache[1]||=$event=>__props.mirror.y=$event,type:`number`},range.y,{prefix:`Y`,suffix:`°`}),null,16,[`modelValue`])])]),createBaseVNode(`div`,_hoisted_5$3,[createBaseVNode(`div`,_hoisted_6$2,[createVNode(unref(bngSlider_default),mergeProps({"bng-no-nav":`true`,ref_key:`inpX`,ref:inpX,class:`slider-x`},range.x,{uiNavFocus:!1,modelValue:__props.mirror.x,"onUpdate:modelValue":_cache[2]||=$event=>__props.mirror.x=$event,onFocusout:reactivateUIScope,onValueChanged,onDeactivate:reactivateUIScope}),null,16,[`modelValue`])]),createBaseVNode(`div`,_hoisted_7$2,[createVNode(unref(bngBinding_default),{class:`keybinding`,action:`menu_item_focus_lr`,deviceMask:`xinput`,dark:!1}),createVNode(unref(bngInput_default),mergeProps({class:`value`,modelValue:__props.mirror.x,"onUpdate:modelValue":_cache[3]||=$event=>__props.mirror.x=$event,type:`number`},range.x,{prefix:`X`,suffix:`°`}),null,16,[`modelValue`])])]),createBaseVNode(`div`,_hoisted_8$1,[createVNode(unref(bngButton_default),{accent:unref(ACCENTS).attention,disabled:!isChanged.value,onClick:_cache[4]||=$event=>resetValues()},{default:withCtx(()=>[createVNode(unref(bngBinding_default),{controller:``,"ui-event":`action_3`}),createTextVNode(` `+toDisplayString(_ctx.$t(`ui.common.reset`)),1)]),_:1},8,[`accent`,`disabled`])])])),[[unref(BngOnUiNav_default),move,`focus_lr,focus_ud`],[unref(BngOnUiNav_default),resetValues,`action_3`]])}},MirrorAdjust_default=__plugin_vue_export_helper_default(_sfc_main$12,[[`__scopeId`,`data-v-14ab0128`]]),_hoisted_1$9={key:0,class:`content buttons-grid`},_sfc_main$11={__name:`Mirrors`,props:{exitRoute:{type:String,default:`menu.vehicleconfig.tuning`}},setup(__props){useUINavScope(`vehicle-config-mirrors`);let comp=ref(null),{lua,events:events$3}=useBridge(),mirrors=ref([]),selectedMirror=ref(null),props=__props;async function exitAdjustmentMode(){selectedMirror.value?(lua.extensions.core_vehicle_mirror.setAngleOffset(selectedMirror.value.name,-selectedMirror.value.y,-selectedMirror.value.x,!1,!0),selectedMirror.value=null,comp.value=null,await lua.extensions.core_vehicle_mirror.focusOnMirror(!1)):bngVue.gotoAngularState(props.exitRoute)}async function getVehicleMirrors(){let data=await lua.extensions.core_vehicle_mirror.getAnglesOffset();for(let key in mirrors.value.splice(0),data){let position=data[key].position,mirrorIcon=data[key].icon,description=data[key].label;if(position||(/_L$|_L_/.test(key)?(position=`left`,mirrorIcon||=`mirrorLeftDefault`):/_R$|_R_/.test(key)?(position=`right`,mirrorIcon||=`mirrorRightDefault`):position=`mid`),!description)description=$translate.instant(`ui.mirrors.position.`+position),key.endsWith(`_spot`)&&(description+=` (${$translate.instant(`ui.mirrors.spot`)})`);else{let tr=$translate.instant(`ui.mirrors.`+description);tr.startsWith(`ui.mirrors.`)||(description=tr)}mirrors.value.push({name:data[key].name,description,position,x:data[key].angleOffset.x,y:data[key].angleOffset.z,clampX:data[key].clampX,clampY:data[key].clampZ,mirrorIcon:mirrorIcon||`mirrorInteriorMiddle`,row:data[key].row||0})}mirrors.value.sort((a$1,b)=>a$1.row-b.row)}return onMounted(async()=>{await getVehicleMirrors(),events$3.on(`VehicleChange`,getVehicleMirrors),lua.extensions.core_input_bindings.setMenuActionEnabled(!0,`menu_item_focus_lr`),lua.extensions.core_input_bindings.setMenuActionEnabled(!0,`menu_item_focus_ud`)}),onUnmounted(()=>{events$3.off(`VehicleChange`,getVehicleMirrors)}),(_ctx,_cache)=>withDirectives((openBlock(),createBlock(unref(layoutSingle_default),{class:`layout-content-full layout-align-hstart`,"bng-ui-scope":`vehicle-config-mirrors`},{default:withCtx(()=>[withDirectives((openBlock(),createBlock(unref(bngCard_default),{class:`mirrors-card`},{buttons:withCtx(()=>[createVNode(unref(bngButton_default),{onClick:exitAdjustmentMode},{default:withCtx(()=>[selectedMirror.value?(openBlock(),createBlock(unref(bngBinding_default),{key:0,controller:``,"ui-event":`action_2`})):(openBlock(),createBlock(unref(bngBinding_default),{key:1,controller:``,"ui-event":`back`})),createTextVNode(` `+toDisplayString(_ctx.$t(selectedMirror.value?`ui.common.apply`:`ui.common.close`)),1)]),_:1})]),default:withCtx(()=>[createVNode(unref(bngCardHeading_default),null,{default:withCtx(()=>[createTextVNode(toDisplayString(_ctx.$t(`ui.mirrors.name`)),1)]),_:1}),selectedMirror.value?(openBlock(),createBlock(MirrorAdjust_default,{key:1,class:`content`,mirror:selectedMirror.value},null,8,[`mirror`])):(openBlock(),createElementBlock(`div`,_hoisted_1$9,[(openBlock(!0),createElementBlock(Fragment,null,renderList(mirrors.value,mirror=>(openBlock(),createBlock(unref(bngImageTile_default),{onClick:$event=>selectedMirror.value=mirror,class:normalizeClass([`mirror-button`,[mirror.position]]),icon:unref(icons)[mirror.mirrorIcon]||unref(icons).placeholder,label:mirror.description,"bng-nav-item":``},null,8,[`onClick`,`class`,`icon`,`label`]))),256))]))]),_:1})),[[unref(BngBlur_default),!0]])]),_:1})),[[unref(BngOnUiNav_default),exitAdjustmentMode,`menu,back`],[unref(BngOnUiNav_default),()=>selectedMirror.value&&exitAdjustmentMode(),`action_2`]])}},Mirrors_default=__plugin_vue_export_helper_default(_sfc_main$11,[[`__scopeId`,`data-v-28f8b633`]]),routes_default$17=[{path:`/vehicle-config`,name:`menu.vehicleconfig`,redirect:`/vehicle-config/parts`,meta:{clickThrough:!0,infoBar:{withAngular:!1,visible:!0,showSysInfo:!1},uiApps:{shown:!0},topBar:{visible:!0}},children:[{path:`parts`,name:`menu.vehicleconfig.parts`,component:VehicleConfig_default,props:{tab:`parts`}},{path:`tuning`,name:`menu.vehicleconfig.tuning`,component:VehicleConfig_default,props:{tab:`tuning`}},{path:`color`,name:`menu.vehicleconfig.color`,component:VehicleConfig_default,props:{tab:`color`},meta:{uiApps:{shown:!1}}},{path:`save`,name:`menu.vehicleconfig.save`,component:VehicleConfig_default,props:{tab:`save`},meta:{uiApps:{shown:!1}}},{path:`debug`,name:`menu.vehicleconfig.debug`,component:VehicleConfig_default,props:{tab:`debug`}}]},{path:`/vehicle-config/tuning/mirrors/:exitRoute?/`,name:`menu.vehicleconfig.tuning.mirrors`,component:Mirrors_default,props:!0},{path:`/vehicle-config/tuning/mirrors-angular`,name:`menu.vehicleconfig.tuning.mirrors.with-angular`,component:Mirrors_default,props:{exitRoute:`menu.vehicleconfigold.tuning`}},{path:`/vehicle-config/tuning/mirrors-garage`,name:`menu.vehicleconfig.tuning.mirrors.in-garage`,component:Mirrors_default,props:{exitRoute:`garagemode.tuning`}}],_hoisted_1$8={key:0,class:`management-details`},_hoisted_2$5={key:0,class:`current-vehicle-info`},_hoisted_3$4={class:`info-row`},_hoisted_4$3={class:`value`},_hoisted_5$2={class:`buttons-section`},_sfc_main$10={__name:`ManagementDetails`,props:{managementDetails:{type:Object,default:null},executeButton:{type:Function,required:!0}},emits:[`button-click`],setup(__props,{emit:__emit}){let props=__props,emit$1=__emit,handleButtonClick=buttonId=>{props.executeButton(buttonId),emit$1(`button-click`,buttonId)};return(_ctx,_cache)=>__props.managementDetails&&__props.managementDetails.buttonInfo&&__props.managementDetails.buttonInfo.length>0?(openBlock(),createElementBlock(`div`,_hoisted_1$8,[__props.managementDetails.details?(openBlock(),createElementBlock(`div`,_hoisted_2$5,[createBaseVNode(`div`,_hoisted_3$4,[_cache[0]||=createBaseVNode(`span`,{class:`label`},`Current Vehicle:`,-1),createBaseVNode(`span`,_hoisted_4$3,toDisplayString(__props.managementDetails.details.currentVehicleName),1)])])):createCommentVNode(``,!0),createBaseVNode(`div`,_hoisted_5$2,[(openBlock(!0),createElementBlock(Fragment,null,renderList(__props.managementDetails.buttonInfo,button=>(openBlock(),createElementBlock(`div`,{key:button.buttonId,class:`button-container`},[createVNode(unref(bngButton_default),{accent:button.accent||`secondary`,label:button.label,icon:button.icon,onClick:$event=>handleButtonClick(button.buttonId)},null,8,[`accent`,`label`,`icon`,`onClick`])]))),128))])])):createCommentVNode(``,!0)}},ManagementDetails_default=__plugin_vue_export_helper_default(_sfc_main$10,[[`__scopeId`,`data-v-b0128491`]]),_sfc_main$9={__name:`VehicleSelector`,setup(__props){return(_ctx,_cache)=>(openBlock(),createBlock(GridSelector_default,{backendName:`vehicleSelector`,routePath:`/vehicle-selector`,defaultPath:{keys:[`allModels`]},defaultDetailsMode:`advanced`,tileImagesTopAligned:``},{"item-details":withCtx(({activeItem,activeItemDetails,executeButton,toggleFavourite,exploreFolder,goToMod})=>[createVNode(VehicleDetails_default,{activeItem,activeItemDetails,executeButton,toggleFavourite,exploreFolder,goToMod,showHeaderTitle:!0},null,8,[`activeItem`,`activeItemDetails`,`executeButton`,`toggleFavourite`,`exploreFolder`,`goToMod`])]),"management-details":withCtx(({managementDetails,executeButton})=>[createVNode(ManagementDetails_default,{managementDetails,executeButton},null,8,[`managementDetails`,`executeButton`])]),_:1}))}},VehicleSelector_default=_sfc_main$9,routes_default$18=[{name:`menu.vehiclesnew`,path:`/vehicle-selector/:pathMatch(.*)*`,component:VehicleSelector_default,props:!0,meta:{clickThrough:!0,infoBar:{visible:!0,showSysInfo:!1},uiApps:{shown:!1},topBar:{visible:!0}}}],router=createRouter({history:createWebHashHistory(),routes:[...Object.values([routes_default,routes_default$1,routes_default$2,routes_default$3,routes_default$4,routes_default$5,routes_default$6,routes_default$7,routes_default$8,routes_default$9,routes_default$10,routes_default$11,routes_default$12,routes_default$13,routes_default$14,routes_default$15,routes_default$16,routes_default$17,routes_default$18]).flatMap(routes=>routes||[]),{path:`/:catchAll(.*)*`,name:`unknown`,component:NotFound_default}]});router.bngUpdateMeta=to=>{to.meta&&(to.meta.uiApps&&handelUIAppsSettings(to.meta.uiApps),handleInfoBarSettings(to.meta.infoBar||{}),handleTopBarSettings(to))},router.afterEach((to,from)=>{reportState(to.path,!0,from.path),window.bridge.api.engineLua(`extensions.hook("onUiChangedState", "${to.name}", "${from.name}")`),router.bngUpdateMeta(to)});var handelUIAppsSettings=settings$1=>{let appsAPI=useUIApps();settings$1.layout&&appsAPI.setLayout(settings$1.layout),`shown`in settings$1&&appsAPI.setVisible(settings$1.shown)},handleInfoBarSettings=settings$1=>{let infoBar=useInfoBar();infoBar.visible=settings$1.visible,infoBar.showSysInfo=settings$1.showSysInfo,infoBar.withAngular=settings$1.withAngular,settings$1.hints&&(infoBar.clearHints(),infoBar.addHints(settings$1.hints))},handleTopBarSettings=to=>{let topBar=useTopBar(),meta=to.meta.topBar||{};meta.visible?meta.visible&&!topBar.visible&&topBar.show():topBar.hide(),topBar.onUIStateChanged(to)},router_default=router,_hoisted_1$7={key:0,id:`vue-debug`},_hoisted_2$4={class:`heading-wrapper`},_hoisted_3$3={class:`label`},_hoisted_4$2={key:0,class:`route-info`},_hoisted_5$1={class:`main`},_hoisted_6$1={class:`controls`},_hoisted_7$1={key:0},_hoisted_8=[`label`],_hoisted_9=[`value`,`selected`],_sfc_main$8={__name:`VueDebug`,setup(__props){let{lua}=useBridge(),EXTRA_ROUTE,routeGroups=router_default.getRoutes().map(r=>r.name).filter(n=>n!==`routelist`).sort((a$1,b)=>a$1.localeCompare(b)).reduce((res,n)=>{if(!n)return res;let g=n.substring(0,1);return res[g]||(res[g]={name:g.toUpperCase(),routes:[]}),res[g].routes.push(n),res},{}),route=useRoute(),hash=ref(location.hash.split(`#`)[1]),path=computed(()=>route.path),routeName=computed(()=>route.name),showDebug=ref(window._VueDebugState),isOpen=ref(window._VueDebugOpen),showComponents=router_default.hasRoute(`components`),bngVue$1=window.bngVue||{};bngVue$1.debug=(state=!0)=>showDebug.value=window._VueDebugState=state,bngVue$1.reset=()=>bngVue$1.gotoGameState(`menu.mainmenu`);function toggleOpen(){isOpen.value=window._VueDebugOpen=!isOpen.value}function selectRoute(e){e.target.value&&bngVue$1.gotoGameState(e.target.value)}function icons$3(){bngVue$1.gotoGameState(`components/IconBrowser`),toggleOpen()}function colours(){bngVue$1.gotoGameState(`components/Colours`),toggleOpen()}function extra(){bngVue$1.gotoGameState(void 0),toggleOpen()}function components(){bngVue$1.showComponents(),toggleOpen()}function menu(){bngVue$1.reset(),toggleOpen()}function mainmenu(){toggleOpen(),lua.returnToMainMenu()}let closeDebug=e=>{e.stopPropagation(),bngVue$1.debug(!1)};return addEventListener(`hashchange`,e=>{hash.value=e.newURL.split(`#`)[1]}),(_ctx,_cache)=>(openBlock(),createBlock(Teleport,{to:`body`},[showDebug.value?(openBlock(),createElementBlock(`div`,_hoisted_1$7,[createBaseVNode(`div`,{class:`handle`,onClick:toggleOpen},[createBaseVNode(`div`,_hoisted_2$4,[createBaseVNode(`span`,_hoisted_3$3,[_cache[1]||=createBaseVNode(`strong`,null,`Vue`,-1),isOpen.value?createCommentVNode(``,!0):(openBlock(),createElementBlock(`span`,_hoisted_4$2,`: `+toDisplayString(path.value)+` [ `+toDisplayString(routeName.value)+` ]`,1))]),createBaseVNode(`a`,{onClick:closeDebug},`x`)])]),withDirectives(createBaseVNode(`div`,_hoisted_5$1,[createBaseVNode(`div`,null,[createTextVNode(` Current hash: `+toDisplayString(hash.value),1),_cache[2]||=createBaseVNode(`br`,null,null,-1),createTextVNode(` Route name: `+toDisplayString(routeName.value),1)]),_cache[4]||=createBaseVNode(`hr`,null,null,-1),createBaseVNode(`div`,_hoisted_6$1,[unref(showComponents)?(openBlock(),createElementBlock(`div`,_hoisted_7$1,[withDirectives((openBlock(),createElementBlock(`a`,{href:`#`,onClick:menu},[..._cache[3]||=[createTextVNode(`Main Menu`,-1)]])),[[unref(BngDoubleClick_default),mainmenu,void 0,{capture:!0}],[unref(BngTooltip_default),`Doubleclick to unload level`]]),unref(void 0)?(openBlock(),createElementBlock(`a`,{key:0,href:`#`,onClick:extra},`⏩`)):createCommentVNode(``,!0),createBaseVNode(`a`,{href:`#`,onClick:_cache[0]||=$event=>_ctx.$simplemenu.value=!_ctx.$simplemenu.value},toDisplayString(_ctx.$simplemenu.value?`✓`:`☐`)+` SimpleMenu`,1),createBaseVNode(`a`,{href:`#`,onClick:components},`Components`),createBaseVNode(`a`,{href:`#`,onClick:icons$3},`Icons`),createBaseVNode(`a`,{href:`#`,onClick:colours},`Colours`)])):createCommentVNode(``,!0),createBaseVNode(`select`,{multiple:``,onClick:selectRoute},[(openBlock(!0),createElementBlock(Fragment,null,renderList(unref(routeGroups),group=>(openBlock(),createElementBlock(`optgroup`,{key:group.name,label:group.name},[(openBlock(!0),createElementBlock(Fragment,null,renderList(group.routes,route$1=>(openBlock(),createElementBlock(`option`,{key:route$1,value:route$1,selected:route$1===routeName.value},toDisplayString(route$1),9,_hoisted_9))),128))],8,_hoisted_8))),128))])])],512),[[vShow,isOpen.value]])])):createCommentVNode(``,!0)]))}},VueDebug_default=__plugin_vue_export_helper_default(_sfc_main$8,[[`__scopeId`,`data-v-669cde99`]]),_hoisted_1$6={class:`hint-content`},_hoisted_2$3={key:0,class:`binding-container`},_hoisted_3$2={key:1,class:`text`},_hoisted_4$1={key:1,class:`hint-text`},_sfc_main$7={__name:`Hint`,props:{data:Object},setup(__props){let Controls=controls_default(),props=__props,PROP_DEFAULTS={icon:{color:`white`},binding:{showUnassigned:!0,dark:!1}},hintRef=ref(null),bindingRefs=ref([]),hintContent=computed(()=>{let hints=props.data?[props.data.content].flat():[],res=[],label;for(let hint of hints)typeof hint==`string`?label=hint:(hint.label&&(label=hint.label),res.push({...hint,label:void 0}));return label&&res.push(label),res}),bindingView=computed(()=>{let res=hintContent.value.filter(item=>typeof item!=`string`);for(let item of res)if(item.type===`binding`){if(item.props?.viewerObj){item.viewerObjs=[item.props.viewerObj];continue}let viewerObjs=Controls.makeViewerObj({...PROP_DEFAULTS[item.type],...item.props,actionVariants:!0,useLastDevice:!0});viewerObjs?.variants?item.viewerObjs=viewerObjs.variants:item.viewerObjs=[viewerObjs]}return res}),labelView=computed(()=>hintContent.value.find(item=>typeof item==`string`)||bindingView.value.find(item=>item.label)?.label),bindingDisplayed=computed(()=>!!(bindingRefs.value.some(ref$1=>ref$1.displayed)||bindingView.value.some(item=>item.type===`icon`)||labelView.value));function onClick(evt){if(lastFocused&&document.body.contains(lastFocused)&&!setFocusExternal(lastFocused,!0,!1))try{lastFocused.focus?.()}catch{}props.data.action?.(evt)}let lastFocused;function trackFocus(evt){let target=evt?.detail?.target||evt?.target||document.activeElement;if(!target){lastFocused=null;return}if(target=target.closest(NAVIGABLE_ELEMENTS_SELECTOR),!target){lastFocused=null;return}if(target===lastFocused)return;let button=hintRef.value?.getElement?.();target!==button&&!button.contains(target)&&(lastFocused=target)}return onMounted(()=>window.addEventListener(`uinav-focus`,trackFocus)),onBeforeUnmount(()=>window.removeEventListener(`uinav-focus`,trackFocus)),(_ctx,_cache)=>withDirectives((openBlock(),createBlock(unref(bngButton_default),{ref_key:`hintRef`,ref:hintRef,class:normalizeClass([`hint`,{"flash-on":__props.data.flash}]),accent:unref(ACCENTS).text,disabled:!__props.data.action,onClick:withModifiers(onClick,[`stop`]),"bng-no-nav":``,tabindex:`-1`},{default:withCtx(()=>[createBaseVNode(`div`,_hoisted_1$6,[bindingView.value.length>0?(openBlock(),createElementBlock(`div`,_hoisted_2$3,[(openBlock(!0),createElementBlock(Fragment,null,renderList(bindingView.value,(item,idx)=>(openBlock(),createElementBlock(`span`,{key:idx,class:`rich`},[item.type===`icon`?(openBlock(),createBlock(unref(bngIcon_default),mergeProps({key:0,class:`icon`},{ref_for:!0},{...PROP_DEFAULTS[item.type],...item.props}),null,16)):createCommentVNode(``,!0),(openBlock(!0),createElementBlock(Fragment,null,renderList(item.viewerObjs,(viewerObj,index)=>(openBlock(),createBlock(unref(bngBinding_default),mergeProps({key:index,ref_for:!0,ref_key:`bindingRefs`,ref:bindingRefs,class:`binding`},{ref_for:!0},{...PROP_DEFAULTS[item.type],...item.props,viewerObj},{"track-ignore":``}),null,16))),128)),item.hold?(openBlock(),createElementBlock(`span`,_hoisted_3$2,toDisplayString(item.hold?`[hold]`:``),1)):createCommentVNode(``,!0)]))),128))])):createCommentVNode(``,!0),labelView.value?(openBlock(),createElementBlock(`span`,_hoisted_4$1,toDisplayString(_ctx.$tt(labelView.value)),1)):createCommentVNode(``,!0)])]),_:1},8,[`class`,`accent`,`disabled`])),[[vShow,bindingDisplayed.value]])}},Hint_default=__plugin_vue_export_helper_default(_sfc_main$7,[[`__scopeId`,`data-v-29a63ba0`]]),_hoisted_1$5={key:0,class:`info-bar-stats`},_hoisted_2$2={key:0},_hoisted_3$1={key:0,class:`divider`},_hoisted_4={key:0},_hoisted_5={class:`sysinfo`},_hoisted_6={class:`sysinfo`},_hoisted_7={key:1,class:`info-bar-buttons`,"bng-no-child-nav":`true`},_sfc_main$6={__name:`InfoBar`,setup(__props){let{visible,showSysInfo,withAngular,hints}=storeToRefs(useInfoBar()),showBuildInfo=ref(!1),toggleBuildInfo=()=>showBuildInfo.value=!showBuildInfo.value,route=useRoute(),solidBar=computed(()=>route.name===`menu.mainmenu`?!sysInfo_default.mainMenuBackgroundRequired.value:withAngular.value);return(_ctx,_cache)=>withDirectives((openBlock(),createElementBlock(`div`,{class:normalizeClass([`info-bar`,{"info-bar-solid":solidBar.value}]),"bng-no-nav":`true`},[unref(showSysInfo)?(openBlock(),createElementBlock(`div`,_hoisted_1$5,[withDirectives(createVNode(unref(bngIcon_default),{style:{"--bng-icon-size":`1.25em`,padding:`0`},type:unref(sysInfo_default).online?unref(icons).globeSimplified:unref(icons).globeSimpleNotSign},null,8,[`type`]),[[unref(BngTooltip_default),unref(sysInfo_default).online?`Online`:`Offline`,`top`]]),(openBlock(!0),createElementBlock(Fragment,null,renderList(unref(sysInfo_default).serviceProviders.value,(info,key)=>(openBlock(),createElementBlock(Fragment,null,[unref(sysInfo_default).serviceProvidersOnline.value[key]?(openBlock(),createElementBlock(`span`,_hoisted_2$2,[createVNode(unref(bngImageAsset_default),{src:`images/mainmenu/${key}icon.png`},null,8,[`src`]),createTextVNode(` `+toDisplayString(info.playerName)+` `,1),info.branch&&info.branch!==`public`?withDirectives((openBlock(),createBlock(unref(bngIcon_default),{key:0,style:{"--bng-icon-size":`1.25em`,padding:`0`},type:unref(icons).branch},null,8,[`type`])),[[unref(BngTooltip_default),`Branch: `+info.branch,`top`]]):createCommentVNode(``,!0),createTextVNode(` `+toDisplayString(info.branch&&info.branch!==`public`?info.branch:``),1)])):createCommentVNode(``,!0)],64))),256)),unref(sysInfo_default).online||unref(sysInfo_default).serviceProvidersOnline.value.any?(openBlock(),createElementBlock(`span`,_hoisted_3$1)):createCommentVNode(``,!0),createBaseVNode(`span`,{onClick:toggleBuildInfo},[showBuildInfo.value?(openBlock(),createElementBlock(Fragment,{key:1},[createBaseVNode(`span`,_hoisted_5,`Alpha v.`+toDisplayString(unref(sysInfo_default).version),1),createBaseVNode(`span`,_hoisted_6,toDisplayString(unref(sysInfo_default).buildInfo),1)],64)):(openBlock(),createElementBlock(`span`,_hoisted_4,`Alpha v.`+toDisplayString(unref(sysInfo_default).versionSimple),1))])])):createCommentVNode(``,!0),_cache[0]||=createBaseVNode(`div`,{class:`spacer`},null,-1),unref(hints).length?(openBlock(),createElementBlock(`div`,_hoisted_7,[(openBlock(!0),createElementBlock(Fragment,null,renderList(unref(hints),item=>(openBlock(),createBlock(Hint_default,{key:item.id,data:item},null,8,[`data`]))),128))])):createCommentVNode(``,!0)],2)),[[vShow,unref(visible)],[unref(BngBlur_default),solidBar.value&&!unref(sysInfo_default).mainMenuBackgroundRequired.value]])}},InfoBar_default=__plugin_vue_export_helper_default(_sfc_main$6,[[`__scopeId`,`data-v-cb5f8971`]]),_hoisted_1$4=[`accent`],_sfc_main$5={__name:`TopBarItem`,props:{icon:{type:String,required:!0},active:{type:Boolean,default:void 0},label:String,iconOnly:Boolean,iconPosition:{type:String,default:`left`},accent:{type:String,default:`default`}},setup(__props){let props=__props,item=ref(null);return watch(()=>props.active,value=>{typeof value==`boolean`&&(value?(item.value.setAttribute(`active`,`true`),item.value.removeAttribute(NO_NAV_ATTR)):(item.value.removeAttribute(`active`),item.value.setAttribute(NO_NAV_ATTR,`true`)))}),(_ctx,_cache)=>withDirectives((openBlock(),createElementBlock(`div`,{ref_key:`item`,ref:item,class:normalizeClass([`topbar-item`,{"icon-only":__props.iconOnly}]),accent:__props.accent,"bng-nav-item":``,"bng-no-nav":`true`,tabindex:`-1`},[createVNode(unref(bngIcon_default),{class:`topbar-item-icon`,type:__props.icon},null,8,[`type`]),__props.label&&!__props.iconOnly?(openBlock(),createBlock(unref(textScroller_default),{key:0,class:`topbar-item-text`},{default:withCtx(()=>[createTextVNode(toDisplayString(_ctx.$t(__props.label)),1)]),_:1})):createCommentVNode(``,!0)],10,_hoisted_1$4)),[[unref(BngSoundClass_default),`bng_click_hover_generic`]])}},TopBarItem_default=__plugin_vue_export_helper_default(_sfc_main$5,[[`__scopeId`,`data-v-2c3015cd`]]),_hoisted_1$3={class:`topbar`},_hoisted_2$1={class:`topbar-section topbar-left`},_hoisted_3={class:`topbar-section topbar-center`},_sfc_main$4={__name:`TopBar`,setup(__props,{expose:__expose}){let topBar=useTopBar(),{visible,items:items$2,activeItem,gameState:gameState$1}=storeToRefs(topBar),overflowContainer=ref(null),pauseButtonTarget=ref(null),showTabBindings=ref(!0),showBackBinding=ref(!0),onItemClicked=item=>{activeItem.value!==item.id&&(activeItem.value=item.id,topBar.selectEntry(item.id))},backStack=new Map,customBack=null;function setBack(id,fn){if(!id)throw Error("Usage: TopBar.setBack(id, [fn]), where `id` is your unique id and `fn` is a custom back function that will fire and expected to return `true` or `false` (undefined return means `true`), which will dis-/allow the base back functionality.");typeof fn==`function`?backStack.set(id,fn):backStack.delete(id),customBack=Array.from(backStack.values()).at(-1)||null}let onBack=()=>{let res=customBack?.();res===void 0&&(res=!0),res&&(gameState$1.isInGame?window.bngVue.gotoGameState(`play`):window.globalAngularRootScope?.$broadcast(`MenuToggle`))},onContinue=()=>{window.bngVue.gotoAngularState(`play`)};return watch(()=>activeItem.value,val=>{if(activeItem.value!==null&&items$2.value.length>0){let idx=items$2.value.findIndex(item=>item.id===val);overflowContainer.value.activate(idx)}else overflowContainer.value.deactivate()}),__expose({pauseButtonTarget:computed(()=>visible.value?pauseButtonTarget.value:null),setBack,showTabBindings,showBackBinding}),onMounted(()=>{}),onUnmounted(()=>{}),(_ctx,_cache)=>withDirectives((openBlock(),createElementBlock(`div`,_hoisted_1$3,[createBaseVNode(`div`,_hoisted_2$1,[unref(gameState$1).isInGame?withDirectives((openBlock(),createBlock(unref(bngButton_default),{key:0,"track-ignore":``,accent:`custom`,class:`topbar-button`,"bng-no-nav":`true`,tabindex:`-1`,onClick:onContinue},{default:withCtx(()=>[createVNode(unref(bngIcon_default),{type:unref(icons).play},null,8,[`type`]),createVNode(unref(bngBinding_default),{"ui-event":`menu`,controller:``})]),_:1})),[[unref(BngTooltip_default),`Back to gameplay`,`right`]]):createCommentVNode(``,!0),withDirectives((openBlock(),createBlock(unref(bngButton_default),{"track-ignore":``,accent:`custom`,class:`topbar-button back-button`,"bng-no-nav":`true`,tabindex:`-1`,onClick:onBack},{default:withCtx(()=>[createVNode(unref(bngIcon_default),{type:unref(icons).undo},null,8,[`type`]),withDirectives(createVNode(unref(bngBinding_default),{"ui-event":`back`,controller:``},null,512),[[vShow,showBackBinding.value]])]),_:1})),[[unref(BngTooltip_default),`Back one level`,`right`]])]),createBaseVNode(`div`,_hoisted_3,[withDirectives(createVNode(unref(bngOverflowContainer_default),{ref_key:`overflowContainer`,ref:overflowContainer,class:`topbar-overflow-container`,"use-bindings-only":``,"show-bindings":showTabBindings.value},{default:withCtx(()=>[(openBlock(!0),createElementBlock(Fragment,null,renderList(unref(items$2),item=>(openBlock(),createBlock(TopBarItem_default,{key:item.id,icon:item.icon,label:item.label,onClick:$event=>onItemClicked(item)},null,8,[`icon`,`label`,`onClick`]))),128))]),_:1},8,[`show-bindings`]),[[vShow,unref(items$2).length>0]])]),createBaseVNode(`div`,{ref_key:`pauseButtonTarget`,ref:pauseButtonTarget,class:`topbar-section topbar-right`},null,512)])),[[vShow,unref(visible)],[unref(BngBlur_default)]])}},TopBar_default=__plugin_vue_export_helper_default(_sfc_main$4,[[`__scopeId`,`data-v-c4d95c66`]]),_sfc_main$3={__name:`Popup`,props:{type:{type:String,default:`default`,validator:val=>[`default`,`activity`].includes(val)}},setup(__props){let props=__props,popups=computed(()=>popupsView[props.type===`default`?`popups`:`activities`]),popupsWrapper=computed(()=>popupsView[props.type===`default`?`popupsWrapper`:`activitiesWrapper`]),wrapper=ref(),innerWrapper=ref(),shown=reactive({wrapper:!1,popups:!1}),tmr;watch(()=>!!popups.value,cur=>{if(cur===shown.wrapper)return;let body=document.body;cur&&popupsWrapper.value.fade?body.classList.add(`popup-all-hide`):body.classList.remove(`popup-all-hide`),tmr&&clearTimeout(tmr),cur?(shown.wrapper=!0,nextTick(()=>{props.type===`default`&&wrapper.value&&typeof wrapper.value.showModal==`function`&&wrapper.value.showModal(),nextTick(()=>shown.popups=!0)}),popupsWrapper.value.fade&&body.classList.add(`popup-show-hide`)):tmr=setTimeout(()=>{tmr=null,!popups.value&&(body.classList.remove(`popup-show-hide`),shown.popups=!1,shown.wrapper=!1,nextTick(()=>priorityFocus()))},200)});function handleUINavEvents(event){console.log(`POPUP handleUINavEvents stopPropagation`,event),event.stopPropagation()}return(_ctx,_cache)=>(openBlock(),createElementBlock(Fragment,null,[shown.wrapper?withDirectives((openBlock(),createBlock(resolveDynamicComponent(__props.type===`default`?`dialog`:`div`),{key:0,ref_key:`wrapper`,ref:wrapper,class:normalizeClass([`popup-wrapper`,`popup-type-${__props.type}`])},{default:withCtx(()=>[createVNode(Transition,{name:`popup-background`},{default:withCtx(()=>[shown.popups?(openBlock(),createElementBlock(`div`,{key:0,class:normalizeClass([`popup-background`,...popupsWrapper.value.style.map(name=>`background-style-`+name)])},null,2)):createCommentVNode(``,!0)]),_:1}),createVNode(TransitionGroup,{name:`popup-fade`},{default:withCtx(()=>[shown.popups?(openBlock(!0),createElementBlock(Fragment,{key:0},renderList(popups.value,popup=>(openBlock(),createElementBlock(`div`,{key:popup.id,class:normalizeClass([`popup-container`,...popup.position.map(name=>`content-position-`+name),popup.animated?`popup-animated`:`popup-notanimated`,popup.active?`popup-active`:`popup-inactive`])},[(openBlock(),createBlock(resolveDynamicComponent(popup.component.ref),mergeProps({ref_for:!0},popup.props,{popupActive:popup.active,class:[`popup-content`,popup.active?`popup-active`:`popup-inactive`],onReturn:popup.return}),null,16,[`popupActive`,`class`,`onReturn`]))],2))),128)):createCommentVNode(``,!0)]),_:1}),createBaseVNode(`div`,{ref_key:`innerWrapper`,ref:innerWrapper},null,512)]),_:1},8,[`class`])),[[unref(BngBlur_default),popupsWrapper.value.blur],[unref(BngOnUiNav_default),handleUINavEvents,`back,menu`]]):createCommentVNode(``,!0),(openBlock(),createBlock(Teleport,{to:innerWrapper.value,disabled:!innerWrapper.value},[renderSlot(_ctx.$slots,`default`,{},void 0,!0)],8,[`to`,`disabled`]))],64))}},Popup_default=__plugin_vue_export_helper_default(_sfc_main$3,[[`__scopeId`,`data-v-c0bb08d7`]]),_hoisted_1$2={class:`popover-container`},_sfc_main$2={__name:`Popover`,setup(__props){return usePopover(),(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$2))}},Popover_default=__plugin_vue_export_helper_default(_sfc_main$2,[[`__scopeId`,`data-v-86205238`]]),_hoisted_1$1={class:`backgrounds-cache`},_hoisted_2=[`src`],DRIVE=8,TECH=1,_sfc_main$1={__name:`MainBackground`,setup(__props,{expose:__expose}){let bgPathResolve=(product,name,blur$1=!1)=>`images/mainmenu/${product?product+`/`:``}${name}${blur$1?`_blur`:``}.jpg`,_backgrounds={drive:Array.from({length:DRIVE},(_,i)=>bgPathResolve(`drive`,i+1)),drive_blur:Array.from({length:DRIVE},(_,i)=>bgPathResolve(`drive`,i+1,!0)),tech:Array.from({length:TECH},(_,i)=>bgPathResolve(`tech`,i+1)),tech_blur:Array.from({length:TECH},(_,i)=>bgPathResolve(`tech`,i+1,!0)),unofficial:[bgPathResolve(null,`unofficial_version`)],unofficial_blur:[bgPathResolve(null,`unofficial_version`,!0)]},backgroundId=ref(`drive`),backgrounds=computed(()=>({normal:_backgrounds[backgroundId.value],blur:_backgrounds[backgroundId.value+`_blur`]})),carousel=ref();return __expose({carousel:computed(()=>carousel.value),backgrounds:computed(()=>backgrounds.value)}),onMounted(async()=>{let isTech=await Lua_default.extensions.tech_license.isValid();backgroundId.value=isTech?`tech`:`drive`,bngApi.engineLua(`sailingTheHighSeas`,ahoy=>{backgroundId.value=ahoy?`unofficial`:isTech?`tech`:`drive`})}),(_ctx,_cache)=>(openBlock(),createElementBlock(Fragment,null,[createVNode(Slideshow_default,{class:`background-image`,ref_key:`carousel`,ref:carousel,images:backgrounds.value.normal,delay:1e4,transition:``,shuffle:``},null,8,[`images`]),(openBlock(!0),createElementBlock(Fragment,null,renderList(backgrounds.value,list=>(openBlock(),createElementBlock(`div`,_hoisted_1$1,[(openBlock(!0),createElementBlock(Fragment,null,renderList(list,src=>(openBlock(),createElementBlock(`img`,{src:unref(getAssetURL)(src)},null,8,_hoisted_2))),256))]))),256))],64))}},MainBackground_default=__plugin_vue_export_helper_default(_sfc_main$1,[[`__scopeId`,`data-v-6c1f834b`]]),_hoisted_1={id:`vue-app-container`},_sfc_main={__name:`App`,setup(__props){let route=useRoute(),settings$1=useSettings(),bngVue$1=window.bngVue||{},apps=ref([]),appContCnt=ref(0),appTargets=computed(()=>apps.value.reduce((res,{teleport})=>({...res,[teleport]:document.getElementById(teleport.substring(1)),cnt:appContCnt.value}),{}));bngVue$1.updateAppContainer=()=>window.requestAnimationFrame(()=>appContCnt.value=++appContCnt.value%1e5);let contClickThrough=ref(!1);bngVue$1.gotoAngularState=(state=`blank`,params=void 0)=>window.angular&&window.angular.element(document.querySelector(`body`)).controller().changeAngularStateFromVue(state,params),bngVue$1.gotoGameState=(state=`ui-test`,{params=!1,tryAngularJS=!0,blankAngularJS=!0,clickThrough=!1,uiAppsShown=!1}={})=>{let a$1=history.state;if(!router_default.hasRoute(state))window.location.hash=`#/`+state,route&&(handleUiAppsMeta(route,uiAppsShown),router_default.bngUpdateMeta(route)),tryAngularJS&&bngVue$1.gotoAngularState(state,params);else{blankAngularJS&&bngVue$1.gotoAngularState(`blank`);let newroute=router_default.resolve({name:state,params});handleUiAppsMeta(newroute,uiAppsShown),newroute.name===route.name&&router_default.bngUpdateMeta(route),window.location.hash=newroute.href,router_default.replace({name:state,params})}history.replaceState(a$1,``,window.location.toString()),contClickThrough.value=clickThrough};function handleUiAppsMeta(route$1,uiAppsShown){route$1.meta?route$1.meta.uiApps||(route$1.meta.uiApps={}):route$1.meta={uiApps:{}},typeof route$1.meta.uiApps.shown!=`boolean`&&(route$1.meta.uiApps.shown=uiAppsShown)}bngVue$1.getCurrentRoute=()=>router_default.currentRoute.value,bngVue$1.spawnApp=(appName,appId,params=null)=>spawnUiApp(appName,appId,params,apps.value),bngVue$1.destroyApp=appName=>destroyUiApp(appName,apps.value),useFocusManager();let topBar=ref();provide(`setBack`,(id,fn)=>topBar.value?.setBack(id,fn)),provide(`showTopbarTabBindings`,val=>topBar.value&&(topBar.value.showTabBindings=val)),provide(`showTopbarBackBinding`,val=>topBar.value&&(topBar.value.showBackBinding=val));let bgRequired=sysInfo_default.mainMenuBackgroundRequired,mainBackground=ref();return provide(`mainBackground`,computed(()=>mainBackground.value?.carousel)),provide(`mainBackgroundBlur`,computed(()=>mainBackground.value?.backgrounds.blur)),watch([()=>settings$1.values.uiLayoutContentAlignment,()=>settings$1.values.uiLayoutContentWidth],([alignment,width$1])=>{let rootStyle=document.documentElement.style;alignment=LAYOUT_ALIGNMENTS[alignment||`center`],width$1=width$1?`${width$1}px`:`100vw`,window.requestAnimationFrame(()=>{rootStyle.setProperty(`--layout-content-alignment`,alignment),rootStyle.setProperty(`--layout-content-width`,width$1)})},{immediate:!0}),(_ctx,_cache)=>{let _component_router_view=resolveComponent(`router-view`);return openBlock(),createElementBlock(Fragment,null,[unref(bgRequired)?(openBlock(),createBlock(MainBackground_default,{key:0,ref_key:`mainBackground`,ref:mainBackground},null,512)):createCommentVNode(``,!0),unref(route).name===`unknown`?createCommentVNode(``,!0):(openBlock(),createElementBlock(`div`,{key:1,class:normalizeClass({"vue-app-main":!0,"click-through":contClickThrough.value||unref(route).meta&&unref(route).meta.clickThrough})},[createVNode(TopBar_default,{ref_key:`topBar`,ref:topBar},null,512),createVNode(_component_router_view),createVNode(InfoBar_default)],2)),createVNode(pauseButton_default,{"teleport-to":topBar.value?.pauseButtonTarget},null,8,[`teleport-to`]),unref(route).name===`unknown`?(openBlock(),createBlock(Popup_default,{key:2,type:`activity`})):createCommentVNode(``,!0),createVNode(Popup_default,null,{default:withCtx(()=>[createVNode(Popover_default)]),_:1}),createVNode(LoadingScreen_default),createVNode(VueDebug_default),createBaseVNode(`div`,_hoisted_1,[(openBlock(!0),createElementBlock(Fragment,null,renderList(apps.value,(app$1,index)=>(openBlock(),createElementBlock(Fragment,{key:app$1.appKey},[appTargets.value[app$1.teleport]?(openBlock(),createBlock(Teleport,{key:0,to:app$1.teleport},[(openBlock(),createBlock(resolveDynamicComponent(app$1.comp),mergeProps({ref_for:!0},app$1.props),null,16))],8,[`to`])):createCommentVNode(``,!0)],64))),128))])],64)}}},App_default=__plugin_vue_export_helper_default(_sfc_main,[[`__scopeId`,`data-v-eef28b65`]]);function customDisposePlugin(context){let store$1=context.store,{$dispose,dispose:dispose$2}=store$1;store$1.$dispose=()=>{$dispose(),dispose$2&&typeof dispose$2==`function`&&dispose$2()}}window.watchdogInit=init,window.Vue=vue_esm_bundler_exports;var deps={Emitter:eventemitter3_default,beamng:window.beamng};window.bngApi&&(deps.overrideAPI=window.bngApi),setBridgeDependencies(deps);var bridge=useBridge();window.bridge=bridge,sysInfo_default.init(),initFocusVisible(),bridge.uiNavService=new UINavService(bridge.events),setUINavServiceInstance(bridge.uiNavService),bridge.uiNavService.initialize();var pinia=createPinia().use(()=>({$game:bridge})).use(customDisposePlugin),app=createApp(App_default).use(router_default).use(pinia).use(registerApps,apps_exports);useGameContextStore(),window.bngVue={start:()=>{window.vueGlobalStore||(window.vueGlobalStore=reactive({}));let globals={$game:bridge,$console:logger_default,$logger:logger_default,$simplemenu:ref(!!window.beamng?.simplemenu),$globalStore:window.vueGlobalStore},{i18n,plugin:translationPlugin$1}=initTranslation();app.use(i18n).use(translationPlugin$1());for(let[key,value]of Object.entries(globals))app.config.globalProperties[key]=value,app.provide(key,value);app.mount(`#vue-app`);let controlsStore=controls_default();window.bngVue.controls={getControllers:()=>controlsStore.controllers,getPlayers:()=>controlsStore.players,getCategories:()=>controlsStore.categories,getCategoriesList:()=>controlsStore.categoriesList,findBindingForAction:controlsStore.findBindingForAction,getActionDetails:controlsStore.getActionDetails,getBindingDetails:controlsStore.getBindingDetails,getAllBindingsForAction:controlsStore.getAllBindingsForAction,addNewBinding:controlsStore.addNewBinding,updateBinding:controlsStore.updateBinding,deleteBinding:controlsStore.deleteBinding,deleteBindings:controlsStore.deleteBindings,deviceIcon:controlsStore.deviceIcon,isFFBBound:controlsStore.isFFBBound,isFFBEnabled:controlsStore.isFFBEnabled,isFFBCapable:controlsStore.isFFBCapable,isGamepadAvailable:controlsStore.isGamepadAvailable,captureBinding:controlsStore.captureBinding,makeViewerObj:controlsStore.makeViewerObj,isControllerAvailable:controlsStore.isControllerAvailable,isControllerUsed:controlsStore.isControllerUsed,showIfController:controlsStore.showIfController,focusIfController:controlsStore.focusIfController,refreshData:()=>bridge.lua.extensions.core_input_bindings.notifyUI(`Vue exposed controls service needs the data`)},window.bngVue.uiNavTracker=useUINavTracker(),window.bngVue.topBar=useTopBar()},startTest:()=>{app.mount(`#vue-app`)},isProd:!0,icons},window.beamng||window.bngVue.start({i18n:window.i18n});
        if core_camera then core_camera.requestConfig() end    -- cameraConfig
      `);async function init$3(){for(let key in active=!0,(window.beamng&&!window.beamng.shipping||editor)&&(watchers$1.push(watch(()=>settingsValues.value,updateSettingsList)),watchers$1.push(watch(()=>layout.value,async()=>{await settings$1.waitForData(),updateSettingsList()}))),events$3.on(`SettingsChanged`,()=>settingsTimestamp.value=Date.now()),watchers$1.push(watch(customValues,()=>settingsTimestamp.value=Date.now(),{deep:!0})),events$3.on(`externalUIURL`,data=>customValues.externalUIURL=data||``),events$3.on(`OpenXRStateChanged`,data=>customValues.openXRstate=data),events$3.on(`CameraConfigChanged`,data=>{customValues.cameraConfigList=Array.isArray(data.cameraConfig)?data.cameraConfig:[],customValues.cameraConfigFocused=data.focusedCamName}),updateCustom(),await settings$1.waitForData(),settings$1.values)initialValues[key]=settings$1.values[key];settingsTimestamp.value=Date.now(),setupSearch(layout,settingsValues,settingsOptions,settingsTimestamp,conditions)}let settingsValues=computed(()=>{if(!active||!settings$1.values)return{};let res={...settings$1.values};for(let key in valueFormatters)res[key]=valueFormatters[key](res[key],settings$1.values,customValues);for(let key in valueExtensions)res[key]=valueExtensions[key](settings$1.values,customValues);return res}),settingsOptions=computed(()=>{let res={};if(!active||!settings$1.options||!settings$1.values)return res;for(let key in settings$1.options)key in optionFormatters?res[key]=optionFormatters[key](settings$1.options[key],settings$1.options,settings$1.values):res[key]=guessOptionFormat(settings$1.options[key]);for(let key in optionExtensions)res[key]=optionExtensions[key](settings$1.options,settings$1.values);return res}),editor=null,layout=ref(layout_default);function updateSettingsList(){if(!active)return;settingsList.value=Object.keys(settingsValues.value).reduce((res,name)=>({...res,[name]:{assigned:!1,assignedIn:[],value:settingsValues.value[name],options:settingsOptions.value[name],elementId:name.split(`.`)}}),{});function dive(items$2,cat,catIndex,level$1=0,parentId=``){for(let i=0;i{let values=name in applyValueFormatters?applyValueFormatters[name](value):{[name]:value};for(let key in name.startsWith(`debug_`)&&(customValues.debug[name.substring(6)]=value,name===`debug_visualization`&&(customValues.debug.visualization_prev&&api$1.engineLua(customValues.debug.visualization_prev),customValues.debug.visualization_prev=value,api$1.engineLua(value))),values)key in settings$1.values||delete values[key];Object.keys(values).length>0&&(logger_default.debug(`Applying:`,JSON.stringify(values)),settings$1.apply(values),updateCustom())};function dispose$2(){active=!1,settingsList.value={};for(let unwatch of watchers$1)unwatch();watchers$1.splice(0),settingsTimestamp.value=0,disposeSearch(),null?.dispose()}return provide(`settingsValues`,settingsValues),provide(`settingsOptions`,settingsOptions),provide(`settingsTimestamp`,settingsTimestamp),provide(`settingsList`,settingsList),provide(`conditions`,conditions),provide(`buildItemId`,buildItemId),{init:init$3,dispose:dispose$2,versions:VERSIONS,version:VERSIONS[0],settings:settings$1,settingsList,settingsValues,settingsOptions,settingsTimestamp,applySetting,buildItemId,layout,conditions,editable:!1,editor:null,searchText,searchResults,searchTemplates:{message:(...args)=>searchTemplates.message(layout,...args),headers:(...args)=>searchTemplates.headers(layout,...args),group:(...args)=>searchTemplates.group(layout,...args)}}}var _hoisted_1$19={class:`options-wrapper`,"bng-ui-scope":`options`},_hoisted_2$13={class:`options-heading`},_hoisted_3$12={key:0,class:`options-container`},_hoisted_4$9={class:`background`},_hoisted_5$8={class:`options-content-wrapper`},_hoisted_6$5={class:`options-message`},_hoisted_7$5={class:`message-content`},_hoisted_8$3={key:1,class:`options-categories`},_hoisted_9$2={key:0,class:`categories-divider`},_hoisted_10$1={key:2,class:`options-container`},_hoisted_11$1={class:`options-subcategories`},_hoisted_12$1={class:`background`},_hoisted_13$1={key:0,class:`categories-divider`},_hoisted_14$1={key:1,class:`categories-spacer`},_hoisted_15$1={key:0,class:`categories-spacer`},_hoisted_16$1={key:1,class:`categories-divider`},_hoisted_17$1={class:`options-content-wrapper`},_hoisted_18$1={key:0,class:`options-add-item`},_hoisted_19$1={key:1,class:`options-content`,"bng-ui-scope":`options-content`},_hoisted_20$1={key:2,class:`options-content`,"bng-ui-scope":`options-content`},_hoisted_21$1={class:`background`},_hoisted_22$1=[`innerHTML`],_hoisted_23$1={key:0,class:`options-info-fps`},_sfc_main$23={__name:`OptionsView`,props:{category:String},setup(__props){useUINavScope(`options`);let router$1=useRouter(),route=useRoute(),{api:api$1}=useBridge(),options=useOptions(),loaded=ref(!1),itemsContainer=ref(null),activeScope=ref(``),props=__props;provide(`version`,options.version);let EditUI=ref(null),itemEdit=(...args)=>EditUI.value?.functions.itemEdit?.(...args),categoryEdit=(...args)=>EditUI.value?.functions.categoryEdit?.(...args),catItemsPaste=(...args)=>EditUI.value?.functions.catItemsPaste?.(...args);provide(`EditUI`,EditUI);let editable=ref(!1);provide(`editable`,editable);let categories=computed(()=>options.layout.value.items||[]),categoryIds=computed(()=>categories.value.map(cat=>cat.categoryId)),categoryIndex=ref(-1);provide(`categoryIndex`,categoryIndex);let allCategories=computed(()=>{let cats=[...categories.value].map(cat=>({...cat})),startIndex=0;for(let i=0;istartIndex&&(cats[ri].subcategoryMode=hadSpacer?`none`:ri===i?`last`:ri===startIndex+1?`first`:`middle`)}}else startIndex=i,cat.indexRange=[i,i]}let hidden=[];for(let cat of cats)if(!(!cat.condition_visible||cat.condition_visible in options.conditions&&options.conditions[cat.condition_visible](options.settingsValues.value)))if(cat.subcategory)hidden.push(cat.categoryIndex);else for(let i=cat.indexRange[0];i<=cat.indexRange[1];i++)hidden.push(i);return options.editable?cats.map(cat=>(cat.hiddenByCondition=hidden.includes(cat.categoryIndex),cat.debugSettings=cat.condition_visible===`__notForShipping`,cat)):hidden.length>0?cats.filter(cat=>!hidden.includes(cat.categoryIndex)):cats}),categoriesView=computed(()=>allCategories.value.filter(cat=>!cat.subcategory&&!cat.persistent&&!cat.spacer)),categoryRange=computed(()=>categoriesView.value.find(cat=>categoryIndex.value>=cat.indexRange[0]&&categoryIndex.value<=cat.indexRange[1])?.indexRange||[categoryIndex.value,categoryIndex.value]),subcategoriesView=computed(()=>{let res=categoryIndex.value===-1?[]:allCategories.value.filter(cat=>!cat.persistent&&cat.categoryIndex>=categoryRange.value[0]&&cat.categoryIndex<=categoryRange.value[1]);return res.length>0&&(res[0]={...res[0],label:`ui.options.general`}),res}),persistentView=computed(()=>allCategories.value.filter(cat=>cat.persistent)),itemsNew=ref([]),itemsNewShow=ref(!1),itemsNewView=computed(()=>itemsNewShow.value?itemsNew.value:[]);options.editor&&watch(options.layout,()=>itemsNew.value.splice(0));function renderNewOptions(doRender=!0){if(itemsNewShow.value=doRender,!doRender||itemsNew.value.length>0)return;function dive(parent){if(parent.version!==options.version)for(let i=parent.items.length-1;i>=0;i--){let item=parent.items[i];item.items&&(item.items.length>0&&dive(item),item.items.length>0)||item.version!==options.version&&parent.items.splice(i,1)}}let layout=JSON.parse(JSON.stringify(options.layout.value.items));for(let i=layout.length-1;i>=0;i--){let cat=layout[i];dive(cat),cat.items.length>0&&itemsNew.value.push(options.searchTemplates.group(cat.label,cat.icon,cat.items))}}provide(`renderNewOptions`,renderNewOptions);let itemsView=computed(()=>[...categoryIndex.value>-1&&categoryIndex.value{renderNewOptions(!1),categoryIndex.value>-1&&(special.value=null,searchActive.value=!1,options.searchText.value=``),itemsContainer.value&&itemsContainer.value.scrollTo({top:0,behavior:`instant`})}),watch(special,()=>{special.value&&(categoryIndex.value=-1,searchActive.value=!1,options.searchText.value=``)});let searchActive=ref(!1),searchFocused=ref(!1);watch(searchFocused,focused$1=>{focused$1?(searchActive.value=!0,categoryIndex.value=-1,special.value=null):options.searchText.value.length===0&&(searchActive.value=!1,categoryIndex.value=0)});let elCategories=ref(null),elSearch=ref(null),elSearchBinding=ref(null);watch(()=>elSearch.value?.scopeActivated,active=>{activeScope.value=active?``:`content`});function toSearchAndBack(){elSearch.value&&(elSearch.value.scopeActivated=!elSearch.value.scopeActivated)}function fromContent(){searchActive.value?elSearch.value.scopeActivated=!0:activeScope.value=`subcategories`}function mainCatNav(evt){!elCategories.value||!evt.detail||(options.searchText.value=``,elSearch.value.scopeActivated=!1,searchActive.value=!1,activeScope.value=`subcategories`,evt.detail.name===`tab_l`?elCategories.value.activatePrev():evt.detail.name===`tab_r`&&elCategories.value.activateNext(),evt.stopPropagation())}function catNavigate(cat){cat.reroute?window.bngVue.gotoAngularState(cat.reroute):categoryIndex.value!==cat.categoryIndex&&(categoryIndex.value=cat.categoryIndex)}provide(`goToSetting`,(catIndex,itemId)=>{categoryIndex.value=catIndex,nextTick(()=>{let elm=document.getElementById(itemId);elm?(elm.scrollIntoView({behavior:`smooth`,block:`center`}),elm.classList.add(`options-setting-highlight`),setTimeout(()=>elm?.classList.remove(`options-setting-highlight`),5e3)):logger_default.warn(`Setting item not found: ${itemId}`)})});function onChange(data,value){options.applySetting(data.setting,value);let lua;switch(data.itemType){case`checkbox`:value===!0||value===`enable`?lua=data.lua:(value===!1||value===`disable`)&&(lua=data.luaOff);break;default:lua=data.lua}lua&&runLua(lua,value)}function onClick(data){data.lua&&runLua(data.lua)}function runLua(code,value=void 0){code.toLowerCase().includes(`%value%`)&&value!==void 0&&(code=code.replace(/%value%/gi,api$1.serializeToLua(value))),code.toLowerCase().includes(`%values%`)&&(code=code.replace(/%values%/gi,api$1.serializeToLua(options.settings.values)));let isLua=!code.startsWith(`$`);logger_default.log(`Running ${isLua?`lua`:`script`}: ${code}`),isLua?api$1.engineLua(code):api$1.engineScript(code)}function updateRoute(){if(!loaded.value||route.path!==`/options`&&!route.path.startsWith(`/options/`))return;let newRoute={name:`options`};categoryIndex.value>-1&&categoryIndex.valuecategoryIndex.value,(index,oldIndex)=>{index>-1?(special.value=null,updateRoute(),options.editor?.clearSelection(),showCategoryInfo(index,categories.value[index]?.categoryInfo),showCategoryInfo(oldIndex)):showCategoryInfo(oldIndex)}),watch(()=>special.value,val=>{val&&(categoryIndex.value=-1,updateRoute())});function selectDefaultCategory(){if(categories.value.length===0)return!1;if(props.category){let catIndex=categoryIds.value.indexOf(props.category);catIndex>-1?categoryIndex.value=catIndex:special.value=props.category}else categoryIndex.value=0;return!0}let elInfo=ref(),infos=new Map,infoHidden=ref(!1),infoView=ref([]);function showInfo(id,text=void 0){if(infos.has(id))if(text){if(infos.get(id)===text)return}else infos.delete(id);else if(!text)return;text&&infos.set(id,text),infos.size===0?infoView.value=[]:infoView.value=Array.from(infos.entries()).sort((a$1,b)=>a$1[0]-b[0]).map(tip=>({id:tip[0],text:tip[1]}))}function onResize(){elInfo.value&&(infoHidden.value=window.getComputedStyle(elInfo.value).display===`none`)}let unwatchResize=watch(elInfo,()=>{elInfo.value&&(unwatchResize(),onResize())});provide(`showInfo`,showInfo),provide(`infoHidden`,infoHidden);let fps=ref(`?`),fpsShown=ref(!1),fpsTimer;function showFps(show=!0){if(fpsShown.value=show,fpsTimer)show||(clearInterval(fpsTimer),fps.value=`?`,fpsTimer=null);else if(show){let fpsUpdate=()=>{infoHidden.value||api$1.engineLua(`getConsoleVariable("fps::avg")`,val=>fps.value=val?Number(val).toFixed(1):`?`)};fpsTimer=setInterval(fpsUpdate,500),fpsUpdate()}}let catInfoFuncs={fps:showFps},catInfoStack=new Map;function showCategoryInfo(id,info=void 0){if(!id)return;catInfoStack.has(id)&&!info?catInfoStack.delete(id):info&&catInfoStack.set(id,info);let infos$1=Array.from(catInfoStack.values()).reduce((res,name)=>res.includes(name)?res:[...res,name],[]);for(let[name,func]of Object.entries(catInfoFuncs))func(infos$1.includes(name))}function disposeCategoryInfo(){for(let func of Object.values(catInfoFuncs))func(!1)}function back(){editable.value?editable.value=!1:window.bngVue.gotoAngularState(`menu.mainmenu`)}return onBeforeMount(async()=>{api$1.engineLua(`if getCurrentLevelIdentifier() then simTimeAuthority.pushPauseRequest('options') end`)}),onMounted(()=>{if(options.init().then(()=>{loaded.value=!0,nextTick(()=>activeScope.value=`subcategories`)}),!selectDefaultCategory()){let unwatchCats=watch(categories,()=>selectDefaultCategory()&&unwatchCats())}window.addEventListener(`resize`,onResize)}),onUnmounted(()=>{options.searchText.value=``,window.removeEventListener(`resize`,onResize),disposeCategoryInfo(),options.dispose(),api$1.engineLua(`if getCurrentLevelIdentifier() then simTimeAuthority.popPauseRequest('options') end`)}),(_ctx,_cache)=>withDirectives((openBlock(),createElementBlock(`div`,_hoisted_1$19,[createBaseVNode(`div`,_hoisted_2$13,[createVNode(unref(bngScreenHeading_default),null,{default:withCtx(()=>[createTextVNode(toDisplayString(_ctx.$tt(`ui.options.options`)),1)]),_:1}),unref(options).editor&&EditUI.value?(openBlock(),createBlock(resolveDynamicComponent(EditUI.value.default),{key:0,options:unref(options),categories:categories.value,"category-index":categoryIndex.value,"onUpdate:categoryIndex":_cache[0]||=$event=>categoryIndex.value=$event,special:special.value,"onUpdate:special":_cache[1]||=$event=>special.value=$event,editable:editable.value,"onUpdate:editable":_cache[2]||=$event=>editable.value=$event},null,40,[`options`,`categories`,`category-index`,`special`,`editable`])):createCommentVNode(``,!0)]),loaded.value?createCommentVNode(``,!0):(openBlock(),createElementBlock(`div`,_hoisted_3$12,[createVNode(BlurBackground_default),withDirectives(createBaseVNode(`div`,_hoisted_4$9,null,512),[[unref(BngBlur_default)]]),createBaseVNode(`div`,_hoisted_5$8,[createBaseVNode(`div`,_hoisted_6$5,[createBaseVNode(`div`,_hoisted_7$5,toDisplayString(_ctx.$t(`ui.repository.loading`)),1)])])])),loaded.value?(openBlock(),createElementBlock(`div`,_hoisted_8$3,[createVNode(unref(bngOverflowContainer_default),{ref_key:`elCategories`,ref:elCategories,class:`categories-container`,"initial-index":0,"use-bindings-only":``},{default:withCtx(()=>[(openBlock(!0),createElementBlock(Fragment,null,renderList(categoriesView.value,cat=>(openBlock(),createElementBlock(Fragment,{key:`cat-`+cat.categoryIndex},[cat.divider?(openBlock(),createElementBlock(`div`,_hoisted_9$2)):(openBlock(),createBlock(CategoryTop_default,{key:1,id:`options-cat-`+cat.categoryIndex,index:cat.categoryIndex,"has-subcategories":cat.hasSubcategories,selected:cat.categoryIndex>=categoryRange.value[0]&&cat.categoryIndex<=categoryRange.value[1],icon:cat.icon,onClick:$event=>catNavigate(cat,!1),"hidden-by-condition":cat.hiddenByCondition,"debug-settings":cat.debugSettings,editable:editable.value,onEditCmd:categoryEdit},{default:withCtx(()=>[createTextVNode(toDisplayString(_ctx.$tt(cat.label)),1)]),_:2},1032,[`id`,`index`,`has-subcategories`,`selected`,`icon`,`onClick`,`hidden-by-condition`,`debug-settings`,`editable`]))],64))),128))]),_:1},512),createBaseVNode(`div`,{class:normalizeClass([`options-search-input`,{"search-active":searchActive.value}])},[createVNode(unref(bngBinding_default),{ref_key:`elSearchBinding`,ref:elSearchBinding,class:`search-binding`,"ui-event":`context`,controller:``},null,512),createVNode(unref(bngInputNew_default),{ref_key:`elSearch`,ref:elSearch,class:`search-input`,modelValue:unref(options).searchText.value,"onUpdate:modelValue":_cache[3]||=$event=>unref(options).searchText.value=$event,modelModifiers:{trim:!0},"leading-icon":elSearchBinding.value?.displayed?null:unref(icons).search,"floating-label":_ctx.$tt(`ui.common.search`),"show-external-button":searchActive.value,onFocus:_cache[4]||=$event=>searchFocused.value=!0,onBlur:_cache[5]||=$event=>searchFocused.value=!1},null,8,[`modelValue`,`leading-icon`,`floating-label`,`show-external-button`])],2)])):createCommentVNode(``,!0),loaded.value?(openBlock(),createElementBlock(`div`,_hoisted_10$1,[withDirectives((openBlock(),createElementBlock(`div`,_hoisted_11$1,[createVNode(BlurBackground_default),withDirectives(createBaseVNode(`div`,_hoisted_12$1,null,512),[[unref(BngBlur_default)]]),(openBlock(!0),createElementBlock(Fragment,null,renderList(subcategoriesView.value,cat=>(openBlock(),createElementBlock(Fragment,{key:`cat-`+cat.categoryIndex},[cat.divider?(openBlock(),createElementBlock(`div`,_hoisted_13$1)):cat.spacer?(openBlock(),createElementBlock(`div`,_hoisted_14$1)):(openBlock(),createBlock(CategorySide_default,{key:2,id:`options-cat-`+cat.categoryIndex,index:cat.categoryIndex,"has-subcategories":cat.hasSubcategories,selected:cat.categoryIndex===categoryIndex.value,subcategory:cat.subcategoryMode,icon:cat.icon,"hidden-by-condition":cat.hiddenByCondition,"debug-settings":cat.debugSettings,onClick:$event=>catNavigate(cat),onFocus:$event=>catNavigate(cat,!1)},{default:withCtx(()=>[createTextVNode(toDisplayString(_ctx.$tt(cat.label)),1)]),_:2},1032,[`id`,`index`,`has-subcategories`,`selected`,`subcategory`,`icon`,`hidden-by-condition`,`debug-settings`,`onClick`,`onFocus`]))],64))),128)),subcategoriesView.value.length===0&&allCategories.value[categoryIndex.value]?.persistent?(openBlock(),createBlock(CategorySide_default,{key:0,icon:allCategories.value[categoryIndex.value].icon,selected:``},{default:withCtx(()=>[createTextVNode(toDisplayString(_ctx.$tt(allCategories.value[categoryIndex.value].label)),1)]),_:1},8,[`icon`])):createCommentVNode(``,!0),searchActive.value?(openBlock(),createBlock(CategorySide_default,{key:1,icon:`search`,selected:``},{default:withCtx(()=>[createTextVNode(toDisplayString(_ctx.$tt(`ui.common.search`)),1)]),_:1})):special.value===`categories-edit`?(openBlock(),createBlock(CategorySide_default,{key:2,icon:`listIndented`,selected:``},{default:withCtx(()=>[..._cache[11]||=[createTextVNode(`Edit categories`,-1)]]),_:1})):createCommentVNode(``,!0),persistentView.value.length>0?(openBlock(),createElementBlock(Fragment,{key:3},[_cache[13]||=createBaseVNode(`div`,{class:`categories-spacer`},null,-1),editable.value&&special.value===`categories-edit`?(openBlock(),createElementBlock(Fragment,{key:0},[(openBlock(!0),createElementBlock(Fragment,null,renderList(persistentView.value,cat=>(openBlock(),createBlock(CategorySide_default,{key:`cat-`+cat.categoryIndex,id:`options-cat-`+cat.categoryIndex,"has-subcategories":cat.hasSubcategories,subcategory:cat.subcategoryMode,icon:cat.icon,index:cat.categoryIndex,"hidden-by-condition":cat.hiddenByCondition,"debug-settings":cat.debugSettings,editable:``,onClick:$event=>categoryEdit(`edit`,cat.categoryIndex),onEditCmd:categoryEdit},{default:withCtx(()=>[createTextVNode(toDisplayString(cat.spacer||cat.divider?`---`:_ctx.$tt(cat.label)),1)]),_:2},1032,[`id`,`has-subcategories`,`subcategory`,`icon`,`index`,`hidden-by-condition`,`debug-settings`,`onClick`]))),128)),createVNode(CategorySide_default,{icon:`plus`,onClick:_cache[6]||=$event=>categoryEdit(`add`,!0),style:normalizeStyle(editable.value?{}:{opacity:0,pointerEvents:`none`})},{default:withCtx(()=>[..._cache[12]||=[createTextVNode(`New category`,-1)]]),_:1},8,[`style`])],64)):(openBlock(!0),createElementBlock(Fragment,{key:1},renderList(persistentView.value,cat=>(openBlock(),createElementBlock(Fragment,{key:`cat-`+cat.categoryIndex},[cat.spacer?(openBlock(),createElementBlock(`div`,_hoisted_15$1)):cat.divider?(openBlock(),createElementBlock(`div`,_hoisted_16$1)):(openBlock(),createBlock(CategorySide_default,{key:2,id:`options-cat-`+cat.categoryIndex,"has-subcategories":cat.hasSubcategories,selected:cat.categoryIndex===categoryIndex.value,subcategory:cat.subcategoryMode,icon:cat.icon,index:cat.categoryIndex,"hidden-by-condition":cat.hiddenByCondition,"debug-settings":cat.debugSettings,onClick:$event=>catNavigate(cat)},{default:withCtx(()=>[createTextVNode(toDisplayString(_ctx.$tt(cat.label)),1)]),_:2},1032,[`id`,`has-subcategories`,`selected`,`subcategory`,`icon`,`index`,`hidden-by-condition`,`debug-settings`,`onClick`]))],64))),128))],64)):createCommentVNode(``,!0)])),[[unref(BngScopedNav_default),{activated:!searchActive.value&&activeScope.value===`subcategories`,bubbleWhitelistEvents:[`context`]}],[unref(BngOnUiNav_default),mainCatNav,`tab_l,tab_r`],[unref(BngOnUiNav_default),back,`back,menu`],[unref(BngOnUiNav_default),()=>activeScope.value=`content`,`ok`,{focusRequired:!0}]]),withDirectives((openBlock(),createElementBlock(`div`,_hoisted_17$1,[createVNode(BlurBackground_default,{class:normalizeClass([`background`,{"background-no-info":infoHidden.value}])},null,8,[`class`]),withDirectives(createBaseVNode(`div`,{class:normalizeClass([`background`,{"background-no-info":infoHidden.value}])},null,2),[[unref(BngBlur_default)]]),categoryIndex.value>-1?withDirectives((openBlock(),createElementBlock(`div`,{key:0,ref_key:`itemsContainer`,ref:itemsContainer,class:`options-content`,"bng-ui-scope":`options-content`},[(openBlock(!0),createElementBlock(Fragment,null,renderList(itemsView.value,(item,index)=>(openBlock(),createBlock(Item_default,{key:`item-`+categoryIndex.value*1e5+`-`+index,parent:categories.value[categoryIndex.value],index,level:0,data:item,onClick,onChange,onEditCmd:itemEdit},null,8,[`parent`,`index`,`data`]))),128)),editable.value?(openBlock(),createElementBlock(`div`,_hoisted_18$1,[createVNode(unref(bngButton_default),{accent:unref(ACCENTS).outlined,icon:unref(icons).plus,onClick:_cache[7]||=$event=>unref(options).editor.itemAdd(categories.value[categoryIndex.value])},{default:withCtx(()=>[..._cache[14]||=[createTextVNode(`Add new item`,-1)]]),_:1},8,[`accent`,`icon`]),createVNode(unref(bngButton_default),{accent:unref(ACCENTS).outlined,icon:unref(icons).addListItem,disabled:!unref(options).editor.clipItems.value.length,onClick:_cache[8]||=$event=>catItemsPaste()},{default:withCtx(()=>[createTextVNode(`Paste `+toDisplayString(unref(options).editor.clipTitle.value),1)]),_:1},8,[`accent`,`icon`,`disabled`]),createVNode(unref(bngButton_default),{accent:unref(ACCENTS).outlined,icon:unref(options).editor.selectedItems.value.size>0?unref(icons).checkboxOn:unref(icons).checkboxOff,onClick:_cache[9]||=$event=>unref(options).editor.itemSelectAll(categories.value[categoryIndex.value])},{default:withCtx(()=>[createTextVNode(toDisplayString(unref(options).editor.selectedItems.value.size>0?`Deselect all`:`Select all`),1)]),_:1},8,[`accent`,`icon`])])):createCommentVNode(``,!0)])),[[unref(BngUiNavScroll_default),void 0,void 0,{force:!0}]]):searchActive.value?withDirectives((openBlock(),createElementBlock(`div`,_hoisted_19$1,[(openBlock(!0),createElementBlock(Fragment,null,renderList(unref(options).searchResults.value,(item,index)=>(openBlock(),createBlock(Item_default,{key:`search-`+index,index,level:0,data:item,onClick,onChange},null,8,[`index`,`data`]))),128))])),[[unref(BngUiNavScroll_default),void 0,void 0,{force:!0}]]):special.value===`categories-edit`?(openBlock(),createElementBlock(`div`,_hoisted_20$1,[(openBlock(!0),createElementBlock(Fragment,null,renderList(allCategories.value,cat=>(openBlock(),createElementBlock(Fragment,{key:`cat-`+cat.categoryIndex},[cat.persistent?createCommentVNode(``,!0):(openBlock(),createBlock(CategorySide_default,{key:0,id:`options-cat-`+cat.categoryIndex,"has-subcategories":cat.hasSubcategories,subcategory:cat.subcategoryMode,icon:cat.icon,index:cat.categoryIndex,"hidden-by-condition":cat.hiddenByCondition,"debug-settings":cat.debugSettings,editable:editable.value,onClick:$event=>categoryEdit(`edit`,cat.categoryIndex),onEditCmd:categoryEdit},{default:withCtx(()=>[createTextVNode(toDisplayString(cat.spacer||cat.divider?`---`:_ctx.$tt(cat.label)),1)]),_:2},1032,[`id`,`has-subcategories`,`subcategory`,`icon`,`index`,`hidden-by-condition`,`debug-settings`,`editable`,`onClick`]))],64))),128)),editable.value?(openBlock(),createBlock(CategorySide_default,{key:0,icon:`plus`,onClick:_cache[10]||=$event=>categoryEdit(`add`),style:normalizeStyle(editable.value?{}:{opacity:0,pointerEvents:`none`})},{default:withCtx(()=>[..._cache[15]||=[createTextVNode(`New category`,-1)]]),_:1},8,[`style`])):createCommentVNode(``,!0)])):createCommentVNode(``,!0),createBaseVNode(`div`,{ref_key:`elInfo`,ref:elInfo,class:normalizeClass([`options-info`,{"info-hidden":!!special.value}])},[createVNode(BlurBackground_default),withDirectives(createBaseVNode(`div`,_hoisted_21$1,null,512),[[unref(BngBlur_default)]]),(openBlock(!0),createElementBlock(Fragment,null,renderList(infoView.value,tip=>(openBlock(),createElementBlock(`span`,{key:tip.id,innerHTML:tip.text},null,8,_hoisted_22$1))),128)),_cache[17]||=createBaseVNode(`div`,{class:`options-spacer`},null,-1),fpsShown.value?(openBlock(),createElementBlock(`div`,_hoisted_23$1,[_cache[16]||=createTextVNode(`FPS: `,-1),createBaseVNode(`span`,null,toDisplayString(fps.value),1)])):createCommentVNode(``,!0)],2)])),[[unref(BngScopedNav_default),{activated:activeScope.value===`content`,bubbleWhitelistEvents:[`context`]}],[unref(BngOnUiNav_default),mainCatNav,`tab_l,tab_r`],[unref(BngOnUiNav_default),fromContent,`back`],[unref(BngOnUiNav_default),back,`menu`]])])):createCommentVNode(``,!0)])),[[unref(BngOnUiNav_default),mainCatNav,`tab_l,tab_r`],[unref(BngOnUiNav_default),back,`back,menu`],[unref(BngOnUiNav_default),toSearchAndBack,`context`],[unref(BngUiNavLabel_default),`ui.common.search`,`context`]])}},OptionsView_default=__plugin_vue_export_helper_default(_sfc_main$23,[[`__scopeId`,`data-v-206a0fb3`]]),routes_default$12=[{path:`/options/:category?`,name:`options`,component:OptionsView_default,props:!0,meta:{infoBar:{visible:!0,showSysInfo:!0},uiApps:{shown:!1}}}],cfg={background:[`var(--bng-black-o8)`,`var(--bng-black-o4)`],info:{icon:`var(--bng-cool-gray-500)`,iconSize:.15,label:`var(--bng-off-white)`,labelSize:.05,line:`var(--bng-cool-gray-700)`,lineSize:.0025,hotkey:`#aaa`,hotkeySize:.04,unfocusedColor:`var(--bng-cool-gray-500)`,focusedColor:`var(--bng-off-white)`},button:{top:.45,height:.175,margin:.004,corners:.03,background:`var(--bng-black)`,highlight:`var(--bng-ter-blue-gray-700)`,border:`var(--bng-cool-gray-700)`,borderHighlight:`var(--bng-cool-gray-500)`,borderSize:.0025,folder:`var(--bng-ter-blue-gray-900)`,folderTop:.45,folderHeight:.015,markerTop:.3,markerHeight:.025,marker:`var(--bng-orange)`,icon:`var(--bng-off-white)`,iconSize:.1,majorBackground:[`var(--bng-black)`,`var(--bng-ter-blue-gray-850)`],majorHighlight:[`var(--bng-ter-blue-gray-600)`,`var(--bng-ter-blue-gray-700)`],pinnedDotInvisible:{fill:`transparent`,stroke:`transparent`,r:4},markDotSolid:{fill:`rgba(var(--bng-cool-gray-100-rgb),0.7)`,stroke:`transparent`,r:4},markDotOutline:{fill:`transparent`,stroke:`rgba(var(--bng-cool-gray-100-rgb),0.7)`,r:3},markStar:{fill:`rgba(var(--bng-cool-gray-100-rgb),0.7)`,stroke:`rgba(var(--bng-cool-gray-100-rgb),0.7)`,"stroke-width":2,r:3,isStar:!0,starPoints:5,innerRadius:1.5,outerRadius:3}},pointer:{color:`var(--bng-orange)`,size:6}},size=500,pointerRadius=125,controlsHotkey=``,getHotkey=action=>{let viewerObj=controls_default().makeViewerObj({action});return viewerObj?icons[viewerObj.icon].glyph+` `+viewerObj.control.split(/[ -]/).map(s=>s.substring(0,1).toUpperCase()+s.substring(1)).join(`+`):``},RadialSVG=class{parent;svg;config;events;itemsCont;info;buttons;pointer;menuIcon=``;constructor(events$3={},config=cfg,element=void 0){this.events=events$3,this.config=config,element&&this.create(element)}create(element){this.parent!==element&&(this.parent=element,this.svg||([this.svg,this.itemsCont,this.info,this.pointer]=createSvg(this.config)),this.parent.appendChild(this.svg))}update(items$2=[]){!this.itemsCont||!this.info||(controlsHotkey=getHotkey(`menu_item_focus_ud`),this.buttons=updateSvg(this.itemsCont,this.info,items$2,this.events,this.config,this.buttons||[],this))}dispose(){this.parent&&(this.parent.removeChild(this.svg),this.parent=null,this.svg=null,this.itemsCont=null,this.info=null,this.buttons=null)}setPointer(x,y){if(!this.pointer)return;let magnitude=Math.sqrt(x*x+y*y);magnitude>.1?(x/=magnitude,y/=magnitude,this.pointer.setAttribute(`cx`,x*pointerRadius+size/2),this.pointer.setAttribute(`cy`,-y*pointerRadius+size/2),this.pointer.setAttribute(`display`,`block`)):this.pointer.setAttribute(`display`,`none`)}setMenuIcon(iconName){if(this.menuIcon=iconName,this.info){let iconGlyph=getIconGlyph(this.menuIcon);this.info.icon.textContent=iconGlyph}}},svgns=`http://www.w3.org/2000/svg`,xhtmlns=`http://www.w3.org/1999/xhtml`,pid=Math.PI*2,getIconGlyph=iconName=>(iconName&&iconName in icons?icons[iconName]:icons.beamNG).glyph,setAttrs=(elm,attrs)=>Object.entries(attrs).forEach(attr=>elm.setAttribute(...attr)),setStyles=(elm,styles)=>Object.entries(styles).forEach(rule=>elm.style.setProperty(...rule)),f2size=f=>f*size,getPoint=(turn,radius,center=[.5,.5])=>[center[0]+radius*Math.cos(turn*pid),center[1]+radius*Math.sin(turn*pid)].map(n=>f2size(n).toFixed(5)),drawLine=to=>` L ${to.join(`,`)} `,drawBezier=(control,to)=>` S ${control.join(`,`)} ${to.join(` `)} `,drawArc=(to,radius,invert=!1)=>` A ${radius} ${radius}, 0, 0, ${invert?`0`:`1`}, ${to.join(` `)} `;function createSimplePath(pos,rad,width$1,height$1){let d=`M ${getPoint(pos,rad).join(`,`)} `;return d+=drawArc(getPoint(pos+width$1,rad),f2size(rad),!1),d+=drawLine(getPoint(pos+width$1,rad-height$1)),d+=drawArc(getPoint(pos,rad-height$1),f2size(rad-height$1),!0),d+=drawLine(getPoint(pos,rad)),d+=`Z`,d}function createPath({pos,rad,width:width$1,height:height$1,corner,padout,padin}){corner>height$1&&(corner=height$1);let corh=corner*rad/Math.PI,corv=corner*rad,d=`M ${getPoint(pos+padout+corh,rad).join(`,`)} `;return d+=drawArc(getPoint(pos+width$1-padout-corh,rad),f2size(rad),!1),d+=drawBezier(getPoint(pos+width$1-padout,rad),getPoint(pos+width$1-padout,rad-corv)),d+=drawLine(getPoint(pos+width$1-padout-padin,rad-height$1+corv)),d+=drawBezier(getPoint(pos+width$1-padout-padin,rad-height$1),getPoint(pos+width$1-padout-corh-padin,rad-height$1)),d+=drawArc(getPoint(pos+padout+corh+padin,rad-height$1),f2size(rad-height$1),!0),d+=drawBezier(getPoint(pos+padout+padin,rad-height$1),getPoint(pos+padout+padin,rad-height$1+corv)),d+=drawLine(getPoint(pos+padout,rad-corv)),d+=drawBezier(getPoint(pos+padout,rad),getPoint(pos+padout+corh,rad)),d+=`Z`,d}function updateSvg(cont,info,items$2,events$3,config=cfg,buttons=[],radialInstance=null){let btns=[...buttons||[]],elmsRem=btns.splice(items$2.length);for(let elm of elmsRem)cont.removeChild(elm.element);if(items$2.length<1)return null;for(let index=btns.length;indexicon,file:icon=>`/ui/modules/apps/RadialMenu/mods_icons/`+icon,symbol:icon=>`#`+({radial_Drift_ESC:`radial_drift_ESC`,radial_Sport_ESC:`radial_sport_ESC`,radial_Regular_ESC:`radial_regular_ESC`,radial_ESC:`radial_regular_ESC`}[icon]||icon)};function createButton(index,info,config,item){let btn={index},majorGradId=uniqueSafeId(),majorHighlightGradId=uniqueSafeId(),control=document.createElementNS(svgns,`g`);btn.element=control;function createGradient(id,colors){let grad=document.createElementNS(svgns,`radialGradient`);return setAttrs(grad,{id,cx:`0.5`,cy:`0.5`,r:`0.5`,fx:`0.5`,fy:`0.5`}),colors.forEach((color,index$1)=>{let stop$1=document.createElementNS(svgns,`stop`);setAttrs(stop$1,{offset:index$1/(colors.length-1),"stop-color":color}),grad.appendChild(stop$1)}),grad}let defs=document.createElementNS(svgns,`defs`);defs.appendChild(createGradient(majorGradId,config.button.majorBackground)),defs.appendChild(createGradient(majorHighlightGradId,config.button.majorHighlight)),control.appendChild(defs);let button=document.createElementNS(svgns,`path`);config.button.border&&config.button.borderSize>0&&setAttrs(button,{stroke:config.button.border,"stroke-width":f2size(config.button.borderSize)}),control.appendChild(button);let folder=document.createElementNS(svgns,`path`);folder.setAttribute(`fill`,config.button.folder),control.appendChild(folder);let marker$1=document.createElementNS(svgns,`path`);marker$1.setAttribute(`fill`,`none`),control.appendChild(marker$1);let pinnedDot=document.createElementNS(svgns,`circle`);setAttrs(pinnedDot,config.button.markDotSolid),pinnedDot.setAttribute(`style`,`display: none`),control.appendChild(pinnedDot);let starPath=document.createElementNS(svgns,`path`),starConfig=config.button.markStar,points=starConfig.starPoints||5,innerRadius=starConfig.innerRadius||1.5,outerRadius=starConfig.outerRadius||3,starPathData=``;for(let i=0;ion?iconRect.removeAttribute(`style`):iconRect.setAttribute(`style`,`display: none`),setGlyph=glyph=>iconText.textContent=glyph||``,setImage=path=>{path?(iconImage.setAttribute(`href`,path),iconImage.removeAttribute(`style`)):(iconImage.removeAttribute(`href`),iconImage.setAttribute(`style`,`display: none`))},setSymbol=id=>{id?(iconMask.setAttribute(`mask-type`,`luminocity`),iconSymbol.setAttribute(`href`,id),iconSymbol.removeAttribute(`style`)):(iconMask.setAttribute(`mask-type`,`alpha`),iconSymbol.removeAttribute(`href`),iconSymbol.setAttribute(`style`,`display: none`))},itype=iconType(item$1.icon);switch(itype){case`glyph`:setGlyph(getIconGlyph(item$1.icon)),setRect(!1),setImage(),setSymbol();break;case`symbol`:setImage(),setSymbol(iconGet[itype](item$1.icon)),setRect(!0),setGlyph();break;default:setImage(iconGet[itype](item$1.icon)),setSymbol(),setRect(!0),setGlyph();break}}let hitzone=document.createElementNS(svgns,`path`);setAttrs(hitzone,{fill:`transparent`,style:`pointer-events: fill`}),control.appendChild(hitzone);function updateHitzone(position,length,config$1){hitzone.setAttribute(`d`,createSimplePath(position-length/2,config$1.button.top,length,config$1.button.height))}function updateEvents$1(events$3,radialInstance){btn._handlers&&(hitzone.removeEventListener(`mouseover`,btn._handlers.focus),hitzone.removeEventListener(`mouseleave`,btn._handlers.blur),hitzone.removeEventListener(`click`,btn._handlers.click),hitzone.removeEventListener(`mousedown`,btn._handlers.down),hitzone.removeEventListener(`mouseup`,btn._handlers.up),hitzone.removeEventListener(`contextmenu`,btn._handlers.contextMenu));let item$1=btn.item,index$1=btn.index;return btn.menuIcon=radialInstance?.menuIcon||``,btn._handlers={focus(){if(item$1.focused&&btn._focused)return;let highlightFill=item$1.majorButton?`url(#${majorHighlightGradId})`:config.button.highlight;button.setAttribute(`fill`,highlightFill),button.setAttribute(`stroke`,config.button.borderHighlight),marker$1.setAttribute(`fill`,config.button.marker);let itype=iconType(item$1.icon);itype===`glyph`?(setStyles(info.icon,{"background-color":`transparent`,"-webkit-mask-image":`none`,color:config.info.focusedColor}),info.icon.textContent=getIconGlyph(item$1.icon)):(info.icon.textContent=``,itype===`symbol`&&info.iconSymbol.setAttribute(`href`,iconGet[itype](item$1.icon)),setStyles(info.icon,{"background-color":config.info.icon,"-webkit-mask-image":itype===`symbol`?`url('#${info.iconMaskId}')`:`url('${iconGet[itype](item$1.icon)}')`})),info.label.textContent=typeof item$1.title==`string`?$translate.contextTranslate({txt:item$1.title,context:item$1.context}):$translate.contextTranslate(item$1.title),info.label.style.color=config.info.focusedColor,info.price.textContent=item$1?.price?.money?.amount===void 0?``:item$1.price.money.amount+` `,info.hotkey.textContent=item$1.hotkey||``,info.cont.removeAttribute(`style`),item$1.focused=!0,btn._focused=!0,typeof events$3.focus==`function`&&events$3.focus(item$1,index$1)},blur(){if(!item$1.focused&&!btn._focused)return;let normalFill=item$1.majorButton?`url(#${majorGradId})`:config.button.background;button.setAttribute(`fill`,normalFill),button.setAttribute(`stroke`,config.button.border),marker$1.setAttribute(`fill`,`none`),setStyles(info.icon,{"background-color":`transparent`,"-webkit-mask-image":`none`,color:config.info.unfocusedColor});let iconGlyph=getIconGlyph(btn.menuIcon);info.icon.textContent=iconGlyph,info.label.textContent=`Select an option`,info.price.textContent=``,info.hotkey.textContent=controlsHotkey,info.label.style.color=config.info.unfocusedColor,item$1.focused=!1,btn._focused=!1,typeof events$3.blur==`function`&&events$3.blur(item$1,index$1)},click(evt){evt&&evt.stopPropagation(),!(!item$1.enabled||!events$3||evt&&!evt.fromController&&evt.type!==`ui_nav`)&&(btn._handlers.isDown=!1,typeof events$3.click==`function`&&events$3.click(item$1,index$1))},down(evt){!item$1.enabled||!events$3||evt.button!==0||(btn._handlers.isDown=!0,typeof events$3.down==`function`&&events$3.down(item$1,index$1))},up(evt){!btn._handlers.isDown||!item$1.enabled||!events$3||evt.button!==0||(btn._handlers.isDown=!1,typeof events$3.up==`function`&&events$3.up(item$1,index$1))},contextMenu(evt){evt&&evt.stopPropagation(),events$3&&typeof events$3.contextAction==`function`&&events$3.contextAction(item$1,index$1)}},hitzone.addEventListener(`mouseover`,btn._handlers.focus),hitzone.addEventListener(`mouseleave`,btn._handlers.blur),hitzone.addEventListener(`click`,btn._handlers.click,!0),hitzone.addEventListener(`mousedown`,btn._handlers.down),hitzone.addEventListener(`mouseup`,btn._handlers.up),hitzone.addEventListener(`contextmenu`,btn._handlers.contextMenu),btn._handlers}function updateEnable(item$1){item$1.enabled?(hitzone.setAttribute(`cursor`,`pointer`),control.removeAttribute(`opacity`)):(hitzone.removeAttribute(`cursor`),control.setAttribute(`opacity`,`0.5`))}return btn.update=(item$1,events$3=void 0,radialInstance=null)=>{btn.item=item$1;let length=Math.min(item$1.size,.5),position=(item$1.position-.5)%1;updateButton(position,length,config,item$1),updateHitzone(position,length,config),updateIcon(position,length,config,item$1),updateEnable(item$1),btn._handlers=updateEvents$1(events$3,radialInstance),Object.assign(btn,btn._handlers),(item$1.focused||btn._focused)&&btn._handlers.focus()},btn}function createSvg(config=cfg){let svg=document.createElementNS(svgns,`svg`);setAttrs(svg,{viewBox:`0 0 ${size} ${size}`,width:`100%`,height:`100%`,preserveAspectRatio:`xMidYMid meet`,style:`pointer-events: none`});let gradId=Array.isArray(config.background)?uniqueSafeId():null;if(gradId){let grad=document.createElementNS(svgns,`radialGradient`);grad.setAttribute(`id`,gradId);for(let i=0;i{evt.stopPropagation()},!0),svg.appendChild(bg);let nfo={cont:document.createElementNS(svgns,`foreignObject`),body:document.createElementNS(xhtmlns,`body`),wrap:document.createElementNS(xhtmlns,`div`),icon:document.createElementNS(xhtmlns,`div`),iconSymbol:document.createElementNS(svgns,`use`),iconMaskId:uniqueSafeId(),label:document.createElementNS(xhtmlns,`div`),price:document.createElementNS(xhtmlns,`div`),hotkey:document.createElementNS(xhtmlns,`div`)},foMinSize=200,nfoSize=size>=200?size:200;setAttrs(nfo.cont,{style:`display: none`,width:nfoSize,height:nfoSize}),size<200&&nfo.cont.setAttribute(`transform`,`scale(${size*.005})`),nfo.body.setAttribute(`xmlns`,xhtmlns),setStyles(nfo.body,{width:`100%`,height:`100%`}),setStyles(nfo.wrap,{width:`${nfoSize*.5}px`,height:`${nfoSize*.4}px`,margin:`${nfoSize*.3}px ${nfoSize*.25}px`,display:`flex`,"flex-direction":`column`,"align-items":`center`,"justify-content":`space-between`,"font-family":`var(--fnt-defs)`}),setStyles(nfo.icon,{color:config.info.icon,"font-size":`${config.info.iconSize*nfoSize}px`,"font-family":`bngIcons`,width:`${config.info.iconSize*nfoSize}px`,height:`${config.info.iconSize*nfoSize}px`,"-webkit-mask-image":`none`,"-webkit-mask-size":`contain`,"-webkit-mask-position":`50% 50%`,"-webkit-mask-repeat":`no-repeat`,"background-color":`transparent`});let iconSvg=document.createElementNS(svgns,`svg`);setAttrs(iconSvg,{viewBox:`0 0 ${config.info.iconSize*nfoSize} ${config.info.iconSize*nfoSize}`,width:`0`,height:`0`,style:`position: absolute;`});let iconMask=document.createElementNS(svgns,`mask`);setAttrs(iconMask,{id:nfo.iconMaskId,maskUnits:`userSpaceOnUse`,maskContentUnits:`userSpaceOnUse`,"mask-type":`luminocity`}),setAttrs(nfo.iconSymbol,{x:`0`,y:`0`,width:config.info.iconSize*nfoSize,height:config.info.iconSize*nfoSize,fill:`#fff`}),iconMask.appendChild(nfo.iconSymbol),iconSvg.appendChild(iconMask),setStyles(nfo.label,{"min-height":`2em`,width:`100%`,"text-align":`center`,color:config.info.label,"font-size":`${config.info.labelSize*nfoSize}px`,"font-family":`var(--fnt-defs)`}),setStyles(nfo.price,{width:`100%`,"text-align":`center`,color:config.info.label,"font-size":`${config.info.labelSize*.8*nfoSize}px`,"font-family":`bngIcons, var(--fnt-defs)`}),setStyles(nfo.hotkey,{width:`80%`,"text-align":`center`,"padding-top":`1px`,"min-height":`${config.info.hotkeySize*nfoSize+10}px`,"border-top":`${config.info.lineSize*nfoSize}px solid ${config.info.line}`,color:config.info.hotkey,"font-size":`${config.info.hotkeySize*nfoSize}px`,"font-family":`bngIcons, "Noto Sans Mono", var(--fnt-defs)`}),nfo.wrap.appendChild(iconSvg),nfo.wrap.appendChild(nfo.icon),nfo.wrap.appendChild(nfo.label),nfo.wrap.appendChild(nfo.price),nfo.wrap.appendChild(nfo.hotkey),nfo.body.appendChild(nfo.wrap),nfo.cont.appendChild(nfo.body),svg.appendChild(nfo.cont);let cont=document.createElementNS(svgns,`g`);svg.appendChild(cont);let pointer=document.createElementNS(svgns,`circle`);return setAttrs(pointer,{r:config.pointer.size,fill:config.pointer.color,display:`none`}),svg.appendChild(pointer),nfo.icon.textContent=getIconGlyph(svg.menuIcon),nfo.label.textContent=`Select an option`,nfo.price.textContent=``,nfo.label.style.color=config.info.unfocusedColor,controlsHotkey=getHotkey(`menu_item_focus_ud`),nfo.hotkey.textContent=controlsHotkey,nfo.cont.removeAttribute(`style`),[svg,cont,nfo,pointer]}var _hoisted_1$18={class:`radial-infos`},_hoisted_2$12={class:`radial-breadcrumbs`},_hoisted_3$11={key:0,class:`radial-categories`},_hoisted_4$8={class:`radial-plate`},_hoisted_5$7={class:`radial-category-label`},_hoisted_6$4={key:0,class:`radial-quick-tabs`},_hoisted_7$4={key:1,class:`radial-description`},sensivity=.5,_sfc_main$22={__name:`Radial`,setup(__props){useUINavScope(`radialMenu`);let infobar=useInfoBar(),controls$1=controls_default(),events$3=useEvents(),radialData=ref({}),temporaryHidden=ref(!1),breadcrumbs=computed(()=>radialData.value&&radialData.value.breadcrumbs&&Array.isArray(radialData.value.breadcrumbs)?radialData.value.breadcrumbs.map(str=>$translate.instant(str)).join(` / `):``),focusedItem=computed(()=>{let items$2=radialData?.value?.items;return items$2&&Array.isArray(items$2)?items$2.find(item=>item.focused):null}),hasLRShoulderButtons=computed(()=>radialData.value&&radialData.value.hasLRShoulderButtons),radialSvg=new RadialSVG({click:(item,index)=>{Lua_default.ui_audio.playEventSound(`bng_click_hover_generic`,`click`),Lua_default.core_quickAccess.selectItem(index+1,!0,1)},down:(item,index)=>{Lua_default.ui_audio.playEventSound(`bng_click_hover_generic`,`click`),Lua_default.core_quickAccess.selectItem(index+1,!0,1)},focus:(item,index)=>{Lua_default.ui_audio.playEventSound(`bng_click_hover_generic`,`focus`)},contextAction:(item,index)=>{Lua_default.ui_audio.playEventSound(`bng_click_hover_generic`,`focus`),Lua_default.core_quickAccess.contextAction(index+1,!0,1)}}),radialCont=ref(),requestData=async()=>{radialData.value=await Lua_default.core_quickAccess.getUiData();let items$2=Array.isArray(radialData.value.items)?radialData.value.items:[];for(let item of items$2)item.hotkey=getHotkey$1(item.action);radialSvg.setMenuIcon(radialData.value.menuIcon||`beamNG`),radialSvg.update(items$2)},getHotkey$1=action=>{let viewerObj=controls$1.makeViewerObj({action});return viewerObj?icons[viewerObj.icon].glyph+` `+viewerObj.control.split(/[ -]/).map(s=>s.substring(0,1).toUpperCase()+s.substring(1)).join(``):``},setLevel=level$1=>{Lua_default.ui_audio.playEventSound(`bng_click_hover_generic`,`focus`),Lua_default.core_quickAccess.setEnabled(!0,level$1,!1)},close=()=>{Lua_default.core_quickAccess.setEnabled(!1,``,!1)},back=()=>{radialData.value.backButtonIndex?Lua_default.core_quickAccess.back():close()},switchCategory=left=>{let indexOffset=left?-1:1;for(let i=0;i{let actions=radialData.value.items;for(let i=0;i{if(radialData.value.categories.length>0){switchCategory(evt.detail.name===`tab_l`);return}LRAction(evt.detail.name)},processMouseClick=evt=>{if(!radialSvg.buttons)return;let elm=radialSvg?.buttons?.find(elm$1=>elm$1._focused)||radialSvg?.buttons?.find(elm$1=>elm$1.item.focused);return evt.detail.name===`context`?elm&&elm.contextMenu(evt):elm&&elm.click(evt),elm},isStickActive=(x,y)=>Math.sqrt(x**2+y**2)>sensivity,pointToItem=(x,y)=>{if(!radialSvg.buttons)return;let len=radialSvg.buttons.length,idx=-1;if(radialSvg.setPointer(x,y),x!==0||y!==0){let cursorPos=.5-Math.atan2(y,x)/Math.PI/2;for(let i=0;i=startPos&&cursorPos=startPos||cursorPos-1&&idx{evt.detail.name===`focus_ud`?stickY=evt.detail.value:stickX=evt.detail.value;let stickActiveBefore=stickActive;stickActive=isStickActive(stickX,stickY),stickActive&&pointToItem(stickX,stickY),!stickActive&&stickActiveBefore&&pointToItem(0,0)},dpadX=0,dpadY=0,processDpadInput=evt=>{switch(evt.detail.name){case`focus_l`:dpadX=-evt.detail.value;break;case`focus_r`:dpadX=evt.detail.value;break;case`focus_u`:dpadY=evt.detail.value;break;case`focus_d`:dpadY=-evt.detail.value;break}dpadX=0+ +dpadX,dpadY=0+ +dpadY,pointToItem(dpadX,dpadY)},openFavoriteSelector=()=>{if(radialData.value.pathBeforeCategory===`favorites`){for(let i=0;i{let isOnComponents=event.target.closest(`.radial-categories, .radial-svg, .radial-tab-left, .radial-tab-right`);event.isTrusted&&event.sourceCapabilities?.firesTouchEvents===!1&&!isOnComponents&&(event.button===0?close():event.button===2&&back())};events$3.on(`radialMenuUpdated`,requestData),events$3.on(`RadialTemporaryHide`,hide$2=>{temporaryHidden.value=hide$2}),onBeforeMount(()=>{infobar.clearHints()}),onMounted(()=>{infobar.visible=!0,radialSvg.create(radialCont.value),requestData()});let headingTitle=computed(()=>radialData.value?.breadcrumbs?.[0]?$translate.instant(radialData.value.breadcrumbs[0]):radialData.value?.items?.length?`Radial Menu`:`No Actions Available`),hasCategories=computed(()=>radialData.value?.categories&&(Array.isArray(radialData.value.categories)?radialData.value.categories.length>0:Object.keys(radialData.value.categories).length>0));return(_ctx,_cache)=>withDirectives((openBlock(),createElementBlock(`div`,{class:normalizeClass([`radial-menu`,{temporaryHidden:temporaryHidden.value}]),"bng-ui-scope":`radialMenu`,onMousedown:handleMouseDown},[createBaseVNode(`div`,_hoisted_1$18,[createVNode(bngCardHeading_default,{class:`radial-title`},{default:withCtx(()=>[createTextVNode(toDisplayString(headingTitle.value),1)]),_:1}),createBaseVNode(`div`,_hoisted_2$12,toDisplayString(breadcrumbs.value),1),hasCategories.value?(openBlock(),createElementBlock(`div`,_hoisted_3$11,[createVNode(unref(bngBinding_default),{class:`radial-plate radial-tab-left`,"ui-event":`tab_l`,style:normalizeStyle({"--rad-tab-icon":`'${unref(icons).arrowSmallLeft.glyph}'`}),controller:``,onClick:_cache[0]||=$event=>switchCategory(!0)},null,8,[`style`]),createBaseVNode(`div`,_hoisted_4$8,[(openBlock(!0),createElementBlock(Fragment,null,renderList(radialData.value.categories,category=>withDirectives((openBlock(),createBlock(unref(bngImageTile_default),{key:category.id,onClick:$event=>setLevel(category.goto),tabindex:`0`,"bng-nav-item":``,class:normalizeClass([`radial-category`,{selected:category.id===radialData.value.selectedCategory}]),icon:unref(icons)[category.icon||`beamNG`]},{default:withCtx(()=>[createBaseVNode(`div`,_hoisted_5$7,toDisplayString(unref($translate).instant(category.title)),1)]),_:2},1032,[`onClick`,`class`,`icon`])),[[unref(BngOnUiNav_default),void 0,`ok`,{asMouse:!0,focusRequired:!0}]])),128)),_cache[4]||=createBaseVNode(`div`,{class:`background-plate`},null,-1)]),createVNode(unref(bngBinding_default),{class:`radial-plate radial-tab-right`,"ui-event":`tab_r`,controller:``,style:normalizeStyle({"--rad-tab-icon":`'${unref(icons).arrowSmallRight.glyph}'`}),onClick:_cache[1]||=$event=>switchCategory(!1)},null,8,[`style`])])):createCommentVNode(``,!0)]),hasLRShoulderButtons.value?(openBlock(),createElementBlock(`div`,_hoisted_6$4,[createVNode(unref(bngBinding_default),{class:`radial-plate radial-tab-left`,style:normalizeStyle({"--rad-tab-icon":`'${unref(icons).arrowSmallLeft.glyph}'`}),"ui-event":`tab_l`,controller:``,onClick:_cache[2]||=$event=>LRAction(`tab_l`)},null,8,[`style`]),createVNode(unref(bngBinding_default),{class:`radial-plate radial-tab-right`,style:normalizeStyle({"--rad-tab-icon":`'${unref(icons).arrowSmallRight.glyph}'`}),"ui-event":`tab_r`,controller:``,onClick:_cache[3]||=$event=>LRAction(`tab_r`)},null,8,[`style`])])):createCommentVNode(``,!0),createBaseVNode(`div`,{ref_key:`radialCont`,ref:radialCont,class:`radial-svg`},null,512),focusedItem.value?.desc?(openBlock(),createElementBlock(`div`,_hoisted_7$4,toDisplayString(unref(content_exports).bbcode.parse(unref($translate).contextTranslate(focusedItem.value.desc,!0))),1)):createCommentVNode(``,!0)],34)),[[unref(BngBlur_default),!temporaryHidden.value],[unref(BngOnUiNav_default),openFavoriteSelector,`context`],[unref(BngOnUiNav_default),back,`menu,back`],[unref(BngOnUiNav_default),processTabInput,`tab_l,tab_r`],[unref(BngOnUiNav_default),processStickInput,`focus_lr,focus_ud`],[unref(BngOnUiNav_default),processDpadInput,`focus_l,focus_r,focus_u,focus_d`,{down:!0}],[unref(BngOnUiNav_default),processDpadInput,`focus_l,focus_r,focus_u,focus_d`,{up:!0}],[unref(BngOnUiNav_default),processMouseClick,`ok,context`],[unref(BngUiNavLabel_default),radialData.value.backButtonIndex?`ui.common.back`:`ui.common.close`,`menu,back`],[unref(BngUiNavLabel_default),`Radial menu navigation`,`focus_lr,focus_ud,focus_l,focus_r,focus_u,focus_d`],[unref(BngUiNavLabel_default),`Select`,`ok`],[unref(BngUiNavLabel_default),`Configure Slot`,`context`],[unref(BngUiNavLabel_default),`Switch Category`,`tab_l,tab_r`]])}},Radial_default=__plugin_vue_export_helper_default(_sfc_main$22,[[`__scopeId`,`data-v-9330a4cb`]]),routes_default$13=[{path:`/radial`,name:`radial`,component:Radial_default,meta:{uiApps:{shown:!1}}}],routes_default$14=[{path:`/recovery`,name:`recovery`,component:Recovery_default,props:!0}],isFuelEnergyType=type=>[`gasoline`,`diesel`].includes(type);const useRefuelStore=defineStore(`refuel`,()=>{let{events:events$3}=useBridge(),minSlider=23,maxSlider=80,minEnergy=0,fuelOptions=[{id:1,value:0,name:`FuelType-1`},{id:2,value:1,name:`FuelType-2`},{id:3,value:2,name:`FuelType-3`}],energyTypes=ref([]),fuelTanks=ref([]),overallPrice=ref(0),flowRate=ref(0),currentEnergyType=ref(null),showFuelTypeSettings=ref(!1),showAmountSettings=ref(!1),energyTypesToLocalUnits=ref({}),gasStationName=ref(``),fuelDiscountData=ref({}),isFuelling=computed(()=>flowRate.value>0),currentFuelData=computed(()=>fuelTanks.value.filter(f=>f.energyType===currentEnergyType.value)[0]),currentFuelType=computed(()=>currentEnergyType.value===``?``:isFuelEnergyType(currentEnergyType.value)?`fuel`:`charge`),currentFuelLevel=computed(()=>currentFuelData.value?currentFuelData.value.currentEnergy/currentFuelData.value.maxEnergy:0),canRefuel=computed(()=>currentFuelData.value?currentFuelData.value.currentEnergycanRefuel.value===!0?isFuelling.value===!0?`on`:`off`:`disabled`),canPay=computed(()=>currentFuelData.value.price>0),canStartFuelling=computed(()=>isFuelling.value===!1&&canRefuel.value===!0),canStopFuelling=computed(()=>isFuelling.value===!0),minEnergyLabel=computed(()=>`0 `+getUnitLabel(currentEnergyType.value)),maxEnergyLabel=computed(()=>currentFuelData.value?(isFuelEnergyType(currentEnergyType.value)?convertToLocalUnit(currentFuelData.value.maxEnergy,currentEnergyType.value).toFixed(2):`100`)+` `+getUnitLabel(currentEnergyType.value):``);function getUnitLabel(energyType){return isFuelEnergyType(energyType)?getLocalUnitLabel(energyType):`%`}function getLocalUnit(energyType){return energyTypesToLocalUnits.value[energyType]?energyTypesToLocalUnits.value[energyType]:`L`}let unitToLabel={gallonUS:`gal`},factorSIToLocalUnit={gallonUS:.26417};function getLocalUnitLabel(energyType){let localUnit=getLocalUnit(energyType);return localUnit&&unitToLabel[localUnit]?unitToLabel[localUnit]:`L`}function convertToLocalUnit(valueSI,energyType){let localUnit=getLocalUnit(energyType);return localUnit?valueSI*(factorSIToLocalUnit[localUnit]||1):valueSI}function convertToPricePerLocalUnit(pricePerSI,energyType){let localUnit=getLocalUnit(energyType);return localUnit?pricePerSI/(factorSIToLocalUnit[localUnit]||1):pricePerSI}function startFuelling(){Lua_default.career_modules_fuel.uiButtonStartFueling(currentEnergyType.value)}function stopFuelling(){Lua_default.career_modules_fuel.uiButtonStopFueling(currentEnergyType.value)}function changeFlowRate(newFlowRate){flowRate.value=newFlowRate,Lua_default.career_modules_fuel.onChangeFlowRate(flowRate.value)}function payPrice(){Lua_default.career_modules_fuel.payPrice()}function requestFuelingData(){Lua_default.career_modules_fuel.requestRefuelingTransactionData(),runInBrowser(()=>getMockedData(`career.initialFuelingData`).then(data=>events$3.emit(`initialFuelingData`,data)))}function cancelTransaction(){console.log(`cancelTransaction`),Lua_default.career_modules_fuel.uiCancelTransaction()}function dispose$2(){events$3.off(`initialFuelingData`),events$3.off(`updateFuelData`)}return events$3.on(`initialFuelingData`,data=>{({fuelData:fuelTanks.value,energyTypes:energyTypes.value}=data),currentEnergyType.value=energyTypes.value[0],energyTypesToLocalUnits.value=data.energyTypesToLocalUnits,factorSIToLocalUnit.value=data.factorSIToLocalUnit,gasStationName.value=data.gasStationName,fuelDiscountData.value=data.fuelDiscountData||{},Lua_default.career_modules_fuel.sendUpdateDataToUI()}),events$3.on(`updateFuelData`,data=>{fuelTanks.value.length!==0&&(fuelTanks.value[0].currentEnergy=data.fuelData[0].currentEnergy,fuelTanks.value[0].fueledEnergy=data.fuelData[0].fueledEnergy,fuelTanks.value[0].price=data.fuelData[0].price,overallPrice.value=data.overallPrice,flowRate.value=data.fuelData[0].fuelingActive===!0?1:0)}),{currentFuelData,currentFuelLevel,currentFuelType,currentEnergyType,nozzleMode,overallPrice,isFuelling,energyTypes,canPay,canStartFuelling,canStopFuelling,fuelDiscountData,showFuelTypeSettings,showAmountSettings,gasStationName,startFuelling,stopFuelling,changeFlowRate,payPrice,requestFuelingData,cancelTransaction,getUnitLabel,convertToPricePerLocalUnit,dispose:dispose$2,minEnergyLabel,maxEnergyLabel,minSlider:23,maxSlider:80,fuelOptions}});var _hoisted_1$17={class:`full`,xmlns:`http://www.w3.org/2000/svg`,"xmlns:xlink":`http://www.w3.org/1999/xlink`,x:`0`,y:`0`,viewBox:`6 0 280 280`,width:`280`,height:`280`},_hoisted_2$11={id:`glow`,x:`-40%`,y:`-40%`,width:`180%`,height:`180%`},_hoisted_3$10=[`flood-color`],_hoisted_4$7={class:`gauge-label`},_hoisted_5$6={class:`info`},DASH_ARR_LENGTH=455,GAUGE_TYPES=[`refuel`,`recharge`],GAUGE_DEFAULTS={refuel:{cssColour:`var(--bng-orange-b400)`,gradientColour:`255,102,0`,icon:icons.fuelPumpFilling},recharge:{cssColour:`var(--bng-add-blue-600)`,gradientColour:`95,157,249`,icon:icons.charging}},_sfc_main$21={__name:`FuelGauge`,props:{value:{type:Number,default:0},type:{type:String,default:`refuel`,validator:v=>GAUGE_TYPES.includes(v)||v===``},fuelling:{type:Boolean,default:!1},label:String,maxLabel:String,minLabel:String},setup(__props){window.bngVue.isProd;let props=__props,gaugeLevelStyle=computed(()=>({stroke:GAUGE_DEFAULTS[props.type].cssColour,fill:`none`,strokeDasharray:DASH_ARR_LENGTH,strokeDashoffset:DASH_ARR_LENGTH-props.value*DASH_ARR_LENGTH})),gaugeStyle=computed(()=>({background:`radial-gradient(22% 22% at 50% 53%, rgba(${GAUGE_DEFAULTS[props.type].gradientColour}, 0.76) 0%, rgba(${GAUGE_DEFAULTS[props.type].gradientColour}, 0.18) 64.06%, rgba(${GAUGE_DEFAULTS[props.type].gradientColour}, 0) 100%)`}));return(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,{class:normalizeClass({"gauge-wrapper":!0,[__props.type]:!0})},[createBaseVNode(`div`,{class:normalizeClass({"pulse-container":!0,pulsing:__props.fuelling})},[createBaseVNode(`div`,{class:`pulser`,style:normalizeStyle(gaugeStyle.value)},null,4)],2),(openBlock(),createElementBlock(`svg`,_hoisted_1$17,[createBaseVNode(`defs`,null,[createBaseVNode(`filter`,_hoisted_2$11,[createBaseVNode(`feFlood`,{"flood-color":GAUGE_DEFAULTS[__props.type].cssColour,result:`flood1`},null,8,_hoisted_3$10),_cache[0]||=createStaticVNode(``,4)])]),_cache[1]||=createBaseVNode(`path`,{class:`gauge-back`,d:`M50,210 A110,110 0 1,1 244,210`,style:{fill:`none`}},null,-1),createBaseVNode(`path`,{class:`gauge-level blur`,d:`M50,210 A110,110 0 1,1 244,210`,style:normalizeStyle(gaugeLevelStyle.value)},null,4),createBaseVNode(`path`,{class:`gauge-level`,d:`M50,210 A110,110 0 1,1 244,210`,style:normalizeStyle(gaugeLevelStyle.value)},null,4)])),createVNode(unref(bngIcon_default),{class:`icon refill-icon`,type:GAUGE_DEFAULTS[__props.type].icon,color:`#fff`},null,8,[`type`]),createBaseVNode(`div`,_hoisted_4$7,[createBaseVNode(`span`,null,toDisplayString(__props.minLabel),1),createBaseVNode(`span`,_hoisted_5$6,toDisplayString(__props.label||`\xA0`),1),createBaseVNode(`span`,null,toDisplayString(__props.maxLabel),1)])],2))}},FuelGauge_default=__plugin_vue_export_helper_default(_sfc_main$21,[[`__scopeId`,`data-v-04de51fb`]]),_hoisted_1$16={class:`fuel-type`},_sfc_main$20={__name:`FuelTypeSettings`,props:{fuelOptions:{type:Array,required:!0}},emits:[`previousClick`,`nextClick`,`fuelTypeSelect`],setup(__props,{emit:__emit}){let emit$1=__emit;return(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$16,[createVNode(unref(bngButton_default),{class:`arrow empty`,accent:unref(ACCENTS).text,"data-testid":`previous-btn`,icon:unref(icons).arrowLargeLeft,onClick:_cache[0]||=$event=>emit$1(`previousClick`)},{default:withCtx(()=>[createVNode(unref(bngBinding_default),{class:`controller`,"ui-event":`tab_l`,deviceMask:`xinput`})]),_:1},8,[`accent`,`icon`]),createVNode(unref(bngPillFilters_default),{options:__props.fuelOptions},null,8,[`options`]),createVNode(unref(bngButton_default),{class:`arrow empty`,accent:unref(ACCENTS).text,"data-testid":`next-btn`,iconRight:unref(icons).arrowLargeRight,onClick:_cache[1]||=$event=>emit$1(`nextClick`)},{default:withCtx(()=>[createVNode(unref(bngBinding_default),{class:`controller`,"ui-event":`tab_r`,deviceMask:`xinput`})]),_:1},8,[`accent`,`iconRight`])]))}},FuelTypeSettings_default=__plugin_vue_export_helper_default(_sfc_main$20,[[`__scopeId`,`data-v-bf968fb2`]]),nozzleModes={on:{color:`var(--bng-orange-b400)`,buttonEnabled:!0},off:{color:`var(--bng-black-o6)`,buttonEnabled:!0},disabled:{color:`var(--bng-black-o2)`,buttonEnabled:!1}},fuellingModes$1={fuel:{nozzleIconType:icons$1.general.fuel_nozzle},charge:{nozzleIconType:icons$1.general.recharge_connector}},_sfc_main$19={__name:`FuelNozzle`,props:{refuelType:{type:String,required:!0},nozzleMode:{type:String,default:`off`}},emits:[`triggerDown`,`triggerUp`],setup(__props,{emit:__emit}){let{showIfController}=storeToRefs(controls_default()),props=__props,emit$1=__emit,nozzleImageURL=computed(()=>`icons/${typeSettings.value.nozzleIconType}.svg`),typeSettings=computed(()=>fuellingModes$1[props.refuelType]),modeSettings=computed(()=>nozzleModes[props.nozzleMode]),nozzleClass=computed(()=>({nozzle:!0,[props.refuelType]:!0}));return(_ctx,_cache)=>(openBlock(),createBlock(unref(bngImageAsset_default),{mask:``,class:normalizeClass(nozzleClass.value),src:nozzleImageURL.value,"bg-color":modeSettings.value.color},{default:withCtx(()=>[createVNode(unref(bngButton_default),{"bng-no-nav":`true`,class:normalizeClass({empty:!0,gamepad:unref(showIfController)}),disabled:!modeSettings.value.buttonEnabled,onMousedown:_cache[0]||=$event=>emit$1(`triggerDown`),onMouseup:_cache[1]||=$event=>emit$1(`triggerUp`),accent:unref(ACCENTS).text},{default:withCtx(()=>[createVNode(unref(bngBinding_default),{action:`fuelVehicle`,deviceMask:`xinput`,disabled:!modeSettings.value.buttonEnabled,accent:unref(ACCENTS).text},null,8,[`disabled`,`accent`]),unref(showIfController)?createCommentVNode(``,!0):(openBlock(),createBlock(unref(bngIcon_default),{key:0,type:unref(icons).plus,title:`Activate`},null,8,[`type`]))]),_:1},8,[`class`,`disabled`,`accent`])]),_:1},8,[`class`,`src`,`bg-color`]))}},FuelNozzle_default=__plugin_vue_export_helper_default(_sfc_main$19,[[`__scopeId`,`data-v-3a31f67d`]]),_hoisted_1$15={class:`cost`},_hoisted_2$10={class:`price`},_hoisted_3$9={class:`per-unit`},_hoisted_4$6={class:`value`},_hoisted_5$5={class:`unit`},_sfc_main$18={__name:`FuelInfo`,props:{totalCost:{type:Number,required:!0},pricePerUnit:{type:Number,required:!0},unitLabel:{type:String,required:!0},fuelDiscountData:{type:Object,required:!1}},setup(__props){let refuelStore=useRefuelStore(),displayPrice=computed(()=>Math.floor(refuelStore.convertToPricePerLocalUnit(props.pricePerUnit,refuelStore.currentEnergyType)*100)+.9),props=__props;return(_ctx,_cache)=>(openBlock(),createElementBlock(Fragment,null,[createBaseVNode(`div`,_hoisted_1$15,[createVNode(unref(bngUnit_default),{money:__props.totalCost},null,8,[`money`]),__props.fuelDiscountData.hasFuelDiscount?(openBlock(),createBlock(insurancePerkIcon_default,{key:0,class:`perk-icon`,perkIconData:__props.fuelDiscountData.perkData},null,8,[`perkIconData`])):createCommentVNode(``,!0)]),createBaseVNode(`div`,_hoisted_2$10,[createBaseVNode(`span`,_hoisted_3$9,[createBaseVNode(`span`,_hoisted_4$6,toDisplayString(displayPrice.value),1),_cache[0]||=createBaseVNode(`span`,{class:`divider`},null,-1),createBaseVNode(`span`,_hoisted_5$5,toDisplayString(unref(refuelStore).getUnitLabel(unref(refuelStore).currentEnergyType)),1)])])],64))}},FuelInfo_default=__plugin_vue_export_helper_default(_sfc_main$18,[[`__scopeId`,`data-v-c4955aba`]]),_hoisted_1$14={class:`amount`},_hoisted_2$9={class:`slider-labels`},_hoisted_3$8={class:`amount-value`},_sfc_main$17={__name:`FuelAmountSettings`,props:{minSlider:{type:Number,default:23},maxSlider:{type:Number,default:80},unitLabel:String},setup(__props){return(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$14,[createVNode(unref(bngButton_default),{class:`top-up`,accent:`text`},{default:withCtx(()=>[createVNode(unref(bngBinding_default),{class:`controller`,"ui-event":`focus_u`,deviceMask:`xinput`}),_cache[0]||=createTextVNode(`Top-up`,-1)]),_:1}),createBaseVNode(`div`,_hoisted_2$9,[createBaseVNode(`span`,null,toDisplayString(`${__props.minSlider}${__props.unitLabel}`),1),createBaseVNode(`span`,null,toDisplayString(`${__props.maxSlider}${__props.unitLabel}`),1)]),createVNode(unref(bngSlider_default),{min:__props.minSlider,max:__props.maxSlider,onValueChanged:()=>{}},null,8,[`min`,`max`]),createBaseVNode(`div`,_hoisted_3$8,[createVNode(unref(bngButton_default),{accent:unref(ACCENTS).text,class:`empty`},{default:withCtx(()=>[createVNode(unref(bngBinding_default),{class:`controller`,"ui-event":`focus_l`,deviceMask:`xinput`})]),_:1},8,[`accent`]),createVNode(unref(bngInput_default),{class:`value`,suffix:`L`,"initial-value":`1234567`}),createVNode(unref(bngButton_default),{accent:unref(ACCENTS).text,class:`empty`},{default:withCtx(()=>[createVNode(unref(bngBinding_default),{class:`controller`,"ui-event":`focus_r`,deviceMask:`xinput`})]),_:1},8,[`accent`])])]))}},FuelAmountSettings_default=__plugin_vue_export_helper_default(_sfc_main$17,[[`__scopeId`,`data-v-9de32e0e`]]),_hoisted_1$13={class:`gauge`},_hoisted_2$8={key:0,class:`settings content`},_hoisted_3$7={class:`status-container`},fuellingModes={fuel:{title:`ui.career.refuelling.modes.fuel.title`,gaugeType:`refuel`,nozzleIconType:icons$1.general.fuel_nozzle,fuellingOngoingLabel:`ui.career.refuelling.modes.fuel.ongoing`,startLabel:`ui.career.refuelling.modes.fuel.start`,unitLabel:`L`},charge:{title:`ui.career.refuelling.modes.charge.title`,gaugeType:`recharge`,nozzleIconType:icons$1.general.recharge_connector,fuellingOngoingLabel:`ui.career.refuelling.modes.charge.ongoing`,startLabel:`ui.career.refuelling.modes.charge.start`,unitLabel:`kWh`}},_sfc_main$16={__name:`RefuelMain`,setup(__props){let{$game}=useLibStore(),refuelStore=useRefuelStore(),mainSettings=computed(()=>fuellingModes[refuelStore.currentFuelType]);onBeforeMount(()=>{refuelStore.requestFuelingData()}),onBeforeUnmount(()=>{refuelStore.cancelTransaction()}),onUnmounted(()=>{refuelStore.$dispose()});let store$1=useTasksStore();provide(`animationSettings`,{animate:!0,animateOnMount:!1,animateOnMountIntervalDelay:.2,animateOnEmptyIntervalDelay:.1,animateOnEmpty:!0,animateNextTask:!0,successCallback:playAudio});function playAudio(){$game.lua.Engine.Audio.playOnce(`AudioGui`,`event:>UI>Career>Checkbox`)}return(_ctx,_cache)=>(openBlock(),createElementBlock(Fragment,null,[unref(refuelStore).currentFuelData?(openBlock(),createBlock(unref(layoutSingle_default),{key:0},{default:withCtx(()=>[createVNode(unref(bngCard_default),{class:`refuel-card`},{buttons:withCtx(()=>[unref(refuelStore).canPay?(openBlock(),createBlock(unref(bngButton_default),{key:0,onClick:_cache[2]||=$event=>unref(refuelStore).payPrice()},{default:withCtx(()=>[..._cache[5]||=[createTextVNode(`Pay`,-1)]]),_:1})):createCommentVNode(``,!0),unref(refuelStore).canStartFuelling?(openBlock(),createBlock(unref(bngButton_default),{key:1,onClick:_cache[3]||=$event=>unref(refuelStore).startFuelling()},{default:withCtx(()=>[createTextVNode(toDisplayString(_ctx.$t(mainSettings.value.startLabel)),1)]),_:1})):unref(refuelStore).canStopFuelling?(openBlock(),createBlock(unref(bngButton_default),{key:2,onClick:_cache[4]||=$event=>unref(refuelStore).stopFuelling()},{default:withCtx(()=>[..._cache[6]||=[createTextVNode(`Stop`,-1)]]),_:1})):createCommentVNode(``,!0)]),default:withCtx(()=>[createVNode(unref(bngCardHeading_default),{type:`ribbon`},{default:withCtx(()=>[createTextVNode(toDisplayString(_ctx.$t(unref(refuelStore).gasStationName)),1)]),_:1}),createBaseVNode(`div`,_hoisted_1$13,[createVNode(FuelGauge_default,{class:`main-gauge`,fuelling:unref(refuelStore).isFuelling,type:mainSettings.value.gaugeType,value:unref(refuelStore).currentFuelLevel,label:unref(refuelStore).isFuelling?_ctx.$t(mainSettings.value.fuellingOngoingLabel):``,minLabel:unref(refuelStore).minEnergyLabel,maxLabel:unref(refuelStore).maxEnergyLabel},null,8,[`fuelling`,`type`,`value`,`label`,`minLabel`,`maxLabel`])]),createVNode(FuelNozzle_default,{"refuel-type":unref(refuelStore).currentFuelType,"nozzle-mode":unref(refuelStore).nozzleMode,onTriggerDown:_cache[0]||=$event=>unref(refuelStore).changeFlowRate(1),onTriggerUp:_cache[1]||=$event=>unref(refuelStore).changeFlowRate(0)},null,8,[`refuel-type`,`nozzle-mode`]),createVNode(FuelInfo_default,{"total-cost":unref(refuelStore).overallPrice,"price-per-unit":unref(refuelStore).currentFuelData.pricePerUnit,"unit-label":mainSettings.value.unitLabel,"fuel-discount-data":unref(refuelStore).fuelDiscountData},null,8,[`total-cost`,`price-per-unit`,`unit-label`,`fuel-discount-data`]),unref(refuelStore).showFuelTypeSettings||unref(refuelStore).showAmountSettings?(openBlock(),createElementBlock(`div`,_hoisted_2$8,[unref(refuelStore).showFuelTypeSettings?(openBlock(),createBlock(FuelTypeSettings_default,{key:0,"fuel-options":unref(refuelStore).fuelOptions},null,8,[`fuel-options`])):createCommentVNode(``,!0),unref(refuelStore).showAmountSettings?(openBlock(),createBlock(FuelAmountSettings_default,{key:1,"min-slider":unref(refuelStore).minSlider,"max-slider":unref(refuelStore).maxSlider,"unit-label":mainSettings.value.unitLabel},null,8,[`min-slider`,`max-slider`,`unit-label`])):createCommentVNode(``,!0)])):createCommentVNode(``,!0)]),_:1})]),_:1})):createCommentVNode(``,!0),createBaseVNode(`div`,_hoisted_3$7,[createVNode(unref(careerStatus_default),{class:`profileStatus`}),createVNode(unref(TaskList_default),{class:`tasklist`,header:unref(store$1).header,tasks:unref(store$1).tasks},null,8,[`header`,`tasks`])])],64))}},RefuelMain_default=__plugin_vue_export_helper_default(_sfc_main$16,[[`__scopeId`,`data-v-d87fd4e5`]]),routes_default$15=[{path:`/refueling`,name:`refueling`,component:RefuelMain_default,meta:{uiApps:{shown:!1}}}],_hoisted_1$12=[`innerHTML`],_sfc_main$15={__name:`ReleaseInfo`,setup(__props){useUINavScope(`releaseInfo`);let settings$1=useSettings(),parseDescription=descKey=>parse$1($translate.instant(descKey)),descriptionHtml=computed(()=>parseDescription(`ui.releaseInfo.description`)),onFinish=async()=>{backToMenu()},backToMenu=()=>window.bngVue.gotoAngularState(`menu.mainmenu`);return onMounted(async()=>{await settings$1.waitForData()}),(_ctx,_cache)=>withDirectives((openBlock(),createBlock(unref(WizardView_default),{title:`ui.releaseInfo.title`,preheadings:[`v.${unref(sysInfo_default).versionSimple}`],style:{"--wizard-height":`45rem`},"bng-ui-scope":`releaseInfo`,onWizardFinish:onFinish},{default:withCtx(()=>[createVNode(unref(WizardStep_default),{id:`releaseInfo`,title:`ui.releaseInfo.stepTitle`},{default:withCtx(()=>[createBaseVNode(`div`,{innerHTML:descriptionHtml.value},null,8,_hoisted_1$12)]),_:1})]),_:1},8,[`preheadings`])),[[unref(BngBlur_default)],[unref(BngOnUiNav_default),backToMenu,`menu,back`]])}},ReleaseInfo_default=_sfc_main$15,routes_default$16=[{name:`menu.release-info`,path:`/release-info`,component:ReleaseInfo_default,meta:{infoBar:{visible:!0,showSysInfo:!0},uiApps:{shown:!1}}}],_hoisted_1$11={class:`veh-debug`},_hoisted_2$7={class:`buttons`},_hoisted_3$6={class:`buttons`},_hoisted_4$5={class:`bng-short-select-item`},_hoisted_5$4={class:`label-width`},_hoisted_6$3={key:0},_hoisted_7$3={class:`parts-switch-label`},_hoisted_8$2={class:`control-row`},_hoisted_9$1={class:`control-label`},_hoisted_10={class:`control-row`},_hoisted_11={class:`control-label`},_hoisted_12={key:0},_hoisted_13={class:`control-row`},_hoisted_14={class:`control-label indented`},_hoisted_15={class:`control-group`},_hoisted_16={class:`control-row`},_hoisted_17={class:`control-label indented`},_hoisted_18={class:`control-group`},_hoisted_19={class:`control-row`},_hoisted_20={class:`control-label indented`},_hoisted_21={class:`control-row`},_hoisted_22={class:`control-label indented`},_hoisted_23={class:`control-row`},_hoisted_24={class:`control-label indented`},_hoisted_25={class:`control-group`},_hoisted_26={class:`control-row`},_hoisted_27={class:`control-label indented`},_hoisted_28={class:`control-group`},_hoisted_29={class:`control-row`},_hoisted_30={class:`control-label indented`},_hoisted_31={class:`control-group`},_hoisted_32={class:`control-row`},_hoisted_33={class:`control-label`},_hoisted_34={key:2},_hoisted_35={class:`control-row`},_hoisted_36={class:`control-label indented`},_hoisted_37={class:`control-group`},_hoisted_38={class:`control-row`},_hoisted_39={class:`control-label indented`},_hoisted_40={class:`control-group`},_hoisted_41={class:`control-row`},_hoisted_42={class:`control-label indented`},_hoisted_43={class:`control-row`},_hoisted_44={class:`control-label indented`},_hoisted_45={key:3,class:`control-row`},_hoisted_46={class:`control-label indented`},_hoisted_47={class:`control-group`},_hoisted_48={key:4,class:`control-row`},_hoisted_49={class:`control-label indented`},_hoisted_50={class:`control-row`},_hoisted_51={class:`control-label`},_hoisted_52={key:5},_hoisted_53={class:`control-row`},_hoisted_54={class:`control-label indented`},_hoisted_55={class:`control-group`},_hoisted_56={class:`control-row`},_hoisted_57={class:`control-label indented`},_hoisted_58={class:`control-group`},_hoisted_59={class:`control-row`},_hoisted_60={class:`control-label indented`},_hoisted_61={class:`control-row`},_hoisted_62={class:`control-label indented`},_hoisted_63={class:`control-row`},_hoisted_64={class:`control-label indented`},_hoisted_65={class:`control-group`},_hoisted_66={class:`control-row`},_hoisted_67={class:`control-label indented`},_hoisted_68={class:`control-group`},_hoisted_69={class:`control-row`},_hoisted_70={class:`control-label indented`},_hoisted_71={class:`control-group`},_hoisted_72={class:`control-row`},_hoisted_73={class:`control-label`},_hoisted_74={class:`control-row`},_hoisted_75={class:`control-label indented`},_hoisted_76={class:`control-group`},_hoisted_77={class:`control-row`},_hoisted_78={class:`control-label indented`},_hoisted_79={class:`control-group`},_hoisted_80={class:`control-row`},_hoisted_81={class:`control-label indented`},_hoisted_82={class:`control-row`},_hoisted_83={class:`control-label indented`},_hoisted_84={class:`control-row`},_hoisted_85={class:`control-label indented`},_hoisted_86={class:`control-group`},_hoisted_87={class:`control-row`},_hoisted_88={class:`control-label indented`},_hoisted_89={class:`control-group`},_hoisted_90={class:`control-row`},_hoisted_91={class:`control-label`},_hoisted_92={class:`control-row`},_hoisted_93={class:`control-label indented`},_hoisted_94={class:`control-group`},_hoisted_95={class:`control-row`},_hoisted_96={class:`control-label indented`},_hoisted_97={class:`control-group`},_hoisted_98={class:`control-row`},_hoisted_99={class:`control-label`},_hoisted_100={class:`control-row`},_hoisted_101={class:`control-label`},_hoisted_102={key:10,class:`control-row`},_hoisted_103={class:`control-label indented`},_hoisted_104={class:`control-group`},_hoisted_105={class:`control-row`},_hoisted_106={class:`control-label`},_hoisted_107={key:11,class:`control-row`},_hoisted_108={class:`control-label indented`},_hoisted_109={class:`control-group`},_hoisted_110={class:`control-row`},_hoisted_111={class:`control-label`},_hoisted_112={class:`control-row`},_hoisted_113={class:`control-label`},_hoisted_114={key:12,class:`control-row`},_hoisted_115={class:`control-label indented`},_hoisted_116={class:`control-group`},_hoisted_117={key:13,class:`control-row`},_hoisted_118={class:`control-label`},_hoisted_119={class:`mesh-visibility`},_hoisted_120={class:`control-row`},_hoisted_121={class:`control-label`},_hoisted_122={class:`mesh-buttons`},_hoisted_123={class:`buttons`},_sfc_main$14={__name:`Debug`,setup(__props){useUINavBlocker().blockOnly([`context`]);let{lua,api:api$1}=useBridge(),events$3=useEvents(),state=reactive({}),stateNoReset=reactive({vehicle:{parts:[],partNameToIdx:{},partsSelected:{},partsSelectedIdxs:[]}}),partsState=reactive({partsSorted:[],partsHighlightedIdxs:[]}),partsFiltered=computed(()=>{let res=partsState.partsSorted;return Array.isArray(res)?(partsSelectedSearchTerm.value&&(res=res.filter(part=>part.includes(partsSelectedSearchTerm.value))),res.map(p$1=>{let segments=p$1.split(`/`);return{label:segments[segments.length-1],reversePath:segments.slice(0,-1).reverse().join(`\\`),value:p$1,selected:Array.isArray(partsState.partsHighlightedIdxs)&&partsState.partsHighlightedIdxs.includes(partsState.partsSorted.indexOf(p$1)+1)}})):[]}),shipping=computed(()=>window.beamng&&window.beamng.shipping),geState=reactive({physicsEnabled:!0,debugSpawnEnabled:!1}),partsSelectedSearchTerm=ref(``),disableVehicleButtons=ref(!1),controls$1={vehicle:{buttonGroup_1:[{label:`ui.debug.vehicle.loadDefault`,action:()=>lua.core_vehicles.loadDefault()},{label:`ui.debug.vehicle.spawnNew`,action:()=>lua.core_vehicles.spawnDefault()},{label:`ui.debug.vehicle.removeCurrent`,action:()=>lua.core_vehicles.removeCurrent()},{label:`ui.debug.vehicle.cloneCurrent`,action:()=>lua.core_vehicles.cloneCurrent()},{label:`ui.debug.vehicle.removeAll`,action:()=>lua.core_vehicles.removeAll()},{label:`ui.debug.vehicle.removeOthers`,action:()=>lua.core_vehicles.removeAllExceptCurrent()},{label:`ui.debug.vehicle.resetAll`,action:()=>lua.resetGameplay(-1)},{label:`ui.debug.vehicle.reloadAll`,action:()=>lua.core_vehicle_manager.reloadAllVehicles()}],toggleGroup_1:[{label:`ui.debug.activatePhysics`,key:`physicsEnabled`,onChange:()=>lua.simTimeAuthority.togglePause()},{label:`ui.debug.debugSpawnEnabled`,key:`debugSpawnEnabled`,onChange:()=>lua.core_vehicle_manager.toggleDebug()}]},jbeamvis:{buttonGroup_1:[{label:`ui.debug.vehicle.toggleVis`,action:()=>api$1.activeObjectLua(`bdebug.toggleEnabled()`)},{label:`ui.debug.vehicle.clearSettings`,action:()=>api$1.activeObjectLua(`bdebug.resetModes()`)}],meshVisButtonGroup:[{label:`0%`,action:()=>lua.core_vehicles.setMeshVisibility(0)},{label:`25%`,action:()=>lua.core_vehicles.setMeshVisibility(.25)},{label:`50%`,action:()=>lua.core_vehicles.setMeshVisibility(.5)},{label:`75%`,action:()=>lua.core_vehicles.setMeshVisibility(.75)},{label:`100%`,action:()=>lua.core_vehicles.setMeshVisibility(1)}]},terrain:{buttonGroup_1:[{label:`ui.debug.terrain.groundmodel`,action:()=>api$1.engineLua(`extensions.load("util_groundModelDebug") util_groundModelDebug.openWindow()`)}]}};onMounted(async()=>{geState.physicsEnabled=!await lua.simTimeAuthority.getPause(),geState.debugSpawnEnabled=await lua.core_vehicle_manager.getDebug(),api$1.activeObjectLua(`bdebug.requestState()`),lua.core_gamestate.requestGameState(),lua.extensions.core_vehicle_partmgmt.sendPartsSelectorStateToUI()});let applyState=(notSendBack=!1)=>{notSendBack=!!notSendBack,api$1.activeObjectLua(`bdebug.setState(${api$1.serializeToLua(state)}, ${api$1.serializeToLua(stateNoReset)}, ${notSendBack})`)},partsSelectedChanged=(part,value)=>{Array.isArray(partsState.partsHighlightedIdxs)||(partsState.partsHighlightedIdxs=[]);let idx=partsState.partsSorted.indexOf(part)+1,idxInArray=partsState.partsHighlightedIdxs.indexOf(idx);value&&idxInArray===-1?partsState.partsHighlightedIdxs.push(idx):!value&&idxInArray!==-1&&partsState.partsHighlightedIdxs.splice(idxInArray,1),applyState(!0),lua.extensions.core_vehicle_partmgmt.partsSelectorChanged(partsState)},partsSelectedChecked=()=>partsState.partsHighlightedIdxs.length===partsState.partsSorted.length,partsSelectedIndeterminate=()=>partsState.partsHighlightedIdxs.length!==0&&partsState.partsHighlightedIdxs.length!==partsState.partsSorted.length,partsSelectedClicked=()=>{partsState.partsHighlightedIdxs.length===partsState.partsSorted.length?partsState.partsHighlightedIdxs=[]:partsState.partsHighlightedIdxs=Array.from({length:partsState.partsSorted.length},(_,i)=>i+1),applyState(),lua.extensions.core_vehicle_partmgmt.partsSelectorChanged(partsState)},selectAllParts=computed({get:()=>partsSelectedChecked(),set:()=>partsSelectedClicked()}),beamTextModeItems=computed(()=>state.vehicle?.beamTextModes?state.vehicle.beamTextModes.map((mode,index)=>({value:index+1,label:mode.name?$translate.instant(`vehicle.bdebug.beamTextMode.${mode.name}`):``})):[]),beamVisModeItems=computed(()=>state.vehicle?.beamVisModes?state.vehicle.beamVisModes.map((mode,index)=>({value:index+1,label:mode.name?$translate.instant(`vehicle.bdebug.beamVisMode.${mode.name}`):``})):[]),currentBeamVisMode=computed(()=>state.vehicle?.beamVisModes?state.vehicle.beamVisModes[state.vehicle.beamVisMode-1]:null),nodeTextModeItems=computed(()=>state.vehicle?.nodeTextModes?state.vehicle.nodeTextModes.map((mode,index)=>({value:index+1,label:mode.name?$translate.instant(`vehicle.bdebug.nodeTextMode.${mode.name}`):``})):[]),currentNodeTextMode=computed(()=>state.vehicle?.nodeTextModes?state.vehicle.nodeTextModes[state.vehicle.nodeTextMode-1]:null),nodeVisModeItems=computed(()=>state.vehicle?.nodeVisModes?state.vehicle.nodeVisModes.map((mode,index)=>({value:index+1,label:mode.name?$translate.instant(`vehicle.bdebug.nodeVisMode.${mode.name}`):``})):[]),currentNodeVisMode=computed(()=>state.vehicle?.nodeVisModes?state.vehicle.nodeVisModes[state.vehicle.nodeVisMode-1]:null),torsionBarVisModeItems=computed(()=>state.vehicle?.torsionBarVisModes?state.vehicle.torsionBarVisModes.map((mode,index)=>({value:index+1,label:mode.name?$translate.instant(`vehicle.bdebug.torsionBarVisMode.${mode.name}`):``})):[]),currentTorsionBarVisMode=computed(()=>state.vehicle?.torsionBarVisModes?state.vehicle.torsionBarVisModes[state.vehicle.torsionBarVisMode-1]:null),railsSlideNodesModeItems=computed(()=>state.vehicle?.railsSlideNodesVisModes?state.vehicle.railsSlideNodesVisModes.map((mode,index)=>({value:index+1,label:mode.name?$translate.instant(`vehicle.bdebug.railsSlideNodesVisMode.${mode.name}`):``})):[]),cogModeItems=computed(()=>state.vehicle?.cogModes?state.vehicle.cogModes.map((mode,index)=>({value:index+1,label:mode.name?$translate.instant(`vehicle.bdebug.cogMode.${mode.name}`):``})):[]),collisionTriangleModeItems=computed(()=>state.vehicle?.collisionTriangleVisModes?state.vehicle.collisionTriangleVisModes.map((mode,index)=>({value:index+1,label:mode.name?$translate.instant(`vehicle.bdebug.collisionTriangleVisMode.${mode.name}`):``})):[]),aeroModeItems=computed(()=>state.vehicle?.aeroModes?state.vehicle.aeroModes.map((mode,index)=>({value:index+1,label:mode.name?$translate.instant(`vehicle.bdebug.aeroMode.${mode.name}`):``})):[]);return events$3.on(`BdebugUpdate`,(debugState,newStateNoReset)=>{Object.assign(state,debugState),Object.assign(stateNoReset,newStateNoReset)}),events$3.on(`PartsSelectorUpdate`,state$1=>{Object.assign(partsState,state$1)}),events$3.on(`VehicleFocusChanged`,()=>{api$1.activeObjectLua(`bdebug.requestState()`),lua.extensions.core_vehicle_partmgmt.sendPartsSelectorStateToUI()}),events$3.on(`physicsStateChanged`,state$1=>geState.physicsEnabled=!!state$1),events$3.on(`debugSpawnChanged`,state$1=>geState.debugSpawnEnabled=!!state$1),events$3.on(`GameStateUpdate`,gamestate=>disableVehicleButtons.value=gamestate.state.toLowerCase().indexOf(`scenario`)>-1),(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$11,[createBaseVNode(`h3`,null,toDisplayString(_ctx.$tt(`ui.debug.vehicle`)),1),(openBlock(!0),createElementBlock(Fragment,null,renderList(controls$1.vehicle.toggleGroup_1,toggle=>(openBlock(),createElementBlock(`div`,{key:toggle.key},[createVNode(unref(bngSwitch_default),{modelValue:geState[toggle.key],"onUpdate:modelValue":$event=>geState[toggle.key]=$event,onValueChanged:$event=>toggle.onChange()},{default:withCtx(()=>[createTextVNode(toDisplayString(_ctx.$tt(toggle.label)),1)]),_:2},1032,[`modelValue`,`onUpdate:modelValue`,`onValueChanged`])]))),128)),createBaseVNode(`div`,_hoisted_2$7,[(openBlock(!0),createElementBlock(Fragment,null,renderList(controls$1.vehicle.buttonGroup_1,btn=>(openBlock(),createBlock(unref(bngButton_default),{key:btn.label,onClick:$event=>btn.action(),disabled:disableVehicleButtons.value,accent:unref(ACCENTS).secondary},{default:withCtx(()=>[createTextVNode(toDisplayString(_ctx.$tt(btn.label)),1)]),_:2},1032,[`onClick`,`disabled`,`accent`]))),128))]),_cache[74]||=createBaseVNode(`hr`,null,null,-1),createBaseVNode(`h4`,null,toDisplayString(_ctx.$tt(`ui.debug.vehicle.jbeamVis`)),1),createBaseVNode(`div`,_hoisted_3$6,[(openBlock(!0),createElementBlock(Fragment,null,renderList(controls$1.jbeamvis.buttonGroup_1,btn=>(openBlock(),createBlock(unref(bngButton_default),{key:btn.label,onClick:$event=>btn.action(),accent:unref(ACCENTS).secondary},{default:withCtx(()=>[createTextVNode(toDisplayString(_ctx.$tt(btn.label)),1)]),_:2},1032,[`onClick`,`accent`]))),128))]),createBaseVNode(`div`,_hoisted_4$5,[createBaseVNode(`span`,_hoisted_5$4,toDisplayString(_ctx.$tt(`ui.debug.vehicle.partsSelected`)),1),createVNode(unref(bngDropdownContainer_default),{class:`bng-select-fullwidth dropdown-width`},{default:withCtx(()=>[createVNode(unref(bngList_default),{layout:unref(LIST_LAYOUTS).LIST,"target-width":31},{default:withCtx(()=>[createVNode(unref(bngInput_default),{modelValue:partsSelectedSearchTerm.value,"onUpdate:modelValue":_cache[0]||=$event=>partsSelectedSearchTerm.value=$event,modelModifiers:{trim:!0},"floating-label":_ctx.$t(`ui.debug.vehicle.partsSelectedSearchText`)},null,8,[`modelValue`,`floating-label`]),partsFiltered.value&&partsFiltered.value.length>0?(openBlock(),createElementBlock(`div`,_hoisted_6$3,[(openBlock(!0),createElementBlock(Fragment,null,renderList(partsFiltered.value,part=>withDirectives((openBlock(),createBlock(unref(bngSwitch_default),{"model-value":part.selected,key:part.value,"label-alignment":unref(LABEL_ALIGNMENTS).START,inline:!1,class:`parts-switch`,onChange:value=>partsSelectedChanged(part.value,value)},{default:withCtx(()=>[createBaseVNode(`span`,_hoisted_7$3,[createBaseVNode(`strong`,null,toDisplayString(part.label),1),createTextVNode(` `+toDisplayString(part.reversePath?`\\`+part.reversePath:``),1)])]),_:2},1032,[`model-value`,`label-alignment`,`onChange`])),[[unref(BngTooltip_default),part.label+` \\ `+part.reversePath,`right`]])),128))])):createCommentVNode(``,!0)]),_:1},8,[`layout`])]),_:1}),createVNode(unref(bngSwitch_default),{modelValue:selectAllParts.value,"onUpdate:modelValue":_cache[1]||=$event=>selectAllParts.value=$event,class:normalizeClass({"switch-indeterminate":partsSelectedIndeterminate(),"switch-width":!0}),onOnClicked:partsSelectedClicked},null,8,[`modelValue`,`class`])]),state.vehicle?(openBlock(),createElementBlock(Fragment,{key:0},[createBaseVNode(`div`,_hoisted_8$2,[createBaseVNode(`span`,_hoisted_9$1,toDisplayString(_ctx.$tt(`ui.debug.vehicle.beamText`)),1),createVNode(unref(bngDropdown_default),{modelValue:state.vehicle.beamTextMode,"onUpdate:modelValue":_cache[2]||=$event=>state.vehicle.beamTextMode=$event,items:beamTextModeItems.value,onValueChanged:applyState,class:`control-input`},null,8,[`modelValue`,`items`])]),createBaseVNode(`div`,_hoisted_10,[createBaseVNode(`span`,_hoisted_11,toDisplayString(_ctx.$tt(`ui.debug.vehicle.beamVis`)),1),createVNode(unref(bngDropdown_default),{modelValue:state.vehicle.beamVisMode,"onUpdate:modelValue":_cache[3]||=$event=>state.vehicle.beamVisMode=$event,items:beamVisModeItems.value,onValueChanged:applyState,class:`control-input`},null,8,[`modelValue`,`items`])]),currentBeamVisMode.value&¤tBeamVisMode.value.usesRange?(openBlock(),createElementBlock(`div`,_hoisted_12,[createBaseVNode(`div`,_hoisted_13,[createBaseVNode(`span`,_hoisted_14,toDisplayString(_ctx.$tt(`ui.debug.vehicle.visRangeMin`)),1),createBaseVNode(`div`,_hoisted_15,[createVNode(unref(bngSlider_default),{modelValue:currentBeamVisMode.value.rangeMin,"onUpdate:modelValue":_cache[4]||=$event=>currentBeamVisMode.value.rangeMin=$event,min:currentBeamVisMode.value.rangeMinCap,max:currentBeamVisMode.value.rangeMaxCap,step:(currentBeamVisMode.value.rangeMaxCap-currentBeamVisMode.value.rangeMinCap)/100,onValueChanged:applyState},null,8,[`modelValue`,`min`,`max`,`step`]),createVNode(unref(bngInput_default),{modelValue:currentBeamVisMode.value.rangeMin,"onUpdate:modelValue":_cache[5]||=$event=>currentBeamVisMode.value.rangeMin=$event,type:`number`,min:currentBeamVisMode.value.rangeMinCap,max:currentBeamVisMode.value.rangeMaxCap,step:(currentBeamVisMode.value.rangeMaxCap-currentBeamVisMode.value.rangeMinCap)/1e3,onValueChanged:applyState},null,8,[`modelValue`,`min`,`max`,`step`]),createVNode(unref(bngSwitch_default),{modelValue:currentBeamVisMode.value.rangeMinEnabled,"onUpdate:modelValue":_cache[6]||=$event=>currentBeamVisMode.value.rangeMinEnabled=$event,onValueChanged:applyState},null,8,[`modelValue`])])]),createBaseVNode(`div`,_hoisted_16,[createBaseVNode(`span`,_hoisted_17,toDisplayString(_ctx.$tt(`ui.debug.vehicle.visRangeMax`)),1),createBaseVNode(`div`,_hoisted_18,[createVNode(unref(bngSlider_default),{modelValue:currentBeamVisMode.value.rangeMax,"onUpdate:modelValue":_cache[7]||=$event=>currentBeamVisMode.value.rangeMax=$event,min:currentBeamVisMode.value.rangeMinCap,max:currentBeamVisMode.value.rangeMaxCap,step:(currentBeamVisMode.value.rangeMaxCap-currentBeamVisMode.value.rangeMinCap)/100,onValueChanged:applyState},null,8,[`modelValue`,`min`,`max`,`step`]),createVNode(unref(bngInput_default),{modelValue:currentBeamVisMode.value.rangeMax,"onUpdate:modelValue":_cache[8]||=$event=>currentBeamVisMode.value.rangeMax=$event,type:`number`,min:currentBeamVisMode.value.rangeMinCap,max:currentBeamVisMode.value.rangeMaxCap,step:(currentBeamVisMode.value.rangeMaxCap-currentBeamVisMode.value.rangeMinCap)/1e3,onValueChanged:applyState},null,8,[`modelValue`,`min`,`max`,`step`]),createVNode(unref(bngSwitch_default),{modelValue:currentBeamVisMode.value.rangeMaxEnabled,"onUpdate:modelValue":_cache[9]||=$event=>currentBeamVisMode.value.rangeMaxEnabled=$event,onValueChanged:applyState},null,8,[`modelValue`])])]),createBaseVNode(`div`,_hoisted_19,[createBaseVNode(`span`,_hoisted_20,toDisplayString(_ctx.$tt(`ui.debug.vehicle.useInclusiveRange`)),1),createVNode(unref(bngSwitch_default),{modelValue:currentBeamVisMode.value.usesInclusiveRange,"onUpdate:modelValue":_cache[10]||=$event=>currentBeamVisMode.value.usesInclusiveRange=$event,onValueChanged:applyState},null,8,[`modelValue`])]),createBaseVNode(`div`,_hoisted_21,[createBaseVNode(`span`,_hoisted_22,toDisplayString(_ctx.$tt(`ui.debug.vehicle.showInf`)),1),createVNode(unref(bngSwitch_default),{modelValue:currentBeamVisMode.value.showInfinity,"onUpdate:modelValue":_cache[11]||=$event=>currentBeamVisMode.value.showInfinity=$event,onValueChanged:applyState},null,8,[`modelValue`])])])):createCommentVNode(``,!0),state.vehicle.beamVisMode===1?createCommentVNode(``,!0):(openBlock(),createElementBlock(Fragment,{key:1},[createBaseVNode(`div`,_hoisted_23,[createBaseVNode(`span`,_hoisted_24,toDisplayString(_ctx.$tt(`ui.debug.vehicle.showHighlighted`)),1),createBaseVNode(`div`,_hoisted_25,[createVNode(unref(bngSwitch_default),{modelValue:state.vehicle.beamVisShowHighlighted,"onUpdate:modelValue":_cache[12]||=$event=>state.vehicle.beamVisShowHighlighted=$event,disabled:state.vehicle.beamVisMode===3,onValueChanged:applyState},null,8,[`modelValue`,`disabled`])])]),createBaseVNode(`div`,_hoisted_26,[createBaseVNode(`span`,_hoisted_27,toDisplayString(_ctx.$tt(`ui.debug.vehicle.width`)),1),createBaseVNode(`div`,_hoisted_28,[createVNode(unref(bngSlider_default),{modelValue:state.vehicle.beamVisWidthScale,"onUpdate:modelValue":_cache[13]||=$event=>state.vehicle.beamVisWidthScale=$event,min:.1,max:5,step:.1,onValueChanged:applyState},null,8,[`modelValue`]),createVNode(unref(bngInput_default),{modelValue:state.vehicle.beamVisWidthScale,"onUpdate:modelValue":_cache[14]||=$event=>state.vehicle.beamVisWidthScale=$event,type:`number`,min:.1,max:5,step:.1,onValueChanged:applyState},null,8,[`modelValue`])])]),createBaseVNode(`div`,_hoisted_29,[createBaseVNode(`span`,_hoisted_30,toDisplayString(_ctx.$tt(`ui.debug.vehicle.transparency`)),1),createBaseVNode(`div`,_hoisted_31,[createVNode(unref(bngSlider_default),{modelValue:state.vehicle.beamVisAlpha,"onUpdate:modelValue":_cache[15]||=$event=>state.vehicle.beamVisAlpha=$event,min:0,max:1,step:.01,onValueChanged:applyState},null,8,[`modelValue`]),createVNode(unref(bngInput_default),{modelValue:state.vehicle.beamVisAlpha,"onUpdate:modelValue":_cache[16]||=$event=>state.vehicle.beamVisAlpha=$event,type:`number`,min:0,max:1,step:.01,onValueChanged:applyState},null,8,[`modelValue`])])])],64)),createBaseVNode(`div`,_hoisted_32,[createBaseVNode(`span`,_hoisted_33,toDisplayString(_ctx.$tt(`ui.debug.vehicle.nodeText`)),1),createVNode(unref(bngDropdown_default),{modelValue:state.vehicle.nodeTextMode,"onUpdate:modelValue":_cache[17]||=$event=>state.vehicle.nodeTextMode=$event,items:nodeTextModeItems.value,onValueChanged:applyState,class:`control-input`},null,8,[`modelValue`,`items`])]),currentNodeTextMode.value&¤tNodeTextMode.value.usesRange?(openBlock(),createElementBlock(`div`,_hoisted_34,[createBaseVNode(`div`,_hoisted_35,[createBaseVNode(`span`,_hoisted_36,toDisplayString(_ctx.$tt(`ui.debug.vehicle.visRangeMin`)),1),createBaseVNode(`div`,_hoisted_37,[createVNode(unref(bngSlider_default),{modelValue:currentNodeTextMode.value.rangeMin,"onUpdate:modelValue":_cache[18]||=$event=>currentNodeTextMode.value.rangeMin=$event,min:currentNodeTextMode.value.rangeMinCap,max:currentNodeTextMode.value.rangeMaxCap,step:(currentNodeTextMode.value.rangeMaxCap-currentNodeTextMode.value.rangeMinCap)/100,onValueChanged:applyState},null,8,[`modelValue`,`min`,`max`,`step`]),createVNode(unref(bngInput_default),{modelValue:currentNodeTextMode.value.rangeMin,"onUpdate:modelValue":_cache[19]||=$event=>currentNodeTextMode.value.rangeMin=$event,type:`number`,min:currentNodeTextMode.value.rangeMinCap,max:currentNodeTextMode.value.rangeMaxCap,step:(currentNodeTextMode.value.rangeMaxCap-currentNodeTextMode.value.rangeMinCap)/1e3,onValueChanged:applyState},null,8,[`modelValue`,`min`,`max`,`step`]),createVNode(unref(bngSwitch_default),{modelValue:currentNodeTextMode.value.rangeMinEnabled,"onUpdate:modelValue":_cache[20]||=$event=>currentNodeTextMode.value.rangeMinEnabled=$event,onValueChanged:applyState},null,8,[`modelValue`])])]),createBaseVNode(`div`,_hoisted_38,[createBaseVNode(`span`,_hoisted_39,toDisplayString(_ctx.$tt(`ui.debug.vehicle.visRangeMax`)),1),createBaseVNode(`div`,_hoisted_40,[createVNode(unref(bngSlider_default),{modelValue:currentNodeTextMode.value.rangeMax,"onUpdate:modelValue":_cache[21]||=$event=>currentNodeTextMode.value.rangeMax=$event,min:currentNodeTextMode.value.rangeMinCap,max:currentNodeTextMode.value.rangeMaxCap,step:(currentNodeTextMode.value.rangeMaxCap-currentNodeTextMode.value.rangeMinCap)/100,onValueChanged:applyState},null,8,[`modelValue`,`min`,`max`,`step`]),createVNode(unref(bngInput_default),{modelValue:currentNodeTextMode.value.rangeMax,"onUpdate:modelValue":_cache[22]||=$event=>currentNodeTextMode.value.rangeMax=$event,type:`number`,min:currentNodeTextMode.value.rangeMinCap,max:currentNodeTextMode.value.rangeMaxCap,step:(currentNodeTextMode.value.rangeMaxCap-currentNodeTextMode.value.rangeMinCap)/1e3,onValueChanged:applyState},null,8,[`modelValue`,`min`,`max`,`step`]),createVNode(unref(bngSwitch_default),{modelValue:currentNodeTextMode.value.rangeMaxEnabled,"onUpdate:modelValue":_cache[23]||=$event=>currentNodeTextMode.value.rangeMaxEnabled=$event,onValueChanged:applyState},null,8,[`modelValue`])])]),createBaseVNode(`div`,_hoisted_41,[createBaseVNode(`span`,_hoisted_42,toDisplayString(_ctx.$tt(`ui.debug.vehicle.useInclusiveRange`)),1),createVNode(unref(bngSwitch_default),{modelValue:currentNodeTextMode.value.usesInclusiveRange,"onUpdate:modelValue":_cache[24]||=$event=>currentNodeTextMode.value.usesInclusiveRange=$event,onValueChanged:applyState},null,8,[`modelValue`])]),createBaseVNode(`div`,_hoisted_43,[createBaseVNode(`span`,_hoisted_44,toDisplayString(_ctx.$tt(`ui.debug.vehicle.showInf`)),1),createVNode(unref(bngSwitch_default),{modelValue:currentNodeTextMode.value.showInfinity,"onUpdate:modelValue":_cache[25]||=$event=>currentNodeTextMode.value.showInfinity=$event,onValueChanged:applyState},null,8,[`modelValue`])])])):createCommentVNode(``,!0),state.vehicle.nodeTextMode===1?createCommentVNode(``,!0):(openBlock(),createElementBlock(`div`,_hoisted_45,[createBaseVNode(`span`,_hoisted_46,toDisplayString(_ctx.$tt(`ui.debug.vehicle.maxDist`)),1),createBaseVNode(`div`,_hoisted_47,[createVNode(unref(bngSlider_default),{modelValue:state.vehicle.nodeTextMaxDist,"onUpdate:modelValue":_cache[26]||=$event=>state.vehicle.nodeTextMaxDist=$event,min:.1,max:state.vehicle.nodeTextMaxDistCap,step:.1,onValueChanged:applyState},null,8,[`modelValue`,`max`]),createVNode(unref(bngInput_default),{modelValue:state.vehicle.nodeTextMaxDist,"onUpdate:modelValue":_cache[27]||=$event=>state.vehicle.nodeTextMaxDist=$event,type:`number`,min:.1,max:state.vehicle.nodeTextMaxDistCap,step:.1,onValueChanged:applyState},null,8,[`modelValue`,`max`])])])),state.vehicle.nodeTextMode===1?createCommentVNode(``,!0):(openBlock(),createElementBlock(`div`,_hoisted_48,[createBaseVNode(`span`,_hoisted_49,toDisplayString(_ctx.$tt(`ui.debug.vehicle.showWheels`)),1),createVNode(unref(bngSwitch_default),{modelValue:state.vehicle.nodeTextShowWheels,"onUpdate:modelValue":_cache[28]||=$event=>state.vehicle.nodeTextShowWheels=$event,onValueChanged:applyState},null,8,[`modelValue`])])),createBaseVNode(`div`,_hoisted_50,[createBaseVNode(`span`,_hoisted_51,toDisplayString(_ctx.$tt(`ui.debug.vehicle.nodeVis`)),1),createVNode(unref(bngDropdown_default),{modelValue:state.vehicle.nodeVisMode,"onUpdate:modelValue":_cache[29]||=$event=>state.vehicle.nodeVisMode=$event,items:nodeVisModeItems.value,onValueChanged:applyState,class:`control-input`},null,8,[`modelValue`,`items`])]),currentNodeVisMode.value&¤tNodeVisMode.value.usesRange?(openBlock(),createElementBlock(`div`,_hoisted_52,[createBaseVNode(`div`,_hoisted_53,[createBaseVNode(`span`,_hoisted_54,toDisplayString(_ctx.$tt(`ui.debug.vehicle.visRangeMin`)),1),createBaseVNode(`div`,_hoisted_55,[createVNode(unref(bngSlider_default),{modelValue:currentNodeVisMode.value.rangeMin,"onUpdate:modelValue":_cache[30]||=$event=>currentNodeVisMode.value.rangeMin=$event,min:currentNodeVisMode.value.rangeMinCap,max:currentNodeVisMode.value.rangeMaxCap,step:(currentNodeVisMode.value.rangeMaxCap-currentNodeVisMode.value.rangeMinCap)/100,onValueChanged:applyState},null,8,[`modelValue`,`min`,`max`,`step`]),createVNode(unref(bngInput_default),{modelValue:currentNodeVisMode.value.rangeMin,"onUpdate:modelValue":_cache[31]||=$event=>currentNodeVisMode.value.rangeMin=$event,type:`number`,min:currentNodeVisMode.value.rangeMinCap,max:currentNodeVisMode.value.rangeMaxCap,step:(currentNodeVisMode.value.rangeMaxCap-currentNodeVisMode.value.rangeMinCap)/1e3,onValueChanged:applyState},null,8,[`modelValue`,`min`,`max`,`step`]),createVNode(unref(bngSwitch_default),{modelValue:currentNodeVisMode.value.rangeMinEnabled,"onUpdate:modelValue":_cache[32]||=$event=>currentNodeVisMode.value.rangeMinEnabled=$event,onValueChanged:applyState},null,8,[`modelValue`])])]),createBaseVNode(`div`,_hoisted_56,[createBaseVNode(`span`,_hoisted_57,toDisplayString(_ctx.$tt(`ui.debug.vehicle.visRangeMax`)),1),createBaseVNode(`div`,_hoisted_58,[createVNode(unref(bngSlider_default),{modelValue:currentNodeVisMode.value.rangeMax,"onUpdate:modelValue":_cache[33]||=$event=>currentNodeVisMode.value.rangeMax=$event,min:currentNodeVisMode.value.rangeMinCap,max:currentNodeVisMode.value.rangeMaxCap,step:(currentNodeVisMode.value.rangeMaxCap-currentNodeVisMode.value.rangeMinCap)/100,onValueChanged:applyState},null,8,[`modelValue`,`min`,`max`,`step`]),createVNode(unref(bngInput_default),{modelValue:currentNodeVisMode.value.rangeMax,"onUpdate:modelValue":_cache[34]||=$event=>currentNodeVisMode.value.rangeMax=$event,type:`number`,min:currentNodeVisMode.value.rangeMinCap,max:currentNodeVisMode.value.rangeMaxCap,step:(currentNodeVisMode.value.rangeMaxCap-currentNodeVisMode.value.rangeMinCap)/1e3,onValueChanged:applyState},null,8,[`modelValue`,`min`,`max`,`step`]),createVNode(unref(bngSwitch_default),{modelValue:currentNodeVisMode.value.rangeMaxEnabled,"onUpdate:modelValue":_cache[35]||=$event=>currentNodeVisMode.value.rangeMaxEnabled=$event,onValueChanged:applyState},null,8,[`modelValue`])])]),createBaseVNode(`div`,_hoisted_59,[createBaseVNode(`span`,_hoisted_60,toDisplayString(_ctx.$tt(`ui.debug.vehicle.useInclusiveRange`)),1),createVNode(unref(bngSwitch_default),{modelValue:currentNodeVisMode.value.usesInclusiveRange,"onUpdate:modelValue":_cache[36]||=$event=>currentNodeVisMode.value.usesInclusiveRange=$event,onValueChanged:applyState},null,8,[`modelValue`])]),createBaseVNode(`div`,_hoisted_61,[createBaseVNode(`span`,_hoisted_62,toDisplayString(_ctx.$tt(`ui.debug.vehicle.showInf`)),1),createVNode(unref(bngSwitch_default),{modelValue:currentNodeVisMode.value.showInfinity,"onUpdate:modelValue":_cache[37]||=$event=>currentNodeVisMode.value.showInfinity=$event,onValueChanged:applyState},null,8,[`modelValue`])])])):createCommentVNode(``,!0),state.vehicle.nodeVisMode===1?createCommentVNode(``,!0):(openBlock(),createElementBlock(Fragment,{key:6},[createBaseVNode(`div`,_hoisted_63,[createBaseVNode(`span`,_hoisted_64,toDisplayString(_ctx.$tt(`ui.debug.vehicle.showHighlighted`)),1),createBaseVNode(`div`,_hoisted_65,[createVNode(unref(bngSwitch_default),{modelValue:state.vehicle.nodeVisShowHighlighted,"onUpdate:modelValue":_cache[38]||=$event=>state.vehicle.nodeVisShowHighlighted=$event,disabled:state.vehicle.nodeVisMode===3,onValueChanged:applyState},null,8,[`modelValue`,`disabled`])])]),createBaseVNode(`div`,_hoisted_66,[createBaseVNode(`span`,_hoisted_67,toDisplayString(_ctx.$tt(`ui.debug.vehicle.width`)),1),createBaseVNode(`div`,_hoisted_68,[createVNode(unref(bngSlider_default),{modelValue:state.vehicle.nodeVisWidthScale,"onUpdate:modelValue":_cache[39]||=$event=>state.vehicle.nodeVisWidthScale=$event,min:.3,max:5,step:.1,onValueChanged:applyState},null,8,[`modelValue`]),createVNode(unref(bngInput_default),{modelValue:state.vehicle.nodeVisWidthScale,"onUpdate:modelValue":_cache[40]||=$event=>state.vehicle.nodeVisWidthScale=$event,type:`number`,min:.3,max:5,step:.1,onValueChanged:applyState},null,8,[`modelValue`])])]),createBaseVNode(`div`,_hoisted_69,[createBaseVNode(`span`,_hoisted_70,toDisplayString(_ctx.$tt(`ui.debug.vehicle.transparency`)),1),createBaseVNode(`div`,_hoisted_71,[createVNode(unref(bngSlider_default),{modelValue:state.vehicle.nodeVisAlpha,"onUpdate:modelValue":_cache[41]||=$event=>state.vehicle.nodeVisAlpha=$event,min:0,max:1,step:.01,onValueChanged:applyState},null,8,[`modelValue`]),createVNode(unref(bngInput_default),{modelValue:state.vehicle.nodeVisAlpha,"onUpdate:modelValue":_cache[42]||=$event=>state.vehicle.nodeVisAlpha=$event,type:`number`,min:0,max:1,step:.01,onValueChanged:applyState},null,8,[`modelValue`])])])],64)),createBaseVNode(`div`,_hoisted_72,[createBaseVNode(`span`,_hoisted_73,toDisplayString(_ctx.$tt(`ui.debug.vehicle.torsionBarVis`)),1),createVNode(unref(bngDropdown_default),{modelValue:state.vehicle.torsionBarVisMode,"onUpdate:modelValue":_cache[43]||=$event=>state.vehicle.torsionBarVisMode=$event,items:torsionBarVisModeItems.value,onValueChanged:_cache[44]||=value=>{console.log(`change triggered`,value),applyState()},class:`control-input`},null,8,[`modelValue`,`items`])]),currentTorsionBarVisMode.value?.usesRange?(openBlock(),createElementBlock(Fragment,{key:7},[createBaseVNode(`div`,_hoisted_74,[createBaseVNode(`span`,_hoisted_75,toDisplayString(_ctx.$tt(`ui.debug.vehicle.visRangeMin`)),1),createBaseVNode(`div`,_hoisted_76,[createVNode(unref(bngSlider_default),{modelValue:currentTorsionBarVisMode.value.rangeMin,"onUpdate:modelValue":_cache[45]||=$event=>currentTorsionBarVisMode.value.rangeMin=$event,min:currentTorsionBarVisMode.value.rangeMinCap,max:currentTorsionBarVisMode.value.rangeMaxCap,step:(currentTorsionBarVisMode.value.rangeMaxCap-currentTorsionBarVisMode.value.rangeMinCap)/100,onValueChanged:applyState},null,8,[`modelValue`,`min`,`max`,`step`]),createVNode(unref(bngInput_default),{modelValue:currentTorsionBarVisMode.value.rangeMin,"onUpdate:modelValue":_cache[46]||=$event=>currentTorsionBarVisMode.value.rangeMin=$event,type:`number`,min:currentTorsionBarVisMode.value.rangeMinCap,max:currentTorsionBarVisMode.value.rangeMaxCap,step:(currentTorsionBarVisMode.value.rangeMaxCap-currentTorsionBarVisMode.value.rangeMinCap)/1e3,onValueChanged:applyState},null,8,[`modelValue`,`min`,`max`,`step`]),createVNode(unref(bngSwitch_default),{modelValue:currentTorsionBarVisMode.value.rangeMinEnabled,"onUpdate:modelValue":_cache[47]||=$event=>currentTorsionBarVisMode.value.rangeMinEnabled=$event,onValueChanged:applyState},null,8,[`modelValue`])])]),createBaseVNode(`div`,_hoisted_77,[createBaseVNode(`span`,_hoisted_78,toDisplayString(_ctx.$tt(`ui.debug.vehicle.visRangeMax`)),1),createBaseVNode(`div`,_hoisted_79,[createVNode(unref(bngSlider_default),{modelValue:currentTorsionBarVisMode.value.rangeMax,"onUpdate:modelValue":_cache[48]||=$event=>currentTorsionBarVisMode.value.rangeMax=$event,min:currentTorsionBarVisMode.value.rangeMinCap,max:currentTorsionBarVisMode.value.rangeMaxCap,step:(currentTorsionBarVisMode.value.rangeMaxCap-currentTorsionBarVisMode.value.rangeMinCap)/100,onValueChanged:applyState},null,8,[`modelValue`,`min`,`max`,`step`]),createVNode(unref(bngInput_default),{modelValue:currentTorsionBarVisMode.value.rangeMax,"onUpdate:modelValue":_cache[49]||=$event=>currentTorsionBarVisMode.value.rangeMax=$event,type:`number`,min:currentTorsionBarVisMode.value.rangeMinCap,max:currentTorsionBarVisMode.value.rangeMaxCap,step:(currentTorsionBarVisMode.value.rangeMaxCap-currentTorsionBarVisMode.value.rangeMinCap)/1e3,onValueChanged:applyState},null,8,[`modelValue`,`min`,`max`,`step`]),createVNode(unref(bngSwitch_default),{modelValue:currentTorsionBarVisMode.value.rangeMaxEnabled,"onUpdate:modelValue":_cache[50]||=$event=>currentTorsionBarVisMode.value.rangeMaxEnabled=$event,onValueChanged:applyState},null,8,[`modelValue`])])]),createBaseVNode(`div`,_hoisted_80,[createBaseVNode(`span`,_hoisted_81,toDisplayString(_ctx.$tt(`ui.debug.vehicle.useInclusiveRange`)),1),createVNode(unref(bngSwitch_default),{modelValue:currentTorsionBarVisMode.value.usesInclusiveRange,"onUpdate:modelValue":_cache[51]||=$event=>currentTorsionBarVisMode.value.usesInclusiveRange=$event,onValueChanged:applyState},null,8,[`modelValue`])]),createBaseVNode(`div`,_hoisted_82,[createBaseVNode(`span`,_hoisted_83,toDisplayString(_ctx.$tt(`ui.debug.vehicle.showInf`)),1),createVNode(unref(bngSwitch_default),{modelValue:currentTorsionBarVisMode.value.showInfinity,"onUpdate:modelValue":_cache[52]||=$event=>currentTorsionBarVisMode.value.showInfinity=$event,onValueChanged:applyState},null,8,[`modelValue`])])],64)):createCommentVNode(``,!0),state.vehicle.torsionBarVisMode===1?createCommentVNode(``,!0):(openBlock(),createElementBlock(Fragment,{key:8},[createBaseVNode(`div`,_hoisted_84,[createBaseVNode(`span`,_hoisted_85,toDisplayString(_ctx.$tt(`ui.debug.vehicle.width`)),1),createBaseVNode(`div`,_hoisted_86,[createVNode(unref(bngSlider_default),{modelValue:state.vehicle.torsionBarVisWidthScale,"onUpdate:modelValue":_cache[53]||=$event=>state.vehicle.torsionBarVisWidthScale=$event,min:.1,max:5,step:.1,onValueChanged:applyState},null,8,[`modelValue`]),createVNode(unref(bngInput_default),{modelValue:state.vehicle.torsionBarVisWidthScale,"onUpdate:modelValue":_cache[54]||=$event=>state.vehicle.torsionBarVisWidthScale=$event,type:`number`,min:.1,max:5,step:.1,onValueChanged:applyState},null,8,[`modelValue`])])]),createBaseVNode(`div`,_hoisted_87,[createBaseVNode(`span`,_hoisted_88,toDisplayString(_ctx.$tt(`ui.debug.vehicle.transparency`)),1),createBaseVNode(`div`,_hoisted_89,[createVNode(unref(bngSlider_default),{modelValue:state.vehicle.torsionBarVisAlpha,"onUpdate:modelValue":_cache[55]||=$event=>state.vehicle.torsionBarVisAlpha=$event,min:0,max:1,step:.01,onValueChanged:applyState},null,8,[`modelValue`]),createVNode(unref(bngInput_default),{modelValue:state.vehicle.torsionBarVisAlpha,"onUpdate:modelValue":_cache[56]||=$event=>state.vehicle.torsionBarVisAlpha=$event,type:`number`,min:0,max:1,step:.01,onValueChanged:applyState},null,8,[`modelValue`])])])],64)),createBaseVNode(`div`,_hoisted_90,[createBaseVNode(`span`,_hoisted_91,toDisplayString(_ctx.$tt(`ui.debug.vehicle.railsSlideNodesVis`)),1),createVNode(unref(bngDropdown_default),{modelValue:state.vehicle.railsSlideNodesVisMode,"onUpdate:modelValue":_cache[57]||=$event=>state.vehicle.railsSlideNodesVisMode=$event,items:railsSlideNodesModeItems.value,onValueChanged:applyState,class:`control-input`},null,8,[`modelValue`,`items`])]),state.vehicle.railsSlideNodesVisMode===1?createCommentVNode(``,!0):(openBlock(),createElementBlock(Fragment,{key:9},[createBaseVNode(`div`,_hoisted_92,[createBaseVNode(`span`,_hoisted_93,toDisplayString(_ctx.$tt(`ui.debug.vehicle.width`)),1),createBaseVNode(`div`,_hoisted_94,[createVNode(unref(bngSlider_default),{modelValue:state.vehicle.railsSlideNodesVisWidthScale,"onUpdate:modelValue":_cache[58]||=$event=>state.vehicle.railsSlideNodesVisWidthScale=$event,min:.1,max:5,step:.1,onValueChanged:applyState},null,8,[`modelValue`]),createVNode(unref(bngInput_default),{modelValue:state.vehicle.railsSlideNodesVisWidthScale,"onUpdate:modelValue":_cache[59]||=$event=>state.vehicle.railsSlideNodesVisWidthScale=$event,type:`number`,min:.1,max:5,step:.1,onValueChanged:applyState},null,8,[`modelValue`])])]),createBaseVNode(`div`,_hoisted_95,[createBaseVNode(`span`,_hoisted_96,toDisplayString(_ctx.$tt(`ui.debug.vehicle.transparency`)),1),createBaseVNode(`div`,_hoisted_97,[createVNode(unref(bngSlider_default),{modelValue:state.vehicle.railsSlideNodesVisAlpha,"onUpdate:modelValue":_cache[60]||=$event=>state.vehicle.railsSlideNodesVisAlpha=$event,min:0,max:1,step:.01,onValueChanged:applyState},null,8,[`modelValue`]),createVNode(unref(bngInput_default),{modelValue:state.vehicle.railsSlideNodesVisAlpha,"onUpdate:modelValue":_cache[61]||=$event=>state.vehicle.railsSlideNodesVisAlpha=$event,type:`number`,min:0,max:1,step:.01,onValueChanged:applyState},null,8,[`modelValue`])])])],64)),createBaseVNode(`div`,_hoisted_98,[createBaseVNode(`span`,_hoisted_99,toDisplayString(_ctx.$tt(`ui.debug.vehicle.centerOfGravity`)),1),createVNode(unref(bngDropdown_default),{modelValue:state.vehicle.cogMode,"onUpdate:modelValue":_cache[62]||=$event=>state.vehicle.cogMode=$event,items:cogModeItems.value,onValueChanged:applyState,class:`control-input`},null,8,[`modelValue`,`items`])]),createBaseVNode(`div`,_hoisted_100,[createBaseVNode(`span`,_hoisted_101,toDisplayString(_ctx.$tt(`ui.debug.vehicle.collisionTriangle`)),1),createVNode(unref(bngDropdown_default),{modelValue:state.vehicle.collisionTriangleVisMode,"onUpdate:modelValue":_cache[63]||=$event=>state.vehicle.collisionTriangleVisMode=$event,items:collisionTriangleModeItems.value,onValueChanged:applyState,class:`control-input`},null,8,[`modelValue`,`items`])]),state.vehicle.collisionTriangleVisMode===1?createCommentVNode(``,!0):(openBlock(),createElementBlock(`div`,_hoisted_102,[createBaseVNode(`span`,_hoisted_103,toDisplayString(_ctx.$tt(`ui.debug.vehicle.transparency`)),1),createBaseVNode(`div`,_hoisted_104,[createVNode(unref(bngSlider_default),{modelValue:state.vehicle.collisionTriangleVisAlpha,"onUpdate:modelValue":_cache[64]||=$event=>state.vehicle.collisionTriangleVisAlpha=$event,min:0,max:1,step:.01,onValueChanged:applyState},null,8,[`modelValue`]),createVNode(unref(bngInput_default),{modelValue:state.vehicle.collisionTriangleVisAlpha,"onUpdate:modelValue":_cache[65]||=$event=>state.vehicle.collisionTriangleVisAlpha=$event,type:`number`,min:0,max:1,step:.01,onValueChanged:applyState},null,8,[`modelValue`])])])),createBaseVNode(`div`,_hoisted_105,[createBaseVNode(`span`,_hoisted_106,toDisplayString(_ctx.$tt(`ui.debug.vehicle.aerodynamics`)),1),createVNode(unref(bngDropdown_default),{modelValue:state.vehicle.aeroMode,"onUpdate:modelValue":_cache[66]||=$event=>state.vehicle.aeroMode=$event,items:aeroModeItems.value,onValueChanged:applyState,class:`control-input`},null,8,[`modelValue`,`items`])]),state.vehicle.aeroMode===1?createCommentVNode(``,!0):(openBlock(),createElementBlock(`div`,_hoisted_107,[createBaseVNode(`span`,_hoisted_108,toDisplayString(_ctx.$tt(`ui.debug.vehicle.aerodynamicsScale`)),1),createBaseVNode(`div`,_hoisted_109,[createVNode(unref(bngSlider_default),{modelValue:state.vehicle.aerodynamicsScale,"onUpdate:modelValue":_cache[67]||=$event=>state.vehicle.aerodynamicsScale=$event,min:0,max:.2,step:.01,onValueChanged:applyState},null,8,[`modelValue`]),createVNode(unref(bngInput_default),{modelValue:state.vehicle.aerodynamicsScale,"onUpdate:modelValue":_cache[68]||=$event=>state.vehicle.aerodynamicsScale=$event,type:`number`,min:0,max:.2,step:.01,onValueChanged:applyState},null,8,[`modelValue`])])])),createBaseVNode(`div`,_hoisted_110,[createBaseVNode(`span`,_hoisted_111,toDisplayString(_ctx.$tt(`ui.debug.vehicle.tireContactPoint`)),1),createVNode(unref(bngSwitch_default),{modelValue:state.vehicle.tireContactPoint,"onUpdate:modelValue":_cache[69]||=$event=>state.vehicle.tireContactPoint=$event,onValueChanged:applyState},null,8,[`modelValue`])]),createBaseVNode(`div`,_hoisted_112,[createBaseVNode(`span`,_hoisted_113,toDisplayString(_ctx.$tt(`ui.debug.vehicle.steeringGeometry`)),1),createVNode(unref(bngSwitch_default),{modelValue:state.vehicle.steeringGeometry,"onUpdate:modelValue":_cache[70]||=$event=>state.vehicle.steeringGeometry=$event,onValueChanged:applyState},null,8,[`modelValue`])]),state.vehicle.steeringGeometry?(openBlock(),createElementBlock(`div`,_hoisted_114,[createBaseVNode(`span`,_hoisted_115,toDisplayString(_ctx.$tt(`ui.debug.vehicle.steeringGeometryLineLength`)),1),createBaseVNode(`div`,_hoisted_116,[createVNode(unref(bngSlider_default),{modelValue:state.vehicle.steeringGeometryLineLength,"onUpdate:modelValue":_cache[71]||=$event=>state.vehicle.steeringGeometryLineLength=$event,min:0,max:50,step:.1,onValueChanged:applyState},null,8,[`modelValue`]),createVNode(unref(bngInput_default),{modelValue:state.vehicle.steeringGeometryLineLength,"onUpdate:modelValue":_cache[72]||=$event=>state.vehicle.steeringGeometryLineLength=$event,type:`number`,min:0,max:50,step:.1,onValueChanged:applyState},null,8,[`modelValue`])])])):createCommentVNode(``,!0),shipping.value?createCommentVNode(``,!0):(openBlock(),createElementBlock(`div`,_hoisted_117,[createBaseVNode(`span`,_hoisted_118,toDisplayString(_ctx.$tt(`ui.debug.vehicle.wheelThermals`))+` 🐞`,1),createVNode(unref(bngSwitch_default),{modelValue:state.vehicle.wheelThermals,"onUpdate:modelValue":_cache[73]||=$event=>state.vehicle.wheelThermals=$event,onValueChanged:applyState},null,8,[`modelValue`])]))],64)):createCommentVNode(``,!0),createBaseVNode(`div`,_hoisted_119,[createBaseVNode(`div`,_hoisted_120,[createBaseVNode(`span`,_hoisted_121,toDisplayString(_ctx.$tt(`ui.debug.vehicle.meshVisibility`)),1),createBaseVNode(`div`,_hoisted_122,[(openBlock(!0),createElementBlock(Fragment,null,renderList(controls$1.jbeamvis.meshVisButtonGroup,btn=>(openBlock(),createBlock(unref(bngButton_default),{key:btn.label,onClick:$event=>btn.action(),disabled:disableVehicleButtons.value,accent:unref(ACCENTS).outlined,class:`mesh-button`},{default:withCtx(()=>[createTextVNode(toDisplayString(btn.label),1)]),_:2},1032,[`onClick`,`disabled`,`accent`]))),128))])])]),_cache[75]||=createBaseVNode(`hr`,null,null,-1),createBaseVNode(`h4`,null,toDisplayString(_ctx.$tt(`ui.debug.terrain`)),1),createBaseVNode(`div`,_hoisted_123,[(openBlock(!0),createElementBlock(Fragment,null,renderList(controls$1.terrain.buttonGroup_1,btn=>(openBlock(),createBlock(unref(bngButton_default),{key:btn.label,onClick:$event=>btn.action(),accent:unref(ACCENTS).secondary},{default:withCtx(()=>[createTextVNode(toDisplayString(_ctx.$tt(btn.label)),1)]),_:2},1032,[`onClick`,`accent`]))),128))])]))}},Debug_default=__plugin_vue_export_helper_default(_sfc_main$14,[[`__scopeId`,`data-v-8c471ede`]]),_sfc_main$13={__name:`VehicleConfig`,props:{tab:{type:String,default:`parts`,validator:val=>!val||[`parts`,`tuning`,`color`,`save`,`debug`].includes(val)}},setup(__props){let exit=event=>{event.detail.force||window.bngVue.gotoAngularState(`menu.mainmenu`)};function syncWithStates(tab){window.bngVue&&(tab=[`parts`,`tuning`,`color`,`save`,`debug`][tab.index]||`parts`,window.bngVue.gotoAngularState(`menu.vehicleconfig.${tab}`))}return(_ctx,_cache)=>withDirectives((openBlock(),createBlock(unref(layoutSingle_default),{class:`vehcfg`,onDeactivate:exit},{default:withCtx(()=>[withDirectives((openBlock(),createBlock(unref(tabs_default),{class:`bng-tabs`,onChange:syncWithStates},{default:withCtx(()=>[withDirectives(createVNode(unref(tabList_default),null,null,512),[[unref(BngBlur_default)]]),withDirectives(createVNode(Parts_default,{"tab-selected":__props.tab===`parts`,"tab-heading":_ctx.$t(`ui.vehicleconfig.parts`)},null,8,[`tab-selected`,`tab-heading`]),[[unref(BngBlur_default)]]),withDirectives(createVNode(Tuning_default,{"tab-selected":__props.tab===`tuning`,"tab-heading":_ctx.$t(`ui.vehicleconfig.tuning`)},null,8,[`tab-selected`,`tab-heading`]),[[unref(BngBlur_default)]]),withDirectives(createVNode(Paint_default,{"tab-selected":__props.tab===`color`,"tab-heading":_ctx.$t(`ui.vehicleconfig.color`)},null,8,[`tab-selected`,`tab-heading`]),[[unref(BngBlur_default)]]),withDirectives(createVNode(Save_default,{"tab-selected":__props.tab===`save`,"tab-heading":_ctx.$t(`ui.vehicleconfig.save`)+` & `+_ctx.$t(`ui.vehicleconfig.load`)},null,8,[`tab-selected`,`tab-heading`]),[[unref(BngBlur_default)]]),withDirectives(createVNode(Debug_default,{"tab-selected":__props.tab===`debug`,"tab-heading":_ctx.$tt(`ui.debug.vehicle`)},null,8,[`tab-selected`,`tab-heading`]),[[unref(BngBlur_default)]])]),_:1})),[[unref(BngFrustumMover_default),!0,void 0,{left:!0}]])]),_:1})),[[unref(BngScopedNav_default),{activateOnMount:!0,bubbleWhitelistEvents:[`tab_l`,`tab_r`,`menu`]}]])}},VehicleConfig_default=__plugin_vue_export_helper_default(_sfc_main$13,[[`__scopeId`,`data-v-e5f4e51f`]]),_hoisted_1$10={class:`adjustment-container`},_hoisted_2$6={class:`y-controls`},_hoisted_3$5={class:`slider-container`},_hoisted_4$4={class:`value-input`},_hoisted_5$3={class:`x-controls`},_hoisted_6$2={class:`slider-container`},_hoisted_7$2={class:`value-input`},_hoisted_8$1={class:`reset-cont`},MIRROR_RANGE_DEFAULTS={min:-20,max:20,step:.01},_sfc_main$12={__name:`MirrorAdjust`,props:{mirror:Object},setup(__props){let props=__props,uiScopeName=`vehicle-config-mirrors`,uiNavScope$1=useUINavScope(uiScopeName),reactivateUIScope=event=>{(event.type===`deactivate`||event.type===`focusout`)&&uiNavScope$1.set(uiScopeName)},range={x:{min:props.mirror.clampX?props.mirror.clampX[0]:MIRROR_RANGE_DEFAULTS.min,max:props.mirror.clampX?props.mirror.clampX[1]:MIRROR_RANGE_DEFAULTS.max,step:MIRROR_RANGE_DEFAULTS.step},y:{min:props.mirror.clampY?props.mirror.clampY[0]:MIRROR_RANGE_DEFAULTS.min,max:props.mirror.clampY?props.mirror.clampY[1]:MIRROR_RANGE_DEFAULTS.max,step:MIRROR_RANGE_DEFAULTS.step}},[inpX,inpY]=[ref(),ref()],isChanged=computed(()=>inpX.value&&inpX.value.dirty||inpY.value&&inpY.value.dirty),mover={x:0,y:0,drift:.2,tmr:null,tmrInterval:100};function move(evt){let val=evt.detail.value>mover.drift?evt.detail.value-mover.drift:evt.detail.value<-mover.drift?evt.detail.value+mover.drift:0;evt.detail.name===`focus_lr`?mover.x=val:evt.detail.name===`focus_ud`&&(mover.y=val)}let precision=10**(MIRROR_RANGE_DEFAULTS.step+`.`).split(/[.,]/)[1].length,clamp$2=(val,axis=`x`)=>Math.round(Math.max(range[axis].min,Math.min(val,range[axis].max))*precision)/precision;function resetValues(){props.mirror.x=inpX.value.currentCleanValue,props.mirror.y=inpY.value.currentCleanValue,onValueChanged()}function onValueChanged(){Lua_default.extensions.core_vehicle_mirror.setAngleOffset(props.mirror.name,-props.mirror.y,-props.mirror.x,!1,!1)}return onMounted(()=>{getUINavServiceInstance().useCrossfire=!1,Lua_default.extensions.core_vehicle_mirror.focusOnMirror(props.mirror.name),mover.tmr=setInterval(()=>{mover.x===0&&mover.y===0||(props.mirror.x=clamp$2(props.mirror.x+mover.x,`x`),props.mirror.y=clamp$2(props.mirror.y+mover.y,`y`),onValueChanged())},mover.tmrInterval)}),onUnmounted(()=>{getUINavServiceInstance().useCrossfire=!0,clearInterval(mover.tmr)}),(_ctx,_cache)=>withDirectives((openBlock(),createElementBlock(`div`,_hoisted_1$10,[createVNode(unref(bngImageTile_default),{class:`mirror-tile`,icon:unref(icons)[__props.mirror.mirrorIcon],label:__props.mirror.description,ratio:`1:1`},null,8,[`icon`,`label`]),createBaseVNode(`div`,_hoisted_2$6,[createBaseVNode(`div`,_hoisted_3$5,[createVNode(unref(bngSlider_default),mergeProps({"bng-no-nav":`true`,ref_key:`inpY`,ref:inpY,class:`slider-y`},range.y,{uiNavFocus:!1,modelValue:__props.mirror.y,"onUpdate:modelValue":_cache[0]||=$event=>__props.mirror.y=$event,onFocusout:reactivateUIScope,onValueChanged,onDeactivate:reactivateUIScope}),null,16,[`modelValue`])]),createBaseVNode(`div`,_hoisted_4$4,[createVNode(unref(bngBinding_default),{class:`keybinding`,action:`menu_item_focus_ud`,deviceMask:`xinput`,dark:!1}),createVNode(unref(bngInput_default),mergeProps({class:`value`,modelValue:__props.mirror.y,"onUpdate:modelValue":_cache[1]||=$event=>__props.mirror.y=$event,type:`number`},range.y,{prefix:`Y`,suffix:`°`}),null,16,[`modelValue`])])]),createBaseVNode(`div`,_hoisted_5$3,[createBaseVNode(`div`,_hoisted_6$2,[createVNode(unref(bngSlider_default),mergeProps({"bng-no-nav":`true`,ref_key:`inpX`,ref:inpX,class:`slider-x`},range.x,{uiNavFocus:!1,modelValue:__props.mirror.x,"onUpdate:modelValue":_cache[2]||=$event=>__props.mirror.x=$event,onFocusout:reactivateUIScope,onValueChanged,onDeactivate:reactivateUIScope}),null,16,[`modelValue`])]),createBaseVNode(`div`,_hoisted_7$2,[createVNode(unref(bngBinding_default),{class:`keybinding`,action:`menu_item_focus_lr`,deviceMask:`xinput`,dark:!1}),createVNode(unref(bngInput_default),mergeProps({class:`value`,modelValue:__props.mirror.x,"onUpdate:modelValue":_cache[3]||=$event=>__props.mirror.x=$event,type:`number`},range.x,{prefix:`X`,suffix:`°`}),null,16,[`modelValue`])])]),createBaseVNode(`div`,_hoisted_8$1,[createVNode(unref(bngButton_default),{accent:unref(ACCENTS).attention,disabled:!isChanged.value,onClick:_cache[4]||=$event=>resetValues()},{default:withCtx(()=>[createVNode(unref(bngBinding_default),{controller:``,"ui-event":`action_3`}),createTextVNode(` `+toDisplayString(_ctx.$t(`ui.common.reset`)),1)]),_:1},8,[`accent`,`disabled`])])])),[[unref(BngOnUiNav_default),move,`focus_lr,focus_ud`],[unref(BngOnUiNav_default),resetValues,`action_3`]])}},MirrorAdjust_default=__plugin_vue_export_helper_default(_sfc_main$12,[[`__scopeId`,`data-v-14ab0128`]]),_hoisted_1$9={key:0,class:`content buttons-grid`},_sfc_main$11={__name:`Mirrors`,props:{exitRoute:{type:String,default:`menu.vehicleconfig.tuning`}},setup(__props){useUINavScope(`vehicle-config-mirrors`);let comp=ref(null),{lua,events:events$3}=useBridge(),mirrors=ref([]),selectedMirror=ref(null),props=__props;async function exitAdjustmentMode(){selectedMirror.value?(lua.extensions.core_vehicle_mirror.setAngleOffset(selectedMirror.value.name,-selectedMirror.value.y,-selectedMirror.value.x,!1,!0),selectedMirror.value=null,comp.value=null,await lua.extensions.core_vehicle_mirror.focusOnMirror(!1)):bngVue.gotoAngularState(props.exitRoute)}async function getVehicleMirrors(){let data=await lua.extensions.core_vehicle_mirror.getAnglesOffset();for(let key in mirrors.value.splice(0),data){let position=data[key].position,mirrorIcon=data[key].icon,description=data[key].label;if(position||(/_L$|_L_/.test(key)?(position=`left`,mirrorIcon||=`mirrorLeftDefault`):/_R$|_R_/.test(key)?(position=`right`,mirrorIcon||=`mirrorRightDefault`):position=`mid`),!description)description=$translate.instant(`ui.mirrors.position.`+position),key.endsWith(`_spot`)&&(description+=` (${$translate.instant(`ui.mirrors.spot`)})`);else{let tr=$translate.instant(`ui.mirrors.`+description);tr.startsWith(`ui.mirrors.`)||(description=tr)}mirrors.value.push({name:data[key].name,description,position,x:data[key].angleOffset.x,y:data[key].angleOffset.z,clampX:data[key].clampX,clampY:data[key].clampZ,mirrorIcon:mirrorIcon||`mirrorInteriorMiddle`,row:data[key].row||0})}mirrors.value.sort((a$1,b)=>a$1.row-b.row)}return onMounted(async()=>{await getVehicleMirrors(),events$3.on(`VehicleChange`,getVehicleMirrors),lua.extensions.core_input_bindings.setMenuActionEnabled(!0,`menu_item_focus_lr`),lua.extensions.core_input_bindings.setMenuActionEnabled(!0,`menu_item_focus_ud`)}),onUnmounted(()=>{events$3.off(`VehicleChange`,getVehicleMirrors)}),(_ctx,_cache)=>withDirectives((openBlock(),createBlock(unref(layoutSingle_default),{class:`layout-content-full layout-align-hstart`,"bng-ui-scope":`vehicle-config-mirrors`},{default:withCtx(()=>[withDirectives((openBlock(),createBlock(unref(bngCard_default),{class:`mirrors-card`},{buttons:withCtx(()=>[createVNode(unref(bngButton_default),{onClick:exitAdjustmentMode},{default:withCtx(()=>[selectedMirror.value?(openBlock(),createBlock(unref(bngBinding_default),{key:0,controller:``,"ui-event":`action_2`})):(openBlock(),createBlock(unref(bngBinding_default),{key:1,controller:``,"ui-event":`back`})),createTextVNode(` `+toDisplayString(_ctx.$t(selectedMirror.value?`ui.common.apply`:`ui.common.close`)),1)]),_:1})]),default:withCtx(()=>[createVNode(unref(bngCardHeading_default),null,{default:withCtx(()=>[createTextVNode(toDisplayString(_ctx.$t(`ui.mirrors.name`)),1)]),_:1}),selectedMirror.value?(openBlock(),createBlock(MirrorAdjust_default,{key:1,class:`content`,mirror:selectedMirror.value},null,8,[`mirror`])):(openBlock(),createElementBlock(`div`,_hoisted_1$9,[(openBlock(!0),createElementBlock(Fragment,null,renderList(mirrors.value,mirror=>(openBlock(),createBlock(unref(bngImageTile_default),{onClick:$event=>selectedMirror.value=mirror,class:normalizeClass([`mirror-button`,[mirror.position]]),icon:unref(icons)[mirror.mirrorIcon]||unref(icons).placeholder,label:mirror.description,"bng-nav-item":``},null,8,[`onClick`,`class`,`icon`,`label`]))),256))]))]),_:1})),[[unref(BngBlur_default),!0]])]),_:1})),[[unref(BngOnUiNav_default),exitAdjustmentMode,`menu,back`],[unref(BngOnUiNav_default),()=>selectedMirror.value&&exitAdjustmentMode(),`action_2`]])}},Mirrors_default=__plugin_vue_export_helper_default(_sfc_main$11,[[`__scopeId`,`data-v-28f8b633`]]),routes_default$17=[{path:`/vehicle-config`,name:`menu.vehicleconfig`,redirect:`/vehicle-config/parts`,meta:{clickThrough:!0,infoBar:{withAngular:!1,visible:!0,showSysInfo:!1},uiApps:{shown:!0},topBar:{visible:!0}},children:[{path:`parts`,name:`menu.vehicleconfig.parts`,component:VehicleConfig_default,props:{tab:`parts`}},{path:`tuning`,name:`menu.vehicleconfig.tuning`,component:VehicleConfig_default,props:{tab:`tuning`}},{path:`color`,name:`menu.vehicleconfig.color`,component:VehicleConfig_default,props:{tab:`color`},meta:{uiApps:{shown:!1}}},{path:`save`,name:`menu.vehicleconfig.save`,component:VehicleConfig_default,props:{tab:`save`},meta:{uiApps:{shown:!1}}},{path:`debug`,name:`menu.vehicleconfig.debug`,component:VehicleConfig_default,props:{tab:`debug`}}]},{path:`/vehicle-config/tuning/mirrors/:exitRoute?/`,name:`menu.vehicleconfig.tuning.mirrors`,component:Mirrors_default,props:!0},{path:`/vehicle-config/tuning/mirrors-angular`,name:`menu.vehicleconfig.tuning.mirrors.with-angular`,component:Mirrors_default,props:{exitRoute:`menu.vehicleconfigold.tuning`}},{path:`/vehicle-config/tuning/mirrors-garage`,name:`menu.vehicleconfig.tuning.mirrors.in-garage`,component:Mirrors_default,props:{exitRoute:`garagemode.tuning`}}],_hoisted_1$8={key:0,class:`management-details`},_hoisted_2$5={key:0,class:`current-vehicle-info`},_hoisted_3$4={class:`info-row`},_hoisted_4$3={class:`value`},_hoisted_5$2={class:`buttons-section`},_sfc_main$10={__name:`ManagementDetails`,props:{managementDetails:{type:Object,default:null},executeButton:{type:Function,required:!0}},emits:[`button-click`],setup(__props,{emit:__emit}){let props=__props,emit$1=__emit,handleButtonClick=buttonId=>{props.executeButton(buttonId),emit$1(`button-click`,buttonId)};return(_ctx,_cache)=>__props.managementDetails&&__props.managementDetails.buttonInfo&&__props.managementDetails.buttonInfo.length>0?(openBlock(),createElementBlock(`div`,_hoisted_1$8,[__props.managementDetails.details?(openBlock(),createElementBlock(`div`,_hoisted_2$5,[createBaseVNode(`div`,_hoisted_3$4,[_cache[0]||=createBaseVNode(`span`,{class:`label`},`Current Vehicle:`,-1),createBaseVNode(`span`,_hoisted_4$3,toDisplayString(__props.managementDetails.details.currentVehicleName),1)])])):createCommentVNode(``,!0),createBaseVNode(`div`,_hoisted_5$2,[(openBlock(!0),createElementBlock(Fragment,null,renderList(__props.managementDetails.buttonInfo,button=>(openBlock(),createElementBlock(`div`,{key:button.buttonId,class:`button-container`},[createVNode(unref(bngButton_default),{accent:button.accent||`secondary`,label:button.label,icon:button.icon,onClick:$event=>handleButtonClick(button.buttonId)},null,8,[`accent`,`label`,`icon`,`onClick`])]))),128))])])):createCommentVNode(``,!0)}},ManagementDetails_default=__plugin_vue_export_helper_default(_sfc_main$10,[[`__scopeId`,`data-v-b0128491`]]),_sfc_main$9={__name:`VehicleSelector`,setup(__props){return(_ctx,_cache)=>(openBlock(),createBlock(GridSelector_default,{backendName:`vehicleSelector`,routePath:`/vehicle-selector`,defaultPath:{keys:[`allModels`]},defaultDetailsMode:`advanced`,tileImagesTopAligned:``},{"item-details":withCtx(({activeItem,activeItemDetails,executeButton,toggleFavourite,exploreFolder,goToMod})=>[createVNode(VehicleDetails_default,{activeItem,activeItemDetails,executeButton,toggleFavourite,exploreFolder,goToMod,showHeaderTitle:!0},null,8,[`activeItem`,`activeItemDetails`,`executeButton`,`toggleFavourite`,`exploreFolder`,`goToMod`])]),"management-details":withCtx(({managementDetails,executeButton})=>[createVNode(ManagementDetails_default,{managementDetails,executeButton},null,8,[`managementDetails`,`executeButton`])]),_:1}))}},VehicleSelector_default=_sfc_main$9,routes_default$18=[{name:`menu.vehiclesnew`,path:`/vehicle-selector/:pathMatch(.*)*`,component:VehicleSelector_default,props:!0,meta:{clickThrough:!0,infoBar:{visible:!0,showSysInfo:!1},uiApps:{shown:!1},topBar:{visible:!0}}}],router=createRouter({history:createWebHashHistory(),routes:[...Object.values([routes_default,routes_default$1,routes_default$2,routes_default$3,routes_default$4,routes_default$5,routes_default$6,routes_default$7,routes_default$8,routes_default$9,routes_default$10,routes_default$11,routes_default$12,routes_default$13,routes_default$14,routes_default$15,routes_default$16,routes_default$17,routes_default$18]).flatMap(routes=>routes||[]),{path:`/:catchAll(.*)*`,name:`unknown`,component:NotFound_default}]});router.bngUpdateMeta=to=>{to.meta&&(to.meta.uiApps&&handelUIAppsSettings(to.meta.uiApps),handleInfoBarSettings(to.meta.infoBar||{}),handleTopBarSettings(to))},router.afterEach((to,from)=>{reportState(to.path,!0,from.path),window.bridge.api.engineLua(`extensions.hook("onUiChangedState", "${to.name}", "${from.name}")`),router.bngUpdateMeta(to)});var handelUIAppsSettings=settings$1=>{let appsAPI=useUIApps();settings$1.layout&&appsAPI.setLayout(settings$1.layout),`shown`in settings$1&&appsAPI.setVisible(settings$1.shown)},handleInfoBarSettings=settings$1=>{let infoBar=useInfoBar();infoBar.visible=settings$1.visible,infoBar.showSysInfo=settings$1.showSysInfo,infoBar.withAngular=settings$1.withAngular,settings$1.hints&&(infoBar.clearHints(),infoBar.addHints(settings$1.hints))},handleTopBarSettings=to=>{let topBar=useTopBar(),meta=to.meta.topBar||{};meta.visible?meta.visible&&!topBar.visible&&topBar.show():topBar.hide(),topBar.onUIStateChanged(to)},router_default=router,_hoisted_1$7={key:0,id:`vue-debug`},_hoisted_2$4={class:`heading-wrapper`},_hoisted_3$3={class:`label`},_hoisted_4$2={key:0,class:`route-info`},_hoisted_5$1={class:`main`},_hoisted_6$1={class:`controls`},_hoisted_7$1={key:0},_hoisted_8=[`label`],_hoisted_9=[`value`,`selected`],_sfc_main$8={__name:`VueDebug`,setup(__props){let{lua}=useBridge(),EXTRA_ROUTE,routeGroups=router_default.getRoutes().map(r=>r.name).filter(n=>n!==`routelist`).sort((a$1,b)=>a$1.localeCompare(b)).reduce((res,n)=>{if(!n)return res;let g=n.substring(0,1);return res[g]||(res[g]={name:g.toUpperCase(),routes:[]}),res[g].routes.push(n),res},{}),route=useRoute(),hash=ref(location.hash.split(`#`)[1]),path=computed(()=>route.path),routeName=computed(()=>route.name),showDebug=ref(window._VueDebugState),isOpen=ref(window._VueDebugOpen),showComponents=router_default.hasRoute(`components`),bngVue$1=window.bngVue||{};bngVue$1.debug=(state=!0)=>showDebug.value=window._VueDebugState=state,bngVue$1.reset=()=>bngVue$1.gotoGameState(`menu.mainmenu`);function toggleOpen(){isOpen.value=window._VueDebugOpen=!isOpen.value}function selectRoute(e){e.target.value&&bngVue$1.gotoGameState(e.target.value)}function icons$3(){bngVue$1.gotoGameState(`components/IconBrowser`),toggleOpen()}function colours(){bngVue$1.gotoGameState(`components/Colours`),toggleOpen()}function extra(){bngVue$1.gotoGameState(void 0),toggleOpen()}function components(){bngVue$1.showComponents(),toggleOpen()}function menu(){bngVue$1.reset(),toggleOpen()}function mainmenu(){toggleOpen(),lua.returnToMainMenu()}let closeDebug=e=>{e.stopPropagation(),bngVue$1.debug(!1)};return addEventListener(`hashchange`,e=>{hash.value=e.newURL.split(`#`)[1]}),(_ctx,_cache)=>(openBlock(),createBlock(Teleport,{to:`body`},[showDebug.value?(openBlock(),createElementBlock(`div`,_hoisted_1$7,[createBaseVNode(`div`,{class:`handle`,onClick:toggleOpen},[createBaseVNode(`div`,_hoisted_2$4,[createBaseVNode(`span`,_hoisted_3$3,[_cache[1]||=createBaseVNode(`strong`,null,`Vue`,-1),isOpen.value?createCommentVNode(``,!0):(openBlock(),createElementBlock(`span`,_hoisted_4$2,`: `+toDisplayString(path.value)+` [ `+toDisplayString(routeName.value)+` ]`,1))]),createBaseVNode(`a`,{onClick:closeDebug},`x`)])]),withDirectives(createBaseVNode(`div`,_hoisted_5$1,[createBaseVNode(`div`,null,[createTextVNode(` Current hash: `+toDisplayString(hash.value),1),_cache[2]||=createBaseVNode(`br`,null,null,-1),createTextVNode(` Route name: `+toDisplayString(routeName.value),1)]),_cache[4]||=createBaseVNode(`hr`,null,null,-1),createBaseVNode(`div`,_hoisted_6$1,[unref(showComponents)?(openBlock(),createElementBlock(`div`,_hoisted_7$1,[withDirectives((openBlock(),createElementBlock(`a`,{href:`#`,onClick:menu},[..._cache[3]||=[createTextVNode(`Main Menu`,-1)]])),[[unref(BngDoubleClick_default),mainmenu,void 0,{capture:!0}],[unref(BngTooltip_default),`Doubleclick to unload level`]]),unref(void 0)?(openBlock(),createElementBlock(`a`,{key:0,href:`#`,onClick:extra},`⏩`)):createCommentVNode(``,!0),createBaseVNode(`a`,{href:`#`,onClick:_cache[0]||=$event=>_ctx.$simplemenu.value=!_ctx.$simplemenu.value},toDisplayString(_ctx.$simplemenu.value?`✓`:`☐`)+` SimpleMenu`,1),createBaseVNode(`a`,{href:`#`,onClick:components},`Components`),createBaseVNode(`a`,{href:`#`,onClick:icons$3},`Icons`),createBaseVNode(`a`,{href:`#`,onClick:colours},`Colours`)])):createCommentVNode(``,!0),createBaseVNode(`select`,{multiple:``,onClick:selectRoute},[(openBlock(!0),createElementBlock(Fragment,null,renderList(unref(routeGroups),group=>(openBlock(),createElementBlock(`optgroup`,{key:group.name,label:group.name},[(openBlock(!0),createElementBlock(Fragment,null,renderList(group.routes,route$1=>(openBlock(),createElementBlock(`option`,{key:route$1,value:route$1,selected:route$1===routeName.value},toDisplayString(route$1),9,_hoisted_9))),128))],8,_hoisted_8))),128))])])],512),[[vShow,isOpen.value]])])):createCommentVNode(``,!0)]))}},VueDebug_default=__plugin_vue_export_helper_default(_sfc_main$8,[[`__scopeId`,`data-v-669cde99`]]),_hoisted_1$6={class:`hint-content`},_hoisted_2$3={key:0,class:`binding-container`},_hoisted_3$2={key:1,class:`text`},_hoisted_4$1={key:1,class:`hint-text`},_sfc_main$7={__name:`Hint`,props:{data:Object},setup(__props){let Controls=controls_default(),props=__props,PROP_DEFAULTS={icon:{color:`white`},binding:{showUnassigned:!0,dark:!1}},hintRef=ref(null),bindingRefs=ref([]),hintContent=computed(()=>{let hints=props.data?[props.data.content].flat():[],res=[],label;for(let hint of hints)typeof hint==`string`?label=hint:(hint.label&&(label=hint.label),res.push({...hint,label:void 0}));return label&&res.push(label),res}),bindingView=computed(()=>{let res=hintContent.value.filter(item=>typeof item!=`string`);for(let item of res)if(item.type===`binding`){if(item.props?.viewerObj){item.viewerObjs=[item.props.viewerObj];continue}let viewerObjs=Controls.makeViewerObj({...PROP_DEFAULTS[item.type],...item.props,actionVariants:!0,useLastDevice:!0});viewerObjs?.variants?item.viewerObjs=viewerObjs.variants:item.viewerObjs=[viewerObjs]}return res}),labelView=computed(()=>hintContent.value.find(item=>typeof item==`string`)||bindingView.value.find(item=>item.label)?.label),bindingDisplayed=computed(()=>!!(bindingRefs.value.some(ref$1=>ref$1.displayed)||bindingView.value.some(item=>item.type===`icon`)||labelView.value));function onClick(evt){if(lastFocused&&document.body.contains(lastFocused)&&!setFocusExternal(lastFocused,!0,!1))try{lastFocused.focus?.()}catch{}props.data.action?.(evt)}let lastFocused;function trackFocus(evt){let target=evt?.detail?.target||evt?.target||document.activeElement;if(!target){lastFocused=null;return}if(target=target.closest(NAVIGABLE_ELEMENTS_SELECTOR),!target){lastFocused=null;return}if(target===lastFocused)return;let button=hintRef.value?.getElement?.();target!==button&&!button.contains(target)&&(lastFocused=target)}return onMounted(()=>window.addEventListener(`uinav-focus`,trackFocus)),onBeforeUnmount(()=>window.removeEventListener(`uinav-focus`,trackFocus)),(_ctx,_cache)=>withDirectives((openBlock(),createBlock(unref(bngButton_default),{ref_key:`hintRef`,ref:hintRef,class:normalizeClass([`hint`,{"flash-on":__props.data.flash}]),accent:unref(ACCENTS).text,disabled:!__props.data.action,onClick:withModifiers(onClick,[`stop`]),"bng-no-nav":``,tabindex:`-1`},{default:withCtx(()=>[createBaseVNode(`div`,_hoisted_1$6,[bindingView.value.length>0?(openBlock(),createElementBlock(`div`,_hoisted_2$3,[(openBlock(!0),createElementBlock(Fragment,null,renderList(bindingView.value,(item,idx)=>(openBlock(),createElementBlock(`span`,{key:idx,class:`rich`},[item.type===`icon`?(openBlock(),createBlock(unref(bngIcon_default),mergeProps({key:0,class:`icon`},{ref_for:!0},{...PROP_DEFAULTS[item.type],...item.props}),null,16)):createCommentVNode(``,!0),(openBlock(!0),createElementBlock(Fragment,null,renderList(item.viewerObjs,(viewerObj,index)=>(openBlock(),createBlock(unref(bngBinding_default),mergeProps({key:index,ref_for:!0,ref_key:`bindingRefs`,ref:bindingRefs,class:`binding`},{ref_for:!0},{...PROP_DEFAULTS[item.type],...item.props,viewerObj},{"track-ignore":``}),null,16))),128)),item.hold?(openBlock(),createElementBlock(`span`,_hoisted_3$2,toDisplayString(item.hold?`[hold]`:``),1)):createCommentVNode(``,!0)]))),128))])):createCommentVNode(``,!0),labelView.value?(openBlock(),createElementBlock(`span`,_hoisted_4$1,toDisplayString(_ctx.$tt(labelView.value)),1)):createCommentVNode(``,!0)])]),_:1},8,[`class`,`accent`,`disabled`])),[[vShow,bindingDisplayed.value]])}},Hint_default=__plugin_vue_export_helper_default(_sfc_main$7,[[`__scopeId`,`data-v-29a63ba0`]]),_hoisted_1$5={key:0,class:`info-bar-stats`},_hoisted_2$2={key:0},_hoisted_3$1={key:0,class:`divider`},_hoisted_4={key:0},_hoisted_5={class:`sysinfo`},_hoisted_6={class:`sysinfo`},_hoisted_7={key:1,class:`info-bar-buttons`,"bng-no-child-nav":`true`},_sfc_main$6={__name:`InfoBar`,setup(__props){let{visible,showSysInfo,withAngular,hints}=storeToRefs(useInfoBar()),showBuildInfo=ref(!1),toggleBuildInfo=()=>showBuildInfo.value=!showBuildInfo.value,route=useRoute(),solidBar=computed(()=>route.name===`menu.mainmenu`?!sysInfo_default.mainMenuBackgroundRequired.value:withAngular.value);return(_ctx,_cache)=>withDirectives((openBlock(),createElementBlock(`div`,{class:normalizeClass([`info-bar`,{"info-bar-solid":solidBar.value}]),"bng-no-nav":`true`},[unref(showSysInfo)?(openBlock(),createElementBlock(`div`,_hoisted_1$5,[withDirectives(createVNode(unref(bngIcon_default),{style:{"--bng-icon-size":`1.25em`,padding:`0`},type:unref(sysInfo_default).online?unref(icons).globeSimplified:unref(icons).globeSimpleNotSign},null,8,[`type`]),[[unref(BngTooltip_default),unref(sysInfo_default).online?`Online`:`Offline`,`top`]]),(openBlock(!0),createElementBlock(Fragment,null,renderList(unref(sysInfo_default).serviceProviders.value,(info,key)=>(openBlock(),createElementBlock(Fragment,null,[unref(sysInfo_default).serviceProvidersOnline.value[key]?(openBlock(),createElementBlock(`span`,_hoisted_2$2,[createVNode(unref(bngImageAsset_default),{src:`images/mainmenu/${key}icon.png`},null,8,[`src`]),createTextVNode(` `+toDisplayString(info.playerName)+` `,1),info.branch&&info.branch!==`public`?withDirectives((openBlock(),createBlock(unref(bngIcon_default),{key:0,style:{"--bng-icon-size":`1.25em`,padding:`0`},type:unref(icons).branch},null,8,[`type`])),[[unref(BngTooltip_default),`Branch: `+info.branch,`top`]]):createCommentVNode(``,!0),createTextVNode(` `+toDisplayString(info.branch&&info.branch!==`public`?info.branch:``),1)])):createCommentVNode(``,!0)],64))),256)),unref(sysInfo_default).online||unref(sysInfo_default).serviceProvidersOnline.value.any?(openBlock(),createElementBlock(`span`,_hoisted_3$1)):createCommentVNode(``,!0),createBaseVNode(`span`,{onClick:toggleBuildInfo},[showBuildInfo.value?(openBlock(),createElementBlock(Fragment,{key:1},[createBaseVNode(`span`,_hoisted_5,`Alpha v.`+toDisplayString(unref(sysInfo_default).version),1),createBaseVNode(`span`,_hoisted_6,toDisplayString(unref(sysInfo_default).buildInfo),1)],64)):(openBlock(),createElementBlock(`span`,_hoisted_4,`Alpha v.`+toDisplayString(unref(sysInfo_default).versionSimple),1))])])):createCommentVNode(``,!0),_cache[0]||=createBaseVNode(`div`,{class:`spacer`},null,-1),unref(hints).length?(openBlock(),createElementBlock(`div`,_hoisted_7,[(openBlock(!0),createElementBlock(Fragment,null,renderList(unref(hints),item=>(openBlock(),createBlock(Hint_default,{key:item.id,data:item},null,8,[`data`]))),128))])):createCommentVNode(``,!0)],2)),[[vShow,unref(visible)],[unref(BngBlur_default),solidBar.value&&!unref(sysInfo_default).mainMenuBackgroundRequired.value]])}},InfoBar_default=__plugin_vue_export_helper_default(_sfc_main$6,[[`__scopeId`,`data-v-cb5f8971`]]),_hoisted_1$4=[`accent`],_sfc_main$5={__name:`TopBarItem`,props:{icon:{type:String,required:!0},active:{type:Boolean,default:void 0},label:String,iconOnly:Boolean,iconPosition:{type:String,default:`left`},accent:{type:String,default:`default`}},setup(__props){let props=__props,item=ref(null);return watch(()=>props.active,value=>{typeof value==`boolean`&&(value?(item.value.setAttribute(`active`,`true`),item.value.removeAttribute(NO_NAV_ATTR)):(item.value.removeAttribute(`active`),item.value.setAttribute(NO_NAV_ATTR,`true`)))}),(_ctx,_cache)=>withDirectives((openBlock(),createElementBlock(`div`,{ref_key:`item`,ref:item,class:normalizeClass([`topbar-item`,{"icon-only":__props.iconOnly}]),accent:__props.accent,"bng-nav-item":``,"bng-no-nav":`true`,tabindex:`-1`},[createVNode(unref(bngIcon_default),{class:`topbar-item-icon`,type:__props.icon},null,8,[`type`]),__props.label&&!__props.iconOnly?(openBlock(),createBlock(unref(textScroller_default),{key:0,class:`topbar-item-text`},{default:withCtx(()=>[createTextVNode(toDisplayString(_ctx.$t(__props.label)),1)]),_:1})):createCommentVNode(``,!0)],10,_hoisted_1$4)),[[unref(BngSoundClass_default),`bng_click_hover_generic`]])}},TopBarItem_default=__plugin_vue_export_helper_default(_sfc_main$5,[[`__scopeId`,`data-v-2c3015cd`]]),_hoisted_1$3={class:`topbar`},_hoisted_2$1={class:`topbar-section topbar-left`},_hoisted_3={class:`topbar-section topbar-center`},_sfc_main$4={__name:`TopBar`,setup(__props,{expose:__expose}){let topBar=useTopBar(),{visible,items:items$2,activeItem,gameState:gameState$1}=storeToRefs(topBar),overflowContainer=ref(null),pauseButtonTarget=ref(null),showTabBindings=ref(!0),showBackBinding=ref(!0),onItemClicked=item=>{activeItem.value!==item.id&&(activeItem.value=item.id,topBar.selectEntry(item.id))},backStack=new Map,customBack=null;function setBack(id,fn){if(!id)throw Error("Usage: TopBar.setBack(id, [fn]), where `id` is your unique id and `fn` is a custom back function that will fire and expected to return `true` or `false` (undefined return means `true`), which will dis-/allow the base back functionality.");typeof fn==`function`?backStack.set(id,fn):backStack.delete(id),customBack=Array.from(backStack.values()).at(-1)||null}let onBack=()=>{let res=customBack?.();res===void 0&&(res=!0),res&&(gameState$1.isInGame?window.bngVue.gotoGameState(`play`):window.globalAngularRootScope?.$broadcast(`MenuToggle`))},onContinue=()=>{window.bngVue.gotoAngularState(`play`)};return watch(()=>activeItem.value,val=>{if(activeItem.value!==null&&items$2.value.length>0){let idx=items$2.value.findIndex(item=>item.id===val);overflowContainer.value.activate(idx)}else overflowContainer.value.deactivate()}),__expose({pauseButtonTarget:computed(()=>visible.value?pauseButtonTarget.value:null),setBack,showTabBindings,showBackBinding}),onMounted(()=>{}),onUnmounted(()=>{}),(_ctx,_cache)=>withDirectives((openBlock(),createElementBlock(`div`,_hoisted_1$3,[createBaseVNode(`div`,_hoisted_2$1,[unref(gameState$1).isInGame?withDirectives((openBlock(),createBlock(unref(bngButton_default),{key:0,"track-ignore":``,accent:`custom`,class:`topbar-button`,"bng-no-nav":`true`,tabindex:`-1`,onClick:onContinue},{default:withCtx(()=>[createVNode(unref(bngIcon_default),{type:unref(icons).play},null,8,[`type`]),createVNode(unref(bngBinding_default),{"ui-event":`menu`,controller:``})]),_:1})),[[unref(BngTooltip_default),`Back to gameplay`,`right`]]):createCommentVNode(``,!0),withDirectives((openBlock(),createBlock(unref(bngButton_default),{"track-ignore":``,accent:`custom`,class:`topbar-button back-button`,"bng-no-nav":`true`,tabindex:`-1`,onClick:onBack},{default:withCtx(()=>[createVNode(unref(bngIcon_default),{type:unref(icons).undo},null,8,[`type`]),withDirectives(createVNode(unref(bngBinding_default),{"ui-event":`back`,controller:``},null,512),[[vShow,showBackBinding.value]])]),_:1})),[[unref(BngTooltip_default),`Back one level`,`right`]])]),createBaseVNode(`div`,_hoisted_3,[withDirectives(createVNode(unref(bngOverflowContainer_default),{ref_key:`overflowContainer`,ref:overflowContainer,class:`topbar-overflow-container`,"use-bindings-only":``,"show-bindings":showTabBindings.value},{default:withCtx(()=>[(openBlock(!0),createElementBlock(Fragment,null,renderList(unref(items$2),item=>(openBlock(),createBlock(TopBarItem_default,{key:item.id,icon:item.icon,label:item.label,onClick:$event=>onItemClicked(item)},null,8,[`icon`,`label`,`onClick`]))),128))]),_:1},8,[`show-bindings`]),[[vShow,unref(items$2).length>0]])]),createBaseVNode(`div`,{ref_key:`pauseButtonTarget`,ref:pauseButtonTarget,class:`topbar-section topbar-right`},null,512)])),[[vShow,unref(visible)],[unref(BngBlur_default)]])}},TopBar_default=__plugin_vue_export_helper_default(_sfc_main$4,[[`__scopeId`,`data-v-c4d95c66`]]),_sfc_main$3={__name:`Popup`,props:{type:{type:String,default:`default`,validator:val=>[`default`,`activity`].includes(val)}},setup(__props){let props=__props,popups=computed(()=>popupsView[props.type===`default`?`popups`:`activities`]),popupsWrapper=computed(()=>popupsView[props.type===`default`?`popupsWrapper`:`activitiesWrapper`]),wrapper=ref(),innerWrapper=ref(),shown=reactive({wrapper:!1,popups:!1}),tmr;watch(()=>!!popups.value,cur=>{if(cur===shown.wrapper)return;let body=document.body;cur&&popupsWrapper.value.fade?body.classList.add(`popup-all-hide`):body.classList.remove(`popup-all-hide`),tmr&&clearTimeout(tmr),cur?(shown.wrapper=!0,nextTick(()=>{props.type===`default`&&wrapper.value&&typeof wrapper.value.showModal==`function`&&wrapper.value.showModal(),nextTick(()=>shown.popups=!0)}),popupsWrapper.value.fade&&body.classList.add(`popup-show-hide`)):tmr=setTimeout(()=>{tmr=null,!popups.value&&(body.classList.remove(`popup-show-hide`),shown.popups=!1,shown.wrapper=!1,nextTick(()=>priorityFocus()))},200)});function handleUINavEvents(event){console.log(`POPUP handleUINavEvents stopPropagation`,event),event.stopPropagation()}return(_ctx,_cache)=>(openBlock(),createElementBlock(Fragment,null,[shown.wrapper?withDirectives((openBlock(),createBlock(resolveDynamicComponent(__props.type===`default`?`dialog`:`div`),{key:0,ref_key:`wrapper`,ref:wrapper,class:normalizeClass([`popup-wrapper`,`popup-type-${__props.type}`])},{default:withCtx(()=>[createVNode(Transition,{name:`popup-background`},{default:withCtx(()=>[shown.popups?(openBlock(),createElementBlock(`div`,{key:0,class:normalizeClass([`popup-background`,...popupsWrapper.value.style.map(name=>`background-style-`+name)])},null,2)):createCommentVNode(``,!0)]),_:1}),createVNode(TransitionGroup,{name:`popup-fade`},{default:withCtx(()=>[shown.popups?(openBlock(!0),createElementBlock(Fragment,{key:0},renderList(popups.value,popup=>(openBlock(),createElementBlock(`div`,{key:popup.id,class:normalizeClass([`popup-container`,...popup.position.map(name=>`content-position-`+name),popup.animated?`popup-animated`:`popup-notanimated`,popup.active?`popup-active`:`popup-inactive`])},[(openBlock(),createBlock(resolveDynamicComponent(popup.component.ref),mergeProps({ref_for:!0},popup.props,{popupActive:popup.active,class:[`popup-content`,popup.active?`popup-active`:`popup-inactive`],onReturn:popup.return}),null,16,[`popupActive`,`class`,`onReturn`]))],2))),128)):createCommentVNode(``,!0)]),_:1}),createBaseVNode(`div`,{ref_key:`innerWrapper`,ref:innerWrapper},null,512)]),_:1},8,[`class`])),[[unref(BngBlur_default),popupsWrapper.value.blur],[unref(BngOnUiNav_default),handleUINavEvents,`back,menu`]]):createCommentVNode(``,!0),(openBlock(),createBlock(Teleport,{to:innerWrapper.value,disabled:!innerWrapper.value},[renderSlot(_ctx.$slots,`default`,{},void 0,!0)],8,[`to`,`disabled`]))],64))}},Popup_default=__plugin_vue_export_helper_default(_sfc_main$3,[[`__scopeId`,`data-v-c0bb08d7`]]),_hoisted_1$2={class:`popover-container`},_sfc_main$2={__name:`Popover`,setup(__props){return usePopover(),(_ctx,_cache)=>(openBlock(),createElementBlock(`div`,_hoisted_1$2))}},Popover_default=__plugin_vue_export_helper_default(_sfc_main$2,[[`__scopeId`,`data-v-86205238`]]),_hoisted_1$1={class:`backgrounds-cache`},_hoisted_2=[`src`],DRIVE=8,TECH=1,_sfc_main$1={__name:`MainBackground`,setup(__props,{expose:__expose}){let bgPathResolve=(product,name,blur$1=!1)=>`images/mainmenu/${product?product+`/`:``}${name}${blur$1?`_blur`:``}.jpg`,_backgrounds={drive:Array.from({length:DRIVE},(_,i)=>bgPathResolve(`drive`,i+1)),drive_blur:Array.from({length:DRIVE},(_,i)=>bgPathResolve(`drive`,i+1,!0)),tech:Array.from({length:TECH},(_,i)=>bgPathResolve(`tech`,i+1)),tech_blur:Array.from({length:TECH},(_,i)=>bgPathResolve(`tech`,i+1,!0)),unofficial:[bgPathResolve(null,`unofficial_version`)],unofficial_blur:[bgPathResolve(null,`unofficial_version`,!0)]},backgroundId=ref(`drive`),backgrounds=computed(()=>({normal:_backgrounds[backgroundId.value],blur:_backgrounds[backgroundId.value+`_blur`]})),carousel=ref();return __expose({carousel:computed(()=>carousel.value),backgrounds:computed(()=>backgrounds.value)}),onMounted(async()=>{let isTech=await Lua_default.extensions.tech_license.isValid();backgroundId.value=isTech?`tech`:`drive`,bngApi.engineLua(`sailingTheHighSeas`,ahoy=>{backgroundId.value=ahoy?`unofficial`:isTech?`tech`:`drive`})}),(_ctx,_cache)=>(openBlock(),createElementBlock(Fragment,null,[createVNode(Slideshow_default,{class:`background-image`,ref_key:`carousel`,ref:carousel,images:backgrounds.value.normal,delay:1e4,transition:``,shuffle:``},null,8,[`images`]),(openBlock(!0),createElementBlock(Fragment,null,renderList(backgrounds.value,list=>(openBlock(),createElementBlock(`div`,_hoisted_1$1,[(openBlock(!0),createElementBlock(Fragment,null,renderList(list,src=>(openBlock(),createElementBlock(`img`,{src:unref(getAssetURL)(src)},null,8,_hoisted_2))),256))]))),256))],64))}},MainBackground_default=__plugin_vue_export_helper_default(_sfc_main$1,[[`__scopeId`,`data-v-6c1f834b`]]),_hoisted_1={id:`vue-app-container`},_sfc_main={__name:`App`,setup(__props){let route=useRoute(),settings$1=useSettings(),bngVue$1=window.bngVue||{},apps=ref([]),appContCnt=ref(0),appTargets=computed(()=>apps.value.reduce((res,{teleport})=>({...res,[teleport]:document.getElementById(teleport.substring(1)),cnt:appContCnt.value}),{}));bngVue$1.updateAppContainer=()=>window.requestAnimationFrame(()=>appContCnt.value=++appContCnt.value%1e5);let contClickThrough=ref(!1);bngVue$1.gotoAngularState=(state=`blank`,params=void 0)=>window.angular&&window.angular.element(document.querySelector(`body`)).controller().changeAngularStateFromVue(state,params),bngVue$1.gotoGameState=(state=`ui-test`,{params=!1,tryAngularJS=!0,blankAngularJS=!0,clickThrough=!1,uiAppsShown=!1}={})=>{let a$1=history.state;if(!router_default.hasRoute(state))window.location.hash=`#/`+state,route&&(handleUiAppsMeta(route,uiAppsShown),router_default.bngUpdateMeta(route)),tryAngularJS&&bngVue$1.gotoAngularState(state,params);else{blankAngularJS&&bngVue$1.gotoAngularState(`blank`);let newroute=router_default.resolve({name:state,params});handleUiAppsMeta(newroute,uiAppsShown),newroute.name===route.name&&router_default.bngUpdateMeta(route),window.location.hash=newroute.href,router_default.replace({name:state,params})}history.replaceState(a$1,``,window.location.toString()),contClickThrough.value=clickThrough};function handleUiAppsMeta(route$1,uiAppsShown){route$1.meta?route$1.meta.uiApps||(route$1.meta.uiApps={}):route$1.meta={uiApps:{}},typeof route$1.meta.uiApps.shown!=`boolean`&&(route$1.meta.uiApps.shown=uiAppsShown)}bngVue$1.getCurrentRoute=()=>router_default.currentRoute.value,bngVue$1.spawnApp=(appName,appId,params=null)=>spawnUiApp(appName,appId,params,apps.value),bngVue$1.destroyApp=appName=>destroyUiApp(appName,apps.value),useFocusManager();let topBar=ref();provide(`setBack`,(id,fn)=>topBar.value?.setBack(id,fn)),provide(`showTopbarTabBindings`,val=>topBar.value&&(topBar.value.showTabBindings=val)),provide(`showTopbarBackBinding`,val=>topBar.value&&(topBar.value.showBackBinding=val));let bgRequired=sysInfo_default.mainMenuBackgroundRequired,mainBackground=ref();return provide(`mainBackground`,computed(()=>mainBackground.value?.carousel)),provide(`mainBackgroundBlur`,computed(()=>mainBackground.value?.backgrounds.blur)),watch([()=>settings$1.values.uiLayoutContentAlignment,()=>settings$1.values.uiLayoutContentWidth],([alignment,width$1])=>{let rootStyle=document.documentElement.style;alignment=LAYOUT_ALIGNMENTS[alignment||`center`],width$1=width$1?`${width$1}px`:`100vw`,window.requestAnimationFrame(()=>{rootStyle.setProperty(`--layout-content-alignment`,alignment),rootStyle.setProperty(`--layout-content-width`,width$1)})},{immediate:!0}),(_ctx,_cache)=>{let _component_router_view=resolveComponent(`router-view`);return openBlock(),createElementBlock(Fragment,null,[unref(bgRequired)?(openBlock(),createBlock(MainBackground_default,{key:0,ref_key:`mainBackground`,ref:mainBackground},null,512)):createCommentVNode(``,!0),unref(route).name===`unknown`?createCommentVNode(``,!0):(openBlock(),createElementBlock(`div`,{key:1,class:normalizeClass({"vue-app-main":!0,"click-through":contClickThrough.value||unref(route).meta&&unref(route).meta.clickThrough})},[createVNode(TopBar_default,{ref_key:`topBar`,ref:topBar},null,512),createVNode(_component_router_view),createVNode(InfoBar_default)],2)),createVNode(pauseButton_default,{"teleport-to":topBar.value?.pauseButtonTarget},null,8,[`teleport-to`]),unref(route).name===`unknown`?(openBlock(),createBlock(Popup_default,{key:2,type:`activity`})):createCommentVNode(``,!0),createVNode(Popup_default,null,{default:withCtx(()=>[createVNode(Popover_default)]),_:1}),createVNode(LoadingScreen_default),createVNode(VueDebug_default),createBaseVNode(`div`,_hoisted_1,[(openBlock(!0),createElementBlock(Fragment,null,renderList(apps.value,(app$1,index)=>(openBlock(),createElementBlock(Fragment,{key:app$1.appKey},[appTargets.value[app$1.teleport]?(openBlock(),createBlock(Teleport,{key:0,to:app$1.teleport},[(openBlock(),createBlock(resolveDynamicComponent(app$1.comp),mergeProps({ref_for:!0},app$1.props),null,16))],8,[`to`])):createCommentVNode(``,!0)],64))),128))])],64)}}},App_default=__plugin_vue_export_helper_default(_sfc_main,[[`__scopeId`,`data-v-eef28b65`]]);function customDisposePlugin(context){let store$1=context.store,{$dispose,dispose:dispose$2}=store$1;store$1.$dispose=()=>{$dispose(),dispose$2&&typeof dispose$2==`function`&&dispose$2()}}window.watchdogInit=init,window.Vue=vue_esm_bundler_exports;var deps={Emitter:eventemitter3_default,beamng:window.beamng};window.bngApi&&(deps.overrideAPI=window.bngApi),setBridgeDependencies(deps);var bridge=useBridge();window.bridge=bridge,sysInfo_default.init(),initFocusVisible(),bridge.uiNavService=new UINavService(bridge.events),setUINavServiceInstance(bridge.uiNavService),bridge.uiNavService.initialize();var pinia=createPinia().use(()=>({$game:bridge})).use(customDisposePlugin),app=createApp(App_default).use(router_default).use(pinia).use(registerApps,apps_exports);useGameContextStore(),window.bngVue={start:()=>{window.vueGlobalStore||(window.vueGlobalStore=reactive({}));let globals={$game:bridge,$console:logger_default,$logger:logger_default,$simplemenu:ref(!!window.beamng?.simplemenu),$globalStore:window.vueGlobalStore},{i18n,plugin:translationPlugin$1}=initTranslation();app.use(i18n).use(translationPlugin$1());for(let[key,value]of Object.entries(globals))app.config.globalProperties[key]=value,app.provide(key,value);app.mount(`#vue-app`);let controlsStore=controls_default();window.bngVue.controls={getControllers:()=>controlsStore.controllers,getPlayers:()=>controlsStore.players,getCategories:()=>controlsStore.categories,getCategoriesList:()=>controlsStore.categoriesList,findBindingForAction:controlsStore.findBindingForAction,getActionDetails:controlsStore.getActionDetails,getBindingDetails:controlsStore.getBindingDetails,getAllBindingsForAction:controlsStore.getAllBindingsForAction,addNewBinding:controlsStore.addNewBinding,updateBinding:controlsStore.updateBinding,deleteBinding:controlsStore.deleteBinding,deleteBindings:controlsStore.deleteBindings,deviceIcon:controlsStore.deviceIcon,isFFBBound:controlsStore.isFFBBound,isFFBEnabled:controlsStore.isFFBEnabled,isFFBCapable:controlsStore.isFFBCapable,isGamepadAvailable:controlsStore.isGamepadAvailable,captureBinding:controlsStore.captureBinding,makeViewerObj:controlsStore.makeViewerObj,isControllerAvailable:controlsStore.isControllerAvailable,isControllerUsed:controlsStore.isControllerUsed,showIfController:controlsStore.showIfController,focusIfController:controlsStore.focusIfController,refreshData:()=>bridge.lua.extensions.core_input_bindings.notifyUI(`Vue exposed controls service needs the data`)},window.bngVue.uiNavTracker=useUINavTracker(),window.bngVue.topBar=useTopBar()},startTest:()=>{app.mount(`#vue-app`)},isProd:!0,icons},window.beamng||window.bngVue.start({i18n:window.i18n});
    @/lua/vehicle/controller/bypassDampers.lua
    
    local function update(dt)
      for _, damper in ipairs(dampers) do
    @/inspector/Workers/HeapSnapshot/HeapSnapshot.js
    
        update()
        {
    
        update()
        {
    @/lua/vehicle/controller/drivingDynamics/sensors/virtualSensors.lua
    
    local function update(dt)
      local sensorHub = CMU.sensorHub
    local function updateDebug(dt)
      update(dt)
      local reference = M.reference
    @/lua/ge/extensions/freeroam/bigMapMarkers.lua
            --print("updating: " .. marker.id .. " ("..marker.cluster.id..")")
            marker:update(updateData)
          end
      for clusterId, marker in pairs(oldMarkersByClusterId) do
        marker:update(updateData)
      end
    @/lua/vehicle/energyStorage/pressureTank.lua
      if not molarQuantity then
        -- if molar quantity is not provided, compute the amount of gas in the tank as per the last update (using previous env temperature)
        -- moles (n) = PV / RT; PV = energy, therefore n = e / RT
    @/lua/ge/extensions/editor/gen/decal.lua
    
    local function update(rd)
        if not rd then rd = croad end
        --            lo('?? key_R2:'..#anode..':'..anode[1].width..':'..croad:getNodeWidth(0))
        --            update(croad)
        --            anode = editor.getNodes(croad)
    @/ui/ui-vue/src/bridge/libs/GameBlurrer.js
    
      update(id, coord) {
        if (!(id in blurRegionList)) throw new Error(`Trying to update bng-blur with an ID that is not registered: ${id} (of ${Object.keys(blurRegionList)})`)
    @/lua/ge/simTimeAuthority.lua
    -- the extension system registers the function pointers, thus functions called back by it cannot be nop'ed. So we wrap it in another function.
    local function update(...)
      updateDispatch(...)
    @/lua/ge/extensions/scenario/race_marker.lua
      for _, m in pairs(idToMarker) do
        m:update(dt, dtSim)
      end
    @/lua/common/utils/filterchain.lua
        })
        dump(f:update(0.5, 1))
        dump(f:update(0.5, 2))
        dump(f:update(0.5, 1))
        dump(f:update(0.5, 2))
        dump(f:update(0.5, 3))
        dump(f:update(0.5, 2))
        dump(f:update(0.5, 3))
        dump(f:update(0.5, 4))
        dump(f:update(0.5, 3))
        dump(f:update(0.5, 4))
        dump(f:update(0.5, 5))
        dump(f:update(0.5, 4))
        dump(f:update(0.5, 5))
    ]]
            timer = timer + dt
            dump(led1:update(dt, 1))
            --local out = led1:update(dt, 1, 2, 3)
            dump(led1:update(dt, 1))
            --local out = led1:update(dt, 1, 2, 3)
            --print('### ' .. timer .. ' = ' .. dumps(unpack({out})))
    @/lua/ge/extensions/gameplay/markers/inspectVehicleMarker.lua
    
    function C:update(data)
      if not self.visible then return end
    @/lua/vehicle/controller/tech/vehicleSystemsCoupling.lua
    -- Update function. This is called on every physics step update, once the controller has been loaded.
    local function update(dt)
      if debugFile then
    @/lua/vehicle/controller/dragTimer.lua
    
    local function update(dt)
      local throttle = electrics.values.throttle or 0
    @/lua/ge/extensions/util/vehicleRopeDebug.lua
          if im.IsItemHovered() then
            im.SetTooltip("Solver iterations per update (1-10)")
          end
    @/lua/vehicle/controller/inputOutputDemo.lua
    
    --This runs at a fixed 100hz. (derived from 2000hz physics step, see note about performance on update())
    local function updateFixedStep(dt)
    --like disk IO in anything that is/derives from the 2000hz update
    local function update(dt)
      --increment timer with passed time since last call, depending on where this is called (update, updateFixedStep, updateGFX the resolution of time keeping changes)
    @/inspector/External/CodeMirror/mark-selection.js
      function onCursorActivity(cm) {
        cm.operation(function() { update(cm); });
      }
    
      function update(cm) {
        if (!cm.somethingSelected()) return clear(cm);
    @/inspector/External/three.js/OrbitControls.js
        // Set to true to enable damping (inertia)
        // If damping is enabled, you must call controls.update() in your animation loop
        this.enableDamping = false;
        // Set to true to automatically rotate around the target
        // If auto-rotate is enabled, you must call controls.update() in your animation loop
        this.autoRotate = false;
    
            scope.update();
    
    
            return function update() {
    
    
            scope.update();
    
    
            scope.update();
    
    
            scope.update();
    
    
            scope.update();
    
                    pan( 0, scope.keyPanSpeed );
                    scope.update();
                    break;
                    pan( 0, - scope.keyPanSpeed );
                    scope.update();
                    break;
                    pan( scope.keyPanSpeed, 0 );
                    scope.update();
                    break;
                    pan( - scope.keyPanSpeed, 0 );
                    scope.update();
                    break;
    
            scope.update();
    
    
            scope.update();
    
    
        this.update();
    
    @/ui/lib/ext/angular-ui-router.min.js
     */
    "undefined"!=typeof module&&"undefined"!=typeof exports&&module.exports===exports&&(module.exports="ui.router"),function(a,b,c){"use strict";function d(a,b){return S(new(S(function(){},{prototype:a})),b)}function e(a){return R(arguments,function(b){b!==a&&R(b,function(b,c){a.hasOwnProperty(c)||(a[c]=b)})}),a}function f(a,b){var c=[];for(var d in a.path){if(a.path[d]!==b.path[d])break;c.push(a.path[d])}return c}function g(a){if(Object.keys)return Object.keys(a);var b=[];return R(a,function(a,c){b.push(c)}),b}function h(a,b){if(Array.prototype.indexOf)return a.indexOf(b,Number(arguments[2])||0);var c=a.length>>>0,d=Number(arguments[2])||0;for(d=d<0?Math.ceil(d):Math.floor(d),d<0&&(d+=c);d=0||(k.push(e[m]),j[e[m]]=a[e[m]]);return S({},j,b)}function j(a,b,c){if(!c){c=[];for(var d in a)c.push(d)}for(var e=0;e "));if(s[c]=d,O(a))q.push(c,[function(){return b.get(a)}],j);else{var e=b.annotate(a);R(e,function(a){a!==c&&i.hasOwnProperty(a)&&n(i[a],a)}),q.push(c,a,e)}r.pop(),s[c]=f}}function o(a){return P(a)&&a.then&&a.$$promises}if(!P(i))throw new Error("'invocables' must be an object");var p=g(i||{}),q=[],r=[],s={};return R(i,n),i=r=s=null,function(d,f,g){function h(){--u||(v||e(t,f.$$values),r.$$values=t,r.$$promises=r.$$promises||!0,delete r.$$inheritedValues,n.resolve(t))}function i(a){r.$$failure=a,n.reject(a)}function j(c,e,f){function j(a){l.reject(a),i(a)}function k(){if(!M(r.$$failure))try{l.resolve(b.invoke(e,g,t)),l.promise.then(function(a){t[c]=a,h()},j)}catch(a){j(a)}}var l=a.defer(),m=0;R(f,function(a){s.hasOwnProperty(a)&&!d.hasOwnProperty(a)&&(m++,s[a].then(function(b){t[a]=b,--m||k()},j))}),m||k(),s[c]=l.promise}if(o(d)&&g===c&&(g=f,f=d,d=null),d){if(!P(d))throw new Error("'locals' must be an object")}else d=k;if(f){if(!o(f))throw new Error("'parent' must be a promise returned by $resolve.resolve()")}else f=l;var n=a.defer(),r=n.promise,s=r.$$promises={},t=S({},d),u=1+q.length/3,v=!1;if(M(f.$$failure))return i(f.$$failure),r;f.$$inheritedValues&&e(t,m(f.$$inheritedValues,p)),S(s,f.$$promises),f.$$values?(v=e(t,m(f.$$values,p)),r.$$inheritedValues=m(f.$$values,p),h()):(f.$$inheritedValues&&(r.$$inheritedValues=m(f.$$inheritedValues,p)),f.then(h,i));for(var w=0,x=q.length;w=0));)s=f(r.id,r.type,r.cfg,"path"),l+=g(r.segment,s.type.pattern.source,s.squash,s.isOptional),n.push(r.segment),m=j.lastIndex;t=a.substring(m);var u=t.indexOf("?");if(u>=0){var v=this.sourceSearch=t.substring(u);if(t=t.substring(0,u),this.sourcePath=a.substring(0,m+u),v.length>0)for(m=0;i=k.exec(v);)r=h(i,!0),s=f(r.id,r.type,r.cfg,"search"),m=j.lastIndex}else this.sourcePath=a,this.sourceSearch="";l+=g(t)+(b.strict===!1?"/?":"")+"$",n.push(t),this.regexp=new RegExp(l,b.caseInsensitive?"i":c),this.prefix=n[0],this.$$paramNames=q}function t(a){S(this,a)}function u(){function a(a){return null!=a?a.toString().replace(/(~|\/)/g,function(a){return{"~":"~~","/":"~2F"}[a]}):a}function e(a){return null!=a?a.toString().replace(/(~~|~2F)/g,function(a){return{"~~":"~","~2F":"/"}[a]}):a}function f(){return{strict:p,caseInsensitive:m}}function i(a){return N(a)||Q(a)&&N(a[a.length-1])}function j(){for(;w.length;){var a=w.shift();if(a.pattern)throw new Error("You cannot override a type's .pattern at runtime.");b.extend(r[a.name],l.invoke(a.def))}}function k(a){S(this,a||{})}V=this;var l,m=!1,p=!0,q=!1,r={},v=!0,w=[],x={string:{encode:a,decode:e,is:function(a){return null==a||!M(a)||"string"==typeof a},pattern:/[^\/]*/},int:{encode:a,decode:function(a){return parseInt(a,10)},is:function(a){return M(a)&&this.decode(a.toString())===a},pattern:/\d+/},bool:{encode:function(a){return a?1:0},decode:function(a){return 0!==parseInt(a,10)},is:function(a){return a===!0||a===!1},pattern:/0|1/},date:{encode:function(a){return this.is(a)?[a.getFullYear(),("0"+(a.getMonth()+1)).slice(-2),("0"+a.getDate()).slice(-2)].join("-"):c},decode:function(a){if(this.is(a))return a;var b=this.capture.exec(a);return b?new Date(b[1],b[2]-1,b[3]):c},is:function(a){return a instanceof Date&&!isNaN(a.valueOf())},equals:function(a,b){return this.is(a)&&this.is(b)&&a.toISOString()===b.toISOString()},pattern:/[0-9]{4}-(?:0[1-9]|1[0-2])-(?:0[1-9]|[1-2][0-9]|3[0-1])/,capture:/([0-9]{4})-(0[1-9]|1[0-2])-(0[1-9]|[1-2][0-9]|3[0-1])/},json:{encode:b.toJson,decode:b.fromJson,is:b.isObject,equals:b.equals,pattern:/[^\/]*/},any:{encode:b.identity,decode:b.identity,equals:b.equals,pattern:/.*/}};u.$$getDefaultValue=function(a){if(!i(a.value))return a.value;if(!l)throw new Error("Injectable functions cannot be called at configuration time");return l.invoke(a.value)},this.caseInsensitive=function(a){return M(a)&&(m=a),m},this.strictMode=function(a){return M(a)&&(p=a),p},this.defaultSquashPolicy=function(a){if(!M(a))return q;if(a!==!0&&a!==!1&&!O(a))throw new Error("Invalid squash policy: "+a+". Valid policies: false, true, arbitrary-string");return q=a,a},this.compile=function(a,b){return new s(a,S(f(),b))},this.isMatcher=function(a){if(!P(a))return!1;var b=!0;return R(s.prototype,function(c,d){N(c)&&(b=b&&M(a[d])&&N(a[d]))}),b},this.type=function(a,b,c){if(!M(b))return r[a];if(r.hasOwnProperty(a))throw new Error("A type named '"+a+"' has already been defined.");return r[a]=new t(S({name:a},b)),c&&(w.push({name:a,def:c}),v||j()),this},R(x,function(a,b){r[b]=new t(S({name:b},a))}),r=d(r,{}),this.$get=["$injector",function(a){return l=a,v=!1,j(),R(x,function(a,b){r[b]||(r[b]=new t(a))}),this}],this.Param=function(a,d,e,f){function j(a){var b=P(a)?g(a):[],c=h(b,"value")===-1&&h(b,"type")===-1&&h(b,"squash")===-1&&h(b,"array")===-1;return c&&(a={value:a}),a.$$fn=i(a.value)?a.value:function(){return a.value},a}function k(c,d,e){if(c.type&&d)throw new Error("Param '"+a+"' has two type configurations.");return d?d:c.type?b.isString(c.type)?r[c.type]:c.type instanceof t?c.type:new t(c.type):"config"===e?r.any:r.string}function m(){var b={array:"search"===f&&"auto"},c=a.match(/\[\]$/)?{array:!0}:{};return S(b,c,e).array}function p(a,b){var c=a.squash;if(!b||c===!1)return!1;if(!M(c)||null==c)return q;if(c===!0||O(c))return c;throw new Error("Invalid squash policy: '"+c+"'. Valid policies: false, true, or arbitrary string")}function s(a,b,d,e){var f,g,i=[{from:"",to:d||b?c:""},{from:null,to:d||b?c:""}];return f=Q(a.replace)?a.replace:[],O(e)&&f.push({from:e,to:c}),g=o(f,function(a){return a.from}),n(i,function(a){return h(g,a.from)===-1}).concat(f)}function u(){if(!l)throw new Error("Injectable functions cannot be called at configuration time");var a=l.invoke(e.$$fn);if(null!==a&&a!==c&&!x.type.is(a))throw new Error("Default value ("+a+") for parameter '"+x.id+"' is not an instance of Type ("+x.type.name+")");return a}function v(a){function b(a){return function(b){return b.from===a}}function c(a){var c=o(n(x.replace,b(a)),function(a){return a.to});return c.length?c[0]:a}return a=c(a),M(a)?x.type.$normalize(a):u()}function w(){return"{Param:"+a+" "+d+" squash: '"+A+"' optional: "+z+"}"}var x=this;e=j(e),d=k(e,d,f);var y=m();d=y?d.$asArray(y,"search"===f):d,"string"!==d.name||y||"path"!==f||e.value!==c||(e.value="");var z=e.value!==c,A=p(e,z),B=s(e,y,z,A);S(this,{id:a,type:d,location:f,array:y,squash:A,replace:B,isOptional:z,value:v,dynamic:c,config:e,toString:w})},k.prototype={$$new:function(){return d(this,S(new k,{$$parent:this}))},$$keys:function(){for(var a=[],b=[],c=this,d=g(k.prototype);c;)b.push(c),c=c.$$parent;return b.reverse(),R(b,function(b){R(g(b),function(b){h(a,b)===-1&&h(d,b)===-1&&a.push(b)})}),a},$$values:function(a){var b={},c=this;return R(c.$$keys(),function(d){b[d]=c[d].value(a&&a[d])}),b},$$equals:function(a,b){var c=!0,d=this;return R(d.$$keys(),function(e){var f=a&&a[e],g=b&&b[e];d[e].type.equals(f,g)||(c=!1)}),c},$$validates:function(a){var d,e,f,g,h,i=this.$$keys();for(d=0;d=0)throw new Error("State must have a valid name");if(A.hasOwnProperty(c))throw new Error("State '"+c+"' is already defined");var e=c.indexOf(".")!==-1?c.substring(0,c.lastIndexOf(".")):O(b.parent)?b.parent:P(b.parent)&&O(b.parent.name)?b.parent.name:"";if(e&&!A[e])return n(e,b.self);for(var f in D)N(D[f])&&(b[f]=D[f](b,D.$delegates[f]));return A[c]=b,!b[C]&&b.url&&a.when(b.url,["$match","$stateParams",function(a,c){z.$current.navigable==b&&j(a,c)||z.transitionTo(b,a,{inherit:!0,location:!1})}]),q(c),b}function s(a){return a.indexOf("*")>-1}function t(a){for(var b=a.split("."),c=z.$current.name.split("."),d=0,e=b.length;d=A;d--)g=o[d],g.self.onExit&&h.invoke(g.self.onExit,g.self,g.locals.globals),g.locals=null;for(d=A;d2?k.enter(a,null,c).then(d):k.enter(a,null,c,d)},leave:function(a,c){b.version.minor>2?k.leave(a).then(c):k.leave(a,c)}};if(j){var e=j&&j(c,a);return{enter:function(a,b,c){e.enter(a,null,b),c()},leave:function(a,b){e.leave(a),b()}}}return d()}var i=g(),j=i("$animator"),k=i("$animate"),l={restrict:"ECA",terminal:!0,priority:400,transclude:"element",compile:function(c,g,i){return function(c,g,j){function k(){if(m&&(m.remove(),m=null),o&&(o.$destroy(),o=null),n){var a=n.data("$uiViewAnim");s.leave(n,function(){a.$$animLeave.resolve(),m=null}),m=n,n=null}}function l(h){var l,m=B(c,j,g,e),t=m&&a.$current&&a.$current.locals[m];if(h||t!==p){l=c.$new(),p=a.$current.locals[m],l.$emit("$viewContentLoading",m);var u=i(l,function(a){var e=f.defer(),h=f.defer(),i={$animEnter:e.promise,$animLeave:h.promise,$$animLeave:h};a.data("$uiViewAnim",i),s.enter(a,g,function(){e.resolve(),o&&o.$emit("$viewContentAnimationEnded"),(b.isDefined(r)&&!r||c.$eval(r))&&d(a)}),k()});n=u,o=l,o.$emit("$viewContentLoaded",m),o.$eval(q)}}var m,n,o,p,q=j.onload||"",r=j.autoscroll,s=h(j,c);g.inheritedData("$uiView");c.$on("$stateChangeSuccess",function(){l(!1)}),l(!0)}}};return l}function A(a,c,d,e){return{restrict:"ECA",priority:-400,compile:function(f){var g=f.html();return function(f,h,i){var j=d.$current,k=B(f,i,h,e),l=j&&j.locals[k];if(l){h.data("$uiView",{name:k,state:l.$$state}),h.html(l.$template?l.$template:g);var m=b.extend({},l);f[l.$$resolveAs]=m;var n=a(h.contents());if(l.$$controller){l.$scope=f,l.$element=h;var o=c(l.$$controller,l);l.$$controllerAs&&(f[l.$$controllerAs]=o,f[l.$$controllerAs][l.$$resolveAs]=m),N(o.$onInit)&&o.$onInit(),h.data("$ngControllerController",o),h.children().data("$ngControllerController",o)}n(f)}}}}}function B(a,b,c,d){var e=d(b.uiView||b.name||"")(a),f=c.inheritedData("$uiView");return e.indexOf("@")>=0?e:e+"@"+(f?f.state.name:"")}function C(a,b){var c,d=a.match(/^\s*({[^}]*})\s*$/);if(d&&(a=b+"("+d[1]+")"),c=a.replace(/\n/g," ").match(/^([^(]+?)\s*(\((.*)\))?$/),!c||4!==c.length)throw new Error("Invalid state ref '"+a+"'");return{state:c[1],paramExpr:c[3]||null}}function D(a){var b=a.parent().inheritedData("$uiView");if(b&&b.state&&b.state.name)return b.state}function E(a){var b="[object SVGAnimatedString]"===Object.prototype.toString.call(a.prop("href")),c="FORM"===a[0].nodeName;return{attr:c?"action":b?"xlink:href":"href",isAnchor:"A"===a.prop("tagName").toUpperCase(),clickable:!c}}function F(a,b,c,d,e){return function(f){var g=f.which||f.button,h=e();if(!(g>1||f.ctrlKey||f.metaKey||f.shiftKey||a.attr("target"))){var i=c(function(){b.go(h.state,h.params,h.options)});f.preventDefault();var j=d.isAnchor&&!h.href?1:0;f.preventDefault=function(){j--<=0&&c.cancel(i)}}}}function G(a,b){return{relative:D(a)||b.$current,inherit:!0}}function H(a,c){return{restrict:"A",require:["?^uiSrefActive","?^uiSrefActiveEq"],link:function(d,e,f,g){var h,i=C(f.uiSref,a.current.name),j={state:i.state,href:null,params:null},k=E(e),l=g[1]||g[0],m=null;j.options=S(G(e,a),f.uiSrefOpts?d.$eval(f.uiSrefOpts):{});var n=function(c){c&&(j.params=b.copy(c)),j.href=a.href(i.state,j.params,j.options),m&&m(),l&&(m=l.$$addStateInfo(i.state,j.params)),null!==j.href&&f.$set(k.attr,j.href)};i.paramExpr&&(d.$watch(i.paramExpr,function(a){a!==j.params&&n(a)},!0),j.params=b.copy(d.$eval(i.paramExpr))),n(),k.clickable&&(h=F(e,a,c,k,function(){return j}),e[e.on?"on":"bind"]("click",h),d.$on("$destroy",function(){e[e.off?"off":"unbind"]("click",h)}))}}}function I(a,b){return{restrict:"A",require:["?^uiSrefActive","?^uiSrefActiveEq"],link:function(c,d,e,f){function g(b){m.state=b[0],m.params=b[1],m.options=b[2],m.href=a.href(m.state,m.params,m.options),n&&n(),j&&(n=j.$$addStateInfo(m.state,m.params)),m.href&&e.$set(i.attr,m.href)}var h,i=E(d),j=f[1]||f[0],k=[e.uiState,e.uiStateParams||null,e.uiStateOpts||null],l="["+k.map(function(a){return a||"null"}).join(", ")+"]",m={state:null,params:null,options:null,href:null},n=null;c.$watch(l,g,!0),g(c.$eval(l)),i.clickable&&(h=F(d,a,b,i,function(){return m}),d[d.on?"on":"bind"]("click",h),c.$on("$destroy",function(){d[d.off?"off":"unbind"]("click",h)}))}}}function J(a,b,c){return{restrict:"A",controller:["$scope","$element","$attrs","$timeout",function(b,d,e,f){function g(b,c,e){var f=a.get(b,D(d)),g=h(b,c),i={state:f||{name:b},params:c,hash:g};return p.push(i),q[g]=e,function(){var a=p.indexOf(i);a!==-1&&p.splice(a,1)}}function h(a,c){if(!O(a))throw new Error("state should be a string");return P(c)?a+U(c):(c=b.$eval(c),P(c)?a+U(c):a)}function i(){for(var a=0;a0)){var c=g(a,b,o);return i(),c}},b.$on("$stateChangeSuccess",i),i()}]}}function K(a){var b=function(b,c){return a.is(b,c)};return b.$stateful=!0,b}function L(a){var b=function(b,c,d){return a.includes(b,c,d)};return b.$stateful=!0,b}var M=b.isDefined,N=b.isFunction,O=b.isString,P=b.isObject,Q=b.isArray,R=b.forEach,S=b.extend,T=b.copy,U=b.toJson;b.module("ui.router.util",["ng"]),b.module("ui.router.router",["ui.router.util"]),b.module("ui.router.state",["ui.router.router","ui.router.util"]),b.module("ui.router",["ui.router.state"]),b.module("ui.router.compat",["ui.router"]),q.$inject=["$q","$injector"],b.module("ui.router.util").service("$resolve",q),r.$inject=["$http","$templateCache","$injector"],b.module("ui.router.util").service("$templateFactory",r);var V;s.prototype.concat=function(a,b){var c={caseInsensitive:V.caseInsensitive(),strict:V.strictMode(),squash:V.defaultSquashPolicy()};return new s(this.sourcePath+a+this.sourceSearch,S(c,b),this)},s.prototype.toString=function(){return this.source},s.prototype.exec=function(a,b){function c(a){function b(a){return a.split("").reverse().join("")}function c(a){return a.replace(/\\-/g,"-")}var d=b(a).split(/-(?!\\)/),e=o(d,b);return o(e,c).reverse()}var d=this.regexp.exec(a);if(!d)return null;b=b||{};var e,f,g,h=this.parameters(),i=h.length,j=this.segments.length-1,k={};if(j!==d.length-1)throw new Error("Unbalanced capture group in route '"+this.source+"'");var l,m;for(e=0;e
     */
    "undefined"!=typeof module&&"undefined"!=typeof exports&&module.exports===exports&&(module.exports="ui.router"),function(a,b,c){"use strict";function d(a,b){return S(new(S(function(){},{prototype:a})),b)}function e(a){return R(arguments,function(b){b!==a&&R(b,function(b,c){a.hasOwnProperty(c)||(a[c]=b)})}),a}function f(a,b){var c=[];for(var d in a.path){if(a.path[d]!==b.path[d])break;c.push(a.path[d])}return c}function g(a){if(Object.keys)return Object.keys(a);var b=[];return R(a,function(a,c){b.push(c)}),b}function h(a,b){if(Array.prototype.indexOf)return a.indexOf(b,Number(arguments[2])||0);var c=a.length>>>0,d=Number(arguments[2])||0;for(d=d<0?Math.ceil(d):Math.floor(d),d<0&&(d+=c);d=0||(k.push(e[m]),j[e[m]]=a[e[m]]);return S({},j,b)}function j(a,b,c){if(!c){c=[];for(var d in a)c.push(d)}for(var e=0;e "));if(s[c]=d,O(a))q.push(c,[function(){return b.get(a)}],j);else{var e=b.annotate(a);R(e,function(a){a!==c&&i.hasOwnProperty(a)&&n(i[a],a)}),q.push(c,a,e)}r.pop(),s[c]=f}}function o(a){return P(a)&&a.then&&a.$$promises}if(!P(i))throw new Error("'invocables' must be an object");var p=g(i||{}),q=[],r=[],s={};return R(i,n),i=r=s=null,function(d,f,g){function h(){--u||(v||e(t,f.$$values),r.$$values=t,r.$$promises=r.$$promises||!0,delete r.$$inheritedValues,n.resolve(t))}function i(a){r.$$failure=a,n.reject(a)}function j(c,e,f){function j(a){l.reject(a),i(a)}function k(){if(!M(r.$$failure))try{l.resolve(b.invoke(e,g,t)),l.promise.then(function(a){t[c]=a,h()},j)}catch(a){j(a)}}var l=a.defer(),m=0;R(f,function(a){s.hasOwnProperty(a)&&!d.hasOwnProperty(a)&&(m++,s[a].then(function(b){t[a]=b,--m||k()},j))}),m||k(),s[c]=l.promise}if(o(d)&&g===c&&(g=f,f=d,d=null),d){if(!P(d))throw new Error("'locals' must be an object")}else d=k;if(f){if(!o(f))throw new Error("'parent' must be a promise returned by $resolve.resolve()")}else f=l;var n=a.defer(),r=n.promise,s=r.$$promises={},t=S({},d),u=1+q.length/3,v=!1;if(M(f.$$failure))return i(f.$$failure),r;f.$$inheritedValues&&e(t,m(f.$$inheritedValues,p)),S(s,f.$$promises),f.$$values?(v=e(t,m(f.$$values,p)),r.$$inheritedValues=m(f.$$values,p),h()):(f.$$inheritedValues&&(r.$$inheritedValues=m(f.$$inheritedValues,p)),f.then(h,i));for(var w=0,x=q.length;w=0));)s=f(r.id,r.type,r.cfg,"path"),l+=g(r.segment,s.type.pattern.source,s.squash,s.isOptional),n.push(r.segment),m=j.lastIndex;t=a.substring(m);var u=t.indexOf("?");if(u>=0){var v=this.sourceSearch=t.substring(u);if(t=t.substring(0,u),this.sourcePath=a.substring(0,m+u),v.length>0)for(m=0;i=k.exec(v);)r=h(i,!0),s=f(r.id,r.type,r.cfg,"search"),m=j.lastIndex}else this.sourcePath=a,this.sourceSearch="";l+=g(t)+(b.strict===!1?"/?":"")+"$",n.push(t),this.regexp=new RegExp(l,b.caseInsensitive?"i":c),this.prefix=n[0],this.$$paramNames=q}function t(a){S(this,a)}function u(){function a(a){return null!=a?a.toString().replace(/(~|\/)/g,function(a){return{"~":"~~","/":"~2F"}[a]}):a}function e(a){return null!=a?a.toString().replace(/(~~|~2F)/g,function(a){return{"~~":"~","~2F":"/"}[a]}):a}function f(){return{strict:p,caseInsensitive:m}}function i(a){return N(a)||Q(a)&&N(a[a.length-1])}function j(){for(;w.length;){var a=w.shift();if(a.pattern)throw new Error("You cannot override a type's .pattern at runtime.");b.extend(r[a.name],l.invoke(a.def))}}function k(a){S(this,a||{})}V=this;var l,m=!1,p=!0,q=!1,r={},v=!0,w=[],x={string:{encode:a,decode:e,is:function(a){return null==a||!M(a)||"string"==typeof a},pattern:/[^\/]*/},int:{encode:a,decode:function(a){return parseInt(a,10)},is:function(a){return M(a)&&this.decode(a.toString())===a},pattern:/\d+/},bool:{encode:function(a){return a?1:0},decode:function(a){return 0!==parseInt(a,10)},is:function(a){return a===!0||a===!1},pattern:/0|1/},date:{encode:function(a){return this.is(a)?[a.getFullYear(),("0"+(a.getMonth()+1)).slice(-2),("0"+a.getDate()).slice(-2)].join("-"):c},decode:function(a){if(this.is(a))return a;var b=this.capture.exec(a);return b?new Date(b[1],b[2]-1,b[3]):c},is:function(a){return a instanceof Date&&!isNaN(a.valueOf())},equals:function(a,b){return this.is(a)&&this.is(b)&&a.toISOString()===b.toISOString()},pattern:/[0-9]{4}-(?:0[1-9]|1[0-2])-(?:0[1-9]|[1-2][0-9]|3[0-1])/,capture:/([0-9]{4})-(0[1-9]|1[0-2])-(0[1-9]|[1-2][0-9]|3[0-1])/},json:{encode:b.toJson,decode:b.fromJson,is:b.isObject,equals:b.equals,pattern:/[^\/]*/},any:{encode:b.identity,decode:b.identity,equals:b.equals,pattern:/.*/}};u.$$getDefaultValue=function(a){if(!i(a.value))return a.value;if(!l)throw new Error("Injectable functions cannot be called at configuration time");return l.invoke(a.value)},this.caseInsensitive=function(a){return M(a)&&(m=a),m},this.strictMode=function(a){return M(a)&&(p=a),p},this.defaultSquashPolicy=function(a){if(!M(a))return q;if(a!==!0&&a!==!1&&!O(a))throw new Error("Invalid squash policy: "+a+". Valid policies: false, true, arbitrary-string");return q=a,a},this.compile=function(a,b){return new s(a,S(f(),b))},this.isMatcher=function(a){if(!P(a))return!1;var b=!0;return R(s.prototype,function(c,d){N(c)&&(b=b&&M(a[d])&&N(a[d]))}),b},this.type=function(a,b,c){if(!M(b))return r[a];if(r.hasOwnProperty(a))throw new Error("A type named '"+a+"' has already been defined.");return r[a]=new t(S({name:a},b)),c&&(w.push({name:a,def:c}),v||j()),this},R(x,function(a,b){r[b]=new t(S({name:b},a))}),r=d(r,{}),this.$get=["$injector",function(a){return l=a,v=!1,j(),R(x,function(a,b){r[b]||(r[b]=new t(a))}),this}],this.Param=function(a,d,e,f){function j(a){var b=P(a)?g(a):[],c=h(b,"value")===-1&&h(b,"type")===-1&&h(b,"squash")===-1&&h(b,"array")===-1;return c&&(a={value:a}),a.$$fn=i(a.value)?a.value:function(){return a.value},a}function k(c,d,e){if(c.type&&d)throw new Error("Param '"+a+"' has two type configurations.");return d?d:c.type?b.isString(c.type)?r[c.type]:c.type instanceof t?c.type:new t(c.type):"config"===e?r.any:r.string}function m(){var b={array:"search"===f&&"auto"},c=a.match(/\[\]$/)?{array:!0}:{};return S(b,c,e).array}function p(a,b){var c=a.squash;if(!b||c===!1)return!1;if(!M(c)||null==c)return q;if(c===!0||O(c))return c;throw new Error("Invalid squash policy: '"+c+"'. Valid policies: false, true, or arbitrary string")}function s(a,b,d,e){var f,g,i=[{from:"",to:d||b?c:""},{from:null,to:d||b?c:""}];return f=Q(a.replace)?a.replace:[],O(e)&&f.push({from:e,to:c}),g=o(f,function(a){return a.from}),n(i,function(a){return h(g,a.from)===-1}).concat(f)}function u(){if(!l)throw new Error("Injectable functions cannot be called at configuration time");var a=l.invoke(e.$$fn);if(null!==a&&a!==c&&!x.type.is(a))throw new Error("Default value ("+a+") for parameter '"+x.id+"' is not an instance of Type ("+x.type.name+")");return a}function v(a){function b(a){return function(b){return b.from===a}}function c(a){var c=o(n(x.replace,b(a)),function(a){return a.to});return c.length?c[0]:a}return a=c(a),M(a)?x.type.$normalize(a):u()}function w(){return"{Param:"+a+" "+d+" squash: '"+A+"' optional: "+z+"}"}var x=this;e=j(e),d=k(e,d,f);var y=m();d=y?d.$asArray(y,"search"===f):d,"string"!==d.name||y||"path"!==f||e.value!==c||(e.value="");var z=e.value!==c,A=p(e,z),B=s(e,y,z,A);S(this,{id:a,type:d,location:f,array:y,squash:A,replace:B,isOptional:z,value:v,dynamic:c,config:e,toString:w})},k.prototype={$$new:function(){return d(this,S(new k,{$$parent:this}))},$$keys:function(){for(var a=[],b=[],c=this,d=g(k.prototype);c;)b.push(c),c=c.$$parent;return b.reverse(),R(b,function(b){R(g(b),function(b){h(a,b)===-1&&h(d,b)===-1&&a.push(b)})}),a},$$values:function(a){var b={},c=this;return R(c.$$keys(),function(d){b[d]=c[d].value(a&&a[d])}),b},$$equals:function(a,b){var c=!0,d=this;return R(d.$$keys(),function(e){var f=a&&a[e],g=b&&b[e];d[e].type.equals(f,g)||(c=!1)}),c},$$validates:function(a){var d,e,f,g,h,i=this.$$keys();for(d=0;d=0)throw new Error("State must have a valid name");if(A.hasOwnProperty(c))throw new Error("State '"+c+"' is already defined");var e=c.indexOf(".")!==-1?c.substring(0,c.lastIndexOf(".")):O(b.parent)?b.parent:P(b.parent)&&O(b.parent.name)?b.parent.name:"";if(e&&!A[e])return n(e,b.self);for(var f in D)N(D[f])&&(b[f]=D[f](b,D.$delegates[f]));return A[c]=b,!b[C]&&b.url&&a.when(b.url,["$match","$stateParams",function(a,c){z.$current.navigable==b&&j(a,c)||z.transitionTo(b,a,{inherit:!0,location:!1})}]),q(c),b}function s(a){return a.indexOf("*")>-1}function t(a){for(var b=a.split("."),c=z.$current.name.split("."),d=0,e=b.length;d=A;d--)g=o[d],g.self.onExit&&h.invoke(g.self.onExit,g.self,g.locals.globals),g.locals=null;for(d=A;d2?k.enter(a,null,c).then(d):k.enter(a,null,c,d)},leave:function(a,c){b.version.minor>2?k.leave(a).then(c):k.leave(a,c)}};if(j){var e=j&&j(c,a);return{enter:function(a,b,c){e.enter(a,null,b),c()},leave:function(a,b){e.leave(a),b()}}}return d()}var i=g(),j=i("$animator"),k=i("$animate"),l={restrict:"ECA",terminal:!0,priority:400,transclude:"element",compile:function(c,g,i){return function(c,g,j){function k(){if(m&&(m.remove(),m=null),o&&(o.$destroy(),o=null),n){var a=n.data("$uiViewAnim");s.leave(n,function(){a.$$animLeave.resolve(),m=null}),m=n,n=null}}function l(h){var l,m=B(c,j,g,e),t=m&&a.$current&&a.$current.locals[m];if(h||t!==p){l=c.$new(),p=a.$current.locals[m],l.$emit("$viewContentLoading",m);var u=i(l,function(a){var e=f.defer(),h=f.defer(),i={$animEnter:e.promise,$animLeave:h.promise,$$animLeave:h};a.data("$uiViewAnim",i),s.enter(a,g,function(){e.resolve(),o&&o.$emit("$viewContentAnimationEnded"),(b.isDefined(r)&&!r||c.$eval(r))&&d(a)}),k()});n=u,o=l,o.$emit("$viewContentLoaded",m),o.$eval(q)}}var m,n,o,p,q=j.onload||"",r=j.autoscroll,s=h(j,c);g.inheritedData("$uiView");c.$on("$stateChangeSuccess",function(){l(!1)}),l(!0)}}};return l}function A(a,c,d,e){return{restrict:"ECA",priority:-400,compile:function(f){var g=f.html();return function(f,h,i){var j=d.$current,k=B(f,i,h,e),l=j&&j.locals[k];if(l){h.data("$uiView",{name:k,state:l.$$state}),h.html(l.$template?l.$template:g);var m=b.extend({},l);f[l.$$resolveAs]=m;var n=a(h.contents());if(l.$$controller){l.$scope=f,l.$element=h;var o=c(l.$$controller,l);l.$$controllerAs&&(f[l.$$controllerAs]=o,f[l.$$controllerAs][l.$$resolveAs]=m),N(o.$onInit)&&o.$onInit(),h.data("$ngControllerController",o),h.children().data("$ngControllerController",o)}n(f)}}}}}function B(a,b,c,d){var e=d(b.uiView||b.name||"")(a),f=c.inheritedData("$uiView");return e.indexOf("@")>=0?e:e+"@"+(f?f.state.name:"")}function C(a,b){var c,d=a.match(/^\s*({[^}]*})\s*$/);if(d&&(a=b+"("+d[1]+")"),c=a.replace(/\n/g," ").match(/^([^(]+?)\s*(\((.*)\))?$/),!c||4!==c.length)throw new Error("Invalid state ref '"+a+"'");return{state:c[1],paramExpr:c[3]||null}}function D(a){var b=a.parent().inheritedData("$uiView");if(b&&b.state&&b.state.name)return b.state}function E(a){var b="[object SVGAnimatedString]"===Object.prototype.toString.call(a.prop("href")),c="FORM"===a[0].nodeName;return{attr:c?"action":b?"xlink:href":"href",isAnchor:"A"===a.prop("tagName").toUpperCase(),clickable:!c}}function F(a,b,c,d,e){return function(f){var g=f.which||f.button,h=e();if(!(g>1||f.ctrlKey||f.metaKey||f.shiftKey||a.attr("target"))){var i=c(function(){b.go(h.state,h.params,h.options)});f.preventDefault();var j=d.isAnchor&&!h.href?1:0;f.preventDefault=function(){j--<=0&&c.cancel(i)}}}}function G(a,b){return{relative:D(a)||b.$current,inherit:!0}}function H(a,c){return{restrict:"A",require:["?^uiSrefActive","?^uiSrefActiveEq"],link:function(d,e,f,g){var h,i=C(f.uiSref,a.current.name),j={state:i.state,href:null,params:null},k=E(e),l=g[1]||g[0],m=null;j.options=S(G(e,a),f.uiSrefOpts?d.$eval(f.uiSrefOpts):{});var n=function(c){c&&(j.params=b.copy(c)),j.href=a.href(i.state,j.params,j.options),m&&m(),l&&(m=l.$$addStateInfo(i.state,j.params)),null!==j.href&&f.$set(k.attr,j.href)};i.paramExpr&&(d.$watch(i.paramExpr,function(a){a!==j.params&&n(a)},!0),j.params=b.copy(d.$eval(i.paramExpr))),n(),k.clickable&&(h=F(e,a,c,k,function(){return j}),e[e.on?"on":"bind"]("click",h),d.$on("$destroy",function(){e[e.off?"off":"unbind"]("click",h)}))}}}function I(a,b){return{restrict:"A",require:["?^uiSrefActive","?^uiSrefActiveEq"],link:function(c,d,e,f){function g(b){m.state=b[0],m.params=b[1],m.options=b[2],m.href=a.href(m.state,m.params,m.options),n&&n(),j&&(n=j.$$addStateInfo(m.state,m.params)),m.href&&e.$set(i.attr,m.href)}var h,i=E(d),j=f[1]||f[0],k=[e.uiState,e.uiStateParams||null,e.uiStateOpts||null],l="["+k.map(function(a){return a||"null"}).join(", ")+"]",m={state:null,params:null,options:null,href:null},n=null;c.$watch(l,g,!0),g(c.$eval(l)),i.clickable&&(h=F(d,a,b,i,function(){return m}),d[d.on?"on":"bind"]("click",h),c.$on("$destroy",function(){d[d.off?"off":"unbind"]("click",h)}))}}}function J(a,b,c){return{restrict:"A",controller:["$scope","$element","$attrs","$timeout",function(b,d,e,f){function g(b,c,e){var f=a.get(b,D(d)),g=h(b,c),i={state:f||{name:b},params:c,hash:g};return p.push(i),q[g]=e,function(){var a=p.indexOf(i);a!==-1&&p.splice(a,1)}}function h(a,c){if(!O(a))throw new Error("state should be a string");return P(c)?a+U(c):(c=b.$eval(c),P(c)?a+U(c):a)}function i(){for(var a=0;a0)){var c=g(a,b,o);return i(),c}},b.$on("$stateChangeSuccess",i),i()}]}}function K(a){var b=function(b,c){return a.is(b,c)};return b.$stateful=!0,b}function L(a){var b=function(b,c,d){return a.includes(b,c,d)};return b.$stateful=!0,b}var M=b.isDefined,N=b.isFunction,O=b.isString,P=b.isObject,Q=b.isArray,R=b.forEach,S=b.extend,T=b.copy,U=b.toJson;b.module("ui.router.util",["ng"]),b.module("ui.router.router",["ui.router.util"]),b.module("ui.router.state",["ui.router.router","ui.router.util"]),b.module("ui.router",["ui.router.state"]),b.module("ui.router.compat",["ui.router"]),q.$inject=["$q","$injector"],b.module("ui.router.util").service("$resolve",q),r.$inject=["$http","$templateCache","$injector"],b.module("ui.router.util").service("$templateFactory",r);var V;s.prototype.concat=function(a,b){var c={caseInsensitive:V.caseInsensitive(),strict:V.strictMode(),squash:V.defaultSquashPolicy()};return new s(this.sourcePath+a+this.sourceSearch,S(c,b),this)},s.prototype.toString=function(){return this.source},s.prototype.exec=function(a,b){function c(a){function b(a){return a.split("").reverse().join("")}function c(a){return a.replace(/\\-/g,"-")}var d=b(a).split(/-(?!\\)/),e=o(d,b);return o(e,c).reverse()}var d=this.regexp.exec(a);if(!d)return null;b=b||{};var e,f,g,h=this.parameters(),i=h.length,j=this.segments.length-1,k={};if(j!==d.length-1)throw new Error("Unbalanced capture group in route '"+this.source+"'");var l,m;for(e=0;e
     */
    "undefined"!=typeof module&&"undefined"!=typeof exports&&module.exports===exports&&(module.exports="ui.router"),function(a,b,c){"use strict";function d(a,b){return S(new(S(function(){},{prototype:a})),b)}function e(a){return R(arguments,function(b){b!==a&&R(b,function(b,c){a.hasOwnProperty(c)||(a[c]=b)})}),a}function f(a,b){var c=[];for(var d in a.path){if(a.path[d]!==b.path[d])break;c.push(a.path[d])}return c}function g(a){if(Object.keys)return Object.keys(a);var b=[];return R(a,function(a,c){b.push(c)}),b}function h(a,b){if(Array.prototype.indexOf)return a.indexOf(b,Number(arguments[2])||0);var c=a.length>>>0,d=Number(arguments[2])||0;for(d=d<0?Math.ceil(d):Math.floor(d),d<0&&(d+=c);d=0||(k.push(e[m]),j[e[m]]=a[e[m]]);return S({},j,b)}function j(a,b,c){if(!c){c=[];for(var d in a)c.push(d)}for(var e=0;e "));if(s[c]=d,O(a))q.push(c,[function(){return b.get(a)}],j);else{var e=b.annotate(a);R(e,function(a){a!==c&&i.hasOwnProperty(a)&&n(i[a],a)}),q.push(c,a,e)}r.pop(),s[c]=f}}function o(a){return P(a)&&a.then&&a.$$promises}if(!P(i))throw new Error("'invocables' must be an object");var p=g(i||{}),q=[],r=[],s={};return R(i,n),i=r=s=null,function(d,f,g){function h(){--u||(v||e(t,f.$$values),r.$$values=t,r.$$promises=r.$$promises||!0,delete r.$$inheritedValues,n.resolve(t))}function i(a){r.$$failure=a,n.reject(a)}function j(c,e,f){function j(a){l.reject(a),i(a)}function k(){if(!M(r.$$failure))try{l.resolve(b.invoke(e,g,t)),l.promise.then(function(a){t[c]=a,h()},j)}catch(a){j(a)}}var l=a.defer(),m=0;R(f,function(a){s.hasOwnProperty(a)&&!d.hasOwnProperty(a)&&(m++,s[a].then(function(b){t[a]=b,--m||k()},j))}),m||k(),s[c]=l.promise}if(o(d)&&g===c&&(g=f,f=d,d=null),d){if(!P(d))throw new Error("'locals' must be an object")}else d=k;if(f){if(!o(f))throw new Error("'parent' must be a promise returned by $resolve.resolve()")}else f=l;var n=a.defer(),r=n.promise,s=r.$$promises={},t=S({},d),u=1+q.length/3,v=!1;if(M(f.$$failure))return i(f.$$failure),r;f.$$inheritedValues&&e(t,m(f.$$inheritedValues,p)),S(s,f.$$promises),f.$$values?(v=e(t,m(f.$$values,p)),r.$$inheritedValues=m(f.$$values,p),h()):(f.$$inheritedValues&&(r.$$inheritedValues=m(f.$$inheritedValues,p)),f.then(h,i));for(var w=0,x=q.length;w=0));)s=f(r.id,r.type,r.cfg,"path"),l+=g(r.segment,s.type.pattern.source,s.squash,s.isOptional),n.push(r.segment),m=j.lastIndex;t=a.substring(m);var u=t.indexOf("?");if(u>=0){var v=this.sourceSearch=t.substring(u);if(t=t.substring(0,u),this.sourcePath=a.substring(0,m+u),v.length>0)for(m=0;i=k.exec(v);)r=h(i,!0),s=f(r.id,r.type,r.cfg,"search"),m=j.lastIndex}else this.sourcePath=a,this.sourceSearch="";l+=g(t)+(b.strict===!1?"/?":"")+"$",n.push(t),this.regexp=new RegExp(l,b.caseInsensitive?"i":c),this.prefix=n[0],this.$$paramNames=q}function t(a){S(this,a)}function u(){function a(a){return null!=a?a.toString().replace(/(~|\/)/g,function(a){return{"~":"~~","/":"~2F"}[a]}):a}function e(a){return null!=a?a.toString().replace(/(~~|~2F)/g,function(a){return{"~~":"~","~2F":"/"}[a]}):a}function f(){return{strict:p,caseInsensitive:m}}function i(a){return N(a)||Q(a)&&N(a[a.length-1])}function j(){for(;w.length;){var a=w.shift();if(a.pattern)throw new Error("You cannot override a type's .pattern at runtime.");b.extend(r[a.name],l.invoke(a.def))}}function k(a){S(this,a||{})}V=this;var l,m=!1,p=!0,q=!1,r={},v=!0,w=[],x={string:{encode:a,decode:e,is:function(a){return null==a||!M(a)||"string"==typeof a},pattern:/[^\/]*/},int:{encode:a,decode:function(a){return parseInt(a,10)},is:function(a){return M(a)&&this.decode(a.toString())===a},pattern:/\d+/},bool:{encode:function(a){return a?1:0},decode:function(a){return 0!==parseInt(a,10)},is:function(a){return a===!0||a===!1},pattern:/0|1/},date:{encode:function(a){return this.is(a)?[a.getFullYear(),("0"+(a.getMonth()+1)).slice(-2),("0"+a.getDate()).slice(-2)].join("-"):c},decode:function(a){if(this.is(a))return a;var b=this.capture.exec(a);return b?new Date(b[1],b[2]-1,b[3]):c},is:function(a){return a instanceof Date&&!isNaN(a.valueOf())},equals:function(a,b){return this.is(a)&&this.is(b)&&a.toISOString()===b.toISOString()},pattern:/[0-9]{4}-(?:0[1-9]|1[0-2])-(?:0[1-9]|[1-2][0-9]|3[0-1])/,capture:/([0-9]{4})-(0[1-9]|1[0-2])-(0[1-9]|[1-2][0-9]|3[0-1])/},json:{encode:b.toJson,decode:b.fromJson,is:b.isObject,equals:b.equals,pattern:/[^\/]*/},any:{encode:b.identity,decode:b.identity,equals:b.equals,pattern:/.*/}};u.$$getDefaultValue=function(a){if(!i(a.value))return a.value;if(!l)throw new Error("Injectable functions cannot be called at configuration time");return l.invoke(a.value)},this.caseInsensitive=function(a){return M(a)&&(m=a),m},this.strictMode=function(a){return M(a)&&(p=a),p},this.defaultSquashPolicy=function(a){if(!M(a))return q;if(a!==!0&&a!==!1&&!O(a))throw new Error("Invalid squash policy: "+a+". Valid policies: false, true, arbitrary-string");return q=a,a},this.compile=function(a,b){return new s(a,S(f(),b))},this.isMatcher=function(a){if(!P(a))return!1;var b=!0;return R(s.prototype,function(c,d){N(c)&&(b=b&&M(a[d])&&N(a[d]))}),b},this.type=function(a,b,c){if(!M(b))return r[a];if(r.hasOwnProperty(a))throw new Error("A type named '"+a+"' has already been defined.");return r[a]=new t(S({name:a},b)),c&&(w.push({name:a,def:c}),v||j()),this},R(x,function(a,b){r[b]=new t(S({name:b},a))}),r=d(r,{}),this.$get=["$injector",function(a){return l=a,v=!1,j(),R(x,function(a,b){r[b]||(r[b]=new t(a))}),this}],this.Param=function(a,d,e,f){function j(a){var b=P(a)?g(a):[],c=h(b,"value")===-1&&h(b,"type")===-1&&h(b,"squash")===-1&&h(b,"array")===-1;return c&&(a={value:a}),a.$$fn=i(a.value)?a.value:function(){return a.value},a}function k(c,d,e){if(c.type&&d)throw new Error("Param '"+a+"' has two type configurations.");return d?d:c.type?b.isString(c.type)?r[c.type]:c.type instanceof t?c.type:new t(c.type):"config"===e?r.any:r.string}function m(){var b={array:"search"===f&&"auto"},c=a.match(/\[\]$/)?{array:!0}:{};return S(b,c,e).array}function p(a,b){var c=a.squash;if(!b||c===!1)return!1;if(!M(c)||null==c)return q;if(c===!0||O(c))return c;throw new Error("Invalid squash policy: '"+c+"'. Valid policies: false, true, or arbitrary string")}function s(a,b,d,e){var f,g,i=[{from:"",to:d||b?c:""},{from:null,to:d||b?c:""}];return f=Q(a.replace)?a.replace:[],O(e)&&f.push({from:e,to:c}),g=o(f,function(a){return a.from}),n(i,function(a){return h(g,a.from)===-1}).concat(f)}function u(){if(!l)throw new Error("Injectable functions cannot be called at configuration time");var a=l.invoke(e.$$fn);if(null!==a&&a!==c&&!x.type.is(a))throw new Error("Default value ("+a+") for parameter '"+x.id+"' is not an instance of Type ("+x.type.name+")");return a}function v(a){function b(a){return function(b){return b.from===a}}function c(a){var c=o(n(x.replace,b(a)),function(a){return a.to});return c.length?c[0]:a}return a=c(a),M(a)?x.type.$normalize(a):u()}function w(){return"{Param:"+a+" "+d+" squash: '"+A+"' optional: "+z+"}"}var x=this;e=j(e),d=k(e,d,f);var y=m();d=y?d.$asArray(y,"search"===f):d,"string"!==d.name||y||"path"!==f||e.value!==c||(e.value="");var z=e.value!==c,A=p(e,z),B=s(e,y,z,A);S(this,{id:a,type:d,location:f,array:y,squash:A,replace:B,isOptional:z,value:v,dynamic:c,config:e,toString:w})},k.prototype={$$new:function(){return d(this,S(new k,{$$parent:this}))},$$keys:function(){for(var a=[],b=[],c=this,d=g(k.prototype);c;)b.push(c),c=c.$$parent;return b.reverse(),R(b,function(b){R(g(b),function(b){h(a,b)===-1&&h(d,b)===-1&&a.push(b)})}),a},$$values:function(a){var b={},c=this;return R(c.$$keys(),function(d){b[d]=c[d].value(a&&a[d])}),b},$$equals:function(a,b){var c=!0,d=this;return R(d.$$keys(),function(e){var f=a&&a[e],g=b&&b[e];d[e].type.equals(f,g)||(c=!1)}),c},$$validates:function(a){var d,e,f,g,h,i=this.$$keys();for(d=0;d=0)throw new Error("State must have a valid name");if(A.hasOwnProperty(c))throw new Error("State '"+c+"' is already defined");var e=c.indexOf(".")!==-1?c.substring(0,c.lastIndexOf(".")):O(b.parent)?b.parent:P(b.parent)&&O(b.parent.name)?b.parent.name:"";if(e&&!A[e])return n(e,b.self);for(var f in D)N(D[f])&&(b[f]=D[f](b,D.$delegates[f]));return A[c]=b,!b[C]&&b.url&&a.when(b.url,["$match","$stateParams",function(a,c){z.$current.navigable==b&&j(a,c)||z.transitionTo(b,a,{inherit:!0,location:!1})}]),q(c),b}function s(a){return a.indexOf("*")>-1}function t(a){for(var b=a.split("."),c=z.$current.name.split("."),d=0,e=b.length;d=A;d--)g=o[d],g.self.onExit&&h.invoke(g.self.onExit,g.self,g.locals.globals),g.locals=null;for(d=A;d2?k.enter(a,null,c).then(d):k.enter(a,null,c,d)},leave:function(a,c){b.version.minor>2?k.leave(a).then(c):k.leave(a,c)}};if(j){var e=j&&j(c,a);return{enter:function(a,b,c){e.enter(a,null,b),c()},leave:function(a,b){e.leave(a),b()}}}return d()}var i=g(),j=i("$animator"),k=i("$animate"),l={restrict:"ECA",terminal:!0,priority:400,transclude:"element",compile:function(c,g,i){return function(c,g,j){function k(){if(m&&(m.remove(),m=null),o&&(o.$destroy(),o=null),n){var a=n.data("$uiViewAnim");s.leave(n,function(){a.$$animLeave.resolve(),m=null}),m=n,n=null}}function l(h){var l,m=B(c,j,g,e),t=m&&a.$current&&a.$current.locals[m];if(h||t!==p){l=c.$new(),p=a.$current.locals[m],l.$emit("$viewContentLoading",m);var u=i(l,function(a){var e=f.defer(),h=f.defer(),i={$animEnter:e.promise,$animLeave:h.promise,$$animLeave:h};a.data("$uiViewAnim",i),s.enter(a,g,function(){e.resolve(),o&&o.$emit("$viewContentAnimationEnded"),(b.isDefined(r)&&!r||c.$eval(r))&&d(a)}),k()});n=u,o=l,o.$emit("$viewContentLoaded",m),o.$eval(q)}}var m,n,o,p,q=j.onload||"",r=j.autoscroll,s=h(j,c);g.inheritedData("$uiView");c.$on("$stateChangeSuccess",function(){l(!1)}),l(!0)}}};return l}function A(a,c,d,e){return{restrict:"ECA",priority:-400,compile:function(f){var g=f.html();return function(f,h,i){var j=d.$current,k=B(f,i,h,e),l=j&&j.locals[k];if(l){h.data("$uiView",{name:k,state:l.$$state}),h.html(l.$template?l.$template:g);var m=b.extend({},l);f[l.$$resolveAs]=m;var n=a(h.contents());if(l.$$controller){l.$scope=f,l.$element=h;var o=c(l.$$controller,l);l.$$controllerAs&&(f[l.$$controllerAs]=o,f[l.$$controllerAs][l.$$resolveAs]=m),N(o.$onInit)&&o.$onInit(),h.data("$ngControllerController",o),h.children().data("$ngControllerController",o)}n(f)}}}}}function B(a,b,c,d){var e=d(b.uiView||b.name||"")(a),f=c.inheritedData("$uiView");return e.indexOf("@")>=0?e:e+"@"+(f?f.state.name:"")}function C(a,b){var c,d=a.match(/^\s*({[^}]*})\s*$/);if(d&&(a=b+"("+d[1]+")"),c=a.replace(/\n/g," ").match(/^([^(]+?)\s*(\((.*)\))?$/),!c||4!==c.length)throw new Error("Invalid state ref '"+a+"'");return{state:c[1],paramExpr:c[3]||null}}function D(a){var b=a.parent().inheritedData("$uiView");if(b&&b.state&&b.state.name)return b.state}function E(a){var b="[object SVGAnimatedString]"===Object.prototype.toString.call(a.prop("href")),c="FORM"===a[0].nodeName;return{attr:c?"action":b?"xlink:href":"href",isAnchor:"A"===a.prop("tagName").toUpperCase(),clickable:!c}}function F(a,b,c,d,e){return function(f){var g=f.which||f.button,h=e();if(!(g>1||f.ctrlKey||f.metaKey||f.shiftKey||a.attr("target"))){var i=c(function(){b.go(h.state,h.params,h.options)});f.preventDefault();var j=d.isAnchor&&!h.href?1:0;f.preventDefault=function(){j--<=0&&c.cancel(i)}}}}function G(a,b){return{relative:D(a)||b.$current,inherit:!0}}function H(a,c){return{restrict:"A",require:["?^uiSrefActive","?^uiSrefActiveEq"],link:function(d,e,f,g){var h,i=C(f.uiSref,a.current.name),j={state:i.state,href:null,params:null},k=E(e),l=g[1]||g[0],m=null;j.options=S(G(e,a),f.uiSrefOpts?d.$eval(f.uiSrefOpts):{});var n=function(c){c&&(j.params=b.copy(c)),j.href=a.href(i.state,j.params,j.options),m&&m(),l&&(m=l.$$addStateInfo(i.state,j.params)),null!==j.href&&f.$set(k.attr,j.href)};i.paramExpr&&(d.$watch(i.paramExpr,function(a){a!==j.params&&n(a)},!0),j.params=b.copy(d.$eval(i.paramExpr))),n(),k.clickable&&(h=F(e,a,c,k,function(){return j}),e[e.on?"on":"bind"]("click",h),d.$on("$destroy",function(){e[e.off?"off":"unbind"]("click",h)}))}}}function I(a,b){return{restrict:"A",require:["?^uiSrefActive","?^uiSrefActiveEq"],link:function(c,d,e,f){function g(b){m.state=b[0],m.params=b[1],m.options=b[2],m.href=a.href(m.state,m.params,m.options),n&&n(),j&&(n=j.$$addStateInfo(m.state,m.params)),m.href&&e.$set(i.attr,m.href)}var h,i=E(d),j=f[1]||f[0],k=[e.uiState,e.uiStateParams||null,e.uiStateOpts||null],l="["+k.map(function(a){return a||"null"}).join(", ")+"]",m={state:null,params:null,options:null,href:null},n=null;c.$watch(l,g,!0),g(c.$eval(l)),i.clickable&&(h=F(d,a,b,i,function(){return m}),d[d.on?"on":"bind"]("click",h),c.$on("$destroy",function(){d[d.off?"off":"unbind"]("click",h)}))}}}function J(a,b,c){return{restrict:"A",controller:["$scope","$element","$attrs","$timeout",function(b,d,e,f){function g(b,c,e){var f=a.get(b,D(d)),g=h(b,c),i={state:f||{name:b},params:c,hash:g};return p.push(i),q[g]=e,function(){var a=p.indexOf(i);a!==-1&&p.splice(a,1)}}function h(a,c){if(!O(a))throw new Error("state should be a string");return P(c)?a+U(c):(c=b.$eval(c),P(c)?a+U(c):a)}function i(){for(var a=0;a0)){var c=g(a,b,o);return i(),c}},b.$on("$stateChangeSuccess",i),i()}]}}function K(a){var b=function(b,c){return a.is(b,c)};return b.$stateful=!0,b}function L(a){var b=function(b,c,d){return a.includes(b,c,d)};return b.$stateful=!0,b}var M=b.isDefined,N=b.isFunction,O=b.isString,P=b.isObject,Q=b.isArray,R=b.forEach,S=b.extend,T=b.copy,U=b.toJson;b.module("ui.router.util",["ng"]),b.module("ui.router.router",["ui.router.util"]),b.module("ui.router.state",["ui.router.router","ui.router.util"]),b.module("ui.router",["ui.router.state"]),b.module("ui.router.compat",["ui.router"]),q.$inject=["$q","$injector"],b.module("ui.router.util").service("$resolve",q),r.$inject=["$http","$templateCache","$injector"],b.module("ui.router.util").service("$templateFactory",r);var V;s.prototype.concat=function(a,b){var c={caseInsensitive:V.caseInsensitive(),strict:V.strictMode(),squash:V.defaultSquashPolicy()};return new s(this.sourcePath+a+this.sourceSearch,S(c,b),this)},s.prototype.toString=function(){return this.source},s.prototype.exec=function(a,b){function c(a){function b(a){return a.split("").reverse().join("")}function c(a){return a.replace(/\\-/g,"-")}var d=b(a).split(/-(?!\\)/),e=o(d,b);return o(e,c).reverse()}var d=this.regexp.exec(a);if(!d)return null;b=b||{};var e,f,g,h=this.parameters(),i=h.length,j=this.segments.length-1,k={};if(j!==d.length-1)throw new Error("Unbalanced capture group in route '"+this.source+"'");var l,m;for(e=0;e
     */
    "undefined"!=typeof module&&"undefined"!=typeof exports&&module.exports===exports&&(module.exports="ui.router"),function(a,b,c){"use strict";function d(a,b){return S(new(S(function(){},{prototype:a})),b)}function e(a){return R(arguments,function(b){b!==a&&R(b,function(b,c){a.hasOwnProperty(c)||(a[c]=b)})}),a}function f(a,b){var c=[];for(var d in a.path){if(a.path[d]!==b.path[d])break;c.push(a.path[d])}return c}function g(a){if(Object.keys)return Object.keys(a);var b=[];return R(a,function(a,c){b.push(c)}),b}function h(a,b){if(Array.prototype.indexOf)return a.indexOf(b,Number(arguments[2])||0);var c=a.length>>>0,d=Number(arguments[2])||0;for(d=d<0?Math.ceil(d):Math.floor(d),d<0&&(d+=c);d=0||(k.push(e[m]),j[e[m]]=a[e[m]]);return S({},j,b)}function j(a,b,c){if(!c){c=[];for(var d in a)c.push(d)}for(var e=0;e "));if(s[c]=d,O(a))q.push(c,[function(){return b.get(a)}],j);else{var e=b.annotate(a);R(e,function(a){a!==c&&i.hasOwnProperty(a)&&n(i[a],a)}),q.push(c,a,e)}r.pop(),s[c]=f}}function o(a){return P(a)&&a.then&&a.$$promises}if(!P(i))throw new Error("'invocables' must be an object");var p=g(i||{}),q=[],r=[],s={};return R(i,n),i=r=s=null,function(d,f,g){function h(){--u||(v||e(t,f.$$values),r.$$values=t,r.$$promises=r.$$promises||!0,delete r.$$inheritedValues,n.resolve(t))}function i(a){r.$$failure=a,n.reject(a)}function j(c,e,f){function j(a){l.reject(a),i(a)}function k(){if(!M(r.$$failure))try{l.resolve(b.invoke(e,g,t)),l.promise.then(function(a){t[c]=a,h()},j)}catch(a){j(a)}}var l=a.defer(),m=0;R(f,function(a){s.hasOwnProperty(a)&&!d.hasOwnProperty(a)&&(m++,s[a].then(function(b){t[a]=b,--m||k()},j))}),m||k(),s[c]=l.promise}if(o(d)&&g===c&&(g=f,f=d,d=null),d){if(!P(d))throw new Error("'locals' must be an object")}else d=k;if(f){if(!o(f))throw new Error("'parent' must be a promise returned by $resolve.resolve()")}else f=l;var n=a.defer(),r=n.promise,s=r.$$promises={},t=S({},d),u=1+q.length/3,v=!1;if(M(f.$$failure))return i(f.$$failure),r;f.$$inheritedValues&&e(t,m(f.$$inheritedValues,p)),S(s,f.$$promises),f.$$values?(v=e(t,m(f.$$values,p)),r.$$inheritedValues=m(f.$$values,p),h()):(f.$$inheritedValues&&(r.$$inheritedValues=m(f.$$inheritedValues,p)),f.then(h,i));for(var w=0,x=q.length;w=0));)s=f(r.id,r.type,r.cfg,"path"),l+=g(r.segment,s.type.pattern.source,s.squash,s.isOptional),n.push(r.segment),m=j.lastIndex;t=a.substring(m);var u=t.indexOf("?");if(u>=0){var v=this.sourceSearch=t.substring(u);if(t=t.substring(0,u),this.sourcePath=a.substring(0,m+u),v.length>0)for(m=0;i=k.exec(v);)r=h(i,!0),s=f(r.id,r.type,r.cfg,"search"),m=j.lastIndex}else this.sourcePath=a,this.sourceSearch="";l+=g(t)+(b.strict===!1?"/?":"")+"$",n.push(t),this.regexp=new RegExp(l,b.caseInsensitive?"i":c),this.prefix=n[0],this.$$paramNames=q}function t(a){S(this,a)}function u(){function a(a){return null!=a?a.toString().replace(/(~|\/)/g,function(a){return{"~":"~~","/":"~2F"}[a]}):a}function e(a){return null!=a?a.toString().replace(/(~~|~2F)/g,function(a){return{"~~":"~","~2F":"/"}[a]}):a}function f(){return{strict:p,caseInsensitive:m}}function i(a){return N(a)||Q(a)&&N(a[a.length-1])}function j(){for(;w.length;){var a=w.shift();if(a.pattern)throw new Error("You cannot override a type's .pattern at runtime.");b.extend(r[a.name],l.invoke(a.def))}}function k(a){S(this,a||{})}V=this;var l,m=!1,p=!0,q=!1,r={},v=!0,w=[],x={string:{encode:a,decode:e,is:function(a){return null==a||!M(a)||"string"==typeof a},pattern:/[^\/]*/},int:{encode:a,decode:function(a){return parseInt(a,10)},is:function(a){return M(a)&&this.decode(a.toString())===a},pattern:/\d+/},bool:{encode:function(a){return a?1:0},decode:function(a){return 0!==parseInt(a,10)},is:function(a){return a===!0||a===!1},pattern:/0|1/},date:{encode:function(a){return this.is(a)?[a.getFullYear(),("0"+(a.getMonth()+1)).slice(-2),("0"+a.getDate()).slice(-2)].join("-"):c},decode:function(a){if(this.is(a))return a;var b=this.capture.exec(a);return b?new Date(b[1],b[2]-1,b[3]):c},is:function(a){return a instanceof Date&&!isNaN(a.valueOf())},equals:function(a,b){return this.is(a)&&this.is(b)&&a.toISOString()===b.toISOString()},pattern:/[0-9]{4}-(?:0[1-9]|1[0-2])-(?:0[1-9]|[1-2][0-9]|3[0-1])/,capture:/([0-9]{4})-(0[1-9]|1[0-2])-(0[1-9]|[1-2][0-9]|3[0-1])/},json:{encode:b.toJson,decode:b.fromJson,is:b.isObject,equals:b.equals,pattern:/[^\/]*/},any:{encode:b.identity,decode:b.identity,equals:b.equals,pattern:/.*/}};u.$$getDefaultValue=function(a){if(!i(a.value))return a.value;if(!l)throw new Error("Injectable functions cannot be called at configuration time");return l.invoke(a.value)},this.caseInsensitive=function(a){return M(a)&&(m=a),m},this.strictMode=function(a){return M(a)&&(p=a),p},this.defaultSquashPolicy=function(a){if(!M(a))return q;if(a!==!0&&a!==!1&&!O(a))throw new Error("Invalid squash policy: "+a+". Valid policies: false, true, arbitrary-string");return q=a,a},this.compile=function(a,b){return new s(a,S(f(),b))},this.isMatcher=function(a){if(!P(a))return!1;var b=!0;return R(s.prototype,function(c,d){N(c)&&(b=b&&M(a[d])&&N(a[d]))}),b},this.type=function(a,b,c){if(!M(b))return r[a];if(r.hasOwnProperty(a))throw new Error("A type named '"+a+"' has already been defined.");return r[a]=new t(S({name:a},b)),c&&(w.push({name:a,def:c}),v||j()),this},R(x,function(a,b){r[b]=new t(S({name:b},a))}),r=d(r,{}),this.$get=["$injector",function(a){return l=a,v=!1,j(),R(x,function(a,b){r[b]||(r[b]=new t(a))}),this}],this.Param=function(a,d,e,f){function j(a){var b=P(a)?g(a):[],c=h(b,"value")===-1&&h(b,"type")===-1&&h(b,"squash")===-1&&h(b,"array")===-1;return c&&(a={value:a}),a.$$fn=i(a.value)?a.value:function(){return a.value},a}function k(c,d,e){if(c.type&&d)throw new Error("Param '"+a+"' has two type configurations.");return d?d:c.type?b.isString(c.type)?r[c.type]:c.type instanceof t?c.type:new t(c.type):"config"===e?r.any:r.string}function m(){var b={array:"search"===f&&"auto"},c=a.match(/\[\]$/)?{array:!0}:{};return S(b,c,e).array}function p(a,b){var c=a.squash;if(!b||c===!1)return!1;if(!M(c)||null==c)return q;if(c===!0||O(c))return c;throw new Error("Invalid squash policy: '"+c+"'. Valid policies: false, true, or arbitrary string")}function s(a,b,d,e){var f,g,i=[{from:"",to:d||b?c:""},{from:null,to:d||b?c:""}];return f=Q(a.replace)?a.replace:[],O(e)&&f.push({from:e,to:c}),g=o(f,function(a){return a.from}),n(i,function(a){return h(g,a.from)===-1}).concat(f)}function u(){if(!l)throw new Error("Injectable functions cannot be called at configuration time");var a=l.invoke(e.$$fn);if(null!==a&&a!==c&&!x.type.is(a))throw new Error("Default value ("+a+") for parameter '"+x.id+"' is not an instance of Type ("+x.type.name+")");return a}function v(a){function b(a){return function(b){return b.from===a}}function c(a){var c=o(n(x.replace,b(a)),function(a){return a.to});return c.length?c[0]:a}return a=c(a),M(a)?x.type.$normalize(a):u()}function w(){return"{Param:"+a+" "+d+" squash: '"+A+"' optional: "+z+"}"}var x=this;e=j(e),d=k(e,d,f);var y=m();d=y?d.$asArray(y,"search"===f):d,"string"!==d.name||y||"path"!==f||e.value!==c||(e.value="");var z=e.value!==c,A=p(e,z),B=s(e,y,z,A);S(this,{id:a,type:d,location:f,array:y,squash:A,replace:B,isOptional:z,value:v,dynamic:c,config:e,toString:w})},k.prototype={$$new:function(){return d(this,S(new k,{$$parent:this}))},$$keys:function(){for(var a=[],b=[],c=this,d=g(k.prototype);c;)b.push(c),c=c.$$parent;return b.reverse(),R(b,function(b){R(g(b),function(b){h(a,b)===-1&&h(d,b)===-1&&a.push(b)})}),a},$$values:function(a){var b={},c=this;return R(c.$$keys(),function(d){b[d]=c[d].value(a&&a[d])}),b},$$equals:function(a,b){var c=!0,d=this;return R(d.$$keys(),function(e){var f=a&&a[e],g=b&&b[e];d[e].type.equals(f,g)||(c=!1)}),c},$$validates:function(a){var d,e,f,g,h,i=this.$$keys();for(d=0;d=0)throw new Error("State must have a valid name");if(A.hasOwnProperty(c))throw new Error("State '"+c+"' is already defined");var e=c.indexOf(".")!==-1?c.substring(0,c.lastIndexOf(".")):O(b.parent)?b.parent:P(b.parent)&&O(b.parent.name)?b.parent.name:"";if(e&&!A[e])return n(e,b.self);for(var f in D)N(D[f])&&(b[f]=D[f](b,D.$delegates[f]));return A[c]=b,!b[C]&&b.url&&a.when(b.url,["$match","$stateParams",function(a,c){z.$current.navigable==b&&j(a,c)||z.transitionTo(b,a,{inherit:!0,location:!1})}]),q(c),b}function s(a){return a.indexOf("*")>-1}function t(a){for(var b=a.split("."),c=z.$current.name.split("."),d=0,e=b.length;d=A;d--)g=o[d],g.self.onExit&&h.invoke(g.self.onExit,g.self,g.locals.globals),g.locals=null;for(d=A;d2?k.enter(a,null,c).then(d):k.enter(a,null,c,d)},leave:function(a,c){b.version.minor>2?k.leave(a).then(c):k.leave(a,c)}};if(j){var e=j&&j(c,a);return{enter:function(a,b,c){e.enter(a,null,b),c()},leave:function(a,b){e.leave(a),b()}}}return d()}var i=g(),j=i("$animator"),k=i("$animate"),l={restrict:"ECA",terminal:!0,priority:400,transclude:"element",compile:function(c,g,i){return function(c,g,j){function k(){if(m&&(m.remove(),m=null),o&&(o.$destroy(),o=null),n){var a=n.data("$uiViewAnim");s.leave(n,function(){a.$$animLeave.resolve(),m=null}),m=n,n=null}}function l(h){var l,m=B(c,j,g,e),t=m&&a.$current&&a.$current.locals[m];if(h||t!==p){l=c.$new(),p=a.$current.locals[m],l.$emit("$viewContentLoading",m);var u=i(l,function(a){var e=f.defer(),h=f.defer(),i={$animEnter:e.promise,$animLeave:h.promise,$$animLeave:h};a.data("$uiViewAnim",i),s.enter(a,g,function(){e.resolve(),o&&o.$emit("$viewContentAnimationEnded"),(b.isDefined(r)&&!r||c.$eval(r))&&d(a)}),k()});n=u,o=l,o.$emit("$viewContentLoaded",m),o.$eval(q)}}var m,n,o,p,q=j.onload||"",r=j.autoscroll,s=h(j,c);g.inheritedData("$uiView");c.$on("$stateChangeSuccess",function(){l(!1)}),l(!0)}}};return l}function A(a,c,d,e){return{restrict:"ECA",priority:-400,compile:function(f){var g=f.html();return function(f,h,i){var j=d.$current,k=B(f,i,h,e),l=j&&j.locals[k];if(l){h.data("$uiView",{name:k,state:l.$$state}),h.html(l.$template?l.$template:g);var m=b.extend({},l);f[l.$$resolveAs]=m;var n=a(h.contents());if(l.$$controller){l.$scope=f,l.$element=h;var o=c(l.$$controller,l);l.$$controllerAs&&(f[l.$$controllerAs]=o,f[l.$$controllerAs][l.$$resolveAs]=m),N(o.$onInit)&&o.$onInit(),h.data("$ngControllerController",o),h.children().data("$ngControllerController",o)}n(f)}}}}}function B(a,b,c,d){var e=d(b.uiView||b.name||"")(a),f=c.inheritedData("$uiView");return e.indexOf("@")>=0?e:e+"@"+(f?f.state.name:"")}function C(a,b){var c,d=a.match(/^\s*({[^}]*})\s*$/);if(d&&(a=b+"("+d[1]+")"),c=a.replace(/\n/g," ").match(/^([^(]+?)\s*(\((.*)\))?$/),!c||4!==c.length)throw new Error("Invalid state ref '"+a+"'");return{state:c[1],paramExpr:c[3]||null}}function D(a){var b=a.parent().inheritedData("$uiView");if(b&&b.state&&b.state.name)return b.state}function E(a){var b="[object SVGAnimatedString]"===Object.prototype.toString.call(a.prop("href")),c="FORM"===a[0].nodeName;return{attr:c?"action":b?"xlink:href":"href",isAnchor:"A"===a.prop("tagName").toUpperCase(),clickable:!c}}function F(a,b,c,d,e){return function(f){var g=f.which||f.button,h=e();if(!(g>1||f.ctrlKey||f.metaKey||f.shiftKey||a.attr("target"))){var i=c(function(){b.go(h.state,h.params,h.options)});f.preventDefault();var j=d.isAnchor&&!h.href?1:0;f.preventDefault=function(){j--<=0&&c.cancel(i)}}}}function G(a,b){return{relative:D(a)||b.$current,inherit:!0}}function H(a,c){return{restrict:"A",require:["?^uiSrefActive","?^uiSrefActiveEq"],link:function(d,e,f,g){var h,i=C(f.uiSref,a.current.name),j={state:i.state,href:null,params:null},k=E(e),l=g[1]||g[0],m=null;j.options=S(G(e,a),f.uiSrefOpts?d.$eval(f.uiSrefOpts):{});var n=function(c){c&&(j.params=b.copy(c)),j.href=a.href(i.state,j.params,j.options),m&&m(),l&&(m=l.$$addStateInfo(i.state,j.params)),null!==j.href&&f.$set(k.attr,j.href)};i.paramExpr&&(d.$watch(i.paramExpr,function(a){a!==j.params&&n(a)},!0),j.params=b.copy(d.$eval(i.paramExpr))),n(),k.clickable&&(h=F(e,a,c,k,function(){return j}),e[e.on?"on":"bind"]("click",h),d.$on("$destroy",function(){e[e.off?"off":"unbind"]("click",h)}))}}}function I(a,b){return{restrict:"A",require:["?^uiSrefActive","?^uiSrefActiveEq"],link:function(c,d,e,f){function g(b){m.state=b[0],m.params=b[1],m.options=b[2],m.href=a.href(m.state,m.params,m.options),n&&n(),j&&(n=j.$$addStateInfo(m.state,m.params)),m.href&&e.$set(i.attr,m.href)}var h,i=E(d),j=f[1]||f[0],k=[e.uiState,e.uiStateParams||null,e.uiStateOpts||null],l="["+k.map(function(a){return a||"null"}).join(", ")+"]",m={state:null,params:null,options:null,href:null},n=null;c.$watch(l,g,!0),g(c.$eval(l)),i.clickable&&(h=F(d,a,b,i,function(){return m}),d[d.on?"on":"bind"]("click",h),c.$on("$destroy",function(){d[d.off?"off":"unbind"]("click",h)}))}}}function J(a,b,c){return{restrict:"A",controller:["$scope","$element","$attrs","$timeout",function(b,d,e,f){function g(b,c,e){var f=a.get(b,D(d)),g=h(b,c),i={state:f||{name:b},params:c,hash:g};return p.push(i),q[g]=e,function(){var a=p.indexOf(i);a!==-1&&p.splice(a,1)}}function h(a,c){if(!O(a))throw new Error("state should be a string");return P(c)?a+U(c):(c=b.$eval(c),P(c)?a+U(c):a)}function i(){for(var a=0;a0)){var c=g(a,b,o);return i(),c}},b.$on("$stateChangeSuccess",i),i()}]}}function K(a){var b=function(b,c){return a.is(b,c)};return b.$stateful=!0,b}function L(a){var b=function(b,c,d){return a.includes(b,c,d)};return b.$stateful=!0,b}var M=b.isDefined,N=b.isFunction,O=b.isString,P=b.isObject,Q=b.isArray,R=b.forEach,S=b.extend,T=b.copy,U=b.toJson;b.module("ui.router.util",["ng"]),b.module("ui.router.router",["ui.router.util"]),b.module("ui.router.state",["ui.router.router","ui.router.util"]),b.module("ui.router",["ui.router.state"]),b.module("ui.router.compat",["ui.router"]),q.$inject=["$q","$injector"],b.module("ui.router.util").service("$resolve",q),r.$inject=["$http","$templateCache","$injector"],b.module("ui.router.util").service("$templateFactory",r);var V;s.prototype.concat=function(a,b){var c={caseInsensitive:V.caseInsensitive(),strict:V.strictMode(),squash:V.defaultSquashPolicy()};return new s(this.sourcePath+a+this.sourceSearch,S(c,b),this)},s.prototype.toString=function(){return this.source},s.prototype.exec=function(a,b){function c(a){function b(a){return a.split("").reverse().join("")}function c(a){return a.replace(/\\-/g,"-")}var d=b(a).split(/-(?!\\)/),e=o(d,b);return o(e,c).reverse()}var d=this.regexp.exec(a);if(!d)return null;b=b||{};var e,f,g,h=this.parameters(),i=h.length,j=this.segments.length-1,k={};if(j!==d.length-1)throw new Error("Unbalanced capture group in route '"+this.source+"'");var l,m;for(e=0;e
     */
    "undefined"!=typeof module&&"undefined"!=typeof exports&&module.exports===exports&&(module.exports="ui.router"),function(a,b,c){"use strict";function d(a,b){return S(new(S(function(){},{prototype:a})),b)}function e(a){return R(arguments,function(b){b!==a&&R(b,function(b,c){a.hasOwnProperty(c)||(a[c]=b)})}),a}function f(a,b){var c=[];for(var d in a.path){if(a.path[d]!==b.path[d])break;c.push(a.path[d])}return c}function g(a){if(Object.keys)return Object.keys(a);var b=[];return R(a,function(a,c){b.push(c)}),b}function h(a,b){if(Array.prototype.indexOf)return a.indexOf(b,Number(arguments[2])||0);var c=a.length>>>0,d=Number(arguments[2])||0;for(d=d<0?Math.ceil(d):Math.floor(d),d<0&&(d+=c);d=0||(k.push(e[m]),j[e[m]]=a[e[m]]);return S({},j,b)}function j(a,b,c){if(!c){c=[];for(var d in a)c.push(d)}for(var e=0;e "));if(s[c]=d,O(a))q.push(c,[function(){return b.get(a)}],j);else{var e=b.annotate(a);R(e,function(a){a!==c&&i.hasOwnProperty(a)&&n(i[a],a)}),q.push(c,a,e)}r.pop(),s[c]=f}}function o(a){return P(a)&&a.then&&a.$$promises}if(!P(i))throw new Error("'invocables' must be an object");var p=g(i||{}),q=[],r=[],s={};return R(i,n),i=r=s=null,function(d,f,g){function h(){--u||(v||e(t,f.$$values),r.$$values=t,r.$$promises=r.$$promises||!0,delete r.$$inheritedValues,n.resolve(t))}function i(a){r.$$failure=a,n.reject(a)}function j(c,e,f){function j(a){l.reject(a),i(a)}function k(){if(!M(r.$$failure))try{l.resolve(b.invoke(e,g,t)),l.promise.then(function(a){t[c]=a,h()},j)}catch(a){j(a)}}var l=a.defer(),m=0;R(f,function(a){s.hasOwnProperty(a)&&!d.hasOwnProperty(a)&&(m++,s[a].then(function(b){t[a]=b,--m||k()},j))}),m||k(),s[c]=l.promise}if(o(d)&&g===c&&(g=f,f=d,d=null),d){if(!P(d))throw new Error("'locals' must be an object")}else d=k;if(f){if(!o(f))throw new Error("'parent' must be a promise returned by $resolve.resolve()")}else f=l;var n=a.defer(),r=n.promise,s=r.$$promises={},t=S({},d),u=1+q.length/3,v=!1;if(M(f.$$failure))return i(f.$$failure),r;f.$$inheritedValues&&e(t,m(f.$$inheritedValues,p)),S(s,f.$$promises),f.$$values?(v=e(t,m(f.$$values,p)),r.$$inheritedValues=m(f.$$values,p),h()):(f.$$inheritedValues&&(r.$$inheritedValues=m(f.$$inheritedValues,p)),f.then(h,i));for(var w=0,x=q.length;w=0));)s=f(r.id,r.type,r.cfg,"path"),l+=g(r.segment,s.type.pattern.source,s.squash,s.isOptional),n.push(r.segment),m=j.lastIndex;t=a.substring(m);var u=t.indexOf("?");if(u>=0){var v=this.sourceSearch=t.substring(u);if(t=t.substring(0,u),this.sourcePath=a.substring(0,m+u),v.length>0)for(m=0;i=k.exec(v);)r=h(i,!0),s=f(r.id,r.type,r.cfg,"search"),m=j.lastIndex}else this.sourcePath=a,this.sourceSearch="";l+=g(t)+(b.strict===!1?"/?":"")+"$",n.push(t),this.regexp=new RegExp(l,b.caseInsensitive?"i":c),this.prefix=n[0],this.$$paramNames=q}function t(a){S(this,a)}function u(){function a(a){return null!=a?a.toString().replace(/(~|\/)/g,function(a){return{"~":"~~","/":"~2F"}[a]}):a}function e(a){return null!=a?a.toString().replace(/(~~|~2F)/g,function(a){return{"~~":"~","~2F":"/"}[a]}):a}function f(){return{strict:p,caseInsensitive:m}}function i(a){return N(a)||Q(a)&&N(a[a.length-1])}function j(){for(;w.length;){var a=w.shift();if(a.pattern)throw new Error("You cannot override a type's .pattern at runtime.");b.extend(r[a.name],l.invoke(a.def))}}function k(a){S(this,a||{})}V=this;var l,m=!1,p=!0,q=!1,r={},v=!0,w=[],x={string:{encode:a,decode:e,is:function(a){return null==a||!M(a)||"string"==typeof a},pattern:/[^\/]*/},int:{encode:a,decode:function(a){return parseInt(a,10)},is:function(a){return M(a)&&this.decode(a.toString())===a},pattern:/\d+/},bool:{encode:function(a){return a?1:0},decode:function(a){return 0!==parseInt(a,10)},is:function(a){return a===!0||a===!1},pattern:/0|1/},date:{encode:function(a){return this.is(a)?[a.getFullYear(),("0"+(a.getMonth()+1)).slice(-2),("0"+a.getDate()).slice(-2)].join("-"):c},decode:function(a){if(this.is(a))return a;var b=this.capture.exec(a);return b?new Date(b[1],b[2]-1,b[3]):c},is:function(a){return a instanceof Date&&!isNaN(a.valueOf())},equals:function(a,b){return this.is(a)&&this.is(b)&&a.toISOString()===b.toISOString()},pattern:/[0-9]{4}-(?:0[1-9]|1[0-2])-(?:0[1-9]|[1-2][0-9]|3[0-1])/,capture:/([0-9]{4})-(0[1-9]|1[0-2])-(0[1-9]|[1-2][0-9]|3[0-1])/},json:{encode:b.toJson,decode:b.fromJson,is:b.isObject,equals:b.equals,pattern:/[^\/]*/},any:{encode:b.identity,decode:b.identity,equals:b.equals,pattern:/.*/}};u.$$getDefaultValue=function(a){if(!i(a.value))return a.value;if(!l)throw new Error("Injectable functions cannot be called at configuration time");return l.invoke(a.value)},this.caseInsensitive=function(a){return M(a)&&(m=a),m},this.strictMode=function(a){return M(a)&&(p=a),p},this.defaultSquashPolicy=function(a){if(!M(a))return q;if(a!==!0&&a!==!1&&!O(a))throw new Error("Invalid squash policy: "+a+". Valid policies: false, true, arbitrary-string");return q=a,a},this.compile=function(a,b){return new s(a,S(f(),b))},this.isMatcher=function(a){if(!P(a))return!1;var b=!0;return R(s.prototype,function(c,d){N(c)&&(b=b&&M(a[d])&&N(a[d]))}),b},this.type=function(a,b,c){if(!M(b))return r[a];if(r.hasOwnProperty(a))throw new Error("A type named '"+a+"' has already been defined.");return r[a]=new t(S({name:a},b)),c&&(w.push({name:a,def:c}),v||j()),this},R(x,function(a,b){r[b]=new t(S({name:b},a))}),r=d(r,{}),this.$get=["$injector",function(a){return l=a,v=!1,j(),R(x,function(a,b){r[b]||(r[b]=new t(a))}),this}],this.Param=function(a,d,e,f){function j(a){var b=P(a)?g(a):[],c=h(b,"value")===-1&&h(b,"type")===-1&&h(b,"squash")===-1&&h(b,"array")===-1;return c&&(a={value:a}),a.$$fn=i(a.value)?a.value:function(){return a.value},a}function k(c,d,e){if(c.type&&d)throw new Error("Param '"+a+"' has two type configurations.");return d?d:c.type?b.isString(c.type)?r[c.type]:c.type instanceof t?c.type:new t(c.type):"config"===e?r.any:r.string}function m(){var b={array:"search"===f&&"auto"},c=a.match(/\[\]$/)?{array:!0}:{};return S(b,c,e).array}function p(a,b){var c=a.squash;if(!b||c===!1)return!1;if(!M(c)||null==c)return q;if(c===!0||O(c))return c;throw new Error("Invalid squash policy: '"+c+"'. Valid policies: false, true, or arbitrary string")}function s(a,b,d,e){var f,g,i=[{from:"",to:d||b?c:""},{from:null,to:d||b?c:""}];return f=Q(a.replace)?a.replace:[],O(e)&&f.push({from:e,to:c}),g=o(f,function(a){return a.from}),n(i,function(a){return h(g,a.from)===-1}).concat(f)}function u(){if(!l)throw new Error("Injectable functions cannot be called at configuration time");var a=l.invoke(e.$$fn);if(null!==a&&a!==c&&!x.type.is(a))throw new Error("Default value ("+a+") for parameter '"+x.id+"' is not an instance of Type ("+x.type.name+")");return a}function v(a){function b(a){return function(b){return b.from===a}}function c(a){var c=o(n(x.replace,b(a)),function(a){return a.to});return c.length?c[0]:a}return a=c(a),M(a)?x.type.$normalize(a):u()}function w(){return"{Param:"+a+" "+d+" squash: '"+A+"' optional: "+z+"}"}var x=this;e=j(e),d=k(e,d,f);var y=m();d=y?d.$asArray(y,"search"===f):d,"string"!==d.name||y||"path"!==f||e.value!==c||(e.value="");var z=e.value!==c,A=p(e,z),B=s(e,y,z,A);S(this,{id:a,type:d,location:f,array:y,squash:A,replace:B,isOptional:z,value:v,dynamic:c,config:e,toString:w})},k.prototype={$$new:function(){return d(this,S(new k,{$$parent:this}))},$$keys:function(){for(var a=[],b=[],c=this,d=g(k.prototype);c;)b.push(c),c=c.$$parent;return b.reverse(),R(b,function(b){R(g(b),function(b){h(a,b)===-1&&h(d,b)===-1&&a.push(b)})}),a},$$values:function(a){var b={},c=this;return R(c.$$keys(),function(d){b[d]=c[d].value(a&&a[d])}),b},$$equals:function(a,b){var c=!0,d=this;return R(d.$$keys(),function(e){var f=a&&a[e],g=b&&b[e];d[e].type.equals(f,g)||(c=!1)}),c},$$validates:function(a){var d,e,f,g,h,i=this.$$keys();for(d=0;d=0)throw new Error("State must have a valid name");if(A.hasOwnProperty(c))throw new Error("State '"+c+"' is already defined");var e=c.indexOf(".")!==-1?c.substring(0,c.lastIndexOf(".")):O(b.parent)?b.parent:P(b.parent)&&O(b.parent.name)?b.parent.name:"";if(e&&!A[e])return n(e,b.self);for(var f in D)N(D[f])&&(b[f]=D[f](b,D.$delegates[f]));return A[c]=b,!b[C]&&b.url&&a.when(b.url,["$match","$stateParams",function(a,c){z.$current.navigable==b&&j(a,c)||z.transitionTo(b,a,{inherit:!0,location:!1})}]),q(c),b}function s(a){return a.indexOf("*")>-1}function t(a){for(var b=a.split("."),c=z.$current.name.split("."),d=0,e=b.length;d=A;d--)g=o[d],g.self.onExit&&h.invoke(g.self.onExit,g.self,g.locals.globals),g.locals=null;for(d=A;d2?k.enter(a,null,c).then(d):k.enter(a,null,c,d)},leave:function(a,c){b.version.minor>2?k.leave(a).then(c):k.leave(a,c)}};if(j){var e=j&&j(c,a);return{enter:function(a,b,c){e.enter(a,null,b),c()},leave:function(a,b){e.leave(a),b()}}}return d()}var i=g(),j=i("$animator"),k=i("$animate"),l={restrict:"ECA",terminal:!0,priority:400,transclude:"element",compile:function(c,g,i){return function(c,g,j){function k(){if(m&&(m.remove(),m=null),o&&(o.$destroy(),o=null),n){var a=n.data("$uiViewAnim");s.leave(n,function(){a.$$animLeave.resolve(),m=null}),m=n,n=null}}function l(h){var l,m=B(c,j,g,e),t=m&&a.$current&&a.$current.locals[m];if(h||t!==p){l=c.$new(),p=a.$current.locals[m],l.$emit("$viewContentLoading",m);var u=i(l,function(a){var e=f.defer(),h=f.defer(),i={$animEnter:e.promise,$animLeave:h.promise,$$animLeave:h};a.data("$uiViewAnim",i),s.enter(a,g,function(){e.resolve(),o&&o.$emit("$viewContentAnimationEnded"),(b.isDefined(r)&&!r||c.$eval(r))&&d(a)}),k()});n=u,o=l,o.$emit("$viewContentLoaded",m),o.$eval(q)}}var m,n,o,p,q=j.onload||"",r=j.autoscroll,s=h(j,c);g.inheritedData("$uiView");c.$on("$stateChangeSuccess",function(){l(!1)}),l(!0)}}};return l}function A(a,c,d,e){return{restrict:"ECA",priority:-400,compile:function(f){var g=f.html();return function(f,h,i){var j=d.$current,k=B(f,i,h,e),l=j&&j.locals[k];if(l){h.data("$uiView",{name:k,state:l.$$state}),h.html(l.$template?l.$template:g);var m=b.extend({},l);f[l.$$resolveAs]=m;var n=a(h.contents());if(l.$$controller){l.$scope=f,l.$element=h;var o=c(l.$$controller,l);l.$$controllerAs&&(f[l.$$controllerAs]=o,f[l.$$controllerAs][l.$$resolveAs]=m),N(o.$onInit)&&o.$onInit(),h.data("$ngControllerController",o),h.children().data("$ngControllerController",o)}n(f)}}}}}function B(a,b,c,d){var e=d(b.uiView||b.name||"")(a),f=c.inheritedData("$uiView");return e.indexOf("@")>=0?e:e+"@"+(f?f.state.name:"")}function C(a,b){var c,d=a.match(/^\s*({[^}]*})\s*$/);if(d&&(a=b+"("+d[1]+")"),c=a.replace(/\n/g," ").match(/^([^(]+?)\s*(\((.*)\))?$/),!c||4!==c.length)throw new Error("Invalid state ref '"+a+"'");return{state:c[1],paramExpr:c[3]||null}}function D(a){var b=a.parent().inheritedData("$uiView");if(b&&b.state&&b.state.name)return b.state}function E(a){var b="[object SVGAnimatedString]"===Object.prototype.toString.call(a.prop("href")),c="FORM"===a[0].nodeName;return{attr:c?"action":b?"xlink:href":"href",isAnchor:"A"===a.prop("tagName").toUpperCase(),clickable:!c}}function F(a,b,c,d,e){return function(f){var g=f.which||f.button,h=e();if(!(g>1||f.ctrlKey||f.metaKey||f.shiftKey||a.attr("target"))){var i=c(function(){b.go(h.state,h.params,h.options)});f.preventDefault();var j=d.isAnchor&&!h.href?1:0;f.preventDefault=function(){j--<=0&&c.cancel(i)}}}}function G(a,b){return{relative:D(a)||b.$current,inherit:!0}}function H(a,c){return{restrict:"A",require:["?^uiSrefActive","?^uiSrefActiveEq"],link:function(d,e,f,g){var h,i=C(f.uiSref,a.current.name),j={state:i.state,href:null,params:null},k=E(e),l=g[1]||g[0],m=null;j.options=S(G(e,a),f.uiSrefOpts?d.$eval(f.uiSrefOpts):{});var n=function(c){c&&(j.params=b.copy(c)),j.href=a.href(i.state,j.params,j.options),m&&m(),l&&(m=l.$$addStateInfo(i.state,j.params)),null!==j.href&&f.$set(k.attr,j.href)};i.paramExpr&&(d.$watch(i.paramExpr,function(a){a!==j.params&&n(a)},!0),j.params=b.copy(d.$eval(i.paramExpr))),n(),k.clickable&&(h=F(e,a,c,k,function(){return j}),e[e.on?"on":"bind"]("click",h),d.$on("$destroy",function(){e[e.off?"off":"unbind"]("click",h)}))}}}function I(a,b){return{restrict:"A",require:["?^uiSrefActive","?^uiSrefActiveEq"],link:function(c,d,e,f){function g(b){m.state=b[0],m.params=b[1],m.options=b[2],m.href=a.href(m.state,m.params,m.options),n&&n(),j&&(n=j.$$addStateInfo(m.state,m.params)),m.href&&e.$set(i.attr,m.href)}var h,i=E(d),j=f[1]||f[0],k=[e.uiState,e.uiStateParams||null,e.uiStateOpts||null],l="["+k.map(function(a){return a||"null"}).join(", ")+"]",m={state:null,params:null,options:null,href:null},n=null;c.$watch(l,g,!0),g(c.$eval(l)),i.clickable&&(h=F(d,a,b,i,function(){return m}),d[d.on?"on":"bind"]("click",h),c.$on("$destroy",function(){d[d.off?"off":"unbind"]("click",h)}))}}}function J(a,b,c){return{restrict:"A",controller:["$scope","$element","$attrs","$timeout",function(b,d,e,f){function g(b,c,e){var f=a.get(b,D(d)),g=h(b,c),i={state:f||{name:b},params:c,hash:g};return p.push(i),q[g]=e,function(){var a=p.indexOf(i);a!==-1&&p.splice(a,1)}}function h(a,c){if(!O(a))throw new Error("state should be a string");return P(c)?a+U(c):(c=b.$eval(c),P(c)?a+U(c):a)}function i(){for(var a=0;a0)){var c=g(a,b,o);return i(),c}},b.$on("$stateChangeSuccess",i),i()}]}}function K(a){var b=function(b,c){return a.is(b,c)};return b.$stateful=!0,b}function L(a){var b=function(b,c,d){return a.includes(b,c,d)};return b.$stateful=!0,b}var M=b.isDefined,N=b.isFunction,O=b.isString,P=b.isObject,Q=b.isArray,R=b.forEach,S=b.extend,T=b.copy,U=b.toJson;b.module("ui.router.util",["ng"]),b.module("ui.router.router",["ui.router.util"]),b.module("ui.router.state",["ui.router.router","ui.router.util"]),b.module("ui.router",["ui.router.state"]),b.module("ui.router.compat",["ui.router"]),q.$inject=["$q","$injector"],b.module("ui.router.util").service("$resolve",q),r.$inject=["$http","$templateCache","$injector"],b.module("ui.router.util").service("$templateFactory",r);var V;s.prototype.concat=function(a,b){var c={caseInsensitive:V.caseInsensitive(),strict:V.strictMode(),squash:V.defaultSquashPolicy()};return new s(this.sourcePath+a+this.sourceSearch,S(c,b),this)},s.prototype.toString=function(){return this.source},s.prototype.exec=function(a,b){function c(a){function b(a){return a.split("").reverse().join("")}function c(a){return a.replace(/\\-/g,"-")}var d=b(a).split(/-(?!\\)/),e=o(d,b);return o(e,c).reverse()}var d=this.regexp.exec(a);if(!d)return null;b=b||{};var e,f,g,h=this.parameters(),i=h.length,j=this.segments.length-1,k={};if(j!==d.length-1)throw new Error("Unbalanced capture group in route '"+this.source+"'");var l,m;for(e=0;e
     */
    "undefined"!=typeof module&&"undefined"!=typeof exports&&module.exports===exports&&(module.exports="ui.router"),function(a,b,c){"use strict";function d(a,b){return S(new(S(function(){},{prototype:a})),b)}function e(a){return R(arguments,function(b){b!==a&&R(b,function(b,c){a.hasOwnProperty(c)||(a[c]=b)})}),a}function f(a,b){var c=[];for(var d in a.path){if(a.path[d]!==b.path[d])break;c.push(a.path[d])}return c}function g(a){if(Object.keys)return Object.keys(a);var b=[];return R(a,function(a,c){b.push(c)}),b}function h(a,b){if(Array.prototype.indexOf)return a.indexOf(b,Number(arguments[2])||0);var c=a.length>>>0,d=Number(arguments[2])||0;for(d=d<0?Math.ceil(d):Math.floor(d),d<0&&(d+=c);d=0||(k.push(e[m]),j[e[m]]=a[e[m]]);return S({},j,b)}function j(a,b,c){if(!c){c=[];for(var d in a)c.push(d)}for(var e=0;e "));if(s[c]=d,O(a))q.push(c,[function(){return b.get(a)}],j);else{var e=b.annotate(a);R(e,function(a){a!==c&&i.hasOwnProperty(a)&&n(i[a],a)}),q.push(c,a,e)}r.pop(),s[c]=f}}function o(a){return P(a)&&a.then&&a.$$promises}if(!P(i))throw new Error("'invocables' must be an object");var p=g(i||{}),q=[],r=[],s={};return R(i,n),i=r=s=null,function(d,f,g){function h(){--u||(v||e(t,f.$$values),r.$$values=t,r.$$promises=r.$$promises||!0,delete r.$$inheritedValues,n.resolve(t))}function i(a){r.$$failure=a,n.reject(a)}function j(c,e,f){function j(a){l.reject(a),i(a)}function k(){if(!M(r.$$failure))try{l.resolve(b.invoke(e,g,t)),l.promise.then(function(a){t[c]=a,h()},j)}catch(a){j(a)}}var l=a.defer(),m=0;R(f,function(a){s.hasOwnProperty(a)&&!d.hasOwnProperty(a)&&(m++,s[a].then(function(b){t[a]=b,--m||k()},j))}),m||k(),s[c]=l.promise}if(o(d)&&g===c&&(g=f,f=d,d=null),d){if(!P(d))throw new Error("'locals' must be an object")}else d=k;if(f){if(!o(f))throw new Error("'parent' must be a promise returned by $resolve.resolve()")}else f=l;var n=a.defer(),r=n.promise,s=r.$$promises={},t=S({},d),u=1+q.length/3,v=!1;if(M(f.$$failure))return i(f.$$failure),r;f.$$inheritedValues&&e(t,m(f.$$inheritedValues,p)),S(s,f.$$promises),f.$$values?(v=e(t,m(f.$$values,p)),r.$$inheritedValues=m(f.$$values,p),h()):(f.$$inheritedValues&&(r.$$inheritedValues=m(f.$$inheritedValues,p)),f.then(h,i));for(var w=0,x=q.length;w=0));)s=f(r.id,r.type,r.cfg,"path"),l+=g(r.segment,s.type.pattern.source,s.squash,s.isOptional),n.push(r.segment),m=j.lastIndex;t=a.substring(m);var u=t.indexOf("?");if(u>=0){var v=this.sourceSearch=t.substring(u);if(t=t.substring(0,u),this.sourcePath=a.substring(0,m+u),v.length>0)for(m=0;i=k.exec(v);)r=h(i,!0),s=f(r.id,r.type,r.cfg,"search"),m=j.lastIndex}else this.sourcePath=a,this.sourceSearch="";l+=g(t)+(b.strict===!1?"/?":"")+"$",n.push(t),this.regexp=new RegExp(l,b.caseInsensitive?"i":c),this.prefix=n[0],this.$$paramNames=q}function t(a){S(this,a)}function u(){function a(a){return null!=a?a.toString().replace(/(~|\/)/g,function(a){return{"~":"~~","/":"~2F"}[a]}):a}function e(a){return null!=a?a.toString().replace(/(~~|~2F)/g,function(a){return{"~~":"~","~2F":"/"}[a]}):a}function f(){return{strict:p,caseInsensitive:m}}function i(a){return N(a)||Q(a)&&N(a[a.length-1])}function j(){for(;w.length;){var a=w.shift();if(a.pattern)throw new Error("You cannot override a type's .pattern at runtime.");b.extend(r[a.name],l.invoke(a.def))}}function k(a){S(this,a||{})}V=this;var l,m=!1,p=!0,q=!1,r={},v=!0,w=[],x={string:{encode:a,decode:e,is:function(a){return null==a||!M(a)||"string"==typeof a},pattern:/[^\/]*/},int:{encode:a,decode:function(a){return parseInt(a,10)},is:function(a){return M(a)&&this.decode(a.toString())===a},pattern:/\d+/},bool:{encode:function(a){return a?1:0},decode:function(a){return 0!==parseInt(a,10)},is:function(a){return a===!0||a===!1},pattern:/0|1/},date:{encode:function(a){return this.is(a)?[a.getFullYear(),("0"+(a.getMonth()+1)).slice(-2),("0"+a.getDate()).slice(-2)].join("-"):c},decode:function(a){if(this.is(a))return a;var b=this.capture.exec(a);return b?new Date(b[1],b[2]-1,b[3]):c},is:function(a){return a instanceof Date&&!isNaN(a.valueOf())},equals:function(a,b){return this.is(a)&&this.is(b)&&a.toISOString()===b.toISOString()},pattern:/[0-9]{4}-(?:0[1-9]|1[0-2])-(?:0[1-9]|[1-2][0-9]|3[0-1])/,capture:/([0-9]{4})-(0[1-9]|1[0-2])-(0[1-9]|[1-2][0-9]|3[0-1])/},json:{encode:b.toJson,decode:b.fromJson,is:b.isObject,equals:b.equals,pattern:/[^\/]*/},any:{encode:b.identity,decode:b.identity,equals:b.equals,pattern:/.*/}};u.$$getDefaultValue=function(a){if(!i(a.value))return a.value;if(!l)throw new Error("Injectable functions cannot be called at configuration time");return l.invoke(a.value)},this.caseInsensitive=function(a){return M(a)&&(m=a),m},this.strictMode=function(a){return M(a)&&(p=a),p},this.defaultSquashPolicy=function(a){if(!M(a))return q;if(a!==!0&&a!==!1&&!O(a))throw new Error("Invalid squash policy: "+a+". Valid policies: false, true, arbitrary-string");return q=a,a},this.compile=function(a,b){return new s(a,S(f(),b))},this.isMatcher=function(a){if(!P(a))return!1;var b=!0;return R(s.prototype,function(c,d){N(c)&&(b=b&&M(a[d])&&N(a[d]))}),b},this.type=function(a,b,c){if(!M(b))return r[a];if(r.hasOwnProperty(a))throw new Error("A type named '"+a+"' has already been defined.");return r[a]=new t(S({name:a},b)),c&&(w.push({name:a,def:c}),v||j()),this},R(x,function(a,b){r[b]=new t(S({name:b},a))}),r=d(r,{}),this.$get=["$injector",function(a){return l=a,v=!1,j(),R(x,function(a,b){r[b]||(r[b]=new t(a))}),this}],this.Param=function(a,d,e,f){function j(a){var b=P(a)?g(a):[],c=h(b,"value")===-1&&h(b,"type")===-1&&h(b,"squash")===-1&&h(b,"array")===-1;return c&&(a={value:a}),a.$$fn=i(a.value)?a.value:function(){return a.value},a}function k(c,d,e){if(c.type&&d)throw new Error("Param '"+a+"' has two type configurations.");return d?d:c.type?b.isString(c.type)?r[c.type]:c.type instanceof t?c.type:new t(c.type):"config"===e?r.any:r.string}function m(){var b={array:"search"===f&&"auto"},c=a.match(/\[\]$/)?{array:!0}:{};return S(b,c,e).array}function p(a,b){var c=a.squash;if(!b||c===!1)return!1;if(!M(c)||null==c)return q;if(c===!0||O(c))return c;throw new Error("Invalid squash policy: '"+c+"'. Valid policies: false, true, or arbitrary string")}function s(a,b,d,e){var f,g,i=[{from:"",to:d||b?c:""},{from:null,to:d||b?c:""}];return f=Q(a.replace)?a.replace:[],O(e)&&f.push({from:e,to:c}),g=o(f,function(a){return a.from}),n(i,function(a){return h(g,a.from)===-1}).concat(f)}function u(){if(!l)throw new Error("Injectable functions cannot be called at configuration time");var a=l.invoke(e.$$fn);if(null!==a&&a!==c&&!x.type.is(a))throw new Error("Default value ("+a+") for parameter '"+x.id+"' is not an instance of Type ("+x.type.name+")");return a}function v(a){function b(a){return function(b){return b.from===a}}function c(a){var c=o(n(x.replace,b(a)),function(a){return a.to});return c.length?c[0]:a}return a=c(a),M(a)?x.type.$normalize(a):u()}function w(){return"{Param:"+a+" "+d+" squash: '"+A+"' optional: "+z+"}"}var x=this;e=j(e),d=k(e,d,f);var y=m();d=y?d.$asArray(y,"search"===f):d,"string"!==d.name||y||"path"!==f||e.value!==c||(e.value="");var z=e.value!==c,A=p(e,z),B=s(e,y,z,A);S(this,{id:a,type:d,location:f,array:y,squash:A,replace:B,isOptional:z,value:v,dynamic:c,config:e,toString:w})},k.prototype={$$new:function(){return d(this,S(new k,{$$parent:this}))},$$keys:function(){for(var a=[],b=[],c=this,d=g(k.prototype);c;)b.push(c),c=c.$$parent;return b.reverse(),R(b,function(b){R(g(b),function(b){h(a,b)===-1&&h(d,b)===-1&&a.push(b)})}),a},$$values:function(a){var b={},c=this;return R(c.$$keys(),function(d){b[d]=c[d].value(a&&a[d])}),b},$$equals:function(a,b){var c=!0,d=this;return R(d.$$keys(),function(e){var f=a&&a[e],g=b&&b[e];d[e].type.equals(f,g)||(c=!1)}),c},$$validates:function(a){var d,e,f,g,h,i=this.$$keys();for(d=0;d=0)throw new Error("State must have a valid name");if(A.hasOwnProperty(c))throw new Error("State '"+c+"' is already defined");var e=c.indexOf(".")!==-1?c.substring(0,c.lastIndexOf(".")):O(b.parent)?b.parent:P(b.parent)&&O(b.parent.name)?b.parent.name:"";if(e&&!A[e])return n(e,b.self);for(var f in D)N(D[f])&&(b[f]=D[f](b,D.$delegates[f]));return A[c]=b,!b[C]&&b.url&&a.when(b.url,["$match","$stateParams",function(a,c){z.$current.navigable==b&&j(a,c)||z.transitionTo(b,a,{inherit:!0,location:!1})}]),q(c),b}function s(a){return a.indexOf("*")>-1}function t(a){for(var b=a.split("."),c=z.$current.name.split("."),d=0,e=b.length;d=A;d--)g=o[d],g.self.onExit&&h.invoke(g.self.onExit,g.self,g.locals.globals),g.locals=null;for(d=A;d2?k.enter(a,null,c).then(d):k.enter(a,null,c,d)},leave:function(a,c){b.version.minor>2?k.leave(a).then(c):k.leave(a,c)}};if(j){var e=j&&j(c,a);return{enter:function(a,b,c){e.enter(a,null,b),c()},leave:function(a,b){e.leave(a),b()}}}return d()}var i=g(),j=i("$animator"),k=i("$animate"),l={restrict:"ECA",terminal:!0,priority:400,transclude:"element",compile:function(c,g,i){return function(c,g,j){function k(){if(m&&(m.remove(),m=null),o&&(o.$destroy(),o=null),n){var a=n.data("$uiViewAnim");s.leave(n,function(){a.$$animLeave.resolve(),m=null}),m=n,n=null}}function l(h){var l,m=B(c,j,g,e),t=m&&a.$current&&a.$current.locals[m];if(h||t!==p){l=c.$new(),p=a.$current.locals[m],l.$emit("$viewContentLoading",m);var u=i(l,function(a){var e=f.defer(),h=f.defer(),i={$animEnter:e.promise,$animLeave:h.promise,$$animLeave:h};a.data("$uiViewAnim",i),s.enter(a,g,function(){e.resolve(),o&&o.$emit("$viewContentAnimationEnded"),(b.isDefined(r)&&!r||c.$eval(r))&&d(a)}),k()});n=u,o=l,o.$emit("$viewContentLoaded",m),o.$eval(q)}}var m,n,o,p,q=j.onload||"",r=j.autoscroll,s=h(j,c);g.inheritedData("$uiView");c.$on("$stateChangeSuccess",function(){l(!1)}),l(!0)}}};return l}function A(a,c,d,e){return{restrict:"ECA",priority:-400,compile:function(f){var g=f.html();return function(f,h,i){var j=d.$current,k=B(f,i,h,e),l=j&&j.locals[k];if(l){h.data("$uiView",{name:k,state:l.$$state}),h.html(l.$template?l.$template:g);var m=b.extend({},l);f[l.$$resolveAs]=m;var n=a(h.contents());if(l.$$controller){l.$scope=f,l.$element=h;var o=c(l.$$controller,l);l.$$controllerAs&&(f[l.$$controllerAs]=o,f[l.$$controllerAs][l.$$resolveAs]=m),N(o.$onInit)&&o.$onInit(),h.data("$ngControllerController",o),h.children().data("$ngControllerController",o)}n(f)}}}}}function B(a,b,c,d){var e=d(b.uiView||b.name||"")(a),f=c.inheritedData("$uiView");return e.indexOf("@")>=0?e:e+"@"+(f?f.state.name:"")}function C(a,b){var c,d=a.match(/^\s*({[^}]*})\s*$/);if(d&&(a=b+"("+d[1]+")"),c=a.replace(/\n/g," ").match(/^([^(]+?)\s*(\((.*)\))?$/),!c||4!==c.length)throw new Error("Invalid state ref '"+a+"'");return{state:c[1],paramExpr:c[3]||null}}function D(a){var b=a.parent().inheritedData("$uiView");if(b&&b.state&&b.state.name)return b.state}function E(a){var b="[object SVGAnimatedString]"===Object.prototype.toString.call(a.prop("href")),c="FORM"===a[0].nodeName;return{attr:c?"action":b?"xlink:href":"href",isAnchor:"A"===a.prop("tagName").toUpperCase(),clickable:!c}}function F(a,b,c,d,e){return function(f){var g=f.which||f.button,h=e();if(!(g>1||f.ctrlKey||f.metaKey||f.shiftKey||a.attr("target"))){var i=c(function(){b.go(h.state,h.params,h.options)});f.preventDefault();var j=d.isAnchor&&!h.href?1:0;f.preventDefault=function(){j--<=0&&c.cancel(i)}}}}function G(a,b){return{relative:D(a)||b.$current,inherit:!0}}function H(a,c){return{restrict:"A",require:["?^uiSrefActive","?^uiSrefActiveEq"],link:function(d,e,f,g){var h,i=C(f.uiSref,a.current.name),j={state:i.state,href:null,params:null},k=E(e),l=g[1]||g[0],m=null;j.options=S(G(e,a),f.uiSrefOpts?d.$eval(f.uiSrefOpts):{});var n=function(c){c&&(j.params=b.copy(c)),j.href=a.href(i.state,j.params,j.options),m&&m(),l&&(m=l.$$addStateInfo(i.state,j.params)),null!==j.href&&f.$set(k.attr,j.href)};i.paramExpr&&(d.$watch(i.paramExpr,function(a){a!==j.params&&n(a)},!0),j.params=b.copy(d.$eval(i.paramExpr))),n(),k.clickable&&(h=F(e,a,c,k,function(){return j}),e[e.on?"on":"bind"]("click",h),d.$on("$destroy",function(){e[e.off?"off":"unbind"]("click",h)}))}}}function I(a,b){return{restrict:"A",require:["?^uiSrefActive","?^uiSrefActiveEq"],link:function(c,d,e,f){function g(b){m.state=b[0],m.params=b[1],m.options=b[2],m.href=a.href(m.state,m.params,m.options),n&&n(),j&&(n=j.$$addStateInfo(m.state,m.params)),m.href&&e.$set(i.attr,m.href)}var h,i=E(d),j=f[1]||f[0],k=[e.uiState,e.uiStateParams||null,e.uiStateOpts||null],l="["+k.map(function(a){return a||"null"}).join(", ")+"]",m={state:null,params:null,options:null,href:null},n=null;c.$watch(l,g,!0),g(c.$eval(l)),i.clickable&&(h=F(d,a,b,i,function(){return m}),d[d.on?"on":"bind"]("click",h),c.$on("$destroy",function(){d[d.off?"off":"unbind"]("click",h)}))}}}function J(a,b,c){return{restrict:"A",controller:["$scope","$element","$attrs","$timeout",function(b,d,e,f){function g(b,c,e){var f=a.get(b,D(d)),g=h(b,c),i={state:f||{name:b},params:c,hash:g};return p.push(i),q[g]=e,function(){var a=p.indexOf(i);a!==-1&&p.splice(a,1)}}function h(a,c){if(!O(a))throw new Error("state should be a string");return P(c)?a+U(c):(c=b.$eval(c),P(c)?a+U(c):a)}function i(){for(var a=0;a0)){var c=g(a,b,o);return i(),c}},b.$on("$stateChangeSuccess",i),i()}]}}function K(a){var b=function(b,c){return a.is(b,c)};return b.$stateful=!0,b}function L(a){var b=function(b,c,d){return a.includes(b,c,d)};return b.$stateful=!0,b}var M=b.isDefined,N=b.isFunction,O=b.isString,P=b.isObject,Q=b.isArray,R=b.forEach,S=b.extend,T=b.copy,U=b.toJson;b.module("ui.router.util",["ng"]),b.module("ui.router.router",["ui.router.util"]),b.module("ui.router.state",["ui.router.router","ui.router.util"]),b.module("ui.router",["ui.router.state"]),b.module("ui.router.compat",["ui.router"]),q.$inject=["$q","$injector"],b.module("ui.router.util").service("$resolve",q),r.$inject=["$http","$templateCache","$injector"],b.module("ui.router.util").service("$templateFactory",r);var V;s.prototype.concat=function(a,b){var c={caseInsensitive:V.caseInsensitive(),strict:V.strictMode(),squash:V.defaultSquashPolicy()};return new s(this.sourcePath+a+this.sourceSearch,S(c,b),this)},s.prototype.toString=function(){return this.source},s.prototype.exec=function(a,b){function c(a){function b(a){return a.split("").reverse().join("")}function c(a){return a.replace(/\\-/g,"-")}var d=b(a).split(/-(?!\\)/),e=o(d,b);return o(e,c).reverse()}var d=this.regexp.exec(a);if(!d)return null;b=b||{};var e,f,g,h=this.parameters(),i=h.length,j=this.segments.length-1,k={};if(j!==d.length-1)throw new Error("Unbalanced capture group in route '"+this.source+"'");var l,m;for(e=0;e
     */
    "undefined"!=typeof module&&"undefined"!=typeof exports&&module.exports===exports&&(module.exports="ui.router"),function(a,b,c){"use strict";function d(a,b){return S(new(S(function(){},{prototype:a})),b)}function e(a){return R(arguments,function(b){b!==a&&R(b,function(b,c){a.hasOwnProperty(c)||(a[c]=b)})}),a}function f(a,b){var c=[];for(var d in a.path){if(a.path[d]!==b.path[d])break;c.push(a.path[d])}return c}function g(a){if(Object.keys)return Object.keys(a);var b=[];return R(a,function(a,c){b.push(c)}),b}function h(a,b){if(Array.prototype.indexOf)return a.indexOf(b,Number(arguments[2])||0);var c=a.length>>>0,d=Number(arguments[2])||0;for(d=d<0?Math.ceil(d):Math.floor(d),d<0&&(d+=c);d=0||(k.push(e[m]),j[e[m]]=a[e[m]]);return S({},j,b)}function j(a,b,c){if(!c){c=[];for(var d in a)c.push(d)}for(var e=0;e "));if(s[c]=d,O(a))q.push(c,[function(){return b.get(a)}],j);else{var e=b.annotate(a);R(e,function(a){a!==c&&i.hasOwnProperty(a)&&n(i[a],a)}),q.push(c,a,e)}r.pop(),s[c]=f}}function o(a){return P(a)&&a.then&&a.$$promises}if(!P(i))throw new Error("'invocables' must be an object");var p=g(i||{}),q=[],r=[],s={};return R(i,n),i=r=s=null,function(d,f,g){function h(){--u||(v||e(t,f.$$values),r.$$values=t,r.$$promises=r.$$promises||!0,delete r.$$inheritedValues,n.resolve(t))}function i(a){r.$$failure=a,n.reject(a)}function j(c,e,f){function j(a){l.reject(a),i(a)}function k(){if(!M(r.$$failure))try{l.resolve(b.invoke(e,g,t)),l.promise.then(function(a){t[c]=a,h()},j)}catch(a){j(a)}}var l=a.defer(),m=0;R(f,function(a){s.hasOwnProperty(a)&&!d.hasOwnProperty(a)&&(m++,s[a].then(function(b){t[a]=b,--m||k()},j))}),m||k(),s[c]=l.promise}if(o(d)&&g===c&&(g=f,f=d,d=null),d){if(!P(d))throw new Error("'locals' must be an object")}else d=k;if(f){if(!o(f))throw new Error("'parent' must be a promise returned by $resolve.resolve()")}else f=l;var n=a.defer(),r=n.promise,s=r.$$promises={},t=S({},d),u=1+q.length/3,v=!1;if(M(f.$$failure))return i(f.$$failure),r;f.$$inheritedValues&&e(t,m(f.$$inheritedValues,p)),S(s,f.$$promises),f.$$values?(v=e(t,m(f.$$values,p)),r.$$inheritedValues=m(f.$$values,p),h()):(f.$$inheritedValues&&(r.$$inheritedValues=m(f.$$inheritedValues,p)),f.then(h,i));for(var w=0,x=q.length;w=0));)s=f(r.id,r.type,r.cfg,"path"),l+=g(r.segment,s.type.pattern.source,s.squash,s.isOptional),n.push(r.segment),m=j.lastIndex;t=a.substring(m);var u=t.indexOf("?");if(u>=0){var v=this.sourceSearch=t.substring(u);if(t=t.substring(0,u),this.sourcePath=a.substring(0,m+u),v.length>0)for(m=0;i=k.exec(v);)r=h(i,!0),s=f(r.id,r.type,r.cfg,"search"),m=j.lastIndex}else this.sourcePath=a,this.sourceSearch="";l+=g(t)+(b.strict===!1?"/?":"")+"$",n.push(t),this.regexp=new RegExp(l,b.caseInsensitive?"i":c),this.prefix=n[0],this.$$paramNames=q}function t(a){S(this,a)}function u(){function a(a){return null!=a?a.toString().replace(/(~|\/)/g,function(a){return{"~":"~~","/":"~2F"}[a]}):a}function e(a){return null!=a?a.toString().replace(/(~~|~2F)/g,function(a){return{"~~":"~","~2F":"/"}[a]}):a}function f(){return{strict:p,caseInsensitive:m}}function i(a){return N(a)||Q(a)&&N(a[a.length-1])}function j(){for(;w.length;){var a=w.shift();if(a.pattern)throw new Error("You cannot override a type's .pattern at runtime.");b.extend(r[a.name],l.invoke(a.def))}}function k(a){S(this,a||{})}V=this;var l,m=!1,p=!0,q=!1,r={},v=!0,w=[],x={string:{encode:a,decode:e,is:function(a){return null==a||!M(a)||"string"==typeof a},pattern:/[^\/]*/},int:{encode:a,decode:function(a){return parseInt(a,10)},is:function(a){return M(a)&&this.decode(a.toString())===a},pattern:/\d+/},bool:{encode:function(a){return a?1:0},decode:function(a){return 0!==parseInt(a,10)},is:function(a){return a===!0||a===!1},pattern:/0|1/},date:{encode:function(a){return this.is(a)?[a.getFullYear(),("0"+(a.getMonth()+1)).slice(-2),("0"+a.getDate()).slice(-2)].join("-"):c},decode:function(a){if(this.is(a))return a;var b=this.capture.exec(a);return b?new Date(b[1],b[2]-1,b[3]):c},is:function(a){return a instanceof Date&&!isNaN(a.valueOf())},equals:function(a,b){return this.is(a)&&this.is(b)&&a.toISOString()===b.toISOString()},pattern:/[0-9]{4}-(?:0[1-9]|1[0-2])-(?:0[1-9]|[1-2][0-9]|3[0-1])/,capture:/([0-9]{4})-(0[1-9]|1[0-2])-(0[1-9]|[1-2][0-9]|3[0-1])/},json:{encode:b.toJson,decode:b.fromJson,is:b.isObject,equals:b.equals,pattern:/[^\/]*/},any:{encode:b.identity,decode:b.identity,equals:b.equals,pattern:/.*/}};u.$$getDefaultValue=function(a){if(!i(a.value))return a.value;if(!l)throw new Error("Injectable functions cannot be called at configuration time");return l.invoke(a.value)},this.caseInsensitive=function(a){return M(a)&&(m=a),m},this.strictMode=function(a){return M(a)&&(p=a),p},this.defaultSquashPolicy=function(a){if(!M(a))return q;if(a!==!0&&a!==!1&&!O(a))throw new Error("Invalid squash policy: "+a+". Valid policies: false, true, arbitrary-string");return q=a,a},this.compile=function(a,b){return new s(a,S(f(),b))},this.isMatcher=function(a){if(!P(a))return!1;var b=!0;return R(s.prototype,function(c,d){N(c)&&(b=b&&M(a[d])&&N(a[d]))}),b},this.type=function(a,b,c){if(!M(b))return r[a];if(r.hasOwnProperty(a))throw new Error("A type named '"+a+"' has already been defined.");return r[a]=new t(S({name:a},b)),c&&(w.push({name:a,def:c}),v||j()),this},R(x,function(a,b){r[b]=new t(S({name:b},a))}),r=d(r,{}),this.$get=["$injector",function(a){return l=a,v=!1,j(),R(x,function(a,b){r[b]||(r[b]=new t(a))}),this}],this.Param=function(a,d,e,f){function j(a){var b=P(a)?g(a):[],c=h(b,"value")===-1&&h(b,"type")===-1&&h(b,"squash")===-1&&h(b,"array")===-1;return c&&(a={value:a}),a.$$fn=i(a.value)?a.value:function(){return a.value},a}function k(c,d,e){if(c.type&&d)throw new Error("Param '"+a+"' has two type configurations.");return d?d:c.type?b.isString(c.type)?r[c.type]:c.type instanceof t?c.type:new t(c.type):"config"===e?r.any:r.string}function m(){var b={array:"search"===f&&"auto"},c=a.match(/\[\]$/)?{array:!0}:{};return S(b,c,e).array}function p(a,b){var c=a.squash;if(!b||c===!1)return!1;if(!M(c)||null==c)return q;if(c===!0||O(c))return c;throw new Error("Invalid squash policy: '"+c+"'. Valid policies: false, true, or arbitrary string")}function s(a,b,d,e){var f,g,i=[{from:"",to:d||b?c:""},{from:null,to:d||b?c:""}];return f=Q(a.replace)?a.replace:[],O(e)&&f.push({from:e,to:c}),g=o(f,function(a){return a.from}),n(i,function(a){return h(g,a.from)===-1}).concat(f)}function u(){if(!l)throw new Error("Injectable functions cannot be called at configuration time");var a=l.invoke(e.$$fn);if(null!==a&&a!==c&&!x.type.is(a))throw new Error("Default value ("+a+") for parameter '"+x.id+"' is not an instance of Type ("+x.type.name+")");return a}function v(a){function b(a){return function(b){return b.from===a}}function c(a){var c=o(n(x.replace,b(a)),function(a){return a.to});return c.length?c[0]:a}return a=c(a),M(a)?x.type.$normalize(a):u()}function w(){return"{Param:"+a+" "+d+" squash: '"+A+"' optional: "+z+"}"}var x=this;e=j(e),d=k(e,d,f);var y=m();d=y?d.$asArray(y,"search"===f):d,"string"!==d.name||y||"path"!==f||e.value!==c||(e.value="");var z=e.value!==c,A=p(e,z),B=s(e,y,z,A);S(this,{id:a,type:d,location:f,array:y,squash:A,replace:B,isOptional:z,value:v,dynamic:c,config:e,toString:w})},k.prototype={$$new:function(){return d(this,S(new k,{$$parent:this}))},$$keys:function(){for(var a=[],b=[],c=this,d=g(k.prototype);c;)b.push(c),c=c.$$parent;return b.reverse(),R(b,function(b){R(g(b),function(b){h(a,b)===-1&&h(d,b)===-1&&a.push(b)})}),a},$$values:function(a){var b={},c=this;return R(c.$$keys(),function(d){b[d]=c[d].value(a&&a[d])}),b},$$equals:function(a,b){var c=!0,d=this;return R(d.$$keys(),function(e){var f=a&&a[e],g=b&&b[e];d[e].type.equals(f,g)||(c=!1)}),c},$$validates:function(a){var d,e,f,g,h,i=this.$$keys();for(d=0;d=0)throw new Error("State must have a valid name");if(A.hasOwnProperty(c))throw new Error("State '"+c+"' is already defined");var e=c.indexOf(".")!==-1?c.substring(0,c.lastIndexOf(".")):O(b.parent)?b.parent:P(b.parent)&&O(b.parent.name)?b.parent.name:"";if(e&&!A[e])return n(e,b.self);for(var f in D)N(D[f])&&(b[f]=D[f](b,D.$delegates[f]));return A[c]=b,!b[C]&&b.url&&a.when(b.url,["$match","$stateParams",function(a,c){z.$current.navigable==b&&j(a,c)||z.transitionTo(b,a,{inherit:!0,location:!1})}]),q(c),b}function s(a){return a.indexOf("*")>-1}function t(a){for(var b=a.split("."),c=z.$current.name.split("."),d=0,e=b.length;d=A;d--)g=o[d],g.self.onExit&&h.invoke(g.self.onExit,g.self,g.locals.globals),g.locals=null;for(d=A;d2?k.enter(a,null,c).then(d):k.enter(a,null,c,d)},leave:function(a,c){b.version.minor>2?k.leave(a).then(c):k.leave(a,c)}};if(j){var e=j&&j(c,a);return{enter:function(a,b,c){e.enter(a,null,b),c()},leave:function(a,b){e.leave(a),b()}}}return d()}var i=g(),j=i("$animator"),k=i("$animate"),l={restrict:"ECA",terminal:!0,priority:400,transclude:"element",compile:function(c,g,i){return function(c,g,j){function k(){if(m&&(m.remove(),m=null),o&&(o.$destroy(),o=null),n){var a=n.data("$uiViewAnim");s.leave(n,function(){a.$$animLeave.resolve(),m=null}),m=n,n=null}}function l(h){var l,m=B(c,j,g,e),t=m&&a.$current&&a.$current.locals[m];if(h||t!==p){l=c.$new(),p=a.$current.locals[m],l.$emit("$viewContentLoading",m);var u=i(l,function(a){var e=f.defer(),h=f.defer(),i={$animEnter:e.promise,$animLeave:h.promise,$$animLeave:h};a.data("$uiViewAnim",i),s.enter(a,g,function(){e.resolve(),o&&o.$emit("$viewContentAnimationEnded"),(b.isDefined(r)&&!r||c.$eval(r))&&d(a)}),k()});n=u,o=l,o.$emit("$viewContentLoaded",m),o.$eval(q)}}var m,n,o,p,q=j.onload||"",r=j.autoscroll,s=h(j,c);g.inheritedData("$uiView");c.$on("$stateChangeSuccess",function(){l(!1)}),l(!0)}}};return l}function A(a,c,d,e){return{restrict:"ECA",priority:-400,compile:function(f){var g=f.html();return function(f,h,i){var j=d.$current,k=B(f,i,h,e),l=j&&j.locals[k];if(l){h.data("$uiView",{name:k,state:l.$$state}),h.html(l.$template?l.$template:g);var m=b.extend({},l);f[l.$$resolveAs]=m;var n=a(h.contents());if(l.$$controller){l.$scope=f,l.$element=h;var o=c(l.$$controller,l);l.$$controllerAs&&(f[l.$$controllerAs]=o,f[l.$$controllerAs][l.$$resolveAs]=m),N(o.$onInit)&&o.$onInit(),h.data("$ngControllerController",o),h.children().data("$ngControllerController",o)}n(f)}}}}}function B(a,b,c,d){var e=d(b.uiView||b.name||"")(a),f=c.inheritedData("$uiView");return e.indexOf("@")>=0?e:e+"@"+(f?f.state.name:"")}function C(a,b){var c,d=a.match(/^\s*({[^}]*})\s*$/);if(d&&(a=b+"("+d[1]+")"),c=a.replace(/\n/g," ").match(/^([^(]+?)\s*(\((.*)\))?$/),!c||4!==c.length)throw new Error("Invalid state ref '"+a+"'");return{state:c[1],paramExpr:c[3]||null}}function D(a){var b=a.parent().inheritedData("$uiView");if(b&&b.state&&b.state.name)return b.state}function E(a){var b="[object SVGAnimatedString]"===Object.prototype.toString.call(a.prop("href")),c="FORM"===a[0].nodeName;return{attr:c?"action":b?"xlink:href":"href",isAnchor:"A"===a.prop("tagName").toUpperCase(),clickable:!c}}function F(a,b,c,d,e){return function(f){var g=f.which||f.button,h=e();if(!(g>1||f.ctrlKey||f.metaKey||f.shiftKey||a.attr("target"))){var i=c(function(){b.go(h.state,h.params,h.options)});f.preventDefault();var j=d.isAnchor&&!h.href?1:0;f.preventDefault=function(){j--<=0&&c.cancel(i)}}}}function G(a,b){return{relative:D(a)||b.$current,inherit:!0}}function H(a,c){return{restrict:"A",require:["?^uiSrefActive","?^uiSrefActiveEq"],link:function(d,e,f,g){var h,i=C(f.uiSref,a.current.name),j={state:i.state,href:null,params:null},k=E(e),l=g[1]||g[0],m=null;j.options=S(G(e,a),f.uiSrefOpts?d.$eval(f.uiSrefOpts):{});var n=function(c){c&&(j.params=b.copy(c)),j.href=a.href(i.state,j.params,j.options),m&&m(),l&&(m=l.$$addStateInfo(i.state,j.params)),null!==j.href&&f.$set(k.attr,j.href)};i.paramExpr&&(d.$watch(i.paramExpr,function(a){a!==j.params&&n(a)},!0),j.params=b.copy(d.$eval(i.paramExpr))),n(),k.clickable&&(h=F(e,a,c,k,function(){return j}),e[e.on?"on":"bind"]("click",h),d.$on("$destroy",function(){e[e.off?"off":"unbind"]("click",h)}))}}}function I(a,b){return{restrict:"A",require:["?^uiSrefActive","?^uiSrefActiveEq"],link:function(c,d,e,f){function g(b){m.state=b[0],m.params=b[1],m.options=b[2],m.href=a.href(m.state,m.params,m.options),n&&n(),j&&(n=j.$$addStateInfo(m.state,m.params)),m.href&&e.$set(i.attr,m.href)}var h,i=E(d),j=f[1]||f[0],k=[e.uiState,e.uiStateParams||null,e.uiStateOpts||null],l="["+k.map(function(a){return a||"null"}).join(", ")+"]",m={state:null,params:null,options:null,href:null},n=null;c.$watch(l,g,!0),g(c.$eval(l)),i.clickable&&(h=F(d,a,b,i,function(){return m}),d[d.on?"on":"bind"]("click",h),c.$on("$destroy",function(){d[d.off?"off":"unbind"]("click",h)}))}}}function J(a,b,c){return{restrict:"A",controller:["$scope","$element","$attrs","$timeout",function(b,d,e,f){function g(b,c,e){var f=a.get(b,D(d)),g=h(b,c),i={state:f||{name:b},params:c,hash:g};return p.push(i),q[g]=e,function(){var a=p.indexOf(i);a!==-1&&p.splice(a,1)}}function h(a,c){if(!O(a))throw new Error("state should be a string");return P(c)?a+U(c):(c=b.$eval(c),P(c)?a+U(c):a)}function i(){for(var a=0;a0)){var c=g(a,b,o);return i(),c}},b.$on("$stateChangeSuccess",i),i()}]}}function K(a){var b=function(b,c){return a.is(b,c)};return b.$stateful=!0,b}function L(a){var b=function(b,c,d){return a.includes(b,c,d)};return b.$stateful=!0,b}var M=b.isDefined,N=b.isFunction,O=b.isString,P=b.isObject,Q=b.isArray,R=b.forEach,S=b.extend,T=b.copy,U=b.toJson;b.module("ui.router.util",["ng"]),b.module("ui.router.router",["ui.router.util"]),b.module("ui.router.state",["ui.router.router","ui.router.util"]),b.module("ui.router",["ui.router.state"]),b.module("ui.router.compat",["ui.router"]),q.$inject=["$q","$injector"],b.module("ui.router.util").service("$resolve",q),r.$inject=["$http","$templateCache","$injector"],b.module("ui.router.util").service("$templateFactory",r);var V;s.prototype.concat=function(a,b){var c={caseInsensitive:V.caseInsensitive(),strict:V.strictMode(),squash:V.defaultSquashPolicy()};return new s(this.sourcePath+a+this.sourceSearch,S(c,b),this)},s.prototype.toString=function(){return this.source},s.prototype.exec=function(a,b){function c(a){function b(a){return a.split("").reverse().join("")}function c(a){return a.replace(/\\-/g,"-")}var d=b(a).split(/-(?!\\)/),e=o(d,b);return o(e,c).reverse()}var d=this.regexp.exec(a);if(!d)return null;b=b||{};var e,f,g,h=this.parameters(),i=h.length,j=this.segments.length-1,k={};if(j!==d.length-1)throw new Error("Unbalanced capture group in route '"+this.source+"'");var l,m;for(e=0;e
    @/lua/ge/extensions/core/cameraModes/transition.lua
    
    function C:update(data)
      local useOldCam = false
    @/inspector/Controllers/CodeMirrorGradientEditingController.js
            {
                popover.update();
            }
    @/inspector/Views/ComputedStyleSection.js
                    let styleOriginView = new WI.StyleOriginView();
                    styleOriginView.update(property.ownerStyle);
                    rightElement.append(styleOriginView.element);
    @/lua/ge/extensions/editor/driftDataEditor.lua
    
      if stuntZoneTransform and stuntZoneTransform:update(mouseInfo) then
        elem.pos = stuntZoneTransform.allowTranslate and stuntZoneTransform.pos or nil
          local driftBoxTr = transformsUtils[lineName.."driftBox"]
          if driftBoxTr and driftBoxTr:update(mouseInfo) then
            lineData.pos = driftBoxTr.allowTranslate and driftBoxTr.pos or nil
          local startDirTr = transformsUtils[lineName.."startDir"]
          if startDirTr and startDirTr:update(mouseInfo) then
            lineData.startDir = startDirTr.allowTranslate and startDirTr.pos - lineData.pos or nil
          local bigMapTpTr = transformsUtils["bigMapTp"]
          if bigMapTpTr and bigMapTpTr:update(mouseInfo) then
            currDriftSpots[selectedDriftSpotId].spatialInfo.bigMapTp.pos = bigMapTpTr.allowTranslate and bigMapTpTr.pos or nil
    @/lua/ge/extensions/scenario/raceMarkers/singleHologramMarker.lua
    
    function C:update(dt, dtSim)
      self.colorTimer = self.colorTimer + dt
      self.colorTimer = 0
      self:update(0,0)
    end
    @/inspector/Views/SourceCodeTextEditor.js
    
            widget.update();
        }
    
            widget.update();
        }
            this._ignoreLocationUpdateBreakpoint = breakpoint;
            breakpoint.sourceCodeLocation.update(this._sourceCode, unformattedNewLineInfo.lineNumber, unformattedNewLineInfo.columnNumber);
            this._ignoreLocationUpdateBreakpoint = null;
                    codeMirror.setValue(formattedText || data.description);
                    this._popover.update();
                });
    @/ui/ui-vue/src/common/directives/BngClick.js
     */
    function update(element, binding) {
      const id = element[ELEMENT_ID] || (element[ELEMENT_ID] = ++curId)
    
        const data = update(el, binding)
    
    @/lua/ge/extensions/editor/aiTests.lua
        end
        change = change or marker:update()
        im.Dummy(im.ImVec2(0, 5))
    @/lua/ge/extensions/core/cameraModes/autopoint.lua
    
    function C:update(data)
      local ref  = data.veh:getNodePosition(self.refNodes.ref)
    @/lua/ge/extensions/scenario/raceMarkers/sideMarker.lua
    -- called every frame to update the visuals.
    function C:update(dt, dtSim)
    
      end
      self:update(0,0)
    end
    @/lua/ge/extensions/gameplay/drift/stuntZones/nearPole.lua
      if self.marker then
        self.marker:update(dtReal, dtSim)
      end
    @/lua/ge/ge_utils.lua
    local function onPreRender(dtReal, dtSim, dtRaw)
      if(fpsLimiter:update(dtReal)) then
         ... do somthging here at 20 FPS ...
    @/lua/common/utils/interactiveShell.lua
    function updateOnce(n)
        BeamEngine:update(1/2000, 1/2000)
    end
        do
            BeamEngine:update(1/2000, 1/2000)
        end
    @/lua/ge/extensions/core/cameraModes/onboard.lua
    local camUp, camLeft, dir, rotatedUp = vec3(), vec3(), vec3(), vec3()
    function C:update(data)
      -- update input
    
      self.manualzoom:update(data)
    
    @/lua/common/utils/wsUtils.lua
      for i = 0, 3 do
        client:update()
        server:update()
        client:update()
        server:update()
      end
      for i = 0, 3 do
        client:update()
        server:update()
        client:update()
        server:update()
      end
    @/lua/ge/extensions/gameplay/delivery/delivery.lua
    
    function C:update(dt)
      if self.state == 'disabled' then return end
    @/ui/ui-vue/src/common/directives/BngDoubleClick.js
    
    function update(vnode, callback = undefined, mod = {}) {
      !globInit && initGlobals()
    export default {
      mounted: (el, { value, modifiers, arg } = {}, vnode) => update(vnode || { el }, value, { capture: arg === "capture", ...modifiers }),
      updated: (el, { value, modifiers, arg } = {}, vnode) => update(vnode || { el }, value, { capture: arg === "capture", ...modifiers }),
      mounted: (el, { value, modifiers, arg } = {}, vnode) => update(vnode || { el }, value, { capture: arg === "capture", ...modifiers }),
      updated: (el, { value, modifiers, arg } = {}, vnode) => update(vnode || { el }, value, { capture: arg === "capture", ...modifiers }),
      unmounted: (el, vnode) => update(vnode || { el }),
      updated: (el, { value, modifiers, arg } = {}, vnode) => update(vnode || { el }, value, { capture: arg === "capture", ...modifiers }),
      unmounted: (el, vnode) => update(vnode || { el }),
    }
    @/lua/ge/extensions/core/cameraModes/manualzoom.lua
    
    function C:update(data)
      if data.openxrSessionRunning then return false end
    @/inspector/Views/InlineSwatch.js
                this._valueEditor.addEventListener(WI.ColorPicker.Event.ColorChanged, this._valueEditorValueDidChange, this);
                this._valueEditor.addEventListener(WI.ColorPicker.Event.FormatChanged, (event) => popover.update());
                break;
                this._valueEditor.addEventListener(WI.GradientEditor.Event.GradientChanged, this._valueEditorValueDidChange, this);
                this._valueEditor.addEventListener(WI.GradientEditor.Event.ColorPickerToggled, (event) => popover.update());
                break;
                this._valueEditor.codeMirror.on("update", () => {
                    popover.update();
                });
    @/lua/vehicle/controller/playerController.lua
    
    local function update(dt)
      --stabilization
    @/lua/ge/extensions/scenario/raceMarkers/sideColumnMarker.lua
    local markerOffset = vec3(0,0,-10)
    function C:update(dt, dtSim)
      self.colorTimer = self.colorTimer + dt
    
      self:update(0,0)
    end
    @/lua/ge/extensions/core/cameraModes/collision.lua
    local camDir, camRight, camUp, dir, nearClipCenter, rayStart, newCamPos = vec3(), vec3(), vec3(), vec3(), vec3(), vec3(), vec3()
    function C:update(data)
      if not settings.getValue('cameraCollision', true) then return end
    @/inspector/Views/Popover.js
    
        update(shouldAnimate = true)
        {
    @/inspector/Models/CSSRule.js
    
            this.update(sourceCodeLocation, selectorText, selectors, matchedSelectorIndices, style, mediaList, true);
        }
    
        update(sourceCodeLocation, selectorText, selectors, matchedSelectorIndices, style, mediaList)
        {
    
                    this.update(sourceCodeLocation, selectorText, selectors, [], this._style, this._mediaList);
                }
    @/lua/ge/extensions/gameplay/rally/loop/rallyLoopManager.lua
          local strictMode = scheduleEntry.missionType == 'serviceIn' or scheduleEntry.missionType == 'serviceOut'
          self.speedingDetector:update(dtSim, scheduleEntry.speedLimitKph, strictMode)
        end
    
      -- Use shared method to update (onlyIfLater = false, since we always want to reschedule to next slot)
      local result = self:_updateSSStartTime(newTime, false, string.format('Not staged at -10s, slot: %d min', slotSizeMinutes))
    @/lua/common/jbeam/sections/events.lua
    
            abo:update(ab.translation, ab.rotation, true, 0)
    
    @/lua/ge/extensions/c2/webSocketHandler.lua
    
      server:update()
    end
    @/inspector/Views/SpreadsheetCSSStyleDeclarationSection.js
    
            this._styleOriginView.update(this._style);
            this._renderSelector();
    @/lua/ge/extensions/core/cameraModes/relative.lua
    
    function C:update(data)
      local ref  = vec3(data.veh:getNodePosition(self.refNodes.ref))
    
      self.manualzoom:update(data)
    
    @/inspector/Views/TextEditor.js
    
            function update()
            {
    @/ui/modules/environment/environment.js
      //vm.weatherPresets // commented out, since this is also commented out in the HTML side
      Environment.update()
      Environment.registerScope($scope, () => { $scope.$evalAsync(); })
    @/inspector/Models/SourceCodeLocation.js
    
        update(sourceCode, lineNumber, columnNumber)
        {
    @/lua/vehicle/controller/drivingDynamics/CMU.lua
    
    local function update(dt)
      M.updateCalibrationCallback(dt)
    @/inspector/Models/CSSStyleDeclaration.js
    
            this.update(text, properties, styleSheetTextRange, {dontFireEvents: true});
        }
    
        update(text, properties, styleSheetTextRange, options = {})
        {
    
            this.update(this._text, this._properties, this._styleSheetTextRange, {dontFireEvents: true, forceUpdate: true});
    
    @/lua/ge/extensions/scenario/raceMarkers/crawlMarker.lua
    
    function C:update(dt, dtSim)
      self.colorTimer = self.colorTimer + dt
    
      self:update(0,0)
    end
    @/inspector/Proxies/HeapSnapshotDiffProxy.js
    
            this.update(() => {
                this.dispatchEventToListeners(WI.HeapSnapshotProxy.Event.CollectedNodes, event.data);
    
        update(callback)
        {
    @/ui/ui-vue/src/modules/radial/radialsvg.js
       */
      update(items = []) {
        if (!this.itemsCont || !this.info) return
      for (const elm of btns) {
        elm.update(items[elm.index], events, radialInstance)
      }
    @/lua/ge/extensions/remoteControl/remoteControl.lua
      timer = timer + dtReal
      ws.update()
      if vim then
    @/lua/vehicle/controller/drivingDynamics/sensors/sensorHub.lua
    
    local function update(dt)
      M.rollAV, M.pitchAV, M.yawAV = obj:getRollPitchYawAngularVelocity()
    local function updateDebug(dt)
      update(dt)
    
    @/inspector/External/CodeMirror/codemirror.js
      var d = cm.display
      var sizes = d.scrollbars.update(measure)
    
      function spansFor(n) {return markedSpans ? markedSpans[n] : null}
      function update(line, text, spans) {
        updateLine(line, text, spans, estimateHeight)
        var added = linesFor(0, text.length - 1)
        update(lastLine, lastLine.text, lastSpans)
        if (nlines) { doc.remove(from.line, nlines) }
        if (text.length == 1) {
          update(firstLine, firstLine.text.slice(0, from.ch) + lastText + firstLine.text.slice(to.ch), lastSpans)
        } else {
          added$1.push(new Line(lastText + firstLine.text.slice(to.ch), lastSpans, estimateHeight))
          update(firstLine, firstLine.text.slice(0, from.ch) + text[0], spansFor(0))
          doc.insert(from.line + 1, added$1)
      } else if (text.length == 1) {
        update(firstLine, firstLine.text.slice(0, from.ch) + text[0] + lastLine.text.slice(to.ch), spansFor(0))
        doc.remove(from.line + 1, nlines)
      } else {
        update(firstLine, firstLine.text.slice(0, from.ch) + text[0], spansFor(0))
        update(lastLine, lastText + lastLine.text.slice(to.ch), lastSpans)
        update(firstLine, firstLine.text.slice(0, from.ch) + text[0], spansFor(0))
        update(lastLine, lastText + lastLine.text.slice(to.ch), lastSpans)
        var added$2 = linesFor(1, text.length - 1)
    @/lua/ge/extensions/core/cameraModes/topDown.lua
    
    function C:update(data)
      -- get the data
    @/lua/ge/extensions/core/vehicleTriggers.lua
        -- do not select another trigger if we are still using one
        if fpsLimiter:update(dtReal) then
          -- allow the c++ classes to draw the alpha according to the distance to this ray
    @/ui/ui-vue/src/common/directives/BngBlur.js
            } else {
              gameBlurrer.update(id, blur)
            }
    @/lua/vehicle/controller/tech/mesh.lua
    -- Physics step update for this sensor instance.
    local function update(dtSim)
      -- Cycle the physics update timer. If we are not ready for a physics step update, leave immediately.
    @/inspector/Base/Main.js
    
            WI._deviceSettingsPopover.update();
        }
    
                    WI._deviceSettingsPopover.update();
                }
    @/inspector/Views/ErrorObjectView.js
    
        update()
        {
    
            this.update();
        }
    @/inspector/Views/URLBreakpointPopover.js
                this._codeMirror.focus();
                this.update();
            }, 0);
    @/lua/vehicle/controller/tech/roadsSensor.lua
    -- The roads sensor physics step update callback.
    local function update(dtSim)
    
    @/lua/ge/extensions/flowgraph/nodes/scene/singleMarker.lua
          end
          self.marker:update(self.mgr.dtReal, self.mgr.dtSim)
          self.pinOut.flow.value = true
    @/lua/ge/extensions/core/cameraModes/observer.lua
    
    function C:update(data)
      if not self.cameraName then
    @/ui/modules/apps/Forcedinduction/app.js
                }
                svg.update(streams)
              } else {
    @/lua/ge/extensions/core/trafficSignals.lua
    
        -- whenever the timer is greater than the queue key, pops the queue and runs the sequence update (if valid)
        while not queue:empty() and queue:peekKey() <= timer do -- while loop is needed due to some timings happening at the same time
          if sequence then
            if sequence.stateTime == key then -- key must match, otherwise ignore the signal update (this can happen if a signal was changed manually)
              sequence._deltaTime = timer - key -- ensures accuracy between frames
    @/lua/vehicle/controller/controllerTemplate.lua
    
    -- local function update(dt)
    -- end
    @/lua/vehicle/controller/loggerTemplate.lua
    
    -- This runs at a fixed 100hz. (derived from 2000hz physics step, see note about performance on update())
    local function updateFixedStep(dt)
    -- like disk IO in anything that is/derives from the 2000hz update
    local function update(dt)
      -- increment timer with passed time since last call, depending on where this is called (update, updateFixedStep, updateGFX the resolution of time keeping changes)
    @/lua/vehicle/main.lua
      wheels.updateWheelVelocities(dtPhys)
      powertrain.update(dtPhys)
      controller.updateWheelsIntermediate(dtPhys)
      wheels.updateWheelTorques(dtPhys)
      controller.update(dtPhys)
      thrusters.update()
      controller.update(dtPhys)
      thrusters.update()
      hydros.update(dtPhys)
      thrusters.update()
      hydros.update(dtPhys)
      beamstate.update(dtPhys)
      hydros.update(dtPhys)
      beamstate.update(dtPhys)
      protocols.update(dtPhys)
      beamstate.update(dtPhys)
      protocols.update(dtPhys)
      extensionsHook("onPhysicsStep", dtPhys)